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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
55,500 | ma_field_extension_init_type_info | eloqsql/libmariadb/libmariadb/mariadb_lib.c | static void ma_field_extension_init_type_info(MA_MEM_ROOT *memroot,
MA_FIELD_EXTENSION *ext,
const char *ptr, size_t length)
{
const char *end= ptr + length;
for ( ; ptr < end; )
{
uint itype= (uchar) *ptr++;
uint len= (uchar) *ptr++;
if (ptr + len > end || len > 127)
break; /*Badly encoded data*/
if (itype <= 127 && itype <= MARIADB_FIELD_ATTR_LAST)
ext->metadata[itype]= ma_const_string_copy_root(memroot, ptr, len);
ptr+= len;
}
} | O0 | c | ma_field_extension_init_type_info:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x18(%rbp), %rax
addq -0x20(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
cmpq -0x28(%rbp), %rax
jae 0x1e367
movq -0x18(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x18(%rbp)
movzbl (%rax), %eax
movl %eax, -0x2c(%rbp)
movq -0x18(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x18(%rbp)
movzbl (%rax), %eax
movl %eax, -0x30(%rbp)
movq -0x18(%rbp), %rax
movl -0x30(%rbp), %ecx
addq %rcx, %rax
cmpq -0x28(%rbp), %rax
ja 0x1e302
cmpl $0x7f, -0x30(%rbp)
jbe 0x1e304
jmp 0x1e367
cmpl $0x7f, -0x2c(%rbp)
ja 0x1e352
cmpl $0x1, -0x2c(%rbp)
ja 0x1e352
movq -0x10(%rbp), %rax
movl -0x2c(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x48(%rbp)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
movl -0x30(%rbp), %eax
movl %eax, %edx
callq 0x1dd90
movq %rax, %rcx
movq -0x48(%rbp), %rax
movq %rcx, -0x40(%rbp)
movq %rdx, -0x38(%rbp)
movq -0x40(%rbp), %rcx
movq %rcx, (%rax)
movq -0x38(%rbp), %rcx
movq %rcx, 0x8(%rax)
movl -0x30(%rbp), %ecx
movq -0x18(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
jmp 0x1e2b4
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax)
| ma_field_extension_init_type_info:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rax, [rbp+var_18]
add rax, [rbp+var_20]
mov [rbp+var_28], rax
loc_1E2B4:
mov rax, [rbp+var_18]
cmp rax, [rbp+var_28]
jnb loc_1E367
mov rax, [rbp+var_18]
mov rcx, rax
add rcx, 1
mov [rbp+var_18], rcx
movzx eax, byte ptr [rax]
mov [rbp+var_2C], eax
mov rax, [rbp+var_18]
mov rcx, rax
add rcx, 1
mov [rbp+var_18], rcx
movzx eax, byte ptr [rax]
mov [rbp+var_30], eax
mov rax, [rbp+var_18]
mov ecx, [rbp+var_30]
add rax, rcx
cmp rax, [rbp+var_28]
ja short loc_1E302
cmp [rbp+var_30], 7Fh
jbe short loc_1E304
loc_1E302:
jmp short loc_1E367
loc_1E304:
cmp [rbp+var_2C], 7Fh
ja short loc_1E352
cmp [rbp+var_2C], 1
ja short loc_1E352
mov rax, [rbp+var_10]
mov ecx, [rbp+var_2C]
shl rcx, 4
add rax, rcx
mov [rbp+var_48], rax
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_18]
mov eax, [rbp+var_30]
mov edx, eax
call ma_const_string_copy_root
mov rcx, rax
mov rax, [rbp+var_48]
mov [rbp+var_40], rcx
mov [rbp+var_38], rdx
mov rcx, [rbp+var_40]
mov [rax], rcx
mov rcx, [rbp+var_38]
mov [rax+8], rcx
loc_1E352:
mov ecx, [rbp+var_30]
mov rax, [rbp+var_18]
mov ecx, ecx
add rax, rcx
mov [rbp+var_18], rax
jmp loc_1E2B4
loc_1E367:
add rsp, 50h
pop rbp
retn
| unsigned __int8 * ma_field_extension_init_type_info(long long a1, long long a2, unsigned __int8 *a3, long long a4)
{
unsigned __int8 *result; // rax
unsigned __int8 *v5; // rax
long long v6; // rdx
long long *v7; // [rsp+8h] [rbp-48h]
unsigned int v8; // [rsp+20h] [rbp-30h]
unsigned int v9; // [rsp+24h] [rbp-2Ch]
unsigned long long v10; // [rsp+28h] [rbp-28h]
unsigned __int8 *v11; // [rsp+38h] [rbp-18h]
long long v12; // [rsp+38h] [rbp-18h]
v11 = a3;
v10 = (unsigned long long)&a3[a4];
while ( 1 )
{
result = v11;
if ( (unsigned long long)v11 >= v10 )
break;
v9 = *v11;
v5 = v11 + 1;
v12 = (long long)(v11 + 2);
v8 = *v5;
result = (unsigned __int8 *)(*v5 + v12);
if ( (unsigned long long)result > v10 || v8 > 0x7F )
break;
if ( v9 <= 1 )
{
v7 = (long long *)(16LL * v9 + a2);
*v7 = ma_const_string_copy_root(a1, v12, v8);
v7[1] = v6;
}
v11 = (unsigned __int8 *)(v8 + v12);
}
return result;
}
| ma_field_extension_init_type_info:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
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 + -0x18]
ADD RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x28],RAX
LAB_0011e2b4:
MOV RAX,qword ptr [RBP + -0x18]
CMP RAX,qword ptr [RBP + -0x28]
JNC 0x0011e367
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,RAX
ADD RCX,0x1
MOV qword ptr [RBP + -0x18],RCX
MOVZX EAX,byte ptr [RAX]
MOV dword ptr [RBP + -0x2c],EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,RAX
ADD RCX,0x1
MOV qword ptr [RBP + -0x18],RCX
MOVZX EAX,byte ptr [RAX]
MOV dword ptr [RBP + -0x30],EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0x30]
ADD RAX,RCX
CMP RAX,qword ptr [RBP + -0x28]
JA 0x0011e302
CMP dword ptr [RBP + -0x30],0x7f
JBE 0x0011e304
LAB_0011e302:
JMP 0x0011e367
LAB_0011e304:
CMP dword ptr [RBP + -0x2c],0x7f
JA 0x0011e352
CMP dword ptr [RBP + -0x2c],0x1
JA 0x0011e352
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x2c]
SHL RCX,0x4
ADD RAX,RCX
MOV qword ptr [RBP + -0x48],RAX
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RBP + -0x30]
MOV EDX,EAX
CALL 0x0011dd90
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RBP + -0x40],RCX
MOV qword ptr [RBP + -0x38],RDX
MOV RCX,qword ptr [RBP + -0x40]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX + 0x8],RCX
LAB_0011e352:
MOV ECX,dword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
JMP 0x0011e2b4
LAB_0011e367:
ADD RSP,0x50
POP RBP
RET
|
void ma_field_extension_init_type_info(int8 param_1,long param_2,byte *param_3,long param_4)
{
uint uVar1;
uint uVar2;
byte *pbVar3;
int1 auVar4 [16];
byte *local_20;
local_20 = param_3;
while( true ) {
if (param_3 + param_4 <= local_20) {
return;
}
uVar1 = (uint)*local_20;
pbVar3 = local_20 + 2;
uVar2 = (uint)local_20[1];
if (param_3 + param_4 < pbVar3 + uVar2) break;
if (0x7f < uVar2) {
return;
}
if ((uVar1 < 0x80) && (uVar1 < 2)) {
auVar4 = ma_const_string_copy_root(param_1,pbVar3,uVar2);
*(int1 (*) [16])(param_2 + (ulong)uVar1 * 0x10) = auVar4;
}
local_20 = pbVar3 + uVar2;
}
return;
}
| |
55,501 | exit_status | eloqsql/unittest/mytap/tap.c | int exit_status()
{
char buff[60];
/*
If there were no plan, we write one last instead.
*/
if (g_test.plan == NO_PLAN)
plan(g_test.last);
if (g_test.plan != g_test.last)
{
diag("%d tests planned but%s %d executed",
g_test.plan, (g_test.plan > g_test.last ? " only" : ""), g_test.last);
return EXIT_FAILURE;
}
if (g_test.failed > 0)
{
diag("Failed %d tests!", g_test.failed);
return EXIT_FAILURE;
}
if (start_time)
{
end_timer(start_time, buff);
printf("Test took %s\n", buff);
fflush(stdout);
}
return EXIT_SUCCESS;
} | O3 | c | exit_status:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %fs:0x28, %rax
movq %rax, -0x18(%rbp)
movl 0xb6e247(%rip), %esi # 0xbffa10
testl %esi, %esi
jne 0x917de
movl 0xb6e241(%rip), %edi # 0xbffa14
callq 0x911bb
movl 0xb6e232(%rip), %esi # 0xbffa10
movl 0xb6e230(%rip), %ecx # 0xbffa14
cmpl %ecx, %esi
jne 0x91802
movl 0xb6e22a(%rip), %esi # 0xbffa18
testl %esi, %esi
jle 0x91845
leaq 0x4a793(%rip), %rdi # 0xdbf8c
xorl %eax, %eax
callq 0x910e7
jmp 0x91822
leaq 0x4ed72(%rip), %rax # 0xe057b
leaq 0x4e609(%rip), %rdx # 0xdfe19
cmovgq %rax, %rdx
leaq 0x4a74e(%rip), %rdi # 0xdbf69
xorl %eax, %eax
callq 0x910e7
movl $0x1, %ebx
movq %fs:0x28, %rax
cmpq -0x18(%rbp), %rax
jne 0x91adc
movl %ebx, %eax
addq $0x60, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq 0xb6e254(%rip), %r14 # 0xbffaa0
testq %r14, %r14
je 0x91ad5
leaq -0x60(%rbp), %rbx
movq %rbx, %rdi
callq 0x29170
subq %r14, %rax
movq %rax, %xmm0
punpckldq 0x4785f(%rip), %xmm0 # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1]
subpd 0x47867(%rip), %xmm0 # 0xd90e0
movapd %xmm0, %xmm1
unpckhpd %xmm0, %xmm1 # xmm1 = xmm1[1],xmm0[1]
addsd %xmm0, %xmm1
movapd %xmm1, -0x70(%rbp)
movl $0x2, %edi
callq 0x29470
movapd -0x70(%rbp), %xmm0
xorps %xmm1, %xmm1
cvtsi2sd %rax, %xmm1
divsd %xmm1, %xmm0
ucomisd 0x4f73b(%rip), %xmm0 # 0xe0fe8
jb 0x91951
movapd %xmm0, %xmm1
divsd 0x4f729(%rip), %xmm1 # 0xe0fe8
cvttsd2si %xmm1, %rax
movq %rax, %rcx
subsd 0x4f6d9(%rip), %xmm1 # 0xe0fa8
cvttsd2si %xmm1, %r8
sarq $0x3f, %rcx
andq %rcx, %r8
orq %rax, %r8
movq %r8, %xmm2
punpckldq 0x477e5(%rip), %xmm2 # xmm2 = xmm2[0],mem[0],xmm2[1],mem[1]
subpd 0x477ed(%rip), %xmm2 # 0xd90e0
movapd %xmm2, %xmm1
unpckhpd %xmm2, %xmm1 # xmm1 = xmm1[1],xmm2[1]
addsd %xmm2, %xmm1
mulsd 0x4f6e9(%rip), %xmm1 # 0xe0ff0
addsd %xmm1, %xmm0
movapd %xmm0, -0x70(%rbp)
cmpq $0x2, %r8
leaq 0x4a6c5(%rip), %rax # 0xdbfe0
leaq 0x4a6c5(%rip), %r9 # 0xdbfe7
cmovaeq %rax, %r9
leaq 0x4a6ac(%rip), %rcx # 0xdbfd9
leaq -0x60(%rbp), %rdi
movl $0x3c, %edx
movl $0x1, %esi
xorl %eax, %eax
callq 0x29970
movapd -0x70(%rbp), %xmm0
cltq
leaq (%rax,%rbp), %rbx
addq $-0x60, %rbx
ucomisd 0x4f69f(%rip), %xmm0 # 0xe0ff8
jb 0x919f9
movapd %xmm0, %xmm1
divsd 0x4f68d(%rip), %xmm1 # 0xe0ff8
cvttsd2si %xmm1, %rax
movq %rax, %rcx
subsd 0x4f62d(%rip), %xmm1 # 0xe0fa8
cvttsd2si %xmm1, %r8
sarq $0x3f, %rcx
andq %rcx, %r8
orq %rax, %r8
movq %r8, %xmm2
punpckldq 0x47739(%rip), %xmm2 # xmm2 = xmm2[0],mem[0],xmm2[1],mem[1]
subpd 0x47741(%rip), %xmm2 # 0xd90e0
movapd %xmm2, %xmm1
unpckhpd %xmm2, %xmm1 # xmm1 = xmm1[1],xmm2[1]
addsd %xmm2, %xmm1
mulsd 0x4f64d(%rip), %xmm1 # 0xe1000
addsd %xmm1, %xmm0
movapd %xmm0, -0x70(%rbp)
cmpq $0x2, %r8
leaq 0x4a626(%rip), %rax # 0xdbfed
leaq 0x4a627(%rip), %r9 # 0xdbff5
cmovaeq %rax, %r9
leaq 0x4a600(%rip), %rcx # 0xdbfd9
movq %rbx, %rdi
movl $0x1, %esi
movq $-0x1, %rdx
xorl %eax, %eax
callq 0x29970
movapd -0x70(%rbp), %xmm0
cltq
addq %rax, %rbx
ucomisd 0x4f607(%rip), %xmm0 # 0xe1008
jb 0x91a8b
movapd %xmm0, %xmm1
divsd 0x4f5f5(%rip), %xmm1 # 0xe1008
cvttsd2si %xmm1, %rax
movq %rax, %rcx
subsd 0x4f585(%rip), %xmm1 # 0xe0fa8
sarq $0x3f, %rcx
cvttsd2si %xmm1, %r8
andq %rcx, %r8
orq %rax, %r8
movq %r8, %xmm2
punpckldq 0x47691(%rip), %xmm2 # xmm2 = xmm2[0],mem[0],xmm2[1],mem[1]
subpd 0x47699(%rip), %xmm2 # 0xd90e0
movapd %xmm2, %xmm1
unpckhpd %xmm2, %xmm1 # xmm1 = xmm1[1],xmm2[1]
addsd %xmm2, %xmm1
mulsd 0x4f5b5(%rip), %xmm1 # 0xe1010
addsd %xmm1, %xmm0
movapd %xmm0, -0x70(%rbp)
leaq 0x4a591(%rip), %rcx # 0xdbffc
movq %rbx, %rdi
movl $0x1, %esi
movq $-0x1, %rdx
xorl %eax, %eax
callq 0x29970
movapd -0x70(%rbp), %xmm0
cltq
addq %rax, %rbx
leaq 0x4a573(%rip), %rcx # 0xdc005
movq %rbx, %rdi
movl $0x1, %esi
movq $-0x1, %rdx
movb $0x1, %al
callq 0x29970
leaq 0x4a4ee(%rip), %rsi # 0xdbf9d
xorl %ebx, %ebx
leaq -0x60(%rbp), %rdx
movl $0x1, %edi
xorl %eax, %eax
callq 0x29810
movq 0x2f24e0(%rip), %rax # 0x383fa8
movq (%rax), %rdi
callq 0x29400
jmp 0x91827
xorl %ebx, %ebx
jmp 0x91827
callq 0x29270
| exit_status:
push rbp
mov rbp, rsp
push r14
push rbx
sub rsp, 60h
mov rax, fs:28h
mov [rbp+var_18], rax
mov esi, cs:g_test
test esi, esi
jnz short loc_917DE
mov edi, cs:dword_BFFA14
call plan
mov esi, cs:g_test
loc_917DE:
mov ecx, cs:dword_BFFA14
cmp esi, ecx
jnz short loc_91802
mov esi, cs:dword_BFFA18
test esi, esi
jle short loc_91845
lea rdi, aFailedDTests; "Failed %d tests!"
xor eax, eax
call diag
jmp short loc_91822
loc_91802:
lea rax, aTableIsReadOnl+0Dh; " only"
lea rdx, asc_DFE15+4; ""
cmovg rdx, rax
lea rdi, aDTestsPlannedB; "%d tests planned but%s %d executed"
xor eax, eax
call diag
loc_91822:
mov ebx, 1
loc_91827:
mov rax, fs:28h
cmp rax, [rbp+var_18]
jnz loc_91ADC
mov eax, ebx
add rsp, 60h
pop rbx
pop r14
pop rbp
retn
loc_91845:
mov r14, cs:start_time
test r14, r14
jz loc_91AD5
lea rbx, [rbp+var_60]
mov rdi, rbx
call _times
sub rax, r14
movq xmm0, rax
punpckldq xmm0, cs:xmmword_D90D0
subpd xmm0, cs:xmmword_D90E0
movapd xmm1, xmm0
unpckhpd xmm1, xmm0
addsd xmm1, xmm0
movapd [rbp+var_70], xmm1
mov edi, 2
call _sysconf
movapd xmm0, [rbp+var_70]
xorps xmm1, xmm1
cvtsi2sd xmm1, rax
divsd xmm0, xmm1
ucomisd xmm0, cs:qword_E0FE8
jb loc_91951
movapd xmm1, xmm0
divsd xmm1, cs:qword_E0FE8
cvttsd2si rax, xmm1
mov rcx, rax
subsd xmm1, cs:qword_E0FA8
cvttsd2si r8, xmm1
sar rcx, 3Fh
and r8, rcx
or r8, rax
movq xmm2, r8
punpckldq xmm2, cs:xmmword_D90D0
subpd xmm2, cs:xmmword_D90E0
movapd xmm1, xmm2
unpckhpd xmm1, xmm2
addsd xmm1, xmm2
mulsd xmm1, cs:qword_E0FF0
addsd xmm0, xmm1
movapd [rbp+var_70], xmm0
cmp r8, 2
lea rax, aDays; " days "
lea r9, aDay; " day "
cmovnb r9, rax
lea rcx, aLdS; "%ld %s"
lea rdi, [rbp+var_60]
mov edx, 3Ch ; '<'
mov esi, 1
xor eax, eax
call ___sprintf_chk
movapd xmm0, [rbp+var_70]
cdqe
lea rbx, [rax+rbp]
add rbx, 0FFFFFFFFFFFFFFA0h
loc_91951:
ucomisd xmm0, cs:qword_E0FF8
jb loc_919F9
movapd xmm1, xmm0
divsd xmm1, cs:qword_E0FF8
cvttsd2si rax, xmm1
mov rcx, rax
subsd xmm1, cs:qword_E0FA8
cvttsd2si r8, xmm1
sar rcx, 3Fh
and r8, rcx
or r8, rax
movq xmm2, r8
punpckldq xmm2, cs:xmmword_D90D0
subpd xmm2, cs:xmmword_D90E0
movapd xmm1, xmm2
unpckhpd xmm1, xmm2
addsd xmm1, xmm2
mulsd xmm1, cs:qword_E1000
addsd xmm0, xmm1
movapd [rbp+var_70], xmm0
cmp r8, 2
lea rax, aHours; " hours "
lea r9, aHour; " hour "
cmovnb r9, rax
lea rcx, aLdS; "%ld %s"
mov rdi, rbx
mov esi, 1
mov rdx, 0FFFFFFFFFFFFFFFFh
xor eax, eax
call ___sprintf_chk
movapd xmm0, [rbp+var_70]
cdqe
add rbx, rax
loc_919F9:
ucomisd xmm0, cs:qword_E1008
jb loc_91A8B
movapd xmm1, xmm0
divsd xmm1, cs:qword_E1008
cvttsd2si rax, xmm1
mov rcx, rax
subsd xmm1, cs:qword_E0FA8
sar rcx, 3Fh
cvttsd2si r8, xmm1
and r8, rcx
or r8, rax
movq xmm2, r8
punpckldq xmm2, cs:xmmword_D90D0
subpd xmm2, cs:xmmword_D90E0
movapd xmm1, xmm2
unpckhpd xmm1, xmm2
addsd xmm1, xmm2
mulsd xmm1, cs:qword_E1010
addsd xmm0, xmm1
movapd [rbp+var_70], xmm0
lea rcx, aLdMin; "%ld min "
mov rdi, rbx
mov esi, 1
mov rdx, 0FFFFFFFFFFFFFFFFh
xor eax, eax
call ___sprintf_chk
movapd xmm0, [rbp+var_70]
cdqe
add rbx, rax
loc_91A8B:
lea rcx, a2fSec; "%.2f sec"
mov rdi, rbx
mov esi, 1
mov rdx, 0FFFFFFFFFFFFFFFFh
mov al, 1
call ___sprintf_chk
lea rsi, aTestTookS; "Test took %s\n"
xor ebx, ebx
lea rdx, [rbp+var_60]
mov edi, 1
xor eax, eax
call ___printf_chk
mov rax, cs:stdout_ptr
mov rdi, [rax]
call _fflush
jmp loc_91827
loc_91AD5:
xor ebx, ebx
jmp loc_91827
loc_91ADC:
call ___stack_chk_fail
| long long exit_status(
__m128 a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
long long a9,
long long a10,
long long a11,
long long a12,
long long a13,
long long a14)
{
long long v14; // rsi
char *v15; // rdx
unsigned int v16; // ebx
char *v18; // rbx
__m128d v19; // xmm0
double v20; // xmm0_8
unsigned long long v21; // r8
__m128d v22; // xmm2
const char *v23; // r9
unsigned long long v24; // r8
__m128d v25; // xmm2
const char *v26; // r9
long long v27; // r8
__m128d v28; // xmm2
char v29; // [rsp+0h] [rbp-70h]
char v30[72]; // [rsp+10h] [rbp-60h] BYREF
unsigned long long v31; // [rsp+58h] [rbp-18h]
v31 = __readfsqword(0x28u);
v14 = (unsigned int)g_test;
if ( !g_test )
{
plan(dword_BFFA14);
v14 = (unsigned int)g_test;
}
if ( (_DWORD)v14 != dword_BFFA14 )
{
v15 = "";
if ( (int)v14 > dword_BFFA14 )
v15 = " only";
diag(
(long long)"%d tests planned but%s %d executed",
v14,
(long long)v15,
(unsigned int)dword_BFFA14,
a13,
a14,
a1,
a2,
a3,
a4,
a5,
a6,
a7,
a8,
v29);
return 1;
}
if ( dword_BFFA18 > 0 )
{
diag(
(long long)"Failed %d tests!",
(unsigned int)dword_BFFA18,
a11,
(unsigned int)dword_BFFA14,
a13,
a14,
a1,
a2,
a3,
a4,
a5,
a6,
a7,
a8,
v29);
return 1;
}
if ( start_time )
{
v18 = v30;
v19 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32((__m128i)(unsigned long long)(times(v30) - start_time), (__m128i)xmmword_D90D0),
(__m128d)xmmword_D90E0);
v20 = (_mm_unpackhi_pd(v19, v19).m128d_f64[0] + v19.m128d_f64[0]) / (double)(int)sysconf(2LL);
if ( v20 >= 86400.0 )
{
v21 = (unsigned int)(int)(v20 / 86400.0);
v22 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32((__m128i)(unsigned int)(int)(v20 / 86400.0), (__m128i)xmmword_D90D0),
(__m128d)xmmword_D90E0);
v20 = v20 + (_mm_unpackhi_pd(v22, v22).m128d_f64[0] + v22.m128d_f64[0]) * -86400.0;
v23 = " day ";
if ( v21 >= 2 )
v23 = " days ";
v18 = &v30[(int)__sprintf_chk(v30, 1LL, 60LL, "%ld %s", v21, v23)];
}
if ( v20 >= 3600.0 )
{
v24 = (unsigned int)(int)(v20 / 3600.0);
v25 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32((__m128i)(unsigned int)(int)(v20 / 3600.0), (__m128i)xmmword_D90D0),
(__m128d)xmmword_D90E0);
v20 = v20 + (_mm_unpackhi_pd(v25, v25).m128d_f64[0] + v25.m128d_f64[0]) * -3600.0;
v26 = " hour ";
if ( v24 >= 2 )
v26 = " hours ";
v18 += (int)__sprintf_chk(v18, 1LL, -1LL, "%ld %s", v24, v26);
}
if ( v20 >= 60.0 )
{
v27 = (unsigned int)(int)(v20 / 60.0);
v28 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32((__m128i)(unsigned int)(int)(v20 / 60.0), (__m128i)xmmword_D90D0),
(__m128d)xmmword_D90E0);
v20 = v20 + (_mm_unpackhi_pd(v28, v28).m128d_f64[0] + v28.m128d_f64[0]) * -60.0;
v18 += (int)__sprintf_chk(v18, 1LL, -1LL, "%ld min ", v27);
}
__sprintf_chk(v18, 1LL, -1LL, "%.2f sec", v20);
v16 = 0;
__printf_chk(1LL, "Test took %s\n", v30);
fflush(stdout);
}
else
{
return 0;
}
return v16;
}
| exit_status:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
SUB RSP,0x60
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
MOV ESI,dword ptr [0x00cffa10]
TEST ESI,ESI
JNZ 0x001917de
MOV EDI,dword ptr [0x00cffa14]
CALL 0x001911bb
MOV ESI,dword ptr [0x00cffa10]
LAB_001917de:
MOV ECX,dword ptr [0x00cffa14]
CMP ESI,ECX
JNZ 0x00191802
MOV ESI,dword ptr [0x00cffa18]
TEST ESI,ESI
JLE 0x00191845
LEA RDI,[0x1dbf8c]
XOR EAX,EAX
CALL 0x001910e7
JMP 0x00191822
LAB_00191802:
LEA RAX,[0x1e057b]
LEA RDX,[0x1dfe19]
CMOVG RDX,RAX
LEA RDI,[0x1dbf69]
XOR EAX,EAX
CALL 0x001910e7
LAB_00191822:
MOV EBX,0x1
LAB_00191827:
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x18]
JNZ 0x00191adc
MOV EAX,EBX
ADD RSP,0x60
POP RBX
POP R14
POP RBP
RET
LAB_00191845:
MOV R14,qword ptr [0x00cffaa0]
TEST R14,R14
JZ 0x00191ad5
LEA RBX,[RBP + -0x60]
MOV RDI,RBX
CALL 0x00129170
SUB RAX,R14
MOVQ XMM0,RAX
PUNPCKLDQ XMM0,xmmword ptr [0x001d90d0]
SUBPD XMM0,xmmword ptr [0x001d90e0]
MOVAPD XMM1,XMM0
UNPCKHPD XMM1,XMM0
ADDSD XMM1,XMM0
MOVAPD xmmword ptr [RBP + -0x70],XMM1
MOV EDI,0x2
CALL 0x00129470
MOVAPD XMM0,xmmword ptr [RBP + -0x70]
XORPS XMM1,XMM1
CVTSI2SD XMM1,RAX
DIVSD XMM0,XMM1
UCOMISD XMM0,qword ptr [0x001e0fe8]
JC 0x00191951
MOVAPD XMM1,XMM0
DIVSD XMM1,qword ptr [0x001e0fe8]
CVTTSD2SI RAX,XMM1
MOV RCX,RAX
SUBSD XMM1,qword ptr [0x001e0fa8]
CVTTSD2SI R8,XMM1
SAR RCX,0x3f
AND R8,RCX
OR R8,RAX
MOVQ XMM2,R8
PUNPCKLDQ XMM2,xmmword ptr [0x001d90d0]
SUBPD XMM2,xmmword ptr [0x001d90e0]
MOVAPD XMM1,XMM2
UNPCKHPD XMM1,XMM2
ADDSD XMM1,XMM2
MULSD XMM1,qword ptr [0x001e0ff0]
ADDSD XMM0,XMM1
MOVAPD xmmword ptr [RBP + -0x70],XMM0
CMP R8,0x2
LEA RAX,[0x1dbfe0]
LEA R9,[0x1dbfe7]
CMOVNC R9,RAX
LEA RCX,[0x1dbfd9]
LEA RDI,[RBP + -0x60]
MOV EDX,0x3c
MOV ESI,0x1
XOR EAX,EAX
CALL 0x00129970
MOVAPD XMM0,xmmword ptr [RBP + -0x70]
CDQE
LEA RBX,[RAX + RBP*0x1]
ADD RBX,-0x60
LAB_00191951:
UCOMISD XMM0,qword ptr [0x001e0ff8]
JC 0x001919f9
MOVAPD XMM1,XMM0
DIVSD XMM1,qword ptr [0x001e0ff8]
CVTTSD2SI RAX,XMM1
MOV RCX,RAX
SUBSD XMM1,qword ptr [0x001e0fa8]
CVTTSD2SI R8,XMM1
SAR RCX,0x3f
AND R8,RCX
OR R8,RAX
MOVQ XMM2,R8
PUNPCKLDQ XMM2,xmmword ptr [0x001d90d0]
SUBPD XMM2,xmmword ptr [0x001d90e0]
MOVAPD XMM1,XMM2
UNPCKHPD XMM1,XMM2
ADDSD XMM1,XMM2
MULSD XMM1,qword ptr [0x001e1000]
ADDSD XMM0,XMM1
MOVAPD xmmword ptr [RBP + -0x70],XMM0
CMP R8,0x2
LEA RAX,[0x1dbfed]
LEA R9,[0x1dbff5]
CMOVNC R9,RAX
LEA RCX,[0x1dbfd9]
MOV RDI,RBX
MOV ESI,0x1
MOV RDX,-0x1
XOR EAX,EAX
CALL 0x00129970
MOVAPD XMM0,xmmword ptr [RBP + -0x70]
CDQE
ADD RBX,RAX
LAB_001919f9:
UCOMISD XMM0,qword ptr [0x001e1008]
JC 0x00191a8b
MOVAPD XMM1,XMM0
DIVSD XMM1,qword ptr [0x001e1008]
CVTTSD2SI RAX,XMM1
MOV RCX,RAX
SUBSD XMM1,qword ptr [0x001e0fa8]
SAR RCX,0x3f
CVTTSD2SI R8,XMM1
AND R8,RCX
OR R8,RAX
MOVQ XMM2,R8
PUNPCKLDQ XMM2,xmmword ptr [0x001d90d0]
SUBPD XMM2,xmmword ptr [0x001d90e0]
MOVAPD XMM1,XMM2
UNPCKHPD XMM1,XMM2
ADDSD XMM1,XMM2
MULSD XMM1,qword ptr [0x001e1010]
ADDSD XMM0,XMM1
MOVAPD xmmword ptr [RBP + -0x70],XMM0
LEA RCX,[0x1dbffc]
MOV RDI,RBX
MOV ESI,0x1
MOV RDX,-0x1
XOR EAX,EAX
CALL 0x00129970
MOVAPD XMM0,xmmword ptr [RBP + -0x70]
CDQE
ADD RBX,RAX
LAB_00191a8b:
LEA RCX,[0x1dc005]
MOV RDI,RBX
MOV ESI,0x1
MOV RDX,-0x1
MOV AL,0x1
CALL 0x00129970
LEA RSI,[0x1dbf9d]
XOR EBX,EBX
LEA RDX,[RBP + -0x60]
MOV EDI,0x1
XOR EAX,EAX
CALL 0x00129810
MOV RAX,qword ptr [0x00483fa8]
MOV RDI,qword ptr [RAX]
CALL 0x00129400
JMP 0x00191827
LAB_00191ad5:
XOR EBX,EBX
JMP 0x00191827
LAB_00191adc:
CALL 0x00129270
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
int8 exit_status(void)
{
int iVar1;
clock_t cVar2;
long lVar3;
ulong uVar4;
int8 uVar5;
tms *__buffer;
char *pcVar6;
long in_FS_OFFSET;
double dVar7;
int1 auVar8 [16];
double dVar9;
int1 auVar10 [16];
int1 auVar11 [16];
tms local_68 [2];
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
if (g_test == 0) {
plan(DAT_00cffa14);
}
lVar3 = start_time;
if (g_test == DAT_00cffa14) {
if (DAT_00cffa18 < 1) {
if (start_time == 0) {
uVar5 = 0;
}
else {
__buffer = local_68;
cVar2 = times(__buffer);
lVar3 = cVar2 - lVar3;
auVar8._8_4_ = (int)((ulong)lVar3 >> 0x20);
auVar8._0_8_ = lVar3;
auVar8._12_4_ = DAT_001d90d0._4_4_;
dVar7 = (double)CONCAT44((int4)DAT_001d90d0,(int)lVar3) - _DAT_001d90e0;
dVar9 = auVar8._8_8_ - _UNK_001d90e8;
lVar3 = sysconf(2);
dVar7 = (dVar9 + dVar7) / (double)lVar3;
if (_DAT_001e0fe8 <= dVar7) {
uVar4 = (ulong)(dVar7 / _DAT_001e0fe8);
uVar4 = (long)(dVar7 / _DAT_001e0fe8 - _DAT_001e0fa8) & (long)uVar4 >> 0x3f | uVar4;
auVar10._8_4_ = (int)(uVar4 >> 0x20);
auVar10._0_8_ = uVar4;
auVar10._12_4_ = DAT_001d90d0._4_4_;
dVar7 = dVar7 + ((auVar10._8_8_ - _UNK_001d90e8) +
((double)CONCAT44((int4)DAT_001d90d0,(int)uVar4) - _DAT_001d90e0)) *
_DAT_001e0ff0;
pcVar6 = " day ";
if (1 < uVar4) {
pcVar6 = " days ";
}
iVar1 = __sprintf_chk(local_68,1,0x3c,"%ld %s",uVar4,pcVar6);
__buffer = (tms *)((long)&local_68[0].tms_utime + (long)iVar1);
}
if (_DAT_001e0ff8 <= dVar7) {
uVar4 = (ulong)(dVar7 / _DAT_001e0ff8);
uVar4 = (long)(dVar7 / _DAT_001e0ff8 - _DAT_001e0fa8) & (long)uVar4 >> 0x3f | uVar4;
auVar11._8_4_ = (int)(uVar4 >> 0x20);
auVar11._0_8_ = uVar4;
auVar11._12_4_ = DAT_001d90d0._4_4_;
dVar7 = dVar7 + ((auVar11._8_8_ - _UNK_001d90e8) +
((double)CONCAT44((int4)DAT_001d90d0,(int)uVar4) - _DAT_001d90e0)) *
_DAT_001e1000;
pcVar6 = " hour ";
if (1 < uVar4) {
pcVar6 = " hours ";
}
iVar1 = __sprintf_chk(__buffer,1,0xffffffffffffffff,"%ld %s",uVar4,pcVar6);
__buffer = (tms *)((long)&__buffer->tms_utime + (long)iVar1);
}
if (_DAT_001e1008 <= dVar7) {
iVar1 = __sprintf_chk(__buffer,1,0xffffffffffffffff,"%ld min ");
__buffer = (tms *)((long)&__buffer->tms_utime + (long)iVar1);
}
__sprintf_chk(__buffer,1,0xffffffffffffffff,"%.2f sec");
uVar5 = 0;
__printf_chk(1,"Test took %s\n",local_68);
fflush(*(FILE **)PTR_stdout_00483fa8);
}
goto LAB_00191827;
}
diag("Failed %d tests!");
}
else {
pcVar6 = "";
if (DAT_00cffa14 < g_test) {
pcVar6 = " only";
}
diag("%d tests planned but%s %d executed",g_test,pcVar6);
}
uVar5 = 1;
LAB_00191827:
if (*(long *)(in_FS_OFFSET + 0x28) == local_20) {
return uVar5;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
55,502 | common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int, std::allocator<int>> const&, std::vector<int, std::allocator<int>> const&, bool) | monkey531[P]llama/common/sampling.cpp | std::vector<llama_token> common_sampler_sample_and_accept_n(struct common_sampler * gsmpl, struct llama_context * ctx, const std::vector<int> & idxs, const llama_tokens & draft, bool grammar_first) {
GGML_ASSERT(idxs.size() == draft.size() + 1 && "idxs.size() must be draft.size() + 1");
std::vector<llama_token> result;
result.reserve(idxs.size());
size_t i = 0;
for (; i < draft.size(); i++) {
const llama_token id = common_sampler_sample(gsmpl, ctx, idxs[i], grammar_first);
common_sampler_accept(gsmpl, id, true);
result.push_back(id);
if (draft[i] != id) {
break;
}
}
if (i == draft.size()) {
const llama_token id = common_sampler_sample(gsmpl, ctx, idxs[i], grammar_first);
common_sampler_accept(gsmpl, id, true);
result.push_back(id);
}
return result;
} | O1 | cpp | common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int, std::allocator<int>> const&, std::vector<int, std::allocator<int>> const&, bool):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, 0x10(%rsp)
movq %rsi, %r14
movq 0x8(%rcx), %rsi
subq (%rcx), %rsi
movq 0x8(%r8), %rax
subq (%r8), %rax
sarq $0x2, %rsi
sarq $0x2, %rax
incq %rax
cmpq %rax, %rsi
jne 0xcfe75
movl %r9d, %ebp
movq %r8, %r13
movq %rcx, %r12
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
callq 0xd0e38
movq 0x8(%r13), %rax
movzbl %bpl, %ebp
cmpq (%r13), %rax
je 0xcfdfe
xorl %r15d, %r15d
movq (%r12), %rax
movl (%rax,%r15,4), %edx
movq %r14, %rdi
movq 0x10(%rsp), %rsi
movl %ebp, %ecx
callq 0xcfbcc
movl %eax, 0x8(%rsp)
movq %r14, %rdi
movl %eax, %esi
movl $0x1, %edx
callq 0xcfa13
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0xcfdcd
movl 0x8(%rsp), %eax
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rbx)
jmp 0xcfdda
movq %rbx, %rdi
leaq 0x8(%rsp), %rdx
callq 0x71d10
movq (%r13), %rax
movl (%rax,%r15,4), %eax
cmpl 0x8(%rsp), %eax
jne 0xcfe01
incq %r15
movq 0x8(%r13), %rax
subq (%r13), %rax
sarq $0x2, %rax
cmpq %rax, %r15
jb 0xcfd89
jmp 0xcfe01
xorl %r15d, %r15d
movq 0x8(%r13), %rax
subq (%r13), %rax
sarq $0x2, %rax
cmpq %rax, %r15
jne 0xcfe63
movq (%r12), %rax
movl (%rax,%r15,4), %edx
movq %r14, %rdi
movq 0x10(%rsp), %rsi
movl %ebp, %ecx
callq 0xcfbcc
movl %eax, 0xc(%rsp)
movq %r14, %rdi
movl %eax, %esi
movl $0x1, %edx
callq 0xcfa13
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0xcfe56
movl 0xc(%rsp), %eax
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rbx)
jmp 0xcfe63
leaq 0xc(%rsp), %rdx
movq %rbx, %rdi
callq 0x71d10
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x28b95(%rip), %rdi # 0xf8a11
leaq 0x1f720(%rip), %rdx # 0xef5a3
leaq 0x28d14(%rip), %rcx # 0xf8b9e
movl $0x155, %esi # imm = 0x155
xorl %eax, %eax
callq 0x1bec0
jmp 0xcfe9a
jmp 0xcfe9a
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0xcfeb1
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x1b900
movq %r14, %rdi
callq 0x1bfc0
| _Z34common_sampler_sample_and_accept_nP14common_samplerP13llama_contextRKSt6vectorIiSaIiEES7_b:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov [rsp+48h+var_38], rdx
mov r14, rsi
mov rsi, [rcx+8]
sub rsi, [rcx]
mov rax, [r8+8]
sub rax, [r8]
sar rsi, 2
sar rax, 2
inc rax
cmp rsi, rax
jnz loc_CFE75
mov ebp, r9d
mov r13, r8
mov r12, rcx
mov rbx, rdi
xorps xmm0, xmm0
movups xmmword ptr [rdi], xmm0
mov qword ptr [rdi+10h], 0
call _ZNSt6vectorIiSaIiEE7reserveEm; std::vector<int>::reserve(ulong)
mov rax, [r13+8]
movzx ebp, bpl
cmp rax, [r13+0]
jz short loc_CFDFE
xor r15d, r15d
loc_CFD89:
mov rax, [r12]
mov edx, [rax+r15*4]
mov rdi, r14
mov rsi, [rsp+48h+var_38]
mov ecx, ebp
call _Z21common_sampler_sampleP14common_samplerP13llama_contextib; common_sampler_sample(common_sampler *,llama_context *,int,bool)
mov [rsp+48h+var_40], eax
mov rdi, r14
mov esi, eax
mov edx, 1
call _Z21common_sampler_acceptP14common_samplerib; common_sampler_accept(common_sampler *,int,bool)
mov rsi, [rbx+8]
cmp rsi, [rbx+10h]
jz short loc_CFDCD
mov eax, [rsp+48h+var_40]
mov [rsi], eax
add rsi, 4
mov [rbx+8], rsi
jmp short loc_CFDDA
loc_CFDCD:
mov rdi, rbx
lea rdx, [rsp+48h+var_40]
call _ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRKiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_; std::vector<int>::_M_realloc_insert<int const&>(__gnu_cxx::__normal_iterator<int *,std::vector<int>>,int const&)
loc_CFDDA:
mov rax, [r13+0]
mov eax, [rax+r15*4]
cmp eax, [rsp+48h+var_40]
jnz short loc_CFE01
inc r15
mov rax, [r13+8]
sub rax, [r13+0]
sar rax, 2
cmp r15, rax
jb short loc_CFD89
jmp short loc_CFE01
loc_CFDFE:
xor r15d, r15d
loc_CFE01:
mov rax, [r13+8]
sub rax, [r13+0]
sar rax, 2
cmp r15, rax
jnz short loc_CFE63
mov rax, [r12]
mov edx, [rax+r15*4]
mov rdi, r14
mov rsi, [rsp+48h+var_38]
mov ecx, ebp
call _Z21common_sampler_sampleP14common_samplerP13llama_contextib; common_sampler_sample(common_sampler *,llama_context *,int,bool)
mov [rsp+48h+var_3C], eax
mov rdi, r14
mov esi, eax
mov edx, 1
call _Z21common_sampler_acceptP14common_samplerib; common_sampler_accept(common_sampler *,int,bool)
mov rsi, [rbx+8]
cmp rsi, [rbx+10h]
jz short loc_CFE56
mov eax, [rsp+48h+var_3C]
mov [rsi], eax
add rsi, 4
mov [rbx+8], rsi
jmp short loc_CFE63
loc_CFE56:
lea rdx, [rsp+48h+var_3C]
mov rdi, rbx
call _ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRKiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_; std::vector<int>::_M_realloc_insert<int const&>(__gnu_cxx::__normal_iterator<int *,std::vector<int>>,int const&)
loc_CFE63:
mov rax, rbx
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_CFE75:
lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aIdxsSizeDraftS; "idxs.size() == draft.size() + 1 && \"id"...
mov esi, 155h
xor eax, eax
call _ggml_abort
jmp short loc_CFE9A
jmp short $+2
loc_CFE9A:
mov r14, rax
mov rdi, [rbx]; void *
test rdi, rdi
jz short loc_CFEB1
mov rsi, [rbx+10h]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_CFEB1:
mov rdi, r14
call __Unwind_Resume
| long long * common_sampler_sample_and_accept_n(
long long *a1,
_QWORD *a2,
long long a3,
_QWORD *a4,
_QWORD *a5,
unsigned __int8 a6)
{
long long v6; // rbx
unsigned long long v11; // r15
_DWORD *v12; // rsi
_DWORD *v13; // rsi
long long v15; // rax
long long v16; // r14
unsigned int v17; // [rsp+8h] [rbp-40h] BYREF
unsigned int v18; // [rsp+Ch] [rbp-3Ch] BYREF
long long v19; // [rsp+10h] [rbp-38h]
v19 = a3;
if ( (long long)(a4[1] - *a4) >> 2 != ((long long)(a5[1] - *a5) >> 2) + 1 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/sampling.cpp",
341LL,
"GGML_ASSERT(%s) failed",
"idxs.size() == draft.size() + 1 && \"idxs.size() must be draft.size() + 1\"");
v16 = v15;
if ( *(_QWORD *)v6 )
operator delete(*(void **)v6, *(_QWORD *)(v6 + 16) - *(_QWORD *)v6);
_Unwind_Resume(v16);
}
*(_OWORD *)a1 = 0LL;
a1[2] = 0LL;
std::vector<int>::reserve();
if ( a5[1] == *a5 )
{
v11 = 0LL;
}
else
{
v11 = 0LL;
do
{
v17 = common_sampler_sample(a2, v19, *(_DWORD *)(*a4 + 4 * v11), a6);
common_sampler_accept(a2, v17, 1);
v12 = (_DWORD *)a1[1];
if ( v12 == (_DWORD *)a1[2] )
{
std::vector<int>::_M_realloc_insert<int const&>(a1, (long long)v12, &v17);
}
else
{
*v12 = v17;
a1[1] = (long long)(v12 + 1);
}
if ( *(_DWORD *)(*a5 + 4 * v11) != v17 )
break;
++v11;
}
while ( v11 < (long long)(a5[1] - *a5) >> 2 );
}
if ( v11 == (long long)(a5[1] - *a5) >> 2 )
{
v18 = common_sampler_sample(a2, v19, *(_DWORD *)(*a4 + 4 * v11), a6);
common_sampler_accept(a2, v18, 1);
v13 = (_DWORD *)a1[1];
if ( v13 == (_DWORD *)a1[2] )
{
std::vector<int>::_M_realloc_insert<int const&>(a1, (long long)v13, &v18);
}
else
{
*v13 = v18;
a1[1] = (long long)(v13 + 1);
}
}
return a1;
}
| common_sampler_sample_and_accept_n:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV qword ptr [RSP + 0x10],RDX
MOV R14,RSI
MOV RSI,qword ptr [RCX + 0x8]
SUB RSI,qword ptr [RCX]
MOV RAX,qword ptr [R8 + 0x8]
SUB RAX,qword ptr [R8]
SAR RSI,0x2
SAR RAX,0x2
INC RAX
CMP RSI,RAX
JNZ 0x001cfe75
MOV EBP,R9D
MOV R13,R8
MOV R12,RCX
MOV RBX,RDI
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI],XMM0
MOV qword ptr [RDI + 0x10],0x0
LAB_001cfd73:
CALL 0x001d0e38
MOV RAX,qword ptr [R13 + 0x8]
MOVZX EBP,BPL
CMP RAX,qword ptr [R13]
JZ 0x001cfdfe
XOR R15D,R15D
LAB_001cfd89:
MOV RAX,qword ptr [R12]
MOV EDX,dword ptr [RAX + R15*0x4]
LAB_001cfd91:
MOV RDI,R14
MOV RSI,qword ptr [RSP + 0x10]
MOV ECX,EBP
CALL 0x001cfbcc
MOV dword ptr [RSP + 0x8],EAX
MOV RDI,R14
MOV ESI,EAX
MOV EDX,0x1
CALL 0x001cfa13
MOV RSI,qword ptr [RBX + 0x8]
CMP RSI,qword ptr [RBX + 0x10]
JZ 0x001cfdcd
MOV EAX,dword ptr [RSP + 0x8]
MOV dword ptr [RSI],EAX
ADD RSI,0x4
MOV qword ptr [RBX + 0x8],RSI
JMP 0x001cfdda
LAB_001cfdcd:
MOV RDI,RBX
LEA RDX,[RSP + 0x8]
CALL 0x00171d10
LAB_001cfdda:
MOV RAX,qword ptr [R13]
MOV EAX,dword ptr [RAX + R15*0x4]
CMP EAX,dword ptr [RSP + 0x8]
JNZ 0x001cfe01
INC R15
MOV RAX,qword ptr [R13 + 0x8]
SUB RAX,qword ptr [R13]
SAR RAX,0x2
CMP R15,RAX
JC 0x001cfd89
JMP 0x001cfe01
LAB_001cfdfe:
XOR R15D,R15D
LAB_001cfe01:
MOV RAX,qword ptr [R13 + 0x8]
SUB RAX,qword ptr [R13]
SAR RAX,0x2
CMP R15,RAX
JNZ 0x001cfe63
MOV RAX,qword ptr [R12]
MOV EDX,dword ptr [RAX + R15*0x4]
LAB_001cfe1a:
MOV RDI,R14
MOV RSI,qword ptr [RSP + 0x10]
MOV ECX,EBP
CALL 0x001cfbcc
MOV dword ptr [RSP + 0xc],EAX
MOV RDI,R14
MOV ESI,EAX
MOV EDX,0x1
CALL 0x001cfa13
MOV RSI,qword ptr [RBX + 0x8]
CMP RSI,qword ptr [RBX + 0x10]
JZ 0x001cfe56
MOV EAX,dword ptr [RSP + 0xc]
MOV dword ptr [RSI],EAX
ADD RSI,0x4
MOV qword ptr [RBX + 0x8],RSI
JMP 0x001cfe63
LAB_001cfe56:
LEA RDX,[RSP + 0xc]
MOV RDI,RBX
CALL 0x00171d10
LAB_001cfe63:
MOV RAX,RBX
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001cfe75:
LEA RDI,[0x1f8a11]
LEA RDX,[0x1ef5a3]
LEA RCX,[0x1f8b9e]
MOV ESI,0x155
XOR EAX,EAX
CALL 0x0011bec0
|
/* common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int,
std::allocator<int> > const&, std::vector<int, std::allocator<int> > const&, bool) */
common_sampler *
common_sampler_sample_and_accept_n
(common_sampler *param_1,llama_context *param_2,vector *param_3,vector *param_4,
bool param_5)
{
int *piVar1;
long *plVar2;
ulong uVar3;
int7 in_register_00000081;
bool in_R9B;
int local_40;
int local_3c;
vector *local_38;
uVar3 = *(long *)(param_4 + 8) - *(long *)param_4 >> 2;
local_38 = param_3;
if (uVar3 == (*(long *)(CONCAT71(in_register_00000081,param_5) + 8) -
*(long *)CONCAT71(in_register_00000081,param_5) >> 2) + 1U) {
plVar2 = (long *)CONCAT71(in_register_00000081,param_5);
*(int8 *)param_1 = 0;
*(int8 *)(param_1 + 8) = 0;
*(int8 *)(param_1 + 0x10) = 0;
/* try { // try from 001cfd73 to 001cfd77 has its CatchHandler @ 001cfe96 */
std::vector<int,std::allocator<int>>::reserve((vector<int,std::allocator<int>> *)param_1,uVar3);
if (plVar2[1] == *plVar2) {
uVar3 = 0;
}
else {
uVar3 = 0;
do {
/* try { // try from 001cfd91 to 001cfdd9 has its CatchHandler @ 001cfe9a */
local_40 = common_sampler_sample
((common_sampler *)param_2,(llama_context *)local_38,
*(int *)(*(long *)param_4 + uVar3 * 4),in_R9B);
common_sampler_accept((common_sampler *)param_2,local_40,true);
piVar1 = *(int **)(param_1 + 8);
if (piVar1 == *(int **)(param_1 + 0x10)) {
std::vector<int,std::allocator<int>>::_M_realloc_insert<int_const&>
((vector<int,std::allocator<int>> *)param_1,piVar1,&local_40);
}
else {
*piVar1 = local_40;
*(int **)(param_1 + 8) = piVar1 + 1;
}
} while ((*(int *)(*plVar2 + uVar3 * 4) == local_40) &&
(uVar3 = uVar3 + 1, uVar3 < (ulong)(plVar2[1] - *plVar2 >> 2)));
}
if (uVar3 == plVar2[1] - *plVar2 >> 2) {
/* try { // try from 001cfe1a to 001cfe62 has its CatchHandler @ 001cfe98 */
local_3c = common_sampler_sample
((common_sampler *)param_2,(llama_context *)local_38,
*(int *)(*(long *)param_4 + uVar3 * 4),in_R9B);
common_sampler_accept((common_sampler *)param_2,local_3c,true);
piVar1 = *(int **)(param_1 + 8);
if (piVar1 == *(int **)(param_1 + 0x10)) {
std::vector<int,std::allocator<int>>::_M_realloc_insert<int_const&>
((vector<int,std::allocator<int>> *)param_1,piVar1,&local_3c);
}
else {
*piVar1 = local_3c;
*(int **)(param_1 + 8) = piVar1 + 1;
}
}
return param_1;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/sampling.cpp",0x155,
"GGML_ASSERT(%s) failed",
"idxs.size() == draft.size() + 1 && \"idxs.size() must be draft.size() + 1\"");
}
| |
55,503 | ma_ft_segiterator_init | eloqsql/storage/maria/ma_ft_update.c | void _ma_ft_segiterator_init(MARIA_HA *info, uint keynr, const uchar *record,
FT_SEG_ITERATOR *ftsi)
{
DBUG_ENTER("_ma_ft_segiterator_init");
ftsi->num=info->s->keyinfo[keynr].keysegs;
ftsi->seg=info->s->keyinfo[keynr].seg;
ftsi->rec=record;
ftsi->pos= 0; /* Avoid warnings from gcc */
ftsi->len= 0; /* Avoid warnings from gcc */
DBUG_VOID_RETURN;
} | O3 | c | ma_ft_segiterator_init:
pushq %rbp
movq %rsp, %rbp
movq (%rdi), %rax
movq 0x570(%rax), %rax
movl %esi, %esi
imulq $0x118, %rsi, %rsi # imm = 0x118
movzwl 0xa0(%rax,%rsi), %eax
movl %eax, (%rcx)
movq (%rdi), %rax
movq 0x570(%rax), %rax
movq 0xc0(%rax,%rsi), %rax
movq %rax, 0x8(%rcx)
movq %rdx, 0x10(%rcx)
movq $0x0, 0x18(%rcx)
movl $0x0, 0x4(%rcx)
popq %rbp
retq
| _ma_ft_segiterator_init:
push rbp
mov rbp, rsp
mov rax, [rdi]
mov rax, [rax+570h]
mov esi, esi
imul rsi, 118h
movzx eax, word ptr [rax+rsi+0A0h]
mov [rcx], eax
mov rax, [rdi]
mov rax, [rax+570h]
mov rax, [rax+rsi+0C0h]
mov [rcx+8], rax
mov [rcx+10h], rdx
mov qword ptr [rcx+18h], 0
mov dword ptr [rcx+4], 0
pop rbp
retn
| long long ma_ft_segiterator_init(long long a1, unsigned int a2, long long a3, long long a4)
{
long long v4; // rsi
long long result; // rax
v4 = 280LL * a2;
*(_DWORD *)a4 = *(unsigned __int16 *)(*(_QWORD *)(*(_QWORD *)a1 + 1392LL) + v4 + 160);
result = *(_QWORD *)(*(_QWORD *)(*(_QWORD *)a1 + 1392LL) + v4 + 192);
*(_QWORD *)(a4 + 8) = result;
*(_QWORD *)(a4 + 16) = a3;
*(_QWORD *)(a4 + 24) = 0LL;
*(_DWORD *)(a4 + 4) = 0;
return result;
}
| _ma_ft_segiterator_init:
PUSH RBP
MOV RBP,RSP
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX + 0x570]
MOV ESI,ESI
IMUL RSI,RSI,0x118
MOVZX EAX,word ptr [RAX + RSI*0x1 + 0xa0]
MOV dword ptr [RCX],EAX
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX + 0x570]
MOV RAX,qword ptr [RAX + RSI*0x1 + 0xc0]
MOV qword ptr [RCX + 0x8],RAX
MOV qword ptr [RCX + 0x10],RDX
MOV qword ptr [RCX + 0x18],0x0
MOV dword ptr [RCX + 0x4],0x0
POP RBP
RET
|
void _ma_ft_segiterator_init(long *param_1,uint param_2,int8 param_3,uint *param_4)
{
*param_4 = (uint)*(ushort *)(*(long *)(*param_1 + 0x570) + 0xa0 + (ulong)param_2 * 0x118);
*(int8 *)(param_4 + 2) =
*(int8 *)(*(long *)(*param_1 + 0x570) + 0xc0 + (ulong)param_2 * 0x118);
*(int8 *)(param_4 + 4) = param_3;
param_4[6] = 0;
param_4[7] = 0;
param_4[1] = 0;
return;
}
| |
55,504 | my_register_filename | eloqsql/mysys/my_open.c | File my_register_filename(File fd, const char *FileName, enum file_type
type_of_file, uint error_message_number, myf MyFlags)
{
DBUG_ENTER("my_register_filename");
if ((int) fd >= MY_FILE_MIN)
{
my_atomic_add32_explicit(&my_file_opened, 1, MY_MEMORY_ORDER_RELAXED);
if ((uint) fd >= my_file_limit || (MyFlags & MY_NO_REGISTER))
DBUG_RETURN(fd);
my_file_info[fd].name = my_strdup(key_memory_my_file_info, FileName, MyFlags);
statistic_increment(my_file_total_opened,&THR_LOCK_open);
my_file_info[fd].type = type_of_file;
DBUG_PRINT("exit",("fd: %d",fd));
DBUG_RETURN(fd);
}
my_errno= errno;
DBUG_PRINT("error",("Got error %d on open", my_errno));
if (MyFlags & (MY_FFNF | MY_FAE | MY_WME))
{
if (my_errno == EMFILE)
error_message_number= EE_OUT_OF_FILERESOURCES;
my_error(error_message_number,
MYF(ME_BELL | (MyFlags & (ME_NOTE | ME_ERROR_LOG))),
FileName, my_errno);
}
DBUG_RETURN(-1);
} | O0 | c | my_register_filename:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl %ecx, -0x18(%rbp)
movq %r8, -0x20(%rbp)
cmpl $0x0, -0x8(%rbp)
jl 0xf4476
movl $0x1, -0x24(%rbp)
movl -0x24(%rbp), %eax
leaq 0xb8ea00(%rip), %rcx # 0xc82dd4
lock
xaddl %eax, (%rcx)
movl %eax, -0x28(%rbp)
movl -0x8(%rbp), %eax
leaq 0x1cb7cb(%rip), %rcx # 0x2bfbb0
cmpl (%rcx), %eax
jae 0xf43f9
movq -0x20(%rbp), %rax
andq $0x2004, %rax # imm = 0x2004
cmpq $0x0, %rax
je 0xf4406
jmp 0xf43fb
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xf44ed
leaq 0xb8eef7(%rip), %rax # 0xc83304
movl (%rax), %edi
movq -0x10(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0xf3ce0
movq %rax, %rcx
leaq 0x1cb792(%rip), %rax # 0x2bfbb8
movq (%rax), %rax
movslq -0x8(%rbp), %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rcx, (%rax)
leaq 0xb8e982(%rip), %rax # 0xc82dc0
movq (%rax), %rcx
addq $0x1, %rcx
leaq 0xb8e974(%rip), %rax # 0xc82dc0
movq %rcx, (%rax)
movl -0x14(%rbp), %ecx
leaq 0x1cb75f(%rip), %rax # 0x2bfbb8
movq (%rax), %rax
movslq -0x8(%rbp), %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movl %ecx, 0x8(%rax)
jmp 0xf446c
jmp 0xf446e
movl -0x8(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xf44ed
callq 0x2a760
movl (%rax), %eax
movl %eax, -0x2c(%rbp)
callq 0xf60c0
movl -0x2c(%rbp), %ecx
movl %ecx, (%rax)
jmp 0xf448c
movq -0x20(%rbp), %rax
andq $0x19, %rax
cmpq $0x0, %rax
je 0xf44e4
callq 0xf60c0
cmpl $0x18, (%rax)
jne 0xf44ab
movl $0x17, -0x18(%rbp)
movl -0x18(%rbp), %eax
movl %eax, -0x44(%rbp)
movq -0x20(%rbp), %rax
andq $0x440, %rax # imm = 0x440
orq $0x4, %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
callq 0xf60c0
movl -0x44(%rbp), %edi
movq -0x40(%rbp), %rsi
movq -0x38(%rbp), %rdx
movl (%rax), %ecx
movb $0x0, %al
callq 0xefb70
jmp 0xf44e6
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| my_register_filename:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], edi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
mov [rbp+var_18], ecx
mov [rbp+var_20], r8
cmp [rbp+var_8], 0
jl loc_F4476
mov [rbp+var_24], 1
mov eax, [rbp+var_24]
lea rcx, my_file_opened
lock xadd [rcx], eax
mov [rbp+var_28], eax
mov eax, [rbp+var_8]
lea rcx, my_file_limit
cmp eax, [rcx]
jnb short loc_F43F9
mov rax, [rbp+var_20]
and rax, 2004h
cmp rax, 0
jz short loc_F4406
loc_F43F9:
jmp short $+2
loc_F43FB:
mov eax, [rbp+var_8]
mov [rbp+var_4], eax
jmp loc_F44ED
loc_F4406:
lea rax, key_memory_my_file_info
mov edi, [rax]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_20]
call my_strdup
mov rcx, rax
lea rax, my_file_info
mov rax, [rax]
movsxd rdx, [rbp+var_8]
shl rdx, 4
add rax, rdx
mov [rax], rcx
lea rax, my_file_total_opened
mov rcx, [rax]
add rcx, 1
lea rax, my_file_total_opened
mov [rax], rcx
mov ecx, [rbp+var_14]
lea rax, my_file_info
mov rax, [rax]
movsxd rdx, [rbp+var_8]
shl rdx, 4
add rax, rdx
mov [rax+8], ecx
jmp short $+2
loc_F446C:
jmp short $+2
loc_F446E:
mov eax, [rbp+var_8]
mov [rbp+var_4], eax
jmp short loc_F44ED
loc_F4476:
call ___errno_location
mov eax, [rax]
mov [rbp+var_2C], eax
call _my_thread_var
mov ecx, [rbp+var_2C]
mov [rax], ecx
jmp short $+2
loc_F448C:
mov rax, [rbp+var_20]
and rax, 19h
cmp rax, 0
jz short loc_F44E4
call _my_thread_var
cmp dword ptr [rax], 18h
jnz short loc_F44AB
mov [rbp+var_18], 17h
loc_F44AB:
mov eax, [rbp+var_18]
mov [rbp+var_44], eax
mov rax, [rbp+var_20]
and rax, 440h
or rax, 4
mov [rbp+var_40], rax
mov rax, [rbp+var_10]
mov [rbp+var_38], rax
call _my_thread_var
mov edi, [rbp+var_44]
mov rsi, [rbp+var_40]
mov rdx, [rbp+var_38]
mov ecx, [rax]
mov al, 0
call my_error
loc_F44E4:
jmp short $+2
loc_F44E6:
mov [rbp+var_4], 0FFFFFFFFh
loc_F44ED:
mov eax, [rbp+var_4]
add rsp, 50h
pop rbp
retn
| long long my_register_filename(long long a1, const char *a2, int a3, unsigned int a4, __int16 a5)
{
unsigned int *v5; // rax
int v7; // [rsp+24h] [rbp-2Ch]
if ( (int)a1 < 0 )
{
v7 = *(_DWORD *)__errno_location();
*(_DWORD *)my_thread_var(a1, a2) = v7;
if ( (a5 & 0x19) != 0 )
{
if ( *(_DWORD *)my_thread_var(a1, a2) == 24 )
a4 = 23;
v5 = (unsigned int *)my_thread_var(a1, a2);
my_error(a4, a5 & 0x440 | 4LL, a2, *v5);
}
return (unsigned int)-1;
}
else
{
_InterlockedExchangeAdd(my_file_opened, 1u);
if ( (unsigned int)a1 >= my_file_limit || (a5 & 0x2004) != 0 )
{
return (unsigned int)a1;
}
else
{
*((_QWORD *)my_file_info + 2 * (int)a1) = my_strdup(key_memory_my_file_info, (long long)a2, a5);
++my_file_total_opened;
*((_DWORD *)my_file_info + 4 * (int)a1 + 2) = a3;
return (unsigned int)a1;
}
}
}
| my_register_filename:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV dword ptr [RBP + -0x8],EDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
MOV dword ptr [RBP + -0x18],ECX
MOV qword ptr [RBP + -0x20],R8
CMP dword ptr [RBP + -0x8],0x0
JL 0x001f4476
MOV dword ptr [RBP + -0x24],0x1
MOV EAX,dword ptr [RBP + -0x24]
LEA RCX,[0xd82dd4]
XADD.LOCK dword ptr [RCX],EAX
MOV dword ptr [RBP + -0x28],EAX
MOV EAX,dword ptr [RBP + -0x8]
LEA RCX,[0x3bfbb0]
CMP EAX,dword ptr [RCX]
JNC 0x001f43f9
MOV RAX,qword ptr [RBP + -0x20]
AND RAX,0x2004
CMP RAX,0x0
JZ 0x001f4406
LAB_001f43f9:
JMP 0x001f43fb
LAB_001f43fb:
MOV EAX,dword ptr [RBP + -0x8]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x001f44ed
LAB_001f4406:
LEA RAX,[0xd83304]
MOV EDI,dword ptr [RAX]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x20]
CALL 0x001f3ce0
MOV RCX,RAX
LEA RAX,[0x3bfbb8]
MOV RAX,qword ptr [RAX]
MOVSXD RDX,dword ptr [RBP + -0x8]
SHL RDX,0x4
ADD RAX,RDX
MOV qword ptr [RAX],RCX
LEA RAX,[0xd82dc0]
MOV RCX,qword ptr [RAX]
ADD RCX,0x1
LEA RAX,[0xd82dc0]
MOV qword ptr [RAX],RCX
MOV ECX,dword ptr [RBP + -0x14]
LEA RAX,[0x3bfbb8]
MOV RAX,qword ptr [RAX]
MOVSXD RDX,dword ptr [RBP + -0x8]
SHL RDX,0x4
ADD RAX,RDX
MOV dword ptr [RAX + 0x8],ECX
JMP 0x001f446c
LAB_001f446c:
JMP 0x001f446e
LAB_001f446e:
MOV EAX,dword ptr [RBP + -0x8]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x001f44ed
LAB_001f4476:
CALL 0x0012a760
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x2c],EAX
CALL 0x001f60c0
MOV ECX,dword ptr [RBP + -0x2c]
MOV dword ptr [RAX],ECX
JMP 0x001f448c
LAB_001f448c:
MOV RAX,qword ptr [RBP + -0x20]
AND RAX,0x19
CMP RAX,0x0
JZ 0x001f44e4
CALL 0x001f60c0
CMP dword ptr [RAX],0x18
JNZ 0x001f44ab
MOV dword ptr [RBP + -0x18],0x17
LAB_001f44ab:
MOV EAX,dword ptr [RBP + -0x18]
MOV dword ptr [RBP + -0x44],EAX
MOV RAX,qword ptr [RBP + -0x20]
AND RAX,0x440
OR RAX,0x4
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x38],RAX
CALL 0x001f60c0
MOV EDI,dword ptr [RBP + -0x44]
MOV RSI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x38]
MOV ECX,dword ptr [RAX]
MOV AL,0x0
CALL 0x001efb70
LAB_001f44e4:
JMP 0x001f44e6
LAB_001f44e6:
MOV dword ptr [RBP + -0x4],0xffffffff
LAB_001f44ed:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x50
POP RBP
RET
|
uint my_register_filename
(uint param_1,int8 param_2,int4 param_3,int4 param_4,ulong param_5)
{
int iVar1;
int8 uVar2;
int *piVar3;
int4 *puVar4;
int4 local_20;
uint local_c;
if ((int)param_1 < 0) {
piVar3 = __errno_location();
iVar1 = *piVar3;
piVar3 = (int *)_my_thread_var();
*piVar3 = iVar1;
if ((param_5 & 0x19) != 0) {
piVar3 = (int *)_my_thread_var();
local_20 = param_4;
if (*piVar3 == 0x18) {
local_20 = 0x17;
}
puVar4 = (int4 *)_my_thread_var();
my_error(local_20,param_5 & 0x440 | 4,param_2,*puVar4);
}
local_c = 0xffffffff;
}
else {
LOCK();
my_file_opened = my_file_opened + 1;
UNLOCK();
local_c = param_1;
if ((param_1 < my_file_limit) && ((param_5 & 0x2004) == 0)) {
uVar2 = my_strdup(key_memory_my_file_info,param_2,param_5);
*(int8 *)(my_file_info + (long)(int)param_1 * 0x10) = uVar2;
my_file_total_opened = my_file_total_opened + 1;
*(int4 *)(my_file_info + (long)(int)param_1 * 0x10 + 8) = param_3;
}
}
return local_c;
}
| |
55,505 | ma_bitmap_flush | eloqsql/storage/maria/ma_bitmap.c | my_bool _ma_bitmap_flush(MARIA_SHARE *share)
{
my_bool res= 0;
DBUG_ENTER("_ma_bitmap_flush");
if (share->bitmap.changed)
{
mysql_mutex_lock(&share->bitmap.bitmap_lock);
if (share->bitmap.changed)
{
/*
We have to mark the file changed here, as otherwise the following
write to pagecache may force a page out from this file, which would
cause _ma_mark_file_changed() to be called with bitmaplock hold!
*/
_ma_bitmap_mark_file_changed(share, 1);
res= write_changed_bitmap(share, &share->bitmap);
share->bitmap.changed= 0;
}
mysql_mutex_unlock(&share->bitmap.bitmap_lock);
}
DBUG_RETURN(res);
} | O0 | c | ma_bitmap_flush:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movb $0x0, -0x9(%rbp)
movq -0x8(%rbp), %rax
cmpb $0x0, 0xa30(%rax)
je 0x41b44
movq -0x8(%rbp), %rdi
addq $0xa10, %rdi # imm = 0xA10
addq $0x88, %rdi
leaq 0x10fb9d(%rip), %rsi # 0x151683
movl $0x1a9, %edx # imm = 0x1A9
callq 0x41c20
movq -0x8(%rbp), %rax
cmpb $0x0, 0xa30(%rax)
je 0x41b2d
movq -0x8(%rbp), %rdi
movl $0x1, %esi
callq 0x41c90
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rsi
addq $0xa10, %rsi # imm = 0xA10
callq 0x41d60
movb %al, -0x9(%rbp)
movq -0x8(%rbp), %rax
movb $0x0, 0xa30(%rax)
movq -0x8(%rbp), %rdi
addq $0xa10, %rdi # imm = 0xA10
addq $0x88, %rdi
callq 0x41ed0
jmp 0x41b46
movb -0x9(%rbp), %al
movb %al, -0xa(%rbp)
movb -0xa(%rbp), %al
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _ma_bitmap_flush:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov [rbp+var_9], 0
mov rax, [rbp+var_8]
cmp byte ptr [rax+0A30h], 0
jz short loc_41B44
mov rdi, [rbp+var_8]
add rdi, 0A10h
add rdi, 88h
lea rsi, aWorkspaceLlm4b_6; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 1A9h
call inline_mysql_mutex_lock_4
mov rax, [rbp+var_8]
cmp byte ptr [rax+0A30h], 0
jz short loc_41B2D
mov rdi, [rbp+var_8]
mov esi, 1
call _ma_bitmap_mark_file_changed
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_8]
add rsi, 0A10h
call write_changed_bitmap
mov [rbp+var_9], al
mov rax, [rbp+var_8]
mov byte ptr [rax+0A30h], 0
loc_41B2D:
mov rdi, [rbp+var_8]
add rdi, 0A10h
add rdi, 88h
call inline_mysql_mutex_unlock_4
loc_41B44:
jmp short $+2
loc_41B46:
mov al, [rbp+var_9]
mov [rbp+var_A], al
mov al, [rbp+var_A]
add rsp, 10h
pop rbp
retn
| char ma_bitmap_flush(long long a1)
{
char v2; // [rsp+7h] [rbp-9h]
v2 = 0;
if ( *(_BYTE *)(a1 + 2608) )
{
inline_mysql_mutex_lock_4(a1 + 2712, "/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 425LL);
if ( *(_BYTE *)(a1 + 2608) )
{
ma_bitmap_mark_file_changed(a1, 1LL);
v2 = write_changed_bitmap(a1, a1 + 2576);
*(_BYTE *)(a1 + 2608) = 0;
}
inline_mysql_mutex_unlock_4(a1 + 2712);
}
return v2;
}
| _ma_bitmap_flush:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV byte ptr [RBP + -0x9],0x0
MOV RAX,qword ptr [RBP + -0x8]
CMP byte ptr [RAX + 0xa30],0x0
JZ 0x00141b44
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0xa10
ADD RDI,0x88
LEA RSI,[0x251683]
MOV EDX,0x1a9
CALL 0x00141c20
MOV RAX,qword ptr [RBP + -0x8]
CMP byte ptr [RAX + 0xa30],0x0
JZ 0x00141b2d
MOV RDI,qword ptr [RBP + -0x8]
MOV ESI,0x1
CALL 0x00141c90
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x8]
ADD RSI,0xa10
CALL 0x00141d60
MOV byte ptr [RBP + -0x9],AL
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0xa30],0x0
LAB_00141b2d:
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0xa10
ADD RDI,0x88
CALL 0x00141ed0
LAB_00141b44:
JMP 0x00141b46
LAB_00141b46:
MOV AL,byte ptr [RBP + -0x9]
MOV byte ptr [RBP + -0xa],AL
MOV AL,byte ptr [RBP + -0xa]
ADD RSP,0x10
POP RBP
RET
|
int1 _ma_bitmap_flush(long param_1)
{
int1 local_11;
local_11 = 0;
if (*(char *)(param_1 + 0xa30) != '\0') {
inline_mysql_mutex_lock
(param_1 + 0xa98,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c",
0x1a9);
if (*(char *)(param_1 + 0xa30) != '\0') {
_ma_bitmap_mark_file_changed(param_1,1);
local_11 = write_changed_bitmap(param_1,param_1 + 0xa10);
*(int1 *)(param_1 + 0xa30) = 0;
}
inline_mysql_mutex_unlock(param_1 + 0xa98);
}
return local_11;
}
| |
55,506 | my_strerror | eloqsql/strings/my_vsnprintf.c | const char* my_strerror(char *buf, size_t len, int nr)
{
char *msg= NULL;
buf[0]= '\0'; /* failsafe */
if (nr <= 0)
{
strmake(buf, (nr == 0 ?
"Internal error/check (Not system error)" :
"Internal error < 0 (Not system error)"),
len-1);
return buf;
}
/*
These (handler-) error messages are shared by perror, as required
by the principle of least surprise.
*/
if ((nr >= HA_ERR_FIRST) && (nr <= HA_ERR_LAST))
{
msg= (char *) handler_error_messages[nr - HA_ERR_FIRST];
strmake(buf, msg, len - 1);
}
else
{
/*
On Windows, do things the Windows way. On a system that supports both
the GNU and the XSI variant, use whichever was configured (GNU); if
this choice is not advertised, use the default (POSIX/XSI). Testing
for __GNUC__ is not sufficient to determine whether this choice exists.
*/
#if defined(_WIN32)
strerror_s(buf, len, nr);
#elif ((defined _POSIX_C_SOURCE && (_POSIX_C_SOURCE >= 200112L)) || \
(defined _XOPEN_SOURCE && (_XOPEN_SOURCE >= 600))) && \
! defined _GNU_SOURCE
strerror_r(nr, buf, len); /* I can build with or without GNU */
#elif defined(__GLIBC__) && defined (_GNU_SOURCE)
char *r= strerror_r(nr, buf, len);
if (r != buf) /* Want to help, GNU? */
strmake(buf, r, len - 1); /* Then don't. */
#else
strerror_r(nr, buf, len);
#endif
}
/*
strerror() return values are implementation-dependent, so let's
be pragmatic.
*/
if (!buf[0])
strmake(buf, "unknown error", len - 1);
return buf;
} | O0 | c | my_strerror:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq $0x0, -0x28(%rbp)
movq -0x10(%rbp), %rax
movb $0x0, (%rax)
cmpl $0x0, -0x1c(%rbp)
jg 0xc7a8e
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %ecx
leaq 0xb63d(%rip), %rsi # 0xd30a3
leaq 0xb60e(%rip), %rax # 0xd307b
cmpl $0x0, %ecx
cmoveq %rax, %rsi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
callq 0xc8710
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0xc7b2a
cmpl $0x78, -0x1c(%rbp)
jl 0xc7acc
cmpl $0xc6, -0x1c(%rbp)
jg 0xc7acc
movl -0x1c(%rbp), %eax
subl $0x78, %eax
movslq %eax, %rcx
leaq 0x324d23(%rip), %rax # 0x3ec7d0
movq (%rax,%rcx,8), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
callq 0xc8710
jmp 0xc7b01
movl -0x1c(%rbp), %edi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x36bb0
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
cmpq -0x10(%rbp), %rax
je 0xc7aff
movq -0x10(%rbp), %rdi
movq -0x30(%rbp), %rsi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
callq 0xc8710
jmp 0xc7b01
movq -0x10(%rbp), %rax
cmpb $0x0, (%rax)
jne 0xc7b22
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
leaq 0xb5ac(%rip), %rsi # 0xd30c9
callq 0xc8710
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| my_strerror:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_1C], edx
mov [rbp+var_28], 0
mov rax, [rbp+var_10]
mov byte ptr [rax], 0
cmp [rbp+var_1C], 0
jg short loc_C7A8E
mov rdi, [rbp+var_10]
mov ecx, [rbp+var_1C]
lea rsi, aInternalError0; "Internal error < 0 (Not system error)"
lea rax, aInternalErrorC; "Internal error/check (Not system error)"
cmp ecx, 0
cmovz rsi, rax
mov rdx, [rbp+var_18]
sub rdx, 1
call strmake
mov rax, [rbp+var_10]
mov [rbp+var_8], rax
jmp loc_C7B2A
loc_C7A8E:
cmp [rbp+var_1C], 78h ; 'x'
jl short loc_C7ACC
cmp [rbp+var_1C], 0C6h
jg short loc_C7ACC
mov eax, [rbp+var_1C]
sub eax, 78h ; 'x'
movsxd rcx, eax
lea rax, handler_error_messages
mov rax, [rax+rcx*8]
mov [rbp+var_28], rax
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
mov rdx, [rbp+var_18]
sub rdx, 1
call strmake
jmp short loc_C7B01
loc_C7ACC:
mov edi, [rbp+var_1C]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
call _strerror_r
mov [rbp+var_30], rax
mov rax, [rbp+var_30]
cmp rax, [rbp+var_10]
jz short loc_C7AFF
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_30]
mov rdx, [rbp+var_18]
sub rdx, 1
call strmake
loc_C7AFF:
jmp short $+2
loc_C7B01:
mov rax, [rbp+var_10]
cmp byte ptr [rax], 0
jnz short loc_C7B22
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_18]
sub rdx, 1
lea rsi, aUnknownError_0; "unknown error"
call strmake
loc_C7B22:
mov rax, [rbp+var_10]
mov [rbp+var_8], rax
loc_C7B2A:
mov rax, [rbp+var_8]
add rsp, 30h
pop rbp
retn
| _BYTE * my_strerror(_BYTE *a1, long long a2, int a3)
{
const char *v3; // rsi
long long v5; // [rsp+0h] [rbp-30h]
*a1 = 0;
if ( a3 > 0 )
{
if ( a3 < 120 || a3 > 198 )
{
v5 = strerror_r((unsigned int)a3, a1, a2);
if ( (_BYTE *)v5 != a1 )
strmake(a1, v5, a2 - 1);
}
else
{
strmake(a1, handler_error_messages[a3 - 120], a2 - 1);
}
if ( !*a1 )
strmake(a1, "unknown error", a2 - 1);
return a1;
}
else
{
v3 = "Internal error < 0 (Not system error)";
if ( !a3 )
v3 = "Internal error/check (Not system error)";
strmake(a1, v3, a2 - 1);
return a1;
}
}
| my_strerror:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV dword ptr [RBP + -0x1c],EDX
MOV qword ptr [RBP + -0x28],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],0x0
CMP dword ptr [RBP + -0x1c],0x0
JG 0x001c7a8e
MOV RDI,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x1c]
LEA RSI,[0x1d30a3]
LEA RAX,[0x1d307b]
CMP ECX,0x0
CMOVZ RSI,RAX
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
CALL 0x001c8710
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001c7b2a
LAB_001c7a8e:
CMP dword ptr [RBP + -0x1c],0x78
JL 0x001c7acc
CMP dword ptr [RBP + -0x1c],0xc6
JG 0x001c7acc
MOV EAX,dword ptr [RBP + -0x1c]
SUB EAX,0x78
MOVSXD RCX,EAX
LEA RAX,[0x4ec7d0]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
CALL 0x001c8710
JMP 0x001c7b01
LAB_001c7acc:
MOV EDI,dword ptr [RBP + -0x1c]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
CALL 0x00136bb0
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x30]
CMP RAX,qword ptr [RBP + -0x10]
JZ 0x001c7aff
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x30]
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
CALL 0x001c8710
LAB_001c7aff:
JMP 0x001c7b01
LAB_001c7b01:
MOV RAX,qword ptr [RBP + -0x10]
CMP byte ptr [RAX],0x0
JNZ 0x001c7b22
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
LEA RSI,[0x1d30c9]
CALL 0x001c8710
LAB_001c7b22:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x8],RAX
LAB_001c7b2a:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x30
POP RBP
RET
|
char * my_strerror(char *param_1,size_t param_2,int param_3)
{
char *pcVar1;
*param_1 = '\0';
if (param_3 < 1) {
pcVar1 = "Internal error < 0 (Not system error)";
if (param_3 == 0) {
pcVar1 = "Internal error/check (Not system error)";
}
strmake(param_1,pcVar1,param_2 - 1);
}
else {
if ((param_3 < 0x78) || (0xc6 < param_3)) {
pcVar1 = strerror_r(param_3,param_1,param_2);
if (pcVar1 != param_1) {
strmake(param_1,pcVar1,param_2 - 1);
}
}
else {
strmake(param_1,*(int8 *)(handler_error_messages + (long)(param_3 + -0x78) * 8),
param_2 - 1);
}
if (*param_1 == '\0') {
strmake(param_1,"unknown error",param_2 - 1);
}
}
return param_1;
}
| |
55,507 | translog_relative_LSN_encode | eloqsql/storage/maria/ma_loghandler.c | static void translog_relative_LSN_encode(struct st_translog_parts *parts,
LSN base_lsn,
uint lsns, uchar *compressed_LSNs)
{
LEX_CUSTRING *part;
uint lsns_len= lsns * LSN_STORE_SIZE;
uchar buffer_src[MAX_NUMBER_OF_LSNS_PER_RECORD * LSN_STORE_SIZE];
uchar *buffer= buffer_src;
const uchar *cbuffer;
DBUG_ENTER("translog_relative_LSN_encode");
DBUG_ASSERT(parts->current != 0);
part= parts->parts + parts->current;
/* collect all LSN(s) in one chunk if it (they) is (are) divided */
if (part->length < lsns_len)
{
size_t copied= part->length;
LEX_CUSTRING *next_part;
DBUG_PRINT("info", ("Using buffer:%p", compressed_LSNs));
memcpy(buffer, part->str, part->length);
next_part= parts->parts + parts->current + 1;
do
{
DBUG_ASSERT(next_part < parts->parts + parts->elements);
if ((next_part->length + copied) < lsns_len)
{
memcpy(buffer + copied, next_part->str,
next_part->length);
copied+= next_part->length;
next_part->length= 0; next_part->str= 0;
/* delete_dynamic_element(&parts->parts, parts->current + 1); */
next_part++;
parts->current++;
part= parts->parts + parts->current;
}
else
{
size_t len= lsns_len - copied;
memcpy(buffer + copied, next_part->str, len);
copied= lsns_len;
next_part->str+= len;
next_part->length-= len;
}
} while (copied < lsns_len);
cbuffer= buffer;
}
else
{
cbuffer= part->str;
part->str+= lsns_len;
part->length-= lsns_len;
parts->current--;
part= parts->parts + parts->current;
}
{
/* Compress */
LSN ref;
int economy;
const uchar *src_ptr;
uchar *dst_ptr= compressed_LSNs + (MAX_NUMBER_OF_LSNS_PER_RECORD *
COMPRESSED_LSN_MAX_STORE_SIZE);
/*
We write the result in backward direction with no special sense or
tricks both directions are equal in complicity
*/
for (src_ptr= cbuffer + lsns_len - LSN_STORE_SIZE;
src_ptr >= (const uchar*)cbuffer;
src_ptr-= LSN_STORE_SIZE)
{
ref= lsn_korr(src_ptr);
dst_ptr= translog_put_LSN_diff(base_lsn, ref, dst_ptr);
}
part->length= (size_t)((compressed_LSNs +
(MAX_NUMBER_OF_LSNS_PER_RECORD *
COMPRESSED_LSN_MAX_STORE_SIZE)) -
dst_ptr);
economy= lsns_len - (uint)part->length;
parts->record_length-= economy;
DBUG_PRINT("info", ("new length of LSNs: %lu economy: %d",
(ulong)part->length, economy));
parts->total_record_length-= economy;
part->str= dst_ptr;
}
DBUG_VOID_RETURN;
} | O0 | c | translog_relative_LSN_encode:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x20(%rbp)
movq %rsi, -0x28(%rbp)
movl %edx, -0x2c(%rbp)
movq %rcx, -0x38(%rbp)
imull $0x7, -0x2c(%rbp), %eax
movl %eax, -0x44(%rbp)
leaq -0x16(%rbp), %rax
movq %rax, -0x50(%rbp)
jmp 0x5af18
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x20(%rbp), %rcx
movl 0x8(%rcx), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
movl -0x44(%rbp), %ecx
cmpq %rcx, %rax
jae 0x5b081
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x60(%rbp)
jmp 0x5af54
movq -0x50(%rbp), %rdi
movq -0x40(%rbp), %rax
movq (%rax), %rsi
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rdx
callq 0x2a090
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x20(%rbp), %rcx
movl 0x8(%rcx), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
addq $0x10, %rax
movq %rax, -0x68(%rbp)
jmp 0x5af8c
jmp 0x5af8e
movq -0x68(%rbp), %rax
movq 0x8(%rax), %rax
addq -0x60(%rbp), %rax
movl -0x44(%rbp), %ecx
cmpq %rcx, %rax
jae 0x5b01a
movq -0x50(%rbp), %rdi
addq -0x60(%rbp), %rdi
movq -0x68(%rbp), %rax
movq (%rax), %rsi
movq -0x68(%rbp), %rax
movq 0x8(%rax), %rdx
callq 0x2a090
movq -0x68(%rbp), %rax
movq 0x8(%rax), %rax
addq -0x60(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x68(%rbp), %rax
movq $0x0, 0x8(%rax)
movq -0x68(%rbp), %rax
movq $0x0, (%rax)
movq -0x68(%rbp), %rax
addq $0x10, %rax
movq %rax, -0x68(%rbp)
movq -0x20(%rbp), %rax
movl 0x8(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x8(%rax)
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x20(%rbp), %rcx
movl 0x8(%rcx), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
jmp 0x5b065
movl -0x44(%rbp), %eax
subq -0x60(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x50(%rbp), %rdi
addq -0x60(%rbp), %rdi
movq -0x68(%rbp), %rax
movq (%rax), %rsi
movq -0x70(%rbp), %rdx
callq 0x2a090
movl -0x44(%rbp), %eax
movq %rax, -0x60(%rbp)
movq -0x70(%rbp), %rcx
movq -0x68(%rbp), %rax
addq (%rax), %rcx
movq %rcx, (%rax)
movq -0x70(%rbp), %rdx
movq -0x68(%rbp), %rax
movq 0x8(%rax), %rcx
subq %rdx, %rcx
movq %rcx, 0x8(%rax)
jmp 0x5b067
movq -0x60(%rbp), %rax
movl -0x44(%rbp), %ecx
cmpq %rcx, %rax
jb 0x5af8a
movq -0x50(%rbp), %rax
movq %rax, -0x58(%rbp)
jmp 0x5b0d9
movq -0x40(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movl -0x44(%rbp), %edx
movq -0x40(%rbp), %rax
movq (%rax), %rcx
movl %edx, %edx
addq %rdx, %rcx
movq %rcx, (%rax)
movl -0x44(%rbp), %eax
movl %eax, %edx
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rcx
subq %rdx, %rcx
movq %rcx, 0x8(%rax)
movq -0x20(%rbp), %rax
movl 0x8(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0x8(%rax)
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x20(%rbp), %rcx
movl 0x8(%rcx), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x38(%rbp), %rax
addq $0x12, %rax
movq %rax, -0x90(%rbp)
movq -0x58(%rbp), %rax
movl -0x44(%rbp), %ecx
addq %rcx, %rax
addq $-0x7, %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rax
cmpq -0x58(%rbp), %rax
jb 0x5b17a
movq -0x88(%rbp), %rax
movzbl (%rax), %eax
movq -0x88(%rbp), %rcx
movzbl 0x1(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x88(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movl %eax, %eax
shlq $0x20, %rax
movq -0x88(%rbp), %rcx
movl 0x3(%rcx), %ecx
orq %rcx, %rax
movq %rax, -0x78(%rbp)
movq -0x28(%rbp), %rdi
movq -0x78(%rbp), %rsi
movq -0x90(%rbp), %rdx
callq 0x5c480
movq %rax, -0x90(%rbp)
movq -0x88(%rbp), %rax
addq $-0x7, %rax
movq %rax, -0x88(%rbp)
jmp 0x5b0fd
movq -0x38(%rbp), %rcx
addq $0x12, %rcx
movq -0x90(%rbp), %rax
subq %rax, %rcx
movq -0x40(%rbp), %rax
movq %rcx, 0x8(%rax)
movl -0x44(%rbp), %eax
movq -0x40(%rbp), %rcx
movq 0x8(%rcx), %rcx
subl %ecx, %eax
movl %eax, -0x7c(%rbp)
movl -0x7c(%rbp), %edx
movq -0x20(%rbp), %rax
movl (%rax), %ecx
subl %edx, %ecx
movl %ecx, (%rax)
jmp 0x5b1b3
movl -0x7c(%rbp), %edx
movq -0x20(%rbp), %rax
movl 0x4(%rax), %ecx
subl %edx, %ecx
movl %ecx, 0x4(%rax)
movq -0x90(%rbp), %rcx
movq -0x40(%rbp), %rax
movq %rcx, (%rax)
jmp 0x5b1d2
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x5b1ed
addq $0x90, %rsp
popq %rbp
retq
callq 0x2a270
nopw %cs:(%rax,%rax)
| translog_relative_LSN_encode:
push rbp
mov rbp, rsp
sub rsp, 90h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_20], rdi
mov [rbp+var_28], rsi
mov [rbp+var_2C], edx
mov [rbp+var_38], rcx
imul eax, [rbp+var_2C], 7
mov [rbp+var_44], eax
lea rax, [rbp+var_16]
mov [rbp+var_50], rax
jmp short $+2
loc_5AF18:
mov rax, [rbp+var_20]
mov rax, [rax+10h]
mov rcx, [rbp+var_20]
mov ecx, [rcx+8]
shl rcx, 4
add rax, rcx
mov [rbp+var_40], rax
mov rax, [rbp+var_40]
mov rax, [rax+8]
mov ecx, [rbp+var_44]
cmp rax, rcx
jnb loc_5B081
mov rax, [rbp+var_40]
mov rax, [rax+8]
mov [rbp+var_60], rax
jmp short $+2
loc_5AF54:
mov rdi, [rbp+var_50]
mov rax, [rbp+var_40]
mov rsi, [rax]
mov rax, [rbp+var_40]
mov rdx, [rax+8]
call _memcpy
mov rax, [rbp+var_20]
mov rax, [rax+10h]
mov rcx, [rbp+var_20]
mov ecx, [rcx+8]
shl rcx, 4
add rax, rcx
add rax, 10h
mov [rbp+var_68], rax
loc_5AF8A:
jmp short $+2
loc_5AF8C:
jmp short $+2
loc_5AF8E:
mov rax, [rbp+var_68]
mov rax, [rax+8]
add rax, [rbp+var_60]
mov ecx, [rbp+var_44]
cmp rax, rcx
jnb short loc_5B01A
mov rdi, [rbp+var_50]
add rdi, [rbp+var_60]
mov rax, [rbp+var_68]
mov rsi, [rax]
mov rax, [rbp+var_68]
mov rdx, [rax+8]
call _memcpy
mov rax, [rbp+var_68]
mov rax, [rax+8]
add rax, [rbp+var_60]
mov [rbp+var_60], rax
mov rax, [rbp+var_68]
mov qword ptr [rax+8], 0
mov rax, [rbp+var_68]
mov qword ptr [rax], 0
mov rax, [rbp+var_68]
add rax, 10h
mov [rbp+var_68], rax
mov rax, [rbp+var_20]
mov ecx, [rax+8]
add ecx, 1
mov [rax+8], ecx
mov rax, [rbp+var_20]
mov rax, [rax+10h]
mov rcx, [rbp+var_20]
mov ecx, [rcx+8]
shl rcx, 4
add rax, rcx
mov [rbp+var_40], rax
jmp short loc_5B065
loc_5B01A:
mov eax, [rbp+var_44]
sub rax, [rbp+var_60]
mov [rbp+var_70], rax
mov rdi, [rbp+var_50]
add rdi, [rbp+var_60]
mov rax, [rbp+var_68]
mov rsi, [rax]
mov rdx, [rbp+var_70]
call _memcpy
mov eax, [rbp+var_44]
mov [rbp+var_60], rax
mov rcx, [rbp+var_70]
mov rax, [rbp+var_68]
add rcx, [rax]
mov [rax], rcx
mov rdx, [rbp+var_70]
mov rax, [rbp+var_68]
mov rcx, [rax+8]
sub rcx, rdx
mov [rax+8], rcx
loc_5B065:
jmp short $+2
loc_5B067:
mov rax, [rbp+var_60]
mov ecx, [rbp+var_44]
cmp rax, rcx
jb loc_5AF8A
mov rax, [rbp+var_50]
mov [rbp+var_58], rax
jmp short loc_5B0D9
loc_5B081:
mov rax, [rbp+var_40]
mov rax, [rax]
mov [rbp+var_58], rax
mov edx, [rbp+var_44]
mov rax, [rbp+var_40]
mov rcx, [rax]
mov edx, edx
add rcx, rdx
mov [rax], rcx
mov eax, [rbp+var_44]
mov edx, eax
mov rax, [rbp+var_40]
mov rcx, [rax+8]
sub rcx, rdx
mov [rax+8], rcx
mov rax, [rbp+var_20]
mov ecx, [rax+8]
add ecx, 0FFFFFFFFh
mov [rax+8], ecx
mov rax, [rbp+var_20]
mov rax, [rax+10h]
mov rcx, [rbp+var_20]
mov ecx, [rcx+8]
shl rcx, 4
add rax, rcx
mov [rbp+var_40], rax
loc_5B0D9:
mov rax, [rbp+var_38]
add rax, 12h
mov [rbp+var_90], rax
mov rax, [rbp+var_58]
mov ecx, [rbp+var_44]
add rax, rcx
add rax, 0FFFFFFFFFFFFFFF9h
mov [rbp+var_88], rax
loc_5B0FD:
mov rax, [rbp+var_88]
cmp rax, [rbp+var_58]
jb short loc_5B17A
mov rax, [rbp+var_88]
movzx eax, byte ptr [rax]
mov rcx, [rbp+var_88]
movzx ecx, byte ptr [rcx+1]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_88]
movzx ecx, byte ptr [rcx+2]
shl ecx, 10h
or eax, ecx
mov eax, eax
shl rax, 20h
mov rcx, [rbp+var_88]
mov ecx, [rcx+3]
or rax, rcx
mov [rbp+var_78], rax
mov rdi, [rbp+var_28]
mov rsi, [rbp+var_78]
mov rdx, [rbp+var_90]
call translog_put_LSN_diff
mov [rbp+var_90], rax
mov rax, [rbp+var_88]
add rax, 0FFFFFFFFFFFFFFF9h
mov [rbp+var_88], rax
jmp short loc_5B0FD
loc_5B17A:
mov rcx, [rbp+var_38]
add rcx, 12h
mov rax, [rbp+var_90]
sub rcx, rax
mov rax, [rbp+var_40]
mov [rax+8], rcx
mov eax, [rbp+var_44]
mov rcx, [rbp+var_40]
mov rcx, [rcx+8]
sub eax, ecx
mov [rbp+var_7C], eax
mov edx, [rbp+var_7C]
mov rax, [rbp+var_20]
mov ecx, [rax]
sub ecx, edx
mov [rax], ecx
jmp short $+2
loc_5B1B3:
mov edx, [rbp+var_7C]
mov rax, [rbp+var_20]
mov ecx, [rax+4]
sub ecx, edx
mov [rax+4], ecx
mov rcx, [rbp+var_90]
mov rax, [rbp+var_40]
mov [rax], rcx
jmp short $+2
loc_5B1D2:
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_5B1ED
add rsp, 90h
pop rbp
retn
loc_5B1ED:
call ___stack_chk_fail
| unsigned long long translog_relative_LSN_encode(long long a1, long long a2, int a3, long long a4)
{
long long v5; // [rsp+0h] [rbp-90h]
unsigned __int16 *i; // [rsp+8h] [rbp-88h]
int v7; // [rsp+14h] [rbp-7Ch]
unsigned long long v8; // [rsp+20h] [rbp-70h]
_QWORD *v9; // [rsp+28h] [rbp-68h]
unsigned long long v10; // [rsp+30h] [rbp-60h]
unsigned __int16 *v11; // [rsp+38h] [rbp-58h]
unsigned int v12; // [rsp+4Ch] [rbp-44h]
long long *v13; // [rsp+50h] [rbp-40h]
long long v15; // [rsp+70h] [rbp-20h]
_BYTE v16[14]; // [rsp+7Ah] [rbp-16h] BYREF
unsigned long long v17; // [rsp+88h] [rbp-8h]
v17 = __readfsqword(0x28u);
v15 = a1;
v12 = 7 * a3;
v13 = (long long *)(16LL * *(unsigned int *)(v15 + 8) + *(_QWORD *)(v15 + 16));
if ( v13[1] >= (unsigned long long)(unsigned int)(7 * a3) )
{
v11 = (unsigned __int16 *)*v13;
*v13 += v12;
v13[1] -= v12;
v13 = (long long *)(16LL * (unsigned int)--*(_DWORD *)(v15 + 8) + *(_QWORD *)(v15 + 16));
}
else
{
v10 = v13[1];
memcpy(v16, *v13, v10);
v9 = (_QWORD *)(16LL * *(unsigned int *)(v15 + 8) + *(_QWORD *)(v15 + 16) + 16);
do
{
if ( v10 + v9[1] >= v12 )
{
v8 = v12 - v10;
memcpy(&v16[v10], *v9, v8);
v10 = v12;
*v9 += v8;
v9[1] -= v8;
}
else
{
memcpy(&v16[v10], *v9, v9[1]);
v10 += v9[1];
v9[1] = 0LL;
*v9 = 0LL;
v9 += 2;
v13 = (long long *)(16LL * (unsigned int)++*(_DWORD *)(v15 + 8) + *(_QWORD *)(v15 + 16));
}
}
while ( v10 < v12 );
v11 = (unsigned __int16 *)v16;
}
v5 = a4 + 18;
for ( i = (unsigned __int16 *)((char *)v11 + v12 - 7); i >= v11; i = (unsigned __int16 *)((char *)i - 7) )
v5 = translog_put_LSN_diff(
a2,
*(unsigned int *)((char *)i + 3) | ((unsigned long long)((*((unsigned __int8 *)i + 2) << 16) | (unsigned int)*i) << 32),
v5);
v13[1] = a4 + 18 - v5;
v7 = v12 - v13[1];
*(_DWORD *)v15 -= v7;
*(_DWORD *)(v15 + 4) -= v7;
*v13 = v5;
return __readfsqword(0x28u);
}
| translog_relative_LSN_encode:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x20],RDI
MOV qword ptr [RBP + -0x28],RSI
MOV dword ptr [RBP + -0x2c],EDX
MOV qword ptr [RBP + -0x38],RCX
IMUL EAX,dword ptr [RBP + -0x2c],0x7
MOV dword ptr [RBP + -0x44],EAX
LEA RAX,[RBP + -0x16]
MOV qword ptr [RBP + -0x50],RAX
JMP 0x0015af18
LAB_0015af18:
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RCX + 0x8]
SHL RCX,0x4
ADD RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x8]
MOV ECX,dword ptr [RBP + -0x44]
CMP RAX,RCX
JNC 0x0015b081
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x60],RAX
JMP 0x0015af54
LAB_0015af54:
MOV RDI,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RAX + 0x8]
CALL 0x0012a090
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RCX + 0x8]
SHL RCX,0x4
ADD RAX,RCX
ADD RAX,0x10
MOV qword ptr [RBP + -0x68],RAX
LAB_0015af8a:
JMP 0x0015af8c
LAB_0015af8c:
JMP 0x0015af8e
LAB_0015af8e:
MOV RAX,qword ptr [RBP + -0x68]
MOV RAX,qword ptr [RAX + 0x8]
ADD RAX,qword ptr [RBP + -0x60]
MOV ECX,dword ptr [RBP + -0x44]
CMP RAX,RCX
JNC 0x0015b01a
MOV RDI,qword ptr [RBP + -0x50]
ADD RDI,qword ptr [RBP + -0x60]
MOV RAX,qword ptr [RBP + -0x68]
MOV RSI,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x68]
MOV RDX,qword ptr [RAX + 0x8]
CALL 0x0012a090
MOV RAX,qword ptr [RBP + -0x68]
MOV RAX,qword ptr [RAX + 0x8]
ADD RAX,qword ptr [RBP + -0x60]
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RAX + 0x8],0x0
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RAX],0x0
MOV RAX,qword ptr [RBP + -0x68]
ADD RAX,0x10
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RAX + 0x8]
ADD ECX,0x1
MOV dword ptr [RAX + 0x8],ECX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RCX + 0x8]
SHL RCX,0x4
ADD RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
JMP 0x0015b065
LAB_0015b01a:
MOV EAX,dword ptr [RBP + -0x44]
SUB RAX,qword ptr [RBP + -0x60]
MOV qword ptr [RBP + -0x70],RAX
MOV RDI,qword ptr [RBP + -0x50]
ADD RDI,qword ptr [RBP + -0x60]
MOV RAX,qword ptr [RBP + -0x68]
MOV RSI,qword ptr [RAX]
MOV RDX,qword ptr [RBP + -0x70]
CALL 0x0012a090
MOV EAX,dword ptr [RBP + -0x44]
MOV qword ptr [RBP + -0x60],RAX
MOV RCX,qword ptr [RBP + -0x70]
MOV RAX,qword ptr [RBP + -0x68]
ADD RCX,qword ptr [RAX]
MOV qword ptr [RAX],RCX
MOV RDX,qword ptr [RBP + -0x70]
MOV RAX,qword ptr [RBP + -0x68]
MOV RCX,qword ptr [RAX + 0x8]
SUB RCX,RDX
MOV qword ptr [RAX + 0x8],RCX
LAB_0015b065:
JMP 0x0015b067
LAB_0015b067:
MOV RAX,qword ptr [RBP + -0x60]
MOV ECX,dword ptr [RBP + -0x44]
CMP RAX,RCX
JC 0x0015af8a
MOV RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x58],RAX
JMP 0x0015b0d9
LAB_0015b081:
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x58],RAX
MOV EDX,dword ptr [RBP + -0x44]
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RAX]
MOV EDX,EDX
ADD RCX,RDX
MOV qword ptr [RAX],RCX
MOV EAX,dword ptr [RBP + -0x44]
MOV EDX,EAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RAX + 0x8]
SUB RCX,RDX
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RAX + 0x8]
ADD ECX,-0x1
MOV dword ptr [RAX + 0x8],ECX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RCX + 0x8]
SHL RCX,0x4
ADD RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
LAB_0015b0d9:
MOV RAX,qword ptr [RBP + -0x38]
ADD RAX,0x12
MOV qword ptr [RBP + -0x90],RAX
MOV RAX,qword ptr [RBP + -0x58]
MOV ECX,dword ptr [RBP + -0x44]
ADD RAX,RCX
ADD RAX,-0x7
MOV qword ptr [RBP + -0x88],RAX
LAB_0015b0fd:
MOV RAX,qword ptr [RBP + -0x88]
CMP RAX,qword ptr [RBP + -0x58]
JC 0x0015b17a
MOV RAX,qword ptr [RBP + -0x88]
MOVZX EAX,byte ptr [RAX]
MOV RCX,qword ptr [RBP + -0x88]
MOVZX ECX,byte ptr [RCX + 0x1]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x88]
MOVZX ECX,byte ptr [RCX + 0x2]
SHL ECX,0x10
OR EAX,ECX
MOV EAX,EAX
SHL RAX,0x20
MOV RCX,qword ptr [RBP + -0x88]
MOV ECX,dword ptr [RCX + 0x3]
OR RAX,RCX
MOV qword ptr [RBP + -0x78],RAX
MOV RDI,qword ptr [RBP + -0x28]
MOV RSI,qword ptr [RBP + -0x78]
MOV RDX,qword ptr [RBP + -0x90]
CALL 0x0015c480
MOV qword ptr [RBP + -0x90],RAX
MOV RAX,qword ptr [RBP + -0x88]
ADD RAX,-0x7
MOV qword ptr [RBP + -0x88],RAX
JMP 0x0015b0fd
LAB_0015b17a:
MOV RCX,qword ptr [RBP + -0x38]
ADD RCX,0x12
MOV RAX,qword ptr [RBP + -0x90]
SUB RCX,RAX
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RAX + 0x8],RCX
MOV EAX,dword ptr [RBP + -0x44]
MOV RCX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RCX + 0x8]
SUB EAX,ECX
MOV dword ptr [RBP + -0x7c],EAX
MOV EDX,dword ptr [RBP + -0x7c]
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RAX]
SUB ECX,EDX
MOV dword ptr [RAX],ECX
JMP 0x0015b1b3
LAB_0015b1b3:
MOV EDX,dword ptr [RBP + -0x7c]
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RAX + 0x4]
SUB ECX,EDX
MOV dword ptr [RAX + 0x4],ECX
MOV RCX,qword ptr [RBP + -0x90]
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RAX],RCX
JMP 0x0015b1d2
LAB_0015b1d2:
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x0015b1ed
ADD RSP,0x90
POP RBP
RET
LAB_0015b1ed:
CALL 0x0012a270
|
void translog_relative_LSN_encode(int *param_1,int8 param_2,int param_3,long param_4)
{
int3 *puVar1;
uint uVar2;
int iVar3;
size_t __n;
long in_FS_OFFSET;
long local_98;
int3 *local_90;
long *local_70;
ulong local_68;
int3 *local_60;
long *local_48;
int3 local_1e [3];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
uVar2 = param_3 * 7;
local_60 = local_1e;
local_48 = (long *)(*(long *)(param_1 + 4) + (ulong)(uint)param_1[2] * 0x10);
if ((ulong)local_48[1] < (ulong)uVar2) {
local_68 = local_48[1];
memcpy(local_60,(void *)*local_48,local_48[1]);
local_70 = (long *)(*(long *)(param_1 + 4) + (ulong)(uint)param_1[2] * 0x10 + 0x10);
do {
if (local_70[1] + local_68 < (ulong)uVar2) {
memcpy((void *)((long)local_60 + local_68),(void *)*local_70,local_70[1]);
local_68 = local_70[1] + local_68;
local_70[1] = 0;
*local_70 = 0;
local_70 = local_70 + 2;
param_1[2] = param_1[2] + 1;
local_48 = (long *)(*(long *)(param_1 + 4) + (ulong)(uint)param_1[2] * 0x10);
}
else {
__n = uVar2 - local_68;
memcpy((void *)((long)local_60 + local_68),(void *)*local_70,__n);
local_68 = (ulong)uVar2;
*local_70 = __n + *local_70;
local_70[1] = local_70[1] - __n;
}
} while (local_68 < uVar2);
}
else {
local_60 = (int3 *)*local_48;
*local_48 = *local_48 + (ulong)uVar2;
local_48[1] = local_48[1] - (ulong)uVar2;
param_1[2] = param_1[2] + -1;
local_48 = (long *)(*(long *)(param_1 + 4) + (ulong)(uint)param_1[2] * 0x10);
}
local_98 = param_4 + 0x12;
puVar1 = (int3 *)((long)local_60 + (ulong)uVar2);
while (local_90 = (int3 *)((long)puVar1 + -7), local_60 <= local_90) {
local_98 = translog_put_LSN_diff
(param_2,(ulong)CONCAT34(*local_90,*(int4 *)(puVar1 + -1)),local_98);
puVar1 = local_90;
}
local_48[1] = (param_4 + 0x12) - local_98;
iVar3 = uVar2 - (int)local_48[1];
*param_1 = *param_1 - iVar3;
param_1[1] = param_1[1] - iVar3;
*local_48 = local_98;
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return;
}
| |
55,508 | stbi_loadf | monkey531[P]llama/examples/llava/../../common/stb_image.h | STBIDEF float *stbi_loadf(char const *filename, int *x, int *y, int *comp, int req_comp)
{
float *result;
FILE *f = stbi__fopen(filename, "rb");
if (!f) return stbi__errpf("can't fopen", "Unable to open file");
result = stbi_loadf_from_file(f,x,y,comp,req_comp);
fclose(f);
return result;
} | O1 | c | stbi_loadf:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl %r8d, %ebx
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
leaq 0xe72aa(%rip), %rsi # 0x1104f5
callq 0x1de50
testq %rax, %rax
je 0x2927c
movq %rax, %r13
movq %rax, %rdi
movq %r12, %rsi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
callq 0x292a2
movq %rax, %rbx
movq %r13, %rdi
callq 0x1dc00
movq %rbx, %rax
jmp 0x29298
movq %fs:0x0, %rax
leaq 0xe4409(%rip), %rcx # 0x10d698
movq %rcx, -0x20(%rax)
xorl %eax, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
| stbi_loadf:
push r15
push r14
push r13
push r12
push rbx
mov ebx, r8d
mov r14, rcx
mov r15, rdx
mov r12, rsi
lea rsi, aCrb+2; "rb"
call _fopen
test rax, rax
jz short loc_2927C
mov r13, rax
mov rdi, rax
mov rsi, r12
mov rdx, r15
mov rcx, r14
mov r8d, ebx
call stbi_loadf_from_file
mov rbx, rax
mov rdi, r13
call _fclose
mov rax, rbx
jmp short loc_29298
loc_2927C:
mov rax, fs:0
lea rcx, aCanTFopen; "can't fopen"
mov [rax-20h], rcx
xor eax, eax
loc_29298:
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| long long stbi_loadf(long long a1, long long a2, long long a3, long long a4, unsigned int a5)
{
long long v8; // rax
long long v9; // r13
long long v10; // rbx
v8 = fopen(a1, "rb");
if ( v8 )
{
v9 = v8;
v10 = stbi_loadf_from_file(v8, a2, a3, a4, a5);
fclose(v9);
return v10;
}
else
{
*(_QWORD *)(__readfsqword(0) - 32) = "can't fopen";
return 0LL;
}
}
| stbi_loadf:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV EBX,R8D
MOV R14,RCX
MOV R15,RDX
MOV R12,RSI
LEA RSI,[0x2104f5]
CALL 0x0011de50
TEST RAX,RAX
JZ 0x0012927c
MOV R13,RAX
MOV RDI,RAX
MOV RSI,R12
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
CALL 0x001292a2
MOV RBX,RAX
MOV RDI,R13
CALL 0x0011dc00
MOV RAX,RBX
JMP 0x00129298
LAB_0012927c:
MOV RAX,qword ptr FS:[0x0]
LEA RCX,[0x20d698]
MOV qword ptr [RAX + -0x20],RCX
XOR EAX,EAX
LAB_00129298:
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
int8
stbi_loadf(char *param_1,int8 param_2,int8 param_3,int8 param_4,int4 param_5
)
{
FILE *__stream;
int8 uVar1;
long *in_FS_OFFSET;
__stream = fopen(param_1,"rb");
if (__stream == (FILE *)0x0) {
*(char **)(*in_FS_OFFSET + -0x20) = "can\'t fopen";
uVar1 = 0;
}
else {
uVar1 = stbi_loadf_from_file(__stream,param_2,param_3,param_4,param_5);
fclose(__stream);
}
return uVar1;
}
| |
55,509 | stbi_loadf | monkey531[P]llama/examples/llava/../../common/stb_image.h | STBIDEF float *stbi_loadf(char const *filename, int *x, int *y, int *comp, int req_comp)
{
float *result;
FILE *f = stbi__fopen(filename, "rb");
if (!f) return stbi__errpf("can't fopen", "Unable to open file");
result = stbi_loadf_from_file(f,x,y,comp,req_comp);
fclose(f);
return result;
} | O2 | c | stbi_loadf:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl %r8d, %ebx
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
leaq 0x9aa6b(%rip), %rsi # 0xc93e5
callq 0x26e80
testq %rax, %rax
je 0x2e9ab
movq %rax, %r13
movq %rax, %rdi
movq %r12, %rsi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
callq 0x2e9d1
movq %rax, %rbx
movq %r13, %rdi
callq 0x26c30
movq %rbx, %rax
jmp 0x2e9c7
movq %fs:0x0, %rax
leaq 0x97bba(%rip), %rcx # 0xc6578
movq %rcx, -0x20(%rax)
xorl %eax, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
| stbi_loadf:
push r15
push r14
push r13
push r12
push rbx
mov ebx, r8d
mov r14, rcx
mov r15, rdx
mov r12, rsi
lea rsi, aCrb+2; "rb"
call _fopen
test rax, rax
jz short loc_2E9AB
mov r13, rax
mov rdi, rax
mov rsi, r12
mov rdx, r15
mov rcx, r14
mov r8d, ebx
call stbi_loadf_from_file
mov rbx, rax
mov rdi, r13
call _fclose
mov rax, rbx
jmp short loc_2E9C7
loc_2E9AB:
mov rax, fs:0
lea rcx, aCanTFopen; "can't fopen"
mov [rax-20h], rcx
xor eax, eax
loc_2E9C7:
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| long long stbi_loadf(long long a1, long long a2, long long a3, long long a4, unsigned int a5)
{
long long v8; // rax
long long v9; // r13
long long v10; // rbx
v8 = fopen(a1, "rb");
if ( v8 )
{
v9 = v8;
v10 = stbi_loadf_from_file(v8, a2, a3, a4, a5);
fclose(v9);
return v10;
}
else
{
*(_QWORD *)(__readfsqword(0) - 32) = "can't fopen";
return 0LL;
}
}
| stbi_loadf:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV EBX,R8D
MOV R14,RCX
MOV R15,RDX
MOV R12,RSI
LEA RSI,[0x1c93e5]
CALL 0x00126e80
TEST RAX,RAX
JZ 0x0012e9ab
MOV R13,RAX
MOV RDI,RAX
MOV RSI,R12
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
CALL 0x0012e9d1
MOV RBX,RAX
MOV RDI,R13
CALL 0x00126c30
MOV RAX,RBX
JMP 0x0012e9c7
LAB_0012e9ab:
MOV RAX,qword ptr FS:[0x0]
LEA RCX,[0x1c6578]
MOV qword ptr [RAX + -0x20],RCX
XOR EAX,EAX
LAB_0012e9c7:
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
int8
stbi_loadf(char *param_1,int8 param_2,int8 param_3,int8 param_4,int4 param_5
)
{
FILE *__stream;
int8 uVar1;
long *in_FS_OFFSET;
__stream = fopen(param_1,"rb");
if (__stream == (FILE *)0x0) {
*(char **)(*in_FS_OFFSET + -0x20) = "can\'t fopen";
uVar1 = 0;
}
else {
uVar1 = stbi_loadf_from_file(__stream,param_2,param_3,param_4,param_5);
fclose(__stream);
}
return uVar1;
}
| |
55,510 | lunasvg::SVGRectElement::SVGRectElement(lunasvg::Document*) | dmazzella[P]pylunasvg/lunasvg/source/svggeometryelement.cpp | SVGRectElement::SVGRectElement(Document* document)
: SVGGeometryElement(document, ElementID::Rect)
, m_x(PropertyID::X, LengthDirection::Horizontal, LengthNegativeMode::Allow)
, m_y(PropertyID::Y, LengthDirection::Vertical, LengthNegativeMode::Allow)
, m_width(PropertyID::Width, LengthDirection::Horizontal, LengthNegativeMode::Forbid)
, m_height(PropertyID::Height, LengthDirection::Vertical, LengthNegativeMode::Forbid)
, m_rx(PropertyID::Rx, LengthDirection::Horizontal, LengthNegativeMode::Forbid)
, m_ry(PropertyID::Ry, LengthDirection::Vertical, LengthNegativeMode::Forbid)
{
addProperty(m_x);
addProperty(m_y);
addProperty(m_width);
addProperty(m_height);
addProperty(m_rx);
addProperty(m_ry);
} | O0 | cpp | lunasvg::SVGRectElement::SVGRectElement(lunasvg::Document*):
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x30(%rbp)
movq -0x10(%rbp), %rsi
movl $0x11, %edx
callq 0x2d000
movq -0x30(%rbp), %rdi
leaq 0x9448f(%rip), %rax # 0xc2530
movq %rax, (%rdi)
addq $0x118, %rdi # imm = 0x118
movq %rdi, -0x28(%rbp)
movl $0x4b, %esi
xorps %xmm0, %xmm0
xorl %r8d, %r8d
movl %r8d, %edx
movl %r8d, %ecx
callq 0x20d00
jmp 0x2e0c7
movq -0x30(%rbp), %rdi
addq $0x130, %rdi # imm = 0x130
movq %rdi, -0x38(%rbp)
movl $0x4e, %esi
movl $0x1, %edx
xorps %xmm0, %xmm0
xorl %r8d, %r8d
movl %r8d, %ecx
callq 0x20d00
jmp 0x2e0f0
movq -0x30(%rbp), %rdi
addq $0x148, %rdi # imm = 0x148
movq %rdi, -0x40(%rbp)
movl $0x4a, %esi
movl $0x1, %ecx
xorps %xmm0, %xmm0
xorl %r8d, %r8d
movl %r8d, %edx
callq 0x20d00
jmp 0x2e119
movq -0x30(%rbp), %rdi
addq $0x160, %rdi # imm = 0x160
movq %rdi, -0x48(%rbp)
movl $0x1b, %esi
movl $0x1, %ecx
xorps %xmm0, %xmm0
xorl %r8d, %r8d
movl %ecx, %edx
callq 0x20d00
jmp 0x2e141
movq -0x30(%rbp), %rdi
addq $0x178, %rdi # imm = 0x178
movq %rdi, -0x50(%rbp)
movl $0x36, %esi
movl $0x1, %ecx
xorps %xmm0, %xmm0
xorl %r8d, %r8d
movl %r8d, %edx
callq 0x20d00
jmp 0x2e16a
movq -0x30(%rbp), %rdi
addq $0x190, %rdi # imm = 0x190
movq %rdi, -0x58(%rbp)
movl $0x37, %esi
movl $0x1, %ecx
xorps %xmm0, %xmm0
xorl %r8d, %r8d
movl %ecx, %edx
callq 0x20d00
jmp 0x2e192
movq -0x30(%rbp), %rdi
movq %rdi, %rsi
addq $0x118, %rsi # imm = 0x118
callq 0x19a70
jmp 0x2e1a7
movq -0x30(%rbp), %rdi
movq %rdi, %rsi
addq $0x130, %rsi # imm = 0x130
callq 0x19a70
jmp 0x2e1bc
movq -0x30(%rbp), %rdi
movq %rdi, %rsi
addq $0x148, %rsi # imm = 0x148
callq 0x19a70
jmp 0x2e1d1
movq -0x30(%rbp), %rdi
movq %rdi, %rsi
addq $0x160, %rsi # imm = 0x160
callq 0x19a70
jmp 0x2e1e6
movq -0x30(%rbp), %rdi
movq %rdi, %rsi
addq $0x178, %rsi # imm = 0x178
callq 0x19a70
jmp 0x2e1fb
movq -0x30(%rbp), %rdi
movq %rdi, %rsi
addq $0x190, %rsi # imm = 0x190
callq 0x19a70
jmp 0x2e210
addq $0x60, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x2e2af
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x2e2a6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x2e29d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x2e294
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x2e28b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x2e282
movq -0x58(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
callq 0xfb10
movq -0x50(%rbp), %rdi
callq 0xfb10
movq -0x48(%rbp), %rdi
callq 0xfb10
movq -0x40(%rbp), %rdi
callq 0xfb10
movq -0x38(%rbp), %rdi
callq 0xfb10
movq -0x28(%rbp), %rdi
callq 0xfb10
movq -0x30(%rbp), %rdi
callq 0x24260
movq -0x18(%rbp), %rdi
callq 0xb6c0
nopw %cs:(%rax,%rax)
| _ZN7lunasvg14SVGRectElementC2EPNS_8DocumentE:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rdi, [rbp+var_8]
mov [rbp+var_30], rdi
mov rsi, [rbp+var_10]
mov edx, 11h
call _ZN7lunasvg18SVGGeometryElementC2EPNS_8DocumentENS_9ElementIDE; lunasvg::SVGGeometryElement::SVGGeometryElement(lunasvg::Document *,lunasvg::ElementID)
mov rdi, [rbp+var_30]
lea rax, off_C2530
mov [rdi], rax
add rdi, 118h
mov [rbp+var_28], rdi
mov esi, 4Bh ; 'K'
xorps xmm0, xmm0
xor r8d, r8d
mov edx, r8d
mov ecx, r8d
call _ZN7lunasvg9SVGLengthC2ENS_10PropertyIDENS_15LengthDirectionENS_18LengthNegativeModeEfNS_11LengthUnitsE; lunasvg::SVGLength::SVGLength(lunasvg::PropertyID,lunasvg::LengthDirection,lunasvg::LengthNegativeMode,float,lunasvg::LengthUnits)
jmp short $+2
loc_2E0C7:
mov rdi, [rbp+var_30]
add rdi, 130h
mov [rbp+var_38], rdi
mov esi, 4Eh ; 'N'
mov edx, 1
xorps xmm0, xmm0
xor r8d, r8d
mov ecx, r8d
call _ZN7lunasvg9SVGLengthC2ENS_10PropertyIDENS_15LengthDirectionENS_18LengthNegativeModeEfNS_11LengthUnitsE; lunasvg::SVGLength::SVGLength(lunasvg::PropertyID,lunasvg::LengthDirection,lunasvg::LengthNegativeMode,float,lunasvg::LengthUnits)
jmp short $+2
loc_2E0F0:
mov rdi, [rbp+var_30]
add rdi, 148h
mov [rbp+var_40], rdi
mov esi, 4Ah ; 'J'
mov ecx, 1
xorps xmm0, xmm0
xor r8d, r8d
mov edx, r8d
call _ZN7lunasvg9SVGLengthC2ENS_10PropertyIDENS_15LengthDirectionENS_18LengthNegativeModeEfNS_11LengthUnitsE; lunasvg::SVGLength::SVGLength(lunasvg::PropertyID,lunasvg::LengthDirection,lunasvg::LengthNegativeMode,float,lunasvg::LengthUnits)
jmp short $+2
loc_2E119:
mov rdi, [rbp+var_30]
add rdi, 160h
mov [rbp+var_48], rdi
mov esi, 1Bh
mov ecx, 1
xorps xmm0, xmm0
xor r8d, r8d
mov edx, ecx
call _ZN7lunasvg9SVGLengthC2ENS_10PropertyIDENS_15LengthDirectionENS_18LengthNegativeModeEfNS_11LengthUnitsE; lunasvg::SVGLength::SVGLength(lunasvg::PropertyID,lunasvg::LengthDirection,lunasvg::LengthNegativeMode,float,lunasvg::LengthUnits)
jmp short $+2
loc_2E141:
mov rdi, [rbp+var_30]
add rdi, 178h
mov [rbp+var_50], rdi
mov esi, 36h ; '6'
mov ecx, 1
xorps xmm0, xmm0
xor r8d, r8d
mov edx, r8d
call _ZN7lunasvg9SVGLengthC2ENS_10PropertyIDENS_15LengthDirectionENS_18LengthNegativeModeEfNS_11LengthUnitsE; lunasvg::SVGLength::SVGLength(lunasvg::PropertyID,lunasvg::LengthDirection,lunasvg::LengthNegativeMode,float,lunasvg::LengthUnits)
jmp short $+2
loc_2E16A:
mov rdi, [rbp+var_30]
add rdi, 190h
mov [rbp+var_58], rdi
mov esi, 37h ; '7'
mov ecx, 1
xorps xmm0, xmm0
xor r8d, r8d
mov edx, ecx
call _ZN7lunasvg9SVGLengthC2ENS_10PropertyIDENS_15LengthDirectionENS_18LengthNegativeModeEfNS_11LengthUnitsE; lunasvg::SVGLength::SVGLength(lunasvg::PropertyID,lunasvg::LengthDirection,lunasvg::LengthNegativeMode,float,lunasvg::LengthUnits)
jmp short $+2
loc_2E192:
mov rdi, [rbp+var_30]; this
mov rsi, rdi
add rsi, 118h; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
jmp short $+2
loc_2E1A7:
mov rdi, [rbp+var_30]; this
mov rsi, rdi
add rsi, 130h; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
jmp short $+2
loc_2E1BC:
mov rdi, [rbp+var_30]; this
mov rsi, rdi
add rsi, 148h; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
jmp short $+2
loc_2E1D1:
mov rdi, [rbp+var_30]; this
mov rsi, rdi
add rsi, 160h; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
jmp short $+2
loc_2E1E6:
mov rdi, [rbp+var_30]; this
mov rsi, rdi
add rsi, 178h; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
jmp short $+2
loc_2E1FB:
mov rdi, [rbp+var_30]; this
mov rsi, rdi
add rsi, 190h; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
jmp short $+2
loc_2E210:
add rsp, 60h
pop rbp
retn
mov rcx, rax
mov eax, edx
mov [rbp+var_18], rcx
mov [rbp+var_1C], eax
jmp loc_2E2AF
mov rcx, rax
mov eax, edx
mov [rbp+var_18], rcx
mov [rbp+var_1C], eax
jmp short loc_2E2A6
mov rcx, rax
mov eax, edx
mov [rbp+var_18], rcx
mov [rbp+var_1C], eax
jmp short loc_2E29D
mov rcx, rax
mov eax, edx
mov [rbp+var_18], rcx
mov [rbp+var_1C], eax
jmp short loc_2E294
mov rcx, rax
mov eax, edx
mov [rbp+var_18], rcx
mov [rbp+var_1C], eax
jmp short loc_2E28B
mov rcx, rax
mov eax, edx
mov [rbp+var_18], rcx
mov [rbp+var_1C], eax
jmp short loc_2E282
mov rdi, [rbp+var_58]; this
mov rcx, rax
mov eax, edx
mov [rbp+var_18], rcx
mov [rbp+var_1C], eax
call _ZN7lunasvg9SVGLengthD2Ev; lunasvg::SVGLength::~SVGLength()
loc_2E282:
mov rdi, [rbp+var_50]; this
call _ZN7lunasvg9SVGLengthD2Ev; lunasvg::SVGLength::~SVGLength()
loc_2E28B:
mov rdi, [rbp+var_48]; this
call _ZN7lunasvg9SVGLengthD2Ev; lunasvg::SVGLength::~SVGLength()
loc_2E294:
mov rdi, [rbp+var_40]; this
call _ZN7lunasvg9SVGLengthD2Ev; lunasvg::SVGLength::~SVGLength()
loc_2E29D:
mov rdi, [rbp+var_38]; this
call _ZN7lunasvg9SVGLengthD2Ev; lunasvg::SVGLength::~SVGLength()
loc_2E2A6:
mov rdi, [rbp+var_28]; this
call _ZN7lunasvg9SVGLengthD2Ev; lunasvg::SVGLength::~SVGLength()
loc_2E2AF:
mov rdi, [rbp+var_30]; this
call _ZN7lunasvg18SVGGeometryElementD2Ev; lunasvg::SVGGeometryElement::~SVGGeometryElement()
mov rdi, [rbp+var_18]
call __Unwind_Resume
| long long lunasvg::SVGRectElement::SVGRectElement(lunasvg::SVGRectElement *this, lunasvg::Document *a2)
{
lunasvg::SVGGeometryElement::SVGGeometryElement((long long)this, a2, 17);
*(_QWORD *)this = off_C2530;
lunasvg::SVGLength::SVGLength((long long)this + 280, 0x4Bu, 0, 0, 0, 0.0);
lunasvg::SVGLength::SVGLength((long long)this + 304, 0x4Eu, 1, 0, 0, 0.0);
lunasvg::SVGLength::SVGLength((long long)this + 328, 0x4Au, 0, 1, 0, 0.0);
lunasvg::SVGLength::SVGLength((long long)this + 352, 0x1Bu, 1, 1, 0, 0.0);
lunasvg::SVGLength::SVGLength((long long)this + 376, 0x36u, 0, 1, 0, 0.0);
lunasvg::SVGLength::SVGLength((long long)this + 400, 0x37u, 1, 1, 0, 0.0);
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 280));
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 304));
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 328));
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 352));
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 376));
return lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 400));
}
| SVGRectElement:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RDI,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x30],RDI
MOV RSI,qword ptr [RBP + -0x10]
MOV EDX,0x11
CALL 0x0012d000
MOV RDI,qword ptr [RBP + -0x30]
LEA RAX,[0x1c2530]
MOV qword ptr [RDI],RAX
ADD RDI,0x118
MOV qword ptr [RBP + -0x28],RDI
LAB_0012e0af:
MOV ESI,0x4b
XORPS XMM0,XMM0
XOR R8D,R8D
MOV EDX,R8D
MOV ECX,R8D
CALL 0x00120d00
JMP 0x0012e0c7
LAB_0012e0c7:
MOV RDI,qword ptr [RBP + -0x30]
ADD RDI,0x130
MOV qword ptr [RBP + -0x38],RDI
LAB_0012e0d6:
MOV ESI,0x4e
MOV EDX,0x1
XORPS XMM0,XMM0
XOR R8D,R8D
MOV ECX,R8D
CALL 0x00120d00
JMP 0x0012e0f0
LAB_0012e0f0:
MOV RDI,qword ptr [RBP + -0x30]
ADD RDI,0x148
MOV qword ptr [RBP + -0x40],RDI
LAB_0012e0ff:
MOV ESI,0x4a
MOV ECX,0x1
XORPS XMM0,XMM0
XOR R8D,R8D
MOV EDX,R8D
CALL 0x00120d00
JMP 0x0012e119
LAB_0012e119:
MOV RDI,qword ptr [RBP + -0x30]
ADD RDI,0x160
MOV qword ptr [RBP + -0x48],RDI
LAB_0012e128:
MOV ESI,0x1b
MOV ECX,0x1
XORPS XMM0,XMM0
XOR R8D,R8D
MOV EDX,ECX
CALL 0x00120d00
JMP 0x0012e141
LAB_0012e141:
MOV RDI,qword ptr [RBP + -0x30]
ADD RDI,0x178
MOV qword ptr [RBP + -0x50],RDI
LAB_0012e150:
MOV ESI,0x36
MOV ECX,0x1
XORPS XMM0,XMM0
XOR R8D,R8D
MOV EDX,R8D
CALL 0x00120d00
JMP 0x0012e16a
LAB_0012e16a:
MOV RDI,qword ptr [RBP + -0x30]
ADD RDI,0x190
MOV qword ptr [RBP + -0x58],RDI
LAB_0012e179:
MOV ESI,0x37
MOV ECX,0x1
XORPS XMM0,XMM0
XOR R8D,R8D
MOV EDX,ECX
CALL 0x00120d00
JMP 0x0012e192
LAB_0012e192:
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,RDI
ADD RSI,0x118
LAB_0012e1a0:
CALL 0x00119a70
JMP 0x0012e1a7
LAB_0012e1a7:
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,RDI
ADD RSI,0x130
CALL 0x00119a70
JMP 0x0012e1bc
LAB_0012e1bc:
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,RDI
ADD RSI,0x148
CALL 0x00119a70
JMP 0x0012e1d1
LAB_0012e1d1:
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,RDI
ADD RSI,0x160
CALL 0x00119a70
JMP 0x0012e1e6
LAB_0012e1e6:
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,RDI
ADD RSI,0x178
CALL 0x00119a70
JMP 0x0012e1fb
LAB_0012e1fb:
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,RDI
ADD RSI,0x190
CALL 0x00119a70
LAB_0012e20e:
JMP 0x0012e210
LAB_0012e210:
ADD RSP,0x60
POP RBP
RET
|
/* lunasvg::SVGRectElement::SVGRectElement(lunasvg::Document*) */
void __thiscall lunasvg::SVGRectElement::SVGRectElement(SVGRectElement *this,Document *param_1)
{
SVGGeometryElement::SVGGeometryElement((SVGGeometryElement *)this,param_1,0x11);
*(int ***)this = &PTR__SVGRectElement_001c2530;
/* try { // try from 0012e0af to 0012e0c4 has its CatchHandler @ 0012e216 */
SVGLength::SVGLength((SVGLength *)0x0,this + 0x118,0x4b,0,0);
/* try { // try from 0012e0d6 to 0012e0ed has its CatchHandler @ 0012e227 */
SVGLength::SVGLength((SVGLength *)0x0,this + 0x130,0x4e,1,0);
/* try { // try from 0012e0ff to 0012e116 has its CatchHandler @ 0012e235 */
SVGLength::SVGLength((SVGLength *)0x0,this + 0x148,0x4a,0,1);
/* try { // try from 0012e128 to 0012e13e has its CatchHandler @ 0012e243 */
SVGLength::SVGLength((SVGLength *)0x0,this + 0x160,0x1b,1,1,0);
/* try { // try from 0012e150 to 0012e167 has its CatchHandler @ 0012e251 */
SVGLength::SVGLength((SVGLength *)0x0,this + 0x178,0x36,0,1);
/* try { // try from 0012e179 to 0012e18f has its CatchHandler @ 0012e25f */
SVGLength::SVGLength((SVGLength *)0x0,this + 400,0x37,1,1,0);
/* try { // try from 0012e1a0 to 0012e20d has its CatchHandler @ 0012e26d */
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x118));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x130));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x148));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x160));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x178));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 400));
return;
}
| |
55,511 | lunasvg::SVGRectElement::SVGRectElement(lunasvg::Document*) | dmazzella[P]pylunasvg/lunasvg/source/svggeometryelement.cpp | SVGRectElement::SVGRectElement(Document* document)
: SVGGeometryElement(document, ElementID::Rect)
, m_x(PropertyID::X, LengthDirection::Horizontal, LengthNegativeMode::Allow)
, m_y(PropertyID::Y, LengthDirection::Vertical, LengthNegativeMode::Allow)
, m_width(PropertyID::Width, LengthDirection::Horizontal, LengthNegativeMode::Forbid)
, m_height(PropertyID::Height, LengthDirection::Vertical, LengthNegativeMode::Forbid)
, m_rx(PropertyID::Rx, LengthDirection::Horizontal, LengthNegativeMode::Forbid)
, m_ry(PropertyID::Ry, LengthDirection::Vertical, LengthNegativeMode::Forbid)
{
addProperty(m_x);
addProperty(m_y);
addProperty(m_width);
addProperty(m_height);
addProperty(m_rx);
addProperty(m_ry);
} | O1 | cpp | lunasvg::SVGRectElement::SVGRectElement(lunasvg::Document*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movl $0x11, %edx
callq 0x102f8
leaq 0x44fa0(%rip), %rax # 0x593c0
movq %rax, (%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x98(%rbx)
xorl %eax, %eax
movq %rax, 0xa8(%rbx)
movabsq $0x408000003f800000, %rcx # imm = 0x408000003F800000
movq %rcx, 0xb0(%rbx)
movl %eax, 0xb8(%rbx)
movw $0x0, 0xbc(%rbx)
movups %xmm0, 0xc0(%rbx)
movups %xmm0, 0xd0(%rbx)
leaq 0x2ed0d(%rip), %rcx # 0x43178
movl (%rcx), %ecx
movl %ecx, 0xe0(%rbx)
movl %eax, 0xe4(%rbx)
movq %rax, 0xe8(%rbx)
movl %ecx, 0xf0(%rbx)
movups %xmm0, 0xf4(%rbx)
movups %xmm0, 0x102(%rbx)
leaq 0x45075(%rip), %rax # 0x59510
movq %rax, (%rbx)
leaq 0x118(%rbx), %r14
movq %r14, %rdi
movl $0x4b, %esi
callq 0x1f3bc
leaq 0x46957(%rip), %r15 # 0x5ae10
addq $0x10, %r15
movq %r15, 0x118(%rbx)
movw $0x0, 0x121(%rbx)
movl $0x0, 0x124(%rbx)
movb $0x0, 0x128(%rbx)
leaq 0x130(%rbx), %r12
movq %r12, %rdi
movl $0x4e, %esi
callq 0x1f3bc
movq %r15, 0x130(%rbx)
movw $0x1, 0x139(%rbx)
movl $0x0, 0x13c(%rbx)
movb $0x0, 0x140(%rbx)
leaq 0x148(%rbx), %r13
movq %r13, %rdi
movl $0x4a, %esi
callq 0x1f3bc
movq %r13, 0x8(%rsp)
movq %r12, 0x10(%rsp)
movq %r15, 0x148(%rbx)
movw $0x100, 0x151(%rbx) # imm = 0x100
movl $0x0, 0x154(%rbx)
movb $0x0, 0x158(%rbx)
leaq 0x160(%rbx), %r13
movq %r13, %rdi
movl $0x1b, %esi
callq 0x1f3bc
movq %r14, %r12
movq %r15, 0x160(%rbx)
movw $0x101, 0x169(%rbx) # imm = 0x101
movl $0x0, 0x16c(%rbx)
movb $0x0, 0x170(%rbx)
leaq 0x178(%rbx), %rbp
movq %rbp, %rdi
movl $0x36, %esi
callq 0x1f3bc
movq %r15, 0x178(%rbx)
movw $0x100, 0x181(%rbx) # imm = 0x100
movl $0x0, 0x184(%rbx)
movb $0x0, 0x188(%rbx)
leaq 0x190(%rbx), %r14
movq %r14, %rdi
movl $0x37, %esi
callq 0x1f3bc
movq %r15, 0x190(%rbx)
movw $0x101, 0x199(%rbx) # imm = 0x101
movl $0x0, 0x19c(%rbx)
movb $0x0, 0x1a0(%rbx)
movq %rbx, %rdi
movq %r12, %rsi
callq 0xfbfe
movq %rbx, %rdi
movq 0x10(%rsp), %rsi
callq 0xfbfe
movq %rbx, %rdi
movq 0x8(%rsp), %rsi
callq 0xfbfe
movq %rbx, %rdi
movq %r13, %rsi
callq 0xfbfe
movq %rbx, %rdi
movq %rbp, %rsi
callq 0xfbfe
movq %rbx, %rdi
movq %r14, %rsi
callq 0xfbfe
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x14655
jmp 0x14655
jmp 0x14655
jmp 0x14655
jmp 0x14655
jmp 0x14655
movq %rax, %r14
movq %rbx, %rdi
callq 0x15038
movq %r14, %rdi
callq 0xa5c0
| _ZN7lunasvg14SVGRectElementC2EPNS_8DocumentE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov rbx, rdi
mov edx, 11h
call _ZN7lunasvg18SVGGraphicsElementC2EPNS_8DocumentENS_9ElementIDE; lunasvg::SVGGraphicsElement::SVGGraphicsElement(lunasvg::Document *,lunasvg::ElementID)
lea rax, off_593C0
mov [rbx], rax
xorps xmm0, xmm0
movups xmmword ptr [rbx+98h], xmm0
xor eax, eax
mov [rbx+0A8h], rax
mov rcx, 408000003F800000h
mov [rbx+0B0h], rcx
mov [rbx+0B8h], eax
mov word ptr [rbx+0BCh], 0
movups xmmword ptr [rbx+0C0h], xmm0
movups xmmword ptr [rbx+0D0h], xmm0
lea rcx, _ZN7lunasvg5Color11TransparentE; lunasvg::Color::Transparent
mov ecx, [rcx]
mov [rbx+0E0h], ecx
mov [rbx+0E4h], eax
mov [rbx+0E8h], rax
mov [rbx+0F0h], ecx
movups xmmword ptr [rbx+0F4h], xmm0
movups xmmword ptr [rbx+102h], xmm0
lea rax, off_59510
mov [rbx], rax
lea r14, [rbx+118h]
mov rdi, r14
mov esi, 4Bh ; 'K'
call _ZN7lunasvg11SVGPropertyC2ENS_10PropertyIDE; lunasvg::SVGProperty::SVGProperty(lunasvg::PropertyID)
lea r15, _ZTVN7lunasvg9SVGLengthE; `vtable for'lunasvg::SVGLength
add r15, 10h
mov [rbx+118h], r15
mov word ptr [rbx+121h], 0
mov dword ptr [rbx+124h], 0
mov byte ptr [rbx+128h], 0
lea r12, [rbx+130h]
mov rdi, r12
mov esi, 4Eh ; 'N'
call _ZN7lunasvg11SVGPropertyC2ENS_10PropertyIDE; lunasvg::SVGProperty::SVGProperty(lunasvg::PropertyID)
mov [rbx+130h], r15
mov word ptr [rbx+139h], 1
mov dword ptr [rbx+13Ch], 0
mov byte ptr [rbx+140h], 0
lea r13, [rbx+148h]
mov rdi, r13
mov esi, 4Ah ; 'J'
call _ZN7lunasvg11SVGPropertyC2ENS_10PropertyIDE; lunasvg::SVGProperty::SVGProperty(lunasvg::PropertyID)
mov [rsp+48h+var_40], r13
mov [rsp+48h+var_38], r12
mov [rbx+148h], r15
mov word ptr [rbx+151h], 100h
mov dword ptr [rbx+154h], 0
mov byte ptr [rbx+158h], 0
lea r13, [rbx+160h]
mov rdi, r13
mov esi, 1Bh
call _ZN7lunasvg11SVGPropertyC2ENS_10PropertyIDE; lunasvg::SVGProperty::SVGProperty(lunasvg::PropertyID)
mov r12, r14
mov [rbx+160h], r15
mov word ptr [rbx+169h], 101h
mov dword ptr [rbx+16Ch], 0
mov byte ptr [rbx+170h], 0
lea rbp, [rbx+178h]
mov rdi, rbp
mov esi, 36h ; '6'
call _ZN7lunasvg11SVGPropertyC2ENS_10PropertyIDE; lunasvg::SVGProperty::SVGProperty(lunasvg::PropertyID)
mov [rbx+178h], r15
mov word ptr [rbx+181h], 100h
mov dword ptr [rbx+184h], 0
mov byte ptr [rbx+188h], 0
lea r14, [rbx+190h]
mov rdi, r14
mov esi, 37h ; '7'
call _ZN7lunasvg11SVGPropertyC2ENS_10PropertyIDE; lunasvg::SVGProperty::SVGProperty(lunasvg::PropertyID)
mov [rbx+190h], r15
mov word ptr [rbx+199h], 101h
mov dword ptr [rbx+19Ch], 0
mov byte ptr [rbx+1A0h], 0
mov rdi, rbx; this
mov rsi, r12; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
mov rdi, rbx; this
mov rsi, [rsp+48h+var_38]; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
mov rdi, rbx; this
mov rsi, [rsp+48h+var_40]; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
mov rdi, rbx; this
mov rsi, r13; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
mov rdi, rbx; this
mov rsi, rbp; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
mov rdi, rbx; this
mov rsi, r14; lunasvg::SVGProperty *
call _ZN7lunasvg10SVGElement11addPropertyERNS_11SVGPropertyE; lunasvg::SVGElement::addProperty(lunasvg::SVGProperty &)
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_14655
jmp short loc_14655
jmp short loc_14655
jmp short loc_14655
jmp short loc_14655
jmp short $+2
loc_14655:
mov r14, rax
mov rdi, rbx; this
call _ZN7lunasvg18SVGGeometryElementD2Ev; lunasvg::SVGGeometryElement::~SVGGeometryElement()
mov rdi, r14
call __Unwind_Resume
| _QWORD * lunasvg::SVGRectElement::SVGRectElement(lunasvg::SVGRectElement *this, lunasvg::Document *a2)
{
lunasvg::SVGGraphicsElement::SVGGraphicsElement((long long)this, (long long)a2, 17);
*(_QWORD *)this = &off_593C0;
*(_OWORD *)((char *)this + 152) = 0LL;
*((_QWORD *)this + 21) = 0LL;
*((_QWORD *)this + 22) = 0x408000003F800000LL;
*((_DWORD *)this + 46) = 0;
*((_WORD *)this + 94) = 0;
*((_OWORD *)this + 12) = 0LL;
*((_OWORD *)this + 13) = 0LL;
*((_DWORD *)this + 56) = lunasvg::Color::Transparent;
*((_DWORD *)this + 57) = 0;
*((_QWORD *)this + 29) = 0LL;
*((_DWORD *)this + 60) = lunasvg::Color::Transparent;
*(_OWORD *)((char *)this + 244) = 0LL;
*(_OWORD *)((char *)this + 258) = 0LL;
*(_QWORD *)this = off_59510;
lunasvg::SVGProperty::SVGProperty((char *)this + 280, 75LL);
*((_QWORD *)this + 35) = &`vtable for'lunasvg::SVGLength + 2;
*(_WORD *)((char *)this + 289) = 0;
*((_DWORD *)this + 73) = 0;
*((_BYTE *)this + 296) = 0;
lunasvg::SVGProperty::SVGProperty((char *)this + 304, 78LL);
*((_QWORD *)this + 38) = &`vtable for'lunasvg::SVGLength + 2;
*(_WORD *)((char *)this + 313) = 1;
*((_DWORD *)this + 79) = 0;
*((_BYTE *)this + 320) = 0;
lunasvg::SVGProperty::SVGProperty((char *)this + 328, 74LL);
*((_QWORD *)this + 41) = &`vtable for'lunasvg::SVGLength + 2;
*(_WORD *)((char *)this + 337) = 256;
*((_DWORD *)this + 85) = 0;
*((_BYTE *)this + 344) = 0;
lunasvg::SVGProperty::SVGProperty((char *)this + 352, 27LL);
*((_QWORD *)this + 44) = &`vtable for'lunasvg::SVGLength + 2;
*(_WORD *)((char *)this + 361) = 257;
*((_DWORD *)this + 91) = 0;
*((_BYTE *)this + 368) = 0;
lunasvg::SVGProperty::SVGProperty((char *)this + 376, 54LL);
*((_QWORD *)this + 47) = &`vtable for'lunasvg::SVGLength + 2;
*(_WORD *)((char *)this + 385) = 256;
*((_DWORD *)this + 97) = 0;
*((_BYTE *)this + 392) = 0;
lunasvg::SVGProperty::SVGProperty((char *)this + 400, 55LL);
*((_QWORD *)this + 50) = &`vtable for'lunasvg::SVGLength + 2;
*(_WORD *)((char *)this + 409) = 257;
*((_DWORD *)this + 103) = 0;
*((_BYTE *)this + 416) = 0;
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 280));
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 304));
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 328));
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 352));
lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 376));
return lunasvg::SVGElement::addProperty(this, (lunasvg::SVGRectElement *)((char *)this + 400));
}
| SVGRectElement:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV RBX,RDI
MOV EDX,0x11
CALL 0x001102f8
LEA RAX,[0x1593c0]
MOV qword ptr [RBX],RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x98],XMM0
XOR EAX,EAX
MOV qword ptr [RBX + 0xa8],RAX
MOV RCX,0x408000003f800000
MOV qword ptr [RBX + 0xb0],RCX
MOV dword ptr [RBX + 0xb8],EAX
MOV word ptr [RBX + 0xbc],0x0
MOVUPS xmmword ptr [RBX + 0xc0],XMM0
MOVUPS xmmword ptr [RBX + 0xd0],XMM0
LEA RCX,[0x143178]
MOV ECX,dword ptr [RCX]
MOV dword ptr [RBX + 0xe0],ECX
MOV dword ptr [RBX + 0xe4],EAX
MOV qword ptr [RBX + 0xe8],RAX
MOV dword ptr [RBX + 0xf0],ECX
MOVUPS xmmword ptr [RBX + 0xf4],XMM0
MOVUPS xmmword ptr [RBX + 0x102],XMM0
LEA RAX,[0x159510]
MOV qword ptr [RBX],RAX
LEA R14,[RBX + 0x118]
LAB_001144a5:
MOV RDI,R14
MOV ESI,0x4b
CALL 0x0011f3bc
LEA R15,[0x15ae10]
ADD R15,0x10
MOV qword ptr [RBX + 0x118],R15
MOV word ptr [RBX + 0x121],0x0
MOV dword ptr [RBX + 0x124],0x0
MOV byte ptr [RBX + 0x128],0x0
LEA R12,[RBX + 0x130]
LAB_001144e5:
MOV RDI,R12
MOV ESI,0x4e
CALL 0x0011f3bc
MOV qword ptr [RBX + 0x130],R15
MOV word ptr [RBX + 0x139],0x1
MOV dword ptr [RBX + 0x13c],0x0
MOV byte ptr [RBX + 0x140],0x0
LEA R13,[RBX + 0x148]
LAB_0011451a:
MOV RDI,R13
MOV ESI,0x4a
CALL 0x0011f3bc
MOV qword ptr [RSP + 0x8],R13
MOV qword ptr [RSP + 0x10],R12
MOV qword ptr [RBX + 0x148],R15
MOV word ptr [RBX + 0x151],0x100
MOV dword ptr [RBX + 0x154],0x0
MOV byte ptr [RBX + 0x158],0x0
LEA R13,[RBX + 0x160]
LAB_00114559:
MOV RDI,R13
MOV ESI,0x1b
CALL 0x0011f3bc
MOV R12,R14
MOV qword ptr [RBX + 0x160],R15
MOV word ptr [RBX + 0x169],0x101
MOV dword ptr [RBX + 0x16c],0x0
MOV byte ptr [RBX + 0x170],0x0
LEA RBP,[RBX + 0x178]
LAB_00114591:
MOV RDI,RBP
MOV ESI,0x36
CALL 0x0011f3bc
MOV qword ptr [RBX + 0x178],R15
MOV word ptr [RBX + 0x181],0x100
MOV dword ptr [RBX + 0x184],0x0
MOV byte ptr [RBX + 0x188],0x0
LEA R14,[RBX + 0x190]
LAB_001145c6:
MOV RDI,R14
MOV ESI,0x37
CALL 0x0011f3bc
MOV qword ptr [RBX + 0x190],R15
MOV word ptr [RBX + 0x199],0x101
MOV dword ptr [RBX + 0x19c],0x0
MOV byte ptr [RBX + 0x1a0],0x0
LAB_001145f4:
MOV RDI,RBX
MOV RSI,R12
CALL 0x0010fbfe
MOV RDI,RBX
MOV RSI,qword ptr [RSP + 0x10]
CALL 0x0010fbfe
MOV RDI,RBX
MOV RSI,qword ptr [RSP + 0x8]
CALL 0x0010fbfe
MOV RDI,RBX
MOV RSI,R13
CALL 0x0010fbfe
MOV RDI,RBX
MOV RSI,RBP
CALL 0x0010fbfe
MOV RDI,RBX
MOV RSI,R14
CALL 0x0010fbfe
LAB_0011463a:
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* lunasvg::SVGRectElement::SVGRectElement(lunasvg::Document*) */
void __thiscall lunasvg::SVGRectElement::SVGRectElement(SVGRectElement *this,Document *param_1)
{
int4 uVar1;
SVGGraphicsElement::SVGGraphicsElement((SVGGraphicsElement *)this,param_1,0x11);
*(int ***)this = &PTR__SVGGeometryElement_001593c0;
*(int8 *)(this + 0x98) = 0;
*(int8 *)(this + 0xa0) = 0;
*(int8 *)(this + 0xa8) = 0;
*(int8 *)(this + 0xb0) = 0x408000003f800000;
*(int4 *)(this + 0xb8) = 0;
*(int2 *)(this + 0xbc) = 0;
*(int8 *)(this + 0xc0) = 0;
*(int8 *)(this + 200) = 0;
*(int8 *)(this + 0xd0) = 0;
*(int8 *)(this + 0xd8) = 0;
uVar1 = Color::Transparent;
*(int4 *)(this + 0xe0) = Color::Transparent;
*(int4 *)(this + 0xe4) = 0;
*(int8 *)(this + 0xe8) = 0;
*(int4 *)(this + 0xf0) = uVar1;
*(int8 *)(this + 0xf4) = 0;
*(int8 *)(this + 0xfc) = 0;
*(int8 *)(this + 0x102) = 0;
*(int8 *)(this + 0x10a) = 0;
*(int ***)this = &PTR__SVGRectElement_00159510;
/* try { // try from 001144a5 to 001144b1 has its CatchHandler @ 00114653 */
SVGProperty::SVGProperty((SVGProperty *)(this + 0x118),0x4b);
*(int ***)(this + 0x118) = &PTR__SVGProperty_0015ae20;
*(int2 *)(this + 0x121) = 0;
*(int4 *)(this + 0x124) = 0;
this[0x128] = (SVGRectElement)0x0;
/* try { // try from 001144e5 to 001144f1 has its CatchHandler @ 00114651 */
SVGProperty::SVGProperty((SVGProperty *)(this + 0x130),0x4e);
*(int ***)(this + 0x130) = &PTR__SVGProperty_0015ae20;
*(int2 *)(this + 0x139) = 1;
*(int4 *)(this + 0x13c) = 0;
this[0x140] = (SVGRectElement)0x0;
/* try { // try from 0011451a to 00114526 has its CatchHandler @ 0011464f */
SVGProperty::SVGProperty((SVGProperty *)(this + 0x148),0x4a);
*(int ***)(this + 0x148) = &PTR__SVGProperty_0015ae20;
*(int2 *)(this + 0x151) = 0x100;
*(int4 *)(this + 0x154) = 0;
this[0x158] = (SVGRectElement)0x0;
/* try { // try from 00114559 to 00114565 has its CatchHandler @ 0011464d */
SVGProperty::SVGProperty((SVGProperty *)(this + 0x160),0x1b);
*(int ***)(this + 0x160) = &PTR__SVGProperty_0015ae20;
*(int2 *)(this + 0x169) = 0x101;
*(int4 *)(this + 0x16c) = 0;
this[0x170] = (SVGRectElement)0x0;
/* try { // try from 00114591 to 0011459d has its CatchHandler @ 0011464b */
SVGProperty::SVGProperty((SVGProperty *)(this + 0x178),0x36);
*(int ***)(this + 0x178) = &PTR__SVGProperty_0015ae20;
*(int2 *)(this + 0x181) = 0x100;
*(int4 *)(this + 0x184) = 0;
this[0x188] = (SVGRectElement)0x0;
/* try { // try from 001145c6 to 001145d2 has its CatchHandler @ 00114649 */
SVGProperty::SVGProperty((SVGProperty *)(this + 400),0x37);
*(int ***)(this + 400) = &PTR__SVGProperty_0015ae20;
*(int2 *)(this + 0x199) = 0x101;
*(int4 *)(this + 0x19c) = 0;
this[0x1a0] = (SVGRectElement)0x0;
/* try { // try from 001145f4 to 00114639 has its CatchHandler @ 00114655 */
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x118));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x130));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x148));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x160));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 0x178));
SVGElement::addProperty((SVGElement *)this,(SVGProperty *)(this + 400));
return;
}
| |
55,512 | Cached_item_str::cmp() | eloqsql/sql/item_buff.cc | bool Cached_item_str::cmp(void)
{
String *res;
bool tmp;
if ((res=item->val_str(&tmp_value)))
res->length(MY_MIN(res->length(), value_max_length));
if (null_value != item->null_value)
{
if ((null_value= item->null_value))
return TRUE; // New value was null
tmp=TRUE;
}
else if (null_value)
return 0; // new and old value was null
else
tmp= sortcmp(&value,res,item->collation.collation) != 0;
if (tmp)
value.copy(*res); // Remember for next cmp
return tmp;
} | O0 | cpp | Cached_item_str::cmp():
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rsi
movq %rsi, -0x28(%rbp)
movq 0x10(%rsi), %rdi
addq $0x40, %rsi
movq (%rdi), %rax
callq *0x108(%rax)
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
je 0x918a9d
movq -0x18(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x30(%rbp)
movq -0x18(%rbp), %rdi
addq $0x8, %rdi
callq 0x48dc60
movq -0x28(%rbp), %rcx
cmpl 0x18(%rcx), %eax
jae 0x918a83
movq -0x18(%rbp), %rdi
addq $0x8, %rdi
callq 0x48dc60
movl %eax, -0x34(%rbp)
jmp 0x918a8d
movq -0x28(%rbp), %rax
movl 0x18(%rax), %eax
movl %eax, -0x34(%rbp)
movq -0x30(%rbp), %rdi
movl -0x34(%rbp), %eax
movl %eax, %eax
movl %eax, %esi
callq 0x48e0e0
movq -0x28(%rbp), %rcx
movb 0x8(%rcx), %al
andb $0x1, %al
movzbl %al, %eax
movq 0x10(%rcx), %rcx
movb 0x64(%rcx), %cl
andb $0x1, %cl
movzbl %cl, %ecx
cmpl %ecx, %eax
je 0x918ae5
movq -0x28(%rbp), %rcx
movq 0x10(%rcx), %rax
movb 0x64(%rax), %al
movb %al, %dl
andb $0x1, %dl
movb %dl, 0x8(%rcx)
testb $0x1, %al
jne 0x918ad3
jmp 0x918adc
movb $0x1, -0x1(%rbp)
jmp 0x918b89
movb $0x1, -0x19(%rbp)
jmp 0x918b6a
movq -0x28(%rbp), %rax
testb $0x1, 0x8(%rax)
je 0x918af8
movb $0x0, -0x1(%rbp)
jmp 0x918b89
movq -0x28(%rbp), %rcx
addq $0x20, %rcx
movq %rcx, -0x48(%rbp)
xorl %eax, %eax
cmpq $0x0, %rcx
movq %rax, -0x40(%rbp)
je 0x918b1c
movq -0x48(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x18(%rbp), %rcx
movq %rcx, -0x58(%rbp)
xorl %eax, %eax
cmpq $0x0, %rcx
movq %rax, -0x50(%rbp)
je 0x918b44
movq -0x58(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x50(%rbp)
movq -0x60(%rbp), %rdi
movq -0x28(%rbp), %rax
movq -0x50(%rbp), %rsi
movq 0x10(%rax), %rax
movq 0x10(%rax), %rdx
callq 0x4923b0
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movb %al, -0x19(%rbp)
jmp 0x918b6a
testb $0x1, -0x19(%rbp)
je 0x918b81
movq -0x28(%rbp), %rdi
addq $0x20, %rdi
movq -0x18(%rbp), %rsi
callq 0x558a00
movb -0x19(%rbp), %al
andb $0x1, %al
movb %al, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x60, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _ZN15Cached_item_str3cmpEv:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_10], rdi
mov rsi, [rbp+var_10]
mov [rbp+var_28], rsi
mov rdi, [rsi+10h]
add rsi, 40h ; '@'
mov rax, [rdi]
call qword ptr [rax+108h]
mov [rbp+var_18], rax
cmp rax, 0
jz short loc_918A9D
mov rax, [rbp+var_18]
add rax, 8
mov [rbp+var_34+4], rax
mov rdi, [rbp+var_18]
add rdi, 8; this
call _ZNK13Binary_string6lengthEv; Binary_string::length(void)
mov rcx, [rbp+var_28]
cmp eax, [rcx+18h]
jnb short loc_918A83
mov rdi, [rbp+var_18]
add rdi, 8; this
call _ZNK13Binary_string6lengthEv; Binary_string::length(void)
mov dword ptr [rbp+var_34], eax
jmp short loc_918A8D
loc_918A83:
mov rax, [rbp+var_28]
mov eax, [rax+18h]
mov dword ptr [rbp+var_34], eax
loc_918A8D:
mov rdi, [rbp+var_34+4]; this
mov eax, dword ptr [rbp+var_34]
mov eax, eax
mov esi, eax; unsigned __int64
call _ZN13Binary_string6lengthEm; Binary_string::length(ulong)
loc_918A9D:
mov rcx, [rbp+var_28]
mov al, [rcx+8]
and al, 1
movzx eax, al
mov rcx, [rcx+10h]
mov cl, [rcx+64h]
and cl, 1
movzx ecx, cl
cmp eax, ecx
jz short loc_918AE5
mov rcx, [rbp+var_28]
mov rax, [rcx+10h]
mov al, [rax+64h]
mov dl, al
and dl, 1
mov [rcx+8], dl
test al, 1
jnz short loc_918AD3
jmp short loc_918ADC
loc_918AD3:
mov [rbp+var_1], 1
jmp loc_918B89
loc_918ADC:
mov [rbp+var_19], 1
jmp loc_918B6A
loc_918AE5:
mov rax, [rbp+var_28]
test byte ptr [rax+8], 1
jz short loc_918AF8
mov [rbp+var_1], 0
jmp loc_918B89
loc_918AF8:
mov rcx, [rbp+var_28]
add rcx, 20h ; ' '
mov [rbp+var_48], rcx
xor eax, eax
cmp rcx, 0
mov [rbp+var_40], rax
jz short loc_918B1C
mov rax, [rbp+var_48]
add rax, 8
mov [rbp+var_40], rax
loc_918B1C:
mov rax, [rbp+var_40]
mov [rbp+var_60], rax
mov rcx, [rbp+var_18]
mov [rbp+var_58], rcx
xor eax, eax
cmp rcx, 0
mov [rbp+var_50], rax
jz short loc_918B44
mov rax, [rbp+var_58]
add rax, 8
mov [rbp+var_50], rax
loc_918B44:
mov rdi, [rbp+var_60]; Binary_string *
mov rax, [rbp+var_28]
mov rsi, [rbp+var_50]; Binary_string *
mov rax, [rax+10h]
mov rdx, [rax+10h]; charset_info_st *
call _Z7sortcmpPK13Binary_stringS1_PK15charset_info_st; sortcmp(Binary_string const*,Binary_string const*,charset_info_st const*)
cmp eax, 0
setnz al
and al, 1
mov [rbp+var_19], al
jmp short $+2
loc_918B6A:
test [rbp+var_19], 1
jz short loc_918B81
mov rdi, [rbp+var_28]
add rdi, 20h ; ' '; this
mov rsi, [rbp+var_18]; String *
call _ZN6String4copyERKS_; String::copy(String const&)
loc_918B81:
mov al, [rbp+var_19]
and al, 1
mov [rbp+var_1], al
loc_918B89:
mov al, [rbp+var_1]
and al, 1
add rsp, 60h
pop rbp
retn
| char Cached_item_str::cmp(Cached_item_str *this)
{
char v1; // dl
Binary_string *v3; // [rsp+10h] [rbp-50h]
const Binary_string *v4; // [rsp+20h] [rbp-40h]
int v5; // [rsp+2Ch] [rbp-34h]
Binary_string *v6; // [rsp+30h] [rbp-30h]
bool v7; // [rsp+47h] [rbp-19h]
String *v8; // [rsp+48h] [rbp-18h]
v8 = (String *)(*(long long ( **)(_QWORD, char *))(**((_QWORD **)this + 2) + 264LL))(
*((_QWORD *)this + 2),
(char *)this + 64);
if ( v8 )
{
v6 = (String *)((char *)v8 + 8);
if ( (unsigned int)Binary_string::length((String *)((char *)v8 + 8)) >= *((_DWORD *)this + 6) )
{
Binary_string::length(v6, *((_DWORD *)this + 6));
}
else
{
v5 = Binary_string::length((String *)((char *)v8 + 8));
Binary_string::length(v6, v5);
}
}
if ( (*((_BYTE *)this + 8) & 1) == (*(_BYTE *)(*((_QWORD *)this + 2) + 100LL) & 1) )
{
if ( (*((_BYTE *)this + 8) & 1) != 0 )
return 0;
v4 = 0LL;
if ( this != (Cached_item_str *)-32LL )
v4 = (Cached_item_str *)((char *)this + 40);
v3 = 0LL;
if ( v8 )
v3 = (String *)((char *)v8 + 8);
v7 = (unsigned int)sortcmp(v4, v3, *(const charset_info_st **)(*((_QWORD *)this + 2) + 16LL)) != 0;
}
else
{
v1 = *(_BYTE *)(*((_QWORD *)this + 2) + 100LL) & 1;
*((_BYTE *)this + 8) = v1;
if ( v1 )
return 1;
v7 = 1;
}
if ( v7 )
String::copy((Cached_item_str *)((char *)this + 32), v8);
return v7;
}
| tp_set_threadpool_size:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV dword ptr [RBP + -0x4],EDI
CMP qword ptr [0x016ef3e0],0x0
JZ 0x00918a45
MOV RDI,qword ptr [0x016ef3e0]
MOV ESI,dword ptr [RBP + -0x4]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x38]
LAB_00918a45:
ADD RSP,0x10
POP RBP
RET
|
/* tp_set_threadpool_size(unsigned int) */
void tp_set_threadpool_size(uint param_1)
{
if (pool != (long *)0x0) {
(**(code **)(*pool + 0x38))(pool,param_1);
}
return;
}
| |
55,513 | js_os_symlink | bluesky950520[P]quickjs/quickjs-libc.c | static JSValue js_os_symlink(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
const char *target, *linkpath;
int err;
target = JS_ToCString(ctx, argv[0]);
if (!target)
return JS_EXCEPTION;
linkpath = JS_ToCString(ctx, argv[1]);
if (!linkpath) {
JS_FreeCString(ctx, target);
return JS_EXCEPTION;
}
err = js_get_errno(symlink(target, linkpath));
JS_FreeCString(ctx, target);
JS_FreeCString(ctx, linkpath);
return JS_NewInt32(ctx, err);
} | O0 | c | js_os_symlink:
subq $0x78, %rsp
movq %rsi, 0x38(%rsp)
movq %rdx, 0x40(%rsp)
movq %rdi, 0x30(%rsp)
movl %ecx, 0x2c(%rsp)
movq %r8, 0x20(%rsp)
movq 0x30(%rsp), %rdi
movq 0x20(%rsp), %rax
movq (%rax), %rsi
movq 0x8(%rax), %rdx
callq 0x13520
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
jne 0x1a2b5
movl $0x0, 0x48(%rsp)
movq $0x6, 0x50(%rsp)
jmp 0x1a36b
movq 0x30(%rsp), %rdi
movq 0x20(%rsp), %rax
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
callq 0x13520
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
jne 0x1a2fb
movq 0x30(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0x28b90
movl $0x0, 0x48(%rsp)
movq $0x6, 0x50(%rsp)
jmp 0x1a36b
movq 0x18(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0xe2b0
movslq %eax, %rdi
callq 0x12790
movl %eax, 0xc(%rsp)
movq 0x30(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0x28b90
movq 0x30(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0x28b90
movq 0x30(%rsp), %rcx
movl 0xc(%rsp), %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
movl 0x5c(%rsp), %eax
movl %eax, 0x68(%rsp)
movq $0x0, 0x70(%rsp)
movq 0x68(%rsp), %rcx
movq 0x70(%rsp), %rax
movq %rcx, 0x48(%rsp)
movq %rax, 0x50(%rsp)
movq 0x48(%rsp), %rax
movq 0x50(%rsp), %rdx
addq $0x78, %rsp
retq
nopw (%rax,%rax)
| js_os_symlink:
sub rsp, 78h
mov [rsp+78h+var_40], rsi
mov [rsp+78h+var_38], rdx
mov [rsp+78h+var_48], rdi
mov [rsp+78h+var_4C], ecx
mov [rsp+78h+var_58], r8
mov rdi, [rsp+78h+var_48]
mov rax, [rsp+78h+var_58]
mov rsi, [rax]
mov rdx, [rax+8]
call JS_ToCString
mov [rsp+78h+var_60], rax
cmp [rsp+78h+var_60], 0
jnz short loc_1A2B5
mov dword ptr [rsp+78h+var_30], 0
mov [rsp+78h+var_28], 6
jmp loc_1A36B
loc_1A2B5:
mov rdi, [rsp+78h+var_48]
mov rax, [rsp+78h+var_58]
mov rsi, [rax+10h]
mov rdx, [rax+18h]
call JS_ToCString
mov [rsp+78h+var_68], rax
cmp [rsp+78h+var_68], 0
jnz short loc_1A2FB
mov rdi, [rsp+78h+var_48]
mov rsi, [rsp+78h+var_60]
call JS_FreeCString
mov dword ptr [rsp+78h+var_30], 0
mov [rsp+78h+var_28], 6
jmp short loc_1A36B
loc_1A2FB:
mov rdi, [rsp+78h+var_60]
mov rsi, [rsp+78h+var_68]
call _symlink
movsxd rdi, eax
call js_get_errno
mov [rsp+78h+var_6C], eax
mov rdi, [rsp+78h+var_48]
mov rsi, [rsp+78h+var_60]
call JS_FreeCString
mov rdi, [rsp+78h+var_48]
mov rsi, [rsp+78h+var_68]
call JS_FreeCString
mov rcx, [rsp+78h+var_48]
mov eax, [rsp+78h+var_6C]
mov [rsp+78h+var_18], rcx
mov [rsp+78h+var_1C], eax
mov eax, [rsp+78h+var_1C]
mov dword ptr [rsp+78h+var_10], eax
mov [rsp+78h+var_8], 0
mov rcx, [rsp+78h+var_10]
mov rax, [rsp+78h+var_8]
mov [rsp+78h+var_30], rcx
mov [rsp+78h+var_28], rax
loc_1A36B:
mov rax, [rsp+78h+var_30]
mov rdx, [rsp+78h+var_28]
add rsp, 78h
retn
| long long js_os_symlink(long long a1, long long a2, long long a3, long long a4, long long *a5)
{
int v5; // eax
int errno; // [rsp+Ch] [rbp-6Ch]
long long v8; // [rsp+10h] [rbp-68h]
long long v9; // [rsp+18h] [rbp-60h]
long long v11; // [rsp+48h] [rbp-30h]
long long v12; // [rsp+68h] [rbp-10h]
v9 = JS_ToCString(a1, *a5, a5[1]);
if ( v9 )
{
v8 = JS_ToCString(a1, a5[2], a5[3]);
if ( v8 )
{
v5 = symlink(v9, v8);
errno = js_get_errno(v5);
JS_FreeCString(a1, v9);
JS_FreeCString(a1, v8);
LODWORD(v12) = errno;
return v12;
}
else
{
JS_FreeCString(a1, v9);
LODWORD(v11) = 0;
}
}
else
{
LODWORD(v11) = 0;
}
return v11;
}
| js_os_symlink:
SUB RSP,0x78
MOV qword ptr [RSP + 0x38],RSI
MOV qword ptr [RSP + 0x40],RDX
MOV qword ptr [RSP + 0x30],RDI
MOV dword ptr [RSP + 0x2c],ECX
MOV qword ptr [RSP + 0x20],R8
MOV RDI,qword ptr [RSP + 0x30]
MOV RAX,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RAX]
MOV RDX,qword ptr [RAX + 0x8]
CALL 0x00113520
MOV qword ptr [RSP + 0x18],RAX
CMP qword ptr [RSP + 0x18],0x0
JNZ 0x0011a2b5
MOV dword ptr [RSP + 0x48],0x0
MOV qword ptr [RSP + 0x50],0x6
JMP 0x0011a36b
LAB_0011a2b5:
MOV RDI,qword ptr [RSP + 0x30]
MOV RAX,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RAX + 0x10]
MOV RDX,qword ptr [RAX + 0x18]
CALL 0x00113520
MOV qword ptr [RSP + 0x10],RAX
CMP qword ptr [RSP + 0x10],0x0
JNZ 0x0011a2fb
MOV RDI,qword ptr [RSP + 0x30]
MOV RSI,qword ptr [RSP + 0x18]
CALL 0x00128b90
MOV dword ptr [RSP + 0x48],0x0
MOV qword ptr [RSP + 0x50],0x6
JMP 0x0011a36b
LAB_0011a2fb:
MOV RDI,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RSP + 0x10]
CALL 0x0010e2b0
MOVSXD RDI,EAX
CALL 0x00112790
MOV dword ptr [RSP + 0xc],EAX
MOV RDI,qword ptr [RSP + 0x30]
MOV RSI,qword ptr [RSP + 0x18]
CALL 0x00128b90
MOV RDI,qword ptr [RSP + 0x30]
MOV RSI,qword ptr [RSP + 0x10]
CALL 0x00128b90
MOV RCX,qword ptr [RSP + 0x30]
MOV EAX,dword ptr [RSP + 0xc]
MOV qword ptr [RSP + 0x60],RCX
MOV dword ptr [RSP + 0x5c],EAX
MOV EAX,dword ptr [RSP + 0x5c]
MOV dword ptr [RSP + 0x68],EAX
MOV qword ptr [RSP + 0x70],0x0
MOV RCX,qword ptr [RSP + 0x68]
MOV RAX,qword ptr [RSP + 0x70]
MOV qword ptr [RSP + 0x48],RCX
MOV qword ptr [RSP + 0x50],RAX
LAB_0011a36b:
MOV RAX,qword ptr [RSP + 0x48]
MOV RDX,qword ptr [RSP + 0x50]
ADD RSP,0x78
RET
|
int1 [16] js_os_symlink(int8 param_1)
{
int1 auVar1 [16];
int iVar2;
char *__from;
char *__to;
int8 *in_R8;
int4 local_30;
int4 uStack_2c;
int8 local_28;
int4 uStack_c;
__from = (char *)JS_ToCString(param_1,*in_R8,in_R8[1]);
if (__from == (char *)0x0) {
local_30 = 0;
local_28 = 6;
}
else {
__to = (char *)JS_ToCString(param_1,in_R8[2],in_R8[3]);
if (__to == (char *)0x0) {
JS_FreeCString(param_1,__from);
local_30 = 0;
local_28 = 6;
}
else {
iVar2 = symlink(__from,__to);
local_30 = js_get_errno((long)iVar2);
JS_FreeCString(param_1,__from);
JS_FreeCString(param_1,__to);
uStack_2c = uStack_c;
local_28 = 0;
}
}
auVar1._4_4_ = uStack_2c;
auVar1._0_4_ = local_30;
auVar1._8_8_ = local_28;
return auVar1;
}
| |
55,514 | js_os_symlink | bluesky950520[P]quickjs/quickjs-libc.c | static JSValue js_os_symlink(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
const char *target, *linkpath;
int err;
target = JS_ToCString(ctx, argv[0]);
if (!target)
return JS_EXCEPTION;
linkpath = JS_ToCString(ctx, argv[1]);
if (!linkpath) {
JS_FreeCString(ctx, target);
return JS_EXCEPTION;
}
err = js_get_errno(symlink(target, linkpath));
JS_FreeCString(ctx, target);
JS_FreeCString(ctx, linkpath);
return JS_NewInt32(ctx, err);
} | O1 | c | js_os_symlink:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r8, %r13
movq %rdi, %rbx
movq (%r8), %rdx
movq 0x8(%r8), %rcx
xorl %r12d, %r12d
xorl %esi, %esi
xorl %r8d, %r8d
callq 0x1ffe3
movl $0x6, %r15d
testq %rax, %rax
je 0x1930c
movq %rax, %r14
movq 0x10(%r13), %rdx
movq 0x18(%r13), %rcx
movq %rbx, %rdi
xorl %esi, %esi
xorl %r8d, %r8d
callq 0x1ffe3
testq %rax, %rax
je 0x192fe
movq %rax, %r12
movq %r14, %rdi
movq %rax, %rsi
callq 0xe2b0
movl %eax, %ebp
cmpl $-0x1, %eax
jne 0x192e0
callq 0xe0b0
xorl %ebp, %ebp
subl (%rax), %ebp
movq %rbx, %rdi
movq %r14, %rsi
callq 0x202c9
movq %rbx, %rdi
movq %r12, %rsi
callq 0x202c9
movl %ebp, %r12d
xorl %r15d, %r15d
jmp 0x1930c
movq %rbx, %rdi
movq %r14, %rsi
callq 0x202c9
xorl %r12d, %r12d
movq %r12, %rax
movq %r15, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| js_os_symlink:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r13, r8
mov rbx, rdi
mov rdx, [r8]
mov rcx, [r8+8]
xor r12d, r12d
xor esi, esi
xor r8d, r8d
call JS_ToCStringLen2
mov r15d, 6
test rax, rax
jz short loc_1930C
mov r14, rax
mov rdx, [r13+10h]
mov rcx, [r13+18h]
mov rdi, rbx
xor esi, esi
xor r8d, r8d
call JS_ToCStringLen2
test rax, rax
jz short loc_192FE
mov r12, rax
mov rdi, r14
mov rsi, rax
call _symlink
mov ebp, eax
cmp eax, 0FFFFFFFFh
jnz short loc_192E0
call ___errno_location
xor ebp, ebp
sub ebp, [rax]
loc_192E0:
mov rdi, rbx
mov rsi, r14
call JS_FreeCString
mov rdi, rbx
mov rsi, r12
call JS_FreeCString
mov r12d, ebp
xor r15d, r15d
jmp short loc_1930C
loc_192FE:
mov rdi, rbx
mov rsi, r14
call JS_FreeCString
xor r12d, r12d
loc_1930C:
mov rax, r12
mov rdx, r15
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long js_os_symlink(long long a1, long long a2, long long a3, long long a4, _QWORD *a5)
{
long long v6; // r12
long long v7; // rax
long long v8; // r14
long long v9; // rax
long long v10; // r12
unsigned int v11; // ebp
v6 = 0LL;
v7 = JS_ToCStringLen2(a1, 0LL, *a5, a5[1], 0LL);
if ( v7 )
{
v8 = v7;
v9 = JS_ToCStringLen2(a1, 0LL, a5[2], a5[3], 0LL);
if ( v9 )
{
v10 = v9;
v11 = symlink(v8, v9);
if ( v11 == -1 )
v11 = -*(_DWORD *)__errno_location(v8);
JS_FreeCString(a1, v8);
JS_FreeCString(a1, v10);
return v11;
}
else
{
JS_FreeCString(a1, v8);
return 0LL;
}
}
return v6;
}
| js_os_symlink:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R13,R8
MOV RBX,RDI
MOV RDX,qword ptr [R8]
MOV RCX,qword ptr [R8 + 0x8]
XOR R12D,R12D
XOR ESI,ESI
XOR R8D,R8D
CALL 0x0011ffe3
MOV R15D,0x6
TEST RAX,RAX
JZ 0x0011930c
MOV R14,RAX
MOV RDX,qword ptr [R13 + 0x10]
MOV RCX,qword ptr [R13 + 0x18]
MOV RDI,RBX
XOR ESI,ESI
XOR R8D,R8D
CALL 0x0011ffe3
TEST RAX,RAX
JZ 0x001192fe
MOV R12,RAX
MOV RDI,R14
MOV RSI,RAX
CALL 0x0010e2b0
MOV EBP,EAX
CMP EAX,-0x1
JNZ 0x001192e0
CALL 0x0010e0b0
XOR EBP,EBP
SUB EBP,dword ptr [RAX]
LAB_001192e0:
MOV RDI,RBX
MOV RSI,R14
CALL 0x001202c9
MOV RDI,RBX
MOV RSI,R12
CALL 0x001202c9
MOV R12D,EBP
XOR R15D,R15D
JMP 0x0011930c
LAB_001192fe:
MOV RDI,RBX
MOV RSI,R14
CALL 0x001202c9
XOR R12D,R12D
LAB_0011930c:
MOV RAX,R12
MOV RDX,R15
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int js_os_symlink(int8 param_1)
{
int iVar1;
char *__from;
char *__to;
int *piVar2;
int8 *in_R8;
iVar1 = 0;
__from = (char *)JS_ToCStringLen2(param_1,0,*in_R8,in_R8[1],0);
if (__from != (char *)0x0) {
__to = (char *)JS_ToCStringLen2(param_1,0,in_R8[2],in_R8[3],0);
if (__to == (char *)0x0) {
JS_FreeCString(param_1,__from);
iVar1 = 0;
}
else {
iVar1 = symlink(__from,__to);
if (iVar1 == -1) {
piVar2 = __errno_location();
iVar1 = -*piVar2;
}
JS_FreeCString(param_1,__from);
JS_FreeCString(param_1,__to);
}
}
return iVar1;
}
| |
55,515 | ma_read_rnd_pack_record | eloqsql/storage/maria/ma_packrec.c | int _ma_read_rnd_pack_record(MARIA_HA *info,
uchar *buf,
register MARIA_RECORD_POS filepos,
my_bool skip_deleted_blocks)
{
File file;
MARIA_BLOCK_INFO block_info;
MARIA_SHARE *share= info->s;
DBUG_ENTER("_ma_read_rnd_pack_record");
if (filepos >= info->state->data_file_length)
{
my_errno= HA_ERR_END_OF_FILE;
goto err;
}
file= info->dfile.file;
if (info->opt_flag & READ_CACHE_USED)
{
if (_ma_read_cache(info, &info->rec_cache, block_info.header,
filepos, share->pack.ref_length,
skip_deleted_blocks ? READING_NEXT : 0))
goto err;
file= -1;
}
if (_ma_pack_get_block_info(info, &info->bit_buff, &block_info,
&info->rec_buff, &info->rec_buff_size,
file, filepos))
goto err; /* Error code is already set */
#ifndef DBUG_OFF
if (block_info.rec_len > share->max_pack_length)
{
_ma_set_fatal_error(info, HA_ERR_WRONG_IN_RECORD);
goto err;
}
#endif
if (info->opt_flag & READ_CACHE_USED)
{
if (_ma_read_cache(info, &info->rec_cache, info->rec_buff,
block_info.filepos, block_info.rec_len,
skip_deleted_blocks ? READING_NEXT : 0))
goto err;
}
else
{
if (mysql_file_read(info->dfile.file, info->rec_buff + block_info.offset,
block_info.rec_len-block_info.offset,
MYF(MY_NABP)))
goto err;
}
info->packed_length= block_info.rec_len;
info->cur_row.lastpos= filepos;
info->cur_row.nextpos= block_info.filepos+block_info.rec_len;
info->update|= HA_STATE_AKTIV | HA_STATE_KEY_CHANGED;
info->rec_buff[block_info.rec_len]= 0; /* Keep valgrind happy */
DBUG_RETURN(_ma_pack_rec_unpack(info, &info->bit_buff, buf,
info->rec_buff, block_info.rec_len));
err:
DBUG_RETURN(my_errno);
} | O0 | c | ma_read_rnd_pack_record:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movb %cl, %al
movq %fs:0x28, %rcx
movq %rcx, -0x8(%rbp)
movq %rdi, -0x70(%rbp)
movq %rsi, -0x78(%rbp)
movq %rdx, -0x80(%rbp)
movb %al, -0x81(%rbp)
movq -0x70(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x90(%rbp)
movq -0x80(%rbp), %rax
movq -0x70(%rbp), %rcx
movq 0x20(%rcx), %rcx
cmpq 0x28(%rcx), %rax
jb 0x3851c
callq 0xf60c0
movl $0x89, (%rax)
jmp 0x38707
movq -0x70(%rbp), %rax
movl 0x480(%rax), %eax
movl %eax, -0x88(%rbp)
movq -0x70(%rbp), %rax
movl 0x61c(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x38595
movq -0x70(%rbp), %rdi
movq -0x70(%rbp), %rsi
addq $0x4b8, %rsi # imm = 0x4B8
leaq -0x60(%rbp), %rdx
movq -0x80(%rbp), %rcx
movq -0x90(%rbp), %rax
movl 0x598(%rax), %eax
movl %eax, %r8d
movsbl -0x81(%rbp), %r10d
xorl %r9d, %r9d
movl $0x1, %eax
cmpl $0x0, %r10d
cmovnel %eax, %r9d
callq 0x72c60
cmpb $0x0, %al
je 0x3858b
jmp 0x38707
movl $0xffffffff, -0x88(%rbp) # imm = 0xFFFFFFFF
movq -0x70(%rbp), %rdi
movq -0x70(%rbp), %rsi
addq $0x290, %rsi # imm = 0x290
movq -0x70(%rbp), %rcx
addq $0x3a0, %rcx # imm = 0x3A0
movq -0x70(%rbp), %r8
addq $0x460, %r8 # imm = 0x460
movl -0x88(%rbp), %r9d
movq -0x80(%rbp), %rax
leaq -0x60(%rbp), %rdx
movq %rax, (%rsp)
callq 0x37f30
cmpl $0x0, %eax
je 0x385dc
jmp 0x38707
movq -0x70(%rbp), %rax
movl 0x61c(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x38638
movq -0x70(%rbp), %rdi
movq -0x70(%rbp), %rsi
addq $0x4b8, %rsi # imm = 0x4B8
movq -0x70(%rbp), %rax
movq 0x3a0(%rax), %rdx
movq -0x28(%rbp), %rcx
movq -0x48(%rbp), %r8
movsbl -0x81(%rbp), %r10d
xorl %r9d, %r9d
movl $0x1, %eax
cmpl $0x0, %r10d
cmovnel %eax, %r9d
callq 0x72c60
cmpb $0x0, %al
je 0x38636
jmp 0x38707
jmp 0x38681
movq -0x70(%rbp), %rax
movl 0x480(%rax), %edx
movq -0x70(%rbp), %rax
movq 0x3a0(%rax), %rcx
movl -0xc(%rbp), %eax
addq %rax, %rcx
movq -0x48(%rbp), %r8
movl -0xc(%rbp), %eax
subq %rax, %r8
leaq 0x118f44(%rip), %rdi # 0x1515a8
movl $0x572, %esi # imm = 0x572
movl $0x4, %r9d
callq 0x38160
cmpq $0x0, %rax
je 0x3867f
jmp 0x38707
jmp 0x38681
movq -0x48(%rbp), %rcx
movq -0x70(%rbp), %rax
movq %rcx, 0x450(%rax)
movq -0x80(%rbp), %rcx
movq -0x70(%rbp), %rax
movq %rcx, 0x98(%rax)
movq -0x28(%rbp), %rcx
addq -0x48(%rbp), %rcx
movq -0x70(%rbp), %rax
movq %rcx, 0xa0(%rax)
movq -0x70(%rbp), %rax
movl 0x624(%rax), %ecx
orl $0x82, %ecx
movl %ecx, 0x624(%rax)
movq -0x70(%rbp), %rax
movq 0x3a0(%rax), %rax
movq -0x48(%rbp), %rcx
movb $0x0, (%rax,%rcx)
movq -0x70(%rbp), %rdi
movq -0x70(%rbp), %rsi
addq $0x290, %rsi # imm = 0x290
movq -0x78(%rbp), %rdx
movq -0x70(%rbp), %rax
movq 0x3a0(%rax), %rcx
movq -0x48(%rbp), %r8
callq 0x382d0
movl %eax, -0x64(%rbp)
jmp 0x38713
jmp 0x38709
callq 0xf60c0
movl (%rax), %eax
movl %eax, -0x64(%rbp)
movl -0x64(%rbp), %eax
movl %eax, -0x94(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x3873d
movl -0x94(%rbp), %eax
addq $0xa0, %rsp
popq %rbp
retq
callq 0x2a270
nopw %cs:(%rax,%rax)
| _ma_read_rnd_pack_record:
push rbp
mov rbp, rsp
sub rsp, 0A0h
mov al, cl
mov rcx, fs:28h
mov [rbp+var_8], rcx
mov [rbp+var_70], rdi
mov [rbp+var_78], rsi
mov [rbp+var_80], rdx
mov [rbp+var_81], al
mov rax, [rbp+var_70]
mov rax, [rax]
mov [rbp+var_90], rax
mov rax, [rbp+var_80]
mov rcx, [rbp+var_70]
mov rcx, [rcx+20h]
cmp rax, [rcx+28h]
jb short loc_3851C
call _my_thread_var
mov dword ptr [rax], 89h
jmp loc_38707
loc_3851C:
mov rax, [rbp+var_70]
mov eax, [rax+480h]
mov [rbp+var_88], eax
mov rax, [rbp+var_70]
mov eax, [rax+61Ch]
and eax, 2
cmp eax, 0
jz short loc_38595
mov rdi, [rbp+var_70]
mov rsi, [rbp+var_70]
add rsi, 4B8h
lea rdx, [rbp+var_60]
mov rcx, [rbp+var_80]
mov rax, [rbp+var_90]
mov eax, [rax+598h]
mov r8d, eax
movsx r10d, [rbp+var_81]
xor r9d, r9d
mov eax, 1
cmp r10d, 0
cmovnz r9d, eax
call _ma_read_cache
cmp al, 0
jz short loc_3858B
jmp loc_38707
loc_3858B:
mov [rbp+var_88], 0FFFFFFFFh
loc_38595:
mov rdi, [rbp+var_70]
mov rsi, [rbp+var_70]
add rsi, 290h
mov rcx, [rbp+var_70]
add rcx, 3A0h
mov r8, [rbp+var_70]
add r8, 460h
mov r9d, [rbp+var_88]
mov rax, [rbp+var_80]
lea rdx, [rbp+var_60]
mov [rsp+0A0h+var_A0], rax
call _ma_pack_get_block_info
cmp eax, 0
jz short loc_385DC
jmp loc_38707
loc_385DC:
mov rax, [rbp+var_70]
mov eax, [rax+61Ch]
and eax, 2
cmp eax, 0
jz short loc_38638
mov rdi, [rbp+var_70]
mov rsi, [rbp+var_70]
add rsi, 4B8h
mov rax, [rbp+var_70]
mov rdx, [rax+3A0h]
mov rcx, [rbp+var_28]
mov r8, [rbp+var_48]
movsx r10d, [rbp+var_81]
xor r9d, r9d
mov eax, 1
cmp r10d, 0
cmovnz r9d, eax
call _ma_read_cache
cmp al, 0
jz short loc_38636
jmp loc_38707
loc_38636:
jmp short loc_38681
loc_38638:
mov rax, [rbp+var_70]
mov edx, [rax+480h]
mov rax, [rbp+var_70]
mov rcx, [rax+3A0h]
mov eax, [rbp+var_C]
add rcx, rax
mov r8, [rbp+var_48]
mov eax, [rbp+var_C]
sub r8, rax
lea rdi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 572h
mov r9d, 4
call inline_mysql_file_read
cmp rax, 0
jz short loc_3867F
jmp loc_38707
loc_3867F:
jmp short $+2
loc_38681:
mov rcx, [rbp+var_48]
mov rax, [rbp+var_70]
mov [rax+450h], rcx
mov rcx, [rbp+var_80]
mov rax, [rbp+var_70]
mov [rax+98h], rcx
mov rcx, [rbp+var_28]
add rcx, [rbp+var_48]
mov rax, [rbp+var_70]
mov [rax+0A0h], rcx
mov rax, [rbp+var_70]
mov ecx, [rax+624h]
or ecx, 82h
mov [rax+624h], ecx
mov rax, [rbp+var_70]
mov rax, [rax+3A0h]
mov rcx, [rbp+var_48]
mov byte ptr [rax+rcx], 0
mov rdi, [rbp+var_70]
mov rsi, [rbp+var_70]
add rsi, 290h
mov rdx, [rbp+var_78]
mov rax, [rbp+var_70]
mov rcx, [rax+3A0h]
mov r8, [rbp+var_48]
call _ma_pack_rec_unpack
mov [rbp+var_64], eax
jmp short loc_38713
loc_38707:
jmp short $+2
loc_38709:
call _my_thread_var
mov eax, [rax]
mov [rbp+var_64], eax
loc_38713:
mov eax, [rbp+var_64]
mov [rbp+var_94], eax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_3873D
mov eax, [rbp+var_94]
add rsp, 0A0h
pop rbp
retn
loc_3873D:
call ___stack_chk_fail
| long long ma_read_rnd_pack_record(long long a1, long long a2, unsigned long long a3, char a4)
{
int v5; // [rsp+18h] [rbp-88h]
_BYTE v9[24]; // [rsp+40h] [rbp-60h] BYREF
long long v10; // [rsp+58h] [rbp-48h]
long long v11; // [rsp+78h] [rbp-28h]
unsigned int v12; // [rsp+94h] [rbp-Ch]
unsigned long long v13; // [rsp+98h] [rbp-8h]
v13 = __readfsqword(0x28u);
if ( a3 >= *(_QWORD *)(*(_QWORD *)(a1 + 32) + 40LL) )
{
*(_DWORD *)my_thread_var() = 137;
return *(unsigned int *)my_thread_var();
}
v5 = *(_DWORD *)(a1 + 1152);
if ( (*(_DWORD *)(a1 + 1564) & 2) != 0 )
{
if ( (unsigned __int8)ma_read_cache(a1, a1 + 1208, v9, a3, *(unsigned int *)(*(_QWORD *)a1 + 1432LL), a4 != 0) )
return *(unsigned int *)my_thread_var();
v5 = -1;
}
if ( (unsigned int)ma_pack_get_block_info(
(_QWORD *)a1,
a1 + 656,
(long long)v9,
(_QWORD *)(a1 + 928),
a1 + 1120,
v5,
a3) )
return *(unsigned int *)my_thread_var();
if ( (*(_DWORD *)(a1 + 1564) & 2) != 0 )
{
if ( (unsigned __int8)ma_read_cache(a1, a1 + 1208, *(_QWORD *)(a1 + 928), v11, v10, a4 != 0) )
return *(unsigned int *)my_thread_var();
}
else if ( inline_mysql_file_read(
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_packrec.c",
0x572u,
*(_DWORD *)(a1 + 1152),
v12 + *(_QWORD *)(a1 + 928),
v10 - v12,
4LL) )
{
return *(unsigned int *)my_thread_var();
}
*(_QWORD *)(a1 + 1104) = v10;
*(_QWORD *)(a1 + 152) = a3;
*(_QWORD *)(a1 + 160) = v10 + v11;
*(_DWORD *)(a1 + 1572) |= 0x82u;
*(_BYTE *)(*(_QWORD *)(a1 + 928) + v10) = 0;
return (unsigned int)ma_pack_rec_unpack((_DWORD *)a1, a1 + 656, a2, *(_QWORD *)(a1 + 928), v10);
}
| _ma_read_rnd_pack_record:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xa0
MOV AL,CL
MOV RCX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RCX
MOV qword ptr [RBP + -0x70],RDI
MOV qword ptr [RBP + -0x78],RSI
MOV qword ptr [RBP + -0x80],RDX
MOV byte ptr [RBP + -0x81],AL
MOV RAX,qword ptr [RBP + -0x70]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x90],RAX
MOV RAX,qword ptr [RBP + -0x80]
MOV RCX,qword ptr [RBP + -0x70]
MOV RCX,qword ptr [RCX + 0x20]
CMP RAX,qword ptr [RCX + 0x28]
JC 0x0013851c
CALL 0x001f60c0
MOV dword ptr [RAX],0x89
JMP 0x00138707
LAB_0013851c:
MOV RAX,qword ptr [RBP + -0x70]
MOV EAX,dword ptr [RAX + 0x480]
MOV dword ptr [RBP + -0x88],EAX
MOV RAX,qword ptr [RBP + -0x70]
MOV EAX,dword ptr [RAX + 0x61c]
AND EAX,0x2
CMP EAX,0x0
JZ 0x00138595
MOV RDI,qword ptr [RBP + -0x70]
MOV RSI,qword ptr [RBP + -0x70]
ADD RSI,0x4b8
LEA RDX,[RBP + -0x60]
MOV RCX,qword ptr [RBP + -0x80]
MOV RAX,qword ptr [RBP + -0x90]
MOV EAX,dword ptr [RAX + 0x598]
MOV R8D,EAX
MOVSX R10D,byte ptr [RBP + -0x81]
XOR R9D,R9D
MOV EAX,0x1
CMP R10D,0x0
CMOVNZ R9D,EAX
CALL 0x00172c60
CMP AL,0x0
JZ 0x0013858b
JMP 0x00138707
LAB_0013858b:
MOV dword ptr [RBP + -0x88],0xffffffff
LAB_00138595:
MOV RDI,qword ptr [RBP + -0x70]
MOV RSI,qword ptr [RBP + -0x70]
ADD RSI,0x290
MOV RCX,qword ptr [RBP + -0x70]
ADD RCX,0x3a0
MOV R8,qword ptr [RBP + -0x70]
ADD R8,0x460
MOV R9D,dword ptr [RBP + -0x88]
MOV RAX,qword ptr [RBP + -0x80]
LEA RDX,[RBP + -0x60]
MOV qword ptr [RSP],RAX
CALL 0x00137f30
CMP EAX,0x0
JZ 0x001385dc
JMP 0x00138707
LAB_001385dc:
MOV RAX,qword ptr [RBP + -0x70]
MOV EAX,dword ptr [RAX + 0x61c]
AND EAX,0x2
CMP EAX,0x0
JZ 0x00138638
MOV RDI,qword ptr [RBP + -0x70]
MOV RSI,qword ptr [RBP + -0x70]
ADD RSI,0x4b8
MOV RAX,qword ptr [RBP + -0x70]
MOV RDX,qword ptr [RAX + 0x3a0]
MOV RCX,qword ptr [RBP + -0x28]
MOV R8,qword ptr [RBP + -0x48]
MOVSX R10D,byte ptr [RBP + -0x81]
XOR R9D,R9D
MOV EAX,0x1
CMP R10D,0x0
CMOVNZ R9D,EAX
CALL 0x00172c60
CMP AL,0x0
JZ 0x00138636
JMP 0x00138707
LAB_00138636:
JMP 0x00138681
LAB_00138638:
MOV RAX,qword ptr [RBP + -0x70]
MOV EDX,dword ptr [RAX + 0x480]
MOV RAX,qword ptr [RBP + -0x70]
MOV RCX,qword ptr [RAX + 0x3a0]
MOV EAX,dword ptr [RBP + -0xc]
ADD RCX,RAX
MOV R8,qword ptr [RBP + -0x48]
MOV EAX,dword ptr [RBP + -0xc]
SUB R8,RAX
LEA RDI,[0x2515a8]
MOV ESI,0x572
MOV R9D,0x4
CALL 0x00138160
CMP RAX,0x0
JZ 0x0013867f
JMP 0x00138707
LAB_0013867f:
JMP 0x00138681
LAB_00138681:
MOV RCX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RAX + 0x450],RCX
MOV RCX,qword ptr [RBP + -0x80]
MOV RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RAX + 0x98],RCX
MOV RCX,qword ptr [RBP + -0x28]
ADD RCX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RAX + 0xa0],RCX
MOV RAX,qword ptr [RBP + -0x70]
MOV ECX,dword ptr [RAX + 0x624]
OR ECX,0x82
MOV dword ptr [RAX + 0x624],ECX
MOV RAX,qword ptr [RBP + -0x70]
MOV RAX,qword ptr [RAX + 0x3a0]
MOV RCX,qword ptr [RBP + -0x48]
MOV byte ptr [RAX + RCX*0x1],0x0
MOV RDI,qword ptr [RBP + -0x70]
MOV RSI,qword ptr [RBP + -0x70]
ADD RSI,0x290
MOV RDX,qword ptr [RBP + -0x78]
MOV RAX,qword ptr [RBP + -0x70]
MOV RCX,qword ptr [RAX + 0x3a0]
MOV R8,qword ptr [RBP + -0x48]
CALL 0x001382d0
MOV dword ptr [RBP + -0x64],EAX
JMP 0x00138713
LAB_00138707:
JMP 0x00138709
LAB_00138709:
CALL 0x001f60c0
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x64],EAX
LAB_00138713:
MOV EAX,dword ptr [RBP + -0x64]
MOV dword ptr [RBP + -0x94],EAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x0013873d
MOV EAX,dword ptr [RBP + -0x94]
ADD RSP,0xa0
POP RBP
RET
LAB_0013873d:
CALL 0x0012a270
|
int4 _ma_read_rnd_pack_record(long *param_1,int8 param_2,ulong param_3,char param_4)
{
char cVar1;
int iVar2;
int4 *puVar3;
long lVar4;
long in_FS_OFFSET;
int4 local_90;
int4 local_6c;
int1 local_68 [24];
long local_50;
long local_30;
uint local_14;
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
if (param_3 < *(ulong *)(param_1[4] + 0x28)) {
local_90 = (int4)param_1[0x90];
if ((*(uint *)((long)param_1 + 0x61c) & 2) != 0) {
cVar1 = _ma_read_cache(param_1,param_1 + 0x97,local_68,param_3,
*(int4 *)(*param_1 + 0x598),param_4 != '\0');
if (cVar1 != '\0') goto LAB_00138707;
local_90 = 0xffffffff;
}
iVar2 = _ma_pack_get_block_info
(param_1,param_1 + 0x52,local_68,param_1 + 0x74,param_1 + 0x8c,local_90,
param_3);
if (iVar2 == 0) {
if ((*(uint *)((long)param_1 + 0x61c) & 2) == 0) {
lVar4 = inline_mysql_file_read
("/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_packrec.c",
0x572,(int)param_1[0x90],param_1[0x74] + (ulong)local_14,
local_50 - (ulong)local_14,4);
if (lVar4 == 0) goto LAB_00138681;
}
else {
cVar1 = _ma_read_cache(param_1,param_1 + 0x97,param_1[0x74],local_30,local_50,
param_4 != '\0');
if (cVar1 == '\0') {
LAB_00138681:
param_1[0x8a] = local_50;
param_1[0x13] = param_3;
param_1[0x14] = local_30 + local_50;
*(uint *)((long)param_1 + 0x624) = *(uint *)((long)param_1 + 0x624) | 0x82;
*(int1 *)(param_1[0x74] + local_50) = 0;
local_6c = _ma_pack_rec_unpack(param_1,param_1 + 0x52,param_2,param_1[0x74],local_50);
goto LAB_00138713;
}
}
}
}
else {
puVar3 = (int4 *)_my_thread_var();
*puVar3 = 0x89;
}
LAB_00138707:
puVar3 = (int4 *)_my_thread_var();
local_6c = *puVar3;
LAB_00138713:
if (*(long *)(in_FS_OFFSET + 0x28) == local_10) {
return local_6c;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
55,516 | common_log_main() | monkey531[P]llama/common/log.cpp | struct common_log * common_log_main() {
static struct common_log log;
return &log;
} | O1 | cpp | common_log_main():
pushq %rbx
movb 0x5f35e(%rip), %al # 0xdf0e0
testb %al, %al
je 0x7fd8f
leaq 0x5f283(%rip), %rax # 0xdf010
popq %rbx
retq
leaq 0x5f34a(%rip), %rdi # 0xdf0e0
callq 0x18bf0
testl %eax, %eax
je 0x7fd86
leaq 0x5f26a(%rip), %rdi # 0xdf010
movl $0x100, %esi # imm = 0x100
callq 0x804bc
leaq 0x151(%rip), %rdi # 0x7ff08
leaq 0x5f252(%rip), %rsi # 0xdf010
leaq 0x5e8e3(%rip), %rdx # 0xde6a8
callq 0x185d0
leaq 0x5f30f(%rip), %rdi # 0xdf0e0
callq 0x18440
jmp 0x7fd86
movq %rax, %rbx
leaq 0x5f2fe(%rip), %rdi # 0xdf0e0
callq 0x18430
movq %rbx, %rdi
callq 0x18ba0
| _Z15common_log_mainv:
push rbx
mov al, cs:_ZGVZ15common_log_mainvE3log; `guard variable for'common_log_main(void)::log
test al, al
jz short loc_7FD8F
loc_7FD86:
lea rax, _ZZ15common_log_mainvE3log; common_log_main(void)::log
pop rbx
retn
loc_7FD8F:
lea rdi, _ZGVZ15common_log_mainvE3log; __guard *
call ___cxa_guard_acquire
test eax, eax
jz short loc_7FD86
lea rdi, _ZZ15common_log_mainvE3log; this
mov esi, 100h; unsigned __int64
call _ZN10common_logC2Em; common_log::common_log(ulong)
lea rdi, _ZN10common_logD2Ev; lpfunc
lea rsi, _ZZ15common_log_mainvE3log; obj
lea rdx, __dso_handle; lpdso_handle
call ___cxa_atexit
lea rdi, _ZGVZ15common_log_mainvE3log; __guard *
call ___cxa_guard_release
jmp short loc_7FD86
mov rbx, rax
lea rdi, _ZGVZ15common_log_mainvE3log; __guard *
call ___cxa_guard_abort
mov rdi, rbx
call __Unwind_Resume
| void *common_log_main(void)
{
if ( !(_BYTE)`guard variable for'common_log_main(void)::log
&& __cxa_guard_acquire(&`guard variable for'common_log_main(void)::log) )
{
common_log::common_log((common_log *)&common_log_main(void)::log, 0x100uLL);
__cxa_atexit(common_log::~common_log, &common_log_main(void)::log, &_dso_handle);
__cxa_guard_release(&`guard variable for'common_log_main(void)::log);
}
return &common_log_main(void)::log;
}
| common_log_main:
PUSH RBX
MOV AL,byte ptr [0x001df0e0]
TEST AL,AL
JZ 0x0017fd8f
LAB_0017fd86:
LEA RAX,[0x1df010]
POP RBX
RET
LAB_0017fd8f:
LEA RDI,[0x1df0e0]
CALL 0x00118bf0
TEST EAX,EAX
JZ 0x0017fd86
LAB_0017fd9f:
LEA RDI,[0x1df010]
MOV ESI,0x100
CALL 0x001804bc
LAB_0017fdb0:
LEA RDI,[0x17ff08]
LEA RSI,[0x1df010]
LEA RDX,[0x1de6a8]
CALL 0x001185d0
LEA RDI,[0x1df0e0]
CALL 0x00118440
JMP 0x0017fd86
|
/* WARNING: Unknown calling convention -- yet parameter storage is locked */
/* common_log_main() */
int1 * common_log_main(void)
{
int iVar1;
if (common_log_main()::log == '\0') {
iVar1 = __cxa_guard_acquire(&common_log_main()::log);
if (iVar1 != 0) {
/* try { // try from 0017fd9f to 0017fdaf has its CatchHandler @ 0017fdd8 */
common_log::common_log((common_log *)common_log_main()::log,0x100);
__cxa_atexit(common_log::~common_log,common_log_main()::log,&__dso_handle);
__cxa_guard_release(&common_log_main()::log);
}
}
return common_log_main()::log;
}
| |
55,517 | ma_apply_redo_index | eloqsql/storage/maria/ma_key_recover.c | uint _ma_apply_redo_index(MARIA_HA *info,
LSN lsn, const uchar *header, uint head_length)
{
MARIA_SHARE *share= info->s;
pgcache_page_no_t page_pos= page_korr(header);
MARIA_PINNED_PAGE page_link;
uchar *buff;
const uchar *header_end= header + head_length;
uint page_offset= 0, org_page_length;
uint page_length, keypage_header, keynr;
uint max_page_size= share->max_index_block_size;
#ifdef DBUG_ASSERT_EXISTS
uint new_page_length= 0;
#endif
int result, mark_crashed;
MARIA_PAGE page;
DBUG_ENTER("_ma_apply_redo_index");
DBUG_PRINT("enter", ("page: %lu", (ulong) page_pos));
/* Set header to point at key data */
header+= PAGE_STORE_SIZE;
if (!(buff= pagecache_read(share->pagecache, &share->kfile,
page_pos, 0, 0,
PAGECACHE_PLAIN_PAGE, PAGECACHE_LOCK_WRITE,
&page_link.link)))
{
result= 1; mark_crashed= 0;
_ma_set_fatal_error(info, my_errno);
goto err;
}
if (lsn_korr(buff) >= lsn)
{
/* Already applied */
check_skipped_lsn(info, lsn_korr(buff), 0, page_pos);
result= mark_crashed= 0;
goto err;
}
keynr= _ma_get_keynr(share, buff);
_ma_page_setup(&page, info, share->keyinfo + keynr, page_pos, buff);
org_page_length= page_length= page.size;
keypage_header= share->keypage_header;
DBUG_PRINT("redo", ("page_length: %u", page_length));
/* Apply modifications to page */
do
{
switch ((enum en_key_op) (*header++)) {
case KEY_OP_OFFSET: /* 1 */
page_offset= uint2korr(header);
header+= 2;
DBUG_PRINT("redo", ("key_op_offset: %u", page_offset));
DBUG_ASSERT(page_offset >= keypage_header && page_offset <= page_length);
break;
case KEY_OP_SHIFT: /* 2 */
{
int length= sint2korr(header);
header+= 2;
DBUG_PRINT("redo", ("key_op_shift: %d", length));
DBUG_ASSERT(page_offset != 0 && page_offset <= page_length &&
page_length + length <= max_page_size);
if (length < 0)
{
DBUG_ASSERT(page_offset - length <= page_length);
bmove(buff + page_offset, buff + page_offset - length,
page_length - page_offset + length);
}
else if (page_length != page_offset)
bmove_upp(buff + page_length + length, buff + page_length,
page_length - page_offset);
page_length+= length;
break;
}
case KEY_OP_CHANGE: /* 3 */
{
uint length= uint2korr(header);
DBUG_PRINT("redo", ("key_op_change: %u", length));
DBUG_ASSERT(page_offset != 0 && page_offset + length <= page_length);
memcpy(buff + page_offset, header + 2 , length);
page_offset+= length; /* Put offset after changed length */
header+= 2 + length;
break;
}
case KEY_OP_ADD_PREFIX: /* 4 */
{
uint insert_length= uint2korr(header);
uint changed_length= uint2korr(header+2);
DBUG_PRINT("redo", ("key_op_add_prefix: %u %u",
insert_length, changed_length));
DBUG_ASSERT(insert_length <= changed_length &&
page_length + insert_length <= max_page_size);
bmove_upp(buff + page_length + insert_length, buff + page_length,
page_length - keypage_header);
memcpy(buff + keypage_header, header + 4 , changed_length);
header+= 4 + changed_length;
page_length+= insert_length;
break;
}
case KEY_OP_DEL_PREFIX: /* 5 */
{
uint length= uint2korr(header);
header+= 2;
DBUG_PRINT("redo", ("key_op_del_prefix: %u", length));
DBUG_ASSERT(length <= page_length - keypage_header);
bmove(buff + keypage_header, buff + keypage_header +
length, page_length - keypage_header - length);
page_length-= length;
page_offset= keypage_header; /* Prepare for change */
break;
}
case KEY_OP_ADD_SUFFIX: /* 6 */
{
uint insert_length= uint2korr(header);
DBUG_PRINT("redo", ("key_op_add_suffix: %u", insert_length));
DBUG_ASSERT(page_length + insert_length <= max_page_size);
memcpy(buff + page_length, header+2, insert_length);
page_length+= insert_length;
header+= 2 + insert_length;
break;
}
case KEY_OP_DEL_SUFFIX: /* 7 */
{
uint del_length= uint2korr(header);
header+= 2;
DBUG_PRINT("redo", ("key_op_del_suffix: %u", del_length));
DBUG_ASSERT(page_length - del_length >= keypage_header);
page_length-= del_length;
break;
}
case KEY_OP_CHECK: /* 8 */
{
#ifdef EXTRA_DEBUG_KEY_CHANGES
uint check_page_length;
ha_checksum crc;
check_page_length= uint2korr(header);
crc= uint4korr(header+2);
_ma_store_page_used(share, buff, page_length);
if (check_page_length != page_length ||
crc != (uint32) my_checksum(0, buff + LSN_STORE_SIZE,
page_length - LSN_STORE_SIZE))
{
DBUG_DUMP("KEY_OP_CHECK bad page", buff, page_length);
if (header + 6 + check_page_length <= header_end)
{
DBUG_DUMP("KEY_OP_CHECK org page", header + 6, check_page_length);
}
DBUG_ASSERT("crc failure in REDO_INDEX" == 0);
}
#endif
DBUG_PRINT("redo", ("key_op_check"));
/*
This is the last entry in the block and it can contain page_length
data or not
*/
DBUG_ASSERT(header + 6 == header_end ||
header + 6 + page_length == header_end);
header= header_end;
break;
}
case KEY_OP_DEBUG:
DBUG_PRINT("redo", ("Debug: %u", (uint) header[0]));
header++;
break;
case KEY_OP_DEBUG_2:
DBUG_PRINT("redo", ("org_page_length: %u new_page_length: %u",
uint2korr(header), uint2korr(header+2)));
DBUG_ASSERT(uint2korr(header) == page_length);
#ifdef DBUG_ASSERT_EXISTS
new_page_length= MY_MIN(uint2korr(header+2), max_page_size);
#endif
header+= 4;
break;
case KEY_OP_MAX_PAGELENGTH:
DBUG_PRINT("redo", ("key_op_max_page_length"));
page_length= max_page_size;
break;
case KEY_OP_MULTI_COPY: /* 9 */
{
/*
List of fixed-len memcpy() operations with their source located inside
the page. The log record's piece looks like:
first the length 'full_length' to be used by memcpy()
then the number of bytes used by the list of (to,from) pairs
then the (to,from) pairs, so we do:
for (t,f) in [list of (to,from) pairs]:
memcpy(t, f, full_length).
*/
uint full_length, log_memcpy_length;
const uchar *log_memcpy_end;
DBUG_PRINT("redo", ("key_op_multi_copy"));
full_length= uint2korr(header);
header+= 2;
log_memcpy_length= uint2korr(header);
header+= 2;
log_memcpy_end= header + log_memcpy_length;
DBUG_ASSERT(full_length <= max_page_size);
while (header < log_memcpy_end)
{
uint to, from;
to= uint2korr(header);
header+= 2;
from= uint2korr(header);
header+= 2;
/* "from" is a place in the existing page */
DBUG_ASSERT(MY_MAX(from, to) < max_page_size);
memcpy(buff + to, buff + from, full_length);
}
break;
}
case KEY_OP_SET_PAGEFLAG:
DBUG_PRINT("redo", ("key_op_set_pageflag"));
_ma_store_keypage_flag(share, buff, *header++);
break;
case KEY_OP_COMPACT_PAGE:
{
TrID transid= transid_korr(header);
DBUG_PRINT("redo", ("key_op_compact_page"));
header+= TRANSID_SIZE;
if (_ma_compact_keypage(&page, transid))
{
result= mark_crashed= 1;
goto err;
}
page_length= page.size;
break;
}
case KEY_OP_NONE:
default:
DBUG_ASSERT(0);
result= mark_crashed= 1;
goto err;
}
} while (header < header_end);
DBUG_ASSERT(header == header_end);
DBUG_ASSERT(new_page_length == 0 || new_page_length == page_length);
/* Write modified page */
page.size= page_length;
_ma_store_page_used(share, buff, page_length);
/*
Clean old stuff up. Gives us better compression of we archive things
and makes things easer to debug
*/
if (page_length < org_page_length)
bzero(buff + page_length, org_page_length-page_length);
/* Mark page to be unlocked and written at _ma_unpin_all_pages() */
page_link.unlock= PAGECACHE_LOCK_WRITE_UNLOCK;
page_link.changed= 1;
push_dynamic(&info->pinned_pages, (void*) &page_link);
DBUG_RETURN(0);
err:
pagecache_unlock_by_link(share->pagecache, page_link.link,
PAGECACHE_LOCK_WRITE_UNLOCK,
PAGECACHE_UNPIN, LSN_IMPOSSIBLE,
LSN_IMPOSSIBLE, 0, FALSE);
if (mark_crashed)
_ma_mark_file_crashed(share);
DBUG_RETURN(result);
} | O3 | c | ma_apply_redo_index:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movl %ecx, -0x38(%rbp)
movq %rdx, %r14
movq %rsi, -0x30(%rbp)
movq %rdi, %r15
movq (%rdi), %rcx
movl (%rdx), %eax
movzbl 0x4(%rdx), %r13d
shlq $0x20, %r13
orq %rax, %r13
movl 0x7c0(%rcx), %eax
movl %eax, -0x54(%rbp)
movq 0x600(%rcx), %rdi
movq %rcx, -0x40(%rbp)
leaq 0x750(%rcx), %rsi
leaq -0x88(%rbp), %rax
movl $0x1, %r12d
movq %r13, %rdx
xorl %ecx, %ecx
xorl %r8d, %r8d
movl $0x1, %r9d
pushq %rax
pushq $0x4
callq 0x32522
addq $0x10, %rsp
testq %rax, %rax
je 0x5a7bf
movq %rax, %rbx
movq %r15, -0x50(%rbp)
movzwl (%rax), %eax
shlq $0x20, %rax
movzbl 0x2(%rbx), %ecx
shlq $0x30, %rcx
orq %rax, %rcx
movl 0x3(%rbx), %esi
orq %rcx, %rsi
cmpq -0x30(%rbp), %rsi
jge 0x5a7d0
movl -0x38(%rbp), %r8d
addq %r14, %r8
addq $0x5, %r14
movq -0x40(%rbp), %r15
movl 0x744(%r15), %eax
addl $-0x4, %eax
movzbl (%rbx,%rax), %eax
imulq $0x118, %rax, %rdx # imm = 0x118
addq 0x570(%r15), %rdx
leaq -0xc0(%rbp), %rdi
movq -0x50(%rbp), %r12
movq %r12, %rsi
movq %r13, %rcx
movq %r8, %r13
movq %rbx, %r8
callq 0x58d94
movq %r13, %r8
leaq -0xc0(%rbp), %rax
movl 0x20(%rax), %eax
movl 0x744(%r15), %ecx
movq %rcx, -0x68(%rbp)
addq %rbx, %rcx
movq %rcx, -0x60(%rbp)
xorl %r13d, %r13d
leaq 0x86f02(%rip), %rsi # 0xe1418
movq %rax, -0x70(%rbp)
movl %eax, %edx
movq %r8, -0x38(%rbp)
movzbl (%r14), %eax
decl %eax
cmpl $0xd, %eax
ja 0x5a883
leaq 0x1(%r14), %r15
movslq (%rsi,%rax,4), %rax
addq %rsi, %rax
jmpq *%rax
movzwl 0x1(%r14), %r13d
addq $0x3, %r14
jmp 0x5a770
movl -0x54(%rbp), %eax
movl %eax, %edx
movq %r15, %r12
jmp 0x5a773
movl 0x1(%r14), %eax
movzwl 0x5(%r14), %esi
shlq $0x20, %rsi
orq %rax, %rsi
leaq -0xc0(%rbp), %rdi
movq %r8, %r15
callq 0x593f8
leaq 0x86e9b(%rip), %rsi # 0xe1418
testb %al, %al
jne 0x5a883
movq %r15, %r8
addq $0x7, %r14
movl -0xa0(%rbp), %edx
jmp 0x5a770
movzwl 0x3(%r14), %eax
leaq 0x5(%r14), %r12
testq %rax, %rax
je 0x5a773
movq %r13, -0x48(%rbp)
movq %rdx, -0x30(%rbp)
leaq (%r14,%rax), %r13
addq $0x5, %r13
movzwl (%r15), %r14d
movzwl (%r12), %edi
movzwl 0x2(%r12), %esi
addq $0x4, %r12
addq %rbx, %rdi
addq %rbx, %rsi
movq %r14, %rdx
callq 0x29080
cmpq %r13, %r12
jb 0x5a5bd
movq -0x38(%rbp), %r8
leaq 0x86e2e(%rip), %rsi # 0xe1418
movq -0x30(%rbp), %rdx
movq -0x48(%rbp), %r13
jmp 0x5a773
movzwl 0x1(%r14), %r12d
movl %r13d, %edi
addq %rbx, %rdi
addq $0x3, %r14
movq %r14, %rsi
movq %rdx, -0x30(%rbp)
movq %r12, %rdx
movq %r13, %r14
movq %r8, %r13
callq 0x29080
movq %r13, %r8
movq -0x30(%rbp), %rdx
leaq 0x86def(%rip), %rsi # 0xe1418
leal (%r12,%r14), %r13d
jmp 0x5a696
movswl 0x1(%r14), %r12d
testl %r12d, %r12d
js 0x5a788
movq %rdx, %r15
subl %r13d, %edx
je 0x5a7b0
movl %r15d, %esi
addq %rbx, %rsi
movl %r12d, %edi
addq %rsi, %rdi
callq 0xaabc0
jmp 0x5a7a5
movzwl 0x1(%r14), %r12d
movl %edx, %edi
addq %rbx, %rdi
addq $0x3, %r14
movq %r14, %rsi
movq %rdx, -0x30(%rbp)
movq %r12, %rdx
movq %r13, %r14
movq %r8, %r13
callq 0x29080
movq %r13, %r8
movq %r14, %r13
movq -0x30(%rbp), %rdx
leaq 0x86d85(%rip), %rsi # 0xe1418
addl %r12d, %edx
addq %r15, %r12
addq $0x2, %r12
jmp 0x5a773
movzwl 0x1(%r14), %eax
addq $0x3, %r14
subl %eax, %edx
jmp 0x5a770
addq $0x5, %r14
jmp 0x5a770
movb 0x1(%r14), %al
addq $0x2, %r14
movq -0x40(%rbp), %rcx
movl 0x744(%rcx), %ecx
addl $-0x3, %ecx
movb %al, (%rbx,%rcx)
jmp 0x5a770
movzwl 0x1(%r14), %r15d
addq $0x3, %r14
movq %r15, %rsi
movq -0x60(%rbp), %rdi
addq %rdi, %rsi
movq -0x68(%rbp), %r12
movq %rdx, %r13
subl %r12d, %edx
subl %r15d, %edx
callq 0x29120
movq -0x38(%rbp), %r8
movq %r13, %rdx
leaq 0x86d0d(%rip), %rsi # 0xe1418
subl %r15d, %edx
movl %r12d, %r13d
jmp 0x5a770
movzwl 0x1(%r14), %edi
movq %rdi, -0x30(%rbp)
movzwl 0x3(%r14), %r12d
movl %edx, %esi
addq %rbx, %rsi
addq %rsi, %rdi
movq %r13, -0x48(%rbp)
movq %rdx, %r13
subl -0x68(%rbp), %edx
callq 0xaabc0
addq $0x5, %r14
movq -0x60(%rbp), %rdi
movq %r14, %rsi
movq %r12, %rdx
callq 0x29080
movq %r13, %rdx
movq -0x48(%rbp), %r13
leaq 0x86cbf(%rip), %rsi # 0xe1418
addq %r15, %r12
addq $0x4, %r12
movq -0x30(%rbp), %rax
addl %eax, %edx
movq -0x38(%rbp), %r8
jmp 0x5a773
addq $0x2, %r14
movq %r14, %r12
movq %r12, %r14
cmpq %r8, %r12
movq -0x50(%rbp), %r12
jb 0x5a520
jmp 0x5a812
movl %r13d, %edi
addq %rbx, %rdi
movslq %r12d, %rax
movq %rdi, %rsi
subq %rax, %rsi
movq %rdx, %r15
subl %r13d, %edx
addl %r12d, %edx
callq 0x29120
movq -0x38(%rbp), %r8
leaq 0x86c68(%rip), %rsi # 0xe1418
addq $0x3, %r14
addl %r12d, %r15d
movq %r14, %r12
movq %r15, %rdx
jmp 0x5a773
callq 0xa1a0a
movl (%rax), %esi
movq %r15, %rdi
callq 0x36934
jmp 0x5a7e1
xorl %r12d, %r12d
movq -0x50(%rbp), %rdi
xorl %edx, %edx
movq %r13, %rcx
callq 0x4c6e5
movq -0x40(%rbp), %rax
movq 0x600(%rax), %rdi
movq -0x88(%rbp), %rsi
xorl %eax, %eax
movl $0x6, %edx
movl $0x3, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
pushq %rax
pushq %rax
callq 0x3223d
addq $0x10, %rsp
jmp 0x5a86e
movl %edx, -0xa0(%rbp)
movq -0x40(%rbp), %rcx
movl 0x744(%rcx), %eax
movb %dl, -0x1(%rbx,%rax)
movl 0x744(%rcx), %eax
movb %dh, -0x2(%rbx,%rax)
movq %rdx, %rax
movq -0x70(%rbp), %rdx
subl %eax, %edx
jbe 0x5a84a
movl %eax, %eax
addq %rax, %rbx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x292c0
leaq -0x88(%rbp), %rsi
movl $0x6, 0x8(%rsi)
movb $0x1, 0x10(%rsi)
addq $0x2e8, %r12 # imm = 0x2E8
movq %r12, %rdi
callq 0x91aae
xorl %r12d, %r12d
movl %r12d, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq -0x40(%rbp), %rbx
movq 0x600(%rbx), %rdi
movq -0x88(%rbp), %rsi
xorl %eax, %eax
movl $0x6, %edx
movl $0x3, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
pushq %rax
pushq %rax
callq 0x3223d
addq $0x10, %rsp
movq %rbx, %rdi
callq 0x38132
movl $0x1, %r12d
jmp 0x5a86e
| _ma_apply_redo_index:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 98h
mov dword ptr [rbp+var_38], ecx
mov r14, rdx
mov [rbp+var_30], rsi
mov r15, rdi
mov rcx, [rdi]
mov eax, [rdx]
movzx r13d, byte ptr [rdx+4]
shl r13, 20h
or r13, rax
mov eax, [rcx+7C0h]
mov [rbp+var_54], eax
mov rdi, [rcx+600h]
mov [rbp+var_40], rcx
lea rsi, [rcx+750h]
lea rax, [rbp+var_88]
mov r12d, 1
mov rdx, r13
xor ecx, ecx
xor r8d, r8d
mov r9d, 1
push rax
push 4
call pagecache_read
add rsp, 10h
test rax, rax
jz loc_5A7BF
mov rbx, rax
mov [rbp+var_50], r15
movzx eax, word ptr [rax]
shl rax, 20h
movzx ecx, byte ptr [rbx+2]
shl rcx, 30h
or rcx, rax
mov esi, [rbx+3]
or rsi, rcx
cmp rsi, [rbp+var_30]
jge loc_5A7D0
mov r8d, dword ptr [rbp+var_38]
add r8, r14
add r14, 5
mov r15, [rbp+var_40]
mov eax, [r15+744h]
add eax, 0FFFFFFFCh
movzx eax, byte ptr [rbx+rax]
imul rdx, rax, 118h
add rdx, [r15+570h]
lea rdi, [rbp+var_C0]
mov r12, [rbp+var_50]
mov rsi, r12
mov rcx, r13
mov r13, r8
mov r8, rbx
call _ma_page_setup
mov r8, r13
lea rax, [rbp+var_C0]
mov eax, [rax+20h]
mov ecx, [r15+744h]
mov [rbp+var_68], rcx
add rcx, rbx
mov [rbp+var_60], rcx
xor r13d, r13d
lea rsi, jpt_5A53A
mov [rbp+var_70], rax
mov edx, eax
mov [rbp+var_38], r8
loc_5A520:
movzx eax, byte ptr [r14]
dec eax; switch 14 cases
cmp eax, 0Dh
ja def_5A53A; jumptable 000000000005A53A default case
lea r15, [r14+1]
movsxd rax, ds:(jpt_5A53A - 0E1418h)[rsi+rax*4]
add rax, rsi
jmp rax; switch jump
loc_5A53C:
movzx r13d, word ptr [r14+1]; jumptable 000000000005A53A case 1
add r14, 3
jmp loc_5A770
loc_5A54A:
mov eax, [rbp+var_54]; jumptable 000000000005A53A case 12
mov edx, eax
mov r12, r15
jmp loc_5A773
loc_5A557:
mov eax, [r14+1]; jumptable 000000000005A53A case 11
movzx esi, word ptr [r14+5]
shl rsi, 20h
or rsi, rax
lea rdi, [rbp+var_C0]
mov r15, r8
call _ma_compact_keypage
lea rsi, jpt_5A53A
test al, al
jnz def_5A53A; jumptable 000000000005A53A default case
mov r8, r15
add r14, 7
mov edx, [rbp+var_A0]
jmp loc_5A770
loc_5A597:
movzx eax, word ptr [r14+3]; jumptable 000000000005A53A case 9
lea r12, [r14+5]
test rax, rax
jz loc_5A773
mov [rbp+var_48], r13
mov [rbp+var_30], rdx
lea r13, [r14+rax]
add r13, 5
movzx r14d, word ptr [r15]
loc_5A5BD:
movzx edi, word ptr [r12]
movzx esi, word ptr [r12+2]
add r12, 4
add rdi, rbx
add rsi, rbx
mov rdx, r14
call _memcpy
cmp r12, r13
jb short loc_5A5BD
mov r8, [rbp+var_38]
lea rsi, jpt_5A53A
mov rdx, [rbp+var_30]
mov r13, [rbp+var_48]
jmp loc_5A773
loc_5A5F7:
movzx r12d, word ptr [r14+1]; jumptable 000000000005A53A case 3
mov edi, r13d
add rdi, rbx
add r14, 3
mov rsi, r14
mov [rbp+var_30], rdx
mov rdx, r12
mov r14, r13
mov r13, r8
call _memcpy
mov r8, r13
mov rdx, [rbp+var_30]
lea rsi, jpt_5A53A
lea r13d, [r12+r14]
jmp short loc_5A696
loc_5A62F:
movsx r12d, word ptr [r14+1]; jumptable 000000000005A53A case 2
test r12d, r12d
js loc_5A788
mov r15, rdx
sub edx, r13d
jz loc_5A7B0
mov esi, r15d
add rsi, rbx
mov edi, r12d
add rdi, rsi
call bmove_upp
jmp loc_5A7A5
loc_5A65F:
movzx r12d, word ptr [r14+1]; jumptable 000000000005A53A case 6
mov edi, edx
add rdi, rbx
add r14, 3
mov rsi, r14
mov [rbp+var_30], rdx
mov rdx, r12
mov r14, r13
mov r13, r8
call _memcpy
mov r8, r13
mov r13, r14
mov rdx, [rbp+var_30]
lea rsi, jpt_5A53A
add edx, r12d
loc_5A696:
add r12, r15
add r12, 2
jmp loc_5A773
loc_5A6A2:
movzx eax, word ptr [r14+1]; jumptable 000000000005A53A case 7
add r14, 3
sub edx, eax
jmp loc_5A770
loc_5A6B2:
add r14, 5; jumptable 000000000005A53A case 14
jmp loc_5A770
loc_5A6BB:
mov al, [r14+1]; jumptable 000000000005A53A case 10
add r14, 2
mov rcx, [rbp+var_40]
mov ecx, [rcx+744h]
add ecx, 0FFFFFFFDh
mov [rbx+rcx], al
jmp loc_5A770
loc_5A6D8:
movzx r15d, word ptr [r14+1]; jumptable 000000000005A53A case 5
add r14, 3
mov rsi, r15
mov rdi, [rbp+var_60]
add rsi, rdi
mov r12, [rbp+var_68]
mov r13, rdx
sub edx, r12d
sub edx, r15d
call _memmove
mov r8, [rbp+var_38]
mov rdx, r13
lea rsi, jpt_5A53A
sub edx, r15d
mov r13d, r12d
jmp short loc_5A770
loc_5A713:
movzx edi, word ptr [r14+1]; jumptable 000000000005A53A case 4
mov [rbp+var_30], rdi
movzx r12d, word ptr [r14+3]
mov esi, edx
add rsi, rbx
add rdi, rsi
mov [rbp+var_48], r13
mov r13, rdx
sub edx, dword ptr [rbp+var_68]
call bmove_upp
add r14, 5
mov rdi, [rbp+var_60]
mov rsi, r14
mov rdx, r12
call _memcpy
mov rdx, r13
mov r13, [rbp+var_48]
lea rsi, jpt_5A53A
add r12, r15
add r12, 4
mov rax, [rbp+var_30]
add edx, eax
mov r8, [rbp+var_38]
jmp short loc_5A773
loc_5A76C:
add r14, 2; jumptable 000000000005A53A case 13
loc_5A770:
mov r12, r14
loc_5A773:
mov r14, r12
cmp r12, r8
mov r12, [rbp+var_50]
jb loc_5A520
jmp loc_5A812; jumptable 000000000005A53A case 8
loc_5A788:
mov edi, r13d
add rdi, rbx
movsxd rax, r12d
mov rsi, rdi
sub rsi, rax
mov r15, rdx
sub edx, r13d
add edx, r12d
call _memmove
loc_5A7A5:
mov r8, [rbp+var_38]
lea rsi, jpt_5A53A
loc_5A7B0:
add r14, 3
add r15d, r12d
mov r12, r14
mov rdx, r15
jmp short loc_5A773
loc_5A7BF:
call _my_thread_var
mov esi, [rax]
mov rdi, r15
call _ma_set_fatal_error
jmp short loc_5A7E1
loc_5A7D0:
xor r12d, r12d
mov rdi, [rbp+var_50]
xor edx, edx
mov rcx, r13
call check_skipped_lsn
loc_5A7E1:
mov rax, [rbp+var_40]
mov rdi, [rax+600h]
mov rsi, [rbp+var_88]
xor eax, eax
mov edx, 6
mov ecx, 3
xor r8d, r8d
xor r9d, r9d
push rax
push rax
call pagecache_unlock_by_link
add rsp, 10h
jmp short loc_5A86E
loc_5A812:
mov [rbp+var_A0], edx; jumptable 000000000005A53A case 8
mov rcx, [rbp+var_40]
mov eax, [rcx+744h]
mov [rbx+rax-1], dl
mov eax, [rcx+744h]
mov [rbx+rax-2], dh
mov rax, rdx
mov rdx, [rbp+var_70]
sub edx, eax
jbe short loc_5A84A
mov eax, eax
add rbx, rax
mov rdi, rbx
xor esi, esi
call _memset
loc_5A84A:
lea rsi, [rbp+var_88]
mov dword ptr [rsi+8], 6
mov byte ptr [rsi+10h], 1
add r12, 2E8h
mov rdi, r12
call insert_dynamic
xor r12d, r12d
loc_5A86E:
mov eax, r12d
add rsp, 98h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
def_5A53A:
mov rbx, [rbp+var_40]; jumptable 000000000005A53A default case
mov rdi, [rbx+600h]
mov rsi, [rbp+var_88]
xor eax, eax
mov edx, 6
mov ecx, 3
xor r8d, r8d
xor r9d, r9d
push rax
push rax
call pagecache_unlock_by_link
add rsp, 10h
mov rdi, rbx
call _ma_mark_file_crashed
mov r12d, 1
jmp short loc_5A86E
| long long ma_apply_redo_index(long long *a1, signed long long a2, unsigned int *a3, int a4)
{
long long v6; // rcx
unsigned long long v7; // r13
long long v8; // rdi
const char *v9; // rsi
unsigned int v10; // r12d
unsigned __int16 *v11; // rax
unsigned __int16 *v12; // rbx
signed long long v13; // rsi
char *v14; // r8
unsigned __int16 *v15; // r14
long long v16; // r15
long long *v17; // r12
long long v18; // rcx
char *v19; // r13
unsigned long long v20; // r8
long long v21; // r13
signed long long v22; // rdx
unsigned __int16 *v23; // r15
unsigned __int16 *v24; // r14
unsigned __int16 *v25; // r12
unsigned long long v26; // r15
long long v27; // rax
unsigned long long v28; // r13
long long v29; // r14
long long v30; // rdi
long long v31; // rsi
long long v32; // r12
char *v33; // rdi
char *v34; // rsi
int v35; // r14d
unsigned long long v36; // r13
int v37; // r12d
int v38; // r15d
char *v39; // rsi
long long v40; // r14
unsigned long long v41; // r13
int v42; // eax
char v43; // al
long long v44; // r15
unsigned int v45; // r12d
int v46; // r13d
long long v47; // r12
int v48; // r13d
int v49; // edx
bool v50; // cf
signed long long v51; // r15
unsigned int *v52; // rax
long long v53; // rdx
long long v54; // rcx
long long v55; // r8
int v56; // r9d
long long v57; // rcx
unsigned int v58; // eax
long long v59; // rdx
long long v61; // rbx
_BYTE v62[32]; // [rsp+0h] [rbp-C0h] BYREF
unsigned int v63; // [rsp+20h] [rbp-A0h]
long long v64; // [rsp+38h] [rbp-88h] BYREF
int v65; // [rsp+40h] [rbp-80h]
char v66; // [rsp+48h] [rbp-78h]
long long v67; // [rsp+50h] [rbp-70h]
long long v68; // [rsp+58h] [rbp-68h]
char *v69; // [rsp+60h] [rbp-60h]
unsigned int v70; // [rsp+6Ch] [rbp-54h]
long long *v71; // [rsp+70h] [rbp-50h]
long long v72; // [rsp+78h] [rbp-48h]
long long v73; // [rsp+80h] [rbp-40h]
unsigned long long v74; // [rsp+88h] [rbp-38h]
signed long long v75; // [rsp+90h] [rbp-30h]
LODWORD(v74) = a4;
v75 = a2;
v6 = *a1;
v7 = *a3 | ((unsigned long long)*((unsigned __int8 *)a3 + 4) << 32);
v70 = *(_DWORD *)(*a1 + 1984);
v8 = *(_QWORD *)(v6 + 1536);
v73 = v6;
v9 = (const char *)(v6 + 1872);
v10 = 1;
v11 = (unsigned __int16 *)pagecache_read(v8, v6 + 1872, v7, 0, 0LL, 1, 4u, &v64);
if ( !v11 )
{
v52 = (unsigned int *)my_thread_var(v8, v9);
ma_set_fatal_error(a1, *v52, v53, v54, v55, v56);
LABEL_33:
pagecache_unlock_by_link(*(_QWORD *)(v73 + 1536), v64, 6, 3, 0LL, 0LL, 0);
return v10;
}
v12 = v11;
v71 = a1;
v13 = ((unsigned long long)*v11 << 32) | ((unsigned long long)*((unsigned __int8 *)v11 + 2) << 48) | *(unsigned int *)((char *)v11 + 3);
if ( v13 >= v75 )
{
v10 = 0;
check_skipped_lsn((long long)v71, v13, 0, v7);
goto LABEL_33;
}
v14 = (char *)a3 + (unsigned int)v74;
v15 = (unsigned __int16 *)((char *)a3 + 5);
v16 = v73;
v17 = v71;
v18 = v7;
v19 = v14;
ma_page_setup(
(long long)v62,
v71,
*(_QWORD *)(v73 + 1392) + 280LL * *((unsigned __int8 *)v11 + (unsigned int)(*(_DWORD *)(v73 + 1860) - 4)),
v18,
(long long)v11);
v20 = (unsigned long long)v19;
v68 = *(unsigned int *)(v16 + 1860);
v69 = (char *)v12 + v68;
v21 = 0LL;
v67 = v63;
v22 = v63;
v74 = v20;
while ( 2 )
{
v23 = (unsigned __int16 *)((char *)v15 + 1);
switch ( *(_BYTE *)v15 )
{
case 1:
v21 = *(unsigned __int16 *)((char *)v15 + 1);
v24 = (unsigned __int16 *)((char *)v15 + 3);
goto LABEL_25;
case 2:
v37 = *(__int16 *)((char *)v15 + 1);
if ( v37 < 0 )
{
v38 = v22;
memmove(
(char *)v12 + (unsigned int)v21,
(char *)v12 + (unsigned int)v21 - *(__int16 *)((char *)v15 + 1),
(unsigned int)(v37 + v22 - v21));
}
else
{
v38 = v22;
if ( (_DWORD)v22 == (_DWORD)v21 )
goto LABEL_30;
bmove_upp((char *)v12 + (unsigned int)v22 + v37, (char *)v12 + (unsigned int)v22);
}
v20 = v74;
LABEL_30:
v51 = (unsigned int)(v37 + v38);
v25 = (unsigned __int16 *)((char *)v15 + 3);
v22 = v51;
LABEL_26:
v15 = v25;
v50 = (unsigned long long)v25 < v20;
v17 = v71;
if ( v50 )
continue;
LABEL_34:
v63 = v22;
v57 = v73;
*((_BYTE *)v12 + *(unsigned int *)(v73 + 1860) - 1) = v22;
*((_BYTE *)v12 + *(unsigned int *)(v57 + 1860) - 2) = BYTE1(v22);
v58 = v22;
v59 = (unsigned int)(v67 - v22);
if ( (unsigned int)v67 > v58 )
memset((char *)v12 + v58, 0LL, v59);
v65 = 6;
v66 = 1;
insert_dynamic(v17 + 93, &v64);
v10 = 0;
break;
case 3:
v32 = *(unsigned __int16 *)((char *)v15 + 1);
v33 = (char *)v12 + (unsigned int)v21;
v34 = (char *)v15 + 3;
v75 = v22;
v35 = v21;
v36 = v20;
memcpy(v33, v34, v32);
v20 = v36;
v22 = v75;
v21 = (unsigned int)(v32 + v35);
goto LABEL_18;
case 4:
v75 = *(unsigned __int16 *)((char *)v15 + 1);
v47 = *(unsigned __int16 *)((char *)v15 + 3);
v72 = v21;
v48 = v22;
bmove_upp((char *)v12 + (unsigned int)v22 + v75, (char *)v12 + (unsigned int)v22);
memcpy(v69, (char *)v15 + 5, v47);
v49 = v48;
v21 = v72;
v25 = (unsigned __int16 *)((char *)v23 + v47 + 4);
v22 = (unsigned int)(v75 + v49);
v20 = v74;
goto LABEL_26;
case 5:
v44 = *(unsigned __int16 *)((char *)v15 + 1);
v24 = (unsigned __int16 *)((char *)v15 + 3);
v45 = v68;
v46 = v22;
memmove(v69, &v69[v44], (unsigned int)(v22 - v68 - v44));
v20 = v74;
v22 = (unsigned int)(v46 - v44);
v21 = v45;
goto LABEL_25;
case 6:
v32 = *(unsigned __int16 *)((char *)v15 + 1);
v39 = (char *)v15 + 3;
v75 = v22;
v40 = v21;
v41 = v20;
memcpy((char *)v12 + (unsigned int)v22, v39, v32);
v20 = v41;
v21 = v40;
v22 = (unsigned int)(v32 + v75);
LABEL_18:
v25 = (unsigned __int16 *)((char *)v23 + v32 + 2);
goto LABEL_26;
case 7:
v42 = *(unsigned __int16 *)((char *)v15 + 1);
v24 = (unsigned __int16 *)((char *)v15 + 3);
v22 = (unsigned int)(v22 - v42);
goto LABEL_25;
case 8:
goto LABEL_34;
case 9:
v27 = *(unsigned __int16 *)((char *)v15 + 3);
v25 = (unsigned __int16 *)((char *)v15 + 5);
if ( *(unsigned __int16 *)((char *)v15 + 3) )
{
v72 = v21;
v75 = v22;
v28 = (unsigned long long)v15 + v27 + 5;
v29 = *v23;
do
{
v30 = *v25;
v31 = v25[1];
v25 += 2;
memcpy((char *)v12 + v30, (char *)v12 + v31, v29);
}
while ( (unsigned long long)v25 < v28 );
v20 = v74;
v22 = v75;
v21 = v72;
}
goto LABEL_26;
case 0xA:
v43 = *((_BYTE *)v15 + 1);
v24 = v15 + 1;
*((_BYTE *)v12 + (unsigned int)(*(_DWORD *)(v73 + 1860) - 3)) = v43;
goto LABEL_25;
case 0xB:
v26 = v20;
if ( (unsigned __int8)ma_compact_keypage(
(long long)v62,
*(unsigned int *)((char *)v15 + 1) | ((unsigned long long)*(unsigned __int16 *)((char *)v15 + 5) << 32)) )
goto LABEL_38;
v20 = v26;
v24 = (unsigned __int16 *)((char *)v15 + 7);
v22 = v63;
LABEL_25:
v25 = v24;
goto LABEL_26;
case 0xC:
v22 = v70;
v25 = (unsigned __int16 *)((char *)v15 + 1);
goto LABEL_26;
case 0xD:
v24 = v15 + 1;
goto LABEL_25;
case 0xE:
v24 = (unsigned __int16 *)((char *)v15 + 5);
goto LABEL_25;
default:
LABEL_38:
v61 = v73;
pagecache_unlock_by_link(*(_QWORD *)(v73 + 1536), v64, 6, 3, 0LL, 0LL, 0);
ma_mark_file_crashed(v61);
return 1;
}
return v10;
}
}
| _ma_apply_redo_index:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x98
MOV dword ptr [RBP + -0x38],ECX
MOV R14,RDX
MOV qword ptr [RBP + -0x30],RSI
MOV R15,RDI
MOV RCX,qword ptr [RDI]
MOV EAX,dword ptr [RDX]
MOVZX R13D,byte ptr [RDX + 0x4]
SHL R13,0x20
OR R13,RAX
MOV EAX,dword ptr [RCX + 0x7c0]
MOV dword ptr [RBP + -0x54],EAX
MOV RDI,qword ptr [RCX + 0x600]
MOV qword ptr [RBP + -0x40],RCX
LEA RSI,[RCX + 0x750]
LEA RAX,[RBP + -0x88]
MOV R12D,0x1
MOV RDX,R13
XOR ECX,ECX
XOR R8D,R8D
MOV R9D,0x1
PUSH RAX
PUSH 0x4
CALL 0x00132522
ADD RSP,0x10
TEST RAX,RAX
JZ 0x0015a7bf
MOV RBX,RAX
MOV qword ptr [RBP + -0x50],R15
MOVZX EAX,word ptr [RAX]
SHL RAX,0x20
MOVZX ECX,byte ptr [RBX + 0x2]
SHL RCX,0x30
OR RCX,RAX
MOV ESI,dword ptr [RBX + 0x3]
OR RSI,RCX
CMP RSI,qword ptr [RBP + -0x30]
JGE 0x0015a7d0
MOV R8D,dword ptr [RBP + -0x38]
ADD R8,R14
ADD R14,0x5
MOV R15,qword ptr [RBP + -0x40]
MOV EAX,dword ptr [R15 + 0x744]
ADD EAX,-0x4
MOVZX EAX,byte ptr [RBX + RAX*0x1]
IMUL RDX,RAX,0x118
ADD RDX,qword ptr [R15 + 0x570]
LEA RDI,[RBP + -0xc0]
MOV R12,qword ptr [RBP + -0x50]
MOV RSI,R12
MOV RCX,R13
MOV R13,R8
MOV R8,RBX
CALL 0x00158d94
MOV R8,R13
LEA RAX,[RBP + -0xc0]
MOV EAX,dword ptr [RAX + 0x20]
MOV ECX,dword ptr [R15 + 0x744]
MOV qword ptr [RBP + -0x68],RCX
ADD RCX,RBX
MOV qword ptr [RBP + -0x60],RCX
XOR R13D,R13D
LEA RSI,[0x1e1418]
MOV qword ptr [RBP + -0x70],RAX
MOV EDX,EAX
MOV qword ptr [RBP + -0x38],R8
LAB_0015a520:
MOVZX EAX,byte ptr [R14]
DEC EAX
CMP EAX,0xd
JA 0x0015a883
LEA R15,[R14 + 0x1]
MOVSXD RAX,dword ptr [RSI + RAX*0x4]
ADD RAX,RSI
switchD:
JMP RAX
caseD_1:
MOVZX R13D,word ptr [R14 + 0x1]
ADD R14,0x3
JMP 0x0015a770
caseD_c:
MOV EAX,dword ptr [RBP + -0x54]
MOV EDX,EAX
MOV R12,R15
JMP 0x0015a773
caseD_b:
MOV EAX,dword ptr [R14 + 0x1]
MOVZX ESI,word ptr [R14 + 0x5]
SHL RSI,0x20
OR RSI,RAX
LEA RDI,[RBP + -0xc0]
MOV R15,R8
CALL 0x001593f8
LEA RSI,[0x1e1418]
TEST AL,AL
JNZ 0x0015a883
MOV R8,R15
ADD R14,0x7
MOV EDX,dword ptr [RBP + -0xa0]
JMP 0x0015a770
caseD_9:
MOVZX EAX,word ptr [R14 + 0x3]
LEA R12,[R14 + 0x5]
TEST RAX,RAX
JZ 0x0015a773
MOV qword ptr [RBP + -0x48],R13
MOV qword ptr [RBP + -0x30],RDX
LEA R13,[R14 + RAX*0x1]
ADD R13,0x5
MOVZX R14D,word ptr [R15]
LAB_0015a5bd:
MOVZX EDI,word ptr [R12]
MOVZX ESI,word ptr [R12 + 0x2]
ADD R12,0x4
ADD RDI,RBX
ADD RSI,RBX
MOV RDX,R14
CALL 0x00129080
CMP R12,R13
JC 0x0015a5bd
MOV R8,qword ptr [RBP + -0x38]
LEA RSI,[0x1e1418]
MOV RDX,qword ptr [RBP + -0x30]
MOV R13,qword ptr [RBP + -0x48]
JMP 0x0015a773
caseD_3:
MOVZX R12D,word ptr [R14 + 0x1]
MOV EDI,R13D
ADD RDI,RBX
ADD R14,0x3
MOV RSI,R14
MOV qword ptr [RBP + -0x30],RDX
MOV RDX,R12
MOV R14,R13
MOV R13,R8
CALL 0x00129080
MOV R8,R13
MOV RDX,qword ptr [RBP + -0x30]
LEA RSI,[0x1e1418]
LEA R13D,[R12 + R14*0x1]
JMP 0x0015a696
caseD_2:
MOVSX R12D,word ptr [R14 + 0x1]
TEST R12D,R12D
JS 0x0015a788
MOV R15,RDX
SUB EDX,R13D
JZ 0x0015a7b0
MOV ESI,R15D
ADD RSI,RBX
MOV EDI,R12D
ADD RDI,RSI
CALL 0x001aabc0
JMP 0x0015a7a5
caseD_6:
MOVZX R12D,word ptr [R14 + 0x1]
MOV EDI,EDX
ADD RDI,RBX
ADD R14,0x3
MOV RSI,R14
MOV qword ptr [RBP + -0x30],RDX
MOV RDX,R12
MOV R14,R13
MOV R13,R8
CALL 0x00129080
MOV R8,R13
MOV R13,R14
MOV RDX,qword ptr [RBP + -0x30]
LEA RSI,[0x1e1418]
ADD EDX,R12D
LAB_0015a696:
ADD R12,R15
ADD R12,0x2
JMP 0x0015a773
caseD_7:
MOVZX EAX,word ptr [R14 + 0x1]
ADD R14,0x3
SUB EDX,EAX
JMP 0x0015a770
caseD_e:
ADD R14,0x5
JMP 0x0015a770
caseD_a:
MOV AL,byte ptr [R14 + 0x1]
ADD R14,0x2
MOV RCX,qword ptr [RBP + -0x40]
MOV ECX,dword ptr [RCX + 0x744]
ADD ECX,-0x3
MOV byte ptr [RBX + RCX*0x1],AL
JMP 0x0015a770
caseD_5:
MOVZX R15D,word ptr [R14 + 0x1]
ADD R14,0x3
MOV RSI,R15
MOV RDI,qword ptr [RBP + -0x60]
ADD RSI,RDI
MOV R12,qword ptr [RBP + -0x68]
MOV R13,RDX
SUB EDX,R12D
SUB EDX,R15D
CALL 0x00129120
MOV R8,qword ptr [RBP + -0x38]
MOV RDX,R13
LEA RSI,[0x1e1418]
SUB EDX,R15D
MOV R13D,R12D
JMP 0x0015a770
caseD_4:
MOVZX EDI,word ptr [R14 + 0x1]
MOV qword ptr [RBP + -0x30],RDI
MOVZX R12D,word ptr [R14 + 0x3]
MOV ESI,EDX
ADD RSI,RBX
ADD RDI,RSI
MOV qword ptr [RBP + -0x48],R13
MOV R13,RDX
SUB EDX,dword ptr [RBP + -0x68]
CALL 0x001aabc0
ADD R14,0x5
MOV RDI,qword ptr [RBP + -0x60]
MOV RSI,R14
MOV RDX,R12
CALL 0x00129080
MOV RDX,R13
MOV R13,qword ptr [RBP + -0x48]
LEA RSI,[0x1e1418]
ADD R12,R15
ADD R12,0x4
MOV RAX,qword ptr [RBP + -0x30]
ADD EDX,EAX
MOV R8,qword ptr [RBP + -0x38]
JMP 0x0015a773
caseD_d:
ADD R14,0x2
LAB_0015a770:
MOV R12,R14
LAB_0015a773:
MOV R14,R12
CMP R12,R8
MOV R12,qword ptr [RBP + -0x50]
JC 0x0015a520
JMP 0x0015a812
LAB_0015a788:
MOV EDI,R13D
ADD RDI,RBX
MOVSXD RAX,R12D
MOV RSI,RDI
SUB RSI,RAX
MOV R15,RDX
SUB EDX,R13D
ADD EDX,R12D
CALL 0x00129120
LAB_0015a7a5:
MOV R8,qword ptr [RBP + -0x38]
LEA RSI,[0x1e1418]
LAB_0015a7b0:
ADD R14,0x3
ADD R15D,R12D
MOV R12,R14
MOV RDX,R15
JMP 0x0015a773
LAB_0015a7bf:
CALL 0x001a1a0a
MOV ESI,dword ptr [RAX]
MOV RDI,R15
CALL 0x00136934
JMP 0x0015a7e1
LAB_0015a7d0:
XOR R12D,R12D
MOV RDI,qword ptr [RBP + -0x50]
XOR EDX,EDX
MOV RCX,R13
CALL 0x0014c6e5
LAB_0015a7e1:
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [RAX + 0x600]
MOV RSI,qword ptr [RBP + -0x88]
XOR EAX,EAX
MOV EDX,0x6
MOV ECX,0x3
XOR R8D,R8D
XOR R9D,R9D
PUSH RAX
PUSH RAX
CALL 0x0013223d
ADD RSP,0x10
JMP 0x0015a86e
caseD_8:
MOV dword ptr [RBP + -0xa0],EDX
MOV RCX,qword ptr [RBP + -0x40]
MOV EAX,dword ptr [RCX + 0x744]
MOV byte ptr [RBX + RAX*0x1 + -0x1],DL
MOV EAX,dword ptr [RCX + 0x744]
MOV byte ptr [RBX + RAX*0x1 + -0x2],DH
MOV RAX,RDX
MOV RDX,qword ptr [RBP + -0x70]
SUB EDX,EAX
JBE 0x0015a84a
MOV EAX,EAX
ADD RBX,RAX
MOV RDI,RBX
XOR ESI,ESI
CALL 0x001292c0
LAB_0015a84a:
LEA RSI,[RBP + -0x88]
MOV dword ptr [RSI + 0x8],0x6
MOV byte ptr [RSI + 0x10],0x1
ADD R12,0x2e8
MOV RDI,R12
CALL 0x00191aae
XOR R12D,R12D
LAB_0015a86e:
MOV EAX,R12D
ADD RSP,0x98
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0015a883:
MOV RBX,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [RBX + 0x600]
MOV RSI,qword ptr [RBP + -0x88]
XOR EAX,EAX
MOV EDX,0x6
MOV ECX,0x3
XOR R8D,R8D
XOR R9D,R9D
PUSH RAX
PUSH RAX
CALL 0x0013223d
ADD RSP,0x10
MOV RDI,RBX
CALL 0x00138132
MOV R12D,0x1
JMP 0x0015a86e
|
int8 _ma_apply_redo_index(long *param_1,ulong param_2,uint5 *param_3,int4 param_4)
{
ushort *puVar1;
ushort uVar2;
ushort uVar3;
ushort uVar4;
char cVar5;
ushort *puVar6;
int4 *puVar7;
int iVar8;
uint uVar9;
ulong uVar10;
long lVar11;
void *__dest;
ushort *puVar12;
int8 uVar13;
ulong uVar14;
int iVar15;
ulong uVar16;
ushort *puVar17;
ushort *puVar18;
int1 local_c8 [32];
uint local_a8;
int8 local_90;
int4 local_88;
int1 local_80;
ulong local_78;
ulong local_70;
void *local_68;
uint local_5c;
long *local_58;
ulong local_50;
long local_48;
ushort *local_40;
ulong local_38;
local_40 = (ushort *)CONCAT44(local_40._4_4_,param_4);
local_48 = *param_1;
uVar16 = (ulong)*param_3;
local_5c = *(uint *)(local_48 + 0x7c0);
uVar13 = 1;
local_38 = param_2;
puVar6 = (ushort *)
pagecache_read(*(int8 *)(local_48 + 0x600),local_48 + 0x750,uVar16,0,0,1,4,
&local_90);
lVar11 = local_48;
if (puVar6 == (ushort *)0x0) {
puVar7 = (int4 *)_my_thread_var();
_ma_set_fatal_error(param_1,*puVar7);
}
else {
uVar10 = (ulong)*(uint *)((long)puVar6 + 3) |
(ulong)(byte)puVar6[1] << 0x30 | (ulong)*puVar6 << 0x20;
local_58 = param_1;
if ((long)uVar10 < (long)local_38) {
puVar12 = (ushort *)(((ulong)local_40 & 0xffffffff) + (long)param_3);
_ma_page_setup(local_c8,param_1,
(ulong)*(byte *)((long)puVar6 + (ulong)(*(int *)(local_48 + 0x744) - 4)) *
0x118 + *(long *)(local_48 + 0x570),uVar16,puVar6);
local_78 = (ulong)local_a8;
local_70 = (ulong)*(uint *)(lVar11 + 0x744);
local_68 = (void *)(local_70 + (long)puVar6);
uVar10 = 0;
uVar16 = (ulong)local_a8;
puVar17 = (ushort *)((long)param_3 + 5);
local_40 = puVar12;
do {
uVar14 = local_70;
if (0xd < (byte)*puVar17 - 1) {
LAB_0015a883:
lVar11 = local_48;
pagecache_unlock_by_link(*(int8 *)(local_48 + 0x600),local_90,6,3,0,0,0,0);
_ma_mark_file_crashed(lVar11);
return 1;
}
puVar1 = (ushort *)((long)puVar17 + 1);
iVar15 = (int)uVar10;
iVar8 = (int)uVar16;
switch((uint)(byte)*puVar17) {
case 1:
uVar10 = (ulong)*(ushort *)((long)puVar17 + 1);
puVar18 = (ushort *)((long)puVar17 + 3);
break;
case 2:
uVar9 = (uint)*(short *)((long)puVar17 + 1);
if (*(short *)((long)puVar17 + 1) < 0) {
__dest = (void *)((uVar10 & 0xffffffff) + (long)puVar6);
memmove(__dest,(void *)((long)__dest - (long)(int)uVar9),
(ulong)((iVar8 - iVar15) + uVar9));
puVar12 = local_40;
}
else if (iVar8 != iVar15) {
bmove_upp((long)puVar6 + (ulong)uVar9 + (uVar16 & 0xffffffff));
puVar12 = local_40;
}
puVar18 = (ushort *)((long)puVar17 + 3);
uVar16 = (ulong)(iVar8 + uVar9);
break;
case 3:
uVar2 = *(ushort *)((long)puVar17 + 1);
uVar14 = (ulong)uVar2;
local_38 = uVar16;
memcpy((void *)((uVar10 & 0xffffffff) + (long)puVar6),(byte *)((long)puVar17 + 3),uVar14);
uVar10 = (ulong)((uint)uVar2 + iVar15);
uVar16 = local_38;
goto LAB_0015a696;
case 4:
local_38 = (ulong)*(ushort *)((long)puVar17 + 1);
uVar2 = *(ushort *)((long)puVar17 + 3);
lVar11 = (uVar16 & 0xffffffff) + (long)puVar6;
local_50 = uVar10;
bmove_upp(local_38 + lVar11,lVar11,iVar8 - (int)local_70);
memcpy(local_68,(byte *)((long)puVar17 + 5),(ulong)uVar2);
puVar18 = (ushort *)((long)puVar1 + (ulong)uVar2 + 4);
uVar16 = (ulong)(uint)(iVar8 + (int)local_38);
puVar12 = local_40;
uVar10 = local_50;
break;
case 5:
uVar2 = *(ushort *)((long)puVar17 + 1);
puVar18 = (ushort *)((long)puVar17 + 3);
memmove(local_68,(void *)((ulong)uVar2 + (long)local_68),
(ulong)((iVar8 - (int)local_70) - (uint)uVar2));
uVar16 = (ulong)(iVar8 - (uint)uVar2);
uVar10 = uVar14 & 0xffffffff;
puVar12 = local_40;
break;
case 6:
uVar2 = *(ushort *)((long)puVar17 + 1);
uVar14 = (ulong)uVar2;
local_38 = uVar16;
memcpy((void *)((uVar16 & 0xffffffff) + (long)puVar6),(byte *)((long)puVar17 + 3),uVar14);
uVar16 = (ulong)((int)local_38 + (uint)uVar2);
LAB_0015a696:
puVar18 = (ushort *)((long)puVar1 + uVar14 + 2);
break;
case 7:
puVar18 = (ushort *)((long)puVar17 + 3);
uVar16 = (ulong)(iVar8 - (uint)*(ushort *)((long)puVar17 + 1));
break;
case 8:
goto switchD_0015a53a_caseD_8;
case 9:
uVar2 = *(ushort *)((long)puVar17 + 3);
puVar18 = (ushort *)((long)puVar17 + 5);
if ((ulong)uVar2 != 0) {
uVar3 = *puVar1;
local_50 = uVar10;
local_38 = uVar16;
do {
uVar4 = *puVar18;
puVar12 = puVar18 + 1;
puVar18 = puVar18 + 2;
memcpy((void *)((ulong)uVar4 + (long)puVar6),(void *)((ulong)*puVar12 + (long)puVar6),
(ulong)uVar3);
uVar16 = local_38;
puVar12 = local_40;
uVar10 = local_50;
} while (puVar18 < (ushort *)((long)puVar17 + (ulong)uVar2 + 5));
}
break;
case 10:
puVar18 = puVar17 + 1;
*(byte *)((long)puVar6 + (ulong)(*(int *)(local_48 + 0x744) - 3)) =
*(byte *)((long)puVar17 + 1);
break;
case 0xb:
cVar5 = _ma_compact_keypage(local_c8,(ulong)*(uint6 *)((long)puVar17 + 1));
if (cVar5 != '\0') goto LAB_0015a883;
puVar18 = (ushort *)((long)puVar17 + 7);
uVar16 = (ulong)local_a8;
break;
case 0xc:
uVar16 = (ulong)local_5c;
puVar18 = puVar1;
break;
case 0xd:
puVar18 = puVar17 + 1;
break;
case 0xe:
puVar18 = (ushort *)((long)puVar17 + 5);
}
param_1 = local_58;
puVar17 = puVar18;
} while (puVar18 < puVar12);
switchD_0015a53a_caseD_8:
local_a8 = (uint)uVar16;
*(char *)((long)puVar6 + ((ulong)*(uint *)(local_48 + 0x744) - 1)) = (char)uVar16;
*(char *)((long)puVar6 + ((ulong)*(uint *)(local_48 + 0x744) - 2)) = (char)(uVar16 >> 8);
uVar9 = (uint)local_78 - local_a8;
if (local_a8 <= (uint)local_78 && uVar9 != 0) {
memset((void *)((long)puVar6 + (uVar16 & 0xffffffff)),0,(ulong)uVar9);
}
local_88 = 6;
local_80 = 1;
insert_dynamic(param_1 + 0x5d);
return 0;
}
uVar13 = 0;
check_skipped_lsn(param_1,uVar10,0,uVar16);
}
pagecache_unlock_by_link(*(int8 *)(local_48 + 0x600),local_90,6,3,0,0,0,0);
return uVar13;
}
| |
55,518 | my_numchars_mb | eloqsql/strings/ctype-mb.c | size_t my_numchars_mb(CHARSET_INFO *cs __attribute__((unused)),
const char *pos, const char *end)
{
register size_t count= 0;
while (pos < end)
{
uint mb_len;
pos+= (mb_len= my_ismbchar(cs,pos,end)) ? mb_len : 1;
count++;
}
return count;
} | O3 | c | my_numchars_mb:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
cmpq %rdx, %rsi
jae 0x3b225
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r12
xorl %r14d, %r14d
movl $0x1, %r13d
movq 0xb8(%r12), %rax
movq %r12, %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq *0xc0(%rax)
cmpl $0x2, %eax
cmovbl %r13d, %eax
cmovll %r13d, %eax
addq %rax, %r15
incq %r14
cmpq %rbx, %r15
jb 0x3b1f6
jmp 0x3b228
xorl %r14d, %r14d
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| my_numchars_mb:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
cmp rsi, rdx
jnb short loc_3B225
mov rbx, rdx
mov r15, rsi
mov r12, rdi
xor r14d, r14d
mov r13d, 1
loc_3B1F6:
mov rax, [r12+0B8h]
mov rdi, r12
mov rsi, r15
mov rdx, rbx
call qword ptr [rax+0C0h]
cmp eax, 2
cmovb eax, r13d
cmovl eax, r13d
add r15, rax
inc r14
cmp r15, rbx
jb short loc_3B1F6
jmp short loc_3B228
loc_3B225:
xor r14d, r14d
loc_3B228:
mov rax, r14
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long my_numchars_mb(long long a1, unsigned long long a2, unsigned long long a3)
{
unsigned long long v4; // r15
long long v5; // r14
long long v6; // rax
bool v7; // cc
if ( a2 >= a3 )
return 0LL;
v4 = a2;
v5 = 0LL;
do
{
v6 = (*(long long ( **)(long long, unsigned long long, unsigned long long))(*(_QWORD *)(a1 + 184) + 192LL))(
a1,
v4,
a3);
v7 = (int)v6 < 2;
if ( (unsigned int)v6 < 2 )
v6 = 1LL;
if ( v7 )
v6 = 1LL;
v4 += v6;
++v5;
}
while ( v4 < a3 );
return v5;
}
| my_numchars_mb:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
CMP RSI,RDX
JNC 0x0013b225
MOV RBX,RDX
MOV R15,RSI
MOV R12,RDI
XOR R14D,R14D
MOV R13D,0x1
LAB_0013b1f6:
MOV RAX,qword ptr [R12 + 0xb8]
MOV RDI,R12
MOV RSI,R15
MOV RDX,RBX
CALL qword ptr [RAX + 0xc0]
CMP EAX,0x2
CMOVC EAX,R13D
CMOVL EAX,R13D
ADD R15,RAX
INC R14
CMP R15,RBX
JC 0x0013b1f6
JMP 0x0013b228
LAB_0013b225:
XOR R14D,R14D
LAB_0013b228:
MOV RAX,R14
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
long my_numchars_mb(long param_1,ulong param_2,ulong param_3)
{
uint uVar1;
ulong uVar2;
long lVar3;
if (param_2 < param_3) {
lVar3 = 0;
do {
uVar1 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,param_3);
uVar2 = (ulong)uVar1;
if (uVar1 < 2) {
uVar2 = 1;
}
if ((int)uVar1 < 2) {
uVar2 = 1;
}
param_2 = param_2 + uVar2;
lVar3 = lVar3 + 1;
} while (param_2 < param_3);
}
else {
lVar3 = 0;
}
return lVar3;
}
| |
55,519 | mysql_once_init | eloqsql/libmariadb/libmariadb/mariadb_lib.c | static int mysql_once_init()
#else
static void mysql_once_init()
#endif
{
ma_init(); /* Will init threads */
init_client_errs();
get_default_configuration_dirs();
set_default_charset_by_name(MARIADB_DEFAULT_CHARSET, 0);
if (mysql_client_plugin_init())
{
#ifdef _WIN32
return 1;
#else
return;
#endif
}
if (!mysql_port)
{
#if !__has_feature(memory_sanitizer) /* work around MSAN deficiency */
struct servent *serv_ptr;
#endif
char *env;
mysql_port = MARIADB_PORT;
#if !__has_feature(memory_sanitizer) /* work around MSAN deficiency */
if ((serv_ptr = getservbyname("mysql", "tcp")))
mysql_port = (uint)ntohs((ushort)serv_ptr->s_port);
#endif
if ((env = getenv("MYSQL_TCP_PORT")))
mysql_port =(uint)atoi(env);
}
if (!mysql_unix_port)
{
char *env;
#ifdef _WIN32
mysql_unix_port = (char*)MARIADB_NAMEDPIPE;
#else
mysql_unix_port = (char*)MARIADB_UNIX_ADDR;
#endif
if ((env = getenv("MYSQL_UNIX_PORT")) ||
(env = getenv("MARIADB_UNIX_PORT")))
mysql_unix_port = env;
} | O0 | c | mysql_once_init:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
callq 0x2ff40
callq 0x20710
movb $0x0, %al
callq 0x1f840
leaq 0x22f8e(%rip), %rdi # 0x5070e
xorl %esi, %esi
callq 0x1f570
movb $0x0, %al
callq 0x45260
cmpl $0x0, %eax
je 0x2d798
jmp 0x2d898
leaq 0x36b81(%rip), %rax # 0x64320
cmpl $0x0, (%rax)
jne 0x2d815
leaq 0x36b75(%rip), %rax # 0x64320
movl $0xcea, (%rax) # imm = 0xCEA
leaq 0x24ab4(%rip), %rdi # 0x5226c
leaq 0x258b5(%rip), %rsi # 0x53074
callq 0x17070
movq %rax, -0x8(%rbp)
cmpq $0x0, %rax
je 0x2d7e9
movq -0x8(%rbp), %rax
movl 0x10(%rax), %eax
movzwl %ax, %edi
callq 0x17a90
movzwl %ax, %ecx
leaq 0x36b39(%rip), %rax # 0x64320
movl %ecx, (%rax)
leaq 0x25888(%rip), %rdi # 0x53078
callq 0x17720
movq %rax, -0x10(%rbp)
cmpq $0x0, %rax
je 0x2d813
movq -0x10(%rbp), %rdi
callq 0x17910
movl %eax, %ecx
leaq 0x36b0f(%rip), %rax # 0x64320
movl %ecx, (%rax)
jmp 0x2d815
leaq 0x36b0c(%rip), %rax # 0x64328
cmpq $0x0, (%rax)
jne 0x2d86f
leaq 0x36aff(%rip), %rax # 0x64328
leaq 0x25857(%rip), %rcx # 0x53087
movq %rcx, (%rax)
leaq 0x2585d(%rip), %rdi # 0x53097
callq 0x17720
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
jne 0x2d85f
leaq 0x25857(%rip), %rdi # 0x530a7
callq 0x17720
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
je 0x2d86d
movq -0x18(%rbp), %rcx
leaq 0x36abe(%rip), %rax # 0x64328
movq %rcx, (%rax)
jmp 0x2d86f
leaq 0x36aea(%rip), %rax # 0x64360
cmpb $0x0, (%rax)
jne 0x2d880
callq 0x3ba40
xorl %eax, %eax
movl %eax, %esi
movq %rsi, %rdi
callq 0x463e0
callq 0x2d8a0
movb $0x1, 0x36aac(%rip) # 0x64344
addq $0x20, %rsp
popq %rbp
retq
nop
| mysql_once_init:
push rbp
mov rbp, rsp
sub rsp, 20h
call ma_init
call init_client_errs
mov al, 0
call get_default_configuration_dirs
lea rdi, aUtf8mb4; "utf8mb4"
xor esi, esi
call set_default_charset_by_name
mov al, 0
call mysql_client_plugin_init
cmp eax, 0
jz short loc_2D798
jmp loc_2D898
loc_2D798:
lea rax, mysql_port
cmp dword ptr [rax], 0
jnz short loc_2D815
lea rax, mysql_port
mov dword ptr [rax], 0CEAh
lea rdi, aEtcMysql+5; "mysql"
lea rsi, aTcp; "tcp"
call _getservbyname
mov [rbp+var_8], rax
cmp rax, 0
jz short loc_2D7E9
mov rax, [rbp+var_8]
mov eax, [rax+10h]
movzx edi, ax
call _ntohs
movzx ecx, ax
lea rax, mysql_port
mov [rax], ecx
loc_2D7E9:
lea rdi, aMysqlTcpPort; "MYSQL_TCP_PORT"
call _getenv
mov [rbp+var_10], rax
cmp rax, 0
jz short loc_2D813
mov rdi, [rbp+var_10]
call _atoi
mov ecx, eax
lea rax, mysql_port
mov [rax], ecx
loc_2D813:
jmp short $+2
loc_2D815:
lea rax, mysql_unix_port
cmp qword ptr [rax], 0
jnz short loc_2D86F
lea rax, mysql_unix_port
lea rcx, aTmpMysqlSock; "/tmp/mysql.sock"
mov [rax], rcx
lea rdi, aMysqlUnixPort; "MYSQL_UNIX_PORT"
call _getenv
mov [rbp+var_18], rax
cmp rax, 0
jnz short loc_2D85F
lea rdi, aMariadbUnixPor; "MARIADB_UNIX_PORT"
call _getenv
mov [rbp+var_18], rax
cmp rax, 0
jz short loc_2D86D
loc_2D85F:
mov rcx, [rbp+var_18]
lea rax, mysql_unix_port
mov [rax], rcx
loc_2D86D:
jmp short $+2
loc_2D86F:
lea rax, mysql_ps_subsystem_initialized
cmp byte ptr [rax], 0
jnz short loc_2D880
call mysql_init_ps_subsystem
loc_2D880:
xor eax, eax
mov esi, eax
mov rdi, rsi
call ma_tls_start
call ignore_sigpipe
mov cs:mysql_client_init, 1
loc_2D898:
add rsp, 20h
pop rbp
retn
| long long mysql_once_init()
{
long long result; // rax
long long v1; // [rsp+8h] [rbp-18h]
long long v2; // [rsp+10h] [rbp-10h]
long long v3; // [rsp+18h] [rbp-8h]
ma_init();
init_client_errs();
get_default_configuration_dirs();
set_default_charset_by_name((long long)"utf8mb4");
result = mysql_client_plugin_init("utf8mb4", 0LL);
if ( !(_DWORD)result )
{
if ( !mysql_port )
{
mysql_port = 3306;
v3 = getservbyname("mysql", "tcp");
if ( v3 )
mysql_port = (unsigned __int16)ntohs((unsigned __int16)*(_DWORD *)(v3 + 16));
v2 = getenv("MYSQL_TCP_PORT");
if ( v2 )
mysql_port = atoi(v2);
}
if ( !mysql_unix_port )
{
mysql_unix_port = "/tmp/mysql.sock";
v1 = getenv("MYSQL_UNIX_PORT");
if ( v1 || (v1 = getenv("MARIADB_UNIX_PORT")) != 0 )
mysql_unix_port = v1;
}
if ( !mysql_ps_subsystem_initialized )
mysql_init_ps_subsystem();
ma_tls_start(0LL);
result = ignore_sigpipe();
mysql_client_init = 1;
}
return result;
}
| mysql_once_init:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
CALL 0x0012ff40
CALL 0x00120710
MOV AL,0x0
CALL 0x0011f840
LEA RDI,[0x15070e]
XOR ESI,ESI
CALL 0x0011f570
MOV AL,0x0
CALL 0x00145260
CMP EAX,0x0
JZ 0x0012d798
JMP 0x0012d898
LAB_0012d798:
LEA RAX,[0x164320]
CMP dword ptr [RAX],0x0
JNZ 0x0012d815
LEA RAX,[0x164320]
MOV dword ptr [RAX],0xcea
LEA RDI,[0x15226c]
LEA RSI,[0x153074]
CALL 0x00117070
MOV qword ptr [RBP + -0x8],RAX
CMP RAX,0x0
JZ 0x0012d7e9
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x10]
MOVZX EDI,AX
CALL 0x00117a90
MOVZX ECX,AX
LEA RAX,[0x164320]
MOV dword ptr [RAX],ECX
LAB_0012d7e9:
LEA RDI,[0x153078]
CALL 0x00117720
MOV qword ptr [RBP + -0x10],RAX
CMP RAX,0x0
JZ 0x0012d813
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00117910
MOV ECX,EAX
LEA RAX,[0x164320]
MOV dword ptr [RAX],ECX
LAB_0012d813:
JMP 0x0012d815
LAB_0012d815:
LEA RAX,[0x164328]
CMP qword ptr [RAX],0x0
JNZ 0x0012d86f
LEA RAX,[0x164328]
LEA RCX,[0x153087]
MOV qword ptr [RAX],RCX
LEA RDI,[0x153097]
CALL 0x00117720
MOV qword ptr [RBP + -0x18],RAX
CMP RAX,0x0
JNZ 0x0012d85f
LEA RDI,[0x1530a7]
CALL 0x00117720
MOV qword ptr [RBP + -0x18],RAX
CMP RAX,0x0
JZ 0x0012d86d
LAB_0012d85f:
MOV RCX,qword ptr [RBP + -0x18]
LEA RAX,[0x164328]
MOV qword ptr [RAX],RCX
LAB_0012d86d:
JMP 0x0012d86f
LAB_0012d86f:
LEA RAX,[0x164360]
CMP byte ptr [RAX],0x0
JNZ 0x0012d880
CALL 0x0013ba40
LAB_0012d880:
XOR EAX,EAX
MOV ESI,EAX
MOV RDI,RSI
CALL 0x001463e0
CALL 0x0012d8a0
MOV byte ptr [0x00164344],0x1
LAB_0012d898:
ADD RSP,0x20
POP RBP
RET
|
void mysql_once_init(void)
{
uint16_t uVar1;
int iVar2;
servent *psVar3;
char *__nptr;
char *local_20;
ma_init();
init_client_errs();
get_default_configuration_dirs();
set_default_charset_by_name("utf8mb4",0);
iVar2 = mysql_client_plugin_init();
if (iVar2 == 0) {
if (mysql_port == 0) {
mysql_port = 0xcea;
psVar3 = getservbyname("mysql","tcp");
if (psVar3 != (servent *)0x0) {
uVar1 = ntohs((uint16_t)psVar3->s_port);
mysql_port = (uint)uVar1;
}
__nptr = getenv("MYSQL_TCP_PORT");
if (__nptr != (char *)0x0) {
mysql_port = atoi(__nptr);
}
}
if (mysql_unix_port == (char *)0x0) {
mysql_unix_port = "/tmp/mysql.sock";
local_20 = getenv("MYSQL_UNIX_PORT");
if ((local_20 != (char *)0x0) ||
(local_20 = getenv("MARIADB_UNIX_PORT"), local_20 != (char *)0x0)) {
mysql_unix_port = local_20;
}
}
if (mysql_ps_subsystem_initialized == '\0') {
mysql_init_ps_subsystem();
}
ma_tls_start(0);
ignore_sigpipe();
mysql_client_init = 1;
}
return;
}
| |
55,520 | my_mb_wc_eucjpms | eloqsql/strings/ctype-eucjpms.c | static int
my_mb_wc_eucjpms(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t *pwc, const uchar *s, const uchar *e)
{
int hi;
if (s >= e)
return MY_CS_TOOSMALL;
if ((hi= s[0]) < 0x80) /* ASCII code set: [00..7F] -> [U+0000..U+007F] */
{
*pwc= hi;
return 1;
}
if (hi >= 0xA1 && hi <= 0xFE) /* JIS X 0208 code set: [A1..FE][A1..FE] */
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
return (*pwc= jisx0208_eucjpms_to_unicode[(hi << 8) + s[1]]) ? 2 :
(s[1] < 0xA1 || s[1] > 0xFE) ? MY_CS_ILSEQ : -2;
}
/* JIS-X-0201 HALF WIDTH KATAKANA: [8E][A1..DF] -> [U+FF61..U+FF9F] */
if (hi == 0x8E)
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
if (s[1] < 0xA1 || s[1] > 0xDF)
return MY_CS_ILSEQ;
*pwc= 0xFEC0 + s[1]; /* 0xFFC0 = 0xFF61 - 0xA1 */
return 2;
}
if (hi == 0x8F) /* JIS X 0212 code set: [8F][A1..FE][A1..FE] */
{
if (s + 3 > e)
return MY_CS_TOOSMALL3;
return (*pwc= jisx0212_eucjpms_to_unicode[(((int) s[1]) << 8) + s[2]]) ?
3 :
(s[1] < 0xA1 || s[1] > 0xFE || s[2] < 0xA1 || s[2] > 0xFE) ?
MY_CS_ILSEQ : -3;
}
return MY_CS_ILSEQ;
} | O0 | c | my_mb_wc_eucjpms:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x20(%rbp), %rax
cmpq -0x28(%rbp), %rax
jb 0x40f0a
movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B
jmp 0x41126
movq -0x20(%rbp), %rax
movzbl (%rax), %eax
movl %eax, -0x2c(%rbp)
cmpl $0x80, %eax
jge 0x40f32
movslq -0x2c(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movl $0x1, -0x4(%rbp)
jmp 0x41126
cmpl $0xa1, -0x2c(%rbp)
jl 0x40fe1
cmpl $0xfe, -0x2c(%rbp)
jg 0x40fe1
movq -0x20(%rbp), %rax
addq $0x2, %rax
cmpq -0x28(%rbp), %rax
jbe 0x40f66
movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A
jmp 0x41126
movl -0x2c(%rbp), %eax
shll $0x8, %eax
movq -0x20(%rbp), %rcx
movzbl 0x1(%rcx), %ecx
addl %ecx, %eax
movslq %eax, %rcx
leaq 0x1ad5e0(%rip), %rax # 0x1ee560
movzwl (%rax,%rcx,2), %eax
movq -0x18(%rbp), %rcx
movq %rax, (%rcx)
cmpq $0x0, %rax
je 0x40f9b
movl $0x2, %eax
movl %eax, -0x30(%rbp)
jmp 0x40fd6
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %ecx
movb $0x1, %al
cmpl $0xa1, %ecx
movb %al, -0x31(%rbp)
jl 0x40fc3
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
cmpl $0xfe, %eax
setg %al
movb %al, -0x31(%rbp)
movb -0x31(%rbp), %dl
movl $0xfffffffe, %eax # imm = 0xFFFFFFFE
xorl %ecx, %ecx
testb $0x1, %dl
cmovnel %ecx, %eax
movl %eax, -0x30(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x41126
cmpl $0x8e, -0x2c(%rbp)
jne 0x41051
movq -0x20(%rbp), %rax
addq $0x2, %rax
cmpq -0x28(%rbp), %rax
jbe 0x41004
movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A
jmp 0x41126
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
cmpl $0xa1, %eax
jl 0x41022
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
cmpl $0xdf, %eax
jle 0x4102e
movl $0x0, -0x4(%rbp)
jmp 0x41126
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
addl $0xfec0, %eax # imm = 0xFEC0
movslq %eax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movl $0x2, -0x4(%rbp)
jmp 0x41126
cmpl $0x8f, -0x2c(%rbp)
jne 0x4111f
movq -0x20(%rbp), %rax
addq $0x3, %rax
cmpq -0x28(%rbp), %rax
jbe 0x41078
movl $0xffffff99, -0x4(%rbp) # imm = 0xFFFFFF99
jmp 0x41126
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
shll $0x8, %eax
movq -0x20(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
addl %ecx, %eax
movslq %eax, %rcx
leaq 0x1cd4c9(%rip), %rax # 0x20e560
movzwl (%rax,%rcx,2), %eax
movq -0x18(%rbp), %rcx
movq %rax, (%rcx)
cmpq $0x0, %rax
je 0x410b2
movl $0x3, %eax
movl %eax, -0x38(%rbp)
jmp 0x41117
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %ecx
movb $0x1, %al
cmpl $0xa1, %ecx
movb %al, -0x39(%rbp)
jl 0x41104
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %ecx
movb $0x1, %al
cmpl $0xfe, %ecx
movb %al, -0x39(%rbp)
jg 0x41104
movq -0x20(%rbp), %rax
movzbl 0x2(%rax), %ecx
movb $0x1, %al
cmpl $0xa1, %ecx
movb %al, -0x39(%rbp)
jl 0x41104
movq -0x20(%rbp), %rax
movzbl 0x2(%rax), %eax
cmpl $0xfe, %eax
setg %al
movb %al, -0x39(%rbp)
movb -0x39(%rbp), %dl
movl $0xfffffffd, %eax # imm = 0xFFFFFFFD
xorl %ecx, %ecx
testb $0x1, %dl
cmovnel %ecx, %eax
movl %eax, -0x38(%rbp)
movl -0x38(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x41126
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax,%rax)
| my_mb_wc_eucjpms:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_20]
cmp rax, [rbp+var_28]
jb short loc_40F0A
mov [rbp+var_4], 0FFFFFF9Bh
jmp loc_41126
loc_40F0A:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax]
mov [rbp+var_2C], eax
cmp eax, 80h
jge short loc_40F32
movsxd rcx, [rbp+var_2C]
mov rax, [rbp+var_18]
mov [rax], rcx
mov [rbp+var_4], 1
jmp loc_41126
loc_40F32:
cmp [rbp+var_2C], 0A1h
jl loc_40FE1
cmp [rbp+var_2C], 0FEh
jg loc_40FE1
mov rax, [rbp+var_20]
add rax, 2
cmp rax, [rbp+var_28]
jbe short loc_40F66
mov [rbp+var_4], 0FFFFFF9Ah
jmp loc_41126
loc_40F66:
mov eax, [rbp+var_2C]
shl eax, 8
mov rcx, [rbp+var_20]
movzx ecx, byte ptr [rcx+1]
add eax, ecx
movsxd rcx, eax
lea rax, jisx0208_eucjpms_to_unicode
movzx eax, word ptr [rax+rcx*2]
mov rcx, [rbp+var_18]
mov [rcx], rax
cmp rax, 0
jz short loc_40F9B
mov eax, 2
mov [rbp+var_30], eax
jmp short loc_40FD6
loc_40F9B:
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+1]
mov al, 1
cmp ecx, 0A1h
mov [rbp+var_31], al
jl short loc_40FC3
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
cmp eax, 0FEh
setnle al
mov [rbp+var_31], al
loc_40FC3:
mov dl, [rbp+var_31]
mov eax, 0FFFFFFFEh
xor ecx, ecx
test dl, 1
cmovnz eax, ecx
mov [rbp+var_30], eax
loc_40FD6:
mov eax, [rbp+var_30]
mov [rbp+var_4], eax
jmp loc_41126
loc_40FE1:
cmp [rbp+var_2C], 8Eh
jnz short loc_41051
mov rax, [rbp+var_20]
add rax, 2
cmp rax, [rbp+var_28]
jbe short loc_41004
mov [rbp+var_4], 0FFFFFF9Ah
jmp loc_41126
loc_41004:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
cmp eax, 0A1h
jl short loc_41022
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
cmp eax, 0DFh
jle short loc_4102E
loc_41022:
mov [rbp+var_4], 0
jmp loc_41126
loc_4102E:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
add eax, 0FEC0h
movsxd rcx, eax
mov rax, [rbp+var_18]
mov [rax], rcx
mov [rbp+var_4], 2
jmp loc_41126
loc_41051:
cmp [rbp+var_2C], 8Fh
jnz loc_4111F
mov rax, [rbp+var_20]
add rax, 3
cmp rax, [rbp+var_28]
jbe short loc_41078
mov [rbp+var_4], 0FFFFFF99h
jmp loc_41126
loc_41078:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
shl eax, 8
mov rcx, [rbp+var_20]
movzx ecx, byte ptr [rcx+2]
add eax, ecx
movsxd rcx, eax
lea rax, jisx0212_eucjpms_to_unicode
movzx eax, word ptr [rax+rcx*2]
mov rcx, [rbp+var_18]
mov [rcx], rax
cmp rax, 0
jz short loc_410B2
mov eax, 3
mov [rbp+var_38], eax
jmp short loc_41117
loc_410B2:
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+1]
mov al, 1
cmp ecx, 0A1h
mov [rbp+var_39], al
jl short loc_41104
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+1]
mov al, 1
cmp ecx, 0FEh
mov [rbp+var_39], al
jg short loc_41104
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+2]
mov al, 1
cmp ecx, 0A1h
mov [rbp+var_39], al
jl short loc_41104
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+2]
cmp eax, 0FEh
setnle al
mov [rbp+var_39], al
loc_41104:
mov dl, [rbp+var_39]
mov eax, 0FFFFFFFDh
xor ecx, ecx
test dl, 1
cmovnz eax, ecx
mov [rbp+var_38], eax
loc_41117:
mov eax, [rbp+var_38]
mov [rbp+var_4], eax
jmp short loc_41126
loc_4111F:
mov [rbp+var_4], 0
loc_41126:
mov eax, [rbp+var_4]
pop rbp
retn
| long long my_mb_wc_eucjpms(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4)
{
long long v4; // rax
unsigned int v5; // eax
long long v6; // rax
unsigned int v7; // eax
bool v9; // [rsp+1h] [rbp-39h]
bool v11; // [rsp+9h] [rbp-31h]
unsigned int v13; // [rsp+Eh] [rbp-2Ch]
if ( (unsigned long long)a3 < a4 )
{
v13 = *a3;
if ( v13 >= 0x80 )
{
if ( *a3 < 0xA1u || *a3 == 255 )
{
if ( v13 == 142 )
{
if ( (unsigned long long)(a3 + 2) <= a4 )
{
if ( a3[1] >= 0xA1u && a3[1] <= 0xDFu )
{
*a2 = a3[1] + 65216;
return 2;
}
else
{
return 0;
}
}
else
{
return (unsigned int)-102;
}
}
else if ( v13 == 143 )
{
if ( (unsigned long long)(a3 + 3) <= a4 )
{
v6 = jisx0212_eucjpms_to_unicode[256 * a3[1] + a3[2]];
*a2 = v6;
if ( v6 )
{
return 3;
}
else
{
v9 = 1;
if ( a3[1] >= 0xA1u )
{
v9 = 1;
if ( a3[1] != 255 )
{
v9 = 1;
if ( a3[2] >= 0xA1u )
v9 = a3[2] == 255;
}
}
v7 = -3;
if ( v9 )
v7 = 0;
return v7;
}
}
else
{
return (unsigned int)-103;
}
}
else
{
return 0;
}
}
else if ( (unsigned long long)(a3 + 2) <= a4 )
{
v4 = jisx0208_eucjpms_to_unicode[a3[1] + (v13 << 8)];
*a2 = v4;
if ( v4 )
{
return 2;
}
else
{
v11 = 1;
if ( a3[1] >= 0xA1u )
v11 = a3[1] == 255;
v5 = -2;
if ( v11 )
v5 = 0;
return v5;
}
}
else
{
return (unsigned int)-102;
}
}
else
{
*a2 = *a3;
return 1;
}
}
else
{
return (unsigned int)-101;
}
}
| my_mb_wc_eucjpms:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RBP + -0x28]
JC 0x00140f0a
MOV dword ptr [RBP + -0x4],0xffffff9b
JMP 0x00141126
LAB_00140f0a:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX]
MOV dword ptr [RBP + -0x2c],EAX
CMP EAX,0x80
JGE 0x00140f32
MOVSXD RCX,dword ptr [RBP + -0x2c]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00141126
LAB_00140f32:
CMP dword ptr [RBP + -0x2c],0xa1
JL 0x00140fe1
CMP dword ptr [RBP + -0x2c],0xfe
JG 0x00140fe1
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x00140f66
MOV dword ptr [RBP + -0x4],0xffffff9a
JMP 0x00141126
LAB_00140f66:
MOV EAX,dword ptr [RBP + -0x2c]
SHL EAX,0x8
MOV RCX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RCX + 0x1]
ADD EAX,ECX
MOVSXD RCX,EAX
LEA RAX,[0x2ee560]
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV RCX,qword ptr [RBP + -0x18]
MOV qword ptr [RCX],RAX
CMP RAX,0x0
JZ 0x00140f9b
MOV EAX,0x2
MOV dword ptr [RBP + -0x30],EAX
JMP 0x00140fd6
LAB_00140f9b:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0x1]
MOV AL,0x1
CMP ECX,0xa1
MOV byte ptr [RBP + -0x31],AL
JL 0x00140fc3
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
CMP EAX,0xfe
SETG AL
MOV byte ptr [RBP + -0x31],AL
LAB_00140fc3:
MOV DL,byte ptr [RBP + -0x31]
MOV EAX,0xfffffffe
XOR ECX,ECX
TEST DL,0x1
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x30],EAX
LAB_00140fd6:
MOV EAX,dword ptr [RBP + -0x30]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x00141126
LAB_00140fe1:
CMP dword ptr [RBP + -0x2c],0x8e
JNZ 0x00141051
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x00141004
MOV dword ptr [RBP + -0x4],0xffffff9a
JMP 0x00141126
LAB_00141004:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
CMP EAX,0xa1
JL 0x00141022
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
CMP EAX,0xdf
JLE 0x0014102e
LAB_00141022:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x00141126
LAB_0014102e:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
ADD EAX,0xfec0
MOVSXD RCX,EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x2
JMP 0x00141126
LAB_00141051:
CMP dword ptr [RBP + -0x2c],0x8f
JNZ 0x0014111f
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x3
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x00141078
MOV dword ptr [RBP + -0x4],0xffffff99
JMP 0x00141126
LAB_00141078:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
SHL EAX,0x8
MOV RCX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RCX + 0x2]
ADD EAX,ECX
MOVSXD RCX,EAX
LEA RAX,[0x30e560]
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV RCX,qword ptr [RBP + -0x18]
MOV qword ptr [RCX],RAX
CMP RAX,0x0
JZ 0x001410b2
MOV EAX,0x3
MOV dword ptr [RBP + -0x38],EAX
JMP 0x00141117
LAB_001410b2:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0x1]
MOV AL,0x1
CMP ECX,0xa1
MOV byte ptr [RBP + -0x39],AL
JL 0x00141104
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0x1]
MOV AL,0x1
CMP ECX,0xfe
MOV byte ptr [RBP + -0x39],AL
JG 0x00141104
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0x2]
MOV AL,0x1
CMP ECX,0xa1
MOV byte ptr [RBP + -0x39],AL
JL 0x00141104
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x2]
CMP EAX,0xfe
SETG AL
MOV byte ptr [RBP + -0x39],AL
LAB_00141104:
MOV DL,byte ptr [RBP + -0x39]
MOV EAX,0xfffffffd
XOR ECX,ECX
TEST DL,0x1
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x38],EAX
LAB_00141117:
MOV EAX,dword ptr [RBP + -0x38]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x00141126
LAB_0014111f:
MOV dword ptr [RBP + -0x4],0x0
LAB_00141126:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int4 my_mb_wc_eucjpms(int8 param_1,ulong *param_2,byte *param_3,byte *param_4)
{
ushort uVar1;
bool bVar2;
uint uVar3;
int4 local_40;
int4 local_38;
int4 local_c;
if (param_3 < param_4) {
uVar3 = (uint)*param_3;
if (uVar3 < 0x80) {
*param_2 = (long)(int)uVar3;
local_c = 1;
}
else if ((uVar3 < 0xa1) || (0xfe < uVar3)) {
if (uVar3 == 0x8e) {
if (param_4 < param_3 + 2) {
local_c = 0xffffff9a;
}
else if ((param_3[1] < 0xa1) || (0xdf < param_3[1])) {
local_c = 0;
}
else {
*param_2 = (long)(int)(param_3[1] + 0xfec0);
local_c = 2;
}
}
else if (uVar3 == 0x8f) {
if (param_4 < param_3 + 3) {
local_c = 0xffffff99;
}
else {
uVar1 = *(ushort *)
(&jisx0212_eucjpms_to_unicode +
(long)(int)((uint)param_3[1] * 0x100 + (uint)param_3[2]) * 2);
*param_2 = (ulong)uVar1;
if ((ulong)uVar1 == 0) {
bVar2 = true;
if (((0xa0 < param_3[1]) && (bVar2 = true, param_3[1] != 0xff)) &&
(bVar2 = true, 0xa0 < param_3[2])) {
bVar2 = 0xfe < param_3[2];
}
local_40 = 0xfffffffd;
if (bVar2) {
local_40 = 0;
}
}
else {
local_40 = 3;
}
local_c = local_40;
}
}
else {
local_c = 0;
}
}
else if (param_4 < param_3 + 2) {
local_c = 0xffffff9a;
}
else {
uVar1 = *(ushort *)
(jisx0208_eucjpms_to_unicode + (long)(int)(uVar3 * 0x100 + (uint)param_3[1]) * 2);
*param_2 = (ulong)uVar1;
if ((ulong)uVar1 == 0) {
bVar2 = true;
if (0xa0 < param_3[1]) {
bVar2 = 0xfe < param_3[1];
}
local_38 = 0xfffffffe;
if (bVar2) {
local_38 = 0;
}
}
else {
local_38 = 2;
}
local_c = local_38;
}
}
else {
local_c = 0xffffff9b;
}
return local_c;
}
| |
55,521 | my_mb_wc_eucjpms | eloqsql/strings/ctype-eucjpms.c | static int
my_mb_wc_eucjpms(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t *pwc, const uchar *s, const uchar *e)
{
int hi;
if (s >= e)
return MY_CS_TOOSMALL;
if ((hi= s[0]) < 0x80) /* ASCII code set: [00..7F] -> [U+0000..U+007F] */
{
*pwc= hi;
return 1;
}
if (hi >= 0xA1 && hi <= 0xFE) /* JIS X 0208 code set: [A1..FE][A1..FE] */
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
return (*pwc= jisx0208_eucjpms_to_unicode[(hi << 8) + s[1]]) ? 2 :
(s[1] < 0xA1 || s[1] > 0xFE) ? MY_CS_ILSEQ : -2;
}
/* JIS-X-0201 HALF WIDTH KATAKANA: [8E][A1..DF] -> [U+FF61..U+FF9F] */
if (hi == 0x8E)
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
if (s[1] < 0xA1 || s[1] > 0xDF)
return MY_CS_ILSEQ;
*pwc= 0xFEC0 + s[1]; /* 0xFFC0 = 0xFF61 - 0xA1 */
return 2;
}
if (hi == 0x8F) /* JIS X 0212 code set: [8F][A1..FE][A1..FE] */
{
if (s + 3 > e)
return MY_CS_TOOSMALL3;
return (*pwc= jisx0212_eucjpms_to_unicode[(((int) s[1]) << 8) + s[2]]) ?
3 :
(s[1] < 0xA1 || s[1] > 0xFE || s[2] < 0xA1 || s[2] > 0xFE) ?
MY_CS_ILSEQ : -3;
}
return MY_CS_ILSEQ;
} | O3 | c | my_mb_wc_eucjpms:
pushq %rbp
movq %rsp, %rbp
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmpq %rcx, %rdx
jae 0x361ca
movzbl (%rdx), %edi
testb %dil, %dil
js 0x361cc
movq %rdi, (%rsi)
movl $0x1, %eax
popq %rbp
retq
leal 0x5f(%rdi), %eax
cmpb $0x5d, %al
ja 0x36218
leaq 0x2(%rdx), %r8
movl $0xffffff9a, %eax # imm = 0xFFFFFF9A
cmpq %rcx, %r8
ja 0x361ca
movzbl 0x1(%rdx), %eax
shll $0x9, %edi
leal (%rdi,%rax,2), %eax
leaq 0xa738e(%rip), %rcx # 0xdd580
movzwl (%rax,%rcx), %ecx
movq %rcx, (%rsi)
movl $0x2, %eax
testq %rcx, %rcx
jne 0x361ca
movb 0x1(%rdx), %al
incb %al
xorl %ecx, %ecx
cmpb $-0x5e, %al
setb %cl
leal -0x2(,%rcx,2), %eax
jmp 0x361ca
cmpq $0x8f, %rdi
je 0x3625c
cmpl $0x8e, %edi
jne 0x3629e
leaq 0x2(%rdx), %rdi
movl $0xffffff9a, %eax # imm = 0xFFFFFF9A
cmpq %rcx, %rdi
ja 0x361ca
movzbl 0x1(%rdx), %ecx
leal 0x20(%rcx), %edx
movl $0x0, %eax
cmpb $-0x3f, %dl
jb 0x361ca
addq $0xfec0, %rcx # imm = 0xFEC0
movq %rcx, (%rsi)
movl $0x2, %eax
jmp 0x361ca
leaq 0x3(%rdx), %rdi
movl $0xffffff99, %eax # imm = 0xFFFFFF99
cmpq %rcx, %rdi
ja 0x361ca
movzwl 0x1(%rdx), %eax
rolw $0x8, %ax
movzwl %ax, %eax
leaq 0xc7300(%rip), %rcx # 0xfd580
movzwl (%rcx,%rax,2), %ecx
movq %rcx, (%rsi)
movl $0x3, %eax
testq %rcx, %rcx
jne 0x361ca
movb 0x1(%rdx), %al
incb %al
cmpb $-0x5e, %al
jae 0x362a5
xorl %eax, %eax
jmp 0x361ca
movb 0x2(%rdx), %cl
movl $0x0, %eax
cmpb $-0x5f, %cl
jb 0x361ca
xorl %eax, %eax
cmpb $-0x1, %cl
sete %al
leal (%rax,%rax,2), %eax
addl $-0x3, %eax
jmp 0x361ca
| my_mb_wc_eucjpms:
push rbp
mov rbp, rsp
mov eax, 0FFFFFF9Bh
cmp rdx, rcx
jnb short loc_361CA
movzx edi, byte ptr [rdx]
test dil, dil
js short loc_361CC
mov [rsi], rdi
mov eax, 1
loc_361CA:
pop rbp
retn
loc_361CC:
lea eax, [rdi+5Fh]
cmp al, 5Dh ; ']'
ja short loc_36218
lea r8, [rdx+2]
mov eax, 0FFFFFF9Ah
cmp r8, rcx
ja short loc_361CA
movzx eax, byte ptr [rdx+1]
shl edi, 9
lea eax, [rdi+rax*2]
lea rcx, jisx0208_eucjpms_to_unicode
movzx ecx, word ptr [rax+rcx]
mov [rsi], rcx
mov eax, 2
test rcx, rcx
jnz short loc_361CA
mov al, [rdx+1]
inc al
xor ecx, ecx
cmp al, 0A2h
setb cl
lea eax, ds:0FFFFFFFFFFFFFFFEh[rcx*2]
jmp short loc_361CA
loc_36218:
cmp rdi, 8Fh
jz short loc_3625C
cmp edi, 8Eh
jnz short loc_3629E
lea rdi, [rdx+2]
mov eax, 0FFFFFF9Ah
cmp rdi, rcx
ja short loc_361CA
movzx ecx, byte ptr [rdx+1]
lea edx, [rcx+20h]
mov eax, 0
cmp dl, 0C1h
jb short loc_361CA
add rcx, 0FEC0h
mov [rsi], rcx
mov eax, 2
jmp loc_361CA
loc_3625C:
lea rdi, [rdx+3]
mov eax, 0FFFFFF99h
cmp rdi, rcx
ja loc_361CA
movzx eax, word ptr [rdx+1]
rol ax, 8
movzx eax, ax
lea rcx, jisx0212_eucjpms_to_unicode
movzx ecx, word ptr [rcx+rax*2]
mov [rsi], rcx
mov eax, 3
test rcx, rcx
jnz loc_361CA
mov al, [rdx+1]
inc al
cmp al, 0A2h
jnb short loc_362A5
loc_3629E:
xor eax, eax
jmp loc_361CA
loc_362A5:
mov cl, [rdx+2]
mov eax, 0
cmp cl, 0A1h
jb loc_361CA
xor eax, eax
cmp cl, 0FFh
setz al
lea eax, [rax+rax*2]
add eax, 0FFFFFFFDh
jmp loc_361CA
| long long my_mb_wc_eucjpms(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4)
{
long long result; // rax
long long v5; // rdi
long long v6; // rcx
long long v7; // rcx
long long v8; // rcx
unsigned __int8 v9; // cl
result = 4294967195LL;
if ( (unsigned long long)a3 >= a4 )
return result;
v5 = *a3;
if ( (v5 & 0x80u) == 0LL )
{
*a2 = v5;
return 1LL;
}
if ( (unsigned __int8)(v5 + 95) <= 0x5Du )
{
result = 4294967194LL;
if ( (unsigned long long)(a3 + 2) <= a4 )
{
v6 = jisx0208_eucjpms_to_unicode[256 * (_DWORD)v5 + a3[1]];
*a2 = v6;
result = 2LL;
if ( !v6 )
return 2 * (unsigned int)((unsigned __int8)(a3[1] + 1) < 0xA2u) - 2;
}
return result;
}
if ( v5 != 143 )
{
if ( (_DWORD)v5 == 142 )
{
result = 4294967194LL;
if ( (unsigned long long)(a3 + 2) <= a4 )
{
v7 = a3[1];
result = 0LL;
if ( (unsigned __int8)(v7 + 32) >= 0xC1u )
{
*a2 = v7 + 65216;
return 2LL;
}
}
return result;
}
return 0LL;
}
result = 4294967193LL;
if ( (unsigned long long)(a3 + 3) > a4 )
return result;
v8 = jisx0212_eucjpms_to_unicode[(unsigned __int16)__ROL2__(*(_WORD *)(a3 + 1), 8)];
*a2 = v8;
result = 3LL;
if ( v8 )
return result;
if ( (unsigned __int8)(a3[1] + 1) < 0xA2u )
return 0LL;
v9 = a3[2];
result = 0LL;
if ( v9 >= 0xA1u )
return 3 * (unsigned int)(v9 == 0xFF) - 3;
return result;
}
| my_mb_wc_eucjpms:
PUSH RBP
MOV RBP,RSP
MOV EAX,0xffffff9b
CMP RDX,RCX
JNC 0x001361ca
MOVZX EDI,byte ptr [RDX]
TEST DIL,DIL
JS 0x001361cc
MOV qword ptr [RSI],RDI
MOV EAX,0x1
LAB_001361ca:
POP RBP
RET
LAB_001361cc:
LEA EAX,[RDI + 0x5f]
CMP AL,0x5d
JA 0x00136218
LEA R8,[RDX + 0x2]
MOV EAX,0xffffff9a
CMP R8,RCX
JA 0x001361ca
MOVZX EAX,byte ptr [RDX + 0x1]
SHL EDI,0x9
LEA EAX,[RDI + RAX*0x2]
LEA RCX,[0x1dd580]
MOVZX ECX,word ptr [RAX + RCX*0x1]
MOV qword ptr [RSI],RCX
MOV EAX,0x2
TEST RCX,RCX
JNZ 0x001361ca
MOV AL,byte ptr [RDX + 0x1]
INC AL
XOR ECX,ECX
CMP AL,0xa2
SETC CL
LEA EAX,[-0x2 + RCX*0x2]
JMP 0x001361ca
LAB_00136218:
CMP RDI,0x8f
JZ 0x0013625c
CMP EDI,0x8e
JNZ 0x0013629e
LEA RDI,[RDX + 0x2]
MOV EAX,0xffffff9a
CMP RDI,RCX
JA 0x001361ca
MOVZX ECX,byte ptr [RDX + 0x1]
LEA EDX,[RCX + 0x20]
MOV EAX,0x0
CMP DL,0xc1
JC 0x001361ca
ADD RCX,0xfec0
MOV qword ptr [RSI],RCX
MOV EAX,0x2
JMP 0x001361ca
LAB_0013625c:
LEA RDI,[RDX + 0x3]
MOV EAX,0xffffff99
CMP RDI,RCX
JA 0x001361ca
MOVZX EAX,word ptr [RDX + 0x1]
ROL AX,0x8
MOVZX EAX,AX
LEA RCX,[0x1fd580]
MOVZX ECX,word ptr [RCX + RAX*0x2]
MOV qword ptr [RSI],RCX
MOV EAX,0x3
TEST RCX,RCX
JNZ 0x001361ca
MOV AL,byte ptr [RDX + 0x1]
INC AL
CMP AL,0xa2
JNC 0x001362a5
LAB_0013629e:
XOR EAX,EAX
JMP 0x001361ca
LAB_001362a5:
MOV CL,byte ptr [RDX + 0x2]
MOV EAX,0x0
CMP CL,0xa1
JC 0x001361ca
XOR EAX,EAX
CMP CL,0xff
SETZ AL
LEA EAX,[RAX + RAX*0x2]
ADD EAX,-0x3
JMP 0x001361ca
|
int my_mb_wc_eucjpms(int8 param_1,ulong *param_2,byte *param_3,byte *param_4)
{
byte bVar1;
ushort uVar2;
int iVar3;
iVar3 = -0x65;
if (param_3 < param_4) {
bVar1 = *param_3;
if ((char)bVar1 < '\0') {
if ((byte)(bVar1 + 0x5f) < 0x5e) {
iVar3 = -0x66;
if (param_3 + 2 <= param_4) {
uVar2 = *(ushort *)
(jisx0208_eucjpms_to_unicode + ((uint)bVar1 * 0x200 + (uint)param_3[1] * 2));
*param_2 = (ulong)uVar2;
iVar3 = 2;
if ((ulong)uVar2 == 0) {
iVar3 = (uint)((byte)(param_3[1] + 1) < 0xa2) * 2 + -2;
}
}
}
else {
if ((ulong)bVar1 == 0x8f) {
if (param_4 < param_3 + 3) {
return -0x67;
}
uVar2 = *(ushort *)
(&jisx0212_eucjpms_to_unicode +
(ulong)(ushort)(*(ushort *)(param_3 + 1) << 8 | *(ushort *)(param_3 + 1) >> 8) *
2);
*param_2 = (ulong)uVar2;
if ((ulong)uVar2 != 0) {
return 3;
}
if (0xa1 < (byte)(param_3[1] + 1)) {
if (param_3[2] < 0xa1) {
return 0;
}
return (uint)(param_3[2] == 0xff) * 3 + -3;
}
}
else if (bVar1 == 0x8e) {
if (param_4 < param_3 + 2) {
return -0x66;
}
if ((byte)(param_3[1] + 0x20) < 0xc1) {
return 0;
}
*param_2 = (ulong)param_3[1] + 0xfec0;
return 2;
}
iVar3 = 0;
}
}
else {
*param_2 = (ulong)bVar1;
iVar3 = 1;
}
}
return iVar3;
}
| |
55,522 | google::protobuf::EncodedDescriptorDatabase::DescriptorIndex::SymbolEntry::AsString[abi:cxx11](google::protobuf::EncodedDescriptorDatabase::DescriptorIndex const&) const | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor_database.cc | std::string AsString(const DescriptorIndex& index) const {
auto p = package(index);
return StrCat(p, p.empty() ? "" : ".", symbol(index));
} | O3 | cpp | google::protobuf::EncodedDescriptorDatabase::DescriptorIndex::SymbolEntry::AsString[abi:cxx11](google::protobuf::EncodedDescriptorDatabase::DescriptorIndex const&) const:
pushq %rbx
subq $0x90, %rsp
movq %rdi, %rbx
movslq (%rsi), %rax
movq (%rdx), %rcx
leaq (%rax,%rax,2), %rax
shlq $0x4, %rax
movq 0x10(%rcx,%rax), %rdx
movq 0x18(%rcx,%rax), %rcx
leaq 0x60(%rsp), %rax
movq %rdx, (%rax)
movq %rcx, 0x8(%rax)
xorl %edi, %edi
testq %rcx, %rcx
setne %dil
leaq 0x6debf(%rip), %rcx # 0x16c424
leaq 0x66f99(%rip), %r8 # 0x165505
cmovneq %rcx, %r8
leaq 0x30(%rsp), %rdx
movq %r8, (%rdx)
movq %rdi, 0x8(%rdx)
movups 0x8(%rsi), %xmm0
movq %rsp, %rcx
movups %xmm0, (%rcx)
movq %rbx, %rdi
movq %rax, %rsi
callq 0x88b1e
movq %rbx, %rax
addq $0x90, %rsp
popq %rbx
retq
nop
| _ZNK6google8protobuf25EncodedDescriptorDatabase15DescriptorIndex11SymbolEntry8AsStringB5cxx11ERKS2_:
push rbx
sub rsp, 90h
mov rbx, rdi
movsxd rax, dword ptr [rsi]
mov rcx, [rdx]
lea rax, [rax+rax*2]
shl rax, 4
mov rdx, [rcx+rax+10h]
mov rcx, [rcx+rax+18h]
lea rax, [rsp+98h+var_38]
mov [rax], rdx
mov [rax+8], rcx
xor edi, edi
test rcx, rcx
setnz dil
lea rcx, aWhichIsNotDefi+77h; "."
lea r8, asc_165504+1; "ࠀ\u0B00"
cmovnz r8, rcx
lea rdx, [rsp+98h+var_68]
mov [rdx], r8
mov [rdx+8], rdi
movups xmm0, xmmword ptr [rsi+8]
mov rcx, rsp
movups xmmword ptr [rcx], xmm0
mov rdi, rbx
mov rsi, rax
call _ZN6google8protobuf6StrCatB5cxx11ERKNS0_7strings8AlphaNumES4_S4_; google::protobuf::StrCat(google::protobuf::strings::AlphaNum const&,google::protobuf::strings::AlphaNum const&,google::protobuf::strings::AlphaNum const&)
mov rax, rbx
add rsp, 90h
pop rbx
retn
| long long * google::protobuf::EncodedDescriptorDatabase::DescriptorIndex::SymbolEntry::AsString[abi:cxx11](
long long *a1,
int *a2,
_QWORD *a3)
{
long long v3; // rax
long long v4; // rcx
char *v5; // r8
_OWORD v7[3]; // [rsp+0h] [rbp-98h] BYREF
_QWORD v8[6]; // [rsp+30h] [rbp-68h] BYREF
_QWORD v9[7]; // [rsp+60h] [rbp-38h] BYREF
v3 = 48LL * *a2;
v4 = *(_QWORD *)(*a3 + v3 + 24);
v9[0] = *(_QWORD *)(*a3 + v3 + 16);
v9[1] = v4;
v5 = (char *)asc_165504 + 1;
if ( v4 )
v5 = ".";
v8[0] = v5;
v8[1] = v4 != 0;
v7[0] = *(_OWORD *)(a2 + 2);
google::protobuf::StrCat[abi:cxx11](a1, (long long)v9, (long long)v8, (long long)v7);
return a1;
}
| AsString[abi:cxx11]:
PUSH RBX
SUB RSP,0x90
MOV RBX,RDI
MOVSXD RAX,dword ptr [RSI]
MOV RCX,qword ptr [RDX]
LEA RAX,[RAX + RAX*0x2]
SHL RAX,0x4
MOV RDX,qword ptr [RCX + RAX*0x1 + 0x10]
MOV RCX,qword ptr [RCX + RAX*0x1 + 0x18]
LEA RAX,[RSP + 0x60]
MOV qword ptr [RAX],RDX
MOV qword ptr [RAX + 0x8],RCX
XOR EDI,EDI
TEST RCX,RCX
SETNZ DIL
LEA RCX,[0x26c424]
LEA R8,[0x265505]
CMOVNZ R8,RCX
LEA RDX,[RSP + 0x30]
MOV qword ptr [RDX],R8
MOV qword ptr [RDX + 0x8],RDI
MOVUPS XMM0,xmmword ptr [RSI + 0x8]
MOV RCX,RSP
MOVUPS xmmword ptr [RCX],XMM0
MOV RDI,RBX
MOV RSI,RAX
CALL 0x00188b1e
MOV RAX,RBX
ADD RSP,0x90
POP RBX
RET
|
/* google::protobuf::EncodedDescriptorDatabase::DescriptorIndex::SymbolEntry::AsString[abi:cxx11](google::protobuf::EncodedDescriptorDatabase::DescriptorIndex
const&) const */
DescriptorIndex *
google::protobuf::EncodedDescriptorDatabase::DescriptorIndex::SymbolEntry::AsString_abi_cxx11_
(DescriptorIndex *param_1)
{
long *in_RDX;
int *in_RSI;
int8 local_98;
int8 uStack_90;
char *local_68;
ulong local_60;
int8 local_38;
long local_30;
local_38 = *(int8 *)(*in_RDX + 0x10 + (long)*in_RSI * 0x30);
local_30 = *(long *)(*in_RDX + 0x18 + (long)*in_RSI * 0x30);
local_60 = (ulong)(local_30 != 0);
local_68 = "";
if (local_30 != 0) {
local_68 = ".";
}
local_98 = *(int8 *)(in_RSI + 2);
uStack_90 = *(int8 *)(in_RSI + 4);
StrCat_abi_cxx11_((protobuf *)param_1,(AlphaNum *)&local_38,(AlphaNum *)&local_68,
(AlphaNum *)&local_98);
return param_1;
}
| |
55,523 | map_to_isogenous_E1 | corpus-core[P]colibri-stateless/build_O2/_deps/blst-src/src/map_to_g1.c | static void map_to_isogenous_E1(POINTonE1 *p, const vec384 u)
{
static const vec384 minus_A = { /* P - A */
TO_LIMB_T(0x8a9955f1650a005a), TO_LIMB_T(0x9865b3d192cfe93c),
TO_LIMB_T(0xaed3ed0f3ef3c441), TO_LIMB_T(0x3c962ef33d92c442),
TO_LIMB_T(0x22e438dbd74f94a2), TO_LIMB_T(0x04acbc265478c915)
};
static const vec384 Z = { /* (11<<384) % P */
TO_LIMB_T(0x886c00000023ffdc), TO_LIMB_T(0x0f70008d3090001d),
TO_LIMB_T(0x77672417ed5828c3), TO_LIMB_T(0x9dac23e943dc1740),
TO_LIMB_T(0x50553f1b9c131521), TO_LIMB_T(0x078c712fbe0ab6e8)
};
static const vec384 sqrt_minus_ZZZ = {
TO_LIMB_T(0x43b571cad3215f1f), TO_LIMB_T(0xccb460ef1c702dc2),
TO_LIMB_T(0x742d884f4f97100b), TO_LIMB_T(0xdb2c3e3238a3382b),
TO_LIMB_T(0xe40f3fa13fce8f88), TO_LIMB_T(0x0073a2af9892a2ff)
};
static const vec384 ZxA = {
TO_LIMB_T(0x7f674ea0a8915178), TO_LIMB_T(0xb0f945fc13b8fa65),
TO_LIMB_T(0x4b46759a38e87d76), TO_LIMB_T(0x2e7a929641bbb6a1),
TO_LIMB_T(0x1668ddfa462bf6b6), TO_LIMB_T(0x00960e2ed1cf294c)
};
vec384 uu, tv2, x2n, gx1, gxd, y2;
#if 0
vec384 xn, x1n, xd, y, y1, Zuu, tv4;
#else
# define xn p->X
# define y p->Y
# define xd p->Z
# define x1n xn
# define y1 y
# define Zuu x2n
# define tv4 y1
#endif
#define sgn0_fp(a) (sgn0_pty_mont_384((a), BLS12_381_P, p0) & 1)
bool_t e1, e2;
/*
* as per map_to_curve() from poc/sswu_opt.sage at
* https://github.com/cfrg/draft-irtf-cfrg-hash-to-curve
*/
/* x numerator variants */
sqr_fp(uu, u); /* uu = u^2 */
mul_fp(Zuu, Z, uu); /* Zuu = Z * uu */
sqr_fp(tv2, Zuu); /* tv2 = Zuu^2 */
add_fp(tv2, tv2, Zuu); /* tv2 = tv2 + Zuu */
add_fp(x1n, tv2, BLS12_381_Rx.p); /* x1n = tv2 + 1 */
mul_fp(x1n, x1n, Bprime_E1); /* x1n = x1n * B */
mul_fp(x2n, Zuu, x1n); /* x2n = Zuu * x1n */
/* x denumenator */
mul_fp(xd, minus_A, tv2); /* xd = -A * tv2 */
e1 = vec_is_zero(xd, sizeof(xd)); /* e1 = xd == 0 */
vec_select(xd, ZxA, xd, sizeof(xd), e1); /* # If xd == 0, set xd = Z*A */
/* y numerators variants */
sqr_fp(tv2, xd); /* tv2 = xd^2 */
mul_fp(gxd, xd, tv2); /* gxd = xd^3 */
mul_fp(tv2, Aprime_E1, tv2); /* tv2 = A * tv2 */
sqr_fp(gx1, x1n); /* gx1 = x1n^2 */
add_fp(gx1, gx1, tv2); /* gx1 = gx1 + tv2 # x1n^2 + A*xd^2 */
mul_fp(gx1, gx1, x1n); /* gx1 = gx1 * x1n # x1n^3 + A*x1n*xd^2 */
mul_fp(tv2, Bprime_E1, gxd); /* tv2 = B * gxd */
add_fp(gx1, gx1, tv2); /* gx1 = gx1 + tv2 # x1^3 + A*x1*xd^2 + B*xd^3 */
sqr_fp(tv4, gxd); /* tv4 = gxd^2 */
mul_fp(tv2, gx1, gxd); /* tv2 = gx1 * gxd */
mul_fp(tv4, tv4, tv2); /* tv4 = tv4 * tv2 # gx1*gxd^3 */
e2 = recip_sqrt_fp(y1, tv4); /* y1 = tv4^c1 # (gx1*gxd^3)^((p-3)/4) */
mul_fp(y1, y1, tv2); /* y1 = y1 * tv2 # gx1*gxd*y1 */
mul_fp(y2, y1, sqrt_minus_ZZZ); /* y2 = y1 * c2 # y2 = y1*sqrt(-Z^3) */
mul_fp(y2, y2, uu); /* y2 = y2 * uu */
mul_fp(y2, y2, u); /* y2 = y2 * u */
/* choose numerators */
vec_select(xn, x1n, x2n, sizeof(xn), e2); /* xn = e2 ? x1n : x2n */
vec_select(y, y1, y2, sizeof(y), e2); /* y = e2 ? y1 : y2 */
e1 = sgn0_fp(u);
e2 = sgn0_fp(y);
cneg_fp(y, y, e1^e2); /* fix sign of y */
/* return (xn, xd, y, 1) */
/* convert (xn, xd, y, 1) to Jacobian projective coordinates */
mul_fp(p->X, xn, xd); /* X = xn * xd */
mul_fp(p->Y, y, gxd); /* Y = y * xd^3 */
#ifndef xd
vec_copy(p->Z, xd, sizeof(xd)); /* Z = xd */
#else
# undef xn
# undef y
# undef xd
# undef x1n
# undef y1
# undef Zuu
# undef tv4
#endif
#undef sgn0_fp
} | O2 | c | map_to_isogenous_E1:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x138, %rsp # imm = 0x138
movq %rsi, -0x38(%rbp)
movq %rdi, %rbx
leaq -0xd0(%rbp), %r12
movq %r12, %rdi
callq 0x582c9
leaq 0x24349(%rip), %rsi # 0x800c0
leaq -0xa0(%rbp), %r14
movq %r14, %rdi
movq %r12, %rdx
callq 0x5aad8
leaq -0x160(%rbp), %r13
movq %r13, %rdi
movq %r14, %rsi
callq 0x582c9
movq %r13, %rdi
movq %r13, %rsi
movq %r14, %rdx
callq 0x56a78
leaq 0x23f38(%rip), %rdx # 0x7fce8
movq %rbx, %rdi
movq %r13, %rsi
callq 0x56a78
leaq 0x2438e(%rip), %rdx # 0x80150
movq %rbx, %rdi
movq %rbx, %rsi
callq 0x5aad8
movq %r14, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x5aad8
leaq 0x60(%rbx), %r14
movq %r14, -0x30(%rbp)
leaq 0x242a6(%rip), %rsi # 0x80090
movq %r14, %rdi
movq %r13, %rdx
callq 0x5aad8
pushq $0x30
popq %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x510f5
leaq 0x24315(%rip), %rsi # 0x80120
movq %r14, %rdi
movq %r14, %rdx
movq %r15, %rcx
movq %rax, %r8
callq 0x51073
movq %r13, %rdi
movq %r14, %rsi
callq 0x582c9
leaq -0x70(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x5aad8
leaq 0x24220(%rip), %rsi # 0x80060
movq %r13, %rdi
movq %r13, %rdx
callq 0x5aad8
leaq -0x130(%rbp), %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x582c9
movq %r14, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x56a78
movq %r14, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x5aad8
movq %r13, %rdi
leaq 0x242cd(%rip), %rsi # 0x80150
movq %r15, %rdx
callq 0x5aad8
movq %r14, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x56a78
leaq 0x30(%rbx), %r12
movq %r12, %rdi
movq %r15, %rsi
callq 0x582c9
movq %r13, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x5aad8
movq %r12, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x5aad8
movq %r12, %rdi
movq %r12, %rsi
callq 0x5c01a
movq %rax, %r14
movq %r12, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x5aad8
leaq 0x24209(%rip), %rdx # 0x800f0
leaq -0x100(%rbp), %r13
movq %r13, %rdi
movq %r12, %rsi
callq 0x5aad8
movq %r13, %rdi
movq %r13, %rsi
leaq -0xd0(%rbp), %rdx
callq 0x5aad8
movq %r13, %rdi
movq %r13, %rsi
movq -0x38(%rbp), %r15
movq %r15, %rdx
callq 0x5aad8
movq %rbx, %rdi
movq %rbx, %rsi
leaq -0xa0(%rbp), %rdx
pushq $0x30
popq %rcx
movq %r14, %r8
callq 0x51073
movq %r12, %rdi
movq %r12, %rsi
movq %r13, %rdx
pushq $0x30
popq %rcx
movq %r14, %r8
callq 0x51073
leaq 0x23d60(%rip), %r14 # 0x7fcb0
movabsq $-0x760c000300030003, %r13 # imm = 0x89F3FFFCFFFCFFFD
movq %r15, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x68f40
movq %rax, %r15
movq %r12, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x68f40
xorl %eax, %r15d
andl $0x1, %r15d
movq %r12, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x56a89
movq %rbx, %rdi
movq %rbx, %rsi
movq -0x30(%rbp), %rdx
callq 0x5aad8
movq %r12, %rdi
movq %r12, %rsi
leaq -0x70(%rbp), %rdx
callq 0x5aad8
addq $0x138, %rsp # imm = 0x138
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| map_to_isogenous_E1:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 138h
mov [rbp+var_38], rsi
mov rbx, rdi
lea r12, [rbp+var_D0]
mov rdi, r12
call sqr_fp
lea rsi, map_to_isogenous_E1_Z
lea r14, [rbp+var_A0]
mov rdi, r14
mov rdx, r12
call mul_fp
lea r13, [rbp+var_160]
mov rdi, r13
mov rsi, r14
call sqr_fp
mov rdi, r13
mov rsi, r13
mov rdx, r14
call add_fp
lea rdx, BLS12_381_Rx
mov rdi, rbx
mov rsi, r13
call add_fp
lea rdx, Bprime_E1
mov rdi, rbx
mov rsi, rbx
call mul_fp
mov rdi, r14
mov rsi, r14
mov rdx, rbx
call mul_fp
lea r14, [rbx+60h]
mov [rbp+var_30], r14
lea rsi, map_to_isogenous_E1_minus_A
mov rdi, r14
mov rdx, r13
call mul_fp
push 30h ; '0'
pop r15
mov rdi, r14
mov rsi, r15
call vec_is_zero
lea rsi, map_to_isogenous_E1_ZxA
mov rdi, r14
mov rdx, r14
mov rcx, r15
mov r8, rax
call vec_select
mov rdi, r13
mov rsi, r14
call sqr_fp
lea r15, [rbp+var_70]
mov rdi, r15
mov rsi, r14
mov rdx, r13
call mul_fp
lea rsi, Aprime_E1
mov rdi, r13
mov rdx, r13
call mul_fp
lea r14, [rbp+var_130]
mov rdi, r14
mov rsi, rbx
call sqr_fp
mov rdi, r14
mov rsi, r14
mov rdx, r13
call add_fp
mov rdi, r14
mov rsi, r14
mov rdx, rbx
call mul_fp
mov rdi, r13
lea rsi, Bprime_E1
mov rdx, r15
call mul_fp
mov rdi, r14
mov rsi, r14
mov rdx, r13
call add_fp
lea r12, [rbx+30h]
mov rdi, r12
mov rsi, r15
call sqr_fp
mov rdi, r13
mov rsi, r14
mov rdx, r15
call mul_fp
mov rdi, r12
mov rsi, r12
mov rdx, r13
call mul_fp
mov rdi, r12
mov rsi, r12
call recip_sqrt_fp
mov r14, rax
mov rdi, r12
mov rsi, r12
mov rdx, r13
call mul_fp
lea rdx, map_to_isogenous_E1_sqrt_minus_ZZZ
lea r13, [rbp+var_100]
mov rdi, r13
mov rsi, r12
call mul_fp
mov rdi, r13
mov rsi, r13
lea rdx, [rbp+var_D0]
call mul_fp
mov rdi, r13
mov rsi, r13
mov r15, [rbp+var_38]
mov rdx, r15
call mul_fp
mov rdi, rbx
mov rsi, rbx
lea rdx, [rbp+var_A0]
push 30h ; '0'
pop rcx
mov r8, r14
call vec_select
mov rdi, r12
mov rsi, r12
mov rdx, r13
push 30h ; '0'
pop rcx
mov r8, r14
call vec_select
lea r14, BLS12_381_P
mov r13, 89F3FFFCFFFCFFFDh
mov rdi, r15
mov rsi, r14
mov rdx, r13
call sgn0_pty_mont_384
mov r15, rax
mov rdi, r12
mov rsi, r14
mov rdx, r13
call sgn0_pty_mont_384
xor r15d, eax
and r15d, 1
mov rdi, r12
mov rsi, r12
mov rdx, r15
call cneg_fp
mov rdi, rbx
mov rsi, rbx
mov rdx, [rbp+var_30]
call mul_fp
mov rdi, r12
mov rsi, r12
lea rdx, [rbp+var_70]
call mul_fp
add rsp, 138h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long map_to_isogenous_E1(long long a1, long long a2)
{
unsigned long long is_zero; // rax
long long v4; // r14
long long v5; // r15
unsigned __int8 v6; // al
_BYTE v8[48]; // [rsp+0h] [rbp-160h] BYREF
_BYTE v9[48]; // [rsp+30h] [rbp-130h] BYREF
_BYTE v10[48]; // [rsp+60h] [rbp-100h] BYREF
_BYTE v11[48]; // [rsp+90h] [rbp-D0h] BYREF
_BYTE v12[48]; // [rsp+C0h] [rbp-A0h] BYREF
_BYTE v13[56]; // [rsp+F0h] [rbp-70h] BYREF
long long v14; // [rsp+128h] [rbp-38h]
long long v15; // [rsp+130h] [rbp-30h]
v14 = a2;
sqr_fp((long long)v11, a2);
mul_fp((long long)v12, (long long)&map_to_isogenous_E1_Z, (long long)v11);
sqr_fp((long long)v8, (long long)v12);
add_fp((long long)v8, (long long)v8, (long long)v12);
add_fp(a1, (long long)v8, (long long)&BLS12_381_Rx);
mul_fp(a1, a1, (long long)&Bprime_E1);
mul_fp((long long)v12, (long long)v12, a1);
v15 = a1 + 96;
mul_fp(a1 + 96, (long long)&map_to_isogenous_E1_minus_A, (long long)v8);
is_zero = vec_is_zero(a1 + 96, 0x30uLL);
vec_select(a1 + 96, (long long)&map_to_isogenous_E1_ZxA, a1 + 96, 0x30uLL, is_zero);
sqr_fp((long long)v8, a1 + 96);
mul_fp((long long)v13, a1 + 96, (long long)v8);
mul_fp((long long)v8, (long long)&Aprime_E1, (long long)v8);
sqr_fp((long long)v9, a1);
add_fp((long long)v9, (long long)v9, (long long)v8);
mul_fp((long long)v9, (long long)v9, a1);
mul_fp((long long)v8, (long long)&Bprime_E1, (long long)v13);
add_fp((long long)v9, (long long)v9, (long long)v8);
sqr_fp(a1 + 48, (long long)v13);
mul_fp((long long)v8, (long long)v9, (long long)v13);
mul_fp(a1 + 48, a1 + 48, (long long)v8);
v4 = recip_sqrt_fp(a1 + 48, a1 + 48);
mul_fp(a1 + 48, a1 + 48, (long long)v8);
mul_fp((long long)v10, a1 + 48, (long long)&map_to_isogenous_E1_sqrt_minus_ZZZ);
mul_fp((long long)v10, (long long)v10, (long long)v11);
v5 = v14;
mul_fp((long long)v10, (long long)v10, v14);
vec_select(a1, a1, (long long)v12, 0x30uLL, v4);
vec_select(a1 + 48, a1 + 48, (long long)v10, 0x30uLL, v4);
LOBYTE(v5) = sgn0_pty_mont_384(v5, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
v6 = sgn0_pty_mont_384(a1 + 48, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
cneg_fp(a1 + 48, a1 + 48, (v6 ^ (unsigned __int8)v5) & 1);
mul_fp(a1, a1, v15);
return mul_fp(a1 + 48, a1 + 48, (long long)v13);
}
| map_to_isogenous_E1:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x138
MOV qword ptr [RBP + -0x38],RSI
MOV RBX,RDI
LEA R12,[RBP + -0xd0]
MOV RDI,R12
CALL 0x001582c9
LEA RSI,[0x1800c0]
LEA R14,[RBP + -0xa0]
MOV RDI,R14
MOV RDX,R12
CALL 0x0015aad8
LEA R13,[RBP + -0x160]
MOV RDI,R13
MOV RSI,R14
CALL 0x001582c9
MOV RDI,R13
MOV RSI,R13
MOV RDX,R14
CALL 0x00156a78
LEA RDX,[0x17fce8]
MOV RDI,RBX
MOV RSI,R13
CALL 0x00156a78
LEA RDX,[0x180150]
MOV RDI,RBX
MOV RSI,RBX
CALL 0x0015aad8
MOV RDI,R14
MOV RSI,R14
MOV RDX,RBX
CALL 0x0015aad8
LEA R14,[RBX + 0x60]
MOV qword ptr [RBP + -0x30],R14
LEA RSI,[0x180090]
MOV RDI,R14
MOV RDX,R13
CALL 0x0015aad8
PUSH 0x30
POP R15
MOV RDI,R14
MOV RSI,R15
CALL 0x001510f5
LEA RSI,[0x180120]
MOV RDI,R14
MOV RDX,R14
MOV RCX,R15
MOV R8,RAX
CALL 0x00151073
MOV RDI,R13
MOV RSI,R14
CALL 0x001582c9
LEA R15,[RBP + -0x70]
MOV RDI,R15
MOV RSI,R14
MOV RDX,R13
CALL 0x0015aad8
LEA RSI,[0x180060]
MOV RDI,R13
MOV RDX,R13
CALL 0x0015aad8
LEA R14,[RBP + -0x130]
MOV RDI,R14
MOV RSI,RBX
CALL 0x001582c9
MOV RDI,R14
MOV RSI,R14
MOV RDX,R13
CALL 0x00156a78
MOV RDI,R14
MOV RSI,R14
MOV RDX,RBX
CALL 0x0015aad8
MOV RDI,R13
LEA RSI,[0x180150]
MOV RDX,R15
CALL 0x0015aad8
MOV RDI,R14
MOV RSI,R14
MOV RDX,R13
CALL 0x00156a78
LEA R12,[RBX + 0x30]
MOV RDI,R12
MOV RSI,R15
CALL 0x001582c9
MOV RDI,R13
MOV RSI,R14
MOV RDX,R15
CALL 0x0015aad8
MOV RDI,R12
MOV RSI,R12
MOV RDX,R13
CALL 0x0015aad8
MOV RDI,R12
MOV RSI,R12
CALL 0x0015c01a
MOV R14,RAX
MOV RDI,R12
MOV RSI,R12
MOV RDX,R13
CALL 0x0015aad8
LEA RDX,[0x1800f0]
LEA R13,[RBP + -0x100]
MOV RDI,R13
MOV RSI,R12
CALL 0x0015aad8
MOV RDI,R13
MOV RSI,R13
LEA RDX,[RBP + -0xd0]
CALL 0x0015aad8
MOV RDI,R13
MOV RSI,R13
MOV R15,qword ptr [RBP + -0x38]
MOV RDX,R15
CALL 0x0015aad8
MOV RDI,RBX
MOV RSI,RBX
LEA RDX,[RBP + -0xa0]
PUSH 0x30
POP RCX
MOV R8,R14
CALL 0x00151073
MOV RDI,R12
MOV RSI,R12
MOV RDX,R13
PUSH 0x30
POP RCX
MOV R8,R14
CALL 0x00151073
LEA R14,[0x17fcb0]
MOV R13,-0x760c000300030003
MOV RDI,R15
MOV RSI,R14
MOV RDX,R13
CALL 0x00168f40
MOV R15,RAX
MOV RDI,R12
MOV RSI,R14
MOV RDX,R13
CALL 0x00168f40
XOR R15D,EAX
AND R15D,0x1
MOV RDI,R12
MOV RSI,R12
MOV RDX,R15
CALL 0x00156a89
MOV RDI,RBX
MOV RSI,RBX
MOV RDX,qword ptr [RBP + -0x30]
CALL 0x0015aad8
MOV RDI,R12
MOV RSI,R12
LEA RDX,[RBP + -0x70]
CALL 0x0015aad8
ADD RSP,0x138
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void map_to_isogenous_E1(long param_1,int8 param_2)
{
long lVar1;
int8 uVar2;
int8 uVar3;
uint uVar4;
uint uVar5;
int1 local_168 [48];
int1 local_138 [48];
int1 local_108 [48];
int1 local_d8 [48];
int1 local_a8 [48];
int1 local_78 [56];
int8 local_40;
long local_38;
local_40 = param_2;
sqr_fp(local_d8);
mul_fp(local_a8,map_to_isogenous_E1_Z,local_d8);
sqr_fp(local_168,local_a8);
add_fp(local_168,local_168,local_a8);
add_fp(param_1,local_168,BLS12_381_Rx);
mul_fp(param_1,param_1,Bprime_E1);
mul_fp(local_a8,local_a8,param_1);
lVar1 = param_1 + 0x60;
local_38 = lVar1;
mul_fp(lVar1,map_to_isogenous_E1_minus_A,local_168);
uVar2 = vec_is_zero(lVar1,0x30);
vec_select(lVar1,map_to_isogenous_E1_ZxA,lVar1,0x30,uVar2);
sqr_fp(local_168,lVar1);
mul_fp(local_78,lVar1,local_168);
mul_fp(local_168,Aprime_E1,local_168);
sqr_fp(local_138,param_1);
add_fp(local_138,local_138,local_168);
mul_fp(local_138,local_138,param_1);
mul_fp(local_168,Bprime_E1,local_78);
add_fp(local_138,local_138,local_168);
lVar1 = param_1 + 0x30;
sqr_fp(lVar1,local_78);
mul_fp(local_168,local_138,local_78);
mul_fp(lVar1,lVar1,local_168);
uVar2 = recip_sqrt_fp(lVar1,lVar1);
mul_fp(lVar1,lVar1,local_168);
mul_fp(local_108,lVar1,map_to_isogenous_E1_sqrt_minus_ZZZ);
mul_fp(local_108,local_108,local_d8);
uVar3 = local_40;
mul_fp(local_108,local_108,local_40);
vec_select(param_1,param_1,local_a8,0x30,uVar2);
vec_select(lVar1,lVar1,local_108,0x30,uVar2);
uVar4 = sgn0_pty_mont_384(uVar3,BLS12_381_P,0x89f3fffcfffcfffd);
uVar5 = sgn0_pty_mont_384(lVar1,BLS12_381_P,0x89f3fffcfffcfffd);
cneg_fp(lVar1,lVar1,(uVar4 ^ uVar5) & 1);
mul_fp(param_1,param_1,local_38);
mul_fp(lVar1,lVar1,local_78);
return;
}
| |
55,524 | my_numcells_cp932 | eloqsql/strings/ctype-cp932.c | static
size_t my_numcells_cp932(CHARSET_INFO *cs __attribute__((unused)),
const char *str, const char *str_end)
{
size_t clen= 0;
const uchar *b= (const uchar *) str;
const uchar *e= (const uchar *) str_end;
for (clen= 0; b < e; )
{
if (*b >= 0xA1 && *b <= 0xDF)
{
clen++;
b++;
}
else if (*b > 0x7F)
{
clen+= 2;
b+= 2;
}
else
{
clen++;
b++;
}
}
return clen;
} | O0 | c | my_numcells_cp932:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x30(%rbp), %rax
jae 0x37e85
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0xa1, %eax
jl 0x37e40
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0xdf, %eax
jg 0x37e40
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x37e80
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x7f, %eax
jle 0x37e66
movq -0x20(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
jmp 0x37e7e
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x37e80
jmp 0x37e00
movq -0x20(%rbp), %rax
popq %rbp
retq
nopl (%rax,%rax)
| my_numcells_cp932:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], 0
mov rax, [rbp+var_10]
mov [rbp+var_28], rax
mov rax, [rbp+var_18]
mov [rbp+var_30], rax
mov [rbp+var_20], 0
loc_37E00:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_30]
jnb short loc_37E85
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 0A1h
jl short loc_37E40
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 0DFh
jg short loc_37E40
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 1
mov [rbp+var_28], rax
jmp short loc_37E80
loc_37E40:
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 7Fh
jle short loc_37E66
mov rax, [rbp+var_20]
add rax, 2
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
jmp short loc_37E7E
loc_37E66:
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 1
mov [rbp+var_28], rax
loc_37E7E:
jmp short $+2
loc_37E80:
jmp loc_37E00
loc_37E85:
mov rax, [rbp+var_20]
pop rbp
retn
| long long my_numcells_cp932(long long a1, unsigned __int8 *a2, unsigned long long a3)
{
long long v5; // [rsp+10h] [rbp-20h]
v5 = 0LL;
while ( (unsigned long long)a2 < a3 )
{
if ( *a2 < 0xA1u || *a2 > 0xDFu )
{
if ( *a2 <= 0x7Fu )
{
++v5;
++a2;
}
else
{
v5 += 2LL;
a2 += 2;
}
}
else
{
++v5;
++a2;
}
}
return v5;
}
| my_numcells_cp932:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
MOV qword ptr [RBP + -0x20],0x0
LAB_00137e00:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNC 0x00137e85
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xa1
JL 0x00137e40
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xdf
JG 0x00137e40
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x1
MOV qword ptr [RBP + -0x28],RAX
JMP 0x00137e80
LAB_00137e40:
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x7f
JLE 0x00137e66
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
JMP 0x00137e7e
LAB_00137e66:
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x1
MOV qword ptr [RBP + -0x28],RAX
LAB_00137e7e:
JMP 0x00137e80
LAB_00137e80:
JMP 0x00137e00
LAB_00137e85:
MOV RAX,qword ptr [RBP + -0x20]
POP RBP
RET
|
long my_numcells_cp932(int8 param_1,byte *param_2,byte *param_3)
{
byte *local_30;
long local_28;
local_28 = 0;
local_30 = param_2;
while (local_30 < param_3) {
if ((*local_30 < 0xa1) || (0xdf < *local_30)) {
if (*local_30 < 0x80) {
local_28 = local_28 + 1;
local_30 = local_30 + 1;
}
else {
local_28 = local_28 + 2;
local_30 = local_30 + 2;
}
}
else {
local_28 = local_28 + 1;
local_30 = local_30 + 1;
}
}
return local_28;
}
| |
55,525 | my_numcells_cp932 | eloqsql/strings/ctype-cp932.c | static
size_t my_numcells_cp932(CHARSET_INFO *cs __attribute__((unused)),
const char *str, const char *str_end)
{
size_t clen= 0;
const uchar *b= (const uchar *) str;
const uchar *e= (const uchar *) str_end;
for (clen= 0; b < e; )
{
if (*b >= 0xA1 && *b <= 0xDF)
{
clen++;
b++;
}
else if (*b > 0x7F)
{
clen+= 2;
b+= 2;
}
else
{
clen++;
b++;
}
}
return clen;
} | O3 | c | my_numcells_cp932:
cmpq %rdx, %rsi
jae 0x3070b
pushq %rbp
movq %rsp, %rbp
xorl %eax, %eax
movl $0x1, %ecx
movb (%rsi), %dil
leal 0x5f(%rdi), %r8d
shrb $0x7, %dil
movzbl %dil, %edi
incq %rdi
cmpb $0x3f, %r8b
cmovbq %rcx, %rdi
addq %rdi, %rax
addq %rdi, %rsi
cmpq %rdx, %rsi
jb 0x306e4
popq %rbp
retq
xorl %eax, %eax
retq
| my_numcells_cp932:
cmp rsi, rdx
jnb short loc_3070B
push rbp
mov rbp, rsp
xor eax, eax
mov ecx, 1
loc_306E4:
mov dil, [rsi]
lea r8d, [rdi+5Fh]
shr dil, 7
movzx edi, dil
inc rdi
cmp r8b, 3Fh ; '?'
cmovb rdi, rcx
add rax, rdi
add rsi, rdi
cmp rsi, rdx
jb short loc_306E4
pop rbp
retn
loc_3070B:
xor eax, eax
retn
| long long my_numcells_cp932(long long a1, _BYTE *a2, unsigned long long a3)
{
long long result; // rax
long long v4; // rdi
if ( (unsigned long long)a2 >= a3 )
return 0LL;
result = 0LL;
do
{
v4 = (*a2 >> 7) + 1LL;
if ( (unsigned __int8)(*a2 + 95) < 0x3Fu )
v4 = 1LL;
result += v4;
a2 += v4;
}
while ( (unsigned long long)a2 < a3 );
return result;
}
| my_numcells_cp932:
CMP RSI,RDX
JNC 0x0013070b
PUSH RBP
MOV RBP,RSP
XOR EAX,EAX
MOV ECX,0x1
LAB_001306e4:
MOV DIL,byte ptr [RSI]
LEA R8D,[RDI + 0x5f]
SHR DIL,0x7
MOVZX EDI,DIL
INC RDI
CMP R8B,0x3f
CMOVC RDI,RCX
ADD RAX,RDI
ADD RSI,RDI
CMP RSI,RDX
JC 0x001306e4
POP RBP
RET
LAB_0013070b:
XOR EAX,EAX
RET
|
long my_numcells_cp932(int8 param_1,byte *param_2,byte *param_3)
{
long lVar1;
long lVar2;
if (param_2 < param_3) {
lVar1 = 0;
do {
lVar2 = (ulong)(*param_2 >> 7) + 1;
if ((byte)(*param_2 + 0x5f) < 0x3f) {
lVar2 = 1;
}
lVar1 = lVar1 + lVar2;
param_2 = param_2 + lVar2;
} while (param_2 < param_3);
return lVar1;
}
return 0;
}
| |
55,526 | HKDF_Extract | corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/keygen.c | static void HKDF_Extract(unsigned char PRK[32],
const void *salt, size_t salt_len,
const void *IKM, size_t IKM_len,
#ifndef __BLST_HKDF_TESTMODE__
int IKM_fixup,
#endif
HMAC_SHA256_CTX *ctx)
{
unsigned char zero[1] = { 0 };
HMAC_init(ctx, salt != NULL ? salt : zero, salt_len);
HMAC_update(ctx, IKM, IKM_len);
#ifndef __BLST_HKDF_TESTMODE__
if (IKM_fixup) {
/* Section 2.3 KeyGen in BLS-signature draft */
HMAC_update(ctx, zero, 1);
}
#endif
HMAC_final(PRK, ctx);
} | O3 | c | HKDF_Extract:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, %r15d
movq %r8, %r12
movq %rcx, %r13
movq %rdi, %rbx
movq 0x10(%rbp), %r14
leaq -0x29(%rbp), %rax
movb $0x0, (%rax)
testq %rsi, %rsi
cmoveq %rax, %rsi
movq %r14, %rdi
callq 0x25c82
movq %r14, %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x25582
testl %r15d, %r15d
je 0x25b03
leaq -0x29(%rbp), %rsi
movl $0x1, %edx
movq %r14, %rdi
callq 0x25582
movq %rbx, %rdi
movq %r14, %rsi
callq 0x25e34
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| HKDF_Extract:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r15d, r9d
mov r12, r8
mov r13, rcx
mov rbx, rdi
mov r14, [rbp+arg_0]
lea rax, [rbp+var_29]
mov byte ptr [rax], 0
test rsi, rsi
cmovz rsi, rax
mov rdi, r14
call HMAC_init
mov rdi, r14
mov rsi, r13
mov rdx, r12
call sha256_update
test r15d, r15d
jz short loc_25B03
lea rsi, [rbp+var_29]
mov edx, 1
mov rdi, r14
call sha256_update
loc_25B03:
mov rdi, rbx
mov rsi, r14
call HMAC_final
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long HKDF_Extract(long long a1, _BYTE *a2, long long a3, long long a4, long long a5, int a6, long long a7)
{
_BYTE v11[41]; // [rsp+1h] [rbp-29h] BYREF
v11[0] = 0;
if ( !a2 )
a2 = v11;
HMAC_init(a7, a2);
sha256_update(a7, a4, a5);
if ( a6 )
sha256_update(a7, v11, 1LL);
return HMAC_final(a1, a7);
}
| HKDF_Extract:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R15D,R9D
MOV R12,R8
MOV R13,RCX
MOV RBX,RDI
MOV R14,qword ptr [RBP + 0x10]
LEA RAX,[RBP + -0x29]
MOV byte ptr [RAX],0x0
TEST RSI,RSI
CMOVZ RSI,RAX
MOV RDI,R14
CALL 0x00125c82
MOV RDI,R14
MOV RSI,R13
MOV RDX,R12
CALL 0x00125582
TEST R15D,R15D
JZ 0x00125b03
LEA RSI,[RBP + -0x29]
MOV EDX,0x1
MOV RDI,R14
CALL 0x00125582
LAB_00125b03:
MOV RDI,RBX
MOV RSI,R14
CALL 0x00125e34
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void HKDF_Extract(int8 param_1,long param_2,int8 param_3,int8 param_4,
int8 param_5,int param_6,int8 param_7)
{
ulong in_RAX;
int8 uStack_38;
uStack_38 = in_RAX & 0xffffffffffffff;
if (param_2 == 0) {
param_2 = (long)&uStack_38 + 7;
}
HMAC_init(param_7,param_2);
sha256_update(param_7,param_4,param_5);
if (param_6 != 0) {
sha256_update(param_7,(long)&uStack_38 + 7,1);
}
HMAC_final(param_1,param_7);
return;
}
| |
55,527 | mysql_close_slow_part | eloqsql/libmariadb/libmariadb/mariadb_lib.c | void mysql_close_slow_part(MYSQL *mysql)
{
if (mysql->net.pvio)
{
free_old_query(mysql);
mysql->status=MYSQL_STATUS_READY; /* Force command */
mysql->options.reconnect=0;
if (mysql->net.pvio && mysql->net.buff)
ma_simple_command(mysql, COM_QUIT,NullS,0,1,0);
end_server(mysql);
}
/* there is an ongoing async operation */
else if (mysql->options.extension && mysql->options.extension->async_context)
{
if (mysql->options.extension->async_context->pending_gai_res)
{
freeaddrinfo(mysql->options.extension->async_context->pending_gai_res);
mysql->options.extension->async_context->pending_gai_res = 0;
}
if (mysql->options.extension->async_context->pvio)
{
ma_pvio_close(mysql->options.extension->async_context->pvio);
mysql->options.extension->async_context->pvio = 0;
}
}
} | O0 | c | mysql_close_slow_part:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, (%rax)
je 0x4fca8
movq -0x8(%rbp), %rdi
callq 0x4fd70
movq -0x8(%rbp), %rax
movl $0x0, 0x488(%rax)
movq -0x8(%rbp), %rax
movb $0x0, 0x43b(%rax)
movq -0x8(%rbp), %rax
cmpq $0x0, (%rax)
je 0x4fc9a
movq -0x8(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x4fc9a
movq -0x8(%rbp), %rdi
movl $0x1, %r8d
xorl %eax, %eax
movl %eax, %r9d
movl %r8d, %esi
movq %r9, %rdx
movq %r9, %rcx
callq 0x48a20
movq -0x8(%rbp), %rdi
callq 0x47b80
jmp 0x4fd5e
movq -0x8(%rbp), %rax
cmpq $0x0, 0x480(%rax)
je 0x4fd5c
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
cmpq $0x0, 0x28(%rax)
je 0x4fd5c
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
cmpq $0x0, 0x30(%rax)
je 0x4fd15
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x38690
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq $0x0, 0x30(%rax)
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
cmpq $0x0, 0x18(%rax)
je 0x4fd5a
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq 0x18(%rax), %rdi
callq 0x55770
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq $0x0, 0x18(%rax)
jmp 0x4fd5c
jmp 0x4fd5e
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| mysql_close_slow_part:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
cmp qword ptr [rax], 0
jz short loc_4FCA8
mov rdi, [rbp+var_8]
call free_old_query
mov rax, [rbp+var_8]
mov dword ptr [rax+488h], 0
mov rax, [rbp+var_8]
mov byte ptr [rax+43Bh], 0
mov rax, [rbp+var_8]
cmp qword ptr [rax], 0
jz short loc_4FC9A
mov rax, [rbp+var_8]
cmp qword ptr [rax+8], 0
jz short loc_4FC9A
mov rdi, [rbp+var_8]
mov r8d, 1
xor eax, eax
mov r9d, eax
mov esi, r8d
mov rdx, r9
mov rcx, r9
call ma_simple_command
loc_4FC9A:
mov rdi, [rbp+var_8]
call end_server
jmp loc_4FD5E
loc_4FCA8:
mov rax, [rbp+var_8]
cmp qword ptr [rax+480h], 0
jz loc_4FD5C
mov rax, [rbp+var_8]
mov rax, [rax+480h]
cmp qword ptr [rax+28h], 0
jz loc_4FD5C
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
cmp qword ptr [rax+30h], 0
jz short loc_4FD15
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov rdi, [rax+30h]
call _freeaddrinfo
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov qword ptr [rax+30h], 0
loc_4FD15:
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
cmp qword ptr [rax+18h], 0
jz short loc_4FD5A
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov rdi, [rax+18h]
call ma_pvio_close
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov qword ptr [rax+18h], 0
loc_4FD5A:
jmp short $+2
loc_4FD5C:
jmp short $+2
loc_4FD5E:
add rsp, 10h
pop rbp
retn
| long long mysql_close_slow_part(long long a1)
{
long long result; // rax
if ( *(_QWORD *)a1 )
{
free_old_query(a1);
*(_DWORD *)(a1 + 1160) = 0;
*(_BYTE *)(a1 + 1083) = 0;
if ( *(_QWORD *)a1 )
{
if ( *(_QWORD *)(a1 + 8) )
ma_simple_command(a1, 1u, 0LL, 0LL, 1, 0LL);
}
return end_server((_QWORD *)a1);
}
else
{
result = a1;
if ( *(_QWORD *)(a1 + 1152) )
{
result = *(_QWORD *)(a1 + 1152);
if ( *(_QWORD *)(result + 40) )
{
if ( *(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL) )
{
freeaddrinfo(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL));
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL) = 0LL;
}
result = *(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL);
if ( *(_QWORD *)(result + 24) )
{
ma_pvio_close(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 24LL));
result = *(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL);
*(_QWORD *)(result + 24) = 0LL;
}
}
}
}
return result;
}
| mysql_close_slow_part:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX],0x0
JZ 0x0014fca8
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x0014fd70
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x488],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x43b],0x0
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX],0x0
JZ 0x0014fc9a
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x8],0x0
JZ 0x0014fc9a
MOV RDI,qword ptr [RBP + -0x8]
MOV R8D,0x1
XOR EAX,EAX
MOV R9D,EAX
MOV ESI,R8D
MOV RDX,R9
MOV RCX,R9
CALL 0x00148a20
LAB_0014fc9a:
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00147b80
JMP 0x0014fd5e
LAB_0014fca8:
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x480],0x0
JZ 0x0014fd5c
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
CMP qword ptr [RAX + 0x28],0x0
JZ 0x0014fd5c
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
CMP qword ptr [RAX + 0x30],0x0
JZ 0x0014fd15
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV RDI,qword ptr [RAX + 0x30]
CALL 0x00138690
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RAX + 0x30],0x0
LAB_0014fd15:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
CMP qword ptr [RAX + 0x18],0x0
JZ 0x0014fd5a
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
CALL 0x00155770
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RAX + 0x18],0x0
LAB_0014fd5a:
JMP 0x0014fd5c
LAB_0014fd5c:
JMP 0x0014fd5e
LAB_0014fd5e:
ADD RSP,0x10
POP RBP
RET
|
void mysql_close_slow_part(long *param_1)
{
if (*param_1 == 0) {
if ((param_1[0x90] != 0) && (*(long *)(param_1[0x90] + 0x28) != 0)) {
if (*(long *)(*(long *)(param_1[0x90] + 0x28) + 0x30) != 0) {
freeaddrinfo(*(addrinfo **)(*(long *)(param_1[0x90] + 0x28) + 0x30));
*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x30) = 0;
}
if (*(long *)(*(long *)(param_1[0x90] + 0x28) + 0x18) != 0) {
ma_pvio_close(*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x18));
*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x18) = 0;
}
}
}
else {
free_old_query(param_1);
*(int4 *)(param_1 + 0x91) = 0;
*(int1 *)((long)param_1 + 0x43b) = 0;
if ((*param_1 != 0) && (param_1[1] != 0)) {
ma_simple_command(param_1,1,0,0);
}
end_server(param_1);
}
return;
}
| |
55,528 | ggml_flash_attn_ext | Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c | struct ggml_tensor * ggml_flash_attn_ext(
struct ggml_context * ctx,
struct ggml_tensor * q,
struct ggml_tensor * k,
struct ggml_tensor * v,
struct ggml_tensor * mask,
float scale,
float max_bias,
float logit_softcap) {
GGML_ASSERT(ggml_can_mul_mat(k, q));
// TODO: check if vT can be multiplied by (k*qT)
if (mask) {
GGML_ASSERT(ggml_is_contiguous(mask));
GGML_ASSERT(mask->ne[2] == 1);
GGML_ASSERT(mask->ne[3] == 1);
GGML_ASSERT(mask->ne[1] >= GGML_PAD(q->ne[1], GGML_KQ_MASK_PAD) &&
"the Flash-Attention kernel requires the mask to be padded to GGML_KQ_MASK_PAD and at least n_queries big");
//GGML_ASSERT(ggml_can_repeat_rows(mask, qk));
}
if (max_bias > 0.0f) {
GGML_ASSERT(mask);
}
// permute(0, 2, 1, 3)
int64_t ne[4] = { q->ne[0], q->ne[2], q->ne[1], q->ne[3] };
struct ggml_tensor * result = ggml_new_tensor(ctx, GGML_TYPE_F32, 4, ne);
float params[] = { scale, max_bias, logit_softcap };
ggml_set_op_params(result, params, sizeof(params));
result->op = GGML_OP_FLASH_ATTN_EXT;
result->src[0] = q;
result->src[1] = k;
result->src[2] = v;
result->src[3] = mask;
return result;
} | O0 | c | ggml_flash_attn_ext:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movss %xmm0, -0x2c(%rbp)
movss %xmm1, -0x30(%rbp)
movss %xmm2, -0x34(%rbp)
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x4eb20
testb $0x1, %al
jne 0x53130
leaq 0x5e4a1(%rip), %rdi # 0xb15b7
movl $0x10cb, %esi # imm = 0x10CB
leaq 0x5e4e7(%rip), %rdx # 0xb1609
leaq 0x5ecf9(%rip), %rcx # 0xb1e22
movb $0x0, %al
callq 0x48a00
cmpq $0x0, -0x28(%rbp)
je 0x5320d
movq -0x28(%rbp), %rdi
callq 0x42ff0
testb $0x1, %al
jne 0x53169
leaq 0x5e468(%rip), %rdi # 0xb15b7
movl $0x10cf, %esi # imm = 0x10CF
leaq 0x5e4ae(%rip), %rdx # 0xb1609
leaq 0x5ecd7(%rip), %rcx # 0xb1e39
movb $0x0, %al
callq 0x48a00
movq -0x28(%rbp), %rax
cmpq $0x1, 0x20(%rax)
je 0x53195
leaq 0x5e43c(%rip), %rdi # 0xb15b7
movl $0x10d0, %esi # imm = 0x10D0
leaq 0x5e482(%rip), %rdx # 0xb1609
leaq 0x5ecc4(%rip), %rcx # 0xb1e52
movb $0x0, %al
callq 0x48a00
movq -0x28(%rbp), %rax
cmpq $0x1, 0x28(%rax)
je 0x531c1
leaq 0x5e410(%rip), %rdi # 0xb15b7
movl $0x10d1, %esi # imm = 0x10D1
leaq 0x5e456(%rip), %rdx # 0xb1609
leaq 0x5eca9(%rip), %rcx # 0xb1e63
movb $0x0, %al
callq 0x48a00
movq -0x28(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x18(%rcx), %rcx
addq $0x20, %rcx
subq $0x1, %rcx
andq $-0x20, %rcx
cmpq %rcx, %rax
jl 0x531ea
movb $0x1, %al
testb $0x1, %al
jne 0x5320b
jmp 0x531ea
leaq 0x5e3c6(%rip), %rdi # 0xb15b7
movl $0x10d3, %esi # imm = 0x10D3
leaq 0x5e40c(%rip), %rdx # 0xb1609
leaq 0x5ecd9(%rip), %rcx # 0xb1edd
movb $0x0, %al
callq 0x48a00
jmp 0x5320d
movss -0x30(%rbp), %xmm0
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jbe 0x53244
cmpq $0x0, -0x28(%rbp)
jne 0x53242
leaq 0x5e38f(%rip), %rdi # 0xb15b7
movl $0x10d8, %esi # imm = 0x10D8
leaq 0x5e3d5(%rip), %rdx # 0xb1609
leaq 0x5ed44(%rip), %rcx # 0xb1f7f
movb $0x0, %al
callq 0x48a00
jmp 0x53244
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x60(%rbp)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x60(%rbp), %rcx
xorl %esi, %esi
movl $0x4, %edx
callq 0x42510
movq %rax, -0x68(%rbp)
movss -0x2c(%rbp), %xmm0
movss %xmm0, -0x74(%rbp)
movss -0x30(%rbp), %xmm0
movss %xmm0, -0x70(%rbp)
movss -0x34(%rbp), %xmm0
movss %xmm0, -0x6c(%rbp)
movq -0x68(%rbp), %rdi
leaq -0x74(%rbp), %rsi
movl $0xc, %edx
callq 0x4e370
movq -0x68(%rbp), %rax
movl $0x3d, 0x50(%rax)
movq -0x10(%rbp), %rcx
movq -0x68(%rbp), %rax
movq %rcx, 0x98(%rax)
movq -0x18(%rbp), %rcx
movq -0x68(%rbp), %rax
movq %rcx, 0xa0(%rax)
movq -0x20(%rbp), %rcx
movq -0x68(%rbp), %rax
movq %rcx, 0xa8(%rax)
movq -0x28(%rbp), %rcx
movq -0x68(%rbp), %rax
movq %rcx, 0xb0(%rax)
movq -0x68(%rbp), %rax
addq $0x80, %rsp
popq %rbp
retq
| ggml_flash_attn_ext:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
movss [rbp+var_2C], xmm0
movss [rbp+var_30], xmm1
movss [rbp+var_34], xmm2
mov rdi, [rbp+var_18]
mov rsi, [rbp+var_10]
call ggml_can_mul_mat
test al, 1
jnz short loc_53130
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
mov esi, 10CBh
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlCanMulMatK; "ggml_can_mul_mat(k, q)"
mov al, 0
call _ggml_abort
loc_53130:
cmp [rbp+var_28], 0
jz loc_5320D
mov rdi, [rbp+var_28]
call _ggml_is_contiguous
test al, 1
jnz short loc_53169
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
mov esi, 10CFh
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlIsContiguo_4; "ggml_is_contiguous(mask)"
mov al, 0
call _ggml_abort
loc_53169:
mov rax, [rbp+var_28]
cmp qword ptr [rax+20h], 1
jz short loc_53195
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
mov esi, 10D0h
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMaskNe21; "mask->ne[2] == 1"
mov al, 0
call _ggml_abort
loc_53195:
mov rax, [rbp+var_28]
cmp qword ptr [rax+28h], 1
jz short loc_531C1
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
mov esi, 10D1h
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMaskNe31; "mask->ne[3] == 1"
mov al, 0
call _ggml_abort
loc_531C1:
mov rax, [rbp+var_28]
mov rax, [rax+18h]
mov rcx, [rbp+var_10]
mov rcx, [rcx+18h]
add rcx, 20h ; ' '
sub rcx, 1
and rcx, 0FFFFFFFFFFFFFFE0h
cmp rax, rcx
jl short loc_531EA
mov al, 1
test al, 1
jnz short loc_5320B
jmp short $+2
loc_531EA:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
mov esi, 10D3h
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMaskNe1GgmlPad; "mask->ne[1] >= GGML_PAD(q->ne[1], GGML_"...
mov al, 0
call _ggml_abort
loc_5320B:
jmp short $+2
loc_5320D:
movss xmm0, [rbp+var_30]
xorps xmm1, xmm1
ucomiss xmm0, xmm1
jbe short loc_53244
cmp [rbp+var_28], 0
jnz short loc_53242
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
mov esi, 10D8h
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMask; "mask"
mov al, 0
call _ggml_abort
loc_53242:
jmp short $+2
loc_53244:
mov rax, [rbp+var_10]
mov rax, [rax+10h]
mov [rbp+var_60], rax
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov [rbp+var_58], rax
mov rax, [rbp+var_10]
mov rax, [rax+18h]
mov [rbp+var_50], rax
mov rax, [rbp+var_10]
mov rax, [rax+28h]
mov [rbp+var_48], rax
mov rdi, [rbp+var_8]
lea rcx, [rbp+var_60]
xor esi, esi
mov edx, 4
call _ggml_new_tensor
mov [rbp+var_68], rax
movss xmm0, [rbp+var_2C]
movss [rbp+var_74], xmm0
movss xmm0, [rbp+var_30]
movss [rbp+var_70], xmm0
movss xmm0, [rbp+var_34]
movss [rbp+var_6C], xmm0
mov rdi, [rbp+var_68]
lea rsi, [rbp+var_74]
mov edx, 0Ch
call ggml_set_op_params
mov rax, [rbp+var_68]
mov dword ptr [rax+50h], 3Dh ; '='
mov rcx, [rbp+var_10]
mov rax, [rbp+var_68]
mov [rax+98h], rcx
mov rcx, [rbp+var_18]
mov rax, [rbp+var_68]
mov [rax+0A0h], rcx
mov rcx, [rbp+var_20]
mov rax, [rbp+var_68]
mov [rax+0A8h], rcx
mov rcx, [rbp+var_28]
mov rax, [rbp+var_68]
mov [rax+0B0h], rcx
mov rax, [rbp+var_68]
add rsp, 80h
pop rbp
retn
| long long ggml_flash_attn_ext(
long long a1,
_QWORD *a2,
_QWORD *a3,
long long a4,
_QWORD *a5,
float a6,
float a7,
float a8)
{
_DWORD v9[3]; // [rsp+Ch] [rbp-74h] BYREF
long long v10; // [rsp+18h] [rbp-68h]
_QWORD v11[5]; // [rsp+20h] [rbp-60h] BYREF
float v12; // [rsp+4Ch] [rbp-34h]
float v13; // [rsp+50h] [rbp-30h]
float v14; // [rsp+54h] [rbp-2Ch]
_QWORD *v15; // [rsp+58h] [rbp-28h]
long long v16; // [rsp+60h] [rbp-20h]
_QWORD *v17; // [rsp+68h] [rbp-18h]
_QWORD *v18; // [rsp+70h] [rbp-10h]
long long v19; // [rsp+78h] [rbp-8h]
v19 = a1;
v18 = a2;
v17 = a3;
v16 = a4;
v15 = a5;
v14 = a6;
v13 = a7;
v12 = a8;
if ( !ggml_can_mul_mat(a3, a2) )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
4299,
(long long)"GGML_ASSERT(%s) failed",
"ggml_can_mul_mat(k, q)");
if ( v15 )
{
if ( (ggml_is_contiguous((long long)v15) & 1) == 0 )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
4303,
(long long)"GGML_ASSERT(%s) failed",
"ggml_is_contiguous(mask)");
if ( v15[4] != 1LL )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
4304,
(long long)"GGML_ASSERT(%s) failed",
"mask->ne[2] == 1");
if ( v15[5] != 1LL )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
4305,
(long long)"GGML_ASSERT(%s) failed",
"mask->ne[3] == 1");
if ( v15[3] < (signed long long)((v18[3] + 31LL) & 0xFFFFFFFFFFFFFFE0LL) )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
4307,
(long long)"GGML_ASSERT(%s) failed",
"mask->ne[1] >= GGML_PAD(q->ne[1], GGML_KQ_MASK_PAD) && \"the Flash-Attention kernel requires the mask to be padd"
"ed to GGML_KQ_MASK_PAD and at least n_queries big\"");
}
if ( v13 > 0.0 && !v15 )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
4312,
(long long)"GGML_ASSERT(%s) failed",
"mask");
v11[0] = v18[2];
v11[1] = v18[4];
v11[2] = v18[3];
v11[3] = v18[5];
v10 = ggml_new_tensor(v19, 0, 4u, (long long)v11);
*(float *)v9 = v14;
*(float *)&v9[1] = v13;
*(float *)&v9[2] = v12;
ggml_set_op_params(v10, (long long)v9, 0xCuLL);
*(_DWORD *)(v10 + 80) = 61;
*(_QWORD *)(v10 + 152) = v18;
*(_QWORD *)(v10 + 160) = v17;
*(_QWORD *)(v10 + 168) = v16;
*(_QWORD *)(v10 + 176) = v15;
return v10;
}
| ggml_flash_attn_ext:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOVSS dword ptr [RBP + -0x2c],XMM0
MOVSS dword ptr [RBP + -0x30],XMM1
MOVSS dword ptr [RBP + -0x34],XMM2
MOV RDI,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x10]
CALL 0x0014eb20
TEST AL,0x1
JNZ 0x00153130
LEA RDI,[0x1b15b7]
MOV ESI,0x10cb
LEA RDX,[0x1b1609]
LEA RCX,[0x1b1e22]
MOV AL,0x0
CALL 0x00148a00
LAB_00153130:
CMP qword ptr [RBP + -0x28],0x0
JZ 0x0015320d
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x00142ff0
TEST AL,0x1
JNZ 0x00153169
LEA RDI,[0x1b15b7]
MOV ESI,0x10cf
LEA RDX,[0x1b1609]
LEA RCX,[0x1b1e39]
MOV AL,0x0
CALL 0x00148a00
LAB_00153169:
MOV RAX,qword ptr [RBP + -0x28]
CMP qword ptr [RAX + 0x20],0x1
JZ 0x00153195
LEA RDI,[0x1b15b7]
MOV ESI,0x10d0
LEA RDX,[0x1b1609]
LEA RCX,[0x1b1e52]
MOV AL,0x0
CALL 0x00148a00
LAB_00153195:
MOV RAX,qword ptr [RBP + -0x28]
CMP qword ptr [RAX + 0x28],0x1
JZ 0x001531c1
LEA RDI,[0x1b15b7]
MOV ESI,0x10d1
LEA RDX,[0x1b1609]
LEA RCX,[0x1b1e63]
MOV AL,0x0
CALL 0x00148a00
LAB_001531c1:
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x18]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x18]
ADD RCX,0x20
SUB RCX,0x1
AND RCX,-0x20
CMP RAX,RCX
JL 0x001531ea
MOV AL,0x1
TEST AL,0x1
JNZ 0x0015320b
JMP 0x001531ea
LAB_001531ea:
LEA RDI,[0x1b15b7]
MOV ESI,0x10d3
LEA RDX,[0x1b1609]
LEA RCX,[0x1b1edd]
MOV AL,0x0
CALL 0x00148a00
LAB_0015320b:
JMP 0x0015320d
LAB_0015320d:
MOVSS XMM0,dword ptr [RBP + -0x30]
XORPS XMM1,XMM1
UCOMISS XMM0,XMM1
JBE 0x00153244
CMP qword ptr [RBP + -0x28],0x0
JNZ 0x00153242
LEA RDI,[0x1b15b7]
MOV ESI,0x10d8
LEA RDX,[0x1b1609]
LEA RCX,[0x1b1f7f]
MOV AL,0x0
CALL 0x00148a00
LAB_00153242:
JMP 0x00153244
LAB_00153244:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x48],RAX
MOV RDI,qword ptr [RBP + -0x8]
LEA RCX,[RBP + -0x60]
XOR ESI,ESI
MOV EDX,0x4
CALL 0x00142510
MOV qword ptr [RBP + -0x68],RAX
MOVSS XMM0,dword ptr [RBP + -0x2c]
MOVSS dword ptr [RBP + -0x74],XMM0
MOVSS XMM0,dword ptr [RBP + -0x30]
MOVSS dword ptr [RBP + -0x70],XMM0
MOVSS XMM0,dword ptr [RBP + -0x34]
MOVSS dword ptr [RBP + -0x6c],XMM0
MOV RDI,qword ptr [RBP + -0x68]
LEA RSI,[RBP + -0x74]
MOV EDX,0xc
CALL 0x0014e370
MOV RAX,qword ptr [RBP + -0x68]
MOV dword ptr [RAX + 0x50],0x3d
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RAX + 0x98],RCX
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RAX + 0xa0],RCX
MOV RCX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RAX + 0xa8],RCX
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RAX + 0xb0],RCX
MOV RAX,qword ptr [RBP + -0x68]
ADD RSP,0x80
POP RBP
RET
|
/* WARNING: Removing unreachable block (ram,0x001531e8) */
long ggml_flash_attn_ext(int4 param_1,float param_2,int4 param_3,int8 param_4,
long param_5,int8 param_6,int8 param_7,long param_8)
{
ulong uVar1;
int4 local_7c;
float local_78;
int4 local_74;
long local_70;
int8 local_68;
int8 local_60;
int8 local_58;
int8 local_50;
int4 local_3c;
float local_38;
int4 local_34;
long local_30;
int8 local_28;
int8 local_20;
long local_18;
int8 local_10;
local_3c = param_3;
local_38 = param_2;
local_34 = param_1;
local_30 = param_8;
local_28 = param_7;
local_20 = param_6;
local_18 = param_5;
local_10 = param_4;
uVar1 = ggml_can_mul_mat(param_6,param_5);
if ((uVar1 & 1) == 0) {
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
0x10cb,"GGML_ASSERT(%s) failed","ggml_can_mul_mat(k, q)");
}
if (local_30 != 0) {
uVar1 = ggml_is_contiguous(local_30);
if ((uVar1 & 1) == 0) {
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c"
,0x10cf,"GGML_ASSERT(%s) failed","ggml_is_contiguous(mask)");
}
if (*(long *)(local_30 + 0x20) != 1) {
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c"
,0x10d0,"GGML_ASSERT(%s) failed","mask->ne[2] == 1");
}
if (*(long *)(local_30 + 0x28) != 1) {
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c"
,0x10d1,"GGML_ASSERT(%s) failed","mask->ne[3] == 1");
}
if (*(long *)(local_30 + 0x18) < (long)(*(long *)(local_18 + 0x18) + 0x1fU & 0xffffffffffffffe0)
) {
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c"
,0x10d3,"GGML_ASSERT(%s) failed",
"mask->ne[1] >= GGML_PAD(q->ne[1], GGML_KQ_MASK_PAD) && \"the Flash-Attention kernel requires the mask to be padded to GGML_KQ_MASK_PAD and at least n_queries big\""
);
}
}
if ((0.0 < local_38) && (local_30 == 0)) {
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
0x10d8,"GGML_ASSERT(%s) failed",&DAT_001b1f7f);
}
local_68 = *(int8 *)(local_18 + 0x10);
local_60 = *(int8 *)(local_18 + 0x20);
local_58 = *(int8 *)(local_18 + 0x18);
local_50 = *(int8 *)(local_18 + 0x28);
local_70 = ggml_new_tensor(local_10,0,4,&local_68);
local_7c = local_34;
local_78 = local_38;
local_74 = local_3c;
ggml_set_op_params(local_70,&local_7c,0xc);
*(int4 *)(local_70 + 0x50) = 0x3d;
*(long *)(local_70 + 0x98) = local_18;
*(int8 *)(local_70 + 0xa0) = local_20;
*(int8 *)(local_70 + 0xa8) = local_28;
*(long *)(local_70 + 0xb0) = local_30;
return local_70;
}
| |
55,529 | ggml_flash_attn_ext | Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c | struct ggml_tensor * ggml_flash_attn_ext(
struct ggml_context * ctx,
struct ggml_tensor * q,
struct ggml_tensor * k,
struct ggml_tensor * v,
struct ggml_tensor * mask,
float scale,
float max_bias,
float logit_softcap) {
GGML_ASSERT(ggml_can_mul_mat(k, q));
// TODO: check if vT can be multiplied by (k*qT)
if (mask) {
GGML_ASSERT(ggml_is_contiguous(mask));
GGML_ASSERT(mask->ne[2] == 1);
GGML_ASSERT(mask->ne[3] == 1);
GGML_ASSERT(mask->ne[1] >= GGML_PAD(q->ne[1], GGML_KQ_MASK_PAD) &&
"the Flash-Attention kernel requires the mask to be padded to GGML_KQ_MASK_PAD and at least n_queries big");
//GGML_ASSERT(ggml_can_repeat_rows(mask, qk));
}
if (max_bias > 0.0f) {
GGML_ASSERT(mask);
}
// permute(0, 2, 1, 3)
int64_t ne[4] = { q->ne[0], q->ne[2], q->ne[1], q->ne[3] };
struct ggml_tensor * result = ggml_new_tensor(ctx, GGML_TYPE_F32, 4, ne);
float params[] = { scale, max_bias, logit_softcap };
ggml_set_op_params(result, params, sizeof(params));
result->op = GGML_OP_FLASH_ATTN_EXT;
result->src[0] = q;
result->src[1] = k;
result->src[2] = v;
result->src[3] = mask;
return result;
} | O2 | c | ggml_flash_attn_ext:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x40, %rsp
movss %xmm2, 0x10(%rsp)
movss %xmm1, 0x8(%rsp)
movss %xmm0, 0xc(%rsp)
movq %r8, %rbx
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r13
movq %rdx, %rdi
callq 0x224cb
testb %al, %al
je 0x250ae
testq %rbx, %rbx
je 0x24fff
movq %rbx, %rdi
callq 0x1fb90
testb %al, %al
je 0x250ca
cmpq $0x1, 0x20(%rbx)
jne 0x250e6
cmpq $0x1, 0x28(%rbx)
jne 0x25102
movq 0x18(%r12), %rax
leaq 0x1f(%rax), %rcx
andq $-0x20, %rcx
cmpq %rcx, 0x18(%rbx)
jge 0x25016
leaq 0x2959c(%rip), %rdi # 0x4e583
leaq 0x295e7(%rip), %rdx # 0x4e5d5
leaq 0x29e0c(%rip), %rcx # 0x4ee01
movl $0x10d3, %esi # imm = 0x10D3
jmp 0x25138
xorps %xmm0, %xmm0
movss 0x8(%rsp), %xmm1
ucomiss %xmm0, %xmm1
ja 0x2511e
movq 0x18(%r12), %rax
movq 0x10(%r12), %rdx
leaq 0x20(%rsp), %rcx
movq %rdx, (%rcx)
movq 0x20(%r12), %rdx
movq %rdx, 0x8(%rcx)
movq %rax, 0x10(%rcx)
movq 0x28(%r12), %rax
movq %rax, 0x18(%rcx)
pushq $0x4
popq %rdx
movq %r13, %rdi
xorl %esi, %esi
callq 0x1d260
movq %rax, %r13
leaq 0x14(%rsp), %rsi
movss 0xc(%rsp), %xmm0
movss %xmm0, (%rsi)
movss 0x8(%rsp), %xmm0
movss %xmm0, 0x4(%rsi)
movss 0x10(%rsp), %xmm0
movss %xmm0, 0x8(%rsi)
pushq $0xc
popq %rdx
movq %rax, %rdi
callq 0x2221d
movl $0x3d, 0x50(%r13)
movq %r12, 0x98(%r13)
movq %r15, 0xa0(%r13)
movq %r14, 0xa8(%r13)
movq %rbx, 0xb0(%r13)
movq %r13, %rax
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
leaq 0x294ce(%rip), %rdi # 0x4e583
leaq 0x29519(%rip), %rdx # 0x4e5d5
leaq 0x29cec(%rip), %rcx # 0x4edaf
movl $0x10cb, %esi # imm = 0x10CB
jmp 0x25138
leaq 0x294b2(%rip), %rdi # 0x4e583
leaq 0x294fd(%rip), %rdx # 0x4e5d5
leaq 0x29ce7(%rip), %rcx # 0x4edc6
movl $0x10cf, %esi # imm = 0x10CF
jmp 0x25138
leaq 0x29496(%rip), %rdi # 0x4e583
leaq 0x294e1(%rip), %rdx # 0x4e5d5
leaq 0x29ce4(%rip), %rcx # 0x4eddf
movl $0x10d0, %esi # imm = 0x10D0
jmp 0x25138
leaq 0x2947a(%rip), %rdi # 0x4e583
leaq 0x294c5(%rip), %rdx # 0x4e5d5
leaq 0x29cd9(%rip), %rcx # 0x4edf0
movl $0x10d1, %esi # imm = 0x10D1
jmp 0x25138
leaq 0x2945e(%rip), %rdi # 0x4e583
leaq 0x294a9(%rip), %rdx # 0x4e5d5
leaq 0x29d70(%rip), %rcx # 0x4eea3
movl $0x10d8, %esi # imm = 0x10D8
xorl %eax, %eax
callq 0x1f9b0
| ggml_flash_attn_ext:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 40h
movss [rsp+68h+var_58], xmm2
movss [rsp+68h+var_60], xmm1
movss [rsp+68h+var_5C], xmm0
mov rbx, r8
mov r14, rcx
mov r15, rdx
mov r12, rsi
mov r13, rdi
mov rdi, rdx
call ggml_can_mul_mat
test al, al
jz loc_250AE
test rbx, rbx
jz short loc_24FFF
mov rdi, rbx
call _ggml_is_contiguous_0
test al, al
jz loc_250CA
cmp qword ptr [rbx+20h], 1
jnz loc_250E6
cmp qword ptr [rbx+28h], 1
jnz loc_25102
mov rax, [r12+18h]
lea rcx, [rax+1Fh]
and rcx, 0FFFFFFFFFFFFFFE0h
cmp [rbx+18h], rcx
jge short loc_25016
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMaskNe1GgmlPad; "mask->ne[1] >= GGML_PAD(q->ne[1], GGML_"...
mov esi, 10D3h
jmp loc_25138
loc_24FFF:
xorps xmm0, xmm0
movss xmm1, [rsp+68h+var_60]
ucomiss xmm1, xmm0
ja loc_2511E
mov rax, [r12+18h]
loc_25016:
mov rdx, [r12+10h]
lea rcx, [rsp+68h+var_48]
mov [rcx], rdx
mov rdx, [r12+20h]
mov [rcx+8], rdx
mov [rcx+10h], rax
mov rax, [r12+28h]
mov [rcx+18h], rax
push 4
pop rdx
mov rdi, r13
xor esi, esi
call _ggml_new_tensor
mov r13, rax
lea rsi, [rsp+68h+var_54]
movss xmm0, [rsp+68h+var_5C]
movss dword ptr [rsi], xmm0
movss xmm0, [rsp+68h+var_60]
movss dword ptr [rsi+4], xmm0
movss xmm0, [rsp+68h+var_58]
movss dword ptr [rsi+8], xmm0
push 0Ch
pop rdx
mov rdi, rax
call ggml_set_op_params
mov dword ptr [r13+50h], 3Dh ; '='
mov [r13+98h], r12
mov [r13+0A0h], r15
mov [r13+0A8h], r14
mov [r13+0B0h], rbx
mov rax, r13
add rsp, 40h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
loc_250AE:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlCanMulMatK; "ggml_can_mul_mat(k, q)"
mov esi, 10CBh
jmp short loc_25138
loc_250CA:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlIsContiguo_4; "ggml_is_contiguous(mask)"
mov esi, 10CFh
jmp short loc_25138
loc_250E6:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMaskNe21; "mask->ne[2] == 1"
mov esi, 10D0h
jmp short loc_25138
loc_25102:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMaskNe31; "mask->ne[3] == 1"
mov esi, 10D1h
jmp short loc_25138
loc_2511E:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMask; "mask"
mov esi, 10D8h
loc_25138:
xor eax, eax
call _ggml_abort
| long long ggml_flash_attn_ext(
long long a1,
_QWORD *a2,
_QWORD *a3,
long long a4,
_QWORD *a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
double a10,
double a11,
__m128 a12,
__m128 a13)
{
long long v16; // r8
long long v17; // r9
__m128 v18; // xmm4
__m128 v19; // xmm5
long long v20; // rax
const char *v21; // rcx
int v22; // esi
long long v23; // r13
long long v24; // rcx
long long v25; // r8
long long v26; // r9
__m128 v27; // xmm4
__m128 v28; // xmm5
char v30; // [rsp+0h] [rbp-68h]
__int32 v31; // [rsp+Ch] [rbp-5Ch]
_DWORD v32[3]; // [rsp+14h] [rbp-54h] BYREF
_QWORD v33[9]; // [rsp+20h] [rbp-48h] BYREF
v31 = a6.m128_i32[0];
if ( !ggml_can_mul_mat(a3, a2) )
{
v21 = "ggml_can_mul_mat(k, q)";
v22 = 4299;
goto LABEL_16;
}
if ( !a5 )
{
a6 = 0LL;
a7 = (__m128)a7.m128_u32[0];
if ( a7.m128_f32[0] <= 0.0 )
{
v20 = a2[3];
goto LABEL_10;
}
v21 = "mask";
v22 = 4312;
LABEL_16:
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
v22,
(long long)"GGML_ASSERT(%s) failed",
(long long)v21,
v16,
v17,
a6,
a7,
a8,
a9,
v18,
v19,
a12,
a13,
v30);
}
if ( !(unsigned __int8)ggml_is_contiguous_0(a5) )
{
v21 = "ggml_is_contiguous(mask)";
v22 = 4303;
goto LABEL_16;
}
if ( a5[4] != 1LL )
{
v21 = "mask->ne[2] == 1";
v22 = 4304;
goto LABEL_16;
}
if ( a5[5] != 1LL )
{
v21 = "mask->ne[3] == 1";
v22 = 4305;
goto LABEL_16;
}
v20 = a2[3];
if ( a5[3] < (signed long long)((v20 + 31) & 0xFFFFFFFFFFFFFFE0LL) )
{
v21 = "mask->ne[1] >= GGML_PAD(q->ne[1], GGML_KQ_MASK_PAD) && \"the Flash-Attention kernel requires the mask to be pa"
"dded to GGML_KQ_MASK_PAD and at least n_queries big\"";
v22 = 4307;
goto LABEL_16;
}
LABEL_10:
v33[0] = a2[2];
v33[1] = a2[4];
v33[2] = v20;
v33[3] = a2[5];
v23 = ggml_new_tensor(a1, 0LL, 4LL, (long long)v33);
v32[0] = v31;
v32[1] = a7.m128_i32[0];
v32[2] = a8.m128_i32[0];
ggml_set_op_params(v23, (long long)v32, 12LL, (__m128)a8.m128_u32[0], a7, a8, a9, v27, v28, a12, a13, v24, v25, v26);
*(_DWORD *)(v23 + 80) = 61;
*(_QWORD *)(v23 + 152) = a2;
*(_QWORD *)(v23 + 160) = a3;
*(_QWORD *)(v23 + 168) = a4;
*(_QWORD *)(v23 + 176) = a5;
return v23;
}
| ggml_flash_attn_ext:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x40
MOVSS dword ptr [RSP + 0x10],XMM2
MOVSS dword ptr [RSP + 0x8],XMM1
MOVSS dword ptr [RSP + 0xc],XMM0
MOV RBX,R8
MOV R14,RCX
MOV R15,RDX
MOV R12,RSI
MOV R13,RDI
MOV RDI,RDX
CALL 0x001224cb
TEST AL,AL
JZ 0x001250ae
TEST RBX,RBX
JZ 0x00124fff
MOV RDI,RBX
CALL 0x0011fb90
TEST AL,AL
JZ 0x001250ca
CMP qword ptr [RBX + 0x20],0x1
JNZ 0x001250e6
CMP qword ptr [RBX + 0x28],0x1
JNZ 0x00125102
MOV RAX,qword ptr [R12 + 0x18]
LEA RCX,[RAX + 0x1f]
AND RCX,-0x20
CMP qword ptr [RBX + 0x18],RCX
JGE 0x00125016
LEA RDI,[0x14e583]
LEA RDX,[0x14e5d5]
LEA RCX,[0x14ee01]
MOV ESI,0x10d3
JMP 0x00125138
LAB_00124fff:
XORPS XMM0,XMM0
MOVSS XMM1,dword ptr [RSP + 0x8]
UCOMISS XMM1,XMM0
JA 0x0012511e
MOV RAX,qword ptr [R12 + 0x18]
LAB_00125016:
MOV RDX,qword ptr [R12 + 0x10]
LEA RCX,[RSP + 0x20]
MOV qword ptr [RCX],RDX
MOV RDX,qword ptr [R12 + 0x20]
MOV qword ptr [RCX + 0x8],RDX
MOV qword ptr [RCX + 0x10],RAX
MOV RAX,qword ptr [R12 + 0x28]
MOV qword ptr [RCX + 0x18],RAX
PUSH 0x4
POP RDX
MOV RDI,R13
XOR ESI,ESI
CALL 0x0011d260
MOV R13,RAX
LEA RSI,[RSP + 0x14]
MOVSS XMM0,dword ptr [RSP + 0xc]
MOVSS dword ptr [RSI],XMM0
MOVSS XMM0,dword ptr [RSP + 0x8]
MOVSS dword ptr [RSI + 0x4],XMM0
MOVSS XMM0,dword ptr [RSP + 0x10]
MOVSS dword ptr [RSI + 0x8],XMM0
PUSH 0xc
POP RDX
MOV RDI,RAX
CALL 0x0012221d
MOV dword ptr [R13 + 0x50],0x3d
MOV qword ptr [R13 + 0x98],R12
MOV qword ptr [R13 + 0xa0],R15
MOV qword ptr [R13 + 0xa8],R14
MOV qword ptr [R13 + 0xb0],RBX
MOV RAX,R13
ADD RSP,0x40
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
LAB_001250ae:
LEA RDI,[0x14e583]
LEA RDX,[0x14e5d5]
LEA RCX,[0x14edaf]
MOV ESI,0x10cb
JMP 0x00125138
LAB_001250ca:
LEA RDI,[0x14e583]
LEA RDX,[0x14e5d5]
LEA RCX,[0x14edc6]
MOV ESI,0x10cf
JMP 0x00125138
LAB_001250e6:
LEA RDI,[0x14e583]
LEA RDX,[0x14e5d5]
LEA RCX,[0x14eddf]
MOV ESI,0x10d0
JMP 0x00125138
LAB_00125102:
LEA RDI,[0x14e583]
LEA RDX,[0x14e5d5]
LEA RCX,[0x14edf0]
MOV ESI,0x10d1
JMP 0x00125138
LAB_0012511e:
LEA RDI,[0x14e583]
LEA RDX,[0x14e5d5]
LEA RCX,[0x14eea3]
MOV ESI,0x10d8
LAB_00125138:
XOR EAX,EAX
CALL 0x0011f9b0
|
long ggml_flash_attn_ext(int4 param_1,float param_2,int4 param_3,int8 param_4,
long param_5,int8 param_6,int8 param_7,long param_8)
{
char cVar1;
long lVar2;
char *pcVar3;
int8 uVar4;
int4 local_54;
float local_50;
int4 local_4c;
int8 local_48;
int8 local_40;
long local_38;
int8 local_30;
cVar1 = ggml_can_mul_mat(param_6);
if (cVar1 == '\0') {
pcVar3 = "ggml_can_mul_mat(k, q)";
uVar4 = 0x10cb;
}
else if (param_8 == 0) {
if (param_2 <= 0.0) {
local_38 = *(long *)(param_5 + 0x18);
LAB_00125016:
local_48 = *(int8 *)(param_5 + 0x10);
local_40 = *(int8 *)(param_5 + 0x20);
local_30 = *(int8 *)(param_5 + 0x28);
lVar2 = ggml_new_tensor(param_4,0,4);
local_54 = param_1;
local_50 = param_2;
local_4c = param_3;
ggml_set_op_params(lVar2,&local_54,0xc);
*(int4 *)(lVar2 + 0x50) = 0x3d;
*(long *)(lVar2 + 0x98) = param_5;
*(int8 *)(lVar2 + 0xa0) = param_6;
*(int8 *)(lVar2 + 0xa8) = param_7;
*(long *)(lVar2 + 0xb0) = param_8;
return lVar2;
}
pcVar3 = "mask";
uVar4 = 0x10d8;
}
else {
cVar1 = ggml_is_contiguous_0(param_8);
if (cVar1 == '\0') {
pcVar3 = "ggml_is_contiguous(mask)";
uVar4 = 0x10cf;
}
else if (*(long *)(param_8 + 0x20) == 1) {
if (*(long *)(param_8 + 0x28) == 1) {
local_38 = *(long *)(param_5 + 0x18);
if ((long)(local_38 + 0x1fU & 0xffffffffffffffe0) <= *(long *)(param_8 + 0x18))
goto LAB_00125016;
pcVar3 =
"mask->ne[1] >= GGML_PAD(q->ne[1], GGML_KQ_MASK_PAD) && \"the Flash-Attention kernel requires the mask to be padded to GGML_KQ_MASK_PAD and at least n_queries big\""
;
uVar4 = 0x10d3;
}
else {
pcVar3 = "mask->ne[3] == 1";
uVar4 = 0x10d1;
}
}
else {
pcVar3 = "mask->ne[2] == 1";
uVar4 = 0x10d0;
}
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
uVar4,"GGML_ASSERT(%s) failed",pcVar3);
}
| |
55,530 | my_copy_8bit | eloqsql/strings/ctype-simple.c | size_t
my_copy_8bit(CHARSET_INFO *cs __attribute__((unused)),
char *dst, size_t dst_length,
const char *src, size_t src_length,
size_t nchars, MY_STRCOPY_STATUS *status)
{
set_if_smaller(src_length, dst_length);
set_if_smaller(src_length, nchars);
if (src_length)
memmove(dst, src, src_length);
status->m_source_end_pos= src + src_length;
status->m_well_formed_error_pos= NULL;
return src_length;
} | O0 | c | my_copy_8bit:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq 0x10(%rbp), %rax
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x18(%rbp), %rax
jbe 0x94106
movq -0x18(%rbp), %rax
movq %rax, -0x28(%rbp)
jmp 0x94108
jmp 0x9410a
movq -0x28(%rbp), %rax
cmpq -0x30(%rbp), %rax
jbe 0x9411c
movq -0x30(%rbp), %rax
movq %rax, -0x28(%rbp)
jmp 0x9411e
cmpq $0x0, -0x28(%rbp)
je 0x94136
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
callq 0x36150
movq -0x20(%rbp), %rcx
addq -0x28(%rbp), %rcx
movq 0x10(%rbp), %rax
movq %rcx, (%rax)
movq 0x10(%rbp), %rax
movq $0x0, 0x8(%rax)
movq -0x28(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| my_copy_8bit:
push rbp
mov rbp, rsp
sub rsp, 30h
mov rax, [rbp+arg_0]
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov [rbp+var_30], r9
mov rax, [rbp+var_28]
cmp rax, [rbp+var_18]
jbe short loc_94106
mov rax, [rbp+var_18]
mov [rbp+var_28], rax
loc_94106:
jmp short $+2
loc_94108:
jmp short $+2
loc_9410A:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_30]
jbe short loc_9411C
mov rax, [rbp+var_30]
mov [rbp+var_28], rax
loc_9411C:
jmp short $+2
loc_9411E:
cmp [rbp+var_28], 0
jz short loc_94136
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_28]
call _memmove
loc_94136:
mov rcx, [rbp+var_20]
add rcx, [rbp+var_28]
mov rax, [rbp+arg_0]
mov [rax], rcx
mov rax, [rbp+arg_0]
mov qword ptr [rax+8], 0
mov rax, [rbp+var_28]
add rsp, 30h
pop rbp
retn
| unsigned long long my_copy_8bit(
long long a1,
long long a2,
unsigned long long a3,
long long a4,
unsigned long long a5,
unsigned long long a6,
_QWORD *a7)
{
unsigned long long v8; // [rsp+8h] [rbp-28h]
v8 = a5;
if ( a5 > a3 )
v8 = a3;
if ( v8 > a6 )
v8 = a6;
if ( v8 )
memmove(a2, a4, v8);
*a7 = v8 + a4;
a7[1] = 0LL;
return v8;
}
| my_copy_8bit:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV qword ptr [RBP + -0x30],R9
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x18]
JBE 0x00194106
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x28],RAX
LAB_00194106:
JMP 0x00194108
LAB_00194108:
JMP 0x0019410a
LAB_0019410a:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x30]
JBE 0x0019411c
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x28],RAX
LAB_0019411c:
JMP 0x0019411e
LAB_0019411e:
CMP qword ptr [RBP + -0x28],0x0
JZ 0x00194136
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x28]
CALL 0x00136150
LAB_00194136:
MOV RCX,qword ptr [RBP + -0x20]
ADD RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RAX + 0x8],0x0
MOV RAX,qword ptr [RBP + -0x28]
ADD RSP,0x30
POP RBP
RET
|
size_t my_copy_8bit(int8 param_1,void *param_2,ulong param_3,void *param_4,ulong param_5,
ulong param_6,long *param_7)
{
ulong local_30;
local_30 = param_5;
if (param_3 < param_5) {
local_30 = param_3;
}
if (param_6 < local_30) {
local_30 = param_6;
}
if (local_30 != 0) {
memmove(param_2,param_4,local_30);
}
*param_7 = (long)param_4 + local_30;
param_7[1] = 0;
return local_30;
}
| |
55,531 | list_add | eloqsql/libmariadb/libmariadb/ma_list.c | LIST *list_add(LIST *root, LIST *element)
{
if (root)
{
if (root->prev) /* If add in mid of list */
root->prev->next= element;
element->prev=root->prev;
root->prev=element;
}
else
element->prev=0;
element->next=root;
return(element); /* New root */
} | O3 | c | list_add:
movq %rsi, %rax
testq %rdi, %rdi
je 0x1ff09
pushq %rbp
movq %rsp, %rbp
movq (%rdi), %rcx
testq %rcx, %rcx
je 0x1ff12
movq %rax, 0x8(%rcx)
movq (%rdi), %rcx
jmp 0x1ff14
movq $0x0, (%rax)
jmp 0x1ff1b
xorl %ecx, %ecx
movq %rcx, (%rax)
movq %rax, (%rdi)
popq %rbp
movq %rdi, 0x8(%rax)
retq
| list_add:
mov rax, rsi
test rdi, rdi
jz short loc_1FF09
push rbp
mov rbp, rsp
mov rcx, [rdi]
test rcx, rcx
jz short loc_1FF12
mov [rcx+8], rax
mov rcx, [rdi]
jmp short loc_1FF14
loc_1FF09:
mov qword ptr [rax], 0
jmp short loc_1FF1B
loc_1FF12:
xor ecx, ecx
loc_1FF14:
mov [rax], rcx
mov [rdi], rax
pop rbp
loc_1FF1B:
mov [rax+8], rdi
retn
| _QWORD * list_add(long long *a1, _QWORD *a2)
{
_QWORD *result; // rax
long long v3; // rcx
result = a2;
if ( a1 )
{
if ( *a1 )
{
*(_QWORD *)(*a1 + 8) = a2;
v3 = *a1;
}
else
{
v3 = 0LL;
}
*a2 = v3;
*a1 = (long long)a2;
}
else
{
*a2 = 0LL;
}
a2[1] = a1;
return result;
}
| list_add:
MOV RAX,RSI
TEST RDI,RDI
JZ 0x0011ff09
PUSH RBP
MOV RBP,RSP
MOV RCX,qword ptr [RDI]
TEST RCX,RCX
JZ 0x0011ff12
MOV qword ptr [RCX + 0x8],RAX
MOV RCX,qword ptr [RDI]
JMP 0x0011ff14
LAB_0011ff09:
MOV qword ptr [RAX],0x0
JMP 0x0011ff1b
LAB_0011ff12:
XOR ECX,ECX
LAB_0011ff14:
MOV qword ptr [RAX],RCX
MOV qword ptr [RDI],RAX
POP RBP
LAB_0011ff1b:
MOV qword ptr [RAX + 0x8],RDI
RET
|
void list_add(long *param_1,long *param_2)
{
long lVar1;
if (param_1 == (long *)0x0) {
*param_2 = 0;
}
else {
if (*param_1 == 0) {
lVar1 = 0;
}
else {
*(long **)(*param_1 + 8) = param_2;
lVar1 = *param_1;
}
*param_2 = lVar1;
*param_1 = (long)param_2;
}
param_2[1] = (long)param_1;
return;
}
| |
55,532 | SceneMain::checkButtonRestart() | GhostEscape/src/scene_main.cpp | void SceneMain::checkButtonRestart()
{
if (!button_restart_->getIsTrigger()) return;
saveData("assets/score.dat");
game_.setScore(0);
auto scene = new SceneMain();
game_.safeChangeScene(scene); // 或者 当前场景 先clean() 再 init()
} | O3 | cpp | SceneMain::checkButtonRestart():
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
movq 0xc8(%rdi), %rdi
callq 0xaac6
testb %al, %al
je 0xf75c
leaq -0x20(%rbp), %r14
movq %r14, -0x10(%r14)
leaq 0xf36(%rip), %rsi # 0x105ad
leaq 0xf3f(%rip), %rdx # 0x105bd
leaq -0x30(%rbp), %rdi
callq 0x6b6c
movq (%rbx), %rax
leaq -0x30(%rbp), %rsi
movq %rbx, %rdi
callq *0x48(%rax)
movq -0x30(%rbp), %rdi
cmpq %r14, %rdi
je 0xf6a9
movq -0x20(%rbp), %rsi
incq %rsi
callq 0x53d0
movq 0x10(%rbx), %rdi
xorl %esi, %esi
callq 0x5fc8
movl $0xe0, %edi
callq 0x53b0
movq %rax, %r14
movl $0xe0, %edx
movq %rax, %rdi
xorl %esi, %esi
callq 0x5230
leaq 0x59d9(%rip), %rax # 0x150b0
addq $0x10, %rax
movq %rax, (%r14)
callq 0x66dc
movq %rax, 0x10(%r14)
xorps %xmm0, %xmm0
movups %xmm0, 0x18(%r14)
movups %xmm0, 0x28(%r14)
movups %xmm0, 0x38(%r14)
movw $0x1, 0x48(%r14)
movups %xmm0, 0x4c(%r14)
movups %xmm0, 0x60(%r14)
movups %xmm0, 0x70(%r14)
movups %xmm0, 0x80(%r14)
movb $0x0, 0x90(%r14)
leaq 0x65c2(%rip), %rax # 0x15ce8
movq %rax, (%r14)
movups %xmm0, 0x98(%r14)
movups %xmm0, 0xa8(%r14)
movups %xmm0, 0xb8(%r14)
movups %xmm0, 0xc8(%r14)
movq $0x0, 0xd8(%r14)
movq 0x10(%rbx), %rax
movq %r14, 0x28(%rax)
addq $0x20, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
movl $0xe0, %esi
movq %r14, %rdi
jmp 0xf785
movq %rax, %rbx
movq -0x30(%rbp), %rdi
cmpq %r14, %rdi
je 0xf78f
movq -0x20(%rbp), %rsi
incq %rsi
callq 0x53d0
jmp 0xf78f
movq %rax, %rbx
movq %rbx, %rdi
callq 0x5600
nop
| _ZN9SceneMain18checkButtonRestartEv:
push rbp
mov rbp, rsp
push r14
push rbx
sub rsp, 20h
mov rbx, rdi
mov rdi, [rdi+0C8h]; this
call _ZN9HUDButton12getIsTriggerEv; HUDButton::getIsTrigger(void)
test al, al
jz loc_F75C
lea r14, [rbp+var_20]
mov [r14-10h], r14
lea rsi, aAssetsScoreDat; "assets/score.dat"
lea rdx, aAssetsScoreDat+10h; ""
lea rdi, [rbp+var_30]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rax, [rbx]
lea rsi, [rbp+var_30]
mov rdi, rbx
call qword ptr [rax+48h]
mov rdi, [rbp+var_30]; void *
cmp rdi, r14
jz short loc_F6A9
mov rsi, [rbp+var_20]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_F6A9:
mov rdi, [rbx+10h]; this
xor esi, esi; int
call _ZN4Game8setScoreEi; Game::setScore(int)
mov edi, 0E0h; unsigned __int64
call __Znwm; operator new(ulong)
mov r14, rax
mov edx, 0E0h
mov rdi, rax; this
xor esi, esi
call _memset
lea rax, _ZTV6Object; `vtable for'Object
add rax, 10h
mov [r14], rax
call _ZN4Game11GetInstanceEv; Game::GetInstance(void)
mov [r14+10h], rax
xorps xmm0, xmm0
movups xmmword ptr [r14+18h], xmm0
movups xmmword ptr [r14+28h], xmm0
movups xmmword ptr [r14+38h], xmm0
mov word ptr [r14+48h], 1
movups xmmword ptr [r14+4Ch], xmm0
movups xmmword ptr [r14+60h], xmm0
movups xmmword ptr [r14+70h], xmm0
movups xmmword ptr [r14+80h], xmm0
mov byte ptr [r14+90h], 0
lea rax, off_15CE8
mov [r14], rax
movups xmmword ptr [r14+98h], xmm0
movups xmmword ptr [r14+0A8h], xmm0
movups xmmword ptr [r14+0B8h], xmm0
movups xmmword ptr [r14+0C8h], xmm0
mov qword ptr [r14+0D8h], 0
mov rax, [rbx+10h]
mov [rax+28h], r14
loc_F75C:
add rsp, 20h
pop rbx
pop r14
pop rbp
retn
mov rbx, rax
mov esi, 0E0h
mov rdi, r14
jmp short loc_F785
mov rbx, rax
mov rdi, [rbp+var_30]; void *
cmp rdi, r14
jz short loc_F78F
mov rsi, [rbp+var_20]
inc rsi; unsigned __int64
loc_F785:
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_F78F
mov rbx, rax
loc_F78F:
mov rdi, rbx
call __Unwind_Resume
| char SceneMain::checkButtonRestart(HUDButton **this)
{
HUDButton *v2; // rax
long long v3; // rdi
void *v5[2]; // [rsp+0h] [rbp-30h] BYREF
_QWORD v6[4]; // [rsp+10h] [rbp-20h] BYREF
LOBYTE(v2) = HUDButton::getIsTrigger(this[25]);
if ( (_BYTE)v2 )
{
v5[0] = v6;
std::string::_M_construct<char const*>((long long)v5, "assets/score.dat", (long long)"");
(*((void ( **)(HUDButton **, void **))*this + 9))(this, v5);
if ( v5[0] != v6 )
operator delete(v5[0], v6[0] + 1LL);
Game::setScore(this[2], 0);
v3 = operator new(0xE0uLL);
memset(v3, 0LL, 224LL);
*(_QWORD *)v3 = &`vtable for'Object + 2;
*(_QWORD *)(v3 + 16) = Game::GetInstance((Game *)v3);
*(_OWORD *)(v3 + 24) = 0LL;
*(_OWORD *)(v3 + 40) = 0LL;
*(_OWORD *)(v3 + 56) = 0LL;
*(_WORD *)(v3 + 72) = 1;
*(_OWORD *)(v3 + 76) = 0LL;
*(_OWORD *)(v3 + 96) = 0LL;
*(_OWORD *)(v3 + 112) = 0LL;
*(_OWORD *)(v3 + 128) = 0LL;
*(_BYTE *)(v3 + 144) = 0;
*(_QWORD *)v3 = off_15CE8;
*(_OWORD *)(v3 + 152) = 0LL;
*(_OWORD *)(v3 + 168) = 0LL;
*(_OWORD *)(v3 + 184) = 0LL;
*(_OWORD *)(v3 + 200) = 0LL;
*(_QWORD *)(v3 + 216) = 0LL;
v2 = this[2];
*((_QWORD *)v2 + 5) = v3;
}
return (char)v2;
}
| checkButtonRestart:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
SUB RSP,0x20
MOV RBX,RDI
MOV RDI,qword ptr [RDI + 0xc8]
CALL 0x0010aac6
TEST AL,AL
JZ 0x0010f75c
LEA R14,[RBP + -0x20]
MOV qword ptr [R14 + -0x10],R14
LAB_0010f670:
LEA RSI,[0x1105ad]
LEA RDX,[0x1105bd]
LEA RDI,[RBP + -0x30]
CALL 0x00106b6c
MOV RAX,qword ptr [RBX]
LAB_0010f68a:
LEA RSI,[RBP + -0x30]
MOV RDI,RBX
CALL qword ptr [RAX + 0x48]
LAB_0010f694:
MOV RDI,qword ptr [RBP + -0x30]
CMP RDI,R14
JZ 0x0010f6a9
MOV RSI,qword ptr [RBP + -0x20]
INC RSI
CALL 0x001053d0
LAB_0010f6a9:
MOV RDI,qword ptr [RBX + 0x10]
XOR ESI,ESI
CALL 0x00105fc8
MOV EDI,0xe0
CALL 0x001053b0
MOV R14,RAX
MOV EDX,0xe0
MOV RDI,RAX
XOR ESI,ESI
CALL 0x00105230
LEA RAX,[0x1150b0]
ADD RAX,0x10
MOV qword ptr [R14],RAX
LAB_0010f6de:
CALL 0x001066dc
LAB_0010f6e3:
MOV qword ptr [R14 + 0x10],RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R14 + 0x18],XMM0
MOVUPS xmmword ptr [R14 + 0x28],XMM0
MOVUPS xmmword ptr [R14 + 0x38],XMM0
MOV word ptr [R14 + 0x48],0x1
MOVUPS xmmword ptr [R14 + 0x4c],XMM0
MOVUPS xmmword ptr [R14 + 0x60],XMM0
MOVUPS xmmword ptr [R14 + 0x70],XMM0
MOVUPS xmmword ptr [R14 + 0x80],XMM0
MOV byte ptr [R14 + 0x90],0x0
LEA RAX,[0x115ce8]
MOV qword ptr [R14],RAX
MOVUPS xmmword ptr [R14 + 0x98],XMM0
MOVUPS xmmword ptr [R14 + 0xa8],XMM0
MOVUPS xmmword ptr [R14 + 0xb8],XMM0
MOVUPS xmmword ptr [R14 + 0xc8],XMM0
MOV qword ptr [R14 + 0xd8],0x0
MOV RAX,qword ptr [RBX + 0x10]
MOV qword ptr [RAX + 0x28],R14
LAB_0010f75c:
ADD RSP,0x20
POP RBX
POP R14
POP RBP
RET
|
/* SceneMain::checkButtonRestart() */
void __thiscall SceneMain::checkButtonRestart(SceneMain *this)
{
char cVar1;
int8 *__s;
int8 uVar2;
long *local_38 [2];
long local_28 [2];
cVar1 = HUDButton::getIsTrigger(*(HUDButton **)(this + 200));
if (cVar1 != '\0') {
/* try { // try from 0010f670 to 0010f686 has its CatchHandler @ 0010f78c */
local_38[0] = local_28;
std::__cxx11::string::_M_construct<char_const*>(local_38,"assets/score.dat","");
/* try { // try from 0010f68a to 0010f693 has its CatchHandler @ 0010f772 */
(**(code **)(*(long *)this + 0x48))(this);
if (local_38[0] != local_28) {
operator_delete(local_38[0],local_28[0] + 1);
}
Game::setScore(*(Game **)(this + 0x10),0);
__s = (int8 *)operator_new(0xe0);
memset(__s,0,0xe0);
*__s = &PTR__Object_001150c0;
/* try { // try from 0010f6de to 0010f6e2 has its CatchHandler @ 0010f765 */
uVar2 = Game::GetInstance();
__s[2] = uVar2;
__s[3] = 0;
__s[4] = 0;
__s[5] = 0;
__s[6] = 0;
__s[7] = 0;
__s[8] = 0;
*(int2 *)(__s + 9) = 1;
*(int8 *)((long)__s + 0x4c) = 0;
*(int8 *)((long)__s + 0x54) = 0;
__s[0xc] = 0;
__s[0xd] = 0;
__s[0xe] = 0;
__s[0xf] = 0;
__s[0x10] = 0;
__s[0x11] = 0;
*(int1 *)(__s + 0x12) = 0;
*__s = &PTR__Scene_00115ce8;
__s[0x13] = 0;
__s[0x14] = 0;
__s[0x15] = 0;
__s[0x16] = 0;
__s[0x17] = 0;
__s[0x18] = 0;
__s[0x19] = 0;
__s[0x1a] = 0;
__s[0x1b] = 0;
*(int8 **)(*(long *)(this + 0x10) + 0x28) = __s;
}
return;
}
| |
55,533 | OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset const&, OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset*, int const*) const | NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceVertex.cpp | int
FaceVertex::findFVarSubsetExtent(Subset const & vtxSub,
Subset * fvarSubsetPtr,
Index const fvarIndices[]) const {
Subset & fvarSub = *fvarSubsetPtr;
//
// Initialize with tags and declare as a boundary to start:
//
fvarSub.Initialize(vtxSub._tag);
fvarSub.SetBoundary(true);
if (vtxSub._numFacesTotal == 1) return 1;
//
// Inspect/gather faces "after" (counter-clockwise order from) the
// corner face. If we arrive back at the corner face, a periodic
// set is complete, but check the continuity of the seam and apply
// before returning:
//
int cornerFace = _faceInRing;
int numFacesAfterToVisit = vtxSub._numFacesAfter;
if (numFacesAfterToVisit) {
int thisFace = cornerFace;
int nextFace = GetFaceNext(thisFace);
for (int i = 0; i < numFacesAfterToVisit; ++i) {
if (!FaceIndicesMatchAcrossEdge(thisFace, nextFace, fvarIndices)) {
break;
}
++ fvarSub._numFacesAfter;
++ fvarSub._numFacesTotal;
thisFace = nextFace;
nextFace = GetFaceNext(thisFace);
}
if (nextFace == cornerFace) {
assert(vtxSub._numFacesBefore == 0);
if (FaceIndicesMatchAtEdgeEnd(thisFace, cornerFace, fvarIndices)) {
fvarSub.SetBoundary(false);
}
return fvarSub._numFacesTotal;
}
}
//
// Inspect/gather faces "before" (clockwise order from) the corner
// face. Include any faces "after" in the case of a periodic vertex
// that was interrupted by a discontinuity above:
//
int numFacesBeforeToVisit = vtxSub._numFacesBefore;
if (!vtxSub.IsBoundary()) {
numFacesBeforeToVisit += vtxSub._numFacesAfter - fvarSub._numFacesAfter;
}
if (numFacesBeforeToVisit) {
int thisFace = cornerFace;
int prevFace = GetFacePrevious(thisFace);
for (int i = 0; i < numFacesBeforeToVisit; ++i) {
if (!FaceIndicesMatchAcrossEdge(prevFace, thisFace, fvarIndices)) {
break;
}
++ fvarSub._numFacesBefore;
++ fvarSub._numFacesTotal;
thisFace = prevFace;
prevFace = GetFacePrevious(thisFace);
}
}
return fvarSub._numFacesTotal;
} | O0 | cpp | OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset const&, OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset*, int const*) const:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
movq -0x18(%rbp), %rax
movw (%rax), %ax
movw %ax, -0x32(%rbp)
leaq -0x32(%rbp), %rsi
callq 0xd3b10
jmp 0x1891e2
leaq -0x32(%rbp), %rdi
callq 0xc8e30
movq -0x30(%rbp), %rdi
movl $0x1, %esi
callq 0xcb960
movq -0x18(%rbp), %rax
movswl 0x6(%rax), %eax
cmpl $0x1, %eax
jne 0x18922c
movl $0x1, -0x4(%rbp)
jmp 0x1893f8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x32(%rbp), %rdi
callq 0xc8e30
jmp 0x189401
movq -0x70(%rbp), %rax
movswl 0x9a(%rax), %eax
movl %eax, -0x48(%rbp)
movq -0x18(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x4c(%rbp)
cmpl $0x0, -0x4c(%rbp)
je 0x189338
movq -0x70(%rbp), %rdi
movl -0x48(%rbp), %eax
movl %eax, -0x50(%rbp)
movl -0x50(%rbp), %esi
callq 0xd23f0
movl %eax, -0x54(%rbp)
movl $0x0, -0x58(%rbp)
movl -0x58(%rbp), %eax
cmpl -0x4c(%rbp), %eax
jge 0x1892cc
movq -0x70(%rbp), %rdi
movl -0x50(%rbp), %esi
movl -0x54(%rbp), %edx
movq -0x28(%rbp), %rcx
callq 0xd07e0
testb $0x1, %al
jne 0x18928c
jmp 0x1892cc
movq -0x70(%rbp), %rdi
movq -0x30(%rbp), %rax
movw 0x4(%rax), %cx
addw $0x1, %cx
movw %cx, 0x4(%rax)
movq -0x30(%rbp), %rax
movw 0x6(%rax), %cx
addw $0x1, %cx
movw %cx, 0x6(%rax)
movl -0x54(%rbp), %eax
movl %eax, -0x50(%rbp)
movl -0x50(%rbp), %esi
callq 0xd23f0
movl %eax, -0x54(%rbp)
movl -0x58(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x58(%rbp)
jmp 0x18926b
movl -0x54(%rbp), %eax
cmpl -0x48(%rbp), %eax
jne 0x189336
movq -0x18(%rbp), %rax
movswl 0x2(%rax), %eax
cmpl $0x0, %eax
jne 0x1892e3
jmp 0x189302
leaq 0x6d7aa(%rip), %rdi # 0x1f6a94
leaq 0x6d6b1(%rip), %rsi # 0x1f69a2
movl $0x147, %edx # imm = 0x147
leaq 0x6d7b3(%rip), %rcx # 0x1f6ab0
callq 0xc9440
movq -0x70(%rbp), %rdi
movl -0x50(%rbp), %esi
movl -0x48(%rbp), %edx
movq -0x28(%rbp), %rcx
callq 0xd2a40
testb $0x1, %al
jne 0x18931b
jmp 0x189326
movq -0x30(%rbp), %rdi
xorl %esi, %esi
callq 0xcb960
movq -0x30(%rbp), %rax
movswl 0x6(%rax), %eax
movl %eax, -0x4(%rbp)
jmp 0x1893f8
jmp 0x189338
movq -0x18(%rbp), %rax
movswl 0x2(%rax), %eax
movl %eax, -0x5c(%rbp)
movq -0x18(%rbp), %rdi
callq 0xc73d0
testb $0x1, %al
jne 0x189368
movq -0x18(%rbp), %rax
movswl 0x4(%rax), %eax
movq -0x30(%rbp), %rcx
movswl 0x4(%rcx), %ecx
subl %ecx, %eax
addl -0x5c(%rbp), %eax
movl %eax, -0x5c(%rbp)
cmpl $0x0, -0x5c(%rbp)
je 0x1893ed
movq -0x70(%rbp), %rdi
movl -0x48(%rbp), %eax
movl %eax, -0x60(%rbp)
movl -0x60(%rbp), %esi
callq 0xcfb40
movl %eax, -0x64(%rbp)
movl $0x0, -0x68(%rbp)
movl -0x68(%rbp), %eax
cmpl -0x5c(%rbp), %eax
jge 0x1893eb
movq -0x70(%rbp), %rdi
movl -0x64(%rbp), %esi
movl -0x60(%rbp), %edx
movq -0x28(%rbp), %rcx
callq 0xd07e0
testb $0x1, %al
jne 0x1893ab
jmp 0x1893eb
movq -0x70(%rbp), %rdi
movq -0x30(%rbp), %rax
movw 0x2(%rax), %cx
addw $0x1, %cx
movw %cx, 0x2(%rax)
movq -0x30(%rbp), %rax
movw 0x6(%rax), %cx
addw $0x1, %cx
movw %cx, 0x6(%rax)
movl -0x64(%rbp), %eax
movl %eax, -0x60(%rbp)
movl -0x60(%rbp), %esi
callq 0xcfb40
movl %eax, -0x64(%rbp)
movl -0x68(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x68(%rbp)
jmp 0x18938a
jmp 0x1893ed
movq -0x30(%rbp), %rax
movswl 0x6(%rax), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x70, %rsp
popq %rbp
retq
movq -0x40(%rbp), %rdi
callq 0xd58b0
nopw (%rax,%rax)
| _ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex20findFVarSubsetExtentERKNS1_16FaceVertexSubsetEPS3_PKi:
push rbp
mov rbp, rsp
sub rsp, 70h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_10]
mov [rbp+var_70], rax
mov rax, [rbp+var_20]
mov [rbp+var_30], rax
mov rdi, [rbp+var_30]
mov rax, [rbp+var_18]
mov ax, [rax]
mov [rbp+var_32], ax
lea rsi, [rbp+var_32]
call __ZN10OpenSubdiv6v3_6_03Bfr16FaceVertexSubset10InitializeENS1_9VertexTagE; OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset::Initialize(OpenSubdiv::v3_6_0::Bfr::VertexTag)
jmp short $+2
loc_1891E2:
lea rdi, [rbp+var_32]; this
call __ZN10OpenSubdiv6v3_6_03Bfr9VertexTagD2Ev; OpenSubdiv::v3_6_0::Bfr::VertexTag::~VertexTag()
mov rdi, [rbp+var_30]; this
mov esi, 1; bool
call __ZN10OpenSubdiv6v3_6_03Bfr16FaceVertexSubset11SetBoundaryEb; OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset::SetBoundary(bool)
mov rax, [rbp+var_18]
movsx eax, word ptr [rax+6]
cmp eax, 1
jnz short loc_18922C
mov [rbp+var_4], 1
jmp loc_1893F8
mov rcx, rax
mov eax, edx
mov [rbp+var_40], rcx
mov [rbp+var_44], eax
lea rdi, [rbp+var_32]; this
call __ZN10OpenSubdiv6v3_6_03Bfr9VertexTagD2Ev; OpenSubdiv::v3_6_0::Bfr::VertexTag::~VertexTag()
jmp loc_189401
loc_18922C:
mov rax, [rbp+var_70]
movsx eax, word ptr [rax+9Ah]
mov [rbp+var_48], eax
mov rax, [rbp+var_18]
movsx eax, word ptr [rax+4]
mov [rbp+var_4C], eax
cmp [rbp+var_4C], 0
jz loc_189338
mov rdi, [rbp+var_70]; this
mov eax, [rbp+var_48]
mov [rbp+var_50], eax
mov esi, [rbp+var_50]; int
call __ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex11GetFaceNextEi; OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetFaceNext(int)
mov [rbp+var_54], eax
mov [rbp+var_58], 0
loc_18926B:
mov eax, [rbp+var_58]
cmp eax, [rbp+var_4C]
jge short loc_1892CC
mov rdi, [rbp+var_70]; this
mov esi, [rbp+var_50]; int
mov edx, [rbp+var_54]; int
mov rcx, [rbp+var_28]; int *
call __ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex26FaceIndicesMatchAcrossEdgeEiiPKi; OpenSubdiv::v3_6_0::Bfr::FaceVertex::FaceIndicesMatchAcrossEdge(int,int,int const*)
test al, 1
jnz short loc_18928C
jmp short loc_1892CC
loc_18928C:
mov rdi, [rbp+var_70]; this
mov rax, [rbp+var_30]
mov cx, [rax+4]
add cx, 1
mov [rax+4], cx
mov rax, [rbp+var_30]
mov cx, [rax+6]
add cx, 1
mov [rax+6], cx
mov eax, [rbp+var_54]
mov [rbp+var_50], eax
mov esi, [rbp+var_50]; int
call __ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex11GetFaceNextEi; OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetFaceNext(int)
mov [rbp+var_54], eax
mov eax, [rbp+var_58]
add eax, 1
mov [rbp+var_58], eax
jmp short loc_18926B
loc_1892CC:
mov eax, [rbp+var_54]
cmp eax, [rbp+var_48]
jnz short loc_189336
mov rax, [rbp+var_18]
movsx eax, word ptr [rax+2]
cmp eax, 0
jnz short loc_1892E3
jmp short loc_189302
loc_1892E3:
lea rdi, aVtxsubNumfaces; "vtxSub._numFacesBefore == 0"
lea rsi, aWorkspaceLlm4b_31; "/workspace/llm4binary/github/2025_star3"...
mov edx, 147h
lea rcx, aIntOpensubdivV_21; "int OpenSubdiv::v3_6_0::Bfr::FaceVertex"...
call ___assert_fail
loc_189302:
mov rdi, [rbp+var_70]; this
mov esi, [rbp+var_50]; int
mov edx, [rbp+var_48]; int
mov rcx, [rbp+var_28]; int *
call __ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex25FaceIndicesMatchAtEdgeEndEiiPKi; OpenSubdiv::v3_6_0::Bfr::FaceVertex::FaceIndicesMatchAtEdgeEnd(int,int,int const*)
test al, 1
jnz short loc_18931B
jmp short loc_189326
loc_18931B:
mov rdi, [rbp+var_30]; this
xor esi, esi; bool
call __ZN10OpenSubdiv6v3_6_03Bfr16FaceVertexSubset11SetBoundaryEb; OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset::SetBoundary(bool)
loc_189326:
mov rax, [rbp+var_30]
movsx eax, word ptr [rax+6]
mov [rbp+var_4], eax
jmp loc_1893F8
loc_189336:
jmp short $+2
loc_189338:
mov rax, [rbp+var_18]
movsx eax, word ptr [rax+2]
mov [rbp+var_5C], eax
mov rdi, [rbp+var_18]; this
call __ZNK10OpenSubdiv6v3_6_03Bfr16FaceVertexSubset10IsBoundaryEv; OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset::IsBoundary(void)
test al, 1
jnz short loc_189368
mov rax, [rbp+var_18]
movsx eax, word ptr [rax+4]
mov rcx, [rbp+var_30]
movsx ecx, word ptr [rcx+4]
sub eax, ecx
add eax, [rbp+var_5C]
mov [rbp+var_5C], eax
loc_189368:
cmp [rbp+var_5C], 0
jz short loc_1893ED
mov rdi, [rbp+var_70]; this
mov eax, [rbp+var_48]
mov [rbp+var_60], eax
mov esi, [rbp+var_60]; int
call __ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex15GetFacePreviousEi; OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetFacePrevious(int)
mov [rbp+var_64], eax
mov [rbp+var_68], 0
loc_18938A:
mov eax, [rbp+var_68]
cmp eax, [rbp+var_5C]
jge short loc_1893EB
mov rdi, [rbp+var_70]; this
mov esi, [rbp+var_64]; int
mov edx, [rbp+var_60]; int
mov rcx, [rbp+var_28]; int *
call __ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex26FaceIndicesMatchAcrossEdgeEiiPKi; OpenSubdiv::v3_6_0::Bfr::FaceVertex::FaceIndicesMatchAcrossEdge(int,int,int const*)
test al, 1
jnz short loc_1893AB
jmp short loc_1893EB
loc_1893AB:
mov rdi, [rbp+var_70]; this
mov rax, [rbp+var_30]
mov cx, [rax+2]
add cx, 1
mov [rax+2], cx
mov rax, [rbp+var_30]
mov cx, [rax+6]
add cx, 1
mov [rax+6], cx
mov eax, [rbp+var_64]
mov [rbp+var_60], eax
mov esi, [rbp+var_60]; int
call __ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex15GetFacePreviousEi; OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetFacePrevious(int)
mov [rbp+var_64], eax
mov eax, [rbp+var_68]
add eax, 1
mov [rbp+var_68], eax
jmp short loc_18938A
loc_1893EB:
jmp short $+2
loc_1893ED:
mov rax, [rbp+var_30]
movsx eax, word ptr [rax+6]
mov [rbp+var_4], eax
loc_1893F8:
mov eax, [rbp+var_4]
add rsp, 70h
pop rbp
retn
loc_189401:
mov rdi, [rbp+var_40]
call __Unwind_Resume
| long long OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(
OpenSubdiv::v3_6_0::Bfr::FaceVertex *this,
const OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset *a2,
OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset *a3,
int *a4)
{
int j; // [rsp+8h] [rbp-68h]
int FacePrevious; // [rsp+Ch] [rbp-64h]
int v7; // [rsp+10h] [rbp-60h]
int v8; // [rsp+14h] [rbp-5Ch]
int i; // [rsp+18h] [rbp-58h]
int FaceNext; // [rsp+1Ch] [rbp-54h]
int v11; // [rsp+20h] [rbp-50h]
int v12; // [rsp+24h] [rbp-4Ch]
int v13; // [rsp+28h] [rbp-48h]
__int16 v14; // [rsp+3Eh] [rbp-32h] BYREF
OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset *v15; // [rsp+40h] [rbp-30h]
int *v16; // [rsp+48h] [rbp-28h]
OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset *v17; // [rsp+50h] [rbp-20h]
OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset *v18; // [rsp+58h] [rbp-18h]
OpenSubdiv::v3_6_0::Bfr::FaceVertex *v19; // [rsp+60h] [rbp-10h]
v19 = this;
v18 = a2;
v17 = a3;
v16 = a4;
v15 = a3;
v14 = *(_WORD *)a2;
OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset::Initialize(a3, &v14);
OpenSubdiv::v3_6_0::Bfr::VertexTag::~VertexTag((OpenSubdiv::v3_6_0::Bfr::VertexTag *)&v14);
OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset::SetBoundary(v15, 1);
if ( *((_WORD *)v18 + 3) == 1 )
{
return 1;
}
else
{
v13 = *((__int16 *)this + 77);
v12 = *((__int16 *)v18 + 2);
if ( !*((_WORD *)v18 + 2) )
goto LABEL_14;
v11 = *((__int16 *)this + 77);
FaceNext = OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetFaceNext(this, v13);
for ( i = 0;
i < v12
&& (OpenSubdiv::v3_6_0::Bfr::FaceVertex::FaceIndicesMatchAcrossEdge(this, v11, FaceNext, v16) & 1) != 0;
++i )
{
++*((_WORD *)v15 + 2);
++*((_WORD *)v15 + 3);
v11 = FaceNext;
FaceNext = OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetFaceNext(this, FaceNext);
}
if ( FaceNext == v13 )
{
if ( *((_WORD *)v18 + 1) )
__assert_fail(
"vtxSub._numFacesBefore == 0",
"/workspace/llm4binary/github/2025_star3/NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceVertex.cpp",
327LL,
"int OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(const Subset &, Subset *, const Index *) const");
if ( (OpenSubdiv::v3_6_0::Bfr::FaceVertex::FaceIndicesMatchAtEdgeEnd(this, v11, v13, v16) & 1) != 0 )
OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset::SetBoundary(v15, 0);
return (unsigned int)*((__int16 *)v15 + 3);
}
else
{
LABEL_14:
v8 = *((__int16 *)v18 + 1);
if ( (OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset::IsBoundary(v18) & 1) == 0 )
v8 += *((__int16 *)v18 + 2) - *((__int16 *)v15 + 2);
if ( v8 )
{
v7 = v13;
FacePrevious = OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetFacePrevious(this, v13);
for ( j = 0;
j < v8
&& (OpenSubdiv::v3_6_0::Bfr::FaceVertex::FaceIndicesMatchAcrossEdge(this, FacePrevious, v7, v16) & 1) != 0;
++j )
{
++*((_WORD *)v15 + 1);
++*((_WORD *)v15 + 3);
v7 = FacePrevious;
FacePrevious = OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetFacePrevious(this, FacePrevious);
}
}
return (unsigned int)*((__int16 *)v15 + 3);
}
}
}
| |||
55,534 | OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset const&, OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset*, int const*) const | NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceVertex.cpp | int
FaceVertex::findFVarSubsetExtent(Subset const & vtxSub,
Subset * fvarSubsetPtr,
Index const fvarIndices[]) const {
Subset & fvarSub = *fvarSubsetPtr;
//
// Initialize with tags and declare as a boundary to start:
//
fvarSub.Initialize(vtxSub._tag);
fvarSub.SetBoundary(true);
if (vtxSub._numFacesTotal == 1) return 1;
//
// Inspect/gather faces "after" (counter-clockwise order from) the
// corner face. If we arrive back at the corner face, a periodic
// set is complete, but check the continuity of the seam and apply
// before returning:
//
int cornerFace = _faceInRing;
int numFacesAfterToVisit = vtxSub._numFacesAfter;
if (numFacesAfterToVisit) {
int thisFace = cornerFace;
int nextFace = GetFaceNext(thisFace);
for (int i = 0; i < numFacesAfterToVisit; ++i) {
if (!FaceIndicesMatchAcrossEdge(thisFace, nextFace, fvarIndices)) {
break;
}
++ fvarSub._numFacesAfter;
++ fvarSub._numFacesTotal;
thisFace = nextFace;
nextFace = GetFaceNext(thisFace);
}
if (nextFace == cornerFace) {
assert(vtxSub._numFacesBefore == 0);
if (FaceIndicesMatchAtEdgeEnd(thisFace, cornerFace, fvarIndices)) {
fvarSub.SetBoundary(false);
}
return fvarSub._numFacesTotal;
}
}
//
// Inspect/gather faces "before" (clockwise order from) the corner
// face. Include any faces "after" in the case of a periodic vertex
// that was interrupted by a discontinuity above:
//
int numFacesBeforeToVisit = vtxSub._numFacesBefore;
if (!vtxSub.IsBoundary()) {
numFacesBeforeToVisit += vtxSub._numFacesAfter - fvarSub._numFacesAfter;
}
if (numFacesBeforeToVisit) {
int thisFace = cornerFace;
int prevFace = GetFacePrevious(thisFace);
for (int i = 0; i < numFacesBeforeToVisit; ++i) {
if (!FaceIndicesMatchAcrossEdge(prevFace, thisFace, fvarIndices)) {
break;
}
++ fvarSub._numFacesBefore;
++ fvarSub._numFacesTotal;
thisFace = prevFace;
prevFace = GetFacePrevious(thisFace);
}
}
return fvarSub._numFacesTotal;
} | O1 | cpp | OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset const&, OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset*, int const*) const:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movzwl (%rsi), %r10d
xorl %eax, %eax
movl %eax, 0x2(%rdx)
movw $0x1, 0x6(%rdx)
movl %eax, 0x8(%rdx)
movl %r10d, %eax
orl $0x1, %eax
movw %ax, (%rdx)
movl $0x1, %eax
cmpw $0x1, 0x6(%rsi)
je 0x8788d
movswl 0x9a(%rdi), %r8d
movslq %r8d, %r14
movswl 0x4(%rsi), %eax
testl %eax, %eax
je 0x8774c
movswl 0x98(%rdi), %r11d
btl $0x8, %r11d
jb 0x875d1
movswl 0x2(%rdi), %r9d
decl %r9d
cmpl %r8d, %r9d
jle 0x875e0
leal 0x1(%r8), %r11d
jmp 0x875e7
movq 0xa8(%rdi), %r9
movswl 0x2(%r9,%r14,4), %r11d
jmp 0x875e7
andl $0x1, %r11d
negl %r11d
movq %r14, (%rsp)
testw %ax, %ax
jle 0x876de
movswl 0x9c(%rdi), %ebx
movq 0x60(%rdi), %r14
movq 0xa8(%rdi), %r15
movswl 0x2(%rdi), %ebp
decl %ebp
movl %r8d, %r13d
movl %r13d, %r12d
movl %r11d, %r13d
testw %bx, %bx
je 0x87623
movl %r12d, %r11d
imull %ebx, %r11d
jmp 0x8762a
movslq %r12d, %r9
movl (%r14,%r9,4), %r11d
testw %bx, %bx
je 0x87638
movl %r13d, %r9d
imull %ebx, %r9d
jmp 0x8763f
movslq %r13d, %r9
movl (%r14,%r9,4), %r9d
movslq %r11d, %r11
movl (%rcx,%r11,4), %r11d
movslq %r9d, %r9
cmpl (%rcx,%r9,4), %r11d
jne 0x876d9
leal 0x1(%r12), %r11d
testw %bx, %bx
je 0x87663
imull %ebx, %r11d
jmp 0x8766a
movslq %r11d, %r9
movl (%r14,%r9,4), %r11d
testw %bx, %bx
je 0x87678
movl %r13d, %r9d
imull %ebx, %r9d
jmp 0x8767f
movslq %r13d, %r9
movl (%r14,%r9,4), %r9d
movslq %r11d, %r11
movl -0x4(%rcx,%r11,4), %r11d
movslq %r9d, %r9
cmpl 0x4(%rcx,%r9,4), %r11d
jne 0x876d9
incw 0x4(%rdx)
incw 0x6(%rdx)
movswl 0x98(%rdi), %r11d
btl $0x8, %r11d
jb 0x876b3
cmpl %r13d, %ebp
jle 0x876c5
leal 0x1(%r13), %r11d
jmp 0x876cc
leal 0x1(,%r13,2), %r9d
movslq %r9d, %r9
movswl (%r15,%r9,2), %r11d
jmp 0x876cc
andl $0x1, %r11d
negl %r11d
movl %r13d, %r12d
decl %eax
jne 0x8760f
jmp 0x876e1
movl %r13d, %r11d
jmp 0x876e1
movl %r8d, %r12d
cmpl %r8d, %r11d
movq (%rsp), %r14
jne 0x87743
cmpw $0x0, 0x2(%rsi)
jne 0x8789c
incl %r12d
movswl 0x9c(%rdi), %eax
testl %eax, %eax
je 0x87709
imull %eax, %r12d
jmp 0x87714
movq 0x60(%rdi), %r9
movslq %r12d, %rbx
movl (%r9,%rbx,4), %r12d
movslq %r12d, %r9
movl -0x4(%rcx,%r9,4), %ebx
testw %ax, %ax
je 0x87727
imull %r8d, %eax
jmp 0x8772f
movq 0x60(%rdi), %rax
movl (%rax,%r14,4), %eax
cltq
cmpl 0x4(%rcx,%rax,4), %ebx
jne 0x8773f
andl $-0x2, %r10d
movw %r10w, (%rdx)
movswl 0x6(%rdx), %eax
cmpl %r8d, %r11d
je 0x8788d
movswl 0x2(%rsi), %eax
testb $0x1, (%rsi)
jne 0x87765
movswl 0x4(%rsi), %esi
movswl 0x4(%rdx), %r9d
addl %eax, %esi
subl %r9d, %esi
movl %esi, %eax
testl %eax, %eax
je 0x87889
movl 0x98(%rdi), %esi
btl $0x8, %esi
jb 0x87785
testw %r8w, %r8w
je 0x87793
leal -0x1(%r8), %ebx
jmp 0x877a8
movq 0xa8(%rdi), %rsi
movswl (%rsi,%r14,4), %ebx
jmp 0x877a8
andl $0x1, %esi
movswl 0x2(%rdi), %r9d
decl %r9d
xorl %ebx, %ebx
negw %si
sbbl %ebx, %ebx
orl %r9d, %ebx
testl %eax, %eax
jle 0x87889
movswl 0x9c(%rdi), %esi
movq 0x60(%rdi), %r9
movq 0xa8(%rdi), %r10
movl %r8d, %r11d
movl %ebx, %r8d
testw %si, %si
je 0x877d5
movl %r8d, %ebx
imull %esi, %ebx
jmp 0x877dc
movslq %r8d, %rbx
movl (%r9,%rbx,4), %ebx
testw %si, %si
je 0x877e9
movl %r11d, %ebp
imull %esi, %ebp
jmp 0x877f0
movslq %r11d, %r14
movl (%r9,%r14,4), %ebp
movslq %ebx, %rbx
movl (%rcx,%rbx,4), %ebx
movslq %ebp, %r14
cmpl (%rcx,%r14,4), %ebx
jne 0x87889
leal 0x1(%r8), %ebx
testw %si, %si
je 0x87811
imull %esi, %ebx
jmp 0x87818
movslq %ebx, %rbx
movl (%r9,%rbx,4), %ebx
testw %si, %si
je 0x87823
imull %esi, %r11d
jmp 0x8782a
movslq %r11d, %r11
movl (%r9,%r11,4), %r11d
movslq %ebx, %rbx
movl -0x4(%rcx,%rbx,4), %ebx
movslq %r11d, %r11
cmpl 0x4(%rcx,%r11,4), %ebx
jne 0x87889
incw 0x2(%rdx)
incw 0x6(%rdx)
movl 0x98(%rdi), %r11d
btl $0x8, %r11d
jb 0x8785c
testl %r8d, %r8d
je 0x8786a
leal -0x1(%r8), %ebx
jmp 0x87881
leal (%r8,%r8), %r11d
movslq %r11d, %r11
movswl (%r10,%r11,2), %ebx
jmp 0x87881
andl $0x1, %r11d
movswl 0x2(%rdi), %ebp
decl %ebp
negw %r11w
movl $0x0, %ebx
sbbl %ebx, %ebx
orl %ebp, %ebx
decl %eax
jne 0x877c2
movswl 0x6(%rdx), %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x36b40(%rip), %rdi # 0xbe3e3
leaq 0x36a47(%rip), %rsi # 0xbe2f1
leaq 0x36b4e(%rip), %rcx # 0xbe3ff
movl $0x147, %edx # imm = 0x147
callq 0x39560
nop
| _ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex20findFVarSubsetExtentERKNS1_16FaceVertexSubsetEPS3_PKi:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
movzx r10d, word ptr [rsi]
xor eax, eax
mov [rdx+2], eax
mov word ptr [rdx+6], 1
mov [rdx+8], eax
mov eax, r10d
or eax, 1
mov [rdx], ax
mov eax, 1
cmp word ptr [rsi+6], 1
jz loc_8788D
movsx r8d, word ptr [rdi+9Ah]
movsxd r14, r8d
movsx eax, word ptr [rsi+4]
test eax, eax
jz loc_8774C
movsx r11d, word ptr [rdi+98h]
bt r11d, 8
jb short loc_875D1
movsx r9d, word ptr [rdi+2]
dec r9d
cmp r9d, r8d
jle short loc_875E0
lea r11d, [r8+1]
jmp short loc_875E7
loc_875D1:
mov r9, [rdi+0A8h]
movsx r11d, word ptr [r9+r14*4+2]
jmp short loc_875E7
loc_875E0:
and r11d, 1
neg r11d
loc_875E7:
mov [rsp+38h+var_38], r14
test ax, ax
jle loc_876DE
movsx ebx, word ptr [rdi+9Ch]
mov r14, [rdi+60h]
mov r15, [rdi+0A8h]
movsx ebp, word ptr [rdi+2]
dec ebp
mov r13d, r8d
loc_8760F:
mov r12d, r13d
mov r13d, r11d
test bx, bx
jz short loc_87623
mov r11d, r12d
imul r11d, ebx
jmp short loc_8762A
loc_87623:
movsxd r9, r12d
mov r11d, [r14+r9*4]
loc_8762A:
test bx, bx
jz short loc_87638
mov r9d, r13d
imul r9d, ebx
jmp short loc_8763F
loc_87638:
movsxd r9, r13d
mov r9d, [r14+r9*4]
loc_8763F:
movsxd r11, r11d
mov r11d, [rcx+r11*4]
movsxd r9, r9d
cmp r11d, [rcx+r9*4]
jnz loc_876D9
lea r11d, [r12+1]
test bx, bx
jz short loc_87663
imul r11d, ebx
jmp short loc_8766A
loc_87663:
movsxd r9, r11d
mov r11d, [r14+r9*4]
loc_8766A:
test bx, bx
jz short loc_87678
mov r9d, r13d
imul r9d, ebx
jmp short loc_8767F
loc_87678:
movsxd r9, r13d
mov r9d, [r14+r9*4]
loc_8767F:
movsxd r11, r11d
mov r11d, [rcx+r11*4-4]
movsxd r9, r9d
cmp r11d, [rcx+r9*4+4]
jnz short loc_876D9
inc word ptr [rdx+4]
inc word ptr [rdx+6]
movsx r11d, word ptr [rdi+98h]
bt r11d, 8
jb short loc_876B3
cmp ebp, r13d
jle short loc_876C5
lea r11d, [r13+1]
jmp short loc_876CC
loc_876B3:
lea r9d, ds:1[r13*2]
movsxd r9, r9d
movsx r11d, word ptr [r15+r9*2]
jmp short loc_876CC
loc_876C5:
and r11d, 1
neg r11d
loc_876CC:
mov r12d, r13d
dec eax
jnz loc_8760F
jmp short loc_876E1
loc_876D9:
mov r11d, r13d
jmp short loc_876E1
loc_876DE:
mov r12d, r8d
loc_876E1:
cmp r11d, r8d
mov r14, [rsp+38h+var_38]
jnz short loc_87743
cmp word ptr [rsi+2], 0
jnz loc_8789C
inc r12d
movsx eax, word ptr [rdi+9Ch]
test eax, eax
jz short loc_87709
imul r12d, eax
jmp short loc_87714
loc_87709:
mov r9, [rdi+60h]
movsxd rbx, r12d
mov r12d, [r9+rbx*4]
loc_87714:
movsxd r9, r12d
mov ebx, [rcx+r9*4-4]
test ax, ax
jz short loc_87727
imul eax, r8d
jmp short loc_8772F
loc_87727:
mov rax, [rdi+60h]
mov eax, [rax+r14*4]
loc_8772F:
cdqe
cmp ebx, [rcx+rax*4+4]
jnz short loc_8773F
and r10d, 0FFFFFFFEh
mov [rdx], r10w
loc_8773F:
movsx eax, word ptr [rdx+6]
loc_87743:
cmp r11d, r8d
jz loc_8788D
loc_8774C:
movsx eax, word ptr [rsi+2]
test byte ptr [rsi], 1
jnz short loc_87765
movsx esi, word ptr [rsi+4]
movsx r9d, word ptr [rdx+4]
add esi, eax
sub esi, r9d
mov eax, esi
loc_87765:
test eax, eax
jz loc_87889
mov esi, [rdi+98h]
bt esi, 8
jb short loc_87785
test r8w, r8w
jz short loc_87793
lea ebx, [r8-1]
jmp short loc_877A8
loc_87785:
mov rsi, [rdi+0A8h]
movsx ebx, word ptr [rsi+r14*4]
jmp short loc_877A8
loc_87793:
and esi, 1
movsx r9d, word ptr [rdi+2]
dec r9d
xor ebx, ebx
neg si
sbb ebx, ebx
or ebx, r9d
loc_877A8:
test eax, eax
jle loc_87889
movsx esi, word ptr [rdi+9Ch]
mov r9, [rdi+60h]
mov r10, [rdi+0A8h]
loc_877C2:
mov r11d, r8d
mov r8d, ebx
test si, si
jz short loc_877D5
mov ebx, r8d
imul ebx, esi
jmp short loc_877DC
loc_877D5:
movsxd rbx, r8d
mov ebx, [r9+rbx*4]
loc_877DC:
test si, si
jz short loc_877E9
mov ebp, r11d
imul ebp, esi
jmp short loc_877F0
loc_877E9:
movsxd r14, r11d
mov ebp, [r9+r14*4]
loc_877F0:
movsxd rbx, ebx
mov ebx, [rcx+rbx*4]
movsxd r14, ebp
cmp ebx, [rcx+r14*4]
jnz loc_87889
lea ebx, [r8+1]
test si, si
jz short loc_87811
imul ebx, esi
jmp short loc_87818
loc_87811:
movsxd rbx, ebx
mov ebx, [r9+rbx*4]
loc_87818:
test si, si
jz short loc_87823
imul r11d, esi
jmp short loc_8782A
loc_87823:
movsxd r11, r11d
mov r11d, [r9+r11*4]
loc_8782A:
movsxd rbx, ebx
mov ebx, [rcx+rbx*4-4]
movsxd r11, r11d
cmp ebx, [rcx+r11*4+4]
jnz short loc_87889
inc word ptr [rdx+2]
inc word ptr [rdx+6]
mov r11d, [rdi+98h]
bt r11d, 8
jb short loc_8785C
test r8d, r8d
jz short loc_8786A
lea ebx, [r8-1]
jmp short loc_87881
loc_8785C:
lea r11d, [r8+r8]
movsxd r11, r11d
movsx ebx, word ptr [r10+r11*2]
jmp short loc_87881
loc_8786A:
and r11d, 1
movsx ebp, word ptr [rdi+2]
dec ebp
neg r11w
mov ebx, 0
sbb ebx, ebx
or ebx, ebp
loc_87881:
dec eax
jnz loc_877C2
loc_87889:
movsx eax, word ptr [rdx+6]
loc_8788D:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_8789C:
lea rdi, aVtxsubNumfaces; "vtxSub._numFacesBefore == 0"
lea rsi, aWorkspaceLlm4b_33; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aIntOpensubdivV_21; "int OpenSubdiv::v3_6_0::Bfr::FaceVertex"...
mov edx, 147h
call ___assert_fail
| long long OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(
long long a1,
__int16 *a2,
long long a3,
long long a4)
{
__int16 v4; // r10
long long result; // rax
int v6; // r8d
long long v7; // r14
__int16 v8; // r11
int v9; // r11d
int v10; // ebx
long long v11; // r14
long long v12; // r15
int v13; // ebp
int v14; // r13d
int v15; // r12d
int v16; // r11d
int v17; // r9d
int v18; // r11d
int v19; // r11d
int v20; // r9d
__int16 v21; // r11
int v22; // r12d
int v23; // eax
int v24; // r12d
int v25; // eax
int v26; // eax
int v27; // esi
int v28; // ebx
int v29; // esi
long long v30; // r9
long long v31; // r10
int v32; // r11d
int v33; // ebx
int v34; // ebp
int v35; // ebx
int v36; // ebx
int v37; // r11d
int v38; // r11d
long long v39; // [rsp+0h] [rbp-38h]
v4 = *a2;
*(_DWORD *)(a3 + 2) = 0;
*(_WORD *)(a3 + 6) = 1;
*(_DWORD *)(a3 + 8) = 0;
*(_WORD *)a3 = v4 | 1;
result = 1LL;
if ( a2[3] != 1 )
{
v6 = *(__int16 *)(a1 + 154);
v7 = *(__int16 *)(a1 + 154);
result = (unsigned int)a2[2];
if ( !a2[2] )
goto LABEL_45;
v8 = *(_WORD *)(a1 + 152);
if ( (v8 & 0x100) != 0 )
v9 = *(__int16 *)(*(_QWORD *)(a1 + 168) + 4 * v7 + 2);
else
v9 = *(__int16 *)(a1 + 2) - 1 <= v6 ? -(v8 & 1) : v6 + 1;
v39 = *(__int16 *)(a1 + 154);
if ( a2[2] <= 0 )
{
v15 = *(__int16 *)(a1 + 154);
}
else
{
v10 = *(__int16 *)(a1 + 156);
v11 = *(_QWORD *)(a1 + 96);
v12 = *(_QWORD *)(a1 + 168);
v13 = *(__int16 *)(a1 + 2) - 1;
v14 = *(__int16 *)(a1 + 154);
while ( 1 )
{
v15 = v14;
v14 = v9;
v16 = (_WORD)v10 ? v10 * v15 : *(_DWORD *)(v11 + 4LL * v15);
v17 = (_WORD)v10 ? v10 * v14 : *(_DWORD *)(v11 + 4LL * v14);
if ( *(_DWORD *)(a4 + 4LL * v16) != *(_DWORD *)(a4 + 4LL * v17) )
break;
v18 = v15 + 1;
v19 = (_WORD)v10 ? v10 * v18 : *(_DWORD *)(v11 + 4LL * v18);
v20 = (_WORD)v10 ? v10 * v14 : *(_DWORD *)(v11 + 4LL * v14);
if ( *(_DWORD *)(a4 + 4LL * v19 - 4) != *(_DWORD *)(a4 + 4LL * v20 + 4) )
break;
++*(_WORD *)(a3 + 4);
++*(_WORD *)(a3 + 6);
v21 = *(_WORD *)(a1 + 152);
if ( (v21 & 0x100) != 0 )
{
v9 = *(__int16 *)(v12 + 2LL * (2 * v14 + 1));
}
else if ( v13 <= v14 )
{
v9 = -(v21 & 1);
}
else
{
v9 = v14 + 1;
}
v15 = v14;
result = (unsigned int)(result - 1);
if ( !(_DWORD)result )
goto LABEL_33;
}
v9 = v14;
}
LABEL_33:
v7 = v39;
if ( v9 == v6 )
{
if ( a2[1] )
__assert_fail(
"vtxSub._numFacesBefore == 0",
"/workspace/llm4binary/github/2025_star3/NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceVertex.cpp",
327LL,
"int OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(const Subset &, Subset *, const Index *) const");
v22 = v15 + 1;
v23 = *(__int16 *)(a1 + 156);
if ( *(_WORD *)(a1 + 156) )
v24 = v23 * v22;
else
v24 = *(_DWORD *)(*(_QWORD *)(a1 + 96) + 4LL * v22);
if ( (_WORD)v23 )
v25 = v6 * v23;
else
v25 = *(_DWORD *)(*(_QWORD *)(a1 + 96) + 4 * v39);
if ( *(_DWORD *)(a4 + 4LL * v24 - 4) == *(_DWORD *)(a4 + 4LL * v25 + 4) )
*(_WORD *)a3 = v4 & 0xFFFE;
result = (unsigned int)*(__int16 *)(a3 + 6);
}
if ( v9 != v6 )
{
LABEL_45:
v26 = a2[1];
if ( (*(_BYTE *)a2 & 1) == 0 )
v26 = v26 + a2[2] - *(__int16 *)(a3 + 4);
if ( v26 )
{
v27 = *(_DWORD *)(a1 + 152);
if ( (v27 & 0x100) != 0 )
v28 = *(__int16 *)(*(_QWORD *)(a1 + 168) + 4 * v7);
else
v28 = (_WORD)v6 ? v6 - 1 : (v27 & 1) != 0 ? -1 : *(__int16 *)(a1 + 2) - 1;
if ( v26 > 0 )
{
v29 = *(__int16 *)(a1 + 156);
v30 = *(_QWORD *)(a1 + 96);
v31 = *(_QWORD *)(a1 + 168);
do
{
v32 = v6;
v6 = v28;
if ( (_WORD)v29 )
v33 = v29 * v28;
else
v33 = *(_DWORD *)(v30 + 4LL * v28);
if ( (_WORD)v29 )
v34 = v29 * v32;
else
v34 = *(_DWORD *)(v30 + 4LL * v32);
if ( *(_DWORD *)(a4 + 4LL * v33) != *(_DWORD *)(a4 + 4LL * v34) )
break;
v35 = v6 + 1;
v36 = (_WORD)v29 ? v29 * v35 : *(_DWORD *)(v30 + 4LL * v35);
v37 = (_WORD)v29 ? v29 * v32 : *(_DWORD *)(v30 + 4LL * v32);
if ( *(_DWORD *)(a4 + 4LL * v36 - 4) != *(_DWORD *)(a4 + 4LL * v37 + 4) )
break;
++*(_WORD *)(a3 + 2);
++*(_WORD *)(a3 + 6);
v38 = *(_DWORD *)(a1 + 152);
if ( (v38 & 0x100) != 0 )
v28 = *(__int16 *)(v31 + 4LL * v6);
else
v28 = v6 ? v6 - 1 : (v38 & 1) != 0 ? -1 : *(__int16 *)(a1 + 2) - 1;
--v26;
}
while ( v26 );
}
}
return (unsigned int)*(__int16 *)(a3 + 6);
}
}
return result;
}
| findFVarSubsetExtent:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOVZX R10D,word ptr [RSI]
XOR EAX,EAX
MOV dword ptr [RDX + 0x2],EAX
MOV word ptr [RDX + 0x6],0x1
MOV dword ptr [RDX + 0x8],EAX
MOV EAX,R10D
OR EAX,0x1
MOV word ptr [RDX],AX
MOV EAX,0x1
CMP word ptr [RSI + 0x6],0x1
JZ 0x0018788d
MOVSX R8D,word ptr [RDI + 0x9a]
MOVSXD R14,R8D
MOVSX EAX,word ptr [RSI + 0x4]
TEST EAX,EAX
JZ 0x0018774c
MOVSX R11D,word ptr [RDI + 0x98]
BT R11D,0x8
JC 0x001875d1
MOVSX R9D,word ptr [RDI + 0x2]
DEC R9D
CMP R9D,R8D
JLE 0x001875e0
LEA R11D,[R8 + 0x1]
JMP 0x001875e7
LAB_001875d1:
MOV R9,qword ptr [RDI + 0xa8]
MOVSX R11D,word ptr [R9 + R14*0x4 + 0x2]
JMP 0x001875e7
LAB_001875e0:
AND R11D,0x1
NEG R11D
LAB_001875e7:
MOV qword ptr [RSP],R14
TEST AX,AX
JLE 0x001876de
MOVSX EBX,word ptr [RDI + 0x9c]
MOV R14,qword ptr [RDI + 0x60]
MOV R15,qword ptr [RDI + 0xa8]
MOVSX EBP,word ptr [RDI + 0x2]
DEC EBP
MOV R13D,R8D
LAB_0018760f:
MOV R12D,R13D
MOV R13D,R11D
TEST BX,BX
JZ 0x00187623
MOV R11D,R12D
IMUL R11D,EBX
JMP 0x0018762a
LAB_00187623:
MOVSXD R9,R12D
MOV R11D,dword ptr [R14 + R9*0x4]
LAB_0018762a:
TEST BX,BX
JZ 0x00187638
MOV R9D,R13D
IMUL R9D,EBX
JMP 0x0018763f
LAB_00187638:
MOVSXD R9,R13D
MOV R9D,dword ptr [R14 + R9*0x4]
LAB_0018763f:
MOVSXD R11,R11D
MOV R11D,dword ptr [RCX + R11*0x4]
MOVSXD R9,R9D
CMP R11D,dword ptr [RCX + R9*0x4]
JNZ 0x001876d9
LEA R11D,[R12 + 0x1]
TEST BX,BX
JZ 0x00187663
IMUL R11D,EBX
JMP 0x0018766a
LAB_00187663:
MOVSXD R9,R11D
MOV R11D,dword ptr [R14 + R9*0x4]
LAB_0018766a:
TEST BX,BX
JZ 0x00187678
MOV R9D,R13D
IMUL R9D,EBX
JMP 0x0018767f
LAB_00187678:
MOVSXD R9,R13D
MOV R9D,dword ptr [R14 + R9*0x4]
LAB_0018767f:
MOVSXD R11,R11D
MOV R11D,dword ptr [RCX + R11*0x4 + -0x4]
MOVSXD R9,R9D
CMP R11D,dword ptr [RCX + R9*0x4 + 0x4]
JNZ 0x001876d9
INC word ptr [RDX + 0x4]
INC word ptr [RDX + 0x6]
MOVSX R11D,word ptr [RDI + 0x98]
BT R11D,0x8
JC 0x001876b3
CMP EBP,R13D
JLE 0x001876c5
LEA R11D,[R13 + 0x1]
JMP 0x001876cc
LAB_001876b3:
LEA R9D,[0x1 + R13*0x2]
MOVSXD R9,R9D
MOVSX R11D,word ptr [R15 + R9*0x2]
JMP 0x001876cc
LAB_001876c5:
AND R11D,0x1
NEG R11D
LAB_001876cc:
MOV R12D,R13D
DEC EAX
JNZ 0x0018760f
JMP 0x001876e1
LAB_001876d9:
MOV R11D,R13D
JMP 0x001876e1
LAB_001876de:
MOV R12D,R8D
LAB_001876e1:
CMP R11D,R8D
MOV R14,qword ptr [RSP]
JNZ 0x00187743
CMP word ptr [RSI + 0x2],0x0
JNZ 0x0018789c
INC R12D
MOVSX EAX,word ptr [RDI + 0x9c]
TEST EAX,EAX
JZ 0x00187709
IMUL R12D,EAX
JMP 0x00187714
LAB_00187709:
MOV R9,qword ptr [RDI + 0x60]
MOVSXD RBX,R12D
MOV R12D,dword ptr [R9 + RBX*0x4]
LAB_00187714:
MOVSXD R9,R12D
MOV EBX,dword ptr [RCX + R9*0x4 + -0x4]
TEST AX,AX
JZ 0x00187727
IMUL EAX,R8D
JMP 0x0018772f
LAB_00187727:
MOV RAX,qword ptr [RDI + 0x60]
MOV EAX,dword ptr [RAX + R14*0x4]
LAB_0018772f:
CDQE
CMP EBX,dword ptr [RCX + RAX*0x4 + 0x4]
JNZ 0x0018773f
AND R10D,0xfffffffe
MOV word ptr [RDX],R10W
LAB_0018773f:
MOVSX EAX,word ptr [RDX + 0x6]
LAB_00187743:
CMP R11D,R8D
JZ 0x0018788d
LAB_0018774c:
MOVSX EAX,word ptr [RSI + 0x2]
TEST byte ptr [RSI],0x1
JNZ 0x00187765
MOVSX ESI,word ptr [RSI + 0x4]
MOVSX R9D,word ptr [RDX + 0x4]
ADD ESI,EAX
SUB ESI,R9D
MOV EAX,ESI
LAB_00187765:
TEST EAX,EAX
JZ 0x00187889
MOV ESI,dword ptr [RDI + 0x98]
BT ESI,0x8
JC 0x00187785
TEST R8W,R8W
JZ 0x00187793
LEA EBX,[R8 + -0x1]
JMP 0x001877a8
LAB_00187785:
MOV RSI,qword ptr [RDI + 0xa8]
MOVSX EBX,word ptr [RSI + R14*0x4]
JMP 0x001877a8
LAB_00187793:
AND ESI,0x1
MOVSX R9D,word ptr [RDI + 0x2]
DEC R9D
XOR EBX,EBX
NEG SI
SBB EBX,EBX
OR EBX,R9D
LAB_001877a8:
TEST EAX,EAX
JLE 0x00187889
MOVSX ESI,word ptr [RDI + 0x9c]
MOV R9,qword ptr [RDI + 0x60]
MOV R10,qword ptr [RDI + 0xa8]
LAB_001877c2:
MOV R11D,R8D
MOV R8D,EBX
TEST SI,SI
JZ 0x001877d5
MOV EBX,R8D
IMUL EBX,ESI
JMP 0x001877dc
LAB_001877d5:
MOVSXD RBX,R8D
MOV EBX,dword ptr [R9 + RBX*0x4]
LAB_001877dc:
TEST SI,SI
JZ 0x001877e9
MOV EBP,R11D
IMUL EBP,ESI
JMP 0x001877f0
LAB_001877e9:
MOVSXD R14,R11D
MOV EBP,dword ptr [R9 + R14*0x4]
LAB_001877f0:
MOVSXD RBX,EBX
MOV EBX,dword ptr [RCX + RBX*0x4]
MOVSXD R14,EBP
CMP EBX,dword ptr [RCX + R14*0x4]
JNZ 0x00187889
LEA EBX,[R8 + 0x1]
TEST SI,SI
JZ 0x00187811
IMUL EBX,ESI
JMP 0x00187818
LAB_00187811:
MOVSXD RBX,EBX
MOV EBX,dword ptr [R9 + RBX*0x4]
LAB_00187818:
TEST SI,SI
JZ 0x00187823
IMUL R11D,ESI
JMP 0x0018782a
LAB_00187823:
MOVSXD R11,R11D
MOV R11D,dword ptr [R9 + R11*0x4]
LAB_0018782a:
MOVSXD RBX,EBX
MOV EBX,dword ptr [RCX + RBX*0x4 + -0x4]
MOVSXD R11,R11D
CMP EBX,dword ptr [RCX + R11*0x4 + 0x4]
JNZ 0x00187889
INC word ptr [RDX + 0x2]
INC word ptr [RDX + 0x6]
MOV R11D,dword ptr [RDI + 0x98]
BT R11D,0x8
JC 0x0018785c
TEST R8D,R8D
JZ 0x0018786a
LEA EBX,[R8 + -0x1]
JMP 0x00187881
LAB_0018785c:
LEA R11D,[R8 + R8*0x1]
MOVSXD R11,R11D
MOVSX EBX,word ptr [R10 + R11*0x2]
JMP 0x00187881
LAB_0018786a:
AND R11D,0x1
MOVSX EBP,word ptr [RDI + 0x2]
DEC EBP
NEG R11W
MOV EBX,0x0
SBB EBX,EBX
OR EBX,EBP
LAB_00187881:
DEC EAX
JNZ 0x001877c2
LAB_00187889:
MOVSX EAX,word ptr [RDX + 0x6]
LAB_0018788d:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0018789c:
LEA RDI,[0x1be3e3]
LEA RSI,[0x1be2f1]
LEA RCX,[0x1be3ff]
MOV EDX,0x147
CALL 0x00139560
|
/* OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset
const&, OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset*, int const*) const */
int __thiscall
OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent
(FaceVertex *this,FaceVertexSubset *param_1,FaceVertexSubset *param_2,int *param_3)
{
ushort uVar1;
short sVar2;
short sVar3;
short sVar4;
long lVar5;
long lVar6;
int iVar7;
int iVar8;
uint uVar9;
uint uVar10;
uint uVar11;
int iVar12;
uint uVar13;
int iVar14;
long lVar15;
uVar1 = *(ushort *)param_1;
*(int4 *)(param_2 + 2) = 0;
*(int2 *)(param_2 + 6) = 1;
*(int4 *)(param_2 + 8) = 0;
*(ushort *)param_2 = uVar1 | 1;
iVar7 = 1;
if (*(short *)(param_1 + 6) != 1) {
sVar2 = *(short *)(this + 0x9a);
uVar11 = (uint)sVar2;
lVar15 = (long)(int)uVar11;
iVar7 = (int)*(short *)(param_1 + 4);
if (iVar7 != 0) {
if (((uint)(int)*(short *)(this + 0x98) >> 8 & 1) == 0) {
if ((int)uVar11 < *(short *)(this + 2) + -1) {
uVar9 = uVar11 + 1;
}
else {
uVar9 = -((int)*(short *)(this + 0x98) & 1U);
}
}
else {
uVar9 = (uint)*(short *)(*(long *)(this + 0xa8) + 2 + lVar15 * 4);
}
uVar10 = uVar11;
if (0 < *(short *)(param_1 + 4)) {
sVar3 = *(short *)(this + 0x9c);
iVar8 = (int)sVar3;
lVar5 = *(long *)(this + 0x60);
lVar6 = *(long *)(this + 0xa8);
sVar4 = *(short *)(this + 2);
uVar13 = uVar9;
do {
if (sVar3 == 0) {
iVar14 = *(int *)(lVar5 + (long)(int)uVar10 * 4);
iVar12 = *(int *)(lVar5 + (long)(int)uVar13 * 4);
}
else {
iVar14 = uVar10 * iVar8;
iVar12 = uVar13 * iVar8;
}
uVar9 = uVar13;
if (param_3[iVar14] != param_3[iVar12]) break;
if (sVar3 == 0) {
iVar14 = *(int *)(lVar5 + (long)(int)(uVar10 + 1) * 4);
iVar12 = *(int *)(lVar5 + (long)(int)uVar13 * 4);
}
else {
iVar14 = (uVar10 + 1) * iVar8;
iVar12 = uVar13 * iVar8;
}
if (param_3[(long)iVar14 + -1] != param_3[(long)iVar12 + 1]) break;
*(short *)(param_2 + 4) = *(short *)(param_2 + 4) + 1;
*(short *)(param_2 + 6) = *(short *)(param_2 + 6) + 1;
if (((uint)(int)*(short *)(this + 0x98) >> 8 & 1) == 0) {
if ((int)uVar13 < sVar4 + -1) {
uVar9 = uVar13 + 1;
}
else {
uVar9 = -((int)*(short *)(this + 0x98) & 1U);
}
}
else {
uVar9 = (uint)*(short *)(lVar6 + (long)(int)(uVar13 * 2 + 1) * 2);
}
iVar7 = iVar7 + -1;
uVar10 = uVar13;
uVar13 = uVar9;
} while (iVar7 != 0);
}
if (uVar9 == uVar11) {
if (*(short *)(param_1 + 2) != 0) {
/* WARNING: Subroutine does not return */
__assert_fail("vtxSub._numFacesBefore == 0",
"/workspace/llm4binary/github/2025_star3/NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceVertex.cpp"
,0x147,
"int OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(const Subset &, Subset *, const Index *) const"
);
}
sVar3 = *(short *)(this + 0x9c);
if (sVar3 == 0) {
iVar7 = *(int *)(*(long *)(this + 0x60) + (long)(int)(uVar10 + 1) * 4);
}
else {
iVar7 = (uVar10 + 1) * (int)sVar3;
}
if (sVar3 == 0) {
iVar8 = *(int *)(*(long *)(this + 0x60) + lVar15 * 4);
}
else {
iVar8 = (int)sVar3 * uVar11;
}
if (param_3[(long)iVar7 + -1] == param_3[(long)iVar8 + 1]) {
*(ushort *)param_2 = uVar1 & 0xfffe;
}
iVar7 = (int)*(short *)(param_2 + 6);
}
if (uVar9 == uVar11) {
return iVar7;
}
}
iVar7 = (int)*(short *)(param_1 + 2);
if (((byte)*param_1 & 1) == 0) {
iVar7 = (*(short *)(param_1 + 4) + iVar7) - (int)*(short *)(param_2 + 4);
}
if (iVar7 != 0) {
if ((*(uint *)(this + 0x98) >> 8 & 1) == 0) {
if (sVar2 == 0) {
uVar9 = -(uint)((*(uint *)(this + 0x98) & 1) != 0) | (int)*(short *)(this + 2) - 1U;
}
else {
uVar9 = uVar11 - 1;
}
}
else {
uVar9 = (uint)*(short *)(*(long *)(this + 0xa8) + lVar15 * 4);
}
if (0 < iVar7) {
sVar2 = *(short *)(this + 0x9c);
iVar8 = (int)sVar2;
lVar15 = *(long *)(this + 0x60);
lVar5 = *(long *)(this + 0xa8);
do {
if (sVar2 == 0) {
iVar14 = *(int *)(lVar15 + (long)(int)uVar9 * 4);
iVar12 = *(int *)(lVar15 + (long)(int)uVar11 * 4);
}
else {
iVar14 = uVar9 * iVar8;
iVar12 = uVar11 * iVar8;
}
if (param_3[iVar14] != param_3[iVar12]) break;
if (sVar2 == 0) {
iVar14 = *(int *)(lVar15 + (long)(int)(uVar9 + 1) * 4);
iVar12 = *(int *)(lVar15 + (long)(int)uVar11 * 4);
}
else {
iVar14 = (uVar9 + 1) * iVar8;
iVar12 = uVar11 * iVar8;
}
if (param_3[(long)iVar14 + -1] != param_3[(long)iVar12 + 1]) break;
*(short *)(param_2 + 2) = *(short *)(param_2 + 2) + 1;
*(short *)(param_2 + 6) = *(short *)(param_2 + 6) + 1;
if ((*(uint *)(this + 0x98) >> 8 & 1) == 0) {
if (uVar9 == 0) {
uVar10 = -(uint)((*(uint *)(this + 0x98) & 1) != 0) | (int)*(short *)(this + 2) - 1U;
}
else {
uVar10 = uVar9 - 1;
}
}
else {
uVar10 = (uint)*(short *)(lVar5 + (long)(int)(uVar9 * 2) * 2);
}
iVar7 = iVar7 + -1;
uVar11 = uVar9;
uVar9 = uVar10;
} while (iVar7 != 0);
}
}
iVar7 = (int)*(short *)(param_2 + 6);
}
return iVar7;
}
| |
55,535 | OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset const&, OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset*, int const*) const | NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceVertex.cpp | int
FaceVertex::findFVarSubsetExtent(Subset const & vtxSub,
Subset * fvarSubsetPtr,
Index const fvarIndices[]) const {
Subset & fvarSub = *fvarSubsetPtr;
//
// Initialize with tags and declare as a boundary to start:
//
fvarSub.Initialize(vtxSub._tag);
fvarSub.SetBoundary(true);
if (vtxSub._numFacesTotal == 1) return 1;
//
// Inspect/gather faces "after" (counter-clockwise order from) the
// corner face. If we arrive back at the corner face, a periodic
// set is complete, but check the continuity of the seam and apply
// before returning:
//
int cornerFace = _faceInRing;
int numFacesAfterToVisit = vtxSub._numFacesAfter;
if (numFacesAfterToVisit) {
int thisFace = cornerFace;
int nextFace = GetFaceNext(thisFace);
for (int i = 0; i < numFacesAfterToVisit; ++i) {
if (!FaceIndicesMatchAcrossEdge(thisFace, nextFace, fvarIndices)) {
break;
}
++ fvarSub._numFacesAfter;
++ fvarSub._numFacesTotal;
thisFace = nextFace;
nextFace = GetFaceNext(thisFace);
}
if (nextFace == cornerFace) {
assert(vtxSub._numFacesBefore == 0);
if (FaceIndicesMatchAtEdgeEnd(thisFace, cornerFace, fvarIndices)) {
fvarSub.SetBoundary(false);
}
return fvarSub._numFacesTotal;
}
}
//
// Inspect/gather faces "before" (clockwise order from) the corner
// face. Include any faces "after" in the case of a periodic vertex
// that was interrupted by a discontinuity above:
//
int numFacesBeforeToVisit = vtxSub._numFacesBefore;
if (!vtxSub.IsBoundary()) {
numFacesBeforeToVisit += vtxSub._numFacesAfter - fvarSub._numFacesAfter;
}
if (numFacesBeforeToVisit) {
int thisFace = cornerFace;
int prevFace = GetFacePrevious(thisFace);
for (int i = 0; i < numFacesBeforeToVisit; ++i) {
if (!FaceIndicesMatchAcrossEdge(prevFace, thisFace, fvarIndices)) {
break;
}
++ fvarSub._numFacesBefore;
++ fvarSub._numFacesTotal;
thisFace = prevFace;
prevFace = GetFacePrevious(thisFace);
}
}
return fvarSub._numFacesTotal;
} | O3 | cpp | OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset const&, OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset*, int const*) const:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movzwl (%rsi), %r9d
xorl %eax, %eax
movl %eax, 0x2(%rdx)
movw $0x1, 0x6(%rdx)
movl %eax, 0x8(%rdx)
movl %r9d, %eax
orl $0x1, %eax
movw %ax, (%rdx)
movl $0x1, %eax
cmpw $0x1, 0x6(%rsi)
je 0x8a087
movswl 0x9a(%rdi), %eax
movslq %eax, %rbx
movswl 0x4(%rsi), %r11d
testl %r11d, %r11d
je 0x89da5
movswl 0x98(%rdi), %r10d
btl $0x8, %r10d
jb 0x89db2
movswl 0x2(%rdi), %r8d
decl %r8d
cmpl %eax, %r8d
jle 0x89dc1
leal 0x1(%rax), %r10d
jmp 0x89dc8
xorl %r13d, %r13d
movw $0x1, %r12w
jmp 0x89f17
movq 0xa8(%rdi), %r8
movswl 0x2(%r8,%rbx,4), %r10d
jmp 0x89dc8
andl $0x1, %r10d
negl %r10d
xorl %r8d, %r8d
testw %r11w, %r11w
movl %r9d, 0x8(%rsp)
jle 0x89ed8
movq %rbx, (%rsp)
movswl 0x9c(%rdi), %ebp
movq 0x60(%rdi), %r15
movq 0xa8(%rdi), %r9
movq %r9, 0x10(%rsp)
movswl 0x2(%rdi), %r9d
decl %r9d
movl %r9d, 0xc(%rsp)
movw $0x1, %r12w
movl %eax, %ebx
movl %ebx, %r14d
movl %r10d, %ebx
movl %r8d, %r13d
testw %bp, %bp
je 0x89e43
movl %r14d, %r8d
imull %ebp, %r8d
movl %ebx, %r9d
imull %ebp, %r9d
movslq %r8d, %r8
movl (%rcx,%r8,4), %r10d
movslq %r9d, %r8
cmpl (%rcx,%r8,4), %r10d
jne 0x89ee9
leal 0x1(%r14), %r10d
imull %ebp, %r10d
jmp 0x89e64
movslq %r14d, %r10
movslq (%r15,%r10,4), %r9
movslq %ebx, %r8
movslq (%r15,%r8,4), %r8
movl (%rcx,%r9,4), %r9d
cmpl (%rcx,%r8,4), %r9d
jne 0x89ee9
movl 0x4(%r15,%r10,4), %r10d
movslq %r10d, %r9
movl -0x4(%rcx,%r9,4), %r9d
cmpl 0x4(%rcx,%r8,4), %r9d
jne 0x89ee5
leal 0x1(%r13), %r8d
movw %r8w, 0x4(%rdx)
addl $0x2, %r13d
movw %r13w, 0x6(%rdx)
movswl 0x98(%rdi), %r10d
btl $0x8, %r10d
jb 0x89ea0
cmpl %ebx, 0xc(%rsp)
jle 0x89eb7
leal 0x1(%rbx), %r10d
jmp 0x89ebe
leal 0x1(,%rbx,2), %r9d
movslq %r9d, %r9
movq 0x10(%rsp), %r10
movswl (%r10,%r9,2), %r10d
jmp 0x89ebe
andl $0x1, %r10d
negl %r10d
incl %r12d
cmpl %r8d, %r11d
jne 0x89e09
movl %r8d, %r12d
incl %r12d
movl %r8d, %r13d
movl %ebx, %r14d
jmp 0x89eec
movw $0x1, %r12w
xorl %r13d, %r13d
movl %eax, %r14d
jmp 0x89ef0
leal 0x1(%r13), %r12d
movl %ebx, %r10d
movq (%rsp), %rbx
cmpl %eax, %r10d
jne 0x89f17
cmpw $0x0, 0x2(%rsi)
jne 0x8a096
incl %r14d
movswl 0x9c(%rdi), %esi
testl %esi, %esi
je 0x89f60
imull %esi, %r14d
imull %esi, %eax
jmp 0x89f6e
movswl 0x2(%rsi), %r8d
movswl 0x4(%rsi), %r9d
movswl %r13w, %r10d
addl %r8d, %r9d
subl %r10d, %r9d
testb $0x1, (%rsi)
cmovnel %r8d, %r9d
testl %r9d, %r9d
je 0x8a083
movl 0x98(%rdi), %esi
btl $0x8, %esi
jb 0x89f52
testw %ax, %ax
je 0x89f90
leal -0x1(%rax), %r8d
jmp 0x89fa7
movq 0xa8(%rdi), %rsi
movswl (%rsi,%rbx,4), %r8d
jmp 0x89fa7
movq 0x60(%rdi), %rax
movslq %r14d, %rsi
movl (%rax,%rsi,4), %r14d
movl (%rax,%rbx,4), %eax
movslq %r14d, %rsi
movl -0x4(%rcx,%rsi,4), %esi
cltq
cmpl 0x4(%rcx,%rax,4), %esi
jne 0x8a083
movl 0x8(%rsp), %eax
andl $-0x2, %eax
movw %ax, (%rdx)
jmp 0x8a083
andl $0x1, %esi
movswl 0x2(%rdi), %r10d
decl %r10d
xorl %r8d, %r8d
negw %si
sbbl %r8d, %r8d
orl %r10d, %r8d
testl %r9d, %r9d
jle 0x8a083
movswl 0x9c(%rdi), %esi
movq 0x60(%rdi), %r10
movq 0xa8(%rdi), %r11
negl %r9d
movl $0x1, %ebx
movl %eax, %ebp
movl %r8d, %eax
testw %si, %si
je 0x89ffa
movl %eax, %r8d
imull %esi, %r8d
imull %esi, %ebp
movslq %r8d, %r8
movl (%rcx,%r8,4), %r14d
movslq %ebp, %r8
cmpl (%rcx,%r8,4), %r14d
jne 0x8a083
leal 0x1(%rax), %ebp
imull %esi, %ebp
jmp 0x8a017
movslq %eax, %r14
movslq (%r10,%r14,4), %r15
movslq %ebp, %r8
movslq (%r10,%r8,4), %r8
movl (%rcx,%r15,4), %ebp
cmpl (%rcx,%r8,4), %ebp
jne 0x8a083
movl 0x4(%r10,%r14,4), %ebp
movslq %ebp, %r14
movl -0x4(%rcx,%r14,4), %ebp
cmpl 0x4(%rcx,%r8,4), %ebp
jne 0x8a083
movw %bx, 0x2(%rdx)
incl %r12d
movw %r12w, 0x6(%rdx)
movl 0x98(%rdi), %r8d
btl $0x8, %r8d
jb 0x8a04a
testl %eax, %eax
je 0x8a058
leal -0x1(%rax), %r8d
jmp 0x8a072
leal (%rax,%rax), %r8d
movslq %r8d, %r8
movswl (%r11,%r8,2), %r8d
jmp 0x8a072
andl $0x1, %r8d
movswl 0x2(%rdi), %ebp
decl %ebp
negw %r8w
movl $0x0, %r8d
sbbl %r8d, %r8d
orl %ebp, %r8d
leal (%r9,%rbx), %ebp
incl %ebp
incl %ebx
cmpl $0x1, %ebp
jne 0x89fca
movswl %r12w, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x37b26(%rip), %rdi # 0xc1bc3
leaq 0x37a2d(%rip), %rsi # 0xc1ad1
leaq 0x37b34(%rip), %rcx # 0xc1bdf
movl $0x147, %edx # imm = 0x147
callq 0x39540
nop
| _ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex20findFVarSubsetExtentERKNS1_16FaceVertexSubsetEPS3_PKi:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
movzx r9d, word ptr [rsi]
xor eax, eax
mov [rdx+2], eax
mov word ptr [rdx+6], 1
mov [rdx+8], eax
mov eax, r9d
or eax, 1
mov [rdx], ax
mov eax, 1
cmp word ptr [rsi+6], 1
jz loc_8A087
movsx eax, word ptr [rdi+9Ah]
movsxd rbx, eax
movsx r11d, word ptr [rsi+4]
test r11d, r11d
jz short loc_89DA5
movsx r10d, word ptr [rdi+98h]
bt r10d, 8
jb short loc_89DB2
movsx r8d, word ptr [rdi+2]
dec r8d
cmp r8d, eax
jle short loc_89DC1
lea r10d, [rax+1]
jmp short loc_89DC8
loc_89DA5:
xor r13d, r13d
mov r12w, 1
jmp loc_89F17
loc_89DB2:
mov r8, [rdi+0A8h]
movsx r10d, word ptr [r8+rbx*4+2]
jmp short loc_89DC8
loc_89DC1:
and r10d, 1
neg r10d
loc_89DC8:
xor r8d, r8d
test r11w, r11w
mov [rsp+48h+var_40], r9d
jle loc_89ED8
mov [rsp+48h+var_48], rbx
movsx ebp, word ptr [rdi+9Ch]
mov r15, [rdi+60h]
mov r9, [rdi+0A8h]
mov [rsp+48h+var_38], r9
movsx r9d, word ptr [rdi+2]
dec r9d
mov [rsp+48h+var_3C], r9d
mov r12w, 1
mov ebx, eax
loc_89E09:
mov r14d, ebx
mov ebx, r10d
mov r13d, r8d
test bp, bp
jz short loc_89E43
mov r8d, r14d
imul r8d, ebp
mov r9d, ebx
imul r9d, ebp
movsxd r8, r8d
mov r10d, [rcx+r8*4]
movsxd r8, r9d
cmp r10d, [rcx+r8*4]
jnz loc_89EE9
lea r10d, [r14+1]
imul r10d, ebp
jmp short loc_89E64
loc_89E43:
movsxd r10, r14d
movsxd r9, dword ptr [r15+r10*4]
movsxd r8, ebx
movsxd r8, dword ptr [r15+r8*4]
mov r9d, [rcx+r9*4]
cmp r9d, [rcx+r8*4]
jnz loc_89EE9
mov r10d, [r15+r10*4+4]
loc_89E64:
movsxd r9, r10d
mov r9d, [rcx+r9*4-4]
cmp r9d, [rcx+r8*4+4]
jnz short loc_89EE5
lea r8d, [r13+1]
mov [rdx+4], r8w
add r13d, 2
mov [rdx+6], r13w
movsx r10d, word ptr [rdi+98h]
bt r10d, 8
jb short loc_89EA0
cmp [rsp+48h+var_3C], ebx
jle short loc_89EB7
lea r10d, [rbx+1]
jmp short loc_89EBE
loc_89EA0:
lea r9d, ds:1[rbx*2]
movsxd r9, r9d
mov r10, [rsp+48h+var_38]
movsx r10d, word ptr [r10+r9*2]
jmp short loc_89EBE
loc_89EB7:
and r10d, 1
neg r10d
loc_89EBE:
inc r12d
cmp r11d, r8d
jnz loc_89E09
mov r12d, r8d
inc r12d
mov r13d, r8d
mov r14d, ebx
jmp short loc_89EEC
loc_89ED8:
mov r12w, 1
xor r13d, r13d
mov r14d, eax
jmp short loc_89EF0
loc_89EE5:
lea r12d, [r13+1]
loc_89EE9:
mov r10d, ebx
loc_89EEC:
mov rbx, [rsp+48h+var_48]
loc_89EF0:
cmp r10d, eax
jnz short loc_89F17
cmp word ptr [rsi+2], 0
jnz loc_8A096
inc r14d
movsx esi, word ptr [rdi+9Ch]
test esi, esi
jz short loc_89F60
imul r14d, esi
imul eax, esi
jmp short loc_89F6E
loc_89F17:
movsx r8d, word ptr [rsi+2]
movsx r9d, word ptr [rsi+4]
movsx r10d, r13w
add r9d, r8d
sub r9d, r10d
test byte ptr [rsi], 1
cmovnz r9d, r8d
test r9d, r9d
jz loc_8A083
mov esi, [rdi+98h]
bt esi, 8
jb short loc_89F52
test ax, ax
jz short loc_89F90
lea r8d, [rax-1]
jmp short loc_89FA7
loc_89F52:
mov rsi, [rdi+0A8h]
movsx r8d, word ptr [rsi+rbx*4]
jmp short loc_89FA7
loc_89F60:
mov rax, [rdi+60h]
movsxd rsi, r14d
mov r14d, [rax+rsi*4]
mov eax, [rax+rbx*4]
loc_89F6E:
movsxd rsi, r14d
mov esi, [rcx+rsi*4-4]
cdqe
cmp esi, [rcx+rax*4+4]
jnz loc_8A083
mov eax, [rsp+48h+var_40]
and eax, 0FFFFFFFEh
mov [rdx], ax
jmp loc_8A083
loc_89F90:
and esi, 1
movsx r10d, word ptr [rdi+2]
dec r10d
xor r8d, r8d
neg si
sbb r8d, r8d
or r8d, r10d
loc_89FA7:
test r9d, r9d
jle loc_8A083
movsx esi, word ptr [rdi+9Ch]
mov r10, [rdi+60h]
mov r11, [rdi+0A8h]
neg r9d
mov ebx, 1
loc_89FCA:
mov ebp, eax
mov eax, r8d
test si, si
jz short loc_89FFA
mov r8d, eax
imul r8d, esi
imul ebp, esi
movsxd r8, r8d
mov r14d, [rcx+r8*4]
movsxd r8, ebp
cmp r14d, [rcx+r8*4]
jnz loc_8A083
lea ebp, [rax+1]
imul ebp, esi
jmp short loc_8A017
loc_89FFA:
movsxd r14, eax
movsxd r15, dword ptr [r10+r14*4]
movsxd r8, ebp
movsxd r8, dword ptr [r10+r8*4]
mov ebp, [rcx+r15*4]
cmp ebp, [rcx+r8*4]
jnz short loc_8A083
mov ebp, [r10+r14*4+4]
loc_8A017:
movsxd r14, ebp
mov ebp, [rcx+r14*4-4]
cmp ebp, [rcx+r8*4+4]
jnz short loc_8A083
mov [rdx+2], bx
inc r12d
mov [rdx+6], r12w
mov r8d, [rdi+98h]
bt r8d, 8
jb short loc_8A04A
test eax, eax
jz short loc_8A058
lea r8d, [rax-1]
jmp short loc_8A072
loc_8A04A:
lea r8d, [rax+rax]
movsxd r8, r8d
movsx r8d, word ptr [r11+r8*2]
jmp short loc_8A072
loc_8A058:
and r8d, 1
movsx ebp, word ptr [rdi+2]
dec ebp
neg r8w
mov r8d, 0
sbb r8d, r8d
or r8d, ebp
loc_8A072:
lea ebp, [r9+rbx]
inc ebp
inc ebx
cmp ebp, 1
jnz loc_89FCA
loc_8A083:
movsx eax, r12w
loc_8A087:
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_8A096:
lea rdi, aVtxsubNumfaces; "vtxSub._numFacesBefore == 0"
lea rsi, aWorkspaceLlm4b_33; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aIntOpensubdivV_21; "int OpenSubdiv::v3_6_0::Bfr::FaceVertex"...
mov edx, 147h
call ___assert_fail
| long long OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(
long long a1,
__int16 *a2,
long long a3,
long long a4)
{
__int16 v4; // r9
long long result; // rax
int v6; // eax
long long v7; // rbx
int v8; // r11d
__int16 v9; // r10
int v10; // r10d
int v11; // r13d
__int16 v12; // r12
int v13; // r8d
int v14; // ebp
long long v15; // r15
int v16; // ebx
int v17; // r14d
long long v18; // r8
int v19; // r10d
__int16 v20; // r10
int v21; // r14d
int v22; // esi
int v23; // r14d
int v24; // eax
int v25; // r9d
int v26; // esi
int v27; // r8d
long long v28; // rax
int v29; // esi
long long v30; // r10
long long v31; // r11
int v32; // r9d
int v33; // ebx
int v34; // ebp
long long v35; // r8
int v36; // ebp
int v37; // r8d
int v38; // ebp
long long v39; // [rsp+0h] [rbp-48h]
int v40; // [rsp+Ch] [rbp-3Ch]
long long v41; // [rsp+10h] [rbp-38h]
v4 = *a2;
*(_DWORD *)(a3 + 2) = 0;
*(_WORD *)(a3 + 6) = 1;
*(_DWORD *)(a3 + 8) = 0;
*(_WORD *)a3 = v4 | 1;
result = 1LL;
if ( a2[3] != 1 )
{
v6 = *(__int16 *)(a1 + 154);
v7 = *(__int16 *)(a1 + 154);
v8 = a2[2];
if ( a2[2] )
{
v9 = *(_WORD *)(a1 + 152);
if ( (v9 & 0x100) != 0 )
{
v10 = *(__int16 *)(*(_QWORD *)(a1 + 168) + 4 * v7 + 2);
}
else if ( *(__int16 *)(a1 + 2) - 1 <= v6 )
{
v10 = -(v9 & 1);
}
else
{
v10 = v6 + 1;
}
v13 = 0;
if ( (__int16)v8 <= 0 )
{
v12 = 1;
LOWORD(v11) = 0;
v17 = *(__int16 *)(a1 + 154);
}
else
{
v39 = *(__int16 *)(a1 + 154);
v14 = *(__int16 *)(a1 + 156);
v15 = *(_QWORD *)(a1 + 96);
v41 = *(_QWORD *)(a1 + 168);
v40 = *(__int16 *)(a1 + 2) - 1;
v12 = 1;
v16 = *(__int16 *)(a1 + 154);
while ( 1 )
{
v17 = v16;
v16 = v10;
v11 = v13;
if ( (_WORD)v14 )
{
v18 = v14 * v10;
if ( *(_DWORD *)(a4 + 4LL * v14 * v17) != *(_DWORD *)(a4 + 4 * v18) )
goto LABEL_26;
v19 = v14 * (v17 + 1);
}
else
{
v18 = *(int *)(v15 + 4LL * v10);
if ( *(_DWORD *)(a4 + 4LL * *(int *)(v15 + 4LL * v17)) != *(_DWORD *)(a4 + 4 * v18) )
goto LABEL_26;
v19 = *(_DWORD *)(v15 + 4LL * v17 + 4);
}
if ( *(_DWORD *)(a4 + 4LL * v19 - 4) != *(_DWORD *)(a4 + 4 * v18 + 4) )
break;
v13 = v11 + 1;
*(_WORD *)(a3 + 4) = v11 + 1;
*(_WORD *)(a3 + 6) = v11 + 2;
v20 = *(_WORD *)(a1 + 152);
if ( (v20 & 0x100) != 0 )
{
v10 = *(__int16 *)(v41 + 2LL * (2 * v16 + 1));
}
else if ( v40 <= v16 )
{
v10 = -(v20 & 1);
}
else
{
v10 = v16 + 1;
}
++v12;
if ( v8 == v13 )
{
v12 = v11 + 2;
LOWORD(v11) = v11 + 1;
v17 = v16;
goto LABEL_27;
}
}
v12 = v11 + 1;
LABEL_26:
v10 = v16;
LABEL_27:
v7 = v39;
}
if ( v10 == v6 )
{
if ( a2[1] )
__assert_fail(
"vtxSub._numFacesBefore == 0",
"/workspace/llm4binary/github/2025_star3/NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceVertex.cpp",
327LL,
"int OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(const Subset &, Subset *, const Index *) const");
v21 = v17 + 1;
v22 = *(__int16 *)(a1 + 156);
if ( *(_WORD *)(a1 + 156) )
{
v23 = v22 * v21;
v24 = v22 * v6;
}
else
{
v28 = *(_QWORD *)(a1 + 96);
v23 = *(_DWORD *)(v28 + 4LL * v21);
v24 = *(_DWORD *)(v28 + 4 * v7);
}
if ( *(_DWORD *)(a4 + 4LL * v23 - 4) == *(_DWORD *)(a4 + 4LL * v24 + 4) )
*(_WORD *)a3 = v4 & 0xFFFE;
return (unsigned int)v12;
}
}
else
{
LOWORD(v11) = 0;
v12 = 1;
}
v25 = a2[1] + a2[2] - (__int16)v11;
if ( (*(_BYTE *)a2 & 1) != 0 )
v25 = a2[1];
if ( v25 )
{
v26 = *(_DWORD *)(a1 + 152);
if ( (v26 & 0x100) != 0 )
v27 = *(__int16 *)(*(_QWORD *)(a1 + 168) + 4 * v7);
else
v27 = (_WORD)v6 ? v6 - 1 : (v26 & 1) != 0 ? -1 : *(__int16 *)(a1 + 2) - 1;
if ( v25 > 0 )
{
v29 = *(__int16 *)(a1 + 156);
v30 = *(_QWORD *)(a1 + 96);
v31 = *(_QWORD *)(a1 + 168);
v32 = -v25;
v33 = 1;
do
{
v34 = v6;
v6 = v27;
if ( (_WORD)v29 )
{
v35 = v29 * v34;
if ( *(_DWORD *)(a4 + 4LL * v29 * v6) != *(_DWORD *)(a4 + 4 * v35) )
return (unsigned int)v12;
v36 = v29 * (v6 + 1);
}
else
{
v35 = *(int *)(v30 + 4LL * v34);
if ( *(_DWORD *)(a4 + 4LL * *(int *)(v30 + 4LL * v6)) != *(_DWORD *)(a4 + 4 * v35) )
return (unsigned int)v12;
v36 = *(_DWORD *)(v30 + 4LL * v6 + 4);
}
if ( *(_DWORD *)(a4 + 4LL * v36 - 4) != *(_DWORD *)(a4 + 4 * v35 + 4) )
break;
*(_WORD *)(a3 + 2) = v33;
*(_WORD *)(a3 + 6) = ++v12;
v37 = *(_DWORD *)(a1 + 152);
if ( (v37 & 0x100) != 0 )
v27 = *(__int16 *)(v31 + 4LL * v6);
else
v27 = v6 ? v6 - 1 : (v37 & 1) != 0 ? -1 : *(__int16 *)(a1 + 2) - 1;
v38 = v32 + v33++ + 1;
}
while ( v38 != 1 );
}
}
return (unsigned int)v12;
}
return result;
}
| findFVarSubsetExtent:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOVZX R9D,word ptr [RSI]
XOR EAX,EAX
MOV dword ptr [RDX + 0x2],EAX
MOV word ptr [RDX + 0x6],0x1
MOV dword ptr [RDX + 0x8],EAX
MOV EAX,R9D
OR EAX,0x1
MOV word ptr [RDX],AX
MOV EAX,0x1
CMP word ptr [RSI + 0x6],0x1
JZ 0x0018a087
MOVSX EAX,word ptr [RDI + 0x9a]
MOVSXD RBX,EAX
MOVSX R11D,word ptr [RSI + 0x4]
TEST R11D,R11D
JZ 0x00189da5
MOVSX R10D,word ptr [RDI + 0x98]
BT R10D,0x8
JC 0x00189db2
MOVSX R8D,word ptr [RDI + 0x2]
DEC R8D
CMP R8D,EAX
JLE 0x00189dc1
LEA R10D,[RAX + 0x1]
JMP 0x00189dc8
LAB_00189da5:
XOR R13D,R13D
MOV R12W,0x1
JMP 0x00189f17
LAB_00189db2:
MOV R8,qword ptr [RDI + 0xa8]
MOVSX R10D,word ptr [R8 + RBX*0x4 + 0x2]
JMP 0x00189dc8
LAB_00189dc1:
AND R10D,0x1
NEG R10D
LAB_00189dc8:
XOR R8D,R8D
TEST R11W,R11W
MOV dword ptr [RSP + 0x8],R9D
JLE 0x00189ed8
MOV qword ptr [RSP],RBX
MOVSX EBP,word ptr [RDI + 0x9c]
MOV R15,qword ptr [RDI + 0x60]
MOV R9,qword ptr [RDI + 0xa8]
MOV qword ptr [RSP + 0x10],R9
MOVSX R9D,word ptr [RDI + 0x2]
DEC R9D
MOV dword ptr [RSP + 0xc],R9D
MOV R12W,0x1
MOV EBX,EAX
LAB_00189e09:
MOV R14D,EBX
MOV EBX,R10D
MOV R13D,R8D
TEST BP,BP
JZ 0x00189e43
MOV R8D,R14D
IMUL R8D,EBP
MOV R9D,EBX
IMUL R9D,EBP
MOVSXD R8,R8D
MOV R10D,dword ptr [RCX + R8*0x4]
MOVSXD R8,R9D
CMP R10D,dword ptr [RCX + R8*0x4]
JNZ 0x00189ee9
LEA R10D,[R14 + 0x1]
IMUL R10D,EBP
JMP 0x00189e64
LAB_00189e43:
MOVSXD R10,R14D
MOVSXD R9,dword ptr [R15 + R10*0x4]
MOVSXD R8,EBX
MOVSXD R8,dword ptr [R15 + R8*0x4]
MOV R9D,dword ptr [RCX + R9*0x4]
CMP R9D,dword ptr [RCX + R8*0x4]
JNZ 0x00189ee9
MOV R10D,dword ptr [R15 + R10*0x4 + 0x4]
LAB_00189e64:
MOVSXD R9,R10D
MOV R9D,dword ptr [RCX + R9*0x4 + -0x4]
CMP R9D,dword ptr [RCX + R8*0x4 + 0x4]
JNZ 0x00189ee5
LEA R8D,[R13 + 0x1]
MOV word ptr [RDX + 0x4],R8W
ADD R13D,0x2
MOV word ptr [RDX + 0x6],R13W
MOVSX R10D,word ptr [RDI + 0x98]
BT R10D,0x8
JC 0x00189ea0
CMP dword ptr [RSP + 0xc],EBX
JLE 0x00189eb7
LEA R10D,[RBX + 0x1]
JMP 0x00189ebe
LAB_00189ea0:
LEA R9D,[0x1 + RBX*0x2]
MOVSXD R9,R9D
MOV R10,qword ptr [RSP + 0x10]
MOVSX R10D,word ptr [R10 + R9*0x2]
JMP 0x00189ebe
LAB_00189eb7:
AND R10D,0x1
NEG R10D
LAB_00189ebe:
INC R12D
CMP R11D,R8D
JNZ 0x00189e09
MOV R12D,R8D
INC R12D
MOV R13D,R8D
MOV R14D,EBX
JMP 0x00189eec
LAB_00189ed8:
MOV R12W,0x1
XOR R13D,R13D
MOV R14D,EAX
JMP 0x00189ef0
LAB_00189ee5:
LEA R12D,[R13 + 0x1]
LAB_00189ee9:
MOV R10D,EBX
LAB_00189eec:
MOV RBX,qword ptr [RSP]
LAB_00189ef0:
CMP R10D,EAX
JNZ 0x00189f17
CMP word ptr [RSI + 0x2],0x0
JNZ 0x0018a096
INC R14D
MOVSX ESI,word ptr [RDI + 0x9c]
TEST ESI,ESI
JZ 0x00189f60
IMUL R14D,ESI
IMUL EAX,ESI
JMP 0x00189f6e
LAB_00189f17:
MOVSX R8D,word ptr [RSI + 0x2]
MOVSX R9D,word ptr [RSI + 0x4]
MOVSX R10D,R13W
ADD R9D,R8D
SUB R9D,R10D
TEST byte ptr [RSI],0x1
CMOVNZ R9D,R8D
TEST R9D,R9D
JZ 0x0018a083
MOV ESI,dword ptr [RDI + 0x98]
BT ESI,0x8
JC 0x00189f52
TEST AX,AX
JZ 0x00189f90
LEA R8D,[RAX + -0x1]
JMP 0x00189fa7
LAB_00189f52:
MOV RSI,qword ptr [RDI + 0xa8]
MOVSX R8D,word ptr [RSI + RBX*0x4]
JMP 0x00189fa7
LAB_00189f60:
MOV RAX,qword ptr [RDI + 0x60]
MOVSXD RSI,R14D
MOV R14D,dword ptr [RAX + RSI*0x4]
MOV EAX,dword ptr [RAX + RBX*0x4]
LAB_00189f6e:
MOVSXD RSI,R14D
MOV ESI,dword ptr [RCX + RSI*0x4 + -0x4]
CDQE
CMP ESI,dword ptr [RCX + RAX*0x4 + 0x4]
JNZ 0x0018a083
MOV EAX,dword ptr [RSP + 0x8]
AND EAX,0xfffffffe
MOV word ptr [RDX],AX
JMP 0x0018a083
LAB_00189f90:
AND ESI,0x1
MOVSX R10D,word ptr [RDI + 0x2]
DEC R10D
XOR R8D,R8D
NEG SI
SBB R8D,R8D
OR R8D,R10D
LAB_00189fa7:
TEST R9D,R9D
JLE 0x0018a083
MOVSX ESI,word ptr [RDI + 0x9c]
MOV R10,qword ptr [RDI + 0x60]
MOV R11,qword ptr [RDI + 0xa8]
NEG R9D
MOV EBX,0x1
LAB_00189fca:
MOV EBP,EAX
MOV EAX,R8D
TEST SI,SI
JZ 0x00189ffa
MOV R8D,EAX
IMUL R8D,ESI
IMUL EBP,ESI
MOVSXD R8,R8D
MOV R14D,dword ptr [RCX + R8*0x4]
MOVSXD R8,EBP
CMP R14D,dword ptr [RCX + R8*0x4]
JNZ 0x0018a083
LEA EBP,[RAX + 0x1]
IMUL EBP,ESI
JMP 0x0018a017
LAB_00189ffa:
MOVSXD R14,EAX
MOVSXD R15,dword ptr [R10 + R14*0x4]
MOVSXD R8,EBP
MOVSXD R8,dword ptr [R10 + R8*0x4]
MOV EBP,dword ptr [RCX + R15*0x4]
CMP EBP,dword ptr [RCX + R8*0x4]
JNZ 0x0018a083
MOV EBP,dword ptr [R10 + R14*0x4 + 0x4]
LAB_0018a017:
MOVSXD R14,EBP
MOV EBP,dword ptr [RCX + R14*0x4 + -0x4]
CMP EBP,dword ptr [RCX + R8*0x4 + 0x4]
JNZ 0x0018a083
MOV word ptr [RDX + 0x2],BX
INC R12D
MOV word ptr [RDX + 0x6],R12W
MOV R8D,dword ptr [RDI + 0x98]
BT R8D,0x8
JC 0x0018a04a
TEST EAX,EAX
JZ 0x0018a058
LEA R8D,[RAX + -0x1]
JMP 0x0018a072
LAB_0018a04a:
LEA R8D,[RAX + RAX*0x1]
MOVSXD R8,R8D
MOVSX R8D,word ptr [R11 + R8*0x2]
JMP 0x0018a072
LAB_0018a058:
AND R8D,0x1
MOVSX EBP,word ptr [RDI + 0x2]
DEC EBP
NEG R8W
MOV R8D,0x0
SBB R8D,R8D
OR R8D,EBP
LAB_0018a072:
LEA EBP,[R9 + RBX*0x1]
INC EBP
INC EBX
CMP EBP,0x1
JNZ 0x00189fca
LAB_0018a083:
MOVSX EAX,R12W
LAB_0018a087:
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0018a096:
LEA RDI,[0x1c1bc3]
LEA RSI,[0x1c1ad1]
LEA RCX,[0x1c1bdf]
MOV EDX,0x147
CALL 0x00139540
|
/* OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset
const&, OpenSubdiv::v3_6_0::Bfr::FaceVertexSubset*, int const*) const */
int __thiscall
OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent
(FaceVertex *this,FaceVertexSubset *param_1,FaceVertexSubset *param_2,int *param_3)
{
ushort uVar1;
short sVar2;
short sVar3;
long lVar4;
uint uVar5;
long lVar6;
int iVar7;
int iVar8;
int iVar9;
uint uVar10;
uint uVar11;
long lVar12;
long lVar13;
uint uVar14;
int iVar15;
short sVar16;
int iVar17;
short sVar18;
bool bVar19;
uVar1 = *(ushort *)param_1;
*(int4 *)(param_2 + 2) = 0;
*(int2 *)(param_2 + 6) = 1;
*(int4 *)(param_2 + 8) = 0;
*(ushort *)param_2 = uVar1 | 1;
if (*(short *)(param_1 + 6) == 1) {
return 1;
}
sVar2 = *(short *)(this + 0x9a);
uVar5 = (uint)sVar2;
lVar6 = (long)(int)uVar5;
sVar18 = *(short *)(param_1 + 4);
if (sVar18 == 0) {
sVar18 = 0;
iVar17 = 1;
}
else {
if (((uint)(int)*(short *)(this + 0x98) >> 8 & 1) == 0) {
if ((int)uVar5 < *(short *)(this + 2) + -1) {
uVar10 = uVar5 + 1;
}
else {
uVar10 = -((int)*(short *)(this + 0x98) & 1U);
}
}
else {
uVar10 = (uint)*(short *)(*(long *)(this + 0xa8) + 2 + lVar6 * 4);
}
uVar11 = uVar5;
if (sVar18 < 1) {
iVar17 = 1;
sVar18 = 0;
}
else {
sVar16 = *(short *)(this + 0x9c);
iVar7 = (int)sVar16;
lVar4 = *(long *)(this + 0x60);
lVar13 = *(long *)(this + 0xa8);
sVar3 = *(short *)(this + 2);
iVar17 = 1;
iVar15 = 0;
do {
uVar14 = uVar10;
iVar9 = iVar15;
uVar10 = uVar14;
if (sVar16 == 0) {
lVar12 = (long)*(int *)(lVar4 + (long)(int)uVar14 * 4);
if (param_3[*(int *)(lVar4 + (long)(int)uVar11 * 4)] != param_3[lVar12])
goto LAB_00189eec;
iVar15 = *(int *)(lVar4 + 4 + (long)(int)uVar11 * 4);
}
else {
lVar12 = (long)(int)(uVar14 * iVar7);
if (param_3[(int)(uVar11 * iVar7)] != param_3[lVar12]) goto LAB_00189eec;
iVar15 = (uVar11 + 1) * iVar7;
}
if (param_3[(long)iVar15 + -1] != param_3[lVar12 + 1]) {
iVar17 = iVar9 + 1;
goto LAB_00189eec;
}
iVar15 = iVar9 + 1;
*(short *)(param_2 + 4) = (short)iVar15;
*(short *)(param_2 + 6) = (short)iVar9 + 2;
if (((uint)(int)*(short *)(this + 0x98) >> 8 & 1) == 0) {
if ((int)uVar14 < sVar3 + -1) {
uVar10 = uVar14 + 1;
}
else {
uVar10 = -((int)*(short *)(this + 0x98) & 1U);
}
}
else {
uVar10 = (uint)*(short *)(lVar13 + (long)(int)(uVar14 * 2 + 1) * 2);
}
iVar17 = iVar17 + 1;
uVar11 = uVar14;
} while (sVar18 != iVar15);
iVar17 = iVar9 + 2;
iVar9 = iVar15;
LAB_00189eec:
sVar18 = (short)iVar9;
}
sVar16 = (short)iVar17;
if (uVar10 == uVar5) {
if (*(short *)(param_1 + 2) != 0) {
/* WARNING: Subroutine does not return */
__assert_fail("vtxSub._numFacesBefore == 0",
"/workspace/llm4binary/github/2025_star3/NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceVertex.cpp"
,0x147,
"int OpenSubdiv::v3_6_0::Bfr::FaceVertex::findFVarSubsetExtent(const Subset &, Subset *, const Index *) const"
);
}
sVar2 = *(short *)(this + 0x9c);
if (sVar2 == 0) {
iVar17 = *(int *)(*(long *)(this + 0x60) + (long)(int)(uVar11 + 1) * 4);
iVar15 = *(int *)(*(long *)(this + 0x60) + lVar6 * 4);
}
else {
iVar17 = (uVar11 + 1) * (int)sVar2;
iVar15 = uVar5 * (int)sVar2;
}
if (param_3[(long)iVar17 + -1] == param_3[(long)iVar15 + 1]) {
*(ushort *)param_2 = uVar1 & 0xfffe;
}
goto LAB_0018a083;
}
}
sVar16 = (short)iVar17;
iVar15 = ((int)*(short *)(param_1 + 4) + (int)*(short *)(param_1 + 2)) - (int)sVar18;
if (((byte)*param_1 & 1) != 0) {
iVar15 = (int)*(short *)(param_1 + 2);
}
if (iVar15 != 0) {
if ((*(uint *)(this + 0x98) >> 8 & 1) == 0) {
if (sVar2 == 0) {
uVar10 = -(uint)((*(uint *)(this + 0x98) & 1) != 0) | (int)*(short *)(this + 2) - 1U;
}
else {
uVar10 = uVar5 - 1;
}
}
else {
uVar10 = (uint)*(short *)(*(long *)(this + 0xa8) + lVar6 * 4);
}
if (0 < iVar15) {
sVar2 = *(short *)(this + 0x9c);
iVar9 = (int)sVar2;
lVar6 = *(long *)(this + 0x60);
lVar4 = *(long *)(this + 0xa8);
iVar7 = 1;
do {
sVar16 = (short)iVar17;
if (sVar2 == 0) {
lVar13 = (long)*(int *)(lVar6 + (long)(int)uVar5 * 4);
if (param_3[*(int *)(lVar6 + (long)(int)uVar10 * 4)] != param_3[lVar13]) break;
iVar8 = *(int *)(lVar6 + 4 + (long)(int)uVar10 * 4);
}
else {
lVar13 = (long)(int)(uVar5 * iVar9);
if (param_3[(int)(uVar10 * iVar9)] != param_3[lVar13]) break;
iVar8 = (uVar10 + 1) * iVar9;
}
if (param_3[(long)iVar8 + -1] != param_3[lVar13 + 1]) break;
*(short *)(param_2 + 2) = (short)iVar7;
iVar17 = iVar17 + 1;
sVar16 = (short)iVar17;
*(short *)(param_2 + 6) = sVar16;
if ((*(uint *)(this + 0x98) >> 8 & 1) == 0) {
if (uVar10 == 0) {
uVar11 = -(uint)((*(uint *)(this + 0x98) & 1) != 0) | (int)*(short *)(this + 2) - 1U;
}
else {
uVar11 = uVar10 - 1;
}
}
else {
uVar11 = (uint)*(short *)(lVar4 + (long)(int)(uVar10 * 2) * 2);
}
bVar19 = iVar7 != iVar15;
uVar5 = uVar10;
iVar7 = iVar7 + 1;
uVar10 = uVar11;
} while (bVar19);
}
}
LAB_0018a083:
return (int)sVar16;
}
| |
55,536 | nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char*, int) | monkey531[P]llama/common/json.hpp | inline char* append_exponent(char* buf, int e)
{
JSON_ASSERT(e > -1000);
JSON_ASSERT(e < 1000);
if (e < 0)
{
e = -e;
*buf++ = '-';
}
else
{
*buf++ = '+';
}
auto k = static_cast<std::uint32_t>(e);
if (k < 10)
{
// Always print at least two digits in the exponent.
// This is for compatibility with printf("%g").
*buf++ = '0';
*buf++ = static_cast<char>('0' + k);
}
else if (k < 100)
{
*buf++ = static_cast<char>('0' + k / 10);
k %= 10;
*buf++ = static_cast<char>('0' + k);
}
else
{
*buf++ = static_cast<char>('0' + k / 100);
k %= 100;
*buf++ = static_cast<char>('0' + k / 10);
k %= 10;
*buf++ = static_cast<char>('0' + k);
}
return buf;
} | O2 | cpp | nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char*, int):
pushq %rax
cmpl $0xfffffc18, %esi # imm = 0xFFFFFC18
jle 0x898a0
cmpl $0x3e8, %esi # imm = 0x3E8
jge 0x898bc
movl %esi, %ecx
shrl $0x1f, %ecx
addb %cl, %cl
addb $0x2b, %cl
movl %esi, %eax
negl %eax
cmovsl %esi, %eax
movb %cl, (%rdi)
cmpl $0x9, %eax
ja 0x8984e
leaq 0x2(%rdi), %rdx
movb $0x30, 0x1(%rdi)
jmp 0x89869
cmpl $0x63, %eax
ja 0x8986d
movzbl %al, %eax
movb $0xa, %cl
divb %cl
movl %eax, %ecx
movzbl %ah, %eax
orb $0x30, %cl
leaq 0x2(%rdi), %rdx
movb %cl, 0x1(%rdi)
pushq $0x3
jmp 0x89893
movw $0x64, %cx
xorl %edx, %edx
divw %cx
addb $0x30, %al
movb %al, 0x1(%rdi)
movzbl %dl, %eax
movb $0xa, %cl
divb %cl
movl %eax, %ecx
movzbl %ah, %eax
orb $0x30, %cl
leaq 0x3(%rdi), %rdx
movb %cl, 0x2(%rdi)
pushq $0x4
popq %rcx
orb $0x30, %al
addq %rcx, %rdi
movb %al, (%rdx)
movq %rdi, %rax
popq %rcx
retq
leaq 0x27655(%rip), %rdi # 0xb0efc
leaq 0x21986(%rip), %rdx # 0xab234
leaq 0x2cff2(%rip), %rcx # 0xb68a7
movl $0x45ae, %esi # imm = 0x45AE
jmp 0x898d6
leaq 0x27639(%rip), %rdi # 0xb0efc
leaq 0x2196a(%rip), %rdx # 0xab234
leaq 0x2cfe0(%rip), %rcx # 0xb68b1
movl $0x45af, %esi # imm = 0x45AF
xorl %eax, %eax
callq 0x23eb0
nop
| _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl15append_exponentEPci:
push rax
cmp esi, 0FFFFFC18h
jle loc_898A0
cmp esi, 3E8h
jge loc_898BC
mov ecx, esi
shr ecx, 1Fh
add cl, cl
add cl, 2Bh ; '+'
mov eax, esi
neg eax
cmovs eax, esi
mov [rdi], cl
cmp eax, 9
ja short loc_8984E
lea rdx, [rdi+2]
mov byte ptr [rdi+1], 30h ; '0'
jmp short loc_89869
loc_8984E:
cmp eax, 63h ; 'c'
ja short loc_8986D
movzx eax, al
mov cl, 0Ah
div cl
mov ecx, eax
movzx eax, ah
or cl, 30h
lea rdx, [rdi+2]
mov [rdi+1], cl
loc_89869:
push 3
jmp short loc_89893
loc_8986D:
mov cx, 64h ; 'd'
xor edx, edx
div cx
add al, 30h ; '0'
mov [rdi+1], al
movzx eax, dl
mov cl, 0Ah
div cl
mov ecx, eax
movzx eax, ah
or cl, 30h
lea rdx, [rdi+3]
mov [rdi+2], cl
push 4
loc_89893:
pop rcx
or al, 30h
add rdi, rcx
mov [rdx], al
mov rax, rdi
pop rcx
retn
loc_898A0:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aE1000; "e > -1000"
mov esi, 45AEh
jmp short loc_898D6
loc_898BC:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aE1000_0; "e < 1000"
mov esi, 45AFh
loc_898D6:
xor eax, eax
call _ggml_abort
nop
| long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *this,
char *a2)
{
unsigned int v2; // eax
_BYTE *v3; // rdx
char v4; // cl
char v5; // cl
long long v7; // [rsp-10h] [rbp-10h]
if ( (int)a2 <= -1000 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17838LL,
"GGML_ASSERT(%s) failed",
"e > -1000");
}
else
{
if ( (int)a2 < 1000 )
{
v2 = -(int)a2;
if ( (int)a2 > 0 )
v2 = (unsigned int)a2;
*(_BYTE *)this = 2 * ((int)a2 < 0) + 43;
if ( v2 > 9 )
{
if ( v2 > 0x63 )
{
*((_BYTE *)this + 1) = (unsigned __int16)v2 / 0x64u + 48;
v5 = (unsigned __int16)v2 % 0x64u / 0xA;
LOBYTE(v2) = (unsigned __int16)v2 % 0x64u % 0xA;
v3 = (char *)this + 3;
*((_BYTE *)this + 2) = v5 | 0x30;
v7 = 4LL;
goto LABEL_11;
}
v4 = (unsigned __int8)v2 / 0xAu;
LOBYTE(v2) = (unsigned __int8)v2 % 0xAu;
v3 = (char *)this + 2;
*((_BYTE *)this + 1) = v4 | 0x30;
}
else
{
v3 = (char *)this + 2;
*((_BYTE *)this + 1) = 48;
}
v7 = 3LL;
LABEL_11:
*v3 = v2 | 0x30;
return (long long)this + v7;
}
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17839LL,
"GGML_ASSERT(%s) failed",
"e < 1000");
}
return nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)3>::construct<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp");
}
| append_exponent:
PUSH RAX
CMP ESI,0xfffffc18
JLE 0x001898a0
CMP ESI,0x3e8
JGE 0x001898bc
MOV ECX,ESI
SHR ECX,0x1f
ADD CL,CL
ADD CL,0x2b
MOV EAX,ESI
NEG EAX
CMOVS EAX,ESI
MOV byte ptr [RDI],CL
CMP EAX,0x9
JA 0x0018984e
LEA RDX,[RDI + 0x2]
MOV byte ptr [RDI + 0x1],0x30
JMP 0x00189869
LAB_0018984e:
CMP EAX,0x63
JA 0x0018986d
MOVZX EAX,AL
MOV CL,0xa
DIV CL
MOV ECX,EAX
MOVZX EAX,AH
OR CL,0x30
LEA RDX,[RDI + 0x2]
MOV byte ptr [RDI + 0x1],CL
LAB_00189869:
PUSH 0x3
JMP 0x00189893
LAB_0018986d:
MOV CX,0x64
XOR EDX,EDX
DIV CX
ADD AL,0x30
MOV byte ptr [RDI + 0x1],AL
MOVZX EAX,DL
MOV CL,0xa
DIV CL
MOV ECX,EAX
MOVZX EAX,AH
OR CL,0x30
LEA RDX,[RDI + 0x3]
MOV byte ptr [RDI + 0x2],CL
PUSH 0x4
LAB_00189893:
POP RCX
OR AL,0x30
ADD RDI,RCX
MOV byte ptr [RDX],AL
MOV RAX,RDI
POP RCX
RET
LAB_001898a0:
LEA RDI,[0x1b0efc]
LEA RDX,[0x1ab234]
LEA RCX,[0x1b68a7]
MOV ESI,0x45ae
JMP 0x001898d6
LAB_001898bc:
LEA RDI,[0x1b0efc]
LEA RDX,[0x1ab234]
LEA RCX,[0x1b68b1]
MOV ESI,0x45af
LAB_001898d6:
XOR EAX,EAX
CALL 0x00123eb0
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char*, int) */
char * nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char *param_1,int param_2)
{
byte bVar2;
uint uVar1;
char *pcVar3;
ushort uVar4;
byte *pbVar5;
int8 uVar6;
long lStack_10;
if (param_2 < -999) {
pcVar3 = "e > -1000";
uVar6 = 0x45ae;
LAB_001898d6:
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar6,
"GGML_ASSERT(%s) failed",pcVar3);
}
if (999 < param_2) {
pcVar3 = "e < 1000";
uVar6 = 0x45af;
goto LAB_001898d6;
}
uVar1 = -param_2;
if (0 < param_2) {
uVar1 = param_2;
}
*param_1 = (char)(param_2 >> 0x1f) * -2 + '+';
if (uVar1 < 10) {
param_1[1] = '0';
}
else {
if (99 < uVar1) {
uVar4 = (ushort)((uVar1 & 0xffff) % 100);
param_1[1] = (char)((uVar1 & 0xffff) / 100) + '0';
bVar2 = (byte)(uVar4 % 10);
pbVar5 = (byte *)(param_1 + 3);
param_1[2] = (byte)(uVar4 / 10) | 0x30;
lStack_10 = 4;
goto LAB_00189893;
}
uVar4 = (ushort)uVar1 & 0xff;
uVar1 = (uint)(byte)(uVar4 % 10);
param_1[1] = (byte)(uVar4 / 10) | 0x30;
}
pbVar5 = (byte *)(param_1 + 2);
bVar2 = (byte)uVar1;
lStack_10 = 3;
LAB_00189893:
*pbVar5 = bVar2 | 0x30;
return param_1 + lStack_10;
}
| |
55,537 | my_dir | eloqsql/mysys/my_lib.c | MY_DIR *my_dir(const char *path, myf MyFlags)
{
MY_DIR_HANDLE *dirh;
FILEINFO finfo;
DIR *dirp;
struct dirent *dp;
char tmp_path[FN_REFLEN + 2], *tmp_file;
char dirent_tmp[sizeof(struct dirent)+_POSIX_PATH_MAX+1];
DBUG_ENTER("my_dir");
DBUG_PRINT("my",("path: '%s' MyFlags: %lu",path,MyFlags));
tmp_file= directory_file_name(tmp_path, path);
if (!(dirp= opendir(tmp_path)))
{
my_errno= errno;
goto err_open;
}
if (!(dirh= my_malloc(key_memory_MY_DIR, sizeof(*dirh),
MYF(MyFlags | MY_ZEROFILL))))
goto err_alloc;
if (my_init_dynamic_array(key_memory_MY_DIR, &dirh->array, sizeof(FILEINFO),
ENTRIES_START_SIZE, ENTRIES_INCREMENT,
MYF(MyFlags)))
goto error;
init_alloc_root(key_memory_MY_DIR, &dirh->root, NAMES_START_SIZE,
NAMES_START_SIZE, MYF(MyFlags));
dp= (struct dirent*) dirent_tmp;
while (!(READDIR(dirp,(struct dirent*) dirent_tmp,dp)))
{
MY_STAT statbuf, *mystat= 0;
if (dp->d_name[0] == '.' &&
(dp->d_name[1] == '\0' ||
(dp->d_name[1] == '.' && dp->d_name[2] == '\0')))
continue; /* . or .. */
if (MyFlags & MY_WANT_STAT)
{
mystat= &statbuf;
bzero(mystat, sizeof(*mystat));
(void) strmov(tmp_file, dp->d_name);
(void) my_stat(tmp_path, mystat, MyFlags);
if (!(mystat->st_mode & MY_S_IREAD))
continue;
}
if (!(finfo.name= strdup_root(&dirh->root, dp->d_name)))
goto error;
if (mystat &&
!((mystat= memdup_root(&dirh->root, mystat, sizeof(*mystat)))))
goto error;
finfo.mystat= mystat;
if (push_dynamic(&dirh->array, (uchar*)&finfo))
goto error;
}
(void) closedir(dirp);
if (MyFlags & MY_WANT_SORT)
sort_dynamic(&dirh->array, (qsort_cmp) comp_names);
dirh->dir.dir_entry= dynamic_element(&dirh->array, 0, FILEINFO *);
dirh->dir.number_of_files= dirh->array.elements;
DBUG_RETURN(&dirh->dir);
error:
my_dirend(&dirh->dir);
err_alloc:
(void) closedir(dirp);
err_open:
if (MyFlags & (MY_FAE | MY_WME))
my_error(EE_DIR, MYF(ME_BELL), path, my_errno);
DBUG_RETURN(NULL);
} | O0 | c | my_dir:
pushq %rbp
movq %rsp, %rbp
subq $0x530, %rsp # imm = 0x530
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x440(%rbp)
movq %rsi, -0x448(%rbp)
jmp 0xfb788
leaq -0x210(%rbp), %rdi
movq -0x440(%rbp), %rsi
callq 0xfbb30
movq %rax, -0x478(%rbp)
leaq -0x210(%rbp), %rdi
callq 0x2a4b0
movq %rax, -0x468(%rbp)
cmpq $0x0, %rax
jne 0xfb7da
callq 0x2a7d0
movl (%rax), %eax
movl %eax, -0x514(%rbp)
callq 0xfe880
movl -0x514(%rbp), %ecx
movl %ecx, (%rax)
jmp 0xfbaab
leaq 0xb92ec3(%rip), %rax # 0xc8e6a4
movl (%rax), %edi
movq -0x448(%rbp), %rdx
orq $0x20, %rdx
movl $0x78, %esi
callq 0xfc020
movq %rax, -0x450(%rbp)
cmpq $0x0, %rax
jne 0xfb80a
jmp 0xfba9f
leaq 0xb92e93(%rip), %rax # 0xc8e6a4
movl (%rax), %edi
movq -0x450(%rbp), %rsi
addq $0x10, %rsi
movq -0x448(%rbp), %rax
movl $0x10, %edx
xorl %ecx, %ecx
movl $0x200, %r8d # imm = 0x200
movl $0x1000, %r9d # imm = 0x1000
movq %rax, (%rsp)
callq 0xdc580
cmpb $0x0, %al
je 0xfb84a
jmp 0xfba93
leaq 0xb92e53(%rip), %rax # 0xc8e6a4
movl (%rax), %edi
movq -0x450(%rbp), %rsi
addq $0x38, %rsi
movq -0x448(%rbp), %r8
movl $0x8000, %ecx # imm = 0x8000
movq %rcx, %rdx
callq 0xf1580
leaq -0x430(%rbp), %rax
movq %rax, -0x470(%rbp)
movq -0x468(%rbp), %rdi
callq 0x2a4c0
movq %rax, -0x470(%rbp)
cmpq $0x0, %rax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
testb $0x1, %al
jne 0xfb8a7
jmp 0xfba0c
movq $0x0, -0x510(%rbp)
movq -0x470(%rbp), %rax
movsbl 0x13(%rax), %eax
cmpl $0x2e, %eax
jne 0xfb8f4
movq -0x470(%rbp), %rax
movsbl 0x14(%rax), %eax
cmpl $0x0, %eax
je 0xfb8f2
movq -0x470(%rbp), %rax
movsbl 0x14(%rax), %eax
cmpl $0x2e, %eax
jne 0xfb8f4
movq -0x470(%rbp), %rax
movsbl 0x15(%rax), %eax
cmpl $0x0, %eax
jne 0xfb8f4
jmp 0xfb880
movq -0x448(%rbp), %rax
andq $0x4000, %rax # imm = 0x4000
cmpq $0x0, %rax
je 0xfb974
leaq -0x508(%rbp), %rax
movq %rax, -0x510(%rbp)
movq -0x510(%rbp), %rdi
xorl %esi, %esi
movl $0x90, %edx
callq 0x2a2c0
movq -0x478(%rbp), %rdi
movq -0x470(%rbp), %rsi
addq $0x13, %rsi
callq 0x2a7a0
leaq -0x210(%rbp), %rdi
movq -0x510(%rbp), %rsi
movq -0x448(%rbp), %rdx
callq 0xfbba0
movq -0x510(%rbp), %rax
movl 0x18(%rax), %eax
andl $0x100, %eax # imm = 0x100
cmpl $0x0, %eax
jne 0xfb972
jmp 0xfb880
jmp 0xfb974
movq -0x450(%rbp), %rdi
addq $0x38, %rdi
movq -0x470(%rbp), %rsi
addq $0x13, %rsi
callq 0xf20b0
movq %rax, -0x460(%rbp)
cmpq $0x0, %rax
jne 0xfb9a1
jmp 0xfba93
cmpq $0x0, -0x510(%rbp)
je 0xfb9d9
movq -0x450(%rbp), %rdi
addq $0x38, %rdi
movq -0x510(%rbp), %rsi
movl $0x90, %edx
callq 0xf2150
movq %rax, -0x510(%rbp)
cmpq $0x0, %rax
jne 0xfb9d9
jmp 0xfba93
movq -0x510(%rbp), %rax
movq %rax, -0x458(%rbp)
movq -0x450(%rbp), %rdi
addq $0x10, %rdi
leaq -0x460(%rbp), %rsi
callq 0xdc6b0
cmpb $0x0, %al
je 0xfba07
jmp 0xfba93
jmp 0xfb880
movq -0x468(%rbp), %rdi
callq 0x2a490
movq -0x448(%rbp), %rax
andq $0x2000, %rax # imm = 0x2000
cmpq $0x0, %rax
je 0xfba5a
movq -0x450(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x450(%rbp), %rax
movl 0x18(%rax), %eax
movl %eax, %esi
movq -0x450(%rbp), %rax
movl 0x24(%rax), %eax
movl %eax, %edx
leaq 0x23b(%rip), %rcx # 0xfbc90
callq 0xedad0
movq -0x450(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x450(%rbp), %rax
movq %rcx, (%rax)
movq -0x450(%rbp), %rax
movl 0x18(%rax), %ecx
movq -0x450(%rbp), %rax
movl %ecx, 0x8(%rax)
movq -0x450(%rbp), %rax
movq %rax, -0x438(%rbp)
jmp 0xfbaf6
movq -0x450(%rbp), %rdi
callq 0xfb710
movq -0x468(%rbp), %rdi
callq 0x2a490
movq -0x448(%rbp), %rax
andq $0x18, %rax
cmpq $0x0, %rax
je 0xfbae9
movq -0x440(%rbp), %rax
movq %rax, -0x520(%rbp)
callq 0xfe880
movq -0x520(%rbp), %rdx
movl (%rax), %ecx
movl $0xc, %edi
movl $0x4, %esi
movb $0x0, %al
callq 0xf3f50
jmp 0xfbaeb
movq $0x0, -0x438(%rbp)
movq -0x438(%rbp), %rax
movq %rax, -0x528(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0xfbb26
movq -0x528(%rbp), %rax
addq $0x530, %rsp # imm = 0x530
popq %rbp
retq
callq 0x2a270
nopl (%rax,%rax)
| my_dir:
push rbp
mov rbp, rsp
sub rsp, 530h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_440], rdi
mov [rbp+var_448], rsi
jmp short $+2
loc_FB788:
lea rdi, [rbp+var_210]
mov rsi, [rbp+var_440]
call directory_file_name
mov [rbp+var_478], rax
lea rdi, [rbp+var_210]
call _opendir
mov [rbp+var_468], rax
cmp rax, 0
jnz short loc_FB7DA
call ___errno_location
mov eax, [rax]
mov [rbp+var_514], eax
call _my_thread_var
mov ecx, [rbp+var_514]
mov [rax], ecx
jmp loc_FBAAB
loc_FB7DA:
lea rax, key_memory_MY_DIR
mov edi, [rax]
mov rdx, [rbp+var_448]
or rdx, 20h
mov esi, 78h ; 'x'
call my_malloc
mov [rbp+var_450], rax
cmp rax, 0
jnz short loc_FB80A
jmp loc_FBA9F
loc_FB80A:
lea rax, key_memory_MY_DIR
mov edi, [rax]
mov rsi, [rbp+var_450]
add rsi, 10h
mov rax, [rbp+var_448]
mov edx, 10h
xor ecx, ecx
mov r8d, 200h
mov r9d, 1000h
mov [rsp+530h+var_530], rax
call init_dynamic_array2
cmp al, 0
jz short loc_FB84A
jmp loc_FBA93
loc_FB84A:
lea rax, key_memory_MY_DIR
mov edi, [rax]
mov rsi, [rbp+var_450]
add rsi, 38h ; '8'
mov r8, [rbp+var_448]
mov ecx, 8000h
mov rdx, rcx
call init_alloc_root
lea rax, [rbp+var_430]
mov [rbp+var_470], rax
loc_FB880:
mov rdi, [rbp+var_468]
call _readdir64
mov [rbp+var_470], rax
cmp rax, 0
setnz al
xor al, 0FFh
xor al, 0FFh
test al, 1
jnz short loc_FB8A7
jmp loc_FBA0C
loc_FB8A7:
mov [rbp+var_510], 0
mov rax, [rbp+var_470]
movsx eax, byte ptr [rax+13h]
cmp eax, 2Eh ; '.'
jnz short loc_FB8F4
mov rax, [rbp+var_470]
movsx eax, byte ptr [rax+14h]
cmp eax, 0
jz short loc_FB8F2
mov rax, [rbp+var_470]
movsx eax, byte ptr [rax+14h]
cmp eax, 2Eh ; '.'
jnz short loc_FB8F4
mov rax, [rbp+var_470]
movsx eax, byte ptr [rax+15h]
cmp eax, 0
jnz short loc_FB8F4
loc_FB8F2:
jmp short loc_FB880
loc_FB8F4:
mov rax, [rbp+var_448]
and rax, 4000h
cmp rax, 0
jz short loc_FB974
lea rax, [rbp+var_508]
mov [rbp+var_510], rax
mov rdi, [rbp+var_510]
xor esi, esi
mov edx, 90h
call _memset
mov rdi, [rbp+var_478]
mov rsi, [rbp+var_470]
add rsi, 13h
call _stpcpy
lea rdi, [rbp+var_210]
mov rsi, [rbp+var_510]
mov rdx, [rbp+var_448]
call my_stat
mov rax, [rbp+var_510]
mov eax, [rax+18h]
and eax, 100h
cmp eax, 0
jnz short loc_FB972
jmp loc_FB880
loc_FB972:
jmp short $+2
loc_FB974:
mov rdi, [rbp+var_450]
add rdi, 38h ; '8'
mov rsi, [rbp+var_470]
add rsi, 13h
call strdup_root
mov [rbp+var_460], rax
cmp rax, 0
jnz short loc_FB9A1
jmp loc_FBA93
loc_FB9A1:
cmp [rbp+var_510], 0
jz short loc_FB9D9
mov rdi, [rbp+var_450]
add rdi, 38h ; '8'
mov rsi, [rbp+var_510]
mov edx, 90h
call memdup_root
mov [rbp+var_510], rax
cmp rax, 0
jnz short loc_FB9D9
jmp loc_FBA93
loc_FB9D9:
mov rax, [rbp+var_510]
mov [rbp+var_458], rax
mov rdi, [rbp+var_450]
add rdi, 10h
lea rsi, [rbp+var_460]
call insert_dynamic
cmp al, 0
jz short loc_FBA07
jmp loc_FBA93
loc_FBA07:
jmp loc_FB880
loc_FBA0C:
mov rdi, [rbp+var_468]
call _closedir
mov rax, [rbp+var_448]
and rax, 2000h
cmp rax, 0
jz short loc_FBA5A
mov rax, [rbp+var_450]
mov rdi, [rax+10h]
mov rax, [rbp+var_450]
mov eax, [rax+18h]
mov esi, eax
mov rax, [rbp+var_450]
mov eax, [rax+24h]
mov edx, eax
lea rcx, comp_names
call my_qsort
loc_FBA5A:
mov rax, [rbp+var_450]
mov rcx, [rax+10h]
mov rax, [rbp+var_450]
mov [rax], rcx
mov rax, [rbp+var_450]
mov ecx, [rax+18h]
mov rax, [rbp+var_450]
mov [rax+8], ecx
mov rax, [rbp+var_450]
mov [rbp+var_438], rax
jmp short loc_FBAF6
loc_FBA93:
mov rdi, [rbp+var_450]
call my_dirend
loc_FBA9F:
mov rdi, [rbp+var_468]
call _closedir
loc_FBAAB:
mov rax, [rbp+var_448]
and rax, 18h
cmp rax, 0
jz short loc_FBAE9
mov rax, [rbp+var_440]
mov [rbp+var_520], rax
call _my_thread_var
mov rdx, [rbp+var_520]
mov ecx, [rax]
mov edi, 0Ch
mov esi, 4
mov al, 0
call my_error
loc_FBAE9:
jmp short $+2
loc_FBAEB:
mov [rbp+var_438], 0
loc_FBAF6:
mov rax, [rbp+var_438]
mov [rbp+var_528], rax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_FBB26
mov rax, [rbp+var_528]
add rsp, 530h
pop rbp
retn
loc_FBB26:
call ___stack_chk_fail
| long long my_dir(const char *a1, long long a2)
{
const char *v2; // rsi
_BYTE *v3; // rdi
unsigned int *v4; // rax
const char *v6; // [rsp+10h] [rbp-520h]
int v7; // [rsp+1Ch] [rbp-514h]
char *v8; // [rsp+20h] [rbp-510h]
_BYTE v9[24]; // [rsp+28h] [rbp-508h] BYREF
__int16 v10; // [rsp+40h] [rbp-4F0h]
long long v11; // [rsp+B8h] [rbp-478h]
char *v12; // [rsp+C0h] [rbp-470h]
long long v13; // [rsp+C8h] [rbp-468h]
_QWORD v14[2]; // [rsp+D0h] [rbp-460h] BYREF
long long v15; // [rsp+E0h] [rbp-450h]
long long v16; // [rsp+E8h] [rbp-448h]
const char *v17; // [rsp+F0h] [rbp-440h]
char v19; // [rsp+100h] [rbp-430h] BYREF
_BYTE v20[520]; // [rsp+320h] [rbp-210h] BYREF
unsigned long long v21; // [rsp+528h] [rbp-8h]
v21 = __readfsqword(0x28u);
v17 = a1;
v16 = a2;
v2 = a1;
v11 = directory_file_name(v20, a1);
v3 = v20;
v13 = opendir(v20);
if ( !v13 )
{
v7 = *(_DWORD *)__errno_location();
*(_DWORD *)my_thread_var(v20, v2) = v7;
LABEL_24:
if ( (v16 & 0x18) != 0 )
{
v6 = v17;
v4 = (unsigned int *)my_thread_var(v3, v2);
my_error(0xCu, 4LL, v6, *v4);
}
return 0LL;
}
v2 = (const char *)&dword_78;
v15 = my_malloc(key_memory_MY_DIR, 120LL, v16 | 0x20);
if ( !v15 )
{
LABEL_23:
v3 = (_BYTE *)v13;
closedir(v13);
goto LABEL_24;
}
v2 = (const char *)(v15 + 16);
if ( init_dynamic_array2(key_memory_MY_DIR, v15 + 16, 0x10u, 0LL, 0x200u, 4096, v16) )
{
LABEL_22:
my_dirend(v15);
goto LABEL_23;
}
init_alloc_root(key_memory_MY_DIR, (long long *)(v15 + 56), 0x8000LL, 0x8000LL, v16);
v12 = &v19;
while ( 1 )
{
v12 = (char *)readdir64(v13);
if ( !v12 )
break;
v8 = 0LL;
if ( v12[19] != 46 || v12[20] && (v12[20] != 46 || v12[21]) )
{
if ( (v16 & 0x4000) == 0
|| (v8 = v9, memset(v9, 0LL, 144LL), stpcpy(v11, v12 + 19), my_stat(v20, v9, v16), (v10 & 0x100) != 0) )
{
v2 = v12 + 19;
v14[0] = strdup_root(v15 + 56, (long long)(v12 + 19));
if ( !v14[0] )
goto LABEL_22;
if ( v8 )
{
v2 = v8;
v8 = memdup_root((_QWORD **)(v15 + 56), (long long)v8, 144LL);
if ( !v8 )
goto LABEL_22;
}
v14[1] = v8;
v2 = (const char *)v14;
if ( insert_dynamic(v15 + 16, (long long)v14) )
goto LABEL_22;
}
}
}
closedir(v13);
if ( (v16 & 0x2000) != 0 )
my_qsort(
*(char **)(v15 + 16),
*(unsigned int *)(v15 + 24),
*(unsigned int *)(v15 + 36),
(int ( *)(char *, char *))comp_names);
*(_QWORD *)v15 = *(_QWORD *)(v15 + 16);
*(_DWORD *)(v15 + 8) = *(_DWORD *)(v15 + 24);
return v15;
}
| my_dir:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x530
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x440],RDI
MOV qword ptr [RBP + -0x448],RSI
JMP 0x001fb788
LAB_001fb788:
LEA RDI,[RBP + -0x210]
MOV RSI,qword ptr [RBP + -0x440]
CALL 0x001fbb30
MOV qword ptr [RBP + -0x478],RAX
LEA RDI,[RBP + -0x210]
CALL 0x0012a4b0
MOV qword ptr [RBP + -0x468],RAX
CMP RAX,0x0
JNZ 0x001fb7da
CALL 0x0012a7d0
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x514],EAX
CALL 0x001fe880
MOV ECX,dword ptr [RBP + -0x514]
MOV dword ptr [RAX],ECX
JMP 0x001fbaab
LAB_001fb7da:
LEA RAX,[0xd8e6a4]
MOV EDI,dword ptr [RAX]
MOV RDX,qword ptr [RBP + -0x448]
OR RDX,0x20
MOV ESI,0x78
CALL 0x001fc020
MOV qword ptr [RBP + -0x450],RAX
CMP RAX,0x0
JNZ 0x001fb80a
JMP 0x001fba9f
LAB_001fb80a:
LEA RAX,[0xd8e6a4]
MOV EDI,dword ptr [RAX]
MOV RSI,qword ptr [RBP + -0x450]
ADD RSI,0x10
MOV RAX,qword ptr [RBP + -0x448]
MOV EDX,0x10
XOR ECX,ECX
MOV R8D,0x200
MOV R9D,0x1000
MOV qword ptr [RSP],RAX
CALL 0x001dc580
CMP AL,0x0
JZ 0x001fb84a
JMP 0x001fba93
LAB_001fb84a:
LEA RAX,[0xd8e6a4]
MOV EDI,dword ptr [RAX]
MOV RSI,qword ptr [RBP + -0x450]
ADD RSI,0x38
MOV R8,qword ptr [RBP + -0x448]
MOV ECX,0x8000
MOV RDX,RCX
CALL 0x001f1580
LEA RAX,[RBP + -0x430]
MOV qword ptr [RBP + -0x470],RAX
LAB_001fb880:
MOV RDI,qword ptr [RBP + -0x468]
CALL 0x0012a4c0
MOV qword ptr [RBP + -0x470],RAX
CMP RAX,0x0
SETNZ AL
XOR AL,0xff
XOR AL,0xff
TEST AL,0x1
JNZ 0x001fb8a7
JMP 0x001fba0c
LAB_001fb8a7:
MOV qword ptr [RBP + -0x510],0x0
MOV RAX,qword ptr [RBP + -0x470]
MOVSX EAX,byte ptr [RAX + 0x13]
CMP EAX,0x2e
JNZ 0x001fb8f4
MOV RAX,qword ptr [RBP + -0x470]
MOVSX EAX,byte ptr [RAX + 0x14]
CMP EAX,0x0
JZ 0x001fb8f2
MOV RAX,qword ptr [RBP + -0x470]
MOVSX EAX,byte ptr [RAX + 0x14]
CMP EAX,0x2e
JNZ 0x001fb8f4
MOV RAX,qword ptr [RBP + -0x470]
MOVSX EAX,byte ptr [RAX + 0x15]
CMP EAX,0x0
JNZ 0x001fb8f4
LAB_001fb8f2:
JMP 0x001fb880
LAB_001fb8f4:
MOV RAX,qword ptr [RBP + -0x448]
AND RAX,0x4000
CMP RAX,0x0
JZ 0x001fb974
LEA RAX,[RBP + -0x508]
MOV qword ptr [RBP + -0x510],RAX
MOV RDI,qword ptr [RBP + -0x510]
XOR ESI,ESI
MOV EDX,0x90
CALL 0x0012a2c0
MOV RDI,qword ptr [RBP + -0x478]
MOV RSI,qword ptr [RBP + -0x470]
ADD RSI,0x13
CALL 0x0012a7a0
LEA RDI,[RBP + -0x210]
MOV RSI,qword ptr [RBP + -0x510]
MOV RDX,qword ptr [RBP + -0x448]
CALL 0x001fbba0
MOV RAX,qword ptr [RBP + -0x510]
MOV EAX,dword ptr [RAX + 0x18]
AND EAX,0x100
CMP EAX,0x0
JNZ 0x001fb972
JMP 0x001fb880
LAB_001fb972:
JMP 0x001fb974
LAB_001fb974:
MOV RDI,qword ptr [RBP + -0x450]
ADD RDI,0x38
MOV RSI,qword ptr [RBP + -0x470]
ADD RSI,0x13
CALL 0x001f20b0
MOV qword ptr [RBP + -0x460],RAX
CMP RAX,0x0
JNZ 0x001fb9a1
JMP 0x001fba93
LAB_001fb9a1:
CMP qword ptr [RBP + -0x510],0x0
JZ 0x001fb9d9
MOV RDI,qword ptr [RBP + -0x450]
ADD RDI,0x38
MOV RSI,qword ptr [RBP + -0x510]
MOV EDX,0x90
CALL 0x001f2150
MOV qword ptr [RBP + -0x510],RAX
CMP RAX,0x0
JNZ 0x001fb9d9
JMP 0x001fba93
LAB_001fb9d9:
MOV RAX,qword ptr [RBP + -0x510]
MOV qword ptr [RBP + -0x458],RAX
MOV RDI,qword ptr [RBP + -0x450]
ADD RDI,0x10
LEA RSI,[RBP + -0x460]
CALL 0x001dc6b0
CMP AL,0x0
JZ 0x001fba07
JMP 0x001fba93
LAB_001fba07:
JMP 0x001fb880
LAB_001fba0c:
MOV RDI,qword ptr [RBP + -0x468]
CALL 0x0012a490
MOV RAX,qword ptr [RBP + -0x448]
AND RAX,0x2000
CMP RAX,0x0
JZ 0x001fba5a
MOV RAX,qword ptr [RBP + -0x450]
MOV RDI,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x450]
MOV EAX,dword ptr [RAX + 0x18]
MOV ESI,EAX
MOV RAX,qword ptr [RBP + -0x450]
MOV EAX,dword ptr [RAX + 0x24]
MOV EDX,EAX
LEA RCX,[0x1fbc90]
CALL 0x001edad0
LAB_001fba5a:
MOV RAX,qword ptr [RBP + -0x450]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x450]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x450]
MOV ECX,dword ptr [RAX + 0x18]
MOV RAX,qword ptr [RBP + -0x450]
MOV dword ptr [RAX + 0x8],ECX
MOV RAX,qword ptr [RBP + -0x450]
MOV qword ptr [RBP + -0x438],RAX
JMP 0x001fbaf6
LAB_001fba93:
MOV RDI,qword ptr [RBP + -0x450]
CALL 0x001fb710
LAB_001fba9f:
MOV RDI,qword ptr [RBP + -0x468]
CALL 0x0012a490
LAB_001fbaab:
MOV RAX,qword ptr [RBP + -0x448]
AND RAX,0x18
CMP RAX,0x0
JZ 0x001fbae9
MOV RAX,qword ptr [RBP + -0x440]
MOV qword ptr [RBP + -0x520],RAX
CALL 0x001fe880
MOV RDX,qword ptr [RBP + -0x520]
MOV ECX,dword ptr [RAX]
MOV EDI,0xc
MOV ESI,0x4
MOV AL,0x0
CALL 0x001f3f50
LAB_001fbae9:
JMP 0x001fbaeb
LAB_001fbaeb:
MOV qword ptr [RBP + -0x438],0x0
LAB_001fbaf6:
MOV RAX,qword ptr [RBP + -0x438]
MOV qword ptr [RBP + -0x528],RAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x001fbb26
MOV RAX,qword ptr [RBP + -0x528]
ADD RSP,0x530
POP RBP
RET
LAB_001fbb26:
CALL 0x0012a270
|
int8 * my_dir(int8 param_1,ulong param_2)
{
int iVar1;
int8 uVar2;
char cVar3;
int *piVar4;
int4 *puVar5;
long in_FS_OFFSET;
int1 *local_518;
int1 local_510 [24];
uint local_4f8;
char *local_480;
dirent64 *local_478;
DIR *local_470;
long local_468;
int1 *local_460;
int8 *local_458;
ulong local_450;
int8 local_448;
int8 *local_440;
dirent64 local_438;
char local_218 [520];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_450 = param_2;
local_448 = param_1;
local_480 = (char *)directory_file_name(local_218,param_1);
local_470 = opendir(local_218);
if (local_470 == (DIR *)0x0) {
piVar4 = __errno_location();
iVar1 = *piVar4;
piVar4 = (int *)_my_thread_var();
*piVar4 = iVar1;
}
else {
local_458 = (int8 *)my_malloc(key_memory_MY_DIR,0x78,local_450 | 0x20);
if (local_458 != (int8 *)0x0) {
cVar3 = init_dynamic_array2(key_memory_MY_DIR,local_458 + 2,0x10,0,0x200,0x1000,local_450);
if (cVar3 == '\0') {
init_alloc_root(key_memory_MY_DIR,local_458 + 7,0x8000,0x8000,local_450);
local_478 = &local_438;
LAB_001fb880:
do {
do {
local_478 = readdir64(local_470);
if (local_478 == (dirent64 *)0x0) {
closedir(local_470);
if ((local_450 & 0x2000) != 0) {
my_qsort(local_458[2],*(int4 *)(local_458 + 3),
*(int4 *)((long)local_458 + 0x24),comp_names);
}
*local_458 = local_458[2];
*(int4 *)(local_458 + 1) = *(int4 *)(local_458 + 3);
local_440 = local_458;
goto LAB_001fbaf6;
}
local_518 = (int1 *)0x0;
} while ((local_478->d_name[0] == '.') &&
((local_478->d_name[1] == '\0' ||
((local_478->d_name[1] == '.' && (local_478->d_name[2] == '\0'))))));
if ((local_450 & 0x4000) != 0) {
local_518 = local_510;
memset(local_518,0,0x90);
stpcpy(local_480,local_478->d_name);
my_stat(local_218,local_518,local_450);
if ((local_4f8 & 0x100) == 0) goto LAB_001fb880;
}
local_468 = strdup_root(local_458 + 7,local_478->d_name);
if ((local_468 == 0) ||
((local_518 != (int1 *)0x0 &&
(local_518 = (int1 *)memdup_root(local_458 + 7,local_518,0x90),
local_518 == (int1 *)0x0)))) break;
local_460 = local_518;
cVar3 = insert_dynamic(local_458 + 2);
if (cVar3 != '\0') break;
} while( true );
}
my_dirend(local_458);
}
closedir(local_470);
}
uVar2 = local_448;
if ((local_450 & 0x18) != 0) {
puVar5 = (int4 *)_my_thread_var();
my_error(0xc,4,uVar2,*puVar5);
}
local_440 = (int8 *)0x0;
LAB_001fbaf6:
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return local_440;
}
| |
55,538 | js_strict_eq2 | bluesky950520[P]quickjs/quickjs.c | static BOOL js_strict_eq2(JSContext *ctx, JSValue op1, JSValue op2,
JSStrictEqModeEnum eq_mode)
{
BOOL res;
int tag1, tag2;
double d1, d2;
tag1 = JS_VALUE_GET_NORM_TAG(op1);
tag2 = JS_VALUE_GET_NORM_TAG(op2);
switch(tag1) {
case JS_TAG_BOOL:
if (tag1 != tag2) {
res = FALSE;
} else {
res = JS_VALUE_GET_INT(op1) == JS_VALUE_GET_INT(op2);
goto done_no_free;
}
break;
case JS_TAG_NULL:
case JS_TAG_UNDEFINED:
res = (tag1 == tag2);
break;
case JS_TAG_STRING:
{
JSString *p1, *p2;
if (tag1 != tag2) {
res = FALSE;
} else {
p1 = JS_VALUE_GET_STRING(op1);
p2 = JS_VALUE_GET_STRING(op2);
res = js_string_eq(p1, p2);
}
}
break;
case JS_TAG_SYMBOL:
{
JSAtomStruct *p1, *p2;
if (tag1 != tag2) {
res = FALSE;
} else {
p1 = JS_VALUE_GET_PTR(op1);
p2 = JS_VALUE_GET_PTR(op2);
res = (p1 == p2);
}
}
break;
case JS_TAG_OBJECT:
if (tag1 != tag2)
res = FALSE;
else
res = JS_VALUE_GET_OBJ(op1) == JS_VALUE_GET_OBJ(op2);
break;
case JS_TAG_INT:
d1 = JS_VALUE_GET_INT(op1);
if (tag2 == JS_TAG_INT) {
d2 = JS_VALUE_GET_INT(op2);
goto number_test;
} else if (tag2 == JS_TAG_FLOAT64) {
d2 = JS_VALUE_GET_FLOAT64(op2);
goto number_test;
} else {
res = FALSE;
}
break;
case JS_TAG_FLOAT64:
d1 = JS_VALUE_GET_FLOAT64(op1);
if (tag2 == JS_TAG_FLOAT64) {
d2 = JS_VALUE_GET_FLOAT64(op2);
} else if (tag2 == JS_TAG_INT) {
d2 = JS_VALUE_GET_INT(op2);
} else {
res = FALSE;
break;
}
number_test:
if (unlikely(eq_mode >= JS_EQ_SAME_VALUE)) {
JSFloat64Union u1, u2;
/* NaN is not always normalized, so this test is necessary */
if (isnan(d1) || isnan(d2)) {
res = isnan(d1) == isnan(d2);
} else if (eq_mode == JS_EQ_SAME_VALUE_ZERO) {
res = (d1 == d2); /* +0 == -0 */
} else {
u1.d = d1;
u2.d = d2;
res = (u1.u64 == u2.u64); /* +0 != -0 */
}
} else {
res = (d1 == d2); /* if NaN return false and +0 == -0 */
}
goto done_no_free;
case JS_TAG_BIG_INT:
{
bf_t a_s, *a, b_s, *b;
if (tag1 != tag2) {
res = FALSE;
break;
}
a = JS_ToBigInt1(ctx, &a_s, op1);
b = JS_ToBigInt1(ctx, &b_s, op2);
res = bf_cmp_eq(a, b);
if (a == &a_s)
bf_delete(a);
if (b == &b_s)
bf_delete(b);
}
break;
default:
res = FALSE;
break;
}
JS_FreeValue(ctx, op1);
JS_FreeValue(ctx, op2);
done_no_free:
return res;
} | O1 | c | js_strict_eq2:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %r8, %rbx
movq %rcx, %r14
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %r15
movq %rsi, 0x8(%rsp)
movq %rcx, (%rsp)
xorl %ebp, %ebp
leal 0x9(%rdx), %eax
cmpl $0x10, %eax
ja 0x3a2a4
movq %r14, %xmm0
leaq 0x62998(%rip), %rcx # 0x9cafc
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
cmpl %ebx, %r12d
sete %bpl
jmp 0x3a2a4
cmpl $-0x7, %ebx
jne 0x3a2a2
movq 0x8(%rsp), %rdi
movq (%rsp), %rsi
movl $0x7fffffff, %eax # imm = 0x7FFFFFFF
movl 0x4(%rdi), %edx
andl %eax, %edx
andl 0x4(%rsi), %eax
cmpl %eax, %edx
jne 0x3a2a2
callq 0x3bb93
testl %eax, %eax
jmp 0x3a170
cmpl $0x1, %ebx
jne 0x3a2a2
movl 0x8(%rsp), %eax
cmpl (%rsp), %eax
sete %bpl
jmp 0x3a2c2
cmpl $-0x9, %ebx
jne 0x3a2a2
leaq 0x40(%rsp), %rsi
movq %r15, %rdi
movq %r13, %rdx
movq %r12, %rcx
callq 0x430ad
movq %rax, %rbp
leaq 0x18(%rsp), %rsi
movq %r15, %rdi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x430ad
movq %rbp, %rdi
movq %rax, 0x10(%rsp)
movq %rax, %rsi
callq 0x854f5
movq %rbp, %rcx
testl %eax, %eax
sete %bpl
leaq 0x40(%rsp), %rax
cmpq %rax, %rcx
je 0x3a2d8
movq 0x10(%rsp), %rcx
leaq 0x18(%rsp), %rax
cmpq %rax, %rcx
jne 0x3a2a4
movq (%rcx), %rax
testq %rax, %rax
je 0x3a2a4
movq 0x20(%rcx), %rsi
testq %rsi, %rsi
je 0x3a2a4
movq (%rax), %rdi
xorl %edx, %edx
callq *0x8(%rax)
jmp 0x3a2a4
cmpl $-0x8, %ebx
sete %al
movq (%rsp), %rcx
cmpq %rcx, 0x8(%rsp)
sete %bpl
andb %al, %bpl
jmp 0x3a2a4
cmpl $-0x1, %ebx
jne 0x3a2a2
movq 0x8(%rsp), %rax
cmpq (%rsp), %rax
jmp 0x3a170
movq %r13, %xmm1
jmp 0x3a27d
cvtsi2sdl 0x8(%rsp), %xmm1
cmpl $0x7, %ebx
je 0x3a28e
testl %ebx, %ebx
jne 0x3a2a2
xorps %xmm0, %xmm0
cvtsi2sdl (%rsp), %xmm0
testl %r9d, %r9d
jne 0x3a2fe
cmpeqsd %xmm0, %xmm1
movq %xmm1, %rbp
andl $0x1, %ebp
jmp 0x3a2c2
xorl %ebp, %ebp
movq 0x18(%r15), %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x1d8c6
movq 0x18(%r15), %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x1d8c6
movzbl %bpl, %eax
andl $0x1, %eax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq (%rcx), %rax
testq %rax, %rax
je 0x3a21b
movq 0x20(%rcx), %rsi
testq %rsi, %rsi
je 0x3a21b
movq (%rax), %rdi
xorl %edx, %edx
callq *0x8(%rax)
jmp 0x3a21b
ucomisd %xmm1, %xmm1
jp 0x3a322
ucomisd %xmm0, %xmm0
jp 0x3a322
cmpl $0x2, %r9d
je 0x3a293
movq %xmm1, %rax
movq %xmm0, %rcx
cmpq %rcx, %rax
jmp 0x3a1b9
xorpd %xmm2, %xmm2
cmpunordpd %xmm2, %xmm1
cmpordpd %xmm2, %xmm0
xorpd %xmm1, %xmm0
movd %xmm0, %ebp
jmp 0x3a2c2
| js_strict_eq2:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 68h
mov rbx, r8
mov r14, rcx
mov r12, rdx
mov r13, rsi
mov r15, rdi
mov [rsp+98h+var_90], rsi
mov [rsp+98h+var_98], rcx
xor ebp, ebp
lea eax, [rdx+9]; switch 17 cases
cmp eax, 10h
ja def_3A16B; jumptable 000000000003A16B default case, cases -6--2,4-6
movq xmm0, r14
lea rcx, jpt_3A16B
movsxd rax, ds:(jpt_3A16B - 9CAFCh)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_3A16D:
cmp r12d, ebx; jumptable 000000000003A16B cases 2,3
loc_3A170:
setz bpl
jmp def_3A16B; jumptable 000000000003A16B default case, cases -6--2,4-6
loc_3A179:
cmp ebx, 0FFFFFFF9h; jumptable 000000000003A16B case -7
jnz loc_3A2A2
mov rdi, [rsp+98h+var_90]
mov rsi, [rsp+98h+var_98]
mov eax, 7FFFFFFFh
mov edx, [rdi+4]
and edx, eax
and eax, [rsi+4]
cmp edx, eax
jnz loc_3A2A2
call js_string_memcmp
test eax, eax
jmp short loc_3A170
loc_3A1A9:
cmp ebx, 1; jumptable 000000000003A16B case 1
jnz loc_3A2A2
mov eax, dword ptr [rsp+98h+var_90]
cmp eax, dword ptr [rsp+98h+var_98]
loc_3A1B9:
setz bpl
jmp loc_3A2C2
loc_3A1C2:
cmp ebx, 0FFFFFFF7h; jumptable 000000000003A16B case -9
jnz loc_3A2A2
lea rsi, [rsp+98h+var_58]
mov rdi, r15
mov rdx, r13
mov rcx, r12
call JS_ToBigInt1
mov rbp, rax
lea rsi, [rsp+98h+var_80]
mov rdi, r15
mov rdx, r14
mov rcx, rbx
call JS_ToBigInt1
mov rdi, rbp
mov [rsp+98h+var_88], rax
mov rsi, rax
call bf_cmp
mov rcx, rbp
test eax, eax
setz bpl
lea rax, [rsp+98h+var_58]
cmp rcx, rax
jz loc_3A2D8
loc_3A21B:
mov rcx, [rsp+98h+var_88]
lea rax, [rsp+98h+var_80]
cmp rcx, rax
jnz short def_3A16B; jumptable 000000000003A16B default case, cases -6--2,4-6
mov rax, [rcx]
test rax, rax
jz short def_3A16B; jumptable 000000000003A16B default case, cases -6--2,4-6
mov rsi, [rcx+20h]
test rsi, rsi
jz short def_3A16B; jumptable 000000000003A16B default case, cases -6--2,4-6
mov rdi, [rax]
xor edx, edx
call qword ptr [rax+8]
jmp short def_3A16B; jumptable 000000000003A16B default case, cases -6--2,4-6
loc_3A245:
cmp ebx, 0FFFFFFF8h; jumptable 000000000003A16B case -8
setz al
mov rcx, [rsp+98h+var_98]
cmp [rsp+98h+var_90], rcx
setz bpl
and bpl, al
jmp short def_3A16B; jumptable 000000000003A16B default case, cases -6--2,4-6
loc_3A25D:
cmp ebx, 0FFFFFFFFh; jumptable 000000000003A16B case -1
jnz short loc_3A2A2
mov rax, [rsp+98h+var_90]
cmp rax, [rsp+98h+var_98]
jmp loc_3A170
loc_3A270:
movq xmm1, r13; jumptable 000000000003A16B case 7
jmp short loc_3A27D
loc_3A277:
cvtsi2sd xmm1, dword ptr [rsp+98h+var_90]; jumptable 000000000003A16B case 0
loc_3A27D:
cmp ebx, 7
jz short loc_3A28E
test ebx, ebx
jnz short loc_3A2A2
xorps xmm0, xmm0
cvtsi2sd xmm0, dword ptr [rsp+98h+var_98]
loc_3A28E:
test r9d, r9d
jnz short loc_3A2FE
loc_3A293:
cmpeqsd xmm1, xmm0
movq rbp, xmm1
and ebp, 1
jmp short loc_3A2C2
loc_3A2A2:
xor ebp, ebp
def_3A16B:
mov rdi, [r15+18h]; jumptable 000000000003A16B default case, cases -6--2,4-6
mov rsi, r13
mov rdx, r12
call JS_FreeValueRT
mov rdi, [r15+18h]
mov rsi, r14
mov rdx, rbx
call JS_FreeValueRT
loc_3A2C2:
movzx eax, bpl
and eax, 1
add rsp, 68h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3A2D8:
mov rax, [rcx]
test rax, rax
jz loc_3A21B
mov rsi, [rcx+20h]
test rsi, rsi
jz loc_3A21B
mov rdi, [rax]
xor edx, edx
call qword ptr [rax+8]
jmp loc_3A21B
loc_3A2FE:
ucomisd xmm1, xmm1
jp short loc_3A322
ucomisd xmm0, xmm0
jp short loc_3A322
cmp r9d, 2
jz short loc_3A293
movq rax, xmm1
movq rcx, xmm0
cmp rax, rcx
jmp loc_3A1B9
loc_3A322:
xorpd xmm2, xmm2
cmpunordpd xmm1, xmm2
cmpordpd xmm0, xmm2
xorpd xmm0, xmm1
movd ebp, xmm0
jmp short loc_3A2C2
| _BOOL8 js_strict_eq2(
long long a1,
_DWORD *a2,
long long a3,
_DWORD *a4,
long long a5,
int a6,
double a7,
__m128d a8)
{
bool v12; // bp
__m128d v13; // xmm0
bool v14; // zf
long long v15; // rdx
long long v17; // rbp
int v18; // eax
_QWORD **v19; // rcx
_QWORD *v20; // rsi
_QWORD *v22; // rsi
_QWORD **v23; // [rsp+10h] [rbp-88h]
_BYTE v24[40]; // [rsp+18h] [rbp-80h] BYREF
_BYTE v25[88]; // [rsp+40h] [rbp-58h] BYREF
v12 = 0;
*(_QWORD *)&v13.m128d_f64[0] = a4;
switch ( (int)a3 )
{
case -9:
if ( (_DWORD)a5 != -9 )
goto LABEL_26;
v17 = JS_ToBigInt1(a1, v25, a2, a3);
v23 = (_QWORD **)JS_ToBigInt1(a1, v24, a4, a5);
v18 = bf_cmp(v17, v23);
v19 = (_QWORD **)v17;
v12 = v18 == 0;
if ( v19 == (_QWORD **)v25 )
{
if ( *v19 )
{
v22 = v19[4];
if ( v22 )
((void ( *)(_QWORD, _QWORD *, _QWORD, double))(*v19)[1])(**v19, v22, 0LL, v13.m128d_f64[0]);
}
}
if ( v23 == (_QWORD **)v24 )
{
if ( *v23 )
{
v20 = v23[4];
if ( v20 )
((void ( *)(_QWORD, _QWORD *, _QWORD, double))(*v23)[1])(**v23, v20, 0LL, v13.m128d_f64[0]);
}
}
goto LABEL_27;
case -8:
v12 = (_DWORD)a5 == -8 && a2 == a4;
goto LABEL_27;
case -7:
if ( (_DWORD)a5 != -7 )
goto LABEL_26;
v15 = a2[1] & 0x7FFFFFFF;
if ( (_DWORD)v15 != (a4[1] & 0x7FFFFFFF) )
goto LABEL_26;
v14 = (unsigned int)js_string_memcmp(a2, a4, v15) == 0;
goto LABEL_3;
case -1:
if ( (_DWORD)a5 != -1 )
goto LABEL_26;
v14 = a2 == a4;
LABEL_3:
v12 = v14;
goto LABEL_27;
case 0:
a8.m128d_f64[0] = (double)(int)a2;
goto LABEL_21;
case 1:
if ( (_DWORD)a5 != 1 )
goto LABEL_26;
return (_DWORD)a2 == (_DWORD)a4;
case 2:
case 3:
v14 = (_DWORD)a3 == (_DWORD)a5;
goto LABEL_3;
case 7:
a8 = (__m128d)(unsigned long long)a2;
LABEL_21:
if ( (_DWORD)a5 == 7 )
goto LABEL_24;
if ( (_DWORD)a5 )
{
LABEL_26:
v12 = 0;
LABEL_27:
JS_FreeValueRT(*(_QWORD *)(a1 + 24), a2, a3);
JS_FreeValueRT(*(_QWORD *)(a1 + 24), a4, a5);
}
else
{
v13.m128d_f64[0] = (double)(int)a4;
LABEL_24:
if ( !a6 || a6 == 2 )
return *(_OWORD *)&_mm_cmpeq_sd(a8, v13) & 1;
else
return *(_QWORD *)&a8.m128d_f64[0] == *(_QWORD *)&v13.m128d_f64[0];
}
return v12;
default:
goto LABEL_27;
}
}
| js_strict_eq2:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x68
MOV RBX,R8
MOV R14,RCX
MOV R12,RDX
MOV R13,RSI
MOV R15,RDI
MOV qword ptr [RSP + 0x8],RSI
MOV qword ptr [RSP],RCX
XOR EBP,EBP
LEA EAX,[RDX + 0x9]
CMP EAX,0x10
JA 0x0013a2a4
MOVQ XMM0,R14
LEA RCX,[0x19cafc]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_2:
CMP R12D,EBX
LAB_0013a170:
SETZ BPL
JMP 0x0013a2a4
caseD_fffffff9:
CMP EBX,-0x7
JNZ 0x0013a2a2
MOV RDI,qword ptr [RSP + 0x8]
MOV RSI,qword ptr [RSP]
MOV EAX,0x7fffffff
MOV EDX,dword ptr [RDI + 0x4]
AND EDX,EAX
AND EAX,dword ptr [RSI + 0x4]
CMP EDX,EAX
JNZ 0x0013a2a2
CALL 0x0013bb93
TEST EAX,EAX
JMP 0x0013a170
caseD_1:
CMP EBX,0x1
JNZ 0x0013a2a2
MOV EAX,dword ptr [RSP + 0x8]
CMP EAX,dword ptr [RSP]
LAB_0013a1b9:
SETZ BPL
JMP 0x0013a2c2
caseD_fffffff7:
CMP EBX,-0x9
JNZ 0x0013a2a2
LEA RSI,[RSP + 0x40]
MOV RDI,R15
MOV RDX,R13
MOV RCX,R12
CALL 0x001430ad
MOV RBP,RAX
LEA RSI,[RSP + 0x18]
MOV RDI,R15
MOV RDX,R14
MOV RCX,RBX
CALL 0x001430ad
MOV RDI,RBP
MOV qword ptr [RSP + 0x10],RAX
MOV RSI,RAX
CALL 0x001854f5
MOV RCX,RBP
TEST EAX,EAX
SETZ BPL
LEA RAX,[RSP + 0x40]
CMP RCX,RAX
JZ 0x0013a2d8
LAB_0013a21b:
MOV RCX,qword ptr [RSP + 0x10]
LEA RAX,[RSP + 0x18]
CMP RCX,RAX
JNZ 0x0013a2a4
MOV RAX,qword ptr [RCX]
TEST RAX,RAX
JZ 0x0013a2a4
MOV RSI,qword ptr [RCX + 0x20]
TEST RSI,RSI
JZ 0x0013a2a4
MOV RDI,qword ptr [RAX]
XOR EDX,EDX
CALL qword ptr [RAX + 0x8]
JMP 0x0013a2a4
caseD_fffffff8:
CMP EBX,-0x8
SETZ AL
MOV RCX,qword ptr [RSP]
CMP qword ptr [RSP + 0x8],RCX
SETZ BPL
AND BPL,AL
JMP 0x0013a2a4
caseD_ffffffff:
CMP EBX,-0x1
JNZ 0x0013a2a2
MOV RAX,qword ptr [RSP + 0x8]
CMP RAX,qword ptr [RSP]
JMP 0x0013a170
caseD_7:
MOVQ XMM1,R13
JMP 0x0013a27d
caseD_0:
CVTSI2SD XMM1,dword ptr [RSP + 0x8]
LAB_0013a27d:
CMP EBX,0x7
JZ 0x0013a28e
TEST EBX,EBX
JNZ 0x0013a2a2
XORPS XMM0,XMM0
CVTSI2SD XMM0,dword ptr [RSP]
LAB_0013a28e:
TEST R9D,R9D
JNZ 0x0013a2fe
LAB_0013a293:
CMPEQSD XMM1,XMM0
MOVQ RBP,XMM1
AND EBP,0x1
JMP 0x0013a2c2
LAB_0013a2a2:
XOR EBP,EBP
caseD_fffffffa:
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,R13
MOV RDX,R12
CALL 0x0011d8c6
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,R14
MOV RDX,RBX
CALL 0x0011d8c6
LAB_0013a2c2:
MOVZX EAX,BPL
AND EAX,0x1
ADD RSP,0x68
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0013a2d8:
MOV RAX,qword ptr [RCX]
TEST RAX,RAX
JZ 0x0013a21b
MOV RSI,qword ptr [RCX + 0x20]
TEST RSI,RSI
JZ 0x0013a21b
MOV RDI,qword ptr [RAX]
XOR EDX,EDX
CALL qword ptr [RAX + 0x8]
JMP 0x0013a21b
LAB_0013a2fe:
UCOMISD XMM1,XMM1
JP 0x0013a322
UCOMISD XMM0,XMM0
JP 0x0013a322
CMP R9D,0x2
JZ 0x0013a293
MOVQ RAX,XMM1
MOVQ RCX,XMM0
CMP RAX,RCX
JMP 0x0013a1b9
LAB_0013a322:
XORPD XMM2,XMM2
CMPUNORDPD XMM1,XMM2
CMPORDPD XMM0,XMM2
XORPD XMM0,XMM1
MOVD EBP,XMM0
JMP 0x0013a2c2
|
bool js_strict_eq2(long param_1,double param_2,int8 param_3,double param_4,int8 param_5,
int param_6)
{
int8 *puVar1;
int iVar2;
long *plVar3;
long *plVar4;
bool bVar5;
double dVar6;
int local_98;
int local_90;
long local_80 [5];
long local_58 [5];
bVar5 = false;
iVar2 = (int)param_5;
local_90 = SUB84(param_2,0);
local_98 = SUB84(param_4,0);
switch((int)param_3) {
case 0:
dVar6 = (double)local_90;
goto LAB_0013a27d;
case 1:
if (iVar2 == 1) {
return local_90 == local_98;
}
break;
case 2:
case 3:
bVar5 = (int)param_3 == iVar2;
goto switchD_0013a16b_caseD_fffffffa;
case 7:
dVar6 = param_2;
LAB_0013a27d:
if (iVar2 == 7) {
LAB_0013a28e:
if (param_6 != 0) {
if ((NAN(dVar6)) || (NAN(param_4))) {
return !NAN(param_4) != NAN(dVar6);
}
if (param_6 != 2) {
return dVar6 == param_4;
}
}
return dVar6 == param_4;
}
if (iVar2 == 0) {
param_4 = (double)local_98;
goto LAB_0013a28e;
}
break;
case -9:
if (iVar2 == -9) {
plVar3 = (long *)JS_ToBigInt1(param_1,local_58,param_2,param_3);
plVar4 = (long *)JS_ToBigInt1(param_1,local_80,param_4,param_5);
iVar2 = bf_cmp(plVar3,plVar4);
bVar5 = iVar2 == 0;
if (((plVar3 == local_58) && (puVar1 = (int8 *)*plVar3, puVar1 != (int8 *)0x0)) &&
(plVar3[4] != 0)) {
(*(code *)puVar1[1])(*puVar1,plVar3[4],0);
}
if (((plVar4 == local_80) && (puVar1 = (int8 *)*plVar4, puVar1 != (int8 *)0x0)) &&
(plVar4[4] != 0)) {
(*(code *)puVar1[1])(*puVar1,plVar4[4],0);
}
goto switchD_0013a16b_caseD_fffffffa;
}
break;
case -8:
bVar5 = param_2 == param_4 && iVar2 == -8;
goto switchD_0013a16b_caseD_fffffffa;
case -7:
if ((iVar2 == -7) &&
((*(uint *)((long)param_2 + 4) & 0x7fffffff) == (*(uint *)((long)param_4 + 4) & 0x7fffffff)))
{
iVar2 = js_string_memcmp();
bVar5 = iVar2 == 0;
goto switchD_0013a16b_caseD_fffffffa;
}
break;
default:
goto switchD_0013a16b_caseD_fffffffa;
case -1:
if (iVar2 == -1) {
bVar5 = param_2 == param_4;
goto switchD_0013a16b_caseD_fffffffa;
}
}
bVar5 = false;
switchD_0013a16b_caseD_fffffffa:
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),param_2,param_3);
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),param_4,param_5);
return bVar5;
}
| |
55,539 | json_at | corpus-core[P]colibri-stateless/src/util/json.c | json_t json_at(json_t parent, size_t index) {
if (parent.type != JSON_TYPE_ARRAY) return json(JSON_TYPE_INVALID, parent.start, 0);
size_t i = 0;
json_for_each_value(parent, val) {
if (index == i++) return val;
}
return json(JSON_TYPE_NOT_FOUND, parent.start, 0);
} | O0 | c | json_at:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x40(%rbp)
movq %rdi, -0x38(%rbp)
leaq 0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
movq %rsi, -0x8(%rbp)
cmpl $0x4, 0x10(%rax)
je 0xa4504
movq -0x40(%rbp), %rax
movq -0x30(%rbp), %rcx
movq (%rcx), %rcx
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movl $0x0, 0x10(%rax)
jmp 0xa45e6
movq -0x30(%rbp), %rax
movq -0x40(%rbp), %rdi
movq $0x0, -0x10(%rbp)
xorl %ecx, %ecx
movl %ecx, %esi
xorl %edx, %edx
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0xa40f0
movq -0x40(%rbp), %rcx
xorl %eax, %eax
cmpl $-0x1, 0x10(%rcx)
movb %al, -0x41(%rbp)
je 0xa4555
movq -0x40(%rbp), %rax
cmpl $0x0, 0x10(%rax)
setne %al
movb %al, -0x41(%rbp)
movb -0x41(%rbp), %al
testb $0x1, %al
jne 0xa455e
jmp 0xa45c9
movq -0x8(%rbp), %rax
movq -0x10(%rbp), %rcx
movq %rcx, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
cmpq %rcx, %rax
jne 0xa4578
jmp 0xa45e6
jmp 0xa457a
movq -0x40(%rbp), %rax
leaq -0x28(%rbp), %rdi
xorl %ecx, %ecx
movl %ecx, %esi
movl $0x2, %edx
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0xa40f0
movq -0x40(%rbp), %rax
movq -0x28(%rbp), %rcx
movq %rcx, (%rax)
movq -0x20(%rbp), %rcx
movq %rcx, 0x8(%rax)
movq -0x18(%rbp), %rcx
movq %rcx, 0x10(%rax)
jmp 0xa4538
movq -0x40(%rbp), %rax
movq -0x30(%rbp), %rcx
movq (%rcx), %rcx
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movl $0xffffffff, 0x10(%rax) # imm = 0xFFFFFFFF
movq -0x38(%rbp), %rax
addq $0x60, %rsp
popq %rbp
retq
| json_at:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_40], rdi
mov [rbp+var_38], rdi
lea rax, [rbp+arg_0]
mov [rbp+var_30], rax
mov [rbp+var_8], rsi
cmp dword ptr [rax+10h], 4
jz short loc_A4504
mov rax, [rbp+var_40]
mov rcx, [rbp+var_30]
mov rcx, [rcx]
mov [rax], rcx
mov qword ptr [rax+8], 0
mov dword ptr [rax+10h], 0
jmp loc_A45E6
loc_A4504:
mov rax, [rbp+var_30]
mov rdi, [rbp+var_40]
mov [rbp+var_10], 0
xor ecx, ecx
mov esi, ecx
xor edx, edx
mov rcx, [rax]
mov [rsp+60h+var_60], rcx
mov rcx, [rax+8]
mov [rsp+60h+var_58], rcx
mov rax, [rax+10h]
mov [rsp+60h+var_50], rax
call json_next_value
loc_A4538:
mov rcx, [rbp+var_40]
xor eax, eax
cmp dword ptr [rcx+10h], 0FFFFFFFFh
mov [rbp+var_41], al
jz short loc_A4555
mov rax, [rbp+var_40]
cmp dword ptr [rax+10h], 0
setnz al
mov [rbp+var_41], al
loc_A4555:
mov al, [rbp+var_41]
test al, 1
jnz short loc_A455E
jmp short loc_A45C9
loc_A455E:
mov rax, [rbp+var_8]
mov rcx, [rbp+var_10]
mov rdx, rcx
add rdx, 1
mov [rbp+var_10], rdx
cmp rax, rcx
jnz short loc_A4578
jmp short loc_A45E6
loc_A4578:
jmp short $+2
loc_A457A:
mov rax, [rbp+var_40]
lea rdi, [rbp+var_28]
xor ecx, ecx
mov esi, ecx
mov edx, 2
mov rcx, [rax]
mov [rsp+60h+var_60], rcx
mov rcx, [rax+8]
mov [rsp+60h+var_58], rcx
mov rax, [rax+10h]
mov [rsp+60h+var_50], rax
call json_next_value
mov rax, [rbp+var_40]
mov rcx, [rbp+var_28]
mov [rax], rcx
mov rcx, [rbp+var_20]
mov [rax+8], rcx
mov rcx, [rbp+var_18]
mov [rax+10h], rcx
jmp loc_A4538
loc_A45C9:
mov rax, [rbp+var_40]
mov rcx, [rbp+var_30]
mov rcx, [rcx]
mov [rax], rcx
mov qword ptr [rax+8], 0
mov dword ptr [rax+10h], 0FFFFFFFFh
loc_A45E6:
mov rax, [rbp+var_38]
add rsp, 60h
pop rbp
retn
| long long * json_at(
long long *a1,
long long a2,
_DWORD a3,
_DWORD a4,
long long a5,
long long a6,
long long a7,
long long a8,
long long a9)
{
long long v9; // r8
long long v10; // r9
long long v11; // rcx
bool v13; // [rsp+1Fh] [rbp-41h]
_QWORD v14[3]; // [rsp+38h] [rbp-28h] BYREF
long long v15; // [rsp+50h] [rbp-10h]
long long v16; // [rsp+58h] [rbp-8h]
v16 = a2;
if ( (_DWORD)a9 == 4 )
{
v15 = 0LL;
json_next_value((long long)a1, 0LL, 0, a8, a5, a6, a7, a8, a9);
while ( 1 )
{
v13 = 0;
if ( *((_DWORD *)a1 + 4) != -1 )
v13 = *((_DWORD *)a1 + 4) != 0;
if ( !v13 )
break;
v11 = v15++;
if ( v16 == v11 )
return a1;
json_next_value((long long)v14, 0LL, 2, a1[1], v9, v10, *a1, a1[1], a1[2]);
*a1 = v14[0];
a1[1] = v14[1];
a1[2] = v14[2];
}
*a1 = a7;
a1[1] = 0LL;
*((_DWORD *)a1 + 4) = -1;
}
else
{
*a1 = a7;
a1[1] = 0LL;
*((_DWORD *)a1 + 4) = 0;
}
return a1;
}
| json_at:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x40],RDI
MOV qword ptr [RBP + -0x38],RDI
LEA RAX,[RBP + 0x10]
MOV qword ptr [RBP + -0x30],RAX
MOV qword ptr [RBP + -0x8],RSI
CMP dword ptr [RAX + 0x10],0x4
JZ 0x001a4504
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RCX]
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV dword ptr [RAX + 0x10],0x0
JMP 0x001a45e6
LAB_001a4504:
MOV RAX,qword ptr [RBP + -0x30]
MOV RDI,qword ptr [RBP + -0x40]
MOV qword ptr [RBP + -0x10],0x0
XOR ECX,ECX
MOV ESI,ECX
XOR EDX,EDX
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x001a40f0
LAB_001a4538:
MOV RCX,qword ptr [RBP + -0x40]
XOR EAX,EAX
CMP dword ptr [RCX + 0x10],-0x1
MOV byte ptr [RBP + -0x41],AL
JZ 0x001a4555
MOV RAX,qword ptr [RBP + -0x40]
CMP dword ptr [RAX + 0x10],0x0
SETNZ AL
MOV byte ptr [RBP + -0x41],AL
LAB_001a4555:
MOV AL,byte ptr [RBP + -0x41]
TEST AL,0x1
JNZ 0x001a455e
JMP 0x001a45c9
LAB_001a455e:
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDX,RCX
ADD RDX,0x1
MOV qword ptr [RBP + -0x10],RDX
CMP RAX,RCX
JNZ 0x001a4578
JMP 0x001a45e6
LAB_001a4578:
JMP 0x001a457a
LAB_001a457a:
MOV RAX,qword ptr [RBP + -0x40]
LEA RDI,[RBP + -0x28]
XOR ECX,ECX
MOV ESI,ECX
MOV EDX,0x2
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x001a40f0
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX + 0x8],RCX
MOV RCX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x10],RCX
JMP 0x001a4538
LAB_001a45c9:
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RCX]
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV dword ptr [RAX + 0x10],0xffffffff
LAB_001a45e6:
MOV RAX,qword ptr [RBP + -0x38]
ADD RSP,0x60
POP RBP
RET
|
int8 * json_at(int8 *param_1,long param_2)
{
bool bVar1;
int8 in_stack_00000008;
int in_stack_00000018;
int8 local_30;
int8 local_28;
int8 local_20;
long local_18;
long local_10;
if (in_stack_00000018 == 4) {
local_18 = 0;
local_10 = param_2;
json_next_value(param_1,0,0);
while( true ) {
bVar1 = false;
if (*(int *)(param_1 + 2) != -1) {
bVar1 = *(int *)(param_1 + 2) != 0;
}
if (!bVar1) break;
if (local_10 == local_18) {
return param_1;
}
local_18 = local_18 + 1;
json_next_value(&local_30,0,2);
*param_1 = local_30;
param_1[1] = local_28;
param_1[2] = local_20;
}
*param_1 = in_stack_00000008;
param_1[1] = 0;
*(int4 *)(param_1 + 2) = 0xffffffff;
}
else {
*param_1 = in_stack_00000008;
param_1[1] = 0;
*(int4 *)(param_1 + 2) = 0;
}
return param_1;
}
| |
55,540 | json_at | corpus-core[P]colibri-stateless/src/util/json.c | json_t json_at(json_t parent, size_t index) {
if (parent.type != JSON_TYPE_ARRAY) return json(JSON_TYPE_INVALID, parent.start, 0);
size_t i = 0;
json_for_each_value(parent, val) {
if (index == i++) return val;
}
return json(JSON_TYPE_NOT_FOUND, parent.start, 0);
} | O2 | c | json_at:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
leaq 0x60(%rsp), %r12
cmpl $0x4, 0x10(%r12)
jne 0x4e7b3
movq %rsi, %r14
movq 0x10(%r12), %rax
movq %rax, 0x10(%rsp)
movups (%r12), %xmm0
movups %xmm0, (%rsp)
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4e4f4
leaq 0x18(%rsp), %r15
pushq $0x2
popq %rbp
movl 0x10(%rbx), %eax
decl %eax
cmpl $-0x3, %eax
ja 0x4e7c5
subq $0x1, %r14
jb 0x4e7d5
movq 0x10(%rbx), %rax
movq %rax, 0x10(%rsp)
movups (%rbx), %xmm0
movups %xmm0, (%rsp)
movq %r15, %rdi
xorl %esi, %esi
movl %ebp, %edx
callq 0x4e4f4
movq 0x28(%rsp), %rax
movq %rax, 0x10(%rbx)
movups 0x18(%rsp), %xmm0
movups %xmm0, (%rbx)
jmp 0x4e774
movq (%r12), %rax
movq %rax, (%rbx)
andq $0x0, 0x8(%rbx)
andl $0x0, 0x10(%rbx)
jmp 0x4e7d5
movq (%r12), %rax
movq %rax, (%rbx)
andq $0x0, 0x8(%rbx)
orl $-0x1, 0x10(%rbx)
movq %rbx, %rax
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| json_at:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 30h
mov rbx, rdi
lea r12, [rsp+58h+arg_0]
cmp dword ptr [r12+10h], 4
jnz short loc_4E7B3
mov r14, rsi
mov rax, [r12+10h]
mov [rsp+58h+var_48], rax
movups xmm0, xmmword ptr [r12]
movups [rsp+58h+var_58], xmm0
mov rdi, rbx
xor esi, esi
xor edx, edx
call json_next_value
lea r15, [rsp+58h+var_40]
push 2
pop rbp
loc_4E774:
mov eax, [rbx+10h]
dec eax
cmp eax, 0FFFFFFFDh
ja short loc_4E7C5
sub r14, 1
jb short loc_4E7D5
mov rax, [rbx+10h]
mov [rsp+58h+var_48], rax
movups xmm0, xmmword ptr [rbx]
movups [rsp+58h+var_58], xmm0
mov rdi, r15
xor esi, esi
mov edx, ebp
call json_next_value
mov rax, [rsp+58h+var_30]
mov [rbx+10h], rax
movups xmm0, [rsp+58h+var_40]
movups xmmword ptr [rbx], xmm0
jmp short loc_4E774
loc_4E7B3:
mov rax, [r12]
mov [rbx], rax
and qword ptr [rbx+8], 0
and dword ptr [rbx+10h], 0
jmp short loc_4E7D5
loc_4E7C5:
mov rax, [r12]
mov [rbx], rax
and qword ptr [rbx+8], 0
or dword ptr [rbx+10h], 0FFFFFFFFh
loc_4E7D5:
mov rax, rbx
add rsp, 30h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| long long json_at(
long long a1,
long long a2,
_DWORD a3,
long long a4,
long long a5,
long long a6,
__int128 a7,
long long a8)
{
long long v9; // rcx
long long v10; // r8
long long v11; // r9
__int128 v14; // [rsp+18h] [rbp-40h] BYREF
long long v15; // [rsp+28h] [rbp-30h]
if ( (_DWORD)a8 == 4 )
{
json_next_value(a1, 0LL, 0, a4, a5, a6, a7, a8);
while ( (unsigned int)(*(_DWORD *)(a1 + 16) - 1) <= 0xFFFFFFFD )
{
if ( a2-- == 0 )
return a1;
json_next_value((long long)&v14, 0LL, 2, v9, v10, v11, *(_OWORD *)a1, *(_QWORD *)(a1 + 16));
*(_QWORD *)(a1 + 16) = v15;
*(_OWORD *)a1 = v14;
}
*(_QWORD *)a1 = a7;
*(_QWORD *)(a1 + 8) = 0LL;
*(_DWORD *)(a1 + 16) = -1;
}
else
{
*(_QWORD *)a1 = a7;
*(_QWORD *)(a1 + 8) = 0LL;
*(_DWORD *)(a1 + 16) = 0;
}
return a1;
}
| json_at:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x30
MOV RBX,RDI
LEA R12,[RSP + 0x60]
CMP dword ptr [R12 + 0x10],0x4
JNZ 0x0014e7b3
MOV R14,RSI
MOV RAX,qword ptr [R12 + 0x10]
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [R12]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,RBX
XOR ESI,ESI
XOR EDX,EDX
CALL 0x0014e4f4
LEA R15,[RSP + 0x18]
PUSH 0x2
POP RBP
LAB_0014e774:
MOV EAX,dword ptr [RBX + 0x10]
DEC EAX
CMP EAX,-0x3
JA 0x0014e7c5
SUB R14,0x1
JC 0x0014e7d5
MOV RAX,qword ptr [RBX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [RBX]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,R15
XOR ESI,ESI
MOV EDX,EBP
CALL 0x0014e4f4
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RBX + 0x10],RAX
MOVUPS XMM0,xmmword ptr [RSP + 0x18]
MOVUPS xmmword ptr [RBX],XMM0
JMP 0x0014e774
LAB_0014e7b3:
MOV RAX,qword ptr [R12]
MOV qword ptr [RBX],RAX
AND qword ptr [RBX + 0x8],0x0
AND dword ptr [RBX + 0x10],0x0
JMP 0x0014e7d5
LAB_0014e7c5:
MOV RAX,qword ptr [R12]
MOV qword ptr [RBX],RAX
AND qword ptr [RBX + 0x8],0x0
OR dword ptr [RBX + 0x10],0xffffffff
LAB_0014e7d5:
MOV RAX,RBX
ADD RSP,0x30
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
int8 * json_at(int8 *param_1,long param_2)
{
bool bVar1;
int8 in_stack_00000008;
int in_stack_00000018;
int8 local_40;
int8 uStack_38;
int8 local_30;
if (in_stack_00000018 == 4) {
json_next_value(param_1,0,0);
while (*(int *)(param_1 + 2) - 1U < 0xfffffffe) {
bVar1 = param_2 == 0;
param_2 = param_2 + -1;
if (bVar1) {
return param_1;
}
json_next_value(&local_40,0,2);
param_1[2] = local_30;
*param_1 = local_40;
param_1[1] = uStack_38;
}
*param_1 = in_stack_00000008;
param_1[1] = 0;
*(int4 *)(param_1 + 2) = 0xffffffff;
}
else {
*param_1 = in_stack_00000008;
param_1[1] = 0;
*(int4 *)(param_1 + 2) = 0;
}
return param_1;
}
| |
55,541 | MyCTX_nopad::finish(unsigned char*, unsigned int*) | eloqsql/mysys_ssl/my_crypt.cc | int finish(uchar *dst, uint *dlen)
{
if (source_tail_len)
{
/*
Not much we can do, block ciphers cannot encrypt data that aren't
a multiple of the block length. At least not without padding.
Let's do something CTR-like for the last partial block.
*/
uchar mask[MY_AES_BLOCK_SIZE];
uint mlen;
int rc= my_aes_crypt(MY_AES_ECB, ENCRYPTION_FLAG_ENCRYPT | ENCRYPTION_FLAG_NOPAD,
oiv, sizeof(mask), mask, &mlen, key, klen, 0, 0);
DBUG_ASSERT(rc == MY_AES_OK);
if (rc)
return rc;
DBUG_ASSERT(mlen == sizeof(mask));
for (uint i=0; i < source_tail_len; i++)
dst[i]= source_tail[i] ^ mask[i];
}
*dlen= source_tail_len;
return MY_AES_OK;
} | O3 | cpp | MyCTX_nopad::finish(unsigned char*, unsigned int*):
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r14
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
xorl %ebx, %ebx
cmpl $0x0, 0xdc(%rdi)
movl $0x0, %r13d
je 0xd858b
movq %rsi, %r15
movq %rdi, %r12
leaq 0xe0(%rdi), %rdx
movl 0xd8(%rdi), %eax
xorl %r13d, %r13d
leaq -0x40(%rbp), %r8
leaq -0x44(%rbp), %r9
xorl %edi, %edi
movl $0x3, %esi
movl $0x10, %ecx
pushq $0x0
pushq $0x0
pushq %rax
pushq 0xd0(%r12)
callq 0xd8107
addq $0x20, %rsp
testl %eax, %eax
je 0xd855e
movl %eax, %ebx
jmp 0xd858e
cmpl $0x0, 0xdc(%r12)
je 0xd858b
xorl %eax, %eax
movb -0x40(%rbp,%rax), %cl
xorb 0xf0(%r12,%rax), %cl
movb %cl, (%r15,%rax)
incq %rax
movl 0xdc(%r12), %r13d
cmpq %r13, %rax
jb 0xd856b
movl %r13d, (%r14)
movq %fs:0x28, %rax
cmpq -0x30(%rbp), %rax
jne 0xd85ae
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x29250
nop
| _ZN11MyCTX_nopad6finishEPhPj:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r14, rdx
mov rax, fs:28h
mov [rbp+var_30], rax
xor ebx, ebx
cmp dword ptr [rdi+0DCh], 0
mov r13d, 0
jz short loc_D858B
mov r15, rsi
mov r12, rdi
lea rdx, [rdi+0E0h]
mov eax, [rdi+0D8h]
xor r13d, r13d
lea r8, [rbp+var_40]
lea r9, [rbp+var_44]
xor edi, edi
mov esi, 3
mov ecx, 10h
push 0
push 0
push rax
push qword ptr [r12+0D0h]
call my_aes_crypt
add rsp, 20h
test eax, eax
jz short loc_D855E
mov ebx, eax
jmp short loc_D858E
loc_D855E:
cmp dword ptr [r12+0DCh], 0
jz short loc_D858B
xor eax, eax
loc_D856B:
mov cl, [rbp+rax+var_40]
xor cl, [r12+rax+0F0h]
mov [r15+rax], cl
inc rax
mov r13d, [r12+0DCh]
cmp rax, r13
jb short loc_D856B
loc_D858B:
mov [r14], r13d
loc_D858E:
mov rax, fs:28h
cmp rax, [rbp+var_30]
jnz short loc_D85AE
mov eax, ebx
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_D85AE:
call ___stack_chk_fail
| long long MyCTX_nopad::finish(MyCTX_nopad *this, unsigned __int8 *a2, unsigned int *a3)
{
unsigned int v4; // ebx
unsigned long long v5; // r13
unsigned int v6; // eax
unsigned long long v7; // rax
int v9; // [rsp+Ch] [rbp-44h] BYREF
_BYTE v10[16]; // [rsp+10h] [rbp-40h] BYREF
unsigned long long v11; // [rsp+20h] [rbp-30h]
v11 = __readfsqword(0x28u);
v4 = 0;
LODWORD(v5) = 0;
if ( !*((_DWORD *)this + 55) )
{
LABEL_7:
*a3 = v5;
return v4;
}
LODWORD(v5) = 0;
v6 = my_aes_crypt(
0,
3,
(long long)this + 224,
0x10u,
(long long)v10,
&v9,
*((_QWORD *)this + 26),
*((_DWORD *)this + 54),
0LL);
if ( !v6 )
{
if ( *((_DWORD *)this + 55) )
{
v7 = 0LL;
do
{
a2[v7] = *((_BYTE *)this + v7 + 240) ^ v10[v7];
++v7;
v5 = *((unsigned int *)this + 55);
}
while ( v7 < v5 );
}
goto LABEL_7;
}
return v6;
}
| finish:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R14,RDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
XOR EBX,EBX
CMP dword ptr [RDI + 0xdc],0x0
MOV R13D,0x0
JZ 0x001d858b
MOV R15,RSI
MOV R12,RDI
LEA RDX,[RDI + 0xe0]
MOV EAX,dword ptr [RDI + 0xd8]
XOR R13D,R13D
LEA R8,[RBP + -0x40]
LEA R9,[RBP + -0x44]
XOR EDI,EDI
MOV ESI,0x3
MOV ECX,0x10
PUSH 0x0
PUSH 0x0
PUSH RAX
PUSH qword ptr [R12 + 0xd0]
CALL 0x001d8107
ADD RSP,0x20
TEST EAX,EAX
JZ 0x001d855e
MOV EBX,EAX
JMP 0x001d858e
LAB_001d855e:
CMP dword ptr [R12 + 0xdc],0x0
JZ 0x001d858b
XOR EAX,EAX
LAB_001d856b:
MOV CL,byte ptr [RBP + RAX*0x1 + -0x40]
XOR CL,byte ptr [R12 + RAX*0x1 + 0xf0]
MOV byte ptr [R15 + RAX*0x1],CL
INC RAX
MOV R13D,dword ptr [R12 + 0xdc]
CMP RAX,R13
JC 0x001d856b
LAB_001d858b:
MOV dword ptr [R14],R13D
LAB_001d858e:
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNZ 0x001d85ae
MOV EAX,EBX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001d85ae:
CALL 0x00129250
|
/* MyCTX_nopad::finish(unsigned char*, unsigned int*) */
int __thiscall MyCTX_nopad::finish(MyCTX_nopad *this,uchar *param_1,uint *param_2)
{
int iVar1;
ulong uVar2;
uint uVar3;
long in_FS_OFFSET;
int1 local_4c [4];
byte local_48 [16];
long local_38;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
uVar3 = 0;
if (*(int *)(this + 0xdc) != 0) {
uVar3 = 0;
iVar1 = my_aes_crypt(0,3,this + 0xe0,0x10,local_48,local_4c,*(int8 *)(this + 0xd0),
*(int4 *)(this + 0xd8),0,0);
if (iVar1 != 0) goto LAB_001d858e;
if (*(int *)(this + 0xdc) != 0) {
uVar2 = 0;
do {
param_1[uVar2] = local_48[uVar2] ^ (byte)this[uVar2 + 0xf0];
uVar2 = uVar2 + 1;
uVar3 = *(uint *)(this + 0xdc);
} while (uVar2 < uVar3);
}
}
*param_2 = uVar3;
iVar1 = 0;
LAB_001d858e:
if (*(long *)(in_FS_OFFSET + 0x28) != local_38) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return iVar1;
}
| |
55,542 | OpenSubdiv::v3_6_0::Vtr::internal::StackBuffer<int, 20u, true>::allocate(unsigned int) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/../bfr/../vtr/stackBuffer.h | inline void
StackBuffer<TYPE,SIZE,POD_TYPE>::allocate(size_type capacity) {
// Again, is alignment an issue here? C++ spec says new will return pointer
// "suitably aligned" for conversion to pointers of other types, which implies
// at least an alignment of 16.
_dynamicData = static_cast<char*>(::operator new(capacity * sizeof(TYPE)));
_data = reinterpret_cast<TYPE*>(_dynamicData);
_capacity = capacity;
} | O0 | c | OpenSubdiv::v3_6_0::Vtr::internal::StackBuffer<int, 20u, true>::allocate(unsigned int):
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movl -0xc(%rbp), %eax
movl %eax, %edi
shlq $0x2, %rdi
callq 0xcd100
movq %rax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x30(%rax)
movq 0x30(%rax), %rcx
movq %rcx, (%rax)
movl -0xc(%rbp), %ecx
movl %ecx, 0xc(%rax)
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
| _ZN10OpenSubdiv6v3_6_03Vtr8internal11StackBufferIiLj8ELb1EE8allocateEj:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov rax, [rbp+var_8]
mov [rbp+var_18], rax
mov eax, [rbp+var_C]
mov edi, eax
shl rdi, 2; unsigned __int64
call __Znwm; operator new(ulong)
mov rcx, rax
mov rax, [rbp+var_18]
mov [rax+30h], rcx
mov rcx, [rax+30h]
mov [rax], rcx
mov ecx, [rbp+var_C]
mov [rax+0Ch], ecx
add rsp, 20h
pop rbp
retn
| long long OpenSubdiv::v3_6_0::Vtr::internal::StackBuffer<int,8u,true>::allocate(long long a1, unsigned int a2)
{
long long v2; // rcx
long long result; // rax
v2 = operator new(4LL * a2);
result = a1;
*(_QWORD *)(a1 + 48) = v2;
*(_QWORD *)a1 = *(_QWORD *)(a1 + 48);
*(_DWORD *)(a1 + 12) = a2;
return result;
}
| |||
55,543 | OpenSubdiv::v3_6_0::Vtr::internal::StackBuffer<int, 20u, true>::allocate(unsigned int) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/../bfr/../vtr/stackBuffer.h | inline void
StackBuffer<TYPE,SIZE,POD_TYPE>::allocate(size_type capacity) {
// Again, is alignment an issue here? C++ spec says new will return pointer
// "suitably aligned" for conversion to pointers of other types, which implies
// at least an alignment of 16.
_dynamicData = static_cast<char*>(::operator new(capacity * sizeof(TYPE)));
_data = reinterpret_cast<TYPE*>(_dynamicData);
_capacity = capacity;
} | O2 | c | OpenSubdiv::v3_6_0::Vtr::internal::StackBuffer<int, 20u, true>::allocate(unsigned int):
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
movl %esi, %edi
shlq $0x2, %rdi
callq 0x52790
movq %rax, 0x30(%r14)
movq %rax, (%r14)
movl %ebx, 0xc(%r14)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
| _ZN10OpenSubdiv6v3_6_03Vtr8internal11StackBufferIiLj8ELb1EE8allocateEj:
push r14
push rbx
push rax
mov ebx, esi
mov r14, rdi
mov edi, esi
shl rdi, 2; unsigned __int64
call __Znwm; operator new(ulong)
mov [r14+30h], rax
mov [r14], rax
mov [r14+0Ch], ebx
add rsp, 8
pop rbx
pop r14
retn
| long long OpenSubdiv::v3_6_0::Vtr::internal::StackBuffer<int,8u,true>::allocate(long long a1, unsigned int a2)
{
long long result; // rax
result = operator new(4LL * a2);
*(_QWORD *)(a1 + 48) = result;
*(_QWORD *)a1 = result;
*(_DWORD *)(a1 + 12) = a2;
return result;
}
| allocate:
PUSH R14
PUSH RBX
PUSH RAX
MOV EBX,ESI
MOV R14,RDI
MOV EDI,ESI
SHL RDI,0x2
CALL 0x00152790
MOV qword ptr [R14 + 0x30],RAX
MOV qword ptr [R14],RAX
MOV dword ptr [R14 + 0xc],EBX
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* OpenSubdiv::v3_6_0::Vtr::internal::StackBuffer<int, 8u, true>::allocate(unsigned int) */
void __thiscall
OpenSubdiv::v3_6_0::Vtr::internal::StackBuffer<int,8u,true>::allocate
(StackBuffer<int,8u,true> *this,uint param_1)
{
void *pvVar1;
pvVar1 = operator_new((ulong)param_1 << 2);
*(void **)(this + 0x30) = pvVar1;
*(void **)this = pvVar1;
*(uint *)(this + 0xc) = param_1;
return;
}
| |
55,544 | ftxui::(anonymous namespace)::Focus::Render(ftxui::Screen&) | Andrewchistyakov[P]flashcards_lyc/build_O2/_deps/ftxui-src/src/ftxui/dom/frame.cpp | void Render(Screen& screen) override {
Select::Render(screen);
// Setting the cursor to the right position allow folks using CJK (China,
// Japanese, Korean, ...) characters to see their [input method editor]
// displayed at the right location. See [issue].
//
// [input method editor]:
// https://en.wikipedia.org/wiki/Input_method
//
// [issue]:
// https://github.com/ArthurSonzogni/FTXUI/issues/2#issuecomment-505282355
//
// Unfortunately, Microsoft terminal do not handle properly hidding the
// cursor. Instead the character under the cursor is hidden, which is a big
// problem. As a result, we can't enable setting cursor to the right
// location. It will be displayed at the bottom right corner.
// See:
// https://github.com/microsoft/terminal/issues/1203
// https://github.com/microsoft/terminal/issues/3093
#if !defined(FTXUI_MICROSOFT_TERMINAL_FALLBACK)
screen.SetCursor(Screen::Cursor{
box_.x_min,
box_.y_min,
Screen::Cursor::Shape::Hidden,
});
#endif
} | O2 | cpp | ftxui::(anonymous namespace)::Focus::Render(ftxui::Screen&):
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
callq 0x1efe0
movl 0x4c(%r14), %eax
movl 0x54(%r14), %ecx
shlq $0x20, %rcx
orq %rax, %rcx
movq %rcx, 0x30(%rbx)
andl $0x0, 0x38(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| _ZN5ftxui12_GLOBAL__N_15Focus6RenderERNS_6ScreenE:
push r14
push rbx
push rax
mov rbx, rsi
mov r14, rdi
call _ZN5ftxui4Node6RenderERNS_6ScreenE; ftxui::Node::Render(ftxui::Screen &)
mov eax, [r14+4Ch]
mov ecx, [r14+54h]
shl rcx, 20h
or rcx, rax
mov [rbx+30h], rcx
and dword ptr [rbx+38h], 0
add rsp, 8
pop rbx
pop r14
retn
| long long ftxui::`anonymous namespace'::Focus::Render(
ftxui::_anonymous_namespace_::Focus *this,
ftxui::Screen *a2)
{
long long result; // rax
ftxui::Node::Render(this, a2);
result = *((unsigned int *)this + 19);
*((_QWORD *)a2 + 6) = result | ((unsigned long long)*((unsigned int *)this + 21) << 32);
*((_DWORD *)a2 + 14) = 0;
return result;
}
| Render:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV R14,RDI
CALL 0x0011efe0
MOV EAX,dword ptr [R14 + 0x4c]
MOV ECX,dword ptr [R14 + 0x54]
SHL RCX,0x20
OR RCX,RAX
MOV qword ptr [RBX + 0x30],RCX
AND dword ptr [RBX + 0x38],0x0
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* ftxui::(anonymous namespace)::Focus::Render(ftxui::Screen&) */
void __thiscall ftxui::(anonymous_namespace)::Focus::Render(Focus *this,Screen *param_1)
{
Node::Render((Node *)this,param_1);
*(ulong *)(param_1 + 0x30) = CONCAT44(*(int4 *)(this + 0x54),*(int4 *)(this + 0x4c));
*(int4 *)(param_1 + 0x38) = 0;
return;
}
| |
55,545 | js_number_constructor | bluesky950520[P]quickjs/quickjs.c | static JSValue js_number_constructor(JSContext *ctx, JSValue new_target,
int argc, JSValue *argv)
{
JSValue val, obj;
if (argc == 0) {
val = js_int32(0);
} else {
val = JS_ToNumeric(ctx, argv[0]);
if (JS_IsException(val))
return val;
switch(JS_VALUE_GET_TAG(val)) {
case JS_TAG_BIG_INT:
{
JSBigInt *p = JS_VALUE_GET_PTR(val);
double d;
bf_get_float64(&p->num, &d, BF_RNDN);
JS_FreeValue(ctx, val);
val = js_float64(d);
}
break;
default:
break;
}
}
if (!JS_IsUndefined(new_target)) {
obj = js_create_from_ctor(ctx, new_target, JS_CLASS_NUMBER);
if (!JS_IsException(obj))
JS_SetObjectData(ctx, obj, val);
return obj;
} else {
return val;
}
} | O1 | c | js_number_constructor:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
testl %ecx, %ecx
je 0x388cf
movq (%r8), %rsi
movq 0x8(%r8), %rdx
movq %rsi, 0x8(%rsp)
cmpl $-0x9, %edx
jb 0x38875
movq 0x8(%rsp), %rax
incl (%rax)
movq %rbx, %rdi
movl $0x1, %ecx
callq 0x42b20
movq %rdx, %r12
movq %rax, 0x8(%rsp)
cmpl $0x6, %r12d
je 0x388dc
cmpl $-0x9, %r12d
jne 0x388e1
movq 0x8(%rsp), %r13
leaq 0x8(%r13), %rdi
leaq 0x10(%rsp), %rbp
movq %rbp, %rsi
xorl %edx, %edx
callq 0x884ee
movq 0x18(%rbx), %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x1d8c6
movsd (%rbp), %xmm0
movsd %xmm0, 0x8(%rsp)
movl $0x7, %ebp
jmp 0x388e4
movq $0x0, 0x8(%rsp)
xorl %ebp, %ebp
jmp 0x388e4
movq %rax, %r13
jmp 0x38929
movq %r12, %rbp
cmpl $0x3, %r14d
jne 0x388f4
movq 0x8(%rsp), %r13
movq %rbp, %r12
jmp 0x38929
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
movl $0x4, %ecx
callq 0x36d56
movq %rax, %r13
movq %rdx, %r12
cmpl $0x6, %r12d
je 0x38929
movq 0x8(%rsp), %rcx
movq %rbx, %rdi
movq %r13, %rsi
movq %r12, %rdx
movq %rbp, %r8
callq 0x36e62
movq %r13, %rax
movq %r12, %rdx
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| js_number_constructor:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov r14, rdx
mov r15, rsi
mov rbx, rdi
test ecx, ecx
jz short loc_388CF
mov rsi, [r8]
mov rdx, [r8+8]
mov [rsp+48h+var_40], rsi
cmp edx, 0FFFFFFF7h
jb short loc_38875
mov rax, [rsp+48h+var_40]
inc dword ptr [rax]
loc_38875:
mov rdi, rbx
mov ecx, 1
call JS_ToNumberHintFree
mov r12, rdx
mov [rsp+48h+var_40], rax
cmp r12d, 6
jz short loc_388DC
cmp r12d, 0FFFFFFF7h
jnz short loc_388E1
mov r13, [rsp+48h+var_40]
lea rdi, [r13+8]
lea rbp, [rsp+48h+var_38]
mov rsi, rbp
xor edx, edx
call bf_get_float64
mov rdi, [rbx+18h]
mov rsi, r13
mov rdx, r12
call JS_FreeValueRT
movsd xmm0, qword ptr [rbp+0]
movsd [rsp+48h+var_40], xmm0
mov ebp, 7
jmp short loc_388E4
loc_388CF:
mov [rsp+48h+var_40], 0
xor ebp, ebp
jmp short loc_388E4
loc_388DC:
mov r13, rax
jmp short loc_38929
loc_388E1:
mov rbp, r12
loc_388E4:
cmp r14d, 3
jnz short loc_388F4
mov r13, [rsp+48h+var_40]
mov r12, rbp
jmp short loc_38929
loc_388F4:
mov rdi, rbx
mov rsi, r15
mov rdx, r14
mov ecx, 4
call js_create_from_ctor
mov r13, rax
mov r12, rdx
cmp r12d, 6
jz short loc_38929
mov rcx, [rsp+48h+var_40]
mov rdi, rbx
mov rsi, r13
mov rdx, r12
mov r8, rbp
call JS_SetObjectData
loc_38929:
mov rax, r13
mov rdx, r12
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| _DWORD * js_number_constructor(
long long a1,
long long a2,
long long a3,
int a4,
_QWORD *a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
double a10,
double a11,
__m128 a12,
__m128 a13)
{
_DWORD *v15; // rsi
long long v16; // rdx
long long v17; // rax
long long v18; // rdx
long long v19; // r12
long long v20; // rbp
unsigned long long v21; // r13
unsigned long long v22; // rax
int v23; // edx
long long v24; // r9
double v25; // xmm4_8
double v26; // xmm5_8
char v28; // [rsp+0h] [rbp-48h]
_DWORD *v29; // [rsp+8h] [rbp-40h]
_DWORD *v30; // [rsp+10h] [rbp-38h] BYREF
if ( a4 )
{
v15 = (_DWORD *)*a5;
v16 = a5[1];
if ( (unsigned int)v16 >= 0xFFFFFFF7 )
++*(_DWORD *)*a5;
v17 = JS_ToNumberHintFree(a1, v15, v16, 1LL);
v19 = v18;
v29 = (_DWORD *)v17;
if ( (_DWORD)v18 == 6 )
return (_DWORD *)v17;
if ( (_DWORD)v18 == -9 )
{
bf_get_float64(v17 + 8, &v30, 0LL);
JS_FreeValueRT(*(_QWORD *)(a1 + 24), v29, v19);
a6 = (__m128)(unsigned long long)v30;
v29 = v30;
v20 = 7LL;
}
else
{
v20 = v18;
}
}
else
{
v29 = 0LL;
v20 = 0LL;
}
if ( (_DWORD)a3 == 3 )
return v29;
v22 = js_create_from_ctor(a1, a2, a3, 4);
v21 = v22;
if ( v23 != 6 )
JS_SetObjectData(a1, v22, v23, v29, v20, a6, a7, a8, a9, v25, v26, a12, a13, v24, v28);
return (_DWORD *)v21;
}
| js_number_constructor:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
TEST ECX,ECX
JZ 0x001388cf
MOV RSI,qword ptr [R8]
MOV RDX,qword ptr [R8 + 0x8]
MOV qword ptr [RSP + 0x8],RSI
CMP EDX,-0x9
JC 0x00138875
MOV RAX,qword ptr [RSP + 0x8]
INC dword ptr [RAX]
LAB_00138875:
MOV RDI,RBX
MOV ECX,0x1
CALL 0x00142b20
MOV R12,RDX
MOV qword ptr [RSP + 0x8],RAX
CMP R12D,0x6
JZ 0x001388dc
CMP R12D,-0x9
JNZ 0x001388e1
MOV R13,qword ptr [RSP + 0x8]
LEA RDI,[R13 + 0x8]
LEA RBP,[RSP + 0x10]
MOV RSI,RBP
XOR EDX,EDX
CALL 0x001884ee
MOV RDI,qword ptr [RBX + 0x18]
MOV RSI,R13
MOV RDX,R12
CALL 0x0011d8c6
MOVSD XMM0,qword ptr [RBP]
MOVSD qword ptr [RSP + 0x8],XMM0
MOV EBP,0x7
JMP 0x001388e4
LAB_001388cf:
MOV qword ptr [RSP + 0x8],0x0
XOR EBP,EBP
JMP 0x001388e4
LAB_001388dc:
MOV R13,RAX
JMP 0x00138929
LAB_001388e1:
MOV RBP,R12
LAB_001388e4:
CMP R14D,0x3
JNZ 0x001388f4
MOV R13,qword ptr [RSP + 0x8]
MOV R12,RBP
JMP 0x00138929
LAB_001388f4:
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R14
MOV ECX,0x4
CALL 0x00136d56
MOV R13,RAX
MOV R12,RDX
CMP R12D,0x6
JZ 0x00138929
MOV RCX,qword ptr [RSP + 0x8]
MOV RDI,RBX
MOV RSI,R13
MOV RDX,R12
MOV R8,RBP
CALL 0x00136e62
LAB_00138929:
MOV RAX,R13
MOV RDX,R12
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int1 [16]
js_number_constructor
(long param_1,int8 param_2,int8 param_3,int param_4,int8 *param_5)
{
int *piVar1;
int8 uVar2;
int1 auVar3 [16];
int8 local_40;
long local_38;
if (param_4 == 0) {
auVar3 = ZEXT816(0);
}
else {
piVar1 = (int *)*param_5;
uVar2 = param_5[1];
if (0xfffffff6 < (uint)uVar2) {
*piVar1 = *piVar1 + 1;
}
auVar3 = JS_ToNumberHintFree(param_1,piVar1,uVar2,1);
if (auVar3._8_4_ == 6) {
return auVar3;
}
if (auVar3._8_4_ == -9) {
bf_get_float64(auVar3._0_8_ + 8,&local_38,0);
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),auVar3._0_8_,auVar3._8_8_);
auVar3._8_8_ = 7;
auVar3._0_8_ = local_38;
}
}
uVar2 = auVar3._8_8_;
local_40 = auVar3._0_8_;
if ((int)param_3 != 3) {
auVar3 = js_create_from_ctor(param_1,param_2,param_3,4);
if (auVar3._8_4_ != 6) {
JS_SetObjectData(param_1,auVar3._0_8_,auVar3._8_8_,local_40,uVar2);
}
}
return auVar3;
}
| |
55,546 | js_number_constructor | bluesky950520[P]quickjs/quickjs.c | static JSValue js_number_constructor(JSContext *ctx, JSValue new_target,
int argc, JSValue *argv)
{
JSValue val, obj;
if (argc == 0) {
val = js_int32(0);
} else {
val = JS_ToNumeric(ctx, argv[0]);
if (JS_IsException(val))
return val;
switch(JS_VALUE_GET_TAG(val)) {
case JS_TAG_BIG_INT:
{
JSBigInt *p = JS_VALUE_GET_PTR(val);
double d;
bf_get_float64(&p->num, &d, BF_RNDN);
JS_FreeValue(ctx, val);
val = js_float64(d);
}
break;
default:
break;
}
}
if (!JS_IsUndefined(new_target)) {
obj = js_create_from_ctor(ctx, new_target, JS_CLASS_NUMBER);
if (!JS_IsException(obj))
JS_SetObjectData(ctx, obj, val);
return obj;
} else {
return val;
}
} | O2 | c | js_number_constructor:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
testl %ecx, %ecx
je 0x31ae2
movq (%r8), %rsi
movq 0x8(%r8), %rdx
cmpl $-0x9, %edx
jb 0x31a9c
incl (%rsi)
movq %rbx, %rdi
callq 0x3a3be
movq %rax, %r12
movq %rdx, %r13
cmpl $0x6, %r13d
je 0x31aee
cmpl $-0x9, %r13d
jne 0x31ae8
movq %r12, %rdi
addq $0x8, %rdi
movq %rsp, %rbp
movq %rbp, %rsi
xorl %edx, %edx
callq 0x723c2
movq %rbx, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x1801e
movq (%rbp), %r12
pushq $0x7
popq %r13
jmp 0x31ae8
xorl %r12d, %r12d
xorl %r13d, %r13d
cmpl $0x3, %r14d
jne 0x31af6
movq %r12, %r14
movq %r13, %r15
jmp 0x31b27
pushq $0x4
popq %rcx
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x3045a
movq %rax, %r14
movq %rdx, %r15
cmpl $0x6, %r15d
je 0x31b27
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
movq %r12, %rcx
movq %r13, %r8
callq 0x3055c
movq %r14, %rax
movq %r15, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| js_number_constructor:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r14, rdx
mov r15, rsi
mov rbx, rdi
test ecx, ecx
jz short loc_31AE2
mov rsi, [r8]
mov rdx, [r8+8]
cmp edx, 0FFFFFFF7h
jb short loc_31A9C
inc dword ptr [rsi]
loc_31A9C:
mov rdi, rbx
call JS_ToNumericFree
mov r12, rax
mov r13, rdx
cmp r13d, 6
jz short loc_31AEE
cmp r13d, 0FFFFFFF7h
jnz short loc_31AE8
mov rdi, r12
add rdi, 8
mov rbp, rsp
mov rsi, rbp
xor edx, edx
call bf_get_float64
mov rdi, rbx
mov rsi, r12
mov rdx, r13
call JS_FreeValue
mov r12, [rbp+0]
push 7
pop r13
jmp short loc_31AE8
loc_31AE2:
xor r12d, r12d
xor r13d, r13d
loc_31AE8:
cmp r14d, 3
jnz short loc_31AF6
loc_31AEE:
mov r14, r12
mov r15, r13
jmp short loc_31B27
loc_31AF6:
push 4
pop rcx
mov rdi, rbx
mov rsi, r15
mov rdx, r14
call js_create_from_ctor
mov r14, rax
mov r15, rdx
cmp r15d, 6
jz short loc_31B27
mov rdi, rbx
mov rsi, r14
mov rdx, r15
mov rcx, r12
mov r8, r13
call JS_SetObjectData
loc_31B27:
mov rax, r14
mov rdx, r15
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long js_number_constructor(
long long a1,
long long a2,
long long a3,
int a4,
long long a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
double a10,
double a11,
__m128 a12,
__m128 a13)
{
long long v13; // rax
_DWORD *v16; // rsi
long long v17; // rax
long long v18; // rdx
long long v19; // r12
long long v20; // r13
unsigned long long v21; // r14
unsigned long long v22; // rax
int v23; // edx
long long v24; // r9
double v25; // xmm4_8
double v26; // xmm5_8
long long v28; // [rsp-8h] [rbp-38h] BYREF
v28 = v13;
if ( a4 )
{
v16 = *(_DWORD **)a5;
if ( (unsigned int)*(_QWORD *)(a5 + 8) >= 0xFFFFFFF7 )
++*v16;
v17 = JS_ToNumericFree(a1, v16);
v19 = v17;
v20 = v18;
if ( (_DWORD)v18 == 6 )
return v19;
if ( (_DWORD)v18 == -9 )
{
bf_get_float64(v17 + 8, &v28, 0LL);
JS_FreeValue(a1, v19, v20);
v19 = v28;
v20 = 7LL;
}
}
else
{
v19 = 0LL;
v20 = 0LL;
}
if ( (_DWORD)a3 == 3 )
return v19;
v22 = js_create_from_ctor(a1, a2, a3, 4);
v21 = v22;
if ( v23 != 6 )
JS_SetObjectData(a1, v22, v23, v19, v20, a6, a7, a8, a9, v25, v26, a12, a13, v24, v28);
return v21;
}
| js_number_constructor:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
TEST ECX,ECX
JZ 0x00131ae2
MOV RSI,qword ptr [R8]
MOV RDX,qword ptr [R8 + 0x8]
CMP EDX,-0x9
JC 0x00131a9c
INC dword ptr [RSI]
LAB_00131a9c:
MOV RDI,RBX
CALL 0x0013a3be
MOV R12,RAX
MOV R13,RDX
CMP R13D,0x6
JZ 0x00131aee
CMP R13D,-0x9
JNZ 0x00131ae8
MOV RDI,R12
ADD RDI,0x8
MOV RBP,RSP
MOV RSI,RBP
XOR EDX,EDX
CALL 0x001723c2
MOV RDI,RBX
MOV RSI,R12
MOV RDX,R13
CALL 0x0011801e
MOV R12,qword ptr [RBP]
PUSH 0x7
POP R13
JMP 0x00131ae8
LAB_00131ae2:
XOR R12D,R12D
XOR R13D,R13D
LAB_00131ae8:
CMP R14D,0x3
JNZ 0x00131af6
LAB_00131aee:
MOV R14,R12
MOV R15,R13
JMP 0x00131b27
LAB_00131af6:
PUSH 0x4
POP RCX
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R14
CALL 0x0013045a
MOV R14,RAX
MOV R15,RDX
CMP R15D,0x6
JZ 0x00131b27
MOV RDI,RBX
MOV RSI,R14
MOV RDX,R15
MOV RCX,R12
MOV R8,R13
CALL 0x0013055c
LAB_00131b27:
MOV RAX,R14
MOV RDX,R15
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int1 [16]
js_number_constructor
(int8 param_1,int8 param_2,int8 param_3,int param_4,int8 *param_5)
{
long in_RAX;
int8 uVar1;
int8 uVar2;
int1 auVar3 [16];
long local_38;
if (param_4 == 0) {
auVar3 = ZEXT816(0);
}
else {
if (0xfffffff6 < (uint)param_5[1]) {
*(int *)*param_5 = *(int *)*param_5 + 1;
}
local_38 = in_RAX;
auVar3 = JS_ToNumericFree(param_1);
if (auVar3._8_4_ == 6) {
return auVar3;
}
if (auVar3._8_4_ == -9) {
bf_get_float64(auVar3._0_8_ + 8,&local_38,0);
JS_FreeValue(param_1,auVar3._0_8_,auVar3._8_8_);
auVar3._8_8_ = 7;
auVar3._0_8_ = local_38;
}
}
uVar2 = auVar3._8_8_;
uVar1 = auVar3._0_8_;
if ((int)param_3 != 3) {
auVar3 = js_create_from_ctor(param_1,param_2,param_3,4);
if (auVar3._8_4_ != 6) {
JS_SetObjectData(param_1,auVar3._0_8_,auVar3._8_8_,uVar1,uVar2);
}
}
return auVar3;
}
| |
55,547 | metrics::Counter::inc(double) | nickolajgrishuk[P]metricz-cpp/examples/../include/metrics.hpp | void inc(double v = 1.0) {
std::lock_guard<std::mutex> lock(mutex_);
value_ += v;
} | O1 | cpp | metrics::Counter::inc(double):
pushq %r14
pushq %rbx
pushq %rax
movsd %xmm0, (%rsp)
movq %rdi, %r14
leaq 0x60(%rdi), %rbx
movq %rbx, %rdi
callq 0x3250
testl %eax, %eax
jne 0x4080
movsd (%rsp), %xmm0
addsd 0x88(%r14), %xmm0
movsd %xmm0, 0x88(%r14)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x3160
movl %eax, %edi
callq 0x3110
nop
| _ZN7metrics7Counter3incEd:
push r14
push rbx
push rax
movsd [rsp+18h+var_18], xmm0
mov r14, rdi
lea rbx, [rdi+60h]
mov rdi, rbx
call _pthread_mutex_lock
test eax, eax
jnz short loc_4080
movsd xmm0, [rsp+18h+var_18]
addsd xmm0, qword ptr [r14+88h]
movsd qword ptr [r14+88h], xmm0
mov rdi, rbx
add rsp, 8
pop rbx
pop r14
jmp _pthread_mutex_unlock
loc_4080:
mov edi, eax; int
call __ZSt20__throw_system_errori; std::__throw_system_error(int)
| long long metrics::Counter::inc(metrics::Counter *this, double a2)
{
int v2; // eax
v2 = pthread_mutex_lock((char *)this + 96);
if ( v2 )
std::__throw_system_error(v2);
*((double *)this + 17) = a2 + *((double *)this + 17);
return pthread_mutex_unlock((char *)this + 96);
}
| inc:
PUSH R14
PUSH RBX
PUSH RAX
MOVSD qword ptr [RSP],XMM0
MOV R14,RDI
LEA RBX,[RDI + 0x60]
MOV RDI,RBX
CALL 0x00103250
TEST EAX,EAX
JNZ 0x00104080
MOVSD XMM0,qword ptr [RSP]
ADDSD XMM0,qword ptr [R14 + 0x88]
MOVSD qword ptr [R14 + 0x88],XMM0
MOV RDI,RBX
ADD RSP,0x8
POP RBX
POP R14
JMP 0x00103160
LAB_00104080:
MOV EDI,EAX
CALL 0x00103110
|
/* metrics::Counter::inc(double) */
void __thiscall metrics::Counter::inc(Counter *this,double param_1)
{
int iVar1;
iVar1 = pthread_mutex_lock((pthread_mutex_t *)(this + 0x60));
if (iVar1 == 0) {
*(double *)(this + 0x88) = param_1 + *(double *)(this + 0x88);
pthread_mutex_unlock((pthread_mutex_t *)(this + 0x60));
return;
}
/* WARNING: Subroutine does not return */
std::__throw_system_error(iVar1);
}
| |
55,548 | nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp) | monkey531[P]llama/common/json.hpp | inline void grisu2(char* buf, int& len, int& decimal_exponent,
diyfp m_minus, diyfp v, diyfp m_plus)
{
JSON_ASSERT(m_plus.e == m_minus.e);
JSON_ASSERT(m_plus.e == v.e);
// --------(-----------------------+-----------------------)-------- (A)
// m- v m+
//
// --------------------(-----------+-----------------------)-------- (B)
// m- v m+
//
// First scale v (and m- and m+) such that the exponent is in the range
// [alpha, gamma].
const cached_power cached = get_cached_power_for_binary_exponent(m_plus.e);
const diyfp c_minus_k(cached.f, cached.e); // = c ~= 10^-k
// The exponent of the products is = v.e + c_minus_k.e + q and is in the range [alpha,gamma]
const diyfp w = diyfp::mul(v, c_minus_k);
const diyfp w_minus = diyfp::mul(m_minus, c_minus_k);
const diyfp w_plus = diyfp::mul(m_plus, c_minus_k);
// ----(---+---)---------------(---+---)---------------(---+---)----
// w- w w+
// = c*m- = c*v = c*m+
//
// diyfp::mul rounds its result and c_minus_k is approximated too. w, w- and
// w+ are now off by a small amount.
// In fact:
//
// w - v * 10^k < 1 ulp
//
// To account for this inaccuracy, add resp. subtract 1 ulp.
//
// --------+---[---------------(---+---)---------------]---+--------
// w- M- w M+ w+
//
// Now any number in [M-, M+] (bounds included) will round to w when input,
// regardless of how the input rounding algorithm breaks ties.
//
// And digit_gen generates the shortest possible such number in [M-, M+].
// Note that this does not mean that Grisu2 always generates the shortest
// possible number in the interval (m-, m+).
const diyfp M_minus(w_minus.f + 1, w_minus.e);
const diyfp M_plus (w_plus.f - 1, w_plus.e );
decimal_exponent = -cached.k; // = -(-k) = k
grisu2_digit_gen(buf, len, decimal_exponent, M_minus, w, M_plus);
} | O1 | cpp | nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rdi, %rax
movq %rcx, 0x58(%rsp)
movl %r8d, 0x60(%rsp)
movl 0xc8(%rsp), %edi
cmpl %r8d, %edi
jne 0x55654
movq %rax, 0x20(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
leaq 0xb0(%rsp), %r13
cmpl 0x8(%r13), %edi
jne 0x55670
callq 0x5572b
movq %rdx, %r12
leaq 0x68(%rsp), %r14
movq %rax, (%r14)
movl %r12d, 0x8(%r14)
movq %r13, %rdi
movq %r14, %rsi
callq 0x5586c
movq %rax, %r15
movl %edx, %ebx
leaq 0x58(%rsp), %rdi
movq %r14, %rsi
callq 0x5586c
movq %rax, %r13
movl %edx, %ebp
leaq 0xc0(%rsp), %rdi
movq %r14, %rsi
callq 0x5586c
incq %r13
decq %rax
shrq $0x20, %r12
negl %r12d
movq 0x30(%rsp), %rcx
movl %r12d, (%rcx)
movq %r15, 0x48(%rsp)
movl %ebx, 0x50(%rsp)
movq %rax, 0x38(%rsp)
movl %edx, 0x40(%rsp)
movups 0x38(%rsp), %xmm0
movups %xmm0, 0x10(%rsp)
movups 0x48(%rsp), %xmm0
movups %xmm0, (%rsp)
movq 0x20(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq %rcx, %rdx
movq %r13, %rcx
movl %ebp, %r8d
callq 0x558c8
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x64dd7(%rip), %rdi # 0xba432
leaq 0x60768(%rip), %rdx # 0xb5dca
leaq 0x65ddb(%rip), %rcx # 0xbb444
movl $0x454b, %esi # imm = 0x454B
jmp 0x5568a
leaq 0x64dbb(%rip), %rdi # 0xba432
leaq 0x6074c(%rip), %rdx # 0xb5dca
leaq 0x65dd5(%rip), %rcx # 0xbb45a
movl $0x454c, %esi # imm = 0x454C
xorl %eax, %eax
callq 0x19b10
nop
| _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl6grisu2EPcRiS4_NS2_5diyfpES5_S5_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 78h
mov rax, rdi
mov [rsp+0A8h+var_50], rcx
mov [rsp+0A8h+var_48], r8d
mov edi, dword ptr [rsp+0A8h+arg_18]; this
cmp edi, r8d
jnz loc_55654
mov [rsp+0A8h+var_88], rax
mov [rsp+0A8h+var_80], rsi
mov [rsp+0A8h+var_78], rdx
lea r13, [rsp+0A8h+arg_0]
cmp edi, [r13+8]
jnz loc_55670
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl36get_cached_power_for_binary_exponentEi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)
mov r12, rdx
lea r14, [rsp+0A8h+var_40]
mov [r14], rax
mov [r14+8], r12d
mov rdi, r13
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r15, rax
mov ebx, edx
lea rdi, [rsp+0A8h+var_50]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r13, rax
mov ebp, edx
lea rdi, [rsp+0A8h+arg_10]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
inc r13
dec rax
shr r12, 20h
neg r12d
mov rcx, [rsp+0A8h+var_78]
mov [rcx], r12d
mov qword ptr [rsp+0A8h+var_60], r15
mov dword ptr [rsp+0A8h+var_60+8], ebx
mov qword ptr [rsp+0A8h+var_70], rax
mov dword ptr [rsp+0A8h+var_70+8], edx
movups xmm0, [rsp+0A8h+var_70]
movups [rsp+0A8h+var_98], xmm0
movups xmm0, [rsp+0A8h+var_60]
movups [rsp+0A8h+var_A8], xmm0
mov rdi, [rsp+0A8h+var_88]
mov rsi, [rsp+0A8h+var_80]
mov rdx, rcx
mov rcx, r13
mov r8d, ebp
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl16grisu2_digit_genEPcRiS4_NS2_5diyfpES5_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(char *,int &,int &,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
add rsp, 78h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_55654:
lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEMMinusE; "m_plus.e == m_minus.e"
mov esi, 454Bh
jmp short loc_5568A
loc_55670:
lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEVE; "m_plus.e == v.e"
mov esi, 454Ch
loc_5568A:
xor eax, eax
call _ggml_abort
nop
| long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(
int a1,
int a2,
_DWORD *a3,
long long a4,
int a5,
int a6,
char a7,
int a8,
char a9,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *a10)
{
long long cached_power_for_binary_exponent; // rax
int v11; // rdx^4
int v12; // r12^4
int v13; // edx
char v14; // r15
int v15; // edx
int v16; // ebx
int v17; // r13d
int v18; // edx
int v19; // ebp
char v20; // al
int v21; // edx
int v22; // r9d
long long v24; // rsi
long long v26; // [rsp+58h] [rbp-50h] BYREF
int v27; // [rsp+60h] [rbp-48h]
long long v28; // [rsp+68h] [rbp-40h] BYREF
int v29; // [rsp+70h] [rbp-38h]
v26 = a4;
v27 = a5;
if ( (_DWORD)a10 == a5 )
{
if ( (_DWORD)a10 == a8 )
{
cached_power_for_binary_exponent = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)(unsigned int)a10,
a2);
v12 = v11;
v28 = cached_power_for_binary_exponent;
v29 = v13;
v14 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a7, &v28);
v16 = v15;
v17 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&v26, &v28);
v19 = v18;
v20 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a9, &v28);
*a3 = -v12;
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(
a1,
a2,
(_DWORD)a3,
v17 + 1,
v19,
v22,
v14,
v16,
v20 - 1,
v21);
}
v24 = 17740LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17740LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == v.e");
}
else
{
v24 = 17739LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17739LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == m_minus.e");
}
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::normalize(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
v24);
}
| grisu2:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x78
MOV RAX,RDI
MOV qword ptr [RSP + 0x58],RCX
MOV dword ptr [RSP + 0x60],R8D
MOV EDI,dword ptr [RSP + 0xc8]
CMP EDI,R8D
JNZ 0x00155654
MOV qword ptr [RSP + 0x20],RAX
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x30],RDX
LEA R13,[RSP + 0xb0]
CMP EDI,dword ptr [R13 + 0x8]
JNZ 0x00155670
CALL 0x0015572b
MOV R12,RDX
LEA R14,[RSP + 0x68]
MOV qword ptr [R14],RAX
MOV dword ptr [R14 + 0x8],R12D
MOV RDI,R13
MOV RSI,R14
CALL 0x0015586c
MOV R15,RAX
MOV EBX,EDX
LEA RDI,[RSP + 0x58]
MOV RSI,R14
CALL 0x0015586c
MOV R13,RAX
MOV EBP,EDX
LEA RDI,[RSP + 0xc0]
MOV RSI,R14
CALL 0x0015586c
INC R13
DEC RAX
SHR R12,0x20
NEG R12D
MOV RCX,qword ptr [RSP + 0x30]
MOV dword ptr [RCX],R12D
MOV qword ptr [RSP + 0x48],R15
MOV dword ptr [RSP + 0x50],EBX
MOV qword ptr [RSP + 0x38],RAX
MOV dword ptr [RSP + 0x40],EDX
MOVUPS XMM0,xmmword ptr [RSP + 0x38]
MOVUPS xmmword ptr [RSP + 0x10],XMM0
MOVUPS XMM0,xmmword ptr [RSP + 0x48]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,RCX
MOV RCX,R13
MOV R8D,EBP
CALL 0x001558c8
ADD RSP,0x78
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00155654:
LEA RDI,[0x1ba432]
LEA RDX,[0x1b5dca]
LEA RCX,[0x1bb444]
MOV ESI,0x454b
JMP 0x0015568a
LAB_00155670:
LEA RDI,[0x1ba432]
LEA RDX,[0x1b5dca]
LEA RCX,[0x1bb45a]
MOV ESI,0x454c
LAB_0015568a:
XOR EAX,EAX
CALL 0x00119b10
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp) */
void nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2
(int8 param_1,int8 param_2,int *param_3,int8 param_4,int param_5,
int8 param_6,int8 param_7,int param_8,int8 param_9,int param_10)
{
int4 uVar1;
char *pcVar2;
int4 extraout_EDX;
int8 uVar3;
int1 auVar4 [12];
int1 auVar5 [12];
int1 auVar6 [16];
int4 uStack_64;
int8 local_50;
int local_48;
int8 local_40;
int4 local_38;
local_50 = param_4;
local_48 = param_5;
if (param_10 == param_5) {
if (param_10 == param_8) {
auVar6 = get_cached_power_for_binary_exponent(param_10);
local_40 = auVar6._0_8_;
local_38 = auVar6._8_4_;
uVar1 = diyfp::mul((diyfp *)¶m_7,(diyfp *)&local_40);
auVar4 = diyfp::mul((diyfp *)&local_50,(diyfp *)&local_40);
auVar5 = diyfp::mul((diyfp *)¶m_9,(diyfp *)&local_40);
*param_3 = -auVar6._12_4_;
grisu2_digit_gen(param_1,param_2,param_3,auVar4._0_8_ + 1,auVar4._8_4_,param_6,uVar1,
extraout_EDX,auVar5._0_8_ + -1,CONCAT44(uStack_64,auVar5._8_4_));
return;
}
pcVar2 = "m_plus.e == v.e";
uVar3 = 0x454c;
}
else {
pcVar2 = "m_plus.e == m_minus.e";
uVar3 = 0x454b;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
| |
55,549 | LefDefParser::defwPinStr(char const*, char const*, int, char const*, char const*, char const*, int, int, char const*, char const*, int, int, int, int) | Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/def/def/defwWriter.cpp | int
defwPinStr(const char *name,
const char *net,
int special, // optional 0-ignore 1-special
const char *direction, // optional
const char *use, // optional
const char *status,
int xo,
int yo,
const char *orient, // optional
const char *layer,
int xl,
int yl,
int xh,
int yh // optional
)
{
defwFunc = DEFW_PIN; // Current function of writer
if (!defwFile)
return DEFW_UNINITIALIZED;
if (defwState != DEFW_PIN_START && defwState != DEFW_PIN)
return DEFW_BAD_ORDER;
defwCounter--;
fprintf(defwFile, " ;\n - %s + NET %s", name, net);
if (special)
fprintf(defwFile, "\n + SPECIAL");
if (direction) {
if (strcmp(direction, "INPUT") && strcmp(direction, "OUTPUT") &&
strcmp(direction, "INOUT") && strcmp(direction, "FEEDTHRU"))
return DEFW_BAD_DATA;
fprintf(defwFile, "\n + DIRECTION %s", direction);
}
if (use) {
if (strcmp(use, "SIGNAL") && strcmp(use, "POWER") &&
strcmp(use, "GROUND") && strcmp(use, "CLOCK") &&
strcmp(use, "TIEOFF") && strcmp(use, "ANALOG") &&
strcmp(use, "SCAN") && strcmp(use, "RESET"))
return DEFW_BAD_DATA;
fprintf(defwFile, "\n + USE %s", use);
}
if (status) {
if (strcmp(status, "FIXED") && strcmp(status, "PLACED") &&
strcmp(status, "COVER"))
return DEFW_BAD_DATA;
fprintf(defwFile, "\n + %s ( %d %d ) %s", status, xo, yo,
orient);
}
// In 5.6, user should use defPinLayer to write out layer construct
if (layer) {
fprintf(defwFile, "\n + LAYER %s ( %d %d ) ( %d %d )",
layer, xl, yl, xh, yh);
}
defwLines++;
defwState = DEFW_PIN;
return DEFW_OK;
} | O0 | cpp | LefDefParser::defwPinStr(char const*, char const*, int, char const*, char const*, char const*, int, int, char const*, char const*, int, int, int, int):
subq $0x48, %rsp
movl 0x88(%rsp), %eax
movl 0x80(%rsp), %eax
movl 0x78(%rsp), %eax
movl 0x70(%rsp), %eax
movq 0x68(%rsp), %rax
movq 0x60(%rsp), %rax
movl 0x58(%rsp), %eax
movl 0x50(%rsp), %eax
movq %rdi, 0x38(%rsp)
movq %rsi, 0x30(%rsp)
movl %edx, 0x2c(%rsp)
movq %rcx, 0x20(%rsp)
movq %r8, 0x18(%rsp)
movq %r9, 0x10(%rsp)
leaq 0x158e8(%rip), %rax # 0x2b168
movl $0x25, (%rax)
leaq 0x158cb(%rip), %rax # 0x2b158
cmpq $0x0, (%rax)
jne 0x158a0
movl $0x1, 0x44(%rsp)
jmp 0x15b83
leaq 0x158bd(%rip), %rax # 0x2b164
cmpl $0x24, (%rax)
je 0x158c5
leaq 0x158b1(%rip), %rax # 0x2b164
cmpl $0x25, (%rax)
je 0x158c5
movl $0x2, 0x44(%rsp)
jmp 0x15b83
leaq 0x158ac(%rip), %rax # 0x2b178
movl (%rax), %ecx
addl $-0x1, %ecx
leaq 0x158a0(%rip), %rax # 0x2b178
movl %ecx, (%rax)
leaq 0x15877(%rip), %rax # 0x2b158
movq (%rax), %rdi
movq 0x38(%rsp), %rdx
movq 0x30(%rsp), %rcx
leaq 0xece5(%rip), %rsi # 0x245da
movb $0x0, %al
callq 0x10f0
cmpl $0x0, 0x2c(%rsp)
je 0x1591b
leaq 0x1584e(%rip), %rax # 0x2b158
movq (%rax), %rdi
leaq 0xecda(%rip), %rsi # 0x245ee
movb $0x0, %al
callq 0x10f0
cmpq $0x0, 0x20(%rsp)
je 0x159a9
movq 0x20(%rsp), %rdi
leaq 0xdede(%rip), %rsi # 0x23811
callq 0x10e0
cmpl $0x0, %eax
je 0x1598c
movq 0x20(%rsp), %rdi
leaq 0xdf54(%rip), %rsi # 0x2389d
callq 0x10e0
cmpl $0x0, %eax
je 0x1598c
movq 0x20(%rsp), %rdi
leaq 0xdf52(%rip), %rsi # 0x238b1
callq 0x10e0
cmpl $0x0, %eax
je 0x1598c
movq 0x20(%rsp), %rdi
leaq 0xec8a(%rip), %rsi # 0x245ff
callq 0x10e0
cmpl $0x0, %eax
je 0x1598c
movl $0x3, 0x44(%rsp)
jmp 0x15b83
leaq 0x157c5(%rip), %rax # 0x2b158
movq (%rax), %rdi
movq 0x20(%rsp), %rdx
leaq 0xec66(%rip), %rsi # 0x24608
movb $0x0, %al
callq 0x10f0
cmpq $0x0, 0x18(%rsp)
je 0x15a97
movq 0x18(%rsp), %rdi
leaq 0xde98(%rip), %rsi # 0x23859
callq 0x10e0
cmpl $0x0, %eax
je 0x15a7a
movq 0x18(%rsp), %rdi
leaq 0xde5f(%rip), %rsi # 0x2383a
callq 0x10e0
cmpl $0x0, %eax
je 0x15a7a
movq 0x18(%rsp), %rdi
leaq 0xec29(%rip), %rsi # 0x2461e
callq 0x10e0
cmpl $0x0, %eax
je 0x15a7a
movq 0x18(%rsp), %rdi
leaq 0xdf0f(%rip), %rsi # 0x2391a
callq 0x10e0
cmpl $0x0, %eax
je 0x15a7a
movq 0x18(%rsp), %rdi
leaq 0xec04(%rip), %rsi # 0x24625
callq 0x10e0
cmpl $0x0, %eax
je 0x15a7a
movq 0x18(%rsp), %rdi
leaq 0xebf5(%rip), %rsi # 0x2462c
callq 0x10e0
cmpl $0x0, %eax
je 0x15a7a
movq 0x18(%rsp), %rdi
leaq 0xdddb(%rip), %rsi # 0x23828
callq 0x10e0
cmpl $0x0, %eax
je 0x15a7a
movq 0x18(%rsp), %rdi
leaq 0xddd1(%rip), %rsi # 0x23834
callq 0x10e0
cmpl $0x0, %eax
je 0x15a7a
movl $0x3, 0x44(%rsp)
jmp 0x15b83
leaq 0x156d7(%rip), %rax # 0x2b158
movq (%rax), %rdi
movq 0x18(%rsp), %rdx
leaq 0xeba3(%rip), %rsi # 0x24633
movb $0x0, %al
callq 0x10f0
cmpq $0x0, 0x10(%rsp)
je 0x15b19
movq 0x10(%rsp), %rdi
leaq 0xdcd7(%rip), %rsi # 0x23782
callq 0x10e0
cmpl $0x0, %eax
je 0x15aee
movq 0x10(%rsp), %rdi
leaq 0xdca5(%rip), %rsi # 0x23766
callq 0x10e0
cmpl $0x0, %eax
je 0x15aee
movq 0x10(%rsp), %rdi
leaq 0xdcb9(%rip), %rsi # 0x23790
callq 0x10e0
cmpl $0x0, %eax
je 0x15aee
movl $0x3, 0x44(%rsp)
jmp 0x15b83
leaq 0x15663(%rip), %rax # 0x2b158
movq (%rax), %rdi
movq 0x10(%rsp), %rdx
movl 0x50(%rsp), %ecx
movl 0x58(%rsp), %r8d
movq 0x60(%rsp), %r9
leaq 0xeb31(%rip), %rsi # 0x24643
movb $0x0, %al
callq 0x10f0
cmpq $0x0, 0x68(%rsp)
je 0x15b59
leaq 0x15630(%rip), %rax # 0x2b158
movq (%rax), %rdi
movq 0x68(%rsp), %rdx
movl 0x70(%rsp), %ecx
movl 0x78(%rsp), %r8d
movl 0x80(%rsp), %r9d
movl 0x88(%rsp), %eax
leaq 0xeb0d(%rip), %rsi # 0x2465c
movl %eax, (%rsp)
movb $0x0, %al
callq 0x10f0
leaq 0x15600(%rip), %rax # 0x2b160
movl (%rax), %ecx
addl $0x1, %ecx
leaq 0x155f4(%rip), %rax # 0x2b160
movl %ecx, (%rax)
leaq 0x155ef(%rip), %rax # 0x2b164
movl $0x25, (%rax)
movl $0x0, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopl (%rax)
| _ZN12LefDefParser10defwPinStrEPKcS1_iS1_S1_S1_iiS1_S1_iiii:
sub rsp, 48h
mov eax, [rsp+48h+arg_38]
mov eax, [rsp+48h+arg_30]
mov eax, [rsp+48h+arg_28]
mov eax, dword ptr [rsp+48h+arg_20]
mov rax, [rsp+48h+arg_18]
mov rax, [rsp+48h+arg_10]
mov eax, [rsp+48h+arg_8]
mov eax, dword ptr [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_28], rcx
mov [rsp+48h+var_30], r8
mov [rsp+48h+var_38], r9
lea rax, _ZN12LefDefParser8defwFuncE; LefDefParser::defwFunc
mov dword ptr [rax], 25h ; '%'
lea rax, _ZN12LefDefParser8defwFileE; LefDefParser::defwFile
cmp qword ptr [rax], 0
jnz short loc_158A0
mov [rsp+48h+var_4], 1
jmp loc_15B83
loc_158A0:
lea rax, _ZN12LefDefParser9defwStateE; LefDefParser::defwState
cmp dword ptr [rax], 24h ; '$'
jz short loc_158C5
lea rax, _ZN12LefDefParser9defwStateE; LefDefParser::defwState
cmp dword ptr [rax], 25h ; '%'
jz short loc_158C5
mov [rsp+48h+var_4], 2
jmp loc_15B83
loc_158C5:
lea rax, _ZN12LefDefParser11defwCounterE; LefDefParser::defwCounter
mov ecx, [rax]
add ecx, 0FFFFFFFFh
lea rax, _ZN12LefDefParser11defwCounterE; LefDefParser::defwCounter
mov [rax], ecx
lea rax, _ZN12LefDefParser8defwFileE; LefDefParser::defwFile
mov rdi, [rax]
mov rdx, [rsp+48h+var_10]
mov rcx, [rsp+48h+var_18]
lea rsi, aSNetS; " ;\n - %s + NET %s"
mov al, 0
call _fprintf
cmp [rsp+48h+var_1C], 0
jz short loc_1591B
lea rax, _ZN12LefDefParser8defwFileE; LefDefParser::defwFile
mov rdi, [rax]
lea rsi, aSpecial; "\n + SPECIAL"
mov al, 0
call _fprintf
loc_1591B:
cmp [rsp+48h+var_28], 0
jz loc_159A9
mov rdi, [rsp+48h+var_28]
lea rsi, aInput; "INPUT"
call _strcmp
cmp eax, 0
jz short loc_1598C
mov rdi, [rsp+48h+var_28]
lea rsi, aOutput; "OUTPUT"
call _strcmp
cmp eax, 0
jz short loc_1598C
mov rdi, [rsp+48h+var_28]
lea rsi, aInout; "INOUT"
call _strcmp
cmp eax, 0
jz short loc_1598C
mov rdi, [rsp+48h+var_28]
lea rsi, aFeedthru; "FEEDTHRU"
call _strcmp
cmp eax, 0
jz short loc_1598C
mov [rsp+48h+var_4], 3
jmp loc_15B83
loc_1598C:
lea rax, _ZN12LefDefParser8defwFileE; LefDefParser::defwFile
mov rdi, [rax]
mov rdx, [rsp+48h+var_28]
lea rsi, aDirectionS; "\n + DIRECTION %s"
mov al, 0
call _fprintf
loc_159A9:
cmp [rsp+48h+var_30], 0
jz loc_15A97
mov rdi, [rsp+48h+var_30]
lea rsi, aSignal; "SIGNAL"
call _strcmp
cmp eax, 0
jz loc_15A7A
mov rdi, [rsp+48h+var_30]
lea rsi, aPower; "POWER"
call _strcmp
cmp eax, 0
jz loc_15A7A
mov rdi, [rsp+48h+var_30]
lea rsi, aGround; "GROUND"
call _strcmp
cmp eax, 0
jz short loc_15A7A
mov rdi, [rsp+48h+var_30]
lea rsi, aClock; "CLOCK"
call _strcmp
cmp eax, 0
jz short loc_15A7A
mov rdi, [rsp+48h+var_30]
lea rsi, aTieoff; "TIEOFF"
call _strcmp
cmp eax, 0
jz short loc_15A7A
mov rdi, [rsp+48h+var_30]
lea rsi, aAnalog; "ANALOG"
call _strcmp
cmp eax, 0
jz short loc_15A7A
mov rdi, [rsp+48h+var_30]
lea rsi, aScan; "SCAN"
call _strcmp
cmp eax, 0
jz short loc_15A7A
mov rdi, [rsp+48h+var_30]
lea rsi, aReset; "RESET"
call _strcmp
cmp eax, 0
jz short loc_15A7A
mov [rsp+48h+var_4], 3
jmp loc_15B83
loc_15A7A:
lea rax, _ZN12LefDefParser8defwFileE; LefDefParser::defwFile
mov rdi, [rax]
mov rdx, [rsp+48h+var_30]
lea rsi, aUseS; "\n + USE %s"
mov al, 0
call _fprintf
loc_15A97:
cmp [rsp+48h+var_38], 0
jz short loc_15B19
mov rdi, [rsp+48h+var_38]
lea rsi, aFixed; "FIXED"
call _strcmp
cmp eax, 0
jz short loc_15AEE
mov rdi, [rsp+48h+var_38]
lea rsi, aUnplaced+2; "PLACED"
call _strcmp
cmp eax, 0
jz short loc_15AEE
mov rdi, [rsp+48h+var_38]
lea rsi, aCover; "COVER"
call _strcmp
cmp eax, 0
jz short loc_15AEE
mov [rsp+48h+var_4], 3
jmp loc_15B83
loc_15AEE:
lea rax, _ZN12LefDefParser8defwFileE; LefDefParser::defwFile
mov rdi, [rax]
mov rdx, [rsp+48h+var_38]
mov ecx, dword ptr [rsp+48h+arg_0]
mov r8d, [rsp+48h+arg_8]
mov r9, [rsp+48h+arg_10]
lea rsi, aSDDS_0; "\n + %s ( %d %d ) %s"
mov al, 0
call _fprintf
loc_15B19:
cmp [rsp+48h+arg_18], 0
jz short loc_15B59
lea rax, _ZN12LefDefParser8defwFileE; LefDefParser::defwFile
mov rdi, [rax]
mov rdx, [rsp+48h+arg_18]
mov ecx, dword ptr [rsp+48h+arg_20]
mov r8d, [rsp+48h+arg_28]
mov r9d, [rsp+48h+arg_30]
mov eax, [rsp+48h+arg_38]
lea rsi, aLayerSDDDD; "\n + LAYER %s ( %d %d ) ( %d %d )"
mov [rsp+48h+var_48], eax
mov al, 0
call _fprintf
loc_15B59:
lea rax, _ZN12LefDefParser9defwLinesE; LefDefParser::defwLines
mov ecx, [rax]
add ecx, 1
lea rax, _ZN12LefDefParser9defwLinesE; LefDefParser::defwLines
mov [rax], ecx
lea rax, _ZN12LefDefParser9defwStateE; LefDefParser::defwState
mov dword ptr [rax], 25h ; '%'
mov [rsp+48h+var_4], 0
loc_15B83:
mov eax, [rsp+48h+var_4]
add rsp, 48h
retn
| long long LefDefParser::defwPinStr(
LefDefParser *this,
const char *a2,
const char *a3,
const char *a4,
const char *a5,
const char *a6,
const char *a7,
int a8,
const char *a9,
const char *a10,
const char *a11,
int a12,
int a13,
int a14)
{
int v18; // [rsp+2Ch] [rbp-1Ch]
v18 = (int)a3;
LefDefParser::defwFunc = 37;
if ( LefDefParser::defwFile )
{
if ( LefDefParser::defwState == 36 || LefDefParser::defwState == 37 )
{
--LefDefParser::defwCounter;
fprintf(LefDefParser::defwFile, " ;\n - %s + NET %s", (const char *)this, a2);
if ( v18 )
fprintf(LefDefParser::defwFile, "\n + SPECIAL");
if ( a4 )
{
if ( (unsigned int)strcmp(a4, "INPUT")
&& (unsigned int)strcmp(a4, "OUTPUT")
&& (unsigned int)strcmp(a4, "INOUT")
&& (unsigned int)strcmp(a4, "FEEDTHRU") )
{
return 3;
}
fprintf(LefDefParser::defwFile, "\n + DIRECTION %s", a4);
}
if ( a5 )
{
if ( (unsigned int)strcmp(a5, "SIGNAL")
&& (unsigned int)strcmp(a5, "POWER")
&& (unsigned int)strcmp(a5, "GROUND")
&& (unsigned int)strcmp(a5, "CLOCK")
&& (unsigned int)strcmp(a5, "TIEOFF")
&& (unsigned int)strcmp(a5, "ANALOG")
&& (unsigned int)strcmp(a5, "SCAN")
&& (unsigned int)strcmp(a5, "RESET") )
{
return 3;
}
fprintf(LefDefParser::defwFile, "\n + USE %s", a5);
}
if ( a6 )
{
if ( (unsigned int)strcmp(a6, "FIXED")
&& (unsigned int)strcmp(a6, "PLACED")
&& (unsigned int)strcmp(a6, "COVER") )
{
return 3;
}
fprintf(LefDefParser::defwFile, "\n + %s ( %d %d ) %s", a6, (_DWORD)a7, a8, a9);
}
if ( a10 )
fprintf(LefDefParser::defwFile, "\n + LAYER %s ( %d %d ) ( %d %d )", a10, (_DWORD)a11, a12, a13, a14);
++LefDefParser::defwLines;
LefDefParser::defwState = 37;
return 0;
}
else
{
return 2;
}
}
else
{
return 1;
}
}
| defwPinStr:
SUB RSP,0x48
MOV EAX,dword ptr [RSP + 0x88]
MOV EAX,dword ptr [RSP + 0x80]
MOV EAX,dword ptr [RSP + 0x78]
MOV EAX,dword ptr [RSP + 0x70]
MOV RAX,qword ptr [RSP + 0x68]
MOV RAX,qword 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 qword ptr [RSP + 0x20],RCX
MOV qword ptr [RSP + 0x18],R8
MOV qword ptr [RSP + 0x10],R9
LEA RAX,[0x12b168]
MOV dword ptr [RAX],0x25
LEA RAX,[0x12b158]
CMP qword ptr [RAX],0x0
JNZ 0x001158a0
MOV dword ptr [RSP + 0x44],0x1
JMP 0x00115b83
LAB_001158a0:
LEA RAX,[0x12b164]
CMP dword ptr [RAX],0x24
JZ 0x001158c5
LEA RAX,[0x12b164]
CMP dword ptr [RAX],0x25
JZ 0x001158c5
MOV dword ptr [RSP + 0x44],0x2
JMP 0x00115b83
LAB_001158c5:
LEA RAX,[0x12b178]
MOV ECX,dword ptr [RAX]
ADD ECX,-0x1
LEA RAX,[0x12b178]
MOV dword ptr [RAX],ECX
LEA RAX,[0x12b158]
MOV RDI,qword ptr [RAX]
MOV RDX,qword ptr [RSP + 0x38]
MOV RCX,qword ptr [RSP + 0x30]
LEA RSI,[0x1245da]
MOV AL,0x0
CALL 0x001010f0
CMP dword ptr [RSP + 0x2c],0x0
JZ 0x0011591b
LEA RAX,[0x12b158]
MOV RDI,qword ptr [RAX]
LEA RSI,[0x1245ee]
MOV AL,0x0
CALL 0x001010f0
LAB_0011591b:
CMP qword ptr [RSP + 0x20],0x0
JZ 0x001159a9
MOV RDI,qword ptr [RSP + 0x20]
LEA RSI,[0x123811]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x0011598c
MOV RDI,qword ptr [RSP + 0x20]
LEA RSI,[0x12389d]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x0011598c
MOV RDI,qword ptr [RSP + 0x20]
LEA RSI,[0x1238b1]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x0011598c
MOV RDI,qword ptr [RSP + 0x20]
LEA RSI,[0x1245ff]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x0011598c
MOV dword ptr [RSP + 0x44],0x3
JMP 0x00115b83
LAB_0011598c:
LEA RAX,[0x12b158]
MOV RDI,qword ptr [RAX]
MOV RDX,qword ptr [RSP + 0x20]
LEA RSI,[0x124608]
MOV AL,0x0
CALL 0x001010f0
LAB_001159a9:
CMP qword ptr [RSP + 0x18],0x0
JZ 0x00115a97
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x123859]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115a7a
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x12383a]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115a7a
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x12461e]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115a7a
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x12391a]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115a7a
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x124625]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115a7a
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x12462c]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115a7a
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x123828]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115a7a
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x123834]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115a7a
MOV dword ptr [RSP + 0x44],0x3
JMP 0x00115b83
LAB_00115a7a:
LEA RAX,[0x12b158]
MOV RDI,qword ptr [RAX]
MOV RDX,qword ptr [RSP + 0x18]
LEA RSI,[0x124633]
MOV AL,0x0
CALL 0x001010f0
LAB_00115a97:
CMP qword ptr [RSP + 0x10],0x0
JZ 0x00115b19
MOV RDI,qword ptr [RSP + 0x10]
LEA RSI,[0x123782]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115aee
MOV RDI,qword ptr [RSP + 0x10]
LEA RSI,[0x123766]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115aee
MOV RDI,qword ptr [RSP + 0x10]
LEA RSI,[0x123790]
CALL 0x001010e0
CMP EAX,0x0
JZ 0x00115aee
MOV dword ptr [RSP + 0x44],0x3
JMP 0x00115b83
LAB_00115aee:
LEA RAX,[0x12b158]
MOV RDI,qword ptr [RAX]
MOV RDX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RSP + 0x50]
MOV R8D,dword ptr [RSP + 0x58]
MOV R9,qword ptr [RSP + 0x60]
LEA RSI,[0x124643]
MOV AL,0x0
CALL 0x001010f0
LAB_00115b19:
CMP qword ptr [RSP + 0x68],0x0
JZ 0x00115b59
LEA RAX,[0x12b158]
MOV RDI,qword ptr [RAX]
MOV RDX,qword ptr [RSP + 0x68]
MOV ECX,dword ptr [RSP + 0x70]
MOV R8D,dword ptr [RSP + 0x78]
MOV R9D,dword ptr [RSP + 0x80]
MOV EAX,dword ptr [RSP + 0x88]
LEA RSI,[0x12465c]
MOV dword ptr [RSP],EAX
MOV AL,0x0
CALL 0x001010f0
LAB_00115b59:
LEA RAX,[0x12b160]
MOV ECX,dword ptr [RAX]
ADD ECX,0x1
LEA RAX,[0x12b160]
MOV dword ptr [RAX],ECX
LEA RAX,[0x12b164]
MOV dword ptr [RAX],0x25
MOV dword ptr [RSP + 0x44],0x0
LAB_00115b83:
MOV EAX,dword ptr [RSP + 0x44]
ADD RSP,0x48
RET
|
/* LefDefParser::defwPinStr(char const*, char const*, int, char const*, char const*, char const*,
int, int, char const*, char const*, int, int, int, int) */
int4
LefDefParser::defwPinStr
(char *param_1,char *param_2,int param_3,char *param_4,char *param_5,char *param_6,
int param_7,int param_8,char *param_9,char *param_10,int param_11,int param_12,
int param_13,int param_14)
{
int iVar1;
int4 local_4;
defwFunc = 0x25;
if (defwFile == (FILE *)0x0) {
local_4 = 1;
}
else if ((defwState == 0x24) || (defwState == 0x25)) {
defwCounter = defwCounter + -1;
fprintf(defwFile," ;\n - %s + NET %s",param_1,param_2);
if (param_3 != 0) {
fprintf(defwFile,"\n + SPECIAL");
}
if (param_4 != (char *)0x0) {
iVar1 = strcmp(param_4,"INPUT");
if ((((iVar1 != 0) && (iVar1 = strcmp(param_4,"OUTPUT"), iVar1 != 0)) &&
(iVar1 = strcmp(param_4,"INOUT"), iVar1 != 0)) &&
(iVar1 = strcmp(param_4,"FEEDTHRU"), iVar1 != 0)) {
return 3;
}
fprintf(defwFile,"\n + DIRECTION %s",param_4);
}
if (param_5 != (char *)0x0) {
iVar1 = strcmp(param_5,"SIGNAL");
if ((((iVar1 != 0) && (iVar1 = strcmp(param_5,"POWER"), iVar1 != 0)) &&
((iVar1 = strcmp(param_5,"GROUND"), iVar1 != 0 &&
((iVar1 = strcmp(param_5,"CLOCK"), iVar1 != 0 &&
(iVar1 = strcmp(param_5,"TIEOFF"), iVar1 != 0)))))) &&
((iVar1 = strcmp(param_5,"ANALOG"), iVar1 != 0 &&
((iVar1 = strcmp(param_5,"SCAN"), iVar1 != 0 &&
(iVar1 = strcmp(param_5,"RESET"), iVar1 != 0)))))) {
return 3;
}
fprintf(defwFile,"\n + USE %s",param_5);
}
if (param_6 != (char *)0x0) {
iVar1 = strcmp(param_6,"FIXED");
if (((iVar1 != 0) && (iVar1 = strcmp(param_6,"PLACED"), iVar1 != 0)) &&
(iVar1 = strcmp(param_6,"COVER"), iVar1 != 0)) {
return 3;
}
fprintf(defwFile,"\n + %s ( %d %d ) %s",param_6,(ulong)(uint)param_7,(ulong)(uint)param_8
,param_9);
}
if (param_10 != (char *)0x0) {
fprintf(defwFile,"\n + LAYER %s ( %d %d ) ( %d %d )",param_10,(ulong)(uint)param_11,
(ulong)(uint)param_12,(ulong)(uint)param_13,param_14);
}
defwLines = defwLines + 1;
defwState = 0x25;
local_4 = 0;
}
else {
local_4 = 2;
}
return local_4;
}
| |
55,550 | patricia_verify | corpus-core[P]colibri-stateless/src/chains/eth/verifier/patricia.c | INTERNAL patricia_result_t patricia_verify(bytes32_t root, bytes_t path, ssz_ob_t proof, bytes_t* expected) {
int result = 1;
uint8_t* nibbles = patricia_to_nibbles(path, 0);
uint8_t* key = nibbles;
bytes_t last_value = NULL_BYTES;
bytes32_t expected_hash;
bytes32_t node_hash;
uint32_t proof_len = ssz_len(proof);
size_t depth = 0;
for (uint32_t i = 0; i < proof_len; i++) {
ssz_ob_t witness = ssz_at(proof, i);
keccak(witness.bytes, node_hash);
if (i == 0) {
memcpy(expected_hash, node_hash, 32);
memcpy(root, node_hash, 32);
}
else if (memcmp(expected_hash, node_hash, 32)) {
result = 0;
break;
}
if (1 != (result = handle_node(&witness.bytes, &key, i + 1 == proof_len, &last_value, expected_hash, &depth))) break;
}
if (result && expected)
*expected = result == 2 ? NULL_BYTES : last_value;
if (nibbles) safe_free(nibbles);
return result == 3 ? PATRICIA_FOUND : (patricia_result_t) result;
} | O0 | c | patricia_verify:
pushq %rbp
movq %rsp, %rbp
subq $0x100, %rsp # imm = 0x100
leaq 0x10(%rbp), %rax
movq %rax, -0xd8(%rbp)
movl %esi, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
movq %rdi, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl $0x1, -0x24(%rbp)
movl -0x10(%rbp), %edi
movq -0x8(%rbp), %rsi
xorl %edx, %edx
callq 0x15860
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x38(%rbp)
leaq -0x48(%rbp), %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x5110
movq -0xd8(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x1b380
movl %eax, -0x94(%rbp)
movq $0x0, -0xa0(%rbp)
movl $0x0, -0xa4(%rbp)
movl -0xa4(%rbp), %eax
cmpl -0x94(%rbp), %eax
jae 0x157ae
movq -0xd8(%rbp), %rax
movl -0xa4(%rbp), %esi
leaq -0xc0(%rbp), %rdi
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x1b0d0
leaq -0x90(%rbp), %rdx
movl -0xc0(%rbp), %edi
movq -0xb8(%rbp), %rsi
callq 0x1f4e0
cmpl $0x0, -0xa4(%rbp)
jne 0x1572d
movq -0x90(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x88(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x80(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x78(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x18(%rbp), %rax
movq -0x90(%rbp), %rcx
movq %rcx, (%rax)
movq -0x88(%rbp), %rcx
movq %rcx, 0x8(%rax)
movq -0x80(%rbp), %rcx
movq %rcx, 0x10(%rax)
movq -0x78(%rbp), %rcx
movq %rcx, 0x18(%rax)
jmp 0x15752
leaq -0x70(%rbp), %rdi
leaq -0x90(%rbp), %rsi
movl $0x20, %edx
callq 0x5310
cmpl $0x0, %eax
je 0x15750
movl $0x0, -0x24(%rbp)
jmp 0x157ae
jmp 0x15752
leaq -0xc0(%rbp), %rdi
movl -0xa4(%rbp), %eax
addl $0x1, %eax
cmpl -0x94(%rbp), %eax
sete %al
andb $0x1, %al
movzbl %al, %edx
leaq -0x70(%rbp), %r8
leaq -0x38(%rbp), %rsi
leaq -0x48(%rbp), %rcx
leaq -0xa0(%rbp), %r9
callq 0x15960
movl %eax, %ecx
movl %ecx, -0x24(%rbp)
movl $0x1, %eax
cmpl %ecx, %eax
je 0x15798
jmp 0x157ae
jmp 0x1579a
movl -0xa4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xa4(%rbp)
jmp 0x15676
cmpl $0x0, -0x24(%rbp)
je 0x15817
cmpq $0x0, -0x20(%rbp)
je 0x15817
movq -0x20(%rbp), %rax
movq %rax, -0xe0(%rbp)
cmpl $0x2, -0x24(%rbp)
jne 0x157ff
movq -0xe0(%rbp), %rax
movl $0x0, -0xd0(%rbp)
movq $0x0, -0xc8(%rbp)
movq -0xd0(%rbp), %rcx
movq %rcx, (%rax)
movq -0xc8(%rbp), %rcx
movq %rcx, 0x8(%rax)
jmp 0x15815
movq -0xe0(%rbp), %rax
movq -0x48(%rbp), %rcx
movq %rcx, (%rax)
movq -0x40(%rbp), %rcx
movq %rcx, 0x8(%rax)
jmp 0x15817
cmpq $0x0, -0x30(%rbp)
je 0x15827
movq -0x30(%rbp), %rdi
callq 0x18740
cmpl $0x3, -0x24(%rbp)
jne 0x1583a
movl $0x1, %eax
movl %eax, -0xe4(%rbp)
jmp 0x15843
movl -0x24(%rbp), %eax
movl %eax, -0xe4(%rbp)
movl -0xe4(%rbp), %eax
addq $0x100, %rsp # imm = 0x100
popq %rbp
retq
nopw %cs:(%rax,%rax)
| patricia_verify:
push rbp
mov rbp, rsp
sub rsp, 100h
lea rax, [rbp+arg_0]
mov [rbp+var_D8], rax
mov [rbp+var_10], esi
mov [rbp+var_8], rdx
mov [rbp+var_18], rdi
mov [rbp+var_20], rcx
mov [rbp+var_24], 1
mov edi, [rbp+var_10]
mov rsi, [rbp+var_8]
xor edx, edx
call patricia_to_nibbles
mov [rbp+var_30], rax
mov rax, [rbp+var_30]
mov [rbp+var_38], rax
lea rdi, [rbp+var_48]
xor esi, esi
mov edx, 10h
call _memset
mov rax, [rbp+var_D8]
mov rcx, [rax]
mov [rsp+100h+var_100], rcx
mov rcx, [rax+8]
mov [rsp+100h+var_F8], rcx
mov rax, [rax+10h]
mov [rsp+100h+var_F0], rax
call ssz_len
mov [rbp+var_94], eax
mov [rbp+var_A0], 0
mov [rbp+var_A4], 0
loc_15676:
mov eax, [rbp+var_A4]
cmp eax, [rbp+var_94]
jnb loc_157AE
mov rax, [rbp+var_D8]
mov esi, [rbp+var_A4]
lea rdi, [rbp+var_C0]
mov rcx, [rax]
mov [rsp+100h+var_100], rcx
mov rcx, [rax+8]
mov [rsp+100h+var_F8], rcx
mov rax, [rax+10h]
mov [rsp+100h+var_F0], rax
call ssz_at
lea rdx, [rbp+var_90]
mov edi, [rbp+var_C0]
mov rsi, [rbp+var_B8]
call keccak
cmp [rbp+var_A4], 0
jnz short loc_1572D
mov rax, [rbp+var_90]
mov [rbp+var_70], rax
mov rax, [rbp+var_88]
mov [rbp+var_68], rax
mov rax, [rbp+var_80]
mov [rbp+var_60], rax
mov rax, [rbp+var_78]
mov [rbp+var_58], rax
mov rax, [rbp+var_18]
mov rcx, [rbp+var_90]
mov [rax], rcx
mov rcx, [rbp+var_88]
mov [rax+8], rcx
mov rcx, [rbp+var_80]
mov [rax+10h], rcx
mov rcx, [rbp+var_78]
mov [rax+18h], rcx
jmp short loc_15752
loc_1572D:
lea rdi, [rbp+var_70]
lea rsi, [rbp+var_90]
mov edx, 20h ; ' '
call _memcmp
cmp eax, 0
jz short loc_15750
mov [rbp+var_24], 0
jmp short loc_157AE
loc_15750:
jmp short $+2
loc_15752:
lea rdi, [rbp+var_C0]
mov eax, [rbp+var_A4]
add eax, 1
cmp eax, [rbp+var_94]
setz al
and al, 1
movzx edx, al
lea r8, [rbp+var_70]
lea rsi, [rbp+var_38]
lea rcx, [rbp+var_48]
lea r9, [rbp+var_A0]
call handle_node
mov ecx, eax
mov [rbp+var_24], ecx
mov eax, 1
cmp eax, ecx
jz short loc_15798
jmp short loc_157AE
loc_15798:
jmp short $+2
loc_1579A:
mov eax, [rbp+var_A4]
add eax, 1
mov [rbp+var_A4], eax
jmp loc_15676
loc_157AE:
cmp [rbp+var_24], 0
jz short loc_15817
cmp [rbp+var_20], 0
jz short loc_15817
mov rax, [rbp+var_20]
mov [rbp+var_E0], rax
cmp [rbp+var_24], 2
jnz short loc_157FF
mov rax, [rbp+var_E0]
mov dword ptr [rbp+var_D0], 0
mov [rbp+var_C8], 0
mov rcx, [rbp+var_D0]
mov [rax], rcx
mov rcx, [rbp+var_C8]
mov [rax+8], rcx
jmp short loc_15815
loc_157FF:
mov rax, [rbp+var_E0]
mov rcx, [rbp+var_48]
mov [rax], rcx
mov rcx, [rbp+var_40]
mov [rax+8], rcx
loc_15815:
jmp short $+2
loc_15817:
cmp [rbp+var_30], 0
jz short loc_15827
mov rdi, [rbp+var_30]
call safe_free
loc_15827:
cmp [rbp+var_24], 3
jnz short loc_1583A
mov eax, 1
mov [rbp+var_E4], eax
jmp short loc_15843
loc_1583A:
mov eax, [rbp+var_24]
mov [rbp+var_E4], eax
loc_15843:
mov eax, [rbp+var_E4]
add rsp, 100h
pop rbp
retn
| long long patricia_verify(
_QWORD *a1,
unsigned int a2,
long long a3,
_QWORD *a4,
_DWORD a5,
_DWORD a6,
long long a7,
long long a8,
long long a9)
{
int v9; // edx
int v10; // r8d
int v11; // r9d
int v12; // edx
int v13; // r8d
int v14; // r9d
_QWORD *v15; // rax
_QWORD *v18; // [rsp+20h] [rbp-E0h]
long long v19; // [rsp+30h] [rbp-D0h]
unsigned int v20; // [rsp+40h] [rbp-C0h] BYREF
long long v21; // [rsp+48h] [rbp-B8h]
unsigned int i; // [rsp+5Ch] [rbp-A4h]
long long v23; // [rsp+60h] [rbp-A0h] BYREF
unsigned int v24; // [rsp+6Ch] [rbp-94h]
long long v25; // [rsp+70h] [rbp-90h] BYREF
long long v26; // [rsp+78h] [rbp-88h]
long long v27; // [rsp+80h] [rbp-80h]
long long v28; // [rsp+88h] [rbp-78h]
_QWORD v29[5]; // [rsp+90h] [rbp-70h] BYREF
_QWORD v30[2]; // [rsp+B8h] [rbp-48h] BYREF
long long v31; // [rsp+C8h] [rbp-38h] BYREF
long long v32; // [rsp+D0h] [rbp-30h]
unsigned int v33; // [rsp+DCh] [rbp-24h]
_QWORD *v34; // [rsp+E0h] [rbp-20h]
_QWORD *v35; // [rsp+E8h] [rbp-18h]
unsigned int v36; // [rsp+F0h] [rbp-10h]
long long v37; // [rsp+F8h] [rbp-8h]
v36 = a2;
v37 = a3;
v35 = a1;
v34 = a4;
v33 = 1;
v32 = patricia_to_nibbles(a2, a3, 0LL);
v31 = v32;
memset(v30, 0LL, sizeof(v30));
v24 = ssz_len((unsigned int)v30, 0, v9, a8, v10, v11, a7, a8, a9);
v23 = 0LL;
for ( i = 0; i < v24; ++i )
{
ssz_at((unsigned int)&v20, i, v12, a8, v13, v14, a7, a8, a9);
keccak(v20, v21, &v25);
if ( i )
{
if ( (unsigned int)memcmp(v29, &v25, 32LL) )
{
v33 = 0;
break;
}
}
else
{
v29[0] = v25;
v29[1] = v26;
v29[2] = v27;
v29[3] = v28;
v15 = v35;
*v35 = v25;
v15[1] = v26;
v15[2] = v27;
v15[3] = v28;
}
v33 = handle_node(&v20, &v31, i + 1 == v24, v30, v29, &v23);
if ( v33 != 1 )
break;
}
if ( v33 && v34 )
{
v18 = v34;
if ( v33 == 2 )
{
LODWORD(v19) = 0;
*v34 = v19;
v18[1] = 0LL;
}
else
{
*v34 = v30[0];
v18[1] = v30[1];
}
}
if ( v32 )
safe_free(v32);
if ( v33 == 3 )
return 1;
else
return v33;
}
| patricia_verify:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x100
LEA RAX,[RBP + 0x10]
MOV qword ptr [RBP + -0xd8],RAX
MOV dword ptr [RBP + -0x10],ESI
MOV qword ptr [RBP + -0x8],RDX
MOV qword ptr [RBP + -0x18],RDI
MOV qword ptr [RBP + -0x20],RCX
MOV dword ptr [RBP + -0x24],0x1
MOV EDI,dword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x8]
XOR EDX,EDX
CALL 0x00115860
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x38],RAX
LEA RDI,[RBP + -0x48]
XOR ESI,ESI
MOV EDX,0x10
CALL 0x00105110
MOV RAX,qword ptr [RBP + -0xd8]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x0011b380
MOV dword ptr [RBP + -0x94],EAX
MOV qword ptr [RBP + -0xa0],0x0
MOV dword ptr [RBP + -0xa4],0x0
LAB_00115676:
MOV EAX,dword ptr [RBP + -0xa4]
CMP EAX,dword ptr [RBP + -0x94]
JNC 0x001157ae
MOV RAX,qword ptr [RBP + -0xd8]
MOV ESI,dword ptr [RBP + -0xa4]
LEA RDI,[RBP + -0xc0]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x0011b0d0
LEA RDX,[RBP + -0x90]
MOV EDI,dword ptr [RBP + -0xc0]
MOV RSI,qword ptr [RBP + -0xb8]
CALL 0x0011f4e0
CMP dword ptr [RBP + -0xa4],0x0
JNZ 0x0011572d
MOV RAX,qword ptr [RBP + -0x90]
MOV qword ptr [RBP + -0x70],RAX
MOV RAX,qword ptr [RBP + -0x88]
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RBP + -0x80]
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x78]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x90]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x88]
MOV qword ptr [RAX + 0x8],RCX
MOV RCX,qword ptr [RBP + -0x80]
MOV qword ptr [RAX + 0x10],RCX
MOV RCX,qword ptr [RBP + -0x78]
MOV qword ptr [RAX + 0x18],RCX
JMP 0x00115752
LAB_0011572d:
LEA RDI,[RBP + -0x70]
LEA RSI,[RBP + -0x90]
MOV EDX,0x20
CALL 0x00105310
CMP EAX,0x0
JZ 0x00115750
MOV dword ptr [RBP + -0x24],0x0
JMP 0x001157ae
LAB_00115750:
JMP 0x00115752
LAB_00115752:
LEA RDI,[RBP + -0xc0]
MOV EAX,dword ptr [RBP + -0xa4]
ADD EAX,0x1
CMP EAX,dword ptr [RBP + -0x94]
SETZ AL
AND AL,0x1
MOVZX EDX,AL
LEA R8,[RBP + -0x70]
LEA RSI,[RBP + -0x38]
LEA RCX,[RBP + -0x48]
LEA R9,[RBP + -0xa0]
CALL 0x00115960
MOV ECX,EAX
MOV dword ptr [RBP + -0x24],ECX
MOV EAX,0x1
CMP EAX,ECX
JZ 0x00115798
JMP 0x001157ae
LAB_00115798:
JMP 0x0011579a
LAB_0011579a:
MOV EAX,dword ptr [RBP + -0xa4]
ADD EAX,0x1
MOV dword ptr [RBP + -0xa4],EAX
JMP 0x00115676
LAB_001157ae:
CMP dword ptr [RBP + -0x24],0x0
JZ 0x00115817
CMP qword ptr [RBP + -0x20],0x0
JZ 0x00115817
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0xe0],RAX
CMP dword ptr [RBP + -0x24],0x2
JNZ 0x001157ff
MOV RAX,qword ptr [RBP + -0xe0]
MOV dword ptr [RBP + -0xd0],0x0
MOV qword ptr [RBP + -0xc8],0x0
MOV RCX,qword ptr [RBP + -0xd0]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0xc8]
MOV qword ptr [RAX + 0x8],RCX
JMP 0x00115815
LAB_001157ff:
MOV RAX,qword ptr [RBP + -0xe0]
MOV RCX,qword ptr [RBP + -0x48]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x40]
MOV qword ptr [RAX + 0x8],RCX
LAB_00115815:
JMP 0x00115817
LAB_00115817:
CMP qword ptr [RBP + -0x30],0x0
JZ 0x00115827
MOV RDI,qword ptr [RBP + -0x30]
CALL 0x00118740
LAB_00115827:
CMP dword ptr [RBP + -0x24],0x3
JNZ 0x0011583a
MOV EAX,0x1
MOV dword ptr [RBP + -0xe4],EAX
JMP 0x00115843
LAB_0011583a:
MOV EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0xe4],EAX
LAB_00115843:
MOV EAX,dword ptr [RBP + -0xe4]
ADD RSP,0x100
POP RBP
RET
|
int patricia_verify(int8 *param_1,int4 param_2,int8 param_3,long *param_4,
int8 param_5,int8 param_6,int8 param_7,int8 param_8,
int8 param_9)
{
int iVar1;
int8 uVar2;
int8 uVar3;
int8 uVar4;
int local_ec;
uint uStack_d4;
int4 local_c8 [2];
int8 local_c0;
uint local_ac;
int8 local_a8;
uint local_9c;
int8 local_98;
int8 local_90;
int8 local_88;
int8 local_80;
int8 local_78;
int8 local_70;
int8 local_68;
int8 local_60;
long local_50;
long local_48;
long local_40;
long local_38;
int local_2c;
long *local_28;
int8 *local_20;
int4 local_18;
int8 local_10;
local_2c = 1;
local_28 = param_4;
local_20 = param_1;
local_18 = param_2;
local_10 = param_3;
local_40 = patricia_to_nibbles(param_2,param_3,0);
local_38 = local_40;
memset(&local_50,0,0x10);
local_9c = ssz_len();
local_a8 = 0;
local_ac = 0;
do {
if (local_9c <= local_ac) {
LAB_001157ae:
if ((local_2c != 0) && (local_28 != (long *)0x0)) {
if (local_2c == 2) {
*local_28 = (ulong)uStack_d4 << 0x20;
local_28[1] = 0;
}
else {
*local_28 = local_50;
local_28[1] = local_48;
}
}
if (local_38 != 0) {
safe_free(local_38);
}
if (local_2c == 3) {
local_ec = 1;
}
else {
local_ec = local_2c;
}
return local_ec;
}
uVar2 = param_7;
uVar3 = param_8;
uVar4 = param_9;
ssz_at(local_c8,local_ac);
keccak(local_c8[0],local_c0,&local_98);
if (local_ac == 0) {
local_78 = local_98;
local_70 = local_90;
local_68 = local_88;
local_60 = local_80;
*local_20 = local_98;
local_20[1] = local_90;
local_20[2] = local_88;
local_20[3] = local_80;
}
else {
iVar1 = memcmp(&local_78,&local_98,0x20);
if (iVar1 != 0) {
local_2c = 0;
goto LAB_001157ae;
}
}
local_2c = handle_node(local_c8,&local_40,local_ac + 1 == local_9c,&local_50,&local_78,&local_a8
,uVar2,uVar3,uVar4);
if (local_2c != 1) goto LAB_001157ae;
local_ac = local_ac + 1;
} while( true );
}
| |
55,551 | patricia_verify | corpus-core[P]colibri-stateless/src/chains/eth/verifier/patricia.c | INTERNAL patricia_result_t patricia_verify(bytes32_t root, bytes_t path, ssz_ob_t proof, bytes_t* expected) {
int result = 1;
uint8_t* nibbles = patricia_to_nibbles(path, 0);
uint8_t* key = nibbles;
bytes_t last_value = NULL_BYTES;
bytes32_t expected_hash;
bytes32_t node_hash;
uint32_t proof_len = ssz_len(proof);
size_t depth = 0;
for (uint32_t i = 0; i < proof_len; i++) {
ssz_ob_t witness = ssz_at(proof, i);
keccak(witness.bytes, node_hash);
if (i == 0) {
memcpy(expected_hash, node_hash, 32);
memcpy(root, node_hash, 32);
}
else if (memcmp(expected_hash, node_hash, 32)) {
result = 0;
break;
}
if (1 != (result = handle_node(&witness.bytes, &key, i + 1 == proof_len, &last_value, expected_hash, &depth))) break;
}
if (result && expected)
*expected = result == 2 ? NULL_BYTES : last_value;
if (nibbles) safe_free(nibbles);
return result == 3 ? PATRICIA_FOUND : (patricia_result_t) result;
} | O3 | c | patricia_verify:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rcx, %r14
movq %rdi, %r15
xorl %r12d, %r12d
movl %esi, %edi
movq %rdx, %rsi
xorl %edx, %edx
callq 0x108a9
movq %rax, %rbx
movq %rax, 0x38(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x40(%rsp)
movq 0xf0(%rsp), %rax
movq %rax, 0x10(%rsp)
movdqa 0xe0(%rsp), %xmm0
movdqu %xmm0, (%rsp)
callq 0x13de0
movq $0x0, 0x30(%rsp)
movl $0x1, %ebp
testl %eax, %eax
je 0x10847
movl %eax, %r13d
movq %r14, 0x28(%rsp)
movq %rbx, 0x20(%rsp)
leaq 0xe0(%rsp), %r14
negl %r13d
leaq 0x90(%rsp), %rbp
leaq 0x30(%rsp), %rbx
movq 0x10(%r14), %rax
movq %rax, 0x10(%rsp)
movups (%r14), %xmm0
movups %xmm0, (%rsp)
movq %rbp, %rdi
movl %r12d, %esi
callq 0x13c65
movl 0x90(%rsp), %edi
movq 0x98(%rsp), %rsi
leaq 0x50(%rsp), %rdx
callq 0x16384
testl %r12d, %r12d
je 0x107ca
movdqa 0x70(%rsp), %xmm0
movdqa 0x80(%rsp), %xmm1
pcmpeqb 0x60(%rsp), %xmm1
pcmpeqb 0x50(%rsp), %xmm0
pand %xmm1, %xmm0
pmovmskb %xmm0, %eax
cmpl $0xffff, %eax # imm = 0xFFFF
je 0x107f0
jmp 0x10878
movdqa 0x50(%rsp), %xmm0
movdqa 0x60(%rsp), %xmm1
movdqa %xmm1, 0x80(%rsp)
movdqa %xmm0, 0x70(%rsp)
movdqu %xmm1, 0x10(%r15)
movdqu %xmm0, (%r15)
leal (%r12,%r13), %eax
xorl %edx, %edx
cmpl $-0x1, %eax
sete %dl
movq %rbp, %rdi
leaq 0x38(%rsp), %rsi
leaq 0x40(%rsp), %rcx
leaq 0x70(%rsp), %r8
movq %rbx, %r9
callq 0x10925
cmpl $0x1, %eax
jne 0x1083b
incl %r12d
movl %r13d, %eax
addl %r12d, %eax
jne 0x10761
movq 0x20(%rsp), %rbx
movq 0x28(%rsp), %r14
movl $0x1, %ebp
jmp 0x10847
movl %eax, %ebp
movq 0x20(%rsp), %rbx
movq 0x28(%rsp), %r14
testq %r14, %r14
je 0x1087f
testl %ebp, %ebp
je 0x1087f
cmpl $0x2, %ebp
jne 0x1086b
movl $0x0, (%r14)
movq $0x0, 0x8(%r14)
movl $0x2, %ebp
jmp 0x1087f
movdqa 0x40(%rsp), %xmm0
movdqu %xmm0, (%r14)
jmp 0x1087f
xorl %ebp, %ebp
movq 0x20(%rsp), %rbx
testq %rbx, %rbx
je 0x1088c
movq %rbx, %rdi
callq 0x125c0
cmpl $0x3, %ebp
movl $0x1, %eax
cmovnel %ebp, %eax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| patricia_verify:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0A8h
mov r14, rcx
mov r15, rdi
xor r12d, r12d
mov edi, esi
mov rsi, rdx
xor edx, edx
call patricia_to_nibbles
mov rbx, rax
mov [rsp+0D8h+var_A0], rax
xorps xmm0, xmm0
movaps [rsp+0D8h+var_98], xmm0
mov rax, [rsp+0D8h+arg_10]
mov [rsp+0D8h+var_C8], rax
movdqa xmm0, [rsp+0D8h+arg_0]
movdqu [rsp+0D8h+var_D8], xmm0
call ssz_len
mov [rsp+0D8h+var_A8], 0
mov ebp, 1
test eax, eax
jz loc_10847
mov r13d, eax
mov [rsp+0D8h+var_B0], r14
mov [rsp+0D8h+var_B8], rbx
lea r14, [rsp+0D8h+arg_0]
neg r13d
lea rbp, [rsp+0D8h+var_48]
lea rbx, [rsp+0D8h+var_A8]
loc_10761:
mov rax, [r14+10h]
mov [rsp+0D8h+var_C8], rax
movups xmm0, xmmword ptr [r14]
movups [rsp+0D8h+var_D8], xmm0
mov rdi, rbp
mov esi, r12d
call ssz_at
mov edi, [rsp+0D8h+var_48]
mov rsi, [rsp+0D8h+var_40]
lea rdx, [rsp+0D8h+var_88]
call keccak
test r12d, r12d
jz short loc_107CA
movdqa xmm0, [rsp+0D8h+var_68]
movdqa xmm1, [rsp+0D8h+var_58]
pcmpeqb xmm1, [rsp+0D8h+var_78]
pcmpeqb xmm0, [rsp+0D8h+var_88]
pand xmm0, xmm1
pmovmskb eax, xmm0
cmp eax, 0FFFFh
jz short loc_107F0
jmp loc_10878
loc_107CA:
movdqa xmm0, [rsp+0D8h+var_88]
movdqa xmm1, [rsp+0D8h+var_78]
movdqa [rsp+0D8h+var_58], xmm1
movdqa [rsp+0D8h+var_68], xmm0
movdqu xmmword ptr [r15+10h], xmm1
movdqu xmmword ptr [r15], xmm0
loc_107F0:
lea eax, [r12+r13]
xor edx, edx
cmp eax, 0FFFFFFFFh
setz dl
mov rdi, rbp
lea rsi, [rsp+0D8h+var_A0]
lea rcx, [rsp+0D8h+var_98]
lea r8, [rsp+0D8h+var_68]
mov r9, rbx
call handle_node
cmp eax, 1
jnz short loc_1083B
inc r12d
mov eax, r13d
add eax, r12d
jnz loc_10761
mov rbx, [rsp+0D8h+var_B8]
mov r14, [rsp+0D8h+var_B0]
mov ebp, 1
jmp short loc_10847
loc_1083B:
mov ebp, eax
mov rbx, [rsp+0D8h+var_B8]
mov r14, [rsp+0D8h+var_B0]
loc_10847:
test r14, r14
jz short loc_1087F
test ebp, ebp
jz short loc_1087F
cmp ebp, 2
jnz short loc_1086B
mov dword ptr [r14], 0
mov qword ptr [r14+8], 0
mov ebp, 2
jmp short loc_1087F
loc_1086B:
movdqa xmm0, [rsp+0D8h+var_98]
movdqu xmmword ptr [r14], xmm0
jmp short loc_1087F
loc_10878:
xor ebp, ebp
mov rbx, [rsp+0D8h+var_B8]
loc_1087F:
test rbx, rbx
jz short loc_1088C
mov rdi, rbx
call safe_free
loc_1088C:
cmp ebp, 3
mov eax, 1
cmovnz eax, ebp
add rsp, 0A8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long patricia_verify(
__m128i *a1,
unsigned int a2,
long long a3,
long long a4,
long long a5,
long long a6,
__int128 a7,
long long a8)
{
int v10; // r12d
long long v11; // rdi
int v12; // esi
long long v13; // rbx
__m128i si128; // xmm0
int v15; // edx
int v16; // ecx
int v17; // r8d
int v18; // r9d
int v19; // eax
int v20; // edx
int v21; // ecx
int v22; // r8d
int v23; // r9d
unsigned int v24; // ebp
int v25; // r13d
__m128i v26; // xmm0
unsigned int v27; // eax
long long result; // rax
long long v29; // [rsp+30h] [rbp-A8h] BYREF
long long v30; // [rsp+38h] [rbp-A0h] BYREF
__m128i v31; // [rsp+40h] [rbp-98h] BYREF
__m128i v32; // [rsp+50h] [rbp-88h] BYREF
__m128i v33; // [rsp+60h] [rbp-78h] BYREF
__m128i v34; // [rsp+70h] [rbp-68h] BYREF
__m128i v35; // [rsp+80h] [rbp-58h] BYREF
unsigned int v36; // [rsp+90h] [rbp-48h] BYREF
long long v37; // [rsp+98h] [rbp-40h]
v10 = 0;
v11 = a2;
v12 = a3;
v13 = patricia_to_nibbles(v11, a3, 0LL);
v30 = v13;
v31 = 0LL;
si128 = _mm_load_si128((const __m128i *)&a7);
v19 = ssz_len(v11, v12, v15, v16, v17, v18, si128.m128i_i8[0], si128.m128i_i32[2], a8);
v29 = 0LL;
v24 = 1;
if ( v19 )
{
v25 = -v19;
while ( 1 )
{
ssz_at((unsigned int)&v36, v10, v20, v21, v22, v23, a7, *((long long *)&a7 + 1), a8);
keccak(v36, v37, &v32);
if ( v10 )
{
if ( _mm_movemask_epi8(_mm_and_si128(_mm_cmpeq_epi8(_mm_load_si128(&v34), v32), _mm_cmpeq_epi8(_mm_load_si128(&v35), v33))) != 0xFFFF )
{
v24 = 0;
goto LABEL_16;
}
}
else
{
v26 = _mm_load_si128(&v32);
v35 = _mm_load_si128(&v33);
v34 = v26;
a1[1] = v35;
*a1 = v26;
}
v27 = handle_node(&v36, &v30, v10 + v25 == -1, &v31, &v34, &v29);
if ( v27 != 1 )
break;
if ( !(++v10 + v25) )
{
v24 = 1;
goto LABEL_11;
}
}
v24 = v27;
}
LABEL_11:
if ( a4 && v24 )
{
if ( v24 == 2 )
{
*(_DWORD *)a4 = 0;
*(_QWORD *)(a4 + 8) = 0LL;
v24 = 2;
}
else
{
*(__m128i *)a4 = _mm_load_si128(&v31);
}
}
LABEL_16:
if ( v13 )
safe_free(v13);
result = 1LL;
if ( v24 != 3 )
return v24;
return result;
}
| patricia_verify:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xa8
MOV R14,RCX
MOV R15,RDI
XOR R12D,R12D
MOV EDI,ESI
MOV RSI,RDX
XOR EDX,EDX
CALL 0x001108a9
MOV RBX,RAX
MOV qword ptr [RSP + 0x38],RAX
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP + 0x40],XMM0
MOV RAX,qword ptr [RSP + 0xf0]
MOV qword ptr [RSP + 0x10],RAX
MOVDQA XMM0,xmmword ptr [RSP + 0xe0]
MOVDQU xmmword ptr [RSP],XMM0
CALL 0x00113de0
MOV qword ptr [RSP + 0x30],0x0
MOV EBP,0x1
TEST EAX,EAX
JZ 0x00110847
MOV R13D,EAX
MOV qword ptr [RSP + 0x28],R14
MOV qword ptr [RSP + 0x20],RBX
LEA R14,[RSP + 0xe0]
NEG R13D
LEA RBP,[RSP + 0x90]
LEA RBX,[RSP + 0x30]
LAB_00110761:
MOV RAX,qword ptr [R14 + 0x10]
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [R14]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,RBP
MOV ESI,R12D
CALL 0x00113c65
MOV EDI,dword ptr [RSP + 0x90]
MOV RSI,qword ptr [RSP + 0x98]
LEA RDX,[RSP + 0x50]
CALL 0x00116384
TEST R12D,R12D
JZ 0x001107ca
MOVDQA XMM0,xmmword ptr [RSP + 0x70]
MOVDQA XMM1,xmmword ptr [RSP + 0x80]
PCMPEQB XMM1,xmmword ptr [RSP + 0x60]
PCMPEQB XMM0,xmmword ptr [RSP + 0x50]
PAND XMM0,XMM1
PMOVMSKB EAX,XMM0
CMP EAX,0xffff
JZ 0x001107f0
JMP 0x00110878
LAB_001107ca:
MOVDQA XMM0,xmmword ptr [RSP + 0x50]
MOVDQA XMM1,xmmword ptr [RSP + 0x60]
MOVDQA xmmword ptr [RSP + 0x80],XMM1
MOVDQA xmmword ptr [RSP + 0x70],XMM0
MOVDQU xmmword ptr [R15 + 0x10],XMM1
MOVDQU xmmword ptr [R15],XMM0
LAB_001107f0:
LEA EAX,[R12 + R13*0x1]
XOR EDX,EDX
CMP EAX,-0x1
SETZ DL
MOV RDI,RBP
LEA RSI,[RSP + 0x38]
LEA RCX,[RSP + 0x40]
LEA R8,[RSP + 0x70]
MOV R9,RBX
CALL 0x00110925
CMP EAX,0x1
JNZ 0x0011083b
INC R12D
MOV EAX,R13D
ADD EAX,R12D
JNZ 0x00110761
MOV RBX,qword ptr [RSP + 0x20]
MOV R14,qword ptr [RSP + 0x28]
MOV EBP,0x1
JMP 0x00110847
LAB_0011083b:
MOV EBP,EAX
MOV RBX,qword ptr [RSP + 0x20]
MOV R14,qword ptr [RSP + 0x28]
LAB_00110847:
TEST R14,R14
JZ 0x0011087f
TEST EBP,EBP
JZ 0x0011087f
CMP EBP,0x2
JNZ 0x0011086b
MOV dword ptr [R14],0x0
MOV qword ptr [R14 + 0x8],0x0
MOV EBP,0x2
JMP 0x0011087f
LAB_0011086b:
MOVDQA XMM0,xmmword ptr [RSP + 0x40]
MOVDQU xmmword ptr [R14],XMM0
JMP 0x0011087f
LAB_00110878:
XOR EBP,EBP
MOV RBX,qword ptr [RSP + 0x20]
LAB_0011087f:
TEST RBX,RBX
JZ 0x0011088c
MOV RDI,RBX
CALL 0x001125c0
LAB_0011088c:
CMP EBP,0x3
MOV EAX,0x1
CMOVNZ EAX,EBP
ADD RSP,0xa8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int patricia_verify(int8 *param_1,int4 param_2,int8 param_3,int8 *param_4,
int8 param_5,int8 param_6,int8 param_7,int8 param_8,
int8 param_9)
{
int iVar1;
int iVar2;
void *__ptr;
int iVar3;
int1 auVar4 [16];
int1 auVar5 [16];
int8 uVar6;
int8 uVar7;
int8 uVar8;
int8 local_a8;
void *local_a0;
int8 local_98;
int8 uStack_90;
char local_88;
char cStack_87;
char cStack_86;
char cStack_85;
char cStack_84;
char cStack_83;
char cStack_82;
char cStack_81;
char cStack_80;
char cStack_7f;
char cStack_7e;
char cStack_7d;
char cStack_7c;
char cStack_7b;
char cStack_7a;
char cStack_79;
char local_78;
char cStack_77;
char cStack_76;
char cStack_75;
char cStack_74;
char cStack_73;
char cStack_72;
char cStack_71;
char cStack_70;
char cStack_6f;
char cStack_6e;
char cStack_6d;
char cStack_6c;
char cStack_6b;
char cStack_6a;
char cStack_69;
int8 local_68;
int8 uStack_60;
int8 local_58;
int8 uStack_50;
int4 local_48 [2];
int8 local_40;
iVar3 = 0;
__ptr = (void *)patricia_to_nibbles(param_2,param_3,0);
local_98 = 0;
uStack_90 = 0;
local_a0 = __ptr;
iVar1 = ssz_len();
local_a8 = 0;
iVar2 = 1;
if (iVar1 != 0) {
do {
uVar6 = param_7;
uVar7 = param_8;
uVar8 = param_9;
ssz_at(local_48,iVar3);
keccak(local_48[0],local_40,&local_88);
if (iVar3 == 0) {
local_68 = CONCAT17(cStack_81,
CONCAT16(cStack_82,
CONCAT15(cStack_83,
CONCAT14(cStack_84,
CONCAT13(cStack_85,
CONCAT12(cStack_86,
CONCAT11(cStack_87,local_88
)))))));
uStack_60 = CONCAT17(cStack_79,
CONCAT16(cStack_7a,
CONCAT15(cStack_7b,
CONCAT14(cStack_7c,
CONCAT13(cStack_7d,
CONCAT12(cStack_7e,
CONCAT11(cStack_7f,
cStack_80)))))));
local_58 = CONCAT17(cStack_71,
CONCAT16(cStack_72,
CONCAT15(cStack_73,
CONCAT14(cStack_74,
CONCAT13(cStack_75,
CONCAT12(cStack_76,
CONCAT11(cStack_77,local_78
)))))));
uStack_50 = CONCAT17(cStack_69,
CONCAT16(cStack_6a,
CONCAT15(cStack_6b,
CONCAT14(cStack_6c,
CONCAT13(cStack_6d,
CONCAT12(cStack_6e,
CONCAT11(cStack_6f,
cStack_70)))))));
param_1[2] = local_58;
param_1[3] = uStack_50;
*param_1 = local_68;
param_1[1] = uStack_60;
}
else {
auVar5[0] = -((char)local_58 == local_78);
auVar5[1] = -(local_58._1_1_ == cStack_77);
auVar5[2] = -(local_58._2_1_ == cStack_76);
auVar5[3] = -(local_58._3_1_ == cStack_75);
auVar5[4] = -(local_58._4_1_ == cStack_74);
auVar5[5] = -(local_58._5_1_ == cStack_73);
auVar5[6] = -(local_58._6_1_ == cStack_72);
auVar5[7] = -(local_58._7_1_ == cStack_71);
auVar5[8] = -((char)uStack_50 == cStack_70);
auVar5[9] = -(uStack_50._1_1_ == cStack_6f);
auVar5[10] = -(uStack_50._2_1_ == cStack_6e);
auVar5[0xb] = -(uStack_50._3_1_ == cStack_6d);
auVar5[0xc] = -(uStack_50._4_1_ == cStack_6c);
auVar5[0xd] = -(uStack_50._5_1_ == cStack_6b);
auVar5[0xe] = -(uStack_50._6_1_ == cStack_6a);
auVar5[0xf] = -(uStack_50._7_1_ == cStack_69);
auVar4[0] = -((char)local_68 == local_88);
auVar4[1] = -(local_68._1_1_ == cStack_87);
auVar4[2] = -(local_68._2_1_ == cStack_86);
auVar4[3] = -(local_68._3_1_ == cStack_85);
auVar4[4] = -(local_68._4_1_ == cStack_84);
auVar4[5] = -(local_68._5_1_ == cStack_83);
auVar4[6] = -(local_68._6_1_ == cStack_82);
auVar4[7] = -(local_68._7_1_ == cStack_81);
auVar4[8] = -((char)uStack_60 == cStack_80);
auVar4[9] = -(uStack_60._1_1_ == cStack_7f);
auVar4[10] = -(uStack_60._2_1_ == cStack_7e);
auVar4[0xb] = -(uStack_60._3_1_ == cStack_7d);
auVar4[0xc] = -(uStack_60._4_1_ == cStack_7c);
auVar4[0xd] = -(uStack_60._5_1_ == cStack_7b);
auVar4[0xe] = -(uStack_60._6_1_ == cStack_7a);
auVar4[0xf] = -(uStack_60._7_1_ == cStack_79);
auVar4 = auVar4 & auVar5;
if ((ushort)((ushort)(SUB161(auVar4 >> 7,0) & 1) |
(ushort)(SUB161(auVar4 >> 0xf,0) & 1) << 1 |
(ushort)(SUB161(auVar4 >> 0x17,0) & 1) << 2 |
(ushort)(SUB161(auVar4 >> 0x1f,0) & 1) << 3 |
(ushort)(SUB161(auVar4 >> 0x27,0) & 1) << 4 |
(ushort)(SUB161(auVar4 >> 0x2f,0) & 1) << 5 |
(ushort)(SUB161(auVar4 >> 0x37,0) & 1) << 6 |
(ushort)(SUB161(auVar4 >> 0x3f,0) & 1) << 7 |
(ushort)(SUB161(auVar4 >> 0x47,0) & 1) << 8 |
(ushort)(SUB161(auVar4 >> 0x4f,0) & 1) << 9 |
(ushort)(SUB161(auVar4 >> 0x57,0) & 1) << 10 |
(ushort)(SUB161(auVar4 >> 0x5f,0) & 1) << 0xb |
(ushort)(SUB161(auVar4 >> 0x67,0) & 1) << 0xc |
(ushort)(SUB161(auVar4 >> 0x6f,0) & 1) << 0xd |
(ushort)(SUB161(auVar4 >> 0x77,0) & 1) << 0xe |
(ushort)(byte)(auVar4[0xf] >> 7) << 0xf) != 0xffff) {
iVar2 = 0;
goto LAB_0011087f;
}
}
iVar2 = handle_node(local_48,&local_a0,iVar3 - iVar1 == -1,&local_98,&local_68,&local_a8,uVar6
,uVar7,uVar8);
if (iVar2 != 1) goto LAB_00110847;
iVar3 = iVar3 + 1;
} while (iVar3 != iVar1);
iVar2 = 1;
}
LAB_00110847:
if ((param_4 != (int8 *)0x0) && (iVar2 != 0)) {
if (iVar2 == 2) {
*(int4 *)param_4 = 0;
param_4[1] = 0;
iVar2 = 2;
}
else {
*param_4 = local_98;
param_4[1] = uStack_90;
}
}
LAB_0011087f:
if (__ptr != (void *)0x0) {
safe_free(__ptr);
}
iVar1 = 1;
if (iVar2 != 3) {
iVar1 = iVar2;
}
return iVar1;
}
| |
55,552 | 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>>>::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>>>::begin() const:
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
movq (%rsi), %rax
movq %rax, (%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rsp)
movabsq $-0x8000000000000000, %rcx # imm = 0x8000000000000000
movq %rcx, 0x18(%rsp)
movzbl (%rax), %ecx
testl %ecx, %ecx
je 0xe47db
cmpl $0x2, %ecx
je 0xe47cd
cmpl $0x1, %ecx
jne 0xe47e6
movq 0x8(%rax), %rax
movq (%rax), %rax
movq %rax, 0x8(%rsp)
jmp 0xe47ef
movq 0x8(%rax), %rax
movq (%rax), %rax
movq %rax, 0x10(%rsp)
jmp 0xe47ef
movq $0x1, 0x18(%rsp)
jmp 0xe47ef
movq $0x0, 0x18(%rsp)
movq %rsp, %rsi
movq %rbx, %rdi
xorl %edx, %edx
callq 0xacfa0
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
retq
nop
| _ZNK8nlohmann16json_abi_v3_11_36detail15iteration_proxyINS1_9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEE5beginEv:
push rbx
sub rsp, 20h
mov rbx, rdi
mov rax, [rsi]
mov [rsp+28h+var_28], rax
xorps xmm0, xmm0
movups [rsp+28h+var_20], xmm0
mov rcx, 8000000000000000h
mov [rsp+28h+var_10], rcx
movzx ecx, byte ptr [rax]
test ecx, ecx
jz short loc_E47DB
cmp ecx, 2
jz short loc_E47CD
cmp ecx, 1
jnz short loc_E47E6
mov rax, [rax+8]
mov rax, [rax]
mov qword ptr [rsp+28h+var_20], rax
jmp short loc_E47EF
loc_E47CD:
mov rax, [rax+8]
mov rax, [rax]
mov qword ptr [rsp+28h+var_20+8], rax
jmp short loc_E47EF
loc_E47DB:
mov [rsp+28h+var_10], 1
jmp short loc_E47EF
loc_E47E6:
mov [rsp+28h+var_10], 0
loc_E47EF:
mov rsi, rsp
mov rdi, rbx
xor edx, edx
call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEEC2ESH_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>>>::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>>,ulong)
mov rax, rbx
add rsp, 20h
pop rbx
retn
| long long nlohmann::json_abi_v3_11_3::detail::iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::begin(
long long a1,
unsigned __int8 **a2)
{
unsigned __int8 *v2; // rax
int v3; // ecx
unsigned __int8 *v5; // [rsp+0h] [rbp-28h] BYREF
__int128 v6; // [rsp+8h] [rbp-20h]
long long v7; // [rsp+18h] [rbp-10h]
v2 = *a2;
v5 = v2;
v6 = 0LL;
v7 = 0x8000000000000000LL;
v3 = *v2;
if ( *v2 )
{
if ( v3 == 2 )
{
*((_QWORD *)&v6 + 1) = **((_QWORD **)v2 + 1);
}
else if ( v3 == 1 )
{
*(_QWORD *)&v6 = **((_QWORD **)v2 + 1);
}
else
{
v7 = 0LL;
}
}
else
{
v7 = 1LL;
}
nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::iteration_proxy_value(
a1,
(__int128 *)&v5,
0LL);
return a1;
}
| begin:
PUSH RBX
SUB RSP,0x20
MOV RBX,RDI
MOV RAX,qword ptr [RSI]
MOV qword ptr [RSP],RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RSP + 0x8],XMM0
MOV RCX,-0x8000000000000000
MOV qword ptr [RSP + 0x18],RCX
MOVZX ECX,byte ptr [RAX]
TEST ECX,ECX
JZ 0x001e47db
CMP ECX,0x2
JZ 0x001e47cd
CMP ECX,0x1
JNZ 0x001e47e6
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0x8],RAX
JMP 0x001e47ef
LAB_001e47cd:
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0x10],RAX
JMP 0x001e47ef
LAB_001e47db:
MOV qword ptr [RSP + 0x18],0x1
JMP 0x001e47ef
LAB_001e47e6:
MOV qword ptr [RSP + 0x18],0x0
LAB_001e47ef:
MOV RSI,RSP
MOV RDI,RBX
XOR EDX,EDX
CALL 0x001acfa0
MOV RAX,RBX
ADD RSP,0x20
POP RBX
RET
|
/* nlohmann::json_abi_v3_11_3::detail::iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> > >::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>>>
::begin(void)
{
iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
::iteration_proxy_value();
return;
}
| |
55,553 | Generator::gen_stmt(NodeStmt const*)::StmtVisitor::operator()(NodeStmtIf const*) const | BhuvanGudi[P]LexiParse/src/generation.hpp | void operator()(const NodeStmtIf* stmt_if) const
{
gen.m_output << " ;; if\n";
gen.gen_expr(stmt_if->expr);
gen.pop("rax");
const std::string label = gen.create_label();
gen.m_output << " test rax, rax\n";
gen.m_output << " jz " << label << "\n";
gen.gen_scope(stmt_if->scope);
if (stmt_if->pred.has_value()) {
const std::string end_label = gen.create_label();
gen.m_output << " jmp " << end_label << "\n";
gen.m_output << label << ":\n";
gen.gen_if_pred(stmt_if->pred.value(), end_label);
gen.m_output << end_label << ":\n";
}
else {
gen.m_output << label << ":\n";
}
gen.m_output << " ;; /if\n";
} | O0 | cpp | Generator::gen_stmt(NodeStmt const*)::StmtVisitor::operator()(NodeStmtIf const*) const:
pushq %rbp
movq %rsp, %rbp
subq $0xf0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0xa0(%rbp)
movq (%rax), %rdi
addq $0x28, %rdi
leaq 0x242c(%rip), %rsi # 0x17538
callq 0x31c0
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
callq 0x114c0
movq -0xa0(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x98(%rbp)
leaq -0x31(%rbp), %rdi
movq %rdi, -0x90(%rbp)
callq 0x32e0
movq -0x90(%rbp), %rdx
leaq 0x2303(%rip), %rsi # 0x17459
leaq -0x30(%rbp), %rdi
callq 0x90b0
jmp 0x15161
movq -0x98(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x114f0
jmp 0x15173
leaq -0x30(%rbp), %rdi
callq 0x3bd0
leaq -0x31(%rbp), %rdi
callq 0x3220
movq -0xa0(%rbp), %rax
movq (%rax), %rsi
leaq -0x68(%rbp), %rdi
callq 0x15440
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
addq $0x28, %rdi
leaq 0x2396(%rip), %rsi # 0x17543
callq 0x31c0
jmp 0x151b4
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
addq $0x28, %rdi
leaq 0x238d(%rip), %rsi # 0x17556
callq 0x31c0
movq %rax, -0xa8(%rbp)
jmp 0x151d7
movq -0xa8(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0x31a0
movq %rax, -0xb0(%rbp)
jmp 0x151f0
movq -0xb0(%rbp), %rdi
leaq 0x21fe(%rip), %rsi # 0x173fc
callq 0x31c0
jmp 0x15205
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
callq 0x144c0
jmp 0x1521e
movq -0x10(%rbp), %rdi
addq $0x10, %rdi
callq 0x15520
testb $0x1, %al
jne 0x15234
jmp 0x153bd
movq -0xa0(%rbp), %rax
movq (%rax), %rsi
leaq -0x88(%rbp), %rdi
callq 0x15440
jmp 0x1524c
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
addq $0x28, %rdi
leaq 0x22fd(%rip), %rsi # 0x1755e
callq 0x31c0
movq %rax, -0xb8(%rbp)
jmp 0x1526f
movq -0xb8(%rbp), %rdi
leaq -0x88(%rbp), %rsi
callq 0x31a0
movq %rax, -0xc0(%rbp)
jmp 0x1528b
movq -0xc0(%rbp), %rdi
leaq 0x2163(%rip), %rsi # 0x173fc
callq 0x31c0
jmp 0x152a0
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
addq $0x28, %rdi
leaq -0x68(%rbp), %rsi
callq 0x31a0
movq %rax, -0xc8(%rbp)
jmp 0x152c0
movq -0xc8(%rbp), %rdi
leaq 0x210c(%rip), %rsi # 0x173da
callq 0x31c0
jmp 0x152d5
movq -0xa0(%rbp), %rax
movq (%rax), %rax
movq %rax, -0xd8(%rbp)
movq -0x10(%rbp), %rdi
addq $0x10, %rdi
callq 0x15580
movq %rax, -0xd0(%rbp)
jmp 0x152fc
movq -0xd8(%rbp), %rdi
movq -0xd0(%rbp), %rax
movq (%rax), %rsi
leaq -0x88(%rbp), %rdx
callq 0x15540
jmp 0x1531b
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
addq $0x28, %rdi
leaq -0x88(%rbp), %rsi
callq 0x31a0
movq %rax, -0xe0(%rbp)
jmp 0x1533e
movq -0xe0(%rbp), %rdi
leaq 0x208e(%rip), %rsi # 0x173da
callq 0x31c0
jmp 0x15353
leaq -0x88(%rbp), %rdi
callq 0x3bd0
jmp 0x153f4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x15387
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x3bd0
leaq -0x31(%rbp), %rdi
callq 0x3220
jmp 0x1542b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x15422
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x88(%rbp), %rdi
callq 0x3bd0
jmp 0x15422
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
addq $0x28, %rdi
leaq -0x68(%rbp), %rsi
callq 0x31a0
movq %rax, -0xe8(%rbp)
jmp 0x153dd
movq -0xe8(%rbp), %rdi
leaq 0x1fef(%rip), %rsi # 0x173da
callq 0x31c0
jmp 0x153f2
jmp 0x153f4
movq -0xa0(%rbp), %rax
movq (%rax), %rdi
addq $0x28, %rdi
leaq 0x215e(%rip), %rsi # 0x17567
callq 0x31c0
jmp 0x15410
leaq -0x68(%rbp), %rdi
callq 0x3bd0
addq $0xf0, %rsp
popq %rbp
retq
leaq -0x68(%rbp), %rdi
callq 0x3bd0
movq -0x40(%rbp), %rdi
callq 0x32d0
nopw %cs:(%rax,%rax)
nop
| _ZZN9Generator8gen_stmtEPK8NodeStmtENK11StmtVisitorclEPK10NodeStmtIf:
push rbp
mov rbp, rsp
sub rsp, 0F0h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_8]
mov [rbp+var_A0], rax
mov rdi, [rax]
add rdi, 28h ; '('
lea rsi, aIf_0; " ;; if\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov rax, [rbp+var_A0]
mov rdi, [rax]
mov rax, [rbp+var_10]
mov rsi, [rax]
call _ZN9Generator8gen_exprEPK8NodeExpr; Generator::gen_expr(NodeExpr const*)
mov rax, [rbp+var_A0]
mov rax, [rax]
mov [rbp+var_98], rax
lea rdi, [rbp+var_31]
mov [rbp+var_90], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rbp+var_90]
lea rsi, aRax; "rax"
lea rdi, [rbp+var_30]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_15161:
mov rdi, [rbp+var_98]
lea rsi, [rbp+var_30]
call _ZN9Generator3popERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; Generator::pop(std::string const&)
jmp short $+2
loc_15173:
lea rdi, [rbp+var_30]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rbp+var_31]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rax, [rbp+var_A0]
mov rsi, [rax]
lea rdi, [rbp+var_68]
call _ZN9Generator12create_labelB5cxx11Ev; Generator::create_label(void)
mov rax, [rbp+var_A0]
mov rdi, [rax]
add rdi, 28h ; '('
lea rsi, aTestRaxRax; " test rax, rax\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_151B4:
mov rax, [rbp+var_A0]
mov rdi, [rax]
add rdi, 28h ; '('
lea rsi, aJz; " jz "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rbp+var_A8], rax
jmp short $+2
loc_151D7:
mov rdi, [rbp+var_A8]
lea rsi, [rbp+var_68]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rbp+var_B0], rax
jmp short $+2
loc_151F0:
mov rdi, [rbp+var_B0]
lea rsi, aMovRdi0+0Eh; "\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_15205:
mov rax, [rbp+var_A0]
mov rdi, [rax]
mov rax, [rbp+var_10]
mov rsi, [rax+8]
call _ZN9Generator9gen_scopeEPK9NodeScope; Generator::gen_scope(NodeScope const*)
jmp short $+2
loc_1521E:
mov rdi, [rbp+var_10]
add rdi, 10h
call _ZNKSt8optionalIP10NodeIfPredE9has_valueEv; std::optional<NodeIfPred *>::has_value(void)
test al, 1
jnz short loc_15234
jmp loc_153BD
loc_15234:
mov rax, [rbp+var_A0]
mov rsi, [rax]
lea rdi, [rbp+var_88]
call _ZN9Generator12create_labelB5cxx11Ev; Generator::create_label(void)
jmp short $+2
loc_1524C:
mov rax, [rbp+var_A0]
mov rdi, [rax]
add rdi, 28h ; '('
lea rsi, aJmp; " jmp "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rbp+var_B8], rax
jmp short $+2
loc_1526F:
mov rdi, [rbp+var_B8]
lea rsi, [rbp+var_88]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rbp+var_C0], rax
jmp short $+2
loc_1528B:
mov rdi, [rbp+var_C0]
lea rsi, aMovRdi0+0Eh; "\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_152A0:
mov rax, [rbp+var_A0]
mov rdi, [rax]
add rdi, 28h ; '('
lea rsi, [rbp+var_68]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rbp+var_C8], rax
jmp short $+2
loc_152C0:
mov rdi, [rbp+var_C8]
lea rsi, aGlobalStartSta+14h; ":\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_152D5:
mov rax, [rbp+var_A0]
mov rax, [rax]
mov [rbp+var_D8], rax
mov rdi, [rbp+var_10]
add rdi, 10h
call _ZNKRSt8optionalIP10NodeIfPredE5valueEv; std::optional<NodeIfPred *>::value(void)
mov [rbp+var_D0], rax
jmp short $+2
loc_152FC:
mov rdi, [rbp+var_D8]
mov rax, [rbp+var_D0]
mov rsi, [rax]
lea rdx, [rbp+var_88]
call _ZN9Generator11gen_if_predEPK10NodeIfPredRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; Generator::gen_if_pred(NodeIfPred const*,std::string const&)
jmp short $+2
loc_1531B:
mov rax, [rbp+var_A0]
mov rdi, [rax]
add rdi, 28h ; '('
lea rsi, [rbp+var_88]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rbp+var_E0], rax
jmp short $+2
loc_1533E:
mov rdi, [rbp+var_E0]
lea rsi, aGlobalStartSta+14h; ":\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_15353:
lea rdi, [rbp+var_88]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp loc_153F4
mov rcx, rax
mov eax, edx
mov [rbp+var_40], rcx
mov [rbp+var_44], eax
jmp short loc_15387
mov rcx, rax
mov eax, edx
mov [rbp+var_40], rcx
mov [rbp+var_44], eax
lea rdi, [rbp+var_30]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_15387:
lea rdi, [rbp+var_31]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_1542B
mov rcx, rax
mov eax, edx
mov [rbp+var_40], rcx
mov [rbp+var_44], eax
jmp short loc_15422
mov rcx, rax
mov eax, edx
mov [rbp+var_40], rcx
mov [rbp+var_44], eax
lea rdi, [rbp+var_88]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_15422
loc_153BD:
mov rax, [rbp+var_A0]
mov rdi, [rax]
add rdi, 28h ; '('
lea rsi, [rbp+var_68]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rbp+var_E8], rax
jmp short $+2
loc_153DD:
mov rdi, [rbp+var_E8]
lea rsi, aGlobalStartSta+14h; ":\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_153F2:
jmp short $+2
loc_153F4:
mov rax, [rbp+var_A0]
mov rdi, [rax]
add rdi, 28h ; '('
lea rsi, aIf_1; " ;; /if\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_15410:
lea rdi, [rbp+var_68]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
add rsp, 0F0h
pop rbp
retn
loc_15422:
lea rdi, [rbp+var_68]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_1542B:
mov rdi, [rbp+var_40]
call __Unwind_Resume
| long long Generator::gen_stmt(NodeStmt const*)::StmtVisitor::operator()(long long *a1, long long *a2)
{
long long v3; // [rsp+8h] [rbp-E8h]
long long v4; // [rsp+10h] [rbp-E0h]
long long v5; // [rsp+18h] [rbp-D8h]
_QWORD *v6; // [rsp+20h] [rbp-D0h]
long long v7; // [rsp+28h] [rbp-C8h]
long long v8; // [rsp+30h] [rbp-C0h]
long long v9; // [rsp+38h] [rbp-B8h]
long long v10; // [rsp+40h] [rbp-B0h]
long long v11; // [rsp+48h] [rbp-A8h]
long long v12; // [rsp+58h] [rbp-98h]
_BYTE v13[32]; // [rsp+68h] [rbp-88h] BYREF
_BYTE v14[36]; // [rsp+88h] [rbp-68h] BYREF
char v15; // [rsp+BFh] [rbp-31h] BYREF
_BYTE v16[32]; // [rsp+C0h] [rbp-30h] BYREF
long long *v17; // [rsp+E0h] [rbp-10h]
long long *v18; // [rsp+E8h] [rbp-8h]
v18 = a1;
v17 = a2;
std::operator<<<std::char_traits<char>>(*a1 + 40, " ;; if\n");
Generator::gen_expr(*a1, *a2);
v12 = *a1;
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>((long long)v16, (long long)"rax", (long long)&v15);
Generator::pop(v12, (long long)v16);
std::string::~string((long long)v16);
std::allocator<char>::~allocator(&v15);
Generator::create_label[abi:cxx11](v14, *a1);
std::operator<<<std::char_traits<char>>(*a1 + 40, " test rax, rax\n");
v11 = std::operator<<<std::char_traits<char>>(*a1 + 40, " jz ");
v10 = std::operator<<<char>(v11, v14);
std::operator<<<std::char_traits<char>>(v10, "\n");
Generator::gen_scope((Generator *)*a1, v17[1]);
if ( (std::optional<NodeIfPred *>::has_value(v17 + 2) & 1) != 0 )
{
Generator::create_label[abi:cxx11](v13, *a1);
v9 = std::operator<<<std::char_traits<char>>(*a1 + 40, " jmp ");
v8 = std::operator<<<char>(v9, v13);
std::operator<<<std::char_traits<char>>(v8, "\n");
v7 = std::operator<<<char>(*a1 + 40, v14);
std::operator<<<std::char_traits<char>>(v7, ":\n");
v5 = *a1;
v6 = (_QWORD *)std::optional<NodeIfPred *>::value(v17 + 2);
Generator::gen_if_pred(v5, *v6, v13);
v4 = std::operator<<<char>(*a1 + 40, v13);
std::operator<<<std::char_traits<char>>(v4, ":\n");
std::string::~string((long long)v13);
}
else
{
v3 = std::operator<<<char>(*a1 + 40, v14);
std::operator<<<std::char_traits<char>>(v3, ":\n");
}
std::operator<<<std::char_traits<char>>(*a1 + 40, " ;; /if\n");
return std::string::~string((long long)v14);
}
| operator():
PUSH RBP
MOV RBP,RSP
SUB RSP,0xf0
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0xa0],RAX
MOV RDI,qword ptr [RAX]
ADD RDI,0x28
LEA RSI,[0x117538]
CALL 0x001031c0
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RAX]
CALL 0x001114c0
MOV RAX,qword ptr [RBP + -0xa0]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x98],RAX
LEA RDI,[RBP + -0x31]
MOV qword ptr [RBP + -0x90],RDI
CALL 0x001032e0
MOV RDX,qword ptr [RBP + -0x90]
LAB_0011514f:
LEA RSI,[0x117459]
LEA RDI,[RBP + -0x30]
CALL 0x001090b0
JMP 0x00115161
LAB_00115161:
MOV RDI,qword ptr [RBP + -0x98]
LEA RSI,[RBP + -0x30]
CALL 0x001114f0
LAB_00115171:
JMP 0x00115173
LAB_00115173:
LEA RDI,[RBP + -0x30]
CALL 0x00103bd0
LEA RDI,[RBP + -0x31]
CALL 0x00103220
MOV RAX,qword ptr [RBP + -0xa0]
MOV RSI,qword ptr [RAX]
LEA RDI,[RBP + -0x68]
CALL 0x00115440
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
ADD RDI,0x28
LAB_001151a6:
LEA RSI,[0x117543]
CALL 0x001031c0
JMP 0x001151b4
LAB_001151b4:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
ADD RDI,0x28
LEA RSI,[0x117556]
CALL 0x001031c0
MOV qword ptr [RBP + -0xa8],RAX
JMP 0x001151d7
LAB_001151d7:
MOV RDI,qword ptr [RBP + -0xa8]
LEA RSI,[RBP + -0x68]
CALL 0x001031a0
MOV qword ptr [RBP + -0xb0],RAX
JMP 0x001151f0
LAB_001151f0:
MOV RDI,qword ptr [RBP + -0xb0]
LEA RSI,[0x1173fc]
CALL 0x001031c0
JMP 0x00115205
LAB_00115205:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RAX + 0x8]
CALL 0x001144c0
JMP 0x0011521e
LAB_0011521e:
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x10
CALL 0x00115520
TEST AL,0x1
JNZ 0x00115234
JMP 0x001153bd
LAB_00115234:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RSI,qword ptr [RAX]
LEA RDI,[RBP + -0x88]
CALL 0x00115440
JMP 0x0011524c
LAB_0011524c:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
ADD RDI,0x28
LAB_0011525a:
LEA RSI,[0x11755e]
CALL 0x001031c0
MOV qword ptr [RBP + -0xb8],RAX
JMP 0x0011526f
LAB_0011526f:
MOV RDI,qword ptr [RBP + -0xb8]
LEA RSI,[RBP + -0x88]
CALL 0x001031a0
MOV qword ptr [RBP + -0xc0],RAX
JMP 0x0011528b
LAB_0011528b:
MOV RDI,qword ptr [RBP + -0xc0]
LEA RSI,[0x1173fc]
CALL 0x001031c0
JMP 0x001152a0
LAB_001152a0:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
ADD RDI,0x28
LEA RSI,[RBP + -0x68]
CALL 0x001031a0
MOV qword ptr [RBP + -0xc8],RAX
JMP 0x001152c0
LAB_001152c0:
MOV RDI,qword ptr [RBP + -0xc8]
LEA RSI,[0x1173da]
CALL 0x001031c0
JMP 0x001152d5
LAB_001152d5:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0xd8],RAX
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x10
CALL 0x00115580
MOV qword ptr [RBP + -0xd0],RAX
JMP 0x001152fc
LAB_001152fc:
MOV RDI,qword ptr [RBP + -0xd8]
MOV RAX,qword ptr [RBP + -0xd0]
MOV RSI,qword ptr [RAX]
LEA RDX,[RBP + -0x88]
CALL 0x00115540
JMP 0x0011531b
LAB_0011531b:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
ADD RDI,0x28
LEA RSI,[RBP + -0x88]
CALL 0x001031a0
MOV qword ptr [RBP + -0xe0],RAX
JMP 0x0011533e
LAB_0011533e:
MOV RDI,qword ptr [RBP + -0xe0]
LEA RSI,[0x1173da]
CALL 0x001031c0
JMP 0x00115353
LAB_00115353:
LEA RDI,[RBP + -0x88]
CALL 0x00103bd0
JMP 0x001153f4
LAB_001153bd:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
ADD RDI,0x28
LAB_001153cb:
LEA RSI,[RBP + -0x68]
CALL 0x001031a0
MOV qword ptr [RBP + -0xe8],RAX
JMP 0x001153dd
LAB_001153dd:
MOV RDI,qword ptr [RBP + -0xe8]
LEA RSI,[0x1173da]
CALL 0x001031c0
JMP 0x001153f2
LAB_001153f2:
JMP 0x001153f4
LAB_001153f4:
MOV RAX,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RAX]
ADD RDI,0x28
LEA RSI,[0x117567]
CALL 0x001031c0
LAB_0011540e:
JMP 0x00115410
LAB_00115410:
LEA RDI,[RBP + -0x68]
CALL 0x00103bd0
ADD RSP,0xf0
POP RBP
RET
|
/* Generator::gen_stmt(NodeStmt const*)::StmtVisitor::TEMPNAMEPLACEHOLDERVALUE(NodeStmtIf const*)
const */
void __thiscall
Generator::gen_stmt(NodeStmt_const*)::StmtVisitor::operator()(StmtVisitor *this,NodeStmtIf *param_1)
{
Generator *pGVar1;
ostream *poVar2;
ulong uVar3;
int8 *puVar4;
string local_90 [32];
string local_70 [55];
allocator local_39;
string local_38 [32];
NodeStmtIf *local_18;
StmtVisitor *local_10;
local_18 = param_1;
local_10 = this;
std::operator<<((ostream *)(*(long *)this + 0x28)," ;; if\n");
gen_expr(*(Generator **)this,*(NodeExpr **)local_18);
pGVar1 = *(Generator **)this;
std::allocator<char>::allocator();
/* try { // try from 0011514f to 0011515e has its CatchHandler @ 00115364 */
std::__cxx11::string::string<std::allocator<char>>(local_38,"rax",&local_39);
/* try { // try from 00115161 to 00115170 has its CatchHandler @ 00115372 */
pop(pGVar1,local_38);
std::__cxx11::string::~string(local_38);
std::allocator<char>::~allocator((allocator<char> *)&local_39);
create_label_abi_cxx11_();
/* try { // try from 001151a6 to 00115249 has its CatchHandler @ 00115395 */
std::operator<<((ostream *)(*(long *)this + 0x28)," test rax, rax\n");
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28)," jz ");
poVar2 = std::operator<<(poVar2,local_70);
std::operator<<(poVar2,"\n");
gen_scope(*(Generator **)this,*(NodeScope **)(local_18 + 8));
uVar3 = std::optional<NodeIfPred*>::has_value((optional<NodeIfPred*> *)(local_18 + 0x10));
if ((uVar3 & 1) == 0) {
/* try { // try from 001153cb to 0011540d has its CatchHandler @ 00115395 */
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28),local_70);
std::operator<<(poVar2,":\n");
}
else {
create_label_abi_cxx11_();
/* try { // try from 0011525a to 00115350 has its CatchHandler @ 001153a3 */
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28)," jmp ");
poVar2 = std::operator<<(poVar2,local_90);
std::operator<<(poVar2,"\n");
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28),local_70);
std::operator<<(poVar2,":\n");
pGVar1 = *(Generator **)this;
puVar4 = (int8 *)
std::optional<NodeIfPred*>::value((optional<NodeIfPred*> *)(local_18 + 0x10));
gen_if_pred(pGVar1,(NodeIfPred *)*puVar4,local_90);
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28),local_90);
std::operator<<(poVar2,":\n");
std::__cxx11::string::~string(local_90);
}
std::operator<<((ostream *)(*(long *)this + 0x28)," ;; /if\n");
std::__cxx11::string::~string(local_70);
return;
}
| |
55,554 | Generator::gen_stmt(NodeStmt const*)::StmtVisitor::operator()(NodeStmtIf const*) const | BhuvanGudi[P]LexiParse/src/generation.hpp | void operator()(const NodeStmtIf* stmt_if) const
{
gen.m_output << " ;; if\n";
gen.gen_expr(stmt_if->expr);
gen.pop("rax");
const std::string label = gen.create_label();
gen.m_output << " test rax, rax\n";
gen.m_output << " jz " << label << "\n";
gen.gen_scope(stmt_if->scope);
if (stmt_if->pred.has_value()) {
const std::string end_label = gen.create_label();
gen.m_output << " jmp " << end_label << "\n";
gen.m_output << label << ":\n";
gen.gen_if_pred(stmt_if->pred.value(), end_label);
gen.m_output << end_label << ":\n";
}
else {
gen.m_output << label << ":\n";
}
gen.m_output << " ;; /if\n";
} | O2 | cpp | Generator::gen_stmt(NodeStmt const*)::StmtVisitor::operator()(NodeStmtIf const*) const:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq (%rdi), %rdi
addq $0x28, %rdi
leaq 0x1779(%rip), %rsi # 0x84f8
callq 0x21a0
movq (%rbx), %rax
movq (%r14), %rsi
leaq 0x8(%rsp), %rdi
movq %rax, (%rdi)
movzbl 0x8(%rsi), %eax
leaq 0x5fa3(%rip), %rcx # 0xcd40
callq *(%rcx,%rax,8)
movq (%rbx), %r15
leaq 0x166f(%rip), %rsi # 0x8419
leaq 0x8(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x43bc
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x5e6e
leaq 0x8(%rsp), %rdi
callq 0x27ea
movq (%rbx), %rsi
leaq 0x8(%rsp), %rdi
callq 0x6f64
movq (%rbx), %rdi
addq $0x28, %rdi
leaq 0x1718(%rip), %rsi # 0x8503
callq 0x21a0
movq (%rbx), %rdi
addq $0x28, %rdi
leaq 0x1718(%rip), %rsi # 0x8516
callq 0x21a0
leaq 0x8(%rsp), %rsi
movq %rax, %rdi
callq 0x2190
leaq 0x15c6(%rip), %rsi # 0x83dd
movq %rax, %rdi
callq 0x21a0
movq (%rbx), %rdi
movq 0x8(%r14), %rsi
callq 0x6a9e
cmpb $0x1, 0x18(%r14)
jne 0x6eed
movq (%rbx), %rsi
leaq 0x28(%rsp), %rdi
callq 0x6f64
movq (%rbx), %rdi
addq $0x28, %rdi
leaq 0x16cd(%rip), %rsi # 0x851e
callq 0x21a0
leaq 0x28(%rsp), %r15
movq %rax, %rdi
movq %r15, %rsi
callq 0x2190
leaq 0x1570(%rip), %rsi # 0x83dd
movq %rax, %rdi
callq 0x21a0
movq (%rbx), %rdi
addq $0x28, %rdi
leaq 0x8(%rsp), %rsi
callq 0x2190
leaq 0x152e(%rip), %rsi # 0x83bb
movq %rax, %rdi
callq 0x21a0
addq $0x10, %r14
movq (%rbx), %r12
movq %r14, %rdi
callq 0x6fdc
movq (%rax), %rsi
leaq 0x48(%rsp), %rdi
movq %r12, (%rdi)
movq %r15, 0x8(%rdi)
movzbl 0x8(%rsi), %eax
leaq 0x5eca(%rip), %rcx # 0xcd88
callq *(%rcx,%rax,8)
movq (%rbx), %rdi
addq $0x28, %rdi
leaq 0x28(%rsp), %rsi
callq 0x2190
leaq 0x14e2(%rip), %rsi # 0x83bb
movq %rax, %rdi
callq 0x21a0
leaq 0x28(%rsp), %rdi
callq 0x27ea
jmp 0x6f0d
movq (%rbx), %rdi
addq $0x28, %rdi
leaq 0x8(%rsp), %rsi
callq 0x2190
leaq 0x14b6(%rip), %rsi # 0x83bb
movq %rax, %rdi
callq 0x21a0
movq (%rbx), %rdi
addq $0x28, %rdi
leaq 0x160c(%rip), %rsi # 0x8527
callq 0x21a0
leaq 0x8(%rsp), %rdi
callq 0x27ea
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0x6f4e
jmp 0x6f4e
movq %rax, %rbx
jmp 0x6f5b
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x27ea
jmp 0x6f51
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x27ea
movq %rbx, %rdi
callq 0x2270
nop
| _ZZN9Generator8gen_stmtEPK8NodeStmtENK11StmtVisitorclEPK10NodeStmtIf:
push r15
push r14
push r12
push rbx
sub rsp, 58h
mov r14, rsi
mov rbx, rdi
mov rdi, [rdi]
add rdi, 28h ; '('
lea rsi, aIf_0; " ;; if\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov rax, [rbx]
mov rsi, [r14]
lea rdi, [rsp+78h+var_70]
mov [rdi], rax
movzx eax, byte ptr [rsi+8]
lea rcx, _ZNSt8__detail9__variant12__gen_vtableINS0_21__deduce_visit_resultIvEERZN9Generator8gen_exprEPK8NodeExprE11ExprVisitorJRKSt7variantIJP8NodeTermP11NodeBinExprEEEE9_S_vtableE; std::__detail::__variant::__gen_vtable<std::__detail::__variant::__deduce_visit_result<void>,Generator::gen_expr(NodeExpr const*)::ExprVisitor &,std::variant<NodeTerm *,NodeBinExpr *> const&>::_S_vtable
call ds:(_ZNSt8__detail9__variant12__gen_vtableINS0_21__deduce_visit_resultIvEERZN9Generator8gen_exprEPK8NodeExprE11ExprVisitorJRKSt7variantIJP8NodeTermP11NodeBinExprEEEE9_S_vtableE - 0CD40h)[rcx+rax*8]; std::__detail::__variant::__gen_vtable_impl<std::__detail::__variant::_Multi_array<std::__detail::__variant::__deduce_visit_result<void> (*)(Generator::gen_expr(NodeExpr const*)::ExprVisitor &,std::variant<NodeTerm *,NodeBinExpr *> const&)>,std::integer_sequence<ulong,0ul>>::__visit_invoke(Generator::gen_expr(NodeExpr const*)::ExprVisitor &,std::variant<NodeTerm *,NodeBinExpr *> const&)
mov r15, [rbx]
lea rsi, aRax; "rax"
lea rdi, [rsp+78h+var_70]
lea rdx, [rsp+78h+var_50]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rsi, [rsp+78h+var_70]
mov rdi, r15
call _ZN9Generator3popERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; Generator::pop(std::string const&)
lea rdi, [rsp+78h+var_70]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rsi, [rbx]
lea rdi, [rsp+78h+var_70]
call _ZN9Generator12create_labelB5cxx11Ev; Generator::create_label(void)
mov rdi, [rbx]
add rdi, 28h ; '('
lea rsi, aTestRaxRax; " test rax, rax\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov rdi, [rbx]
add rdi, 28h ; '('
lea rsi, aJz; " jz "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
lea rsi, [rsp+78h+var_70]
mov rdi, rax
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
lea rsi, aMovRdi0+0Eh; "\n"
mov rdi, rax
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov rdi, [rbx]; this
mov rsi, [r14+8]
call _ZN9Generator9gen_scopeEPK9NodeScope; Generator::gen_scope(NodeScope const*)
cmp byte ptr [r14+18h], 1
jnz loc_6EED
mov rsi, [rbx]
lea rdi, [rsp+78h+var_50]
call _ZN9Generator12create_labelB5cxx11Ev; Generator::create_label(void)
mov rdi, [rbx]
add rdi, 28h ; '('
lea rsi, aJmp; " jmp "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
lea r15, [rsp+78h+var_50]
mov rdi, rax
mov rsi, r15
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
lea rsi, aMovRdi0+0Eh; "\n"
mov rdi, rax
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov rdi, [rbx]
add rdi, 28h ; '('
lea rsi, [rsp+78h+var_70]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
lea rsi, aGlobalStartSta+14h; ":\n"
mov rdi, rax
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
add r14, 10h
mov r12, [rbx]
mov rdi, r14
call _ZNKRSt8optionalIP10NodeIfPredE5valueEv; std::optional<NodeIfPred *>::value(void)
mov rsi, [rax]
lea rdi, [rsp+78h+var_30]
mov [rdi], r12
mov [rdi+8], r15
movzx eax, byte ptr [rsi+8]
lea rcx, _ZNSt8__detail9__variant12__gen_vtableINS0_21__deduce_visit_resultIvEERZN9Generator11gen_if_predEPK10NodeIfPredRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE11PredVisitorJRKSt7variantIJP14NodeIfPredElifP14NodeIfPredElseEEEE9_S_vtableE; std::__detail::__variant::__gen_vtable<std::__detail::__variant::__deduce_visit_result<void>,Generator::gen_if_pred(NodeIfPred const*,std::string const&)::PredVisitor &,std::variant<NodeIfPredElif *,NodeIfPredElse *> const&>::_S_vtable
call ds:(_ZNSt8__detail9__variant12__gen_vtableINS0_21__deduce_visit_resultIvEERZN9Generator11gen_if_predEPK10NodeIfPredRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE11PredVisitorJRKSt7variantIJP14NodeIfPredElifP14NodeIfPredElseEEEE9_S_vtableE - 0CD88h)[rcx+rax*8]; std::__detail::__variant::__gen_vtable_impl<std::__detail::__variant::_Multi_array<std::__detail::__variant::__deduce_visit_result<void> (*)(Generator::gen_if_pred(NodeIfPred const*,std::string const&)::PredVisitor &,std::variant<NodeIfPredElif *,NodeIfPredElse *> const&)>,std::integer_sequence<ulong,0ul>>::__visit_invoke(Generator::gen_if_pred(NodeIfPred const*,std::string const&)::PredVisitor &,std::variant<NodeIfPredElif *,NodeIfPredElse *> const&)
mov rdi, [rbx]
add rdi, 28h ; '('
lea rsi, [rsp+78h+var_50]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
lea rsi, aGlobalStartSta+14h; ":\n"
mov rdi, rax
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
lea rdi, [rsp+78h+var_50]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_6F0D
loc_6EED:
mov rdi, [rbx]
add rdi, 28h ; '('
lea rsi, [rsp+78h+var_70]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
lea rsi, aGlobalStartSta+14h; ":\n"
mov rdi, rax
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
loc_6F0D:
mov rdi, [rbx]
add rdi, 28h ; '('
lea rsi, aIf_1; " ;; /if\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
lea rdi, [rsp+78h+var_70]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
add rsp, 58h
pop rbx
pop r12
pop r14
pop r15
retn
jmp short loc_6F4E
jmp short loc_6F4E
mov rbx, rax
jmp short loc_6F5B
mov rbx, rax
lea rdi, [rsp+arg_20]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_6F51
loc_6F4E:
mov rbx, rax
loc_6F51:
lea rdi, [rsp+arg_0]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_6F5B:
mov rdi, rbx
call __Unwind_Resume
| long long Generator::gen_stmt(NodeStmt const*)::StmtVisitor::operator()(
Generator **a1,
long long *a2,
long long a3)
{
long long v4; // rsi
long long v5; // r15
long long v6; // rdx
long long v7; // rdx
long long v8; // rdx
long long v9; // rax
long long v10; // rax
long long v11; // rdx
long long v12; // rdx
long long v13; // rax
long long v14; // rax
long long v15; // rdx
long long v16; // rax
long long v17; // rdx
Generator *v18; // r12
long long v19; // rsi
long long v20; // rax
long long v21; // rdx
long long v22; // rdx
long long v23; // rax
long long v24; // rdx
long long result; // rax
_QWORD v26[4]; // [rsp+8h] [rbp-70h] BYREF
_BYTE v27[32]; // [rsp+28h] [rbp-50h] BYREF
Generator *v28; // [rsp+48h] [rbp-30h]
_BYTE *v29; // [rsp+50h] [rbp-28h]
std::operator<<<std::char_traits<char>>((char *)*a1 + 40, " ;; if\n", a3);
v4 = *a2;
v26[0] = *a1;
((void ( *)(_QWORD *))*(&std::__detail::__variant::__gen_vtable<std::__detail::__variant::__deduce_visit_result<void>,Generator::gen_expr(NodeExpr const*)::ExprVisitor &,std::variant<NodeTerm *,NodeBinExpr *> const&>::_S_vtable
+ *(unsigned __int8 *)(v4 + 8)))(v26);
v5 = (long long)*a1;
std::string::basic_string<std::allocator<char>>(v26, (long long)"rax");
Generator::pop(v5, (long long)v26, v6);
std::string::~string();
Generator::create_label[abi:cxx11](v26, *a1);
std::operator<<<std::char_traits<char>>((char *)*a1 + 40, " test rax, rax\n", v7);
v9 = std::operator<<<std::char_traits<char>>((char *)*a1 + 40, " jz ", v8);
v10 = std::operator<<<char>(v9, v26);
std::operator<<<std::char_traits<char>>(v10, "\n", v11);
Generator::gen_scope(*a1, (long long **)a2[1]);
if ( *((_BYTE *)a2 + 24) == 1 )
{
Generator::create_label[abi:cxx11](v27, *a1);
v13 = std::operator<<<std::char_traits<char>>((char *)*a1 + 40, " jmp ", v12);
v14 = std::operator<<<char>(v13, v27);
std::operator<<<std::char_traits<char>>(v14, "\n", v15);
v16 = std::operator<<<char>((char *)*a1 + 40, v26);
std::operator<<<std::char_traits<char>>(v16, ":\n", v17);
v18 = *a1;
v19 = *(_QWORD *)std::optional<NodeIfPred *>::value(a2 + 2);
v28 = v18;
v29 = v27;
(*(&std::__detail::__variant::__gen_vtable<std::__detail::__variant::__deduce_visit_result<void>,Generator::gen_if_pred(NodeIfPred const*,std::string const&)::PredVisitor &,std::variant<NodeIfPredElif *,NodeIfPredElse *> const&>::_S_vtable
+ *(unsigned __int8 *)(v19 + 8)))();
v20 = std::operator<<<char>((char *)*a1 + 40, v27);
std::operator<<<std::char_traits<char>>(v20, ":\n", v21);
std::string::~string();
}
else
{
v23 = std::operator<<<char>((char *)*a1 + 40, v26);
std::operator<<<std::char_traits<char>>(v23, ":\n", v24);
}
result = std::operator<<<std::char_traits<char>>((char *)*a1 + 40, " ;; /if\n", v22);
std::string::~string();
return result;
}
| operator():
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x58
MOV R14,RSI
MOV RBX,RDI
MOV RDI,qword ptr [RDI]
ADD RDI,0x28
LEA RSI,[0x1084f8]
CALL 0x001021a0
MOV RAX,qword ptr [RBX]
MOV RSI,qword ptr [R14]
LEA RDI,[RSP + 0x8]
MOV qword ptr [RDI],RAX
MOVZX EAX,byte ptr [RSI + 0x8]
LEA RCX,[0x10cd40]
CALL qword ptr [RCX + RAX*0x8]
MOV R15,qword ptr [RBX]
LAB_00106da3:
LEA RSI,[0x108419]
LEA RDI,[RSP + 0x8]
LEA RDX,[RSP + 0x28]
CALL 0x001043bc
LAB_00106db9:
LEA RSI,[RSP + 0x8]
MOV RDI,R15
CALL 0x00105e6e
LAB_00106dc6:
LEA RDI,[RSP + 0x8]
CALL 0x001027ea
MOV RSI,qword ptr [RBX]
LEA RDI,[RSP + 0x8]
CALL 0x00106f64
MOV RDI,qword ptr [RBX]
ADD RDI,0x28
LAB_00106de4:
LEA RSI,[0x108503]
CALL 0x001021a0
MOV RDI,qword ptr [RBX]
ADD RDI,0x28
LEA RSI,[0x108516]
CALL 0x001021a0
LEA RSI,[RSP + 0x8]
MOV RDI,RAX
CALL 0x00102190
LEA RSI,[0x1083dd]
MOV RDI,RAX
CALL 0x001021a0
MOV RDI,qword ptr [RBX]
MOV RSI,qword ptr [R14 + 0x8]
CALL 0x00106a9e
CMP byte ptr [R14 + 0x18],0x1
JNZ 0x00106eed
MOV RSI,qword ptr [RBX]
LAB_00106e39:
LEA RDI,[RSP + 0x28]
CALL 0x00106f64
MOV RDI,qword ptr [RBX]
ADD RDI,0x28
LAB_00106e4a:
LEA RSI,[0x10851e]
CALL 0x001021a0
LEA R15,[RSP + 0x28]
MOV RDI,RAX
MOV RSI,R15
CALL 0x00102190
LEA RSI,[0x1083dd]
MOV RDI,RAX
CALL 0x001021a0
MOV RDI,qword ptr [RBX]
ADD RDI,0x28
LEA RSI,[RSP + 0x8]
CALL 0x00102190
LEA RSI,[0x1083bb]
MOV RDI,RAX
CALL 0x001021a0
ADD R14,0x10
MOV R12,qword ptr [RBX]
MOV RDI,R14
CALL 0x00106fdc
MOV RSI,qword ptr [RAX]
LEA RDI,[RSP + 0x48]
MOV qword ptr [RDI],R12
MOV qword ptr [RDI + 0x8],R15
MOVZX EAX,byte ptr [RSI + 0x8]
LEA RCX,[0x10cd88]
CALL qword ptr [RCX + RAX*0x8]
MOV RDI,qword ptr [RBX]
ADD RDI,0x28
LEA RSI,[RSP + 0x28]
CALL 0x00102190
LEA RSI,[0x1083bb]
MOV RDI,RAX
CALL 0x001021a0
LEA RDI,[RSP + 0x28]
CALL 0x001027ea
JMP 0x00106f0d
LAB_00106eed:
MOV RDI,qword ptr [RBX]
ADD RDI,0x28
LAB_00106ef4:
LEA RSI,[RSP + 0x8]
CALL 0x00102190
LEA RSI,[0x1083bb]
MOV RDI,RAX
CALL 0x001021a0
LAB_00106f0d:
MOV RDI,qword ptr [RBX]
ADD RDI,0x28
LEA RSI,[0x108527]
CALL 0x001021a0
LAB_00106f20:
LEA RDI,[RSP + 0x8]
CALL 0x001027ea
ADD RSP,0x58
POP RBX
POP R12
POP R14
POP R15
RET
|
/* Generator::gen_stmt(NodeStmt const*)::StmtVisitor::TEMPNAMEPLACEHOLDERVALUE(NodeStmtIf const*)
const */
void __thiscall
Generator::gen_stmt(NodeStmt_const*)::StmtVisitor::operator()(StmtVisitor *this,NodeStmtIf *param_1)
{
Generator *this_00;
int8 uVar1;
ostream *poVar2;
long *plVar3;
int8 local_70 [4];
allocator local_50 [32];
int8 local_30;
string *local_28;
std::operator<<((ostream *)(*(long *)this + 0x28)," ;; if\n");
local_70[0] = *(int8 *)this;
(**(code **)(std::__detail::__variant::
__gen_vtable<std::__detail::__variant::__deduce_visit_result<void>,Generator::gen_expr(NodeExpr_const*)::ExprVisitor&,std::variant<NodeTerm*,NodeBinExpr*>const&>
::_S_vtable + (ulong)*(byte *)(*(long *)param_1 + 8) * 8))();
this_00 = *(Generator **)this;
/* try { // try from 00106da3 to 00106db8 has its CatchHandler @ 00106f3a */
std::__cxx11::string::string<std::allocator<char>>((string *)local_70,"rax",local_50);
/* try { // try from 00106db9 to 00106dc5 has its CatchHandler @ 00106f38 */
pop(this_00,(string *)local_70);
std::__cxx11::string::~string((string *)local_70);
create_label_abi_cxx11_();
/* try { // try from 00106de4 to 00106e2a has its CatchHandler @ 00106f4e */
std::operator<<((ostream *)(*(long *)this + 0x28)," test rax, rax\n");
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28)," jz ");
poVar2 = std::operator<<(poVar2,(string *)local_70);
std::operator<<(poVar2,"\n");
gen_scope(*(Generator **)this,*(NodeScope **)(param_1 + 8));
if (param_1[0x18] == (NodeStmtIf)0x1) {
/* try { // try from 00106e39 to 00106e42 has its CatchHandler @ 00106f36 */
create_label_abi_cxx11_();
/* try { // try from 00106e4a to 00106ee0 has its CatchHandler @ 00106f3f */
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28)," jmp ");
poVar2 = std::operator<<(poVar2,(string *)local_50);
std::operator<<(poVar2,"\n");
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28),(string *)local_70);
std::operator<<(poVar2,":\n");
uVar1 = *(int8 *)this;
plVar3 = (long *)std::optional<NodeIfPred*>::value();
local_30 = uVar1;
local_28 = (string *)local_50;
(**(code **)(std::__detail::__variant::
__gen_vtable<std::__detail::__variant::__deduce_visit_result<void>,Generator::gen_if_pred(NodeIfPred_const*,std::__cxx11::string_const&)::PredVisitor&,std::variant<NodeIfPredElif*,NodeIfPredElse*>const&>
::_S_vtable + (ulong)*(byte *)(*plVar3 + 8) * 8))();
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28),(string *)local_50);
std::operator<<(poVar2,":\n");
std::__cxx11::string::~string((string *)local_50);
}
else {
/* try { // try from 00106ef4 to 00106f1f has its CatchHandler @ 00106f4e */
poVar2 = std::operator<<((ostream *)(*(long *)this + 0x28),(string *)local_70);
std::operator<<(poVar2,":\n");
}
std::operator<<((ostream *)(*(long *)this + 0x28)," ;; /if\n");
std::__cxx11::string::~string((string *)local_70);
return;
}
| |
55,555 | ma_get_indicator | eloqsql/libmariadb/libmariadb/mariadb_stmt.c | static signed char ma_get_indicator(MYSQL_STMT *stmt, unsigned int param_nr, unsigned long row_nr)
{
if (!MARIADB_STMT_BULK_SUPPORTED(stmt) ||
!stmt->array_size ||
!stmt->params[param_nr].u.indicator)
return 0;
if (stmt->param_callback)
return *stmt->params[param_nr].u.indicator;
if (stmt->row_size)
return *((char *)stmt->params[param_nr].u.indicator + (row_nr * stmt->row_size));
return stmt->params[param_nr].u.indicator[row_nr];
} | O3 | c | ma_get_indicator:
movq 0x38(%rdi), %rax
testq %rax, %rax
je 0x1ff6d
pushq %rbp
movq %rsp, %rbp
testb $0x1, 0x370(%rax)
jne 0x1ff69
movq 0x4f0(%rax), %rax
testb $0x4, 0x70(%rax)
je 0x1ff69
cmpl $0x0, 0x368(%rdi)
je 0x1ff69
movq 0x70(%rdi), %rax
movl %esi, %ecx
imulq $0x70, %rcx, %rcx
movq 0x20(%rax,%rcx), %rax
testq %rax, %rax
je 0x1ff69
cmpq $0x0, 0x390(%rdi)
jne 0x1ff73
movq 0x370(%rdi), %rcx
testq %rcx, %rcx
je 0x1ff70
imulq %rdx, %rcx
addq %rcx, %rax
jmp 0x1ff73
xorl %eax, %eax
popq %rbp
retq
xorl %eax, %eax
retq
addq %rdx, %rax
movb (%rax), %al
jmp 0x1ff6b
| ma_get_indicator:
mov rax, [rdi+38h]
test rax, rax
jz short loc_1FF6D
push rbp
mov rbp, rsp
test byte ptr [rax+370h], 1
jnz short loc_1FF69
mov rax, [rax+4F0h]
test byte ptr [rax+70h], 4
jz short loc_1FF69
cmp dword ptr [rdi+368h], 0
jz short loc_1FF69
mov rax, [rdi+70h]
mov ecx, esi
imul rcx, 70h ; 'p'
mov rax, [rax+rcx+20h]
test rax, rax
jz short loc_1FF69
cmp qword ptr [rdi+390h], 0
jnz short loc_1FF73
mov rcx, [rdi+370h]
test rcx, rcx
jz short loc_1FF70
imul rcx, rdx
add rax, rcx
jmp short loc_1FF73
loc_1FF69:
xor eax, eax
loc_1FF6B:
pop rbp
retn
loc_1FF6D:
xor eax, eax
retn
loc_1FF70:
add rax, rdx
loc_1FF73:
mov al, [rax]
jmp short loc_1FF6B
| char ma_get_indicator(long long a1, unsigned int a2, long long a3)
{
long long v3; // rax
long long v4; // rax
long long v5; // rcx
v3 = *(_QWORD *)(a1 + 56);
if ( !v3 )
return 0;
if ( (*(_BYTE *)(v3 + 880) & 1) != 0 )
return 0;
if ( (*(_BYTE *)(*(_QWORD *)(v3 + 1264) + 112LL) & 4) == 0 )
return 0;
if ( !*(_DWORD *)(a1 + 872) )
return 0;
v4 = *(_QWORD *)(*(_QWORD *)(a1 + 112) + 112LL * a2 + 32);
if ( !v4 )
return 0;
if ( !*(_QWORD *)(a1 + 912) )
{
v5 = *(_QWORD *)(a1 + 880);
if ( v5 )
v4 += a3 * v5;
else
v4 += a3;
}
return *(_BYTE *)v4;
}
| ma_get_indicator:
MOV RAX,qword ptr [RDI + 0x38]
TEST RAX,RAX
JZ 0x0011ff6d
PUSH RBP
MOV RBP,RSP
TEST byte ptr [RAX + 0x370],0x1
JNZ 0x0011ff69
MOV RAX,qword ptr [RAX + 0x4f0]
TEST byte ptr [RAX + 0x70],0x4
JZ 0x0011ff69
CMP dword ptr [RDI + 0x368],0x0
JZ 0x0011ff69
MOV RAX,qword ptr [RDI + 0x70]
MOV ECX,ESI
IMUL RCX,RCX,0x70
MOV RAX,qword ptr [RAX + RCX*0x1 + 0x20]
TEST RAX,RAX
JZ 0x0011ff69
CMP qword ptr [RDI + 0x390],0x0
JNZ 0x0011ff73
MOV RCX,qword ptr [RDI + 0x370]
TEST RCX,RCX
JZ 0x0011ff70
IMUL RCX,RDX
ADD RAX,RCX
JMP 0x0011ff73
LAB_0011ff69:
XOR EAX,EAX
LAB_0011ff6b:
POP RBP
RET
LAB_0011ff6d:
XOR EAX,EAX
RET
LAB_0011ff70:
ADD RAX,RDX
LAB_0011ff73:
MOV AL,byte ptr [RAX]
JMP 0x0011ff6b
|
int8 ma_get_indicator(long param_1,uint param_2,long param_3)
{
long lVar1;
int1 *puVar2;
int8 uVar3;
lVar1 = *(long *)(param_1 + 0x38);
if (lVar1 != 0) {
if (((((*(byte *)(lVar1 + 0x370) & 1) == 0) &&
((*(byte *)(*(long *)(lVar1 + 0x4f0) + 0x70) & 4) != 0)) &&
(*(int *)(param_1 + 0x368) != 0)) &&
(puVar2 = *(int1 **)(*(long *)(param_1 + 0x70) + 0x20 + (ulong)param_2 * 0x70),
puVar2 != (int1 *)0x0)) {
if (*(long *)(param_1 + 0x390) == 0) {
if (*(long *)(param_1 + 0x370) == 0) {
puVar2 = puVar2 + param_3;
}
else {
puVar2 = puVar2 + *(long *)(param_1 + 0x370) * param_3;
}
}
uVar3 = CONCAT71((int7)((ulong)puVar2 >> 8),*puVar2);
}
else {
uVar3 = 0;
}
return uVar3;
}
return 0;
}
| |
55,556 | minco::MINCO<3, 3, 1>::getEnergy() const | zusiliang[P]myMINCO/minco.hpp | inline double getEnergy() const
{
double energy = 0;
for(int Ti = 0; Ti < N; Ti++)
energy += Op::getEnergy_diag(c, T, Ti, make_int_sequence<s>()) +
2 * Op::getEnergy_edge(c, T, Ti, make_int_sequence<s>());
return energy;
} | O2 | cpp | minco::MINCO<3, 3, 1>::getEnergy() const:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
leaq 0x80(%rdi), %r14
leaq 0x90(%rdi), %r15
xorl %ebp, %ebp
xorpd %xmm0, %xmm0
cmpl (%rbx), %ebp
jge 0x3843
movq %r14, %rdi
movq %r15, %rsi
movl %ebp, %edx
movsd %xmm0, 0x8(%rsp)
callq 0x84f6
movsd %xmm0, 0x10(%rsp)
movq %r14, %rdi
movq %r15, %rsi
movl %ebp, %edx
callq 0x859e
addsd %xmm0, %xmm0
addsd 0x10(%rsp), %xmm0
movsd 0x8(%rsp), %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, 0x8(%rsp)
movsd 0x8(%rsp), %xmm0
incl %ebp
jmp 0x37f5
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| _ZNK5minco5MINCOILi3ELi2ELi0EE9getEnergyEv:
push rbp
push r15
push r14
push rbx
sub rsp, 18h
mov rbx, rdi
lea r14, [rdi+80h]
lea r15, [rdi+90h]
xor ebp, ebp
xorpd xmm0, xmm0
loc_37F5:
cmp ebp, [rbx]
jge short loc_3843
mov rdi, r14
mov rsi, r15
mov edx, ebp
movsd [rsp+38h+var_30], xmm0
call _ZN5minco8MINCO_opILi3ELi2ELi0EE14getEnergy_diagIJLi0ELi1ELi2EEEEdRKN5Eigen6MatrixIdLin1ELi2ELi0ELin1ELi2EEERKNS4_IdLi6ELin1ELi0ELi6ELin1EEEiSt16integer_sequenceIiJXspT_EEE
movsd [rsp+38h+var_28], xmm0
mov rdi, r14
mov rsi, r15
mov edx, ebp
call _ZN5minco8MINCO_opILi3ELi2ELi0EE14getEnergy_edgeIJLi0ELi1ELi2EEEEdRKN5Eigen6MatrixIdLin1ELi2ELi0ELin1ELi2EEERKNS4_IdLi6ELin1ELi0ELi6ELin1EEEiSt16integer_sequenceIiJXspT_EEE
addsd xmm0, xmm0
addsd xmm0, [rsp+38h+var_28]
movsd xmm1, [rsp+38h+var_30]
addsd xmm1, xmm0
movsd [rsp+38h+var_30], xmm1
movsd xmm0, [rsp+38h+var_30]
inc ebp
jmp short loc_37F5
loc_3843:
add rsp, 18h
pop rbx
pop r14
pop r15
pop rbp
retn
| void minco::MINCO<3,2,0>::getEnergy(_DWORD *a1)
{
_DWORD *v1; // r14
_DWORD *v2; // r15
unsigned int v3; // ebp
double v4; // xmm0_8
double v5; // xmm0_8
double v6; // [rsp+8h] [rbp-30h]
double Energy; // [rsp+10h] [rbp-28h]
v1 = a1 + 32;
v2 = a1 + 36;
v3 = 0;
v4 = 0.0;
while ( (signed int)v3 < *a1 )
{
v6 = v4;
Energy = minco::MINCO_op<3,2,0>::getEnergy_diag<0,1,2>(v1, v2, v3);
v5 = minco::MINCO_op<3,2,0>::getEnergy_edge<0,1,2>(v1, v2, v3);
v4 = v6 + v5 + v5 + Energy;
++v3;
}
}
| getEnergy:
PUSH RBP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x18
MOV RBX,RDI
LEA R14,[RDI + 0x80]
LEA R15,[RDI + 0x90]
XOR EBP,EBP
XORPD XMM0,XMM0
LAB_001037f5:
CMP EBP,dword ptr [RBX]
JGE 0x00103843
MOV RDI,R14
MOV RSI,R15
MOV EDX,EBP
MOVSD qword ptr [RSP + 0x8],XMM0
CALL 0x001084f6
MOVSD qword ptr [RSP + 0x10],XMM0
MOV RDI,R14
MOV RSI,R15
MOV EDX,EBP
CALL 0x0010859e
ADDSD XMM0,XMM0
ADDSD XMM0,qword ptr [RSP + 0x10]
MOVSD XMM1,qword ptr [RSP + 0x8]
ADDSD XMM1,XMM0
MOVSD qword ptr [RSP + 0x8],XMM1
MOVSD XMM0,qword ptr [RSP + 0x8]
INC EBP
JMP 0x001037f5
LAB_00103843:
ADD RSP,0x18
POP RBX
POP R14
POP R15
POP RBP
RET
|
/* minco::MINCO<3, 2, 0>::getEnergy() const */
void __thiscall minco::MINCO<3,2,0>::getEnergy(MINCO<3,2,0> *this)
{
int iVar1;
for (iVar1 = 0; iVar1 < *(int *)this; iVar1 = iVar1 + 1) {
MINCO_op<3,2,0>::getEnergy_diag<0,1,2>(this + 0x80,this + 0x90,iVar1);
MINCO_op<3,2,0>::getEnergy_edge<0,1,2>(this + 0x80,this + 0x90,iVar1);
}
return;
}
| |
55,557 | lunasvg::SVGMaskElement::maskBoundingBox(lunasvg::SVGElement const*) const | dmazzella[P]pylunasvg/lunasvg/source/svgelement.cpp | Rect SVGMaskElement::maskBoundingBox(const SVGElement* element) const
{
auto maskBoundingBox = paintBoundingBox();
if(m_maskContentUnits.value() == Units::ObjectBoundingBox) {
auto bbox = element->fillBoundingBox();
maskBoundingBox.x = maskBoundingBox.x * bbox.w + bbox.x;
maskBoundingBox.y = maskBoundingBox.y * bbox.h + bbox.y;
maskBoundingBox.w = maskBoundingBox.w * bbox.w;
maskBoundingBox.h = maskBoundingBox.h * bbox.h;
}
return maskBoundingBox.intersected(maskRect(element));
} | O0 | cpp | lunasvg::SVGMaskElement::maskBoundingBox(lunasvg::SVGElement const*) const:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x18(%rbp)
movq %rsi, -0x20(%rbp)
movq -0x18(%rbp), %rdi
movq %rdi, -0x58(%rbp)
callq 0x19560
movq -0x58(%rbp), %rdi
movlpd %xmm0, -0x30(%rbp)
movlpd %xmm1, -0x28(%rbp)
addq $0xe0, %rdi
callq 0x215f0
cmpb $0x1, %al
jne 0x19828
movq -0x20(%rbp), %rdi
movq (%rdi), %rax
movq 0x58(%rax), %rax
callq *%rax
movlpd %xmm0, -0x40(%rbp)
movlpd %xmm1, -0x38(%rbp)
movss -0x30(%rbp), %xmm0
movss -0x38(%rbp), %xmm2
movss -0x40(%rbp), %xmm1
mulss %xmm2, %xmm0
addss %xmm1, %xmm0
movss %xmm0, -0x30(%rbp)
movss -0x2c(%rbp), %xmm0
movss -0x34(%rbp), %xmm2
movss -0x3c(%rbp), %xmm1
mulss %xmm2, %xmm0
addss %xmm1, %xmm0
movss %xmm0, -0x2c(%rbp)
movss -0x28(%rbp), %xmm0
mulss -0x38(%rbp), %xmm0
movss %xmm0, -0x28(%rbp)
movss -0x24(%rbp), %xmm0
mulss -0x34(%rbp), %xmm0
movss %xmm0, -0x24(%rbp)
movq -0x58(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0x1d3c0
movlpd %xmm0, -0x50(%rbp)
movlpd %xmm1, -0x48(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x217c0
movlpd %xmm0, -0x10(%rbp)
movlpd %xmm1, -0x8(%rbp)
movsd -0x10(%rbp), %xmm0
movsd -0x8(%rbp), %xmm1
addq $0x60, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _ZNK7lunasvg14SVGMaskElement15maskBoundingBoxEPKNS_10SVGElementE:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_18], rdi
mov [rbp+var_20], rsi
mov rdi, [rbp+var_18]; this
mov [rbp+var_58], rdi
call _ZNK7lunasvg10SVGElement16paintBoundingBoxEv; lunasvg::SVGElement::paintBoundingBox(void)
mov rdi, [rbp+var_58]
movlpd [rbp+var_30], xmm0
movlpd [rbp+var_28], xmm1
add rdi, 0E0h
call _ZNK7lunasvg14SVGEnumerationINS_5UnitsEE5valueEv; lunasvg::SVGEnumeration<lunasvg::Units>::value(void)
cmp al, 1
jnz short loc_19828
mov rdi, [rbp+var_20]
mov rax, [rdi]
mov rax, [rax+58h]
call rax
movlpd [rbp+var_40], xmm0
movlpd [rbp+var_38], xmm1
movss xmm0, dword ptr [rbp+var_30]
movss xmm2, dword ptr [rbp+var_38]
movss xmm1, dword ptr [rbp+var_40]
mulss xmm0, xmm2
addss xmm0, xmm1
movss dword ptr [rbp+var_30], xmm0
movss xmm0, dword ptr [rbp+var_30+4]
movss xmm2, dword ptr [rbp+var_38+4]
movss xmm1, dword ptr [rbp+var_40+4]
mulss xmm0, xmm2
addss xmm0, xmm1
movss dword ptr [rbp+var_30+4], xmm0
movss xmm0, dword ptr [rbp+var_28]
mulss xmm0, dword ptr [rbp+var_38]
movss dword ptr [rbp+var_28], xmm0
movss xmm0, dword ptr [rbp+var_28+4]
mulss xmm0, dword ptr [rbp+var_38+4]
movss dword ptr [rbp+var_28+4], xmm0
loc_19828:
mov rdi, [rbp+var_58]; this
mov rsi, [rbp+var_20]; lunasvg::SVGElement *
call _ZNK7lunasvg14SVGMaskElement8maskRectEPKNS_10SVGElementE; lunasvg::SVGMaskElement::maskRect(lunasvg::SVGElement const*)
movlpd [rbp+var_50], xmm0
movlpd [rbp+var_48], xmm1
lea rdi, [rbp+var_30]; this
lea rsi, [rbp+var_50]; lunasvg::Rect *
call _ZNK7lunasvg4Rect11intersectedERKS0_; lunasvg::Rect::intersected(lunasvg::Rect const&)
movlpd [rbp+var_10], xmm0
movlpd [rbp+var_8], xmm1
movsd xmm0, [rbp+var_10]
movsd xmm1, [rbp+var_8]
add rsp, 60h
pop rbp
retn
| long long lunasvg::SVGMaskElement::maskBoundingBox(
lunasvg::SVGMaskElement *this,
const lunasvg::SVGElement *a2,
double a3,
double a4)
{
double v4; // xmm0_8
float v5; // xmm2_4
_QWORD v7[2]; // [rsp+10h] [rbp-50h] BYREF
double v8; // [rsp+20h] [rbp-40h]
double v9; // [rsp+28h] [rbp-38h]
double v10; // [rsp+30h] [rbp-30h] BYREF
double v11; // [rsp+38h] [rbp-28h]
lunasvg::SVGElement *v12; // [rsp+40h] [rbp-20h]
lunasvg::SVGElement *v13; // [rsp+48h] [rbp-18h]
v13 = this;
v12 = a2;
v4 = lunasvg::SVGElement::paintBoundingBox(this, a3, a4);
v10 = v4;
v11 = a4;
if ( (unsigned __int8)lunasvg::SVGEnumeration<lunasvg::Units>::value((char *)this + 224) == 1 )
{
v8 = (*(double ( **)(lunasvg::SVGElement *))(*(_QWORD *)v12 + 88LL))(v12);
v9 = a4;
*(float *)&v10 = (float)(*(float *)&v10 * *(float *)&a4) + *(float *)&v8;
v5 = *((float *)&a4 + 1);
*(_QWORD *)&a4 = HIDWORD(v8);
*((float *)&v10 + 1) = (float)(*((float *)&v10 + 1) * v5) + *((float *)&v8 + 1);
*(float *)&v11 = *(float *)&v11 * *(float *)&v9;
*(_QWORD *)&v4 = HIDWORD(v11);
*(float *)&v4 = *((float *)&v11 + 1) * *((float *)&v9 + 1);
*((float *)&v11 + 1) = *((float *)&v11 + 1) * *((float *)&v9 + 1);
}
lunasvg::SVGMaskElement::maskRect(this, v12);
*(double *)v7 = v4;
*(double *)&v7[1] = a4;
return lunasvg::Rect::intersected((lunasvg::Rect *)&v10, (const lunasvg::Rect *)v7);
}
| maskBoundingBox:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x18],RDI
MOV qword ptr [RBP + -0x20],RSI
MOV RDI,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x58],RDI
CALL 0x00119560
MOV RDI,qword ptr [RBP + -0x58]
MOVLPD qword ptr [RBP + -0x30],XMM0
MOVLPD qword ptr [RBP + -0x28],XMM1
ADD RDI,0xe0
CALL 0x001215f0
CMP AL,0x1
JNZ 0x00119828
MOV RDI,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX + 0x58]
CALL RAX
MOVLPD qword ptr [RBP + -0x40],XMM0
MOVLPD qword ptr [RBP + -0x38],XMM1
MOVSS XMM0,dword ptr [RBP + -0x30]
MOVSS XMM2,dword ptr [RBP + -0x38]
MOVSS XMM1,dword ptr [RBP + -0x40]
MULSS XMM0,XMM2
ADDSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x30],XMM0
MOVSS XMM0,dword ptr [RBP + -0x2c]
MOVSS XMM2,dword ptr [RBP + -0x34]
MOVSS XMM1,dword ptr [RBP + -0x3c]
MULSS XMM0,XMM2
ADDSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x2c],XMM0
MOVSS XMM0,dword ptr [RBP + -0x28]
MULSS XMM0,dword ptr [RBP + -0x38]
MOVSS dword ptr [RBP + -0x28],XMM0
MOVSS XMM0,dword ptr [RBP + -0x24]
MULSS XMM0,dword ptr [RBP + -0x34]
MOVSS dword ptr [RBP + -0x24],XMM0
LAB_00119828:
MOV RDI,qword ptr [RBP + -0x58]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x0011d3c0
MOVLPD qword ptr [RBP + -0x50],XMM0
MOVLPD qword ptr [RBP + -0x48],XMM1
LEA RDI,[RBP + -0x30]
LEA RSI,[RBP + -0x50]
CALL 0x001217c0
MOVLPD qword ptr [RBP + -0x10],XMM0
MOVLPD qword ptr [RBP + -0x8],XMM1
MOVSD XMM0,qword ptr [RBP + -0x10]
MOVSD XMM1,qword ptr [RBP + -0x8]
ADD RSP,0x60
POP RBP
RET
|
/* lunasvg::SVGMaskElement::maskBoundingBox(lunasvg::SVGElement const*) const */
int1 [16] lunasvg::SVGMaskElement::maskBoundingBox(SVGElement *param_1)
{
int1 auVar1 [16];
char cVar2;
SVGElement *in_RSI;
int8 uVar3;
ulong in_XMM1_Qa;
int8 local_58;
ulong local_50;
int8 local_48;
float local_40;
float fStack_3c;
int8 local_38;
int8 local_30;
SVGElement *local_28;
SVGElement *local_20;
local_28 = in_RSI;
local_20 = param_1;
local_38 = SVGElement::paintBoundingBox();
local_30 = in_XMM1_Qa;
cVar2 = SVGEnumeration<lunasvg::Units>::value((SVGEnumeration<lunasvg::Units> *)(param_1 + 0xe0));
if (cVar2 == '\x01') {
uVar3 = (**(code **)(*(long *)local_28 + 0x58))();
local_40 = (float)in_XMM1_Qa;
local_48._0_4_ = (float)uVar3;
fStack_3c = (float)(in_XMM1_Qa >> 0x20);
local_48._4_4_ = (float)((ulong)uVar3 >> 0x20);
in_XMM1_Qa = (ulong)(uint)local_48._4_4_;
local_38 = CONCAT44(local_38._4_4_ * fStack_3c + local_48._4_4_,
(float)local_38 * local_40 + (float)local_48);
local_30 = CONCAT44(local_30._4_4_ * fStack_3c,(float)local_30 * local_40);
local_48 = uVar3;
}
local_58 = maskRect((SVGMaskElement *)param_1,local_28);
local_50 = in_XMM1_Qa;
uVar3 = Rect::intersected((Rect *)&local_38,(Rect *)&local_58);
auVar1._8_8_ = in_XMM1_Qa;
auVar1._0_8_ = uVar3;
return auVar1;
}
| |
55,558 | lunasvg::SVGMaskElement::maskBoundingBox(lunasvg::SVGElement const*) const | dmazzella[P]pylunasvg/lunasvg/source/svgelement.cpp | Rect SVGMaskElement::maskBoundingBox(const SVGElement* element) const
{
auto maskBoundingBox = paintBoundingBox();
if(m_maskContentUnits.value() == Units::ObjectBoundingBox) {
auto bbox = element->fillBoundingBox();
maskBoundingBox.x = maskBoundingBox.x * bbox.w + bbox.x;
maskBoundingBox.y = maskBoundingBox.y * bbox.h + bbox.y;
maskBoundingBox.w = maskBoundingBox.w * bbox.w;
maskBoundingBox.h = maskBoundingBox.h * bbox.h;
}
return maskBoundingBox.intersected(maskRect(element));
} | O2 | cpp | lunasvg::SVGMaskElement::maskBoundingBox(lunasvg::SVGElement const*) const:
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rsi, %rbx
movq %rdi, %r14
callq 0xecc4
movaps %xmm0, %xmm2
movlhps %xmm1, %xmm2 # xmm2 = xmm2[0],xmm1[0]
movups %xmm2, (%rsp)
cmpb $0x1, 0xe9(%r14)
jne 0xee63
movq (%rbx), %rax
movq %rbx, %rdi
movaps %xmm0, 0x10(%rsp)
movaps %xmm1, 0x20(%rsp)
callq *0x58(%rax)
movaps 0x10(%rsp), %xmm2
mulps %xmm1, %xmm2
addps %xmm0, %xmm2
movaps 0x20(%rsp), %xmm0
mulps %xmm1, %xmm0
movlhps %xmm0, %xmm2 # xmm2 = xmm2[0],xmm0[0]
movups %xmm2, (%rsp)
movq %r14, %rdi
movq %rbx, %rsi
callq 0x11054
movlhps %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0]
leaq 0x38(%rsp), %rsi
movups %xmm0, (%rsi)
movq %rsp, %rdi
callq 0x11f52
addq $0x48, %rsp
popq %rbx
popq %r14
retq
nop
| _ZNK7lunasvg14SVGMaskElement15maskBoundingBoxEPKNS_10SVGElementE:
push r14
push rbx
sub rsp, 48h
mov rbx, rsi
mov r14, rdi
call _ZNK7lunasvg10SVGElement16paintBoundingBoxEv; lunasvg::SVGElement::paintBoundingBox(void)
movaps xmm2, xmm0
movlhps xmm2, xmm1
movups [rsp+58h+var_58], xmm2
cmp byte ptr [r14+0E9h], 1
jnz short loc_EE63
mov rax, [rbx]
mov rdi, rbx
movaps [rsp+58h+var_48], xmm0
movaps [rsp+58h+var_38], xmm1
call qword ptr [rax+58h]
movaps xmm2, [rsp+58h+var_48]
mulps xmm2, xmm1
addps xmm2, xmm0
movaps xmm0, [rsp+58h+var_38]
mulps xmm0, xmm1
movlhps xmm2, xmm0
movups [rsp+58h+var_58], xmm2
loc_EE63:
mov rdi, r14; this
mov rsi, rbx; lunasvg::SVGElement *
call _ZNK7lunasvg14SVGMaskElement8maskRectEPKNS_10SVGElementE; lunasvg::SVGMaskElement::maskRect(lunasvg::SVGElement const*)
movlhps xmm0, xmm1
lea rsi, [rsp+58h+var_20]; lunasvg::Rect *
movups xmmword ptr [rsi], xmm0
mov rdi, rsp; this
call _ZNK7lunasvg4Rect11intersectedERKS0_; lunasvg::Rect::intersected(lunasvg::Rect const&)
add rsp, 48h
pop rbx
pop r14
retn
| long long lunasvg::SVGMaskElement::maskBoundingBox(
lunasvg::SVGMaskElement *this,
const lunasvg::SVGElement *a2,
__m128 a3,
__m128 a4)
{
long long v4; // rax
__m128 v5; // xmm2
__m128 v7; // [rsp+0h] [rbp-58h] BYREF
__m128 v8; // [rsp+10h] [rbp-48h]
__m128 v9; // [rsp+20h] [rbp-38h]
__m128 v10[2]; // [rsp+38h] [rbp-20h] BYREF
*(double *)a3.m128_u64 = lunasvg::SVGElement::paintBoundingBox(this);
v7 = _mm_movelh_ps(a3, a4);
if ( *((_BYTE *)this + 233) == 1 )
{
v4 = *(_QWORD *)a2;
v8 = a3;
v9 = a4;
*(double *)a3.m128_u64 = (*(double ( **)(const lunasvg::SVGElement *))(v4 + 88))(a2);
v5 = _mm_add_ps(_mm_mul_ps(v8, a4), a3);
a3 = _mm_mul_ps(a4, a4);
v7 = _mm_movelh_ps(v5, a3);
}
lunasvg::SVGMaskElement::maskRect(this, a2);
v10[0] = _mm_movelh_ps(a3, a4);
return lunasvg::Rect::intersected((lunasvg::Rect *)&v7, (const lunasvg::Rect *)v10);
}
| maskBoundingBox:
PUSH R14
PUSH RBX
SUB RSP,0x48
MOV RBX,RSI
MOV R14,RDI
CALL 0x0010ecc4
MOVAPS XMM2,XMM0
MOVLHPS XMM2,XMM1
MOVUPS xmmword ptr [RSP],XMM2
CMP byte ptr [R14 + 0xe9],0x1
JNZ 0x0010ee63
MOV RAX,qword ptr [RBX]
MOV RDI,RBX
MOVAPS xmmword ptr [RSP + 0x10],XMM0
MOVAPS xmmword ptr [RSP + 0x20],XMM1
CALL qword ptr [RAX + 0x58]
MOVAPS XMM2,xmmword ptr [RSP + 0x10]
MULPS XMM2,XMM1
ADDPS XMM2,XMM0
MOVAPS XMM0,xmmword ptr [RSP + 0x20]
MULPS XMM0,XMM1
MOVLHPS XMM2,XMM0
MOVUPS xmmword ptr [RSP],XMM2
LAB_0010ee63:
MOV RDI,R14
MOV RSI,RBX
CALL 0x00111054
MOVLHPS XMM0,XMM1
LEA RSI,[RSP + 0x38]
MOVUPS xmmword ptr [RSI],XMM0
MOV RDI,RSP
CALL 0x00111f52
ADD RSP,0x48
POP RBX
POP R14
RET
|
/* lunasvg::SVGMaskElement::maskBoundingBox(lunasvg::SVGElement const*) const */
void lunasvg::SVGMaskElement::maskBoundingBox(SVGElement *param_1)
{
long *in_RSI;
int8 uVar1;
float in_XMM1_Da;
float in_XMM1_Db;
int8 local_58;
float fStack_50;
float fStack_4c;
int8 local_48;
float local_38;
float fStack_34;
int8 local_20 [2];
local_58 = SVGElement::paintBoundingBox(param_1);
fStack_50 = in_XMM1_Da;
fStack_4c = in_XMM1_Db;
if (param_1[0xe9] == (SVGElement)0x1) {
local_38 = in_XMM1_Da;
fStack_34 = in_XMM1_Db;
local_48 = local_58;
uVar1 = (**(code **)(*in_RSI + 0x58))();
local_58 = CONCAT44(local_48._4_4_ * in_XMM1_Db + (float)((ulong)uVar1 >> 0x20),
(float)local_48 * in_XMM1_Da + (float)uVar1);
fStack_50 = local_38 * in_XMM1_Da;
fStack_4c = fStack_34 * in_XMM1_Db;
}
local_20[0] = maskRect(param_1);
Rect::intersected((Rect *)&local_58,(Rect *)local_20);
return;
}
| |
55,559 | nlohmann::json_abi_v3_11_3::detail::invalid_iterator nlohmann::json_abi_v3_11_3::detail::invalid_iterator::create<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const*, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const*) | monkey531[P]llama/common/json.hpp | static invalid_iterator create(int id_, const std::string& what_arg, BasicJsonContext context)
{
const std::string w = concat(exception::name("invalid_iterator", id_), exception::diagnostics(context), what_arg);
return {id_, w.c_str()};
} | O1 | cpp | nlohmann::json_abi_v3_11_3::detail::invalid_iterator nlohmann::json_abi_v3_11_3::detail::invalid_iterator::create<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const*, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdx, %r15
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x38(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x60fb8(%rip), %rsi # 0xefcff
leaq 0x60fc1(%rip), %rdx # 0xefd0f
leaq 0x28(%rsp), %rdi
callq 0x23580
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
movl %ebp, %edx
callq 0x5996c
leaq 0x78(%rsp), %r14
movq %r14, -0x10(%r14)
xorl %eax, %eax
movq %rax, -0x8(%r14)
movb %al, (%r14)
leaq 0x18(%rsp), %r12
movq %r12, -0x10(%r12)
movq %rax, -0x8(%r12)
movb %al, (%r12)
movq 0x8(%r15), %rsi
addq 0x50(%rsp), %rsi
leaq 0x8(%rsp), %rdi
callq 0x1bd80
movq 0x48(%rsp), %rsi
movq 0x50(%rsp), %rdx
leaq 0x8(%rsp), %rdi
callq 0x1b250
movq 0x68(%rsp), %rsi
movq 0x70(%rsp), %rdx
leaq 0x8(%rsp), %rdi
callq 0x1b250
movq (%r15), %rsi
movq 0x8(%r15), %rdx
leaq 0x8(%rsp), %rdi
callq 0x1b250
movq 0x68(%rsp), %rdi
cmpq %r14, %rdi
je 0x8edf1
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x1b8e0
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x8ee0c
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x8ee23
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl %ebp, %esi
callq 0x59bda
leaq 0x9e0b7(%rip), %rax # 0x12cef0
addq $0x10, %rax
movq %rax, (%rbx)
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0x8ee57
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq %rbx, %rax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0x8eee5
movq 0x18(%rsp), %rsi
jmp 0x8eedd
movq %rax, %rbx
jmp 0x8eece
movq %rax, %rbx
jmp 0x8eee5
movq %rdx, %rbx
movq %rax, %r15
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0x8eea7
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1b8e0
leaq 0x68(%rsp), %rdi
leaq 0x48(%rsp), %rdx
leaq 0x88(%rsp), %r12
movq %r14, %rsi
movq %r15, %rcx
movl %ebx, %r8d
movq %r12, %r9
callq 0x1cdbb
movq (%r12), %rbx
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x8eee5
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq %rbx, %rdi
callq 0x1bfb0
nop
| _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 98h
mov r15, rdx
mov ebp, esi
mov rbx, rdi
lea r13, [rsp+0C8h+var_90]
mov [r13-10h], r13
lea rsi, aInvalidIterato; "invalid_iterator"
lea rdx, aInvalidIterato+10h; ""
lea rdi, [rsp+0C8h+var_A0]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
lea rdi, [rsp+0C8h+var_80]; int
lea rsi, [rsp+0C8h+var_A0]; int
mov edx, ebp; int
call _ZN8nlohmann16json_abi_v3_11_36detail9exception4nameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi; nlohmann::json_abi_v3_11_3::detail::exception::name(std::string const&,int)
lea r14, [rsp+0C8h+var_50]
mov [r14-10h], r14
xor eax, eax
mov [r14-8], rax
mov [r14], al
lea r12, [rsp+0C8h+var_B0]
mov [r12-10h], r12
mov [r12-8], rax
mov [r12], al
mov rsi, [r15+8]
add rsi, [rsp+0C8h+var_78]
lea rdi, [rsp+0C8h+var_C0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong)
mov rsi, qword ptr [rsp+0C8h+var_80]
mov rdx, [rsp+0C8h+var_78]
lea rdi, [rsp+0C8h+var_C0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
mov rsi, [rsp+0C8h+var_60]
mov rdx, [rsp+0C8h+var_58]
lea rdi, [rsp+0C8h+var_C0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
mov rsi, [r15]
mov rdx, [r15+8]
lea rdi, [rsp+0C8h+var_C0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
mov rdi, [rsp+0C8h+var_60]; void *
cmp rdi, r14
jz short loc_8EDF1
mov rsi, [rsp+0C8h+var_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EDF1:
lea rax, [rsp+0C8h+var_70]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_8EE0C
mov rsi, [rsp+0C8h+var_70]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EE0C:
mov rdi, [rsp+0C8h+var_A0]; void *
cmp rdi, r13
jz short loc_8EE23
mov rsi, [rsp+0C8h+var_90]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EE23:
mov rdx, [rsp+0C8h+var_C0]; char *
mov rdi, rbx; this
mov esi, ebp; int
call _ZN8nlohmann16json_abi_v3_11_36detail9exceptionC2EiPKc; nlohmann::json_abi_v3_11_3::detail::exception::exception(int,char const*)
lea rax, _ZTVN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorE; `vtable for'nlohmann::json_abi_v3_11_3::detail::invalid_iterator
add rax, 10h
mov [rbx], rax
mov rdi, [rsp+0C8h+var_C0]; void *
cmp rdi, r12
jz short loc_8EE57
mov rsi, [rsp+0C8h+var_B0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EE57:
mov rax, rbx
add rsp, 98h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
mov rdi, [rsp+arg_0]
cmp rdi, r12
jz short loc_8EEE5
mov rsi, [rsp+arg_10]
jmp short loc_8EEDD
mov rbx, rax
jmp short loc_8EECE
mov rbx, rax
jmp short loc_8EEE5
mov rbx, rdx
mov r15, rax
mov rdi, [rsp+arg_0]; void *
cmp rdi, r12
jz short loc_8EEA7
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EEA7:
lea rdi, [rsp+arg_60]
lea rdx, [rsp+arg_40]
lea r12, [rsp+arg_80]
mov rsi, r14
mov rcx, r15
mov r8d, ebx
mov r9, r12
call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK__cold_1
mov rbx, [r12]
loc_8EECE:
mov rdi, [rsp+arg_20]; void *
cmp rdi, r13
jz short loc_8EEE5
mov rsi, [rsp+arg_30]
loc_8EEDD:
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EEE5:
mov rdi, rbx
call __Unwind_Resume
| nlohmann::json_abi_v3_11_3::detail::exception * ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_(
nlohmann::json_abi_v3_11_3::detail::exception *this,
int a2,
_QWORD *a3)
{
char *v5[2]; // [rsp+8h] [rbp-C0h] BYREF
_QWORD v6[2]; // [rsp+18h] [rbp-B0h] BYREF
void *v7[2]; // [rsp+28h] [rbp-A0h] BYREF
_QWORD v8[2]; // [rsp+38h] [rbp-90h] BYREF
int v9[2]; // [rsp+48h] [rbp-80h] BYREF
long long v10; // [rsp+50h] [rbp-78h]
long long v11; // [rsp+58h] [rbp-70h] BYREF
void *v12; // [rsp+68h] [rbp-60h]
long long v13; // [rsp+70h] [rbp-58h]
_QWORD v14[10]; // [rsp+78h] [rbp-50h] BYREF
v7[0] = v8;
std::string::_M_construct<char const*>(v7, "invalid_iterator", (long long)"");
nlohmann::json_abi_v3_11_3::detail::exception::name((long long)v9, (long long)v7, a2);
v12 = v14;
v13 = 0LL;
LOBYTE(v14[0]) = 0;
v5[0] = (char *)v6;
v5[1] = 0LL;
LOBYTE(v6[0]) = 0;
std::string::reserve(v5, v10 + a3[1]);
std::string::_M_append(v5, *(_QWORD *)v9, v10);
std::string::_M_append(v5, v12, v13);
std::string::_M_append(v5, *a3, a3[1]);
if ( v12 != v14 )
operator delete(v12, v14[0] + 1LL);
if ( *(long long **)v9 != &v11 )
operator delete(*(void **)v9, v11 + 1);
if ( v7[0] != v8 )
operator delete(v7[0], v8[0] + 1LL);
nlohmann::json_abi_v3_11_3::detail::exception::exception(this, a2, v5[0]);
*(_QWORD *)this = &`vtable for'nlohmann::json_abi_v3_11_3::detail::invalid_iterator + 2;
if ( (_QWORD *)v5[0] != v6 )
operator delete(v5[0], v6[0] + 1LL);
return this;
}
| _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x98
MOV R15,RDX
MOV EBP,ESI
MOV RBX,RDI
LEA R13,[RSP + 0x38]
MOV qword ptr [R13 + -0x10],R13
LAB_0018ed40:
LEA RSI,[0x1efcff]
LEA RDX,[0x1efd0f]
LEA RDI,[RSP + 0x28]
CALL 0x00123580
LAB_0018ed58:
LEA RDI,[RSP + 0x48]
LEA RSI,[RSP + 0x28]
MOV EDX,EBP
CALL 0x0015996c
LEA R14,[RSP + 0x78]
MOV qword ptr [R14 + -0x10],R14
XOR EAX,EAX
MOV qword ptr [R14 + -0x8],RAX
MOV byte ptr [R14],AL
LEA R12,[RSP + 0x18]
MOV qword ptr [R12 + -0x10],R12
MOV qword ptr [R12 + -0x8],RAX
MOV byte ptr [R12],AL
MOV RSI,qword ptr [R15 + 0x8]
ADD RSI,qword ptr [RSP + 0x50]
LAB_0018ed97:
LEA RDI,[RSP + 0x8]
CALL 0x0011bd80
MOV RSI,qword ptr [RSP + 0x48]
MOV RDX,qword ptr [RSP + 0x50]
LEA RDI,[RSP + 0x8]
CALL 0x0011b250
MOV RSI,qword ptr [RSP + 0x68]
MOV RDX,qword ptr [RSP + 0x70]
LEA RDI,[RSP + 0x8]
CALL 0x0011b250
MOV RSI,qword ptr [R15]
MOV RDX,qword ptr [R15 + 0x8]
LEA RDI,[RSP + 0x8]
CALL 0x0011b250
MOV RDI,qword ptr [RSP + 0x68]
CMP RDI,R14
JZ 0x0018edf1
MOV RSI,qword ptr [RSP + 0x78]
INC RSI
CALL 0x0011b8e0
LAB_0018edf1:
LEA RAX,[RSP + 0x58]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0018ee0c
MOV RSI,qword ptr [RSP + 0x58]
INC RSI
CALL 0x0011b8e0
LAB_0018ee0c:
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R13
JZ 0x0018ee23
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x0011b8e0
LAB_0018ee23:
MOV RDX,qword ptr [RSP + 0x8]
LAB_0018ee28:
MOV RDI,RBX
MOV ESI,EBP
CALL 0x00159bda
LAB_0018ee32:
LEA RAX,[0x22cef0]
ADD RAX,0x10
MOV qword ptr [RBX],RAX
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,R12
JZ 0x0018ee57
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011b8e0
LAB_0018ee57:
MOV RAX,RBX
ADD RSP,0x98
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
exception *
_ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
(exception *param_1,int param_2,ulong *param_3)
{
char *local_c0;
int8 local_b8;
char local_b0;
int7 uStack_af;
long *local_a0 [2];
long local_90 [2];
long *local_80 [2];
long local_70 [2];
int1 *local_60;
int8 local_58;
int1 local_50;
int7 uStack_4f;
/* try { // try from 0018ed40 to 0018ed57 has its CatchHandler @ 0018ee85 */
local_a0[0] = local_90;
std::__cxx11::string::_M_construct<char_const*>(local_a0,"invalid_iterator","");
/* try { // try from 0018ed58 to 0018ed68 has its CatchHandler @ 0018ee80 */
nlohmann::json_abi_v3_11_3::detail::exception::name
((exception *)local_80,(string *)local_a0,param_2);
local_58 = 0;
local_50 = 0;
local_b8 = 0;
local_b0 = '\0';
/* try { // try from 0018ed97 to 0018edd9 has its CatchHandler @ 0018ee8a */
local_c0 = &local_b0;
local_60 = &local_50;
std::__cxx11::string::reserve((ulong)&local_c0);
std::__cxx11::string::_M_append((char *)&local_c0,(ulong)local_80[0]);
std::__cxx11::string::_M_append((char *)&local_c0,(ulong)local_60);
std::__cxx11::string::_M_append((char *)&local_c0,*param_3);
if (local_60 != &local_50) {
operator_delete(local_60,CONCAT71(uStack_4f,local_50) + 1);
}
if (local_80[0] != local_70) {
operator_delete(local_80[0],local_70[0] + 1);
}
if (local_a0[0] != local_90) {
operator_delete(local_a0[0],local_90[0] + 1);
}
/* try { // try from 0018ee28 to 0018ee31 has its CatchHandler @ 0018ee6c */
nlohmann::json_abi_v3_11_3::detail::exception::exception(param_1,param_2,local_c0);
*(int ***)param_1 = &PTR__exception_0022cf00;
if (local_c0 != &local_b0) {
operator_delete(local_c0,CONCAT71(uStack_af,local_b0) + 1);
}
return param_1;
}
| |
55,560 | nlohmann::json_abi_v3_11_3::detail::invalid_iterator nlohmann::json_abi_v3_11_3::detail::invalid_iterator::create<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const*, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const*) | monkey531[P]llama/common/json.hpp | static invalid_iterator create(int id_, const std::string& what_arg, BasicJsonContext context)
{
const std::string w = concat(exception::name("invalid_iterator", id_), exception::diagnostics(context), what_arg);
return {id_, w.c_str()};
} | O2 | cpp | nlohmann::json_abi_v3_11_3::detail::invalid_iterator nlohmann::json_abi_v3_11_3::detail::invalid_iterator::create<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const*, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const*):
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x88, %rsp
movq %rcx, %r15
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x48314(%rip), %rsi # 0xb0cb1
leaq 0x28(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0x27c44
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
movl %ebp, %edx
callq 0x3e6f2
leaq 0x8(%rsp), %rdi
movq %r15, %rsi
callq 0x42a6c
leaq 0x68(%rsp), %rdi
leaq 0x48(%rsp), %rsi
leaq 0x8(%rsp), %rdx
movq %r14, %rcx
callq 0x3e689
leaq 0x8(%rsp), %rdi
callq 0x241f8
leaq 0x48(%rsp), %rdi
callq 0x241f8
leaq 0x28(%rsp), %rdi
callq 0x241f8
movq 0x68(%rsp), %rdx
movq %rbx, %rdi
movl %ebp, %esi
callq 0x43bfc
leaq 0x68(%rsp), %rdi
callq 0x241f8
movq %rbx, %rax
addq $0x88, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x68(%rsp), %rdi
jmp 0x68a59
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x241f8
jmp 0x68a45
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0x241f8
jmp 0x68a54
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x241f8
jmp 0x68a63
movq %rax, %rbx
movq %rbx, %rdi
callq 0x23fb0
nop
| _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_:
push rbp
push r15
push r14
push rbx
sub rsp, 88h
mov r15, rcx
mov r14, rdx
mov ebp, esi
mov rbx, rdi
lea rsi, aInvalidIterato; "invalid_iterator"
lea rdi, [rsp+0A8h+var_80]
lea rdx, [rsp+0A8h+var_A1]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rdi, [rsp+0A8h+var_60]
lea rsi, [rsp+0A8h+var_80]
mov edx, ebp
call _ZN8nlohmann16json_abi_v3_11_36detail9exception4nameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi; nlohmann::json_abi_v3_11_3::detail::exception::name(std::string const&,int)
lea rdi, [rsp+0A8h+var_A0]
mov rsi, r15
call _ZN8nlohmann16json_abi_v3_11_36detail9exception11diagnosticsINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEESC_PKT_; nlohmann::json_abi_v3_11_3::detail::exception::diagnostics<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const*)
lea rdi, [rsp+0A8h+var_40]
lea rsi, [rsp+0A8h+var_60]
lea rdx, [rsp+0A8h+var_A0]
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJS8_S8_RKS8_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,std::string,std::string const&>(std::string,std::string,std::string const&)
lea rdi, [rsp+0A8h+var_A0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+0A8h+var_60]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+0A8h+var_80]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdx, [rsp+0A8h+var_40]; char *
mov rdi, rbx; this
mov esi, ebp; int
call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorC2EiPKc; nlohmann::json_abi_v3_11_3::detail::invalid_iterator::invalid_iterator(int,char const*)
lea rdi, [rsp+0A8h+var_40]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rax, rbx
add rsp, 88h
pop rbx
pop r14
pop r15
pop rbp
retn
mov rbx, rax
lea rdi, [rsp+arg_60]
jmp short loc_68A59
mov rbx, rax
lea rdi, [rsp+arg_0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_68A45
mov rbx, rax
loc_68A45:
lea rdi, [rsp+arg_40]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_68A54
mov rbx, rax
loc_68A54:
lea rdi, [rsp+arg_20]; void *
loc_68A59:
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_68A63
mov rbx, rax
loc_68A63:
mov rdi, rbx
call __Unwind_Resume
| nlohmann::json_abi_v3_11_3::detail::invalid_iterator * ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_(
nlohmann::json_abi_v3_11_3::detail::invalid_iterator *this,
int a2,
long long a3)
{
_QWORD v5[4]; // [rsp+8h] [rbp-A0h] BYREF
_QWORD v6[4]; // [rsp+28h] [rbp-80h] BYREF
_BYTE v7[32]; // [rsp+48h] [rbp-60h] BYREF
char *v8[8]; // [rsp+68h] [rbp-40h] BYREF
std::string::basic_string<std::allocator<char>>(v6, (long long)"invalid_iterator");
nlohmann::json_abi_v3_11_3::detail::exception::name((long long)v7, (long long)v6, a2);
nlohmann::json_abi_v3_11_3::detail::exception::diagnostics<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>>(v5);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,std::string,std::string const&>(
(long long)v8,
(long long)v7,
(long long)v5,
a3);
std::string::~string(v5);
std::string::~string(v7);
std::string::~string(v6);
nlohmann::json_abi_v3_11_3::detail::invalid_iterator::invalid_iterator(this, a2, v8[0]);
std::string::~string(v8);
return this;
}
| _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_:
PUSH RBP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x88
MOV R15,RCX
MOV R14,RDX
MOV EBP,ESI
MOV RBX,RDI
LAB_00168996:
LEA RSI,[0x1b0cb1]
LEA RDI,[RSP + 0x28]
LEA RDX,[RSP + 0x7]
CALL 0x00127c44
LAB_001689ac:
LEA RDI,[RSP + 0x48]
LEA RSI,[RSP + 0x28]
MOV EDX,EBP
CALL 0x0013e6f2
LAB_001689bd:
LEA RDI,[RSP + 0x8]
MOV RSI,R15
CALL 0x00142a6c
LAB_001689ca:
LEA RDI,[RSP + 0x68]
LEA RSI,[RSP + 0x48]
LEA RDX,[RSP + 0x8]
MOV RCX,R14
CALL 0x0013e689
LEA RDI,[RSP + 0x8]
CALL 0x001241f8
LEA RDI,[RSP + 0x48]
CALL 0x001241f8
LEA RDI,[RSP + 0x28]
CALL 0x001241f8
MOV RDX,qword ptr [RSP + 0x68]
LAB_00168a04:
MOV RDI,RBX
MOV ESI,EBP
CALL 0x00143bfc
LAB_00168a0e:
LEA RDI,[RSP + 0x68]
CALL 0x001241f8
MOV RAX,RBX
ADD RSP,0x88
POP RBX
POP R14
POP R15
POP RBP
RET
|
invalid_iterator *
_ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
(invalid_iterator *param_1,int param_2,string *param_3)
{
allocator local_a1;
string local_a0 [32];
string local_80 [32];
exception local_60 [32];
char *local_40 [4];
/* try { // try from 00168996 to 001689ab has its CatchHandler @ 00168a60 */
std::__cxx11::string::string<std::allocator<char>>(local_80,"invalid_iterator",&local_a1);
/* try { // try from 001689ac to 001689bc has its CatchHandler @ 00168a51 */
nlohmann::json_abi_v3_11_3::detail::exception::name(local_60,local_80,param_2);
/* try { // try from 001689bd to 001689c9 has its CatchHandler @ 00168a42 */
nlohmann::json_abi_v3_11_3::detail::exception::
diagnostics<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
(local_a0);
/* try { // try from 001689ca to 001689e0 has its CatchHandler @ 00168a33 */
nlohmann::json_abi_v3_11_3::detail::
concat<std::__cxx11::string,std::__cxx11::string,std::__cxx11::string,std::__cxx11::string_const&>
((detail *)local_40,(string *)local_60,local_a0,param_3);
std::__cxx11::string::~string(local_a0);
std::__cxx11::string::~string((string *)local_60);
std::__cxx11::string::~string(local_80);
/* try { // try from 00168a04 to 00168a0d has its CatchHandler @ 00168a29 */
nlohmann::json_abi_v3_11_3::detail::invalid_iterator::invalid_iterator
(param_1,param_2,local_40[0]);
std::__cxx11::string::~string((string *)local_40);
return param_1;
}
| |
55,561 | nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>::reset() | monkey531[P]llama/common/json.hpp | void reset() noexcept
{
token_buffer.clear();
token_string.clear();
token_string.push_back(char_traits<char_type>::to_char_type(current));
} | O2 | cpp | nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>::reset():
pushq %rax
movq %rdi, %rax
andq $0x0, 0x58(%rdi)
movq 0x50(%rdi), %rcx
movb $0x0, (%rcx)
addq $0x38, %rdi
movq 0x38(%rax), %rcx
cmpq %rcx, 0x40(%rax)
je 0x3ef88
movq %rcx, 0x40(%rax)
movb 0x14(%rax), %al
leaq 0x7(%rsp), %rsi
movb %al, (%rsi)
callq 0x3edfe
popq %rax
retq
movq %rax, %rdi
callq 0x27af1
nop
| _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE5resetEv:
push rax
mov rax, rdi
and qword ptr [rdi+58h], 0
mov rcx, [rdi+50h]
mov byte ptr [rcx], 0
add rdi, 38h ; '8'
mov rcx, [rax+38h]
cmp [rax+40h], rcx
jz short loc_3EF88
mov [rax+40h], rcx
loc_3EF88:
mov al, [rax+14h]
lea rsi, [rsp+8+var_1]
mov [rsi], al
call _ZNSt6vectorIcSaIcEE12emplace_backIJcEEERcDpOT_; std::vector<char>::emplace_back<char>(char &&)
pop rax
retn
mov rdi, rax
call __clang_call_terminate
| void __spoils<rdx,rcx,r8,r9,r10,r11,xmm4,xmm5> nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::reset(
long long a1)
{
long long v2; // rdi
long long v3; // rcx
char v4; // [rsp+1h] [rbp-1h] BYREF
*(_QWORD *)(a1 + 88) = 0LL;
**(_BYTE **)(a1 + 80) = 0;
v2 = a1 + 56;
v3 = *(_QWORD *)(a1 + 56);
if ( *(_QWORD *)(a1 + 64) != v3 )
*(_QWORD *)(a1 + 64) = v3;
v4 = *(_BYTE *)(a1 + 20);
std::vector<char>::emplace_back<char>(v2, &v4);
}
| reset:
PUSH RAX
MOV RAX,RDI
AND qword ptr [RDI + 0x58],0x0
MOV RCX,qword ptr [RDI + 0x50]
MOV byte ptr [RCX],0x0
ADD RDI,0x38
MOV RCX,qword ptr [RAX + 0x38]
CMP qword ptr [RAX + 0x40],RCX
JZ 0x0013ef88
MOV qword ptr [RAX + 0x40],RCX
LAB_0013ef88:
MOV AL,byte ptr [RAX + 0x14]
LEA RSI,[RSP + 0x7]
MOV byte ptr [RSI],AL
LAB_0013ef92:
CALL 0x0013edfe
POP RAX
RET
|
/* nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>,
nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char
const*, std::__cxx11::string > > >::reset() */
int8 __thiscall
nlohmann::json_abi_v3_11_3::detail::
lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
::reset(lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
*this)
{
int8 in_RAX;
int8 uStack_8;
*(int8 *)(this + 0x58) = 0;
**(int1 **)(this + 0x50) = 0;
if (*(long *)(this + 0x40) != *(long *)(this + 0x38)) {
*(long *)(this + 0x40) = *(long *)(this + 0x38);
}
uStack_8 = CONCAT17(this[0x14],(int7)in_RAX);
/* try { // try from 0013ef92 to 0013ef96 has its CatchHandler @ 0013ef99 */
std::vector<char,std::allocator<char>>::emplace_back<char>
((vector<char,std::allocator<char>> *)(this + 0x38),(char *)((long)&uStack_8 + 7));
return uStack_8;
}
| |
55,562 | MemoryManager::getByte(unsigned int, unsigned int*) | DanielDanyang[P]CSC3050-2025-Spring-Project-4/src/MemoryManager.cpp | uint8_t MemoryManager::getByte(uint32_t addr, uint32_t *cycles) {
if (!this->isAddrExist(addr)) {
dbgprintf("Byte read to invalid addr 0x%x!\n", addr);
return false;
}
if (this->cache != nullptr) {
return this->cache->getByte(addr, cycles);
}
uint32_t i = this->getFirstEntryId(addr);
uint32_t j = this->getSecondEntryId(addr);
uint32_t k = this->getPageOffset(addr);
return this->memory[i][j][k];
} | O0 | cpp | MemoryManager::getByte(unsigned int, unsigned int*):
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movq %rdx, 0x18(%rsp)
movq 0x28(%rsp), %rdi
movq %rdi, (%rsp)
movl 0x24(%rsp), %esi
callq 0x3440
testb $0x1, %al
jne 0x3774
movl 0x24(%rsp), %esi
leaq 0x4a1a(%rip), %rdi # 0x817d
movb $0x0, %al
callq 0x4180
movb $0x0, 0x37(%rsp)
jmp 0x37f5
movq (%rsp), %rax
cmpq $0x0, 0x2000(%rax)
je 0x37a1
movq (%rsp), %rax
movq 0x2000(%rax), %rdi
movl 0x24(%rsp), %esi
movq 0x18(%rsp), %rdx
callq 0x4870
movb %al, 0x37(%rsp)
jmp 0x37f5
movq (%rsp), %rdi
movl 0x24(%rsp), %esi
callq 0x33d0
movq (%rsp), %rdi
movl %eax, 0x14(%rsp)
movl 0x24(%rsp), %esi
callq 0x33f0
movq (%rsp), %rdi
movl %eax, 0x10(%rsp)
movl 0x24(%rsp), %esi
callq 0x3660
movl %eax, %ecx
movq (%rsp), %rax
movl %ecx, 0xc(%rsp)
movl 0x14(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movl 0x10(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movl 0xc(%rsp), %ecx
movb (%rax,%rcx), %al
movb %al, 0x37(%rsp)
movb 0x37(%rsp), %al
addq $0x38, %rsp
retq
nop
| _ZN13MemoryManager7getByteEjPj:
sub rsp, 38h
mov [rsp+38h+var_10], rdi
mov [rsp+38h+var_14], esi
mov [rsp+38h+var_20], rdx
mov rdi, [rsp+38h+var_10]; this
mov [rsp+38h+var_38], rdi
mov esi, [rsp+38h+var_14]; unsigned int
call _ZN13MemoryManager11isAddrExistEj; MemoryManager::isAddrExist(uint)
test al, 1
jnz short loc_3774
mov esi, [rsp+38h+var_14]
lea rdi, aByteReadToInva; "Byte read to invalid addr 0x%x!\n"
mov al, 0
call _Z9dbgprintfPKcz; dbgprintf(char const*,...)
mov [rsp+38h+var_1], 0
jmp loc_37F5
loc_3774:
mov rax, [rsp+38h+var_38]
cmp qword ptr [rax+2000h], 0
jz short loc_37A1
mov rax, [rsp+38h+var_38]
mov rdi, [rax+2000h]; this
mov esi, [rsp+38h+var_14]; unsigned int
mov rdx, [rsp+38h+var_20]; unsigned int *
call _ZN5Cache7getByteEjPj; Cache::getByte(uint,uint *)
mov [rsp+38h+var_1], al
jmp short loc_37F5
loc_37A1:
mov rdi, [rsp+38h+var_38]; this
mov esi, [rsp+38h+var_14]; unsigned int
call _ZN13MemoryManager15getFirstEntryIdEj; MemoryManager::getFirstEntryId(uint)
mov rdi, [rsp+38h+var_38]; this
mov [rsp+38h+var_24], eax
mov esi, [rsp+38h+var_14]; unsigned int
call _ZN13MemoryManager16getSecondEntryIdEj; MemoryManager::getSecondEntryId(uint)
mov rdi, [rsp+38h+var_38]; this
mov [rsp+38h+var_28], eax
mov esi, [rsp+38h+var_14]; unsigned int
call _ZN13MemoryManager13getPageOffsetEj; MemoryManager::getPageOffset(uint)
mov ecx, eax
mov rax, [rsp+38h+var_38]
mov [rsp+38h+var_2C], ecx
mov ecx, [rsp+38h+var_24]
mov rax, [rax+rcx*8]
mov ecx, [rsp+38h+var_28]
mov rax, [rax+rcx*8]
mov ecx, [rsp+38h+var_2C]
mov al, [rax+rcx]
mov [rsp+38h+var_1], al
loc_37F5:
mov al, [rsp+38h+var_1]
add rsp, 38h
retn
| char MemoryManager::getByte(Cache **this, unsigned int a2, unsigned int *a3)
{
unsigned int SecondEntryId; // [rsp+10h] [rbp-28h]
int FirstEntryId; // [rsp+14h] [rbp-24h]
if ( MemoryManager::isAddrExist((MemoryManager *)this, a2) )
{
if ( this[1024] )
{
return Cache::getByte(this[1024], a2, a3);
}
else
{
FirstEntryId = MemoryManager::getFirstEntryId((MemoryManager *)this, a2);
SecondEntryId = MemoryManager::getSecondEntryId((MemoryManager *)this, a2);
return *(_BYTE *)(*((_QWORD *)this[FirstEntryId] + SecondEntryId)
+ (unsigned int)MemoryManager::getPageOffset((MemoryManager *)this, a2));
}
}
else
{
dbgprintf("Byte read to invalid addr 0x%x!\n", a2);
return 0;
}
}
| getByte:
SUB RSP,0x38
MOV qword ptr [RSP + 0x28],RDI
MOV dword ptr [RSP + 0x24],ESI
MOV qword ptr [RSP + 0x18],RDX
MOV RDI,qword ptr [RSP + 0x28]
MOV qword ptr [RSP],RDI
MOV ESI,dword ptr [RSP + 0x24]
CALL 0x00103440
TEST AL,0x1
JNZ 0x00103774
MOV ESI,dword ptr [RSP + 0x24]
LEA RDI,[0x10817d]
MOV AL,0x0
CALL 0x00104180
MOV byte ptr [RSP + 0x37],0x0
JMP 0x001037f5
LAB_00103774:
MOV RAX,qword ptr [RSP]
CMP qword ptr [RAX + 0x2000],0x0
JZ 0x001037a1
MOV RAX,qword ptr [RSP]
MOV RDI,qword ptr [RAX + 0x2000]
MOV ESI,dword ptr [RSP + 0x24]
MOV RDX,qword ptr [RSP + 0x18]
CALL 0x00104870
MOV byte ptr [RSP + 0x37],AL
JMP 0x001037f5
LAB_001037a1:
MOV RDI,qword ptr [RSP]
MOV ESI,dword ptr [RSP + 0x24]
CALL 0x001033d0
MOV RDI,qword ptr [RSP]
MOV dword ptr [RSP + 0x14],EAX
MOV ESI,dword ptr [RSP + 0x24]
CALL 0x001033f0
MOV RDI,qword ptr [RSP]
MOV dword ptr [RSP + 0x10],EAX
MOV ESI,dword ptr [RSP + 0x24]
CALL 0x00103660
MOV ECX,EAX
MOV RAX,qword ptr [RSP]
MOV dword ptr [RSP + 0xc],ECX
MOV ECX,dword ptr [RSP + 0x14]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV ECX,dword ptr [RSP + 0x10]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV ECX,dword ptr [RSP + 0xc]
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RSP + 0x37],AL
LAB_001037f5:
MOV AL,byte ptr [RSP + 0x37]
ADD RSP,0x38
RET
|
/* MemoryManager::getByte(unsigned int, unsigned int*) */
int8 __thiscall MemoryManager::getByte(MemoryManager *this,uint param_1,uint *param_2)
{
long lVar1;
int1 extraout_AL;
uint uVar2;
uint uVar3;
uint uVar4;
ulong uVar5;
int7 extraout_var;
int7 extraout_var_00;
int7 uVar6;
int1 local_1;
uVar5 = isAddrExist(this,param_1);
if ((uVar5 & 1) == 0) {
dbgprintf("Byte read to invalid addr 0x%x!\n",(ulong)param_1);
local_1 = 0;
uVar6 = extraout_var;
}
else if (*(long *)(this + 0x2000) == 0) {
uVar2 = getFirstEntryId(this,param_1);
uVar3 = getSecondEntryId(this,param_1);
uVar4 = getPageOffset(this,param_1);
lVar1 = *(long *)(*(long *)(this + (ulong)uVar2 * 8) + (ulong)uVar3 * 8);
local_1 = *(int1 *)(lVar1 + (ulong)uVar4);
uVar6 = (int7)((ulong)lVar1 >> 8);
}
else {
Cache::getByte(*(Cache **)(this + 0x2000),param_1,param_2);
uVar6 = extraout_var_00;
local_1 = extraout_AL;
}
return CONCAT71(uVar6,local_1);
}
| |
55,563 | MemoryManager::getByte(unsigned int, unsigned int*) | DanielDanyang[P]CSC3050-2025-Spring-Project-4/src/MemoryManager.cpp | uint8_t MemoryManager::getByte(uint32_t addr, uint32_t *cycles) {
if (!this->isAddrExist(addr)) {
dbgprintf("Byte read to invalid addr 0x%x!\n", addr);
return false;
}
if (this->cache != nullptr) {
return this->cache->getByte(addr, cycles);
}
uint32_t i = this->getFirstEntryId(addr);
uint32_t j = this->getSecondEntryId(addr);
uint32_t k = this->getPageOffset(addr);
return this->memory[i][j][k];
} | O1 | cpp | MemoryManager::getByte(unsigned int, unsigned int*):
pushq %rbx
movl %esi, %eax
shrl $0x16, %eax
movq (%rdi,%rax,8), %rax
testq %rax, %rax
je 0x3038
movl %esi, %ecx
shrl $0x9, %ecx
andl $0x1ff8, %ecx # imm = 0x1FF8
cmpq $0x0, (%rax,%rcx)
je 0x3038
movq 0x2000(%rdi), %rdi
testq %rdi, %rdi
je 0x3029
popq %rbx
jmp 0x3a58
andl $0xfff, %esi # imm = 0xFFF
movq (%rax,%rcx), %rax
movb (%rax,%rsi), %bl
jmp 0x3048
leaq 0x2178(%rip), %rdi # 0x51b7
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x2330
movl %ebx, %eax
popq %rbx
retq
| _ZN13MemoryManager7getByteEjPj:
push rbx
mov eax, esi
shr eax, 16h
mov rax, [rdi+rax*8]
test rax, rax
jz short loc_3038
mov ecx, esi
shr ecx, 9
and ecx, 1FF8h
cmp qword ptr [rax+rcx], 0
jz short loc_3038
mov rdi, [rdi+2000h]; this
test rdi, rdi
jz short loc_3029
pop rbx
jmp _ZN5Cache7getByteEjPj; Cache::getByte(uint,uint *)
loc_3029:
and esi, 0FFFh
mov rax, [rax+rcx]
mov bl, [rax+rsi]
jmp short loc_3048
loc_3038:
lea rdi, aByteReadToInva; "Byte read to invalid addr 0x%x!\n"
xor ebx, ebx
xor eax, eax
call _Z9dbgprintfPKcz; dbgprintf(char const*,...)
loc_3048:
mov eax, ebx
pop rbx
retn
| long long MemoryManager::getByte(
MemoryManager *this,
long long a2,
unsigned int *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)
{
unsigned int v14; // ebx
long long v15; // rax
Cache *v16; // rdi
char v18; // [rsp+0h] [rbp-8h]
v15 = *((_QWORD *)this + ((unsigned int)a2 >> 22));
if ( v15 && (a4 = ((unsigned int)a2 >> 9) & 0x1FF8, *(_QWORD *)(v15 + a4)) )
{
v16 = (Cache *)*((_QWORD *)this + 1024);
if ( v16 )
return Cache::getByte(v16, a2, a3);
LOBYTE(v14) = *(_BYTE *)(*(_QWORD *)(v15 + a4) + (a2 & 0xFFF));
}
else
{
v14 = 0;
dbgprintf(
"Byte read to invalid addr 0x%x!\n",
a2,
(long long)a3,
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
a12,
a13,
a14,
v18);
}
return v14;
}
| getByte:
PUSH RBX
MOV EAX,ESI
SHR EAX,0x16
MOV RAX,qword ptr [RDI + RAX*0x8]
TEST RAX,RAX
JZ 0x00103038
MOV ECX,ESI
SHR ECX,0x9
AND ECX,0x1ff8
CMP qword ptr [RAX + RCX*0x1],0x0
JZ 0x00103038
MOV RDI,qword ptr [RDI + 0x2000]
TEST RDI,RDI
JZ 0x00103029
POP RBX
JMP 0x00103a58
LAB_00103029:
AND ESI,0xfff
MOV RAX,qword ptr [RAX + RCX*0x1]
MOV BL,byte ptr [RAX + RSI*0x1]
JMP 0x00103048
LAB_00103038:
LEA RDI,[0x1051b7]
XOR EBX,EBX
XOR EAX,EAX
CALL 0x00102330
LAB_00103048:
MOV EAX,EBX
POP RBX
RET
|
/* MemoryManager::getByte(unsigned int, unsigned int*) */
ulong __thiscall MemoryManager::getByte(MemoryManager *this,uint param_1,uint *param_2)
{
long lVar1;
ulong uVar2;
int8 unaff_RBX;
lVar1 = *(long *)(this + (ulong)(param_1 >> 0x16) * 8);
if ((lVar1 == 0) || (uVar2 = (ulong)(param_1 >> 9 & 0x1ff8), *(long *)(lVar1 + uVar2) == 0)) {
uVar2 = 0;
dbgprintf("Byte read to invalid addr 0x%x!\n");
}
else {
if (*(Cache **)(this + 0x2000) != (Cache *)0x0) {
uVar2 = Cache::getByte(*(Cache **)(this + 0x2000),param_1,param_2);
return uVar2;
}
uVar2 = CONCAT71((int7)((ulong)unaff_RBX >> 8),
*(int1 *)(*(long *)(lVar1 + uVar2) + (ulong)(param_1 & 0xfff)));
}
return uVar2 & 0xffffffff;
}
| |
55,564 | MemoryManager::getByte(unsigned int, unsigned int*) | DanielDanyang[P]CSC3050-2025-Spring-Project-4/src/MemoryManager.cpp | uint8_t MemoryManager::getByte(uint32_t addr, uint32_t *cycles) {
if (!this->isAddrExist(addr)) {
dbgprintf("Byte read to invalid addr 0x%x!\n", addr);
return false;
}
if (this->cache != nullptr) {
return this->cache->getByte(addr, cycles);
}
uint32_t i = this->getFirstEntryId(addr);
uint32_t j = this->getSecondEntryId(addr);
uint32_t k = this->getPageOffset(addr);
return this->memory[i][j][k];
} | O3 | cpp | MemoryManager::getByte(unsigned int, unsigned int*):
pushq %rbx
movl %esi, %eax
shrl $0x16, %eax
movq (%rdi,%rax,8), %rax
testq %rax, %rax
je 0x3020
movl %esi, %ecx
shrl $0x9, %ecx
andl $0x1ff8, %ecx # imm = 0x1FF8
movq (%rax,%rcx), %rax
testq %rax, %rax
je 0x3020
movq 0x2000(%rdi), %rdi
testq %rdi, %rdi
je 0x3015
popq %rbx
jmp 0x39d6
andl $0xfff, %esi # imm = 0xFFF
movb (%rax,%rsi), %bl
jmp 0x3030
leaq 0x2190(%rip), %rdi # 0x51b7
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x2330
movl %ebx, %eax
popq %rbx
retq
| _ZN13MemoryManager7getByteEjPj:
push rbx
mov eax, esi
shr eax, 16h
mov rax, [rdi+rax*8]
test rax, rax
jz short loc_3020
mov ecx, esi
shr ecx, 9
and ecx, 1FF8h
mov rax, [rax+rcx]
test rax, rax
jz short loc_3020
mov rdi, [rdi+2000h]; this
test rdi, rdi
jz short loc_3015
pop rbx
jmp _ZN5Cache7getByteEjPj; Cache::getByte(uint,uint *)
loc_3015:
and esi, 0FFFh
mov bl, [rax+rsi]
jmp short loc_3030
loc_3020:
lea rdi, aByteReadToInva; "Byte read to invalid addr 0x%x!\n"
xor ebx, ebx
xor eax, eax
call _Z9dbgprintfPKcz; dbgprintf(char const*,...)
loc_3030:
mov eax, ebx
pop rbx
retn
| long long MemoryManager::getByte(
MemoryManager *this,
long long a2,
unsigned int *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)
{
unsigned int v14; // ebx
long long v15; // rax
long long v16; // rax
Cache *v17; // rdi
char v19; // [rsp+0h] [rbp-8h]
v15 = *((_QWORD *)this + ((unsigned int)a2 >> 22));
if ( v15 && (a4 = ((unsigned int)a2 >> 9) & 0x1FF8, (v16 = *(_QWORD *)(v15 + a4)) != 0) )
{
v17 = (Cache *)*((_QWORD *)this + 1024);
if ( v17 )
return Cache::getByte(v17, a2, a3);
LOBYTE(v14) = *(_BYTE *)(v16 + (a2 & 0xFFF));
}
else
{
v14 = 0;
dbgprintf(
"Byte read to invalid addr 0x%x!\n",
a2,
(long long)a3,
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
a12,
a13,
a14,
v19);
}
return v14;
}
| getByte:
PUSH RBX
MOV EAX,ESI
SHR EAX,0x16
MOV RAX,qword ptr [RDI + RAX*0x8]
TEST RAX,RAX
JZ 0x00103020
MOV ECX,ESI
SHR ECX,0x9
AND ECX,0x1ff8
MOV RAX,qword ptr [RAX + RCX*0x1]
TEST RAX,RAX
JZ 0x00103020
MOV RDI,qword ptr [RDI + 0x2000]
TEST RDI,RDI
JZ 0x00103015
POP RBX
JMP 0x001039d6
LAB_00103015:
AND ESI,0xfff
MOV BL,byte ptr [RAX + RSI*0x1]
JMP 0x00103030
LAB_00103020:
LEA RDI,[0x1051b7]
XOR EBX,EBX
XOR EAX,EAX
CALL 0x00102330
LAB_00103030:
MOV EAX,EBX
POP RBX
RET
|
/* MemoryManager::getByte(unsigned int, unsigned int*) */
ulong __thiscall MemoryManager::getByte(MemoryManager *this,uint param_1,uint *param_2)
{
long lVar1;
ulong uVar2;
int8 unaff_RBX;
if ((*(long *)(this + (ulong)(param_1 >> 0x16) * 8) == 0) ||
(lVar1 = *(long *)(*(long *)(this + (ulong)(param_1 >> 0x16) * 8) +
(ulong)(param_1 >> 9 & 0x1ff8)), lVar1 == 0)) {
uVar2 = 0;
dbgprintf("Byte read to invalid addr 0x%x!\n");
}
else {
if (*(Cache **)(this + 0x2000) != (Cache *)0x0) {
uVar2 = Cache::getByte(*(Cache **)(this + 0x2000),param_1,param_2);
return uVar2;
}
uVar2 = CONCAT71((int7)((ulong)unaff_RBX >> 8),*(int1 *)(lVar1 + (ulong)(param_1 & 0xfff))
);
}
return uVar2 & 0xffffffff;
}
| |
55,565 | fmt::v10::detail::compare(fmt::v10::detail::bigint const&, fmt::v10::detail::bigint const&) | AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/fmt/bundled/format.h | FMT_CONSTEXPR20 auto compare(const bigint& lhs, const bigint& rhs)
-> int {
int num_lhs_bigits = lhs.num_bigits(), num_rhs_bigits = rhs.num_bigits();
if (num_lhs_bigits != num_rhs_bigits)
return num_lhs_bigits > num_rhs_bigits ? 1 : -1;
int i = static_cast<int>(lhs.bigits_.size()) - 1;
int j = static_cast<int>(rhs.bigits_.size()) - 1;
int end = i - j;
if (end < 0) end = 0;
for (; i >= end; --i, --j) {
bigit lhs_bigit = lhs[i], rhs_bigit = rhs[j];
if (lhs_bigit != rhs_bigit) return lhs_bigit > rhs_bigit ? 1 : -1;
}
if (i != j) return i > j ? 1 : -1;
return 0;
} | O0 | c | fmt::v10::detail::compare(fmt::v10::detail::bigint const&, fmt::v10::detail::bigint const&):
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq 0x28(%rsp), %rdi
callq 0xa4e70
movl %eax, 0x1c(%rsp)
movq 0x20(%rsp), %rdi
callq 0xa4e70
movl %eax, 0x18(%rsp)
movl 0x1c(%rsp), %eax
cmpl 0x18(%rsp), %eax
je 0xa3974
movl 0x1c(%rsp), %edx
movl 0x18(%rsp), %esi
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
movl $0x1, %ecx
cmpl %esi, %edx
cmovgl %ecx, %eax
movl %eax, 0x34(%rsp)
jmp 0xa3a51
movq 0x28(%rsp), %rdi
callq 0xa3dd0
subl $0x1, %eax
movl %eax, 0x14(%rsp)
movq 0x20(%rsp), %rdi
callq 0xa3dd0
subl $0x1, %eax
movl %eax, 0x10(%rsp)
movl 0x14(%rsp), %eax
subl 0x10(%rsp), %eax
movl %eax, 0xc(%rsp)
cmpl $0x0, 0xc(%rsp)
jge 0xa39b1
movl $0x0, 0xc(%rsp)
jmp 0xa39b3
movl 0x14(%rsp), %eax
cmpl 0xc(%rsp), %eax
jl 0xa3a22
movq 0x28(%rsp), %rdi
movl 0x14(%rsp), %esi
callq 0xa4f40
movl %eax, 0x8(%rsp)
movq 0x20(%rsp), %rdi
movl 0x10(%rsp), %esi
callq 0xa4f40
movl %eax, 0x4(%rsp)
movl 0x8(%rsp), %eax
cmpl 0x4(%rsp), %eax
je 0xa3a08
movl 0x8(%rsp), %edx
movl 0x4(%rsp), %esi
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
movl $0x1, %ecx
cmpl %esi, %edx
cmoval %ecx, %eax
movl %eax, 0x34(%rsp)
jmp 0xa3a51
jmp 0xa3a0a
movl 0x14(%rsp), %eax
addl $-0x1, %eax
movl %eax, 0x14(%rsp)
movl 0x10(%rsp), %eax
addl $-0x1, %eax
movl %eax, 0x10(%rsp)
jmp 0xa39b3
movl 0x14(%rsp), %eax
cmpl 0x10(%rsp), %eax
je 0xa3a49
movl 0x14(%rsp), %edx
movl 0x10(%rsp), %esi
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
movl $0x1, %ecx
cmpl %esi, %edx
cmovgl %ecx, %eax
movl %eax, 0x34(%rsp)
jmp 0xa3a51
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
addq $0x38, %rsp
retq
nopw (%rax,%rax)
| _ZN3fmt3v106detail7compareERKNS1_6bigintES4_:
sub rsp, 38h
mov [rsp+38h+var_10], rdi
mov [rsp+38h+var_18], rsi
mov rdi, [rsp+38h+var_10]; this
call _ZNK3fmt3v106detail6bigint10num_bigitsEv; fmt::v10::detail::bigint::num_bigits(void)
mov [rsp+38h+var_1C], eax
mov rdi, [rsp+38h+var_18]; this
call _ZNK3fmt3v106detail6bigint10num_bigitsEv; fmt::v10::detail::bigint::num_bigits(void)
mov [rsp+38h+var_20], eax
mov eax, [rsp+38h+var_1C]
cmp eax, [rsp+38h+var_20]
jz short loc_A3974
mov edx, [rsp+38h+var_1C]
mov esi, [rsp+38h+var_20]
mov eax, 0FFFFFFFFh
mov ecx, 1
cmp edx, esi
cmovg eax, ecx
mov [rsp+38h+var_4], eax
jmp loc_A3A51
loc_A3974:
mov rdi, [rsp+38h+var_10]
call _ZNK3fmt3v106detail6bufferIjE4sizeEv; fmt::v10::detail::buffer<uint>::size(void)
sub eax, 1
mov [rsp+38h+var_24], eax
mov rdi, [rsp+38h+var_18]
call _ZNK3fmt3v106detail6bufferIjE4sizeEv; fmt::v10::detail::buffer<uint>::size(void)
sub eax, 1
mov [rsp+38h+var_28], eax
mov eax, [rsp+38h+var_24]
sub eax, [rsp+38h+var_28]
mov [rsp+38h+var_2C], eax
cmp [rsp+38h+var_2C], 0
jge short loc_A39B1
mov [rsp+38h+var_2C], 0
loc_A39B1:
jmp short $+2
loc_A39B3:
mov eax, [rsp+38h+var_24]
cmp eax, [rsp+38h+var_2C]
jl short loc_A3A22
mov rdi, [rsp+38h+var_10]
mov esi, [rsp+38h+var_24]
call _ZNK3fmt3v106detail6bigintixEi; fmt::v10::detail::bigint::operator[](int)
mov [rsp+38h+var_30], eax
mov rdi, [rsp+38h+var_18]
mov esi, [rsp+38h+var_28]
call _ZNK3fmt3v106detail6bigintixEi; fmt::v10::detail::bigint::operator[](int)
mov [rsp+38h+var_34], eax
mov eax, [rsp+38h+var_30]
cmp eax, [rsp+38h+var_34]
jz short loc_A3A08
mov edx, [rsp+38h+var_30]
mov esi, [rsp+38h+var_34]
mov eax, 0FFFFFFFFh
mov ecx, 1
cmp edx, esi
cmova eax, ecx
mov [rsp+38h+var_4], eax
jmp short loc_A3A51
loc_A3A08:
jmp short $+2
loc_A3A0A:
mov eax, [rsp+38h+var_24]
add eax, 0FFFFFFFFh
mov [rsp+38h+var_24], eax
mov eax, [rsp+38h+var_28]
add eax, 0FFFFFFFFh
mov [rsp+38h+var_28], eax
jmp short loc_A39B3
loc_A3A22:
mov eax, [rsp+38h+var_24]
cmp eax, [rsp+38h+var_28]
jz short loc_A3A49
mov edx, [rsp+38h+var_24]
mov esi, [rsp+38h+var_28]
mov eax, 0FFFFFFFFh
mov ecx, 1
cmp edx, esi
cmovg eax, ecx
mov [rsp+38h+var_4], eax
jmp short loc_A3A51
loc_A3A49:
mov [rsp+38h+var_4], 0
loc_A3A51:
mov eax, [rsp+38h+var_4]
add rsp, 38h
retn
| long long fmt::v10::detail::compare(
fmt::v10::detail *this,
const fmt::v10::detail::bigint *a2,
const fmt::v10::detail::bigint *a3)
{
unsigned int v3; // eax
unsigned int v4; // eax
unsigned int v5; // eax
unsigned int v7; // [rsp+4h] [rbp-34h]
unsigned int v8; // [rsp+8h] [rbp-30h]
int v9; // [rsp+Ch] [rbp-2Ch]
unsigned int v10; // [rsp+10h] [rbp-28h]
signed int v11; // [rsp+14h] [rbp-24h]
int v12; // [rsp+18h] [rbp-20h]
int v13; // [rsp+1Ch] [rbp-1Ch]
v13 = fmt::v10::detail::bigint::num_bigits(this);
v12 = fmt::v10::detail::bigint::num_bigits(a2);
if ( v13 == v12 )
{
v11 = fmt::v10::detail::buffer<unsigned int>::size(this, a2) - 1;
v10 = fmt::v10::detail::buffer<unsigned int>::size(a2, a2) - 1;
v9 = v11 - v10;
if ( (int)(v11 - v10) < 0 )
v9 = 0;
while ( v11 >= v9 )
{
v8 = fmt::v10::detail::bigint::operator[](this, (unsigned int)v11);
v7 = fmt::v10::detail::bigint::operator[](a2, v10);
if ( v8 != v7 )
{
v4 = -1;
if ( v8 > v7 )
return 1;
return v4;
}
--v11;
--v10;
}
if ( v11 == v10 )
{
return 0;
}
else
{
v5 = -1;
if ( v11 > (int)v10 )
return 1;
return v5;
}
}
else
{
v3 = -1;
if ( v13 > v12 )
return 1;
return v3;
}
}
| compare:
SUB RSP,0x38
MOV qword ptr [RSP + 0x28],RDI
MOV qword ptr [RSP + 0x20],RSI
MOV RDI,qword ptr [RSP + 0x28]
CALL 0x001a4e70
MOV dword ptr [RSP + 0x1c],EAX
MOV RDI,qword ptr [RSP + 0x20]
CALL 0x001a4e70
MOV dword ptr [RSP + 0x18],EAX
MOV EAX,dword ptr [RSP + 0x1c]
CMP EAX,dword ptr [RSP + 0x18]
JZ 0x001a3974
MOV EDX,dword ptr [RSP + 0x1c]
MOV ESI,dword ptr [RSP + 0x18]
MOV EAX,0xffffffff
MOV ECX,0x1
CMP EDX,ESI
CMOVG EAX,ECX
MOV dword ptr [RSP + 0x34],EAX
JMP 0x001a3a51
LAB_001a3974:
MOV RDI,qword ptr [RSP + 0x28]
CALL 0x001a3dd0
SUB EAX,0x1
MOV dword ptr [RSP + 0x14],EAX
MOV RDI,qword ptr [RSP + 0x20]
CALL 0x001a3dd0
SUB EAX,0x1
MOV dword ptr [RSP + 0x10],EAX
MOV EAX,dword ptr [RSP + 0x14]
SUB EAX,dword ptr [RSP + 0x10]
MOV dword ptr [RSP + 0xc],EAX
CMP dword ptr [RSP + 0xc],0x0
JGE 0x001a39b1
MOV dword ptr [RSP + 0xc],0x0
LAB_001a39b1:
JMP 0x001a39b3
LAB_001a39b3:
MOV EAX,dword ptr [RSP + 0x14]
CMP EAX,dword ptr [RSP + 0xc]
JL 0x001a3a22
MOV RDI,qword ptr [RSP + 0x28]
MOV ESI,dword ptr [RSP + 0x14]
CALL 0x001a4f40
MOV dword ptr [RSP + 0x8],EAX
MOV RDI,qword ptr [RSP + 0x20]
MOV ESI,dword ptr [RSP + 0x10]
CALL 0x001a4f40
MOV dword ptr [RSP + 0x4],EAX
MOV EAX,dword ptr [RSP + 0x8]
CMP EAX,dword ptr [RSP + 0x4]
JZ 0x001a3a08
MOV EDX,dword ptr [RSP + 0x8]
MOV ESI,dword ptr [RSP + 0x4]
MOV EAX,0xffffffff
MOV ECX,0x1
CMP EDX,ESI
CMOVA EAX,ECX
MOV dword ptr [RSP + 0x34],EAX
JMP 0x001a3a51
LAB_001a3a08:
JMP 0x001a3a0a
LAB_001a3a0a:
MOV EAX,dword ptr [RSP + 0x14]
ADD EAX,-0x1
MOV dword ptr [RSP + 0x14],EAX
MOV EAX,dword ptr [RSP + 0x10]
ADD EAX,-0x1
MOV dword ptr [RSP + 0x10],EAX
JMP 0x001a39b3
LAB_001a3a22:
MOV EAX,dword ptr [RSP + 0x14]
CMP EAX,dword ptr [RSP + 0x10]
JZ 0x001a3a49
MOV EDX,dword ptr [RSP + 0x14]
MOV ESI,dword ptr [RSP + 0x10]
MOV EAX,0xffffffff
MOV ECX,0x1
CMP EDX,ESI
CMOVG EAX,ECX
MOV dword ptr [RSP + 0x34],EAX
JMP 0x001a3a51
LAB_001a3a49:
MOV dword ptr [RSP + 0x34],0x0
LAB_001a3a51:
MOV EAX,dword ptr [RSP + 0x34]
ADD RSP,0x38
RET
|
/* fmt::v10::detail::compare(fmt::v10::detail::bigint const&, fmt::v10::detail::bigint const&) */
int4 fmt::v10::detail::compare(bigint *param_1,bigint *param_2)
{
int iVar1;
int iVar2;
uint uVar3;
uint uVar4;
int local_2c;
int local_28;
int local_24;
int4 local_4;
iVar1 = bigint::num_bigits(param_1);
iVar2 = bigint::num_bigits(param_2);
if (iVar1 == iVar2) {
local_24 = buffer<unsigned_int>::size((buffer<unsigned_int> *)param_1);
local_24 = local_24 + -1;
local_28 = buffer<unsigned_int>::size((buffer<unsigned_int> *)param_2);
local_28 = local_28 + -1;
local_2c = local_24 - local_28;
if (local_2c < 0) {
local_2c = 0;
}
for (; local_2c <= local_24; local_24 = local_24 + -1) {
uVar3 = bigint::operator[](param_1,local_24);
uVar4 = bigint::operator[](param_2,local_28);
if (uVar3 != uVar4) {
if (uVar3 <= uVar4) {
return 0xffffffff;
}
return 1;
}
local_28 = local_28 + -1;
}
if (local_24 == local_28) {
local_4 = 0;
}
else {
local_4 = 0xffffffff;
if (local_28 < local_24) {
local_4 = 1;
}
}
}
else {
local_4 = 0xffffffff;
if (iVar2 < iVar1) {
local_4 = 1;
}
}
return local_4;
}
| |
55,566 | mi_check_unique | eloqsql/storage/myisam/mi_unique.c | my_bool mi_check_unique(MI_INFO *info, MI_UNIQUEDEF *def, const uchar *record,
ha_checksum unique_hash, my_off_t disk_pos)
{
my_off_t lastpos=info->lastpos;
MI_KEYDEF *key= &info->s->keyinfo[def->key];
uchar *key_buff=info->lastkey2;
DBUG_ENTER("mi_check_unique");
/* We need to store the hash value as a key in the record, breaking const */
mi_unique_store(((uchar*) record)+key->seg->start, unique_hash);
_mi_make_key(info,def->key,key_buff,record,0);
/* The above changed info->lastkey2. Inform mi_rnext_same(). */
info->update&= ~HA_STATE_RNEXT_SAME;
if (_mi_search(info,info->s->keyinfo+def->key,key_buff,MI_UNIQUE_HASH_LENGTH,
SEARCH_FIND,info->s->state.key_root[def->key]))
{
info->page_changed=1; /* Can't optimize read next */
info->lastpos= lastpos;
DBUG_RETURN(0); /* No matching rows */
}
for (;;)
{
if (info->lastpos != disk_pos &&
!(*info->s->compare_unique)(info,def,record,info->lastpos))
{
my_errno=HA_ERR_FOUND_DUPP_UNIQUE;
info->errkey= (int) def->key;
info->dupp_key_pos= info->lastpos;
info->page_changed=1; /* Can't optimize read next */
info->lastpos=lastpos;
DBUG_PRINT("info",("Found duplicate"));
DBUG_RETURN(1); /* Found identical */
}
if (_mi_search_next(info,info->s->keyinfo+def->key, info->lastkey,
MI_UNIQUE_HASH_LENGTH, SEARCH_BIGGER,
info->s->state.key_root[def->key]) ||
memcmp(info->lastkey, key_buff, MI_UNIQUE_HASH_LENGTH))
{
info->page_changed=1; /* Can't optimize read next */
info->lastpos=lastpos;
DBUG_RETURN(0); /* end of tree */
}
}
} | O0 | c | mi_check_unique:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl %ecx, -0x24(%rbp)
movq %r8, -0x30(%rbp)
movq -0x10(%rbp), %rax
movq 0x170(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x218(%rax), %rax
movq -0x18(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
imulq $0x70, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rax
movq 0x110(%rax), %rax
movq %rax, -0x48(%rbp)
movl -0x24(%rbp), %eax
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x40(%rbp), %rcx
movq 0x28(%rcx), %rcx
movl 0x8(%rcx), %ecx
movb %dl, 0x3(%rax,%rcx)
movq -0x50(%rbp), %rax
shrq $0x8, %rax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x40(%rbp), %rcx
movq 0x28(%rcx), %rcx
movl 0x8(%rcx), %ecx
movb %dl, 0x2(%rax,%rcx)
movq -0x50(%rbp), %rax
shrq $0x10, %rax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x40(%rbp), %rcx
movq 0x28(%rcx), %rcx
movl 0x8(%rcx), %ecx
movb %dl, 0x1(%rax,%rcx)
movq -0x50(%rbp), %rax
shrq $0x18, %rax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x40(%rbp), %rcx
movq 0x28(%rcx), %rcx
movl 0x8(%rcx), %ecx
movb %dl, (%rax,%rcx)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movzbl 0x2(%rax), %esi
movq -0x48(%rbp), %rdx
movq -0x20(%rbp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x39c20
movq -0x10(%rbp), %rax
movl 0x1d0(%rax), %ecx
andl $0xffffefff, %ecx # imm = 0xFFFFEFFF
movl %ecx, 0x1d0(%rax)
movq -0x10(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x218(%rax), %rsi
movq -0x18(%rbp), %rax
movzbl 0x2(%rax), %eax
cltq
imulq $0x70, %rax, %rax
addq %rax, %rsi
movq -0x48(%rbp), %rdx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x98(%rax), %rax
movq -0x18(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
movq (%rax,%rcx,8), %r9
movl $0x4, %ecx
movl $0x1, %r8d
callq 0x4c500
cmpl $0x0, %eax
je 0x52a2d
movq -0x10(%rbp), %rax
movb $0x1, 0x33c(%rax)
movq -0x38(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x170(%rax)
movb $0x0, -0x1(%rbp)
jmp 0x52b6c
jmp 0x52a2f
movq -0x10(%rbp), %rax
movq 0x170(%rax), %rax
cmpq -0x30(%rbp), %rax
je 0x52aca
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x2d8(%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
movq -0x10(%rbp), %rcx
movq 0x170(%rcx), %rcx
callq *%rax
cmpl $0x0, %eax
jne 0x52aca
callq 0x86110
movl $0x8d, (%rax)
movq -0x18(%rbp), %rax
movzbl 0x2(%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x1f0(%rax)
movq -0x10(%rbp), %rax
movq 0x170(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x1a0(%rax)
movq -0x10(%rbp), %rax
movb $0x1, 0x33c(%rax)
movq -0x38(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x170(%rax)
jmp 0x52abf
jmp 0x52ac1
movb $0x1, -0x1(%rbp)
jmp 0x52b6c
movq -0x10(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x218(%rax), %rsi
movq -0x18(%rbp), %rax
movzbl 0x2(%rax), %eax
cltq
imulq $0x70, %rax, %rax
addq %rax, %rsi
movq -0x10(%rbp), %rax
movq 0x108(%rax), %rdx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x98(%rax), %rax
movq -0x18(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
movq (%rax,%rcx,8), %r9
movl $0x4, %ecx
movl $0x8, %r8d
callq 0x4fb00
cmpl $0x0, %eax
jne 0x52b47
movq -0x10(%rbp), %rax
movq 0x108(%rax), %rax
movq -0x48(%rbp), %rcx
movl (%rcx), %ecx
movl (%rax), %eax
subl %ecx, %eax
setne %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x52b67
movq -0x10(%rbp), %rax
movb $0x1, 0x33c(%rax)
movq -0x38(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x170(%rax)
movb $0x0, -0x1(%rbp)
jmp 0x52b6c
jmp 0x52a2f
movb -0x1(%rbp), %al
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| mi_check_unique:
push rbp
mov rbp, rsp
sub rsp, 50h
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 rax, [rbp+var_10]
mov rax, [rax+170h]
mov [rbp+var_38], rax
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+218h]
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+2]
imul rcx, 70h ; 'p'
add rax, rcx
mov [rbp+var_40], rax
mov rax, [rbp+var_10]
mov rax, [rax+110h]
mov [rbp+var_48], rax
mov eax, [rbp+var_24]
mov [rbp+var_50], rax
mov rax, [rbp+var_50]
mov dl, al
mov rax, [rbp+var_20]
mov rcx, [rbp+var_40]
mov rcx, [rcx+28h]
mov ecx, [rcx+8]
mov [rax+rcx+3], dl
mov rax, [rbp+var_50]
shr rax, 8
mov dl, al
mov rax, [rbp+var_20]
mov rcx, [rbp+var_40]
mov rcx, [rcx+28h]
mov ecx, [rcx+8]
mov [rax+rcx+2], dl
mov rax, [rbp+var_50]
shr rax, 10h
mov dl, al
mov rax, [rbp+var_20]
mov rcx, [rbp+var_40]
mov rcx, [rcx+28h]
mov ecx, [rcx+8]
mov [rax+rcx+1], dl
mov rax, [rbp+var_50]
shr rax, 18h
mov dl, al
mov rax, [rbp+var_20]
mov rcx, [rbp+var_40]
mov rcx, [rcx+28h]
mov ecx, [rcx+8]
mov [rax+rcx], dl
mov rdi, [rbp+var_10]
mov rax, [rbp+var_18]
movzx esi, byte ptr [rax+2]
mov rdx, [rbp+var_48]
mov rcx, [rbp+var_20]
xor eax, eax
mov r8d, eax
call _mi_make_key
mov rax, [rbp+var_10]
mov ecx, [rax+1D0h]
and ecx, 0FFFFEFFFh
mov [rax+1D0h], ecx
mov rdi, [rbp+var_10]
mov rax, [rbp+var_10]
mov rax, [rax]
mov rsi, [rax+218h]
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax+2]
cdqe
imul rax, 70h ; 'p'
add rsi, rax
mov rdx, [rbp+var_48]
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+98h]
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+2]
mov r9, [rax+rcx*8]
mov ecx, 4
mov r8d, 1
call _mi_search
cmp eax, 0
jz short loc_52A2D
mov rax, [rbp+var_10]
mov byte ptr [rax+33Ch], 1
mov rcx, [rbp+var_38]
mov rax, [rbp+var_10]
mov [rax+170h], rcx
mov [rbp+var_1], 0
jmp loc_52B6C
loc_52A2D:
jmp short $+2
loc_52A2F:
mov rax, [rbp+var_10]
mov rax, [rax+170h]
cmp rax, [rbp+var_30]
jz loc_52ACA
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+2D8h]
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_20]
mov rcx, [rbp+var_10]
mov rcx, [rcx+170h]
call rax
cmp eax, 0
jnz short loc_52ACA
call _my_thread_var
mov dword ptr [rax], 8Dh
mov rax, [rbp+var_18]
movzx ecx, byte ptr [rax+2]
mov rax, [rbp+var_10]
mov [rax+1F0h], ecx
mov rax, [rbp+var_10]
mov rcx, [rax+170h]
mov rax, [rbp+var_10]
mov [rax+1A0h], rcx
mov rax, [rbp+var_10]
mov byte ptr [rax+33Ch], 1
mov rcx, [rbp+var_38]
mov rax, [rbp+var_10]
mov [rax+170h], rcx
jmp short $+2
loc_52ABF:
jmp short $+2
loc_52AC1:
mov [rbp+var_1], 1
jmp loc_52B6C
loc_52ACA:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_10]
mov rax, [rax]
mov rsi, [rax+218h]
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax+2]
cdqe
imul rax, 70h ; 'p'
add rsi, rax
mov rax, [rbp+var_10]
mov rdx, [rax+108h]
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+98h]
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+2]
mov r9, [rax+rcx*8]
mov ecx, 4
mov r8d, 8
call _mi_search_next
cmp eax, 0
jnz short loc_52B47
mov rax, [rbp+var_10]
mov rax, [rax+108h]
mov rcx, [rbp+var_48]
mov ecx, [rcx]
mov eax, [rax]
sub eax, ecx
setnz al
movzx eax, al
cmp eax, 0
jz short loc_52B67
loc_52B47:
mov rax, [rbp+var_10]
mov byte ptr [rax+33Ch], 1
mov rcx, [rbp+var_38]
mov rax, [rbp+var_10]
mov [rax+170h], rcx
mov [rbp+var_1], 0
jmp short loc_52B6C
loc_52B67:
jmp loc_52A2F
loc_52B6C:
mov al, [rbp+var_1]
add rsp, 50h
pop rbp
retn
| char mi_check_unique(long long a1, long long a2, long long a3, int a4, long long a5)
{
_BYTE *v6; // [rsp+8h] [rbp-48h]
long long v7; // [rsp+10h] [rbp-40h]
long long v8; // [rsp+18h] [rbp-38h]
v8 = *(_QWORD *)(a1 + 368);
v7 = 112LL * *(unsigned __int8 *)(a2 + 2) + *(_QWORD *)(*(_QWORD *)a1 + 536LL);
v6 = *(_BYTE **)(a1 + 272);
*(_BYTE *)(a3 + *(unsigned int *)(*(_QWORD *)(v7 + 40) + 8LL) + 3) = a4;
*(_BYTE *)(a3 + *(unsigned int *)(*(_QWORD *)(v7 + 40) + 8LL) + 2) = BYTE1(a4);
*(_BYTE *)(a3 + *(unsigned int *)(*(_QWORD *)(v7 + 40) + 8LL) + 1) = BYTE2(a4);
*(_BYTE *)(a3 + *(unsigned int *)(*(_QWORD *)(v7 + 40) + 8LL)) = HIBYTE(a4);
mi_make_key(a1, *(unsigned __int8 *)(a2 + 2), v6, a3, 0LL);
*(_DWORD *)(a1 + 464) &= ~0x1000u;
if ( (unsigned int)mi_search(
(_QWORD *)a1,
(const char *)(112LL * *(unsigned __int8 *)(a2 + 2) + *(_QWORD *)(*(_QWORD *)a1 + 536LL)),
(long long)v6,
4u,
1u,
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)a1 + 152LL) + 8LL * *(unsigned __int8 *)(a2 + 2))) )
{
*(_BYTE *)(a1 + 828) = 1;
*(_QWORD *)(a1 + 368) = v8;
return 0;
}
else
{
do
{
if ( *(_QWORD *)(a1 + 368) != a5
&& !(*(unsigned int ( **)(long long, long long, long long, _QWORD))(*(_QWORD *)a1 + 728LL))(
a1,
a2,
a3,
*(_QWORD *)(a1 + 368)) )
{
*(_DWORD *)my_thread_var(a1, (const char *)a2) = 141;
*(_DWORD *)(a1 + 496) = *(unsigned __int8 *)(a2 + 2);
*(_QWORD *)(a1 + 416) = *(_QWORD *)(a1 + 368);
*(_BYTE *)(a1 + 828) = 1;
*(_QWORD *)(a1 + 368) = v8;
return 1;
}
}
while ( !(unsigned int)mi_search_next(
(_QWORD *)a1,
(const char *)(112LL * *(unsigned __int8 *)(a2 + 2) + *(_QWORD *)(*(_QWORD *)a1 + 536LL)),
*(_QWORD *)(a1 + 264),
4u,
8,
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)a1 + 152LL) + 8LL * *(unsigned __int8 *)(a2 + 2)))
&& **(_DWORD **)(a1 + 264) == *(_DWORD *)v6 );
*(_BYTE *)(a1 + 828) = 1;
*(_QWORD *)(a1 + 368) = v8;
return 0;
}
}
| mi_check_unique:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
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 RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x170]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x218]
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x2]
IMUL RCX,RCX,0x70
ADD RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x110]
MOV qword ptr [RBP + -0x48],RAX
MOV EAX,dword ptr [RBP + -0x24]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x50]
MOV DL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RCX + 0x28]
MOV ECX,dword ptr [RCX + 0x8]
MOV byte ptr [RAX + RCX*0x1 + 0x3],DL
MOV RAX,qword ptr [RBP + -0x50]
SHR RAX,0x8
MOV DL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RCX + 0x28]
MOV ECX,dword ptr [RCX + 0x8]
MOV byte ptr [RAX + RCX*0x1 + 0x2],DL
MOV RAX,qword ptr [RBP + -0x50]
SHR RAX,0x10
MOV DL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RCX + 0x28]
MOV ECX,dword ptr [RCX + 0x8]
MOV byte ptr [RAX + RCX*0x1 + 0x1],DL
MOV RAX,qword ptr [RBP + -0x50]
SHR RAX,0x18
MOV DL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RCX + 0x28]
MOV ECX,dword ptr [RCX + 0x8]
MOV byte ptr [RAX + RCX*0x1],DL
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x18]
MOVZX ESI,byte ptr [RAX + 0x2]
MOV RDX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x20]
XOR EAX,EAX
MOV R8D,EAX
CALL 0x00139c20
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x1d0]
AND ECX,0xffffefff
MOV dword ptr [RAX + 0x1d0],ECX
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RSI,qword ptr [RAX + 0x218]
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x2]
CDQE
IMUL RAX,RAX,0x70
ADD RSI,RAX
MOV RDX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x98]
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x2]
MOV R9,qword ptr [RAX + RCX*0x8]
MOV ECX,0x4
MOV R8D,0x1
CALL 0x0014c500
CMP EAX,0x0
JZ 0x00152a2d
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x33c],0x1
MOV RCX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x170],RCX
MOV byte ptr [RBP + -0x1],0x0
JMP 0x00152b6c
LAB_00152a2d:
JMP 0x00152a2f
LAB_00152a2f:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x170]
CMP RAX,qword ptr [RBP + -0x30]
JZ 0x00152aca
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x2d8]
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x170]
CALL RAX
CMP EAX,0x0
JNZ 0x00152aca
CALL 0x00186110
MOV dword ptr [RAX],0x8d
MOV RAX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RAX + 0x2]
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x1f0],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x170]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x1a0],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x33c],0x1
MOV RCX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x170],RCX
JMP 0x00152abf
LAB_00152abf:
JMP 0x00152ac1
LAB_00152ac1:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00152b6c
LAB_00152aca:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RSI,qword ptr [RAX + 0x218]
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x2]
CDQE
IMUL RAX,RAX,0x70
ADD RSI,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RAX + 0x108]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x98]
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x2]
MOV R9,qword ptr [RAX + RCX*0x8]
MOV ECX,0x4
MOV R8D,0x8
CALL 0x0014fb00
CMP EAX,0x0
JNZ 0x00152b47
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x108]
MOV RCX,qword ptr [RBP + -0x48]
MOV ECX,dword ptr [RCX]
MOV EAX,dword ptr [RAX]
SUB EAX,ECX
SETNZ AL
MOVZX EAX,AL
CMP EAX,0x0
JZ 0x00152b67
LAB_00152b47:
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x33c],0x1
MOV RCX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x170],RCX
MOV byte ptr [RBP + -0x1],0x0
JMP 0x00152b6c
LAB_00152b67:
JMP 0x00152a2f
LAB_00152b6c:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x50
POP RBP
RET
|
int1 mi_check_unique(long *param_1,long param_2,long param_3,int4 param_4,long param_5)
{
long lVar1;
int *piVar2;
int iVar3;
long lVar4;
int4 *puVar5;
lVar1 = param_1[0x2e];
lVar4 = *(long *)(*param_1 + 0x218) + (ulong)*(byte *)(param_2 + 2) * 0x70;
piVar2 = (int *)param_1[0x22];
*(char *)(param_3 + 3 + (ulong)*(uint *)(*(long *)(lVar4 + 0x28) + 8)) = (char)param_4;
*(char *)(param_3 + 2 + (ulong)*(uint *)(*(long *)(lVar4 + 0x28) + 8)) =
(char)((uint)param_4 >> 8);
*(char *)(param_3 + 1 + (ulong)*(uint *)(*(long *)(lVar4 + 0x28) + 8)) =
(char)((uint)param_4 >> 0x10);
*(char *)(param_3 + (ulong)*(uint *)(*(long *)(lVar4 + 0x28) + 8)) = (char)((uint)param_4 >> 0x18)
;
_mi_make_key(param_1,*(int1 *)(param_2 + 2),piVar2,param_3,0);
*(uint *)(param_1 + 0x3a) = *(uint *)(param_1 + 0x3a) & 0xffffefff;
iVar3 = _mi_search(param_1,*(long *)(*param_1 + 0x218) +
(long)(int)(uint)*(byte *)(param_2 + 2) * 0x70,piVar2,4,1,
*(int8 *)(*(long *)(*param_1 + 0x98) + (ulong)*(byte *)(param_2 + 2) * 8)
);
if (iVar3 == 0) {
do {
if ((param_1[0x2e] != param_5) &&
(iVar3 = (**(code **)(*param_1 + 0x2d8))(param_1,param_2,param_3,param_1[0x2e]), iVar3 == 0
)) {
puVar5 = (int4 *)_my_thread_var();
*puVar5 = 0x8d;
*(uint *)(param_1 + 0x3e) = (uint)*(byte *)(param_2 + 2);
param_1[0x34] = param_1[0x2e];
*(int1 *)((long)param_1 + 0x33c) = 1;
param_1[0x2e] = lVar1;
return 1;
}
iVar3 = _mi_search_next(param_1,*(long *)(*param_1 + 0x218) +
(long)(int)(uint)*(byte *)(param_2 + 2) * 0x70,param_1[0x21],4
,8,*(int8 *)
(*(long *)(*param_1 + 0x98) + (ulong)*(byte *)(param_2 + 2) * 8));
} while ((iVar3 == 0) && (*(int *)param_1[0x21] == *piVar2));
*(int1 *)((long)param_1 + 0x33c) = 1;
param_1[0x2e] = lVar1;
}
else {
*(int1 *)((long)param_1 + 0x33c) = 1;
param_1[0x2e] = lVar1;
}
return 0;
}
| |
55,567 | mi_check_unique | eloqsql/storage/myisam/mi_unique.c | my_bool mi_check_unique(MI_INFO *info, MI_UNIQUEDEF *def, const uchar *record,
ha_checksum unique_hash, my_off_t disk_pos)
{
my_off_t lastpos=info->lastpos;
MI_KEYDEF *key= &info->s->keyinfo[def->key];
uchar *key_buff=info->lastkey2;
DBUG_ENTER("mi_check_unique");
/* We need to store the hash value as a key in the record, breaking const */
mi_unique_store(((uchar*) record)+key->seg->start, unique_hash);
_mi_make_key(info,def->key,key_buff,record,0);
/* The above changed info->lastkey2. Inform mi_rnext_same(). */
info->update&= ~HA_STATE_RNEXT_SAME;
if (_mi_search(info,info->s->keyinfo+def->key,key_buff,MI_UNIQUE_HASH_LENGTH,
SEARCH_FIND,info->s->state.key_root[def->key]))
{
info->page_changed=1; /* Can't optimize read next */
info->lastpos= lastpos;
DBUG_RETURN(0); /* No matching rows */
}
for (;;)
{
if (info->lastpos != disk_pos &&
!(*info->s->compare_unique)(info,def,record,info->lastpos))
{
my_errno=HA_ERR_FOUND_DUPP_UNIQUE;
info->errkey= (int) def->key;
info->dupp_key_pos= info->lastpos;
info->page_changed=1; /* Can't optimize read next */
info->lastpos=lastpos;
DBUG_PRINT("info",("Found duplicate"));
DBUG_RETURN(1); /* Found identical */
}
if (_mi_search_next(info,info->s->keyinfo+def->key, info->lastkey,
MI_UNIQUE_HASH_LENGTH, SEARCH_BIGGER,
info->s->state.key_root[def->key]) ||
memcmp(info->lastkey, key_buff, MI_UNIQUE_HASH_LENGTH))
{
info->page_changed=1; /* Can't optimize read next */
info->lastpos=lastpos;
DBUG_RETURN(0); /* end of tree */
}
}
} | O3 | c | mi_check_unique:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r8, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq 0x170(%rdi), %rax
movq %rax, -0x30(%rbp)
movq (%rdi), %rax
movq 0x110(%rdi), %r12
movq 0x218(%rax), %rax
movzbl 0x2(%rsi), %esi
imulq $0x70, %rsi, %r9
movq 0x28(%rax,%r9), %rsi
movl 0x8(%rsi), %esi
movb %cl, 0x3(%rdx,%rsi)
movq 0x28(%rax,%r9), %rsi
movl 0x8(%rsi), %esi
movb %ch, 0x2(%rdx,%rsi)
movq %rdx, %r8
movl %ecx, %esi
shrl $0x10, %esi
movq 0x28(%rax,%r9), %rdi
movl 0x8(%rdi), %edi
movb %sil, 0x1(%rdx,%rdi)
shrl $0x18, %ecx
movq 0x28(%rax,%r9), %rax
movl 0x8(%rax), %eax
movb %cl, (%rdx,%rax)
movzbl 0x2(%r14), %esi
xorl %r13d, %r13d
movq %rbx, %rdi
movq %r12, %rdx
movq %r8, -0x38(%rbp)
movq %r8, %rcx
xorl %r8d, %r8d
callq 0x35c10
andb $-0x11, 0x1d1(%rbx)
movq (%rbx), %rax
movzbl 0x2(%r14), %ecx
imulq $0x70, %rcx, %rsi
addq 0x218(%rax), %rsi
movq 0x98(%rax), %rax
movq (%rax,%rcx,8), %r9
movq %rbx, %rdi
movq %r12, %rdx
movl $0x4, %ecx
movl $0x1, %r8d
callq 0x403b3
testl %eax, %eax
movq -0x30(%rbp), %rax
jne 0x43b0e
movq -0x38(%rbp), %r13
movq 0x170(%rbx), %rcx
cmpq %r15, %rcx
je 0x43a93
movq (%rbx), %rax
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq *0x2d8(%rax)
testl %eax, %eax
je 0x43ae3
movzbl 0x2(%r14), %eax
imulq $0x70, %rax, %rsi
movq (%rbx), %rcx
movq 0x108(%rbx), %rdx
addq 0x218(%rcx), %rsi
movq 0x98(%rcx), %rcx
movq (%rcx,%rax,8), %r9
movq %rbx, %rdi
movl $0x4, %ecx
movl $0x8, %r8d
callq 0x42031
testl %eax, %eax
jne 0x43ade
movq 0x108(%rbx), %rax
movl (%rax), %eax
cmpl (%r12), %eax
je 0x43a71
xorl %r13d, %r13d
jmp 0x43b0a
callq 0x5ecfe
movl $0x8d, (%rax)
movzbl 0x2(%r14), %eax
movl %eax, 0x1f0(%rbx)
movq 0x170(%rbx), %rax
movq %rax, 0x1a0(%rbx)
movb $0x1, %r13b
movq -0x30(%rbp), %rax
movb $0x1, 0x33c(%rbx)
movq %rax, 0x170(%rbx)
movl %r13d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| mi_check_unique:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov r15, r8
mov r14, rsi
mov rbx, rdi
mov rax, [rdi+170h]
mov [rbp+var_30], rax
mov rax, [rdi]
mov r12, [rdi+110h]
mov rax, [rax+218h]
movzx esi, byte ptr [rsi+2]
imul r9, rsi, 70h ; 'p'
mov rsi, [rax+r9+28h]
mov esi, [rsi+8]
mov [rdx+rsi+3], cl
mov rsi, [rax+r9+28h]
mov esi, [rsi+8]
mov [rdx+rsi+2], ch
mov r8, rdx
mov esi, ecx
shr esi, 10h
mov rdi, [rax+r9+28h]
mov edi, [rdi+8]
mov [rdx+rdi+1], sil
shr ecx, 18h
mov rax, [rax+r9+28h]
mov eax, [rax+8]
mov [rdx+rax], cl
movzx esi, byte ptr [r14+2]
xor r13d, r13d
mov rdi, rbx
mov rdx, r12
mov [rbp+var_38], r8
mov rcx, r8
xor r8d, r8d
call _mi_make_key
and byte ptr [rbx+1D1h], 0EFh
mov rax, [rbx]
movzx ecx, byte ptr [r14+2]
imul rsi, rcx, 70h ; 'p'
add rsi, [rax+218h]
mov rax, [rax+98h]
mov r9, [rax+rcx*8]
mov rdi, rbx
mov rdx, r12
mov ecx, 4
mov r8d, 1
call _mi_search
test eax, eax
mov rax, [rbp+var_30]
jnz loc_43B0E
mov r13, [rbp+var_38]
loc_43A71:
mov rcx, [rbx+170h]
cmp rcx, r15
jz short loc_43A93
mov rax, [rbx]
mov rdi, rbx
mov rsi, r14
mov rdx, r13
call qword ptr [rax+2D8h]
test eax, eax
jz short loc_43AE3
loc_43A93:
movzx eax, byte ptr [r14+2]
imul rsi, rax, 70h ; 'p'
mov rcx, [rbx]
mov rdx, [rbx+108h]
add rsi, [rcx+218h]
mov rcx, [rcx+98h]
mov r9, [rcx+rax*8]
mov rdi, rbx
mov ecx, 4
mov r8d, 8
call _mi_search_next
test eax, eax
jnz short loc_43ADE
mov rax, [rbx+108h]
mov eax, [rax]
cmp eax, [r12]
jz short loc_43A71
loc_43ADE:
xor r13d, r13d
jmp short loc_43B0A
loc_43AE3:
call _my_thread_var
mov dword ptr [rax], 8Dh
movzx eax, byte ptr [r14+2]
mov [rbx+1F0h], eax
mov rax, [rbx+170h]
mov [rbx+1A0h], rax
mov r13b, 1
loc_43B0A:
mov rax, [rbp+var_30]
loc_43B0E:
mov byte ptr [rbx+33Ch], 1
mov [rbx+170h], rax
mov eax, r13d
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long mi_check_unique(long long a1, long long a2, long long a3, int a4, long long a5)
{
char *v6; // r12
long long v7; // rax
long long v8; // r9
unsigned int v9; // r13d
bool v10; // zf
long long v11; // rax
long long v14; // [rsp+10h] [rbp-30h]
v14 = *(_QWORD *)(a1 + 368);
v6 = *(char **)(a1 + 272);
v7 = *(_QWORD *)(*(_QWORD *)a1 + 536LL);
v8 = 112LL * *(unsigned __int8 *)(a2 + 2);
*(_BYTE *)(a3 + *(unsigned int *)(*(_QWORD *)(v7 + v8 + 40) + 8LL) + 3) = a4;
*(_BYTE *)(a3 + *(unsigned int *)(*(_QWORD *)(v7 + v8 + 40) + 8LL) + 2) = BYTE1(a4);
*(_BYTE *)(a3 + *(unsigned int *)(*(_QWORD *)(v7 + v8 + 40) + 8LL) + 1) = BYTE2(a4);
*(_BYTE *)(a3 + *(unsigned int *)(*(_QWORD *)(v7 + v8 + 40) + 8LL)) = HIBYTE(a4);
v9 = 0;
mi_make_key(a1, *(unsigned __int8 *)(a2 + 2), v6, a3, 0LL);
*(_BYTE *)(a1 + 465) &= ~0x10u;
v10 = (unsigned int)mi_search(
a1,
*(_QWORD *)(*(_QWORD *)a1 + 536LL) + 112LL * *(unsigned __int8 *)(a2 + 2),
(long long)v6,
4u,
1u,
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)a1 + 152LL) + 8LL * *(unsigned __int8 *)(a2 + 2))) == 0;
v11 = v14;
if ( v10 )
{
v9 = a3;
while ( *(_QWORD *)(a1 + 368) == a5
|| (*(unsigned int ( **)(long long, long long, long long))(*(_QWORD *)a1 + 728LL))(a1, a2, a3) )
{
if ( (unsigned int)mi_search_next(
a1,
*(_QWORD *)(*(_QWORD *)a1 + 536LL) + 112LL * *(unsigned __int8 *)(a2 + 2),
*(_QWORD *)(a1 + 264),
4u,
8,
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)a1 + 152LL) + 8LL * *(unsigned __int8 *)(a2 + 2)))
|| **(_DWORD **)(a1 + 264) != *(_DWORD *)v6 )
{
v9 = 0;
goto LABEL_9;
}
}
*(_DWORD *)my_thread_var(a1, (const char *)a2) = 141;
*(_DWORD *)(a1 + 496) = *(unsigned __int8 *)(a2 + 2);
*(_QWORD *)(a1 + 416) = *(_QWORD *)(a1 + 368);
LOBYTE(v9) = 1;
LABEL_9:
v11 = v14;
}
*(_BYTE *)(a1 + 828) = 1;
*(_QWORD *)(a1 + 368) = v11;
return v9;
}
| mi_check_unique:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV R15,R8
MOV R14,RSI
MOV RBX,RDI
MOV RAX,qword ptr [RDI + 0x170]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RDI]
MOV R12,qword ptr [RDI + 0x110]
MOV RAX,qword ptr [RAX + 0x218]
MOVZX ESI,byte ptr [RSI + 0x2]
IMUL R9,RSI,0x70
MOV RSI,qword ptr [RAX + R9*0x1 + 0x28]
MOV ESI,dword ptr [RSI + 0x8]
MOV byte ptr [RDX + RSI*0x1 + 0x3],CL
MOV RSI,qword ptr [RAX + R9*0x1 + 0x28]
MOV ESI,dword ptr [RSI + 0x8]
MOV byte ptr [RDX + RSI*0x1 + 0x2],CH
MOV R8,RDX
MOV ESI,ECX
SHR ESI,0x10
MOV RDI,qword ptr [RAX + R9*0x1 + 0x28]
MOV EDI,dword ptr [RDI + 0x8]
MOV byte ptr [RDX + RDI*0x1 + 0x1],SIL
SHR ECX,0x18
MOV RAX,qword ptr [RAX + R9*0x1 + 0x28]
MOV EAX,dword ptr [RAX + 0x8]
MOV byte ptr [RDX + RAX*0x1],CL
MOVZX ESI,byte ptr [R14 + 0x2]
XOR R13D,R13D
MOV RDI,RBX
MOV RDX,R12
MOV qword ptr [RBP + -0x38],R8
MOV RCX,R8
XOR R8D,R8D
CALL 0x00135c10
AND byte ptr [RBX + 0x1d1],0xef
MOV RAX,qword ptr [RBX]
MOVZX ECX,byte ptr [R14 + 0x2]
IMUL RSI,RCX,0x70
ADD RSI,qword ptr [RAX + 0x218]
MOV RAX,qword ptr [RAX + 0x98]
MOV R9,qword ptr [RAX + RCX*0x8]
MOV RDI,RBX
MOV RDX,R12
MOV ECX,0x4
MOV R8D,0x1
CALL 0x001403b3
TEST EAX,EAX
MOV RAX,qword ptr [RBP + -0x30]
JNZ 0x00143b0e
MOV R13,qword ptr [RBP + -0x38]
LAB_00143a71:
MOV RCX,qword ptr [RBX + 0x170]
CMP RCX,R15
JZ 0x00143a93
MOV RAX,qword ptr [RBX]
MOV RDI,RBX
MOV RSI,R14
MOV RDX,R13
CALL qword ptr [RAX + 0x2d8]
TEST EAX,EAX
JZ 0x00143ae3
LAB_00143a93:
MOVZX EAX,byte ptr [R14 + 0x2]
IMUL RSI,RAX,0x70
MOV RCX,qword ptr [RBX]
MOV RDX,qword ptr [RBX + 0x108]
ADD RSI,qword ptr [RCX + 0x218]
MOV RCX,qword ptr [RCX + 0x98]
MOV R9,qword ptr [RCX + RAX*0x8]
MOV RDI,RBX
MOV ECX,0x4
MOV R8D,0x8
CALL 0x00142031
TEST EAX,EAX
JNZ 0x00143ade
MOV RAX,qword ptr [RBX + 0x108]
MOV EAX,dword ptr [RAX]
CMP EAX,dword ptr [R12]
JZ 0x00143a71
LAB_00143ade:
XOR R13D,R13D
JMP 0x00143b0a
LAB_00143ae3:
CALL 0x0015ecfe
MOV dword ptr [RAX],0x8d
MOVZX EAX,byte ptr [R14 + 0x2]
MOV dword ptr [RBX + 0x1f0],EAX
MOV RAX,qword ptr [RBX + 0x170]
MOV qword ptr [RBX + 0x1a0],RAX
MOV R13B,0x1
LAB_00143b0a:
MOV RAX,qword ptr [RBP + -0x30]
LAB_00143b0e:
MOV byte ptr [RBX + 0x33c],0x1
MOV qword ptr [RBX + 0x170],RAX
MOV EAX,R13D
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
ulong mi_check_unique(long *param_1,long param_2,long param_3,int4 param_4,long param_5)
{
long lVar1;
int *piVar2;
long lVar3;
int iVar4;
int4 *puVar5;
long lVar6;
ulong uVar7;
lVar1 = param_1[0x2e];
piVar2 = (int *)param_1[0x22];
lVar3 = *(long *)(*param_1 + 0x218);
lVar6 = (ulong)*(byte *)(param_2 + 2) * 0x70;
*(char *)(param_3 + 3 + (ulong)*(uint *)(*(long *)(lVar3 + 0x28 + lVar6) + 8)) = (char)param_4;
*(char *)(param_3 + 2 + (ulong)*(uint *)(*(long *)(lVar3 + 0x28 + lVar6) + 8)) =
(char)((uint)param_4 >> 8);
*(char *)(param_3 + 1 + (ulong)*(uint *)(*(long *)(lVar3 + 0x28 + lVar6) + 8)) =
(char)((uint)param_4 >> 0x10);
*(char *)(param_3 + (ulong)*(uint *)(*(long *)(lVar3 + 0x28 + lVar6) + 8)) =
(char)((uint)param_4 >> 0x18);
uVar7 = 0;
_mi_make_key(param_1,*(int1 *)(param_2 + 2),piVar2,param_3,0);
*(byte *)((long)param_1 + 0x1d1) = *(byte *)((long)param_1 + 0x1d1) & 0xef;
iVar4 = _mi_search(param_1,(ulong)*(byte *)(param_2 + 2) * 0x70 + *(long *)(*param_1 + 0x218),
piVar2,4,1,
*(int8 *)(*(long *)(*param_1 + 0x98) + (ulong)*(byte *)(param_2 + 2) * 8)
);
if (iVar4 == 0) {
do {
if ((param_1[0x2e] != param_5) &&
(iVar4 = (**(code **)(*param_1 + 0x2d8))(param_1,param_2,param_3), iVar4 == 0)) {
puVar5 = (int4 *)_my_thread_var();
*puVar5 = 0x8d;
*(uint *)(param_1 + 0x3e) = (uint)*(byte *)(param_2 + 2);
param_1[0x34] = param_1[0x2e];
uVar7 = CONCAT71((int7)((ulong)param_3 >> 8),1);
goto LAB_00143b0e;
}
iVar4 = _mi_search_next(param_1,(ulong)*(byte *)(param_2 + 2) * 0x70 +
*(long *)(*param_1 + 0x218),param_1[0x21],4,8,
*(int8 *)
(*(long *)(*param_1 + 0x98) + (ulong)*(byte *)(param_2 + 2) * 8));
} while ((iVar4 == 0) && (*(int *)param_1[0x21] == *piVar2));
uVar7 = 0;
}
LAB_00143b0e:
*(int1 *)((long)param_1 + 0x33c) = 1;
param_1[0x2e] = lVar1;
return uVar7 & 0xffffffff;
}
| |
55,568 | CLI::Option::type_size(int, int) | MikePodsytnik[P]TCRtrie/build_O0/_deps/cli11-src/include/CLI/impl/Option_inl.hpp | CLI11_INLINE Option *Option::type_size(int option_type_size_min, int option_type_size_max) {
if(option_type_size_min < 0 || option_type_size_max < 0) {
// this section is included for backwards compatibility
expected_max_ = detail::expected_max_vector_size;
option_type_size_min = (std::abs)(option_type_size_min);
option_type_size_max = (std::abs)(option_type_size_max);
}
if(option_type_size_min > option_type_size_max) {
type_size_max_ = option_type_size_min;
type_size_min_ = option_type_size_max;
} else {
type_size_min_ = option_type_size_min;
type_size_max_ = option_type_size_max;
}
if(type_size_max_ == 0) {
required_ = false;
}
if(type_size_max_ >= detail::expected_max_vector_size) {
inject_separator_ = true;
}
return this;
} | O0 | cpp | CLI::Option::type_size(int, int):
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
cmpl $0x0, -0xc(%rbp)
jl 0x50232
cmpl $0x0, -0x10(%rbp)
jge 0x5025a
movq -0x18(%rbp), %rax
movl $0x20000000, 0x174(%rax) # imm = 0x20000000
movl -0xc(%rbp), %eax
movl %eax, %ecx
negl %ecx
cmovnsl %ecx, %eax
movl %eax, -0xc(%rbp)
movl -0x10(%rbp), %eax
movl %eax, %ecx
negl %ecx
cmovnsl %ecx, %eax
movl %eax, -0x10(%rbp)
movl -0xc(%rbp), %eax
cmpl -0x10(%rbp), %eax
jle 0x5027a
movq -0x18(%rbp), %rax
movl -0xc(%rbp), %ecx
movl %ecx, 0x168(%rax)
movl -0x10(%rbp), %ecx
movl %ecx, 0x16c(%rax)
jmp 0x50290
movq -0x18(%rbp), %rax
movl -0xc(%rbp), %ecx
movl %ecx, 0x16c(%rax)
movl -0x10(%rbp), %ecx
movl %ecx, 0x168(%rax)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x168(%rax)
jne 0x502a5
movq -0x18(%rbp), %rax
movb $0x0, 0x20(%rax)
movq -0x18(%rbp), %rax
cmpl $0x20000000, 0x168(%rax) # imm = 0x20000000
jl 0x502c0
movq -0x18(%rbp), %rax
movb $0x1, 0x24c(%rax)
movq -0x18(%rbp), %rax
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _ZN3CLI6Option9type_sizeEii:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_10], edx
mov rax, [rbp+var_8]
mov [rbp+var_18], rax
cmp [rbp+var_C], 0
jl short loc_50232
cmp [rbp+var_10], 0
jge short loc_5025A
loc_50232:
mov rax, [rbp+var_18]
mov dword ptr [rax+174h], 20000000h
mov eax, [rbp+var_C]
mov ecx, eax
neg ecx
cmovns eax, ecx
mov [rbp+var_C], eax
mov eax, [rbp+var_10]
mov ecx, eax
neg ecx
cmovns eax, ecx
mov [rbp+var_10], eax
loc_5025A:
mov eax, [rbp+var_C]
cmp eax, [rbp+var_10]
jle short loc_5027A
mov rax, [rbp+var_18]
mov ecx, [rbp+var_C]
mov [rax+168h], ecx
mov ecx, [rbp+var_10]
mov [rax+16Ch], ecx
jmp short loc_50290
loc_5027A:
mov rax, [rbp+var_18]
mov ecx, [rbp+var_C]
mov [rax+16Ch], ecx
mov ecx, [rbp+var_10]
mov [rax+168h], ecx
loc_50290:
mov rax, [rbp+var_18]
cmp dword ptr [rax+168h], 0
jnz short loc_502A5
mov rax, [rbp+var_18]
mov byte ptr [rax+20h], 0
loc_502A5:
mov rax, [rbp+var_18]
cmp dword ptr [rax+168h], 20000000h
jl short loc_502C0
mov rax, [rbp+var_18]
mov byte ptr [rax+24Ch], 1
loc_502C0:
mov rax, [rbp+var_18]
pop rbp
retn
| CLI::Option * CLI::Option::type_size(CLI::Option *this, int a2, int a3)
{
int v3; // eax
int v4; // eax
int v6; // [rsp+8h] [rbp-10h]
int v7; // [rsp+Ch] [rbp-Ch]
v7 = a2;
v6 = a3;
if ( a2 < 0 || a3 < 0 )
{
*((_DWORD *)this + 93) = 0x20000000;
v3 = a2;
if ( a2 <= 0 )
v3 = -a2;
v7 = v3;
v4 = a3;
if ( a3 <= 0 )
v4 = -a3;
v6 = v4;
}
if ( v7 <= v6 )
{
*((_DWORD *)this + 91) = v7;
*((_DWORD *)this + 90) = v6;
}
else
{
*((_DWORD *)this + 90) = v7;
*((_DWORD *)this + 91) = v6;
}
if ( !*((_DWORD *)this + 90) )
*((_BYTE *)this + 32) = 0;
if ( *((int *)this + 90) >= 0x20000000 )
*((_BYTE *)this + 588) = 1;
return this;
}
| type_size:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV dword ptr [RBP + -0x10],EDX
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x18],RAX
CMP dword ptr [RBP + -0xc],0x0
JL 0x00150232
CMP dword ptr [RBP + -0x10],0x0
JGE 0x0015025a
LAB_00150232:
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX + 0x174],0x20000000
MOV EAX,dword ptr [RBP + -0xc]
MOV ECX,EAX
NEG ECX
CMOVNS EAX,ECX
MOV dword ptr [RBP + -0xc],EAX
MOV EAX,dword ptr [RBP + -0x10]
MOV ECX,EAX
NEG ECX
CMOVNS EAX,ECX
MOV dword ptr [RBP + -0x10],EAX
LAB_0015025a:
MOV EAX,dword ptr [RBP + -0xc]
CMP EAX,dword ptr [RBP + -0x10]
JLE 0x0015027a
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0xc]
MOV dword ptr [RAX + 0x168],ECX
MOV ECX,dword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x16c],ECX
JMP 0x00150290
LAB_0015027a:
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0xc]
MOV dword ptr [RAX + 0x16c],ECX
MOV ECX,dword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x168],ECX
LAB_00150290:
MOV RAX,qword ptr [RBP + -0x18]
CMP dword ptr [RAX + 0x168],0x0
JNZ 0x001502a5
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX + 0x20],0x0
LAB_001502a5:
MOV RAX,qword ptr [RBP + -0x18]
CMP dword ptr [RAX + 0x168],0x20000000
JL 0x001502c0
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX + 0x24c],0x1
LAB_001502c0:
MOV RAX,qword ptr [RBP + -0x18]
POP RBP
RET
|
/* CLI::Option::type_size(int, int) */
Option * __thiscall CLI::Option::type_size(Option *this,int param_1,int param_2)
{
int local_18;
int local_14;
local_14 = param_1;
if ((param_1 < 0) || (local_18 = param_2, param_2 < 0)) {
*(int4 *)(this + 0x174) = 0x20000000;
if (param_1 < 1) {
local_14 = -param_1;
}
local_18 = param_2;
if (param_2 < 1) {
local_18 = -param_2;
}
}
if (local_18 < local_14) {
*(int *)(this + 0x168) = local_14;
*(int *)(this + 0x16c) = local_18;
}
else {
*(int *)(this + 0x16c) = local_14;
*(int *)(this + 0x168) = local_18;
}
if (*(int *)(this + 0x168) == 0) {
this[0x20] = (Option)0x0;
}
if (0x1fffffff < *(int *)(this + 0x168)) {
this[0x24c] = (Option)0x1;
}
return this;
}
| |
55,569 | init_available_charsets | eloqsql/mysys/charset.c | static void init_available_charsets(void)
{
char fname[FN_REFLEN + sizeof(MY_CHARSET_INDEX)];
struct charset_info_st **cs;
MY_CHARSET_LOADER loader;
DBUG_ENTER("init_available_charsets");
bzero((char*) &all_charsets,sizeof(all_charsets));
bzero((char*) &my_collation_statistics, sizeof(my_collation_statistics));
my_hash_init2(key_memory_charsets, &charset_name_hash, 16,
&my_charset_latin1, 64, 0, 0, get_charset_key,
0, 0, HASH_UNIQUE);
init_compiled_charsets(MYF(0));
/* Copy compiled charsets */
for (cs= (struct charset_info_st**) all_charsets;
cs < (struct charset_info_st**) all_charsets +
array_elements(all_charsets)-1 ;
cs++)
{
if (*cs)
{
DBUG_ASSERT(cs[0]->mbmaxlen <= MY_CS_MBMAXLEN);
if (cs[0]->m_ctype)
if (init_state_maps(*cs))
*cs= NULL;
}
}
my_charset_loader_init_mysys(&loader);
strmov(get_charsets_dir(fname), MY_CHARSET_INDEX);
my_read_charset_file(&loader, fname, MYF(0));
DBUG_VOID_RETURN;
} | O0 | c | init_available_charsets:
pushq %rbp
movq %rsp, %rbp
subq $0x300, %rsp # imm = 0x300
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
leaq 0x36dfd1(%rip), %rdi # 0x398ad0
xorl %esi, %esi
movl $0x4000, %edx # imm = 0x4000
callq 0x251d0
leaq 0x37202e(%rip), %rdi # 0x39cb40
xorl %esi, %esi
movl $0x4000, %edx # imm = 0x4000
callq 0x251d0
leaq 0x376a67(%rip), %rax # 0x3a158c
movl (%rax), %edi
leaq 0x371fa2(%rip), %rsi # 0x39cad0
movl $0x10, %edx
leaq 0x25cfa6(%rip), %rcx # 0x287ae0
movl $0x40, %r8d
xorl %eax, %eax
movl %eax, %r9d
leaq 0x1ab4(%rip), %rax # 0x2c600
movq $0x0, (%rsp)
movq %rax, 0x8(%rsp)
movq $0x0, 0x10(%rsp)
movq $0x0, 0x18(%rsp)
movl $0x1, 0x20(%rsp)
callq 0x2cf70
xorl %eax, %eax
movl %eax, %edi
callq 0x3c0d0
leaq 0x36df48(%rip), %rax # 0x398ad0
movq %rax, -0x2d8(%rbp)
leaq 0x36df3a(%rip), %rax # 0x398ad0
addq $0x4000, %rax # imm = 0x4000
addq $-0x8, %rax
cmpq %rax, -0x2d8(%rbp)
jae 0x2ac06
movq -0x2d8(%rbp), %rax
cmpq $0x0, (%rax)
je 0x2abf0
jmp 0x2abb8
jmp 0x2abba
movq -0x2d8(%rbp), %rax
movq (%rax), %rax
cmpq $0x0, 0x40(%rax)
je 0x2abee
movq -0x2d8(%rbp), %rax
movq (%rax), %rdi
callq 0x2c160
cmpb $0x0, %al
je 0x2abec
movq -0x2d8(%rbp), %rax
movq $0x0, (%rax)
jmp 0x2abee
jmp 0x2abf0
jmp 0x2abf2
movq -0x2d8(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x2d8(%rbp)
jmp 0x2ab8f
leaq -0x2d0(%rbp), %rdi
callq 0x2a100
leaq -0x220(%rbp), %rdi
callq 0x2a7a0
movq %rax, %rdi
leaq 0x5e771(%rip), %rsi # 0x89399
callq 0x25320
leaq -0x220(%rbp), %rsi
leaq -0x2d0(%rbp), %rdi
xorl %eax, %eax
movl %eax, %edx
callq 0x2c640
jmp 0x2ac46
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x2ac61
addq $0x300, %rsp # imm = 0x300
popq %rbp
retq
callq 0x25380
nopw %cs:(%rax,%rax)
| init_available_charsets:
push rbp
mov rbp, rsp
sub rsp, 300h
mov rax, fs:28h
mov [rbp+var_8], rax
lea rdi, all_charsets
xor esi, esi
mov edx, 4000h
call _memset
lea rdi, my_collation_statistics
xor esi, esi
mov edx, 4000h
call _memset
lea rax, key_memory_charsets
mov edi, [rax]
lea rsi, charset_name_hash
mov edx, 10h
lea rcx, my_charset_latin1
mov r8d, 40h ; '@'
xor eax, eax
mov r9d, eax
lea rax, get_charset_key
mov [rsp+300h+var_300], 0
mov [rsp+300h+var_2F8], rax
mov [rsp+300h+var_2F0], 0
mov [rsp+300h+var_2E8], 0
mov [rsp+300h+var_2E0], 1
call my_hash_init2
xor eax, eax
mov edi, eax
call init_compiled_charsets
lea rax, all_charsets
mov [rbp+var_2D8], rax
loc_2AB8F:
lea rax, all_charsets
add rax, 4000h
add rax, 0FFFFFFFFFFFFFFF8h
cmp [rbp+var_2D8], rax
jnb short loc_2AC06
mov rax, [rbp+var_2D8]
cmp qword ptr [rax], 0
jz short loc_2ABF0
jmp short $+2
loc_2ABB8:
jmp short $+2
loc_2ABBA:
mov rax, [rbp+var_2D8]
mov rax, [rax]
cmp qword ptr [rax+40h], 0
jz short loc_2ABEE
mov rax, [rbp+var_2D8]
mov rdi, [rax]
call init_state_maps
cmp al, 0
jz short loc_2ABEC
mov rax, [rbp+var_2D8]
mov qword ptr [rax], 0
loc_2ABEC:
jmp short $+2
loc_2ABEE:
jmp short $+2
loc_2ABF0:
jmp short $+2
loc_2ABF2:
mov rax, [rbp+var_2D8]
add rax, 8
mov [rbp+var_2D8], rax
jmp short loc_2AB8F
loc_2AC06:
lea rdi, [rbp+var_2D0]
call my_charset_loader_init_mysys
lea rdi, [rbp+var_220]
call get_charsets_dir
mov rdi, rax
lea rsi, aIndexXml; "Index.xml"
call _stpcpy
lea rsi, [rbp+var_220]
lea rdi, [rbp+var_2D0]
xor eax, eax
mov edx, eax
call my_read_charset_file
jmp short $+2
loc_2AC46:
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_2AC61
add rsp, 300h
pop rbp
retn
loc_2AC61:
call ___stack_chk_fail
| unsigned long long init_available_charsets()
{
long long charsets_dir; // rax
_QWORD *i; // [rsp+28h] [rbp-2D8h]
_BYTE v3[176]; // [rsp+30h] [rbp-2D0h] BYREF
_BYTE v4[536]; // [rsp+E0h] [rbp-220h] BYREF
unsigned long long v5; // [rsp+2F8h] [rbp-8h]
v5 = __readfsqword(0x28u);
memset(all_charsets, 0LL, sizeof(all_charsets));
memset(my_collation_statistics, 0LL, sizeof(my_collation_statistics));
my_hash_init2(
key_memory_charsets,
(unsigned int)&charset_name_hash,
16,
(unsigned int)&my_charset_latin1,
64,
0,
0LL,
(long long)get_charset_key,
0LL,
0LL,
1);
init_compiled_charsets(0LL);
for ( i = all_charsets; i < &all_charsets[2047]; ++i )
{
if ( *i && *(_QWORD *)(*i + 64LL) )
{
if ( (unsigned __int8)init_state_maps(*i) )
*i = 0LL;
}
}
my_charset_loader_init_mysys((long long)v3);
charsets_dir = get_charsets_dir((long long)v4);
stpcpy(charsets_dir, "Index.xml");
my_read_charset_file(v3, v4, 0LL);
return __readfsqword(0x28u);
}
| init_available_charsets:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x300
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
LEA RDI,[0x498ad0]
XOR ESI,ESI
MOV EDX,0x4000
CALL 0x001251d0
LEA RDI,[0x49cb40]
XOR ESI,ESI
MOV EDX,0x4000
CALL 0x001251d0
LEA RAX,[0x4a158c]
MOV EDI,dword ptr [RAX]
LEA RSI,[0x49cad0]
MOV EDX,0x10
LEA RCX,[0x387ae0]
MOV R8D,0x40
XOR EAX,EAX
MOV R9D,EAX
LEA RAX,[0x12c600]
MOV qword ptr [RSP],0x0
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x10],0x0
MOV qword ptr [RSP + 0x18],0x0
MOV dword ptr [RSP + 0x20],0x1
CALL 0x0012cf70
XOR EAX,EAX
MOV EDI,EAX
CALL 0x0013c0d0
LEA RAX,[0x498ad0]
MOV qword ptr [RBP + -0x2d8],RAX
LAB_0012ab8f:
LEA RAX,[0x498ad0]
ADD RAX,0x4000
ADD RAX,-0x8
CMP qword ptr [RBP + -0x2d8],RAX
JNC 0x0012ac06
MOV RAX,qword ptr [RBP + -0x2d8]
CMP qword ptr [RAX],0x0
JZ 0x0012abf0
JMP 0x0012abb8
LAB_0012abb8:
JMP 0x0012abba
LAB_0012abba:
MOV RAX,qword ptr [RBP + -0x2d8]
MOV RAX,qword ptr [RAX]
CMP qword ptr [RAX + 0x40],0x0
JZ 0x0012abee
MOV RAX,qword ptr [RBP + -0x2d8]
MOV RDI,qword ptr [RAX]
CALL 0x0012c160
CMP AL,0x0
JZ 0x0012abec
MOV RAX,qword ptr [RBP + -0x2d8]
MOV qword ptr [RAX],0x0
LAB_0012abec:
JMP 0x0012abee
LAB_0012abee:
JMP 0x0012abf0
LAB_0012abf0:
JMP 0x0012abf2
LAB_0012abf2:
MOV RAX,qword ptr [RBP + -0x2d8]
ADD RAX,0x8
MOV qword ptr [RBP + -0x2d8],RAX
JMP 0x0012ab8f
LAB_0012ac06:
LEA RDI,[RBP + -0x2d0]
CALL 0x0012a100
LEA RDI,[RBP + -0x220]
CALL 0x0012a7a0
MOV RDI,RAX
LEA RSI,[0x189399]
CALL 0x00125320
LEA RSI,[RBP + -0x220]
LEA RDI,[RBP + -0x2d0]
XOR EAX,EAX
MOV EDX,EAX
CALL 0x0012c640
JMP 0x0012ac46
LAB_0012ac46:
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x0012ac61
ADD RSP,0x300
POP RBP
RET
LAB_0012ac61:
CALL 0x00125380
|
void init_available_charsets(void)
{
char cVar1;
char *__dest;
long in_FS_OFFSET;
long *local_2e0;
int1 local_2d8 [176];
int1 local_228 [536];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
memset(&all_charsets,0,0x4000);
memset(my_collation_statistics,0,0x4000);
my_hash_init2(key_memory_charsets,charset_name_hash,0x10,&my_charset_latin1,0x40,0,0,
get_charset_key,0,0,1);
init_compiled_charsets(0);
for (local_2e0 = &all_charsets; local_2e0 < (long *)0x49cac8; local_2e0 = local_2e0 + 1) {
if (((*local_2e0 != 0) && (*(long *)(*local_2e0 + 0x40) != 0)) &&
(cVar1 = init_state_maps(*local_2e0), cVar1 != '\0')) {
*local_2e0 = 0;
}
}
my_charset_loader_init_mysys(local_2d8);
__dest = (char *)get_charsets_dir(local_228);
stpcpy(__dest,"Index.xml");
my_read_charset_file(local_2d8,local_228,0);
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return;
}
| |
55,570 | init_available_charsets | eloqsql/mysys/charset.c | static void init_available_charsets(void)
{
char fname[FN_REFLEN + sizeof(MY_CHARSET_INDEX)];
struct charset_info_st **cs;
MY_CHARSET_LOADER loader;
DBUG_ENTER("init_available_charsets");
bzero((char*) &all_charsets,sizeof(all_charsets));
bzero((char*) &my_collation_statistics, sizeof(my_collation_statistics));
my_hash_init2(key_memory_charsets, &charset_name_hash, 16,
&my_charset_latin1, 64, 0, 0, get_charset_key,
0, 0, HASH_UNIQUE);
init_compiled_charsets(MYF(0));
/* Copy compiled charsets */
for (cs= (struct charset_info_st**) all_charsets;
cs < (struct charset_info_st**) all_charsets +
array_elements(all_charsets)-1 ;
cs++)
{
if (*cs)
{
DBUG_ASSERT(cs[0]->mbmaxlen <= MY_CS_MBMAXLEN);
if (cs[0]->m_ctype)
if (init_state_maps(*cs))
*cs= NULL;
}
}
my_charset_loader_init_mysys(&loader);
strmov(get_charsets_dir(fname), MY_CHARSET_INDEX);
my_read_charset_file(&loader, fname, MYF(0));
DBUG_VOID_RETURN;
} | O3 | c | init_available_charsets:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x300, %rsp # imm = 0x300
movq %fs:0x28, %rax
movq %rax, -0x18(%rbp)
leaq 0x3488e3(%rip), %rbx # 0x370f20
movl $0x4000, %edx # imm = 0x4000
movq %rbx, %rdi
xorl %esi, %esi
callq 0x241e0
leaq 0x34c93d(%rip), %rdi # 0x374f90
movl $0x4000, %edx # imm = 0x4000
xorl %esi, %esi
callq 0x241e0
leaq 0x351376(%rip), %rax # 0x3799dc
movl (%rax), %edi
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rsp)
leaq 0x10fc(%rip), %rax # 0x29773
movq %rax, 0x8(%rsp)
movl $0x1, 0x20(%rsp)
movq $0x0, (%rsp)
leaq 0x34c88d(%rip), %rsi # 0x374f20
leaq 0x2f8406(%rip), %rcx # 0x320aa0
movl $0x40, %r8d
movl $0x10, %edx
xorl %r9d, %r9d
callq 0x29a45
xorl %edi, %edi
callq 0x32fb8
movq $-0x8, %r14
movq 0x8(%rbx,%r14), %rdi
testq %rdi, %rdi
je 0x286de
cmpq $0x0, 0x40(%rdi)
je 0x286de
callq 0x295be
testb %al, %al
je 0x286de
movq $0x0, 0x8(%rbx,%r14)
addq $0x8, %r14
cmpq $0x3ff0, %r14 # imm = 0x3FF0
jb 0x286bb
leaq -0x2e0(%rbp), %rbx
movb $0x0, (%rbx)
leaq -0x8ae(%rip), %rax # 0x27e4e
movq %rax, 0x80(%rbx)
leaq -0x8ad(%rip), %rax # 0x27e5d
movq %rax, 0x88(%rbx)
leaq -0x8a0(%rip), %rax # 0x27e78
movq %rax, 0x90(%rbx)
leaq 0x7be0(%rip), %rax # 0x30306
movq %rax, 0x98(%rbx)
leaq 0x2d1ba4(%rip), %rax # 0x2fa2d8
movq (%rax), %rax
movq %rax, 0xa0(%rbx)
leaq -0x8af(%rip), %rax # 0x27e96
movq %rax, 0xa8(%rbx)
leaq -0x230(%rbp), %r14
movq %r14, %rdi
callq 0x283db
movabsq $0x6d782e7865646e49, %rcx # imm = 0x6D782E7865646E49
movq %rcx, (%rax)
movw $0x6c, 0x8(%rax)
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x29784
movq %fs:0x28, %rax
cmpq -0x18(%rbp), %rax
jne 0x28796
addq $0x300, %rsp # imm = 0x300
popq %rbx
popq %r14
popq %rbp
retq
callq 0x243e0
| init_available_charsets:
push rbp
mov rbp, rsp
push r14
push rbx
sub rsp, 300h
mov rax, fs:28h
mov [rbp+var_18], rax
lea rbx, all_charsets
mov edx, 4000h
mov rdi, rbx
xor esi, esi
call _memset
lea rdi, my_collation_statistics
mov edx, 4000h
xor esi, esi
call _memset
lea rax, key_memory_charsets
mov edi, [rax]
xorps xmm0, xmm0
movups [rsp+310h+var_300], xmm0
lea rax, get_charset_key
mov [rsp+310h+var_308], rax
mov [rsp+310h+var_2F0], 1
mov [rsp+310h+var_310], 0
lea rsi, charset_name_hash
lea rcx, my_charset_latin1
mov r8d, 40h ; '@'
mov edx, 10h
xor r9d, r9d
call my_hash_init2
xor edi, edi
call init_compiled_charsets
mov r14, 0FFFFFFFFFFFFFFF8h
loc_286BB:
mov rdi, [rbx+r14+8]
test rdi, rdi
jz short loc_286DE
cmp qword ptr [rdi+40h], 0
jz short loc_286DE
call init_state_maps
test al, al
jz short loc_286DE
mov qword ptr [rbx+r14+8], 0
loc_286DE:
add r14, 8
cmp r14, 3FF0h
jb short loc_286BB
lea rbx, [rbp+var_2E0]
mov byte ptr [rbx], 0
lea rax, my_once_alloc_c
mov [rbx+80h], rax
lea rax, my_malloc_c
mov [rbx+88h], rax
lea rax, my_realloc_c
mov [rbx+90h], rax
lea rax, my_free
mov [rbx+98h], rax
lea rax, my_charset_error_reporter
mov rax, [rax]
mov [rbx+0A0h], rax
lea rax, add_collation
mov [rbx+0A8h], rax
lea r14, [rbp+var_230]
mov rdi, r14
call get_charsets_dir
mov rcx, 6D782E7865646E49h
mov [rax], rcx
mov word ptr [rax+8], 6Ch ; 'l'
mov rdi, rbx
mov rsi, r14
xor edx, edx
call my_read_charset_file
mov rax, fs:28h
cmp rax, [rbp+var_18]
jnz short loc_28796
add rsp, 300h
pop rbx
pop r14
pop rbp
retn
loc_28796:
call ___stack_chk_fail
| unsigned long long init_available_charsets()
{
unsigned long long v0; // r14
long long v1; // rdi
_BYTE v3[128]; // [rsp+30h] [rbp-2E0h] BYREF
long long ( *v4)(long long); // [rsp+B0h] [rbp-260h]
long long ( *v5)(long long); // [rsp+B8h] [rbp-258h]
long long ( *v6)(long long, long long); // [rsp+C0h] [rbp-250h]
long long ( *v7)(_QWORD); // [rsp+C8h] [rbp-248h]
long long ( *v8)(); // [rsp+D0h] [rbp-240h]
long long ( *v9)(unsigned int *); // [rsp+D8h] [rbp-238h]
_BYTE v10[536]; // [rsp+E0h] [rbp-230h] BYREF
unsigned long long v11; // [rsp+2F8h] [rbp-18h]
v11 = __readfsqword(0x28u);
memset(all_charsets, 0LL, sizeof(all_charsets));
memset(my_collation_statistics, 0LL, sizeof(my_collation_statistics));
my_hash_init2(
key_memory_charsets,
(unsigned int)&charset_name_hash,
16,
(unsigned int)&my_charset_latin1,
64,
0,
0LL,
(long long)get_charset_key,
0LL,
0LL,
1);
init_compiled_charsets(0LL);
v0 = 0x1FFFFFFFFFFFFFFFLL;
do
{
v1 = all_charsets[v0 + 1];
if ( v1 && *(_QWORD *)(v1 + 64) && (unsigned __int8)init_state_maps(v1) )
all_charsets[v0 + 1] = 0LL;
++v0;
}
while ( v0 < 2046 );
v3[0] = 0;
v4 = my_once_alloc_c;
v5 = my_malloc_c;
v6 = my_realloc_c;
v7 = my_free;
v8 = my_charset_error_reporter;
v9 = add_collation;
strcpy((char *)get_charsets_dir((long long)v10), "Index.xml");
my_read_charset_file(v3, v10, 0LL);
return __readfsqword(0x28u);
}
| init_available_charsets:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
SUB RSP,0x300
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
LEA RBX,[0x470f20]
MOV EDX,0x4000
MOV RDI,RBX
XOR ESI,ESI
CALL 0x001241e0
LEA RDI,[0x474f90]
MOV EDX,0x4000
XOR ESI,ESI
CALL 0x001241e0
LEA RAX,[0x4799dc]
MOV EDI,dword ptr [RAX]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RSP + 0x10],XMM0
LEA RAX,[0x129773]
MOV qword ptr [RSP + 0x8],RAX
MOV dword ptr [RSP + 0x20],0x1
MOV qword ptr [RSP],0x0
LEA RSI,[0x474f20]
LEA RCX,[0x420aa0]
MOV R8D,0x40
MOV EDX,0x10
XOR R9D,R9D
CALL 0x00129a45
XOR EDI,EDI
CALL 0x00132fb8
MOV R14,-0x8
LAB_001286bb:
MOV RDI,qword ptr [RBX + R14*0x1 + 0x8]
TEST RDI,RDI
JZ 0x001286de
CMP qword ptr [RDI + 0x40],0x0
JZ 0x001286de
CALL 0x001295be
TEST AL,AL
JZ 0x001286de
MOV qword ptr [RBX + R14*0x1 + 0x8],0x0
LAB_001286de:
ADD R14,0x8
CMP R14,0x3ff0
JC 0x001286bb
LEA RBX,[RBP + -0x2e0]
MOV byte ptr [RBX],0x0
LEA RAX,[0x127e4e]
MOV qword ptr [RBX + 0x80],RAX
LEA RAX,[0x127e5d]
MOV qword ptr [RBX + 0x88],RAX
LEA RAX,[0x127e78]
MOV qword ptr [RBX + 0x90],RAX
LEA RAX,[0x130306]
MOV qword ptr [RBX + 0x98],RAX
LEA RAX,[0x3fa2d8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBX + 0xa0],RAX
LEA RAX,[0x127e96]
MOV qword ptr [RBX + 0xa8],RAX
LEA R14,[RBP + -0x230]
MOV RDI,R14
CALL 0x001283db
MOV RCX,0x6d782e7865646e49
MOV qword ptr [RAX],RCX
MOV word ptr [RAX + 0x8],0x6c
MOV RDI,RBX
MOV RSI,R14
XOR EDX,EDX
CALL 0x00129784
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x18]
JNZ 0x00128796
ADD RSP,0x300
POP RBX
POP R14
POP RBP
RET
LAB_00128796:
CALL 0x001243e0
|
void init_available_charsets(void)
{
char cVar1;
int8 *puVar2;
ulong uVar3;
long in_FS_OFFSET;
int1 local_2e8 [128];
code *local_268;
code *local_260;
code *local_258;
code *local_250;
int *local_248;
code *local_240;
int1 local_238 [536];
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
memset(&all_charsets,0,0x4000);
memset(my_collation_statistics,0,0x4000);
my_hash_init2(key_memory_charsets,charset_name_hash,0x10,&my_charset_latin1,0x40,0,0,
get_charset_key,0,0,1);
init_compiled_charsets(0);
uVar3 = 0xfffffffffffffff8;
do {
if ((*(long *)((long)&DAT_00470f28 + uVar3) != 0) &&
(*(long *)(*(long *)((long)&DAT_00470f28 + uVar3) + 0x40) != 0)) {
cVar1 = init_state_maps();
if (cVar1 != '\0') {
*(int8 *)((long)&DAT_00470f28 + uVar3) = 0;
}
}
uVar3 = uVar3 + 8;
} while (uVar3 < 0x3ff0);
local_2e8[0] = 0;
local_268 = my_once_alloc_c;
local_260 = my_malloc_c;
local_258 = my_realloc_c;
local_250 = my_free;
local_248 = my_charset_error_reporter;
local_240 = add_collation;
puVar2 = (int8 *)get_charsets_dir(local_238);
*puVar2 = 0x6d782e7865646e49;
*(int2 *)(puVar2 + 1) = 0x6c;
my_read_charset_file(local_2e8,local_238,0);
if (*(long *)(in_FS_OFFSET + 0x28) == local_20) {
return;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
55,571 | IsLocaleValid(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | SylCore-WoTLK/src/common/Common.cpp | bool IsLocaleValid(std::string const& locale)
{
for (int i = 0; i < TOTAL_LOCALES; ++i)
if (locale == localeNames[i])
return true;
return false;
} | O0 | cpp | IsLocaleValid(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
subq $0x18, %rsp
movq %rdi, 0x8(%rsp)
movl $0x0, 0x4(%rsp)
cmpl $0x9, 0x4(%rsp)
jge 0x1835ee
movq 0x8(%rsp), %rdi
movslq 0x4(%rsp), %rcx
leaq 0x251dd7(%rip), %rax # 0x3d53a0
movq (%rax,%rcx,8), %rsi
callq 0x83990
testb $0x1, %al
jne 0x1835d8
jmp 0x1835df
movb $0x1, 0x17(%rsp)
jmp 0x1835f3
jmp 0x1835e1
movl 0x4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4(%rsp)
jmp 0x1835b1
movb $0x0, 0x17(%rsp)
movb 0x17(%rsp), %al
andb $0x1, %al
addq $0x18, %rsp
retq
nop
| _Z13IsLocaleValidRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
sub rsp, 18h
mov [rsp+18h+var_10], rdi
mov [rsp+18h+var_14], 0
loc_1835B1:
cmp [rsp+18h+var_14], 9
jge short loc_1835EE
mov rdi, [rsp+18h+var_10]
movsxd rcx, [rsp+18h+var_14]
lea rax, localeNames
mov rsi, [rax+rcx*8]
call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*)
test al, 1
jnz short loc_1835D8
jmp short loc_1835DF
loc_1835D8:
mov [rsp+18h+var_1], 1
jmp short loc_1835F3
loc_1835DF:
jmp short $+2
loc_1835E1:
mov eax, [rsp+18h+var_14]
add eax, 1
mov [rsp+18h+var_14], eax
jmp short loc_1835B1
loc_1835EE:
mov [rsp+18h+var_1], 0
loc_1835F3:
mov al, [rsp+18h+var_1]
and al, 1
add rsp, 18h
retn
| char IsLocaleValid(long long a1)
{
int i; // [rsp+4h] [rbp-14h]
for ( i = 0; i < 9; ++i )
{
if ( (std::operator==<char>(a1, (long long)localeNames[i]) & 1) != 0 )
return 1;
}
return 0;
}
| MessageBuffer:
SUB RSP,0x28
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x18],RSI
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RAX],0x0
MOV qword ptr [RAX + 0x8],0x0
MOV RDI,RAX
ADD RDI,0x10
MOV qword ptr [RSP],RDI
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RAX + 0x10],XMM0
MOV qword ptr [RAX + 0x20],0x0
CALL 0x00185600
MOV RDI,qword ptr [RSP]
MOV RSI,qword ptr [RSP + 0x18]
LAB_001835ea:
CALL 0x00152b70
LAB_001835ef:
JMP 0x001835f1
LAB_001835f1:
ADD RSP,0x28
RET
|
/* MessageBuffer::MessageBuffer(unsigned long) */
void __thiscall MessageBuffer::MessageBuffer(MessageBuffer *this,ulong param_1)
{
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)(this + 0x20) = 0;
std::vector<unsigned_char,std::allocator<unsigned_char>>::vector
((vector<unsigned_char,std::allocator<unsigned_char>> *)(this + 0x10));
/* try { // try from 001835ea to 001835ee has its CatchHandler @ 001835f6 */
std::vector<unsigned_char,std::allocator<unsigned_char>>::resize
((vector<unsigned_char,std::allocator<unsigned_char>> *)(this + 0x10),param_1);
return;
}
| |
55,572 | std::pair<bool, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>*> nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::handle_value<std::nullptr_t>(std::nullptr_t&&, bool) | monkey531[P]llama/common/json.hpp | std::pair<bool, BasicJsonType*> handle_value(Value&& v, const bool skip_callback = false)
{
JSON_ASSERT(!keep_stack.empty());
// do not handle this value if we know it would be added to a discarded
// container
if (!keep_stack.back())
{
return {false, nullptr};
}
// create value
auto value = BasicJsonType(std::forward<Value>(v));
// check callback
const bool keep = skip_callback || callback(static_cast<int>(ref_stack.size()), parse_event_t::value, value);
// do not handle this value if we just learnt it shall be discarded
if (!keep)
{
return {false, nullptr};
}
if (ref_stack.empty())
{
root = std::move(value);
return {true, & root};
}
// skip this value if we already decided to skip the parent
// (https://github.com/nlohmann/json/issues/971#issuecomment-413678360)
if (!ref_stack.back())
{
return {false, nullptr};
}
// we now only expect arrays and objects
JSON_ASSERT(ref_stack.back()->is_array() || ref_stack.back()->is_object());
// array
if (ref_stack.back()->is_array())
{
ref_stack.back()->m_data.m_value.array->emplace_back(std::move(value));
return {true, & (ref_stack.back()->m_data.m_value.array->back())};
}
// object
JSON_ASSERT(ref_stack.back()->is_object());
// check if we should store an element for the current key
JSON_ASSERT(!key_keep_stack.empty());
const bool store_element = key_keep_stack.back();
key_keep_stack.pop_back();
if (!store_element)
{
return {false, nullptr};
}
JSON_ASSERT(object_element);
*object_element = std::move(value);
return {true, object_element};
} | O3 | cpp | std::pair<bool, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>*> nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::handle_value<std::nullptr_t>(std::nullptr_t&&, bool):
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movl %edx, %ebp
movq 0x30(%rdi), %rax
movl 0x38(%rdi), %ecx
cmpq %rax, 0x20(%rdi)
sete %dl
testl %ecx, %ecx
sete %sil
andb %dl, %sil
cmpb $0x1, %sil
je 0x603ef
movl %ecx, %ecx
movabsq $-0x8000000000000000, %r15 # imm = 0x8000000000000000
leaq -0x1(%rcx), %rdx
addq $0x3e, %rcx
testq %rdx, %rdx
cmovnsq %rdx, %rcx
sarq $0x6, %rcx
leaq (%rax,%rcx,8), %rax
leaq 0x3f(%r15), %rcx
andq %rdx, %rcx
xorl %esi, %esi
cmpq %r15, %rcx
setbe %sil
movq -0x8(%rax,%rsi,8), %rax
btq %rdx, %rax
jae 0x60282
movq %rdi, %rbx
leaq 0x10(%rsp), %r14
movb $0x0, (%r14)
movq $0x0, 0x8(%r14)
movq %r14, %rdi
movl $0x1, %esi
callq 0x58aa4
movq %r14, %rdi
movl $0x1, %esi
callq 0x58aa4
testb %bpl, %bpl
jne 0x6022f
movq 0x10(%rbx), %rax
subq 0x8(%rbx), %rax
shrq $0x3, %rax
movl %eax, 0xc(%rsp)
movb $0x5, 0xb(%rsp)
cmpq $0x0, 0x90(%rbx)
je 0x60410
leaq 0x80(%rbx), %rdi
leaq 0xc(%rsp), %rsi
leaq 0xb(%rsp), %rdx
leaq 0x10(%rsp), %rcx
callq *0x98(%rbx)
testb %al, %al
je 0x603c3
movq 0x10(%rbx), %rax
cmpq %rax, 0x8(%rbx)
je 0x6028c
movq -0x8(%rax), %rax
testq %rax, %rax
je 0x603c3
movzbl (%rax), %ecx
cmpl $0x1, %ecx
je 0x602e6
cmpl $0x2, %ecx
jne 0x60415
movq 0x8(%rax), %rdi
leaq 0x10(%rsp), %rsi
callq 0x5d666
movq 0x10(%rbx), %rax
movq -0x8(%rax), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %r14
addq $-0x10, %r14
jmp 0x603bf
xorl %ebx, %ebx
xorl %r14d, %r14d
jmp 0x603df
leaq 0x10(%rsp), %r14
movups (%r14), %xmm0
leaq 0x30(%rsp), %r15
movaps %xmm0, (%r15)
movq %r14, %rdi
xorl %esi, %esi
callq 0x58aa4
movb $0x0, (%r14)
movq $0x0, 0x8(%r14)
movq %r15, %rdi
movl $0x1, %esi
callq 0x58aa4
movq (%rbx), %rdi
movq %r15, %rsi
callq 0x5b246
movq %r15, %rdi
xorl %esi, %esi
callq 0x58aa4
movq %r15, %rdi
callq 0x5df92
movq (%rbx), %r14
jmp 0x603bf
movq 0x58(%rbx), %rax
movl 0x60(%rbx), %ecx
cmpq %rax, 0x48(%rbx)
sete %dl
testl %ecx, %ecx
sete %sil
andb %dl, %sil
cmpb $0x1, %sil
je 0x60423
movl %ecx, %esi
leaq -0x1(%rsi), %rcx
movq %rsi, %rdx
addq $0x3e, %rdx
testq %rcx, %rcx
cmovnsq %rcx, %rdx
sarq $0x6, %rdx
leaq (%rax,%rdx,8), %rdi
leaq 0x3f(%r15), %rdx
andq %rcx, %rdx
xorl %r8d, %r8d
cmpq %r15, %rdx
setbe %r8b
movl $0x1, %edx
shlq %cl, %rdx
andq -0x8(%rdi,%r8,8), %rdx
subl $0x1, %esi
movl %esi, 0x60(%rbx)
jae 0x60358
movl $0x3f, 0x60(%rbx)
addq $-0x8, %rax
movq %rax, 0x58(%rbx)
testq %rdx, %rdx
je 0x603c3
cmpq $0x0, 0x70(%rbx)
je 0x60444
leaq 0x10(%rsp), %r14
movups (%r14), %xmm0
leaq 0x20(%rsp), %r15
movaps %xmm0, (%r15)
movq %r14, %rdi
xorl %esi, %esi
callq 0x58aa4
movb $0x0, (%r14)
movq $0x0, 0x8(%r14)
movq %r15, %rdi
movl $0x1, %esi
callq 0x58aa4
movq 0x70(%rbx), %rdi
movq %r15, %rsi
callq 0x5b246
movq %r15, %rdi
xorl %esi, %esi
callq 0x58aa4
movq %r15, %rdi
callq 0x5df92
movq 0x70(%rbx), %r14
movb $0x1, %bl
jmp 0x603c8
xorl %ebx, %ebx
xorl %r14d, %r14d
leaq 0x10(%rsp), %r15
movq %r15, %rdi
xorl %esi, %esi
callq 0x58aa4
movq %r15, %rdi
callq 0x5df92
movl %ebx, %eax
movq %r14, %rdx
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x8c153(%rip), %rdi # 0xec549
leaq 0x8c196(%rip), %rdx # 0xec593
leaq 0x8d0c1(%rip), %rcx # 0xed4c5
movl $0x1c28, %esi # imm = 0x1C28
xorl %eax, %eax
callq 0x1aeb0
callq 0x1a320
leaq 0x8d0bd(%rip), %rcx # 0xed4d9
movl $0x1c4b, %esi # imm = 0x1C4B
jmp 0x6042f
leaq 0x8d0ed(%rip), %rcx # 0xed517
movl $0x1c57, %esi # imm = 0x1C57
leaq 0x8c113(%rip), %rdi # 0xec549
leaq 0x8c156(%rip), %rdx # 0xec593
xorl %eax, %eax
callq 0x1aeb0
leaq 0x8c0fe(%rip), %rdi # 0xec549
leaq 0x8c141(%rip), %rdx # 0xec593
leaq 0x8d0d6(%rip), %rcx # 0xed52f
movl $0x1c60, %esi # imm = 0x1C60
xorl %eax, %eax
callq 0x1aeb0
jmp 0x60467
movq %rax, %rbx
leaq 0x10(%rsp), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x58aa4
movq %r14, %rdi
callq 0x5df92
movq %rbx, %rdi
callq 0x1afb0
nop
| _ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12handle_valueIDnEESt4pairIbPSF_EOT_b:
push rbp
push r15
push r14
push rbx
sub rsp, 48h
mov ebp, edx
mov rax, [rdi+30h]
mov ecx, [rdi+38h]
cmp [rdi+20h], rax
setz dl
test ecx, ecx
setz sil
and sil, dl
cmp sil, 1
jz loc_603EF
mov ecx, ecx
mov r15, 8000000000000000h
lea rdx, [rcx-1]
add rcx, 3Eh ; '>'
test rdx, rdx
cmovns rcx, rdx
sar rcx, 6
lea rax, [rax+rcx*8]
lea rcx, [r15+3Fh]
and rcx, rdx
xor esi, esi
cmp rcx, r15
setbe sil
mov rax, [rax+rsi*8-8]
bt rax, rdx
jnb loc_60282
mov rbx, rdi
lea r14, [rsp+68h+var_58]
mov byte ptr [r14], 0
mov qword ptr [r14+8], 0
mov rdi, r14
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
test bpl, bpl
jnz short loc_6022F
mov rax, [rbx+10h]
sub rax, [rbx+8]
shr rax, 3
mov [rsp+68h+var_5C], eax
mov [rsp+68h+var_5D], 5
cmp qword ptr [rbx+90h], 0
jz loc_60410
lea rdi, [rbx+80h]
lea rsi, [rsp+68h+var_5C]
lea rdx, [rsp+68h+var_5D]
lea rcx, [rsp+68h+var_58]
call qword ptr [rbx+98h]
test al, al
jz loc_603C3
loc_6022F:
mov rax, [rbx+10h]
cmp [rbx+8], rax
jz short loc_6028C
mov rax, [rax-8]
test rax, rax
jz loc_603C3
movzx ecx, byte ptr [rax]
cmp ecx, 1
jz loc_602E6
cmp ecx, 2
jnz loc_60415
mov rdi, [rax+8]
lea rsi, [rsp+68h+var_58]
call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EE12emplace_backIJSD_EEERSD_DpOT_; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &&)
mov rax, [rbx+10h]
mov rax, [rax-8]
mov rax, [rax+8]
mov r14, [rax+8]
add r14, 0FFFFFFFFFFFFFFF0h
jmp loc_603BF
loc_60282:
xor ebx, ebx
xor r14d, r14d
jmp loc_603DF
loc_6028C:
lea r14, [rsp+68h+var_58]
movups xmm0, xmmword ptr [r14]
lea r15, [rsp+68h+var_38]
movaps xmmword ptr [r15], xmm0
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov byte ptr [r14], 0
mov qword ptr [r14+8], 0
mov rdi, r15
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, [rbx]
mov rsi, r15
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::operator=(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>)
mov rdi, r15
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r15
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov r14, [rbx]
jmp loc_603BF
loc_602E6:
mov rax, [rbx+58h]
mov ecx, [rbx+60h]
cmp [rbx+48h], rax
setz dl
test ecx, ecx
setz sil
and sil, dl
cmp sil, 1
jz loc_60423
mov esi, ecx
lea rcx, [rsi-1]
mov rdx, rsi
add rdx, 3Eh ; '>'
test rcx, rcx
cmovns rdx, rcx
sar rdx, 6
lea rdi, [rax+rdx*8]
lea rdx, [r15+3Fh]
and rdx, rcx
xor r8d, r8d
cmp rdx, r15
setbe r8b
mov edx, 1
shl rdx, cl
and rdx, [rdi+r8*8-8]
sub esi, 1
mov [rbx+60h], esi
jnb short loc_60358
mov dword ptr [rbx+60h], 3Fh ; '?'
add rax, 0FFFFFFFFFFFFFFF8h
mov [rbx+58h], rax
loc_60358:
test rdx, rdx
jz short loc_603C3
cmp qword ptr [rbx+70h], 0
jz loc_60444
lea r14, [rsp+68h+var_58]
movups xmm0, xmmword ptr [r14]
lea r15, [rsp+68h+var_48]
movaps xmmword ptr [r15], xmm0
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov byte ptr [r14], 0
mov qword ptr [r14+8], 0
mov rdi, r15
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, [rbx+70h]
mov rsi, r15
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::operator=(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>)
mov rdi, r15
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r15
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov r14, [rbx+70h]
loc_603BF:
mov bl, 1
jmp short loc_603C8
loc_603C3:
xor ebx, ebx
xor r14d, r14d
loc_603C8:
lea r15, [rsp+68h+var_58]
mov rdi, r15
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r15
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
loc_603DF:
mov eax, ebx
mov rdx, r14
add rsp, 48h
pop rbx
pop r14
pop r15
pop rbp
retn
loc_603EF:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aKeepStackEmpty; "!keep_stack.empty()"
mov esi, 1C28h
xor eax, eax
call _ggml_abort
loc_60410:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
loc_60415:
lea rcx, aRefStackBackIs; "ref_stack.back()->is_array() || ref_sta"...
mov esi, 1C4Bh
jmp short loc_6042F
loc_60423:
lea rcx, aKeyKeepStackEm; "!key_keep_stack.empty()"
mov esi, 1C57h
loc_6042F:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
xor eax, eax
call _ggml_abort
loc_60444:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aObjectElement; "object_element"
mov esi, 1C60h
xor eax, eax
call _ggml_abort
jmp short $+2
loc_60467:
mov rbx, rax
lea r14, [rsp+68h+var_58]
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rdi, rbx
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::handle_value<decltype(nullptr)>(
long long a1,
long long a2,
char a3)
{
long long v4; // rax
unsigned int v5; // ecx
signed long long v6; // rdx
long long v7; // rcx
long long v8; // rax
unsigned int v9; // ebx
long long v10; // rax
unsigned __int8 *v11; // rax
int v12; // ecx
long long v13; // rax
unsigned int v14; // ecx
long long v15; // rsi
long long v16; // rcx
long long v17; // rdx
long long v18; // rdx
const char *v20; // rcx
long long v21; // rsi
long long v22; // rbx
char v23; // [rsp+Bh] [rbp-5Dh] BYREF
int v24; // [rsp+Ch] [rbp-5Ch] BYREF
__int128 v25; // [rsp+10h] [rbp-58h] BYREF
__int128 v26; // [rsp+20h] [rbp-48h] BYREF
_OWORD v27[3]; // [rsp+30h] [rbp-38h] BYREF
v4 = *(_QWORD *)(a1 + 48);
v5 = *(_DWORD *)(a1 + 56);
if ( *(_QWORD *)(a1 + 32) == v4 && v5 == 0 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
7208LL,
"GGML_ASSERT(%s) failed",
"!keep_stack.empty()");
goto LABEL_28;
}
v6 = v5 - 1LL;
v7 = v5 + 62LL;
if ( v6 >= 0 )
v7 = v6;
v8 = *(_QWORD *)(v4 + 8 * (v7 >> 6) + 8LL * ((v6 & 0x800000000000003FLL) <= 0x8000000000000000LL) - 8);
if ( _bittest64(&v8, v6) )
{
v9 = a1;
LOBYTE(v25) = 0;
*((_QWORD *)&v25 + 1) = 0LL;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)&v25);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)&v25);
if ( a3 )
{
LABEL_8:
v10 = *(_QWORD *)(a1 + 16);
if ( *(_QWORD *)(a1 + 8) == v10 )
{
v27[0] = v25;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)&v25);
LOBYTE(v25) = 0;
*((_QWORD *)&v25 + 1) = 0LL;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v27);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator=(
*(_QWORD *)a1,
(long long)v27);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v27);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v27);
goto LABEL_23;
}
v11 = *(unsigned __int8 **)(v10 - 8);
if ( v11 )
{
v12 = *v11;
if ( v12 != 1 )
{
if ( v12 == 2 )
{
std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(
*((_QWORD *)v11 + 1),
(long long)&v25);
LABEL_23:
LOBYTE(v9) = 1;
LABEL_25:
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)&v25);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(&v25);
return v9;
}
v20 = "ref_stack.back()->is_array() || ref_stack.back()->is_object()";
v21 = 7243LL;
goto LABEL_31;
}
v13 = *(_QWORD *)(a1 + 88);
v14 = *(_DWORD *)(a1 + 96);
if ( *(_QWORD *)(a1 + 72) == v13 && v14 == 0 )
{
v20 = "!key_keep_stack.empty()";
v21 = 7255LL;
LABEL_31:
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
v21,
"GGML_ASSERT(%s) failed",
v20);
goto LABEL_32;
}
v15 = v14;
v16 = v14 - 1LL;
v17 = v15 + 62;
if ( v16 >= 0 )
v17 = v16;
v18 = *(_QWORD *)(v13 + 8 * (v17 >> 6) + 8LL * ((v16 & 0x800000000000003FLL) <= 0x8000000000000000LL) - 8) & (1LL << v16);
*(_DWORD *)(a1 + 96) = v15 - 1;
if ( !(_DWORD)v15 )
{
*(_DWORD *)(a1 + 96) = 63;
*(_QWORD *)(a1 + 88) = v13 - 8;
}
if ( v18 )
{
if ( *(_QWORD *)(a1 + 112) )
{
v26 = v25;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)&v25);
LOBYTE(v25) = 0;
*((_QWORD *)&v25 + 1) = 0LL;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)&v26);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator=(
*(_QWORD *)(a1 + 112),
(long long)&v26);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)&v26);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(&v26);
goto LABEL_23;
}
LABEL_32:
v22 = ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
7264LL,
"GGML_ASSERT(%s) failed",
"object_element");
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)&v25);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(&v25);
_Unwind_Resume(v22);
}
}
LABEL_24:
v9 = 0;
goto LABEL_25;
}
v24 = (*(_QWORD *)(a1 + 16) - *(_QWORD *)(a1 + 8)) >> 3;
v23 = 5;
if ( *(_QWORD *)(a1 + 144) )
{
if ( !(*(unsigned __int8 ( **)(long long, int *, char *, __int128 *))(a1 + 152))(
a1 + 128,
&v24,
&v23,
&v25) )
goto LABEL_24;
goto LABEL_8;
}
LABEL_28:
std::__throw_bad_function_call();
}
return 0;
}
| handle_value<decltype(nullptr)>:
PUSH RBP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x48
MOV EBP,EDX
MOV RAX,qword ptr [RDI + 0x30]
MOV ECX,dword ptr [RDI + 0x38]
CMP qword ptr [RDI + 0x20],RAX
SETZ DL
TEST ECX,ECX
SETZ SIL
AND SIL,DL
CMP SIL,0x1
JZ 0x001603ef
MOV ECX,ECX
MOV R15,-0x8000000000000000
LEA RDX,[RCX + -0x1]
ADD RCX,0x3e
TEST RDX,RDX
CMOVNS RCX,RDX
SAR RCX,0x6
LEA RAX,[RAX + RCX*0x8]
LEA RCX,[R15 + 0x3f]
AND RCX,RDX
XOR ESI,ESI
CMP RCX,R15
SETBE SIL
MOV RAX,qword ptr [RAX + RSI*0x8 + -0x8]
BT RAX,RDX
JNC 0x00160282
MOV RBX,RDI
LEA R14,[RSP + 0x10]
MOV byte ptr [R14],0x0
MOV qword ptr [R14 + 0x8],0x0
MOV RDI,R14
MOV ESI,0x1
CALL 0x00158aa4
MOV RDI,R14
MOV ESI,0x1
CALL 0x00158aa4
TEST BPL,BPL
JNZ 0x0016022f
MOV RAX,qword ptr [RBX + 0x10]
SUB RAX,qword ptr [RBX + 0x8]
SHR RAX,0x3
MOV dword ptr [RSP + 0xc],EAX
MOV byte ptr [RSP + 0xb],0x5
CMP qword ptr [RBX + 0x90],0x0
JZ 0x00160410
LEA RDI,[RBX + 0x80]
LAB_00160212:
LEA RSI,[RSP + 0xc]
LEA RDX,[RSP + 0xb]
LEA RCX,[RSP + 0x10]
CALL qword ptr [RBX + 0x98]
TEST AL,AL
JZ 0x001603c3
LAB_0016022f:
MOV RAX,qword ptr [RBX + 0x10]
CMP qword ptr [RBX + 0x8],RAX
JZ 0x0016028c
MOV RAX,qword ptr [RAX + -0x8]
TEST RAX,RAX
JZ 0x001603c3
MOVZX ECX,byte ptr [RAX]
CMP ECX,0x1
JZ 0x001602e6
CMP ECX,0x2
JNZ 0x00160415
MOV RDI,qword ptr [RAX + 0x8]
LEA RSI,[RSP + 0x10]
CALL 0x0015d666
LAB_00160269:
MOV RAX,qword ptr [RBX + 0x10]
MOV RAX,qword ptr [RAX + -0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV R14,qword ptr [RAX + 0x8]
ADD R14,-0x10
JMP 0x001603bf
LAB_00160282:
XOR EBX,EBX
XOR R14D,R14D
JMP 0x001603df
LAB_0016028c:
LEA R14,[RSP + 0x10]
MOVUPS XMM0,xmmword ptr [R14]
LEA R15,[RSP + 0x30]
MOVAPS xmmword ptr [R15],XMM0
MOV RDI,R14
XOR ESI,ESI
CALL 0x00158aa4
MOV byte ptr [R14],0x0
MOV qword ptr [R14 + 0x8],0x0
MOV RDI,R15
MOV ESI,0x1
CALL 0x00158aa4
MOV RDI,qword ptr [RBX]
MOV RSI,R15
CALL 0x0015b246
MOV RDI,R15
XOR ESI,ESI
CALL 0x00158aa4
MOV RDI,R15
CALL 0x0015df92
MOV R14,qword ptr [RBX]
JMP 0x001603bf
LAB_001602e6:
MOV RAX,qword ptr [RBX + 0x58]
MOV ECX,dword ptr [RBX + 0x60]
CMP qword ptr [RBX + 0x48],RAX
SETZ DL
TEST ECX,ECX
SETZ SIL
AND SIL,DL
CMP SIL,0x1
JZ 0x00160423
MOV ESI,ECX
LEA RCX,[RSI + -0x1]
MOV RDX,RSI
ADD RDX,0x3e
TEST RCX,RCX
CMOVNS RDX,RCX
SAR RDX,0x6
LEA RDI,[RAX + RDX*0x8]
LEA RDX,[R15 + 0x3f]
AND RDX,RCX
XOR R8D,R8D
CMP RDX,R15
SETBE R8B
MOV EDX,0x1
SHL RDX,CL
AND RDX,qword ptr [RDI + R8*0x8 + -0x8]
SUB ESI,0x1
MOV dword ptr [RBX + 0x60],ESI
JNC 0x00160358
MOV dword ptr [RBX + 0x60],0x3f
ADD RAX,-0x8
MOV qword ptr [RBX + 0x58],RAX
LAB_00160358:
TEST RDX,RDX
JZ 0x001603c3
CMP qword ptr [RBX + 0x70],0x0
JZ 0x00160444
LEA R14,[RSP + 0x10]
MOVUPS XMM0,xmmword ptr [R14]
LEA R15,[RSP + 0x20]
MOVAPS xmmword ptr [R15],XMM0
MOV RDI,R14
XOR ESI,ESI
CALL 0x00158aa4
MOV byte ptr [R14],0x0
MOV qword ptr [R14 + 0x8],0x0
MOV RDI,R15
MOV ESI,0x1
CALL 0x00158aa4
MOV RDI,qword ptr [RBX + 0x70]
MOV RSI,R15
CALL 0x0015b246
MOV RDI,R15
XOR ESI,ESI
CALL 0x00158aa4
MOV RDI,R15
CALL 0x0015df92
MOV R14,qword ptr [RBX + 0x70]
LAB_001603bf:
MOV BL,0x1
JMP 0x001603c8
LAB_001603c3:
XOR EBX,EBX
XOR R14D,R14D
LAB_001603c8:
LEA R15,[RSP + 0x10]
MOV RDI,R15
XOR ESI,ESI
CALL 0x00158aa4
MOV RDI,R15
CALL 0x0015df92
LAB_001603df:
MOV EAX,EBX
MOV RDX,R14
ADD RSP,0x48
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_001603ef:
LEA RDI,[0x1ec549]
LEA RDX,[0x1ec593]
LEA RCX,[0x1ed4c5]
MOV ESI,0x1c28
XOR EAX,EAX
CALL 0x0011aeb0
LAB_00160410:
CALL 0x0011a320
LAB_00160415:
LEA RCX,[0x1ed4d9]
MOV ESI,0x1c4b
JMP 0x0016042f
LAB_00160423:
LEA RCX,[0x1ed517]
MOV ESI,0x1c57
LAB_0016042f:
LEA RDI,[0x1ec549]
LEA RDX,[0x1ec593]
XOR EAX,EAX
CALL 0x0011aeb0
LAB_00160444:
LEA RDI,[0x1ec549]
LEA RDX,[0x1ec593]
LEA RCX,[0x1ed52f]
MOV ESI,0x1c60
XOR EAX,EAX
CALL 0x0011aeb0
|
/* std::pair<bool, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>*>
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >::handle_value<decltype(nullptr)>(decltype(nullptr)&&, bool) */
int1 [16] __thiscall
nlohmann::json_abi_v3_11_3::detail::
json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::handle_value<decltype(nullptr)>
(json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*this,_func_decltype_nullptr **param_1,bool param_2)
{
uint uVar1;
char cVar2;
ulong uVar3;
char *pcVar4;
ulong uVar5;
int8 uVar6;
bool bVar7;
long lVar8;
int1 auVar9 [16];
int1 local_5d;
int4 local_5c;
basic_json local_58;
int7 uStack_57;
int8 uStack_50;
int8 local_48;
int8 uStack_40;
int8 local_38;
int8 uStack_30;
uVar1 = *(uint *)(this + 0x38);
if (uVar1 == 0 && *(long *)(this + 0x20) == *(long *)(this + 0x30)) {
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x1c28,
"GGML_ASSERT(%s) failed","!keep_stack.empty()");
}
uVar5 = (ulong)uVar1 - 1;
uVar3 = (ulong)uVar1 + 0x3e;
if (-1 < (long)uVar5) {
uVar3 = uVar5;
}
if ((*(ulong *)(*(long *)(this + 0x30) + ((long)uVar3 >> 6) * 8 + -8 +
(ulong)((uVar5 & 0x800000000000003f) < 0x8000000000000001) * 8) >> (uVar5 & 0x3f) &
1) == 0) {
uVar5 = 0;
lVar8 = 0;
goto LAB_001603df;
}
local_58 = (basic_json)0x0;
uStack_50 = 0;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(&local_58,0));
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(&local_58,0));
if (param_2) {
LAB_0016022f:
if (*(long *)(this + 8) == *(long *)(this + 0x10)) {
local_38 = CONCAT71(uStack_57,local_58);
uStack_30 = uStack_50;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(&local_58,0));
local_58 = (basic_json)0x0;
uStack_50 = 0;
bVar7 = SUB81((data *)&local_38,0);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(bVar7);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::operator=(*(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
**)this,(data *)&local_38);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(bVar7);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data((data *)&local_38);
lVar8 = *(long *)this;
}
else {
pcVar4 = *(char **)(*(long *)(this + 0x10) + -8);
if (pcVar4 == (char *)0x0) goto LAB_001603c3;
if (*pcVar4 == '\x01') {
lVar8 = *(long *)(this + 0x58);
uVar1 = *(uint *)(this + 0x60);
if (uVar1 == 0 && *(long *)(this + 0x48) == lVar8) {
pcVar4 = "!key_keep_stack.empty()";
uVar6 = 0x1c57;
goto LAB_0016042f;
}
uVar5 = (ulong)uVar1 - 1;
uVar3 = (ulong)uVar1 + 0x3e;
if (-1 < (long)uVar5) {
uVar3 = uVar5;
}
uVar3 = *(ulong *)(lVar8 + ((long)uVar3 >> 6) * 8 + -8 +
(ulong)((uVar5 & 0x800000000000003f) < 0x8000000000000001) * 8);
*(uint *)(this + 0x60) = uVar1 - 1;
if (uVar1 == 0) {
*(int4 *)(this + 0x60) = 0x3f;
*(long *)(this + 0x58) = lVar8 + -8;
}
if ((1L << ((byte)uVar5 & 0x3f) & uVar3) == 0) goto LAB_001603c3;
if (*(long *)(this + 0x70) == 0) {
/* try { // try from 00160444 to 00160464 has its CatchHandler @ 00160465 */
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
0x1c60,"GGML_ASSERT(%s) failed","object_element");
}
local_48 = CONCAT71(uStack_57,local_58);
uStack_40 = uStack_50;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(&local_58,0));
local_58 = (basic_json)0x0;
uStack_50 = 0;
bVar7 = SUB81((data *)&local_48,0);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(bVar7);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::operator=(*(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
**)(this + 0x70),(data *)&local_48);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(bVar7);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data((data *)&local_48);
lVar8 = *(long *)(this + 0x70);
}
else {
if (*pcVar4 != '\x02') {
pcVar4 = "ref_stack.back()->is_array() || ref_stack.back()->is_object()";
uVar6 = 0x1c4b;
LAB_0016042f:
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
uVar6,"GGML_ASSERT(%s) failed",pcVar4);
}
std::
vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
::
emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
(*(vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
**)(pcVar4 + 8),&local_58);
lVar8 = *(long *)(*(long *)(*(long *)(*(long *)(this + 0x10) + -8) + 8) + 8) + -0x10;
}
}
uVar5 = CONCAT71((int7)((ulong)this >> 8),1);
}
else {
local_5c = (int4)((ulong)(*(long *)(this + 0x10) - *(long *)(this + 8)) >> 3);
local_5d = 5;
if (*(long *)(this + 0x90) == 0) {
/* WARNING: Subroutine does not return */
/* try { // try from 00160410 to 00160443 has its CatchHandler @ 00160467 */
std::__throw_bad_function_call();
}
/* try { // try from 00160212 to 00160268 has its CatchHandler @ 00160467 */
cVar2 = (**(code **)(this + 0x98))(this + 0x80,&local_5c,&local_5d,&local_58);
if (cVar2 != '\0') goto LAB_0016022f;
LAB_001603c3:
uVar5 = 0;
lVar8 = 0;
}
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81((data *)&local_58,0));
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data((data *)&local_58);
LAB_001603df:
auVar9._0_8_ = uVar5 & 0xffffffff;
auVar9._8_8_ = lVar8;
return auVar9;
}
| |
55,573 | uf_prespace | eloqsql/storage/myisam/mi_packrec.c | static void uf_prespace(MI_COLUMNDEF *rec, MI_BIT_BUFF *bit_buff, uchar *to,
uchar *end)
{
uint spaces;
if ((spaces=get_bits(bit_buff,rec->space_length_bits))+to > end)
{
bit_buff->error=1;
return;
}
bfill((uchar*) to,spaces,' ');
if (to+spaces != end)
decode_bytes(rec,bit_buff,to+spaces,end);
} | O0 | c | uf_prespace:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movq -0x8(%rbp), %rcx
cmpl 0x1c(%rcx), %eax
jb 0xbd25b
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 0x20988d(%rip), %rcx # 0x2c6ae0
andl (%rcx,%rdx,4), %eax
movl %eax, -0x28(%rbp)
jmp 0xbd26e
movq -0x10(%rbp), %rdi
movq -0x8(%rbp), %rax
movl 0x1c(%rax), %esi
callq 0xba450
movl %eax, -0x28(%rbp)
movl -0x28(%rbp), %ecx
movl %ecx, -0x24(%rbp)
movq -0x18(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
cmpq -0x20(%rbp), %rax
jbe 0xbd290
movq -0x10(%rbp), %rax
movl $0x1, 0x28(%rax)
jmp 0xbd2ce
movq -0x18(%rbp), %rdi
movl -0x24(%rbp), %eax
movl %eax, %edx
movl $0x20, %esi
callq 0x2a2a0
movq -0x18(%rbp), %rax
movl -0x24(%rbp), %ecx
addq %rcx, %rax
cmpq -0x20(%rbp), %rax
je 0xbd2ce
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movl -0x24(%rbp), %eax
addq %rax, %rdx
movq -0x20(%rbp), %rcx
callq 0xbc3b0
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| uf_prespace_0:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rax, [rbp+var_10]
mov eax, [rax+4]
mov rcx, [rbp+var_8]
cmp eax, [rcx+1Ch]
jb short loc_BD25B
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_28], eax
jmp short loc_BD26E
loc_BD25B:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_8]
mov esi, [rax+1Ch]
call fill_and_get_bits_0
mov [rbp+var_28], eax
loc_BD26E:
mov ecx, [rbp+var_28]
mov [rbp+var_24], ecx
mov rax, [rbp+var_18]
mov ecx, ecx
add rax, rcx
cmp rax, [rbp+var_20]
jbe short loc_BD290
mov rax, [rbp+var_10]
mov dword ptr [rax+28h], 1
jmp short loc_BD2CE
loc_BD290:
mov rdi, [rbp+var_18]
mov eax, [rbp+var_24]
mov edx, eax
mov esi, 20h ; ' '
call _memset
mov rax, [rbp+var_18]
mov ecx, [rbp+var_24]
add rax, rcx
cmp rax, [rbp+var_20]
jz short loc_BD2CE
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov eax, [rbp+var_24]
add rdx, rax
mov rcx, [rbp+var_20]
call decode_bytes_0
loc_BD2CE:
add rsp, 30h
pop rbp
retn
| long long uf_prespace_0(long long a1, unsigned int *a2, long long a3, _BYTE *a4)
{
unsigned int v4; // eax
int v5; // ecx
long long result; // rax
unsigned int bits_0; // [rsp+8h] [rbp-28h]
if ( a2[1] < *(_DWORD *)(a1 + 28) )
{
bits_0 = fill_and_get_bits_0(a2, *(_DWORD *)(a1 + 28));
}
else
{
v4 = *a2;
v5 = a2[1] - *(_DWORD *)(a1 + 28);
a2[1] = v5;
bits_0 = mask_0[*(unsigned int *)(a1 + 28)] & (v4 >> v5);
}
if ( (unsigned long long)bits_0 + a3 <= (unsigned long long)a4 )
{
memset(a3, 32LL, bits_0);
result = bits_0 + a3;
if ( (_BYTE *)result != a4 )
return decode_bytes_0(a1, (long long)a2, (_BYTE *)(bits_0 + a3), a4);
}
else
{
result = (long long)a2;
a2[10] = 1;
}
return result;
}
| uf_prespace:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x4]
MOV RCX,qword ptr [RBP + -0x8]
CMP EAX,dword ptr [RCX + 0x1c]
JC 0x001bd25b
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,[0x3c6ae0]
AND EAX,dword ptr [RCX + RDX*0x4]
MOV dword ptr [RBP + -0x28],EAX
JMP 0x001bd26e
LAB_001bd25b:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV ESI,dword ptr [RAX + 0x1c]
CALL 0x001ba450
MOV dword ptr [RBP + -0x28],EAX
LAB_001bd26e:
MOV ECX,dword ptr [RBP + -0x28]
MOV dword ptr [RBP + -0x24],ECX
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,ECX
ADD RAX,RCX
CMP RAX,qword ptr [RBP + -0x20]
JBE 0x001bd290
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x28],0x1
JMP 0x001bd2ce
LAB_001bd290:
MOV RDI,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RBP + -0x24]
MOV EDX,EAX
MOV ESI,0x20
CALL 0x0012a2a0
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0x24]
ADD RAX,RCX
CMP RAX,qword ptr [RBP + -0x20]
JZ 0x001bd2ce
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RBP + -0x24]
ADD RDX,RAX
MOV RCX,qword ptr [RBP + -0x20]
CALL 0x001bc3b0
LAB_001bd2ce:
ADD RSP,0x30
POP RBP
RET
|
void uf_prespace(long param_1,uint *param_2,void *param_3,ulong param_4)
{
uint uVar1;
uint local_30;
if (param_2[1] < *(uint *)(param_1 + 0x1c)) {
local_30 = fill_and_get_bits(param_2,*(int4 *)(param_1 + 0x1c));
}
else {
uVar1 = param_2[1] - *(int *)(param_1 + 0x1c);
param_2[1] = uVar1;
local_30 = *param_2 >> ((byte)uVar1 & 0x1f) &
*(uint *)(mask + (ulong)*(uint *)(param_1 + 0x1c) * 4);
}
if (param_4 < (long)param_3 + (ulong)local_30) {
param_2[10] = 1;
}
else {
memset(param_3,0x20,(ulong)local_30);
if ((long)param_3 + (ulong)local_30 != param_4) {
decode_bytes(param_1,param_2,(long)param_3 + (ulong)local_30,param_4);
}
}
return;
}
| |
55,574 | uf_prespace | eloqsql/storage/myisam/mi_packrec.c | static void uf_prespace(MI_COLUMNDEF *rec, MI_BIT_BUFF *bit_buff, uchar *to,
uchar *end)
{
uint spaces;
if ((spaces=get_bits(bit_buff,rec->space_length_bits))+to > end)
{
bit_buff->error=1;
return;
}
bfill((uchar*) to,spaces,' ');
if (to+spaces != end)
decode_bytes(rec,bit_buff,to+spaces,end);
} | O3 | c | uf_prespace:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r12
movq %rsi, %r14
movq %rdi, %r15
movl 0x4(%rsi), %ecx
movl 0x1c(%rdi), %r13d
cmpl %r13d, %ecx
jae 0x84da8
subl %ecx, %r13d
leaq 0x617ee(%rip), %rax # 0xe6560
movq %rbx, -0x30(%rbp)
movl (%rax,%rcx,4), %ebx
andl (%r14), %ebx
movl %r13d, %ecx
shll %cl, %ebx
movq %r14, %rdi
callq 0x839c9
movl $0x20, %eax
subl %r13d, %eax
movl %eax, 0x4(%r14)
movl (%r14), %eax
negl %r13d
movl %r13d, %ecx
shrl %cl, %eax
addl %ebx, %eax
movq -0x30(%rbp), %rbx
jmp 0x84dc2
movl (%r14), %eax
subl %r13d, %ecx
movl %ecx, 0x4(%r14)
shrl %cl, %eax
movl 0x1c(%r15), %ecx
leaq 0x617a1(%rip), %rdx # 0xe6560
andl (%rdx,%rcx,4), %eax
movl %eax, %edx
leaq (%r12,%rdx), %r13
cmpq %rbx, %r13
jbe 0x84dd7
movl $0x1, 0x28(%r14)
jmp 0x84e08
movq %r12, %rdi
movl $0x20, %esi
callq 0x2a290
cmpq %rbx, %r13
je 0x84e08
movq %r15, %rdi
movq %r14, %rsi
movq %r13, %rdx
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x842ba
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| uf_prespace_0:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rcx
mov r12, rdx
mov r14, rsi
mov r15, rdi
mov ecx, [rsi+4]
mov r13d, [rdi+1Ch]
cmp ecx, r13d
jnb short loc_84DA8
sub r13d, ecx
lea rax, mask_0
mov [rbp+var_30], rbx
mov ebx, [rax+rcx*4]
and ebx, [r14]
mov ecx, r13d
shl ebx, cl
mov rdi, r14
call fill_buffer_0
mov eax, 20h ; ' '
sub eax, r13d
mov [r14+4], eax
mov eax, [r14]
neg r13d
mov ecx, r13d
shr eax, cl
add eax, ebx
mov rbx, [rbp+var_30]
jmp short loc_84DC2
loc_84DA8:
mov eax, [r14]
sub ecx, r13d
mov [r14+4], ecx
shr eax, cl
mov ecx, [r15+1Ch]
lea rdx, mask_0
and eax, [rdx+rcx*4]
loc_84DC2:
mov edx, eax
lea r13, [r12+rdx]
cmp r13, rbx
jbe short loc_84DD7
mov dword ptr [r14+28h], 1
jmp short loc_84E08
loc_84DD7:
mov rdi, r12
mov esi, 20h ; ' '
call _memset
cmp r13, rbx
jz short loc_84E08
mov rdi, r15
mov rsi, r14
mov rdx, r13
mov rcx, rbx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp decode_bytes_0
loc_84E08:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long uf_prespace_0(long long a1, unsigned int *a2, long long a3, _BYTE *a4)
{
long long v6; // rcx
unsigned int v7; // r13d
int v8; // r13d
int v9; // ebx
long long result; // rax
unsigned int v11; // eax
unsigned int v12; // ecx
_BYTE *v13; // r13
_BYTE *v14; // [rsp+0h] [rbp-30h]
v6 = a2[1];
v7 = *(_DWORD *)(a1 + 28);
if ( (unsigned int)v6 >= v7 )
{
v11 = *a2;
v12 = v6 - v7;
a2[1] = v12;
result = mask_0[*(unsigned int *)(a1 + 28)] & (v11 >> v12);
}
else
{
v8 = v7 - v6;
v14 = a4;
v9 = (*a2 & mask_0[v6]) << v8;
fill_buffer_0((long long)a2);
a2[1] = 32 - v8;
result = v9 + (*a2 >> -(char)v8);
a4 = v14;
}
v13 = (_BYTE *)(a3 + (unsigned int)result);
if ( v13 <= a4 )
{
result = memset(a3, 32LL, (unsigned int)result);
if ( v13 != a4 )
return (long long)decode_bytes_0(a1, (long long)a2, v13, a4);
}
else
{
a2[10] = 1;
}
return result;
}
| uf_prespace:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RCX
MOV R12,RDX
MOV R14,RSI
MOV R15,RDI
MOV ECX,dword ptr [RSI + 0x4]
MOV R13D,dword ptr [RDI + 0x1c]
CMP ECX,R13D
JNC 0x00184da8
SUB R13D,ECX
LEA RAX,[0x1e6560]
MOV qword ptr [RBP + -0x30],RBX
MOV EBX,dword ptr [RAX + RCX*0x4]
AND EBX,dword ptr [R14]
MOV ECX,R13D
SHL EBX,CL
MOV RDI,R14
CALL 0x001839c9
MOV EAX,0x20
SUB EAX,R13D
MOV dword ptr [R14 + 0x4],EAX
MOV EAX,dword ptr [R14]
NEG R13D
MOV ECX,R13D
SHR EAX,CL
ADD EAX,EBX
MOV RBX,qword ptr [RBP + -0x30]
JMP 0x00184dc2
LAB_00184da8:
MOV EAX,dword ptr [R14]
SUB ECX,R13D
MOV dword ptr [R14 + 0x4],ECX
SHR EAX,CL
MOV ECX,dword ptr [R15 + 0x1c]
LEA RDX,[0x1e6560]
AND EAX,dword ptr [RDX + RCX*0x4]
LAB_00184dc2:
MOV EDX,EAX
LEA R13,[R12 + RDX*0x1]
CMP R13,RBX
JBE 0x00184dd7
MOV dword ptr [R14 + 0x28],0x1
JMP 0x00184e08
LAB_00184dd7:
MOV RDI,R12
MOV ESI,0x20
CALL 0x0012a290
CMP R13,RBX
JZ 0x00184e08
MOV RDI,R15
MOV RSI,R14
MOV RDX,R13
MOV RCX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x001842ba
LAB_00184e08:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void uf_prespace(long param_1,uint *param_2,void *param_3,ulong param_4)
{
ulong uVar1;
uint uVar2;
uint uVar3;
uint uVar4;
uint uVar5;
byte bVar6;
uVar5 = param_2[1];
uVar2 = *(uint *)(param_1 + 0x1c);
if (uVar5 < uVar2) {
uVar3 = (&mask)[uVar5];
uVar4 = *param_2;
bVar6 = (byte)(uVar2 - uVar5);
fill_buffer(param_2);
param_2[1] = 0x20 - (uVar2 - uVar5);
uVar5 = (*param_2 >> (-bVar6 & 0x1f)) + ((uVar3 & uVar4) << (bVar6 & 0x1f));
}
else {
param_2[1] = uVar5 - uVar2;
uVar5 = *param_2 >> ((byte)(uVar5 - uVar2) & 0x1f) & (&mask)[*(uint *)(param_1 + 0x1c)];
}
uVar1 = (long)param_3 + (ulong)uVar5;
if (param_4 < uVar1) {
param_2[10] = 1;
}
else {
memset(param_3,0x20,(ulong)uVar5);
if (uVar1 != param_4) {
decode_bytes(param_1,param_2,uVar1,param_4);
return;
}
}
return;
}
| |
55,575 | ggml_compute_forward_acc | monkey531[P]llama/ggml/src/ggml-cpu/ggml-cpu.c | static void ggml_compute_forward_acc(
const struct ggml_compute_params * params,
struct ggml_tensor * dst) {
const struct ggml_tensor * src0 = dst->src[0];
switch (src0->type) {
case GGML_TYPE_F32:
{
ggml_compute_forward_acc_f32(params, dst);
} break;
case GGML_TYPE_F16:
case GGML_TYPE_BF16:
case GGML_TYPE_Q4_0:
case GGML_TYPE_Q4_1:
case GGML_TYPE_Q5_0:
case GGML_TYPE_Q5_1:
case GGML_TYPE_Q8_0:
case GGML_TYPE_Q8_1:
case GGML_TYPE_Q2_K:
case GGML_TYPE_Q3_K:
case GGML_TYPE_Q4_K:
case GGML_TYPE_Q5_K:
case GGML_TYPE_Q6_K:
case GGML_TYPE_TQ1_0:
case GGML_TYPE_TQ2_0:
case GGML_TYPE_IQ2_XXS:
case GGML_TYPE_IQ2_XS:
case GGML_TYPE_IQ3_XXS:
case GGML_TYPE_IQ1_S:
case GGML_TYPE_IQ1_M:
case GGML_TYPE_IQ4_NL:
case GGML_TYPE_IQ4_XS:
case GGML_TYPE_IQ3_S:
case GGML_TYPE_IQ2_S:
default:
{
GGML_ABORT("fatal error");
}
}
} | O0 | c | ggml_compute_forward_acc:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq 0x98(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
movl (%rax), %eax
movl %eax, 0xc(%rsp)
testl %eax, %eax
je 0x135f5
jmp 0x135b0
movl 0xc(%rsp), %eax
decl %eax
subl $0x3, %eax
jb 0x13606
jmp 0x135bd
movl 0xc(%rsp), %eax
addl $-0x6, %eax
subl $0x9, %eax
jb 0x13606
jmp 0x135cb
movl 0xc(%rsp), %eax
addl $-0x10, %eax
subl $0x8, %eax
jb 0x13606
jmp 0x135d9
movl 0xc(%rsp), %eax
addl $-0x1d, %eax
subl $0x2, %eax
jb 0x13606
jmp 0x135e7
movl 0xc(%rsp), %eax
addl $-0x22, %eax
subl $0x2, %eax
jb 0x13606
jmp 0x13608
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0x25280
jmp 0x13622
jmp 0x13608
leaq 0x9e54b(%rip), %rdi # 0xb1b5a
movl $0x13a7, %esi # imm = 0x13A7
leaq 0x9e6ac(%rip), %rdx # 0xb1cc7
movb $0x0, %al
callq 0xd030
addq $0x28, %rsp
retq
nopw (%rax,%rax)
| ggml_compute_forward_acc:
sub rsp, 28h
mov [rsp+28h+var_8], rdi
mov [rsp+28h+var_10], rsi
mov rax, [rsp+28h+var_10]
mov rax, [rax+98h]
mov [rsp+28h+var_18], rax
mov rax, [rsp+28h+var_18]
mov eax, [rax]
mov [rsp+28h+var_1C], eax
test eax, eax
jz short loc_135F5
jmp short $+2
loc_135B0:
mov eax, [rsp+28h+var_1C]
dec eax
sub eax, 3
jb short loc_13606
jmp short $+2
loc_135BD:
mov eax, [rsp+28h+var_1C]
add eax, 0FFFFFFFAh
sub eax, 9
jb short loc_13606
jmp short $+2
loc_135CB:
mov eax, [rsp+28h+var_1C]
add eax, 0FFFFFFF0h
sub eax, 8
jb short loc_13606
jmp short $+2
loc_135D9:
mov eax, [rsp+28h+var_1C]
add eax, 0FFFFFFE3h
sub eax, 2
jb short loc_13606
jmp short $+2
loc_135E7:
mov eax, [rsp+28h+var_1C]
add eax, 0FFFFFFDEh
sub eax, 2
jb short loc_13606
jmp short loc_13608
loc_135F5:
mov rdi, [rsp+28h+var_8]
mov rsi, [rsp+28h+var_10]
call ggml_compute_forward_acc_f32
jmp short loc_13622
loc_13606:
jmp short $+2
loc_13608:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
mov esi, 13A7h
lea rdx, aFatalError; "fatal error"
mov al, 0
call _ggml_abort
loc_13622:
add rsp, 28h
retn
| double ggml_compute_forward_acc(long long a1, long long a2)
{
double result; // xmm0_8
if ( **(_DWORD **)(a2 + 152) )
return ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/ggml/src/ggml-cpu/ggml-cpu.c",
5031LL,
"fatal error");
ggml_compute_forward_acc_f32(a1, a2);
return result;
}
| ggml_compute_forward_acc:
SUB RSP,0x28
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x18],RSI
MOV RAX,qword ptr [RSP + 0x18]
MOV RAX,qword ptr [RAX + 0x98]
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RSP + 0xc],EAX
TEST EAX,EAX
JZ 0x001135f5
JMP 0x001135b0
LAB_001135b0:
MOV EAX,dword ptr [RSP + 0xc]
DEC EAX
SUB EAX,0x3
JC 0x00113606
JMP 0x001135bd
LAB_001135bd:
MOV EAX,dword ptr [RSP + 0xc]
ADD EAX,-0x6
SUB EAX,0x9
JC 0x00113606
JMP 0x001135cb
LAB_001135cb:
MOV EAX,dword ptr [RSP + 0xc]
ADD EAX,-0x10
SUB EAX,0x8
JC 0x00113606
JMP 0x001135d9
LAB_001135d9:
MOV EAX,dword ptr [RSP + 0xc]
ADD EAX,-0x1d
SUB EAX,0x2
JC 0x00113606
JMP 0x001135e7
LAB_001135e7:
MOV EAX,dword ptr [RSP + 0xc]
ADD EAX,-0x22
SUB EAX,0x2
JC 0x00113606
JMP 0x00113608
LAB_001135f5:
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x18]
CALL 0x00125280
JMP 0x00113622
LAB_00113606:
JMP 0x00113608
LAB_00113608:
LEA RDI,[0x1b1b5a]
MOV ESI,0x13a7
LEA RDX,[0x1b1cc7]
MOV AL,0x0
CALL 0x0010d030
LAB_00113622:
ADD RSP,0x28
RET
|
void ggml_compute_forward_acc(int8 param_1,long param_2)
{
if (**(int **)(param_2 + 0x98) != 0) {
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/ggml/src/ggml-cpu/ggml-cpu.c"
,0x13a7,"fatal error");
}
ggml_compute_forward_acc_f32(param_1,param_2);
return;
}
| |
55,576 | my_mb_wc_filename | eloqsql/strings/ctype-utf8.c | static int
my_mb_wc_filename(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t *pwc, const uchar *s, const uchar *e)
{
int byte1, byte2;
if (s >= e)
return MY_CS_TOOSMALL;
if (*s < 128 && filename_safe_char[*s])
{
*pwc= *s;
return 1;
}
if (*s != MY_FILENAME_ESCAPE)
return MY_CS_ILSEQ;
if (s + 3 > e)
return MY_CS_TOOSMALL3;
byte1= s[1];
if (byte1 == 0)
return MY_CS_ILSEQ; /* avoid possible out-of-bounds read */
byte2= s[2];
if (byte1 >= 0x30 && byte1 <= 0x7F &&
byte2 >= 0x30 && byte2 <= 0x7F)
{
int code= (byte1 - 0x30) * 80 + byte2 - 0x30;
if (code < 5994 && touni[code])
{
*pwc= touni[code];
return 3;
}
if (byte1 == '@' && byte2 == '@')
{
*pwc= 0;
return 3;
}
}
if (s + 4 > e)
return MY_CS_TOOSMALL4;
if ((byte1= hexlo(byte1)) >= 0 &&
(byte2= hexlo(byte2)) >= 0)
{
int byte3= hexlo(s[3]);
int byte4= hexlo(s[3] ? s[4] : 0);
if (byte3 >=0 && byte4 >=0)
{
*pwc= (byte1 << 12) + (byte2 << 8) + (byte3 << 4) + byte4;
return 5;
}
}
return MY_CS_ILSEQ;
} | O0 | c | my_mb_wc_filename:
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 -0x20(%rbp), %rax
cmpq -0x28(%rbp), %rax
jb 0xc791e
movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B
jmp 0xc7b0e
movq -0x20(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x80, %eax
jge 0xc7961
movq -0x20(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %ecx
leaq 0x14c194(%rip), %rax # 0x213ad0
movsbl (%rax,%rcx), %eax
cmpl $0x0, %eax
je 0xc7961
movq -0x20(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %ecx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movl $0x1, -0x4(%rbp)
jmp 0xc7b0e
movq -0x20(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x40, %eax
je 0xc7979
movl $0x0, -0x4(%rbp)
jmp 0xc7b0e
movq -0x20(%rbp), %rax
addq $0x3, %rax
cmpq -0x28(%rbp), %rax
jbe 0xc7993
movl $0xffffff99, -0x4(%rbp) # imm = 0xFFFFFF99
jmp 0xc7b0e
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
movl %eax, -0x2c(%rbp)
cmpl $0x0, -0x2c(%rbp)
jne 0xc79b0
movl $0x0, -0x4(%rbp)
jmp 0xc7b0e
movq -0x20(%rbp), %rax
movzbl 0x2(%rax), %eax
movl %eax, -0x30(%rbp)
cmpl $0x30, -0x2c(%rbp)
jl 0xc7a53
cmpl $0x7f, -0x2c(%rbp)
jg 0xc7a53
cmpl $0x30, -0x30(%rbp)
jl 0xc7a53
cmpl $0x7f, -0x30(%rbp)
jg 0xc7a53
movl -0x2c(%rbp), %eax
subl $0x30, %eax
imull $0x50, %eax, %eax
addl -0x30(%rbp), %eax
subl $0x30, %eax
movl %eax, -0x34(%rbp)
cmpl $0x176a, -0x34(%rbp) # imm = 0x176A
jge 0xc7a2e
movslq -0x34(%rbp), %rcx
leaq 0x14c14f(%rip), %rax # 0x213b50
movzwl (%rax,%rcx,2), %eax
cmpl $0x0, %eax
je 0xc7a2e
movslq -0x34(%rbp), %rcx
leaq 0x14c13b(%rip), %rax # 0x213b50
movzwl (%rax,%rcx,2), %eax
movl %eax, %ecx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movl $0x3, -0x4(%rbp)
jmp 0xc7b0e
cmpl $0x40, -0x2c(%rbp)
jne 0xc7a51
cmpl $0x40, -0x30(%rbp)
jne 0xc7a51
movq -0x18(%rbp), %rax
movq $0x0, (%rax)
movl $0x3, -0x4(%rbp)
jmp 0xc7b0e
jmp 0xc7a53
movq -0x20(%rbp), %rax
addq $0x4, %rax
cmpq -0x28(%rbp), %rax
jbe 0xc7a6d
movl $0xffffff98, -0x4(%rbp) # imm = 0xFFFFFF98
jmp 0xc7b0e
movl -0x2c(%rbp), %edi
callq 0xc7f30
movl %eax, -0x2c(%rbp)
cmpl $0x0, %eax
jl 0xc7b07
movl -0x30(%rbp), %edi
callq 0xc7f30
movl %eax, -0x30(%rbp)
cmpl $0x0, %eax
jl 0xc7b07
movq -0x20(%rbp), %rax
movzbl 0x3(%rax), %edi
callq 0xc7f30
movl %eax, -0x38(%rbp)
movq -0x20(%rbp), %rax
movzbl 0x3(%rax), %eax
cmpl $0x0, %eax
je 0xc7abb
movq -0x20(%rbp), %rax
movzbl 0x4(%rax), %eax
movl %eax, -0x40(%rbp)
jmp 0xc7ac2
xorl %eax, %eax
movl %eax, -0x40(%rbp)
jmp 0xc7ac2
movl -0x40(%rbp), %edi
callq 0xc7f30
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0x38(%rbp)
jl 0xc7b05
cmpl $0x0, -0x3c(%rbp)
jl 0xc7b05
movl -0x2c(%rbp), %eax
shll $0xc, %eax
movl -0x30(%rbp), %ecx
shll $0x8, %ecx
addl %ecx, %eax
movl -0x38(%rbp), %ecx
shll $0x4, %ecx
addl %ecx, %eax
addl -0x3c(%rbp), %eax
movslq %eax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movl $0x5, -0x4(%rbp)
jmp 0xc7b0e
jmp 0xc7b07
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)
| my_mb_wc_filename:
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_20]
cmp rax, [rbp+var_28]
jb short loc_C791E
mov [rbp+var_4], 0FFFFFF9Bh
jmp loc_C7B0E
loc_C791E:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax]
cmp eax, 80h
jge short loc_C7961
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax]
mov ecx, eax
lea rax, filename_safe_char
movsx eax, byte ptr [rax+rcx]
cmp eax, 0
jz short loc_C7961
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax]
mov ecx, eax
mov rax, [rbp+var_18]
mov [rax], rcx
mov [rbp+var_4], 1
jmp loc_C7B0E
loc_C7961:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax]
cmp eax, 40h ; '@'
jz short loc_C7979
mov [rbp+var_4], 0
jmp loc_C7B0E
loc_C7979:
mov rax, [rbp+var_20]
add rax, 3
cmp rax, [rbp+var_28]
jbe short loc_C7993
mov [rbp+var_4], 0FFFFFF99h
jmp loc_C7B0E
loc_C7993:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
mov [rbp+var_2C], eax
cmp [rbp+var_2C], 0
jnz short loc_C79B0
mov [rbp+var_4], 0
jmp loc_C7B0E
loc_C79B0:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+2]
mov [rbp+var_30], eax
cmp [rbp+var_2C], 30h ; '0'
jl loc_C7A53
cmp [rbp+var_2C], 7Fh
jg loc_C7A53
cmp [rbp+var_30], 30h ; '0'
jl short loc_C7A53
cmp [rbp+var_30], 7Fh
jg short loc_C7A53
mov eax, [rbp+var_2C]
sub eax, 30h ; '0'
imul eax, 50h ; 'P'
add eax, [rbp+var_30]
sub eax, 30h ; '0'
mov [rbp+var_34], eax
cmp [rbp+var_34], 176Ah
jge short loc_C7A2E
movsxd rcx, [rbp+var_34]
lea rax, touni
movzx eax, word ptr [rax+rcx*2]
cmp eax, 0
jz short loc_C7A2E
movsxd rcx, [rbp+var_34]
lea rax, touni
movzx eax, word ptr [rax+rcx*2]
mov ecx, eax
mov rax, [rbp+var_18]
mov [rax], rcx
mov [rbp+var_4], 3
jmp loc_C7B0E
loc_C7A2E:
cmp [rbp+var_2C], 40h ; '@'
jnz short loc_C7A51
cmp [rbp+var_30], 40h ; '@'
jnz short loc_C7A51
mov rax, [rbp+var_18]
mov qword ptr [rax], 0
mov [rbp+var_4], 3
jmp loc_C7B0E
loc_C7A51:
jmp short $+2
loc_C7A53:
mov rax, [rbp+var_20]
add rax, 4
cmp rax, [rbp+var_28]
jbe short loc_C7A6D
mov [rbp+var_4], 0FFFFFF98h
jmp loc_C7B0E
loc_C7A6D:
mov edi, [rbp+var_2C]
call hexlo
mov [rbp+var_2C], eax
cmp eax, 0
jl loc_C7B07
mov edi, [rbp+var_30]
call hexlo
mov [rbp+var_30], eax
cmp eax, 0
jl short loc_C7B07
mov rax, [rbp+var_20]
movzx edi, byte ptr [rax+3]
call hexlo
mov [rbp+var_38], eax
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+3]
cmp eax, 0
jz short loc_C7ABB
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+4]
mov [rbp+var_40], eax
jmp short loc_C7AC2
loc_C7ABB:
xor eax, eax
mov [rbp+var_40], eax
jmp short $+2
loc_C7AC2:
mov edi, [rbp+var_40]
call hexlo
mov [rbp+var_3C], eax
cmp [rbp+var_38], 0
jl short loc_C7B05
cmp [rbp+var_3C], 0
jl short loc_C7B05
mov eax, [rbp+var_2C]
shl eax, 0Ch
mov ecx, [rbp+var_30]
shl ecx, 8
add eax, ecx
mov ecx, [rbp+var_38]
shl ecx, 4
add eax, ecx
add eax, [rbp+var_3C]
movsxd rcx, eax
mov rax, [rbp+var_18]
mov [rax], rcx
mov [rbp+var_4], 5
jmp short loc_C7B0E
loc_C7B05:
jmp short $+2
loc_C7B07:
mov [rbp+var_4], 0
loc_C7B0E:
mov eax, [rbp+var_4]
add rsp, 40h
pop rbp
retn
| long long my_mb_wc_filename(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4)
{
unsigned int v5; // [rsp+0h] [rbp-40h]
int v6; // [rsp+4h] [rbp-3Ch]
int v7; // [rsp+8h] [rbp-38h]
int v8; // [rsp+Ch] [rbp-34h]
unsigned int v9; // [rsp+10h] [rbp-30h]
int v10; // [rsp+10h] [rbp-30h]
int v11; // [rsp+14h] [rbp-2Ch]
int v12; // [rsp+14h] [rbp-2Ch]
if ( (unsigned long long)a3 < a4 )
{
if ( *a3 < 0x80u && filename_safe_char[*a3] )
{
*a2 = *a3;
return 1;
}
else if ( *a3 == 64 )
{
if ( (unsigned long long)(a3 + 3) <= a4 )
{
v11 = a3[1];
if ( a3[1] )
{
v9 = a3[2];
if ( a3[1] >= 0x30u && a3[1] <= 0x7Fu && a3[2] >= 0x30u && a3[2] <= 0x7Fu )
{
v8 = v9 + 80 * (v11 - 48) - 48;
if ( v8 < 5994 && touni[v8] )
{
*a2 = touni[v8];
return 3;
}
if ( v11 == 64 && v9 == 64 )
{
*a2 = 0LL;
return 3;
}
}
if ( (unsigned long long)(a3 + 4) <= a4 )
{
v12 = hexlo(a3[1]);
if ( v12 < 0 )
return 0;
v10 = hexlo(v9);
if ( v10 < 0 )
return 0;
v7 = hexlo(a3[3]);
v5 = a3[3] ? a3[4] : 0;
v6 = hexlo(v5);
if ( v7 < 0 || v6 < 0 )
{
return 0;
}
else
{
*a2 = v6 + 16 * v7 + (v10 << 8) + (v12 << 12);
return 5;
}
}
else
{
return (unsigned int)-104;
}
}
else
{
return 0;
}
}
else
{
return (unsigned int)-103;
}
}
else
{
return 0;
}
}
else
{
return (unsigned int)-101;
}
}
| my_mb_wc_filename:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RBP + -0x28]
JC 0x001c791e
MOV dword ptr [RBP + -0x4],0xffffff9b
JMP 0x001c7b0e
LAB_001c791e:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x80
JGE 0x001c7961
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX]
MOV ECX,EAX
LEA RAX,[0x313ad0]
MOVSX EAX,byte ptr [RAX + RCX*0x1]
CMP EAX,0x0
JZ 0x001c7961
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x1
JMP 0x001c7b0e
LAB_001c7961:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x40
JZ 0x001c7979
MOV dword ptr [RBP + -0x4],0x0
JMP 0x001c7b0e
LAB_001c7979:
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x3
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x001c7993
MOV dword ptr [RBP + -0x4],0xffffff99
JMP 0x001c7b0e
LAB_001c7993:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
MOV dword ptr [RBP + -0x2c],EAX
CMP dword ptr [RBP + -0x2c],0x0
JNZ 0x001c79b0
MOV dword ptr [RBP + -0x4],0x0
JMP 0x001c7b0e
LAB_001c79b0:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x2]
MOV dword ptr [RBP + -0x30],EAX
CMP dword ptr [RBP + -0x2c],0x30
JL 0x001c7a53
CMP dword ptr [RBP + -0x2c],0x7f
JG 0x001c7a53
CMP dword ptr [RBP + -0x30],0x30
JL 0x001c7a53
CMP dword ptr [RBP + -0x30],0x7f
JG 0x001c7a53
MOV EAX,dword ptr [RBP + -0x2c]
SUB EAX,0x30
IMUL EAX,EAX,0x50
ADD EAX,dword ptr [RBP + -0x30]
SUB EAX,0x30
MOV dword ptr [RBP + -0x34],EAX
CMP dword ptr [RBP + -0x34],0x176a
JGE 0x001c7a2e
MOVSXD RCX,dword ptr [RBP + -0x34]
LEA RAX,[0x313b50]
MOVZX EAX,word ptr [RAX + RCX*0x2]
CMP EAX,0x0
JZ 0x001c7a2e
MOVSXD RCX,dword ptr [RBP + -0x34]
LEA RAX,[0x313b50]
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x3
JMP 0x001c7b0e
LAB_001c7a2e:
CMP dword ptr [RBP + -0x2c],0x40
JNZ 0x001c7a51
CMP dword ptr [RBP + -0x30],0x40
JNZ 0x001c7a51
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],0x0
MOV dword ptr [RBP + -0x4],0x3
JMP 0x001c7b0e
LAB_001c7a51:
JMP 0x001c7a53
LAB_001c7a53:
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x4
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x001c7a6d
MOV dword ptr [RBP + -0x4],0xffffff98
JMP 0x001c7b0e
LAB_001c7a6d:
MOV EDI,dword ptr [RBP + -0x2c]
CALL 0x001c7f30
MOV dword ptr [RBP + -0x2c],EAX
CMP EAX,0x0
JL 0x001c7b07
MOV EDI,dword ptr [RBP + -0x30]
CALL 0x001c7f30
MOV dword ptr [RBP + -0x30],EAX
CMP EAX,0x0
JL 0x001c7b07
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EDI,byte ptr [RAX + 0x3]
CALL 0x001c7f30
MOV dword ptr [RBP + -0x38],EAX
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x3]
CMP EAX,0x0
JZ 0x001c7abb
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x4]
MOV dword ptr [RBP + -0x40],EAX
JMP 0x001c7ac2
LAB_001c7abb:
XOR EAX,EAX
MOV dword ptr [RBP + -0x40],EAX
JMP 0x001c7ac2
LAB_001c7ac2:
MOV EDI,dword ptr [RBP + -0x40]
CALL 0x001c7f30
MOV dword ptr [RBP + -0x3c],EAX
CMP dword ptr [RBP + -0x38],0x0
JL 0x001c7b05
CMP dword ptr [RBP + -0x3c],0x0
JL 0x001c7b05
MOV EAX,dword ptr [RBP + -0x2c]
SHL EAX,0xc
MOV ECX,dword ptr [RBP + -0x30]
SHL ECX,0x8
ADD EAX,ECX
MOV ECX,dword ptr [RBP + -0x38]
SHL ECX,0x4
ADD EAX,ECX
ADD EAX,dword ptr [RBP + -0x3c]
MOVSXD RCX,EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x5
JMP 0x001c7b0e
LAB_001c7b05:
JMP 0x001c7b07
LAB_001c7b07:
MOV dword ptr [RBP + -0x4],0x0
LAB_001c7b0e:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x40
POP RBP
RET
|
int4 my_mb_wc_filename(int8 param_1,ulong *param_2,byte *param_3,byte *param_4)
{
byte bVar1;
uint uVar2;
uint uVar3;
int iVar4;
int iVar5;
int iVar6;
int iVar7;
int4 local_c;
if (param_3 < param_4) {
if ((*param_3 < 0x80) && (filename_safe_char[*param_3] != '\0')) {
*param_2 = (ulong)*param_3;
local_c = 1;
}
else if (*param_3 == 0x40) {
if (param_4 < param_3 + 3) {
local_c = 0xffffff99;
}
else {
uVar2 = (uint)param_3[1];
if (uVar2 == 0) {
local_c = 0;
}
else {
uVar3 = (uint)param_3[2];
if ((((0x2f < uVar2) && (uVar2 < 0x80)) && (0x2f < uVar3)) && (uVar3 < 0x80)) {
iVar4 = (uVar2 - 0x30) * 0x50 + uVar3 + -0x30;
if ((iVar4 < 0x176a) && (*(short *)(touni + (long)iVar4 * 2) != 0)) {
*param_2 = (ulong)*(ushort *)(touni + (long)iVar4 * 2);
return 3;
}
if ((uVar2 == 0x40) && (uVar3 == 0x40)) {
*param_2 = 0;
return 3;
}
}
if (param_4 < param_3 + 4) {
local_c = 0xffffff98;
}
else {
iVar4 = hexlo(uVar2);
if ((-1 < iVar4) && (iVar5 = hexlo(uVar3), -1 < iVar5)) {
iVar6 = hexlo(param_3[3]);
if (param_3[3] == 0) {
bVar1 = 0;
}
else {
bVar1 = param_3[4];
}
iVar7 = hexlo(bVar1);
if ((-1 < iVar6) && (-1 < iVar7)) {
*param_2 = (long)(iVar4 * 0x1000 + iVar5 * 0x100 + iVar6 * 0x10 + iVar7);
return 5;
}
}
local_c = 0;
}
}
}
}
else {
local_c = 0;
}
}
else {
local_c = 0xffffff9b;
}
return local_c;
}
| |
55,577 | psi_rwlock_trywrlock | eloqsql/mysys/my_thr_init.c | ATTRIBUTE_COLD
int psi_rwlock_trywrlock(mysql_rwlock_t *that, const char *file, uint line)
{
PSI_rwlock_locker_state state;
PSI_rwlock_locker *locker= PSI_RWLOCK_CALL(start_rwlock_wrwait)
(&state, that->m_psi, PSI_RWLOCK_TRYWRITELOCK, file, line);
int result= rw_trywrlock(&that->m_rwlock);
if (locker)
PSI_RWLOCK_CALL(end_rwlock_wrwait)(locker, result);
return result;
} | O0 | c | psi_rwlock_trywrlock:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
leaq 0x1a7fb6(%rip), %rax # 0x1cf8f0
movq (%rax), %rax
movq 0x1b0(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x90(%rcx), %rsi
movq -0x10(%rbp), %rcx
movl -0x14(%rbp), %r8d
leaq -0x48(%rbp), %rdi
movl $0x3, %edx
callq *%rax
movq %rax, -0x50(%rbp)
movq -0x8(%rbp), %rdi
callq 0x27fa0
movl %eax, -0x54(%rbp)
cmpq $0x0, -0x50(%rbp)
je 0x27993
leaq 0x1a7f70(%rip), %rax # 0x1cf8f0
movq (%rax), %rax
movq 0x1b8(%rax), %rax
movq -0x50(%rbp), %rdi
movl -0x54(%rbp), %esi
callq *%rax
movl -0x54(%rbp), %eax
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
| psi_rwlock_trywrlock:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+1B0h]
mov rcx, [rbp+var_8]
mov rsi, [rcx+90h]
mov rcx, [rbp+var_10]
mov r8d, [rbp+var_14]
lea rdi, [rbp+var_48]
mov edx, 3
call rax
mov [rbp+var_50], rax
mov rdi, [rbp+var_8]
call my_rw_trywrlock
mov [rbp+var_54], eax
cmp [rbp+var_50], 0
jz short loc_27993
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+1B8h]
mov rdi, [rbp+var_50]
mov esi, [rbp+var_54]
call rax
loc_27993:
mov eax, [rbp+var_54]
add rsp, 60h
pop rbp
retn
| long long psi_rwlock_trywrlock(long long a1, long long a2, unsigned int a3)
{
unsigned int v4; // [rsp+Ch] [rbp-54h]
long long v5; // [rsp+10h] [rbp-50h]
_BYTE v6[52]; // [rsp+18h] [rbp-48h] BYREF
unsigned int v7; // [rsp+4Ch] [rbp-14h]
long long v8; // [rsp+50h] [rbp-10h]
long long v9; // [rsp+58h] [rbp-8h]
v9 = a1;
v8 = a2;
v7 = a3;
v5 = (*((long long ( **)(_BYTE *, _QWORD, long long, long long, _QWORD))PSI_server[0] + 54))(
v6,
*(_QWORD *)(a1 + 144),
3LL,
a2,
a3);
v4 = my_rw_trywrlock(v9);
if ( v5 )
(*((void ( **)(long long, _QWORD))PSI_server[0] + 55))(v5, v4);
return v4;
}
| psi_rwlock_trywrlock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
LEA RAX,[0x2cf8f0]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x1b0]
MOV RCX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RCX + 0x90]
MOV RCX,qword ptr [RBP + -0x10]
MOV R8D,dword ptr [RBP + -0x14]
LEA RDI,[RBP + -0x48]
MOV EDX,0x3
CALL RAX
MOV qword ptr [RBP + -0x50],RAX
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00127fa0
MOV dword ptr [RBP + -0x54],EAX
CMP qword ptr [RBP + -0x50],0x0
JZ 0x00127993
LEA RAX,[0x2cf8f0]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x1b8]
MOV RDI,qword ptr [RBP + -0x50]
MOV ESI,dword ptr [RBP + -0x54]
CALL RAX
LAB_00127993:
MOV EAX,dword ptr [RBP + -0x54]
ADD RSP,0x60
POP RBP
RET
|
int4 psi_rwlock_trywrlock(long param_1,int8 param_2,int4 param_3)
{
int4 uVar1;
long lVar2;
int1 local_50 [52];
int4 local_1c;
int8 local_18;
long local_10;
local_1c = param_3;
local_18 = param_2;
local_10 = param_1;
lVar2 = (**(code **)(PSI_server + 0x1b0))
(local_50,*(int8 *)(param_1 + 0x90),3,param_2,param_3);
uVar1 = my_rw_trywrlock(local_10);
if (lVar2 != 0) {
(**(code **)(PSI_server + 0x1b8))(lVar2,uVar1);
}
return uVar1;
}
| |
55,578 | wake_up_waiters | eloqsql/mysys/thr_lock.c | static void wake_up_waiters(THR_LOCK *lock)
{
THR_LOCK_DATA *data;
enum thr_lock_type lock_type;
DBUG_ENTER("wake_up_waiters");
check_locks(lock, "before waking up waiters", TL_UNLOCK, 1);
if (!lock->write.data) /* If no active write locks */
{
data=lock->write_wait.data;
if (!lock->read.data) /* If no more locks in use */
{
/* Release write-locks with TL_WRITE or TL_WRITE_ONLY priority first */
if (data &&
(data->type != TL_WRITE_LOW_PRIORITY || !lock->read_wait.data ||
lock->read_wait.data->type < TL_READ_HIGH_PRIORITY))
{
if (lock->write_lock_count++ > max_write_lock_count)
{
/* Too many write locks in a row; Release all waiting read locks */
lock->write_lock_count=0;
if (lock->read_wait.data)
{
DBUG_PRINT("info",("Freeing all read_locks because of max_write_lock_count"));
free_all_read_locks(lock,0);
goto end;
}
}
for (;;)
{
if (((*data->prev)=data->next)) /* remove from wait-list */
data->next->prev= data->prev;
else
lock->write_wait.last=data->prev;
(*lock->write.last)=data; /* Put in execute list */
data->prev=lock->write.last;
data->next=0;
lock->write.last= &data->next;
if (data->type == TL_WRITE_CONCURRENT_INSERT &&
(*lock->check_status)(data->status_param))
data->type=TL_WRITE; /* Upgrade lock */
/* purecov: begin inspected */
DBUG_PRINT("lock",("giving write lock of type %d to thread: %lu",
data->type, (ulong) data->owner->thread_id));
/* purecov: end */
{
mysql_cond_t *cond= data->cond;
data->cond=0; /* Mark thread free */
mysql_cond_signal(cond); /* Start waiting thread */
}
if (data->type != TL_WRITE_ALLOW_WRITE ||
!lock->write_wait.data ||
lock->write_wait.data->type != TL_WRITE_ALLOW_WRITE)
break;
data=lock->write_wait.data; /* Free this too */
}
if (data->type >= TL_WRITE_LOW_PRIORITY)
goto end;
/* Release possible read locks together with the write lock */
}
if (lock->read_wait.data)
free_all_read_locks(lock,
data &&
(data->type == TL_WRITE_CONCURRENT_INSERT ||
data->type == TL_WRITE_ALLOW_WRITE));
else
{
DBUG_PRINT("lock",("No waiting read locks to free"));
}
}
else if (data &&
(lock_type=data->type) <= TL_WRITE_DELAYED &&
((lock_type != TL_WRITE_CONCURRENT_INSERT &&
lock_type != TL_WRITE_ALLOW_WRITE) ||
!lock->read_no_write_count))
{
/*
For DELAYED, ALLOW_READ, WRITE_ALLOW_WRITE or CONCURRENT_INSERT locks
start WRITE locks together with the READ locks
*/
if (lock_type == TL_WRITE_CONCURRENT_INSERT &&
(*lock->check_status)(data->status_param))
{
data->type=TL_WRITE; /* Upgrade lock */
if (lock->read_wait.data)
free_all_read_locks(lock,0);
goto end;
}
do {
mysql_cond_t *cond= data->cond;
if (((*data->prev)=data->next)) /* remove from wait-list */
data->next->prev= data->prev;
else
lock->write_wait.last=data->prev;
(*lock->write.last)=data; /* Put in execute list */
data->prev=lock->write.last;
lock->write.last= &data->next;
data->next=0; /* Only one write lock */
data->cond=0; /* Mark thread free */
mysql_cond_signal(cond); /* Start waiting thread */
} while (lock_type == TL_WRITE_ALLOW_WRITE &&
(data=lock->write_wait.data) &&
data->type == TL_WRITE_ALLOW_WRITE);
if (lock->read_wait.data)
free_all_read_locks(lock,
(lock_type == TL_WRITE_CONCURRENT_INSERT ||
lock_type == TL_WRITE_ALLOW_WRITE));
}
else if (!data && lock->read_wait.data)
free_all_read_locks(lock,0);
}
end:
check_locks(lock, "after waking up waiters", TL_UNLOCK, 0);
DBUG_VOID_RETURN;
} | O0 | c | wake_up_waiters:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x90(%rax)
jne 0xf80b1
movq -0x8(%rbp), %rax
movq 0x80(%rax), %rax
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x70(%rax)
jne 0xf7ee5
cmpq $0x0, -0x10(%rbp)
je 0xf7e82
movq -0x10(%rbp), %rax
cmpl $0xb, 0x40(%rax)
jne 0xf7cfe
movq -0x8(%rbp), %rax
cmpq $0x0, 0x60(%rax)
je 0xf7cfe
movq -0x8(%rbp), %rax
movq 0x60(%rax), %rax
cmpl $0x4, 0x40(%rax)
jge 0xf7e82
movq -0x8(%rbp), %rcx
movq 0xa0(%rcx), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, 0xa0(%rcx)
leaq 0x1c7f3a(%rip), %rcx # 0x2bfc58
cmpq (%rcx), %rax
jbe 0xf7d53
movq -0x8(%rbp), %rax
movq $0x0, 0xa0(%rax)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x60(%rax)
je 0xf7d51
jmp 0xf7d3f
jmp 0xf7d41
movq -0x8(%rbp), %rdi
xorl %esi, %esi
callq 0xf9720
jmp 0xf80b3
jmp 0xf7d53
jmp 0xf7d55
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq %rax, (%rcx)
cmpq $0x0, %rax
je 0xf7d84
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rcx, 0x10(%rax)
jmp 0xf7d97
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x88(%rax)
movq -0x10(%rbp), %rcx
movq -0x8(%rbp), %rax
movq 0x98(%rax), %rax
movq %rcx, (%rax)
movq -0x8(%rbp), %rax
movq 0x98(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x8(%rax)
movq -0x10(%rbp), %rcx
addq $0x8, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x98(%rax)
movq -0x10(%rbp), %rax
cmpl $0x8, 0x40(%rax)
jne 0xf7e0d
movq -0x8(%rbp), %rax
movq 0xd8(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x28(%rcx), %rdi
callq *%rax
movsbl %al, %eax
cmpl $0x0, %eax
je 0xf7e0d
movq -0x10(%rbp), %rax
movl $0xd, 0x40(%rax)
jmp 0xf7e0f
jmp 0xf7e11
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq $0x0, 0x20(%rax)
movq -0x20(%rbp), %rdi
callq 0xf8da0
movq -0x10(%rbp), %rax
cmpl $0x7, 0x40(%rax)
jne 0xf7e5b
movq -0x8(%rbp), %rax
cmpq $0x0, 0x80(%rax)
je 0xf7e5b
movq -0x8(%rbp), %rax
movq 0x80(%rax), %rax
cmpl $0x7, 0x40(%rax)
je 0xf7e5d
jmp 0xf7e71
movq -0x8(%rbp), %rax
movq 0x80(%rax), %rax
movq %rax, -0x10(%rbp)
jmp 0xf7d55
movq -0x10(%rbp), %rax
cmpl $0xb, 0x40(%rax)
jl 0xf7e80
jmp 0xf80b3
jmp 0xf7e82
movq -0x8(%rbp), %rax
cmpq $0x0, 0x60(%rax)
je 0xf7eda
movq -0x8(%rbp), %rax
movq %rax, -0x38(%rbp)
xorl %eax, %eax
cmpq $0x0, -0x10(%rbp)
movb %al, -0x29(%rbp)
je 0xf7ec4
movq -0x10(%rbp), %rcx
movb $0x1, %al
cmpl $0x8, 0x40(%rcx)
movb %al, -0x39(%rbp)
je 0xf7ebe
movq -0x10(%rbp), %rax
cmpl $0x7, 0x40(%rax)
sete %al
movb %al, -0x39(%rbp)
movb -0x39(%rbp), %al
movb %al, -0x29(%rbp)
movq -0x38(%rbp), %rdi
movb -0x29(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movsbl %al, %esi
callq 0xf9720
jmp 0xf7ee0
jmp 0xf7edc
jmp 0xf7ede
jmp 0xf7ee0
jmp 0xf80af
cmpq $0x0, -0x10(%rbp)
je 0xf808e
movq -0x10(%rbp), %rax
movl 0x40(%rax), %eax
movl %eax, -0x14(%rbp)
cmpl $0x9, %eax
jg 0xf808e
cmpl $0x8, -0x14(%rbp)
je 0xf7f0f
cmpl $0x7, -0x14(%rbp)
jne 0xf7f20
movq -0x8(%rbp), %rax
cmpl $0x0, 0xa8(%rax)
jne 0xf808e
cmpl $0x8, -0x14(%rbp)
jne 0xf7f69
movq -0x8(%rbp), %rax
movq 0xd8(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x28(%rcx), %rdi
callq *%rax
movsbl %al, %eax
cmpl $0x0, %eax
je 0xf7f69
movq -0x10(%rbp), %rax
movl $0xd, 0x40(%rax)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x60(%rax)
je 0xf7f64
movq -0x8(%rbp), %rdi
xorl %esi, %esi
callq 0xf9720
jmp 0xf80b3
jmp 0xf7f6b
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq %rax, (%rcx)
cmpq $0x0, %rax
je 0xf7fa6
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rcx, 0x10(%rax)
jmp 0xf7fb9
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x88(%rax)
movq -0x10(%rbp), %rcx
movq -0x8(%rbp), %rax
movq 0x98(%rax), %rax
movq %rcx, (%rax)
movq -0x8(%rbp), %rax
movq 0x98(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x10(%rbp), %rcx
addq $0x8, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x98(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x8(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x20(%rax)
movq -0x28(%rbp), %rdi
callq 0xf8da0
xorl %eax, %eax
cmpl $0x7, -0x14(%rbp)
movb %al, -0x3a(%rbp)
jne 0xf8045
movq -0x8(%rbp), %rax
movq 0x80(%rax), %rcx
movq %rcx, -0x10(%rbp)
xorl %eax, %eax
cmpq $0x0, %rcx
movb %al, -0x3a(%rbp)
je 0xf8045
movq -0x10(%rbp), %rax
cmpl $0x7, 0x40(%rax)
sete %al
movb %al, -0x3a(%rbp)
movb -0x3a(%rbp), %al
testb $0x1, %al
jne 0xf7f6b
movq -0x8(%rbp), %rax
cmpq $0x0, 0x60(%rax)
je 0xf808c
movq -0x8(%rbp), %rax
movq %rax, -0x48(%rbp)
movb $0x1, %al
cmpl $0x8, -0x14(%rbp)
movb %al, -0x3b(%rbp)
je 0xf8078
cmpl $0x7, -0x14(%rbp)
sete %al
movb %al, -0x3b(%rbp)
movq -0x48(%rbp), %rdi
movb -0x3b(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movsbl %al, %esi
callq 0xf9720
jmp 0xf80ad
cmpq $0x0, -0x10(%rbp)
jne 0xf80ab
movq -0x8(%rbp), %rax
cmpq $0x0, 0x60(%rax)
je 0xf80ab
movq -0x8(%rbp), %rdi
xorl %esi, %esi
callq 0xf9720
jmp 0xf80ad
jmp 0xf80af
jmp 0xf80b1
jmp 0xf80b3
jmp 0xf80b5
jmp 0xf80b7
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax)
| wake_up_waiters:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
cmp qword ptr [rax+90h], 0
jnz loc_F80B1
mov rax, [rbp+var_8]
mov rax, [rax+80h]
mov [rbp+var_10], rax
mov rax, [rbp+var_8]
cmp qword ptr [rax+70h], 0
jnz loc_F7EE5
cmp [rbp+var_10], 0
jz loc_F7E82
mov rax, [rbp+var_10]
cmp dword ptr [rax+40h], 0Bh
jnz short loc_F7CFE
mov rax, [rbp+var_8]
cmp qword ptr [rax+60h], 0
jz short loc_F7CFE
mov rax, [rbp+var_8]
mov rax, [rax+60h]
cmp dword ptr [rax+40h], 4
jge loc_F7E82
loc_F7CFE:
mov rcx, [rbp+var_8]
mov rax, [rcx+0A0h]
mov rdx, rax
add rdx, 1
mov [rcx+0A0h], rdx
lea rcx, max_write_lock_count
cmp rax, [rcx]
jbe short loc_F7D53
mov rax, [rbp+var_8]
mov qword ptr [rax+0A0h], 0
mov rax, [rbp+var_8]
cmp qword ptr [rax+60h], 0
jz short loc_F7D51
jmp short $+2
loc_F7D3F:
jmp short $+2
loc_F7D41:
mov rdi, [rbp+var_8]
xor esi, esi
call free_all_read_locks
jmp loc_F80B3
loc_F7D51:
jmp short $+2
loc_F7D53:
jmp short $+2
loc_F7D55:
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov rcx, [rbp+var_10]
mov rcx, [rcx+10h]
mov [rcx], rax
cmp rax, 0
jz short loc_F7D84
mov rax, [rbp+var_10]
mov rcx, [rax+10h]
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov [rax+10h], rcx
jmp short loc_F7D97
loc_F7D84:
mov rax, [rbp+var_10]
mov rcx, [rax+10h]
mov rax, [rbp+var_8]
mov [rax+88h], rcx
loc_F7D97:
mov rcx, [rbp+var_10]
mov rax, [rbp+var_8]
mov rax, [rax+98h]
mov [rax], rcx
mov rax, [rbp+var_8]
mov rcx, [rax+98h]
mov rax, [rbp+var_10]
mov [rax+10h], rcx
mov rax, [rbp+var_10]
mov qword ptr [rax+8], 0
mov rcx, [rbp+var_10]
add rcx, 8
mov rax, [rbp+var_8]
mov [rax+98h], rcx
mov rax, [rbp+var_10]
cmp dword ptr [rax+40h], 8
jnz short loc_F7E0D
mov rax, [rbp+var_8]
mov rax, [rax+0D8h]
mov rcx, [rbp+var_10]
mov rdi, [rcx+28h]
call rax
movsx eax, al
cmp eax, 0
jz short loc_F7E0D
mov rax, [rbp+var_10]
mov dword ptr [rax+40h], 0Dh
loc_F7E0D:
jmp short $+2
loc_F7E0F:
jmp short $+2
loc_F7E11:
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov [rbp+var_20], rax
mov rax, [rbp+var_10]
mov qword ptr [rax+20h], 0
mov rdi, [rbp+var_20]
call inline_mysql_cond_signal_4
mov rax, [rbp+var_10]
cmp dword ptr [rax+40h], 7
jnz short loc_F7E5B
mov rax, [rbp+var_8]
cmp qword ptr [rax+80h], 0
jz short loc_F7E5B
mov rax, [rbp+var_8]
mov rax, [rax+80h]
cmp dword ptr [rax+40h], 7
jz short loc_F7E5D
loc_F7E5B:
jmp short loc_F7E71
loc_F7E5D:
mov rax, [rbp+var_8]
mov rax, [rax+80h]
mov [rbp+var_10], rax
jmp loc_F7D55
loc_F7E71:
mov rax, [rbp+var_10]
cmp dword ptr [rax+40h], 0Bh
jl short loc_F7E80
jmp loc_F80B3
loc_F7E80:
jmp short $+2
loc_F7E82:
mov rax, [rbp+var_8]
cmp qword ptr [rax+60h], 0
jz short loc_F7EDA
mov rax, [rbp+var_8]
mov [rbp+var_38], rax
xor eax, eax
cmp [rbp+var_10], 0
mov [rbp+var_29], al
jz short loc_F7EC4
mov rcx, [rbp+var_10]
mov al, 1
cmp dword ptr [rcx+40h], 8
mov [rbp+var_39], al
jz short loc_F7EBE
mov rax, [rbp+var_10]
cmp dword ptr [rax+40h], 7
setz al
mov [rbp+var_39], al
loc_F7EBE:
mov al, [rbp+var_39]
mov [rbp+var_29], al
loc_F7EC4:
mov rdi, [rbp+var_38]
mov al, [rbp+var_29]
and al, 1
movzx eax, al
movsx esi, al
call free_all_read_locks
jmp short loc_F7EE0
loc_F7EDA:
jmp short $+2
loc_F7EDC:
jmp short $+2
loc_F7EDE:
jmp short $+2
loc_F7EE0:
jmp loc_F80AF
loc_F7EE5:
cmp [rbp+var_10], 0
jz loc_F808E
mov rax, [rbp+var_10]
mov eax, [rax+40h]
mov [rbp+var_14], eax
cmp eax, 9
jg loc_F808E
cmp [rbp+var_14], 8
jz short loc_F7F0F
cmp [rbp+var_14], 7
jnz short loc_F7F20
loc_F7F0F:
mov rax, [rbp+var_8]
cmp dword ptr [rax+0A8h], 0
jnz loc_F808E
loc_F7F20:
cmp [rbp+var_14], 8
jnz short loc_F7F69
mov rax, [rbp+var_8]
mov rax, [rax+0D8h]
mov rcx, [rbp+var_10]
mov rdi, [rcx+28h]
call rax
movsx eax, al
cmp eax, 0
jz short loc_F7F69
mov rax, [rbp+var_10]
mov dword ptr [rax+40h], 0Dh
mov rax, [rbp+var_8]
cmp qword ptr [rax+60h], 0
jz short loc_F7F64
mov rdi, [rbp+var_8]
xor esi, esi
call free_all_read_locks
loc_F7F64:
jmp loc_F80B3
loc_F7F69:
jmp short $+2
loc_F7F6B:
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov [rbp+var_28], rax
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov rcx, [rbp+var_10]
mov rcx, [rcx+10h]
mov [rcx], rax
cmp rax, 0
jz short loc_F7FA6
mov rax, [rbp+var_10]
mov rcx, [rax+10h]
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov [rax+10h], rcx
jmp short loc_F7FB9
loc_F7FA6:
mov rax, [rbp+var_10]
mov rcx, [rax+10h]
mov rax, [rbp+var_8]
mov [rax+88h], rcx
loc_F7FB9:
mov rcx, [rbp+var_10]
mov rax, [rbp+var_8]
mov rax, [rax+98h]
mov [rax], rcx
mov rax, [rbp+var_8]
mov rcx, [rax+98h]
mov rax, [rbp+var_10]
mov [rax+10h], rcx
mov rcx, [rbp+var_10]
add rcx, 8
mov rax, [rbp+var_8]
mov [rax+98h], rcx
mov rax, [rbp+var_10]
mov qword ptr [rax+8], 0
mov rax, [rbp+var_10]
mov qword ptr [rax+20h], 0
mov rdi, [rbp+var_28]
call inline_mysql_cond_signal_4
xor eax, eax
cmp [rbp+var_14], 7
mov [rbp+var_3A], al
jnz short loc_F8045
mov rax, [rbp+var_8]
mov rcx, [rax+80h]
mov [rbp+var_10], rcx
xor eax, eax
cmp rcx, 0
mov [rbp+var_3A], al
jz short loc_F8045
mov rax, [rbp+var_10]
cmp dword ptr [rax+40h], 7
setz al
mov [rbp+var_3A], al
loc_F8045:
mov al, [rbp+var_3A]
test al, 1
jnz loc_F7F6B
mov rax, [rbp+var_8]
cmp qword ptr [rax+60h], 0
jz short loc_F808C
mov rax, [rbp+var_8]
mov [rbp+var_48], rax
mov al, 1
cmp [rbp+var_14], 8
mov [rbp+var_3B], al
jz short loc_F8078
cmp [rbp+var_14], 7
setz al
mov [rbp+var_3B], al
loc_F8078:
mov rdi, [rbp+var_48]
mov al, [rbp+var_3B]
and al, 1
movzx eax, al
movsx esi, al
call free_all_read_locks
loc_F808C:
jmp short loc_F80AD
loc_F808E:
cmp [rbp+var_10], 0
jnz short loc_F80AB
mov rax, [rbp+var_8]
cmp qword ptr [rax+60h], 0
jz short loc_F80AB
mov rdi, [rbp+var_8]
xor esi, esi
call free_all_read_locks
loc_F80AB:
jmp short $+2
loc_F80AD:
jmp short $+2
loc_F80AF:
jmp short $+2
loc_F80B1:
jmp short $+2
loc_F80B3:
jmp short $+2
loc_F80B5:
jmp short $+2
loc_F80B7:
add rsp, 50h
pop rbp
retn
| long long wake_up_waiters(long long a1)
{
long long result; // rax
unsigned long long v2; // rax
long long v3; // rax
long long v4; // rax
bool v5; // [rsp+15h] [rbp-3Bh]
bool v6; // [rsp+16h] [rbp-3Ah]
bool v7; // [rsp+17h] [rbp-39h]
bool v8; // [rsp+27h] [rbp-29h]
long long v9; // [rsp+28h] [rbp-28h]
long long v10; // [rsp+30h] [rbp-20h]
int v11; // [rsp+3Ch] [rbp-14h]
long long v12; // [rsp+40h] [rbp-10h]
result = a1;
if ( *(_QWORD *)(a1 + 144) )
return result;
v12 = *(_QWORD *)(a1 + 128);
result = a1;
if ( *(_QWORD *)(a1 + 112) )
{
if ( v12 )
{
result = *(unsigned int *)(v12 + 64);
v11 = result;
if ( (int)result <= 9 )
{
if ( (_DWORD)result != 8 && (_DWORD)result != 7 || (result = a1, !*(_DWORD *)(a1 + 168)) )
{
if ( v11 == 8 && (*(unsigned __int8 ( **)(_QWORD))(a1 + 216))(*(_QWORD *)(v12 + 40)) )
{
*(_DWORD *)(v12 + 64) = 13;
result = a1;
if ( *(_QWORD *)(a1 + 96) )
return free_all_read_locks(a1, 0LL);
}
else
{
do
{
v9 = *(_QWORD *)(v12 + 32);
v4 = *(_QWORD *)(v12 + 8);
**(_QWORD **)(v12 + 16) = v4;
if ( v4 )
*(_QWORD *)(*(_QWORD *)(v12 + 8) + 16LL) = *(_QWORD *)(v12 + 16);
else
*(_QWORD *)(a1 + 136) = *(_QWORD *)(v12 + 16);
**(_QWORD **)(a1 + 152) = v12;
*(_QWORD *)(v12 + 16) = *(_QWORD *)(a1 + 152);
*(_QWORD *)(a1 + 152) = v12 + 8;
*(_QWORD *)(v12 + 8) = 0LL;
*(_QWORD *)(v12 + 32) = 0LL;
inline_mysql_cond_signal_4(v9);
v6 = 0;
if ( v11 == 7 )
{
v12 = *(_QWORD *)(a1 + 128);
v6 = 0;
if ( v12 )
v6 = *(_DWORD *)(v12 + 64) == 7;
}
}
while ( v6 );
result = a1;
if ( *(_QWORD *)(a1 + 96) )
{
v5 = 1;
if ( v11 != 8 )
v5 = v11 == 7;
return free_all_read_locks(a1, v5);
}
}
return result;
}
}
}
if ( v12 )
return result;
result = a1;
if ( !*(_QWORD *)(a1 + 96) )
return result;
return free_all_read_locks(a1, 0LL);
}
if ( !v12 || *(_DWORD *)(v12 + 64) == 11 && *(_QWORD *)(a1 + 96) && *(int *)(*(_QWORD *)(a1 + 96) + 64LL) >= 4 )
{
LABEL_21:
result = a1;
if ( *(_QWORD *)(a1 + 96) )
{
v8 = 0;
if ( v12 )
{
v7 = 1;
if ( *(_DWORD *)(v12 + 64) != 8 )
v7 = *(_DWORD *)(v12 + 64) == 7;
v8 = v7;
}
return free_all_read_locks(a1, v8);
}
return result;
}
v2 = *(_QWORD *)(a1 + 160);
*(_QWORD *)(a1 + 160) = v2 + 1;
if ( v2 > max_write_lock_count )
{
*(_QWORD *)(a1 + 160) = 0LL;
if ( *(_QWORD *)(a1 + 96) )
return free_all_read_locks(a1, 0LL);
}
while ( 1 )
{
v3 = *(_QWORD *)(v12 + 8);
**(_QWORD **)(v12 + 16) = v3;
if ( v3 )
*(_QWORD *)(*(_QWORD *)(v12 + 8) + 16LL) = *(_QWORD *)(v12 + 16);
else
*(_QWORD *)(a1 + 136) = *(_QWORD *)(v12 + 16);
**(_QWORD **)(a1 + 152) = v12;
*(_QWORD *)(v12 + 16) = *(_QWORD *)(a1 + 152);
*(_QWORD *)(v12 + 8) = 0LL;
*(_QWORD *)(a1 + 152) = v12 + 8;
if ( *(_DWORD *)(v12 + 64) == 8 && (*(unsigned __int8 ( **)(_QWORD))(a1 + 216))(*(_QWORD *)(v12 + 40)) )
*(_DWORD *)(v12 + 64) = 13;
v10 = *(_QWORD *)(v12 + 32);
*(_QWORD *)(v12 + 32) = 0LL;
inline_mysql_cond_signal_4(v10);
if ( *(_DWORD *)(v12 + 64) != 7 || !*(_QWORD *)(a1 + 128) || *(_DWORD *)(*(_QWORD *)(a1 + 128) + 64LL) != 7 )
break;
v12 = *(_QWORD *)(a1 + 128);
}
result = v12;
if ( *(int *)(v12 + 64) < 11 )
goto LABEL_21;
return result;
}
| wake_up_waiters:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x90],0x0
JNZ 0x001f80b1
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x80]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x70],0x0
JNZ 0x001f7ee5
CMP qword ptr [RBP + -0x10],0x0
JZ 0x001f7e82
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x40],0xb
JNZ 0x001f7cfe
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x60],0x0
JZ 0x001f7cfe
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x60]
CMP dword ptr [RAX + 0x40],0x4
JGE 0x001f7e82
LAB_001f7cfe:
MOV RCX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RCX + 0xa0]
MOV RDX,RAX
ADD RDX,0x1
MOV qword ptr [RCX + 0xa0],RDX
LEA RCX,[0x3bfc58]
CMP RAX,qword ptr [RCX]
JBE 0x001f7d53
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0xa0],0x0
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x60],0x0
JZ 0x001f7d51
JMP 0x001f7d3f
LAB_001f7d3f:
JMP 0x001f7d41
LAB_001f7d41:
MOV RDI,qword ptr [RBP + -0x8]
XOR ESI,ESI
CALL 0x001f9720
JMP 0x001f80b3
LAB_001f7d51:
JMP 0x001f7d53
LAB_001f7d53:
JMP 0x001f7d55
LAB_001f7d55:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x10]
MOV qword ptr [RCX],RAX
CMP RAX,0x0
JZ 0x001f7d84
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RAX + 0x10],RCX
JMP 0x001f7d97
LAB_001f7d84:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x88],RCX
LAB_001f7d97:
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x98]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x98]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x10],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x8],0x0
MOV RCX,qword ptr [RBP + -0x10]
ADD RCX,0x8
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x98],RCX
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x40],0x8
JNZ 0x001f7e0d
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xd8]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RCX + 0x28]
CALL RAX
MOVSX EAX,AL
CMP EAX,0x0
JZ 0x001f7e0d
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x40],0xd
LAB_001f7e0d:
JMP 0x001f7e0f
LAB_001f7e0f:
JMP 0x001f7e11
LAB_001f7e11:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x20],0x0
MOV RDI,qword ptr [RBP + -0x20]
CALL 0x001f8da0
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x40],0x7
JNZ 0x001f7e5b
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x80],0x0
JZ 0x001f7e5b
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x80]
CMP dword ptr [RAX + 0x40],0x7
JZ 0x001f7e5d
LAB_001f7e5b:
JMP 0x001f7e71
LAB_001f7e5d:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x80]
MOV qword ptr [RBP + -0x10],RAX
JMP 0x001f7d55
LAB_001f7e71:
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x40],0xb
JL 0x001f7e80
JMP 0x001f80b3
LAB_001f7e80:
JMP 0x001f7e82
LAB_001f7e82:
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x60],0x0
JZ 0x001f7eda
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x38],RAX
XOR EAX,EAX
CMP qword ptr [RBP + -0x10],0x0
MOV byte ptr [RBP + -0x29],AL
JZ 0x001f7ec4
MOV RCX,qword ptr [RBP + -0x10]
MOV AL,0x1
CMP dword ptr [RCX + 0x40],0x8
MOV byte ptr [RBP + -0x39],AL
JZ 0x001f7ebe
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x40],0x7
SETZ AL
MOV byte ptr [RBP + -0x39],AL
LAB_001f7ebe:
MOV AL,byte ptr [RBP + -0x39]
MOV byte ptr [RBP + -0x29],AL
LAB_001f7ec4:
MOV RDI,qword ptr [RBP + -0x38]
MOV AL,byte ptr [RBP + -0x29]
AND AL,0x1
MOVZX EAX,AL
MOVSX ESI,AL
CALL 0x001f9720
JMP 0x001f7ee0
LAB_001f7eda:
JMP 0x001f7edc
LAB_001f7edc:
JMP 0x001f7ede
LAB_001f7ede:
JMP 0x001f7ee0
LAB_001f7ee0:
JMP 0x001f80af
LAB_001f7ee5:
CMP qword ptr [RBP + -0x10],0x0
JZ 0x001f808e
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x40]
MOV dword ptr [RBP + -0x14],EAX
CMP EAX,0x9
JG 0x001f808e
CMP dword ptr [RBP + -0x14],0x8
JZ 0x001f7f0f
CMP dword ptr [RBP + -0x14],0x7
JNZ 0x001f7f20
LAB_001f7f0f:
MOV RAX,qword ptr [RBP + -0x8]
CMP dword ptr [RAX + 0xa8],0x0
JNZ 0x001f808e
LAB_001f7f20:
CMP dword ptr [RBP + -0x14],0x8
JNZ 0x001f7f69
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xd8]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RCX + 0x28]
CALL RAX
MOVSX EAX,AL
CMP EAX,0x0
JZ 0x001f7f69
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x40],0xd
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x60],0x0
JZ 0x001f7f64
MOV RDI,qword ptr [RBP + -0x8]
XOR ESI,ESI
CALL 0x001f9720
LAB_001f7f64:
JMP 0x001f80b3
LAB_001f7f69:
JMP 0x001f7f6b
LAB_001f7f6b:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x10]
MOV qword ptr [RCX],RAX
CMP RAX,0x0
JZ 0x001f7fa6
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RAX + 0x10],RCX
JMP 0x001f7fb9
LAB_001f7fa6:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x88],RCX
LAB_001f7fb9:
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x98]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x98]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x10],RCX
MOV RCX,qword ptr [RBP + -0x10]
ADD RCX,0x8
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x98],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x8],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x20],0x0
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x001f8da0
XOR EAX,EAX
CMP dword ptr [RBP + -0x14],0x7
MOV byte ptr [RBP + -0x3a],AL
JNZ 0x001f8045
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x80]
MOV qword ptr [RBP + -0x10],RCX
XOR EAX,EAX
CMP RCX,0x0
MOV byte ptr [RBP + -0x3a],AL
JZ 0x001f8045
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x40],0x7
SETZ AL
MOV byte ptr [RBP + -0x3a],AL
LAB_001f8045:
MOV AL,byte ptr [RBP + -0x3a]
TEST AL,0x1
JNZ 0x001f7f6b
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x60],0x0
JZ 0x001f808c
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x48],RAX
MOV AL,0x1
CMP dword ptr [RBP + -0x14],0x8
MOV byte ptr [RBP + -0x3b],AL
JZ 0x001f8078
CMP dword ptr [RBP + -0x14],0x7
SETZ AL
MOV byte ptr [RBP + -0x3b],AL
LAB_001f8078:
MOV RDI,qword ptr [RBP + -0x48]
MOV AL,byte ptr [RBP + -0x3b]
AND AL,0x1
MOVZX EAX,AL
MOVSX ESI,AL
CALL 0x001f9720
LAB_001f808c:
JMP 0x001f80ad
LAB_001f808e:
CMP qword ptr [RBP + -0x10],0x0
JNZ 0x001f80ab
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x60],0x0
JZ 0x001f80ab
MOV RDI,qword ptr [RBP + -0x8]
XOR ESI,ESI
CALL 0x001f9720
LAB_001f80ab:
JMP 0x001f80ad
LAB_001f80ad:
JMP 0x001f80af
LAB_001f80af:
JMP 0x001f80b1
LAB_001f80b1:
JMP 0x001f80b3
LAB_001f80b3:
JMP 0x001f80b5
LAB_001f80b5:
JMP 0x001f80b7
LAB_001f80b7:
ADD RSP,0x50
POP RBP
RET
|
void wake_up_waiters(long param_1)
{
int iVar1;
ulong uVar2;
long lVar3;
int8 uVar4;
char cVar5;
bool bVar6;
bool local_43;
bool local_41;
bool local_31;
long local_18;
if (*(long *)(param_1 + 0x90) == 0) {
local_18 = *(long *)(param_1 + 0x80);
if (*(long *)(param_1 + 0x70) == 0) {
if ((local_18 != 0) &&
(((*(int *)(local_18 + 0x40) != 0xb || (*(long *)(param_1 + 0x60) == 0)) ||
(*(int *)(*(long *)(param_1 + 0x60) + 0x40) < 4)))) {
uVar2 = *(ulong *)(param_1 + 0xa0);
*(ulong *)(param_1 + 0xa0) = uVar2 + 1;
if ((max_write_lock_count < uVar2) &&
(*(int8 *)(param_1 + 0xa0) = 0, *(long *)(param_1 + 0x60) != 0)) {
free_all_read_locks(param_1,0);
return;
}
while( true ) {
lVar3 = *(long *)(local_18 + 8);
**(long **)(local_18 + 0x10) = lVar3;
if (lVar3 == 0) {
*(int8 *)(param_1 + 0x88) = *(int8 *)(local_18 + 0x10);
}
else {
*(int8 *)(*(long *)(local_18 + 8) + 0x10) = *(int8 *)(local_18 + 0x10);
}
**(long **)(param_1 + 0x98) = local_18;
*(int8 *)(local_18 + 0x10) = *(int8 *)(param_1 + 0x98);
*(int8 *)(local_18 + 8) = 0;
*(long *)(param_1 + 0x98) = local_18 + 8;
if ((*(int *)(local_18 + 0x40) == 8) &&
(cVar5 = (**(code **)(param_1 + 0xd8))(*(int8 *)(local_18 + 0x28)), cVar5 != '\0'
)) {
*(int4 *)(local_18 + 0x40) = 0xd;
}
uVar4 = *(int8 *)(local_18 + 0x20);
*(int8 *)(local_18 + 0x20) = 0;
inline_mysql_cond_signal(uVar4);
if (((*(int *)(local_18 + 0x40) != 7) || (*(long *)(param_1 + 0x80) == 0)) ||
(*(int *)(*(long *)(param_1 + 0x80) + 0x40) != 7)) break;
local_18 = *(long *)(param_1 + 0x80);
}
if (10 < *(int *)(local_18 + 0x40)) {
return;
}
}
if (*(long *)(param_1 + 0x60) != 0) {
local_31 = false;
if (local_18 != 0) {
local_41 = true;
if (*(int *)(local_18 + 0x40) != 8) {
local_41 = *(int *)(local_18 + 0x40) == 7;
}
local_31 = local_41;
}
free_all_read_locks(param_1,local_31);
}
}
else if (((local_18 == 0) || (iVar1 = *(int *)(local_18 + 0x40), 9 < iVar1)) ||
(((iVar1 == 8 || (iVar1 == 7)) && (*(int *)(param_1 + 0xa8) != 0)))) {
if ((local_18 == 0) && (*(long *)(param_1 + 0x60) != 0)) {
free_all_read_locks(param_1,0);
}
}
else if ((iVar1 == 8) &&
(cVar5 = (**(code **)(param_1 + 0xd8))(*(int8 *)(local_18 + 0x28)), cVar5 != '\0')
) {
*(int4 *)(local_18 + 0x40) = 0xd;
if (*(long *)(param_1 + 0x60) != 0) {
free_all_read_locks(param_1,0);
}
}
else {
do {
uVar4 = *(int8 *)(local_18 + 0x20);
lVar3 = *(long *)(local_18 + 8);
**(long **)(local_18 + 0x10) = lVar3;
if (lVar3 == 0) {
*(int8 *)(param_1 + 0x88) = *(int8 *)(local_18 + 0x10);
}
else {
*(int8 *)(*(long *)(local_18 + 8) + 0x10) = *(int8 *)(local_18 + 0x10);
}
**(long **)(param_1 + 0x98) = local_18;
*(int8 *)(local_18 + 0x10) = *(int8 *)(param_1 + 0x98);
*(long *)(param_1 + 0x98) = local_18 + 8;
*(int8 *)(local_18 + 8) = 0;
*(int8 *)(local_18 + 0x20) = 0;
inline_mysql_cond_signal(uVar4);
bVar6 = false;
if (iVar1 == 7) {
local_18 = *(long *)(param_1 + 0x80);
bVar6 = false;
if (local_18 != 0) {
bVar6 = *(int *)(local_18 + 0x40) == 7;
}
}
} while (bVar6);
if (*(long *)(param_1 + 0x60) != 0) {
local_43 = iVar1 == 8 || iVar1 == 7;
free_all_read_locks(param_1,local_43);
}
}
}
return;
}
| |
55,579 | strmake | eloqsql/strings/strmake.c | char *strmake(register char *dst, register const char *src, size_t length)
{
while (length--)
{
if (! (*dst++ = *src++))
{
#ifdef EXTRA_DEBUG
/*
'length' is the maximum length of the string; the buffer needs
to be one character larger to accommodate the terminating
'\0'. This is easy to get wrong, so we make sure we write to
the entire length of the buffer to identify incorrect
buffer-sizes. We only initialism the "unused" part of the
buffer here, a) for efficiency, and b) because dst==src is
allowed, so initializing the entire buffer would overwrite the
source-string. Also, we write a character rather than '\0' as
this makes spotting these problems in the results easier.
If we are using purify/valgrind, we only set one character at
end to be able to detect also wrong accesses after the end of
dst.
*/
if (length)
{
#ifdef HAVE_valgrind
dst[length-1]= 'Z';
#else
bfill(dst, length-1, (int) 'Z');
#endif /* HAVE_valgrind */
}
#endif /* EXTRA_DEBUG */
return dst-1;
}
}
*dst=0;
return dst;
} | O3 | c | strmake:
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rax
xorl %edi, %edi
movq %rdi, %rcx
cmpq %rdi, %rdx
je 0xd70e0
movb (%rsi,%rcx), %r8b
movb %r8b, (%rax,%rcx)
leaq 0x1(%rcx), %rdi
testb %r8b, %r8b
jne 0xd70c5
jmp 0xd70e4
movb $0x0, (%rax,%rcx)
addq %rcx, %rax
popq %rbp
retq
nopl (%rax)
| strmake:
push rbp
mov rbp, rsp
mov rax, rdi
xor edi, edi
loc_D70C5:
mov rcx, rdi
cmp rdx, rdi
jz short loc_D70E0
mov r8b, [rsi+rcx]
mov [rax+rcx], r8b
lea rdi, [rcx+1]
test r8b, r8b
jnz short loc_D70C5
jmp short loc_D70E4
loc_D70E0:
mov byte ptr [rax+rcx], 0
loc_D70E4:
add rax, rcx
pop rbp
retn
| long long strmake(long long a1, long long a2, long long a3)
{
long long v4; // rdi
long long v5; // rcx
char v6; // r8
v4 = 0LL;
while ( 1 )
{
v5 = v4;
if ( a3 == v4 )
break;
v6 = *(_BYTE *)(a2 + v4);
*(_BYTE *)(a1 + v4++) = v6;
if ( !v6 )
return v5 + a1;
}
*(_BYTE *)(a1 + v4) = 0;
return v5 + a1;
}
| strmake:
PUSH RBP
MOV RBP,RSP
MOV RAX,RDI
XOR EDI,EDI
LAB_001d70c5:
MOV RCX,RDI
CMP RDX,RDI
JZ 0x001d70e0
MOV R8B,byte ptr [RSI + RCX*0x1]
MOV byte ptr [RAX + RCX*0x1],R8B
LEA RDI,[RCX + 0x1]
TEST R8B,R8B
JNZ 0x001d70c5
JMP 0x001d70e4
LAB_001d70e0:
MOV byte ptr [RAX + RCX*0x1],0x0
LAB_001d70e4:
ADD RAX,RCX
POP RBP
RET
|
long strmake(long param_1,long param_2,long param_3)
{
char cVar1;
long lVar2;
long lVar3;
lVar2 = 0;
do {
lVar3 = lVar2;
if (param_3 == lVar3) {
*(int1 *)(param_1 + lVar3) = 0;
break;
}
cVar1 = *(char *)(param_2 + lVar3);
*(char *)(param_1 + lVar3) = cVar1;
lVar2 = lVar3 + 1;
} while (cVar1 != '\0');
return param_1 + lVar3;
}
| |
55,580 | google::protobuf::util::converter::JsonObjectWriter::RenderFloat(google::protobuf::stringpiece_internal::StringPiece, float) | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/util/internal/json_objectwriter.cc | JsonObjectWriter* JsonObjectWriter::RenderFloat(StringPiece name,
float value) {
if (std::isfinite(value)) {
return RenderSimple(name, SimpleFtoa(value));
}
// Render quoted with NaN/Infinity-aware FloatAsString.
return RenderString(name, FloatAsString(value));
} | O0 | cpp | google::protobuf::util::converter::JsonObjectWriter::RenderFloat(google::protobuf::stringpiece_internal::StringPiece, float):
subq $0xe8, %rsp
movq %rsi, 0xd0(%rsp)
movq %rdx, 0xd8(%rsp)
movq %rdi, 0xc8(%rsp)
movss %xmm0, 0xc4(%rsp)
movq 0xc8(%rsp), %rax
movq %rax, 0x28(%rsp)
movss 0xc4(%rsp), %xmm0
callq 0x1a1120
testb $0x1, %al
jne 0x59965c
jmp 0x59970b
movups 0xd0(%rsp), %xmm0
movaps %xmm0, 0xb0(%rsp)
movss 0xc4(%rsp), %xmm0
leaq 0x80(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0x3f5e60
movq 0x20(%rsp), %rsi
leaq 0xa0(%rsp), %rdi
callq 0x3b7cf0
jmp 0x59969b
movq 0x28(%rsp), %rdi
movq 0xb0(%rsp), %rsi
movq 0xb8(%rsp), %rdx
movq 0xa0(%rsp), %rcx
movq 0xa8(%rsp), %r8
callq 0x599e50
movq %rax, 0x18(%rsp)
jmp 0x5996cc
movq 0x18(%rsp), %rax
movq %rax, 0xe0(%rsp)
leaq 0x80(%rsp), %rdi
callq 0x19b990
jmp 0x59979d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x78(%rsp)
movl %eax, 0x74(%rsp)
leaq 0x80(%rsp), %rdi
callq 0x19b990
jmp 0x5997ad
movups 0xd0(%rsp), %xmm0
movaps %xmm0, 0x60(%rsp)
movss 0xc4(%rsp), %xmm0
leaq 0x30(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x5c19b0
movq 0x10(%rsp), %rsi
leaq 0x50(%rsp), %rdi
callq 0x3b7cf0
jmp 0x599741
movq 0x28(%rsp), %rdi
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
movq 0x50(%rsp), %rcx
movq 0x58(%rsp), %r8
movq (%rdi), %rax
movq 0x68(%rax), %rax
callq *%rax
movq %rax, 0x8(%rsp)
jmp 0x59976a
movq 0x8(%rsp), %rax
movq %rax, 0xe0(%rsp)
leaq 0x30(%rsp), %rdi
callq 0x19b990
jmp 0x59979d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x78(%rsp)
movl %eax, 0x74(%rsp)
leaq 0x30(%rsp), %rdi
callq 0x19b990
jmp 0x5997ad
movq 0xe0(%rsp), %rax
addq $0xe8, %rsp
retq
movq 0x78(%rsp), %rdi
callq 0x198ce0
nopw (%rax,%rax)
| _ZN6google8protobuf4util9converter16JsonObjectWriter11RenderFloatENS0_20stringpiece_internal11StringPieceEf:
sub rsp, 0E8h
mov qword ptr [rsp+0E8h+var_18], rsi
mov qword ptr [rsp+0E8h+var_18+8], rdx
mov [rsp+0E8h+var_20], rdi
movss [rsp+0E8h+var_24], xmm0
mov rax, [rsp+0E8h+var_20]
mov [rsp+0E8h+var_C0], rax
movss xmm0, [rsp+0E8h+var_24]; float
call __ZSt8isfinitef; std::isfinite(float)
test al, 1
jnz short loc_59965C
jmp loc_59970B
loc_59965C:
movups xmm0, [rsp+0E8h+var_18]
movaps [rsp+0E8h+var_38], xmm0
movss xmm0, [rsp+0E8h+var_24]
lea rdi, [rsp+0E8h+var_68]
mov [rsp+0E8h+var_C8], rdi
call _ZN6google8protobuf10SimpleFtoaB5cxx11Ef; google::protobuf::SimpleFtoa(float)
mov rsi, [rsp+0E8h+var_C8]
lea rdi, [rsp+0E8h+var_48]
call _ZN6google8protobuf20stringpiece_internal11StringPieceC2ISaIcEEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcET_EE; google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(std::string const&)
jmp short $+2
loc_59969B:
mov rdi, [rsp+0E8h+var_C0]
mov rsi, qword ptr [rsp+0E8h+var_38]
mov rdx, qword ptr [rsp+0E8h+var_38+8]
mov rcx, [rsp+0E8h+var_48]
mov r8, [rsp+0E8h+var_40]
call _ZN6google8protobuf4util9converter16JsonObjectWriter12RenderSimpleENS0_20stringpiece_internal11StringPieceES5_; google::protobuf::util::converter::JsonObjectWriter::RenderSimple(google::protobuf::stringpiece_internal::StringPiece,google::protobuf::stringpiece_internal::StringPiece)
mov [rsp+0E8h+var_D0], rax
jmp short $+2
loc_5996CC:
mov rax, [rsp+0E8h+var_D0]
mov [rsp+0E8h+var_8], rax
lea rdi, [rsp+0E8h+var_68]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_59979D
mov rcx, rax
mov eax, edx
mov [rsp+arg_70], rcx
mov [rsp+arg_6C], eax
lea rdi, [rsp+arg_78]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_5997AD
loc_59970B:
movups xmm0, [rsp+0E8h+var_18]
movaps [rsp+0E8h+var_88], xmm0
movss xmm0, [rsp+0E8h+var_24]
lea rdi, [rsp+0E8h+var_B8]
mov [rsp+0E8h+var_D8], rdi
call _ZN6google8protobuf4util9converter13FloatAsStringB5cxx11Ef; google::protobuf::util::converter::FloatAsString(float)
mov rsi, [rsp+0E8h+var_D8]
lea rdi, [rsp+0E8h+var_98]
call _ZN6google8protobuf20stringpiece_internal11StringPieceC2ISaIcEEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcET_EE; google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(std::string const&)
jmp short $+2
loc_599741:
mov rdi, [rsp+0E8h+var_C0]
mov rsi, qword ptr [rsp+0E8h+var_88]
mov rdx, qword ptr [rsp+0E8h+var_88+8]
mov rcx, [rsp+0E8h+var_98]
mov r8, [rsp+0E8h+var_90]
mov rax, [rdi]
mov rax, [rax+68h]
call rax
mov [rsp+0E8h+var_E0], rax
jmp short $+2
loc_59976A:
mov rax, [rsp+0E8h+var_E0]
mov [rsp+0E8h+var_8], rax
lea rdi, [rsp+0E8h+var_B8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_59979D
mov rcx, rax
mov eax, edx
mov [rsp+arg_70], rcx
mov [rsp+arg_6C], eax
lea rdi, [rsp+arg_28]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_5997AD
loc_59979D:
mov rax, [rsp+0E8h+var_8]
add rsp, 0E8h
retn
loc_5997AD:
mov rdi, [rsp+arg_70]
call __Unwind_Resume
| long long google::protobuf::util::converter::JsonObjectWriter::RenderFloat(
long long a1,
char *a2,
long long a3,
float a4)
{
_BYTE v5[32]; // [rsp+30h] [rbp-B8h] BYREF
_QWORD v6[2]; // [rsp+50h] [rbp-98h] BYREF
__int128 v7; // [rsp+60h] [rbp-88h]
_BYTE v8[32]; // [rsp+80h] [rbp-68h] BYREF
_QWORD v9[2]; // [rsp+A0h] [rbp-48h] BYREF
__int128 v10; // [rsp+B0h] [rbp-38h]
float v11; // [rsp+C4h] [rbp-24h]
long long v12; // [rsp+C8h] [rbp-20h]
__int128 v13; // [rsp+D0h] [rbp-18h]
long long v14; // [rsp+E0h] [rbp-8h]
*(_QWORD *)&v13 = a2;
*((_QWORD *)&v13 + 1) = a3;
v12 = a1;
v11 = a4;
if ( (std::isfinite(a4) & 1) != 0 )
{
v10 = v13;
google::protobuf::SimpleFtoa[abi:cxx11]((long long)v8, a2, v11);
google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(v9, (long long)v8);
v14 = google::protobuf::util::converter::JsonObjectWriter::RenderSimple(
a1,
v10,
*((_QWORD *)&v10 + 1),
v9[0],
v9[1]);
std::string::~string(v8);
}
else
{
v7 = v13;
google::protobuf::util::converter::FloatAsString[abi:cxx11](v11);
google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(v6, (long long)v5);
v14 = (*(long long ( **)(long long, _QWORD, _QWORD, _QWORD, _QWORD))(*(_QWORD *)a1 + 104LL))(
a1,
v7,
*((_QWORD *)&v7 + 1),
v6[0],
v6[1]);
std::string::~string(v5);
}
return v14;
}
| FindExtensionByName:
SUB RSP,0x48
MOV qword ptr [RSP + 0x40],RDI
MOV qword ptr [RSP + 0x38],RSI
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [RAX + 0x80]
MOV qword ptr [RSP + 0x8],RAX
MOV RSI,qword ptr [RSP + 0x38]
LEA RDI,[RSP + 0x18]
CALL 0x004b7cf0
MOV RDI,qword ptr [RSP + 0x8]
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RSP + 0x18]
MOV RCX,qword ptr [RSP + 0x20]
CALL 0x005d7530
MOV qword ptr [RSP + 0x28],RAX
LEA RDI,[RSP + 0x28]
CALL 0x005d5cf0
MOV qword ptr [RSP + 0x30],RAX
CMP qword ptr [RSP + 0x30],0x0
JZ 0x00599693
MOV RDI,qword ptr [RSP + 0x30]
CALL 0x0050f420
TEST AL,0x1
JNZ 0x00599688
JMP 0x00599693
LAB_00599688:
MOV RAX,qword ptr [RSP + 0x30]
MOV qword ptr [RSP],RAX
JMP 0x0059969b
LAB_00599693:
XOR EAX,EAX
MOV qword ptr [RSP],RAX
JMP 0x0059969b
LAB_0059969b:
MOV RAX,qword ptr [RSP]
ADD RSP,0x48
RET
|
/* google::protobuf::FileDescriptor::FindExtensionByName(std::__cxx11::string const&) const */
FieldDescriptor * __thiscall
google::protobuf::FileDescriptor::FindExtensionByName(FileDescriptor *this,string *param_1)
{
int8 uVar1;
ulong uVar2;
FieldDescriptor *local_48;
int8 local_30;
int8 local_28;
int8 local_20;
FieldDescriptor *local_18;
string *local_10;
FileDescriptor *local_8;
uVar1 = *(int8 *)(this + 0x80);
local_10 = param_1;
local_8 = this;
stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>
((StringPiece *)&local_30,param_1);
local_20 = FileDescriptorTables::FindNestedSymbol(uVar1,this,local_30,local_28);
local_18 = (FieldDescriptor *)Symbol::field_descriptor((Symbol *)&local_20);
if ((local_18 == (FieldDescriptor *)0x0) ||
(uVar2 = FieldDescriptor::is_extension(local_18), (uVar2 & 1) == 0)) {
local_48 = (FieldDescriptor *)0x0;
}
else {
local_48 = local_18;
}
return local_48;
}
| |
55,581 | inline_mysql_file_pwrite | eloqsql/include/mysql/psi/mysql_file.h | static inline size_t
inline_mysql_file_pwrite(
#ifdef HAVE_PSI_FILE_INTERFACE
const char *src_file, uint src_line,
#endif
File file, const uchar *buffer, size_t count, my_off_t offset, myf flags)
{
size_t result;
#ifdef HAVE_PSI_FILE_INTERFACE
struct PSI_file_locker *locker;
PSI_file_locker_state state;
size_t bytes_written;
locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_WRITE);
if (psi_likely(locker != NULL))
{
PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line);
result= my_pwrite(file, buffer, count, offset, flags);
if (flags & (MY_NABP | MY_FNABP))
bytes_written= (result == 0) ? count : 0;
else
bytes_written= (result != MY_FILE_ERROR) ? result : 0;
PSI_FILE_CALL(end_file_wait)(locker, bytes_written);
return result;
}
#endif
result= my_pwrite(file, buffer, count, offset, flags);
return result;
} | O0 | c | inline_mysql_file_pwrite:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq 0x10(%rbp), %rax
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
leaq 0x1de29c(%rip), %rax # 0x2c0248
movq (%rax), %rax
movq 0x158(%rax), %rax
movl -0x18(%rbp), %esi
leaq -0x88(%rbp), %rdi
movl $0x7, %edx
callq *%rax
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x40(%rbp)
setne %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0xe20bf
leaq 0x1de252(%rip), %rax # 0x2c0248
movq (%rax), %rax
movq 0x210(%rax), %rax
movq -0x40(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x10(%rbp), %rdx
movl -0x14(%rbp), %ecx
callq *%rax
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
movq -0x30(%rbp), %rcx
movq 0x10(%rbp), %r8
callq 0xf4a20
movq %rax, -0x38(%rbp)
movq 0x10(%rbp), %rax
andq $0x6, %rax
cmpq $0x0, %rax
je 0xe206a
cmpq $0x0, -0x38(%rbp)
jne 0xe204f
movq -0x28(%rbp), %rax
movq %rax, -0x98(%rbp)
jmp 0xe205a
xorl %eax, %eax
movq %rax, -0x98(%rbp)
jmp 0xe205a
movq -0x98(%rbp), %rax
movq %rax, -0x90(%rbp)
jmp 0xe2097
cmpq $-0x1, -0x38(%rbp)
je 0xe207e
movq -0x38(%rbp), %rax
movq %rax, -0xa0(%rbp)
jmp 0xe2089
xorl %eax, %eax
movq %rax, -0xa0(%rbp)
jmp 0xe2089
movq -0xa0(%rbp), %rax
movq %rax, -0x90(%rbp)
leaq 0x1de1aa(%rip), %rax # 0x2c0248
movq (%rax), %rax
movq 0x218(%rax), %rax
movq -0x40(%rbp), %rdi
movq -0x90(%rbp), %rsi
callq *%rax
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0xe20e3
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
movq -0x30(%rbp), %rcx
movq 0x10(%rbp), %r8
callq 0xf4a20
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0xa0, %rsp
popq %rbp
retq
| inline_mysql_file_pwrite_3:
push rbp
mov rbp, rsp
sub rsp, 0A0h
mov rax, [rbp+arg_0]
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov [rbp+var_30], r9
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+158h]
mov esi, [rbp+var_18]
lea rdi, [rbp+var_88]
mov edx, 7
call rax
mov [rbp+var_40], rax
cmp [rbp+var_40], 0
setnz al
and al, 1
movzx eax, al
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz loc_E20BF
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+210h]
mov rdi, [rbp+var_40]
mov rsi, [rbp+var_28]
mov rdx, [rbp+var_10]
mov ecx, [rbp+var_14]
call rax
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_28]
mov rcx, [rbp+var_30]
mov r8, [rbp+arg_0]
call my_pwrite
mov [rbp+var_38], rax
mov rax, [rbp+arg_0]
and rax, 6
cmp rax, 0
jz short loc_E206A
cmp [rbp+var_38], 0
jnz short loc_E204F
mov rax, [rbp+var_28]
mov [rbp+var_98], rax
jmp short loc_E205A
loc_E204F:
xor eax, eax
mov [rbp+var_98], rax
jmp short $+2
loc_E205A:
mov rax, [rbp+var_98]
mov [rbp+var_90], rax
jmp short loc_E2097
loc_E206A:
cmp [rbp+var_38], 0FFFFFFFFFFFFFFFFh
jz short loc_E207E
mov rax, [rbp+var_38]
mov [rbp+var_A0], rax
jmp short loc_E2089
loc_E207E:
xor eax, eax
mov [rbp+var_A0], rax
jmp short $+2
loc_E2089:
mov rax, [rbp+var_A0]
mov [rbp+var_90], rax
loc_E2097:
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+218h]
mov rdi, [rbp+var_40]
mov rsi, [rbp+var_90]
call rax
mov rax, [rbp+var_38]
mov [rbp+var_8], rax
jmp short loc_E20E3
loc_E20BF:
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_28]
mov rcx, [rbp+var_30]
mov r8, [rbp+arg_0]
call my_pwrite
mov [rbp+var_38], rax
mov rax, [rbp+var_38]
mov [rbp+var_8], rax
loc_E20E3:
mov rax, [rbp+var_8]
add rsp, 0A0h
pop rbp
retn
| long long inline_mysql_file_pwrite_3(
long long a1,
unsigned int a2,
unsigned int a3,
long long a4,
long long a5,
long long a6,
long long a7)
{
long long v8; // [rsp+0h] [rbp-A0h]
long long v9; // [rsp+8h] [rbp-98h]
_BYTE v10[72]; // [rsp+18h] [rbp-88h] BYREF
long long v11; // [rsp+60h] [rbp-40h]
long long v12; // [rsp+68h] [rbp-38h]
long long v13; // [rsp+70h] [rbp-30h]
long long v14; // [rsp+78h] [rbp-28h]
long long v15; // [rsp+80h] [rbp-20h]
unsigned int v16; // [rsp+88h] [rbp-18h]
unsigned int v17; // [rsp+8Ch] [rbp-14h]
long long v18; // [rsp+90h] [rbp-10h]
v18 = a1;
v17 = a2;
v16 = a3;
v15 = a4;
v14 = a5;
v13 = a6;
v11 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v10, a3, 7LL);
if ( v11 )
{
((void ( *)(long long, long long, long long, _QWORD))PSI_server[66])(v11, v14, v18, v17);
v12 = my_pwrite(v16, v15, v14, v13, a7);
if ( (a7 & 6) != 0 )
{
if ( v12 )
v9 = 0LL;
else
v9 = v14;
((void ( *)(long long, long long))PSI_server[67])(v11, v9);
}
else
{
if ( v12 == -1 )
v8 = 0LL;
else
v8 = v12;
((void ( *)(long long, long long))PSI_server[67])(v11, v8);
}
return v12;
}
else
{
return my_pwrite(v16, v15, v14, v13, a7);
}
}
| inline_mysql_file_pwrite:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xa0
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV dword ptr [RBP + -0x18],EDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV qword ptr [RBP + -0x30],R9
LEA RAX,[0x3c0248]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x158]
MOV ESI,dword ptr [RBP + -0x18]
LEA RDI,[RBP + -0x88]
MOV EDX,0x7
CALL RAX
MOV qword ptr [RBP + -0x40],RAX
CMP qword ptr [RBP + -0x40],0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x001e20bf
LEA RAX,[0x3c0248]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x210]
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x14]
CALL RAX
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RBP + -0x30]
MOV R8,qword ptr [RBP + 0x10]
CALL 0x001f4a20
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + 0x10]
AND RAX,0x6
CMP RAX,0x0
JZ 0x001e206a
CMP qword ptr [RBP + -0x38],0x0
JNZ 0x001e204f
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x98],RAX
JMP 0x001e205a
LAB_001e204f:
XOR EAX,EAX
MOV qword ptr [RBP + -0x98],RAX
JMP 0x001e205a
LAB_001e205a:
MOV RAX,qword ptr [RBP + -0x98]
MOV qword ptr [RBP + -0x90],RAX
JMP 0x001e2097
LAB_001e206a:
CMP qword ptr [RBP + -0x38],-0x1
JZ 0x001e207e
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0xa0],RAX
JMP 0x001e2089
LAB_001e207e:
XOR EAX,EAX
MOV qword ptr [RBP + -0xa0],RAX
JMP 0x001e2089
LAB_001e2089:
MOV RAX,qword ptr [RBP + -0xa0]
MOV qword ptr [RBP + -0x90],RAX
LAB_001e2097:
LEA RAX,[0x3c0248]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x218]
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x90]
CALL RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001e20e3
LAB_001e20bf:
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RBP + -0x30]
MOV R8,qword ptr [RBP + 0x10]
CALL 0x001f4a20
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x8],RAX
LAB_001e20e3:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0xa0
POP RBP
RET
|
long inline_mysql_file_pwrite
(int8 param_1,int4 param_2,int4 param_3,int8 param_4,
long param_5,int8 param_6,ulong param_7)
{
long local_a8;
long local_a0;
long local_98;
int1 local_90 [72];
long local_48;
long local_40;
int8 local_38;
long local_30;
int8 local_28;
int4 local_20;
int4 local_1c;
int8 local_18;
long local_10;
local_38 = param_6;
local_30 = param_5;
local_28 = param_4;
local_20 = param_3;
local_1c = param_2;
local_18 = param_1;
local_48 = (**(code **)(PSI_server + 0x158))(local_90,param_3,7);
if (local_48 == 0) {
local_10 = my_pwrite(local_20,local_28,local_30,local_38,param_7);
}
else {
(**(code **)(PSI_server + 0x210))(local_48,local_30,local_18,local_1c);
local_40 = my_pwrite(local_20,local_28,local_30,local_38,param_7);
if ((param_7 & 6) == 0) {
local_a8 = local_40;
if (local_40 == -1) {
local_a8 = 0;
}
local_98 = local_a8;
}
else {
if (local_40 == 0) {
local_a0 = local_30;
}
else {
local_a0 = 0;
}
local_98 = local_a0;
}
(**(code **)(PSI_server + 0x218))(local_48,local_98);
local_10 = local_40;
}
return local_10;
}
| |
55,582 | ftb_phrase_add_word | eloqsql/storage/myisam/ft_boolean_search.c | static int ftb_phrase_add_word(MYSQL_FTPARSER_PARAM *param,
const char *word, int word_len,
MYSQL_FTPARSER_BOOLEAN_INFO *boolean_info __attribute__((unused)))
{
MY_FTB_PHRASE_PARAM *phrase_param= param->mysql_ftparam;
FT_WORD *w= (FT_WORD *)phrase_param->document->data;
LIST *phrase, *document;
w->pos= (uchar*) word;
w->len= word_len;
phrase_param->document= phrase_param->document->prev;
if (phrase_param->phrase_length > phrase_param->document_length)
{
phrase_param->document_length++;
return 0;
}
/* TODO: rewrite phrase search to avoid
comparing the same word twice. */
for (phrase= phrase_param->phrase, document= phrase_param->document->next;
phrase; phrase= phrase->next, document= document->next)
{
FT_WORD *phrase_word= (FT_WORD *)phrase->data;
FT_WORD *document_word= (FT_WORD *)document->data;
if (my_strnncoll(phrase_param->cs, (uchar*) phrase_word->pos,
phrase_word->len,
(uchar*) document_word->pos, document_word->len))
return 0;
}
phrase_param->match++;
return 0;
} | O3 | c | ftb_phrase_add_word:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq 0x18(%rdi), %rbx
movq 0x8(%rbx), %rax
movq 0x10(%rax), %rax
movq %rsi, (%rax)
movslq %edx, %rcx
movq %rcx, 0x10(%rax)
movq 0x8(%rbx), %rax
movq (%rax), %r14
movq %r14, 0x8(%rbx)
movl 0x1c(%rbx), %eax
cmpl %eax, 0x18(%rbx)
jbe 0x729aa
incl %eax
movl %eax, 0x1c(%rbx)
jmp 0x729eb
movq (%rbx), %r15
testq %r15, %r15
je 0x729e8
movq 0x8(%r14), %r14
movq 0x10(%r15), %rax
movq 0x10(%r14), %r8
movq 0x10(%rbx), %rdi
movq 0xc0(%rdi), %r10
movq (%rax), %rsi
movq 0x10(%rax), %rdx
movq (%r8), %rcx
movq 0x10(%r8), %r8
xorl %r9d, %r9d
callq *0x8(%r10)
testl %eax, %eax
jne 0x729eb
movq 0x8(%r15), %r15
jmp 0x729ad
incl 0x20(%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| ftb_phrase_add_word:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov rbx, [rdi+18h]
mov rax, [rbx+8]
mov rax, [rax+10h]
mov [rax], rsi
movsxd rcx, edx
mov [rax+10h], rcx
mov rax, [rbx+8]
mov r14, [rax]
mov [rbx+8], r14
mov eax, [rbx+1Ch]
cmp [rbx+18h], eax
jbe short loc_729AA
inc eax
mov [rbx+1Ch], eax
jmp short loc_729EB
loc_729AA:
mov r15, [rbx]
loc_729AD:
test r15, r15
jz short loc_729E8
mov r14, [r14+8]
mov rax, [r15+10h]
mov r8, [r14+10h]
mov rdi, [rbx+10h]
mov r10, [rdi+0C0h]
mov rsi, [rax]
mov rdx, [rax+10h]
mov rcx, [r8]
mov r8, [r8+10h]
xor r9d, r9d
call qword ptr [r10+8]
test eax, eax
jnz short loc_729EB
mov r15, [r15+8]
jmp short loc_729AD
loc_729E8:
inc dword ptr [rbx+20h]
loc_729EB:
xor eax, eax
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
| long long ftb_phrase_add_word(long long a1, long long a2, int a3)
{
long long v3; // rax
long long *v4; // rbx
_QWORD *v5; // rax
long long v6; // r14
unsigned int v7; // eax
long long i; // r15
long long v10; // [rsp-8h] [rbp-20h]
v10 = v3;
v4 = *(long long **)(a1 + 24);
v5 = *(_QWORD **)(v4[1] + 16);
*v5 = a2;
v5[2] = a3;
v6 = *(_QWORD *)v4[1];
v4[1] = v6;
v7 = *((_DWORD *)v4 + 7);
if ( *((_DWORD *)v4 + 6) <= v7 )
{
for ( i = *v4; i; i = *(_QWORD *)(i + 8) )
{
v6 = *(_QWORD *)(v6 + 8);
if ( (*(unsigned int ( **)(long long, _QWORD, _QWORD, _QWORD, _QWORD, _QWORD, long long))(*(_QWORD *)(v4[2] + 192) + 8LL))(
v4[2],
**(_QWORD **)(i + 16),
*(_QWORD *)(*(_QWORD *)(i + 16) + 16LL),
**(_QWORD **)(v6 + 16),
*(_QWORD *)(*(_QWORD *)(v6 + 16) + 16LL),
0LL,
v10) )
{
return 0LL;
}
}
++*((_DWORD *)v4 + 8);
}
else
{
*((_DWORD *)v4 + 7) = v7 + 1;
}
return 0LL;
}
| ftb_phrase_add_word:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,qword ptr [RDI + 0x18]
MOV RAX,qword ptr [RBX + 0x8]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RAX],RSI
MOVSXD RCX,EDX
MOV qword ptr [RAX + 0x10],RCX
MOV RAX,qword ptr [RBX + 0x8]
MOV R14,qword ptr [RAX]
MOV qword ptr [RBX + 0x8],R14
MOV EAX,dword ptr [RBX + 0x1c]
CMP dword ptr [RBX + 0x18],EAX
JBE 0x001729aa
INC EAX
MOV dword ptr [RBX + 0x1c],EAX
JMP 0x001729eb
LAB_001729aa:
MOV R15,qword ptr [RBX]
LAB_001729ad:
TEST R15,R15
JZ 0x001729e8
MOV R14,qword ptr [R14 + 0x8]
MOV RAX,qword ptr [R15 + 0x10]
MOV R8,qword ptr [R14 + 0x10]
MOV RDI,qword ptr [RBX + 0x10]
MOV R10,qword ptr [RDI + 0xc0]
MOV RSI,qword ptr [RAX]
MOV RDX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [R8]
MOV R8,qword ptr [R8 + 0x10]
XOR R9D,R9D
CALL qword ptr [R10 + 0x8]
TEST EAX,EAX
JNZ 0x001729eb
MOV R15,qword ptr [R15 + 0x8]
JMP 0x001729ad
LAB_001729e8:
INC dword ptr [RBX + 0x20]
LAB_001729eb:
XOR EAX,EAX
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
|
int8 ftb_phrase_add_word(long param_1,int8 param_2,int param_3)
{
long *plVar1;
int8 *puVar2;
int iVar3;
long lVar4;
long lVar5;
plVar1 = *(long **)(param_1 + 0x18);
puVar2 = *(int8 **)(plVar1[1] + 0x10);
*puVar2 = param_2;
puVar2[2] = (long)param_3;
lVar4 = *(long *)plVar1[1];
plVar1[1] = lVar4;
if (*(uint *)((long)plVar1 + 0x1c) < *(uint *)(plVar1 + 3)) {
*(uint *)((long)plVar1 + 0x1c) = *(uint *)((long)plVar1 + 0x1c) + 1;
}
else {
for (lVar5 = *plVar1; lVar5 != 0; lVar5 = *(long *)(lVar5 + 8)) {
lVar4 = *(long *)(lVar4 + 8);
iVar3 = (**(code **)(*(long *)(plVar1[2] + 0xc0) + 8))
(plVar1[2],**(int8 **)(lVar5 + 0x10),
(*(int8 **)(lVar5 + 0x10))[2],**(int8 **)(lVar4 + 0x10),
(*(int8 **)(lVar4 + 0x10))[2],0);
if (iVar3 != 0) {
return 0;
}
}
*(int *)(plVar1 + 4) = (int)plVar1[4] + 1;
}
return 0;
}
| |
55,583 | mi_reset | eloqsql/storage/myisam/mi_extra.c | int mi_reset(MI_INFO *info)
{
int error= 0;
MYISAM_SHARE *share=info->s;
DBUG_ENTER("mi_reset");
/*
Free buffers and reset the following flags:
EXTRA_CACHE, EXTRA_WRITE_CACHE, EXTRA_KEYREAD, EXTRA_QUICK
If the row buffer cache is large (for dynamic tables), reduce it
to save memory.
*/
if (info->opt_flag & (READ_CACHE_USED | WRITE_CACHE_USED))
{
info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED);
error= end_io_cache(&info->rec_cache);
}
if (share->base.blobs)
mi_alloc_rec_buff(info, -1, &info->rec_buff);
#if defined(HAVE_MMAP) && defined(HAVE_MADVISE)
if (info->opt_flag & MEMMAP_USED)
madvise((char*) share->file_map, share->state.state.data_file_length,
MADV_RANDOM);
#endif
info->opt_flag&= ~(KEY_READ_USED | REMEMBER_OLD_POS);
info->quick_mode=0;
info->lastinx= 0; /* Use first index as def */
info->last_search_keypage= info->lastpos= HA_OFFSET_ERROR;
info->page_changed= 1;
info->update= ((info->update & HA_STATE_CHANGED) | HA_STATE_NEXT_FOUND |
HA_STATE_PREV_FOUND);
DBUG_RETURN(error);
} | O0 | c | mi_reset:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl 0x1c8(%rax), %eax
andl $0x12, %eax
cmpl $0x0, %eax
je 0xaf246
movq -0x8(%rbp), %rax
movl 0x1c8(%rax), %ecx
andl $-0x13, %ecx
movl %ecx, 0x1c8(%rax)
movq -0x8(%rbp), %rdi
addq $0x220, %rdi # imm = 0x220
callq 0xe3560
movl %eax, -0xc(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x188(%rax)
je 0xaf26e
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rdx
addq $0x120, %rdx # imm = 0x120
movq $-0x1, %rsi
callq 0xb8150
movq -0x8(%rbp), %rax
movl 0x1c8(%rax), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0xaf29d
movq -0x18(%rbp), %rax
movq 0x270(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x40(%rax), %rsi
movl $0x1, %edx
callq 0x2a460
movq -0x8(%rbp), %rax
movl 0x1c8(%rax), %ecx
andl $-0x49, %ecx
movl %ecx, 0x1c8(%rax)
movq -0x8(%rbp), %rax
movb $0x0, 0x33b(%rax)
movq -0x8(%rbp), %rax
movl $0x0, 0x1d4(%rax)
movq -0x8(%rbp), %rax
movq $-0x1, 0x170(%rax)
movq -0x8(%rbp), %rax
movq $-0x1, 0x198(%rax)
movq -0x8(%rbp), %rax
movb $0x1, 0x33c(%rax)
movq -0x8(%rbp), %rax
movl 0x1d0(%rax), %ecx
andl $0x1, %ecx
orl $0x10, %ecx
orl $0x20, %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x1d0(%rax)
movl -0xc(%rbp), %eax
movl %eax, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
| mi_reset:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_C], 0
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_18], rax
mov rax, [rbp+var_8]
mov eax, [rax+1C8h]
and eax, 12h
cmp eax, 0
jz short loc_AF246
mov rax, [rbp+var_8]
mov ecx, [rax+1C8h]
and ecx, 0FFFFFFEDh
mov [rax+1C8h], ecx
mov rdi, [rbp+var_8]
add rdi, 220h
call end_io_cache
mov [rbp+var_C], eax
loc_AF246:
mov rax, [rbp+var_18]
cmp dword ptr [rax+188h], 0
jz short loc_AF26E
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_8]
add rdx, 120h
mov rsi, 0FFFFFFFFFFFFFFFFh
call mi_alloc_rec_buff
loc_AF26E:
mov rax, [rbp+var_8]
mov eax, [rax+1C8h]
and eax, 20h
cmp eax, 0
jz short loc_AF29D
mov rax, [rbp+var_18]
mov rdi, [rax+270h]
mov rax, [rbp+var_18]
mov rsi, [rax+40h]
mov edx, 1
call _madvise
loc_AF29D:
mov rax, [rbp+var_8]
mov ecx, [rax+1C8h]
and ecx, 0FFFFFFB7h
mov [rax+1C8h], ecx
mov rax, [rbp+var_8]
mov byte ptr [rax+33Bh], 0
mov rax, [rbp+var_8]
mov dword ptr [rax+1D4h], 0
mov rax, [rbp+var_8]
mov qword ptr [rax+170h], 0FFFFFFFFFFFFFFFFh
mov rax, [rbp+var_8]
mov qword ptr [rax+198h], 0FFFFFFFFFFFFFFFFh
mov rax, [rbp+var_8]
mov byte ptr [rax+33Ch], 1
mov rax, [rbp+var_8]
mov ecx, [rax+1D0h]
and ecx, 1
or ecx, 10h
or ecx, 20h
mov rax, [rbp+var_8]
mov [rax+1D0h], ecx
mov eax, [rbp+var_C]
mov [rbp+var_1C], eax
mov eax, [rbp+var_1C]
add rsp, 20h
pop rbp
retn
| long long mi_reset(long long *a1)
{
long long v2; // [rsp+8h] [rbp-18h]
unsigned int v3; // [rsp+14h] [rbp-Ch]
v3 = 0;
v2 = *a1;
if ( (a1[57] & 0x12) != 0 )
{
*((_DWORD *)a1 + 114) &= 0xFFFFFFED;
v3 = end_io_cache(a1 + 68);
}
if ( *(_DWORD *)(v2 + 392) )
mi_alloc_rec_buff(a1, -1LL, a1 + 36);
if ( (a1[57] & 0x20) != 0 )
madvise(*(_QWORD *)(v2 + 624), *(_QWORD *)(v2 + 64), 1LL);
*((_DWORD *)a1 + 114) &= 0xFFFFFFB7;
*((_BYTE *)a1 + 827) = 0;
*((_DWORD *)a1 + 117) = 0;
a1[46] = -1LL;
a1[51] = -1LL;
*((_BYTE *)a1 + 828) = 1;
*((_DWORD *)a1 + 116) = a1[58] & 1 | 0x30;
return v3;
}
| mi_reset:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x1c8]
AND EAX,0x12
CMP EAX,0x0
JZ 0x001af246
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x1c8]
AND ECX,0xffffffed
MOV dword ptr [RAX + 0x1c8],ECX
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x220
CALL 0x001e3560
MOV dword ptr [RBP + -0xc],EAX
LAB_001af246:
MOV RAX,qword ptr [RBP + -0x18]
CMP dword ptr [RAX + 0x188],0x0
JZ 0x001af26e
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x8]
ADD RDX,0x120
MOV RSI,-0x1
CALL 0x001b8150
LAB_001af26e:
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x1c8]
AND EAX,0x20
CMP EAX,0x0
JZ 0x001af29d
MOV RAX,qword ptr [RBP + -0x18]
MOV RDI,qword ptr [RAX + 0x270]
MOV RAX,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RAX + 0x40]
MOV EDX,0x1
CALL 0x0012a460
LAB_001af29d:
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x1c8]
AND ECX,0xffffffb7
MOV dword ptr [RAX + 0x1c8],ECX
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x33b],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x1d4],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x170],-0x1
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x198],-0x1
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x33c],0x1
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x1d0]
AND ECX,0x1
OR ECX,0x10
OR ECX,0x20
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x1d0],ECX
MOV EAX,dword ptr [RBP + -0xc]
MOV dword ptr [RBP + -0x1c],EAX
MOV EAX,dword ptr [RBP + -0x1c]
ADD RSP,0x20
POP RBP
RET
|
int4 mi_reset(long *param_1)
{
long lVar1;
int4 local_14;
local_14 = 0;
lVar1 = *param_1;
if ((*(uint *)(param_1 + 0x39) & 0x12) != 0) {
*(uint *)(param_1 + 0x39) = *(uint *)(param_1 + 0x39) & 0xffffffed;
local_14 = end_io_cache(param_1 + 0x44);
}
if (*(int *)(lVar1 + 0x188) != 0) {
mi_alloc_rec_buff(param_1,0xffffffffffffffff,param_1 + 0x24);
}
if ((*(uint *)(param_1 + 0x39) & 0x20) != 0) {
madvise(*(void **)(lVar1 + 0x270),*(size_t *)(lVar1 + 0x40),1);
}
*(uint *)(param_1 + 0x39) = *(uint *)(param_1 + 0x39) & 0xffffffb7;
*(int1 *)((long)param_1 + 0x33b) = 0;
*(int4 *)((long)param_1 + 0x1d4) = 0;
param_1[0x2e] = -1;
param_1[0x33] = -1;
*(int1 *)((long)param_1 + 0x33c) = 1;
*(uint *)(param_1 + 0x3a) = *(uint *)(param_1 + 0x3a) & 1 | 0x30;
return local_14;
}
| |
55,584 | skip | eloqsql/libmariadb/unittest/mytap/tap.c | void
skip(int how_many, char const *const fmt, ...)
{
char reason[80];
if (fmt && *fmt)
{
va_list ap;
va_start(ap, fmt);
vsnprintf(reason, sizeof(reason), fmt, ap);
va_end(ap);
}
else
reason[0] = '\0';
while (how_many-- > 0)
{
va_list ap;
memset((char*) &ap, 0, sizeof(ap)); /* Keep compiler happy */
vemit_tap(1, NULL, ap);
emit_dir("skip", reason);
emit_endl();
}
} | O0 | c | skip:
pushq %rbp
movq %rsp, %rbp
subq $0x160, %rsp # imm = 0x160
testb %al, %al
je 0x158f7
movaps %xmm0, -0x130(%rbp)
movaps %xmm1, -0x120(%rbp)
movaps %xmm2, -0x110(%rbp)
movaps %xmm3, -0x100(%rbp)
movaps %xmm4, -0xf0(%rbp)
movaps %xmm5, -0xe0(%rbp)
movaps %xmm6, -0xd0(%rbp)
movaps %xmm7, -0xc0(%rbp)
movq %r9, -0x138(%rbp)
movq %r8, -0x140(%rbp)
movq %rcx, -0x148(%rbp)
movq %rdx, -0x150(%rbp)
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movl %edi, -0x64(%rbp)
movq %rsi, -0x70(%rbp)
cmpq $0x0, -0x70(%rbp)
je 0x15983
movq -0x70(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
je 0x15983
leaq -0x90(%rbp), %rax
leaq -0x160(%rbp), %rcx
movq %rcx, 0x10(%rax)
leaq 0x10(%rbp), %rcx
movq %rcx, 0x8(%rax)
movl $0x30, 0x4(%rax)
movl $0x10, (%rax)
leaq -0x60(%rbp), %rdi
movq -0x70(%rbp), %rdx
leaq -0x90(%rbp), %rcx
movl $0x50, %esi
callq 0x132a0
leaq -0x90(%rbp), %rax
jmp 0x15987
movb $0x0, -0x60(%rbp)
jmp 0x15989
movl -0x64(%rbp), %eax
movl %eax, %ecx
addl $-0x1, %ecx
movl %ecx, -0x64(%rbp)
cmpl $0x0, %eax
jle 0x159d8
leaq -0xb0(%rbp), %rdi
xorl %esi, %esi
movl $0x18, %edx
callq 0x13250
leaq -0xb0(%rbp), %rdx
movl $0x1, %edi
xorl %eax, %eax
movl %eax, %esi
callq 0x157a0
leaq -0x60(%rbp), %rsi
leaq 0x35e38(%rip), %rdi # 0x4b804
callq 0x15870
callq 0x15b60
jmp 0x15989
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x159f3
addq $0x160, %rsp # imm = 0x160
popq %rbp
retq
callq 0x134b0
nopl (%rax,%rax)
| skip:
push rbp
mov rbp, rsp
sub rsp, 160h
test al, al
jz short loc_158F7
movaps [rbp+var_130], xmm0
movaps [rbp+var_120], xmm1
movaps [rbp+var_110], xmm2
movaps [rbp+var_100], xmm3
movaps [rbp+var_F0], xmm4
movaps [rbp+var_E0], xmm5
movaps [rbp+var_D0], xmm6
movaps [rbp+var_C0], xmm7
loc_158F7:
mov [rbp+var_138], r9
mov [rbp+var_140], r8
mov [rbp+var_148], rcx
mov [rbp+var_150], rdx
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_64], edi
mov [rbp+var_70], rsi
cmp [rbp+var_70], 0
jz short loc_15983
mov rax, [rbp+var_70]
movsx eax, byte ptr [rax]
cmp eax, 0
jz short loc_15983
lea rax, [rbp+var_90]
lea rcx, [rbp+var_160]
mov [rax+10h], rcx
lea rcx, [rbp+arg_0]
mov [rax+8], rcx
mov dword ptr [rax+4], 30h ; '0'
mov dword ptr [rax], 10h
lea rdi, [rbp+var_60]
mov rdx, [rbp+var_70]
lea rcx, [rbp+var_90]
mov esi, 50h ; 'P'
call _vsnprintf
lea rax, [rbp+var_90]
jmp short loc_15987
loc_15983:
mov [rbp+var_60], 0
loc_15987:
jmp short $+2
loc_15989:
mov eax, [rbp+var_64]
mov ecx, eax
add ecx, 0FFFFFFFFh
mov [rbp+var_64], ecx
cmp eax, 0
jle short loc_159D8
lea rdi, [rbp+var_B0]
xor esi, esi
mov edx, 18h
call _memset
lea rdx, [rbp+var_B0]
mov edi, 1
xor eax, eax
mov esi, eax
call vemit_tap
lea rsi, [rbp+var_60]
lea rdi, aSkip; "skip"
call emit_dir
call emit_endl
jmp short loc_15989
loc_159D8:
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_159F3
add rsp, 160h
pop rbp
retn
loc_159F3:
call ___stack_chk_fail
| unsigned long long skip(int a1, _BYTE *a2, ...)
{
int v2; // eax
_BYTE v4[32]; // [rsp+B0h] [rbp-B0h] BYREF
va_list va; // [rsp+D0h] [rbp-90h] BYREF
_BYTE *v6; // [rsp+F0h] [rbp-70h]
int v7; // [rsp+FCh] [rbp-64h]
char v8[88]; // [rsp+100h] [rbp-60h] BYREF
unsigned long long v9; // [rsp+158h] [rbp-8h]
v9 = __readfsqword(0x28u);
v7 = a1;
v6 = a2;
if ( a2 && *v6 )
{
va_start(va, a2);
vsnprintf(v8, 80LL, v6, va);
}
else
{
v8[0] = 0;
}
while ( 1 )
{
v2 = v7--;
if ( v2 <= 0 )
break;
memset(v4, 0LL, 24LL);
vemit_tap(1, 0LL, (long long)v4);
emit_dir("skip", v8);
emit_endl();
}
return __readfsqword(0x28u);
}
| skip:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x160
TEST AL,AL
JZ 0x001158f7
MOVAPS xmmword ptr [RBP + -0x130],XMM0
MOVAPS xmmword ptr [RBP + -0x120],XMM1
MOVAPS xmmword ptr [RBP + -0x110],XMM2
MOVAPS xmmword ptr [RBP + -0x100],XMM3
MOVAPS xmmword ptr [RBP + -0xf0],XMM4
MOVAPS xmmword ptr [RBP + -0xe0],XMM5
MOVAPS xmmword ptr [RBP + -0xd0],XMM6
MOVAPS xmmword ptr [RBP + -0xc0],XMM7
LAB_001158f7:
MOV qword ptr [RBP + -0x138],R9
MOV qword ptr [RBP + -0x140],R8
MOV qword ptr [RBP + -0x148],RCX
MOV qword ptr [RBP + -0x150],RDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV dword ptr [RBP + -0x64],EDI
MOV qword ptr [RBP + -0x70],RSI
CMP qword ptr [RBP + -0x70],0x0
JZ 0x00115983
MOV RAX,qword ptr [RBP + -0x70]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x0
JZ 0x00115983
LEA RAX,[RBP + -0x90]
LEA RCX,[RBP + -0x160]
MOV qword ptr [RAX + 0x10],RCX
LEA RCX,[RBP + 0x10]
MOV qword ptr [RAX + 0x8],RCX
MOV dword ptr [RAX + 0x4],0x30
MOV dword ptr [RAX],0x10
LEA RDI,[RBP + -0x60]
MOV RDX,qword ptr [RBP + -0x70]
LEA RCX,[RBP + -0x90]
MOV ESI,0x50
CALL 0x001132a0
LEA RAX,[RBP + -0x90]
JMP 0x00115987
LAB_00115983:
MOV byte ptr [RBP + -0x60],0x0
LAB_00115987:
JMP 0x00115989
LAB_00115989:
MOV EAX,dword ptr [RBP + -0x64]
MOV ECX,EAX
ADD ECX,-0x1
MOV dword ptr [RBP + -0x64],ECX
CMP EAX,0x0
JLE 0x001159d8
LEA RDI,[RBP + -0xb0]
XOR ESI,ESI
MOV EDX,0x18
CALL 0x00113250
LEA RDX,[RBP + -0xb0]
MOV EDI,0x1
XOR EAX,EAX
MOV ESI,EAX
CALL 0x001157a0
LEA RSI,[RBP + -0x60]
LEA RDI,[0x14b804]
CALL 0x00115870
CALL 0x00115b60
JMP 0x00115989
LAB_001159d8:
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x001159f3
ADD RSP,0x160
POP RBP
RET
LAB_001159f3:
CALL 0x001134b0
|
void skip(int8 param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5,int8 param_6,int8 param_7,int8 param_8,int param_9,
char *param_10,int8 param_11,int8 param_12,int8 param_13,
int8 param_14)
{
char in_AL;
long in_FS_OFFSET;
int1 local_168 [16];
int8 local_158;
int8 local_150;
int8 local_148;
int8 local_140;
int8 local_138;
int8 local_128;
int8 local_118;
int8 local_108;
int8 local_f8;
int8 local_e8;
int8 local_d8;
int8 local_c8;
int1 local_b8 [32];
int4 local_98;
int4 local_94;
int1 *local_90;
int1 *local_88;
char *local_78;
int local_6c;
char local_68 [88];
long local_10;
if (in_AL != '\0') {
local_138 = param_1;
local_128 = param_2;
local_118 = param_3;
local_108 = param_4;
local_f8 = param_5;
local_e8 = param_6;
local_d8 = param_7;
local_c8 = param_8;
}
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_158 = param_11;
local_150 = param_12;
local_148 = param_13;
local_140 = param_14;
local_78 = param_10;
local_6c = param_9;
if ((param_10 == (char *)0x0) || (*param_10 == '\0')) {
local_68[0] = '\0';
}
else {
local_88 = local_168;
local_90 = &stack0x00000008;
local_94 = 0x30;
local_98 = 0x10;
vsnprintf(local_68,0x50,param_10,&local_98);
}
while (0 < local_6c) {
local_6c = local_6c + -1;
memset(local_b8,0,0x18);
vemit_tap(1,0,local_b8);
emit_dir(&DAT_0014b804);
emit_endl();
}
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
local_6c = local_6c + -1;
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return;
}
| |
55,585 | ma_update_status_with_lock | eloqsql/storage/maria/ma_state.c | void _ma_update_status_with_lock(MARIA_HA *info)
{
my_bool locked= 0;
if (info->state == &info->state_save)
{
locked= 1;
mysql_mutex_lock(&info->s->lock.mutex);
}
(*info->s->lock.update_status)(info->lock.status_param);
if (locked)
mysql_mutex_unlock(&info->s->lock.mutex);
} | O0 | c | ma_update_status_with_lock:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movb $0x0, -0x9(%rbp)
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x8(%rbp), %rcx
addq $0x28, %rcx
cmpq %rcx, %rax
jne 0x3bb5c
movb $0x1, -0x9(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rdi
addq $0x7f0, %rdi # imm = 0x7F0
addq $0x18, %rdi
leaq 0xe2f76(%rip), %rsi # 0x11eac8
movl $0x168, %edx # imm = 0x168
callq 0x3b690
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq 0x8b0(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x6b8(%rcx), %rdi
callq *%rax
cmpb $0x0, -0x9(%rbp)
je 0x3bb94
movq -0x8(%rbp), %rax
movq (%rax), %rdi
addq $0x7f0, %rdi # imm = 0x7F0
addq $0x18, %rdi
callq 0x3b700
addq $0x10, %rsp
popq %rbp
retq
nopw (%rax,%rax)
| _ma_update_status_with_lock:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov [rbp+var_9], 0
mov rax, [rbp+var_8]
mov rax, [rax+20h]
mov rcx, [rbp+var_8]
add rcx, 28h ; '('
cmp rax, rcx
jnz short loc_3BB5C
mov [rbp+var_9], 1
mov rax, [rbp+var_8]
mov rdi, [rax]
add rdi, 7F0h
add rdi, 18h
lea rsi, aWorkspaceLlm4b_6; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 168h
call inline_mysql_mutex_lock_2
loc_3BB5C:
mov rax, [rbp+var_8]
mov rax, [rax]
mov rax, [rax+8B0h]
mov rcx, [rbp+var_8]
mov rdi, [rcx+6B8h]
call rax
cmp [rbp+var_9], 0
jz short loc_3BB94
mov rax, [rbp+var_8]
mov rdi, [rax]
add rdi, 7F0h
add rdi, 18h
call inline_mysql_mutex_unlock_2
loc_3BB94:
add rsp, 10h
pop rbp
retn
| long long ma_update_status_with_lock(_QWORD *a1)
{
long long result; // rax
char v2; // [rsp+7h] [rbp-9h]
v2 = 0;
if ( (_QWORD *)a1[4] == a1 + 5 )
{
v2 = 1;
inline_mysql_mutex_lock_2(
*a1 + 2056LL,
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_state.c",
0x168u);
}
result = (*(long long ( **)(_QWORD))(*a1 + 2224LL))(a1[215]);
if ( v2 )
return inline_mysql_mutex_unlock_2(*a1 + 2056LL);
return result;
}
| _ma_update_status_with_lock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV byte ptr [RBP + -0x9],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x20]
MOV RCX,qword ptr [RBP + -0x8]
ADD RCX,0x28
CMP RAX,RCX
JNZ 0x0013bb5c
MOV byte ptr [RBP + -0x9],0x1
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX]
ADD RDI,0x7f0
ADD RDI,0x18
LEA RSI,[0x21eac8]
MOV EDX,0x168
CALL 0x0013b690
LAB_0013bb5c:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x8b0]
MOV RCX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RCX + 0x6b8]
CALL RAX
CMP byte ptr [RBP + -0x9],0x0
JZ 0x0013bb94
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX]
ADD RDI,0x7f0
ADD RDI,0x18
CALL 0x0013b700
LAB_0013bb94:
ADD RSP,0x10
POP RBP
RET
|
void _ma_update_status_with_lock(long *param_1)
{
long *plVar1;
plVar1 = (long *)param_1[4];
if (plVar1 == param_1 + 5) {
inline_mysql_mutex_lock
(*param_1 + 0x808,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_state.c",
0x168);
}
(**(code **)(*param_1 + 0x8b0))(param_1[0xd7]);
if (plVar1 == param_1 + 5) {
inline_mysql_mutex_unlock(*param_1 + 0x808);
}
return;
}
| |
55,586 | 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);
} | O3 | c | bitmap_get_first_set:
pushq %rbp
movq %rsp, %rbp
movq (%rdi), %rcx
movq 0x8(%rdi), %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
jae 0x9da66
xorl %eax, %eax
movl (%rcx), %esi
testl %esi, %esi
jne 0x9da71
addq $0x4, %rcx
incl %eax
cmpq %rdx, %rcx
jb 0x9da55
movl (%rcx), %esi
movl 0x18(%rdi), %ecx
notl %ecx
testl %ecx, %esi
je 0x9daac
movl %esi, -0x4(%rbp)
xorl %edx, %edx
movl $0x0, %ecx
testb %sil, %sil
jne 0x9da94
xorl %ecx, %ecx
leaq -0x3(%rbp), %rdi
movb (%rdi), %sil
addl $0x8, %ecx
incq %rdi
testb %sil, %sil
je 0x9da86
movzbl %sil, %esi
btl %edx, %esi
leal 0x1(%rdx), %edx
jae 0x9da98
shll $0x5, %eax
addl %eax, %ecx
leal (%rdx,%rcx), %eax
decl %eax
jmp 0x9dab1
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
popq %rbp
retq
| bitmap_get_first_set:
push rbp
mov rbp, rsp
mov rcx, [rdi]
mov rdx, [rdi+8]
xor eax, eax
cmp rcx, rdx
jnb short loc_9DA66
xor eax, eax
loc_9DA55:
mov esi, [rcx]
test esi, esi
jnz short loc_9DA71
add rcx, 4
inc eax
cmp rcx, rdx
jb short loc_9DA55
loc_9DA66:
mov esi, [rcx]
mov ecx, [rdi+18h]
not ecx
test esi, ecx
jz short loc_9DAAC
loc_9DA71:
mov [rbp+var_4], esi
xor edx, edx
mov ecx, 0
test sil, sil
jnz short loc_9DA94
xor ecx, ecx
lea rdi, [rbp+var_4+1]
loc_9DA86:
mov sil, [rdi]
add ecx, 8
inc rdi
test sil, sil
jz short loc_9DA86
loc_9DA94:
movzx esi, sil
loc_9DA98:
bt esi, edx
lea edx, [rdx+1]
jnb short loc_9DA98
shl eax, 5
add ecx, eax
lea eax, [rdx+rcx]
dec eax
jmp short loc_9DAB1
loc_9DAAC:
mov eax, 0FFFFFFFFh
loc_9DAB1:
pop rbp
retn
| long long bitmap_get_first_set(long long a1)
{
int *v1; // rcx
unsigned long long v2; // rdx
int v3; // eax
int v4; // esi
unsigned int v5; // edx
int v6; // ecx
_BYTE *v7; // rdi
int v10; // [rsp+0h] [rbp-4h] BYREF
v1 = *(int **)a1;
v2 = *(_QWORD *)(a1 + 8);
v3 = 0;
if ( *(_QWORD *)a1 >= v2 )
{
LABEL_5:
v4 = *v1;
if ( (~*(_DWORD *)(a1 + 24) & *v1) == 0 )
return 0xFFFFFFFFLL;
}
else
{
v3 = 0;
while ( 1 )
{
v4 = *v1;
if ( *v1 )
break;
++v1;
++v3;
if ( (unsigned long long)v1 >= v2 )
goto LABEL_5;
}
}
v10 = v4;
v5 = 0;
v6 = 0;
if ( !(_BYTE)v4 )
{
v6 = 0;
v7 = (char *)&v10 + 1;
do
{
LOBYTE(v4) = *v7;
v6 += 8;
++v7;
}
while ( !(_BYTE)v4 );
}
v4 = (unsigned __int8)v4;
while ( !_bittest(&v4, v5++) )
;
return v5 + 32 * v3 + v6 - 1;
}
| bitmap_get_first_set:
PUSH RBP
MOV RBP,RSP
MOV RCX,qword ptr [RDI]
MOV RDX,qword ptr [RDI + 0x8]
XOR EAX,EAX
CMP RCX,RDX
JNC 0x0019da66
XOR EAX,EAX
LAB_0019da55:
MOV ESI,dword ptr [RCX]
TEST ESI,ESI
JNZ 0x0019da71
ADD RCX,0x4
INC EAX
CMP RCX,RDX
JC 0x0019da55
LAB_0019da66:
MOV ESI,dword ptr [RCX]
MOV ECX,dword ptr [RDI + 0x18]
NOT ECX
TEST ESI,ECX
JZ 0x0019daac
LAB_0019da71:
MOV dword ptr [RBP + -0x4],ESI
XOR EDX,EDX
MOV ECX,0x0
TEST SIL,SIL
JNZ 0x0019da94
XOR ECX,ECX
LEA RDI,[RBP + -0x3]
LAB_0019da86:
MOV SIL,byte ptr [RDI]
ADD ECX,0x8
INC RDI
TEST SIL,SIL
JZ 0x0019da86
LAB_0019da94:
MOVZX ESI,SIL
LAB_0019da98:
BT ESI,EDX
LEA EDX,[RDX + 0x1]
JNC 0x0019da98
SHL EAX,0x5
ADD ECX,EAX
LEA EAX,[RDX + RCX*0x1]
DEC EAX
JMP 0x0019dab1
LAB_0019daac:
MOV EAX,0xffffffff
LAB_0019dab1:
POP RBP
RET
|
int bitmap_get_first_set(int8 *param_1)
{
byte bVar1;
uint uVar2;
int iVar3;
int iVar4;
uint *puVar5;
uint uVar6;
uint uVar7;
byte *pbVar8;
byte abStack_b [3];
puVar5 = (uint *)*param_1;
iVar3 = 0;
if (puVar5 < (uint *)param_1[1]) {
iVar3 = 0;
do {
uVar7 = *puVar5;
if (uVar7 != 0) goto LAB_0019da71;
puVar5 = puVar5 + 1;
iVar3 = iVar3 + 1;
} while (puVar5 < (uint *)param_1[1]);
}
uVar7 = *puVar5;
if ((uVar7 & ~*(uint *)(param_1 + 3)) == 0) {
iVar3 = -1;
}
else {
LAB_0019da71:
uVar6 = 0;
iVar4 = 0;
if ((char)uVar7 == '\0') {
iVar4 = 0;
pbVar8 = abStack_b;
do {
bVar1 = *pbVar8;
uVar7 = (uint)bVar1;
iVar4 = iVar4 + 8;
pbVar8 = pbVar8 + 1;
} while (bVar1 == 0);
}
do {
uVar2 = uVar6 & 0x1f;
uVar6 = uVar6 + 1;
} while (((uVar7 & 0xff) >> uVar2 & 1) == 0);
iVar3 = uVar6 + iVar4 + iVar3 * 0x20 + -1;
}
return iVar3;
}
| |
55,587 | ma_reset_history | eloqsql/storage/maria/ma_state.c | void _ma_reset_history(MARIA_SHARE *share)
{
MARIA_STATE_HISTORY *history, *next;
DBUG_ENTER("_ma_reset_history");
share->state_history->trid= 0; /* Visibly by all */
share->state_history->state= share->state.state;
history= share->state_history->next;
share->state_history->next= 0;
for (; history; history= next)
{
next= history->next;
my_free(history);
}
DBUG_VOID_RETURN;
} | O3 | c | ma_reset_history:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq 0x450(%rdi), %rax
xorl %ecx, %ecx
movq %rcx, 0x8(%rax)
movq 0x450(%rdi), %rax
movq 0x48(%rdi), %rdx
movq %rdx, 0x40(%rax)
movups 0x18(%rdi), %xmm0
movups 0x28(%rdi), %xmm1
movups 0x38(%rdi), %xmm2
movups %xmm2, 0x30(%rax)
movups %xmm1, 0x20(%rax)
movups %xmm0, 0x10(%rax)
movq 0x450(%rdi), %rax
movq (%rax), %rdi
movq %rcx, (%rax)
testq %rdi, %rdi
je 0x38b07
movq (%rdi), %rbx
callq 0x9ffde
movq %rbx, %rdi
testq %rbx, %rbx
jne 0x38af7
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| _ma_reset_history:
push rbp
mov rbp, rsp
push rbx
push rax
mov rax, [rdi+450h]
xor ecx, ecx
mov [rax+8], rcx
mov rax, [rdi+450h]
mov rdx, [rdi+48h]
mov [rax+40h], rdx
movups xmm0, xmmword ptr [rdi+18h]
movups xmm1, xmmword ptr [rdi+28h]
movups xmm2, xmmword ptr [rdi+38h]
movups xmmword ptr [rax+30h], xmm2
movups xmmword ptr [rax+20h], xmm1
movups xmmword ptr [rax+10h], xmm0
mov rax, [rdi+450h]
mov rdi, [rax]
mov [rax], rcx
test rdi, rdi
jz short loc_38B07
loc_38AF7:
mov rbx, [rdi]
call my_free
mov rdi, rbx
test rbx, rbx
jnz short loc_38AF7
loc_38B07:
add rsp, 8
pop rbx
pop rbp
retn
| _QWORD ** ma_reset_history(long long a1)
{
long long v1; // rax
__int128 v2; // xmm0
__int128 v3; // xmm1
_QWORD **result; // rax
_QWORD *v5; // rdi
_QWORD *v6; // rbx
*(_QWORD *)(*(_QWORD *)(a1 + 1104) + 8LL) = 0LL;
v1 = *(_QWORD *)(a1 + 1104);
*(_QWORD *)(v1 + 64) = *(_QWORD *)(a1 + 72);
v2 = *(_OWORD *)(a1 + 24);
v3 = *(_OWORD *)(a1 + 40);
*(_OWORD *)(v1 + 48) = *(_OWORD *)(a1 + 56);
*(_OWORD *)(v1 + 32) = v3;
*(_OWORD *)(v1 + 16) = v2;
result = *(_QWORD ***)(a1 + 1104);
v5 = *result;
*result = 0LL;
if ( v5 )
{
do
{
v6 = (_QWORD *)*v5;
result = (_QWORD **)my_free(v5);
v5 = v6;
}
while ( v6 );
}
return result;
}
| _ma_reset_history:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RAX,qword ptr [RDI + 0x450]
XOR ECX,ECX
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RDI + 0x450]
MOV RDX,qword ptr [RDI + 0x48]
MOV qword ptr [RAX + 0x40],RDX
MOVUPS XMM0,xmmword ptr [RDI + 0x18]
MOVUPS XMM1,xmmword ptr [RDI + 0x28]
MOVUPS XMM2,xmmword ptr [RDI + 0x38]
MOVUPS xmmword ptr [RAX + 0x30],XMM2
MOVUPS xmmword ptr [RAX + 0x20],XMM1
MOVUPS xmmword ptr [RAX + 0x10],XMM0
MOV RAX,qword ptr [RDI + 0x450]
MOV RDI,qword ptr [RAX]
MOV qword ptr [RAX],RCX
TEST RDI,RDI
JZ 0x00138b07
LAB_00138af7:
MOV RBX,qword ptr [RDI]
CALL 0x0019ffde
MOV RDI,RBX
TEST RBX,RBX
JNZ 0x00138af7
LAB_00138b07:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
void _ma_reset_history(long param_1)
{
long lVar1;
int8 *puVar2;
int4 uVar3;
int4 uVar4;
int4 uVar5;
int4 uVar6;
int8 uVar7;
int8 uVar8;
int8 uVar9;
*(int8 *)(*(long *)(param_1 + 0x450) + 8) = 0;
lVar1 = *(long *)(param_1 + 0x450);
*(int8 *)(lVar1 + 0x40) = *(int8 *)(param_1 + 0x48);
uVar3 = *(int4 *)(param_1 + 0x18);
uVar4 = *(int4 *)(param_1 + 0x1c);
uVar5 = *(int4 *)(param_1 + 0x20);
uVar6 = *(int4 *)(param_1 + 0x24);
uVar7 = *(int8 *)(param_1 + 0x28);
uVar8 = *(int8 *)(param_1 + 0x30);
uVar9 = *(int8 *)(param_1 + 0x40);
*(int8 *)(lVar1 + 0x30) = *(int8 *)(param_1 + 0x38);
*(int8 *)(lVar1 + 0x38) = uVar9;
*(int8 *)(lVar1 + 0x20) = uVar7;
*(int8 *)(lVar1 + 0x28) = uVar8;
*(int4 *)(lVar1 + 0x10) = uVar3;
*(int4 *)(lVar1 + 0x14) = uVar4;
*(int4 *)(lVar1 + 0x18) = uVar5;
*(int4 *)(lVar1 + 0x1c) = uVar6;
puVar2 = (int8 *)**(int8 **)(param_1 + 0x450);
**(int8 **)(param_1 + 0x450) = 0;
while (puVar2 != (int8 *)0x0) {
puVar2 = (int8 *)*puVar2;
my_free();
}
return;
}
| |
55,588 | 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;
} | O3 | c | my_b_cache_write:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rsi, %r15
movq %rdi, %rbx
cmpq %rsi, 0x30(%rdi)
je 0xb2780
movl $0xfffff000, %eax # imm = 0xFFFFF000
andq %rax, %rdx
je 0xb2853
movq %rdx, -0x30(%rbp)
cmpl $0x0, 0xe0(%rbx)
je 0xb27ef
movl 0xd4(%rbx), %r13d
movq (%rbx), %rax
movq %rax, -0x38(%rbp)
movq 0xf8(%rbx), %r12
andl $0x10, %r12d
leaq 0x2fc26b(%rip), %rax # 0x3aea18
movq (%rax), %rax
leaq -0x80(%rbp), %rdi
movl %r13d, %esi
movl $0x8, %edx
callq *0x158(%rax)
testq %rax, %rax
jne 0xb28d4
movl %r13d, %edi
movq -0x38(%rbp), %rsi
xorl %edx, %edx
movq %r12, %rcx
callq 0xc056c
movq %rax, %r12
cmpq $-0x1, %r12
je 0xb2857
movl $0x0, 0xe0(%rbx)
movl 0xd4(%rbx), %r13d
movq 0xf8(%rbx), %r12
orq $0x4, %r12
leaq 0x2fc210(%rip), %rax # 0x3aea18
movq (%rax), %rax
leaq -0x80(%rbp), %rdi
movl %r13d, %esi
movl $0x7, %edx
callq *0x158(%rax)
testq %rax, %rax
jne 0xb2875
movl %r13d, %edi
movq %r15, %rsi
movq -0x30(%rbp), %r13
movq %r13, %rdx
movq %r12, %rcx
callq 0x3175f
movq %rax, %r15
testq %r15, %r15
je 0xb2850
movl $0xffffffff, 0xe4(%rbx) # imm = 0xFFFFFFFF
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
jmp 0xb2866
addq %r13, (%rbx)
xorl %eax, %eax
jmp 0xb2866
movl $0xffffffff, 0xe4(%rbx) # imm = 0xFFFFFFFF
movl $0x1, %eax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
leaq 0x2fc199(%rip), %rax # 0x3aea18
movq (%rax), %rax
leaq 0x4d36e(%rip), %rdx # 0xffbf7
movq %r14, %rdi
movq -0x30(%rbp), %rsi
movl $0x5f6, %ecx # imm = 0x5F6
callq *0x210(%rax)
movl %r13d, %edi
movq -0x30(%rbp), %r13
movq %r15, %rsi
movq %r13, %rdx
movq %r12, %rcx
callq 0x3175f
movq %rax, %r15
xorl %esi, %esi
testq %rax, %rax
cmoveq %r13, %rsi
leaq 0x2fc155(%rip), %rax # 0x3aea18
movq (%rax), %rax
movq %r14, %rdi
callq *0x218(%rax)
jmp 0xb283a
movq %rax, %r14
leaq 0x2fc13a(%rip), %rax # 0x3aea18
movq (%rax), %rax
leaq 0x4d30f(%rip), %rdx # 0xffbf7
movq %r14, %rdi
xorl %esi, %esi
movl $0x5ef, %ecx # imm = 0x5EF
callq *0x210(%rax)
movl %r13d, %edi
movq -0x38(%rbp), %rsi
xorl %edx, %edx
movq %r12, %rcx
callq 0xc056c
movq %rax, %r12
leaq 0x2fc105(%rip), %rax # 0x3aea18
movq (%rax), %rax
movq %r14, %rdi
xorl %esi, %esi
callq *0x218(%rax)
jmp 0xb27df
| _my_b_cache_write:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 58h
mov r15, rsi
mov rbx, rdi
cmp [rdi+30h], rsi
jz short loc_B2780
mov eax, 0FFFFF000h
and rdx, rax
jz loc_B2853
loc_B2780:
mov [rbp+var_30], rdx
cmp dword ptr [rbx+0E0h], 0
jz short loc_B27EF
mov r13d, [rbx+0D4h]
mov rax, [rbx]
mov [rbp+var_38], rax
mov r12, [rbx+0F8h]
and r12d, 10h
lea rax, PSI_server
mov rax, [rax]
lea rdi, [rbp+var_80]
mov esi, r13d
mov edx, 8
call qword ptr [rax+158h]
test rax, rax
jnz loc_B28D4
mov edi, r13d
mov rsi, [rbp+var_38]
xor edx, edx
mov rcx, r12
call my_seek
mov r12, rax
loc_B27DF:
cmp r12, 0FFFFFFFFFFFFFFFFh
jz short loc_B2857
mov dword ptr [rbx+0E0h], 0
loc_B27EF:
mov r13d, [rbx+0D4h]
mov r12, [rbx+0F8h]
or r12, 4
lea rax, PSI_server
mov rax, [rax]
lea rdi, [rbp+var_80]
mov esi, r13d
mov edx, 7
call qword ptr [rax+158h]
test rax, rax
jnz short loc_B2875
mov edi, r13d
mov rsi, r15
mov r13, [rbp+var_30]
mov rdx, r13
mov rcx, r12
call my_write
mov r15, rax
loc_B283A:
test r15, r15
jz short loc_B2850
mov dword ptr [rbx+0E4h], 0FFFFFFFFh
mov eax, 0FFFFFFFFh
jmp short loc_B2866
loc_B2850:
add [rbx], r13
loc_B2853:
xor eax, eax
jmp short loc_B2866
loc_B2857:
mov dword ptr [rbx+0E4h], 0FFFFFFFFh
mov eax, 1
loc_B2866:
add rsp, 58h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_B2875:
mov r14, rax
lea rax, PSI_server
mov rax, [rax]
lea rdx, aWorkspaceLlm4b_26; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, r14
mov rsi, [rbp+var_30]
mov ecx, 5F6h
call qword ptr [rax+210h]
mov edi, r13d
mov r13, [rbp+var_30]
mov rsi, r15
mov rdx, r13
mov rcx, r12
call my_write
mov r15, rax
xor esi, esi
test rax, rax
cmovz rsi, r13
lea rax, PSI_server
mov rax, [rax]
mov rdi, r14
call qword ptr [rax+218h]
jmp loc_B283A
loc_B28D4:
mov r14, rax
lea rax, PSI_server
mov rax, [rax]
lea rdx, aWorkspaceLlm4b_26; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, r14
xor esi, esi
mov ecx, 5EFh
call qword ptr [rax+210h]
mov edi, r13d
mov rsi, [rbp+var_38]
xor edx, edx
mov rcx, r12
call my_seek
mov r12, rax
lea rax, PSI_server
mov rax, [rax]
mov rdi, r14
xor esi, esi
call qword ptr [rax+218h]
jmp loc_B27DF
| long long my_b_cache_write(long long *a1, long long a2, long long a3)
{
unsigned int v4; // r13d
long long v5; // r12
long long v6; // rax
long long v7; // r12
unsigned int v8; // r13d
long long v9; // r12
long long v10; // rax
unsigned int v11; // edi
long long v12; // r13
long long v13; // r15
long long v15; // r14
unsigned int v16; // edi
long long v17; // rsi
long long v18; // r14
_BYTE v19[72]; // [rsp+0h] [rbp-80h] BYREF
long long v20; // [rsp+48h] [rbp-38h]
long long v21; // [rsp+50h] [rbp-30h]
if ( a1[6] != a2 )
{
a3 = (unsigned int)a3 & 0xFFFFF000;
if ( !a3 )
return 0LL;
}
v21 = a3;
if ( !*((_DWORD *)a1 + 56) )
{
LABEL_8:
v8 = *((_DWORD *)a1 + 53);
v9 = a1[31] | 4;
v10 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v19, v8, 7LL);
if ( v10 )
{
v15 = v10;
((void ( *)(long long, long long, const char *, long long))PSI_server[66])(
v10,
v21,
"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",
1526LL);
v16 = v8;
v12 = v21;
v13 = my_write(v16, a2, v21, v9);
v17 = 0LL;
if ( !v13 )
v17 = v12;
((void ( *)(long long, long long))PSI_server[67])(v15, v17);
}
else
{
v11 = v8;
v12 = v21;
v13 = my_write(v11, a2, v21, v9);
}
if ( v13 )
{
*((_DWORD *)a1 + 57) = -1;
return 0xFFFFFFFFLL;
}
*a1 += v12;
return 0LL;
}
v4 = *((_DWORD *)a1 + 53);
v20 = *a1;
v5 = a1[31] & 0x10;
v6 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v19, v4, 8LL);
if ( v6 )
{
v18 = v6;
((void ( *)(long long, _QWORD, const char *, long long))PSI_server[66])(
v6,
0LL,
"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",
1519LL);
v7 = my_seek(v4, v20, 0LL, v5);
((void ( *)(long long, _QWORD))PSI_server[67])(v18, 0LL);
}
else
{
v7 = my_seek(v4, v20, 0LL, v5);
}
if ( v7 != -1 )
{
*((_DWORD *)a1 + 56) = 0;
goto LABEL_8;
}
*((_DWORD *)a1 + 57) = -1;
return 1LL;
}
| _my_b_cache_write:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x58
MOV R15,RSI
MOV RBX,RDI
CMP qword ptr [RDI + 0x30],RSI
JZ 0x001b2780
MOV EAX,0xfffff000
AND RDX,RAX
JZ 0x001b2853
LAB_001b2780:
MOV qword ptr [RBP + -0x30],RDX
CMP dword ptr [RBX + 0xe0],0x0
JZ 0x001b27ef
MOV R13D,dword ptr [RBX + 0xd4]
MOV RAX,qword ptr [RBX]
MOV qword ptr [RBP + -0x38],RAX
MOV R12,qword ptr [RBX + 0xf8]
AND R12D,0x10
LEA RAX,[0x4aea18]
MOV RAX,qword ptr [RAX]
LEA RDI,[RBP + -0x80]
MOV ESI,R13D
MOV EDX,0x8
CALL qword ptr [RAX + 0x158]
TEST RAX,RAX
JNZ 0x001b28d4
MOV EDI,R13D
MOV RSI,qword ptr [RBP + -0x38]
XOR EDX,EDX
MOV RCX,R12
CALL 0x001c056c
MOV R12,RAX
LAB_001b27df:
CMP R12,-0x1
JZ 0x001b2857
MOV dword ptr [RBX + 0xe0],0x0
LAB_001b27ef:
MOV R13D,dword ptr [RBX + 0xd4]
MOV R12,qword ptr [RBX + 0xf8]
OR R12,0x4
LEA RAX,[0x4aea18]
MOV RAX,qword ptr [RAX]
LEA RDI,[RBP + -0x80]
MOV ESI,R13D
MOV EDX,0x7
CALL qword ptr [RAX + 0x158]
TEST RAX,RAX
JNZ 0x001b2875
MOV EDI,R13D
MOV RSI,R15
MOV R13,qword ptr [RBP + -0x30]
MOV RDX,R13
MOV RCX,R12
CALL 0x0013175f
MOV R15,RAX
LAB_001b283a:
TEST R15,R15
JZ 0x001b2850
MOV dword ptr [RBX + 0xe4],0xffffffff
MOV EAX,0xffffffff
JMP 0x001b2866
LAB_001b2850:
ADD qword ptr [RBX],R13
LAB_001b2853:
XOR EAX,EAX
JMP 0x001b2866
LAB_001b2857:
MOV dword ptr [RBX + 0xe4],0xffffffff
MOV EAX,0x1
LAB_001b2866:
ADD RSP,0x58
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001b2875:
MOV R14,RAX
LEA RAX,[0x4aea18]
MOV RAX,qword ptr [RAX]
LEA RDX,[0x1ffbf7]
MOV RDI,R14
MOV RSI,qword ptr [RBP + -0x30]
MOV ECX,0x5f6
CALL qword ptr [RAX + 0x210]
MOV EDI,R13D
MOV R13,qword ptr [RBP + -0x30]
MOV RSI,R15
MOV RDX,R13
MOV RCX,R12
CALL 0x0013175f
MOV R15,RAX
XOR ESI,ESI
TEST RAX,RAX
CMOVZ RSI,R13
LEA RAX,[0x4aea18]
MOV RAX,qword ptr [RAX]
MOV RDI,R14
CALL qword ptr [RAX + 0x218]
JMP 0x001b283a
LAB_001b28d4:
MOV R14,RAX
LEA RAX,[0x4aea18]
MOV RAX,qword ptr [RAX]
LEA RDX,[0x1ffbf7]
MOV RDI,R14
XOR ESI,ESI
MOV ECX,0x5ef
CALL qword ptr [RAX + 0x210]
MOV EDI,R13D
MOV RSI,qword ptr [RBP + -0x38]
XOR EDX,EDX
MOV RCX,R12
CALL 0x001c056c
MOV R12,RAX
LEA RAX,[0x4aea18]
MOV RAX,qword ptr [RAX]
MOV RDI,R14
XOR ESI,ESI
CALL qword ptr [RAX + 0x218]
JMP 0x001b27df
|
int8 _my_b_cache_write(long *param_1,long param_2,ulong param_3)
{
int4 uVar1;
long lVar2;
long lVar3;
ulong uVar4;
uint uVar5;
ulong uVar6;
int1 local_88 [72];
long local_40;
ulong local_38;
if ((param_1[6] == param_2) || (param_3 = param_3 & 0xfffff000, param_3 != 0)) {
local_38 = param_3;
if ((int)param_1[0x1c] != 0) {
uVar1 = *(int4 *)((long)param_1 + 0xd4);
local_40 = *param_1;
uVar5 = (uint)param_1[0x1f] & 0x10;
lVar2 = (**(code **)(PSI_server + 0x158))(local_88,uVar1,8);
if (lVar2 == 0) {
lVar3 = my_seek(uVar1,local_40,0,uVar5);
}
else {
(**(code **)(PSI_server + 0x210))
(lVar2,0,"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x5ef);
lVar3 = my_seek(uVar1,local_40,0,uVar5);
(**(code **)(PSI_server + 0x218))(lVar2,0);
}
if (lVar3 == -1) {
*(int4 *)((long)param_1 + 0xe4) = 0xffffffff;
return 1;
}
*(int4 *)(param_1 + 0x1c) = 0;
}
uVar1 = *(int4 *)((long)param_1 + 0xd4);
uVar4 = param_1[0x1f];
lVar2 = (**(code **)(PSI_server + 0x158))(local_88,uVar1,7);
uVar6 = local_38;
if (lVar2 == 0) {
lVar3 = my_write(uVar1,param_2,local_38,uVar4 | 4);
}
else {
(**(code **)(PSI_server + 0x210))
(lVar2,local_38,"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x5f6)
;
uVar6 = local_38;
lVar3 = my_write(uVar1,param_2,local_38,uVar4 | 4);
uVar4 = 0;
if (lVar3 == 0) {
uVar4 = uVar6;
}
(**(code **)(PSI_server + 0x218))(lVar2,uVar4);
}
if (lVar3 != 0) {
*(int4 *)((long)param_1 + 0xe4) = 0xffffffff;
return 0xffffffff;
}
*param_1 = *param_1 + uVar6;
}
return 0;
}
| |
55,589 | makeContextCurrentEGL | untodesu[P]riteg/build_O0/_deps/glfw-src/src/egl_context.c | static void makeContextCurrentEGL(_GLFWwindow* window)
{
if (window)
{
if (!eglMakeCurrent(_glfw.egl.display,
window->context.egl.surface,
window->context.egl.surface,
window->context.egl.handle))
{
_glfwInputError(GLFW_PLATFORM_ERROR,
"EGL: Failed to make context current: %s",
getEGLErrorString(eglGetError()));
return;
}
}
else
{
if (!eglMakeCurrent(_glfw.egl.display,
EGL_NO_SURFACE,
EGL_NO_SURFACE,
EGL_NO_CONTEXT))
{
_glfwInputError(GLFW_PLATFORM_ERROR,
"EGL: Failed to clear current context: %s",
getEGLErrorString(eglGetError()));
return;
}
}
_glfwPlatformSetTls(&_glfw.contextSlot, window);
} | O0 | c | makeContextCurrentEGL:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
je 0x39d55
leaq 0xa6f7e(%rip), %rax # 0xe0c68
movq 0x20928(%rax), %rax
leaq 0xa6f70(%rip), %rcx # 0xe0c68
movq 0x208a0(%rcx), %rdi
movq -0x8(%rbp), %rcx
movq 0x290(%rcx), %rsi
movq -0x8(%rbp), %rcx
movq 0x290(%rcx), %rdx
movq -0x8(%rbp), %rcx
movq 0x288(%rcx), %rcx
callq *%rax
cmpl $0x0, %eax
jne 0x39d53
leaq 0xa6f3a(%rip), %rax # 0xe0c68
callq *0x208e8(%rax)
movl %eax, %edi
callq 0x38be0
movq %rax, %rdx
movl $0x10008, %edi # imm = 0x10008
leaq 0x829d8(%rip), %rsi # 0xbc722
movb $0x0, %al
callq 0x221a0
jmp 0x39dc5
jmp 0x39dae
leaq 0xa6f0c(%rip), %rax # 0xe0c68
movq 0x20928(%rax), %rax
leaq 0xa6efe(%rip), %rcx # 0xe0c68
movq 0x208a0(%rcx), %rdi
xorl %ecx, %ecx
movq %rcx, %rsi
movq %rcx, %rdx
callq *%rax
cmpl $0x0, %eax
jne 0x39dac
leaq 0xa6ee1(%rip), %rax # 0xe0c68
callq *0x208e8(%rax)
movl %eax, %edi
callq 0x38be0
movq %rax, %rdx
movl $0x10008, %edi # imm = 0x10008
leaq 0x829a7(%rip), %rsi # 0xbc74a
movb $0x0, %al
callq 0x221a0
jmp 0x39dc5
jmp 0x39dae
movq -0x8(%rbp), %rsi
leaq 0xa6eaf(%rip), %rdi # 0xe0c68
addq $0x1fe1c, %rdi # imm = 0x1FE1C
callq 0x367e0
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| makeContextCurrentEGL:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
cmp [rbp+var_8], 0
jz short loc_39D55
lea rax, _glfw
mov rax, [rax+20928h]
lea rcx, _glfw
mov rdi, qword ptr ds:_ZSt19__iterator_categoryIPKPKcENSt15iterator_traitsIT_E17iterator_categoryERKS5_[rcx]; std::__iterator_category<char const* const*>(char const* const* const&)
mov rcx, [rbp+var_8]
mov rsi, [rcx+290h]
mov rcx, [rbp+var_8]
mov rdx, [rcx+290h]
mov rcx, [rbp+var_8]
mov rcx, [rcx+288h]
call rax
cmp eax, 0
jnz short loc_39D53
lea rax, _glfw
call qword ptr ds:loc_208E8[rax]
mov edi, eax
call getEGLErrorString
mov rdx, rax
mov edi, 10008h
lea rsi, aEglFailedToMak; "EGL: Failed to make context current: %s"
mov al, 0
call _glfwInputError
jmp short loc_39DC5
loc_39D53:
jmp short loc_39DAE
loc_39D55:
lea rax, _glfw
mov rax, [rax+20928h]
lea rcx, _glfw
mov rdi, qword ptr ds:_ZSt19__iterator_categoryIPKPKcENSt15iterator_traitsIT_E17iterator_categoryERKS5_[rcx]; std::__iterator_category<char const* const*>(char const* const* const&)
xor ecx, ecx
mov rsi, rcx
mov rdx, rcx
call rax
cmp eax, 0
jnz short loc_39DAC
lea rax, _glfw
call qword ptr ds:loc_208E8[rax]
mov edi, eax
call getEGLErrorString
mov rdx, rax
mov edi, 10008h
lea rsi, aEglFailedToCle; "EGL: Failed to clear current context: %"...
mov al, 0
call _glfwInputError
jmp short loc_39DC5
loc_39DAC:
jmp short $+2
loc_39DAE:
mov rsi, [rbp+var_8]
lea rdi, _glfw
add rdi, 1FE1Ch
call _glfwPlatformSetTls
loc_39DC5:
add rsp, 10h
pop rbp
retn
| long long makeContextCurrentEGL(long long a1)
{
int v1; // eax
const char *EGLErrorString; // rax
int v4; // eax
const char *v5; // rax
if ( a1 )
{
if ( !(*(unsigned int ( **)(_QWORD, _QWORD, _QWORD, _QWORD))&glfw[33354])(
*(_QWORD *)((char *)std::__iterator_category<char const* const*> + (_QWORD)glfw),
*(_QWORD *)(a1 + 656),
*(_QWORD *)(a1 + 656),
*(_QWORD *)(a1 + 648)) )
{
v1 = (*(long long (**)(void))((char *)&loc_208E8 + (_QWORD)glfw))();
EGLErrorString = getEGLErrorString(v1);
return glfwInputError(0x10008u, (long long)"EGL: Failed to make context current: %s", EGLErrorString);
}
}
else if ( !(*(unsigned int ( **)(_QWORD, _QWORD, _QWORD))&glfw[33354])(
*(_QWORD *)((char *)std::__iterator_category<char const* const*> + (_QWORD)glfw),
0LL,
0LL) )
{
v4 = (*(long long (**)(void))((char *)&loc_208E8 + (_QWORD)glfw))();
v5 = getEGLErrorString(v4);
return glfwInputError(0x10008u, (long long)"EGL: Failed to clear current context: %s", v5);
}
return glfwPlatformSetTls(&glfw[32647], a1);
}
| makeContextCurrentEGL:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
CMP qword ptr [RBP + -0x8],0x0
JZ 0x00139d55
LEA RAX,[0x1e0c68]
MOV RAX,qword ptr [RAX + 0x20928]
LEA RCX,[0x1e0c68]
MOV RDI,qword ptr [RCX + 0x208a0]
MOV RCX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RCX + 0x290]
MOV RCX,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RCX + 0x290]
MOV RCX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RCX + 0x288]
CALL RAX
CMP EAX,0x0
JNZ 0x00139d53
LEA RAX,[0x1e0c68]
CALL qword ptr [RAX + 0x208e8]
MOV EDI,EAX
CALL 0x00138be0
MOV RDX,RAX
MOV EDI,0x10008
LEA RSI,[0x1bc722]
MOV AL,0x0
CALL 0x001221a0
JMP 0x00139dc5
LAB_00139d53:
JMP 0x00139dae
LAB_00139d55:
LEA RAX,[0x1e0c68]
MOV RAX,qword ptr [RAX + 0x20928]
LEA RCX,[0x1e0c68]
MOV RDI,qword ptr [RCX + 0x208a0]
XOR ECX,ECX
MOV RSI,RCX
MOV RDX,RCX
CALL RAX
CMP EAX,0x0
JNZ 0x00139dac
LEA RAX,[0x1e0c68]
CALL qword ptr [RAX + 0x208e8]
MOV EDI,EAX
CALL 0x00138be0
MOV RDX,RAX
MOV EDI,0x10008
LEA RSI,[0x1bc74a]
MOV AL,0x0
CALL 0x001221a0
JMP 0x00139dc5
LAB_00139dac:
JMP 0x00139dae
LAB_00139dae:
MOV RSI,qword ptr [RBP + -0x8]
LEA RDI,[0x1e0c68]
ADD RDI,0x1fe1c
CALL 0x001367e0
LAB_00139dc5:
ADD RSP,0x10
POP RBP
RET
|
void makeContextCurrentEGL(long param_1)
{
int iVar1;
int4 uVar2;
int8 uVar3;
if (param_1 == 0) {
iVar1 = (*DAT_00201590)(DAT_00201508,0,0);
if (iVar1 == 0) {
uVar2 = (*DAT_00201550)();
uVar3 = getEGLErrorString(uVar2);
_glfwInputError(0x10008,"EGL: Failed to clear current context: %s",uVar3);
return;
}
}
else {
iVar1 = (*DAT_00201590)(DAT_00201508,*(int8 *)(param_1 + 0x290),
*(int8 *)(param_1 + 0x290),*(int8 *)(param_1 + 0x288));
if (iVar1 == 0) {
uVar2 = (*DAT_00201550)();
uVar3 = getEGLErrorString(uVar2);
_glfwInputError(0x10008,"EGL: Failed to make context current: %s",uVar3);
return;
}
}
_glfwPlatformSetTls(&DAT_00200a84,param_1);
return;
}
| |
55,590 | ma_update_status_with_lock | eloqsql/storage/maria/ma_state.c | void _ma_update_status_with_lock(MARIA_HA *info)
{
my_bool locked= 0;
if (info->state == &info->state_save)
{
locked= 1;
mysql_mutex_lock(&info->s->lock.mutex);
}
(*info->s->lock.update_status)(info->lock.status_param);
if (locked)
mysql_mutex_unlock(&info->s->lock.mutex);
} | O0 | c | ma_update_status_with_lock:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movb $0x0, -0x9(%rbp)
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x8(%rbp), %rcx
addq $0x28, %rcx
cmpq %rcx, %rax
jne 0x369cc
movb $0x1, -0x9(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rdi
addq $0x7f0, %rdi # imm = 0x7F0
addq $0x18, %rdi
leaq 0x11aba4(%rip), %rsi # 0x151566
movl $0x168, %edx # imm = 0x168
callq 0x36500
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq 0x8b0(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x6b8(%rcx), %rdi
callq *%rax
cmpb $0x0, -0x9(%rbp)
je 0x36a04
movq -0x8(%rbp), %rax
movq (%rax), %rdi
addq $0x7f0, %rdi # imm = 0x7F0
addq $0x18, %rdi
callq 0x36570
addq $0x10, %rsp
popq %rbp
retq
nopw (%rax,%rax)
| _ma_update_status_with_lock:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov [rbp+var_9], 0
mov rax, [rbp+var_8]
mov rax, [rax+20h]
mov rcx, [rbp+var_8]
add rcx, 28h ; '('
cmp rax, rcx
jnz short loc_369CC
mov [rbp+var_9], 1
mov rax, [rbp+var_8]
mov rdi, [rax]
add rdi, 7F0h
add rdi, 18h
lea rsi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 168h
call inline_mysql_mutex_lock_3
loc_369CC:
mov rax, [rbp+var_8]
mov rax, [rax]
mov rax, [rax+8B0h]
mov rcx, [rbp+var_8]
mov rdi, [rcx+6B8h]
call rax
cmp [rbp+var_9], 0
jz short loc_36A04
mov rax, [rbp+var_8]
mov rdi, [rax]
add rdi, 7F0h
add rdi, 18h
call inline_mysql_mutex_unlock_3
loc_36A04:
add rsp, 10h
pop rbp
retn
| long long ma_update_status_with_lock(_QWORD *a1)
{
long long result; // rax
char v2; // [rsp+7h] [rbp-9h]
v2 = 0;
if ( (_QWORD *)a1[4] == a1 + 5 )
{
v2 = 1;
inline_mysql_mutex_lock_3(
*a1 + 2056LL,
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_state.c",
0x168u);
}
result = (*(long long ( **)(_QWORD))(*a1 + 2224LL))(a1[215]);
if ( v2 )
return inline_mysql_mutex_unlock_3(*a1 + 2056LL);
return result;
}
| _ma_update_status_with_lock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV byte ptr [RBP + -0x9],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x20]
MOV RCX,qword ptr [RBP + -0x8]
ADD RCX,0x28
CMP RAX,RCX
JNZ 0x001369cc
MOV byte ptr [RBP + -0x9],0x1
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX]
ADD RDI,0x7f0
ADD RDI,0x18
LEA RSI,[0x251566]
MOV EDX,0x168
CALL 0x00136500
LAB_001369cc:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x8b0]
MOV RCX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RCX + 0x6b8]
CALL RAX
CMP byte ptr [RBP + -0x9],0x0
JZ 0x00136a04
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX]
ADD RDI,0x7f0
ADD RDI,0x18
CALL 0x00136570
LAB_00136a04:
ADD RSP,0x10
POP RBP
RET
|
void _ma_update_status_with_lock(long *param_1)
{
long *plVar1;
plVar1 = (long *)param_1[4];
if (plVar1 == param_1 + 5) {
inline_mysql_mutex_lock
(*param_1 + 0x808,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_state.c",
0x168);
}
(**(code **)(*param_1 + 0x8b0))(param_1[0xd7]);
if (plVar1 == param_1 + 5) {
inline_mysql_mutex_unlock(*param_1 + 0x808);
}
return;
}
| |
55,591 | host_call | corpus-core[P]colibri-stateless/src/chains/eth/verifier/call_evmone.c | static void host_call(void* context, const struct evmone_message* msg, const uint8_t* code, size_t code_size, struct evmone_result* result) {
evmone_context_t* ctx = (evmone_context_t*) context;
EVM_LOG("========Executing child call...");
debug_print_address("call from", &msg->sender);
debug_print_address("call to", &msg->destination);
debug_print_address("code from", &msg->code_address);
EVM_LOG("call gas: %zu, depth: %d, is_static: %s", (size_t) msg->gas, msg->depth, msg->is_static ? "true" : "false");
if (bytes_all_zero(bytes(msg->code_address.bytes, 19)) && msg->code_address.bytes[19]) {
buffer_t output = {0};
uint64_t gas_used = 0;
pre_result_t pre_result = eth_execute_precompile(msg->code_address.bytes, bytes(msg->input_data, msg->input_size), &output, &gas_used);
result->output_data = output.data.data;
result->output_size = output.data.len;
result->gas_left = msg->gas - gas_used;
result->gas_refund = 0;
result->status_code = pre_result;
if (pre_result != PRE_SUCCESS) {
EVM_LOG("Precompile failed with status code: %d", pre_result);
result->gas_left = 0;
}
add_evm_result(ctx, result);
return;
}
// If code isn't provided (which happens during DELEGATECALL and CALLCODE),
// we need to fetch it from the account specified by code_address
const uint8_t* execution_code = code;
size_t execution_code_size = code_size;
bytes_t fetched_code = {0};
if ((execution_code == NULL || execution_code_size == 0) && msg->kind != CALL_KIND_CREATE && msg->kind != CALL_KIND_CREATE2) {
EVM_LOG("Code not provided, fetching from code_address");
fetched_code = get_code(ctx, msg->code_address.bytes);
execution_code = fetched_code.data;
execution_code_size = fetched_code.len;
EVM_LOG("Fetched code size: %zu bytes", execution_code_size);
}
EVM_LOG("call code size: %zu bytes", execution_code_size);
if (msg->input_data && msg->input_size > 0) {
EVM_LOG("call input data (%zu bytes): 0x", msg->input_size);
if (EVM_DEBUG) {
for (size_t i = 0; i < (msg->input_size > 64 ? 64 : msg->input_size); i++) {
fprintf(stderr, "%02x", msg->input_data[i]);
}
if (msg->input_size > 64) fprintf(stderr, "...");
fprintf(stderr, "\n");
}
}
evmone_context_t child = *ctx;
child.parent = ctx;
child.changed_accounts = NULL;
// Execute the code (now using fetched code if needed)
evmone_result exec_result = evmone_execute(
ctx->executor,
&host_interface,
&child,
14, // Revision - using CANCUN
msg,
execution_code,
execution_code_size);
EVM_LOG("Child call complete. Status: %d, Gas left: %zu", exec_result.status_code, (size_t) exec_result.gas_left);
if (exec_result.output_data && exec_result.output_size > 0) {
EVM_LOG("Child call output (%zu bytes): 0x", exec_result.output_size);
if (EVM_DEBUG) {
for (size_t i = 0; i < (exec_result.output_size > 64 ? 64 : exec_result.output_size); i++) {
fprintf(stderr, "%02x", exec_result.output_data[i]);
}
if (exec_result.output_size > 64) fprintf(stderr, "...");
fprintf(stderr, "\n");
}
}
add_evm_result(ctx, &exec_result);
if (exec_result.status_code == 0) {
context_apply(&child);
}
EVM_LOG("========/child call complete ====");
context_free(&child);
*result = exec_result;
} | O3 | c | host_call:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xf8, %rsp
movq %r8, %rbx
movq %rcx, %r13
movq %rdx, %r12
movq %rsi, %r15
movq %rdi, %r14
leaq 0x90(%rsi), %rbp
movl $0x13, %edi
movq %rbp, %rsi
xorl %edx, %edx
callq 0x51165
testb %al, %al
je 0x27cb8
cmpb $0x0, 0xa3(%r15)
je 0x27cb8
xorps %xmm0, %xmm0
leaq 0x50(%rsp), %r12
movaps %xmm0, (%r12)
xorl %eax, %eax
movq %rax, 0x10(%r12)
leaq 0x10(%rsp), %r13
movq %rax, (%r13)
movl 0x48(%r15), %esi
movq 0x40(%r15), %rdx
movq %rbp, %rdi
movq %r12, %rcx
movq %r13, %r8
callq 0x50e68
movq 0x8(%r12), %rcx
movq %rcx, 0x18(%rbx)
movl (%r12), %ecx
movq %rcx, 0x20(%rbx)
movq 0x10(%r15), %rcx
subq (%r13), %rcx
movq %rcx, 0x8(%rbx)
xorl %ecx, %ecx
movq %rcx, 0x10(%rbx)
movl %eax, (%rbx)
testl %eax, %eax
je 0x27c79
movq $0x0, 0x8(%rbx)
movl $0x48, %edi
callq 0x50ecc
movups (%rbx), %xmm0
movups 0x10(%rbx), %xmm1
movups 0x20(%rbx), %xmm2
movups 0x30(%rbx), %xmm3
movups %xmm0, (%rax)
movups %xmm1, 0x10(%rax)
movups %xmm2, 0x20(%rax)
movups %xmm3, 0x30(%rax)
movq 0x98(%r14), %rcx
movq %rcx, 0x40(%rax)
movq %rax, 0x98(%r14)
jmp 0x27e35
testq %r12, %r12
setne %al
testq %r13, %r13
setne %cl
testb %cl, %al
jne 0x27ce4
movl (%r15), %eax
addl $-0x3, %eax
cmpl $0x2, %eax
jb 0x27ce4
movq %r14, %rdi
movq %rbp, %rsi
callq 0x274f2
movq %rdx, %r12
movl %eax, %r13d
leaq 0x50(%rsp), %rbp
movl $0xa0, %edx
movq %rbp, %rdi
movq %r14, %rsi
callq 0x211a0
movq %r14, 0x90(%rbp)
movq $0x0, 0x28(%rbp)
movq (%r14), %rsi
leaq 0x82e9e(%rip), %rdx # 0xaabb0
movq %r12, %rax
leaq 0x10(%rsp), %r12
movq %r12, %rdi
movq %rbp, %rcx
movl $0xe, %r8d
movq %r15, %r9
pushq %r13
pushq %rax
callq 0x2da1b
addq $0x10, %rsp
movl $0x48, %edi
callq 0x50ecc
movups (%r12), %xmm0
movups 0x10(%r12), %xmm1
movups 0x20(%r12), %xmm2
movups 0x30(%r12), %xmm3
movups %xmm0, (%rax)
movups %xmm1, 0x10(%rax)
movups %xmm2, 0x20(%rax)
movups %xmm3, 0x30(%rax)
movq 0x98(%r14), %rcx
movq %rcx, 0x40(%rax)
movq %rax, 0x98(%r14)
cmpl $0x0, (%r12)
jne 0x27e08
cmpq $0x0, 0xe0(%rsp)
je 0x27e08
movq 0x78(%rsp), %r14
testq %r14, %r14
je 0x27e08
leaq 0xf(%rsp), %r15
movq 0xe0(%rsp), %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x27f55
movups 0x14(%r14), %xmm0
movups 0x24(%r14), %xmm1
movups %xmm0, 0x14(%rax)
movups %xmm1, 0x24(%rax)
movups 0x38(%r14), %xmm0
movups %xmm0, 0x38(%rax)
movb 0x59(%r14), %cl
movb %cl, 0x59(%rax)
movq 0x50(%r14), %r12
testq %r12, %r12
je 0x27dff
movq 0xe0(%rsp), %rdi
leaq 0x20(%r12), %rcx
movq %r14, %rsi
movq %r12, %rdx
movq %r15, %r8
movq %r15, %r9
callq 0x27eb4
movq 0x40(%r12), %r12
jmp 0x27dd5
movq 0x48(%r14), %r14
testq %r14, %r14
jne 0x27d9c
leaq 0x50(%rsp), %rdi
callq 0x275ec
movups 0x10(%rsp), %xmm0
movups 0x20(%rsp), %xmm1
movups 0x30(%rsp), %xmm2
movups 0x40(%rsp), %xmm3
movups %xmm3, 0x30(%rbx)
movups %xmm2, 0x20(%rbx)
movups %xmm1, 0x10(%rbx)
movups %xmm0, (%rbx)
addq $0xf8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| host_call:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0F8h
mov rbx, r8
mov r13, rcx
mov r12, rdx
mov r15, rsi
mov r14, rdi
lea rbp, [rsi+90h]
mov edi, 13h
mov rsi, rbp
xor edx, edx
call bytes_all_equal
test al, al
jz loc_27CB8
cmp byte ptr [r15+0A3h], 0
jz loc_27CB8
xorps xmm0, xmm0
lea r12, [rsp+128h+var_D8]
movaps xmmword ptr [r12], xmm0
xor eax, eax
mov [r12+10h], rax
lea r13, [rsp+128h+var_118]
mov [r13+0], rax
mov esi, [r15+48h]
mov rdx, [r15+40h]
mov rdi, rbp
mov rcx, r12
mov r8, r13
call eth_execute_precompile
mov rcx, [r12+8]
mov [rbx+18h], rcx
mov ecx, [r12]
mov [rbx+20h], rcx
mov rcx, [r15+10h]
sub rcx, [r13+0]
mov [rbx+8], rcx
xor ecx, ecx
mov [rbx+10h], rcx
mov [rbx], eax
test eax, eax
jz short loc_27C79
mov qword ptr [rbx+8], 0
loc_27C79:
mov edi, 48h ; 'H'
call safe_malloc
movups xmm0, xmmword ptr [rbx]
movups xmm1, xmmword ptr [rbx+10h]
movups xmm2, xmmword ptr [rbx+20h]
movups xmm3, xmmword ptr [rbx+30h]
movups xmmword ptr [rax], xmm0
movups xmmword ptr [rax+10h], xmm1
movups xmmword ptr [rax+20h], xmm2
movups xmmword ptr [rax+30h], xmm3
mov rcx, [r14+98h]
mov [rax+40h], rcx
mov [r14+98h], rax
jmp loc_27E35
loc_27CB8:
test r12, r12
setnz al
test r13, r13
setnz cl
test al, cl
jnz short loc_27CE4
mov eax, [r15]
add eax, 0FFFFFFFDh
cmp eax, 2
jb short loc_27CE4
mov rdi, r14
mov rsi, rbp
call get_code
mov r12, rdx
mov r13d, eax
loc_27CE4:
lea rbp, [rsp+128h+var_D8]
mov edx, 0A0h
mov rdi, rbp
mov rsi, r14
call _memcpy
mov [rbp+90h], r14
mov qword ptr [rbp+28h], 0
mov rsi, [r14]
lea rdx, host_interface
mov rax, r12
lea r12, [rsp+128h+var_118]
mov rdi, r12
mov rcx, rbp
mov r8d, 0Eh
mov r9, r15
push r13
push rax
call evmone_execute
add rsp, 10h
mov edi, 48h ; 'H'
call safe_malloc
movups xmm0, xmmword ptr [r12]
movups xmm1, xmmword ptr [r12+10h]
movups xmm2, xmmword ptr [r12+20h]
movups xmm3, xmmword ptr [r12+30h]
movups xmmword ptr [rax], xmm0
movups xmmword ptr [rax+10h], xmm1
movups xmmword ptr [rax+20h], xmm2
movups xmmword ptr [rax+30h], xmm3
mov rcx, [r14+98h]
mov [rax+40h], rcx
mov [r14+98h], rax
cmp dword ptr [r12], 0
jnz loc_27E08
cmp [rsp+128h+var_48], 0
jz short loc_27E08
mov r14, [rsp+128h+var_B0]
test r14, r14
jz short loc_27E08
lea r15, [rsp+128h+var_119]
loc_27D9C:
mov rdi, [rsp+128h+var_48]
mov rsi, r14
mov rdx, r15
call create_changed_account
movups xmm0, xmmword ptr [r14+14h]
movups xmm1, xmmword ptr [r14+24h]
movups xmmword ptr [rax+14h], xmm0
movups xmmword ptr [rax+24h], xmm1
movups xmm0, xmmword ptr [r14+38h]
movups xmmword ptr [rax+38h], xmm0
mov cl, [r14+59h]
mov [rax+59h], cl
mov r12, [r14+50h]
loc_27DD5:
test r12, r12
jz short loc_27DFF
mov rdi, [rsp+128h+var_48]
lea rcx, [r12+20h]
mov rsi, r14
mov rdx, r12
mov r8, r15
mov r9, r15
call set_changed_storage
mov r12, [r12+40h]
jmp short loc_27DD5
loc_27DFF:
mov r14, [r14+48h]
test r14, r14
jnz short loc_27D9C
loc_27E08:
lea rdi, [rsp+128h+var_D8]
call context_free
movups xmm0, [rsp+128h+var_118]
movups xmm1, [rsp+128h+var_108]
movups xmm2, [rsp+128h+var_F8]
movups xmm3, [rsp+128h+var_E8]
movups xmmword ptr [rbx+30h], xmm3
movups xmmword ptr [rbx+20h], xmm2
movups xmmword ptr [rbx+10h], xmm1
movups xmmword ptr [rbx], xmm0
loc_27E35:
add rsp, 0F8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long host_call(_QWORD *a1, long long a2, long long a3, long long a4, long long a5)
{
long long v8; // rbp
int v9; // eax
long long result; // rax
__int128 v11; // xmm1
__int128 v12; // xmm2
__int128 v13; // xmm3
unsigned int code; // eax
long long v15; // rdx
long long v16; // rax
__int128 v17; // xmm1
__int128 v18; // xmm2
__int128 v19; // xmm3
long long i; // r14
long long v21; // rax
__int128 v22; // xmm1
long long j; // r12
__int128 v24; // xmm0
__int128 v25; // xmm1
__int128 v26; // xmm2
__int128 v27; // [rsp-10h] [rbp-138h]
char v28; // [rsp+Fh] [rbp-119h] BYREF
__int128 v29; // [rsp+10h] [rbp-118h] BYREF
__int128 v30; // [rsp+20h] [rbp-108h]
__int128 v31; // [rsp+30h] [rbp-F8h]
__int128 v32; // [rsp+40h] [rbp-E8h]
__int128 v33; // [rsp+50h] [rbp-D8h] BYREF
long long v34; // [rsp+60h] [rbp-C8h]
long long v35; // [rsp+78h] [rbp-B0h]
_QWORD *v36; // [rsp+E0h] [rbp-48h]
v8 = a2 + 144;
if ( (unsigned __int8)bytes_all_equal(19LL, a2 + 144, 0LL) && *(_BYTE *)(a2 + 163) )
{
v33 = 0LL;
v34 = 0LL;
*(_QWORD *)&v29 = 0LL;
v9 = eth_execute_precompile(v8, *(unsigned int *)(a2 + 72), *(_QWORD *)(a2 + 64), &v33, &v29);
*(_QWORD *)(a5 + 24) = *((_QWORD *)&v33 + 1);
*(_QWORD *)(a5 + 32) = (unsigned int)v33;
*(_QWORD *)(a5 + 8) = *(_QWORD *)(a2 + 16) - v29;
*(_QWORD *)(a5 + 16) = 0LL;
*(_DWORD *)a5 = v9;
if ( v9 )
*(_QWORD *)(a5 + 8) = 0LL;
result = safe_malloc(72LL);
v11 = *(_OWORD *)(a5 + 16);
v12 = *(_OWORD *)(a5 + 32);
v13 = *(_OWORD *)(a5 + 48);
*(_OWORD *)result = *(_OWORD *)a5;
*(_OWORD *)(result + 16) = v11;
*(_OWORD *)(result + 32) = v12;
*(_OWORD *)(result + 48) = v13;
*(_QWORD *)(result + 64) = a1[19];
a1[19] = result;
}
else
{
if ( (a4 == 0 || a3 == 0) && (unsigned int)(*(_DWORD *)a2 - 3) >= 2 )
{
code = get_code((long long)a1, v8);
a3 = v15;
a4 = code;
}
memcpy(&v33);
v36 = a1;
v35 = 0LL;
*((_QWORD *)&v27 + 1) = a4;
*(_QWORD *)&v27 = a3;
evmone_execute((unsigned int)&v29, *a1, (unsigned int)host_interface, (unsigned int)&v33, 14, a2, v27);
v16 = safe_malloc(72LL);
v17 = v30;
v18 = v31;
v19 = v32;
*(_OWORD *)v16 = v29;
*(_OWORD *)(v16 + 16) = v17;
*(_OWORD *)(v16 + 32) = v18;
*(_OWORD *)(v16 + 48) = v19;
*(_QWORD *)(v16 + 64) = a1[19];
a1[19] = v16;
if ( !(_DWORD)v29 )
{
if ( v36 )
{
for ( i = v35; i; i = *(_QWORD *)(i + 72) )
{
v21 = create_changed_account(v36, i, &v28);
v22 = *(_OWORD *)(i + 36);
*(_OWORD *)(v21 + 20) = *(_OWORD *)(i + 20);
*(_OWORD *)(v21 + 36) = v22;
*(_OWORD *)(v21 + 56) = *(_OWORD *)(i + 56);
*(_BYTE *)(v21 + 89) = *(_BYTE *)(i + 89);
for ( j = *(_QWORD *)(i + 80); j; j = *(_QWORD *)(j + 64) )
set_changed_storage(v36, i, j, j + 32, &v28, &v28);
}
}
}
result = context_free((long long)&v33);
v24 = v29;
v25 = v30;
v26 = v31;
*(_OWORD *)(a5 + 48) = v32;
*(_OWORD *)(a5 + 32) = v26;
*(_OWORD *)(a5 + 16) = v25;
*(_OWORD *)a5 = v24;
}
return result;
}
| host_call:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xf8
MOV RBX,R8
MOV R13,RCX
MOV R12,RDX
MOV R15,RSI
MOV R14,RDI
LEA RBP,[RSI + 0x90]
MOV EDI,0x13
MOV RSI,RBP
XOR EDX,EDX
CALL 0x00151165
TEST AL,AL
JZ 0x00127cb8
CMP byte ptr [R15 + 0xa3],0x0
JZ 0x00127cb8
XORPS XMM0,XMM0
LEA R12,[RSP + 0x50]
MOVAPS xmmword ptr [R12],XMM0
XOR EAX,EAX
MOV qword ptr [R12 + 0x10],RAX
LEA R13,[RSP + 0x10]
MOV qword ptr [R13],RAX
MOV ESI,dword ptr [R15 + 0x48]
MOV RDX,qword ptr [R15 + 0x40]
MOV RDI,RBP
MOV RCX,R12
MOV R8,R13
CALL 0x00150e68
MOV RCX,qword ptr [R12 + 0x8]
MOV qword ptr [RBX + 0x18],RCX
MOV ECX,dword ptr [R12]
MOV qword ptr [RBX + 0x20],RCX
MOV RCX,qword ptr [R15 + 0x10]
SUB RCX,qword ptr [R13]
MOV qword ptr [RBX + 0x8],RCX
XOR ECX,ECX
MOV qword ptr [RBX + 0x10],RCX
MOV dword ptr [RBX],EAX
TEST EAX,EAX
JZ 0x00127c79
MOV qword ptr [RBX + 0x8],0x0
LAB_00127c79:
MOV EDI,0x48
CALL 0x00150ecc
MOVUPS XMM0,xmmword ptr [RBX]
MOVUPS XMM1,xmmword ptr [RBX + 0x10]
MOVUPS XMM2,xmmword ptr [RBX + 0x20]
MOVUPS XMM3,xmmword ptr [RBX + 0x30]
MOVUPS xmmword ptr [RAX],XMM0
MOVUPS xmmword ptr [RAX + 0x10],XMM1
MOVUPS xmmword ptr [RAX + 0x20],XMM2
MOVUPS xmmword ptr [RAX + 0x30],XMM3
MOV RCX,qword ptr [R14 + 0x98]
MOV qword ptr [RAX + 0x40],RCX
MOV qword ptr [R14 + 0x98],RAX
JMP 0x00127e35
LAB_00127cb8:
TEST R12,R12
SETNZ AL
TEST R13,R13
SETNZ CL
TEST AL,CL
JNZ 0x00127ce4
MOV EAX,dword ptr [R15]
ADD EAX,-0x3
CMP EAX,0x2
JC 0x00127ce4
MOV RDI,R14
MOV RSI,RBP
CALL 0x001274f2
MOV R12,RDX
MOV R13D,EAX
LAB_00127ce4:
LEA RBP,[RSP + 0x50]
MOV EDX,0xa0
MOV RDI,RBP
MOV RSI,R14
CALL 0x001211a0
MOV qword ptr [RBP + 0x90],R14
MOV qword ptr [RBP + 0x28],0x0
MOV RSI,qword ptr [R14]
LEA RDX,[0x1aabb0]
MOV RAX,R12
LEA R12,[RSP + 0x10]
MOV RDI,R12
MOV RCX,RBP
MOV R8D,0xe
MOV R9,R15
PUSH R13
PUSH RAX
CALL 0x0012da1b
ADD RSP,0x10
MOV EDI,0x48
CALL 0x00150ecc
MOVUPS XMM0,xmmword ptr [R12]
MOVUPS XMM1,xmmword ptr [R12 + 0x10]
MOVUPS XMM2,xmmword ptr [R12 + 0x20]
MOVUPS XMM3,xmmword ptr [R12 + 0x30]
MOVUPS xmmword ptr [RAX],XMM0
MOVUPS xmmword ptr [RAX + 0x10],XMM1
MOVUPS xmmword ptr [RAX + 0x20],XMM2
MOVUPS xmmword ptr [RAX + 0x30],XMM3
MOV RCX,qword ptr [R14 + 0x98]
MOV qword ptr [RAX + 0x40],RCX
MOV qword ptr [R14 + 0x98],RAX
CMP dword ptr [R12],0x0
JNZ 0x00127e08
CMP qword ptr [RSP + 0xe0],0x0
JZ 0x00127e08
MOV R14,qword ptr [RSP + 0x78]
TEST R14,R14
JZ 0x00127e08
LEA R15,[RSP + 0xf]
LAB_00127d9c:
MOV RDI,qword ptr [RSP + 0xe0]
MOV RSI,R14
MOV RDX,R15
CALL 0x00127f55
MOVUPS XMM0,xmmword ptr [R14 + 0x14]
MOVUPS XMM1,xmmword ptr [R14 + 0x24]
MOVUPS xmmword ptr [RAX + 0x14],XMM0
MOVUPS xmmword ptr [RAX + 0x24],XMM1
MOVUPS XMM0,xmmword ptr [R14 + 0x38]
MOVUPS xmmword ptr [RAX + 0x38],XMM0
MOV CL,byte ptr [R14 + 0x59]
MOV byte ptr [RAX + 0x59],CL
MOV R12,qword ptr [R14 + 0x50]
LAB_00127dd5:
TEST R12,R12
JZ 0x00127dff
MOV RDI,qword ptr [RSP + 0xe0]
LEA RCX,[R12 + 0x20]
MOV RSI,R14
MOV RDX,R12
MOV R8,R15
MOV R9,R15
CALL 0x00127eb4
MOV R12,qword ptr [R12 + 0x40]
JMP 0x00127dd5
LAB_00127dff:
MOV R14,qword ptr [R14 + 0x48]
TEST R14,R14
JNZ 0x00127d9c
LAB_00127e08:
LEA RDI,[RSP + 0x50]
CALL 0x001275ec
MOVUPS XMM0,xmmword ptr [RSP + 0x10]
MOVUPS XMM1,xmmword ptr [RSP + 0x20]
MOVUPS XMM2,xmmword ptr [RSP + 0x30]
MOVUPS XMM3,xmmword ptr [RSP + 0x40]
MOVUPS xmmword ptr [RBX + 0x30],XMM3
MOVUPS xmmword ptr [RBX + 0x20],XMM2
MOVUPS xmmword ptr [RBX + 0x10],XMM1
MOVUPS xmmword ptr [RBX],XMM0
LAB_00127e35:
ADD RSP,0xf8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void host_call(int8 *param_1,int *param_2,long param_3,ulong param_4,int *param_5)
{
int4 uVar1;
int4 uVar2;
int4 uVar3;
int8 uVar4;
int8 uVar5;
int8 uVar6;
int8 uVar7;
int8 uVar8;
int8 uVar9;
int8 uVar10;
char cVar11;
int iVar12;
uint uVar13;
int8 *puVar14;
int *piVar15;
long lVar16;
long extraout_RDX;
long lVar17;
int1 local_119;
int8 local_118;
int iStack_110;
int iStack_10c;
int8 local_108;
int8 uStack_100;
int8 local_f8;
int8 uStack_f0;
int8 local_e8;
int8 uStack_e0;
ulong local_d8;
int8 uStack_d0;
int8 local_c8;
long local_b0;
int8 *local_48;
piVar15 = param_2 + 0x24;
cVar11 = bytes_all_equal(0x13,piVar15,0);
if ((cVar11 == '\0') || (*(char *)((long)param_2 + 0xa3) == '\0')) {
if ((param_3 == 0 || param_4 == 0) && (1 < *param_2 - 3U)) {
uVar13 = get_code(param_1,piVar15);
param_4 = (ulong)uVar13;
param_3 = extraout_RDX;
}
memcpy(&local_d8,param_1,0xa0);
local_b0 = 0;
local_48 = param_1;
evmone_execute(&local_118,*param_1,host_interface,&local_d8,0xe,param_2,param_3,param_4);
piVar15 = (int *)safe_malloc(0x48);
*piVar15 = (int)local_118;
piVar15[1] = local_118._4_4_;
piVar15[2] = iStack_110;
piVar15[3] = iStack_10c;
*(int8 *)(piVar15 + 4) = local_108;
*(int8 *)(piVar15 + 6) = uStack_100;
*(int8 *)(piVar15 + 8) = local_f8;
*(int8 *)(piVar15 + 10) = uStack_f0;
*(int8 *)(piVar15 + 0xc) = local_e8;
*(int8 *)(piVar15 + 0xe) = uStack_e0;
*(int8 *)(piVar15 + 0x10) = param_1[0x13];
param_1[0x13] = piVar15;
if ((((int)local_118 == 0) && (local_48 != (int8 *)0x0)) && (local_b0 != 0)) {
lVar17 = local_b0;
do {
lVar16 = create_changed_account(local_48,lVar17,&local_119);
uVar4 = *(int8 *)(lVar17 + 0x1c);
uVar5 = *(int8 *)(lVar17 + 0x24);
uVar6 = *(int8 *)(lVar17 + 0x2c);
*(int8 *)(lVar16 + 0x14) = *(int8 *)(lVar17 + 0x14);
*(int8 *)(lVar16 + 0x1c) = uVar4;
*(int8 *)(lVar16 + 0x24) = uVar5;
*(int8 *)(lVar16 + 0x2c) = uVar6;
uVar1 = *(int4 *)(lVar17 + 0x3c);
uVar2 = *(int4 *)(lVar17 + 0x40);
uVar3 = *(int4 *)(lVar17 + 0x44);
*(int4 *)(lVar16 + 0x38) = *(int4 *)(lVar17 + 0x38);
*(int4 *)(lVar16 + 0x3c) = uVar1;
*(int4 *)(lVar16 + 0x40) = uVar2;
*(int4 *)(lVar16 + 0x44) = uVar3;
*(int1 *)(lVar16 + 0x59) = *(int1 *)(lVar17 + 0x59);
for (lVar16 = *(long *)(lVar17 + 0x50); lVar16 != 0; lVar16 = *(long *)(lVar16 + 0x40)) {
set_changed_storage(local_48,lVar17,lVar16,lVar16 + 0x20,&local_119,&local_119);
}
lVar17 = *(long *)(lVar17 + 0x48);
} while (lVar17 != 0);
}
context_free(&local_d8);
*(int8 *)(param_5 + 0xc) = local_e8;
*(int8 *)(param_5 + 0xe) = uStack_e0;
*(int8 *)(param_5 + 8) = local_f8;
*(int8 *)(param_5 + 10) = uStack_f0;
*(int8 *)(param_5 + 4) = local_108;
*(int8 *)(param_5 + 6) = uStack_100;
*(long *)param_5 = local_118;
*(ulong *)(param_5 + 2) = CONCAT44(iStack_10c,iStack_110);
}
else {
local_d8 = 0;
uStack_d0 = 0;
local_c8 = 0;
local_118 = 0;
iVar12 = eth_execute_precompile
(piVar15,param_2[0x12],*(int8 *)(param_2 + 0x10),&local_d8,&local_118);
*(int8 *)(param_5 + 6) = uStack_d0;
*(ulong *)(param_5 + 8) = local_d8 & 0xffffffff;
*(long *)(param_5 + 2) = *(long *)(param_2 + 4) - local_118;
param_5[4] = 0;
param_5[5] = 0;
*param_5 = iVar12;
if (iVar12 != 0) {
param_5[2] = 0;
param_5[3] = 0;
}
puVar14 = (int8 *)safe_malloc(0x48);
uVar4 = *(int8 *)(param_5 + 2);
uVar5 = *(int8 *)(param_5 + 4);
uVar6 = *(int8 *)(param_5 + 6);
uVar7 = *(int8 *)(param_5 + 8);
uVar8 = *(int8 *)(param_5 + 10);
uVar9 = *(int8 *)(param_5 + 0xc);
uVar10 = *(int8 *)(param_5 + 0xe);
*puVar14 = *(int8 *)param_5;
puVar14[1] = uVar4;
puVar14[2] = uVar5;
puVar14[3] = uVar6;
puVar14[4] = uVar7;
puVar14[5] = uVar8;
puVar14[6] = uVar9;
puVar14[7] = uVar10;
puVar14[8] = param_1[0x13];
param_1[0x13] = puVar14;
}
return;
}
| |
55,592 | ma_strmake | eloqsql/libmariadb/libmariadb/ma_string.c | char *ma_strmake(register char *dst, register const char *src, size_t length)
{
while (length--)
if (! (*dst++ = *src++))
return dst-1;
*dst=0;
return dst;
} | O0 | c | ma_strmake:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rax, %rcx
addq $-0x1, %rcx
movq %rcx, -0x20(%rbp)
cmpq $0x0, %rax
je 0x31d1b
movq -0x18(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x18(%rbp)
movb (%rax), %al
movq -0x10(%rbp), %rcx
movq %rcx, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %al, (%rcx)
cmpb $0x0, %al
jne 0x31d19
movq -0x10(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x8(%rbp)
jmp 0x31d2a
jmp 0x31cd0
movq -0x10(%rbp), %rax
movb $0x0, (%rax)
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
popq %rbp
retq
| ma_strmake:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
loc_31CD0:
mov rax, [rbp+var_20]
mov rcx, rax
add rcx, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_20], rcx
cmp rax, 0
jz short loc_31D1B
mov rax, [rbp+var_18]
mov rcx, rax
add rcx, 1
mov [rbp+var_18], rcx
mov al, [rax]
mov rcx, [rbp+var_10]
mov rdx, rcx
add rdx, 1
mov [rbp+var_10], rdx
mov [rcx], al
cmp al, 0
jnz short loc_31D19
mov rax, [rbp+var_10]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_8], rax
jmp short loc_31D2A
loc_31D19:
jmp short loc_31CD0
loc_31D1B:
mov rax, [rbp+var_10]
mov byte ptr [rax], 0
mov rax, [rbp+var_10]
mov [rbp+var_8], rax
loc_31D2A:
mov rax, [rbp+var_8]
pop rbp
retn
| _BYTE * ma_strmake(_BYTE *a1, _BYTE *a2, long long a3)
{
_BYTE *v4; // rax
_BYTE *v5; // rcx
while ( a3-- )
{
v4 = a2++;
LOBYTE(v4) = *v4;
v5 = a1++;
*v5 = (_BYTE)v4;
if ( !(_BYTE)v4 )
return a1 - 1;
}
*a1 = 0;
return a1;
}
| ma_strmake:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
LAB_00131cd0:
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,RAX
ADD RCX,-0x1
MOV qword ptr [RBP + -0x20],RCX
CMP RAX,0x0
JZ 0x00131d1b
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,RAX
ADD RCX,0x1
MOV qword ptr [RBP + -0x18],RCX
MOV AL,byte ptr [RAX]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDX,RCX
ADD RDX,0x1
MOV qword ptr [RBP + -0x10],RDX
MOV byte ptr [RCX],AL
CMP AL,0x0
JNZ 0x00131d19
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x8],RAX
JMP 0x00131d2a
LAB_00131d19:
JMP 0x00131cd0
LAB_00131d1b:
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x8],RAX
LAB_00131d2a:
MOV RAX,qword ptr [RBP + -0x8]
POP RBP
RET
|
char * ma_strmake(char *param_1,char *param_2,long param_3)
{
char cVar1;
char *pcVar2;
long local_28;
char *local_20;
char *local_18;
local_28 = param_3;
local_20 = param_2;
pcVar2 = param_1;
do {
local_18 = pcVar2;
if (local_28 == 0) {
*local_18 = '\0';
return local_18;
}
cVar1 = *local_20;
*local_18 = cVar1;
local_28 = local_28 + -1;
local_20 = local_20 + 1;
pcVar2 = local_18 + 1;
} while (cVar1 != '\0');
return local_18;
}
| |
55,593 | type_pair_create | tsotchke[P]eshkol/src/core/utils/type_creation.c | Type* type_pair_create(Arena* arena, Type* car_type, Type* cdr_type) {
assert(car_type != NULL);
assert(cdr_type != NULL);
Type* type = arena_alloc(arena, sizeof(Type));
if (!type) return NULL;
type->kind = TYPE_PAIR;
// Allocate memory for parameters
Type** params = arena_alloc(arena, 2 * sizeof(Type*));
if (!params) return NULL;
params[0] = car_type;
params[1] = cdr_type;
type->function.param_count = 2;
type->function.params = params;
type->function.return_type = NULL;
type->function.variadic = false;
return type;
} | O3 | c | type_pair_create:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
testq %rsi, %rsi
je 0x2c7f
movq %rdx, %rbx
testq %rdx, %rdx
je 0x2c9e
movq %rsi, %r15
movq %rdi, %r12
movl $0x28, %esi
callq 0x2877
testq %rax, %rax
je 0x2c6d
movq %rax, %r14
movl $0x7, (%rax)
movl $0x10, %esi
movq %r12, %rdi
callq 0x2877
testq %rax, %rax
je 0x2c6d
movq %r15, (%rax)
movq %rbx, 0x8(%rax)
movq $0x2, 0x8(%r14)
movq %rax, 0x10(%r14)
movq $0x0, 0x18(%r14)
movb $0x0, 0x20(%r14)
jmp 0x2c70
xorl %r14d, %r14d
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x3412(%rip), %rdi # 0x6098
leaq 0x341c(%rip), %rsi # 0x60a9
leaq 0x346e(%rip), %rcx # 0x6102
movl $0x66, %edx
callq 0x10e0
leaq 0x348d(%rip), %rdi # 0x6132
leaq 0x33fd(%rip), %rsi # 0x60a9
leaq 0x344f(%rip), %rcx # 0x6102
movl $0x67, %edx
callq 0x10e0
| type_pair_create:
push r15
push r14
push r12
push rbx
push rax
test rsi, rsi
jz short loc_2C7F
mov rbx, rdx
test rdx, rdx
jz loc_2C9E
mov r15, rsi
mov r12, rdi
mov esi, 28h ; '('
call arena_alloc
test rax, rax
jz short loc_2C6D
mov r14, rax
mov dword ptr [rax], 7
mov esi, 10h
mov rdi, r12
call arena_alloc
test rax, rax
jz short loc_2C6D
mov [rax], r15
mov [rax+8], rbx
mov qword ptr [r14+8], 2
mov [r14+10h], rax
mov qword ptr [r14+18h], 0
mov byte ptr [r14+20h], 0
jmp short loc_2C70
loc_2C6D:
xor r14d, r14d
loc_2C70:
mov rax, r14
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
loc_2C7F:
lea rdi, aCarTypeNull; "car_type != NULL"
lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aTypeTypePairCr; "Type *type_pair_create(Arena *, Type *,"...
mov edx, 66h ; 'f'
call ___assert_fail
loc_2C9E:
lea rdi, aCdrTypeNull; "cdr_type != NULL"
lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aTypeTypePairCr; "Type *type_pair_create(Arena *, Type *,"...
mov edx, 67h ; 'g'
call ___assert_fail
| _DWORD * type_pair_create(long long a1, long long a2, long long a3)
{
_DWORD *v4; // rax
_DWORD *v5; // r14
_QWORD *v6; // rax
if ( !a2 )
__assert_fail(
"car_type != NULL",
"/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/type_creation.c",
102LL,
"Type *type_pair_create(Arena *, Type *, Type *)");
if ( !a3 )
__assert_fail(
"cdr_type != NULL",
"/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/type_creation.c",
103LL,
"Type *type_pair_create(Arena *, Type *, Type *)");
v4 = (_DWORD *)arena_alloc(a1, 40LL);
if ( !v4 )
return 0LL;
v5 = v4;
*v4 = 7;
v6 = (_QWORD *)arena_alloc(a1, 16LL);
if ( !v6 )
return 0LL;
*v6 = a2;
v6[1] = a3;
*((_QWORD *)v5 + 1) = 2LL;
*((_QWORD *)v5 + 2) = v6;
*((_QWORD *)v5 + 3) = 0LL;
*((_BYTE *)v5 + 32) = 0;
return v5;
}
| type_pair_create:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
TEST RSI,RSI
JZ 0x00102c7f
MOV RBX,RDX
TEST RDX,RDX
JZ 0x00102c9e
MOV R15,RSI
MOV R12,RDI
MOV ESI,0x28
CALL 0x00102877
TEST RAX,RAX
JZ 0x00102c6d
MOV R14,RAX
MOV dword ptr [RAX],0x7
MOV ESI,0x10
MOV RDI,R12
CALL 0x00102877
TEST RAX,RAX
JZ 0x00102c6d
MOV qword ptr [RAX],R15
MOV qword ptr [RAX + 0x8],RBX
MOV qword ptr [R14 + 0x8],0x2
MOV qword ptr [R14 + 0x10],RAX
MOV qword ptr [R14 + 0x18],0x0
MOV byte ptr [R14 + 0x20],0x0
JMP 0x00102c70
LAB_00102c6d:
XOR R14D,R14D
LAB_00102c70:
MOV RAX,R14
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
LAB_00102c7f:
LEA RDI,[0x106098]
LEA RSI,[0x1060a9]
LEA RCX,[0x106102]
MOV EDX,0x66
CALL 0x001010e0
LAB_00102c9e:
LEA RDI,[0x106132]
LEA RSI,[0x1060a9]
LEA RCX,[0x106102]
MOV EDX,0x67
CALL 0x001010e0
|
int4 * type_pair_create(int8 param_1,long param_2,long param_3)
{
int4 *puVar1;
long *plVar2;
if (param_2 == 0) {
/* WARNING: Subroutine does not return */
__assert_fail("car_type != NULL",
"/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/type_creation.c"
,0x66,"Type *type_pair_create(Arena *, Type *, Type *)");
}
if (param_3 != 0) {
puVar1 = (int4 *)arena_alloc(param_1,0x28);
if (puVar1 != (int4 *)0x0) {
*puVar1 = 7;
plVar2 = (long *)arena_alloc(param_1,0x10);
if (plVar2 != (long *)0x0) {
*plVar2 = param_2;
plVar2[1] = param_3;
*(int8 *)(puVar1 + 2) = 2;
*(long **)(puVar1 + 4) = plVar2;
*(int8 *)(puVar1 + 6) = 0;
*(int1 *)(puVar1 + 8) = 0;
return puVar1;
}
}
return (int4 *)0x0;
}
/* WARNING: Subroutine does not return */
__assert_fail("cdr_type != NULL",
"/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/type_creation.c"
,0x67,"Type *type_pair_create(Arena *, Type *, Type *)");
}
| |
55,594 | mysql_client_register_plugin | eloqsql/build_O0/libmariadb/libmariadb/ma_client_plugin.c | struct st_mysql_client_plugin * STDCALL
mysql_client_register_plugin(MYSQL *mysql,
struct st_mysql_client_plugin *plugin)
{
struct st_mysql_client_plugin *found_plugin= NULL;
va_list unused;
LINT_INIT_STRUCT(unused);
if (is_not_initialized(mysql, plugin->name))
return NULL;
pthread_mutex_lock(&LOCK_load_client_plugin);
/* make sure the plugin wasn't loaded meanwhile */
if (!(found_plugin= find_plugin(plugin->name, plugin->type)))
found_plugin= add_plugin(mysql, plugin, 0, 0, unused);
pthread_mutex_unlock(&LOCK_load_client_plugin);
return found_plugin;
} | O0 | c | mysql_client_register_plugin:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
leaq -0x40(%rbp), %rdi
xorl %esi, %esi
movl $0x18, %edx
callq 0x13250
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rsi
callq 0x3b770
cmpl $0x0, %eax
je 0x3b708
movq $0x0, -0x8(%rbp)
jmp 0x3b760
leaq 0x2d8b9(%rip), %rdi # 0x68fc8
callq 0x13660
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x18(%rbp), %rax
movl (%rax), %esi
callq 0x3b7e0
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
jne 0x3b74c
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
leaq -0x40(%rbp), %r8
xorl %eax, %eax
movl %eax, %edx
xorl %ecx, %ecx
callq 0x3b320
movq %rax, -0x20(%rbp)
leaq 0x2d875(%rip), %rdi # 0x68fc8
callq 0x13310
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)
| mysql_client_register_plugin:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], 0
lea rdi, [rbp+var_40]
xor esi, esi
mov edx, 18h
call _memset
mov rdi, [rbp+var_10]
mov rax, [rbp+var_18]
mov rsi, [rax+8]
call is_not_initialized
cmp eax, 0
jz short loc_3B708
mov [rbp+var_8], 0
jmp short loc_3B760
loc_3B708:
lea rdi, LOCK_load_client_plugin
call _pthread_mutex_lock
mov rax, [rbp+var_18]
mov rdi, [rax+8]
mov rax, [rbp+var_18]
mov esi, [rax]
call find_plugin
mov [rbp+var_20], rax
cmp rax, 0
jnz short loc_3B74C
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
lea r8, [rbp+var_40]
xor eax, eax
mov edx, eax
xor ecx, ecx
call add_plugin
mov [rbp+var_20], rax
loc_3B74C:
lea rdi, LOCK_load_client_plugin
call _pthread_mutex_unlock
mov rax, [rbp+var_20]
mov [rbp+var_8], rax
loc_3B760:
mov rax, [rbp+var_8]
add rsp, 40h
pop rbp
retn
| void (** mysql_client_register_plugin(long long a1, void (**a2)(void)))(void)
{
_BYTE v3[32]; // [rsp+0h] [rbp-40h] BYREF
void (**plugin)(void); // [rsp+20h] [rbp-20h]
void (**v5)(void); // [rsp+28h] [rbp-18h]
long long v6; // [rsp+30h] [rbp-10h]
v6 = a1;
v5 = a2;
plugin = 0LL;
memset(v3, 0LL, 24LL);
if ( (unsigned int)is_not_initialized(v6, v5[1]) )
return 0LL;
pthread_mutex_lock(&LOCK_load_client_plugin);
plugin = (void (**)(void))find_plugin(v5[1], *(unsigned int *)v5);
if ( !plugin )
plugin = add_plugin(v6, v5, 0LL, 0, (long long)v3);
pthread_mutex_unlock(&LOCK_load_client_plugin);
return plugin;
}
| mysql_client_register_plugin:
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],0x0
LEA RDI,[RBP + -0x40]
XOR ESI,ESI
MOV EDX,0x18
CALL 0x00113250
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RAX + 0x8]
CALL 0x0013b770
CMP EAX,0x0
JZ 0x0013b708
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0013b760
LAB_0013b708:
LEA RDI,[0x168fc8]
CALL 0x00113660
MOV RAX,qword ptr [RBP + -0x18]
MOV RDI,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x18]
MOV ESI,dword ptr [RAX]
CALL 0x0013b7e0
MOV qword ptr [RBP + -0x20],RAX
CMP RAX,0x0
JNZ 0x0013b74c
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
LEA R8,[RBP + -0x40]
XOR EAX,EAX
MOV EDX,EAX
XOR ECX,ECX
CALL 0x0013b320
MOV qword ptr [RBP + -0x20],RAX
LAB_0013b74c:
LEA RDI,[0x168fc8]
CALL 0x00113310
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x8],RAX
LAB_0013b760:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x40
POP RBP
RET
|
long mysql_client_register_plugin(int8 param_1,int4 *param_2)
{
int iVar1;
int1 local_48 [32];
long local_28;
int4 *local_20;
int8 local_18;
long local_10;
local_28 = 0;
local_20 = param_2;
local_18 = param_1;
memset(local_48,0,0x18);
iVar1 = is_not_initialized(local_18,*(int8 *)(local_20 + 2));
if (iVar1 == 0) {
pthread_mutex_lock((pthread_mutex_t *)LOCK_load_client_plugin);
local_28 = find_plugin(*(int8 *)(local_20 + 2),*local_20);
if (local_28 == 0) {
local_28 = add_plugin(local_18,local_20,0,0,local_48);
}
pthread_mutex_unlock((pthread_mutex_t *)LOCK_load_client_plugin);
local_10 = local_28;
}
else {
local_10 = 0;
}
return local_10;
}
| |
55,595 | ma_bin_search | eloqsql/storage/maria/ma_search.c | int _ma_bin_search(const MARIA_KEY *key, const MARIA_PAGE *ma_page,
uint32 comp_flag, uchar **ret_pos,
uchar *buff __attribute__((unused)), my_bool *last_key)
{
int UNINIT_VAR(flag);
uint page_flag;
uint start, mid, end, save_end, totlength, nod_flag;
uint not_used[2];
MARIA_KEYDEF *keyinfo= key->keyinfo;
MARIA_SHARE *share= keyinfo->share;
uchar *page;
DBUG_ENTER("_ma_bin_search");
page_flag= ma_page->flag;
if (page_flag & KEYPAGE_FLAG_HAS_TRANSID)
{
/* Keys have varying length, can't use binary search */
DBUG_RETURN(_ma_seq_search(key, ma_page, comp_flag, ret_pos, buff,
last_key));
}
nod_flag= ma_page->node;
totlength= keyinfo->keylength + nod_flag;
DBUG_ASSERT(ma_page->size >= share->keypage_header + nod_flag + totlength);
start=0;
mid=1;
save_end= end= ((ma_page->size - nod_flag - share->keypage_header) /
totlength-1);
DBUG_PRINT("test",("page_length: %u end: %u", ma_page->size, end));
page= ma_page->buff + share->keypage_header + nod_flag;
while (start != end)
{
mid= (start+end)/2;
if ((flag=ha_key_cmp(keyinfo->seg, page + (uint) mid * totlength,
key->data, key->data_length + key->ref_length,
comp_flag, not_used))
>= 0)
end=mid;
else
start=mid+1;
}
if (mid != start)
flag=ha_key_cmp(keyinfo->seg, page + (uint) start * totlength,
key->data, key->data_length + key->ref_length, comp_flag,
not_used);
if (flag < 0)
start++; /* point at next, bigger key */
*ret_pos= (page + (uint) start * totlength);
*last_key= end == save_end;
DBUG_PRINT("exit",("flag: %d keypos: %d",flag,start));
DBUG_RETURN(flag);
} | O3 | c | ma_bin_search:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %r9, %rbx
movq %rcx, %r14
movl %edx, %r10d
movq %rdi, %r9
testb $0x2, 0x2c(%rsi)
jne 0x3d06a
movq 0x8(%r9), %rdx
movq (%rdx), %rcx
movl 0x20(%rsi), %eax
movl 0x28(%rsi), %edi
movq %rdx, -0x40(%rbp)
movzwl 0xaa(%rdx), %r13d
addl %edi, %r13d
movl 0x744(%rcx), %r12d
subl %r12d, %eax
subl %edi, %eax
xorl %edx, %edx
divl %r13d
addq 0x10(%rsi), %r12
xorl %r15d, %r15d
addq %rdi, %r12
decl %eax
movl %eax, -0x2c(%rbp)
je 0x3d016
movq %r12, -0x38(%rbp)
movq %r14, -0x48(%rbp)
movq %rbx, -0x50(%rbp)
xorl %ecx, %ecx
movl -0x2c(%rbp), %eax
movl %eax, %r14d
movl %r13d, -0x30(%rbp)
leal (%rcx,%r14), %ebx
shrl %ebx
movq -0x40(%rbp), %rax
movq 0xc0(%rax), %rdi
movl %ebx, %esi
imull %r13d, %esi
addq -0x38(%rbp), %rsi
movq (%r9), %rdx
movq %rcx, %r15
movl 0x14(%r9), %ecx
movq %r9, %r12
addl 0x10(%r9), %ecx
movl %r10d, %r13d
movl %r10d, %r8d
leaq -0x58(%rbp), %r9
callq 0xa8c4a
movq %r15, %rcx
movl %ebx, %r15d
testl %eax, %eax
jns 0x3cff3
leal 0x1(%rbx), %ecx
movl %r14d, %r15d
movl %r15d, %r14d
cmpl %r15d, %ecx
movl %r13d, %r10d
movl -0x30(%rbp), %r13d
movq %r12, %r9
jne 0x3cfa8
cmpl %r15d, %ebx
movq -0x50(%rbp), %rbx
movq -0x48(%rbp), %r14
movq -0x38(%rbp), %r12
je 0x3d042
movq -0x40(%rbp), %rax
movq 0xc0(%rax), %rdi
movl %r15d, %esi
imull %r13d, %esi
addq %r12, %rsi
movq (%r9), %rdx
movl 0x14(%r9), %ecx
addl 0x10(%r9), %ecx
leaq -0x58(%rbp), %r9
movl %r10d, %r8d
callq 0xa8c4a
movl %eax, %ecx
shrl $0x1f, %ecx
addl %r15d, %ecx
imull %r13d, %ecx
addq %rcx, %r12
movq %r12, (%r14)
cmpl -0x2c(%rbp), %r15d
sete (%rbx)
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r9, %rdi
movl %r10d, %edx
movq %r14, %rcx
movq %rbx, %r9
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3d089
| _ma_bin_search:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov rbx, r9
mov r14, rcx
mov r10d, edx
mov r9, rdi
test byte ptr [rsi+2Ch], 2
jnz loc_3D06A
mov rdx, [r9+8]
mov rcx, [rdx]
mov eax, [rsi+20h]
mov edi, [rsi+28h]
mov [rbp+var_40], rdx
movzx r13d, word ptr [rdx+0AAh]
add r13d, edi
mov r12d, [rcx+744h]
sub eax, r12d
sub eax, edi
xor edx, edx
div r13d
add r12, [rsi+10h]
xor r15d, r15d
add r12, rdi
dec eax
mov [rbp+var_2C], eax
jz loc_3D016
mov [rbp+var_38], r12
mov [rbp+var_48], r14
mov [rbp+var_50], rbx
xor ecx, ecx
mov eax, [rbp+var_2C]
mov r14d, eax
mov [rbp+var_30], r13d
loc_3CFA8:
lea ebx, [rcx+r14]
shr ebx, 1
mov rax, [rbp+var_40]
mov rdi, [rax+0C0h]
mov esi, ebx
imul esi, r13d
add rsi, [rbp+var_38]
mov rdx, [r9]
mov r15, rcx
mov ecx, [r9+14h]
mov r12, r9
add ecx, [r9+10h]
mov r13d, r10d
mov r8d, r10d
lea r9, [rbp+var_58]
call ha_key_cmp
mov rcx, r15
mov r15d, ebx
test eax, eax
jns short loc_3CFF3
lea ecx, [rbx+1]
mov r15d, r14d
loc_3CFF3:
mov r14d, r15d
cmp ecx, r15d
mov r10d, r13d
mov r13d, [rbp+var_30]
mov r9, r12
jnz short loc_3CFA8
cmp ebx, r15d
mov rbx, [rbp+var_50]
mov r14, [rbp+var_48]
mov r12, [rbp+var_38]
jz short loc_3D042
loc_3D016:
mov rax, [rbp+var_40]
mov rdi, [rax+0C0h]
mov esi, r15d
imul esi, r13d
add rsi, r12
mov rdx, [r9]
mov ecx, [r9+14h]
add ecx, [r9+10h]
lea r9, [rbp+var_58]
mov r8d, r10d
call ha_key_cmp
loc_3D042:
mov ecx, eax
shr ecx, 1Fh
add ecx, r15d
imul ecx, r13d
add r12, rcx
mov [r14], r12
cmp r15d, [rbp+var_2C]
setz byte ptr [rbx]
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3D06A:
mov rdi, r9
mov edx, r10d
mov rcx, r14
mov r9, rbx
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp $+5
| long long ma_bin_search(_QWORD *a1, long long a2, unsigned int a3, _QWORD *a4, long long a5, bool *a6)
{
_QWORD *v7; // r14
unsigned int v8; // r10d
_QWORD *v9; // r9
long long *v10; // rdx
long long v11; // rcx
int v12; // eax
long long v13; // rdi
unsigned int v14; // r13d
long long v15; // r12
unsigned int v16; // eax
unsigned int v17; // r15d
long long v18; // r12
long long v19; // rcx
unsigned int v20; // r14d
unsigned int v21; // ebx
long long v22; // rsi
long long v23; // r15
_QWORD *v24; // r12
unsigned int v25; // r13d
long long result; // rax
bool v27; // zf
char v28[8]; // [rsp+8h] [rbp-58h] BYREF
bool *v29; // [rsp+10h] [rbp-50h]
_QWORD *v30; // [rsp+18h] [rbp-48h]
long long v31; // [rsp+20h] [rbp-40h]
long long v32; // [rsp+28h] [rbp-38h]
unsigned int v33; // [rsp+30h] [rbp-30h]
unsigned int v34; // [rsp+34h] [rbp-2Ch]
v7 = a4;
v8 = a3;
v9 = a1;
if ( (*(_BYTE *)(a2 + 44) & 2) != 0 )
return ma_seq_search(a1, a2, a3, a4, a5, a6);
v10 = (long long *)a1[1];
v11 = *v10;
v12 = *(_DWORD *)(a2 + 32);
v13 = *(unsigned int *)(a2 + 40);
v31 = v9[1];
v14 = v13 + *((unsigned __int16 *)v10 + 85);
v15 = *(unsigned int *)(v11 + 1860);
v16 = (v12 - (int)v15 - (int)v13) / v14;
v17 = 0;
v18 = v13 + *(_QWORD *)(a2 + 16) + v15;
v34 = v16 - 1;
if ( v16 == 1 )
goto LABEL_8;
v32 = v18;
v30 = v7;
v29 = a6;
v19 = 0LL;
v20 = v34;
v33 = v14;
do
{
v21 = ((unsigned int)v19 + v20) >> 1;
v22 = v32 + v14 * v21;
v23 = v19;
v24 = v9;
v25 = v8;
result = ha_key_cmp(
*(_QWORD *)(v31 + 192),
v22,
*v9,
(unsigned int)(*((_DWORD *)v9 + 4) + *((_DWORD *)v9 + 5)),
v8,
v28);
v19 = v23;
v17 = v21;
if ( (int)result < 0 )
{
v19 = v21 + 1;
v17 = v20;
}
v20 = v17;
v8 = v25;
v14 = v33;
v9 = v24;
}
while ( (_DWORD)v19 != v17 );
v27 = v21 == v17;
a6 = v29;
v7 = v30;
v18 = v32;
if ( !v27 )
LABEL_8:
result = ha_key_cmp(
*(_QWORD *)(v31 + 192),
v18 + v14 * v17,
*v9,
(unsigned int)(*((_DWORD *)v9 + 4) + *((_DWORD *)v9 + 5)),
v8,
v28);
*v7 = v14 * (v17 + ((unsigned int)result >> 31)) + v18;
*a6 = v17 == v34;
return result;
}
| _ma_bin_search:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV RBX,R9
MOV R14,RCX
MOV R10D,EDX
MOV R9,RDI
TEST byte ptr [RSI + 0x2c],0x2
JNZ 0x0013d06a
MOV RDX,qword ptr [R9 + 0x8]
MOV RCX,qword ptr [RDX]
MOV EAX,dword ptr [RSI + 0x20]
MOV EDI,dword ptr [RSI + 0x28]
MOV qword ptr [RBP + -0x40],RDX
MOVZX R13D,word ptr [RDX + 0xaa]
ADD R13D,EDI
MOV R12D,dword ptr [RCX + 0x744]
SUB EAX,R12D
SUB EAX,EDI
XOR EDX,EDX
DIV R13D
ADD R12,qword ptr [RSI + 0x10]
XOR R15D,R15D
ADD R12,RDI
DEC EAX
MOV dword ptr [RBP + -0x2c],EAX
JZ 0x0013d016
MOV qword ptr [RBP + -0x38],R12
MOV qword ptr [RBP + -0x48],R14
MOV qword ptr [RBP + -0x50],RBX
XOR ECX,ECX
MOV EAX,dword ptr [RBP + -0x2c]
MOV R14D,EAX
MOV dword ptr [RBP + -0x30],R13D
LAB_0013cfa8:
LEA EBX,[RCX + R14*0x1]
SHR EBX,0x1
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [RAX + 0xc0]
MOV ESI,EBX
IMUL ESI,R13D
ADD RSI,qword ptr [RBP + -0x38]
MOV RDX,qword ptr [R9]
MOV R15,RCX
MOV ECX,dword ptr [R9 + 0x14]
MOV R12,R9
ADD ECX,dword ptr [R9 + 0x10]
MOV R13D,R10D
MOV R8D,R10D
LEA R9,[RBP + -0x58]
CALL 0x001a8c4a
MOV RCX,R15
MOV R15D,EBX
TEST EAX,EAX
JNS 0x0013cff3
LEA ECX,[RBX + 0x1]
MOV R15D,R14D
LAB_0013cff3:
MOV R14D,R15D
CMP ECX,R15D
MOV R10D,R13D
MOV R13D,dword ptr [RBP + -0x30]
MOV R9,R12
JNZ 0x0013cfa8
CMP EBX,R15D
MOV RBX,qword ptr [RBP + -0x50]
MOV R14,qword ptr [RBP + -0x48]
MOV R12,qword ptr [RBP + -0x38]
JZ 0x0013d042
LAB_0013d016:
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [RAX + 0xc0]
MOV ESI,R15D
IMUL ESI,R13D
ADD RSI,R12
MOV RDX,qword ptr [R9]
MOV ECX,dword ptr [R9 + 0x14]
ADD ECX,dword ptr [R9 + 0x10]
LEA R9,[RBP + -0x58]
MOV R8D,R10D
CALL 0x001a8c4a
LAB_0013d042:
MOV ECX,EAX
SHR ECX,0x1f
ADD ECX,R15D
IMUL ECX,R13D
ADD R12,RCX
MOV qword ptr [R14],R12
CMP R15D,dword ptr [RBP + -0x2c]
SETZ byte ptr [RBX]
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0013d06a:
MOV RDI,R9
MOV EDX,R10D
MOV RCX,R14
MOV R9,RBX
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x0013d089
|
void _ma_bin_search(int8 *param_1,long param_2,int4 param_3,long *param_4,
int8 param_5,int8 param_6)
{
uint uVar1;
int iVar2;
uint uVar3;
uint uVar4;
long lVar5;
uint uVar6;
int1 local_60 [8];
int8 local_58;
long *local_50;
long *local_48;
long local_40;
uint local_38;
uint local_34;
if ((*(byte *)(param_2 + 0x2c) & 2) != 0) {
_ma_seq_search(param_1,param_2,param_3,param_4,param_5,param_6);
return;
}
local_48 = (long *)param_1[1];
uVar3 = *(uint *)(param_2 + 0x28);
uVar6 = *(ushort *)((long)local_48 + 0xaa) + uVar3;
lVar5 = (ulong)*(uint *)(*local_48 + 0x744) + *(long *)(param_2 + 0x10) + (ulong)uVar3;
uVar1 = ((*(int *)(param_2 + 0x20) - *(uint *)(*local_48 + 0x744)) - uVar3) / uVar6 - 1;
uVar3 = 0;
local_34 = uVar1;
if (uVar1 != 0) {
uVar3 = 0;
local_58 = param_6;
local_50 = param_4;
local_40 = lVar5;
local_38 = uVar6;
do {
uVar4 = uVar3 + uVar1 >> 1;
iVar2 = ha_key_cmp(local_48[0x18],(ulong)(uVar4 * local_38) + local_40,*param_1,
*(int *)((long)param_1 + 0x14) + *(int *)(param_1 + 2),param_3,local_60);
uVar6 = uVar4;
if (iVar2 < 0) {
uVar3 = uVar4 + 1;
uVar6 = uVar1;
}
uVar1 = uVar6;
} while (uVar3 != uVar1);
param_6 = local_58;
lVar5 = local_40;
param_4 = local_50;
uVar6 = local_38;
uVar3 = uVar1;
if (uVar4 == uVar1) goto LAB_0013d042;
}
iVar2 = ha_key_cmp(local_48[0x18],(ulong)(uVar3 * uVar6) + lVar5,*param_1,
*(int *)((long)param_1 + 0x14) + *(int *)(param_1 + 2),param_3,local_60);
local_58 = param_6;
local_50 = param_4;
LAB_0013d042:
*local_50 = lVar5 + (ulong)((uVar3 - (iVar2 >> 0x1f)) * uVar6);
*(bool *)local_58 = uVar3 == local_34;
return;
}
| |
55,596 | bc_get_atom | bluesky950520[P]quickjs/quickjs.c | static int bc_get_atom(BCReaderState *s, JSAtom *patom)
{
uint32_t v;
if (bc_get_leb128(s, &v))
return -1;
if (v & 1) {
*patom = __JS_AtomFromUInt32(v >> 1);
return 0;
} else {
return bc_idx_to_atom(s, patom, v >> 1);
}
} | O1 | c | bc_get_atom:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x4(%rsp), %rsi
callq 0x45a75
movl %eax, %ecx
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
testl %ecx, %ecx
jne 0x46efd
movl 0x4(%rsp), %eax
movl %eax, %edx
shrl %edx
testb $0x1, %al
jne 0x46ef3
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x4700e
orl $0x80000000, %edx # imm = 0x80000000
movl %edx, (%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| bc_get_atom:
push r14
push rbx
push rax
mov rbx, rsi
mov r14, rdi
lea rsi, [rsp+18h+var_14]
call bc_get_leb128
mov ecx, eax
mov eax, 0FFFFFFFFh
test ecx, ecx
jnz short loc_46EFD
mov eax, [rsp+18h+var_14]
mov edx, eax
shr edx, 1
test al, 1
jnz short loc_46EF3
mov rdi, r14
mov rsi, rbx
add rsp, 8
pop rbx
pop r14
jmp bc_idx_to_atom
loc_46EF3:
or edx, 80000000h
mov [rbx], edx
xor eax, eax
loc_46EFD:
add rsp, 8
pop rbx
pop r14
retn
| long long bc_get_atom(long long a1, _DWORD *a2, long long a3, int a4, unsigned long long a5)
{
long long v5; // rax
int leb128; // ecx
long long result; // rax
long long v8; // rdx
_DWORD v9[5]; // [rsp+0h] [rbp-14h] BYREF
v9[0] = HIDWORD(v5);
leb128 = bc_get_leb128(a1, v9, a3, a4, a5);
result = 0xFFFFFFFFLL;
if ( !leb128 )
{
v8 = v9[0] >> 1;
if ( (v9[0] & 1) != 0 )
{
*a2 = v8 | 0x80000000;
return 0LL;
}
else
{
return bc_idx_to_atom(a1, a2, v8);
}
}
return result;
}
| bc_get_atom:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV R14,RDI
LEA RSI,[RSP + 0x4]
CALL 0x00145a75
MOV ECX,EAX
MOV EAX,0xffffffff
TEST ECX,ECX
JNZ 0x00146efd
MOV EAX,dword ptr [RSP + 0x4]
MOV EDX,EAX
SHR EDX,0x1
TEST AL,0x1
JNZ 0x00146ef3
MOV RDI,R14
MOV RSI,RBX
ADD RSP,0x8
POP RBX
POP R14
JMP 0x0014700e
LAB_00146ef3:
OR EDX,0x80000000
MOV dword ptr [RBX],EDX
XOR EAX,EAX
LAB_00146efd:
ADD RSP,0x8
POP RBX
POP R14
RET
|
int8 bc_get_atom(int8 param_1,uint *param_2)
{
int iVar1;
int8 in_RAX;
int8 uVar2;
uint local_14;
local_14 = (uint)((ulong)in_RAX >> 0x20);
iVar1 = bc_get_leb128(param_1,&local_14);
uVar2 = 0xffffffff;
if (iVar1 == 0) {
if ((local_14 & 1) == 0) {
uVar2 = bc_idx_to_atom(param_1,param_2);
return uVar2;
}
*param_2 = local_14 >> 1 | 0x80000000;
uVar2 = 0;
}
return uVar2;
}
| |
55,597 | bc_get_atom | bluesky950520[P]quickjs/quickjs.c | static int bc_get_atom(BCReaderState *s, JSAtom *patom)
{
uint32_t v;
if (bc_get_leb128(s, &v))
return -1;
if (v & 1) {
*patom = __JS_AtomFromUInt32(v >> 1);
return 0;
} else {
return bc_idx_to_atom(s, patom, v >> 1);
}
} | O2 | c | bc_get_atom:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x4(%rsp), %rsi
callq 0x3d194
testl %eax, %eax
je 0x3d320
pushq $-0x1
popq %rax
jmp 0x3d348
movl 0x4(%rsp), %eax
movl %eax, %edx
shrl %edx
testb $0x1, %al
jne 0x3d33e
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x3d3d0
orl $0x80000000, %edx # imm = 0x80000000
movl %edx, (%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| bc_get_atom:
push r14
push rbx
push rax
mov rbx, rsi
mov r14, rdi
lea rsi, [rsp+18h+var_14]
call bc_get_leb128
test eax, eax
jz short loc_3D320
push 0FFFFFFFFFFFFFFFFh
pop rax
jmp short loc_3D348
loc_3D320:
mov eax, [rsp+18h+var_14]
mov edx, eax
shr edx, 1
test al, 1
jnz short loc_3D33E
mov rdi, r14
mov rsi, rbx
add rsp, 8
pop rbx
pop r14
jmp bc_idx_to_atom
loc_3D33E:
or edx, 80000000h
mov [rbx], edx
xor eax, eax
loc_3D348:
add rsp, 8
pop rbx
pop r14
retn
| long long bc_get_atom(long long a1, _DWORD *a2)
{
long long v2; // rax
long long v4; // rdx
_DWORD v5[5]; // [rsp+0h] [rbp-14h] BYREF
v5[0] = HIDWORD(v2);
if ( (unsigned int)bc_get_leb128(a1, v5) )
return -1LL;
v4 = v5[0] >> 1;
if ( (v5[0] & 1) == 0 )
return bc_idx_to_atom(a1, a2, v4);
*a2 = v4 | 0x80000000;
return 0LL;
}
| bc_get_atom:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV R14,RDI
LEA RSI,[RSP + 0x4]
CALL 0x0013d194
TEST EAX,EAX
JZ 0x0013d320
PUSH -0x1
POP RAX
JMP 0x0013d348
LAB_0013d320:
MOV EAX,dword ptr [RSP + 0x4]
MOV EDX,EAX
SHR EDX,0x1
TEST AL,0x1
JNZ 0x0013d33e
MOV RDI,R14
MOV RSI,RBX
ADD RSP,0x8
POP RBX
POP R14
JMP 0x0013d3d0
LAB_0013d33e:
OR EDX,0x80000000
MOV dword ptr [RBX],EDX
XOR EAX,EAX
LAB_0013d348:
ADD RSP,0x8
POP RBX
POP R14
RET
|
int8 bc_get_atom(int8 param_1,uint *param_2)
{
int iVar1;
int8 in_RAX;
int8 uVar2;
uint local_14;
local_14 = (uint)((ulong)in_RAX >> 0x20);
iVar1 = bc_get_leb128(param_1,&local_14);
if (iVar1 == 0) {
if ((local_14 & 1) == 0) {
uVar2 = bc_idx_to_atom(param_1,param_2);
return uVar2;
}
*param_2 = local_14 >> 1 | 0x80000000;
uVar2 = 0;
}
else {
uVar2 = 0xffffffffffffffff;
}
return uVar2;
}
| |
55,598 | bc_get_atom | bluesky950520[P]quickjs/quickjs.c | static int bc_get_atom(BCReaderState *s, JSAtom *patom)
{
uint32_t v;
if (bc_get_leb128(s, &v))
return -1;
if (v & 1) {
*patom = __JS_AtomFromUInt32(v >> 1);
return 0;
} else {
return bc_idx_to_atom(s, patom, v >> 1);
}
} | O3 | c | bc_get_atom:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x4(%rsp), %rsi
callq 0x4760c
movl %eax, %ecx
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
testl %ecx, %ecx
jne 0x48b0c
movl 0x4(%rsp), %eax
movl %eax, %edx
shrl %edx
testb $0x1, %al
jne 0x48b02
movq %r14, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x48c1d
orl $0x80000000, %edx # imm = 0x80000000
movl %edx, (%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| bc_get_atom:
push r14
push rbx
push rax
mov rbx, rsi
mov r14, rdi
lea rsi, [rsp+18h+var_14]
call bc_get_leb128
mov ecx, eax
mov eax, 0FFFFFFFFh
test ecx, ecx
jnz short loc_48B0C
mov eax, [rsp+18h+var_14]
mov edx, eax
shr edx, 1
test al, 1
jnz short loc_48B02
mov rdi, r14
mov rsi, rbx
add rsp, 8
pop rbx
pop r14
jmp bc_idx_to_atom
loc_48B02:
or edx, 80000000h
mov [rbx], edx
xor eax, eax
loc_48B0C:
add rsp, 8
pop rbx
pop r14
retn
| long long bc_get_atom(long long a1, _DWORD *a2, long long a3, int a4, int a5, int a6)
{
long long v6; // rax
int leb128; // ecx
long long result; // rax
long long v9; // rdx
unsigned int v10[5]; // [rsp+0h] [rbp-14h] BYREF
v10[0] = HIDWORD(v6);
leb128 = bc_get_leb128(a1, (int *)v10, a3, a4, a5, a6);
result = 0xFFFFFFFFLL;
if ( !leb128 )
{
v9 = v10[0] >> 1;
if ( (v10[0] & 1) != 0 )
{
*a2 = v9 | 0x80000000;
return 0LL;
}
else
{
return bc_idx_to_atom(a1, a2, v9);
}
}
return result;
}
| bc_get_atom:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV R14,RDI
LEA RSI,[RSP + 0x4]
CALL 0x0014760c
MOV ECX,EAX
MOV EAX,0xffffffff
TEST ECX,ECX
JNZ 0x00148b0c
MOV EAX,dword ptr [RSP + 0x4]
MOV EDX,EAX
SHR EDX,0x1
TEST AL,0x1
JNZ 0x00148b02
MOV RDI,R14
MOV RSI,RBX
ADD RSP,0x8
POP RBX
POP R14
JMP 0x00148c1d
LAB_00148b02:
OR EDX,0x80000000
MOV dword ptr [RBX],EDX
XOR EAX,EAX
LAB_00148b0c:
ADD RSP,0x8
POP RBX
POP R14
RET
|
int8 bc_get_atom(int8 param_1,uint *param_2)
{
int iVar1;
int8 in_RAX;
int8 uVar2;
uint local_14;
local_14 = (uint)((ulong)in_RAX >> 0x20);
iVar1 = bc_get_leb128(param_1,&local_14);
uVar2 = 0xffffffff;
if (iVar1 == 0) {
if ((local_14 & 1) == 0) {
uVar2 = bc_idx_to_atom(param_1,param_2);
return uVar2;
}
*param_2 = local_14 >> 1 | 0x80000000;
uVar2 = 0;
}
return uVar2;
}
| |
55,599 | OpenSubdiv::v3_6_0::Far::GregoryTriConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const | NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/loopPatchBuilder.cpp | void
GregoryTriConverter<REAL>::resizeMatrixIsolatedIrregular(
Matrix & matrix, int cornerIndex, int cornerValence) const {
int irregRingSize = 1 + cornerValence;
int irregCorner = cornerIndex;
int irregPlus = (cornerIndex + 1) % 3;
int irregMinus = (cornerIndex + 2) % 3;
int rowSizes[18];
int * rowSizePtr = 0;
rowSizePtr = rowSizes + irregCorner * 5;
*rowSizePtr++ = irregRingSize;
*rowSizePtr++ = irregRingSize;
*rowSizePtr++ = irregRingSize;
*rowSizePtr++ = 3 + irregRingSize;
*rowSizePtr++ = 3 + irregRingSize;
rowSizePtr = rowSizes + irregPlus * 5;
*rowSizePtr++ = 7;
*rowSizePtr++ = 7;
*rowSizePtr++ = 7;
*rowSizePtr++ = 5;
*rowSizePtr++ = 3 + irregRingSize;
rowSizePtr = rowSizes + irregMinus * 5;
*rowSizePtr++ = 7;
*rowSizePtr++ = 7;
*rowSizePtr++ = 7;
*rowSizePtr++ = 3 + irregRingSize;
*rowSizePtr++ = 5;
// The 3 quartic mid-edge points are not grouped with corners:
rowSizes[15 + irregCorner] = 3 + irregRingSize;
rowSizes[15 + irregPlus] = 4;
rowSizes[15 + irregMinus] = 3 + irregRingSize;
int numElements = 9*irregRingSize + 74;
_resizeMatrix(matrix, 18, _numSourcePoints, numElements, rowSizes);
} | O1 | cpp | OpenSubdiv::v3_6_0::Far::GregoryTriConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const:
pushq %rbx
subq $0x50, %rsp
movq %rsi, %rax
leal 0x1(%rcx), %r9d
leal 0x1(%rdx), %esi
movslq %esi, %r8
imulq $0x55555556, %r8, %rsi # imm = 0x55555556
movq %rsi, %r10
shrq $0x3f, %r10
shrq $0x20, %rsi
addl %r10d, %esi
leal (%rsi,%rsi,2), %esi
subl %esi, %r8d
leal 0x2(%rdx), %r10d
movslq %r10d, %r11
imulq $0x55555556, %r11, %r10 # imm = 0x55555556
movq %r10, %rbx
shrq $0x3f, %rbx
shrq $0x20, %r10
addl %ebx, %r10d
leal (%r10,%r10,2), %r10d
subl %r10d, %r11d
leal (%rdx,%rdx,4), %ebx
movslq %ebx, %rbx
movl %r9d, (%rsp,%rbx,4)
movl %r9d, 0x4(%rsp,%rbx,4)
movl %r9d, 0x8(%rsp,%rbx,4)
leal 0x4(%rcx), %r9d
movl %r9d, 0xc(%rsp,%rbx,4)
movl %r9d, 0x10(%rsp,%rbx,4)
leal (%r8,%r8,4), %r8d
movslq %r8d, %r8
movaps 0x5eac0(%rip), %xmm0 # 0xb5f90
movups %xmm0, (%rsp,%r8,4)
movl %r9d, 0x10(%rsp,%r8,4)
leal (%r11,%r11,4), %r8d
movslq %r8d, %r8
movabsq $0x700000007, %r11 # imm = 0x700000007
movq %r11, (%rsp,%r8,4)
movl $0x7, 0x8(%rsp,%r8,4)
movl %r9d, 0xc(%rsp,%r8,4)
movl $0x5, 0x10(%rsp,%r8,4)
movslq %edx, %r8
movl %r9d, 0x3c(%rsp,%r8,4)
negl %esi
addl %edx, %esi
addl $0x10, %esi
movl $0x4, (%rsp,%rsi,4)
negl %r10d
addl %r10d, %edx
addl $0x11, %edx
movl %r9d, (%rsp,%rdx,4)
leal 0x53(%rcx,%rcx,8), %edx
movl (%rdi), %esi
movq %rsp, %rcx
movq %rax, %rdi
callq 0x549bc
addq $0x50, %rsp
popq %rbx
retq
| _ZNK10OpenSubdiv6v3_6_03Far19GregoryTriConverterIfE29resizeMatrixIsolatedIrregularERNS1_12SparseMatrixIfEEii:
push rbx
sub rsp, 50h
mov rax, rsi
lea r9d, [rcx+1]
lea esi, [rdx+1]
movsxd r8, esi
imul rsi, r8, 55555556h
mov r10, rsi
shr r10, 3Fh
shr rsi, 20h
add esi, r10d
lea esi, [rsi+rsi*2]
sub r8d, esi
lea r10d, [rdx+2]
movsxd r11, r10d
imul r10, r11, 55555556h
mov rbx, r10
shr rbx, 3Fh
shr r10, 20h
add r10d, ebx
lea r10d, [r10+r10*2]
sub r11d, r10d
lea ebx, [rdx+rdx*4]
movsxd rbx, ebx
mov dword ptr [rsp+rbx*4+58h+var_58], r9d
mov dword ptr [rsp+rbx*4+58h+var_58+4], r9d
mov dword ptr [rsp+rbx*4+58h+var_58+8], r9d
lea r9d, [rcx+4]
mov dword ptr [rsp+rbx*4+58h+var_58+0Ch], r9d
mov [rsp+rbx*4+58h+var_48], r9d
lea r8d, [r8+r8*4]
movsxd r8, r8d
movaps xmm0, cs:xmmword_B5F90
movups [rsp+r8*4+58h+var_58], xmm0
mov [rsp+r8*4+58h+var_48], r9d
lea r8d, [r11+r11*4]
movsxd r8, r8d
mov r11, 700000007h
mov qword ptr [rsp+r8*4+58h+var_58], r11
mov dword ptr [rsp+r8*4+58h+var_58+8], 7
mov dword ptr [rsp+r8*4+58h+var_58+0Ch], r9d
mov [rsp+r8*4+58h+var_48], 5
movsxd r8, edx
mov [rsp+r8*4+58h+var_1C], r9d
neg esi
add esi, edx
add esi, 10h
mov dword ptr [rsp+rsi*4+58h+var_58], 4
neg r10d
add edx, r10d
add edx, 11h
mov dword ptr [rsp+rdx*4+58h+var_58], r9d
lea edx, [rcx+rcx*8+53h]
mov esi, [rdi]
mov rcx, rsp
mov rdi, rax
call _ZN10OpenSubdiv6v3_6_03Far12_GLOBAL__N_113_resizeMatrixIfEEvRNS1_12SparseMatrixIT_EEiiiPKi_0; OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<float>(OpenSubdiv::v3_6_0::Far::SparseMatrix<float> &,int,int,int,int const*)
add rsp, 50h
pop rbx
retn
| long long OpenSubdiv::v3_6_0::Far::GregoryTriConverter<float>::resizeMatrixIsolatedIrregular(
int *a1,
int *a2,
int a3,
int a4)
{
long long v4; // rbx
long long v5; // r8
long long v6; // r8
_BYTE v8[88]; // [rsp+0h] [rbp-58h] BYREF
v4 = 5 * a3;
*(_DWORD *)&v8[4 * v4] = a4 + 1;
*(_DWORD *)&v8[4 * v4 + 4] = a4 + 1;
*(_DWORD *)&v8[4 * v4 + 8] = a4 + 1;
*(_DWORD *)&v8[4 * v4 + 12] = a4 + 4;
*(_DWORD *)&v8[4 * v4 + 16] = a4 + 4;
v5 = 5 * ((a3 + 1) % 3);
*(_OWORD *)&v8[4 * v5] = xmmword_B5F90;
*(_DWORD *)&v8[4 * v5 + 16] = a4 + 4;
v6 = 5 * ((a3 + 2) % 3);
*(_QWORD *)&v8[4 * v6] = 0x700000007LL;
*(_DWORD *)&v8[4 * v6 + 8] = 7;
*(_DWORD *)&v8[4 * v6 + 12] = a4 + 4;
*(_DWORD *)&v8[4 * v6 + 16] = 5;
*(_DWORD *)&v8[4 * a3 + 60] = a4 + 4;
*(_DWORD *)&v8[4 * (a3 - 3 * ((a3 + 1) / 3) + 16)] = 4;
*(_DWORD *)&v8[4 * (-3 * ((a3 + 2) / 3) + a3 + 17)] = a4 + 4;
return OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<float>(a2, *a1, 9 * a4 + 83, (long long)v8);
}
| resizeMatrixIsolatedIrregular:
PUSH RBX
SUB RSP,0x50
MOV RAX,RSI
LEA R9D,[RCX + 0x1]
LEA ESI,[RDX + 0x1]
MOVSXD R8,ESI
IMUL RSI,R8,0x55555556
MOV R10,RSI
SHR R10,0x3f
SHR RSI,0x20
ADD ESI,R10D
LEA ESI,[RSI + RSI*0x2]
SUB R8D,ESI
LEA R10D,[RDX + 0x2]
MOVSXD R11,R10D
IMUL R10,R11,0x55555556
MOV RBX,R10
SHR RBX,0x3f
SHR R10,0x20
ADD R10D,EBX
LEA R10D,[R10 + R10*0x2]
SUB R11D,R10D
LEA EBX,[RDX + RDX*0x4]
MOVSXD RBX,EBX
MOV dword ptr [RSP + RBX*0x4],R9D
MOV dword ptr [RSP + RBX*0x4 + 0x4],R9D
MOV dword ptr [RSP + RBX*0x4 + 0x8],R9D
LEA R9D,[RCX + 0x4]
MOV dword ptr [RSP + RBX*0x4 + 0xc],R9D
MOV dword ptr [RSP + RBX*0x4 + 0x10],R9D
LEA R8D,[R8 + R8*0x4]
MOVSXD R8,R8D
MOVAPS XMM0,xmmword ptr [0x001b5f90]
MOVUPS xmmword ptr [RSP + R8*0x4],XMM0
MOV dword ptr [RSP + R8*0x4 + 0x10],R9D
LEA R8D,[R11 + R11*0x4]
MOVSXD R8,R8D
MOV R11,0x700000007
MOV qword ptr [RSP + R8*0x4],R11
MOV dword ptr [RSP + R8*0x4 + 0x8],0x7
MOV dword ptr [RSP + R8*0x4 + 0xc],R9D
MOV dword ptr [RSP + R8*0x4 + 0x10],0x5
MOVSXD R8,EDX
MOV dword ptr [RSP + R8*0x4 + 0x3c],R9D
NEG ESI
ADD ESI,EDX
ADD ESI,0x10
MOV dword ptr [RSP + RSI*0x4],0x4
NEG R10D
ADD EDX,R10D
ADD EDX,0x11
MOV dword ptr [RSP + RDX*0x4],R9D
LEA EDX,[RCX + RCX*0x8 + 0x53]
MOV ESI,dword ptr [RDI]
MOV RCX,RSP
MOV RDI,RAX
CALL 0x001549bc
ADD RSP,0x50
POP RBX
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* OpenSubdiv::v3_6_0::Far::GregoryTriConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&,
int, int) const */
void __thiscall
OpenSubdiv::v3_6_0::Far::GregoryTriConverter<float>::resizeMatrixIsolatedIrregular
(GregoryTriConverter<float> *this,SparseMatrix *param_1,int param_2,int param_3)
{
long lVar1;
int iVar2;
int aiStack_58 [2];
int8 uStack_50;
int aiStack_48 [11];
int aiStack_1c [5];
iVar2 = param_3 + 1;
lVar1 = (long)(param_2 * 5);
aiStack_58[lVar1] = iVar2;
aiStack_58[lVar1 + 1] = iVar2;
*(int *)((long)&uStack_50 + lVar1 * 4) = iVar2;
iVar2 = param_3 + 4;
aiStack_48[lVar1 + -1] = iVar2;
aiStack_48[lVar1] = iVar2;
lVar1 = (long)(((param_2 + 1) % 3) * 5);
*(int8 *)(aiStack_58 + lVar1) = _DAT_001b5f90;
*(int8 *)((long)&uStack_50 + lVar1 * 4) = _UNK_001b5f98;
aiStack_48[lVar1] = iVar2;
lVar1 = (long)(((param_2 + 2) % 3) * 5);
(aiStack_58 + lVar1)[0] = 7;
(aiStack_58 + lVar1)[1] = 7;
*(int4 *)((long)&uStack_50 + lVar1 * 4) = 7;
aiStack_48[lVar1 + -1] = iVar2;
aiStack_48[lVar1] = 5;
aiStack_1c[param_2] = iVar2;
aiStack_58[((param_2 + 1) / 3) * -3 + param_2 + 0x10] = 4;
aiStack_58[param_2 + ((param_2 + 2) / 3) * -3 + 0x11] = iVar2;
(anonymous_namespace)::_resizeMatrix<float>
(param_1,*(int *)this,param_3 * 9 + 0x53,(int)aiStack_58,(int *)(long)param_2);
return;
}
|
Subsets and Splits
C++ Functions With Standard Library Dependencies
Identifies C++ functions that depend on standard library components, revealing patterns in how developers utilize STL libraries and potentially highlighting common coding practices or dependencies in the dataset.
C++ Standard Library Function Analysis
Filters C++ code examples that use standard library containers and types, providing useful insights into common programming patterns and data structures in the dataset.
Random Training Function Samples
Performs basic filtering and random sampling of assembly code data without revealing meaningful patterns or relationships.
Random Training Function Samples
Retrieves a random sample of 1000 records from the training dataset, providing basic data exploration but offering limited analytical value beyond seeing raw entries.