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
56,800
js_ecvt1
bluesky950520[P]quickjs/quickjs.c
static int js_ecvt1(double d, int n_digits, char dest[minimum_length(JS_ECVT_BUF_SIZE)], size_t size, int *decpt) { /* d is positive, ensure decimal point is always present */ snprintf(dest, size, "%#.*e", n_digits - 1, d); /* dest contents: 0: first digit 1: '.' decimal point (locale specific) 2..n_digits: (n_digits-1) additional digits n_digits+1: 'e' exponent mark n_digits+2..: exponent sign, value and null terminator */ /* extract the exponent (actually the position of the decimal point) */ *decpt = 1 + atoi(dest + n_digits + 2); return n_digits; }
O0
c
js_ecvt1: subq $0x28, %rsp movsd %xmm0, 0x20(%rsp) movl %edi, 0x1c(%rsp) movq %rsi, 0x10(%rsp) movq %rdx, 0x8(%rsp) movq %rcx, (%rsp) movq 0x10(%rsp), %rdi movq 0x8(%rsp), %rsi movl 0x1c(%rsp), %ecx subl $0x1, %ecx movsd 0x20(%rsp), %xmm0 leaq 0xab9a8(%rip), %rdx # 0x10e232 movb $0x1, %al callq 0xe2d0 movq 0x10(%rsp), %rdi movslq 0x1c(%rsp), %rax addq %rax, %rdi addq $0x2, %rdi callq 0xe880 movl %eax, %ecx addl $0x1, %ecx movq (%rsp), %rax movl %ecx, (%rax) movl 0x1c(%rsp), %eax addq $0x28, %rsp retq nopl (%rax,%rax)
js_ecvt1: sub rsp, 28h movsd [rsp+28h+var_8], xmm0 mov [rsp+28h+var_C], edi mov [rsp+28h+var_18], rsi mov [rsp+28h+var_20], rdx mov [rsp+28h+var_28], rcx mov rdi, [rsp+28h+var_18] mov rsi, [rsp+28h+var_20] mov ecx, [rsp+28h+var_C] sub ecx, 1 movsd xmm0, [rsp+28h+var_8] lea rdx, aE; "%#.*e" mov al, 1 call _snprintf mov rdi, [rsp+28h+var_18] movsxd rax, [rsp+28h+var_C] add rdi, rax add rdi, 2 call _atoi mov ecx, eax add ecx, 1 mov rax, [rsp+28h+var_28] mov [rax], ecx mov eax, [rsp+28h+var_C] add rsp, 28h retn
long long js_ecvt1(unsigned int a1, long long a2, long long a3, _DWORD *a4, double a5) { snprintf(a2, a3, "%#.*e", a1 - 1, a5); *a4 = atoi((int)a1 + a2 + 2) + 1; return a1; }
js_ecvt1: SUB RSP,0x28 MOVSD qword ptr [RSP + 0x20],XMM0 MOV dword ptr [RSP + 0x1c],EDI MOV qword ptr [RSP + 0x10],RSI MOV qword ptr [RSP + 0x8],RDX MOV qword ptr [RSP],RCX MOV RDI,qword ptr [RSP + 0x10] MOV RSI,qword ptr [RSP + 0x8] MOV ECX,dword ptr [RSP + 0x1c] SUB ECX,0x1 MOVSD XMM0,qword ptr [RSP + 0x20] LEA RDX,[0x20e232] MOV AL,0x1 CALL 0x0010e2d0 MOV RDI,qword ptr [RSP + 0x10] MOVSXD RAX,dword ptr [RSP + 0x1c] ADD RDI,RAX ADD RDI,0x2 CALL 0x0010e880 MOV ECX,EAX ADD ECX,0x1 MOV RAX,qword ptr [RSP] MOV dword ptr [RAX],ECX MOV EAX,dword ptr [RSP + 0x1c] ADD RSP,0x28 RET
int js_ecvt1(int8 param_1,int param_2,char *param_3,size_t param_4,int *param_5) { int iVar1; snprintf(param_3,param_4,"%#.*e",param_1,(ulong)(param_2 - 1)); iVar1 = atoi(param_3 + (long)param_2 + 2); *param_5 = iVar1 + 1; return param_2; }
56,801
js_ecvt1
bluesky950520[P]quickjs/quickjs.c
static int js_ecvt1(double d, int n_digits, char dest[minimum_length(JS_ECVT_BUF_SIZE)], size_t size, int *decpt) { /* d is positive, ensure decimal point is always present */ snprintf(dest, size, "%#.*e", n_digits - 1, d); /* dest contents: 0: first digit 1: '.' decimal point (locale specific) 2..n_digits: (n_digits-1) additional digits n_digits+1: 'e' exponent mark n_digits+2..: exponent sign, value and null terminator */ /* extract the exponent (actually the position of the decimal point) */ *decpt = 1 + atoi(dest + n_digits + 2); return n_digits; }
O2
c
js_ecvt1: pushq %r15 pushq %r14 pushq %rbx movq %rdx, %rbx movq %rsi, %r14 movl %edi, %r15d leal -0x1(%r15), %ecx leaq 0x4f7cc(%rip), %rdx # 0x8611e pushq $0x7d popq %rsi movq %r14, %rdi movb $0x1, %al callq 0xe2e0 movslq %r15d, %r15 leaq (%r14,%r15), %rdi addq $0x2, %rdi callq 0xe8b0 incl %eax movl %eax, (%rbx) movl %r15d, %eax popq %rbx popq %r14 popq %r15 retq
js_ecvt1: push r15 push r14 push rbx mov rbx, rdx mov r14, rsi mov r15d, edi lea ecx, [r15-1] lea rdx, aE; "%#.*e" push 7Dh ; '}' pop rsi mov rdi, r14 mov al, 1 call _snprintf movsxd r15, r15d lea rdi, [r14+r15] add rdi, 2 call _atoi inc eax mov [rbx], eax mov eax, r15d pop rbx pop r14 pop r15 retn
long long js_ecvt1(unsigned int a1, long long a2, _DWORD *a3, double a4) { snprintf(a2, 125LL, "%#.*e", a1 - 1, a4); *a3 = atoi(a2 + (int)a1 + 2) + 1; return a1; }
js_ecvt1: PUSH R15 PUSH R14 PUSH RBX MOV RBX,RDX MOV R14,RSI MOV R15D,EDI LEA ECX,[R15 + -0x1] LEA RDX,[0x18611e] PUSH 0x7d POP RSI MOV RDI,R14 MOV AL,0x1 CALL 0x0010e2e0 MOVSXD R15,R15D LEA RDI,[R14 + R15*0x1] ADD RDI,0x2 CALL 0x0010e8b0 INC EAX MOV dword ptr [RBX],EAX MOV EAX,R15D POP RBX POP R14 POP R15 RET
int js_ecvt1(int param_1,char *param_2,int *param_3) { int iVar1; snprintf(param_2,0x7d,"%#.*e",(ulong)(param_1 - 1)); iVar1 = atoi(param_2 + (long)param_1 + 2); *param_3 = iVar1 + 1; return param_1; }
56,802
func_uni_ksc5601_onechar
eloqsql/strings/ctype-euc_kr.c
static int func_uni_ksc5601_onechar(int code){ if ((code>=0x00A1)&&(code<=0x0167)) return(tab_uni_ksc56010[code-0x00A1]); if ((code>=0x02C7)&&(code<=0x0451)) return(tab_uni_ksc56011[code-0x02C7]); if ((code>=0x2015)&&(code<=0x2312)) return(tab_uni_ksc56012[code-0x2015]); if ((code>=0x2460)&&(code<=0x266D)) return(tab_uni_ksc56013[code-0x2460]); if ((code>=0x3000)&&(code<=0x327F)) return(tab_uni_ksc56014[code-0x3000]); if ((code>=0x3380)&&(code<=0x33DD)) return(tab_uni_ksc56015[code-0x3380]); if ((code>=0x4E00)&&(code<=0x947F)) return(tab_uni_ksc56016[code-0x4E00]); if ((code>=0x9577)&&(code<=0x9F9C)) return(tab_uni_ksc56017[code-0x9577]); if ((code>=0xAC00)&&(code<=0xD7A3)) return(tab_uni_ksc56018[code-0xAC00]); if ((code>=0xF900)&&(code<=0xFA0B)) return(tab_uni_ksc56019[code-0xF900]); if ((code>=0xFF01)&&(code<=0xFFE6)) return(tab_uni_ksc560110[code-0xFF01]); return(0); }
O0
c
func_uni_ksc5601_onechar: pushq %rbp movq %rsp, %rbp movl %edi, -0x8(%rbp) cmpl $0xa1, -0x8(%rbp) jl 0x72317 cmpl $0x167, -0x8(%rbp) # imm = 0x167 jg 0x72317 movl -0x8(%rbp), %eax subl $0xa1, %eax movslq %eax, %rcx leaq 0xec145(%rip), %rax # 0x15e450 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0x2c7, -0x8(%rbp) # imm = 0x2C7 jl 0x72347 cmpl $0x451, -0x8(%rbp) # imm = 0x451 jg 0x72347 movl -0x8(%rbp), %eax subl $0x2c7, %eax # imm = 0x2C7 movslq %eax, %rcx leaq 0xec2a5(%rip), %rax # 0x15e5e0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0x2015, -0x8(%rbp) # imm = 0x2015 jl 0x72377 cmpl $0x2312, -0x8(%rbp) # imm = 0x2312 jg 0x72377 movl -0x8(%rbp), %eax subl $0x2015, %eax # imm = 0x2015 movslq %eax, %rcx leaq 0xec595(%rip), %rax # 0x15e900 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0x2460, -0x8(%rbp) # imm = 0x2460 jl 0x723a7 cmpl $0x266d, -0x8(%rbp) # imm = 0x266D jg 0x723a7 movl -0x8(%rbp), %eax subl $0x2460, %eax # imm = 0x2460 movslq %eax, %rcx leaq 0xecb65(%rip), %rax # 0x15ef00 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0x3000, -0x8(%rbp) # imm = 0x3000 jl 0x723d7 cmpl $0x327f, -0x8(%rbp) # imm = 0x327F jg 0x723d7 movl -0x8(%rbp), %eax subl $0x3000, %eax # imm = 0x3000 movslq %eax, %rcx leaq 0xecf55(%rip), %rax # 0x15f320 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0x3380, -0x8(%rbp) # imm = 0x3380 jl 0x72407 cmpl $0x33dd, -0x8(%rbp) # imm = 0x33DD jg 0x72407 movl -0x8(%rbp), %eax subl $0x3380, %eax # imm = 0x3380 movslq %eax, %rcx leaq 0xed425(%rip), %rax # 0x15f820 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0x4e00, -0x8(%rbp) # imm = 0x4E00 jl 0x72437 cmpl $0x947f, -0x8(%rbp) # imm = 0x947F jg 0x72437 movl -0x8(%rbp), %eax subl $0x4e00, %eax # imm = 0x4E00 movslq %eax, %rcx leaq 0xed4b5(%rip), %rax # 0x15f8e0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0x9577, -0x8(%rbp) # imm = 0x9577 jl 0x72467 cmpl $0x9f9c, -0x8(%rbp) # imm = 0x9F9C jg 0x72467 movl -0x8(%rbp), %eax subl $0x9577, %eax # imm = 0x9577 movslq %eax, %rcx leaq 0xf6185(%rip), %rax # 0x1685e0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0xac00, -0x8(%rbp) # imm = 0xAC00 jl 0x72494 cmpl $0xd7a3, -0x8(%rbp) # imm = 0xD7A3 jg 0x72494 movl -0x8(%rbp), %eax subl $0xac00, %eax # imm = 0xAC00 movslq %eax, %rcx leaq 0xf75a5(%rip), %rax # 0x169a30 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0xf900, -0x8(%rbp) # imm = 0xF900 jl 0x724c1 cmpl $0xfa0b, -0x8(%rbp) # imm = 0xFA0B jg 0x724c1 movl -0x8(%rbp), %eax subl $0xf900, %eax # imm = 0xF900 movslq %eax, %rcx leaq 0xfccc8(%rip), %rax # 0x16f180 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 cmpl $0xff01, -0x8(%rbp) # imm = 0xFF01 jl 0x724ee cmpl $0xffe6, -0x8(%rbp) # imm = 0xFFE6 jg 0x724ee movl -0x8(%rbp), %eax subl $0xff01, %eax # imm = 0xFF01 movslq %eax, %rcx leaq 0xfcebb(%rip), %rax # 0x16f3a0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x724f5 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopw (%rax,%rax)
func_uni_ksc5601_onechar: push rbp mov rbp, rsp mov [rbp+var_8], edi cmp [rbp+var_8], 0A1h jl short loc_72317 cmp [rbp+var_8], 167h jg short loc_72317 mov eax, [rbp+var_8] sub eax, 0A1h movsxd rcx, eax lea rax, tab_uni_ksc56010 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_724F5 loc_72317: cmp [rbp+var_8], 2C7h jl short loc_72347 cmp [rbp+var_8], 451h jg short loc_72347 mov eax, [rbp+var_8] sub eax, 2C7h movsxd rcx, eax lea rax, tab_uni_ksc56011 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_724F5 loc_72347: cmp [rbp+var_8], 2015h jl short loc_72377 cmp [rbp+var_8], 2312h jg short loc_72377 mov eax, [rbp+var_8] sub eax, 2015h movsxd rcx, eax lea rax, tab_uni_ksc56012 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_724F5 loc_72377: cmp [rbp+var_8], 2460h jl short loc_723A7 cmp [rbp+var_8], 266Dh jg short loc_723A7 mov eax, [rbp+var_8] sub eax, 2460h movsxd rcx, eax lea rax, tab_uni_ksc56013 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_724F5 loc_723A7: cmp [rbp+var_8], 3000h jl short loc_723D7 cmp [rbp+var_8], 327Fh jg short loc_723D7 mov eax, [rbp+var_8] sub eax, 3000h movsxd rcx, eax lea rax, tab_uni_ksc56014 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_724F5 loc_723D7: cmp [rbp+var_8], 3380h jl short loc_72407 cmp [rbp+var_8], 33DDh jg short loc_72407 mov eax, [rbp+var_8] sub eax, 3380h movsxd rcx, eax lea rax, tab_uni_ksc56015 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_724F5 loc_72407: cmp [rbp+var_8], 4E00h jl short loc_72437 cmp [rbp+var_8], 947Fh jg short loc_72437 mov eax, [rbp+var_8] sub eax, 4E00h movsxd rcx, eax lea rax, tab_uni_ksc56016 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_724F5 loc_72437: cmp [rbp+var_8], 9577h jl short loc_72467 cmp [rbp+var_8], 9F9Ch jg short loc_72467 mov eax, [rbp+var_8] sub eax, 9577h movsxd rcx, eax lea rax, tab_uni_ksc56017 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_724F5 loc_72467: cmp [rbp+var_8], 0AC00h jl short loc_72494 cmp [rbp+var_8], 0D7A3h jg short loc_72494 mov eax, [rbp+var_8] sub eax, 0AC00h movsxd rcx, eax lea rax, tab_uni_ksc56018 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp short loc_724F5 loc_72494: cmp [rbp+var_8], 0F900h jl short loc_724C1 cmp [rbp+var_8], 0FA0Bh jg short loc_724C1 mov eax, [rbp+var_8] sub eax, 0F900h movsxd rcx, eax lea rax, tab_uni_ksc56019 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp short loc_724F5 loc_724C1: cmp [rbp+var_8], 0FF01h jl short loc_724EE cmp [rbp+var_8], 0FFE6h jg short loc_724EE mov eax, [rbp+var_8] sub eax, 0FF01h movsxd rcx, eax lea rax, tab_uni_ksc560110 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp short loc_724F5 loc_724EE: mov [rbp+var_4], 0 loc_724F5: mov eax, [rbp+var_4] pop rbp retn
long long func_uni_ksc5601_onechar(int a1) { if ( a1 < 161 || a1 > 359 ) { if ( a1 < 711 || a1 > 1105 ) { if ( a1 < 8213 || a1 > 8978 ) { if ( a1 < 9312 || a1 > 9837 ) { if ( a1 < 12288 || a1 > 12927 ) { if ( a1 < 13184 || a1 > 13277 ) { if ( a1 < 19968 || a1 > 38015 ) { if ( a1 < 38263 || a1 > 40860 ) { if ( a1 < 44032 || a1 > 55203 ) { if ( a1 < 63744 || a1 > 64011 ) { if ( a1 < 65281 || a1 > 65510 ) return 0; else return tab_uni_ksc560110[a1 - 65281]; } else { return tab_uni_ksc56019[a1 - 63744]; } } else { return tab_uni_ksc56018[a1 - 44032]; } } else { return tab_uni_ksc56017[a1 - 38263]; } } else { return tab_uni_ksc56016[a1 - 19968]; } } else { return tab_uni_ksc56015[a1 - 13184]; } } else { return tab_uni_ksc56014[a1 - 12288]; } } else { return tab_uni_ksc56013[a1 - 9312]; } } else { return tab_uni_ksc56012[a1 - 8213]; } } else { return tab_uni_ksc56011[a1 - 711]; } } else { return tab_uni_ksc56010[a1 - 161]; } }
func_uni_ksc5601_onechar: PUSH RBP MOV RBP,RSP MOV dword ptr [RBP + -0x8],EDI CMP dword ptr [RBP + -0x8],0xa1 JL 0x00172317 CMP dword ptr [RBP + -0x8],0x167 JG 0x00172317 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0xa1 MOVSXD RCX,EAX LEA RAX,[0x25e450] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_00172317: CMP dword ptr [RBP + -0x8],0x2c7 JL 0x00172347 CMP dword ptr [RBP + -0x8],0x451 JG 0x00172347 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x2c7 MOVSXD RCX,EAX LEA RAX,[0x25e5e0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_00172347: CMP dword ptr [RBP + -0x8],0x2015 JL 0x00172377 CMP dword ptr [RBP + -0x8],0x2312 JG 0x00172377 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x2015 MOVSXD RCX,EAX LEA RAX,[0x25e900] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_00172377: CMP dword ptr [RBP + -0x8],0x2460 JL 0x001723a7 CMP dword ptr [RBP + -0x8],0x266d JG 0x001723a7 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x2460 MOVSXD RCX,EAX LEA RAX,[0x25ef00] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_001723a7: CMP dword ptr [RBP + -0x8],0x3000 JL 0x001723d7 CMP dword ptr [RBP + -0x8],0x327f JG 0x001723d7 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x3000 MOVSXD RCX,EAX LEA RAX,[0x25f320] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_001723d7: CMP dword ptr [RBP + -0x8],0x3380 JL 0x00172407 CMP dword ptr [RBP + -0x8],0x33dd JG 0x00172407 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x3380 MOVSXD RCX,EAX LEA RAX,[0x25f820] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_00172407: CMP dword ptr [RBP + -0x8],0x4e00 JL 0x00172437 CMP dword ptr [RBP + -0x8],0x947f JG 0x00172437 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x4e00 MOVSXD RCX,EAX LEA RAX,[0x25f8e0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_00172437: CMP dword ptr [RBP + -0x8],0x9577 JL 0x00172467 CMP dword ptr [RBP + -0x8],0x9f9c JG 0x00172467 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x9577 MOVSXD RCX,EAX LEA RAX,[0x2685e0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_00172467: CMP dword ptr [RBP + -0x8],0xac00 JL 0x00172494 CMP dword ptr [RBP + -0x8],0xd7a3 JG 0x00172494 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0xac00 MOVSXD RCX,EAX LEA RAX,[0x269a30] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_00172494: CMP dword ptr [RBP + -0x8],0xf900 JL 0x001724c1 CMP dword ptr [RBP + -0x8],0xfa0b JG 0x001724c1 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0xf900 MOVSXD RCX,EAX LEA RAX,[0x26f180] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_001724c1: CMP dword ptr [RBP + -0x8],0xff01 JL 0x001724ee CMP dword ptr [RBP + -0x8],0xffe6 JG 0x001724ee MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0xff01 MOVSXD RCX,EAX LEA RAX,[0x26f3a0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x001724f5 LAB_001724ee: MOV dword ptr [RBP + -0x4],0x0 LAB_001724f5: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int2 func_uni_ksc5601_onechar(int param_1) { int2 uVar1; if ((param_1 < 0xa1) || (0x167 < param_1)) { if ((param_1 < 0x2c7) || (0x451 < param_1)) { if ((param_1 < 0x2015) || (0x2312 < param_1)) { if ((param_1 < 0x2460) || (0x266d < param_1)) { if ((param_1 < 0x3000) || (0x327f < param_1)) { if ((param_1 < 0x3380) || (0x33dd < param_1)) { if ((param_1 < 0x4e00) || (0x947f < param_1)) { if ((param_1 < 0x9577) || (0x9f9c < param_1)) { if ((param_1 < 0xac00) || (0xd7a3 < param_1)) { if ((param_1 < 0xf900) || (0xfa0b < param_1)) { if ((param_1 < 0xff01) || (0xffe6 < param_1)) { uVar1 = 0; } else { uVar1 = *(int2 *)(tab_uni_ksc560110 + (long)(param_1 + -0xff01) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56019 + (long)(param_1 + -0xf900) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56018 + (long)(param_1 + -0xac00) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56017 + (long)(param_1 + -0x9577) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56016 + (long)(param_1 + -0x4e00) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56015 + (long)(param_1 + -0x3380) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56014 + (long)(param_1 + -0x3000) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56013 + (long)(param_1 + -0x2460) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56012 + (long)(param_1 + -0x2015) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56011 + (long)(param_1 + -0x2c7) * 2); } } else { uVar1 = *(int2 *)(tab_uni_ksc56010 + (long)(param_1 + -0xa1) * 2); } return uVar1; }
56,803
fmt::v11::detail::bigint::align(fmt::v11::detail::bigint const&)
zkingston[P]unknot/build_O1/_deps/fmt-src/include/fmt/format.h
FMT_CONSTEXPR void align(const bigint& other) { int exp_difference = exp_ - other.exp_; if (exp_difference <= 0) return; int num_bigits = static_cast<int>(bigits_.size()); bigits_.resize(to_unsigned(num_bigits + exp_difference)); for (int i = num_bigits - 1, j = i + exp_difference; i >= 0; --i, --j) bigits_[j] = bigits_[i]; memset(bigits_.data(), 0, to_unsigned(exp_difference) * sizeof(bigit)); exp_ -= exp_difference; }
O1
c
fmt::v11::detail::bigint::align(fmt::v11::detail::bigint const&): pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movl 0xa8(%rdi), %r15d subl 0xa8(%rsi), %r15d jle 0x450f9 movq %rdi, %rbx movl 0x8(%rdi), %r12d leal (%r15,%r12), %r14d cmpq %r14, 0x10(%rdi) jae 0x450aa movq %rbx, %rdi movq %r14, %rsi callq *0x18(%rbx) movq 0x10(%rbx), %rax cmpq %rax, %r14 cmovbq %r14, %rax movq %rax, 0x8(%rbx) testl %r12d, %r12d jle 0x450e1 movl %r12d, %eax decl %eax leal (%r12,%r15), %edx decl %edx movq (%rbx), %rcx movslq %edx, %rdx incq %rax movl -0x4(%rcx,%rax,4), %esi movl %esi, (%rcx,%rdx,4) decq %rdx decq %rax jg 0x450d2 movq (%rbx), %rdi movl %r15d, %edx shlq $0x2, %rdx xorl %esi, %esi callq 0xf5b0 subl %r15d, 0xa8(%rbx) addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq nop
_ZN3fmt3v116detail6bigint5alignERKS2_: push r15 push r14 push r12 push rbx push rax mov r15d, [rdi+0A8h] sub r15d, [rsi+0A8h] jle short loc_450F9 mov rbx, rdi mov r12d, [rdi+8] lea r14d, [r15+r12] cmp [rdi+10h], r14 jnb short loc_450AA mov rdi, rbx mov rsi, r14 call qword ptr [rbx+18h] loc_450AA: mov rax, [rbx+10h] cmp r14, rax cmovb rax, r14 mov [rbx+8], rax test r12d, r12d jle short loc_450E1 mov eax, r12d dec eax lea edx, [r12+r15] dec edx mov rcx, [rbx] movsxd rdx, edx inc rax loc_450D2: mov esi, [rcx+rax*4-4] mov [rcx+rdx*4], esi dec rdx dec rax jg short loc_450D2 loc_450E1: mov rdi, [rbx] mov edx, r15d shl rdx, 2 xor esi, esi call _memset sub [rbx+0A8h], r15d loc_450F9: add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
void fmt::v11::detail::bigint::align(fmt::v11::detail::bigint *this, const fmt::v11::detail::bigint *a2) { int v2; // r15d bool v3; // cc unsigned int v4; // r15d int v5; // r12d unsigned long long v6; // r14 unsigned long long v7; // rax long long v8; // rcx long long v9; // rdx long long v10; // rax v2 = *((_DWORD *)this + 42); v3 = v2 <= *((_DWORD *)a2 + 42); v4 = v2 - *((_DWORD *)a2 + 42); if ( !v3 ) { v5 = *((_DWORD *)this + 2); v6 = v4 + v5; if ( *((_QWORD *)this + 2) < v6 ) (*((void ( **)(fmt::v11::detail::bigint *, _QWORD))this + 3))(this, v4 + v5); v7 = *((_QWORD *)this + 2); if ( v6 < v7 ) v7 = v4 + v5; *((_QWORD *)this + 1) = v7; if ( v5 > 0 ) { v8 = *(_QWORD *)this; v9 = (int)(v5 + v4 - 1); v10 = (unsigned int)(v5 - 1) + 1LL; do { *(_DWORD *)(v8 + 4 * v9--) = *(_DWORD *)(v8 + 4 * v10 - 4); v3 = v10-- <= 1; } while ( !v3 ); } memset(*(_QWORD *)this, 0LL, 4LL * v4); *((_DWORD *)this + 42) -= v4; } }
align: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV R15D,dword ptr [RDI + 0xa8] SUB R15D,dword ptr [RSI + 0xa8] JLE 0x001450f9 MOV RBX,RDI MOV R12D,dword ptr [RDI + 0x8] LEA R14D,[R15 + R12*0x1] CMP qword ptr [RDI + 0x10],R14 JNC 0x001450aa MOV RDI,RBX MOV RSI,R14 CALL qword ptr [RBX + 0x18] LAB_001450aa: MOV RAX,qword ptr [RBX + 0x10] CMP R14,RAX CMOVC RAX,R14 MOV qword ptr [RBX + 0x8],RAX TEST R12D,R12D JLE 0x001450e1 MOV EAX,R12D DEC EAX LEA EDX,[R12 + R15*0x1] DEC EDX MOV RCX,qword ptr [RBX] MOVSXD RDX,EDX INC RAX LAB_001450d2: MOV ESI,dword ptr [RCX + RAX*0x4 + -0x4] MOV dword ptr [RCX + RDX*0x4],ESI DEC RDX DEC RAX JG 0x001450d2 LAB_001450e1: MOV RDI,qword ptr [RBX] MOV EDX,R15D SHL RDX,0x2 XOR ESI,ESI CALL 0x0010f5b0 SUB dword ptr [RBX + 0xa8],R15D LAB_001450f9: ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
/* fmt::v11::detail::bigint::align(fmt::v11::detail::bigint const&) */ void __thiscall fmt::v11::detail::bigint::align(bigint *this,bigint *param_1) { int iVar1; long lVar2; bool bVar3; ulong uVar4; long lVar5; long lVar6; long lVar7; ulong uVar8; uint uVar9; uVar9 = *(int *)(this + 0xa8) - *(int *)(param_1 + 0xa8); if (uVar9 != 0 && *(int *)(param_1 + 0xa8) <= *(int *)(this + 0xa8)) { iVar1 = *(int *)(this + 8); uVar8 = (ulong)(uVar9 + iVar1); if (*(ulong *)(this + 0x10) < uVar8) { (**(code **)(this + 0x18))(this); } uVar4 = *(ulong *)(this + 0x10); if (uVar8 < *(ulong *)(this + 0x10)) { uVar4 = uVar8; } *(ulong *)(this + 8) = uVar4; if (0 < iVar1) { lVar2 = *(long *)this; lVar7 = (long)(int)(iVar1 + uVar9 + -1); lVar5 = (ulong)(iVar1 - 1) + 1; do { *(int4 *)(lVar2 + lVar7 * 4) = *(int4 *)(lVar2 + -4 + lVar5 * 4); lVar7 = lVar7 + -1; lVar6 = lVar5 + -1; bVar3 = 0 < lVar5; lVar5 = lVar6; } while (lVar6 != 0 && bVar3); } memset(*(void **)this,0,(ulong)uVar9 << 2); *(uint *)(this + 0xa8) = *(int *)(this + 0xa8) - uVar9; } return; }
56,804
nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::decode(unsigned char&, unsigned int&, unsigned char)
llama.cpp/common/json.hpp
static std::uint8_t decode(std::uint8_t& state, std::uint32_t& codep, const std::uint8_t byte) noexcept { static const std::array<std::uint8_t, 400> utf8d = { { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 00..1F 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 20..3F 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 40..5F 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 60..7F 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, // 80..9F 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, // A0..BF 8, 8, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, // C0..DF 0xA, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x4, 0x3, 0x3, // E0..EF 0xB, 0x6, 0x6, 0x6, 0x5, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, // F0..FF 0x0, 0x1, 0x2, 0x3, 0x5, 0x8, 0x7, 0x1, 0x1, 0x1, 0x4, 0x6, 0x1, 0x1, 0x1, 0x1, // s0..s0 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, // s1..s2 1, 2, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, // s3..s4 1, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 3, 1, 1, 1, 1, 1, 1, // s5..s6 1, 3, 1, 1, 1, 1, 1, 3, 1, 3, 1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 // s7..s8 } }; JSON_ASSERT(byte < utf8d.size()); const std::uint8_t type = utf8d[byte]; codep = (state != UTF8_ACCEPT) ? (byte & 0x3fu) | (codep << 6u) : (0xFFu >> type) & (byte); const std::size_t index = 256u + static_cast<size_t>(state) * 16u + static_cast<size_t>(type); JSON_ASSERT(index < utf8d.size()); state = utf8d[index]; return state; }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::decode(unsigned char&, unsigned int&, unsigned char): pushq %rax movl %edx, %ecx leaq 0x520f6(%rip), %rax # 0x121d72 movzbl (%rax,%rcx), %ecx cmpb $0x0, (%rdi) je 0xcfc96 andb $0x3f, %dl movzbl %dl, %r8d movl (%rsi), %edx shll $0x6, %edx orl %r8d, %edx jmp 0xcfca5 movl $0xff, %r8d shrl %cl, %r8d movzbl %dl, %edx andl %r8d, %edx movl %edx, (%rsi) movzbl (%rdi), %edx shll $0x4, %edx movl %ecx, %ecx addq %rdx, %rcx addq $0x100, %rcx # imm = 0x100 cmpq $0x190, %rcx # imm = 0x190 jae 0xcfcc9 movb (%rax,%rcx), %al movb %al, (%rdi) popq %rcx retq leaq 0x48b42(%rip), %rdi # 0x118812 leaq 0x48b76(%rip), %rdx # 0x11884d leaq 0x49f1e(%rip), %rcx # 0x119bfc movl $0x49fb, %esi # imm = 0x49FB xorl %eax, %eax callq 0x20e40 movq %rax, %rdi callq 0x27dc5
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE6decodeERhRjh: push rax mov ecx, edx lea rax, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE6decodeERhRjhE5utf8d; nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::decode(uchar &,uint &,uchar)::utf8d movzx ecx, byte ptr [rax+rcx] cmp byte ptr [rdi], 0 jz short loc_CFC96 and dl, 3Fh movzx r8d, dl mov edx, [rsi] shl edx, 6 or edx, r8d jmp short loc_CFCA5 loc_CFC96: mov r8d, 0FFh shr r8d, cl movzx edx, dl and edx, r8d loc_CFCA5: mov [rsi], edx movzx edx, byte ptr [rdi] shl edx, 4 mov ecx, ecx add rcx, rdx add rcx, 100h cmp rcx, 190h jnb short loc_CFCC9 mov al, [rax+rcx] mov [rdi], al pop rcx retn loc_CFCC9: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/llama."... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aIndexUtf8dSize; "index < utf8d.size()" mov esi, 49FBh xor eax, eax call _ggml_abort mov rdi, rax call __clang_call_terminate
unsigned __int8 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>>::decode( unsigned __int8 *a1, unsigned int *a2, int a3) { unsigned int v3; // ecx unsigned int v4; // edx unsigned long long v5; // rcx unsigned __int8 result; // al void *v7; // rax v3 = 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>>::decode(unsigned char &,unsigned int &,unsigned char)::utf8d[a3]; if ( *a1 ) v4 = a3 & 0x3F | (*a2 << 6); else v4 = (0xFFu >> v3) & (unsigned __int8)a3; *a2 = v4; v5 = 16 * (unsigned int)*a1 + (unsigned long long)v3 + 256; if ( v5 >= 0x190 ) { ggml_abort( "/workspace/llm4binary/github2025/llama.cpp/common/json.hpp", 18939LL, "GGML_ASSERT(%s) failed", "index < utf8d.size()"); _clang_call_terminate(v7); } result = 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>>::decode(unsigned char &,unsigned int &,unsigned char)::utf8d[v5]; *a1 = result; return result; }
decode: PUSH RAX MOV ECX,EDX LEA RAX,[0x221d72] MOVZX ECX,byte ptr [RAX + RCX*0x1] CMP byte ptr [RDI],0x0 JZ 0x001cfc96 AND DL,0x3f MOVZX R8D,DL MOV EDX,dword ptr [RSI] SHL EDX,0x6 OR EDX,R8D JMP 0x001cfca5 LAB_001cfc96: MOV R8D,0xff SHR R8D,CL MOVZX EDX,DL AND EDX,R8D LAB_001cfca5: MOV dword ptr [RSI],EDX MOVZX EDX,byte ptr [RDI] SHL EDX,0x4 MOV ECX,ECX ADD RCX,RDX ADD RCX,0x100 CMP RCX,0x190 JNC 0x001cfcc9 MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RDI],AL POP RCX RET LAB_001cfcc9: LEA RDI,[0x218812] LEA RDX,[0x21884d] LEA RCX,[0x219bfc] MOV ESI,0x49fb XOR EAX,EAX CALL 0x00120e40
/* 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> >::decode(unsigned char&, unsigned int&, unsigned char) */ void 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>> ::decode(uchar *param_1,uint *param_2,uchar param_3) { byte bVar1; long lVar2; uint uVar3; int7 in_register_00000011; bVar1 = decode(unsigned_char&,unsigned_int&,unsigned_char)::utf8d [CONCAT71(in_register_00000011,param_3) & 0xffffffff]; if (*param_1 == '\0') { uVar3 = (uint)param_3 & 0xffU >> (bVar1 & 0x1f); } else { uVar3 = *param_2 << 6 | (uint)(param_3 & 0x3f); } *param_2 = uVar3; lVar2 = (ulong)bVar1 + (ulong)*param_1 * 0x10; if (lVar2 + 0x100U < 400) { *param_1 = decode(unsigned_char&,unsigned_int&,unsigned_char)::utf8d[lVar2 + 0x100]; return; } /* try { // try from 001cfcc9 to 001cfce9 has its CatchHandler @ 001cfcea */ /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github2025/llama.cpp/common/json.hpp",0x49fb, "GGML_ASSERT(%s) failed","index < utf8d.size()"); }
56,805
testing::internal::GetThreadCount()
AlayaLite/build_O0/_deps/googletest-src/googletest/src/gtest-port.cc
size_t GetThreadCount() { const std::string filename = (Message() << "/proc/" << getpid() << "/stat").GetString(); return ReadProcFileField<size_t>(filename, 19); }
O0
cpp
testing::internal::GetThreadCount(): subq $0x68, %rsp leaq 0x40(%rsp), %rdi movq %rdi, 0x20(%rsp) callq 0x22e80 movq 0x20(%rsp), %rdi leaq 0x5e39a(%rip), %rsi # 0x74289 callq 0x46eb0 movq %rax, 0x28(%rsp) jmp 0x15efb callq 0xb7b0 movq 0x28(%rsp), %rdi movl %eax, 0x30(%rsp) leaq 0x30(%rsp), %rsi callq 0x46ef0 movq %rax, 0x18(%rsp) jmp 0x15f1a movq 0x18(%rsp), %rdi leaq 0x5e36a(%rip), %rsi # 0x74290 callq 0x46f30 movq %rax, 0x10(%rsp) jmp 0x15f32 movq 0x10(%rsp), %rsi leaq 0x48(%rsp), %rdi callq 0x14e90 jmp 0x15f43 leaq 0x40(%rsp), %rdi callq 0xee50 leaq 0x48(%rsp), %rdi movl $0x13, %esi callq 0x1acb0 movq %rax, 0x8(%rsp) jmp 0x15f63 leaq 0x48(%rsp), %rdi callq 0xec60 movq 0x8(%rsp), %rax addq $0x68, %rsp retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x38(%rsp) movl %eax, 0x34(%rsp) leaq 0x40(%rsp), %rdi callq 0xee50 jmp 0x15fa9 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x38(%rsp) movl %eax, 0x34(%rsp) leaq 0x48(%rsp), %rdi callq 0xec60 movq 0x38(%rsp), %rdi callq 0xb910 nopw %cs:(%rax,%rax)
_ZN7testing8internal14GetThreadCountEv: sub rsp, 68h lea rdi, [rsp+68h+var_28]; this mov [rsp+68h+var_48], rdi call _ZN7testing7MessageC2Ev; testing::Message::Message(void) mov rdi, [rsp+68h+var_48] lea rsi, aProc; "/proc/" call _ZN7testing7MessagelsIA7_cEERS0_RKT_; testing::Message::operator<<<char [7]>(char [7] const&) mov [rsp+68h+var_40], rax jmp short $+2 loc_15EFB: call _getpid mov rdi, [rsp+68h+var_40] mov [rsp+68h+var_38], eax lea rsi, [rsp+68h+var_38] call _ZN7testing7MessagelsIiEERS0_RKT_; testing::Message::operator<<<int>(int const&) mov [rsp+68h+var_50], rax jmp short $+2 loc_15F1A: mov rdi, [rsp+68h+var_50] lea rsi, aStat_0; "/stat" call _ZN7testing7MessagelsIA6_cEERS0_RKT_; testing::Message::operator<<<char [6]>(char [6] const&) mov qword ptr [rsp+68h+var_58], rax jmp short $+2 loc_15F32: mov rsi, qword ptr [rsp+68h+var_58]; int lea rdi, [rsp+68h+var_20]; int call _ZNK7testing7Message9GetStringB5cxx11Ev; testing::Message::GetString(void) jmp short $+2 loc_15F43: lea rdi, [rsp+68h+var_28]; this call _ZN7testing7MessageD2Ev; testing::Message::~Message() lea rdi, [rsp+68h+var_20] mov esi, 13h call _ZN7testing8internal12_GLOBAL__N_117ReadProcFileFieldImEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi; testing::internal::`anonymous namespace'::ReadProcFileField<ulong>(std::string const&,int) mov [rsp+68h+var_60], rax jmp short $+2 loc_15F63: lea rdi, [rsp+68h+var_20]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rax, [rsp+68h+var_60] add rsp, 68h retn mov rcx, rax mov eax, edx mov [rsp+arg_30], rcx mov [rsp+arg_2C], eax lea rdi, [rsp+arg_38]; this call _ZN7testing7MessageD2Ev; testing::Message::~Message() jmp short loc_15FA9 mov rcx, rax mov eax, edx mov [rsp+arg_30], rcx mov [rsp+arg_2C], eax lea rdi, [rsp+arg_40]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() loc_15FA9: mov rdi, [rsp+arg_30] call __Unwind_Resume
long long testing::internal::GetThreadCount(testing::internal *this) { long long ProcFile; // [rsp+8h] [rbp-60h] int v3; // [rsp+10h] [rbp-58h] long long v4; // [rsp+18h] [rbp-50h] long long v5; // [rsp+28h] [rbp-40h] _DWORD v6[4]; // [rsp+30h] [rbp-38h] BYREF _BYTE v7[8]; // [rsp+40h] [rbp-28h] BYREF int v8[8]; // [rsp+48h] [rbp-20h] BYREF testing::Message::Message((testing::Message *)v7); v5 = testing::Message::operator<<<char [7]>(v7, "/proc/"); v6[0] = getpid(); v4 = testing::Message::operator<<<int>(v5, v6); v3 = testing::Message::operator<<<char [6]>(v4, "/stat"); testing::Message::GetString[abi:cxx11]((int)v8, v3); testing::Message::~Message((testing::Message *)v7); ProcFile = testing::internal::`anonymous namespace'::ReadProcFileField<unsigned long>(v8, 19LL); std::string::~string(v8); return ProcFile; }
GetThreadCount: SUB RSP,0x68 LEA RDI,[RSP + 0x40] MOV qword ptr [RSP + 0x20],RDI CALL 0x00122e80 MOV RDI,qword ptr [RSP + 0x20] LAB_00115ee8: LEA RSI,[0x174289] CALL 0x00146eb0 MOV qword ptr [RSP + 0x28],RAX JMP 0x00115efb LAB_00115efb: CALL 0x0010b7b0 MOV RDI,qword ptr [RSP + 0x28] MOV dword ptr [RSP + 0x30],EAX LEA RSI,[RSP + 0x30] CALL 0x00146ef0 MOV qword ptr [RSP + 0x18],RAX JMP 0x00115f1a LAB_00115f1a: MOV RDI,qword ptr [RSP + 0x18] LEA RSI,[0x174290] CALL 0x00146f30 MOV qword ptr [RSP + 0x10],RAX JMP 0x00115f32 LAB_00115f32: MOV RSI,qword ptr [RSP + 0x10] LEA RDI,[RSP + 0x48] CALL 0x00114e90 JMP 0x00115f43 LAB_00115f43: LEA RDI,[RSP + 0x40] CALL 0x0010ee50 LAB_00115f4d: LEA RDI,[RSP + 0x48] MOV ESI,0x13 CALL 0x0011acb0 LAB_00115f5c: MOV qword ptr [RSP + 0x8],RAX JMP 0x00115f63 LAB_00115f63: LEA RDI,[RSP + 0x48] CALL 0x0010ec60 MOV RAX,qword ptr [RSP + 0x8] ADD RSP,0x68 RET
/* testing::internal::GetThreadCount() */ ulong testing::internal::GetThreadCount(void) { Message *pMVar1; ulong uVar2; __pid_t local_38 [4]; Message local_28 [8]; string local_20 [32]; Message::Message(local_28); /* try { // try from 00115ee8 to 00115f40 has its CatchHandler @ 00115f77 */ pMVar1 = Message::operator<<(local_28,"/proc/"); local_38[0] = getpid(); pMVar1 = Message::operator<<(pMVar1,local_38); Message::operator<<(pMVar1,"/stat"); Message::GetString_abi_cxx11_(); Message::~Message(local_28); /* try { // try from 00115f4d to 00115f5b has its CatchHandler @ 00115f91 */ uVar2 = (anonymous_namespace)::ReadProcFileField<unsigned_long>(local_20,0x13); std::__cxx11::string::~string(local_20); return uVar2; }
56,806
nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int)
ng-log[P]ng-log/src/vlog_is_on.cc
bool InitializeVLOG3(SiteFlag* site_flag, int32* level_default, const char* fname, int32 verbose_level) { std::lock_guard<std::mutex> l(vmodule_mutex); bool read_vmodule_flag = inited_vmodule; if (!read_vmodule_flag) { VLOG2Initializer(); } // protect the errno global in case someone writes: // VLOG(..) << "The last error was " << strerror(errno) int old_errno = errno; // site_default normally points to FLAGS_v int32* site_flag_value = level_default; // Get basename for file const char* base = strrchr(fname, '/'); #ifdef _WIN32 if (!base) { base = strrchr(fname, '\\'); } #endif base = base ? (base + 1) : fname; const char* base_end = strchr(base, '.'); size_t base_length = base_end ? static_cast<size_t>(base_end - base) : strlen(base); // Trim out trailing "-inl" if any if (base_length >= 4 && (memcmp(base + base_length - 4, "-inl", 4) == 0)) { base_length -= 4; } // TODO: Trim out _unittest suffix? Perhaps it is better to have // the extra control and just leave it there. // find target in vector of modules, replace site_flag_value with // a module-specific verbose level, if any. for (const VModuleInfo* info = vmodule_list; info != nullptr; info = info->next) { if (SafeFNMatch_(info->module_pattern.c_str(), info->module_pattern.size(), base, base_length)) { site_flag_value = &info->vlog_level; // value at info->vlog_level is now what controls // the VLOG at the caller site forever break; } } // Cache the vlog value pointer if --vmodule flag has been parsed. ANNOTATE_BENIGN_RACE(site_flag, "*site_flag may be written by several threads," " but the value will be the same"); if (read_vmodule_flag) { site_flag->level = site_flag_value; // If VLOG flag has been cached to the default site pointer, // we want to add to the cached list in order to invalidate in case // SetVModule is called afterwards with new modules. // The performance penalty here is neglible, because InitializeVLOG3 is // called once per site. if (site_flag_value == level_default && !site_flag->base_name) { site_flag->base_name = base; site_flag->base_len = base_length; site_flag->next = cached_site_list; cached_site_list = site_flag; } } // restore the errno in case something recoverable went wrong during // the initialization of the VLOG mechanism (see above note "protect the..") errno = old_errno; return *site_flag_value >= verbose_level; }
O2
cpp
nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movl %ecx, %ebp movq %rdx, %r14 movq %rsi, %r13 movq %rdi, %r12 leaq 0x21049(%rip), %rdi # 0x3eb70 callq 0x1b7e8 movb 0x21036(%rip), %al # 0x3eb68 movb %al, 0x7(%rsp) testb %al, %al jne 0x1dc56 movq %r14, 0x10(%rsp) movq %r13, 0x18(%rsp) movq %r12, 0x20(%rsp) movl %ebp, 0x8(%rsp) movb $0x0, 0x21010(%rip) # 0x3eb68 leaq 0xfa69(%rip), %rax # 0x2d5c8 movq (%rax), %rax movq (%rax), %r14 leaq 0x28(%rsp), %r13 xorl %ebp, %ebp xorl %r12d, %r12d movq %r14, %rdi pushq $0x3d popq %rsi callq 0x71d0 testq %rax, %rax je 0x1dc22 movq %rax, %r15 leaq 0x38(%rsp), %rax movq %rax, 0x28(%rsp) movq %r13, %rdi movq %r14, %rsi movq %r15, %rdx callq 0x9bda movq %r15, %rdi leaq 0x26ea(%rip), %rsi # 0x20292 leaq 0xc(%rsp), %rdx xorl %eax, %eax callq 0x7570 cmpl $0x1, %eax jne 0x1dbf2 pushq $0x30 popq %rdi callq 0x75b0 movq %rax, %rbx addq $0x10, %rax movq %rax, (%rbx) andq $0x0, 0x8(%rbx) movb $0x0, 0x10(%rbx) movq %rbx, %rdi movq %r13, %rsi callq 0x7300 movl 0xc(%rsp), %eax movl %eax, 0x20(%rbx) testq %rbp, %rbp je 0x1dbf7 movq %rbx, 0x28(%r12) jmp 0x1dbfa movq %r12, %rbx jmp 0x1dbfa movq %rbx, %rbp movq %r15, %rdi pushq $0x2c popq %rsi callq 0x71d0 movq %rax, %r15 leaq 0x1(%rax), %r14 movq %r13, %rdi callq 0x7b58 movq %rbx, %r12 testq %r15, %r15 jne 0x1db6f jmp 0x1dc25 movq %r12, %rbx testq %rbp, %rbp je 0x1dc3c movq 0x20f07(%rip), %rax # 0x3eb38 movq %rax, 0x28(%rbx) movq %rbp, 0x20efc(%rip) # 0x3eb38 movb $0x1, 0x20f25(%rip) # 0x3eb68 movl 0x8(%rsp), %ebp movq 0x20(%rsp), %r12 movq 0x18(%rsp), %r13 movq 0x10(%rsp), %r14 pushq $0x2f popq %rsi movq %r14, %rdi callq 0x7660 leaq 0x1(%rax), %rbx testq %rax, %rax cmoveq %r14, %rbx pushq $0x2e popq %rsi movq %rbx, %rdi callq 0x71d0 testq %rax, %rax je 0x1dc84 movq %rax, %r14 subq %rbx, %r14 jmp 0x1dc8f movq %rbx, %rdi callq 0x7240 movq %rax, %r14 cmpq $0x4, %r14 jb 0x1dca6 leaq -0x4(%r14), %rax cmpl $0x6c6e692d, -0x4(%rbx,%r14) # imm = 0x6C6E692D cmoveq %rax, %r14 leaq 0x20e8b(%rip), %r15 # 0x3eb38 movq (%r15), %r15 testq %r15, %r15 je 0x1dcd1 movq (%r15), %rdi movq 0x8(%r15), %rsi movq %rbx, %rdx movq %r14, %rcx callq 0x1d8a8 testb %al, %al jne 0x1dcd6 addq $0x28, %r15 jmp 0x1dcad movq %r13, %r15 jmp 0x1dcda addq $0x20, %r15 cmpb $0x0, 0x7(%rsp) je 0x1dd0f movq %r15, (%r12) cmpq %r13, %r15 jne 0x1dd0f cmpq $0x0, 0x8(%r12) jne 0x1dd0f movq %rbx, 0x8(%r12) movq %r14, 0x10(%r12) movq 0x20e3d(%rip), %rax # 0x3eb40 movq %rax, 0x18(%r12) movq %r12, 0x20e31(%rip) # 0x3eb40 cmpl %ebp, (%r15) setge %bl leaq 0x20e54(%rip), %rdi # 0x3eb70 callq 0x7450 movl %ebx, %eax addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx leaq 0x28(%rsp), %rdi callq 0x7b58 jmp 0x1dd44 movq %rax, %rbx leaq 0x20e25(%rip), %rdi # 0x3eb70 callq 0x7450 movq %rbx, %rdi callq 0x7a20
_ZN5nglog15InitializeVLOG3EPNS_8SiteFlagEPiPKci: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov ebp, ecx mov r14, rdx mov r13, rsi mov r12, rdi lea rdi, _ZN5nglogL13vmodule_mutexE; this call _ZNSt5mutex4lockEv; std::mutex::lock(void) mov al, cs:_ZN5nglogL14inited_vmoduleE; nglog::inited_vmodule mov [rsp+78h+var_71], al test al, al jnz loc_1DC56 mov [rsp+78h+var_68], r14 mov [rsp+78h+var_60], r13 mov [rsp+78h+var_58], r12 mov [rsp+78h+var_70], ebp mov cs:_ZN5nglogL14inited_vmoduleE, 0; nglog::inited_vmodule lea rax, _ZN3fLS13FLAGS_vmoduleB5cxx11E; fLS::FLAGS_vmodule mov rax, [rax] mov r14, [rax] lea r13, [rsp+78h+var_50] xor ebp, ebp xor r12d, r12d loc_1DB6F: mov rdi, r14 push 3Dh ; '=' pop rsi call _strchr test rax, rax jz loc_1DC22 mov r15, rax lea rax, [rsp+78h+var_40] mov [rsp+78h+var_50], rax mov rdi, r13 mov rsi, r14 mov rdx, 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) mov rdi, r15 lea rsi, aD_0; "=%d" lea rdx, [rsp+78h+var_6C] xor eax, eax call ___isoc99_sscanf cmp eax, 1 jnz short loc_1DBF2 push 30h ; '0' pop rdi; unsigned __int64 call __Znwm; operator new(ulong) mov rbx, rax add rax, 10h mov [rbx], rax and qword ptr [rbx+8], 0 mov byte ptr [rbx+10h], 0 mov rdi, rbx mov rsi, r13 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&) mov eax, [rsp+78h+var_6C] mov [rbx+20h], eax test rbp, rbp jz short loc_1DBF7 mov [r12+28h], rbx jmp short loc_1DBFA loc_1DBF2: mov rbx, r12 jmp short loc_1DBFA loc_1DBF7: mov rbp, rbx loc_1DBFA: mov rdi, r15 push 2Ch ; ',' pop rsi call _strchr mov r15, rax lea r14, [rax+1] mov rdi, r13; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov r12, rbx test r15, r15 jnz loc_1DB6F jmp short loc_1DC25 loc_1DC22: mov rbx, r12 loc_1DC25: test rbp, rbp jz short loc_1DC3C mov rax, cs:_ZN5nglogL12vmodule_listE; nglog::vmodule_list mov [rbx+28h], rax mov cs:_ZN5nglogL12vmodule_listE, rbp; nglog::vmodule_list loc_1DC3C: mov cs:_ZN5nglogL14inited_vmoduleE, 1; nglog::inited_vmodule mov ebp, [rsp+78h+var_70] mov r12, [rsp+78h+var_58] mov r13, [rsp+78h+var_60] mov r14, [rsp+78h+var_68] loc_1DC56: push 2Fh ; '/' pop rsi mov rdi, r14 call _strrchr lea rbx, [rax+1] test rax, rax cmovz rbx, r14 push 2Eh ; '.' pop rsi mov rdi, rbx call _strchr test rax, rax jz short loc_1DC84 mov r14, rax sub r14, rbx jmp short loc_1DC8F loc_1DC84: mov rdi, rbx call _strlen mov r14, rax loc_1DC8F: cmp r14, 4 jb short loc_1DCA6 lea rax, [r14-4] cmp dword ptr [rbx+r14-4], 6C6E692Dh cmovz r14, rax loc_1DCA6: lea r15, _ZN5nglogL12vmodule_listE; nglog::vmodule_list loc_1DCAD: mov r15, [r15] test r15, r15 jz short loc_1DCD1 mov rdi, [r15]; this mov rsi, [r15+8]; char * mov rdx, rbx; unsigned __int64 mov rcx, r14; char * call _ZN5nglog5tools12SafeFNMatch_EPKcmS2_m; nglog::tools::SafeFNMatch_(char const*,ulong,char const*,ulong) test al, al jnz short loc_1DCD6 add r15, 28h ; '(' jmp short loc_1DCAD loc_1DCD1: mov r15, r13 jmp short loc_1DCDA loc_1DCD6: add r15, 20h ; ' ' loc_1DCDA: cmp [rsp+78h+var_71], 0 jz short loc_1DD0F mov [r12], r15 cmp r15, r13 jnz short loc_1DD0F cmp qword ptr [r12+8], 0 jnz short loc_1DD0F mov [r12+8], rbx mov [r12+10h], r14 mov rax, cs:_ZN5nglogL16cached_site_listE; nglog::cached_site_list mov [r12+18h], rax mov cs:_ZN5nglogL16cached_site_listE, r12; nglog::cached_site_list loc_1DD0F: cmp [r15], ebp setnl bl lea rdi, _ZN5nglogL13vmodule_mutexE; nglog::vmodule_mutex call _pthread_mutex_unlock mov eax, ebx add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax lea rdi, [rsp+arg_20]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_1DD44 mov rbx, rax loc_1DD44: lea rdi, _ZN5nglogL13vmodule_mutexE; nglog::vmodule_mutex call _pthread_mutex_unlock mov rdi, rbx call __Unwind_Resume
long long nglog::InitializeVLOG3(_QWORD *a1, _DWORD *a2, long long a3, int a4) { _DWORD *v6; // r13 _QWORD *v7; // r12 _BYTE *v8; // r14 long long v9; // rbp long long v10; // r12 long long v11; // rax long long v12; // r15 long long v13; // rbx long long v14; // r15 long long v15; // rax long long v16; // rbx long long v17; // rax unsigned long long v18; // r8 const char *v19; // r14 long long *i; // r15 long long v21; // r15 _DWORD *v22; // r15 char v24; // [rsp+7h] [rbp-71h] int v25; // [rsp+8h] [rbp-70h] int v26; // [rsp+Ch] [rbp-6Ch] BYREF long long v27; // [rsp+10h] [rbp-68h] _DWORD *v28; // [rsp+18h] [rbp-60h] _QWORD *v29; // [rsp+20h] [rbp-58h] _QWORD v30[2]; // [rsp+28h] [rbp-50h] BYREF char v31; // [rsp+38h] [rbp-40h] BYREF v6 = a2; v7 = a1; std::mutex::lock((std::mutex *)&nglog::vmodule_mutex); v24 = nglog::inited_vmodule; if ( !nglog::inited_vmodule ) { v27 = a3; v28 = a2; v29 = a1; v25 = a4; nglog::inited_vmodule = 0; v8 = (_BYTE *)fLS::FLAGS_vmodule_buf[abi:cxx11]; v9 = 0LL; v10 = 0LL; while ( 1 ) { v11 = strchr(v8, 61LL); if ( !v11 ) break; v12 = v11; v30[0] = &v31; std::string::_M_construct<char const*>((long long)v30, v8, v11); if ( (unsigned int)__isoc99_sscanf(v12, "=%d", &v26) == 1 ) { v13 = operator new(0x30uLL); *(_QWORD *)v13 = v13 + 16; *(_QWORD *)(v13 + 8) = 0LL; *(_BYTE *)(v13 + 16) = 0; std::string::_M_assign(v13, v30); *(_DWORD *)(v13 + 32) = v26; if ( v9 ) *(_QWORD *)(v10 + 40) = v13; else v9 = v13; } else { v13 = v10; } v14 = strchr(v12, 44LL); v8 = (_BYTE *)(v14 + 1); std::string::~string(v30); v10 = v13; if ( !v14 ) goto LABEL_12; } v13 = v10; LABEL_12: if ( v9 ) { *(_QWORD *)(v13 + 40) = nglog::vmodule_list; nglog::vmodule_list = v9; } nglog::inited_vmodule = 1; a4 = v25; v7 = v29; v6 = v28; a3 = v27; } v15 = strrchr(a3, 47LL); v16 = v15 + 1; if ( !v15 ) v16 = a3; v17 = strchr(v16, 46LL); if ( v17 ) v19 = (const char *)(v17 - v16); else v19 = (const char *)strlen(v16); if ( (unsigned long long)v19 >= 4 && *(_DWORD *)&v19[v16 - 4] == 1819175213 ) v19 -= 4; for ( i = &nglog::vmodule_list; ; i = (long long *)(v21 + 40) ) { v21 = *i; if ( !v21 ) { v22 = v6; goto LABEL_29; } if ( nglog::tools::SafeFNMatch_(*(nglog::tools **)v21, *(const char **)(v21 + 8), v16, v19, v18) ) break; } v22 = (_DWORD *)(v21 + 32); LABEL_29: if ( v24 ) { *v7 = v22; if ( v22 == v6 && !v7[1] ) { v7[1] = v16; v7[2] = v19; v7[3] = nglog::cached_site_list; nglog::cached_site_list = (long long)v7; } } LOBYTE(v16) = *v22 >= a4; pthread_mutex_unlock(&nglog::vmodule_mutex); return (unsigned int)v16; }
InitializeVLOG3: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV EBP,ECX MOV R14,RDX MOV R13,RSI MOV R12,RDI LEA RDI,[0x13eb70] CALL 0x0011b7e8 MOV AL,byte ptr [0x0013eb68] MOV byte ptr [RSP + 0x7],AL TEST AL,AL JNZ 0x0011dc56 MOV qword ptr [RSP + 0x10],R14 MOV qword ptr [RSP + 0x18],R13 MOV qword ptr [RSP + 0x20],R12 MOV dword ptr [RSP + 0x8],EBP MOV byte ptr [0x0013eb68],0x0 LEA RAX,[0x12d5c8] MOV RAX,qword ptr [RAX] MOV R14,qword ptr [RAX] LEA R13,[RSP + 0x28] XOR EBP,EBP XOR R12D,R12D LAB_0011db6f: MOV RDI,R14 PUSH 0x3d POP RSI CALL 0x001071d0 TEST RAX,RAX JZ 0x0011dc22 MOV R15,RAX LEA RAX,[RSP + 0x38] MOV qword ptr [RSP + 0x28],RAX LAB_0011db90: MOV RDI,R13 MOV RSI,R14 MOV RDX,R15 CALL 0x00109bda MOV RDI,R15 LEA RSI,[0x120292] LEA RDX,[RSP + 0xc] XOR EAX,EAX CALL 0x00107570 CMP EAX,0x1 JNZ 0x0011dbf2 LAB_0011dbb9: PUSH 0x30 POP RDI CALL 0x001075b0 MOV RBX,RAX ADD RAX,0x10 MOV qword ptr [RBX],RAX AND qword ptr [RBX + 0x8],0x0 MOV byte ptr [RBX + 0x10],0x0 MOV RDI,RBX MOV RSI,R13 CALL 0x00107300 LAB_0011dbdf: MOV EAX,dword ptr [RSP + 0xc] MOV dword ptr [RBX + 0x20],EAX TEST RBP,RBP JZ 0x0011dbf7 MOV qword ptr [R12 + 0x28],RBX JMP 0x0011dbfa LAB_0011dbf2: MOV RBX,R12 JMP 0x0011dbfa LAB_0011dbf7: MOV RBP,RBX LAB_0011dbfa: MOV RDI,R15 PUSH 0x2c POP RSI CALL 0x001071d0 MOV R15,RAX LEA R14,[RAX + 0x1] MOV RDI,R13 CALL 0x00107b58 MOV R12,RBX TEST R15,R15 JNZ 0x0011db6f JMP 0x0011dc25 LAB_0011dc22: MOV RBX,R12 LAB_0011dc25: TEST RBP,RBP JZ 0x0011dc3c MOV RAX,qword ptr [0x0013eb38] MOV qword ptr [RBX + 0x28],RAX MOV qword ptr [0x0013eb38],RBP LAB_0011dc3c: MOV byte ptr [0x0013eb68],0x1 MOV EBP,dword ptr [RSP + 0x8] MOV R12,qword ptr [RSP + 0x20] MOV R13,qword ptr [RSP + 0x18] MOV R14,qword ptr [RSP + 0x10] LAB_0011dc56: PUSH 0x2f POP RSI MOV RDI,R14 CALL 0x00107660 LEA RBX,[RAX + 0x1] TEST RAX,RAX CMOVZ RBX,R14 PUSH 0x2e POP RSI MOV RDI,RBX CALL 0x001071d0 TEST RAX,RAX JZ 0x0011dc84 MOV R14,RAX SUB R14,RBX JMP 0x0011dc8f LAB_0011dc84: MOV RDI,RBX CALL 0x00107240 MOV R14,RAX LAB_0011dc8f: CMP R14,0x4 JC 0x0011dca6 LEA RAX,[R14 + -0x4] CMP dword ptr [RBX + R14*0x1 + -0x4],0x6c6e692d CMOVZ R14,RAX LAB_0011dca6: LEA R15,[0x13eb38] LAB_0011dcad: MOV R15,qword ptr [R15] TEST R15,R15 JZ 0x0011dcd1 MOV RDI,qword ptr [R15] MOV RSI,qword ptr [R15 + 0x8] MOV RDX,RBX MOV RCX,R14 CALL 0x0011d8a8 TEST AL,AL JNZ 0x0011dcd6 ADD R15,0x28 JMP 0x0011dcad LAB_0011dcd1: MOV R15,R13 JMP 0x0011dcda LAB_0011dcd6: ADD R15,0x20 LAB_0011dcda: CMP byte ptr [RSP + 0x7],0x0 JZ 0x0011dd0f MOV qword ptr [R12],R15 CMP R15,R13 JNZ 0x0011dd0f CMP qword ptr [R12 + 0x8],0x0 JNZ 0x0011dd0f MOV qword ptr [R12 + 0x8],RBX MOV qword ptr [R12 + 0x10],R14 MOV RAX,qword ptr [0x0013eb40] MOV qword ptr [R12 + 0x18],RAX MOV qword ptr [0x0013eb40],R12 LAB_0011dd0f: CMP dword ptr [R15],EBP SETGE BL LEA RDI,[0x13eb70] CALL 0x00107450 MOV EAX,EBX ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int) */ ulong nglog::InitializeVLOG3(SiteFlag *param_1,int *param_2,char *param_3,int param_4) { int8 *puVar1; char cVar2; char cVar3; int iVar4; char *pcVar5; string *psVar6; char *pcVar7; string *psVar8; string *psVar9; string *psVar10; ulong uVar11; long *plVar12; int *piVar13; int4 local_6c; char *local_68; int *local_60; SiteFlag *local_58; int1 *local_50 [2]; int1 local_40 [16]; std::mutex::lock((mutex *)vmodule_mutex); cVar2 = inited_vmodule; if (inited_vmodule == '\0') { inited_vmodule = 0; pcVar7 = *(char **)fLS::FLAGS_vmodule_abi_cxx11_; psVar8 = (string *)0x0; psVar10 = (string *)0x0; local_68 = param_3; local_60 = param_2; local_58 = param_1; do { pcVar5 = strchr(pcVar7,0x3d); psVar6 = psVar10; psVar9 = psVar8; if (pcVar5 == (char *)0x0) break; local_50[0] = local_40; /* try { // try from 0011db90 to 0011db9d has its CatchHandler @ 0011dd41 */ std::__cxx11::string::_M_construct<char_const*>((string *)local_50,pcVar7,pcVar5); iVar4 = __isoc99_sscanf(pcVar5,&DAT_00120292,&local_6c); if (iVar4 == 1) { /* try { // try from 0011dbb9 to 0011dbde has its CatchHandler @ 0011dd32 */ psVar6 = (string *)operator_new(0x30); *(string **)psVar6 = psVar6 + 0x10; *(int8 *)(psVar6 + 8) = 0; psVar6[0x10] = (string)0x0; std::__cxx11::string::_M_assign(psVar6); *(int4 *)(psVar6 + 0x20) = local_6c; psVar9 = psVar6; if (psVar8 != (string *)0x0) { *(string **)(psVar10 + 0x28) = psVar6; psVar9 = psVar8; } } pcVar5 = strchr(pcVar5,0x2c); pcVar7 = pcVar5 + 1; std::__cxx11::string::~string((string *)local_50); psVar8 = psVar9; psVar10 = psVar6; } while (pcVar5 != (char *)0x0); if (psVar9 != (string *)0x0) { *(string **)(psVar6 + 0x28) = vmodule_list; vmodule_list = psVar9; } inited_vmodule = '\x01'; param_1 = local_58; param_2 = local_60; param_3 = local_68; } pcVar5 = strrchr(param_3,0x2f); pcVar7 = pcVar5 + 1; if (pcVar5 == (char *)0x0) { pcVar7 = param_3; } pcVar5 = strchr(pcVar7,0x2e); if (pcVar5 == (char *)0x0) { uVar11 = strlen(pcVar7); } else { uVar11 = (long)pcVar5 - (long)pcVar7; } if ((3 < uVar11) && (*(int *)(pcVar7 + (uVar11 - 4)) == 0x6c6e692d)) { uVar11 = uVar11 - 4; } plVar12 = (long *)&vmodule_list; do { puVar1 = (int8 *)*plVar12; piVar13 = param_2; if (puVar1 == (int8 *)0x0) { LAB_0011dcda: if (((cVar2 != '\0') && (*(int **)param_1 = piVar13, piVar13 == param_2)) && (*(long *)(param_1 + 8) == 0)) { *(char **)(param_1 + 8) = pcVar7; *(ulong *)(param_1 + 0x10) = uVar11; *(SiteFlag **)(param_1 + 0x18) = cached_site_list; cached_site_list = param_1; } iVar4 = *piVar13; pthread_mutex_unlock((pthread_mutex_t *)vmodule_mutex); return CONCAT71((int7)((ulong)pcVar7 >> 8),param_4 <= iVar4) & 0xffffffff; } cVar3 = tools::SafeFNMatch_((char *)*puVar1,puVar1[1],pcVar7,uVar11); if (cVar3 != '\0') { piVar13 = (int *)(puVar1 + 4); goto LAB_0011dcda; } plVar12 = puVar1 + 5; } while( true ); }
56,807
nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int)
ng-log[P]ng-log/src/vlog_is_on.cc
bool InitializeVLOG3(SiteFlag* site_flag, int32* level_default, const char* fname, int32 verbose_level) { std::lock_guard<std::mutex> l(vmodule_mutex); bool read_vmodule_flag = inited_vmodule; if (!read_vmodule_flag) { VLOG2Initializer(); } // protect the errno global in case someone writes: // VLOG(..) << "The last error was " << strerror(errno) int old_errno = errno; // site_default normally points to FLAGS_v int32* site_flag_value = level_default; // Get basename for file const char* base = strrchr(fname, '/'); #ifdef _WIN32 if (!base) { base = strrchr(fname, '\\'); } #endif base = base ? (base + 1) : fname; const char* base_end = strchr(base, '.'); size_t base_length = base_end ? static_cast<size_t>(base_end - base) : strlen(base); // Trim out trailing "-inl" if any if (base_length >= 4 && (memcmp(base + base_length - 4, "-inl", 4) == 0)) { base_length -= 4; } // TODO: Trim out _unittest suffix? Perhaps it is better to have // the extra control and just leave it there. // find target in vector of modules, replace site_flag_value with // a module-specific verbose level, if any. for (const VModuleInfo* info = vmodule_list; info != nullptr; info = info->next) { if (SafeFNMatch_(info->module_pattern.c_str(), info->module_pattern.size(), base, base_length)) { site_flag_value = &info->vlog_level; // value at info->vlog_level is now what controls // the VLOG at the caller site forever break; } } // Cache the vlog value pointer if --vmodule flag has been parsed. ANNOTATE_BENIGN_RACE(site_flag, "*site_flag may be written by several threads," " but the value will be the same"); if (read_vmodule_flag) { site_flag->level = site_flag_value; // If VLOG flag has been cached to the default site pointer, // we want to add to the cached list in order to invalidate in case // SetVModule is called afterwards with new modules. // The performance penalty here is neglible, because InitializeVLOG3 is // called once per site. if (site_flag_value == level_default && !site_flag->base_name) { site_flag->base_name = base; site_flag->base_len = base_length; site_flag->next = cached_site_list; cached_site_list = site_flag; } } // restore the errno in case something recoverable went wrong during // the initialization of the VLOG mechanism (see above note "protect the..") errno = old_errno; return *site_flag_value >= verbose_level; }
O3
cpp
nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movl %ecx, %ebp movq %rdx, %r14 movq %rsi, %r13 movq %rdi, %r15 leaq 0x1ea8f(%rip), %rdi # 0x40b10 callq 0x7820 testl %eax, %eax jne 0x222a7 movb 0x1ea74(%rip), %al # 0x40b08 movb %al, 0x7(%rsp) testb %al, %al jne 0x221c6 movq %r14, 0x10(%rsp) movq %r13, 0x18(%rsp) movq %r15, 0x20(%rsp) movl %ebp, 0x8(%rsp) movb $0x0, 0x1ea4e(%rip) # 0x40b08 leaq 0xd4f7(%rip), %rax # 0x2f5b8 movq (%rax), %rax movq (%rax), %r15 leaq 0x38(%rsp), %r12 leaq 0x28(%rsp), %r13 xorl %ebp, %ebp xorl %ebx, %ebx movq %r15, %rdi movl $0x3d, %esi callq 0x71b0 testq %rax, %rax je 0x22195 movq %rax, %r14 movq %r12, 0x28(%rsp) movq %r13, %rdi movq %r15, %rsi movq %rax, %rdx callq 0x9f14 movq %r14, %rdi leaq 0x316f(%rip), %rsi # 0x2527a leaq 0xc(%rsp), %rdx xorl %eax, %eax callq 0x7500 cmpl $0x1, %eax jne 0x22161 movl $0x30, %edi callq 0x7530 movq %rax, %r15 addq $0x10, %rax movq %rax, (%r15) movq $0x0, 0x8(%r15) movb $0x0, 0x10(%r15) movq %r15, %rdi movq %r13, %rsi callq 0x72a0 movl 0xc(%rsp), %eax movl %eax, 0x20(%r15) testq %rbp, %rbp je 0x2215b movq %r15, 0x28(%rbx) jmp 0x2215e movq %r15, %rbp movq %r15, %rbx movq %r14, %rdi movl $0x2c, %esi callq 0x71b0 movq %rax, %r14 movq 0x28(%rsp), %rdi cmpq %r12, %rdi je 0x22188 movq 0x38(%rsp), %rsi incq %rsi callq 0x7540 leaq 0x1(%r14), %r15 testq %r14, %r14 jne 0x220d5 testq %rbp, %rbp je 0x221ac movq 0x1e937(%rip), %rax # 0x40ad8 movq %rax, 0x28(%rbx) movq %rbp, 0x1e92c(%rip) # 0x40ad8 movb $0x1, 0x1e955(%rip) # 0x40b08 movl 0x8(%rsp), %ebp movq 0x20(%rsp), %r15 movq 0x18(%rsp), %r13 movq 0x10(%rsp), %r14 movq %r14, %rdi movl $0x2f, %esi callq 0x75d0 leaq 0x1(%rax), %rbx testq %rax, %rax cmoveq %r14, %rbx movq %rbx, %rdi movl $0x2e, %esi callq 0x71b0 testq %rax, %rax je 0x221f8 movq %rax, %r12 subq %rbx, %r12 jmp 0x22203 movq %rbx, %rdi callq 0x7200 movq %rax, %r12 cmpq $0x4, %r12 jb 0x2221b leaq -0x4(%r12), %rax cmpl $0x6c6e692d, -0x4(%rbx,%r12) # imm = 0x6C6E692D cmoveq %rax, %r12 movq 0x1e8b6(%rip), %r14 # 0x40ad8 movq %r13, %rax testq %r14, %r14 je 0x22255 movq (%r14), %rdi movq 0x8(%r14), %rsi movq %rbx, %rdx movq %r12, %rcx callq 0x21dd0 testb %al, %al jne 0x2224e movq 0x28(%r14), %r14 testq %r14, %r14 jne 0x2222a movq %r13, %rax jmp 0x22255 addq $0x20, %r14 movq %r14, %rax cmpb $0x0, 0x7(%rsp) je 0x22285 movq %rax, (%r15) cmpq %r13, %rax jne 0x22285 cmpq $0x0, 0x8(%r15) jne 0x22285 movq %rbx, 0x8(%r15) movq %r12, 0x10(%r15) movq 0x1e866(%rip), %rcx # 0x40ae0 movq %rcx, 0x18(%r15) movq %r15, 0x1e85b(%rip) # 0x40ae0 cmpl %ebp, (%rax) setge %bl leaq 0x1e87f(%rip), %rdi # 0x40b10 callq 0x73e0 movl %ebx, %eax addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl %eax, %edi callq 0x7350 movq %rax, %rbx movq 0x28(%rsp), %rdi cmpq %r12, %rdi je 0x222cd movq 0x38(%rsp), %rsi incq %rsi callq 0x7540 jmp 0x222cd movq %rax, %rbx leaq 0x1e83c(%rip), %rdi # 0x40b10 callq 0x73e0 movq %rbx, %rdi callq 0x7990
_ZN5nglog15InitializeVLOG3EPNS_8SiteFlagEPiPKci: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov ebp, ecx mov r14, rdx mov r13, rsi mov r15, rdi lea rdi, _ZN5nglogL13vmodule_mutexE; nglog::vmodule_mutex call _pthread_mutex_lock test eax, eax jnz loc_222A7 mov al, cs:_ZN5nglogL14inited_vmoduleE; nglog::inited_vmodule mov [rsp+78h+var_71], al test al, al jnz loc_221C6 mov [rsp+78h+var_68], r14 mov [rsp+78h+var_60], r13 mov [rsp+78h+var_58], r15 mov [rsp+78h+var_70], ebp mov cs:_ZN5nglogL14inited_vmoduleE, 0; nglog::inited_vmodule lea rax, _ZN3fLS13FLAGS_vmoduleB5cxx11E; fLS::FLAGS_vmodule mov rax, [rax] mov r15, [rax] lea r12, [rsp+78h+var_40] lea r13, [rsp+78h+var_50] xor ebp, ebp xor ebx, ebx loc_220D5: mov rdi, r15 mov esi, 3Dh ; '=' call _strchr test rax, rax jz loc_22195 mov r14, rax mov [rsp+78h+var_50], r12 mov rdi, r13 mov rsi, r15 mov rdx, rax call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) mov rdi, r14 lea rsi, aD_0; "=%d" lea rdx, [rsp+78h+var_6C] xor eax, eax call ___isoc99_sscanf cmp eax, 1 jnz short loc_22161 mov edi, 30h ; '0'; unsigned __int64 call __Znwm; operator new(ulong) mov r15, rax add rax, 10h mov [r15], rax mov qword ptr [r15+8], 0 mov byte ptr [r15+10h], 0 mov rdi, r15 mov rsi, r13 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&) mov eax, [rsp+78h+var_6C] mov [r15+20h], eax test rbp, rbp jz short loc_2215B mov [rbx+28h], r15 jmp short loc_2215E loc_2215B: mov rbp, r15 loc_2215E: mov rbx, r15 loc_22161: mov rdi, r14 mov esi, 2Ch ; ',' call _strchr mov r14, rax mov rdi, [rsp+78h+var_50]; void * cmp rdi, r12 jz short loc_22188 mov rsi, [rsp+78h+var_40] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_22188: lea r15, [r14+1] test r14, r14 jnz loc_220D5 loc_22195: test rbp, rbp jz short loc_221AC mov rax, cs:_ZN5nglogL12vmodule_listE; nglog::vmodule_list mov [rbx+28h], rax mov cs:_ZN5nglogL12vmodule_listE, rbp; nglog::vmodule_list loc_221AC: mov cs:_ZN5nglogL14inited_vmoduleE, 1; nglog::inited_vmodule mov ebp, [rsp+78h+var_70] mov r15, [rsp+78h+var_58] mov r13, [rsp+78h+var_60] mov r14, [rsp+78h+var_68] loc_221C6: mov rdi, r14 mov esi, 2Fh ; '/' call _strrchr lea rbx, [rax+1] test rax, rax cmovz rbx, r14 mov rdi, rbx mov esi, 2Eh ; '.' call _strchr test rax, rax jz short loc_221F8 mov r12, rax sub r12, rbx jmp short loc_22203 loc_221F8: mov rdi, rbx call _strlen mov r12, rax loc_22203: cmp r12, 4 jb short loc_2221B lea rax, [r12-4] cmp dword ptr [rbx+r12-4], 6C6E692Dh cmovz r12, rax loc_2221B: mov r14, cs:_ZN5nglogL12vmodule_listE; nglog::vmodule_list mov rax, r13 test r14, r14 jz short loc_22255 loc_2222A: mov rdi, [r14]; this mov rsi, [r14+8]; char * mov rdx, rbx; unsigned __int64 mov rcx, r12; char * call _ZN5nglog5tools12SafeFNMatch_EPKcmS2_m; nglog::tools::SafeFNMatch_(char const*,ulong,char const*,ulong) test al, al jnz short loc_2224E mov r14, [r14+28h] test r14, r14 jnz short loc_2222A mov rax, r13 jmp short loc_22255 loc_2224E: add r14, 20h ; ' ' mov rax, r14 loc_22255: cmp [rsp+78h+var_71], 0 jz short loc_22285 mov [r15], rax cmp rax, r13 jnz short loc_22285 cmp qword ptr [r15+8], 0 jnz short loc_22285 mov [r15+8], rbx mov [r15+10h], r12 mov rcx, cs:_ZN5nglogL16cached_site_listE; nglog::cached_site_list mov [r15+18h], rcx mov cs:_ZN5nglogL16cached_site_listE, r15; nglog::cached_site_list loc_22285: cmp [rax], ebp setnl bl lea rdi, _ZN5nglogL13vmodule_mutexE; nglog::vmodule_mutex call _pthread_mutex_unlock mov eax, ebx add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_222A7: mov edi, eax; int call __ZSt20__throw_system_errori; std::__throw_system_error(int) mov rbx, rax mov rdi, [rsp+78h+var_50]; void * cmp rdi, r12 jz short loc_222CD mov rsi, [rsp+78h+var_40] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_222CD mov rbx, rax loc_222CD: lea rdi, _ZN5nglogL13vmodule_mutexE; nglog::vmodule_mutex call _pthread_mutex_unlock mov rdi, rbx call __Unwind_Resume
long long nglog::InitializeVLOG3(_QWORD *a1, _DWORD *a2, long long a3, int a4) { _DWORD *v6; // r13 _QWORD *v7; // r15 int v8; // eax _BYTE *v9; // r15 long long v10; // rbp long long v11; // rbx long long v12; // rax long long v13; // r14 long long v14; // r15 long long v15; // r14 long long v16; // rax long long v17; // rbx long long v18; // rax unsigned long long v19; // r8 const char *v20; // r12 long long v21; // r14 _DWORD *v22; // rax char v24; // [rsp+7h] [rbp-71h] int v25; // [rsp+8h] [rbp-70h] int v26; // [rsp+Ch] [rbp-6Ch] BYREF long long v27; // [rsp+10h] [rbp-68h] _DWORD *v28; // [rsp+18h] [rbp-60h] _QWORD *v29; // [rsp+20h] [rbp-58h] void *v30[2]; // [rsp+28h] [rbp-50h] BYREF _QWORD v31[8]; // [rsp+38h] [rbp-40h] BYREF v6 = a2; v7 = a1; v8 = pthread_mutex_lock(&nglog::vmodule_mutex); if ( v8 ) std::__throw_system_error(v8); v24 = nglog::inited_vmodule; if ( !nglog::inited_vmodule ) { v27 = a3; v28 = a2; v29 = a1; v25 = a4; nglog::inited_vmodule = 0; v9 = (_BYTE *)fLS::FLAGS_vmodule_buf[abi:cxx11]; v10 = 0LL; v11 = 0LL; do { v12 = strchr(v9, 61LL); if ( !v12 ) break; v13 = v12; v30[0] = v31; std::string::_M_construct<char const*>((long long)v30, v9, v12); if ( (unsigned int)__isoc99_sscanf(v13, "=%d", &v26) == 1 ) { v14 = operator new(0x30uLL); *(_QWORD *)v14 = v14 + 16; *(_QWORD *)(v14 + 8) = 0LL; *(_BYTE *)(v14 + 16) = 0; std::string::_M_assign(v14, v30); *(_DWORD *)(v14 + 32) = v26; if ( v10 ) *(_QWORD *)(v11 + 40) = v14; else v10 = v14; v11 = v14; } v15 = strchr(v13, 44LL); if ( v30[0] != v31 ) operator delete(v30[0], v31[0] + 1LL); v9 = (_BYTE *)(v15 + 1); } while ( v15 ); if ( v10 ) { *(_QWORD *)(v11 + 40) = nglog::vmodule_list; nglog::vmodule_list = v10; } nglog::inited_vmodule = 1; a4 = v25; v7 = v29; v6 = v28; a3 = v27; } v16 = strrchr(a3, 47LL); v17 = v16 + 1; if ( !v16 ) v17 = a3; v18 = strchr(v17, 46LL); if ( v18 ) v20 = (const char *)(v18 - v17); else v20 = (const char *)strlen(v17); if ( (unsigned long long)v20 >= 4 && *(_DWORD *)&v20[v17 - 4] == 1819175213 ) v20 -= 4; v21 = nglog::vmodule_list; v22 = v6; if ( nglog::vmodule_list ) { while ( !nglog::tools::SafeFNMatch_(*(nglog::tools **)v21, *(const char **)(v21 + 8), v17, v20, v19) ) { v21 = *(_QWORD *)(v21 + 40); if ( !v21 ) { v22 = v6; goto LABEL_29; } } v22 = (_DWORD *)(v21 + 32); } LABEL_29: if ( v24 ) { *v7 = v22; if ( v22 == v6 && !v7[1] ) { v7[1] = v17; v7[2] = v20; v7[3] = nglog::cached_site_list; nglog::cached_site_list = (long long)v7; } } LOBYTE(v17) = *v22 >= a4; pthread_mutex_unlock(&nglog::vmodule_mutex); return (unsigned int)v17; }
InitializeVLOG3: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV EBP,ECX MOV R14,RDX MOV R13,RSI MOV R15,RDI LEA RDI,[0x140b10] CALL 0x00107820 TEST EAX,EAX JNZ 0x001222a7 MOV AL,byte ptr [0x00140b08] MOV byte ptr [RSP + 0x7],AL TEST AL,AL JNZ 0x001221c6 MOV qword ptr [RSP + 0x10],R14 MOV qword ptr [RSP + 0x18],R13 MOV qword ptr [RSP + 0x20],R15 MOV dword ptr [RSP + 0x8],EBP MOV byte ptr [0x00140b08],0x0 LEA RAX,[0x12f5b8] MOV RAX,qword ptr [RAX] MOV R15,qword ptr [RAX] LEA R12,[RSP + 0x38] LEA R13,[RSP + 0x28] XOR EBP,EBP XOR EBX,EBX LAB_001220d5: MOV RDI,R15 MOV ESI,0x3d CALL 0x001071b0 TEST RAX,RAX JZ 0x00122195 MOV R14,RAX MOV qword ptr [RSP + 0x28],R12 LAB_001220f3: MOV RDI,R13 MOV RSI,R15 MOV RDX,RAX CALL 0x00109f14 MOV RDI,R14 LEA RSI,[0x12527a] LEA RDX,[RSP + 0xc] XOR EAX,EAX CALL 0x00107500 CMP EAX,0x1 JNZ 0x00122161 LAB_0012211c: MOV EDI,0x30 CALL 0x00107530 MOV R15,RAX ADD RAX,0x10 MOV qword ptr [R15],RAX MOV qword ptr [R15 + 0x8],0x0 MOV byte ptr [R15 + 0x10],0x0 MOV RDI,R15 MOV RSI,R13 CALL 0x001072a0 LAB_00122148: MOV EAX,dword ptr [RSP + 0xc] MOV dword ptr [R15 + 0x20],EAX TEST RBP,RBP JZ 0x0012215b MOV qword ptr [RBX + 0x28],R15 JMP 0x0012215e LAB_0012215b: MOV RBP,R15 LAB_0012215e: MOV RBX,R15 LAB_00122161: MOV RDI,R14 MOV ESI,0x2c CALL 0x001071b0 MOV R14,RAX MOV RDI,qword ptr [RSP + 0x28] CMP RDI,R12 JZ 0x00122188 MOV RSI,qword ptr [RSP + 0x38] INC RSI CALL 0x00107540 LAB_00122188: LEA R15,[R14 + 0x1] TEST R14,R14 JNZ 0x001220d5 LAB_00122195: TEST RBP,RBP JZ 0x001221ac MOV RAX,qword ptr [0x00140ad8] MOV qword ptr [RBX + 0x28],RAX MOV qword ptr [0x00140ad8],RBP LAB_001221ac: MOV byte ptr [0x00140b08],0x1 MOV EBP,dword ptr [RSP + 0x8] MOV R15,qword ptr [RSP + 0x20] MOV R13,qword ptr [RSP + 0x18] MOV R14,qword ptr [RSP + 0x10] LAB_001221c6: MOV RDI,R14 MOV ESI,0x2f CALL 0x001075d0 LEA RBX,[RAX + 0x1] TEST RAX,RAX CMOVZ RBX,R14 MOV RDI,RBX MOV ESI,0x2e CALL 0x001071b0 TEST RAX,RAX JZ 0x001221f8 MOV R12,RAX SUB R12,RBX JMP 0x00122203 LAB_001221f8: MOV RDI,RBX CALL 0x00107200 MOV R12,RAX LAB_00122203: CMP R12,0x4 JC 0x0012221b LEA RAX,[R12 + -0x4] CMP dword ptr [RBX + R12*0x1 + -0x4],0x6c6e692d CMOVZ R12,RAX LAB_0012221b: MOV R14,qword ptr [0x00140ad8] MOV RAX,R13 TEST R14,R14 JZ 0x00122255 LAB_0012222a: MOV RDI,qword ptr [R14] MOV RSI,qword ptr [R14 + 0x8] MOV RDX,RBX MOV RCX,R12 CALL 0x00121dd0 TEST AL,AL JNZ 0x0012224e MOV R14,qword ptr [R14 + 0x28] TEST R14,R14 JNZ 0x0012222a MOV RAX,R13 JMP 0x00122255 LAB_0012224e: ADD R14,0x20 MOV RAX,R14 LAB_00122255: CMP byte ptr [RSP + 0x7],0x0 JZ 0x00122285 MOV qword ptr [R15],RAX CMP RAX,R13 JNZ 0x00122285 CMP qword ptr [R15 + 0x8],0x0 JNZ 0x00122285 MOV qword ptr [R15 + 0x8],RBX MOV qword ptr [R15 + 0x10],R12 MOV RCX,qword ptr [0x00140ae0] MOV qword ptr [R15 + 0x18],RCX MOV qword ptr [0x00140ae0],R15 LAB_00122285: CMP dword ptr [RAX],EBP SETGE BL LEA RDI,[0x140b10] CALL 0x001073e0 MOV EAX,EBX ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001222a7: MOV EDI,EAX CALL 0x00107350
/* nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int) */ ulong nglog::InitializeVLOG3(SiteFlag *param_1,int *param_2,char *param_3,int param_4) { char cVar1; char cVar2; int iVar3; char *pcVar4; string *psVar5; string *psVar6; char *pcVar7; string *psVar8; ulong uVar9; string *psVar10; int4 local_6c; char *local_68; string *local_60; SiteFlag *local_58; long *local_50 [2]; long local_40 [2]; iVar3 = pthread_mutex_lock((pthread_mutex_t *)vmodule_mutex); cVar1 = inited_vmodule; if (iVar3 != 0) { /* WARNING: Subroutine does not return */ std::__throw_system_error(iVar3); } if (inited_vmodule == '\0') { inited_vmodule = 0; pcVar7 = *(char **)fLS::FLAGS_vmodule_abi_cxx11_; psVar6 = (string *)0x0; psVar10 = (string *)0x0; local_68 = param_3; local_60 = (string *)param_2; local_58 = param_1; do { pcVar4 = strchr(pcVar7,0x3d); psVar5 = psVar6; psVar8 = psVar10; if (pcVar4 == (char *)0x0) break; local_50[0] = local_40; /* try { // try from 001220f3 to 00122100 has its CatchHandler @ 001222ca */ std::__cxx11::string::_M_construct<char_const*>(local_50,pcVar7,pcVar4); iVar3 = __isoc99_sscanf(pcVar4,&DAT_0012527a,&local_6c); if (iVar3 == 1) { /* try { // try from 0012211c to 00122147 has its CatchHandler @ 001222ae */ psVar5 = (string *)operator_new(0x30); *(string **)psVar5 = psVar5 + 0x10; *(int8 *)(psVar5 + 8) = 0; psVar5[0x10] = (string)0x0; std::__cxx11::string::_M_assign(psVar5); *(int4 *)(psVar5 + 0x20) = local_6c; psVar8 = psVar5; if (psVar10 != (string *)0x0) { *(string **)(psVar6 + 0x28) = psVar5; psVar8 = psVar10; } } pcVar4 = strchr(pcVar4,0x2c); if (local_50[0] != local_40) { operator_delete(local_50[0],local_40[0] + 1); } pcVar7 = pcVar4 + 1; psVar6 = psVar5; psVar10 = psVar8; } while (pcVar4 != (char *)0x0); if (psVar8 != (string *)0x0) { *(string **)(psVar5 + 0x28) = vmodule_list; vmodule_list = psVar8; } inited_vmodule = '\x01'; param_2 = (int *)local_60; param_3 = local_68; param_1 = local_58; } pcVar4 = strrchr(param_3,0x2f); pcVar7 = pcVar4 + 1; if (pcVar4 == (char *)0x0) { pcVar7 = param_3; } pcVar4 = strchr(pcVar7,0x2e); if (pcVar4 == (char *)0x0) { uVar9 = strlen(pcVar7); } else { uVar9 = (long)pcVar4 - (long)pcVar7; } psVar6 = vmodule_list; if ((3 < uVar9) && (*(int *)(pcVar7 + (uVar9 - 4)) == 0x6c6e692d)) { uVar9 = uVar9 - 4; } do { psVar10 = (string *)param_2; if (psVar6 == (string *)0x0) { LAB_00122255: if (((cVar1 != '\0') && (*(string **)param_1 = psVar10, psVar10 == (string *)param_2)) && (*(long *)(param_1 + 8) == 0)) { *(char **)(param_1 + 8) = pcVar7; *(ulong *)(param_1 + 0x10) = uVar9; *(SiteFlag **)(param_1 + 0x18) = cached_site_list; cached_site_list = param_1; } iVar3 = *(int *)psVar10; pthread_mutex_unlock((pthread_mutex_t *)vmodule_mutex); return CONCAT71((int7)((ulong)pcVar7 >> 8),param_4 <= iVar3) & 0xffffffff; } cVar2 = tools::SafeFNMatch_(*(char **)psVar6,*(ulong *)(psVar6 + 8),pcVar7,uVar9); if (cVar2 != '\0') { psVar10 = psVar6 + 0x20; goto LAB_00122255; } psVar6 = *(string **)(psVar6 + 0x28); } while( true ); }
56,808
my_safe_printf_stderr
eloqsql/mysys/stacktrace.c
size_t my_safe_printf_stderr(const char* fmt, ...) { char to[512]; size_t result; va_list args; va_start(args,fmt); result= my_vsnprintf(to, sizeof(to), fmt, args); va_end(args); my_write_stderr(to, result); return result; }
O3
c
my_safe_printf_stderr: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx subq $0x2e0, %rsp # imm = 0x2E0 movq %rdi, %r10 leaq -0x2f0(%rbp), %rdi movq %rsi, 0x8(%rdi) movq %rdx, 0x10(%rdi) movq %rcx, 0x18(%rdi) movq %r8, 0x20(%rdi) movq %r9, 0x28(%rdi) testb %al, %al je 0x26c90 movaps %xmm0, -0x2c0(%rbp) movaps %xmm1, -0x2b0(%rbp) movaps %xmm2, -0x2a0(%rbp) movaps %xmm3, -0x290(%rbp) movaps %xmm4, -0x280(%rbp) movaps %xmm5, -0x270(%rbp) movaps %xmm6, -0x260(%rbp) movaps %xmm7, -0x250(%rbp) movq %fs:0x28, %rax movq %rax, -0x18(%rbp) leaq -0x240(%rbp), %rcx movq %rdi, 0x10(%rcx) leaq 0x10(%rbp), %rax movq %rax, 0x8(%rcx) movabsq $0x3000000008, %rax # imm = 0x3000000008 movq %rax, (%rcx) leaq -0x220(%rbp), %r14 movl $0x200, %esi # imm = 0x200 movq %r14, %rdi movq %r10, %rdx callq 0x5a2f9 movq %rax, %rbx movq 0x2c82f2(%rip), %rax # 0x2eefd0 movq (%rax), %rdi callq 0x24350 movl %ebx, %edx movl %eax, %edi movq %r14, %rsi callq 0x24120 movq %fs:0x28, %rax cmpq -0x18(%rbp), %rax jne 0x26d10 movq %rbx, %rax addq $0x2e0, %rsp # imm = 0x2E0 popq %rbx popq %r14 popq %rbp retq callq 0x24390
my_safe_printf_stderr: push rbp mov rbp, rsp push r14 push rbx sub rsp, 2E0h mov r10, rdi lea rdi, [rbp+var_2F0] mov [rdi+8], rsi mov [rdi+10h], rdx mov [rdi+18h], rcx mov [rdi+20h], r8 mov [rdi+28h], r9 test al, al jz short loc_26C90 movaps [rbp+var_2C0], xmm0 movaps [rbp+var_2B0], xmm1 movaps [rbp+var_2A0], xmm2 movaps [rbp+var_290], xmm3 movaps [rbp+var_280], xmm4 movaps [rbp+var_270], xmm5 movaps [rbp+var_260], xmm6 movaps [rbp+var_250], xmm7 loc_26C90: mov rax, fs:28h mov [rbp+var_18], rax lea rcx, [rbp+var_240] mov [rcx+10h], rdi lea rax, [rbp+arg_0] mov [rcx+8], rax mov rax, 3000000008h mov [rcx], rax lea r14, [rbp+var_220] mov esi, 200h mov rdi, r14 mov rdx, r10 call my_vsnprintf mov rbx, rax mov rax, cs:stderr_ptr mov rdi, [rax] call _fileno mov edx, ebx mov edi, eax mov rsi, r14 call _write mov rax, fs:28h cmp rax, [rbp+var_18] jnz short loc_26D10 mov rax, rbx add rsp, 2E0h pop rbx pop r14 pop rbp retn loc_26D10: call ___stack_chk_fail
long long my_safe_printf_stderr( 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 a15) { long long v15; // rbx unsigned int v16; // eax char v18; // [rsp+0h] [rbp-2F0h] BYREF long long v19; // [rsp+8h] [rbp-2E8h] long long v20; // [rsp+10h] [rbp-2E0h] long long v21; // [rsp+18h] [rbp-2D8h] long long v22; // [rsp+20h] [rbp-2D0h] long long v23; // [rsp+28h] [rbp-2C8h] __m128 v24; // [rsp+30h] [rbp-2C0h] __m128 v25; // [rsp+40h] [rbp-2B0h] __m128 v26; // [rsp+50h] [rbp-2A0h] __m128 v27; // [rsp+60h] [rbp-290h] __m128 v28; // [rsp+70h] [rbp-280h] __m128 v29; // [rsp+80h] [rbp-270h] __m128 v30; // [rsp+90h] [rbp-260h] __m128 v31; // [rsp+A0h] [rbp-250h] _QWORD v32[4]; // [rsp+B0h] [rbp-240h] BYREF _BYTE v33[520]; // [rsp+D0h] [rbp-220h] BYREF unsigned long long v34; // [rsp+2D8h] [rbp-18h] v24 = a7; v25 = a8; v26 = a9; v27 = a10; v28 = a11; v29 = a12; v30 = a13; v31 = a14; v19 = a2; v20 = a3; v21 = a4; v22 = a5; v23 = a6; v34 = __readfsqword(0x28u); v32[2] = &v18; v32[1] = &a15; v32[0] = 0x3000000008LL; v15 = my_vsnprintf(v33, 512LL, a1, v32); v16 = fileno(stderr, 512LL); write(v16, v33, (unsigned int)v15); return v15; }
my_safe_printf_stderr: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX SUB RSP,0x2e0 MOV R10,RDI LEA RDI,[RBP + -0x2f0] MOV qword ptr [RDI + 0x8],RSI MOV qword ptr [RDI + 0x10],RDX MOV qword ptr [RDI + 0x18],RCX MOV qword ptr [RDI + 0x20],R8 MOV qword ptr [RDI + 0x28],R9 TEST AL,AL JZ 0x00126c90 MOVAPS xmmword ptr [RBP + -0x2c0],XMM0 MOVAPS xmmword ptr [RBP + -0x2b0],XMM1 MOVAPS xmmword ptr [RBP + -0x2a0],XMM2 MOVAPS xmmword ptr [RBP + -0x290],XMM3 MOVAPS xmmword ptr [RBP + -0x280],XMM4 MOVAPS xmmword ptr [RBP + -0x270],XMM5 MOVAPS xmmword ptr [RBP + -0x260],XMM6 MOVAPS xmmword ptr [RBP + -0x250],XMM7 LAB_00126c90: MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x18],RAX LEA RCX,[RBP + -0x240] MOV qword ptr [RCX + 0x10],RDI LEA RAX,[RBP + 0x10] MOV qword ptr [RCX + 0x8],RAX MOV RAX,0x3000000008 MOV qword ptr [RCX],RAX LEA R14,[RBP + -0x220] MOV ESI,0x200 MOV RDI,R14 MOV RDX,R10 CALL 0x0015a2f9 MOV RBX,RAX MOV RAX,qword ptr [0x003eefd0] MOV RDI,qword ptr [RAX] CALL 0x00124350 MOV EDX,EBX MOV EDI,EAX MOV RSI,R14 CALL 0x00124120 MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x18] JNZ 0x00126d10 MOV RAX,RBX ADD RSP,0x2e0 POP RBX POP R14 POP RBP RET LAB_00126d10: CALL 0x00124390
ulong my_safe_printf_stderr (int8 param_1,int8 param_2,int8 param_3,int8 param_4, int8 param_5,int8 param_6,int8 param_7,int8 param_8, int8 param_9,int8 param_10,int8 param_11,int8 param_12, int8 param_13,int8 param_14) { char in_AL; int __fd; ulong uVar1; long in_FS_OFFSET; int1 local_2f8 [8]; int8 local_2f0; int8 local_2e8; int8 local_2e0; int8 local_2d8; int8 local_2d0; int8 local_2c8; int8 local_2b8; int8 local_2a8; int8 local_298; int8 local_288; int8 local_278; int8 local_268; int8 local_258; int8 local_248; int1 *local_240; int1 *local_238; int1 local_228 [520]; long local_20; local_238 = local_2f8; if (in_AL != '\0') { local_2c8 = param_1; local_2b8 = param_2; local_2a8 = param_3; local_298 = param_4; local_288 = param_5; local_278 = param_6; local_268 = param_7; local_258 = param_8; } local_20 = *(long *)(in_FS_OFFSET + 0x28); local_240 = &stack0x00000008; local_248 = 0x3000000008; local_2f0 = param_10; local_2e8 = param_11; local_2e0 = param_12; local_2d8 = param_13; local_2d0 = param_14; uVar1 = my_vsnprintf(local_228,0x200,param_9); __fd = fileno(*(FILE **)PTR_stderr_003eefd0); write(__fd,local_228,uVar1 & 0xffffffff); if (*(long *)(in_FS_OFFSET + 0x28) == local_20) { return uVar1; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
56,809
safe_hash_change
eloqsql/mysys/my_safehash.c
void safe_hash_change(SAFE_HASH *hash, uchar *old_data, uchar *new_data) { SAFE_HASH_ENTRY *entry, *next; DBUG_ENTER("safe_hash_change"); mysql_rwlock_wrlock(&hash->mutex); for (entry= hash->root ; entry ; entry= next) { next= entry->next; if (entry->data == old_data) { if (new_data == hash->default_value) { if ((*entry->prev= entry->next)) entry->next->prev= entry->prev; my_hash_delete(&hash->hash, (uchar*) entry); } else entry->data= new_data; } } mysql_rwlock_unlock(&hash->mutex); DBUG_VOID_RETURN; }
O0
c
safe_hash_change: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rdi leaq 0x54f8c(%rip), %rsi # 0x15360b movl $0x11b, %edx # imm = 0x11B callq 0xfe5f0 movq -0x8(%rbp), %rax movq 0x110(%rax), %rax movq %rax, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) je 0xfe72e movq -0x20(%rbp), %rax movq 0x18(%rax), %rax movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rax movq 0x10(%rax), %rax cmpq -0x10(%rbp), %rax jne 0xfe71f movq -0x18(%rbp), %rax movq -0x8(%rbp), %rcx cmpq 0x108(%rcx), %rax jne 0xfe711 movq -0x20(%rbp), %rax movq 0x18(%rax), %rax movq -0x20(%rbp), %rcx movq 0x20(%rcx), %rcx movq %rax, (%rcx) cmpq $0x0, %rax je 0xfe6fb movq -0x20(%rbp), %rax movq 0x20(%rax), %rcx movq -0x20(%rbp), %rax movq 0x18(%rax), %rax movq %rcx, 0x20(%rax) movq -0x8(%rbp), %rdi addq $0x98, %rdi movq -0x20(%rbp), %rsi callq 0xde430 jmp 0xfe71d movq -0x18(%rbp), %rcx movq -0x20(%rbp), %rax movq %rcx, 0x10(%rax) jmp 0xfe71f jmp 0xfe721 movq -0x28(%rbp), %rax movq %rax, -0x20(%rbp) jmp 0xfe698 movq -0x8(%rbp), %rdi callq 0xfe3b0 jmp 0xfe739 addq $0x30, %rsp popq %rbp retq nop
safe_hash_change: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rdi, [rbp+var_8] lea rsi, aWorkspaceLlm4b_40; "/workspace/llm4binary/github2025/eloqsq"... mov edx, 11Bh call inline_mysql_rwlock_wrlock_4 mov rax, [rbp+var_8] mov rax, [rax+110h] mov [rbp+var_20], rax loc_FE698: cmp [rbp+var_20], 0 jz loc_FE72E mov rax, [rbp+var_20] mov rax, [rax+18h] mov [rbp+var_28], rax mov rax, [rbp+var_20] mov rax, [rax+10h] cmp rax, [rbp+var_10] jnz short loc_FE71F mov rax, [rbp+var_18] mov rcx, [rbp+var_8] cmp rax, [rcx+108h] jnz short loc_FE711 mov rax, [rbp+var_20] mov rax, [rax+18h] mov rcx, [rbp+var_20] mov rcx, [rcx+20h] mov [rcx], rax cmp rax, 0 jz short loc_FE6FB mov rax, [rbp+var_20] mov rcx, [rax+20h] mov rax, [rbp+var_20] mov rax, [rax+18h] mov [rax+20h], rcx loc_FE6FB: mov rdi, [rbp+var_8] add rdi, 98h mov rsi, [rbp+var_20] call my_hash_delete jmp short loc_FE71D loc_FE711: mov rcx, [rbp+var_18] mov rax, [rbp+var_20] mov [rax+10h], rcx loc_FE71D: jmp short $+2 loc_FE71F: jmp short $+2 loc_FE721: mov rax, [rbp+var_28] mov [rbp+var_20], rax jmp loc_FE698 loc_FE72E: mov rdi, [rbp+var_8] call inline_mysql_rwlock_unlock_8 jmp short $+2 loc_FE739: add rsp, 30h pop rbp retn
long long safe_hash_change(long long a1, long long a2, long long a3) { long long v3; // rax long long v5; // [rsp+8h] [rbp-28h] long long i; // [rsp+10h] [rbp-20h] inline_mysql_rwlock_wrlock_4(a1, (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/my_safehash.c", 0x11Bu); for ( i = *(_QWORD *)(a1 + 272); i; i = v5 ) { v5 = *(_QWORD *)(i + 24); if ( *(_QWORD *)(i + 16) == a2 ) { if ( a3 == *(_QWORD *)(a1 + 264) ) { v3 = *(_QWORD *)(i + 24); **(_QWORD **)(i + 32) = v3; if ( v3 ) *(_QWORD *)(*(_QWORD *)(i + 24) + 32LL) = *(_QWORD *)(i + 32); my_hash_delete(a1 + 152, i); } else { *(_QWORD *)(i + 16) = a3; } } } return inline_mysql_rwlock_unlock_8(a1); }
safe_hash_change: 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 RDI,qword ptr [RBP + -0x8] LEA RSI,[0x25360b] MOV EDX,0x11b CALL 0x001fe5f0 MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x110] MOV qword ptr [RBP + -0x20],RAX LAB_001fe698: CMP qword ptr [RBP + -0x20],0x0 JZ 0x001fe72e MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x10] CMP RAX,qword ptr [RBP + -0x10] JNZ 0x001fe71f MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,qword ptr [RCX + 0x108] JNZ 0x001fe711 MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x18] MOV RCX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RCX + 0x20] MOV qword ptr [RCX],RAX CMP RAX,0x0 JZ 0x001fe6fb MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RAX + 0x20] MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RAX + 0x20],RCX LAB_001fe6fb: MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x98 MOV RSI,qword ptr [RBP + -0x20] CALL 0x001de430 JMP 0x001fe71d LAB_001fe711: MOV RCX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RAX + 0x10],RCX LAB_001fe71d: JMP 0x001fe71f LAB_001fe71f: JMP 0x001fe721 LAB_001fe721: MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x20],RAX JMP 0x001fe698 LAB_001fe72e: MOV RDI,qword ptr [RBP + -0x8] CALL 0x001fe3b0 JMP 0x001fe739 LAB_001fe739: ADD RSP,0x30 POP RBP RET
void safe_hash_change(long param_1,long param_2,long param_3) { long lVar1; long lVar2; long local_28; inline_mysql_rwlock_wrlock (param_1,"/workspace/llm4binary/github2025/eloqsql/mysys/my_safehash.c",0x11b); lVar1 = *(long *)(param_1 + 0x110); while (local_28 = lVar1, local_28 != 0) { lVar1 = *(long *)(local_28 + 0x18); if (*(long *)(local_28 + 0x10) == param_2) { if (param_3 == *(long *)(param_1 + 0x108)) { lVar2 = *(long *)(local_28 + 0x18); **(long **)(local_28 + 0x20) = lVar2; if (lVar2 != 0) { *(int8 *)(*(long *)(local_28 + 0x18) + 0x20) = *(int8 *)(local_28 + 0x20); } my_hash_delete(param_1 + 0x98,local_28); } else { *(long *)(local_28 + 0x10) = param_3; } } } inline_mysql_rwlock_unlock(param_1); return; }
56,810
safe_hash_change
eloqsql/mysys/my_safehash.c
void safe_hash_change(SAFE_HASH *hash, uchar *old_data, uchar *new_data) { SAFE_HASH_ENTRY *entry, *next; DBUG_ENTER("safe_hash_change"); mysql_rwlock_wrlock(&hash->mutex); for (entry= hash->root ; entry ; entry= next) { next= entry->next; if (entry->data == old_data) { if (new_data == hash->default_value) { if ((*entry->prev= entry->next)) entry->next->prev= entry->prev; my_hash_delete(&hash->hash, (uchar*) entry); } else entry->data= new_data; } } mysql_rwlock_unlock(&hash->mutex); DBUG_VOID_RETURN; }
O3
c
safe_hash_change: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx cmpq $0x0, 0x90(%rdi) jne 0xa5d4d movq %rbx, %rdi callq 0xa3f95 movq 0x110(%rbx), %r13 testq %r13, %r13 je 0xa5d2b leaq 0x98(%rbx), %r12 movq %r13, %rsi movq 0x18(%r13), %r13 cmpq %r15, 0x10(%rsi) jne 0xa5d26 cmpq %r14, 0x108(%rbx) je 0xa5d06 movq %r14, 0x10(%rsi) jmp 0xa5d26 movq 0x20(%rsi), %rax movq %r13, (%rax) testq %r13, %r13 je 0xa5d1e movq 0x18(%rsi), %rax movq 0x20(%rsi), %rcx movq %rcx, 0x20(%rax) movq %r12, %rdi callq 0x93d5e testq %r13, %r13 jne 0xa5cea movq 0x90(%rbx), %rdi testq %rdi, %rdi jne 0xa5d66 movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0xa4036 leaq 0x368b0(%rip), %rsi # 0xdc604 movq %rbx, %rdi movl $0x11b, %edx # imm = 0x11B callq 0x2ed7b jmp 0xa5cd7 leaq 0x2e02a3(%rip), %rax # 0x386010 movq (%rax), %rax callq *0x168(%rax) jmp 0xa5d37
safe_hash_change: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r14, rdx mov r15, rsi mov rbx, rdi cmp qword ptr [rdi+90h], 0 jnz short loc_A5D4D mov rdi, rbx call my_rw_wrlock loc_A5CD7: mov r13, [rbx+110h] test r13, r13 jz short loc_A5D2B lea r12, [rbx+98h] loc_A5CEA: mov rsi, r13 mov r13, [r13+18h] cmp [rsi+10h], r15 jnz short loc_A5D26 cmp [rbx+108h], r14 jz short loc_A5D06 mov [rsi+10h], r14 jmp short loc_A5D26 loc_A5D06: mov rax, [rsi+20h] mov [rax], r13 test r13, r13 jz short loc_A5D1E mov rax, [rsi+18h] mov rcx, [rsi+20h] mov [rax+20h], rcx loc_A5D1E: mov rdi, r12 call my_hash_delete loc_A5D26: test r13, r13 jnz short loc_A5CEA loc_A5D2B: mov rdi, [rbx+90h] test rdi, rdi jnz short loc_A5D66 loc_A5D37: mov rdi, rbx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp my_rw_unlock loc_A5D4D: lea rsi, aWorkspaceLlm4b_41; "/workspace/llm4binary/github2025/eloqsq"... mov rdi, rbx mov edx, 11Bh call psi_rwlock_wrlock jmp loc_A5CD7 loc_A5D66: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+168h] jmp short loc_A5D37
long long safe_hash_change(_QWORD *a1, long long a2, long long a3) { long long v6; // r13 long long v7; // rsi long long v8; // rdi if ( a1[18] ) psi_rwlock_wrlock((long long)a1, (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/my_safehash.c", 0x11Bu); else my_rw_wrlock((long long)a1); v6 = a1[34]; while ( v6 ) { v7 = v6; v6 = *(_QWORD *)(v6 + 24); if ( *(_QWORD *)(v7 + 16) == a2 ) { if ( a1[33] == a3 ) { **(_QWORD **)(v7 + 32) = v6; if ( v6 ) *(_QWORD *)(*(_QWORD *)(v7 + 24) + 32LL) = *(_QWORD *)(v7 + 32); my_hash_delete((long long)(a1 + 19), v7); } else { *(_QWORD *)(v7 + 16) = a3; } } } v8 = a1[18]; if ( v8 ) ((void ( *)(long long))PSI_server[45])(v8); return my_rw_unlock((long long)a1); }
safe_hash_change: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,RDX MOV R15,RSI MOV RBX,RDI CMP qword ptr [RDI + 0x90],0x0 JNZ 0x001a5d4d MOV RDI,RBX CALL 0x001a3f95 LAB_001a5cd7: MOV R13,qword ptr [RBX + 0x110] TEST R13,R13 JZ 0x001a5d2b LEA R12,[RBX + 0x98] LAB_001a5cea: MOV RSI,R13 MOV R13,qword ptr [R13 + 0x18] CMP qword ptr [RSI + 0x10],R15 JNZ 0x001a5d26 CMP qword ptr [RBX + 0x108],R14 JZ 0x001a5d06 MOV qword ptr [RSI + 0x10],R14 JMP 0x001a5d26 LAB_001a5d06: MOV RAX,qword ptr [RSI + 0x20] MOV qword ptr [RAX],R13 TEST R13,R13 JZ 0x001a5d1e MOV RAX,qword ptr [RSI + 0x18] MOV RCX,qword ptr [RSI + 0x20] MOV qword ptr [RAX + 0x20],RCX LAB_001a5d1e: MOV RDI,R12 CALL 0x00193d5e LAB_001a5d26: TEST R13,R13 JNZ 0x001a5cea LAB_001a5d2b: MOV RDI,qword ptr [RBX + 0x90] TEST RDI,RDI JNZ 0x001a5d66 LAB_001a5d37: MOV RDI,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x001a4036 LAB_001a5d4d: LEA RSI,[0x1dc604] MOV RDI,RBX MOV EDX,0x11b CALL 0x0012ed7b JMP 0x001a5cd7 LAB_001a5d66: LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x168] JMP 0x001a5d37
void safe_hash_change(long param_1,long param_2,long param_3) { long lVar1; long lVar2; if (*(long *)(param_1 + 0x90) == 0) { my_rw_wrlock(param_1); } else { psi_rwlock_wrlock(param_1,"/workspace/llm4binary/github2025/eloqsql/mysys/my_safehash.c",0x11b); } if (*(long *)(param_1 + 0x110) != 0) { lVar2 = *(long *)(param_1 + 0x110); do { lVar1 = *(long *)(lVar2 + 0x18); if (*(long *)(lVar2 + 0x10) == param_2) { if (*(long *)(param_1 + 0x108) == param_3) { **(long **)(lVar2 + 0x20) = lVar1; if (lVar1 != 0) { *(int8 *)(*(long *)(lVar2 + 0x18) + 0x20) = *(int8 *)(lVar2 + 0x20); } my_hash_delete(param_1 + 0x98); } else { *(long *)(lVar2 + 0x10) = param_3; } } lVar2 = lVar1; } while (lVar1 != 0); } if (*(long *)(param_1 + 0x90) != 0) { (**(code **)(PSI_server + 0x168))(); } my_rw_unlock(param_1); return; }
56,811
LefDefParser::lefiNonDefault::addMinCuts(char const*, int)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefiNonDefault.cpp
void lefiNonDefault::addMinCuts(const char *name, int numCuts) { if (numMinCuts_ == allocatedMinCuts_) { int i; char **cn; int *nc; if (allocatedMinCuts_ == 0) allocatedMinCuts_ = 2; else allocatedMinCuts_ *= 2; cn = (char**) lefMalloc(sizeof(char*) * allocatedMinCuts_); nc = (int*) lefMalloc(sizeof(int) * allocatedMinCuts_); for (i = 0; i < numMinCuts_; i++) { cn[i] = cutLayerName_[i]; nc[i] = numCuts_[i]; } if (numMinCuts_) { lefFree((char*) (cutLayerName_)); lefFree((char*) (numCuts_)); } cutLayerName_ = cn; numCuts_ = nc; } cutLayerName_[numMinCuts_] = (char*) lefMalloc(strlen(name) + 1); strcpy(cutLayerName_[numMinCuts_], CASE(name)); numCuts_[numMinCuts_] = numCuts; numMinCuts_ += 1; }
O3
cpp
LefDefParser::lefiNonDefault::addMinCuts(char const*, int): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx movl %edx, %ebx movq %rsi, %r15 movq %rdi, %r14 movl 0xd8(%rdi), %eax cmpl 0xdc(%rdi), %eax jne 0x2bf69 leal (%rax,%rax), %ecx testl %eax, %eax movl $0x2, %eax cmovnel %ecx, %eax movl %eax, 0xdc(%r14) movslq %eax, %rdi shlq $0x3, %rdi callq 0x30c15 movq %rax, %r12 movslq 0xdc(%r14), %rdi shlq $0x2, %rdi callq 0x30c15 movq %rax, %r13 movl 0xd8(%r14), %ecx testl %ecx, %ecx jle 0x2bf3f xorl %eax, %eax movq 0xe0(%r14), %rcx movq (%rcx,%rax,8), %rcx movq %rcx, (%r12,%rax,8) movq 0xe8(%r14), %rcx movl (%rcx,%rax,4), %ecx movl %ecx, (%r13,%rax,4) incq %rax movslq 0xd8(%r14), %rcx cmpq %rcx, %rax jl 0x2bf12 testl %ecx, %ecx je 0x2bf5b movq 0xe0(%r14), %rdi callq 0x322d0 movq 0xe8(%r14), %rdi callq 0x322d0 movq %r12, 0xe0(%r14) movq %r13, 0xe8(%r14) movq %r15, %rdi callq 0x20e0 leaq 0x1(%rax), %rdi callq 0x30c15 movq 0xe0(%r14), %rcx movslq 0xd8(%r14), %rdx movq %rax, (%rcx,%rdx,8) movq 0xe0(%r14), %rax movq (%rax,%rdx,8), %r12 movq %r15, %rdi callq 0x33e9a movq %r12, %rdi movq %rax, %rsi callq 0x21d0 movq 0xe8(%r14), %rax movslq 0xd8(%r14), %rcx movl %ebx, (%rax,%rcx,4) incl 0xd8(%r14) popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq
_ZN12LefDefParser14lefiNonDefault10addMinCutsEPKci: push r15 push r14 push r13 push r12 push rbx mov ebx, edx mov r15, rsi mov r14, rdi mov eax, [rdi+0D8h] cmp eax, [rdi+0DCh] jnz loc_2BF69 lea ecx, [rax+rax] test eax, eax mov eax, 2 cmovnz eax, ecx mov [r14+0DCh], eax movsxd rdi, eax shl rdi, 3; this call _ZN12LefDefParser9lefMallocEm; LefDefParser::lefMalloc(ulong) mov r12, rax movsxd rdi, dword ptr [r14+0DCh] shl rdi, 2; this call _ZN12LefDefParser9lefMallocEm; LefDefParser::lefMalloc(ulong) mov r13, rax mov ecx, [r14+0D8h] test ecx, ecx jle short loc_2BF3F xor eax, eax loc_2BF12: mov rcx, [r14+0E0h] mov rcx, [rcx+rax*8] mov [r12+rax*8], rcx mov rcx, [r14+0E8h] mov ecx, [rcx+rax*4] mov [r13+rax*4+0], ecx inc rax movsxd rcx, dword ptr [r14+0D8h] cmp rax, rcx jl short loc_2BF12 loc_2BF3F: test ecx, ecx jz short loc_2BF5B mov rdi, [r14+0E0h]; this call _ZN12LefDefParser7lefFreeEPv; LefDefParser::lefFree(void *) mov rdi, [r14+0E8h]; this call _ZN12LefDefParser7lefFreeEPv; LefDefParser::lefFree(void *) loc_2BF5B: mov [r14+0E0h], r12 mov [r14+0E8h], r13 loc_2BF69: mov rdi, r15 call _strlen lea rdi, [rax+1]; this call _ZN12LefDefParser9lefMallocEm; LefDefParser::lefMalloc(ulong) mov rcx, [r14+0E0h] movsxd rdx, dword ptr [r14+0D8h] mov [rcx+rdx*8], rax mov rax, [r14+0E0h] mov r12, [rax+rdx*8] mov rdi, r15; this call _ZN12LefDefParser4CASEEPKc; LefDefParser::CASE(char const*) mov rdi, r12 mov rsi, rax call _strcpy mov rax, [r14+0E8h] movsxd rcx, dword ptr [r14+0D8h] mov [rax+rcx*4], ebx inc dword ptr [r14+0D8h] pop rbx pop r12 pop r13 pop r14 pop r15 retn
long long LefDefParser::lefiNonDefault::addMinCuts(LefDefParser::lefiNonDefault *this, char *a2, int a3) { int v4; // eax int v5; // ecx bool v6; // zf int v7; // eax long long v8; // r12 long long v9; // r13 long long v10; // rcx long long v11; // rax long long v12; // rax long long v13; // rax long long v14; // rdx long long v15; // r12 long long v16; // rax long long result; // rax v4 = *((_DWORD *)this + 54); if ( v4 == *((_DWORD *)this + 55) ) { v5 = 2 * v4; v6 = v4 == 0; v7 = 2; if ( !v6 ) v7 = v5; *((_DWORD *)this + 55) = v7; v8 = LefDefParser::lefMalloc((LefDefParser *)(8LL * v7), (unsigned long long)a2); v9 = LefDefParser::lefMalloc((LefDefParser *)(4LL * *((int *)this + 55)), (unsigned long long)a2); LODWORD(v10) = *((_DWORD *)this + 54); if ( (int)v10 > 0 ) { v11 = 0LL; do { *(_QWORD *)(v8 + 8 * v11) = *(_QWORD *)(*((_QWORD *)this + 28) + 8 * v11); *(_DWORD *)(v9 + 4 * v11) = *(_DWORD *)(*((_QWORD *)this + 29) + 4 * v11); ++v11; v10 = *((int *)this + 54); } while ( v11 < v10 ); } if ( (_DWORD)v10 ) { LefDefParser::lefFree(*((LefDefParser **)this + 28), a2); LefDefParser::lefFree(*((LefDefParser **)this + 29), a2); } *((_QWORD *)this + 28) = v8; *((_QWORD *)this + 29) = v9; } v12 = strlen(a2); v13 = LefDefParser::lefMalloc((LefDefParser *)(v12 + 1), (unsigned long long)a2); v14 = *((int *)this + 54); *(_QWORD *)(*((_QWORD *)this + 28) + 8 * v14) = v13; v15 = *(_QWORD *)(*((_QWORD *)this + 28) + 8 * v14); v16 = LefDefParser::CASE((LefDefParser *)a2, a2); strcpy(v15, v16); result = *((_QWORD *)this + 29); *(_DWORD *)(result + 4LL * (int)(*((_DWORD *)this + 54))++) = a3; return result; }
addMinCuts: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX MOV EBX,EDX MOV R15,RSI MOV R14,RDI MOV EAX,dword ptr [RDI + 0xd8] CMP EAX,dword ptr [RDI + 0xdc] JNZ 0x0012bf69 LEA ECX,[RAX + RAX*0x1] TEST EAX,EAX MOV EAX,0x2 CMOVNZ EAX,ECX MOV dword ptr [R14 + 0xdc],EAX MOVSXD RDI,EAX SHL RDI,0x3 CALL 0x00130c15 MOV R12,RAX MOVSXD RDI,dword ptr [R14 + 0xdc] SHL RDI,0x2 CALL 0x00130c15 MOV R13,RAX MOV ECX,dword ptr [R14 + 0xd8] TEST ECX,ECX JLE 0x0012bf3f XOR EAX,EAX LAB_0012bf12: MOV RCX,qword ptr [R14 + 0xe0] MOV RCX,qword ptr [RCX + RAX*0x8] MOV qword ptr [R12 + RAX*0x8],RCX MOV RCX,qword ptr [R14 + 0xe8] MOV ECX,dword ptr [RCX + RAX*0x4] MOV dword ptr [R13 + RAX*0x4],ECX INC RAX MOVSXD RCX,dword ptr [R14 + 0xd8] CMP RAX,RCX JL 0x0012bf12 LAB_0012bf3f: TEST ECX,ECX JZ 0x0012bf5b MOV RDI,qword ptr [R14 + 0xe0] CALL 0x001322d0 MOV RDI,qword ptr [R14 + 0xe8] CALL 0x001322d0 LAB_0012bf5b: MOV qword ptr [R14 + 0xe0],R12 MOV qword ptr [R14 + 0xe8],R13 LAB_0012bf69: MOV RDI,R15 CALL 0x001020e0 LEA RDI,[RAX + 0x1] CALL 0x00130c15 MOV RCX,qword ptr [R14 + 0xe0] MOVSXD RDX,dword ptr [R14 + 0xd8] MOV qword ptr [RCX + RDX*0x8],RAX MOV RAX,qword ptr [R14 + 0xe0] MOV R12,qword ptr [RAX + RDX*0x8] MOV RDI,R15 CALL 0x00133e9a MOV RDI,R12 MOV RSI,RAX CALL 0x001021d0 MOV RAX,qword ptr [R14 + 0xe8] MOVSXD RCX,dword ptr [R14 + 0xd8] MOV dword ptr [RAX + RCX*0x4],EBX INC dword ptr [R14 + 0xd8] POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* LefDefParser::lefiNonDefault::addMinCuts(char const*, int) */ void __thiscall LefDefParser::lefiNonDefault::addMinCuts(lefiNonDefault *this,char *param_1,int param_2) { int iVar1; long lVar2; long lVar3; long lVar4; size_t sVar5; int8 uVar6; char *__src; int iVar7; char *pcVar8; iVar7 = *(int *)(this + 0xd8); pcVar8 = param_1; if (iVar7 == *(int *)(this + 0xdc)) { iVar1 = 2; if (iVar7 != 0) { iVar1 = iVar7 * 2; } *(int *)(this + 0xdc) = iVar1; lVar2 = lefMalloc((LefDefParser *)((long)iVar1 << 3),(ulong)param_1); lVar3 = lefMalloc((LefDefParser *)((long)*(int *)(this + 0xdc) << 2),(ulong)pcVar8); iVar7 = *(int *)(this + 0xd8); if (0 < iVar7) { lVar4 = 0; do { *(int8 *)(lVar2 + lVar4 * 8) = *(int8 *)(*(long *)(this + 0xe0) + lVar4 * 8); *(int4 *)(lVar3 + lVar4 * 4) = *(int4 *)(*(long *)(this + 0xe8) + lVar4 * 4); lVar4 = lVar4 + 1; iVar7 = *(int *)(this + 0xd8); } while (lVar4 < iVar7); } if (iVar7 != 0) { lefFree(*(void **)(this + 0xe0)); lefFree(*(void **)(this + 0xe8)); } *(long *)(this + 0xe0) = lVar2; *(long *)(this + 0xe8) = lVar3; } sVar5 = strlen(param_1); uVar6 = lefMalloc((LefDefParser *)(sVar5 + 1),(ulong)pcVar8); iVar7 = *(int *)(this + 0xd8); *(int8 *)(*(long *)(this + 0xe0) + (long)iVar7 * 8) = uVar6; pcVar8 = *(char **)(*(long *)(this + 0xe0) + (long)iVar7 * 8); __src = (char *)CASE(param_1); strcpy(pcVar8,__src); *(int *)(*(long *)(this + 0xe8) + (long)*(int *)(this + 0xd8) * 4) = param_2; *(int *)(this + 0xd8) = *(int *)(this + 0xd8) + 1; return; }
56,812
has_path
eloqsql/mysys/my_getwd.c
my_bool has_path(const char *name) { return MY_TEST(strchr(name, FN_LIBCHAR)) #if FN_LIBCHAR != '/' || MY_TEST(strchr(name, '/')) #endif #ifdef FN_DEVCHAR || MY_TEST(strchr(name, FN_DEVCHAR)) #endif ; }
O0
c
has_path: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movl $0x2f, %esi callq 0x3a4e0 movq %rax, %rdx xorl %eax, %eax movl $0x1, %ecx cmpq $0x0, %rdx cmovnel %ecx, %eax addq $0x10, %rsp popq %rbp retq nopw %cs:(%rax,%rax) nopl (%rax,%rax)
has_path: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov rdi, [rbp+var_8] mov esi, 2Fh ; '/' call _strchr mov rdx, rax xor eax, eax mov ecx, 1 cmp rdx, 0 cmovnz eax, ecx add rsp, 10h pop rbp retn
_BOOL8 has_path(long long a1) { return strchr(a1, 47LL) != 0; }
has_path: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV RDI,qword ptr [RBP + -0x8] MOV ESI,0x2f CALL 0x0013a4e0 MOV RDX,RAX XOR EAX,EAX MOV ECX,0x1 CMP RDX,0x0 CMOVNZ EAX,ECX ADD RSP,0x10 POP RBP RET
bool has_path(char *param_1) { char *pcVar1; pcVar1 = strchr(param_1,0x2f); return pcVar1 != (char *)0x0; }
56,813
read_user_name
eloqsql/libmariadb/libmariadb/mariadb_lib.c
void read_user_name(char *name) { if (geteuid() == 0) strcpy(name,"root"); /* allow use of surun */ else { #ifdef HAVE_GETPWUID struct passwd *skr; const char *str; if ((skr=getpwuid(geteuid())) != NULL) { str=skr->pw_name; } else if ((str=getlogin()) == NULL) { if (!(str=getenv("USER")) && !(str=getenv("LOGNAME")) && !(str=getenv("LOGIN"))) str="UNKNOWN_USER"; } ma_strmake(name,str,USERNAME_LENGTH); #elif defined(HAVE_CUSERID) (void) cuserid(name); #else ma_strmake(name,"UNKNOWN_USER", USERNAME_LENGTH); #endif } return; }
O3
c
read_user_name: pushq %rbp movq %rsp, %rbp pushq %rbx pushq %rax movq %rdi, %rbx callq 0x13290 testl %eax, %eax je 0x1b257 callq 0x13290 movl %eax, %edi callq 0x13530 testq %rax, %rax je 0x1b268 movq (%rax), %rsi jmp 0x1b297 movb $0x0, 0x4(%rbx) movl $0x746f6f72, (%rbx) # imm = 0x746F6F72 addq $0x8, %rsp popq %rbx popq %rbp retq callq 0x13470 testq %rax, %rax jne 0x1b294 leaq 0x208aa(%rip), %rdi # 0x3bb23 callq 0x13590 testq %rax, %rax jne 0x1b294 leaq 0x20883(%rip), %rdi # 0x3bb0d callq 0x13590 testq %rax, %rax je 0x1b2aa movq %rax, %rsi movl $0x200, %edx # imm = 0x200 movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %rbp jmp 0x2a20f leaq 0x20864(%rip), %rdi # 0x3bb15 callq 0x13590 testq %rax, %rax leaq 0x2085b(%rip), %rsi # 0x3bb1b cmovneq %rax, %rsi jmp 0x1b297
read_user_name: push rbp mov rbp, rsp push rbx push rax mov rbx, rdi call _geteuid test eax, eax jz short loc_1B257 call _geteuid mov edi, eax call _getpwuid test rax, rax jz short loc_1B268 mov rsi, [rax] jmp short loc_1B297 loc_1B257: mov byte ptr [rbx+4], 0 mov dword ptr [rbx], 746F6F72h add rsp, 8 pop rbx pop rbp retn loc_1B268: call _getlogin test rax, rax jnz short loc_1B294 lea rdi, aUnknownUser+8; "USER" call _getenv test rax, rax jnz short loc_1B294 lea rdi, aLogname; "LOGNAME" call _getenv test rax, rax jz short loc_1B2AA loc_1B294: mov rsi, rax loc_1B297: mov edx, 200h mov rdi, rbx add rsp, 8 pop rbx pop rbp jmp ma_strmake loc_1B2AA: lea rdi, aLogin; "LOGIN" call _getenv test rax, rax lea rsi, aUnknownUser; "UNKNOWN_USER" cmovnz rsi, rax jmp short loc_1B297
long long read_user_name(char *a1) { long long result; // rax unsigned int v2; // eax const char **v3; // rax const char *v4; // rsi long long v5; // rax long long v6; // rax result = geteuid(a1); if ( (_DWORD)result ) { v2 = geteuid(a1); v3 = (const char **)getpwuid(v2); if ( v3 ) { v4 = *v3; } else { v5 = getlogin(); if ( v5 || (v5 = getenv("USER")) != 0 || (v5 = getenv("LOGNAME")) != 0 ) { v4 = (const char *)v5; } else { v6 = getenv("LOGIN"); v4 = "UNKNOWN_USER"; if ( v6 ) v4 = (const char *)v6; } } return ma_strmake(a1, v4, 512LL); } else { strcpy(a1, "root"); } return result; }
read_user_name: PUSH RBP MOV RBP,RSP PUSH RBX PUSH RAX MOV RBX,RDI CALL 0x00113290 TEST EAX,EAX JZ 0x0011b257 CALL 0x00113290 MOV EDI,EAX CALL 0x00113530 TEST RAX,RAX JZ 0x0011b268 MOV RSI,qword ptr [RAX] JMP 0x0011b297 LAB_0011b257: MOV byte ptr [RBX + 0x4],0x0 MOV dword ptr [RBX],0x746f6f72 ADD RSP,0x8 POP RBX POP RBP RET LAB_0011b268: CALL 0x00113470 TEST RAX,RAX JNZ 0x0011b294 LEA RDI,[0x13bb23] CALL 0x00113590 TEST RAX,RAX JNZ 0x0011b294 LEA RDI,[0x13bb0d] CALL 0x00113590 TEST RAX,RAX JZ 0x0011b2aa LAB_0011b294: MOV RSI,RAX LAB_0011b297: MOV EDX,0x200 MOV RDI,RBX ADD RSP,0x8 POP RBX POP RBP JMP 0x0012a20f LAB_0011b2aa: LEA RDI,[0x13bb15] CALL 0x00113590 TEST RAX,RAX LEA RSI,[0x13bb1b] CMOVNZ RSI,RAX JMP 0x0011b297
void read_user_name(int4 *param_1) { __uid_t _Var1; passwd *ppVar2; char *pcVar3; char *pcVar4; _Var1 = geteuid(); if (_Var1 != 0) { _Var1 = geteuid(); ppVar2 = getpwuid(_Var1); if (ppVar2 == (passwd *)0x0) { pcVar3 = getlogin(); if (((pcVar3 == (char *)0x0) && (pcVar3 = getenv("USER"), pcVar3 == (char *)0x0)) && (pcVar3 = getenv("LOGNAME"), pcVar3 == (char *)0x0)) { pcVar4 = getenv("LOGIN"); pcVar3 = "UNKNOWN_USER"; if (pcVar4 != (char *)0x0) { pcVar3 = pcVar4; } } } else { pcVar3 = ppVar2->pw_name; } ma_strmake(param_1,pcVar3,0x200); return; } *(int1 *)(param_1 + 1) = 0; *param_1 = 0x746f6f72; return; }
56,814
uf_varchar2
eloqsql/storage/myisam/mi_packrec.c
static void uf_varchar2(MI_COLUMNDEF *rec, MI_BIT_BUFF *bit_buff, uchar *to, uchar *end __attribute__((unused))) { if (get_bit(bit_buff)) to[0]=to[1]=0; /* Zero lengths */ else { ulong length=get_bits(bit_buff,rec->space_length_bits); int2store(to,length); decode_bytes(rec,bit_buff,to+2,to+2+length); } }
O0
c
uf_varchar2: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq -0x10(%rbp), %rax cmpl $0x0, 0x4(%rax) je 0xbf147 movq -0x10(%rbp), %rax movl (%rax), %eax movq -0x10(%rbp), %rdx movl 0x4(%rdx), %ecx addl $-0x1, %ecx movl %ecx, 0x4(%rdx) movl $0x1, %edx shll %cl, %edx movl %edx, %ecx andl %ecx, %eax cmpl $0x0, %eax jne 0xbf16b jmp 0xbf17f movq -0x10(%rbp), %rdi callq 0xbd720 movq -0x10(%rbp), %rax movl $0x1f, 0x4(%rax) movq -0x10(%rbp), %rax movl (%rax), %eax andl $0x80000000, %eax # imm = 0x80000000 cmpl $0x0, %eax je 0xbf17f movq -0x18(%rbp), %rax movb $0x0, 0x1(%rax) movq -0x18(%rbp), %rax movb $0x0, (%rax) jmp 0xbf215 movq -0x10(%rbp), %rax movl 0x4(%rax), %eax movq -0x8(%rbp), %rcx cmpl 0x1c(%rcx), %eax jb 0xbf1c2 movq -0x10(%rbp), %rax movl (%rax), %eax movq -0x8(%rbp), %rcx movl 0x1c(%rcx), %esi movq -0x10(%rbp), %rdx movl 0x4(%rdx), %ecx subl %esi, %ecx movl %ecx, 0x4(%rdx) shrl %cl, %eax movq -0x8(%rbp), %rcx movl 0x1c(%rcx), %ecx movl %ecx, %edx leaq 0x201526(%rip), %rcx # 0x2c06e0 andl (%rcx,%rdx,4), %eax movl %eax, -0x34(%rbp) jmp 0xbf1d5 movq -0x10(%rbp), %rdi movq -0x8(%rbp), %rax movl 0x1c(%rax), %esi callq 0xbbed0 movl %eax, -0x34(%rbp) movl -0x34(%rbp), %eax movl %eax, %eax movq %rax, -0x28(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x28(%rbp), %rax movw %ax, %cx movq -0x30(%rbp), %rax movw %cx, (%rax) movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx addq $0x2, %rdx movq -0x18(%rbp), %rcx addq $0x2, %rcx addq -0x28(%rbp), %rcx callq 0xbde30 addq $0x40, %rsp popq %rbp retq nopl (%rax,%rax)
uf_varchar2_0: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov [rbp+var_20], rcx mov rax, [rbp+var_10] cmp dword ptr [rax+4], 0 jz short loc_BF147 mov rax, [rbp+var_10] mov eax, [rax] mov rdx, [rbp+var_10] mov ecx, [rdx+4] add ecx, 0FFFFFFFFh mov [rdx+4], ecx mov edx, 1 shl edx, cl mov ecx, edx and eax, ecx cmp eax, 0 jnz short loc_BF16B jmp short loc_BF17F loc_BF147: mov rdi, [rbp+var_10] call fill_buffer_0 mov rax, [rbp+var_10] mov dword ptr [rax+4], 1Fh mov rax, [rbp+var_10] mov eax, [rax] and eax, 80000000h cmp eax, 0 jz short loc_BF17F loc_BF16B: mov rax, [rbp+var_18] mov byte ptr [rax+1], 0 mov rax, [rbp+var_18] mov byte ptr [rax], 0 jmp loc_BF215 loc_BF17F: mov rax, [rbp+var_10] mov eax, [rax+4] mov rcx, [rbp+var_8] cmp eax, [rcx+1Ch] jb short loc_BF1C2 mov rax, [rbp+var_10] mov eax, [rax] mov rcx, [rbp+var_8] mov esi, [rcx+1Ch] mov rdx, [rbp+var_10] mov ecx, [rdx+4] sub ecx, esi mov [rdx+4], ecx shr eax, cl mov rcx, [rbp+var_8] mov ecx, [rcx+1Ch] mov edx, ecx lea rcx, mask_0 and eax, [rcx+rdx*4] mov [rbp+var_34], eax jmp short loc_BF1D5 loc_BF1C2: mov rdi, [rbp+var_10] mov rax, [rbp+var_8] mov esi, [rax+1Ch] call fill_and_get_bits_0 mov [rbp+var_34], eax loc_BF1D5: mov eax, [rbp+var_34] mov eax, eax mov [rbp+var_28], rax mov rax, [rbp+var_18] mov [rbp+var_30], rax mov rax, [rbp+var_28] mov cx, ax mov rax, [rbp+var_30] mov [rax], cx mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] add rdx, 2 mov rcx, [rbp+var_18] add rcx, 2 add rcx, [rbp+var_28] call decode_bytes_0 loc_BF215: add rsp, 40h pop rbp retn
long long uf_varchar2_0(long long a1, int *a2, _BYTE *a3) { int v3; // eax int v4; // ecx long long result; // rax unsigned int v6; // eax int v7; // ecx int bits_0; // [rsp+Ch] [rbp-34h] if ( a2[1] ) { v3 = *a2; v4 = a2[1] - 1; a2[1] = v4; if ( ((1 << v4) & v3) == 0 ) goto LABEL_6; LABEL_5: a3[1] = 0; result = (long long)a3; *a3 = 0; return result; } fill_buffer_0((long long)a2); a2[1] = 31; if ( *a2 < 0 ) goto LABEL_5; LABEL_6: if ( (unsigned int)a2[1] < *(_DWORD *)(a1 + 28) ) { bits_0 = fill_and_get_bits_0(a2, *(_DWORD *)(a1 + 28)); } else { v6 = *a2; v7 = a2[1] - *(_DWORD *)(a1 + 28); a2[1] = v7; bits_0 = mask_0[*(unsigned int *)(a1 + 28)] & (v6 >> v7); } *(_WORD *)a3 = bits_0; return decode_bytes_0(a1, (long long)a2, a3 + 2, &a3[bits_0 + 2]); }
uf_varchar2: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x4],0x0 JZ 0x001bf147 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX] MOV RDX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RDX + 0x4] ADD ECX,-0x1 MOV dword ptr [RDX + 0x4],ECX MOV EDX,0x1 SHL EDX,CL MOV ECX,EDX AND EAX,ECX CMP EAX,0x0 JNZ 0x001bf16b JMP 0x001bf17f LAB_001bf147: MOV RDI,qword ptr [RBP + -0x10] CALL 0x001bd720 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x4],0x1f MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX] AND EAX,0x80000000 CMP EAX,0x0 JZ 0x001bf17f LAB_001bf16b: MOV RAX,qword ptr [RBP + -0x18] MOV byte ptr [RAX + 0x1],0x0 MOV RAX,qword ptr [RBP + -0x18] MOV byte ptr [RAX],0x0 JMP 0x001bf215 LAB_001bf17f: MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x4] MOV RCX,qword ptr [RBP + -0x8] CMP EAX,dword ptr [RCX + 0x1c] JC 0x001bf1c2 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX] MOV RCX,qword ptr [RBP + -0x8] MOV ESI,dword ptr [RCX + 0x1c] MOV RDX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RDX + 0x4] SUB ECX,ESI MOV dword ptr [RDX + 0x4],ECX SHR EAX,CL MOV RCX,qword ptr [RBP + -0x8] MOV ECX,dword ptr [RCX + 0x1c] MOV EDX,ECX LEA RCX,[0x3c06e0] AND EAX,dword ptr [RCX + RDX*0x4] MOV dword ptr [RBP + -0x34],EAX JMP 0x001bf1d5 LAB_001bf1c2: MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x8] MOV ESI,dword ptr [RAX + 0x1c] CALL 0x001bbed0 MOV dword ptr [RBP + -0x34],EAX LAB_001bf1d5: MOV EAX,dword ptr [RBP + -0x34] MOV EAX,EAX MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x28] MOV CX,AX MOV RAX,qword ptr [RBP + -0x30] MOV word ptr [RAX],CX MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] ADD RDX,0x2 MOV RCX,qword ptr [RBP + -0x18] ADD RCX,0x2 ADD RCX,qword ptr [RBP + -0x28] CALL 0x001bde30 LAB_001bf215: ADD RSP,0x40 POP RBP RET
void uf_varchar2(long param_1,uint *param_2,int2 *param_3) { uint uVar1; uint local_3c; if (param_2[1] == 0) { fill_buffer(param_2); param_2[1] = 0x1f; uVar1 = *param_2 & 0x80000000; } else { uVar1 = param_2[1]; param_2[1] = uVar1 - 1; uVar1 = *param_2 & 1 << ((byte)(uVar1 - 1) & 0x1f); } if (uVar1 == 0) { if (param_2[1] < *(uint *)(param_1 + 0x1c)) { local_3c = fill_and_get_bits(param_2,*(int4 *)(param_1 + 0x1c)); } else { uVar1 = param_2[1] - *(int *)(param_1 + 0x1c); param_2[1] = uVar1; local_3c = *param_2 >> ((byte)uVar1 & 0x1f) & *(uint *)(mask + (ulong)*(uint *)(param_1 + 0x1c) * 4); } *param_3 = (short)local_3c; decode_bytes(param_1,param_2,param_3 + 1,(int1 *)((long)param_3 + (ulong)local_3c + 2)); } else { *(int1 *)((long)param_3 + 1) = 0; *(int1 *)param_3 = 0; } return; }
56,815
bitmap_invert
eloqsql/mysys/my_bitmap.c
void bitmap_invert(MY_BITMAP *map) { my_bitmap_map *to= map->bitmap, *end; DBUG_ASSERT(map->bitmap); end= map->last_word_ptr; while (to <= end) *to++ ^= 0xFFFFFFFF; }
O0
c
bitmap_invert: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq (%rax), %rax movq %rax, -0x10(%rbp) jmp 0xf1e55 movq -0x8(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0x18(%rbp) movq -0x10(%rbp), %rax cmpq -0x18(%rbp), %rax ja 0xf1e83 movq -0x10(%rbp), %rax movq %rax, %rcx addq $0x4, %rcx movq %rcx, -0x10(%rbp) movl (%rax), %ecx xorl $-0x1, %ecx movl %ecx, (%rax) jmp 0xf1e61 popq %rbp retq nopw %cs:(%rax,%rax)
bitmap_invert: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov rax, [rax] mov [rbp+var_10], rax jmp short $+2 loc_F1E55: mov rax, [rbp+var_8] mov rax, [rax+8] mov [rbp+var_18], rax loc_F1E61: mov rax, [rbp+var_10] cmp rax, [rbp+var_18] ja short loc_F1E83 mov rax, [rbp+var_10] mov rcx, rax add rcx, 4 mov [rbp+var_10], rcx mov ecx, [rax] xor ecx, 0FFFFFFFFh mov [rax], ecx jmp short loc_F1E61 loc_F1E83: pop rbp retn
int * bitmap_invert(int **a1) { int *result; // rax int *v2; // rax unsigned long long v3; // [rsp+0h] [rbp-18h] int *v4; // [rsp+8h] [rbp-10h] v4 = *a1; v3 = (unsigned long long)a1[1]; while ( 1 ) { result = v4; if ( (unsigned long long)v4 > v3 ) break; v2 = v4++; *v2 = ~*v2; } return result; }
bitmap_invert: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x10],RAX JMP 0x001f1e55 LAB_001f1e55: MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x18],RAX LAB_001f1e61: MOV RAX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RBP + -0x18] JA 0x001f1e83 MOV RAX,qword ptr [RBP + -0x10] MOV RCX,RAX ADD RCX,0x4 MOV qword ptr [RBP + -0x10],RCX MOV ECX,dword ptr [RAX] XOR ECX,0xffffffff MOV dword ptr [RAX],ECX JMP 0x001f1e61 LAB_001f1e83: POP RBP RET
void bitmap_invert(int8 *param_1) { uint *puVar1; uint *local_18; puVar1 = (uint *)param_1[1]; local_18 = (uint *)*param_1; while (local_18 <= puVar1) { *local_18 = *local_18 ^ 0xffffffff; local_18 = local_18 + 1; } return; }
56,816
psi_mutex_lock
eloqsql/mysys/my_thr_init.c
ATTRIBUTE_COLD int psi_mutex_lock(mysql_mutex_t *that, const char *file, uint line) { PSI_mutex_locker_state state; PSI_mutex_locker *locker= PSI_MUTEX_CALL(start_mutex_wait) (&state, that->m_psi, PSI_MUTEX_LOCK, file, line); # ifdef SAFE_MUTEX int result= safe_mutex_lock(&that->m_mutex, FALSE, file, line); # else int result= pthread_mutex_lock(&that->m_mutex); # endif if (locker) PSI_MUTEX_CALL(end_mutex_wait)(locker, result); return result; }
O3
c
psi_mutex_lock: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x38, %rsp movl %edx, %r8d movq %rsi, %rcx movq %rdi, %r14 leaq 0x2cb0cd(%rip), %r15 # 0x2ef830 movq (%r15), %rax movq 0x40(%rdi), %rsi leaq -0x48(%rbp), %rdi xorl %edx, %edx callq *0x190(%rax) movq %rax, %rbx movq %r14, %rdi callq 0x24450 movl %eax, %r14d testq %rbx, %rbx je 0x24798 movq (%r15), %rax movq %rbx, %rdi movl %r14d, %esi callq *0x198(%rax) movl %r14d, %eax addq $0x38, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
psi_mutex_lock: push rbp mov rbp, rsp push r15 push r14 push rbx sub rsp, 38h mov r8d, edx mov rcx, rsi mov r14, rdi lea r15, PSI_server mov rax, [r15] mov rsi, [rdi+40h] lea rdi, [rbp+var_48] xor edx, edx call qword ptr [rax+190h] mov rbx, rax mov rdi, r14 call _pthread_mutex_lock mov r14d, eax test rbx, rbx jz short loc_24798 mov rax, [r15] mov rdi, rbx mov esi, r14d call qword ptr [rax+198h] loc_24798: mov eax, r14d add rsp, 38h pop rbx pop r14 pop r15 pop rbp retn
long long psi_mutex_lock(long long a1, long long a2, unsigned int a3) { long long v3; // rbx unsigned int v4; // r14d _BYTE v6[72]; // [rsp+8h] [rbp-48h] BYREF v3 = (*((long long ( **)(_BYTE *, _QWORD, _QWORD, long long, _QWORD))PSI_server[0] + 50))( v6, *(_QWORD *)(a1 + 64), 0LL, a2, a3); v4 = pthread_mutex_lock(a1); if ( v3 ) (*((void ( **)(long long, _QWORD))PSI_server[0] + 51))(v3, v4); return v4; }
psi_mutex_lock: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x38 MOV R8D,EDX MOV RCX,RSI MOV R14,RDI LEA R15,[0x3ef830] MOV RAX,qword ptr [R15] MOV RSI,qword ptr [RDI + 0x40] LEA RDI,[RBP + -0x48] XOR EDX,EDX CALL qword ptr [RAX + 0x190] MOV RBX,RAX MOV RDI,R14 CALL 0x00124450 MOV R14D,EAX TEST RBX,RBX JZ 0x00124798 MOV RAX,qword ptr [R15] MOV RDI,RBX MOV ESI,R14D CALL qword ptr [RAX + 0x198] LAB_00124798: MOV EAX,R14D ADD RSP,0x38 POP RBX POP R14 POP R15 POP RBP RET
int psi_mutex_lock(pthread_mutex_t *param_1,int8 param_2,int4 param_3) { int iVar1; long lVar2; int1 local_50 [48]; lVar2 = (**(code **)(PSI_server + 400)) (local_50,*(int8 *)((long)param_1 + 0x40),0,param_2,param_3); iVar1 = pthread_mutex_lock(param_1); if (lVar2 != 0) { (**(code **)(PSI_server + 0x198))(lVar2,iVar1); } return iVar1; }
56,817
nglog::base_logging::LogStreamBuf::~LogStreamBuf()
ng-log[P]ng-log/src/ng-log/logging.h
class NGLOG_EXPORT LogStreamBuf : public std::streambuf { public: // REQUIREMENTS: "len" must be >= 2 to account for the '\n' and '\0'. LogStreamBuf(char* buf, int len) { setp(buf, buf + len - 2); } // This effectively ignores overflow. int_type overflow(int_type ch) { return ch; } // Legacy public ostrstream method. size_t pcount() const { return static_cast<size_t>(pptr() - pbase()); } char* pbase() const { return std::streambuf::pbase(); } }
O1
c
nglog::base_logging::LogStreamBuf::~LogStreamBuf(): pushq %rbx movq %rdi, %rbx movq 0x2edef(%rip), %rax # 0x45f18 addq $0x10, %rax movq %rax, (%rdi) addq $0x38, %rdi callq 0x8910 movq %rbx, %rdi popq %rbx jmp 0x8790
_ZN5nglog12base_logging12LogStreamBufD0Ev: push rbx mov rbx, rdi mov rax, cs:_ZTVSt15basic_streambufIcSt11char_traitsIcEE_ptr add rax, 10h mov [rdi], rax add rdi, 38h ; '8'; this call __ZNSt6localeD1Ev; std::locale::~locale() mov rdi, rbx pop rbx jmp _free
void nglog::base_logging::LogStreamBuf::~LogStreamBuf(nglog::base_logging::LogStreamBuf *this) { *(_QWORD *)this = (char *)&`vtable for'std::streambuf + 16; std::locale::~locale((nglog::base_logging::LogStreamBuf *)((char *)this + 56)); free(this); }
~LogStreamBuf: PUSH RBX MOV RBX,RDI MOV RAX,qword ptr [0x00145f18] ADD RAX,0x10 MOV qword ptr [RDI],RAX ADD RDI,0x38 CALL 0x00108910 MOV RDI,RBX POP RBX JMP 0x00108790
/* nglog::base_logging::LogStreamBuf::~LogStreamBuf() */ void __thiscall nglog::base_logging::LogStreamBuf::~LogStreamBuf(LogStreamBuf *this) { *(int **)this = PTR_vtable_00145f18 + 0x10; std::locale::~locale((locale *)(this + 0x38)); free(this); return; }
56,818
SET_mongodb_col
xtate/src/xconf.c
static ConfRes SET_mongodb_col(void *conf, const char *name, const char *value) { XConf *xconf = (XConf *)conf; if (xconf->echo) { return 0; } FREE(xconf->mongodb_col); xconf->mongodb_col = STRDUP(value); return Conf_OK; }
O3
c
SET_mongodb_col: cmpq $0x0, 0x2a8(%rdi) jne 0x59756 pushq %r14 pushq %rbx pushq %rax movq %rdx, %r14 movq %rdi, %rbx movq 0x730(%rdi), %rdi testq %rdi, %rdi je 0x59740 callq 0x151e0 movq $0x0, 0x730(%rbx) movq %r14, %rdi callq 0x508d7 movq %rax, 0x730(%rbx) addq $0x8, %rsp popq %rbx popq %r14 xorl %eax, %eax retq
SET_mongodb_col: cmp qword ptr [rdi+2A8h], 0 jnz short loc_59756 push r14 push rbx push rax mov r14, rdx mov rbx, rdi mov rdi, [rdi+730h] test rdi, rdi jz short loc_59740 call _free mov qword ptr [rbx+730h], 0 loc_59740: mov rdi, r14 call STRDUP mov [rbx+730h], rax add rsp, 8 pop rbx pop r14 loc_59756: xor eax, eax retn
long long SET_mongodb_col(long long a1, long long a2, long long a3) { long long v5; // rdi if ( !*(_QWORD *)(a1 + 680) ) { v5 = *(_QWORD *)(a1 + 1840); if ( v5 ) { free(v5); *(_QWORD *)(a1 + 1840) = 0LL; } *(_QWORD *)(a1 + 1840) = STRDUP(a3); } return 0LL; }
SET_mongodb_col: CMP qword ptr [RDI + 0x2a8],0x0 JNZ 0x00159756 PUSH R14 PUSH RBX PUSH RAX MOV R14,RDX MOV RBX,RDI MOV RDI,qword ptr [RDI + 0x730] TEST RDI,RDI JZ 0x00159740 CALL 0x001151e0 MOV qword ptr [RBX + 0x730],0x0 LAB_00159740: MOV RDI,R14 CALL 0x001508d7 MOV qword ptr [RBX + 0x730],RAX ADD RSP,0x8 POP RBX POP R14 LAB_00159756: XOR EAX,EAX RET
int8 SET_mongodb_col(long param_1,int8 param_2,int8 param_3) { int8 uVar1; if (*(long *)(param_1 + 0x2a8) == 0) { if (*(void **)(param_1 + 0x730) != (void *)0x0) { free(*(void **)(param_1 + 0x730)); *(int8 *)(param_1 + 0x730) = 0; } uVar1 = STRDUP(param_3); *(int8 *)(param_1 + 0x730) = uVar1; } return 0; }
56,819
mi_delete_static_record
eloqsql/storage/myisam/mi_statrec.c
int _mi_delete_static_record(MI_INFO *info) { uchar temp[9]; /* 1+sizeof(uint32) */ info->state->del++; info->state->empty+=info->s->base.pack_reclength; temp[0]= '\0'; /* Mark that record is deleted */ _mi_dpointer(info,temp+1,info->s->state.dellink); info->s->state.dellink = info->lastpos; info->rec_cache.seek_not_done=1; return (info->s->file_write(info,(uchar*) temp, 1+info->s->rec_reflength, info->lastpos, MYF(MY_NABP)) != 0); }
O0
c
mi_delete_static_record: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x20(%rbp) movq -0x20(%rbp), %rax movq 0x8(%rax), %rax movq 0x8(%rax), %rcx incq %rcx movq %rcx, 0x8(%rax) movq -0x20(%rbp), %rax movq (%rax), %rcx movq 0x8(%rax), %rax movq 0x148(%rcx), %rdx movq 0x10(%rax), %rcx addq %rdx, %rcx movq %rcx, 0x10(%rax) movb $0x0, -0x11(%rbp) movq -0x20(%rbp), %rdi leaq -0x10(%rbp), %rsi movq (%rdi), %rax movq 0x58(%rax), %rdx callq 0xc5a60 movq -0x20(%rbp), %rcx movq (%rcx), %rax movq 0x170(%rcx), %rcx movq %rcx, 0x58(%rax) movq -0x20(%rbp), %rax movl $0x1, 0x300(%rax) movq -0x20(%rbp), %rdi movq (%rdi), %rdx movq 0x170(%rdi), %rcx movq 0x2e8(%rdx), %rax movl 0x338(%rdx), %edx incl %edx leaq -0x11(%rbp), %rsi movl $0x4, %r8d callq *%rax testq %rax, %rax setne %al movzbl %al, %eax movl %eax, -0x24(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0xc90d1 movl -0x24(%rbp), %eax addq $0x30, %rsp popq %rbp retq callq 0x2a250 nopw %cs:(%rax,%rax)
_mi_delete_static_record: push rbp mov rbp, rsp sub rsp, 30h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_20], rdi mov rax, [rbp+var_20] mov rax, [rax+8] mov rcx, [rax+8] inc rcx mov [rax+8], rcx mov rax, [rbp+var_20] mov rcx, [rax] mov rax, [rax+8] mov rdx, [rcx+148h] mov rcx, [rax+10h] add rcx, rdx mov [rax+10h], rcx mov [rbp+var_11], 0 mov rdi, [rbp+var_20] lea rsi, [rbp+var_10] mov rax, [rdi] mov rdx, [rax+58h] call _mi_dpointer mov rcx, [rbp+var_20] mov rax, [rcx] mov rcx, [rcx+170h] mov [rax+58h], rcx mov rax, [rbp+var_20] mov dword ptr [rax+300h], 1 mov rdi, [rbp+var_20] mov rdx, [rdi] mov rcx, [rdi+170h] mov rax, [rdx+2E8h] mov edx, [rdx+338h] inc edx lea rsi, [rbp+var_11] mov r8d, 4 call rax test rax, rax setnz al movzx eax, al mov [rbp+var_24], eax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_C90D1 mov eax, [rbp+var_24] add rsp, 30h pop rbp retn loc_C90D1: call ___stack_chk_fail
_BOOL8 mi_delete_static_record(_QWORD *a1) { char v2; // [rsp+1Fh] [rbp-11h] BYREF _BYTE v3[8]; // [rsp+20h] [rbp-10h] BYREF unsigned long long v4; // [rsp+28h] [rbp-8h] v4 = __readfsqword(0x28u); ++*(_QWORD *)(a1[1] + 8LL); *(_QWORD *)(a1[1] + 16LL) += *(_QWORD *)(*a1 + 328LL); v2 = 0; mi_dpointer((long long)a1, v3, *(_QWORD *)(*a1 + 88LL)); *(_QWORD *)(*a1 + 88LL) = a1[46]; *((_DWORD *)a1 + 192) = 1; return (*(long long ( **)(_QWORD *, char *, _QWORD, _QWORD, long long))(*a1 + 744LL))( a1, &v2, (unsigned int)(*(_DWORD *)(*a1 + 824LL) + 1), a1[46], 4LL) != 0; }
_mi_delete_static_record: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x20],RDI MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RAX + 0x8] INC RCX MOV qword ptr [RAX + 0x8],RCX MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x8] MOV RDX,qword ptr [RCX + 0x148] MOV RCX,qword ptr [RAX + 0x10] ADD RCX,RDX MOV qword ptr [RAX + 0x10],RCX MOV byte ptr [RBP + -0x11],0x0 MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[RBP + -0x10] MOV RAX,qword ptr [RDI] MOV RDX,qword ptr [RAX + 0x58] CALL 0x001c5a60 MOV RCX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RCX] MOV RCX,qword ptr [RCX + 0x170] MOV qword ptr [RAX + 0x58],RCX MOV RAX,qword ptr [RBP + -0x20] MOV dword ptr [RAX + 0x300],0x1 MOV RDI,qword ptr [RBP + -0x20] MOV RDX,qword ptr [RDI] MOV RCX,qword ptr [RDI + 0x170] MOV RAX,qword ptr [RDX + 0x2e8] MOV EDX,dword ptr [RDX + 0x338] INC EDX LEA RSI,[RBP + -0x11] MOV R8D,0x4 CALL RAX TEST RAX,RAX SETNZ AL MOVZX EAX,AL MOV dword ptr [RBP + -0x24],EAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x001c90d1 MOV EAX,dword ptr [RBP + -0x24] ADD RSP,0x30 POP RBP RET LAB_001c90d1: CALL 0x0012a250
bool _mi_delete_static_record(long *param_1) { long lVar1; long in_FS_OFFSET; int1 local_19; int1 local_18 [8]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); *(long *)(param_1[1] + 8) = *(long *)(param_1[1] + 8) + 1; *(long *)(param_1[1] + 0x10) = *(long *)(param_1[1] + 0x10) + *(long *)(*param_1 + 0x148); local_19 = 0; _mi_dpointer(param_1,local_18,*(int8 *)(*param_1 + 0x58)); *(long *)(*param_1 + 0x58) = param_1[0x2e]; *(int4 *)(param_1 + 0x60) = 1; lVar1 = (**(code **)(*param_1 + 0x2e8)) (param_1,&local_19,*(int *)(*param_1 + 0x338) + 1,param_1[0x2e],4); if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return lVar1 != 0; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
56,820
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 (&) [9], 0>(char const (&) [9]) const
monkey531[P]llama/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; }
O0
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 (&) [9], 0>(char const (&) [9]) const: subq $0xc8, %rsp movq %rdi, 0xc0(%rsp) movq %rsi, 0xb8(%rsp) movq 0xc0(%rsp), %rdi movq %rdi, 0x20(%rsp) callq 0x11ec10 xorb $-0x1, %al xorb $-0x1, %al xorb $-0x1, %al testb $0x1, %al jne 0x1ab1b8 jmp 0x1ab294 movb $0x1, 0x83(%rsp) movl $0x20, %edi callq 0x618c0 movq 0x20(%rsp), %rdi movq %rax, 0x18(%rsp) callq 0x1253d0 movq %rax, 0x90(%rsp) leaq 0xb094e(%rip), %rsi # 0x25bb36 leaq 0x98(%rsp), %rdi leaq 0x90(%rsp), %rdx callq 0x1b2d10 jmp 0x1ab1ff movq 0x20(%rsp), %rcx movq 0x18(%rsp), %rdi movl $0x130, %esi # imm = 0x130 leaq 0x98(%rsp), %rdx callq 0x15be20 jmp 0x1ab21d movq 0x18(%rsp), %rdi movb $0x0, 0x83(%rsp) leaq 0x148de7(%rip), %rsi # 0x2f4018 leaq -0x85db8(%rip), %rdx # 0x125480 callq 0x61ef0 jmp 0x1ab411 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) jmp 0x1ab279 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) leaq 0x98(%rsp), %rdi callq 0x62cf8 testb $0x1, 0x83(%rsp) jne 0x1ab285 jmp 0x1ab28f movq 0x18(%rsp), %rdi callq 0x62500 jmp 0x1ab404 movq 0x20(%rsp), %rax movq 0x8(%rax), %rdi movq 0xb8(%rsp), %rsi callq 0x1b4c30 movq %rax, %rcx movq 0x20(%rsp), %rax movq %rcx, 0x78(%rsp) movq 0x8(%rax), %rdi callq 0x123ed0 movq %rax, 0x70(%rsp) leaq 0x78(%rsp), %rdi leaq 0x70(%rsp), %rsi callq 0x124da0 testb $0x1, %al jne 0x1ab2dd jmp 0x1ab3ee movb $0x1, 0x2e(%rsp) movl $0x20, %edi callq 0x618c0 movq %rax, (%rsp) movq 0xb8(%rsp), %rax movq %rax, 0x8(%rsp) leaq 0x2f(%rsp), %rdi movq %rdi, 0x10(%rsp) callq 0x626e0 movq 0x8(%rsp), %rsi movq 0x10(%rsp), %rdx leaq 0x30(%rsp), %rdi callq 0x6acb0 jmp 0x1ab322 leaq 0xb083d(%rip), %rsi # 0x25bb66 leaq 0xb083c(%rip), %rcx # 0x25bb6c leaq 0x50(%rsp), %rdi leaq 0x30(%rsp), %rdx callq 0x1b3f30 jmp 0x1ab341 movq 0x20(%rsp), %rcx movq (%rsp), %rdi movl $0x193, %esi # imm = 0x193 leaq 0x50(%rsp), %rdx callq 0x1b4e20 jmp 0x1ab35b movq (%rsp), %rdi movb $0x0, 0x2e(%rsp) leaq 0x148c2d(%rip), %rsi # 0x2f3f98 leaq -0x8d502(%rip), %rdx # 0x11de70 callq 0x61ef0 jmp 0x1ab411 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) jmp 0x1ab3d0 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) jmp 0x1ab3c6 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) leaq 0x50(%rsp), %rdi callq 0x62cf8 leaq 0x30(%rsp), %rdi callq 0x62cf8 leaq 0x2f(%rsp), %rdi callq 0x62cd0 testb $0x1, 0x2e(%rsp) jne 0x1ab3e3 jmp 0x1ab3ec movq (%rsp), %rdi callq 0x62500 jmp 0x1ab404 leaq 0x78(%rsp), %rdi callq 0x124fa0 addq $0x20, %rax addq $0xc8, %rsp retq movq 0x88(%rsp), %rdi callq 0x61ff0 nopw %cs:(%rax,%rax) nopl (%rax,%rax)
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA9_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_: sub rsp, 0C8h mov [rsp+0C8h+var_8], rdi mov qword ptr [rsp+0C8h+var_10], rsi mov rdi, [rsp+0C8h+var_8] mov [rsp+0C8h+var_A8], rdi; int call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9is_objectEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::is_object(void) xor al, 0FFh xor al, 0FFh xor al, 0FFh test al, 1 jnz short loc_1AB1B8 jmp loc_1AB294 loc_1AB1B8: mov [rsp+0C8h+var_45], 1 mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rdi, [rsp+0C8h+var_A8] mov [rsp+0C8h+var_B0], rax; char 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 qword ptr [rsp+0C8h+var_38], rax; char lea rsi, aCannotUseAtWit; "cannot use at() with " lea rdi, [rsp+0C8h+var_30]; int lea rdx, [rsp+0C8h+var_38]; int 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* &&) jmp short $+2 loc_1AB1FF: mov rcx, [rsp+0C8h+var_A8] mov rdi, [rsp+0C8h+var_B0]; int mov esi, 130h lea rdx, [rsp+0C8h+var_30] call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ jmp short $+2 loc_1AB21D: mov rdi, [rsp+0C8h+var_B0]; void * mov [rsp+0C8h+var_45], 0 lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail10type_errorD2Ev; void (*)(void *) call ___cxa_throw jmp loc_1AB411 mov rcx, rax mov eax, edx mov [rsp+arg_80], rcx mov [rsp+arg_7C], eax jmp short loc_1AB279 mov rcx, rax mov eax, edx mov [rsp+arg_80], rcx mov [rsp+arg_7C], eax lea rdi, [rsp+arg_90]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_1AB279: test [rsp+arg_7B], 1 jnz short loc_1AB285 jmp short loc_1AB28F loc_1AB285: mov rdi, [rsp+arg_10]; void * call ___cxa_free_exception loc_1AB28F: jmp loc_1AB404 loc_1AB294: mov rax, [rsp+0C8h+var_A8] mov rdi, [rax+8] mov rsi, qword ptr [rsp+0C8h+var_10] call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA9_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_ mov rcx, rax mov rax, [rsp+0C8h+var_A8] mov qword ptr [rsp+0C8h+var_50], rcx; int mov rdi, [rax+8] call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<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>>>::end(void) mov qword ptr [rsp+0C8h+var_58], rax; char lea rdi, [rsp+0C8h+var_50] lea rsi, [rsp+0C8h+var_58] call _ZN9__gnu_cxxeqIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbRKNS_17__normal_iteratorIT_T0_EESR_; __gnu_cxx::operator==<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>> *,std::vector<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>>>>(__gnu_cxx::__normal_iterator<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>> *,std::vector<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>>>> const&,__gnu_cxx::__normal_iterator<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>> *,std::vector<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>>>> const&) test al, 1 jnz short loc_1AB2DD jmp loc_1AB3EE loc_1AB2DD: mov [rsp+0C8h+var_9A], 1 mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov [rsp+0C8h+var_C8], rax; int mov rax, qword ptr [rsp+0C8h+var_10] mov qword ptr [rsp+0C8h+var_C0], rax; int lea rdi, [rsp+0C8h+var_99] mov qword ptr [rsp+0C8h+var_B8], rdi; int call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rsi, qword ptr [rsp+0C8h+var_C0] mov rdx, qword ptr [rsp+0C8h+var_B8] lea rdi, [rsp+0C8h+var_99+1] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short $+2 loc_1AB322: lea rsi, aKey; "key '" lea rcx, aNotFound; "' not found" lea rdi, [rsp+0C8h+var_78]; int lea rdx, [rsp+0C8h+var_99+1]; int 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] &&) jmp short $+2 loc_1AB341: mov rcx, [rsp+0C8h+var_A8] mov rdi, [rsp+0C8h+var_C8]; int mov esi, 193h lea rdx, [rsp+0C8h+var_78] 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_ jmp short $+2 loc_1AB35B: mov rdi, [rsp+0C8h+var_C8]; void * mov [rsp+0C8h+var_9A], 0 lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail12out_of_rangeE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail12out_of_rangeD2Ev; void (*)(void *) call ___cxa_throw jmp loc_1AB411 mov rcx, rax mov eax, edx mov [rsp+arg_80], rcx mov [rsp+arg_7C], eax jmp short loc_1AB3D0 mov rcx, rax mov eax, edx mov [rsp+arg_80], rcx mov [rsp+arg_7C], eax jmp short loc_1AB3C6 mov rcx, rax mov eax, edx mov [rsp+arg_80], rcx mov [rsp+arg_7C], eax lea rdi, [rsp+arg_48]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_1AB3C6: lea rdi, [rsp+arg_28]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_1AB3D0: lea rdi, [rsp+arg_27] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() test [rsp+arg_26], 1 jnz short loc_1AB3E3 jmp short loc_1AB3EC loc_1AB3E3: mov rdi, [rsp+0]; void * call ___cxa_free_exception loc_1AB3EC: jmp short loc_1AB404 loc_1AB3EE: lea rdi, [rsp+0C8h+var_50] call _ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEptEv; __gnu_cxx::__normal_iterator<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>> *,std::vector<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>>>>::operator->(void) add rax, 20h ; ' ' add rsp, 0C8h retn loc_1AB404: mov rdi, [rsp+arg_80] call __Unwind_Resume loc_1AB411: nop word ptr [rax+rax+00000000h] nop dword ptr [rax+rax+00h]
long long ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA9_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_( long long a1, long long a2) { int v2; // ecx int v3; // r8d int v4; // r9d long long v5; // rdx int v6; // r8d int v7; // r9d int v9; // [rsp+0h] [rbp-C8h] void *v10; // [rsp+0h] [rbp-C8h] int v11; // [rsp+0h] [rbp-C8h] void *v12; // [rsp+0h] [rbp-C8h] void *v13; // [rsp+8h] [rbp-C0h] long long v14; // [rsp+8h] [rbp-C0h] int v15; // [rsp+8h] [rbp-C0h] int v16; // [rsp+10h] [rbp-B8h] int v17; // [rsp+10h] [rbp-B8h] int v18; // [rsp+18h] [rbp-B0h] void *exception; // [rsp+18h] [rbp-B0h] nlohmann::json_abi_v3_11_3::detail::type_error *v20; // [rsp+18h] [rbp-B0h] char v21; // [rsp+18h] [rbp-B0h] int v22; // [rsp+20h] [rbp-A8h] int v23; // [rsp+28h] [rbp-A0h] char v24; // [rsp+2Fh] [rbp-99h] BYREF int v25[4]; // [rsp+30h] [rbp-98h] BYREF long long v26; // [rsp+40h] [rbp-88h] int v27; // [rsp+48h] [rbp-80h] int v28[8]; // [rsp+50h] [rbp-78h] BYREF char v29[8]; // [rsp+70h] [rbp-58h] BYREF int v30[2]; // [rsp+78h] [rbp-50h] BYREF int v31; // [rsp+80h] [rbp-48h] int v32; // [rsp+88h] [rbp-40h] char v33[8]; // [rsp+90h] [rbp-38h] BYREF int v34[8]; // [rsp+98h] [rbp-30h] BYREF int v35[2]; // [rsp+B8h] [rbp-10h] long long v36; // [rsp+C0h] [rbp-8h] v36 = a1; *(_QWORD *)v35 = a2; if ( !nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::is_object((_BYTE *)a1) ) { exception = __cxa_allocate_exception(0x20uLL); *(_QWORD *)v33 = 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((_BYTE *)a1); nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[22],char const*>( (int)v34, (int)"cannot use at() with ", (int)v33, v2, v3, v4, v9, v13, v16, (long long)exception); ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( v20, 304LL, (long long)v34, a1); HIBYTE(v31) = 0; __cxa_throw( v20, (struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error, (void (*)(void *))nlohmann::json_abi_v3_11_3::detail::type_error::~type_error); } *(_QWORD *)v30 = ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA9_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_( *(_QWORD *)(a1 + 8), *(_QWORD *)v35); *(_QWORD *)v29 = std::vector<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>>>::end(*(_QWORD *)(a1 + 8)); if ( __gnu_cxx::operator==<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>> *,std::vector<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>>>>( (long long)v30, (long long)v29) ) { v10 = __cxa_allocate_exception(0x20uLL); v14 = *(_QWORD *)v35; std::allocator<char>::allocator(&v24, v29, v5); std::string::basic_string<std::allocator<char>>((long long)v25, v14, (long long)&v24); nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[6],std::string,char const(&)[12]>( (int)v28, (int)"key '", (int)v25, (int)"' not found", v6, v7, v10, v14, (int)&v24, v18, a1); ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( v11, v11, v15, v17, v21, v22, v23, v25[0], v25[2], v26, v27, v28[0], v28[2], v28[4], v28[6], v29[0], v30[0], v31, v32, v33[0]); __cxa_throw( v12, (struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::out_of_range, (void (*)(void *))nlohmann::json_abi_v3_11_3::detail::out_of_range::~out_of_range); } return __gnu_cxx::__normal_iterator<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>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator->((long long)v30) + 32; }
56,821
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 (&) [9], 0>(char const (&) [9]) const
monkey531[P]llama/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; }
O2
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 (&) [9], 0>(char const (&) [9]) const: pushq %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x48, %rsp movq %rdi, %r14 cmpb $0x1, (%rdi) jne 0x9ab19 movq %rsi, %r15 movq 0x8(%r14), %rdi callq 0x99f3a movq 0x8(%r14), %rcx cmpq 0x8(%rcx), %rax je 0x9ab77 addq $0x20, %rax addq $0x48, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq pushq $0x20 popq %rdi callq 0x265e0 movq %rax, %rbx movq %r14, %rdi callq 0x6a48e leaq 0x28(%rsp), %rdx movq %rax, (%rdx) leaq 0x377f0(%rip), %rsi # 0xd232b leaq 0x8(%rsp), %rdi callq 0x99965 movb $0x1, %bpl leaq 0x8(%rsp), %rdx movq %rbx, %rdi movl $0x130, %esi # imm = 0x130 movq %r14, %rcx callq 0x7f136 xorl %ebp, %ebp leaq 0x84632(%rip), %rsi # 0x11f198 leaq -0x339c7(%rip), %rdx # 0x671a6 movq %rbx, %rdi callq 0x275b0 jmp 0x9abe1 pushq $0x20 popq %rdi callq 0x265e0 movq %rax, %rbx leaq 0x28(%rsp), %rdi leaq 0x7(%rsp), %rdx movq %r15, %rsi callq 0x2b096 leaq 0x377c0(%rip), %rsi # 0xd235b leaq 0x377bf(%rip), %rcx # 0xd2361 leaq 0x8(%rsp), %rdi leaq 0x28(%rsp), %rdx callq 0x99f6f movb $0x1, %bpl leaq 0x8(%rsp), %rdx movq %rbx, %rdi movl $0x193, %esi # imm = 0x193 movq %r14, %rcx callq 0x9a3da xorl %ebp, %ebp leaq 0x84546(%rip), %rsi # 0x11f118 leaq -0x33a33(%rip), %rdx # 0x671a6 movq %rbx, %rdi callq 0x275b0 movq %rax, %r14 leaq 0x8(%rsp), %rdi callq 0x27998 jmp 0x9abf6 movq %rax, %r14 movb $0x1, %bpl leaq 0x28(%rsp), %rdi jmp 0x9ac07 jmp 0x9ac13 movq %rax, %r14 leaq 0x8(%rsp), %rdi callq 0x27998 testb %bpl, %bpl jne 0x9ac16 jmp 0x9ac1e movq %rax, %r14 movq %rbx, %rdi callq 0x268f0 movq %r14, %rdi callq 0x27660
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA8_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_: push rbp; char push r15; int push r14; int push rbx; int sub rsp, 48h mov r14, rdi cmp byte ptr [rdi], 1 jnz short loc_9AB19 mov r15, rsi mov rdi, [r14+8] call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA8_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_ mov rcx, [r14+8] cmp rax, [rcx+8] jz short loc_9AB77 add rax, 20h ; ' ' add rsp, 48h pop rbx pop r14 pop r15 pop rbp retn loc_9AB19: push 20h ; ' ' pop rdi; thrown_size call ___cxa_allocate_exception mov rbx, rax mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void) lea rdx, [rsp+68h+var_40] mov [rdx], rax lea rsi, aCannotUseAtWit; "cannot use at() with " lea rdi, [rsp+68h+var_60] 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_60] 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_9ABE1 loc_9AB77: push 20h ; ' ' pop rdi; thrown_size call ___cxa_allocate_exception mov rbx, rax lea rdi, [rsp+68h+var_40] lea rdx, [rsp+68h+var_61] mov rsi, r15 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) lea rsi, aKey; "key '" lea rcx, aNotFound; "' not found" lea rdi, [rsp+68h+var_60] lea rdx, [rsp+68h+var_40] 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_60] 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_9ABE1: mov r14, rax lea rdi, [rsp+68h+var_60]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_9ABF6 mov r14, rax mov bpl, 1 loc_9ABF6: lea rdi, [rsp+68h+var_40] jmp short loc_9AC07 jmp short loc_9AC13 mov r14, rax lea rdi, [rsp+68h+var_60]; void * loc_9AC07: call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() test bpl, bpl jnz short loc_9AC16 jmp short loc_9AC1E loc_9AC13: mov r14, rax loc_9AC16: mov rdi, rbx; void * call ___cxa_free_exception loc_9AC1E: mov rdi, r14 call __Unwind_Resume
long long ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA8_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_( long long a1, long long a2) { long long v2; // rax nlohmann::json_abi_v3_11_3::detail::type_error *exception; // rbx nlohmann::json_abi_v3_11_3::detail::out_of_range *v5; // rbx _BYTE v6[32]; // [rsp+8h] [rbp-60h] BYREF _QWORD v7[8]; // [rsp+28h] [rbp-40h] BYREF if ( *(_BYTE *)a1 != 1 ) { exception = (nlohmann::json_abi_v3_11_3::detail::type_error *)__cxa_allocate_exception(0x20uLL); v7[0] = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name((unsigned __int8 *)a1); nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[22],char const*>( (long long)v6, (long long)"cannot use at() with ", v7); ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( exception, 304, (long long)v6); __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); } v2 = ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA8_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_(*(long long **)(a1 + 8)); if ( v2 == *(_QWORD *)(*(_QWORD *)(a1 + 8) + 8LL) ) { v5 = (nlohmann::json_abi_v3_11_3::detail::out_of_range *)__cxa_allocate_exception(0x20uLL); std::string::basic_string<std::allocator<char>>(v7, a2); nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[6],std::string,char const(&)[12]>( (long long)v6, (long long)"key '", (long long)v7, (long long)"' not found"); ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( v5, 403, (long long)v6); __cxa_throw( v5, (struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::out_of_range, (void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception); } return v2 + 32; }
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA8_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x48 MOV R14,RDI CMP byte ptr [RDI],0x1 JNZ 0x0019ab19 MOV R15,RSI MOV RDI,qword ptr [R14 + 0x8] CALL 0x00199f3a MOV RCX,qword ptr [R14 + 0x8] CMP RAX,qword ptr [RCX + 0x8] JZ 0x0019ab77 ADD RAX,0x20 ADD RSP,0x48 POP RBX POP R14 POP R15 POP RBP RET LAB_0019ab19: PUSH 0x20 POP RDI CALL 0x001265e0 MOV RBX,RAX MOV RDI,R14 CALL 0x0016a48e LEA RDX,[RSP + 0x28] MOV qword ptr [RDX],RAX LAB_0019ab34: LEA RSI,[0x1d232b] LEA RDI,[RSP + 0x8] CALL 0x00199965 MOV BPL,0x1 LAB_0019ab48: LEA RDX,[RSP + 0x8] MOV RDI,RBX MOV ESI,0x130 MOV RCX,R14 CALL 0x0017f136 XOR EBP,EBP LEA RSI,[0x21f198] LEA RDX,[0x1671a6] MOV RDI,RBX CALL 0x001275b0 LAB_0019ab77: PUSH 0x20 POP RDI CALL 0x001265e0 MOV RBX,RAX LAB_0019ab82: LEA RDI,[RSP + 0x28] LEA RDX,[RSP + 0x7] MOV RSI,R15 CALL 0x0012b096 LAB_0019ab94: LEA RSI,[0x1d235b] LEA RCX,[0x1d2361] LEA RDI,[RSP + 0x8] LEA RDX,[RSP + 0x28] CALL 0x00199f6f MOV BPL,0x1 LAB_0019abb4: LEA RDX,[RSP + 0x8] MOV RDI,RBX MOV ESI,0x193 MOV RCX,R14 CALL 0x0019a3da XOR EBP,EBP LEA RSI,[0x21f118] LEA RDX,[0x1671a6] MOV RDI,RBX CALL 0x001275b0
long _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA8_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 lVar1; int8 uVar2; allocator local_61; detail local_60 [32]; char *local_40 [4]; 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) { uVar2 = __cxa_allocate_exception(0x20); local_40[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 0019ab34 to 0019ab44 has its CatchHandler @ 0019ac13 */ nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[22],char_const*> (local_60,"cannot use at() with ",local_40); /* try { // try from 0019ab48 to 0019ab74 has its CatchHandler @ 0019abff */ _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ (uVar2,0x130,local_60,param_1); /* WARNING: Subroutine does not return */ __cxa_throw(uVar2,&nlohmann::json_abi_v3_11_3::detail::type_error::typeinfo, nlohmann::json_abi_v3_11_3::detail::exception::~exception); } lVar1 = _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA8_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_ (*(int8 *)(param_1 + 8)); if (lVar1 != *(long *)(*(long *)(param_1 + 8) + 8)) { return lVar1 + 0x20; } uVar2 = __cxa_allocate_exception(0x20); /* try { // try from 0019ab82 to 0019ab93 has its CatchHandler @ 0019abfd */ std::__cxx11::string::string<std::allocator<char>>((string *)local_40,param_2,&local_61); /* try { // try from 0019ab94 to 0019abb0 has its CatchHandler @ 0019abf0 */ nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,char_const(&)[6],std::__cxx11::string,char_const(&)[12]> (local_60,"key \'",(string *)local_40,"\' not found"); /* try { // try from 0019abb4 to 0019abe0 has its CatchHandler @ 0019abe1 */ _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ (uVar2,0x193,local_60,param_1); /* WARNING: Subroutine does not return */ __cxa_throw(uVar2,&nlohmann::json_abi_v3_11_3::detail::out_of_range::typeinfo, nlohmann::json_abi_v3_11_3::detail::exception::~exception); }
56,822
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 (&) [9], 0>(char const (&) [9]) const
monkey531[P]llama/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 (&) [9], 0>(char const (&) [9]) const: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x40, %rsp movq %rdi, %r14 cmpb $0x1, (%rdi) jne 0xcf439 movq %rsi, %r15 movq 0x8(%r14), %r12 movq (%r12), %rbx movq 0x8(%r12), %rax cmpq %rax, %rbx je 0xcf423 movq %rbx, %rdi movq %r15, %rsi callq 0x1d2a0 testl %eax, %eax je 0xcf418 addq $0x30, %rbx movq 0x8(%r12), %rax cmpq %rax, %rbx jne 0xcf3f9 jmp 0xcf41b movq %rbx, %rax movq 0x8(%r14), %rcx movq 0x8(%rcx), %rbx cmpq %rbx, %rax je 0xcf497 addq $0x20, %rax addq $0x40, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movl $0x20, %edi callq 0x1d5b0 movq %rax, %rbx movq %r14, %rdi callq 0x8f08a movq %rsp, %rdx movq %rax, (%rdx) leaq 0x46ff0(%rip), %rsi # 0x11644b leaq 0x20(%rsp), %rdi callq 0xce305 movb $0x1, %bpl leaq 0x20(%rsp), %rdx movq %rbx, %rdi movl $0x130, %esi # imm = 0x130 movq %r14, %rcx callq 0xa9d1a xorl %ebp, %ebp leaq 0x84d12(%rip), %rsi # 0x154198 leaq -0x440f9(%rip), %rdx # 0x8b394 movq %rbx, %rdi callq 0x1e5b0 jmp 0xcf510 movl $0x20, %edi callq 0x1d5b0 movq %rax, %rbx leaq 0x10(%rsp), %r12 movq %r12, -0x10(%r12) movq %r15, %rdi callq 0x1d4f0 leaq (%rax,%r15), %rdx movq %rsp, %rdi movq %r15, %rsi callq 0x25e6a leaq 0x46faf(%rip), %rsi # 0x11647b leaq 0x46fae(%rip), %rcx # 0x116481 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0xce8e2 movb $0x1, %bpl leaq 0x20(%rsp), %rdx movq %rbx, %rdi movl $0x193, %esi # imm = 0x193 movq %r14, %rcx callq 0xcec5a xorl %ebp, %ebp leaq 0x84c17(%rip), %rsi # 0x154118 leaq -0x44174(%rip), %rdx # 0x8b394 movq %rbx, %rdi callq 0x1e5b0 movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xcf52e movq 0x30(%rsp), %rsi incq %rsi callq 0x1dc50 movq (%rsp), %rdi cmpq %r12, %rdi je 0xcf579 movq 0x10(%rsp), %rsi jmp 0xcf571 movq %rax, %r14 movq (%rsp), %rdi cmpq %r12, %rdi je 0xcf583 movq 0x10(%rsp), %rsi incq %rsi callq 0x1dc50 jmp 0xcf583 jmp 0xcf580 movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xcf579 movq 0x30(%rsp), %rsi incq %rsi callq 0x1dc50 testb %bpl, %bpl jne 0xcf583 jmp 0xcf58b movq %rax, %r14 movq %rbx, %rdi callq 0x1d8c0 movq %r14, %rdi callq 0x1e660 nop
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA8_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_: push rbp; char push r15; int push r14; int push r12; int push rbx; char sub rsp, 40h mov r14, rdi cmp byte ptr [rdi], 1 jnz short loc_CF439 mov r15, rsi mov r12, [r14+8] mov rbx, [r12] mov rax, [r12+8] cmp rbx, rax jz short loc_CF423 loc_CF3F9: mov rdi, rbx mov rsi, r15 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*) test eax, eax jz short loc_CF418 add rbx, 30h ; '0' mov rax, [r12+8] cmp rbx, rax jnz short loc_CF3F9 jmp short loc_CF41B loc_CF418: mov rax, rbx loc_CF41B: mov rcx, [r14+8] mov rbx, [rcx+8] loc_CF423: cmp rax, rbx jz short loc_CF497 add rax, 20h ; ' ' add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_CF439: 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_CF510 loc_CF497: 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_CF510: mov r14, rax lea rax, [rsp+68h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_CF52E mov rsi, [rsp+68h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_CF52E: mov rdi, [rsp+68h+var_68] cmp rdi, r12 jz short loc_CF579 mov rsi, [rsp+68h+var_58] jmp short loc_CF571 mov r14, rax mov rdi, [rsp+68h+var_68]; void * cmp rdi, r12 jz short loc_CF583 mov rsi, [rsp+68h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_CF583 jmp short loc_CF580 mov r14, rax lea rax, [rsp+68h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_CF579 mov rsi, [rsp+68h+var_38] loc_CF571: inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_CF579: test bpl, bpl jnz short loc_CF583 jmp short loc_CF58B loc_CF580: mov r14, rax loc_CF583: mov rdi, rbx; void * call ___cxa_free_exception loc_CF58B: mov rdi, r14 call __Unwind_Resume
long long ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA8_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_( long long a1, _BYTE *a2) { long long *v2; // r12 long long v3; // rbx long long v4; // rax nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx nlohmann::json_abi_v3_11_3::detail::exception *v7; // rbx long long v8; // rax void *v9[2]; // [rsp+0h] [rbp-68h] BYREF long long v10; // [rsp+10h] [rbp-58h] BYREF _QWORD v11[2]; // [rsp+20h] [rbp-48h] BYREF if ( *(_BYTE *)a1 != 1 ) { exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL); v9[0] = (void *)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(&)[22],char const*>( (long long)v11, (long long)"cannot use at() with ", v9); ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( exception, 304, v11); __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); } v2 = *(long long **)(a1 + 8); v3 = *v2; v4 = v2[1]; if ( *v2 != v4 ) { while ( (unsigned int)std::string::compare(v3, a2) ) { v3 += 48LL; v4 = v2[1]; if ( v3 == v4 ) goto LABEL_7; } v4 = v3; LABEL_7: v3 = *(_QWORD *)(*(_QWORD *)(a1 + 8) + 8LL); } if ( v4 == v3 ) { v7 = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL); v9[0] = &v10; v8 = strlen(a2); std::string::_M_construct<char const*>((long long)v9, a2, (long long)&a2[v8]); nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[6],std::string,char const(&)[12]>( (long long)v11, (long long)"key '", v9, (long long)"' not found"); ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( v7, 403, v11); __cxa_throw( v7, (struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::out_of_range, (void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception); } return v4 + 32; }
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA8_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 0x001cf439 MOV R15,RSI MOV R12,qword ptr [R14 + 0x8] MOV RBX,qword ptr [R12] MOV RAX,qword ptr [R12 + 0x8] CMP RBX,RAX JZ 0x001cf423 LAB_001cf3f9: MOV RDI,RBX MOV RSI,R15 CALL 0x0011d2a0 TEST EAX,EAX JZ 0x001cf418 ADD RBX,0x30 MOV RAX,qword ptr [R12 + 0x8] CMP RBX,RAX JNZ 0x001cf3f9 JMP 0x001cf41b LAB_001cf418: MOV RAX,RBX LAB_001cf41b: MOV RCX,qword ptr [R14 + 0x8] MOV RBX,qword ptr [RCX + 0x8] LAB_001cf423: CMP RAX,RBX JZ 0x001cf497 ADD RAX,0x20 ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_001cf439: MOV EDI,0x20 CALL 0x0011d5b0 MOV RBX,RAX MOV RDI,R14 CALL 0x0018f08a MOV RDX,RSP MOV qword ptr [RDX],RAX LAB_001cf454: LEA RSI,[0x21644b] LEA RDI,[RSP + 0x20] CALL 0x001ce305 MOV BPL,0x1 LAB_001cf468: LEA RDX,[RSP + 0x20] MOV RDI,RBX MOV ESI,0x130 MOV RCX,R14 CALL 0x001a9d1a XOR EBP,EBP LEA RSI,[0x254198] LEA RDX,[0x18b394] MOV RDI,RBX CALL 0x0011e5b0 LAB_001cf497: MOV EDI,0x20 CALL 0x0011d5b0 MOV RBX,RAX LEA R12,[RSP + 0x10] MOV qword ptr [R12 + -0x10],R12 MOV RDI,R15 CALL 0x0011d4f0 LEA RDX,[RAX + R15*0x1] LAB_001cf4ba: MOV RDI,RSP MOV RSI,R15 CALL 0x00125e6a LAB_001cf4c5: LEA RSI,[0x21647b] LEA RCX,[0x216481] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x001ce8e2 MOV BPL,0x1 LAB_001cf4e3: LEA RDX,[RSP + 0x20] MOV RDI,RBX MOV ESI,0x193 MOV RCX,R14 CALL 0x001cec5a XOR EBP,EBP LEA RSI,[0x254118] LEA RDX,[0x18b394] MOV RDI,RBX CALL 0x0011e5b0
char * _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA8_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 001cf454 to 001cf464 has its CatchHandler @ 001cf580 */ 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 001cf468 to 001cf494 has its CatchHandler @ 001cf55b */ _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 001cf4ba to 001cf4c4 has its CatchHandler @ 001cf559 */ std::__cxx11::string::_M_construct<char_const*>(local_68,param_2,param_2 + sVar5); /* try { // try from 001cf4c5 to 001cf4df has its CatchHandler @ 001cf53e */ 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 001cf4e3 to 001cf50f has its CatchHandler @ 001cf510 */ _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; }
56,823
check_mb_gb18030_valid
eloqsql/libmariadb/libmariadb/ma_charset.c
static unsigned int check_mb_gb18030_valid(const char * start, const char * end) { if (end - start <= 1 || !is_gb18030_odd(start[0])) { return 0; } if (is_gb18030_even_2(start[1])) { return 2; } else if (end - start > 3 && is_gb18030_even_4(start[1]) && is_gb18030_odd(start[2]) && is_gb18030_even_4(start[3])) { return 4; } return 0; }
O0
c
check_mb_gb18030_valid: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rax movq -0x10(%rbp), %rcx subq %rcx, %rax cmpq $0x1, %rax jle 0x4bbeb movq -0x10(%rbp), %rax movzbl (%rax), %ecx movl $0x81, %eax cmpl %ecx, %eax jg 0x4bbeb movq -0x10(%rbp), %rax movzbl (%rax), %eax cmpl $0xfe, %eax jle 0x4bbf7 movl $0x0, -0x4(%rbp) jmp 0x4bcbd movq -0x10(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x40, %eax cmpl %ecx, %eax jg 0x4bc15 movq -0x10(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0x7e, %eax jle 0x4bc35 movq -0x10(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x80, %eax cmpl %ecx, %eax jg 0x4bc3e movq -0x10(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0xfe, %eax jg 0x4bc3e movl $0x2, -0x4(%rbp) jmp 0x4bcbd movq -0x18(%rbp), %rax movq -0x10(%rbp), %rcx subq %rcx, %rax cmpq $0x3, %rax jle 0x4bcb4 movq -0x10(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x30, %eax cmpl %ecx, %eax jg 0x4bcb4 movq -0x10(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0x39, %eax jg 0x4bcb4 movq -0x10(%rbp), %rax movzbl 0x2(%rax), %ecx movl $0x81, %eax cmpl %ecx, %eax jg 0x4bcb4 movq -0x10(%rbp), %rax movzbl 0x2(%rax), %eax cmpl $0xfe, %eax jg 0x4bcb4 movq -0x10(%rbp), %rax movzbl 0x3(%rax), %ecx movl $0x30, %eax cmpl %ecx, %eax jg 0x4bcb4 movq -0x10(%rbp), %rax movzbl 0x3(%rax), %eax cmpl $0x39, %eax jg 0x4bcb4 movl $0x4, -0x4(%rbp) jmp 0x4bcbd jmp 0x4bcb6 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopw %cs:(%rax,%rax)
check_mb_gb18030_valid: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_18] mov rcx, [rbp+var_10] sub rax, rcx cmp rax, 1 jle short loc_4BBEB mov rax, [rbp+var_10] movzx ecx, byte ptr [rax] mov eax, 81h cmp eax, ecx jg short loc_4BBEB mov rax, [rbp+var_10] movzx eax, byte ptr [rax] cmp eax, 0FEh jle short loc_4BBF7 loc_4BBEB: mov [rbp+var_4], 0 jmp loc_4BCBD loc_4BBF7: mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+1] mov eax, 40h ; '@' cmp eax, ecx jg short loc_4BC15 mov rax, [rbp+var_10] movzx eax, byte ptr [rax+1] cmp eax, 7Eh ; '~' jle short loc_4BC35 loc_4BC15: mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+1] mov eax, 80h cmp eax, ecx jg short loc_4BC3E mov rax, [rbp+var_10] movzx eax, byte ptr [rax+1] cmp eax, 0FEh jg short loc_4BC3E loc_4BC35: mov [rbp+var_4], 2 jmp short loc_4BCBD loc_4BC3E: mov rax, [rbp+var_18] mov rcx, [rbp+var_10] sub rax, rcx cmp rax, 3 jle short loc_4BCB4 mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+1] mov eax, 30h ; '0' cmp eax, ecx jg short loc_4BCB4 mov rax, [rbp+var_10] movzx eax, byte ptr [rax+1] cmp eax, 39h ; '9' jg short loc_4BCB4 mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+2] mov eax, 81h cmp eax, ecx jg short loc_4BCB4 mov rax, [rbp+var_10] movzx eax, byte ptr [rax+2] cmp eax, 0FEh jg short loc_4BCB4 mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+3] mov eax, 30h ; '0' cmp eax, ecx jg short loc_4BCB4 mov rax, [rbp+var_10] movzx eax, byte ptr [rax+3] cmp eax, 39h ; '9' jg short loc_4BCB4 mov [rbp+var_4], 4 jmp short loc_4BCBD loc_4BCB4: jmp short $+2 loc_4BCB6: mov [rbp+var_4], 0 loc_4BCBD: mov eax, [rbp+var_4] pop rbp retn
long long check_mb_gb18030_valid(unsigned __int8 *a1, long long a2) { if ( a2 - (long long)a1 <= 1 || *a1 < 0x81u || *a1 == 255 ) { return 0; } else if ( (a1[1] < 0x40u || a1[1] > 0x7Eu) && (a1[1] < 0x80u || a1[1] == 255) ) { if ( a2 - (long long)a1 <= 3 || a1[1] < 0x30u || a1[1] > 0x39u || a1[2] < 0x81u || a1[2] == 255 || a1[3] < 0x30u || a1[3] > 0x39u ) { return 0; } else { return 4; } } else { return 2; } }
check_mb_gb18030_valid: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] SUB RAX,RCX CMP RAX,0x1 JLE 0x0014bbeb MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX] MOV EAX,0x81 CMP EAX,ECX JG 0x0014bbeb MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX] CMP EAX,0xfe JLE 0x0014bbf7 LAB_0014bbeb: MOV dword ptr [RBP + -0x4],0x0 JMP 0x0014bcbd LAB_0014bbf7: MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x40 CMP EAX,ECX JG 0x0014bc15 MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0x7e JLE 0x0014bc35 LAB_0014bc15: MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x80 CMP EAX,ECX JG 0x0014bc3e MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0xfe JG 0x0014bc3e LAB_0014bc35: MOV dword ptr [RBP + -0x4],0x2 JMP 0x0014bcbd LAB_0014bc3e: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] SUB RAX,RCX CMP RAX,0x3 JLE 0x0014bcb4 MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x30 CMP EAX,ECX JG 0x0014bcb4 MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0x39 JG 0x0014bcb4 MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x2] MOV EAX,0x81 CMP EAX,ECX JG 0x0014bcb4 MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x2] CMP EAX,0xfe JG 0x0014bcb4 MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x3] MOV EAX,0x30 CMP EAX,ECX JG 0x0014bcb4 MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x3] CMP EAX,0x39 JG 0x0014bcb4 MOV dword ptr [RBP + -0x4],0x4 JMP 0x0014bcbd LAB_0014bcb4: JMP 0x0014bcb6 LAB_0014bcb6: MOV dword ptr [RBP + -0x4],0x0 LAB_0014bcbd: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int4 check_mb_gb18030_valid(byte *param_1,long param_2) { int4 local_c; if (((param_2 - (long)param_1 < 2) || (*param_1 < 0x81)) || (*param_1 == 0xff)) { local_c = 0; } else if (((param_1[1] < 0x40) || (0x7e < param_1[1])) && ((param_1[1] < 0x80 || (param_1[1] == 0xff)))) { if (((param_2 - (long)param_1 < 4) || (param_1[1] < 0x30)) || ((0x39 < param_1[1] || ((((param_1[2] < 0x81 || (0xfe < param_1[2])) || (param_1[3] < 0x30)) || (0x39 < param_1[3]) ))))) { local_c = 0; } else { local_c = 4; } } else { local_c = 2; } return local_c; }
56,824
PtrToSegment
seiftnesse[P]memoryallocator/src/custom_alloc_util.c
segment_t *PtrToSegment(void *ptr) { if (!ptr) { HEAP_LOG("Cannot convert NULL pointer to segment\n"); return NULL; } // Calculate segment address based on alignment and metadata size uintptr_t addr = (uintptr_t) ptr; addr &= ~(ALIGNMENT - 1); // Round down to alignment boundary addr -= sizeof(segment_t); segment_t *s = (segment_t *) addr; // Verify segment is valid if (debug_mode && s->magic != SEGMENT_MAGIC) { HEAP_LOG("CRITICAL: Invalid magic number in segment at %p (ptr=%p)\n", s, ptr); return NULL; } HEAP_LOG("User pointer %p converted to segment %p\n", ptr, s); return s; }
O0
c
PtrToSegment: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) cmpq $0x0, -0x10(%rbp) jne 0x4089 movq $0x0, -0x8(%rbp) jmp 0x40dc movq -0x10(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax andq $-0x10, %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax subq $0x30, %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x20(%rbp) leaq 0x4105078(%rip), %rax # 0x4109130 cmpl $0x0, (%rax) je 0x40d4 movq -0x20(%rbp), %rax cmpl $0xcafebafe, 0x28(%rax) # imm = 0xCAFEBAFE je 0x40d4 movq $0x0, -0x8(%rbp) jmp 0x40dc movq -0x20(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax popq %rbp retq nopw %cs:(%rax,%rax)
PtrToSegment: push rbp mov rbp, rsp mov [rbp+var_10], rdi cmp [rbp+var_10], 0 jnz short loc_4089 mov [rbp+var_8], 0 jmp short loc_40DC loc_4089: mov rax, [rbp+var_10] mov [rbp+var_18], rax mov rax, [rbp+var_18] and rax, 0FFFFFFFFFFFFFFF0h mov [rbp+var_18], rax mov rax, [rbp+var_18] sub rax, 30h ; '0' mov [rbp+var_18], rax mov rax, [rbp+var_18] mov [rbp+var_20], rax lea rax, debug_mode cmp dword ptr [rax], 0 jz short loc_40D4 mov rax, [rbp+var_20] cmp dword ptr [rax+28h], 0CAFEBAFEh jz short loc_40D4 mov [rbp+var_8], 0 jmp short loc_40DC loc_40D4: mov rax, [rbp+var_20] mov [rbp+var_8], rax loc_40DC: mov rax, [rbp+var_8] pop rbp retn
unsigned long long PtrToSegment(long long a1) { if ( !a1 ) return 0LL; if ( !debug_mode || *(_DWORD *)((char *)&qword_28 + (a1 & 0xFFFFFFFFFFFFFFF0LL) - 48) == -889275650 ) return (a1 & 0xFFFFFFFFFFFFFFF0LL) - 48; return 0LL; }
PtrToSegment: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI CMP qword ptr [RBP + -0x10],0x0 JNZ 0x00104089 MOV qword ptr [RBP + -0x8],0x0 JMP 0x001040dc LAB_00104089: MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x18] AND RAX,-0x10 MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x18] SUB RAX,0x30 MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x20],RAX LEA RAX,[0x4209130] CMP dword ptr [RAX],0x0 JZ 0x001040d4 MOV RAX,qword ptr [RBP + -0x20] CMP dword ptr [RAX + 0x28],0xcafebafe JZ 0x001040d4 MOV qword ptr [RBP + -0x8],0x0 JMP 0x001040dc LAB_001040d4: MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x8],RAX LAB_001040dc: MOV RAX,qword ptr [RBP + -0x8] POP RBP RET
long PtrToSegment(ulong param_1) { long local_10; if (param_1 == 0) { local_10 = 0; } else { local_10 = (param_1 & 0xfffffffffffffff0) - 0x30; if ((debug_mode != 0) && (*(int *)((param_1 & 0xfffffffffffffff0) - 8) != -0x35014502)) { local_10 = 0; } } return local_10; }
56,825
my_read_charset_file
eloqsql/mysys/charset.c
static my_bool my_read_charset_file(MY_CHARSET_LOADER *loader, const char *filename, myf myflags) { uchar *buf; int fd; size_t len, tmp_len; MY_STAT stat_info; if (!my_stat(filename, &stat_info, MYF(myflags)) || ((len= (uint)stat_info.st_size) > MY_MAX_ALLOWED_BUF) || !(buf= (uchar*) my_malloc(key_memory_charset_loader,len,myflags))) return TRUE; if ((fd= mysql_file_open(key_file_charset, filename, O_RDONLY, myflags)) < 0) goto error; tmp_len= mysql_file_read(fd, buf, len, myflags); mysql_file_close(fd, myflags); if (tmp_len != len) goto error; if (my_parse_charset_xml(loader, (char *) buf, len)) { my_printf_error(EE_UNKNOWN_CHARSET, "Error while parsing '%s': %s\n", MYF(0), filename, loader->error); goto error; } my_free(buf); return FALSE; error: my_free(buf); return TRUE; }
O3
c
my_read_charset_file: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xf8, %rsp movq %rdx, %r12 movq %rsi, %r14 movq %rdi, %rbx leaq -0x120(%rbp), %rsi movq %r14, %rdi callq 0x9fa23 testq %rax, %rax je 0x93808 movl -0xf0(%rbp), %r13d cmpq $0x100000, %r13 # imm = 0x100000 ja 0x93808 leaq 0xb74b34(%rip), %rax # 0xc08224 movl (%rax), %edi movq %r13, %rsi movq %r12, %rdx callq 0x9fd41 testq %rax, %rax je 0x93808 movq %rax, %r15 movq %rbx, -0x38(%rbp) leaq 0xb741ac(%rip), %rax # 0xc078c0 movl (%rax), %esi leaq 0x2f28f3(%rip), %rax # 0x386010 movq (%rax), %rax leaq -0x90(%rbp), %rdi leaq -0x48(%rbp), %rbx movl $0x2, %edx movq %r14, %rcx movq %rbx, %r8 callq *0x148(%rax) movq %rax, (%rbx) testq %rax, %rax jne 0x9381a movq %r14, %rdi xorl %esi, %esi movq %r12, %rdx callq 0xa0370 movl %eax, %ebx testl %ebx, %ebx js 0x93800 leaq 0x2f28aa(%rip), %rax # 0x386010 movq (%rax), %rax leaq -0x90(%rbp), %rdi movl %ebx, %esi movl $0x6, %edx callq *0x158(%rax) testq %rax, %rax jne 0x93863 movl %ebx, %edi movq %r15, %rsi movq %r13, %rdx movq %r12, %rcx callq 0xa0930 movq %rax, -0x30(%rbp) leaq 0x2f286f(%rip), %rax # 0x386010 movq (%rax), %rax leaq -0x90(%rbp), %rdi movl %ebx, %esi movl $0x4, %edx callq *0x158(%rax) testq %rax, %rax jne 0x938d7 movl %ebx, %edi movq %r12, %rsi callq 0xa0515 cmpq %r13, -0x30(%rbp) jne 0x93800 movq -0x38(%rbp), %rdi movq %r15, %rsi movq %r13, %rdx callq 0xd0afc testb %al, %al je 0x93800 leaq 0x48570(%rip), %rsi # 0xdbd5b movl $0x16, %edi xorl %edx, %edx movq %r14, %rcx movq -0x38(%rbp), %r8 xorl %eax, %eax callq 0x9e0dd movq %r15, %rdi callq 0x9ff6e addq $0xf8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x2f27ef(%rip), %rcx # 0x386010 movq (%rcx), %rcx leaq 0x484f7(%rip), %rsi # 0xdbd22 movq %rax, %rdi movl $0x223, %edx # imm = 0x223 callq *0x1f0(%rcx) movq %r14, %rdi xorl %esi, %esi movq %r12, %rdx callq 0xa0370 movl %eax, %ebx leaq 0x2f27c1(%rip), %rax # 0x386010 movq (%rax), %rax movq -0x48(%rbp), %rdi movl %ebx, %esi callq *0x200(%rax) jmp 0x93757 movq %rax, %rcx leaq 0x2f27a3(%rip), %rax # 0x386010 movq (%rax), %rax leaq 0x484ab(%rip), %rdx # 0xdbd22 movq %rcx, -0x40(%rbp) movq %rcx, %rdi movq %r13, %rsi movl $0x225, %ecx # imm = 0x225 callq *0x210(%rax) movl %ebx, %edi movq %r15, %rsi movq %r13, %rdx movq %r12, %rcx callq 0xa0930 xorl %esi, %esi testq %rax, %rax movl $0x0, %ecx cmoveq %r13, %rcx cmpq $-0x1, %rax movq %rax, -0x30(%rbp) cmovneq %rax, %rsi testb $0x6, %r12b cmovneq %rcx, %rsi leaq 0x2f274b(%rip), %rax # 0x386010 movq (%rax), %rax movq -0x40(%rbp), %rdi callq *0x218(%rax) jmp 0x9379a movq %rax, %rdi movl %ebx, %esi movq %r12, %rdx callq 0x2e8a4 jmp 0x937cb
my_read_charset_file: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 0F8h mov r12, rdx mov r14, rsi mov rbx, rdi lea rsi, [rbp+var_120] mov rdi, r14 call my_stat test rax, rax jz loc_93808 mov r13d, [rbp+var_F0] cmp r13, offset xmmword_100000 ja loc_93808 lea rax, key_memory_charset_loader mov edi, [rax] mov rsi, r13 mov rdx, r12 call my_malloc test rax, rax jz loc_93808 mov r15, rax mov [rbp+var_38], rbx lea rax, key_file_charset mov esi, [rax] lea rax, PSI_server mov rax, [rax] lea rdi, [rbp+var_90] lea rbx, [rbp+var_48] mov edx, 2 mov rcx, r14 mov r8, rbx call qword ptr [rax+148h] mov [rbx], rax test rax, rax jnz loc_9381A mov rdi, r14 xor esi, esi mov rdx, r12 call my_open mov ebx, eax loc_93757: test ebx, ebx js loc_93800 lea rax, PSI_server mov rax, [rax] lea rdi, [rbp+var_90] mov esi, ebx mov edx, 6 call qword ptr [rax+158h] test rax, rax jnz loc_93863 mov edi, ebx mov rsi, r15 mov rdx, r13 mov rcx, r12 call my_read mov [rbp+var_30], rax loc_9379A: lea rax, PSI_server mov rax, [rax] lea rdi, [rbp+var_90] mov esi, ebx mov edx, 4 call qword ptr [rax+158h] test rax, rax jnz loc_938D7 mov edi, ebx mov rsi, r12 call my_close loc_937CB: cmp [rbp+var_30], r13 jnz short loc_93800 mov rdi, [rbp+var_38] mov rsi, r15 mov rdx, r13 call my_parse_charset_xml test al, al jz short loc_93800 lea rsi, aErrorWhilePars; "Error while parsing '%s': %s\n" mov edi, 16h xor edx, edx mov rcx, r14 mov r8, [rbp+var_38] xor eax, eax call my_printf_error loc_93800: mov rdi, r15 call my_free loc_93808: add rsp, 0F8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_9381A: lea rcx, PSI_server mov rcx, [rcx] lea rsi, aWorkspaceLlm4b_20; "/workspace/llm4binary/github2025/eloqsq"... mov rdi, rax mov edx, 223h call qword ptr [rcx+1F0h] mov rdi, r14 xor esi, esi mov rdx, r12 call my_open mov ebx, eax lea rax, PSI_server mov rax, [rax] mov rdi, [rbp+var_48] mov esi, ebx call qword ptr [rax+200h] jmp loc_93757 loc_93863: mov rcx, rax lea rax, PSI_server mov rax, [rax] lea rdx, aWorkspaceLlm4b_20; "/workspace/llm4binary/github2025/eloqsq"... mov [rbp+var_40], rcx mov rdi, rcx mov rsi, r13 mov ecx, 225h call qword ptr [rax+210h] mov edi, ebx mov rsi, r15 mov rdx, r13 mov rcx, r12 call my_read xor esi, esi test rax, rax mov ecx, 0 cmovz rcx, r13 cmp rax, 0FFFFFFFFFFFFFFFFh mov [rbp+var_30], rax cmovnz rsi, rax test r12b, 6 cmovnz rsi, rcx lea rax, PSI_server mov rax, [rax] mov rdi, [rbp+var_40] call qword ptr [rax+218h] jmp loc_9379A loc_938D7: mov rdi, rax mov esi, ebx mov rdx, r12 call my_read_charset_file_cold_1 jmp loc_937CB
long long my_read_charset_file(long long a1, long long a2, long long a3) { int v4; // r14d long long result; // rax long long v6; // r13 long long v7; // r15 long long v8; // rax long long v9; // rbx long long v10; // rax long long v11; // rax int v12; // r9d long long v13; // rax long long v14; // rdx long long v15; // rsi long long v16; // rcx char v17[48]; // [rsp+0h] [rbp-120h] BYREF unsigned int v18; // [rsp+30h] [rbp-F0h] _BYTE v19[72]; // [rsp+90h] [rbp-90h] BYREF long long v20; // [rsp+D8h] [rbp-48h] BYREF long long v21; // [rsp+E0h] [rbp-40h] long long v22; // [rsp+E8h] [rbp-38h] long long v23; // [rsp+F0h] [rbp-30h] v4 = a2; result = my_stat(a2, v17, a3); if ( result ) { v6 = v18; if ( v18 <= (unsigned long long)&xmmword_100000 ) { result = my_malloc(key_memory_charset_loader, v18, a3); if ( result ) { v7 = result; v22 = a1; v8 = ((long long ( *)(_BYTE *, _QWORD, long long, long long, long long *))PSI_server[41])( v19, key_file_charset, 2LL, a2, &v20); v20 = v8; if ( v8 ) { ((void ( *)(long long, const char *, long long))PSI_server[62])( v8, "/workspace/llm4binary/github2025/eloqsql/mysys/charset.c", 547LL); v9 = (unsigned int)my_open(a2, 0LL, a3); ((void ( *)(long long, long long))PSI_server[64])(v20, v9); } else { LODWORD(v9) = my_open(a2, 0LL, a3); } if ( (int)v9 >= 0 ) { v10 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v19, (unsigned int)v9, 6LL); if ( v10 ) { v21 = v10; ((void ( *)(long long, long long, const char *, long long))PSI_server[66])( v10, v6, "/workspace/llm4binary/github2025/eloqsql/mysys/charset.c", 549LL); v13 = my_read((unsigned int)v9, v7, v6, a3); v15 = 0LL; v16 = 0LL; if ( !v13 ) v16 = v6; v23 = v13; if ( v13 != -1 ) v15 = v13; if ( (a3 & 6) != 0 ) v15 = v16; ((void ( *)(long long, long long, long long, long long))PSI_server[67])(v21, v15, v14, v16); } else { v23 = my_read((unsigned int)v9, v7, v6, a3); } v11 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v19, (unsigned int)v9, 4LL); if ( v11 ) my_read_charset_file_cold_1(v11, v9, a3); else my_close((unsigned int)v9, a3); if ( v23 == v6 ) { if ( (unsigned __int8)my_parse_charset_xml(v22, v7, v6) ) my_printf_error(22, (unsigned int)"Error while parsing '%s': %s\n", 0, v4, v22, v12); } } return my_free(v7); } } } return result; }
my_read_charset_file: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xf8 MOV R12,RDX MOV R14,RSI MOV RBX,RDI LEA RSI,[RBP + -0x120] MOV RDI,R14 CALL 0x0019fa23 TEST RAX,RAX JZ 0x00193808 MOV R13D,dword ptr [RBP + -0xf0] CMP R13,0x100000 JA 0x00193808 LEA RAX,[0xd08224] MOV EDI,dword ptr [RAX] MOV RSI,R13 MOV RDX,R12 CALL 0x0019fd41 TEST RAX,RAX JZ 0x00193808 MOV R15,RAX MOV qword ptr [RBP + -0x38],RBX LEA RAX,[0xd078c0] MOV ESI,dword ptr [RAX] LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDI,[RBP + -0x90] LEA RBX,[RBP + -0x48] MOV EDX,0x2 MOV RCX,R14 MOV R8,RBX CALL qword ptr [RAX + 0x148] MOV qword ptr [RBX],RAX TEST RAX,RAX JNZ 0x0019381a MOV RDI,R14 XOR ESI,ESI MOV RDX,R12 CALL 0x001a0370 MOV EBX,EAX LAB_00193757: TEST EBX,EBX JS 0x00193800 LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDI,[RBP + -0x90] MOV ESI,EBX MOV EDX,0x6 CALL qword ptr [RAX + 0x158] TEST RAX,RAX JNZ 0x00193863 MOV EDI,EBX MOV RSI,R15 MOV RDX,R13 MOV RCX,R12 CALL 0x001a0930 MOV qword ptr [RBP + -0x30],RAX LAB_0019379a: LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDI,[RBP + -0x90] MOV ESI,EBX MOV EDX,0x4 CALL qword ptr [RAX + 0x158] TEST RAX,RAX JNZ 0x001938d7 MOV EDI,EBX MOV RSI,R12 CALL 0x001a0515 LAB_001937cb: CMP qword ptr [RBP + -0x30],R13 JNZ 0x00193800 MOV RDI,qword ptr [RBP + -0x38] MOV RSI,R15 MOV RDX,R13 CALL 0x001d0afc TEST AL,AL JZ 0x00193800 LEA RSI,[0x1dbd5b] MOV EDI,0x16 XOR EDX,EDX MOV RCX,R14 MOV R8,qword ptr [RBP + -0x38] XOR EAX,EAX CALL 0x0019e0dd LAB_00193800: MOV RDI,R15 CALL 0x0019ff6e LAB_00193808: ADD RSP,0xf8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0019381a: LEA RCX,[0x486010] MOV RCX,qword ptr [RCX] LEA RSI,[0x1dbd22] MOV RDI,RAX MOV EDX,0x223 CALL qword ptr [RCX + 0x1f0] MOV RDI,R14 XOR ESI,ESI MOV RDX,R12 CALL 0x001a0370 MOV EBX,EAX LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] MOV RDI,qword ptr [RBP + -0x48] MOV ESI,EBX CALL qword ptr [RAX + 0x200] JMP 0x00193757 LAB_00193863: MOV RCX,RAX LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDX,[0x1dbd22] MOV qword ptr [RBP + -0x40],RCX MOV RDI,RCX MOV RSI,R13 MOV ECX,0x225 CALL qword ptr [RAX + 0x210] MOV EDI,EBX MOV RSI,R15 MOV RDX,R13 MOV RCX,R12 CALL 0x001a0930 XOR ESI,ESI TEST RAX,RAX MOV ECX,0x0 CMOVZ RCX,R13 CMP RAX,-0x1 MOV qword ptr [RBP + -0x30],RAX CMOVNZ RSI,RAX TEST R12B,0x6 CMOVNZ RSI,RCX LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] MOV RDI,qword ptr [RBP + -0x40] CALL qword ptr [RAX + 0x218] JMP 0x0019379a LAB_001938d7: MOV RDI,RAX MOV ESI,EBX MOV RDX,R12 CALL 0x0012e8a4 JMP 0x001937cb
void my_read_charset_file(int8 param_1,int8 param_2,ulong param_3) { char cVar1; int iVar2; long lVar3; long lVar4; ulong uVar5; ulong uVar6; ulong uVar7; int1 local_128 [48]; uint local_f8; int1 local_98 [72]; long local_50; long local_48; int8 local_40; ulong local_38; lVar3 = my_stat(param_2,local_128); if ((lVar3 != 0) && (uVar7 = (ulong)local_f8, uVar7 < 0x100001)) { lVar3 = my_malloc(key_memory_charset_loader,uVar7,param_3); if (lVar3 != 0) { local_40 = param_1; local_50 = (**(code **)(PSI_server + 0x148))(local_98,key_file_charset,2,param_2,&local_50); if (local_50 == 0) { iVar2 = my_open(param_2,0,param_3); } else { (**(code **)(PSI_server + 0x1f0)) (local_50,"/workspace/llm4binary/github2025/eloqsql/mysys/charset.c",0x223); iVar2 = my_open(param_2,0,param_3); (**(code **)(PSI_server + 0x200))(local_50,iVar2); } if (-1 < iVar2) { lVar4 = (**(code **)(PSI_server + 0x158))(local_98,iVar2,6); if (lVar4 == 0) { local_38 = my_read(iVar2,lVar3,uVar7,param_3); } else { local_48 = lVar4; (**(code **)(PSI_server + 0x210)) (lVar4,uVar7,"/workspace/llm4binary/github2025/eloqsql/mysys/charset.c",0x225); local_38 = my_read(iVar2,lVar3,uVar7,param_3); uVar5 = 0; if (local_38 == 0) { uVar5 = uVar7; } uVar6 = 0; if (local_38 != 0xffffffffffffffff) { uVar6 = local_38; } if ((param_3 & 6) != 0) { uVar6 = uVar5; } (**(code **)(PSI_server + 0x218))(local_48,uVar6); } lVar4 = (**(code **)(PSI_server + 0x158))(local_98,iVar2,4); if (lVar4 == 0) { my_close(iVar2,param_3); } else { my_read_charset_file_cold_1(lVar4,iVar2,param_3); } if (local_38 == uVar7) { cVar1 = my_parse_charset_xml(local_40,lVar3,uVar7); if (cVar1 != '\0') { my_printf_error(0x16,"Error while parsing \'%s\': %s\n",0,param_2,local_40); } } } my_free(lVar3); } } return; }
56,826
js_string_substring
bluesky950520[P]quickjs/quickjs.c
static JSValue js_string_substring(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSValue str, ret; int a, b, start, end; JSString *p; str = JS_ToStringCheckObject(ctx, this_val); if (JS_IsException(str)) return str; p = JS_VALUE_GET_STRING(str); if (JS_ToInt32Clamp(ctx, &a, argv[0], 0, p->len, 0)) { JS_FreeValue(ctx, str); return JS_EXCEPTION; } b = p->len; if (!JS_IsUndefined(argv[1])) { if (JS_ToInt32Clamp(ctx, &b, argv[1], 0, p->len, 0)) { JS_FreeValue(ctx, str); return JS_EXCEPTION; } } if (a < b) { start = a; end = b; } else { start = b; end = a; } ret = js_sub_string(ctx, p, start, end); JS_FreeValue(ctx, str); return ret; }
O2
c
js_string_substring: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %r8, %r13 movq %rdi, %r15 callq 0x3de40 movq %rax, %rbx movq %rdx, %r14 cmpl $0x6, %r14d je 0x6bed6 movl $0x7fffffff, %ebp # imm = 0x7FFFFFFF movl 0x4(%rbx), %r9d andl %ebp, %r9d movq (%r13), %rdx movq 0x8(%r13), %rcx andl $0x0, (%rsp) leaq 0x14(%rsp), %rsi xorl %r12d, %r12d movq %r15, %rdi xorl %r8d, %r8d callq 0x24f85 testl %eax, %eax je 0x6be6b pushq $0x6 popq %r13 jmp 0x6bec2 andl 0x4(%rbx), %ebp movl %ebp, 0x10(%rsp) movq 0x18(%r13), %rcx cmpl $0x3, %ecx je 0x6bea1 movq 0x10(%r13), %rdx andl $0x0, (%rsp) leaq 0x10(%rsp), %rsi xorl %r12d, %r12d movq %r15, %rdi xorl %r8d, %r8d movl %ebp, %r9d callq 0x24f85 testl %eax, %eax jne 0x6be65 movl 0x10(%rsp), %ebp movl 0x14(%rsp), %eax cmpl %ebp, %eax movl %ebp, %ecx cmovgl %eax, %ecx cmovll %eax, %ebp movq %r15, %rdi movq %rbx, %rsi movl %ebp, %edx callq 0x31dcd movq %rax, %r12 movq %rdx, %r13 movq %r15, %rdi movq %rbx, %rsi movq %r14, %rdx callq 0x1bbce movq %r12, %rbx movq %r13, %r14 movq %rbx, %rax movq %r14, %rdx addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
js_string_substring: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov r13, r8 mov r15, rdi call JS_ToStringCheckObject mov rbx, rax mov r14, rdx cmp r14d, 6 jz loc_6BED6 mov ebp, 7FFFFFFFh mov r9d, [rbx+4] and r9d, ebp mov rdx, [r13+0] mov rcx, [r13+8] and [rsp+48h+var_48], 0 lea rsi, [rsp+48h+var_34] xor r12d, r12d mov rdi, r15 xor r8d, r8d call JS_ToInt32Clamp test eax, eax jz short loc_6BE6B loc_6BE65: push 6 pop r13 jmp short loc_6BEC2 loc_6BE6B: and ebp, [rbx+4] mov [rsp+48h+var_38], ebp mov rcx, [r13+18h] cmp ecx, 3 jz short loc_6BEA1 mov rdx, [r13+10h] and [rsp+48h+var_48], 0 lea rsi, [rsp+48h+var_38] xor r12d, r12d mov rdi, r15 xor r8d, r8d mov r9d, ebp call JS_ToInt32Clamp test eax, eax jnz short loc_6BE65 mov ebp, [rsp+48h+var_38] loc_6BEA1: mov eax, [rsp+48h+var_34] cmp eax, ebp mov ecx, ebp cmovg ecx, eax cmovl ebp, eax mov rdi, r15 mov rsi, rbx mov edx, ebp call js_sub_string mov r12, rax mov r13, rdx loc_6BEC2: mov rdi, r15 mov rsi, rbx mov rdx, r14 call JS_FreeValue mov rbx, r12 mov r14, r13 loc_6BED6: mov rax, rbx mov rdx, r14 add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
_DWORD * js_string_substring( long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14) { long long v15; // rax _DWORD *v16; // rbx long long v17; // rdx long long v18; // r14 long long v19; // r12 int v20; // ebp long long v21; // rcx int v22; // ecx int v24; // [rsp+10h] [rbp-38h] BYREF int v25[13]; // [rsp+14h] [rbp-34h] BYREF v15 = JS_ToStringCheckObject(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14); v16 = (_DWORD *)v15; v18 = v17; if ( (_DWORD)v17 != 6 ) { v19 = 0LL; if ( (unsigned int)JS_ToInt32Clamp( a1, v25, *(_DWORD **)a5, *(_QWORD *)(a5 + 8), 0, *(_DWORD *)(v15 + 4) & 0x7FFFFFFF, 0) ) { LABEL_12: JS_FreeValue(a1, (long long)v16, v18); return (_DWORD *)v19; } v20 = v16[1] & 0x7FFFFFFF; v24 = v20; v21 = *(_QWORD *)(a5 + 24); if ( (_DWORD)v21 != 3 ) { v19 = 0LL; if ( (unsigned int)JS_ToInt32Clamp(a1, &v24, *(_DWORD **)(a5 + 16), v21, 0, v20, 0) ) goto LABEL_12; v20 = v24; } v22 = v20; if ( v25[0] > v20 ) v22 = v25[0]; if ( v25[0] < v20 ) v20 = v25[0]; v19 = js_sub_string(a1, v16, (unsigned int)v20, v22); goto LABEL_12; } return v16; }
js_string_substring: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV R13,R8 MOV R15,RDI CALL 0x0013de40 MOV RBX,RAX MOV R14,RDX CMP R14D,0x6 JZ 0x0016bed6 MOV EBP,0x7fffffff MOV R9D,dword ptr [RBX + 0x4] AND R9D,EBP MOV RDX,qword ptr [R13] MOV RCX,qword ptr [R13 + 0x8] AND dword ptr [RSP],0x0 LEA RSI,[RSP + 0x14] XOR R12D,R12D MOV RDI,R15 XOR R8D,R8D CALL 0x00124f85 TEST EAX,EAX JZ 0x0016be6b LAB_0016be65: PUSH 0x6 POP R13 JMP 0x0016bec2 LAB_0016be6b: AND EBP,dword ptr [RBX + 0x4] MOV dword ptr [RSP + 0x10],EBP MOV RCX,qword ptr [R13 + 0x18] CMP ECX,0x3 JZ 0x0016bea1 MOV RDX,qword ptr [R13 + 0x10] AND dword ptr [RSP],0x0 LEA RSI,[RSP + 0x10] XOR R12D,R12D MOV RDI,R15 XOR R8D,R8D MOV R9D,EBP CALL 0x00124f85 TEST EAX,EAX JNZ 0x0016be65 MOV EBP,dword ptr [RSP + 0x10] LAB_0016bea1: MOV EAX,dword ptr [RSP + 0x14] CMP EAX,EBP MOV ECX,EBP CMOVG ECX,EAX CMOVL EBP,EAX MOV RDI,R15 MOV RSI,RBX MOV EDX,EBP CALL 0x00131dcd MOV R12,RAX MOV R13,RDX LAB_0016bec2: MOV RDI,R15 MOV RSI,RBX MOV RDX,R14 CALL 0x0011bbce MOV RBX,R12 MOV R14,R13 LAB_0016bed6: MOV RAX,RBX MOV RDX,R14 ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int1 [16] js_string_substring(int8 param_1) { uint uVar1; uint uVar2; int iVar3; long lVar4; int8 *in_R8; int1 auVar5 [16]; int1 auVar6 [16]; uint local_38; uint local_34; auVar5 = JS_ToStringCheckObject(); lVar4 = auVar5._0_8_; if (auVar5._8_4_ == 6) { return auVar5; } iVar3 = JS_ToInt32Clamp(param_1,&local_34,*in_R8,in_R8[1],0,*(uint *)(lVar4 + 4) & 0x7fffffff,0); if (iVar3 == 0) { local_38 = *(uint *)(lVar4 + 4) & 0x7fffffff; if (((int)in_R8[3] == 3) || (iVar3 = JS_ToInt32Clamp(param_1,&local_38,in_R8[2],in_R8[3],0,local_38,0), iVar3 == 0)) { uVar2 = local_38; if ((int)local_38 < (int)local_34) { uVar2 = local_34; } uVar1 = local_38; if ((int)local_34 < (int)local_38) { uVar1 = local_34; } auVar6 = js_sub_string(param_1,lVar4,uVar1,uVar2); goto LAB_0016bec2; } } auVar6 = ZEXT816(6) << 0x40; LAB_0016bec2: JS_FreeValue(param_1,lVar4,auVar5._8_8_); return auVar6; }
56,827
LefDefParser::defrRead(_IO_FILE*, char const*, void*, int)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/def/def/defrReader.cpp
int defrRead(FILE *f, const char *fName, defiUserData uData, int case_sensitive) { int status; delete defContext.data; defrData *defData = new defrData(defContext.callbacks, defContext.settings, defContext.session); defContext.data = defData; // lex_init struct stat statbuf; /* 4/11/2003 - Remove file lefrRWarning.log from directory if it exist */ /* pcr 569729 */ if (stat("defRWarning.log", &statbuf) != -1) { /* file exist, remove it */ if (!defContext.settings->LogFileAppend) { remove("defRWarning.log"); } } // Propagate Settings parameter to Data. if (defData->settings->reader_case_sensitive_set) { defData->names_case_sensitive = defData->session->reader_case_sensitive; } else if (defData->VersionNum > 5.5) { defData->names_case_sensitive = true; } defData->session->FileName = (char*) fName; defData->File = f; defData->session->UserData = uData; defData->session->reader_case_sensitive = case_sensitive; // Create a path pointer that is all ready to go just in case // we need it later. defData->NeedPathData = ( ((defData->callbacks->NetCbk || defData->callbacks->SNetCbk) && defData->settings->AddPathToNet) || defData->callbacks->PathCbk) ? 1 : 0; if (defData->NeedPathData) { defData->PathObj.Init(); } status = defyyparse(defData); return status; }
O0
cpp
LefDefParser::defrRead(_IO_FILE*, char const*, void*, int): subq $0xe8, %rsp movq %rdi, 0xe0(%rsp) movq %rsi, 0xd8(%rsp) movq %rdx, 0xd0(%rsp) movl %ecx, 0xcc(%rsp) leaq 0x72e23(%rip), %rax # 0x932f0 movq 0x18(%rax), %rax movq %rax, 0x18(%rsp) cmpq $0x0, %rax je 0x204f5 movq 0x18(%rsp), %rdi callq 0x50d10 movq 0x18(%rsp), %rdi movl $0x92d0, %esi # imm = 0x92D0 callq 0x7260 movl $0x92d0, %edi # imm = 0x92D0 callq 0x7250 movq %rax, %rdi movq %rdi, %rax movq %rax, 0x10(%rsp) leaq 0x72ddf(%rip), %rax # 0x932f0 movq (%rax), %rdx movq 0x8(%rax), %rsi movq 0x10(%rax), %rcx callq 0x4fd90 jmp 0x20523 movq 0x10(%rsp), %rax movq %rax, 0xc0(%rsp) movq 0xc0(%rsp), %rcx leaq 0x72db1(%rip), %rax # 0x932f0 movq %rcx, 0x18(%rax) leaq 0x52fdf(%rip), %rdi # 0x73529 leaq 0x20(%rsp), %rsi callq 0x71f0 cmpl $-0x1, %eax je 0x205a1 leaq 0x72d90(%rip), %rax # 0x932f0 movq (%rax), %rax cmpl $0x0, 0x58(%rax) jne 0x2059f leaq 0x52fb9(%rip), %rdi # 0x73529 callq 0x73c0 jmp 0x2059f movq 0x10(%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0xb8(%rsp) movl %eax, 0xb4(%rsp) movl $0x92d0, %esi # imm = 0x92D0 callq 0x7260 jmp 0x20747 jmp 0x205a1 movq 0xc0(%rsp), %rax movq 0x9250(%rax), %rax cmpl $0x0, 0xb4(%rax) je 0x205db movq 0xc0(%rsp), %rax movq 0x9258(%rax), %rax movl 0x8(%rax), %ecx movq 0xc0(%rsp), %rax movl %ecx, 0x13c(%rax) jmp 0x2060d movq 0xc0(%rsp), %rax movsd 0x260(%rax), %xmm0 movsd 0x5008d(%rip), %xmm1 # 0x70680 ucomisd %xmm1, %xmm0 jbe 0x2060b movq 0xc0(%rsp), %rax movl $0x1, 0x13c(%rax) jmp 0x2060d movq 0xd8(%rsp), %rcx movq 0xc0(%rsp), %rax movq 0x9258(%rax), %rax movq %rcx, (%rax) movq 0xe0(%rsp), %rcx movq 0xc0(%rsp), %rax movq %rcx, 0x92c8(%rax) movq 0xd0(%rsp), %rcx movq 0xc0(%rsp), %rax movq 0x9258(%rax), %rax movq %rcx, 0x10(%rax) movl 0xcc(%rsp), %ecx movq 0xc0(%rsp), %rax movq 0x9258(%rax), %rax movl %ecx, 0x8(%rax) movq 0xc0(%rsp), %rax movq 0x9248(%rax), %rax cmpq $0x0, 0xa0(%rax) jne 0x206a4 movq 0xc0(%rsp), %rax movq 0x9248(%rax), %rax cmpq $0x0, 0x1b8(%rax) je 0x206c2 movq 0xc0(%rsp), %rax movq 0x9250(%rax), %rcx movb $0x1, %al cmpl $0x0, 0xa4(%rcx) movb %al, 0xf(%rsp) jne 0x206e0 movq 0xc0(%rsp), %rax movq 0x9248(%rax), %rax cmpq $0x0, 0xc8(%rax) setne %al movb %al, 0xf(%rsp) movb 0xf(%rsp), %dl xorl %ecx, %ecx movl $0x1, %eax testb $0x1, %dl cmovnel %eax, %ecx movq 0xc0(%rsp), %rax movl %ecx, 0x1264(%rax) movq 0xc0(%rsp), %rax cmpl $0x0, 0x1264(%rax) je 0x20724 movq 0xc0(%rsp), %rdi addq $0x278, %rdi # imm = 0x278 callq 0x1a740 movq 0xc0(%rsp), %rdi callq 0x51d50 movl %eax, 0xc8(%rsp) movl 0xc8(%rsp), %eax addq $0xe8, %rsp retq movq 0xb8(%rsp), %rdi callq 0x73b0 nopw %cs:(%rax,%rax)
_ZN12LefDefParser8defrReadEP8_IO_FILEPKcPvi: sub rsp, 0E8h mov [rsp+0E8h+var_8], rdi; LefDefParser::defiNet * mov [rsp+0E8h+var_10], rsi; LefDefParser::defiSite * mov [rsp+0E8h+var_18], rdx; LefDefParser::defiSite * mov [rsp+0E8h+var_1C], ecx lea rax, _ZN12LefDefParser10defContextE; LefDefParser::defContext mov rax, [rax+18h] mov [rsp+0E8h+var_D0], rax; int cmp rax, 0 jz short loc_204F5 mov rdi, [rsp+0E8h+var_D0]; this call _ZN12LefDefParser8defrDataD2Ev; LefDefParser::defrData::~defrData() mov rdi, [rsp+0E8h+var_D0]; void * mov esi, 92D0h; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_204F5: mov edi, 92D0h; unsigned __int64 call __Znwm; operator new(ulong) mov rdi, rax; int mov rax, rdi mov [rsp+0E8h+var_D8], rax; __int64 lea rax, _ZN12LefDefParser10defContextE; LefDefParser::defContext mov rdx, [rax]; int mov rsi, [rax+8]; int mov rcx, [rax+10h]; int call _ZN12LefDefParser8defrDataC2EPKNS_13defrCallbacksEPKNS_12defrSettingsEPNS_11defrSessionE; LefDefParser::defrData::defrData(LefDefParser::defrCallbacks const*,LefDefParser::defrSettings const*,LefDefParser::defrSession *) jmp short $+2 loc_20523: mov rax, [rsp+0E8h+var_D8] mov [rsp+0E8h+var_28], rax mov rcx, [rsp+0E8h+var_28] lea rax, _ZN12LefDefParser10defContextE; LefDefParser::defContext mov [rax+18h], rcx lea rdi, aDefrwarningLog; "defRWarning.log" lea rsi, [rsp+0E8h+var_C8]; LefDefParser::defrData * call _stat cmp eax, 0FFFFFFFFh jz short loc_205A1 lea rax, _ZN12LefDefParser10defContextE; LefDefParser::defContext mov rax, [rax] cmp dword ptr [rax+58h], 0 jnz short loc_2059F lea rdi, aDefrwarningLog; "defRWarning.log" call _remove jmp short loc_2059F mov rdi, [rsp+arg_8]; void * mov rcx, rax mov eax, edx mov [rsp+arg_B0], rcx mov [rsp+arg_AC], eax mov esi, 92D0h; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp loc_20747 loc_2059F: jmp short $+2 loc_205A1: mov rax, [rsp+0E8h+var_28] mov rax, [rax+9250h] cmp dword ptr [rax+0B4h], 0 jz short loc_205DB mov rax, [rsp+0E8h+var_28] mov rax, [rax+9258h] mov ecx, [rax+8] mov rax, [rsp+0E8h+var_28] mov [rax+13Ch], ecx jmp short loc_2060D loc_205DB: mov rax, [rsp+0E8h+var_28] movsd xmm0, qword ptr [rax+260h] movsd xmm1, cs:qword_70680 ucomisd xmm0, xmm1 jbe short loc_2060B mov rax, [rsp+0E8h+var_28] mov dword ptr [rax+13Ch], 1 loc_2060B: jmp short $+2 loc_2060D: mov rcx, [rsp+0E8h+var_10] mov rax, [rsp+0E8h+var_28] mov rax, [rax+9258h] mov [rax], rcx mov rcx, [rsp+0E8h+var_8] mov rax, [rsp+0E8h+var_28] mov [rax+92C8h], rcx mov rcx, [rsp+0E8h+var_18] mov rax, [rsp+0E8h+var_28] mov rax, [rax+9258h] mov [rax+10h], rcx mov ecx, [rsp+0E8h+var_1C] mov rax, [rsp+0E8h+var_28] mov rax, [rax+9258h] mov [rax+8], ecx mov rax, [rsp+0E8h+var_28] mov rax, [rax+9248h] cmp qword ptr [rax+0A0h], 0 jnz short loc_206A4 mov rax, [rsp+0E8h+var_28] mov rax, [rax+9248h] cmp qword ptr [rax+1B8h], 0 jz short loc_206C2 loc_206A4: mov rax, [rsp+0E8h+var_28] mov rcx, [rax+9250h] mov al, 1 cmp dword ptr [rcx+0A4h], 0 mov [rsp+0E8h+var_D9], al jnz short loc_206E0 loc_206C2: mov rax, [rsp+0E8h+var_28] mov rax, [rax+9248h] cmp qword ptr [rax+0C8h], 0 setnz al mov [rsp+0E8h+var_D9], al loc_206E0: mov dl, [rsp+0E8h+var_D9] xor ecx, ecx mov eax, 1 test dl, 1 cmovnz ecx, eax mov rax, [rsp+0E8h+var_28] mov [rax+1264h], ecx mov rax, [rsp+0E8h+var_28] cmp dword ptr [rax+1264h], 0 jz short loc_20724 mov rdi, [rsp+0E8h+var_28] add rdi, 278h; this call _ZN12LefDefParser8defiPath4InitEv; LefDefParser::defiPath::Init(void) loc_20724: mov rdi, [rsp+0E8h+var_28]; this call _ZN12LefDefParser10defyyparseEPNS_8defrDataE; LefDefParser::defyyparse(LefDefParser::defrData *) mov [rsp+0E8h+var_20], eax mov eax, [rsp+0E8h+var_20] add rsp, 0E8h retn loc_20747: mov rdi, [rsp+arg_B0] call __Unwind_Resume
defrRead: SUB RSP,0xe8 MOV qword ptr [RSP + 0xe0],RDI MOV qword ptr [RSP + 0xd8],RSI MOV qword ptr [RSP + 0xd0],RDX MOV dword ptr [RSP + 0xcc],ECX LEA RAX,[0x1932f0] MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RSP + 0x18],RAX CMP RAX,0x0 JZ 0x001204f5 MOV RDI,qword ptr [RSP + 0x18] CALL 0x00150d10 MOV RDI,qword ptr [RSP + 0x18] MOV ESI,0x92d0 CALL 0x00107260 LAB_001204f5: MOV EDI,0x92d0 CALL 0x00107250 MOV RDI,RAX MOV RAX,RDI MOV qword ptr [RSP + 0x10],RAX LEA RAX,[0x1932f0] MOV RDX,qword ptr [RAX] MOV RSI,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RAX + 0x10] LAB_0012051c: CALL 0x0014fd90 LAB_00120521: JMP 0x00120523 LAB_00120523: MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0xc0],RAX MOV RCX,qword ptr [RSP + 0xc0] LEA RAX,[0x1932f0] MOV qword ptr [RAX + 0x18],RCX LEA RDI,[0x173529] LEA RSI,[RSP + 0x20] CALL 0x001071f0 CMP EAX,-0x1 JZ 0x001205a1 LEA RAX,[0x1932f0] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX + 0x58],0x0 JNZ 0x0012059f LEA RDI,[0x173529] CALL 0x001073c0 JMP 0x0012059f LAB_0012059f: JMP 0x001205a1 LAB_001205a1: MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x9250] CMP dword ptr [RAX + 0xb4],0x0 JZ 0x001205db MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x9258] MOV ECX,dword ptr [RAX + 0x8] MOV RAX,qword ptr [RSP + 0xc0] MOV dword ptr [RAX + 0x13c],ECX JMP 0x0012060d LAB_001205db: MOV RAX,qword ptr [RSP + 0xc0] MOVSD XMM0,qword ptr [RAX + 0x260] MOVSD XMM1,qword ptr [0x00170680] UCOMISD XMM0,XMM1 JBE 0x0012060b MOV RAX,qword ptr [RSP + 0xc0] MOV dword ptr [RAX + 0x13c],0x1 LAB_0012060b: JMP 0x0012060d LAB_0012060d: MOV RCX,qword ptr [RSP + 0xd8] MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x9258] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RSP + 0xe0] MOV RAX,qword ptr [RSP + 0xc0] MOV qword ptr [RAX + 0x92c8],RCX MOV RCX,qword ptr [RSP + 0xd0] MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x9258] MOV qword ptr [RAX + 0x10],RCX MOV ECX,dword ptr [RSP + 0xcc] MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x9258] MOV dword ptr [RAX + 0x8],ECX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x9248] CMP qword ptr [RAX + 0xa0],0x0 JNZ 0x001206a4 MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x9248] CMP qword ptr [RAX + 0x1b8],0x0 JZ 0x001206c2 LAB_001206a4: MOV RAX,qword ptr [RSP + 0xc0] MOV RCX,qword ptr [RAX + 0x9250] MOV AL,0x1 CMP dword ptr [RCX + 0xa4],0x0 MOV byte ptr [RSP + 0xf],AL JNZ 0x001206e0 LAB_001206c2: MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x9248] CMP qword ptr [RAX + 0xc8],0x0 SETNZ AL MOV byte ptr [RSP + 0xf],AL LAB_001206e0: MOV DL,byte ptr [RSP + 0xf] XOR ECX,ECX MOV EAX,0x1 TEST DL,0x1 CMOVNZ ECX,EAX MOV RAX,qword ptr [RSP + 0xc0] MOV dword ptr [RAX + 0x1264],ECX MOV RAX,qword ptr [RSP + 0xc0] CMP dword ptr [RAX + 0x1264],0x0 JZ 0x00120724 MOV RDI,qword ptr [RSP + 0xc0] ADD RDI,0x278 CALL 0x0011a740 LAB_00120724: MOV RDI,qword ptr [RSP + 0xc0] CALL 0x00151d50 MOV dword ptr [RSP + 0xc8],EAX MOV EAX,dword ptr [RSP + 0xc8] ADD RSP,0xe8 RET
/* LefDefParser::defrRead(_IO_FILE*, char const*, void*, int) */ int4 LefDefParser::defrRead(_IO_FILE *param_1,char *param_2,void *param_3,int param_4) { int iVar1; int4 uVar2; defrData *pdVar3; bool bVar4; stat local_c8; defrData *local_28; int local_1c; void *local_18; char *local_10; _IO_FILE *local_8; pdVar3 = DAT_00193308; local_1c = param_4; local_18 = param_3; local_10 = param_2; local_8 = param_1; if (DAT_00193308 != (defrData *)0x0) { defrData::~defrData(DAT_00193308); operator_delete(pdVar3,0x92d0); } pdVar3 = (defrData *)operator_new(0x92d0); /* try { // try from 0012051c to 00120520 has its CatchHandler @ 00120577 */ defrData::defrData(pdVar3,DAT_001932f8,defContext,DAT_00193300); DAT_00193308 = pdVar3; local_28 = pdVar3; iVar1 = stat("defRWarning.log",&local_c8); if ((iVar1 != -1) && (*(int *)(defContext + 0x58) == 0)) { remove("defRWarning.log"); } if (*(int *)(*(long *)(local_28 + 0x9250) + 0xb4) == 0) { if (DAT_00170680 < *(double *)(local_28 + 0x260)) { *(int4 *)(local_28 + 0x13c) = 1; } } else { *(int4 *)(local_28 + 0x13c) = *(int4 *)(*(long *)(local_28 + 0x9258) + 8); } **(int8 **)(local_28 + 0x9258) = local_10; *(_IO_FILE **)(local_28 + 0x92c8) = local_8; *(void **)(*(long *)(local_28 + 0x9258) + 0x10) = local_18; *(int *)(*(long *)(local_28 + 0x9258) + 8) = local_1c; if (((*(long *)(*(long *)(local_28 + 0x9248) + 0xa0) == 0) && (*(long *)(*(long *)(local_28 + 0x9248) + 0x1b8) == 0)) || (bVar4 = true, *(int *)(*(long *)(local_28 + 0x9250) + 0xa4) == 0)) { bVar4 = *(long *)(*(long *)(local_28 + 0x9248) + 200) != 0; } *(uint *)(local_28 + 0x1264) = (uint)bVar4; if (*(int *)(local_28 + 0x1264) != 0) { defiPath::Init((defiPath *)(local_28 + 0x278)); } uVar2 = defyyparse(local_28); return uVar2; }
56,828
nlohmann::json_abi_v3_11_3::detail::iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const>>::begin() const
monkey531[P]llama/common/json.hpp
iteration_proxy_value<IteratorType> begin() const noexcept { return iteration_proxy_value<IteratorType>(container->begin()); }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const>>::begin() const: pushq %r14 pushq %rbx subq $0x28, %rsp movq %rdi, %rbx movq (%rsi), %rax leaq 0x8(%rsp), %r14 movq %rax, (%r14) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%r14) movabsq $-0x8000000000000000, %rax # imm = 0x8000000000000000 movq %rax, 0x18(%r14) movq %r14, %rdi callq 0x917f4 movq %rbx, %rdi movq %r14, %rsi xorl %edx, %edx callq 0xba308 movq %rbx, %rax addq $0x28, %rsp popq %rbx popq %r14 retq nop
_ZNK8nlohmann16json_abi_v3_11_36detail15iteration_proxyINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEE5beginEv: push r14 push rbx sub rsp, 28h mov rbx, rdi mov rax, [rsi] lea r14, [rsp+38h+var_30] mov [r14], rax xorps xmm0, xmm0 movups xmmword ptr [r14+8], xmm0 mov rax, 8000000000000000h mov [r14+18h], rax mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE9set_beginEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::set_begin(void) mov rdi, rbx mov rsi, r14 xor edx, edx call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEEC2ESI_m; nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>>::iteration_proxy_value(nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>,ulong) mov rax, rbx add rsp, 28h pop rbx pop r14 retn
long long nlohmann::json_abi_v3_11_3::detail::iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>>::begin( long long a1, unsigned __int8 **a2) { unsigned __int8 *v3; // [rsp+8h] [rbp-30h] BYREF __int128 v4; // [rsp+10h] [rbp-28h] unsigned long long v5; // [rsp+20h] [rbp-18h] v3 = *a2; v4 = 0LL; v5 = 0x8000000000000000LL; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::set_begin(&v3); nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>>::iteration_proxy_value( a1, (__int128 *)&v3, 0LL); return a1; }
begin: PUSH R14 PUSH RBX SUB RSP,0x28 MOV RBX,RDI MOV RAX,qword ptr [RSI] LEA R14,[RSP + 0x8] MOV qword ptr [R14],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [R14 + 0x8],XMM0 MOV RAX,-0x8000000000000000 MOV qword ptr [R14 + 0x18],RAX MOV RDI,R14 CALL 0x001917f4 MOV RDI,RBX MOV RSI,R14 XOR EDX,EDX CALL 0x001ba308 MOV RAX,RBX ADD RSP,0x28 POP RBX POP R14 RET
/* nlohmann::json_abi_v3_11_3::detail::iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> const> >::begin() const */ void nlohmann::json_abi_v3_11_3::detail:: iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>> ::begin(void) { int8 *in_RSI; int8 local_30; int8 local_28; int8 uStack_20; int8 local_18; local_30 = *in_RSI; local_28 = 0; uStack_20 = 0; local_18 = 0x8000000000000000; iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::set_begin((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_30); iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>> ::iteration_proxy_value(); return; }
56,829
my_caseup_utf32
eloqsql/strings/ctype-ucs2.c
static size_t my_caseup_utf32(CHARSET_INFO *cs, const char *src, size_t srclen, char *dst, size_t dstlen) { my_wc_t wc; int res; const char *srcend= src + srclen; char *dstend= dst + dstlen; MY_UNICASE_INFO *uni_plane= cs->caseinfo; DBUG_ASSERT(srclen <= dstlen); while ((src < srcend) && (res= my_utf32_uni(cs, &wc, (uchar *)src, (uchar*) srcend)) > 0) { my_toupper_utf32(uni_plane, &wc); if (res != my_uni_utf32(cs, wc, (uchar*) dst, (uchar*) dstend)) break; src+= res; dst+= res; } return srclen; }
O3
c
my_caseup_utf32: movq %rdx, %rax cmpq $0x4, %rdx jl 0x932c5 pushq %rbp movq %rsp, %rbp pushq %rbx leaq (%rsi,%rax), %rdx addq %rcx, %r8 movq 0x78(%rdi), %rdi addq $0x4, %rcx movzbl (%rsi), %r9d shll $0x18, %r9d movzbl 0x1(%rsi), %r10d shll $0x10, %r10d orl %r9d, %r10d cmpl $0x10ffff, %r10d # imm = 0x10FFFF ja 0x932c3 movzbl 0x2(%rsi), %ebx shll $0x8, %ebx movzbl 0x3(%rsi), %r9d orq %r9, %rbx orq %r10, %rbx cmpq (%rdi), %rbx ja 0x93284 movq 0x8(%rdi), %r10 movl %ebx, %r11d shrl $0x8, %r11d movq (%r10,%r11,8), %r10 testq %r10, %r10 je 0x93284 leaq (%r9,%r9,2), %r9 movl (%r10,%r9,4), %ebx cmpq %r8, %rcx ja 0x932c3 cmpl $0x10ffff, %ebx # imm = 0x10FFFF ja 0x932c3 movb $0x0, -0x4(%rcx) movl %ebx, %r9d shrl $0x10, %r9d movb %r9b, -0x3(%rcx) movb %bh, -0x2(%rcx) movb %bl, -0x1(%rcx) leaq 0x4(%rsi), %r9 cmpq %rdx, %r9 jae 0x932c3 addq $0x8, %rsi addq $0x4, %rcx cmpq %rdx, %rsi movq %r9, %rsi jbe 0x93234 popq %rbx popq %rbp retq
my_caseup_utf32: mov rax, rdx cmp rdx, 4 jl locret_932C5 push rbp mov rbp, rsp push rbx lea rdx, [rsi+rax] add r8, rcx mov rdi, [rdi+78h] add rcx, 4 loc_93234: movzx r9d, byte ptr [rsi] shl r9d, 18h movzx r10d, byte ptr [rsi+1] shl r10d, 10h or r10d, r9d cmp r10d, offset unk_10FFFF ja short loc_932C3 movzx ebx, byte ptr [rsi+2] shl ebx, 8 movzx r9d, byte ptr [rsi+3] or rbx, r9 or rbx, r10 cmp rbx, [rdi] ja short loc_93284 mov r10, [rdi+8] mov r11d, ebx shr r11d, 8 mov r10, [r10+r11*8] test r10, r10 jz short loc_93284 lea r9, [r9+r9*2] mov ebx, [r10+r9*4] loc_93284: cmp rcx, r8 ja short loc_932C3 cmp ebx, offset unk_10FFFF ja short loc_932C3 mov byte ptr [rcx-4], 0 mov r9d, ebx shr r9d, 10h mov [rcx-3], r9b mov [rcx-2], bh mov [rcx-1], bl lea r9, [rsi+4] cmp r9, rdx jnb short loc_932C3 add rsi, 8 add rcx, 4 cmp rsi, rdx mov rsi, r9 jbe loc_93234 loc_932C3: pop rbx pop rbp locret_932C5: retn
long long my_caseup_utf32(long long a1, unsigned __int8 *a2, long long a3, long long a4, long long a5) { long long result; // rax unsigned long long v6; // rdx unsigned long long v7; // r8 unsigned long long *v8; // rdi unsigned long long v9; // rcx long long v10; // r10 long long v11; // r9 unsigned long long v12; // rbx long long v13; // r10 bool v14; // cc result = a3; if ( a3 >= 4 ) { v6 = (unsigned long long)&a2[a3]; v7 = a4 + a5; v8 = *(unsigned long long **)(a1 + 120); v9 = a4 + 4; do { v10 = (*a2 << 24) | (a2[1] << 16); if ( (unsigned int)v10 > (unsigned int)&unk_10FFFF ) break; v11 = a2[3]; v12 = v10 | v11 | (a2[2] << 8); if ( v12 <= *v8 ) { v13 = *(_QWORD *)(v8[1] + 8LL * ((unsigned int)v12 >> 8)); if ( v13 ) LODWORD(v12) = *(_DWORD *)(v13 + 12 * v11); } if ( v9 > v7 ) break; if ( (unsigned int)v12 > (unsigned int)&unk_10FFFF ) break; *(_BYTE *)(v9 - 4) = 0; *(_BYTE *)(v9 - 3) = BYTE2(v12); *(_BYTE *)(v9 - 2) = BYTE1(v12); *(_BYTE *)(v9 - 1) = v12; if ( (unsigned long long)(a2 + 4) >= v6 ) break; v9 += 4LL; v14 = (unsigned long long)(a2 + 8) <= v6; a2 += 4; } while ( v14 ); } return result; }
my_caseup_utf32: MOV RAX,RDX CMP RDX,0x4 JL 0x001932c5 PUSH RBP MOV RBP,RSP PUSH RBX LEA RDX,[RSI + RAX*0x1] ADD R8,RCX MOV RDI,qword ptr [RDI + 0x78] ADD RCX,0x4 LAB_00193234: MOVZX R9D,byte ptr [RSI] SHL R9D,0x18 MOVZX R10D,byte ptr [RSI + 0x1] SHL R10D,0x10 OR R10D,R9D CMP R10D,0x10ffff JA 0x001932c3 MOVZX EBX,byte ptr [RSI + 0x2] SHL EBX,0x8 MOVZX R9D,byte ptr [RSI + 0x3] OR RBX,R9 OR RBX,R10 CMP RBX,qword ptr [RDI] JA 0x00193284 MOV R10,qword ptr [RDI + 0x8] MOV R11D,EBX SHR R11D,0x8 MOV R10,qword ptr [R10 + R11*0x8] TEST R10,R10 JZ 0x00193284 LEA R9,[R9 + R9*0x2] MOV EBX,dword ptr [R10 + R9*0x4] LAB_00193284: CMP RCX,R8 JA 0x001932c3 CMP EBX,0x10ffff JA 0x001932c3 MOV byte ptr [RCX + -0x4],0x0 MOV R9D,EBX SHR R9D,0x10 MOV byte ptr [RCX + -0x3],R9B MOV byte ptr [RCX + -0x2],BH MOV byte ptr [RCX + -0x1],BL LEA R9,[RSI + 0x4] CMP R9,RDX JNC 0x001932c3 ADD RSI,0x8 ADD RCX,0x4 CMP RSI,RDX MOV RSI,R9 JBE 0x00193234 LAB_001932c3: POP RBX POP RBP LAB_001932c5: RET
void my_caseup_utf32(long param_1,byte *param_2,long param_3,long param_4,long param_5) { ulong *puVar1; long lVar2; ulong uVar3; ulong uVar4; byte *pbVar5; byte *pbVar6; uint uVar7; if (3 < param_3) { puVar1 = *(ulong **)(param_1 + 0x78); uVar3 = param_4 + 4; pbVar5 = param_2; while (uVar7 = (uint)pbVar5[1] << 0x10 | (uint)*pbVar5 << 0x18, uVar7 < 0x110000) { uVar4 = (ulong)CONCAT11(pbVar5[2],pbVar5[3]) | (ulong)uVar7; if ((uVar4 <= *puVar1) && (lVar2 = *(long *)(puVar1[1] + (uVar4 >> 8) * 8), lVar2 != 0)) { uVar4 = (ulong)*(uint *)(lVar2 + (ulong)pbVar5[3] * 0xc); } if ((ulong)(param_5 + param_4) < uVar3) { return; } if (0x10ffff < (uint)uVar4) { return; } *(int1 *)(uVar3 - 4) = 0; *(char *)(uVar3 - 3) = (char)(uVar4 >> 0x10); *(char *)(uVar3 - 2) = (char)(uVar4 >> 8); *(char *)(uVar3 - 1) = (char)uVar4; if (param_2 + param_3 <= pbVar5 + 4) { return; } pbVar6 = pbVar5 + 8; uVar3 = uVar3 + 4; pbVar5 = pbVar5 + 4; if (param_2 + param_3 < pbVar6) { return; } } } return; }
56,830
my_strdup
eloqsql/mysys/my_malloc.c
char *my_strdup(PSI_memory_key key, const char *from, myf my_flags) { char *ptr; size_t length= strlen(from)+1; DBUG_ENTER("my_strdup"); if ((ptr= (char*) my_malloc(key, length, my_flags))) memcpy(ptr, from, length); DBUG_RETURN(ptr); }
O0
c
my_strdup: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movl %edi, -0x4(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x10(%rbp), %rdi callq 0x25150 addq $0x1, %rax movq %rax, -0x28(%rbp) movl -0x4(%rbp), %edi movq -0x28(%rbp), %rsi movq -0x18(%rbp), %rdx callq 0x300f0 movq %rax, -0x20(%rbp) cmpq $0x0, %rax je 0x305bf movq -0x20(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x28(%rbp), %rdx callq 0x252e0 jmp 0x305c1 movq -0x20(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
my_strdup: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_4], edi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rdi, [rbp+var_10] call _strlen add rax, 1 mov [rbp+var_28], rax mov edi, [rbp+var_4] mov rsi, [rbp+var_28] mov rdx, [rbp+var_18] call my_malloc mov [rbp+var_20], rax cmp rax, 0 jz short loc_305BF mov rdi, [rbp+var_20] mov rsi, [rbp+var_10] mov rdx, [rbp+var_28] call _memcpy loc_305BF: jmp short $+2 loc_305C1: mov rax, [rbp+var_20] mov [rbp+var_30], rax mov rax, [rbp+var_30] add rsp, 30h pop rbp retn
long long my_strdup(unsigned int a1, long long a2, int a3) { unsigned long long v4; // [rsp+8h] [rbp-28h] long long v5; // [rsp+10h] [rbp-20h] v4 = strlen(a2) + 1; v5 = my_malloc(a1, v4, a3); if ( v5 ) memcpy(v5, a2, v4); return v5; }
my_strdup: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV dword ptr [RBP + -0x4],EDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RDI,qword ptr [RBP + -0x10] CALL 0x00125150 ADD RAX,0x1 MOV qword ptr [RBP + -0x28],RAX MOV EDI,dword ptr [RBP + -0x4] MOV RSI,qword ptr [RBP + -0x28] MOV RDX,qword ptr [RBP + -0x18] CALL 0x001300f0 MOV qword ptr [RBP + -0x20],RAX CMP RAX,0x0 JZ 0x001305bf MOV RDI,qword ptr [RBP + -0x20] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x28] CALL 0x001252e0 LAB_001305bf: JMP 0x001305c1 LAB_001305c1: MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] ADD RSP,0x30 POP RBP RET
void * my_strdup(int4 param_1,char *param_2,int8 param_3) { size_t sVar1; void *__dest; sVar1 = strlen(param_2); __dest = (void *)my_malloc(param_1,sVar1 + 1,param_3); if (__dest != (void *)0x0) { memcpy(__dest,param_2,sVar1 + 1); } return __dest; }
56,831
my_strdup
eloqsql/mysys/my_malloc.c
char *my_strdup(PSI_memory_key key, const char *from, myf my_flags) { char *ptr; size_t length= strlen(from)+1; DBUG_ENTER("my_strdup"); if ((ptr= (char*) my_malloc(key, length, my_flags))) memcpy(ptr, from, length); DBUG_RETURN(ptr); }
O3
c
my_strdup: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rdx, %r15 movq %rsi, %rbx movl %edi, %r12d movq %rsi, %rdi callq 0x24150 movq %rax, %r14 incq %r14 movl %r12d, %edi movq %r14, %rsi movq %r15, %rdx callq 0x2b4f5 testq %rax, %rax je 0x2b803 movq %rax, %rdi movq %rbx, %rsi movq %r14, %rdx popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp jmp 0x24300 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
my_strdup: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx mov r15, rdx mov rbx, rsi mov r12d, edi mov rdi, rsi call _strlen mov r14, rax inc r14 mov edi, r12d mov rsi, r14 mov rdx, r15 call my_malloc test rax, rax jz short loc_2B803 mov rdi, rax mov rsi, rbx mov rdx, r14 pop rbx pop r12 pop r14 pop r15 pop rbp jmp _memcpy loc_2B803: pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long my_strdup(unsigned int a1, long long a2, int a3) { unsigned long long v4; // r14 long long result; // rax v4 = strlen(a2) + 1; result = my_malloc(a1, v4, a3); if ( result ) return memcpy(result, a2, v4); return result; }
my_strdup: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R15,RDX MOV RBX,RSI MOV R12D,EDI MOV RDI,RSI CALL 0x00124150 MOV R14,RAX INC R14 MOV EDI,R12D MOV RSI,R14 MOV RDX,R15 CALL 0x0012b4f5 TEST RAX,RAX JZ 0x0012b803 MOV RDI,RAX MOV RSI,RBX MOV RDX,R14 POP RBX POP R12 POP R14 POP R15 POP RBP JMP 0x00124300 LAB_0012b803: POP RBX POP R12 POP R14 POP R15 POP RBP RET
void my_strdup(int4 param_1,char *param_2,int8 param_3) { size_t sVar1; void *__dest; sVar1 = strlen(param_2); __dest = (void *)my_malloc(param_1,sVar1 + 1,param_3); if (__dest != (void *)0x0) { memcpy(__dest,param_2,sVar1 + 1); return; } return; }
56,832
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 (&) [22], char const*>(char const (&) [22], char const*&&)
monkey531[P]llama/common/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 (&) [22], char const*>(char const (&) [22], char const*&&): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx leaq 0x10(%rdi), %r13 movq %r13, (%rdi) movq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) movq %rsi, %rdi callq 0x1b410 movq %rax, %r12 movq (%r14), %rdi callq 0x1b410 addq %rax, %r12 movq %rbx, %rdi movq %r12, %rsi callq 0x1be70 movq %rbx, %rdi movq %r15, %rsi callq 0x1c240 movq (%r14), %rsi movq %rbx, %rdi callq 0x1c240 movq %rbx, %rax popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq movq %rax, %r14 movq (%rbx), %rdi cmpq %r13, %rdi je 0xb006d movq (%r13), %rsi incq %rsi callq 0x1b930 movq %r14, %rdi callq 0x1c0d0 nop
_ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA22_KcPS9_EEET_DpOT0_: push r15 push r14 push r13 push r12 push rbx mov r14, rdx mov r15, rsi mov rbx, rdi lea r13, [rdi+10h] mov [rdi], r13 mov qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 mov rdi, rsi call _strlen mov r12, rax mov rdi, [r14] call _strlen add r12, rax mov rdi, rbx mov rsi, r12 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong) mov rdi, rbx mov rsi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) mov rsi, [r14] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) mov rax, rbx pop rbx pop r12 pop r13 pop r14 pop r15 retn mov r14, rax mov rdi, [rbx]; void * cmp rdi, r13 jz short loc_B006D mov rsi, [r13+0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_B006D: mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[22],char const*>( long long a1, long long a2, _QWORD *a3) { long long v4; // r12 long long v5; // rax *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v4 = strlen(a2); v5 = strlen(*a3); std::string::reserve(a1, v5 + v4); std::string::append(a1, a2); std::string::append(a1, *a3); return a1; }
concat<std::__cxx11::string,char_const(&)[22],char_const*>: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX MOV R14,RDX MOV R15,RSI MOV RBX,RDI LEA R13,[RDI + 0x10] MOV qword ptr [RDI],R13 MOV qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 MOV RDI,RSI CALL 0x0011b410 MOV R12,RAX MOV RDI,qword ptr [R14] CALL 0x0011b410 ADD R12,RAX LAB_001b0028: MOV RDI,RBX MOV RSI,R12 CALL 0x0011be70 MOV RDI,RBX MOV RSI,R15 CALL 0x0011c240 MOV RSI,qword ptr [R14] MOV RDI,RBX CALL 0x0011c240 LAB_001b0049: MOV RAX,RBX POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* std::__cxx11::string nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string, char const (&) [22], char const*>(char const (&) [22], char const*&&) */ detail * __thiscall nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[22],char_const*> (detail *this,char *param_1,char **param_2) { *(detail **)this = this + 0x10; *(int8 *)(this + 8) = 0; this[0x10] = (detail)0x0; strlen(param_1); strlen(*param_2); /* try { // try from 001b0028 to 001b0048 has its CatchHandler @ 001b0056 */ std::__cxx11::string::reserve((ulong)this); std::__cxx11::string::append((char *)this); std::__cxx11::string::append((char *)this); return this; }
56,833
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 (&) [22], char const*>(char const (&) [22], char const*&&)
monkey531[P]llama/common/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 (&) [22], char const*>(char const (&) [22], char const*&&): pushq %r15 pushq %r14 pushq %rbx movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx leaq 0x10(%rdi), %rax movq %rax, (%rdi) andq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) movq %rsi, %rdi movq %rdx, %rsi callq 0x45697 movq %rbx, %rdi movq %rax, %rsi callq 0x23e90 movq %rbx, %rdi movq %r15, %rsi movq %r14, %rdx callq 0x8aa9c movq %rbx, %rax popq %rbx popq %r14 popq %r15 retq movq %rax, %r14 movq %rbx, %rdi callq 0x24348 movq %r14, %rdi callq 0x240e0
_ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA39_KcS8_EEET_DpOT0_: push r15 push r14 push rbx mov r14, rdx mov r15, rsi mov rbx, rdi 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 call _ZN8nlohmann16json_abi_v3_11_36detail13concat_lengthIJNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEmPKcDpRKT_; nlohmann::json_abi_v3_11_3::detail::concat_length<std::string>(char const*,std::string const&) mov rdi, rbx mov rsi, rax call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong) mov rdi, rbx mov rsi, r15 mov rdx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail11concat_intoINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERA39_KcJS8_ETnNSt9enable_ifIXsr24detect_string_can_appendIT_T0_EE5valueEiE4typeELi0EEEvRSD_OSE_DpOT1_ mov rax, rbx pop rbx pop r14 pop r15 retn mov r14, rax mov rdi, rbx; void * 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,char const(&)[39],std::string>( long long a1, long long a2, long long a3) { long long v4; // rax *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v4 = nlohmann::json_abi_v3_11_3::detail::concat_length<std::string>(a2, a3); std::string::reserve(a1, v4); ZN8nlohmann16json_abi_v3_11_36detail11concat_intoINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERA39_KcJS8_ETnNSt9enable_ifIXsr24detect_string_can_appendIT_T0_EE5valueEiE4typeELi0EEEvRSD_OSE_DpOT1_( a1, a2, a3); return a1; }
concat<std::__cxx11::string,char_const(&)[39],std::__cxx11::string>: PUSH R15 PUSH R14 PUSH RBX MOV R14,RDX MOV R15,RSI MOV RBX,RDI LEA RAX,[RDI + 0x10] MOV qword ptr [RDI],RAX AND qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 LAB_0018a995: MOV RDI,RSI MOV RSI,RDX CALL 0x00145697 MOV RDI,RBX MOV RSI,RAX CALL 0x00123e90 MOV RDI,RBX MOV RSI,R15 MOV RDX,R14 CALL 0x0018aa9c LAB_0018a9b9: MOV RAX,RBX POP RBX POP R14 POP R15 RET
/* std::__cxx11::string nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string, char const (&) [39], std::__cxx11::string >(char const (&) [39], std::__cxx11::string&&) */ detail * __thiscall nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,char_const(&)[39],std::__cxx11::string> (detail *this,char *param_1,string *param_2) { *(detail **)this = this + 0x10; *(int8 *)(this + 8) = 0; this[0x10] = (detail)0x0; /* try { // try from 0018a995 to 0018a9b8 has its CatchHandler @ 0018a9c2 */ concat_length<std::__cxx11::string>(param_1,param_2); std::__cxx11::string::reserve((ulong)this); _ZN8nlohmann16json_abi_v3_11_36detail11concat_intoINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERA39_KcJS8_ETnNSt9enable_ifIXsr24detect_string_can_appendIT_T0_EE5valueEiE4typeELi0EEEvRSD_OSE_DpOT1_ (this,param_1,param_2); return this; }
56,834
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 (&) [22], char const*>(char const (&) [22], char const*&&)
monkey531[P]llama/common/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 (&) [22], char const*>(char const (&) [22], 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 0x1b410 movq %rax, %rbp addq 0x8(%r12), %rbp movq %r15, %rdi callq 0x1b410 addq %rax, %rbp addq 0x8(%r14), %rbp movq %rbx, %rdi movq %rbp, %rsi callq 0x1be70 movq %rbx, %rdi movq %r13, %rsi callq 0x1c240 movq (%r12), %rsi movq 0x8(%r12), %rdx movq %rbx, %rdi callq 0x1b270 movq %rbx, %rdi movq %r15, %rsi callq 0x1c240 movq (%r14), %rsi movq 0x8(%r14), %rdx movq %rbx, %rdi callq 0x1b270 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 0xbbfda movq (%rsp), %rax movq (%rax), %rsi incq %rsi callq 0x1b930 movq %r14, %rdi callq 0x1c0d0
_ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA29_KcS8_RA5_S9_S8_EEET_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 add rbp, [r12+8] mov rdi, r15 call _strlen add rbp, rax add rbp, [r14+8] mov rdi, rbx mov rsi, rbp call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong) mov rdi, rbx mov rsi, r13 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, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) mov rsi, [r14] mov rdx, [r14+8] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) 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_BBFDA mov rax, [rsp+0] mov rsi, [rax] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_BBFDA: mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],std::string,char const(&)[5],std::string>( long long a1, long long a2, _QWORD *a3, long long a4, _QWORD *a5) { long long v8; // rbp long long v9; // rax *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v8 = a3[1] + strlen(a2); v9 = strlen(a4); std::string::reserve(a1, a5[1] + v9 + v8); std::string::append(a1, a2); std::string::_M_append(a1, *a3, a3[1]); std::string::append(a1, a4); std::string::_M_append(a1, *a5, a5[1]); return a1; }
concat<std::__cxx11::string,char_const(&)[29],std::__cxx11::string,char_const(&)[5],std::__cxx11::string>: 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,RSI CALL 0x0011b410 MOV RBP,RAX ADD RBP,qword ptr [R12 + 0x8] MOV RDI,R15 CALL 0x0011b410 ADD RBP,RAX ADD RBP,qword ptr [R14 + 0x8] LAB_001bbf6c: MOV RDI,RBX MOV RSI,RBP CALL 0x0011be70 MOV RDI,RBX MOV RSI,R13 CALL 0x0011c240 MOV RSI,qword ptr [R12] MOV RDX,qword ptr [R12 + 0x8] MOV RDI,RBX CALL 0x0011b270 MOV RDI,RBX MOV RSI,R15 CALL 0x0011c240 MOV RSI,qword ptr [R14] MOV RDX,qword ptr [R14 + 0x8] MOV RDI,RBX CALL 0x0011b270 LAB_001bbfad: 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 (&) [29], std::__cxx11::string, char const (&) [5], std::__cxx11::string >(char const (&) [29], std::__cxx11::string&&, char const (&) [5], std::__cxx11::string&&) */ detail * __thiscall nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,char_const(&)[29],std::__cxx11::string,char_const(&)[5],std::__cxx11::string> (detail *this,char *param_1,string *param_2,char *param_3,string *param_4) { *(detail **)this = this + 0x10; *(int8 *)(this + 8) = 0; this[0x10] = (detail)0x0; strlen(param_1); strlen(param_3); /* try { // try from 001bbf6c to 001bbfac has its CatchHandler @ 001bbfbf */ std::__cxx11::string::reserve((ulong)this); std::__cxx11::string::append((char *)this); std::__cxx11::string::_M_append((char *)this,*(ulong *)param_2); std::__cxx11::string::append((char *)this); std::__cxx11::string::_M_append((char *)this,*(ulong *)param_4); return this; }
56,835
ggml_ftype_to_ggml_type
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
enum ggml_type ggml_ftype_to_ggml_type(enum ggml_ftype ftype) { enum ggml_type wtype = GGML_TYPE_COUNT; switch (ftype) { case GGML_FTYPE_ALL_F32: wtype = GGML_TYPE_F32; break; case GGML_FTYPE_MOSTLY_F16: wtype = GGML_TYPE_F16; break; case GGML_FTYPE_MOSTLY_BF16: wtype = GGML_TYPE_BF16; break; case GGML_FTYPE_MOSTLY_Q4_0: wtype = GGML_TYPE_Q4_0; break; case GGML_FTYPE_MOSTLY_Q4_1: wtype = GGML_TYPE_Q4_1; break; case GGML_FTYPE_MOSTLY_Q5_0: wtype = GGML_TYPE_Q5_0; break; case GGML_FTYPE_MOSTLY_Q5_1: wtype = GGML_TYPE_Q5_1; break; case GGML_FTYPE_MOSTLY_Q8_0: wtype = GGML_TYPE_Q8_0; break; case GGML_FTYPE_MOSTLY_Q2_K: wtype = GGML_TYPE_Q2_K; break; case GGML_FTYPE_MOSTLY_Q3_K: wtype = GGML_TYPE_Q3_K; break; case GGML_FTYPE_MOSTLY_Q4_K: wtype = GGML_TYPE_Q4_K; break; case GGML_FTYPE_MOSTLY_Q5_K: wtype = GGML_TYPE_Q5_K; break; case GGML_FTYPE_MOSTLY_Q6_K: wtype = GGML_TYPE_Q6_K; break; case GGML_FTYPE_MOSTLY_IQ2_XXS: wtype = GGML_TYPE_IQ2_XXS; break; case GGML_FTYPE_MOSTLY_IQ2_XS: wtype = GGML_TYPE_IQ2_XS; break; case GGML_FTYPE_MOSTLY_IQ3_XXS: wtype = GGML_TYPE_IQ3_XXS; break; case GGML_FTYPE_MOSTLY_IQ1_S: wtype = GGML_TYPE_IQ1_S; break; case GGML_FTYPE_MOSTLY_IQ1_M: wtype = GGML_TYPE_IQ1_M; break; case GGML_FTYPE_MOSTLY_IQ4_NL: wtype = GGML_TYPE_IQ4_NL; break; case GGML_FTYPE_MOSTLY_IQ4_XS: wtype = GGML_TYPE_IQ4_XS; break; case GGML_FTYPE_MOSTLY_IQ3_S: wtype = GGML_TYPE_IQ3_S; break; case GGML_FTYPE_MOSTLY_IQ2_S: wtype = GGML_TYPE_IQ2_S; break; case GGML_FTYPE_UNKNOWN: wtype = GGML_TYPE_COUNT; break; case GGML_FTYPE_MOSTLY_Q4_1_SOME_F16: wtype = GGML_TYPE_COUNT; break; } GGML_ASSERT(wtype != GGML_TYPE_COUNT); return wtype; }
O0
c
ggml_ftype_to_ggml_type: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movl %edi, -0x4(%rbp) movl $0x27, -0x8(%rbp) movl -0x4(%rbp), %eax incl %eax movl %eax, %ecx movq %rcx, -0x10(%rbp) subl $0x19, %eax ja 0x4b50b movq -0x10(%rbp), %rax leaq 0x65c3f(%rip), %rcx # 0xb1050 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax movl $0x0, -0x8(%rbp) jmp 0x4b50b movl $0x1, -0x8(%rbp) jmp 0x4b50b movl $0x1e, -0x8(%rbp) jmp 0x4b50b movl $0x2, -0x8(%rbp) jmp 0x4b50b movl $0x3, -0x8(%rbp) jmp 0x4b50b movl $0x6, -0x8(%rbp) jmp 0x4b50b movl $0x7, -0x8(%rbp) jmp 0x4b50b movl $0x8, -0x8(%rbp) jmp 0x4b50b movl $0xa, -0x8(%rbp) jmp 0x4b50b movl $0xb, -0x8(%rbp) jmp 0x4b50b movl $0xc, -0x8(%rbp) jmp 0x4b50b movl $0xd, -0x8(%rbp) jmp 0x4b50b movl $0xe, -0x8(%rbp) jmp 0x4b50b movl $0x10, -0x8(%rbp) jmp 0x4b50b movl $0x11, -0x8(%rbp) jmp 0x4b50b movl $0x12, -0x8(%rbp) jmp 0x4b50b movl $0x13, -0x8(%rbp) jmp 0x4b50b movl $0x1d, -0x8(%rbp) jmp 0x4b50b movl $0x14, -0x8(%rbp) jmp 0x4b50b movl $0x17, -0x8(%rbp) jmp 0x4b50b movl $0x15, -0x8(%rbp) jmp 0x4b50b movl $0x16, -0x8(%rbp) jmp 0x4b50b movl $0x27, -0x8(%rbp) jmp 0x4b50b movl $0x27, -0x8(%rbp) cmpl $0x27, -0x8(%rbp) jne 0x4b532 leaq 0x6609f(%rip), %rdi # 0xb15b7 movl $0x502, %esi # imm = 0x502 leaq 0x660e5(%rip), %rdx # 0xb1609 leaq 0x661c7(%rip), %rcx # 0xb16f2 movb $0x0, %al callq 0x48a00 movl -0x8(%rbp), %eax addq $0x10, %rsp popq %rbp retq nopl (%rax,%rax)
ggml_ftype_to_ggml_type: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_4], edi mov [rbp+var_8], 27h ; ''' mov eax, [rbp+var_4] inc eax; switch 26 cases mov ecx, eax mov [rbp+var_10], rcx sub eax, 19h ja def_4B418; jumptable 000000000004B418 default case, cases 5,6 mov rax, [rbp+var_10] lea rcx, jpt_4B418 movsxd rax, ds:(jpt_4B418 - 0B1050h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_4B41A: mov [rbp+var_8], 0; jumptable 000000000004B418 case 0 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B426: mov [rbp+var_8], 1; jumptable 000000000004B418 case 1 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B432: mov [rbp+var_8], 1Eh; jumptable 000000000004B418 case 24 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B43E: mov [rbp+var_8], 2; jumptable 000000000004B418 case 2 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B44A: mov [rbp+var_8], 3; jumptable 000000000004B418 case 3 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B456: mov [rbp+var_8], 6; jumptable 000000000004B418 case 8 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B462: mov [rbp+var_8], 7; jumptable 000000000004B418 case 9 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B46E: mov [rbp+var_8], 8; jumptable 000000000004B418 case 7 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B47A: mov [rbp+var_8], 0Ah; jumptable 000000000004B418 case 10 jmp def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B486: mov [rbp+var_8], 0Bh; jumptable 000000000004B418 case 11 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B48F: mov [rbp+var_8], 0Ch; jumptable 000000000004B418 case 12 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B498: mov [rbp+var_8], 0Dh; jumptable 000000000004B418 case 13 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4A1: mov [rbp+var_8], 0Eh; jumptable 000000000004B418 case 14 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4AA: mov [rbp+var_8], 10h; jumptable 000000000004B418 case 15 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4B3: mov [rbp+var_8], 11h; jumptable 000000000004B418 case 16 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4BC: mov [rbp+var_8], 12h; jumptable 000000000004B418 case 17 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4C5: mov [rbp+var_8], 13h; jumptable 000000000004B418 case 18 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4CE: mov [rbp+var_8], 1Dh; jumptable 000000000004B418 case 23 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4D7: mov [rbp+var_8], 14h; jumptable 000000000004B418 case 19 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4E0: mov [rbp+var_8], 17h; jumptable 000000000004B418 case 22 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4E9: mov [rbp+var_8], 15h; jumptable 000000000004B418 case 20 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4F2: mov [rbp+var_8], 16h; jumptable 000000000004B418 case 21 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B4FB: mov [rbp+var_8], 27h ; '''; jumptable 000000000004B418 case -1 jmp short def_4B418; jumptable 000000000004B418 default case, cases 5,6 loc_4B504: mov [rbp+var_8], 27h ; '''; jumptable 000000000004B418 case 4 def_4B418: cmp [rbp+var_8], 27h ; '''; jumptable 000000000004B418 default case, cases 5,6 jnz short loc_4B532 lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov esi, 502h lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aWtypeGgmlTypeC; "wtype != GGML_TYPE_COUNT" mov al, 0 call _ggml_abort loc_4B532: mov eax, [rbp+var_8] add rsp, 10h pop rbp retn
long long ggml_ftype_to_ggml_type(int a1) { unsigned int v2; // [rsp+8h] [rbp-8h] v2 = 39; switch ( a1 ) { case -1: v2 = 39; break; case 0: v2 = 0; break; case 1: v2 = 1; break; case 2: v2 = 2; break; case 3: v2 = 3; break; case 4: v2 = 39; break; case 7: v2 = 8; break; case 8: v2 = 6; break; case 9: v2 = 7; break; case 10: v2 = 10; break; case 11: v2 = 11; break; case 12: v2 = 12; break; case 13: v2 = 13; break; case 14: v2 = 14; break; case 15: v2 = 16; break; case 16: v2 = 17; break; case 17: v2 = 18; break; case 18: v2 = 19; break; case 19: v2 = 20; break; case 20: v2 = 21; break; case 21: v2 = 22; break; case 22: v2 = 23; break; case 23: v2 = 29; break; case 24: v2 = 30; break; default: break; } if ( v2 == 39 ) ggml_abort( "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 1282, (long long)"GGML_ASSERT(%s) failed", "wtype != GGML_TYPE_COUNT"); return v2; }
ggml_ftype_to_ggml_type: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV dword ptr [RBP + -0x4],EDI MOV dword ptr [RBP + -0x8],0x27 MOV EAX,dword ptr [RBP + -0x4] INC EAX MOV ECX,EAX MOV qword ptr [RBP + -0x10],RCX SUB EAX,0x19 JA 0x0014b50b MOV RAX,qword ptr [RBP + -0x10] LEA RCX,[0x1b1050] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_0: MOV dword ptr [RBP + -0x8],0x0 JMP 0x0014b50b caseD_1: MOV dword ptr [RBP + -0x8],0x1 JMP 0x0014b50b caseD_18: MOV dword ptr [RBP + -0x8],0x1e JMP 0x0014b50b caseD_2: MOV dword ptr [RBP + -0x8],0x2 JMP 0x0014b50b caseD_3: MOV dword ptr [RBP + -0x8],0x3 JMP 0x0014b50b caseD_8: MOV dword ptr [RBP + -0x8],0x6 JMP 0x0014b50b caseD_9: MOV dword ptr [RBP + -0x8],0x7 JMP 0x0014b50b caseD_7: MOV dword ptr [RBP + -0x8],0x8 JMP 0x0014b50b caseD_a: MOV dword ptr [RBP + -0x8],0xa JMP 0x0014b50b caseD_b: MOV dword ptr [RBP + -0x8],0xb JMP 0x0014b50b caseD_c: MOV dword ptr [RBP + -0x8],0xc JMP 0x0014b50b caseD_d: MOV dword ptr [RBP + -0x8],0xd JMP 0x0014b50b caseD_e: MOV dword ptr [RBP + -0x8],0xe JMP 0x0014b50b caseD_f: MOV dword ptr [RBP + -0x8],0x10 JMP 0x0014b50b caseD_10: MOV dword ptr [RBP + -0x8],0x11 JMP 0x0014b50b caseD_11: MOV dword ptr [RBP + -0x8],0x12 JMP 0x0014b50b caseD_12: MOV dword ptr [RBP + -0x8],0x13 JMP 0x0014b50b caseD_17: MOV dword ptr [RBP + -0x8],0x1d JMP 0x0014b50b caseD_13: MOV dword ptr [RBP + -0x8],0x14 JMP 0x0014b50b caseD_16: MOV dword ptr [RBP + -0x8],0x17 JMP 0x0014b50b caseD_14: MOV dword ptr [RBP + -0x8],0x15 JMP 0x0014b50b caseD_15: MOV dword ptr [RBP + -0x8],0x16 JMP 0x0014b50b caseD_ffffffff: MOV dword ptr [RBP + -0x8],0x27 JMP 0x0014b50b caseD_4: MOV dword ptr [RBP + -0x8],0x27 caseD_5: CMP dword ptr [RBP + -0x8],0x27 JNZ 0x0014b532 LEA RDI,[0x1b15b7] MOV ESI,0x502 LEA RDX,[0x1b1609] LEA RCX,[0x1b16f2] MOV AL,0x0 CALL 0x00148a00 LAB_0014b532: MOV EAX,dword ptr [RBP + -0x8] ADD RSP,0x10 POP RBP RET
int ggml_ftype_to_ggml_type(int4 param_1) { int local_10; local_10 = 0x27; switch(param_1) { case 0: local_10 = 0; break; case 1: local_10 = 1; break; case 2: local_10 = 2; break; case 3: local_10 = 3; break; case 4: local_10 = 0x27; break; case 7: local_10 = 8; break; case 8: local_10 = 6; break; case 9: local_10 = 7; break; case 10: local_10 = 10; break; case 0xb: local_10 = 0xb; break; case 0xc: local_10 = 0xc; break; case 0xd: local_10 = 0xd; break; case 0xe: local_10 = 0xe; break; case 0xf: local_10 = 0x10; break; case 0x10: local_10 = 0x11; break; case 0x11: local_10 = 0x12; break; case 0x12: local_10 = 0x13; break; case 0x13: local_10 = 0x14; break; case 0x14: local_10 = 0x15; break; case 0x15: local_10 = 0x16; break; case 0x16: local_10 = 0x17; break; case 0x17: local_10 = 0x1d; break; case 0x18: local_10 = 0x1e; break; case 0xffffffff: local_10 = 0x27; } if (local_10 == 0x27) { ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 0x502,"GGML_ASSERT(%s) failed","wtype != GGML_TYPE_COUNT"); } return local_10; }
56,836
ggml_ftype_to_ggml_type
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
enum ggml_type ggml_ftype_to_ggml_type(enum ggml_ftype ftype) { enum ggml_type wtype = GGML_TYPE_COUNT; switch (ftype) { case GGML_FTYPE_ALL_F32: wtype = GGML_TYPE_F32; break; case GGML_FTYPE_MOSTLY_F16: wtype = GGML_TYPE_F16; break; case GGML_FTYPE_MOSTLY_BF16: wtype = GGML_TYPE_BF16; break; case GGML_FTYPE_MOSTLY_Q4_0: wtype = GGML_TYPE_Q4_0; break; case GGML_FTYPE_MOSTLY_Q4_1: wtype = GGML_TYPE_Q4_1; break; case GGML_FTYPE_MOSTLY_Q5_0: wtype = GGML_TYPE_Q5_0; break; case GGML_FTYPE_MOSTLY_Q5_1: wtype = GGML_TYPE_Q5_1; break; case GGML_FTYPE_MOSTLY_Q8_0: wtype = GGML_TYPE_Q8_0; break; case GGML_FTYPE_MOSTLY_Q2_K: wtype = GGML_TYPE_Q2_K; break; case GGML_FTYPE_MOSTLY_Q3_K: wtype = GGML_TYPE_Q3_K; break; case GGML_FTYPE_MOSTLY_Q4_K: wtype = GGML_TYPE_Q4_K; break; case GGML_FTYPE_MOSTLY_Q5_K: wtype = GGML_TYPE_Q5_K; break; case GGML_FTYPE_MOSTLY_Q6_K: wtype = GGML_TYPE_Q6_K; break; case GGML_FTYPE_MOSTLY_IQ2_XXS: wtype = GGML_TYPE_IQ2_XXS; break; case GGML_FTYPE_MOSTLY_IQ2_XS: wtype = GGML_TYPE_IQ2_XS; break; case GGML_FTYPE_MOSTLY_IQ3_XXS: wtype = GGML_TYPE_IQ3_XXS; break; case GGML_FTYPE_MOSTLY_IQ1_S: wtype = GGML_TYPE_IQ1_S; break; case GGML_FTYPE_MOSTLY_IQ1_M: wtype = GGML_TYPE_IQ1_M; break; case GGML_FTYPE_MOSTLY_IQ4_NL: wtype = GGML_TYPE_IQ4_NL; break; case GGML_FTYPE_MOSTLY_IQ4_XS: wtype = GGML_TYPE_IQ4_XS; break; case GGML_FTYPE_MOSTLY_IQ3_S: wtype = GGML_TYPE_IQ3_S; break; case GGML_FTYPE_MOSTLY_IQ2_S: wtype = GGML_TYPE_IQ2_S; break; case GGML_FTYPE_UNKNOWN: wtype = GGML_TYPE_COUNT; break; case GGML_FTYPE_MOSTLY_Q4_1_SOME_F16: wtype = GGML_TYPE_COUNT; break; } GGML_ASSERT(wtype != GGML_TYPE_COUNT); return wtype; }
O1
c
ggml_ftype_to_ggml_type: movl $0x27, %eax movb $0x1, %cl cmpl $0x18, %edi ja 0x1b3cf movl %edi, %edx leaq 0x30d0b(%rip), %rsi # 0x4c070 movslq (%rsi,%rdx,4), %rdx addq %rsi, %rdx jmpq *%rdx xorl %ecx, %ecx movl %edi, %eax jmp 0x1b3cf movl $0x16, %eax jmp 0x1b3cd movl $0x1e, %eax jmp 0x1b3cd movl $0x11, %eax jmp 0x1b3cd movl $0x6, %eax jmp 0x1b3cd movl $0x10, %eax jmp 0x1b3cd movl $0x17, %eax jmp 0x1b3cd movl $0x7, %eax jmp 0x1b3cd movl $0x12, %eax jmp 0x1b3cd movl $0x13, %eax jmp 0x1b3cd movl $0x8, %eax jmp 0x1b3cd movl $0x15, %eax jmp 0x1b3cd movl $0x14, %eax jmp 0x1b3cd movl $0x1d, %eax xorl %ecx, %ecx testb %cl, %cl jne 0x1b3d4 retq pushq %rax leaq 0x31193(%rip), %rdi # 0x4c56f leaq 0x311de(%rip), %rdx # 0x4c5c1 leaq 0x312c0(%rip), %rcx # 0x4c6aa movl $0x502, %esi # imm = 0x502 xorl %eax, %eax callq 0x18ce0
ggml_ftype_to_ggml_type: mov eax, 27h ; ''' mov cl, 1 cmp edi, 18h; switch 25 cases ja short def_1B36C; jumptable 000000000001B36C default case, cases 4-6 mov edx, edi lea rsi, jpt_1B36C movsxd rdx, ds:(jpt_1B36C - 4C070h)[rsi+rdx*4] add rdx, rsi jmp rdx; switch jump loc_1B36E: xor ecx, ecx; jumptable 000000000001B36C cases 0-3,10-14 mov eax, edi jmp short def_1B36C; jumptable 000000000001B36C default case, cases 4-6 loc_1B374: mov eax, 16h; jumptable 000000000001B36C case 21 jmp short loc_1B3CD loc_1B37B: mov eax, 1Eh; jumptable 000000000001B36C case 24 jmp short loc_1B3CD loc_1B382: mov eax, 11h; jumptable 000000000001B36C case 16 jmp short loc_1B3CD loc_1B389: mov eax, 6; jumptable 000000000001B36C case 8 jmp short loc_1B3CD loc_1B390: mov eax, 10h; jumptable 000000000001B36C case 15 jmp short loc_1B3CD loc_1B397: mov eax, 17h; jumptable 000000000001B36C case 22 jmp short loc_1B3CD loc_1B39E: mov eax, 7; jumptable 000000000001B36C case 9 jmp short loc_1B3CD loc_1B3A5: mov eax, 12h; jumptable 000000000001B36C case 17 jmp short loc_1B3CD loc_1B3AC: mov eax, 13h; jumptable 000000000001B36C case 18 jmp short loc_1B3CD loc_1B3B3: mov eax, 8; jumptable 000000000001B36C case 7 jmp short loc_1B3CD loc_1B3BA: mov eax, 15h; jumptable 000000000001B36C case 20 jmp short loc_1B3CD loc_1B3C1: mov eax, 14h; jumptable 000000000001B36C case 19 jmp short loc_1B3CD loc_1B3C8: mov eax, 1Dh; jumptable 000000000001B36C case 23 loc_1B3CD: xor ecx, ecx def_1B36C: test cl, cl; jumptable 000000000001B36C default case, cases 4-6 jnz short loc_1B3D4 retn loc_1B3D4: push rax lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aWtypeGgmlTypeC; "wtype != GGML_TYPE_COUNT" mov esi, 502h xor eax, eax call _ggml_abort
long long ggml_ftype_to_ggml_type(unsigned int a1, long long a2, long long a3, long long a4, int a5, int a6) { long long result; // rax char v7; // cl result = 39LL; v7 = 1; switch ( a1 ) { case 0u: case 1u: case 2u: case 3u: case 0xAu: case 0xBu: case 0xCu: case 0xDu: case 0xEu: v7 = 0; result = a1; break; case 7u: result = 8LL; goto LABEL_16; case 8u: result = 6LL; goto LABEL_16; case 9u: result = 7LL; goto LABEL_16; case 0xFu: result = 16LL; goto LABEL_16; case 0x10u: result = 17LL; goto LABEL_16; case 0x11u: result = 18LL; goto LABEL_16; case 0x12u: result = 19LL; goto LABEL_16; case 0x13u: result = 20LL; goto LABEL_16; case 0x14u: result = 21LL; goto LABEL_16; case 0x15u: result = 22LL; goto LABEL_16; case 0x16u: result = 23LL; goto LABEL_16; case 0x17u: result = 29LL; goto LABEL_16; case 0x18u: result = 30LL; LABEL_16: v7 = 0; break; default: break; } if ( v7 ) ggml_abort( (unsigned int)"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 1282, (unsigned int)"GGML_ASSERT(%s) failed", (unsigned int)"wtype != GGML_TYPE_COUNT", a5, a6); return result; }
ggml_ftype_to_ggml_type: MOV EAX,0x27 MOV CL,0x1 CMP EDI,0x18 JA 0x0011b3cf MOV EDX,EDI LEA RSI,[0x14c070] MOVSXD RDX,dword ptr [RSI + RDX*0x4] ADD RDX,RSI switchD: JMP RDX caseD_0: XOR ECX,ECX MOV EAX,EDI JMP 0x0011b3cf caseD_15: MOV EAX,0x16 JMP 0x0011b3cd caseD_18: MOV EAX,0x1e JMP 0x0011b3cd caseD_10: MOV EAX,0x11 JMP 0x0011b3cd caseD_8: MOV EAX,0x6 JMP 0x0011b3cd caseD_f: MOV EAX,0x10 JMP 0x0011b3cd caseD_16: MOV EAX,0x17 JMP 0x0011b3cd caseD_9: MOV EAX,0x7 JMP 0x0011b3cd caseD_11: MOV EAX,0x12 JMP 0x0011b3cd caseD_12: MOV EAX,0x13 JMP 0x0011b3cd caseD_7: MOV EAX,0x8 JMP 0x0011b3cd caseD_14: MOV EAX,0x15 JMP 0x0011b3cd caseD_13: MOV EAX,0x14 JMP 0x0011b3cd caseD_17: MOV EAX,0x1d LAB_0011b3cd: XOR ECX,ECX caseD_4: TEST CL,CL JNZ 0x0011b3d4 RET LAB_0011b3d4: PUSH RAX LEA RDI,[0x14c56f] LEA RDX,[0x14c5c1] LEA RCX,[0x14c6aa] MOV ESI,0x502 XOR EAX,EAX CALL 0x00118ce0
void ggml_ftype_to_ggml_type(int4 param_1) { bool bVar1; int4 uVar2; int8 in_R8; int8 in_R9; bVar1 = true; uVar2 = 0x27; switch(param_1) { case 0: case 1: case 2: case 3: case 10: case 0xb: case 0xc: case 0xd: case 0xe: bVar1 = false; uVar2 = param_1; default: goto switchD_0011b36c_caseD_4; case 7: uVar2 = 8; break; case 8: uVar2 = 6; break; case 9: uVar2 = 7; break; case 0xf: uVar2 = 0x10; break; case 0x10: uVar2 = 0x11; break; case 0x11: uVar2 = 0x12; break; case 0x12: uVar2 = 0x13; break; case 0x13: uVar2 = 0x14; break; case 0x14: uVar2 = 0x15; break; case 0x15: uVar2 = 0x16; break; case 0x16: uVar2 = 0x17; break; case 0x17: uVar2 = 0x1d; break; case 0x18: uVar2 = 0x1e; } bVar1 = false; switchD_0011b36c_caseD_4: if (!bVar1) { return; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 0x502,"GGML_ASSERT(%s) failed","wtype != GGML_TYPE_COUNT",in_R8,in_R9,uVar2); }
56,837
ggml_ftype_to_ggml_type
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
enum ggml_type ggml_ftype_to_ggml_type(enum ggml_ftype ftype) { enum ggml_type wtype = GGML_TYPE_COUNT; switch (ftype) { case GGML_FTYPE_ALL_F32: wtype = GGML_TYPE_F32; break; case GGML_FTYPE_MOSTLY_F16: wtype = GGML_TYPE_F16; break; case GGML_FTYPE_MOSTLY_BF16: wtype = GGML_TYPE_BF16; break; case GGML_FTYPE_MOSTLY_Q4_0: wtype = GGML_TYPE_Q4_0; break; case GGML_FTYPE_MOSTLY_Q4_1: wtype = GGML_TYPE_Q4_1; break; case GGML_FTYPE_MOSTLY_Q5_0: wtype = GGML_TYPE_Q5_0; break; case GGML_FTYPE_MOSTLY_Q5_1: wtype = GGML_TYPE_Q5_1; break; case GGML_FTYPE_MOSTLY_Q8_0: wtype = GGML_TYPE_Q8_0; break; case GGML_FTYPE_MOSTLY_Q2_K: wtype = GGML_TYPE_Q2_K; break; case GGML_FTYPE_MOSTLY_Q3_K: wtype = GGML_TYPE_Q3_K; break; case GGML_FTYPE_MOSTLY_Q4_K: wtype = GGML_TYPE_Q4_K; break; case GGML_FTYPE_MOSTLY_Q5_K: wtype = GGML_TYPE_Q5_K; break; case GGML_FTYPE_MOSTLY_Q6_K: wtype = GGML_TYPE_Q6_K; break; case GGML_FTYPE_MOSTLY_IQ2_XXS: wtype = GGML_TYPE_IQ2_XXS; break; case GGML_FTYPE_MOSTLY_IQ2_XS: wtype = GGML_TYPE_IQ2_XS; break; case GGML_FTYPE_MOSTLY_IQ3_XXS: wtype = GGML_TYPE_IQ3_XXS; break; case GGML_FTYPE_MOSTLY_IQ1_S: wtype = GGML_TYPE_IQ1_S; break; case GGML_FTYPE_MOSTLY_IQ1_M: wtype = GGML_TYPE_IQ1_M; break; case GGML_FTYPE_MOSTLY_IQ4_NL: wtype = GGML_TYPE_IQ4_NL; break; case GGML_FTYPE_MOSTLY_IQ4_XS: wtype = GGML_TYPE_IQ4_XS; break; case GGML_FTYPE_MOSTLY_IQ3_S: wtype = GGML_TYPE_IQ3_S; break; case GGML_FTYPE_MOSTLY_IQ2_S: wtype = GGML_TYPE_IQ2_S; break; case GGML_FTYPE_UNKNOWN: wtype = GGML_TYPE_COUNT; break; case GGML_FTYPE_MOSTLY_Q4_1_SOME_F16: wtype = GGML_TYPE_COUNT; break; } GGML_ASSERT(wtype != GGML_TYPE_COUNT); return wtype; }
O2
c
ggml_ftype_to_ggml_type: cmpl $0x19, %edi jae 0x20da2 movl $0x1ffff8f, %eax # imm = 0x1FFFF8F btl %edi, %eax jae 0x20da2 movl %edi, %eax leaq 0x2d602(%rip), %rcx # 0x4e3a0 movl (%rcx,%rax,4), %eax retq pushq %rax leaq 0x2d7d9(%rip), %rdi # 0x4e583 leaq 0x2d824(%rip), %rdx # 0x4e5d5 leaq 0x2d906(%rip), %rcx # 0x4e6be movl $0x502, %esi # imm = 0x502 xorl %eax, %eax callq 0x1f9b0
ggml_ftype_to_ggml_type: cmp edi, 19h jnb short loc_20DA2 mov eax, 1FFFF8Fh bt eax, edi jnb short loc_20DA2 mov eax, edi lea rcx, unk_4E3A0 mov eax, [rcx+rax*4] retn loc_20DA2: push rax lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aWtypeGgmlTypeC; "wtype != GGML_TYPE_COUNT" mov esi, 502h xor eax, eax call _ggml_abort
long long ggml_ftype_to_ggml_type( unsigned int a1, __m128 a2, __m128 a3, __m128 a4, __m128 a5, __m128 a6, __m128 a7, __m128 a8, __m128 a9, long long a10, long long a11, long long a12, long long a13, long long a14) { int v14; // eax if ( a1 >= 0x19 || (v14 = 33554319, !_bittest(&v14, a1)) ) ggml_abort( "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 1282, (long long)"GGML_ASSERT(%s) failed", (long long)"wtype != GGML_TYPE_COUNT", a13, a14, a2, a3, a4, a5, a6, a7, a8, a9, v14); return dword_4E3A0[a1]; }
ggml_ftype_to_ggml_type: CMP EDI,0x19 JNC 0x00120da2 MOV EAX,0x1ffff8f BT EAX,EDI JNC 0x00120da2 MOV EAX,EDI LEA RCX,[0x14e3a0] MOV EAX,dword ptr [RCX + RAX*0x4] RET LAB_00120da2: PUSH RAX LEA RDI,[0x14e583] LEA RDX,[0x14e5d5] LEA RCX,[0x14e6be] MOV ESI,0x502 XOR EAX,EAX CALL 0x0011f9b0
int4 ggml_ftype_to_ggml_type(uint param_1) { int8 in_RAX; int8 in_R8; int8 in_R9; if ((param_1 < 0x19) && (in_RAX = 0x1ffff8f, (0x1ffff8fU >> (param_1 & 0x1f) & 1) != 0)) { return *(int4 *)(&DAT_0014e3a0 + (ulong)param_1 * 4); } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 0x502,"GGML_ASSERT(%s) failed","wtype != GGML_TYPE_COUNT",in_R8,in_R9,in_RAX); }
56,838
ggml_ftype_to_ggml_type
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
enum ggml_type ggml_ftype_to_ggml_type(enum ggml_ftype ftype) { enum ggml_type wtype = GGML_TYPE_COUNT; switch (ftype) { case GGML_FTYPE_ALL_F32: wtype = GGML_TYPE_F32; break; case GGML_FTYPE_MOSTLY_F16: wtype = GGML_TYPE_F16; break; case GGML_FTYPE_MOSTLY_BF16: wtype = GGML_TYPE_BF16; break; case GGML_FTYPE_MOSTLY_Q4_0: wtype = GGML_TYPE_Q4_0; break; case GGML_FTYPE_MOSTLY_Q4_1: wtype = GGML_TYPE_Q4_1; break; case GGML_FTYPE_MOSTLY_Q5_0: wtype = GGML_TYPE_Q5_0; break; case GGML_FTYPE_MOSTLY_Q5_1: wtype = GGML_TYPE_Q5_1; break; case GGML_FTYPE_MOSTLY_Q8_0: wtype = GGML_TYPE_Q8_0; break; case GGML_FTYPE_MOSTLY_Q2_K: wtype = GGML_TYPE_Q2_K; break; case GGML_FTYPE_MOSTLY_Q3_K: wtype = GGML_TYPE_Q3_K; break; case GGML_FTYPE_MOSTLY_Q4_K: wtype = GGML_TYPE_Q4_K; break; case GGML_FTYPE_MOSTLY_Q5_K: wtype = GGML_TYPE_Q5_K; break; case GGML_FTYPE_MOSTLY_Q6_K: wtype = GGML_TYPE_Q6_K; break; case GGML_FTYPE_MOSTLY_IQ2_XXS: wtype = GGML_TYPE_IQ2_XXS; break; case GGML_FTYPE_MOSTLY_IQ2_XS: wtype = GGML_TYPE_IQ2_XS; break; case GGML_FTYPE_MOSTLY_IQ3_XXS: wtype = GGML_TYPE_IQ3_XXS; break; case GGML_FTYPE_MOSTLY_IQ1_S: wtype = GGML_TYPE_IQ1_S; break; case GGML_FTYPE_MOSTLY_IQ1_M: wtype = GGML_TYPE_IQ1_M; break; case GGML_FTYPE_MOSTLY_IQ4_NL: wtype = GGML_TYPE_IQ4_NL; break; case GGML_FTYPE_MOSTLY_IQ4_XS: wtype = GGML_TYPE_IQ4_XS; break; case GGML_FTYPE_MOSTLY_IQ3_S: wtype = GGML_TYPE_IQ3_S; break; case GGML_FTYPE_MOSTLY_IQ2_S: wtype = GGML_TYPE_IQ2_S; break; case GGML_FTYPE_UNKNOWN: wtype = GGML_TYPE_COUNT; break; case GGML_FTYPE_MOSTLY_Q4_1_SOME_F16: wtype = GGML_TYPE_COUNT; break; } GGML_ASSERT(wtype != GGML_TYPE_COUNT); return wtype; }
O3
c
ggml_ftype_to_ggml_type: cmpl $0x19, %edi jae 0x1a07d movl $0x1ffff8f, %eax # imm = 0x1FFFF8F btl %edi, %eax jae 0x1a07d movl %edi, %eax leaq 0x323b7(%rip), %rcx # 0x4c430 movl (%rcx,%rax,4), %eax retq pushq %rax leaq 0x3258e(%rip), %rdi # 0x4c613 leaq 0x325d9(%rip), %rdx # 0x4c665 leaq 0x326bb(%rip), %rcx # 0x4c74e movl $0x502, %esi # imm = 0x502 xorl %eax, %eax callq 0x17cd0
ggml_ftype_to_ggml_type: cmp edi, 19h jnb short loc_1A07D mov eax, 1FFFF8Fh bt eax, edi jnb short loc_1A07D mov eax, edi lea rcx, unk_4C430 mov eax, [rcx+rax*4] retn loc_1A07D: push rax lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aWtypeGgmlTypeC; "wtype != GGML_TYPE_COUNT" mov esi, 502h xor eax, eax call _ggml_abort
long long ggml_ftype_to_ggml_type(unsigned int a1, long long a2, long long a3, long long a4, int a5, int a6) { int v6; // eax if ( a1 >= 0x19 || (v6 = 33554319, !_bittest(&v6, a1)) ) ggml_abort( (unsigned int)"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 1282, (unsigned int)"GGML_ASSERT(%s) failed", (unsigned int)"wtype != GGML_TYPE_COUNT", a5, a6); return dword_4C430[a1]; }
ggml_ftype_to_ggml_type: CMP EDI,0x19 JNC 0x0011a07d MOV EAX,0x1ffff8f BT EAX,EDI JNC 0x0011a07d MOV EAX,EDI LEA RCX,[0x14c430] MOV EAX,dword ptr [RCX + RAX*0x4] RET LAB_0011a07d: PUSH RAX LEA RDI,[0x14c613] LEA RDX,[0x14c665] LEA RCX,[0x14c74e] MOV ESI,0x502 XOR EAX,EAX CALL 0x00117cd0
int4 ggml_ftype_to_ggml_type(uint param_1) { int8 in_RAX; int8 in_R8; int8 in_R9; if ((param_1 < 0x19) && (in_RAX = 0x1ffff8f, (0x1ffff8fU >> (param_1 & 0x1f) & 1) != 0)) { return *(int4 *)(&DAT_0014c430 + (ulong)param_1 * 4); } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 0x502,"GGML_ASSERT(%s) failed","wtype != GGML_TYPE_COUNT",in_R8,in_R9,in_RAX); }
56,839
SetNumberNode::post(std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::any, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::any>>>&, std::nullptr_t const&, int const&)
The-Pocket[P]PocketFlow-CPP/main.cpp
std::optional<std::string> post(Context& ctx, const std::nullptr_t&, const int& e) override { ctx["currentValue"] = e; // Store result in context return e > 20 ? std::make_optional("over_20") : std::nullopt; // Branching action }
O1
cpp
SetNumberNode::post(std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::any, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::any>>>&, std::nullptr_t const&, int const&): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x20, %rsp movq %r8, %r14 movq %rdx, %r15 movq %rdi, %rbx leaq 0x10(%rsp), %r13 movq %r13, -0x10(%r13) leaq 0x3ace(%rip), %rsi # 0x11130 leaq 0x3ad3(%rip), %rdx # 0x1113c movq %rsp, %r12 movq %r12, %rdi callq 0x90e4 movq %r15, %rdi movq %r12, %rsi callq 0x6d60 movq %rax, %rdi movq %r14, %rsi callq 0xe056 movq (%rsp), %rdi cmpq %r13, %rdi je 0xd6a0 movq 0x10(%rsp), %rsi incq %rsi callq 0x5180 cmpl $0x15, (%r14) jl 0xd6b5 leaq 0x3b24(%rip), %rax # 0x111d1 movq %rax, (%rsp) movb $0x1, %al jmp 0xd6b7 xorl %eax, %eax movq %rsp, %rsi movb %al, 0x8(%rsi) movq %rbx, %rdi callq 0xe0b8 movq %rbx, %rax addq $0x20, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq movq %rax, %rbx movq (%rsp), %rdi cmpq %r13, %rdi je 0xd6ef movq 0x10(%rsp), %rsi incq %rsi callq 0x5180 movq %rbx, %rdi callq 0x52a0 nop
_ZN13SetNumberNode4postERSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt3anySt4lessIS6_ESaISt4pairIKS6_S7_EEERKDnRKi: push r15 push r14 push r13 push r12 push rbx sub rsp, 20h mov r14, r8 mov r15, rdx mov rbx, rdi lea r13, [rsp+48h+var_38] mov [r13-10h], r13 lea rsi, aCurrentvalue; "currentValue" lea rdx, aCurrentvalue+0Ch; "" mov r12, rsp mov rdi, r12 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) mov rdi, r15 mov rsi, r12 call _ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt3anySt4lessIS5_ESaISt4pairIKS5_S6_EEEixEOS5_; std::map<std::string,std::any>::operator[](std::string&&) mov rdi, rax mov rsi, r14 call _ZNSt3anyaSIRKiEENSt9enable_ifIXsr21is_copy_constructibleINS3_IXnt9is_same_vINSt5decayIT_E4typeES_EES7_E4typeEEE5valueERS_E4typeEOS5_ mov rdi, [rsp+48h+var_48]; void * cmp rdi, r13 jz short loc_D6A0 mov rsi, [rsp+48h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_D6A0: cmp dword ptr [r14], 15h jl short loc_D6B5 lea rax, aOver20; "over_20" mov [rsp+48h+var_48], rax mov al, 1 jmp short loc_D6B7 loc_D6B5: xor eax, eax loc_D6B7: mov rsi, rsp mov [rsi+8], al mov rdi, rbx call _ZNSt8optionalINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPKcTnNSt9enable_ifIX7__and_vISt6__not_ISt7is_sameIS5_T_EESt16is_constructibleIS5_JSD_EESt14is_convertibleISD_S5_ESB_ISt5__or_IJSG_IS5_JRKS_ISD_EEESG_IS5_JRSL_EESG_IS5_JOSM_EESG_IS5_JOSL_EESI_ISN_S5_ESI_ISP_S5_ESI_ISR_S5_ESI_IST_S5_EEEEEEbE4typeELb1EEEST_ mov rax, rbx add rsp, 20h pop rbx pop r12 pop r13 pop r14 pop r15 retn mov rbx, rax mov rdi, [rsp+0]; void * cmp rdi, r13 jz short loc_D6EF mov rsi, [rsp+arg_8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_D6EF: mov rdi, rbx call __Unwind_Resume
long long SetNumberNode::post(long long a1, long long a2, long long a3, long long a4, int *a5) { long long v7; // rax char v8; // al void *v10; // [rsp+0h] [rbp-48h] BYREF char v11; // [rsp+8h] [rbp-40h] _QWORD v12[7]; // [rsp+10h] [rbp-38h] BYREF v10 = v12; std::string::_M_construct<char const*>(&v10, "currentValue", (long long)""); v7 = std::map<std::string,std::any>::operator[](a3, (long long)&v10); std::any::operator=<int const&>(v7, a5); if ( v10 != v12 ) operator delete(v10, v12[0] + 1LL); if ( *a5 < 21 ) { v8 = 0; } else { v10 = "over_20"; v8 = 1; } v11 = v8; ZNSt8optionalINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPKcTnNSt9enable_ifIX7__and_vISt6__not_ISt7is_sameIS5_T_EESt16is_constructibleIS5_JSD_EESt14is_convertibleISD_S5_ESB_ISt5__or_IJSG_IS5_JRKS_ISD_EEESG_IS5_JRSL_EESG_IS5_JOSM_EESG_IS5_JOSL_EESI_ISN_S5_ESI_ISP_S5_ESI_ISR_S5_ESI_IST_S5_EEEEEEbE4typeELb1EEEST_(a1); return a1; }
post: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x20 MOV R14,R8 MOV R15,RDX MOV RBX,RDI LEA R13,[RSP + 0x10] MOV qword ptr [R13 + -0x10],R13 LEA RSI,[0x111130] LEA RDX,[0x11113c] MOV R12,RSP MOV RDI,R12 CALL 0x001090e4 LAB_0010d674: MOV RDI,R15 MOV RSI,R12 CALL 0x00106d60 MOV RDI,RAX MOV RSI,R14 CALL 0x0010e056 LAB_0010d68a: MOV RDI,qword ptr [RSP] CMP RDI,R13 JZ 0x0010d6a0 MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x00105180 LAB_0010d6a0: CMP dword ptr [R14],0x15 JL 0x0010d6b5 LEA RAX,[0x1111d1] MOV qword ptr [RSP],RAX MOV AL,0x1 JMP 0x0010d6b7 LAB_0010d6b5: XOR EAX,EAX LAB_0010d6b7: MOV RSI,RSP MOV byte ptr [RSI + 0x8],AL MOV RDI,RBX CALL 0x0010e0b8 MOV RAX,RBX ADD RSP,0x20 POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* SetNumberNode::post(std::map<std::__cxx11::string, std::any, std::less<std::__cxx11::string >, std::allocator<std::pair<std::__cxx11::string const, std::any> > >&, decltype(nullptr) const&, int const&) */ map * SetNumberNode::post(map *param_1,_func_decltype_nullptr **param_2,int *param_3) { any *this; int *in_R8; long *local_48; int1 local_40; long local_38 [2]; local_48 = local_38; std::__cxx11::string::_M_construct<char_const*>((string *)&local_48,"currentValue",""); /* try { // try from 0010d674 to 0010d689 has its CatchHandler @ 0010d6d6 */ this = (any *)std:: map<std::__cxx11::string,std::any,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::any>>> ::operator[]((map<std::__cxx11::string,std::any,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::any>>> *)param_3,(string *)&local_48); std::any::operator=(this,in_R8); if (local_48 != local_38) { operator_delete(local_48,local_38[0] + 1); } local_40 = 0x14 < *in_R8; if ((bool)local_40) { local_48 = (long *)&DAT_001111d1; } _ZNSt8optionalINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPKcTnNSt9enable_ifIX7__and_vISt6__not_ISt7is_sameIS5_T_EESt16is_constructibleIS5_JSD_EESt14is_convertibleISD_S5_ESB_ISt5__or_IJSG_IS5_JRKS_ISD_EEESG_IS5_JRSL_EESG_IS5_JOSM_EESG_IS5_JOSL_EESI_ISN_S5_ESI_ISP_S5_ESI_ISR_S5_ESI_IST_S5_EEEEEEbE4typeELb1EEEST_ (param_1); return param_1; }
56,840
SetNumberNode::post(std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::any, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::any>>>&, std::nullptr_t const&, int const&)
The-Pocket[P]PocketFlow-CPP/main.cpp
std::optional<std::string> post(Context& ctx, const std::nullptr_t&, const int& e) override { ctx["currentValue"] = e; // Store result in context return e > 20 ? std::make_optional("over_20") : std::nullopt; // Branching action }
O3
cpp
SetNumberNode::post(std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::any, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, std::any>>>&, std::nullptr_t const&, int const&): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x20, %rsp movq %r8, %r14 movq %rdx, %r15 movq %rdi, %rbx leaq 0x10(%rsp), %r13 movq %r13, -0x10(%r13) leaq 0x3b8e(%rip), %rsi # 0x11130 leaq 0x3b93(%rip), %rdx # 0x1113c movq %rsp, %r12 movq %r12, %rdi callq 0x9030 movq %r15, %rdi movq %r12, %rsi callq 0x6cf4 movq %rax, %rdi movq %r14, %rsi callq 0xdfc8 movq (%rsp), %rdi cmpq %r13, %rdi je 0xd5e0 movq 0x10(%rsp), %rsi incq %rsi callq 0x5180 cmpl $0x15, (%r14) jl 0xd5f5 leaq 0x3be4(%rip), %rax # 0x111d1 movq %rax, (%rsp) movb $0x1, %al jmp 0xd5f7 xorl %eax, %eax movq %rsp, %rsi movb %al, 0x8(%rsi) movq %rbx, %rdi callq 0xe020 movq %rbx, %rax addq $0x20, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq movq %rax, %rbx movq (%rsp), %rdi cmpq %r13, %rdi je 0xd62f movq 0x10(%rsp), %rsi incq %rsi callq 0x5180 movq %rbx, %rdi callq 0x52a0 nop
_ZN13SetNumberNode4postERSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt3anySt4lessIS6_ESaISt4pairIKS6_S7_EEERKDnRKi: push r15 push r14 push r13 push r12 push rbx sub rsp, 20h mov r14, r8 mov r15, rdx mov rbx, rdi lea r13, [rsp+48h+var_38] mov [r13-10h], r13 lea rsi, aCurrentvalue; "currentValue" lea rdx, aCurrentvalue+0Ch; "" mov r12, rsp mov rdi, r12 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) mov rdi, r15 mov rsi, r12 call _ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt3anySt4lessIS5_ESaISt4pairIKS5_S6_EEEixEOS5_; std::map<std::string,std::any>::operator[](std::string&&) mov rdi, rax mov rsi, r14 call _ZNSt3anyaSIRKiEENSt9enable_ifIXsr21is_copy_constructibleINS3_IXnt9is_same_vINSt5decayIT_E4typeES_EES7_E4typeEEE5valueERS_E4typeEOS5_ mov rdi, [rsp+48h+var_48]; void * cmp rdi, r13 jz short loc_D5E0 mov rsi, [rsp+48h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_D5E0: cmp dword ptr [r14], 15h jl short loc_D5F5 lea rax, aOver20; "over_20" mov [rsp+48h+var_48], rax mov al, 1 jmp short loc_D5F7 loc_D5F5: xor eax, eax loc_D5F7: mov rsi, rsp mov [rsi+8], al mov rdi, rbx call _ZNSt8optionalINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPKcTnNSt9enable_ifIX7__and_vISt6__not_ISt7is_sameIS5_T_EESt16is_constructibleIS5_JSD_EESt14is_convertibleISD_S5_ESB_ISt5__or_IJSG_IS5_JRKS_ISD_EEESG_IS5_JRSL_EESG_IS5_JOSM_EESG_IS5_JOSL_EESI_ISN_S5_ESI_ISP_S5_ESI_ISR_S5_ESI_IST_S5_EEEEEEbE4typeELb1EEEST_ mov rax, rbx add rsp, 20h pop rbx pop r12 pop r13 pop r14 pop r15 retn mov rbx, rax mov rdi, [rsp+0]; void * cmp rdi, r13 jz short loc_D62F mov rsi, [rsp+arg_8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_D62F: mov rdi, rbx call __Unwind_Resume
long long SetNumberNode::post(long long a1, long long a2, long long a3, long long a4, int *a5) { long long v7; // rax char v8; // al void *v10; // [rsp+0h] [rbp-48h] BYREF char v11; // [rsp+8h] [rbp-40h] _QWORD v12[7]; // [rsp+10h] [rbp-38h] BYREF v10 = v12; std::string::_M_construct<char const*>((long long)&v10, "currentValue", (long long)""); v7 = std::map<std::string,std::any>::operator[](a3, (long long)&v10); std::any::operator=<int const&>(v7, a5); if ( v10 != v12 ) operator delete(v10, v12[0] + 1LL); if ( *a5 < 21 ) { v8 = 0; } else { v10 = "over_20"; v8 = 1; } v11 = v8; ZNSt8optionalINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPKcTnNSt9enable_ifIX7__and_vISt6__not_ISt7is_sameIS5_T_EESt16is_constructibleIS5_JSD_EESt14is_convertibleISD_S5_ESB_ISt5__or_IJSG_IS5_JRKS_ISD_EEESG_IS5_JRSL_EESG_IS5_JOSM_EESG_IS5_JOSL_EESI_ISN_S5_ESI_ISP_S5_ESI_ISR_S5_ESI_IST_S5_EEEEEEbE4typeELb1EEEST_(a1); return a1; }
post: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x20 MOV R14,R8 MOV R15,RDX MOV RBX,RDI LEA R13,[RSP + 0x10] MOV qword ptr [R13 + -0x10],R13 LEA RSI,[0x111130] LEA RDX,[0x11113c] MOV R12,RSP MOV RDI,R12 CALL 0x00109030 LAB_0010d5b4: MOV RDI,R15 MOV RSI,R12 CALL 0x00106cf4 MOV RDI,RAX MOV RSI,R14 CALL 0x0010dfc8 LAB_0010d5ca: MOV RDI,qword ptr [RSP] CMP RDI,R13 JZ 0x0010d5e0 MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x00105180 LAB_0010d5e0: CMP dword ptr [R14],0x15 JL 0x0010d5f5 LEA RAX,[0x1111d1] MOV qword ptr [RSP],RAX MOV AL,0x1 JMP 0x0010d5f7 LAB_0010d5f5: XOR EAX,EAX LAB_0010d5f7: MOV RSI,RSP MOV byte ptr [RSI + 0x8],AL MOV RDI,RBX CALL 0x0010e020 MOV RAX,RBX ADD RSP,0x20 POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* SetNumberNode::post(std::map<std::__cxx11::string, std::any, std::less<std::__cxx11::string >, std::allocator<std::pair<std::__cxx11::string const, std::any> > >&, decltype(nullptr) const&, int const&) */ map * SetNumberNode::post(map *param_1,_func_decltype_nullptr **param_2,int *param_3) { any *this; int *in_R8; long *local_48; int1 local_40; long local_38 [2]; local_48 = local_38; std::__cxx11::string::_M_construct<char_const*>((string *)&local_48,"currentValue",""); /* try { // try from 0010d5b4 to 0010d5c9 has its CatchHandler @ 0010d616 */ this = (any *)std:: map<std::__cxx11::string,std::any,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::any>>> ::operator[]((map<std::__cxx11::string,std::any,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::any>>> *)param_3,(string *)&local_48); std::any::operator=(this,in_R8); if (local_48 != local_38) { operator_delete(local_48,local_38[0] + 1); } local_40 = 0x14 < *in_R8; if ((bool)local_40) { local_48 = (long *)&DAT_001111d1; } _ZNSt8optionalINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPKcTnNSt9enable_ifIX7__and_vISt6__not_ISt7is_sameIS5_T_EESt16is_constructibleIS5_JSD_EESt14is_convertibleISD_S5_ESB_ISt5__or_IJSG_IS5_JRKS_ISD_EEESG_IS5_JRSL_EESG_IS5_JOSM_EESG_IS5_JOSL_EESI_ISN_S5_ESI_ISP_S5_ESI_ISR_S5_ESI_IST_S5_EEEEEEbE4typeELb1EEEST_ (param_1); return param_1; }
56,841
ma_ck_write
eloqsql/storage/maria/ma_write.c
my_bool _ma_ck_write(MARIA_HA *info, MARIA_KEY *key) { DBUG_ENTER("_ma_ck_write"); if (info->bulk_insert && is_tree_inited(&info->bulk_insert[key->keyinfo->key_nr])) { DBUG_RETURN(_ma_ck_write_tree(info, key)); } DBUG_RETURN(_ma_ck_write_btree(info, key)); }
O0
c
ma_ck_write: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax cmpq $0x0, 0x310(%rax) je 0x8cf7c movq -0x10(%rbp), %rax movq 0x310(%rax), %rax movq -0x18(%rbp), %rcx movq 0x8(%rcx), %rcx movzbl 0xa5(%rcx), %ecx imulq $0x298, %rcx, %rcx # imm = 0x298 addq %rcx, %rax cmpq $0x0, (%rax) je 0x8cf7c jmp 0x8cf6a movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x8cfa0 movb %al, -0x1(%rbp) jmp 0x8cf8e jmp 0x8cf7e movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x8d050 movb %al, -0x1(%rbp) movb -0x1(%rbp), %al addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
_ma_ck_write: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_10] cmp qword ptr [rax+310h], 0 jz short loc_8CF7C mov rax, [rbp+var_10] mov rax, [rax+310h] mov rcx, [rbp+var_18] mov rcx, [rcx+8] movzx ecx, byte ptr [rcx+0A5h] imul rcx, 298h add rax, rcx cmp qword ptr [rax], 0 jz short loc_8CF7C jmp short $+2 loc_8CF6A: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call _ma_ck_write_tree mov [rbp+var_1], al jmp short loc_8CF8E loc_8CF7C: jmp short $+2 loc_8CF7E: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call _ma_ck_write_btree mov [rbp+var_1], al loc_8CF8E: mov al, [rbp+var_1] add rsp, 20h pop rbp retn
char ma_ck_write(long long a1, long long a2) { if ( *(_QWORD *)(a1 + 784) && *(_QWORD *)(664LL * *(unsigned __int8 *)(*(_QWORD *)(a2 + 8) + 165LL) + *(_QWORD *)(a1 + 784)) ) { return ma_ck_write_tree(a1, a2); } else { return ma_ck_write_btree(a1, a2); } }
_ma_ck_write: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX + 0x310],0x0 JZ 0x0018cf7c MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x310] MOV RCX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RCX + 0x8] MOVZX ECX,byte ptr [RCX + 0xa5] IMUL RCX,RCX,0x298 ADD RAX,RCX CMP qword ptr [RAX],0x0 JZ 0x0018cf7c JMP 0x0018cf6a LAB_0018cf6a: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] CALL 0x0018cfa0 MOV byte ptr [RBP + -0x1],AL JMP 0x0018cf8e LAB_0018cf7c: JMP 0x0018cf7e LAB_0018cf7e: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] CALL 0x0018d050 MOV byte ptr [RBP + -0x1],AL LAB_0018cf8e: MOV AL,byte ptr [RBP + -0x1] ADD RSP,0x20 POP RBP RET
int1 _ma_ck_write(long param_1,long param_2) { int1 local_9; if ((*(long *)(param_1 + 0x310) == 0) || (*(long *)(*(long *)(param_1 + 0x310) + (ulong)*(byte *)(*(long *)(param_2 + 8) + 0xa5) * 0x298 ) == 0)) { local_9 = _ma_ck_write_btree(param_1,param_2); } else { local_9 = _ma_ck_write_tree(param_1,param_2); } return local_9; }
56,842
js_global_isFinite
bluesky950520[P]quickjs/quickjs.c
static JSValue js_global_isFinite(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { BOOL res; double d; if (unlikely(JS_ToFloat64(ctx, &d, argv[0]))) return JS_EXCEPTION; res = isfinite(d); return js_bool(res); }
O2
c
js_global_isFinite: pushq %rax movq (%r8), %rdx movq 0x8(%r8), %rcx movq %rsp, %rsi callq 0x2127f testl %eax, %eax jne 0x65eb4 movabsq $0x7fffffffffffffff, %rcx # imm = 0x7FFFFFFFFFFFFFFF andq (%rsp), %rcx movabsq $0x7ff0000000000000, %rdx # imm = 0x7FF0000000000000 xorl %eax, %eax cmpq %rdx, %rcx setl %al pushq $0x1 popq %rdx popq %rcx retq pushq $0x6 popq %rdx xorl %eax, %eax jmp 0x65eb2
js_global_isFinite: push rax mov rdx, [r8] mov rcx, [r8+8] mov rsi, rsp call JS_ToFloat64 test eax, eax jnz short loc_65EB4 mov rcx, 7FFFFFFFFFFFFFFFh and rcx, [rsp+8+var_8] mov rdx, 7FF0000000000000h xor eax, eax cmp rcx, rdx setl al push 1 pop rdx loc_65EB2: pop rcx retn loc_65EB4: push 6 pop rdx xor eax, eax jmp short loc_65EB2
_BOOL8 js_global_isFinite(long long a1, long long a2, long long a3, long long a4, long long a5) { long long v5; // rax long long v7; // [rsp+0h] [rbp-8h] BYREF v7 = v5; return !(unsigned int)JS_ToFloat64(a1, (long long)&v7, *(_DWORD **)a5, *(_QWORD *)(a5 + 8)) && (v7 & 0x7FFFFFFFFFFFFFFFuLL) < 0x7FF0000000000000LL; }
js_global_isFinite: PUSH RAX MOV RDX,qword ptr [R8] MOV RCX,qword ptr [R8 + 0x8] MOV RSI,RSP CALL 0x0012127f TEST EAX,EAX JNZ 0x00165eb4 MOV RCX,0x7fffffffffffffff AND RCX,qword ptr [RSP] MOV RDX,0x7ff0000000000000 XOR EAX,EAX CMP RCX,RDX SETL AL PUSH 0x1 POP RDX LAB_00165eb2: POP RCX RET LAB_00165eb4: PUSH 0x6 POP RDX XOR EAX,EAX JMP 0x00165eb2
bool js_global_isFinite(int8 param_1) { int iVar1; ulong in_RAX; int8 *in_R8; ulong local_8; local_8 = in_RAX; iVar1 = JS_ToFloat64(param_1,&local_8,*in_R8,in_R8[1]); return iVar1 == 0 && (local_8 & 0x7fffffffffffffff) < 0x7ff0000000000000; }
56,843
testing::internal::DoubleNearPredFormat(char const*, char const*, char const*, double, double, double)
giladroyz[P]FindPeaks/build_O1/_deps/googletest-src/googletest/src/gtest.cc
AssertionResult DoubleNearPredFormat(const char* expr1, const char* expr2, const char* abs_error_expr, double val1, double val2, double abs_error) { // We want to return success when the two values are infinity and at least // one of the following is true: // * The values are the same-signed infinity. // * The error limit itself is infinity. // This is done here so that we don't end up with a NaN when calculating the // difference in values. if (std::isinf(val1) && std::isinf(val2) && (std::signbit(val1) == std::signbit(val2) || (abs_error > 0.0 && std::isinf(abs_error)))) { return AssertionSuccess(); } const double diff = fabs(val1 - val2); if (diff <= abs_error) return AssertionSuccess(); // Find the value which is closest to zero. const double min_abs = std::min(fabs(val1), fabs(val2)); // Find the distance to the next double from that value. const double epsilon = nextafter(min_abs, std::numeric_limits<double>::infinity()) - min_abs; // Detect the case where abs_error is so small that EXPECT_NEAR is // effectively the same as EXPECT_EQUAL, and give an informative error // message so that the situation can be more easily understood without // requiring exotic floating-point knowledge. // Don't do an epsilon check if abs_error is zero because that implies // that an equality check was actually intended. if (!(std::isnan)(val1) && !(std::isnan)(val2) && abs_error > 0 && abs_error < epsilon) { return AssertionFailure() << "The difference between " << expr1 << " and " << expr2 << " is " << diff << ", where\n" << expr1 << " evaluates to " << val1 << ",\n" << expr2 << " evaluates to " << val2 << ".\nThe abs_error parameter " << abs_error_expr << " evaluates to " << abs_error << " which is smaller than the minimum distance between doubles for " "numbers of this magnitude which is " << epsilon << ", thus making this EXPECT_NEAR check equivalent to " "EXPECT_EQUAL. Consider using EXPECT_DOUBLE_EQ instead."; } return AssertionFailure() << "The difference between " << expr1 << " and " << expr2 << " is " << diff << ", which exceeds " << abs_error_expr << ", where\n" << expr1 << " evaluates to " << val1 << ",\n" << expr2 << " evaluates to " << val2 << ", and\n" << abs_error_expr << " evaluates to " << abs_error << "."; }
O1
cpp
testing::internal::DoubleNearPredFormat(char const*, char const*, char const*, double, double, double): pushq %r14 pushq %rbx subq $0x68, %rsp movdqa %xmm1, %xmm3 movq %rdi, %rbx movq %xmm1, %rax movq %xmm0, %rdi movq %rsi, 0x8(%rsp) movq %rdx, (%rsp) movq %rcx, 0x38(%rsp) movq %xmm0, 0x30(%rsp) movq %xmm1, 0x28(%rsp) movsd %xmm2, 0x20(%rsp) btrq $0x3f, %rdi movabsq $0x7ff0000000000000, %rcx # imm = 0x7FF0000000000000 xorq %rcx, %rdi btrq $0x3f, %rax xorq %rcx, %rax orq %rdi, %rax jne 0x1e280 ucomisd 0x23cac(%rip), %xmm2 # 0x41f10 jae 0x1e45b movdqa %xmm3, %xmm1 pxor %xmm0, %xmm1 movq %xmm1, %rax testq %rax, %rax jns 0x1e45b movdqa %xmm0, %xmm1 subsd %xmm3, %xmm1 andpd 0x23bc0(%rip), %xmm1 # 0x41e50 movlpd %xmm1, 0x40(%rsp) ucomisd %xmm1, %xmm2 jae 0x1e45b pand 0x23ba8(%rip), %xmm0 # 0x41e50 andpd 0x23ba0(%rip), %xmm3 # 0x41e50 minsd %xmm0, %xmm3 movapd %xmm3, 0x50(%rsp) movsd 0x23c4e(%rip), %xmm1 # 0x41f10 movapd %xmm3, %xmm0 callq 0x8380 subsd 0x50(%rsp), %xmm0 movsd %xmm0, 0x48(%rsp) movsd 0x30(%rsp), %xmm1 ucomisd %xmm1, %xmm1 jp 0x1e46b movsd 0x28(%rsp), %xmm1 ucomisd %xmm1, %xmm1 jp 0x1e46b movsd 0x20(%rsp), %xmm1 xorpd %xmm2, %xmm2 ucomisd %xmm2, %xmm1 jbe 0x1e46b ucomisd %xmm1, %xmm0 jbe 0x1e46b leaq 0x18(%rsp), %r14 movb $0x0, -0x8(%r14) movq $0x0, (%r14) leaq 0x24869(%rip), %rsi # 0x42b96 leaq 0x10(%rsp), %rdi callq 0x33140 leaq 0x8(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x24863(%rip), %rsi # 0x42bae movq %rax, %rdi callq 0x331be movq %rsp, %rsi movq %rax, %rdi callq 0xe69e leaq 0x248e1(%rip), %rsi # 0x42c46 movq %rax, %rdi callq 0xe820 leaq 0x40(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x24833(%rip), %rsi # 0x42bb4 movq %rax, %rdi callq 0x332ae leaq 0x8(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x24820(%rip), %rsi # 0x42bbd movq %rax, %rdi callq 0x3332c leaq 0x30(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x2530c(%rip), %rsi # 0x436c5 movq %rax, %rdi callq 0xe72e movq %rsp, %rsi movq %rax, %rdi callq 0xe69e leaq 0x247ea(%rip), %rsi # 0x42bbd movq %rax, %rdi callq 0x3332c leaq 0x28(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x247dd(%rip), %rsi # 0x42bcc movq %rax, %rdi callq 0x333aa leaq 0x38(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x247b2(%rip), %rsi # 0x42bbd movq %rax, %rdi callq 0x3332c leaq 0x20(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x247c0(%rip), %rsi # 0x42be7 movq %rax, %rdi callq 0x33428 leaq 0x48(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x24808(%rip), %rsi # 0x42c4b movq %rax, %rdi callq 0x334a6 movq %rbx, %rdi movq %rax, %rsi callq 0xefc4 jmp 0x1e5ac movb $0x1, (%rbx) movq $0x0, 0x8(%rbx) jmp 0x1e5be leaq 0x18(%rsp), %r14 movb $0x0, -0x8(%r14) movq $0x0, (%r14) leaq 0x24713(%rip), %rsi # 0x42b96 leaq 0x10(%rsp), %rdi callq 0x33140 leaq 0x8(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x2470d(%rip), %rsi # 0x42bae movq %rax, %rdi callq 0x331be movq %rsp, %rsi movq %rax, %rdi callq 0xe69e leaq 0x2478b(%rip), %rsi # 0x42c46 movq %rax, %rdi callq 0xe820 leaq 0x40(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x247de(%rip), %rsi # 0x42cb5 movq %rax, %rdi callq 0x33524 leaq 0x38(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x246c1(%rip), %rsi # 0x42bb4 movq %rax, %rdi callq 0x332ae leaq 0x8(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x246ae(%rip), %rsi # 0x42bbd movq %rax, %rdi callq 0x3332c leaq 0x30(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x2519a(%rip), %rsi # 0x436c5 movq %rax, %rdi callq 0xe72e movq %rsp, %rsi movq %rax, %rdi callq 0xe69e leaq 0x24678(%rip), %rsi # 0x42bbd movq %rax, %rdi callq 0x3332c leaq 0x28(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x24765(%rip), %rsi # 0x42cc6 movq %rax, %rdi callq 0x335a2 leaq 0x38(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x24640(%rip), %rsi # 0x42bbd movq %rax, %rdi callq 0x3332c leaq 0x20(%rsp), %rsi movq %rax, %rdi callq 0x3323c leaq 0x250d8(%rip), %rsi # 0x43671 movq %rax, %rdi callq 0x33620 movq %rbx, %rdi movq %rax, %rsi callq 0xefc4 movq 0x18(%rsp), %rsi testq %rsi, %rsi je 0x1e5be movq %r14, %rdi callq 0xde4a movq %rbx, %rax addq $0x68, %rsp popq %rbx popq %r14 retq jmp 0x1e5cb movq %rax, %rbx movq 0x18(%rsp), %rsi testq %rsi, %rsi je 0x1e5e0 movq %r14, %rdi callq 0xde4a movq %rbx, %rdi callq 0x8990
_ZN7testing8internal20DoubleNearPredFormatEPKcS2_S2_ddd: push r14 push rbx sub rsp, 68h movdqa xmm3, xmm1 mov rbx, rdi movq rax, xmm1 movq rdi, xmm0 mov [rsp+78h+var_70], rsi mov [rsp+78h+var_78], rdx; __int64 mov [rsp+78h+var_40], rcx movq [rsp+78h+var_48], xmm0 movq [rsp+78h+var_50], xmm1 movsd [rsp+78h+var_58], xmm2 btr rdi, 3Fh ; '?' mov rcx, 7FF0000000000000h xor rdi, rcx btr rax, 3Fh ; '?' xor rax, rcx or rax, rdi jnz short loc_1E280 ucomisd xmm2, cs:qword_41F10 jnb loc_1E45B movdqa xmm1, xmm3 pxor xmm1, xmm0 movq rax, xmm1 test rax, rax jns loc_1E45B loc_1E280: movdqa xmm1, xmm0 subsd xmm1, xmm3 andpd xmm1, cs:xmmword_41E50 movlpd [rsp+78h+var_38], xmm1 ucomisd xmm2, xmm1 jnb loc_1E45B pand xmm0, cs:xmmword_41E50 andpd xmm3, cs:xmmword_41E50 minsd xmm3, xmm0 movapd [rsp+78h+var_28], xmm3 movsd xmm1, cs:qword_41F10 movapd xmm0, xmm3 call _nextafter subsd xmm0, qword ptr [rsp+78h+var_28] movsd [rsp+78h+var_30], xmm0 movsd xmm1, [rsp+78h+var_48] ucomisd xmm1, xmm1 jp loc_1E46B movsd xmm1, [rsp+78h+var_50] ucomisd xmm1, xmm1 jp loc_1E46B movsd xmm1, [rsp+78h+var_58] xorpd xmm2, xmm2 ucomisd xmm1, xmm2 jbe loc_1E46B ucomisd xmm0, xmm1 jbe loc_1E46B lea r14, [rsp+78h+var_60] mov byte ptr [r14-8], 0 mov qword ptr [r14], 0 lea rsi, aTheDifferenceB; "The difference between " lea rdi, [rsp+78h+var_68]; this call _ZN7testing15AssertionResultlsIA24_cEERS0_RKT_; testing::AssertionResult::operator<<<char [24]>(char [24] const&) lea rsi, [rsp+78h+var_70] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aAnd; " and " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA6_cEERS0_RKT_; testing::AssertionResult::operator<<<char [6]>(char [6] const&) mov rsi, rsp mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aWhichIsSmaller+5Fh; " is " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA5_cEERS0_RKT_; testing::AssertionResult::operator<<<char [5]>(char [5] const&) lea rsi, [rsp+78h+var_38] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, aWhere; ", where\n" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA9_cEERS0_RKT_; testing::AssertionResult::operator<<<char [9]>(char [9] const&) lea rsi, [rsp+78h+var_70] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aEvaluatesTo; " evaluates to " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA15_cEERS0_RKT_; testing::AssertionResult::operator<<<char [15]>(char [15] const&) lea rsi, [rsp+78h+var_48] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, asc_436C4+1; ",\n" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA3_cEERS0_RKT_; testing::AssertionResult::operator<<<char [3]>(char [3] const&) mov rsi, rsp mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aEvaluatesTo; " evaluates to " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA15_cEERS0_RKT_; testing::AssertionResult::operator<<<char [15]>(char [15] const&) lea rsi, [rsp+78h+var_50] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, aTheAbsErrorPar; ".\nThe abs_error parameter " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA27_cEERS0_RKT_; testing::AssertionResult::operator<<<char [27]>(char [27] const&) lea rsi, [rsp+78h+var_40] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aEvaluatesTo; " evaluates to " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA15_cEERS0_RKT_; testing::AssertionResult::operator<<<char [15]>(char [15] const&) lea rsi, [rsp+78h+var_58] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, aWhichIsSmaller; " which is smaller than the minimum dist"... mov rdi, rax; this call _ZN7testing15AssertionResultlsIA100_cEERS0_RKT_; testing::AssertionResult::operator<<<char [100]>(char [100] const&) lea rsi, [rsp+78h+var_30] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, aThusMakingThis; ", thus making this EXPECT_NEAR check eq"... mov rdi, rax; this call _ZN7testing15AssertionResultlsIA106_cEERS0_RKT_; testing::AssertionResult::operator<<<char [106]>(char [106] const&) mov rdi, rbx mov rsi, rax call _ZN7testing15AssertionResultC2ERKS0_; testing::AssertionResult::AssertionResult(testing::AssertionResult const&) jmp loc_1E5AC loc_1E45B: mov byte ptr [rbx], 1 mov qword ptr [rbx+8], 0 jmp loc_1E5BE loc_1E46B: lea r14, [rsp+78h+var_60] mov byte ptr [r14-8], 0 mov qword ptr [r14], 0 lea rsi, aTheDifferenceB; "The difference between " lea rdi, [rsp+78h+var_68]; this call _ZN7testing15AssertionResultlsIA24_cEERS0_RKT_; testing::AssertionResult::operator<<<char [24]>(char [24] const&) lea rsi, [rsp+78h+var_70] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aAnd; " and " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA6_cEERS0_RKT_; testing::AssertionResult::operator<<<char [6]>(char [6] const&) mov rsi, rsp mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aWhichIsSmaller+5Fh; " is " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA5_cEERS0_RKT_; testing::AssertionResult::operator<<<char [5]>(char [5] const&) lea rsi, [rsp+78h+var_38] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, aWhichExceeds; ", which exceeds " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA17_cEERS0_RKT_; testing::AssertionResult::operator<<<char [17]>(char [17] const&) lea rsi, [rsp+78h+var_40] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aWhere; ", where\n" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA9_cEERS0_RKT_; testing::AssertionResult::operator<<<char [9]>(char [9] const&) lea rsi, [rsp+78h+var_70] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aEvaluatesTo; " evaluates to " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA15_cEERS0_RKT_; testing::AssertionResult::operator<<<char [15]>(char [15] const&) lea rsi, [rsp+78h+var_48] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, asc_436C4+1; ",\n" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA3_cEERS0_RKT_; testing::AssertionResult::operator<<<char [3]>(char [3] const&) mov rsi, rsp mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aEvaluatesTo; " evaluates to " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA15_cEERS0_RKT_; testing::AssertionResult::operator<<<char [15]>(char [15] const&) lea rsi, [rsp+78h+var_50] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, aAnd_0; ", and\n" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA7_cEERS0_RKT_; testing::AssertionResult::operator<<<char [7]>(char [7] const&) lea rsi, [rsp+78h+var_40] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aEvaluatesTo; " evaluates to " mov rdi, rax; this call _ZN7testing15AssertionResultlsIA15_cEERS0_RKT_; testing::AssertionResult::operator<<<char [15]>(char [15] const&) lea rsi, [rsp+78h+var_58] mov rdi, rax; this call _ZN7testing15AssertionResultlsIdEERS0_RKT_; testing::AssertionResult::operator<<<double>(double const&) lea rsi, asc_43670+1; "." mov rdi, rax; this call _ZN7testing15AssertionResultlsIA2_cEERS0_RKT_; testing::AssertionResult::operator<<<char [2]>(char [2] const&) mov rdi, rbx mov rsi, rax call _ZN7testing15AssertionResultC2ERKS0_; testing::AssertionResult::AssertionResult(testing::AssertionResult const&) loc_1E5AC: mov rsi, [rsp+78h+var_60] test rsi, rsi jz short loc_1E5BE mov rdi, r14 call _ZNKSt14default_deleteINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEclEPS5_; std::default_delete<std::string>::operator()(std::string*) loc_1E5BE: mov rax, rbx add rsp, 68h pop rbx pop r14 retn jmp short $+2 loc_1E5CB: mov rbx, rax mov rsi, [rsp+arg_10] test rsi, rsi jz short loc_1E5E0 mov rdi, r14 call _ZNKSt14default_deleteINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEclEPS5_; std::default_delete<std::string>::operator()(std::string*) loc_1E5E0: mov rdi, rbx call __Unwind_Resume
testing::internal * testing::internal::DoubleNearPredFormat( testing::internal *this, const char *a2, const char *a3, const char *a4, __m128i a5, __m128 a6, double a7) { __m128d v7; // xmm3 double v8; // xmm0_8 testing::AssertionResult *v9; // rax testing::AssertionResult *v10; // rax testing::AssertionResult *v11; // rax testing::AssertionResult *v12; // rax testing::AssertionResult *v13; // rax testing::AssertionResult *v14; // rax testing::AssertionResult *v15; // rax testing::AssertionResult *v16; // rax testing::AssertionResult *v17; // rax testing::AssertionResult *v18; // rax testing::AssertionResult *v19; // rax testing::AssertionResult *v20; // rax testing::AssertionResult *v21; // rax testing::AssertionResult *v22; // rax testing::AssertionResult *v23; // rax testing::AssertionResult *v24; // rax testing::AssertionResult *v25; // rax testing::AssertionResult *v26; // rax testing::AssertionResult *v27; // rax testing::AssertionResult *v28; // rax const testing::AssertionResult *v29; // rax testing::AssertionResult *v30; // rax testing::AssertionResult *v31; // rax testing::AssertionResult *v32; // rax testing::AssertionResult *v33; // rax testing::AssertionResult *v34; // rax testing::AssertionResult *v35; // rax testing::AssertionResult *v36; // rax testing::AssertionResult *v37; // rax testing::AssertionResult *v38; // rax testing::AssertionResult *v39; // rax testing::AssertionResult *v40; // rax testing::AssertionResult *v41; // rax testing::AssertionResult *v42; // rax testing::AssertionResult *v43; // rax testing::AssertionResult *v44; // rax testing::AssertionResult *v45; // rax testing::AssertionResult *v46; // rax testing::AssertionResult *v47; // rax testing::AssertionResult *v48; // rax testing::AssertionResult *v49; // rax const testing::AssertionResult *v50; // rax long long v52; // [rsp+0h] [rbp-78h] BYREF const char *v53; // [rsp+8h] [rbp-70h] BYREF _BYTE v54[8]; // [rsp+10h] [rbp-68h] BYREF long long v55; // [rsp+18h] [rbp-60h] BYREF double v56; // [rsp+20h] [rbp-58h] unsigned long long v57; // [rsp+28h] [rbp-50h] unsigned long long v58; // [rsp+30h] [rbp-48h] const char *v59; // [rsp+38h] [rbp-40h] BYREF double v60; // [rsp+40h] [rbp-38h] double v61; // [rsp+48h] [rbp-30h] __m128d v62; // [rsp+50h] [rbp-28h] v53 = a2; v52 = (long long)a3; v59 = a4; v58 = a5.m128i_i64[0]; v57 = a6.m128_u64[0]; v56 = a7; if ( (a5.m128i_i64[0] & 0x7FFFFFFFFFFFFFFFLL ^ 0x7FF0000000000000LL | a6.m128_u64[0] & 0x7FFFFFFFFFFFFFFFLL ^ 0x7FF0000000000000LL || a7 < INFINITY && _mm_xor_si128((__m128i)a6, a5).m128i_i64[0] < 0) && (v60 = fabs(*(double *)a5.m128i_i64 - *(double *)a6.m128_u64), a7 < v60) ) { v7 = _mm_and_pd((__m128d)a6, (__m128d)xmmword_41E50); v7.m128d_f64[0] = fmin(v7.m128d_f64[0], *(double *)_mm_and_si128(a5, (__m128i)xmmword_41E50).m128i_i64); v62 = v7; v8 = nextafter(v7.m128d_f64[0], INFINITY) - v7.m128d_f64[0]; v61 = v8; if ( v56 <= 0.0 || v8 <= v56 ) { v54[0] = 0; v55 = 0LL; v30 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [24]>( (testing::AssertionResult *)v54, v52); v31 = testing::AssertionResult::operator<<<char const*>(v30, &v53); v32 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [6]>(v31, v52); v33 = testing::AssertionResult::operator<<<char const*>(v32, (const char **)&v52); v34 = testing::AssertionResult::operator<<<char [5]>(v33, (long long)" is "); v35 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v34, v52); v36 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [17]>(v35, v52); v37 = testing::AssertionResult::operator<<<char const*>(v36, &v59); v38 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [9]>(v37, v52); v39 = testing::AssertionResult::operator<<<char const*>(v38, &v53); v40 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [15]>(v39, v52); v41 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v40, v52); v42 = testing::AssertionResult::operator<<<char [3]>(v41, (long long)",\n"); v43 = testing::AssertionResult::operator<<<char const*>(v42, (const char **)&v52); v44 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [15]>(v43, v52); v45 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v44, v52); v46 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [7]>(v45, v52); v47 = testing::AssertionResult::operator<<<char const*>(v46, &v59); v48 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [15]>(v47, v52); v49 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v48, v52); v50 = (const testing::AssertionResult *)testing::AssertionResult::operator<<<char [2]>(v49, v52); testing::AssertionResult::AssertionResult(this, v50); } else { v54[0] = 0; v55 = 0LL; v9 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [24]>( (testing::AssertionResult *)v54, v52); v10 = testing::AssertionResult::operator<<<char const*>(v9, &v53); v11 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [6]>(v10, v52); v12 = testing::AssertionResult::operator<<<char const*>(v11, (const char **)&v52); v13 = testing::AssertionResult::operator<<<char [5]>(v12, (long long)" is "); v14 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v13, v52); v15 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [9]>(v14, v52); v16 = testing::AssertionResult::operator<<<char const*>(v15, &v53); v17 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [15]>(v16, v52); v18 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v17, v52); v19 = testing::AssertionResult::operator<<<char [3]>(v18, (long long)",\n"); v20 = testing::AssertionResult::operator<<<char const*>(v19, (const char **)&v52); v21 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [15]>(v20, v52); v22 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v21, v52); v23 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [27]>(v22, v52); v24 = testing::AssertionResult::operator<<<char const*>(v23, &v59); v25 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [15]>(v24, v52); v26 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v25, v52); v27 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [100]>(v26, v52); v28 = (testing::AssertionResult *)testing::AssertionResult::operator<<<double>(v27, v52); v29 = (const testing::AssertionResult *)testing::AssertionResult::operator<<<char [106]>(v28, v52); testing::AssertionResult::AssertionResult(this, v29); } if ( v55 ) std::default_delete<std::string>::operator()((long long)&v55, v55); } else { *(_BYTE *)this = 1; *((_QWORD *)this + 1) = 0LL; } return this; }
DoubleNearPredFormat: PUSH R14 PUSH RBX SUB RSP,0x68 MOVDQA XMM3,XMM1 MOV RBX,RDI MOVQ RAX,XMM1 MOVQ RDI,XMM0 MOV qword ptr [RSP + 0x8],RSI MOV qword ptr [RSP],RDX MOV qword ptr [RSP + 0x38],RCX MOVQ qword ptr [RSP + 0x30],XMM0 MOVQ qword ptr [RSP + 0x28],XMM1 MOVSD qword ptr [RSP + 0x20],XMM2 BTR RDI,0x3f MOV RCX,0x7ff0000000000000 XOR RDI,RCX BTR RAX,0x3f XOR RAX,RCX OR RAX,RDI JNZ 0x0011e280 UCOMISD XMM2,qword ptr [0x00141f10] JNC 0x0011e45b MOVDQA XMM1,XMM3 PXOR XMM1,XMM0 MOVQ RAX,XMM1 TEST RAX,RAX JNS 0x0011e45b LAB_0011e280: MOVDQA XMM1,XMM0 SUBSD XMM1,XMM3 ANDPD XMM1,xmmword ptr [0x00141e50] MOVLPD qword ptr [RSP + 0x40],XMM1 UCOMISD XMM2,XMM1 JNC 0x0011e45b PAND XMM0,xmmword ptr [0x00141e50] ANDPD XMM3,xmmword ptr [0x00141e50] MINSD XMM3,XMM0 MOVAPD xmmword ptr [RSP + 0x50],XMM3 MOVSD XMM1,qword ptr [0x00141f10] MOVAPD XMM0,XMM3 CALL 0x00108380 SUBSD XMM0,qword ptr [RSP + 0x50] MOVSD qword ptr [RSP + 0x48],XMM0 MOVSD XMM1,qword ptr [RSP + 0x30] UCOMISD XMM1,XMM1 JP 0x0011e46b MOVSD XMM1,qword ptr [RSP + 0x28] UCOMISD XMM1,XMM1 JP 0x0011e46b MOVSD XMM1,qword ptr [RSP + 0x20] XORPD XMM2,XMM2 UCOMISD XMM1,XMM2 JBE 0x0011e46b UCOMISD XMM0,XMM1 JBE 0x0011e46b LEA R14,[RSP + 0x18] MOV byte ptr [R14 + -0x8],0x0 MOV qword ptr [R14],0x0 LAB_0011e326: LEA RSI,[0x142b96] LEA RDI,[RSP + 0x10] CALL 0x00133140 LEA RSI,[RSP + 0x8] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bae] MOV RDI,RAX CALL 0x001331be MOV RSI,RSP MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142c46] MOV RDI,RAX CALL 0x0010e820 LEA RSI,[RSP + 0x40] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x142bb4] MOV RDI,RAX CALL 0x001332ae LEA RSI,[RSP + 0x8] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bbd] MOV RDI,RAX CALL 0x0013332c LEA RSI,[RSP + 0x30] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x1436c5] MOV RDI,RAX CALL 0x0010e72e MOV RSI,RSP MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bbd] MOV RDI,RAX CALL 0x0013332c LEA RSI,[RSP + 0x28] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x142bcc] MOV RDI,RAX CALL 0x001333aa LEA RSI,[RSP + 0x38] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bbd] MOV RDI,RAX CALL 0x0013332c LEA RSI,[RSP + 0x20] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x142be7] MOV RDI,RAX CALL 0x00133428 LEA RSI,[RSP + 0x48] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x142c4b] MOV RDI,RAX CALL 0x001334a6 MOV RDI,RBX MOV RSI,RAX CALL 0x0010efc4 JMP 0x0011e5ac LAB_0011e45b: MOV byte ptr [RBX],0x1 MOV qword ptr [RBX + 0x8],0x0 JMP 0x0011e5be LAB_0011e46b: LEA R14,[RSP + 0x18] MOV byte ptr [R14 + -0x8],0x0 MOV qword ptr [R14],0x0 LAB_0011e47c: LEA RSI,[0x142b96] LEA RDI,[RSP + 0x10] CALL 0x00133140 LEA RSI,[RSP + 0x8] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bae] MOV RDI,RAX CALL 0x001331be MOV RSI,RSP MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142c46] MOV RDI,RAX CALL 0x0010e820 LEA RSI,[RSP + 0x40] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x142cb5] MOV RDI,RAX CALL 0x00133524 LEA RSI,[RSP + 0x38] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bb4] MOV RDI,RAX CALL 0x001332ae LEA RSI,[RSP + 0x8] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bbd] MOV RDI,RAX CALL 0x0013332c LEA RSI,[RSP + 0x30] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x1436c5] MOV RDI,RAX CALL 0x0010e72e MOV RSI,RSP MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bbd] MOV RDI,RAX CALL 0x0013332c LEA RSI,[RSP + 0x28] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x142cc6] MOV RDI,RAX CALL 0x001335a2 LEA RSI,[RSP + 0x38] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142bbd] MOV RDI,RAX CALL 0x0013332c LEA RSI,[RSP + 0x20] MOV RDI,RAX CALL 0x0013323c LEA RSI,[0x143671] MOV RDI,RAX CALL 0x00133620 MOV RDI,RBX MOV RSI,RAX CALL 0x0010efc4 LAB_0011e5ac: MOV RSI,qword ptr [RSP + 0x18] TEST RSI,RSI JZ 0x0011e5be MOV RDI,R14 CALL 0x0010de4a LAB_0011e5be: MOV RAX,RBX ADD RSP,0x68 POP RBX POP R14 RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* testing::internal::DoubleNearPredFormat(char const*, char const*, char const*, double, double, double) */ internal * __thiscall testing::internal::DoubleNearPredFormat (internal *this,char *param_1,char *param_2,char *param_3,double param_4,double param_5, double param_6) { AssertionResult *pAVar1; ulong in_XMM1_Qb; char *local_78; char *local_70; AssertionResult local_68 [8]; string *local_60; double local_58; double local_50; double local_48; char *local_40; double local_38; double local_30; double local_28; ulong uStack_20; if (((ABS(param_5) == INFINITY && ABS(param_4) == INFINITY) && ((DAT_00141f10 <= param_6 || (-1 < (long)((ulong)param_5 ^ (ulong)param_4))))) || (local_38 = (double)((ulong)(param_4 - param_5) & _DAT_00141e50), local_38 <= param_6)) { *this = (internal)0x1; *(int8 *)(this + 8) = 0; } else { uStack_20 = in_XMM1_Qb & _UNK_00141e58; local_28 = (double)((ulong)param_5 & _DAT_00141e50); if ((double)((ulong)param_4 & _DAT_00141e50) <= (double)((ulong)param_5 & _DAT_00141e50)) { local_28 = (double)((ulong)param_4 & _DAT_00141e50); } local_78 = param_2; local_70 = param_1; local_58 = param_6; local_50 = param_5; local_48 = param_4; local_40 = param_3; local_30 = nextafter(local_28,DAT_00141f10); local_30 = local_30 - local_28; if ((((NAN(local_48)) || (NAN(local_50))) || (local_58 <= 0.0)) || (local_30 <= local_58)) { local_68[0] = (AssertionResult)0x0; local_60 = (string *)0x0; /* try { // try from 0011e47c to 0011e5ab has its CatchHandler @ 0011e5cb */ pAVar1 = AssertionResult::operator<<(local_68,"The difference between "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_70); pAVar1 = AssertionResult::operator<<(pAVar1," and "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_78); pAVar1 = AssertionResult::operator<<(pAVar1," is "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_38); pAVar1 = AssertionResult::operator<<(pAVar1,", which exceeds "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_40); pAVar1 = AssertionResult::operator<<(pAVar1,", where\n"); pAVar1 = AssertionResult::operator<<(pAVar1,&local_70); pAVar1 = AssertionResult::operator<<(pAVar1," evaluates to "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_48); pAVar1 = AssertionResult::operator<<(pAVar1,",\n"); pAVar1 = AssertionResult::operator<<(pAVar1,&local_78); pAVar1 = AssertionResult::operator<<(pAVar1," evaluates to "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_50); pAVar1 = AssertionResult::operator<<(pAVar1,", and\n"); pAVar1 = AssertionResult::operator<<(pAVar1,&local_40); pAVar1 = AssertionResult::operator<<(pAVar1," evaluates to "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_58); pAVar1 = AssertionResult::operator<<(pAVar1,"."); AssertionResult::AssertionResult((AssertionResult *)this,pAVar1); } else { local_68[0] = (AssertionResult)0x0; local_60 = (string *)0x0; /* try { // try from 0011e326 to 0011e455 has its CatchHandler @ 0011e5c9 */ pAVar1 = AssertionResult::operator<<(local_68,"The difference between "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_70); pAVar1 = AssertionResult::operator<<(pAVar1," and "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_78); pAVar1 = AssertionResult::operator<<(pAVar1," is "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_38); pAVar1 = AssertionResult::operator<<(pAVar1,", where\n"); pAVar1 = AssertionResult::operator<<(pAVar1,&local_70); pAVar1 = AssertionResult::operator<<(pAVar1," evaluates to "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_48); pAVar1 = AssertionResult::operator<<(pAVar1,",\n"); pAVar1 = AssertionResult::operator<<(pAVar1,&local_78); pAVar1 = AssertionResult::operator<<(pAVar1," evaluates to "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_50); pAVar1 = AssertionResult::operator<<(pAVar1,".\nThe abs_error parameter "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_40); pAVar1 = AssertionResult::operator<<(pAVar1," evaluates to "); pAVar1 = AssertionResult::operator<<(pAVar1,&local_58); pAVar1 = AssertionResult::operator<< (pAVar1, " which is smaller than the minimum distance between doubles for numbers of this magnitude which is " ); pAVar1 = AssertionResult::operator<<(pAVar1,&local_30); pAVar1 = AssertionResult::operator<< (pAVar1, ", thus making this EXPECT_NEAR check equivalent to EXPECT_EQUAL. Consider using EXPECT_DOUBLE_EQ instead." ); AssertionResult::AssertionResult((AssertionResult *)this,pAVar1); } if (local_60 != (string *)0x0) { std::default_delete<std::__cxx11::string>::operator() ((default_delete<std::__cxx11::string> *)&local_60,local_60); } } return this; }
56,844
insert_dynamic
eloqsql/mysys/array.c
my_bool insert_dynamic(DYNAMIC_ARRAY *array, const void * element) { void *buffer; if (array->elements == array->max_element) { /* Call only when necessary */ if (!(buffer=alloc_dynamic(array))) return TRUE; } else { buffer=array->buffer+(array->elements * array->size_of_element); array->elements++; } memcpy(buffer,element,(size_t) array->size_of_element); return FALSE; }
O3
c
insert_dynamic: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rsi, %rbx movq %rdi, %r14 movl 0x8(%rdi), %ecx cmpl 0xc(%rdi), %ecx jne 0x44999 movq %r14, %rdi callq 0x449c0 testq %rax, %rax je 0x449bc movq %rax, %rdi movl 0x14(%r14), %eax jmp 0x449ab movl 0x14(%r14), %eax movl %eax, %edi imull %ecx, %edi addq (%r14), %rdi incl %ecx movl %ecx, 0x8(%r14) movl %eax, %edx movq %rbx, %rsi callq 0x26290 xorl %eax, %eax popq %rbx popq %r14 popq %rbp retq movb $0x1, %al jmp 0x449b7
insert_dynamic: push rbp mov rbp, rsp push r14 push rbx mov rbx, rsi mov r14, rdi mov ecx, [rdi+8] cmp ecx, [rdi+0Ch] jnz short loc_44999 mov rdi, r14 call alloc_dynamic test rax, rax jz short loc_449BC mov rdi, rax mov eax, [r14+14h] jmp short loc_449AB loc_44999: mov eax, [r14+14h] mov edi, eax imul edi, ecx add rdi, [r14] inc ecx mov [r14+8], ecx loc_449AB: mov edx, eax mov rsi, rbx call _memcpy xor eax, eax loc_449B7: pop rbx pop r14 pop rbp retn loc_449BC: mov al, 1 jmp short loc_449B7
long long insert_dynamic(long long a1, long long a2) { int v3; // ecx long long v4; // rax long long v5; // rdi unsigned int v6; // eax v3 = *(_DWORD *)(a1 + 8); if ( v3 != *(_DWORD *)(a1 + 12) ) { v6 = *(_DWORD *)(a1 + 20); v5 = *(_QWORD *)a1 + v3 * v6; *(_DWORD *)(a1 + 8) = v3 + 1; goto LABEL_5; } v4 = alloc_dynamic(a1); if ( v4 ) { v5 = v4; v6 = *(_DWORD *)(a1 + 20); LABEL_5: memcpy(v5, a2, v6); return 0LL; } return 1LL; }
insert_dynamic: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,RSI MOV R14,RDI MOV ECX,dword ptr [RDI + 0x8] CMP ECX,dword ptr [RDI + 0xc] JNZ 0x00144999 MOV RDI,R14 CALL 0x001449c0 TEST RAX,RAX JZ 0x001449bc MOV RDI,RAX MOV EAX,dword ptr [R14 + 0x14] JMP 0x001449ab LAB_00144999: MOV EAX,dword ptr [R14 + 0x14] MOV EDI,EAX IMUL EDI,ECX ADD RDI,qword ptr [R14] INC ECX MOV dword ptr [R14 + 0x8],ECX LAB_001449ab: MOV EDX,EAX MOV RSI,RBX CALL 0x00126290 XOR EAX,EAX LAB_001449b7: POP RBX POP R14 POP RBP RET LAB_001449bc: MOV AL,0x1 JMP 0x001449b7
int8 insert_dynamic(long *param_1,void *param_2) { int iVar1; uint uVar2; void *__dest; iVar1 = (int)param_1[1]; if (iVar1 == *(int *)((long)param_1 + 0xc)) { __dest = (void *)alloc_dynamic(param_1); if (__dest == (void *)0x0) { return 1; } uVar2 = *(uint *)((long)param_1 + 0x14); } else { uVar2 = *(uint *)((long)param_1 + 0x14); __dest = (void *)((ulong)(uVar2 * iVar1) + *param_1); *(int *)(param_1 + 1) = iVar1 + 1; } memcpy(__dest,param_2,(ulong)uVar2); return 0; }
56,845
maria_rtree_get_next
eloqsql/storage/maria/ma_rt_index.c
int maria_rtree_get_next(MARIA_HA *info, uint keynr, uint key_length) { my_off_t root; MARIA_KEYDEF *keyinfo= info->s->keyinfo + keynr; uchar *keyread_buff= info->keyread_buff; if (!info->keyread_buff_used) { uint key_data_length= keyinfo->keylength - info->s->base.rec_reflength; /* rt_PAGE_NEXT_KEY(*info->last_rtree_keypos) */ uchar *key= keyread_buff + *info->last_rtree_keypos + keyinfo->keylength; /* rt_PAGE_NEXT_KEY(key) */ uchar *after_key= key + keyinfo->keylength; MARIA_KEY tmp_key; tmp_key.keyinfo= keyinfo; tmp_key.data= key; tmp_key.data_length= key_data_length; tmp_key.ref_length= info->s->base.rec_reflength; tmp_key.flag= 0; info->cur_row.lastpos= _ma_row_pos_from_key(&tmp_key); _ma_copy_key(&info->last_key, &tmp_key); *info->last_rtree_keypos= (uint) (key - keyread_buff); if (after_key >= info->int_maxpos) { info->keyread_buff_used= 1; } return 0; } else { if ((root= info->s->state.key_root[keynr]) == HA_OFFSET_ERROR) { my_errno= HA_ERR_END_OF_FILE; return -1; } return maria_rtree_get_req(info, &keyinfo[keynr], key_length, root, 0); } }
O0
c
maria_rtree_get_next: pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) movl %edx, -0x18(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rax movq 0x570(%rax), %rax movl -0x14(%rbp), %ecx imulq $0x118, %rcx, %rcx # imm = 0x118 addq %rcx, %rax movq %rax, -0x28(%rbp) movq -0x10(%rbp), %rax movq 0x380(%rax), %rax movq %rax, -0x30(%rbp) movq -0x10(%rbp), %rax cmpb $0x0, 0x685(%rax) jne 0x797f5 movq -0x28(%rbp), %rax movzwl 0xaa(%rax), %eax movq -0x10(%rbp), %rcx movq (%rcx), %rcx subl 0x3e0(%rcx), %eax movl %eax, -0x34(%rbp) movq -0x30(%rbp), %rax movq -0x10(%rbp), %rcx movq 0x638(%rcx), %rcx movl (%rcx), %ecx addq %rcx, %rax movq -0x28(%rbp), %rcx movzwl 0xaa(%rcx), %ecx movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x40(%rbp) movq -0x40(%rbp), %rax movq -0x28(%rbp), %rcx movzwl 0xaa(%rcx), %ecx movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x48(%rbp) movq -0x28(%rbp), %rax movq %rax, -0x60(%rbp) movq -0x40(%rbp), %rax movq %rax, -0x68(%rbp) movl -0x34(%rbp), %eax movl %eax, -0x58(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rax movl 0x3e0(%rax), %eax movl %eax, -0x54(%rbp) movl $0x0, -0x50(%rbp) leaq -0x68(%rbp), %rdi callq 0x3ba20 movq %rax, %rcx movq -0x10(%rbp), %rax movq %rcx, 0x98(%rax) movq -0x10(%rbp), %rdi addq $0x200, %rdi # imm = 0x200 leaq -0x68(%rbp), %rsi callq 0x444e0 movq -0x40(%rbp), %rax movq -0x30(%rbp), %rcx subq %rcx, %rax movl %eax, %ecx movq -0x10(%rbp), %rax movq 0x638(%rax), %rax movl %ecx, (%rax) movq -0x48(%rbp), %rax movq -0x10(%rbp), %rcx cmpq 0x3b8(%rcx), %rax jb 0x797ec movq -0x10(%rbp), %rax movb $0x1, 0x685(%rax) movl $0x0, -0x4(%rbp) jmp 0x7984f movq -0x10(%rbp), %rax movq (%rax), %rax movq 0x118(%rax), %rax movl -0x14(%rbp), %ecx movq (%rax,%rcx,8), %rax movq %rax, -0x20(%rbp) cmpq $-0x1, %rax jne 0x79828 callq 0xfea30 movl $0x89, (%rax) movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0x7984f movq -0x10(%rbp), %rdi movq -0x28(%rbp), %rsi movl -0x14(%rbp), %eax imulq $0x118, %rax, %rax # imm = 0x118 addq %rax, %rsi movl -0x18(%rbp), %edx movq -0x20(%rbp), %rcx xorl %r8d, %r8d callq 0x79180 movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x70, %rsp popq %rbp retq nopl (%rax,%rax)
maria_rtree_get_next: push rbp mov rbp, rsp sub rsp, 70h mov [rbp+var_10], rdi mov [rbp+var_14], esi mov [rbp+var_18], edx mov rax, [rbp+var_10] mov rax, [rax] mov rax, [rax+570h] mov ecx, [rbp+var_14] imul rcx, 118h add rax, rcx mov [rbp+var_28], rax mov rax, [rbp+var_10] mov rax, [rax+380h] mov [rbp+var_30], rax mov rax, [rbp+var_10] cmp byte ptr [rax+685h], 0 jnz loc_797F5 mov rax, [rbp+var_28] movzx eax, word ptr [rax+0AAh] mov rcx, [rbp+var_10] mov rcx, [rcx] sub eax, [rcx+3E0h] mov [rbp+var_34], eax mov rax, [rbp+var_30] mov rcx, [rbp+var_10] mov rcx, [rcx+638h] mov ecx, [rcx] add rax, rcx mov rcx, [rbp+var_28] movzx ecx, word ptr [rcx+0AAh] movsxd rcx, ecx add rax, rcx mov [rbp+var_40], rax mov rax, [rbp+var_40] mov rcx, [rbp+var_28] movzx ecx, word ptr [rcx+0AAh] movsxd rcx, ecx add rax, rcx mov [rbp+var_48], rax mov rax, [rbp+var_28] mov [rbp+var_60], rax mov rax, [rbp+var_40] mov [rbp+var_68], rax mov eax, [rbp+var_34] mov [rbp+var_58], eax mov rax, [rbp+var_10] mov rax, [rax] mov eax, [rax+3E0h] mov [rbp+var_54], eax mov [rbp+var_50], 0 lea rdi, [rbp+var_68] call _ma_row_pos_from_key mov rcx, rax mov rax, [rbp+var_10] mov [rax+98h], rcx mov rdi, [rbp+var_10] add rdi, 200h lea rsi, [rbp+var_68] call _ma_copy_key mov rax, [rbp+var_40] mov rcx, [rbp+var_30] sub rax, rcx mov ecx, eax mov rax, [rbp+var_10] mov rax, [rax+638h] mov [rax], ecx mov rax, [rbp+var_48] mov rcx, [rbp+var_10] cmp rax, [rcx+3B8h] jb short loc_797EC mov rax, [rbp+var_10] mov byte ptr [rax+685h], 1 loc_797EC: mov [rbp+var_4], 0 jmp short loc_7984F loc_797F5: mov rax, [rbp+var_10] mov rax, [rax] mov rax, [rax+118h] mov ecx, [rbp+var_14] mov rax, [rax+rcx*8] mov [rbp+var_20], rax cmp rax, 0FFFFFFFFFFFFFFFFh jnz short loc_79828 call _my_thread_var mov dword ptr [rax], 89h mov [rbp+var_4], 0FFFFFFFFh jmp short loc_7984F loc_79828: mov rdi, [rbp+var_10] mov rsi, [rbp+var_28] mov eax, [rbp+var_14] imul rax, 118h add rsi, rax mov edx, [rbp+var_18] mov rcx, [rbp+var_20] xor r8d, r8d call maria_rtree_get_req mov [rbp+var_4], eax loc_7984F: mov eax, [rbp+var_4] add rsp, 70h pop rbp retn
long long maria_rtree_get_next(long long a1, const char *a2, unsigned int a3) { long long v3; // rax _QWORD v5[2]; // [rsp+8h] [rbp-68h] BYREF int v6; // [rsp+18h] [rbp-58h] int v7; // [rsp+1Ch] [rbp-54h] int v8; // [rsp+20h] [rbp-50h] unsigned long long v9; // [rsp+28h] [rbp-48h] long long v10; // [rsp+30h] [rbp-40h] int v11; // [rsp+3Ch] [rbp-34h] long long v12; // [rsp+40h] [rbp-30h] long long v13; // [rsp+48h] [rbp-28h] unsigned long long v14; // [rsp+50h] [rbp-20h] unsigned int v15; // [rsp+58h] [rbp-18h] unsigned int v16; // [rsp+5Ch] [rbp-14h] long long v17; // [rsp+60h] [rbp-10h] v17 = a1; v16 = (unsigned int)a2; v15 = a3; v13 = 280LL * (unsigned int)a2 + *(_QWORD *)(*(_QWORD *)a1 + 1392LL); v12 = *(_QWORD *)(a1 + 896); if ( *(_BYTE *)(a1 + 1669) ) { v14 = *(_QWORD *)(*(_QWORD *)(*(_QWORD *)v17 + 280LL) + 8LL * v16); if ( v14 == -1LL ) { *(_DWORD *)my_thread_var(a1, a2) = 137; return (unsigned int)-1; } else { return (unsigned int)maria_rtree_get_req(v17, 280LL * v16 + v13, v15, v14, 0); } } else { v11 = *(unsigned __int16 *)(v13 + 170) - *(_DWORD *)(*(_QWORD *)v17 + 992LL); v10 = *(unsigned __int16 *)(v13 + 170) + **(unsigned int **)(v17 + 1592) + v12; v9 = *(unsigned __int16 *)(v13 + 170) + v10; v5[1] = v13; v5[0] = v10; v6 = v11; v7 = *(_DWORD *)(*(_QWORD *)v17 + 992LL); v8 = 0; v3 = ma_row_pos_from_key((long long)v5); *(_QWORD *)(v17 + 152) = v3; ma_copy_key(v17 + 512, (long long)v5); **(_DWORD **)(v17 + 1592) = v10 - v12; if ( v9 >= *(_QWORD *)(v17 + 952) ) *(_BYTE *)(v17 + 1669) = 1; return 0; } }
maria_rtree_get_next: PUSH RBP MOV RBP,RSP SUB RSP,0x70 MOV qword ptr [RBP + -0x10],RDI MOV dword ptr [RBP + -0x14],ESI MOV dword ptr [RBP + -0x18],EDX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x570] MOV ECX,dword ptr [RBP + -0x14] IMUL RCX,RCX,0x118 ADD RAX,RCX MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x380] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x10] CMP byte ptr [RAX + 0x685],0x0 JNZ 0x001797f5 MOV RAX,qword ptr [RBP + -0x28] MOVZX EAX,word ptr [RAX + 0xaa] MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX] SUB EAX,dword ptr [RCX + 0x3e0] MOV dword ptr [RBP + -0x34],EAX MOV RAX,qword ptr [RBP + -0x30] MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX + 0x638] MOV ECX,dword ptr [RCX] ADD RAX,RCX MOV RCX,qword ptr [RBP + -0x28] MOVZX ECX,word ptr [RCX + 0xaa] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x40],RAX MOV RAX,qword ptr [RBP + -0x40] MOV RCX,qword ptr [RBP + -0x28] MOVZX ECX,word ptr [RCX + 0xaa] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x60],RAX MOV RAX,qword ptr [RBP + -0x40] MOV qword ptr [RBP + -0x68],RAX MOV EAX,dword ptr [RBP + -0x34] MOV dword ptr [RBP + -0x58],EAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV EAX,dword ptr [RAX + 0x3e0] MOV dword ptr [RBP + -0x54],EAX MOV dword ptr [RBP + -0x50],0x0 LEA RDI,[RBP + -0x68] CALL 0x0013ba20 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x98],RCX MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x200 LEA RSI,[RBP + -0x68] CALL 0x001444e0 MOV RAX,qword ptr [RBP + -0x40] MOV RCX,qword ptr [RBP + -0x30] SUB RAX,RCX MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x638] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x48] MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0x3b8] JC 0x001797ec MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x685],0x1 LAB_001797ec: MOV dword ptr [RBP + -0x4],0x0 JMP 0x0017984f LAB_001797f5: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x118] MOV ECX,dword ptr [RBP + -0x14] MOV RAX,qword ptr [RAX + RCX*0x8] MOV qword ptr [RBP + -0x20],RAX CMP RAX,-0x1 JNZ 0x00179828 CALL 0x001fea30 MOV dword ptr [RAX],0x89 MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x0017984f LAB_00179828: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x28] MOV EAX,dword ptr [RBP + -0x14] IMUL RAX,RAX,0x118 ADD RSI,RAX MOV EDX,dword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x20] XOR R8D,R8D CALL 0x00179180 MOV dword ptr [RBP + -0x4],EAX LAB_0017984f: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x70 POP RBP RET
int4 maria_rtree_get_next(long *param_1,uint param_2,int4 param_3) { long lVar1; int4 *puVar2; long local_70; long local_68; int local_60; int4 local_5c; int4 local_58; ulong local_50; long local_48; int local_3c; long local_38; long local_30; long local_28; int4 local_20; uint local_1c; long *local_18; int4 local_c; local_68 = *(long *)(*param_1 + 0x570) + (ulong)param_2 * 0x118; local_38 = param_1[0x70]; local_30 = local_68; local_20 = param_3; local_1c = param_2; local_18 = param_1; if (*(char *)((long)param_1 + 0x685) == '\0') { local_60 = (uint)*(ushort *)(local_68 + 0xaa) - *(int *)(*param_1 + 0x3e0); local_70 = local_38 + (ulong)*(uint *)param_1[199] + (long)(int)(uint)*(ushort *)(local_68 + 0xaa); local_50 = local_70 + (int)(uint)*(ushort *)(local_68 + 0xaa); local_5c = *(int4 *)(*param_1 + 0x3e0); local_58 = 0; local_48 = local_70; local_3c = local_60; lVar1 = _ma_row_pos_from_key(&local_70); local_18[0x13] = lVar1; _ma_copy_key(local_18 + 0x40,&local_70); *(int *)local_18[199] = (int)local_48 - (int)local_38; if ((ulong)local_18[0x77] <= local_50) { *(int1 *)((long)local_18 + 0x685) = 1; } local_c = 0; } else { local_28 = *(long *)(*(long *)(*param_1 + 0x118) + (ulong)param_2 * 8); if (local_28 == -1) { puVar2 = (int4 *)_my_thread_var(); *puVar2 = 0x89; local_c = 0xffffffff; } else { local_c = maria_rtree_get_req(param_1,local_68 + (ulong)param_2 * 0x118,param_3,local_28,0); } } return local_c; }
56,846
std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> string_split<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char)
monkey531[P]llama/common/common.h
std::vector<std::string> string_split<std::string>(const std::string & input, char separator) { std::vector<std::string> parts; size_t begin_pos = 0; size_t separator_pos = input.find(separator); while (separator_pos != std::string::npos) { std::string part = input.substr(begin_pos, separator_pos - begin_pos); parts.emplace_back(part); begin_pos = separator_pos + 1; separator_pos = input.find(separator, begin_pos); } parts.emplace_back(input.substr(begin_pos, separator_pos - begin_pos)); return parts; }
O2
c
std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> string_split<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movl %edx, %ebp movq %rsi, %r14 movq %rdi, %rbx xorps %xmm0, %xmm0 movups %xmm0, (%rdi) andq $0x0, 0x10(%rdi) xorl %r13d, %r13d movq %rsi, %rdi movl %edx, %esi xorl %edx, %edx callq 0x24b40 movq %rax, %r15 leaq 0x8(%rsp), %r12 movsbl %bpl, %eax movl %eax, 0x4(%rsp) cmpq $-0x1, %r15 je 0x36395 movq %r15, %rcx subq %r13, %rcx movq %r12, %rdi movq %r14, %rsi movq %r13, %rdx callq 0x24920 movq %rbx, %rbp movq %rbx, %rdi movq %r12, %rsi callq 0x3b7f6 incq %r15 movq %r14, %rdi movl 0x4(%rsp), %esi movq %r15, %rdx callq 0x24b40 movq %rax, %rbx movq %r12, %rdi callq 0x251d8 movq %r15, %r13 movq %rbx, %r15 movq %rbp, %rbx jmp 0x36345 movq %r13, %rcx notq %rcx leaq 0x8(%rsp), %rdi movq %r14, %rsi movq %r13, %rdx callq 0x24920 leaq 0x8(%rsp), %rsi movq %rbx, %rdi callq 0x3b832 leaq 0x8(%rsp), %rdi callq 0x251d8 movq %rbx, %rax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rbx, %rbp jmp 0x363e3 jmp 0x363db movq %rbx, %rbp movq %rax, %r14 jmp 0x363f0 movq %rax, %r14 leaq 0x8(%rsp), %rdi callq 0x251d8 movq %rbp, %rdi callq 0x2801a movq %r14, %rdi callq 0x24f80
_ZL12string_splitINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEESt6vectorIT_SaIS7_EERKS5_c: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov ebp, edx mov r14, rsi mov rbx, rdi xorps xmm0, xmm0 movups xmmword ptr [rdi], xmm0 and qword ptr [rdi+10h], 0 xor r13d, r13d mov rdi, rsi mov esi, edx xor edx, edx call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEcm; std::string::find(char,ulong) mov r15, rax lea r12, [rsp+58h+var_50] movsx eax, bpl mov [rsp+58h+var_54], eax loc_36345: cmp r15, 0FFFFFFFFFFFFFFFFh jz short loc_36395 mov rcx, r15 sub rcx, r13 mov rdi, r12 mov rsi, r14 mov rdx, r13 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) mov rbp, rbx mov rdi, rbx mov rsi, r12 call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJRS5_EEES9_DpOT_; std::vector<std::string>::emplace_back<std::string&>(std::string&) inc r15 mov rdi, r14 mov esi, [rsp+58h+var_54] mov rdx, r15 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEcm; std::string::find(char,ulong) mov rbx, rax mov rdi, r12; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov r13, r15 mov r15, rbx mov rbx, rbp jmp short loc_36345 loc_36395: mov rcx, r13 not rcx lea rdi, [rsp+58h+var_50] mov rsi, r14 mov rdx, r13 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) lea rsi, [rsp+58h+var_50] mov rdi, rbx call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&) lea rdi, [rsp+58h+var_50]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rax, rbx add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbp, rbx jmp short loc_363E3 jmp short $+2 loc_363DB: mov rbp, rbx mov r14, rax jmp short loc_363F0 loc_363E3: mov r14, rax lea rdi, [rsp+arg_0]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() loc_363F0: mov rdi, rbp call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() mov rdi, r14 call __Unwind_Resume
long long string_split<std::string>(long long a1, long long a2, unsigned int a3) { char v3; // bp long long v4; // rbx long long v5; // r13 long long v6; // r15 long long v7; // rbp long long v8; // r15 long long v9; // rbx unsigned int v11; // [rsp+4h] [rbp-54h] _BYTE v12[80]; // [rsp+8h] [rbp-50h] BYREF v3 = a3; v4 = a1; *(_OWORD *)a1 = 0LL; *(_QWORD *)(a1 + 16) = 0LL; v5 = 0LL; v6 = std::string::find(a2, a3, 0LL); v11 = v3; while ( v6 != -1 ) { std::string::substr(v12, a2, v5, v6 - v5); v7 = v4; std::vector<std::string>::emplace_back<std::string&>(v4, v12); v8 = v6 + 1; v9 = std::string::find(a2, v11, v8); std::string::~string(v12); v5 = v8; v6 = v9; v4 = v7; } std::string::substr(v12, a2, v5, ~v5); std::vector<std::string>::emplace_back<std::string>(v4, v12); std::string::~string(v12); return v4; }
string_split<std::__cxx11::string>: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV EBP,EDX MOV R14,RSI MOV RBX,RDI XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI],XMM0 AND qword ptr [RDI + 0x10],0x0 XOR R13D,R13D MOV RDI,RSI MOV ESI,EDX XOR EDX,EDX CALL 0x00124b40 MOV R15,RAX LEA R12,[RSP + 0x8] MOVSX EAX,BPL MOV dword ptr [RSP + 0x4],EAX LAB_00136345: CMP R15,-0x1 JZ 0x00136395 MOV RCX,R15 SUB RCX,R13 LAB_00136351: MOV RDI,R12 MOV RSI,R14 MOV RDX,R13 CALL 0x00124920 LAB_0013635f: MOV RBP,RBX MOV RDI,RBX MOV RSI,R12 CALL 0x0013b7f6 INC R15 MOV RDI,R14 MOV ESI,dword ptr [RSP + 0x4] MOV RDX,R15 CALL 0x00124b40 MOV RBX,RAX MOV RDI,R12 CALL 0x001251d8 MOV R13,R15 MOV R15,RBX MOV RBX,RBP JMP 0x00136345 LAB_00136395: MOV RCX,R13 NOT RCX LAB_0013639b: LEA RDI,[RSP + 0x8] MOV RSI,R14 MOV RDX,R13 CALL 0x00124920 LAB_001363ab: LEA RSI,[RSP + 0x8] MOV RDI,RBX CALL 0x0013b832 LAB_001363b8: LEA RDI,[RSP + 0x8] CALL 0x001251d8 MOV RAX,RBX ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* std::vector<std::__cxx11::string, std::allocator<std::__cxx11::string > > string_split<std::__cxx11::string >(std::__cxx11::string const&, char) */ string * string_split<std::__cxx11::string>(string *param_1,char param_2) { long lVar1; uint in_EDX; int7 in_register_00000031; string local_50 [32]; *(int8 *)param_1 = 0; *(int8 *)(param_1 + 8) = 0; *(int8 *)(param_1 + 0x10) = 0; lVar1 = std::__cxx11::string::find(param_2,(ulong)in_EDX); while (lVar1 != -1) { /* try { // try from 00136351 to 0013635e has its CatchHandler @ 001363db */ std::__cxx11::string::substr((ulong)local_50,CONCAT71(in_register_00000031,param_2)); /* try { // try from 0013635f to 0013636c has its CatchHandler @ 001363e3 */ std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>:: emplace_back<std::__cxx11::string&> ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1,local_50 ); lVar1 = std::__cxx11::string::find(param_2,(ulong)(uint)(int)(char)in_EDX); std::__cxx11::string::~string(local_50); } /* try { // try from 0013639b to 001363aa has its CatchHandler @ 001363d9 */ std::__cxx11::string::substr((ulong)local_50,CONCAT71(in_register_00000031,param_2)); /* try { // try from 001363ab to 001363b7 has its CatchHandler @ 001363d4 */ std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>:: emplace_back<std::__cxx11::string> ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1,local_50); std::__cxx11::string::~string(local_50); return param_1; }
56,847
std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> string_split<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char)
monkey531[P]llama/common/common.h
std::vector<std::string> string_split<std::string>(const std::string & input, char separator) { std::vector<std::string> parts; size_t begin_pos = 0; size_t separator_pos = input.find(separator); while (separator_pos != std::string::npos) { std::string part = input.substr(begin_pos, separator_pos - begin_pos); parts.emplace_back(part); begin_pos = separator_pos + 1; separator_pos = input.find(separator, begin_pos); } parts.emplace_back(input.substr(begin_pos, separator_pos - begin_pos)); return parts; }
O3
c
std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> string_split<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movl %edx, %ebp movq %rsi, %r14 movq %rdi, %rbx xorps %xmm0, %xmm0 movups %xmm0, (%rdi) movq $0x0, 0x10(%rdi) xorl %r15d, %r15d movq %rsi, %rdi movl %edx, %esi xorl %edx, %edx callq 0x1bb10 cmpq $-0x1, %rax je 0x4f15e movq %rax, %r12 xorl %r15d, %r15d leaq 0x8(%rsp), %r13 movsbl %bpl, %ebp movq %r12, %rcx subq %r15, %rcx movq %r13, %rdi movq %r14, %rsi movq %r15, %rdx callq 0x1b910 movq %rbx, %rdi movq %r13, %rsi callq 0x561f8 movq %r12, %r15 incq %r15 movq %r14, %rdi movl %ebp, %esi movq %r15, %rdx callq 0x1bb10 movq %rax, %r12 movq 0x8(%rsp), %rdi leaq 0x18(%rsp), %rax cmpq %rax, %rdi je 0x4f158 movq 0x18(%rsp), %rsi incq %rsi callq 0x1b8c0 cmpq $-0x1, %r12 jne 0x4f107 movq %r15, %rcx notq %rcx leaq 0x8(%rsp), %rdi movq %r14, %rsi movq %r15, %rdx callq 0x1b910 leaq 0x8(%rsp), %rsi movq %rbx, %rdi callq 0x56246 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x4f19c movq 0x18(%rsp), %rsi incq %rsi callq 0x1b8c0 addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi jmp 0x4f1cd jmp 0x4f1bb movq %rax, %r14 jmp 0x4f1df movq %rax, %r14 movq 0x8(%rsp), %rdi leaq 0x18(%rsp), %rax cmpq %rax, %rdi je 0x4f1df movq 0x18(%rsp), %rsi incq %rsi callq 0x1b8c0 movq %rbx, %rdi callq 0x21ff8 movq %r14, %rdi callq 0x1bf90 nop
_ZL12string_splitINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEESt6vectorIT_SaIS7_EERKS5_c: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov ebp, edx mov r14, rsi mov rbx, rdi xorps xmm0, xmm0 movups xmmword ptr [rdi], xmm0 mov qword ptr [rdi+10h], 0 xor r15d, r15d mov rdi, rsi mov esi, edx xor edx, edx call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEcm; std::string::find(char,ulong) cmp rax, 0FFFFFFFFFFFFFFFFh jz short loc_4F15E mov r12, rax xor r15d, r15d lea r13, [rsp+58h+var_50] movsx ebp, bpl loc_4F107: mov rcx, r12 sub rcx, r15 mov rdi, r13 mov rsi, r14 mov rdx, r15 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) mov rdi, rbx mov rsi, r13 call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJRS5_EEES9_DpOT_; std::vector<std::string>::emplace_back<std::string&>(std::string&) mov r15, r12 inc r15 mov rdi, r14 mov esi, ebp mov rdx, r15 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEcm; std::string::find(char,ulong) mov r12, rax mov rdi, [rsp+58h+var_50]; void * lea rax, [rsp+58h+var_40] cmp rdi, rax jz short loc_4F158 mov rsi, [rsp+58h+var_40] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_4F158: cmp r12, 0FFFFFFFFFFFFFFFFh jnz short loc_4F107 loc_4F15E: mov rcx, r15 not rcx lea rdi, [rsp+58h+var_50] mov rsi, r14 mov rdx, r15 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) lea rsi, [rsp+58h+var_50] mov rdi, rbx call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&) lea rax, [rsp+58h+var_40] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_4F19C mov rsi, [rsp+58h+var_40] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_4F19C: add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov r14, rax lea rax, [rsp+arg_10] mov rdi, [rax-10h] jmp short loc_4F1CD jmp short $+2 loc_4F1BB: mov r14, rax jmp short loc_4F1DF mov r14, rax mov rdi, [rsp+arg_0]; void * lea rax, [rsp+arg_10] loc_4F1CD: cmp rdi, rax jz short loc_4F1DF mov rsi, [rsp+arg_10] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_4F1DF: mov rdi, rbx call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() mov rdi, r14 call __Unwind_Resume
void string_split<std::string>(long long a1, long long a2, unsigned int a3) { char v3; // bp long long v4; // r15 long long v5; // rax long long v6; // r12 void *v7[2]; // [rsp+8h] [rbp-50h] BYREF _QWORD v8[8]; // [rsp+18h] [rbp-40h] BYREF v3 = a3; *(_OWORD *)a1 = 0LL; *(_QWORD *)(a1 + 16) = 0LL; v4 = 0LL; v5 = std::string::find(a2, a3, 0LL); if ( v5 != -1 ) { v6 = v5; v4 = 0LL; do { std::string::substr(v7, a2, v4, v6 - v4); std::vector<std::string>::emplace_back<std::string&>(a1, v7); v4 = v6 + 1; v6 = std::string::find(a2, (unsigned int)v3, v6 + 1); if ( v7[0] != v8 ) operator delete(v7[0], v8[0] + 1LL); } while ( v6 != -1 ); } std::string::substr(v7, a2, v4, ~v4); std::vector<std::string>::emplace_back<std::string>(a1, v7); if ( v7[0] != v8 ) operator delete(v7[0], v8[0] + 1LL); }
string_split<std::__cxx11::string>: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV EBP,EDX MOV R14,RSI MOV RBX,RDI XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI],XMM0 MOV qword ptr [RDI + 0x10],0x0 XOR R15D,R15D MOV RDI,RSI MOV ESI,EDX XOR EDX,EDX CALL 0x0011bb10 CMP RAX,-0x1 JZ 0x0014f15e MOV R12,RAX XOR R15D,R15D LEA R13,[RSP + 0x8] MOVSX EBP,BPL LAB_0014f107: MOV RCX,R12 SUB RCX,R15 LAB_0014f10d: MOV RDI,R13 MOV RSI,R14 MOV RDX,R15 CALL 0x0011b910 LAB_0014f11b: MOV RDI,RBX MOV RSI,R13 CALL 0x001561f8 MOV R15,R12 INC R15 MOV RDI,R14 MOV ESI,EBP MOV RDX,R15 CALL 0x0011bb10 MOV R12,RAX MOV RDI,qword ptr [RSP + 0x8] LEA RAX,[RSP + 0x18] CMP RDI,RAX JZ 0x0014f158 MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x0011b8c0 LAB_0014f158: CMP R12,-0x1 JNZ 0x0014f107 LAB_0014f15e: MOV RCX,R15 NOT RCX LAB_0014f164: LEA RDI,[RSP + 0x8] MOV RSI,R14 MOV RDX,R15 CALL 0x0011b910 LAB_0014f174: LEA RSI,[RSP + 0x8] MOV RDI,RBX CALL 0x00156246 LAB_0014f181: LEA RAX,[RSP + 0x18] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x0014f19c MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x0011b8c0 LAB_0014f19c: ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* std::vector<std::__cxx11::string, std::allocator<std::__cxx11::string > > string_split<std::__cxx11::string >(std::__cxx11::string const&, char) */ void string_split<std::__cxx11::string>(string *param_1,char param_2) { long lVar1; uint in_EDX; int7 in_register_00000031; long *local_50 [2]; long local_40 [2]; *(int8 *)param_1 = 0; *(int8 *)(param_1 + 8) = 0; *(int8 *)(param_1 + 0x10) = 0; lVar1 = std::__cxx11::string::find(param_2,(ulong)in_EDX); if (lVar1 != -1) { do { /* try { // try from 0014f10d to 0014f11a has its CatchHandler @ 0014f1bb */ std::__cxx11::string::substr((ulong)local_50,CONCAT71(in_register_00000031,param_2)); /* try { // try from 0014f11b to 0014f125 has its CatchHandler @ 0014f1c0 */ std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>:: emplace_back<std::__cxx11::string&> ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1, (string *)local_50); lVar1 = std::__cxx11::string::find(param_2,(ulong)(uint)(int)(char)in_EDX); if (local_50[0] != local_40) { operator_delete(local_50[0],local_40[0] + 1); } } while (lVar1 != -1); } /* try { // try from 0014f164 to 0014f173 has its CatchHandler @ 0014f1b9 */ std::__cxx11::string::substr((ulong)local_50,CONCAT71(in_register_00000031,param_2)); /* try { // try from 0014f174 to 0014f180 has its CatchHandler @ 0014f1ab */ std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>:: emplace_back<std::__cxx11::string> ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1, (string *)local_50); if (local_50[0] != local_40) { operator_delete(local_50[0],local_40[0] + 1); } return; }
56,848
add_closure_var
bluesky950520[P]quickjs/quickjs.c
static int add_closure_var(JSContext *ctx, JSFunctionDef *s, BOOL is_local, BOOL is_arg, int var_idx, JSAtom var_name, BOOL is_const, BOOL is_lexical, JSVarKindEnum var_kind) { JSClosureVar *cv; /* the closure variable indexes are currently stored on 16 bits */ if (s->closure_var_count >= JS_MAX_LOCAL_VARS) { // XXX: add_closure_var() should take JSParseState *s and use js_parse_error JS_ThrowSyntaxError(ctx, "too many closure variables used (only %d allowed)", JS_MAX_LOCAL_VARS - 1); return -1; } if (js_resize_array(ctx, (void **)&s->closure_var, sizeof(s->closure_var[0]), &s->closure_var_size, s->closure_var_count + 1)) return -1; cv = &s->closure_var[s->closure_var_count++]; cv->is_local = is_local; cv->is_arg = is_arg; cv->is_const = is_const; cv->is_lexical = is_lexical; cv->var_kind = var_kind; cv->var_idx = var_idx; cv->var_name = JS_DupAtom(ctx, var_name); return s->closure_var_count - 1; }
O0
c
add_closure_var: subq $0x48, %rsp movl 0x60(%rsp), %eax movl 0x58(%rsp), %eax movl 0x50(%rsp), %eax movq %rdi, 0x38(%rsp) movq %rsi, 0x30(%rsp) movl %edx, 0x2c(%rsp) movl %ecx, 0x28(%rsp) movl %r8d, 0x24(%rsp) movl %r9d, 0x20(%rsp) movq 0x30(%rsp), %rax cmpl $0xffff, 0x198(%rax) # imm = 0xFFFF jl 0xb096c movq 0x38(%rsp), %rdi leaq 0x5e343(%rip), %rsi # 0x10ec8c movl $0xfffe, %edx # imm = 0xFFFE movb $0x0, %al callq 0x2bf50 movq %rax, 0x8(%rsp) movq %rdx, 0x10(%rsp) movl $0xffffffff, 0x44(%rsp) # imm = 0xFFFFFFFF jmp 0xb0a9e movq 0x38(%rsp), %rdi movq 0x30(%rsp), %rsi addq $0x1a0, %rsi # imm = 0x1A0 movq 0x30(%rsp), %rcx addq $0x19c, %rcx # imm = 0x19C movq 0x30(%rsp), %rax movl 0x198(%rax), %r8d addl $0x1, %r8d movl $0x8, %edx callq 0x71e80 cmpl $0x0, %eax je 0xb09b5 movl $0xffffffff, 0x44(%rsp) # imm = 0xFFFFFFFF jmp 0xb0a9e movq 0x30(%rsp), %rax movq 0x1a0(%rax), %rax movq 0x30(%rsp), %rdx movl 0x198(%rdx), %ecx movl %ecx, %esi addl $0x1, %esi movl %esi, 0x198(%rdx) movslq %ecx, %rcx shlq $0x3, %rcx addq %rcx, %rax movq %rax, 0x18(%rsp) movl 0x2c(%rsp), %eax movb %al, %dl movq 0x18(%rsp), %rax movb (%rax), %cl andb $0x1, %dl andb $-0x2, %cl orb %dl, %cl movb %cl, (%rax) movl 0x28(%rsp), %eax movb %al, %dl movq 0x18(%rsp), %rax movb (%rax), %cl andb $0x1, %dl shlb %dl andb $-0x3, %cl orb %dl, %cl movb %cl, (%rax) movl 0x50(%rsp), %eax movb %al, %dl movq 0x18(%rsp), %rax movb (%rax), %cl andb $0x1, %dl shlb $0x2, %dl andb $-0x5, %cl orb %dl, %cl movb %cl, (%rax) movl 0x58(%rsp), %eax movb %al, %dl movq 0x18(%rsp), %rax movb (%rax), %cl andb $0x1, %dl shlb $0x3, %dl andb $-0x9, %cl orb %dl, %cl movb %cl, (%rax) movl 0x60(%rsp), %eax movb %al, %dl movq 0x18(%rsp), %rax movb (%rax), %cl andb $0xf, %dl shlb $0x4, %dl andb $0xf, %cl orb %dl, %cl movb %cl, (%rax) movl 0x24(%rsp), %eax movw %ax, %cx movq 0x18(%rsp), %rax movw %cx, 0x2(%rax) movq 0x38(%rsp), %rdi movl 0x20(%rsp), %esi callq 0x26ce0 movl %eax, %ecx movq 0x18(%rsp), %rax movl %ecx, 0x4(%rax) movq 0x30(%rsp), %rax movl 0x198(%rax), %eax subl $0x1, %eax movl %eax, 0x44(%rsp) movl 0x44(%rsp), %eax addq $0x48, %rsp retq nopw (%rax,%rax)
add_closure_var: sub rsp, 48h mov eax, [rsp+48h+arg_10] mov eax, [rsp+48h+arg_8] mov eax, [rsp+48h+arg_0] mov [rsp+48h+var_10], rdi mov [rsp+48h+var_18], rsi mov [rsp+48h+var_1C], edx mov [rsp+48h+var_20], ecx mov [rsp+48h+var_24], r8d mov [rsp+48h+var_28], r9d mov rax, [rsp+48h+var_18] cmp dword ptr [rax+198h], 0FFFFh jl short loc_B096C mov rdi, [rsp+48h+var_10] lea rsi, aTooManyClosure; "too many closure variables used (only %"... mov edx, 0FFFEh mov al, 0 call JS_ThrowSyntaxError mov [rsp+48h+var_40], rax mov [rsp+48h+var_38], rdx mov [rsp+48h+var_4], 0FFFFFFFFh jmp loc_B0A9E loc_B096C: mov rdi, [rsp+48h+var_10] mov rsi, [rsp+48h+var_18] add rsi, 1A0h mov rcx, [rsp+48h+var_18] add rcx, 19Ch mov rax, [rsp+48h+var_18] mov r8d, [rax+198h] add r8d, 1 mov edx, 8 call js_resize_array cmp eax, 0 jz short loc_B09B5 mov [rsp+48h+var_4], 0FFFFFFFFh jmp loc_B0A9E loc_B09B5: mov rax, [rsp+48h+var_18] mov rax, [rax+1A0h] mov rdx, [rsp+48h+var_18] mov ecx, [rdx+198h] mov esi, ecx add esi, 1 mov [rdx+198h], esi movsxd rcx, ecx shl rcx, 3 add rax, rcx mov [rsp+48h+var_30], rax mov eax, [rsp+48h+var_1C] mov dl, al mov rax, [rsp+48h+var_30] mov cl, [rax] and dl, 1 and cl, 0FEh or cl, dl mov [rax], cl mov eax, [rsp+48h+var_20] mov dl, al mov rax, [rsp+48h+var_30] mov cl, [rax] and dl, 1 shl dl, 1 and cl, 0FDh or cl, dl mov [rax], cl mov eax, [rsp+48h+arg_0] mov dl, al mov rax, [rsp+48h+var_30] mov cl, [rax] and dl, 1 shl dl, 2 and cl, 0FBh or cl, dl mov [rax], cl mov eax, [rsp+48h+arg_8] mov dl, al mov rax, [rsp+48h+var_30] mov cl, [rax] and dl, 1 shl dl, 3 and cl, 0F7h or cl, dl mov [rax], cl mov eax, [rsp+48h+arg_10] mov dl, al mov rax, [rsp+48h+var_30] mov cl, [rax] and dl, 0Fh shl dl, 4 and cl, 0Fh or cl, dl mov [rax], cl mov eax, [rsp+48h+var_24] mov cx, ax mov rax, [rsp+48h+var_30] mov [rax+2], cx mov rdi, [rsp+48h+var_10] mov esi, [rsp+48h+var_28] call JS_DupAtom mov ecx, eax mov rax, [rsp+48h+var_30] mov [rax+4], ecx mov rax, [rsp+48h+var_18] mov eax, [rax+198h] sub eax, 1 mov [rsp+48h+var_4], eax loc_B0A9E: mov eax, [rsp+48h+var_4] add rsp, 48h retn
long long add_closure_var( long long a1, long long a2, char a3, long long a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14, char a15, char a16, char a17) { long long v17; // rax int v18; // ecx char v20; // [rsp+0h] [rbp-48h] long long v21; // [rsp+18h] [rbp-30h] unsigned int v22; // [rsp+20h] [rbp-28h] __int16 v23; // [rsp+24h] [rbp-24h] char v24; // [rsp+28h] [rbp-20h] v24 = a4; v23 = a5; v22 = a6; if ( *(int *)(a2 + 408) < 0xFFFF ) { if ( (unsigned int)js_resize_array(a1, a2 + 416, 8u, (_DWORD *)(a2 + 412), *(_DWORD *)(a2 + 408) + 1) ) { return (unsigned int)-1; } else { v17 = *(_QWORD *)(a2 + 416); v18 = *(_DWORD *)(a2 + 408); *(_DWORD *)(a2 + 408) = v18 + 1; v21 = 8LL * v18 + v17; *(_BYTE *)v21 = a3 & 1 | *(_BYTE *)v21 & 0xFE; *(_BYTE *)v21 = (2 * (v24 & 1)) | *(_BYTE *)v21 & 0xFD; *(_BYTE *)v21 = (4 * (a15 & 1)) | *(_BYTE *)v21 & 0xFB; *(_BYTE *)v21 = (8 * (a16 & 1)) | *(_BYTE *)v21 & 0xF7; *(_BYTE *)v21 = (16 * (a17 & 0xF)) | *(_BYTE *)v21 & 0xF; *(_WORD *)(v21 + 2) = v23; *(_DWORD *)(v21 + 4) = JS_DupAtom(a1, v22); return (unsigned int)(*(_DWORD *)(a2 + 408) - 1); } } else { JS_ThrowSyntaxError( a1, (long long)"too many closure variables used (only %d allowed)", 65534LL, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v20); return (unsigned int)-1; } }
add_closure_var: SUB RSP,0x48 MOV EAX,dword ptr [RSP + 0x60] MOV EAX,dword ptr [RSP + 0x58] MOV EAX,dword ptr [RSP + 0x50] MOV qword ptr [RSP + 0x38],RDI MOV qword ptr [RSP + 0x30],RSI MOV dword ptr [RSP + 0x2c],EDX MOV dword ptr [RSP + 0x28],ECX MOV dword ptr [RSP + 0x24],R8D MOV dword ptr [RSP + 0x20],R9D MOV RAX,qword ptr [RSP + 0x30] CMP dword ptr [RAX + 0x198],0xffff JL 0x001b096c MOV RDI,qword ptr [RSP + 0x38] LEA RSI,[0x20ec8c] MOV EDX,0xfffe MOV AL,0x0 CALL 0x0012bf50 MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x10],RDX MOV dword ptr [RSP + 0x44],0xffffffff JMP 0x001b0a9e LAB_001b096c: MOV RDI,qword ptr [RSP + 0x38] MOV RSI,qword ptr [RSP + 0x30] ADD RSI,0x1a0 MOV RCX,qword ptr [RSP + 0x30] ADD RCX,0x19c MOV RAX,qword ptr [RSP + 0x30] MOV R8D,dword ptr [RAX + 0x198] ADD R8D,0x1 MOV EDX,0x8 CALL 0x00171e80 CMP EAX,0x0 JZ 0x001b09b5 MOV dword ptr [RSP + 0x44],0xffffffff JMP 0x001b0a9e LAB_001b09b5: MOV RAX,qword ptr [RSP + 0x30] MOV RAX,qword ptr [RAX + 0x1a0] MOV RDX,qword ptr [RSP + 0x30] MOV ECX,dword ptr [RDX + 0x198] MOV ESI,ECX ADD ESI,0x1 MOV dword ptr [RDX + 0x198],ESI MOVSXD RCX,ECX SHL RCX,0x3 ADD RAX,RCX MOV qword ptr [RSP + 0x18],RAX MOV EAX,dword ptr [RSP + 0x2c] MOV DL,AL MOV RAX,qword ptr [RSP + 0x18] MOV CL,byte ptr [RAX] AND DL,0x1 AND CL,0xfe OR CL,DL MOV byte ptr [RAX],CL MOV EAX,dword ptr [RSP + 0x28] MOV DL,AL MOV RAX,qword ptr [RSP + 0x18] MOV CL,byte ptr [RAX] AND DL,0x1 SHL DL,0x1 AND CL,0xfd OR CL,DL MOV byte ptr [RAX],CL MOV EAX,dword ptr [RSP + 0x50] MOV DL,AL MOV RAX,qword ptr [RSP + 0x18] MOV CL,byte ptr [RAX] AND DL,0x1 SHL DL,0x2 AND CL,0xfb OR CL,DL MOV byte ptr [RAX],CL MOV EAX,dword ptr [RSP + 0x58] MOV DL,AL MOV RAX,qword ptr [RSP + 0x18] MOV CL,byte ptr [RAX] AND DL,0x1 SHL DL,0x3 AND CL,0xf7 OR CL,DL MOV byte ptr [RAX],CL MOV EAX,dword ptr [RSP + 0x60] MOV DL,AL MOV RAX,qword ptr [RSP + 0x18] MOV CL,byte ptr [RAX] AND DL,0xf SHL DL,0x4 AND CL,0xf OR CL,DL MOV byte ptr [RAX],CL MOV EAX,dword ptr [RSP + 0x24] MOV CX,AX MOV RAX,qword ptr [RSP + 0x18] MOV word ptr [RAX + 0x2],CX MOV RDI,qword ptr [RSP + 0x38] MOV ESI,dword ptr [RSP + 0x20] CALL 0x00126ce0 MOV ECX,EAX MOV RAX,qword ptr [RSP + 0x18] MOV dword ptr [RAX + 0x4],ECX MOV RAX,qword ptr [RSP + 0x30] MOV EAX,dword ptr [RAX + 0x198] SUB EAX,0x1 MOV dword ptr [RSP + 0x44],EAX LAB_001b0a9e: MOV EAX,dword ptr [RSP + 0x44] ADD RSP,0x48 RET
int add_closure_var(int8 param_1,long param_2,byte param_3,byte param_4,int2 param_5, int4 param_6,byte param_7,byte param_8,char param_9) { int iVar1; int4 uVar2; byte *pbVar3; int local_4; if (*(int *)(param_2 + 0x198) < 0xffff) { iVar1 = js_resize_array(param_1,param_2 + 0x1a0,8,param_2 + 0x19c,*(int *)(param_2 + 0x198) + 1) ; if (iVar1 == 0) { iVar1 = *(int *)(param_2 + 0x198); *(int *)(param_2 + 0x198) = iVar1 + 1; pbVar3 = (byte *)(*(long *)(param_2 + 0x1a0) + (long)iVar1 * 8); *pbVar3 = *pbVar3 & 0xfe | param_3 & 1; *pbVar3 = *pbVar3 & 0xfd | (param_4 & 1) << 1; *pbVar3 = *pbVar3 & 0xfb | (param_7 & 1) << 2; *pbVar3 = *pbVar3 & 0xf7 | (param_8 & 1) << 3; *pbVar3 = *pbVar3 & 0xf | param_9 << 4; *(int2 *)(pbVar3 + 2) = param_5; uVar2 = JS_DupAtom(param_1,param_6); *(int4 *)(pbVar3 + 4) = uVar2; local_4 = *(int *)(param_2 + 0x198) + -1; } else { local_4 = -1; } } else { JS_ThrowSyntaxError(param_1,"too many closure variables used (only %d allowed)",0xfffe); local_4 = -1; } return local_4; }
56,849
add_closure_var
bluesky950520[P]quickjs/quickjs.c
static int add_closure_var(JSContext *ctx, JSFunctionDef *s, BOOL is_local, BOOL is_arg, int var_idx, JSAtom var_name, BOOL is_const, BOOL is_lexical, JSVarKindEnum var_kind) { JSClosureVar *cv; /* the closure variable indexes are currently stored on 16 bits */ if (s->closure_var_count >= JS_MAX_LOCAL_VARS) { // XXX: add_closure_var() should take JSParseState *s and use js_parse_error JS_ThrowSyntaxError(ctx, "too many closure variables used (only %d allowed)", JS_MAX_LOCAL_VARS - 1); return -1; } if (js_resize_array(ctx, (void **)&s->closure_var, sizeof(s->closure_var[0]), &s->closure_var_size, s->closure_var_count + 1)) return -1; cv = &s->closure_var[s->closure_var_count++]; cv->is_local = is_local; cv->is_arg = is_arg; cv->is_const = is_const; cv->is_lexical = is_lexical; cv->var_kind = var_kind; cv->var_idx = var_idx; cv->var_name = JS_DupAtom(ctx, var_name); return s->closure_var_count - 1; }
O1
c
add_closure_var: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movl %r8d, %ebp movq %rdi, %r15 movl 0x198(%rsi), %r8d cmpl $0xffff, %r8d # imm = 0xFFFF jl 0x6c2ad leaq 0x339fc(%rip), %rsi # 0x9fc90 movq %r15, %rdi movl $0xfffe, %edx # imm = 0xFFFE xorl %eax, %eax callq 0x218bd movl $0xffffffff, %eax # imm = 0xFFFFFFFF jmp 0x6c341 movl %r9d, %ebx movl %ecx, %r12d movl %edx, %r13d movq %rsi, %r14 cmpl %r8d, 0x19c(%rsi) jle 0x6c350 movl 0x50(%rsp), %esi movl 0x48(%rsp), %edx movl 0x40(%rsp), %edi movq 0x1a0(%r14), %rax movslq 0x198(%r14), %rcx leal 0x1(%rcx), %r8d movl %r8d, 0x198(%r14) andb $0x1, %r13b addb %r12b, %r12b andb $0x2, %r12b orb %r13b, %r12b shlb $0x2, %dil andb $0x4, %dil orb %r12b, %dil shlb $0x3, %dl shlb $0x4, %sil andb $0x8, %dl orb %dil, %dl orb %sil, %dl movb %dl, (%rax,%rcx,8) movw %bp, 0x2(%rax,%rcx,8) cmpl $0xe0, %ebx jl 0x6c334 movq 0x18(%r15), %rdx movq 0x68(%rdx), %rdx movl %ebx, %esi movq (%rdx,%rsi,8), %rdx incl (%rdx) movl %ebx, 0x4(%rax,%rcx,8) movl 0x198(%r14), %eax decl %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x1a0(%r14), %rsi leaq 0x19c(%r14), %rcx incl %r8d movq %r15, %rdi movl $0x8, %edx callq 0x428db movl %eax, %ecx movl $0xffffffff, %eax # imm = 0xFFFFFFFF testl %ecx, %ecx jne 0x6c341 jmp 0x6c2c6
add_closure_var: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov ebp, r8d mov r15, rdi mov r8d, [rsi+198h] cmp r8d, 0FFFFh jl short loc_6C2AD lea rsi, aTooManyClosure; "too many closure variables used (only %"... mov rdi, r15 mov edx, 0FFFEh xor eax, eax call JS_ThrowSyntaxError mov eax, 0FFFFFFFFh jmp loc_6C341 loc_6C2AD: mov ebx, r9d mov r12d, ecx mov r13d, edx mov r14, rsi cmp [rsi+19Ch], r8d jle loc_6C350 loc_6C2C6: mov esi, [rsp+38h+arg_10] mov edx, [rsp+38h+arg_8] mov edi, [rsp+38h+arg_0] mov rax, [r14+1A0h] movsxd rcx, dword ptr [r14+198h] lea r8d, [rcx+1] mov [r14+198h], r8d and r13b, 1 add r12b, r12b and r12b, 2 or r12b, r13b shl dil, 2 and dil, 4 or dil, r12b shl dl, 3 shl sil, 4 and dl, 8 or dl, dil or dl, sil mov [rax+rcx*8], dl mov [rax+rcx*8+2], bp cmp ebx, 0E0h jl short loc_6C334 mov rdx, [r15+18h] mov rdx, [rdx+68h] mov esi, ebx mov rdx, [rdx+rsi*8] inc dword ptr [rdx] loc_6C334: mov [rax+rcx*8+4], ebx mov eax, [r14+198h] dec eax loc_6C341: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_6C350: lea rsi, [r14+1A0h] lea rcx, [r14+19Ch] inc r8d mov rdi, r15 mov edx, 8 call js_realloc_array mov ecx, eax mov eax, 0FFFFFFFFh test ecx, ecx jnz short loc_6C341 jmp loc_6C2C6
long long add_closure_var( long long a1, long long a2, char a3, long long a4, __int16 a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14, char a15, char a16, char a17) { char v17; // al long long v19; // r8 long long result; // rax int v21; // ebx char v22; // r12 long long v24; // rax long long v25; // rcx _DWORD *v26; // rdx int v27; // ecx v19 = *(unsigned int *)(a2 + 408); if ( (int)v19 < 0xFFFF ) { v21 = a6; v22 = a4; if ( *(_DWORD *)(a2 + 412) > (int)v19 || (v27 = js_realloc_array(a1, (long long *)(a2 + 416), 8u, (_DWORD *)(a2 + 412), (int)v19 + 1), result = 0xFFFFFFFFLL, !v27) ) { v24 = *(_QWORD *)(a2 + 416); v25 = *(int *)(a2 + 408); *(_DWORD *)(a2 + 408) = v25 + 1; *(_BYTE *)(v24 + 8 * v25) = (16 * a17) | a3 & 1 | (2 * v22) & 2 | (4 * a15) & 4 | (8 * a16) & 8; *(_WORD *)(v24 + 8 * v25 + 2) = a5; if ( v21 >= 224 ) { v26 = *(_DWORD **)(*(_QWORD *)(*(_QWORD *)(a1 + 24) + 104LL) + 8LL * (unsigned int)v21); ++*v26; } *(_DWORD *)(v24 + 8 * v25 + 4) = v21; return (unsigned int)(*(_DWORD *)(a2 + 408) - 1); } } else { JS_ThrowSyntaxError( a1, (long long)"too many closure variables used (only %d allowed)", 65534LL, a4, v19, a6, a7, a8, a9, a10, a11, a12, a13, a14, v17); return 0xFFFFFFFFLL; } return result; }
add_closure_var: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV EBP,R8D MOV R15,RDI MOV R8D,dword ptr [RSI + 0x198] CMP R8D,0xffff JL 0x0016c2ad LEA RSI,[0x19fc90] MOV RDI,R15 MOV EDX,0xfffe XOR EAX,EAX CALL 0x001218bd MOV EAX,0xffffffff JMP 0x0016c341 LAB_0016c2ad: MOV EBX,R9D MOV R12D,ECX MOV R13D,EDX MOV R14,RSI CMP dword ptr [RSI + 0x19c],R8D JLE 0x0016c350 LAB_0016c2c6: MOV ESI,dword ptr [RSP + 0x50] MOV EDX,dword ptr [RSP + 0x48] MOV EDI,dword ptr [RSP + 0x40] MOV RAX,qword ptr [R14 + 0x1a0] MOVSXD RCX,dword ptr [R14 + 0x198] LEA R8D,[RCX + 0x1] MOV dword ptr [R14 + 0x198],R8D AND R13B,0x1 ADD R12B,R12B AND R12B,0x2 OR R12B,R13B SHL DIL,0x2 AND DIL,0x4 OR DIL,R12B SHL DL,0x3 SHL SIL,0x4 AND DL,0x8 OR DL,DIL OR DL,SIL MOV byte ptr [RAX + RCX*0x8],DL MOV word ptr [RAX + RCX*0x8 + 0x2],BP CMP EBX,0xe0 JL 0x0016c334 MOV RDX,qword ptr [R15 + 0x18] MOV RDX,qword ptr [RDX + 0x68] MOV ESI,EBX MOV RDX,qword ptr [RDX + RSI*0x8] INC dword ptr [RDX] LAB_0016c334: MOV dword ptr [RAX + RCX*0x8 + 0x4],EBX MOV EAX,dword ptr [R14 + 0x198] DEC EAX LAB_0016c341: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0016c350: LEA RSI,[R14 + 0x1a0] LEA RCX,[R14 + 0x19c] INC R8D MOV RDI,R15 MOV EDX,0x8 CALL 0x001428db MOV ECX,EAX MOV EAX,0xffffffff TEST ECX,ECX JNZ 0x0016c341 JMP 0x0016c2c6
int add_closure_var(long param_1,long param_2,byte param_3,char param_4,int2 param_5, uint param_6,byte param_7,byte param_8,char param_9) { long lVar1; int *piVar2; int iVar3; long lVar4; iVar3 = *(int *)(param_2 + 0x198); if (iVar3 < 0xffff) { if ((*(int *)(param_2 + 0x19c) <= iVar3) && (iVar3 = js_realloc_array(param_1,param_2 + 0x1a0,8,param_2 + 0x19c,iVar3 + 1), iVar3 != 0)) { return -1; } lVar1 = *(long *)(param_2 + 0x1a0); lVar4 = (long)*(int *)(param_2 + 0x198); *(int *)(param_2 + 0x198) = *(int *)(param_2 + 0x198) + 1; *(byte *)(lVar1 + lVar4 * 8) = (param_8 & 1) << 3 | (param_7 & 1) << 2 | param_4 * '\x02' & 2U | param_3 & 1 | param_9 << 4; *(int2 *)(lVar1 + 2 + lVar4 * 8) = param_5; if (0xdf < (int)param_6) { piVar2 = *(int **)(*(long *)(*(long *)(param_1 + 0x18) + 0x68) + (ulong)param_6 * 8); *piVar2 = *piVar2 + 1; } *(uint *)(lVar1 + 4 + lVar4 * 8) = param_6; iVar3 = *(int *)(param_2 + 0x198) + -1; } else { JS_ThrowSyntaxError(param_1,"too many closure variables used (only %d allowed)",0xfffe); iVar3 = -1; } return iVar3; }
56,850
add_closure_var
bluesky950520[P]quickjs/quickjs.c
static int add_closure_var(JSContext *ctx, JSFunctionDef *s, BOOL is_local, BOOL is_arg, int var_idx, JSAtom var_name, BOOL is_const, BOOL is_lexical, JSVarKindEnum var_kind) { JSClosureVar *cv; /* the closure variable indexes are currently stored on 16 bits */ if (s->closure_var_count >= JS_MAX_LOCAL_VARS) { // XXX: add_closure_var() should take JSParseState *s and use js_parse_error JS_ThrowSyntaxError(ctx, "too many closure variables used (only %d allowed)", JS_MAX_LOCAL_VARS - 1); return -1; } if (js_resize_array(ctx, (void **)&s->closure_var, sizeof(s->closure_var[0]), &s->closure_var_size, s->closure_var_count + 1)) return -1; cv = &s->closure_var[s->closure_var_count++]; cv->is_local = is_local; cv->is_arg = is_arg; cv->is_const = is_const; cv->is_lexical = is_lexical; cv->var_kind = var_kind; cv->var_idx = var_idx; cv->var_name = JS_DupAtom(ctx, var_name); return s->closure_var_count - 1; }
O3
c
add_closure_var: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movl %r8d, %ebp movq %rdi, %r15 movl 0x198(%rsi), %r8d cmpl $0xffff, %r8d # imm = 0xFFFF jl 0x6e48d leaq 0x347d6(%rip), %rsi # 0xa2c4a movq %r15, %rdi movl $0xfffe, %edx # imm = 0xFFFE xorl %eax, %eax callq 0x220b9 movl $0xffffffff, %eax # imm = 0xFFFFFFFF jmp 0x6e51d movl %r9d, %ebx movl %ecx, %r12d movl %edx, %r13d movq %rsi, %r14 cmpl %r8d, 0x19c(%rsi) jle 0x6e52c movl 0x50(%rsp), %esi movl 0x48(%rsp), %edx movl 0x40(%rsp), %edi movq 0x1a0(%r14), %rax leal 0x1(%r8), %ecx movl %ecx, 0x198(%r14) movslq %r8d, %rcx andb $0x1, %r13b addb %r12b, %r12b andb $0x2, %r12b orb %r13b, %r12b shlb $0x2, %dil andb $0x4, %dil orb %r12b, %dil shlb $0x3, %dl shlb $0x4, %sil andb $0x8, %dl orb %dil, %dl orb %sil, %dl movb %dl, (%rax,%rcx,8) movw %bp, 0x2(%rax,%rcx,8) cmpl $0xe0, %ebx jl 0x6e510 movq 0x18(%r15), %rdx movq 0x68(%rdx), %rdx movl %ebx, %esi movq (%rdx,%rsi,8), %rdx incl (%rdx) movl %ebx, 0x4(%rax,%rcx,8) movl 0x198(%r14), %eax decl %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x1a0(%r14), %rsi leaq 0x19c(%r14), %rcx incl %r8d movq %r15, %rdi movl $0x8, %edx callq 0x444ee movl %eax, %ecx movl $0xffffffff, %eax # imm = 0xFFFFFFFF testl %ecx, %ecx jne 0x6e51d movl 0x198(%r14), %r8d jmp 0x6e4a6
add_closure_var: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov ebp, r8d mov r15, rdi mov r8d, [rsi+198h] cmp r8d, 0FFFFh jl short loc_6E48D lea rsi, aTooManyClosure; "too many closure variables used (only %"... mov rdi, r15 mov edx, 0FFFEh xor eax, eax call JS_ThrowSyntaxError mov eax, 0FFFFFFFFh jmp loc_6E51D loc_6E48D: mov ebx, r9d mov r12d, ecx mov r13d, edx mov r14, rsi cmp [rsi+19Ch], r8d jle loc_6E52C loc_6E4A6: mov esi, [rsp+38h+arg_10] mov edx, [rsp+38h+arg_8] mov edi, [rsp+38h+arg_0] mov rax, [r14+1A0h] lea ecx, [r8+1] mov [r14+198h], ecx movsxd rcx, r8d and r13b, 1 add r12b, r12b and r12b, 2 or r12b, r13b shl dil, 2 and dil, 4 or dil, r12b shl dl, 3 shl sil, 4 and dl, 8 or dl, dil or dl, sil mov [rax+rcx*8], dl mov [rax+rcx*8+2], bp cmp ebx, 0E0h jl short loc_6E510 mov rdx, [r15+18h] mov rdx, [rdx+68h] mov esi, ebx mov rdx, [rdx+rsi*8] inc dword ptr [rdx] loc_6E510: mov [rax+rcx*8+4], ebx mov eax, [r14+198h] dec eax loc_6E51D: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_6E52C: lea rsi, [r14+1A0h] lea rcx, [r14+19Ch] inc r8d mov rdi, r15 mov edx, 8 call js_realloc_array mov ecx, eax mov eax, 0FFFFFFFFh test ecx, ecx jnz short loc_6E51D mov r8d, [r14+198h] jmp loc_6E4A6
long long add_closure_var( long long a1, long long a2, char a3, long long a4, __int16 a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14, char a15, char a16, char a17) { char v17; // al long long v19; // r8 long long result; // rax int v21; // ebx char v22; // r12 long long v24; // rax _DWORD *v25; // rdx int v26; // ecx v19 = *(unsigned int *)(a2 + 408); if ( (int)v19 >= 0xFFFF ) { JS_ThrowSyntaxError( a1, (long long)"too many closure variables used (only %d allowed)", 65534LL, a4, v19, a6, a7, a8, a9, a10, a11, a12, a13, a14, v17); return 0xFFFFFFFFLL; } v21 = a6; v22 = a4; if ( *(_DWORD *)(a2 + 412) <= (int)v19 ) { v26 = js_realloc_array(a1, (long long *)(a2 + 416), 8u, (_DWORD *)(a2 + 412), (int)v19 + 1); result = 0xFFFFFFFFLL; if ( v26 ) return result; LODWORD(v19) = *(_DWORD *)(a2 + 408); } v24 = *(_QWORD *)(a2 + 416); *(_DWORD *)(a2 + 408) = v19 + 1; *(_BYTE *)(v24 + 8LL * (int)v19) = (16 * a17) | a3 & 1 | (2 * v22) & 2 | (4 * a15) & 4 | (8 * a16) & 8; *(_WORD *)(v24 + 8LL * (int)v19 + 2) = a5; if ( v21 >= 224 ) { v25 = *(_DWORD **)(*(_QWORD *)(*(_QWORD *)(a1 + 24) + 104LL) + 8LL * (unsigned int)v21); ++*v25; } *(_DWORD *)(v24 + 8LL * (int)v19 + 4) = v21; return (unsigned int)(*(_DWORD *)(a2 + 408) - 1); }
add_closure_var: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV EBP,R8D MOV R15,RDI MOV R8D,dword ptr [RSI + 0x198] CMP R8D,0xffff JL 0x0016e48d LEA RSI,[0x1a2c4a] MOV RDI,R15 MOV EDX,0xfffe XOR EAX,EAX CALL 0x001220b9 MOV EAX,0xffffffff JMP 0x0016e51d LAB_0016e48d: MOV EBX,R9D MOV R12D,ECX MOV R13D,EDX MOV R14,RSI CMP dword ptr [RSI + 0x19c],R8D JLE 0x0016e52c LAB_0016e4a6: MOV ESI,dword ptr [RSP + 0x50] MOV EDX,dword ptr [RSP + 0x48] MOV EDI,dword ptr [RSP + 0x40] MOV RAX,qword ptr [R14 + 0x1a0] LEA ECX,[R8 + 0x1] MOV dword ptr [R14 + 0x198],ECX MOVSXD RCX,R8D AND R13B,0x1 ADD R12B,R12B AND R12B,0x2 OR R12B,R13B SHL DIL,0x2 AND DIL,0x4 OR DIL,R12B SHL DL,0x3 SHL SIL,0x4 AND DL,0x8 OR DL,DIL OR DL,SIL MOV byte ptr [RAX + RCX*0x8],DL MOV word ptr [RAX + RCX*0x8 + 0x2],BP CMP EBX,0xe0 JL 0x0016e510 MOV RDX,qword ptr [R15 + 0x18] MOV RDX,qword ptr [RDX + 0x68] MOV ESI,EBX MOV RDX,qword ptr [RDX + RSI*0x8] INC dword ptr [RDX] LAB_0016e510: MOV dword ptr [RAX + RCX*0x8 + 0x4],EBX MOV EAX,dword ptr [R14 + 0x198] DEC EAX LAB_0016e51d: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0016e52c: LEA RSI,[R14 + 0x1a0] LEA RCX,[R14 + 0x19c] INC R8D MOV RDI,R15 MOV EDX,0x8 CALL 0x001444ee MOV ECX,EAX MOV EAX,0xffffffff TEST ECX,ECX JNZ 0x0016e51d MOV R8D,dword ptr [R14 + 0x198] JMP 0x0016e4a6
int add_closure_var(long param_1,long param_2,byte param_3,char param_4,int2 param_5, uint param_6,byte param_7,byte param_8,char param_9) { long lVar1; int *piVar2; int iVar3; long lVar4; iVar3 = *(int *)(param_2 + 0x198); if (iVar3 < 0xffff) { if (*(int *)(param_2 + 0x19c) <= iVar3) { iVar3 = js_realloc_array(param_1,param_2 + 0x1a0,8,param_2 + 0x19c,iVar3 + 1); if (iVar3 != 0) { return -1; } iVar3 = *(int *)(param_2 + 0x198); } lVar1 = *(long *)(param_2 + 0x1a0); *(int *)(param_2 + 0x198) = iVar3 + 1; lVar4 = (long)iVar3; *(byte *)(lVar1 + lVar4 * 8) = (param_8 & 1) << 3 | (param_7 & 1) << 2 | param_4 * '\x02' & 2U | param_3 & 1 | param_9 << 4; *(int2 *)(lVar1 + 2 + lVar4 * 8) = param_5; if (0xdf < (int)param_6) { piVar2 = *(int **)(*(long *)(*(long *)(param_1 + 0x18) + 0x68) + (ulong)param_6 * 8); *piVar2 = *piVar2 + 1; } *(uint *)(lVar1 + 4 + lVar4 * 8) = param_6; iVar3 = *(int *)(param_2 + 0x198) + -1; } else { JS_ThrowSyntaxError(param_1,"too many closure variables used (only %d allowed)",0xfffe); iVar3 = -1; } return iVar3; }
56,851
stbi_load
SDL3Lite/dependencies/stb_image.h
STBIDEF stbi_uc *stbi_load(char const *filename, int *x, int *y, int *comp, int req_comp) { FILE *f = stbi__fopen(filename, "rb"); unsigned char *result; if (!f) return stbi__errpuc("can't fopen", "Unable to open file"); result = stbi_load_from_file(f,x,y,comp,req_comp); fclose(f); return result; }
O0
c
stbi_load: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movl %r8d, -0x2c(%rbp) movq -0x10(%rbp), %rdi leaq 0xc1b1(%rip), %rsi # 0x33fb8 callq 0x27e70 movq %rax, -0x38(%rbp) cmpq $0x0, -0x38(%rbp) jne 0x27e34 leaq 0xc19d(%rip), %rdi # 0x33fbb callq 0x27ea0 movl %eax, %ecx xorl %eax, %eax cmpl $0x0, %ecx cmovneq %rax, %rax movq %rax, -0x8(%rbp) jmp 0x27e62 movq -0x38(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rdx movq -0x28(%rbp), %rcx movl -0x2c(%rbp), %r8d callq 0x27ec0 movq %rax, -0x40(%rbp) movq -0x38(%rbp), %rdi callq 0x1a270 movq -0x40(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x40, %rsp popq %rbp retq nopl (%rax)
stbi_load: 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 [rbp+var_2C], r8d mov rdi, [rbp+var_10]; char * lea rsi, aRb; "rb" call _ZL11stbi__fopenPKcS0_; stbi__fopen(char const*,char const*) mov [rbp+var_38], rax cmp [rbp+var_38], 0 jnz short loc_27E34 lea rdi, aCanTFopen; "can't fopen" call _ZL9stbi__errPKc; stbi__err(char const*) mov ecx, eax xor eax, eax cmp ecx, 0 cmovnz rax, rax mov [rbp+var_8], rax jmp short loc_27E62 loc_27E34: mov rdi, [rbp+var_38] mov rsi, [rbp+var_18] mov rdx, [rbp+var_20] mov rcx, [rbp+var_28] mov r8d, [rbp+var_2C] call stbi_load_from_file mov [rbp+var_40], rax mov rdi, [rbp+var_38] call _fclose mov rax, [rbp+var_40] mov [rbp+var_8], rax loc_27E62: mov rax, [rbp+var_8] add rsp, 40h pop rbp retn
long long stbi_load(const char *a1, long long a2, long long a3, long long a4, unsigned int a5) { long long v6; // [rsp+0h] [rbp-40h] long long v7; // [rsp+8h] [rbp-38h] v7 = stbi__fopen(a1, "rb"); if ( v7 ) { v6 = stbi_load_from_file(v7, a2, a3, a4, a5); fclose(v7); return v6; } else { stbi__err("can't fopen"); return 0LL; } }
stbi_load: 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 dword ptr [RBP + -0x2c],R8D MOV RDI,qword ptr [RBP + -0x10] LEA RSI,[0x133fb8] CALL 0x00127e70 MOV qword ptr [RBP + -0x38],RAX CMP qword ptr [RBP + -0x38],0x0 JNZ 0x00127e34 LEA RDI,[0x133fbb] CALL 0x00127ea0 MOV ECX,EAX XOR EAX,EAX CMP ECX,0x0 CMOVNZ RAX,RAX MOV qword ptr [RBP + -0x8],RAX JMP 0x00127e62 LAB_00127e34: MOV RDI,qword ptr [RBP + -0x38] MOV RSI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x28] MOV R8D,dword ptr [RBP + -0x2c] CALL 0x00127ec0 MOV qword ptr [RBP + -0x40],RAX MOV RDI,qword ptr [RBP + -0x38] CALL 0x0011a270 MOV RAX,qword ptr [RBP + -0x40] MOV qword ptr [RBP + -0x8],RAX LAB_00127e62: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x40 POP RBP RET
int8 stbi_load(char *param_1,int8 param_2,int8 param_3,int8 param_4,int4 param_5) { FILE *__stream; int8 local_10; __stream = (FILE *)stbi__fopen(param_1,"rb"); if (__stream == (FILE *)0x0) { stbi__err("can\'t fopen"); local_10 = 0; } else { local_10 = stbi_load_from_file(__stream,param_2,param_3,param_4,param_5); fclose(__stream); } return local_10; }
56,852
stbi_load
SDL3Lite/dependencies/stb_image.h
STBIDEF stbi_uc *stbi_load(char const *filename, int *x, int *y, int *comp, int req_comp) { FILE *f = stbi__fopen(filename, "rb"); unsigned char *result; if (!f) return stbi__errpuc("can't fopen", "Unable to open file"); result = stbi_load_from_file(f,x,y,comp,req_comp); fclose(f); return result; }
O3
c
stbi_load: subq $0x48, %rsp movq %rdi, 0x38(%rsp) movq %rsi, 0x30(%rsp) movq %rdx, 0x28(%rsp) movq %rcx, 0x20(%rsp) movl %r8d, 0x1c(%rsp) movq 0x38(%rsp), %rdi leaq 0xcecf(%rip), %rsi # 0x34fb8 callq 0x28160 movq %rax, 0x10(%rsp) cmpq $0x0, 0x10(%rsp) jne 0x28119 leaq 0xceb9(%rip), %rdi # 0x34fbb callq 0x28190 movl %eax, %ecx xorl %eax, %eax cmpl $0x0, %ecx cmovneq %rax, %rax movq %rax, 0x40(%rsp) jmp 0x28150 movq 0x10(%rsp), %rdi movq 0x30(%rsp), %rsi movq 0x28(%rsp), %rdx movq 0x20(%rsp), %rcx movl 0x1c(%rsp), %r8d callq 0x281b0 movq %rax, 0x8(%rsp) movq 0x10(%rsp), %rdi callq 0x1a270 movq 0x8(%rsp), %rax movq %rax, 0x40(%rsp) movq 0x40(%rsp), %rax addq $0x48, %rsp retq nopw (%rax,%rax)
stbi_load: sub rsp, 48h mov [rsp+48h+var_10], rdi mov [rsp+48h+var_18], rsi mov [rsp+48h+var_20], rdx mov [rsp+48h+var_28], rcx mov [rsp+48h+var_2C], r8d mov rdi, [rsp+48h+var_10]; char * lea rsi, aRb; "rb" call _ZL11stbi__fopenPKcS0_; stbi__fopen(char const*,char const*) mov [rsp+48h+var_38], rax cmp [rsp+48h+var_38], 0 jnz short loc_28119 lea rdi, aCanTFopen; "can't fopen" call _ZL9stbi__errPKc; stbi__err(char const*) mov ecx, eax xor eax, eax cmp ecx, 0 cmovnz rax, rax mov [rsp+48h+var_8], rax jmp short loc_28150 loc_28119: mov rdi, [rsp+48h+var_38] mov rsi, [rsp+48h+var_18] mov rdx, [rsp+48h+var_20] mov rcx, [rsp+48h+var_28] mov r8d, [rsp+48h+var_2C] call stbi_load_from_file mov [rsp+48h+var_40], rax mov rdi, [rsp+48h+var_38] call _fclose mov rax, [rsp+48h+var_40] mov [rsp+48h+var_8], rax loc_28150: mov rax, [rsp+48h+var_8] add rsp, 48h retn
long long stbi_load(const char *a1, long long a2, long long a3, long long a4, unsigned int a5) { long long v6; // [rsp+8h] [rbp-40h] long long v7; // [rsp+10h] [rbp-38h] v7 = stbi__fopen(a1, "rb"); if ( v7 ) { v6 = stbi_load_from_file(v7, a2, a3, a4, a5); fclose(v7); return v6; } else { stbi__err("can't fopen"); return 0LL; } }
stbi_load: SUB RSP,0x48 MOV qword ptr [RSP + 0x38],RDI MOV qword ptr [RSP + 0x30],RSI MOV qword ptr [RSP + 0x28],RDX MOV qword ptr [RSP + 0x20],RCX MOV dword ptr [RSP + 0x1c],R8D MOV RDI,qword ptr [RSP + 0x38] LEA RSI,[0x134fb8] CALL 0x00128160 MOV qword ptr [RSP + 0x10],RAX CMP qword ptr [RSP + 0x10],0x0 JNZ 0x00128119 LEA RDI,[0x134fbb] CALL 0x00128190 MOV ECX,EAX XOR EAX,EAX CMP ECX,0x0 CMOVNZ RAX,RAX MOV qword ptr [RSP + 0x40],RAX JMP 0x00128150 LAB_00128119: MOV RDI,qword ptr [RSP + 0x10] MOV RSI,qword ptr [RSP + 0x30] MOV RDX,qword ptr [RSP + 0x28] MOV RCX,qword ptr [RSP + 0x20] MOV R8D,dword ptr [RSP + 0x1c] CALL 0x001281b0 MOV qword ptr [RSP + 0x8],RAX MOV RDI,qword ptr [RSP + 0x10] CALL 0x0011a270 MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x40],RAX LAB_00128150: MOV RAX,qword ptr [RSP + 0x40] ADD RSP,0x48 RET
int8 stbi_load(char *param_1,int8 param_2,int8 param_3,int8 param_4,int4 param_5) { FILE *__stream; int8 local_8; __stream = (FILE *)stbi__fopen(param_1,"rb"); if (__stream == (FILE *)0x0) { stbi__err("can\'t fopen"); local_8 = 0; } else { local_8 = stbi_load_from_file(__stream,param_2,param_3,param_4,param_5); fclose(__stream); } return local_8; }
56,853
check_skipped_lsn
eloqsql/storage/maria/ma_loghandler.c
void check_skipped_lsn(MARIA_HA *info, LSN lsn, my_bool index_file, pgcache_page_no_t page) { if (lsn <= log_descriptor.horizon) { DBUG_PRINT("info", ("Page is up to date, skipping redo")); } else { /* Give error, but don't flood the log */ if (skipped_lsn_err_count++ < MAX_LSN_ERRORS && ! info->s->redo_error_given++) { eprint(tracef, "Table %s has wrong LSN: " LSN_FMT " on page: %llu", (index_file ? info->s->data_file_name.str : info->s->index_file_name.str), LSN_IN_PARTS(lsn), (ulonglong) page); recovery_found_crashed_tables++; } } }
O3
c
check_skipped_lsn: cmpq %rsi, 0xbb3f88(%rip) # 0xc016b8 jge 0x4d762 movq %rcx, %r9 movq %rsi, %r8 leaq 0xbb4379(%rip), %rax # 0xc01ab8 movl (%rax), %ecx leal 0x1(%rcx), %esi movl %esi, (%rax) cmpl $0x9, %ecx ja 0x4d762 movq (%rdi), %rax movb 0x7eb(%rax), %cl leal 0x1(%rcx), %esi movb %sil, 0x7eb(%rax) testb %cl, %cl je 0x4d763 retq pushq %rbp movq %rsp, %rbp leaq 0xbb433a(%rip), %rax # 0xc01aa8 movq (%rax), %rax xorl %ecx, %ecx testb %dl, %dl sete %cl movq (%rdi), %rdx shll $0x4, %ecx movq 0x5c0(%rdx,%rcx), %rdx movq %r8, %rcx shrq $0x20, %rcx leaq 0x8da77(%rip), %rsi # 0xdb20b movq %rax, %rdi xorl %eax, %eax callq 0x515e4 leaq 0xbb430b(%rip), %rax # 0xc01ab0 incq (%rax) popq %rbp retq
check_skipped_lsn: cmp cs:qword_C016B8, rsi jge short locret_4D762 mov r9, rcx mov r8, rsi lea rax, skipped_lsn_err_count mov ecx, [rax] lea esi, [rcx+1] mov [rax], esi cmp ecx, 9 ja short locret_4D762 mov rax, [rdi] mov cl, [rax+7EBh] lea esi, [rcx+1] mov [rax+7EBh], sil test cl, cl jz short loc_4D763 locret_4D762: retn loc_4D763: push rbp mov rbp, rsp lea rax, tracef mov rax, [rax] xor ecx, ecx test dl, dl setz cl mov rdx, [rdi] shl ecx, 4 mov rdx, [rdx+rcx+5C0h] mov rcx, r8 shr rcx, 20h lea rsi, aTableSHasWrong; "Table %s has wrong LSN: (%u,0x%x) on pa"... mov rdi, rax xor eax, eax call eprint lea rax, recovery_found_crashed_tables inc qword ptr [rax] pop rbp retn
_QWORD * check_skipped_lsn(long long a1, long long a2, char a3, int a4) { char v4; // bp _QWORD *result; // rax unsigned int v7; // ecx char v8; // cl if ( qword_C016B8 < a2 ) { result = &skipped_lsn_err_count; v7 = skipped_lsn_err_count++; if ( v7 <= 9 ) { result = *(_QWORD **)a1; v8 = *(_BYTE *)(*(_QWORD *)a1 + 2027LL); *(_BYTE *)(*(_QWORD *)a1 + 2027LL) = v8 + 1; if ( !v8 ) { eprint( tracef, (unsigned int)"Table %s has wrong LSN: (%u,0x%x) on page: %llu", *(_QWORD *)(*(_QWORD *)a1 + 16 * (unsigned int)(a3 == 0) + 1472LL), HIDWORD(a2), a2, a4, v4); result = &recovery_found_crashed_tables; ++recovery_found_crashed_tables; } } } return result; }
check_skipped_lsn: CMP qword ptr [0x00d016b8],RSI JGE 0x0014d762 MOV R9,RCX MOV R8,RSI LEA RAX,[0xd01ab8] MOV ECX,dword ptr [RAX] LEA ESI,[RCX + 0x1] MOV dword ptr [RAX],ESI CMP ECX,0x9 JA 0x0014d762 MOV RAX,qword ptr [RDI] MOV CL,byte ptr [RAX + 0x7eb] LEA ESI,[RCX + 0x1] MOV byte ptr [RAX + 0x7eb],SIL TEST CL,CL JZ 0x0014d763 LAB_0014d762: RET LAB_0014d763: PUSH RBP MOV RBP,RSP LEA RAX,[0xd01aa8] MOV RAX,qword ptr [RAX] XOR ECX,ECX TEST DL,DL SETZ CL MOV RDX,qword ptr [RDI] SHL ECX,0x4 MOV RDX,qword ptr [RDX + RCX*0x1 + 0x5c0] MOV RCX,R8 SHR RCX,0x20 LEA RSI,[0x1db20b] MOV RDI,RAX XOR EAX,EAX CALL 0x001515e4 LEA RAX,[0xd01ab0] INC qword ptr [RAX] POP RBP RET
void check_skipped_lsn(long *param_1,ulong param_2,char param_3,int8 param_4) { char cVar1; bool bVar2; uint uVar3; if (((DAT_00d016b8 < (long)param_2) && (uVar3 = skipped_lsn_err_count + 1, bVar2 = skipped_lsn_err_count < 10, skipped_lsn_err_count = uVar3, bVar2)) && (cVar1 = *(char *)(*param_1 + 0x7eb), *(char *)(*param_1 + 0x7eb) = cVar1 + '\x01', cVar1 == '\0')) { eprint(tracef,"Table %s has wrong LSN: (%u,0x%x) on page: %llu", *(int8 *)(*param_1 + 0x5c0 + (ulong)(param_3 == '\0') * 0x10),param_2 >> 0x20, param_2,param_4); recovery_found_crashed_tables = recovery_found_crashed_tables + 1; return; } return; }
56,854
SchemaConverter::_not_strings(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&)::TrieNode::insert(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
monkey531[P]llama/common/json-schema-to-grammar.cpp
void insert(const std::string & string) { auto node = this; for (char c : string) { node = &node->children[c]; } node->is_end_of_string = true; }
O3
cpp
SchemaConverter::_not_strings(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&)::TrieNode::insert(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rax movq 0x8(%rsi), %r14 testq %r14, %r14 je 0xc6f48 movq (%rsi), %r15 xorl %r12d, %r12d leaq 0x7(%rsp), %rbx movb (%r15,%r12), %cl movb %cl, 0x7(%rsp) movq %rax, %rdi movq %rbx, %rsi callq 0xc6f58 incq %r12 cmpq %r12, %r14 jne 0xc6f2d movb $0x1, 0x30(%rax) addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
_ZZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EEEN8TrieNode6insertERKS6_: push r15 push r14 push r12 push rbx push rax mov rax, rdi mov r14, [rsi+8] test r14, r14 jz short loc_C6F48 mov r15, [rsi] xor r12d, r12d lea rbx, [rsp+28h+var_21] loc_C6F2D: mov cl, [r15+r12] mov [rsp+28h+var_21], cl mov rdi, rax mov rsi, rbx call _ZNSt3mapIcZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEE8TrieNodeSt4lessIcESaISt4pairIKcSC_EEEixERSG_; std::map<char,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode,std::less<char>,std::allocator<std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>>>::operator[](char const&) inc r12 cmp r14, r12 jnz short loc_C6F2D loc_C6F48: mov byte ptr [rax+30h], 1 add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
long long SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode::insert( long long a1, long long *a2) { long long v2; // rax long long result; // rax long long v4; // r14 long long v5; // r15 long long i; // r12 _BYTE v7[33]; // [rsp+1h] [rbp-21h] BYREF v7[0] = HIBYTE(v2); result = a1; v4 = a2[1]; if ( v4 ) { v5 = *a2; for ( i = 0LL; i != v4; ++i ) { v7[0] = *(_BYTE *)(v5 + i); result = std::map<char,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode,std::less<char>,std::allocator<std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>>>::operator[]( result, v7); } } *(_BYTE *)(result + 48) = 1; return result; }
string_const&): PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RAX,RDI MOV R14,qword ptr [RSI + 0x8] TEST R14,R14 JZ 0x001c6f48 MOV R15,qword ptr [RSI] XOR R12D,R12D LEA RBX,[RSP + 0x7] LAB_001c6f2d: MOV CL,byte ptr [R15 + R12*0x1] MOV byte ptr [RSP + 0x7],CL MOV RDI,RAX MOV RSI,RBX CALL 0x001c6f58 INC R12 CMP R14,R12 JNZ 0x001c6f2d LAB_001c6f48: MOV byte ptr [RAX + 0x30],0x1 ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
/* SchemaConverter::_not_strings(std::vector<std::__cxx11::string, std::allocator<std::__cxx11::string > > const&)::TrieNode::insert(std::__cxx11::string const&) */ void SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11:: string>>const&)::TrieNode::insert(std::__cxx11::string_const__ (map<char,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode,std::less<char>,std::allocator<std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>>> *param_1,long *param_2) { long lVar1; long lVar2; int8 in_RAX; long lVar3; int8 uStack_28; lVar1 = param_2[1]; if (lVar1 != 0) { lVar2 = *param_2; lVar3 = 0; uStack_28 = in_RAX; do { uStack_28 = CONCAT17(*(int1 *)(lVar2 + lVar3),(int7)uStack_28); param_1 = (map<char,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode,std::less<char>,std::allocator<std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>>> *)std:: map<char,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode,std::less<char>,std::allocator<std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>>> ::operator[](param_1,(char *)((long)&uStack_28 + 7)); lVar3 = lVar3 + 1; } while (lVar1 != lVar3); } param_1[0x30] = (map<char,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode,std::less<char>,std::allocator<std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>>> )0x1; return; }
56,855
minja::Parser::parseMathPlusMinus()
monkey531[P]llama/common/minja.hpp
std::shared_ptr<Expression> parseMathPlusMinus() { static std::regex plus_minus_tok(R"(\+|-(?![}%#]\}))"); auto left = parseMathMulDiv(); if (!left) throw std::runtime_error("Expected left side of 'math plus/minus' expression"); std::string op_str; while (!(op_str = consumeToken(plus_minus_tok)).empty()) { auto right = parseMathMulDiv(); if (!right) throw std::runtime_error("Expected right side of 'math plus/minus' expression"); auto op = op_str == "+" ? BinaryOpExpr::Op::Add : BinaryOpExpr::Op::Sub; left = std::make_shared<BinaryOpExpr>(get_location(), std::move(left), std::move(right), op); } return left; }
O3
cpp
minja::Parser::parseMathPlusMinus(): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x68, %rsp movq %rsi, %r14 movq %rdi, %rbp leaq 0x9db91(%rip), %rax # 0xdee68 movb (%rax), %al testb %al, %al movq %rdi, 0x8(%rsp) je 0x414d5 movq %rbp, %rdi movq %r14, %rsi callq 0x415f8 cmpq $0x0, (%rbp) je 0x41531 leaq 0x50(%rsp), %rax movq %rax, -0x10(%rax) movq $0x0, -0x8(%rax) movb $0x0, (%rax) leaq 0x20(%rsp), %r12 leaq 0x40(%rsp), %r13 leaq 0x9b677(%rip), %rax # 0xdc998 addq $0x10, %rax movq %rax, 0x60(%rsp) movq %r12, %rdi movq %r14, %rsi leaq 0x9db11(%rip), %rdx # 0xdee48 movl $0x1, %ecx callq 0x313dc movq %r13, %rdi movq %r12, %rsi callq 0x18800 movq 0x8(%rax), %r15 movq 0x20(%rsp), %rdi leaq 0x30(%rsp), %rax cmpq %rax, %rdi je 0x4136c movq 0x30(%rsp), %rsi incq %rsi callq 0x186a0 testq %r15, %r15 je 0x41470 leaq 0x10(%rsp), %rdi movq %r14, %rsi callq 0x415f8 cmpq $0x0, 0x10(%rsp) je 0x4149e movq %r13, %rdi leaq 0x6b503(%rip), %rsi # 0xac89b callq 0x18190 cmpl $0x1, %eax movl $0x2, %r15d sbbl $0x0, %r15d movq (%r14), %rax movq %rax, 0x20(%rsp) movq 0x8(%r14), %rax movq %rax, 0x28(%rsp) testq %rax, %rax je 0x413d5 movq 0x9cbd1(%rip), %rcx # 0xddf98 cmpb $0x0, (%rcx) je 0x413d1 incl 0x8(%rax) jmp 0x413d5 lock incl 0x8(%rax) movq 0x20(%r14), %rax movq %r14, %rbx subq 0x10(%r14), %rax movq %rax, 0x30(%rsp) movl $0x58, %edi callq 0x18690 movq %rax, %r13 movabsq $0x100000001, %rax # imm = 0x100000001 movq %rax, 0x8(%r13) movq 0x60(%rsp), %rax movq %rax, (%r13) movq %r13, %r14 addq $0x10, %r14 movq %r14, %rdi movq %r12, %rsi movq 0x8(%rsp), %rbp movq %rbp, %rdx leaq 0x10(%rsp), %rcx movl %r15d, %r8d callq 0x581d6 movq %r14, (%rbp) movq 0x8(%rbp), %rdi movq %r13, 0x8(%rbp) testq %rdi, %rdi je 0x41441 callq 0x30ed6 movq 0x28(%rsp), %rdi testq %rdi, %rdi je 0x41450 callq 0x30ed6 movq 0x18(%rsp), %rdi testq %rdi, %rdi leaq 0x40(%rsp), %r13 movq %rbx, %r14 je 0x4132a callq 0x30ed6 jmp 0x4132a movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0x4148c movq 0x50(%rsp), %rsi incq %rsi callq 0x186a0 movq %rbp, %rax addq $0x68, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0x10, %edi callq 0x18350 movq %rax, %r15 leaq 0x69764(%rip), %rsi # 0xaac16 movq %rax, %rdi callq 0x18260 movq 0x9cb2f(%rip), %rsi # 0xddff0 movq 0x9caa8(%rip), %rdx # 0xddf70 movq %r15, %rdi callq 0x18b50 jmp 0x41563 leaq 0x9d98c(%rip), %rdi # 0xdee68 callq 0x18c10 testl %eax, %eax je 0x412e6 leaq 0x9d958(%rip), %rdi # 0xdee48 leaq 0x696dc(%rip), %rsi # 0xaabd3 movl $0x10, %edx callq 0x30f46 leaq -0x1055a(%rip), %rdi # 0x30fae leaq 0x9d939(%rip), %rsi # 0xdee48 leaq 0x9d1a2(%rip), %rdx # 0xde6b8 callq 0x185d0 leaq 0x9d946(%rip), %rdi # 0xdee68 callq 0x18440 movq 0x8(%rsp), %rbp jmp 0x412e6 movl $0x10, %edi callq 0x18350 movq %rax, %r15 leaq 0x6969e(%rip), %rsi # 0xaabe3 movq %rax, %rdi callq 0x18260 movq 0x9ca9c(%rip), %rsi # 0xddff0 movq 0x9ca15(%rip), %rdx # 0xddf70 movq %r15, %rdi callq 0x18b50 movq %rax, %r14 leaq 0x9d8fb(%rip), %rdi # 0xdee68 callq 0x18430 jmp 0x415ef movq %rax, %r14 jmp 0x415dc movq %rax, %r14 movq %r15, %rdi callq 0x184f0 jmp 0x415dc movq %rax, %r14 jmp 0x415ac movq %rax, %r14 movq %r15, %rdi callq 0x184f0 jmp 0x415ac jmp 0x415bd movq %rax, %r14 movq 0x28(%rsp), %rdi testq %rdi, %rdi je 0x415ac callq 0x30ed6 movq 0x18(%rsp), %rdi testq %rdi, %rdi je 0x415c0 callq 0x30ed6 jmp 0x415c0 movq %rax, %r14 movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0x415dc movq 0x50(%rsp), %rsi incq %rsi callq 0x186a0 movq 0x8(%rsp), %rax movq 0x8(%rax), %rdi testq %rdi, %rdi je 0x415ef callq 0x30ed6 movq %r14, %rdi callq 0x18bc0 nop
_ZN5minja6Parser18parseMathPlusMinusEv: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 68h mov r14, rsi mov rbp, rdi lea rax, _ZGVZN5minja6Parser18parseMathPlusMinusEvE14plus_minus_tokB5cxx11; `guard variable for'minja::Parser::parseMathPlusMinus(void)::plus_minus_tok mov al, [rax] test al, al mov [rsp+98h+var_90], rdi jz loc_414D5 loc_412E6: mov rdi, rbp; this mov rsi, r14 call _ZN5minja6Parser15parseMathMulDivEv; minja::Parser::parseMathMulDiv(void) cmp qword ptr [rbp+0], 0 jz loc_41531 lea rax, [rsp+98h+var_48] mov [rax-10h], rax mov qword ptr [rax-8], 0 mov byte ptr [rax], 0 lea r12, [rsp+98h+var_78] lea r13, [rsp+98h+var_58] lea rax, _ZTVSt23_Sp_counted_ptr_inplaceIN5minja12BinaryOpExprESaIS1_ELN9__gnu_cxx12_Lock_policyE2EE; `vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2> add rax, 10h mov [rsp+98h+var_38], rax loc_4132A: mov rdi, r12 mov rsi, r14 lea rdx, _ZZN5minja6Parser18parseMathPlusMinusEvE14plus_minus_tokB5cxx11; minja::Parser::parseMathPlusMinus(void)::plus_minus_tok mov ecx, 1 call _ZN5minja6Parser12consumeTokenERKNSt7__cxx1111basic_regexIcNS1_12regex_traitsIcEEEENS_13SpaceHandlingE; minja::Parser::consumeToken(std::basic_regex<char,std::regex_traits<char>> const&,minja::SpaceHandling) mov rdi, r13 mov rsi, r12 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov r15, [rax+8] mov rdi, [rsp+98h+var_78]; void * lea rax, [rsp+98h+var_68] cmp rdi, rax jz short loc_4136C mov rsi, [rsp+98h+var_68] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_4136C: test r15, r15 jz loc_41470 lea rdi, [rsp+98h+var_88]; this mov rsi, r14 call _ZN5minja6Parser15parseMathMulDivEv; minja::Parser::parseMathMulDiv(void) cmp [rsp+98h+var_88], 0 jz loc_4149E mov rdi, r13 lea rsi, aSRN_0+0Bh; "+" call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*) cmp eax, 1 mov r15d, 2 sbb r15d, 0 mov rax, [r14] mov [rsp+98h+var_78], rax mov rax, [r14+8] mov [rsp+98h+var_70], rax test rax, rax jz short loc_413D5 mov rcx, cs:__libc_single_threaded_ptr cmp byte ptr [rcx], 0 jz short loc_413D1 inc dword ptr [rax+8] jmp short loc_413D5 loc_413D1: lock inc dword ptr [rax+8] loc_413D5: mov rax, [r14+20h] mov rbx, r14 sub rax, [r14+10h] mov [rsp+98h+var_68], rax mov edi, 58h ; 'X'; unsigned __int64 call __Znwm; operator new(ulong) mov r13, rax mov rax, 100000001h mov [r13+8], rax mov rax, [rsp+98h+var_38] mov [r13+0], rax mov r14, r13 add r14, 10h mov rdi, r14 mov rsi, r12 mov rbp, [rsp+98h+var_90] mov rdx, rbp lea rcx, [rsp+98h+var_88] mov r8d, r15d call _ZN5minja12BinaryOpExprC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEES7_NS0_2OpE; minja::BinaryOpExpr::BinaryOpExpr(minja::Location const&,std::shared_ptr<minja::Expression> &&,std::shared_ptr<minja::Expression> &,minja::BinaryOpExpr::Op) mov [rbp+0], r14 mov rdi, [rbp+8] mov [rbp+8], r13 test rdi, rdi jz short loc_41441 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_41441: mov rdi, [rsp+98h+var_70] test rdi, rdi jz short loc_41450 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_41450: mov rdi, [rsp+98h+var_80] test rdi, rdi lea r13, [rsp+98h+var_58] mov r14, rbx jz loc_4132A call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) jmp loc_4132A loc_41470: mov rdi, [rsp+98h+var_58]; void * lea rax, [rsp+98h+var_48] cmp rdi, rax jz short loc_4148C mov rsi, [rsp+98h+var_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_4148C: mov rax, rbp add rsp, 68h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_4149E: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r15, rax lea rsi, aExpectedRightS_4; "Expected right side of 'math plus/minus"... mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r15; void * call ___cxa_throw jmp loc_41563 loc_414D5: lea rdi, _ZGVZN5minja6Parser18parseMathPlusMinusEvE14plus_minus_tokB5cxx11; __guard * call ___cxa_guard_acquire test eax, eax jz loc_412E6 lea rdi, _ZZN5minja6Parser18parseMathPlusMinusEvE14plus_minus_tokB5cxx11; minja::Parser::parseMathPlusMinus(void)::plus_minus_tok lea rsi, asc_AABD3; "\\+|-(?![}%#]\\})" mov edx, 10h call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEEC2EPKcNSt15regex_constants18syntax_option_typeE; std::basic_regex<char,std::regex_traits<char>>::basic_regex(char const*,std::regex_constants::syntax_option_type) lea rdi, _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; lpfunc lea rsi, _ZZN5minja6Parser18parseMathPlusMinusEvE14plus_minus_tokB5cxx11; obj lea rdx, __dso_handle; lpdso_handle call ___cxa_atexit lea rdi, _ZGVZN5minja6Parser18parseMathPlusMinusEvE14plus_minus_tokB5cxx11; __guard * call ___cxa_guard_release mov rbp, [rsp+98h+var_90] jmp loc_412E6 loc_41531: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r15, rax lea rsi, aExpectedLeftSi_4; "Expected left side of 'math plus/minus'"... mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r15; void * call ___cxa_throw loc_41563: mov r14, rax lea rdi, _ZGVZN5minja6Parser18parseMathPlusMinusEvE14plus_minus_tokB5cxx11; __guard * call ___cxa_guard_abort jmp short loc_415EF mov r14, rax jmp short loc_415DC mov r14, rax mov rdi, r15; void * call ___cxa_free_exception jmp short loc_415DC mov r14, rax jmp short loc_415AC mov r14, rax mov rdi, r15; void * call ___cxa_free_exception jmp short loc_415AC jmp short loc_415BD mov r14, rax mov rdi, [rsp+98h+var_70] test rdi, rdi jz short loc_415AC call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_415AC: mov rdi, [rsp+98h+var_80] test rdi, rdi jz short loc_415C0 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) jmp short loc_415C0 loc_415BD: mov r14, rax loc_415C0: mov rdi, [rsp+98h+var_58]; void * lea rax, [rsp+98h+var_48] cmp rdi, rax jz short loc_415DC mov rsi, [rsp+98h+var_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_415DC: mov rax, [rsp+98h+var_90] mov rdi, [rax+8] test rdi, rdi jz short loc_415EF call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_415EF: mov rdi, r14 call __Unwind_Resume
minja::Parser * minja::Parser::parseMathPlusMinus(volatile signed __int32 **this, long long a2) { minja::Parser *v2; // rbp long long v3; // r15 unsigned int v4; // r15d volatile signed __int32 *v5; // rax long long **v6; // r13 volatile signed __int32 *v7; // rdi std::runtime_error *v9; // r15 std::runtime_error *exception; // r15 long long v12; // [rsp+10h] [rbp-88h] BYREF volatile signed __int32 *v13; // [rsp+18h] [rbp-80h] void *v14; // [rsp+20h] [rbp-78h] BYREF volatile signed __int32 *v15; // [rsp+28h] [rbp-70h] long long v16; // [rsp+30h] [rbp-68h] BYREF void *v17[2]; // [rsp+40h] [rbp-58h] BYREF _QWORD v18[2]; // [rsp+50h] [rbp-48h] BYREF long long *v19; // [rsp+60h] [rbp-38h] v2 = (minja::Parser *)this; if ( !(_BYTE)`guard variable for'minja::Parser::parseMathPlusMinus(void)::plus_minus_tok[abi:cxx11] && __cxa_guard_acquire(&`guard variable for'minja::Parser::parseMathPlusMinus(void)::plus_minus_tok[abi:cxx11]) ) { std::basic_regex<char,std::regex_traits<char>>::basic_regex( (long long)&minja::Parser::parseMathPlusMinus(void)::plus_minus_tok[abi:cxx11], "\\+|-(?![}%#]\\})", 0x10u); __cxa_atexit( (void (*)(void *))std::basic_regex<char,std::regex_traits<char>>::~basic_regex, &minja::Parser::parseMathPlusMinus(void)::plus_minus_tok[abi:cxx11], &_dso_handle); __cxa_guard_release(&`guard variable for'minja::Parser::parseMathPlusMinus(void)::plus_minus_tok[abi:cxx11]); v2 = (minja::Parser *)this; } minja::Parser::parseMathMulDiv(v2); if ( !*(_QWORD *)v2 ) { exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "Expected left side of 'math plus/minus' expression"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v17[0] = v18; v17[1] = 0LL; LOBYTE(v18[0]) = 0; v19 = &`vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2> + 2; while ( 1 ) { minja::Parser::consumeToken( (long long)&v14, a2, (long long)&minja::Parser::parseMathPlusMinus(void)::plus_minus_tok[abi:cxx11], 1u); v3 = *(_QWORD *)(std::string::operator=(v17) + 8); if ( v14 != &v16 ) operator delete(v14, v16 + 1); if ( !v3 ) break; minja::Parser::parseMathMulDiv((minja::Parser *)&v12); if ( !v12 ) { v9 = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(v9, "Expected right side of 'math plus/minus' expression"); __cxa_throw( v9, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v4 = (((unsigned int)std::string::compare(v17, "+") | 0x200000000uLL) - 1) >> 32; v14 = *(void **)a2; v5 = *(volatile signed __int32 **)(a2 + 8); v15 = v5; if ( v5 ) { if ( _libc_single_threaded ) ++*((_DWORD *)v5 + 2); else _InterlockedIncrement(v5 + 2); } v16 = *(_QWORD *)(a2 + 32) - *(_QWORD *)(a2 + 16); v6 = (long long **)operator new(0x58uLL); v6[1] = (long long *)0x100000001LL; *v6 = v19; v2 = (minja::Parser *)this; minja::BinaryOpExpr::BinaryOpExpr(v6 + 2, &v14, this, &v12, v4); *this = (volatile signed __int32 *)(v6 + 2); v7 = this[1]; this[1] = (volatile signed __int32 *)v6; if ( v7 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v7); if ( v15 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v15); if ( v13 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v13); } if ( v17[0] != v18 ) operator delete(v17[0], v18[0] + 1LL); return v2; }
parseMathPlusMinus: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x68 MOV R14,RSI MOV RBP,RDI LEA RAX,[0x1dee68] MOV AL,byte ptr [RAX] TEST AL,AL MOV qword ptr [RSP + 0x8],RDI JZ 0x001414d5 LAB_001412e6: MOV RDI,RBP MOV RSI,R14 CALL 0x001415f8 CMP qword ptr [RBP],0x0 JZ 0x00141531 LEA RAX,[RSP + 0x50] MOV qword ptr [RAX + -0x10],RAX MOV qword ptr [RAX + -0x8],0x0 MOV byte ptr [RAX],0x0 LEA R12,[RSP + 0x20] LEA R13,[RSP + 0x40] LEA RAX,[0x1dc998] ADD RAX,0x10 MOV qword ptr [RSP + 0x60],RAX LAB_0014132a: MOV RDI,R12 MOV RSI,R14 LEA RDX,[0x1dee48] MOV ECX,0x1 CALL 0x001313dc MOV RDI,R13 MOV RSI,R12 CALL 0x00118800 MOV R15,qword ptr [RAX + 0x8] MOV RDI,qword ptr [RSP + 0x20] LEA RAX,[RSP + 0x30] CMP RDI,RAX JZ 0x0014136c MOV RSI,qword ptr [RSP + 0x30] INC RSI CALL 0x001186a0 LAB_0014136c: TEST R15,R15 JZ 0x00141470 LAB_00141375: LEA RDI,[RSP + 0x10] MOV RSI,R14 CALL 0x001415f8 CMP qword ptr [RSP + 0x10],0x0 JZ 0x0014149e MOV RDI,R13 LEA RSI,[0x1ac89b] CALL 0x00118190 CMP EAX,0x1 MOV R15D,0x2 SBB R15D,0x0 MOV RAX,qword ptr [R14] MOV qword ptr [RSP + 0x20],RAX MOV RAX,qword ptr [R14 + 0x8] MOV qword ptr [RSP + 0x28],RAX TEST RAX,RAX JZ 0x001413d5 MOV RCX,qword ptr [0x001ddf98] CMP byte ptr [RCX],0x0 JZ 0x001413d1 INC dword ptr [RAX + 0x8] JMP 0x001413d5 LAB_001413d1: INC.LOCK dword ptr [RAX + 0x8] LAB_001413d5: MOV RAX,qword ptr [R14 + 0x20] MOV RBX,R14 SUB RAX,qword ptr [R14 + 0x10] MOV qword ptr [RSP + 0x30],RAX LAB_001413e5: MOV EDI,0x58 CALL 0x00118690 LAB_001413ef: MOV R13,RAX MOV RAX,0x100000001 MOV qword ptr [R13 + 0x8],RAX MOV RAX,qword ptr [RSP + 0x60] MOV qword ptr [R13],RAX MOV R14,R13 ADD R14,0x10 MOV RDI,R14 MOV RSI,R12 MOV RBP,qword ptr [RSP + 0x8] MOV RDX,RBP LEA RCX,[RSP + 0x10] MOV R8D,R15D CALL 0x001581d6 MOV qword ptr [RBP],R14 MOV RDI,qword ptr [RBP + 0x8] MOV qword ptr [RBP + 0x8],R13 TEST RDI,RDI JZ 0x00141441 CALL 0x00130ed6 LAB_00141441: MOV RDI,qword ptr [RSP + 0x28] TEST RDI,RDI JZ 0x00141450 CALL 0x00130ed6 LAB_00141450: MOV RDI,qword ptr [RSP + 0x18] TEST RDI,RDI LEA R13,[RSP + 0x40] MOV R14,RBX JZ 0x0014132a CALL 0x00130ed6 JMP 0x0014132a LAB_00141470: MOV RDI,qword ptr [RSP + 0x40] LEA RAX,[RSP + 0x50] CMP RDI,RAX JZ 0x0014148c MOV RSI,qword ptr [RSP + 0x50] INC RSI CALL 0x001186a0 LAB_0014148c: MOV RAX,RBP ADD RSP,0x68 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0014149e: MOV EDI,0x10 CALL 0x00118350 MOV R15,RAX LAB_001414ab: LEA RSI,[0x1aac16] MOV RDI,RAX CALL 0x00118260 LAB_001414ba: MOV RSI,qword ptr [0x001ddff0] MOV RDX,qword ptr [0x001ddf70] MOV RDI,R15 CALL 0x00118b50 LAB_001414d5: LEA RDI,[0x1dee68] CALL 0x00118c10 TEST EAX,EAX JZ 0x001412e6 LAB_001414e9: LEA RDI,[0x1dee48] LEA RSI,[0x1aabd3] MOV EDX,0x10 CALL 0x00130f46 LAB_00141501: LEA RDI,[0x130fae] LEA RSI,[0x1dee48] LEA RDX,[0x1de6b8] CALL 0x001185d0 LEA RDI,[0x1dee68] CALL 0x00118440 MOV RBP,qword ptr [RSP + 0x8] JMP 0x001412e6 LAB_00141531: MOV EDI,0x10 CALL 0x00118350 MOV R15,RAX LAB_0014153e: LEA RSI,[0x1aabe3] MOV RDI,RAX CALL 0x00118260 LAB_0014154d: MOV RSI,qword ptr [0x001ddff0] MOV RDX,qword ptr [0x001ddf70] MOV RDI,R15 CALL 0x00118b50
/* minja::Parser::parseMathPlusMinus() */ long * minja::Parser::parseMathPlusMinus(void) { _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *this; int iVar1; long lVar2; int8 *puVar3; runtime_error *prVar4; int8 *in_RSI; long *in_RDI; long local_88; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_80; long *local_78; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_70; long local_68 [2]; int1 *local_58; int8 local_50; int1 local_48; int7 uStack_47; int **local_38; if (parseMathPlusMinus()::plus_minus_tok_abi_cxx11_ == '\0') { iVar1 = __cxa_guard_acquire(&parseMathPlusMinus()::plus_minus_tok_abi_cxx11_); if (iVar1 != 0) { /* try { // try from 001414e9 to 00141500 has its CatchHandler @ 00141563 */ std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::basic_regex ((basic_regex<char,std::__cxx11::regex_traits<char>> *) parseMathPlusMinus()::plus_minus_tok_abi_cxx11_,"\\+|-(?![}%#]\\})",0x10); __cxa_atexit(std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex, parseMathPlusMinus()::plus_minus_tok_abi_cxx11_,&__dso_handle); __cxa_guard_release(&parseMathPlusMinus()::plus_minus_tok_abi_cxx11_); } } parseMathMulDiv(); if (*in_RDI != 0) { local_58 = &local_48; local_50 = 0; local_48 = 0; local_38 = &PTR___Sp_counted_ptr_inplace_001dc9a8; while( true ) { /* try { // try from 0014132a to 00141340 has its CatchHandler @ 001415bd */ consumeToken((string *)&local_78,in_RSI,parseMathPlusMinus()::plus_minus_tok_abi_cxx11_,1); lVar2 = std::__cxx11::string::operator=((string *)&local_58,(string *)&local_78); lVar2 = *(long *)(lVar2 + 8); if (local_78 != local_68) { operator_delete(local_78,local_68[0] + 1); } if (lVar2 == 0) break; /* try { // try from 00141375 to 00141381 has its CatchHandler @ 00141598 */ parseMathMulDiv(); if (local_88 == 0) { prVar4 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001414ab to 001414b9 has its CatchHandler @ 0014158b */ std::runtime_error::runtime_error (prVar4,"Expected right side of \'math plus/minus\' expression"); /* try { // try from 001414ba to 001414cf has its CatchHandler @ 00141586 */ /* WARNING: Subroutine does not return */ __cxa_throw(prVar4,PTR_typeinfo_001ddff0,PTR__runtime_error_001ddf70); } iVar1 = std::__cxx11::string::compare((char *)&local_58); local_78 = (long *)*in_RSI; local_70 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RSI[1]; if (local_70 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { if (*PTR___libc_single_threaded_001ddf98 == '\0') { LOCK(); *(int *)(local_70 + 8) = *(int *)(local_70 + 8) + 1; UNLOCK(); } else { *(int *)(local_70 + 8) = *(int *)(local_70 + 8) + 1; } } local_68[0] = in_RSI[4] - in_RSI[2]; /* try { // try from 001413e5 to 001413ee has its CatchHandler @ 0014159a */ puVar3 = (int8 *)operator_new(0x58); puVar3[1] = 0x100000001; *puVar3 = local_38; BinaryOpExpr::BinaryOpExpr ((BinaryOpExpr *)(puVar3 + 2),(string *)&local_78,in_RDI,&local_88, 2 - (uint)(iVar1 == 0)); *in_RDI = (long)(puVar3 + 2); this = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RDI[1]; in_RDI[1] = (long)puVar3; if (this != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(this); } if (local_70 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_70); } if (local_80 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_80); } } if (local_58 != &local_48) { operator_delete(local_58,CONCAT71(uStack_47,local_48) + 1); } return in_RDI; } prVar4 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 0014153e to 0014154c has its CatchHandler @ 00141579 */ std::runtime_error::runtime_error(prVar4,"Expected left side of \'math plus/minus\' expression"); /* try { // try from 0014154d to 00141562 has its CatchHandler @ 00141574 */ /* WARNING: Subroutine does not return */ __cxa_throw(prVar4,PTR_typeinfo_001ddff0,PTR__runtime_error_001ddf70); }
56,856
has_path
eloqsql/mysys/my_getwd.c
my_bool has_path(const char *name) { return MY_TEST(strchr(name, FN_LIBCHAR)) #if FN_LIBCHAR != '/' || MY_TEST(strchr(name, '/')) #endif #ifdef FN_DEVCHAR || MY_TEST(strchr(name, FN_DEVCHAR)) #endif ; }
O3
c
has_path: pushq %rbp movq %rsp, %rbp movl $0x2f, %esi callq 0x3a5d0 testq %rax, %rax setne %al popq %rbp retq nopl (%rax)
has_path: push rbp mov rbp, rsp mov esi, 2Fh ; '/' call _strchr test rax, rax setnz al pop rbp retn
bool has_path(long long a1, long long a2, long long a3, long long a4) { return strchr(a1, 47LL, a3, a4) != 0; }
has_path: PUSH RBP MOV RBP,RSP MOV ESI,0x2f CALL 0x0013a5d0 TEST RAX,RAX SETNZ AL POP RBP RET
bool has_path(char *param_1) { char *pcVar1; pcVar1 = strchr(param_1,0x2f); return pcVar1 != (char *)0x0; }
56,857
rtree_find_next
eloqsql/storage/myisam/rt_index.c
int rtree_find_next(MI_INFO *info, uint keynr, uint search_flag) { my_off_t root; uint nod_cmp_flag; MI_KEYDEF *keyinfo = info->s->keyinfo + keynr; /* At the moment index can only properly handle the MBR_INTERSECT, so we use it for all sorts of queries. TODO: better searsh for CONTAINS/WITHIN. */ search_flag= nod_cmp_flag= MBR_INTERSECT; if (info->update & HA_STATE_DELETED) return rtree_find_first(info, keynr, info->lastkey, info->lastkey_length, search_flag); if (!info->buff_used) { uchar *key= info->int_keypos; while (key < info->int_maxpos) { if (!rtree_key_cmp(keyinfo->seg, info->first_mbr_key, key, info->last_rkey_length, search_flag)) { uchar *after_key = key + keyinfo->keylength; info->lastpos= _mi_dpos(info, 0, after_key); memcpy(info->lastkey, key, info->lastkey_length); if (after_key < info->int_maxpos) info->int_keypos= after_key; else info->buff_used= 1; return 0; } key+= keyinfo->keylength; } } if ((root = info->s->state.key_root[keynr]) == HA_OFFSET_ERROR) { my_errno= HA_ERR_END_OF_FILE; return -1; } /* TODO better search for CONTAINS/WITHIN. nod_cmp_flag= (((search_flag & (MBR_EQUAL | MBR_WITHIN)) ? MBR_WITHIN : MBR_INTERSECT)); */ return rtree_find_req(info, keyinfo, search_flag, nod_cmp_flag, root, 0); }
O3
c
rtree_find_next: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx testb $0x8, 0x1d0(%rdi) jne 0x89cca movq (%rbx), %rax movl %esi, %r13d imulq $0x70, %r13, %r14 addq 0x218(%rax), %r14 cmpb $0x0, 0x33d(%rbx) jne 0x89c9e movq 0x128(%rbx), %r15 cmpq 0x130(%rbx), %r15 jae 0x89c9e movq 0x28(%r14), %rdi movq 0x118(%rbx), %rsi movl 0x1dc(%rbx), %ecx movq %r15, %rdx movl $0x400, %r8d # imm = 0x400 callq 0x8b2f4 movzwl 0x12(%r14), %r12d addq %r15, %r12 testl %eax, %eax je 0x89d10 movq %r12, %r15 cmpq 0x130(%rbx), %r12 jb 0x89c60 movq (%rbx), %rax movq 0x98(%rax), %rax movq (%rax,%r13,8), %rdx cmpq $-0x1, %rdx je 0x89ced movq %rbx, %rdi movq %r14, %rsi xorl %ecx, %ecx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0x8999f movq 0x108(%rbx), %rdx movl 0x1d8(%rbx), %ecx movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0x8990c callq 0xa1b26 movl $0x89, (%rax) movl $0xffffffff, %r14d # imm = 0xFFFFFFFF movl %r14d, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq xorl %r14d, %r14d movq %rbx, %rdi xorl %esi, %esi movq %r12, %rdx callq 0x84591 movq %rax, 0x170(%rbx) movq 0x108(%rbx), %rdi movl 0x1d8(%rbx), %edx movq %r15, %rsi callq 0x29080 cmpq 0x130(%rbx), %r12 jae 0x89d4e movq %r12, 0x128(%rbx) jmp 0x89cfe movb $0x1, 0x33d(%rbx) jmp 0x89cfe
rtree_find_next: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdi test byte ptr [rdi+1D0h], 8 jnz loc_89CCA mov rax, [rbx] mov r13d, esi imul r14, r13, 70h ; 'p' add r14, [rax+218h] cmp byte ptr [rbx+33Dh], 0 jnz short loc_89C9E mov r15, [rbx+128h] cmp r15, [rbx+130h] jnb short loc_89C9E loc_89C60: mov rdi, [r14+28h] mov rsi, [rbx+118h] mov ecx, [rbx+1DCh] mov rdx, r15 mov r8d, 400h call rtree_key_cmp movzx r12d, word ptr [r14+12h] add r12, r15 test eax, eax jz loc_89D10 mov r15, r12 cmp r12, [rbx+130h] jb short loc_89C60 mov rax, [rbx] loc_89C9E: mov rax, [rax+98h] mov rdx, [rax+r13*8] cmp rdx, 0FFFFFFFFFFFFFFFFh jz short loc_89CED mov rdi, rbx mov rsi, r14 xor ecx, ecx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp rtree_find_req loc_89CCA: mov rdx, [rbx+108h] mov ecx, [rbx+1D8h] mov rdi, rbx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp rtree_find_first loc_89CED: call _my_thread_var mov dword ptr [rax], 89h mov r14d, 0FFFFFFFFh loc_89CFE: mov eax, r14d add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_89D10: xor r14d, r14d mov rdi, rbx xor esi, esi mov rdx, r12 call _mi_dpos mov [rbx+170h], rax mov rdi, [rbx+108h] mov edx, [rbx+1D8h] mov rsi, r15 call _memcpy cmp r12, [rbx+130h] jnb short loc_89D4E mov [rbx+128h], r12 jmp short loc_89CFE loc_89D4E: mov byte ptr [rbx+33Dh], 1 jmp short loc_89CFE
long long rtree_find_next(long long a1, unsigned int a2) { long long v2; // rbx long long v3; // rax long long v4; // r14 unsigned long long v5; // r15 int v6; // eax unsigned long long v7; // r12 long long v8; // rdx unsigned int v10; // r14d v2 = a1; if ( (*(_BYTE *)(a1 + 464) & 8) != 0 ) return rtree_find_first(a1, a2, *(_QWORD *)(a1 + 264), *(_DWORD *)(a1 + 472)); v3 = *(_QWORD *)a1; v4 = *(_QWORD *)(*(_QWORD *)a1 + 536LL) + 112LL * a2; if ( *(_BYTE *)(a1 + 829) || (v5 = *(_QWORD *)(a1 + 296), v5 >= *(_QWORD *)(a1 + 304)) ) { LABEL_7: v8 = *(_QWORD *)(*(_QWORD *)(v3 + 152) + 8LL * a2); if ( v8 != -1 ) return rtree_find_req((long long *)v2, v4, v8, 0LL); *(_DWORD *)my_thread_var(a1) = 137; return (unsigned int)-1; } else { while ( 1 ) { a1 = *(_QWORD *)(v4 + 40); v6 = rtree_key_cmp(a1, *(_QWORD *)(v2 + 280), v5, *(unsigned int *)(v2 + 476), 1024LL); v7 = v5 + *(unsigned __int16 *)(v4 + 18); if ( !v6 ) break; v5 += *(unsigned __int16 *)(v4 + 18); if ( v7 >= *(_QWORD *)(v2 + 304) ) { v3 = *(_QWORD *)v2; goto LABEL_7; } } v10 = 0; *(_QWORD *)(v2 + 368) = mi_dpos((long long *)v2, 0, v7); memcpy(*(_QWORD *)(v2 + 264), v5, *(unsigned int *)(v2 + 472)); if ( v7 >= *(_QWORD *)(v2 + 304) ) *(_BYTE *)(v2 + 829) = 1; else *(_QWORD *)(v2 + 296) = v7; } return v10; }
rtree_find_next: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI TEST byte ptr [RDI + 0x1d0],0x8 JNZ 0x00189cca MOV RAX,qword ptr [RBX] MOV R13D,ESI IMUL R14,R13,0x70 ADD R14,qword ptr [RAX + 0x218] CMP byte ptr [RBX + 0x33d],0x0 JNZ 0x00189c9e MOV R15,qword ptr [RBX + 0x128] CMP R15,qword ptr [RBX + 0x130] JNC 0x00189c9e LAB_00189c60: MOV RDI,qword ptr [R14 + 0x28] MOV RSI,qword ptr [RBX + 0x118] MOV ECX,dword ptr [RBX + 0x1dc] MOV RDX,R15 MOV R8D,0x400 CALL 0x0018b2f4 MOVZX R12D,word ptr [R14 + 0x12] ADD R12,R15 TEST EAX,EAX JZ 0x00189d10 MOV R15,R12 CMP R12,qword ptr [RBX + 0x130] JC 0x00189c60 MOV RAX,qword ptr [RBX] LAB_00189c9e: MOV RAX,qword ptr [RAX + 0x98] MOV RDX,qword ptr [RAX + R13*0x8] CMP RDX,-0x1 JZ 0x00189ced MOV RDI,RBX MOV RSI,R14 XOR ECX,ECX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x0018999f LAB_00189cca: MOV RDX,qword ptr [RBX + 0x108] MOV ECX,dword ptr [RBX + 0x1d8] MOV RDI,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x0018990c LAB_00189ced: CALL 0x001a1b26 MOV dword ptr [RAX],0x89 MOV R14D,0xffffffff LAB_00189cfe: MOV EAX,R14D ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00189d10: XOR R14D,R14D MOV RDI,RBX XOR ESI,ESI MOV RDX,R12 CALL 0x00184591 MOV qword ptr [RBX + 0x170],RAX MOV RDI,qword ptr [RBX + 0x108] MOV EDX,dword ptr [RBX + 0x1d8] MOV RSI,R15 CALL 0x00129080 CMP R12,qword ptr [RBX + 0x130] JNC 0x00189d4e MOV qword ptr [RBX + 0x128],R12 JMP 0x00189cfe LAB_00189d4e: MOV byte ptr [RBX + 0x33d],0x1 JMP 0x00189cfe
int8 rtree_find_next(long *param_1,ulong param_2) { int iVar1; int8 uVar2; int4 *puVar3; long lVar4; void *pvVar5; long lVar6; void *__src; if ((*(byte *)(param_1 + 0x3a) & 8) != 0) { uVar2 = rtree_find_first(param_1,param_2,param_1[0x21],(int)param_1[0x3b]); return uVar2; } lVar4 = *param_1; lVar6 = (param_2 & 0xffffffff) * 0x70 + *(long *)(lVar4 + 0x218); if ((*(char *)((long)param_1 + 0x33d) == '\0') && (__src = (void *)param_1[0x25], (void *)param_1[0x25] < (void *)param_1[0x26])) { do { iVar1 = rtree_key_cmp(*(int8 *)(lVar6 + 0x28),param_1[0x23],__src, *(int4 *)((long)param_1 + 0x1dc),0x400); pvVar5 = (void *)((ulong)*(ushort *)(lVar6 + 0x12) + (long)__src); if (iVar1 == 0) { lVar4 = _mi_dpos(param_1,0,pvVar5); param_1[0x2e] = lVar4; memcpy((void *)param_1[0x21],__src,(ulong)*(uint *)(param_1 + 0x3b)); if (pvVar5 < (void *)param_1[0x26]) { param_1[0x25] = (long)pvVar5; return 0; } *(int1 *)((long)param_1 + 0x33d) = 1; return 0; } __src = pvVar5; } while (pvVar5 < (void *)param_1[0x26]); lVar4 = *param_1; } lVar4 = *(long *)(*(long *)(lVar4 + 0x98) + (param_2 & 0xffffffff) * 8); if (lVar4 == -1) { puVar3 = (int4 *)_my_thread_var(); *puVar3 = 0x89; return 0xffffffff; } uVar2 = rtree_find_req(param_1,lVar6,lVar4,0); return uVar2; }
56,858
OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::initializePatches()
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/patchTreeBuilder.cpp
void PatchTreeBuilder::initializePatches() { // Keep track of the growing index of local points in irregular patches: int irregPointIndexBase = _patchTree->_numControlPoints + _patchTree->_numRefinedPoints; Far::PtexIndices ptexIndices(_faceRefiner); for (size_t i = 0; i < _patchFaces.size(); ++i) { PatchFace const & pf = _patchFaces[i]; PatchParam & patchParam = _patchTree->_patchParams[i]; Index * patchPoints = &_patchTree->_patchPoints[i * _patchTree->_patchPointStride]; if (pf.isRegular) { // Determine boundary mask before computing/assigning PatchParam: int boundaryMask = _patchBuilder->GetRegularPatchBoundaryMask(pf.level, pf.face); patchParam = _patchBuilder->ComputePatchParam(pf.level, pf.face, ptexIndices, true, boundaryMask, true); // Gather the points of the patch -- since they are assigned // directly into the PatchTree's buffer by the PatchBuilder // here, they must be offset as a post-process: _patchBuilder->GetRegularPatchPoints(pf.level, pf.face, boundaryMask, patchPoints); for (int j = 0; j < _patchTree->_regPatchSize; ++j) { patchPoints[j] += _levelOffsets[pf.level]; } } else { // Compute/assign the PatchParam for an irregular patch: patchParam = _patchBuilder->ComputePatchParam(pf.level, pf.face, ptexIndices, false /*irreg*/, 0 /*mask*/, false); // Assign indices of new/local points for this irregular patch: for (int j = 0; j < _patchTree->_irregPatchSize; ++j) { patchPoints[j] = irregPointIndexBase ++; } } } }
O1
cpp
OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::initializePatches(): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %rdi, %rbx movq (%rdi), %rax movl 0x1c(%rax), %ebp movl 0x20(%rax), %eax movl %eax, 0xc(%rsp) movq 0x8(%rdi), %rsi leaq 0x20(%rsp), %rdi callq 0x39ee0 movq 0x30(%rbx), %r15 cmpq %r15, 0x38(%rbx) je 0x8e190 movq %rbx, %r8 addl %ebp, 0xc(%rsp) xorl %r12d, %r12d xorl %r13d, %r13d movq (%r8), %rax movq 0x30(%rax), %r14 movq 0x48(%rax), %rbx movslq 0x14(%rax), %rax movq %rax, 0x10(%rsp) cmpw $0x0, 0x6(%r15,%r13,8) movswl 0x4(%r15,%r13,8), %esi movl (%r15,%r13,8), %edx je 0x8e113 movq %r12, 0x18(%rsp) movq 0x48(%r8), %rdi movl $0xffffffff, %ecx # imm = 0xFFFFFFFF movq %r8, %r12 callq 0x39d00 movl %eax, %ebp movq 0x48(%r12), %rdi movswl 0x4(%r15,%r13,8), %esi movl (%r15,%r13,8), %edx movl $0x1, (%rsp) leaq 0x20(%rsp), %rcx movl $0x1, %r8d movl %eax, %r9d callq 0x39b30 movq %r13, %rcx imulq 0x10(%rsp), %rcx leaq (%r14,%rcx,4), %r8 movq %rax, (%rbx,%r13,8) movq 0x48(%r12), %rdi movswl 0x4(%r15,%r13,8), %esi movl (%r15,%r13,8), %edx movl %ebp, %ecx movl $0xffffffff, %r9d # imm = 0xFFFFFFFF callq 0x39970 movq (%r12), %rax cmpl $0x0, 0xc(%rax) movq %r12, %r8 jle 0x8e16c movswq 0x4(%r15,%r13,8), %rcx movq 0x18(%r8), %rdx movq 0x10(%rsp), %rsi movq 0x18(%rsp), %r12 imulq %r12, %rsi addq %rsi, %r14 xorl %esi, %esi movl (%rdx,%rcx,4), %edi addl %edi, (%r14,%rsi,4) incq %rsi movslq 0xc(%rax), %rdi cmpq %rdi, %rsi jl 0x8e0fe jmp 0x8e171 movq 0x48(%r8), %rdi movl $0x0, (%rsp) leaq 0x20(%rsp), %rcx movq %r8, %r15 xorl %r8d, %r8d xorl %r9d, %r9d callq 0x39b30 movq %rax, (%rbx,%r13,8) movq (%r15), %rax cmpl $0x0, 0x10(%rax) movq %r15, %r8 jle 0x8e171 movq 0x10(%rsp), %rcx imulq %r12, %rcx addq %rcx, %r14 movl 0xc(%rsp), %ecx xorl %edx, %edx leal (%rcx,%rdx), %esi movl %esi, (%r14,%rdx,4) incq %rdx movslq 0x10(%rax), %rsi cmpq %rsi, %rdx jl 0x8e153 addl %edx, 0xc(%rsp) jmp 0x8e171 movq 0x18(%rsp), %r12 incq %r13 movq 0x30(%r8), %r15 movq 0x38(%r8), %rax subq %r15, %rax sarq $0x3, %rax addq $0x4, %r12 cmpq %rax, %r13 jb 0x8e037 leaq 0x20(%rsp), %rdi callq 0x38900 addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0x8e1ad jmp 0x8e1ad movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x38900 movq %rbx, %rdi callq 0x3bd70
_ZN10OpenSubdiv6v3_6_03Bfr16PatchTreeBuilder17initializePatchesEv: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov rbx, rdi mov rax, [rdi] mov ebp, [rax+1Ch] mov eax, [rax+20h] mov [rsp+68h+var_5C], eax mov rsi, [rdi+8]; OpenSubdiv::v3_6_0::Far::TopologyRefiner * lea rdi, [rsp+68h+var_48]; this call __ZN10OpenSubdiv6v3_6_03Far11PtexIndicesC2ERKNS1_15TopologyRefinerE; OpenSubdiv::v3_6_0::Far::PtexIndices::PtexIndices(OpenSubdiv::v3_6_0::Far::TopologyRefiner const&) mov r15, [rbx+30h] cmp [rbx+38h], r15 jz loc_8E190 mov r8, rbx add [rsp+68h+var_5C], ebp xor r12d, r12d xor r13d, r13d loc_8E037: mov rax, [r8] mov r14, [rax+30h] mov rbx, [rax+48h] movsxd rax, dword ptr [rax+14h] mov [rsp+68h+var_58], rax cmp word ptr [r15+r13*8+6], 0 movsx esi, word ptr [r15+r13*8+4]; int mov edx, [r15+r13*8]; int jz loc_8E113 mov [rsp+68h+var_50], r12 mov rdi, [r8+48h]; this mov ecx, 0FFFFFFFFh; int mov r12, r8 call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder27GetRegularPatchBoundaryMaskEiii; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetRegularPatchBoundaryMask(int,int,int) mov ebp, eax mov rdi, [r12+48h]; this movsx esi, word ptr [r15+r13*8+4]; int mov edx, [r15+r13*8]; int mov dword ptr [rsp+68h+var_68], 1; bool lea rcx, [rsp+68h+var_48]; OpenSubdiv::v3_6_0::Far::PtexIndices * mov r8d, 1; bool mov r9d, eax; int call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder17ComputePatchParamEiiRKNS1_11PtexIndicesEbib; OpenSubdiv::v3_6_0::Far::PatchBuilder::ComputePatchParam(int,int,OpenSubdiv::v3_6_0::Far::PtexIndices const&,bool,int,bool) mov rcx, r13 imul rcx, [rsp+68h+var_58] lea r8, [r14+rcx*4]; int * mov [rbx+r13*8], rax mov rdi, [r12+48h]; this movsx esi, word ptr [r15+r13*8+4]; int mov edx, [r15+r13*8]; int mov ecx, ebp; int mov r9d, 0FFFFFFFFh; int call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder21GetRegularPatchPointsEiiiPii; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetRegularPatchPoints(int,int,int,int *,int) mov rax, [r12] cmp dword ptr [rax+0Ch], 0 mov r8, r12 jle loc_8E16C movsx rcx, word ptr [r15+r13*8+4] mov rdx, [r8+18h] mov rsi, [rsp+68h+var_58] mov r12, [rsp+68h+var_50] imul rsi, r12 add r14, rsi xor esi, esi loc_8E0FE: mov edi, [rdx+rcx*4] add [r14+rsi*4], edi inc rsi movsxd rdi, dword ptr [rax+0Ch] cmp rsi, rdi jl short loc_8E0FE jmp short loc_8E171 loc_8E113: mov rdi, [r8+48h]; this mov dword ptr [rsp+68h+var_68], 0; bool lea rcx, [rsp+68h+var_48]; OpenSubdiv::v3_6_0::Far::PtexIndices * mov r15, r8 xor r8d, r8d; bool xor r9d, r9d; int call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder17ComputePatchParamEiiRKNS1_11PtexIndicesEbib; OpenSubdiv::v3_6_0::Far::PatchBuilder::ComputePatchParam(int,int,OpenSubdiv::v3_6_0::Far::PtexIndices const&,bool,int,bool) mov [rbx+r13*8], rax mov rax, [r15] cmp dword ptr [rax+10h], 0 mov r8, r15 jle short loc_8E171 mov rcx, [rsp+68h+var_58] imul rcx, r12 add r14, rcx mov ecx, [rsp+68h+var_5C] xor edx, edx loc_8E153: lea esi, [rcx+rdx] mov [r14+rdx*4], esi inc rdx movsxd rsi, dword ptr [rax+10h] cmp rdx, rsi jl short loc_8E153 add [rsp+68h+var_5C], edx jmp short loc_8E171 loc_8E16C: mov r12, [rsp+68h+var_50] loc_8E171: inc r13 mov r15, [r8+30h] mov rax, [r8+38h] sub rax, r15 sar rax, 3 add r12, 4 cmp r13, rax jb loc_8E037 loc_8E190: lea rdi, [rsp+68h+var_48]; this call __ZN10OpenSubdiv6v3_6_03Far11PtexIndicesD2Ev; OpenSubdiv::v3_6_0::Far::PtexIndices::~PtexIndices() add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short loc_8E1AD jmp short $+2 loc_8E1AD: mov rbx, rax lea rdi, [rsp+arg_18]; this call __ZN10OpenSubdiv6v3_6_03Far11PtexIndicesD2Ev; OpenSubdiv::v3_6_0::Far::PtexIndices::~PtexIndices() mov rdi, rbx call __Unwind_Resume
void OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::initializePatches( const OpenSubdiv::v3_6_0::Far::TopologyRefiner **this) { int v1; // ebp const OpenSubdiv::v3_6_0::Far::TopologyRefiner *v2; // r15 const OpenSubdiv::v3_6_0::Far::TopologyRefiner **v3; // r8 long long v4; // r12 unsigned long long v5; // r13 long long v6; // r14 long long v7; // rbx int v8; // esi int v9; // edx const OpenSubdiv::v3_6_0::Far::TopologyRefiner **v10; // r12 int RegularPatchBoundaryMask; // ebp const OpenSubdiv::v3_6_0::Far::TopologyRefiner *v12; // rax long long v13; // rcx const OpenSubdiv::v3_6_0::Far::TopologyRefiner *v14; // rdx long long v15; // r14 long long v16; // rsi const OpenSubdiv::v3_6_0::Far::TopologyRefiner **v17; // r15 const OpenSubdiv::v3_6_0::Far::TopologyRefiner *v18; // rax long long v19; // r14 long long v20; // rdx int v21; // [rsp+Ch] [rbp-5Ch] int v22; // [rsp+Ch] [rbp-5Ch] long long v23; // [rsp+10h] [rbp-58h] long long v24; // [rsp+18h] [rbp-50h] _BYTE v25[72]; // [rsp+20h] [rbp-48h] BYREF v1 = *((_DWORD *)*this + 7); v21 = *((_DWORD *)*this + 8); OpenSubdiv::v3_6_0::Far::PtexIndices::PtexIndices((OpenSubdiv::v3_6_0::Far::PtexIndices *)v25, this[1]); v2 = this[6]; if ( this[7] != v2 ) { v3 = this; v22 = v1 + v21; v4 = 0LL; v5 = 0LL; do { v6 = *((_QWORD *)*v3 + 6); v7 = *((_QWORD *)*v3 + 9); v23 = *((int *)*v3 + 5); v8 = *((__int16 *)v2 + 4 * v5 + 2); v9 = *((_DWORD *)v2 + 2 * v5); if ( *((_WORD *)v2 + 4 * v5 + 3) ) { v24 = v4; v10 = v3; RegularPatchBoundaryMask = OpenSubdiv::v3_6_0::Far::PatchBuilder::GetRegularPatchBoundaryMask(v3[9], v8, v9, -1); *(_QWORD *)(v7 + 8 * v5) = OpenSubdiv::v3_6_0::Far::PatchBuilder::ComputePatchParam( v10[9], *((__int16 *)v2 + 4 * v5 + 2), *((_DWORD *)v2 + 2 * v5), (const OpenSubdiv::v3_6_0::Far::PtexIndices *)v25, 1, RegularPatchBoundaryMask, 1); OpenSubdiv::v3_6_0::Far::PatchBuilder::GetRegularPatchPoints( v10[9], *((__int16 *)v2 + 4 * v5 + 2), *((_DWORD *)v2 + 2 * v5), RegularPatchBoundaryMask, (int *)(v6 + 4 * v23 * v5), -1); v12 = *v10; v3 = v10; if ( *((int *)*v10 + 3) <= 0 ) { v4 = v24; } else { v13 = *((__int16 *)v2 + 4 * v5 + 2); v14 = v10[3]; v4 = v24; v15 = v24 * v23 + v6; v16 = 0LL; do *(_DWORD *)(v15 + 4 * v16++) += *((_DWORD *)v14 + v13); while ( v16 < *((int *)v12 + 3) ); } } else { v17 = v3; *(_QWORD *)(v7 + 8 * v5) = OpenSubdiv::v3_6_0::Far::PatchBuilder::ComputePatchParam( v3[9], v8, v9, (const OpenSubdiv::v3_6_0::Far::PtexIndices *)v25, 0, 0, 0); v18 = *v17; v3 = v17; if ( *((int *)*v17 + 4) > 0 ) { v19 = v4 * v23 + v6; v20 = 0LL; do { *(_DWORD *)(v19 + 4 * v20) = v22 + v20; ++v20; } while ( v20 < *((int *)v18 + 4) ); v22 += v20; } } ++v5; v2 = v3[6]; v4 += 4LL; } while ( v5 < (v3[7] - v2) >> 3 ); } OpenSubdiv::v3_6_0::Far::PtexIndices::~PtexIndices((OpenSubdiv::v3_6_0::Far::PtexIndices *)v25); }
initializePatches: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV RBX,RDI MOV RAX,qword ptr [RDI] MOV EBP,dword ptr [RAX + 0x1c] MOV EAX,dword ptr [RAX + 0x20] MOV dword ptr [RSP + 0xc],EAX MOV RSI,qword ptr [RDI + 0x8] LEA RDI,[RSP + 0x20] CALL 0x00139ee0 MOV R15,qword ptr [RBX + 0x30] CMP qword ptr [RBX + 0x38],R15 JZ 0x0018e190 MOV R8,RBX ADD dword ptr [RSP + 0xc],EBP XOR R12D,R12D XOR R13D,R13D LAB_0018e037: MOV RAX,qword ptr [R8] MOV R14,qword ptr [RAX + 0x30] MOV RBX,qword ptr [RAX + 0x48] MOVSXD RAX,dword ptr [RAX + 0x14] MOV qword ptr [RSP + 0x10],RAX CMP word ptr [R15 + R13*0x8 + 0x6],0x0 MOVSX ESI,word ptr [R15 + R13*0x8 + 0x4] MOV EDX,dword ptr [R15 + R13*0x8] JZ 0x0018e113 MOV qword ptr [RSP + 0x18],R12 MOV RDI,qword ptr [R8 + 0x48] LAB_0018e06b: MOV ECX,0xffffffff MOV R12,R8 CALL 0x00139d00 MOV EBP,EAX MOV RDI,qword ptr [R12 + 0x48] MOVSX ESI,word ptr [R15 + R13*0x8 + 0x4] MOV EDX,dword ptr [R15 + R13*0x8] LAB_0018e089: MOV dword ptr [RSP],0x1 LEA RCX,[RSP + 0x20] MOV R8D,0x1 MOV R9D,EAX CALL 0x00139b30 MOV RCX,R13 IMUL RCX,qword ptr [RSP + 0x10] LEA R8,[R14 + RCX*0x4] MOV qword ptr [RBX + R13*0x8],RAX MOV RDI,qword ptr [R12 + 0x48] MOVSX ESI,word ptr [R15 + R13*0x8 + 0x4] MOV EDX,dword ptr [R15 + R13*0x8] LAB_0018e0c3: MOV ECX,EBP MOV R9D,0xffffffff CALL 0x00139970 MOV RAX,qword ptr [R12] CMP dword ptr [RAX + 0xc],0x0 MOV R8,R12 JLE 0x0018e16c MOVSX RCX,word ptr [R15 + R13*0x8 + 0x4] MOV RDX,qword ptr [R8 + 0x18] MOV RSI,qword ptr [RSP + 0x10] MOV R12,qword ptr [RSP + 0x18] IMUL RSI,R12 ADD R14,RSI XOR ESI,ESI LAB_0018e0fe: MOV EDI,dword ptr [RDX + RCX*0x4] ADD dword ptr [R14 + RSI*0x4],EDI INC RSI MOVSXD RDI,dword ptr [RAX + 0xc] CMP RSI,RDI JL 0x0018e0fe JMP 0x0018e171 LAB_0018e113: MOV RDI,qword ptr [R8 + 0x48] LAB_0018e117: MOV dword ptr [RSP],0x0 LEA RCX,[RSP + 0x20] MOV R15,R8 XOR R8D,R8D XOR R9D,R9D CALL 0x00139b30 LAB_0018e131: MOV qword ptr [RBX + R13*0x8],RAX MOV RAX,qword ptr [R15] CMP dword ptr [RAX + 0x10],0x0 MOV R8,R15 JLE 0x0018e171 MOV RCX,qword ptr [RSP + 0x10] IMUL RCX,R12 ADD R14,RCX MOV ECX,dword ptr [RSP + 0xc] XOR EDX,EDX LAB_0018e153: LEA ESI,[RCX + RDX*0x1] MOV dword ptr [R14 + RDX*0x4],ESI INC RDX MOVSXD RSI,dword ptr [RAX + 0x10] CMP RDX,RSI JL 0x0018e153 ADD dword ptr [RSP + 0xc],EDX JMP 0x0018e171 LAB_0018e16c: MOV R12,qword ptr [RSP + 0x18] LAB_0018e171: INC R13 MOV R15,qword ptr [R8 + 0x30] MOV RAX,qword ptr [R8 + 0x38] SUB RAX,R15 SAR RAX,0x3 ADD R12,0x4 CMP R13,RAX JC 0x0018e037 LAB_0018e190: LEA RDI,[RSP + 0x20] CALL 0x00138900 ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::initializePatches() */ void __thiscall OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::initializePatches(PatchTreeBuilder *this) { int *piVar1; short sVar2; long lVar3; int iVar4; long lVar5; int8 uVar6; long lVar7; int iVar8; long lVar9; long lVar10; ulong uVar11; long lVar12; int local_5c; PtexIndices local_48 [24]; iVar4 = *(int *)(*(long *)this + 0x1c); local_5c = *(int *)(*(long *)this + 0x20); Far::PtexIndices::PtexIndices(local_48,*(TopologyRefiner **)(this + 8)); lVar12 = *(long *)(this + 0x30); if (*(long *)(this + 0x38) != lVar12) { local_5c = local_5c + iVar4; lVar10 = 0; uVar11 = 0; do { lVar5 = *(long *)this; lVar3 = *(long *)(lVar5 + 0x30); lVar7 = *(long *)(lVar5 + 0x48); lVar5 = (long)*(int *)(lVar5 + 0x14); iVar8 = (int)*(short *)(lVar12 + 4 + uVar11 * 8); iVar4 = *(int *)(lVar12 + uVar11 * 8); if (*(short *)(lVar12 + 6 + uVar11 * 8) == 0) { /* try { // try from 0018e117 to 0018e130 has its CatchHandler @ 0018e1a9 */ uVar6 = Far::PatchBuilder::ComputePatchParam (*(PatchBuilder **)(this + 0x48),iVar8,iVar4,local_48,false,0,false); *(int8 *)(lVar7 + uVar11 * 8) = uVar6; lVar12 = *(long *)this; if (0 < *(int *)(lVar12 + 0x10)) { lVar7 = 0; do { *(int *)(lVar3 + lVar5 * lVar10 + lVar7 * 4) = local_5c + (int)lVar7; lVar7 = lVar7 + 1; } while (lVar7 < *(int *)(lVar12 + 0x10)); local_5c = local_5c + (int)lVar7; } } else { /* try { // try from 0018e06b to 0018e077 has its CatchHandler @ 0018e1ad */ iVar4 = Far::PatchBuilder::GetRegularPatchBoundaryMask (*(PatchBuilder **)(this + 0x48),iVar8,iVar4,-1); /* try { // try from 0018e089 to 0018e0a2 has its CatchHandler @ 0018e1ab */ uVar6 = Far::PatchBuilder::ComputePatchParam (*(PatchBuilder **)(this + 0x48),(int)*(short *)(lVar12 + 4 + uVar11 * 8), *(int *)(lVar12 + uVar11 * 8),local_48,true,iVar4,true); *(int8 *)(lVar7 + uVar11 * 8) = uVar6; /* try { // try from 0018e0c3 to 0018e0cf has its CatchHandler @ 0018e1ad */ Far::PatchBuilder::GetRegularPatchPoints (*(PatchBuilder **)(this + 0x48),(int)*(short *)(lVar12 + 4 + uVar11 * 8), *(int *)(lVar12 + uVar11 * 8),iVar4,(int *)(lVar3 + uVar11 * lVar5 * 4),-1); lVar7 = *(long *)this; if (0 < *(int *)(lVar7 + 0xc)) { sVar2 = *(short *)(lVar12 + 4 + uVar11 * 8); lVar12 = *(long *)(this + 0x18); lVar9 = 0; do { piVar1 = (int *)(lVar3 + lVar5 * lVar10 + lVar9 * 4); *piVar1 = *piVar1 + *(int *)(lVar12 + (long)sVar2 * 4); lVar9 = lVar9 + 1; } while (lVar9 < *(int *)(lVar7 + 0xc)); } } uVar11 = uVar11 + 1; lVar12 = *(long *)(this + 0x30); lVar10 = lVar10 + 4; } while (uVar11 < (ulong)(*(long *)(this + 0x38) - lVar12 >> 3)); } Far::PtexIndices::~PtexIndices(local_48); return; }
56,859
my_string_metadata_get
eloqsql/strings/ctype.c
void my_string_metadata_get(MY_STRING_METADATA *metadata, CHARSET_INFO *cs, const char *str, size_t length) { if (cs->mbmaxlen == 1 && !(cs->state & MY_CS_NONASCII)) { metadata->char_length= length; metadata->repertoire= my_string_repertoire_8bit(cs, str, (ulong)length); } else { my_string_metadata_get_mb(metadata, cs, str, (ulong)length); } }
O3
c
my_string_metadata_get: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rcx, %r14 movq %rdx, %r15 movq %rsi, %r12 movq %rdi, %rbx cmpl $0x1, 0x9c(%rsi) jne 0x358d5 testb $0x20, 0xd(%r12) jne 0x358d5 movq %r14, (%rbx) movl $0x3, %eax testq %r14, %r14 je 0x358b5 movl $0x2000, %ecx # imm = 0x2000 andl 0xc(%r12), %ecx jne 0x358d0 testq %r14, %r14 jle 0x358cb addq %r15, %r14 cmpb $0x0, (%r15) js 0x358d0 incq %r15 cmpq %r14, %r15 jb 0x358bd movl $0x1, %eax movl %eax, 0x8(%rbx) jmp 0x3593f movl $0x1, 0x8(%rbx) movq $0x0, (%rbx) testq %r14, %r14 jle 0x3593f addq %r15, %r14 leaq -0x30(%rbp), %r13 movq 0xb8(%r12), %rax movq %r12, %rdi movq %r13, %rsi movq %r15, %rdx movq %r14, %rcx callq *0x28(%rax) testl %eax, %eax jle 0x3591a cmpq $0x80, -0x30(%rbp) jb 0x35932 orb $0x2, 0x8(%rbx) jmp 0x35932 je 0x35929 orb $0x2, 0x8(%rbx) cmpl $-0x64, %eax jb 0x3593f negl %eax jmp 0x35932 orb $0x2, 0x8(%rbx) movl $0x1, %eax movl %eax, %eax addq %rax, %r15 incq (%rbx) cmpq %r14, %r15 jb 0x358ef addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_string_metadata_get: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r14, rcx mov r15, rdx mov r12, rsi mov rbx, rdi cmp dword ptr [rsi+9Ch], 1 jnz short loc_358D5 test byte ptr [r12+0Dh], 20h jnz short loc_358D5 mov [rbx], r14 mov eax, 3 test r14, r14 jz short loc_358B5 mov ecx, 2000h and ecx, [r12+0Ch] jnz short loc_358D0 loc_358B5: test r14, r14 jle short loc_358CB add r14, r15 loc_358BD: cmp byte ptr [r15], 0 js short loc_358D0 inc r15 cmp r15, r14 jb short loc_358BD loc_358CB: mov eax, 1 loc_358D0: mov [rbx+8], eax jmp short loc_3593F loc_358D5: mov dword ptr [rbx+8], 1 mov qword ptr [rbx], 0 test r14, r14 jle short loc_3593F add r14, r15 lea r13, [rbp+var_30] loc_358EF: mov rax, [r12+0B8h] mov rdi, r12 mov rsi, r13 mov rdx, r15 mov rcx, r14 call qword ptr [rax+28h] test eax, eax jle short loc_3591A cmp [rbp+var_30], 80h jb short loc_35932 or byte ptr [rbx+8], 2 jmp short loc_35932 loc_3591A: jz short loc_35929 or byte ptr [rbx+8], 2 cmp eax, 0FFFFFF9Ch jb short loc_3593F neg eax jmp short loc_35932 loc_35929: or byte ptr [rbx+8], 2 mov eax, 1 loc_35932: mov eax, eax add r15, rax inc qword ptr [rbx] cmp r15, r14 jb short loc_358EF loc_3593F: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_string_metadata_get(long long a1, long long a2, char *a3, long long a4) { long long result; // rax char *v5; // r15 unsigned long long v6; // r14 unsigned long long v7[6]; // [rsp+0h] [rbp-30h] BYREF v7[0] = result; v5 = a3; if ( *(_DWORD *)(a2 + 156) != 1 || (*(_BYTE *)(a2 + 13) & 0x20) != 0 ) { *(_DWORD *)(a1 + 8) = 1; *(_QWORD *)a1 = 0LL; if ( a4 > 0 ) { v6 = (unsigned long long)&a3[a4]; do { result = (*(long long ( **)(long long, unsigned long long *, char *, unsigned long long))(*(_QWORD *)(a2 + 184) + 40LL))( a2, v7, v5, v6); if ( (int)result <= 0 ) { if ( (_DWORD)result ) { *(_BYTE *)(a1 + 8) |= 2u; if ( (unsigned int)result < 0xFFFFFF9C ) return result; LODWORD(result) = -(int)result; } else { *(_BYTE *)(a1 + 8) |= 2u; LODWORD(result) = 1; } } else if ( v7[0] >= 0x80 ) { *(_BYTE *)(a1 + 8) |= 2u; } result = (unsigned int)result; v5 += (unsigned int)result; ++*(_QWORD *)a1; } while ( (unsigned long long)v5 < v6 ); } } else { *(_QWORD *)a1 = a4; result = 3LL; if ( !a4 || (*(_DWORD *)(a2 + 12) & 0x2000) == 0 ) { if ( a4 <= 0 ) { LABEL_8: result = 1LL; } else { while ( *v5 >= 0 ) { if ( ++v5 >= &a3[a4] ) goto LABEL_8; } } } *(_DWORD *)(a1 + 8) = result; } return result; }
my_string_metadata_get: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,RCX MOV R15,RDX MOV R12,RSI MOV RBX,RDI CMP dword ptr [RSI + 0x9c],0x1 JNZ 0x001358d5 TEST byte ptr [R12 + 0xd],0x20 JNZ 0x001358d5 MOV qword ptr [RBX],R14 MOV EAX,0x3 TEST R14,R14 JZ 0x001358b5 MOV ECX,0x2000 AND ECX,dword ptr [R12 + 0xc] JNZ 0x001358d0 LAB_001358b5: TEST R14,R14 JLE 0x001358cb ADD R14,R15 LAB_001358bd: CMP byte ptr [R15],0x0 JS 0x001358d0 INC R15 CMP R15,R14 JC 0x001358bd LAB_001358cb: MOV EAX,0x1 LAB_001358d0: MOV dword ptr [RBX + 0x8],EAX JMP 0x0013593f LAB_001358d5: MOV dword ptr [RBX + 0x8],0x1 MOV qword ptr [RBX],0x0 TEST R14,R14 JLE 0x0013593f ADD R14,R15 LEA R13,[RBP + -0x30] LAB_001358ef: MOV RAX,qword ptr [R12 + 0xb8] MOV RDI,R12 MOV RSI,R13 MOV RDX,R15 MOV RCX,R14 CALL qword ptr [RAX + 0x28] TEST EAX,EAX JLE 0x0013591a CMP qword ptr [RBP + -0x30],0x80 JC 0x00135932 OR byte ptr [RBX + 0x8],0x2 JMP 0x00135932 LAB_0013591a: JZ 0x00135929 OR byte ptr [RBX + 0x8],0x2 CMP EAX,-0x64 JC 0x0013593f NEG EAX JMP 0x00135932 LAB_00135929: OR byte ptr [RBX + 0x8],0x2 MOV EAX,0x1 LAB_00135932: MOV EAX,EAX ADD R15,RAX INC qword ptr [RBX] CMP R15,R14 JC 0x001358ef LAB_0013593f: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void my_string_metadata_get(long *param_1,long param_2,char *param_3,long param_4) { int4 uVar1; uint uVar2; ulong in_RAX; char *pcVar3; ulong local_38; if ((*(int *)(param_2 + 0x9c) == 1) && ((*(byte *)(param_2 + 0xd) & 0x20) == 0)) { *param_1 = param_4; uVar1 = 3; if ((param_4 == 0) || ((*(uint *)(param_2 + 0xc) & 0x2000) == 0)) { if (0 < param_4) { pcVar3 = param_3 + param_4; do { if (*param_3 < '\0') goto LAB_001358d0; param_3 = param_3 + 1; } while (param_3 < pcVar3); } uVar1 = 1; } LAB_001358d0: *(int4 *)(param_1 + 1) = uVar1; } else { *(int4 *)(param_1 + 1) = 1; *param_1 = 0; if (0 < param_4) { pcVar3 = param_3 + param_4; local_38 = in_RAX; do { uVar2 = (**(code **)(*(long *)(param_2 + 0xb8) + 0x28))(param_2,&local_38,param_3,pcVar3); if ((int)uVar2 < 1) { if (uVar2 == 0) { *(byte *)(param_1 + 1) = *(byte *)(param_1 + 1) | 2; uVar2 = 1; } else { *(byte *)(param_1 + 1) = *(byte *)(param_1 + 1) | 2; if (uVar2 < 0xffffff9c) { return; } uVar2 = -uVar2; } } else if (0x7f < local_38) { *(byte *)(param_1 + 1) = *(byte *)(param_1 + 1) | 2; } param_3 = param_3 + uVar2; *param_1 = *param_1 + 1; } while (param_3 < pcVar3); } } return; }
56,860
google::protobuf::compiler::cpp::RepeatedEnumFieldGenerator::GenerateSwappingCode(google::protobuf::io::Printer*) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/cpp/enum_field.cc
void RepeatedEnumFieldGenerator::GenerateSwappingCode( io::Printer* printer) const { Formatter format(printer, variables_); format("$field$.InternalSwap(&other->$field$);\n"); }
O3
cpp
google::protobuf::compiler::cpp::RepeatedEnumFieldGenerator::GenerateSwappingCode(google::protobuf::io::Printer*) const: pushq %r14 pushq %rbx subq $0x38, %rsp leaq 0x18(%rdi), %rax leaq 0x8(%rsp), %rbx movq %rsi, -0x8(%rbx) movq %rbx, %rdi movq %rax, %rsi callq 0x7e61e leaq 0xd581b(%rip), %rsi # 0x1c8535 movq %rsp, %rdi callq 0x39938 movq %rbx, %rdi callq 0x2e5e0 addq $0x38, %rsp popq %rbx popq %r14 retq movq %rax, %r14 movq %rbx, %rdi callq 0x2e5e0 movq %r14, %rdi callq 0x1f860 nop
_ZNK6google8protobuf8compiler3cpp26RepeatedEnumFieldGenerator20GenerateSwappingCodeEPNS0_2io7PrinterE: push r14 push rbx sub rsp, 38h lea rax, [rdi+18h] lea rbx, [rsp+48h+var_40] mov [rbx-8], rsi mov rdi, rbx mov rsi, rax call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_S5_ESt10_Select1stIS8_ESt4lessIS5_ESaIS8_EEC2ERKSE_; std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::_Rb_tree(std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>> const&) lea rsi, aFieldInternals; "$field$.InternalSwap(&other->$field$);"... mov rdi, rsp call _ZNK6google8protobuf8compiler3cpp9FormatterclIJEEEvPKcDpRKT_ mov rdi, rbx call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_S5_ESt10_Select1stIS8_ESt4lessIS5_ESaIS8_EED2Ev; std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::~_Rb_tree() add rsp, 38h pop rbx pop r14 retn mov r14, rax mov rdi, rbx call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_S5_ESt10_Select1stIS8_ESt4lessIS5_ESaIS8_EED2Ev; std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::~_Rb_tree() mov rdi, r14 call __Unwind_Resume
long long google::protobuf::compiler::cpp::RepeatedEnumFieldGenerator::GenerateSwappingCode( google::protobuf::compiler::cpp::RepeatedEnumFieldGenerator *this, google::protobuf::io::Printer *a2) { long long result; // rax google::protobuf::io::Printer *v3; // [rsp+0h] [rbp-48h] BYREF _BYTE v4[64]; // [rsp+8h] [rbp-40h] BYREF v3 = a2; std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::_Rb_tree( (long long)v4, (long long)this + 24); result = google::protobuf::compiler::cpp::Formatter::operator()<>(&v3, "$field$.InternalSwap(&other->$field$);\n"); std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::~_Rb_tree((long long)v4); return result; }
GenerateSwappingCode: PUSH R14 PUSH RBX SUB RSP,0x38 LEA RAX,[RDI + 0x18] LEA RBX,[RSP + 0x8] MOV qword ptr [RBX + -0x8],RSI MOV RDI,RBX MOV RSI,RAX CALL 0x0017e61e LAB_001f2d13: LEA RSI,[0x2c8535] MOV RDI,RSP CALL 0x00139938 LAB_001f2d22: MOV RDI,RBX CALL 0x0012e5e0 ADD RSP,0x38 POP RBX POP R14 RET
/* google::protobuf::compiler::cpp::RepeatedEnumFieldGenerator::GenerateSwappingCode(google::protobuf::io::Printer*) const */ void __thiscall google::protobuf::compiler::cpp::RepeatedEnumFieldGenerator::GenerateSwappingCode (RepeatedEnumFieldGenerator *this,Printer *param_1) { Printer *local_48; _Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>> local_40 [48]; local_48 = param_1; std:: _Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>> ::_Rb_tree(local_40,(_Rb_tree *)(this + 0x18)); /* try { // try from 001f2d13 to 001f2d21 has its CatchHandler @ 001f2d32 */ Formatter::operator()<>((Formatter *)&local_48,"$field$.InternalSwap(&other->$field$);\n"); std:: _Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>> ::~_Rb_tree(local_40); return; }
56,861
destroy_socket(PFS_socket*)
eloqsql/storage/perfschema/pfs_instr.cc
void destroy_socket(PFS_socket *pfs) { assert(pfs != NULL); PFS_socket_class *klass= pfs->m_class; /* Aggregate to SOCKET_SUMMARY_BY_EVENT_NAME */ klass->m_socket_stat.m_io_stat.aggregate(&pfs->m_socket_stat.m_io_stat); if (klass->is_singleton()) klass->m_singleton= NULL; /* Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME */ PFS_thread *thread= pfs->m_thread_owner; if (thread != NULL) { /* Combine stats for all operations */ PFS_single_stat stat; pfs->m_socket_stat.m_io_stat.sum_waits(&stat); if (stat.m_count != 0) { PFS_single_stat *event_name_array; event_name_array= thread->write_instr_class_waits_stats(); uint index= pfs->m_class->m_event_name_index; event_name_array[index].aggregate(&stat); } } pfs->m_socket_stat.reset(); pfs->m_thread_owner= NULL; pfs->m_fd= 0; pfs->m_addr_len= 0; global_socket_container.deallocate(pfs); }
O3
cpp
destroy_socket(PFS_socket*): pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rdi, %rbx movq 0xb0(%rdi), %rax movq 0xb8(%rdi), %rcx testq %rcx, %rcx je 0x370ca addq %rcx, 0xa0(%rax) movq 0xc0(%rbx), %rcx addq %rcx, 0xa8(%rax) movq 0xc8(%rbx), %rcx cmpq %rcx, 0xb0(%rax) ja 0x3731c movq 0xd0(%rbx), %rcx cmpq %rcx, 0xb8(%rax) jb 0x37328 movq 0xd8(%rbx), %rcx addq %rcx, 0xc0(%rax) movq 0xe0(%rbx), %rcx testq %rcx, %rcx je 0x37121 addq %rcx, 0xc8(%rax) movq 0xe8(%rbx), %rcx addq %rcx, 0xd0(%rax) movq 0xf0(%rbx), %rcx cmpq %rcx, 0xd8(%rax) ja 0x37334 movq 0xf8(%rbx), %rcx cmpq %rcx, 0xe0(%rax) jb 0x37340 movq 0x100(%rbx), %rcx addq %rcx, 0xe8(%rax) movq 0x108(%rbx), %rcx testq %rcx, %rcx je 0x37178 addq %rcx, 0xf0(%rax) movq 0x110(%rbx), %rcx addq %rcx, 0xf8(%rax) movq 0x118(%rbx), %rcx cmpq %rcx, 0x100(%rax) ja 0x3734c movq 0x120(%rbx), %rcx cmpq %rcx, 0x108(%rax) jb 0x37358 movq 0x128(%rbx), %rcx addq %rcx, 0x110(%rax) testb $0x1, 0x8(%rax) je 0x37189 movq $0x0, 0x118(%rax) leaq 0xb8(%rbx), %rdi movq 0x18(%rbx), %r14 testq %r14, %r14 je 0x3729e movq (%rdi), %rcx testq %rcx, %rcx je 0x371c3 movq 0xc0(%rbx), %r13 movq 0xc8(%rbx), %r8 movq 0xd0(%rbx), %rdx testq %rdx, %rdx jne 0x371cf xorl %edx, %edx jmp 0x371cf movq $-0x1, %r8 xorl %edx, %edx xorl %r13d, %r13d movq 0xe0(%rbx), %rax testq %rax, %rax je 0x37203 movq 0xf0(%rbx), %rsi cmpq %rsi, %r8 ja 0x37364 addq %rcx, %rax addq 0xe8(%rbx), %r13 movq 0xf8(%rbx), %rcx cmpq %rcx, %rdx jae 0x37206 jmp 0x37209 movq %rcx, %rax movq %rdx, %rcx movq 0x108(%rbx), %r12 testq %r12, %r12 je 0x3723d movq 0x118(%rbx), %rdx cmpq %rdx, %r8 ja 0x3736c addq %rax, %r12 addq 0x110(%rbx), %r13 movq 0x120(%rbx), %r15 cmpq %r15, %rcx jae 0x37240 jmp 0x37243 movq %rax, %r12 movq %rcx, %r15 testq %r12, %r12 je 0x3729e cmpb $0x0, (%r14) jne 0x3726a movq %rdi, -0x38(%rbp) movq %r14, %rdi movq %r8, -0x30(%rbp) callq 0x46378 movq -0x30(%rbp), %r8 movq -0x38(%rbp), %rdi movb $0x1, (%r14) movq 0x8(%r14), %rcx movq 0xb0(%rbx), %rax movl 0x10(%rax), %edx shlq $0x5, %rdx addq %r12, (%rcx,%rdx) addq %r13, 0x8(%rcx,%rdx) leaq (%rcx,%rdx), %rax cmpq %r8, 0x10(%rcx,%rdx) ja 0x37374 cmpq %r15, 0x18(%rax) jb 0x3737d xorps %xmm0, %xmm0 movups %xmm0, (%rdi) movq $-0x1, %rax movq %rax, 0xc8(%rbx) movups %xmm0, 0xd0(%rbx) movups %xmm0, 0xe0(%rbx) movq %rax, 0xf0(%rbx) movups %xmm0, 0xf8(%rbx) movups %xmm0, 0x108(%rbx) movq %rax, 0x118(%rbx) movups %xmm0, 0x120(%rbx) movq $0x0, 0x18(%rbx) xorl %eax, %eax movl %eax, 0x20(%rbx) movl %eax, 0xa8(%rbx) movq 0x8(%rbx), %rcx movl (%rbx), %edx andl $-0x4, %edx xchgl %edx, (%rbx) movb %al, (%rcx) leaq 0x366b0e(%rip), %rcx # 0x39de18 movb %al, 0x9(%rcx) addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rcx, 0xb0(%rax) jmp 0x370a8 movq %rcx, 0xb8(%rax) jmp 0x370bc movq %rcx, 0xd8(%rax) jmp 0x370ff movq %rcx, 0xe0(%rax) jmp 0x37113 movq %rcx, 0x100(%rax) jmp 0x37156 movq %rcx, 0x108(%rax) jmp 0x3716a movq %rsi, %r8 jmp 0x371eb movq %rdx, %r8 jmp 0x37225 movq %r8, 0x10(%rax) jmp 0x37294 movq %r15, 0x18(%rax) jmp 0x3729e
_Z14destroy_socketP10PFS_socket: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov rbx, rdi mov rax, [rdi+0B0h] mov rcx, [rdi+0B8h] test rcx, rcx jz short loc_370CA add [rax+0A0h], rcx mov rcx, [rbx+0C0h] add [rax+0A8h], rcx mov rcx, [rbx+0C8h] cmp [rax+0B0h], rcx ja loc_3731C loc_370A8: mov rcx, [rbx+0D0h] cmp [rax+0B8h], rcx jb loc_37328 loc_370BC: mov rcx, [rbx+0D8h] add [rax+0C0h], rcx loc_370CA: mov rcx, [rbx+0E0h] test rcx, rcx jz short loc_37121 add [rax+0C8h], rcx mov rcx, [rbx+0E8h] add [rax+0D0h], rcx mov rcx, [rbx+0F0h] cmp [rax+0D8h], rcx ja loc_37334 loc_370FF: mov rcx, [rbx+0F8h] cmp [rax+0E0h], rcx jb loc_37340 loc_37113: mov rcx, [rbx+100h] add [rax+0E8h], rcx loc_37121: mov rcx, [rbx+108h] test rcx, rcx jz short loc_37178 add [rax+0F0h], rcx mov rcx, [rbx+110h] add [rax+0F8h], rcx mov rcx, [rbx+118h] cmp [rax+100h], rcx ja loc_3734C loc_37156: mov rcx, [rbx+120h] cmp [rax+108h], rcx jb loc_37358 loc_3716A: mov rcx, [rbx+128h] add [rax+110h], rcx loc_37178: test byte ptr [rax+8], 1 jz short loc_37189 mov qword ptr [rax+118h], 0 loc_37189: lea rdi, [rbx+0B8h] mov r14, [rbx+18h] test r14, r14 jz loc_3729E mov rcx, [rdi] test rcx, rcx jz short loc_371C3 mov r13, [rbx+0C0h] mov r8, [rbx+0C8h] mov rdx, [rbx+0D0h] test rdx, rdx jnz short loc_371CF xor edx, edx jmp short loc_371CF loc_371C3: mov r8, 0FFFFFFFFFFFFFFFFh xor edx, edx xor r13d, r13d loc_371CF: mov rax, [rbx+0E0h] test rax, rax jz short loc_37203 mov rsi, [rbx+0F0h] cmp r8, rsi ja loc_37364 loc_371EB: add rax, rcx add r13, [rbx+0E8h] mov rcx, [rbx+0F8h] cmp rdx, rcx jnb short loc_37206 jmp short loc_37209 loc_37203: mov rax, rcx loc_37206: mov rcx, rdx loc_37209: mov r12, [rbx+108h] test r12, r12 jz short loc_3723D mov rdx, [rbx+118h] cmp r8, rdx ja loc_3736C loc_37225: add r12, rax add r13, [rbx+110h] mov r15, [rbx+120h] cmp rcx, r15 jnb short loc_37240 jmp short loc_37243 loc_3723D: mov r12, rax loc_37240: mov r15, rcx loc_37243: test r12, r12 jz short loc_3729E cmp byte ptr [r14], 0 jnz short loc_3726A mov [rbp+var_38], rdi mov rdi, r14; this mov [rbp+var_30], r8 call _ZN20PFS_connection_slice17reset_waits_statsEv; PFS_connection_slice::reset_waits_stats(void) mov r8, [rbp+var_30] mov rdi, [rbp+var_38] mov byte ptr [r14], 1 loc_3726A: mov rcx, [r14+8] mov rax, [rbx+0B0h] mov edx, [rax+10h] shl rdx, 5 add [rcx+rdx], r12 add [rcx+rdx+8], r13 lea rax, [rcx+rdx] cmp [rcx+rdx+10h], r8 ja loc_37374 loc_37294: cmp [rax+18h], r15 jb loc_3737D loc_3729E: xorps xmm0, xmm0 movups xmmword ptr [rdi], xmm0 mov rax, 0FFFFFFFFFFFFFFFFh mov [rbx+0C8h], rax movups xmmword ptr [rbx+0D0h], xmm0 movups xmmword ptr [rbx+0E0h], xmm0 mov [rbx+0F0h], rax movups xmmword ptr [rbx+0F8h], xmm0 movups xmmword ptr [rbx+108h], xmm0 mov [rbx+118h], rax movups xmmword ptr [rbx+120h], xmm0 mov qword ptr [rbx+18h], 0 xor eax, eax mov [rbx+20h], eax mov [rbx+0A8h], eax mov rcx, [rbx+8] mov edx, [rbx] and edx, 0FFFFFFFCh xchg edx, [rbx] mov [rcx], al lea rcx, global_socket_container mov [rcx+9], al add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_3731C: mov [rax+0B0h], rcx jmp loc_370A8 loc_37328: mov [rax+0B8h], rcx jmp loc_370BC loc_37334: mov [rax+0D8h], rcx jmp loc_370FF loc_37340: mov [rax+0E0h], rcx jmp loc_37113 loc_3734C: mov [rax+100h], rcx jmp loc_37156 loc_37358: mov [rax+108h], rcx jmp loc_3716A loc_37364: mov r8, rsi jmp loc_371EB loc_3736C: mov r8, rdx jmp loc_37225 loc_37374: mov [rax+10h], r8 jmp loc_37294 loc_3737D: mov [rax+18h], r15 jmp loc_3729E
long long destroy_socket(long long a1) { long long v2; // rax long long v3; // rcx unsigned long long v4; // rcx unsigned long long v5; // rcx long long v6; // rcx unsigned long long v7; // rcx unsigned long long v8; // rcx long long v9; // rcx unsigned long long v10; // rcx unsigned long long v11; // rcx long long *v12; // rdi PFS_connection_slice *v13; // r14 long long v14; // r13 unsigned long long v15; // r8 unsigned long long v16; // rdx long long v17; // rax long long v18; // rax unsigned long long v19; // rcx long long v20; // r12 long long v21; // r12 unsigned long long v22; // r15 long long v23; // rcx long long v24; // rdx long long v25; // rax long long result; // rax _BYTE *v27; // rcx unsigned long long v28; // [rsp+10h] [rbp-30h] v2 = *(_QWORD *)(a1 + 176); v3 = *(_QWORD *)(a1 + 184); if ( v3 ) { *(_QWORD *)(v2 + 160) += v3; *(_QWORD *)(v2 + 168) += *(_QWORD *)(a1 + 192); v4 = *(_QWORD *)(a1 + 200); if ( *(_QWORD *)(v2 + 176) > v4 ) *(_QWORD *)(v2 + 176) = v4; v5 = *(_QWORD *)(a1 + 208); if ( *(_QWORD *)(v2 + 184) < v5 ) *(_QWORD *)(v2 + 184) = v5; *(_QWORD *)(v2 + 192) += *(_QWORD *)(a1 + 216); } v6 = *(_QWORD *)(a1 + 224); if ( v6 ) { *(_QWORD *)(v2 + 200) += v6; *(_QWORD *)(v2 + 208) += *(_QWORD *)(a1 + 232); v7 = *(_QWORD *)(a1 + 240); if ( *(_QWORD *)(v2 + 216) > v7 ) *(_QWORD *)(v2 + 216) = v7; v8 = *(_QWORD *)(a1 + 248); if ( *(_QWORD *)(v2 + 224) < v8 ) *(_QWORD *)(v2 + 224) = v8; *(_QWORD *)(v2 + 232) += *(_QWORD *)(a1 + 256); } v9 = *(_QWORD *)(a1 + 264); if ( v9 ) { *(_QWORD *)(v2 + 240) += v9; *(_QWORD *)(v2 + 248) += *(_QWORD *)(a1 + 272); v10 = *(_QWORD *)(a1 + 280); if ( *(_QWORD *)(v2 + 256) > v10 ) *(_QWORD *)(v2 + 256) = v10; v11 = *(_QWORD *)(a1 + 288); if ( *(_QWORD *)(v2 + 264) < v11 ) *(_QWORD *)(v2 + 264) = v11; *(_QWORD *)(v2 + 272) += *(_QWORD *)(a1 + 296); } if ( (*(_BYTE *)(v2 + 8) & 1) != 0 ) *(_QWORD *)(v2 + 280) = 0LL; v12 = (long long *)(a1 + 184); v13 = *(PFS_connection_slice **)(a1 + 24); if ( v13 ) { if ( *v12 ) { v14 = *(_QWORD *)(a1 + 192); v15 = *(_QWORD *)(a1 + 200); v16 = *(_QWORD *)(a1 + 208); if ( !v16 ) v16 = 0LL; } else { v15 = -1LL; v16 = 0LL; v14 = 0LL; } v17 = *(_QWORD *)(a1 + 224); if ( v17 ) { if ( v15 > *(_QWORD *)(a1 + 240) ) v15 = *(_QWORD *)(a1 + 240); v18 = *v12 + v17; v14 += *(_QWORD *)(a1 + 232); v19 = *(_QWORD *)(a1 + 248); if ( v16 < v19 ) { LABEL_33: v20 = *(_QWORD *)(a1 + 264); if ( v20 ) { if ( v15 > *(_QWORD *)(a1 + 280) ) v15 = *(_QWORD *)(a1 + 280); v21 = v18 + v20; v14 += *(_QWORD *)(a1 + 272); v22 = *(_QWORD *)(a1 + 288); if ( v19 < v22 ) goto LABEL_40; } else { v21 = v18; } v22 = v19; LABEL_40: if ( v21 ) { if ( !*(_BYTE *)v13 ) { v28 = v15; PFS_connection_slice::reset_waits_stats(v13); v15 = v28; v12 = (long long *)(a1 + 184); *(_BYTE *)v13 = 1; } v23 = *((_QWORD *)v13 + 1); v24 = 32LL * *(unsigned int *)(*(_QWORD *)(a1 + 176) + 16LL); *(_QWORD *)(v23 + v24) += v21; *(_QWORD *)(v23 + v24 + 8) += v14; v25 = v23 + v24; if ( *(_QWORD *)(v23 + v24 + 16) > v15 ) *(_QWORD *)(v25 + 16) = v15; if ( *(_QWORD *)(v25 + 24) < v22 ) *(_QWORD *)(v25 + 24) = v22; } goto LABEL_47; } } else { v18 = *v12; } v19 = v16; goto LABEL_33; } LABEL_47: *(_OWORD *)v12 = 0LL; *(_QWORD *)(a1 + 200) = -1LL; *(_OWORD *)(a1 + 208) = 0LL; *(_OWORD *)(a1 + 224) = 0LL; *(_QWORD *)(a1 + 240) = -1LL; *(_OWORD *)(a1 + 248) = 0LL; *(_OWORD *)(a1 + 264) = 0LL; *(_QWORD *)(a1 + 280) = -1LL; *(_OWORD *)(a1 + 288) = 0LL; *(_QWORD *)(a1 + 24) = 0LL; result = 0LL; *(_DWORD *)(a1 + 32) = 0; *(_DWORD *)(a1 + 168) = 0; v27 = *(_BYTE **)(a1 + 8); _InterlockedExchange((volatile __int32 *)a1, *(_DWORD *)a1 & 0xFFFFFFFC); *v27 = 0; BYTE1(global_socket_container[1]) = 0; return result; }
destroy_socket: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV RBX,RDI MOV RAX,qword ptr [RDI + 0xb0] MOV RCX,qword ptr [RDI + 0xb8] TEST RCX,RCX JZ 0x001370ca ADD qword ptr [RAX + 0xa0],RCX MOV RCX,qword ptr [RBX + 0xc0] ADD qword ptr [RAX + 0xa8],RCX MOV RCX,qword ptr [RBX + 0xc8] CMP qword ptr [RAX + 0xb0],RCX JA 0x0013731c LAB_001370a8: MOV RCX,qword ptr [RBX + 0xd0] CMP qword ptr [RAX + 0xb8],RCX JC 0x00137328 LAB_001370bc: MOV RCX,qword ptr [RBX + 0xd8] ADD qword ptr [RAX + 0xc0],RCX LAB_001370ca: MOV RCX,qword ptr [RBX + 0xe0] TEST RCX,RCX JZ 0x00137121 ADD qword ptr [RAX + 0xc8],RCX MOV RCX,qword ptr [RBX + 0xe8] ADD qword ptr [RAX + 0xd0],RCX MOV RCX,qword ptr [RBX + 0xf0] CMP qword ptr [RAX + 0xd8],RCX JA 0x00137334 LAB_001370ff: MOV RCX,qword ptr [RBX + 0xf8] CMP qword ptr [RAX + 0xe0],RCX JC 0x00137340 LAB_00137113: MOV RCX,qword ptr [RBX + 0x100] ADD qword ptr [RAX + 0xe8],RCX LAB_00137121: MOV RCX,qword ptr [RBX + 0x108] TEST RCX,RCX JZ 0x00137178 ADD qword ptr [RAX + 0xf0],RCX MOV RCX,qword ptr [RBX + 0x110] ADD qword ptr [RAX + 0xf8],RCX MOV RCX,qword ptr [RBX + 0x118] CMP qword ptr [RAX + 0x100],RCX JA 0x0013734c LAB_00137156: MOV RCX,qword ptr [RBX + 0x120] CMP qword ptr [RAX + 0x108],RCX JC 0x00137358 LAB_0013716a: MOV RCX,qword ptr [RBX + 0x128] ADD qword ptr [RAX + 0x110],RCX LAB_00137178: TEST byte ptr [RAX + 0x8],0x1 JZ 0x00137189 MOV qword ptr [RAX + 0x118],0x0 LAB_00137189: LEA RDI,[RBX + 0xb8] MOV R14,qword ptr [RBX + 0x18] TEST R14,R14 JZ 0x0013729e MOV RCX,qword ptr [RDI] TEST RCX,RCX JZ 0x001371c3 MOV R13,qword ptr [RBX + 0xc0] MOV R8,qword ptr [RBX + 0xc8] MOV RDX,qword ptr [RBX + 0xd0] TEST RDX,RDX JNZ 0x001371cf XOR EDX,EDX JMP 0x001371cf LAB_001371c3: MOV R8,-0x1 XOR EDX,EDX XOR R13D,R13D LAB_001371cf: MOV RAX,qword ptr [RBX + 0xe0] TEST RAX,RAX JZ 0x00137203 MOV RSI,qword ptr [RBX + 0xf0] CMP R8,RSI JA 0x00137364 LAB_001371eb: ADD RAX,RCX ADD R13,qword ptr [RBX + 0xe8] MOV RCX,qword ptr [RBX + 0xf8] CMP RDX,RCX JNC 0x00137206 JMP 0x00137209 LAB_00137203: MOV RAX,RCX LAB_00137206: MOV RCX,RDX LAB_00137209: MOV R12,qword ptr [RBX + 0x108] TEST R12,R12 JZ 0x0013723d MOV RDX,qword ptr [RBX + 0x118] CMP R8,RDX JA 0x0013736c LAB_00137225: ADD R12,RAX ADD R13,qword ptr [RBX + 0x110] MOV R15,qword ptr [RBX + 0x120] CMP RCX,R15 JNC 0x00137240 JMP 0x00137243 LAB_0013723d: MOV R12,RAX LAB_00137240: MOV R15,RCX LAB_00137243: TEST R12,R12 JZ 0x0013729e CMP byte ptr [R14],0x0 JNZ 0x0013726a MOV qword ptr [RBP + -0x38],RDI MOV RDI,R14 MOV qword ptr [RBP + -0x30],R8 CALL 0x00146378 MOV R8,qword ptr [RBP + -0x30] MOV RDI,qword ptr [RBP + -0x38] MOV byte ptr [R14],0x1 LAB_0013726a: MOV RCX,qword ptr [R14 + 0x8] MOV RAX,qword ptr [RBX + 0xb0] MOV EDX,dword ptr [RAX + 0x10] SHL RDX,0x5 ADD qword ptr [RCX + RDX*0x1],R12 ADD qword ptr [RCX + RDX*0x1 + 0x8],R13 LEA RAX,[RCX + RDX*0x1] CMP qword ptr [RCX + RDX*0x1 + 0x10],R8 JA 0x00137374 LAB_00137294: CMP qword ptr [RAX + 0x18],R15 JC 0x0013737d LAB_0013729e: XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI],XMM0 MOV RAX,-0x1 MOV qword ptr [RBX + 0xc8],RAX MOVUPS xmmword ptr [RBX + 0xd0],XMM0 MOVUPS xmmword ptr [RBX + 0xe0],XMM0 MOV qword ptr [RBX + 0xf0],RAX MOVUPS xmmword ptr [RBX + 0xf8],XMM0 MOVUPS xmmword ptr [RBX + 0x108],XMM0 MOV qword ptr [RBX + 0x118],RAX MOVUPS xmmword ptr [RBX + 0x120],XMM0 MOV qword ptr [RBX + 0x18],0x0 XOR EAX,EAX MOV dword ptr [RBX + 0x20],EAX MOV dword ptr [RBX + 0xa8],EAX MOV RCX,qword ptr [RBX + 0x8] MOV EDX,dword ptr [RBX] AND EDX,0xfffffffc XCHG dword ptr [RBX],EDX MOV byte ptr [RCX],AL LEA RCX,[0x49de18] MOV byte ptr [RCX + 0x9],AL ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0013731c: MOV qword ptr [RAX + 0xb0],RCX JMP 0x001370a8 LAB_00137328: MOV qword ptr [RAX + 0xb8],RCX JMP 0x001370bc LAB_00137334: MOV qword ptr [RAX + 0xd8],RCX JMP 0x001370ff LAB_00137340: MOV qword ptr [RAX + 0xe0],RCX JMP 0x00137113 LAB_0013734c: MOV qword ptr [RAX + 0x100],RCX JMP 0x00137156 LAB_00137358: MOV qword ptr [RAX + 0x108],RCX JMP 0x0013716a LAB_00137364: MOV R8,RSI JMP 0x001371eb LAB_0013736c: MOV R8,RDX JMP 0x00137225 LAB_00137374: MOV qword ptr [RAX + 0x10],R8 JMP 0x00137294 LAB_0013737d: MOV qword ptr [RAX + 0x18],R15 JMP 0x0013729e
/* destroy_socket(PFS_socket*) */ void destroy_socket(PFS_socket *param_1) { long *plVar1; PFS_connection_slice *this; long lVar2; long lVar3; ulong uVar4; long lVar5; ulong uVar6; long lVar7; lVar3 = *(long *)(param_1 + 0xb0); if (*(long *)(param_1 + 0xb8) != 0) { *(long *)(lVar3 + 0xa0) = *(long *)(lVar3 + 0xa0) + *(long *)(param_1 + 0xb8); *(long *)(lVar3 + 0xa8) = *(long *)(lVar3 + 0xa8) + *(long *)(param_1 + 0xc0); if (*(ulong *)(param_1 + 200) < *(ulong *)(lVar3 + 0xb0)) { *(ulong *)(lVar3 + 0xb0) = *(ulong *)(param_1 + 200); } if (*(ulong *)(lVar3 + 0xb8) < *(ulong *)(param_1 + 0xd0)) { *(ulong *)(lVar3 + 0xb8) = *(ulong *)(param_1 + 0xd0); } *(long *)(lVar3 + 0xc0) = *(long *)(lVar3 + 0xc0) + *(long *)(param_1 + 0xd8); } if (*(long *)(param_1 + 0xe0) != 0) { *(long *)(lVar3 + 200) = *(long *)(lVar3 + 200) + *(long *)(param_1 + 0xe0); *(long *)(lVar3 + 0xd0) = *(long *)(lVar3 + 0xd0) + *(long *)(param_1 + 0xe8); if (*(ulong *)(param_1 + 0xf0) < *(ulong *)(lVar3 + 0xd8)) { *(ulong *)(lVar3 + 0xd8) = *(ulong *)(param_1 + 0xf0); } if (*(ulong *)(lVar3 + 0xe0) < *(ulong *)(param_1 + 0xf8)) { *(ulong *)(lVar3 + 0xe0) = *(ulong *)(param_1 + 0xf8); } *(long *)(lVar3 + 0xe8) = *(long *)(lVar3 + 0xe8) + *(long *)(param_1 + 0x100); } if (*(long *)(param_1 + 0x108) != 0) { *(long *)(lVar3 + 0xf0) = *(long *)(lVar3 + 0xf0) + *(long *)(param_1 + 0x108); *(long *)(lVar3 + 0xf8) = *(long *)(lVar3 + 0xf8) + *(long *)(param_1 + 0x110); if (*(ulong *)(param_1 + 0x118) < *(ulong *)(lVar3 + 0x100)) { *(ulong *)(lVar3 + 0x100) = *(ulong *)(param_1 + 0x118); } if (*(ulong *)(lVar3 + 0x108) < *(ulong *)(param_1 + 0x120)) { *(ulong *)(lVar3 + 0x108) = *(ulong *)(param_1 + 0x120); } *(long *)(lVar3 + 0x110) = *(long *)(lVar3 + 0x110) + *(long *)(param_1 + 0x128); } if ((*(byte *)(lVar3 + 8) & 1) != 0) { *(int8 *)(lVar3 + 0x118) = 0; } this = *(PFS_connection_slice **)(param_1 + 0x18); if (this != (PFS_connection_slice *)0x0) { lVar3 = *(long *)(param_1 + 0xb8); if (lVar3 == 0) { uVar6 = 0xffffffffffffffff; uVar4 = 0; lVar7 = 0; } else { lVar7 = *(long *)(param_1 + 0xc0); uVar6 = *(ulong *)(param_1 + 200); uVar4 = *(ulong *)(param_1 + 0xd0); if (uVar4 == 0) { uVar4 = 0; } } if (*(long *)(param_1 + 0xe0) != 0) { if (*(ulong *)(param_1 + 0xf0) < uVar6) { uVar6 = *(ulong *)(param_1 + 0xf0); } lVar3 = *(long *)(param_1 + 0xe0) + lVar3; lVar7 = lVar7 + *(long *)(param_1 + 0xe8); if (uVar4 < *(ulong *)(param_1 + 0xf8)) { uVar4 = *(ulong *)(param_1 + 0xf8); } } if (*(long *)(param_1 + 0x108) != 0) { if (*(ulong *)(param_1 + 0x118) < uVar6) { uVar6 = *(ulong *)(param_1 + 0x118); } lVar3 = *(long *)(param_1 + 0x108) + lVar3; lVar7 = lVar7 + *(long *)(param_1 + 0x110); if (uVar4 < *(ulong *)(param_1 + 0x120)) { uVar4 = *(ulong *)(param_1 + 0x120); } } if (lVar3 != 0) { if (*this == (PFS_connection_slice)0x0) { PFS_connection_slice::reset_waits_stats(this); *this = (PFS_connection_slice)0x1; } lVar2 = *(long *)(this + 8); lVar5 = (ulong)*(uint *)(*(long *)(param_1 + 0xb0) + 0x10) * 0x20; *(long *)(lVar2 + lVar5) = *(long *)(lVar2 + lVar5) + lVar3; plVar1 = (long *)(lVar2 + 8 + lVar5); *plVar1 = *plVar1 + lVar7; lVar3 = lVar2 + lVar5; if (uVar6 < *(ulong *)(lVar2 + 0x10 + lVar5)) { *(ulong *)(lVar3 + 0x10) = uVar6; } if (*(ulong *)(lVar3 + 0x18) < uVar4) { *(ulong *)(lVar3 + 0x18) = uVar4; } } } *(long *)(param_1 + 0xb8) = 0; *(int8 *)(param_1 + 0xc0) = 0; *(int8 *)(param_1 + 200) = 0xffffffffffffffff; *(int8 *)(param_1 + 0xd0) = 0; *(int8 *)(param_1 + 0xd8) = 0; *(int8 *)(param_1 + 0xe0) = 0; *(int8 *)(param_1 + 0xe8) = 0; *(int8 *)(param_1 + 0xf0) = 0xffffffffffffffff; *(int8 *)(param_1 + 0xf8) = 0; *(int8 *)(param_1 + 0x100) = 0; *(int8 *)(param_1 + 0x108) = 0; *(int8 *)(param_1 + 0x110) = 0; *(int8 *)(param_1 + 0x118) = 0xffffffffffffffff; *(int8 *)(param_1 + 0x120) = 0; *(int8 *)(param_1 + 0x128) = 0; *(int8 *)(param_1 + 0x18) = 0; *(int4 *)(param_1 + 0x20) = 0; *(int4 *)(param_1 + 0xa8) = 0; LOCK(); *(uint *)param_1 = *(uint *)param_1 & 0xfffffffc; UNLOCK(); **(int1 **)(param_1 + 8) = 0; global_socket_container[9] = 0; return; }
56,862
fft_clear_cache
bluesky950520[P]quickjs/libbf.c
void fft_clear_cache(bf_context_t *s1) { int m_idx, inverse, k; BFNTTState *s = s1->ntt_state; if (s) { for(m_idx = 0; m_idx < NB_MODS; m_idx++) { for(inverse = 0; inverse < 2; inverse++) { for(k = 0; k < NTT_TRIG_K_MAX + 1; k++) { if (s->ntt_trig[m_idx][inverse][k]) { ntt_free(s, s->ntt_trig[m_idx][inverse][k]); s->ntt_trig[m_idx][inverse][k] = NULL; } } } } #if defined(__AVX2__) bf_aligned_free(s1, s); #else bf_free(s1, s); #endif s1->ntt_state = NULL; } }
O0
c
fft_clear_cache: subq $0x28, %rsp movq %rdi, 0x20(%rsp) movq 0x20(%rsp), %rax movq 0x70(%rax), %rax movq %rax, 0x8(%rsp) cmpq $0x0, 0x8(%rsp) je 0xecd65 movl $0x0, 0x1c(%rsp) cmpl $0x5, 0x1c(%rsp) jge 0xecd49 movl $0x0, 0x18(%rsp) cmpl $0x2, 0x18(%rsp) jge 0xecd37 movl $0x0, 0x14(%rsp) cmpl $0x14, 0x14(%rsp) jge 0xecd25 movq 0x8(%rsp), %rax addq $0x20b0, %rax # imm = 0x20B0 movslq 0x1c(%rsp), %rcx imulq $0x140, %rcx, %rcx # imm = 0x140 addq %rcx, %rax movslq 0x18(%rsp), %rcx imulq $0xa0, %rcx, %rcx addq %rcx, %rax movslq 0x14(%rsp), %rcx cmpq $0x0, (%rax,%rcx,8) je 0xecd13 movq 0x8(%rsp), %rdi movq 0x8(%rsp), %rax addq $0x20b0, %rax # imm = 0x20B0 movslq 0x1c(%rsp), %rcx imulq $0x140, %rcx, %rcx # imm = 0x140 addq %rcx, %rax movslq 0x18(%rsp), %rcx imulq $0xa0, %rcx, %rcx addq %rcx, %rax movslq 0x14(%rsp), %rcx movq (%rax,%rcx,8), %rsi callq 0xf9a80 movq 0x8(%rsp), %rax addq $0x20b0, %rax # imm = 0x20B0 movslq 0x1c(%rsp), %rcx imulq $0x140, %rcx, %rcx # imm = 0x140 addq %rcx, %rax movslq 0x18(%rsp), %rcx imulq $0xa0, %rcx, %rcx addq %rcx, %rax movslq 0x14(%rsp), %rcx movq $0x0, (%rax,%rcx,8) jmp 0xecd15 movl 0x14(%rsp), %eax addl $0x1, %eax movl %eax, 0x14(%rsp) jmp 0xecc61 jmp 0xecd27 movl 0x18(%rsp), %eax addl $0x1, %eax movl %eax, 0x18(%rsp) jmp 0xecc4e jmp 0xecd39 movl 0x1c(%rsp), %eax addl $0x1, %eax movl %eax, 0x1c(%rsp) jmp 0xecc3b movq 0x20(%rsp), %rdi movq 0x8(%rsp), %rsi callq 0xe5110 movq 0x20(%rsp), %rax movq $0x0, 0x70(%rax) addq $0x28, %rsp retq nopw (%rax,%rax)
fft_clear_cache: sub rsp, 28h mov [rsp+28h+var_8], rdi mov rax, [rsp+28h+var_8] mov rax, [rax+70h] mov [rsp+28h+var_20], rax cmp [rsp+28h+var_20], 0 jz loc_ECD65 mov [rsp+28h+var_C], 0 loc_ECC3B: cmp [rsp+28h+var_C], 5 jge loc_ECD49 mov [rsp+28h+var_10], 0 loc_ECC4E: cmp [rsp+28h+var_10], 2 jge loc_ECD37 mov [rsp+28h+var_14], 0 loc_ECC61: cmp [rsp+28h+var_14], 14h jge loc_ECD25 mov rax, [rsp+28h+var_20] add rax, 20B0h movsxd rcx, [rsp+28h+var_C] imul rcx, 140h add rax, rcx movsxd rcx, [rsp+28h+var_10] imul rcx, 0A0h add rax, rcx movsxd rcx, [rsp+28h+var_14] cmp qword ptr [rax+rcx*8], 0 jz short loc_ECD13 mov rdi, [rsp+28h+var_20] mov rax, [rsp+28h+var_20] add rax, 20B0h movsxd rcx, [rsp+28h+var_C] imul rcx, 140h add rax, rcx movsxd rcx, [rsp+28h+var_10] imul rcx, 0A0h add rax, rcx movsxd rcx, [rsp+28h+var_14] mov rsi, [rax+rcx*8] call ntt_free mov rax, [rsp+28h+var_20] add rax, 20B0h movsxd rcx, [rsp+28h+var_C] imul rcx, 140h add rax, rcx movsxd rcx, [rsp+28h+var_10] imul rcx, 0A0h add rax, rcx movsxd rcx, [rsp+28h+var_14] mov qword ptr [rax+rcx*8], 0 loc_ECD13: jmp short $+2 loc_ECD15: mov eax, [rsp+28h+var_14] add eax, 1 mov [rsp+28h+var_14], eax jmp loc_ECC61 loc_ECD25: jmp short $+2 loc_ECD27: mov eax, [rsp+28h+var_10] add eax, 1 mov [rsp+28h+var_10], eax jmp loc_ECC4E loc_ECD37: jmp short $+2 loc_ECD39: mov eax, [rsp+28h+var_C] add eax, 1 mov [rsp+28h+var_C], eax jmp loc_ECC3B loc_ECD49: mov rdi, [rsp+28h+var_8] mov rsi, [rsp+28h+var_20] call bf_free_0 mov rax, [rsp+28h+var_8] mov qword ptr [rax+70h], 0 loc_ECD65: add rsp, 28h retn
long long fft_clear_cache(long long a1, long long a2, long long a3, long long a4, long long a5, long long a6) { long long result; // rax long long v7; // [rsp+8h] [rbp-20h] int k; // [rsp+14h] [rbp-14h] int j; // [rsp+18h] [rbp-10h] int i; // [rsp+1Ch] [rbp-Ch] result = *(_QWORD *)(a1 + 112); v7 = result; if ( result ) { for ( i = 0; i < 5; ++i ) { for ( j = 0; j < 2; ++j ) { for ( k = 0; k < 20; ++k ) { a4 = k; if ( *(_QWORD *)(160LL * j + 320LL * i + v7 + 8368 + 8LL * k) ) { ntt_free(v7, *(_QWORD *)(160LL * j + 320LL * i + v7 + 8368 + 8LL * k)); a4 = k; *(_QWORD *)(160LL * j + 320LL * i + v7 + 8368 + 8LL * k) = 0LL; } } } } bf_free_0(a1, v7, a3, a4, a5, a6); result = a1; *(_QWORD *)(a1 + 112) = 0LL; } return result; }
fft_clear_cache: SUB RSP,0x28 MOV qword ptr [RSP + 0x20],RDI MOV RAX,qword ptr [RSP + 0x20] MOV RAX,qword ptr [RAX + 0x70] MOV qword ptr [RSP + 0x8],RAX CMP qword ptr [RSP + 0x8],0x0 JZ 0x001ecd65 MOV dword ptr [RSP + 0x1c],0x0 LAB_001ecc3b: CMP dword ptr [RSP + 0x1c],0x5 JGE 0x001ecd49 MOV dword ptr [RSP + 0x18],0x0 LAB_001ecc4e: CMP dword ptr [RSP + 0x18],0x2 JGE 0x001ecd37 MOV dword ptr [RSP + 0x14],0x0 LAB_001ecc61: CMP dword ptr [RSP + 0x14],0x14 JGE 0x001ecd25 MOV RAX,qword ptr [RSP + 0x8] ADD RAX,0x20b0 MOVSXD RCX,dword ptr [RSP + 0x1c] IMUL RCX,RCX,0x140 ADD RAX,RCX MOVSXD RCX,dword ptr [RSP + 0x18] IMUL RCX,RCX,0xa0 ADD RAX,RCX MOVSXD RCX,dword ptr [RSP + 0x14] CMP qword ptr [RAX + RCX*0x8],0x0 JZ 0x001ecd13 MOV RDI,qword ptr [RSP + 0x8] MOV RAX,qword ptr [RSP + 0x8] ADD RAX,0x20b0 MOVSXD RCX,dword ptr [RSP + 0x1c] IMUL RCX,RCX,0x140 ADD RAX,RCX MOVSXD RCX,dword ptr [RSP + 0x18] IMUL RCX,RCX,0xa0 ADD RAX,RCX MOVSXD RCX,dword ptr [RSP + 0x14] MOV RSI,qword ptr [RAX + RCX*0x8] CALL 0x001f9a80 MOV RAX,qword ptr [RSP + 0x8] ADD RAX,0x20b0 MOVSXD RCX,dword ptr [RSP + 0x1c] IMUL RCX,RCX,0x140 ADD RAX,RCX MOVSXD RCX,dword ptr [RSP + 0x18] IMUL RCX,RCX,0xa0 ADD RAX,RCX MOVSXD RCX,dword ptr [RSP + 0x14] MOV qword ptr [RAX + RCX*0x8],0x0 LAB_001ecd13: JMP 0x001ecd15 LAB_001ecd15: MOV EAX,dword ptr [RSP + 0x14] ADD EAX,0x1 MOV dword ptr [RSP + 0x14],EAX JMP 0x001ecc61 LAB_001ecd25: JMP 0x001ecd27 LAB_001ecd27: MOV EAX,dword ptr [RSP + 0x18] ADD EAX,0x1 MOV dword ptr [RSP + 0x18],EAX JMP 0x001ecc4e LAB_001ecd37: JMP 0x001ecd39 LAB_001ecd39: MOV EAX,dword ptr [RSP + 0x1c] ADD EAX,0x1 MOV dword ptr [RSP + 0x1c],EAX JMP 0x001ecc3b LAB_001ecd49: MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RSP + 0x8] CALL 0x001e5110 MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RAX + 0x70],0x0 LAB_001ecd65: ADD RSP,0x28 RET
void fft_clear_cache(long param_1) { long lVar1; int4 local_14; int4 local_10; int4 local_c; lVar1 = *(long *)(param_1 + 0x70); if (lVar1 != 0) { for (local_c = 0; local_c < 5; local_c = local_c + 1) { for (local_10 = 0; local_10 < 2; local_10 = local_10 + 1) { for (local_14 = 0; local_14 < 0x14; local_14 = local_14 + 1) { if (*(long *)(lVar1 + 0x20b0 + (long)local_c * 0x140 + (long)local_10 * 0xa0 + (long)local_14 * 8) != 0) { ntt_free(lVar1,*(int8 *) (lVar1 + 0x20b0 + (long)local_c * 0x140 + (long)local_10 * 0xa0 + (long)local_14 * 8)); *(int8 *) (lVar1 + 0x20b0 + (long)local_c * 0x140 + (long)local_10 * 0xa0 + (long)local_14 * 8) = 0; } } } } bf_free(param_1,lVar1); *(int8 *)(param_1 + 0x70) = 0; } return; }
56,863
Load_log_event::write_data_body()
eloqsql/sql/log_event_server.cc
bool Load_log_event::write_data_body() { if (sql_ex.write_data(writer)) return 1; if (num_fields && fields && field_lens) { if (write_data(field_lens, num_fields) || write_data(fields, field_block_len)) return 1; } return (write_data(table_name, table_name_len + 1) || write_data(db, db_len + 1) || write_data(fname, fname_len)); }
O0
cpp
Load_log_event::write_data_body(): pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x18(%rbp) movq %rax, %rdi addq $0xc8, %rdi movq 0x58(%rax), %rsi callq 0xa1b570 testb $0x1, %al jne 0xa1b46d jmp 0xa1b476 movb $0x1, -0x1(%rbp) jmp 0xa1b556 movq -0x18(%rbp), %rax cmpl $0x0, 0x8c(%rax) je 0xa1b4e1 movq -0x18(%rbp), %rax cmpq $0x0, 0x90(%rax) je 0xa1b4e1 movq -0x18(%rbp), %rax cmpq $0x0, 0x98(%rax) je 0xa1b4e1 movq -0x18(%rbp), %rdi movq 0x98(%rdi), %rsi movl 0x8c(%rdi), %eax movl %eax, %edx callq 0xa2cff0 testb $0x1, %al jne 0xa1b4d9 movq -0x18(%rbp), %rdi movq 0x90(%rdi), %rsi movl 0xa0(%rdi), %eax movl %eax, %edx callq 0xa2d030 testb $0x1, %al jne 0xa1b4d9 jmp 0xa1b4df movb $0x1, -0x1(%rbp) jmp 0xa1b556 jmp 0xa1b4e1 movq -0x18(%rbp), %rdi movq 0xa8(%rdi), %rsi movl 0x80(%rdi), %eax addl $0x1, %eax movl %eax, %eax movl %eax, %edx callq 0xa2d030 movb %al, %cl movb $0x1, %al testb $0x1, %cl movb %al, -0x19(%rbp) jne 0xa1b54e movq -0x18(%rbp), %rdi movq 0xb0(%rdi), %rsi movl 0x84(%rdi), %eax addl $0x1, %eax movl %eax, %eax movl %eax, %edx callq 0xa2d030 movb %al, %cl movb $0x1, %al testb $0x1, %cl movb %al, -0x19(%rbp) jne 0xa1b54e movq -0x18(%rbp), %rdi movq 0xb8(%rdi), %rsi movl 0x88(%rdi), %eax movl %eax, %edx callq 0xa2d030 movb %al, -0x19(%rbp) movb -0x19(%rbp), %al andb $0x1, %al movb %al, -0x1(%rbp) movb -0x1(%rbp), %al andb $0x1, %al addq $0x20, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ZN14Load_log_event15write_data_bodyEv: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov rax, [rbp+var_10] mov [rbp+var_18], rax mov rdi, rax add rdi, 0C8h; this mov rsi, [rax+58h]; Log_event_writer * call _ZN11sql_ex_info10write_dataEP16Log_event_writer; sql_ex_info::write_data(Log_event_writer *) test al, 1 jnz short loc_A1B46D jmp short loc_A1B476 loc_A1B46D: mov [rbp+var_1], 1 jmp loc_A1B556 loc_A1B476: mov rax, [rbp+var_18] cmp dword ptr [rax+8Ch], 0 jz short loc_A1B4E1 mov rax, [rbp+var_18] cmp qword ptr [rax+90h], 0 jz short loc_A1B4E1 mov rax, [rbp+var_18] cmp qword ptr [rax+98h], 0 jz short loc_A1B4E1 mov rdi, [rbp+var_18]; this mov rsi, [rdi+98h]; unsigned __int8 * mov eax, [rdi+8Ch] mov edx, eax; unsigned __int64 call _ZN9Log_event10write_dataEPKhm; Log_event::write_data(uchar const*,ulong) test al, 1 jnz short loc_A1B4D9 mov rdi, [rbp+var_18]; this mov rsi, [rdi+90h]; char * mov eax, [rdi+0A0h] mov edx, eax; unsigned __int64 call _ZN9Log_event10write_dataEPKcm; Log_event::write_data(char const*,ulong) test al, 1 jnz short loc_A1B4D9 jmp short loc_A1B4DF loc_A1B4D9: mov [rbp+var_1], 1 jmp short loc_A1B556 loc_A1B4DF: jmp short $+2 loc_A1B4E1: mov rdi, [rbp+var_18]; this mov rsi, [rdi+0A8h]; char * mov eax, [rdi+80h] add eax, 1 mov eax, eax mov edx, eax; unsigned __int64 call _ZN9Log_event10write_dataEPKcm; Log_event::write_data(char const*,ulong) mov cl, al mov al, 1 test cl, 1 mov [rbp+var_19], al jnz short loc_A1B54E mov rdi, [rbp+var_18]; this mov rsi, [rdi+0B0h]; char * mov eax, [rdi+84h] add eax, 1 mov eax, eax mov edx, eax; unsigned __int64 call _ZN9Log_event10write_dataEPKcm; Log_event::write_data(char const*,ulong) mov cl, al mov al, 1 test cl, 1 mov [rbp+var_19], al jnz short loc_A1B54E mov rdi, [rbp+var_18]; this mov rsi, [rdi+0B8h]; char * mov eax, [rdi+88h] mov edx, eax; unsigned __int64 call _ZN9Log_event10write_dataEPKcm; Log_event::write_data(char const*,ulong) mov [rbp+var_19], al loc_A1B54E: mov al, [rbp+var_19] and al, 1 mov [rbp+var_1], al loc_A1B556: mov al, [rbp+var_1] and al, 1 add rsp, 20h pop rbp retn
char Load_log_event::write_data_body(Load_log_event *this) { char v2; // [rsp+7h] [rbp-19h] if ( (sql_ex_info::write_data((Load_log_event *)((char *)this + 200), *((Log_event_writer **)this + 11)) & 1) != 0 ) return 1; if ( *((_DWORD *)this + 35) && *((_QWORD *)this + 18) && *((_QWORD *)this + 19) && ((Log_event::write_data(this, *((const unsigned __int8 **)this + 19), *((unsigned int *)this + 35)) & 1) != 0 || (Log_event::write_data(this, *((const char **)this + 18), *((unsigned int *)this + 40)) & 1) != 0) ) { return 1; } v2 = 1; if ( (Log_event::write_data(this, *((const char **)this + 21), (unsigned int)(*((_DWORD *)this + 32) + 1)) & 1) == 0 ) { v2 = 1; if ( (Log_event::write_data(this, *((const char **)this + 22), (unsigned int)(*((_DWORD *)this + 33) + 1)) & 1) == 0 ) v2 = Log_event::write_data(this, *((const char **)this + 23), *((unsigned int *)this + 34)); } return v2 & 1; }
compare_e_datetime: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x10],RDI MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x30],RAX CALL 0x005936d0 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x18],RCX MOV RAX,qword ptr [RAX] MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x268] MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x20],RCX MOV RAX,qword ptr [RAX + 0x8] MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x268] MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x28],RCX MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX] TEST byte ptr [RAX + 0x64],0x1 JNZ 0x00a1b4be MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x8] MOV RAX,qword ptr [RAX] TEST byte ptr [RAX + 0x64],0x1 JZ 0x00a1b4f9 LAB_00a1b4be: MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX] MOV RCX,qword ptr [RAX] XOR EAX,EAX TEST byte ptr [RCX + 0x64],0x1 MOV byte ptr [RBP + -0x31],AL JZ 0x00a1b4e4 MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x8] MOV RAX,qword ptr [RAX] MOV AL,byte ptr [RAX + 0x64] MOV byte ptr [RBP + -0x31],AL LAB_00a1b4e4: MOV DL,byte ptr [RBP + -0x31] XOR EAX,EAX MOV ECX,0x1 TEST DL,0x1 CMOVNZ EAX,ECX MOV dword ptr [RBP + -0x4],EAX JMP 0x00a1b511 LAB_00a1b4f9: MOV RDX,qword ptr [RBP + -0x20] MOV RSI,qword ptr [RBP + -0x28] XOR EAX,EAX MOV ECX,0x1 CMP RDX,RSI CMOVZ EAX,ECX MOV dword ptr [RBP + -0x4],EAX LAB_00a1b511: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x40 POP RBP RET
/* Arg_comparator::compare_e_datetime() */ bool __thiscall Arg_comparator::compare_e_datetime(Arg_comparator *this) { int8 uVar1; long lVar2; long lVar3; bool bVar4; byte local_39; uVar1 = _current_thd(); lVar2 = (**(code **)(*(long *)**(int8 **)this + 0x268))((long *)**(int8 **)this,uVar1) ; lVar3 = (**(code **)(*(long *)**(int8 **)(this + 8) + 0x268)) ((long *)**(int8 **)(this + 8),uVar1); if (((*(byte *)(**(long **)this + 100) & 1) == 0) && ((*(byte *)(**(long **)(this + 8) + 100) & 1) == 0)) { bVar4 = lVar2 == lVar3; } else { local_39 = 0; if ((*(byte *)(**(long **)this + 100) & 1) != 0) { local_39 = *(byte *)(**(long **)(this + 8) + 100); } bVar4 = (local_39 & 1) != 0; } return bVar4; }
56,864
mi_unpack_index_tuple
eloqsql/storage/myisam/mi_key.c
static int mi_unpack_index_tuple(MI_INFO *info, uint keynr, uchar *record) { if (_mi_put_key_in_record(info, keynr, FALSE, record)) { /* Impossible case; Can only happen if bug in code */ mi_print_error(info->s, HA_ERR_CRASHED); info->lastpos= HA_OFFSET_ERROR; /* No active record */ my_errno= HA_ERR_CRASHED; return 1; } return 0; }
O3
c
mi_unpack_index_tuple: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rdx, %rcx movq %rdi, %rbx xorl %r14d, %r14d xorl %edx, %edx callq 0x7b586 testl %eax, %eax je 0x7baa5 movq (%rbx), %rax movq 0x268(%rax), %rsi movl $0x7e, %edi callq 0x7ad3a movq $-0x1, 0x170(%rbx) callq 0xa1ab2 movl $0x7e, (%rax) movl $0x1, %r14d movl %r14d, %eax popq %rbx popq %r14 popq %rbp retq
mi_unpack_index_tuple: push rbp mov rbp, rsp push r14 push rbx mov rcx, rdx mov rbx, rdi xor r14d, r14d xor edx, edx call _mi_put_key_in_record test eax, eax jz short loc_7BAA5 mov rax, [rbx] mov rsi, [rax+268h] mov edi, 7Eh ; '~' call mi_report_error mov qword ptr [rbx+170h], 0FFFFFFFFFFFFFFFFh call _my_thread_var mov dword ptr [rax], 7Eh ; '~' mov r14d, 1 loc_7BAA5: mov eax, r14d pop rbx pop r14 pop rbp retn
long long mi_unpack_index_tuple(_QWORD *a1, unsigned int a2, long long a3) { unsigned int v3; // r14d v3 = 0; if ( (unsigned int)mi_put_key_in_record((long long)a1, a2, 0, a3) ) { mi_report_error(126, *(_QWORD *)(*a1 + 616LL)); a1[46] = -1LL; *(_DWORD *)my_thread_var(126LL) = 126; return 1; } return v3; }
mi_unpack_index_tuple: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RCX,RDX MOV RBX,RDI XOR R14D,R14D XOR EDX,EDX CALL 0x0017b586 TEST EAX,EAX JZ 0x0017baa5 MOV RAX,qword ptr [RBX] MOV RSI,qword ptr [RAX + 0x268] MOV EDI,0x7e CALL 0x0017ad3a MOV qword ptr [RBX + 0x170],-0x1 CALL 0x001a1ab2 MOV dword ptr [RAX],0x7e MOV R14D,0x1 LAB_0017baa5: MOV EAX,R14D POP RBX POP R14 POP RBP RET
bool mi_unpack_index_tuple(long *param_1,int8 param_2,int8 param_3) { int iVar1; int4 *puVar2; iVar1 = _mi_put_key_in_record(param_1,param_2,0,param_3); if (iVar1 != 0) { mi_report_error(0x7e,*(int8 *)(*param_1 + 0x268)); param_1[0x2e] = -1; puVar2 = (int4 *)_my_thread_var(); *puVar2 = 0x7e; } return iVar1 != 0; }
56,865
cli::group cli::matchable_derived<cli::option>::operator&<cli::hex>(cli::matchable_derived<cli::hex> const&)
msxemulator/build_O0/_deps/picotool-src/cli.h
group matchable_derived<D>::operator&(const matchable_derived<T> &m) { int _min = matchable::min(); int _max = matchable::max(); min(1); max(1); return group{this->to_ptr(), m.to_ptr()}.set_type(group::sequence).min(_min).max(_max); }
O0
c
cli::group cli::matchable_derived<cli::option>::operator&<cli::hex>(cli::matchable_derived<cli::hex> const&): subq $0x178, %rsp # imm = 0x178 movq %rdi, 0x8(%rsp) movq %rdi, %rax movq %rax, 0x10(%rsp) movq %rdi, 0x170(%rsp) movq %rsi, 0x168(%rsp) movq %rdx, 0x160(%rsp) movq 0x168(%rsp), %rdi movq %rdi, 0x20(%rsp) callq 0x57590 movq 0x20(%rsp), %rdi movl %eax, 0x15c(%rsp) callq 0x575b0 movq 0x20(%rsp), %rdi movl %eax, 0x158(%rsp) movl $0x1, %esi movl %esi, 0x1c(%rsp) callq 0x9de00 movl 0x1c(%rsp), %esi movq 0x20(%rsp), %rdi callq 0x9de20 movq 0x20(%rsp), %rsi leaq 0x48(%rsp), %rdi callq 0x83fc0 movq 0x160(%rsp), %rsi leaq 0x38(%rsp), %rdi callq 0x9eb00 jmp 0x9e2aa xorl %eax, %eax leaq 0x58(%rsp), %rdi leaq 0x48(%rsp), %rsi leaq 0x38(%rsp), %rdx callq 0x840e0 jmp 0x9e2c2 leaq 0x58(%rsp), %rdi xorl %esi, %esi callq 0x9ded0 movq %rax, %rdi movl 0x15c(%rsp), %esi callq 0x59030 movq %rax, (%rsp) jmp 0x9e2e3 movq (%rsp), %rdi movl 0x158(%rsp), %esi callq 0x9def0 movq 0x8(%rsp), %rdi movq %rax, %rsi callq 0x590b0 jmp 0x9e302 leaq 0x58(%rsp), %rdi callq 0x59190 leaq 0x38(%rsp), %rdi callq 0x7bf00 leaq 0x48(%rsp), %rdi callq 0x7bf00 movq 0x10(%rsp), %rax addq $0x178, %rsp # imm = 0x178 retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x30(%rsp) movl %eax, 0x2c(%rsp) jmp 0x9e36f movq %rax, %rcx movl %edx, %eax movq %rcx, 0x30(%rsp) movl %eax, 0x2c(%rsp) jmp 0x9e365 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x30(%rsp) movl %eax, 0x2c(%rsp) leaq 0x58(%rsp), %rdi callq 0x59190 leaq 0x38(%rsp), %rdi callq 0x7bf00 leaq 0x48(%rsp), %rdi callq 0x7bf00 movq 0x30(%rsp), %rdi callq 0xf9e0 nopw %cs:(%rax,%rax) nopl (%rax)
_ZN3cli17matchable_derivedINS_6optionEEanINS_3hexEEENS_5groupERKNS0_IT_EE: sub rsp, 178h mov [rsp+178h+var_170], rdi; __int64 mov rax, rdi mov qword ptr [rsp+178h+var_168], rax; int mov [rsp+178h+var_8], rdi mov [rsp+178h+var_10], rsi mov qword ptr [rsp+178h+var_18], rdx mov rdi, [rsp+178h+var_10]; this mov [rsp+178h+var_158], rdi; int call _ZNK3cli9matchable3minEv; cli::matchable::min(void) mov rdi, [rsp+178h+var_158]; this mov [rsp+178h+var_1C], eax call _ZNK3cli9matchable3maxEv; cli::matchable::max(void) mov rdi, [rsp+178h+var_158] mov [rsp+178h+var_20], eax mov esi, 1 mov [rsp+178h+var_15C], esi call _ZN3cli17matchable_derivedINS_6optionEE3minEi; cli::matchable_derived<cli::option>::min(int) mov esi, [rsp+178h+var_15C] mov rdi, [rsp+178h+var_158] call _ZN3cli17matchable_derivedINS_6optionEE3maxEi; cli::matchable_derived<cli::option>::max(int) mov rsi, [rsp+178h+var_158] lea rdi, [rsp+178h+var_130]; void * call _ZNK3cli17matchable_derivedINS_6optionEE6to_ptrEv; cli::matchable_derived<cli::option>::to_ptr(void) mov rsi, qword ptr [rsp+178h+var_18]; int lea rdi, [rsp+178h+var_140]; int call _ZNK3cli17matchable_derivedINS_3hexEE6to_ptrEv; cli::matchable_derived<cli::hex>::to_ptr(void) jmp short $+2 loc_9E2AA: xor eax, eax lea rdi, [rsp+178h+var_120]; int lea rsi, [rsp+178h+var_130]; int lea rdx, [rsp+178h+var_140]; int call _ZN3cli5groupC2ISt10shared_ptrINS_9matchableEEJEEET_S5_z; cli::group::group<std::shared_ptr<cli::matchable>>(std::shared_ptr<cli::matchable>,std::shared_ptr<cli::matchable>,...) jmp short $+2 loc_9E2C2: lea rdi, [rsp+178h+var_120] xor esi, esi call _ZN3cli5group8set_typeENS0_10group_typeE; cli::group::set_type(cli::group::group_type) mov rdi, rax mov esi, [rsp+178h+var_1C] call _ZN3cli17matchable_derivedINS_5groupEE3minEi; cli::matchable_derived<cli::group>::min(int) mov [rsp+178h+var_178], rax jmp short $+2 loc_9E2E3: mov rdi, [rsp+178h+var_178] mov esi, [rsp+178h+var_20] call _ZN3cli17matchable_derivedINS_5groupEE3maxEi; cli::matchable_derived<cli::group>::max(int) mov rdi, [rsp+178h+var_170]; this mov rsi, rax; cli::group * call _ZN3cli5groupC2ERKS0_; cli::group::group(cli::group const&) jmp short $+2 loc_9E302: lea rdi, [rsp+178h+var_120]; void * call _ZN3cli5groupD2Ev; cli::group::~group() lea rdi, [rsp+178h+var_140] call _ZNSt10shared_ptrIN3cli9matchableEED2Ev; std::shared_ptr<cli::matchable>::~shared_ptr() lea rdi, [rsp+178h+var_130] call _ZNSt10shared_ptrIN3cli9matchableEED2Ev; std::shared_ptr<cli::matchable>::~shared_ptr() mov rax, qword ptr [rsp+178h+var_168] add rsp, 178h retn mov rcx, rax mov eax, edx mov [rsp+arg_28], rcx mov [rsp+arg_24], eax jmp short loc_9E36F mov rcx, rax mov eax, edx mov [rsp+arg_28], rcx mov [rsp+arg_24], eax jmp short loc_9E365 mov rcx, rax mov eax, edx mov [rsp+arg_28], rcx mov [rsp+arg_24], eax lea rdi, [rsp+arg_50]; void * call _ZN3cli5groupD2Ev; cli::group::~group() loc_9E365: lea rdi, [rsp+arg_30] call _ZNSt10shared_ptrIN3cli9matchableEED2Ev; std::shared_ptr<cli::matchable>::~shared_ptr() loc_9E36F: lea rdi, [rsp+arg_40] call _ZNSt10shared_ptrIN3cli9matchableEED2Ev; std::shared_ptr<cli::matchable>::~shared_ptr() mov rdi, [rsp+arg_28] call __Unwind_Resume
long long cli::matchable_derived<cli::option>::operator&<cli::hex>(long long a1, cli::matchable *a2, long long a3) { int v3; // edx int v4; // ecx int v5; // r8d int v6; // r9d long long v7; // rax const cli::group *v8; // rax int v10; // [rsp+0h] [rbp-178h] long long v11; // [rsp+0h] [rbp-178h] cli::group *v12; // [rsp+8h] [rbp-170h] int v13[2]; // [rsp+10h] [rbp-168h] void *v14; // [rsp+18h] [rbp-160h] long long v15; // [rsp+28h] [rbp-150h] int v16[4]; // [rsp+38h] [rbp-140h] BYREF int v17[4]; // [rsp+48h] [rbp-130h] BYREF _QWORD v18[32]; // [rsp+58h] [rbp-120h] BYREF int v19; // [rsp+158h] [rbp-20h] int v20; // [rsp+15Ch] [rbp-1Ch] int v21[2]; // [rsp+160h] [rbp-18h] cli::matchable *v22; // [rsp+168h] [rbp-10h] long long v23; // [rsp+170h] [rbp-8h] v23 = a1; v22 = a2; *(_QWORD *)v21 = a3; v20 = cli::matchable::min(a2); v19 = cli::matchable::max(a2); HIDWORD(v14) = 1; cli::matchable_derived<cli::option>::min((long long)a2, 1); cli::matchable_derived<cli::option>::max((long long)a2, 1); cli::matchable_derived<cli::option>::to_ptr(v17, (long long)a2); cli::matchable_derived<cli::hex>::to_ptr((int)v16, v21[0], v3, v4, v5, v6, v10, a1, a1, v14, (int)a2, v15); cli::group::group<std::shared_ptr<cli::matchable>>((long long)v18, (long long)v17, (long long)v16); v7 = cli::group::set_type((long long)v18, 0); v11 = cli::matchable_derived<cli::group>::min(v7, v20); v8 = (const cli::group *)cli::matchable_derived<cli::group>::max(v11, v19); cli::group::group(v12, v8); cli::group::~group(v18); std::shared_ptr<cli::matchable>::~shared_ptr((long long)v16); std::shared_ptr<cli::matchable>::~shared_ptr((long long)v17); return *(_QWORD *)v13; }
operator&: SUB RSP,0x178 MOV qword ptr [RSP + 0x8],RDI MOV RAX,RDI MOV qword ptr [RSP + 0x10],RAX MOV qword ptr [RSP + 0x170],RDI MOV qword ptr [RSP + 0x168],RSI MOV qword ptr [RSP + 0x160],RDX MOV RDI,qword ptr [RSP + 0x168] MOV qword ptr [RSP + 0x20],RDI CALL 0x00157590 MOV RDI,qword ptr [RSP + 0x20] MOV dword ptr [RSP + 0x15c],EAX CALL 0x001575b0 MOV RDI,qword ptr [RSP + 0x20] MOV dword ptr [RSP + 0x158],EAX MOV ESI,0x1 MOV dword ptr [RSP + 0x1c],ESI CALL 0x0019de00 MOV ESI,dword ptr [RSP + 0x1c] MOV RDI,qword ptr [RSP + 0x20] CALL 0x0019de20 MOV RSI,qword ptr [RSP + 0x20] LEA RDI,[RSP + 0x48] CALL 0x00183fc0 MOV RSI,qword ptr [RSP + 0x160] LAB_0019e29e: LEA RDI,[RSP + 0x38] CALL 0x0019eb00 JMP 0x0019e2aa LAB_0019e2aa: XOR EAX,EAX LEA RDI,[RSP + 0x58] LEA RSI,[RSP + 0x48] LEA RDX,[RSP + 0x38] CALL 0x001840e0 JMP 0x0019e2c2 LAB_0019e2c2: LEA RDI,[RSP + 0x58] XOR ESI,ESI CALL 0x0019ded0 MOV RDI,RAX MOV ESI,dword ptr [RSP + 0x15c] LAB_0019e2d8: CALL 0x00159030 MOV qword ptr [RSP],RAX JMP 0x0019e2e3 LAB_0019e2e3: MOV RDI,qword ptr [RSP] MOV ESI,dword ptr [RSP + 0x158] CALL 0x0019def0 MOV RDI,qword ptr [RSP + 0x8] MOV RSI,RAX CALL 0x001590b0 LAB_0019e300: JMP 0x0019e302 LAB_0019e302: LEA RDI,[RSP + 0x58] CALL 0x00159190 LEA RDI,[RSP + 0x38] CALL 0x0017bf00 LEA RDI,[RSP + 0x48] CALL 0x0017bf00 MOV RAX,qword ptr [RSP + 0x10] ADD RSP,0x178 RET
/* cli::group cli::matchable_derived<cli::option>::TEMPNAMEPLACEHOLDERVALUE(cli::matchable_derived<cli::hex> const&) */ matchable_derived<cli::option> * __thiscall cli::matchable_derived<cli::option>::operator& (matchable_derived<cli::option> *this,matchable_derived *param_1) { matchable_derived<cli::group> *pmVar1; group *pgVar2; shared_ptr<cli::matchable> local_140 [16]; shared_ptr<cli::matchable> local_130 [16]; group local_120 [256]; int local_20; int local_1c; matchable_derived *local_10; matchable_derived<cli::option> *local_8; local_10 = param_1; local_8 = this; local_1c = matchable::min((matchable *)param_1); local_20 = matchable::max((matchable *)param_1); min((matchable_derived<cli::option> *)param_1,1); max((matchable_derived<cli::option> *)param_1,1); to_ptr(); /* try { // try from 0019e29e to 0019e2a7 has its CatchHandler @ 0019e32d */ matchable_derived<cli::hex>::to_ptr(); /* try { // try from 0019e2aa to 0019e2bf has its CatchHandler @ 0019e33d */ group::group<std::shared_ptr<cli::matchable>>(local_120,local_130,local_140); pmVar1 = (matchable_derived<cli::group> *)group::set_type(local_120,0); /* try { // try from 0019e2d8 to 0019e2ff has its CatchHandler @ 0019e34d */ pmVar1 = (matchable_derived<cli::group> *)matchable_derived<cli::group>::min(pmVar1,local_1c); pgVar2 = (group *)matchable_derived<cli::group>::max(pmVar1,local_20); group::group((group *)this,pgVar2); group::~group(local_120); std::shared_ptr<cli::matchable>::~shared_ptr(local_140); std::shared_ptr<cli::matchable>::~shared_ptr(local_130); return this; }
56,866
ha_partition::end_bulk_update()
eloqsql/sql/ha_partition.cc
int ha_partition::end_bulk_update() { int error= 0; handler **file= m_file; DBUG_ENTER("ha_partition::end_bulk_update"); do { int tmp; if ((tmp= (*file)->end_bulk_update())) error= tmp; } while (*(++file)); sum_copy_infos(); DBUG_RETURN(error); }
O0
cpp
ha_partition::end_bulk_update(): pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x28(%rbp) movl $0x0, -0xc(%rbp) movq 0x548(%rax), %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax movq (%rax), %rdi movq (%rdi), %rax callq *0xf8(%rax) movl %eax, -0x1c(%rbp) cmpl $0x0, %eax je 0xca4f54 movl -0x1c(%rbp), %eax movl %eax, -0xc(%rbp) jmp 0xca4f56 movq -0x18(%rbp), %rax movq %rax, %rcx addq $0x8, %rcx movq %rcx, -0x18(%rbp) cmpq $0x0, 0x8(%rax) jne 0xca4f36 movq -0x28(%rbp), %rdi callq 0xc9bea0 movl -0xc(%rbp), %eax addq $0x30, %rsp popq %rbp retq nop
_ZN12ha_partition15end_bulk_updateEv: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov [rbp+var_28], rax mov [rbp+var_C], 0 mov rax, [rax+548h] mov [rbp+var_18], rax loc_CA4F36: mov rax, [rbp+var_18] mov rdi, [rax] mov rax, [rdi] call qword ptr [rax+0F8h] mov [rbp+var_1C], eax cmp eax, 0 jz short loc_CA4F54 mov eax, [rbp+var_1C] mov [rbp+var_C], eax loc_CA4F54: jmp short $+2 loc_CA4F56: mov rax, [rbp+var_18] mov rcx, rax add rcx, 8 mov [rbp+var_18], rcx cmp qword ptr [rax+8], 0 jnz short loc_CA4F36 mov rdi, [rbp+var_28]; this call _ZN12ha_partition14sum_copy_infosEv; ha_partition::sum_copy_infos(void) mov eax, [rbp+var_C] add rsp, 30h pop rbp retn
long long ha_partition::end_bulk_update(ha_partition *this) { _QWORD *v1; // rax unsigned int v3; // [rsp+14h] [rbp-1Ch] _QWORD *v4; // [rsp+18h] [rbp-18h] unsigned int v5; // [rsp+24h] [rbp-Ch] v5 = 0; v4 = (_QWORD *)*((_QWORD *)this + 169); do { v3 = (*(long long ( **)(_QWORD))(*(_QWORD *)*v4 + 248LL))(*v4); if ( v3 ) v5 = v3; v1 = v4++; } while ( v1[1] ); ha_partition::sum_copy_infos(this); return v5; }
my_bit_log2_hex_digit: PUSH RBP MOV RBP,RSP MOV AL,DIL MOV byte ptr [RBP + -0x1],AL MOVZX EAX,byte ptr [RBP + -0x1] AND EAX,0xc CMP EAX,0x0 JZ 0x00ca4f42 MOVZX EDX,byte ptr [RBP + -0x1] AND EDX,0x8 MOV EAX,0x2 MOV ECX,0x3 CMP EDX,0x0 CMOVNZ EAX,ECX MOV dword ptr [RBP + -0x8],EAX JMP 0x00ca4f59 LAB_00ca4f42: MOVZX EDX,byte ptr [RBP + -0x1] AND EDX,0x2 XOR EAX,EAX MOV ECX,0x1 CMP EDX,0x0 CMOVNZ EAX,ECX MOV dword ptr [RBP + -0x8],EAX LAB_00ca4f59: MOV EAX,dword ptr [RBP + -0x8] POP RBP RET
/* my_bit_log2_hex_digit(unsigned char) */ int1 my_bit_log2_hex_digit(uchar param_1) { int1 uVar1; if ((param_1 & 0xc) == 0) { uVar1 = (param_1 & 2) != 0; } else { uVar1 = 2; if ((param_1 & 8) != 0) { uVar1 = 3; } } return uVar1; }
56,867
stbiw__crc32(unsigned char*, int)
7CodeWizard[P]stablediffusion/thirdparty/stb_image_write.h
static unsigned int stbiw__crc32(unsigned char *buffer, int len) { #ifdef STBIW_CRC32 return STBIW_CRC32(buffer, len); #else static unsigned int crc_table[256] = { 0x00000000, 0x77073096, 0xEE0E612C, 0x990951BA, 0x076DC419, 0x706AF48F, 0xE963A535, 0x9E6495A3, 0x0eDB8832, 0x79DCB8A4, 0xE0D5E91E, 0x97D2D988, 0x09B64C2B, 0x7EB17CBD, 0xE7B82D07, 0x90BF1D91, 0x1DB71064, 0x6AB020F2, 0xF3B97148, 0x84BE41DE, 0x1ADAD47D, 0x6DDDE4EB, 0xF4D4B551, 0x83D385C7, 0x136C9856, 0x646BA8C0, 0xFD62F97A, 0x8A65C9EC, 0x14015C4F, 0x63066CD9, 0xFA0F3D63, 0x8D080DF5, 0x3B6E20C8, 0x4C69105E, 0xD56041E4, 0xA2677172, 0x3C03E4D1, 0x4B04D447, 0xD20D85FD, 0xA50AB56B, 0x35B5A8FA, 0x42B2986C, 0xDBBBC9D6, 0xACBCF940, 0x32D86CE3, 0x45DF5C75, 0xDCD60DCF, 0xABD13D59, 0x26D930AC, 0x51DE003A, 0xC8D75180, 0xBFD06116, 0x21B4F4B5, 0x56B3C423, 0xCFBA9599, 0xB8BDA50F, 0x2802B89E, 0x5F058808, 0xC60CD9B2, 0xB10BE924, 0x2F6F7C87, 0x58684C11, 0xC1611DAB, 0xB6662D3D, 0x76DC4190, 0x01DB7106, 0x98D220BC, 0xEFD5102A, 0x71B18589, 0x06B6B51F, 0x9FBFE4A5, 0xE8B8D433, 0x7807C9A2, 0x0F00F934, 0x9609A88E, 0xE10E9818, 0x7F6A0DBB, 0x086D3D2D, 0x91646C97, 0xE6635C01, 0x6B6B51F4, 0x1C6C6162, 0x856530D8, 0xF262004E, 0x6C0695ED, 0x1B01A57B, 0x8208F4C1, 0xF50FC457, 0x65B0D9C6, 0x12B7E950, 0x8BBEB8EA, 0xFCB9887C, 0x62DD1DDF, 0x15DA2D49, 0x8CD37CF3, 0xFBD44C65, 0x4DB26158, 0x3AB551CE, 0xA3BC0074, 0xD4BB30E2, 0x4ADFA541, 0x3DD895D7, 0xA4D1C46D, 0xD3D6F4FB, 0x4369E96A, 0x346ED9FC, 0xAD678846, 0xDA60B8D0, 0x44042D73, 0x33031DE5, 0xAA0A4C5F, 0xDD0D7CC9, 0x5005713C, 0x270241AA, 0xBE0B1010, 0xC90C2086, 0x5768B525, 0x206F85B3, 0xB966D409, 0xCE61E49F, 0x5EDEF90E, 0x29D9C998, 0xB0D09822, 0xC7D7A8B4, 0x59B33D17, 0x2EB40D81, 0xB7BD5C3B, 0xC0BA6CAD, 0xEDB88320, 0x9ABFB3B6, 0x03B6E20C, 0x74B1D29A, 0xEAD54739, 0x9DD277AF, 0x04DB2615, 0x73DC1683, 0xE3630B12, 0x94643B84, 0x0D6D6A3E, 0x7A6A5AA8, 0xE40ECF0B, 0x9309FF9D, 0x0A00AE27, 0x7D079EB1, 0xF00F9344, 0x8708A3D2, 0x1E01F268, 0x6906C2FE, 0xF762575D, 0x806567CB, 0x196C3671, 0x6E6B06E7, 0xFED41B76, 0x89D32BE0, 0x10DA7A5A, 0x67DD4ACC, 0xF9B9DF6F, 0x8EBEEFF9, 0x17B7BE43, 0x60B08ED5, 0xD6D6A3E8, 0xA1D1937E, 0x38D8C2C4, 0x4FDFF252, 0xD1BB67F1, 0xA6BC5767, 0x3FB506DD, 0x48B2364B, 0xD80D2BDA, 0xAF0A1B4C, 0x36034AF6, 0x41047A60, 0xDF60EFC3, 0xA867DF55, 0x316E8EEF, 0x4669BE79, 0xCB61B38C, 0xBC66831A, 0x256FD2A0, 0x5268E236, 0xCC0C7795, 0xBB0B4703, 0x220216B9, 0x5505262F, 0xC5BA3BBE, 0xB2BD0B28, 0x2BB45A92, 0x5CB36A04, 0xC2D7FFA7, 0xB5D0CF31, 0x2CD99E8B, 0x5BDEAE1D, 0x9B64C2B0, 0xEC63F226, 0x756AA39C, 0x026D930A, 0x9C0906A9, 0xEB0E363F, 0x72076785, 0x05005713, 0x95BF4A82, 0xE2B87A14, 0x7BB12BAE, 0x0CB61B38, 0x92D28E9B, 0xE5D5BE0D, 0x7CDCEFB7, 0x0BDBDF21, 0x86D3D2D4, 0xF1D4E242, 0x68DDB3F8, 0x1FDA836E, 0x81BE16CD, 0xF6B9265B, 0x6FB077E1, 0x18B74777, 0x88085AE6, 0xFF0F6A70, 0x66063BCA, 0x11010B5C, 0x8F659EFF, 0xF862AE69, 0x616BFFD3, 0x166CCF45, 0xA00AE278, 0xD70DD2EE, 0x4E048354, 0x3903B3C2, 0xA7672661, 0xD06016F7, 0x4969474D, 0x3E6E77DB, 0xAED16A4A, 0xD9D65ADC, 0x40DF0B66, 0x37D83BF0, 0xA9BCAE53, 0xDEBB9EC5, 0x47B2CF7F, 0x30B5FFE9, 0xBDBDF21C, 0xCABAC28A, 0x53B39330, 0x24B4A3A6, 0xBAD03605, 0xCDD70693, 0x54DE5729, 0x23D967BF, 0xB3667A2E, 0xC4614AB8, 0x5D681B02, 0x2A6F2B94, 0xB40BBE37, 0xC30C8EA1, 0x5A05DF1B, 0x2D02EF8D }; unsigned int crc = ~0u; int i; for (i=0; i < len; ++i) crc = (crc >> 8) ^ crc_table[buffer[i] ^ (crc & 0xff)]; return ~crc; #endif }
O0
c
stbiw__crc32(unsigned char*, int): movq %rdi, -0x8(%rsp) movl %esi, -0xc(%rsp) movl $0xffffffff, -0x10(%rsp) # imm = 0xFFFFFFFF movl $0x0, -0x14(%rsp) movl -0x14(%rsp), %eax cmpl -0xc(%rsp), %eax jge 0x301d3 movl -0x10(%rsp), %eax shrl $0x8, %eax movq -0x8(%rsp), %rcx movslq -0x14(%rsp), %rdx movzbl (%rcx,%rdx), %ecx movl -0x10(%rsp), %edx andl $0xff, %edx xorl %edx, %ecx movl %ecx, %ecx movl %ecx, %edx leaq 0x1a8801(%rip), %rcx # 0x1d89c0 xorl (%rcx,%rdx,4), %eax movl %eax, -0x10(%rsp) movl -0x14(%rsp), %eax addl $0x1, %eax movl %eax, -0x14(%rsp) jmp 0x30189 movl -0x10(%rsp), %eax xorl $-0x1, %eax retq nopl (%rax,%rax)
_ZL12stbiw__crc32Phi: mov [rsp+var_8], rdi mov [rsp+var_C], esi mov [rsp+var_10], 0FFFFFFFFh mov [rsp+var_14], 0 loc_30189: mov eax, [rsp+var_14] cmp eax, [rsp+var_C] jge short loc_301D3 mov eax, [rsp+var_10] shr eax, 8 mov rcx, [rsp+var_8] movsxd rdx, [rsp+var_14] movzx ecx, byte ptr [rcx+rdx] mov edx, [rsp+var_10] and edx, 0FFh xor ecx, edx mov ecx, ecx mov edx, ecx lea rcx, _ZZL12stbiw__crc32PhiE9crc_table; stbiw__crc32(uchar *,int)::crc_table xor eax, [rcx+rdx*4] mov [rsp+var_10], eax mov eax, [rsp+var_14] add eax, 1 mov [rsp+var_14], eax jmp short loc_30189 loc_301D3: mov eax, [rsp+var_10] xor eax, 0FFFFFFFFh retn
long long stbiw__crc32(unsigned __int8 *a1, int a2) { int i; // [rsp+0h] [rbp-14h] unsigned int v4; // [rsp+4h] [rbp-10h] v4 = -1; for ( i = 0; i < a2; ++i ) v4 = stbiw__crc32(unsigned char *,int)::crc_table[(unsigned __int8)v4 ^ a1[i]] ^ (v4 >> 8); return ~v4; }
stbiw__crc32: MOV qword ptr [RSP + -0x8],RDI MOV dword ptr [RSP + -0xc],ESI MOV dword ptr [RSP + -0x10],0xffffffff MOV dword ptr [RSP + -0x14],0x0 LAB_00130189: MOV EAX,dword ptr [RSP + -0x14] CMP EAX,dword ptr [RSP + -0xc] JGE 0x001301d3 MOV EAX,dword ptr [RSP + -0x10] SHR EAX,0x8 MOV RCX,qword ptr [RSP + -0x8] MOVSXD RDX,dword ptr [RSP + -0x14] MOVZX ECX,byte ptr [RCX + RDX*0x1] MOV EDX,dword ptr [RSP + -0x10] AND EDX,0xff XOR ECX,EDX MOV ECX,ECX MOV EDX,ECX LEA RCX,[0x2d89c0] XOR EAX,dword ptr [RCX + RDX*0x4] MOV dword ptr [RSP + -0x10],EAX MOV EAX,dword ptr [RSP + -0x14] ADD EAX,0x1 MOV dword ptr [RSP + -0x14],EAX JMP 0x00130189 LAB_001301d3: MOV EAX,dword ptr [RSP + -0x10] XOR EAX,0xffffffff RET
/* stbiw__crc32(unsigned char*, int) */ uint stbiw__crc32(uchar *param_1,int param_2) { int local_14; uint local_10; local_10 = 0xffffffff; for (local_14 = 0; local_14 < param_2; local_14 = local_14 + 1) { local_10 = local_10 >> 8 ^ *(uint *)(stbiw__crc32(unsigned_char*,int)::crc_table + (ulong)((uint)param_1[local_14] ^ local_10 & 0xff) * 4); } return local_10 ^ 0xffffffff; }
56,868
get_charsets_dir
eloqsql/mysys/charset.c
char *get_charsets_dir(char *buf) { const char *sharedir= SHAREDIR; char *res; DBUG_ENTER("get_charsets_dir"); if (charsets_dir != NULL) strmake(buf, charsets_dir, FN_REFLEN-1); else { if (test_if_hard_path(sharedir) || is_prefix(sharedir, DEFAULT_CHARSET_HOME)) strxmov(buf, sharedir, "/", CHARSET_DIR, NullS); else strxmov(buf, DEFAULT_CHARSET_HOME, "/", sharedir, "/", CHARSET_DIR, NullS); } res= convert_dirname(buf,buf,NullS); DBUG_PRINT("info",("charsets dir: '%s'", buf)); DBUG_RETURN(res); }
O0
c
get_charsets_dir: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) leaq 0x7da24(%rip), %rax # 0xfe207 movq %rax, -0x10(%rbp) leaq 0x3b8d72(%rip), %rax # 0x439560 cmpq $0x0, (%rax) je 0x8080e movq -0x8(%rbp), %rdi leaq 0x3b8d61(%rip), %rax # 0x439560 movq (%rax), %rsi movl $0x1ff, %edx # imm = 0x1FF callq 0xf64e0 jmp 0x80888 movq -0x10(%rbp), %rdi callq 0x9cce0 cmpl $0x0, %eax jne 0x80831 movq -0x10(%rbp), %rdi leaq 0x7d9f9(%rip), %rsi # 0xfe220 callq 0xf2cd0 cmpl $0x0, %eax je 0x80855 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi leaq 0x7fb12(%rip), %rdx # 0x100352 leaq 0x7d9ec(%rip), %rcx # 0xfe233 xorl %eax, %eax movl %eax, %r8d movb $0x0, %al callq 0xf65c0 jmp 0x80886 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rcx leaq 0x7d9bc(%rip), %rsi # 0xfe220 leaq 0x7fae7(%rip), %r8 # 0x100352 leaq 0x7d9c1(%rip), %r9 # 0xfe233 xorl %eax, %eax movq %r8, %rdx movq $0x0, (%rsp) movb $0x0, %al callq 0xf65c0 jmp 0x80888 movq -0x8(%rbp), %rdi movq -0x8(%rbp), %rsi xorl %eax, %eax movl %eax, %edx callq 0x86f40 movq %rax, -0x18(%rbp) jmp 0x8089f jmp 0x808a1 movq -0x18(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
get_charsets_dir: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi lea rax, aHomeMonoInstal; "/home/mono/install/share" mov [rbp+var_10], rax lea rax, charsets_dir cmp qword ptr [rax], 0 jz short loc_8080E mov rdi, [rbp+var_8] lea rax, charsets_dir mov rsi, [rax] mov edx, 1FFh call strmake jmp short loc_80888 loc_8080E: mov rdi, [rbp+var_10] call test_if_hard_path cmp eax, 0 jnz short loc_80831 mov rdi, [rbp+var_10] lea rsi, aHomeMonoInstal_0; "/home/mono/install" call is_prefix cmp eax, 0 jz short loc_80855 loc_80831: mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] lea rdx, word_100352 lea rcx, aCharsets; "charsets/" xor eax, eax mov r8d, eax mov al, 0 call strxmov jmp short loc_80886 loc_80855: mov rdi, [rbp+var_8] mov rcx, [rbp+var_10] lea rsi, aHomeMonoInstal_0; "/home/mono/install" lea r8, word_100352 lea r9, aCharsets; "charsets/" xor eax, eax mov rdx, r8 mov [rsp+30h+var_30], 0 mov al, 0 call strxmov loc_80886: jmp short $+2 loc_80888: mov rdi, [rbp+var_8] mov rsi, [rbp+var_8] xor eax, eax mov edx, eax call convert_dirname mov [rbp+var_18], rax jmp short $+2 loc_8089F: jmp short $+2 loc_808A1: mov rax, [rbp+var_18] mov [rbp+var_20], rax mov rax, [rbp+var_20] add rsp, 30h pop rbp retn
long long get_charsets_dir(long long a1) { int v1; // r9d if ( charsets_dir ) { strmake(a1, charsets_dir, 511LL); } else if ( (unsigned int)test_if_hard_path("/home/mono/install/share") || (unsigned int)is_prefix("/home/mono/install/share", "/home/mono/install") ) { strxmov(a1, (unsigned int)"/home/mono/install/share", (unsigned int)&word_100352, (unsigned int)"charsets/", 0, v1); } else { strxmov( a1, (unsigned int)"/home/mono/install", (unsigned int)&word_100352, (unsigned int)"/home/mono/install/share", (unsigned int)&word_100352, (unsigned int)"charsets/"); } return convert_dirname(a1, a1, 0LL); }
get_charsets_dir: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI LEA RAX,[0x1fe207] MOV qword ptr [RBP + -0x10],RAX LEA RAX,[0x539560] CMP qword ptr [RAX],0x0 JZ 0x0018080e MOV RDI,qword ptr [RBP + -0x8] LEA RAX,[0x539560] MOV RSI,qword ptr [RAX] MOV EDX,0x1ff CALL 0x001f64e0 JMP 0x00180888 LAB_0018080e: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0019cce0 CMP EAX,0x0 JNZ 0x00180831 MOV RDI,qword ptr [RBP + -0x10] LEA RSI,[0x1fe220] CALL 0x001f2cd0 CMP EAX,0x0 JZ 0x00180855 LAB_00180831: MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] LEA RDX,[0x200352] LEA RCX,[0x1fe233] XOR EAX,EAX MOV R8D,EAX MOV AL,0x0 CALL 0x001f65c0 JMP 0x00180886 LAB_00180855: MOV RDI,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RBP + -0x10] LEA RSI,[0x1fe220] LEA R8,[0x200352] LEA R9,[0x1fe233] XOR EAX,EAX MOV RDX,R8 MOV qword ptr [RSP],0x0 MOV AL,0x0 CALL 0x001f65c0 LAB_00180886: JMP 0x00180888 LAB_00180888: MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x8] XOR EAX,EAX MOV EDX,EAX CALL 0x00186f40 MOV qword ptr [RBP + -0x18],RAX JMP 0x0018089f LAB_0018089f: JMP 0x001808a1 LAB_001808a1: MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] ADD RSP,0x30 POP RBP RET
int8 get_charsets_dir(int8 param_1) { int iVar1; int8 uVar2; if (charsets_dir == 0) { iVar1 = test_if_hard_path("/home/mono/install/share"); if ((iVar1 == 0) && (iVar1 = is_prefix("/home/mono/install/share","/home/mono/install"), iVar1 == 0)) { strxmov(param_1,"/home/mono/install",&DAT_00200352,"/home/mono/install/share",&DAT_00200352, "charsets/",0); } else { strxmov(param_1,"/home/mono/install/share",&DAT_00200352,"charsets/",0); } } else { strmake(param_1,charsets_dir,0x1ff); } uVar2 = convert_dirname(param_1,param_1,0); return uVar2; }
56,869
js_object_list_resize_hash
bluesky950520[P]quickjs/quickjs.c
static int js_object_list_resize_hash(JSContext *ctx, JSObjectList *s, uint32_t new_hash_size) { JSObjectListEntry *e; uint32_t i, h, *new_hash_table; new_hash_table = js_malloc(ctx, sizeof(new_hash_table[0]) * new_hash_size); if (!new_hash_table) return -1; js_free(ctx, s->hash_table); s->hash_table = new_hash_table; s->hash_size = new_hash_size; for(i = 0; i < s->hash_size; i++) { s->hash_table[i] = -1; } for(i = 0; i < s->object_count; i++) { e = &s->object_tab[i]; h = js_object_list_get_hash(e->obj, s->hash_size); e->hash_next = s->hash_table[h]; s->hash_table[h] = i; } return 0; }
O0
c
js_object_list_resize_hash: subq $0x38, %rsp movq %rdi, 0x28(%rsp) movq %rsi, 0x20(%rsp) movl %edx, 0x1c(%rsp) movq 0x28(%rsp), %rdi movl 0x1c(%rsp), %eax movl %eax, %esi shlq $0x2, %rsi callq 0x21cb0 movq %rax, (%rsp) cmpq $0x0, (%rsp) jne 0x79ede movl $0xffffffff, 0x34(%rsp) # imm = 0xFFFFFFFF jmp 0x79fc9 movq 0x28(%rsp), %rdi movq 0x20(%rsp), %rax movq 0x10(%rax), %rsi callq 0x21db0 movq (%rsp), %rcx movq 0x20(%rsp), %rax movq %rcx, 0x10(%rax) movl 0x1c(%rsp), %ecx movq 0x20(%rsp), %rax movl %ecx, 0x18(%rax) movl $0x0, 0xc(%rsp) movl 0xc(%rsp), %eax movq 0x20(%rsp), %rcx cmpl 0x18(%rcx), %eax jae 0x79f41 movq 0x20(%rsp), %rax movq 0x10(%rax), %rax movl 0xc(%rsp), %ecx movl $0xffffffff, (%rax,%rcx,4) # imm = 0xFFFFFFFF movl 0xc(%rsp), %eax addl $0x1, %eax movl %eax, 0xc(%rsp) jmp 0x79f12 movl $0x0, 0xc(%rsp) movl 0xc(%rsp), %eax movq 0x20(%rsp), %rcx cmpl 0x8(%rcx), %eax jae 0x79fc1 movq 0x20(%rsp), %rax movq (%rax), %rax movl 0xc(%rsp), %ecx shlq $0x4, %rcx addq %rcx, %rax movq %rax, 0x10(%rsp) movq 0x10(%rsp), %rax movq (%rax), %rdi movq 0x20(%rsp), %rax movl 0x18(%rax), %esi callq 0x79e70 movl %eax, 0x8(%rsp) movq 0x20(%rsp), %rax movq 0x10(%rax), %rax movl 0x8(%rsp), %ecx movl (%rax,%rcx,4), %ecx movq 0x10(%rsp), %rax movl %ecx, 0x8(%rax) movl 0xc(%rsp), %edx movq 0x20(%rsp), %rax movq 0x10(%rax), %rax movl 0x8(%rsp), %ecx movl %edx, (%rax,%rcx,4) movl 0xc(%rsp), %eax addl $0x1, %eax movl %eax, 0xc(%rsp) jmp 0x79f49 movl $0x0, 0x34(%rsp) movl 0x34(%rsp), %eax addq $0x38, %rsp retq nopw %cs:(%rax,%rax)
js_object_list_resize_hash: sub rsp, 38h mov [rsp+38h+var_10], rdi mov [rsp+38h+var_18], rsi mov [rsp+38h+var_1C], edx mov rdi, [rsp+38h+var_10] mov eax, [rsp+38h+var_1C] mov esi, eax shl rsi, 2 call js_malloc mov [rsp+38h+var_38], rax cmp [rsp+38h+var_38], 0 jnz short loc_79EDE mov [rsp+38h+var_4], 0FFFFFFFFh jmp loc_79FC9 loc_79EDE: mov rdi, [rsp+38h+var_10] mov rax, [rsp+38h+var_18] mov rsi, [rax+10h] call js_free mov rcx, [rsp+38h+var_38] mov rax, [rsp+38h+var_18] mov [rax+10h], rcx mov ecx, [rsp+38h+var_1C] mov rax, [rsp+38h+var_18] mov [rax+18h], ecx mov [rsp+38h+var_2C], 0 loc_79F12: mov eax, [rsp+38h+var_2C] mov rcx, [rsp+38h+var_18] cmp eax, [rcx+18h] jnb short loc_79F41 mov rax, [rsp+38h+var_18] mov rax, [rax+10h] mov ecx, [rsp+38h+var_2C] mov dword ptr [rax+rcx*4], 0FFFFFFFFh mov eax, [rsp+38h+var_2C] add eax, 1 mov [rsp+38h+var_2C], eax jmp short loc_79F12 loc_79F41: mov [rsp+38h+var_2C], 0 loc_79F49: mov eax, [rsp+38h+var_2C] mov rcx, [rsp+38h+var_18] cmp eax, [rcx+8] jnb short loc_79FC1 mov rax, [rsp+38h+var_18] mov rax, [rax] mov ecx, [rsp+38h+var_2C] shl rcx, 4 add rax, rcx mov [rsp+38h+var_28], rax mov rax, [rsp+38h+var_28] mov rdi, [rax] mov rax, [rsp+38h+var_18] mov esi, [rax+18h] call js_object_list_get_hash mov [rsp+38h+var_30], eax mov rax, [rsp+38h+var_18] mov rax, [rax+10h] mov ecx, [rsp+38h+var_30] mov ecx, [rax+rcx*4] mov rax, [rsp+38h+var_28] mov [rax+8], ecx mov edx, [rsp+38h+var_2C] mov rax, [rsp+38h+var_18] mov rax, [rax+10h] mov ecx, [rsp+38h+var_30] mov [rax+rcx*4], edx mov eax, [rsp+38h+var_2C] add eax, 1 mov [rsp+38h+var_2C], eax jmp short loc_79F49 loc_79FC1: mov [rsp+38h+var_4], 0 loc_79FC9: mov eax, [rsp+38h+var_4] add rsp, 38h retn
long long js_object_list_resize_hash(long long a1, long long a2, unsigned int a3) { long long v4; // [rsp+0h] [rbp-38h] unsigned int hash; // [rsp+8h] [rbp-30h] unsigned int i; // [rsp+Ch] [rbp-2Ch] unsigned int j; // [rsp+Ch] [rbp-2Ch] long long v8; // [rsp+10h] [rbp-28h] v4 = js_malloc(a1, 4LL * a3); if ( v4 ) { js_free(a1, *(_QWORD *)(a2 + 16)); *(_QWORD *)(a2 + 16) = v4; *(_DWORD *)(a2 + 24) = a3; for ( i = 0; i < *(_DWORD *)(a2 + 24); ++i ) *(_DWORD *)(*(_QWORD *)(a2 + 16) + 4LL * i) = -1; for ( j = 0; j < *(_DWORD *)(a2 + 8); ++j ) { v8 = 16LL * j + *(_QWORD *)a2; hash = js_object_list_get_hash(*(_QWORD *)v8, *(_DWORD *)(a2 + 24)); *(_DWORD *)(v8 + 8) = *(_DWORD *)(*(_QWORD *)(a2 + 16) + 4LL * hash); *(_DWORD *)(*(_QWORD *)(a2 + 16) + 4LL * hash) = j; } return 0; } else { return (unsigned int)-1; } }
js_object_list_resize_hash: SUB RSP,0x38 MOV qword ptr [RSP + 0x28],RDI MOV qword ptr [RSP + 0x20],RSI MOV dword ptr [RSP + 0x1c],EDX MOV RDI,qword ptr [RSP + 0x28] MOV EAX,dword ptr [RSP + 0x1c] MOV ESI,EAX SHL RSI,0x2 CALL 0x00121cb0 MOV qword ptr [RSP],RAX CMP qword ptr [RSP],0x0 JNZ 0x00179ede MOV dword ptr [RSP + 0x34],0xffffffff JMP 0x00179fc9 LAB_00179ede: MOV RDI,qword ptr [RSP + 0x28] MOV RAX,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RAX + 0x10] CALL 0x00121db0 MOV RCX,qword ptr [RSP] MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RAX + 0x10],RCX MOV ECX,dword ptr [RSP + 0x1c] MOV RAX,qword ptr [RSP + 0x20] MOV dword ptr [RAX + 0x18],ECX MOV dword ptr [RSP + 0xc],0x0 LAB_00179f12: MOV EAX,dword ptr [RSP + 0xc] MOV RCX,qword ptr [RSP + 0x20] CMP EAX,dword ptr [RCX + 0x18] JNC 0x00179f41 MOV RAX,qword ptr [RSP + 0x20] MOV RAX,qword ptr [RAX + 0x10] MOV ECX,dword ptr [RSP + 0xc] MOV dword ptr [RAX + RCX*0x4],0xffffffff MOV EAX,dword ptr [RSP + 0xc] ADD EAX,0x1 MOV dword ptr [RSP + 0xc],EAX JMP 0x00179f12 LAB_00179f41: MOV dword ptr [RSP + 0xc],0x0 LAB_00179f49: MOV EAX,dword ptr [RSP + 0xc] MOV RCX,qword ptr [RSP + 0x20] CMP EAX,dword ptr [RCX + 0x8] JNC 0x00179fc1 MOV RAX,qword ptr [RSP + 0x20] MOV RAX,qword ptr [RAX] MOV ECX,dword ptr [RSP + 0xc] SHL RCX,0x4 ADD RAX,RCX MOV qword ptr [RSP + 0x10],RAX MOV RAX,qword ptr [RSP + 0x10] MOV RDI,qword ptr [RAX] MOV RAX,qword ptr [RSP + 0x20] MOV ESI,dword ptr [RAX + 0x18] CALL 0x00179e70 MOV dword ptr [RSP + 0x8],EAX MOV RAX,qword ptr [RSP + 0x20] MOV RAX,qword ptr [RAX + 0x10] MOV ECX,dword ptr [RSP + 0x8] MOV ECX,dword ptr [RAX + RCX*0x4] MOV RAX,qword ptr [RSP + 0x10] MOV dword ptr [RAX + 0x8],ECX MOV EDX,dword ptr [RSP + 0xc] MOV RAX,qword ptr [RSP + 0x20] MOV RAX,qword ptr [RAX + 0x10] MOV ECX,dword ptr [RSP + 0x8] MOV dword ptr [RAX + RCX*0x4],EDX MOV EAX,dword ptr [RSP + 0xc] ADD EAX,0x1 MOV dword ptr [RSP + 0xc],EAX JMP 0x00179f49 LAB_00179fc1: MOV dword ptr [RSP + 0x34],0x0 LAB_00179fc9: MOV EAX,dword ptr [RSP + 0x34] ADD RSP,0x38 RET
int4 js_object_list_resize_hash(int8 param_1,long *param_2,uint param_3) { uint uVar1; long lVar2; int8 *puVar3; uint local_2c; int4 local_4; lVar2 = js_malloc(param_1,(ulong)param_3 << 2); if (lVar2 == 0) { local_4 = 0xffffffff; } else { js_free(param_1,param_2[2]); param_2[2] = lVar2; *(uint *)(param_2 + 3) = param_3; for (local_2c = 0; local_2c < *(uint *)(param_2 + 3); local_2c = local_2c + 1) { *(int4 *)(param_2[2] + (ulong)local_2c * 4) = 0xffffffff; } for (local_2c = 0; local_2c < *(uint *)(param_2 + 1); local_2c = local_2c + 1) { puVar3 = (int8 *)(*param_2 + (ulong)local_2c * 0x10); uVar1 = js_object_list_get_hash(*puVar3,(int)param_2[3]); *(int4 *)(puVar3 + 1) = *(int4 *)(param_2[2] + (ulong)uVar1 * 4); *(uint *)(param_2[2] + (ulong)uVar1 * 4) = local_2c; } local_4 = 0; } return local_4; }
56,870
my_wc_mb_bin
eloqsql/strings/ctype-bin.c
int my_wc_mb_bin(CHARSET_INFO *cs __attribute__((unused)), my_wc_t wc, uchar *s, uchar *e) { if (s >= e) return MY_CS_TOOSMALL; if (wc < 256) { s[0]= (char) wc; return 1; } return MY_CS_ILUNI; }
O0
c
my_wc_mb_bin: 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 0x3dbd7 movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B jmp 0x3dbfd cmpq $0x100, -0x18(%rbp) # imm = 0x100 jae 0x3dbf6 movq -0x18(%rbp), %rax movb %al, %cl movq -0x20(%rbp), %rax movb %cl, (%rax) movl $0x1, -0x4(%rbp) jmp 0x3dbfd movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopw %cs:(%rax,%rax)
my_wc_mb_bin: 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_3DBD7 mov [rbp+var_4], 0FFFFFF9Bh jmp short loc_3DBFD loc_3DBD7: cmp [rbp+var_18], 100h jnb short loc_3DBF6 mov rax, [rbp+var_18] mov cl, al mov rax, [rbp+var_20] mov [rax], cl mov [rbp+var_4], 1 jmp short loc_3DBFD loc_3DBF6: mov [rbp+var_4], 0 loc_3DBFD: mov eax, [rbp+var_4] pop rbp retn
long long my_wc_mb_bin(long long a1, unsigned long long a2, _BYTE *a3, unsigned long long a4) { if ( (unsigned long long)a3 < a4 ) { if ( a2 >= 0x100 ) { return 0; } else { *a3 = a2; return 1; } } else { return (unsigned int)-101; } }
my_wc_mb_bin: 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 0x0013dbd7 MOV dword ptr [RBP + -0x4],0xffffff9b JMP 0x0013dbfd LAB_0013dbd7: CMP qword ptr [RBP + -0x18],0x100 JNC 0x0013dbf6 MOV RAX,qword ptr [RBP + -0x18] MOV CL,AL MOV RAX,qword ptr [RBP + -0x20] MOV byte ptr [RAX],CL MOV dword ptr [RBP + -0x4],0x1 JMP 0x0013dbfd LAB_0013dbf6: MOV dword ptr [RBP + -0x4],0x0 LAB_0013dbfd: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int4 my_wc_mb_bin(int8 param_1,ulong param_2,int1 *param_3,int1 *param_4) { int4 local_c; if (param_3 < param_4) { if (param_2 < 0x100) { *param_3 = (char)param_2; local_c = 1; } else { local_c = 0; } } else { local_c = 0xffffff9b; } return local_c; }
56,871
my_b_cache_write
eloqsql/mysys/mf_iocache.c
int _my_b_cache_write(IO_CACHE *info, const uchar *Buffer, size_t Count) { if (Buffer != info->write_buffer) { Count= IO_ROUND_DN(Count); if (!Count) return 0; } if (info->seek_not_done) { /* Whenever a function which operates on IO_CACHE flushes/writes some part of the IO_CACHE to disk it will set the property "seek_not_done" to indicate this to other functions operating on the IO_CACHE. */ if (mysql_file_seek(info->file, info->pos_in_file, MY_SEEK_SET, MYF(info->myflags & MY_WME)) == MY_FILEPOS_ERROR) { info->error= -1; return 1; } info->seek_not_done=0; } if (mysql_file_write(info->file, Buffer, Count, info->myflags | MY_NABP)) return info->error= -1; info->pos_in_file+= Count; return 0; }
O0
c
my_b_cache_write: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x18(%rbp), %rax movq -0x10(%rbp), %rcx cmpq 0x30(%rcx), %rax je 0x71189 movabsq $0xfffff000, %rax # imm = 0xFFFFF000 andq -0x20(%rbp), %rax movq %rax, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) jne 0x71187 movl $0x0, -0x4(%rbp) jmp 0x71259 jmp 0x71189 movq -0x10(%rbp), %rax cmpl $0x0, 0xe0(%rax) je 0x711f5 movq -0x10(%rbp), %rax movl 0xd4(%rax), %edx movq -0x10(%rbp), %rax movq (%rax), %rcx movq -0x10(%rbp), %rax movq 0xf8(%rax), %r9 andq $0x10, %r9 leaq 0x688c3(%rip), %rdi # 0xd9a80 movl $0x5ef, %esi # imm = 0x5EF xorl %r8d, %r8d callq 0x6e860 cmpq $-0x1, %rax jne 0x711e7 movq -0x10(%rbp), %rax movl $0xffffffff, 0xe4(%rax) # imm = 0xFFFFFFFF movl $0x1, -0x4(%rbp) jmp 0x71259 movq -0x10(%rbp), %rax movl $0x0, 0xe0(%rax) movq -0x10(%rbp), %rax movl 0xd4(%rax), %edx movq -0x18(%rbp), %rcx movq -0x20(%rbp), %r8 movq -0x10(%rbp), %rax movq 0xf8(%rax), %r9 orq $0x4, %r9 leaq 0x68863(%rip), %rdi # 0xd9a80 movl $0x5f6, %esi # imm = 0x5F6 callq 0x70210 cmpq $0x0, %rax je 0x71244 movq -0x10(%rbp), %rax movl $0xffffffff, 0xe4(%rax) # imm = 0xFFFFFFFF movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0x71259 movq -0x20(%rbp), %rcx movq -0x10(%rbp), %rax addq (%rax), %rcx movq %rcx, (%rax) movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_my_b_cache_write: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov rax, [rbp+var_18] mov rcx, [rbp+var_10] cmp rax, [rcx+30h] jz short loc_71189 mov rax, 0FFFFF000h and rax, [rbp+var_20] mov [rbp+var_20], rax cmp [rbp+var_20], 0 jnz short loc_71187 mov [rbp+var_4], 0 jmp loc_71259 loc_71187: jmp short $+2 loc_71189: mov rax, [rbp+var_10] cmp dword ptr [rax+0E0h], 0 jz short loc_711F5 mov rax, [rbp+var_10] mov edx, [rax+0D4h] mov rax, [rbp+var_10] mov rcx, [rax] mov rax, [rbp+var_10] mov r9, [rax+0F8h] and r9, 10h lea rdi, aWorkspaceLlm4b_19; "/workspace/llm4binary/github2025/eloqsq"... mov esi, 5EFh xor r8d, r8d call inline_mysql_file_seek_2 cmp rax, 0FFFFFFFFFFFFFFFFh jnz short loc_711E7 mov rax, [rbp+var_10] mov dword ptr [rax+0E4h], 0FFFFFFFFh mov [rbp+var_4], 1 jmp short loc_71259 loc_711E7: mov rax, [rbp+var_10] mov dword ptr [rax+0E0h], 0 loc_711F5: mov rax, [rbp+var_10] mov edx, [rax+0D4h] mov rcx, [rbp+var_18] mov r8, [rbp+var_20] mov rax, [rbp+var_10] mov r9, [rax+0F8h] or r9, 4 lea rdi, aWorkspaceLlm4b_19; "/workspace/llm4binary/github2025/eloqsq"... mov esi, 5F6h call inline_mysql_file_write_1 cmp rax, 0 jz short loc_71244 mov rax, [rbp+var_10] mov dword ptr [rax+0E4h], 0FFFFFFFFh mov [rbp+var_4], 0FFFFFFFFh jmp short loc_71259 loc_71244: mov rcx, [rbp+var_20] mov rax, [rbp+var_10] add rcx, [rax] mov [rax], rcx mov [rbp+var_4], 0 loc_71259: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long my_b_cache_write(long long a1, long long a2, long long a3) { long long v4; // [rsp+0h] [rbp-20h] v4 = a3; if ( a2 == *(_QWORD *)(a1 + 48) || (v4 = (unsigned int)a3 & 0xFFFFF000, (a3 & 0xFFFFF000) != 0) ) { if ( *(_DWORD *)(a1 + 224) ) { if ( inline_mysql_file_seek_2( (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c", 0x5EFu, *(_DWORD *)(a1 + 212), *(_QWORD *)a1, 0, *(_QWORD *)(a1 + 248) & 0x10LL) == -1 ) { *(_DWORD *)(a1 + 228) = -1; return 1; } *(_DWORD *)(a1 + 224) = 0; } if ( inline_mysql_file_write_1( (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c", 0x5F6u, *(_DWORD *)(a1 + 212), a2, v4, *(_QWORD *)(a1 + 248) | 4LL) ) { *(_DWORD *)(a1 + 228) = -1; return (unsigned int)-1; } else { *(_QWORD *)a1 += v4; return 0; } } else { return 0; } }
_my_b_cache_write: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0x30] JZ 0x00171189 MOV RAX,0xfffff000 AND RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x20],RAX CMP qword ptr [RBP + -0x20],0x0 JNZ 0x00171187 MOV dword ptr [RBP + -0x4],0x0 JMP 0x00171259 LAB_00171187: JMP 0x00171189 LAB_00171189: MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0xe0],0x0 JZ 0x001711f5 MOV RAX,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RAX + 0xd4] MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x10] MOV R9,qword ptr [RAX + 0xf8] AND R9,0x10 LEA RDI,[0x1d9a80] MOV ESI,0x5ef XOR R8D,R8D CALL 0x0016e860 CMP RAX,-0x1 JNZ 0x001711e7 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xe4],0xffffffff MOV dword ptr [RBP + -0x4],0x1 JMP 0x00171259 LAB_001711e7: MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xe0],0x0 LAB_001711f5: MOV RAX,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RAX + 0xd4] MOV RCX,qword ptr [RBP + -0x18] MOV R8,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] MOV R9,qword ptr [RAX + 0xf8] OR R9,0x4 LEA RDI,[0x1d9a80] MOV ESI,0x5f6 CALL 0x00170210 CMP RAX,0x0 JZ 0x00171244 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xe4],0xffffffff MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x00171259 LAB_00171244: MOV RCX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] ADD RCX,qword ptr [RAX] MOV qword ptr [RAX],RCX MOV dword ptr [RBP + -0x4],0x0 LAB_00171259: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 _my_b_cache_write(long *param_1,long param_2,ulong param_3) { long lVar1; ulong local_28; int4 local_c; local_28 = param_3; if ((param_2 == param_1[6]) || (local_28 = param_3 & 0xfffff000, local_28 != 0)) { if ((int)param_1[0x1c] != 0) { lVar1 = inline_mysql_file_seek ("/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x5ef, *(int4 *)((long)param_1 + 0xd4),*param_1,0,param_1[0x1f] & 0x10); if (lVar1 == -1) { *(int4 *)((long)param_1 + 0xe4) = 0xffffffff; return 1; } *(int4 *)(param_1 + 0x1c) = 0; } lVar1 = inline_mysql_file_write ("/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x5f6, *(int4 *)((long)param_1 + 0xd4),param_2,local_28,param_1[0x1f] | 4); if (lVar1 == 0) { *param_1 = local_28 + *param_1; local_c = 0; } else { *(int4 *)((long)param_1 + 0xe4) = 0xffffffff; local_c = 0xffffffff; } } else { local_c = 0; } return local_c; }
56,872
my_strntoull_mb2_or_mb4
eloqsql/strings/ctype-ucs2.c
static ulonglong my_strntoull_mb2_or_mb4(CHARSET_INFO *cs, const char *nptr, size_t l, int base, char **endptr, int *err) { int negative= 0; int overflow; int cnv; my_wc_t wc; my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc; register ulonglong cutoff; register unsigned int cutlim; register ulonglong res; register const uchar *s= (const uchar*) nptr; register const uchar *e= (const uchar*) nptr + l; const uchar *save; *err= 0; do { if ((cnv= mb_wc(cs, &wc, s, e)) > 0) { switch (wc) { case ' ' : break; case '\t': break; case '-' : negative= !negative; break; case '+' : break; default : goto bs; } } else /* No more characters or bad multibyte sequence */ { if (endptr !=NULL ) *endptr = (char*)s; err[0]= (cnv==MY_CS_ILSEQ) ? EILSEQ : EDOM; return 0; } s+=cnv; } while (1); bs: overflow = 0; res = 0; save = s; cutoff = (~(ulonglong) 0) / (unsigned long int) base; cutlim = (uint) ((~(ulonglong) 0) % (unsigned long int) base); do { if ((cnv= mb_wc(cs, &wc, s, e)) > 0) { s+=cnv; if ( wc>='0' && wc<='9') wc -= '0'; else if ( wc>='A' && wc<='Z') wc = wc - 'A' + 10; else if ( wc>='a' && wc<='z') wc = wc - 'a' + 10; else break; if ((int)wc >= base) break; if (res > cutoff || (res == cutoff && wc > cutlim)) overflow = 1; else { res *= (ulonglong) base; res += wc; } } else if (cnv==MY_CS_ILSEQ) { if (endptr !=NULL ) *endptr = (char*)s; err[0]= EILSEQ; return 0; } else { /* No more characters */ break; } } while(1); if (endptr != NULL) *endptr = (char *) s; if (s == save) { err[0]= EDOM; return 0L; } if (overflow) { err[0]= ERANGE; return (~(ulonglong) 0); } return (negative ? -((longlong) res) : (longlong) res); }
O0
c
my_strntoull_mb2_or_mb4: pushq %rbp movq %rsp, %rbp subq $0xa0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movl %ecx, -0x24(%rbp) movq %r8, -0x30(%rbp) movq %r9, -0x38(%rbp) movl $0x0, -0x3c(%rbp) movq -0x10(%rbp), %rax movq 0xb8(%rax), %rax movq 0x28(%rax), %rax movq %rax, -0x58(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x78(%rbp) movq -0x18(%rbp), %rax addq -0x20(%rbp), %rax movq %rax, -0x80(%rbp) movq -0x38(%rbp), %rax movl $0x0, (%rax) movq -0x58(%rbp), %rax movq -0x10(%rbp), %rdi movq -0x78(%rbp), %rdx movq -0x80(%rbp), %rcx leaq -0x50(%rbp), %rsi callq *%rax movl %eax, -0x44(%rbp) cmpl $0x0, %eax jle 0x93311 movq -0x50(%rbp), %rax addq $-0x9, %rax movq %rax, -0x90(%rbp) subq $0x24, %rax ja 0x9330d movq -0x90(%rbp), %rax leaq 0x1583a1(%rip), %rcx # 0x1eb68c movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax jmp 0x9330f jmp 0x9330f cmpl $0x0, -0x3c(%rbp) setne %al xorb $-0x1, %al andb $0x1, %al movzbl %al, %eax movl %eax, -0x3c(%rbp) jmp 0x9330f jmp 0x9330f jmp 0x93368 jmp 0x93349 cmpq $0x0, -0x30(%rbp) je 0x93323 movq -0x78(%rbp), %rcx movq -0x30(%rbp), %rax movq %rcx, (%rax) movl -0x44(%rbp), %edx movl $0x21, %ecx movl $0x54, %eax cmpl $0x0, %edx cmovel %eax, %ecx movq -0x38(%rbp), %rax movl %ecx, (%rax) movq $0x0, -0x8(%rbp) jmp 0x9354c movl -0x44(%rbp), %ecx movq -0x78(%rbp), %rax movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x78(%rbp) movb $0x1, %al testb $0x1, %al jne 0x932aa jmp 0x93366 jmp 0x93368 movl $0x0, -0x40(%rbp) movq $0x0, -0x70(%rbp) movq -0x78(%rbp), %rax movq %rax, -0x88(%rbp) movslq -0x24(%rbp), %rcx movq $-0x1, %rax xorl %edx, %edx divq %rcx movq %rax, -0x60(%rbp) movslq -0x24(%rbp), %rcx movq $-0x1, %rax xorl %edx, %edx divq %rcx movl %edx, %eax movl %eax, -0x64(%rbp) movq -0x58(%rbp), %rax movq -0x10(%rbp), %rdi movq -0x78(%rbp), %rdx movq -0x80(%rbp), %rcx leaq -0x50(%rbp), %rsi callq *%rax movl %eax, -0x44(%rbp) cmpl $0x0, %eax jle 0x93495 movl -0x44(%rbp), %ecx movq -0x78(%rbp), %rax movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x78(%rbp) cmpq $0x30, -0x50(%rbp) jb 0x933fa cmpq $0x39, -0x50(%rbp) ja 0x933fa movq -0x50(%rbp), %rax subq $0x30, %rax movq %rax, -0x50(%rbp) jmp 0x93443 cmpq $0x41, -0x50(%rbp) jb 0x9341a cmpq $0x5a, -0x50(%rbp) ja 0x9341a movq -0x50(%rbp), %rax subq $0x41, %rax addq $0xa, %rax movq %rax, -0x50(%rbp) jmp 0x93441 cmpq $0x61, -0x50(%rbp) jb 0x9343a cmpq $0x7a, -0x50(%rbp) ja 0x9343a movq -0x50(%rbp), %rax subq $0x61, %rax addq $0xa, %rax movq %rax, -0x50(%rbp) jmp 0x9343f jmp 0x934d4 jmp 0x93441 jmp 0x93443 movq -0x50(%rbp), %rax cmpl -0x24(%rbp), %eax jl 0x93451 jmp 0x934d4 movq -0x70(%rbp), %rax cmpq -0x60(%rbp), %rax ja 0x93471 movq -0x70(%rbp), %rax cmpq -0x60(%rbp), %rax jne 0x9347a movq -0x50(%rbp), %rax movl -0x64(%rbp), %ecx cmpq %rcx, %rax jbe 0x9347a movl $0x1, -0x40(%rbp) jmp 0x93493 movslq -0x24(%rbp), %rax imulq -0x70(%rbp), %rax movq %rax, -0x70(%rbp) movq -0x50(%rbp), %rax addq -0x70(%rbp), %rax movq %rax, -0x70(%rbp) jmp 0x934c6 cmpl $0x0, -0x44(%rbp) jne 0x934c4 cmpq $0x0, -0x30(%rbp) je 0x934ad movq -0x78(%rbp), %rcx movq -0x30(%rbp), %rax movq %rcx, (%rax) movq -0x38(%rbp), %rax movl $0x54, (%rax) movq $0x0, -0x8(%rbp) jmp 0x9354c jmp 0x934d4 jmp 0x934c8 movb $0x1, %al testb $0x1, %al jne 0x933ab jmp 0x934d4 cmpq $0x0, -0x30(%rbp) je 0x934e6 movq -0x78(%rbp), %rcx movq -0x30(%rbp), %rax movq %rcx, (%rax) movq -0x78(%rbp), %rax cmpq -0x88(%rbp), %rax jne 0x93507 movq -0x38(%rbp), %rax movl $0x21, (%rax) movq $0x0, -0x8(%rbp) jmp 0x9354c cmpl $0x0, -0x40(%rbp) je 0x93521 movq -0x38(%rbp), %rax movl $0x22, (%rax) movq $-0x1, -0x8(%rbp) jmp 0x9354c cmpl $0x0, -0x3c(%rbp) je 0x93536 xorl %eax, %eax subq -0x70(%rbp), %rax movq %rax, -0x98(%rbp) jmp 0x93541 movq -0x70(%rbp), %rax movq %rax, -0x98(%rbp) movq -0x98(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0xa0, %rsp popq %rbp retq nopl (%rax)
my_strntoull_mb2_or_mb4: push rbp mov rbp, rsp sub rsp, 0A0h 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 [rbp+var_3C], 0 mov rax, [rbp+var_10] mov rax, [rax+0B8h] mov rax, [rax+28h] mov [rbp+var_58], rax mov rax, [rbp+var_18] mov [rbp+var_78], rax mov rax, [rbp+var_18] add rax, [rbp+var_20] mov [rbp+var_80], rax mov rax, [rbp+var_38] mov dword ptr [rax], 0 loc_932AA: mov rax, [rbp+var_58] mov rdi, [rbp+var_10] mov rdx, [rbp+var_78] mov rcx, [rbp+var_80] lea rsi, [rbp+var_50] call rax mov [rbp+var_44], eax cmp eax, 0 jle short loc_93311 mov rax, [rbp+var_50] add rax, 0FFFFFFFFFFFFFFF7h; switch 37 cases mov [rbp+var_90], rax sub rax, 24h ja short def_932F2; jumptable 00000000000932F2 default case, cases 10-31,33-42,44 mov rax, [rbp+var_90] lea rcx, jpt_932F2 movsxd rax, ds:(jpt_932F2 - 1EB68Ch)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_932F4: jmp short loc_9330F; jumptable 00000000000932F2 case 32 loc_932F6: jmp short loc_9330F; jumptable 00000000000932F2 case 9 loc_932F8: cmp [rbp+var_3C], 0; jumptable 00000000000932F2 case 45 setnz al xor al, 0FFh and al, 1 movzx eax, al mov [rbp+var_3C], eax jmp short loc_9330F loc_9330B: jmp short loc_9330F; jumptable 00000000000932F2 case 43 def_932F2: jmp short loc_93368; jumptable 00000000000932F2 default case, cases 10-31,33-42,44 loc_9330F: jmp short loc_93349 loc_93311: cmp [rbp+var_30], 0 jz short loc_93323 mov rcx, [rbp+var_78] mov rax, [rbp+var_30] mov [rax], rcx loc_93323: mov edx, [rbp+var_44] mov ecx, 21h ; '!' mov eax, 54h ; 'T' cmp edx, 0 cmovz ecx, eax mov rax, [rbp+var_38] mov [rax], ecx mov [rbp+var_8], 0 jmp loc_9354C loc_93349: mov ecx, [rbp+var_44] mov rax, [rbp+var_78] movsxd rcx, ecx add rax, rcx mov [rbp+var_78], rax mov al, 1 test al, 1 jnz loc_932AA jmp short $+2 loc_93366: jmp short $+2 loc_93368: mov [rbp+var_40], 0 mov [rbp+var_70], 0 mov rax, [rbp+var_78] mov [rbp+var_88], rax movsxd rcx, [rbp+var_24] mov rax, 0FFFFFFFFFFFFFFFFh xor edx, edx div rcx mov [rbp+var_60], rax movsxd rcx, [rbp+var_24] mov rax, 0FFFFFFFFFFFFFFFFh xor edx, edx div rcx mov eax, edx mov [rbp+var_64], eax loc_933AB: mov rax, [rbp+var_58] mov rdi, [rbp+var_10] mov rdx, [rbp+var_78] mov rcx, [rbp+var_80] lea rsi, [rbp+var_50] call rax mov [rbp+var_44], eax cmp eax, 0 jle loc_93495 mov ecx, [rbp+var_44] mov rax, [rbp+var_78] movsxd rcx, ecx add rax, rcx mov [rbp+var_78], rax cmp [rbp+var_50], 30h ; '0' jb short loc_933FA cmp [rbp+var_50], 39h ; '9' ja short loc_933FA mov rax, [rbp+var_50] sub rax, 30h ; '0' mov [rbp+var_50], rax jmp short loc_93443 loc_933FA: cmp [rbp+var_50], 41h ; 'A' jb short loc_9341A cmp [rbp+var_50], 5Ah ; 'Z' ja short loc_9341A mov rax, [rbp+var_50] sub rax, 41h ; 'A' add rax, 0Ah mov [rbp+var_50], rax jmp short loc_93441 loc_9341A: cmp [rbp+var_50], 61h ; 'a' jb short loc_9343A cmp [rbp+var_50], 7Ah ; 'z' ja short loc_9343A mov rax, [rbp+var_50] sub rax, 61h ; 'a' add rax, 0Ah mov [rbp+var_50], rax jmp short loc_9343F loc_9343A: jmp loc_934D4 loc_9343F: jmp short $+2 loc_93441: jmp short $+2 loc_93443: mov rax, [rbp+var_50] cmp eax, [rbp+var_24] jl short loc_93451 jmp loc_934D4 loc_93451: mov rax, [rbp+var_70] cmp rax, [rbp+var_60] ja short loc_93471 mov rax, [rbp+var_70] cmp rax, [rbp+var_60] jnz short loc_9347A mov rax, [rbp+var_50] mov ecx, [rbp+var_64] cmp rax, rcx jbe short loc_9347A loc_93471: mov [rbp+var_40], 1 jmp short loc_93493 loc_9347A: movsxd rax, [rbp+var_24] imul rax, [rbp+var_70] mov [rbp+var_70], rax mov rax, [rbp+var_50] add rax, [rbp+var_70] mov [rbp+var_70], rax loc_93493: jmp short loc_934C6 loc_93495: cmp [rbp+var_44], 0 jnz short loc_934C4 cmp [rbp+var_30], 0 jz short loc_934AD mov rcx, [rbp+var_78] mov rax, [rbp+var_30] mov [rax], rcx loc_934AD: mov rax, [rbp+var_38] mov dword ptr [rax], 54h ; 'T' mov [rbp+var_8], 0 jmp loc_9354C loc_934C4: jmp short loc_934D4 loc_934C6: jmp short $+2 loc_934C8: mov al, 1 test al, 1 jnz loc_933AB jmp short $+2 loc_934D4: cmp [rbp+var_30], 0 jz short loc_934E6 mov rcx, [rbp+var_78] mov rax, [rbp+var_30] mov [rax], rcx loc_934E6: mov rax, [rbp+var_78] cmp rax, [rbp+var_88] jnz short loc_93507 mov rax, [rbp+var_38] mov dword ptr [rax], 21h ; '!' mov [rbp+var_8], 0 jmp short loc_9354C loc_93507: cmp [rbp+var_40], 0 jz short loc_93521 mov rax, [rbp+var_38] mov dword ptr [rax], 22h ; '"' mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh jmp short loc_9354C loc_93521: cmp [rbp+var_3C], 0 jz short loc_93536 xor eax, eax sub rax, [rbp+var_70] mov [rbp+var_98], rax jmp short loc_93541 loc_93536: mov rax, [rbp+var_70] mov [rbp+var_98], rax loc_93541: mov rax, [rbp+var_98] mov [rbp+var_8], rax loc_9354C: mov rax, [rbp+var_8] add rsp, 0A0h pop rbp retn
long long my_strntoull_mb2_or_mb4(long long a1, long long a2, long long a3, int a4, _QWORD *a5, int *a6) { int v6; // ecx long long v9; // [rsp+18h] [rbp-88h] long long v10; // [rsp+20h] [rbp-80h] long long v11; // [rsp+28h] [rbp-78h] unsigned long long v12; // [rsp+30h] [rbp-70h] unsigned int v13; // [rsp+3Ch] [rbp-64h] unsigned long long v14; // [rsp+40h] [rbp-60h] long long ( *v15)(long long, unsigned long long *, long long, long long); // [rsp+48h] [rbp-58h] unsigned long long v16; // [rsp+50h] [rbp-50h] BYREF int v17; // [rsp+5Ch] [rbp-44h] int v18; // [rsp+60h] [rbp-40h] BOOL v19; // [rsp+64h] [rbp-3Ch] int *v20; // [rsp+68h] [rbp-38h] _QWORD *v21; // [rsp+70h] [rbp-30h] int v22; // [rsp+7Ch] [rbp-24h] long long v23; // [rsp+80h] [rbp-20h] long long v24; // [rsp+88h] [rbp-18h] long long v25; // [rsp+90h] [rbp-10h] v25 = a1; v24 = a2; v23 = a3; v22 = a4; v21 = a5; v20 = a6; v19 = 0; v15 = *(long long ( **)(long long, unsigned long long *, long long, long long))(*(_QWORD *)(a1 + 184) + 40LL); v11 = a2; v10 = a3 + a2; *a6 = 0; while ( 2 ) { v17 = v15(v25, &v16, v11, v10); if ( v17 <= 0 ) { if ( v21 ) *v21 = v11; v6 = 33; if ( !v17 ) v6 = 84; *v20 = v6; return 0LL; } else { switch ( v16 ) { case 9uLL: case 0x20uLL: case 0x2BuLL: goto LABEL_10; case 0x2DuLL: v19 = !v19; LABEL_10: v11 += v17; continue; default: v18 = 0; v12 = 0LL; v9 = v11; v14 = 0xFFFFFFFFFFFFFFFFLL / v22; v13 = 0xFFFFFFFFFFFFFFFFLL % v22; break; } while ( 1 ) { v17 = v15(v25, &v16, v11, v10); if ( v17 <= 0 ) break; v11 += v17; if ( v16 < 0x30 || v16 > 0x39 ) { if ( v16 < 0x41 || v16 > 0x5A ) { if ( v16 < 0x61 || v16 > 0x7A ) goto LABEL_33; v16 = v16 - 97 + 10; } else { v16 = v16 - 65 + 10; } } else { v16 -= 48LL; } if ( (int)v16 >= v22 ) goto LABEL_33; if ( v12 > v14 || v12 == v14 && v16 > v13 ) v18 = 1; else v12 = v12 * v22 + v16; } if ( v17 ) { LABEL_33: if ( v21 ) *v21 = v11; if ( v11 == v9 ) { *v20 = 33; return 0LL; } else if ( v18 ) { *v20 = 34; return -1LL; } else if ( v19 ) { return -(long long)v12; } else { return v12; } } if ( v21 ) *v21 = v11; *v20 = 84; return 0LL; } } }
my_strntoull_mb2_or_mb4: PUSH RBP MOV RBP,RSP SUB RSP,0xa0 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 dword ptr [RBP + -0x3c],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0xb8] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x58],RAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x18] ADD RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x80],RAX MOV RAX,qword ptr [RBP + -0x38] MOV dword ptr [RAX],0x0 LAB_001932aa: MOV RAX,qword ptr [RBP + -0x58] MOV RDI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x78] MOV RCX,qword ptr [RBP + -0x80] LEA RSI,[RBP + -0x50] CALL RAX MOV dword ptr [RBP + -0x44],EAX CMP EAX,0x0 JLE 0x00193311 MOV RAX,qword ptr [RBP + -0x50] ADD RAX,-0x9 MOV qword ptr [RBP + -0x90],RAX SUB RAX,0x24 JA 0x0019330d MOV RAX,qword ptr [RBP + -0x90] LEA RCX,[0x2eb68c] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_20: JMP 0x0019330f caseD_9: JMP 0x0019330f caseD_2d: CMP dword ptr [RBP + -0x3c],0x0 SETNZ AL XOR AL,0xff AND AL,0x1 MOVZX EAX,AL MOV dword ptr [RBP + -0x3c],EAX JMP 0x0019330f caseD_2b: JMP 0x0019330f caseD_a: JMP 0x00193368 LAB_0019330f: JMP 0x00193349 LAB_00193311: CMP qword ptr [RBP + -0x30],0x0 JZ 0x00193323 MOV RCX,qword ptr [RBP + -0x78] MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RAX],RCX LAB_00193323: MOV EDX,dword ptr [RBP + -0x44] MOV ECX,0x21 MOV EAX,0x54 CMP EDX,0x0 CMOVZ ECX,EAX MOV RAX,qword ptr [RBP + -0x38] MOV dword ptr [RAX],ECX MOV qword ptr [RBP + -0x8],0x0 JMP 0x0019354c LAB_00193349: MOV ECX,dword ptr [RBP + -0x44] MOV RAX,qword ptr [RBP + -0x78] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x78],RAX MOV AL,0x1 TEST AL,0x1 JNZ 0x001932aa JMP 0x00193366 LAB_00193366: JMP 0x00193368 LAB_00193368: MOV dword ptr [RBP + -0x40],0x0 MOV qword ptr [RBP + -0x70],0x0 MOV RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0x88],RAX MOVSXD RCX,dword ptr [RBP + -0x24] MOV RAX,-0x1 XOR EDX,EDX DIV RCX MOV qword ptr [RBP + -0x60],RAX MOVSXD RCX,dword ptr [RBP + -0x24] MOV RAX,-0x1 XOR EDX,EDX DIV RCX MOV EAX,EDX MOV dword ptr [RBP + -0x64],EAX LAB_001933ab: MOV RAX,qword ptr [RBP + -0x58] MOV RDI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x78] MOV RCX,qword ptr [RBP + -0x80] LEA RSI,[RBP + -0x50] CALL RAX MOV dword ptr [RBP + -0x44],EAX CMP EAX,0x0 JLE 0x00193495 MOV ECX,dword ptr [RBP + -0x44] MOV RAX,qword ptr [RBP + -0x78] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x78],RAX CMP qword ptr [RBP + -0x50],0x30 JC 0x001933fa CMP qword ptr [RBP + -0x50],0x39 JA 0x001933fa MOV RAX,qword ptr [RBP + -0x50] SUB RAX,0x30 MOV qword ptr [RBP + -0x50],RAX JMP 0x00193443 LAB_001933fa: CMP qword ptr [RBP + -0x50],0x41 JC 0x0019341a CMP qword ptr [RBP + -0x50],0x5a JA 0x0019341a MOV RAX,qword ptr [RBP + -0x50] SUB RAX,0x41 ADD RAX,0xa MOV qword ptr [RBP + -0x50],RAX JMP 0x00193441 LAB_0019341a: CMP qword ptr [RBP + -0x50],0x61 JC 0x0019343a CMP qword ptr [RBP + -0x50],0x7a JA 0x0019343a MOV RAX,qword ptr [RBP + -0x50] SUB RAX,0x61 ADD RAX,0xa MOV qword ptr [RBP + -0x50],RAX JMP 0x0019343f LAB_0019343a: JMP 0x001934d4 LAB_0019343f: JMP 0x00193441 LAB_00193441: JMP 0x00193443 LAB_00193443: MOV RAX,qword ptr [RBP + -0x50] CMP EAX,dword ptr [RBP + -0x24] JL 0x00193451 JMP 0x001934d4 LAB_00193451: MOV RAX,qword ptr [RBP + -0x70] CMP RAX,qword ptr [RBP + -0x60] JA 0x00193471 MOV RAX,qword ptr [RBP + -0x70] CMP RAX,qword ptr [RBP + -0x60] JNZ 0x0019347a MOV RAX,qword ptr [RBP + -0x50] MOV ECX,dword ptr [RBP + -0x64] CMP RAX,RCX JBE 0x0019347a LAB_00193471: MOV dword ptr [RBP + -0x40],0x1 JMP 0x00193493 LAB_0019347a: MOVSXD RAX,dword ptr [RBP + -0x24] IMUL RAX,qword ptr [RBP + -0x70] MOV qword ptr [RBP + -0x70],RAX MOV RAX,qword ptr [RBP + -0x50] ADD RAX,qword ptr [RBP + -0x70] MOV qword ptr [RBP + -0x70],RAX LAB_00193493: JMP 0x001934c6 LAB_00193495: CMP dword ptr [RBP + -0x44],0x0 JNZ 0x001934c4 CMP qword ptr [RBP + -0x30],0x0 JZ 0x001934ad MOV RCX,qword ptr [RBP + -0x78] MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RAX],RCX LAB_001934ad: MOV RAX,qword ptr [RBP + -0x38] MOV dword ptr [RAX],0x54 MOV qword ptr [RBP + -0x8],0x0 JMP 0x0019354c LAB_001934c4: JMP 0x001934d4 LAB_001934c6: JMP 0x001934c8 LAB_001934c8: MOV AL,0x1 TEST AL,0x1 JNZ 0x001933ab JMP 0x001934d4 LAB_001934d4: CMP qword ptr [RBP + -0x30],0x0 JZ 0x001934e6 MOV RCX,qword ptr [RBP + -0x78] MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RAX],RCX LAB_001934e6: MOV RAX,qword ptr [RBP + -0x78] CMP RAX,qword ptr [RBP + -0x88] JNZ 0x00193507 MOV RAX,qword ptr [RBP + -0x38] MOV dword ptr [RAX],0x21 MOV qword ptr [RBP + -0x8],0x0 JMP 0x0019354c LAB_00193507: CMP dword ptr [RBP + -0x40],0x0 JZ 0x00193521 MOV RAX,qword ptr [RBP + -0x38] MOV dword ptr [RAX],0x22 MOV qword ptr [RBP + -0x8],-0x1 JMP 0x0019354c LAB_00193521: CMP dword ptr [RBP + -0x3c],0x0 JZ 0x00193536 XOR EAX,EAX SUB RAX,qword ptr [RBP + -0x70] MOV qword ptr [RBP + -0x98],RAX JMP 0x00193541 LAB_00193536: MOV RAX,qword ptr [RBP + -0x70] MOV qword ptr [RBP + -0x98],RAX LAB_00193541: MOV RAX,qword ptr [RBP + -0x98] MOV qword ptr [RBP + -0x8],RAX LAB_0019354c: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0xa0 POP RBP RET
/* WARNING: Removing unreachable block (ram,0x00193364) */ /* WARNING: Removing unreachable block (ram,0x001934d2) */ ulong my_strntoull_mb2_or_mb4 (long param_1,long param_2,long param_3,int param_4,long *param_5, int4 *param_6) { code *pcVar1; int1 auVar2 [16]; int1 auVar3 [16]; long lVar4; ulong uVar5; int4 uVar6; ulong local_a0; long local_80; ulong local_78; ulong local_58; int local_4c; int local_48; uint local_44; int4 *local_40; long *local_38; int local_2c; long local_28; long local_20; long local_18; ulong local_10; local_44 = 0; pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28); *param_6 = 0; local_80 = param_2; local_40 = param_6; local_38 = param_5; local_2c = param_4; local_28 = param_3; local_20 = param_2; local_18 = param_1; do { lVar4 = local_80; local_4c = (*pcVar1)(local_18,&local_58,local_80,param_2 + param_3); if (local_4c < 1) { if (local_38 != (long *)0x0) { *local_38 = local_80; } uVar6 = 0x21; if (local_4c == 0) { uVar6 = 0x54; } *local_40 = uVar6; return 0; } switch(local_58) { case 9: break; default: local_48 = 0; local_78 = 0; auVar2._8_8_ = 0; auVar2._0_8_ = (long)local_2c; uVar5 = SUB168((ZEXT816(0) << 0x40 | ZEXT816(0xffffffffffffffff)) / auVar2,0); auVar3._8_8_ = 0; auVar3._0_8_ = (long)local_2c; goto LAB_001933ab; case 0x20: break; case 0x2b: break; case 0x2d: local_44 = (uint)((local_44 != 0 ^ 0xffU) & 1); } local_80 = local_80 + local_4c; } while( true ); LAB_001933ab: local_4c = (*pcVar1)(local_18,&local_58,local_80,param_2 + param_3); if (local_4c < 1) { if (local_4c == 0) { if (local_38 != (long *)0x0) { *local_38 = local_80; } *local_40 = 0x54; local_10 = 0; } else { LAB_001934d4: if (local_38 != (long *)0x0) { *local_38 = local_80; } if (local_80 == lVar4) { *local_40 = 0x21; local_10 = 0; } else if (local_48 == 0) { if (local_44 == 0) { local_a0 = local_78; } else { local_a0 = -local_78; } local_10 = local_a0; } else { *local_40 = 0x22; local_10 = 0xffffffffffffffff; } } return local_10; } local_80 = local_80 + local_4c; if ((local_58 < 0x30) || (0x39 < local_58)) { if ((local_58 < 0x41) || (0x5a < local_58)) { if ((local_58 < 0x61) || (0x7a < local_58)) goto LAB_001934d4; local_58 = local_58 - 0x57; } else { local_58 = local_58 - 0x37; } } else { local_58 = local_58 - 0x30; } if (local_2c <= (int)local_58) goto LAB_001934d4; if ((uVar5 < local_78) || ((local_78 == uVar5 && (SUB164((ZEXT816(0) << 0x40 | ZEXT816(0xffffffffffffffff)) % auVar3,0) < local_58)))) { local_48 = 1; } else { local_78 = local_58 + (long)local_2c * local_78; } goto LAB_001933ab; }
56,873
R3D_SetLightEnergy
r3d/src/r3d_lighting.c
void R3D_SetLightEnergy(R3D_Light id, float energy) { r3d_get_and_check_light(light, id); light->energy = energy; }
O3
c
R3D_SetLightEnergy: pushq %rbp movq %rsp, %rbp movl %edi, %edx testl %edi, %edi je 0xbe069 leaq 0xf1bc1(%rip), %rax # 0x1afbf0 cmpl %edx, 0x168(%rax) jbe 0xbe069 movq 0x128(%rax), %rsi leal -0x1(%rdx), %ecx cmpb $0x1, (%rsi,%rcx) jne 0xbe069 movq 0x108(%rax), %rsi cmpq %rcx, 0x110(%rax) setbe %dil testq %rsi, %rsi sete %r8b orb %dil, %r8b cmpb $0x1, %r8b jne 0xbe07d leaq 0x53f3c(%rip), %rsi # 0x111fac movl $0x5, %edi xorl %eax, %eax popq %rbp jmp 0xa9c31 imulq 0x120(%rax), %rcx movss %xmm0, 0x90(%rsi,%rcx) popq %rbp retq
R3D_SetLightEnergy: push rbp mov rbp, rsp mov edx, edi test edi, edi jz short loc_BE069 lea rax, R3D cmp [rax+168h], edx jbe short loc_BE069 mov rsi, [rax+128h] lea ecx, [rdx-1] cmp byte ptr [rsi+rcx], 1 jnz short loc_BE069 mov rsi, [rax+108h] cmp [rax+110h], rcx setbe dil test rsi, rsi setz r8b or r8b, dil cmp r8b, 1 jnz short loc_BE07D loc_BE069: lea rsi, aLightIdIIsNotV; "Light [ID %i] is not valid" mov edi, 5 xor eax, eax pop rbp jmp TraceLog loc_BE07D: imul rcx, [rax+120h] movss dword ptr [rsi+rcx+90h], xmm0 pop rbp retn
void R3D_SetLightEnergy(unsigned int a1, float a2) { unsigned long long v2; // rcx long long v3; // rsi if ( a1 && *((_DWORD *)&R3D + 90) > a1 && (v2 = a1 - 1, *(_BYTE *)(*((_QWORD *)&R3D + 37) + v2) == 1) && (v3 = *((_QWORD *)&R3D + 33), *((_QWORD *)&R3D + 34) > v2 && v3 != 0) ) { *(float *)(v3 + *((_QWORD *)&R3D + 36) * v2 + 144) = a2; } else { TraceLog(5, (long long)"Light [ID %i] is not valid", a1); } }
R3D_SetLightEnergy: PUSH RBP MOV RBP,RSP MOV EDX,EDI TEST EDI,EDI JZ 0x001be069 LEA RAX,[0x2afbf0] CMP dword ptr [RAX + 0x168],EDX JBE 0x001be069 MOV RSI,qword ptr [RAX + 0x128] LEA ECX,[RDX + -0x1] CMP byte ptr [RSI + RCX*0x1],0x1 JNZ 0x001be069 MOV RSI,qword ptr [RAX + 0x108] CMP qword ptr [RAX + 0x110],RCX SETBE DIL TEST RSI,RSI SETZ R8B OR R8B,DIL CMP R8B,0x1 JNZ 0x001be07d LAB_001be069: LEA RSI,[0x211fac] MOV EDI,0x5 XOR EAX,EAX POP RBP JMP 0x001a9c31 LAB_001be07d: IMUL RCX,qword ptr [RAX + 0x120] MOVSS dword ptr [RSI + RCX*0x1 + 0x90],XMM0 POP RBP RET
void R3D_SetLightEnergy(int4 param_1,uint param_2) { ulong uVar1; if (((param_2 != 0) && (param_2 < DAT_002afd58)) && (uVar1 = (ulong)(param_2 - 1), *(char *)(DAT_002afd18 + uVar1) == '\x01')) { if (DAT_002afcf8 != 0 && uVar1 < DAT_002afd00) { *(int4 *)(DAT_002afcf8 + 0x90 + uVar1 * DAT_002afd10) = param_1; return; } } TraceLog(5,"Light [ID %i] is not valid"); return; }
56,874
minja::Value::to_str[abi:cxx11]() const
monkey531[P]llama/common/minja.hpp
std::string to_str() const { if (is_string()) return get<std::string>(); if (is_number_integer()) return std::to_string(get<int64_t>()); if (is_number_float()) return std::to_string(get<double>()); if (is_boolean()) return get<bool>() ? "True" : "False"; if (is_null()) return "None"; return dump(); }
O2
cpp
minja::Value::to_str[abi:cxx11]() const: pushq %r14 pushq %rbx pushq %rax movq %rsi, %r14 movq %rdi, %rbx movzbl 0x40(%rsi), %eax cmpl $0x3, %eax jne 0x7063f movq %rbx, %rdi movq %r14, %rsi callq 0x63d54 jmp 0x706cd leal -0x5(%rax), %ecx cmpb $0x1, %cl ja 0x7065c movq %r14, %rdi callq 0x63168 movq %rbx, %rdi movq %rax, %rsi callq 0x70f48 jmp 0x706cd cmpl $0x4, %eax je 0x70678 cmpl $0x7, %eax jne 0x7069b movq %r14, %rdi callq 0x6323c movq %rbx, %rdi callq 0x70fa8 jmp 0x706cd movq %r14, %rdi callq 0x63c9e leaq 0x45415(%rip), %rcx # 0xb5a9c leaq 0x45413(%rip), %rsi # 0xb5aa1 testb %al, %al cmovneq %rcx, %rsi leaq 0x7(%rsp), %rdx jmp 0x706b3 movq %r14, %rdi callq 0x6390a testb %al, %al je 0x706bd leaq 0x4580e(%rip), %rsi # 0xb5ebc leaq 0x6(%rsp), %rdx movq %rbx, %rdi callq 0x27852 jmp 0x706cd pushq $-0x1 popq %rdx movq %rbx, %rdi movq %r14, %rsi xorl %ecx, %ecx callq 0x63320 movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r14 retq
_ZNK5minja5Value6to_strB5cxx11Ev: push r14 push rbx push rax mov r14, rsi mov rbx, rdi movzx eax, byte ptr [rsi+40h] cmp eax, 3 jnz short loc_7063F mov rdi, rbx mov rsi, r14 call _ZNK5minja5Value3getINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEET_v; minja::Value::get<std::string>(void) jmp loc_706CD loc_7063F: lea ecx, [rax-5] cmp cl, 1 ja short loc_7065C mov rdi, r14 call _ZNK5minja5Value3getIlEET_v; minja::Value::get<long>(void) mov rdi, rbx; this mov rsi, rax; __int64 call _ZNSt7__cxx119to_stringEl; std::to_string(long) jmp short loc_706CD loc_7065C: cmp eax, 4 jz short loc_70678 cmp eax, 7 jnz short loc_7069B mov rdi, r14 call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void) mov rdi, rbx; this call _ZNSt7__cxx119to_stringEd; std::to_string(double) jmp short loc_706CD loc_70678: mov rdi, r14 call _ZNK5minja5Value3getIbEET_v; minja::Value::get<bool>(void) lea rcx, aTrue_0; "True" lea rsi, aFalse; "False" test al, al cmovnz rsi, rcx lea rdx, [rsp+18h+var_11] jmp short loc_706B3 loc_7069B: mov rdi, r14; this call _ZNK5minja5Value7is_nullEv; minja::Value::is_null(void) test al, al jz short loc_706BD lea rsi, aNone_0; "None" lea rdx, [rsp+18h+var_12] loc_706B3: mov rdi, rbx call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short loc_706CD loc_706BD: push 0FFFFFFFFFFFFFFFFh pop rdx mov rdi, rbx mov rsi, r14 xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) loc_706CD: mov rax, rbx add rsp, 8 pop rbx pop r14 retn
std::__cxx11 * minja::Value::to_str[abi:cxx11](std::__cxx11 *this, minja::Value *a2, double a3) { int v3; // eax long long v4; // rax char v5; // al const char *v6; // rsi v3 = *((unsigned __int8 *)a2 + 64); if ( v3 == 3 ) { minja::Value::get<std::string>((long long)this, a2); } else { if ( (unsigned __int8)(v3 - 5) > 1u ) { if ( v3 == 4 ) { v5 = minja::Value::get<bool>(a2); v6 = "False"; if ( v5 ) v6 = "True"; } else { if ( v3 == 7 ) { minja::Value::get<double>(a2); std::to_string(this, a3); return this; } if ( !minja::Value::is_null(a2) ) { minja::Value::dump[abi:cxx11]((long long)this, (long long)a2, 0xFFFFFFFF, 0); return this; } v6 = "None"; } std::string::basic_string<std::allocator<char>>(this, (long long)v6); return this; } v4 = minja::Value::get<long>(a2); std::to_string(this, v4); } return this; }
to_str[abi:cxx11]: PUSH R14 PUSH RBX PUSH RAX MOV R14,RSI MOV RBX,RDI MOVZX EAX,byte ptr [RSI + 0x40] CMP EAX,0x3 JNZ 0x0017063f MOV RDI,RBX MOV RSI,R14 CALL 0x00163d54 JMP 0x001706cd LAB_0017063f: LEA ECX,[RAX + -0x5] CMP CL,0x1 JA 0x0017065c MOV RDI,R14 CALL 0x00163168 MOV RDI,RBX MOV RSI,RAX CALL 0x00170f48 JMP 0x001706cd LAB_0017065c: CMP EAX,0x4 JZ 0x00170678 CMP EAX,0x7 JNZ 0x0017069b MOV RDI,R14 CALL 0x0016323c MOV RDI,RBX CALL 0x00170fa8 JMP 0x001706cd LAB_00170678: MOV RDI,R14 CALL 0x00163c9e LEA RCX,[0x1b5a9c] LEA RSI,[0x1b5aa1] TEST AL,AL CMOVNZ RSI,RCX LEA RDX,[RSP + 0x7] JMP 0x001706b3 LAB_0017069b: MOV RDI,R14 CALL 0x0016390a TEST AL,AL JZ 0x001706bd LEA RSI,[0x1b5ebc] LEA RDX,[RSP + 0x6] LAB_001706b3: MOV RDI,RBX CALL 0x00127852 JMP 0x001706cd LAB_001706bd: PUSH -0x1 POP RDX MOV RDI,RBX MOV RSI,R14 XOR ECX,ECX CALL 0x00163320 LAB_001706cd: MOV RAX,RBX ADD RSP,0x8 POP RBX POP R14 RET
/* minja::Value::to_str[abi:cxx11]() const */ void minja::Value::to_str_abi_cxx11_(void) { Value VVar1; bool bVar2; char cVar3; long lVar4; allocator *paVar5; Value *in_RSI; char *pcVar6; __cxx11 *in_RDI; double dVar7; allocator local_12; allocator local_11; VVar1 = in_RSI[0x40]; if (VVar1 == (Value)0x3) { get<std::__cxx11::string>(); } else if ((byte)((char)VVar1 - 5U) < 2) { lVar4 = get<long>(in_RSI); std::__cxx11::to_string(in_RDI,lVar4); } else { if (VVar1 == (Value)0x4) { bVar2 = get<bool>(in_RSI); pcVar6 = "False"; if (bVar2) { pcVar6 = "True"; } paVar5 = &local_11; } else { if (VVar1 == (Value)0x7) { dVar7 = get<double>(in_RSI); std::__cxx11::to_string(dVar7); return; } cVar3 = is_null(in_RSI); if (cVar3 == '\0') { dump_abi_cxx11_((int)in_RDI,SUB81(in_RSI,0)); return; } pcVar6 = "None"; paVar5 = &local_12; } std::__cxx11::string::string<std::allocator<char>>((string *)in_RDI,pcVar6,paVar5); } return; }
56,875
minja::TextTemplateToken::TextTemplateToken(minja::Location const&, minja::SpaceHandling, minja::SpaceHandling, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
monkey531[P]llama/common/minja.hpp
TextTemplateToken(const Location & location, SpaceHandling pre, SpaceHandling post, const std::string& t) : TemplateToken(Type::Text, location, pre, post), text(t) {}
O3
cpp
minja::TextTemplateToken::TextTemplateToken(minja::Location const&, minja::SpaceHandling, minja::SpaceHandling, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %rbx movq %rdi, %rbx leaq 0x7faef(%rip), %rax # 0xdbf00 addq $0x10, %rax movq %rax, (%rdi) movq 0x30(%rdi), %rdi leaq 0x40(%rbx), %rax cmpq %rax, %rdi je 0x5c430 movq (%rax), %rsi incq %rsi callq 0x186a0 leaq 0x7ed81(%rip), %rax # 0xdb1b8 addq $0x10, %rax movq %rax, (%rbx) movq 0x18(%rbx), %rdi testq %rdi, %rdi je 0x5c44c callq 0x2f99c movl $0x50, %esi movq %rbx, %rdi popq %rbx jmp 0x186a0
_ZN5minja17TextTemplateTokenD0Ev: push rbx mov rbx, rdi lea rax, _ZTVN5minja17TextTemplateTokenE; `vtable for'minja::TextTemplateToken add rax, 10h mov [rdi], rax mov rdi, [rdi+30h]; void * lea rax, [rbx+40h] cmp rdi, rax jz short loc_5C430 mov rsi, [rax] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_5C430: lea rax, _ZTVN5minja13TemplateTokenE; `vtable for'minja::TemplateToken add rax, 10h mov [rbx], rax mov rdi, [rbx+18h] test rdi, rdi jz short loc_5C44C call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_5C44C: mov esi, 50h ; 'P'; unsigned __int64 mov rdi, rbx; void * pop rbx jmp __ZdlPvm; operator delete(void *,ulong)
void minja::TextTemplateToken::~TextTemplateToken(minja::TextTemplateToken *this) { char *v2; // rdi volatile signed __int32 *v3; // rdi *(_QWORD *)this = &`vtable for'minja::TextTemplateToken + 2; v2 = (char *)*((_QWORD *)this + 6); if ( v2 != (char *)this + 64 ) operator delete(v2, *((_QWORD *)this + 8) + 1LL); *(_QWORD *)this = &`vtable for'minja::TemplateToken + 2; v3 = (volatile signed __int32 *)*((_QWORD *)this + 3); if ( v3 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v3); operator delete(this, 0x50uLL); }
~TextTemplateToken: PUSH RBX MOV RBX,RDI LEA RAX,[0x1dbf00] ADD RAX,0x10 MOV qword ptr [RDI],RAX MOV RDI,qword ptr [RDI + 0x30] LEA RAX,[RBX + 0x40] CMP RDI,RAX JZ 0x0015c430 MOV RSI,qword ptr [RAX] INC RSI CALL 0x001186a0 LAB_0015c430: LEA RAX,[0x1db1b8] ADD RAX,0x10 MOV qword ptr [RBX],RAX MOV RDI,qword ptr [RBX + 0x18] TEST RDI,RDI JZ 0x0015c44c CALL 0x0012f99c LAB_0015c44c: MOV ESI,0x50 MOV RDI,RBX POP RBX JMP 0x001186a0
/* minja::TextTemplateToken::~TextTemplateToken() */ void __thiscall minja::TextTemplateToken::~TextTemplateToken(TextTemplateToken *this) { *(int ***)this = &PTR__TextTemplateToken_001dbf10; if (*(TextTemplateToken **)(this + 0x30) != this + 0x40) { operator_delete(*(TextTemplateToken **)(this + 0x30),*(long *)(this + 0x40) + 1); } *(int ***)this = &PTR__TemplateToken_001db1c8; if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18)); } operator_delete(this,0x50); return; }
56,876
stbi__load_and_postprocess_8bit(stbi__context*, int*, int*, int*, int)
monkey531[P]llama/examples/llava/../../common/stb_image.h
static unsigned char *stbi__load_and_postprocess_8bit(stbi__context *s, int *x, int *y, int *comp, int req_comp) { stbi__result_info ri; void *result = stbi__load_main(s, x, y, comp, req_comp, &ri, 8); if (result == NULL) return NULL; // it is the responsibility of the loaders to make sure we get either 8 or 16 bit. STBI_ASSERT(ri.bits_per_channel == 8 || ri.bits_per_channel == 16); if (ri.bits_per_channel != 8) { result = stbi__convert_16_to_8((stbi__uint16 *) result, *x, *y, req_comp == 0 ? *comp : req_comp); ri.bits_per_channel = 8; } // @TODO: move stbi__convert_format to here if (stbi__vertically_flip_on_load) { int channels = req_comp ? req_comp : *comp; stbi__vertical_flip(result, *x, *y, channels * sizeof(stbi_uc)); } return (unsigned char *) result; }
O1
c
stbi__load_and_postprocess_8bit(stbi__context*, int*, int*, int*, int): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movl %r8d, %ebx movq %rcx, %rbp movq %rdx, %r14 movq %rsi, %r15 movl $0x8, (%rsp) leaq 0x1c(%rsp), %r9 callq 0x35c37 testq %rax, %rax je 0x28d58 movq %rax, %r13 cmpl $0x8, 0x1c(%rsp) je 0x28d89 movl (%r15), %eax movl (%r14), %r12d movl %ebx, %ecx testl %ebx, %ebx jne 0x28d16 movl (%rbp), %ecx movq %rbp, 0x10(%rsp) imull %eax, %r12d imull %ecx, %r12d movslq %r12d, %rdi callq 0x1e000 testq %rax, %rax je 0x28d5d movq %rax, %rbp testl %r12d, %r12d jle 0x28d4e movl %r12d, %eax xorl %ecx, %ecx movb 0x1(%r13,%rcx,2), %dl movb %dl, (%rbp,%rcx) incq %rcx cmpq %rcx, %rax jne 0x28d3d movq %r13, %rdi callq 0x1de70 jmp 0x28d79 xorl %r13d, %r13d jmp 0x28dca movq %fs:0x0, %rax leaq 0xe5853(%rip), %rcx # 0x10e5c3 movq %rcx, -0x20(%rax) xorl %ebp, %ebp movl $0x8, 0x1c(%rsp) movq %rbp, %r13 movq 0x10(%rsp), %rbp movq %fs:0x0, %rax cmpl $0x0, -0x14(%rax) leaq -0x18(%rax), %rax leaq 0x1313fe(%rip), %rcx # 0x15a1a8 cmovneq %rax, %rcx cmpl $0x0, (%rcx) je 0x28dca testl %ebx, %ebx jne 0x28dba movl (%rbp), %ebx movl (%r15), %esi movl (%r14), %edx movq %r13, %rdi movl %ebx, %ecx callq 0x387d4 movq %r13, %rax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ZL31stbi__load_and_postprocess_8bitP13stbi__contextPiS1_S1_i: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov ebx, r8d mov rbp, rcx mov r14, rdx mov r15, rsi mov [rsp+58h+var_58], 8 lea r9, [rsp+58h+var_3C] call _ZL15stbi__load_mainP13stbi__contextPiS1_S1_iP17stbi__result_infoi; stbi__load_main(stbi__context *,int *,int *,int *,int,stbi__result_info *,int) test rax, rax jz short loc_28D58 mov r13, rax cmp [rsp+58h+var_3C], 8 jz loc_28D89 mov eax, [r15] mov r12d, [r14] mov ecx, ebx test ebx, ebx jnz short loc_28D16 mov ecx, [rbp+0] loc_28D16: mov [rsp+58h+var_48], rbp imul r12d, eax imul r12d, ecx movsxd rdi, r12d call _malloc test rax, rax jz short loc_28D5D mov rbp, rax test r12d, r12d jle short loc_28D4E mov eax, r12d xor ecx, ecx loc_28D3D: mov dl, [r13+rcx*2+1] mov [rbp+rcx+0], dl inc rcx cmp rax, rcx jnz short loc_28D3D loc_28D4E: mov rdi, r13 call _free jmp short loc_28D79 loc_28D58: xor r13d, r13d jmp short loc_28DCA loc_28D5D: mov rax, fs:0 lea rcx, aOutofmem; "outofmem" mov [rax-20h], rcx xor ebp, ebp loc_28D79: mov [rsp+58h+var_3C], 8 mov r13, rbp mov rbp, [rsp+58h+var_48] loc_28D89: mov rax, fs:0 cmp dword ptr [rax-14h], 0 lea rax, [rax-18h] lea rcx, _ZL36stbi__vertically_flip_on_load_global; stbi__vertically_flip_on_load_global cmovnz rcx, rax cmp dword ptr [rcx], 0 jz short loc_28DCA test ebx, ebx jnz short loc_28DBA mov ebx, [rbp+0] loc_28DBA: mov esi, [r15]; int mov edx, [r14]; int mov rdi, r13; void * mov ecx, ebx; int call _ZL19stbi__vertical_flipPviii; stbi__vertical_flip(void *,int,int,int) loc_28DCA: mov rax, r13 add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
_BYTE * stbi__load_and_postprocess_8bit(long long a1, int *a2, int *a3, int *a4, long long a5) { int v5; // ebx int *v6; // rbp long long main; // rax _BYTE *v9; // r13 int v10; // ecx int v11; // r12d long long v12; // rax _BYTE *v13; // rbp long long i; // rcx unsigned long long v15; // rax bool v16; // zf int *v17; // rax int *v18; // rcx int *v20; // [rsp+10h] [rbp-48h] int v21[15]; // [rsp+1Ch] [rbp-3Ch] BYREF v5 = a5; v6 = a4; main = stbi__load_main(a1, a2, a3, a4, a5, v21, 8); if ( !main ) return 0LL; v9 = (_BYTE *)main; if ( v21[0] != 8 ) { v10 = v5; if ( !v5 ) v10 = *v6; v20 = v6; v11 = v10 * *a2 * *a3; v12 = malloc(v11); if ( v12 ) { v13 = (_BYTE *)v12; if ( v11 > 0 ) { for ( i = 0LL; i != v11; ++i ) *(_BYTE *)(v12 + i) = v9[2 * i + 1]; } free(v9); } else { *(_QWORD *)(__readfsqword(0) - 32) = "outofmem"; v13 = 0LL; } v21[0] = 8; v9 = v13; v6 = v20; } v15 = __readfsqword(0); v16 = *(_DWORD *)(v15 - 20) == 0; v17 = (int *)(v15 - 24); v18 = &stbi__vertically_flip_on_load_global; if ( !v16 ) v18 = v17; if ( *v18 ) { if ( !v5 ) v5 = *v6; stbi__vertical_flip(v9, *a2, *a3, v5); } return v9; }
stbi__load_and_postprocess_8bit: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV EBX,R8D MOV RBP,RCX MOV R14,RDX MOV R15,RSI MOV dword ptr [RSP],0x8 LEA R9,[RSP + 0x1c] CALL 0x00135c37 TEST RAX,RAX JZ 0x00128d58 MOV R13,RAX CMP dword ptr [RSP + 0x1c],0x8 JZ 0x00128d89 MOV EAX,dword ptr [R15] MOV R12D,dword ptr [R14] MOV ECX,EBX TEST EBX,EBX JNZ 0x00128d16 MOV ECX,dword ptr [RBP] LAB_00128d16: MOV qword ptr [RSP + 0x10],RBP IMUL R12D,EAX IMUL R12D,ECX MOVSXD RDI,R12D CALL 0x0011e000 TEST RAX,RAX JZ 0x00128d5d MOV RBP,RAX TEST R12D,R12D JLE 0x00128d4e MOV EAX,R12D XOR ECX,ECX LAB_00128d3d: MOV DL,byte ptr [R13 + RCX*0x2 + 0x1] MOV byte ptr [RBP + RCX*0x1],DL INC RCX CMP RAX,RCX JNZ 0x00128d3d LAB_00128d4e: MOV RDI,R13 CALL 0x0011de70 JMP 0x00128d79 LAB_00128d58: XOR R13D,R13D JMP 0x00128dca LAB_00128d5d: MOV RAX,qword ptr FS:[0x0] LEA RCX,[0x20e5c3] MOV qword ptr [RAX + -0x20],RCX XOR EBP,EBP LAB_00128d79: MOV dword ptr [RSP + 0x1c],0x8 MOV R13,RBP MOV RBP,qword ptr [RSP + 0x10] LAB_00128d89: MOV RAX,qword ptr FS:[0x0] CMP dword ptr [RAX + -0x14],0x0 LEA RAX,[RAX + -0x18] LEA RCX,[0x25a1a8] CMOVNZ RCX,RAX CMP dword ptr [RCX],0x0 JZ 0x00128dca TEST EBX,EBX JNZ 0x00128dba MOV EBX,dword ptr [RBP] LAB_00128dba: MOV ESI,dword ptr [R15] MOV EDX,dword ptr [R14] MOV RDI,R13 MOV ECX,EBX CALL 0x001387d4 LAB_00128dca: MOV RAX,R13 ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* stbi__load_and_postprocess_8bit(stbi__context*, int*, int*, int*, int) */ void * stbi__load_and_postprocess_8bit (stbi__context *param_1,int *param_2,int *param_3,int *param_4,int param_5) { void *__ptr; void *pvVar1; int iVar2; ulong uVar3; int *piVar4; uint uVar5; long *in_FS_OFFSET; int local_3c [3]; __ptr = (void *)stbi__load_main(param_1,param_2,param_3,param_4,param_5, (stbi__result_info *)local_3c,8); if (__ptr == (void *)0x0) { pvVar1 = (void *)0x0; } else { pvVar1 = __ptr; if (local_3c[0] != 8) { iVar2 = param_5; if (param_5 == 0) { iVar2 = *param_4; } uVar5 = *param_3 * *param_2 * iVar2; pvVar1 = malloc((long)(int)uVar5); if (pvVar1 == (void *)0x0) { *(char **)(*in_FS_OFFSET + -0x20) = "outofmem"; pvVar1 = (void *)0x0; } else { if (0 < (int)uVar5) { uVar3 = 0; do { *(int1 *)((long)pvVar1 + uVar3) = *(int1 *)((long)__ptr + uVar3 * 2 + 1); uVar3 = uVar3 + 1; } while (uVar5 != uVar3); } free(__ptr); } local_3c[0] = 8; } piVar4 = &stbi__vertically_flip_on_load_global; if (*(int *)(*in_FS_OFFSET + -0x14) != 0) { piVar4 = (int *)(*in_FS_OFFSET + -0x18); } if (*piVar4 != 0) { if (param_5 == 0) { param_5 = *param_4; } stbi__vertical_flip(pvVar1,*param_2,*param_3,param_5); } } return pvVar1; }
56,877
tailoring_append_abbreviation
eloqsql/strings/ctype.c
static int tailoring_append_abbreviation(MY_XML_PARSER *st, const char *fmt, size_t len, const char *attr) { size_t clen; const char *attrend= attr + len; my_wc_t wc; for ( ; (clen= scan_one_character(attr, attrend, &wc)) > 0; attr+= clen) { DBUG_ASSERT(attr < attrend); if (tailoring_append(st, fmt, clen, attr) != MY_XML_OK) return MY_XML_ERROR; } return MY_XML_OK; }
O0
c
tailoring_append_abbreviation: 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 -0x28(%rbp), %rax addq -0x20(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x28(%rbp), %rdi movq -0x38(%rbp), %rsi leaq -0x40(%rbp), %rdx callq 0x144c70 movq %rax, -0x30(%rbp) cmpq $0x0, %rax jbe 0x144c56 jmp 0x144c21 jmp 0x144c23 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x30(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0x144710 cmpl $0x0, %eax je 0x144c46 movl $0x1, -0x4(%rbp) jmp 0x144c5d jmp 0x144c48 movq -0x30(%rbp), %rax addq -0x28(%rbp), %rax movq %rax, -0x28(%rbp) jmp 0x144c04 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
tailoring_append_abbreviation: 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_28] add rax, [rbp+var_20] mov [rbp+var_38], rax loc_144C04: mov rdi, [rbp+var_28] mov rsi, [rbp+var_38] lea rdx, [rbp+var_40] call scan_one_character mov [rbp+var_30], rax cmp rax, 0 jbe short loc_144C56 jmp short $+2 loc_144C21: jmp short $+2 loc_144C23: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rdx, [rbp+var_30] mov rcx, [rbp+var_28] call tailoring_append cmp eax, 0 jz short loc_144C46 mov [rbp+var_4], 1 jmp short loc_144C5D loc_144C46: jmp short $+2 loc_144C48: mov rax, [rbp+var_30] add rax, [rbp+var_28] mov [rbp+var_28], rax jmp short loc_144C04 loc_144C56: mov [rbp+var_4], 0 loc_144C5D: mov eax, [rbp+var_4] add rsp, 40h pop rbp retn
long long tailoring_append_abbreviation(long long a1, const char *a2, long long a3, long long a4) { _BYTE v5[8]; // [rsp+0h] [rbp-40h] BYREF long long v6; // [rsp+8h] [rbp-38h] long long v7; // [rsp+10h] [rbp-30h] long long v8; // [rsp+18h] [rbp-28h] long long v9; // [rsp+20h] [rbp-20h] const char *v10; // [rsp+28h] [rbp-18h] long long v11; // [rsp+30h] [rbp-10h] v11 = a1; v10 = a2; v9 = a3; v8 = a4; v6 = a3 + a4; while ( 1 ) { v7 = scan_one_character(v8, v6, v5); if ( !v7 ) break; if ( (unsigned int)tailoring_append(v11, v10, v7, v8) ) return 1; v8 += v7; } return 0; }
_ma_log_add: PUSH RBP MOV RBP,RSP SUB RSP,0x190 MOV AL,R9B MOV R9D,dword ptr [RBP + 0x10] MOV R9,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],R9 MOV qword ptr [RBP + -0x40],RDI MOV dword ptr [RBP + -0x44],ESI MOV qword ptr [RBP + -0x50],RDX MOV dword ptr [RBP + -0x54],ECX MOV dword ptr [RBP + -0x58],R8D MOV byte ptr [RBP + -0x59],AL MOV RAX,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x108],RAX MOV RAX,qword ptr [RBP + -0x50] MOV RCX,qword ptr [RBP + -0x78] SUB RAX,RCX MOV dword ptr [RBP + -0x10c],EAX MOV RAX,qword ptr [RBP + -0x108] MOV RAX,qword ptr [RAX] MOV EAX,dword ptr [RAX + 0x7c0] MOV dword ptr [RBP + -0x110],EAX MOV RAX,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RAX + 0x18] MOV RCX,qword ptr [RBP + -0x108] MOV RCX,qword ptr [RCX] MOV ECX,dword ptr [RCX + 0x7bc] XOR EDX,EDX DIV RCX MOV qword ptr [RBP + -0x120],RAX JMP 0x00144c7b LAB_00144c7b: JMP 0x00144c7d LAB_00144c7d: JMP 0x00144c7f LAB_00144c7f: JMP 0x00144c81 LAB_00144c81: JMP 0x00144c83 LAB_00144c83: JMP 0x00144c85 LAB_00144c85: JMP 0x00144c87 LAB_00144c87: JMP 0x00144c89 LAB_00144c89: JMP 0x00144c8b LAB_00144c8b: JMP 0x00144c8d LAB_00144c8d: JMP 0x00144c8f LAB_00144c8f: LEA RAX,[RBP + -0x30] ADD RAX,0x2 MOV qword ptr [RBP + -0x70],RAX MOV RAX,qword ptr [RBP + -0x70] MOV qword ptr [RBP + -0x128],RAX MOV RAX,qword ptr [RBP + -0x120] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x128] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x120] SHR RAX,0x20 MOV CL,AL MOV RAX,qword ptr [RBP + -0x128] MOV byte ptr [RAX + 0x4],CL MOV RAX,qword ptr [RBP + -0x40] MOV EAX,dword ptr [RAX + 0x24] MOV dword ptr [RBP + -0x118],EAX MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x5 MOV qword ptr [RBP + -0x70],RAX MOV RAX,qword ptr [RBP + -0x70] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x70],RCX MOV byte ptr [RAX],0xa MOV RAX,qword ptr [RBP + -0x78] MOV RCX,qword ptr [RBP + -0x108] MOV RCX,qword ptr [RCX] MOV ECX,dword ptr [RCX + 0x744] SUB ECX,0x2 SUB ECX,0x1 MOV ECX,ECX MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RBP + -0x70] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RBP + -0x70],RDX MOV byte ptr [RAX],CL MOV EAX,dword ptr [RBP + -0x10c] ADD EAX,dword ptr [RBP + -0x54] CMP EAX,dword ptr [RBP + -0x110] JBE 0x00144d73 JMP 0x00144d3d LAB_00144d3d: JMP 0x00144d3f LAB_00144d3f: MOV EAX,dword ptr [RBP + -0x110] SUB EAX,dword ptr [RBP + -0x10c] MOV dword ptr [RBP + -0x54],EAX MOV dword ptr [RBP + -0x58],0x0 MOV RAX,qword ptr [RBP + -0x70] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x70],RCX MOV byte ptr [RAX],0xc MOV EAX,dword ptr [RBP + -0x110] MOV dword ptr [RBP + -0x118],EAX LAB_00144d73: MOV EAX,dword ptr [RBP + -0x118] ADD EAX,dword ptr [RBP + -0x58] CMP EAX,dword ptr [RBP + -0x110] JBE 0x00144de1 JMP 0x00144d86 LAB_00144d86: JMP 0x00144d88 LAB_00144d88: MOV EAX,dword ptr [RBP + -0x118] ADD EAX,dword ptr [RBP + -0x58] SUB EAX,dword ptr [RBP + -0x110] MOV dword ptr [RBP + -0x12c],EAX MOV RAX,qword ptr [RBP + -0x70] MOV byte ptr [RAX],0x7 MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x1 MOV qword ptr [RBP + -0x138],RAX MOV EAX,dword ptr [RBP + -0x12c] MOV CX,AX MOV RAX,qword ptr [RBP + -0x138] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x3 MOV qword ptr [RBP + -0x70],RAX MOV EAX,dword ptr [RBP + -0x110] SUB EAX,dword ptr [RBP + -0x58] MOV dword ptr [RBP + -0x118],EAX LAB_00144de1: MOV EAX,dword ptr [RBP + -0x10c] CMP EAX,dword ptr [RBP + -0x118] JNZ 0x00144e0a MOV RAX,qword ptr [RBP + -0x70] MOV byte ptr [RAX],0x6 MOV EAX,dword ptr [RBP + -0x54] ADD EAX,dword ptr [RBP + -0x118] MOV dword ptr [RBP + -0x118],EAX JMP 0x00144edd LAB_00144e0a: MOV RAX,qword ptr [RBP + -0x70] MOV byte ptr [RAX],0x1 MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x1 MOV qword ptr [RBP + -0x140],RAX MOV EAX,dword ptr [RBP + -0x10c] MOV CX,AX MOV RAX,qword ptr [RBP + -0x140] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x3 MOV qword ptr [RBP + -0x70],RAX CMP dword ptr [RBP + -0x58],0x0 JZ 0x00144eb2 CMP dword ptr [RBP + -0x58],0x0 JGE 0x00144e71 JMP 0x00144e4d LAB_00144e4d: JMP 0x00144e4f LAB_00144e4f: MOV EAX,dword ptr [RBP + -0x10c] SUB EAX,dword ptr [RBP + -0x58] CMP EAX,dword ptr [RBP + -0x118] JBE 0x00144e6f MOV EAX,dword ptr [RBP + -0x10c] SUB EAX,dword ptr [RBP + -0x118] MOV dword ptr [RBP + -0x58],EAX LAB_00144e6f: JMP 0x00144e71 LAB_00144e71: MOV RAX,qword ptr [RBP + -0x70] MOV byte ptr [RAX],0x2 MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x1 MOV qword ptr [RBP + -0x148],RAX MOV EAX,dword ptr [RBP + -0x58] MOV CX,AX MOV RAX,qword ptr [RBP + -0x148] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x3 MOV qword ptr [RBP + -0x70],RAX MOV EAX,dword ptr [RBP + -0x58] ADD EAX,dword ptr [RBP + -0x118] MOV dword ptr [RBP + -0x118],EAX LAB_00144eb2: MOV EAX,dword ptr [RBP + -0x10c] ADD EAX,dword ptr [RBP + -0x54] CMP EAX,dword ptr [RBP + -0x118] JBE 0x00144ed6 JMP 0x00144ec5 LAB_00144ec5: JMP 0x00144ec7 LAB_00144ec7: MOV EAX,dword ptr [RBP + -0x118] SUB EAX,dword ptr [RBP + -0x10c] MOV dword ptr [RBP + -0x54],EAX LAB_00144ed6: MOV RAX,qword ptr [RBP + -0x70] MOV byte ptr [RAX],0x3 LAB_00144edd: JMP 0x00144edf LAB_00144edf: MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x1 MOV qword ptr [RBP + -0x150],RAX MOV EAX,dword ptr [RBP + -0x54] MOV CX,AX MOV RAX,qword ptr [RBP + -0x150] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x3 MOV qword ptr [RBP + -0x70],RAX LEA RAX,[RBP + -0x30] MOV qword ptr [RBP + -0xe0],RAX MOV RAX,qword ptr [RBP + -0x70] LEA RCX,[RBP + -0x30] SUB RAX,RCX MOV EAX,EAX MOV qword ptr [RBP + -0xd8],RAX MOV RAX,qword ptr [RBP + -0x50] MOV qword ptr [RBP + -0xd0],RAX MOV EAX,dword ptr [RBP + -0x54] MOV qword ptr [RBP + -0xc8],RAX MOV dword ptr [RBP + -0x114],0x4 JMP 0x00144f4a LAB_00144f4a: MOV EAX,dword ptr [RBP + -0x118] MOV RCX,qword ptr [RBP + -0x40] CMP EAX,dword ptr [RCX + 0x20] JZ 0x001450af MOV EAX,dword ptr [RBP + -0x118] CMP EAX,dword ptr [RBP + -0x110] JZ 0x001450af MOV RAX,qword ptr [RBP + -0x40] MOV EAX,dword ptr [RAX + 0x20] CMP EAX,dword ptr [RBP + -0x110] JNC 0x00144f8d MOV RAX,qword ptr [RBP + -0x40] MOV EAX,dword ptr [RAX + 0x20] MOV dword ptr [RBP + -0x16c],EAX JMP 0x00144f99 LAB_00144f8d: MOV EAX,dword ptr [RBP + -0x110] MOV dword ptr [RBP + -0x16c],EAX LAB_00144f99: MOV EAX,dword ptr [RBP + -0x16c] SUB EAX,dword ptr [RBP + -0x118] MOV dword ptr [RBP + -0x154],EAX MOV RAX,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RAX + 0x10] MOV ECX,dword ptr [RBP + -0x118] ADD RAX,RCX MOV qword ptr [RBP + -0x160],RAX MOV RAX,qword ptr [RBP + -0x70] MOV byte ptr [RAX],0x6 MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x1 MOV qword ptr [RBP + -0x168],RAX MOV EAX,dword ptr [RBP + -0x154] MOV CX,AX MOV RAX,qword ptr [RBP + -0x168] MOV word ptr [RAX],CX MOV RCX,qword ptr [RBP + -0x70] MOV EAX,dword ptr [RBP + -0x114] MOV EDX,EAX LEA RAX,[RBP + -0x100] SHL RDX,0x4 ADD RAX,RDX MOV qword ptr [RAX],RCX MOV EAX,dword ptr [RBP + -0x114] MOV ECX,EAX LEA RAX,[RBP + -0x100] SHL RCX,0x4 ADD RAX,RCX MOV qword ptr [RAX + 0x8],0x3 MOV RCX,qword ptr [RBP + -0x160] MOV EAX,dword ptr [RBP + -0x114] ADD EAX,0x1 MOV EAX,EAX MOV EDX,EAX LEA RAX,[RBP + -0x100] SHL RDX,0x4 ADD RAX,RDX MOV qword ptr [RAX],RCX MOV EAX,dword ptr [RBP + -0x154] MOV ECX,EAX MOV EAX,dword ptr [RBP + -0x114] ADD EAX,0x1 MOV EAX,EAX MOV EDX,EAX LEA RAX,[RBP + -0x100] SHL RDX,0x4 ADD RAX,RDX MOV qword ptr [RAX + 0x8],RCX MOV RAX,qword ptr [RBP + -0x70] ADD RAX,0x3 MOV qword ptr [RBP + -0x70],RAX MOV EAX,dword ptr [RBP + -0x114] ADD EAX,0x2 MOV dword ptr [RBP + -0x114],EAX MOV EAX,dword ptr [RBP + -0x154] ADD EAX,dword ptr [RBP + -0x118] MOV dword ptr [RBP + -0x118],EAX MOV EAX,dword ptr [RBP + -0x154] ADD EAX,0x3 ADD EAX,dword ptr [RBP + -0x54] MOV dword ptr [RBP + -0x54],EAX LAB_001450af: MOV ECX,dword ptr [RBP + -0x118] MOV RAX,qword ptr [RBP + -0x40] MOV dword ptr [RAX + 0x24],ECX JMP 0x001450be LAB_001450be: MOV RAX,qword ptr [RBP + -0x108] MOV RDX,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x108] MOV RAX,qword ptr [RBP + -0xd8] MOV R8D,EAX ADD R8D,dword ptr [RBP + -0x54] MOV R9D,dword ptr [RBP + -0x114] LEA R10,[RBP + -0x100] LEA RAX,[RBP + -0x30] LEA RDI,[RBP + -0x68] MOV ESI,0xc XOR R11D,R11D MOV qword ptr [RSP],R10 MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x10],0x0 CALL 0x00131e30 CMP AL,0x0 JZ 0x0014511f JMP 0x00145119 LAB_00145119: MOV byte ptr [RBP + -0x31],0xff JMP 0x00145125 LAB_0014511f: JMP 0x00145121 LAB_00145121: MOV byte ptr [RBP + -0x31],0x0 LAB_00145125: MOV AL,byte ptr [RBP + -0x31] MOV byte ptr [RBP + -0x16d],AL MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0014514f MOV AL,byte ptr [RBP + -0x16d] ADD RSP,0x190 POP RBP RET LAB_0014514f: CALL 0x0012a250
int8 _ma_log_add(long *param_1,int4 param_2,int8 param_3,uint param_4,int param_5, int1 param_6) { long *plVar1; int1 *puVar2; char cVar3; uint uVar4; ulong uVar5; int1 *puVar6; long in_FS_OFFSET; uint local_174; uint local_120; int4 local_11c; int1 local_108 [32]; int1 *local_e8; ulong local_e0; int8 local_d8; ulong local_d0; int1 *local_c8; int8 local_c0; long local_b8; ulong local_b0; long local_80; int1 *local_78; int1 local_70 [15]; int1 local_61; int local_60; uint local_5c; int8 local_58; int4 local_4c; long *local_48; int1 local_39; int1 local_38 [2]; int4 local_36; int1 local_32; int1 local_31; int1 local_30; int1 local_2f [31]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_80 = param_1[2]; plVar1 = (long *)*param_1; uVar4 = (int)param_3 - (int)local_80; local_174 = *(uint *)(*plVar1 + 0x7c0); uVar5 = (ulong)param_1[3] / (ulong)*(uint *)(*plVar1 + 0x7bc); local_36 = (int4)uVar5; local_32 = (int1)(uVar5 >> 0x20); local_120 = *(uint *)((long)param_1 + 0x24); local_31 = 10; local_30 = *(int1 *)(local_80 + (ulong)(*(int *)(*plVar1 + 0x744) - 3)); local_78 = local_2f; local_60 = param_5; local_5c = param_4; if (local_174 < uVar4 + param_4) { local_5c = local_174 - uVar4; local_60 = 0; local_78 = local_2f + 1; local_2f[0] = 0xc; local_120 = local_174; } if (local_174 < local_120 + local_60) { *local_78 = 7; *(short *)(local_78 + 1) = ((short)local_120 + (short)local_60) - (short)local_174; local_78 = local_78 + 3; local_120 = local_174 - local_60; } if (uVar4 == local_120) { *local_78 = 6; local_120 = local_5c + local_120; } else { *local_78 = 1; *(short *)(local_78 + 1) = (short)uVar4; puVar2 = local_78 + 3; if (local_60 != 0) { if ((local_60 < 0) && (local_120 < uVar4 - local_60)) { local_60 = uVar4 - local_120; } local_78[3] = 2; *(short *)(local_78 + 4) = (short)local_60; local_120 = local_60 + local_120; puVar2 = local_78 + 6; } local_78 = puVar2; if (local_120 < uVar4 + local_5c) { local_5c = local_120 - uVar4; } *local_78 = 3; } *(short *)(local_78 + 1) = (short)local_5c; puVar6 = local_78 + 3; local_e8 = local_38; uVar4 = (int)puVar6 - (int)local_38; local_e0 = (ulong)uVar4; local_d0 = (ulong)local_5c; local_11c = 4; puVar2 = puVar6; if ((local_120 != *(uint *)(param_1 + 4)) && (local_120 != local_174)) { if (*(uint *)(param_1 + 4) < local_174) { local_174 = *(uint *)(param_1 + 4); } local_174 = local_174 - local_120; local_b8 = param_1[2] + (ulong)local_120; *puVar6 = 6; *(short *)(local_78 + 4) = (short)local_174; local_c0 = 3; local_b0 = (ulong)local_174; local_11c = 6; local_120 = local_174 + local_120; local_5c = local_174 + 3 + local_5c; puVar2 = local_78 + 6; local_c8 = puVar6; } local_78 = puVar2; *(uint *)((long)param_1 + 0x24) = local_120; local_d8 = param_3; local_61 = param_6; local_58 = param_3; local_4c = param_2; local_48 = param_1; cVar3 = translog_write_record (local_70,0xc,plVar1[1],plVar1,uVar4 + local_5c,local_11c,local_108,local_38,0); if (cVar3 == '\0') { local_39 = 0; } else { local_39 = 0xff; } if (*(long *)(in_FS_OFFSET + 0x28) != local_10) { /* WARNING: Subroutine does not return */ __stack_chk_fail(); } return CONCAT71((int7)((ulong)*(long *)(in_FS_OFFSET + 0x28) >> 8),local_39); }
56,878
mi_ft_cmp
eloqsql/storage/myisam/ft_update.c
int _mi_ft_cmp(MI_INFO *info, uint keynr, const uchar *rec1, const uchar *rec2) { FT_SEG_ITERATOR ftsi1, ftsi2; CHARSET_INFO *cs=info->s->keyinfo[keynr].seg->charset; DBUG_ENTER("_mi_ft_cmp"); _mi_ft_segiterator_init(info, keynr, rec1, &ftsi1); _mi_ft_segiterator_init(info, keynr, rec2, &ftsi2); while (_mi_ft_segiterator(&ftsi1) && _mi_ft_segiterator(&ftsi2)) { if ((ftsi1.pos != ftsi2.pos) && (!ftsi1.pos || !ftsi2.pos || ha_compare_text(cs, (uchar*) ftsi1.pos,ftsi1.len, (uchar*) ftsi2.pos,ftsi2.len,0))) DBUG_RETURN(THOSE_TWO_DAMN_KEYS_ARE_REALLY_DIFFERENT); } DBUG_RETURN(GEE_THEY_ARE_ABSOLUTELY_IDENTICAL); }
O3
c
mi_ft_cmp: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x40, %rsp movq (%rdi), %rax movq 0x218(%rax), %rax movl %esi, %esi imulq $0x70, %rsi, %rsi movq 0x28(%rax,%rsi), %r8 movq (%r8), %rbx movzwl 0x8(%rax,%rsi), %eax leaq -0x60(%rbp), %rdi movl %eax, (%rdi) movq %r8, 0x8(%rdi) movq %rdx, 0x10(%rdi) xorl %r14d, %r14d movq %r14, 0x18(%rdi) movl %r14d, 0x4(%rdi) movl %eax, -0x40(%rbp) movq %r8, -0x38(%rbp) movq %rcx, -0x30(%rbp) movq %r14, -0x28(%rbp) movl %r14d, -0x3c(%rbp) callq 0x437aa testl %eax, %eax je 0x43a80 leaq -0x40(%rbp), %r15 leaq -0x60(%rbp), %r12 movq %r15, %rdi callq 0x437aa testl %eax, %eax je 0x43a7d movq -0x48(%rbp), %rsi movq -0x28(%rbp), %rcx cmpq %rcx, %rsi je 0x43a71 movl $0x1, %r14d testq %rsi, %rsi je 0x43a80 testq %rcx, %rcx je 0x43a80 movl -0x5c(%rbp), %edx movl -0x3c(%rbp), %r8d movq %rbx, %rdi xorl %r9d, %r9d callq 0x5a8dc testl %eax, %eax jne 0x43a80 movq %r12, %rdi callq 0x437aa testl %eax, %eax jne 0x43a32 xorl %r14d, %r14d movl %r14d, %eax addq $0x40, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
_mi_ft_cmp: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx sub rsp, 40h mov rax, [rdi] mov rax, [rax+218h] mov esi, esi imul rsi, 70h ; 'p' mov r8, [rax+rsi+28h] mov rbx, [r8] movzx eax, word ptr [rax+rsi+8] lea rdi, [rbp+var_60] mov [rdi], eax mov [rdi+8], r8 mov [rdi+10h], rdx xor r14d, r14d mov [rdi+18h], r14 mov [rdi+4], r14d mov [rbp+var_40], eax mov [rbp+var_38], r8 mov [rbp+var_30], rcx mov [rbp+var_28], r14 mov [rbp+var_3C], r14d call _mi_ft_segiterator test eax, eax jz short loc_43A80 lea r15, [rbp+var_40] lea r12, [rbp+var_60] loc_43A32: mov rdi, r15 call _mi_ft_segiterator test eax, eax jz short loc_43A7D mov rsi, [rbp+var_48] mov rcx, [rbp+var_28] cmp rsi, rcx jz short loc_43A71 mov r14d, 1 test rsi, rsi jz short loc_43A80 test rcx, rcx jz short loc_43A80 mov edx, [rbp+var_5C] mov r8d, [rbp+var_3C] mov rdi, rbx xor r9d, r9d call ha_compare_text test eax, eax jnz short loc_43A80 loc_43A71: mov rdi, r12 call _mi_ft_segiterator test eax, eax jnz short loc_43A32 loc_43A7D: xor r14d, r14d loc_43A80: mov eax, r14d add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long mi_ft_cmp(long long a1, unsigned int a2, long long a3, long long a4) { long long v4; // rax long long v5; // rsi _QWORD *v6; // r8 long long v7; // rbx unsigned int v8; // r14d int v10; // [rsp+0h] [rbp-60h] BYREF unsigned int v11; // [rsp+4h] [rbp-5Ch] _QWORD *v12; // [rsp+8h] [rbp-58h] long long v13; // [rsp+10h] [rbp-50h] long long v14; // [rsp+18h] [rbp-48h] int v15; // [rsp+20h] [rbp-40h] BYREF unsigned int v16; // [rsp+24h] [rbp-3Ch] _QWORD *v17; // [rsp+28h] [rbp-38h] long long v18; // [rsp+30h] [rbp-30h] long long v19; // [rsp+38h] [rbp-28h] v4 = *(_QWORD *)(*(_QWORD *)a1 + 536LL); v5 = 112LL * a2; v6 = *(_QWORD **)(v4 + v5 + 40); v7 = *v6; v10 = *(unsigned __int16 *)(v4 + v5 + 8); v12 = v6; v13 = a3; v8 = 0; v14 = 0LL; v11 = 0; v15 = v10; v17 = v6; v18 = a4; v19 = 0LL; v16 = 0; if ( (unsigned int)mi_ft_segiterator((long long)&v10) ) { do { if ( !(unsigned int)mi_ft_segiterator((long long)&v15) ) break; if ( v14 != v19 ) { v8 = 1; if ( !v14 || !v19 || (unsigned int)ha_compare_text(v7, v14, v11, v19, v16, 0LL) ) return v8; } } while ( (unsigned int)mi_ft_segiterator((long long)&v10) ); return 0; } return v8; }
_mi_ft_cmp: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x40 MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + 0x218] MOV ESI,ESI IMUL RSI,RSI,0x70 MOV R8,qword ptr [RAX + RSI*0x1 + 0x28] MOV RBX,qword ptr [R8] MOVZX EAX,word ptr [RAX + RSI*0x1 + 0x8] LEA RDI,[RBP + -0x60] MOV dword ptr [RDI],EAX MOV qword ptr [RDI + 0x8],R8 MOV qword ptr [RDI + 0x10],RDX XOR R14D,R14D MOV qword ptr [RDI + 0x18],R14 MOV dword ptr [RDI + 0x4],R14D MOV dword ptr [RBP + -0x40],EAX MOV qword ptr [RBP + -0x38],R8 MOV qword ptr [RBP + -0x30],RCX MOV qword ptr [RBP + -0x28],R14 MOV dword ptr [RBP + -0x3c],R14D CALL 0x001437aa TEST EAX,EAX JZ 0x00143a80 LEA R15,[RBP + -0x40] LEA R12,[RBP + -0x60] LAB_00143a32: MOV RDI,R15 CALL 0x001437aa TEST EAX,EAX JZ 0x00143a7d MOV RSI,qword ptr [RBP + -0x48] MOV RCX,qword ptr [RBP + -0x28] CMP RSI,RCX JZ 0x00143a71 MOV R14D,0x1 TEST RSI,RSI JZ 0x00143a80 TEST RCX,RCX JZ 0x00143a80 MOV EDX,dword ptr [RBP + -0x5c] MOV R8D,dword ptr [RBP + -0x3c] MOV RDI,RBX XOR R9D,R9D CALL 0x0015a8dc TEST EAX,EAX JNZ 0x00143a80 LAB_00143a71: MOV RDI,R12 CALL 0x001437aa TEST EAX,EAX JNZ 0x00143a32 LAB_00143a7d: XOR R14D,R14D LAB_00143a80: MOV EAX,R14D ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET
int8 _mi_ft_cmp(long *param_1,uint param_2,int8 param_3,int8 param_4) { int8 uVar1; int iVar2; uint local_68; int4 local_64; int8 *local_60; int8 local_58; long local_50; uint local_48; int4 local_44; int8 *local_40; int8 local_38; long local_30; local_60 = *(int8 **)(*(long *)(*param_1 + 0x218) + 0x28 + (ulong)param_2 * 0x70); uVar1 = *local_60; local_68 = (uint)*(ushort *)(*(long *)(*param_1 + 0x218) + 8 + (ulong)param_2 * 0x70); local_50 = 0; local_64 = 0; local_30 = 0; local_44 = 0; local_58 = param_3; local_48 = local_68; local_40 = local_60; local_38 = param_4; iVar2 = _mi_ft_segiterator(); if (iVar2 != 0) { do { iVar2 = _mi_ft_segiterator(&local_48); if (iVar2 == 0) { return 0; } if (local_50 != local_30) { if (local_50 == 0) { return 1; } if (local_30 == 0) { return 1; } iVar2 = ha_compare_text(uVar1,local_50,local_64,local_30,local_44,0); if (iVar2 != 0) { return 1; } } iVar2 = _mi_ft_segiterator(&local_68); } while (iVar2 != 0); } return 0; }
56,879
(anonymous namespace)::msgpack23_SystemClockTypePacking_Test::~msgpack23_SystemClockTypePacking_Test()
msgpack23/tests/type_packing_tests.cpp
TEST(msgpack23, SystemClockTypePacking) { msgpack23::Packer packer{}; auto const expected = std::chrono::system_clock::now(); auto const data = packer(expected); msgpack23::Unpacker unpacker{data}; decltype(std::chrono::system_clock::now()) actual{}; unpacker(actual); EXPECT_EQ(expected, actual); }
O0
cpp
(anonymous namespace)::msgpack23_SystemClockTypePacking_Test::~msgpack23_SystemClockTypePacking_Test(): pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi callq 0x9f3e0 addq $0x10, %rsp popq %rbp retq nopl (%rax,%rax)
_ZN12_GLOBAL__N_137msgpack23_SystemClockTypePacking_TestD2Ev: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov rdi, [rbp+var_8]; this call _ZN7testing4TestD2Ev; testing::Test::~Test() add rsp, 10h pop rbp retn
void `anonymous namespace'::msgpack23_SystemClockTypePacking_Test::~msgpack23_SystemClockTypePacking_Test( _anonymous_namespace_::msgpack23_SystemClockTypePacking_Test *this) { testing::Test::~Test(this); }
~msgpack23_SystemClockTypePacking_Test: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV RDI,qword ptr [RBP + -0x8] CALL 0x0019f3e0 ADD RSP,0x10 POP RBP RET
/* (anonymous namespace)::msgpack23_SystemClockTypePacking_Test::~msgpack23_SystemClockTypePacking_Test() */ void __thiscall (anonymous_namespace)::msgpack23_SystemClockTypePacking_Test::~msgpack23_SystemClockTypePacking_Test (msgpack23_SystemClockTypePacking_Test *this) { testing::Test::~Test((Test *)this); return; }
56,880
create_control_file
eloqsql/storage/maria/ma_control_file.c
static CONTROL_FILE_ERROR create_control_file(const char *name, int open_flags) { uint32 sum; uchar buffer[CF_CREATE_TIME_TOTAL_SIZE]; ulong rnd1,rnd2; DBUG_ENTER("maria_create_control_file"); if ((control_file_fd= mysql_file_create(key_file_control, name, 0, open_flags, MYF(MY_SYNC_DIR | MY_WME))) < 0) DBUG_RETURN(CONTROL_FILE_UNKNOWN_ERROR); /* Reset variables, as we are creating the file */ cf_create_time_size= CF_CREATE_TIME_TOTAL_SIZE; cf_changeable_size= CF_CHANGEABLE_TOTAL_SIZE; /* Create unique uuid for the control file */ my_random_bytes((uchar *)&rnd1, sizeof (rnd1)); my_random_bytes((uchar *)&rnd2, sizeof (rnd2)); my_uuid_init(rnd1, rnd2); my_uuid(maria_uuid); /* Prepare and write the file header */ memcpy(buffer, CF_MAGIC_STRING, CF_MAGIC_STRING_SIZE); buffer[CF_VERSION_OFFSET]= CONTROL_FILE_VERSION; memcpy(buffer + CF_UUID_OFFSET, maria_uuid, CF_UUID_SIZE); int2store(buffer + CF_CREATE_TIME_SIZE_OFFSET, cf_create_time_size); int2store(buffer + CF_CHANGEABLE_SIZE_OFFSET, cf_changeable_size); /* Write create time variables */ int2store(buffer + CF_BLOCKSIZE_OFFSET, maria_block_size); /* Store checksum for create time parts */ sum= (uint32) my_checksum(0, buffer, cf_create_time_size - CF_CHECKSUM_SIZE); int4store(buffer + cf_create_time_size - CF_CHECKSUM_SIZE, sum); if (my_pwrite(control_file_fd, buffer, cf_create_time_size, 0, MYF(MY_FNABP | MY_WME))) DBUG_RETURN(CONTROL_FILE_UNKNOWN_ERROR); /* To be safer we should make sure that there are no logs or data/index files around (indeed it could be that the control file alone was deleted or not restored, and we should not go on with life at this point). Things should still be relatively safe as if someone tries to use an old table with a new control file the different uuid:s between the files will cause ma_open() to generate an HA_ERR_OLD_FILE error. When used from mysqld this will cause the table to be open in repair mode which will remove all dependencies between the table and the old control file. We could have a tool which can rebuild the control file, by reading the directory of logs, finding the newest log, reading it to find last checkpoint... Slow but can save your db. For this to be possible, we must always write to the control file right after writing the checkpoint log record, and do nothing in between (i.e. the checkpoint must be usable as soon as it has been written to the log). */ /* init the file with these "undefined" values */ DBUG_RETURN(ma_control_file_write_and_force(LSN_IMPOSSIBLE, FILENO_IMPOSSIBLE, 0, 0)); }
O0
c
create_control_file: pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x40(%rbp) movl %esi, -0x44(%rbp) leaq 0x4291da(%rip), %rax # 0x476d20 movl (%rax), %edi movq -0x40(%rbp), %rcx movl -0x44(%rbp), %r9d leaq 0x102c0e(%rip), %rsi # 0x150765 movl $0x9a, %edx xorl %r8d, %r8d movq $0x8010, (%rsp) # imm = 0x8010 callq 0x4eb30 movl %eax, 0x26e84e(%rip) # 0x2bc3c0 cmpl $0x0, %eax jge 0x4db85 jmp 0x4db79 movl $0xb, -0x34(%rbp) jmp 0x4dcd8 movl $0x1e, 0x4295f5(%rip) # 0x477184 movl $0x16, 0x4295ef(%rip) # 0x477188 leaq -0x50(%rbp), %rdi movl $0x8, %esi callq 0x14f630 leaq -0x58(%rbp), %rdi movl $0x8, %esi callq 0x14f630 movq -0x50(%rbp), %rdi movq -0x58(%rbp), %rsi callq 0xfe7e0 leaq 0x428f37(%rip), %rdi # 0x476b00 callq 0xfe990 movw 0x102c56(%rip), %ax # 0x15082b movw %ax, -0x30(%rbp) movb 0x102c4e(%rip), %al # 0x15082d movb %al, -0x2e(%rbp) movb $0x1, -0x2d(%rbp) leaq 0x428f13(%rip), %rax # 0x476b00 movq (%rax), %rcx movq %rcx, -0x2c(%rbp) movq 0x8(%rax), %rax movq %rax, -0x24(%rbp) leaq -0x30(%rbp), %rax addq $0x14, %rax movq %rax, -0x60(%rbp) movl 0x429576(%rip), %eax # 0x477184 movw %ax, %cx movq -0x60(%rbp), %rax movw %cx, (%rax) jmp 0x4dc1a leaq -0x30(%rbp), %rax addq $0x16, %rax movq %rax, -0x68(%rbp) movl 0x42955c(%rip), %eax # 0x477188 movw %ax, %cx movq -0x68(%rbp), %rax movw %cx, (%rax) jmp 0x4dc38 leaq -0x30(%rbp), %rax addq $0x18, %rax movq %rax, -0x70(%rbp) leaq 0x26e5b5(%rip), %rax # 0x2bc200 movq (%rax), %rax movw %ax, %cx movq -0x70(%rbp), %rax movw %cx, (%rax) leaq -0x30(%rbp), %rsi movl 0x429522(%rip), %eax # 0x477184 subl $0x4, %eax movl %eax, %eax movl %eax, %edx xorl %edi, %edi callq 0x101bb0 movl %eax, -0x48(%rbp) leaq -0x30(%rbp), %rax movl 0x429507(%rip), %ecx # 0x477184 addq %rcx, %rax addq $-0x4, %rax movq %rax, -0x78(%rbp) movl -0x48(%rbp), %ecx movq -0x78(%rbp), %rax movl %ecx, (%rax) movl 0x26e729(%rip), %edi # 0x2bc3c0 leaq -0x30(%rbp), %rsi movl 0x4294e3(%rip), %eax # 0x477184 movl %eax, %edx xorl %eax, %eax movl %eax, %ecx movl $0x12, %r8d callq 0xf4240 cmpq $0x0, %rax je 0x4dcc3 jmp 0x4dcba movl $0xb, -0x34(%rbp) jmp 0x4dcd8 jmp 0x4dcc5 xorl %eax, %eax movl %eax, %edx xorl %ecx, %ecx movq %rdx, %rdi movl %ecx, %esi callq 0x4e1f0 movl %eax, -0x34(%rbp) movl -0x34(%rbp), %eax movl %eax, -0x7c(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x4dcfc movl -0x7c(%rbp), %eax addq $0x90, %rsp popq %rbp retq callq 0x2a270 nopw %cs:(%rax,%rax)
create_control_file: push rbp mov rbp, rsp sub rsp, 90h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_40], rdi mov [rbp+var_44], esi lea rax, key_file_control mov edi, [rax] mov rcx, [rbp+var_40] mov r9d, [rbp+var_44] lea rsi, aWorkspaceLlm4b_10; "/workspace/llm4binary/github2025/eloqsq"... mov edx, 9Ah xor r8d, r8d mov [rsp+90h+var_90], 8010h call inline_mysql_file_create mov cs:control_file_fd, eax cmp eax, 0 jge short loc_4DB85 jmp short $+2 loc_4DB79: mov [rbp+var_34], 0Bh jmp loc_4DCD8 loc_4DB85: mov cs:cf_create_time_size, 1Eh mov cs:cf_changeable_size, 16h lea rdi, [rbp+var_50] mov esi, 8 call my_random_bytes lea rdi, [rbp+var_58] mov esi, 8 call my_random_bytes mov rdi, [rbp+var_50] mov rsi, [rbp+var_58] call my_uuid_init lea rdi, maria_uuid call my_uuid mov ax, cs:word_15082B mov [rbp+var_30], ax mov al, cs:byte_15082D mov [rbp+var_2E], al mov [rbp+var_2D], 1 lea rax, maria_uuid mov rcx, [rax] mov [rbp+var_2C], rcx mov rax, [rax+8] mov [rbp+var_24], rax lea rax, [rbp+var_30] add rax, 14h mov [rbp+var_60], rax mov eax, cs:cf_create_time_size mov cx, ax mov rax, [rbp+var_60] mov [rax], cx jmp short $+2 loc_4DC1A: lea rax, [rbp+var_30] add rax, 16h mov [rbp+var_68], rax mov eax, cs:cf_changeable_size mov cx, ax mov rax, [rbp+var_68] mov [rax], cx jmp short $+2 loc_4DC38: lea rax, [rbp+var_30] add rax, 18h mov [rbp+var_70], rax lea rax, maria_block_size mov rax, [rax] mov cx, ax mov rax, [rbp+var_70] mov [rax], cx lea rsi, [rbp+var_30] mov eax, cs:cf_create_time_size sub eax, 4 mov eax, eax mov edx, eax xor edi, edi call my_checksum mov [rbp+var_48], eax lea rax, [rbp+var_30] mov ecx, cs:cf_create_time_size add rax, rcx add rax, 0FFFFFFFFFFFFFFFCh mov [rbp+var_78], rax mov ecx, [rbp+var_48] mov rax, [rbp+var_78] mov [rax], ecx mov edi, cs:control_file_fd lea rsi, [rbp+var_30] mov eax, cs:cf_create_time_size mov edx, eax xor eax, eax mov ecx, eax mov r8d, 12h call my_pwrite cmp rax, 0 jz short loc_4DCC3 jmp short $+2 loc_4DCBA: mov [rbp+var_34], 0Bh jmp short loc_4DCD8 loc_4DCC3: jmp short $+2 loc_4DCC5: xor eax, eax mov edx, eax xor ecx, ecx mov rdi, rdx mov esi, ecx call ma_control_file_write_and_force mov [rbp+var_34], eax loc_4DCD8: mov eax, [rbp+var_34] mov [rbp+var_7C], eax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_4DCFC mov eax, [rbp+var_7C] add rsp, 90h pop rbp retn loc_4DCFC: call ___stack_chk_fail
long long create_control_file(long long a1, int a2) { long long v3; // [rsp+38h] [rbp-58h] BYREF long long v4; // [rsp+40h] [rbp-50h] BYREF int v5; // [rsp+48h] [rbp-48h] int v6; // [rsp+4Ch] [rbp-44h] long long v7; // [rsp+50h] [rbp-40h] __int16 v9; // [rsp+60h] [rbp-30h] BYREF char v10; // [rsp+62h] [rbp-2Eh] char v11; // [rsp+63h] [rbp-2Dh] long long v12; // [rsp+64h] [rbp-2Ch] long long v13; // [rsp+6Ch] [rbp-24h] __int16 v14; // [rsp+74h] [rbp-1Ch] __int16 v15; // [rsp+76h] [rbp-1Ah] __int16 v16; // [rsp+78h] [rbp-18h] unsigned long long v17; // [rsp+88h] [rbp-8h] v17 = __readfsqword(0x28u); v7 = a1; v6 = a2; control_file_fd = inline_mysql_file_create( key_file_control, (unsigned int)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_control_file.c", 154, a1, 0, a2, 32784LL); if ( control_file_fd >= 0 ) { cf_create_time_size = 30; cf_changeable_size = 22; my_random_bytes(&v4, 8LL); my_random_bytes(&v3, 8LL); my_uuid_init(v4, v3); my_uuid(maria_uuid); v9 = -258; v10 = 12; v11 = 1; v12 = maria_uuid[0]; v13 = maria_uuid[1]; v14 = cf_create_time_size; v15 = cf_changeable_size; v16 = maria_block_size; v5 = my_checksum(0LL, &v9, (unsigned int)(cf_create_time_size - 4)); *(_DWORD *)((char *)&v9 + (unsigned int)cf_create_time_size - 4) = v5; if ( my_pwrite((unsigned int)control_file_fd, &v9, (unsigned int)cf_create_time_size, 0LL) ) return 11; else return (unsigned int)ma_control_file_write_and_force(0LL, 0LL); } else { return 11; } }
create_control_file: PUSH RBP MOV RBP,RSP SUB RSP,0x90 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x40],RDI MOV dword ptr [RBP + -0x44],ESI LEA RAX,[0x576d20] MOV EDI,dword ptr [RAX] MOV RCX,qword ptr [RBP + -0x40] MOV R9D,dword ptr [RBP + -0x44] LEA RSI,[0x250765] MOV EDX,0x9a XOR R8D,R8D MOV qword ptr [RSP],0x8010 CALL 0x0014eb30 MOV dword ptr [0x003bc3c0],EAX CMP EAX,0x0 JGE 0x0014db85 JMP 0x0014db79 LAB_0014db79: MOV dword ptr [RBP + -0x34],0xb JMP 0x0014dcd8 LAB_0014db85: MOV dword ptr [0x00577184],0x1e MOV dword ptr [0x00577188],0x16 LEA RDI,[RBP + -0x50] MOV ESI,0x8 CALL 0x0024f630 LEA RDI,[RBP + -0x58] MOV ESI,0x8 CALL 0x0024f630 MOV RDI,qword ptr [RBP + -0x50] MOV RSI,qword ptr [RBP + -0x58] CALL 0x001fe7e0 LEA RDI,[0x576b00] CALL 0x001fe990 MOV AX,word ptr [0x0025082b] MOV word ptr [RBP + -0x30],AX MOV AL,byte ptr [0x0025082d] MOV byte ptr [RBP + -0x2e],AL MOV byte ptr [RBP + -0x2d],0x1 LEA RAX,[0x576b00] MOV RCX,qword ptr [RAX] MOV qword ptr [RBP + -0x2c],RCX MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x24],RAX LEA RAX,[RBP + -0x30] ADD RAX,0x14 MOV qword ptr [RBP + -0x60],RAX MOV EAX,dword ptr [0x00577184] MOV CX,AX MOV RAX,qword ptr [RBP + -0x60] MOV word ptr [RAX],CX JMP 0x0014dc1a LAB_0014dc1a: LEA RAX,[RBP + -0x30] ADD RAX,0x16 MOV qword ptr [RBP + -0x68],RAX MOV EAX,dword ptr [0x00577188] MOV CX,AX MOV RAX,qword ptr [RBP + -0x68] MOV word ptr [RAX],CX JMP 0x0014dc38 LAB_0014dc38: LEA RAX,[RBP + -0x30] ADD RAX,0x18 MOV qword ptr [RBP + -0x70],RAX LEA RAX,[0x3bc200] MOV RAX,qword ptr [RAX] MOV CX,AX MOV RAX,qword ptr [RBP + -0x70] MOV word ptr [RAX],CX LEA RSI,[RBP + -0x30] MOV EAX,dword ptr [0x00577184] SUB EAX,0x4 MOV EAX,EAX MOV EDX,EAX XOR EDI,EDI CALL 0x00201bb0 MOV dword ptr [RBP + -0x48],EAX LEA RAX,[RBP + -0x30] MOV ECX,dword ptr [0x00577184] ADD RAX,RCX ADD RAX,-0x4 MOV qword ptr [RBP + -0x78],RAX MOV ECX,dword ptr [RBP + -0x48] MOV RAX,qword ptr [RBP + -0x78] MOV dword ptr [RAX],ECX MOV EDI,dword ptr [0x003bc3c0] LEA RSI,[RBP + -0x30] MOV EAX,dword ptr [0x00577184] MOV EDX,EAX XOR EAX,EAX MOV ECX,EAX MOV R8D,0x12 CALL 0x001f4240 CMP RAX,0x0 JZ 0x0014dcc3 JMP 0x0014dcba LAB_0014dcba: MOV dword ptr [RBP + -0x34],0xb JMP 0x0014dcd8 LAB_0014dcc3: JMP 0x0014dcc5 LAB_0014dcc5: XOR EAX,EAX MOV EDX,EAX XOR ECX,ECX MOV RDI,RDX MOV ESI,ECX CALL 0x0014e1f0 MOV dword ptr [RBP + -0x34],EAX LAB_0014dcd8: MOV EAX,dword ptr [RBP + -0x34] MOV dword ptr [RBP + -0x7c],EAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0014dcfc MOV EAX,dword ptr [RBP + -0x7c] ADD RSP,0x90 POP RBP RET LAB_0014dcfc: CALL 0x0012a270
int4 create_control_file(int8 param_1,int4 param_2) { long lVar1; long in_FS_OFFSET; int8 local_60; int8 local_58; int4 local_50; int4 local_4c; int8 local_48; int4 local_3c; int2 local_38; int1 local_36; int1 local_35; int8 local_34; int8 local_2c; int2 local_24; int2 local_22; int2 local_20; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_4c = param_2; local_48 = param_1; control_file_fd = inline_mysql_file_create (key_file_control, "/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_control_file.c",0x9a, param_1,0,param_2,0x8010); if (control_file_fd < 0) { local_3c = 0xb; } else { cf_create_time_size = 0x1e; cf_changeable_size = 0x16; my_random_bytes(&local_58,8); my_random_bytes(&local_60,8); my_uuid_init(local_58,local_60); my_uuid(&maria_uuid); local_38 = DAT_0025082b; local_36 = DAT_0025082d; local_35 = 1; local_34 = maria_uuid; local_2c = DAT_00576b08; local_24 = (int2)cf_create_time_size; local_22 = (int2)cf_changeable_size; local_20 = (int2)maria_block_size; local_50 = my_checksum(0,&local_38,cf_create_time_size - 4); *(int4 *)((long)&local_3c + (ulong)cf_create_time_size) = local_50; lVar1 = my_pwrite(control_file_fd,&local_38,cf_create_time_size,0,0x12); if (lVar1 == 0) { local_3c = ma_control_file_write_and_force(0,0); } else { local_3c = 0xb; } } if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return local_3c; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
56,881
my_mb_wc_gbk
eloqsql/strings/ctype-gbk.c
static int my_mb_wc_gbk(CHARSET_INFO *cs __attribute__((unused)), my_wc_t *pwc, const uchar *s, const uchar *e) { int hi; if (s >= e) return MY_CS_TOOSMALL; hi=s[0]; if (hi<0x80) { pwc[0]=hi; return 1; } if (s+2>e) return MY_CS_TOOSMALL2; if (!IS_MB2_CHAR(hi, s[1])) return MY_CS_ILSEQ; if (!(pwc[0]=func_gbk_uni_onechar( (hi<<8) + s[1]))) return -2; return 2; }
O0
c
my_mb_wc_gbk: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq -0x20(%rbp), %rax cmpq -0x28(%rbp), %rax jb 0x46d3e movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B jmp 0x46e19 movq -0x20(%rbp), %rax movzbl (%rax), %eax movl %eax, -0x2c(%rbp) cmpl $0x80, -0x2c(%rbp) jge 0x46d68 movslq -0x2c(%rbp), %rcx movq -0x18(%rbp), %rax movq %rcx, (%rax) movl $0x1, -0x4(%rbp) jmp 0x46e19 movq -0x20(%rbp), %rax addq $0x2, %rax cmpq -0x28(%rbp), %rax jbe 0x46d82 movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A jmp 0x46e19 movl -0x2c(%rbp), %eax movzbl %al, %ecx movl $0x81, %eax cmpl %ecx, %eax jg 0x46ddc movl -0x2c(%rbp), %eax movzbl %al, %eax cmpl $0xfe, %eax jg 0x46ddc movq -0x20(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x40, %eax cmpl %ecx, %eax jg 0x46dbc movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0x7e, %eax jle 0x46de5 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x80, %eax cmpl %ecx, %eax jg 0x46ddc movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0xfe, %eax jle 0x46de5 movl $0x0, -0x4(%rbp) jmp 0x46e19 movl -0x2c(%rbp), %edi shll $0x8, %edi movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax addl %eax, %edi callq 0x47160 cltq movq -0x18(%rbp), %rcx movq %rax, (%rcx) cmpq $0x0, %rax jne 0x46e12 movl $0xfffffffe, -0x4(%rbp) # imm = 0xFFFFFFFE jmp 0x46e19 movl $0x2, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
my_mb_wc_gbk: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_28], rcx mov rax, [rbp+var_20] cmp rax, [rbp+var_28] jb short loc_46D3E mov [rbp+var_4], 0FFFFFF9Bh jmp loc_46E19 loc_46D3E: mov rax, [rbp+var_20] movzx eax, byte ptr [rax] mov [rbp+var_2C], eax cmp [rbp+var_2C], 80h jge short loc_46D68 movsxd rcx, [rbp+var_2C] mov rax, [rbp+var_18] mov [rax], rcx mov [rbp+var_4], 1 jmp loc_46E19 loc_46D68: mov rax, [rbp+var_20] add rax, 2 cmp rax, [rbp+var_28] jbe short loc_46D82 mov [rbp+var_4], 0FFFFFF9Ah jmp loc_46E19 loc_46D82: mov eax, [rbp+var_2C] movzx ecx, al mov eax, 81h cmp eax, ecx jg short loc_46DDC mov eax, [rbp+var_2C] movzx eax, al cmp eax, 0FEh jg short loc_46DDC mov rax, [rbp+var_20] movzx ecx, byte ptr [rax+1] mov eax, 40h ; '@' cmp eax, ecx jg short loc_46DBC mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] cmp eax, 7Eh ; '~' jle short loc_46DE5 loc_46DBC: mov rax, [rbp+var_20] movzx ecx, byte ptr [rax+1] mov eax, 80h cmp eax, ecx jg short loc_46DDC mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] cmp eax, 0FEh jle short loc_46DE5 loc_46DDC: mov [rbp+var_4], 0 jmp short loc_46E19 loc_46DE5: mov edi, [rbp+var_2C] shl edi, 8 mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] add edi, eax call func_gbk_uni_onechar cdqe mov rcx, [rbp+var_18] mov [rcx], rax cmp rax, 0 jnz short loc_46E12 mov [rbp+var_4], 0FFFFFFFEh jmp short loc_46E19 loc_46E12: mov [rbp+var_4], 2 loc_46E19: mov eax, [rbp+var_4] add rsp, 30h pop rbp retn
long long my_mb_wc_gbk(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4) { int v4; // eax unsigned int v6; // [rsp+4h] [rbp-2Ch] if ( (unsigned long long)a3 < a4 ) { v6 = *a3; if ( v6 >= 0x80 ) { if ( (unsigned long long)(a3 + 2) <= a4 ) { if ( (unsigned __int8)v6 < 0x81u || (unsigned __int8)v6 == 255 || (a3[1] < 0x40u || a3[1] > 0x7Eu) && (a3[1] < 0x80u || a3[1] == 255) ) { return 0; } else { v4 = func_gbk_uni_onechar(a3[1] + (v6 << 8)); *a2 = v4; if ( v4 ) return 2; else return (unsigned int)-2; } } else { return (unsigned int)-102; } } else { *a2 = *a3; return 1; } } else { return (unsigned int)-101; } }
my_mb_wc_gbk: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV qword ptr [RBP + -0x28],RCX MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x28] JC 0x00146d3e MOV dword ptr [RBP + -0x4],0xffffff9b JMP 0x00146e19 LAB_00146d3e: MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX] MOV dword ptr [RBP + -0x2c],EAX CMP dword ptr [RBP + -0x2c],0x80 JGE 0x00146d68 MOVSXD RCX,dword ptr [RBP + -0x2c] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],RCX MOV dword ptr [RBP + -0x4],0x1 JMP 0x00146e19 LAB_00146d68: MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x2 CMP RAX,qword ptr [RBP + -0x28] JBE 0x00146d82 MOV dword ptr [RBP + -0x4],0xffffff9a JMP 0x00146e19 LAB_00146d82: MOV EAX,dword ptr [RBP + -0x2c] MOVZX ECX,AL MOV EAX,0x81 CMP EAX,ECX JG 0x00146ddc MOV EAX,dword ptr [RBP + -0x2c] MOVZX EAX,AL CMP EAX,0xfe JG 0x00146ddc MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x40 CMP EAX,ECX JG 0x00146dbc MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0x7e JLE 0x00146de5 LAB_00146dbc: MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x80 CMP EAX,ECX JG 0x00146ddc MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0xfe JLE 0x00146de5 LAB_00146ddc: MOV dword ptr [RBP + -0x4],0x0 JMP 0x00146e19 LAB_00146de5: MOV EDI,dword ptr [RBP + -0x2c] SHL EDI,0x8 MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] ADD EDI,EAX CALL 0x00147160 CDQE MOV RCX,qword ptr [RBP + -0x18] MOV qword ptr [RCX],RAX CMP RAX,0x0 JNZ 0x00146e12 MOV dword ptr [RBP + -0x4],0xfffffffe JMP 0x00146e19 LAB_00146e12: MOV dword ptr [RBP + -0x4],0x2 LAB_00146e19: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x30 POP RBP RET
int4 my_mb_wc_gbk(int8 param_1,long *param_2,byte *param_3,byte *param_4) { uint uVar1; int iVar2; int4 local_c; if (param_3 < param_4) { uVar1 = (uint)*param_3; if (uVar1 < 0x80) { *param_2 = (long)(int)uVar1; local_c = 1; } else if (param_4 < param_3 + 2) { local_c = 0xffffff9a; } else if (((uVar1 < 0x81) || (0xfe < uVar1)) || (((param_3[1] < 0x40 || (0x7e < param_3[1])) && ((param_3[1] < 0x80 || (param_3[1] == 0xff)))))) { local_c = 0; } else { iVar2 = func_gbk_uni_onechar(uVar1 * 0x100 + (uint)param_3[1]); *param_2 = (long)iVar2; if ((long)iVar2 == 0) { local_c = 0xfffffffe; } else { local_c = 2; } } } else { local_c = 0xffffff9b; } return local_c; }
56,882
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>::size() const
llama.cpp/common/json.hpp
size_type size() const noexcept { switch (m_data.m_type) { case value_t::null: { // null values are empty return 0; } case value_t::array: { // delegate call to array_t::size() return m_data.m_value.array->size(); } case value_t::object: { // delegate call to object_t::size() return m_data.m_value.object->size(); } case value_t::string: case value_t::boolean: case value_t::number_integer: case value_t::number_unsigned: case value_t::number_float: case value_t::binary: case value_t::discarded: default: { // all other types have size 1 return 1; } } }
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>::size() const: movzbl (%rdi), %eax testl %eax, %eax je 0x8ccc2 cmpl $0x1, %eax je 0x8cc9f cmpl $0x2, %eax jne 0x8ccbd movq 0x8(%rdi), %rcx movq 0x8(%rcx), %rax subq (%rcx), %rax sarq $0x4, %rax retq movq 0x8(%rdi), %rax movq 0x8(%rax), %rcx subq (%rax), %rcx sarq $0x4, %rcx movabsq $-0x5555555555555555, %rax # imm = 0xAAAAAAAAAAAAAAAB imulq %rcx, %rax retq movl $0x1, %eax retq nop
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4sizeEv: movzx eax, byte ptr [rdi] test eax, eax jz short locret_8CCC2 cmp eax, 1 jz short loc_8CC9F cmp eax, 2 jnz short loc_8CCBD mov rcx, [rdi+8] mov rax, [rcx+8] sub rax, [rcx] sar rax, 4 retn loc_8CC9F: mov rax, [rdi+8] mov rcx, [rax+8] sub rcx, [rax] sar rcx, 4 mov rax, 0AAAAAAAAAAAAAAABh imul rax, rcx retn loc_8CCBD: mov eax, 1 locret_8CCC2: retn
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>::size( unsigned __int8 *a1) { long long result; // rax result = *a1; if ( *a1 ) { if ( (_DWORD)result == 1 ) { return 0xAAAAAAAAAAAAAAABLL * ((long long)(*(_QWORD *)(*((_QWORD *)a1 + 1) + 8LL) - **((_QWORD **)a1 + 1)) >> 4); } else if ( (_DWORD)result == 2 ) { return (long long)(*(_QWORD *)(*((_QWORD *)a1 + 1) + 8LL) - **((_QWORD **)a1 + 1)) >> 4; } else { return 1LL; } } return result; }
size: MOVZX EAX,byte ptr [RDI] TEST EAX,EAX JZ 0x0018ccc2 CMP EAX,0x1 JZ 0x0018cc9f CMP EAX,0x2 JNZ 0x0018ccbd MOV RCX,qword ptr [RDI + 0x8] MOV RAX,qword ptr [RCX + 0x8] SUB RAX,qword ptr [RCX] SAR RAX,0x4 RET LAB_0018cc9f: MOV RAX,qword ptr [RDI + 0x8] MOV RCX,qword ptr [RAX + 0x8] SUB RCX,qword ptr [RAX] SAR RCX,0x4 MOV RAX,-0x5555555555555555 IMUL RAX,RCX RET LAB_0018ccbd: MOV EAX,0x1 LAB_0018ccc2: 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>::size() const */ ulong __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> ::size(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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; ulong uVar2; bVar1 = *this; uVar2 = (ulong)(byte)bVar1; 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) { 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) { return ((*(long **)(this + 8))[1] - **(long **)(this + 8) >> 4) * -0x5555555555555555; } 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> )0x2) { return (*(long **)(this + 8))[1] - **(long **)(this + 8) >> 4; } uVar2 = 1; } return uVar2; }
56,883
thr_multi_unlock
eloqsql/mysys/thr_lock.c
void thr_multi_unlock(THR_LOCK_DATA **data,uint count, uint unlock_flags) { THR_LOCK_DATA **pos,**end; DBUG_ENTER("thr_multi_unlock"); DBUG_PRINT("lock",("data: %p count: %d flags: %u", data, count, unlock_flags)); for (pos=data,end=data+count; pos < end ; pos++) { #ifdef MAIN printf("Thread: %s Rel lock: %p type: %d\n", my_thread_name(), pos[0]->lock, pos[0]->type); fflush(stdout); #endif if ((*pos)->type != TL_UNLOCK) thr_unlock(*pos, unlock_flags); else { DBUG_PRINT("lock",("Free lock: data: %p thread:%lu lock: %p", *pos, (ulong) (*pos)->owner->thread_id, (*pos)->lock)); } } DBUG_VOID_RETURN; }
O3
c
thr_multi_unlock: testl %esi, %esi je 0x5f464 pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %edx, %ebx movq %rdi, %r14 movl %esi, %eax leaq (%rdi,%rax,8), %r15 movq (%r14), %rdi cmpl $0x0, 0x40(%rdi) je 0x5f451 movl %ebx, %esi callq 0x5e75c addq $0x8, %r14 cmpq %r15, %r14 jb 0x5f441 addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
thr_multi_unlock: test esi, esi jz short locret_5F464 push rbp mov rbp, rsp push r15 push r14 push rbx push rax mov ebx, edx mov r14, rdi mov eax, esi lea r15, [rdi+rax*8] loc_5F441: mov rdi, [r14] cmp dword ptr [rdi+40h], 0 jz short loc_5F451 mov esi, ebx call thr_unlock loc_5F451: add r14, 8 cmp r14, r15 jb short loc_5F441 add rsp, 8 pop rbx pop r14 pop r15 pop rbp locret_5F464: retn
long long thr_multi_unlock(long long *a1, unsigned int a2, char a3) { long long *v4; // r14 long long result; // rax if ( a2 ) { v4 = a1; result = a2; do { if ( *(_DWORD *)(*v4 + 64) ) result = thr_unlock(*v4, a3); ++v4; } while ( v4 < &a1[a2] ); } return result; }
thr_multi_unlock: TEST ESI,ESI JZ 0x0015f464 PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV EBX,EDX MOV R14,RDI MOV EAX,ESI LEA R15,[RDI + RAX*0x8] LAB_0015f441: MOV RDI,qword ptr [R14] CMP dword ptr [RDI + 0x40],0x0 JZ 0x0015f451 MOV ESI,EBX CALL 0x0015e75c LAB_0015f451: ADD R14,0x8 CMP R14,R15 JC 0x0015f441 ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP LAB_0015f464: RET
void thr_multi_unlock(long *param_1,uint param_2,int4 param_3) { long *plVar1; if (param_2 != 0) { plVar1 = param_1 + param_2; do { if (*(int *)(*param_1 + 0x40) != 0) { thr_unlock(*param_1,param_3); } param_1 = param_1 + 1; } while (param_1 < plVar1); } return; }
56,884
mysql_load_plugin
eloqsql/build_O0/libmariadb/libmariadb/ma_client_plugin.c
struct st_mysql_client_plugin * STDCALL mysql_load_plugin(MYSQL *mysql, const char *name, int type, int argc, ...) { struct st_mysql_client_plugin *p; va_list args; va_start(args, argc); p= mysql_load_plugin_v(mysql, name, type, argc, args); va_end(args); return p; }
O0
c
mysql_load_plugin: pushq %rbp movq %rsp, %rbp subq $0xf0, %rsp testb %al, %al je 0x509ab movaps %xmm0, -0xc0(%rbp) movaps %xmm1, -0xb0(%rbp) movaps %xmm2, -0xa0(%rbp) movaps %xmm3, -0x90(%rbp) movaps %xmm4, -0x80(%rbp) movaps %xmm5, -0x70(%rbp) movaps %xmm6, -0x60(%rbp) movaps %xmm7, -0x50(%rbp) movq %r9, -0xc8(%rbp) movq %r8, -0xd0(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movl %edx, -0x14(%rbp) movl %ecx, -0x18(%rbp) leaq -0xf0(%rbp), %rax movq %rax, -0x30(%rbp) leaq 0x10(%rbp), %rax movq %rax, -0x38(%rbp) movl $0x30, -0x3c(%rbp) movl $0x20, -0x40(%rbp) movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movl -0x14(%rbp), %edx movl -0x18(%rbp), %ecx leaq -0x40(%rbp), %r8 callq 0x50580 movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax addq $0xf0, %rsp popq %rbp retq
mysql_load_plugin: push rbp mov rbp, rsp sub rsp, 0F0h test al, al jz short loc_509AB movaps [rbp+var_C0], xmm0 movaps [rbp+var_B0], xmm1 movaps [rbp+var_A0], xmm2 movaps [rbp+var_90], xmm3 movaps [rbp+var_80], xmm4 movaps [rbp+var_70], xmm5 movaps [rbp+var_60], xmm6 movaps [rbp+var_50], xmm7 loc_509AB: mov [rbp+var_C8], r9 mov [rbp+var_D0], r8 mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_14], edx mov [rbp+var_18], ecx lea rax, [rbp+var_F0] mov [rbp+var_30], rax lea rax, [rbp+arg_0] mov [rbp+var_38], rax mov [rbp+var_3C], 30h ; '0' mov [rbp+var_40], 20h ; ' ' mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov edx, [rbp+var_14] mov ecx, [rbp+var_18] lea r8, [rbp+var_40] call mysql_load_plugin_v mov [rbp+var_20], rax mov rax, [rbp+var_20] add rsp, 0F0h pop rbp retn
void (**mysql_load_plugin(long long a1, const char *a2, signed int a3, unsigned int a4, ...))(void) { va_list va; // [rsp+B0h] [rbp-40h] BYREF unsigned int v6; // [rsp+D8h] [rbp-18h] signed int v7; // [rsp+DCh] [rbp-14h] const char *v8; // [rsp+E0h] [rbp-10h] long long v9; // [rsp+E8h] [rbp-8h] va_start(va, a4); v9 = a1; v8 = a2; v7 = a3; v6 = a4; return mysql_load_plugin_v(a1, a2, a3, a4, (long long)va); }
mysql_load_plugin: PUSH RBP MOV RBP,RSP SUB RSP,0xf0 TEST AL,AL JZ 0x001509ab MOVAPS xmmword ptr [RBP + -0xc0],XMM0 MOVAPS xmmword ptr [RBP + -0xb0],XMM1 MOVAPS xmmword ptr [RBP + -0xa0],XMM2 MOVAPS xmmword ptr [RBP + -0x90],XMM3 MOVAPS xmmword ptr [RBP + -0x80],XMM4 MOVAPS xmmword ptr [RBP + -0x70],XMM5 MOVAPS xmmword ptr [RBP + -0x60],XMM6 MOVAPS xmmword ptr [RBP + -0x50],XMM7 LAB_001509ab: MOV qword ptr [RBP + -0xc8],R9 MOV qword ptr [RBP + -0xd0],R8 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV dword ptr [RBP + -0x14],EDX MOV dword ptr [RBP + -0x18],ECX LEA RAX,[RBP + -0xf0] MOV qword ptr [RBP + -0x30],RAX LEA RAX,[RBP + 0x10] MOV qword ptr [RBP + -0x38],RAX MOV dword ptr [RBP + -0x3c],0x30 MOV dword ptr [RBP + -0x40],0x20 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RBP + -0x14] MOV ECX,dword ptr [RBP + -0x18] LEA R8,[RBP + -0x40] CALL 0x00150580 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] ADD RSP,0xf0 POP RBP RET
int8 mysql_load_plugin(int8 param_1,int8 param_2,int8 param_3,int8 param_4, int8 param_5,int8 param_6,int8 param_7,int8 param_8, int8 param_9,int8 param_10,int4 param_11,int4 param_12, int8 param_13,int8 param_14) { char in_AL; int8 uVar1; int1 local_f8 [32]; int8 local_d8; int8 local_d0; int8 local_c8; int8 local_b8; int8 local_a8; int8 local_98; int8 local_88; int8 local_78; int8 local_68; int8 local_58; int4 local_48; int4 local_44; int1 *local_40; int1 *local_38; int4 local_20; int4 local_1c; int8 local_18; int8 local_10; if (in_AL != '\0') { local_c8 = param_1; local_b8 = param_2; local_a8 = param_3; local_98 = param_4; local_88 = param_5; local_78 = param_6; local_68 = param_7; local_58 = param_8; } local_38 = local_f8; local_40 = &stack0x00000008; local_44 = 0x30; local_48 = 0x20; local_d8 = param_13; local_d0 = param_14; local_20 = param_12; local_1c = param_11; local_18 = param_10; local_10 = param_9; uVar1 = mysql_load_plugin_v(param_9,param_10,param_11,param_12,&local_48); return uVar1; }
56,885
bitmap_get_first_set
eloqsql/mysys/my_bitmap.c
uint bitmap_get_first_set(const MY_BITMAP *map) { uint i; my_bitmap_map *data_ptr= map->bitmap, *end= map->last_word_ptr; DBUG_ASSERT(map->bitmap); for (i=0; data_ptr < end; data_ptr++, i++) if (*data_ptr) goto found; if (!(*data_ptr & ~map->last_word_mask)) return MY_BIT_NONE; found: return get_first_set(*data_ptr, i); }
O0
c
bitmap_get_first_set: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0x28(%rbp) jmp 0xb5815 movl $0x0, -0x14(%rbp) movq -0x20(%rbp), %rax cmpq -0x28(%rbp), %rax jae 0xb584a movq -0x20(%rbp), %rax cmpl $0x0, (%rax) je 0xb5831 jmp 0xb586c jmp 0xb5833 movq -0x20(%rbp), %rax addq $0x4, %rax movq %rax, -0x20(%rbp) movl -0x14(%rbp), %eax addl $0x1, %eax movl %eax, -0x14(%rbp) jmp 0xb581c movq -0x20(%rbp), %rax movl (%rax), %eax movq -0x10(%rbp), %rcx movl 0x18(%rcx), %ecx xorl $-0x1, %ecx andl %ecx, %eax cmpl $0x0, %eax jne 0xb586a movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0xb587d jmp 0xb586c movq -0x20(%rbp), %rax movl (%rax), %edi movl -0x14(%rbp), %esi callq 0xb5890 movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
bitmap_get_first_set: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov rax, [rbp+var_10] mov rax, [rax] mov [rbp+var_20], rax mov rax, [rbp+var_10] mov rax, [rax+8] mov [rbp+var_28], rax jmp short $+2 loc_B5815: mov [rbp+var_14], 0 loc_B581C: mov rax, [rbp+var_20] cmp rax, [rbp+var_28] jnb short loc_B584A mov rax, [rbp+var_20] cmp dword ptr [rax], 0 jz short loc_B5831 jmp short loc_B586C loc_B5831: jmp short $+2 loc_B5833: mov rax, [rbp+var_20] add rax, 4 mov [rbp+var_20], rax mov eax, [rbp+var_14] add eax, 1 mov [rbp+var_14], eax jmp short loc_B581C loc_B584A: mov rax, [rbp+var_20] mov eax, [rax] mov rcx, [rbp+var_10] mov ecx, [rcx+18h] xor ecx, 0FFFFFFFFh and eax, ecx cmp eax, 0 jnz short loc_B586A mov [rbp+var_4], 0FFFFFFFFh jmp short loc_B587D loc_B586A: jmp short $+2 loc_B586C: mov rax, [rbp+var_20] mov edi, [rax] mov esi, [rbp+var_14] call get_first_set mov [rbp+var_4], eax loc_B587D: mov eax, [rbp+var_4] add rsp, 30h pop rbp retn
long long bitmap_get_first_set(long long a1) { _DWORD *v2; // [rsp+10h] [rbp-20h] unsigned int v3; // [rsp+1Ch] [rbp-14h] v2 = *(_DWORD **)a1; v3 = 0; while ( (unsigned long long)v2 < *(_QWORD *)(a1 + 8) ) { if ( *v2 ) return (unsigned int)get_first_set((unsigned int)*v2, v3); ++v2; ++v3; } if ( (~*(_DWORD *)(a1 + 24) & *v2) == 0 ) return (unsigned int)-1; return (unsigned int)get_first_set((unsigned int)*v2, v3); }
bitmap_get_first_set: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x28],RAX JMP 0x001b5815 LAB_001b5815: MOV dword ptr [RBP + -0x14],0x0 LAB_001b581c: MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x28] JNC 0x001b584a MOV RAX,qword ptr [RBP + -0x20] CMP dword ptr [RAX],0x0 JZ 0x001b5831 JMP 0x001b586c LAB_001b5831: JMP 0x001b5833 LAB_001b5833: MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x4 MOV qword ptr [RBP + -0x20],RAX MOV EAX,dword ptr [RBP + -0x14] ADD EAX,0x1 MOV dword ptr [RBP + -0x14],EAX JMP 0x001b581c LAB_001b584a: MOV RAX,qword ptr [RBP + -0x20] MOV EAX,dword ptr [RAX] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x18] XOR ECX,0xffffffff AND EAX,ECX CMP EAX,0x0 JNZ 0x001b586a MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x001b587d LAB_001b586a: JMP 0x001b586c LAB_001b586c: MOV RAX,qword ptr [RBP + -0x20] MOV EDI,dword ptr [RAX] MOV ESI,dword ptr [RBP + -0x14] CALL 0x001b5890 MOV dword ptr [RBP + -0x4],EAX LAB_001b587d: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x30 POP RBP RET
int4 bitmap_get_first_set(int8 *param_1) { uint *local_28; int local_1c; int4 local_c; local_28 = (uint *)*param_1; local_1c = 0; for (; local_28 < (uint *)param_1[1]; local_28 = local_28 + 1) { if (*local_28 != 0) goto LAB_001b586c; local_1c = local_1c + 1; } if ((*local_28 & (*(uint *)(param_1 + 3) ^ 0xffffffff)) == 0) { local_c = 0xffffffff; } else { LAB_001b586c: local_c = get_first_set(*local_28,local_1c); } return local_c; }
56,886
google::protobuf::Fls64(unsigned long)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/stubs/int128.cc
static inline int Fls64(uint64_t n) { GOOGLE_DCHECK_NE(0, n); int pos = 0; STEP(uint64_t, n, pos, 0x20); uint32_t n32 = n; STEP(uint32_t, n32, pos, 0x10); STEP(uint32_t, n32, pos, 0x08); STEP(uint32_t, n32, pos, 0x04); return pos + ((uint64_t{0x3333333322221100u} >> (n32 << 2)) & 0x3); } #undef STEP // Like Fls64() above, but returns the 0-based position of the last set bit // (i.e., most significant bit) in the given uint128. The argument may not be 0. static inline int Fls128(uint128 n) { if (uint64_t hi = Uint128High64(n)) { return Fls64(hi) + 64; } return Fls64(Uint128Low64(n)); } void uint128::DivModImpl(uint128 dividend, uint128 divisor, uint128* quotient_ret, uint128* remainder_ret) { if (divisor == 0) { GOOGLE_LOG(FATAL) << "Division or mod by zero: dividend.hi=" << dividend.hi_ << ", lo=" << dividend.lo_; } else if (dividend < divisor) { *quotient_ret = 0; *remainder_ret = dividend; return; } else { int dividend_bit_length = Fls128(dividend); int divisor_bit_length = Fls128(divisor); int difference = dividend_bit_length - divisor_bit_length; uint128 quotient = 0; while (difference >= 0) { quotient <<= 1; uint128 shifted_divisor = divisor << difference; if (shifted_divisor <= dividend) { dividend -= shifted_divisor; quotient += 1; } difference -= 1; } //record the final quotient and remainder *quotient_ret = quotient; *remainder_ret = dividend; } } uint128& uint128::operator/=(const uint128& divisor) { uint128 quotient = 0; uint128 remainder = 0; DivModImpl(*this, divisor, &quotient, &remainder); *this = quotient; return *this; } uint128& uint128::operator%=(const uint128& divisor) { uint128 quotient = 0; uint128 remainder = 0; DivModImpl(*this, divisor, &quotient, &remainder); *this = remainder; return *this; } std::ostream& operator<<(std::ostream& o, const uint128& b) { std::ios_base::fmtflags flags = o.flags(); // Select a divisor which is the largest power of the base < 2^64. uint128 div; std::streamsize div_base_log; switch (flags & std::ios::basefield) { case std::ios::hex: div = static_cast<uint64_t>(uint64_t{0x1000000000000000u}); // 16^15 div_base_log = 15; break; case std::ios::oct: div = static_cast<uint64_t>( uint64_t{01000000000000000000000u}); // 8^21 div_base_log = 21; break; default: // std::ios::dec div = static_cast<uint64_t>( uint64_t{10000000000000000000u}); // 10^19 div_base_log = 19; break; } // Now piece together the uint128 representation from three chunks of // the original value, each less than "div" and therefore representable // as a uint64. std::ostringstream os; std::ios_base::fmtflags copy_mask = std::ios::basefield | std::ios::showbase | std::ios::uppercase; os.setf(flags & copy_mask, copy_mask); uint128 high = b; uint128 low; uint128::DivModImpl(high, div, &high, &low); uint128 mid; uint128::DivModImpl(high, div, &high, &mid); if (high.lo_ != 0) { os << high.lo_; os << std::noshowbase << std::setfill('0') << std::setw(div_base_log); os << mid.lo_; os << std::setw(div_base_log); } else if (mid.lo_ != 0) { os << mid.lo_; os << std::noshowbase << std::setfill('0') << std::setw(div_base_log); } os << low.lo_; std::string rep = os.str(); // Add the requisite padding. std::streamsize width = o.width(0); auto repSize = static_cast<std::streamsize>(rep.size()); if (width > repSize) { if ((flags & std::ios::adjustfield) == std::ios::left) { rep.append(width - repSize, o.fill()); } else { rep.insert(static_cast<std::string::size_type>(0), width - repSize, o.fill()); } } // Stream the final representation in a single "<<" call. return o << rep; } }
O0
cpp
google::protobuf::Fls64(unsigned long): subq $0x78, %rsp movq %rdi, 0x70(%rsp) xorl %eax, %eax testb $0x1, %al jne 0x24bb4 jmp 0x24c55 movq 0x70(%rsp), %rcx movb $0x0, 0x37(%rsp) xorl %eax, %eax cmpq %rcx, %rax je 0x24bc7 jmp 0x24c17 leaq 0x1c782a(%rip), %rdx # 0x1ec3f8 leaq 0x38(%rsp), %rdi movq %rdi, 0x8(%rsp) movl $0x3, %esi movl $0x3d, %ecx callq 0x237e0 movq 0x8(%rsp), %rdi movb $0x1, 0x37(%rsp) leaq 0x1c7895(%rip), %rsi # 0x1ec48d callq 0x230a0 movq %rax, 0x10(%rsp) jmp 0x24c04 movq 0x10(%rsp), %rsi leaq 0x23(%rsp), %rdi callq 0x23250 jmp 0x24c15 jmp 0x24c17 testb $0x1, 0x37(%rsp) jne 0x24c20 jmp 0x24c2a leaq 0x38(%rsp), %rdi callq 0x23820 jmp 0x24ba9 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x28(%rsp) movl %eax, 0x24(%rsp) testb $0x1, 0x37(%rsp) jne 0x24c46 jmp 0x24c50 leaq 0x38(%rsp), %rdi callq 0x23820 jmp 0x24d23 movl $0x0, 0x1c(%rsp) movabsq $0x100000000, %rax # imm = 0x100000000 cmpq %rax, 0x70(%rsp) jb 0x24c87 movq 0x70(%rsp), %rax shrq $0x20, %rax movq %rax, 0x70(%rsp) movl 0x1c(%rsp), %eax orl $0x20, %eax movl %eax, 0x1c(%rsp) jmp 0x24c89 movq 0x70(%rsp), %rax movl %eax, 0x18(%rsp) cmpl $0x10000, 0x18(%rsp) # imm = 0x10000 jb 0x24cb2 movl 0x18(%rsp), %eax shrl $0x10, %eax movl %eax, 0x18(%rsp) movl 0x1c(%rsp), %eax orl $0x10, %eax movl %eax, 0x1c(%rsp) jmp 0x24cb4 jmp 0x24cb6 cmpl $0x100, 0x18(%rsp) # imm = 0x100 jb 0x24cd6 movl 0x18(%rsp), %eax shrl $0x8, %eax movl %eax, 0x18(%rsp) movl 0x1c(%rsp), %eax orl $0x8, %eax movl %eax, 0x1c(%rsp) jmp 0x24cd8 jmp 0x24cda cmpl $0x10, 0x18(%rsp) jb 0x24cf7 movl 0x18(%rsp), %eax shrl $0x4, %eax movl %eax, 0x18(%rsp) movl 0x1c(%rsp), %eax orl $0x4, %eax movl %eax, 0x1c(%rsp) jmp 0x24cf9 movslq 0x1c(%rsp), %rax movl 0x18(%rsp), %ecx shll $0x2, %ecx movl %ecx, %ecx movabsq $0x3333333322221100, %rdx # imm = 0x3333333322221100 shrq %cl, %rdx movq %rdx, %rcx andq $0x3, %rcx addq %rcx, %rax addq $0x78, %rsp retq movq 0x28(%rsp), %rdi callq 0x13750 nopl (%rax)
_ZN6google8protobufL5Fls64Em: sub rsp, 78h mov [rsp+78h+var_8], rdi loc_24BA9: xor eax, eax test al, 1 jnz short loc_24BB4 jmp loc_24C55 loc_24BB4: mov rcx, [rsp+78h+var_8] mov [rsp+78h+var_41], 0 xor eax, eax cmp rax, rcx jz short loc_24BC7 jmp short loc_24C17 loc_24BC7: lea rdx, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/aimrt_"... lea rdi, [rsp+78h+var_40] mov [rsp+78h+var_70], rdi mov esi, 3 mov ecx, 3Dh ; '=' call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int) mov rdi, [rsp+78h+var_70] mov [rsp+78h+var_41], 1 lea rsi, aCheckFailed0N; "CHECK failed: (0) != (n): " call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*) mov [rsp+78h+var_68], rax jmp short $+2 loc_24C04: mov rsi, [rsp+78h+var_68] lea rdi, [rsp+78h+var_55] call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &) jmp short $+2 loc_24C15: jmp short $+2 loc_24C17: test [rsp+78h+var_41], 1 jnz short loc_24C20 jmp short loc_24C2A loc_24C20: lea rdi, [rsp+78h+var_40]; this call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage() loc_24C2A: jmp loc_24BA9 mov rcx, rax mov eax, edx mov [rsp+arg_20], rcx mov [rsp+arg_1C], eax test [rsp+arg_2F], 1 jnz short loc_24C46 jmp short loc_24C50 loc_24C46: lea rdi, [rsp+arg_30]; this call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage() loc_24C50: jmp loc_24D23 loc_24C55: mov [rsp+78h+var_5C], 0 mov rax, 100000000h cmp [rsp+78h+var_8], rax jb short loc_24C87 mov rax, [rsp+78h+var_8] shr rax, 20h mov [rsp+78h+var_8], rax mov eax, [rsp+78h+var_5C] or eax, 20h mov [rsp+78h+var_5C], eax loc_24C87: jmp short $+2 loc_24C89: mov rax, [rsp+78h+var_8] mov [rsp+78h+var_60], eax cmp [rsp+78h+var_60], 10000h jb short loc_24CB2 mov eax, [rsp+78h+var_60] shr eax, 10h mov [rsp+78h+var_60], eax mov eax, [rsp+78h+var_5C] or eax, 10h mov [rsp+78h+var_5C], eax loc_24CB2: jmp short $+2 loc_24CB4: jmp short $+2 loc_24CB6: cmp [rsp+78h+var_60], 100h jb short loc_24CD6 mov eax, [rsp+78h+var_60] shr eax, 8 mov [rsp+78h+var_60], eax mov eax, [rsp+78h+var_5C] or eax, 8 mov [rsp+78h+var_5C], eax loc_24CD6: jmp short $+2 loc_24CD8: jmp short $+2 loc_24CDA: cmp [rsp+78h+var_60], 10h jb short loc_24CF7 mov eax, [rsp+78h+var_60] shr eax, 4 mov [rsp+78h+var_60], eax mov eax, [rsp+78h+var_5C] or eax, 4 mov [rsp+78h+var_5C], eax loc_24CF7: jmp short $+2 loc_24CF9: movsxd rax, [rsp+78h+var_5C] mov ecx, [rsp+78h+var_60] shl ecx, 2 mov ecx, ecx mov rdx, 3333333322221100h shr rdx, cl mov rcx, rdx and rcx, 3 add rax, rcx add rsp, 78h retn loc_24D23: mov rdi, [rsp+arg_20] call __Unwind_Resume
unsigned long long google::protobuf::Fls64(google::protobuf *this) { unsigned int v2; // [rsp+18h] [rbp-60h] int v3; // [rsp+1Ch] [rbp-5Ch] unsigned long long v4; // [rsp+70h] [rbp-8h] v4 = (unsigned long long)this; v3 = 0; if ( (unsigned long long)this >= 0x100000000LL ) { v4 >>= 32; v3 = 32; } v2 = v4; if ( (unsigned int)v4 >= 0x10000 ) { v2 = WORD1(v4); v3 |= 0x10u; } if ( v2 >= 0x100 ) { v2 >>= 8; v3 |= 8u; } if ( v2 >= 0x10 ) { v2 >>= 4; v3 |= 4u; } return ((0x3333333322221100uLL >> (4 * (unsigned __int8)v2)) & 3) + v3; }
Fls64: SUB RSP,0x78 MOV qword ptr [RSP + 0x70],RDI LAB_00124ba9: XOR EAX,EAX TEST AL,0x1 JNZ 0x00124bb4 JMP 0x00124c55 LAB_00124bb4: MOV RCX,qword ptr [RSP + 0x70] MOV byte ptr [RSP + 0x37],0x0 XOR EAX,EAX CMP RAX,RCX JZ 0x00124bc7 JMP 0x00124c17 LAB_00124bc7: LEA RDX,[0x2ec3f8] LEA RDI,[RSP + 0x38] MOV qword ptr [RSP + 0x8],RDI MOV ESI,0x3 MOV ECX,0x3d CALL 0x001237e0 MOV RDI,qword ptr [RSP + 0x8] MOV byte ptr [RSP + 0x37],0x1 LAB_00124bf1: LEA RSI,[0x2ec48d] CALL 0x001230a0 MOV qword ptr [RSP + 0x10],RAX JMP 0x00124c04 LAB_00124c04: MOV RSI,qword ptr [RSP + 0x10] LEA RDI,[RSP + 0x23] CALL 0x00123250 LAB_00124c13: JMP 0x00124c15 LAB_00124c15: JMP 0x00124c17 LAB_00124c17: TEST byte ptr [RSP + 0x37],0x1 JNZ 0x00124c20 JMP 0x00124c2a LAB_00124c20: LEA RDI,[RSP + 0x38] CALL 0x00123820 LAB_00124c2a: JMP 0x00124ba9 LAB_00124c55: MOV dword ptr [RSP + 0x1c],0x0 MOV RAX,0x100000000 CMP qword ptr [RSP + 0x70],RAX JC 0x00124c87 MOV RAX,qword ptr [RSP + 0x70] SHR RAX,0x20 MOV qword ptr [RSP + 0x70],RAX MOV EAX,dword ptr [RSP + 0x1c] OR EAX,0x20 MOV dword ptr [RSP + 0x1c],EAX LAB_00124c87: JMP 0x00124c89 LAB_00124c89: MOV RAX,qword ptr [RSP + 0x70] MOV dword ptr [RSP + 0x18],EAX CMP dword ptr [RSP + 0x18],0x10000 JC 0x00124cb2 MOV EAX,dword ptr [RSP + 0x18] SHR EAX,0x10 MOV dword ptr [RSP + 0x18],EAX MOV EAX,dword ptr [RSP + 0x1c] OR EAX,0x10 MOV dword ptr [RSP + 0x1c],EAX LAB_00124cb2: JMP 0x00124cb4 LAB_00124cb4: JMP 0x00124cb6 LAB_00124cb6: CMP dword ptr [RSP + 0x18],0x100 JC 0x00124cd6 MOV EAX,dword ptr [RSP + 0x18] SHR EAX,0x8 MOV dword ptr [RSP + 0x18],EAX MOV EAX,dword ptr [RSP + 0x1c] OR EAX,0x8 MOV dword ptr [RSP + 0x1c],EAX LAB_00124cd6: JMP 0x00124cd8 LAB_00124cd8: JMP 0x00124cda LAB_00124cda: CMP dword ptr [RSP + 0x18],0x10 JC 0x00124cf7 MOV EAX,dword ptr [RSP + 0x18] SHR EAX,0x4 MOV dword ptr [RSP + 0x18],EAX MOV EAX,dword ptr [RSP + 0x1c] OR EAX,0x4 MOV dword ptr [RSP + 0x1c],EAX LAB_00124cf7: JMP 0x00124cf9 LAB_00124cf9: MOVSXD RAX,dword ptr [RSP + 0x1c] MOV ECX,dword ptr [RSP + 0x18] SHL ECX,0x2 MOV ECX,ECX MOV RDX,0x3333333322221100 SHR RDX,CL MOV RCX,RDX AND RCX,0x3 ADD RAX,RCX ADD RSP,0x78 RET
/* WARNING: Removing unreachable block (ram,0x00124bb4) */ /* WARNING: Removing unreachable block (ram,0x00124bc7) */ /* WARNING: Removing unreachable block (ram,0x00124bc5) */ /* WARNING: Removing unreachable block (ram,0x00124c17) */ /* WARNING: Removing unreachable block (ram,0x00124c20) */ /* WARNING: Removing unreachable block (ram,0x00124c1e) */ /* WARNING: Removing unreachable block (ram,0x00124c2a) */ /* google::protobuf::Fls64(unsigned long) */ long google::protobuf::Fls64(ulong param_1) { int4 local_60; int4 local_5c; int8 local_8; local_5c = 0; local_8 = param_1; if (0xffffffff < param_1) { local_8 = param_1 >> 0x20; local_5c = 0x20; } local_60 = (uint)local_8; if (0xffff < local_60) { local_60 = local_60 >> 0x10; local_5c = local_5c | 0x10; } if (0xff < local_60) { local_60 = local_60 >> 8; local_5c = local_5c | 8; } if (0xf < local_60) { local_60 = local_60 >> 4; local_5c = local_5c | 4; } return (long)(int)local_5c + (0x3333333322221100U >> ((byte)(local_60 << 2) & 0x3f) & 3); }
56,887
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::start_array(unsigned long)
monkey531[P]llama/common/./json.hpp
bool start_array(std::size_t len) { ref_stack.push_back(handle_value(BasicJsonType::value_t::array)); if (JSON_HEDLEY_UNLIKELY(len != static_cast<std::size_t>(-1) && len > ref_stack.back()->max_size())) { JSON_THROW(out_of_range::create(408, concat("excessive array size: ", std::to_string(len)), ref_stack.back())); } return true; }
O0
cpp
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::start_array(unsigned long): subq $0x98, %rsp movq %rdi, 0x90(%rsp) movq %rsi, 0x88(%rsp) movq 0x90(%rsp), %rdi movq %rdi, 0x18(%rsp) movq %rdi, %rax addq $0x8, %rax movq %rax, 0x20(%rsp) movb $0x2, 0x7f(%rsp) leaq 0x7f(%rsp), %rsi callq 0xc3dc0 movq 0x20(%rsp), %rdi movq %rax, 0x80(%rsp) leaq 0x80(%rsp), %rsi callq 0xc3d90 xorl %eax, %eax cmpq $-0x1, 0x88(%rsp) movb %al, 0x2a(%rsp) je 0xc3a3f movq 0x18(%rsp), %rdi movq 0x88(%rsp), %rax movq %rax, 0x10(%rsp) addq $0x8, %rdi callq 0xb9880 movq (%rax), %rdi callq 0xb98c0 movq %rax, %rcx movq 0x10(%rsp), %rax cmpq %rcx, %rax seta %al movb %al, 0x2a(%rsp) movb 0x2a(%rsp), %al xorb $-0x1, %al xorb $-0x1, %al testb $0x1, %al jne 0xc3a50 jmp 0xc3b2d movb $0x1, 0x2b(%rsp) movl $0x20, %edi callq 0x50540 movq %rax, 0x8(%rsp) movq 0x88(%rsp), %rsi leaq 0x38(%rsp), %rdi callq 0xb9ba0 jmp 0xc3a78 leaq 0x10bb57(%rip), %rsi # 0x1cf5d6 leaq 0x58(%rsp), %rdi leaq 0x38(%rsp), %rdx callq 0xbe250 jmp 0xc3a90 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xb9880 movq 0x8(%rsp), %rdi movq (%rax), %rcx movl $0x198, %esi # imm = 0x198 leaq 0x58(%rsp), %rdx callq 0xb9940 jmp 0xc3ab7 movq 0x8(%rsp), %rdi movb $0x0, 0x2b(%rsp) leaq 0x18e718(%rip), %rsi # 0x2521e0 leaq -0xab8f(%rip), %rdx # 0xb8f40 callq 0x508f0 jmp 0xc3b43 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x30(%rsp) movl %eax, 0x2c(%rsp) jmp 0xc3b18 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x30(%rsp) movl %eax, 0x2c(%rsp) jmp 0xc3b0e movq %rax, %rcx movl %edx, %eax movq %rcx, 0x30(%rsp) movl %eax, 0x2c(%rsp) leaq 0x58(%rsp), %rdi callq 0x510c0 leaq 0x38(%rsp), %rdi callq 0x510c0 testb $0x1, 0x2b(%rsp) jne 0xc3b21 jmp 0xc3b2b movq 0x8(%rsp), %rdi callq 0x50c40 jmp 0xc3b39 movb $0x1, %al andb $0x1, %al addq $0x98, %rsp retq movq 0x30(%rsp), %rdi callq 0x50940 nopw %cs:(%rax,%rax) nopl (%rax)
_ZN8nlohmann16json_abi_v3_11_36detail19json_sax_dom_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE11start_arrayEm: sub rsp, 98h mov qword ptr [rsp+98h+var_8], rdi; char mov [rsp+98h+var_10], rsi; int mov rdi, qword ptr [rsp+98h+var_8] mov qword ptr [rsp+98h+var_80], rdi; char mov rax, rdi add rax, 8 mov qword ptr [rsp+98h+var_78], rax; int mov [rsp+98h+var_19], 2 lea rsi, [rsp+98h+var_19] call _ZN8nlohmann16json_abi_v3_11_36detail19json_sax_dom_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12handle_valueINS1_7value_tEEEPSF_OT_; nlohmann::json_abi_v3_11_3::detail::json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::handle_value<nlohmann::json_abi_v3_11_3::detail::value_t>(nlohmann::json_abi_v3_11_3::detail::value_t &&) mov rdi, qword ptr [rsp+98h+var_78] mov qword ptr [rsp+98h+var_18], rax; int lea rsi, [rsp+98h+var_18] call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE9push_backEOSE_; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::push_back(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *&&) xor eax, eax cmp [rsp+98h+var_10], 0FFFFFFFFFFFFFFFFh mov [rsp+98h+var_6E], al jz short loc_C3A3F mov rdi, qword ptr [rsp+98h+var_80] mov rax, [rsp+98h+var_10] mov qword ptr [rsp+98h+var_88], rax; int add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rdi, [rax] call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8max_sizeEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::max_size(void) mov rcx, rax mov rax, qword ptr [rsp+98h+var_88] cmp rax, rcx setnbe al mov [rsp+98h+var_6E], al loc_C3A3F: mov al, [rsp+98h+var_6E] xor al, 0FFh xor al, 0FFh test al, 1 jnz short loc_C3A50 jmp loc_C3B2D loc_C3A50: mov [rsp+98h+var_6D], 1 mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov [rsp+98h+var_90], rax; int mov rsi, [rsp+98h+var_10]; unsigned __int64 lea rdi, [rsp+98h+var_60]; this call _ZNSt7__cxx119to_stringEm; std::to_string(ulong) jmp short $+2 loc_C3A78: lea rsi, aExcessiveArray; "excessive array size: " lea rdi, [rsp+98h+var_40] lea rdx, [rsp+98h+var_60] call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA23_KcS8_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[23],std::string>(char const(&)[23],std::string &&) jmp short $+2 loc_C3A90: mov rdi, qword ptr [rsp+98h+var_80] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rdi, [rsp+98h+var_90]; int mov rcx, [rax] mov esi, 198h lea rdx, [rsp+98h+var_40] call _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ jmp short $+2 loc_C3AB7: mov rdi, [rsp+98h+var_90]; void * mov [rsp+98h+var_6D], 0 lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail12out_of_rangeE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail12out_of_rangeD2Ev; void (*)(void *) call ___cxa_throw jmp short loc_C3B43 mov rcx, rax mov eax, edx mov [rsp+arg_28], rcx mov [rsp+arg_24], eax jmp short loc_C3B18 mov rcx, rax mov eax, edx mov [rsp+arg_28], rcx mov [rsp+arg_24], eax jmp short loc_C3B0E mov rcx, rax mov eax, edx mov [rsp+arg_28], rcx mov [rsp+arg_24], eax lea rdi, [rsp+arg_50]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_C3B0E: lea rdi, [rsp+arg_30]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_C3B18: test [rsp+arg_23], 1 jnz short loc_C3B21 jmp short loc_C3B2B loc_C3B21: mov rdi, [rsp+arg_0]; void * call ___cxa_free_exception loc_C3B2B: jmp short loc_C3B39 loc_C3B2D: mov al, 1 and al, 1 add rsp, 98h retn loc_C3B39: mov rdi, [rsp+arg_28] call __Unwind_Resume loc_C3B43: nop word ptr [rax+rax+00000000h] nop dword ptr [rax]
char nlohmann::json_abi_v3_11_3::detail::json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::start_array( long long a1, unsigned long long a2) { long long *v2; // rax long long *v3; // rax nlohmann::json_abi_v3_11_3::detail::out_of_range *exception; // [rsp+8h] [rbp-90h] unsigned long long v6; // [rsp+10h] [rbp-88h] bool v7; // [rsp+2Ah] [rbp-6Eh] _BYTE v8[32]; // [rsp+38h] [rbp-60h] BYREF _BYTE v9[39]; // [rsp+58h] [rbp-40h] BYREF char v10; // [rsp+7Fh] [rbp-19h] BYREF int v11[2]; // [rsp+80h] [rbp-18h] BYREF unsigned long long v12; // [rsp+88h] [rbp-10h] char v13[8]; // [rsp+90h] [rbp-8h] *(_QWORD *)v13 = a1; v12 = a2; v10 = 2; *(_QWORD *)v11 = nlohmann::json_abi_v3_11_3::detail::json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::handle_value<nlohmann::json_abi_v3_11_3::detail::value_t>( a1, &v10); std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *>>::push_back( a1 + 8, v11); v7 = 0; if ( v12 != -1LL ) { v6 = v12; v2 = (long long *)std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *>>::back(a1 + 8); v7 = v6 > 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>::max_size(*v2); } if ( v7 ) { exception = (nlohmann::json_abi_v3_11_3::detail::out_of_range *)__cxa_allocate_exception(0x20uLL); std::to_string((std::__cxx11 *)v8, v12); nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[23],std::string>( (long long)v9, (long long)"excessive array size: ", (nlohmann::json_abi_v3_11_3::detail *)v8); v3 = (long long *)std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *>>::back(a1 + 8); ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_( exception, 408, (long long)v9, *v3); __cxa_throw( exception, (struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::out_of_range, (void (*)(void *))nlohmann::json_abi_v3_11_3::detail::out_of_range::~out_of_range); } return 1; }
start_array: SUB RSP,0x98 MOV qword ptr [RSP + 0x90],RDI MOV qword ptr [RSP + 0x88],RSI MOV RDI,qword ptr [RSP + 0x90] MOV qword ptr [RSP + 0x18],RDI MOV RAX,RDI ADD RAX,0x8 MOV qword ptr [RSP + 0x20],RAX MOV byte ptr [RSP + 0x7f],0x2 LEA RSI,[RSP + 0x7f] CALL 0x001c3dc0 MOV RDI,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x80],RAX LEA RSI,[RSP + 0x80] CALL 0x001c3d90 XOR EAX,EAX CMP qword ptr [RSP + 0x88],-0x1 MOV byte ptr [RSP + 0x2a],AL JZ 0x001c3a3f MOV RDI,qword ptr [RSP + 0x18] MOV RAX,qword ptr [RSP + 0x88] MOV qword ptr [RSP + 0x10],RAX ADD RDI,0x8 CALL 0x001b9880 MOV RDI,qword ptr [RAX] CALL 0x001b98c0 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x10] CMP RAX,RCX SETA AL MOV byte ptr [RSP + 0x2a],AL LAB_001c3a3f: MOV AL,byte ptr [RSP + 0x2a] XOR AL,0xff XOR AL,0xff TEST AL,0x1 JNZ 0x001c3a50 JMP 0x001c3b2d LAB_001c3a50: MOV byte ptr [RSP + 0x2b],0x1 MOV EDI,0x20 CALL 0x00150540 MOV qword ptr [RSP + 0x8],RAX MOV RSI,qword ptr [RSP + 0x88] LAB_001c3a6c: LEA RDI,[RSP + 0x38] CALL 0x001b9ba0 JMP 0x001c3a78 LAB_001c3a78: LEA RSI,[0x2cf5d6] LEA RDI,[RSP + 0x58] LEA RDX,[RSP + 0x38] CALL 0x001be250 JMP 0x001c3a90 LAB_001c3a90: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001b9880 MOV RDI,qword ptr [RSP + 0x8] MOV RCX,qword ptr [RAX] LAB_001c3aa6: MOV ESI,0x198 LEA RDX,[RSP + 0x58] CALL 0x001b9940 JMP 0x001c3ab7 LAB_001c3ab7: MOV RDI,qword ptr [RSP + 0x8] MOV byte ptr [RSP + 0x2b],0x0 LEA RSI,[0x3521e0] LEA RDX,[0x1b8f40] CALL 0x001508f0 LAB_001c3b2d: MOV AL,0x1 AND AL,0x1 ADD RSP,0x98 RET
/* nlohmann::json_abi_v3_11_3::detail::json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> >::start_array(unsigned long) */ int8 __thiscall nlohmann::json_abi_v3_11_3::detail:: json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::start_array(json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *this,ulong param_1) { bool bVar1; ulong uVar2; int8 *puVar3; ulong uVar4; int7 uVar6; int8 uVar5; __cxx11 local_60 [32]; detail local_40 [39]; value_t local_19; basic_json *local_18; ulong local_10; json_sax_dom_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *local_8; local_19 = 2; local_10 = param_1; local_8 = this; local_18 = handle_value<nlohmann::json_abi_v3_11_3::detail::value_t>(this,&local_19); std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::push_back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8),&local_18); uVar2 = local_10; uVar6 = 0; bVar1 = false; if (local_10 != 0xffffffffffffffff) { puVar3 = (int8 *) std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); uVar4 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::max_size((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *)*puVar3); bVar1 = uVar4 < uVar2; uVar6 = (int7)(uVar2 >> 8); } if (!bVar1) { return CONCAT71(uVar6,1); } uVar5 = __cxa_allocate_exception(0x20); /* try { // try from 001c3a6c to 001c3a75 has its CatchHandler @ 001c3ad6 */ std::__cxx11::to_string(local_60,local_10); /* try { // try from 001c3a78 to 001c3a8d has its CatchHandler @ 001c3ae6 */ concat<std::__cxx11::string,char_const(&)[23],std::__cxx11::string> (local_40,"excessive array size: ",(string *)local_60); puVar3 = (int8 *) std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); /* try { // try from 001c3aa6 to 001c3ad3 has its CatchHandler @ 001c3af6 */ _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ (uVar5,0x198,local_40,*puVar3); /* WARNING: Subroutine does not return */ __cxa_throw(uVar5,&out_of_range::typeinfo,out_of_range::~out_of_range); }
56,888
mi_end_bulk_insert
eloqsql/storage/myisam/mi_write.c
int mi_end_bulk_insert(MI_INFO *info, my_bool abort) { int first_error= 0; if (info->bulk_insert) { uint i; for (i=0 ; i < info->s->base.keys ; i++) { if (is_tree_inited(& info->bulk_insert[i])) { int error; if ((error= delete_tree(& info->bulk_insert[i], abort))) { first_error= first_error ? first_error : error; abort= 1; } } } my_free(info->bulk_insert); info->bulk_insert=0; } return first_error; }
O0
c
mi_end_bulk_insert: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movb %sil, %al movq %rdi, -0x8(%rbp) movb %al, -0x9(%rbp) movl $0x0, -0x10(%rbp) movq -0x8(%rbp), %rax cmpq $0x0, 0x80(%rax) je 0xcb64a movl $0x0, -0x14(%rbp) movl -0x14(%rbp), %eax movq -0x8(%rbp), %rcx movq (%rcx), %rcx cmpl 0x180(%rcx), %eax jae 0xcb62b movq -0x8(%rbp), %rax movq 0x80(%rax), %rax movl -0x14(%rbp), %ecx imulq $0x298, %rcx, %rcx # imm = 0x298 addq %rcx, %rax cmpq $0x0, (%rax) je 0xcb61b movq -0x8(%rbp), %rax movq 0x80(%rax), %rdi movl -0x14(%rbp), %eax imulq $0x298, %rax, %rax # imm = 0x298 addq %rax, %rdi movsbl -0x9(%rbp), %esi callq 0x100e90 movl %eax, -0x18(%rbp) cmpl $0x0, %eax je 0xcb619 cmpl $0x0, -0x10(%rbp) je 0xcb609 movl -0x10(%rbp), %eax movl %eax, -0x1c(%rbp) jmp 0xcb60f movl -0x18(%rbp), %eax movl %eax, -0x1c(%rbp) movl -0x1c(%rbp), %eax movl %eax, -0x10(%rbp) movb $0x1, -0x9(%rbp) jmp 0xcb61b jmp 0xcb61d movl -0x14(%rbp), %eax addl $0x1, %eax movl %eax, -0x14(%rbp) jmp 0xcb5a2 movq -0x8(%rbp), %rax movq 0x80(%rax), %rdi callq 0xfa370 movq -0x8(%rbp), %rax movq $0x0, 0x80(%rax) movl -0x10(%rbp), %eax addq $0x20, %rsp popq %rbp retq nopw %cs:(%rax,%rax) nopl (%rax)
mi_end_bulk_insert: push rbp mov rbp, rsp sub rsp, 20h mov al, sil mov [rbp+var_8], rdi mov [rbp+var_9], al mov [rbp+var_10], 0 mov rax, [rbp+var_8] cmp qword ptr [rax+80h], 0 jz loc_CB64A mov [rbp+var_14], 0 loc_CB5A2: mov eax, [rbp+var_14] mov rcx, [rbp+var_8] mov rcx, [rcx] cmp eax, [rcx+180h] jnb short loc_CB62B mov rax, [rbp+var_8] mov rax, [rax+80h] mov ecx, [rbp+var_14] imul rcx, 298h add rax, rcx cmp qword ptr [rax], 0 jz short loc_CB61B mov rax, [rbp+var_8] mov rdi, [rax+80h] mov eax, [rbp+var_14] imul rax, 298h add rdi, rax movsx esi, [rbp+var_9] call delete_tree mov [rbp+var_18], eax cmp eax, 0 jz short loc_CB619 cmp [rbp+var_10], 0 jz short loc_CB609 mov eax, [rbp+var_10] mov [rbp+var_1C], eax jmp short loc_CB60F loc_CB609: mov eax, [rbp+var_18] mov [rbp+var_1C], eax loc_CB60F: mov eax, [rbp+var_1C] mov [rbp+var_10], eax mov [rbp+var_9], 1 loc_CB619: jmp short $+2 loc_CB61B: jmp short $+2 loc_CB61D: mov eax, [rbp+var_14] add eax, 1 mov [rbp+var_14], eax jmp loc_CB5A2 loc_CB62B: mov rax, [rbp+var_8] mov rdi, [rax+80h] call my_free mov rax, [rbp+var_8] mov qword ptr [rax+80h], 0 loc_CB64A: mov eax, [rbp+var_10] add rsp, 20h pop rbp retn
long long mi_end_bulk_insert(_QWORD *a1, char a2) { int v3; // [rsp+4h] [rbp-1Ch] int v4; // [rsp+8h] [rbp-18h] unsigned int i; // [rsp+Ch] [rbp-14h] unsigned int v6; // [rsp+10h] [rbp-10h] v6 = 0; if ( a1[16] ) { for ( i = 0; i < *(_DWORD *)(*a1 + 384LL); ++i ) { if ( *(_QWORD *)(664LL * i + a1[16]) ) { v4 = delete_tree(664LL * i + a1[16], (unsigned int)a2); if ( v4 ) { if ( v6 ) v3 = v6; else v3 = v4; v6 = v3; a2 = 1; } } } my_free(a1[16]); a1[16] = 0LL; } return v6; }
mi_end_bulk_insert: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV AL,SIL MOV qword ptr [RBP + -0x8],RDI MOV byte ptr [RBP + -0x9],AL MOV dword ptr [RBP + -0x10],0x0 MOV RAX,qword ptr [RBP + -0x8] CMP qword ptr [RAX + 0x80],0x0 JZ 0x001cb64a MOV dword ptr [RBP + -0x14],0x0 LAB_001cb5a2: MOV EAX,dword ptr [RBP + -0x14] MOV RCX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RCX] CMP EAX,dword ptr [RCX + 0x180] JNC 0x001cb62b MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x80] MOV ECX,dword ptr [RBP + -0x14] IMUL RCX,RCX,0x298 ADD RAX,RCX CMP qword ptr [RAX],0x0 JZ 0x001cb61b MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX + 0x80] MOV EAX,dword ptr [RBP + -0x14] IMUL RAX,RAX,0x298 ADD RDI,RAX MOVSX ESI,byte ptr [RBP + -0x9] CALL 0x00200e90 MOV dword ptr [RBP + -0x18],EAX CMP EAX,0x0 JZ 0x001cb619 CMP dword ptr [RBP + -0x10],0x0 JZ 0x001cb609 MOV EAX,dword ptr [RBP + -0x10] MOV dword ptr [RBP + -0x1c],EAX JMP 0x001cb60f LAB_001cb609: MOV EAX,dword ptr [RBP + -0x18] MOV dword ptr [RBP + -0x1c],EAX LAB_001cb60f: MOV EAX,dword ptr [RBP + -0x1c] MOV dword ptr [RBP + -0x10],EAX MOV byte ptr [RBP + -0x9],0x1 LAB_001cb619: JMP 0x001cb61b LAB_001cb61b: JMP 0x001cb61d LAB_001cb61d: MOV EAX,dword ptr [RBP + -0x14] ADD EAX,0x1 MOV dword ptr [RBP + -0x14],EAX JMP 0x001cb5a2 LAB_001cb62b: MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX + 0x80] CALL 0x001fa370 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x80],0x0 LAB_001cb64a: MOV EAX,dword ptr [RBP + -0x10] ADD RSP,0x20 POP RBP RET
int mi_end_bulk_insert(long *param_1,char param_2) { int local_24; uint local_1c; int local_18; char local_11; local_18 = 0; if (param_1[0x10] != 0) { local_11 = param_2; for (local_1c = 0; local_1c < *(uint *)(*param_1 + 0x180); local_1c = local_1c + 1) { if ((*(long *)(param_1[0x10] + (ulong)local_1c * 0x298) != 0) && (local_24 = delete_tree(param_1[0x10] + (ulong)local_1c * 0x298,(int)local_11), local_24 != 0)) { if (local_18 != 0) { local_24 = local_18; } local_18 = local_24; local_11 = '\x01'; } } my_free(param_1[0x10]); param_1[0x10] = 0; } return local_18; }
56,889
ggml_cpu_extra_compute_forward
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu-traits.cpp
bool ggml_cpu_extra_compute_forward(struct ggml_compute_params * params, struct ggml_tensor * op) { for (auto extra : ggml_backend_cpu_get_extra_buffers_type()) { if (extra && extra->context) { auto buf_extra = (ggml::cpu::extra_buffer_type *) extra->context; auto tensor_traits = buf_extra->get_tensor_traits(op); if (tensor_traits && tensor_traits->compute_forward(params, op)) { return true; } } } return false; }
O0
cpp
ggml_cpu_extra_compute_forward: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) callq 0xd1c0 movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rdi callq 0xe3c0 movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rdi callq 0xe330 movq %rax, -0x30(%rbp) leaq -0x28(%rbp), %rdi leaq -0x30(%rbp), %rsi callq 0xe2a0 testb $0x1, %al jne 0x722a6 jmp 0x7231d leaq -0x28(%rbp), %rdi callq 0xe2c0 movq (%rax), %rax movq %rax, -0x38(%rbp) cmpq $0x0, -0x38(%rbp) je 0x7230d movq -0x38(%rbp), %rax cmpq $0x0, 0x38(%rax) je 0x7230d movq -0x38(%rbp), %rax movq 0x38(%rax), %rax movq %rax, -0x40(%rbp) movq -0x40(%rbp), %rdi movq -0x18(%rbp), %rsi movq (%rdi), %rax callq *0x18(%rax) movq %rax, -0x48(%rbp) cmpq $0x0, -0x48(%rbp) je 0x7230b movq -0x48(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq (%rdi), %rax callq *0x18(%rax) testb $0x1, %al jne 0x72305 jmp 0x7230b movb $0x1, -0x1(%rbp) jmp 0x72321 jmp 0x7230d jmp 0x7230f leaq -0x28(%rbp), %rdi callq 0xd840 jmp 0x72293 movb $0x0, -0x1(%rbp) movb -0x1(%rbp), %al andb $0x1, %al addq $0x50, %rsp popq %rbp retq nopl (%rax)
ggml_cpu_extra_compute_forward: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_10], rdi mov [rbp+var_18], rsi call __Z39ggml_backend_cpu_get_extra_buffers_typev; ggml_backend_cpu_get_extra_buffers_type(void) mov [rbp+var_20], rax mov rdi, [rbp+var_20] call __ZNSt6vectorIP24ggml_backend_buffer_typeSaIS1_EE5beginEv; std::vector<ggml_backend_buffer_type *>::begin(void) mov [rbp+var_28], rax mov rdi, [rbp+var_20] call __ZNSt6vectorIP24ggml_backend_buffer_typeSaIS1_EE3endEv; std::vector<ggml_backend_buffer_type *>::end(void) mov [rbp+var_30], rax loc_72293: lea rdi, [rbp+var_28] lea rsi, [rbp+var_30] call __ZN9__gnu_cxxneIPP24ggml_backend_buffer_typeSt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESC_; __gnu_cxx::operator!=<ggml_backend_buffer_type **,std::vector<ggml_backend_buffer_type *>>(__gnu_cxx::__normal_iterator<ggml_backend_buffer_type **,std::vector<ggml_backend_buffer_type *>> const&,__gnu_cxx::__normal_iterator<ggml_backend_buffer_type **,std::vector<ggml_backend_buffer_type *>> const&) test al, 1 jnz short loc_722A6 jmp short loc_7231D loc_722A6: lea rdi, [rbp+var_28] call __ZNK9__gnu_cxx17__normal_iteratorIPP24ggml_backend_buffer_typeSt6vectorIS2_SaIS2_EEEdeEv; __gnu_cxx::__normal_iterator<ggml_backend_buffer_type **,std::vector<ggml_backend_buffer_type *>>::operator*(void) mov rax, [rax] mov [rbp+var_38], rax cmp [rbp+var_38], 0 jz short loc_7230D mov rax, [rbp+var_38] cmp qword ptr [rax+38h], 0 jz short loc_7230D mov rax, [rbp+var_38] mov rax, [rax+38h] mov [rbp+var_40], rax mov rdi, [rbp+var_40] mov rsi, [rbp+var_18] mov rax, [rdi] call qword ptr [rax+18h] mov [rbp+var_48], rax cmp [rbp+var_48], 0 jz short loc_7230B mov rdi, [rbp+var_48] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rax, [rdi] call qword ptr [rax+18h] test al, 1 jnz short loc_72305 jmp short loc_7230B loc_72305: mov [rbp+var_1], 1 jmp short loc_72321 loc_7230B: jmp short $+2 loc_7230D: jmp short $+2 loc_7230F: lea rdi, [rbp+var_28] call __ZN9__gnu_cxx17__normal_iteratorIPP24ggml_backend_buffer_typeSt6vectorIS2_SaIS2_EEEppEv; __gnu_cxx::__normal_iterator<ggml_backend_buffer_type **,std::vector<ggml_backend_buffer_type *>>::operator++(void) jmp loc_72293 loc_7231D: mov [rbp+var_1], 0 loc_72321: mov al, [rbp+var_1] and al, 1 add rsp, 50h pop rbp retn
char ggml_cpu_extra_compute_forward(long long a1, long long a2) { long long v3; // [rsp+8h] [rbp-48h] long long v4; // [rsp+18h] [rbp-38h] long long v5; // [rsp+20h] [rbp-30h] BYREF long long v6; // [rsp+28h] [rbp-28h] BYREF long long extra_buffers_type; // [rsp+30h] [rbp-20h] long long v8; // [rsp+38h] [rbp-18h] long long v9; // [rsp+40h] [rbp-10h] v9 = a1; v8 = a2; extra_buffers_type = ggml_backend_cpu_get_extra_buffers_type(); v6 = std::vector<ggml_backend_buffer_type *>::begin(extra_buffers_type); v5 = std::vector<ggml_backend_buffer_type *>::end(extra_buffers_type); while ( (__gnu_cxx::operator!=<ggml_backend_buffer_type **,std::vector<ggml_backend_buffer_type *>>(&v6, &v5) & 1) != 0 ) { v4 = *(_QWORD *)__gnu_cxx::__normal_iterator<ggml_backend_buffer_type **,std::vector<ggml_backend_buffer_type *>>::operator*(&v6); if ( v4 ) { if ( *(_QWORD *)(v4 + 56) ) { v3 = (*(long long ( **)(_QWORD, long long))(**(_QWORD **)(v4 + 56) + 24LL))(*(_QWORD *)(v4 + 56), v8); if ( v3 ) { if ( ((*(long long ( **)(long long, long long, long long))(*(_QWORD *)v3 + 24LL))(v3, v9, v8) & 1) != 0 ) return 1; } } } __gnu_cxx::__normal_iterator<ggml_backend_buffer_type **,std::vector<ggml_backend_buffer_type *>>::operator++(&v6); } return 0; }
ggml_cpu_extra_compute_forward: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI CALL 0x0010d1c0 MOV qword ptr [RBP + -0x20],RAX MOV RDI,qword ptr [RBP + -0x20] CALL 0x0010e3c0 MOV qword ptr [RBP + -0x28],RAX MOV RDI,qword ptr [RBP + -0x20] CALL 0x0010e330 MOV qword ptr [RBP + -0x30],RAX LAB_00172293: LEA RDI,[RBP + -0x28] LEA RSI,[RBP + -0x30] CALL 0x0010e2a0 TEST AL,0x1 JNZ 0x001722a6 JMP 0x0017231d LAB_001722a6: LEA RDI,[RBP + -0x28] CALL 0x0010e2c0 MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x38],RAX CMP qword ptr [RBP + -0x38],0x0 JZ 0x0017230d MOV RAX,qword ptr [RBP + -0x38] CMP qword ptr [RAX + 0x38],0x0 JZ 0x0017230d MOV RAX,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RAX + 0x38] MOV qword ptr [RBP + -0x40],RAX MOV RDI,qword ptr [RBP + -0x40] MOV RSI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x18] MOV qword ptr [RBP + -0x48],RAX CMP qword ptr [RBP + -0x48],0x0 JZ 0x0017230b MOV RDI,qword ptr [RBP + -0x48] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x18] TEST AL,0x1 JNZ 0x00172305 JMP 0x0017230b LAB_00172305: MOV byte ptr [RBP + -0x1],0x1 JMP 0x00172321 LAB_0017230b: JMP 0x0017230d LAB_0017230d: JMP 0x0017230f LAB_0017230f: LEA RDI,[RBP + -0x28] CALL 0x0010d840 JMP 0x00172293 LAB_0017231d: MOV byte ptr [RBP + -0x1],0x0 LAB_00172321: MOV AL,byte ptr [RBP + -0x1] AND AL,0x1 ADD RSP,0x50 POP RBP RET
int1 ggml_cpu_extra_compute_forward(int8 param_1,int8 param_2) { long lVar1; bool bVar2; long *plVar3; ulong uVar4; int8 local_38; int8 local_30; vector<ggml_backend_buffer_type*,std::allocator<ggml_backend_buffer_type*>> *local_28; int8 local_20; int8 local_18; local_20 = param_2; local_18 = param_1; local_28 = (vector<ggml_backend_buffer_type*,std::allocator<ggml_backend_buffer_type*>> *) ggml_backend_cpu_get_extra_buffers_type(); local_30 = std::vector<ggml_backend_buffer_type*,std::allocator<ggml_backend_buffer_type*>>::begin (local_28); local_38 = std::vector<ggml_backend_buffer_type*,std::allocator<ggml_backend_buffer_type*>>::end (local_28); while( true ) { bVar2 = __gnu_cxx::operator!=((__normal_iterator *)&local_30,(__normal_iterator *)&local_38); if (!bVar2) { return 0; } plVar3 = (long *)__gnu_cxx:: __normal_iterator<ggml_backend_buffer_type**,std::vector<ggml_backend_buffer_type*,std::allocator<ggml_backend_buffer_type*>>> ::operator*((__normal_iterator<ggml_backend_buffer_type**,std::vector<ggml_backend_buffer_type*,std::allocator<ggml_backend_buffer_type*>>> *)&local_30); lVar1 = *plVar3; if ((((lVar1 != 0) && (*(long *)(lVar1 + 0x38) != 0)) && (plVar3 = (long *)(**(code **)(**(long **)(lVar1 + 0x38) + 0x18)) (*(long **)(lVar1 + 0x38),local_20), plVar3 != (long *)0x0)) && (uVar4 = (**(code **)(*plVar3 + 0x18))(plVar3,local_18,local_20), (uVar4 & 1) != 0)) break; __gnu_cxx:: __normal_iterator<ggml_backend_buffer_type**,std::vector<ggml_backend_buffer_type*,std::allocator<ggml_backend_buffer_type*>>> ::operator++((__normal_iterator<ggml_backend_buffer_type**,std::vector<ggml_backend_buffer_type*,std::allocator<ggml_backend_buffer_type*>>> *)&local_30); } return 1; }
56,890
ggml_cpu_extra_compute_forward
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu-traits.cpp
bool ggml_cpu_extra_compute_forward(struct ggml_compute_params * params, struct ggml_tensor * op) { for (auto extra : ggml_backend_cpu_get_extra_buffers_type()) { if (extra && extra->context) { auto buf_extra = (ggml::cpu::extra_buffer_type *) extra->context; auto tensor_traits = buf_extra->get_tensor_traits(op); if (tensor_traits && tensor_traits->compute_forward(params, op)) { return true; } } } return false; }
O2
cpp
ggml_cpu_extra_compute_forward: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r14 callq 0x8160 movq (%rax), %r15 movq 0x8(%rax), %r12 cmpq %r12, %r15 je 0x32507 movq (%r15), %rax testq %rax, %rax je 0x32501 movq 0x38(%rax), %rdi testq %rdi, %rdi je 0x32501 movq (%rdi), %rax movq %rbx, %rsi callq *0x18(%rax) testq %rax, %rax je 0x32501 movq (%rax), %rcx movq %rax, %rdi movq %r14, %rsi movq %rbx, %rdx callq *0x18(%rcx) testb %al, %al jne 0x32507 addq $0x8, %r15 jmp 0x324ca cmpq %r12, %r15 setne %al addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
ggml_cpu_extra_compute_forward: push r15 push r14 push r12 push rbx push rax mov rbx, rsi mov r14, rdi call __Z39ggml_backend_cpu_get_extra_buffers_typev; ggml_backend_cpu_get_extra_buffers_type(void) mov r15, [rax] mov r12, [rax+8] loc_324CA: cmp r15, r12 jz short loc_32507 mov rax, [r15] test rax, rax jz short loc_32501 mov rdi, [rax+38h] test rdi, rdi jz short loc_32501 mov rax, [rdi] mov rsi, rbx call qword ptr [rax+18h] test rax, rax jz short loc_32501 mov rcx, [rax] mov rdi, rax mov rsi, r14 mov rdx, rbx call qword ptr [rcx+18h] test al, al jnz short loc_32507 loc_32501: add r15, 8 jmp short loc_324CA loc_32507: cmp r15, r12 setnz al add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
bool ggml_cpu_extra_compute_forward(long long a1, long long a2) { long long *extra_buffers_type; // rax long long v4; // r15 long long v5; // r12 long long v6; // rdi long long v7; // rax extra_buffers_type = (long long *)ggml_backend_cpu_get_extra_buffers_type(); v4 = *extra_buffers_type; v5 = extra_buffers_type[1]; while ( v4 != v5 ) { if ( *(_QWORD *)v4 ) { v6 = *(_QWORD *)(*(_QWORD *)v4 + 56LL); if ( v6 ) { v7 = (*(long long ( **)(long long, long long))(*(_QWORD *)v6 + 24LL))(v6, a2); if ( v7 ) { if ( (*(unsigned __int8 ( **)(long long, long long, long long))(*(_QWORD *)v7 + 24LL))(v7, a1, a2) ) break; } } } v4 += 8LL; } return v4 != v5; }
ggml_cpu_extra_compute_forward: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RSI MOV R14,RDI CALL 0x00108160 MOV R15,qword ptr [RAX] MOV R12,qword ptr [RAX + 0x8] LAB_001324ca: CMP R15,R12 JZ 0x00132507 MOV RAX,qword ptr [R15] TEST RAX,RAX JZ 0x00132501 MOV RDI,qword ptr [RAX + 0x38] TEST RDI,RDI JZ 0x00132501 MOV RAX,qword ptr [RDI] MOV RSI,RBX CALL qword ptr [RAX + 0x18] TEST RAX,RAX JZ 0x00132501 MOV RCX,qword ptr [RAX] MOV RDI,RAX MOV RSI,R14 MOV RDX,RBX CALL qword ptr [RCX + 0x18] TEST AL,AL JNZ 0x00132507 LAB_00132501: ADD R15,0x8 JMP 0x001324ca LAB_00132507: CMP R15,R12 SETNZ AL ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
bool ggml_cpu_extra_compute_forward(int8 param_1,int8 param_2) { long *plVar1; char cVar2; int8 *puVar3; long *plVar4; long *plVar5; puVar3 = (int8 *)ggml_backend_cpu_get_extra_buffers_type(); plVar1 = (long *)puVar3[1]; for (plVar5 = (long *)*puVar3; plVar5 != plVar1; plVar5 = plVar5 + 1) { if ((*plVar5 != 0) && (plVar4 = *(long **)(*plVar5 + 0x38), plVar4 != (long *)0x0)) { plVar4 = (long *)(**(code **)(*plVar4 + 0x18))(plVar4,param_2); if (plVar4 != (long *)0x0) { cVar2 = (**(code **)(*plVar4 + 0x18))(plVar4,param_1,param_2); if (cVar2 != '\0') break; } } } return plVar5 != plVar1; }
56,891
ggml_cpu_extra_compute_forward
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu-traits.cpp
bool ggml_cpu_extra_compute_forward(struct ggml_compute_params * params, struct ggml_tensor * op) { for (auto extra : ggml_backend_cpu_get_extra_buffers_type()) { if (extra && extra->context) { auto buf_extra = (ggml::cpu::extra_buffer_type *) extra->context; auto tensor_traits = buf_extra->get_tensor_traits(op); if (tensor_traits && tensor_traits->compute_forward(params, op)) { return true; } } } return false; }
O3
cpp
ggml_cpu_extra_compute_forward: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r14 callq 0x8140 movq (%rax), %r15 movq 0x8(%rax), %r12 cmpq %r12, %r15 je 0x35bdf movq (%r15), %rax testq %rax, %rax je 0x35bd9 movq 0x38(%rax), %rdi testq %rdi, %rdi je 0x35bd9 movq (%rdi), %rax movq %rbx, %rsi callq *0x18(%rax) testq %rax, %rax je 0x35bd9 movq (%rax), %rcx movq %rax, %rdi movq %r14, %rsi movq %rbx, %rdx callq *0x18(%rcx) testb %al, %al jne 0x35bed addq $0x8, %r15 jmp 0x35ba2 xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq movb $0x1, %al jmp 0x35be1
ggml_cpu_extra_compute_forward: push r15 push r14 push r12 push rbx push rax mov rbx, rsi mov r14, rdi call __Z39ggml_backend_cpu_get_extra_buffers_typev; ggml_backend_cpu_get_extra_buffers_type(void) mov r15, [rax] mov r12, [rax+8] loc_35BA2: cmp r15, r12 jz short loc_35BDF mov rax, [r15] test rax, rax jz short loc_35BD9 mov rdi, [rax+38h] test rdi, rdi jz short loc_35BD9 mov rax, [rdi] mov rsi, rbx call qword ptr [rax+18h] test rax, rax jz short loc_35BD9 mov rcx, [rax] mov rdi, rax mov rsi, r14 mov rdx, rbx call qword ptr [rcx+18h] test al, al jnz short loc_35BED loc_35BD9: add r15, 8 jmp short loc_35BA2 loc_35BDF: xor eax, eax loc_35BE1: add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn loc_35BED: mov al, 1 jmp short loc_35BE1
char ggml_cpu_extra_compute_forward(long long a1, long long a2) { long long *extra_buffers_type; // rax long long v4; // r15 long long v5; // r12 long long v6; // rdi long long v7; // rax extra_buffers_type = (long long *)ggml_backend_cpu_get_extra_buffers_type(); v4 = *extra_buffers_type; v5 = extra_buffers_type[1]; while ( 1 ) { if ( v4 == v5 ) return 0; if ( *(_QWORD *)v4 ) { v6 = *(_QWORD *)(*(_QWORD *)v4 + 56LL); if ( v6 ) { v7 = (*(long long ( **)(long long, long long))(*(_QWORD *)v6 + 24LL))(v6, a2); if ( v7 ) { if ( (*(unsigned __int8 ( **)(long long, long long, long long))(*(_QWORD *)v7 + 24LL))(v7, a1, a2) ) break; } } } v4 += 8LL; } return 1; }
ggml_cpu_extra_compute_forward: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RSI MOV R14,RDI CALL 0x00108140 MOV R15,qword ptr [RAX] MOV R12,qword ptr [RAX + 0x8] LAB_00135ba2: CMP R15,R12 JZ 0x00135bdf MOV RAX,qword ptr [R15] TEST RAX,RAX JZ 0x00135bd9 MOV RDI,qword ptr [RAX + 0x38] TEST RDI,RDI JZ 0x00135bd9 MOV RAX,qword ptr [RDI] MOV RSI,RBX CALL qword ptr [RAX + 0x18] TEST RAX,RAX JZ 0x00135bd9 MOV RCX,qword ptr [RAX] MOV RDI,RAX MOV RSI,R14 MOV RDX,RBX CALL qword ptr [RCX + 0x18] TEST AL,AL JNZ 0x00135bed LAB_00135bd9: ADD R15,0x8 JMP 0x00135ba2 LAB_00135bdf: XOR EAX,EAX LAB_00135be1: ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET LAB_00135bed: MOV AL,0x1 JMP 0x00135be1
int8 ggml_cpu_extra_compute_forward(int8 param_1,int8 param_2) { long *plVar1; char cVar2; int8 *puVar3; long *plVar4; long *plVar5; puVar3 = (int8 *)ggml_backend_cpu_get_extra_buffers_type(); plVar5 = (long *)*puVar3; plVar1 = (long *)puVar3[1]; while( true ) { if (plVar5 == plVar1) { return 0; } if ((((*plVar5 != 0) && (plVar4 = *(long **)(*plVar5 + 0x38), plVar4 != (long *)0x0)) && (plVar4 = (long *)(**(code **)(*plVar4 + 0x18))(plVar4,param_2), plVar4 != (long *)0x0)) && (cVar2 = (**(code **)(*plVar4 + 0x18))(plVar4,param_1,param_2), cVar2 != '\0')) break; plVar5 = plVar5 + 1; } return 1; }
56,892
my_strcasecmp_utf8mb4
eloqsql/strings/ctype-utf8.c
static int my_strcasecmp_utf8mb4(CHARSET_INFO *cs, const char *s, const char *t) { MY_UNICASE_INFO *uni_plane= cs->caseinfo; while (s[0] && t[0]) { my_wc_t s_wc,t_wc; if ((uchar) s[0] < 128) { /* s[0] is between 0 and 127. It represents a single byte character. Convert it into weight according to collation. */ s_wc= my_unicase_default_page00[(uchar) s[0]].tolower; s++; } else { int res= my_mb_wc_utf8mb4_no_range(cs, &s_wc, (const uchar*) s); /* In the case of wrong multibyte sequence we will call strcmp() for byte-to-byte comparison. */ if (res <= 0) return strcmp(s, t); s+= res; my_tolower_utf8mb4(uni_plane, &s_wc); } /* Do the same for the second string */ if ((uchar) t[0] < 128) { /* Convert single byte character into weight */ t_wc= my_unicase_default_page00[(uchar) t[0]].tolower; t++; } else { int res= my_mb_wc_utf8mb4_no_range(cs, &t_wc, (const uchar*) t); if (res <= 0) return strcmp(s, t); t+= res; my_tolower_utf8mb4(uni_plane, &t_wc); } /* Now we have two weights, let's compare them */ if ( s_wc != t_wc ) return ((int) s_wc) - ((int) t_wc); } return ((int) (uchar) s[0]) - ((int) (uchar) t[0]); }
O3
c
my_strcasecmp_utf8mb4: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rdx, %rbx movb (%rsi), %al testb %al, %al je 0x744e5 movq %rsi, %r14 movq 0x78(%rdi), %r15 leaq 0x2f9370(%rip), %r12 # 0x36d780 cmpb $0x0, (%rbx) je 0x744df testb %al, %al js 0x74432 movzbl %al, %eax leaq (%rax,%rax,2), %rax movl 0x4(%r12,%rax,4), %r13d movq %r13, -0x30(%rbp) incq %r14 jmp 0x74479 leaq -0x30(%rbp), %rdi movq %r14, %rsi callq 0x73f9f testl %eax, %eax je 0x74505 movl %eax, %eax addq %rax, %r14 movq -0x30(%rbp), %r13 cmpq (%r15), %r13 ja 0x74479 movq 0x8(%r15), %rax movq %r13, %rcx shrq $0x8, %rcx movq (%rax,%rcx,8), %rax testq %rax, %rax je 0x74479 movzbl %r13b, %ecx leaq (%rcx,%rcx,2), %rcx movl 0x4(%rax,%rcx,4), %r13d movq %r13, -0x30(%rbp) movsbq (%rbx), %rax testq %rax, %rax js 0x74490 leaq (%rax,%rax,2), %rax movl 0x4(%r12,%rax,4), %eax incq %rbx jmp 0x744cd leaq -0x38(%rbp), %rdi movq %rbx, %rsi callq 0x73f9f testl %eax, %eax je 0x74505 movl %eax, %eax addq %rax, %rbx movq -0x38(%rbp), %rax cmpq (%r15), %rax ja 0x744cd movq 0x8(%r15), %rcx movq %rax, %rdx shrq $0x8, %rdx movq (%rcx,%rdx,8), %rcx testq %rcx, %rcx je 0x744cd movzbl %al, %eax leaq (%rax,%rax,2), %rax movl 0x4(%rcx,%rax,4), %eax cmpq %rax, %r13 jne 0x74500 movb (%r14), %al testb %al, %al jne 0x74410 xorl %eax, %eax movzbl %al, %r13d jmp 0x744e8 xorl %r13d, %r13d movzbl (%rbx), %eax subl %eax, %r13d movl %r13d, %eax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq subl %eax, %r13d jmp 0x744ee movq %r14, %rdi movq %rbx, %rsi callq 0x264a0 movl %eax, %r13d jmp 0x744ee
my_strcasecmp_utf8mb4: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov rbx, rdx mov al, [rsi] test al, al jz loc_744E5 mov r14, rsi mov r15, [rdi+78h] lea r12, my_unicase_default_page00 loc_74410: cmp byte ptr [rbx], 0 jz loc_744DF test al, al js short loc_74432 movzx eax, al lea rax, [rax+rax*2] mov r13d, [r12+rax*4+4] mov [rbp+var_30], r13 inc r14 jmp short loc_74479 loc_74432: lea rdi, [rbp+var_30] mov rsi, r14 call my_mb_wc_utf8mb4_no_range test eax, eax jz loc_74505 mov eax, eax add r14, rax mov r13, [rbp+var_30] cmp r13, [r15] ja short loc_74479 mov rax, [r15+8] mov rcx, r13 shr rcx, 8 mov rax, [rax+rcx*8] test rax, rax jz short loc_74479 movzx ecx, r13b lea rcx, [rcx+rcx*2] mov r13d, [rax+rcx*4+4] mov [rbp+var_30], r13 loc_74479: movsx rax, byte ptr [rbx] test rax, rax js short loc_74490 lea rax, [rax+rax*2] mov eax, [r12+rax*4+4] inc rbx jmp short loc_744CD loc_74490: lea rdi, [rbp+var_38] mov rsi, rbx call my_mb_wc_utf8mb4_no_range test eax, eax jz short loc_74505 mov eax, eax add rbx, rax mov rax, [rbp+var_38] cmp rax, [r15] ja short loc_744CD mov rcx, [r15+8] mov rdx, rax shr rdx, 8 mov rcx, [rcx+rdx*8] test rcx, rcx jz short loc_744CD movzx eax, al lea rax, [rax+rax*2] mov eax, [rcx+rax*4+4] loc_744CD: cmp r13, rax jnz short loc_74500 mov al, [r14] test al, al jnz loc_74410 xor eax, eax loc_744DF: movzx r13d, al jmp short loc_744E8 loc_744E5: xor r13d, r13d loc_744E8: movzx eax, byte ptr [rbx] sub r13d, eax loc_744EE: mov eax, r13d add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_74500: sub r13d, eax jmp short loc_744EE loc_74505: mov rdi, r14 mov rsi, rbx call _strcmp mov r13d, eax jmp short loc_744EE
long long my_strcasecmp_utf8mb4(long long a1, unsigned __int8 *a2, unsigned __int8 *a3) { unsigned __int8 v4; // al unsigned __int8 *v5; // r14 _QWORD *v6; // r15 unsigned long long v7; // r13 unsigned int v8; // eax long long v9; // rax long long v10; // rax unsigned long long v11; // rax unsigned int v12; // eax long long v13; // rcx int v14; // r13d unsigned long long v17; // [rsp+8h] [rbp-38h] BYREF unsigned long long v18[6]; // [rsp+10h] [rbp-30h] BYREF v4 = *a2; if ( *a2 ) { v5 = a2; v6 = *(_QWORD **)(a1 + 120); while ( 1 ) { if ( !*a3 ) goto LABEL_19; if ( (v4 & 0x80u) != 0 ) { v8 = my_mb_wc_utf8mb4_no_range(v18, v5); if ( !v8 ) return (unsigned int)strcmp(v5, a3); v5 += v8; v7 = v18[0]; if ( v18[0] <= *v6 ) { v9 = *(_QWORD *)(v6[1] + 8 * (v18[0] >> 8)); if ( v9 ) { v7 = *(unsigned int *)(v9 + 12LL * LOBYTE(v18[0]) + 4); v18[0] = v7; } } } else { v7 = (unsigned int)my_unicase_default_page00[3 * v4 + 1]; v18[0] = v7; ++v5; } v10 = (char)*a3; if ( v10 < 0 ) { v12 = my_mb_wc_utf8mb4_no_range(&v17, a3); if ( !v12 ) return (unsigned int)strcmp(v5, a3); a3 += v12; v11 = v17; if ( v17 <= *v6 ) { v13 = *(_QWORD *)(v6[1] + 8 * (v17 >> 8)); if ( v13 ) v11 = *(unsigned int *)(v13 + 12LL * (unsigned __int8)v17 + 4); } } else { v11 = (unsigned int)my_unicase_default_page00[3 * v10 + 1]; ++a3; } if ( v7 != v11 ) return (unsigned int)(v7 - v11); v4 = *v5; if ( !*v5 ) { v4 = 0; LABEL_19: v14 = v4; return (unsigned int)(v14 - *a3); } } } v14 = 0; return (unsigned int)(v14 - *a3); }
my_strcasecmp_utf8mb4: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV RBX,RDX MOV AL,byte ptr [RSI] TEST AL,AL JZ 0x001744e5 MOV R14,RSI MOV R15,qword ptr [RDI + 0x78] LEA R12,[0x46d780] LAB_00174410: CMP byte ptr [RBX],0x0 JZ 0x001744df TEST AL,AL JS 0x00174432 MOVZX EAX,AL LEA RAX,[RAX + RAX*0x2] MOV R13D,dword ptr [R12 + RAX*0x4 + 0x4] MOV qword ptr [RBP + -0x30],R13 INC R14 JMP 0x00174479 LAB_00174432: LEA RDI,[RBP + -0x30] MOV RSI,R14 CALL 0x00173f9f TEST EAX,EAX JZ 0x00174505 MOV EAX,EAX ADD R14,RAX MOV R13,qword ptr [RBP + -0x30] CMP R13,qword ptr [R15] JA 0x00174479 MOV RAX,qword ptr [R15 + 0x8] MOV RCX,R13 SHR RCX,0x8 MOV RAX,qword ptr [RAX + RCX*0x8] TEST RAX,RAX JZ 0x00174479 MOVZX ECX,R13B LEA RCX,[RCX + RCX*0x2] MOV R13D,dword ptr [RAX + RCX*0x4 + 0x4] MOV qword ptr [RBP + -0x30],R13 LAB_00174479: MOVSX RAX,byte ptr [RBX] TEST RAX,RAX JS 0x00174490 LEA RAX,[RAX + RAX*0x2] MOV EAX,dword ptr [R12 + RAX*0x4 + 0x4] INC RBX JMP 0x001744cd LAB_00174490: LEA RDI,[RBP + -0x38] MOV RSI,RBX CALL 0x00173f9f TEST EAX,EAX JZ 0x00174505 MOV EAX,EAX ADD RBX,RAX MOV RAX,qword ptr [RBP + -0x38] CMP RAX,qword ptr [R15] JA 0x001744cd MOV RCX,qword ptr [R15 + 0x8] MOV RDX,RAX SHR RDX,0x8 MOV RCX,qword ptr [RCX + RDX*0x8] TEST RCX,RCX JZ 0x001744cd MOVZX EAX,AL LEA RAX,[RAX + RAX*0x2] MOV EAX,dword ptr [RCX + RAX*0x4 + 0x4] LAB_001744cd: CMP R13,RAX JNZ 0x00174500 MOV AL,byte ptr [R14] TEST AL,AL JNZ 0x00174410 XOR EAX,EAX LAB_001744df: MOVZX R13D,AL JMP 0x001744e8 LAB_001744e5: XOR R13D,R13D LAB_001744e8: MOVZX EAX,byte ptr [RBX] SUB R13D,EAX LAB_001744ee: MOV EAX,R13D ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00174500: SUB R13D,EAX JMP 0x001744ee LAB_00174505: MOV RDI,R14 MOV RSI,RBX CALL 0x001264a0 MOV R13D,EAX JMP 0x001744ee
int my_strcasecmp_utf8mb4(long param_1,byte *param_2,byte *param_3) { ulong *puVar1; long lVar2; ulong uVar3; byte bVar4; uint uVar5; int iVar6; ulong uVar7; ulong local_40; ulong local_38; bVar4 = *param_2; if (bVar4 == 0) { uVar5 = 0; } else { puVar1 = *(ulong **)(param_1 + 0x78); do { if (*param_3 == 0) goto LAB_001744df; if ((char)bVar4 < '\0') { uVar5 = my_mb_wc_utf8mb4_no_range(&local_38,param_2); if (uVar5 == 0) goto LAB_00174505; param_2 = param_2 + uVar5; if ((local_38 <= *puVar1) && (lVar2 = *(long *)(puVar1[1] + (local_38 >> 8) * 8), lVar2 != 0)) { local_38 = (ulong)*(uint *)(lVar2 + 4 + (local_38 & 0xff) * 0xc); } } else { local_38 = (ulong)*(uint *)(my_unicase_default_page00 + (ulong)bVar4 * 0xc + 4); param_2 = param_2 + 1; } uVar3 = local_38; bVar4 = *param_3; if ((long)(char)bVar4 < 0) { uVar5 = my_mb_wc_utf8mb4_no_range(&local_40,param_3); if (uVar5 == 0) { LAB_00174505: iVar6 = strcmp((char *)param_2,(char *)param_3); return iVar6; } param_3 = param_3 + uVar5; uVar7 = local_40; if ((local_40 <= *puVar1) && (lVar2 = *(long *)(puVar1[1] + (local_40 >> 8) * 8), lVar2 != 0)) { uVar7 = (ulong)*(uint *)(lVar2 + 4 + (local_40 & 0xff) * 0xc); } } else { param_3 = param_3 + 1; uVar7 = (ulong)*(uint *)(my_unicase_default_page00 + (long)(char)bVar4 * 0xc + 4); } if (uVar3 != uVar7) { return (int)uVar3 - (int)uVar7; } bVar4 = *param_2; } while (bVar4 != 0); bVar4 = 0; LAB_001744df: uVar5 = (uint)bVar4; } return uVar5 - *param_3; }
56,893
string_parse_kv_override(char const*, std::vector<llama_model_kv_override, std::allocator<llama_model_kv_override>>&)
monkey531[P]llama/common/common.cpp
bool string_parse_kv_override(const char * data, std::vector<llama_model_kv_override> & overrides) { const char * sep = strchr(data, '='); if (sep == nullptr || sep - data >= 128) { LOG_ERR("%s: malformed KV override '%s'\n", __func__, data); return false; } llama_model_kv_override kvo; std::strncpy(kvo.key, data, sep - data); kvo.key[sep - data] = 0; sep++; if (strncmp(sep, "int:", 4) == 0) { sep += 4; kvo.tag = LLAMA_KV_OVERRIDE_TYPE_INT; kvo.val_i64 = std::atol(sep); } else if (strncmp(sep, "float:", 6) == 0) { sep += 6; kvo.tag = LLAMA_KV_OVERRIDE_TYPE_FLOAT; kvo.val_f64 = std::atof(sep); } else if (strncmp(sep, "bool:", 5) == 0) { sep += 5; kvo.tag = LLAMA_KV_OVERRIDE_TYPE_BOOL; if (std::strcmp(sep, "true") == 0) { kvo.val_bool = true; } else if (std::strcmp(sep, "false") == 0) { kvo.val_bool = false; } else { LOG_ERR("%s: invalid boolean value for KV override '%s'\n", __func__, data); return false; } } else if (strncmp(sep, "str:", 4) == 0) { sep += 4; kvo.tag = LLAMA_KV_OVERRIDE_TYPE_STR; if (strlen(sep) > 127) { LOG_ERR("%s: malformed KV override '%s', value cannot exceed 127 chars\n", __func__, data); return false; } strncpy(kvo.val_str, sep, 127); kvo.val_str[127] = '\0'; } else { LOG_ERR("%s: invalid type for KV override '%s'\n", __func__, data); return false; } overrides.emplace_back(std::move(kvo)); return true; }
O0
cpp
string_parse_kv_override(char const*, std::vector<llama_model_kv_override, std::allocator<llama_model_kv_override>>&): subq $0x128, %rsp # imm = 0x128 movq %rdi, 0x118(%rsp) movq %rsi, 0x110(%rsp) movq 0x118(%rsp), %rdi movl $0x3d, %esi callq 0x5a980 movq %rax, 0x108(%rsp) cmpq $0x0, 0x108(%rsp) je 0xee1d7 movq 0x108(%rsp), %rax movq 0x118(%rsp), %rcx subq %rcx, %rax cmpq $0x80, %rax jl 0xee21f jmp 0xee1d9 xorl %eax, %eax leaq 0x1b8436(%rip), %rcx # 0x2a6618 cmpl (%rcx), %eax jg 0xee210 callq 0x1be7b0 movq %rax, %rdi movq 0x118(%rsp), %r8 movl $0x4, %esi leaq 0x1244b8(%rip), %rdx # 0x2126ba leaq 0x1244d1(%rip), %rcx # 0x2126da movb $0x0, %al callq 0x1be8a0 jmp 0xee212 movb $0x0, 0x127(%rsp) jmp 0xee50c movq %rsp, %rdi addq $0x4, %rdi movq 0x118(%rsp), %rsi movq 0x108(%rsp), %rdx movq 0x118(%rsp), %rax subq %rax, %rdx callq 0x5a260 movq 0x108(%rsp), %rax movq 0x118(%rsp), %rcx subq %rcx, %rax movb $0x0, 0x4(%rsp,%rax) movq 0x108(%rsp), %rax addq $0x1, %rax movq %rax, 0x108(%rsp) movq 0x108(%rsp), %rdi leaq 0x124472(%rip), %rsi # 0x2126f3 movl $0x4, %edx callq 0x5a3e0 cmpl $0x0, %eax jne 0xee2c5 movq 0x108(%rsp), %rax addq $0x4, %rax movq %rax, 0x108(%rsp) movl $0x0, (%rsp) movq 0x108(%rsp), %rdi callq 0x5aa80 movq %rax, 0x88(%rsp) jmp 0xee4f4 movq 0x108(%rsp), %rdi leaq 0x124424(%rip), %rsi # 0x2126f8 movl $0x6, %edx callq 0x5a3e0 cmpl $0x0, %eax jne 0xee319 movq 0x108(%rsp), %rax addq $0x6, %rax movq %rax, 0x108(%rsp) movl $0x1, (%rsp) movq 0x108(%rsp), %rdi callq 0x5aea0 movsd %xmm0, 0x88(%rsp) jmp 0xee4f2 movq 0x108(%rsp), %rdi leaq 0x1243d7(%rip), %rsi # 0x2126ff movl $0x5, %edx callq 0x5a3e0 cmpl $0x0, %eax jne 0xee3eb movq 0x108(%rsp), %rax addq $0x5, %rax movq %rax, 0x108(%rsp) movl $0x2, (%rsp) movq 0x108(%rsp), %rdi leaq 0x11bd89(%rip), %rsi # 0x20a0ee callq 0x5aeb0 cmpl $0x0, %eax jne 0xee379 movb $0x1, 0x88(%rsp) jmp 0xee3e6 movq 0x108(%rsp), %rdi leaq 0x11ea4f(%rip), %rsi # 0x20cdd7 callq 0x5aeb0 cmpl $0x0, %eax jne 0xee39c movb $0x0, 0x88(%rsp) jmp 0xee3e4 jmp 0xee39e xorl %eax, %eax leaq 0x1b8271(%rip), %rcx # 0x2a6618 cmpl (%rcx), %eax jg 0xee3d5 callq 0x1be7b0 movq %rax, %rdi movq 0x118(%rsp), %r8 movl $0x4, %esi leaq 0x12433e(%rip), %rdx # 0x212705 leaq 0x12430c(%rip), %rcx # 0x2126da movb $0x0, %al callq 0x1be8a0 jmp 0xee3d7 movb $0x0, 0x127(%rsp) jmp 0xee50c jmp 0xee3e6 jmp 0xee4f0 movq 0x108(%rsp), %rdi leaq 0x12433b(%rip), %rsi # 0x212735 movl $0x4, %edx callq 0x5a3e0 cmpl $0x0, %eax jne 0xee4a9 movq 0x108(%rsp), %rax addq $0x4, %rax movq %rax, 0x108(%rsp) movl $0x3, (%rsp) movq 0x108(%rsp), %rdi callq 0x5a6a0 cmpq $0x7f, %rax jbe 0xee483 jmp 0xee43d xorl %eax, %eax leaq 0x1b81d2(%rip), %rcx # 0x2a6618 cmpl (%rcx), %eax jg 0xee474 callq 0x1be7b0 movq %rax, %rdi movq 0x118(%rsp), %r8 movl $0x4, %esi leaq 0x1242d4(%rip), %rdx # 0x21273a leaq 0x12426d(%rip), %rcx # 0x2126da movb $0x0, %al callq 0x1be8a0 jmp 0xee476 movb $0x0, 0x127(%rsp) jmp 0xee50c movq %rsp, %rdi addq $0x88, %rdi movq 0x108(%rsp), %rsi movl $0x7f, %edx callq 0x5a260 movb $0x0, 0x107(%rsp) jmp 0xee4ee jmp 0xee4ab xorl %eax, %eax leaq 0x1b8164(%rip), %rcx # 0x2a6618 cmpl (%rcx), %eax jg 0xee4e2 callq 0x1be7b0 movq %rax, %rdi movq 0x118(%rsp), %r8 movl $0x4, %esi leaq 0x1242a5(%rip), %rdx # 0x212779 leaq 0x1241ff(%rip), %rcx # 0x2126da movb $0x0, %al callq 0x1be8a0 jmp 0xee4e4 movb $0x0, 0x127(%rsp) jmp 0xee50c jmp 0xee4f0 jmp 0xee4f2 jmp 0xee4f4 movq 0x110(%rsp), %rdi movq %rsp, %rsi callq 0xf7eb0 movb $0x1, 0x127(%rsp) movb 0x127(%rsp), %al andb $0x1, %al addq $0x128, %rsp # imm = 0x128 retq nopl (%rax)
_Z24string_parse_kv_overridePKcRSt6vectorI23llama_model_kv_overrideSaIS2_EE: sub rsp, 128h mov [rsp+128h+var_10], rdi mov [rsp+128h+var_18], rsi mov rdi, [rsp+128h+var_10] mov esi, 3Dh ; '=' call _strchr mov [rsp+128h+var_20], rax cmp [rsp+128h+var_20], 0 jz short loc_EE1D7 mov rax, [rsp+128h+var_20] mov rcx, [rsp+128h+var_10] sub rax, rcx cmp rax, 80h jl short loc_EE21F loc_EE1D7: jmp short $+2 loc_EE1D9: xor eax, eax lea rcx, common_log_verbosity_thold cmp eax, [rcx] jg short loc_EE210 call _Z15common_log_mainv; common_log_main(void) mov rdi, rax mov r8, [rsp+128h+var_10] mov esi, 4 lea rdx, aSMalformedKvOv; "%s: malformed KV override '%s'\n" lea rcx, aStringParseKvO; "string_parse_kv_override" mov al, 0 call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...) loc_EE210: jmp short $+2 loc_EE212: mov [rsp+128h+var_1], 0 jmp loc_EE50C loc_EE21F: mov rdi, rsp add rdi, 4 mov rsi, [rsp+128h+var_10] mov rdx, [rsp+128h+var_20] mov rax, [rsp+128h+var_10] sub rdx, rax call _strncpy mov rax, [rsp+128h+var_20] mov rcx, [rsp+128h+var_10] sub rax, rcx mov [rsp+rax+128h+var_124], 0 mov rax, [rsp+128h+var_20] add rax, 1 mov [rsp+128h+var_20], rax mov rdi, [rsp+128h+var_20] lea rsi, aInt; "int:" mov edx, 4 call _strncmp cmp eax, 0 jnz short loc_EE2C5 mov rax, [rsp+128h+var_20] add rax, 4 mov [rsp+128h+var_20], rax mov [rsp+128h+var_128], 0 mov rdi, [rsp+128h+var_20] call _atol mov [rsp+128h+var_A0], rax jmp loc_EE4F4 loc_EE2C5: mov rdi, [rsp+128h+var_20] lea rsi, aFloat; "float:" mov edx, 6 call _strncmp cmp eax, 0 jnz short loc_EE319 mov rax, [rsp+128h+var_20] add rax, 6 mov [rsp+128h+var_20], rax mov [rsp+128h+var_128], 1 mov rdi, [rsp+128h+var_20] call _atof movsd [rsp+128h+var_A0], xmm0 jmp loc_EE4F2 loc_EE319: mov rdi, [rsp+128h+var_20] lea rsi, aBool; "bool:" mov edx, 5 call _strncmp cmp eax, 0 jnz loc_EE3EB mov rax, [rsp+128h+var_20] add rax, 5 mov [rsp+128h+var_20], rax mov [rsp+128h+var_128], 2 mov rdi, [rsp+128h+var_20] lea rsi, aTrue; "true" call _strcmp cmp eax, 0 jnz short loc_EE379 mov byte ptr [rsp+128h+var_A0], 1 jmp short loc_EE3E6 loc_EE379: mov rdi, [rsp+128h+var_20] lea rsi, aAdvancedOption+0ABh; "false" call _strcmp cmp eax, 0 jnz short loc_EE39C mov byte ptr [rsp+128h+var_A0], 0 jmp short loc_EE3E4 loc_EE39C: jmp short $+2 loc_EE39E: xor eax, eax lea rcx, common_log_verbosity_thold cmp eax, [rcx] jg short loc_EE3D5 call _Z15common_log_mainv; common_log_main(void) mov rdi, rax mov r8, [rsp+128h+var_10] mov esi, 4 lea rdx, aSInvalidBoolea; "%s: invalid boolean value for KV overri"... lea rcx, aStringParseKvO; "string_parse_kv_override" mov al, 0 call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...) loc_EE3D5: jmp short $+2 loc_EE3D7: mov [rsp+128h+var_1], 0 jmp loc_EE50C loc_EE3E4: jmp short $+2 loc_EE3E6: jmp loc_EE4F0 loc_EE3EB: mov rdi, [rsp+128h+var_20] lea rsi, aStr; "str:" mov edx, 4 call _strncmp cmp eax, 0 jnz loc_EE4A9 mov rax, [rsp+128h+var_20] add rax, 4 mov [rsp+128h+var_20], rax mov [rsp+128h+var_128], 3 mov rdi, [rsp+128h+var_20] call _strlen cmp rax, 7Fh jbe short loc_EE483 jmp short $+2 loc_EE43D: xor eax, eax lea rcx, common_log_verbosity_thold cmp eax, [rcx] jg short loc_EE474 call _Z15common_log_mainv; common_log_main(void) mov rdi, rax mov r8, [rsp+128h+var_10] mov esi, 4 lea rdx, aSMalformedKvOv_0; "%s: malformed KV override '%s', value c"... lea rcx, aStringParseKvO; "string_parse_kv_override" mov al, 0 call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...) loc_EE474: jmp short $+2 loc_EE476: mov [rsp+128h+var_1], 0 jmp loc_EE50C loc_EE483: mov rdi, rsp add rdi, 88h mov rsi, [rsp+128h+var_20] mov edx, 7Fh call _strncpy mov [rsp+128h+var_21], 0 jmp short loc_EE4EE loc_EE4A9: jmp short $+2 loc_EE4AB: xor eax, eax lea rcx, common_log_verbosity_thold cmp eax, [rcx] jg short loc_EE4E2 call _Z15common_log_mainv; common_log_main(void) mov rdi, rax mov r8, [rsp+128h+var_10] mov esi, 4 lea rdx, aSInvalidTypeFo; "%s: invalid type for KV override '%s'\n" lea rcx, aStringParseKvO; "string_parse_kv_override" mov al, 0 call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...) loc_EE4E2: jmp short $+2 loc_EE4E4: mov [rsp+128h+var_1], 0 jmp short loc_EE50C loc_EE4EE: jmp short $+2 loc_EE4F0: jmp short $+2 loc_EE4F2: jmp short $+2 loc_EE4F4: mov rdi, [rsp+128h+var_18] mov rsi, rsp call _ZNSt6vectorI23llama_model_kv_overrideSaIS0_EE12emplace_backIJS0_EEERS0_DpOT_; std::vector<llama_model_kv_override>::emplace_back<llama_model_kv_override>(llama_model_kv_override &&) mov [rsp+128h+var_1], 1 loc_EE50C: mov al, [rsp+128h+var_1] and al, 1 add rsp, 128h retn
char string_parse_kv_override(long long a1, long long a2) { int v2; // eax int v3; // r9d int v4; // eax int v5; // r9d int v6; // eax int v7; // r9d int v8; // eax int v9; // r9d int v11; // [rsp+0h] [rbp-128h] BYREF _BYTE v12[132]; // [rsp+4h] [rbp-124h] BYREF long long v13[15]; // [rsp+88h] [rbp-A0h] BYREF char v14; // [rsp+107h] [rbp-21h] long long v15; // [rsp+108h] [rbp-20h] long long v16; // [rsp+110h] [rbp-18h] long long v17; // [rsp+118h] [rbp-10h] v17 = a1; v16 = a2; v15 = strchr(a1, 61LL); if ( !v15 || v15 - v17 >= 128 ) { if ( common_log_verbosity_thold >= 0 ) { v2 = common_log_main(); common_log_add( v2, 4, (unsigned int)"%s: malformed KV override '%s'\n", (unsigned int)"string_parse_kv_override", v17, v3); } return 0; } strncpy(v12, v17, v15 - v17); v12[v15 - v17] = 0; if ( !(unsigned int)strncmp(++v15, "int:", 4LL) ) { v15 += 4LL; v11 = 0; v13[0] = atol(v15); LABEL_27: std::vector<llama_model_kv_override>::emplace_back<llama_model_kv_override>(v16, &v11); return 1; } if ( !(unsigned int)strncmp(v15, "float:", 6LL) ) { v15 += 6LL; v11 = 1; v13[0] = atof(v15); goto LABEL_27; } if ( !(unsigned int)strncmp(v15, "bool:", 5LL) ) { v15 += 5LL; v11 = 2; if ( !(unsigned int)strcmp(v15, "true") ) { LOBYTE(v13[0]) = 1; goto LABEL_27; } if ( !(unsigned int)strcmp(v15, "false") ) { LOBYTE(v13[0]) = 0; goto LABEL_27; } if ( common_log_verbosity_thold >= 0 ) { v4 = common_log_main(); common_log_add( v4, 4, (unsigned int)"%s: invalid boolean value for KV override '%s'\n", (unsigned int)"string_parse_kv_override", v17, v5); } return 0; } else if ( !(unsigned int)strncmp(v15, "str:", 4LL) ) { v15 += 4LL; v11 = 3; if ( (unsigned long long)strlen(v15) <= 0x7F ) { strncpy(v13, v15, 127LL); v14 = 0; goto LABEL_27; } if ( common_log_verbosity_thold >= 0 ) { v6 = common_log_main(); common_log_add( v6, 4, (unsigned int)"%s: malformed KV override '%s', value cannot exceed 127 chars\n", (unsigned int)"string_parse_kv_override", v17, v7); } return 0; } else { if ( common_log_verbosity_thold >= 0 ) { v8 = common_log_main(); common_log_add( v8, 4, (unsigned int)"%s: invalid type for KV override '%s'\n", (unsigned int)"string_parse_kv_override", v17, v9); } return 0; } }
string_parse_kv_override: SUB RSP,0x128 MOV qword ptr [RSP + 0x118],RDI MOV qword ptr [RSP + 0x110],RSI MOV RDI,qword ptr [RSP + 0x118] MOV ESI,0x3d CALL 0x0015a980 MOV qword ptr [RSP + 0x108],RAX CMP qword ptr [RSP + 0x108],0x0 JZ 0x001ee1d7 MOV RAX,qword ptr [RSP + 0x108] MOV RCX,qword ptr [RSP + 0x118] SUB RAX,RCX CMP RAX,0x80 JL 0x001ee21f LAB_001ee1d7: JMP 0x001ee1d9 LAB_001ee1d9: XOR EAX,EAX LEA RCX,[0x3a6618] CMP EAX,dword ptr [RCX] JG 0x001ee210 CALL 0x002be7b0 MOV RDI,RAX MOV R8,qword ptr [RSP + 0x118] MOV ESI,0x4 LEA RDX,[0x3126ba] LEA RCX,[0x3126da] MOV AL,0x0 CALL 0x002be8a0 LAB_001ee210: JMP 0x001ee212 LAB_001ee212: MOV byte ptr [RSP + 0x127],0x0 JMP 0x001ee50c LAB_001ee21f: MOV RDI,RSP ADD RDI,0x4 MOV RSI,qword ptr [RSP + 0x118] MOV RDX,qword ptr [RSP + 0x108] MOV RAX,qword ptr [RSP + 0x118] SUB RDX,RAX CALL 0x0015a260 MOV RAX,qword ptr [RSP + 0x108] MOV RCX,qword ptr [RSP + 0x118] SUB RAX,RCX MOV byte ptr [RSP + RAX*0x1 + 0x4],0x0 MOV RAX,qword ptr [RSP + 0x108] ADD RAX,0x1 MOV qword ptr [RSP + 0x108],RAX MOV RDI,qword ptr [RSP + 0x108] LEA RSI,[0x3126f3] MOV EDX,0x4 CALL 0x0015a3e0 CMP EAX,0x0 JNZ 0x001ee2c5 MOV RAX,qword ptr [RSP + 0x108] ADD RAX,0x4 MOV qword ptr [RSP + 0x108],RAX MOV dword ptr [RSP],0x0 MOV RDI,qword ptr [RSP + 0x108] CALL 0x0015aa80 MOV qword ptr [RSP + 0x88],RAX JMP 0x001ee4f4 LAB_001ee2c5: MOV RDI,qword ptr [RSP + 0x108] LEA RSI,[0x3126f8] MOV EDX,0x6 CALL 0x0015a3e0 CMP EAX,0x0 JNZ 0x001ee319 MOV RAX,qword ptr [RSP + 0x108] ADD RAX,0x6 MOV qword ptr [RSP + 0x108],RAX MOV dword ptr [RSP],0x1 MOV RDI,qword ptr [RSP + 0x108] CALL 0x0015aea0 MOVSD qword ptr [RSP + 0x88],XMM0 JMP 0x001ee4f2 LAB_001ee319: MOV RDI,qword ptr [RSP + 0x108] LEA RSI,[0x3126ff] MOV EDX,0x5 CALL 0x0015a3e0 CMP EAX,0x0 JNZ 0x001ee3eb MOV RAX,qword ptr [RSP + 0x108] ADD RAX,0x5 MOV qword ptr [RSP + 0x108],RAX MOV dword ptr [RSP],0x2 MOV RDI,qword ptr [RSP + 0x108] LEA RSI,[0x30a0ee] CALL 0x0015aeb0 CMP EAX,0x0 JNZ 0x001ee379 MOV byte ptr [RSP + 0x88],0x1 JMP 0x001ee3e6 LAB_001ee379: MOV RDI,qword ptr [RSP + 0x108] LEA RSI,[0x30cdd7] CALL 0x0015aeb0 CMP EAX,0x0 JNZ 0x001ee39c MOV byte ptr [RSP + 0x88],0x0 JMP 0x001ee3e4 LAB_001ee39c: JMP 0x001ee39e LAB_001ee39e: XOR EAX,EAX LEA RCX,[0x3a6618] CMP EAX,dword ptr [RCX] JG 0x001ee3d5 CALL 0x002be7b0 MOV RDI,RAX MOV R8,qword ptr [RSP + 0x118] MOV ESI,0x4 LEA RDX,[0x312705] LEA RCX,[0x3126da] MOV AL,0x0 CALL 0x002be8a0 LAB_001ee3d5: JMP 0x001ee3d7 LAB_001ee3d7: MOV byte ptr [RSP + 0x127],0x0 JMP 0x001ee50c LAB_001ee3e4: JMP 0x001ee3e6 LAB_001ee3e6: JMP 0x001ee4f0 LAB_001ee3eb: MOV RDI,qword ptr [RSP + 0x108] LEA RSI,[0x312735] MOV EDX,0x4 CALL 0x0015a3e0 CMP EAX,0x0 JNZ 0x001ee4a9 MOV RAX,qword ptr [RSP + 0x108] ADD RAX,0x4 MOV qword ptr [RSP + 0x108],RAX MOV dword ptr [RSP],0x3 MOV RDI,qword ptr [RSP + 0x108] CALL 0x0015a6a0 CMP RAX,0x7f JBE 0x001ee483 JMP 0x001ee43d LAB_001ee43d: XOR EAX,EAX LEA RCX,[0x3a6618] CMP EAX,dword ptr [RCX] JG 0x001ee474 CALL 0x002be7b0 MOV RDI,RAX MOV R8,qword ptr [RSP + 0x118] MOV ESI,0x4 LEA RDX,[0x31273a] LEA RCX,[0x3126da] MOV AL,0x0 CALL 0x002be8a0 LAB_001ee474: JMP 0x001ee476 LAB_001ee476: MOV byte ptr [RSP + 0x127],0x0 JMP 0x001ee50c LAB_001ee483: MOV RDI,RSP ADD RDI,0x88 MOV RSI,qword ptr [RSP + 0x108] MOV EDX,0x7f CALL 0x0015a260 MOV byte ptr [RSP + 0x107],0x0 JMP 0x001ee4ee LAB_001ee4a9: JMP 0x001ee4ab LAB_001ee4ab: XOR EAX,EAX LEA RCX,[0x3a6618] CMP EAX,dword ptr [RCX] JG 0x001ee4e2 CALL 0x002be7b0 MOV RDI,RAX MOV R8,qword ptr [RSP + 0x118] MOV ESI,0x4 LEA RDX,[0x312779] LEA RCX,[0x3126da] MOV AL,0x0 CALL 0x002be8a0 LAB_001ee4e2: JMP 0x001ee4e4 LAB_001ee4e4: MOV byte ptr [RSP + 0x127],0x0 JMP 0x001ee50c LAB_001ee4ee: JMP 0x001ee4f0 LAB_001ee4f0: JMP 0x001ee4f2 LAB_001ee4f2: JMP 0x001ee4f4 LAB_001ee4f4: MOV RDI,qword ptr [RSP + 0x110] MOV RSI,RSP CALL 0x001f7eb0 MOV byte ptr [RSP + 0x127],0x1 LAB_001ee50c: MOV AL,byte ptr [RSP + 0x127] AND AL,0x1 ADD RSP,0x128 RET
/* string_parse_kv_override(char const*, std::vector<llama_model_kv_override, std::allocator<llama_model_kv_override> >&) */ int1 string_parse_kv_override(char *param_1,vector *param_2) { int iVar1; int8 uVar2; size_t sVar3; int4 local_128; char acStack_124 [132]; double local_a0 [15]; int1 local_21; char *local_20; vector *local_18; char *local_10; local_18 = param_2; local_10 = param_1; local_20 = strchr(param_1,0x3d); if ((local_20 == (char *)0x0) || (0x7f < (long)local_20 - (long)local_10)) { if (-1 < common_log_verbosity_thold) { uVar2 = common_log_main(); common_log_add(uVar2,4,"%s: malformed KV override \'%s\'\n","string_parse_kv_override", local_10); } return 0; } strncpy(acStack_124,local_10,(long)local_20 - (long)local_10); local_20[(long)(acStack_124 + -(long)local_10)] = '\0'; local_20 = local_20 + 1; iVar1 = strncmp(local_20,"int:",4); if (iVar1 == 0) { local_20 = local_20 + 4; local_128 = 0; local_a0[0] = (double)atol(local_20); } else { iVar1 = strncmp(local_20,"float:",6); if (iVar1 == 0) { local_20 = local_20 + 6; local_128 = 1; local_a0[0] = atof(local_20); } else { iVar1 = strncmp(local_20,"bool:",5); if (iVar1 == 0) { local_20 = local_20 + 5; local_128 = 2; iVar1 = strcmp(local_20,"true"); if (iVar1 == 0) { local_a0[0] = (double)CONCAT71(local_a0[0]._1_7_,1); } else { iVar1 = strcmp(local_20,"false"); if (iVar1 != 0) { if (-1 < common_log_verbosity_thold) { uVar2 = common_log_main(); common_log_add(uVar2,4,"%s: invalid boolean value for KV override \'%s\'\n", "string_parse_kv_override",local_10); } return 0; } local_a0[0] = (double)((ulong)local_a0[0] & 0xffffffffffffff00); } } else { iVar1 = strncmp(local_20,"str:",4); if (iVar1 != 0) { if (-1 < common_log_verbosity_thold) { uVar2 = common_log_main(); common_log_add(uVar2,4,"%s: invalid type for KV override \'%s\'\n", "string_parse_kv_override",local_10); } return 0; } local_20 = local_20 + 4; local_128 = 3; sVar3 = strlen(local_20); if (0x7f < sVar3) { if (-1 < common_log_verbosity_thold) { uVar2 = common_log_main(); common_log_add(uVar2,4, "%s: malformed KV override \'%s\', value cannot exceed 127 chars\n", "string_parse_kv_override",local_10); } return 0; } strncpy((char *)local_a0,local_20,0x7f); local_21 = 0; } } } std::vector<llama_model_kv_override,std::allocator<llama_model_kv_override>>:: emplace_back<llama_model_kv_override> ((vector<llama_model_kv_override,std::allocator<llama_model_kv_override>> *)local_18, (llama_model_kv_override *)&local_128); return 1; }
56,894
string_parse_kv_override(char const*, std::vector<llama_model_kv_override, std::allocator<llama_model_kv_override>>&)
monkey531[P]llama/common/common.cpp
bool string_parse_kv_override(const char * data, std::vector<llama_model_kv_override> & overrides) { const char * sep = strchr(data, '='); if (sep == nullptr || sep - data >= 128) { LOG_ERR("%s: malformed KV override '%s'\n", __func__, data); return false; } llama_model_kv_override kvo; std::strncpy(kvo.key, data, sep - data); kvo.key[sep - data] = 0; sep++; if (strncmp(sep, "int:", 4) == 0) { sep += 4; kvo.tag = LLAMA_KV_OVERRIDE_TYPE_INT; kvo.val_i64 = std::atol(sep); } else if (strncmp(sep, "float:", 6) == 0) { sep += 6; kvo.tag = LLAMA_KV_OVERRIDE_TYPE_FLOAT; kvo.val_f64 = std::atof(sep); } else if (strncmp(sep, "bool:", 5) == 0) { sep += 5; kvo.tag = LLAMA_KV_OVERRIDE_TYPE_BOOL; if (std::strcmp(sep, "true") == 0) { kvo.val_bool = true; } else if (std::strcmp(sep, "false") == 0) { kvo.val_bool = false; } else { LOG_ERR("%s: invalid boolean value for KV override '%s'\n", __func__, data); return false; } } else if (strncmp(sep, "str:", 4) == 0) { sep += 4; kvo.tag = LLAMA_KV_OVERRIDE_TYPE_STR; if (strlen(sep) > 127) { LOG_ERR("%s: malformed KV override '%s', value cannot exceed 127 chars\n", __func__, data); return false; } strncpy(kvo.val_str, sep, 127); kvo.val_str[127] = '\0'; } else { LOG_ERR("%s: invalid type for KV override '%s'\n", __func__, data); return false; } overrides.emplace_back(std::move(kvo)); return true; }
O3
cpp
string_parse_kv_override(char const*, std::vector<llama_model_kv_override, std::allocator<llama_model_kv_override>>&): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x110, %rsp # imm = 0x110 movq %rsi, %r14 movq %rdi, %rbx movl $0x3d, %esi callq 0x1a320 testq %rax, %rax je 0x73134 movq %rax, %r15 movq %rax, %r12 subq %rbx, %r12 cmpq $0x80, %r12 jl 0x73170 leaq 0xba2fd(%rip), %rax # 0x12d438 cmpl $0x0, (%rax) js 0x7331c callq 0xcb8a7 leaq 0x7bb86(%rip), %rdx # 0xeecd6 leaq 0x7bb9f(%rip), %rcx # 0xeecf6 xorl %ebp, %ebp movq %rax, %rdi movl $0x4, %esi movq %rbx, %r8 xorl %eax, %eax callq 0xcb944 jmp 0x7331e leaq 0xc(%rsp), %rdi movq %rbx, %rsi movq %r12, %rdx callq 0x1a490 movb $0x0, 0xc(%rsp,%r12) leaq 0x1(%r15), %r12 leaq 0x7bb7e(%rip), %rsi # 0xeed0f movl $0x4, %edx movq %r12, %rdi callq 0x1a450 testl %eax, %eax je 0x73213 leaq 0x7bb6b(%rip), %rsi # 0xeed14 movl $0x6, %edx movq %r12, %rdi callq 0x1a450 testl %eax, %eax je 0x73231 leaq 0x7bb5a(%rip), %rsi # 0xeed1b movl $0x5, %edx movq %r12, %rdi callq 0x1a450 testl %eax, %eax je 0x7328c leaq 0x7bb74(%rip), %rsi # 0xeed51 movl $0x4, %edx movq %r12, %rdi callq 0x1a450 testl %eax, %eax je 0x732e3 leaq 0xba23f(%rip), %rax # 0x12d438 cmpl $0x0, (%rax) js 0x7331c callq 0xcb8a7 leaq 0x7bb87(%rip), %rdx # 0xeed95 jmp 0x73150 addq $0x5, %r15 movl $0x0, 0x8(%rsp) movq %r15, %rdi callq 0x1aa70 movq %rax, 0x90(%rsp) jmp 0x7324e addq $0x7, %r15 movl $0x1, 0x8(%rsp) movq %r15, %rdi callq 0x1aad0 movsd %xmm0, 0x90(%rsp) movq 0x8(%r14), %rax cmpq 0x10(%r14), %rax je 0x73274 leaq 0x8(%rsp), %rsi movl $0x108, %edx # imm = 0x108 movq %rax, %rdi callq 0x1a750 addq $0x108, 0x8(%r14) # imm = 0x108 jmp 0x73284 leaq 0x8(%rsp), %rdx movq %r14, %rdi movq %rax, %rsi callq 0xb8b4a movb $0x1, %bpl jmp 0x7331e addq $0x6, %r15 movl $0x2, 0x8(%rsp) leaq 0x7393b(%rip), %rsi # 0xe6bda movq %r15, %rdi callq 0x1ac50 testl %eax, %eax je 0x73330 leaq 0x7660d(%rip), %rsi # 0xe98c3 movq %r15, %rdi callq 0x1ac50 testl %eax, %eax je 0x7335e leaq 0xba16b(%rip), %rax # 0x12d438 cmpl $0x0, (%rax) js 0x7331c callq 0xcb8a7 leaq 0x7ba43(%rip), %rdx # 0xeed21 jmp 0x73150 addq $0x5, %r15 movl $0x3, 0x8(%rsp) movq %r15, %rdi callq 0x1a400 cmpq $0x80, %rax jb 0x7333d leaq 0xba132(%rip), %rax # 0x12d438 cmpl $0x0, (%rax) js 0x7331c callq 0xcb8a7 leaq 0x7ba3f(%rip), %rdx # 0xeed56 jmp 0x73150 xorl %ebp, %ebp movl %ebp, %eax addq $0x110, %rsp # imm = 0x110 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movb $0x1, 0x90(%rsp) jmp 0x7324e leaq 0x90(%rsp), %rbx movl $0x7f, %edx movq %rbx, %rdi movq %r15, %rsi callq 0x1a490 movb $0x0, 0x7f(%rbx) jmp 0x7324e movb $0x0, 0x90(%rsp) jmp 0x7324e
_Z24string_parse_kv_overridePKcRSt6vectorI23llama_model_kv_overrideSaIS2_EE: push rbp push r15 push r14 push r12 push rbx sub rsp, 110h mov r14, rsi mov rbx, rdi mov esi, 3Dh ; '=' call _strchr test rax, rax jz short loc_73134 mov r15, rax mov r12, rax sub r12, rbx cmp r12, 80h jl short loc_73170 loc_73134: lea rax, common_log_verbosity_thold cmp dword ptr [rax], 0 js loc_7331C call _Z15common_log_mainv; common_log_main(void) lea rdx, aSMalformedKvOv; "%s: malformed KV override '%s'\n" loc_73150: lea rcx, aStringParseKvO; "string_parse_kv_override" xor ebp, ebp mov rdi, rax mov esi, 4 mov r8, rbx xor eax, eax call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...) jmp loc_7331E loc_73170: lea rdi, [rsp+138h+var_12C] mov rsi, rbx mov rdx, r12 call _strncpy mov [rsp+r12+138h+var_12C], 0 lea r12, [r15+1] lea rsi, aInt; "int:" mov edx, 4 mov rdi, r12 call _strncmp test eax, eax jz short loc_73213 lea rsi, aFloat; "float:" mov edx, 6 mov rdi, r12 call _strncmp test eax, eax jz short loc_73231 lea rsi, aBool; "bool:" mov edx, 5 mov rdi, r12 call _strncmp test eax, eax jz loc_7328C lea rsi, aStr; "str:" mov edx, 4 mov rdi, r12 call _strncmp test eax, eax jz loc_732E3 lea rax, common_log_verbosity_thold cmp dword ptr [rax], 0 js loc_7331C call _Z15common_log_mainv; common_log_main(void) lea rdx, aSInvalidTypeFo; "%s: invalid type for KV override '%s'\n" jmp loc_73150 loc_73213: add r15, 5 mov [rsp+138h+var_130], 0 mov rdi, r15 call _atol mov [rsp+138h+var_A8], rax jmp short loc_7324E loc_73231: add r15, 7 mov [rsp+138h+var_130], 1 mov rdi, r15 call _atof movsd [rsp+138h+var_A8], xmm0 loc_7324E: mov rax, [r14+8] cmp rax, [r14+10h] jz short loc_73274 lea rsi, [rsp+138h+var_130] mov edx, 108h mov rdi, rax call _memcpy add qword ptr [r14+8], 108h jmp short loc_73284 loc_73274: lea rdx, [rsp+138h+var_130] mov rdi, r14 mov rsi, rax call _ZNSt6vectorI23llama_model_kv_overrideSaIS0_EE17_M_realloc_insertIJS0_EEEvN9__gnu_cxx17__normal_iteratorIPS0_S2_EEDpOT_; std::vector<llama_model_kv_override>::_M_realloc_insert<llama_model_kv_override>(__gnu_cxx::__normal_iterator<llama_model_kv_override*,std::vector<llama_model_kv_override>>,llama_model_kv_override &&) loc_73284: mov bpl, 1 jmp loc_7331E loc_7328C: add r15, 6 mov [rsp+138h+var_130], 2 lea rsi, aTrue; "true" mov rdi, r15 call _strcmp test eax, eax jz loc_73330 lea rsi, aAdvancedOption+0ABh; "false" mov rdi, r15 call _strcmp test eax, eax jz loc_7335E lea rax, common_log_verbosity_thold cmp dword ptr [rax], 0 js short loc_7331C call _Z15common_log_mainv; common_log_main(void) lea rdx, aSInvalidBoolea; "%s: invalid boolean value for KV overri"... jmp loc_73150 loc_732E3: add r15, 5 mov [rsp+138h+var_130], 3 mov rdi, r15 call _strlen cmp rax, 80h jb short loc_7333D lea rax, common_log_verbosity_thold cmp dword ptr [rax], 0 js short loc_7331C call _Z15common_log_mainv; common_log_main(void) lea rdx, aSMalformedKvOv_0; "%s: malformed KV override '%s', value c"... jmp loc_73150 loc_7331C: xor ebp, ebp loc_7331E: mov eax, ebp add rsp, 110h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_73330: mov byte ptr [rsp+138h+var_A8], 1 jmp loc_7324E loc_7333D: lea rbx, [rsp+138h+var_A8] mov edx, 7Fh mov rdi, rbx mov rsi, r15 call _strncpy mov byte ptr [rbx+7Fh], 0 jmp loc_7324E loc_7335E: mov byte ptr [rsp+138h+var_A8], 0 jmp loc_7324E
long long string_parse_kv_override(long long a1, long long a2) { unsigned int v2; // ebp long long v3; // rax long long v4; // r15 long long v5; // r12 int v6; // eax int v7; // r9d const char *v8; // rdx long long v9; // r15 long long v10; // r15 int v12; // [rsp+8h] [rbp-130h] BYREF _BYTE v13[132]; // [rsp+Ch] [rbp-12Ch] BYREF long long v14[15]; // [rsp+90h] [rbp-A8h] BYREF char v15; // [rsp+10Fh] [rbp-29h] v3 = strchr(a1, 61LL); if ( !v3 || (v4 = v3, v5 = v3 - a1, v3 - a1 >= 128) ) { if ( common_log_verbosity_thold >= 0 ) { v6 = common_log_main(); v8 = "%s: malformed KV override '%s'\n"; LABEL_5: v2 = 0; common_log_add(v6, 4, (_DWORD)v8, (unsigned int)"string_parse_kv_override", a1, v7); return v2; } return 0; } strncpy(v13, a1, v3 - a1); v13[v5] = 0; if ( !(unsigned int)strncmp(v4 + 1, "int:", 4LL) ) { v12 = 0; v14[0] = atol(v4 + 5); } else if ( !(unsigned int)strncmp(v4 + 1, "float:", 6LL) ) { v12 = 1; v14[0] = atof(v4 + 7); } else if ( !(unsigned int)strncmp(v4 + 1, "bool:", 5LL) ) { v9 = v4 + 6; v12 = 2; if ( !(unsigned int)strcmp(v9, "true") ) { LOBYTE(v14[0]) = 1; } else { if ( (unsigned int)strcmp(v9, "false") ) { if ( common_log_verbosity_thold >= 0 ) { v6 = common_log_main(); v8 = "%s: invalid boolean value for KV override '%s'\n"; goto LABEL_5; } return 0; } LOBYTE(v14[0]) = 0; } } else { if ( (unsigned int)strncmp(v4 + 1, "str:", 4LL) ) { if ( common_log_verbosity_thold >= 0 ) { v6 = common_log_main(); v8 = "%s: invalid type for KV override '%s'\n"; goto LABEL_5; } return 0; } v10 = v4 + 5; v12 = 3; if ( (unsigned long long)strlen(v10) >= 0x80 ) { if ( common_log_verbosity_thold >= 0 ) { v6 = common_log_main(); v8 = "%s: malformed KV override '%s', value cannot exceed 127 chars\n"; goto LABEL_5; } return 0; } strncpy(v14, v10, 127LL); v15 = 0; } if ( *(_QWORD *)(a2 + 8) == *(_QWORD *)(a2 + 16) ) { std::vector<llama_model_kv_override>::_M_realloc_insert<llama_model_kv_override>(a2, *(_QWORD *)(a2 + 8), &v12); } else { memcpy(*(_QWORD *)(a2 + 8), &v12, 264LL); *(_QWORD *)(a2 + 8) += 264LL; } LOBYTE(v2) = 1; return v2; }
56,895
ggml_compute_forward_timestep_embedding_f32(ggml_compute_params const*, ggml_tensor*)
ngxson[P]ggml-easy/ggml/src/ggml-cpu/ops.cpp
static void ggml_compute_forward_timestep_embedding_f32( const ggml_compute_params * params, ggml_tensor * dst) { const ggml_tensor * src0 = dst->src[0]; GGML_ASSERT(src0->nb[0] == sizeof(float)); const int ith = params->ith; const int nth = params->nth; GGML_TENSOR_UNARY_OP_LOCALS const int dim = ggml_get_op_params_i32(dst, 0); const int max_period = ggml_get_op_params_i32(dst, 1); int half = dim / 2; for (int64_t i = 0; i < ne00; i++) { float * embed_data = (float *)((char *) dst->data + i*nb1); for (int64_t j = ith; j < half; j += nth) { float timestep = ((float *)src0->data)[i]; float freq = (float)expf(-logf(max_period) * j / half); float arg = timestep * freq; embed_data[j] = cosf(arg); embed_data[j + half] = sinf(arg); } if (dim % 2 != 0 && ith == 0) { embed_data[dim] = 0.f; } } }
O0
cpp
ggml_compute_forward_timestep_embedding_f32(ggml_compute_params const*, ggml_tensor*): subq $0xd8, %rsp movq %rdi, 0xd0(%rsp) movq %rsi, 0xc8(%rsp) movq 0xc8(%rsp), %rax movq 0x98(%rax), %rax movq %rax, 0xc0(%rsp) movq 0xc0(%rsp), %rax cmpq $0x4, 0x30(%rax) je 0x9f22e leaq 0x16484(%rip), %rdi # 0xb5698 movl $0x1a60, %esi # imm = 0x1A60 leaq 0xc75e(%rip), %rdx # 0xab97e leaq 0x16984(%rip), %rcx # 0xb5bab movb $0x0, %al callq 0x10660 movq 0xd0(%rsp), %rax movl (%rax), %eax movl %eax, 0xbc(%rsp) movq 0xd0(%rsp), %rax movl 0x4(%rax), %eax movl %eax, 0xb8(%rsp) movq 0xc0(%rsp), %rax movq 0x10(%rax), %rax movq %rax, 0xb0(%rsp) movq 0xc0(%rsp), %rax movq 0x18(%rax), %rax movq %rax, 0xa8(%rsp) movq 0xc0(%rsp), %rax movq 0x20(%rax), %rax movq %rax, 0xa0(%rsp) movq 0xc0(%rsp), %rax movq 0x28(%rax), %rax movq %rax, 0x98(%rsp) movq 0xc0(%rsp), %rax movq 0x30(%rax), %rax movq %rax, 0x90(%rsp) movq 0xc0(%rsp), %rax movq 0x38(%rax), %rax movq %rax, 0x88(%rsp) movq 0xc0(%rsp), %rax movq 0x40(%rax), %rax movq %rax, 0x80(%rsp) movq 0xc0(%rsp), %rax movq 0x48(%rax), %rax movq %rax, 0x78(%rsp) movq 0xc8(%rsp), %rax movq 0x10(%rax), %rax movq %rax, 0x70(%rsp) movq 0xc8(%rsp), %rax movq 0x18(%rax), %rax movq %rax, 0x68(%rsp) movq 0xc8(%rsp), %rax movq 0x20(%rax), %rax movq %rax, 0x60(%rsp) movq 0xc8(%rsp), %rax movq 0x28(%rax), %rax movq %rax, 0x58(%rsp) movq 0xc8(%rsp), %rax movq 0x30(%rax), %rax movq %rax, 0x50(%rsp) movq 0xc8(%rsp), %rax movq 0x38(%rax), %rax movq %rax, 0x48(%rsp) movq 0xc8(%rsp), %rax movq 0x40(%rax), %rax movq %rax, 0x40(%rsp) movq 0xc8(%rsp), %rax movq 0x48(%rax), %rax movq %rax, 0x38(%rsp) movq 0xc8(%rsp), %rdi xorl %esi, %esi callq 0x9bd30 movl %eax, 0x34(%rsp) movq 0xc8(%rsp), %rdi movl $0x1, %esi callq 0x9bd30 movl %eax, 0x30(%rsp) movl 0x34(%rsp), %eax movl $0x2, %ecx cltd idivl %ecx movl %eax, 0x2c(%rsp) movq $0x0, 0x20(%rsp) movq 0x20(%rsp), %rax cmpq 0xb0(%rsp), %rax jge 0x9f50c movq 0xc8(%rsp), %rax movq 0xf8(%rax), %rax movq 0x20(%rsp), %rcx imulq 0x48(%rsp), %rcx addq %rcx, %rax movq %rax, 0x18(%rsp) movslq 0xbc(%rsp), %rax movq %rax, 0x10(%rsp) movq 0x10(%rsp), %rax movslq 0x2c(%rsp), %rcx cmpq %rcx, %rax jge 0x9f4c9 movq 0xc0(%rsp), %rax movq 0xf8(%rax), %rax movq 0x20(%rsp), %rcx vmovss (%rax,%rcx,4), %xmm0 vmovss %xmm0, 0xc(%rsp) vcvtsi2ssl 0x30(%rsp), %xmm0, %xmm0 callq 0x10990 vmovd %xmm0, %eax xorl $0x80000000, %eax # imm = 0x80000000 vmovd %eax, %xmm0 vcvtsi2ssq 0x10(%rsp), %xmm1, %xmm1 vmulss %xmm1, %xmm0, %xmm0 vcvtsi2ssl 0x2c(%rsp), %xmm1, %xmm1 vdivss %xmm1, %xmm0, %xmm0 callq 0x105c0 vmovss %xmm0, 0x8(%rsp) vmovss 0xc(%rsp), %xmm0 vmulss 0x8(%rsp), %xmm0, %xmm0 vmovss %xmm0, 0x4(%rsp) vmovss 0x4(%rsp), %xmm0 callq 0xf910 movq 0x18(%rsp), %rax movq 0x10(%rsp), %rcx vmovss %xmm0, (%rax,%rcx,4) vmovss 0x4(%rsp), %xmm0 callq 0xfa70 movq 0x18(%rsp), %rax movq 0x10(%rsp), %rcx movslq 0x2c(%rsp), %rdx addq %rdx, %rcx vmovss %xmm0, (%rax,%rcx,4) movslq 0xb8(%rsp), %rax addq 0x10(%rsp), %rax movq %rax, 0x10(%rsp) jmp 0x9f3fa movl 0x34(%rsp), %eax movl $0x2, %ecx cltd idivl %ecx cmpl $0x0, %edx je 0x9f4f7 cmpl $0x0, 0xbc(%rsp) jne 0x9f4f7 movq 0x18(%rsp), %rax movslq 0x34(%rsp), %rcx vpxor %xmm0, %xmm0, %xmm0 vmovss %xmm0, (%rax,%rcx,4) jmp 0x9f4f9 movq 0x20(%rsp), %rax addq $0x1, %rax movq %rax, 0x20(%rsp) jmp 0x9f3b8 addq $0xd8, %rsp retq nopw %cs:(%rax,%rax)
_ZL43ggml_compute_forward_timestep_embedding_f32PK19ggml_compute_paramsP11ggml_tensor: sub rsp, 0D8h mov [rsp+0D8h+var_8], rdi mov [rsp+0D8h+var_10], rsi mov rax, [rsp+0D8h+var_10] mov rax, [rax+98h] mov [rsp+0D8h+var_18], rax mov rax, [rsp+0D8h+var_18] cmp qword ptr [rax+30h], 4 jz short loc_9F22E lea rdi, aWorkspaceLlm4b_6; "/workspace/llm4binary/github/2025_star3"... mov esi, 1A60h lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aSrc0Nb0SizeofF; "src0->nb[0] == sizeof(float)" mov al, 0 call _ggml_abort loc_9F22E: mov rax, [rsp+0D8h+var_8] mov eax, [rax] mov [rsp+0D8h+var_1C], eax mov rax, [rsp+0D8h+var_8] mov eax, [rax+4] mov [rsp+0D8h+var_20], eax mov rax, [rsp+0D8h+var_18] mov rax, [rax+10h] mov [rsp+0D8h+var_28], rax mov rax, [rsp+0D8h+var_18] mov rax, [rax+18h] mov [rsp+0D8h+var_30], rax mov rax, [rsp+0D8h+var_18] mov rax, [rax+20h] mov [rsp+0D8h+var_38], rax mov rax, [rsp+0D8h+var_18] mov rax, [rax+28h] mov [rsp+0D8h+var_40], rax mov rax, [rsp+0D8h+var_18] mov rax, [rax+30h] mov [rsp+0D8h+var_48], rax mov rax, [rsp+0D8h+var_18] mov rax, [rax+38h] mov [rsp+0D8h+var_50], rax mov rax, [rsp+0D8h+var_18] mov rax, [rax+40h] mov [rsp+0D8h+var_58], rax mov rax, [rsp+0D8h+var_18] mov rax, [rax+48h] mov [rsp+0D8h+var_60], rax mov rax, [rsp+0D8h+var_10] mov rax, [rax+10h] mov [rsp+0D8h+var_68], rax mov rax, [rsp+0D8h+var_10] mov rax, [rax+18h] mov [rsp+0D8h+var_70], rax mov rax, [rsp+0D8h+var_10] mov rax, [rax+20h] mov [rsp+0D8h+var_78], rax mov rax, [rsp+0D8h+var_10] mov rax, [rax+28h] mov [rsp+0D8h+var_80], rax mov rax, [rsp+0D8h+var_10] mov rax, [rax+30h] mov [rsp+0D8h+var_88], rax mov rax, [rsp+0D8h+var_10] mov rax, [rax+38h] mov [rsp+0D8h+var_90], rax mov rax, [rsp+0D8h+var_10] mov rax, [rax+40h] mov [rsp+0D8h+var_98], rax mov rax, [rsp+0D8h+var_10] mov rax, [rax+48h] mov [rsp+0D8h+var_A0], rax mov rdi, [rsp+0D8h+var_10] xor esi, esi call _ZL22ggml_get_op_params_i32PK11ggml_tensorj; ggml_get_op_params_i32(ggml_tensor const*,uint) mov [rsp+0D8h+var_A4], eax mov rdi, [rsp+0D8h+var_10] mov esi, 1 call _ZL22ggml_get_op_params_i32PK11ggml_tensorj; ggml_get_op_params_i32(ggml_tensor const*,uint) mov [rsp+0D8h+var_A8], eax mov eax, [rsp+0D8h+var_A4] mov ecx, 2 cdq idiv ecx mov [rsp+0D8h+var_AC], eax mov [rsp+0D8h+var_B8], 0 loc_9F3B8: mov rax, [rsp+0D8h+var_B8] cmp rax, [rsp+0D8h+var_28] jge loc_9F50C mov rax, [rsp+0D8h+var_10] mov rax, [rax+0F8h] mov rcx, [rsp+0D8h+var_B8] imul rcx, [rsp+0D8h+var_90] add rax, rcx mov [rsp+0D8h+var_C0], rax movsxd rax, [rsp+0D8h+var_1C] mov [rsp+0D8h+var_C8], rax loc_9F3FA: mov rax, [rsp+0D8h+var_C8] movsxd rcx, [rsp+0D8h+var_AC] cmp rax, rcx jge loc_9F4C9 mov rax, [rsp+0D8h+var_18] mov rax, [rax+0F8h] mov rcx, [rsp+0D8h+var_B8] vmovss xmm0, dword ptr [rax+rcx*4] vmovss [rsp+0D8h+var_CC], xmm0 vcvtsi2ss xmm0, xmm0, [rsp+0D8h+var_A8] call _logf vmovd eax, xmm0 xor eax, 80000000h vmovd xmm0, eax vcvtsi2ss xmm1, xmm1, [rsp+0D8h+var_C8] vmulss xmm0, xmm0, xmm1 vcvtsi2ss xmm1, xmm1, [rsp+0D8h+var_AC] vdivss xmm0, xmm0, xmm1 call _expf vmovss [rsp+0D8h+var_D0], xmm0 vmovss xmm0, [rsp+0D8h+var_CC] vmulss xmm0, xmm0, [rsp+0D8h+var_D0] vmovss [rsp+0D8h+var_D4], xmm0 vmovss xmm0, [rsp+0D8h+var_D4] call _cosf mov rax, [rsp+0D8h+var_C0] mov rcx, [rsp+0D8h+var_C8] vmovss dword ptr [rax+rcx*4], xmm0 vmovss xmm0, [rsp+0D8h+var_D4] call _sinf mov rax, [rsp+0D8h+var_C0] mov rcx, [rsp+0D8h+var_C8] movsxd rdx, [rsp+0D8h+var_AC] add rcx, rdx vmovss dword ptr [rax+rcx*4], xmm0 movsxd rax, [rsp+0D8h+var_20] add rax, [rsp+0D8h+var_C8] mov [rsp+0D8h+var_C8], rax jmp loc_9F3FA loc_9F4C9: mov eax, [rsp+0D8h+var_A4] mov ecx, 2 cdq idiv ecx cmp edx, 0 jz short loc_9F4F7 cmp [rsp+0D8h+var_1C], 0 jnz short loc_9F4F7 mov rax, [rsp+0D8h+var_C0] movsxd rcx, [rsp+0D8h+var_A4] vpxor xmm0, xmm0, xmm0 vmovss dword ptr [rax+rcx*4], xmm0 loc_9F4F7: jmp short $+2 loc_9F4F9: mov rax, [rsp+0D8h+var_B8] add rax, 1 mov [rsp+0D8h+var_B8], rax jmp loc_9F3B8 loc_9F50C: add rsp, 0D8h retn
long long ggml_compute_forward_timestep_embedding_f32(int *a1, _QWORD *a2, __m128 _XMM0, __m128 _XMM1) { long long result; // rax long long j; // [rsp+10h] [rbp-C8h] long long v27; // [rsp+18h] [rbp-C0h] long long i; // [rsp+20h] [rbp-B8h] int v29; // [rsp+2Ch] [rbp-ACh] int op_params_i32; // [rsp+34h] [rbp-A4h] long long v31; // [rsp+48h] [rbp-90h] long long v32; // [rsp+B0h] [rbp-28h] int v33; // [rsp+B8h] [rbp-20h] int v34; // [rsp+BCh] [rbp-1Ch] _QWORD *v35; // [rsp+C0h] [rbp-18h] v35 = (_QWORD *)a2[19]; if ( v35[6] != 4LL ) *(double *)_XMM0.m128_u64 = ggml_abort( "/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml-cpu/ops.cpp", 6752LL, "GGML_ASSERT(%s) failed", "src0->nb[0] == sizeof(float)"); v34 = *a1; v33 = a1[1]; v32 = v35[2]; v31 = a2[7]; op_params_i32 = ggml_get_op_params_i32((long long)a2, 0); ggml_get_op_params_i32((long long)a2, 1u); v29 = op_params_i32 / 2; for ( i = 0LL; ; ++i ) { result = i; if ( i >= v32 ) break; v27 = v31 * i + a2[31]; for ( j = v34; j < v29; j += v33 ) { _RAX = v35[31]; _RCX = i; __asm { vmovss xmm0, dword ptr [rax+rcx*4] vmovss [rsp+0D8h+var_CC], xmm0 vcvtsi2ss xmm0, xmm0, [rsp+0D8h+var_A8] } *(double *)&_XMM0 = logf(*(double *)&_XMM0); __asm { vmovd eax, xmm0 } _EAX ^= 0x80000000; __asm { vmovd xmm0, eax vcvtsi2ss xmm1, xmm1, [rsp+0D8h+var_C8] vmulss xmm0, xmm0, xmm1 vcvtsi2ss xmm1, xmm1, [rsp+0D8h+var_AC] vdivss xmm0, xmm0, xmm1 } *(double *)&_XMM0 = expf(*(double *)&_XMM0); __asm { vmovss [rsp+0D8h+var_D0], xmm0 vmovss xmm0, [rsp+0D8h+var_CC] vmulss xmm0, xmm0, [rsp+0D8h+var_D0] vmovss [rsp+0D8h+var_D4], xmm0 vmovss xmm0, [rsp+0D8h+var_D4] } *(double *)&_XMM0 = cosf(*(double *)&_XMM0); _RAX = v27; _RCX = j; __asm { vmovss dword ptr [rax+rcx*4], xmm0 vmovss xmm0, [rsp+0D8h+var_D4] } *(double *)_XMM0.m128_u64 = sinf(*(double *)_XMM0.m128_u64); _RAX = v27; _RCX = v29 + j; __asm { vmovss dword ptr [rax+rcx*4], xmm0 } } if ( op_params_i32 % 2 ) { if ( !v34 ) { _RAX = v27; _RCX = op_params_i32; __asm { vpxor xmm0, xmm0, xmm0 vmovss dword ptr [rax+rcx*4], xmm0 } } } } return result; }
ggml_compute_forward_timestep_embedding_f32: SUB RSP,0xd8 MOV qword ptr [RSP + 0xd0],RDI MOV qword ptr [RSP + 0xc8],RSI MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x98] MOV qword ptr [RSP + 0xc0],RAX MOV RAX,qword ptr [RSP + 0xc0] CMP qword ptr [RAX + 0x30],0x4 JZ 0x0019f22e LEA RDI,[0x1b5698] MOV ESI,0x1a60 LEA RDX,[0x1ab97e] LEA RCX,[0x1b5bab] MOV AL,0x0 CALL 0x00110660 LAB_0019f22e: MOV RAX,qword ptr [RSP + 0xd0] MOV EAX,dword ptr [RAX] MOV dword ptr [RSP + 0xbc],EAX MOV RAX,qword ptr [RSP + 0xd0] MOV EAX,dword ptr [RAX + 0x4] MOV dword ptr [RSP + 0xb8],EAX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RSP + 0xb0],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RSP + 0xa8],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x20] MOV qword ptr [RSP + 0xa0],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RSP + 0x98],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x30] MOV qword ptr [RSP + 0x90],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x38] MOV qword ptr [RSP + 0x88],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x40] MOV qword ptr [RSP + 0x80],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0x48] MOV qword ptr [RSP + 0x78],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RSP + 0x70],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RSP + 0x68],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x20] MOV qword ptr [RSP + 0x60],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RSP + 0x58],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x30] MOV qword ptr [RSP + 0x50],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x38] MOV qword ptr [RSP + 0x48],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x40] MOV qword ptr [RSP + 0x40],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0x48] MOV qword ptr [RSP + 0x38],RAX MOV RDI,qword ptr [RSP + 0xc8] XOR ESI,ESI CALL 0x0019bd30 MOV dword ptr [RSP + 0x34],EAX MOV RDI,qword ptr [RSP + 0xc8] MOV ESI,0x1 CALL 0x0019bd30 MOV dword ptr [RSP + 0x30],EAX MOV EAX,dword ptr [RSP + 0x34] MOV ECX,0x2 CDQ IDIV ECX MOV dword ptr [RSP + 0x2c],EAX MOV qword ptr [RSP + 0x20],0x0 LAB_0019f3b8: MOV RAX,qword ptr [RSP + 0x20] CMP RAX,qword ptr [RSP + 0xb0] JGE 0x0019f50c MOV RAX,qword ptr [RSP + 0xc8] MOV RAX,qword ptr [RAX + 0xf8] MOV RCX,qword ptr [RSP + 0x20] IMUL RCX,qword ptr [RSP + 0x48] ADD RAX,RCX MOV qword ptr [RSP + 0x18],RAX MOVSXD RAX,dword ptr [RSP + 0xbc] MOV qword ptr [RSP + 0x10],RAX LAB_0019f3fa: MOV RAX,qword ptr [RSP + 0x10] MOVSXD RCX,dword ptr [RSP + 0x2c] CMP RAX,RCX JGE 0x0019f4c9 MOV RAX,qword ptr [RSP + 0xc0] MOV RAX,qword ptr [RAX + 0xf8] MOV RCX,qword ptr [RSP + 0x20] VMOVSS XMM0,dword ptr [RAX + RCX*0x4] VMOVSS dword ptr [RSP + 0xc],XMM0 VCVTSI2SS XMM0,XMM0,dword ptr [RSP + 0x30] CALL 0x00110990 VMOVD EAX,XMM0 XOR EAX,0x80000000 VMOVD XMM0,EAX VCVTSI2SS XMM1,XMM1,qword ptr [RSP + 0x10] VMULSS XMM0,XMM0,XMM1 VCVTSI2SS XMM1,XMM1,dword ptr [RSP + 0x2c] VDIVSS XMM0,XMM0,XMM1 CALL 0x001105c0 VMOVSS dword ptr [RSP + 0x8],XMM0 VMOVSS XMM0,dword ptr [RSP + 0xc] VMULSS XMM0,XMM0,dword ptr [RSP + 0x8] VMOVSS dword ptr [RSP + 0x4],XMM0 VMOVSS XMM0,dword ptr [RSP + 0x4] CALL 0x0010f910 MOV RAX,qword ptr [RSP + 0x18] MOV RCX,qword ptr [RSP + 0x10] VMOVSS dword ptr [RAX + RCX*0x4],XMM0 VMOVSS XMM0,dword ptr [RSP + 0x4] CALL 0x0010fa70 MOV RAX,qword ptr [RSP + 0x18] MOV RCX,qword ptr [RSP + 0x10] MOVSXD RDX,dword ptr [RSP + 0x2c] ADD RCX,RDX VMOVSS dword ptr [RAX + RCX*0x4],XMM0 MOVSXD RAX,dword ptr [RSP + 0xb8] ADD RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x10],RAX JMP 0x0019f3fa LAB_0019f4c9: MOV EAX,dword ptr [RSP + 0x34] MOV ECX,0x2 CDQ IDIV ECX CMP EDX,0x0 JZ 0x0019f4f7 CMP dword ptr [RSP + 0xbc],0x0 JNZ 0x0019f4f7 MOV RAX,qword ptr [RSP + 0x18] MOVSXD RCX,dword ptr [RSP + 0x34] VPXOR XMM0,XMM0,XMM0 VMOVSS dword ptr [RAX + RCX*0x4],XMM0 LAB_0019f4f7: JMP 0x0019f4f9 LAB_0019f4f9: MOV RAX,qword ptr [RSP + 0x20] ADD RAX,0x1 MOV qword ptr [RSP + 0x20],RAX JMP 0x0019f3b8 LAB_0019f50c: ADD RSP,0xd8 RET
/* ggml_compute_forward_timestep_embedding_f32(ggml_compute_params const*, ggml_tensor*) */ void ggml_compute_forward_timestep_embedding_f32(ggml_compute_params *param_1,ggml_tensor *param_2) { int iVar1; int iVar2; long lVar3; long lVar4; long lVar5; int iVar6; int iVar7; int iVar8; long lVar9; float fVar10; float fVar11; long local_c8; long local_b8; lVar3 = *(long *)(param_2 + 0x98); if (*(long *)(lVar3 + 0x30) != 4) { ggml_abort("/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml-cpu/ops.cpp" ,0x1a60,"GGML_ASSERT(%s) failed","src0->nb[0] == sizeof(float)"); } iVar1 = *(int *)param_1; iVar2 = *(int *)(param_1 + 4); lVar4 = *(long *)(lVar3 + 0x10); lVar5 = *(long *)(param_2 + 0x38); iVar6 = ggml_get_op_params_i32(param_2,0); iVar7 = ggml_get_op_params_i32(param_2,1); iVar8 = iVar6 / 2; for (local_b8 = 0; local_b8 < lVar4; local_b8 = local_b8 + 1) { lVar9 = *(long *)(param_2 + 0xf8) + local_b8 * lVar5; for (local_c8 = (long)iVar1; local_c8 < iVar8; local_c8 = iVar2 + local_c8) { fVar11 = *(float *)(*(long *)(lVar3 + 0xf8) + local_b8 * 4); fVar10 = logf((float)iVar7); fVar10 = expf((-fVar10 * (float)local_c8) / (float)iVar8); fVar11 = fVar11 * fVar10; fVar10 = cosf(fVar11); *(float *)(lVar9 + local_c8 * 4) = fVar10; fVar11 = sinf(fVar11); *(float *)(lVar9 + (local_c8 + iVar8) * 4) = fVar11; } if ((iVar6 % 2 != 0) && (iVar1 == 0)) { *(int4 *)(lVar9 + (long)iVar6 * 4) = 0; } } return; }
56,896
ggml_backend_tensor_get
llama.cpp/ggml/src/ggml-backend.cpp
void ggml_backend_tensor_get(const struct ggml_tensor * tensor, void * data, size_t offset, size_t size) { GGML_ASSERT(tensor); ggml_backend_buffer_t buf = tensor->view_src ? tensor->view_src->buffer : tensor->buffer; if (size == 0) { return; } GGML_ASSERT(buf != NULL && "tensor buffer not set"); GGML_ASSERT(tensor->data != NULL && "tensor not allocated"); GGML_ASSERT(offset + size <= ggml_nbytes(tensor) && "tensor read out of bounds"); buf->iface.get_tensor(buf, tensor, data, offset, size); }
O3
cpp
ggml_backend_tensor_get: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax testq %rdi, %rdi je 0x25512 movq %rcx, %rbx movq %rdi, %r12 movq 0xe8(%rdi), %rax testq %rax, %rax cmoveq %rdi, %rax testq %rcx, %rcx je 0x25503 movq 0x8(%rax), %r13 testq %r13, %r13 je 0x2552e cmpq $0x0, 0xf8(%r12) je 0x2554a movq %rdx, %r14 movq %rsi, %r15 leaq (%rbx,%rdx), %rbp movq %r12, %rdi callq 0x161b0 cmpq %rax, %rbp ja 0x25566 movq 0x28(%r13), %rax movq %r13, %rdi movq %r12, %rsi movq %r15, %rdx movq %r14, %rcx movq %rbx, %r8 addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmpq *%rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x27dd9(%rip), %rdi # 0x4d2f2 leaq 0x2512e(%rip), %rdx # 0x4a64e leaq 0x27560(%rip), %rcx # 0x4ca87 movl $0x110, %esi # imm = 0x110 jmp 0x25580 leaq 0x27dbd(%rip), %rdi # 0x4d2f2 leaq 0x25112(%rip), %rdx # 0x4a64e leaq 0x27ee1(%rip), %rcx # 0x4d424 movl $0x117, %esi # imm = 0x117 jmp 0x25580 leaq 0x27da1(%rip), %rdi # 0x4d2f2 leaq 0x250f6(%rip), %rdx # 0x4a64e leaq 0x27e0d(%rip), %rcx # 0x4d36c movl $0x118, %esi # imm = 0x118 jmp 0x25580 leaq 0x27d85(%rip), %rdi # 0x4d2f2 leaq 0x250da(%rip), %rdx # 0x4a64e leaq 0x27e65(%rip), %rcx # 0x4d3e0 movl $0x119, %esi # imm = 0x119 xorl %eax, %eax callq 0x17c80
ggml_backend_tensor_get: push rbp push r15 push r14 push r13 push r12 push rbx push rax test rdi, rdi jz short loc_25512 mov rbx, rcx mov r12, rdi mov rax, [rdi+0E8h] test rax, rax cmovz rax, rdi test rcx, rcx jz short loc_25503 mov r13, [rax+8] test r13, r13 jz short loc_2552E cmp qword ptr [r12+0F8h], 0 jz loc_2554A mov r14, rdx mov r15, rsi lea rbp, [rbx+rdx] mov rdi, r12 call _ggml_nbytes cmp rbp, rax ja loc_25566 mov rax, [r13+28h] mov rdi, r13 mov rsi, r12 mov rdx, r15 mov rcx, r14 mov r8, rbx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp rax loc_25503: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_25512: lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/llama."... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aCgraphNodesCgr+26h; "tensor" mov esi, 110h jmp short loc_25580 loc_2552E: lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/llama."... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aBufNullTensorB; "buf != NULL && \"tensor buffer not set"... mov esi, 117h jmp short loc_25580 loc_2554A: lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/llama."... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aTensorDataNull; "tensor->data != NULL && \"tensor not al"... mov esi, 118h jmp short loc_25580 loc_25566: lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/llama."... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aOffsetSizeGgml_0; "offset + size <= ggml_nbytes(tensor) &&"... mov esi, 119h loc_25580: xor eax, eax call _ggml_abort
long long ggml_backend_tensor_get(long long a1, long long a2, long long a3, long long a4, int a5, int a6) { long long result; // rax long long v8; // r13 char *v10; // rcx int v11; // esi if ( !a1 ) { v10 = "tensor"; v11 = 272; goto LABEL_14; } result = *(_QWORD *)(a1 + 232); if ( !result ) result = a1; if ( a4 ) { v8 = *(_QWORD *)(result + 8); if ( v8 ) { if ( *(_QWORD *)(a1 + 248) ) { if ( a4 + a3 <= ggml_nbytes((unsigned int *)a1) ) return (*(long long ( **)(long long, long long, long long, long long, long long))(v8 + 40))(v8, a1, a2, a3, a4); v10 = "offset + size <= ggml_nbytes(tensor) && \"tensor read out of bounds\""; v11 = 281; } else { v10 = "tensor->data != NULL && \"tensor not allocated\""; v11 = 280; } } else { v10 = "buf != NULL && \"tensor buffer not set\""; v11 = 279; } LABEL_14: ggml_abort( (unsigned int)"/workspace/llm4binary/github2025/llama.cpp/ggml/src/ggml-backend.cpp", v11, (unsigned int)"GGML_ASSERT(%s) failed", (_DWORD)v10, a5, a6); } return result; }
ggml_backend_tensor_get: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX TEST RDI,RDI JZ 0x00125512 MOV RBX,RCX MOV R12,RDI MOV RAX,qword ptr [RDI + 0xe8] TEST RAX,RAX CMOVZ RAX,RDI TEST RCX,RCX JZ 0x00125503 MOV R13,qword ptr [RAX + 0x8] TEST R13,R13 JZ 0x0012552e CMP qword ptr [R12 + 0xf8],0x0 JZ 0x0012554a MOV R14,RDX MOV R15,RSI LEA RBP,[RBX + RDX*0x1] MOV RDI,R12 CALL 0x001161b0 CMP RBP,RAX JA 0x00125566 MOV RAX,qword ptr [R13 + 0x28] MOV RDI,R13 MOV RSI,R12 MOV RDX,R15 MOV RCX,R14 MOV R8,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP RAX LAB_00125503: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00125512: LEA RDI,[0x14d2f2] LEA RDX,[0x14a64e] LEA RCX,[0x14ca87] MOV ESI,0x110 JMP 0x00125580 LAB_0012552e: LEA RDI,[0x14d2f2] LEA RDX,[0x14a64e] LEA RCX,[0x14d424] MOV ESI,0x117 JMP 0x00125580 LAB_0012554a: LEA RDI,[0x14d2f2] LEA RDX,[0x14a64e] LEA RCX,[0x14d36c] MOV ESI,0x118 JMP 0x00125580 LAB_00125566: LEA RDI,[0x14d2f2] LEA RDX,[0x14a64e] LEA RCX,[0x14d3e0] MOV ESI,0x119 LAB_00125580: XOR EAX,EAX CALL 0x00117c80
void ggml_backend_tensor_get(long param_1,int8 param_2,long param_3,long param_4) { long lVar1; ulong uVar2; char *pcVar3; int8 uVar4; if (param_1 == 0) { pcVar3 = "tensor"; uVar4 = 0x110; } else { lVar1 = *(long *)(param_1 + 0xe8); if (*(long *)(param_1 + 0xe8) == 0) { lVar1 = param_1; } if (param_4 == 0) { return; } lVar1 = *(long *)(lVar1 + 8); if (lVar1 == 0) { pcVar3 = "buf != NULL && \"tensor buffer not set\""; uVar4 = 0x117; } else if (*(long *)(param_1 + 0xf8) == 0) { pcVar3 = "tensor->data != NULL && \"tensor not allocated\""; uVar4 = 0x118; } else { uVar2 = ggml_nbytes(param_1); if ((ulong)(param_4 + param_3) <= uVar2) { /* WARNING: Could not recover jumptable at 0x00125501. Too many branches */ /* WARNING: Treating indirect jump as call */ (**(code **)(lVar1 + 0x28))(lVar1,param_1,param_2,param_3,param_4); return; } pcVar3 = "offset + size <= ggml_nbytes(tensor) && \"tensor read out of bounds\""; uVar4 = 0x119; } } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github2025/llama.cpp/ggml/src/ggml-backend.cpp",uVar4, "GGML_ASSERT(%s) failed",pcVar3); }
56,897
translog_page_next
eloqsql/storage/maria/ma_loghandler.c
static my_bool translog_page_next(TRANSLOG_ADDRESS *horizon, struct st_buffer_cursor *cursor, struct st_translog_buffer **prev_buffer) { struct st_translog_buffer *buffer= cursor->buffer; DBUG_ENTER("translog_page_next"); *prev_buffer= NULL; if ((cursor->ptr + TRANSLOG_PAGE_SIZE > cursor->buffer->buffer + TRANSLOG_WRITE_BUFFER) || (LSN_OFFSET(*horizon) > log_descriptor.log_file_max_size - TRANSLOG_PAGE_SIZE)) { DBUG_PRINT("info", ("Switch to next buffer Buffer Size: %lu (%lu) => %d " "File size: %lu max: %lu => %d", (ulong) cursor->buffer->size, (ulong) (cursor->ptr - cursor->buffer->buffer), (cursor->ptr + TRANSLOG_PAGE_SIZE > cursor->buffer->buffer + TRANSLOG_WRITE_BUFFER), (ulong) LSN_OFFSET(*horizon), (ulong) log_descriptor.log_file_max_size, (LSN_OFFSET(*horizon) > (log_descriptor.log_file_max_size - TRANSLOG_PAGE_SIZE)))); if (translog_buffer_next(horizon, cursor, LSN_OFFSET(*horizon) > (log_descriptor.log_file_max_size - TRANSLOG_PAGE_SIZE))) DBUG_RETURN(1); *prev_buffer= buffer; DBUG_PRINT("info", ("Buffer #%u (%p): have to be flushed", (uint) buffer->buffer_no, buffer)); } else { DBUG_PRINT("info", ("Use the same buffer #%u (%p): " "Buffer Size: %lu (%lu)", (uint) buffer->buffer_no, buffer, (ulong) cursor->buffer->size, (ulong) (cursor->ptr - cursor->buffer->buffer))); translog_finish_page(horizon, cursor); translog_new_page_header(horizon, cursor); } DBUG_RETURN(0); }
O0
c
translog_page_next: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x18(%rbp), %rax movq 0x28(%rax), %rax movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rax movq $0x0, (%rax) movq -0x18(%rbp), %rax movq 0x20(%rax), %rax addq $0x2000, %rax # imm = 0x2000 movq -0x18(%rbp), %rcx movq 0x28(%rcx), %rcx addq $0x100000, %rcx # imm = 0x100000 cmpq %rcx, %rax ja 0xeba281 movq -0x10(%rbp), %rcx movabsq $0xffffffff, %rax # imm = 0xFFFFFFFF andq (%rcx), %rax movl 0xec6d3c(%rip), %ecx # 0x1d80fb0 subl $0x2000, %ecx # imm = 0x2000 movl %ecx, %ecx cmpq %rcx, %rax jbe 0xeba2da jmp 0xeba283 jmp 0xeba285 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x10(%rbp), %rcx movabsq $0xffffffff, %rax # imm = 0xFFFFFFFF andq (%rcx), %rax movl 0xec6d0c(%rip), %ecx # 0x1d80fb0 subl $0x2000, %ecx # imm = 0x2000 movl %ecx, %ecx cmpq %rcx, %rax seta %al andb $0x1, %al movzbl %al, %eax movsbl %al, %edx callq 0xeb8560 cmpb $0x0, %al je 0xeba2cb jmp 0xeba2c5 movb $0x1, -0x1(%rbp) jmp 0xeba2fe movq -0x28(%rbp), %rcx movq -0x20(%rbp), %rax movq %rcx, (%rax) jmp 0xeba2d8 jmp 0xeba2f8 jmp 0xeba2dc jmp 0xeba2de movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0xeb4390 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0xeb3300 jmp 0xeba2fa movb $0x0, -0x1(%rbp) movb -0x1(%rbp), %al addq $0x30, %rsp popq %rbp retq nopw (%rax,%rax)
translog_page_next: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov rax, [rbp+var_18] mov rax, [rax+28h] mov [rbp+var_28], rax mov rax, [rbp+var_20] mov qword ptr [rax], 0 mov rax, [rbp+var_18] mov rax, [rax+20h] add rax, 2000h mov rcx, [rbp+var_18] mov rcx, [rcx+28h] add rcx, 100000h cmp rax, rcx ja short loc_EBA281 mov rcx, [rbp+var_10] mov rax, 0FFFFFFFFh and rax, [rcx] mov ecx, cs:dword_1D80FB0 sub ecx, 2000h mov ecx, ecx cmp rax, rcx jbe short loc_EBA2DA loc_EBA281: jmp short $+2 loc_EBA283: jmp short $+2 loc_EBA285: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rcx, [rbp+var_10] mov rax, 0FFFFFFFFh and rax, [rcx] mov ecx, cs:dword_1D80FB0 sub ecx, 2000h mov ecx, ecx cmp rax, rcx setnbe al and al, 1 movzx eax, al movsx edx, al call translog_buffer_next cmp al, 0 jz short loc_EBA2CB jmp short $+2 loc_EBA2C5: mov [rbp+var_1], 1 jmp short loc_EBA2FE loc_EBA2CB: mov rcx, [rbp+var_28] mov rax, [rbp+var_20] mov [rax], rcx jmp short $+2 loc_EBA2D8: jmp short loc_EBA2F8 loc_EBA2DA: jmp short $+2 loc_EBA2DC: jmp short $+2 loc_EBA2DE: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call translog_finish_page mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call translog_new_page_header loc_EBA2F8: jmp short $+2 loc_EBA2FA: mov [rbp+var_1], 0 loc_EBA2FE: mov al, [rbp+var_1] add rsp, 30h pop rbp retn
char translog_page_next(long long *a1, long long a2, _QWORD *a3) { long long v4; // [rsp+8h] [rbp-28h] v4 = *(_QWORD *)(a2 + 40); *a3 = 0LL; if ( *(_QWORD *)(a2 + 32) + 0x2000LL <= (unsigned long long)(*(_QWORD *)(a2 + 40) + 0x100000LL) && (unsigned int)*a1 <= (unsigned long long)(unsigned int)(dword_1D80FB0 - 0x2000) ) { translog_finish_page(a1, a2); translog_new_page_header(a1, a2); return 0; } if ( !translog_buffer_next(a1, a2, (unsigned int)*a1 > (unsigned long long)(unsigned int)(dword_1D80FB0 - 0x2000)) ) { *a3 = v4; return 0; } return 1; }
Item_bool_func_args_geometry_geometry: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RDI,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x28],RDI MOV RSI,qword ptr [RBP + -0x10] CALL 0x009d0810 MOV RDI,qword ptr [RBP + -0x28] LEA RAX,[0x1bcee88] MOV qword ptr [RDI],RAX LEA RAX,[0x1bcf4f0] MOV qword ptr [RDI + 0xa8],RAX ADD RDI,0xb0 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0xb0 LAB_00eba25f: CALL 0x00983f90 LAB_00eba264: JMP 0x00eba266 LAB_00eba266: ADD RSP,0x30 POP RBP RET
/* Item_bool_func_args_geometry_geometry::Item_bool_func_args_geometry_geometry(Item_bool_func_args_geometry_geometry const&) */ void __thiscall Item_bool_func_args_geometry_geometry::Item_bool_func_args_geometry_geometry (Item_bool_func_args_geometry_geometry *this, Item_bool_func_args_geometry_geometry *param_1) { Item_bool_func::Item_bool_func((Item_bool_func *)this,(Item_bool_func *)param_1); *(int ***)this = &PTR__Item_bool_func_args_geometry_geometry_01bcee88; *(int ***)(this + 0xa8) = &PTR__Item_bool_func_args_geometry_geometry_01bcf4f0; /* try { // try from 00eba25f to 00eba263 has its CatchHandler @ 00eba26c */ String::String((String *)(this + 0xb0),(String *)(param_1 + 0xb0)); return; }
56,898
str_to_TIME
eloqsql/libmariadb/libmariadb/ma_stmt_codec.c
int str_to_TIME(const char *str, size_t length, MYSQL_TIME *tm) { const char *p = str; const char *end = str + length; int is_time = 0; if (!p) goto error; while (p < end && isspace(*p)) p++; while (p < end && isspace(end[-1])) end--; if (end -p < 5) goto error; if (*p == '-') { tm->neg = 1; /* Only TIME can't be negative.*/ is_time = 1; p++; } else { int i; tm->neg = 0; /* Date parsing (in server) accepts leading zeroes, thus position of the delimiters is not fixed. Scan the string to find out what we need to parse. */ for (i = 1; p + i < end; i++) { if(p[i] == '-' || p [i] == ':') { is_time = p[i] == ':'; break; } } } if (is_time) { if (parse_time(p, end - p, &p, tm)) goto error; tm->year = tm->month = tm->day = 0; tm->time_type = MYSQL_TIMESTAMP_TIME; return 0; } if (parse_date(p, end - p, &p, tm)) goto error; if (p == end || p[0] != ' ') { tm->hour = tm->minute = tm->second = tm->second_part = 0; tm->time_type = MYSQL_TIMESTAMP_DATE; return 0; } /* Skip space. */ p++; if (parse_time(p, end - p, &p, tm)) goto error; /* In DATETIME, hours must be < 24.*/ if (tm->hour > 23) goto error; tm->time_type = MYSQL_TIMESTAMP_DATETIME; return 0; error: memset(tm, 0, sizeof(*tm)); tm->time_type = MYSQL_TIMESTAMP_ERROR; return 1; }
O3
c
str_to_TIME: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rdx, %r10 testq %rdi, %rdi je 0x27a16 movq %rsi, %r11 movq %rdi, %r15 movq %rdi, %rbx testq %rsi, %rsi movq %r10, -0x40(%rbp) movq %rsi, %r12 jle 0x278d3 leaq (%r15,%r11), %r14 callq 0x134d0 movq %r12, %r11 movq (%rax), %rax movq %r15, %rbx movsbq (%rbx), %rcx testb $0x20, 0x1(%rax,%rcx,2) je 0x278d3 incq %rbx cmpq %r14, %rbx jb 0x278c0 movq %rbx, -0x38(%rbp) movl $0x1, %eax subq %r15, %rax movq %rbx, %rcx subq %r15, %rcx movq %rax, %r13 movq %rcx, %r14 leaq (%r15,%r11), %rax movq %rax, -0x30(%rbp) cmpq %rax, %rbx jae 0x2791b callq 0x134d0 movq %r12, %r11 movq (%rax), %rdx movsbq -0x1(%r15,%r12), %rsi decq %r15 leaq 0x1(%r13), %rax leaq 0x1(%r14), %rcx testb $0x20, 0x1(%rdx,%rsi,2) jne 0x278e5 movq %r11, %rsi subq %r14, %rsi cmpq $0x5, %rsi movq -0x40(%rbp), %r10 jl 0x27a16 leaq 0x1(%rbx), %rdi cmpb $0x2d, (%rbx) jne 0x27980 movb $0x1, 0x20(%r10) movq %rdi, -0x38(%rbp) notq %r14 addq %r11, %r14 movq %r14, %rsi leaq -0x38(%rbp), %rdx movq %r10, %rcx callq 0x27c2b movq -0x40(%rbp), %r10 testl %eax, %eax jne 0x27a16 movl $0x0, 0x8(%r10) movq $0x0, (%r10) movl $0x2, 0x24(%r10) xorl %eax, %eax jmp 0x27a37 movb $0x0, 0x20(%r10) movq -0x30(%rbp), %r14 cmpq %r14, %rdi jae 0x279a4 movzbl (%rdi), %eax cmpl $0x2d, %eax je 0x279a4 cmpl $0x3a, %eax je 0x27aeb incq %rdi jmp 0x27989 movabsq $0x199999999999999a, %rcx # imm = 0x199999999999999A xorl %eax, %eax xorl %edx, %edx movsbq (%rbx,%rax), %rsi leal -0x30(%rsi), %edi cmpb $0xa, %dil setb %dil jae 0x27a00 cmpq %rcx, %rdx jae 0x27a00 leaq (%rdx,%rdx), %rdi leaq (%rdi,%rdi,4), %rdi movl $0x2f, %r8d subq %rsi, %r8 cmpq %r8, %rdi ja 0x279fd leaq (%rdi,%rsi), %rdx addq $-0x30, %rdx leaq (%rbx,%rax), %rsi incq %rsi incq %rax cmpq %r14, %rsi jb 0x279b2 addq %rbx, %rax xorl %esi, %esi jmp 0x27a0d movb $0x1, %dil testq %rax, %rax sete %sil orb %dil, %sil addq %rbx, %rax movq %rdx, %rdi shrq $0x20, %rdi je 0x27a46 xorps %xmm0, %xmm0 movups %xmm0, 0x10(%r10) movups %xmm0, (%r10) movq $0x0, 0x20(%r10) movl $0xffffffff, 0x24(%r10) # imm = 0xFFFFFFFF movl $0x1, %eax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl %edx, (%r10) cmpq $0x2710, %rdx # imm = 0x2710 setae %dil orb %dil, %sil jne 0x27a16 cmpq %rax, -0x30(%rbp) je 0x27a16 cmpb $0x2d, (%rax) jne 0x27a16 movq %rax, %rsi subq %rbx, %rsi cmpq $0x2, %rsi jne 0x27a86 leal 0x7d0(%rdx), %esi leal 0x76c(%rdx), %edi cmpq $0x46, %rdx cmovbl %esi, %edi movl %edi, (%r10) movq %r11, %rdx subq %rax, %rdx subq %r13, %rdx testq %rdx, %rdx jle 0x27a16 incq %rax xorl %esi, %esi xorl %edx, %edx movq -0x30(%rbp), %r14 movsbq (%rax,%rsi), %rdi leal -0x30(%rdi), %r8d cmpb $0xa, %r8b setb %r8b jae 0x27af6 cmpq %rcx, %rdx jae 0x27af6 leaq (%rdx,%rdx), %r8 leaq (%r8,%r8,4), %r8 movl $0x2f, %r9d subq %rdi, %r9 cmpq %r9, %r8 ja 0x27af3 leaq (%r8,%rdi), %rdx addq $-0x30, %rdx leaq (%rax,%rsi), %rdi incq %rdi incq %rsi cmpq %r14, %rdi jb 0x27a9f addq %rsi, %rax xorl %esi, %esi jmp 0x27b03 movq %rbx, %rdi jmp 0x2794a movb $0x1, %r8b addq %rsi, %rax testq %rsi, %rsi sete %sil orb %r8b, %sil movq %rdx, %rdi shrq $0x20, %rdi jne 0x27a16 movl %edx, 0x4(%r10) cmpq $0xd, %rdx setae %dl orb %dl, %sil jne 0x27a16 cmpq %rax, -0x30(%rbp) je 0x27a16 cmpb $0x2d, (%rax) jne 0x27a16 movq %r11, %rdx subq %rax, %rdx subq %r13, %rdx testq %rdx, %rdx jle 0x27a16 incq %rax xorl %esi, %esi xorl %edx, %edx movq -0x30(%rbp), %r14 movsbq (%rax,%rsi), %rdi leal -0x30(%rdi), %r8d cmpb $0xa, %r8b setb %r8b jae 0x27ba3 cmpq %rcx, %rdx jae 0x27ba3 leaq (%rdx,%rdx), %r8 leaq (%r8,%r8,4), %r8 movl $0x2f, %r9d subq %rdi, %r9 cmpq %r9, %r8 ja 0x27ba0 leaq (%r8,%rdi), %rdx addq $-0x30, %rdx leaq (%rax,%rsi), %rdi incq %rdi incq %rsi cmpq %r14, %rdi jb 0x27b54 addq %rsi, %rax xorl %ecx, %ecx jmp 0x27baf movb $0x1, %r8b addq %rsi, %rax testq %rsi, %rsi sete %cl orb %r8b, %cl movl %edx, 0x8(%r10) movq %rax, -0x38(%rbp) testb %cl, %cl jne 0x27a16 cmpq $0x1f, %rdx ja 0x27a16 cmpq %rax, -0x30(%rbp) je 0x27c14 cmpb $0x20, (%rax) jne 0x27c14 leaq 0x1(%rax), %rdi leaq -0x38(%rbp), %rdx movq %rdi, (%rdx) subq %rax, %r11 subq %r13, %r11 movq %r11, %rsi movq %r10, %rcx callq 0x27c2b movq -0x40(%rbp), %r10 testl %eax, %eax jne 0x27a16 cmpl $0x17, 0xc(%r10) ja 0x27a16 movl $0x1, 0x24(%r10) jmp 0x27979 xorl %eax, %eax movl %eax, 0x24(%r10) xorps %xmm0, %xmm0 movups %xmm0, 0xc(%r10) movl %eax, 0x1c(%r10) jmp 0x27a37
str_to_TIME: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov r10, rdx test rdi, rdi jz loc_27A16 mov r11, rsi mov r15, rdi mov rbx, rdi test rsi, rsi mov [rbp+var_40], r10 mov r12, rsi jle short loc_278D3 lea r14, [r15+r11] call ___ctype_b_loc mov r11, r12 mov rax, [rax] mov rbx, r15 loc_278C0: movsx rcx, byte ptr [rbx] test byte ptr [rax+rcx*2+1], 20h jz short loc_278D3 inc rbx cmp rbx, r14 jb short loc_278C0 loc_278D3: mov [rbp+var_38], rbx mov eax, 1 sub rax, r15 mov rcx, rbx sub rcx, r15 loc_278E5: mov r13, rax mov r14, rcx lea rax, [r15+r11] mov [rbp+var_30], rax cmp rbx, rax jnb short loc_2791B call ___ctype_b_loc mov r11, r12 mov rdx, [rax] movsx rsi, byte ptr [r15+r12-1] dec r15 lea rax, [r13+1] lea rcx, [r14+1] test byte ptr [rdx+rsi*2+1], 20h jnz short loc_278E5 loc_2791B: mov rsi, r11 sub rsi, r14 cmp rsi, 5 mov r10, [rbp+var_40] jl loc_27A16 lea rdi, [rbx+1] cmp byte ptr [rbx], 2Dh ; '-' jnz short loc_27980 mov byte ptr [r10+20h], 1 mov [rbp+var_38], rdi not r14 add r14, r11 mov rsi, r14 loc_2794A: lea rdx, [rbp+var_38] mov rcx, r10 call parse_time mov r10, [rbp+var_40] test eax, eax jnz loc_27A16 mov dword ptr [r10+8], 0 mov qword ptr [r10], 0 mov dword ptr [r10+24h], 2 loc_27979: xor eax, eax jmp loc_27A37 loc_27980: mov byte ptr [r10+20h], 0 mov r14, [rbp+var_30] loc_27989: cmp rdi, r14 jnb short loc_279A4 movzx eax, byte ptr [rdi] cmp eax, 2Dh ; '-' jz short loc_279A4 cmp eax, 3Ah ; ':' jz loc_27AEB inc rdi jmp short loc_27989 loc_279A4: mov rcx, 199999999999999Ah xor eax, eax xor edx, edx loc_279B2: movsx rsi, byte ptr [rbx+rax] lea edi, [rsi-30h] cmp dil, 0Ah setb dil jnb short loc_27A00 cmp rdx, rcx jnb short loc_27A00 lea rdi, [rdx+rdx] lea rdi, [rdi+rdi*4] mov r8d, 2Fh ; '/' sub r8, rsi cmp rdi, r8 ja short loc_279FD lea rdx, [rdi+rsi] add rdx, 0FFFFFFFFFFFFFFD0h lea rsi, [rbx+rax] inc rsi inc rax cmp rsi, r14 jb short loc_279B2 add rax, rbx xor esi, esi jmp short loc_27A0D loc_279FD: mov dil, 1 loc_27A00: test rax, rax setz sil or sil, dil add rax, rbx loc_27A0D: mov rdi, rdx shr rdi, 20h jz short loc_27A46 loc_27A16: xorps xmm0, xmm0 movups xmmword ptr [r10+10h], xmm0 movups xmmword ptr [r10], xmm0 mov qword ptr [r10+20h], 0 mov dword ptr [r10+24h], 0FFFFFFFFh mov eax, 1 loc_27A37: add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_27A46: mov [r10], edx cmp rdx, 2710h setnb dil or sil, dil jnz short loc_27A16 cmp [rbp+var_30], rax jz short loc_27A16 cmp byte ptr [rax], 2Dh ; '-' jnz short loc_27A16 mov rsi, rax sub rsi, rbx cmp rsi, 2 jnz short loc_27A86 lea esi, [rdx+7D0h] lea edi, [rdx+76Ch] cmp rdx, 46h ; 'F' cmovb edi, esi mov [r10], edi loc_27A86: mov rdx, r11 sub rdx, rax sub rdx, r13 test rdx, rdx jle short loc_27A16 inc rax xor esi, esi xor edx, edx mov r14, [rbp+var_30] loc_27A9F: movsx rdi, byte ptr [rax+rsi] lea r8d, [rdi-30h] cmp r8b, 0Ah setb r8b jnb short loc_27AF6 cmp rdx, rcx jnb short loc_27AF6 lea r8, [rdx+rdx] lea r8, [r8+r8*4] mov r9d, 2Fh ; '/' sub r9, rdi cmp r8, r9 ja short loc_27AF3 lea rdx, [r8+rdi] add rdx, 0FFFFFFFFFFFFFFD0h lea rdi, [rax+rsi] inc rdi inc rsi cmp rdi, r14 jb short loc_27A9F add rax, rsi xor esi, esi jmp short loc_27B03 loc_27AEB: mov rdi, rbx jmp loc_2794A loc_27AF3: mov r8b, 1 loc_27AF6: add rax, rsi test rsi, rsi setz sil or sil, r8b loc_27B03: mov rdi, rdx shr rdi, 20h jnz loc_27A16 mov [r10+4], edx cmp rdx, 0Dh setnb dl or sil, dl jnz loc_27A16 cmp [rbp+var_30], rax jz loc_27A16 cmp byte ptr [rax], 2Dh ; '-' jnz loc_27A16 mov rdx, r11 sub rdx, rax sub rdx, r13 test rdx, rdx jle loc_27A16 inc rax xor esi, esi xor edx, edx mov r14, [rbp+var_30] loc_27B54: movsx rdi, byte ptr [rax+rsi] lea r8d, [rdi-30h] cmp r8b, 0Ah setb r8b jnb short loc_27BA3 cmp rdx, rcx jnb short loc_27BA3 lea r8, [rdx+rdx] lea r8, [r8+r8*4] mov r9d, 2Fh ; '/' sub r9, rdi cmp r8, r9 ja short loc_27BA0 lea rdx, [r8+rdi] add rdx, 0FFFFFFFFFFFFFFD0h lea rdi, [rax+rsi] inc rdi inc rsi cmp rdi, r14 jb short loc_27B54 add rax, rsi xor ecx, ecx jmp short loc_27BAF loc_27BA0: mov r8b, 1 loc_27BA3: add rax, rsi test rsi, rsi setz cl or cl, r8b loc_27BAF: mov [r10+8], edx mov [rbp+var_38], rax test cl, cl jnz loc_27A16 cmp rdx, 1Fh ja loc_27A16 cmp [rbp+var_30], rax jz short loc_27C14 cmp byte ptr [rax], 20h ; ' ' jnz short loc_27C14 lea rdi, [rax+1] lea rdx, [rbp+var_38] mov [rdx], rdi sub r11, rax sub r11, r13 mov rsi, r11 mov rcx, r10 call parse_time mov r10, [rbp+var_40] test eax, eax jnz loc_27A16 cmp dword ptr [r10+0Ch], 17h ja loc_27A16 mov dword ptr [r10+24h], 1 jmp loc_27979 loc_27C14: xor eax, eax mov [r10+24h], eax xorps xmm0, xmm0 movups xmmword ptr [r10+0Ch], xmm0 mov [r10+1Ch], eax jmp loc_27A37
long long str_to_TIME(_BYTE *a1, long long a2, long long a3) { long long v3; // r10 long long v4; // r11 _BYTE *v5; // r15 unsigned __int8 *v6; // rbx long long *v8; // rax long long v9; // rax long long v10; // rax _BYTE *v11; // rcx long long v12; // r13 signed long long v13; // r14 long long *v14; // rax long long v15; // rdx long long v16; // rsi long long v17; // rsi unsigned __int8 *v18; // rdi int v19; // eax long long result; // rax int v21; // eax long long v22; // rax unsigned long long v23; // rdx long long v24; // rsi bool v25; // di unsigned long long v26; // rsi unsigned __int8 *v27; // rax bool v28; // si int v29; // edi _BYTE *v30; // rax long long v31; // rsi unsigned long long v32; // rdx long long v33; // rdi bool v34; // r8 unsigned long long v35; // rdi unsigned __int8 *v36; // rax bool v37; // si _BYTE *v38; // rax long long v39; // rsi unsigned long long v40; // rdx long long v41; // rdi bool v42; // r8 unsigned long long v43; // rdi unsigned __int8 *v44; // rax bool v45; // cl int v46; // eax unsigned __int8 *v48; // [rsp+8h] [rbp-38h] BYREF unsigned __int8 *v49; // [rsp+10h] [rbp-30h] v3 = a3; if ( !a1 ) goto LABEL_29; v4 = a2; v5 = a1; v6 = a1; if ( a2 > 0 ) { v8 = (long long *)__ctype_b_loc(); v4 = a2; v9 = *v8; v6 = a1; do { if ( (*(_BYTE *)(v9 + 2LL * (char)*v6 + 1) & 0x20) == 0 ) break; ++v6; } while ( v6 < &a1[a2] ); } v48 = v6; v10 = 1LL - (_QWORD)a1; v11 = (_BYTE *)(v6 - a1); do { v12 = v10; v13 = (signed long long)v11; v49 = &v5[v4]; if ( v6 >= &v5[v4] ) break; v14 = (long long *)__ctype_b_loc(); v4 = a2; v15 = *v14; v16 = (char)v5[a2 - 1]; --v5; v10 = v12 + 1; v11 = (_BYTE *)(v13 + 1); } while ( (*(_BYTE *)(v15 + 2 * v16 + 1) & 0x20) != 0 ); v17 = v4 - v13; v3 = a3; if ( v4 - v13 < 5 ) goto LABEL_29; v18 = v6 + 1; if ( *v6 == 45 ) { *(_BYTE *)(a3 + 32) = 1; v48 = v6 + 1; v17 = v4 + ~v13; LABEL_12: v19 = parse_time(v18, v17, &v48, a3); v3 = a3; if ( !v19 ) { *(_DWORD *)(a3 + 8) = 0; *(_QWORD *)a3 = 0LL; *(_DWORD *)(a3 + 36) = 2; return 0LL; } goto LABEL_29; } *(_BYTE *)(a3 + 32) = 0; while ( v18 < v49 ) { v21 = *v18; if ( v21 == 45 ) break; if ( v21 == 58 ) { v18 = v6; goto LABEL_12; } ++v18; } v22 = 0LL; v23 = 0LL; while ( 1 ) { v24 = (char)v6[v22]; v25 = (unsigned __int8)(v24 - 48) < 0xAu; if ( (unsigned __int8)(v24 - 48) >= 0xAu || v23 >= 0x199999999999999ALL ) break; if ( 10 * v23 > 47 - v24 ) { v25 = 1; break; } v23 = 10 * v23 + v24 - 48; v26 = (unsigned long long)&v6[++v22]; if ( v26 >= (unsigned long long)v49 ) { v27 = &v6[v22]; v28 = 0; goto LABEL_28; } } v28 = v25 || v22 == 0; v27 = &v6[v22]; LABEL_28: if ( HIDWORD(v23) ) goto LABEL_29; *(_DWORD *)a3 = v23; if ( v23 >= 0x2710 || v28 || v49 == v27 || *v27 != 45 ) goto LABEL_29; if ( v27 - v6 == 2 ) { v29 = v23 + 1900; if ( v23 < 0x46 ) v29 = v23 + 2000; *(_DWORD *)a3 = v29; } if ( v4 - (long long)v27 - v12 <= 0 ) goto LABEL_29; v30 = v27 + 1; v31 = 0LL; v32 = 0LL; while ( 1 ) { v33 = (char)v30[v31]; v34 = (unsigned __int8)(v33 - 48) < 0xAu; if ( (unsigned __int8)(v33 - 48) >= 0xAu || v32 >= 0x199999999999999ALL ) break; if ( 10 * v32 > 47 - v33 ) { v34 = 1; break; } v32 = 10 * v32 + v33 - 48; v35 = (unsigned long long)&v30[++v31]; if ( v35 >= (unsigned long long)v49 ) { v36 = &v30[v31]; v37 = 0; goto LABEL_47; } } v36 = &v30[v31]; v37 = v34 || v31 == 0; LABEL_47: if ( HIDWORD(v32) ) goto LABEL_29; *(_DWORD *)(a3 + 4) = v32; if ( v32 >= 0xD || v37 || v49 == v36 || *v36 != 45 || v4 - (long long)v36 - v12 <= 0 ) goto LABEL_29; v38 = v36 + 1; v39 = 0LL; v40 = 0LL; while ( 1 ) { v41 = (char)v38[v39]; v42 = (unsigned __int8)(v41 - 48) < 0xAu; if ( (unsigned __int8)(v41 - 48) >= 0xAu || v40 >= 0x199999999999999ALL ) break; if ( 10 * v40 > 47 - v41 ) { v42 = 1; break; } v40 = 10 * v40 + v41 - 48; v43 = (unsigned long long)&v38[++v39]; if ( v43 >= (unsigned long long)v49 ) { v44 = &v38[v39]; v45 = 0; goto LABEL_60; } } v44 = &v38[v39]; v45 = v42 || v39 == 0; LABEL_60: *(_DWORD *)(a3 + 8) = v40; v48 = v44; if ( v45 || v40 > 0x1F ) { LABEL_29: *(_OWORD *)(v3 + 16) = 0LL; *(_OWORD *)v3 = 0LL; *(_QWORD *)(v3 + 32) = 0LL; *(_DWORD *)(v3 + 36) = -1; return 1LL; } if ( v49 != v44 && *v44 == 32 ) { v48 = v44 + 1; v46 = parse_time(v44 + 1, v4 - (_QWORD)v44 - v12, &v48, a3); v3 = a3; if ( !v46 && *(_DWORD *)(a3 + 12) <= 0x17u ) { *(_DWORD *)(a3 + 36) = 1; return 0LL; } goto LABEL_29; } result = 0LL; *(_DWORD *)(a3 + 36) = 0; *(_OWORD *)(a3 + 12) = 0LL; *(_DWORD *)(a3 + 28) = 0; return result; }
str_to_TIME: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV R10,RDX TEST RDI,RDI JZ 0x00127a16 MOV R11,RSI MOV R15,RDI MOV RBX,RDI TEST RSI,RSI MOV qword ptr [RBP + -0x40],R10 MOV R12,RSI JLE 0x001278d3 LEA R14,[R15 + R11*0x1] CALL 0x001134d0 MOV R11,R12 MOV RAX,qword ptr [RAX] MOV RBX,R15 LAB_001278c0: MOVSX RCX,byte ptr [RBX] TEST byte ptr [RAX + RCX*0x2 + 0x1],0x20 JZ 0x001278d3 INC RBX CMP RBX,R14 JC 0x001278c0 LAB_001278d3: MOV qword ptr [RBP + -0x38],RBX MOV EAX,0x1 SUB RAX,R15 MOV RCX,RBX SUB RCX,R15 LAB_001278e5: MOV R13,RAX MOV R14,RCX LEA RAX,[R15 + R11*0x1] MOV qword ptr [RBP + -0x30],RAX CMP RBX,RAX JNC 0x0012791b CALL 0x001134d0 MOV R11,R12 MOV RDX,qword ptr [RAX] MOVSX RSI,byte ptr [R15 + R12*0x1 + -0x1] DEC R15 LEA RAX,[R13 + 0x1] LEA RCX,[R14 + 0x1] TEST byte ptr [RDX + RSI*0x2 + 0x1],0x20 JNZ 0x001278e5 LAB_0012791b: MOV RSI,R11 SUB RSI,R14 CMP RSI,0x5 MOV R10,qword ptr [RBP + -0x40] JL 0x00127a16 LEA RDI,[RBX + 0x1] CMP byte ptr [RBX],0x2d JNZ 0x00127980 MOV byte ptr [R10 + 0x20],0x1 MOV qword ptr [RBP + -0x38],RDI NOT R14 ADD R14,R11 MOV RSI,R14 LAB_0012794a: LEA RDX,[RBP + -0x38] MOV RCX,R10 CALL 0x00127c2b MOV R10,qword ptr [RBP + -0x40] TEST EAX,EAX JNZ 0x00127a16 MOV dword ptr [R10 + 0x8],0x0 MOV qword ptr [R10],0x0 MOV dword ptr [R10 + 0x24],0x2 LAB_00127979: XOR EAX,EAX JMP 0x00127a37 LAB_00127980: MOV byte ptr [R10 + 0x20],0x0 MOV R14,qword ptr [RBP + -0x30] LAB_00127989: CMP RDI,R14 JNC 0x001279a4 MOVZX EAX,byte ptr [RDI] CMP EAX,0x2d JZ 0x001279a4 CMP EAX,0x3a JZ 0x00127aeb INC RDI JMP 0x00127989 LAB_001279a4: MOV RCX,0x199999999999999a XOR EAX,EAX XOR EDX,EDX LAB_001279b2: MOVSX RSI,byte ptr [RBX + RAX*0x1] LEA EDI,[RSI + -0x30] CMP DIL,0xa SETC DIL JNC 0x00127a00 CMP RDX,RCX JNC 0x00127a00 LEA RDI,[RDX + RDX*0x1] LEA RDI,[RDI + RDI*0x4] MOV R8D,0x2f SUB R8,RSI CMP RDI,R8 JA 0x001279fd LEA RDX,[RDI + RSI*0x1] ADD RDX,-0x30 LEA RSI,[RBX + RAX*0x1] INC RSI INC RAX CMP RSI,R14 JC 0x001279b2 ADD RAX,RBX XOR ESI,ESI JMP 0x00127a0d LAB_001279fd: MOV DIL,0x1 LAB_00127a00: TEST RAX,RAX SETZ SIL OR SIL,DIL ADD RAX,RBX LAB_00127a0d: MOV RDI,RDX SHR RDI,0x20 JZ 0x00127a46 LAB_00127a16: XORPS XMM0,XMM0 MOVUPS xmmword ptr [R10 + 0x10],XMM0 MOVUPS xmmword ptr [R10],XMM0 MOV qword ptr [R10 + 0x20],0x0 MOV dword ptr [R10 + 0x24],0xffffffff MOV EAX,0x1 LAB_00127a37: ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00127a46: MOV dword ptr [R10],EDX CMP RDX,0x2710 SETNC DIL OR SIL,DIL JNZ 0x00127a16 CMP qword ptr [RBP + -0x30],RAX JZ 0x00127a16 CMP byte ptr [RAX],0x2d JNZ 0x00127a16 MOV RSI,RAX SUB RSI,RBX CMP RSI,0x2 JNZ 0x00127a86 LEA ESI,[RDX + 0x7d0] LEA EDI,[RDX + 0x76c] CMP RDX,0x46 CMOVC EDI,ESI MOV dword ptr [R10],EDI LAB_00127a86: MOV RDX,R11 SUB RDX,RAX SUB RDX,R13 TEST RDX,RDX JLE 0x00127a16 INC RAX XOR ESI,ESI XOR EDX,EDX MOV R14,qword ptr [RBP + -0x30] LAB_00127a9f: MOVSX RDI,byte ptr [RAX + RSI*0x1] LEA R8D,[RDI + -0x30] CMP R8B,0xa SETC R8B JNC 0x00127af6 CMP RDX,RCX JNC 0x00127af6 LEA R8,[RDX + RDX*0x1] LEA R8,[R8 + R8*0x4] MOV R9D,0x2f SUB R9,RDI CMP R8,R9 JA 0x00127af3 LEA RDX,[R8 + RDI*0x1] ADD RDX,-0x30 LEA RDI,[RAX + RSI*0x1] INC RDI INC RSI CMP RDI,R14 JC 0x00127a9f ADD RAX,RSI XOR ESI,ESI JMP 0x00127b03 LAB_00127aeb: MOV RDI,RBX JMP 0x0012794a LAB_00127af3: MOV R8B,0x1 LAB_00127af6: ADD RAX,RSI TEST RSI,RSI SETZ SIL OR SIL,R8B LAB_00127b03: MOV RDI,RDX SHR RDI,0x20 JNZ 0x00127a16 MOV dword ptr [R10 + 0x4],EDX CMP RDX,0xd SETNC DL OR SIL,DL JNZ 0x00127a16 CMP qword ptr [RBP + -0x30],RAX JZ 0x00127a16 CMP byte ptr [RAX],0x2d JNZ 0x00127a16 MOV RDX,R11 SUB RDX,RAX SUB RDX,R13 TEST RDX,RDX JLE 0x00127a16 INC RAX XOR ESI,ESI XOR EDX,EDX MOV R14,qword ptr [RBP + -0x30] LAB_00127b54: MOVSX RDI,byte ptr [RAX + RSI*0x1] LEA R8D,[RDI + -0x30] CMP R8B,0xa SETC R8B JNC 0x00127ba3 CMP RDX,RCX JNC 0x00127ba3 LEA R8,[RDX + RDX*0x1] LEA R8,[R8 + R8*0x4] MOV R9D,0x2f SUB R9,RDI CMP R8,R9 JA 0x00127ba0 LEA RDX,[R8 + RDI*0x1] ADD RDX,-0x30 LEA RDI,[RAX + RSI*0x1] INC RDI INC RSI CMP RDI,R14 JC 0x00127b54 ADD RAX,RSI XOR ECX,ECX JMP 0x00127baf LAB_00127ba0: MOV R8B,0x1 LAB_00127ba3: ADD RAX,RSI TEST RSI,RSI SETZ CL OR CL,R8B LAB_00127baf: MOV dword ptr [R10 + 0x8],EDX MOV qword ptr [RBP + -0x38],RAX TEST CL,CL JNZ 0x00127a16 CMP RDX,0x1f JA 0x00127a16 CMP qword ptr [RBP + -0x30],RAX JZ 0x00127c14 CMP byte ptr [RAX],0x20 JNZ 0x00127c14 LEA RDI,[RAX + 0x1] LEA RDX,[RBP + -0x38] MOV qword ptr [RDX],RDI SUB R11,RAX SUB R11,R13 MOV RSI,R11 MOV RCX,R10 CALL 0x00127c2b MOV R10,qword ptr [RBP + -0x40] TEST EAX,EAX JNZ 0x00127a16 CMP dword ptr [R10 + 0xc],0x17 JA 0x00127a16 MOV dword ptr [R10 + 0x24],0x1 JMP 0x00127979 LAB_00127c14: XOR EAX,EAX MOV dword ptr [R10 + 0x24],EAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [R10 + 0xc],XMM0 MOV dword ptr [R10 + 0x1c],EAX JMP 0x00127a37
int8 str_to_TIME(char *param_1,long param_2,int *param_3) { char cVar1; long lVar2; int iVar3; ushort **ppuVar4; long lVar5; ulong uVar6; ulong uVar7; char *pcVar8; long lVar9; int iVar10; char *pcVar11; bool bVar12; char *local_40; char *local_38; if (param_1 != (char *)0x0) { pcVar8 = param_1; if (0 < param_2) { ppuVar4 = __ctype_b_loc(); do { if ((*(byte *)((long)*ppuVar4 + (long)*pcVar8 * 2 + 1) & 0x20) == 0) break; pcVar8 = pcVar8 + 1; } while (pcVar8 < param_1 + param_2); } lVar5 = -(long)param_1; uVar7 = (long)pcVar8 - (long)param_1; local_40 = pcVar8; do { uVar6 = uVar7; lVar5 = lVar5 + 1; local_38 = param_1 + param_2; if (local_38 <= pcVar8) break; ppuVar4 = __ctype_b_loc(); pcVar11 = param_1 + param_2 + -1; param_1 = param_1 + -1; uVar7 = uVar6 + 1; } while ((*(byte *)((long)*ppuVar4 + (long)*pcVar11 * 2 + 1) & 0x20) != 0); lVar9 = param_2 - uVar6; if (4 < lVar9) { pcVar11 = pcVar8 + 1; if (*pcVar8 == '-') { *(int1 *)(param_3 + 8) = 1; lVar9 = ~uVar6 + param_2; pcVar8 = pcVar11; local_40 = pcVar11; LAB_0012794a: iVar3 = parse_time(pcVar8,lVar9,&local_40,param_3); if (iVar3 == 0) { param_3[2] = 0; param_3[0] = 0; param_3[1] = 0; param_3[9] = 2; return 0; } } else { *(int1 *)(param_3 + 8) = 0; for (; (pcVar11 < local_38 && (*pcVar11 != '-')); pcVar11 = pcVar11 + 1) { if (*pcVar11 == ':') goto LAB_0012794a; } lVar9 = 0; uVar7 = 0; do { cVar1 = pcVar8[lVar9]; bVar12 = (byte)(cVar1 - 0x30U) < 10; if ((!bVar12) || (0x1999999999999999 < uVar7)) { LAB_00127a00: bVar12 = (bool)(lVar9 == 0 | bVar12); goto LAB_00127a0d; } if (0x2fU - (long)cVar1 < uVar7 * 10) { bVar12 = true; goto LAB_00127a00; } uVar7 = (uVar7 * 10 + (long)cVar1) - 0x30; lVar2 = lVar9 + 1; lVar9 = lVar9 + 1; } while (pcVar8 + lVar2 < local_38); bVar12 = false; LAB_00127a0d: pcVar11 = pcVar8 + lVar9; if (uVar7 >> 0x20 == 0) { iVar3 = (int)uVar7; *param_3 = iVar3; if (((!bVar12 && uVar7 < 10000) && (local_38 != pcVar11)) && (*pcVar11 == '-')) { if ((long)pcVar11 - (long)pcVar8 == 2) { iVar10 = iVar3 + 0x76c; if (uVar7 < 0x46) { iVar10 = iVar3 + 2000; } *param_3 = iVar10; } if (param_2 - (long)pcVar11 != lVar5 && -1 < (param_2 - (long)pcVar11) - lVar5) { lVar9 = 0; uVar7 = 0; do { cVar1 = pcVar11[lVar9 + 1]; bVar12 = (byte)(cVar1 - 0x30U) < 10; if ((!bVar12) || (0x1999999999999999 < uVar7)) { LAB_00127af6: bVar12 = (bool)(lVar9 == 0 | bVar12); goto LAB_00127b03; } if (0x2fU - (long)cVar1 < uVar7 * 10) { bVar12 = true; goto LAB_00127af6; } uVar7 = (uVar7 * 10 + (long)cVar1) - 0x30; lVar2 = lVar9 + 2; lVar9 = lVar9 + 1; } while (pcVar11 + lVar2 < local_38); bVar12 = false; LAB_00127b03: pcVar11 = pcVar11 + lVar9 + 1; if (((uVar7 >> 0x20 == 0) && (param_3[1] = (int)uVar7, !bVar12 && uVar7 < 0xd)) && ((local_38 != pcVar11 && ((*pcVar11 == '-' && (param_2 - (long)pcVar11 != lVar5 && -1 < (param_2 - (long)pcVar11) - lVar5)))))) { lVar9 = 0; uVar7 = 0; do { cVar1 = pcVar11[lVar9 + 1]; bVar12 = (byte)(cVar1 - 0x30U) < 10; if ((!bVar12) || (0x1999999999999999 < uVar7)) { LAB_00127ba3: bVar12 = (bool)(lVar9 == 0 | bVar12); goto LAB_00127baf; } if (0x2fU - (long)cVar1 < uVar7 * 10) { bVar12 = true; goto LAB_00127ba3; } uVar7 = (uVar7 * 10 + (long)cVar1) - 0x30; lVar2 = lVar9 + 2; lVar9 = lVar9 + 1; } while (pcVar11 + lVar2 < local_38); bVar12 = false; LAB_00127baf: pcVar11 = pcVar11 + lVar9 + 1; param_3[2] = (int)uVar7; if ((!bVar12) && (uVar7 < 0x20)) { if ((local_38 == pcVar11) || (*pcVar11 != ' ')) { param_3[9] = 0; param_3[3] = 0; param_3[4] = 0; param_3[5] = 0; param_3[6] = 0; param_3[7] = 0; return 0; } local_40 = pcVar11 + 1; iVar3 = parse_time(local_40,(param_2 - (long)pcVar11) - lVar5,&local_40,param_3); if ((iVar3 == 0) && ((uint)param_3[3] < 0x18)) { param_3[9] = 1; return 0; } } } } } } } } } param_3[4] = 0; param_3[5] = 0; param_3[6] = 0; param_3[7] = 0; param_3[0] = 0; param_3[1] = 0; param_3[2] = 0; param_3[3] = 0; param_3[8] = 0; param_3[9] = 0; param_3[9] = -1; return 1; }
56,899
LefDefParser::lefwLayerRoutingSpacingEOLParallel(double, double, int)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp
int lefwLayerRoutingSpacingEOLParallel(double parSpace, double parWithin, int twoEdges) { if (!lefwHasLayerRoutingEol) return LEFW_BAD_DATA;// EndOfLine in not defined if (lefwWriteEncrypt) { if (twoEdges) encPrint(lefwFile, (char*) " PARALLELEDGE %.11g WITHIN %.11g TWOEDGES ;\n", parSpace, parWithin); else encPrint(lefwFile, (char*) " PARALLELEDGE %.11g WITHIN %.11g ;\n", parSpace, parWithin); } else { if (twoEdges) fprintf(lefwFile, " PARALLELEDGE %.11g WITHIN %.11g TWOEDGES ;\n", parSpace, parWithin); else fprintf(lefwFile, " PARALLELEDGE %.11g WITHIN %.11g ;\n", parSpace, parWithin); } lefwLines++; lefwHasLayerRoutingEol = 0; return LEFW_OK; }
O3
cpp
LefDefParser::lefwLayerRoutingSpacingEOLParallel(double, double, int): movl $0x3, %eax cmpb $0x1, 0x79b57(%rip) # 0x8d3f0 jne 0x138ff pushq %rax movl %edi, %ecx leaq 0x7984b(%rip), %rax # 0x8d0f0 movq (%rax), %rdi cmpb $0x1, 0x79b2d(%rip) # 0x8d3dc jne 0x138be testl %ecx, %ecx je 0x138cb leaq 0x476ca(%rip), %rsi # 0x5af86 jmp 0x138d2 testl %ecx, %ecx je 0x138db leaq 0x476bd(%rip), %rsi # 0x5af86 jmp 0x138e2 leaq 0x476e5(%rip), %rsi # 0x5afb7 movb $0x2, %al callq 0x55afd jmp 0x138e9 leaq 0x476d5(%rip), %rsi # 0x5afb7 movb $0x2, %al callq 0x22e0 leaq 0x79a4c(%rip), %rax # 0x8d33c incl (%rax) movb $0x0, 0x79af7(%rip) # 0x8d3f0 xorl %eax, %eax addq $0x8, %rsp retq
_ZN12LefDefParser34lefwLayerRoutingSpacingEOLParallelEddi: mov eax, 3 cmp cs:_ZN12LefDefParserL22lefwHasLayerRoutingEolE, 1; LefDefParser::lefwHasLayerRoutingEol jnz short locret_138FF push rax mov ecx, edi lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 1; LefDefParser::lefwWriteEncrypt jnz short loc_138BE test ecx, ecx jz short loc_138CB lea rsi, aParalleledge11; " PARALLELEDGE %.11g WITHIN %.11g TW"... jmp short loc_138D2 loc_138BE: test ecx, ecx jz short loc_138DB lea rsi, aParalleledge11; " PARALLELEDGE %.11g WITHIN %.11g TW"... jmp short loc_138E2 loc_138CB: lea rsi, aParalleledge11_0; " PARALLELEDGE %.11g WITHIN %.11g ;"... loc_138D2: mov al, 2 call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...) jmp short loc_138E9 loc_138DB: lea rsi, aParalleledge11_0; " PARALLELEDGE %.11g WITHIN %.11g ;"... loc_138E2: mov al, 2 call _fprintf loc_138E9: lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines inc dword ptr [rax] mov cs:_ZN12LefDefParserL22lefwHasLayerRoutingEolE, 0; LefDefParser::lefwHasLayerRoutingEol xor eax, eax add rsp, 8 locret_138FF: retn
long long LefDefParser::lefwLayerRoutingSpacingEOLParallel( LefDefParser *this, double a2, double a3, int a4, int a5, long long a6, int a7, int a8) { long long result; // rax const char *v9; // rsi result = 3LL; if ( LefDefParser::lefwHasLayerRoutingEol == 1 ) { if ( LefDefParser::lefwWriteEncrypt == 1 ) { if ( (_DWORD)this ) v9 = " PARALLELEDGE %.11g WITHIN %.11g TWOEDGES ;\n"; else v9 = " PARALLELEDGE %.11g WITHIN %.11g ;\n"; LefDefParser::encPrint(LefDefParser::lefwFile, (_DWORD)v9, a5, (_DWORD)this, a7, a8); } else if ( (_DWORD)this ) { fprintf(*(_QWORD *)&LefDefParser::lefwFile, " PARALLELEDGE %.11g WITHIN %.11g TWOEDGES ;\n", a2, a3); } else { fprintf(*(_QWORD *)&LefDefParser::lefwFile, " PARALLELEDGE %.11g WITHIN %.11g ;\n", a2, a3); } ++LefDefParser::lefwLines; LefDefParser::lefwHasLayerRoutingEol = 0; return 0LL; } return result; }
lefwLayerRoutingSpacingEOLParallel: MOV EAX,0x3 CMP byte ptr [0x0018d3f0],0x1 JNZ 0x001138ff PUSH RAX MOV ECX,EDI LEA RAX,[0x18d0f0] MOV RDI,qword ptr [RAX] CMP byte ptr [0x0018d3dc],0x1 JNZ 0x001138be TEST ECX,ECX JZ 0x001138cb LEA RSI,[0x15af86] JMP 0x001138d2 LAB_001138be: TEST ECX,ECX JZ 0x001138db LEA RSI,[0x15af86] JMP 0x001138e2 LAB_001138cb: LEA RSI,[0x15afb7] LAB_001138d2: MOV AL,0x2 CALL 0x00155afd JMP 0x001138e9 LAB_001138db: LEA RSI,[0x15afb7] LAB_001138e2: MOV AL,0x2 CALL 0x001022e0 LAB_001138e9: LEA RAX,[0x18d33c] INC dword ptr [RAX] MOV byte ptr [0x0018d3f0],0x0 XOR EAX,EAX ADD RSP,0x8 LAB_001138ff: RET
/* LefDefParser::lefwLayerRoutingSpacingEOLParallel(double, double, int) */ int8 LefDefParser::lefwLayerRoutingSpacingEOLParallel(double param_1,double param_2,int param_3) { int8 uVar1; char *pcVar2; uVar1 = 3; if (lefwHasLayerRoutingEol == '\x01') { if (lefwWriteEncrypt == '\x01') { if (param_3 == 0) { pcVar2 = " PARALLELEDGE %.11g WITHIN %.11g ;\n"; } else { pcVar2 = " PARALLELEDGE %.11g WITHIN %.11g TWOEDGES ;\n"; } encPrint(lefwFile,pcVar2); } else { if (param_3 == 0) { pcVar2 = " PARALLELEDGE %.11g WITHIN %.11g ;\n"; } else { pcVar2 = " PARALLELEDGE %.11g WITHIN %.11g TWOEDGES ;\n"; } fprintf(lefwFile,pcVar2); } lefwLines = lefwLines + 1; lefwHasLayerRoutingEol = '\0'; uVar1 = 0; } return uVar1; }