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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
23,300 | wqueue_add_and_wait | eloqsql/mysys/wqueue.c | void wqueue_add_and_wait(WQUEUE *wqueue,
struct st_my_thread_var *thread,
mysql_mutex_t *lock)
{
DBUG_ENTER("wqueue_add_and_wait");
DBUG_PRINT("enter",
("thread: %p cond: %p mutex: %p",
thread, &thread->suspend, lock));
wqueue_add_to_queue(wqueue, thread);
do
{
DBUG_PRINT("info", ("wait... cond: %p mutex: %p",
&thread->suspend, lock));
mysql_cond_wait(&thread->suspend, lock);
DBUG_PRINT("info", ("wait done cond: %p mutex: %p next: %p",
&thread->suspend, lock,
thread->next));
}
while (thread->next);
DBUG_VOID_RETURN;
} | O3 | c | wqueue_add_and_wait:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq (%rdi), %rax
testq %rax, %rax
je 0xa68d0
movq 0x88(%rax), %rcx
addq $0x88, %rax
movq %rcx, 0x88(%r14)
jmp 0xa68d7
leaq 0x88(%r14), %rax
movq %r14, (%rax)
movq %r14, (%rdi)
leaq 0x8(%r14), %r15
leaq 0x36090(%rip), %r12 # 0xdc978
cmpq $0x0, 0x38(%r14)
jne 0xa6906
movq %r15, %rdi
movq %rbx, %rsi
callq 0x29430
cmpq $0x0, 0x88(%r14)
jne 0xa68e8
jmp 0xa691b
movq %r15, %rdi
movq %rbx, %rsi
movq %r12, %rdx
movl $0xeb, %ecx
callq 0x2eea0
jmp 0xa68fa
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| wqueue_add_and_wait:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
mov rbx, rdx
mov r14, rsi
mov rax, [rdi]
test rax, rax
jz short loc_A68D0
mov rcx, [rax+88h]
add rax, 88h
mov [r14+88h], rcx
jmp short loc_A68D7
loc_A68D0:
lea rax, [r14+88h]
loc_A68D7:
mov [rax], r14
mov [rdi], r14
lea r15, [r14+8]
lea r12, aWorkspaceLlm4b_42; "/workspace/llm4binary/github2025/eloqsq"...
loc_A68E8:
cmp qword ptr [r14+38h], 0
jnz short loc_A6906
mov rdi, r15
mov rsi, rbx
call _pthread_cond_wait
loc_A68FA:
cmp qword ptr [r14+88h], 0
jnz short loc_A68E8
jmp short loc_A691B
loc_A6906:
mov rdi, r15
mov rsi, rbx
mov rdx, r12
mov ecx, 0EBh
call psi_cond_wait
jmp short loc_A68FA
loc_A691B:
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| long long wqueue_add_and_wait(long long *a1, long long a2, long long a3)
{
long long v4; // rax
long long v5; // rcx
_QWORD *v6; // rax
long long result; // rax
v4 = *a1;
if ( *a1 )
{
v5 = *(_QWORD *)(v4 + 136);
v6 = (_QWORD *)(v4 + 136);
*(_QWORD *)(a2 + 136) = v5;
}
else
{
v6 = (_QWORD *)(a2 + 136);
}
*v6 = a2;
*a1 = a2;
do
{
if ( *(_QWORD *)(a2 + 56) )
result = psi_cond_wait(a2 + 8, a3, (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/wqueue.c", 0xEBu);
else
result = pthread_cond_wait(a2 + 8, a3);
}
while ( *(_QWORD *)(a2 + 136) );
return result;
}
| wqueue_add_and_wait:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV RBX,RDX
MOV R14,RSI
MOV RAX,qword ptr [RDI]
TEST RAX,RAX
JZ 0x001a68d0
MOV RCX,qword ptr [RAX + 0x88]
ADD RAX,0x88
MOV qword ptr [R14 + 0x88],RCX
JMP 0x001a68d7
LAB_001a68d0:
LEA RAX,[R14 + 0x88]
LAB_001a68d7:
MOV qword ptr [RAX],R14
MOV qword ptr [RDI],R14
LEA R15,[R14 + 0x8]
LEA R12,[0x1dc978]
LAB_001a68e8:
CMP qword ptr [R14 + 0x38],0x0
JNZ 0x001a6906
MOV RDI,R15
MOV RSI,RBX
CALL 0x00129430
LAB_001a68fa:
CMP qword ptr [R14 + 0x88],0x0
JNZ 0x001a68e8
JMP 0x001a691b
LAB_001a6906:
MOV RDI,R15
MOV RSI,RBX
MOV RDX,R12
MOV ECX,0xeb
CALL 0x0012eea0
JMP 0x001a68fa
LAB_001a691b:
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
void wqueue_add_and_wait(long *param_1,long param_2,pthread_mutex_t *param_3)
{
long lVar1;
long *plVar2;
lVar1 = *param_1;
if (lVar1 == 0) {
plVar2 = (long *)(param_2 + 0x88);
}
else {
plVar2 = (long *)(lVar1 + 0x88);
*(int8 *)(param_2 + 0x88) = *(int8 *)(lVar1 + 0x88);
}
*plVar2 = param_2;
*param_1 = param_2;
do {
if (*(long *)(param_2 + 0x38) == 0) {
pthread_cond_wait((pthread_cond_t *)(param_2 + 8),param_3);
}
else {
psi_cond_wait((pthread_cond_t *)(param_2 + 8),param_3,
"/workspace/llm4binary/github2025/eloqsql/mysys/wqueue.c",0xeb);
}
} while (*(long *)(param_2 + 0x88) != 0);
return;
}
| |
23,301 | server_task::server_task(server_task_type) | monkey531[P]llama/examples/server/server.cpp | server_task(server_task_type type) : type(type) {} | O0 | cpp | server_task::server_task(server_task_type):
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movq 0x10(%rsp), %rdi
movq %rdi, (%rsp)
movl $0xffffffff, (%rdi) # imm = 0xFFFFFFFF
movl $0xffffffff, 0x4(%rdi) # imm = 0xFFFFFFFF
movl 0xc(%rsp), %eax
movl %eax, 0x8(%rdi)
movl $0xffffffff, 0xc(%rdi) # imm = 0xFFFFFFFF
addq $0x10, %rdi
callq 0xe8820
movq (%rsp), %rdi
addq $0x6e8, %rdi # imm = 0x6E8
callq 0x9efd0
movq (%rsp), %rdi
movl $0xffffffff, 0x700(%rdi) # imm = 0xFFFFFFFF
addq $0x708, %rdi # imm = 0x708
callq 0x141f50
movq (%rsp), %rdi
movb $0x0, 0x750(%rdi)
addq $0x758, %rdi # imm = 0x758
callq 0x9efb0
addq $0x18, %rsp
retq
| _ZN11server_taskC2E16server_task_type:
sub rsp, 18h
mov [rsp+18h+var_8], rdi
mov [rsp+18h+var_C], esi
mov rdi, [rsp+18h+var_8]
mov [rsp+18h+var_18], rdi
mov dword ptr [rdi], 0FFFFFFFFh
mov dword ptr [rdi+4], 0FFFFFFFFh
mov eax, [rsp+18h+var_C]
mov [rdi+8], eax
mov dword ptr [rdi+0Ch], 0FFFFFFFFh
add rdi, 10h; this
call _ZN11slot_paramsC2Ev; slot_params::slot_params(void)
mov rdi, [rsp+18h+var_18]
add rdi, 6E8h
call _ZNSt6vectorIiSaIiEEC2Ev; std::vector<int>::vector(void)
mov rdi, [rsp+18h+var_18]
mov dword ptr [rdi+700h], 0FFFFFFFFh
add rdi, 708h; this
call _ZN11server_task11slot_actionC2Ev; server_task::slot_action::slot_action(void)
mov rdi, [rsp+18h+var_18]
mov byte ptr [rdi+750h], 0
add rdi, 758h
call _ZNSt6vectorI24common_adapter_lora_infoSaIS0_EEC2Ev; std::vector<common_adapter_lora_info>::vector(void)
add rsp, 18h
retn
| long long server_task::server_task(long long a1, int a2)
{
*(_DWORD *)a1 = -1;
*(_DWORD *)(a1 + 4) = -1;
*(_DWORD *)(a1 + 8) = a2;
*(_DWORD *)(a1 + 12) = -1;
slot_params::slot_params((slot_params *)(a1 + 16));
std::vector<int>::vector(a1 + 1768);
*(_DWORD *)(a1 + 1792) = -1;
server_task::slot_action::slot_action((server_task::slot_action *)(a1 + 1800));
*(_BYTE *)(a1 + 1872) = 0;
return std::vector<common_adapter_lora_info>::vector(a1 + 1880);
}
| |||
23,302 | server_task::server_task(server_task_type) | monkey531[P]llama/examples/server/server.cpp | server_task(server_task_type type) : type(type) {} | O3 | cpp | server_task::server_task(server_task_type):
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq $-0x1, (%rdi)
movl %esi, 0x8(%rdi)
movl $0xffffffff, 0xc(%rdi) # imm = 0xFFFFFFFF
movw $0x101, 0x10(%rdi) # imm = 0x101
movb $0x0, 0x12(%rdi)
movdqa 0xcdcff(%rip), %xmm0 # 0x144120
movdqu %xmm0, 0x14(%rdi)
pcmpeqd %xmm0, %xmm0
movdqu %xmm0, 0x28(%rdi)
leaq 0x88(%rdi), %r15
pxor %xmm0, %xmm0
movdqu %xmm0, 0x38(%rdi)
movdqu %xmm0, 0x48(%rdi)
movdqu %xmm0, 0x58(%rdi)
movdqu %xmm0, 0x68(%rdi)
movdqu %xmm0, 0x73(%rdi)
movq %r15, %rdi
callq 0x42cee
leaq 0x1c0(%rbx), %rdi
callq 0x42f40
xorl %eax, %eax
movb %al, 0x698(%rbx)
movl %eax, 0x69c(%rbx)
leaq 0x6b0(%rbx), %rcx
movq %rcx, 0x6a0(%rbx)
movq %rax, 0x6a8(%rbx)
movb %al, 0x6b0(%rbx)
leaq 0x6d0(%rbx), %rcx
movq %rcx, 0x6c0(%rbx)
movq %rax, 0x6c8(%rbx)
movb %al, 0x6d0(%rbx)
movl %eax, 0x6e0(%rbx)
pxor %xmm0, %xmm0
movdqu %xmm0, 0x6e8(%rbx)
movq %rax, 0x6f8(%rbx)
movl $0xffffffff, 0x700(%rbx) # imm = 0xFFFFFFFF
leaq 0x720(%rbx), %rcx
movq %rcx, 0x710(%rbx)
movq %rax, 0x718(%rbx)
movb %al, 0x720(%rbx)
leaq 0x740(%rbx), %rcx
movq %rcx, 0x730(%rbx)
movq %rax, 0x738(%rbx)
movb %al, 0x740(%rbx)
movb %al, 0x750(%rbx)
movq %rax, 0x768(%rbx)
movdqu %xmm0, 0x758(%rbx)
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq %r15, %rdi
callq 0x43416
jmp 0x7652f
movq %rax, %r14
leaq 0x38(%rbx), %r15
leaq 0x68(%rbx), %rdi
addq $0x50, %rbx
callq 0x431ea
movq %rbx, %rdi
callq 0x431ea
movq %r15, %rdi
callq 0x432be
movq %r14, %rdi
callq 0x20380
| _ZN11server_taskC2E16server_task_type:
push r15
push r14
push rbx
mov rbx, rdi
mov qword ptr [rdi], 0FFFFFFFFFFFFFFFFh
mov [rdi+8], esi
mov dword ptr [rdi+0Ch], 0FFFFFFFFh
mov word ptr [rdi+10h], 101h
mov byte ptr [rdi+12h], 0
movdqa xmm0, cs:xmmword_144120
movdqu xmmword ptr [rdi+14h], xmm0
pcmpeqd xmm0, xmm0
movdqu xmmword ptr [rdi+28h], xmm0
lea r15, [rdi+88h]
pxor xmm0, xmm0
movdqu xmmword ptr [rdi+38h], xmm0
movdqu xmmword ptr [rdi+48h], xmm0
movdqu xmmword ptr [rdi+58h], xmm0
movdqu xmmword ptr [rdi+68h], xmm0
movdqu xmmword ptr [rdi+73h], xmm0
mov rdi, r15; this
call _ZN22common_params_samplingC2Ev; common_params_sampling::common_params_sampling(void)
lea rdi, [rbx+1C0h]; this
call _ZN25common_params_speculativeC2Ev; common_params_speculative::common_params_speculative(void)
xor eax, eax
mov [rbx+698h], al
mov [rbx+69Ch], eax
lea rcx, [rbx+6B0h]
mov [rbx+6A0h], rcx
mov [rbx+6A8h], rax
mov [rbx+6B0h], al
lea rcx, [rbx+6D0h]
mov [rbx+6C0h], rcx
mov [rbx+6C8h], rax
mov [rbx+6D0h], al
mov [rbx+6E0h], eax
pxor xmm0, xmm0
movdqu xmmword ptr [rbx+6E8h], xmm0
mov [rbx+6F8h], rax
mov dword ptr [rbx+700h], 0FFFFFFFFh
lea rcx, [rbx+720h]
mov [rbx+710h], rcx
mov [rbx+718h], rax
mov [rbx+720h], al
lea rcx, [rbx+740h]
mov [rbx+730h], rcx
mov [rbx+738h], rax
mov [rbx+740h], al
mov [rbx+750h], al
mov [rbx+768h], rax
movdqu xmmword ptr [rbx+758h], xmm0
pop rbx
pop r14
pop r15
retn
mov r14, rax
mov rdi, r15; this
call _ZN22common_params_samplingD2Ev; common_params_sampling::~common_params_sampling()
jmp short loc_7652F
mov r14, rax
loc_7652F:
lea r15, [rbx+38h]
lea rdi, [rbx+68h]; void *
add rbx, 50h ; 'P'
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, rbx; void *
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, r15
call _ZNSt6vectorI24common_adapter_lora_infoSaIS0_EED2Ev; std::vector<common_adapter_lora_info>::~vector()
mov rdi, r14
call __Unwind_Resume
| long long server_task::server_task(long long a1, int a2)
{
long long result; // rax
*(_QWORD *)a1 = -1LL;
*(_DWORD *)(a1 + 8) = a2;
*(_DWORD *)(a1 + 12) = -1;
*(_WORD *)(a1 + 16) = 257;
*(_BYTE *)(a1 + 18) = 0;
*(__m128i *)(a1 + 20) = _mm_load_si128((const __m128i *)&xmmword_144120);
*(_OWORD *)(a1 + 40) = -1LL;
*(_OWORD *)(a1 + 56) = 0LL;
*(_OWORD *)(a1 + 72) = 0LL;
*(_OWORD *)(a1 + 88) = 0LL;
*(_OWORD *)(a1 + 104) = 0LL;
*(_OWORD *)(a1 + 115) = 0LL;
common_params_sampling::common_params_sampling((common_params_sampling *)(a1 + 136));
common_params_speculative::common_params_speculative((common_params_speculative *)(a1 + 448));
result = 0LL;
*(_BYTE *)(a1 + 1688) = 0;
*(_DWORD *)(a1 + 1692) = 0;
*(_QWORD *)(a1 + 1696) = a1 + 1712;
*(_QWORD *)(a1 + 1704) = 0LL;
*(_BYTE *)(a1 + 1712) = 0;
*(_QWORD *)(a1 + 1728) = a1 + 1744;
*(_QWORD *)(a1 + 1736) = 0LL;
*(_BYTE *)(a1 + 1744) = 0;
*(_DWORD *)(a1 + 1760) = 0;
*(_OWORD *)(a1 + 1768) = 0LL;
*(_QWORD *)(a1 + 1784) = 0LL;
*(_DWORD *)(a1 + 1792) = -1;
*(_QWORD *)(a1 + 1808) = a1 + 1824;
*(_QWORD *)(a1 + 1816) = 0LL;
*(_BYTE *)(a1 + 1824) = 0;
*(_QWORD *)(a1 + 1840) = a1 + 1856;
*(_QWORD *)(a1 + 1848) = 0LL;
*(_BYTE *)(a1 + 1856) = 0;
*(_BYTE *)(a1 + 1872) = 0;
*(_QWORD *)(a1 + 1896) = 0LL;
*(_OWORD *)(a1 + 1880) = 0LL;
return result;
}
| server_task:
PUSH R15
PUSH R14
PUSH RBX
MOV RBX,RDI
MOV qword ptr [RDI],-0x1
MOV dword ptr [RDI + 0x8],ESI
MOV dword ptr [RDI + 0xc],0xffffffff
MOV word ptr [RDI + 0x10],0x101
MOV byte ptr [RDI + 0x12],0x0
MOVDQA XMM0,xmmword ptr [0x00244120]
MOVDQU xmmword ptr [RDI + 0x14],XMM0
PCMPEQD XMM0,XMM0
MOVDQU xmmword ptr [RDI + 0x28],XMM0
LEA R15,[RDI + 0x88]
PXOR XMM0,XMM0
MOVDQU xmmword ptr [RDI + 0x38],XMM0
MOVDQU xmmword ptr [RDI + 0x48],XMM0
MOVDQU xmmword ptr [RDI + 0x58],XMM0
MOVDQU xmmword ptr [RDI + 0x68],XMM0
MOVDQU xmmword ptr [RDI + 0x73],XMM0
LAB_00176453:
MOV RDI,R15
CALL 0x00142cee
LEA RDI,[RBX + 0x1c0]
LAB_00176462:
CALL 0x00142f40
LAB_00176467:
XOR EAX,EAX
MOV byte ptr [RBX + 0x698],AL
MOV dword ptr [RBX + 0x69c],EAX
LEA RCX,[RBX + 0x6b0]
MOV qword ptr [RBX + 0x6a0],RCX
MOV qword ptr [RBX + 0x6a8],RAX
MOV byte ptr [RBX + 0x6b0],AL
LEA RCX,[RBX + 0x6d0]
MOV qword ptr [RBX + 0x6c0],RCX
MOV qword ptr [RBX + 0x6c8],RAX
MOV byte ptr [RBX + 0x6d0],AL
MOV dword ptr [RBX + 0x6e0],EAX
PXOR XMM0,XMM0
MOVDQU xmmword ptr [RBX + 0x6e8],XMM0
MOV qword ptr [RBX + 0x6f8],RAX
MOV dword ptr [RBX + 0x700],0xffffffff
LEA RCX,[RBX + 0x720]
MOV qword ptr [RBX + 0x710],RCX
MOV qword ptr [RBX + 0x718],RAX
MOV byte ptr [RBX + 0x720],AL
LEA RCX,[RBX + 0x740]
MOV qword ptr [RBX + 0x730],RCX
MOV qword ptr [RBX + 0x738],RAX
MOV byte ptr [RBX + 0x740],AL
MOV byte ptr [RBX + 0x750],AL
MOV qword ptr [RBX + 0x768],RAX
MOVDQU xmmword ptr [RBX + 0x758],XMM0
POP RBX
POP R14
POP R15
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* server_task::server_task(server_task_type) */
void __thiscall server_task::server_task(server_task *this,int4 param_2)
{
int8 uVar1;
*(int8 *)this = 0xffffffffffffffff;
*(int4 *)(this + 8) = param_2;
*(int4 *)(this + 0xc) = 0xffffffff;
*(int2 *)(this + 0x10) = 0x101;
this[0x12] = (server_task)0x0;
uVar1 = _UNK_00244128;
*(int8 *)(this + 0x14) = _DAT_00244120;
*(int8 *)(this + 0x1c) = uVar1;
*(int4 *)(this + 0x28) = 0xffffffff;
*(int4 *)(this + 0x2c) = 0xffffffff;
*(int4 *)(this + 0x30) = 0xffffffff;
*(int4 *)(this + 0x34) = 0xffffffff;
*(int1 (*) [16])(this + 0x38) = (int1 [16])0x0;
*(int1 (*) [16])(this + 0x48) = (int1 [16])0x0;
*(int1 (*) [16])(this + 0x58) = (int1 [16])0x0;
*(int1 (*) [16])(this + 0x68) = (int1 [16])0x0;
*(int1 (*) [16])(this + 0x73) = (int1 [16])0x0;
/* try { // try from 00176453 to 0017645a has its CatchHandler @ 0017652c */
common_params_sampling::common_params_sampling((common_params_sampling *)(this + 0x88));
/* try { // try from 00176462 to 00176466 has its CatchHandler @ 0017651f */
common_params_speculative::common_params_speculative((common_params_speculative *)(this + 0x1c0));
this[0x698] = (server_task)0x0;
*(int4 *)(this + 0x69c) = 0;
*(server_task **)(this + 0x6a0) = this + 0x6b0;
*(int8 *)(this + 0x6a8) = 0;
this[0x6b0] = (server_task)0x0;
*(server_task **)(this + 0x6c0) = this + 0x6d0;
*(int8 *)(this + 0x6c8) = 0;
this[0x6d0] = (server_task)0x0;
*(int4 *)(this + 0x6e0) = 0;
*(int1 (*) [16])(this + 0x6e8) = (int1 [16])0x0;
*(int8 *)(this + 0x6f8) = 0;
*(int4 *)(this + 0x700) = 0xffffffff;
*(server_task **)(this + 0x710) = this + 0x720;
*(int8 *)(this + 0x718) = 0;
this[0x720] = (server_task)0x0;
*(server_task **)(this + 0x730) = this + 0x740;
*(int8 *)(this + 0x738) = 0;
this[0x740] = (server_task)0x0;
this[0x750] = (server_task)0x0;
*(int8 *)(this + 0x768) = 0;
*(int1 (*) [16])(this + 0x758) = (int1 [16])0x0;
return;
}
| |
23,303 | google::protobuf::FileDescriptorSet::Clear() | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.pb.cc | void FileDescriptorSet::Clear() {
// @@protoc_insertion_point(message_clear_start:google.protobuf.FileDescriptorSet)
uint32_t cached_has_bits = 0;
// Prevent compiler warnings about cached_has_bits being unused
(void) cached_has_bits;
_impl_.file_.Clear();
_internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
} | O3 | cpp | google::protobuf::FileDescriptorSet::Clear():
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movslq 0x18(%rdi), %r14
testq %r14, %r14
jle 0x47af0
movq 0x20(%rbx), %r15
xorl %r12d, %r12d
movq 0x8(%r15,%r12,8), %rdi
incq %r12
callq 0x4831c
cmpq %r12, %r14
jne 0x47ad7
movl $0x0, 0x18(%rbx)
testb $0x1, 0x8(%rbx)
jne 0x47b02
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
addq $0x8, %rbx
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x597c4
nop
| _ZN6google8protobuf17FileDescriptorSet5ClearEv:
push r15
push r14
push r12
push rbx
push rax
mov rbx, rdi
movsxd r14, dword ptr [rdi+18h]
test r14, r14
jle short loc_47AF0
mov r15, [rbx+20h]
xor r12d, r12d
loc_47AD7:
mov rdi, [r15+r12*8+8]; this
inc r12
call _ZN6google8protobuf19FileDescriptorProto5ClearEv; google::protobuf::FileDescriptorProto::Clear(void)
cmp r14, r12
jnz short loc_47AD7
mov dword ptr [rbx+18h], 0
loc_47AF0:
test byte ptr [rbx+8], 1
jnz short loc_47B02
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
loc_47B02:
add rbx, 8
mov rdi, rbx
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
jmp _ZN6google8protobuf8internal16InternalMetadata7DoClearINS0_15UnknownFieldSetEEEvv; google::protobuf::internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet>(void)
| long long google::protobuf::FileDescriptorSet::Clear(google::protobuf::FileDescriptorSet *this)
{
long long v2; // r14
long long v3; // r15
long long i; // r12
google::protobuf::FileDescriptorProto *v5; // rdi
long long result; // rax
v2 = *((int *)this + 6);
if ( v2 > 0 )
{
v3 = *((_QWORD *)this + 4);
for ( i = 0LL; i != v2; ++i )
{
v5 = *(google::protobuf::FileDescriptorProto **)(v3 + 8 * i + 8);
result = google::protobuf::FileDescriptorProto::Clear(v5);
}
*((_DWORD *)this + 6) = 0;
}
if ( (*((_BYTE *)this + 8) & 1) != 0 )
return google::protobuf::internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet>((char *)this + 8);
return result;
}
| Clear:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOVSXD R14,dword ptr [RDI + 0x18]
TEST R14,R14
JLE 0x00147af0
MOV R15,qword ptr [RBX + 0x20]
XOR R12D,R12D
LAB_00147ad7:
MOV RDI,qword ptr [R15 + R12*0x8 + 0x8]
INC R12
CALL 0x0014831c
CMP R14,R12
JNZ 0x00147ad7
MOV dword ptr [RBX + 0x18],0x0
LAB_00147af0:
TEST byte ptr [RBX + 0x8],0x1
JNZ 0x00147b02
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
LAB_00147b02:
ADD RBX,0x8
MOV RDI,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
JMP 0x001597c4
|
/* google::protobuf::FileDescriptorSet::Clear() */
void __thiscall google::protobuf::FileDescriptorSet::Clear(FileDescriptorSet *this)
{
long lVar1;
int iVar2;
long lVar3;
long lVar4;
iVar2 = *(int *)(this + 0x18);
if (0 < (long)iVar2) {
lVar3 = *(long *)(this + 0x20);
lVar4 = 0;
do {
lVar1 = lVar4 * 8;
lVar4 = lVar4 + 1;
FileDescriptorProto::Clear(*(FileDescriptorProto **)(lVar3 + 8 + lVar1));
} while (iVar2 != lVar4);
*(int4 *)(this + 0x18) = 0;
}
if (((byte)this[8] & 1) == 0) {
return;
}
internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet>
((InternalMetadata *)(this + 8));
return;
}
| |
23,304 | lunasvg::SVGSVGElement::render(lunasvg::SVGRenderState&) const | dmazzella[P]pylunasvg/lunasvg/source/svgelement.cpp | void SVGSVGElement::render(SVGRenderState& state) const
{
if(isDisplayNone())
return;
LengthContext lengthContext(this);
const Size viewportSize = {
lengthContext.valueForLength(m_width),
lengthContext.valueForLength(m_height)
};
if(viewportSize.isEmpty())
return;
SVGBlendInfo blendInfo(this);
SVGRenderState newState(this, state, localTransform());
newState.beginGroup(blendInfo);
if(isOverflowHidden())
newState->clipRect(getClipRect(viewportSize), FillRule::NonZero, newState.currentTransform());
renderChildren(newState);
newState.endGroup(blendInfo);
} | O0 | cpp | lunasvg::SVGSVGElement::render(lunasvg::SVGRenderState&) const:
pushq %rbp
movq %rsp, %rbp
subq $0x130, %rsp # imm = 0x130
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0xc0(%rbp)
callq 0x20470
testb $0x1, %al
jne 0x1ac89
jmp 0x1ac8e
jmp 0x1ae6b
movq -0xc0(%rbp), %rsi
leaq -0x20(%rbp), %rdi
xorl %edx, %edx
callq 0x20050
movq -0xc0(%rbp), %rsi
addq $0x100, %rsi # imm = 0x100
leaq -0x20(%rbp), %rdi
callq 0x20080
movq -0xc0(%rbp), %rsi
movss %xmm0, -0xc4(%rbp)
addq $0x118, %rsi # imm = 0x118
leaq -0x20(%rbp), %rdi
callq 0x20080
movaps %xmm0, %xmm1
movss -0xc4(%rbp), %xmm0
leaq -0x28(%rbp), %rdi
callq 0x20020
leaq -0x28(%rbp), %rdi
callq 0x20540
testb $0x1, %al
jne 0x1acf9
jmp 0x1acfe
jmp 0x1ae6b
movq -0xc0(%rbp), %rsi
leaq -0x40(%rbp), %rdi
movq %rdi, -0xd0(%rbp)
callq 0x4c890
movq -0xc0(%rbp), %rsi
movq -0x10(%rbp), %rax
movq %rax, -0xe8(%rbp)
movq (%rsi), %rax
movq 0x50(%rax), %rax
leaq -0x98(%rbp), %rdi
movq %rdi, -0xe0(%rbp)
callq *%rax
movq -0xc0(%rbp), %rsi
movq -0xe8(%rbp), %rdx
movq -0xe0(%rbp), %rcx
leaq -0x80(%rbp), %rdi
movq %rdi, -0xd8(%rbp)
callq 0x20e00
movq -0xd8(%rbp), %rdi
movq -0xd0(%rbp), %rsi
callq 0x4c9d0
jmp 0x1ad78
movq -0xc0(%rbp), %rdi
callq 0x20e90
movb %al, -0xe9(%rbp)
jmp 0x1ad8c
movb -0xe9(%rbp), %al
testb $0x1, %al
jne 0x1ad9b
jmp 0x1ae41
leaq -0x80(%rbp), %rdi
callq 0x20750
movq %rax, -0xf8(%rbp)
jmp 0x1adad
movq -0xc0(%rbp), %rdi
addq $0x98, %rdi
leaq -0x28(%rbp), %rsi
callq 0x1a270
movaps %xmm1, -0x120(%rbp)
movaps %xmm0, -0x110(%rbp)
jmp 0x1add4
movaps -0x120(%rbp), %xmm0
movaps -0x110(%rbp), %xmm1
movlpd %xmm1, -0xb4(%rbp)
movlpd %xmm0, -0xac(%rbp)
leaq -0x80(%rbp), %rdi
callq 0x20eb0
movq %rax, -0x128(%rbp)
jmp 0x1ae04
movq -0x128(%rbp), %rcx
movq -0xf8(%rbp), %rdi
leaq -0xb4(%rbp), %rsi
xorl %edx, %edx
callq 0x13ef0
jmp 0x1ae22
jmp 0x1ae41
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xa0(%rbp)
movl %eax, -0xa4(%rbp)
leaq -0x80(%rbp), %rdi
callq 0xe810
jmp 0x1ae74
movq -0xc0(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x1a060
jmp 0x1ae53
leaq -0x80(%rbp), %rdi
leaq -0x40(%rbp), %rsi
callq 0x4cae0
jmp 0x1ae62
leaq -0x80(%rbp), %rdi
callq 0xe810
addq $0x130, %rsp # imm = 0x130
popq %rbp
retq
movq -0xa0(%rbp), %rdi
callq 0xb6c0
| _ZNK7lunasvg13SVGSVGElement6renderERNS_14SVGRenderStateE:
push rbp
mov rbp, rsp
sub rsp, 130h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rdi, [rbp+var_8]; this
mov [rbp+var_C0], rdi
call _ZNK7lunasvg10SVGElement13isDisplayNoneEv; lunasvg::SVGElement::isDisplayNone(void)
test al, 1
jnz short loc_1AC89
jmp short loc_1AC8E
loc_1AC89:
jmp loc_1AE6B
loc_1AC8E:
mov rsi, [rbp+var_C0]
lea rdi, [rbp+var_20]
xor edx, edx
call _ZN7lunasvg13LengthContextC2EPKNS_10SVGElementENS_5UnitsE; lunasvg::LengthContext::LengthContext(lunasvg::SVGElement const*,lunasvg::Units)
mov rsi, [rbp+var_C0]
add rsi, 100h; lunasvg::SVGLength *
lea rdi, [rbp+var_20]; this
call _ZNK7lunasvg13LengthContext14valueForLengthERKNS_9SVGLengthE; lunasvg::LengthContext::valueForLength(lunasvg::SVGLength const&)
mov rsi, [rbp+var_C0]
movss [rbp+var_C4], xmm0
add rsi, 118h; lunasvg::SVGLength *
lea rdi, [rbp+var_20]; this
call _ZNK7lunasvg13LengthContext14valueForLengthERKNS_9SVGLengthE; lunasvg::LengthContext::valueForLength(lunasvg::SVGLength const&)
movaps xmm1, xmm0; float
movss xmm0, [rbp+var_C4]; float
lea rdi, [rbp+var_28]; this
call _ZN7lunasvg4SizeC2Eff; lunasvg::Size::Size(float,float)
lea rdi, [rbp+var_28]; this
call _ZNK7lunasvg4Size7isEmptyEv; lunasvg::Size::isEmpty(void)
test al, 1
jnz short loc_1ACF9
jmp short loc_1ACFE
loc_1ACF9:
jmp loc_1AE6B
loc_1ACFE:
mov rsi, [rbp+var_C0]; lunasvg::SVGElement *
lea rdi, [rbp+var_40]; this
mov [rbp+var_D0], rdi
call _ZN7lunasvg12SVGBlendInfoC2EPKNS_10SVGElementE; lunasvg::SVGBlendInfo::SVGBlendInfo(lunasvg::SVGElement const*)
mov rsi, [rbp+var_C0]
mov rax, [rbp+var_10]
mov [rbp+var_E8], rax
mov rax, [rsi]
mov rax, [rax+50h]
lea rdi, [rbp+var_98]
mov [rbp+var_E0], rdi
call rax
mov rsi, [rbp+var_C0]; lunasvg::SVGElement *
mov rdx, [rbp+var_E8]; lunasvg::SVGRenderState *
mov rcx, [rbp+var_E0]; lunasvg::Transform *
lea rdi, [rbp+var_80]; this
mov [rbp+var_D8], rdi
call _ZN7lunasvg14SVGRenderStateC2EPKNS_10SVGElementERKS0_RKNS_9TransformE; lunasvg::SVGRenderState::SVGRenderState(lunasvg::SVGElement const*,lunasvg::SVGRenderState const&,lunasvg::Transform const&)
mov rdi, [rbp+var_D8]; this
mov rsi, [rbp+var_D0]; lunasvg::SVGBlendInfo *
call _ZN7lunasvg14SVGRenderState10beginGroupERKNS_12SVGBlendInfoE; lunasvg::SVGRenderState::beginGroup(lunasvg::SVGBlendInfo const&)
jmp short $+2
loc_1AD78:
mov rdi, [rbp+var_C0]; this
call _ZNK7lunasvg10SVGElement16isOverflowHiddenEv; lunasvg::SVGElement::isOverflowHidden(void)
mov [rbp+var_E9], al
jmp short $+2
loc_1AD8C:
mov al, [rbp+var_E9]
test al, 1
jnz short loc_1AD9B
jmp loc_1AE41
loc_1AD9B:
lea rdi, [rbp+var_80]
call _ZNK7lunasvg14SVGRenderStateptEv; lunasvg::SVGRenderState::operator->(void)
mov [rbp+var_F8], rax
jmp short $+2
loc_1ADAD:
mov rdi, [rbp+var_C0]
add rdi, 98h; this
lea rsi, [rbp+var_28]; lunasvg::Size *
call _ZNK7lunasvg15SVGFitToViewBox11getClipRectERKNS_4SizeE; lunasvg::SVGFitToViewBox::getClipRect(lunasvg::Size const&)
movaps [rbp+var_120], xmm1
movaps [rbp+var_110], xmm0
jmp short $+2
loc_1ADD4:
movaps xmm0, [rbp+var_120]
movaps xmm1, [rbp+var_110]
movlpd [rbp+var_B4], xmm1
movlpd [rbp+var_AC], xmm0
lea rdi, [rbp+var_80]; this
call _ZNK7lunasvg14SVGRenderState16currentTransformEv; lunasvg::SVGRenderState::currentTransform(void)
mov [rbp+var_128], rax
jmp short $+2
loc_1AE04:
mov rcx, [rbp+var_128]
mov rdi, [rbp+var_F8]
lea rsi, [rbp+var_B4]
xor edx, edx
call _ZN7lunasvg6Canvas8clipRectERKNS_4RectENS_8FillRuleERKNS_9TransformE; lunasvg::Canvas::clipRect(lunasvg::Rect const&,lunasvg::FillRule,lunasvg::Transform const&)
jmp short $+2
loc_1AE22:
jmp short loc_1AE41
mov rcx, rax
mov eax, edx
mov [rbp+var_A0], rcx
mov [rbp+var_A4], eax
lea rdi, [rbp+var_80]; this
call _ZN7lunasvg14SVGRenderStateD2Ev; lunasvg::SVGRenderState::~SVGRenderState()
jmp short loc_1AE74
loc_1AE41:
mov rdi, [rbp+var_C0]; this
lea rsi, [rbp+var_80]; lunasvg::SVGRenderState *
call _ZNK7lunasvg10SVGElement14renderChildrenERNS_14SVGRenderStateE; lunasvg::SVGElement::renderChildren(lunasvg::SVGRenderState &)
jmp short $+2
loc_1AE53:
lea rdi, [rbp+var_80]; this
lea rsi, [rbp+var_40]; lunasvg::SVGBlendInfo *
call _ZN7lunasvg14SVGRenderState8endGroupERKNS_12SVGBlendInfoE; lunasvg::SVGRenderState::endGroup(lunasvg::SVGBlendInfo const&)
jmp short $+2
loc_1AE62:
lea rdi, [rbp+var_80]; this
call _ZN7lunasvg14SVGRenderStateD2Ev; lunasvg::SVGRenderState::~SVGRenderState()
loc_1AE6B:
add rsp, 130h
pop rbp
retn
loc_1AE74:
mov rdi, [rbp+var_A0]
call __Unwind_Resume
| void lunasvg::SVGSVGElement::render(lunasvg::SVGSVGElement *this, lunasvg::SVGRenderState *a2, double a3)
{
lunasvg::Transform *v4; // [rsp+8h] [rbp-128h]
long long v5; // [rsp+38h] [rbp-F8h]
lunasvg::SVGRenderState *v6; // [rsp+48h] [rbp-E8h]
_QWORD v7[2]; // [rsp+7Ch] [rbp-B4h] BYREF
_BYTE v8[24]; // [rsp+98h] [rbp-98h] BYREF
_BYTE v9[64]; // [rsp+B0h] [rbp-80h] BYREF
_BYTE v10[24]; // [rsp+F0h] [rbp-40h] BYREF
_BYTE v11[8]; // [rsp+108h] [rbp-28h] BYREF
_BYTE v12[16]; // [rsp+110h] [rbp-20h] BYREF
lunasvg::SVGRenderState *v13; // [rsp+120h] [rbp-10h]
lunasvg::SVGElement *v14; // [rsp+128h] [rbp-8h]
v14 = this;
v13 = a2;
if ( (lunasvg::SVGElement::isDisplayNone(this) & 1) == 0 )
{
lunasvg::LengthContext::LengthContext(v12, this, 0LL);
lunasvg::LengthContext::valueForLength(
(lunasvg::LengthContext *)v12,
(lunasvg::SVGSVGElement *)((char *)this + 256));
lunasvg::LengthContext::valueForLength(
(lunasvg::LengthContext *)v12,
(lunasvg::SVGSVGElement *)((char *)this + 280));
lunasvg::Size::Size((lunasvg::Size *)v11, *(float *)&a3, *(float *)&a3);
if ( (lunasvg::Size::isEmpty((lunasvg::Size *)v11) & 1) == 0 )
{
lunasvg::SVGBlendInfo::SVGBlendInfo((lunasvg::SVGBlendInfo *)v10, this);
v6 = v13;
(*(void (**)(void))(*(_QWORD *)this + 80LL))();
lunasvg::SVGRenderState::SVGRenderState((lunasvg::SVGRenderState *)v9, this, v6, (const lunasvg::Transform *)v8);
lunasvg::SVGRenderState::beginGroup((lunasvg::SVGRenderState *)v9, (const lunasvg::SVGBlendInfo *)v10);
if ( (lunasvg::SVGElement::isOverflowHidden(this) & 1) != 0 )
{
v5 = lunasvg::SVGRenderState::operator->(v9);
v7[0] = lunasvg::SVGFitToViewBox::getClipRect(
(lunasvg::SVGSVGElement *)((char *)this + 152),
(const lunasvg::Size *)v11,
COERCE_DOUBLE((unsigned long long)LODWORD(a3)),
a3);
*(double *)&v7[1] = a3;
v4 = (lunasvg::Transform *)lunasvg::SVGRenderState::currentTransform((lunasvg::SVGRenderState *)v9);
lunasvg::Canvas::clipRect(v5, (float *)v7, 0, v4);
}
lunasvg::SVGElement::renderChildren(this, (lunasvg::SVGRenderState *)v9);
lunasvg::SVGRenderState::endGroup((lunasvg::SVGRenderState *)v9, (const lunasvg::SVGBlendInfo *)v10);
lunasvg::SVGRenderState::~SVGRenderState((lunasvg::SVGRenderState *)v9);
}
}
}
| render:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x130
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RDI,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0xc0],RDI
CALL 0x00120470
TEST AL,0x1
JNZ 0x0011ac89
JMP 0x0011ac8e
LAB_0011ac89:
JMP 0x0011ae6b
LAB_0011ac8e:
MOV RSI,qword ptr [RBP + -0xc0]
LEA RDI,[RBP + -0x20]
XOR EDX,EDX
CALL 0x00120050
MOV RSI,qword ptr [RBP + -0xc0]
ADD RSI,0x100
LEA RDI,[RBP + -0x20]
CALL 0x00120080
MOV RSI,qword ptr [RBP + -0xc0]
MOVSS dword ptr [RBP + -0xc4],XMM0
ADD RSI,0x118
LEA RDI,[RBP + -0x20]
CALL 0x00120080
MOVAPS XMM1,XMM0
MOVSS XMM0,dword ptr [RBP + -0xc4]
LEA RDI,[RBP + -0x28]
CALL 0x00120020
LEA RDI,[RBP + -0x28]
CALL 0x00120540
TEST AL,0x1
JNZ 0x0011acf9
JMP 0x0011acfe
LAB_0011acf9:
JMP 0x0011ae6b
LAB_0011acfe:
MOV RSI,qword ptr [RBP + -0xc0]
LEA RDI,[RBP + -0x40]
MOV qword ptr [RBP + -0xd0],RDI
CALL 0x0014c890
MOV RSI,qword ptr [RBP + -0xc0]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0xe8],RAX
MOV RAX,qword ptr [RSI]
MOV RAX,qword ptr [RAX + 0x50]
LEA RDI,[RBP + -0x98]
MOV qword ptr [RBP + -0xe0],RDI
CALL RAX
MOV RSI,qword ptr [RBP + -0xc0]
MOV RDX,qword ptr [RBP + -0xe8]
MOV RCX,qword ptr [RBP + -0xe0]
LEA RDI,[RBP + -0x80]
MOV qword ptr [RBP + -0xd8],RDI
CALL 0x00120e00
MOV RDI,qword ptr [RBP + -0xd8]
MOV RSI,qword ptr [RBP + -0xd0]
LAB_0011ad71:
CALL 0x0014c9d0
JMP 0x0011ad78
LAB_0011ad78:
MOV RDI,qword ptr [RBP + -0xc0]
CALL 0x00120e90
MOV byte ptr [RBP + -0xe9],AL
JMP 0x0011ad8c
LAB_0011ad8c:
MOV AL,byte ptr [RBP + -0xe9]
TEST AL,0x1
JNZ 0x0011ad9b
JMP 0x0011ae41
LAB_0011ad9b:
LEA RDI,[RBP + -0x80]
CALL 0x00120750
MOV qword ptr [RBP + -0xf8],RAX
JMP 0x0011adad
LAB_0011adad:
MOV RDI,qword ptr [RBP + -0xc0]
ADD RDI,0x98
LEA RSI,[RBP + -0x28]
CALL 0x0011a270
MOVAPS xmmword ptr [RBP + -0x120],XMM1
MOVAPS xmmword ptr [RBP + -0x110],XMM0
JMP 0x0011add4
LAB_0011add4:
MOVAPS XMM0,xmmword ptr [RBP + -0x120]
MOVAPS XMM1,xmmword ptr [RBP + -0x110]
MOVLPD qword ptr [RBP + -0xb4],XMM1
MOVLPD qword ptr [RBP + -0xac],XMM0
LEA RDI,[RBP + -0x80]
CALL 0x00120eb0
MOV qword ptr [RBP + -0x128],RAX
JMP 0x0011ae04
LAB_0011ae04:
MOV RCX,qword ptr [RBP + -0x128]
MOV RDI,qword ptr [RBP + -0xf8]
LEA RSI,[RBP + -0xb4]
XOR EDX,EDX
CALL 0x00113ef0
JMP 0x0011ae22
LAB_0011ae22:
JMP 0x0011ae41
LAB_0011ae41:
MOV RDI,qword ptr [RBP + -0xc0]
LEA RSI,[RBP + -0x80]
CALL 0x0011a060
JMP 0x0011ae53
LAB_0011ae53:
LEA RDI,[RBP + -0x80]
LEA RSI,[RBP + -0x40]
CALL 0x0014cae0
LAB_0011ae60:
JMP 0x0011ae62
LAB_0011ae62:
LEA RDI,[RBP + -0x80]
CALL 0x0010e810
LAB_0011ae6b:
ADD RSP,0x130
POP RBP
RET
|
/* lunasvg::SVGSVGElement::render(lunasvg::SVGRenderState&) const */
void __thiscall lunasvg::SVGSVGElement::render(SVGSVGElement *this,SVGRenderState *param_1)
{
SVGRenderState *pSVar1;
byte bVar2;
ulong uVar3;
Canvas *pCVar4;
float fVar5;
int8 uVar6;
int8 local_bc;
int8 local_b4;
Transform local_a0 [24];
SVGRenderState local_88 [64];
SVGBlendInfo local_48 [24];
Size local_30 [8];
LengthContext local_28 [16];
SVGRenderState *local_18;
SVGSVGElement *local_10;
local_18 = param_1;
local_10 = this;
uVar3 = SVGElement::isDisplayNone((SVGElement *)this);
if ((uVar3 & 1) == 0) {
LengthContext::LengthContext(local_28,this,0);
fVar5 = (float)LengthContext::valueForLength(local_28,(SVGLength *)(this + 0x100));
uVar6 = LengthContext::valueForLength(local_28,(SVGLength *)(this + 0x118));
Size::Size(local_30,fVar5,(float)uVar6);
uVar3 = Size::isEmpty(local_30);
if ((uVar3 & 1) == 0) {
SVGBlendInfo::SVGBlendInfo(local_48,(SVGElement *)this);
pSVar1 = local_18;
(**(code **)(*(long *)this + 0x50))();
SVGRenderState::SVGRenderState(local_88,(SVGElement *)this,pSVar1,local_a0);
/* try { // try from 0011ad71 to 0011ae5f has its CatchHandler @ 0011ae24 */
SVGRenderState::beginGroup((SVGBlendInfo *)local_88);
bVar2 = SVGElement::isOverflowHidden((SVGElement *)this);
if ((bVar2 & 1) != 0) {
pCVar4 = (Canvas *)SVGRenderState::operator->(local_88);
local_b4 = uVar6;
local_bc = SVGFitToViewBox::getClipRect((Size *)(this + 0x98));
uVar6 = SVGRenderState::currentTransform(local_88);
Canvas::clipRect(pCVar4,&local_bc,0,uVar6);
}
SVGElement::renderChildren((SVGElement *)this,local_88);
SVGRenderState::endGroup(local_88,local_48);
SVGRenderState::~SVGRenderState(local_88);
}
}
return;
}
| |
23,305 | fnv1a_hash | seiftnesse[P]memoryallocator/src/custom_alloc_util.c | uint32_t fnv1a_hash(const void *data, size_t len) {
const uint8_t *bytes = (const uint8_t *) (data);
uint32_t hash = 2166136261u; // FNV offset basis
for (size_t i = 0; i < len; i++) {
hash ^= bytes[i];
hash *= 16777619; // FNV prime
}
return hash;
} | O1 | c | fnv1a_hash:
movl $0x811c9dc5, %eax # imm = 0x811C9DC5
testq %rsi, %rsi
je 0x3c14
xorl %ecx, %ecx
movzbl (%rdi,%rcx), %edx
xorl %eax, %edx
imull $0x1000193, %edx, %eax # imm = 0x1000193
incq %rcx
cmpq %rcx, %rsi
jne 0x3c00
retq
| fnv1a_hash:
mov eax, 811C9DC5h
test rsi, rsi
jz short locret_3C14
xor ecx, ecx
loc_3C00:
movzx edx, byte ptr [rdi+rcx]
xor edx, eax
imul eax, edx, 1000193h
inc rcx
cmp rsi, rcx
jnz short loc_3C00
locret_3C14:
retn
| long long fnv1a_hash(long long a1, long long a2)
{
long long result; // rax
long long i; // rcx
result = 2166136261LL;
if ( a2 )
{
for ( i = 0LL; i != a2; ++i )
result = 16777619 * ((unsigned int)result ^ *(unsigned __int8 *)(a1 + i));
}
return result;
}
| fnv1a_hash:
MOV EAX,0x811c9dc5
TEST RSI,RSI
JZ 0x00103c14
XOR ECX,ECX
LAB_00103c00:
MOVZX EDX,byte ptr [RDI + RCX*0x1]
XOR EDX,EAX
IMUL EAX,EDX,0x1000193
INC RCX
CMP RSI,RCX
JNZ 0x00103c00
LAB_00103c14:
RET
|
void fnv1a_hash(int8 param_1,long param_2)
{
long lVar1;
if (param_2 != 0) {
lVar1 = 0;
do {
lVar1 = lVar1 + 1;
} while (param_2 != lVar1);
}
return;
}
| |
23,306 | fnv1a_hash | seiftnesse[P]memoryallocator/src/custom_alloc_util.c | uint32_t fnv1a_hash(const void *data, size_t len) {
const uint8_t *bytes = (const uint8_t *) (data);
uint32_t hash = 2166136261u; // FNV offset basis
for (size_t i = 0; i < len; i++) {
hash ^= bytes[i];
hash *= 16777619; // FNV prime
}
return hash;
} | O3 | c | fnv1a_hash:
movl $0x811c9dc5, %eax # imm = 0x811C9DC5
testq %rsi, %rsi
je 0x3c04
xorl %ecx, %ecx
movzbl (%rdi,%rcx), %edx
xorl %eax, %edx
imull $0x1000193, %edx, %eax # imm = 0x1000193
incq %rcx
cmpq %rcx, %rsi
jne 0x3bf0
retq
| fnv1a_hash:
mov eax, 811C9DC5h
test rsi, rsi
jz short locret_3C04
xor ecx, ecx
loc_3BF0:
movzx edx, byte ptr [rdi+rcx]
xor edx, eax
imul eax, edx, 1000193h
inc rcx
cmp rsi, rcx
jnz short loc_3BF0
locret_3C04:
retn
| long long fnv1a_hash(long long a1, long long a2)
{
long long result; // rax
long long i; // rcx
result = 2166136261LL;
if ( a2 )
{
for ( i = 0LL; i != a2; ++i )
result = 16777619 * ((unsigned int)result ^ *(unsigned __int8 *)(a1 + i));
}
return result;
}
| fnv1a_hash:
MOV EAX,0x811c9dc5
TEST RSI,RSI
JZ 0x00103c04
XOR ECX,ECX
LAB_00103bf0:
MOVZX EDX,byte ptr [RDI + RCX*0x1]
XOR EDX,EAX
IMUL EAX,EDX,0x1000193
INC RCX
CMP RSI,RCX
JNZ 0x00103bf0
LAB_00103c04:
RET
|
void fnv1a_hash(int8 param_1,long param_2)
{
long lVar1;
if (param_2 != 0) {
lVar1 = 0;
do {
lVar1 = lVar1 + 1;
} while (param_2 != lVar1);
}
return;
}
| |
23,307 | flush_cached_blocks | eloqsql/storage/maria/ma_pagecache.c | static int flush_cached_blocks(PAGECACHE *pagecache,
PAGECACHE_FILE *file,
PAGECACHE_BLOCK_LINK **cache,
PAGECACHE_BLOCK_LINK **end,
enum flush_type type,
int *first_errno)
{
int rc= PCFLUSH_OK;
my_bool error;
uint count= (uint) (end-cache);
DBUG_ENTER("flush_cached_blocks");
*first_errno= 0;
/* Don't lock the cache during the flush */
pagecache_pthread_mutex_unlock(&pagecache->cache_lock);
/*
As all blocks referred in 'cache' are marked by PCBLOCK_IN_FLUSH
we are guaranteed that no thread will change them
*/
qsort((uchar*) cache, count, sizeof(*cache), (qsort_cmp) cmp_sec_link);
pagecache_pthread_mutex_lock(&pagecache->cache_lock);
for (; cache != end; cache++)
{
PAGECACHE_BLOCK_LINK *block= *cache;
/*
In the case of non_transactional tables we want to flush also
block pinned with reads. This is becasue we may have other
threads reading the block during flush, as non transactional
tables can have many readers while the one writer is doing the
flush.
We don't want to do flush pinned blocks during checkpoint.
We detect the checkpoint case by checking if type is LAZY.
*/
if ((type == FLUSH_KEEP_LAZY && block->pins) || block->wlocks)
{
KEYCACHE_DBUG_PRINT("flush_cached_blocks",
("block: %u (%p) pinned",
PCBLOCK_NUMBER(pagecache, block), block));
DBUG_PRINT("info", ("block: %u (%p) pinned",
PCBLOCK_NUMBER(pagecache, block), block));
PCBLOCK_INFO(block);
/* undo the mark put by flush_pagecache_blocks_int(): */
block->status&= ~PCBLOCK_IN_FLUSH;
rc|= PCFLUSH_PINNED;
DBUG_PRINT("warning", ("Page pinned"));
unreg_request(pagecache, block, 1);
if (!*first_errno)
*first_errno= HA_ERR_INTERNAL_ERROR;
continue;
}
if (make_lock_and_pin(pagecache, block,
PAGECACHE_LOCK_READ, PAGECACHE_PIN, FALSE))
DBUG_ASSERT(0);
KEYCACHE_PRINT("flush_cached_blocks",
("block: %u (%p) to be flushed",
PCBLOCK_NUMBER(pagecache, block), block));
DBUG_PRINT("info", ("block: %u (%p) to be flushed",
PCBLOCK_NUMBER(pagecache, block), block));
PCBLOCK_INFO(block);
/**
@todo IO If page is contiguous with next page to flush, group flushes
in one single my_pwrite().
*/
/**
It is important to use block->hash_link->file below and not 'file', as
the first one is right and the second may have different out-of-date
content (see StaleFilePointersInFlush in ma_checkpoint.c).
@todo change argument of functions to be File.
*/
pagecache_pthread_mutex_unlock(&pagecache->cache_lock);
error= pagecache_fwrite(pagecache, &block->hash_link->file,
block->buffer,
block->hash_link->pageno,
block->type,
pagecache->readwrite_flags);
pagecache_pthread_mutex_lock(&pagecache->cache_lock);
if (make_lock_and_pin(pagecache, block,
PAGECACHE_LOCK_READ_UNLOCK,
PAGECACHE_UNPIN, FALSE))
DBUG_ASSERT(0);
pagecache->global_cache_write++;
if (error)
{
block->status|= PCBLOCK_ERROR;
block->error= (int16) my_errno;
my_debug_put_break_here();
if (!*first_errno)
*first_errno= my_errno ? my_errno : -1;
rc|= PCFLUSH_ERROR;
}
/*
Let to proceed for possible waiting requests to write to the block page.
It might happen only during an operation to resize the key cache.
*/
if (block->wqueue[COND_FOR_SAVED].last_thread)
wqueue_release_queue(&block->wqueue[COND_FOR_SAVED]);
/* type will never be FLUSH_IGNORE_CHANGED here */
if (! (type == FLUSH_KEEP || type == FLUSH_KEEP_LAZY ||
type == FLUSH_FORCE_WRITE))
{
if (!free_block(pagecache, block, 1))
{
pagecache->blocks_changed--;
pagecache->global_blocks_changed--;
}
else
{
block->status&= ~PCBLOCK_IN_FLUSH;
link_to_file_list(pagecache, block, file, 1);
}
}
else
{
block->status&= ~PCBLOCK_IN_FLUSH;
link_to_file_list(pagecache, block, file, 1);
unreg_request(pagecache, block, 1);
}
}
DBUG_RETURN(rc);
} | O3 | c | flush_cached_blocks:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r9, %r14
movl %r8d, -0x2c(%rbp)
movq %rdx, %r12
movq %rsi, -0x38(%rbp)
movq %rdi, %r13
movq %rcx, -0x48(%rbp)
movq %rcx, %rbx
subq %rdx, %rbx
shrq $0x3, %rbx
movl $0x0, (%r9)
leaq 0xc8(%rdi), %r15
movq 0x108(%rdi), %rdi
testq %rdi, %rdi
jne 0x52b29
movq %r15, %rdi
callq 0x2a1e0
movl %ebx, %esi
leaq 0x258(%rip), %rcx # 0x52b57
movl $0x8, %edx
movq %r12, %rdi
callq 0x2a610
cmpq $0x0, 0x108(%r13)
jne 0x52b3e
movq %r15, %rdi
callq 0x2a220
cmpq -0x48(%rbp), %r12
movl -0x2c(%rbp), %eax
je 0x52b14
movq %r15, -0x50(%rbp)
xorl %r15d, %r15d
movq %r14, -0x40(%rbp)
movq (%r12), %rbx
cmpl $0x4, %eax
jne 0x52949
cmpl $0x0, 0x64(%rbx)
jne 0x5294f
cmpl $0x0, 0x68(%rbx)
je 0x5297d
andb $-0x11, 0x74(%rbx)
orl $0x2, %r15d
movq %r13, %rdi
movq %rbx, %rsi
movl $0x1, %edx
callq 0x4f7cf
cmpl $0x0, (%r14)
jne 0x52a98
movl $0x7a, (%r14)
jmp 0x52a98
movl %r15d, -0x30(%rbp)
movq %r13, %rdi
movq %rbx, %rsi
movl $0x3, %edx
movl $0x2, %ecx
callq 0x4f65f
movq 0x108(%r13), %rdi
testq %rdi, %rdi
jne 0x52ae6
movq -0x50(%rbp), %r15
movq %r15, %rdi
callq 0x2a1e0
movq 0x20(%rbx), %rsi
movq 0x30(%rbx), %rdx
movq 0x60(%rsi), %rcx
addq $0x18, %rsi
movq 0x198(%r13), %r8
movq %r13, %rdi
callq 0x517e0
movl %eax, %r14d
cmpq $0x0, 0x108(%r13)
jne 0x52afb
movq %r15, %rdi
callq 0x2a220
movq %r13, %rdi
movq %rbx, %rsi
movl $0x5, %edx
movl $0x3, %ecx
callq 0x4f65f
incq 0x178(%r13)
testb %r14b, %r14b
movl -0x30(%rbp), %r15d
je 0x52a3c
orb $0x1, 0x74(%rbx)
callq 0xa66da
movzwl (%rax), %eax
movw %ax, 0x76(%rbx)
movq -0x40(%rbp), %r14
cmpl $0x0, (%r14)
jne 0x52a4a
callq 0xa66da
cmpl $0x0, (%rax)
je 0x52a42
callq 0xa66da
movl (%rax), %eax
jmp 0x52a47
movq -0x40(%rbp), %r14
jmp 0x52a4e
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
movl %eax, (%r14)
orl $0x1, %r15d
cmpq $0x0, 0x50(%rbx)
je 0x52a5e
leaq 0x50(%rbx), %rdi
callq 0xab8db
movl -0x2c(%rbp), %eax
cmpl $0x4, %eax
ja 0x52aab
movl $0x19, %ecx
btl %eax, %ecx
jae 0x52aab
andb $-0x11, 0x74(%rbx)
movq %r13, %rdi
movq %rbx, %rsi
movq -0x38(%rbp), %rdx
movl $0x1, %ecx
callq 0x5255a
movq %r13, %rdi
movq %rbx, %rsi
movl $0x1, %edx
callq 0x4f7cf
movl -0x2c(%rbp), %eax
addq $0x8, %r12
cmpq -0x48(%rbp), %r12
jne 0x5293a
jmp 0x52b17
movq %r13, %rdi
movq %rbx, %rsi
movl $0x1, %edx
callq 0x52381
testb %al, %al
je 0x52ad9
andb $-0x11, 0x74(%rbx)
movq %r13, %rdi
movq %rbx, %rsi
movq -0x38(%rbp), %rdx
movl $0x1, %ecx
callq 0x5255a
jmp 0x52a98
decq 0x58(%r13)
decq 0x168(%r13)
jmp 0x52a98
leaq 0x33b6db(%rip), %rax # 0x38e1c8
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x529a6
movq %r15, %rdi
leaq 0x8e51b(%rip), %rsi # 0xe1020
movl $0x12dd, %edx # imm = 0x12DD
callq 0x2fc0f
jmp 0x529ea
xorl %r15d, %r15d
movl %r15d, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x33b698(%rip), %rax # 0x38e1c8
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x528ee
leaq 0x8e4db(%rip), %rsi # 0xe1020
movq %r15, %rdi
movl $0x12a3, %edx # imm = 0x12A3
callq 0x2fc0f
jmp 0x52922
| flush_cached_blocks:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r14, r9
mov [rbp+var_2C], r8d
mov r12, rdx
mov [rbp+var_38], rsi
mov r13, rdi
mov [rbp+var_48], rcx
mov rbx, rcx
sub rbx, rdx
shr rbx, 3
mov dword ptr [r9], 0
lea r15, [rdi+0C8h]
mov rdi, [rdi+108h]
test rdi, rdi
jnz loc_52B29
loc_528EE:
mov rdi, r15
call _pthread_mutex_unlock
mov esi, ebx
lea rcx, cmp_sec_link
mov edx, 8
mov rdi, r12
call _qsort
cmp qword ptr [r13+108h], 0
jnz loc_52B3E
mov rdi, r15
call _pthread_mutex_lock
loc_52922:
cmp r12, [rbp+var_48]
mov eax, [rbp+var_2C]
jz loc_52B14
mov [rbp+var_50], r15
xor r15d, r15d
mov [rbp+var_40], r14
loc_5293A:
mov rbx, [r12]
cmp eax, 4
jnz short loc_52949
cmp dword ptr [rbx+64h], 0
jnz short loc_5294F
loc_52949:
cmp dword ptr [rbx+68h], 0
jz short loc_5297D
loc_5294F:
and byte ptr [rbx+74h], 0EFh
or r15d, 2
mov rdi, r13
mov rsi, rbx
mov edx, 1
call unreg_request
cmp dword ptr [r14], 0
jnz loc_52A98
mov dword ptr [r14], 7Ah ; 'z'
jmp loc_52A98
loc_5297D:
mov [rbp+var_30], r15d
mov rdi, r13
mov rsi, rbx
mov edx, 3
mov ecx, 2
call make_lock_and_pin
mov rdi, [r13+108h]
test rdi, rdi
jnz loc_52AE6
loc_529A6:
mov r15, [rbp+var_50]
mov rdi, r15
call _pthread_mutex_unlock
mov rsi, [rbx+20h]
mov rdx, [rbx+30h]
mov rcx, [rsi+60h]
add rsi, 18h
mov r8, [r13+198h]
mov rdi, r13
call pagecache_fwrite
mov r14d, eax
cmp qword ptr [r13+108h], 0
jnz loc_52AFB
mov rdi, r15
call _pthread_mutex_lock
loc_529EA:
mov rdi, r13
mov rsi, rbx
mov edx, 5
mov ecx, 3
call make_lock_and_pin
inc qword ptr [r13+178h]
test r14b, r14b
mov r15d, [rbp+var_30]
jz short loc_52A3C
or byte ptr [rbx+74h], 1
call _my_thread_var
movzx eax, word ptr [rax]
mov [rbx+76h], ax
mov r14, [rbp+var_40]
cmp dword ptr [r14], 0
jnz short loc_52A4A
call _my_thread_var
cmp dword ptr [rax], 0
jz short loc_52A42
call _my_thread_var
mov eax, [rax]
jmp short loc_52A47
loc_52A3C:
mov r14, [rbp+var_40]
jmp short loc_52A4E
loc_52A42:
mov eax, 0FFFFFFFFh
loc_52A47:
mov [r14], eax
loc_52A4A:
or r15d, 1
loc_52A4E:
cmp qword ptr [rbx+50h], 0
jz short loc_52A5E
lea rdi, [rbx+50h]
call wqueue_release_queue
loc_52A5E:
mov eax, [rbp+var_2C]
cmp eax, 4
ja short loc_52AAB
mov ecx, 19h
bt ecx, eax
jnb short loc_52AAB
and byte ptr [rbx+74h], 0EFh
mov rdi, r13
mov rsi, rbx
mov rdx, [rbp+var_38]
mov ecx, 1
call link_to_file_list
mov rdi, r13
mov rsi, rbx
mov edx, 1
call unreg_request
loc_52A98:
mov eax, [rbp+var_2C]
add r12, 8
cmp r12, [rbp+var_48]
jnz loc_5293A
jmp short loc_52B17
loc_52AAB:
mov rdi, r13
mov rsi, rbx
mov edx, 1
call free_block
test al, al
jz short loc_52AD9
and byte ptr [rbx+74h], 0EFh
mov rdi, r13
mov rsi, rbx
mov rdx, [rbp+var_38]
mov ecx, 1
call link_to_file_list
jmp short loc_52A98
loc_52AD9:
dec qword ptr [r13+58h]
dec qword ptr [r13+168h]
jmp short loc_52A98
loc_52AE6:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp loc_529A6
loc_52AFB:
mov rdi, r15
lea rsi, aWorkspaceLlm4b_29; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 12DDh
call psi_mutex_lock
jmp loc_529EA
loc_52B14:
xor r15d, r15d
loc_52B17:
mov eax, r15d
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_52B29:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp loc_528EE
loc_52B3E:
lea rsi, aWorkspaceLlm4b_29; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, r15
mov edx, 12A3h
call psi_mutex_lock
jmp loc_52922
| long long flush_cached_blocks(_QWORD *a1, long long a2, long long *a3, long long *a4, unsigned int a5, int *a6)
{
int *v6; // r14
long long *v7; // r12
unsigned long long v8; // rbx
long long v9; // r15
unsigned int v10; // eax
unsigned int v11; // r15d
long long v12; // rbx
char v13; // r14
int v14; // eax
int v15; // ecx
long long v17; // [rsp+0h] [rbp-50h]
int *v19; // [rsp+10h] [rbp-40h]
v6 = a6;
v7 = a3;
v8 = (unsigned long long)((char *)a4 - (char *)a3) >> 3;
*a6 = 0;
v9 = (long long)(a1 + 25);
if ( a1[33] )
PSI_server[44]();
pthread_mutex_unlock(v9);
qsort(v7, (unsigned int)v8, 8LL, cmp_sec_link);
if ( a1[33] )
psi_mutex_lock(v9, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c", 0x12A3u);
else
pthread_mutex_lock(v9);
v10 = a5;
if ( v7 == a4 )
{
return 0;
}
else
{
v17 = (long long)(a1 + 25);
v11 = 0;
v19 = v6;
do
{
v12 = *v7;
if ( v10 == 4 && *(_DWORD *)(v12 + 100) || *(_DWORD *)(v12 + 104) )
{
*(_BYTE *)(v12 + 116) &= ~0x10u;
v11 |= 2u;
unreg_request(a1, v12, 1);
if ( !*v6 )
*v6 = 122;
}
else
{
make_lock_and_pin((long long)a1, v12, 3, 2);
if ( a1[33] )
PSI_server[44]();
pthread_mutex_unlock(v17);
v13 = pagecache_fwrite(
(long long)a1,
*(_QWORD *)(v12 + 32) + 24LL,
*(_QWORD *)(v12 + 48),
*(_QWORD *)(*(_QWORD *)(v12 + 32) + 96LL),
a1[51]);
if ( a1[33] )
psi_mutex_lock(v17, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c", 0x12DDu);
else
pthread_mutex_lock(v17);
make_lock_and_pin((long long)a1, v12, 5, 3);
++a1[47];
if ( v13 )
{
*(_BYTE *)(v12 + 116) |= 1u;
*(_WORD *)(v12 + 118) = *(_WORD *)my_thread_var(a1);
v6 = v19;
if ( !*v19 )
{
if ( *(_DWORD *)my_thread_var(a1) )
v14 = *(_DWORD *)my_thread_var(a1);
else
v14 = -1;
*v19 = v14;
}
v11 |= 1u;
}
else
{
v6 = v19;
}
if ( *(_QWORD *)(v12 + 80) )
wqueue_release_queue(v12 + 80);
if ( a5 <= 4 && (v15 = 25, _bittest(&v15, a5)) )
{
*(_BYTE *)(v12 + 116) &= ~0x10u;
link_to_file_list((long long)a1, v12, a2, 1);
unreg_request(a1, v12, 1);
}
else if ( (unsigned __int8)free_block(a1, v12, 1) )
{
*(_BYTE *)(v12 + 116) &= ~0x10u;
link_to_file_list((long long)a1, v12, a2, 1);
}
else
{
--a1[11];
--a1[45];
}
}
v10 = a5;
++v7;
}
while ( v7 != a4 );
}
return v11;
}
| flush_cached_blocks:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R14,R9
MOV dword ptr [RBP + -0x2c],R8D
MOV R12,RDX
MOV qword ptr [RBP + -0x38],RSI
MOV R13,RDI
MOV qword ptr [RBP + -0x48],RCX
MOV RBX,RCX
SUB RBX,RDX
SHR RBX,0x3
MOV dword ptr [R9],0x0
LEA R15,[RDI + 0xc8]
MOV RDI,qword ptr [RDI + 0x108]
TEST RDI,RDI
JNZ 0x00152b29
LAB_001528ee:
MOV RDI,R15
CALL 0x0012a1e0
MOV ESI,EBX
LEA RCX,[0x152b57]
MOV EDX,0x8
MOV RDI,R12
CALL 0x0012a610
CMP qword ptr [R13 + 0x108],0x0
JNZ 0x00152b3e
MOV RDI,R15
CALL 0x0012a220
LAB_00152922:
CMP R12,qword ptr [RBP + -0x48]
MOV EAX,dword ptr [RBP + -0x2c]
JZ 0x00152b14
MOV qword ptr [RBP + -0x50],R15
XOR R15D,R15D
MOV qword ptr [RBP + -0x40],R14
LAB_0015293a:
MOV RBX,qword ptr [R12]
CMP EAX,0x4
JNZ 0x00152949
CMP dword ptr [RBX + 0x64],0x0
JNZ 0x0015294f
LAB_00152949:
CMP dword ptr [RBX + 0x68],0x0
JZ 0x0015297d
LAB_0015294f:
AND byte ptr [RBX + 0x74],0xef
OR R15D,0x2
MOV RDI,R13
MOV RSI,RBX
MOV EDX,0x1
CALL 0x0014f7cf
CMP dword ptr [R14],0x0
JNZ 0x00152a98
MOV dword ptr [R14],0x7a
JMP 0x00152a98
LAB_0015297d:
MOV dword ptr [RBP + -0x30],R15D
MOV RDI,R13
MOV RSI,RBX
MOV EDX,0x3
MOV ECX,0x2
CALL 0x0014f65f
MOV RDI,qword ptr [R13 + 0x108]
TEST RDI,RDI
JNZ 0x00152ae6
LAB_001529a6:
MOV R15,qword ptr [RBP + -0x50]
MOV RDI,R15
CALL 0x0012a1e0
MOV RSI,qword ptr [RBX + 0x20]
MOV RDX,qword ptr [RBX + 0x30]
MOV RCX,qword ptr [RSI + 0x60]
ADD RSI,0x18
MOV R8,qword ptr [R13 + 0x198]
MOV RDI,R13
CALL 0x001517e0
MOV R14D,EAX
CMP qword ptr [R13 + 0x108],0x0
JNZ 0x00152afb
MOV RDI,R15
CALL 0x0012a220
LAB_001529ea:
MOV RDI,R13
MOV RSI,RBX
MOV EDX,0x5
MOV ECX,0x3
CALL 0x0014f65f
INC qword ptr [R13 + 0x178]
TEST R14B,R14B
MOV R15D,dword ptr [RBP + -0x30]
JZ 0x00152a3c
OR byte ptr [RBX + 0x74],0x1
CALL 0x001a66da
MOVZX EAX,word ptr [RAX]
MOV word ptr [RBX + 0x76],AX
MOV R14,qword ptr [RBP + -0x40]
CMP dword ptr [R14],0x0
JNZ 0x00152a4a
CALL 0x001a66da
CMP dword ptr [RAX],0x0
JZ 0x00152a42
CALL 0x001a66da
MOV EAX,dword ptr [RAX]
JMP 0x00152a47
LAB_00152a3c:
MOV R14,qword ptr [RBP + -0x40]
JMP 0x00152a4e
LAB_00152a42:
MOV EAX,0xffffffff
LAB_00152a47:
MOV dword ptr [R14],EAX
LAB_00152a4a:
OR R15D,0x1
LAB_00152a4e:
CMP qword ptr [RBX + 0x50],0x0
JZ 0x00152a5e
LEA RDI,[RBX + 0x50]
CALL 0x001ab8db
LAB_00152a5e:
MOV EAX,dword ptr [RBP + -0x2c]
CMP EAX,0x4
JA 0x00152aab
MOV ECX,0x19
BT ECX,EAX
JNC 0x00152aab
AND byte ptr [RBX + 0x74],0xef
MOV RDI,R13
MOV RSI,RBX
MOV RDX,qword ptr [RBP + -0x38]
MOV ECX,0x1
CALL 0x0015255a
MOV RDI,R13
MOV RSI,RBX
MOV EDX,0x1
CALL 0x0014f7cf
LAB_00152a98:
MOV EAX,dword ptr [RBP + -0x2c]
ADD R12,0x8
CMP R12,qword ptr [RBP + -0x48]
JNZ 0x0015293a
JMP 0x00152b17
LAB_00152aab:
MOV RDI,R13
MOV RSI,RBX
MOV EDX,0x1
CALL 0x00152381
TEST AL,AL
JZ 0x00152ad9
AND byte ptr [RBX + 0x74],0xef
MOV RDI,R13
MOV RSI,RBX
MOV RDX,qword ptr [RBP + -0x38]
MOV ECX,0x1
CALL 0x0015255a
JMP 0x00152a98
LAB_00152ad9:
DEC qword ptr [R13 + 0x58]
DEC qword ptr [R13 + 0x168]
JMP 0x00152a98
LAB_00152ae6:
LEA RAX,[0x48e1c8]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x001529a6
LAB_00152afb:
MOV RDI,R15
LEA RSI,[0x1e1020]
MOV EDX,0x12dd
CALL 0x0012fc0f
JMP 0x001529ea
LAB_00152b14:
XOR R15D,R15D
LAB_00152b17:
MOV EAX,R15D
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00152b29:
LEA RAX,[0x48e1c8]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x001528ee
LAB_00152b3e:
LEA RSI,[0x1e1020]
MOV RDI,R15
MOV EDX,0x12a3
CALL 0x0012fc0f
JMP 0x00152922
|
uint flush_cached_blocks(long param_1,int8 param_2,long *param_3,long *param_4,uint param_5,
int *param_6)
{
pthread_mutex_t *__mutex;
long lVar1;
char cVar2;
int iVar3;
int2 *puVar4;
int *piVar5;
uint uVar6;
*param_6 = 0;
__mutex = (pthread_mutex_t *)(param_1 + 200);
if (*(long *)(param_1 + 0x108) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
qsort(param_3,(ulong)((long)param_4 - (long)param_3) >> 3 & 0xffffffff,8,cmp_sec_link);
if (*(long *)(param_1 + 0x108) == 0) {
pthread_mutex_lock(__mutex);
}
else {
psi_mutex_lock(__mutex,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c",
0x12a3);
}
if (param_3 == param_4) {
uVar6 = 0;
}
else {
uVar6 = 0;
do {
lVar1 = *param_3;
if (((param_5 == 4) && (*(int *)(lVar1 + 100) != 0)) || (*(int *)(lVar1 + 0x68) != 0)) {
*(byte *)(lVar1 + 0x74) = *(byte *)(lVar1 + 0x74) & 0xef;
uVar6 = uVar6 | 2;
unreg_request(param_1,lVar1,1);
if (*param_6 == 0) {
*param_6 = 0x7a;
}
}
else {
make_lock_and_pin(param_1,lVar1,3,2);
if (*(long *)(param_1 + 0x108) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
cVar2 = pagecache_fwrite(param_1,*(long *)(lVar1 + 0x20) + 0x18,
*(int8 *)(lVar1 + 0x30),
*(int8 *)(*(long *)(lVar1 + 0x20) + 0x60),
*(int8 *)(param_1 + 0x198));
if (*(long *)(param_1 + 0x108) == 0) {
pthread_mutex_lock(__mutex);
}
else {
psi_mutex_lock(__mutex,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c",
0x12dd);
}
make_lock_and_pin(param_1,lVar1,5,3);
*(long *)(param_1 + 0x178) = *(long *)(param_1 + 0x178) + 1;
if (cVar2 != '\0') {
*(byte *)(lVar1 + 0x74) = *(byte *)(lVar1 + 0x74) | 1;
puVar4 = (int2 *)_my_thread_var();
*(int2 *)(lVar1 + 0x76) = *puVar4;
if (*param_6 == 0) {
piVar5 = (int *)_my_thread_var();
if (*piVar5 == 0) {
iVar3 = -1;
}
else {
piVar5 = (int *)_my_thread_var();
iVar3 = *piVar5;
}
*param_6 = iVar3;
}
uVar6 = uVar6 | 1;
}
if (*(long *)(lVar1 + 0x50) != 0) {
wqueue_release_queue(lVar1 + 0x50);
}
if ((param_5 < 5) && ((0x19U >> (param_5 & 0x1f) & 1) != 0)) {
*(byte *)(lVar1 + 0x74) = *(byte *)(lVar1 + 0x74) & 0xef;
link_to_file_list(param_1,lVar1,param_2,1);
unreg_request(param_1,lVar1,1);
}
else {
cVar2 = free_block(param_1,lVar1,1);
if (cVar2 == '\0') {
*(long *)(param_1 + 0x58) = *(long *)(param_1 + 0x58) + -1;
*(long *)(param_1 + 0x168) = *(long *)(param_1 + 0x168) + -1;
}
else {
*(byte *)(lVar1 + 0x74) = *(byte *)(lVar1 + 0x74) & 0xef;
link_to_file_list(param_1,lVar1,param_2,1);
}
}
}
param_3 = param_3 + 1;
} while (param_3 != param_4);
}
return uVar6;
}
| |
23,308 | minja::error_location_suffix(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long) | monkey531[P]llama/common/minja.hpp | static std::string error_location_suffix(const std::string & source, size_t pos) {
auto get_line = [&](size_t line) {
auto start = source.begin();
for (size_t i = 1; i < line; ++i) {
start = std::find(start, source.end(), '\n') + 1;
}
auto end = std::find(start, source.end(), '\n');
return std::string(start, end);
};
auto start = source.begin();
auto end = source.end();
auto it = start + pos;
auto line = std::count(start, it, '\n') + 1;
auto max_line = std::count(start, end, '\n') + 1;
auto col = pos - std::string(start, it).rfind('\n');
std::ostringstream out;
out << " at row " << line << ", column " << col << ":\n";
if (line > 1) out << get_line(line - 1) << "\n";
out << get_line(line) << "\n";
out << std::string(col - 1, ' ') << "^\n";
if (line < max_line) out << get_line(line + 1) << "\n";
return out.str();
} | O0 | cpp | minja::error_location_suffix(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long):
subq $0x358, %rsp # imm = 0x358
movq %rdi, 0x70(%rsp)
movq %rdi, %rax
movq %rax, 0x78(%rsp)
movq %rdi, 0x350(%rsp)
movq %rsi, 0x348(%rsp)
movq %rdx, 0x340(%rsp)
movq 0x348(%rsp), %rax
movq %rax, 0x338(%rsp)
movq 0x348(%rsp), %rdi
callq 0x522f0
movq %rax, 0x330(%rsp)
movq 0x348(%rsp), %rdi
callq 0x52f20
movq %rax, 0x328(%rsp)
movq 0x340(%rsp), %rsi
leaq 0x330(%rsp), %rdi
callq 0x88760
movq %rax, 0x320(%rsp)
movq 0x330(%rsp), %rax
movq %rax, 0x310(%rsp)
movq 0x320(%rsp), %rax
movq %rax, 0x308(%rsp)
movb $0xa, 0x307(%rsp)
movq 0x310(%rsp), %rdi
movq 0x308(%rsp), %rsi
leaq 0x307(%rsp), %rdx
callq 0x102770
incq %rax
movq %rax, 0x318(%rsp)
movq 0x330(%rsp), %rax
movq %rax, 0x2f0(%rsp)
movq 0x328(%rsp), %rax
movq %rax, 0x2e8(%rsp)
movb $0xa, 0x2e7(%rsp)
movq 0x2f0(%rsp), %rdi
movq 0x2e8(%rsp), %rsi
leaq 0x2e7(%rsp), %rdx
callq 0x102770
incq %rax
movq %rax, 0x2f8(%rsp)
movq 0x340(%rsp), %rax
movq %rax, 0x80(%rsp)
movq 0x330(%rsp), %rax
movq %rax, 0x2b0(%rsp)
movq 0x320(%rsp), %rax
movq %rax, 0x2a8(%rsp)
leaq 0x2a7(%rsp), %rdi
movq %rdi, 0x88(%rsp)
callq 0x52de0
movq 0x88(%rsp), %rcx
movq 0x2b0(%rsp), %rsi
movq 0x2a8(%rsp), %rdx
leaq 0x2b8(%rsp), %rdi
callq 0x887f0
jmp 0x6de7f
leaq 0x2b8(%rsp), %rdi
movq %rdi, 0x50(%rsp)
movl $0xa, %esi
movq $-0x1, %rdx
callq 0x52660
movq 0x50(%rsp), %rdi
movq %rax, %rcx
movq 0x80(%rsp), %rax
subq %rcx, %rax
movq %rax, 0x58(%rsp)
callq 0x53180
leaq 0x2a7(%rsp), %rdi
callq 0x53160
movq 0x58(%rsp), %rax
movq %rax, 0x2d8(%rsp)
leaq 0x118(%rsp), %rdi
movq %rdi, 0x60(%rsp)
callq 0x52db0
movq 0x60(%rsp), %rdi
leaq 0x15816b(%rip), %rsi # 0x1c605d
callq 0x528b0
movq %rax, 0x68(%rsp)
jmp 0x6defe
movq 0x68(%rsp), %rdi
movq 0x318(%rsp), %rsi
callq 0x52550
movq %rax, 0x48(%rsp)
jmp 0x6df17
movq 0x48(%rsp), %rdi
leaq 0x1576e3(%rip), %rsi # 0x1c5606
callq 0x528b0
movq %rax, 0x40(%rsp)
jmp 0x6df2f
movq 0x40(%rsp), %rdi
movq 0x2d8(%rsp), %rsi
callq 0x52ef0
movq %rax, 0x38(%rsp)
jmp 0x6df48
movq 0x38(%rsp), %rdi
leaq 0x160241(%rip), %rsi # 0x1ce195
callq 0x528b0
jmp 0x6df5b
cmpq $0x1, 0x318(%rsp)
jle 0x6e02f
movq 0x318(%rsp), %rdx
decq %rdx
leaq 0xf8(%rsp), %rdi
leaq 0x338(%rsp), %rsi
callq 0x6e350
jmp 0x6df8c
leaq 0x118(%rsp), %rdi
leaq 0xf8(%rsp), %rsi
callq 0x52440
movq %rax, 0x30(%rsp)
jmp 0x6dfa8
movq 0x30(%rsp), %rdi
leaq 0x152816(%rip), %rsi # 0x1c07ca
callq 0x528b0
jmp 0x6dfbb
leaq 0xf8(%rsp), %rdi
callq 0x53180
jmp 0x6e02f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
leaq 0x2a7(%rsp), %rdi
callq 0x53160
jmp 0x6e256
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
jmp 0x6e249
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
leaq 0xf8(%rsp), %rdi
callq 0x53180
jmp 0x6e249
movq 0x318(%rsp), %rdx
leaq 0xd8(%rsp), %rdi
leaq 0x338(%rsp), %rsi
callq 0x6e350
jmp 0x6e04e
leaq 0x118(%rsp), %rdi
leaq 0xd8(%rsp), %rsi
callq 0x52440
movq %rax, 0x28(%rsp)
jmp 0x6e06a
movq 0x28(%rsp), %rdi
leaq 0x152754(%rip), %rsi # 0x1c07ca
callq 0x528b0
jmp 0x6e07d
leaq 0xd8(%rsp), %rdi
callq 0x53180
movq 0x2d8(%rsp), %rax
decq %rax
movq %rax, 0x18(%rsp)
leaq 0xb7(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0x52de0
movq 0x18(%rsp), %rsi
movq 0x20(%rsp), %rcx
leaq 0xb8(%rsp), %rdi
movl $0x20, %edx
callq 0x7ba90
jmp 0x6e0ca
leaq 0x118(%rsp), %rdi
leaq 0xb8(%rsp), %rsi
callq 0x52440
movq %rax, 0x10(%rsp)
jmp 0x6e0e6
movq 0x10(%rsp), %rdi
leaq 0x157f74(%rip), %rsi # 0x1c6066
callq 0x528b0
jmp 0x6e0f9
leaq 0xb8(%rsp), %rdi
callq 0x53180
leaq 0xb7(%rsp), %rdi
callq 0x53160
movq 0x318(%rsp), %rax
cmpq 0x2f8(%rsp), %rax
jge 0x6e21b
movq 0x318(%rsp), %rdx
incq %rdx
leaq 0x90(%rsp), %rdi
leaq 0x338(%rsp), %rsi
callq 0x6e350
jmp 0x6e14b
leaq 0x118(%rsp), %rdi
leaq 0x90(%rsp), %rsi
callq 0x52440
movq %rax, 0x8(%rsp)
jmp 0x6e167
movq 0x8(%rsp), %rdi
leaq 0x152657(%rip), %rsi # 0x1c07ca
callq 0x528b0
jmp 0x6e17a
leaq 0x90(%rsp), %rdi
callq 0x53180
jmp 0x6e21b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
leaq 0xd8(%rsp), %rdi
callq 0x53180
jmp 0x6e249
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
jmp 0x6e1e9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
leaq 0xb8(%rsp), %rdi
callq 0x53180
leaq 0xb7(%rsp), %rdi
callq 0x53160
jmp 0x6e249
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x298(%rsp)
movl %eax, 0x294(%rsp)
leaq 0x90(%rsp), %rdi
callq 0x53180
jmp 0x6e249
movq 0x70(%rsp), %rdi
leaq 0x118(%rsp), %rsi
callq 0x530c0
jmp 0x6e22f
leaq 0x118(%rsp), %rdi
callq 0x52cf0
movq 0x78(%rsp), %rax
addq $0x358, %rsp # imm = 0x358
retq
leaq 0x118(%rsp), %rdi
callq 0x52cf0
movq 0x298(%rsp), %rdi
callq 0x529b0
nopw %cs:(%rax,%rax)
| _ZN5minjaL21error_location_suffixERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEm:
sub rsp, 358h
mov [rsp+358h+var_2E8], rdi
mov rax, rdi
mov [rsp+358h+var_2E0], rax
mov [rsp+358h+var_8], rdi
mov [rsp+358h+var_10], rsi
mov [rsp+358h+var_18], rdx
mov rax, [rsp+358h+var_10]
mov [rsp+358h+var_20], rax
mov rdi, [rsp+358h+var_10]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5beginEv; std::string::begin(void)
mov [rsp+358h+var_28], rax
mov rdi, [rsp+358h+var_10]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE3endEv; std::string::end(void)
mov [rsp+358h+var_30], rax
mov rsi, [rsp+358h+var_18]
lea rdi, [rsp+358h+var_28]
call _ZNK9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEplEl; __gnu_cxx::__normal_iterator<char const*,std::string>::operator+(long)
mov [rsp+358h+var_38], rax
mov rax, [rsp+358h+var_28]
mov [rsp+358h+var_48], rax
mov rax, [rsp+358h+var_38]
mov [rsp+358h+var_50], rax
mov [rsp+358h+var_51], 0Ah
mov rdi, [rsp+358h+var_48]
mov rsi, [rsp+358h+var_50]
lea rdx, [rsp+358h+var_51]
call _ZSt5countIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEcENSt15iterator_traitsIT_E15difference_typeESC_SC_RKT0_; std::count<__gnu_cxx::__normal_iterator<char const*,std::string>,char>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,char const&)
inc rax
mov [rsp+358h+var_40], rax
mov rax, [rsp+358h+var_28]
mov [rsp+358h+var_68], rax
mov rax, [rsp+358h+var_30]
mov [rsp+358h+var_70], rax
mov [rsp+358h+var_71], 0Ah
mov rdi, [rsp+358h+var_68]
mov rsi, [rsp+358h+var_70]
lea rdx, [rsp+358h+var_71]
call _ZSt5countIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEcENSt15iterator_traitsIT_E15difference_typeESC_SC_RKT0_; std::count<__gnu_cxx::__normal_iterator<char const*,std::string>,char>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,char const&)
inc rax
mov [rsp+358h+var_60], rax
mov rax, [rsp+358h+var_18]
mov [rsp+358h+var_2D8], rax
mov rax, [rsp+358h+var_28]
mov [rsp+358h+var_A8], rax
mov rax, [rsp+358h+var_38]
mov [rsp+358h+var_B0], rax
lea rdi, [rsp+358h+var_B1]
mov [rsp+358h+var_2D0], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rcx, [rsp+358h+var_2D0]
mov rsi, [rsp+358h+var_A8]
mov rdx, [rsp+358h+var_B0]
lea rdi, [rsp+358h+var_A0]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IN9__gnu_cxx17__normal_iteratorIPKcS4_EEvEET_SB_RKS3_; std::string::basic_string<__gnu_cxx::__normal_iterator<char const*,std::string>,void>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::allocator<char> const&)
jmp short $+2
loc_6DE7F:
lea rdi, [rsp+358h+var_A0]
mov [rsp+358h+var_308], rdi
mov esi, 0Ah
mov rdx, 0FFFFFFFFFFFFFFFFh
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5rfindEcm; std::string::rfind(char,ulong)
mov rdi, [rsp+358h+var_308]; void *
mov rcx, rax
mov rax, [rsp+358h+var_2D8]
sub rax, rcx
mov [rsp+358h+var_300], rax
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+358h+var_B1]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rax, [rsp+358h+var_300]
mov [rsp+358h+var_80], rax
lea rdi, [rsp+358h+var_240]
mov [rsp+358h+var_2F8], rdi
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::ostringstream::basic_ostringstream(void)
mov rdi, [rsp+358h+var_2F8]
lea rsi, aAtRow; " at row "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rsp+358h+var_2F0], rax
jmp short $+2
loc_6DEFE:
mov rdi, [rsp+358h+var_2F0]
mov rsi, [rsp+358h+var_40]
call __ZNSolsEl; std::ostream::operator<<(long)
mov [rsp+358h+var_310], rax
jmp short $+2
loc_6DF17:
mov rdi, [rsp+358h+var_310]
lea rsi, aColumn; ", column "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rsp+358h+var_318], rax
jmp short $+2
loc_6DF2F:
mov rdi, [rsp+358h+var_318]
mov rsi, [rsp+358h+var_80]
call __ZNSolsEm; std::ostream::operator<<(ulong)
mov [rsp+358h+var_320], rax
jmp short $+2
loc_6DF48:
mov rdi, [rsp+358h+var_320]
lea rsi, aJsonSchemaConv+1Dh; ":\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_6DF5B:
cmp [rsp+358h+var_40], 1
jle loc_6E02F
mov rdx, [rsp+358h+var_40]
dec rdx
lea rdi, [rsp+358h+var_260]
lea rsi, [rsp+358h+var_20]
call _ZZN5minjaL21error_location_suffixERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEmENK3$_0clB5cxx11Em; minja::error_location_suffix(std::string const&,ulong)::$_0::operator()(ulong)
jmp short $+2
loc_6DF8C:
lea rdi, [rsp+358h+var_240]
lea rsi, [rsp+358h+var_260]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rsp+358h+var_328], rax
jmp short $+2
loc_6DFA8:
mov rdi, [rsp+358h+var_328]
lea rsi, asc_1C075E+6Ch; "\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_6DFBB:
lea rdi, [rsp+358h+var_260]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_6E02F
mov rcx, rax
mov eax, edx
mov [rsp+arg_290], rcx
mov [rsp+arg_28C], eax
lea rdi, [rsp+arg_29F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_6E256
mov rcx, rax
mov eax, edx
mov [rsp+arg_290], rcx
mov [rsp+arg_28C], eax
jmp loc_6E249
mov rcx, rax
mov eax, edx
mov [rsp+arg_290], rcx
mov [rsp+arg_28C], eax
lea rdi, [rsp+arg_F0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_6E249
loc_6E02F:
mov rdx, [rsp+358h+var_40]
lea rdi, [rsp+358h+var_280]
lea rsi, [rsp+358h+var_20]
call _ZZN5minjaL21error_location_suffixERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEmENK3$_0clB5cxx11Em; minja::error_location_suffix(std::string const&,ulong)::$_0::operator()(ulong)
jmp short $+2
loc_6E04E:
lea rdi, [rsp+358h+var_240]
lea rsi, [rsp+358h+var_280]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rsp+358h+var_330], rax
jmp short $+2
loc_6E06A:
mov rdi, [rsp+358h+var_330]
lea rsi, asc_1C075E+6Ch; "\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_6E07D:
lea rdi, [rsp+358h+var_280]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rax, [rsp+358h+var_80]
dec rax
mov [rsp+358h+var_340], rax
lea rdi, [rsp+358h+var_2A1]
mov [rsp+358h+var_338], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rsi, [rsp+358h+var_340]
mov rcx, [rsp+358h+var_338]
lea rdi, [rsp+358h+var_2A0]
mov edx, 20h ; ' '
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEmcRKS3_; std::string::basic_string<std::allocator<char>>(ulong,char,std::allocator<char> const&)
jmp short $+2
loc_6E0CA:
lea rdi, [rsp+358h+var_240]
lea rsi, [rsp+358h+var_2A0]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rsp+358h+var_348], rax
jmp short $+2
loc_6E0E6:
mov rdi, [rsp+358h+var_348]
lea rsi, asc_1C6066; "^\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_6E0F9:
lea rdi, [rsp+358h+var_2A0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+358h+var_2A1]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rax, [rsp+358h+var_40]
cmp rax, [rsp+358h+var_60]
jge loc_6E21B
mov rdx, [rsp+358h+var_40]
inc rdx
lea rdi, [rsp+358h+var_2C8]
lea rsi, [rsp+358h+var_20]
call _ZZN5minjaL21error_location_suffixERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEmENK3$_0clB5cxx11Em; minja::error_location_suffix(std::string const&,ulong)::$_0::operator()(ulong)
jmp short $+2
loc_6E14B:
lea rdi, [rsp+358h+var_240]
lea rsi, [rsp+358h+var_2C8]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rsp+358h+var_350], rax
jmp short $+2
loc_6E167:
mov rdi, [rsp+358h+var_350]
lea rsi, asc_1C075E+6Ch; "\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_6E17A:
lea rdi, [rsp+358h+var_2C8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_6E21B
mov rcx, rax
mov eax, edx
mov [rsp+arg_290], rcx
mov [rsp+arg_28C], eax
lea rdi, [rsp+arg_D0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_6E249
mov rcx, rax
mov eax, edx
mov [rsp+arg_290], rcx
mov [rsp+arg_28C], eax
jmp short loc_6E1E9
mov rcx, rax
mov eax, edx
mov [rsp+arg_290], rcx
mov [rsp+arg_28C], eax
lea rdi, [rsp+arg_B0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_6E1E9:
lea rdi, [rsp+arg_AF]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_6E249
mov rcx, rax
mov eax, edx
mov [rsp+arg_290], rcx
mov [rsp+arg_28C], eax
lea rdi, [rsp+arg_88]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_6E249
loc_6E21B:
mov rdi, [rsp+358h+var_2E8]
lea rsi, [rsp+358h+var_240]
call __ZNKSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEE3strEv; std::ostringstream::str(void)
jmp short $+2
loc_6E22F:
lea rdi, [rsp+358h+var_240]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED1Ev; std::ostringstream::~ostringstream()
mov rax, [rsp+358h+var_2E0]
add rsp, 358h
retn
loc_6E249:
lea rdi, [rsp+arg_110]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED1Ev; std::ostringstream::~ostringstream()
loc_6E256:
mov rdi, [rsp+arg_290]
call __Unwind_Resume
| long long minja::error_location_suffix(long long a1, long long a2, long long a3)
{
int v3; // r8d
int v4; // r9d
int v5; // ecx
int v6; // r8d
int v7; // r9d
int v8; // r8d
int v9; // r9d
int v10; // ecx
int v11; // r8d
int v12; // r9d
int v14; // [rsp+0h] [rbp-358h]
int v15; // [rsp+0h] [rbp-358h]
int v16; // [rsp+0h] [rbp-358h]
int v17; // [rsp+8h] [rbp-350h]
long long v18; // [rsp+8h] [rbp-350h]
int v19; // [rsp+8h] [rbp-350h]
long long v20; // [rsp+8h] [rbp-350h]
long long v21; // [rsp+10h] [rbp-348h]
int v22; // [rsp+18h] [rbp-340h]
long long v23; // [rsp+28h] [rbp-330h]
long long v24; // [rsp+30h] [rbp-328h]
long long v25; // [rsp+38h] [rbp-320h]
long long v26; // [rsp+40h] [rbp-318h]
long long v27; // [rsp+48h] [rbp-310h]
long long v28; // [rsp+58h] [rbp-300h]
long long v29; // [rsp+68h] [rbp-2F0h]
long long v30; // [rsp+80h] [rbp-2D8h]
_BYTE v31[39]; // [rsp+90h] [rbp-2C8h] BYREF
char v32; // [rsp+B7h] [rbp-2A1h] BYREF
_BYTE v33[32]; // [rsp+B8h] [rbp-2A0h] BYREF
_BYTE v34[32]; // [rsp+D8h] [rbp-280h] BYREF
_BYTE v35[32]; // [rsp+F8h] [rbp-260h] BYREF
_BYTE v36[399]; // [rsp+118h] [rbp-240h] BYREF
char v37; // [rsp+2A7h] [rbp-B1h] BYREF
long long v38; // [rsp+2A8h] [rbp-B0h]
long long v39; // [rsp+2B0h] [rbp-A8h]
_BYTE v40[32]; // [rsp+2B8h] [rbp-A0h] BYREF
long long v41; // [rsp+2D8h] [rbp-80h]
char v42; // [rsp+2E7h] [rbp-71h] BYREF
long long v43; // [rsp+2E8h] [rbp-70h]
long long v44; // [rsp+2F0h] [rbp-68h]
long long v45; // [rsp+2F8h] [rbp-60h]
char v46; // [rsp+307h] [rbp-51h] BYREF
long long v47; // [rsp+308h] [rbp-50h]
long long v48; // [rsp+310h] [rbp-48h]
long long v49; // [rsp+318h] [rbp-40h]
long long v50; // [rsp+320h] [rbp-38h]
long long v51; // [rsp+328h] [rbp-30h]
long long v52; // [rsp+330h] [rbp-28h] BYREF
long long v53; // [rsp+338h] [rbp-20h] BYREF
long long v54; // [rsp+340h] [rbp-18h]
long long v55; // [rsp+348h] [rbp-10h]
long long v56; // [rsp+350h] [rbp-8h]
v56 = a1;
v55 = a2;
v54 = a3;
v53 = a2;
v52 = std::string::begin(a2);
v51 = std::string::end(a2);
v50 = __gnu_cxx::__normal_iterator<char const*,std::string>::operator+(&v52, v54);
v48 = v52;
v47 = v50;
v46 = 10;
v49 = std::count<__gnu_cxx::__normal_iterator<char const*,std::string>,char>(v52, v50, &v46) + 1;
v44 = v52;
v43 = v51;
v42 = 10;
v45 = std::count<__gnu_cxx::__normal_iterator<char const*,std::string>,char>(v52, v51, &v42) + 1;
v30 = v54;
v39 = v52;
v38 = v50;
std::allocator<char>::allocator();
std::string::basic_string<__gnu_cxx::__normal_iterator<char const*,std::string>,void>(
(unsigned int)v40,
v39,
v38,
(unsigned int)&v37,
v3,
v4);
v28 = v30 - std::string::rfind(v40, 10LL, -1LL);
std::string::~string(v40);
std::allocator<char>::~allocator(&v37);
v41 = v28;
std::ostringstream::basic_ostringstream(v36);
v29 = std::operator<<<std::char_traits<char>>(v36, " at row ");
v27 = std::ostream::operator<<(v29, v49);
v26 = std::operator<<<std::char_traits<char>>(v27, ", column ");
v25 = std::ostream::operator<<(v26, v41);
std::operator<<<std::char_traits<char>>(v25, ":\n");
if ( v49 > 1 )
{
minja::error_location_suffix(std::string const&,unsigned long)::$_0::operator()[abi:cxx11](
(unsigned int)v35,
(unsigned int)&v53,
v49 - 1,
v5,
v6,
v7,
v14,
v17);
v24 = std::operator<<<char>(v36, v35);
std::operator<<<std::char_traits<char>>(v24, "\n");
std::string::~string(v35);
}
minja::error_location_suffix(std::string const&,unsigned long)::$_0::operator()[abi:cxx11](
(unsigned int)v34,
(unsigned int)&v53,
v49,
v5,
v6,
v7,
v14,
v17);
v23 = std::operator<<<char>(v36, v34);
std::operator<<<std::char_traits<char>>(v23, "\n");
std::string::~string(v34);
v22 = v41 - 1;
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>((unsigned int)v33, v22, 32, (unsigned int)&v32, v8, v9, v15, v18);
v21 = std::operator<<<char>(v36, v33);
std::operator<<<std::char_traits<char>>(v21, "^\n");
std::string::~string(v33);
std::allocator<char>::~allocator(&v32);
if ( v49 < v45 )
{
minja::error_location_suffix(std::string const&,unsigned long)::$_0::operator()[abi:cxx11](
(unsigned int)v31,
(unsigned int)&v53,
v49 + 1,
v10,
v11,
v12,
v16,
v19);
v20 = std::operator<<<char>(v36, v31);
std::operator<<<std::char_traits<char>>(v20, "\n");
std::string::~string(v31);
}
std::ostringstream::str(a1, v36);
std::ostringstream::~ostringstream(v36);
return a1;
}
| error_location_suffix:
SUB RSP,0x358
MOV qword ptr [RSP + 0x70],RDI
MOV RAX,RDI
MOV qword ptr [RSP + 0x78],RAX
MOV qword ptr [RSP + 0x350],RDI
MOV qword ptr [RSP + 0x348],RSI
MOV qword ptr [RSP + 0x340],RDX
MOV RAX,qword ptr [RSP + 0x348]
MOV qword ptr [RSP + 0x338],RAX
MOV RDI,qword ptr [RSP + 0x348]
CALL 0x001522f0
MOV qword ptr [RSP + 0x330],RAX
MOV RDI,qword ptr [RSP + 0x348]
CALL 0x00152f20
MOV qword ptr [RSP + 0x328],RAX
MOV RSI,qword ptr [RSP + 0x340]
LEA RDI,[RSP + 0x330]
CALL 0x00188760
MOV qword ptr [RSP + 0x320],RAX
MOV RAX,qword ptr [RSP + 0x330]
MOV qword ptr [RSP + 0x310],RAX
MOV RAX,qword ptr [RSP + 0x320]
MOV qword ptr [RSP + 0x308],RAX
MOV byte ptr [RSP + 0x307],0xa
MOV RDI,qword ptr [RSP + 0x310]
MOV RSI,qword ptr [RSP + 0x308]
LEA RDX,[RSP + 0x307]
CALL 0x00202770
INC RAX
MOV qword ptr [RSP + 0x318],RAX
MOV RAX,qword ptr [RSP + 0x330]
MOV qword ptr [RSP + 0x2f0],RAX
MOV RAX,qword ptr [RSP + 0x328]
MOV qword ptr [RSP + 0x2e8],RAX
MOV byte ptr [RSP + 0x2e7],0xa
MOV RDI,qword ptr [RSP + 0x2f0]
MOV RSI,qword ptr [RSP + 0x2e8]
LEA RDX,[RSP + 0x2e7]
CALL 0x00202770
INC RAX
MOV qword ptr [RSP + 0x2f8],RAX
MOV RAX,qword ptr [RSP + 0x340]
MOV qword ptr [RSP + 0x80],RAX
MOV RAX,qword ptr [RSP + 0x330]
MOV qword ptr [RSP + 0x2b0],RAX
MOV RAX,qword ptr [RSP + 0x320]
MOV qword ptr [RSP + 0x2a8],RAX
LEA RDI,[RSP + 0x2a7]
MOV qword ptr [RSP + 0x88],RDI
CALL 0x00152de0
MOV RCX,qword ptr [RSP + 0x88]
MOV RSI,qword ptr [RSP + 0x2b0]
MOV RDX,qword ptr [RSP + 0x2a8]
LAB_0016de70:
LEA RDI,[RSP + 0x2b8]
CALL 0x001887f0
LAB_0016de7d:
JMP 0x0016de7f
LAB_0016de7f:
LEA RDI,[RSP + 0x2b8]
MOV qword ptr [RSP + 0x50],RDI
MOV ESI,0xa
MOV RDX,-0x1
CALL 0x00152660
MOV RDI,qword ptr [RSP + 0x50]
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x80]
SUB RAX,RCX
MOV qword ptr [RSP + 0x58],RAX
CALL 0x00153180
LEA RDI,[RSP + 0x2a7]
CALL 0x00153160
MOV RAX,qword ptr [RSP + 0x58]
MOV qword ptr [RSP + 0x2d8],RAX
LEA RDI,[RSP + 0x118]
MOV qword ptr [RSP + 0x60],RDI
CALL 0x00152db0
MOV RDI,qword ptr [RSP + 0x60]
LAB_0016deeb:
LEA RSI,[0x2c605d]
CALL 0x001528b0
MOV qword ptr [RSP + 0x68],RAX
JMP 0x0016defe
LAB_0016defe:
MOV RDI,qword ptr [RSP + 0x68]
MOV RSI,qword ptr [RSP + 0x318]
CALL 0x00152550
MOV qword ptr [RSP + 0x48],RAX
JMP 0x0016df17
LAB_0016df17:
MOV RDI,qword ptr [RSP + 0x48]
LEA RSI,[0x2c5606]
CALL 0x001528b0
MOV qword ptr [RSP + 0x40],RAX
JMP 0x0016df2f
LAB_0016df2f:
MOV RDI,qword ptr [RSP + 0x40]
MOV RSI,qword ptr [RSP + 0x2d8]
CALL 0x00152ef0
MOV qword ptr [RSP + 0x38],RAX
JMP 0x0016df48
LAB_0016df48:
MOV RDI,qword ptr [RSP + 0x38]
LEA RSI,[0x2ce195]
CALL 0x001528b0
JMP 0x0016df5b
LAB_0016df5b:
CMP qword ptr [RSP + 0x318],0x1
JLE 0x0016e02f
MOV RDX,qword ptr [RSP + 0x318]
DEC RDX
LEA RDI,[RSP + 0xf8]
LEA RSI,[RSP + 0x338]
CALL 0x0016e350
JMP 0x0016df8c
LAB_0016df8c:
LEA RDI,[RSP + 0x118]
LEA RSI,[RSP + 0xf8]
CALL 0x00152440
MOV qword ptr [RSP + 0x30],RAX
JMP 0x0016dfa8
LAB_0016dfa8:
MOV RDI,qword ptr [RSP + 0x30]
LEA RSI,[0x2c07ca]
CALL 0x001528b0
JMP 0x0016dfbb
LAB_0016dfbb:
LEA RDI,[RSP + 0xf8]
CALL 0x00153180
JMP 0x0016e02f
LAB_0016e02f:
MOV RDX,qword ptr [RSP + 0x318]
LAB_0016e037:
LEA RDI,[RSP + 0xd8]
LEA RSI,[RSP + 0x338]
CALL 0x0016e350
JMP 0x0016e04e
LAB_0016e04e:
LEA RDI,[RSP + 0x118]
LEA RSI,[RSP + 0xd8]
CALL 0x00152440
MOV qword ptr [RSP + 0x28],RAX
JMP 0x0016e06a
LAB_0016e06a:
MOV RDI,qword ptr [RSP + 0x28]
LEA RSI,[0x2c07ca]
CALL 0x001528b0
JMP 0x0016e07d
LAB_0016e07d:
LEA RDI,[RSP + 0xd8]
CALL 0x00153180
MOV RAX,qword ptr [RSP + 0x2d8]
DEC RAX
MOV qword ptr [RSP + 0x18],RAX
LEA RDI,[RSP + 0xb7]
MOV qword ptr [RSP + 0x20],RDI
CALL 0x00152de0
MOV RSI,qword ptr [RSP + 0x18]
MOV RCX,qword ptr [RSP + 0x20]
LAB_0016e0b6:
LEA RDI,[RSP + 0xb8]
MOV EDX,0x20
CALL 0x0017ba90
JMP 0x0016e0ca
LAB_0016e0ca:
LEA RDI,[RSP + 0x118]
LEA RSI,[RSP + 0xb8]
CALL 0x00152440
MOV qword ptr [RSP + 0x10],RAX
JMP 0x0016e0e6
LAB_0016e0e6:
MOV RDI,qword ptr [RSP + 0x10]
LEA RSI,[0x2c6066]
CALL 0x001528b0
JMP 0x0016e0f9
LAB_0016e0f9:
LEA RDI,[RSP + 0xb8]
CALL 0x00153180
LEA RDI,[RSP + 0xb7]
CALL 0x00153160
MOV RAX,qword ptr [RSP + 0x318]
CMP RAX,qword ptr [RSP + 0x2f8]
JGE 0x0016e21b
MOV RDX,qword ptr [RSP + 0x318]
INC RDX
LAB_0016e134:
LEA RDI,[RSP + 0x90]
LEA RSI,[RSP + 0x338]
CALL 0x0016e350
JMP 0x0016e14b
LAB_0016e14b:
LEA RDI,[RSP + 0x118]
LEA RSI,[RSP + 0x90]
CALL 0x00152440
MOV qword ptr [RSP + 0x8],RAX
JMP 0x0016e167
LAB_0016e167:
MOV RDI,qword ptr [RSP + 0x8]
LEA RSI,[0x2c07ca]
CALL 0x001528b0
JMP 0x0016e17a
LAB_0016e17a:
LEA RDI,[RSP + 0x90]
CALL 0x00153180
JMP 0x0016e21b
LAB_0016e21b:
MOV RDI,qword ptr [RSP + 0x70]
LEA RSI,[RSP + 0x118]
CALL 0x001530c0
LAB_0016e22d:
JMP 0x0016e22f
LAB_0016e22f:
LEA RDI,[RSP + 0x118]
CALL 0x00152cf0
MOV RAX,qword ptr [RSP + 0x78]
ADD RSP,0x358
RET
|
/* minja::error_location_suffix(std::__cxx11::string const&, unsigned long) */
minja * __thiscall minja::error_location_suffix(minja *this,string *param_1,ulong param_2)
{
long lVar1;
ostream *poVar2;
ulong uVar3;
string local_2c8 [39];
allocator local_2a1;
string local_2a0 [32];
string local_280 [32];
string local_260 [32];
ostringstream local_240 [399];
allocator<char> local_b1;
int8 local_b0;
int8 local_a8;
string local_a0 [32];
ulong local_80;
int1 local_71;
int8 local_70;
int8 local_68;
long local_60;
int1 local_51;
int8 local_50;
int8 local_48;
long local_40;
int8 local_38;
int8 local_30;
int8 local_28;
string *local_20;
ulong local_18;
string *local_10;
minja *local_8;
local_20 = param_1;
local_18 = param_2;
local_10 = param_1;
local_8 = this;
local_28 = std::__cxx11::string::begin();
local_30 = std::__cxx11::string::end();
local_50 = __gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::operator+
((__normal_iterator<char_const*,std::__cxx11::string> *)&local_28,local_18);
local_48 = local_28;
local_51 = 10;
local_38 = local_50;
local_40 = std::count<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,char>
(local_28,local_50,&local_51);
local_40 = local_40 + 1;
local_68 = local_28;
local_70 = local_30;
local_71 = 10;
local_60 = std::count<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,char>
(local_28,local_30,&local_71);
uVar3 = local_18;
local_60 = local_60 + 1;
local_a8 = local_28;
local_b0 = local_38;
std::allocator<char>::allocator();
/* try { // try from 0016de70 to 0016de7c has its CatchHandler @ 0016dfca */
std::__cxx11::string::string<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,void>
(local_a0,local_a8,local_b0,&local_b1);
lVar1 = std::__cxx11::string::rfind((char)local_a0,10);
std::__cxx11::string::~string(local_a0);
std::allocator<char>::~allocator(&local_b1);
local_80 = uVar3 - lVar1;
std::__cxx11::ostringstream::ostringstream(local_240);
/* try { // try from 0016deeb to 0016df89 has its CatchHandler @ 0016dff0 */
poVar2 = std::operator<<((ostream *)local_240," at row ");
poVar2 = (ostream *)std::ostream::operator<<(poVar2,local_40);
poVar2 = std::operator<<(poVar2,", column ");
poVar2 = (ostream *)std::ostream::operator<<(poVar2,local_80);
std::operator<<(poVar2,":\n");
if (1 < local_40) {
error_location_suffix(std::__cxx11::string_const&,unsigned_long)::$_0::operator()[abi_cxx11_
((ulong)local_260);
/* try { // try from 0016df8c to 0016dfb8 has its CatchHandler @ 0016e009 */
poVar2 = std::operator<<((ostream *)local_240,local_260);
std::operator<<(poVar2,"\n");
std::__cxx11::string::~string(local_260);
}
/* try { // try from 0016e037 to 0016e04b has its CatchHandler @ 0016dff0 */
error_location_suffix(std::__cxx11::string_const&,unsigned_long)::$_0::operator()[abi_cxx11_
((ulong)local_280);
/* try { // try from 0016e04e to 0016e07a has its CatchHandler @ 0016e18c */
poVar2 = std::operator<<((ostream *)local_240,local_280);
std::operator<<(poVar2,"\n");
std::__cxx11::string::~string(local_280);
uVar3 = local_80 - 1;
std::allocator<char>::allocator();
/* try { // try from 0016e0b6 to 0016e0c7 has its CatchHandler @ 0016e1b2 */
std::__cxx11::string::string<std::allocator<char>>(local_2a0,uVar3,' ',&local_2a1);
/* try { // try from 0016e0ca to 0016e0f6 has its CatchHandler @ 0016e1c8 */
poVar2 = std::operator<<((ostream *)local_240,local_2a0);
std::operator<<(poVar2,"^\n");
std::__cxx11::string::~string(local_2a0);
std::allocator<char>::~allocator((allocator<char> *)&local_2a1);
if (local_40 < local_60) {
/* try { // try from 0016e134 to 0016e148 has its CatchHandler @ 0016dff0 */
error_location_suffix(std::__cxx11::string_const&,unsigned_long)::$_0::operator()[abi_cxx11_
((ulong)local_2c8);
/* try { // try from 0016e14b to 0016e177 has its CatchHandler @ 0016e1f8 */
poVar2 = std::operator<<((ostream *)local_240,local_2c8);
std::operator<<(poVar2,"\n");
std::__cxx11::string::~string(local_2c8);
}
/* try { // try from 0016e21b to 0016e22c has its CatchHandler @ 0016dff0 */
std::__cxx11::ostringstream::str();
std::__cxx11::ostringstream::~ostringstream(local_240);
return this;
}
| |
23,309 | intx::div_result<intx::uint<256u>, intx::uint<256u>> intx::udivrem<256u, 256u>(intx::uint<256u> const&, intx::uint<256u> const&) | corpus-core[P]colibri-stateless/build_O3/_deps/intx-src/include/intx/intx.hpp | constexpr div_result<uint<M>, uint<N>> udivrem(const uint<M>& u, const uint<N>& v) noexcept
{
auto na = internal::normalize(u, v);
if (na.num_numerator_words <= na.num_divisor_words)
return {0, static_cast<uint<N>>(u)};
if (na.num_divisor_words == 1)
{
const auto r = internal::udivrem_by1(
as_words(na.numerator), na.num_numerator_words, as_words(na.divisor)[0]);
return {static_cast<uint<M>>(na.numerator), r >> na.shift};
}
if (na.num_divisor_words == 2)
{
const auto d = as_words(na.divisor);
const auto r =
internal::udivrem_by2(as_words(na.numerator), na.num_numerator_words, {d[0], d[1]});
return {static_cast<uint<M>>(na.numerator), r >> na.shift};
}
auto un = as_words(na.numerator); // Will be modified.
uint<M> q;
internal::udivrem_knuth(
as_words(q), &un[0], na.num_numerator_words, as_words(na.divisor), na.num_divisor_words);
uint<N> r;
auto rw = as_words(r);
for (int i = 0; i < na.num_divisor_words - 1; ++i)
rw[i] = na.shift ? (un[i] >> na.shift) | (un[i + 1] << (64 - na.shift)) : un[i];
rw[na.num_divisor_words - 1] = un[na.num_divisor_words - 1] >> na.shift;
return {q, r};
} | O3 | cpp | intx::div_result<intx::uint<256u>, intx::uint<256u>> intx::udivrem<256u, 256u>(intx::uint<256u> const&, intx::uint<256u> const&):
pushq %r15
pushq %r14
pushq %rbx
subq $0xe0, %rsp
movq %rdi, %rbx
xorps %xmm0, %xmm0
leaq 0x20(%rsp), %r14
movaps %xmm0, 0x30(%r14)
movaps %xmm0, 0x20(%r14)
movaps %xmm0, 0x10(%r14)
movaps %xmm0, (%r14)
movaps %xmm0, -0x10(%r14)
movaps %xmm0, -0x20(%r14)
movq $0x0, 0x40(%r14)
movl $0x9, %ecx
leal -0x1(%rcx), %eax
cmpq $0x0, -0x8(%rsi,%rax,8)
jne 0x3f079
decl %ecx
cmpl $0x1, %ecx
ja 0x3f065
xorl %eax, %eax
movl %eax, 0x6c(%rsp)
movl $0x5, %ecx
leal -0x1(%rcx), %r8d
cmpq $0x0, -0x8(%rdx,%r8,8)
jne 0x3f098
decl %ecx
cmpl $0x1, %ecx
ja 0x3f082
xorl %r8d, %r8d
movl %r8d, 0x68(%rsp)
movslq %r8d, %r9
movq -0x8(%rdx,%r9,8), %rcx
testq %rcx, %rcx
je 0x3f3bc
bsrq %rcx, %rdi
xorq $0x3f, %rdi
movl %edi, 0x70(%rsp)
je 0x3f14a
movl $0x4, %r10d
movq -0x10(%rdx,%r10,8), %r11
movq -0x8(%rdx,%r10,8), %r15
movl %edi, %ecx
shldq %cl, %r11, %r15
movq %r15, -0x8(%rsp,%r10,8)
decq %r10
cmpq $0x1, %r10
ja 0x3f0c6
movq (%rdx), %rdx
movl %edi, %ecx
shlq %cl, %rdx
movq %rdx, (%rsp)
movq 0x38(%rsi), %r10
movq %rdi, %rcx
negq %rcx
shrq %cl, %r10
movl $0x40, %edx
subq %rdi, %rdx
movq %r10, 0x60(%rsp)
movl $0x6, %r10d
movq (%rsi,%r10,8), %r11
movq 0x8(%rsi,%r10,8), %r15
movl %edi, %ecx
shlq %cl, %r15
movl %edx, %ecx
shrq %cl, %r11
orq %r15, %r11
movq %r11, 0x28(%rsp,%r10,8)
leaq -0x1(%r10), %rcx
incq %r10
cmpq $0x1, %r10
movq %rcx, %r10
ja 0x3f110
movq (%rsi), %rdx
movl %edi, %ecx
shlq %cl, %rdx
movq %rdx, 0x20(%rsp)
jmp 0x3f1a5
movups (%rsi), %xmm0
movups 0x10(%rsi), %xmm1
movups 0x20(%rsi), %xmm2
movups 0x30(%rsi), %xmm3
movaps %xmm3, 0xd0(%rsp)
movaps %xmm2, 0xc0(%rsp)
movaps %xmm1, 0xb0(%rsp)
movaps %xmm0, 0xa0(%rsp)
movups %xmm3, 0x30(%r14)
movups %xmm2, 0x20(%r14)
movups %xmm1, 0x10(%r14)
movups %xmm0, (%r14)
movq $0x0, 0x60(%rsp)
movups (%rdx), %xmm0
movups 0x10(%rdx), %xmm1
movaps %xmm0, (%rsp)
movaps %xmm1, 0x10(%rsp)
movslq %eax, %rcx
cmpq $0x0, 0x20(%rsp,%rcx,8)
jne 0x3f1bc
movq 0x18(%rsp,%rcx,8), %rcx
cmpq -0x8(%rsp,%r9,8), %rcx
jb 0x3f1c2
incl %eax
movl %eax, 0x6c(%rsp)
cmpl %r8d, %eax
jle 0x3f226
cmpl $0x2, %r8d
je 0x3f244
cmpl $0x1, %r8d
jne 0x3f2ab
movq (%rsp), %rdx
movq %r14, %rdi
movl %eax, %esi
callq 0x3de07
movups (%r14), %xmm0
movups 0x10(%r14), %xmm1
movups 0x20(%r14), %xmm2
movups 0x30(%r14), %xmm3
movups %xmm0, (%rbx)
movups %xmm1, 0x10(%rbx)
movups %xmm2, 0x20(%rbx)
movups %xmm3, 0x30(%rbx)
movb 0x70(%rsp), %cl
shrq %cl, %rax
xorps %xmm0, %xmm0
movups %xmm0, 0x48(%rbx)
movq $0x0, 0x58(%rbx)
movq %rax, 0x40(%rbx)
jmp 0x3f38b
xorps %xmm0, %xmm0
movups %xmm0, 0x30(%rbx)
movups %xmm0, 0x20(%rbx)
movups %xmm0, 0x10(%rbx)
movups %xmm0, (%rbx)
movups (%rsi), %xmm0
movups 0x10(%rsi), %xmm1
jmp 0x3f383
movq (%rsp), %rdx
movq 0x8(%rsp), %rcx
movq %r14, %rdi
movl %eax, %esi
callq 0x3dfaf
movups (%r14), %xmm0
movups 0x10(%r14), %xmm1
movups 0x20(%r14), %xmm2
movups 0x30(%r14), %xmm3
movups %xmm3, 0x30(%rbx)
movups %xmm2, 0x20(%rbx)
movups %xmm1, 0x10(%rbx)
movups %xmm0, (%rbx)
movl 0x70(%rsp), %esi
cmpq $0x7f, %rsi
ja 0x3f39b
cmpl $0x3f, %esi
ja 0x3f3a1
movl %esi, %ecx
shrq %cl, %rax
leaq (%rdx,%rdx), %rdi
notb %cl
shlq %cl, %rdi
orq %rax, %rdi
movl %esi, %ecx
shrq %cl, %rdx
jmp 0x3f3ab
xorps %xmm0, %xmm0
leaq 0xa0(%rsp), %rdi
movaps %xmm0, 0x30(%rdi)
movaps %xmm0, 0x20(%rdi)
movaps %xmm0, 0x10(%rdi)
movaps %xmm0, (%rdi)
movq %rsp, %r15
movq %r14, %rsi
movl %eax, %edx
movq %r15, %rcx
callq 0x3e195
xorps %xmm0, %xmm0
movaps %xmm0, 0x90(%rsp)
movaps %xmm0, 0x80(%rsp)
movl 0x68(%r15), %ecx
movl 0x70(%r15), %eax
leal -0x1(%rcx), %esi
cmpl $0x1, %ecx
jle 0x3f32f
movl $0x40, %edx
subl %eax, %edx
movl %esi, %edi
xorl %r8d, %r8d
movq 0x20(%rsp,%r8,8), %r9
testl %eax, %eax
je 0x3f31f
movl %eax, %ecx
shrq %cl, %r9
movq 0x28(%rsp,%r8,8), %r10
movl %edx, %ecx
shlq %cl, %r10
orq %r10, %r9
movq %r9, 0x80(%rsp,%r8,8)
incq %r8
cmpq %r8, %rdi
jne 0x3f304
movslq %esi, %rdx
movq 0x20(%rsp,%rdx,8), %rsi
movl %eax, %ecx
shrq %cl, %rsi
movq %rsi, 0x80(%rsp,%rdx,8)
movaps 0xa0(%rsp), %xmm0
movaps 0xb0(%rsp), %xmm1
movaps 0xc0(%rsp), %xmm2
movaps 0xd0(%rsp), %xmm3
movups %xmm3, 0x30(%rbx)
movups %xmm2, 0x20(%rbx)
movups %xmm1, 0x10(%rbx)
movups %xmm0, (%rbx)
movaps 0x80(%rsp), %xmm0
movaps 0x90(%rsp), %xmm1
movups %xmm0, 0x40(%rbx)
movups %xmm1, 0x50(%rbx)
movq %rbx, %rax
addq $0xe0, %rsp
popq %rbx
popq %r14
popq %r15
retq
xorl %edx, %edx
xorl %edi, %edi
jmp 0x3f3ab
movq %rdx, %rdi
movl %esi, %ecx
shrq %cl, %rdi
xorl %edx, %edx
xorps %xmm0, %xmm0
movups %xmm0, 0x50(%rbx)
movq %rdi, 0x40(%rbx)
movq %rdx, 0x48(%rbx)
jmp 0x3f38b
leaq 0x427e4(%rip), %rdi # 0x81ba7
leaq 0x427e4(%rip), %rsi # 0x81bae
leaq 0x42853(%rip), %rcx # 0x81c24
movl $0x5ff, %edx # imm = 0x5FF
callq 0x21130
| _ZN4intx7udivremILj512ELj256EEENS_10div_resultINS_4uintIXT_EEENS2_IXT0_EEEEERKS3_RKS4_:
push r15
push r14
push rbx
sub rsp, 0E0h
mov rbx, rdi
xorps xmm0, xmm0
lea r14, [rsp+0F8h+var_D8]
movaps xmmword ptr [r14+30h], xmm0
movaps xmmword ptr [r14+20h], xmm0
movaps xmmword ptr [r14+10h], xmm0
movaps xmmword ptr [r14], xmm0
movaps xmmword ptr [r14-10h], xmm0
movaps xmmword ptr [r14-20h], xmm0
mov qword ptr [r14+40h], 0
mov ecx, 9
loc_3F065:
lea eax, [rcx-1]
cmp qword ptr [rsi+rax*8-8], 0
jnz short loc_3F079
dec ecx
cmp ecx, 1
ja short loc_3F065
xor eax, eax
loc_3F079:
mov [rsp+0F8h+var_8C], eax
mov ecx, 5
loc_3F082:
lea r8d, [rcx-1]
cmp qword ptr [rdx+r8*8-8], 0
jnz short loc_3F098
dec ecx
cmp ecx, 1
ja short loc_3F082
xor r8d, r8d; unsigned __int64 *
loc_3F098:
mov [rsp+0F8h+var_90], r8d
movsxd r9, r8d; int
mov rcx, [rdx+r9*8-8]
test rcx, rcx
jz loc_3F3BC
bsr rdi, rcx
xor rdi, 3Fh
mov [rsp+0F8h+var_88], edi
jz loc_3F14A
mov r10d, 4
loc_3F0C6:
mov r11, [rdx+r10*8-10h]
mov r15, [rdx+r10*8-8]
mov ecx, edi
shld r15, r11, cl
mov [rsp+r10*8+0F8h+var_100], r15
dec r10
cmp r10, 1
ja short loc_3F0C6
mov rdx, [rdx]
mov ecx, edi
shl rdx, cl
mov qword ptr [rsp+0F8h+var_F8], rdx
mov r10, [rsi+38h]
mov rcx, rdi
neg rcx
shr r10, cl
mov edx, 40h ; '@'
sub rdx, rdi
mov [rsp+0F8h+var_98], r10
mov r10d, 6
loc_3F110:
mov r11, [rsi+r10*8]
mov r15, [rsi+r10*8+8]
mov ecx, edi
shl r15, cl
mov ecx, edx
shr r11, cl
or r11, r15
mov [rsp+r10*8+0F8h+var_D0], r11
lea rcx, [r10-1]
inc r10
cmp r10, 1
mov r10, rcx
ja short loc_3F110
mov rdx, [rsi]
mov ecx, edi
shl rdx, cl
mov [rsp+0F8h+var_D8], rdx
jmp short loc_3F1A5
loc_3F14A:
movups xmm0, xmmword ptr [rsi]
movups xmm1, xmmword ptr [rsi+10h]
movups xmm2, xmmword ptr [rsi+20h]
movups xmm3, xmmword ptr [rsi+30h]
movaps [rsp+0F8h+var_28], xmm3
movaps [rsp+0F8h+var_38], xmm2
movaps [rsp+0F8h+var_48], xmm1
movaps [rsp+0F8h+var_58], xmm0
movups xmmword ptr [r14+30h], xmm3
movups xmmword ptr [r14+20h], xmm2
movups xmmword ptr [r14+10h], xmm1
movups xmmword ptr [r14], xmm0
mov [rsp+0F8h+var_98], 0
movups xmm0, xmmword ptr [rdx]
movups xmm1, xmmword ptr [rdx+10h]
movaps xmmword ptr [rsp+0F8h+var_F8], xmm0
movaps xmmword ptr [rsp+0F8h+var_E8], xmm1
loc_3F1A5:
movsxd rcx, eax
cmp [rsp+rcx*8+0F8h+var_D8], 0
jnz short loc_3F1BC
mov rcx, [rsp+rcx*8+0F8h+var_E8+8]; unsigned __int64
cmp rcx, [rsp+r9*8+0F8h+var_100]
jb short loc_3F1C2
loc_3F1BC:
inc eax
mov [rsp+0F8h+var_8C], eax
loc_3F1C2:
cmp eax, r8d
jle short loc_3F226
cmp r8d, 2
jz short loc_3F244
cmp r8d, 1
jnz loc_3F2AB
mov rdx, qword ptr [rsp+0F8h+var_F8]; int
mov rdi, r14; this
mov esi, eax; unsigned __int64 *
call _ZN4intx8internal11udivrem_by1EPmim; intx::internal::udivrem_by1(ulong *,int,ulong)
movups xmm0, xmmword ptr [r14]
movups xmm1, xmmword ptr [r14+10h]
movups xmm2, xmmword ptr [r14+20h]
movups xmm3, xmmword ptr [r14+30h]
movups xmmword ptr [rbx], xmm0
movups xmmword ptr [rbx+10h], xmm1
movups xmmword ptr [rbx+20h], xmm2
movups xmmword ptr [rbx+30h], xmm3
mov cl, byte ptr [rsp+0F8h+var_88]
shr rax, cl
xorps xmm0, xmm0
movups xmmword ptr [rbx+48h], xmm0
mov qword ptr [rbx+58h], 0
mov [rbx+40h], rax
jmp loc_3F38B
loc_3F226:
xorps xmm0, xmm0
movups xmmword ptr [rbx+30h], xmm0
movups xmmword ptr [rbx+20h], xmm0
movups xmmword ptr [rbx+10h], xmm0
movups xmmword ptr [rbx], xmm0
movups xmm0, xmmword ptr [rsi]
movups xmm1, xmmword ptr [rsi+10h]
jmp loc_3F383
loc_3F244:
mov rdx, qword ptr [rsp+0F8h+var_F8]
mov rcx, qword ptr [rsp+0F8h+var_F8+8]
mov rdi, r14
mov esi, eax
call _ZN4intx8internal11udivrem_by2EPmiNS_4uintILj128EEE; intx::internal::udivrem_by2(ulong *,int,intx::uint<128u>)
movups xmm0, xmmword ptr [r14]
movups xmm1, xmmword ptr [r14+10h]
movups xmm2, xmmword ptr [r14+20h]
movups xmm3, xmmword ptr [r14+30h]
movups xmmword ptr [rbx+30h], xmm3
movups xmmword ptr [rbx+20h], xmm2
movups xmmword ptr [rbx+10h], xmm1
movups xmmword ptr [rbx], xmm0
mov esi, [rsp+0F8h+var_88]
cmp rsi, 7Fh
ja loc_3F39B
cmp esi, 3Fh ; '?'
ja loc_3F3A1
mov ecx, esi
shr rax, cl
lea rdi, [rdx+rdx]
not cl
shl rdi, cl
or rdi, rax
mov ecx, esi
shr rdx, cl
jmp loc_3F3AB
loc_3F2AB:
xorps xmm0, xmm0
lea rdi, [rsp+0F8h+var_58]; this
movaps xmmword ptr [rdi+30h], xmm0
movaps xmmword ptr [rdi+20h], xmm0
movaps xmmword ptr [rdi+10h], xmm0
movaps xmmword ptr [rdi], xmm0
mov r15, rsp
mov rsi, r14; unsigned __int64 *
mov edx, eax; unsigned __int64 *
mov rcx, r15; int
call _ZN4intx8internal13udivrem_knuthEPmS1_iPKmi; intx::internal::udivrem_knuth(ulong *,ulong *,int,ulong const*,int)
xorps xmm0, xmm0
movaps [rsp+0F8h+var_68], xmm0
movaps [rsp+0F8h+var_78], xmm0
mov ecx, [r15+68h]
mov eax, [r15+70h]
lea esi, [rcx-1]
cmp ecx, 1
jle short loc_3F32F
mov edx, 40h ; '@'
sub edx, eax
mov edi, esi
xor r8d, r8d
loc_3F304:
mov r9, [rsp+r8*8+0F8h+var_D8]
test eax, eax
jz short loc_3F31F
mov ecx, eax
shr r9, cl
mov r10, [rsp+r8*8+0F8h+var_D0]
mov ecx, edx
shl r10, cl
or r9, r10
loc_3F31F:
mov qword ptr [rsp+r8*8+0F8h+var_78], r9
inc r8
cmp rdi, r8
jnz short loc_3F304
loc_3F32F:
movsxd rdx, esi
mov rsi, [rsp+rdx*8+0F8h+var_D8]
mov ecx, eax
shr rsi, cl
mov qword ptr [rsp+rdx*8+0F8h+var_78], rsi
movaps xmm0, [rsp+0F8h+var_58]
movaps xmm1, [rsp+0F8h+var_48]
movaps xmm2, [rsp+0F8h+var_38]
movaps xmm3, [rsp+0F8h+var_28]
movups xmmword ptr [rbx+30h], xmm3
movups xmmword ptr [rbx+20h], xmm2
movups xmmword ptr [rbx+10h], xmm1
movups xmmword ptr [rbx], xmm0
movaps xmm0, [rsp+0F8h+var_78]
movaps xmm1, [rsp+0F8h+var_68]
loc_3F383:
movups xmmword ptr [rbx+40h], xmm0
movups xmmword ptr [rbx+50h], xmm1
loc_3F38B:
mov rax, rbx
add rsp, 0E0h
pop rbx
pop r14
pop r15
retn
loc_3F39B:
xor edx, edx
xor edi, edi
jmp short loc_3F3AB
loc_3F3A1:
mov rdi, rdx
mov ecx, esi
shr rdi, cl
xor edx, edx
loc_3F3AB:
xorps xmm0, xmm0
movups xmmword ptr [rbx+50h], xmm0
mov [rbx+40h], rdi
mov [rbx+48h], rdx
jmp short loc_3F38B
loc_3F3BC:
lea rdi, aX0; "x != 0"
lea rsi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aUnsignedIntInt; "unsigned int intx::internal::clz_nonzer"...
mov edx, 5FFh
call ___assert_fail
| long long intx::udivrem<512u,256u>(long long a1, __int128 *a2, long long a3)
{
int v4; // ecx
long long v5; // rax
int v6; // ecx
const unsigned long long *v7; // r8
unsigned long long v8; // rcx
unsigned long long v9; // rdi
unsigned long long v10; // rdi
long long v11; // r10
bool v12; // cf
long long v13; // r10
bool v14; // cc
__int128 v15; // xmm0
__int128 v16; // xmm1
__int128 v17; // xmm2
__int128 v18; // xmm1
unsigned long long v19; // rax
__int128 v20; // xmm1
__int128 v21; // xmm2
__int128 v22; // xmm3
unsigned long long v23; // rax
__int128 v24; // xmm0
__int128 v25; // xmm1
__int128 v26; // rdi
unsigned long long v27; // rax
unsigned long long v28; // rdx
__int128 v29; // xmm0
__int128 v30; // xmm1
__int128 v31; // xmm2
unsigned long long v32; // rdi
unsigned long long v33; // rdx
unsigned int v34; // eax
int v35; // esi
char v36; // dl
long long v37; // r8
unsigned long long v38; // r9
__int128 v39; // xmm0
__int128 v40; // xmm1
__int128 v41; // xmm2
int v44[4]; // [rsp+8h] [rbp-F8h] BYREF
unsigned long long v45[2]; // [rsp+18h] [rbp-E8h]
unsigned long long v46[2]; // [rsp+28h] [rbp-D8h] BYREF
__int128 v47; // [rsp+38h] [rbp-C8h]
__int128 v48; // [rsp+48h] [rbp-B8h]
__int128 v49; // [rsp+58h] [rbp-A8h]
long long v50; // [rsp+68h] [rbp-98h]
int v51; // [rsp+70h] [rbp-90h]
int v52; // [rsp+74h] [rbp-8Ch]
unsigned int v53; // [rsp+78h] [rbp-88h]
__int128 v54; // [rsp+88h] [rbp-78h]
__int128 v55; // [rsp+98h] [rbp-68h]
__int128 v56; // [rsp+A8h] [rbp-58h] BYREF
__int128 v57; // [rsp+B8h] [rbp-48h]
__int128 v58; // [rsp+C8h] [rbp-38h]
__int128 v59; // [rsp+D8h] [rbp-28h]
v49 = 0LL;
v48 = 0LL;
v47 = 0LL;
*(_OWORD *)v46 = 0LL;
*(_OWORD *)v45 = 0LL;
*(_OWORD *)v44 = 0LL;
v50 = 0LL;
v4 = 9;
while ( 1 )
{
v5 = (unsigned int)(v4 - 1);
if ( *((_QWORD *)a2 + v5 - 1) )
break;
if ( (unsigned int)--v4 <= 1 )
{
LODWORD(v5) = 0;
break;
}
}
v52 = v5;
v6 = 5;
while ( 1 )
{
v7 = (const unsigned long long *)(unsigned int)(v6 - 1);
if ( *(_QWORD *)(a3 + 8LL * (_QWORD)v7 - 8) )
break;
if ( (unsigned int)--v6 <= 1 )
{
v7 = 0LL;
break;
}
}
v51 = (int)v7;
v8 = *(_QWORD *)(a3 + 8LL * (int)v7 - 8);
if ( !v8 )
__assert_fail(
"x != 0",
"/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O3/_deps/intx-src/include/intx/intx.hpp",
1535LL,
"unsigned int intx::internal::clz_nonzero(uint64_t)");
_BitScanReverse64(&v9, v8);
v10 = v9 ^ 0x3F;
v53 = v10;
if ( v10 )
{
v11 = 4LL;
do
{
*(_QWORD *)&v44[2 * v11 - 2] = (*(_QWORD *)(a3 + 8 * v11 - 8) << v10) | (*(_QWORD *)(a3 + 8 * v11 - 16) >> (64 - (unsigned __int8)v10));
v12 = v11-- == 1;
}
while ( !v12 && v11 != 1 );
*(_QWORD *)v44 = *(_QWORD *)a3 << v10;
v50 = *((_QWORD *)a2 + 7) >> -(char)v10;
v13 = 6LL;
do
{
v46[v13 + 1] = (*((_QWORD *)a2 + v13 + 1) << v10) | (*((_QWORD *)a2 + v13) >> (64 - (unsigned __int8)v10));
v14 = v13 == -1 || v13 == 0;
--v13;
}
while ( !v14 );
v46[0] = *(_QWORD *)a2 << v10;
}
else
{
v15 = *a2;
v16 = a2[1];
v17 = a2[2];
v59 = a2[3];
v58 = v17;
v57 = v16;
v56 = v15;
v49 = v59;
v48 = v17;
v47 = v16;
*(_OWORD *)v46 = v15;
v50 = 0LL;
v18 = *(_OWORD *)(a3 + 16);
*(_OWORD *)v44 = *(_OWORD *)a3;
*(_OWORD *)v45 = v18;
}
if ( v46[(int)v5] || v45[(int)v5 + 1] >= *(_QWORD *)&v44[2 * (int)v7 - 2] )
{
LODWORD(v5) = v5 + 1;
v52 = v5;
}
if ( (int)v5 <= (int)v7 )
{
*(_OWORD *)(a1 + 48) = 0LL;
*(_OWORD *)(a1 + 32) = 0LL;
*(_OWORD *)(a1 + 16) = 0LL;
*(_OWORD *)a1 = 0LL;
v24 = *a2;
v25 = a2[1];
goto LABEL_34;
}
if ( (_DWORD)v7 != 2 )
{
if ( (_DWORD)v7 == 1 )
{
v19 = intx::internal::udivrem_by1(
(intx::internal *)v46,
(unsigned long long *)(unsigned int)v5,
*(unsigned long long *)v44);
v20 = v47;
v21 = v48;
v22 = v49;
*(_OWORD *)a1 = *(_OWORD *)v46;
*(_OWORD *)(a1 + 16) = v20;
*(_OWORD *)(a1 + 32) = v21;
*(_OWORD *)(a1 + 48) = v22;
v23 = v19 >> v53;
*(_OWORD *)(a1 + 72) = 0LL;
*(_QWORD *)(a1 + 88) = 0LL;
*(_QWORD *)(a1 + 64) = v23;
return a1;
}
v59 = 0LL;
v58 = 0LL;
v57 = 0LL;
v56 = 0LL;
intx::internal::udivrem_knuth(
(intx::internal *)&v56,
v46,
(unsigned long long *)(unsigned int)v5,
(const unsigned long long *)v44,
v7);
v55 = 0LL;
v54 = 0LL;
v34 = v53;
v35 = v51 - 1;
if ( v51 > 1 )
{
v36 = 64 - v53;
v37 = 0LL;
do
{
v38 = v46[v37];
if ( v34 )
v38 = (v46[v37 + 1] << v36) | (v38 >> v34);
*((_QWORD *)&v54 + v37++) = v38;
}
while ( v35 != v37 );
}
*((_QWORD *)&v54 + v35) = v46[v35] >> v34;
v39 = v56;
v40 = v57;
v41 = v58;
*(_OWORD *)(a1 + 48) = v59;
*(_OWORD *)(a1 + 32) = v41;
*(_OWORD *)(a1 + 16) = v40;
*(_OWORD *)a1 = v39;
v24 = v54;
v25 = v55;
LABEL_34:
*(_OWORD *)(a1 + 64) = v24;
*(_OWORD *)(a1 + 80) = v25;
return a1;
}
*(_QWORD *)&v26 = v46;
*((_QWORD *)&v26 + 1) = (unsigned int)v5;
v27 = intx::internal::udivrem_by2(v26, *(unsigned long long *)v44, *(unsigned long long *)&v44[2]);
v29 = *(_OWORD *)v46;
v30 = v47;
v31 = v48;
*(_OWORD *)(a1 + 48) = v49;
*(_OWORD *)(a1 + 32) = v31;
*(_OWORD *)(a1 + 16) = v30;
*(_OWORD *)a1 = v29;
if ( v53 > 0x7FuLL )
{
v33 = 0LL;
v32 = 0LL;
}
else if ( v53 > 0x3F )
{
v32 = v28 >> v53;
v33 = 0LL;
}
else
{
v32 = (v27 >> v53) | ((2 * v28) << ~(_BYTE)v53);
v33 = v28 >> v53;
}
*(_OWORD *)(a1 + 80) = 0LL;
*(_QWORD *)(a1 + 64) = v32;
*(_QWORD *)(a1 + 72) = v33;
return a1;
}
| udivrem<512u,256u>:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0xe0
MOV RBX,RDI
XORPS XMM0,XMM0
LEA R14,[RSP + 0x20]
MOVAPS xmmword ptr [R14 + 0x30],XMM0
MOVAPS xmmword ptr [R14 + 0x20],XMM0
MOVAPS xmmword ptr [R14 + 0x10],XMM0
MOVAPS xmmword ptr [R14],XMM0
MOVAPS xmmword ptr [R14 + -0x10],XMM0
MOVAPS xmmword ptr [R14 + -0x20],XMM0
MOV qword ptr [R14 + 0x40],0x0
MOV ECX,0x9
LAB_0013f065:
LEA EAX,[RCX + -0x1]
CMP qword ptr [RSI + RAX*0x8 + -0x8],0x0
JNZ 0x0013f079
DEC ECX
CMP ECX,0x1
JA 0x0013f065
XOR EAX,EAX
LAB_0013f079:
MOV dword ptr [RSP + 0x6c],EAX
MOV ECX,0x5
LAB_0013f082:
LEA R8D,[RCX + -0x1]
CMP qword ptr [RDX + R8*0x8 + -0x8],0x0
JNZ 0x0013f098
DEC ECX
CMP ECX,0x1
JA 0x0013f082
XOR R8D,R8D
LAB_0013f098:
MOV dword ptr [RSP + 0x68],R8D
MOVSXD R9,R8D
MOV RCX,qword ptr [RDX + R9*0x8 + -0x8]
TEST RCX,RCX
JZ 0x0013f3bc
BSR RDI,RCX
XOR RDI,0x3f
MOV dword ptr [RSP + 0x70],EDI
JZ 0x0013f14a
MOV R10D,0x4
LAB_0013f0c6:
MOV R11,qword ptr [RDX + R10*0x8 + -0x10]
MOV R15,qword ptr [RDX + R10*0x8 + -0x8]
MOV ECX,EDI
SHLD R15,R11,CL
MOV qword ptr [RSP + R10*0x8 + -0x8],R15
DEC R10
CMP R10,0x1
JA 0x0013f0c6
MOV RDX,qword ptr [RDX]
MOV ECX,EDI
SHL RDX,CL
MOV qword ptr [RSP],RDX
MOV R10,qword ptr [RSI + 0x38]
MOV RCX,RDI
NEG RCX
SHR R10,CL
MOV EDX,0x40
SUB RDX,RDI
MOV qword ptr [RSP + 0x60],R10
MOV R10D,0x6
LAB_0013f110:
MOV R11,qword ptr [RSI + R10*0x8]
MOV R15,qword ptr [RSI + R10*0x8 + 0x8]
MOV ECX,EDI
SHL R15,CL
MOV ECX,EDX
SHR R11,CL
OR R11,R15
MOV qword ptr [RSP + R10*0x8 + 0x28],R11
LEA RCX,[R10 + -0x1]
INC R10
CMP R10,0x1
MOV R10,RCX
JA 0x0013f110
MOV RDX,qword ptr [RSI]
MOV ECX,EDI
SHL RDX,CL
MOV qword ptr [RSP + 0x20],RDX
JMP 0x0013f1a5
LAB_0013f14a:
MOVUPS XMM0,xmmword ptr [RSI]
MOVUPS XMM1,xmmword ptr [RSI + 0x10]
MOVUPS XMM2,xmmword ptr [RSI + 0x20]
MOVUPS XMM3,xmmword ptr [RSI + 0x30]
MOVAPS xmmword ptr [RSP + 0xd0],XMM3
MOVAPS xmmword ptr [RSP + 0xc0],XMM2
MOVAPS xmmword ptr [RSP + 0xb0],XMM1
MOVAPS xmmword ptr [RSP + 0xa0],XMM0
MOVUPS xmmword ptr [R14 + 0x30],XMM3
MOVUPS xmmword ptr [R14 + 0x20],XMM2
MOVUPS xmmword ptr [R14 + 0x10],XMM1
MOVUPS xmmword ptr [R14],XMM0
MOV qword ptr [RSP + 0x60],0x0
MOVUPS XMM0,xmmword ptr [RDX]
MOVUPS XMM1,xmmword ptr [RDX + 0x10]
MOVAPS xmmword ptr [RSP],XMM0
MOVAPS xmmword ptr [RSP + 0x10],XMM1
LAB_0013f1a5:
MOVSXD RCX,EAX
CMP qword ptr [RSP + RCX*0x8 + 0x20],0x0
JNZ 0x0013f1bc
MOV RCX,qword ptr [RSP + RCX*0x8 + 0x18]
CMP RCX,qword ptr [RSP + R9*0x8 + -0x8]
JC 0x0013f1c2
LAB_0013f1bc:
INC EAX
MOV dword ptr [RSP + 0x6c],EAX
LAB_0013f1c2:
CMP EAX,R8D
JLE 0x0013f226
CMP R8D,0x2
JZ 0x0013f244
CMP R8D,0x1
JNZ 0x0013f2ab
MOV RDX,qword ptr [RSP]
MOV RDI,R14
MOV ESI,EAX
CALL 0x0013de07
MOVUPS XMM0,xmmword ptr [R14]
MOVUPS XMM1,xmmword ptr [R14 + 0x10]
MOVUPS XMM2,xmmword ptr [R14 + 0x20]
MOVUPS XMM3,xmmword ptr [R14 + 0x30]
MOVUPS xmmword ptr [RBX],XMM0
MOVUPS xmmword ptr [RBX + 0x10],XMM1
MOVUPS xmmword ptr [RBX + 0x20],XMM2
MOVUPS xmmword ptr [RBX + 0x30],XMM3
MOV CL,byte ptr [RSP + 0x70]
SHR RAX,CL
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x48],XMM0
MOV qword ptr [RBX + 0x58],0x0
MOV qword ptr [RBX + 0x40],RAX
JMP 0x0013f38b
LAB_0013f226:
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x30],XMM0
MOVUPS xmmword ptr [RBX + 0x20],XMM0
MOVUPS xmmword ptr [RBX + 0x10],XMM0
MOVUPS xmmword ptr [RBX],XMM0
MOVUPS XMM0,xmmword ptr [RSI]
MOVUPS XMM1,xmmword ptr [RSI + 0x10]
JMP 0x0013f383
LAB_0013f244:
MOV RDX,qword ptr [RSP]
MOV RCX,qword ptr [RSP + 0x8]
MOV RDI,R14
MOV ESI,EAX
CALL 0x0013dfaf
MOVUPS XMM0,xmmword ptr [R14]
MOVUPS XMM1,xmmword ptr [R14 + 0x10]
MOVUPS XMM2,xmmword ptr [R14 + 0x20]
MOVUPS XMM3,xmmword ptr [R14 + 0x30]
MOVUPS xmmword ptr [RBX + 0x30],XMM3
MOVUPS xmmword ptr [RBX + 0x20],XMM2
MOVUPS xmmword ptr [RBX + 0x10],XMM1
MOVUPS xmmword ptr [RBX],XMM0
MOV ESI,dword ptr [RSP + 0x70]
CMP RSI,0x7f
JA 0x0013f39b
CMP ESI,0x3f
JA 0x0013f3a1
MOV ECX,ESI
SHR RAX,CL
LEA RDI,[RDX + RDX*0x1]
NOT CL
SHL RDI,CL
OR RDI,RAX
MOV ECX,ESI
SHR RDX,CL
JMP 0x0013f3ab
LAB_0013f2ab:
XORPS XMM0,XMM0
LEA RDI,[RSP + 0xa0]
MOVAPS xmmword ptr [RDI + 0x30],XMM0
MOVAPS xmmword ptr [RDI + 0x20],XMM0
MOVAPS xmmword ptr [RDI + 0x10],XMM0
MOVAPS xmmword ptr [RDI],XMM0
MOV R15,RSP
MOV RSI,R14
MOV EDX,EAX
MOV RCX,R15
CALL 0x0013e195
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP + 0x90],XMM0
MOVAPS xmmword ptr [RSP + 0x80],XMM0
MOV ECX,dword ptr [R15 + 0x68]
MOV EAX,dword ptr [R15 + 0x70]
LEA ESI,[RCX + -0x1]
CMP ECX,0x1
JLE 0x0013f32f
MOV EDX,0x40
SUB EDX,EAX
MOV EDI,ESI
XOR R8D,R8D
LAB_0013f304:
MOV R9,qword ptr [RSP + R8*0x8 + 0x20]
TEST EAX,EAX
JZ 0x0013f31f
MOV ECX,EAX
SHR R9,CL
MOV R10,qword ptr [RSP + R8*0x8 + 0x28]
MOV ECX,EDX
SHL R10,CL
OR R9,R10
LAB_0013f31f:
MOV qword ptr [RSP + R8*0x8 + 0x80],R9
INC R8
CMP RDI,R8
JNZ 0x0013f304
LAB_0013f32f:
MOVSXD RDX,ESI
MOV RSI,qword ptr [RSP + RDX*0x8 + 0x20]
MOV ECX,EAX
SHR RSI,CL
MOV qword ptr [RSP + RDX*0x8 + 0x80],RSI
MOVAPS XMM0,xmmword ptr [RSP + 0xa0]
MOVAPS XMM1,xmmword ptr [RSP + 0xb0]
MOVAPS XMM2,xmmword ptr [RSP + 0xc0]
MOVAPS XMM3,xmmword ptr [RSP + 0xd0]
MOVUPS xmmword ptr [RBX + 0x30],XMM3
MOVUPS xmmword ptr [RBX + 0x20],XMM2
MOVUPS xmmword ptr [RBX + 0x10],XMM1
MOVUPS xmmword ptr [RBX],XMM0
MOVAPS XMM0,xmmword ptr [RSP + 0x80]
MOVAPS XMM1,xmmword ptr [RSP + 0x90]
LAB_0013f383:
MOVUPS xmmword ptr [RBX + 0x40],XMM0
MOVUPS xmmword ptr [RBX + 0x50],XMM1
LAB_0013f38b:
MOV RAX,RBX
ADD RSP,0xe0
POP RBX
POP R14
POP R15
RET
LAB_0013f39b:
XOR EDX,EDX
XOR EDI,EDI
JMP 0x0013f3ab
LAB_0013f3a1:
MOV RDI,RDX
MOV ECX,ESI
SHR RDI,CL
XOR EDX,EDX
LAB_0013f3ab:
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x50],XMM0
MOV qword ptr [RBX + 0x40],RDI
MOV qword ptr [RBX + 0x48],RDX
JMP 0x0013f38b
LAB_0013f3bc:
LEA RDI,[0x181ba7]
LEA RSI,[0x181bae]
LEA RCX,[0x181c24]
MOV EDX,0x5ff
CALL 0x00121130
|
/* intx::div_result<intx::uint<512u>, intx::uint<256u> > intx::udivrem<512u, 256u>(intx::uint<512u>
const&, intx::uint<256u> const&) */
intx * __thiscall intx::udivrem<512u,256u>(intx *this,uint *param_1,uint *param_2)
{
byte bVar1;
uint uVar2;
ulong uVar3;
ulong uVar4;
long lVar5;
int1 auVar6 [16];
code *pcStack_100;
ulong local_f8;
code *apcStack_f0 [3];
ulong local_d8 [9];
uint local_90;
uint local_8c;
uint uStack_88;
int8 uStack_78;
int8 uStack_70;
int8 uStack_68;
int8 uStack_60;
ulong uStack_58;
int8 uStack_50;
int8 uStack_48;
int8 uStack_40;
int8 uStack_38;
int8 uStack_30;
int8 uStack_28;
int8 uStack_20;
local_d8[6] = 0;
local_d8[7] = 0;
local_d8[4] = 0;
local_d8[5] = 0;
local_d8[2] = 0;
local_d8[3] = 0;
local_d8[0] = 0;
local_d8[1] = 0;
apcStack_f0[1] = (code *)0x0;
apcStack_f0[2] = (code *)0x0;
local_f8 = 0;
apcStack_f0[0] = (code *)0x0;
local_d8[8] = 0;
uVar2 = 9;
do {
local_8c = uVar2 - 1;
if (*(long *)(param_1 + (ulong)local_8c * 8 + -8) != 0) goto LAB_0013f079;
uVar2 = uVar2 - 1;
} while (1 < uVar2);
local_8c = 0;
LAB_0013f079:
uVar2 = 5;
do {
local_90 = uVar2 - 1;
if (*(long *)(param_2 + (ulong)local_90 * 8 + -8) != 0) goto LAB_0013f098;
uVar2 = uVar2 - 1;
} while (1 < uVar2);
local_90 = 0;
LAB_0013f098:
uVar4 = *(ulong *)(param_2 + (long)(int)local_90 * 8 + -8);
if (uVar4 == 0) {
/* WARNING: Subroutine does not return */
pcStack_100 = exp<256u>;
__assert_fail("x != 0",
"/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O3/_deps/intx-src/include/intx/intx.hpp"
,0x5ff,"unsigned int intx::internal::clz_nonzero(uint64_t)");
}
uVar3 = 0x3f;
if (uVar4 != 0) {
for (; uVar4 >> uVar3 == 0; uVar3 = uVar3 - 1) {
}
}
uVar3 = uVar3 ^ 0x3f;
uStack_88 = (uint)uVar3;
if (uVar3 == 0) {
uStack_28 = *(int8 *)(param_1 + 0x30);
uStack_20 = *(int8 *)(param_1 + 0x38);
uStack_38 = *(int8 *)(param_1 + 0x20);
uStack_30 = *(int8 *)(param_1 + 0x28);
uStack_48 = *(int8 *)(param_1 + 0x10);
uStack_40 = *(int8 *)(param_1 + 0x18);
uStack_58 = *(ulong *)param_1;
uStack_50 = *(int8 *)(param_1 + 8);
local_d8[6] = *(int8 *)(param_1 + 0x30);
local_d8[7] = *(int8 *)(param_1 + 0x38);
local_d8[4] = *(int8 *)(param_1 + 0x20);
local_d8[5] = *(int8 *)(param_1 + 0x28);
local_d8[2] = *(int8 *)(param_1 + 0x10);
local_d8[3] = *(int8 *)(param_1 + 0x18);
local_d8[0] = *(ulong *)param_1;
local_d8[1] = *(int8 *)(param_1 + 8);
local_d8[8] = 0;
local_f8 = *(ulong *)param_2;
apcStack_f0[0] = *(code **)(param_2 + 8);
apcStack_f0[1] = (code *)*(int8 *)(param_2 + 0x10);
apcStack_f0[2] = (code *)*(int8 *)(param_2 + 0x18);
}
else {
uVar4 = 4;
do {
bVar1 = (byte)uVar3;
(&pcStack_100)[uVar4] =
(code *)(*(long *)(param_2 + uVar4 * 8 + -8) << (bVar1 & 0x3f) |
*(ulong *)(param_2 + uVar4 * 8 + -0x10) >> 0x40 - (bVar1 & 0x3f));
uVar4 = uVar4 - 1;
} while (1 < uVar4);
local_f8 = *(long *)param_2 << (bVar1 & 0x3f);
local_d8[8] = *(ulong *)(param_1 + 0x38) >> (-bVar1 & 0x3f);
lVar5 = 6;
do {
local_d8[lVar5 + 1] =
*(ulong *)(param_1 + lVar5 * 8) >> (0x40 - bVar1 & 0x3f) |
*(long *)(param_1 + lVar5 * 8 + 8) << (bVar1 & 0x3f);
uVar4 = lVar5 + 1;
lVar5 = lVar5 + -1;
} while (1 < uVar4);
local_d8[0] = *(long *)param_1 << (bVar1 & 0x3f);
}
if ((local_d8[(int)local_8c] != 0) ||
((&pcStack_100)[(int)local_90] <= apcStack_f0[(long)(int)local_8c + 2])) {
local_8c = local_8c + 1;
}
if ((int)local_90 < (int)local_8c) {
if (local_90 == 2) {
pcStack_100 = (code *)0x13f257;
auVar6 = internal::udivrem_by2((internal *)local_d8,local_8c,local_f8,apcStack_f0[0]);
uVar4 = auVar6._8_8_;
*(ulong *)(this + 0x30) = local_d8[6];
*(ulong *)(this + 0x38) = local_d8[7];
*(ulong *)(this + 0x20) = local_d8[4];
*(ulong *)(this + 0x28) = local_d8[5];
*(ulong *)(this + 0x10) = local_d8[2];
*(ulong *)(this + 0x18) = local_d8[3];
*(ulong *)this = local_d8[0];
*(ulong *)(this + 8) = local_d8[1];
if (uStack_88 < 0x80) {
bVar1 = (byte)uStack_88;
if (uStack_88 < 0x40) {
uVar3 = uVar4 * 2 << (~bVar1 & 0x3f) | auVar6._0_8_ >> (bVar1 & 0x3f);
uVar4 = uVar4 >> (bVar1 & 0x3f);
}
else {
uVar3 = uVar4 >> (bVar1 & 0x3f);
uVar4 = 0;
}
}
else {
uVar4 = 0;
uVar3 = 0;
}
*(int8 *)(this + 0x50) = 0;
*(int8 *)(this + 0x58) = 0;
*(ulong *)(this + 0x40) = uVar3;
*(ulong *)(this + 0x48) = uVar4;
return this;
}
if (local_90 == 1) {
pcStack_100 = (code *)0x13f1e5;
uVar4 = internal::udivrem_by1(local_d8,local_8c,local_f8);
*(ulong *)this = local_d8[0];
*(ulong *)(this + 8) = local_d8[1];
*(ulong *)(this + 0x10) = local_d8[2];
*(ulong *)(this + 0x18) = local_d8[3];
*(ulong *)(this + 0x20) = local_d8[4];
*(ulong *)(this + 0x28) = local_d8[5];
*(ulong *)(this + 0x30) = local_d8[6];
*(ulong *)(this + 0x38) = local_d8[7];
*(int8 *)(this + 0x48) = 0;
*(int8 *)(this + 0x50) = 0;
*(int8 *)(this + 0x58) = 0;
*(ulong *)(this + 0x40) = uVar4 >> ((byte)uStack_88 & 0x3f);
return this;
}
uStack_28 = 0;
uStack_20 = 0;
uStack_38 = 0;
uStack_30 = 0;
uStack_48 = 0;
uStack_40 = 0;
uStack_58 = 0;
uStack_50 = 0;
pcStack_100 = (code *)0x13f2d5;
internal::udivrem_knuth(&uStack_58,local_d8,local_8c,&local_f8,local_90);
uStack_68 = 0;
uStack_60 = 0;
uStack_78 = 0;
uStack_70 = 0;
uVar2 = local_90 - 1;
bVar1 = (byte)uStack_88;
if (1 < (int)local_90) {
uVar4 = 0;
do {
uVar3 = local_d8[uVar4];
if (uStack_88 != 0) {
uVar3 = uVar3 >> (bVar1 & 0x3f) | local_d8[uVar4 + 1] << (0x40 - bVar1 & 0x3f);
}
(&uStack_78)[uVar4] = uVar3;
uVar4 = uVar4 + 1;
} while (uVar2 != uVar4);
}
(&uStack_78)[(int)uVar2] = local_d8[(int)uVar2] >> (bVar1 & 0x3f);
*(int8 *)(this + 0x30) = uStack_28;
*(int8 *)(this + 0x38) = uStack_20;
*(int8 *)(this + 0x20) = uStack_38;
*(int8 *)(this + 0x28) = uStack_30;
*(int8 *)(this + 0x10) = uStack_48;
*(int8 *)(this + 0x18) = uStack_40;
*(ulong *)this = uStack_58;
*(int8 *)(this + 8) = uStack_50;
}
else {
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
uStack_78._0_4_ = *(int4 *)param_1;
uStack_78._4_4_ = *(int4 *)(param_1 + 4);
uStack_70._0_4_ = *(int4 *)(param_1 + 8);
uStack_70._4_4_ = *(int4 *)(param_1 + 0xc);
uStack_68._0_4_ = *(int4 *)(param_1 + 0x10);
uStack_68._4_4_ = *(int4 *)(param_1 + 0x14);
uStack_60._0_4_ = *(int4 *)(param_1 + 0x18);
uStack_60._4_4_ = *(int4 *)(param_1 + 0x1c);
}
*(int4 *)(this + 0x40) = (int4)uStack_78;
*(int4 *)(this + 0x44) = uStack_78._4_4_;
*(int4 *)(this + 0x48) = (int4)uStack_70;
*(int4 *)(this + 0x4c) = uStack_70._4_4_;
*(int4 *)(this + 0x50) = (int4)uStack_68;
*(int4 *)(this + 0x54) = uStack_68._4_4_;
*(int4 *)(this + 0x58) = (int4)uStack_60;
*(int4 *)(this + 0x5c) = uStack_60._4_4_;
return this;
}
| |
23,310 | find_hashed_shape_proto | bluesky950520[P]quickjs/quickjs.c | static JSShape *find_hashed_shape_proto(JSRuntime *rt, JSObject *proto)
{
JSShape *sh1;
uint32_t h, h1;
h = shape_initial_hash(proto);
h1 = get_shape_hash(h, rt->shape_hash_bits);
for(sh1 = rt->shape_hash[h1]; sh1 != NULL; sh1 = sh1->shape_hash_next) {
if (sh1->hash == h &&
sh1->proto == proto &&
sh1->prop_count == 0) {
return sh1;
}
}
return NULL;
} | O0 | c | find_hashed_shape_proto:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq %rsi, 0x10(%rsp)
movq 0x10(%rsp), %rdi
callq 0x63bb0
movl %eax, 0x4(%rsp)
movl 0x4(%rsp), %edi
movq 0x18(%rsp), %rax
movl 0x184(%rax), %esi
callq 0x63b80
movl %eax, (%rsp)
movq 0x18(%rsp), %rax
movq 0x190(%rax), %rax
movl (%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rsp)
je 0x3032a
movq 0x8(%rsp), %rax
movl 0x1c(%rax), %eax
cmpl 0x4(%rsp), %eax
jne 0x30318
movq 0x8(%rsp), %rax
movq 0x38(%rax), %rax
cmpq 0x10(%rsp), %rax
jne 0x30318
movq 0x8(%rsp), %rax
cmpl $0x0, 0x28(%rax)
jne 0x30318
movq 0x8(%rsp), %rax
movq %rax, 0x20(%rsp)
jmp 0x30333
jmp 0x3031a
movq 0x8(%rsp), %rax
movq 0x30(%rax), %rax
movq %rax, 0x8(%rsp)
jmp 0x302db
movq $0x0, 0x20(%rsp)
movq 0x20(%rsp), %rax
addq $0x28, %rsp
retq
nopl (%rax)
| find_hashed_shape_proto:
sub rsp, 28h
mov [rsp+28h+var_10], rdi
mov [rsp+28h+var_18], rsi
mov rdi, [rsp+28h+var_18]
call shape_initial_hash
mov [rsp+28h+var_24], eax
mov edi, [rsp+28h+var_24]
mov rax, [rsp+28h+var_10]
mov esi, [rax+184h]
call get_shape_hash
mov [rsp+28h+var_28], eax
mov rax, [rsp+28h+var_10]
mov rax, [rax+190h]
mov ecx, [rsp+28h+var_28]
mov rax, [rax+rcx*8]
mov [rsp+28h+var_20], rax
loc_302DB:
cmp [rsp+28h+var_20], 0
jz short loc_3032A
mov rax, [rsp+28h+var_20]
mov eax, [rax+1Ch]
cmp eax, [rsp+28h+var_24]
jnz short loc_30318
mov rax, [rsp+28h+var_20]
mov rax, [rax+38h]
cmp rax, [rsp+28h+var_18]
jnz short loc_30318
mov rax, [rsp+28h+var_20]
cmp dword ptr [rax+28h], 0
jnz short loc_30318
mov rax, [rsp+28h+var_20]
mov [rsp+28h+var_8], rax
jmp short loc_30333
loc_30318:
jmp short $+2
loc_3031A:
mov rax, [rsp+28h+var_20]
mov rax, [rax+30h]
mov [rsp+28h+var_20], rax
jmp short loc_302DB
loc_3032A:
mov [rsp+28h+var_8], 0
loc_30333:
mov rax, [rsp+28h+var_8]
add rsp, 28h
retn
| long long find_hashed_shape_proto(long long a1, long long a2)
{
unsigned int v3; // [rsp+4h] [rbp-24h]
long long i; // [rsp+8h] [rbp-20h]
v3 = shape_initial_hash(a2);
for ( i = *(_QWORD *)(*(_QWORD *)(a1 + 400) + 8LL * (unsigned int)get_shape_hash(v3, *(unsigned int *)(a1 + 388)));
i;
i = *(_QWORD *)(i + 48) )
{
if ( *(_DWORD *)(i + 28) == v3 && *(_QWORD *)(i + 56) == a2 && !*(_DWORD *)(i + 40) )
return i;
}
return 0LL;
}
| find_hashed_shape_proto:
SUB RSP,0x28
MOV qword ptr [RSP + 0x18],RDI
MOV qword ptr [RSP + 0x10],RSI
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x00163bb0
MOV dword ptr [RSP + 0x4],EAX
MOV EDI,dword ptr [RSP + 0x4]
MOV RAX,qword ptr [RSP + 0x18]
MOV ESI,dword ptr [RAX + 0x184]
CALL 0x00163b80
MOV dword ptr [RSP],EAX
MOV RAX,qword ptr [RSP + 0x18]
MOV RAX,qword ptr [RAX + 0x190]
MOV ECX,dword ptr [RSP]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RSP + 0x8],RAX
LAB_001302db:
CMP qword ptr [RSP + 0x8],0x0
JZ 0x0013032a
MOV RAX,qword ptr [RSP + 0x8]
MOV EAX,dword ptr [RAX + 0x1c]
CMP EAX,dword ptr [RSP + 0x4]
JNZ 0x00130318
MOV RAX,qword ptr [RSP + 0x8]
MOV RAX,qword ptr [RAX + 0x38]
CMP RAX,qword ptr [RSP + 0x10]
JNZ 0x00130318
MOV RAX,qword ptr [RSP + 0x8]
CMP dword ptr [RAX + 0x28],0x0
JNZ 0x00130318
MOV RAX,qword ptr [RSP + 0x8]
MOV qword ptr [RSP + 0x20],RAX
JMP 0x00130333
LAB_00130318:
JMP 0x0013031a
LAB_0013031a:
MOV RAX,qword ptr [RSP + 0x8]
MOV RAX,qword ptr [RAX + 0x30]
MOV qword ptr [RSP + 0x8],RAX
JMP 0x001302db
LAB_0013032a:
MOV qword ptr [RSP + 0x20],0x0
LAB_00130333:
MOV RAX,qword ptr [RSP + 0x20]
ADD RSP,0x28
RET
|
long find_hashed_shape_proto(long param_1,long param_2)
{
int iVar1;
uint uVar2;
long local_20;
iVar1 = shape_initial_hash(param_2);
uVar2 = get_shape_hash(iVar1,*(int4 *)(param_1 + 0x184));
local_20 = *(long *)(*(long *)(param_1 + 400) + (ulong)uVar2 * 8);
while( true ) {
if (local_20 == 0) {
return 0;
}
if (((*(int *)(local_20 + 0x1c) == iVar1) && (*(long *)(local_20 + 0x38) == param_2)) &&
(*(int *)(local_20 + 0x28) == 0)) break;
local_20 = *(long *)(local_20 + 0x30);
}
return local_20;
}
| |
23,311 | find_tag | bluesky950520[P]quickjs/run-test262.c | static char *find_tag(char *desc, const char *tag, int *state)
{
char *p;
p = strstr(desc, tag);
if (p) {
p += strlen(tag);
*state = 0;
}
return p;
} | O0 | c | find_tag:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq %rdx, 0x10(%rsp)
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0xe9f0
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rsp)
je 0x130de
movq 0x18(%rsp), %rdi
callq 0xe260
addq 0x8(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rax
movl $0x0, (%rax)
movq 0x8(%rsp), %rax
addq $0x28, %rsp
retq
nopl (%rax,%rax)
| find_tag:
sub rsp, 28h
mov [rsp+28h+var_8], rdi
mov [rsp+28h+var_10], rsi
mov [rsp+28h+var_18], rdx
mov rdi, [rsp+28h+var_8]
mov rsi, [rsp+28h+var_10]
call _strstr
mov [rsp+28h+var_20], rax
cmp [rsp+28h+var_20], 0
jz short loc_130DE
mov rdi, [rsp+28h+var_10]
call _strlen
add rax, [rsp+28h+var_20]
mov [rsp+28h+var_20], rax
mov rax, [rsp+28h+var_18]
mov dword ptr [rax], 0
loc_130DE:
mov rax, [rsp+28h+var_20]
add rsp, 28h
retn
| long long find_tag(long long a1, long long a2, _DWORD *a3)
{
long long v4; // [rsp+8h] [rbp-20h]
v4 = strstr(a1, a2);
if ( v4 )
{
v4 += strlen(a2);
*a3 = 0;
}
return v4;
}
| find_tag:
SUB RSP,0x28
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x18],RSI
MOV qword ptr [RSP + 0x10],RDX
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x18]
CALL 0x0010e9f0
MOV qword ptr [RSP + 0x8],RAX
CMP qword ptr [RSP + 0x8],0x0
JZ 0x001130de
MOV RDI,qword ptr [RSP + 0x18]
CALL 0x0010e260
ADD RAX,qword ptr [RSP + 0x8]
MOV qword ptr [RSP + 0x8],RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX],0x0
LAB_001130de:
MOV RAX,qword ptr [RSP + 0x8]
ADD RSP,0x28
RET
|
char * find_tag(char *param_1,char *param_2,int4 *param_3)
{
size_t sVar1;
char *local_20;
local_20 = strstr(param_1,param_2);
if (local_20 != (char *)0x0) {
sVar1 = strlen(param_2);
local_20 = local_20 + sVar1;
*param_3 = 0;
}
return local_20;
}
| |
23,312 | find_tag | bluesky950520[P]quickjs/run-test262.c | static char *find_tag(char *desc, const char *tag, int *state)
{
char *p;
p = strstr(desc, tag);
if (p) {
p += strlen(tag);
*state = 0;
}
return p;
} | O2 | c | find_tag:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r15
callq 0xea30
testq %rax, %rax
je 0x1178d
movq %rax, %r14
movq %r15, %rdi
callq 0xe280
addq %rax, %r14
andl $0x0, (%rbx)
jmp 0x11790
xorl %r14d, %r14d
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
| find_tag:
push r15
push r14
push rbx
mov rbx, rdx
mov r15, rsi
call _strstr
test rax, rax
jz short loc_1178D
mov r14, rax
mov rdi, r15
call _strlen
add r14, rax
and dword ptr [rbx], 0
jmp short loc_11790
loc_1178D:
xor r14d, r14d
loc_11790:
mov rax, r14
pop rbx
pop r14
pop r15
retn
| long long find_tag(long long a1, long long a2, _DWORD *a3)
{
long long v4; // rax
long long v5; // r14
v4 = strstr(a1, a2);
if ( !v4 )
return 0LL;
v5 = strlen(a2) + v4;
*a3 = 0;
return v5;
}
| find_tag:
PUSH R15
PUSH R14
PUSH RBX
MOV RBX,RDX
MOV R15,RSI
CALL 0x0010ea30
TEST RAX,RAX
JZ 0x0011178d
MOV R14,RAX
MOV RDI,R15
CALL 0x0010e280
ADD R14,RAX
AND dword ptr [RBX],0x0
JMP 0x00111790
LAB_0011178d:
XOR R14D,R14D
LAB_00111790:
MOV RAX,R14
POP RBX
POP R14
POP R15
RET
|
char * find_tag(char *param_1,char *param_2,int4 *param_3)
{
char *pcVar1;
size_t sVar2;
pcVar1 = strstr(param_1,param_2);
if (pcVar1 == (char *)0x0) {
pcVar1 = (char *)0x0;
}
else {
sVar2 = strlen(param_2);
pcVar1 = pcVar1 + sVar2;
*param_3 = 0;
}
return pcVar1;
}
| |
23,313 | minja::Parser::parseString[abi:cxx11]() | monkey531[P]llama/common/minja.hpp | std::unique_ptr<std::string> parseString() {
auto doParse = [&](char quote) -> std::unique_ptr<std::string> {
if (it == end || *it != quote) return nullptr;
std::string result;
bool escape = false;
for (++it; it != end; ++it) {
if (escape) {
escape = false;
switch (*it) {
case 'n': result += '\n'; break;
case 'r': result += '\r'; break;
case 't': result += '\t'; break;
case 'b': result += '\b'; break;
case 'f': result += '\f'; break;
case '\\': result += '\\'; break;
default:
if (*it == quote) {
result += quote;
} else {
result += *it;
}
break;
}
} else if (*it == '\\') {
escape = true;
} else if (*it == quote) {
++it;
return std::make_unique<std::string>(std::move(result));
} else {
result += *it;
}
}
return nullptr;
};
consumeSpaces();
if (it == end) return nullptr;
if (*it == '"') return doParse('"');
if (*it == '\'') return doParse('\'');
return nullptr;
} | O3 | cpp | minja::Parser::parseString[abi:cxx11]():
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq %rsi, (%rsp)
movq 0x18(%rsi), %r12
movq 0x20(%rsi), %r15
cmpq %r12, %r15
je 0x8b4e4
movq %rsi, %r14
movsbl (%r15), %edi
callq 0x1b0c0
testl %eax, %eax
je 0x8b4e4
incq %r15
movq %r15, 0x20(%r14)
cmpq %r12, %r15
jne 0x8b4cb
cmpq %r12, %r15
je 0x8b504
movzbl (%r15), %eax
cmpl $0x27, %eax
je 0x8b50d
cmpl $0x22, %eax
jne 0x8b504
movq %rsp, %rsi
movq %rbx, %rdi
movl $0x22, %edx
jmp 0x8b518
movq $0x0, (%rbx)
jmp 0x8b51d
movq %rsp, %rsi
movq %rbx, %rdi
movl $0x27, %edx
callq 0x8b998
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
| _ZN5minja6Parser11parseStringB5cxx11Ev:
push r15
push r14
push r12; __int64
push rbx; int
push rax
mov rbx, rdi
mov [rsp+28h+var_28], rsi; void *
mov r12, [rsi+18h]
mov r15, [rsi+20h]
cmp r15, r12
jz short loc_8B4E4
mov r14, rsi
loc_8B4CB:
movsx edi, byte ptr [r15]
call _isspace
test eax, eax
jz short loc_8B4E4
inc r15
mov [r14+20h], r15
cmp r15, r12
jnz short loc_8B4CB
loc_8B4E4:
cmp r15, r12
jz short loc_8B504
movzx eax, byte ptr [r15]
cmp eax, 27h ; '''
jz short loc_8B50D
cmp eax, 22h ; '"'
jnz short loc_8B504
mov rsi, rsp
mov rdi, rbx
mov edx, 22h ; '"'
jmp short loc_8B518
loc_8B504:
mov qword ptr [rbx], 0
jmp short loc_8B51D
loc_8B50D:
mov rsi, rsp; int
mov rdi, rbx; int
mov edx, 27h ; '''; int
loc_8B518:
call _ZZN5minja6Parser11parseStringB5cxx11EvENKUlcE_clB5cxx11Ec; minja::Parser::parseString(void)::{lambda(char)#1}::operator()(char)
loc_8B51D:
mov rax, rbx
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
| _QWORD * minja::Parser::parseString[abi:cxx11](_QWORD *a1, void *a2, long long a3, int a4, int a5, int a6)
{
char *v6; // r12
unsigned __int8 *i; // r15
int v8; // eax
int v9; // edx
void *v11; // [rsp+0h] [rbp-28h] BYREF
int v12; // [rsp+8h] [rbp-20h]
long long v13; // [rsp+10h] [rbp-18h]
v11 = a2;
v6 = (char *)*((_QWORD *)a2 + 3);
for ( i = (unsigned __int8 *)*((_QWORD *)a2 + 4); i != (unsigned __int8 *)v6; *((_QWORD *)a2 + 4) = ++i )
{
if ( !(unsigned int)isspace((unsigned int)(char)*i) )
break;
}
if ( i != (unsigned __int8 *)v6 )
{
v8 = *i;
if ( v8 == 39 )
{
v9 = 39;
goto LABEL_10;
}
if ( v8 == 34 )
{
v9 = 34;
LABEL_10:
minja::Parser::parseString[abi:cxx11](void)::{lambda(char)#1}::operator()[abi:cxx11](
(int)a1,
(int)&v11,
v9,
a4,
a5,
a6,
v11,
v12,
v13);
return a1;
}
}
*a1 = 0LL;
return a1;
}
| parseString[abi:cxx11]:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV qword ptr [RSP],RSI
MOV R12,qword ptr [RSI + 0x18]
MOV R15,qword ptr [RSI + 0x20]
CMP R15,R12
JZ 0x0018b4e4
MOV R14,RSI
LAB_0018b4cb:
MOVSX EDI,byte ptr [R15]
CALL 0x0011b0c0
TEST EAX,EAX
JZ 0x0018b4e4
INC R15
MOV qword ptr [R14 + 0x20],R15
CMP R15,R12
JNZ 0x0018b4cb
LAB_0018b4e4:
CMP R15,R12
JZ 0x0018b504
MOVZX EAX,byte ptr [R15]
CMP EAX,0x27
JZ 0x0018b50d
CMP EAX,0x22
JNZ 0x0018b504
MOV RSI,RSP
MOV RDI,RBX
MOV EDX,0x22
JMP 0x0018b518
LAB_0018b504:
MOV qword ptr [RBX],0x0
JMP 0x0018b51d
LAB_0018b50d:
MOV RSI,RSP
MOV RDI,RBX
MOV EDX,0x27
LAB_0018b518:
CALL 0x0018b998
LAB_0018b51d:
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
|
/* minja::Parser::parseString[abi:cxx11]() */
void minja::Parser::parseString_abi_cxx11_(void)
{
char *pcVar1;
int iVar2;
long in_RSI;
int8 *in_RDI;
char *pcVar3;
pcVar1 = *(char **)(in_RSI + 0x18);
pcVar3 = *(char **)(in_RSI + 0x20);
while ((pcVar3 != pcVar1 && (iVar2 = isspace((int)*pcVar3), iVar2 != 0))) {
pcVar3 = pcVar3 + 1;
*(char **)(in_RSI + 0x20) = pcVar3;
}
if ((pcVar3 == pcVar1) || ((*pcVar3 != '\'' && (*pcVar3 != '\"')))) {
*in_RDI = 0;
}
else {
parseString[abi:cxx11]()::{lambda(char)#1}::operator()[abi_cxx11_((char)in_RDI);
}
return;
}
| |
23,314 | fmt::v11::basic_appender<char> fmt::v11::detail::write<char, fmt::v11::basic_appender<char>, unsigned int, 0>(fmt::v11::basic_appender<char>, unsigned int) | zkingston[P]unknot/build_O1/_deps/fmt-src/include/fmt/format.h | FMT_CONSTEXPR auto write(OutputIt out, T value) -> OutputIt {
auto abs_value = static_cast<uint32_or_64_or_128_t<T>>(value);
bool negative = is_negative(value);
// Don't do -abs_value since it trips unsigned-integer-overflow sanitizer.
if (negative) abs_value = ~abs_value + 1;
int num_digits = count_digits(abs_value);
auto size = (negative ? 1 : 0) + static_cast<size_t>(num_digits);
if (auto ptr = to_pointer<Char>(out, size)) {
if (negative) *ptr++ = static_cast<Char>('-');
format_decimal<Char>(ptr, abs_value, num_digits);
return out;
}
if (negative) *out++ = static_cast<Char>('-');
return format_decimal<Char>(out, abs_value, num_digits);
} | O1 | c | fmt::v11::basic_appender<char> fmt::v11::detail::write<char, fmt::v11::basic_appender<char>, unsigned int, 0>(fmt::v11::basic_appender<char>, unsigned int):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r12
movq %rsi, %rbx
movq %rdi, %r14
testq %rdx, %rdx
js 0x4026b
movq %r12, %r15
jmp 0x40274
xorl %r15d, %r15d
negq %rbx
sbbq %r12, %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4038c
movl %eax, %ebp
movq %r12, %rax
shrq $0x3f, %rax
movslq %ebp, %rsi
addq %rax, %rsi
movq %r14, %rdi
callq 0x3fec6
testq %rax, %rax
je 0x402d5
movq %rax, %r13
testq %r12, %r12
js 0x402a8
movq %r13, %rdi
jmp 0x402b1
leaq 0x1(%r13), %rdi
movb $0x2d, (%r13)
movq %rbx, %rsi
movq %r15, %rdx
movl %ebp, %ecx
callq 0x40434
testq %r13, %r13
je 0x402d5
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
testq %r12, %r12
jns 0x40301
movq 0x8(%r14), %rsi
incq %rsi
cmpq %rsi, 0x10(%r14)
jae 0x402ee
movq %r14, %rdi
callq *0x18(%r14)
movq (%r14), %rax
movq 0x8(%r14), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, 0x8(%r14)
movb $0x2d, (%rax,%rcx)
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
movl %ebp, %ecx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x4031f
| _ZN3fmt3v116detail5writeIcNS0_14basic_appenderIcEEnTnNSt9enable_ifIXaaaasr11is_integralIT1_EE5valuentsr3std7is_sameIS6_bEE5valuentsr3std7is_sameIS6_T_EE5valueEiE4typeELi0EEET0_SA_S6_:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r12, rdx
mov rbx, rsi
mov r14, rdi
test rdx, rdx
js short loc_4026B
mov r15, r12
jmp short loc_40274
loc_4026B:
xor r15d, r15d
neg rbx
sbb r15, r12
loc_40274:
mov rdi, rbx
mov rsi, r15
call _ZN3fmt3v116detail21count_digits_fallbackIoEEiT_; fmt::v11::detail::count_digits_fallback<unsigned __int128>(unsigned __int128)
mov ebp, eax
mov rax, r12
shr rax, 3Fh
movsxd rsi, ebp
add rsi, rax
mov rdi, r14
call _ZN3fmt3v116detail10to_pointerIcEEPT_NS0_14basic_appenderIS3_EEm; fmt::v11::detail::to_pointer<char>(fmt::v11::basic_appender<char>,ulong)
test rax, rax
jz short loc_402D5
mov r13, rax
test r12, r12
js short loc_402A8
mov rdi, r13
jmp short loc_402B1
loc_402A8:
lea rdi, [r13+1]
mov byte ptr [r13+0], 2Dh ; '-'
loc_402B1:
mov rsi, rbx
mov rdx, r15
mov ecx, ebp
call _ZN3fmt3v116detail17do_format_decimalIcoEEPT_S4_T0_i; fmt::v11::detail::do_format_decimal<char,unsigned __int128>(char *,unsigned __int128,int)
test r13, r13
jz short loc_402D5
mov rax, r14
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_402D5:
test r12, r12
jns short loc_40301
mov rsi, [r14+8]
inc rsi
cmp [r14+10h], rsi
jnb short loc_402EE
mov rdi, r14
call qword ptr [r14+18h]
loc_402EE:
mov rax, [r14]
mov rcx, [r14+8]
lea rdx, [rcx+1]
mov [r14+8], rdx
mov byte ptr [rax+rcx], 2Dh ; '-'
loc_40301:
mov rdi, r14
mov rsi, rbx
mov rdx, r15
mov ecx, ebp
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp $+5
| long long ZN3fmt3v116detail5writeIcNS0_14basic_appenderIcEEnTnNSt9enable_ifIXaaaasr11is_integralIT1_EE5valuentsr3std7is_sameIS6_bEE5valuentsr3std7is_sameIS6_T_EE5valueEiE4typeELi0EEET0_SA_S6_(
long long a1,
unsigned long long a2,
long long a3)
{
long long v4; // rbx
long long v6; // r15
unsigned int v7; // ebp
_BYTE *v8; // rax
_BYTE *v9; // rdi
long long v11; // rax
long long v12; // rcx
v4 = a2;
if ( a3 < 0 )
{
v4 = -(long long)a2;
v6 = (unsigned __int128)-(__int128)__PAIR128__(a3, a2) >> 64;
}
else
{
v6 = a3;
}
v7 = fmt::v11::detail::count_digits_fallback<unsigned __int128>(v4, v6);
v8 = (_BYTE *)fmt::v11::detail::to_pointer<char>(a1, ((unsigned long long)a3 >> 63) + (int)v7);
if ( v8 )
{
if ( a3 < 0 )
{
v9 = v8 + 1;
*v8 = 45;
}
else
{
v9 = v8;
}
fmt::v11::detail::do_format_decimal<char,unsigned __int128>(v9, v4, v6, v7);
return a1;
}
else
{
if ( a3 < 0 )
{
if ( *(_QWORD *)(a1 + 16) < (unsigned long long)(*(_QWORD *)(a1 + 8) + 1LL) )
(*(void ( **)(long long))(a1 + 24))(a1);
v11 = *(_QWORD *)a1;
v12 = *(_QWORD *)(a1 + 8);
*(_QWORD *)(a1 + 8) = v12 + 1;
*(_BYTE *)(v11 + v12) = 45;
}
return ZN3fmt3v116detail14format_decimalIcoNS0_14basic_appenderIcEETnNSt9enable_ifIXntsr3std10is_pointerINSt9remove_cvINSt16remove_referenceIT1_E4typeEE4typeEEE5valueEiE4typeELi0EEES8_S8_T0_i(
a1,
v4,
v6,
v7);
}
}
| _ZN3fmt3v116detail5writeIcNS0_14basic_appenderIcEEnTnNSt9enable_ifIXaaaasr11is_integralIT1_EE5valuentsr3std7is_sameIS6_bEE5valuentsr3std7is_sameIS6_T_EE5valueEiE4typeELi0EEET0_SA_S6_:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R12,RDX
MOV RBX,RSI
MOV R14,RDI
TEST RDX,RDX
JS 0x0014026b
MOV R15,R12
JMP 0x00140274
LAB_0014026b:
XOR R15D,R15D
NEG RBX
SBB R15,R12
LAB_00140274:
MOV RDI,RBX
MOV RSI,R15
CALL 0x0014038c
MOV EBP,EAX
MOV RAX,R12
SHR RAX,0x3f
MOVSXD RSI,EBP
ADD RSI,RAX
MOV RDI,R14
CALL 0x0013fec6
TEST RAX,RAX
JZ 0x001402d5
MOV R13,RAX
TEST R12,R12
JS 0x001402a8
MOV RDI,R13
JMP 0x001402b1
LAB_001402a8:
LEA RDI,[R13 + 0x1]
MOV byte ptr [R13],0x2d
LAB_001402b1:
MOV RSI,RBX
MOV RDX,R15
MOV ECX,EBP
CALL 0x00140434
TEST R13,R13
JZ 0x001402d5
MOV RAX,R14
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001402d5:
TEST R12,R12
JNS 0x00140301
MOV RSI,qword ptr [R14 + 0x8]
INC RSI
CMP qword ptr [R14 + 0x10],RSI
JNC 0x001402ee
MOV RDI,R14
CALL qword ptr [R14 + 0x18]
LAB_001402ee:
MOV RAX,qword ptr [R14]
MOV RCX,qword ptr [R14 + 0x8]
LEA RDX,[RCX + 0x1]
MOV qword ptr [R14 + 0x8],RDX
MOV byte ptr [RAX + RCX*0x1],0x2d
LAB_00140301:
MOV RDI,R14
MOV RSI,RBX
MOV RDX,R15
MOV ECX,EBP
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x0014031f
|
long * _ZN3fmt3v116detail5writeIcNS0_14basic_appenderIcEEnTnNSt9enable_ifIXaaaasr11is_integralIT1_EE5valuentsr3std7is_sameIS6_bEE5valuentsr3std7is_sameIS6_T_EE5valueEiE4typeELi0EEET0_SA_S6_
(long *param_1,detail *param_2,long param_3)
{
long lVar1;
int iVar2;
detail *pdVar3;
long *plVar4;
detail *this;
long lVar5;
bool bVar6;
lVar5 = param_3;
if (param_3 < 0) {
bVar6 = param_2 != (detail *)0x0;
param_2 = (detail *)-(long)param_2;
lVar5 = -(ulong)bVar6 - param_3;
}
iVar2 = fmt::v11::detail::count_digits_fallback<unsigned__int128>(param_2,(uint)lVar5);
pdVar3 = (detail *)fmt::v11::detail::to_pointer<char>(param_1,(long)iVar2 - (param_3 >> 0x3f));
if (pdVar3 != (detail *)0x0) {
this = pdVar3;
if (param_3 < 0) {
*pdVar3 = (detail)0x2d;
this = pdVar3 + 1;
}
fmt::v11::detail::do_format_decimal<char,unsigned__int128>
(this,(char *)param_2,(uint)lVar5,iVar2);
if (pdVar3 != (detail *)0x0) {
return param_1;
}
}
if (param_3 < 0) {
if ((ulong)param_1[2] < param_1[1] + 1U) {
(*(code *)param_1[3])(param_1);
}
lVar1 = param_1[1];
param_1[1] = lVar1 + 1;
*(int1 *)(*param_1 + lVar1) = 0x2d;
}
plVar4 = (long *)_ZN3fmt3v116detail14format_decimalIcoNS0_14basic_appenderIcEETnNSt9enable_ifIXntsr3std10is_pointerINSt9remove_cvINSt16remove_referenceIT1_E4typeEE4typeEEE5valueEiE4typeELi0EEES8_S8_T0_i
(param_1,param_2,lVar5,iVar2);
return plVar4;
}
| |
23,315 | alaya::FindExactGTTest_BasicFunctionality_Test::~FindExactGTTest_BasicFunctionality_Test() | AlayaLite/tests/utils/evaluate_test.cpp | TEST(FindExactGTTest, BasicFunctionality) {
std::vector<float> queries = {1.0, 2.0, 3.0};
std::vector<float> data = {3.0, 2.0, 1.0, 4.0, 5.0, 6.0};
uint32_t dim = 3;
uint32_t topk = 2;
auto result = find_exact_gt(queries, data, dim, topk);
ASSERT_EQ(result.size(), 2);
EXPECT_EQ(result[0], 0); // Closest point
EXPECT_EQ(result[1], 1); // Second closest
} | O0 | cpp | alaya::FindExactGTTest_BasicFunctionality_Test::~FindExactGTTest_BasicFunctionality_Test():
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0xc5960
movq 0x8(%rsp), %rax
leaq 0x14aafc(%rip), %rcx # 0x174280
addq $0x10, %rcx
movq %rcx, (%rax)
addq $0x18, %rsp
retq
| _ZN5alaya39FindExactGTTest_BasicFunctionality_TestC2Ev:
sub rsp, 18h
mov [rsp+18h+var_8], rdi
mov rdi, [rsp+18h+var_8]; this
mov [rsp+18h+var_10], rdi
call _ZN7testing4TestC2Ev; testing::Test::Test(void)
mov rax, [rsp+18h+var_10]
lea rcx, _ZTVN5alaya39FindExactGTTest_BasicFunctionality_TestE; `vtable for'alaya::FindExactGTTest_BasicFunctionality_Test
add rcx, 10h
mov [rax], rcx
add rsp, 18h
retn
| alaya::FindExactGTTest_BasicFunctionality_Test * alaya::FindExactGTTest_BasicFunctionality_Test::FindExactGTTest_BasicFunctionality_Test(
alaya::FindExactGTTest_BasicFunctionality_Test *this)
{
alaya::FindExactGTTest_BasicFunctionality_Test *result; // rax
testing::Test::Test(this);
result = this;
*(_QWORD *)this = &`vtable for'alaya::FindExactGTTest_BasicFunctionality_Test + 2;
return result;
}
| FindExactGTTest_BasicFunctionality_Test:
SUB RSP,0x18
MOV qword ptr [RSP + 0x10],RDI
MOV RDI,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x8],RDI
CALL 0x001c5960
MOV RAX,qword ptr [RSP + 0x8]
LEA RCX,[0x274280]
ADD RCX,0x10
MOV qword ptr [RAX],RCX
ADD RSP,0x18
RET
|
/* alaya::FindExactGTTest_BasicFunctionality_Test::FindExactGTTest_BasicFunctionality_Test() */
void __thiscall
alaya::FindExactGTTest_BasicFunctionality_Test::FindExactGTTest_BasicFunctionality_Test
(FindExactGTTest_BasicFunctionality_Test *this)
{
testing::Test::Test((Test *)this);
*(int ***)this = &PTR__FindExactGTTest_BasicFunctionality_Test_00274290;
return;
}
| |
23,316 | my_xml_attr_ensure_space | eloqsql/strings/xml.c | static int my_xml_attr_ensure_space(MY_XML_PARSER *st, size_t len)
{
size_t ofs= st->attr.end - st->attr.start;
len++; // Add terminating zero.
if (ofs + len > st->attr.buffer_size)
{
st->attr.buffer_size= (SIZE_T_MAX - len) / 2 > st->attr.buffer_size ?
st->attr.buffer_size * 2 + len : SIZE_T_MAX;
if (!st->attr.buffer)
{
st->attr.buffer= (char *) my_malloc(PSI_INSTRUMENT_ME, st->attr.buffer_size, MYF(0));
if (st->attr.buffer)
memcpy(st->attr.buffer, st->attr.static_buffer, ofs + 1 /*term. zero */);
}
else
st->attr.buffer= (char *) my_realloc(PSI_INSTRUMENT_ME, st->attr.buffer,
st->attr.buffer_size, MYF(0));
st->attr.start= st->attr.buffer;
st->attr.end= st->attr.start + ofs;
return st->attr.buffer ? MY_XML_OK : MY_XML_ERROR;
}
return MY_XML_OK;
} | O0 | c | my_xml_attr_ensure_space:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x120(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x118(%rcx), %rcx
subq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
movq -0x20(%rbp), %rax
addq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x110(%rcx), %rax
jbe 0x78e03
movq $-0x1, %rax
subq -0x18(%rbp), %rax
shrq %rax
movq -0x10(%rbp), %rcx
cmpq 0x110(%rcx), %rax
jbe 0x78d05
movq -0x10(%rbp), %rax
movq 0x110(%rax), %rax
shlq %rax
addq -0x18(%rbp), %rax
movq %rax, -0x28(%rbp)
jmp 0x78d12
movq $-0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x78d12
movq -0x28(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x110(%rax)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x108(%rax)
jne 0x78d86
movq -0x10(%rbp), %rax
movq 0x110(%rax), %rsi
xorl %edi, %edi
xorl %eax, %eax
movl %eax, %edx
callq 0x2f560
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x108(%rax)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x108(%rax)
je 0x78d84
movq -0x10(%rbp), %rax
movq 0x108(%rax), %rdi
movq -0x10(%rbp), %rsi
addq $0x88, %rsi
movq -0x20(%rbp), %rdx
addq $0x1, %rdx
callq 0x24230
jmp 0x78db5
movq -0x10(%rbp), %rax
movq 0x108(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x110(%rax), %rdx
xorl %edi, %edi
xorl %eax, %eax
movl %eax, %ecx
callq 0x2f730
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x108(%rax)
movq -0x10(%rbp), %rax
movq 0x108(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x118(%rax)
movq -0x10(%rbp), %rax
movq 0x118(%rax), %rcx
addq -0x20(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x120(%rax)
movq -0x10(%rbp), %rax
movq 0x108(%rax), %rdx
movl $0x1, %eax
xorl %ecx, %ecx
cmpq $0x0, %rdx
cmovnel %ecx, %eax
movl %eax, -0x4(%rbp)
jmp 0x78e0a
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
| my_xml_attr_ensure_space:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rax, [rbp+var_10]
mov rax, [rax+120h]
mov rcx, [rbp+var_10]
mov rcx, [rcx+118h]
sub rax, rcx
mov [rbp+var_20], rax
mov rax, [rbp+var_18]
add rax, 1
mov [rbp+var_18], rax
mov rax, [rbp+var_20]
add rax, [rbp+var_18]
mov rcx, [rbp+var_10]
cmp rax, [rcx+110h]
jbe loc_78E03
mov rax, 0FFFFFFFFFFFFFFFFh
sub rax, [rbp+var_18]
shr rax, 1
mov rcx, [rbp+var_10]
cmp rax, [rcx+110h]
jbe short loc_78D05
mov rax, [rbp+var_10]
mov rax, [rax+110h]
shl rax, 1
add rax, [rbp+var_18]
mov [rbp+var_28], rax
jmp short loc_78D12
loc_78D05:
mov rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_28], rax
jmp short $+2
loc_78D12:
mov rcx, [rbp+var_28]
mov rax, [rbp+var_10]
mov [rax+110h], rcx
mov rax, [rbp+var_10]
cmp qword ptr [rax+108h], 0
jnz short loc_78D86
mov rax, [rbp+var_10]
mov rsi, [rax+110h]
xor edi, edi
xor eax, eax
mov edx, eax
call my_malloc
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+108h], rcx
mov rax, [rbp+var_10]
cmp qword ptr [rax+108h], 0
jz short loc_78D84
mov rax, [rbp+var_10]
mov rdi, [rax+108h]
mov rsi, [rbp+var_10]
add rsi, 88h
mov rdx, [rbp+var_20]
add rdx, 1
call _memcpy
loc_78D84:
jmp short loc_78DB5
loc_78D86:
mov rax, [rbp+var_10]
mov rsi, [rax+108h]
mov rax, [rbp+var_10]
mov rdx, [rax+110h]
xor edi, edi
xor eax, eax
mov ecx, eax
call my_realloc
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+108h], rcx
loc_78DB5:
mov rax, [rbp+var_10]
mov rcx, [rax+108h]
mov rax, [rbp+var_10]
mov [rax+118h], rcx
mov rax, [rbp+var_10]
mov rcx, [rax+118h]
add rcx, [rbp+var_20]
mov rax, [rbp+var_10]
mov [rax+120h], rcx
mov rax, [rbp+var_10]
mov rdx, [rax+108h]
mov eax, 1
xor ecx, ecx
cmp rdx, 0
cmovnz eax, ecx
mov [rbp+var_4], eax
jmp short loc_78E0A
loc_78E03:
mov [rbp+var_4], 0
loc_78E0A:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
| _BOOL8 my_xml_attr_ensure_space(_QWORD *a1, long long a2)
{
long long v3; // [rsp+8h] [rbp-28h]
long long v4; // [rsp+10h] [rbp-20h]
long long v5; // [rsp+18h] [rbp-18h]
v4 = a1[36] - a1[35];
v5 = a2 + 1;
if ( (unsigned long long)(a2 + 1 + v4) <= a1[34] )
{
return 0;
}
else
{
if ( (unsigned long long)(-1 - v5) >> 1 <= a1[34] )
v3 = -1LL;
else
v3 = v5 + 2LL * a1[34];
a1[34] = v3;
if ( a1[33] )
{
a1[33] = my_realloc(0, a1[33], a1[34], 0);
}
else
{
a1[33] = my_malloc(0, a1[34], 0);
if ( a1[33] )
memcpy(a1[33], a1 + 17, v4 + 1);
}
a1[35] = a1[33];
a1[36] = v4 + a1[35];
return a1[33] == 0LL;
}
}
| my_xml_attr_ensure_space:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x120]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x118]
SUB RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x1
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RCX + 0x110]
JBE 0x00178e03
MOV RAX,-0x1
SUB RAX,qword ptr [RBP + -0x18]
SHR RAX,0x1
MOV RCX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RCX + 0x110]
JBE 0x00178d05
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x110]
SHL RAX,0x1
ADD RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x28],RAX
JMP 0x00178d12
LAB_00178d05:
MOV RAX,-0x1
MOV qword ptr [RBP + -0x28],RAX
JMP 0x00178d12
LAB_00178d12:
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x110],RCX
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x108],0x0
JNZ 0x00178d86
MOV RAX,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RAX + 0x110]
XOR EDI,EDI
XOR EAX,EAX
MOV EDX,EAX
CALL 0x0012f560
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x108],RCX
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x108],0x0
JZ 0x00178d84
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX + 0x108]
MOV RSI,qword ptr [RBP + -0x10]
ADD RSI,0x88
MOV RDX,qword ptr [RBP + -0x20]
ADD RDX,0x1
CALL 0x00124230
LAB_00178d84:
JMP 0x00178db5
LAB_00178d86:
MOV RAX,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RAX + 0x108]
MOV RAX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RAX + 0x110]
XOR EDI,EDI
XOR EAX,EAX
MOV ECX,EAX
CALL 0x0012f730
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x108],RCX
LAB_00178db5:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x108]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x118],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x118]
ADD RCX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x120],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RAX + 0x108]
MOV EAX,0x1
XOR ECX,ECX
CMP RDX,0x0
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x4],EAX
JMP 0x00178e0a
LAB_00178e03:
MOV dword ptr [RBP + -0x4],0x0
LAB_00178e0a:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
bool my_xml_attr_ensure_space(long param_1,long param_2)
{
long lVar1;
int8 uVar2;
bool bVar3;
long local_30;
lVar1 = *(long *)(param_1 + 0x120) - *(long *)(param_1 + 0x118);
param_2 = param_2 + 1;
if (*(ulong *)(param_1 + 0x110) < (ulong)(lVar1 + param_2)) {
if (*(ulong *)(param_1 + 0x110) < -param_2 - 1U >> 1) {
local_30 = *(long *)(param_1 + 0x110) * 2 + param_2;
}
else {
local_30 = -1;
}
*(long *)(param_1 + 0x110) = local_30;
if (*(long *)(param_1 + 0x108) == 0) {
uVar2 = my_malloc(0,*(int8 *)(param_1 + 0x110),0);
*(int8 *)(param_1 + 0x108) = uVar2;
if (*(long *)(param_1 + 0x108) != 0) {
memcpy(*(void **)(param_1 + 0x108),(void *)(param_1 + 0x88),lVar1 + 1);
}
}
else {
uVar2 = my_realloc(0,*(int8 *)(param_1 + 0x108),*(int8 *)(param_1 + 0x110),0);
*(int8 *)(param_1 + 0x108) = uVar2;
}
*(int8 *)(param_1 + 0x118) = *(int8 *)(param_1 + 0x108);
*(long *)(param_1 + 0x120) = *(long *)(param_1 + 0x118) + lVar1;
bVar3 = *(long *)(param_1 + 0x108) == 0;
}
else {
bVar3 = false;
}
return bVar3;
}
| |
23,317 | nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>) | 7CodeWizard[P]stablediffusion/thirdparty/json.hpp | reference operator[](typename object_t::key_type key)
{
// implicitly convert null value to an empty object
if (is_null())
{
m_type = value_t::object;
m_value.object = create<object_t>();
assert_invariant();
}
// operator[] only works for objects
if (JSON_HEDLEY_LIKELY(is_object()))
{
auto result = m_value.object->emplace(std::move(key), nullptr);
return set_parent(result.first->second);
}
JSON_THROW(type_error::create(305, detail::concat("cannot use operator[] with a string argument with ", type_name()), this));
} | O2 | cpp | nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movb (%rdi), %al
testb %al, %al
jne 0x54d36
movb $0x1, (%r14)
callq 0x4dfb8
movq %rax, 0x8(%r14)
movb (%r14), %al
cmpb $0x1, %al
jne 0x54d5c
movq 0x8(%r14), %rdi
leaq 0x10(%rsp), %rdx
andq $0x0, (%rdx)
movq %rbx, %rsi
callq 0x54e3e
addq $0x40, %rax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
pushq $0x20
popq %rdi
callq 0xa270
movq %rax, %rbx
movq %r14, %rdi
callq 0x4bba0
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
leaq 0x4a409(%rip), %rsi # 0x9f187
leaq 0x10(%rsp), %rdi
callq 0x54ddf
movb $0x1, %bpl
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
movl $0x131, %esi # imm = 0x131
movq %r14, %rcx
callq 0x51cae
xorl %ebp, %ebp
leaq 0x8011f(%rip), %rsi # 0xd4ec8
leaq -0x5208(%rip), %rdx # 0x4fba8
movq %rbx, %rdi
callq 0xaa50
movq %rax, %r14
leaq 0x10(%rsp), %rdi
callq 0xac60
testb %bpl, %bpl
jne 0x54dcf
jmp 0x54dd7
movq %rax, %r14
movq %rbx, %rdi
callq 0xa410
movq %r14, %rdi
callq 0xaab0
| _ZN8nlohmann16json_abi_v3_11_210basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEEixES9_:
push rbp; char
push r14; int
push rbx; int
sub rsp, 30h
mov rbx, rsi
mov r14, rdi
mov al, [rdi]
test al, al
jnz short loc_54D36
mov byte ptr [r14], 1
call _ZN8nlohmann16json_abi_v3_11_210basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEE6createIS2_IS9_SD_St4lessIvESaISt4pairIKS9_SD_EEEJEEEPT_DpOT0_; nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>::create<std::map<std::string,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>>()
mov [r14+8], rax
mov al, [r14]
loc_54D36:
cmp al, 1
jnz short loc_54D5C
mov rdi, [r14+8]
lea rdx, [rsp+48h+var_38]
and qword ptr [rdx], 0
mov rsi, rbx
call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_N8nlohmann16json_abi_v3_11_210basic_jsonISt3mapSt6vectorS5_blmdSaNS9_14adl_serializerESC_IhSaIhEEEEESt10_Select1stISH_ESt4lessIvESaISH_EE17_M_emplace_uniqueIJS5_DnEEES6_ISt17_Rb_tree_iteratorISH_EbEDpOT_; std::_Rb_tree<std::string,std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>,std::_Select1st<std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>>>::_M_emplace_unique<std::string,decltype(nullptr)>(std::string,decltype(nullptr) &&)
add rax, 40h ; '@'
add rsp, 30h
pop rbx
pop r14
pop rbp
retn
loc_54D5C:
push 20h ; ' '
pop rdi; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_210basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEE9type_nameEv; nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>::type_name(void)
lea rdx, [rsp+48h+var_40]
mov [rdx], rax
lea rsi, aCannotUseOpera_0; "cannot use operator[] with a string arg"...
lea rdi, [rsp+48h+var_38]
call _ZN8nlohmann16json_abi_v3_11_26detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA51_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_2::detail::concat<std::string,char const(&)[51],char const*>(char const(&)[51],char const* &&)
mov bpl, 1
lea rdx, [rsp+48h+var_38]
mov rdi, rbx; this
mov esi, 131h; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_26detail10type_error6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_26detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_26detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rdi, [rsp+48h+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
jnz short loc_54DCF
jmp short loc_54DD7
mov r14, rax
loc_54DCF:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_54DD7:
mov rdi, r14
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>::operator[](
long long a1,
long long a2)
{
unsigned __int8 v2; // al
long long v3; // rdi
nlohmann::json_abi_v3_11_2::detail::type_error *exception; // rbx
_QWORD v6[7]; // [rsp+10h] [rbp-38h] BYREF
v2 = *(_BYTE *)a1;
if ( !*(_BYTE *)a1 )
{
*(_BYTE *)a1 = 1;
*(_QWORD *)(a1 + 8) = nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>::create<std::map<std::string,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>>();
v2 = *(_BYTE *)a1;
}
if ( v2 != 1 )
{
exception = (nlohmann::json_abi_v3_11_2::detail::type_error *)__cxa_allocate_exception(0x20uLL);
nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>::type_name((unsigned __int8 *)a1);
nlohmann::json_abi_v3_11_2::detail::concat<std::string,char const(&)[51],char const*>(
v6,
"cannot use operator[] with a string argument with ");
ZN8nlohmann16json_abi_v3_11_26detail10type_error6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
exception,
305,
(long long)v6);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_2::detail::type_error,
(void (*)(void *))nlohmann::json_abi_v3_11_2::detail::exception::~exception);
}
v3 = *(_QWORD *)(a1 + 8);
v6[0] = 0LL;
return std::_Rb_tree<std::string,std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>,std::_Select1st<std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>>>::_M_emplace_unique<std::string,decltype(nullptr)>(
v3,
a2,
v6)
+ 64;
}
| operator[]:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV RBX,RSI
MOV R14,RDI
MOV AL,byte ptr [RDI]
TEST AL,AL
JNZ 0x00154d36
MOV byte ptr [R14],0x1
CALL 0x0014dfb8
MOV qword ptr [R14 + 0x8],RAX
MOV AL,byte ptr [R14]
LAB_00154d36:
CMP AL,0x1
JNZ 0x00154d5c
MOV RDI,qword ptr [R14 + 0x8]
LEA RDX,[RSP + 0x10]
AND qword ptr [RDX],0x0
MOV RSI,RBX
CALL 0x00154e3e
ADD RAX,0x40
ADD RSP,0x30
POP RBX
POP R14
POP RBP
RET
LAB_00154d5c:
PUSH 0x20
POP RDI
CALL 0x0010a270
MOV RBX,RAX
MOV RDI,R14
CALL 0x0014bba0
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],RAX
LAB_00154d77:
LEA RSI,[0x19f187]
LEA RDI,[RSP + 0x10]
CALL 0x00154ddf
MOV BPL,0x1
LAB_00154d8b:
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
MOV ESI,0x131
MOV RCX,R14
CALL 0x00151cae
XOR EBP,EBP
LEA RSI,[0x1d4ec8]
LEA RDX,[0x14fba8]
MOV RDI,RBX
CALL 0x0010aa50
|
/* nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::string, bool, long,
unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer,
std::vector<unsigned char, std::allocator<unsigned char> > >::operator[](std::__cxx11::string) */
long __thiscall
nlohmann::json_abi_v3_11_2::
basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>
::operator[](basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>
*this,string *param_2)
{
basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>
bVar1;
map *pmVar2;
long lVar3;
int8 uVar4;
char *local_40;
_func_decltype_nullptr *local_38 [4];
bVar1 = *this;
if (bVar1 == (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>
)0x0) {
*this = (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>
)0x1;
pmVar2 = create<std::map<std::__cxx11::string,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>>>>
();
*(map **)(this + 8) = pmVar2;
bVar1 = *this;
}
if (bVar1 == (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>
)0x1) {
local_38[0] = (_func_decltype_nullptr *)0x0;
lVar3 = std::
_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>,std::_Select1st<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>>>
::_M_emplace_unique<std::__cxx11::string,decltype(nullptr)>
(*(_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>,std::_Select1st<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>>>
**)(this + 8),param_2,local_38);
return lVar3 + 0x40;
}
uVar4 = __cxa_allocate_exception(0x20);
local_40 = (char *)type_name(this);
/* try { // try from 00154d77 to 00154d87 has its CatchHandler @ 00154dcc */
detail::concat<std::__cxx11::string,char_const(&)[51],char_const*>
((detail *)local_38,"cannot use operator[] with a string argument with ",&local_40);
/* try { // try from 00154d8b to 00154db7 has its CatchHandler @ 00154db8 */
_ZN8nlohmann16json_abi_v3_11_26detail10type_error6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar4,0x131,local_38,this);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar4,&detail::type_error::typeinfo,detail::exception::~exception);
}
| |
23,318 | nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>) | 7CodeWizard[P]stablediffusion/thirdparty/json.hpp | reference operator[](typename object_t::key_type key)
{
// implicitly convert null value to an empty object
if (is_null())
{
m_type = value_t::object;
m_value.object = create<object_t>();
assert_invariant();
}
// operator[] only works for objects
if (JSON_HEDLEY_LIKELY(is_object()))
{
auto result = m_value.object->emplace(std::move(key), nullptr);
return set_parent(result.first->second);
}
JSON_THROW(type_error::create(305, detail::concat("cannot use operator[] with a string argument with ", type_name()), this));
} | O3 | cpp | nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movb (%rdi), %al
testb %al, %al
jne 0x77d75
movb $0x1, (%r14)
movl $0x30, %edi
callq 0xa5c0
leaq 0x8(%rax), %rcx
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
xorl %edx, %edx
movq %rdx, 0x10(%rax)
movq %rcx, 0x18(%rax)
movq %rcx, 0x20(%rax)
movq %rdx, 0x28(%rax)
movq %rax, 0x8(%r14)
movb (%r14), %al
cmpb $0x1, %al
jne 0x77d9e
movq 0x8(%r14), %rdi
leaq 0x8(%rsp), %rdx
movq $0x0, (%rdx)
movq %rbx, %rsi
callq 0x77ebc
addq $0x40, %rax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movl $0x20, %edi
callq 0xa270
movq %rax, %rbx
movq %r14, %rdi
callq 0x6e0ae
leaq 0x28(%rsp), %rdx
movq %rax, (%rdx)
leaq 0x4a4c5(%rip), %rsi # 0xc2287
leaq 0x8(%rsp), %rdi
callq 0x77e34
movb $0x1, %bpl
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0x131, %esi # imm = 0x131
movq %r14, %rcx
callq 0x749bc
xorl %ebp, %ebp
leaq 0x7c0eb(%rip), %rsi # 0xf3ed8
leaq -0x5b48(%rip), %rdx # 0x722ac
movq %rbx, %rdi
callq 0xaa70
movq %rax, %r14
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x77e1a
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xa5d0
testb %bpl, %bpl
jne 0x77e24
jmp 0x77e2c
movq %rax, %r14
movq %rbx, %rdi
callq 0xa410
movq %r14, %rdi
callq 0xaad0
| _ZN8nlohmann16json_abi_v3_11_210basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEEixES9_:
push rbp; char
push r14; int
push rbx; __int64
sub rsp, 30h
mov rbx, rsi
mov r14, rdi
mov al, [rdi]
test al, al
jnz short loc_77D75
mov byte ptr [r14], 1
mov edi, 30h ; '0'; unsigned __int64
call __Znwm; operator new(ulong)
lea rcx, [rax+8]
xorps xmm0, xmm0
movups xmmword ptr [rax], xmm0
xor edx, edx
mov [rax+10h], rdx
mov [rax+18h], rcx
mov [rax+20h], rcx
mov [rax+28h], rdx
mov [r14+8], rax
mov al, [r14]
loc_77D75:
cmp al, 1
jnz short loc_77D9E
mov rdi, [r14+8]
lea rdx, [rsp+48h+var_40]
mov qword ptr [rdx], 0
mov rsi, rbx
call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_N8nlohmann16json_abi_v3_11_210basic_jsonISt3mapSt6vectorS5_blmdSaNS9_14adl_serializerESC_IhSaIhEEEEESt10_Select1stISH_ESt4lessIvESaISH_EE17_M_emplace_uniqueIJS5_DnEEES6_ISt17_Rb_tree_iteratorISH_EbEDpOT_; std::_Rb_tree<std::string,std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>,std::_Select1st<std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>>>::_M_emplace_unique<std::string,decltype(nullptr)>(std::string,decltype(nullptr) &&)
add rax, 40h ; '@'
add rsp, 30h
pop rbx
pop r14
pop rbp
retn
loc_77D9E:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_210basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEE9type_nameEv; nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>::type_name(void)
lea rdx, [rsp+48h+var_20]
mov [rdx], rax
lea rsi, aCannotUseOpera_0; "cannot use operator[] with a string arg"...
lea rdi, [rsp+48h+var_40]
call _ZN8nlohmann16json_abi_v3_11_26detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA51_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_2::detail::concat<std::string,char const(&)[51],char const*>(char const(&)[51],char const* &&)
mov bpl, 1
lea rdx, [rsp+48h+var_40]
mov rdi, rbx; this
mov esi, 131h; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_26detail10type_error6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_26detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_26detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+48h+var_30]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_77E1A
mov rsi, [rsp+48h+var_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_77E1A:
test bpl, bpl
jnz short loc_77E24
jmp short loc_77E2C
mov r14, rax
loc_77E24:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_77E2C:
mov rdi, r14
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>::operator[](
long long a1,
long long a2)
{
unsigned __int8 v2; // al
long long v3; // rax
long long v4; // rdi
nlohmann::json_abi_v3_11_2::detail::exception *exception; // rbx
_QWORD v7[8]; // [rsp+8h] [rbp-40h] BYREF
v2 = *(_BYTE *)a1;
if ( !*(_BYTE *)a1 )
{
*(_BYTE *)a1 = 1;
v3 = operator new(0x30uLL);
*(_OWORD *)v3 = 0LL;
*(_QWORD *)(v3 + 16) = 0LL;
*(_QWORD *)(v3 + 24) = v3 + 8;
*(_QWORD *)(v3 + 32) = v3 + 8;
*(_QWORD *)(v3 + 40) = 0LL;
*(_QWORD *)(a1 + 8) = v3;
v2 = *(_BYTE *)a1;
}
if ( v2 != 1 )
{
exception = (nlohmann::json_abi_v3_11_2::detail::exception *)__cxa_allocate_exception(0x20uLL);
v7[4] = nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>::type_name((unsigned __int8 *)a1);
nlohmann::json_abi_v3_11_2::detail::concat<std::string,char const(&)[51],char const*>(
v7,
"cannot use operator[] with a string argument with ");
ZN8nlohmann16json_abi_v3_11_26detail10type_error6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
exception,
305,
v7);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_2::detail::type_error,
(void (*)(void *))nlohmann::json_abi_v3_11_2::detail::exception::~exception);
}
v4 = *(_QWORD *)(a1 + 8);
v7[0] = 0LL;
return std::_Rb_tree<std::string,std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>,std::_Select1st<std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>>>::_M_emplace_unique<std::string,decltype(nullptr)>(
v4,
a2,
v7)
+ 64;
}
| |||
23,319 | reset_table_lock_waits_by_table() | eloqsql/storage/perfschema/pfs_events_waits.cc | void reset_table_lock_waits_by_table()
{
global_table_share_container.apply(fct_reset_table_lock_waits_by_table);
} | O3 | cpp | reset_table_lock_waits_by_table():
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
xorl %r14d, %r14d
leaq 0x36f47b(%rip), %r15 # 0x3a3280
movq 0xa8(%r15,%r14,8), %rax
testq %rax, %rax
je 0x33e44
movq 0x50(%rax), %r12
testq %r12, %r12
jle 0x33e44
movq 0x48(%rax), %rbx
shlq $0xa, %r12
addq %rbx, %r12
movl (%rbx), %eax
andl $0x3, %eax
cmpl $0x2, %eax
jne 0x33e38
movq %rbx, %rdi
callq 0x3c7de
addq $0x400, %rbx # imm = 0x400
cmpq %r12, %rbx
jb 0x33e26
incq %r14
cmpq $0x1000, %r14 # imm = 0x1000
jne 0x33e05
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| _Z31reset_table_lock_waits_by_tablev:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
xor r14d, r14d
lea r15, global_table_share_container
loc_33E05:
mov rax, [r15+r14*8+0A8h]
test rax, rax
jz short loc_33E44
mov r12, [rax+50h]
test r12, r12
jle short loc_33E44
mov rbx, [rax+48h]
shl r12, 0Ah
add r12, rbx
loc_33E26:
mov eax, [rbx]
and eax, 3
cmp eax, 2
jnz short loc_33E38
mov rdi, rbx; this
call _ZN15PFS_table_share14aggregate_lockEv; PFS_table_share::aggregate_lock(void)
loc_33E38:
add rbx, 400h
cmp rbx, r12
jb short loc_33E26
loc_33E44:
inc r14
cmp r14, 1000h
jnz short loc_33E05
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| long long reset_table_lock_waits_by_table(void)
{
long long i; // r14
long long result; // rax
long long v2; // r12
PFS_table_share *v3; // rbx
PFS_table_share *v4; // r12
for ( i = 0LL; i != 4096; ++i )
{
result = global_table_share_container[i + 21];
if ( result )
{
v2 = *(_QWORD *)(result + 80);
if ( v2 > 0 )
{
v3 = *(PFS_table_share **)(result + 72);
v4 = (PFS_table_share *)((char *)v3 + 1024 * v2);
do
{
result = *(_DWORD *)v3 & 3;
if ( (_DWORD)result == 2 )
result = PFS_table_share::aggregate_lock(v3);
v3 = (PFS_table_share *)((char *)v3 + 1024);
}
while ( v3 < v4 );
}
}
}
return result;
}
| reset_table_lock_waits_by_table:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
XOR R14D,R14D
LEA R15,[0x4a3280]
LAB_00133e05:
MOV RAX,qword ptr [R15 + R14*0x8 + 0xa8]
TEST RAX,RAX
JZ 0x00133e44
MOV R12,qword ptr [RAX + 0x50]
TEST R12,R12
JLE 0x00133e44
MOV RBX,qword ptr [RAX + 0x48]
SHL R12,0xa
ADD R12,RBX
LAB_00133e26:
MOV EAX,dword ptr [RBX]
AND EAX,0x3
CMP EAX,0x2
JNZ 0x00133e38
MOV RDI,RBX
CALL 0x0013c7de
LAB_00133e38:
ADD RBX,0x400
CMP RBX,R12
JC 0x00133e26
LAB_00133e44:
INC R14
CMP R14,0x1000
JNZ 0x00133e05
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
/* WARNING: Unknown calling convention -- yet parameter storage is locked */
/* reset_table_lock_waits_by_table() */
void reset_table_lock_waits_by_table(void)
{
long lVar1;
PFS_table_share *this;
PFS_table_share *pPVar2;
long lVar3;
lVar3 = 0;
do {
lVar1 = (&DAT_004a3328)[lVar3];
if ((lVar1 != 0) && (0 < *(long *)(lVar1 + 0x50))) {
this = *(PFS_table_share **)(lVar1 + 0x48);
pPVar2 = this + *(long *)(lVar1 + 0x50) * 0x400;
do {
if ((*(uint *)this & 3) == 2) {
PFS_table_share::aggregate_lock(this);
}
this = this + 0x400;
} while (this < pPVar2);
}
lVar3 = lVar3 + 1;
} while (lVar3 != 0x1000);
return;
}
| |
23,320 | nlohmann::json_abi_v3_11_3::detail::out_of_range nlohmann::json_abi_v3_11_3::detail::out_of_range::create<std::nullptr_t, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::nullptr_t) | monkey531[P]llama/common/json.hpp | static out_of_range create(int id_, const std::string& what_arg, BasicJsonContext context)
{
const std::string w = concat(exception::name("out_of_range", id_), exception::diagnostics(context), what_arg);
return {id_, w.c_str()};
} | O3 | cpp | nlohmann::json_abi_v3_11_3::detail::out_of_range nlohmann::json_abi_v3_11_3::detail::out_of_range::create<std::nullptr_t, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::nullptr_t):
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 0x60bec(%rip), %rsi # 0xbc1dd
leaq 0x60bf1(%rip), %rdx # 0xbc1e9
leaq 0x28(%rsp), %rdi
callq 0x25304
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
movl %ebp, %edx
callq 0x510ae
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 0x19c00
movq 0x48(%rsp), %rsi
movq 0x50(%rsp), %rdx
leaq 0x8(%rsp), %rdi
callq 0x19210
movq 0x68(%rsp), %rsi
movq 0x70(%rsp), %rdx
leaq 0x8(%rsp), %rdi
callq 0x19210
movq (%r15), %rsi
movq 0x8(%r15), %rdx
leaq 0x8(%rsp), %rdi
callq 0x19210
movq 0x68(%rsp), %rdi
cmpq %r14, %rdi
je 0x5b69b
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x197f0
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x5b6b6
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x197f0
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x5b6cd
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x197f0
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl %ebp, %esi
callq 0x512aa
leaq 0x93ce5(%rip), %rax # 0xef3c8
addq $0x10, %rax
movq %rax, (%rbx)
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0x5b701
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x197f0
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 0x5b78f
movq 0x18(%rsp), %rsi
jmp 0x5b787
movq %rax, %rbx
jmp 0x5b778
movq %rax, %rbx
jmp 0x5b78f
movq %rdx, %rbx
movq %rax, %r15
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0x5b751
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x197f0
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 0x1a833
movq (%r12), %rbx
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x5b78f
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x197f0
movq %rbx, %rdi
callq 0x19dc0
| _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_:
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, aOutOfRange; "out_of_range"
lea rdx, aOutOfRange+0Ch; ""
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_5B69B
mov rsi, [rsp+0C8h+var_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_5B69B:
lea rax, [rsp+0C8h+var_70]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_5B6B6
mov rsi, [rsp+0C8h+var_70]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_5B6B6:
mov rdi, [rsp+0C8h+var_A0]; void *
cmp rdi, r13
jz short loc_5B6CD
mov rsi, [rsp+0C8h+var_90]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_5B6CD:
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_36detail12out_of_rangeE; `vtable for'nlohmann::json_abi_v3_11_3::detail::out_of_range
add rax, 10h
mov [rbx], rax
mov rdi, [rsp+0C8h+var_C0]; void *
cmp rdi, r12
jz short loc_5B701
mov rsi, [rsp+0C8h+var_B0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_5B701:
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_5B78F
mov rsi, [rsp+arg_10]
jmp short loc_5B787
mov rbx, rax
jmp short loc_5B778
mov rbx, rax
jmp short loc_5B78F
mov rbx, rdx
mov r15, rax
mov rdi, [rsp+arg_0]; void *
cmp rdi, r12
jz short loc_5B751
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_5B751:
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_36detail12out_of_range6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5__cold_1
mov rbx, [r12]
loc_5B778:
mov rdi, [rsp+arg_20]; void *
cmp rdi, r13
jz short loc_5B78F
mov rsi, [rsp+arg_30]
loc_5B787:
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_5B78F:
mov rdi, rbx
call __Unwind_Resume
| nlohmann::json_abi_v3_11_3::detail::exception * ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_(
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*>((long long)v7, "out_of_range", (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);
std::string::_M_append(v5, v12);
std::string::_M_append(v5, *a3);
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::out_of_range + 2;
if ( (_QWORD *)v5[0] != v6 )
operator delete(v5[0], v6[0] + 1LL);
return this;
}
| _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_:
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_0015b5ea:
LEA RSI,[0x1bc1dd]
LEA RDX,[0x1bc1e9]
LEA RDI,[RSP + 0x28]
CALL 0x00125304
LAB_0015b602:
LEA RDI,[RSP + 0x48]
LEA RSI,[RSP + 0x28]
MOV EDX,EBP
CALL 0x001510ae
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_0015b641:
LEA RDI,[RSP + 0x8]
CALL 0x00119c00
MOV RSI,qword ptr [RSP + 0x48]
MOV RDX,qword ptr [RSP + 0x50]
LEA RDI,[RSP + 0x8]
CALL 0x00119210
MOV RSI,qword ptr [RSP + 0x68]
MOV RDX,qword ptr [RSP + 0x70]
LEA RDI,[RSP + 0x8]
CALL 0x00119210
MOV RSI,qword ptr [R15]
MOV RDX,qword ptr [R15 + 0x8]
LEA RDI,[RSP + 0x8]
CALL 0x00119210
MOV RDI,qword ptr [RSP + 0x68]
CMP RDI,R14
JZ 0x0015b69b
MOV RSI,qword ptr [RSP + 0x78]
INC RSI
CALL 0x001197f0
LAB_0015b69b:
LEA RAX,[RSP + 0x58]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0015b6b6
MOV RSI,qword ptr [RSP + 0x58]
INC RSI
CALL 0x001197f0
LAB_0015b6b6:
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R13
JZ 0x0015b6cd
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x001197f0
LAB_0015b6cd:
MOV RDX,qword ptr [RSP + 0x8]
LAB_0015b6d2:
MOV RDI,RBX
MOV ESI,EBP
CALL 0x001512aa
LAB_0015b6dc:
LEA RAX,[0x1ef3c8]
ADD RAX,0x10
MOV qword ptr [RBX],RAX
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,R12
JZ 0x0015b701
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001197f0
LAB_0015b701:
MOV RAX,RBX
ADD RSP,0x98
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
exception *
_ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_
(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 0015b5ea to 0015b601 has its CatchHandler @ 0015b72f */
local_a0[0] = local_90;
std::__cxx11::string::_M_construct<char_const*>(local_a0,"out_of_range","");
/* try { // try from 0015b602 to 0015b612 has its CatchHandler @ 0015b72a */
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 0015b641 to 0015b683 has its CatchHandler @ 0015b734 */
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 0015b6d2 to 0015b6db has its CatchHandler @ 0015b716 */
nlohmann::json_abi_v3_11_3::detail::exception::exception(param_1,param_2,local_c0);
*(int ***)param_1 = &PTR__exception_001ef3d8;
if (local_c0 != &local_b0) {
operator_delete(local_c0,CONCAT71(uStack_af,local_b0) + 1);
}
return param_1;
}
| |
23,321 | lunasvg::parsePseudoClassSelector(std::basic_string_view<char, std::char_traits<char>>&, lunasvg::SimpleSelector&) | dmazzella[P]pylunasvg/lunasvg/source/svgparser.cpp | static bool parsePseudoClassSelector(std::string_view& input, SimpleSelector& simpleSelector)
{
std::string name;
if(!readCSSIdentifier(input, name))
return false;
PseudoClassSelector selector;
if(name.compare("empty") == 0)
selector.type = PseudoClassSelector::Type::Empty;
else if(name.compare("root") == 0)
selector.type = PseudoClassSelector::Type::Root;
else if(name.compare("not") == 0)
selector.type = PseudoClassSelector::Type::Not;
else if(name.compare("first-child") == 0)
selector.type = PseudoClassSelector::Type::FirstChild;
else if(name.compare("last-child") == 0)
selector.type = PseudoClassSelector::Type::LastChild;
else if(name.compare("only-child") == 0)
selector.type = PseudoClassSelector::Type::OnlyChild;
else if(name.compare("first-of-type") == 0)
selector.type = PseudoClassSelector::Type::FirstOfType;
else if(name.compare("last-of-type") == 0)
selector.type = PseudoClassSelector::Type::LastOfType;
else if(name.compare("only-of-type") == 0)
selector.type = PseudoClassSelector::Type::OnlyOfType;
if(selector.type == PseudoClassSelector::Type::Is || selector.type == PseudoClassSelector::Type::Not) {
skipOptionalSpaces(input);
if(!skipDelimiter(input, '('))
return false;
skipOptionalSpaces(input);
if(!parseSelectors(input, selector.subSelectors))
return false;
skipOptionalSpaces(input);
if(!skipDelimiter(input, ')')) {
return false;
}
}
simpleSelector.pseudoClassSelectors.push_back(std::move(selector));
return true;
} | O0 | cpp | lunasvg::parsePseudoClassSelector(std::basic_string_view<char, std::char_traits<char>>&, lunasvg::SimpleSelector&):
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
leaq -0x38(%rbp), %rdi
movq %rdi, -0x78(%rbp)
callq 0xb520
movq -0x78(%rbp), %rsi
movq -0x10(%rbp), %rdi
callq 0x3fbe0
movb %al, -0x69(%rbp)
jmp 0x3dd92
movb -0x69(%rbp), %al
testb $0x1, %al
jne 0x3ddbc
jmp 0x3dd9b
movb $0x0, -0x1(%rbp)
movl $0x1, -0x48(%rbp)
jmp 0x3dfc1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x3dfd8
leaq -0x68(%rbp), %rdi
callq 0x40f20
leaq -0x38(%rbp), %rdi
leaq 0x4f089(%rip), %rsi # 0x8ce59
callq 0xb100
cmpl $0x0, %eax
jne 0x3dde6
movl $0x1, -0x68(%rbp)
jmp 0x3deed
leaq -0x38(%rbp), %rdi
leaq 0x4f06e(%rip), %rsi # 0x8ce5f
callq 0xb100
cmpl $0x0, %eax
jne 0x3de07
movl $0x2, -0x68(%rbp)
jmp 0x3deeb
leaq -0x38(%rbp), %rdi
leaq 0x4f052(%rip), %rsi # 0x8ce64
callq 0xb100
cmpl $0x0, %eax
jne 0x3de28
movl $0x4, -0x68(%rbp)
jmp 0x3dee9
leaq -0x38(%rbp), %rdi
leaq 0x4f035(%rip), %rsi # 0x8ce68
callq 0xb100
cmpl $0x0, %eax
jne 0x3de49
movl $0x5, -0x68(%rbp)
jmp 0x3dee7
leaq -0x38(%rbp), %rdi
leaq 0x4f020(%rip), %rsi # 0x8ce74
callq 0xb100
cmpl $0x0, %eax
jne 0x3de67
movl $0x6, -0x68(%rbp)
jmp 0x3dee5
leaq -0x38(%rbp), %rdi
leaq 0x4f00d(%rip), %rsi # 0x8ce7f
callq 0xb100
cmpl $0x0, %eax
jne 0x3de85
movl $0x7, -0x68(%rbp)
jmp 0x3dee3
leaq -0x38(%rbp), %rdi
leaq 0x4effa(%rip), %rsi # 0x8ce8a
callq 0xb100
cmpl $0x0, %eax
jne 0x3dea3
movl $0x8, -0x68(%rbp)
jmp 0x3dee1
leaq -0x38(%rbp), %rdi
leaq 0x4efea(%rip), %rsi # 0x8ce98
callq 0xb100
cmpl $0x0, %eax
jne 0x3dec1
movl $0x9, -0x68(%rbp)
jmp 0x3dedf
leaq -0x38(%rbp), %rdi
leaq 0x4efd9(%rip), %rsi # 0x8cea5
callq 0xb100
cmpl $0x0, %eax
jne 0x3dedd
movl $0xa, -0x68(%rbp)
jmp 0x3dedf
jmp 0x3dee1
jmp 0x3dee3
jmp 0x3dee5
jmp 0x3dee7
jmp 0x3dee9
jmp 0x3deeb
jmp 0x3deed
cmpl $0x3, -0x68(%rbp)
je 0x3defd
cmpl $0x4, -0x68(%rbp)
jne 0x3df9a
movq -0x10(%rbp), %rdi
callq 0x332b0
movq -0x10(%rbp), %rdi
movl $0x28, %esi
callq 0x33420
testb $0x1, %al
jne 0x3df28
movb $0x0, -0x1(%rbp)
movl $0x1, -0x48(%rbp)
jmp 0x3dfb8
movq -0x10(%rbp), %rdi
callq 0x332b0
movq -0x10(%rbp), %rdi
leaq -0x60(%rbp), %rsi
callq 0x3cff0
movb %al, -0x79(%rbp)
jmp 0x3df43
movb -0x79(%rbp), %al
testb $0x1, %al
jne 0x3df70
jmp 0x3df4c
movb $0x0, -0x1(%rbp)
movl $0x1, -0x48(%rbp)
jmp 0x3dfb8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x40f80
jmp 0x3dfd8
movq -0x10(%rbp), %rdi
callq 0x332b0
movq -0x10(%rbp), %rdi
movl $0x29, %esi
callq 0x33420
testb $0x1, %al
jne 0x3df98
movb $0x0, -0x1(%rbp)
movl $0x1, -0x48(%rbp)
jmp 0x3dfb8
jmp 0x3df9a
movq -0x18(%rbp), %rdi
addq $0x20, %rdi
leaq -0x68(%rbp), %rsi
callq 0x40f50
jmp 0x3dfad
movb $0x1, -0x1(%rbp)
movl $0x1, -0x48(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x40f80
leaq -0x38(%rbp), %rdi
callq 0xb7a8
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x80, %rsp
popq %rbp
retq
leaq -0x38(%rbp), %rdi
callq 0xb7a8
movq -0x40(%rbp), %rdi
callq 0xb6c0
nopw (%rax,%rax)
| _ZN7lunasvgL24parsePseudoClassSelectorERSt17basic_string_viewIcSt11char_traitsIcEERNS_14SimpleSelectorE:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
lea rdi, [rbp+var_38]
mov [rbp+var_78], rdi
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev; std::string::basic_string(void)
mov rsi, [rbp+var_78]
mov rdi, [rbp+var_10]
call _ZN7lunasvg17readCSSIdentifierERSt17basic_string_viewIcSt11char_traitsIcEERNSt7__cxx1112basic_stringIcS2_SaIcEEE; lunasvg::readCSSIdentifier(std::string_view &,std::string &)
mov [rbp+var_69], al
jmp short $+2
loc_3DD92:
mov al, [rbp+var_69]
test al, 1
jnz short loc_3DDBC
jmp short $+2
loc_3DD9B:
mov [rbp+var_1], 0
mov [rbp+var_48], 1
jmp loc_3DFC1
mov rcx, rax
mov eax, edx
mov [rbp+var_40], rcx
mov [rbp+var_44], eax
jmp loc_3DFD8
loc_3DDBC:
lea rdi, [rbp+var_68]; this
call _ZN7lunasvg19PseudoClassSelectorC2Ev; lunasvg::PseudoClassSelector::PseudoClassSelector(void)
lea rdi, [rbp+var_38]
lea rsi, aEmpty; "empty"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DDE6
mov [rbp+var_68], 1
jmp loc_3DEED
loc_3DDE6:
lea rdi, [rbp+var_38]
lea rsi, aRoot; "root"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DE07
mov [rbp+var_68], 2
jmp loc_3DEEB
loc_3DE07:
lea rdi, [rbp+var_38]
lea rsi, aNot; "not"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DE28
mov [rbp+var_68], 4
jmp loc_3DEE9
loc_3DE28:
lea rdi, [rbp+var_38]
lea rsi, aFirstChild; "first-child"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DE49
mov [rbp+var_68], 5
jmp loc_3DEE7
loc_3DE49:
lea rdi, [rbp+var_38]
lea rsi, aLastChild; "last-child"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DE67
mov [rbp+var_68], 6
jmp short loc_3DEE5
loc_3DE67:
lea rdi, [rbp+var_38]
lea rsi, aOnlyChild; "only-child"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DE85
mov [rbp+var_68], 7
jmp short loc_3DEE3
loc_3DE85:
lea rdi, [rbp+var_38]
lea rsi, aFirstOfType; "first-of-type"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DEA3
mov [rbp+var_68], 8
jmp short loc_3DEE1
loc_3DEA3:
lea rdi, [rbp+var_38]
lea rsi, aLastOfType; "last-of-type"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DEC1
mov [rbp+var_68], 9
jmp short loc_3DEDF
loc_3DEC1:
lea rdi, [rbp+var_38]
lea rsi, aOnlyOfType; "only-of-type"
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
cmp eax, 0
jnz short loc_3DEDD
mov [rbp+var_68], 0Ah
loc_3DEDD:
jmp short $+2
loc_3DEDF:
jmp short $+2
loc_3DEE1:
jmp short $+2
loc_3DEE3:
jmp short $+2
loc_3DEE5:
jmp short $+2
loc_3DEE7:
jmp short $+2
loc_3DEE9:
jmp short $+2
loc_3DEEB:
jmp short $+2
loc_3DEED:
cmp [rbp+var_68], 3
jz short loc_3DEFD
cmp [rbp+var_68], 4
jnz loc_3DF9A
loc_3DEFD:
mov rdi, [rbp+var_10]
call _ZN7lunasvg18skipOptionalSpacesERSt17basic_string_viewIcSt11char_traitsIcEE; lunasvg::skipOptionalSpaces(std::string_view &)
mov rdi, [rbp+var_10]
mov esi, 28h ; '('
call _ZN7lunasvg13skipDelimiterERSt17basic_string_viewIcSt11char_traitsIcEEc; lunasvg::skipDelimiter(std::string_view &,char)
test al, 1
jnz short loc_3DF28
mov [rbp+var_1], 0
mov [rbp+var_48], 1
jmp loc_3DFB8
loc_3DF28:
mov rdi, [rbp+var_10]
call _ZN7lunasvg18skipOptionalSpacesERSt17basic_string_viewIcSt11char_traitsIcEE; lunasvg::skipOptionalSpaces(std::string_view &)
mov rdi, [rbp+var_10]
lea rsi, [rbp+var_60]
call _ZN7lunasvgL14parseSelectorsERSt17basic_string_viewIcSt11char_traitsIcEERSt6vectorIS5_INS_14SimpleSelectorESaIS6_EESaIS8_EE; lunasvg::parseSelectors(std::string_view &,std::vector<std::vector<lunasvg::SimpleSelector>> &)
mov [rbp+var_79], al
jmp short $+2
loc_3DF43:
mov al, [rbp+var_79]
test al, 1
jnz short loc_3DF70
jmp short $+2
loc_3DF4C:
mov [rbp+var_1], 0
mov [rbp+var_48], 1
jmp short loc_3DFB8
mov rcx, rax
mov eax, edx
mov [rbp+var_40], rcx
mov [rbp+var_44], eax
lea rdi, [rbp+var_68]; this
call _ZN7lunasvg19PseudoClassSelectorD2Ev; lunasvg::PseudoClassSelector::~PseudoClassSelector()
jmp short loc_3DFD8
loc_3DF70:
mov rdi, [rbp+var_10]
call _ZN7lunasvg18skipOptionalSpacesERSt17basic_string_viewIcSt11char_traitsIcEE; lunasvg::skipOptionalSpaces(std::string_view &)
mov rdi, [rbp+var_10]
mov esi, 29h ; ')'
call _ZN7lunasvg13skipDelimiterERSt17basic_string_viewIcSt11char_traitsIcEEc; lunasvg::skipDelimiter(std::string_view &,char)
test al, 1
jnz short loc_3DF98
mov [rbp+var_1], 0
mov [rbp+var_48], 1
jmp short loc_3DFB8
loc_3DF98:
jmp short $+2
loc_3DF9A:
mov rdi, [rbp+var_18]
add rdi, 20h ; ' '
lea rsi, [rbp+var_68]
call _ZNSt6vectorIN7lunasvg19PseudoClassSelectorESaIS1_EE9push_backEOS1_; std::vector<lunasvg::PseudoClassSelector>::push_back(lunasvg::PseudoClassSelector&&)
jmp short $+2
loc_3DFAD:
mov [rbp+var_1], 1
mov [rbp+var_48], 1
loc_3DFB8:
lea rdi, [rbp+var_68]; this
call _ZN7lunasvg19PseudoClassSelectorD2Ev; lunasvg::PseudoClassSelector::~PseudoClassSelector()
loc_3DFC1:
lea rdi, [rbp+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov al, [rbp+var_1]
and al, 1
add rsp, 80h
pop rbp
retn
loc_3DFD8:
lea rdi, [rbp+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rdi, [rbp+var_40]
call __Unwind_Resume
| char lunasvg::parsePseudoClassSelector(_QWORD *a1, long long a2)
{
int v3; // [rsp+18h] [rbp-68h] BYREF
_BYTE v4[24]; // [rsp+20h] [rbp-60h] BYREF
int v5; // [rsp+38h] [rbp-48h]
_BYTE v6[32]; // [rsp+48h] [rbp-38h] BYREF
long long v7; // [rsp+68h] [rbp-18h]
_QWORD *v8; // [rsp+70h] [rbp-10h]
char v9; // [rsp+7Fh] [rbp-1h]
v8 = a1;
v7 = a2;
std::string::basic_string(v6);
if ( (lunasvg::readCSSIdentifier(v8, v6) & 1) != 0 )
{
lunasvg::PseudoClassSelector::PseudoClassSelector((lunasvg::PseudoClassSelector *)&v3);
if ( !(unsigned int)std::string::compare(v6, "empty") )
{
v3 = 1;
}
else if ( !(unsigned int)std::string::compare(v6, "root") )
{
v3 = 2;
}
else if ( !(unsigned int)std::string::compare(v6, "not") )
{
v3 = 4;
}
else if ( !(unsigned int)std::string::compare(v6, "first-child") )
{
v3 = 5;
}
else if ( !(unsigned int)std::string::compare(v6, "last-child") )
{
v3 = 6;
}
else if ( !(unsigned int)std::string::compare(v6, "only-child") )
{
v3 = 7;
}
else if ( !(unsigned int)std::string::compare(v6, "first-of-type") )
{
v3 = 8;
}
else if ( !(unsigned int)std::string::compare(v6, "last-of-type") )
{
v3 = 9;
}
else if ( !(unsigned int)std::string::compare(v6, "only-of-type") )
{
v3 = 10;
}
if ( v3 == 3 || v3 == 4 )
{
lunasvg::skipOptionalSpaces(v8);
if ( (lunasvg::skipDelimiter(v8, 40) & 1) == 0 )
{
v9 = 0;
v5 = 1;
LABEL_30:
lunasvg::PseudoClassSelector::~PseudoClassSelector((lunasvg::PseudoClassSelector *)&v3);
goto LABEL_31;
}
lunasvg::skipOptionalSpaces(v8);
if ( (lunasvg::parseSelectors((long long)v8, (long long)v4) & 1) == 0 )
{
v9 = 0;
v5 = 1;
goto LABEL_30;
}
lunasvg::skipOptionalSpaces(v8);
if ( (lunasvg::skipDelimiter(v8, 41) & 1) == 0 )
{
v9 = 0;
v5 = 1;
goto LABEL_30;
}
}
std::vector<lunasvg::PseudoClassSelector>::push_back(v7 + 32, &v3);
v9 = 1;
v5 = 1;
goto LABEL_30;
}
v9 = 0;
v5 = 1;
LABEL_31:
std::string::~string(v6);
return v9 & 1;
}
| parsePseudoClassSelector:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
LEA RDI,[RBP + -0x38]
MOV qword ptr [RBP + -0x78],RDI
CALL 0x0010b520
MOV RSI,qword ptr [RBP + -0x78]
MOV RDI,qword ptr [RBP + -0x10]
LAB_0013dd88:
CALL 0x0013fbe0
MOV byte ptr [RBP + -0x69],AL
JMP 0x0013dd92
LAB_0013dd92:
MOV AL,byte ptr [RBP + -0x69]
TEST AL,0x1
JNZ 0x0013ddbc
JMP 0x0013dd9b
LAB_0013dd9b:
MOV byte ptr [RBP + -0x1],0x0
MOV dword ptr [RBP + -0x48],0x1
JMP 0x0013dfc1
LAB_0013ddbc:
LEA RDI,[RBP + -0x68]
CALL 0x00140f20
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18ce59]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013dde6
MOV dword ptr [RBP + -0x68],0x1
JMP 0x0013deed
LAB_0013dde6:
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18ce5f]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013de07
MOV dword ptr [RBP + -0x68],0x2
JMP 0x0013deeb
LAB_0013de07:
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18ce64]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013de28
MOV dword ptr [RBP + -0x68],0x4
JMP 0x0013dee9
LAB_0013de28:
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18ce68]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013de49
MOV dword ptr [RBP + -0x68],0x5
JMP 0x0013dee7
LAB_0013de49:
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18ce74]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013de67
MOV dword ptr [RBP + -0x68],0x6
JMP 0x0013dee5
LAB_0013de67:
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18ce7f]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013de85
MOV dword ptr [RBP + -0x68],0x7
JMP 0x0013dee3
LAB_0013de85:
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18ce8a]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013dea3
MOV dword ptr [RBP + -0x68],0x8
JMP 0x0013dee1
LAB_0013dea3:
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18ce98]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013dec1
MOV dword ptr [RBP + -0x68],0x9
JMP 0x0013dedf
LAB_0013dec1:
LEA RDI,[RBP + -0x38]
LEA RSI,[0x18cea5]
CALL 0x0010b100
CMP EAX,0x0
JNZ 0x0013dedd
MOV dword ptr [RBP + -0x68],0xa
LAB_0013dedd:
JMP 0x0013dedf
LAB_0013dedf:
JMP 0x0013dee1
LAB_0013dee1:
JMP 0x0013dee3
LAB_0013dee3:
JMP 0x0013dee5
LAB_0013dee5:
JMP 0x0013dee7
LAB_0013dee7:
JMP 0x0013dee9
LAB_0013dee9:
JMP 0x0013deeb
LAB_0013deeb:
JMP 0x0013deed
LAB_0013deed:
CMP dword ptr [RBP + -0x68],0x3
JZ 0x0013defd
CMP dword ptr [RBP + -0x68],0x4
JNZ 0x0013df9a
LAB_0013defd:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001332b0
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,0x28
CALL 0x00133420
TEST AL,0x1
JNZ 0x0013df28
MOV byte ptr [RBP + -0x1],0x0
MOV dword ptr [RBP + -0x48],0x1
JMP 0x0013dfb8
LAB_0013df28:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001332b0
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[RBP + -0x60]
LAB_0013df39:
CALL 0x0013cff0
MOV byte ptr [RBP + -0x79],AL
JMP 0x0013df43
LAB_0013df43:
MOV AL,byte ptr [RBP + -0x79]
TEST AL,0x1
JNZ 0x0013df70
JMP 0x0013df4c
LAB_0013df4c:
MOV byte ptr [RBP + -0x1],0x0
MOV dword ptr [RBP + -0x48],0x1
JMP 0x0013dfb8
LAB_0013df70:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001332b0
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,0x29
CALL 0x00133420
TEST AL,0x1
JNZ 0x0013df98
MOV byte ptr [RBP + -0x1],0x0
MOV dword ptr [RBP + -0x48],0x1
JMP 0x0013dfb8
LAB_0013df98:
JMP 0x0013df9a
LAB_0013df9a:
MOV RDI,qword ptr [RBP + -0x18]
ADD RDI,0x20
LEA RSI,[RBP + -0x68]
CALL 0x00140f50
LAB_0013dfab:
JMP 0x0013dfad
LAB_0013dfad:
MOV byte ptr [RBP + -0x1],0x1
MOV dword ptr [RBP + -0x48],0x1
LAB_0013dfb8:
LEA RDI,[RBP + -0x68]
CALL 0x00140f80
LAB_0013dfc1:
LEA RDI,[RBP + -0x38]
CALL 0x0010b7a8
MOV AL,byte ptr [RBP + -0x1]
AND AL,0x1
ADD RSP,0x80
POP RBP
RET
|
/* lunasvg::parsePseudoClassSelector(std::basic_string_view<char, std::char_traits<char> >&,
lunasvg::SimpleSelector&) */
uint lunasvg::parsePseudoClassSelector(basic_string_view *param_1,SimpleSelector *param_2)
{
byte bVar1;
int iVar2;
uint uVar3;
int4 uVar4;
int local_70 [2];
vector local_68 [24];
int4 local_50;
string local_40 [32];
SimpleSelector *local_20;
basic_string_view *local_18;
int1 local_9;
local_20 = param_2;
local_18 = param_1;
std::__cxx11::string::string(local_40);
/* try { // try from 0013dd88 to 0013dd8c has its CatchHandler @ 0013ddab */
bVar1 = readCSSIdentifier(local_18,local_40);
if ((bVar1 & 1) == 0) {
local_9 = 0;
local_50 = 1;
goto LAB_0013dfc1;
}
PseudoClassSelector::PseudoClassSelector((PseudoClassSelector *)local_70);
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 1;
}
else {
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 2;
}
else {
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 4;
}
else {
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 5;
}
else {
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 6;
}
else {
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 7;
}
else {
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 8;
}
else {
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 9;
}
else {
iVar2 = std::__cxx11::string::compare((char *)local_40);
if (iVar2 == 0) {
local_70[0] = 10;
}
}
}
}
}
}
}
}
}
if ((local_70[0] == 3) || (local_70[0] == 4)) {
skipOptionalSpaces(local_18);
uVar3 = skipDelimiter(local_18,'(');
if ((uVar3 & 1) == 0) {
local_9 = 0;
}
else {
skipOptionalSpaces(local_18);
/* try { // try from 0013df39 to 0013dfaa has its CatchHandler @ 0013df59 */
bVar1 = parseSelectors(local_18,local_68);
if ((bVar1 & 1) == 0) {
local_9 = 0;
}
else {
skipOptionalSpaces(local_18);
uVar3 = skipDelimiter(local_18,')');
if ((uVar3 & 1) != 0) goto LAB_0013df9a;
local_9 = 0;
}
}
}
else {
LAB_0013df9a:
std::vector<lunasvg::PseudoClassSelector,std::allocator<lunasvg::PseudoClassSelector>>::
push_back((vector<lunasvg::PseudoClassSelector,std::allocator<lunasvg::PseudoClassSelector>> *)
(local_20 + 0x20),(PseudoClassSelector *)local_70);
local_9 = 1;
}
local_50 = 1;
PseudoClassSelector::~PseudoClassSelector((PseudoClassSelector *)local_70);
LAB_0013dfc1:
uVar4 = std::__cxx11::string::~string(local_40);
return CONCAT31((int3)((uint)uVar4 >> 8),local_9) & 0xffffff01;
}
| |
23,322 | get_charset_number_internal | eloqsql/mysys/charset.c | static uint
get_charset_number_internal(const char *charset_name, uint cs_flags)
{
CHARSET_INFO **cs;
for (cs= all_charsets;
cs < all_charsets + array_elements(all_charsets);
cs++)
{
if ( cs[0] && cs[0]->cs_name.str && (cs[0]->state & cs_flags) &&
!my_strcasecmp(&my_charset_latin1, cs[0]->cs_name.str, charset_name))
return cs[0]->number;
}
return 0;
} | O3 | c | get_charset_number_internal:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
movq $-0x8, %r12
leaq 0x33d9ef(%rip), %r13 # 0x365980
leaq 0x2ec7d8(%rip), %r15 # 0x314770
movq 0x8(%r13,%r12), %rax
testq %rax, %rax
je 0x27fc4
movq 0x10(%rax), %rsi
testq %rsi, %rsi
je 0x27fc4
testl %ebx, 0xc(%rax)
je 0x27fc4
movq 0xc0(%r15), %rax
movq %r15, %rdi
movq %r14, %rdx
callq *0x40(%rax)
testl %eax, %eax
je 0x27fe2
addq $0x8, %r12
cmpq $0x3ff8, %r12 # imm = 0x3FF8
jb 0x27f98
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x8(%r13,%r12), %rax
movl (%rax), %eax
jmp 0x27fd3
| get_charset_number_internal:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov ebx, esi
mov r14, rdi
mov r12, 0FFFFFFFFFFFFFFF8h
lea r13, all_charsets
lea r15, my_charset_latin1
loc_27F98:
mov rax, [r13+r12+8]
test rax, rax
jz short loc_27FC4
mov rsi, [rax+10h]
test rsi, rsi
jz short loc_27FC4
test [rax+0Ch], ebx
jz short loc_27FC4
mov rax, [r15+0C0h]
mov rdi, r15
mov rdx, r14
call qword ptr [rax+40h]
test eax, eax
jz short loc_27FE2
loc_27FC4:
add r12, 8
cmp r12, 3FF8h
jb short loc_27F98
xor eax, eax
loc_27FD3:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_27FE2:
mov rax, [r13+r12+8]
mov eax, [rax]
jmp short loc_27FD3
| long long get_charset_number_internal(long long a1, int a2)
{
long long v3; // r12
long long v4; // rax
long long v5; // rsi
v3 = 0x1FFFFFFFFFFFFFFFLL;
while ( 1 )
{
v4 = all_charsets[v3 + 1];
if ( v4 )
{
v5 = *(_QWORD *)(v4 + 16);
if ( v5 )
{
if ( (a2 & *(_DWORD *)(v4 + 12)) != 0
&& !(*(unsigned int ( **)(void *, long long, long long))(*((_QWORD *)&my_charset_latin1 + 24) + 64LL))(
&my_charset_latin1,
v5,
a1) )
{
break;
}
}
}
if ( (unsigned long long)++v3 >= 2047 )
return 0LL;
}
return *(unsigned int *)all_charsets[v3 + 1];
}
| get_charset_number_internal:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV EBX,ESI
MOV R14,RDI
MOV R12,-0x8
LEA R13,[0x465980]
LEA R15,[0x414770]
LAB_00127f98:
MOV RAX,qword ptr [R13 + R12*0x1 + 0x8]
TEST RAX,RAX
JZ 0x00127fc4
MOV RSI,qword ptr [RAX + 0x10]
TEST RSI,RSI
JZ 0x00127fc4
TEST dword ptr [RAX + 0xc],EBX
JZ 0x00127fc4
MOV RAX,qword ptr [R15 + 0xc0]
MOV RDI,R15
MOV RDX,R14
CALL qword ptr [RAX + 0x40]
TEST EAX,EAX
JZ 0x00127fe2
LAB_00127fc4:
ADD R12,0x8
CMP R12,0x3ff8
JC 0x00127f98
XOR EAX,EAX
LAB_00127fd3:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00127fe2:
MOV RAX,qword ptr [R13 + R12*0x1 + 0x8]
MOV EAX,dword ptr [RAX]
JMP 0x00127fd3
|
int4 get_charset_number_internal(int8 param_1,uint param_2)
{
long lVar1;
int iVar2;
ulong uVar3;
uVar3 = 0xfffffffffffffff8;
while ((((lVar1 = *(long *)((long)&DAT_00465988 + uVar3), lVar1 == 0 ||
(*(long *)(lVar1 + 0x10) == 0)) || ((*(uint *)(lVar1 + 0xc) & param_2) == 0)) ||
(iVar2 = (**(code **)(PTR_my_collation_8bit_simple_ci_handler_00414830 + 0x40))
(&my_charset_latin1,*(long *)(lVar1 + 0x10),param_1), iVar2 != 0))) {
uVar3 = uVar3 + 8;
if (0x3ff7 < uVar3) {
return 0;
}
}
return **(int4 **)((long)&DAT_00465988 + uVar3);
}
| |
23,323 | evmone::advanced::Instruction const* evmone::advanced::(anonymous namespace)::op_call<(evmone::Opcode)241>(evmone::advanced::Instruction const*, evmone::advanced::AdvancedExecutionState&) | corpus-core[P]colibri-stateless/build_O2/_deps/evmone_external-src/lib/evmone/advanced_instructions.cpp | const Instruction* op_call(const Instruction* instr, AdvancedExecutionState& state) noexcept
{
const auto gas_left_correction = state.current_block_cost - instr->arg.number;
state.gas_left += gas_left_correction;
const auto status = instr::impl<Op>(state);
if (status != EVMC_SUCCESS)
return state.exit(status);
if ((state.gas_left -= gas_left_correction) < 0)
return state.exit(EVMC_OUT_OF_GAS);
return ++instr;
} | O2 | cpp | evmone::advanced::Instruction const* evmone::advanced::(anonymous namespace)::op_call<(evmone::Opcode)241>(evmone::advanced::Instruction const*, evmone::advanced::AdvancedExecutionState&):
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movl 0x230(%rsi), %r15d
subq 0x8(%rdi), %r15
addq %r15, 0x220(%rsi)
movq %rsi, %rdi
callq 0x488af
testl %eax, %eax
je 0x47c03
movl %eax, 0x78(%r14)
xorl %ebx, %ebx
jmp 0x47c10
subq %r15, 0x220(%r14)
js 0x47c19
addq $0x10, %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
movl $0x3, 0x78(%r14)
jmp 0x47bff
| _ZN6evmone8advanced12_GLOBAL__N_17op_callILNS_6OpcodeE244EEEPKNS0_11InstructionES6_RNS0_22AdvancedExecutionStateE:
push r15
push r14
push rbx
mov r14, rsi
mov rbx, rdi
mov r15d, [rsi+230h]
sub r15, [rdi+8]
add [rsi+220h], r15
mov rdi, rsi
call _ZN6evmone8advanced5instr4implILNS_6OpcodeE244EXadL_ZNS_5instr4core9call_implILS3_244EEENS_6ResultENS_8StackTopElRNS_14ExecutionStateEEEEE16evmc_status_codeRNS0_22AdvancedExecutionStateE; evmone::advanced::instr::impl<(evmone::Opcode)244,&evmone::instr::core::call_impl<(evmone::Opcode)244>>(evmone::advanced::AdvancedExecutionState &)
test eax, eax
jz short loc_47C03
mov [r14+78h], eax
loc_47BFF:
xor ebx, ebx
jmp short loc_47C10
loc_47C03:
sub [r14+220h], r15
js short loc_47C19
add rbx, 10h
loc_47C10:
mov rax, rbx
pop rbx
pop r14
pop r15
retn
loc_47C19:
mov dword ptr [r14+78h], 3
jmp short loc_47BFF
| long long evmone::advanced::`anonymous namespace'::op_call<(evmone::Opcode)244>(long long a1, long long a2)
{
long long v2; // r15
int v3; // eax
bool v5; // sf
v2 = *(unsigned int *)(a2 + 560) - *(_QWORD *)(a1 + 8);
*(_QWORD *)(a2 + 544) += v2;
v3 = evmone::advanced::instr::impl<(evmone::Opcode)244,&evmone::Result evmone::instr::core::call_impl<(evmone::Opcode)244>>(a2);
if ( v3 )
{
*(_DWORD *)(a2 + 120) = v3;
}
else
{
v5 = *(_QWORD *)(a2 + 544) - v2 < 0;
*(_QWORD *)(a2 + 544) -= v2;
if ( !v5 )
return a1 + 16;
*(_DWORD *)(a2 + 120) = 3;
}
return 0LL;
}
| op_call<(evmone::Opcode)244>:
PUSH R15
PUSH R14
PUSH RBX
MOV R14,RSI
MOV RBX,RDI
MOV R15D,dword ptr [RSI + 0x230]
SUB R15,qword ptr [RDI + 0x8]
ADD qword ptr [RSI + 0x220],R15
MOV RDI,RSI
CALL 0x001488af
TEST EAX,EAX
JZ 0x00147c03
MOV dword ptr [R14 + 0x78],EAX
LAB_00147bff:
XOR EBX,EBX
JMP 0x00147c10
LAB_00147c03:
SUB qword ptr [R14 + 0x220],R15
JS 0x00147c19
ADD RBX,0x10
LAB_00147c10:
MOV RAX,RBX
POP RBX
POP R14
POP R15
RET
LAB_00147c19:
MOV dword ptr [R14 + 0x78],0x3
JMP 0x00147bff
|
/* evmone::advanced::Instruction const* evmone::advanced::(anonymous
namespace)::op_call<(evmone::Opcode)244>(evmone::advanced::Instruction const*,
evmone::advanced::AdvancedExecutionState&) */
Instruction *
evmone::advanced::(anonymous_namespace)::op_call<(evmone::Opcode)244>
(Instruction *param_1,AdvancedExecutionState *param_2)
{
AdvancedExecutionState *pAVar1;
uint uVar2;
long lVar3;
int iVar4;
uVar2 = *(uint *)(param_2 + 0x230);
lVar3 = *(long *)(param_1 + 8);
*(ulong *)(param_2 + 0x220) = *(long *)(param_2 + 0x220) + ((ulong)uVar2 - lVar3);
iVar4 = instr::
impl<(evmone::Opcode)244,&(evmone::Result_evmone::instr::core::call_impl<(evmone::Opcode)244>(evmone::StackTop,long,evmone::ExecutionState&))>
(param_2);
if (iVar4 == 0) {
pAVar1 = param_2 + 0x220;
*(ulong *)pAVar1 = *(long *)pAVar1 - ((ulong)uVar2 - lVar3);
if (-1 < *(long *)pAVar1) {
return param_1 + 0x10;
}
*(int4 *)(param_2 + 0x78) = 3;
}
else {
*(int *)(param_2 + 0x78) = iVar4;
}
return (Instruction *)0x0;
}
| |
23,324 | mysql_stmt_prepare_start_internal | eloqsql/libmariadb/libmariadb/mariadb_async.c | static void
mysql_stmt_prepare_start_internal(void *d)
{
MK_ASYNC_INTERNAL_BODY(
mysql_stmt_prepare,
(parms->stmt, parms->query, parms->length),
parms->stmt->mysql,
int,
r_int)
} | O0 | c | mysql_stmt_prepare_start_internal:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x38(%rax), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rdx
callq 0x45070
movl %eax, -0x14(%rbp)
movl -0x14(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x8(%rax)
movq -0x20(%rbp), %rax
movl $0x0, (%rax)
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
| mysql_stmt_prepare_start_internal:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov [rbp+var_10], rax
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+38h]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov [rbp+var_20], rax
mov rax, [rbp+var_10]
mov rdi, [rax]
mov rax, [rbp+var_10]
mov rsi, [rax+8]
mov rax, [rbp+var_10]
mov rdx, [rax+10h]
call mysql_stmt_prepare
mov [rbp+var_14], eax
mov ecx, [rbp+var_14]
mov rax, [rbp+var_20]
mov [rax+8], ecx
mov rax, [rbp+var_20]
mov dword ptr [rax], 0
add rsp, 20h
pop rbp
retn
| _DWORD * mysql_stmt_prepare_start_internal(long long *a1)
{
_DWORD *result; // rax
_DWORD *v2; // [rsp+0h] [rbp-20h]
v2 = *(_DWORD **)(*(_QWORD *)(*(_QWORD *)(*a1 + 56) + 1152LL) + 40LL);
v2[2] = mysql_stmt_prepare(*a1, a1[1], a1[2]);
result = v2;
*v2 = 0;
return result;
}
| mysql_store_result_start:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x14],0x1
MOV RDI,qword ptr [RBP + -0x28]
ADD RDI,0x38
LEA RSI,[0x157250]
LEA RDX,[RBP + -0x30]
CALL 0x0015d3e0
MOV dword ptr [RBP + -0x1c],EAX
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x15],0x0
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x14],0x0
CMP dword ptr [RBP + -0x1c],0x0
JLE 0x001571aa
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x15],0x1
MOV RAX,qword ptr [RBP + -0x28]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x00157238
LAB_001571aa:
CMP dword ptr [RBP + -0x1c],0x0
JGE 0x00157222
JMP 0x001571b2
LAB_001571b2:
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX + 0x90],0x7d8
MOV RDI,qword ptr [RBP + -0x18]
ADD RDI,0x297
LEA RAX,[0x184ca0]
MOV RSI,qword ptr [RAX]
MOV EDX,0x5
CALL 0x00114210
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX + 0x29c],0x0
MOV RDI,qword ptr [RBP + -0x18]
ADD RDI,0x97
LEA RAX,[0x184cb0]
MOV RSI,qword ptr [RAX + 0x40]
MOV EDX,0x1ff
CALL 0x00114210
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX + 0x296],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX],0x0
JMP 0x00157231
LAB_00157222:
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX],RCX
LAB_00157231:
MOV dword ptr [RBP + -0x4],0x0
LAB_00157238:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
int4 mysql_store_result_start(int8 *param_1,long param_2)
{
long local_38;
int4 *local_30;
int local_24;
long local_20;
int8 *local_18;
int4 local_c;
local_30 = *(int4 **)(*(long *)(param_2 + 0x480) + 0x28);
*(int1 *)(local_30 + 5) = 1;
local_38 = param_2;
local_20 = param_2;
local_18 = param_1;
local_24 = my_context_spawn(local_30 + 0xe,mysql_store_result_start_internal,&local_38);
*(int1 *)((long)local_30 + 0x15) = 0;
*(int1 *)(local_30 + 5) = 0;
if (local_24 < 1) {
if (local_24 < 0) {
*(int4 *)(local_20 + 0x90) = 0x7d8;
strncpy((char *)(local_20 + 0x297),SQLSTATE_UNKNOWN,5);
*(int1 *)(local_20 + 0x29c) = 0;
strncpy((char *)(local_20 + 0x97),PTR_s_Client_run_out_of_memory_00184cf0,0x1ff);
*(int1 *)(local_20 + 0x296) = 0;
*local_18 = 0;
}
else {
*local_18 = *(int8 *)(local_30 + 2);
}
local_c = 0;
}
else {
*(int1 *)((long)local_30 + 0x15) = 1;
local_c = *local_30;
}
return local_c;
}
| |
23,325 | ftxui::ComponentBase::CaptureMouse(ftxui::Event const&) | Andrewchistyakov[P]flashcards_lyc/build_O3/_deps/ftxui-src/src/ftxui/component/component.cpp | CapturedMouse ComponentBase::CaptureMouse(const Event& event) { // NOLINT
if (event.screen_) {
return event.screen_->CaptureMouse();
}
return std::make_unique<CaptureMouseImpl>();
} | O3 | cpp | ftxui::ComponentBase::CaptureMouse(ftxui::Event const&):
pushq %rbx
movq %rdi, %rbx
movq (%rdx), %rsi
testq %rsi, %rsi
je 0x27248
movq %rbx, %rdi
callq 0x2d5ac
jmp 0x2725f
movl $0x8, %edi
callq 0xb3e0
leaq 0x30acf(%rip), %rcx # 0x57d28
movq %rcx, (%rax)
movq %rax, (%rbx)
movq %rbx, %rax
popq %rbx
retq
| _ZN5ftxui13ComponentBase12CaptureMouseERKNS_5EventE:
push rbx
mov rbx, rdi
mov rsi, [rdx]
test rsi, rsi
jz short loc_27248
mov rdi, rbx; this
call _ZN5ftxui17ScreenInteractive12CaptureMouseEv; ftxui::ScreenInteractive::CaptureMouse(void)
jmp short loc_2725F
loc_27248:
mov edi, 8; unsigned __int64
call __Znwm; operator new(ulong)
lea rcx, off_57D28
mov [rax], rcx
mov [rbx], rax
loc_2725F:
mov rax, rbx
pop rbx
retn
| ftxui::ComponentBase * ftxui::ComponentBase::CaptureMouse(
ftxui::ComponentBase *this,
const ftxui::Event *a2,
_QWORD *a3)
{
_QWORD *v3; // rax
if ( *a3 )
{
ftxui::ScreenInteractive::CaptureMouse(this);
}
else
{
v3 = (_QWORD *)operator new(8uLL);
*v3 = off_57D28;
*(_QWORD *)this = v3;
}
return this;
}
| CaptureMouse:
PUSH RBX
MOV RBX,RDI
MOV RSI,qword ptr [RDX]
TEST RSI,RSI
JZ 0x00127248
MOV RDI,RBX
CALL 0x0012d5ac
JMP 0x0012725f
LAB_00127248:
MOV EDI,0x8
CALL 0x0010b3e0
LEA RCX,[0x157d28]
MOV qword ptr [RAX],RCX
MOV qword ptr [RBX],RAX
LAB_0012725f:
MOV RAX,RBX
POP RBX
RET
|
/* ftxui::ComponentBase::CaptureMouse(ftxui::Event const&) */
Event * ftxui::ComponentBase::CaptureMouse(Event *param_1)
{
int8 *puVar1;
long *in_RDX;
if (*in_RDX == 0) {
puVar1 = (int8 *)operator_new(8);
*puVar1 = &PTR__CapturedMouseInterface_00157d28;
*(int8 **)param_1 = puVar1;
}
else {
ScreenInteractive::CaptureMouse();
}
return param_1;
}
| |
23,326 | 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::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator[]<char const>(char const*) | monkey531[P]llama/common/./json.hpp | reference operator[](T* key)
{
return operator[](typename object_t::key_type(key));
} | O3 | cpp | nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>& nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator[]<char const>(char const*):
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
leaq 0x7(%rsp), %rdx
movq %r14, %rdi
callq 0x233f4
movq %rbx, %rdi
movq %r14, %rsi
callq 0x6fb22
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x690cd
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r14
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x690f6
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
movq %rbx, %rdi
callq 0x18b90
| _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERSD_PT_:
push r14
push rbx
sub rsp, 28h
mov rbx, rdi
lea r14, [rsp+38h+var_30]
lea rdx, [rsp+38h+var_31]
mov rdi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
mov rdi, rbx
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixES9_; 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[](std::string)
mov rbx, rax
lea rax, [rsp+38h+var_20]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_690CD
mov rsi, [rsp+38h+var_20]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_690CD:
mov rax, rbx
add rsp, 28h
pop rbx
pop r14
retn
mov rbx, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_690F6
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_690F6:
mov rdi, rbx
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator[]<char const>(
long long a1,
long long a2)
{
long long v2; // rbx
void *v4[2]; // [rsp+8h] [rbp-30h] BYREF
long long v5; // [rsp+18h] [rbp-20h] BYREF
std::string::basic_string<std::allocator<char>>(v4, a2);
v2 = 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[](
a1,
v4);
if ( v4[0] != &v5 )
operator delete(v4[0], v5 + 1);
return v2;
}
| operator[]<char_const>:
PUSH R14
PUSH RBX
SUB RSP,0x28
MOV RBX,RDI
LEA R14,[RSP + 0x8]
LEA RDX,[RSP + 0x7]
MOV RDI,R14
CALL 0x001233f4
LAB_001690a4:
MOV RDI,RBX
MOV RSI,R14
CALL 0x0016fb22
LAB_001690af:
MOV RBX,RAX
LEA RAX,[RSP + 0x18]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x001690cd
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001186a0
LAB_001690cd:
MOV RAX,RBX
ADD RSP,0x28
POP RBX
POP R14
RET
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>& nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>::operator[]<char const>(char const*) */
basic_json * __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::operator[]<char_const>
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,char *param_1)
{
basic_json *pbVar1;
allocator local_31;
long *local_30 [2];
long local_20 [2];
std::__cxx11::string::string<std::allocator<char>>((string *)local_30,param_1,&local_31);
/* try { // try from 001690a4 to 001690ae has its CatchHandler @ 001690d8 */
pbVar1 = (basic_json *)operator[](this,(string *)local_30);
if (local_30[0] != local_20) {
operator_delete(local_30[0],local_20[0] + 1);
}
return pbVar1;
}
| |
23,327 | 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;
} | O0 | c | ftb_phrase_add_word:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x10(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x18(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, (%rax)
movslq -0x1c(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movq (%rax), %rcx
movq -0x30(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x30(%rbp), %rax
movl 0x18(%rax), %eax
movq -0x30(%rbp), %rcx
cmpl 0x1c(%rcx), %eax
jbe 0x9fa36
movq -0x30(%rbp), %rax
movl 0x1c(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x1c(%rax)
movl $0x0, -0x4(%rbp)
jmp 0x9faf3
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x40(%rbp)
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, -0x48(%rbp)
cmpq $0x0, -0x40(%rbp)
je 0x9fadf
movq -0x40(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x48(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movq 0xc0(%rax), %rax
movq 0x8(%rax), %rax
movq -0x30(%rbp), %rcx
movq 0x10(%rcx), %rdi
movq -0x50(%rbp), %rcx
movq (%rcx), %rsi
movq -0x50(%rbp), %rcx
movq 0x10(%rcx), %rdx
movq -0x58(%rbp), %rcx
movq (%rcx), %rcx
movq -0x58(%rbp), %r8
movq 0x10(%r8), %r8
xorl %r9d, %r9d
callq *%rax
cmpl $0x0, %eax
je 0x9fac0
movl $0x0, -0x4(%rbp)
jmp 0x9faf3
jmp 0x9fac2
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x40(%rbp)
movq -0x48(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x48(%rbp)
jmp 0x9fa51
movq -0x30(%rbp), %rax
movl 0x20(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x20(%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
| ftb_phrase_add_word:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_1C], edx
mov [rbp+var_28], rcx
mov rax, [rbp+var_10]
mov rax, [rax+18h]
mov [rbp+var_30], rax
mov rax, [rbp+var_30]
mov rax, [rax+8]
mov rax, [rax+10h]
mov [rbp+var_38], rax
mov rcx, [rbp+var_18]
mov rax, [rbp+var_38]
mov [rax], rcx
movsxd rcx, [rbp+var_1C]
mov rax, [rbp+var_38]
mov [rax+10h], rcx
mov rax, [rbp+var_30]
mov rax, [rax+8]
mov rcx, [rax]
mov rax, [rbp+var_30]
mov [rax+8], rcx
mov rax, [rbp+var_30]
mov eax, [rax+18h]
mov rcx, [rbp+var_30]
cmp eax, [rcx+1Ch]
jbe short loc_9FA36
mov rax, [rbp+var_30]
mov ecx, [rax+1Ch]
add ecx, 1
mov [rax+1Ch], ecx
mov [rbp+var_4], 0
jmp loc_9FAF3
loc_9FA36:
mov rax, [rbp+var_30]
mov rax, [rax]
mov [rbp+var_40], rax
mov rax, [rbp+var_30]
mov rax, [rax+8]
mov rax, [rax+8]
mov [rbp+var_48], rax
loc_9FA51:
cmp [rbp+var_40], 0
jz loc_9FADF
mov rax, [rbp+var_40]
mov rax, [rax+10h]
mov [rbp+var_50], rax
mov rax, [rbp+var_48]
mov rax, [rax+10h]
mov [rbp+var_58], rax
mov rax, [rbp+var_30]
mov rax, [rax+10h]
mov rax, [rax+0C0h]
mov rax, [rax+8]
mov rcx, [rbp+var_30]
mov rdi, [rcx+10h]
mov rcx, [rbp+var_50]
mov rsi, [rcx]
mov rcx, [rbp+var_50]
mov rdx, [rcx+10h]
mov rcx, [rbp+var_58]
mov rcx, [rcx]
mov r8, [rbp+var_58]
mov r8, [r8+10h]
xor r9d, r9d
call rax
cmp eax, 0
jz short loc_9FAC0
mov [rbp+var_4], 0
jmp short loc_9FAF3
loc_9FAC0:
jmp short $+2
loc_9FAC2:
mov rax, [rbp+var_40]
mov rax, [rax+8]
mov [rbp+var_40], rax
mov rax, [rbp+var_48]
mov rax, [rax+8]
mov [rbp+var_48], rax
jmp loc_9FA51
loc_9FADF:
mov rax, [rbp+var_30]
mov ecx, [rax+20h]
add ecx, 1
mov [rax+20h], ecx
mov [rbp+var_4], 0
loc_9FAF3:
mov eax, [rbp+var_4]
add rsp, 60h
pop rbp
retn
| long long ftb_phrase_add_word(long long a1, long long a2, int a3)
{
long long v4; // [rsp+18h] [rbp-48h]
long long v5; // [rsp+20h] [rbp-40h]
_QWORD *v6; // [rsp+28h] [rbp-38h]
long long *v7; // [rsp+30h] [rbp-30h]
v7 = *(long long **)(a1 + 24);
v6 = *(_QWORD **)(v7[1] + 16);
*v6 = a2;
v6[2] = a3;
v7[1] = *(_QWORD *)v7[1];
if ( *((_DWORD *)v7 + 6) <= *((_DWORD *)v7 + 7) )
{
v5 = *v7;
v4 = *(_QWORD *)(v7[1] + 8);
while ( v5 )
{
if ( (*(unsigned int ( **)(long long, _QWORD, _QWORD, _QWORD, _QWORD, _QWORD))(*(_QWORD *)(v7[2] + 192)
+ 8LL))(
v7[2],
**(_QWORD **)(v5 + 16),
*(_QWORD *)(*(_QWORD *)(v5 + 16) + 16LL),
**(_QWORD **)(v4 + 16),
*(_QWORD *)(*(_QWORD *)(v4 + 16) + 16LL),
0LL) )
{
return 0LL;
}
v5 = *(_QWORD *)(v5 + 8);
v4 = *(_QWORD *)(v4 + 8);
}
++*((_DWORD *)v7 + 8);
}
else
{
++*((_DWORD *)v7 + 7);
}
return 0LL;
}
| ftb_phrase_add_word:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV dword ptr [RBP + -0x1c],EDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x38],RAX
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX],RCX
MOVSXD RCX,dword ptr [RBP + -0x1c]
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX + 0x10],RCX
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RBP + -0x30]
MOV EAX,dword ptr [RAX + 0x18]
MOV RCX,qword ptr [RBP + -0x30]
CMP EAX,dword ptr [RCX + 0x1c]
JBE 0x0019fa36
MOV RAX,qword ptr [RBP + -0x30]
MOV ECX,dword ptr [RAX + 0x1c]
ADD ECX,0x1
MOV dword ptr [RAX + 0x1c],ECX
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0019faf3
LAB_0019fa36:
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x48],RAX
LAB_0019fa51:
CMP qword ptr [RBP + -0x40],0x0
JZ 0x0019fadf
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RAX + 0xc0]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x30]
MOV RDI,qword ptr [RCX + 0x10]
MOV RCX,qword ptr [RBP + -0x50]
MOV RSI,qword ptr [RCX]
MOV RCX,qword ptr [RBP + -0x50]
MOV RDX,qword ptr [RCX + 0x10]
MOV RCX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RCX]
MOV R8,qword ptr [RBP + -0x58]
MOV R8,qword ptr [R8 + 0x10]
XOR R9D,R9D
CALL RAX
CMP EAX,0x0
JZ 0x0019fac0
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0019faf3
LAB_0019fac0:
JMP 0x0019fac2
LAB_0019fac2:
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x48],RAX
JMP 0x0019fa51
LAB_0019fadf:
MOV RAX,qword ptr [RBP + -0x30]
MOV ECX,dword ptr [RAX + 0x20]
ADD ECX,0x1
MOV dword ptr [RAX + 0x20],ECX
MOV dword ptr [RBP + -0x4],0x0
LAB_0019faf3:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x60
POP RBP
RET
|
int4 ftb_phrase_add_word(long param_1,int8 param_2,int param_3)
{
long *plVar1;
int8 *puVar2;
int iVar3;
long local_50;
long local_48;
plVar1 = *(long **)(param_1 + 0x18);
puVar2 = *(int8 **)(plVar1[1] + 0x10);
*puVar2 = param_2;
puVar2[2] = (long)param_3;
plVar1[1] = *(long *)plVar1[1];
if (*(uint *)((long)plVar1 + 0x1c) < *(uint *)(plVar1 + 3)) {
*(int *)((long)plVar1 + 0x1c) = *(int *)((long)plVar1 + 0x1c) + 1;
}
else {
local_50 = *(long *)(plVar1[1] + 8);
for (local_48 = *plVar1; local_48 != 0; local_48 = *(long *)(local_48 + 8)) {
iVar3 = (**(code **)(*(long *)(plVar1[2] + 0xc0) + 8))
(plVar1[2],**(int8 **)(local_48 + 0x10),
(*(int8 **)(local_48 + 0x10))[2],**(int8 **)(local_50 + 0x10),
(*(int8 **)(local_50 + 0x10))[2],0);
if (iVar3 != 0) {
return 0;
}
local_50 = *(long *)(local_50 + 8);
}
*(int *)(plVar1 + 4) = (int)plVar1[4] + 1;
}
return 0;
}
| |
23,328 | 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 0x741ba
incl %eax
movl %eax, 0x1c(%rbx)
jmp 0x741fb
movq (%rbx), %r15
testq %r15, %r15
je 0x741f8
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 0x741fb
movq 0x8(%r15), %r15
jmp 0x741bd
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_741BA
inc eax
mov [rbx+1Ch], eax
jmp short loc_741FB
loc_741BA:
mov r15, [rbx]
loc_741BD:
test r15, r15
jz short loc_741F8
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_741FB
mov r15, [r15+8]
jmp short loc_741BD
loc_741F8:
inc dword ptr [rbx+20h]
loc_741FB:
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 0x001741ba
INC EAX
MOV dword ptr [RBX + 0x1c],EAX
JMP 0x001741fb
LAB_001741ba:
MOV R15,qword ptr [RBX]
LAB_001741bd:
TEST R15,R15
JZ 0x001741f8
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 0x001741fb
MOV R15,qword ptr [R15 + 0x8]
JMP 0x001741bd
LAB_001741f8:
INC dword ptr [RBX + 0x20]
LAB_001741fb:
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;
}
| |
23,329 | StableDiffusionGGML::get_learned_condition(ggml_context*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int, int, int, bool) | 7CodeWizard[P]stablediffusion/stable-diffusion.cpp | std::pair<ggml_tensor*, ggml_tensor*> get_learned_condition(ggml_context* work_ctx,
const std::string& text,
int clip_skip,
int width,
int height,
bool force_zero_embeddings = false) {
cond_stage_model.set_clip_skip(clip_skip);
auto tokens_and_weights = cond_stage_model.tokenize(text, true);
std::vector<int>& tokens = tokens_and_weights.first;
std::vector<float>& weights = tokens_and_weights.second;
int64_t t0 = ggml_time_ms();
struct ggml_tensor* pooled = NULL;
size_t total_hidden_size = cond_stage_model.text_model.hidden_size;
if (version == VERSION_XL) {
total_hidden_size += cond_stage_model.text_model2.hidden_size;
pooled = ggml_new_tensor_1d(work_ctx, GGML_TYPE_F32, cond_stage_model.text_model2.projection_dim);
}
struct ggml_tensor* hidden_states = ggml_new_tensor_2d(work_ctx,
GGML_TYPE_F32,
total_hidden_size,
cond_stage_model.text_model.max_position_embeddings); // [N, n_token, hidden_size]
cond_stage_model.alloc_compute_buffer(work_ctx, (int)tokens.size());
cond_stage_model.compute(n_threads, tokens, hidden_states, pooled);
cond_stage_model.free_compute_buffer();
// if (pooled != NULL) {
// print_ggml_tensor(hidden_states);
// print_ggml_tensor(pooled);
// }
int64_t t1 = ggml_time_ms();
LOG_DEBUG("computing condition graph completed, taking %" PRId64 " ms", t1 - t0);
ggml_tensor* result = ggml_dup_tensor(work_ctx, hidden_states);
{
float original_mean = ggml_tensor_mean(hidden_states);
for (int i2 = 0; i2 < hidden_states->ne[2]; i2++) {
for (int i1 = 0; i1 < hidden_states->ne[1]; i1++) {
for (int i0 = 0; i0 < hidden_states->ne[0]; i0++) {
float value = ggml_tensor_get_f32(hidden_states, i0, i1, i2);
value *= weights[i1];
ggml_tensor_set_f32(result, value, i0, i1, i2);
}
}
}
float new_mean = ggml_tensor_mean(result);
ggml_tensor_scale(result, (original_mean / new_mean));
}
if (force_zero_embeddings) {
float* vec = (float*)result->data;
for (int i = 0; i < ggml_nelements(result); i++) {
vec[i] = 0;
}
}
ggml_tensor* vec = NULL;
if (version == VERSION_XL) {
int out_dim = 256;
vec = ggml_new_tensor_1d(work_ctx, GGML_TYPE_F32, diffusion_model.adm_in_channels);
// [0:1280]
size_t offset = 0;
memcpy(vec->data, pooled->data, ggml_nbytes(pooled));
offset += ggml_nbytes(pooled);
struct ggml_tensor* timesteps = ggml_new_tensor_1d(work_ctx, GGML_TYPE_F32, 2);
// original_size_as_tuple
float orig_width = (float)width;
float orig_height = (float)height;
ggml_tensor_set_f32(timesteps, orig_height, 0);
ggml_tensor_set_f32(timesteps, orig_width, 1);
ggml_tensor* embed_view = ggml_view_2d(work_ctx, vec, out_dim, 2, ggml_type_size(GGML_TYPE_F32) * out_dim, offset);
offset += ggml_nbytes(embed_view);
set_timestep_embedding(timesteps, embed_view, out_dim);
// print_ggml_tensor(ggml_reshape_1d(work_ctx, embed_view, out_dim * 2));
// crop_coords_top_left
float crop_coord_top = 0.f;
float crop_coord_left = 0.f;
ggml_tensor_set_f32(timesteps, crop_coord_top, 0);
ggml_tensor_set_f32(timesteps, crop_coord_left, 1);
embed_view = ggml_view_2d(work_ctx, vec, out_dim, 2, ggml_type_size(GGML_TYPE_F32) * out_dim, offset);
offset += ggml_nbytes(embed_view);
set_timestep_embedding(timesteps, embed_view, out_dim);
// print_ggml_tensor(ggml_reshape_1d(work_ctx, embed_view, out_dim * 2));
// target_size_as_tuple
float target_width = (float)width;
float target_height = (float)height;
ggml_tensor_set_f32(timesteps, target_height, 0);
ggml_tensor_set_f32(timesteps, target_width, 1);
embed_view = ggml_view_2d(work_ctx, vec, out_dim, 2, ggml_type_size(GGML_TYPE_F32) * out_dim, offset);
offset += ggml_nbytes(embed_view);
set_timestep_embedding(timesteps, embed_view, out_dim);
// print_ggml_tensor(ggml_reshape_1d(work_ctx, embed_view, out_dim * 2));
GGML_ASSERT(offset == ggml_nbytes(vec));
}
// print_ggml_tensor(result);
return {result, vec};
} | O2 | cpp | StableDiffusionGGML::get_learned_condition(ggml_context*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int, int, int, bool):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movl %r9d, 0x1c(%rsp)
movl %r8d, %ebp
movq %rdx, %rbx
movq %rsi, (%rsp)
movq %rdi, %r12
leaq 0x20(%rdi), %r14
movq %r14, %rdi
movl %ecx, %esi
callq 0x32444
leaq 0x68(%rsp), %r15
movq %r15, %rdi
movq %rbx, %rsi
callq 0xa840
leaq 0x38(%rsp), %rdi
pushq $0x1
popq %rcx
movq %r14, %rsi
movq %r15, %rdx
callq 0x3246e
leaq 0x68(%rsp), %rdi
callq 0xac60
callq 0x67697
movq %rax, %r15
movslq 0x154(%r12), %rbx
cmpl $0x2, (%r12)
movl %ebp, 0x18(%rsp)
jne 0x1ec9c
movslq 0x1c4(%r12), %r13
movslq 0x1d8(%r12), %rdx
movq (%rsp), %rdi
xorl %esi, %esi
callq 0x68616
movq %rax, 0x10(%rsp)
addq %r13, %rbx
jmp 0x1eca5
movq $0x0, 0x10(%rsp)
movslq 0x150(%r12), %rcx
movq (%rsp), %rdi
xorl %esi, %esi
movq %rbx, %rdx
callq 0x68627
movq %rax, %rbp
movq 0x40(%rsp), %rdx
subq 0x38(%rsp), %rdx
shrq $0x2, %rdx
movq %r14, %rdi
movq (%rsp), %rsi
callq 0x324d6
movl 0x18(%r12), %ebx
leaq 0x20(%rsp), %rdi
leaq 0x38(%rsp), %rsi
callq 0x325e2
leaq 0x20(%rsp), %rdx
movq %r14, %rdi
movl %ebx, %esi
movq %rbp, %rcx
movq 0x10(%rsp), %r8
callq 0x3252e
leaq 0x20(%rsp), %rdi
callq 0x22d64
movq %r14, %rdi
callq 0x2d2d6
callq 0x67697
subq %r15, %rax
leaq 0x7aef1(%rip), %rsi # 0x99c15
leaq 0x7c0ec(%rip), %rcx # 0x9ae17
xorl %edi, %edi
movl $0x1b9, %edx # imm = 0x1B9
movq %rax, %r8
xorl %eax, %eax
callq 0x55f59
movq (%rsp), %rdi
movq %rbp, %rsi
callq 0x68a65
movq %rax, %r14
movq %rbp, %rdi
callq 0x1d06a
movss %xmm0, 0xc(%rsp)
xorl %r15d, %r15d
cmpq %r15, 0x20(%rbp)
jle 0x1edb3
xorl %r13d, %r13d
cmpq %r13, 0x18(%rbp)
jle 0x1edae
xorl %ebx, %ebx
cmpq %rbx, 0x10(%rbp)
jle 0x1eda9
movq %rbp, %rdi
movl %ebx, %esi
movl %r13d, %edx
movl %r15d, %ecx
xorl %r8d, %r8d
callq 0x1d0a4
movq 0x50(%rsp), %rax
mulss (%rax,%r13,4), %xmm0
movq %r14, %rdi
movl %ebx, %esi
movl %r13d, %edx
movl %r15d, %ecx
xorl %r8d, %r8d
callq 0x1cdf4
incq %rbx
jmp 0x1ed6d
incq %r13
jmp 0x1ed65
incq %r15
jmp 0x1ed5c
movq %r14, %rdi
callq 0x1d06a
movss 0xc(%rsp), %xmm1
divss %xmm0, %xmm1
movq %r14, %rdi
movaps %xmm1, %xmm0
callq 0x1d11c
cmpb $0x0, 0xc0(%rsp)
movq 0x10(%rsp), %r13
je 0x1ee00
movq 0x118(%r14), %rbx
xorl %r15d, %r15d
movq %r14, %rdi
callq 0x67ada
cmpq %r15, %rax
jle 0x1ee00
andl $0x0, (%rbx,%r15,4)
incq %r15
jmp 0x1ede9
cmpl $0x2, (%r12)
jne 0x1f017
movslq 0x300(%r12), %rdx
movq (%rsp), %rdi
xorl %esi, %esi
callq 0x68616
movq %rax, %r12
movq 0x118(%rax), %rbx
movq 0x118(%r13), %r15
movq %r13, %rdi
callq 0x67afd
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0xa4c0
movq %r13, %rdi
callq 0x67afd
movq %rax, %rbp
pushq $0x2
popq %rdx
movq (%rsp), %rdi
xorl %esi, %esi
callq 0x68616
movq %rax, %r13
cvtsi2ssl 0x1c(%rsp), %xmm0
movq %rax, %rdi
movss %xmm0, 0x10(%rsp)
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x1cdf4
cvtsi2ssl 0x18(%rsp), %xmm0
pushq $0x1
popq %rsi
movq %r13, %rdi
movss %xmm0, 0xc(%rsp)
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x1cdf4
xorl %edi, %edi
callq 0x67b83
shlq $0x8, %rax
pushq $0x2
popq %rcx
movl $0x100, %edx # imm = 0x100
movq (%rsp), %rdi
movq %r12, %rsi
movq %rax, %r8
movq %rbp, %r9
callq 0x6c17f
movq %rax, %rbx
movq %rax, %rdi
callq 0x67afd
movq %rax, %r15
movq %r13, %rdi
movq %rbx, %rsi
movl $0x100, %edx # imm = 0x100
callq 0x1cca5
xorps %xmm0, %xmm0
movq %r13, %rdi
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x1cdf4
pushq $0x1
popq %rsi
xorps %xmm0, %xmm0
movq %r13, %rdi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x1cdf4
xorl %edi, %edi
callq 0x67b83
addq %rbp, %r15
shlq $0x8, %rax
pushq $0x2
popq %rcx
movl $0x100, %edx # imm = 0x100
movq (%rsp), %rdi
movq %r12, %rsi
movq %rax, %r8
movq %r15, %r9
callq 0x6c17f
movq %rax, %rbx
movq %rax, %rdi
callq 0x67afd
movq %rax, %rbp
movq %r13, %rdi
movq %rbx, %rsi
movl $0x100, %edx # imm = 0x100
callq 0x1cca5
movq %r13, %rdi
movss 0x10(%rsp), %xmm0
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x1cdf4
pushq $0x1
popq %rsi
movq %r13, %rdi
movss 0xc(%rsp), %xmm0
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x1cdf4
xorl %edi, %edi
callq 0x67b83
addq %r15, %rbp
shlq $0x8, %rax
pushq $0x2
popq %rcx
movl $0x100, %edx # imm = 0x100
movq (%rsp), %rdi
movq %r12, %rsi
movq %rax, %r8
movq %rbp, %r9
callq 0x6c17f
movq %rax, %r15
movq %rax, %rdi
callq 0x67afd
movq %rax, %rbx
movq %r13, %rdi
movq %r15, %rsi
movl $0x100, %edx # imm = 0x100
callq 0x1cca5
movq %r12, %rdi
callq 0x67afd
addq %rbp, %rbx
cmpq %rax, %rbx
je 0x1f01a
movq 0xb6f6e(%rip), %rax # 0xd5f48
movq (%rax), %rdi
callq 0xa6f0
movq 0xb6fbf(%rip), %rax # 0xd5fa8
movq (%rax), %rdi
leaq 0x7b22b(%rip), %rsi # 0x9a21e
leaq 0x7ac1b(%rip), %rdx # 0x99c15
leaq 0x7be49(%rip), %r8 # 0x9ae4a
movl $0x1f5, %ecx # imm = 0x1F5
xorl %eax, %eax
callq 0xa8b0
callq 0x67550
callq 0xa300
xorl %r12d, %r12d
leaq 0x38(%rsp), %rdi
callq 0x32630
movq %r14, %rax
movq %r12, %rdx
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x22d64
jmp 0x1f07b
jmp 0x1f078
movq %rax, %rbx
leaq 0x68(%rsp), %rdi
callq 0xac60
jmp 0x1f085
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
jmp 0x1f078
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x32630
movq %rbx, %rdi
callq 0xaab0
nop
| _ZN19StableDiffusionGGML21get_learned_conditionEP12ggml_contextRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiib:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 88h
mov [rsp+0B8h+var_9C], r9d
mov ebp, r8d
mov rbx, rdx
mov [rsp+0B8h+var_B8], rsi
mov r12, rdi
lea r14, [rdi+20h]
mov rdi, r14; this
mov esi, ecx; int
call _ZN33FrozenCLIPEmbedderWithCustomWords13set_clip_skipEi; FrozenCLIPEmbedderWithCustomWords::set_clip_skip(int)
lea r15, [rsp+0B8h+var_50]
mov rdi, r15
mov rsi, rbx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2ERKS4_; std::string::basic_string(std::string const&)
lea rdi, [rsp+0B8h+var_80]
push 1
pop rcx
mov rsi, r14
mov rdx, r15
call _ZN33FrozenCLIPEmbedderWithCustomWords8tokenizeENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEb; FrozenCLIPEmbedderWithCustomWords::tokenize(std::string,bool)
lea rdi, [rsp+0B8h+var_50]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
call ggml_time_ms
mov r15, rax
movsxd rbx, dword ptr [r12+154h]
cmp dword ptr [r12], 2
mov [rsp+0B8h+var_A0], ebp
jnz short loc_1EC9C
movsxd r13, dword ptr [r12+1C4h]
movsxd rdx, dword ptr [r12+1D8h]
mov rdi, [rsp+0B8h+var_B8]
xor esi, esi
call ggml_new_tensor_1d
mov [rsp+0B8h+var_A8], rax
add rbx, r13
jmp short loc_1ECA5
loc_1EC9C:
mov [rsp+0B8h+var_A8], 0
loc_1ECA5:
movsxd rcx, dword ptr [r12+150h]
mov rdi, [rsp+0B8h+var_B8]
xor esi, esi
mov rdx, rbx
call ggml_new_tensor_2d
mov rbp, rax
mov rdx, [rsp+0B8h+var_78]
sub rdx, [rsp+0B8h+var_80]
shr rdx, 2
mov rdi, r14
mov rsi, [rsp+0B8h+var_B8]
call _ZN33FrozenCLIPEmbedderWithCustomWords20alloc_compute_bufferEP12ggml_contexti; FrozenCLIPEmbedderWithCustomWords::alloc_compute_buffer(ggml_context *,int)
mov ebx, [r12+18h]
lea rdi, [rsp+0B8h+var_98]
lea rsi, [rsp+0B8h+var_80]
call _ZNSt6vectorIiSaIiEEC2ERKS1_; std::vector<int>::vector(std::vector<int> const&)
lea rdx, [rsp+0B8h+var_98]
mov rdi, r14
mov esi, ebx
mov rcx, rbp
mov r8, [rsp+0B8h+var_A8]
call _ZN33FrozenCLIPEmbedderWithCustomWords7computeEiSt6vectorIiSaIiEEP11ggml_tensorS4_; FrozenCLIPEmbedderWithCustomWords::compute(int,std::vector<int>,ggml_tensor *,ggml_tensor *)
lea rdi, [rsp+0B8h+var_98]
call _ZNSt12_Vector_baseIiSaIiEED2Ev; std::_Vector_base<int>::~_Vector_base()
mov rdi, r14; this
call _ZN10GGMLModule19free_compute_bufferEv; GGMLModule::free_compute_buffer(void)
call ggml_time_ms
sub rax, r15
lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aComputingCondi; "computing condition graph completed, ta"...
xor edi, edi
mov edx, 1B9h
mov r8, rax
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, [rsp+0B8h+var_B8]
mov rsi, rbp
call ggml_dup_tensor
mov r14, rax
mov rdi, rbp
call _ZL16ggml_tensor_meanP11ggml_tensor; ggml_tensor_mean(ggml_tensor *)
movss [rsp+0B8h+var_AC], xmm0
xor r15d, r15d
loc_1ED5C:
cmp [rbp+20h], r15
jle short loc_1EDB3
xor r13d, r13d
loc_1ED65:
cmp [rbp+18h], r13
jle short loc_1EDAE
xor ebx, ebx
loc_1ED6D:
cmp [rbp+10h], rbx
jle short loc_1EDA9
mov rdi, rbp
mov esi, ebx
mov edx, r13d
mov ecx, r15d
xor r8d, r8d
call _ZL19ggml_tensor_get_f32PK11ggml_tensoriiii; ggml_tensor_get_f32(ggml_tensor const*,int,int,int,int)
mov rax, [rsp+0B8h+var_68]
mulss xmm0, dword ptr [rax+r13*4]
mov rdi, r14
mov esi, ebx
mov edx, r13d
mov ecx, r15d
xor r8d, r8d
call _ZL19ggml_tensor_set_f32P11ggml_tensorfiiii; ggml_tensor_set_f32(ggml_tensor *,float,int,int,int,int)
inc rbx
jmp short loc_1ED6D
loc_1EDA9:
inc r13
jmp short loc_1ED65
loc_1EDAE:
inc r15
jmp short loc_1ED5C
loc_1EDB3:
mov rdi, r14
call _ZL16ggml_tensor_meanP11ggml_tensor; ggml_tensor_mean(ggml_tensor *)
movss xmm1, [rsp+0B8h+var_AC]
divss xmm1, xmm0
mov rdi, r14
movaps xmm0, xmm1
call _ZL17ggml_tensor_scaleP11ggml_tensorf; ggml_tensor_scale(ggml_tensor *,float)
cmp [rsp+0B8h+arg_0], 0
mov r13, [rsp+0B8h+var_A8]
jz short loc_1EE00
mov rbx, [r14+118h]
xor r15d, r15d
loc_1EDE9:
mov rdi, r14
call ggml_nelements
cmp rax, r15
jle short loc_1EE00
and dword ptr [rbx+r15*4], 0
inc r15
jmp short loc_1EDE9
loc_1EE00:
cmp dword ptr [r12], 2
jnz loc_1F017
movsxd rdx, dword ptr [r12+300h]
mov rdi, [rsp+0B8h+var_B8]
xor esi, esi
call ggml_new_tensor_1d
mov r12, rax
mov rbx, [rax+118h]
mov r15, [r13+118h]
mov rdi, r13
call ggml_nbytes
mov rdi, rbx
mov rsi, r15
mov rdx, rax
call _memcpy
mov rdi, r13
call ggml_nbytes
mov rbp, rax
push 2
pop rdx
mov rdi, [rsp+0B8h+var_B8]
xor esi, esi
call ggml_new_tensor_1d
mov r13, rax
cvtsi2ss xmm0, [rsp+0B8h+var_9C]
mov rdi, rax
movss dword ptr [rsp+0B8h+var_A8], xmm0
xor esi, esi
xor edx, edx
xor ecx, ecx
xor r8d, r8d
call _ZL19ggml_tensor_set_f32P11ggml_tensorfiiii; ggml_tensor_set_f32(ggml_tensor *,float,int,int,int,int)
cvtsi2ss xmm0, [rsp+0B8h+var_A0]
push 1
pop rsi
mov rdi, r13
movss [rsp+0B8h+var_AC], xmm0
xor edx, edx
xor ecx, ecx
xor r8d, r8d
call _ZL19ggml_tensor_set_f32P11ggml_tensorfiiii; ggml_tensor_set_f32(ggml_tensor *,float,int,int,int,int)
xor edi, edi
call ggml_type_size
shl rax, 8
push 2
pop rcx
mov edx, 100h
mov rdi, [rsp+0B8h+var_B8]
mov rsi, r12
mov r8, rax
mov r9, rbp
call ggml_view_2d
mov rbx, rax
mov rdi, rax
call ggml_nbytes
mov r15, rax
mov rdi, r13
mov rsi, rbx
mov edx, 100h
call _ZL22set_timestep_embeddingP11ggml_tensorS0_ii; set_timestep_embedding(ggml_tensor *,ggml_tensor *,int,int)
xorps xmm0, xmm0
mov rdi, r13
xor esi, esi
xor edx, edx
xor ecx, ecx
xor r8d, r8d
call _ZL19ggml_tensor_set_f32P11ggml_tensorfiiii; ggml_tensor_set_f32(ggml_tensor *,float,int,int,int,int)
push 1
pop rsi
xorps xmm0, xmm0
mov rdi, r13
xor edx, edx
xor ecx, ecx
xor r8d, r8d
call _ZL19ggml_tensor_set_f32P11ggml_tensorfiiii; ggml_tensor_set_f32(ggml_tensor *,float,int,int,int,int)
xor edi, edi
call ggml_type_size
add r15, rbp
shl rax, 8
push 2
pop rcx
mov edx, 100h
mov rdi, [rsp+0B8h+var_B8]
mov rsi, r12
mov r8, rax
mov r9, r15
call ggml_view_2d
mov rbx, rax
mov rdi, rax
call ggml_nbytes
mov rbp, rax
mov rdi, r13
mov rsi, rbx
mov edx, 100h
call _ZL22set_timestep_embeddingP11ggml_tensorS0_ii; set_timestep_embedding(ggml_tensor *,ggml_tensor *,int,int)
mov rdi, r13
movss xmm0, dword ptr [rsp+0B8h+var_A8]
xor esi, esi
xor edx, edx
xor ecx, ecx
xor r8d, r8d
call _ZL19ggml_tensor_set_f32P11ggml_tensorfiiii; ggml_tensor_set_f32(ggml_tensor *,float,int,int,int,int)
push 1
pop rsi
mov rdi, r13
movss xmm0, [rsp+0B8h+var_AC]
xor edx, edx
xor ecx, ecx
xor r8d, r8d
call _ZL19ggml_tensor_set_f32P11ggml_tensorfiiii; ggml_tensor_set_f32(ggml_tensor *,float,int,int,int,int)
xor edi, edi
call ggml_type_size
add rbp, r15
shl rax, 8
push 2
pop rcx
mov edx, 100h
mov rdi, [rsp+0B8h+var_B8]
mov rsi, r12
mov r8, rax
mov r9, rbp
call ggml_view_2d
mov r15, rax
mov rdi, rax
call ggml_nbytes
mov rbx, rax
mov rdi, r13
mov rsi, r15
mov edx, 100h
call _ZL22set_timestep_embeddingP11ggml_tensorS0_ii; set_timestep_embedding(ggml_tensor *,ggml_tensor *,int,int)
mov rdi, r12
call ggml_nbytes
add rbx, rbp
cmp rbx, rax
jz short loc_1F01A
mov rax, cs:stdout_ptr
mov rdi, [rax]
call _fflush
mov rax, cs:stderr_ptr
mov rdi, [rax]
lea rsi, aGgmlAssertSDS; "GGML_ASSERT: %s:%d: %s\n"
lea rdx, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea r8, aOffsetGgmlNbyt; "offset == ggml_nbytes(vec)"
mov ecx, 1F5h
xor eax, eax
call _fprintf
call ggml_print_backtrace
call _abort
loc_1F017:
xor r12d, r12d
loc_1F01A:
lea rdi, [rsp+0B8h+var_80]
call _ZNSt4pairISt6vectorIiSaIiEES0_IfSaIfEEED2Ev; std::pair<std::vector<int>,std::vector<float>>::~pair()
mov rax, r14
mov rdx, r12
add rsp, 88h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
mov rbx, rax
lea rdi, [rsp+arg_18]
call _ZNSt12_Vector_baseIiSaIiEED2Ev; std::_Vector_base<int>::~_Vector_base()
jmp short loc_1F07B
jmp short loc_1F078
mov rbx, rax
lea rdi, [rsp+arg_60]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_1F085
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
jmp short loc_1F078
jmp short $+2
loc_1F078:
mov rbx, rax
loc_1F07B:
lea rdi, [rsp+arg_30]
call _ZNSt4pairISt6vectorIiSaIiEES0_IfSaIfEEED2Ev; std::pair<std::vector<int>,std::vector<float>>::~pair()
loc_1F085:
mov rdi, rbx
call __Unwind_Resume
| _QWORD * StableDiffusionGGML::get_learned_condition(
_DWORD *a1,
char a2,
long long a3,
int a4,
int a5,
int a6,
float a7,
char a8)
{
GGMLModule *v10; // r14
int v11; // r8d
int v12; // r9d
long long v13; // rdx
int v14; // r15d
long long v15; // rbx
long long v16; // r13
_QWORD *v17; // rbp
int v18; // ecx
int v19; // r8d
int v20; // r9d
unsigned int v21; // ebx
long long v22; // rdx
int v23; // eax
int v24; // r9d
_QWORD *v25; // r14
long long i; // r15
long long j; // r13
long long k; // rbx
float f32; // xmm0_4
long long v30; // rbx
long long m; // r15
long long v32; // r12
long long v33; // rbx
long long v34; // r15
long long v35; // rax
long long v36; // rbp
_QWORD *v37; // r13
long long v38; // rax
_QWORD *v39; // rbx
long long v40; // r15
long long v41; // rax
long long v42; // r15
_QWORD *v43; // rbx
long long v44; // rbp
long long v45; // rax
long long v46; // rbp
_QWORD *v47; // r15
long long v48; // rbx
long long v49; // rdi
double v50; // xmm0_8
long long v52; // [rsp+0h] [rbp-B8h]
long long v53; // [rsp+0h] [rbp-B8h]
float v54; // [rsp+Ch] [rbp-ACh]
long long v55; // [rsp+10h] [rbp-A8h]
int v56; // [rsp+18h] [rbp-A0h]
_BYTE v58[24]; // [rsp+20h] [rbp-98h] BYREF
_QWORD v59[6]; // [rsp+38h] [rbp-80h] BYREF
_BYTE v60[80]; // [rsp+68h] [rbp-50h] BYREF
v10 = (GGMLModule *)(a1 + 8);
FrozenCLIPEmbedderWithCustomWords::set_clip_skip((FrozenCLIPEmbedderWithCustomWords *)(a1 + 8), a4);
std::string::basic_string(v60, a3);
FrozenCLIPEmbedderWithCustomWords::tokenize((unsigned int)v59, (_DWORD)a1 + 32, (unsigned int)v60, 1, v11, v12, a2);
std::string::~string(v60);
v14 = ggml_time_ms(v60, a1 + 8, v13);
v15 = (int)a1[85];
v56 = a5;
if ( *a1 == 2 )
{
v16 = (int)a1[113];
v55 = ggml_new_tensor_1d(v52, 0LL, (int)a1[118]);
v15 += v16;
}
else
{
v55 = 0LL;
}
v17 = (_QWORD *)ggml_new_tensor_2d(v52, 0LL, v15, (int)a1[84]);
FrozenCLIPEmbedderWithCustomWords::alloc_compute_buffer((_DWORD)v10, v52, (v59[1] - v59[0]) >> 2, v18, v19, v20, v52);
v21 = a1[6];
std::vector<int>::vector(v58, v59);
FrozenCLIPEmbedderWithCustomWords::compute(v10, v21, v58, v17, v55);
std::_Vector_base<int>::~_Vector_base(v58);
GGMLModule::free_compute_buffer(v10);
v23 = ggml_time_ms(v10, v21, v22);
log_printf(
0,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/stable-diffusion.cpp",
441,
(unsigned int)"computing condition graph completed, taking %ld ms",
v23 - v14,
v24);
v25 = (_QWORD *)ggml_dup_tensor(v53, v17);
ggml_tensor_mean((long long)v17);
v54 = a7;
for ( i = 0LL; v17[4] > i; ++i )
{
for ( j = 0LL; v17[3] > j; ++j )
{
for ( k = 0LL; v17[2] > k; ++k )
{
f32 = ggml_tensor_get_f32(v17, k, j, i, 0);
a7 = f32 * *(float *)(v59[3] + 4 * j);
ggml_tensor_set_f32(v25, k, j, i, 0, a7);
}
}
}
ggml_tensor_mean((long long)v25);
ggml_tensor_scale((long long)v25, v54 / a7);
if ( a8 )
{
v30 = v25[35];
for ( m = 0LL; ggml_nelements(v25) > m; ++m )
*(_DWORD *)(v30 + 4 * m) = 0;
}
if ( *a1 == 2 )
{
v32 = ggml_new_tensor_1d(v53, 0LL, (int)a1[192]);
v33 = *(_QWORD *)(v32 + 280);
v34 = *(_QWORD *)(v55 + 280);
v35 = ggml_nbytes(v55);
memcpy(v33, v34, v35);
v36 = ggml_nbytes(v55);
v37 = (_QWORD *)ggml_new_tensor_1d(v53, 0LL, 2LL);
ggml_tensor_set_f32(v37, 0, 0, 0, 0, (float)a6);
ggml_tensor_set_f32(v37, 1, 0, 0, 0, (float)v56);
v38 = ggml_type_size(0LL);
v39 = (_QWORD *)ggml_view_2d(v53, v32, 256LL, 2LL, v38 << 8, v36);
v40 = ggml_nbytes(v39);
set_timestep_embedding((long long)v37, v39, 256);
ggml_tensor_set_f32(v37, 0, 0, 0, 0, 0.0);
ggml_tensor_set_f32(v37, 1, 0, 0, 0, 0.0);
v41 = ggml_type_size(0LL);
v42 = v36 + v40;
v43 = (_QWORD *)ggml_view_2d(v53, v32, 256LL, 2LL, v41 << 8, v42);
v44 = ggml_nbytes(v43);
set_timestep_embedding((long long)v37, v43, 256);
ggml_tensor_set_f32(v37, 0, 0, 0, 0, (float)a6);
ggml_tensor_set_f32(v37, 1, 0, 0, 0, (float)v56);
v45 = ggml_type_size(0LL);
v46 = v42 + v44;
v47 = (_QWORD *)ggml_view_2d(v53, v32, 256LL, 2LL, v45 << 8, v46);
v48 = ggml_nbytes(v47);
set_timestep_embedding((long long)v37, v47, 256);
if ( v46 + v48 != ggml_nbytes(v32) )
{
fflush(stdout);
v49 = stderr;
v50 = fprintf(
stderr,
"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/stable-diffusion.cpp",
501,
"offset == ggml_nbytes(vec)");
ggml_print_backtrace(v50);
abort(v49);
}
}
std::pair<std::vector<int>,std::vector<float>>::~pair(v59);
return v25;
}
| get_learned_condition:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x88
MOV dword ptr [RSP + 0x1c],R9D
MOV EBP,R8D
MOV RBX,RDX
MOV qword ptr [RSP],RSI
MOV R12,RDI
LEA R14,[RDI + 0x20]
MOV RDI,R14
MOV ESI,ECX
CALL 0x00132444
LEA R15,[RSP + 0x68]
MOV RDI,R15
MOV RSI,RBX
CALL 0x0010a840
LAB_0011ec3f:
LEA RDI,[RSP + 0x38]
PUSH 0x1
POP RCX
MOV RSI,R14
MOV RDX,R15
CALL 0x0013246e
LEA RDI,[RSP + 0x68]
CALL 0x0010ac60
LAB_0011ec5c:
CALL 0x00167697
MOV R15,RAX
MOVSXD RBX,dword ptr [R12 + 0x154]
CMP dword ptr [R12],0x2
MOV dword ptr [RSP + 0x18],EBP
JNZ 0x0011ec9c
MOVSXD R13,dword ptr [R12 + 0x1c4]
MOVSXD RDX,dword ptr [R12 + 0x1d8]
LAB_0011ec87:
MOV RDI,qword ptr [RSP]
XOR ESI,ESI
CALL 0x00168616
MOV qword ptr [RSP + 0x10],RAX
ADD RBX,R13
JMP 0x0011eca5
LAB_0011ec9c:
MOV qword ptr [RSP + 0x10],0x0
LAB_0011eca5:
MOVSXD RCX,dword ptr [R12 + 0x150]
LAB_0011ecad:
MOV RDI,qword ptr [RSP]
XOR ESI,ESI
MOV RDX,RBX
CALL 0x00168627
MOV RBP,RAX
MOV RDX,qword ptr [RSP + 0x40]
SUB RDX,qword ptr [RSP + 0x38]
SHR RDX,0x2
MOV RDI,R14
MOV RSI,qword ptr [RSP]
CALL 0x001324d6
MOV EBX,dword ptr [R12 + 0x18]
LEA RDI,[RSP + 0x20]
LEA RSI,[RSP + 0x38]
CALL 0x001325e2
LAB_0011ecec:
LEA RDX,[RSP + 0x20]
MOV RDI,R14
MOV ESI,EBX
MOV RCX,RBP
MOV R8,qword ptr [RSP + 0x10]
CALL 0x0013252e
LEA RDI,[RSP + 0x20]
CALL 0x00122d64
LAB_0011ed0d:
MOV RDI,R14
CALL 0x0012d2d6
LAB_0011ed15:
CALL 0x00167697
SUB RAX,R15
LEA RSI,[0x199c15]
LEA RCX,[0x19ae17]
XOR EDI,EDI
MOV EDX,0x1b9
MOV R8,RAX
XOR EAX,EAX
CALL 0x00155f59
LAB_0011ed3c:
MOV RDI,qword ptr [RSP]
MOV RSI,RBP
CALL 0x00168a65
LAB_0011ed48:
MOV R14,RAX
MOV RDI,RBP
CALL 0x0011d06a
MOVSS dword ptr [RSP + 0xc],XMM0
XOR R15D,R15D
LAB_0011ed5c:
CMP qword ptr [RBP + 0x20],R15
JLE 0x0011edb3
XOR R13D,R13D
LAB_0011ed65:
CMP qword ptr [RBP + 0x18],R13
JLE 0x0011edae
XOR EBX,EBX
LAB_0011ed6d:
CMP qword ptr [RBP + 0x10],RBX
JLE 0x0011eda9
LAB_0011ed73:
MOV RDI,RBP
MOV ESI,EBX
MOV EDX,R13D
MOV ECX,R15D
XOR R8D,R8D
CALL 0x0011d0a4
MOV RAX,qword ptr [RSP + 0x50]
MULSS XMM0,dword ptr [RAX + R13*0x4]
MOV RDI,R14
MOV ESI,EBX
MOV EDX,R13D
MOV ECX,R15D
XOR R8D,R8D
CALL 0x0011cdf4
INC RBX
JMP 0x0011ed6d
LAB_0011eda9:
INC R13
JMP 0x0011ed65
LAB_0011edae:
INC R15
JMP 0x0011ed5c
LAB_0011edb3:
MOV RDI,R14
CALL 0x0011d06a
MOVSS XMM1,dword ptr [RSP + 0xc]
DIVSS XMM1,XMM0
MOV RDI,R14
MOVAPS XMM0,XMM1
CALL 0x0011d11c
CMP byte ptr [RSP + 0xc0],0x0
MOV R13,qword ptr [RSP + 0x10]
JZ 0x0011ee00
MOV RBX,qword ptr [R14 + 0x118]
XOR R15D,R15D
LAB_0011ede9:
MOV RDI,R14
CALL 0x00167ada
CMP RAX,R15
JLE 0x0011ee00
AND dword ptr [RBX + R15*0x4],0x0
INC R15
JMP 0x0011ede9
LAB_0011ee00:
CMP dword ptr [R12],0x2
JNZ 0x0011f017
MOVSXD RDX,dword ptr [R12 + 0x300]
LAB_0011ee13:
MOV RDI,qword ptr [RSP]
XOR ESI,ESI
CALL 0x00168616
MOV R12,RAX
MOV RBX,qword ptr [RAX + 0x118]
MOV R15,qword ptr [R13 + 0x118]
LAB_0011ee2f:
MOV RDI,R13
CALL 0x00167afd
LAB_0011ee37:
MOV RDI,RBX
MOV RSI,R15
MOV RDX,RAX
CALL 0x0010a4c0
LAB_0011ee45:
MOV RDI,R13
CALL 0x00167afd
LAB_0011ee4d:
MOV RBP,RAX
PUSH 0x2
POP RDX
MOV RDI,qword ptr [RSP]
XOR ESI,ESI
CALL 0x00168616
MOV R13,RAX
CVTSI2SS XMM0,dword ptr [RSP + 0x1c]
LAB_0011ee67:
MOV RDI,RAX
MOVSS dword ptr [RSP + 0x10],XMM0
XOR ESI,ESI
XOR EDX,EDX
XOR ECX,ECX
XOR R8D,R8D
CALL 0x0011cdf4
CVTSI2SS XMM0,dword ptr [RSP + 0x18]
PUSH 0x1
POP RSI
MOV RDI,R13
MOVSS dword ptr [RSP + 0xc],XMM0
XOR EDX,EDX
XOR ECX,ECX
XOR R8D,R8D
CALL 0x0011cdf4
LAB_0011ee9c:
XOR EDI,EDI
CALL 0x00167b83
SHL RAX,0x8
PUSH 0x2
POP RCX
MOV EDX,0x100
MOV RDI,qword ptr [RSP]
MOV RSI,R12
MOV R8,RAX
MOV R9,RBP
CALL 0x0016c17f
MOV RBX,RAX
MOV RDI,RAX
CALL 0x00167afd
MOV R15,RAX
MOV RDI,R13
MOV RSI,RBX
MOV EDX,0x100
CALL 0x0011cca5
LAB_0011eedf:
XORPS XMM0,XMM0
MOV RDI,R13
XOR ESI,ESI
XOR EDX,EDX
XOR ECX,ECX
XOR R8D,R8D
CALL 0x0011cdf4
PUSH 0x1
POP RSI
XORPS XMM0,XMM0
MOV RDI,R13
XOR EDX,EDX
XOR ECX,ECX
XOR R8D,R8D
CALL 0x0011cdf4
XOR EDI,EDI
CALL 0x00167b83
ADD R15,RBP
SHL RAX,0x8
PUSH 0x2
POP RCX
MOV EDX,0x100
MOV RDI,qword ptr [RSP]
MOV RSI,R12
MOV R8,RAX
MOV R9,R15
CALL 0x0016c17f
MOV RBX,RAX
MOV RDI,RAX
CALL 0x00167afd
MOV RBP,RAX
MOV RDI,R13
MOV RSI,RBX
MOV EDX,0x100
CALL 0x0011cca5
LAB_0011ef4e:
MOV RDI,R13
MOVSS XMM0,dword ptr [RSP + 0x10]
XOR ESI,ESI
XOR EDX,EDX
XOR ECX,ECX
XOR R8D,R8D
CALL 0x0011cdf4
PUSH 0x1
POP RSI
MOV RDI,R13
MOVSS XMM0,dword ptr [RSP + 0xc]
XOR EDX,EDX
XOR ECX,ECX
XOR R8D,R8D
CALL 0x0011cdf4
XOR EDI,EDI
CALL 0x00167b83
ADD RBP,R15
SHL RAX,0x8
PUSH 0x2
POP RCX
MOV EDX,0x100
MOV RDI,qword ptr [RSP]
MOV RSI,R12
MOV R8,RAX
MOV R9,RBP
CALL 0x0016c17f
MOV R15,RAX
MOV RDI,RAX
CALL 0x00167afd
MOV RBX,RAX
MOV RDI,R13
MOV RSI,R15
MOV EDX,0x100
CALL 0x0011cca5
MOV RDI,R12
CALL 0x00167afd
ADD RBX,RBP
CMP RBX,RAX
JZ 0x0011f01a
MOV RAX,qword ptr [0x001d5f48]
MOV RDI,qword ptr [RAX]
CALL 0x0010a6f0
MOV RAX,qword ptr [0x001d5fa8]
MOV RDI,qword ptr [RAX]
LEA RSI,[0x19a21e]
LEA RDX,[0x199c15]
LEA R8,[0x19ae4a]
MOV ECX,0x1f5
XOR EAX,EAX
CALL 0x0010a8b0
CALL 0x00167550
LAB_0011f012:
CALL 0x0010a300
LAB_0011f017:
XOR R12D,R12D
LAB_0011f01a:
LEA RDI,[RSP + 0x38]
CALL 0x00132630
MOV RAX,R14
MOV RDX,R12
ADD RSP,0x88
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* StableDiffusionGGML::get_learned_condition(ggml_context*, std::__cxx11::string const&, int, int,
int, bool) */
int1 [16] __thiscall
StableDiffusionGGML::get_learned_condition
(StableDiffusionGGML *this,ggml_context *param_1,string *param_2,int param_3,int param_4,
int param_5,bool param_6)
{
FrozenCLIPEmbedderWithCustomWords *this_00;
int4 uVar1;
void *__dest;
void *__src;
ggml_tensor *pgVar2;
size_t __n;
ggml_tensor *pgVar3;
long lVar4;
long lVar5;
int iVar6;
long lVar7;
long lVar8;
long lVar9;
float fVar10;
float fVar11;
int1 auVar12 [16];
long local_a8;
vector<int,std::allocator<int>> local_98 [24];
long local_80;
long local_78;
long local_68;
string local_50 [32];
this_00 = (FrozenCLIPEmbedderWithCustomWords *)(this + 0x20);
FrozenCLIPEmbedderWithCustomWords::set_clip_skip(this_00,param_3);
std::__cxx11::string::string(local_50,param_2);
/* try { // try from 0011ec3f to 0011ec51 has its CatchHandler @ 0011f05b */
FrozenCLIPEmbedderWithCustomWords::tokenize(&local_80,this_00,local_50,1);
std::__cxx11::string::~string(local_50);
/* try { // try from 0011ec5c to 0011ec60 has its CatchHandler @ 0011f059 */
ggml_time_ms();
lVar7 = (long)*(int *)(this + 0x154);
if (*(int *)this == 2) {
iVar6 = *(int *)(this + 0x1c4);
/* try { // try from 0011ec87 to 0011ec96 has its CatchHandler @ 0011f040 */
local_a8 = ggml_new_tensor_1d(param_1,0,(long)*(int *)(this + 0x1d8));
lVar7 = lVar7 + iVar6;
}
else {
local_a8 = 0;
}
/* try { // try from 0011ecad to 0011eceb has its CatchHandler @ 0011f072 */
pgVar2 = (ggml_tensor *)ggml_new_tensor_2d(param_1,0,lVar7,(long)*(int *)(this + 0x150));
FrozenCLIPEmbedderWithCustomWords::alloc_compute_buffer
(this_00,param_1,(int)((ulong)(local_78 - local_80) >> 2));
uVar1 = *(int4 *)(this + 0x18);
std::vector<int,std::allocator<int>>::vector(local_98,(vector *)&local_80);
/* try { // try from 0011ecec to 0011ed02 has its CatchHandler @ 0011f04a */
FrozenCLIPEmbedderWithCustomWords::compute(this_00,uVar1,local_98,pgVar2,local_a8);
std::_Vector_base<int,std::allocator<int>>::~_Vector_base
((_Vector_base<int,std::allocator<int>> *)local_98);
/* try { // try from 0011ed0d to 0011ed14 has its CatchHandler @ 0011f072 */
GGMLModule::free_compute_buffer((GGMLModule *)this_00);
/* try { // try from 0011ed15 to 0011ed3b has its CatchHandler @ 0011f06e */
ggml_time_ms();
log_printf(0,
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/stable-diffusion.cpp"
,0x1b9);
/* try { // try from 0011ed3c to 0011ed47 has its CatchHandler @ 0011f048 */
auVar12._0_8_ = (ggml_tensor *)ggml_dup_tensor(param_1,pgVar2);
/* try { // try from 0011ed48 to 0011ed58 has its CatchHandler @ 0011f046 */
fVar10 = (float)ggml_tensor_mean(pgVar2);
for (lVar7 = 0; lVar7 < *(long *)(pgVar2 + 0x20); lVar7 = lVar7 + 1) {
for (lVar9 = 0; lVar9 < *(long *)(pgVar2 + 0x18); lVar9 = lVar9 + 1) {
for (lVar8 = 0; lVar8 < *(long *)(pgVar2 + 0x10); lVar8 = lVar8 + 1) {
/* try { // try from 0011ed73 to 0011eda3 has its CatchHandler @ 0011f078 */
fVar11 = (float)ggml_tensor_get_f32(pgVar2,(int)lVar8,(int)lVar9,(int)lVar7,0);
ggml_tensor_set_f32(auVar12._0_8_,fVar11 * *(float *)(local_68 + lVar9 * 4),(int)lVar8,
(int)lVar9,(int)lVar7,0);
}
}
}
/* try { // try from 0011edb3 to 0011edcf has its CatchHandler @ 0011f06c */
fVar11 = (float)ggml_tensor_mean(auVar12._0_8_);
ggml_tensor_scale(auVar12._0_8_,fVar10 / fVar11);
if (param_6) {
lVar7 = *(long *)(auVar12._0_8_ + 0x118);
lVar9 = 0;
while( true ) {
/* try { // try from 0011ede9 to 0011edf0 has its CatchHandler @ 0011f074 */
lVar8 = ggml_nelements(auVar12._0_8_);
if (lVar8 <= lVar9) break;
*(int4 *)(lVar7 + lVar9 * 4) = 0;
lVar9 = lVar9 + 1;
}
}
if (*(int *)this == 2) {
/* try { // try from 0011ee13 to 0011ee1d has its CatchHandler @ 0011f03e */
lVar7 = ggml_new_tensor_1d(param_1,0,(long)*(int *)(this + 0x300));
__dest = *(void **)(lVar7 + 0x118);
__src = *(void **)(local_a8 + 0x118);
/* try { // try from 0011ee2f to 0011ee36 has its CatchHandler @ 0011f044 */
__n = ggml_nbytes(local_a8);
memcpy(__dest,__src,__n);
/* try { // try from 0011ee45 to 0011ee4c has its CatchHandler @ 0011f044 */
lVar9 = ggml_nbytes(local_a8);
/* try { // try from 0011ee4d to 0011ee5d has its CatchHandler @ 0011f03c */
pgVar2 = (ggml_tensor *)ggml_new_tensor_1d(param_1,0,2);
/* try { // try from 0011ee67 to 0011ee9b has its CatchHandler @ 0011f042 */
ggml_tensor_set_f32(pgVar2,(float)param_5,0,0,0,0);
ggml_tensor_set_f32(pgVar2,(float)param_4,1,0,0,0);
/* try { // try from 0011ee9c to 0011eede has its CatchHandler @ 0011f06a */
lVar8 = ggml_type_size(0);
iVar6 = 2;
pgVar3 = (ggml_tensor *)ggml_view_2d(param_1,lVar7,0x100,2,lVar8 << 8,lVar9);
lVar8 = ggml_nbytes(pgVar3);
set_timestep_embedding(pgVar2,pgVar3,0x100,iVar6);
/* try { // try from 0011eedf to 0011ef4d has its CatchHandler @ 0011f070 */
ggml_tensor_set_f32(pgVar2,0.0,0,0,0,0);
ggml_tensor_set_f32(pgVar2,0.0,1,0,0,0);
lVar4 = ggml_type_size(0);
iVar6 = 2;
pgVar3 = (ggml_tensor *)ggml_view_2d(param_1,lVar7,0x100,2,lVar4 << 8,lVar8 + lVar9);
lVar4 = ggml_nbytes(pgVar3);
set_timestep_embedding(pgVar2,pgVar3,0x100,iVar6);
/* try { // try from 0011ef4e to 0011f011 has its CatchHandler @ 0011f076 */
ggml_tensor_set_f32(pgVar2,(float)param_5,0,0,0,0);
ggml_tensor_set_f32(pgVar2,(float)param_4,1,0,0,0);
lVar5 = ggml_type_size(0);
lVar4 = lVar4 + lVar8 + lVar9;
iVar6 = 2;
pgVar3 = (ggml_tensor *)ggml_view_2d(param_1,lVar7,0x100,2,lVar5 << 8,lVar4);
lVar9 = ggml_nbytes(pgVar3);
set_timestep_embedding(pgVar2,pgVar3,0x100,iVar6);
lVar8 = ggml_nbytes(lVar7);
if (lVar9 + lVar4 != lVar8) {
fflush(*(FILE **)PTR_stdout_001d5f48);
fprintf(*(FILE **)PTR_stderr_001d5fa8,"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/stable-diffusion.cpp"
,0x1f5,"offset == ggml_nbytes(vec)");
ggml_print_backtrace();
/* WARNING: Subroutine does not return */
abort();
}
}
else {
lVar7 = 0;
}
std::pair<std::vector<int,std::allocator<int>>,std::vector<float,std::allocator<float>>>::~pair
((pair<std::vector<int,std::allocator<int>>,std::vector<float,std::allocator<float>>> *)
&local_80);
auVar12._8_8_ = lVar7;
return auVar12;
}
| |
23,330 | ma_bitmap_find_new_place | eloqsql/storage/maria/ma_bitmap.c | my_bool _ma_bitmap_find_new_place(MARIA_HA *info, MARIA_ROW *row,
pgcache_page_no_t page, uint free_size,
MARIA_BITMAP_BLOCKS *blocks)
{
MARIA_SHARE *share= info->s;
my_bool res= 1;
uint position;
uint head_length, row_length, rest_length, extents_length;
ulonglong bitmap_page;
DBUG_ENTER("_ma_bitmap_find_new_place");
blocks->count= 0;
blocks->tail_page_skipped= blocks->page_skipped= 0;
row->extents_count= 0;
info->bitmap_blocks.elements= ELEMENTS_RESERVED_FOR_MAIN_PART;
mysql_mutex_lock(&share->bitmap.bitmap_lock);
/*
First allocate all blobs (so that we can find out the needed size for
the main block.
*/
if (row->blob_length && allocate_blobs(info, row))
goto abort;
/* Switch bitmap to current head page */
bitmap_page= page - page % share->bitmap.pages_covered;
if (share->bitmap.page != bitmap_page &&
_ma_change_bitmap_page(info, &share->bitmap, bitmap_page))
goto abort;
extents_length= row->extents_count * ROW_EXTENT_SIZE;
if ((head_length= (row->head_length + extents_length + 3)) <= free_size)
{
/* Main row part fits into one page */
position= ELEMENTS_RESERVED_FOR_MAIN_PART - 1;
use_head(info, page, head_length, position);
row->space_on_head_page= head_length;
goto end;
}
/* Allocate enough space */
head_length+= ELEMENTS_RESERVED_FOR_MAIN_PART * ROW_EXTENT_SIZE;
/*
The first segment size is stored in 'row_length'
We have to add ELEMENTS_RESERVED_FOR_MAIN_PART here as the extent
information may be up to this size when the header splits.
*/
row_length= find_where_to_split_row(share, row, row->extents_count +
ELEMENTS_RESERVED_FOR_MAIN_PART-1,
free_size);
position= 0;
rest_length= head_length - row_length;
if (rest_length <= MAX_TAIL_SIZE(share->block_size))
position= ELEMENTS_RESERVED_FOR_MAIN_PART -2; /* Only head and tail */
use_head(info, page, row_length, position);
row->space_on_head_page= row_length;
if (write_rest_of_head(info, position, rest_length))
goto abort;
end:
blocks->block= dynamic_element(&info->bitmap_blocks, position,
MARIA_BITMAP_BLOCK*);
blocks->block->sub_blocks= ELEMENTS_RESERVED_FOR_MAIN_PART - position;
/* First block's page_count is for all blocks */
blocks->count= info->bitmap_blocks.elements - position;
res= 0;
abort:
mysql_mutex_unlock(&share->bitmap.bitmap_lock);
DBUG_RETURN(res);
} | O3 | c | ma_bitmap_find_new_place:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %ecx, -0x2c(%rbp)
movq %rdx, %rbx
movq %rsi, %r13
movq %rdi, %r12
movq (%rdi), %r14
xorl %eax, %eax
movl %eax, 0x8(%r8)
movq %r8, -0x38(%rbp)
movw $0x0, 0xc(%r8)
movl %eax, 0xac(%rsi)
movl $0x4, 0x2c8(%rdi)
leaq 0xa98(%r14), %rdi
cmpq $0x0, 0xad8(%r14)
movq %rdi, -0x40(%rbp)
jne 0x549ad
callq 0x2a200
cmpq $0x0, 0x88(%r13)
je 0x5476b
movq %r12, %rdi
movq %r13, %rsi
callq 0x543b2
movb $0x1, %r15b
testb %al, %al
jne 0x54986
movq %rbx, %rax
xorl %edx, %edx
divq 0xb48(%r14)
movq %rdx, %rax
movq %rbx, %rdx
subq %rax, %rdx
cmpq %rdx, 0xa20(%r14)
je 0x547a3
leaq 0xa10(%r14), %rsi
movq %r12, %rdi
callq 0x549d5
movb $0x1, %r15b
testb %al, %al
jne 0x54986
movl 0xa0(%r13), %r15d
movl 0xac(%r13), %edx
leal (,%rdx,8), %esi
subl %edx, %esi
leal (%r15,%rsi), %eax
addl $0x3, %eax
movl -0x2c(%rbp), %ecx
cmpl %ecx, %eax
jbe 0x54827
addl %esi, %r15d
addl $0x3, %edx
movq %r14, %rdi
movq %r13, %rsi
callq 0x54569
subl %eax, %r15d
addl $0x1f, %r15d
movl 0x7bc(%r14), %ecx
leal (%rcx,%rcx,2), %ecx
shrl $0x2, %ecx
movq (%r12), %rdx
movq 0x2c0(%r12), %rsi
cmpl %ecx, %r15d
jbe 0x548af
movl $0x0, -0x2c(%rbp)
movl $0x15, %edi
movl $0x14, %ecx
movl $0xc, %r9d
movl $0x8, %r10d
movq %rsi, %r8
jmp 0x548d0
movq (%r12), %rdx
movq 0x2c0(%r12), %r8
movq %rbx, 0x48(%r8)
movl $0x8001, 0x50(%r8) # imm = 0x8001
movl %eax, 0x54(%r8)
movb $0x4, 0x5c(%r8)
movl 0xa20(%rdx), %ecx
notl %ecx
addl %ecx, %ebx
leal (%rbx,%rbx,2), %ecx
movq 0xa18(%rdx), %rsi
movl %ecx, %edi
shrl $0x3, %edi
movzwl (%rsi,%rdi), %r9d
andb $0x7, %cl
movl %r9d, %r10d
shrl %cl, %r10d
andb $0x7, %r10b
movb %r10b, 0x5d(%r8)
movl $0x7, %r8d
shll %cl, %r8d
notl %r8d
andl %r9d, %r8d
movl $0x4, %r9d
shll %cl, %r9d
orl %r8d, %r9d
movw %r9w, (%rsi,%rdi)
movb $0x1, 0xa30(%rdx)
movl %eax, 0xb8(%r13)
movl $0x3, %ebx
jmp 0x54953
leaq 0x30(%rsi), %r8
movl $0x2, -0x2c(%rbp)
movl $0x45, %edi
movl $0x44, %ecx
movl $0x3c, %r9d
movl $0x38, %r10d
movq %rbx, (%r8)
movl $0x8001, (%rsi,%r10) # imm = 0x8001
movl %eax, (%rsi,%r9)
movb $0x4, (%rsi,%rcx)
movl 0xa20(%rdx), %ecx
notl %ecx
addl %ecx, %ebx
leal (%rbx,%rbx,2), %ecx
movq 0xa18(%rdx), %r8
movl %ecx, %r9d
shrl $0x3, %r9d
movzwl (%r8,%r9), %r10d
andb $0x7, %cl
movl %r10d, %r11d
shrl %cl, %r11d
andb $0x7, %r11b
movb %r11b, (%rsi,%rdi)
movl $0x7, %esi
shll %cl, %esi
notl %esi
andl %r10d, %esi
movl $0x4, %edi
shll %cl, %edi
orl %esi, %edi
movw %di, (%r8,%r9)
movb $0x1, 0xa30(%rdx)
movl %eax, 0xb8(%r13)
movl %r15d, %edx
movq %r12, %rdi
movl -0x2c(%rbp), %ebx
movl %ebx, %esi
callq 0x54605
movb $0x1, %r15b
testb %al, %al
jne 0x54986
movq 0x2c0(%r12), %rax
movl %ebx, %ecx
leaq (%rcx,%rcx,2), %rcx
leaq (%rax,%rcx,8), %rax
movq -0x38(%rbp), %rdx
movq %rax, (%rdx)
movl $0x4, %ecx
subl %ebx, %ecx
movl %ecx, 0x10(%rax)
movl 0x2c8(%r12), %eax
subl %ebx, %eax
movl %eax, 0x8(%rdx)
xorl %r15d, %r15d
movq 0xad8(%r14), %rdi
testq %rdi, %rdi
jne 0x549c3
movq -0x40(%rbp), %rdi
callq 0x2a1d0
movl %r15d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x90948(%rip), %rsi # 0xe52fc
movl $0x8b1, %edx # imm = 0x8B1
callq 0x308cf
jmp 0x5474b
leaq 0x33f08e(%rip), %rax # 0x393a58
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x54992
| _ma_bitmap_find_new_place:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov [rbp+var_2C], ecx
mov rbx, rdx
mov r13, rsi
mov r12, rdi
mov r14, [rdi]
xor eax, eax
mov [r8+8], eax
mov [rbp+var_38], r8
mov word ptr [r8+0Ch], 0
mov [rsi+0ACh], eax
mov dword ptr [rdi+2C8h], 4
lea rdi, [r14+0A98h]
cmp qword ptr [r14+0AD8h], 0
mov [rbp+var_40], rdi
jnz loc_549AD
call _pthread_mutex_lock
loc_5474B:
cmp qword ptr [r13+88h], 0
jz short loc_5476B
mov rdi, r12
mov rsi, r13
call allocate_blobs
mov r15b, 1
test al, al
jnz loc_54986
loc_5476B:
mov rax, rbx
xor edx, edx
div qword ptr [r14+0B48h]
mov rax, rdx
mov rdx, rbx
sub rdx, rax
cmp [r14+0A20h], rdx
jz short loc_547A3
lea rsi, [r14+0A10h]
mov rdi, r12
call _ma_change_bitmap_page
mov r15b, 1
test al, al
jnz loc_54986
loc_547A3:
mov r15d, [r13+0A0h]
mov edx, [r13+0ACh]
lea esi, ds:0[rdx*8]
sub esi, edx
lea eax, [r15+rsi]
add eax, 3
mov ecx, [rbp+var_2C]
cmp eax, ecx
jbe short loc_54827
add r15d, esi
add edx, 3
mov rdi, r14
mov rsi, r13
call find_where_to_split_row
sub r15d, eax
add r15d, 1Fh
mov ecx, [r14+7BCh]
lea ecx, [rcx+rcx*2]
shr ecx, 2
mov rdx, [r12]
mov rsi, [r12+2C0h]
cmp r15d, ecx
jbe loc_548AF
mov [rbp+var_2C], 0
mov edi, 15h
mov ecx, 14h
mov r9d, 0Ch
mov r10d, 8
mov r8, rsi
jmp loc_548D0
loc_54827:
mov rdx, [r12]
mov r8, [r12+2C0h]
mov [r8+48h], rbx
mov dword ptr [r8+50h], 8001h
mov [r8+54h], eax
mov byte ptr [r8+5Ch], 4
mov ecx, [rdx+0A20h]
not ecx
add ebx, ecx
lea ecx, [rbx+rbx*2]
mov rsi, [rdx+0A18h]
mov edi, ecx
shr edi, 3
movzx r9d, word ptr [rsi+rdi]
and cl, 7
mov r10d, r9d
shr r10d, cl
and r10b, 7
mov [r8+5Dh], r10b
mov r8d, 7
shl r8d, cl
not r8d
and r8d, r9d
mov r9d, 4
shl r9d, cl
or r9d, r8d
mov [rsi+rdi], r9w
mov byte ptr [rdx+0A30h], 1
mov [r13+0B8h], eax
mov ebx, 3
jmp loc_54953
loc_548AF:
lea r8, [rsi+30h]
mov [rbp+var_2C], 2
mov edi, 45h ; 'E'
mov ecx, 44h ; 'D'
mov r9d, 3Ch ; '<'
mov r10d, 38h ; '8'
loc_548D0:
mov [r8], rbx
mov dword ptr [rsi+r10], 8001h
mov [rsi+r9], eax
mov byte ptr [rsi+rcx], 4
mov ecx, [rdx+0A20h]
not ecx
add ebx, ecx
lea ecx, [rbx+rbx*2]
mov r8, [rdx+0A18h]
mov r9d, ecx
shr r9d, 3
movzx r10d, word ptr [r8+r9]
and cl, 7
mov r11d, r10d
shr r11d, cl
and r11b, 7
mov [rsi+rdi], r11b
mov esi, 7
shl esi, cl
not esi
and esi, r10d
mov edi, 4
shl edi, cl
or edi, esi
mov [r8+r9], di
mov byte ptr [rdx+0A30h], 1
mov [r13+0B8h], eax
mov edx, r15d
mov rdi, r12
mov ebx, [rbp+var_2C]
mov esi, ebx
call write_rest_of_head
mov r15b, 1
test al, al
jnz short loc_54986
loc_54953:
mov rax, [r12+2C0h]
mov ecx, ebx
lea rcx, [rcx+rcx*2]
lea rax, [rax+rcx*8]
mov rdx, [rbp+var_38]
mov [rdx], rax
mov ecx, 4
sub ecx, ebx
mov [rax+10h], ecx
mov eax, [r12+2C8h]
sub eax, ebx
mov [rdx+8], eax
xor r15d, r15d
loc_54986:
mov rdi, [r14+0AD8h]
test rdi, rdi
jnz short loc_549C3
loc_54992:
mov rdi, [rbp+var_40]
call _pthread_mutex_unlock
mov eax, r15d
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_549AD:
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 8B1h
call psi_mutex_lock
jmp loc_5474B
loc_549C3:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp short loc_54992
| long long ma_bitmap_find_new_place(long long a1, long long a2, unsigned long long a3, unsigned int a4, long long a5)
{
unsigned int v5; // r15d
long long v9; // r14
long long v10; // rdi
long long v11; // rcx
unsigned long long v12; // rdx
int v13; // r15d
int v14; // edx
int v15; // esi
unsigned int v16; // eax
int where_to_split_row; // eax
long long v18; // rdx
long long v19; // rsi
long long v20; // rdi
long long v21; // rcx
long long v22; // r9
long long v23; // r10
unsigned long long *v24; // r8
long long v25; // rdx
long long v26; // r8
long long v27; // rsi
long long v28; // rdi
unsigned __int16 v29; // r9
char v30; // cl
unsigned int v31; // ebx
long long v32; // r8
long long v33; // r9
unsigned __int16 v34; // r10
char v35; // cl
char v36; // al
long long v37; // rax
long long v38; // rdi
int v42; // [rsp+14h] [rbp-2Ch]
v9 = *(_QWORD *)a1;
*(_DWORD *)(a5 + 8) = 0;
*(_WORD *)(a5 + 12) = 0;
*(_DWORD *)(a2 + 172) = 0;
*(_DWORD *)(a1 + 712) = 4;
v10 = v9 + 2712;
if ( *(_QWORD *)(v9 + 2776) )
psi_mutex_lock(v10, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 0x8B1u);
else
pthread_mutex_lock(v10);
if ( *(_QWORD *)(a2 + 136) )
{
LOBYTE(v5) = 1;
if ( allocate_blobs((long long *)a1, a2) )
goto LABEL_14;
}
v12 = a3 - a3 % *(_QWORD *)(v9 + 2888);
if ( *(_QWORD *)(v9 + 2592) != v12 )
{
LOBYTE(v5) = 1;
if ( (unsigned __int8)ma_change_bitmap_page(a1, v9 + 2576, v12, v11) )
goto LABEL_14;
}
v13 = *(_DWORD *)(a2 + 160);
v14 = *(_DWORD *)(a2 + 172);
v15 = 7 * v14;
v16 = v13 + 7 * v14 + 3;
if ( v16 <= a4 )
{
v25 = *(_QWORD *)a1;
v26 = *(_QWORD *)(a1 + 704);
*(_QWORD *)(v26 + 72) = a3;
*(_DWORD *)(v26 + 80) = 32769;
*(_DWORD *)(v26 + 84) = v16;
*(_BYTE *)(v26 + 92) = 4;
v27 = *(_QWORD *)(v25 + 2584);
v28 = (unsigned int)(3 * (~*(_DWORD *)(v25 + 2592) + a3)) >> 3;
v29 = *(_WORD *)(v27 + v28);
v30 = (3 * (~*(_BYTE *)(v25 + 2592) + a3)) & 7;
*(_BYTE *)(v26 + 93) = (v29 >> v30) & 7;
*(_WORD *)(v27 + v28) = v29 & ~(7 << v30) | (4 << v30);
*(_BYTE *)(v25 + 2608) = 1;
*(_DWORD *)(a2 + 184) = v16;
v31 = 3;
}
else
{
where_to_split_row = find_where_to_split_row((unsigned int *)v9, a2, v14 + 3, a4);
v5 = v15 + v13 - where_to_split_row + 31;
v18 = *(_QWORD *)a1;
v19 = *(_QWORD *)(a1 + 704);
if ( v5 <= (unsigned int)(3 * *(_DWORD *)(v9 + 1980)) >> 2 )
{
v24 = (unsigned long long *)(v19 + 48);
v42 = 2;
v20 = 69LL;
v21 = 68LL;
v22 = 60LL;
v23 = 56LL;
}
else
{
v42 = 0;
v20 = 21LL;
v21 = 20LL;
v22 = 12LL;
v23 = 8LL;
v24 = *(unsigned long long **)(a1 + 704);
}
*v24 = a3;
*(_DWORD *)(v19 + v23) = 32769;
*(_DWORD *)(v19 + v22) = where_to_split_row;
*(_BYTE *)(v19 + v21) = 4;
v32 = *(_QWORD *)(v18 + 2584);
v33 = (unsigned int)(3 * (~*(_DWORD *)(v18 + 2592) + a3)) >> 3;
v34 = *(_WORD *)(v32 + v33);
v35 = (3 * (~*(_BYTE *)(v18 + 2592) + a3)) & 7;
*(_BYTE *)(v19 + v20) = (v34 >> v35) & 7;
*(_WORD *)(v32 + v33) = v34 & ~(7 << v35) | (4 << v35);
*(_BYTE *)(v18 + 2608) = 1;
*(_DWORD *)(a2 + 184) = where_to_split_row;
v31 = v42;
v36 = write_rest_of_head((_QWORD *)a1, v42, v5);
LOBYTE(v5) = 1;
if ( v36 )
goto LABEL_14;
}
v37 = *(_QWORD *)(a1 + 704) + 24LL * v31;
*(_QWORD *)a5 = v37;
*(_DWORD *)(v37 + 16) = 4 - v31;
*(_DWORD *)(a5 + 8) = *(_DWORD *)(a1 + 712) - v31;
v5 = 0;
LABEL_14:
v38 = *(_QWORD *)(v9 + 2776);
if ( v38 )
((void ( *)(long long))PSI_server[44])(v38);
pthread_mutex_unlock(v9 + 2712);
return v5;
}
| _ma_bitmap_find_new_place:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV dword ptr [RBP + -0x2c],ECX
MOV RBX,RDX
MOV R13,RSI
MOV R12,RDI
MOV R14,qword ptr [RDI]
XOR EAX,EAX
MOV dword ptr [R8 + 0x8],EAX
MOV qword ptr [RBP + -0x38],R8
MOV word ptr [R8 + 0xc],0x0
MOV dword ptr [RSI + 0xac],EAX
MOV dword ptr [RDI + 0x2c8],0x4
LEA RDI,[R14 + 0xa98]
CMP qword ptr [R14 + 0xad8],0x0
MOV qword ptr [RBP + -0x40],RDI
JNZ 0x001549ad
CALL 0x0012a200
LAB_0015474b:
CMP qword ptr [R13 + 0x88],0x0
JZ 0x0015476b
MOV RDI,R12
MOV RSI,R13
CALL 0x001543b2
MOV R15B,0x1
TEST AL,AL
JNZ 0x00154986
LAB_0015476b:
MOV RAX,RBX
XOR EDX,EDX
DIV qword ptr [R14 + 0xb48]
MOV RAX,RDX
MOV RDX,RBX
SUB RDX,RAX
CMP qword ptr [R14 + 0xa20],RDX
JZ 0x001547a3
LEA RSI,[R14 + 0xa10]
MOV RDI,R12
CALL 0x001549d5
MOV R15B,0x1
TEST AL,AL
JNZ 0x00154986
LAB_001547a3:
MOV R15D,dword ptr [R13 + 0xa0]
MOV EDX,dword ptr [R13 + 0xac]
LEA ESI,[RDX*0x8]
SUB ESI,EDX
LEA EAX,[R15 + RSI*0x1]
ADD EAX,0x3
MOV ECX,dword ptr [RBP + -0x2c]
CMP EAX,ECX
JBE 0x00154827
ADD R15D,ESI
ADD EDX,0x3
MOV RDI,R14
MOV RSI,R13
CALL 0x00154569
SUB R15D,EAX
ADD R15D,0x1f
MOV ECX,dword ptr [R14 + 0x7bc]
LEA ECX,[RCX + RCX*0x2]
SHR ECX,0x2
MOV RDX,qword ptr [R12]
MOV RSI,qword ptr [R12 + 0x2c0]
CMP R15D,ECX
JBE 0x001548af
MOV dword ptr [RBP + -0x2c],0x0
MOV EDI,0x15
MOV ECX,0x14
MOV R9D,0xc
MOV R10D,0x8
MOV R8,RSI
JMP 0x001548d0
LAB_00154827:
MOV RDX,qword ptr [R12]
MOV R8,qword ptr [R12 + 0x2c0]
MOV qword ptr [R8 + 0x48],RBX
MOV dword ptr [R8 + 0x50],0x8001
MOV dword ptr [R8 + 0x54],EAX
MOV byte ptr [R8 + 0x5c],0x4
MOV ECX,dword ptr [RDX + 0xa20]
NOT ECX
ADD EBX,ECX
LEA ECX,[RBX + RBX*0x2]
MOV RSI,qword ptr [RDX + 0xa18]
MOV EDI,ECX
SHR EDI,0x3
MOVZX R9D,word ptr [RSI + RDI*0x1]
AND CL,0x7
MOV R10D,R9D
SHR R10D,CL
AND R10B,0x7
MOV byte ptr [R8 + 0x5d],R10B
MOV R8D,0x7
SHL R8D,CL
NOT R8D
AND R8D,R9D
MOV R9D,0x4
SHL R9D,CL
OR R9D,R8D
MOV word ptr [RSI + RDI*0x1],R9W
MOV byte ptr [RDX + 0xa30],0x1
MOV dword ptr [R13 + 0xb8],EAX
MOV EBX,0x3
JMP 0x00154953
LAB_001548af:
LEA R8,[RSI + 0x30]
MOV dword ptr [RBP + -0x2c],0x2
MOV EDI,0x45
MOV ECX,0x44
MOV R9D,0x3c
MOV R10D,0x38
LAB_001548d0:
MOV qword ptr [R8],RBX
MOV dword ptr [RSI + R10*0x1],0x8001
MOV dword ptr [RSI + R9*0x1],EAX
MOV byte ptr [RSI + RCX*0x1],0x4
MOV ECX,dword ptr [RDX + 0xa20]
NOT ECX
ADD EBX,ECX
LEA ECX,[RBX + RBX*0x2]
MOV R8,qword ptr [RDX + 0xa18]
MOV R9D,ECX
SHR R9D,0x3
MOVZX R10D,word ptr [R8 + R9*0x1]
AND CL,0x7
MOV R11D,R10D
SHR R11D,CL
AND R11B,0x7
MOV byte ptr [RSI + RDI*0x1],R11B
MOV ESI,0x7
SHL ESI,CL
NOT ESI
AND ESI,R10D
MOV EDI,0x4
SHL EDI,CL
OR EDI,ESI
MOV word ptr [R8 + R9*0x1],DI
MOV byte ptr [RDX + 0xa30],0x1
MOV dword ptr [R13 + 0xb8],EAX
MOV EDX,R15D
MOV RDI,R12
MOV EBX,dword ptr [RBP + -0x2c]
MOV ESI,EBX
CALL 0x00154605
MOV R15B,0x1
TEST AL,AL
JNZ 0x00154986
LAB_00154953:
MOV RAX,qword ptr [R12 + 0x2c0]
MOV ECX,EBX
LEA RCX,[RCX + RCX*0x2]
LEA RAX,[RAX + RCX*0x8]
MOV RDX,qword ptr [RBP + -0x38]
MOV qword ptr [RDX],RAX
MOV ECX,0x4
SUB ECX,EBX
MOV dword ptr [RAX + 0x10],ECX
MOV EAX,dword ptr [R12 + 0x2c8]
SUB EAX,EBX
MOV dword ptr [RDX + 0x8],EAX
XOR R15D,R15D
LAB_00154986:
MOV RDI,qword ptr [R14 + 0xad8]
TEST RDI,RDI
JNZ 0x001549c3
LAB_00154992:
MOV RDI,qword ptr [RBP + -0x40]
CALL 0x0012a1d0
MOV EAX,R15D
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001549ad:
LEA RSI,[0x1e52fc]
MOV EDX,0x8b1
CALL 0x001308cf
JMP 0x0015474b
LAB_001549c3:
LEA RAX,[0x493a58]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x00154992
|
ulong _ma_bitmap_find_new_place(long *param_1,long param_2,ulong param_3,uint param_4,long *param_5)
{
pthread_mutex_t *__mutex;
ushort uVar1;
int iVar2;
long lVar3;
long lVar4;
ulong *puVar5;
uint uVar6;
int iVar7;
char cVar8;
uint uVar9;
int iVar10;
byte bVar11;
long lVar12;
long lVar13;
ulong uVar14;
ulong *puVar15;
long lVar16;
long lVar17;
ulong unaff_R15;
uint local_34;
lVar3 = *param_1;
*(int4 *)(param_5 + 1) = 0;
*(int2 *)((long)param_5 + 0xc) = 0;
*(int4 *)(param_2 + 0xac) = 0;
*(int4 *)(param_1 + 0x59) = 4;
__mutex = (pthread_mutex_t *)(lVar3 + 0xa98);
if (*(long *)(lVar3 + 0xad8) == 0) {
pthread_mutex_lock(__mutex);
}
else {
psi_mutex_lock(__mutex,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c",
0x8b1);
}
if (*(long *)(param_2 + 0x88) != 0) {
cVar8 = allocate_blobs(param_1,param_2);
unaff_R15 = CONCAT71((int7)(unaff_R15 >> 8),1);
if (cVar8 != '\0') goto LAB_00154986;
}
if (*(long *)(lVar3 + 0xa20) != param_3 - param_3 % *(ulong *)(lVar3 + 0xb48)) {
cVar8 = _ma_change_bitmap_page(param_1,lVar3 + 0xa10);
unaff_R15 = CONCAT71((int7)(unaff_R15 >> 8),1);
if (cVar8 != '\0') goto LAB_00154986;
}
iVar2 = *(int *)(param_2 + 0xa0);
iVar7 = *(int *)(param_2 + 0xac) * 7;
uVar9 = iVar2 + iVar7 + 3;
if (param_4 < uVar9) {
iVar10 = find_where_to_split_row(lVar3,param_2,*(int *)(param_2 + 0xac) + 3);
uVar9 = ((iVar2 + iVar7) - iVar10) + 0x1f;
lVar4 = *param_1;
puVar5 = (ulong *)param_1[0x58];
if ((uint)(*(int *)(lVar3 + 0x7bc) * 3) >> 2 < uVar9) {
local_34 = 0;
lVar13 = 0x15;
lVar12 = 0x14;
lVar16 = 0xc;
lVar17 = 8;
puVar15 = puVar5;
}
else {
puVar15 = puVar5 + 6;
local_34 = 2;
lVar13 = 0x45;
lVar12 = 0x44;
lVar16 = 0x3c;
lVar17 = 0x38;
}
*puVar15 = param_3;
*(int4 *)((long)puVar5 + lVar17) = 0x8001;
*(int *)((long)puVar5 + lVar16) = iVar10;
*(int1 *)((long)puVar5 + lVar12) = 4;
uVar6 = ((int)param_3 + ~*(uint *)(lVar4 + 0xa20)) * 3;
lVar12 = *(long *)(lVar4 + 0xa18);
uVar14 = (ulong)(uVar6 >> 3);
uVar1 = *(ushort *)(lVar12 + uVar14);
bVar11 = (byte)uVar6 & 7;
*(byte *)((long)puVar5 + lVar13) = (byte)(uVar1 >> bVar11) & 7;
*(ushort *)(lVar12 + uVar14) = (ushort)(4 << bVar11) | ~(ushort)(7 << bVar11) & uVar1;
*(int1 *)(lVar4 + 0xa30) = 1;
*(int *)(param_2 + 0xb8) = iVar10;
cVar8 = write_rest_of_head(param_1,local_34,uVar9);
unaff_R15 = CONCAT71((uint7)(uint3)(uVar9 >> 8),1);
if (cVar8 != '\0') goto LAB_00154986;
}
else {
lVar4 = *param_1;
lVar12 = param_1[0x58];
*(ulong *)(lVar12 + 0x48) = param_3;
*(int4 *)(lVar12 + 0x50) = 0x8001;
*(uint *)(lVar12 + 0x54) = uVar9;
*(int1 *)(lVar12 + 0x5c) = 4;
uVar6 = ((int)param_3 + ~*(uint *)(lVar4 + 0xa20)) * 3;
lVar13 = *(long *)(lVar4 + 0xa18);
uVar14 = (ulong)(uVar6 >> 3);
uVar1 = *(ushort *)(lVar13 + uVar14);
bVar11 = (byte)uVar6 & 7;
*(byte *)(lVar12 + 0x5d) = (byte)(uVar1 >> bVar11) & 7;
*(ushort *)(lVar13 + uVar14) = (ushort)(4 << bVar11) | ~(ushort)(7 << bVar11) & uVar1;
*(int1 *)(lVar4 + 0xa30) = 1;
*(uint *)(param_2 + 0xb8) = uVar9;
local_34 = 3;
}
lVar4 = param_1[0x58] + (ulong)local_34 * 0x18;
*param_5 = lVar4;
*(uint *)(lVar4 + 0x10) = 4 - local_34;
*(uint *)(param_5 + 1) = (int)param_1[0x59] - local_34;
unaff_R15 = 0;
LAB_00154986:
if (*(long *)(lVar3 + 0xad8) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
return unaff_R15 & 0xffffffff;
}
| |
23,331 | my_once_free | eloqsql/mysys/my_once.c | void my_once_free(void)
{
reg1 USED_MEM *next,*old;
DBUG_ENTER("my_once_free");
for (next=my_once_root_block ; next ; )
{
old=next; next= next->next ;
free((uchar*) old);
}
my_once_root_block=0;
DBUG_VOID_RETURN;
} | O0 | c | my_once_free:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
leaq 0x3a1b01(%rip), %rax # 0x442580
movq (%rax), %rax
movq %rax, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
je 0xa0aab
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x8(%rbp)
movq -0x10(%rbp), %rdi
callq 0x2a4a0
jmp 0xa0a86
leaq 0x3a1ace(%rip), %rax # 0x442580
movq $0x0, (%rax)
jmp 0xa0abb
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax,%rax)
| my_once_free:
push rbp
mov rbp, rsp
sub rsp, 10h
lea rax, my_once_root_block
mov rax, [rax]
mov [rbp+var_8], rax
loc_A0A86:
cmp [rbp+var_8], 0
jz short loc_A0AAB
mov rax, [rbp+var_8]
mov [rbp+var_10], rax
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_8], rax
mov rdi, [rbp+var_10]
call _free
jmp short loc_A0A86
loc_A0AAB:
lea rax, my_once_root_block
mov qword ptr [rax], 0
jmp short $+2
loc_A0ABB:
add rsp, 10h
pop rbp
retn
| _QWORD *my_once_free()
{
_QWORD *result; // rax
_QWORD *v1; // [rsp+0h] [rbp-10h]
_QWORD *v2; // [rsp+8h] [rbp-8h]
v2 = (_QWORD *)my_once_root_block;
while ( v2 )
{
v1 = v2;
v2 = (_QWORD *)*v2;
free(v1);
}
result = &my_once_root_block;
my_once_root_block = 0LL;
return result;
}
| my_once_free:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
LEA RAX,[0x542580]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x8],RAX
LAB_001a0a86:
CMP qword ptr [RBP + -0x8],0x0
JZ 0x001a0aab
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x8],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0012a4a0
JMP 0x001a0a86
LAB_001a0aab:
LEA RAX,[0x542580]
MOV qword ptr [RAX],0x0
JMP 0x001a0abb
LAB_001a0abb:
ADD RSP,0x10
POP RBP
RET
|
void my_once_free(void)
{
int8 *puVar1;
int8 local_10;
local_10 = my_once_root_block;
while (local_10 != (int8 *)0x0) {
puVar1 = (int8 *)*local_10;
free(local_10);
local_10 = puVar1;
}
my_once_root_block = (int8 *)0x0;
return;
}
| |
23,332 | mjp_getResourceProvider | aimrt_mujoco_sim/_deps/mujoco-src/src/engine/engine_plugin.cc | const mjpResourceProvider* mjp_getResourceProvider(const char* resource_name) {
if (!resource_name || !resource_name[0]) {
return nullptr;
}
const char* ch = std::strchr(resource_name, ':');
if (ch == nullptr) {
return nullptr;
}
int n = ch - resource_name;
std::string file_prefix = std::string(resource_name, n);
// return NULL if file_prefix doesn't have a valid URI scheme syntax
if (!IsValidURISchemeFormat(file_prefix.c_str())) {
return nullptr;
}
return GlobalTable<mjpResourceProvider>::GetSingleton().GetByKey(file_prefix.c_str(), nullptr);
} | O3 | cpp | mjp_getResourceProvider:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
testq %rdi, %rdi
je 0x7c5d6
movq %rdi, %rbx
cmpb $0x0, (%rdi)
je 0x7c5d6
movq %rbx, %rdi
movl $0x3a, %esi
callq 0x2deb0
testq %rax, %rax
je 0x7c5d6
subl %ebx, %eax
movslq %eax, %rdx
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
addq %rbx, %rdx
movq %rsp, %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2dec0
movq (%r14), %r14
movq %r14, %rdi
callq 0x7c431
testb %al, %al
je 0x7c5e5
callq 0x7c4b6
movq %rax, %rbx
movq (%rsp), %r14
movq %r14, %rdi
callq 0x2de60
movl 0x400(%rbx), %r8d
movq %rbx, %rdi
movq %rax, %rsi
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x7d25e
movq %rax, %rbx
movq (%rsp), %r14
jmp 0x7c5e7
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
xorl %ebx, %ebx
cmpq %r15, %r14
je 0x7c5d8
movq 0x10(%rsp), %rsi
incq %rsi
movq %r14, %rdi
callq 0x2ded0
jmp 0x7c5d8
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x7c617
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2ded0
movq %rbx, %rdi
callq 0x2dee0
| mjp_getResourceProvider:
push r15
push r14
push rbx
sub rsp, 20h
test rdi, rdi
jz short loc_7C5D6
mov rbx, rdi
cmp byte ptr [rdi], 0
jz short loc_7C5D6
mov rdi, rbx
mov esi, 3Ah ; ':'
call _strchr
test rax, rax
jz short loc_7C5D6
sub eax, ebx
movsxd rdx, eax
lea r15, [rsp+38h+var_28]
mov [r15-10h], r15
add rdx, rbx
mov r14, rsp
mov rdi, r14
mov rsi, rbx; char *
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 r14, [r14]
mov rdi, r14; this
call _ZN12_GLOBAL__N_122IsValidURISchemeFormatEPKc; `anonymous namespace'::IsValidURISchemeFormat(char const*)
test al, al
jz short loc_7C5E5
call _ZN6mujoco11GlobalTableI19mjpResourceProviderE12GetSingletonEv; mujoco::GlobalTable<mjpResourceProvider>::GetSingleton(void)
mov rbx, rax
mov r14, [rsp+38h+var_38]
mov rdi, r14
call _strlen
mov r8d, [rbx+400h]
mov rdi, rbx
mov rsi, rax
mov rdx, r14
xor ecx, ecx
call _ZN6mujoco11GlobalTableI19mjpResourceProviderE14GetByKeyUnsafeESt17basic_string_viewIcSt11char_traitsIcEEPii; mujoco::GlobalTable<mjpResourceProvider>::GetByKeyUnsafe(std::string_view,int *,int)
mov rbx, rax
mov r14, [rsp+38h+var_38]
jmp short loc_7C5E7
loc_7C5D6:
xor ebx, ebx
loc_7C5D8:
mov rax, rbx
add rsp, 20h
pop rbx
pop r14
pop r15
retn
loc_7C5E5:
xor ebx, ebx
loc_7C5E7:
cmp r14, r15
jz short loc_7C5D8
mov rsi, [rsp+38h+var_28]
inc rsi; unsigned __int64
mov rdi, r14; void *
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_7C5D8
mov rbx, rax
mov rdi, [rsp+0]; void *
cmp rdi, r15
jz short loc_7C617
mov rsi, [rsp+arg_8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_7C617:
mov rdi, rbx
call __Unwind_Resume
| long long mjp_getResourceProvider(char *a1, __m128 a2)
{
long long v2; // rax
_QWORD *v3; // r14
unsigned int *Singleton; // rbx
void *v5; // r14
long long v6; // rax
long long v7; // rbx
void *v9; // [rsp+0h] [rbp-38h] BYREF
_QWORD v10[5]; // [rsp+10h] [rbp-28h] BYREF
if ( !a1 )
return 0LL;
if ( !*a1 )
return 0LL;
v2 = strchr(a1, 58LL);
if ( !v2 )
return 0LL;
v9 = v10;
std::string::_M_construct<char const*>(&v9, a1, &a1[(int)v2 - (int)a1]);
v3 = v9;
if ( `anonymous namespace'::IsValidURISchemeFormat((_anonymous_namespace_ *)v9, a1) )
{
Singleton = (unsigned int *)mujoco::GlobalTable<mjpResourceProvider>::GetSingleton(a2);
v5 = v9;
v6 = strlen(v9);
v7 = mujoco::GlobalTable<mjpResourceProvider>::GetByKeyUnsafe(Singleton, v6, v5, 0LL, Singleton[256]);
v3 = v9;
}
else
{
v7 = 0LL;
}
if ( v3 != v10 )
operator delete(v3, v10[0] + 1LL);
return v7;
}
| mjp_getResourceProvider:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x20
TEST RDI,RDI
JZ 0x0017c5d6
MOV RBX,RDI
CMP byte ptr [RDI],0x0
JZ 0x0017c5d6
MOV RDI,RBX
MOV ESI,0x3a
CALL 0x0012deb0
TEST RAX,RAX
JZ 0x0017c5d6
SUB EAX,EBX
MOVSXD RDX,EAX
LEA R15,[RSP + 0x10]
MOV qword ptr [R15 + -0x10],R15
ADD RDX,RBX
MOV R14,RSP
MOV RDI,R14
MOV RSI,RBX
CALL 0x0012dec0
MOV R14,qword ptr [R14]
MOV RDI,R14
CALL 0x0017c431
TEST AL,AL
JZ 0x0017c5e5
LAB_0017c5a2:
CALL 0x0017c4b6
MOV RBX,RAX
MOV R14,qword ptr [RSP]
MOV RDI,R14
CALL 0x0012de60
MOV R8D,dword ptr [RBX + 0x400]
MOV RDI,RBX
MOV RSI,RAX
MOV RDX,R14
XOR ECX,ECX
CALL 0x0017d25e
LAB_0017c5cd:
MOV RBX,RAX
MOV R14,qword ptr [RSP]
JMP 0x0017c5e7
LAB_0017c5d6:
XOR EBX,EBX
LAB_0017c5d8:
MOV RAX,RBX
ADD RSP,0x20
POP RBX
POP R14
POP R15
RET
LAB_0017c5e5:
XOR EBX,EBX
LAB_0017c5e7:
CMP R14,R15
JZ 0x0017c5d8
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
MOV RDI,R14
CALL 0x0012ded0
JMP 0x0017c5d8
|
int8 mjp_getResourceProvider(char *param_1)
{
char cVar1;
char *pcVar2;
long lVar3;
size_t sVar4;
int8 uVar5;
long *plVar6;
long *local_38 [2];
long local_28 [2];
if (((param_1 == (char *)0x0) || (*param_1 == '\0')) ||
(pcVar2 = strchr(param_1,0x3a), pcVar2 == (char *)0x0)) {
return 0;
}
local_38[0] = local_28;
std::__cxx11::string::_M_construct<char_const*>
(local_38,param_1,param_1 + ((int)pcVar2 - (int)param_1));
plVar6 = local_38[0];
cVar1 = (anonymous_namespace)::IsValidURISchemeFormat((char *)local_38[0]);
if (cVar1 == '\0') {
uVar5 = 0;
}
else {
/* try { // try from 0017c5a2 to 0017c5cc has its CatchHandler @ 0017c5fe */
lVar3 = mujoco::GlobalTable<mjpResourceProvider>::GetSingleton();
plVar6 = local_38[0];
sVar4 = strlen((char *)local_38[0]);
uVar5 = mujoco::GlobalTable<mjpResourceProvider>::GetByKeyUnsafe
(lVar3,sVar4,plVar6,0,*(int4 *)(lVar3 + 0x400));
plVar6 = local_38[0];
}
if (plVar6 == local_28) {
return uVar5;
}
operator_delete(plVar6,local_28[0] + 1);
return uVar5;
}
| |
23,333 | gguf_set_val_u8 | ngxson[P]ggml-easy/ggml/src/gguf.cpp | void gguf_set_val_u8(struct gguf_context * ctx, const char * key, uint8_t val) {
gguf_check_reserved_keys(key, val);
gguf_remove_key(ctx, key);
ctx->kv.emplace_back(key, val);
} | O1 | cpp | gguf_set_val_u8:
pushq %r14
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
movq %rsi, 0x10(%rsp)
movb %dl, 0xe(%rsp)
leaq 0x18(%rsp), %r14
leaq 0xf(%rsp), %rdx
movq %r14, %rdi
callq 0x17d00
leaq 0x1bcbe(%rip), %rsi # 0x59e92
movq %r14, %rdi
callq 0x163e0
testl %eax, %eax
je 0x3e227
leaq 0x28(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3e1fb
movq 0x28(%rsp), %rsi
incq %rsi
callq 0x17080
leaq 0x10(%rsp), %r14
movq (%r14), %rsi
movq %rbx, %rdi
callq 0x17660
addq $0x8, %rbx
leaq 0xe(%rsp), %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x16920
addq $0x38, %rsp
popq %rbx
popq %r14
retq
leaq 0x1bbf7(%rip), %rdi # 0x59e25
leaq 0x1c451(%rip), %rdx # 0x5a686
movl $0x3a8, %esi # imm = 0x3A8
xorl %eax, %eax
callq 0x17c70
movq %rax, %rbx
leaq 0x28(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3e25f
movq 0x28(%rsp), %rsi
incq %rsi
callq 0x17080
movq %rbx, %rdi
callq 0x17e30
| gguf_set_val_u8:
push r14
push rbx
sub rsp, 38h
mov rbx, rdi
mov [rsp+48h+var_38], rsi
mov [rsp+48h+var_3A], dl
lea r14, [rsp+48h+var_30]
lea rdx, [rsp+48h+var_39]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rsi, aGeneralAlignme; "general.alignment"
mov rdi, r14
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*)
test eax, eax
jz short loc_3E227
lea rax, [rsp+48h+var_20]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_3E1FB
mov rsi, [rsp+48h+var_20]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_3E1FB:
lea r14, [rsp+48h+var_38]
mov rsi, [r14]
mov rdi, rbx
call _gguf_remove_key
add rbx, 8
lea rdx, [rsp+48h+var_3A]
mov rdi, rbx
mov rsi, r14
call __ZNSt6vectorI7gguf_kvSaIS0_EE12emplace_backIJRPKcRhEEERS0_DpOT_; std::vector<gguf_kv>::emplace_back<char const*&,uchar &>(char const*&,uchar &)
add rsp, 38h
pop rbx
pop r14
retn
loc_3E227:
lea rdi, aWorkspaceLlm4b_5; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGeneralAlignme_0; "general.alignment must be type u32"
mov esi, 3A8h
xor eax, eax
call _ggml_abort
mov rbx, rax
lea rax, [rsp+48h+var_20]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_3E25F
mov rsi, [rsp+48h+var_20]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_3E25F:
mov rdi, rbx
call __Unwind_Resume
| long long gguf_set_val_u8(long long a1, long long a2, char a3)
{
int v3; // ecx
int v4; // r8d
int v5; // r9d
char v7; // [rsp+Eh] [rbp-3Ah] BYREF
char v8; // [rsp+Fh] [rbp-39h] BYREF
long long v9; // [rsp+10h] [rbp-38h] BYREF
void *v10[2]; // [rsp+18h] [rbp-30h] BYREF
long long v11; // [rsp+28h] [rbp-20h] BYREF
v9 = a2;
v7 = a3;
std::string::basic_string<std::allocator<char>>(v10, a2, &v8);
if ( !(unsigned int)std::string::compare(v10, "general.alignment") )
ggml_abort(
(unsigned int)"/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/gguf.cpp",
936,
(unsigned int)"general.alignment must be type u32",
v3,
v4,
v5);
if ( v10[0] != &v11 )
operator delete(v10[0], v11 + 1);
gguf_remove_key(a1, v9);
return std::vector<gguf_kv>::emplace_back<char const*&,unsigned char &>(a1 + 8, &v9, &v7);
}
| gguf_set_val_u8:
PUSH R14
PUSH RBX
SUB RSP,0x38
MOV RBX,RDI
MOV qword ptr [RSP + 0x10],RSI
MOV byte ptr [RSP + 0xe],DL
LEA R14,[RSP + 0x18]
LEA RDX,[RSP + 0xf]
MOV RDI,R14
CALL 0x00117d00
LEA RSI,[0x159e92]
MOV RDI,R14
CALL 0x001163e0
TEST EAX,EAX
JZ 0x0013e227
LEA RAX,[RSP + 0x28]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0013e1fb
MOV RSI,qword ptr [RSP + 0x28]
INC RSI
CALL 0x00117080
LAB_0013e1fb:
LEA R14,[RSP + 0x10]
MOV RSI,qword ptr [R14]
MOV RDI,RBX
CALL 0x00117660
ADD RBX,0x8
LEA RDX,[RSP + 0xe]
MOV RDI,RBX
MOV RSI,R14
CALL 0x00116920
ADD RSP,0x38
POP RBX
POP R14
RET
LAB_0013e227:
LEA RDI,[0x159e25]
LEA RDX,[0x15a686]
MOV ESI,0x3a8
XOR EAX,EAX
CALL 0x00117c70
|
void gguf_set_val_u8(long param_1,char *param_2,uchar param_3)
{
int iVar1;
uchar local_3a;
allocator local_39;
char *local_38;
long *local_30 [2];
long local_20 [2];
local_3a = param_3;
local_38 = param_2;
std::__cxx11::string::string<std::allocator<char>>((string *)local_30,param_2,&local_39);
iVar1 = std::__cxx11::string::compare((char *)local_30);
if (iVar1 != 0) {
if (local_30[0] != local_20) {
operator_delete(local_30[0],local_20[0] + 1);
}
gguf_remove_key(param_1,local_38);
std::vector<gguf_kv,std::allocator<gguf_kv>>::emplace_back<char_const*&,unsigned_char&>
((vector<gguf_kv,std::allocator<gguf_kv>> *)(param_1 + 8),&local_38,&local_3a);
return;
}
/* try { // try from 0013e227 to 0013e240 has its CatchHandler @ 0013e241 */
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/gguf.cpp",0x3a8,
"general.alignment must be type u32");
}
| |
23,334 | gguf_set_val_u8 | ngxson[P]ggml-easy/ggml/src/gguf.cpp | void gguf_set_val_u8(struct gguf_context * ctx, const char * key, uint8_t val) {
gguf_check_reserved_keys(key, val);
gguf_remove_key(ctx, key);
ctx->kv.emplace_back(key, val);
} | O2 | cpp | gguf_set_val_u8:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, 0x8(%rsp)
movb %dl, 0x6(%rsp)
leaq 0x10(%rsp), %r15
leaq 0x7(%rsp), %rdx
movq %r15, %rdi
callq 0x1e820
leaq 0x1abbe(%rip), %rsi # 0x5a982
movq %r15, %rdi
callq 0x1efa0
testb %al, %al
jne 0x3fe05
leaq 0x10(%rsp), %rdi
callq 0x1c9a0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1def0
addq $0x8, %rbx
leaq 0x8(%rsp), %rsi
leaq 0x6(%rsp), %rdx
movq %rbx, %rdi
callq 0x1cc90
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
leaq 0x1ab09(%rip), %rdi # 0x5a915
leaq 0x1b363(%rip), %rdx # 0x5b176
movl $0x3a8, %esi # imm = 0x3A8
xorl %eax, %eax
callq 0x1e770
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x1c9a0
movq %rbx, %rdi
callq 0x1e9b0
| gguf_set_val_u8:
push r15
push r14
push rbx
sub rsp, 30h
mov r14, rsi
mov rbx, rdi
mov [rsp+48h+var_40], rsi
mov [rsp+48h+var_42], dl
lea r15, [rsp+48h+var_38]
lea rdx, [rsp+48h+var_41]
mov rdi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rsi, aGeneralAlignme; "general.alignment"
mov rdi, r15
call __ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*)
test al, al
jnz short loc_3FE05
lea rdi, [rsp+48h+var_38]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, rbx
mov rsi, r14
call _gguf_remove_key
add rbx, 8
lea rsi, [rsp+48h+var_40]
lea rdx, [rsp+48h+var_42]
mov rdi, rbx
call __ZNSt6vectorI7gguf_kvSaIS0_EE12emplace_backIJRPKcRhEEERS0_DpOT_; std::vector<gguf_kv>::emplace_back<char const*&,uchar &>(char const*&,uchar &)
add rsp, 30h
pop rbx
pop r14
pop r15
retn
loc_3FE05:
lea rdi, aWorkspaceLlm4b_5; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGeneralAlignme_0; "general.alignment must be type u32"
mov esi, 3A8h
xor eax, eax
call _ggml_abort
mov rbx, rax
lea rdi, [rsp+48h+var_38]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, rbx
call __Unwind_Resume
| long long gguf_set_val_u8(
long long a1,
long long a2,
char a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
double a8,
double a9,
__m128 a10,
__m128 a11)
{
long long v11; // rcx
long long v12; // r8
long long v13; // r9
__m128 v14; // xmm4
__m128 v15; // xmm5
long long v16; // rdx
char v18; // [rsp+0h] [rbp-48h]
char v19; // [rsp+6h] [rbp-42h] BYREF
char v20; // [rsp+7h] [rbp-41h] BYREF
long long v21; // [rsp+8h] [rbp-40h] BYREF
_BYTE v22[56]; // [rsp+10h] [rbp-38h] BYREF
v21 = a2;
v19 = a3;
std::string::basic_string<std::allocator<char>>(v22, a2, &v20);
if ( (unsigned __int8)std::operator==<char>(v22, "general.alignment") )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/gguf.cpp",
936,
(long long)"general.alignment must be type u32",
v11,
v12,
v13,
a4,
a5,
a6,
a7,
v14,
v15,
a10,
a11,
v18);
std::string::~string(v22);
gguf_remove_key(a1, a2, v16);
return std::vector<gguf_kv>::emplace_back<char const*&,unsigned char &>(a1 + 8, &v21, &v19);
}
| gguf_set_val_u8:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV R14,RSI
MOV RBX,RDI
MOV qword ptr [RSP + 0x8],RSI
MOV byte ptr [RSP + 0x6],DL
LEA R15,[RSP + 0x10]
LEA RDX,[RSP + 0x7]
MOV RDI,R15
CALL 0x0011e820
LEA RSI,[0x15a982]
MOV RDI,R15
CALL 0x0011efa0
TEST AL,AL
JNZ 0x0013fe05
LEA RDI,[RSP + 0x10]
CALL 0x0011c9a0
MOV RDI,RBX
MOV RSI,R14
CALL 0x0011def0
ADD RBX,0x8
LEA RSI,[RSP + 0x8]
LEA RDX,[RSP + 0x6]
MOV RDI,RBX
CALL 0x0011cc90
ADD RSP,0x30
POP RBX
POP R14
POP R15
RET
LAB_0013fe05:
LEA RDI,[0x15a915]
LEA RDX,[0x15b176]
MOV ESI,0x3a8
XOR EAX,EAX
CALL 0x0011e770
|
void gguf_set_val_u8(long param_1,char *param_2,uchar param_3)
{
bool bVar1;
uchar local_42;
allocator local_41;
char *local_40;
string local_38 [32];
local_42 = param_3;
local_40 = param_2;
std::__cxx11::string::string<std::allocator<char>>(local_38,param_2,&local_41);
bVar1 = std::operator==(local_38,"general.alignment");
if (!bVar1) {
std::__cxx11::string::~string(local_38);
gguf_remove_key(param_1,param_2);
std::vector<gguf_kv,std::allocator<gguf_kv>>::emplace_back<char_const*&,unsigned_char&>
((vector<gguf_kv,std::allocator<gguf_kv>> *)(param_1 + 8),&local_40,&local_42);
return;
}
/* try { // try from 0013fe05 to 0013fe1e has its CatchHandler @ 0013fe1f */
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/gguf.cpp",0x3a8,
"general.alignment must be type u32");
}
| |
23,335 | write_hook_for_undo | eloqsql/storage/maria/ma_blockrec.c | my_bool write_hook_for_undo(enum translog_record_type type
__attribute__ ((unused)),
TRN *trn, MARIA_HA *tbl_info
__attribute__ ((unused)),
LSN *lsn, void *hook_arg
__attribute__ ((unused)))
{
DBUG_ASSERT(trn->trid != 0);
trn->undo_lsn= *lsn;
if (unlikely(LSN_WITH_FLAGS_TO_LSN(trn->first_undo_lsn) == 0))
trn->first_undo_lsn=
trn->undo_lsn | LSN_WITH_FLAGS_TO_FLAGS(trn->first_undo_lsn);
return 0;
/*
when we implement purging, we will specialize this hook: UNDO_PURGE
records will additionally set trn->undo_purge_lsn
*/
} | O3 | c | write_hook_for_undo:
pushq %rbp
movq %rsp, %rbp
movq (%rcx), %rax
movq %rax, 0x98(%rsi)
movq 0xa0(%rsi), %rcx
movq %rcx, %rdx
shlq $0x8, %rdx
je 0x48c76
xorl %eax, %eax
popq %rbp
retq
orq %rax, %rcx
movq %rcx, 0xa0(%rsi)
jmp 0x48c72
| write_hook_for_undo:
push rbp
mov rbp, rsp
mov rax, [rcx]
mov [rsi+98h], rax
mov rcx, [rsi+0A0h]
mov rdx, rcx
shl rdx, 8
jz short loc_48C76
loc_48C72:
xor eax, eax
pop rbp
retn
loc_48C76:
or rcx, rax
mov [rsi+0A0h], rcx
jmp short loc_48C72
| long long write_hook_for_undo(long long a1, long long a2, long long a3, long long *a4)
{
long long v4; // rax
v4 = *a4;
*(_QWORD *)(a2 + 152) = *a4;
if ( !(*(_QWORD *)(a2 + 160) << 8) )
*(_QWORD *)(a2 + 160) |= v4;
return 0LL;
}
| write_hook_for_undo:
PUSH RBP
MOV RBP,RSP
MOV RAX,qword ptr [RCX]
MOV qword ptr [RSI + 0x98],RAX
MOV RCX,qword ptr [RSI + 0xa0]
MOV RDX,RCX
SHL RDX,0x8
JZ 0x00148c76
LAB_00148c72:
XOR EAX,EAX
POP RBP
RET
LAB_00148c76:
OR RCX,RAX
MOV qword ptr [RSI + 0xa0],RCX
JMP 0x00148c72
|
int8 write_hook_for_undo(int8 param_1,long param_2,int8 param_3,ulong *param_4)
{
ulong uVar1;
uVar1 = *param_4;
*(ulong *)(param_2 + 0x98) = uVar1;
if ((*(ulong *)(param_2 + 0xa0) & 0xffffffffffffff) == 0) {
*(ulong *)(param_2 + 0xa0) = *(ulong *)(param_2 + 0xa0) | uVar1;
}
return 0;
}
| |
23,336 | nlohmann::json_abi_v3_11_3::detail::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>, 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>>>>>::exception_message(nlohmann::json_abi_v3_11_3::detail::lexer_base<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>>::token_type, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | monkey531[P]llama/common/./json.hpp | std::string exception_message(const token_type expected, const std::string& context)
{
std::string error_msg = "syntax error ";
if (!context.empty())
{
error_msg += concat("while parsing ", context, ' ');
}
error_msg += "- ";
if (last_token == token_type::parse_error)
{
error_msg += concat(m_lexer.get_error_message(), "; last read: '",
m_lexer.get_token_string(), '\'');
}
else
{
error_msg += concat("unexpected ", lexer_t::token_type_name(last_token));
}
if (expected != token_type::uninitialized)
{
error_msg += concat("; expected ", lexer_t::token_type_name(expected));
}
return error_msg;
} | O0 | cpp | nlohmann::json_abi_v3_11_3::detail::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>, 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>>>>>::exception_message(nlohmann::json_abi_v3_11_3::detail::lexer_base<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>>::token_type, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
subq $0x128, %rsp # imm = 0x128
movq %rdi, 0x18(%rsp)
movq %rdi, %rax
movq %rax, 0x8(%rsp)
movq %rdi, 0x120(%rsp)
movq %rsi, 0x118(%rsp)
movl %edx, 0x114(%rsp)
movq %rcx, 0x108(%rsp)
movq 0x118(%rsp), %rax
movq %rax, 0x10(%rsp)
movb $0x0, 0x107(%rsp)
leaq 0x106(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0x50d60
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rdx
leaq 0x11c1d3(%rip), %rsi # 0x1cfc8e
callq 0x61bd0
jmp 0xb3ac2
leaq 0x106(%rsp), %rdi
callq 0x510a0
movq 0x108(%rsp), %rdi
callq 0x503b0
testb $0x1, %al
jne 0xb3b9a
movq 0x108(%rsp), %rdx
movb $0x20, 0xcf(%rsp)
leaq 0x12a585(%rip), %rsi # 0x1de080
leaq 0xd0(%rsp), %rdi
leaq 0xcf(%rsp), %rcx
callq 0xc12a0
jmp 0xb3b12
movq 0x18(%rsp), %rdi
leaq 0xd0(%rsp), %rsi
callq 0x50110
jmp 0xb3b26
leaq 0xd0(%rsp), %rdi
callq 0x510c0
jmp 0xb3b9a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0x106(%rsp), %rdi
callq 0x510a0
jmp 0xb3da2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
jmp 0xb3d98
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0xd0(%rsp), %rdi
callq 0x510c0
jmp 0xb3d98
movq 0x18(%rsp), %rdi
leaq 0x11c0f6(%rip), %rsi # 0x1cfc9c
callq 0x501c0
jmp 0xb3bad
movq 0x10(%rsp), %rax
cmpl $0xe, 0x20(%rax)
jne 0xb3c95
movq 0x10(%rsp), %rdi
addq $0x28, %rdi
movq %rdi, (%rsp)
callq 0xc1430
movq (%rsp), %rsi
movq %rax, 0xa0(%rsp)
leaq 0x80(%rsp), %rdi
callq 0xb36a0
jmp 0xb3be9
movb $0x27, 0x7f(%rsp)
leaq 0x11c0aa(%rip), %rdx # 0x1cfc9f
leaq 0xa8(%rsp), %rdi
leaq 0xa0(%rsp), %rsi
leaq 0x80(%rsp), %rcx
leaq 0x7f(%rsp), %r8
callq 0xc1360
jmp 0xb3c19
movq 0x18(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
callq 0x50110
jmp 0xb3c2d
leaq 0xa8(%rsp), %rdi
callq 0x510c0
leaq 0x80(%rsp), %rdi
callq 0x510c0
jmp 0xb3cff
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
jmp 0xb3c83
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0xa8(%rsp), %rdi
callq 0x510c0
leaq 0x80(%rsp), %rdi
callq 0x510c0
jmp 0xb3d98
movq 0x10(%rsp), %rax
movl 0x20(%rax), %edi
callq 0xc14f0
movq %rax, 0x50(%rsp)
leaq 0x11c000(%rip), %rsi # 0x1cfcae
leaq 0x58(%rsp), %rdi
leaq 0x50(%rsp), %rdx
callq 0xc1440
jmp 0xb3cbf
movq 0x18(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x50110
jmp 0xb3cd0
leaq 0x58(%rsp), %rdi
callq 0x510c0
jmp 0xb3cff
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x510c0
jmp 0xb3d98
cmpl $0x0, 0x114(%rsp)
je 0xb3d6f
movl 0x114(%rsp), %edi
callq 0xc14f0
movq %rax, 0x28(%rsp)
leaq 0x11bf99(%rip), %rsi # 0x1cfcba
leaq 0x30(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0xc1440
jmp 0xb3d32
movq 0x18(%rsp), %rdi
leaq 0x30(%rsp), %rsi
callq 0x50110
jmp 0xb3d43
leaq 0x30(%rsp), %rdi
callq 0x510c0
jmp 0xb3d6f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0x30(%rsp), %rdi
callq 0x510c0
jmp 0xb3d98
movb $0x1, 0x107(%rsp)
testb $0x1, 0x107(%rsp)
jne 0xb3d8b
movq 0x18(%rsp), %rdi
callq 0x510c0
movq 0x8(%rsp), %rax
addq $0x128, %rsp # imm = 0x128
retq
movq 0x18(%rsp), %rdi
callq 0x510c0
movq 0xf8(%rsp), %rdi
callq 0x50940
nop
| _ZN8nlohmann16json_abi_v3_11_36detail6parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE17exception_messageENS1_10lexer_baseISF_E10token_typeERKSB_:
sub rsp, 128h
mov [rsp+128h+var_110], rdi; __int64
mov rax, rdi
mov [rsp+128h+var_120], rax; void *
mov [rsp+128h+var_8], rdi
mov qword ptr [rsp+128h+var_10], rsi
mov [rsp+128h+var_14], edx
mov [rsp+128h+var_22+2], rcx
mov rax, qword ptr [rsp+128h+var_10]
mov qword ptr [rsp+128h+var_118], rax; int
mov byte ptr [rsp+128h+var_22+1], 0
lea rdi, [rsp+128h+var_22]
mov [rsp+128h+var_108], rdi; int
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rsp+128h+var_110]
mov rdx, [rsp+128h+var_108]
lea rsi, aSyntaxError; "syntax error "
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_B3AC2:
lea rdi, [rsp+128h+var_22]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rdi, [rsp+128h+var_22+2]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5emptyEv; std::string::empty(void)
test al, 1
jnz loc_B3B9A
mov rdx, [rsp+128h+var_22+2]; int
mov byte ptr [rsp+128h+var_59], 20h ; ' '
lea rsi, aSyntaxErrorWhi+0Dh; int
lea rdi, [rsp+128h+var_59+1]; int
lea rcx, [rsp+128h+var_59]; int
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA15_KcRKS8_cEEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[15],std::string const&,char>(char const(&)[15],std::string const&,char &&)
jmp short $+2
loc_B3B12:
mov rdi, [rsp+128h+var_110]
lea rsi, [rsp+128h+var_59+1]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_; std::string::operator+=(std::string const&)
jmp short $+2
loc_B3B26:
lea rdi, [rsp+128h+var_59+1]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_B3B9A
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_FE]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_B3DA2
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
jmp loc_B3D98
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_C8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_B3D98
loc_B3B9A:
mov rdi, [rsp+128h+var_110]
lea rsi, asc_1CFC9C; "- "
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc; std::string::operator+=(char const*)
jmp short $+2
loc_B3BAD:
mov rax, qword ptr [rsp+128h+var_118]
cmp dword ptr [rax+20h], 0Eh
jnz loc_B3C95
mov rdi, qword ptr [rsp+128h+var_118]
add rdi, 28h ; '('
mov qword ptr [rsp+128h+var_128], rdi; int
call _ZNK8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE17get_error_messageEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get_error_message(void)
mov rsi, qword ptr [rsp+128h+var_128]; int
mov [rsp+128h+var_88], rax
lea rdi, [rsp+128h+var_A8]; int
call _ZNK8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE16get_token_stringEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get_token_string(void)
jmp short $+2
loc_B3BE9:
mov [rsp+128h+var_A9], 27h ; '''
lea rdx, aLastRead; "; last read: '"
lea rdi, [rsp+128h+var_80]
lea rsi, [rsp+128h+var_88]
lea rcx, [rsp+128h+var_A8]
lea r8, [rsp+128h+var_A9]
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJPKcRA15_S9_S8_cEEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const*,char const(&)[15],std::string,char>(char const*,char const(&)[15],std::string,char &&)
jmp short $+2
loc_B3C19:
mov rdi, [rsp+128h+var_110]
lea rsi, [rsp+128h+var_80]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_; std::string::operator+=(std::string const&)
jmp short $+2
loc_B3C2D:
lea rdi, [rsp+128h+var_80]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+128h+var_A8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_B3CFF
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
jmp short loc_B3C83
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_A0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_B3C83:
lea rdi, [rsp+arg_78]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_B3D98
loc_B3C95:
mov rax, qword ptr [rsp+128h+var_118]
mov edi, [rax+20h]
call _ZN8nlohmann16json_abi_v3_11_36detail10lexer_baseINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE15token_type_nameENSG_10token_typeE; nlohmann::json_abi_v3_11_3::detail::lexer_base<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>>::token_type_name(nlohmann::json_abi_v3_11_3::detail::lexer_base<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>>::token_type)
mov qword ptr [rsp+128h+var_D8], rax
lea rsi, aUnexpected; "unexpected "
lea rdi, [rsp+128h+var_D0]; int
lea rdx, [rsp+128h+var_D8]; int
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA12_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[12],char const*>(char const(&)[12],char const* &&)
jmp short $+2
loc_B3CBF:
mov rdi, [rsp+128h+var_110]
lea rsi, [rsp+128h+var_D0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_; std::string::operator+=(std::string const&)
jmp short $+2
loc_B3CD0:
lea rdi, [rsp+128h+var_D0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_B3CFF
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_50]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_B3D98
loc_B3CFF:
cmp [rsp+128h+var_14], 0
jz short loc_B3D6F
mov edi, [rsp+128h+var_14]
call _ZN8nlohmann16json_abi_v3_11_36detail10lexer_baseINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE15token_type_nameENSG_10token_typeE; nlohmann::json_abi_v3_11_3::detail::lexer_base<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>>::token_type_name(nlohmann::json_abi_v3_11_3::detail::lexer_base<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>>::token_type)
mov qword ptr [rsp+128h+var_100], rax
lea rsi, aExpected; "; expected "
lea rdi, [rsp+128h+var_F8]; int
lea rdx, [rsp+128h+var_100]; int
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA12_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[12],char const*>(char const(&)[12],char const* &&)
jmp short $+2
loc_B3D32:
mov rdi, [rsp+128h+var_110]
lea rsi, [rsp+128h+var_F8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_; std::string::operator+=(std::string const&)
jmp short $+2
loc_B3D43:
lea rdi, [rsp+128h+var_F8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_B3D6F
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_28]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_B3D98
loc_B3D6F:
mov byte ptr [rsp+128h+var_22+1], 1
test byte ptr [rsp+128h+var_22+1], 1
jnz short loc_B3D8B
mov rdi, [rsp+128h+var_110]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_B3D8B:
mov rax, [rsp+128h+var_120]
add rsp, 128h
retn
loc_B3D98:
mov rdi, [rsp+arg_10]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_B3DA2:
mov rdi, [rsp+arg_F0]
call __Unwind_Resume
| void * nlohmann::json_abi_v3_11_3::detail::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>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::exception_message(
long long a1,
long long a2,
unsigned int a3,
long long a4)
{
int v4; // r8d
int v5; // r9d
int v6; // r9d
int v7; // ecx
int v8; // r8d
int v9; // r9d
int v10; // ecx
int v11; // r8d
int v12; // r9d
void *v14; // [rsp+0h] [rbp-128h]
int v15; // [rsp+0h] [rbp-128h]
void *v16; // [rsp+8h] [rbp-120h]
void *v17; // [rsp+8h] [rbp-120h]
int v18[2]; // [rsp+10h] [rbp-118h]
int v19; // [rsp+10h] [rbp-118h]
void *v20; // [rsp+18h] [rbp-110h]
void *v21; // [rsp+18h] [rbp-110h]
void *v22; // [rsp+18h] [rbp-110h]
int v23[2]; // [rsp+28h] [rbp-100h] BYREF
int v24[8]; // [rsp+30h] [rbp-F8h] BYREF
int v25[2]; // [rsp+50h] [rbp-D8h] BYREF
int v26[9]; // [rsp+58h] [rbp-D0h] BYREF
char v27; // [rsp+7Fh] [rbp-A9h] BYREF
int v28[8]; // [rsp+80h] [rbp-A8h] BYREF
long long error_message; // [rsp+A0h] [rbp-88h] BYREF
_BYTE v30[39]; // [rsp+A8h] [rbp-80h] BYREF
char v31; // [rsp+CFh] [rbp-59h] BYREF
_BYTE v32[54]; // [rsp+D0h] [rbp-58h] BYREF
_BYTE v33[14]; // [rsp+106h] [rbp-22h] BYREF
unsigned int v34; // [rsp+114h] [rbp-14h]
int v35[2]; // [rsp+118h] [rbp-10h]
long long v36; // [rsp+120h] [rbp-8h]
v20 = (void *)a1;
v16 = (void *)a1;
v36 = a1;
*(_QWORD *)v35 = a2;
v34 = a3;
*(_QWORD *)&v33[2] = a4;
*(_QWORD *)v18 = a2;
v33[1] = 0;
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, (long long)"syntax error ", (long long)v33);
std::allocator<char>::~allocator(v33);
if ( (std::string::empty(*(_QWORD *)&v33[2]) & 1) == 0 )
{
v31 = 32;
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[15],std::string const&,char>(
(int)v32,
(int)"while parsing ",
*(int *)&v33[2],
(int)&v31,
v4,
v5,
v14,
a1,
a2,
a1,
(long long)v33);
std::string::operator+=(v20, v32);
std::string::~string(v32);
}
std::string::operator+=(v20, "- ");
if ( *(_DWORD *)(*(_QWORD *)v18 + 32LL) == 14 )
{
error_message = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get_error_message();
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get_token_string(
(long long)v28,
*(_QWORD *)v18 + 40LL);
v27 = 39;
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const*,char const(&)[15],std::string,char>(
(unsigned int)v30,
(unsigned int)&error_message,
(unsigned int)"; last read: '",
(unsigned int)v28,
(unsigned int)&v27,
v6,
v18[0] + 40,
(_DWORD)v16,
v18[0],
(long long)v20);
std::string::operator+=(v21, v30);
std::string::~string(v30);
std::string::~string(v28);
}
else
{
*(_QWORD *)v25 = nlohmann::json_abi_v3_11_3::detail::lexer_base<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>>::token_type_name(*(unsigned int *)(*(_QWORD *)v18 + 32LL));
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[12],char const*>(
(int)v26,
(int)"unexpected ",
(int)v25,
v7,
v8,
v9,
(int)v14,
v16,
v18[0],
(long long)v20);
std::string::operator+=(v21, v26);
std::string::~string(v26);
}
if ( v34 )
{
*(_QWORD *)v23 = nlohmann::json_abi_v3_11_3::detail::lexer_base<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>>::token_type_name(v34);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[12],char const*>(
(int)v24,
(int)"; expected ",
(int)v23,
v10,
v11,
v12,
v15,
v17,
v19,
(long long)v21);
std::string::operator+=(v22, v24);
std::string::~string(v24);
}
return v17;
}
| exception_message:
SUB RSP,0x128
MOV qword ptr [RSP + 0x18],RDI
MOV RAX,RDI
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x120],RDI
MOV qword ptr [RSP + 0x118],RSI
MOV dword ptr [RSP + 0x114],EDX
MOV qword ptr [RSP + 0x108],RCX
MOV RAX,qword ptr [RSP + 0x118]
MOV qword ptr [RSP + 0x10],RAX
MOV byte ptr [RSP + 0x107],0x0
LEA RDI,[RSP + 0x106]
MOV qword ptr [RSP + 0x20],RDI
CALL 0x00150d60
MOV RDI,qword ptr [RSP + 0x18]
MOV RDX,qword ptr [RSP + 0x20]
LAB_001b3ab4:
LEA RSI,[0x2cfc8e]
CALL 0x00161bd0
JMP 0x001b3ac2
LAB_001b3ac2:
LEA RDI,[RSP + 0x106]
CALL 0x001510a0
MOV RDI,qword ptr [RSP + 0x108]
CALL 0x001503b0
TEST AL,0x1
JNZ 0x001b3b9a
MOV RDX,qword ptr [RSP + 0x108]
MOV byte ptr [RSP + 0xcf],0x20
LAB_001b3af4:
LEA RSI,[0x2de080]
LEA RDI,[RSP + 0xd0]
LEA RCX,[RSP + 0xcf]
CALL 0x001c12a0
JMP 0x001b3b12
LAB_001b3b12:
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[RSP + 0xd0]
CALL 0x00150110
JMP 0x001b3b26
LAB_001b3b26:
LEA RDI,[RSP + 0xd0]
CALL 0x001510c0
JMP 0x001b3b9a
LAB_001b3b9a:
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x2cfc9c]
CALL 0x001501c0
JMP 0x001b3bad
LAB_001b3bad:
MOV RAX,qword ptr [RSP + 0x10]
CMP dword ptr [RAX + 0x20],0xe
JNZ 0x001b3c95
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0x28
MOV qword ptr [RSP],RDI
CALL 0x001c1430
MOV RSI,qword ptr [RSP]
MOV qword ptr [RSP + 0xa0],RAX
LEA RDI,[RSP + 0x80]
CALL 0x001b36a0
JMP 0x001b3be9
LAB_001b3be9:
MOV byte ptr [RSP + 0x7f],0x27
LAB_001b3bee:
LEA RDX,[0x2cfc9f]
LEA RDI,[RSP + 0xa8]
LEA RSI,[RSP + 0xa0]
LEA RCX,[RSP + 0x80]
LEA R8,[RSP + 0x7f]
CALL 0x001c1360
JMP 0x001b3c19
LAB_001b3c19:
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[RSP + 0xa8]
CALL 0x00150110
JMP 0x001b3c2d
LAB_001b3c2d:
LEA RDI,[RSP + 0xa8]
CALL 0x001510c0
LEA RDI,[RSP + 0x80]
CALL 0x001510c0
JMP 0x001b3cff
LAB_001b3c95:
MOV RAX,qword ptr [RSP + 0x10]
MOV EDI,dword ptr [RAX + 0x20]
CALL 0x001c14f0
MOV qword ptr [RSP + 0x50],RAX
LAB_001b3ca7:
LEA RSI,[0x2cfcae]
LEA RDI,[RSP + 0x58]
LEA RDX,[RSP + 0x50]
CALL 0x001c1440
JMP 0x001b3cbf
LAB_001b3cbf:
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[RSP + 0x58]
CALL 0x00150110
JMP 0x001b3cd0
LAB_001b3cd0:
LEA RDI,[RSP + 0x58]
CALL 0x001510c0
JMP 0x001b3cff
LAB_001b3cff:
CMP dword ptr [RSP + 0x114],0x0
JZ 0x001b3d6f
MOV EDI,dword ptr [RSP + 0x114]
CALL 0x001c14f0
MOV qword ptr [RSP + 0x28],RAX
LAB_001b3d1a:
LEA RSI,[0x2cfcba]
LEA RDI,[RSP + 0x30]
LEA RDX,[RSP + 0x28]
CALL 0x001c1440
JMP 0x001b3d32
LAB_001b3d32:
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[RSP + 0x30]
CALL 0x00150110
LAB_001b3d41:
JMP 0x001b3d43
LAB_001b3d43:
LEA RDI,[RSP + 0x30]
CALL 0x001510c0
JMP 0x001b3d6f
LAB_001b3d6f:
MOV byte ptr [RSP + 0x107],0x1
TEST byte ptr [RSP + 0x107],0x1
JNZ 0x001b3d8b
MOV RDI,qword ptr [RSP + 0x18]
CALL 0x001510c0
LAB_001b3d8b:
MOV RAX,qword ptr [RSP + 0x8]
ADD RSP,0x128
RET
|
/* WARNING: Removing unreachable block (ram,0x001b3d81) */
/* nlohmann::json_abi_v3_11_3::detail::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>,
nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char
const*, std::__cxx11::string > >
>::exception_message(nlohmann::json_abi_v3_11_3::detail::lexer_base<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> >::token_type, std::__cxx11::string const&) */
string * nlohmann::json_abi_v3_11_3::detail::
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>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
::exception_message(string *param_1,long param_2,int param_3,string *param_4)
{
ulong uVar1;
char *local_100;
detail local_f8 [32];
char *local_d8;
detail local_d0 [39];
char local_a9;
string local_a8 [32];
char *local_88;
detail local_80 [39];
char local_59;
detail local_58 [54];
allocator local_22;
int1 local_21;
string *local_20;
int local_14;
long local_10;
string *local_8;
local_21 = 0;
local_20 = param_4;
local_14 = param_3;
local_10 = param_2;
local_8 = param_1;
std::allocator<char>::allocator();
/* try { // try from 001b3ab4 to 001b3abf has its CatchHandler @ 001b3b35 */
std::__cxx11::string::string<std::allocator<char>>(param_1,"syntax error ",&local_22);
std::allocator<char>::~allocator((allocator<char> *)&local_22);
uVar1 = std::__cxx11::string::empty();
if ((uVar1 & 1) == 0) {
local_59 = ' ';
/* try { // try from 001b3af4 to 001b3b0f has its CatchHandler @ 001b3b5b */
concat<std::__cxx11::string,char_const(&)[15],std::__cxx11::string_const&,char>
(local_58,"while parsing ",local_20,&local_59);
/* try { // try from 001b3b12 to 001b3b23 has its CatchHandler @ 001b3b74 */
std::__cxx11::string::operator+=(param_1,(string *)local_58);
std::__cxx11::string::~string((string *)local_58);
}
/* try { // try from 001b3b9a to 001b3be6 has its CatchHandler @ 001b3b5b */
std::__cxx11::string::operator+=(param_1,"- ");
if (*(int *)(param_2 + 0x20) == 0xe) {
local_88 = (char *)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>>>
::get_error_message((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>>>
*)(param_2 + 0x28));
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>>>
::get_token_string();
local_a9 = '\'';
/* try { // try from 001b3bee to 001b3c16 has its CatchHandler @ 001b3c4c */
concat<std::__cxx11::string,char_const*,char_const(&)[15],std::__cxx11::string,char>
(local_80,&local_88,"; last read: \'",local_a8,&local_a9);
/* try { // try from 001b3c19 to 001b3c2a has its CatchHandler @ 001b3c62 */
std::__cxx11::string::operator+=(param_1,(string *)local_80);
std::__cxx11::string::~string((string *)local_80);
std::__cxx11::string::~string(local_a8);
}
else {
local_d8 = (char *)lexer_base<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>>
::token_type_name(*(int4 *)(param_2 + 0x20));
/* try { // try from 001b3ca7 to 001b3cbc has its CatchHandler @ 001b3b5b */
concat<std::__cxx11::string,char_const(&)[12],char_const*>(local_d0,"unexpected ",&local_d8);
/* try { // try from 001b3cbf to 001b3ccd has its CatchHandler @ 001b3cdc */
std::__cxx11::string::operator+=(param_1,(string *)local_d0);
std::__cxx11::string::~string((string *)local_d0);
}
if (local_14 != 0) {
local_100 = (char *)lexer_base<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>>
::token_type_name(local_14);
/* try { // try from 001b3d1a to 001b3d2f has its CatchHandler @ 001b3b5b */
concat<std::__cxx11::string,char_const(&)[12],char_const*>(local_f8,"; expected ",&local_100);
/* try { // try from 001b3d32 to 001b3d40 has its CatchHandler @ 001b3d4f */
std::__cxx11::string::operator+=(param_1,(string *)local_f8);
std::__cxx11::string::~string((string *)local_f8);
}
return param_1;
}
| |
23,337 | maria_page_filler_set_normal | eloqsql/storage/maria/ma_pagecrc.c | my_bool maria_page_filler_set_normal(PAGECACHE_IO_HOOK_ARGS *args)
{
uchar *page= args->page;
#ifdef DBUG_ASSERT_EXISTS
pgcache_page_no_t page_no= args->pageno;
#endif
MARIA_SHARE *share= (MARIA_SHARE *)args->data;
DBUG_ENTER("maria_page_filler_set_normal");
DBUG_ASSERT(page_no != 0); /* Catches some simple bugs */
int4store_aligned(page + share->block_size - CRC_SIZE,
MARIA_NO_CRC_NORMAL_PAGE);
DBUG_RETURN(0);
} | O0 | c | maria_page_filler_set_normal:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x18(%rbp)
jmp 0x43541
jmp 0x43543
movq -0x10(%rbp), %rax
movq -0x18(%rbp), %rcx
movl 0x7bc(%rcx), %ecx
addq %rcx, %rax
addq $-0x4, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movl $0xffffffff, (%rax) # imm = 0xFFFFFFFF
jmp 0x43568
jmp 0x4356a
xorl %eax, %eax
popq %rbp
retq
nop
| maria_page_filler_set_normal:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_10], rax
mov rax, [rbp+var_8]
mov rax, [rax+10h]
mov [rbp+var_18], rax
jmp short $+2
loc_43541:
jmp short $+2
loc_43543:
mov rax, [rbp+var_10]
mov rcx, [rbp+var_18]
mov ecx, [rcx+7BCh]
add rax, rcx
add rax, 0FFFFFFFFFFFFFFFCh
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
mov dword ptr [rax], 0FFFFFFFFh
jmp short $+2
loc_43568:
jmp short $+2
loc_4356A:
xor eax, eax
pop rbp
retn
| long long maria_page_filler_set_normal(_QWORD *a1)
{
*(_DWORD *)(*(unsigned int *)(a1[2] + 1980LL) + *a1 - 4LL) = -1;
return 0LL;
}
| maria_page_filler_set_normal:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x18],RAX
JMP 0x00143541
LAB_00143541:
JMP 0x00143543
LAB_00143543:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RCX + 0x7bc]
ADD RAX,RCX
ADD RAX,-0x4
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX],0xffffffff
JMP 0x00143568
LAB_00143568:
JMP 0x0014356a
LAB_0014356a:
XOR EAX,EAX
POP RBP
RET
|
int8 maria_page_filler_set_normal(long *param_1)
{
*(int4 *)(*param_1 + (ulong)*(uint *)(param_1[2] + 0x7bc) + -4) = 0xffffffff;
return 0;
}
| |
23,338 | glfwInitVulkan | untodesu[P]riteg/build_O3/_deps/glfw-src/src/vulkan.c | GLFWbool _glfwInitVulkan(int mode)
{
VkResult err;
VkExtensionProperties* ep;
uint32_t i, count;
if (_glfw.vk.available)
return GLFW_TRUE;
#if !defined(_GLFW_VULKAN_STATIC)
#if defined(_GLFW_VULKAN_LIBRARY)
_glfw.vk.handle = _glfw_dlopen(_GLFW_VULKAN_LIBRARY);
#elif defined(_GLFW_WIN32)
_glfw.vk.handle = _glfw_dlopen("vulkan-1.dll");
#elif defined(_GLFW_COCOA)
_glfw.vk.handle = _glfw_dlopen("libvulkan.1.dylib");
#else
_glfw.vk.handle = _glfw_dlopen("libvulkan.so.1");
#endif
if (!_glfw.vk.handle)
{
if (mode == _GLFW_REQUIRE_LOADER)
_glfwInputError(GLFW_API_UNAVAILABLE, "Vulkan: Loader not found");
return GLFW_FALSE;
}
_glfw.vk.GetInstanceProcAddr = (PFN_vkGetInstanceProcAddr)
_glfw_dlsym(_glfw.vk.handle, "vkGetInstanceProcAddr");
if (!_glfw.vk.GetInstanceProcAddr)
{
_glfwInputError(GLFW_API_UNAVAILABLE,
"Vulkan: Loader does not export vkGetInstanceProcAddr");
_glfwTerminateVulkan();
return GLFW_FALSE;
}
_glfw.vk.EnumerateInstanceExtensionProperties = (PFN_vkEnumerateInstanceExtensionProperties)
vkGetInstanceProcAddr(NULL, "vkEnumerateInstanceExtensionProperties");
if (!_glfw.vk.EnumerateInstanceExtensionProperties)
{
_glfwInputError(GLFW_API_UNAVAILABLE,
"Vulkan: Failed to retrieve vkEnumerateInstanceExtensionProperties");
_glfwTerminateVulkan();
return GLFW_FALSE;
}
#endif // _GLFW_VULKAN_STATIC
err = vkEnumerateInstanceExtensionProperties(NULL, &count, NULL);
if (err)
{
// NOTE: This happens on systems with a loader but without any Vulkan ICD
if (mode == _GLFW_REQUIRE_LOADER)
{
_glfwInputError(GLFW_API_UNAVAILABLE,
"Vulkan: Failed to query instance extension count: %s",
_glfwGetVulkanResultString(err));
}
_glfwTerminateVulkan();
return GLFW_FALSE;
}
ep = calloc(count, sizeof(VkExtensionProperties));
err = vkEnumerateInstanceExtensionProperties(NULL, &count, ep);
if (err)
{
_glfwInputError(GLFW_API_UNAVAILABLE,
"Vulkan: Failed to query instance extensions: %s",
_glfwGetVulkanResultString(err));
free(ep);
_glfwTerminateVulkan();
return GLFW_FALSE;
}
for (i = 0; i < count; i++)
{
if (strcmp(ep[i].extensionName, "VK_KHR_surface") == 0)
_glfw.vk.KHR_surface = GLFW_TRUE;
#if defined(_GLFW_WIN32)
else if (strcmp(ep[i].extensionName, "VK_KHR_win32_surface") == 0)
_glfw.vk.KHR_win32_surface = GLFW_TRUE;
#elif defined(_GLFW_COCOA)
else if (strcmp(ep[i].extensionName, "VK_MVK_macos_surface") == 0)
_glfw.vk.MVK_macos_surface = GLFW_TRUE;
#elif defined(_GLFW_X11)
else if (strcmp(ep[i].extensionName, "VK_KHR_xlib_surface") == 0)
_glfw.vk.KHR_xlib_surface = GLFW_TRUE;
else if (strcmp(ep[i].extensionName, "VK_KHR_xcb_surface") == 0)
_glfw.vk.KHR_xcb_surface = GLFW_TRUE;
#elif defined(_GLFW_WAYLAND)
else if (strcmp(ep[i].extensionName, "VK_KHR_wayland_surface") == 0)
_glfw.vk.KHR_wayland_surface = GLFW_TRUE;
#endif
}
free(ep);
_glfw.vk.available = GLFW_TRUE;
_glfwPlatformGetRequiredInstanceExtensions(_glfw.vk.extensions);
return GLFW_TRUE;
} | O3 | c | glfwInitVulkan:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
leaq 0x8c062(%rip), %rbx # 0xa8638
movl $0x1, %r14d
cmpl $0x0, 0x1fe70(%rbx)
je 0x1c5f7
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %edi, %ebp
leaq 0x67310(%rip), %rdi # 0x83910
movl $0x1, %esi
callq 0xcb30
movq %rax, 0x1fe78(%rbx)
testq %rax, %rax
je 0x1c690
leaq 0x6733a(%rip), %rsi # 0x83957
movq %rax, %rdi
callq 0xc820
movq %rax, 0x1fe98(%rbx)
testq %rax, %rax
je 0x1c6b7
leaq 0x6734c(%rip), %rsi # 0x83988
xorl %r14d, %r14d
xorl %edi, %edi
callq *%rax
movq %rax, 0x1fe90(%rbx)
testq %rax, %rax
je 0x1c6c3
leaq 0x4(%rsp), %rsi
xorl %edi, %edi
xorl %edx, %edx
callq *%rax
testl %eax, %eax
je 0x1c6f0
cmpl $0x2, %ebp
jne 0x1c684
movl %eax, %edi
callq 0x1c800
leaq 0x6733a(%rip), %rsi # 0x839af
movl $0x10006, %edi # imm = 0x10006
movq %rax, %rdx
xorl %eax, %eax
callq 0x18e91
movq 0x1fe78(%rbx), %rdi
xorl %r14d, %r14d
jmp 0x1c6dd
xorl %r14d, %r14d
cmpl $0x2, %ebp
jne 0x1c5e5
leaq 0x6727c(%rip), %rsi # 0x8391f
xorl %r14d, %r14d
movl $0x10006, %edi # imm = 0x10006
xorl %eax, %eax
callq 0x18e91
jmp 0x1c5e5
leaq 0x6727a(%rip), %rsi # 0x83938
xorl %r14d, %r14d
jmp 0x1c6ca
leaq 0x672a3(%rip), %rsi # 0x8396d
movl $0x10006, %edi # imm = 0x10006
xorl %eax, %eax
callq 0x18e91
movq 0x1fe78(%rbx), %rdi
testq %rdi, %rdi
je 0x1c5e5
callq 0xc670
jmp 0x1c5e5
leaq 0x4(%rsp), %r12
movl (%r12), %edi
movl $0x104, %esi # imm = 0x104
callq 0xc550
movq %rax, %r15
xorl %r14d, %r14d
xorl %edi, %edi
movq %r12, %rsi
movq %rax, %rdx
callq *0x1fe90(%rbx)
testl %eax, %eax
je 0x1c742
movl %eax, %edi
callq 0x1c800
leaq 0x672bb(%rip), %rsi # 0x839e4
movl $0x10006, %edi # imm = 0x10006
movq %rax, %rdx
xorl %eax, %eax
callq 0x18e91
movq %r15, %rdi
callq 0xca50
jmp 0x1c6d6
movl 0x4(%rsp), %r13d
testq %r13, %r13
je 0x1c7bc
leaq 0x672c1(%rip), %r14 # 0x83a14
leaq 0x672c9(%rip), %r12 # 0x83a23
movq %r15, %rbp
movq %rbp, %rdi
movq %r14, %rsi
callq 0xcb50
testl %eax, %eax
je 0x1c79a
movq %rbp, %rdi
movq %r12, %rsi
callq 0xcb50
testl %eax, %eax
je 0x1c7a6
movq %rbp, %rdi
leaq 0x672b2(%rip), %rsi # 0x83a37
callq 0xcb50
testl %eax, %eax
jne 0x1c7b0
movl $0x1, 0x1fea8(%rbx)
jmp 0x1c7b0
movl $0x1, 0x1fea0(%rbx)
jmp 0x1c7b0
movl $0x1, 0x1fea4(%rbx)
addq $0x104, %rbp # imm = 0x104
decq %r13
jne 0x1c75d
movq %r15, %rdi
callq 0xca50
movl $0x1, 0x1fe70(%rbx)
addq $0x1fe80, %rbx # imm = 0x1FE80
movq %rbx, %rdi
callq 0x25907
movl $0x1, %r14d
jmp 0x1c5e5
| _glfwInitVulkan:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
lea rbx, _glfw
mov r14d, 1
cmp dword ptr [rbx+1FE70h], 0
jz short loc_1C5F7
loc_1C5E5:
mov eax, r14d
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_1C5F7:
mov ebp, edi
lea rdi, aLibvulkanSo1; "libvulkan.so.1"
mov esi, 1
call _dlopen
mov [rbx+1FE78h], rax
test rax, rax
jz short loc_1C690
lea rsi, aVulkanLoaderDo+1Fh; "vkGetInstanceProcAddr"
mov rdi, rax
call _dlsym
mov [rbx+1FE98h], rax
test rax, rax
jz loc_1C6B7
lea rsi, aVulkanFailedTo_0+1Bh; "vkEnumerateInstanceExtensionProperties"
xor r14d, r14d
xor edi, edi
call rax
mov [rbx+1FE90h], rax
test rax, rax
jz short loc_1C6C3
lea rsi, [rsp+38h+var_34]
xor edi, edi
xor edx, edx
call rax
test eax, eax
jz loc_1C6F0
cmp ebp, 2
jnz short loc_1C684
mov edi, eax
call _glfwGetVulkanResultString
lea rsi, aVulkanFailedTo; "Vulkan: Failed to query instance extens"...
mov edi, offset loc_10006
mov rdx, rax
xor eax, eax
call _glfwInputError
loc_1C684:
mov rdi, [rbx+1FE78h]
xor r14d, r14d
jmp short loc_1C6DD
loc_1C690:
xor r14d, r14d
cmp ebp, 2
jnz loc_1C5E5
lea rsi, aVulkanLoaderNo; "Vulkan: Loader not found"
xor r14d, r14d
mov edi, offset loc_10006
xor eax, eax
call _glfwInputError
jmp loc_1C5E5
loc_1C6B7:
lea rsi, aVulkanLoaderDo; "Vulkan: Loader does not export vkGetIns"...
xor r14d, r14d
jmp short loc_1C6CA
loc_1C6C3:
lea rsi, aVulkanFailedTo_0; "Vulkan: Failed to retrieve vkEnumerateI"...
loc_1C6CA:
mov edi, offset loc_10006
xor eax, eax
call _glfwInputError
loc_1C6D6:
mov rdi, [rbx+1FE78h]
loc_1C6DD:
test rdi, rdi
jz loc_1C5E5
call _dlclose
jmp loc_1C5E5
loc_1C6F0:
lea r12, [rsp+38h+var_34]
mov edi, [r12]
mov esi, 104h
call _calloc
mov r15, rax
xor r14d, r14d
xor edi, edi
mov rsi, r12
mov rdx, rax
call qword ptr [rbx+1FE90h]
test eax, eax
jz short loc_1C742
mov edi, eax
call _glfwGetVulkanResultString
lea rsi, aVulkanFailedTo_1; "Vulkan: Failed to query instance extens"...
mov edi, offset loc_10006
mov rdx, rax
xor eax, eax
call _glfwInputError
mov rdi, r15
call _free
jmp short loc_1C6D6
loc_1C742:
mov r13d, [rsp+38h+var_34]
test r13, r13
jz short loc_1C7BC
lea r14, aVkKhrSurface; "VK_KHR_surface"
lea r12, aVkKhrXlibSurfa; "VK_KHR_xlib_surface"
mov rbp, r15
loc_1C75D:
mov rdi, rbp
mov rsi, r14
call _strcmp
test eax, eax
jz short loc_1C79A
mov rdi, rbp
mov rsi, r12
call _strcmp
test eax, eax
jz short loc_1C7A6
mov rdi, rbp
lea rsi, aVkKhrXcbSurfac; "VK_KHR_xcb_surface"
call _strcmp
test eax, eax
jnz short loc_1C7B0
mov dword ptr [rbx+1FEA8h], 1
jmp short loc_1C7B0
loc_1C79A:
mov dword ptr [rbx+1FEA0h], 1
jmp short loc_1C7B0
loc_1C7A6:
mov dword ptr [rbx+1FEA4h], 1
loc_1C7B0:
add rbp, 104h
dec r13
jnz short loc_1C75D
loc_1C7BC:
mov rdi, r15
call _free
mov dword ptr [rbx+1FE70h], 1
add rbx, 1FE80h
mov rdi, rbx
call _glfwPlatformGetRequiredInstanceExtensions
mov r14d, 1
jmp loc_1C5E5
| long long glfwInitVulkan(int a1)
{
long long v1; // rax
unsigned int v2; // r14d
long long v4; // rax
long long ( *v5)(_QWORD, char *); // rax
long long ( *v6)(_QWORD, _DWORD *, _QWORD); // rax
unsigned int v7; // eax
const char *VulkanResultString; // rax
long long v9; // rdi
long long v10; // r15
unsigned int v11; // eax
const char *v12; // rax
long long v13; // r13
long long v14; // rbp
_DWORD v15[13]; // [rsp+0h] [rbp-34h] BYREF
v15[0] = HIDWORD(v1);
v2 = 1;
if ( glfw[32668] )
return v2;
v4 = dlopen("libvulkan.so.1", 1LL);
*(_QWORD *)&glfw[32670] = v4;
if ( !v4 )
{
v2 = 0;
if ( a1 == 2 )
{
v2 = 0;
glfwInputError((unsigned int)&loc_10006, (long long)"Vulkan: Loader not found");
}
return v2;
}
v5 = (long long ( *)(_QWORD, char *))dlsym(v4, "vkGetInstanceProcAddr");
*(_QWORD *)&glfw[32678] = v5;
if ( !v5 )
{
v2 = 0;
glfwInputError((unsigned int)&loc_10006, (long long)"Vulkan: Loader does not export vkGetInstanceProcAddr");
LABEL_14:
v9 = *(_QWORD *)&glfw[32670];
LABEL_15:
if ( v9 )
dlclose(v9);
return v2;
}
v2 = 0;
v6 = (long long ( *)(_QWORD, _DWORD *, _QWORD))v5(0LL, "vkEnumerateInstanceExtensionProperties");
*(_QWORD *)&glfw[32676] = v6;
if ( !v6 )
{
glfwInputError(
(unsigned int)&loc_10006,
(long long)"Vulkan: Failed to retrieve vkEnumerateInstanceExtensionProperties");
goto LABEL_14;
}
v7 = v6(0LL, v15, 0LL);
if ( v7 )
{
if ( a1 == 2 )
{
VulkanResultString = (const char *)glfwGetVulkanResultString(v7);
glfwInputError(
(unsigned int)&loc_10006,
(long long)"Vulkan: Failed to query instance extension count: %s",
VulkanResultString);
}
v9 = *(_QWORD *)&glfw[32670];
v2 = 0;
goto LABEL_15;
}
v10 = calloc(v15[0], 260LL);
v2 = 0;
v11 = (*(long long ( **)(_QWORD, _DWORD *, long long))&glfw[32676])(0LL, v15, v10);
if ( v11 )
{
v12 = (const char *)glfwGetVulkanResultString(v11);
glfwInputError((unsigned int)&loc_10006, (long long)"Vulkan: Failed to query instance extensions: %s", v12);
free(v10);
goto LABEL_14;
}
v13 = v15[0];
if ( v15[0] )
{
v14 = v10;
do
{
if ( !(unsigned int)strcmp(v14, "VK_KHR_surface") )
{
glfw[32680] = 1;
}
else if ( !(unsigned int)strcmp(v14, "VK_KHR_xlib_surface") )
{
glfw[32681] = 1;
}
else if ( !(unsigned int)strcmp(v14, "VK_KHR_xcb_surface") )
{
glfw[32682] = 1;
}
v14 += 260LL;
--v13;
}
while ( v13 );
}
free(v10);
glfw[32668] = 1;
glfwPlatformGetRequiredInstanceExtensions(&glfw[32672]);
return 1;
}
| _glfwInitVulkan:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
LEA RBX,[0x1a8638]
MOV R14D,0x1
CMP dword ptr [RBX + 0x1fe70],0x0
JZ 0x0011c5f7
LAB_0011c5e5:
MOV EAX,R14D
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0011c5f7:
MOV EBP,EDI
LEA RDI,[0x183910]
MOV ESI,0x1
CALL 0x0010cb30
MOV qword ptr [RBX + 0x1fe78],RAX
TEST RAX,RAX
JZ 0x0011c690
LEA RSI,[0x183957]
MOV RDI,RAX
CALL 0x0010c820
MOV qword ptr [RBX + 0x1fe98],RAX
TEST RAX,RAX
JZ 0x0011c6b7
LEA RSI,[0x183988]
XOR R14D,R14D
XOR EDI,EDI
CALL RAX
MOV qword ptr [RBX + 0x1fe90],RAX
TEST RAX,RAX
JZ 0x0011c6c3
LEA RSI,[RSP + 0x4]
XOR EDI,EDI
XOR EDX,EDX
CALL RAX
TEST EAX,EAX
JZ 0x0011c6f0
CMP EBP,0x2
JNZ 0x0011c684
MOV EDI,EAX
CALL 0x0011c800
LEA RSI,[0x1839af]
MOV EDI,0x10006
MOV RDX,RAX
XOR EAX,EAX
CALL 0x00118e91
LAB_0011c684:
MOV RDI,qword ptr [RBX + 0x1fe78]
XOR R14D,R14D
JMP 0x0011c6dd
LAB_0011c690:
XOR R14D,R14D
CMP EBP,0x2
JNZ 0x0011c5e5
LEA RSI,[0x18391f]
XOR R14D,R14D
MOV EDI,0x10006
XOR EAX,EAX
CALL 0x00118e91
JMP 0x0011c5e5
LAB_0011c6b7:
LEA RSI,[0x183938]
XOR R14D,R14D
JMP 0x0011c6ca
LAB_0011c6c3:
LEA RSI,[0x18396d]
LAB_0011c6ca:
MOV EDI,0x10006
XOR EAX,EAX
CALL 0x00118e91
LAB_0011c6d6:
MOV RDI,qword ptr [RBX + 0x1fe78]
LAB_0011c6dd:
TEST RDI,RDI
JZ 0x0011c5e5
CALL 0x0010c670
JMP 0x0011c5e5
LAB_0011c6f0:
LEA R12,[RSP + 0x4]
MOV EDI,dword ptr [R12]
MOV ESI,0x104
CALL 0x0010c550
MOV R15,RAX
XOR R14D,R14D
XOR EDI,EDI
MOV RSI,R12
MOV RDX,RAX
CALL qword ptr [RBX + 0x1fe90]
TEST EAX,EAX
JZ 0x0011c742
MOV EDI,EAX
CALL 0x0011c800
LEA RSI,[0x1839e4]
MOV EDI,0x10006
MOV RDX,RAX
XOR EAX,EAX
CALL 0x00118e91
MOV RDI,R15
CALL 0x0010ca50
JMP 0x0011c6d6
LAB_0011c742:
MOV R13D,dword ptr [RSP + 0x4]
TEST R13,R13
JZ 0x0011c7bc
LEA R14,[0x183a14]
LEA R12,[0x183a23]
MOV RBP,R15
LAB_0011c75d:
MOV RDI,RBP
MOV RSI,R14
CALL 0x0010cb50
TEST EAX,EAX
JZ 0x0011c79a
MOV RDI,RBP
MOV RSI,R12
CALL 0x0010cb50
TEST EAX,EAX
JZ 0x0011c7a6
MOV RDI,RBP
LEA RSI,[0x183a37]
CALL 0x0010cb50
TEST EAX,EAX
JNZ 0x0011c7b0
MOV dword ptr [RBX + 0x1fea8],0x1
JMP 0x0011c7b0
LAB_0011c79a:
MOV dword ptr [RBX + 0x1fea0],0x1
JMP 0x0011c7b0
LAB_0011c7a6:
MOV dword ptr [RBX + 0x1fea4],0x1
LAB_0011c7b0:
ADD RBP,0x104
DEC R13
JNZ 0x0011c75d
LAB_0011c7bc:
MOV RDI,R15
CALL 0x0010ca50
MOV dword ptr [RBX + 0x1fe70],0x1
ADD RBX,0x1fe80
MOV RDI,RBX
CALL 0x00125907
MOV R14D,0x1
JMP 0x0011c5e5
|
int8 _glfwInitVulkan(int param_1)
{
int iVar1;
ulong in_RAX;
int8 uVar2;
char *pcVar3;
char *__s1;
ulong uVar4;
int8 uStack_38;
if (DAT_001c84a8 != 0) {
return 1;
}
uStack_38 = in_RAX;
DAT_001c84b0 = dlopen("libvulkan.so.1",1);
if (DAT_001c84b0 == 0) {
if (param_1 != 2) {
return 0;
}
_glfwInputError(0x10006,"Vulkan: Loader not found");
return 0;
}
DAT_001c84d0 = (code *)dlsym(DAT_001c84b0,"vkGetInstanceProcAddr");
if (DAT_001c84d0 == (code *)0x0) {
pcVar3 = "Vulkan: Loader does not export vkGetInstanceProcAddr";
}
else {
DAT_001c84c8 = (code *)(*DAT_001c84d0)(0,"vkEnumerateInstanceExtensionProperties");
if (DAT_001c84c8 != (code *)0x0) {
iVar1 = (*DAT_001c84c8)(0,(long)&uStack_38 + 4,0);
if (iVar1 == 0) {
pcVar3 = (char *)calloc(uStack_38 >> 0x20,0x104);
iVar1 = (*DAT_001c84c8)(0,(long)&uStack_38 + 4,pcVar3);
if (iVar1 == 0) {
__s1 = pcVar3;
for (uVar4 = (ulong)uStack_38._4_4_; uVar4 != 0; uVar4 = uVar4 - 1) {
iVar1 = strcmp(__s1,"VK_KHR_surface");
if (iVar1 == 0) {
DAT_001c84d8 = 1;
}
else {
iVar1 = strcmp(__s1,"VK_KHR_xlib_surface");
if (iVar1 == 0) {
DAT_001c84dc = 1;
}
else {
iVar1 = strcmp(__s1,"VK_KHR_xcb_surface");
if (iVar1 == 0) {
DAT_001c84e0 = 1;
}
}
}
__s1 = __s1 + 0x104;
}
free(pcVar3);
DAT_001c84a8 = 1;
_glfwPlatformGetRequiredInstanceExtensions(&DAT_001c84b8);
return 1;
}
uVar2 = _glfwGetVulkanResultString(iVar1);
_glfwInputError(0x10006,"Vulkan: Failed to query instance extensions: %s",uVar2);
free(pcVar3);
}
else if (param_1 == 2) {
uVar2 = _glfwGetVulkanResultString(iVar1);
_glfwInputError(0x10006,"Vulkan: Failed to query instance extension count: %s",uVar2);
}
goto LAB_0011c6dd;
}
pcVar3 = "Vulkan: Failed to retrieve vkEnumerateInstanceExtensionProperties";
}
_glfwInputError(0x10006,pcVar3);
LAB_0011c6dd:
if (DAT_001c84b0 != 0) {
dlclose();
}
return 0;
}
| |
23,339 | mariadb_field_attr | eloqsql/libmariadb/libmariadb/mariadb_lib.c | int STDCALL
mariadb_field_attr(MARIADB_CONST_STRING *attr,
const MYSQL_FIELD *field,
enum mariadb_field_attr_t type)
{
MA_FIELD_EXTENSION *ext= (MA_FIELD_EXTENSION*) field->extension;
if (!ext || type > MARIADB_FIELD_ATTR_LAST)
{
*attr= null_const_string;
return 1;
}
*attr= ext->metadata[type];
return 0;
} | O0 | c | mariadb_field_attr:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x18(%rbp), %rax
movq 0x78(%rax), %rax
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0x517a8
cmpl $0x1, -0x1c(%rbp)
jbe 0x517ca
movq -0x10(%rbp), %rax
movq 0x3b12f5(%rip), %rcx # 0x402aa8
movq %rcx, (%rax)
movq 0x3b12f3(%rip), %rcx # 0x402ab0
movq %rcx, 0x8(%rax)
movl $0x1, -0x4(%rbp)
jmp 0x517f1
movq -0x10(%rbp), %rax
movq -0x28(%rbp), %rcx
movl -0x1c(%rbp), %edx
shlq $0x4, %rdx
addq %rdx, %rcx
movq (%rcx), %rdx
movq %rdx, (%rax)
movq 0x8(%rcx), %rcx
movq %rcx, 0x8(%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopw %cs:(%rax,%rax)
| mariadb_field_attr:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_1C], edx
mov rax, [rbp+var_18]
mov rax, [rax+78h]
mov [rbp+var_28], rax
cmp [rbp+var_28], 0
jz short loc_517A8
cmp [rbp+var_1C], 1
jbe short loc_517CA
loc_517A8:
mov rax, [rbp+var_10]
mov rcx, cs:null_const_string
mov [rax], rcx
mov rcx, cs:qword_402AB0
mov [rax+8], rcx
mov [rbp+var_4], 1
jmp short loc_517F1
loc_517CA:
mov rax, [rbp+var_10]
mov rcx, [rbp+var_28]
mov edx, [rbp+var_1C]
shl rdx, 4
add rcx, rdx
mov rdx, [rcx]
mov [rax], rdx
mov rcx, [rcx+8]
mov [rax+8], rcx
mov [rbp+var_4], 0
loc_517F1:
mov eax, [rbp+var_4]
pop rbp
retn
| long long mariadb_field_attr(_QWORD *a1, long long a2, unsigned int a3)
{
long long v3; // rdx
long long v5; // [rsp+0h] [rbp-28h]
v5 = *(_QWORD *)(a2 + 120);
if ( v5 && a3 <= 1 )
{
v3 = 16LL * a3;
*a1 = *(_QWORD *)(v3 + v5);
a1[1] = *(_QWORD *)(v3 + v5 + 8);
return 0;
}
else
{
*a1 = null_const_string;
a1[1] = qword_402AB0;
return 1;
}
}
| mariadb_field_attr:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV dword ptr [RBP + -0x1c],EDX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x78]
MOV qword ptr [RBP + -0x28],RAX
CMP qword ptr [RBP + -0x28],0x0
JZ 0x001517a8
CMP dword ptr [RBP + -0x1c],0x1
JBE 0x001517ca
LAB_001517a8:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [0x00502aa8]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [0x00502ab0]
MOV qword ptr [RAX + 0x8],RCX
MOV dword ptr [RBP + -0x4],0x1
JMP 0x001517f1
LAB_001517ca:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x28]
MOV EDX,dword ptr [RBP + -0x1c]
SHL RDX,0x4
ADD RCX,RDX
MOV RDX,qword ptr [RCX]
MOV qword ptr [RAX],RDX
MOV RCX,qword ptr [RCX + 0x8]
MOV qword ptr [RAX + 0x8],RCX
MOV dword ptr [RBP + -0x4],0x0
LAB_001517f1:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int4 mariadb_field_attr(int8 *param_1,long param_2,uint param_3)
{
int8 *puVar1;
int4 local_c;
if ((*(long *)(param_2 + 0x78) == 0) || (1 < param_3)) {
*param_1 = null_const_string;
param_1[1] = DAT_00502ab0;
local_c = 1;
}
else {
puVar1 = (int8 *)(*(long *)(param_2 + 0x78) + (ulong)param_3 * 0x10);
*param_1 = *puVar1;
param_1[1] = puVar1[1];
local_c = 0;
}
return local_c;
}
| |
23,340 | my_fill_utf8mb3_mb | eloqsql/strings/ctype-utf8.c | static void
my_fill_utf8mb3_mb(CHARSET_INFO *cs, char *str, size_t length, int fill)
{
char *end= str + length;
char buf[10];
char buflen= my_ci_native_to_mb(cs, (my_wc_t) fill, (uchar*) buf,
(uchar*) buf + sizeof(buf));
DBUG_ASSERT(buflen > 0);
for ( ; str + buflen <= end ; )
{
memcpy(str, buf, buflen);
str+= buflen;
}
for ( ; str < end; )
*str++= ' ';
} | O0 | c | my_fill_utf8mb3_mb:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x20(%rbp)
movq %rsi, -0x28(%rbp)
movq %rdx, -0x30(%rbp)
movl %ecx, -0x34(%rbp)
movq -0x28(%rbp), %rax
addq -0x30(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x20(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0xd8(%rax), %rax
movq -0x20(%rbp), %rdi
movslq -0x34(%rbp), %rsi
leaq -0x12(%rbp), %rdx
leaq -0x12(%rbp), %rcx
addq $0xa, %rcx
callq *%rax
movb %al, -0x41(%rbp)
jmp 0x9d09d
jmp 0x9d09f
movq -0x28(%rbp), %rax
movsbl -0x41(%rbp), %ecx
movslq %ecx, %rcx
addq %rcx, %rax
cmpq -0x40(%rbp), %rax
ja 0x9d0d9
movq -0x28(%rbp), %rdi
leaq -0x12(%rbp), %rsi
movsbq -0x41(%rbp), %rdx
callq 0x26280
movsbl -0x41(%rbp), %ecx
movq -0x28(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
jmp 0x9d09f
jmp 0x9d0db
movq -0x28(%rbp), %rax
cmpq -0x40(%rbp), %rax
jae 0x9d0f9
movq -0x28(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x28(%rbp)
movb $0x20, (%rax)
jmp 0x9d0db
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x9d111
addq $0x50, %rsp
popq %rbp
retq
callq 0x26370
nopw %cs:(%rax,%rax)
| my_fill_utf8mb3_mb:
push rbp
mov rbp, rsp
sub rsp, 50h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_20], rdi
mov [rbp+var_28], rsi
mov [rbp+var_30], rdx
mov [rbp+var_34], ecx
mov rax, [rbp+var_28]
add rax, [rbp+var_30]
mov [rbp+var_40], rax
mov rax, [rbp+var_20]
mov rax, [rax+0B8h]
mov rax, [rax+0D8h]
mov rdi, [rbp+var_20]
movsxd rsi, [rbp+var_34]
lea rdx, [rbp+var_12]
lea rcx, [rbp+var_12]
add rcx, 0Ah
call rax
mov [rbp+var_41], al
jmp short $+2
loc_9D09D:
jmp short $+2
loc_9D09F:
mov rax, [rbp+var_28]
movsx ecx, [rbp+var_41]
movsxd rcx, ecx
add rax, rcx
cmp rax, [rbp+var_40]
ja short loc_9D0D9
mov rdi, [rbp+var_28]
lea rsi, [rbp+var_12]
movsx rdx, [rbp+var_41]
call _memcpy
movsx ecx, [rbp+var_41]
mov rax, [rbp+var_28]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_28], rax
jmp short loc_9D09F
loc_9D0D9:
jmp short $+2
loc_9D0DB:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_40]
jnb short loc_9D0F9
mov rax, [rbp+var_28]
mov rcx, rax
add rcx, 1
mov [rbp+var_28], rcx
mov byte ptr [rax], 20h ; ' '
jmp short loc_9D0DB
loc_9D0F9:
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_9D111
add rsp, 50h
pop rbp
retn
loc_9D111:
call ___stack_chk_fail
| unsigned long long my_fill_utf8mb3_mb(long long a1, _BYTE *a2, long long a3, int a4)
{
_BYTE *v4; // rax
char i; // [rsp+Fh] [rbp-41h]
unsigned long long v7; // [rsp+10h] [rbp-40h]
_BYTE *v8; // [rsp+28h] [rbp-28h]
_BYTE v9[10]; // [rsp+3Eh] [rbp-12h] BYREF
unsigned long long v10; // [rsp+48h] [rbp-8h] BYREF
v10 = __readfsqword(0x28u);
v8 = a2;
v7 = (unsigned long long)&a2[a3];
for ( i = (*(long long ( **)(long long, _QWORD, _BYTE *, unsigned long long *))(*(_QWORD *)(a1 + 184) + 216LL))(
a1,
a4,
v9,
&v10); (unsigned long long)&v8[i] <= v7; v8 += i )
memcpy(v8, v9, i);
while ( (unsigned long long)v8 < v7 )
{
v4 = v8++;
*v4 = 32;
}
return __readfsqword(0x28u);
}
| my_fill_utf8mb3_mb:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x20],RDI
MOV qword ptr [RBP + -0x28],RSI
MOV qword ptr [RBP + -0x30],RDX
MOV dword ptr [RBP + -0x34],ECX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0xd8]
MOV RDI,qword ptr [RBP + -0x20]
MOVSXD RSI,dword ptr [RBP + -0x34]
LEA RDX,[RBP + -0x12]
LEA RCX,[RBP + -0x12]
ADD RCX,0xa
CALL RAX
MOV byte ptr [RBP + -0x41],AL
JMP 0x0019d09d
LAB_0019d09d:
JMP 0x0019d09f
LAB_0019d09f:
MOV RAX,qword ptr [RBP + -0x28]
MOVSX ECX,byte ptr [RBP + -0x41]
MOVSXD RCX,ECX
ADD RAX,RCX
CMP RAX,qword ptr [RBP + -0x40]
JA 0x0019d0d9
MOV RDI,qword ptr [RBP + -0x28]
LEA RSI,[RBP + -0x12]
MOVSX RDX,byte ptr [RBP + -0x41]
CALL 0x00126280
MOVSX ECX,byte ptr [RBP + -0x41]
MOV RAX,qword ptr [RBP + -0x28]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x28],RAX
JMP 0x0019d09f
LAB_0019d0d9:
JMP 0x0019d0db
LAB_0019d0db:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x40]
JNC 0x0019d0f9
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,RAX
ADD RCX,0x1
MOV qword ptr [RBP + -0x28],RCX
MOV byte ptr [RAX],0x20
JMP 0x0019d0db
LAB_0019d0f9:
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x0019d111
ADD RSP,0x50
POP RBP
RET
LAB_0019d111:
CALL 0x00126370
|
void my_fill_utf8mb3_mb(long param_1,int1 *param_2,long param_3,int param_4)
{
char cVar1;
long in_FS_OFFSET;
int1 *local_30;
int1 local_1a [10];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
cVar1 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xd8))(param_1,(long)param_4,local_1a,&local_10);
for (local_30 = param_2; local_30 + (int)cVar1 <= param_2 + param_3;
local_30 = local_30 + (int)cVar1) {
memcpy(local_30,local_1a,(long)cVar1);
}
while (local_30 < param_2 + param_3) {
*local_30 = 0x20;
local_30 = local_30 + 1;
}
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return;
}
| |
23,341 | google::protobuf::Reflection::GetRepeatedMessage(google::protobuf::Message const&, google::protobuf::FieldDescriptor const*, int) const | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/generated_message_reflection.cc | const Message& Reflection::GetRepeatedMessage(const Message& message,
const FieldDescriptor* field,
int index) const {
USAGE_CHECK_ALL(GetRepeatedMessage, REPEATED, MESSAGE);
CheckInvalidAccess(schema_, field);
if (field->is_extension()) {
return static_cast<const Message&>(
GetExtensionSet(message).GetRepeatedMessage(field->number(), index));
} else {
if (IsMapFieldInApi(field)) {
return GetRaw<MapFieldBase>(message, field)
.GetRepeatedField()
.Get<GenericTypeHandler<Message> >(index);
} else {
return GetRaw<RepeatedPtrFieldBase>(message, field)
.Get<GenericTypeHandler<Message> >(index);
}
}
} | O0 | cpp | google::protobuf::Reflection::GetRepeatedMessage(google::protobuf::Message const&, google::protobuf::FieldDescriptor const*, int) const:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq %rdx, 0x18(%rsp)
movl %ecx, 0x14(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
callq 0x586b0
movq 0x8(%rsp), %rcx
cmpq (%rcx), %rax
je 0x311705
movq 0x8(%rsp), %rax
movq (%rax), %rdi
movq 0x18(%rsp), %rsi
leaq 0xf3b31(%rip), %rdx # 0x40522a
leaq 0xf36af(%rip), %rcx # 0x404daf
callq 0x30abc0
movq 0x18(%rsp), %rdi
callq 0x3cbf0
cmpl $0x3, %eax
je 0x311734
movq 0x8(%rsp), %rax
movq (%rax), %rdi
movq 0x18(%rsp), %rsi
leaq 0xf3b02(%rip), %rdx # 0x40522a
leaq 0xf3743(%rip), %rcx # 0x404e72
callq 0x30abc0
movq 0x18(%rsp), %rdi
callq 0x58090
cmpl $0xa, %eax
je 0x311761
movq 0x8(%rsp), %rax
movq (%rax), %rdi
movq 0x18(%rsp), %rsi
leaq 0xf3ad3(%rip), %rdx # 0x40522a
movl $0xa, %ecx
callq 0x30b630
movq 0x8(%rsp), %rdi
addq $0x8, %rdi
movq 0x18(%rsp), %rsi
callq 0x30ad30
movq 0x18(%rsp), %rdi
callq 0x58070
testb $0x1, %al
jne 0x311784
jmp 0x3117b7
movq 0x8(%rsp), %rdi
movq 0x20(%rsp), %rsi
callq 0x308040
movq %rax, (%rsp)
movq 0x18(%rsp), %rdi
callq 0x3d8e0
movq (%rsp), %rdi
movl %eax, %esi
movl 0x14(%rsp), %edx
callq 0x3936d0
movq %rax, 0x30(%rsp)
jmp 0x31181b
movq 0x18(%rsp), %rdi
callq 0x3086a0
testb $0x1, %al
jne 0x3117c7
jmp 0x3117f6
movq 0x8(%rsp), %rdi
movq 0x20(%rsp), %rsi
movq 0x18(%rsp), %rdx
callq 0x3177a0
movq %rax, %rdi
callq 0x32bd70
movq %rax, %rdi
movl 0x14(%rsp), %esi
callq 0x31c4b0
movq %rax, 0x30(%rsp)
jmp 0x31181b
movq 0x8(%rsp), %rdi
movq 0x20(%rsp), %rsi
movq 0x18(%rsp), %rdx
callq 0x317920
movq %rax, %rdi
movl 0x14(%rsp), %esi
callq 0x31c4b0
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
| _ZNK6google8protobuf10Reflection18GetRepeatedMessageERKNS0_7MessageEPKNS0_15FieldDescriptorEi:
sub rsp, 38h
mov [rsp+38h+var_10], rdi
mov [rsp+38h+var_18], rsi
mov [rsp+38h+var_20], rdx
mov [rsp+38h+var_24], ecx
mov rax, [rsp+38h+var_10]
mov [rsp+38h+var_30], rax
mov rdi, [rsp+38h+var_20]; this
call _ZNK6google8protobuf15FieldDescriptor15containing_typeEv; google::protobuf::FieldDescriptor::containing_type(void)
mov rcx, [rsp+38h+var_30]
cmp rax, [rcx]
jz short loc_311705
mov rax, [rsp+38h+var_30]
mov rdi, [rax]; this
mov rsi, [rsp+38h+var_20]; google::protobuf::Descriptor *
lea rdx, aGetrepeatedmes; "GetRepeatedMessage"
lea rcx, aFieldDoesNotMa; "Field does not match message type."
call _ZN6google8protobuf12_GLOBAL__N_126ReportReflectionUsageErrorEPKNS0_10DescriptorEPKNS0_15FieldDescriptorEPKcS9_; google::protobuf::`anonymous namespace'::ReportReflectionUsageError(google::protobuf::Descriptor const*,google::protobuf::FieldDescriptor const*,char const*,char const*)
loc_311705:
mov rdi, [rsp+38h+var_20]; this
call _ZNK6google8protobuf15FieldDescriptor5labelEv; google::protobuf::FieldDescriptor::label(void)
cmp eax, 3
jz short loc_311734
mov rax, [rsp+38h+var_30]
mov rdi, [rax]; this
mov rsi, [rsp+38h+var_20]; google::protobuf::Descriptor *
lea rdx, aGetrepeatedmes; "GetRepeatedMessage"
lea rcx, aFieldIsSingula; "Field is singular; the method requires "...
call _ZN6google8protobuf12_GLOBAL__N_126ReportReflectionUsageErrorEPKNS0_10DescriptorEPKNS0_15FieldDescriptorEPKcS9_; google::protobuf::`anonymous namespace'::ReportReflectionUsageError(google::protobuf::Descriptor const*,google::protobuf::FieldDescriptor const*,char const*,char const*)
loc_311734:
mov rdi, [rsp+38h+var_20]; this
call _ZNK6google8protobuf15FieldDescriptor8cpp_typeEv; google::protobuf::FieldDescriptor::cpp_type(void)
cmp eax, 0Ah
jz short loc_311761
mov rax, [rsp+38h+var_30]
mov rdi, [rax]
mov rsi, [rsp+38h+var_20]
lea rdx, aGetrepeatedmes; "GetRepeatedMessage"
mov ecx, 0Ah
call _ZN6google8protobuf12_GLOBAL__N_130ReportReflectionUsageTypeErrorEPKNS0_10DescriptorEPKNS0_15FieldDescriptorEPKcNS5_7CppTypeE; google::protobuf::`anonymous namespace'::ReportReflectionUsageTypeError(google::protobuf::Descriptor const*,google::protobuf::FieldDescriptor const*,char const*,google::protobuf::FieldDescriptor::CppType)
loc_311761:
mov rdi, [rsp+38h+var_30]
add rdi, 8; this
mov rsi, [rsp+38h+var_20]; google::protobuf::FieldDescriptor *
call _ZN6google8protobuf12_GLOBAL__N_118CheckInvalidAccessERKNS0_8internal16ReflectionSchemaEPKNS0_15FieldDescriptorE; google::protobuf::`anonymous namespace'::CheckInvalidAccess(google::protobuf::internal::ReflectionSchema const&,google::protobuf::FieldDescriptor const*)
mov rdi, [rsp+38h+var_20]; this
call _ZNK6google8protobuf15FieldDescriptor12is_extensionEv; google::protobuf::FieldDescriptor::is_extension(void)
test al, 1
jnz short loc_311784
jmp short loc_3117B7
loc_311784:
mov rdi, [rsp+38h+var_30]; this
mov rsi, [rsp+38h+var_18]; google::protobuf::Message *
call _ZNK6google8protobuf10Reflection15GetExtensionSetERKNS0_7MessageE; google::protobuf::Reflection::GetExtensionSet(google::protobuf::Message const&)
mov [rsp+38h+var_38], rax
mov rdi, [rsp+38h+var_20]; this
call _ZNK6google8protobuf15FieldDescriptor6numberEv; google::protobuf::FieldDescriptor::number(void)
mov rdi, [rsp+38h+var_38]; this
mov esi, eax; int
mov edx, [rsp+38h+var_24]; int
call _ZNK6google8protobuf8internal12ExtensionSet18GetRepeatedMessageEii; google::protobuf::internal::ExtensionSet::GetRepeatedMessage(int,int)
mov [rsp+38h+var_8], rax
jmp short loc_31181B
loc_3117B7:
mov rdi, [rsp+38h+var_20]; this
call _ZN6google8protobuf12_GLOBAL__N_115IsMapFieldInApiEPKNS0_15FieldDescriptorE_0; google::protobuf::`anonymous namespace'::IsMapFieldInApi(google::protobuf::FieldDescriptor const*)
test al, 1
jnz short loc_3117C7
jmp short loc_3117F6
loc_3117C7:
mov rdi, [rsp+38h+var_30]
mov rsi, [rsp+38h+var_18]
mov rdx, [rsp+38h+var_20]
call _ZNK6google8protobuf10Reflection6GetRawINS0_8internal12MapFieldBaseEEERKT_RKNS0_7MessageEPKNS0_15FieldDescriptorE; google::protobuf::Reflection::GetRaw<google::protobuf::internal::MapFieldBase>(google::protobuf::Message const&,google::protobuf::FieldDescriptor const*)
mov rdi, rax; this
call _ZNK6google8protobuf8internal12MapFieldBase16GetRepeatedFieldEv; google::protobuf::internal::MapFieldBase::GetRepeatedField(void)
mov rdi, rax
mov esi, [rsp+38h+var_24]
call _ZNK6google8protobuf8internal20RepeatedPtrFieldBase3GetINS1_18GenericTypeHandlerINS0_7MessageEEEEERKNT_4TypeEi; google::protobuf::internal::RepeatedPtrFieldBase::Get<google::protobuf::internal::GenericTypeHandler<google::protobuf::Message>>(int)
mov [rsp+38h+var_8], rax
jmp short loc_31181B
loc_3117F6:
mov rdi, [rsp+38h+var_30]
mov rsi, [rsp+38h+var_18]
mov rdx, [rsp+38h+var_20]
call _ZNK6google8protobuf10Reflection6GetRawINS0_8internal20RepeatedPtrFieldBaseEEERKT_RKNS0_7MessageEPKNS0_15FieldDescriptorE; google::protobuf::Reflection::GetRaw<google::protobuf::internal::RepeatedPtrFieldBase>(google::protobuf::Message const&,google::protobuf::FieldDescriptor const*)
mov rdi, rax
mov esi, [rsp+38h+var_24]
call _ZNK6google8protobuf8internal20RepeatedPtrFieldBase3GetINS1_18GenericTypeHandlerINS0_7MessageEEEEERKNT_4TypeEi; google::protobuf::internal::RepeatedPtrFieldBase::Get<google::protobuf::internal::GenericTypeHandler<google::protobuf::Message>>(int)
mov [rsp+38h+var_8], rax
loc_31181B:
mov rax, [rsp+38h+var_8]
add rsp, 38h
retn
| RepeatedPtrField:
SUB RSP,0x18
MOV qword ptr [RSP + 0x10],RDI
MOV qword ptr [RSP + 0x8],RSI
MOV RDI,qword ptr [RSP + 0x10]
MOV RSI,qword ptr [RSP + 0x8]
CALL 0x001b1650
ADD RSP,0x18
RET
|
/* google::protobuf::RepeatedPtrField<std::__cxx11::string
>::RepeatedPtrField(google::protobuf::Arena*) */
void __thiscall
google::protobuf::RepeatedPtrField<std::__cxx11::string>::RepeatedPtrField
(RepeatedPtrField<std::__cxx11::string> *this,Arena *param_1)
{
internal::RepeatedPtrFieldBase::RepeatedPtrFieldBase((RepeatedPtrFieldBase *)this,param_1);
return;
}
| ||
23,342 | mysql_stat | eloqsql/libmariadb/libmariadb/mariadb_lib.c | char * STDCALL
mysql_stat(MYSQL *mysql)
{
if (ma_simple_command(mysql, COM_STATISTICS,0,0,0,0))
return mysql->net.last_error;
mysql->net.read_pos[mysql->packet_length]=0; /* End of stat string */
if (!mysql->net.read_pos[0])
{
SET_CLIENT_ERROR(mysql, CR_WRONG_HOST_INFO , SQLSTATE_UNKNOWN, 0);
return mysql->net.last_error;
}
return((char*) mysql->net.read_pos);
} | O0 | c | mysql_stat:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movl $0x9, %esi
xorl %eax, %eax
movl %eax, %r9d
xorl %r8d, %r8d
movq %r9, %rdx
movq %r9, %rcx
callq 0x31620
cmpl $0x0, %eax
je 0x3ae70
movq -0x10(%rbp), %rax
addq $0x97, %rax
movq %rax, -0x8(%rbp)
jmp 0x3af15
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x358(%rcx), %rcx
movb $0x0, (%rax,%rcx)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
cmpb $0x0, (%rax)
jne 0x3af09
jmp 0x3ae96
movq -0x10(%rbp), %rax
movl $0x7d9, 0x90(%rax) # imm = 0x7D9
movq -0x10(%rbp), %rdi
addq $0x297, %rdi # imm = 0x297
leaq 0x45fea(%rip), %rax # 0x80ea0
movq (%rax), %rsi
movl $0x5, %edx
callq 0x14220
movq -0x10(%rbp), %rax
movb $0x0, 0x29c(%rax)
movq -0x10(%rbp), %rdi
addq $0x97, %rdi
leaq 0x45fd0(%rip), %rax # 0x80eb0
movq 0x48(%rax), %rsi
movl $0x1ff, %edx # imm = 0x1FF
callq 0x14220
movq -0x10(%rbp), %rax
movb $0x0, 0x296(%rax)
movq -0x10(%rbp), %rax
addq $0x97, %rax
movq %rax, -0x8(%rbp)
jmp 0x3af15
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nop
| mysql_stat:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_10], rdi
mov rdi, [rbp+var_10]
mov esi, 9
xor eax, eax
mov r9d, eax
xor r8d, r8d
mov rdx, r9
mov rcx, r9
call ma_simple_command
cmp eax, 0
jz short loc_3AE70
mov rax, [rbp+var_10]
add rax, 97h
mov [rbp+var_8], rax
jmp loc_3AF15
loc_3AE70:
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov rcx, [rbp+var_10]
mov rcx, [rcx+358h]
mov byte ptr [rax+rcx], 0
mov rax, [rbp+var_10]
mov rax, [rax+20h]
cmp byte ptr [rax], 0
jnz short loc_3AF09
jmp short $+2
loc_3AE96:
mov rax, [rbp+var_10]
mov dword ptr [rax+90h], 7D9h
mov rdi, [rbp+var_10]
add rdi, 297h
lea rax, SQLSTATE_UNKNOWN
mov rsi, [rax]
mov edx, 5
call _strncpy
mov rax, [rbp+var_10]
mov byte ptr [rax+29Ch], 0
mov rdi, [rbp+var_10]
add rdi, 97h
lea rax, client_errors
mov rsi, [rax+48h]
mov edx, 1FFh
call _strncpy
mov rax, [rbp+var_10]
mov byte ptr [rax+296h], 0
mov rax, [rbp+var_10]
add rax, 97h
mov [rbp+var_8], rax
jmp short loc_3AF15
loc_3AF09:
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov [rbp+var_8], rax
loc_3AF15:
mov rax, [rbp+var_8]
add rsp, 10h
pop rbp
retn
| long long mysql_stat(long long a1)
{
if ( (unsigned int)ma_simple_command(a1, 9u, 0LL, 0LL, 0, 0LL) )
return a1 + 151;
*(_BYTE *)(*(_QWORD *)(a1 + 32) + *(_QWORD *)(a1 + 856)) = 0;
if ( **(_BYTE **)(a1 + 32) )
return *(_QWORD *)(a1 + 32);
*(_DWORD *)(a1 + 144) = 2009;
strncpy(a1 + 663, SQLSTATE_UNKNOWN, 5LL);
*(_BYTE *)(a1 + 668) = 0;
strncpy(a1 + 151, client_errors[9], 511LL);
*(_BYTE *)(a1 + 662) = 0;
return a1 + 151;
}
| mysql_stat:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x10],RDI
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,0x9
XOR EAX,EAX
MOV R9D,EAX
XOR R8D,R8D
MOV RDX,R9
MOV RCX,R9
CALL 0x00131620
CMP EAX,0x0
JZ 0x0013ae70
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x97
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0013af15
LAB_0013ae70:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x358]
MOV byte ptr [RAX + RCX*0x1],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
CMP byte ptr [RAX],0x0
JNZ 0x0013af09
JMP 0x0013ae96
LAB_0013ae96:
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x90],0x7d9
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x297
LEA RAX,[0x180ea0]
MOV RSI,qword ptr [RAX]
MOV EDX,0x5
CALL 0x00114220
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x29c],0x0
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x97
LEA RAX,[0x180eb0]
MOV RSI,qword ptr [RAX + 0x48]
MOV EDX,0x1ff
CALL 0x00114220
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x296],0x0
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x97
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0013af15
LAB_0013af09:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV qword ptr [RBP + -0x8],RAX
LAB_0013af15:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x10
POP RBP
RET
|
long mysql_stat(long param_1)
{
int iVar1;
int8 local_10;
iVar1 = ma_simple_command(param_1,9,0,0,0);
if (iVar1 == 0) {
*(int1 *)(*(long *)(param_1 + 0x20) + *(long *)(param_1 + 0x358)) = 0;
if (**(char **)(param_1 + 0x20) == '\0') {
*(int4 *)(param_1 + 0x90) = 0x7d9;
strncpy((char *)(param_1 + 0x297),SQLSTATE_UNKNOWN,5);
*(int1 *)(param_1 + 0x29c) = 0;
strncpy((char *)(param_1 + 0x97),PTR_s_Wrong_host_info_00180ef8,0x1ff);
*(int1 *)(param_1 + 0x296) = 0;
local_10 = param_1 + 0x97;
}
else {
local_10 = *(long *)(param_1 + 0x20);
}
}
else {
local_10 = param_1 + 0x97;
}
return local_10;
}
| |
23,343 | my_uca_copy_page | eloqsql/strings/ctype-uca.c | static my_bool
my_uca_copy_page(MY_CHARSET_LOADER *loader,
const MY_UCA_WEIGHT_LEVEL *src,
MY_UCA_WEIGHT_LEVEL *dst,
size_t page)
{
uint chc, size= 256 * dst->lengths[page] * sizeof(uint16);
if (!(dst->weights[page]= (uint16 *) (loader->once_alloc)(size)))
return TRUE;
DBUG_ASSERT(src->lengths[page] <= dst->lengths[page]);
memset(dst->weights[page], 0, size);
for (chc=0 ; chc < 256; chc++)
{
memcpy(dst->weights[page] + chc * dst->lengths[page],
src->weights[page] + chc * src->lengths[page],
src->lengths[page] * sizeof(uint16));
}
return FALSE;
} | O0 | c | my_uca_copy_page:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x28(%rbp), %rcx
movzbl (%rax,%rcx), %eax
shll $0x8, %eax
cltq
shlq %rax
movl %eax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movq 0x80(%rax), %rax
movl -0x30(%rbp), %ecx
movl %ecx, %edi
callq *%rax
movq -0x20(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq -0x28(%rbp), %rdx
movq %rax, (%rcx,%rdx,8)
cmpq $0x0, %rax
jne 0xa18d4
movb $0x1, -0x1(%rbp)
jmp 0xa1990
jmp 0xa18d6
jmp 0xa18d8
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
movl -0x30(%rbp), %eax
movl %eax, %edx
xorl %esi, %esi
callq 0x362e0
movl $0x0, -0x2c(%rbp)
cmpl $0x100, -0x2c(%rbp) # imm = 0x100
jae 0xa198c
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
movl -0x2c(%rbp), %eax
movq -0x20(%rbp), %rcx
movq 0x8(%rcx), %rcx
movq -0x28(%rbp), %rdx
movzbl (%rcx,%rdx), %ecx
imull %ecx, %eax
movl %eax, %eax
shlq %rax
addq %rax, %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rsi
movl -0x2c(%rbp), %eax
movq -0x18(%rbp), %rcx
movq 0x8(%rcx), %rcx
movq -0x28(%rbp), %rdx
movzbl (%rcx,%rdx), %ecx
imull %ecx, %eax
movl %eax, %eax
shlq %rax
addq %rax, %rsi
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x28(%rbp), %rcx
movzbl (%rax,%rcx), %eax
movl %eax, %edx
shlq %rdx
callq 0x360b0
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0xa18fb
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
| my_uca_copy_page:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_20]
mov rax, [rax+8]
mov rcx, [rbp+var_28]
movzx eax, byte ptr [rax+rcx]
shl eax, 8
cdqe
shl rax, 1
mov [rbp+var_30], eax
mov rax, [rbp+var_10]
mov rax, [rax+80h]
mov ecx, [rbp+var_30]
mov edi, ecx
call rax
mov rcx, [rbp+var_20]
mov rcx, [rcx+10h]
mov rdx, [rbp+var_28]
mov [rcx+rdx*8], rax
cmp rax, 0
jnz short loc_A18D4
mov [rbp+var_1], 1
jmp loc_A1990
loc_A18D4:
jmp short $+2
loc_A18D6:
jmp short $+2
loc_A18D8:
mov rax, [rbp+var_20]
mov rax, [rax+10h]
mov rcx, [rbp+var_28]
mov rdi, [rax+rcx*8]
mov eax, [rbp+var_30]
mov edx, eax
xor esi, esi
call _memset
mov [rbp+var_2C], 0
loc_A18FB:
cmp [rbp+var_2C], 100h
jnb loc_A198C
mov rax, [rbp+var_20]
mov rax, [rax+10h]
mov rcx, [rbp+var_28]
mov rdi, [rax+rcx*8]
mov eax, [rbp+var_2C]
mov rcx, [rbp+var_20]
mov rcx, [rcx+8]
mov rdx, [rbp+var_28]
movzx ecx, byte ptr [rcx+rdx]
imul eax, ecx
mov eax, eax
shl rax, 1
add rdi, rax
mov rax, [rbp+var_18]
mov rax, [rax+10h]
mov rcx, [rbp+var_28]
mov rsi, [rax+rcx*8]
mov eax, [rbp+var_2C]
mov rcx, [rbp+var_18]
mov rcx, [rcx+8]
mov rdx, [rbp+var_28]
movzx ecx, byte ptr [rcx+rdx]
imul eax, ecx
mov eax, eax
shl rax, 1
add rsi, rax
mov rax, [rbp+var_18]
mov rax, [rax+8]
mov rcx, [rbp+var_28]
movzx eax, byte ptr [rax+rcx]
mov edx, eax
shl rdx, 1
call _memcpy
mov eax, [rbp+var_2C]
add eax, 1
mov [rbp+var_2C], eax
jmp loc_A18FB
loc_A198C:
mov [rbp+var_1], 0
loc_A1990:
mov al, [rbp+var_1]
add rsp, 30h
pop rbp
retn
| char my_uca_copy_page(long long a1, long long a2, long long a3, long long a4)
{
long long v4; // rax
unsigned int v6; // [rsp+0h] [rbp-30h]
unsigned int i; // [rsp+4h] [rbp-2Ch]
v6 = *(unsigned __int8 *)(*(_QWORD *)(a3 + 8) + a4) << 9;
v4 = (*(long long ( **)(_QWORD))(a1 + 128))(v6);
*(_QWORD *)(*(_QWORD *)(a3 + 16) + 8 * a4) = v4;
if ( !v4 )
return 1;
memset(*(_QWORD *)(*(_QWORD *)(a3 + 16) + 8 * a4), 0LL, v6);
for ( i = 0; i < 0x100; ++i )
memcpy(
2LL * *(unsigned __int8 *)(*(_QWORD *)(a3 + 8) + a4) * i + *(_QWORD *)(*(_QWORD *)(a3 + 16) + 8 * a4),
2LL * *(unsigned __int8 *)(*(_QWORD *)(a2 + 8) + a4) * i + *(_QWORD *)(*(_QWORD *)(a2 + 16) + 8 * a4),
2LL * *(unsigned __int8 *)(*(_QWORD *)(a2 + 8) + a4));
return 0;
}
| my_uca_copy_page:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
SHL EAX,0x8
CDQE
SHL RAX,0x1
MOV dword ptr [RBP + -0x30],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x80]
MOV ECX,dword ptr [RBP + -0x30]
MOV EDI,ECX
CALL RAX
MOV RCX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RCX + 0x10]
MOV RDX,qword ptr [RBP + -0x28]
MOV qword ptr [RCX + RDX*0x8],RAX
CMP RAX,0x0
JNZ 0x001a18d4
MOV byte ptr [RBP + -0x1],0x1
JMP 0x001a1990
LAB_001a18d4:
JMP 0x001a18d6
LAB_001a18d6:
JMP 0x001a18d8
LAB_001a18d8:
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x28]
MOV RDI,qword ptr [RAX + RCX*0x8]
MOV EAX,dword ptr [RBP + -0x30]
MOV EDX,EAX
XOR ESI,ESI
CALL 0x001362e0
MOV dword ptr [RBP + -0x2c],0x0
LAB_001a18fb:
CMP dword ptr [RBP + -0x2c],0x100
JNC 0x001a198c
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x28]
MOV RDI,qword ptr [RAX + RCX*0x8]
MOV EAX,dword ptr [RBP + -0x2c]
MOV RCX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RCX + 0x8]
MOV RDX,qword ptr [RBP + -0x28]
MOVZX ECX,byte ptr [RCX + RDX*0x1]
IMUL EAX,ECX
MOV EAX,EAX
SHL RAX,0x1
ADD RDI,RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x28]
MOV RSI,qword ptr [RAX + RCX*0x8]
MOV EAX,dword ptr [RBP + -0x2c]
MOV RCX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RCX + 0x8]
MOV RDX,qword ptr [RBP + -0x28]
MOVZX ECX,byte ptr [RCX + RDX*0x1]
IMUL EAX,ECX
MOV EAX,EAX
SHL RAX,0x1
ADD RSI,RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV EDX,EAX
SHL RDX,0x1
CALL 0x001360b0
MOV EAX,dword ptr [RBP + -0x2c]
ADD EAX,0x1
MOV dword ptr [RBP + -0x2c],EAX
JMP 0x001a18fb
LAB_001a198c:
MOV byte ptr [RBP + -0x1],0x0
LAB_001a1990:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x30
POP RBP
RET
|
int1 my_uca_copy_page(long param_1,long param_2,long param_3,long param_4)
{
size_t __n;
long lVar1;
int4 local_34;
int1 local_9;
__n = (long)(int)((uint)*(byte *)(*(long *)(param_3 + 8) + param_4) << 8) << 1;
lVar1 = (**(code **)(param_1 + 0x80))(__n);
*(long *)(*(long *)(param_3 + 0x10) + param_4 * 8) = lVar1;
if (lVar1 == 0) {
local_9 = 1;
}
else {
memset(*(void **)(*(long *)(param_3 + 0x10) + param_4 * 8),0,__n);
for (local_34 = 0; local_34 < 0x100; local_34 = local_34 + 1) {
memcpy((void *)(*(long *)(*(long *)(param_3 + 0x10) + param_4 * 8) +
(ulong)(local_34 * *(byte *)(*(long *)(param_3 + 8) + param_4)) * 2),
(void *)(*(long *)(*(long *)(param_2 + 0x10) + param_4 * 8) +
(ulong)(local_34 * *(byte *)(*(long *)(param_2 + 8) + param_4)) * 2),
(ulong)*(byte *)(*(long *)(param_2 + 8) + param_4) << 1);
}
local_9 = 0;
}
return local_9;
}
| |
23,344 | alaya::SQ4Quantizer<float>::operator=(alaya::SQ4Quantizer<float>&&) | AlayaLite/include/space/quant/sq4.hpp | auto operator=(SQ4Quantizer &&other) noexcept -> SQ4Quantizer & {
if (this != &other) {
dim_ = other.dim_;
min_vector_ = std::move(other.min_vector_);
max_vector_ = std::move(other.max_vector_);
other.dim_ = 0;
}
return *this;
} | O0 | cpp | alaya::SQ4Quantizer<float>::operator=(alaya::SQ4Quantizer<float>&&):
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq %rsi, 0x8(%rsp)
movq 0x10(%rsp), %rax
movq %rax, (%rsp)
cmpq 0x8(%rsp), %rax
je 0x1fa7e
movq (%rsp), %rdi
movq 0x8(%rsp), %rax
movl (%rax), %eax
movl %eax, (%rdi)
movq 0x8(%rsp), %rsi
addq $0x8, %rsi
addq $0x8, %rdi
callq 0x1fb80
movq (%rsp), %rdi
movq 0x8(%rsp), %rsi
addq $0x20, %rsi
addq $0x20, %rdi
callq 0x1fb80
movq 0x8(%rsp), %rax
movl $0x0, (%rax)
movq (%rsp), %rax
addq $0x18, %rsp
retq
nopw (%rax,%rax)
| _ZN5alaya12SQ4QuantizerIfEaSEOS1_:
sub rsp, 18h
mov [rsp+18h+var_8], rdi
mov [rsp+18h+var_10], rsi
mov rax, [rsp+18h+var_8]
mov [rsp+18h+var_18], rax
cmp rax, [rsp+18h+var_10]
jz short loc_1FA7E
mov rdi, [rsp+18h+var_18]
mov rax, [rsp+18h+var_10]
mov eax, [rax]
mov [rdi], eax
mov rsi, [rsp+18h+var_10]
add rsi, 8
add rdi, 8
call _ZNSt6vectorIfSaIfEEaSEOS1_; std::vector<float>::operator=(std::vector<float>&&)
mov rdi, [rsp+18h+var_18]
mov rsi, [rsp+18h+var_10]
add rsi, 20h ; ' '
add rdi, 20h ; ' '
call _ZNSt6vectorIfSaIfEEaSEOS1_; std::vector<float>::operator=(std::vector<float>&&)
mov rax, [rsp+18h+var_10]
mov dword ptr [rax], 0
loc_1FA7E:
mov rax, [rsp+18h+var_18]
add rsp, 18h
retn
| _DWORD * alaya::SQ4Quantizer<float>::operator=(_DWORD *a1, _DWORD *a2)
{
if ( a1 != a2 )
{
*a1 = *a2;
std::vector<float>::operator=(a1 + 2);
std::vector<float>::operator=(a1 + 8);
*a2 = 0;
}
return a1;
}
| operator=:
SUB RSP,0x18
MOV qword ptr [RSP + 0x10],RDI
MOV qword ptr [RSP + 0x8],RSI
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP],RAX
CMP RAX,qword ptr [RSP + 0x8]
JZ 0x0011fa7e
MOV RDI,qword ptr [RSP]
MOV RAX,qword ptr [RSP + 0x8]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RDI],EAX
MOV RSI,qword ptr [RSP + 0x8]
ADD RSI,0x8
ADD RDI,0x8
CALL 0x0011fb80
MOV RDI,qword ptr [RSP]
MOV RSI,qword ptr [RSP + 0x8]
ADD RSI,0x20
ADD RDI,0x20
CALL 0x0011fb80
MOV RAX,qword ptr [RSP + 0x8]
MOV dword ptr [RAX],0x0
LAB_0011fa7e:
MOV RAX,qword ptr [RSP]
ADD RSP,0x18
RET
|
/* alaya::SQ4Quantizer<float>::TEMPNAMEPLACEHOLDERVALUE(alaya::SQ4Quantizer<float>&&) */
SQ4Quantizer<float> * __thiscall
alaya::SQ4Quantizer<float>::operator=(SQ4Quantizer<float> *this,SQ4Quantizer *param_1)
{
if (this != (SQ4Quantizer<float> *)param_1) {
*(int4 *)this = *(int4 *)param_1;
std::vector<float,std::allocator<float>>::operator=
((vector<float,std::allocator<float>> *)(this + 8),(vector *)(param_1 + 8));
std::vector<float,std::allocator<float>>::operator=
((vector<float,std::allocator<float>> *)(this + 0x20),(vector *)(param_1 + 0x20));
*(int4 *)param_1 = 0;
}
return this;
}
| |
23,345 | ma_multi_malloc | eloqsql/libmariadb/libmariadb/ma_alloc.c | void *ma_multi_malloc(myf myFlags, ...)
{
va_list args;
char **ptr,*start,*res;
size_t tot_length,length;
va_start(args,myFlags);
tot_length=0;
while ((ptr=va_arg(args, char **)))
{
length=va_arg(args, size_t);
tot_length+=ALIGN_SIZE(length);
}
va_end(args);
if (!(start=(char *)malloc(tot_length)))
return 0;
va_start(args,myFlags);
res=start;
while ((ptr=va_arg(args, char **)))
{
*ptr=res;
length=va_arg(args,size_t);
res+=ALIGN_SIZE(length);
}
va_end(args);
return start;
} | O0 | c | ma_multi_malloc:
pushq %rbp
movq %rsp, %rbp
subq $0x170, %rsp # imm = 0x170
testb %al, %al
je 0x294a1
movaps %xmm0, -0xe0(%rbp)
movaps %xmm1, -0xd0(%rbp)
movaps %xmm2, -0xc0(%rbp)
movaps %xmm3, -0xb0(%rbp)
movaps %xmm4, -0xa0(%rbp)
movaps %xmm5, -0x90(%rbp)
movaps %xmm6, -0x80(%rbp)
movaps %xmm7, -0x70(%rbp)
movq %r9, -0xe8(%rbp)
movq %r8, -0xf0(%rbp)
movq %rcx, -0xf8(%rbp)
movq %rdx, -0x100(%rbp)
movq %rsi, -0x108(%rbp)
movl %edi, -0xc(%rbp)
leaq -0x30(%rbp), %rax
leaq -0x110(%rbp), %rcx
movq %rcx, 0x10(%rax)
leaq 0x10(%rbp), %rcx
movq %rcx, 0x8(%rax)
movl $0x30, 0x4(%rax)
movl $0x8, (%rax)
movq $0x0, -0x50(%rbp)
leaq -0x30(%rbp), %rax
movq %rax, -0x120(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0x114(%rbp)
cmpl $0x28, %eax
ja 0x2952e
movq -0x120(%rbp), %rcx
movl -0x114(%rbp), %edx
movslq %edx, %rax
addq 0x10(%rcx), %rax
addl $0x8, %edx
movl %edx, (%rcx)
movq %rax, -0x128(%rbp)
jmp 0x2954b
movq -0x120(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x8(%rcx)
movq %rax, -0x128(%rbp)
movq -0x128(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, %rax
je 0x295e6
leaq -0x30(%rbp), %rax
movq %rax, -0x138(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0x12c(%rbp)
cmpl $0x28, %eax
ja 0x2959e
movq -0x138(%rbp), %rcx
movl -0x12c(%rbp), %edx
movslq %edx, %rax
addq 0x10(%rcx), %rax
addl $0x8, %edx
movl %edx, (%rcx)
movq %rax, -0x140(%rbp)
jmp 0x295bb
movq -0x138(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x8(%rcx)
movq %rax, -0x140(%rbp)
movq -0x140(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
addq $0x8, %rax
subq $0x1, %rax
andq $-0x8, %rax
addq -0x50(%rbp), %rax
movq %rax, -0x50(%rbp)
jmp 0x294f3
leaq -0x30(%rbp), %rax
movq -0x50(%rbp), %rdi
callq 0x135c0
movq %rax, -0x40(%rbp)
cmpq $0x0, %rax
jne 0x2960a
movq $0x0, -0x8(%rbp)
jmp 0x29740
leaq -0x30(%rbp), %rax
leaq -0x110(%rbp), %rcx
movq %rcx, 0x10(%rax)
leaq 0x10(%rbp), %rcx
movq %rcx, 0x8(%rax)
movl $0x30, 0x4(%rax)
movl $0x8, (%rax)
movq -0x40(%rbp), %rax
movq %rax, -0x48(%rbp)
leaq -0x30(%rbp), %rax
movq %rax, -0x150(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0x144(%rbp)
cmpl $0x28, %eax
ja 0x29671
movq -0x150(%rbp), %rcx
movl -0x144(%rbp), %edx
movslq %edx, %rax
addq 0x10(%rcx), %rax
addl $0x8, %edx
movl %edx, (%rcx)
movq %rax, -0x158(%rbp)
jmp 0x2968e
movq -0x150(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x8(%rcx)
movq %rax, -0x158(%rbp)
movq -0x158(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, %rax
je 0x29734
movq -0x48(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, (%rax)
leaq -0x30(%rbp), %rax
movq %rax, -0x168(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0x15c(%rbp)
cmpl $0x28, %eax
ja 0x296ec
movq -0x168(%rbp), %rcx
movl -0x15c(%rbp), %edx
movslq %edx, %rax
addq 0x10(%rcx), %rax
addl $0x8, %edx
movl %edx, (%rcx)
movq %rax, -0x170(%rbp)
jmp 0x29709
movq -0x168(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x8(%rcx)
movq %rax, -0x170(%rbp)
movq -0x170(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
addq $0x8, %rax
subq $0x1, %rax
andq $-0x8, %rax
addq -0x48(%rbp), %rax
movq %rax, -0x48(%rbp)
jmp 0x29636
leaq -0x30(%rbp), %rax
movq -0x40(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x170, %rsp # imm = 0x170
popq %rbp
retq
nopl (%rax)
| ma_multi_malloc:
push rbp
mov rbp, rsp
sub rsp, 170h
test al, al
jz short loc_294A1
movaps [rbp+var_E0], xmm0
movaps [rbp+var_D0], xmm1
movaps [rbp+var_C0], xmm2
movaps [rbp+var_B0], xmm3
movaps [rbp+var_A0], xmm4
movaps [rbp+var_90], xmm5
movaps [rbp+var_80], xmm6
movaps [rbp+var_70], xmm7
loc_294A1:
mov [rbp+var_E8], r9
mov [rbp+var_F0], r8
mov [rbp+var_F8], rcx
mov [rbp+var_100], rdx
mov [rbp+var_108], rsi
mov [rbp+var_C], edi
lea rax, [rbp+var_30]
lea rcx, [rbp+var_110]
mov [rax+10h], rcx
lea rcx, [rbp+arg_0]
mov [rax+8], rcx
mov dword ptr [rax+4], 30h ; '0'
mov dword ptr [rax], 8
mov [rbp+var_50], 0
loc_294F3:
lea rax, [rbp+var_30]
mov [rbp+var_120], rax
mov eax, [rbp+var_30]
mov [rbp+var_114], eax
cmp eax, 28h ; '('
ja short loc_2952E
mov rcx, [rbp+var_120]
mov edx, [rbp+var_114]
movsxd rax, edx
add rax, [rcx+10h]
add edx, 8
mov [rcx], edx
mov [rbp+var_128], rax
jmp short loc_2954B
loc_2952E:
mov rcx, [rbp+var_120]
mov rax, [rcx+8]
mov rdx, rax
add rdx, 8
mov [rcx+8], rdx
mov [rbp+var_128], rax
loc_2954B:
mov rax, [rbp+var_128]
mov rax, [rax]
mov [rbp+var_38], rax
cmp rax, 0
jz loc_295E6
lea rax, [rbp+var_30]
mov [rbp+var_138], rax
mov eax, [rbp+var_30]
mov [rbp+var_12C], eax
cmp eax, 28h ; '('
ja short loc_2959E
mov rcx, [rbp+var_138]
mov edx, [rbp+var_12C]
movsxd rax, edx
add rax, [rcx+10h]
add edx, 8
mov [rcx], edx
mov [rbp+var_140], rax
jmp short loc_295BB
loc_2959E:
mov rcx, [rbp+var_138]
mov rax, [rcx+8]
mov rdx, rax
add rdx, 8
mov [rcx+8], rdx
mov [rbp+var_140], rax
loc_295BB:
mov rax, [rbp+var_140]
mov rax, [rax]
mov [rbp+var_58], rax
mov rax, [rbp+var_58]
add rax, 8
sub rax, 1
and rax, 0FFFFFFFFFFFFFFF8h
add rax, [rbp+var_50]
mov [rbp+var_50], rax
jmp loc_294F3
loc_295E6:
lea rax, [rbp+var_30]
mov rdi, [rbp+var_50]
call _malloc
mov [rbp+var_40], rax
cmp rax, 0
jnz short loc_2960A
mov [rbp+var_8], 0
jmp loc_29740
loc_2960A:
lea rax, [rbp+var_30]
lea rcx, [rbp+var_110]
mov [rax+10h], rcx
lea rcx, [rbp+arg_0]
mov [rax+8], rcx
mov dword ptr [rax+4], 30h ; '0'
mov dword ptr [rax], 8
mov rax, [rbp+var_40]
mov [rbp+var_48], rax
loc_29636:
lea rax, [rbp+var_30]
mov [rbp+var_150], rax
mov eax, [rbp+var_30]
mov [rbp+var_144], eax
cmp eax, 28h ; '('
ja short loc_29671
mov rcx, [rbp+var_150]
mov edx, [rbp+var_144]
movsxd rax, edx
add rax, [rcx+10h]
add edx, 8
mov [rcx], edx
mov [rbp+var_158], rax
jmp short loc_2968E
loc_29671:
mov rcx, [rbp+var_150]
mov rax, [rcx+8]
mov rdx, rax
add rdx, 8
mov [rcx+8], rdx
mov [rbp+var_158], rax
loc_2968E:
mov rax, [rbp+var_158]
mov rax, [rax]
mov [rbp+var_38], rax
cmp rax, 0
jz loc_29734
mov rcx, [rbp+var_48]
mov rax, [rbp+var_38]
mov [rax], rcx
lea rax, [rbp+var_30]
mov [rbp+var_168], rax
mov eax, [rbp+var_30]
mov [rbp+var_15C], eax
cmp eax, 28h ; '('
ja short loc_296EC
mov rcx, [rbp+var_168]
mov edx, [rbp+var_15C]
movsxd rax, edx
add rax, [rcx+10h]
add edx, 8
mov [rcx], edx
mov [rbp+var_170], rax
jmp short loc_29709
loc_296EC:
mov rcx, [rbp+var_168]
mov rax, [rcx+8]
mov rdx, rax
add rdx, 8
mov [rcx+8], rdx
mov [rbp+var_170], rax
loc_29709:
mov rax, [rbp+var_170]
mov rax, [rax]
mov [rbp+var_58], rax
mov rax, [rbp+var_58]
add rax, 8
sub rax, 1
and rax, 0FFFFFFFFFFFFFFF8h
add rax, [rbp+var_48]
mov [rbp+var_48], rax
jmp loc_29636
loc_29734:
lea rax, [rbp+var_30]
mov rax, [rbp+var_40]
mov [rbp+var_8], rax
loc_29740:
mov rax, [rbp+var_8]
add rsp, 170h
pop rbp
retn
| long long ma_multi_malloc(int a1, ...)
{
_QWORD *overflow_arg_area; // rax
_QWORD *v2; // rax
_QWORD *v3; // rax
_QWORD *v4; // rax
long long i; // [rsp+120h] [rbp-50h]
long long j; // [rsp+128h] [rbp-48h]
long long v8; // [rsp+130h] [rbp-40h]
va_list va; // [rsp+140h] [rbp-30h] BYREF
int v10; // [rsp+164h] [rbp-Ch]
va_start(va, a1);
v10 = a1;
for ( i = 0LL; ; i += (*v2 + 7LL) & 0xFFFFFFFFFFFFFFF8LL )
{
if ( va[0].gp_offset > 0x28 )
{
overflow_arg_area = va[0].overflow_arg_area;
va[0].overflow_arg_area = (char *)va[0].overflow_arg_area + 8;
}
else
{
overflow_arg_area = (char *)va[0].reg_save_area + (int)va[0].gp_offset;
va[0].gp_offset += 8;
}
if ( !*overflow_arg_area )
break;
if ( va[0].gp_offset > 0x28 )
{
v2 = va[0].overflow_arg_area;
va[0].overflow_arg_area = (char *)va[0].overflow_arg_area + 8;
}
else
{
v2 = (char *)va[0].reg_save_area + (int)va[0].gp_offset;
va[0].gp_offset += 8;
}
}
v8 = malloc(i);
if ( !v8 )
return 0LL;
va_end(va);
va_start(va, a1);
for ( j = v8; ; j += (*v4 + 7LL) & 0xFFFFFFFFFFFFFFF8LL )
{
if ( va[0].gp_offset > 0x28 )
{
v3 = va[0].overflow_arg_area;
va[0].overflow_arg_area = (char *)va[0].overflow_arg_area + 8;
}
else
{
v3 = (char *)va[0].reg_save_area + (int)va[0].gp_offset;
va[0].gp_offset += 8;
}
if ( !*v3 )
break;
*(_QWORD *)*v3 = j;
if ( va[0].gp_offset > 0x28 )
{
v4 = va[0].overflow_arg_area;
va[0].overflow_arg_area = (char *)va[0].overflow_arg_area + 8;
}
else
{
v4 = (char *)va[0].reg_save_area + (int)va[0].gp_offset;
va[0].gp_offset += 8;
}
}
return v8;
}
| ma_multi_malloc:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x170
TEST AL,AL
JZ 0x001294a1
MOVAPS xmmword ptr [RBP + -0xe0],XMM0
MOVAPS xmmword ptr [RBP + -0xd0],XMM1
MOVAPS xmmword ptr [RBP + -0xc0],XMM2
MOVAPS xmmword ptr [RBP + -0xb0],XMM3
MOVAPS xmmword ptr [RBP + -0xa0],XMM4
MOVAPS xmmword ptr [RBP + -0x90],XMM5
MOVAPS xmmword ptr [RBP + -0x80],XMM6
MOVAPS xmmword ptr [RBP + -0x70],XMM7
LAB_001294a1:
MOV qword ptr [RBP + -0xe8],R9
MOV qword ptr [RBP + -0xf0],R8
MOV qword ptr [RBP + -0xf8],RCX
MOV qword ptr [RBP + -0x100],RDX
MOV qword ptr [RBP + -0x108],RSI
MOV dword ptr [RBP + -0xc],EDI
LEA RAX,[RBP + -0x30]
LEA RCX,[RBP + -0x110]
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],0x8
MOV qword ptr [RBP + -0x50],0x0
LAB_001294f3:
LEA RAX,[RBP + -0x30]
MOV qword ptr [RBP + -0x120],RAX
MOV EAX,dword ptr [RBP + -0x30]
MOV dword ptr [RBP + -0x114],EAX
CMP EAX,0x28
JA 0x0012952e
MOV RCX,qword ptr [RBP + -0x120]
MOV EDX,dword ptr [RBP + -0x114]
MOVSXD RAX,EDX
ADD RAX,qword ptr [RCX + 0x10]
ADD EDX,0x8
MOV dword ptr [RCX],EDX
MOV qword ptr [RBP + -0x128],RAX
JMP 0x0012954b
LAB_0012952e:
MOV RCX,qword ptr [RBP + -0x120]
MOV RAX,qword ptr [RCX + 0x8]
MOV RDX,RAX
ADD RDX,0x8
MOV qword ptr [RCX + 0x8],RDX
MOV qword ptr [RBP + -0x128],RAX
LAB_0012954b:
MOV RAX,qword ptr [RBP + -0x128]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x38],RAX
CMP RAX,0x0
JZ 0x001295e6
LEA RAX,[RBP + -0x30]
MOV qword ptr [RBP + -0x138],RAX
MOV EAX,dword ptr [RBP + -0x30]
MOV dword ptr [RBP + -0x12c],EAX
CMP EAX,0x28
JA 0x0012959e
MOV RCX,qword ptr [RBP + -0x138]
MOV EDX,dword ptr [RBP + -0x12c]
MOVSXD RAX,EDX
ADD RAX,qword ptr [RCX + 0x10]
ADD EDX,0x8
MOV dword ptr [RCX],EDX
MOV qword ptr [RBP + -0x140],RAX
JMP 0x001295bb
LAB_0012959e:
MOV RCX,qword ptr [RBP + -0x138]
MOV RAX,qword ptr [RCX + 0x8]
MOV RDX,RAX
ADD RDX,0x8
MOV qword ptr [RCX + 0x8],RDX
MOV qword ptr [RBP + -0x140],RAX
LAB_001295bb:
MOV RAX,qword ptr [RBP + -0x140]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x8
SUB RAX,0x1
AND RAX,-0x8
ADD RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x50],RAX
JMP 0x001294f3
LAB_001295e6:
LEA RAX,[RBP + -0x30]
MOV RDI,qword ptr [RBP + -0x50]
CALL 0x001135c0
MOV qword ptr [RBP + -0x40],RAX
CMP RAX,0x0
JNZ 0x0012960a
MOV qword ptr [RBP + -0x8],0x0
JMP 0x00129740
LAB_0012960a:
LEA RAX,[RBP + -0x30]
LEA RCX,[RBP + -0x110]
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],0x8
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RBP + -0x48],RAX
LAB_00129636:
LEA RAX,[RBP + -0x30]
MOV qword ptr [RBP + -0x150],RAX
MOV EAX,dword ptr [RBP + -0x30]
MOV dword ptr [RBP + -0x144],EAX
CMP EAX,0x28
JA 0x00129671
MOV RCX,qword ptr [RBP + -0x150]
MOV EDX,dword ptr [RBP + -0x144]
MOVSXD RAX,EDX
ADD RAX,qword ptr [RCX + 0x10]
ADD EDX,0x8
MOV dword ptr [RCX],EDX
MOV qword ptr [RBP + -0x158],RAX
JMP 0x0012968e
LAB_00129671:
MOV RCX,qword ptr [RBP + -0x150]
MOV RAX,qword ptr [RCX + 0x8]
MOV RDX,RAX
ADD RDX,0x8
MOV qword ptr [RCX + 0x8],RDX
MOV qword ptr [RBP + -0x158],RAX
LAB_0012968e:
MOV RAX,qword ptr [RBP + -0x158]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x38],RAX
CMP RAX,0x0
JZ 0x00129734
MOV RCX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX],RCX
LEA RAX,[RBP + -0x30]
MOV qword ptr [RBP + -0x168],RAX
MOV EAX,dword ptr [RBP + -0x30]
MOV dword ptr [RBP + -0x15c],EAX
CMP EAX,0x28
JA 0x001296ec
MOV RCX,qword ptr [RBP + -0x168]
MOV EDX,dword ptr [RBP + -0x15c]
MOVSXD RAX,EDX
ADD RAX,qword ptr [RCX + 0x10]
ADD EDX,0x8
MOV dword ptr [RCX],EDX
MOV qword ptr [RBP + -0x170],RAX
JMP 0x00129709
LAB_001296ec:
MOV RCX,qword ptr [RBP + -0x168]
MOV RAX,qword ptr [RCX + 0x8]
MOV RDX,RAX
ADD RDX,0x8
MOV qword ptr [RCX + 0x8],RDX
MOV qword ptr [RBP + -0x170],RAX
LAB_00129709:
MOV RAX,qword ptr [RBP + -0x170]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x8
SUB RAX,0x1
AND RAX,-0x8
ADD RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RBP + -0x48],RAX
JMP 0x00129636
LAB_00129734:
LEA RAX,[RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RBP + -0x8],RAX
LAB_00129740:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x170
POP RBP
RET
|
/* WARNING: Restarted to delay deadcode elimination for space: stack */
void * ma_multi_malloc(int8 param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5,int8 param_6,int8 param_7,int8 param_8,
int4 param_9,int8 param_10,int8 param_11,int8 param_12
,int8 param_13,int8 param_14)
{
char in_AL;
long *local_178;
long *local_160;
long *local_148;
long *local_130;
long local_118 [4];
int8 local_f8;
int8 local_f0;
int8 local_e8;
int8 local_d8;
int8 local_c8;
int8 local_b8;
int8 local_a8;
int8 local_98;
int8 local_88;
int8 local_78;
long local_60;
size_t local_58;
void *local_50;
long local_40;
uint local_38;
int4 local_34;
long *local_30;
long *local_28;
int4 local_14;
void *local_10;
if (in_AL != '\0') {
local_e8 = param_1;
local_d8 = param_2;
local_c8 = param_3;
local_b8 = param_4;
local_a8 = param_5;
local_98 = param_6;
local_88 = param_7;
local_78 = param_8;
}
local_28 = local_118;
local_30 = (long *)&stack0x00000008;
local_34 = 0x30;
local_38 = 8;
local_58 = 0;
while( true ) {
if (local_38 < 0x29) {
local_130 = (long *)((long)local_28 + (long)(int)local_38);
local_38 = local_38 + 8;
}
else {
local_130 = local_30;
local_30 = local_30 + 1;
}
local_40 = *local_130;
if (local_40 == 0) break;
if (local_38 < 0x29) {
local_148 = (long *)((long)local_28 + (long)(int)local_38);
local_38 = local_38 + 8;
}
else {
local_148 = local_30;
local_30 = local_30 + 1;
}
local_60 = *local_148;
local_58 = (local_60 + 7U & 0xfffffffffffffff8) + local_58;
}
local_118[1] = param_10;
local_118[2] = param_11;
local_118[3] = param_12;
local_f8 = param_13;
local_f0 = param_14;
local_14 = param_9;
local_10 = malloc(local_58);
if (local_10 == (void *)0x0) {
local_10 = (void *)0x0;
}
else {
local_30 = (long *)&stack0x00000008;
local_38 = 8;
local_50 = local_10;
while( true ) {
if (local_38 < 0x29) {
local_160 = (long *)((long)local_118 + (long)(int)local_38);
local_38 = local_38 + 8;
}
else {
local_160 = local_30;
local_30 = local_30 + 1;
}
if ((int8 *)*local_160 == (int8 *)0x0) break;
*(int8 *)*local_160 = local_50;
if (local_38 < 0x29) {
local_178 = (long *)((long)local_118 + (long)(int)local_38);
local_38 = local_38 + 8;
}
else {
local_178 = local_30;
local_30 = local_30 + 1;
}
local_50 = (void *)((*local_178 + 7U & 0xfffffffffffffff8) + (long)local_50);
}
}
return local_10;
}
| |
23,346 | ModbusPortPrivate::ModbusPortPrivate(bool) | serhmarch[P]ModbusBridge/modbus/src/unix/../ModbusPort_p.h | ModbusPortPrivate(bool blocking)
{
this->state = STATE_UNKNOWN;
this->modeServer = false;
this->modeBlocking = blocking;
this->clearChanged();
} | O2 | c | ModbusPortPrivate::ModbusPortPrivate(bool):
leaq 0xd0f5(%rip), %rax # 0x1cc08
movq %rax, (%rdi)
leaq 0x28(%rdi), %rax
movq %rax, 0x18(%rdi)
andq $0x0, 0x20(%rdi)
movb $0x0, 0x28(%rdi)
andl $0x0, 0x8(%rdi)
movb %sil, 0xe(%rdi)
andw $0x0, 0xc(%rdi)
retq
nop
| _ZN17ModbusPortPrivateC2Eb:
lea rax, off_1CC08
mov [rdi], rax
lea rax, [rdi+28h]
mov [rdi+18h], rax
and qword ptr [rdi+20h], 0
mov byte ptr [rdi+28h], 0
and dword ptr [rdi+8], 0
mov [rdi+0Eh], sil
and word ptr [rdi+0Ch], 0
retn
| void ModbusPortPrivate::ModbusPortPrivate(ModbusPortPrivate *this, char a2)
{
*(_QWORD *)this = off_1CC08;
*((_QWORD *)this + 3) = (char *)this + 40;
*((_QWORD *)this + 4) = 0LL;
*((_BYTE *)this + 40) = 0;
*((_DWORD *)this + 2) = 0;
*((_BYTE *)this + 14) = a2;
*((_WORD *)this + 6) = 0;
}
| ModbusPortPrivate:
LEA RAX,[0x11cc08]
MOV qword ptr [RDI],RAX
LEA RAX,[RDI + 0x28]
MOV qword ptr [RDI + 0x18],RAX
AND qword ptr [RDI + 0x20],0x0
MOV byte ptr [RDI + 0x28],0x0
AND dword ptr [RDI + 0x8],0x0
MOV byte ptr [RDI + 0xe],SIL
AND word ptr [RDI + 0xc],0x0
RET
|
/* ModbusPortPrivate::ModbusPortPrivate(bool) */
void __thiscall ModbusPortPrivate::ModbusPortPrivate(ModbusPortPrivate *this,bool param_1)
{
*(int ***)this = &PTR__ModbusPortPrivate_0011cc08;
*(ModbusPortPrivate **)(this + 0x18) = this + 0x28;
*(int8 *)(this + 0x20) = 0;
this[0x28] = (ModbusPortPrivate)0x0;
*(int4 *)(this + 8) = 0;
this[0xe] = (ModbusPortPrivate)param_1;
*(int2 *)(this + 0xc) = 0;
return;
}
| |
23,347 | my_strnncollsp_padspace_bin | eloqsql/strings/ctype-bin.c | int my_strnncollsp_padspace_bin(const uchar *str, size_t length)
{
for ( ; length ; str++, length--)
{
if (*str < ' ')
return -1;
else if (*str > ' ')
return 1;
}
return 0;
} | O3 | c | my_strnncollsp_padspace_bin:
pushq %rbp
movq %rsp, %rbp
testq %rsi, %rsi
je 0x4f258
xorl %eax, %eax
cmpb $0x20, (%rdi,%rax)
jb 0x4f25c
jne 0x4f263
incq %rax
cmpq %rax, %rsi
jne 0x4f248
xorl %eax, %eax
jmp 0x4f268
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
jmp 0x4f268
movl $0x1, %eax
popq %rbp
retq
| my_strnncollsp_padspace_bin:
push rbp
mov rbp, rsp
test rsi, rsi
jz short loc_4F258
xor eax, eax
loc_4F248:
cmp byte ptr [rdi+rax], 20h ; ' '
jb short loc_4F25C
jnz short loc_4F263
inc rax
cmp rsi, rax
jnz short loc_4F248
loc_4F258:
xor eax, eax
jmp short loc_4F268
loc_4F25C:
mov eax, 0FFFFFFFFh
jmp short loc_4F268
loc_4F263:
mov eax, 1
loc_4F268:
pop rbp
retn
| long long my_strnncollsp_padspace_bin(long long a1, long long a2)
{
long long v2; // rax
if ( !a2 )
return 0LL;
v2 = 0LL;
while ( 1 )
{
if ( *(_BYTE *)(a1 + v2) < 0x20u )
return 0xFFFFFFFFLL;
if ( *(_BYTE *)(a1 + v2) != 32 )
break;
if ( a2 == ++v2 )
return 0LL;
}
return 1LL;
}
| my_strnncollsp_padspace_bin:
PUSH RBP
MOV RBP,RSP
TEST RSI,RSI
JZ 0x0014f258
XOR EAX,EAX
LAB_0014f248:
CMP byte ptr [RDI + RAX*0x1],0x20
JC 0x0014f25c
JNZ 0x0014f263
INC RAX
CMP RSI,RAX
JNZ 0x0014f248
LAB_0014f258:
XOR EAX,EAX
JMP 0x0014f268
LAB_0014f25c:
MOV EAX,0xffffffff
JMP 0x0014f268
LAB_0014f263:
MOV EAX,0x1
LAB_0014f268:
POP RBP
RET
|
int8 my_strnncollsp_padspace_bin(long param_1,long param_2)
{
long lVar1;
if (param_2 != 0) {
lVar1 = 0;
do {
if (*(byte *)(param_1 + lVar1) < 0x20) {
return 0xffffffff;
}
if (*(byte *)(param_1 + lVar1) != 0x20) {
return 1;
}
lVar1 = lVar1 + 1;
} while (param_2 != lVar1);
}
return 0;
}
| |
23,348 | my_string_repertoire | eloqsql/strings/ctype.c | my_repertoire_t
my_string_repertoire(CHARSET_INFO *cs, const char *str, size_t length)
{
if (cs->mbminlen == 1 && !(cs->state & MY_CS_NONASCII))
{
return my_string_repertoire_8bit(cs, str, length);
}
else
{
const char *strend= str + length;
my_wc_t wc;
int chlen;
for (;
(chlen= my_ci_mb_wc(cs, &wc, (uchar*) str, (uchar*) strend)) > 0;
str+= chlen)
{
if (wc > 0x7F)
return MY_REPERTOIRE_UNICODE30;
}
}
return MY_REPERTOIRE_ASCII;
} | O3 | c | my_string_repertoire:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
cmpl $0x1, 0x98(%rdi)
jne 0xd196b
testb $0x20, 0xd(%r15)
jne 0xd196b
movl $0x1, %eax
testq %rbx, %rbx
jle 0xd19d1
addq %r14, %rbx
cmpb $0x0, (%r14)
js 0xd19de
incq %r14
cmpq %rbx, %r14
jb 0xd195b
jmp 0xd19d1
addq %r14, %rbx
movq 0xb8(%r15), %rax
leaq -0x28(%rbp), %rsi
movq %r15, %rdi
movq %r14, %rdx
movq %rbx, %rcx
callq *0x28(%rax)
testl %eax, %eax
setg %cl
jle 0xd19c7
cmpq $0x7f, -0x28(%rbp)
ja 0xd19c7
leaq -0x28(%rbp), %r12
movq %r14, %rcx
movl %eax, %r14d
addq %rcx, %r14
movq 0xb8(%r15), %rax
movq %r15, %rdi
movq %r12, %rsi
movq %r14, %rdx
movq %rbx, %rcx
callq *0x28(%rax)
testl %eax, %eax
setg %cl
jle 0xd19c7
cmpq $0x80, -0x28(%rbp)
jb 0xd1997
movzbl %cl, %eax
leal 0x1(,%rax,2), %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl $0x3, %eax
jmp 0xd19d1
| my_string_repertoire:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
sub rsp, 10h
mov rbx, rdx
mov r14, rsi
mov r15, rdi
cmp dword ptr [rdi+98h], 1
jnz short loc_D196B
test byte ptr [r15+0Dh], 20h
jnz short loc_D196B
mov eax, 1
test rbx, rbx
jle short loc_D19D1
add rbx, r14
loc_D195B:
cmp byte ptr [r14], 0
js short loc_D19DE
inc r14
cmp r14, rbx
jb short loc_D195B
jmp short loc_D19D1
loc_D196B:
add rbx, r14
mov rax, [r15+0B8h]
lea rsi, [rbp+var_28]
mov rdi, r15
mov rdx, r14
mov rcx, rbx
call qword ptr [rax+28h]
test eax, eax
setnle cl
jle short loc_D19C7
cmp [rbp+var_28], 7Fh
ja short loc_D19C7
lea r12, [rbp+var_28]
loc_D1997:
mov rcx, r14
mov r14d, eax
add r14, rcx
mov rax, [r15+0B8h]
mov rdi, r15
mov rsi, r12
mov rdx, r14
mov rcx, rbx
call qword ptr [rax+28h]
test eax, eax
setnle cl
jle short loc_D19C7
cmp [rbp+var_28], 80h
jb short loc_D1997
loc_D19C7:
movzx eax, cl
lea eax, ds:1[rax*2]
loc_D19D1:
add rsp, 10h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_D19DE:
mov eax, 3
jmp short loc_D19D1
| long long my_string_repertoire(long long a1, char *a2, long long a3)
{
char *v3; // r14
long long result; // rax
char *v5; // rbx
int v6; // eax
bool v7; // cl
_QWORD v8[5]; // [rsp+8h] [rbp-28h] BYREF
v3 = a2;
if ( *(_DWORD *)(a1 + 152) != 1 || (*(_BYTE *)(a1 + 13) & 0x20) != 0 )
{
v5 = &a2[a3];
v6 = (*(long long ( **)(long long, _QWORD *, char *, char *))(*(_QWORD *)(a1 + 184) + 40LL))(
a1,
v8,
a2,
&a2[a3]);
v7 = v6 > 0;
if ( v6 > 0 && v8[0] <= 0x7FuLL )
{
do
{
v3 += (unsigned int)v6;
v6 = (*(long long ( **)(long long, _QWORD *, char *, char *))(*(_QWORD *)(a1 + 184) + 40LL))(
a1,
v8,
v3,
v5);
v7 = v6 > 0;
}
while ( v6 > 0 && v8[0] < 0x80uLL );
}
return 2 * (unsigned int)v7 + 1;
}
else
{
result = 1LL;
if ( a3 > 0 )
{
while ( *v3 >= 0 )
{
if ( ++v3 >= &a2[a3] )
return result;
}
return 3LL;
}
}
return result;
}
| my_string_repertoire:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV RBX,RDX
MOV R14,RSI
MOV R15,RDI
CMP dword ptr [RDI + 0x98],0x1
JNZ 0x001d196b
TEST byte ptr [R15 + 0xd],0x20
JNZ 0x001d196b
MOV EAX,0x1
TEST RBX,RBX
JLE 0x001d19d1
ADD RBX,R14
LAB_001d195b:
CMP byte ptr [R14],0x0
JS 0x001d19de
INC R14
CMP R14,RBX
JC 0x001d195b
JMP 0x001d19d1
LAB_001d196b:
ADD RBX,R14
MOV RAX,qword ptr [R15 + 0xb8]
LEA RSI,[RBP + -0x28]
MOV RDI,R15
MOV RDX,R14
MOV RCX,RBX
CALL qword ptr [RAX + 0x28]
TEST EAX,EAX
SETG CL
JLE 0x001d19c7
CMP qword ptr [RBP + -0x28],0x7f
JA 0x001d19c7
LEA R12,[RBP + -0x28]
LAB_001d1997:
MOV RCX,R14
MOV R14D,EAX
ADD R14,RCX
MOV RAX,qword ptr [R15 + 0xb8]
MOV RDI,R15
MOV RSI,R12
MOV RDX,R14
MOV RCX,RBX
CALL qword ptr [RAX + 0x28]
TEST EAX,EAX
SETG CL
JLE 0x001d19c7
CMP qword ptr [RBP + -0x28],0x80
JC 0x001d1997
LAB_001d19c7:
MOVZX EAX,CL
LEA EAX,[0x1 + RAX*0x2]
LAB_001d19d1:
ADD RSP,0x10
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_001d19de:
MOV EAX,0x3
JMP 0x001d19d1
|
char my_string_repertoire(long param_1,char *param_2,long param_3)
{
char cVar1;
uint uVar2;
bool bVar3;
char *pcVar4;
ulong local_30;
if ((*(int *)(param_1 + 0x98) == 1) && ((*(byte *)(param_1 + 0xd) & 0x20) == 0)) {
cVar1 = '\x01';
if (0 < param_3) {
pcVar4 = param_2 + param_3;
do {
if (*param_2 < '\0') {
return '\x03';
}
param_2 = param_2 + 1;
} while (param_2 < pcVar4);
}
}
else {
pcVar4 = param_2 + param_3;
uVar2 = (**(code **)(*(long *)(param_1 + 0xb8) + 0x28))(param_1,&local_30,param_2,pcVar4);
bVar3 = 0 < (int)uVar2;
if ((0 < (int)uVar2) && (local_30 < 0x80)) {
do {
param_2 = param_2 + uVar2;
uVar2 = (**(code **)(*(long *)(param_1 + 0xb8) + 0x28))(param_1,&local_30,param_2,pcVar4);
bVar3 = 0 < (int)uVar2;
if ((int)uVar2 < 1) break;
} while (local_30 < 0x80);
}
cVar1 = bVar3 * '\x02' + '\x01';
}
return cVar1;
}
| |
23,349 | 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>::push_back(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 | void push_back(const basic_json& val)
{
// push_back only works for null objects or arrays
if (JSON_HEDLEY_UNLIKELY(!(is_null() || is_array())))
{
JSON_THROW(type_error::create(308, detail::concat("cannot use push_back() with ", type_name()), this));
}
// transform null object into an array
if (is_null())
{
m_data.m_type = value_t::array;
m_data.m_value = value_t::array;
assert_invariant();
}
// add element to array
const auto old_capacity = m_data.m_value.array->capacity();
m_data.m_value.array->push_back(val);
set_parent(m_data.m_value.array->back(), old_capacity);
} | O3 | cpp | nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::push_back(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 %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movzbl (%rdi), %eax
testl %eax, %eax
jne 0xa650e
movb $0x2, (%r14)
movl $0x18, %edi
callq 0x1a870
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
movq %rax, 0x8(%r14)
movq %r14, %rdi
movl $0x1, %esi
callq 0x595aa
jmp 0xa6513
cmpl $0x2, %eax
jne 0xa6527
movq 0x8(%r14), %rdi
movq %rbx, %rsi
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
jmp 0xac72e
movl $0x20, %edi
callq 0x1a430
movq %rax, %rbx
movq %r14, %rdi
callq 0x5faf2
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
leaq 0x4adaf(%rip), %rsi # 0xf12fa
leaq 0x10(%rsp), %rdi
callq 0x875fd
movb $0x1, %bpl
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
movl $0x134, %esi # imm = 0x134
movq %r14, %rcx
callq 0x5f89a
xorl %ebp, %ebp
leaq 0x839e2(%rip), %rsi # 0x129f58
leaq -0x4a855(%rip), %rdx # 0x5bd28
movq %rbx, %rdi
callq 0x1aea0
movq %rax, %r14
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa65a3
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x1a890
testb %bpl, %bpl
jne 0xa65ad
jmp 0xa65b5
movq %rax, %r14
movq %rbx, %rdi
callq 0x1a650
movq %r14, %rdi
callq 0x1af20
nop
| _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backERKSD_:
push rbp; char
push r14; int
push rbx; __int64
sub rsp, 30h
mov rbx, rsi
mov r14, rdi
movzx eax, byte ptr [rdi]
test eax, eax
jnz short loc_A650E
mov byte ptr [r14], 2
mov edi, 18h; unsigned __int64
call __Znwm; operator new(ulong)
xorps xmm0, xmm0
movups xmmword ptr [rax], xmm0
mov qword ptr [rax+10h], 0
mov [r14+8], rax
mov rdi, r14
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
jmp short loc_A6513
loc_A650E:
cmp eax, 2
jnz short loc_A6527
loc_A6513:
mov rdi, [r14+8]
mov rsi, rbx
add rsp, 30h
pop rbx
pop r14
pop rbp
jmp _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EE9push_backERKSD_; 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>>::push_back(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
loc_A6527:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void)
lea rdx, [rsp+48h+var_40]
mov [rdx], rax
lea rsi, aCannotUsePushB; "cannot use push_back() with "
lea rdi, [rsp+48h+var_38]
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA29_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(char const(&)[29],char const* &&)
mov bpl, 1
lea rdx, [rsp+48h+var_38]
mov rdi, rbx; this
mov esi, 134h; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+48h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_A65A3
mov rsi, [rsp+48h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A65A3:
test bpl, bpl
jnz short loc_A65AD
jmp short loc_A65B5
mov r14, rax
loc_A65AD:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_A65B5:
mov rdi, r14
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back(
long long a1,
long long a2)
{
long long v2; // rax
nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx
const char *v5; // [rsp+8h] [rbp-40h] BYREF
_QWORD v6[2]; // [rsp+10h] [rbp-38h] BYREF
if ( *(_BYTE *)a1 )
{
if ( *(_BYTE *)a1 != 2 )
{
exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL);
v5 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name((unsigned __int8 *)a1);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(
(long long)v6,
(long long)"cannot use push_back() with ",
&v5);
ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
exception,
308,
v6);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
}
else
{
*(_BYTE *)a1 = 2;
v2 = operator new(0x18uLL);
*(_OWORD *)v2 = 0LL;
*(_QWORD *)(v2 + 16) = 0LL;
*(_QWORD *)(a1 + 8) = v2;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1);
}
return 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>>::push_back(
*(_QWORD *)(a1 + 8),
a2);
}
| push_back:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV RBX,RSI
MOV R14,RDI
MOVZX EAX,byte ptr [RDI]
TEST EAX,EAX
JNZ 0x001a650e
MOV byte ptr [R14],0x2
MOV EDI,0x18
CALL 0x0011a870
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RAX],XMM0
MOV qword ptr [RAX + 0x10],0x0
MOV qword ptr [R14 + 0x8],RAX
MOV RDI,R14
MOV ESI,0x1
CALL 0x001595aa
JMP 0x001a6513
LAB_001a650e:
CMP EAX,0x2
JNZ 0x001a6527
LAB_001a6513:
MOV RDI,qword ptr [R14 + 0x8]
MOV RSI,RBX
ADD RSP,0x30
POP RBX
POP R14
POP RBP
JMP 0x001ac72e
LAB_001a6527:
MOV EDI,0x20
CALL 0x0011a430
MOV RBX,RAX
MOV RDI,R14
CALL 0x0015faf2
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],RAX
LAB_001a6544:
LEA RSI,[0x1f12fa]
LEA RDI,[RSP + 0x10]
CALL 0x001875fd
MOV BPL,0x1
LAB_001a6558:
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
MOV ESI,0x134
MOV RCX,R14
CALL 0x0015f89a
XOR EBP,EBP
LEA RSI,[0x229f58]
LEA RDX,[0x15bd28]
MOV RDI,RBX
CALL 0x0011aea0
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >,
void>::push_back(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const&) */
void __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::push_back(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,basic_json *param_1)
{
int8 *puVar1;
int8 uVar2;
char *local_40;
detail local_38 [32];
if (*this == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x0) {
*this = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2;
puVar1 = (int8 *)operator_new(0x18);
*puVar1 = 0;
puVar1[1] = 0;
puVar1[2] = 0;
*(int8 **)(this + 8) = puVar1;
assert_invariant(SUB81(this,0));
}
else if (*this != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2) {
uVar2 = __cxa_allocate_exception(0x20);
local_40 = (char *)type_name(this);
/* try { // try from 001a6544 to 001a6554 has its CatchHandler @ 001a65aa */
detail::concat<std::__cxx11::string,char_const(&)[29],char_const*>
(local_38,"cannot use push_back() with ",&local_40);
/* try { // try from 001a6558 to 001a6584 has its CatchHandler @ 001a6585 */
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar2,0x134,local_38,this);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar2,&detail::type_error::typeinfo,detail::exception::~exception);
}
std::
vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
::push_back(*(vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
**)(this + 8),param_1);
return;
}
| |
23,350 | ft_boolean_check_syntax_string | eloqsql/storage/myisam/ft_parser.c | my_bool ft_boolean_check_syntax_string(const uchar *str, size_t length,
CHARSET_INFO *cs)
{
uint i, j;
if (cs->mbminlen != 1)
{
DBUG_ASSERT(0);
return 1;
}
if (!str ||
(length + 1 != sizeof(DEFAULT_FTB_SYNTAX)) ||
(str[0] != ' ' && str[1] != ' '))
return 1;
for (i=0; i<sizeof(DEFAULT_FTB_SYNTAX); i++)
{
/* limiting to 7-bit ascii only */
if ((unsigned char)(str[i]) > 127 || my_isalnum(cs, str[i]))
return 1;
for (j=0; j<i; j++)
if (str[i] == str[j] && (i != 11 || j != 10))
return 1;
}
return 0;
} | O0 | c | ft_boolean_check_syntax_string:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x20(%rbp), %rax
cmpl $0x1, 0x98(%rax)
je 0xa1cda
jmp 0xa1ccf
jmp 0xa1cd1
movb $0x1, -0x1(%rbp)
jmp 0xa1db7
cmpq $0x0, -0x10(%rbp)
je 0xa1d08
movq -0x18(%rbp), %rax
addq $0x1, %rax
cmpq $0xf, %rax
jne 0xa1d08
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x20, %eax
je 0xa1d11
movq -0x10(%rbp), %rax
movzbl 0x1(%rax), %eax
cmpl $0x20, %eax
je 0xa1d11
movb $0x1, -0x1(%rbp)
jmp 0xa1db7
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpq $0xf, %rax
jae 0xa1db3
movq -0x10(%rbp), %rax
movl -0x24(%rbp), %ecx
movzbl (%rax,%rcx), %eax
cmpl $0x7f, %eax
jg 0xa1d55
movq -0x20(%rbp), %rax
movq 0x40(%rax), %rax
movq -0x10(%rbp), %rcx
movl -0x24(%rbp), %edx
movzbl (%rcx,%rdx), %ecx
movzbl 0x1(%rax,%rcx), %eax
andl $0x7, %eax
cmpl $0x0, %eax
je 0xa1d5b
movb $0x1, -0x1(%rbp)
jmp 0xa1db7
movl $0x0, -0x28(%rbp)
movl -0x28(%rbp), %eax
cmpl -0x24(%rbp), %eax
jae 0xa1da3
movq -0x10(%rbp), %rax
movl -0x24(%rbp), %ecx
movzbl (%rax,%rcx), %eax
movq -0x10(%rbp), %rcx
movl -0x28(%rbp), %edx
movzbl (%rcx,%rdx), %ecx
cmpl %ecx, %eax
jne 0xa1d96
cmpl $0xb, -0x24(%rbp)
jne 0xa1d90
cmpl $0xa, -0x28(%rbp)
je 0xa1d96
movb $0x1, -0x1(%rbp)
jmp 0xa1db7
jmp 0xa1d98
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0xa1d62
jmp 0xa1da5
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0xa1d18
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
popq %rbp
retq
nopl (%rax)
| ft_boolean_check_syntax_string:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov rax, [rbp+var_20]
cmp dword ptr [rax+98h], 1
jz short loc_A1CDA
jmp short $+2
loc_A1CCF:
jmp short $+2
loc_A1CD1:
mov [rbp+var_1], 1
jmp loc_A1DB7
loc_A1CDA:
cmp [rbp+var_10], 0
jz short loc_A1D08
mov rax, [rbp+var_18]
add rax, 1
cmp rax, 0Fh
jnz short loc_A1D08
mov rax, [rbp+var_10]
movzx eax, byte ptr [rax]
cmp eax, 20h ; ' '
jz short loc_A1D11
mov rax, [rbp+var_10]
movzx eax, byte ptr [rax+1]
cmp eax, 20h ; ' '
jz short loc_A1D11
loc_A1D08:
mov [rbp+var_1], 1
jmp loc_A1DB7
loc_A1D11:
mov [rbp+var_24], 0
loc_A1D18:
mov eax, [rbp+var_24]
cmp rax, 0Fh
jnb loc_A1DB3
mov rax, [rbp+var_10]
mov ecx, [rbp+var_24]
movzx eax, byte ptr [rax+rcx]
cmp eax, 7Fh
jg short loc_A1D55
mov rax, [rbp+var_20]
mov rax, [rax+40h]
mov rcx, [rbp+var_10]
mov edx, [rbp+var_24]
movzx ecx, byte ptr [rcx+rdx]
movzx eax, byte ptr [rax+rcx+1]
and eax, 7
cmp eax, 0
jz short loc_A1D5B
loc_A1D55:
mov [rbp+var_1], 1
jmp short loc_A1DB7
loc_A1D5B:
mov [rbp+var_28], 0
loc_A1D62:
mov eax, [rbp+var_28]
cmp eax, [rbp+var_24]
jnb short loc_A1DA3
mov rax, [rbp+var_10]
mov ecx, [rbp+var_24]
movzx eax, byte ptr [rax+rcx]
mov rcx, [rbp+var_10]
mov edx, [rbp+var_28]
movzx ecx, byte ptr [rcx+rdx]
cmp eax, ecx
jnz short loc_A1D96
cmp [rbp+var_24], 0Bh
jnz short loc_A1D90
cmp [rbp+var_28], 0Ah
jz short loc_A1D96
loc_A1D90:
mov [rbp+var_1], 1
jmp short loc_A1DB7
loc_A1D96:
jmp short $+2
loc_A1D98:
mov eax, [rbp+var_28]
add eax, 1
mov [rbp+var_28], eax
jmp short loc_A1D62
loc_A1DA3:
jmp short $+2
loc_A1DA5:
mov eax, [rbp+var_24]
add eax, 1
mov [rbp+var_24], eax
jmp loc_A1D18
loc_A1DB3:
mov [rbp+var_1], 0
loc_A1DB7:
mov al, [rbp+var_1]
pop rbp
retn
| char ft_boolean_check_syntax_string(_BYTE *a1, long long a2, long long a3)
{
unsigned int j; // [rsp+0h] [rbp-28h]
unsigned int i; // [rsp+4h] [rbp-24h]
if ( *(_DWORD *)(a3 + 152) != 1 )
return 1;
if ( !a1 || a2 != 14 || *a1 != 32 && a1[1] != 32 )
return 1;
for ( i = 0; i < 0xFuLL; ++i )
{
if ( (unsigned __int8)a1[i] > 0x7Fu || (*(_BYTE *)(*(_QWORD *)(a3 + 64) + (unsigned __int8)a1[i] + 1LL) & 7) != 0 )
return 1;
for ( j = 0; j < i; ++j )
{
if ( a1[i] == a1[j] && (i != 11 || j != 10) )
return 1;
}
}
return 0;
}
| ft_boolean_check_syntax_string:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV RAX,qword ptr [RBP + -0x20]
CMP dword ptr [RAX + 0x98],0x1
JZ 0x001a1cda
JMP 0x001a1ccf
LAB_001a1ccf:
JMP 0x001a1cd1
LAB_001a1cd1:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x001a1db7
LAB_001a1cda:
CMP qword ptr [RBP + -0x10],0x0
JZ 0x001a1d08
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x1
CMP RAX,0xf
JNZ 0x001a1d08
MOV RAX,qword ptr [RBP + -0x10]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x20
JZ 0x001a1d11
MOV RAX,qword ptr [RBP + -0x10]
MOVZX EAX,byte ptr [RAX + 0x1]
CMP EAX,0x20
JZ 0x001a1d11
LAB_001a1d08:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x001a1db7
LAB_001a1d11:
MOV dword ptr [RBP + -0x24],0x0
LAB_001a1d18:
MOV EAX,dword ptr [RBP + -0x24]
CMP RAX,0xf
JNC 0x001a1db3
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x24]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
CMP EAX,0x7f
JG 0x001a1d55
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x40]
MOV RCX,qword ptr [RBP + -0x10]
MOV EDX,dword ptr [RBP + -0x24]
MOVZX ECX,byte ptr [RCX + RDX*0x1]
MOVZX EAX,byte ptr [RAX + RCX*0x1 + 0x1]
AND EAX,0x7
CMP EAX,0x0
JZ 0x001a1d5b
LAB_001a1d55:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x001a1db7
LAB_001a1d5b:
MOV dword ptr [RBP + -0x28],0x0
LAB_001a1d62:
MOV EAX,dword ptr [RBP + -0x28]
CMP EAX,dword ptr [RBP + -0x24]
JNC 0x001a1da3
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x24]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV RCX,qword ptr [RBP + -0x10]
MOV EDX,dword ptr [RBP + -0x28]
MOVZX ECX,byte ptr [RCX + RDX*0x1]
CMP EAX,ECX
JNZ 0x001a1d96
CMP dword ptr [RBP + -0x24],0xb
JNZ 0x001a1d90
CMP dword ptr [RBP + -0x28],0xa
JZ 0x001a1d96
LAB_001a1d90:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x001a1db7
LAB_001a1d96:
JMP 0x001a1d98
LAB_001a1d98:
MOV EAX,dword ptr [RBP + -0x28]
ADD EAX,0x1
MOV dword ptr [RBP + -0x28],EAX
JMP 0x001a1d62
LAB_001a1da3:
JMP 0x001a1da5
LAB_001a1da5:
MOV EAX,dword ptr [RBP + -0x24]
ADD EAX,0x1
MOV dword ptr [RBP + -0x24],EAX
JMP 0x001a1d18
LAB_001a1db3:
MOV byte ptr [RBP + -0x1],0x0
LAB_001a1db7:
MOV AL,byte ptr [RBP + -0x1]
POP RBP
RET
|
int1 ft_boolean_check_syntax_string(char *param_1,long param_2,long param_3)
{
uint local_30;
uint local_2c;
int1 local_9;
if (*(int *)(param_3 + 0x98) == 1) {
if (((param_1 == (char *)0x0) || (param_2 != 0xe)) || ((*param_1 != ' ' && (param_1[1] != ' ')))
) {
local_9 = 1;
}
else {
for (local_2c = 0; local_2c < 0xf; local_2c = local_2c + 1) {
if ((0x7f < (byte)param_1[local_2c]) ||
((*(byte *)(*(long *)(param_3 + 0x40) + 1 + (ulong)(byte)param_1[local_2c]) & 7) != 0)) {
return 1;
}
for (local_30 = 0; local_30 < local_2c; local_30 = local_30 + 1) {
if ((param_1[local_2c] == param_1[local_30]) && ((local_2c != 0xb || (local_30 != 10)))) {
return 1;
}
}
}
local_9 = 0;
}
}
else {
local_9 = 1;
}
return local_9;
}
| |
23,351 | ft_boolean_check_syntax_string | eloqsql/storage/myisam/ft_parser.c | my_bool ft_boolean_check_syntax_string(const uchar *str, size_t length,
CHARSET_INFO *cs)
{
uint i, j;
if (cs->mbminlen != 1)
{
DBUG_ASSERT(0);
return 1;
}
if (!str ||
(length + 1 != sizeof(DEFAULT_FTB_SYNTAX)) ||
(str[0] != ' ' && str[1] != ' '))
return 1;
for (i=0; i<sizeof(DEFAULT_FTB_SYNTAX); i++)
{
/* limiting to 7-bit ascii only */
if ((unsigned char)(str[i]) > 127 || my_isalnum(cs, str[i]))
return 1;
for (j=0; j<i; j++)
if (str[i] == str[j] && (i != 11 || j != 10))
return 1;
}
return 0;
} | O3 | c | ft_boolean_check_syntax_string:
cmpl $0x1, 0x98(%rdx)
jne 0x738e6
testq %rdi, %rdi
sete %al
cmpq $0xe, %rsi
setne %cl
orb %al, %cl
jne 0x738e6
cmpb $0x20, (%rdi)
je 0x7388e
cmpb $0x20, 0x1(%rdi)
jne 0x738e6
pushq %rbp
movq %rsp, %rbp
xorl %ecx, %ecx
movsbq (%rdi,%rcx), %rax
testq %rax, %rax
js 0x738e9
movq 0x40(%rdx), %rsi
testb $0x7, 0x1(%rsi,%rax)
jne 0x738e9
testq %rcx, %rcx
je 0x738d9
movq %rcx, %rsi
xorq $0xb, %rsi
xorl %r8d, %r8d
movq %r8, %r9
xorq $0xa, %r9
orq %rsi, %r9
setne %r9b
cmpb (%rdi,%r8), %al
jne 0x738d1
testb %r9b, %r9b
jne 0x738e9
incq %r8
cmpq %r8, %rcx
jne 0x738b8
incq %rcx
xorl %eax, %eax
cmpq $0xf, %rcx
jne 0x73894
jmp 0x738eb
movb $0x1, %al
retq
movb $0x1, %al
popq %rbp
retq
| ft_boolean_check_syntax_string:
cmp dword ptr [rdx+98h], 1
jnz short loc_738E6
test rdi, rdi
setz al
cmp rsi, 0Eh
setnz cl
or cl, al
jnz short loc_738E6
cmp byte ptr [rdi], 20h ; ' '
jz short loc_7388E
cmp byte ptr [rdi+1], 20h ; ' '
jnz short loc_738E6
loc_7388E:
push rbp
mov rbp, rsp
xor ecx, ecx
loc_73894:
movsx rax, byte ptr [rdi+rcx]
test rax, rax
js short loc_738E9
mov rsi, [rdx+40h]
test byte ptr [rsi+rax+1], 7
jnz short loc_738E9
test rcx, rcx
jz short loc_738D9
mov rsi, rcx
xor rsi, 0Bh
xor r8d, r8d
loc_738B8:
mov r9, r8
xor r9, 0Ah
or r9, rsi
setnz r9b
cmp al, [rdi+r8]
jnz short loc_738D1
test r9b, r9b
jnz short loc_738E9
loc_738D1:
inc r8
cmp rcx, r8
jnz short loc_738B8
loc_738D9:
inc rcx
xor eax, eax
cmp rcx, 0Fh
jnz short loc_73894
jmp short loc_738EB
loc_738E6:
mov al, 1
retn
loc_738E9:
mov al, 1
loc_738EB:
pop rbp
retn
| char ft_boolean_check_syntax_string(_BYTE *a1, long long a2, long long a3)
{
long long v3; // rcx
long long v4; // rax
long long v5; // r8
char result; // al
if ( *(_DWORD *)(a3 + 152) != 1 || a1 == 0LL || a2 != 14 || *a1 != 32 && a1[1] != 32 )
return 1;
v3 = 0LL;
while ( 1 )
{
v4 = (char)a1[v3];
if ( v4 < 0 || (*(_BYTE *)(*(_QWORD *)(a3 + 64) + v4 + 1) & 7) != 0 )
return 1;
if ( v3 )
{
v5 = 0LL;
while ( (_BYTE)v4 != a1[v5] || !(v3 ^ 0xB | v5 ^ 0xA) )
{
if ( v3 == ++v5 )
goto LABEL_13;
}
return 1;
}
LABEL_13:
++v3;
result = 0;
if ( v3 == 15 )
return result;
}
}
| ft_boolean_check_syntax_string:
CMP dword ptr [RDX + 0x98],0x1
JNZ 0x001738e6
TEST RDI,RDI
SETZ AL
CMP RSI,0xe
SETNZ CL
OR CL,AL
JNZ 0x001738e6
CMP byte ptr [RDI],0x20
JZ 0x0017388e
CMP byte ptr [RDI + 0x1],0x20
JNZ 0x001738e6
LAB_0017388e:
PUSH RBP
MOV RBP,RSP
XOR ECX,ECX
LAB_00173894:
MOVSX RAX,byte ptr [RDI + RCX*0x1]
TEST RAX,RAX
JS 0x001738e9
MOV RSI,qword ptr [RDX + 0x40]
TEST byte ptr [RSI + RAX*0x1 + 0x1],0x7
JNZ 0x001738e9
TEST RCX,RCX
JZ 0x001738d9
MOV RSI,RCX
XOR RSI,0xb
XOR R8D,R8D
LAB_001738b8:
MOV R9,R8
XOR R9,0xa
OR R9,RSI
SETNZ R9B
CMP AL,byte ptr [RDI + R8*0x1]
JNZ 0x001738d1
TEST R9B,R9B
JNZ 0x001738e9
LAB_001738d1:
INC R8
CMP RCX,R8
JNZ 0x001738b8
LAB_001738d9:
INC RCX
XOR EAX,EAX
CMP RCX,0xf
JNZ 0x00173894
JMP 0x001738eb
LAB_001738e6:
MOV AL,0x1
RET
LAB_001738e9:
MOV AL,0x1
LAB_001738eb:
POP RBP
RET
|
int8 ft_boolean_check_syntax_string(char *param_1,long param_2,long param_3)
{
char cVar1;
long lVar2;
long lVar3;
if (((*(int *)(param_3 + 0x98) == 1) && (param_2 == 0xe && param_1 != (char *)0x0)) &&
((*param_1 == ' ' || (param_1[1] == ' ')))) {
lVar2 = 0;
do {
cVar1 = param_1[lVar2];
if (((long)cVar1 < 0) || ((*(byte *)(*(long *)(param_3 + 0x40) + 1 + (long)cVar1) & 7) != 0))
{
return 1;
}
if (lVar2 != 0) {
lVar3 = 0;
do {
if ((cVar1 == param_1[lVar3]) && (lVar3 != 10 || lVar2 != 0xb)) {
return 1;
}
lVar3 = lVar3 + 1;
} while (lVar2 != lVar3);
}
lVar2 = lVar2 + 1;
if (lVar2 == 0xf) {
return 0;
}
} while( true );
}
return 1;
}
| |
23,352 | MatrixDecompose | csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/raymath.h | RMAPI void MatrixDecompose(Matrix mat, Vector3 *translation, Quaternion *rotation, Vector3 *scale)
{
// Extract translation.
translation->x = mat.m12;
translation->y = mat.m13;
translation->z = mat.m14;
// Extract upper-left for determinant computation
const float a = mat.m0;
const float b = mat.m4;
const float c = mat.m8;
const float d = mat.m1;
const float e = mat.m5;
const float f = mat.m9;
const float g = mat.m2;
const float h = mat.m6;
const float i = mat.m10;
const float A = e*i - f*h;
const float B = f*g - d*i;
const float C = d*h - e*g;
// Extract scale
const float det = a*A + b*B + c*C;
Vector3 abc = { a, b, c };
Vector3 def = { d, e, f };
Vector3 ghi = { g, h, i };
float scalex = Vector3Length(abc);
float scaley = Vector3Length(def);
float scalez = Vector3Length(ghi);
Vector3 s = { scalex, scaley, scalez };
if (det < 0) s = Vector3Negate(s);
*scale = s;
// Remove scale from the matrix if it is not close to zero
Matrix clone = mat;
if (!FloatEquals(det, 0))
{
clone.m0 /= s.x;
clone.m4 /= s.x;
clone.m8 /= s.x;
clone.m1 /= s.y;
clone.m5 /= s.y;
clone.m9 /= s.y;
clone.m2 /= s.z;
clone.m6 /= s.z;
clone.m10 /= s.z;
// Extract rotation
*rotation = QuaternionFromMatrix(clone);
}
else
{
// Set to identity if close to zero
*rotation = QuaternionIdentity();
}
} | O0 | c | MatrixDecompose:
pushq %rbp
movq %rsp, %rbp
subq $0x1b0, %rsp # imm = 0x1B0
leaq 0x10(%rbp), %rax
movq %rax, -0x158(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movss 0xc(%rax), %xmm0
movq -0x8(%rbp), %rcx
movss %xmm0, (%rcx)
movss 0x1c(%rax), %xmm0
movq -0x8(%rbp), %rcx
movss %xmm0, 0x4(%rcx)
movss 0x2c(%rax), %xmm0
movq -0x8(%rbp), %rcx
movss %xmm0, 0x8(%rcx)
movss (%rax), %xmm0
movss %xmm0, -0x1c(%rbp)
movss 0x4(%rax), %xmm0
movss %xmm0, -0x20(%rbp)
movss 0x8(%rax), %xmm0
movss %xmm0, -0x24(%rbp)
movss 0x10(%rax), %xmm0
movss %xmm0, -0x28(%rbp)
movss 0x14(%rax), %xmm0
movss %xmm0, -0x2c(%rbp)
movss 0x18(%rax), %xmm0
movss %xmm0, -0x30(%rbp)
movss 0x20(%rax), %xmm0
movss %xmm0, -0x34(%rbp)
movss 0x24(%rax), %xmm0
movss %xmm0, -0x38(%rbp)
movss 0x28(%rax), %xmm0
movss %xmm0, -0x3c(%rbp)
movss -0x2c(%rbp), %xmm0
movss -0x3c(%rbp), %xmm2
movss -0x30(%rbp), %xmm1
movss -0x38(%rbp), %xmm3
mulss %xmm3, %xmm1
mulss %xmm2, %xmm0
subss %xmm1, %xmm0
movss %xmm0, -0x40(%rbp)
movss -0x30(%rbp), %xmm0
movss -0x34(%rbp), %xmm2
movss -0x28(%rbp), %xmm1
movss -0x3c(%rbp), %xmm3
mulss %xmm3, %xmm1
mulss %xmm2, %xmm0
subss %xmm1, %xmm0
movss %xmm0, -0x44(%rbp)
movss -0x28(%rbp), %xmm0
movss -0x38(%rbp), %xmm2
movss -0x2c(%rbp), %xmm1
movss -0x34(%rbp), %xmm3
mulss %xmm3, %xmm1
mulss %xmm2, %xmm0
subss %xmm1, %xmm0
movss %xmm0, -0x48(%rbp)
movss -0x1c(%rbp), %xmm1
movss -0x40(%rbp), %xmm2
movss -0x20(%rbp), %xmm0
movss -0x44(%rbp), %xmm3
mulss %xmm3, %xmm0
mulss %xmm2, %xmm1
addss %xmm0, %xmm1
movss -0x24(%rbp), %xmm0
movss -0x48(%rbp), %xmm2
mulss %xmm2, %xmm0
addss %xmm1, %xmm0
movss %xmm0, -0x4c(%rbp)
movss -0x1c(%rbp), %xmm0
movss %xmm0, -0x58(%rbp)
movss -0x20(%rbp), %xmm0
movss %xmm0, -0x54(%rbp)
movss -0x24(%rbp), %xmm0
movss %xmm0, -0x50(%rbp)
movss -0x28(%rbp), %xmm0
movss %xmm0, -0x64(%rbp)
movss -0x2c(%rbp), %xmm0
movss %xmm0, -0x60(%rbp)
movss -0x30(%rbp), %xmm0
movss %xmm0, -0x5c(%rbp)
movss -0x34(%rbp), %xmm0
movss %xmm0, -0x70(%rbp)
movss -0x38(%rbp), %xmm0
movss %xmm0, -0x6c(%rbp)
movss -0x3c(%rbp), %xmm0
movss %xmm0, -0x68(%rbp)
movl -0x50(%rbp), %eax
movl %eax, -0x80(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0x88(%rbp)
movsd -0x88(%rbp), %xmm0
movss -0x80(%rbp), %xmm1
callq 0xb95e0
movss %xmm0, -0x74(%rbp)
movl -0x5c(%rbp), %eax
movl %eax, -0x98(%rbp)
movq -0x64(%rbp), %rax
movq %rax, -0xa0(%rbp)
movsd -0xa0(%rbp), %xmm0
movss -0x98(%rbp), %xmm1
callq 0xb95e0
movss %xmm0, -0x8c(%rbp)
movl -0x68(%rbp), %eax
movl %eax, -0xb0(%rbp)
movq -0x70(%rbp), %rax
movq %rax, -0xb8(%rbp)
movsd -0xb8(%rbp), %xmm0
movss -0xb0(%rbp), %xmm1
callq 0xb95e0
movss %xmm0, -0xa4(%rbp)
movss -0x74(%rbp), %xmm0
movss %xmm0, -0xc4(%rbp)
movss -0x8c(%rbp), %xmm0
movss %xmm0, -0xc0(%rbp)
movss -0xa4(%rbp), %xmm0
movss %xmm0, -0xbc(%rbp)
xorps %xmm0, %xmm0
ucomiss -0x4c(%rbp), %xmm0
jbe 0xc26f7
movl -0xbc(%rbp), %eax
movl %eax, -0xd8(%rbp)
movq -0xc4(%rbp), %rax
movq %rax, -0xe0(%rbp)
movsd -0xe0(%rbp), %xmm0
movss -0xd8(%rbp), %xmm1
callq 0xb99e0
movss %xmm1, -0xe8(%rbp)
movlpd %xmm0, -0xf0(%rbp)
movq -0xf0(%rbp), %rax
movq %rax, -0xd0(%rbp)
movl -0xe8(%rbp), %eax
movl %eax, -0xc8(%rbp)
movq -0xd0(%rbp), %rax
movq %rax, -0xc4(%rbp)
movl -0xc8(%rbp), %eax
movl %eax, -0xbc(%rbp)
movq -0x158(%rbp), %rsi
movq -0x18(%rbp), %rax
movq -0xc4(%rbp), %rcx
movq %rcx, (%rax)
movl -0xbc(%rbp), %ecx
movl %ecx, 0x8(%rax)
leaq -0x130(%rbp), %rdi
movl $0x40, %edx
callq 0xa400
movss -0x4c(%rbp), %xmm0
xorps %xmm1, %xmm1
callq 0xb81b0
cmpl $0x0, %eax
jne 0xc28a4
movss -0xc4(%rbp), %xmm1
movss -0x130(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x130(%rbp)
movss -0xc4(%rbp), %xmm1
movss -0x12c(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x12c(%rbp)
movss -0xc4(%rbp), %xmm1
movss -0x128(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x128(%rbp)
movss -0xc0(%rbp), %xmm1
movss -0x120(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x120(%rbp)
movss -0xc0(%rbp), %xmm1
movss -0x11c(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x11c(%rbp)
movss -0xc0(%rbp), %xmm1
movss -0x118(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x118(%rbp)
movss -0xbc(%rbp), %xmm1
movss -0x110(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x110(%rbp)
movss -0xbc(%rbp), %xmm1
movss -0x10c(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x10c(%rbp)
movss -0xbc(%rbp), %xmm1
movss -0x108(%rbp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, -0x108(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x160(%rbp)
movups -0x130(%rbp), %xmm0
movups -0x120(%rbp), %xmm1
movups -0x110(%rbp), %xmm2
movups -0x100(%rbp), %xmm3
movq %rsp, %rax
movups %xmm3, 0x30(%rax)
movups %xmm2, 0x20(%rax)
movups %xmm1, 0x10(%rax)
movups %xmm0, (%rax)
callq 0xc1300
movq -0x160(%rbp), %rax
movlpd %xmm0, -0x140(%rbp)
movlpd %xmm1, -0x138(%rbp)
movq -0x140(%rbp), %rcx
movq %rcx, (%rax)
movq -0x138(%rbp), %rcx
movq %rcx, 0x8(%rax)
jmp 0xc28e0
movq -0x10(%rbp), %rax
movq %rax, -0x168(%rbp)
callq 0xc03c0
movq -0x168(%rbp), %rax
movlpd %xmm0, -0x150(%rbp)
movlpd %xmm1, -0x148(%rbp)
movq -0x150(%rbp), %rcx
movq %rcx, (%rax)
movq -0x148(%rbp), %rcx
movq %rcx, 0x8(%rax)
addq $0x1b0, %rsp # imm = 0x1B0
popq %rbp
retq
nopl (%rax)
| MatrixDecompose:
push rbp
mov rbp, rsp
sub rsp, 1B0h
lea rax, [rbp+arg_0]
mov [rbp+var_158], rax
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
movss xmm0, dword ptr [rax+0Ch]
mov rcx, [rbp+var_8]
movss dword ptr [rcx], xmm0
movss xmm0, dword ptr [rax+1Ch]
mov rcx, [rbp+var_8]
movss dword ptr [rcx+4], xmm0
movss xmm0, dword ptr [rax+2Ch]
mov rcx, [rbp+var_8]
movss dword ptr [rcx+8], xmm0
movss xmm0, dword ptr [rax]
movss [rbp+var_1C], xmm0
movss xmm0, dword ptr [rax+4]
movss [rbp+var_20], xmm0
movss xmm0, dword ptr [rax+8]
movss [rbp+var_24], xmm0
movss xmm0, dword ptr [rax+10h]
movss [rbp+var_28], xmm0
movss xmm0, dword ptr [rax+14h]
movss [rbp+var_2C], xmm0
movss xmm0, dword ptr [rax+18h]
movss [rbp+var_30], xmm0
movss xmm0, dword ptr [rax+20h]
movss [rbp+var_34], xmm0
movss xmm0, dword ptr [rax+24h]
movss [rbp+var_38], xmm0
movss xmm0, dword ptr [rax+28h]
movss [rbp+var_3C], xmm0
movss xmm0, [rbp+var_2C]
movss xmm2, [rbp+var_3C]
movss xmm1, [rbp+var_30]
movss xmm3, [rbp+var_38]
mulss xmm1, xmm3
mulss xmm0, xmm2
subss xmm0, xmm1
movss [rbp+var_40], xmm0
movss xmm0, [rbp+var_30]
movss xmm2, [rbp+var_34]
movss xmm1, [rbp+var_28]
movss xmm3, [rbp+var_3C]
mulss xmm1, xmm3
mulss xmm0, xmm2
subss xmm0, xmm1
movss [rbp+var_44], xmm0
movss xmm0, [rbp+var_28]
movss xmm2, [rbp+var_38]
movss xmm1, [rbp+var_2C]
movss xmm3, [rbp+var_34]
mulss xmm1, xmm3
mulss xmm0, xmm2
subss xmm0, xmm1
movss [rbp+var_48], xmm0
movss xmm1, [rbp+var_1C]
movss xmm2, [rbp+var_40]
movss xmm0, [rbp+var_20]
movss xmm3, [rbp+var_44]
mulss xmm0, xmm3
mulss xmm1, xmm2
addss xmm1, xmm0
movss xmm0, [rbp+var_24]
movss xmm2, [rbp+var_48]
mulss xmm0, xmm2
addss xmm0, xmm1
movss [rbp+var_4C], xmm0
movss xmm0, [rbp+var_1C]
movss dword ptr [rbp+var_58], xmm0
movss xmm0, [rbp+var_20]
movss dword ptr [rbp+var_58+4], xmm0
movss xmm0, [rbp+var_24]
movss [rbp+var_50], xmm0
movss xmm0, [rbp+var_28]
movss dword ptr [rbp+var_64], xmm0
movss xmm0, [rbp+var_2C]
movss dword ptr [rbp+var_64+4], xmm0
movss xmm0, [rbp+var_30]
movss [rbp+var_5C], xmm0
movss xmm0, [rbp+var_34]
movss dword ptr [rbp+var_70], xmm0
movss xmm0, [rbp+var_38]
movss dword ptr [rbp+var_70+4], xmm0
movss xmm0, [rbp+var_3C]
movss [rbp+var_68], xmm0
mov eax, [rbp+var_50]
mov [rbp+var_80], eax
mov rax, [rbp+var_58]
mov [rbp+var_88], rax
movsd xmm0, [rbp+var_88]
movss xmm1, [rbp+var_80]
call Vector3Length
movss [rbp+var_74], xmm0
mov eax, [rbp+var_5C]
mov [rbp+var_98], eax
mov rax, [rbp+var_64]
mov [rbp+var_A0], rax
movsd xmm0, [rbp+var_A0]
movss xmm1, [rbp+var_98]
call Vector3Length
movss [rbp+var_8C], xmm0
mov eax, [rbp+var_68]
mov [rbp+var_B0], eax
mov rax, [rbp+var_70]
mov [rbp+var_B8], rax
movsd xmm0, [rbp+var_B8]
movss xmm1, [rbp+var_B0]
call Vector3Length
movss [rbp+var_A4], xmm0
movss xmm0, [rbp+var_74]
movss dword ptr [rbp+var_C4], xmm0
movss xmm0, [rbp+var_8C]
movss dword ptr [rbp+var_C4+4], xmm0
movss xmm0, [rbp+var_A4]
movss [rbp+var_BC], xmm0
xorps xmm0, xmm0
ucomiss xmm0, [rbp+var_4C]
jbe short loc_C26F7
mov eax, [rbp+var_BC]
mov [rbp+var_D8], eax
mov rax, [rbp+var_C4]
mov [rbp+var_E0], rax
movsd xmm0, [rbp+var_E0]
movss xmm1, [rbp+var_D8]
call Vector3Negate
movss [rbp+var_E8], xmm1
movlpd [rbp+var_F0], xmm0
mov rax, [rbp+var_F0]
mov [rbp+var_D0], rax
mov eax, [rbp+var_E8]
mov [rbp+var_C8], eax
mov rax, [rbp+var_D0]
mov [rbp+var_C4], rax
mov eax, [rbp+var_C8]
mov [rbp+var_BC], eax
loc_C26F7:
mov rsi, [rbp+var_158]
mov rax, [rbp+var_18]
mov rcx, [rbp+var_C4]
mov [rax], rcx
mov ecx, [rbp+var_BC]
mov [rax+8], ecx
lea rdi, [rbp+var_130]
mov edx, 40h ; '@'
call _memcpy
movss xmm0, [rbp+var_4C]
xorps xmm1, xmm1
call FloatEquals
cmp eax, 0
jnz loc_C28A4
movss xmm1, dword ptr [rbp+var_C4]
movss xmm0, dword ptr [rbp+var_130]
divss xmm0, xmm1
movss dword ptr [rbp+var_130], xmm0
movss xmm1, dword ptr [rbp+var_C4]
movss xmm0, dword ptr [rbp+var_130+4]
divss xmm0, xmm1
movss dword ptr [rbp+var_130+4], xmm0
movss xmm1, dword ptr [rbp+var_C4]
movss xmm0, dword ptr [rbp+var_130+8]
divss xmm0, xmm1
movss dword ptr [rbp+var_130+8], xmm0
movss xmm1, dword ptr [rbp+var_C4+4]
movss xmm0, dword ptr [rbp+var_120]
divss xmm0, xmm1
movss dword ptr [rbp+var_120], xmm0
movss xmm1, dword ptr [rbp+var_C4+4]
movss xmm0, dword ptr [rbp+var_120+4]
divss xmm0, xmm1
movss dword ptr [rbp+var_120+4], xmm0
movss xmm1, dword ptr [rbp+var_C4+4]
movss xmm0, dword ptr [rbp+var_120+8]
divss xmm0, xmm1
movss dword ptr [rbp+var_120+8], xmm0
movss xmm1, [rbp+var_BC]
movss xmm0, dword ptr [rbp+var_110]
divss xmm0, xmm1
movss dword ptr [rbp+var_110], xmm0
movss xmm1, [rbp+var_BC]
movss xmm0, dword ptr [rbp+var_110+4]
divss xmm0, xmm1
movss dword ptr [rbp+var_110+4], xmm0
movss xmm1, [rbp+var_BC]
movss xmm0, dword ptr [rbp+var_110+8]
divss xmm0, xmm1
movss dword ptr [rbp+var_110+8], xmm0
mov rax, [rbp+var_10]
mov [rbp+var_160], rax
movups xmm0, [rbp+var_130]
movups xmm1, [rbp+var_120]
movups xmm2, [rbp+var_110]
movups xmm3, [rbp+var_100]
mov rax, rsp
movups xmmword ptr [rax+30h], xmm3
movups xmmword ptr [rax+20h], xmm2
movups xmmword ptr [rax+10h], xmm1
movups xmmword ptr [rax], xmm0
call QuaternionFromMatrix
mov rax, [rbp+var_160]
movlpd [rbp+var_140], xmm0
movlpd [rbp+var_138], xmm1
mov rcx, [rbp+var_140]
mov [rax], rcx
mov rcx, [rbp+var_138]
mov [rax+8], rcx
jmp short loc_C28E0
loc_C28A4:
mov rax, [rbp+var_10]
mov [rbp+var_168], rax
call QuaternionIdentity
mov rax, [rbp+var_168]
movlpd [rbp+var_150], xmm0
movlpd [rbp+var_148], xmm1
mov rcx, [rbp+var_150]
mov [rax], rcx
mov rcx, [rbp+var_148]
mov [rax+8], rcx
loc_C28E0:
add rsp, 1B0h
pop rbp
retn
| double * MatrixDecompose(
_DWORD *a1,
double *a2,
double *a3,
double a4,
double a5,
double a6,
double a7,
double a8,
double a9,
double a10,
double a11,
long long a12,
long long a13,
long long a14,
double a15,
long long a16,
double a17,
long long a18,
double a19,
long long a20)
{
unsigned int v20; // xmm0_4
double *v21; // rax
long long v22; // rdx
long long v23; // rcx
long long v24; // r8
long long v25; // r9
double v26; // xmm4_8
double v27; // xmm5_8
double v28; // xmm1_8
double v29; // xmm0_8
double *result; // rax
double v31; // xmm0_8
double *v32; // [rsp+48h] [rbp-168h]
double *v33; // [rsp+50h] [rbp-160h]
double v34; // [rsp+80h] [rbp-130h] BYREF
float v35; // [rsp+88h] [rbp-128h]
double v36; // [rsp+90h] [rbp-120h]
float v37; // [rsp+98h] [rbp-118h]
double v38; // [rsp+A0h] [rbp-110h]
float v39; // [rsp+A8h] [rbp-108h]
__int128 v40; // [rsp+B0h] [rbp-100h]
double v41; // [rsp+C0h] [rbp-F0h]
float v42; // [rsp+C8h] [rbp-E8h]
double v43; // [rsp+D0h] [rbp-E0h]
float v44; // [rsp+D8h] [rbp-D8h]
double v45; // [rsp+E0h] [rbp-D0h]
float v46; // [rsp+E8h] [rbp-C8h]
double v47; // [rsp+ECh] [rbp-C4h]
float v48; // [rsp+F4h] [rbp-BCh]
double v49; // [rsp+F8h] [rbp-B8h]
float v50; // [rsp+100h] [rbp-B0h]
int v51; // [rsp+10Ch] [rbp-A4h]
double v52; // [rsp+110h] [rbp-A0h]
float v53; // [rsp+118h] [rbp-98h]
int v54; // [rsp+124h] [rbp-8Ch]
double v55; // [rsp+128h] [rbp-88h]
int v56; // [rsp+130h] [rbp-80h]
unsigned int v57; // [rsp+13Ch] [rbp-74h]
double v58; // [rsp+140h] [rbp-70h]
float v59; // [rsp+148h] [rbp-68h]
double v60; // [rsp+14Ch] [rbp-64h]
float v61; // [rsp+154h] [rbp-5Ch]
double v62; // [rsp+158h] [rbp-58h]
int v63; // [rsp+160h] [rbp-50h]
float v64; // [rsp+164h] [rbp-4Ch]
float v65; // [rsp+168h] [rbp-48h]
float v66; // [rsp+16Ch] [rbp-44h]
float v67; // [rsp+170h] [rbp-40h]
int v68; // [rsp+174h] [rbp-3Ch]
int v69; // [rsp+178h] [rbp-38h]
int v70; // [rsp+17Ch] [rbp-34h]
int v71; // [rsp+180h] [rbp-30h]
int v72; // [rsp+184h] [rbp-2Ch]
int v73; // [rsp+188h] [rbp-28h]
int v74; // [rsp+18Ch] [rbp-24h]
int v75; // [rsp+190h] [rbp-20h]
int v76; // [rsp+194h] [rbp-1Ch]
double *v77; // [rsp+198h] [rbp-18h]
double *v78; // [rsp+1A0h] [rbp-10h]
_DWORD *v79; // [rsp+1A8h] [rbp-8h]
v79 = a1;
v78 = a2;
v77 = a3;
*a1 = HIDWORD(a16);
v79[1] = HIDWORD(a18);
v79[2] = HIDWORD(a20);
v75 = HIDWORD(a15);
v76 = LODWORD(a15);
v74 = a16;
v72 = HIDWORD(a17);
v73 = LODWORD(a17);
v71 = a18;
v69 = HIDWORD(a19);
v70 = LODWORD(a19);
v68 = a20;
v67 = (float)(*((float *)&a17 + 1) * *(float *)&a20) - (float)(*(float *)&a18 * *((float *)&a19 + 1));
v66 = (float)(*(float *)&a18 * *(float *)&a19) - (float)(*(float *)&a17 * *(float *)&a20);
v65 = (float)(*(float *)&a17 * *((float *)&a19 + 1)) - (float)(*((float *)&a17 + 1) * *(float *)&a19);
v64 = (float)(*(float *)&a16 * v65) + (float)((float)(*(float *)&a15 * v67) + (float)(*((float *)&a15 + 1) * v66));
v62 = a15;
v63 = a16;
v60 = a17;
v61 = *(float *)&a18;
v58 = a19;
v59 = *(float *)&a20;
v56 = a16;
v55 = a15;
v20 = LODWORD(a15);
Vector3Length(a15, *(float *)&a16);
v57 = v20;
v53 = v61;
v52 = v60;
Vector3Length(v60, v61);
v54 = LODWORD(v60);
v50 = v59;
v49 = v58;
Vector3Length(v58, v59);
v51 = LODWORD(v58);
v47 = COERCE_DOUBLE(__PAIR64__(LODWORD(v60), v20));
v48 = *(float *)&v58;
if ( v64 < 0.0 )
{
v44 = v48;
v43 = v47;
v42 = v48;
v41 = Vector3Negate(v47);
v45 = v41;
v46 = v48;
v47 = v41;
}
v21 = v77;
*v77 = v47;
*((float *)v21 + 2) = v48;
memcpy(&v34, &a15, 64LL);
if ( FloatEquals(v64, 0.0) )
{
v32 = v78;
v31 = QuaternionIdentity();
result = v32;
*v32 = v31;
v32[1] = 0.0;
}
else
{
*(float *)&v34 = *(float *)&v34 / *(float *)&v47;
*((float *)&v34 + 1) = *((float *)&v34 + 1) / *(float *)&v47;
v35 = v35 / *(float *)&v47;
*(float *)&v36 = *(float *)&v36 / *((float *)&v47 + 1);
*((float *)&v36 + 1) = *((float *)&v36 + 1) / *((float *)&v47 + 1);
v37 = v37 / *((float *)&v47 + 1);
*(float *)&v38 = *(float *)&v38 / v48;
*((float *)&v38 + 1) = *((float *)&v38 + 1) / v48;
v39 = v39 / v48;
v33 = v78;
v28 = v36;
v29 = QuaternionFromMatrix(
(long long)&v34,
(long long)&a15,
v22,
v23,
v24,
v25,
v34,
v36,
v38,
*(double *)&v40,
v26,
v27,
a10,
a11,
*(long long *)&v34,
v35,
*(long long *)&v36,
v37,
*(long long *)&v38,
v39);
result = v33;
*v33 = v29;
v33[1] = v28;
}
return result;
}
| MatrixDecompose:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x1b0
LEA RAX,[RBP + 0x10]
MOV qword ptr [RBP + -0x158],RAX
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOVSS XMM0,dword ptr [RAX + 0xc]
MOV RCX,qword ptr [RBP + -0x8]
MOVSS dword ptr [RCX],XMM0
MOVSS XMM0,dword ptr [RAX + 0x1c]
MOV RCX,qword ptr [RBP + -0x8]
MOVSS dword ptr [RCX + 0x4],XMM0
MOVSS XMM0,dword ptr [RAX + 0x2c]
MOV RCX,qword ptr [RBP + -0x8]
MOVSS dword ptr [RCX + 0x8],XMM0
MOVSS XMM0,dword ptr [RAX]
MOVSS dword ptr [RBP + -0x1c],XMM0
MOVSS XMM0,dword ptr [RAX + 0x4]
MOVSS dword ptr [RBP + -0x20],XMM0
MOVSS XMM0,dword ptr [RAX + 0x8]
MOVSS dword ptr [RBP + -0x24],XMM0
MOVSS XMM0,dword ptr [RAX + 0x10]
MOVSS dword ptr [RBP + -0x28],XMM0
MOVSS XMM0,dword ptr [RAX + 0x14]
MOVSS dword ptr [RBP + -0x2c],XMM0
MOVSS XMM0,dword ptr [RAX + 0x18]
MOVSS dword ptr [RBP + -0x30],XMM0
MOVSS XMM0,dword ptr [RAX + 0x20]
MOVSS dword ptr [RBP + -0x34],XMM0
MOVSS XMM0,dword ptr [RAX + 0x24]
MOVSS dword ptr [RBP + -0x38],XMM0
MOVSS XMM0,dword ptr [RAX + 0x28]
MOVSS dword ptr [RBP + -0x3c],XMM0
MOVSS XMM0,dword ptr [RBP + -0x2c]
MOVSS XMM2,dword ptr [RBP + -0x3c]
MOVSS XMM1,dword ptr [RBP + -0x30]
MOVSS XMM3,dword ptr [RBP + -0x38]
MULSS XMM1,XMM3
MULSS XMM0,XMM2
SUBSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x40],XMM0
MOVSS XMM0,dword ptr [RBP + -0x30]
MOVSS XMM2,dword ptr [RBP + -0x34]
MOVSS XMM1,dword ptr [RBP + -0x28]
MOVSS XMM3,dword ptr [RBP + -0x3c]
MULSS XMM1,XMM3
MULSS XMM0,XMM2
SUBSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x44],XMM0
MOVSS XMM0,dword ptr [RBP + -0x28]
MOVSS XMM2,dword ptr [RBP + -0x38]
MOVSS XMM1,dword ptr [RBP + -0x2c]
MOVSS XMM3,dword ptr [RBP + -0x34]
MULSS XMM1,XMM3
MULSS XMM0,XMM2
SUBSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x48],XMM0
MOVSS XMM1,dword ptr [RBP + -0x1c]
MOVSS XMM2,dword ptr [RBP + -0x40]
MOVSS XMM0,dword ptr [RBP + -0x20]
MOVSS XMM3,dword ptr [RBP + -0x44]
MULSS XMM0,XMM3
MULSS XMM1,XMM2
ADDSS XMM1,XMM0
MOVSS XMM0,dword ptr [RBP + -0x24]
MOVSS XMM2,dword ptr [RBP + -0x48]
MULSS XMM0,XMM2
ADDSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x4c],XMM0
MOVSS XMM0,dword ptr [RBP + -0x1c]
MOVSS dword ptr [RBP + -0x58],XMM0
MOVSS XMM0,dword ptr [RBP + -0x20]
MOVSS dword ptr [RBP + -0x54],XMM0
MOVSS XMM0,dword ptr [RBP + -0x24]
MOVSS dword ptr [RBP + -0x50],XMM0
MOVSS XMM0,dword ptr [RBP + -0x28]
MOVSS dword ptr [RBP + -0x64],XMM0
MOVSS XMM0,dword ptr [RBP + -0x2c]
MOVSS dword ptr [RBP + -0x60],XMM0
MOVSS XMM0,dword ptr [RBP + -0x30]
MOVSS dword ptr [RBP + -0x5c],XMM0
MOVSS XMM0,dword ptr [RBP + -0x34]
MOVSS dword ptr [RBP + -0x70],XMM0
MOVSS XMM0,dword ptr [RBP + -0x38]
MOVSS dword ptr [RBP + -0x6c],XMM0
MOVSS XMM0,dword ptr [RBP + -0x3c]
MOVSS dword ptr [RBP + -0x68],XMM0
MOV EAX,dword ptr [RBP + -0x50]
MOV dword ptr [RBP + -0x80],EAX
MOV RAX,qword ptr [RBP + -0x58]
MOV qword ptr [RBP + -0x88],RAX
MOVSD XMM0,qword ptr [RBP + -0x88]
MOVSS XMM1,dword ptr [RBP + -0x80]
CALL 0x001b95e0
MOVSS dword ptr [RBP + -0x74],XMM0
MOV EAX,dword ptr [RBP + -0x5c]
MOV dword ptr [RBP + -0x98],EAX
MOV RAX,qword ptr [RBP + -0x64]
MOV qword ptr [RBP + -0xa0],RAX
MOVSD XMM0,qword ptr [RBP + -0xa0]
MOVSS XMM1,dword ptr [RBP + -0x98]
CALL 0x001b95e0
MOVSS dword ptr [RBP + -0x8c],XMM0
MOV EAX,dword ptr [RBP + -0x68]
MOV dword ptr [RBP + -0xb0],EAX
MOV RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RBP + -0xb8],RAX
MOVSD XMM0,qword ptr [RBP + -0xb8]
MOVSS XMM1,dword ptr [RBP + -0xb0]
CALL 0x001b95e0
MOVSS dword ptr [RBP + -0xa4],XMM0
MOVSS XMM0,dword ptr [RBP + -0x74]
MOVSS dword ptr [RBP + -0xc4],XMM0
MOVSS XMM0,dword ptr [RBP + -0x8c]
MOVSS dword ptr [RBP + -0xc0],XMM0
MOVSS XMM0,dword ptr [RBP + -0xa4]
MOVSS dword ptr [RBP + -0xbc],XMM0
XORPS XMM0,XMM0
UCOMISS XMM0,dword ptr [RBP + -0x4c]
JBE 0x001c26f7
MOV EAX,dword ptr [RBP + -0xbc]
MOV dword ptr [RBP + -0xd8],EAX
MOV RAX,qword ptr [RBP + -0xc4]
MOV qword ptr [RBP + -0xe0],RAX
MOVSD XMM0,qword ptr [RBP + -0xe0]
MOVSS XMM1,dword ptr [RBP + -0xd8]
CALL 0x001b99e0
MOVSS dword ptr [RBP + -0xe8],XMM1
MOVLPD qword ptr [RBP + -0xf0],XMM0
MOV RAX,qword ptr [RBP + -0xf0]
MOV qword ptr [RBP + -0xd0],RAX
MOV EAX,dword ptr [RBP + -0xe8]
MOV dword ptr [RBP + -0xc8],EAX
MOV RAX,qword ptr [RBP + -0xd0]
MOV qword ptr [RBP + -0xc4],RAX
MOV EAX,dword ptr [RBP + -0xc8]
MOV dword ptr [RBP + -0xbc],EAX
LAB_001c26f7:
MOV RSI,qword ptr [RBP + -0x158]
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0xc4]
MOV qword ptr [RAX],RCX
MOV ECX,dword ptr [RBP + -0xbc]
MOV dword ptr [RAX + 0x8],ECX
LEA RDI,[RBP + -0x130]
MOV EDX,0x40
CALL 0x0010a400
MOVSS XMM0,dword ptr [RBP + -0x4c]
XORPS XMM1,XMM1
CALL 0x001b81b0
CMP EAX,0x0
JNZ 0x001c28a4
MOVSS XMM1,dword ptr [RBP + -0xc4]
MOVSS XMM0,dword ptr [RBP + -0x130]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x130],XMM0
MOVSS XMM1,dword ptr [RBP + -0xc4]
MOVSS XMM0,dword ptr [RBP + -0x12c]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x12c],XMM0
MOVSS XMM1,dword ptr [RBP + -0xc4]
MOVSS XMM0,dword ptr [RBP + -0x128]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x128],XMM0
MOVSS XMM1,dword ptr [RBP + -0xc0]
MOVSS XMM0,dword ptr [RBP + -0x120]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x120],XMM0
MOVSS XMM1,dword ptr [RBP + -0xc0]
MOVSS XMM0,dword ptr [RBP + -0x11c]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x11c],XMM0
MOVSS XMM1,dword ptr [RBP + -0xc0]
MOVSS XMM0,dword ptr [RBP + -0x118]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x118],XMM0
MOVSS XMM1,dword ptr [RBP + -0xbc]
MOVSS XMM0,dword ptr [RBP + -0x110]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x110],XMM0
MOVSS XMM1,dword ptr [RBP + -0xbc]
MOVSS XMM0,dword ptr [RBP + -0x10c]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x10c],XMM0
MOVSS XMM1,dword ptr [RBP + -0xbc]
MOVSS XMM0,dword ptr [RBP + -0x108]
DIVSS XMM0,XMM1
MOVSS dword ptr [RBP + -0x108],XMM0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x160],RAX
MOVUPS XMM0,xmmword ptr [RBP + -0x130]
MOVUPS XMM1,xmmword ptr [RBP + -0x120]
MOVUPS XMM2,xmmword ptr [RBP + -0x110]
MOVUPS XMM3,xmmword ptr [RBP + -0x100]
MOV RAX,RSP
MOVUPS xmmword ptr [RAX + 0x30],XMM3
MOVUPS xmmword ptr [RAX + 0x20],XMM2
MOVUPS xmmword ptr [RAX + 0x10],XMM1
MOVUPS xmmword ptr [RAX],XMM0
CALL 0x001c1300
MOV RAX,qword ptr [RBP + -0x160]
MOVLPD qword ptr [RBP + -0x140],XMM0
MOVLPD qword ptr [RBP + -0x138],XMM1
MOV RCX,qword ptr [RBP + -0x140]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x138]
MOV qword ptr [RAX + 0x8],RCX
JMP 0x001c28e0
LAB_001c28a4:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x168],RAX
CALL 0x001c03c0
MOV RAX,qword ptr [RBP + -0x168]
MOVLPD qword ptr [RBP + -0x150],XMM0
MOVLPD qword ptr [RBP + -0x148],XMM1
MOV RCX,qword ptr [RBP + -0x150]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x148]
MOV qword ptr [RAX + 0x8],RCX
LAB_001c28e0:
ADD RSP,0x1b0
POP RBP
RET
|
void MatrixDecompose(int4 *param_1,int8 *param_2,int8 *param_3)
{
int8 uVar1;
int8 *puVar2;
int iVar3;
float fVar4;
float fVar5;
int4 uVar6;
int4 uVar7;
float fStack0000000000000008;
float fStack000000000000000c;
float fStack0000000000000010;
int4 uStack0000000000000014;
float fStack0000000000000018;
float fStack000000000000001c;
float fStack0000000000000020;
int4 uStack0000000000000024;
float fStack0000000000000028;
float fStack000000000000002c;
float fStack0000000000000030;
int4 uStack0000000000000034;
float local_138;
float fStack_134;
float fStack_130;
float local_128;
float fStack_124;
float fStack_120;
float local_118;
float fStack_114;
float fStack_110;
int8 local_f8;
float local_f0;
int8 local_e8;
float local_e0;
int8 local_d8;
float local_d0;
int8 local_cc;
float local_c4;
int8 local_c0;
float local_b8;
float local_ac;
int8 local_a8;
float local_a0;
int4 local_94;
int8 local_90;
float local_88;
int4 local_7c;
float local_78;
float fStack_74;
float local_70;
float local_6c;
float fStack_68;
float local_64;
float local_60;
float local_58;
float local_54;
float local_50;
float local_4c;
float local_48;
float local_44;
float local_3c;
float local_38;
float local_30;
float local_2c;
float local_24;
int8 *local_20;
int8 *local_18;
int4 *local_10;
*param_1 = uStack0000000000000014;
param_1[1] = uStack0000000000000024;
param_1[2] = uStack0000000000000034;
local_24 = fStack0000000000000008;
local_2c = fStack0000000000000010;
local_30 = fStack0000000000000018;
local_38 = fStack0000000000000020;
local_3c = fStack0000000000000028;
local_44 = fStack0000000000000030;
local_48 = fStack000000000000001c * fStack0000000000000030 -
fStack0000000000000020 * fStack000000000000002c;
local_4c = fStack0000000000000020 * fStack0000000000000028 -
fStack0000000000000018 * fStack0000000000000030;
local_50 = fStack0000000000000018 * fStack000000000000002c -
fStack000000000000001c * fStack0000000000000028;
local_54 = fStack0000000000000010 * local_50 +
fStack0000000000000008 * local_48 + fStack000000000000000c * local_4c;
local_60 = fStack0000000000000008;
local_58 = fStack0000000000000010;
local_6c = fStack0000000000000018;
fStack_68 = fStack000000000000001c;
local_64 = fStack0000000000000020;
local_78 = fStack0000000000000028;
fStack_74 = fStack000000000000002c;
local_70 = fStack0000000000000030;
local_88 = fStack0000000000000010;
local_90 = _fStack0000000000000008;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
local_7c = Vector3Length(fStack0000000000000008,fStack0000000000000010);
local_a0 = local_64;
local_a8 = CONCAT44(fStack_68,local_6c);
local_94 = Vector3Length(local_6c,local_64);
local_b8 = local_70;
local_c0 = CONCAT44(fStack_74,local_78);
local_c4 = (float)Vector3Length(local_78);
local_cc = CONCAT44(local_94,local_7c);
local_ac = local_c4;
if (local_54 < 0.0) {
local_e8 = local_cc;
local_e0 = local_c4;
local_f8 = Vector3Negate(local_7c);
local_f0 = local_c4;
local_d8 = local_f8;
local_d0 = local_c4;
local_cc = local_f8;
}
*local_20 = local_cc;
*(float *)(local_20 + 1) = local_c4;
memcpy(&local_138,&stack0x00000008,0x40);
uVar6 = 0;
uVar7 = 0;
iVar3 = FloatEquals(local_54);
puVar2 = local_18;
if (iVar3 == 0) {
local_138 = local_138 / (float)local_cc;
fStack_134 = fStack_134 / (float)local_cc;
fStack_130 = fStack_130 / (float)local_cc;
fVar4 = local_128 / local_cc._4_4_;
fVar5 = fStack_124 / local_cc._4_4_;
fStack_120 = fStack_120 / local_cc._4_4_;
local_118 = local_118 / local_c4;
fStack_114 = fStack_114 / local_c4;
fStack_110 = fStack_110 / local_c4;
local_128 = fVar4;
fStack_124 = fVar5;
uVar1 = QuaternionFromMatrix();
*puVar2 = uVar1;
puVar2[1] = CONCAT44(fVar5,fVar4);
}
else {
uVar1 = QuaternionIdentity();
*puVar2 = uVar1;
puVar2[1] = CONCAT44(uVar7,uVar6);
}
return;
}
| |
23,353 | MatrixDecompose | csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/raymath.h | RMAPI void MatrixDecompose(Matrix mat, Vector3 *translation, Quaternion *rotation, Vector3 *scale)
{
// Extract translation.
translation->x = mat.m12;
translation->y = mat.m13;
translation->z = mat.m14;
// Extract upper-left for determinant computation
const float a = mat.m0;
const float b = mat.m4;
const float c = mat.m8;
const float d = mat.m1;
const float e = mat.m5;
const float f = mat.m9;
const float g = mat.m2;
const float h = mat.m6;
const float i = mat.m10;
const float A = e*i - f*h;
const float B = f*g - d*i;
const float C = d*h - e*g;
// Extract scale
const float det = a*A + b*B + c*C;
Vector3 abc = { a, b, c };
Vector3 def = { d, e, f };
Vector3 ghi = { g, h, i };
float scalex = Vector3Length(abc);
float scaley = Vector3Length(def);
float scalez = Vector3Length(ghi);
Vector3 s = { scalex, scaley, scalez };
if (det < 0) s = Vector3Negate(s);
*scale = s;
// Remove scale from the matrix if it is not close to zero
Matrix clone = mat;
if (!FloatEquals(det, 0))
{
clone.m0 /= s.x;
clone.m4 /= s.x;
clone.m8 /= s.x;
clone.m1 /= s.y;
clone.m5 /= s.y;
clone.m9 /= s.y;
clone.m2 /= s.z;
clone.m6 /= s.z;
clone.m10 /= s.z;
// Extract rotation
*rotation = QuaternionFromMatrix(clone);
}
else
{
// Set to identity if close to zero
*rotation = QuaternionIdentity();
}
} | O2 | c | MatrixDecompose:
pushq %rbx
subq $0x80, %rsp
movq %rsi, %rbx
movss 0x9c(%rsp), %xmm0
movss %xmm0, (%rdi)
movss 0xac(%rsp), %xmm0
movss %xmm0, 0x4(%rdi)
movss 0xbc(%rsp), %xmm0
movss %xmm0, 0x8(%rdi)
movss 0x90(%rsp), %xmm1
movss 0x94(%rsp), %xmm6
movss 0x98(%rsp), %xmm5
movss 0xa0(%rsp), %xmm7
movss 0xa4(%rsp), %xmm8
movss 0xa8(%rsp), %xmm10
movss 0xb0(%rsp), %xmm3
movss 0xb4(%rsp), %xmm4
movss 0xb8(%rsp), %xmm2
movaps %xmm4, %xmm9
mulss %xmm10, %xmm9
movaps %xmm2, %xmm11
mulss %xmm7, %xmm11
movaps %xmm3, %xmm12
mulss %xmm8, %xmm12
movaps %xmm7, %xmm0
mulss %xmm4, %xmm0
subss %xmm12, %xmm0
mulss %xmm5, %xmm0
unpcklps %xmm10, %xmm5 # xmm5 = xmm5[0],xmm10[0],xmm5[1],xmm10[1]
mulss %xmm3, %xmm10
subss %xmm11, %xmm10
mulss %xmm6, %xmm10
unpcklps %xmm8, %xmm6 # xmm6 = xmm6[0],xmm8[0],xmm6[1],xmm8[1]
mulss %xmm2, %xmm8
subss %xmm9, %xmm8
mulss %xmm1, %xmm8
addss %xmm10, %xmm8
addss %xmm8, %xmm0
mulps %xmm6, %xmm6
unpcklps %xmm7, %xmm1 # xmm1 = xmm1[0],xmm7[0],xmm1[1],xmm7[1]
mulps %xmm1, %xmm1
addps %xmm6, %xmm1
mulps %xmm5, %xmm5
addps %xmm1, %xmm5
sqrtps %xmm5, %xmm1
mulss %xmm4, %xmm4
mulss %xmm3, %xmm3
addss %xmm4, %xmm3
mulss %xmm2, %xmm2
addss %xmm3, %xmm2
xorps %xmm5, %xmm5
ucomiss %xmm0, %xmm5
sqrtss %xmm2, %xmm3
movaps 0x5ac21(%rip), %xmm2 # 0xb5140
movaps %xmm3, %xmm4
xorps %xmm2, %xmm4
jbe 0x5a52a
xorps %xmm2, %xmm1
movaps %xmm0, %xmm2
cmpltss %xmm5, %xmm2
andps %xmm2, %xmm4
andnps %xmm3, %xmm2
orps %xmm4, %xmm2
movlps %xmm1, (%rdx)
movss %xmm2, 0x8(%rdx)
movaps 0x90(%rsp), %xmm3
movaps 0xa0(%rsp), %xmm4
movaps 0xb0(%rsp), %xmm5
movaps 0xc0(%rsp), %xmm6
movaps %xmm6, 0x70(%rsp)
movaps %xmm5, 0x60(%rsp)
movaps %xmm4, 0x50(%rsp)
andps 0x5f587(%rip), %xmm0 # 0xb9b00
movaps %xmm3, 0x40(%rsp)
movaps %xmm0, %xmm3
maxss 0x5f113(%rip), %xmm3 # 0xb969c
mulss 0x68f4f(%rip), %xmm3 # 0xc34e0
ucomiss %xmm0, %xmm3
jae 0x5a632
movsd 0x40(%rsp), %xmm0
movaps %xmm1, %xmm3
unpcklps %xmm1, %xmm3 # xmm3 = xmm3[0],xmm1[0],xmm3[1],xmm1[1]
divps %xmm3, %xmm0
movlps %xmm0, 0x40(%rsp)
movss 0x48(%rsp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, 0x48(%rsp)
shufps $0x55, %xmm1, %xmm1 # xmm1 = xmm1[1,1,1,1]
movsd 0x50(%rsp), %xmm0
divps %xmm1, %xmm0
movlps %xmm0, 0x50(%rsp)
movss 0x58(%rsp), %xmm0
divss %xmm1, %xmm0
movss %xmm0, 0x58(%rsp)
movsd 0x60(%rsp), %xmm0
movaps %xmm2, %xmm1
unpcklps %xmm2, %xmm1 # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
divps %xmm1, %xmm0
movlps %xmm0, 0x60(%rsp)
movss 0x68(%rsp), %xmm0
divss %xmm2, %xmm0
movss %xmm0, 0x68(%rsp)
movaps 0x40(%rsp), %xmm0
movaps 0x50(%rsp), %xmm1
movaps 0x60(%rsp), %xmm2
movaps 0x70(%rsp), %xmm3
movups %xmm3, 0x30(%rsp)
movups %xmm2, 0x20(%rsp)
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
callq 0x599b3
jmp 0x5a63d
movsd 0x5f3a6(%rip), %xmm1 # 0xb99e0
xorps %xmm0, %xmm0
movlhps %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0]
movups %xmm0, (%rbx)
addq $0x80, %rsp
popq %rbx
retq
| MatrixDecompose:
push rbx
sub rsp, 80h
mov rbx, rsi
movss xmm0, dword ptr [rsp+88h+arg_0+0Ch]
movss dword ptr [rdi], xmm0
movss xmm0, dword ptr [rsp+88h+arg_10+0Ch]
movss dword ptr [rdi+4], xmm0
movss xmm0, dword ptr [rsp+88h+arg_20+0Ch]
movss dword ptr [rdi+8], xmm0
movss xmm1, dword ptr [rsp+88h+arg_0]
movss xmm6, dword ptr [rsp+88h+arg_0+4]
movss xmm5, dword ptr [rsp+88h+arg_0+8]
movss xmm7, dword ptr [rsp+88h+arg_10]
movss xmm8, dword ptr [rsp+88h+arg_10+4]
movss xmm10, dword ptr [rsp+88h+arg_10+8]
movss xmm3, dword ptr [rsp+88h+arg_20]
movss xmm4, dword ptr [rsp+88h+arg_20+4]
movss xmm2, dword ptr [rsp+88h+arg_20+8]
movaps xmm9, xmm4
mulss xmm9, xmm10
movaps xmm11, xmm2
mulss xmm11, xmm7
movaps xmm12, xmm3
mulss xmm12, xmm8
movaps xmm0, xmm7
mulss xmm0, xmm4
subss xmm0, xmm12
mulss xmm0, xmm5
unpcklps xmm5, xmm10
mulss xmm10, xmm3
subss xmm10, xmm11
mulss xmm10, xmm6
unpcklps xmm6, xmm8
mulss xmm8, xmm2
subss xmm8, xmm9
mulss xmm8, xmm1
addss xmm8, xmm10
addss xmm0, xmm8
mulps xmm6, xmm6
unpcklps xmm1, xmm7
mulps xmm1, xmm1
addps xmm1, xmm6
mulps xmm5, xmm5
addps xmm5, xmm1
sqrtps xmm1, xmm5
mulss xmm4, xmm4
mulss xmm3, xmm3
addss xmm3, xmm4
mulss xmm2, xmm2
addss xmm2, xmm3
xorps xmm5, xmm5
ucomiss xmm5, xmm0
sqrtss xmm3, xmm2
movaps xmm2, cs:xmmword_B5140
movaps xmm4, xmm3
xorps xmm4, xmm2
jbe short loc_5A52A
xorps xmm1, xmm2
loc_5A52A:
movaps xmm2, xmm0
cmpltss xmm2, xmm5
andps xmm4, xmm2
andnps xmm2, xmm3
orps xmm2, xmm4
movlps qword ptr [rdx], xmm1
movss dword ptr [rdx+8], xmm2
movaps xmm3, [rsp+88h+arg_0]
movaps xmm4, [rsp+88h+arg_10]
movaps xmm5, [rsp+88h+arg_20]
movaps xmm6, [rsp+88h+arg_30]
movaps [rsp+88h+var_18], xmm6
movaps [rsp+88h+var_28], xmm5
movaps [rsp+88h+var_38], xmm4
andps xmm0, cs:xmmword_B9B00
movaps [rsp+88h+var_48], xmm3
movaps xmm3, xmm0
maxss xmm3, cs:dword_B969C
mulss xmm3, cs:dword_C34E0
ucomiss xmm3, xmm0
jnb loc_5A632
movsd xmm0, qword ptr [rsp+88h+var_48]
movaps xmm3, xmm1
unpcklps xmm3, xmm1
divps xmm0, xmm3
movlps qword ptr [rsp+88h+var_48], xmm0
movss xmm0, dword ptr [rsp+88h+var_48+8]
divss xmm0, xmm1
movss dword ptr [rsp+88h+var_48+8], xmm0
shufps xmm1, xmm1, 55h ; 'U'
movsd xmm0, qword ptr [rsp+88h+var_38]
divps xmm0, xmm1
movlps qword ptr [rsp+88h+var_38], xmm0
movss xmm0, dword ptr [rsp+88h+var_38+8]
divss xmm0, xmm1
movss dword ptr [rsp+88h+var_38+8], xmm0
movsd xmm0, qword ptr [rsp+88h+var_28]
movaps xmm1, xmm2
unpcklps xmm1, xmm2
divps xmm0, xmm1
movlps qword ptr [rsp+88h+var_28], xmm0
movss xmm0, dword ptr [rsp+88h+var_28+8]
divss xmm0, xmm2
movss dword ptr [rsp+88h+var_28+8], xmm0
movaps xmm0, [rsp+88h+var_48]
movaps xmm1, [rsp+88h+var_38]
movaps xmm2, [rsp+88h+var_28]
movaps xmm3, [rsp+88h+var_18]
movups [rsp+88h+var_58], xmm3
movups [rsp+88h+var_68], xmm2
movups [rsp+88h+var_78], xmm1
movups [rsp+88h+var_88], xmm0
call QuaternionFromMatrix
jmp short loc_5A63D
loc_5A632:
movsd xmm1, qword ptr cs:xmmword_B99E0
xorps xmm0, xmm0
loc_5A63D:
movlhps xmm0, xmm1
movups xmmword ptr [rbx], xmm0
add rsp, 80h
pop rbx
retn
| // local variable allocation has failed, the output may be wrong!
void MatrixDecompose(
_DWORD *a1,
__m128 *a2,
long long a3,
long long a4,
long long a5,
long long a6,
__int128 a7,
__int128 a8,
__int128 a9,
__int128 a10)
{
__m128 v10; // xmm6
__m128 v11; // xmm0
__m128 v12; // xmm1
__m128 v13; // xmm1
__m128 v14; // xmm5
__m128 v15; // xmm3
__m128 v16; // xmm4
__m128 v17; // xmm2
__m128 v18; // xmm2
float v19; // xmm0_4
__m128 v20; // xmm1
__m128 v21; // xmm1
__m128 v22; // xmm0
long long v23; // [rsp+8h] [rbp-80h]
__int128 v24; // [rsp+10h] [rbp-78h] OVERLAPPED
long long v25; // [rsp+20h] [rbp-68h] OVERLAPPED
__int128 v26; // [rsp+40h] [rbp-48h] BYREF
__int128 v27; // [rsp+50h] [rbp-38h] BYREF
__int128 v28; // [rsp+60h] [rbp-28h] BYREF
__int128 v29; // [rsp+70h] [rbp-18h]
*a1 = HIDWORD(a7);
a1[1] = HIDWORD(a8);
a1[2] = HIDWORD(a9);
v15 = (__m128)(unsigned int)a9;
v11 = (__m128)(unsigned int)a8;
v14 = _mm_unpacklo_ps((__m128)DWORD2(a7), (__m128)DWORD2(a8));
v10 = _mm_unpacklo_ps((__m128)DWORD1(a7), (__m128)DWORD1(a8));
v11.m128_f32[0] = (float)((float)((float)(*(float *)&a8 * *((float *)&a9 + 1))
- (float)(*(float *)&a9 * *((float *)&a8 + 1)))
* *((float *)&a7 + 2))
+ (float)((float)((float)((float)(*((float *)&a8 + 1) * *((float *)&a9 + 2))
- (float)(*((float *)&a9 + 1) * *((float *)&a8 + 2)))
* *(float *)&a7)
+ (float)((float)((float)(*((float *)&a8 + 2) * *(float *)&a9)
- (float)(*((float *)&a9 + 2) * *(float *)&a8))
* *((float *)&a7 + 1)));
v12 = _mm_unpacklo_ps((__m128)(unsigned int)a7, (__m128)(unsigned int)a8);
v13 = _mm_sqrt_ps(_mm_add_ps(_mm_mul_ps(v14, v14), _mm_add_ps(_mm_mul_ps(v12, v12), _mm_mul_ps(v10, v10))));
v14.m128_i32[0] = 0;
v15.m128_f32[0] = fsqrt(
(float)(*((float *)&a9 + 2) * *((float *)&a9 + 2))
+ (float)((float)(v15.m128_f32[0] * v15.m128_f32[0])
+ (float)(*((float *)&a9 + 1) * *((float *)&a9 + 1))));
v16 = _mm_xor_ps(v15, (__m128)xmmword_B5140);
if ( v11.m128_f32[0] < 0.0 )
v13 = _mm_xor_ps(v13, (__m128)xmmword_B5140);
v17 = _mm_cmplt_ss(v11, v14);
v18 = _mm_or_ps(_mm_andnot_ps(v17, v15), _mm_and_ps(v16, v17));
_mm_storel_ps((double *)a3, v13);
*(_DWORD *)(a3 + 8) = v18.m128_i32[0];
v29 = a10;
v28 = a9;
v27 = a8;
v19 = fabs(v11.m128_f32[0]);
v26 = a7;
if ( (float)(fmaxf(v19, 1.0) * 0.000001) >= v19 )
{
v21 = (__m128)0x3F80000000000000uLL;
v22 = 0LL;
}
else
{
_mm_storel_ps((double *)&v26, _mm_div_ps((__m128)(unsigned long long)v26, _mm_unpacklo_ps(v13, v13)));
*((float *)&v26 + 2) = *((float *)&v26 + 2) / v13.m128_f32[0];
v20 = _mm_shuffle_ps(v13, v13, 85);
_mm_storel_ps((double *)&v27, _mm_div_ps((__m128)(unsigned long long)v27, v20));
*((float *)&v27 + 2) = *((float *)&v27 + 2) / v20.m128_f32[0];
_mm_storel_ps((double *)&v28, _mm_div_ps((__m128)(unsigned long long)v28, _mm_unpacklo_ps(v18, v18)));
*((float *)&v28 + 2) = *((float *)&v28 + 2) / v18.m128_f32[0];
v21 = (__m128)v27;
v25 = v28;
v24 = v27;
v23 = *((_QWORD *)&v26 + 1);
v22 = QuaternionFromMatrix(
(long long)a1,
(long long)a2,
a3,
a4,
a5,
a6,
*(double *)&v26,
*(double *)&v27,
*(double *)&v28,
*(double *)&v29,
*(double *)&a8,
*(double *)&a9,
*(double *)&a10,
COERCE_DOUBLE((unsigned long long)(unsigned int)a8),
v26,
*(__m128 *)((char *)&v24 - 8),
*(__m128 *)(&v25 - 1),
*((float *)&v28 + 2));
}
*a2 = _mm_movelh_ps(v22, v21);
}
| MatrixDecompose:
PUSH RBX
SUB RSP,0x80
MOV RBX,RSI
MOVSS XMM0,dword ptr [RSP + 0x9c]
MOVSS dword ptr [RDI],XMM0
MOVSS XMM0,dword ptr [RSP + 0xac]
MOVSS dword ptr [RDI + 0x4],XMM0
MOVSS XMM0,dword ptr [RSP + 0xbc]
MOVSS dword ptr [RDI + 0x8],XMM0
MOVSS XMM1,dword ptr [RSP + 0x90]
MOVSS XMM6,dword ptr [RSP + 0x94]
MOVSS XMM5,dword ptr [RSP + 0x98]
MOVSS XMM7,dword ptr [RSP + 0xa0]
MOVSS XMM8,dword ptr [RSP + 0xa4]
MOVSS XMM10,dword ptr [RSP + 0xa8]
MOVSS XMM3,dword ptr [RSP + 0xb0]
MOVSS XMM4,dword ptr [RSP + 0xb4]
MOVSS XMM2,dword ptr [RSP + 0xb8]
MOVAPS XMM9,XMM4
MULSS XMM9,XMM10
MOVAPS XMM11,XMM2
MULSS XMM11,XMM7
MOVAPS XMM12,XMM3
MULSS XMM12,XMM8
MOVAPS XMM0,XMM7
MULSS XMM0,XMM4
SUBSS XMM0,XMM12
MULSS XMM0,XMM5
UNPCKLPS XMM5,XMM10
MULSS XMM10,XMM3
SUBSS XMM10,XMM11
MULSS XMM10,XMM6
UNPCKLPS XMM6,XMM8
MULSS XMM8,XMM2
SUBSS XMM8,XMM9
MULSS XMM8,XMM1
ADDSS XMM8,XMM10
ADDSS XMM0,XMM8
MULPS XMM6,XMM6
UNPCKLPS XMM1,XMM7
MULPS XMM1,XMM1
ADDPS XMM1,XMM6
MULPS XMM5,XMM5
ADDPS XMM5,XMM1
SQRTPS XMM1,XMM5
MULSS XMM4,XMM4
MULSS XMM3,XMM3
ADDSS XMM3,XMM4
MULSS XMM2,XMM2
ADDSS XMM2,XMM3
XORPS XMM5,XMM5
UCOMISS XMM5,XMM0
SQRTSS XMM3,XMM2
MOVAPS XMM2,xmmword ptr [0x001b5140]
MOVAPS XMM4,XMM3
XORPS XMM4,XMM2
JBE 0x0015a52a
XORPS XMM1,XMM2
LAB_0015a52a:
MOVAPS XMM2,XMM0
CMPLTSS XMM2,XMM5
ANDPS XMM4,XMM2
ANDNPS XMM2,XMM3
ORPS XMM2,XMM4
MOVLPS qword ptr [RDX],XMM1
MOVSS dword ptr [RDX + 0x8],XMM2
MOVAPS XMM3,xmmword ptr [RSP + 0x90]
MOVAPS XMM4,xmmword ptr [RSP + 0xa0]
MOVAPS XMM5,xmmword ptr [RSP + 0xb0]
MOVAPS XMM6,xmmword ptr [RSP + 0xc0]
MOVAPS xmmword ptr [RSP + 0x70],XMM6
MOVAPS xmmword ptr [RSP + 0x60],XMM5
MOVAPS xmmword ptr [RSP + 0x50],XMM4
ANDPS XMM0,xmmword ptr [0x001b9b00]
MOVAPS xmmword ptr [RSP + 0x40],XMM3
MOVAPS XMM3,XMM0
MAXSS XMM3,dword ptr [0x001b969c]
MULSS XMM3,dword ptr [0x001c34e0]
UCOMISS XMM3,XMM0
JNC 0x0015a632
MOVSD XMM0,qword ptr [RSP + 0x40]
MOVAPS XMM3,XMM1
UNPCKLPS XMM3,XMM1
DIVPS XMM0,XMM3
MOVLPS qword ptr [RSP + 0x40],XMM0
MOVSS XMM0,dword ptr [RSP + 0x48]
DIVSS XMM0,XMM1
MOVSS dword ptr [RSP + 0x48],XMM0
SHUFPS XMM1,XMM1,0x55
MOVSD XMM0,qword ptr [RSP + 0x50]
DIVPS XMM0,XMM1
MOVLPS qword ptr [RSP + 0x50],XMM0
MOVSS XMM0,dword ptr [RSP + 0x58]
DIVSS XMM0,XMM1
MOVSS dword ptr [RSP + 0x58],XMM0
MOVSD XMM0,qword ptr [RSP + 0x60]
MOVAPS XMM1,XMM2
UNPCKLPS XMM1,XMM2
DIVPS XMM0,XMM1
MOVLPS qword ptr [RSP + 0x60],XMM0
MOVSS XMM0,dword ptr [RSP + 0x68]
DIVSS XMM0,XMM2
MOVSS dword ptr [RSP + 0x68],XMM0
MOVAPS XMM0,xmmword ptr [RSP + 0x40]
MOVAPS XMM1,xmmword ptr [RSP + 0x50]
MOVAPS XMM2,xmmword ptr [RSP + 0x60]
MOVAPS XMM3,xmmword ptr [RSP + 0x70]
MOVUPS xmmword ptr [RSP + 0x30],XMM3
MOVUPS xmmword ptr [RSP + 0x20],XMM2
MOVUPS xmmword ptr [RSP + 0x10],XMM1
MOVUPS xmmword ptr [RSP],XMM0
CALL 0x001599b3
JMP 0x0015a63d
LAB_0015a632:
MOVSD XMM1,qword ptr [0x001b99e0]
XORPS XMM0,XMM0
LAB_0015a63d:
MOVLHPS XMM0,XMM1
MOVUPS xmmword ptr [RBX],XMM0
ADD RSP,0x80
POP RBX
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
void MatrixDecompose(int4 *param_1,int1 (*param_2) [16],int8 *param_3)
{
int1 auVar1 [16];
uint uVar2;
float fVar3;
int1 auVar4 [16];
int1 auVar5 [16];
int1 auVar6 [16];
int1 auVar8 [16];
int1 auVar9 [16];
int8 uVar7;
int1 auVar10 [16];
int1 auVar11 [16];
float fVar12;
int1 auVar13 [16];
float fStack0000000000000008;
float fStack000000000000000c;
float fStack0000000000000010;
int4 uStack0000000000000014;
float fStack0000000000000018;
float fStack000000000000001c;
float fStack0000000000000020;
int4 uStack0000000000000024;
float fStack0000000000000028;
float fStack000000000000002c;
float fStack0000000000000030;
int4 uStack0000000000000034;
*param_1 = uStack0000000000000014;
param_1[1] = uStack0000000000000024;
param_1[2] = uStack0000000000000034;
fVar3 = (fStack0000000000000018 * fStack000000000000002c -
fStack0000000000000028 * fStack000000000000001c) * fStack0000000000000010 +
(fStack000000000000001c * fStack0000000000000030 -
fStack000000000000002c * fStack0000000000000020) * fStack0000000000000008 +
(fStack0000000000000020 * fStack0000000000000028 -
fStack0000000000000030 * fStack0000000000000018) * fStack000000000000000c;
auVar8._0_4_ = fStack0000000000000008 * fStack0000000000000008 +
fStack000000000000000c * fStack000000000000000c;
auVar8._4_4_ = fStack0000000000000018 * fStack0000000000000018 +
fStack000000000000001c * fStack000000000000001c;
auVar8._8_8_ = 0;
auVar9._4_4_ = fStack0000000000000020 * fStack0000000000000020 + auVar8._4_4_;
auVar9._0_4_ = fStack0000000000000010 * fStack0000000000000010 + auVar8._0_4_;
auVar9._8_8_ = 0;
auVar9 = sqrtps(auVar8,auVar9);
uVar7 = auVar9._0_8_;
fVar12 = SQRT(fStack0000000000000030 * fStack0000000000000030 +
fStack0000000000000028 * fStack0000000000000028 +
fStack000000000000002c * fStack000000000000002c);
if (fVar3 < 0.0) {
uVar7 = CONCAT44(auVar9._4_4_ ^ _UNK_001b5144,auVar9._0_4_ ^ _DAT_001b5140);
}
uVar2 = ~-(uint)(fVar3 < 0.0) & (uint)fVar12 |
((uint)fVar12 ^ _DAT_001b5140) & -(uint)(fVar3 < 0.0);
*param_3 = uVar7;
*(uint *)(param_3 + 1) = uVar2;
fVar3 = (float)((uint)fVar3 & _DAT_001b9b00);
fVar12 = fVar3;
if (fVar3 <= DAT_001b969c) {
fVar12 = DAT_001b969c;
}
if (fVar3 <= fVar12 * DAT_001c34e0) {
auVar13._8_8_ = 0;
auVar13._0_8_ = DAT_001b99e0;
auVar13 = auVar13 << 0x40;
}
else {
auVar4._8_8_ = 0;
auVar4._0_8_ = _fStack0000000000000008;
auVar10._4_4_ = (int4)((ulong)uVar7 >> 0x20);
auVar1._4_4_ = (int)uVar7;
auVar1._0_4_ = (int)uVar7;
auVar1._8_4_ = auVar10._4_4_;
auVar1._12_4_ = auVar10._4_4_;
divps(auVar4,auVar1);
auVar10._0_4_ = auVar10._4_4_;
auVar10._8_4_ = auVar10._4_4_;
auVar10._12_4_ = auVar10._4_4_;
auVar5._8_8_ = 0;
auVar5._0_8_ = _fStack0000000000000018;
divps(auVar5,auVar10);
auVar6._8_8_ = 0;
auVar6._0_8_ = _fStack0000000000000028;
auVar11._4_4_ = uVar2;
auVar11._0_4_ = uVar2;
auVar11._8_8_ = 0;
divps(auVar6,auVar11);
auVar13 = QuaternionFromMatrix();
}
*param_2 = auVar13;
return;
}
| |
23,354 | my_write | eloqsql/mysys/my_write.c | size_t my_write(File Filedes, const uchar *Buffer, size_t Count, myf MyFlags)
{
size_t writtenbytes, written;
uint errors;
DBUG_ENTER("my_write");
DBUG_PRINT("my",("fd: %d Buffer: %p Count: %lu MyFlags: %lu",
Filedes, Buffer, (ulong) Count, MyFlags));
errors= 0; written= 0;
if (!(MyFlags & (MY_WME | MY_FAE | MY_FNABP)))
MyFlags|= my_global_flags;
/* The behavior of write(fd, buf, 0) is not portable */
if (unlikely(!Count))
DBUG_RETURN(0);
for (;;)
{
#ifdef _WIN32
if(Filedes < 0)
{
my_errno= errno= EBADF;
DBUG_RETURN((size_t)-1);
}
writtenbytes= my_win_write(Filedes, Buffer, Count);
#else
writtenbytes= write(Filedes, Buffer, Count);
#endif
/**
To simulate the write error set the errno = error code
and the number pf written bytes to -1.
*/
DBUG_EXECUTE_IF ("simulate_file_write_error",
if (!errors) {
errno= ENOSPC;
writtenbytes= (size_t) -1;
});
if (writtenbytes == Count)
break;
if (writtenbytes != (size_t) -1)
{ /* Safeguard */
written+= writtenbytes;
Buffer+= writtenbytes;
Count-= writtenbytes;
}
my_errno= errno;
DBUG_PRINT("error",("Write only %ld bytes, error: %d",
(long) writtenbytes, my_errno));
#ifndef NO_BACKGROUND
if (my_thread_var->abort)
MyFlags&= ~ MY_WAIT_IF_FULL; /* End if aborted by user */
if ((my_errno == ENOSPC || my_errno == EDQUOT) &&
(MyFlags & MY_WAIT_IF_FULL))
{
wait_for_free_space(my_filename(Filedes), errors);
errors++;
continue;
}
if ((writtenbytes == 0 || writtenbytes == (size_t) -1))
{
if (my_errno == EINTR)
{
DBUG_PRINT("debug", ("my_write() was interrupted and returned %ld",
(long) writtenbytes));
continue; /* Interrupted */
}
if (!writtenbytes && !errors++) /* Retry once */
{
/* We may come here if the file quota is exeeded */
errno= EFBIG; /* Assume this is the error */
continue;
}
}
else
continue; /* Retry */
#endif
/* Don't give a warning if it's ok that we only write part of the data */
if (MyFlags & (MY_NABP | MY_FNABP))
{
if (MyFlags & (MY_WME | MY_FAE | MY_FNABP))
{
my_error(EE_WRITE, MYF(ME_BELL | (MyFlags & (ME_NOTE | ME_ERROR_LOG))),
my_filename(Filedes),my_errno);
}
DBUG_RETURN(MY_FILE_ERROR); /* Error on read */
}
break; /* Return bytes written */
}
if (MyFlags & (MY_NABP | MY_FNABP))
DBUG_RETURN(0); /* Want only errors */
DBUG_RETURN(writtenbytes+written);
} | O3 | c | my_write:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r15
movl %edi, %r12d
xorl %ebx, %ebx
movl $0x0, %r13d
testb $0x1a, %cl
jne 0x2f012
leaq 0xbd8cf9(%rip), %rax # 0xc07d08
movq (%rax), %r13
testq %r15, %r15
je 0x2f156
orq %rcx, %r13
movl %r12d, %edi
movq %rsi, -0x40(%rbp)
movq %r15, %rdx
callq 0x297e0
cmpq %r15, %rax
jne 0x2f048
movq %r15, %rcx
xorl %ebx, %ebx
testb $0x6, %r13b
je 0x2f153
xorl %ebx, %ebx
jmp 0x2f156
movq %rax, %r14
movq $0x0, -0x38(%rbp)
callq 0x29790
movq %r15, %rcx
movq %rax, -0x48(%rbp)
xorl %ebx, %ebx
movq -0x40(%rbp), %r15
movl %r12d, -0x2c(%rbp)
movq %r13, %r12
movq %rbx, %rax
cmpq $-0x1, %r14
movl $0x0, %ebx
cmovneq %r14, %rbx
addq %rbx, %r15
subq %rbx, %rcx
movq %rcx, -0x40(%rbp)
addq %rax, %rbx
movq -0x48(%rbp), %rax
movl (%rax), %r13d
callq 0xa1ac2
movl %r13d, (%rax)
callq 0xa1ac2
movl %r12d, %r13d
andl $-0x21, %r13d
cmpl $0x0, 0xe0(%rax)
cmoveq %r12, %r13
callq 0xa1ac2
cmpl $0x1c, (%rax)
jne 0x2f0c5
testb $0x20, %r13b
movl -0x2c(%rbp), %r12d
je 0x2f0db
jmp 0x2f115
callq 0xa1ac2
cmpl $0x7a, (%rax)
movl -0x2c(%rbp), %r12d
jne 0x2f0db
movl %r13d, %eax
andl $0x20, %eax
jne 0x2f115
leaq 0x1(%r14), %rax
cmpq $0x1, %rax
ja 0x2f0ef
callq 0xa1ac2
cmpl $0x4, (%rax)
jne 0x2f135
movl %r12d, %edi
movq %r15, %rsi
movq -0x40(%rbp), %r14
movq %r14, %rdx
callq 0x297e0
movq %r14, %rcx
movq %rax, %r14
cmpq %rcx, %rax
jne 0x2f069
jmp 0x2f037
movl %r12d, %edi
callq 0xa8f34
movq %rax, %rdi
movq -0x38(%rbp), %r14
movl %r14d, %esi
callq 0xa89a2
incl %r14d
movq %r14, -0x38(%rbp)
jmp 0x2f0ef
testq %r14, %r14
jne 0x2f168
cmpl $0x0, -0x38(%rbp)
jne 0x2f168
movq -0x48(%rbp), %rax
movl $0x1b, (%rax)
pushq $0x1
popq %rax
movq %rax, -0x38(%rbp)
jmp 0x2f0ef
addq %rcx, %rbx
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
testb $0x6, %r13b
je 0x2f1a6
pushq $-0x1
popq %rbx
testb $0x1a, %r13b
je 0x2f156
andl $0x440, %r13d # imm = 0x440
orq $0x4, %r13
movl %r12d, %edi
callq 0xa8f34
movq %rax, %r14
callq 0xa1ac2
movl (%rax), %ecx
pushq $0x3
popq %rdi
movq %r13, %rsi
movq %r14, %rdx
xorl %eax, %eax
callq 0x9dfd3
jmp 0x2f156
movq %r14, %rcx
jmp 0x2f037
| my_write:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r15, rdx
mov r12d, edi
xor ebx, ebx
mov r13d, 0
test cl, 1Ah
jnz short loc_2F012
lea rax, my_global_flags
mov r13, [rax]
loc_2F012:
test r15, r15
jz loc_2F156
or r13, rcx
mov edi, r12d
mov [rbp+var_40], rsi
mov rdx, r15
call _write
cmp rax, r15
jnz short loc_2F048
mov rcx, r15
xor ebx, ebx
loc_2F037:
test r13b, 6
jz loc_2F153
xor ebx, ebx
jmp loc_2F156
loc_2F048:
mov r14, rax
mov [rbp+var_38], 0
call ___errno_location
mov rcx, r15
mov [rbp+var_48], rax
xor ebx, ebx
mov r15, [rbp+var_40]
mov [rbp+var_2C], r12d
loc_2F069:
mov r12, r13
mov rax, rbx
cmp r14, 0FFFFFFFFFFFFFFFFh
mov ebx, 0
cmovnz rbx, r14
add r15, rbx
sub rcx, rbx
mov [rbp+var_40], rcx
add rbx, rax
mov rax, [rbp+var_48]
mov r13d, [rax]
call _my_thread_var
mov [rax], r13d
call _my_thread_var
mov r13d, r12d
and r13d, 0FFFFFFDFh
cmp dword ptr [rax+0E0h], 0
cmovz r13, r12
call _my_thread_var
cmp dword ptr [rax], 1Ch
jnz short loc_2F0C5
test r13b, 20h
mov r12d, [rbp+var_2C]
jz short loc_2F0DB
jmp short loc_2F115
loc_2F0C5:
call _my_thread_var
cmp dword ptr [rax], 7Ah ; 'z'
mov r12d, [rbp+var_2C]
jnz short loc_2F0DB
mov eax, r13d
and eax, 20h
jnz short loc_2F115
loc_2F0DB:
lea rax, [r14+1]
cmp rax, 1
ja short loc_2F0EF
call _my_thread_var
cmp dword ptr [rax], 4
jnz short loc_2F135
loc_2F0EF:
mov edi, r12d
mov rsi, r15
mov r14, [rbp+var_40]
mov rdx, r14
call _write
mov rcx, r14
mov r14, rax
cmp rax, rcx
jnz loc_2F069
jmp loc_2F037
loc_2F115:
mov edi, r12d
call my_filename
mov rdi, rax
mov r14, [rbp+var_38]
mov esi, r14d
call wait_for_free_space
inc r14d
mov [rbp+var_38], r14
jmp short loc_2F0EF
loc_2F135:
test r14, r14
jnz short loc_2F168
cmp dword ptr [rbp+var_38], 0
jnz short loc_2F168
mov rax, [rbp+var_48]
mov dword ptr [rax], 1Bh
push 1
pop rax
mov [rbp+var_38], rax
jmp short loc_2F0EF
loc_2F153:
add rbx, rcx
loc_2F156:
mov rax, rbx
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_2F168:
test r13b, 6
jz short loc_2F1A6
push 0FFFFFFFFFFFFFFFFh
pop rbx
test r13b, 1Ah
jz short loc_2F156
and r13d, 440h
or r13, 4
mov edi, r12d
call my_filename
mov r14, rax
call _my_thread_var
mov ecx, [rax]
push 3
pop rdi
mov rsi, r13
mov rdx, r14
xor eax, eax
call my_error
jmp short loc_2F156
loc_2F1A6:
mov rcx, r14
jmp loc_2F037
| long long my_write(unsigned int a1, long long a2, long long a3, long long a4)
{
long long v5; // rbx
long long v6; // r13
long long v7; // r13
long long v8; // rax
long long v9; // rcx
long long v10; // rbx
long long v11; // r14
long long v12; // rax
long long v13; // r15
long long v14; // r12
long long v15; // rax
long long v16; // rbx
int v17; // r13d
unsigned int v18; // r12d
long long v19; // rax
long long v20; // rax
int v22; // r14d
_DWORD *v23; // rax
int v24; // r8d
int v25; // r9d
int *v26; // [rsp+8h] [rbp-48h]
long long v27; // [rsp+10h] [rbp-40h]
unsigned int v28; // [rsp+18h] [rbp-38h]
v5 = 0LL;
v6 = 0LL;
if ( (a4 & 0x1A) == 0 )
v6 = my_global_flags;
if ( a3 )
{
v7 = a4 | v6;
v8 = write(a1, a2, a3);
if ( v8 == a3 )
{
v9 = a3;
v10 = 0LL;
goto LABEL_6;
}
v11 = v8;
v28 = 0;
v12 = __errno_location(a1);
v9 = a3;
v26 = (int *)v12;
v10 = 0LL;
v13 = a2;
while ( 1 )
{
v14 = v7;
v15 = v10;
v16 = 0LL;
if ( v11 != -1 )
v16 = v11;
v13 += v16;
v27 = v9 - v16;
v10 = v15 + v16;
v17 = *v26;
*(_DWORD *)my_thread_var() = v17;
v7 = (unsigned int)v14 & 0xFFFFFFDF;
if ( !*(_DWORD *)(my_thread_var() + 224) )
v7 = v14;
if ( *(_DWORD *)my_thread_var() == 28 )
{
v18 = a1;
if ( (v7 & 0x20) != 0 )
goto LABEL_22;
}
else
{
v18 = a1;
if ( *(_DWORD *)my_thread_var() == 122 && (v7 & 0x20) != 0 )
{
LABEL_22:
v20 = my_filename(v18);
wait_for_free_space(v20, v28++);
goto LABEL_20;
}
}
if ( (unsigned long long)(v11 + 1) <= 1 && *(_DWORD *)my_thread_var() != 4 )
{
if ( v11 || v28 )
{
if ( (v7 & 6) != 0 )
{
v5 = -1LL;
if ( (v7 & 0x1A) != 0 )
{
v22 = my_filename(v18);
v23 = (_DWORD *)my_thread_var();
my_error(3, v7 & 0x440 | 4, v22, *v23, v24, v25);
}
return v5;
}
v9 = v11;
LABEL_6:
if ( (v7 & 6) != 0 )
return 0LL;
else
return v9 + v10;
}
*v26 = 27;
v28 = 1;
}
LABEL_20:
v19 = write(v18, v13, v27);
v9 = v27;
v11 = v19;
if ( v19 == v27 )
goto LABEL_6;
}
}
return v5;
}
| my_write:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R15,RDX
MOV R12D,EDI
XOR EBX,EBX
MOV R13D,0x0
TEST CL,0x1a
JNZ 0x0012f012
LEA RAX,[0xd07d08]
MOV R13,qword ptr [RAX]
LAB_0012f012:
TEST R15,R15
JZ 0x0012f156
OR R13,RCX
MOV EDI,R12D
MOV qword ptr [RBP + -0x40],RSI
MOV RDX,R15
CALL 0x001297e0
CMP RAX,R15
JNZ 0x0012f048
MOV RCX,R15
XOR EBX,EBX
LAB_0012f037:
TEST R13B,0x6
JZ 0x0012f153
XOR EBX,EBX
JMP 0x0012f156
LAB_0012f048:
MOV R14,RAX
MOV qword ptr [RBP + -0x38],0x0
CALL 0x00129790
MOV RCX,R15
MOV qword ptr [RBP + -0x48],RAX
XOR EBX,EBX
MOV R15,qword ptr [RBP + -0x40]
MOV dword ptr [RBP + -0x2c],R12D
LAB_0012f069:
MOV R12,R13
MOV RAX,RBX
CMP R14,-0x1
MOV EBX,0x0
CMOVNZ RBX,R14
ADD R15,RBX
SUB RCX,RBX
MOV qword ptr [RBP + -0x40],RCX
ADD RBX,RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV R13D,dword ptr [RAX]
CALL 0x001a1ac2
MOV dword ptr [RAX],R13D
CALL 0x001a1ac2
MOV R13D,R12D
AND R13D,0xffffffdf
CMP dword ptr [RAX + 0xe0],0x0
CMOVZ R13,R12
CALL 0x001a1ac2
CMP dword ptr [RAX],0x1c
JNZ 0x0012f0c5
TEST R13B,0x20
MOV R12D,dword ptr [RBP + -0x2c]
JZ 0x0012f0db
JMP 0x0012f115
LAB_0012f0c5:
CALL 0x001a1ac2
CMP dword ptr [RAX],0x7a
MOV R12D,dword ptr [RBP + -0x2c]
JNZ 0x0012f0db
MOV EAX,R13D
AND EAX,0x20
JNZ 0x0012f115
LAB_0012f0db:
LEA RAX,[R14 + 0x1]
CMP RAX,0x1
JA 0x0012f0ef
CALL 0x001a1ac2
CMP dword ptr [RAX],0x4
JNZ 0x0012f135
LAB_0012f0ef:
MOV EDI,R12D
MOV RSI,R15
MOV R14,qword ptr [RBP + -0x40]
MOV RDX,R14
CALL 0x001297e0
MOV RCX,R14
MOV R14,RAX
CMP RAX,RCX
JNZ 0x0012f069
JMP 0x0012f037
LAB_0012f115:
MOV EDI,R12D
CALL 0x001a8f34
MOV RDI,RAX
MOV R14,qword ptr [RBP + -0x38]
MOV ESI,R14D
CALL 0x001a89a2
INC R14D
MOV qword ptr [RBP + -0x38],R14
JMP 0x0012f0ef
LAB_0012f135:
TEST R14,R14
JNZ 0x0012f168
CMP dword ptr [RBP + -0x38],0x0
JNZ 0x0012f168
MOV RAX,qword ptr [RBP + -0x48]
MOV dword ptr [RAX],0x1b
PUSH 0x1
POP RAX
MOV qword ptr [RBP + -0x38],RAX
JMP 0x0012f0ef
LAB_0012f153:
ADD RBX,RCX
LAB_0012f156:
MOV RAX,RBX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0012f168:
TEST R13B,0x6
JZ 0x0012f1a6
PUSH -0x1
POP RBX
TEST R13B,0x1a
JZ 0x0012f156
AND R13D,0x440
OR R13,0x4
MOV EDI,R12D
CALL 0x001a8f34
MOV R14,RAX
CALL 0x001a1ac2
MOV ECX,dword ptr [RAX]
PUSH 0x3
POP RDI
MOV RSI,R13
MOV RDX,R14
XOR EAX,EAX
CALL 0x0019dfd3
JMP 0x0012f156
LAB_0012f1a6:
MOV RCX,R14
JMP 0x0012f037
|
long my_write(int param_1,void *param_2,size_t param_3,ulong param_4)
{
int iVar1;
size_t sVar2;
int *piVar3;
int *piVar4;
long lVar5;
int8 uVar6;
int4 *puVar7;
size_t sVar8;
long lVar9;
ulong uVar10;
ulong uVar11;
int iVar12;
lVar9 = 0;
uVar10 = 0;
if ((param_4 & 0x1a) == 0) {
uVar10 = my_global_flags;
}
if (param_3 != 0) {
uVar10 = uVar10 | param_4;
sVar2 = write(param_1,param_2,param_3);
if (sVar2 == param_3) {
lVar9 = 0;
}
else {
iVar12 = 0;
piVar3 = __errno_location();
lVar9 = 0;
uVar11 = uVar10;
do {
sVar8 = 0;
if (sVar2 != 0xffffffffffffffff) {
sVar8 = sVar2;
}
param_2 = (void *)((long)param_2 + sVar8);
param_3 = param_3 - sVar8;
lVar9 = sVar8 + lVar9;
iVar1 = *piVar3;
piVar4 = (int *)_my_thread_var();
*piVar4 = iVar1;
lVar5 = _my_thread_var();
uVar10 = (ulong)((uint)uVar11 & 0xffffffdf);
if (*(int *)(lVar5 + 0xe0) == 0) {
uVar10 = uVar11;
}
piVar4 = (int *)_my_thread_var();
if (*piVar4 == 0x1c) {
if ((uVar10 & 0x20) != 0) goto LAB_0012f115;
LAB_0012f0db:
if ((sVar2 + 1 < 2) && (piVar4 = (int *)_my_thread_var(), *piVar4 != 4)) {
if ((sVar2 != 0) || (iVar12 != 0)) {
param_3 = sVar2;
if ((uVar10 & 6) != 0) {
if ((uVar10 & 0x1a) == 0) {
return -1;
}
uVar6 = my_filename(param_1);
puVar7 = (int4 *)_my_thread_var();
my_error(3,(uint)uVar10 & 0x440 | 4,uVar6,*puVar7);
return -1;
}
break;
}
*piVar3 = 0x1b;
iVar12 = 1;
}
}
else {
piVar4 = (int *)_my_thread_var();
if ((*piVar4 != 0x7a) || ((uVar10 & 0x20) == 0)) goto LAB_0012f0db;
LAB_0012f115:
uVar6 = my_filename(param_1);
wait_for_free_space(uVar6,iVar12);
iVar12 = iVar12 + 1;
}
sVar2 = write(param_1,param_2,param_3);
uVar11 = uVar10;
} while (sVar2 != param_3);
}
if ((uVar10 & 6) == 0) {
lVar9 = lVar9 + param_3;
}
else {
lVar9 = 0;
}
}
return lVar9;
}
| |
23,355 | minja::Parser::parseLogicalAnd() | monkey531[P]llama/common/minja.hpp | std::shared_ptr<Expression> parseLogicalAnd() {
auto left = parseLogicalNot();
if (!left) throw std::runtime_error("Expected left side of 'logical and' expression");
static std::regex and_tok(R"(and\b)");
auto location = get_location();
while (!consumeToken(and_tok).empty()) {
auto right = parseLogicalNot();
if (!right) throw std::runtime_error("Expected right side of 'and' expression");
left = std::make_shared<BinaryOpExpr>(location, std::move(left), std::move(right), BinaryOpExpr::Op::And);
}
return left;
} | O1 | cpp | minja::Parser::parseLogicalAnd():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x5173c
cmpq $0x0, (%rbx)
je 0x51643
leaq 0xa4d08(%rip), %rax # 0xf61e0
movb (%rax), %al
testb %al, %al
je 0x51675
movq (%r14), %rax
movq %rax, 0x20(%rsp)
movq 0x8(%r14), %rax
movq %rax, 0x28(%rsp)
testq %rax, %rax
je 0x5150d
movq 0xa3a99(%rip), %rcx # 0xf4f98
cmpb $0x0, (%rcx)
je 0x51509
incl 0x8(%rax)
jmp 0x5150d
lock
incl 0x8(%rax)
movq 0x20(%r14), %rax
subq 0x10(%r14), %rax
leaq 0x20(%rsp), %rcx
movq %rax, 0x10(%rcx)
movq %rsp, %r13
leaq 0xa2470(%rip), %r12 # 0xf3998
addq $0x10, %r12
movq %r13, %rdi
movq %r14, %rsi
leaq 0xa4c87(%rip), %rdx # 0xf61c0
movl $0x1, %ecx
callq 0x4fe98
movq (%rsp), %rdi
movq 0x8(%rsp), %r15
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x51563
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1a7f0
testq %r15, %r15
je 0x515ee
movq %r13, %rdi
movq %r14, %rsi
callq 0x5173c
cmpq $0x0, (%rsp)
je 0x5160f
movl $0x58, %edi
callq 0x1a7d0
movq %rax, %rbp
movabsq $0x100000001, %rax # imm = 0x100000001
movq %rax, 0x8(%rbp)
movq %r12, (%rbp)
movq %rbp, %r15
addq $0x10, %r15
movq %r15, %rdi
leaq 0x20(%rsp), %rsi
movq %rbx, %rdx
movq %r13, %rcx
movl $0xe, %r8d
callq 0x6bc4e
movq %r15, (%rbx)
movq 0x8(%rbx), %rdi
movq %rbp, 0x8(%rbx)
testq %rdi, %rdi
je 0x515d6
callq 0x32b80
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x5152c
callq 0x32b80
jmp 0x5152c
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x515fd
callq 0x32b80
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x1a3b0
movq %rax, %r15
leaq 0x6d61b(%rip), %rsi # 0xbec3e
movq %rax, %rdi
callq 0x1a2a0
movq 0xa39be(%rip), %rsi # 0xf4ff0
movq 0xa3937(%rip), %rdx # 0xf4f70
movq %r15, %rdi
callq 0x1ad60
jmp 0x51675
movl $0x10, %edi
callq 0x1a3b0
movq %rax, %r15
leaq 0x6d5b2(%rip), %rsi # 0xbec09
movq %rax, %rdi
callq 0x1a2a0
movq 0xa398a(%rip), %rsi # 0xf4ff0
movq 0xa3903(%rip), %rdx # 0xf4f70
movq %r15, %rdi
callq 0x1ad60
leaq 0xa4b64(%rip), %rdi # 0xf61e0
callq 0x1ae10
testl %eax, %eax
je 0x514e2
leaq 0xa4b30(%rip), %rdi # 0xf61c0
leaq 0x6d5a1(%rip), %rsi # 0xbec38
movl $0x10, %edx
callq 0x2559e
leaq -0x2bcc8(%rip), %rdi # 0x259e0
leaq 0xa4b11(%rip), %rsi # 0xf61c0
leaq 0xa4102(%rip), %rdx # 0xf57b8
callq 0x1a6a0
leaq 0xa4b1e(%rip), %rdi # 0xf61e0
callq 0x1a4d0
jmp 0x514e2
movq %rax, %r14
leaq 0xa4b0a(%rip), %rdi # 0xf61e0
callq 0x1a4c0
jmp 0x51726
movq %rax, %r14
jmp 0x51726
movq %rax, %r14
movq %r15, %rdi
callq 0x1a5a0
jmp 0x51726
jmp 0x51700
movq %rax, %r14
movq %r15, %rdi
callq 0x1a5a0
jmp 0x51703
jmp 0x51714
movq %rax, %r14
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x51717
callq 0x32b80
jmp 0x51717
movq %rax, %r14
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x51726
callq 0x32b80
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x51734
callq 0x32b80
movq %r14, %rdi
callq 0x1adc0
| _ZN5minja6Parser15parseLogicalAndEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov r14, rsi
mov rbx, rdi
call _ZN5minja6Parser15parseLogicalNotEv; minja::Parser::parseLogicalNot(void)
cmp qword ptr [rbx], 0
jz loc_51643
lea rax, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; `guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok
mov al, [rax]
test al, al
jz loc_51675
loc_514E2:
mov rax, [r14]
mov [rsp+68h+var_48], rax
mov rax, [r14+8]
mov [rsp+68h+var_40], rax
test rax, rax
jz short loc_5150D
mov rcx, cs:__libc_single_threaded_ptr
cmp byte ptr [rcx], 0
jz short loc_51509
inc dword ptr [rax+8]
jmp short loc_5150D
loc_51509:
lock inc dword ptr [rax+8]
loc_5150D:
mov rax, [r14+20h]
sub rax, [r14+10h]
lea rcx, [rsp+68h+var_48]
mov [rcx+10h], rax
mov r13, rsp
lea r12, _ZTVSt23_Sp_counted_ptr_inplaceIN5minja12BinaryOpExprESaIS1_ELN9__gnu_cxx12_Lock_policyE2EE; `vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2>
add r12, 10h
loc_5152C:
mov rdi, r13
mov rsi, r14
lea rdx, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; minja::Parser::parseLogicalAnd(void)::and_tok
mov ecx, 1
call _ZN5minja6Parser12consumeTokenERKNSt7__cxx1111basic_regexIcNS1_12regex_traitsIcEEEENS_13SpaceHandlingE; minja::Parser::consumeToken(std::basic_regex<char,std::regex_traits<char>> const&,minja::SpaceHandling)
mov rdi, [rsp+68h+var_68]; void *
mov r15, [rsp+68h+var_60]
lea rax, [rsp+68h+var_58]
cmp rdi, rax
jz short loc_51563
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_51563:
test r15, r15
jz loc_515EE
mov rdi, r13; this
mov rsi, r14
call _ZN5minja6Parser15parseLogicalNotEv; minja::Parser::parseLogicalNot(void)
cmp [rsp+68h+var_68], 0
jz loc_5160F
mov edi, 58h ; 'X'; unsigned __int64
call __Znwm; operator new(ulong)
mov rbp, rax
mov rax, 100000001h
mov [rbp+8], rax
mov [rbp+0], r12
mov r15, rbp
add r15, 10h
mov rdi, r15
lea rsi, [rsp+68h+var_48]
mov rdx, rbx
mov rcx, r13
mov r8d, 0Eh
call _ZN5minja12BinaryOpExprC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEES7_NS0_2OpE; minja::BinaryOpExpr::BinaryOpExpr(minja::Location const&,std::shared_ptr<minja::Expression> &&,std::shared_ptr<minja::Expression> &,minja::BinaryOpExpr::Op)
mov [rbx], r15
mov rdi, [rbx+8]
mov [rbx+8], rbp
test rdi, rdi
jz short loc_515D6
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_515D6:
mov rdi, [rsp+68h+var_60]
test rdi, rdi
jz loc_5152C
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
jmp loc_5152C
loc_515EE:
mov rdi, [rsp+68h+var_40]
test rdi, rdi
jz short loc_515FD
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_515FD:
mov rax, rbx
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_5160F:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedRightS_0; "Expected right side of 'and' expression"
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
jmp short loc_51675
loc_51643:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedLeftSi_0; "Expected left side of 'logical and' exp"...
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
loc_51675:
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_acquire
test eax, eax
jz loc_514E2
lea rdi, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; minja::Parser::parseLogicalAnd(void)::and_tok
lea rsi, aAndB; "and\\b"
mov edx, 10h
call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEEC2EPKcNSt15regex_constants18syntax_option_typeE; std::basic_regex<char,std::regex_traits<char>>::basic_regex(char const*,std::regex_constants::syntax_option_type)
lea rdi, _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; lpfunc
lea rsi, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; obj
lea rdx, __dso_handle; lpdso_handle
call ___cxa_atexit
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_release
jmp loc_514E2
mov r14, rax
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_abort
jmp short loc_51726
mov r14, rax
jmp short loc_51726
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_51726
jmp short loc_51700
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_51703
jmp short loc_51714
loc_51700:
mov r14, rax
loc_51703:
mov rdi, [rsp+arg_0]
test rdi, rdi
jz short loc_51717
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
jmp short loc_51717
loc_51714:
mov r14, rax
loc_51717:
mov rdi, [rsp+arg_20]
test rdi, rdi
jz short loc_51726
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_51726:
mov rdi, [rbx+8]
test rdi, rdi
jz short loc_51734
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_51734:
mov rdi, r14
call __Unwind_Resume
| minja::Parser * minja::Parser::parseLogicalAnd(volatile signed __int32 **this, long long *a2)
{
volatile signed __int32 *v3; // rax
volatile signed __int32 *v4; // r15
volatile signed __int32 *v5; // rbp
volatile signed __int32 *v6; // rdi
std::runtime_error *v8; // r15
std::runtime_error *exception; // r15
void *v10; // [rsp+0h] [rbp-68h] BYREF
volatile signed __int32 *v11; // [rsp+8h] [rbp-60h]
long long v12; // [rsp+10h] [rbp-58h] BYREF
long long v13; // [rsp+20h] [rbp-48h] BYREF
volatile signed __int32 *v14; // [rsp+28h] [rbp-40h]
long long v15; // [rsp+30h] [rbp-38h]
minja::Parser::parseLogicalNot((minja::Parser *)this);
if ( !*this )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Expected left side of 'logical and' expression");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
if ( !(_BYTE)`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]
&& __cxa_guard_acquire(&`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]) )
{
std::basic_regex<char,std::regex_traits<char>>::basic_regex(
(long long)&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
(long long)"and\\b",
0x10u);
__cxa_atexit(
(void (*)(void *))std::basic_regex<char,std::regex_traits<char>>::~basic_regex,
&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
&_dso_handle);
__cxa_guard_release(&`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]);
}
v13 = *a2;
v3 = (volatile signed __int32 *)a2[1];
v14 = v3;
if ( v3 )
{
if ( _libc_single_threaded )
++*((_DWORD *)v3 + 2);
else
_InterlockedIncrement(v3 + 2);
}
v15 = a2[4] - a2[2];
while ( 1 )
{
minja::Parser::consumeToken(
(long long)&v10,
(long long)a2,
(long long)&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
1u);
v4 = v11;
if ( v10 != &v12 )
operator delete(v10, v12 + 1);
if ( !v4 )
break;
minja::Parser::parseLogicalNot((minja::Parser *)&v10);
if ( !v10 )
{
v8 = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(v8, "Expected right side of 'and' expression");
__cxa_throw(
v8,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
v5 = (volatile signed __int32 *)operator new(0x58uLL);
*((_QWORD *)v5 + 1) = 0x100000001LL;
*(_QWORD *)v5 = &`vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2>
+ 2;
minja::BinaryOpExpr::BinaryOpExpr(v5 + 4, &v13, this, &v10, 14LL);
*this = v5 + 4;
v6 = this[1];
this[1] = v5;
if ( v6 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v6);
if ( v11 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v11);
}
if ( v14 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v14);
return (minja::Parser *)this;
}
| parseLogicalAnd:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV R14,RSI
MOV RBX,RDI
CALL 0x0015173c
CMP qword ptr [RBX],0x0
JZ 0x00151643
LEA RAX,[0x1f61e0]
MOV AL,byte ptr [RAX]
TEST AL,AL
JZ 0x00151675
LAB_001514e2:
MOV RAX,qword ptr [R14]
MOV qword ptr [RSP + 0x20],RAX
MOV RAX,qword ptr [R14 + 0x8]
MOV qword ptr [RSP + 0x28],RAX
TEST RAX,RAX
JZ 0x0015150d
MOV RCX,qword ptr [0x001f4f98]
CMP byte ptr [RCX],0x0
JZ 0x00151509
INC dword ptr [RAX + 0x8]
JMP 0x0015150d
LAB_00151509:
INC.LOCK dword ptr [RAX + 0x8]
LAB_0015150d:
MOV RAX,qword ptr [R14 + 0x20]
SUB RAX,qword ptr [R14 + 0x10]
LEA RCX,[RSP + 0x20]
MOV qword ptr [RCX + 0x10],RAX
MOV R13,RSP
LEA R12,[0x1f3998]
ADD R12,0x10
LAB_0015152c:
MOV RDI,R13
MOV RSI,R14
LEA RDX,[0x1f61c0]
MOV ECX,0x1
CALL 0x0014fe98
MOV RDI,qword ptr [RSP]
MOV R15,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x10]
CMP RDI,RAX
JZ 0x00151563
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0011a7f0
LAB_00151563:
TEST R15,R15
JZ 0x001515ee
LAB_0015156c:
MOV RDI,R13
MOV RSI,R14
CALL 0x0015173c
CMP qword ptr [RSP],0x0
JZ 0x0015160f
LAB_00151582:
MOV EDI,0x58
CALL 0x0011a7d0
LAB_0015158c:
MOV RBP,RAX
MOV RAX,0x100000001
MOV qword ptr [RBP + 0x8],RAX
MOV qword ptr [RBP],R12
MOV R15,RBP
ADD R15,0x10
MOV RDI,R15
LEA RSI,[RSP + 0x20]
MOV RDX,RBX
MOV RCX,R13
MOV R8D,0xe
CALL 0x0016bc4e
MOV qword ptr [RBX],R15
MOV RDI,qword ptr [RBX + 0x8]
MOV qword ptr [RBX + 0x8],RBP
TEST RDI,RDI
JZ 0x001515d6
CALL 0x00132b80
LAB_001515d6:
MOV RDI,qword ptr [RSP + 0x8]
TEST RDI,RDI
JZ 0x0015152c
CALL 0x00132b80
JMP 0x0015152c
LAB_001515ee:
MOV RDI,qword ptr [RSP + 0x28]
TEST RDI,RDI
JZ 0x001515fd
CALL 0x00132b80
LAB_001515fd:
MOV RAX,RBX
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0015160f:
MOV EDI,0x10
CALL 0x0011a3b0
MOV R15,RAX
LAB_0015161c:
LEA RSI,[0x1bec3e]
MOV RDI,RAX
CALL 0x0011a2a0
LAB_0015162b:
MOV RSI,qword ptr [0x001f4ff0]
MOV RDX,qword ptr [0x001f4f70]
MOV RDI,R15
CALL 0x0011ad60
LAB_00151643:
MOV EDI,0x10
CALL 0x0011a3b0
MOV R15,RAX
LAB_00151650:
LEA RSI,[0x1bec09]
MOV RDI,RAX
CALL 0x0011a2a0
LAB_0015165f:
MOV RSI,qword ptr [0x001f4ff0]
MOV RDX,qword ptr [0x001f4f70]
MOV RDI,R15
CALL 0x0011ad60
LAB_00151675:
LEA RDI,[0x1f61e0]
CALL 0x0011ae10
TEST EAX,EAX
JZ 0x001514e2
LAB_00151689:
LEA RDI,[0x1f61c0]
LEA RSI,[0x1bec38]
MOV EDX,0x10
CALL 0x0012559e
LAB_001516a1:
LEA RDI,[0x1259e0]
LEA RSI,[0x1f61c0]
LEA RDX,[0x1f57b8]
CALL 0x0011a6a0
LEA RDI,[0x1f61e0]
CALL 0x0011a4d0
JMP 0x001514e2
|
/* minja::Parser::parseLogicalAnd() */
void minja::Parser::parseLogicalAnd(void)
{
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Var1;
int iVar2;
int8 *puVar3;
runtime_error *prVar4;
int8 *in_RSI;
long *in_RDI;
long *local_68;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_60;
long local_58 [2];
int8 local_48;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_40;
long local_38;
parseLogicalNot();
if (*in_RDI == 0) {
prVar4 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00151650 to 0015165e has its CatchHandler @ 001516e2 */
std::runtime_error::runtime_error(prVar4,"Expected left side of \'logical and\' expression");
/* try { // try from 0015165f to 00151674 has its CatchHandler @ 001516dd */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar4,PTR_typeinfo_001f4ff0,PTR__runtime_error_001f4f70);
}
if (parseLogicalAnd()::and_tok_abi_cxx11_ == '\0') {
iVar2 = __cxa_guard_acquire(&parseLogicalAnd()::and_tok_abi_cxx11_);
if (iVar2 != 0) {
/* try { // try from 00151689 to 001516a0 has its CatchHandler @ 001516cc */
std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::basic_regex
((basic_regex<char,std::__cxx11::regex_traits<char>> *)
parseLogicalAnd()::and_tok_abi_cxx11_,"and\\b",0x10);
__cxa_atexit(std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex,
parseLogicalAnd()::and_tok_abi_cxx11_,&__dso_handle);
__cxa_guard_release(&parseLogicalAnd()::and_tok_abi_cxx11_);
}
}
local_48 = *in_RSI;
local_40 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RSI[1];
if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
if (*PTR___libc_single_threaded_001f4f98 == '\0') {
LOCK();
*(int *)(local_40 + 8) = *(int *)(local_40 + 8) + 1;
UNLOCK();
}
else {
*(int *)(local_40 + 8) = *(int *)(local_40 + 8) + 1;
}
}
local_38 = in_RSI[4] - in_RSI[2];
while( true ) {
/* try { // try from 0015152c to 00151542 has its CatchHandler @ 00151714 */
consumeToken(&local_68);
p_Var1 = local_60;
if (local_68 != local_58) {
operator_delete(local_68,local_58[0] + 1);
}
if (p_Var1 == (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) break;
/* try { // try from 0015156c to 00151576 has its CatchHandler @ 001516fe */
parseLogicalNot();
if (local_68 == (long *)0x0) {
prVar4 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0015161c to 0015162a has its CatchHandler @ 001516f1 */
std::runtime_error::runtime_error(prVar4,"Expected right side of \'and\' expression");
/* try { // try from 0015162b to 00151640 has its CatchHandler @ 001516ef */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar4,PTR_typeinfo_001f4ff0,PTR__runtime_error_001f4f70);
}
/* try { // try from 00151582 to 0015158b has its CatchHandler @ 00151700 */
puVar3 = (int8 *)operator_new(0x58);
puVar3[1] = 0x100000001;
*puVar3 = &PTR___Sp_counted_ptr_inplace_001f39a8;
BinaryOpExpr::BinaryOpExpr((BinaryOpExpr *)(puVar3 + 2),&local_48);
*in_RDI = (long)(puVar3 + 2);
p_Var1 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RDI[1];
in_RDI[1] = (long)puVar3;
if (p_Var1 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Var1);
}
if (local_60 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_60);
}
}
if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_40);
}
return;
}
| |
23,356 | minja::Parser::parseLogicalAnd() | monkey531[P]llama/common/minja.hpp | std::shared_ptr<Expression> parseLogicalAnd() {
auto left = parseLogicalNot();
if (!left) throw std::runtime_error("Expected left side of 'logical and' expression");
static std::regex and_tok(R"(and\b)");
auto location = get_location();
while (!consumeToken(and_tok).empty()) {
auto right = parseLogicalNot();
if (!right) throw std::runtime_error("Expected right side of 'and' expression");
left = std::make_shared<BinaryOpExpr>(location, std::move(left), std::move(right), BinaryOpExpr::Op::And);
}
return left;
} | O3 | cpp | minja::Parser::parseLogicalAnd():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x4f928
cmpq $0x0, (%rbx)
je 0x4f82f
leaq 0xa2b1c(%rip), %rax # 0xf21e0
movb (%rax), %al
testb %al, %al
je 0x4f861
movq (%r14), %rax
movq %rax, 0x20(%rsp)
movq 0x8(%r14), %rax
movq %rax, 0x28(%rsp)
testq %rax, %rax
je 0x4f6f9
movq 0xa18ad(%rip), %rcx # 0xf0f98
cmpb $0x0, (%rcx)
je 0x4f6f5
incl 0x8(%rax)
jmp 0x4f6f9
lock
incl 0x8(%rax)
movq 0x20(%r14), %rax
subq 0x10(%r14), %rax
leaq 0x20(%rsp), %rcx
movq %rax, 0x10(%rcx)
movq %rsp, %r13
leaq 0xa0284(%rip), %r12 # 0xef998
addq $0x10, %r12
movq %r13, %rdi
movq %r14, %rsi
leaq 0xa2a9b(%rip), %rdx # 0xf21c0
movl $0x1, %ecx
callq 0x4e0ce
movq (%rsp), %rdi
movq 0x8(%rsp), %r15
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x4f74f
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x197f0
testq %r15, %r15
je 0x4f7da
movq %r13, %rdi
movq %r14, %rsi
callq 0x4f928
cmpq $0x0, (%rsp)
je 0x4f7fb
movl $0x58, %edi
callq 0x197d0
movq %rax, %rbp
movabsq $0x100000001, %rax # imm = 0x100000001
movq %rax, 0x8(%rbp)
movq %r12, (%rbp)
movq %rbp, %r15
addq $0x10, %r15
movq %r15, %rdi
leaq 0x20(%rsp), %rsi
movq %rbx, %rdx
movq %r13, %rcx
movl $0xe, %r8d
callq 0x69908
movq %r15, (%rbx)
movq 0x8(%rbx), %rdi
movq %rbp, 0x8(%rbx)
testq %rdi, %rdi
je 0x4f7c2
callq 0x31b9a
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x4f718
callq 0x31b9a
jmp 0x4f718
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x4f7e9
callq 0x31b9a
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x193b0
movq %rax, %r15
leaq 0x6b41f(%rip), %rsi # 0xbac2e
movq %rax, %rdi
callq 0x192a0
movq 0xa17d2(%rip), %rsi # 0xf0ff0
movq 0xa174b(%rip), %rdx # 0xf0f70
movq %r15, %rdi
callq 0x19d60
jmp 0x4f861
movl $0x10, %edi
callq 0x193b0
movq %rax, %r15
leaq 0x6b3b6(%rip), %rsi # 0xbabf9
movq %rax, %rdi
callq 0x192a0
movq 0xa179e(%rip), %rsi # 0xf0ff0
movq 0xa1717(%rip), %rdx # 0xf0f70
movq %r15, %rdi
callq 0x19d60
leaq 0xa2978(%rip), %rdi # 0xf21e0
callq 0x19e10
testl %eax, %eax
je 0x4f6ce
leaq 0xa2944(%rip), %rdi # 0xf21c0
leaq 0x6b3a5(%rip), %rsi # 0xbac28
movl $0x10, %edx
callq 0x2457a
leaq -0x2aeda(%rip), %rdi # 0x249ba
leaq 0xa2925(%rip), %rsi # 0xf21c0
leaq 0xa1f16(%rip), %rdx # 0xf17b8
callq 0x196a0
leaq 0xa2932(%rip), %rdi # 0xf21e0
callq 0x194d0
jmp 0x4f6ce
movq %rax, %r14
leaq 0xa291e(%rip), %rdi # 0xf21e0
callq 0x194c0
jmp 0x4f912
movq %rax, %r14
jmp 0x4f912
movq %rax, %r14
movq %r15, %rdi
callq 0x195a0
jmp 0x4f912
jmp 0x4f8ec
movq %rax, %r14
movq %r15, %rdi
callq 0x195a0
jmp 0x4f8ef
jmp 0x4f900
movq %rax, %r14
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x4f903
callq 0x31b9a
jmp 0x4f903
movq %rax, %r14
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x4f912
callq 0x31b9a
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x4f920
callq 0x31b9a
movq %r14, %rdi
callq 0x19dc0
| _ZN5minja6Parser15parseLogicalAndEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov r14, rsi
mov rbx, rdi
call _ZN5minja6Parser15parseLogicalNotEv; minja::Parser::parseLogicalNot(void)
cmp qword ptr [rbx], 0
jz loc_4F82F
lea rax, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; `guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok
mov al, [rax]
test al, al
jz loc_4F861
loc_4F6CE:
mov rax, [r14]
mov [rsp+68h+var_48], rax
mov rax, [r14+8]
mov [rsp+68h+var_40], rax
test rax, rax
jz short loc_4F6F9
mov rcx, cs:__libc_single_threaded_ptr
cmp byte ptr [rcx], 0
jz short loc_4F6F5
inc dword ptr [rax+8]
jmp short loc_4F6F9
loc_4F6F5:
lock inc dword ptr [rax+8]
loc_4F6F9:
mov rax, [r14+20h]
sub rax, [r14+10h]
lea rcx, [rsp+68h+var_48]
mov [rcx+10h], rax
mov r13, rsp
lea r12, _ZTVSt23_Sp_counted_ptr_inplaceIN5minja12BinaryOpExprESaIS1_ELN9__gnu_cxx12_Lock_policyE2EE; `vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2>
add r12, 10h
loc_4F718:
mov rdi, r13
mov rsi, r14
lea rdx, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; minja::Parser::parseLogicalAnd(void)::and_tok
mov ecx, 1
call _ZN5minja6Parser12consumeTokenERKNSt7__cxx1111basic_regexIcNS1_12regex_traitsIcEEEENS_13SpaceHandlingE; minja::Parser::consumeToken(std::basic_regex<char,std::regex_traits<char>> const&,minja::SpaceHandling)
mov rdi, [rsp+68h+var_68]; void *
mov r15, [rsp+68h+var_60]
lea rax, [rsp+68h+var_58]
cmp rdi, rax
jz short loc_4F74F
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_4F74F:
test r15, r15
jz loc_4F7DA
mov rdi, r13; this
mov rsi, r14
call _ZN5minja6Parser15parseLogicalNotEv; minja::Parser::parseLogicalNot(void)
cmp [rsp+68h+var_68], 0
jz loc_4F7FB
mov edi, 58h ; 'X'; unsigned __int64
call __Znwm; operator new(ulong)
mov rbp, rax
mov rax, 100000001h
mov [rbp+8], rax
mov [rbp+0], r12
mov r15, rbp
add r15, 10h
mov rdi, r15
lea rsi, [rsp+68h+var_48]
mov rdx, rbx
mov rcx, r13
mov r8d, 0Eh
call _ZN5minja12BinaryOpExprC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEES7_NS0_2OpE; minja::BinaryOpExpr::BinaryOpExpr(minja::Location const&,std::shared_ptr<minja::Expression> &&,std::shared_ptr<minja::Expression> &,minja::BinaryOpExpr::Op)
mov [rbx], r15
mov rdi, [rbx+8]
mov [rbx+8], rbp
test rdi, rdi
jz short loc_4F7C2
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_4F7C2:
mov rdi, [rsp+68h+var_60]
test rdi, rdi
jz loc_4F718
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
jmp loc_4F718
loc_4F7DA:
mov rdi, [rsp+68h+var_40]
test rdi, rdi
jz short loc_4F7E9
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_4F7E9:
mov rax, rbx
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_4F7FB:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedRightS_0; "Expected right side of 'and' expression"
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
jmp short loc_4F861
loc_4F82F:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedLeftSi_0; "Expected left side of 'logical and' exp"...
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
loc_4F861:
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_acquire
test eax, eax
jz loc_4F6CE
lea rdi, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; minja::Parser::parseLogicalAnd(void)::and_tok
lea rsi, aAndB; "and\\b"
mov edx, 10h
call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEEC2EPKcNSt15regex_constants18syntax_option_typeE; std::basic_regex<char,std::regex_traits<char>>::basic_regex(char const*,std::regex_constants::syntax_option_type)
lea rdi, _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; lpfunc
lea rsi, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; obj
lea rdx, __dso_handle; lpdso_handle
call ___cxa_atexit
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_release
jmp loc_4F6CE
mov r14, rax
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_abort
jmp short loc_4F912
mov r14, rax
jmp short loc_4F912
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_4F912
jmp short loc_4F8EC
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_4F8EF
jmp short loc_4F900
loc_4F8EC:
mov r14, rax
loc_4F8EF:
mov rdi, [rsp+arg_0]
test rdi, rdi
jz short loc_4F903
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
jmp short loc_4F903
loc_4F900:
mov r14, rax
loc_4F903:
mov rdi, [rsp+arg_20]
test rdi, rdi
jz short loc_4F912
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_4F912:
mov rdi, [rbx+8]
test rdi, rdi
jz short loc_4F920
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_4F920:
mov rdi, r14
call __Unwind_Resume
| minja::Parser * minja::Parser::parseLogicalAnd(volatile signed __int32 **this, long long *a2)
{
volatile signed __int32 *v3; // rax
volatile signed __int32 *v4; // r15
volatile signed __int32 *v5; // rbp
volatile signed __int32 *v6; // rdi
std::runtime_error *v8; // r15
std::runtime_error *exception; // r15
void *v10; // [rsp+0h] [rbp-68h] BYREF
volatile signed __int32 *v11; // [rsp+8h] [rbp-60h]
long long v12; // [rsp+10h] [rbp-58h] BYREF
long long v13; // [rsp+20h] [rbp-48h] BYREF
volatile signed __int32 *v14; // [rsp+28h] [rbp-40h]
long long v15; // [rsp+30h] [rbp-38h]
minja::Parser::parseLogicalNot((minja::Parser *)this);
if ( !*this )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Expected left side of 'logical and' expression");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
if ( !(_BYTE)`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]
&& __cxa_guard_acquire(&`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]) )
{
std::basic_regex<char,std::regex_traits<char>>::basic_regex(
(long long)&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
(long long)"and\\b",
0x10u);
__cxa_atexit(
(void (*)(void *))std::basic_regex<char,std::regex_traits<char>>::~basic_regex,
&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
&_dso_handle);
__cxa_guard_release(&`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]);
}
v13 = *a2;
v3 = (volatile signed __int32 *)a2[1];
v14 = v3;
if ( v3 )
{
if ( _libc_single_threaded )
++*((_DWORD *)v3 + 2);
else
_InterlockedIncrement(v3 + 2);
}
v15 = a2[4] - a2[2];
while ( 1 )
{
minja::Parser::consumeToken(
(long long)&v10,
(long long)a2,
(long long)&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
1u);
v4 = v11;
if ( v10 != &v12 )
operator delete(v10, v12 + 1);
if ( !v4 )
break;
minja::Parser::parseLogicalNot((minja::Parser *)&v10);
if ( !v10 )
{
v8 = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(v8, "Expected right side of 'and' expression");
__cxa_throw(
v8,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
v5 = (volatile signed __int32 *)operator new(0x58uLL);
*((_QWORD *)v5 + 1) = 0x100000001LL;
*(_QWORD *)v5 = &`vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2>
+ 2;
minja::BinaryOpExpr::BinaryOpExpr(v5 + 4, &v13, this, &v10, 14LL);
*this = v5 + 4;
v6 = this[1];
this[1] = v5;
if ( v6 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v6);
if ( v11 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v11);
}
if ( v14 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v14);
return (minja::Parser *)this;
}
| parseLogicalAnd:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV R14,RSI
MOV RBX,RDI
CALL 0x0014f928
CMP qword ptr [RBX],0x0
JZ 0x0014f82f
LEA RAX,[0x1f21e0]
MOV AL,byte ptr [RAX]
TEST AL,AL
JZ 0x0014f861
LAB_0014f6ce:
MOV RAX,qword ptr [R14]
MOV qword ptr [RSP + 0x20],RAX
MOV RAX,qword ptr [R14 + 0x8]
MOV qword ptr [RSP + 0x28],RAX
TEST RAX,RAX
JZ 0x0014f6f9
MOV RCX,qword ptr [0x001f0f98]
CMP byte ptr [RCX],0x0
JZ 0x0014f6f5
INC dword ptr [RAX + 0x8]
JMP 0x0014f6f9
LAB_0014f6f5:
INC.LOCK dword ptr [RAX + 0x8]
LAB_0014f6f9:
MOV RAX,qword ptr [R14 + 0x20]
SUB RAX,qword ptr [R14 + 0x10]
LEA RCX,[RSP + 0x20]
MOV qword ptr [RCX + 0x10],RAX
MOV R13,RSP
LEA R12,[0x1ef998]
ADD R12,0x10
LAB_0014f718:
MOV RDI,R13
MOV RSI,R14
LEA RDX,[0x1f21c0]
MOV ECX,0x1
CALL 0x0014e0ce
MOV RDI,qword ptr [RSP]
MOV R15,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x10]
CMP RDI,RAX
JZ 0x0014f74f
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x001197f0
LAB_0014f74f:
TEST R15,R15
JZ 0x0014f7da
LAB_0014f758:
MOV RDI,R13
MOV RSI,R14
CALL 0x0014f928
CMP qword ptr [RSP],0x0
JZ 0x0014f7fb
LAB_0014f76e:
MOV EDI,0x58
CALL 0x001197d0
LAB_0014f778:
MOV RBP,RAX
MOV RAX,0x100000001
MOV qword ptr [RBP + 0x8],RAX
MOV qword ptr [RBP],R12
MOV R15,RBP
ADD R15,0x10
MOV RDI,R15
LEA RSI,[RSP + 0x20]
MOV RDX,RBX
MOV RCX,R13
MOV R8D,0xe
CALL 0x00169908
MOV qword ptr [RBX],R15
MOV RDI,qword ptr [RBX + 0x8]
MOV qword ptr [RBX + 0x8],RBP
TEST RDI,RDI
JZ 0x0014f7c2
CALL 0x00131b9a
LAB_0014f7c2:
MOV RDI,qword ptr [RSP + 0x8]
TEST RDI,RDI
JZ 0x0014f718
CALL 0x00131b9a
JMP 0x0014f718
LAB_0014f7da:
MOV RDI,qword ptr [RSP + 0x28]
TEST RDI,RDI
JZ 0x0014f7e9
CALL 0x00131b9a
LAB_0014f7e9:
MOV RAX,RBX
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0014f7fb:
MOV EDI,0x10
CALL 0x001193b0
MOV R15,RAX
LAB_0014f808:
LEA RSI,[0x1bac2e]
MOV RDI,RAX
CALL 0x001192a0
LAB_0014f817:
MOV RSI,qword ptr [0x001f0ff0]
MOV RDX,qword ptr [0x001f0f70]
MOV RDI,R15
CALL 0x00119d60
LAB_0014f82f:
MOV EDI,0x10
CALL 0x001193b0
MOV R15,RAX
LAB_0014f83c:
LEA RSI,[0x1babf9]
MOV RDI,RAX
CALL 0x001192a0
LAB_0014f84b:
MOV RSI,qword ptr [0x001f0ff0]
MOV RDX,qword ptr [0x001f0f70]
MOV RDI,R15
CALL 0x00119d60
LAB_0014f861:
LEA RDI,[0x1f21e0]
CALL 0x00119e10
TEST EAX,EAX
JZ 0x0014f6ce
LAB_0014f875:
LEA RDI,[0x1f21c0]
LEA RSI,[0x1bac28]
MOV EDX,0x10
CALL 0x0012457a
LAB_0014f88d:
LEA RDI,[0x1249ba]
LEA RSI,[0x1f21c0]
LEA RDX,[0x1f17b8]
CALL 0x001196a0
LEA RDI,[0x1f21e0]
CALL 0x001194d0
JMP 0x0014f6ce
|
/* minja::Parser::parseLogicalAnd() */
void minja::Parser::parseLogicalAnd(void)
{
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Var1;
int iVar2;
int8 *puVar3;
runtime_error *prVar4;
int8 *in_RSI;
long *in_RDI;
long *local_68;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_60;
long local_58 [2];
int8 local_48;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_40;
long local_38;
parseLogicalNot();
if (*in_RDI == 0) {
prVar4 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0014f83c to 0014f84a has its CatchHandler @ 0014f8ce */
std::runtime_error::runtime_error(prVar4,"Expected left side of \'logical and\' expression");
/* try { // try from 0014f84b to 0014f860 has its CatchHandler @ 0014f8c9 */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar4,PTR_typeinfo_001f0ff0,PTR__runtime_error_001f0f70);
}
if (parseLogicalAnd()::and_tok_abi_cxx11_ == '\0') {
iVar2 = __cxa_guard_acquire(&parseLogicalAnd()::and_tok_abi_cxx11_);
if (iVar2 != 0) {
/* try { // try from 0014f875 to 0014f88c has its CatchHandler @ 0014f8b8 */
std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::basic_regex
((basic_regex<char,std::__cxx11::regex_traits<char>> *)
parseLogicalAnd()::and_tok_abi_cxx11_,"and\\b",0x10);
__cxa_atexit(std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex,
parseLogicalAnd()::and_tok_abi_cxx11_,&__dso_handle);
__cxa_guard_release(&parseLogicalAnd()::and_tok_abi_cxx11_);
}
}
local_48 = *in_RSI;
local_40 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RSI[1];
if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
if (*PTR___libc_single_threaded_001f0f98 == '\0') {
LOCK();
*(int *)(local_40 + 8) = *(int *)(local_40 + 8) + 1;
UNLOCK();
}
else {
*(int *)(local_40 + 8) = *(int *)(local_40 + 8) + 1;
}
}
local_38 = in_RSI[4] - in_RSI[2];
while( true ) {
/* try { // try from 0014f718 to 0014f72e has its CatchHandler @ 0014f900 */
consumeToken(&local_68);
p_Var1 = local_60;
if (local_68 != local_58) {
operator_delete(local_68,local_58[0] + 1);
}
if (p_Var1 == (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) break;
/* try { // try from 0014f758 to 0014f762 has its CatchHandler @ 0014f8ea */
parseLogicalNot();
if (local_68 == (long *)0x0) {
prVar4 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0014f808 to 0014f816 has its CatchHandler @ 0014f8dd */
std::runtime_error::runtime_error(prVar4,"Expected right side of \'and\' expression");
/* try { // try from 0014f817 to 0014f82c has its CatchHandler @ 0014f8db */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar4,PTR_typeinfo_001f0ff0,PTR__runtime_error_001f0f70);
}
/* try { // try from 0014f76e to 0014f777 has its CatchHandler @ 0014f8ec */
puVar3 = (int8 *)operator_new(0x58);
puVar3[1] = 0x100000001;
*puVar3 = &PTR___Sp_counted_ptr_inplace_001ef9a8;
BinaryOpExpr::BinaryOpExpr((BinaryOpExpr *)(puVar3 + 2),&local_48);
*in_RDI = (long)(puVar3 + 2);
p_Var1 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RDI[1];
in_RDI[1] = (long)puVar3;
if (p_Var1 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Var1);
}
if (local_60 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_60);
}
}
if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_40);
}
return;
}
| |
23,357 | LefDefParser::lefwMacroPinForeign(char const*, double, double, int) | Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp | int
lefwMacroPinForeign(const char *name,
double xl,
double yl,
int orient)
{ // optional
lefwObsoleteNum = LEFW_MACRO_PINFOREIGN;
if (!lefwFile)
return LEFW_UNINITIALIZED;
if (!lefwDidInit)
return LEFW_BAD_ORDER;
if (!lefwIsMacroPin)
return LEFW_BAD_ORDER;
if (versionNum >= 5.6)
return LEFW_OBSOLETE;
if (!name || name == 0 || *name == 0)
return LEFW_BAD_DATA;
if (lefwWriteEncrypt) {
encPrint(lefwFile, (char*) " FOREIGN %s ", name);
if (xl || yl) {
encPrint(lefwFile, (char*) "STRUCTURE %.11g %.11g ", xl, yl);
if (orient >= 0 && orient <= 7)
encPrint(lefwFile, (char*) "%s ", lefwOrient(orient));
} else if (orient > 0 && orient <= 7) { // assume user has 0 0 for pt
encPrint(lefwFile, (char*) "STRUCTURE %.11g %.11g ", xl, yl);
encPrint(lefwFile, (char*) "%s ", lefwOrient(orient));
}
encPrint(lefwFile, (char*) ";\n");
} else {
fprintf(lefwFile, " FOREIGN %s ", name);
if (xl || yl) {
fprintf(lefwFile, "STRUCTURE %.11g %.11g ", xl, yl);
if (orient >= 0 && orient <= 7)
fprintf(lefwFile, "%s ", lefwOrient(orient));
} else if (orient > 0 && orient <= 7) { // assume user has 0 0 for pt
fprintf(lefwFile, "STRUCTURE %.11g %.11g ", xl, yl);
fprintf(lefwFile, "%s ", lefwOrient(orient));
}
fprintf(lefwFile, ";\n");
}
lefwLines++;
lefwState = LEFW_MACRO;
return LEFW_OK;
} | O0 | cpp | LefDefParser::lefwMacroPinForeign(char const*, double, double, int):
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movsd %xmm0, 0x30(%rsp)
movsd %xmm1, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movl $0x2d, 0x12b05(%rip) # 0x32d48
leaq 0x12bb6(%rip), %rax # 0x32e00
cmpq $0x0, (%rax)
jne 0x2025d
movl $0x1, 0x44(%rsp)
jmp 0x20550
leaq 0x12df0(%rip), %rax # 0x33054
cmpl $0x0, (%rax)
jne 0x20276
movl $0x2, 0x44(%rsp)
jmp 0x20550
leaq 0x12e23(%rip), %rax # 0x330a0
cmpl $0x0, (%rax)
jne 0x2028f
movl $0x2, 0x44(%rsp)
jmp 0x20550
movsd 0x12aa9(%rip), %xmm0 # 0x32d40
movsd 0x8f51(%rip), %xmm1 # 0x291f0
ucomisd %xmm1, %xmm0
jb 0x202b2
movl $0x7, 0x44(%rsp)
jmp 0x20550
cmpq $0x0, 0x38(%rsp)
je 0x202cf
cmpq $0x0, 0x38(%rsp)
je 0x202cf
movq 0x38(%rsp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
jne 0x202dc
movl $0x3, 0x44(%rsp)
jmp 0x20550
cmpl $0x0, 0x12e09(%rip) # 0x330ec
je 0x2040b
leaq 0x12b10(%rip), %rax # 0x32e00
movq (%rax), %rdi
movq 0x38(%rsp), %rdx
leaq 0xb3d9(%rip), %rsi # 0x2b6d8
movb $0x0, %al
callq 0x289b0
movsd 0x30(%rsp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x2032a
jp 0x2032a
movsd 0x28(%rsp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x2032a
jp 0x2032a
jmp 0x2038c
leaq 0x12acf(%rip), %rax # 0x32e00
movq (%rax), %rdi
movsd 0x30(%rsp), %xmm0
movsd 0x28(%rsp), %xmm1
leaq 0xb3a3(%rip), %rsi # 0x2b6ea
movb $0x2, %al
callq 0x289b0
cmpl $0x0, 0x24(%rsp)
jl 0x2038a
cmpl $0x7, 0x24(%rsp)
jg 0x2038a
leaq 0x12a9d(%rip), %rax # 0x32e00
movq (%rax), %rax
movq %rax, 0x18(%rsp)
movl 0x24(%rsp), %edi
callq 0xbe30
movq 0x18(%rsp), %rdi
movq %rax, %rdx
leaq 0xa0ec(%rip), %rsi # 0x2a46f
movb $0x0, %al
callq 0x289b0
jmp 0x203ee
cmpl $0x0, 0x24(%rsp)
jle 0x203ec
cmpl $0x7, 0x24(%rsp)
jg 0x203ec
leaq 0x12a5f(%rip), %rax # 0x32e00
movq (%rax), %rdi
movsd 0x30(%rsp), %xmm0
movsd 0x28(%rsp), %xmm1
leaq 0xb333(%rip), %rsi # 0x2b6ea
movb $0x2, %al
callq 0x289b0
leaq 0x12a3b(%rip), %rax # 0x32e00
movq (%rax), %rax
movq %rax, 0x10(%rsp)
movl 0x24(%rsp), %edi
callq 0xbe30
movq 0x10(%rsp), %rdi
movq %rax, %rdx
leaq 0xa08a(%rip), %rsi # 0x2a46f
movb $0x0, %al
callq 0x289b0
jmp 0x203ee
leaq 0x12a0b(%rip), %rax # 0x32e00
movq (%rax), %rdi
leaq 0x9b55(%rip), %rsi # 0x29f54
movb $0x0, %al
callq 0x289b0
jmp 0x20526
leaq 0x129ee(%rip), %rax # 0x32e00
movq (%rax), %rdi
movq 0x38(%rsp), %rdx
leaq 0xb2b7(%rip), %rsi # 0x2b6d8
movb $0x0, %al
callq 0x1100
movsd 0x30(%rsp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x2044c
jp 0x2044c
movsd 0x28(%rsp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x2044c
jp 0x2044c
jmp 0x204ae
leaq 0x129ad(%rip), %rax # 0x32e00
movq (%rax), %rdi
movsd 0x30(%rsp), %xmm0
movsd 0x28(%rsp), %xmm1
leaq 0xb281(%rip), %rsi # 0x2b6ea
movb $0x2, %al
callq 0x1100
cmpl $0x0, 0x24(%rsp)
jl 0x204ac
cmpl $0x7, 0x24(%rsp)
jg 0x204ac
leaq 0x1297b(%rip), %rax # 0x32e00
movq (%rax), %rax
movq %rax, 0x8(%rsp)
movl 0x24(%rsp), %edi
callq 0xbe30
movq 0x8(%rsp), %rdi
movq %rax, %rdx
leaq 0x9fca(%rip), %rsi # 0x2a46f
movb $0x0, %al
callq 0x1100
jmp 0x2050e
cmpl $0x0, 0x24(%rsp)
jle 0x2050c
cmpl $0x7, 0x24(%rsp)
jg 0x2050c
leaq 0x1293d(%rip), %rax # 0x32e00
movq (%rax), %rdi
movsd 0x30(%rsp), %xmm0
movsd 0x28(%rsp), %xmm1
leaq 0xb211(%rip), %rsi # 0x2b6ea
movb $0x2, %al
callq 0x1100
leaq 0x12919(%rip), %rax # 0x32e00
movq (%rax), %rax
movq %rax, (%rsp)
movl 0x24(%rsp), %edi
callq 0xbe30
movq (%rsp), %rdi
movq %rax, %rdx
leaq 0x9f6a(%rip), %rsi # 0x2a46f
movb $0x0, %al
callq 0x1100
jmp 0x2050e
leaq 0x128eb(%rip), %rax # 0x32e00
movq (%rax), %rdi
leaq 0x9a35(%rip), %rsi # 0x29f54
movb $0x0, %al
callq 0x1100
leaq 0x12b1f(%rip), %rax # 0x3304c
movl (%rax), %ecx
addl $0x1, %ecx
leaq 0x12b13(%rip), %rax # 0x3304c
movl %ecx, (%rax)
leaq 0x12b0e(%rip), %rax # 0x33050
movl $0x21, (%rax)
movl $0x0, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopl (%rax)
| _ZN12LefDefParser19lefwMacroPinForeignEPKcddi:
sub rsp, 48h
mov [rsp+48h+var_10], rdi
movsd [rsp+48h+var_18], xmm0
movsd [rsp+48h+var_24+4], xmm1
mov dword ptr [rsp+48h+var_24], esi
mov cs:_ZN12LefDefParserL15lefwObsoleteNumE, 2Dh ; '-'; LefDefParser::lefwObsoleteNum
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
cmp qword ptr [rax], 0
jnz short loc_2025D
mov [rsp+48h+var_4], 1
jmp loc_20550
loc_2025D:
lea rax, _ZN12LefDefParser11lefwDidInitE; LefDefParser::lefwDidInit
cmp dword ptr [rax], 0
jnz short loc_20276
mov [rsp+48h+var_4], 2
jmp loc_20550
loc_20276:
lea rax, _ZN12LefDefParser14lefwIsMacroPinE; LefDefParser::lefwIsMacroPin
cmp dword ptr [rax], 0
jnz short loc_2028F
mov [rsp+48h+var_4], 2
jmp loc_20550
loc_2028F:
movsd xmm0, cs:_ZN12LefDefParserL10versionNumE; LefDefParser::versionNum
movsd xmm1, cs:dbl_291F0
ucomisd xmm0, xmm1
jb short loc_202B2
mov [rsp+48h+var_4], 7
jmp loc_20550
loc_202B2:
cmp [rsp+48h+var_10], 0
jz short loc_202CF
cmp [rsp+48h+var_10], 0
jz short loc_202CF
mov rax, [rsp+48h+var_10]
movsx eax, byte ptr [rax]
cmp eax, 0
jnz short loc_202DC
loc_202CF:
mov [rsp+48h+var_4], 3
jmp loc_20550
loc_202DC:
cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 0; LefDefParser::lefwWriteEncrypt
jz loc_2040B
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
mov rdx, [rsp+48h+var_10]
lea rsi, aForeignS; " FOREIGN %s "
mov al, 0
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
movsd xmm0, [rsp+48h+var_18]
xorps xmm1, xmm1
ucomisd xmm0, xmm1
jnz short loc_2032A
jp short loc_2032A
movsd xmm0, [rsp+48h+var_24+4]
xorps xmm1, xmm1
ucomisd xmm0, xmm1
jnz short loc_2032A
jp short loc_2032A
jmp short loc_2038C
loc_2032A:
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
movsd xmm0, [rsp+48h+var_18]
movsd xmm1, [rsp+48h+var_24+4]
lea rsi, aStructure11g11; "STRUCTURE %.11g %.11g "
mov al, 2
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
cmp dword ptr [rsp+48h+var_24], 0
jl short loc_2038A
cmp dword ptr [rsp+48h+var_24], 7
jg short loc_2038A
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rax, [rax]
mov [rsp+48h+var_30], rax
mov edi, dword ptr [rsp+48h+var_24]; this
call _ZN12LefDefParser10lefwOrientEi; LefDefParser::lefwOrient(int)
mov rdi, [rsp+48h+var_30]
mov rdx, rax
lea rsi, aS+6; "%s "
mov al, 0
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
loc_2038A:
jmp short loc_203EE
loc_2038C:
cmp dword ptr [rsp+48h+var_24], 0
jle short loc_203EC
cmp dword ptr [rsp+48h+var_24], 7
jg short loc_203EC
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
movsd xmm0, [rsp+48h+var_18]
movsd xmm1, [rsp+48h+var_24+4]
lea rsi, aStructure11g11; "STRUCTURE %.11g %.11g "
mov al, 2
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rax, [rax]
mov [rsp+48h+var_38], rax
mov edi, dword ptr [rsp+48h+var_24]; this
call _ZN12LefDefParser10lefwOrientEi; LefDefParser::lefwOrient(int)
mov rdi, [rsp+48h+var_38]
mov rdx, rax
lea rsi, aS+6; "%s "
mov al, 0
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
loc_203EC:
jmp short $+2
loc_203EE:
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
lea rsi, aDividercharS+11h; ";\n"
mov al, 0
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
jmp loc_20526
loc_2040B:
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
mov rdx, [rsp+48h+var_10]
lea rsi, aForeignS; " FOREIGN %s "
mov al, 0
call _fprintf
movsd xmm0, [rsp+48h+var_18]
xorps xmm1, xmm1
ucomisd xmm0, xmm1
jnz short loc_2044C
jp short loc_2044C
movsd xmm0, [rsp+48h+var_24+4]
xorps xmm1, xmm1
ucomisd xmm0, xmm1
jnz short loc_2044C
jp short loc_2044C
jmp short loc_204AE
loc_2044C:
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
movsd xmm0, [rsp+48h+var_18]
movsd xmm1, [rsp+48h+var_24+4]
lea rsi, aStructure11g11; "STRUCTURE %.11g %.11g "
mov al, 2
call _fprintf
cmp dword ptr [rsp+48h+var_24], 0
jl short loc_204AC
cmp dword ptr [rsp+48h+var_24], 7
jg short loc_204AC
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rax, [rax]
mov [rsp+48h+var_40], rax
mov edi, dword ptr [rsp+48h+var_24]; this
call _ZN12LefDefParser10lefwOrientEi; LefDefParser::lefwOrient(int)
mov rdi, [rsp+48h+var_40]
mov rdx, rax
lea rsi, aS+6; "%s "
mov al, 0
call _fprintf
loc_204AC:
jmp short loc_2050E
loc_204AE:
cmp dword ptr [rsp+48h+var_24], 0
jle short loc_2050C
cmp dword ptr [rsp+48h+var_24], 7
jg short loc_2050C
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
movsd xmm0, [rsp+48h+var_18]
movsd xmm1, [rsp+48h+var_24+4]
lea rsi, aStructure11g11; "STRUCTURE %.11g %.11g "
mov al, 2
call _fprintf
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rax, [rax]
mov [rsp+48h+var_48], rax
mov edi, dword ptr [rsp+48h+var_24]; this
call _ZN12LefDefParser10lefwOrientEi; LefDefParser::lefwOrient(int)
mov rdi, [rsp+48h+var_48]
mov rdx, rax
lea rsi, aS+6; "%s "
mov al, 0
call _fprintf
loc_2050C:
jmp short $+2
loc_2050E:
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
lea rsi, aDividercharS+11h; ";\n"
mov al, 0
call _fprintf
loc_20526:
lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines
mov ecx, [rax]
add ecx, 1
lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines
mov [rax], ecx
lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState
mov dword ptr [rax], 21h ; '!'
mov [rsp+48h+var_4], 0
loc_20550:
mov eax, [rsp+48h+var_4]
add rsp, 48h
retn
| long long LefDefParser::lefwMacroPinForeign(
LefDefParser *this,
const char *a2,
double a3,
double a4,
int a5,
int a6,
int a7,
int a8)
{
int v8; // edx
int v9; // ecx
int v10; // r8d
int v11; // r9d
unsigned int v12; // eax
int v13; // ecx
int v14; // r8d
int v15; // r9d
unsigned int v16; // eax
int v17; // ecx
int v18; // r8d
int v19; // r9d
LefDefParser *v20; // rax
LefDefParser *v21; // rax
long long v23; // [rsp+0h] [rbp-48h]
long long v24; // [rsp+8h] [rbp-40h]
int v25; // [rsp+10h] [rbp-38h]
int v26; // [rsp+18h] [rbp-30h]
LefDefParser::lefwObsoleteNum = 45;
if ( *(_QWORD *)&LefDefParser::lefwFile )
{
if ( LefDefParser::lefwDidInit )
{
if ( LefDefParser::lefwIsMacroPin )
{
if ( *(double *)&LefDefParser::versionNum < 5.6 )
{
if ( this && *(_BYTE *)this )
{
if ( LefDefParser::lefwWriteEncrypt )
{
LefDefParser::encPrint(
LefDefParser::lefwFile,
(unsigned int)" FOREIGN %s ",
(_DWORD)this,
a6,
a7,
a8);
if ( a3 == 0.0 && a4 == 0.0 )
{
if ( (int)a2 > 0 && (int)a2 <= 7 )
{
LefDefParser::encPrint(
LefDefParser::lefwFile,
(unsigned int)"STRUCTURE %.11g %.11g ",
v8,
v9,
v10,
v11);
v25 = LefDefParser::lefwFile;
v16 = (unsigned int)LefDefParser::lefwOrient(
(LefDefParser *)(unsigned int)a2,
"STRUCTURE %.11g %.11g ");
LefDefParser::encPrint(v25, (unsigned int)"%s ", v16, v17, v18, v19);
}
}
else
{
LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)"STRUCTURE %.11g %.11g ", v8, v9, v10, v11);
if ( (unsigned int)a2 < 8 )
{
v26 = LefDefParser::lefwFile;
v12 = (unsigned int)LefDefParser::lefwOrient(
(LefDefParser *)(unsigned int)a2,
"STRUCTURE %.11g %.11g ");
LefDefParser::encPrint(v26, (unsigned int)"%s ", v12, v13, v14, v15);
}
}
LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)";\n", v8, v9, v10, v11);
}
else
{
fprintf(*(_QWORD *)&LefDefParser::lefwFile, " FOREIGN %s ", (const char *)this);
if ( a3 == 0.0 && a4 == 0.0 )
{
if ( (int)a2 > 0 && (int)a2 <= 7 )
{
fprintf(*(_QWORD *)&LefDefParser::lefwFile, "STRUCTURE %.11g %.11g ", a3, a4);
v23 = *(_QWORD *)&LefDefParser::lefwFile;
v21 = LefDefParser::lefwOrient((LefDefParser *)(unsigned int)a2, "STRUCTURE %.11g %.11g ");
fprintf(v23, "%s ", (const char *)v21);
}
}
else
{
fprintf(*(_QWORD *)&LefDefParser::lefwFile, "STRUCTURE %.11g %.11g ", a3, a4);
if ( (unsigned int)a2 < 8 )
{
v24 = *(_QWORD *)&LefDefParser::lefwFile;
v20 = LefDefParser::lefwOrient((LefDefParser *)(unsigned int)a2, "STRUCTURE %.11g %.11g ");
fprintf(v24, "%s ", (const char *)v20);
}
}
fprintf(*(_QWORD *)&LefDefParser::lefwFile, ";\n");
}
++LefDefParser::lefwLines;
LefDefParser::lefwState = 33;
return 0;
}
else
{
return 3;
}
}
else
{
return 7;
}
}
else
{
return 2;
}
}
else
{
return 2;
}
}
else
{
return 1;
}
}
| lefwMacroPinForeign:
SUB RSP,0x48
MOV qword ptr [RSP + 0x38],RDI
MOVSD qword ptr [RSP + 0x30],XMM0
MOVSD qword ptr [RSP + 0x28],XMM1
MOV dword ptr [RSP + 0x24],ESI
MOV dword ptr [0x00132d48],0x2d
LEA RAX,[0x132e00]
CMP qword ptr [RAX],0x0
JNZ 0x0012025d
MOV dword ptr [RSP + 0x44],0x1
JMP 0x00120550
LAB_0012025d:
LEA RAX,[0x133054]
CMP dword ptr [RAX],0x0
JNZ 0x00120276
MOV dword ptr [RSP + 0x44],0x2
JMP 0x00120550
LAB_00120276:
LEA RAX,[0x1330a0]
CMP dword ptr [RAX],0x0
JNZ 0x0012028f
MOV dword ptr [RSP + 0x44],0x2
JMP 0x00120550
LAB_0012028f:
MOVSD XMM0,qword ptr [0x00132d40]
MOVSD XMM1,qword ptr [0x001291f0]
UCOMISD XMM0,XMM1
JC 0x001202b2
MOV dword ptr [RSP + 0x44],0x7
JMP 0x00120550
LAB_001202b2:
CMP qword ptr [RSP + 0x38],0x0
JZ 0x001202cf
CMP qword ptr [RSP + 0x38],0x0
JZ 0x001202cf
MOV RAX,qword ptr [RSP + 0x38]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x0
JNZ 0x001202dc
LAB_001202cf:
MOV dword ptr [RSP + 0x44],0x3
JMP 0x00120550
LAB_001202dc:
CMP dword ptr [0x001330ec],0x0
JZ 0x0012040b
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
MOV RDX,qword ptr [RSP + 0x38]
LEA RSI,[0x12b6d8]
MOV AL,0x0
CALL 0x001289b0
MOVSD XMM0,qword ptr [RSP + 0x30]
XORPS XMM1,XMM1
UCOMISD XMM0,XMM1
JNZ 0x0012032a
JP 0x0012032a
MOVSD XMM0,qword ptr [RSP + 0x28]
XORPS XMM1,XMM1
UCOMISD XMM0,XMM1
JNZ 0x0012032a
JP 0x0012032a
JMP 0x0012038c
LAB_0012032a:
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
MOVSD XMM0,qword ptr [RSP + 0x30]
MOVSD XMM1,qword ptr [RSP + 0x28]
LEA RSI,[0x12b6ea]
MOV AL,0x2
CALL 0x001289b0
CMP dword ptr [RSP + 0x24],0x0
JL 0x0012038a
CMP dword ptr [RSP + 0x24],0x7
JG 0x0012038a
LEA RAX,[0x132e00]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0x18],RAX
MOV EDI,dword ptr [RSP + 0x24]
CALL 0x0010be30
MOV RDI,qword ptr [RSP + 0x18]
MOV RDX,RAX
LEA RSI,[0x12a46f]
MOV AL,0x0
CALL 0x001289b0
LAB_0012038a:
JMP 0x001203ee
LAB_0012038c:
CMP dword ptr [RSP + 0x24],0x0
JLE 0x001203ec
CMP dword ptr [RSP + 0x24],0x7
JG 0x001203ec
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
MOVSD XMM0,qword ptr [RSP + 0x30]
MOVSD XMM1,qword ptr [RSP + 0x28]
LEA RSI,[0x12b6ea]
MOV AL,0x2
CALL 0x001289b0
LEA RAX,[0x132e00]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0x10],RAX
MOV EDI,dword ptr [RSP + 0x24]
CALL 0x0010be30
MOV RDI,qword ptr [RSP + 0x10]
MOV RDX,RAX
LEA RSI,[0x12a46f]
MOV AL,0x0
CALL 0x001289b0
LAB_001203ec:
JMP 0x001203ee
LAB_001203ee:
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
LEA RSI,[0x129f54]
MOV AL,0x0
CALL 0x001289b0
JMP 0x00120526
LAB_0012040b:
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
MOV RDX,qword ptr [RSP + 0x38]
LEA RSI,[0x12b6d8]
MOV AL,0x0
CALL 0x00101100
MOVSD XMM0,qword ptr [RSP + 0x30]
XORPS XMM1,XMM1
UCOMISD XMM0,XMM1
JNZ 0x0012044c
JP 0x0012044c
MOVSD XMM0,qword ptr [RSP + 0x28]
XORPS XMM1,XMM1
UCOMISD XMM0,XMM1
JNZ 0x0012044c
JP 0x0012044c
JMP 0x001204ae
LAB_0012044c:
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
MOVSD XMM0,qword ptr [RSP + 0x30]
MOVSD XMM1,qword ptr [RSP + 0x28]
LEA RSI,[0x12b6ea]
MOV AL,0x2
CALL 0x00101100
CMP dword ptr [RSP + 0x24],0x0
JL 0x001204ac
CMP dword ptr [RSP + 0x24],0x7
JG 0x001204ac
LEA RAX,[0x132e00]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0x8],RAX
MOV EDI,dword ptr [RSP + 0x24]
CALL 0x0010be30
MOV RDI,qword ptr [RSP + 0x8]
MOV RDX,RAX
LEA RSI,[0x12a46f]
MOV AL,0x0
CALL 0x00101100
LAB_001204ac:
JMP 0x0012050e
LAB_001204ae:
CMP dword ptr [RSP + 0x24],0x0
JLE 0x0012050c
CMP dword ptr [RSP + 0x24],0x7
JG 0x0012050c
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
MOVSD XMM0,qword ptr [RSP + 0x30]
MOVSD XMM1,qword ptr [RSP + 0x28]
LEA RSI,[0x12b6ea]
MOV AL,0x2
CALL 0x00101100
LEA RAX,[0x132e00]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP],RAX
MOV EDI,dword ptr [RSP + 0x24]
CALL 0x0010be30
MOV RDI,qword ptr [RSP]
MOV RDX,RAX
LEA RSI,[0x12a46f]
MOV AL,0x0
CALL 0x00101100
LAB_0012050c:
JMP 0x0012050e
LAB_0012050e:
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
LEA RSI,[0x129f54]
MOV AL,0x0
CALL 0x00101100
LAB_00120526:
LEA RAX,[0x13304c]
MOV ECX,dword ptr [RAX]
ADD ECX,0x1
LEA RAX,[0x13304c]
MOV dword ptr [RAX],ECX
LEA RAX,[0x133050]
MOV dword ptr [RAX],0x21
MOV dword ptr [RSP + 0x44],0x0
LAB_00120550:
MOV EAX,dword ptr [RSP + 0x44]
ADD RSP,0x48
RET
|
/* LefDefParser::lefwMacroPinForeign(char const*, double, double, int) */
int4
LefDefParser::lefwMacroPinForeign(char *param_1,double param_2,double param_3,int param_4)
{
_IO_FILE *p_Var1;
FILE *pFVar2;
int8 uVar3;
int4 local_4;
lefwObsoleteNum = 0x2d;
if (lefwFile == (_IO_FILE *)0x0) {
local_4 = 1;
}
else if (lefwDidInit == 0) {
local_4 = 2;
}
else if (lefwIsMacroPin == 0) {
local_4 = 2;
}
else if (DAT_001291f0 <= versionNum) {
local_4 = 7;
}
else if (((param_1 == (char *)0x0) || (param_1 == (char *)0x0)) || (*param_1 == '\0')) {
local_4 = 3;
}
else {
if (lefwWriteEncrypt == 0) {
fprintf(lefwFile," FOREIGN %s ",param_1);
if (((param_2 != 0.0) || (NAN(param_2))) || ((param_3 != 0.0 || (NAN(param_3))))) {
fprintf(lefwFile,"STRUCTURE %.11g %.11g ",param_2,param_3);
pFVar2 = lefwFile;
if ((-1 < param_4) && (param_4 < 8)) {
uVar3 = lefwOrient(param_4);
fprintf(pFVar2,"%s ",uVar3);
}
}
else if ((0 < param_4) && (param_4 < 8)) {
fprintf(lefwFile,"STRUCTURE %.11g %.11g ",param_2,param_3);
pFVar2 = lefwFile;
uVar3 = lefwOrient(param_4);
fprintf(pFVar2,"%s ",uVar3);
}
fprintf(lefwFile,";\n");
}
else {
encPrint(lefwFile," FOREIGN %s ",param_1);
if ((((param_2 != 0.0) || (NAN(param_2))) || (param_3 != 0.0)) || (NAN(param_3))) {
encPrint(lefwFile,"STRUCTURE %.11g %.11g ",param_2,param_3);
p_Var1 = lefwFile;
if ((-1 < param_4) && (param_4 < 8)) {
uVar3 = lefwOrient(param_4);
encPrint(p_Var1,"%s ",uVar3);
}
}
else if ((0 < param_4) && (param_4 < 8)) {
encPrint(lefwFile,"STRUCTURE %.11g %.11g ",param_2,param_3);
p_Var1 = lefwFile;
uVar3 = lefwOrient(param_4);
encPrint(p_Var1,"%s ",uVar3);
}
encPrint(lefwFile,";\n");
}
lefwLines = lefwLines + 1;
lefwState = 0x21;
local_4 = 0;
}
return local_4;
}
| |
23,358 | action_a_add | navaro[P]qoraal-tictactoe/build_O3/_deps/qoraal_engine-src/src/parts/engine.c | int32_t
action_a_add (PENGINE_T instance, uint32_t parm, uint32_t flags)
{
int32_t value ;
if (flags & (PART_ACTION_FLAG_VALIDATE)) {
return parts_valadate_int (instance, parm, flags, INT_MIN, INT_MAX) ;
}
value = parts_get_int (instance, parm, flags, INT_MIN, INT_MAX) ;
int32_t acc = 0 ;
engine_get_variable (instance, ENGINE_VARIABLE_ACCUMULATOR, &acc) ;
acc += value ;
engine_set_variable (instance, ENGINE_VARIABLE_ACCUMULATOR, acc) ;
return acc ;
} | O3 | c | action_a_add:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
testb $0x1, %dl
jne 0x6d61
movq %rbx, %rdi
movl $0x80000000, %ecx # imm = 0x80000000
movl $0x7fffffff, %r8d # imm = 0x7FFFFFFF
callq 0x82dd
movl %eax, %r14d
leaq -0x1c(%rbp), %r15
movl $0x0, (%r15)
movq %rbx, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0xe6b1
addl (%r15), %r14d
movl %r14d, (%r15)
movq %rbx, %rdi
xorl %esi, %esi
movl %r14d, %edx
callq 0xe75e
movl (%r15), %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rbx, %rdi
movl $0x80000000, %ecx # imm = 0x80000000
movl $0x7fffffff, %r8d # imm = 0x7FFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x8254
| action_a_add:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov rbx, rdi
test dl, 1
jnz short loc_6D61
mov rdi, rbx
mov ecx, 80000000h
mov r8d, 7FFFFFFFh
call parts_get_int
mov r14d, eax
lea r15, [rbp+var_1C]
mov dword ptr [r15], 0
mov rdi, rbx
xor esi, esi
mov rdx, r15
call engine_get_variable
add r14d, [r15]
mov [r15], r14d
mov rdi, rbx
xor esi, esi
mov edx, r14d
call engine_set_variable
mov eax, [r15]
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
loc_6D61:
mov rdi, rbx
mov ecx, 80000000h
mov r8d, 7FFFFFFFh
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
jmp parts_valadate_int
| long long action_a_add(long long a1, long long a2, long long a3)
{
long long v3; // rax
int v4; // r14d
_DWORD v6[7]; // [rsp+0h] [rbp-1Ch] BYREF
v6[0] = HIDWORD(v3);
if ( (a3 & 1) != 0 )
return parts_valadate_int(a1, a2, a3, 0x80000000LL, 0x7FFFFFFFLL);
v4 = parts_get_int(a1, a2, a3, 0x80000000LL, 0x7FFFFFFFLL);
v6[0] = 0;
engine_get_variable(a1, 0LL, v6);
v6[0] += v4;
engine_set_variable(a1, 0LL, v6[0]);
return v6[0];
}
| action_a_add:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
TEST DL,0x1
JNZ 0x00106d61
MOV RDI,RBX
MOV ECX,0x80000000
MOV R8D,0x7fffffff
CALL 0x001082dd
MOV R14D,EAX
LEA R15,[RBP + -0x1c]
MOV dword ptr [R15],0x0
MOV RDI,RBX
XOR ESI,ESI
MOV RDX,R15
CALL 0x0010e6b1
ADD R14D,dword ptr [R15]
MOV dword ptr [R15],R14D
MOV RDI,RBX
XOR ESI,ESI
MOV EDX,R14D
CALL 0x0010e75e
MOV EAX,dword ptr [R15]
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_00106d61:
MOV RDI,RBX
MOV ECX,0x80000000
MOV R8D,0x7fffffff
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
JMP 0x00108254
|
ulong action_a_add(int8 param_1,int8 param_2,ulong param_3)
{
uint in_EAX;
int iVar1;
ulong uVar2;
uint uVar3;
int8 uStack_28;
if ((param_3 & 1) == 0) {
uStack_28._0_4_ = in_EAX;
iVar1 = parts_get_int(param_1,param_2,param_3,0x80000000,0x7fffffff);
uStack_28 = (ulong)(uint)uStack_28;
engine_get_variable(param_1,0,(long)&uStack_28 + 4);
uVar3 = iVar1 + uStack_28._4_4_;
uStack_28._4_4_ = uVar3;
engine_set_variable(param_1,0,uVar3);
return (ulong)uStack_28._4_4_;
}
uVar2 = parts_valadate_int(param_1,param_2,param_3,0x80000000,0x7fffffff);
return uVar2;
}
| |
23,359 | ImPlot::ShowSubplotsContextMenu(ImPlotSubplot&) | zkingston[P]unknot/build_O1/_deps/implot-src/implot.cpp | void ShowSubplotsContextMenu(ImPlotSubplot& subplot) {
if ((ImGui::BeginMenu("Linking"))) {
if (ImGui::MenuItem("Link Rows",nullptr,ImHasFlag(subplot.Flags, ImPlotSubplotFlags_LinkRows)))
ImFlipFlag(subplot.Flags, ImPlotSubplotFlags_LinkRows);
if (ImGui::MenuItem("Link Cols",nullptr,ImHasFlag(subplot.Flags, ImPlotSubplotFlags_LinkCols)))
ImFlipFlag(subplot.Flags, ImPlotSubplotFlags_LinkCols);
if (ImGui::MenuItem("Link All X",nullptr,ImHasFlag(subplot.Flags, ImPlotSubplotFlags_LinkAllX)))
ImFlipFlag(subplot.Flags, ImPlotSubplotFlags_LinkAllX);
if (ImGui::MenuItem("Link All Y",nullptr,ImHasFlag(subplot.Flags, ImPlotSubplotFlags_LinkAllY)))
ImFlipFlag(subplot.Flags, ImPlotSubplotFlags_LinkAllY);
ImGui::EndMenu();
}
if ((ImGui::BeginMenu("Settings"))) {
BeginDisabledControls(!subplot.HasTitle);
if (ImGui::MenuItem("Title",nullptr,subplot.HasTitle && !ImHasFlag(subplot.Flags, ImPlotSubplotFlags_NoTitle)))
ImFlipFlag(subplot.Flags, ImPlotSubplotFlags_NoTitle);
EndDisabledControls(!subplot.HasTitle);
if (ImGui::MenuItem("Resizable",nullptr,!ImHasFlag(subplot.Flags, ImPlotSubplotFlags_NoResize)))
ImFlipFlag(subplot.Flags, ImPlotSubplotFlags_NoResize);
if (ImGui::MenuItem("Align",nullptr,!ImHasFlag(subplot.Flags, ImPlotSubplotFlags_NoAlign)))
ImFlipFlag(subplot.Flags, ImPlotSubplotFlags_NoAlign);
if (ImGui::MenuItem("Share Items",nullptr,ImHasFlag(subplot.Flags, ImPlotSubplotFlags_ShareItems)))
ImFlipFlag(subplot.Flags, ImPlotSubplotFlags_ShareItems);
ImGui::EndMenu();
}
} | O1 | cpp | ImPlot::ShowSubplotsContextMenu(ImPlotSubplot&):
pushq %rbx
movq %rdi, %rbx
leaq 0x1e600e(%rip), %rdi # 0x29a587
movl $0x1, %esi
callq 0x26cb24
testb %al, %al
je 0xb4620
movl 0x4(%rbx), %edx
andl $0x40, %edx
shrl $0x6, %edx
leaq 0x1e5ff4(%rip), %rdi # 0x29a58f
xorl %esi, %esi
movl $0x1, %ecx
callq 0x25a265
testb %al, %al
je 0xb45af
xorb $0x40, 0x4(%rbx)
movb 0x4(%rbx), %al
shrb $0x7, %al
movzbl %al, %edx
leaq 0x1e5fda(%rip), %rdi # 0x29a599
xorl %esi, %esi
movl $0x1, %ecx
callq 0x25a265
testb %al, %al
je 0xb45d3
xorb $-0x80, 0x4(%rbx)
movl 0x4(%rbx), %edx
shrl $0x8, %edx
andl $0x1, %edx
leaq 0x1e5fc0(%rip), %rdi # 0x29a5a3
xorl %esi, %esi
movl $0x1, %ecx
callq 0x25a265
testb %al, %al
je 0xb45f7
xorb $0x1, 0x5(%rbx)
movl 0x4(%rbx), %edx
shrl $0x9, %edx
andl $0x1, %edx
leaq 0x1e5fa7(%rip), %rdi # 0x29a5ae
xorl %esi, %esi
movl $0x1, %ecx
callq 0x25a265
testb %al, %al
je 0xb461b
xorb $0x2, 0x5(%rbx)
callq 0x26cb2d
leaq 0x1f173a(%rip), %rdi # 0x2a5d61
movl $0x1, %esi
callq 0x26cb24
testb %al, %al
je 0xb471f
cmpb $0x0, 0x131(%rbx)
jne 0xb4669
movl $0x400, %edi # imm = 0x400
movl $0x1, %esi
callq 0x228f23
callq 0x215e75
movss (%rax), %xmm0
mulss 0x1dfd16(%rip), %xmm0 # 0x294378
xorl %edi, %edi
callq 0x2163bf
movl 0x4(%rbx), %eax
testb $0x1, %al
sete %al
andb 0x131(%rbx), %al
movzbl %al, %edx
leaq 0x1e0734(%rip), %rdi # 0x294db5
xorl %esi, %esi
movl $0x1, %ecx
callq 0x25a265
testb %al, %al
je 0xb4695
xorb $0x1, 0x4(%rbx)
cmpb $0x0, 0x131(%rbx)
jne 0xb46ad
callq 0x228fef
movl $0x1, %edi
callq 0x216849
xorl %edx, %edx
testb $0x8, 0x4(%rbx)
sete %dl
leaq 0x1e5efc(%rip), %rdi # 0x29a5b9
xorl %esi, %esi
movl $0x1, %ecx
callq 0x25a265
testb %al, %al
je 0xb46d1
xorb $0x8, 0x4(%rbx)
xorl %edx, %edx
testb $0x10, 0x4(%rbx)
sete %dl
leaq 0x1e5ee2(%rip), %rdi # 0x29a5c3
xorl %esi, %esi
movl $0x1, %ecx
callq 0x25a265
testb %al, %al
je 0xb46f5
xorb $0x10, 0x4(%rbx)
movl 0x4(%rbx), %edx
andl $0x20, %edx
shrl $0x5, %edx
leaq 0x1e5ec4(%rip), %rdi # 0x29a5c9
xorl %esi, %esi
movl $0x1, %ecx
callq 0x25a265
testb %al, %al
je 0xb4719
xorb $0x20, 0x4(%rbx)
popq %rbx
jmp 0x26cb2d
popq %rbx
retq
| _ZN6ImPlot23ShowSubplotsContextMenuER13ImPlotSubplot:
push rbx
mov rbx, rdi
lea rdi, aLinking; "Linking"
mov esi, (offset dword_0+1); char *
call _ZN5ImGui9BeginMenuEPKcb; ImGui::BeginMenu(char const*,bool)
test al, al
jz loc_B4620
mov edx, [rbx+4]
and edx, 40h
shr edx, 6; char *
lea rdi, aLinkRows; "Link Rows"
xor esi, esi; char *
mov ecx, 1; bool
call _ZN5ImGui8MenuItemEPKcS1_bb; ImGui::MenuItem(char const*,char const*,bool,bool)
test al, al
jz short loc_B45AF
xor byte ptr [rbx+4], 40h
loc_B45AF:
mov al, [rbx+4]
shr al, 7
movzx edx, al; char *
lea rdi, aLinkCols; "Link Cols"
xor esi, esi; char *
mov ecx, 1; bool
call _ZN5ImGui8MenuItemEPKcS1_bb; ImGui::MenuItem(char const*,char const*,bool,bool)
test al, al
jz short loc_B45D3
xor byte ptr [rbx+4], 80h
loc_B45D3:
mov edx, [rbx+4]
shr edx, 8
and edx, 1; char *
lea rdi, aLinkAllX; "Link All X"
xor esi, esi; char *
mov ecx, 1; bool
call _ZN5ImGui8MenuItemEPKcS1_bb; ImGui::MenuItem(char const*,char const*,bool,bool)
test al, al
jz short loc_B45F7
xor byte ptr [rbx+5], 1
loc_B45F7:
mov edx, [rbx+4]
shr edx, 9
and edx, 1; char *
lea rdi, aLinkAllY; "Link All Y"
xor esi, esi; char *
mov ecx, 1; bool
call _ZN5ImGui8MenuItemEPKcS1_bb; ImGui::MenuItem(char const*,char const*,bool,bool)
test al, al
jz short loc_B461B
xor byte ptr [rbx+5], 2
loc_B461B:
call _ZN5ImGui7EndMenuEv; ImGui::EndMenu(void)
loc_B4620:
lea rdi, aIoConfigdebugi+11h; this
mov esi, (offset dword_0+1); char *
call _ZN5ImGui9BeginMenuEPKcb; ImGui::BeginMenu(char const*,bool)
test al, al
jz loc_B471F
cmp byte ptr [rbx+131h], 0
jnz short loc_B4669
mov edi, offset stru_400; this
mov esi, 1; int
call _ZN5ImGui12PushItemFlagEib; ImGui::PushItemFlag(int,bool)
call _ZN5ImGui8GetStyleEv; ImGui::GetStyle(void)
movss xmm0, dword ptr [rax]
mulss xmm0, cs:flt_294378; float
xor edi, edi; this
call _ZN5ImGui12PushStyleVarEif; ImGui::PushStyleVar(int,float)
loc_B4669:
mov eax, [rbx+4]
test al, 1
setz al
and al, [rbx+131h]
movzx edx, al; char *
lea rdi, aTitle; "Title"
xor esi, esi; int
mov ecx, 1; bool
call _ZN5ImGui8MenuItemEPKcS1_bb; ImGui::MenuItem(char const*,char const*,bool,bool)
test al, al
jz short loc_B4695
xor byte ptr [rbx+4], 1
loc_B4695:
cmp byte ptr [rbx+131h], 0
jnz short loc_B46AD
call _ZN5ImGui11PopItemFlagEv; ImGui::PopItemFlag(void)
mov edi, (offset dword_0+1); this
call _ZN5ImGui11PopStyleVarEi; ImGui::PopStyleVar(int)
loc_B46AD:
xor edx, edx
test byte ptr [rbx+4], 8
setz dl; char *
lea rdi, aResizable; "Resizable"
xor esi, esi; char *
mov ecx, 1; bool
call _ZN5ImGui8MenuItemEPKcS1_bb; ImGui::MenuItem(char const*,char const*,bool,bool)
test al, al
jz short loc_B46D1
xor byte ptr [rbx+4], 8
loc_B46D1:
xor edx, edx
test byte ptr [rbx+4], 10h
setz dl; char *
lea rdi, aAlign; "Align"
xor esi, esi; char *
mov ecx, 1; bool
call _ZN5ImGui8MenuItemEPKcS1_bb; ImGui::MenuItem(char const*,char const*,bool,bool)
test al, al
jz short loc_B46F5
xor byte ptr [rbx+4], 10h
loc_B46F5:
mov edx, [rbx+4]
and edx, 20h
shr edx, 5; char *
lea rdi, aShareItems; "Share Items"
xor esi, esi; char *
mov ecx, 1; bool
call _ZN5ImGui8MenuItemEPKcS1_bb; ImGui::MenuItem(char const*,char const*,bool,bool)
test al, al
jz short loc_B4719
xor byte ptr [rbx+4], 20h
loc_B4719:
pop rbx
jmp _ZN5ImGui7EndMenuEv; ImGui::EndMenu(void)
loc_B471F:
pop rbx
retn
| long long ImPlot::ShowSubplotsContextMenu(ImPlot *this, ImPlotSubplot *a2, bool a3)
{
bool v3; // dl
bool v4; // r8
bool v5; // r8
bool v6; // r8
bool v7; // r8
long long result; // rax
bool v9; // dl
bool v10; // r8
float *Style; // rax
bool v12; // r8
bool v13; // r8
bool v14; // r8
if ( (unsigned __int8)ImGui::BeginMenu((ImGui *)"Linking", (const char *)&dword_0 + 1, a3) )
{
if ( (unsigned __int8)ImGui::MenuItem(
(ImGui *)"Link Rows",
0LL,
(const char *)((*((_DWORD *)this + 1) & 0x40u) >> 6),
1,
v4) )
*((_BYTE *)this + 4) ^= 0x40u;
if ( (unsigned __int8)ImGui::MenuItem((ImGui *)"Link Cols", 0LL, (const char *)(*((_BYTE *)this + 4) >> 7), 1, v5) )
*((_BYTE *)this + 4) ^= 0x80u;
if ( (unsigned __int8)ImGui::MenuItem(
(ImGui *)"Link All X",
0LL,
(const char *)((*((_DWORD *)this + 1) >> 8) & 1),
1,
v6) )
*((_BYTE *)this + 5) ^= 1u;
if ( (unsigned __int8)ImGui::MenuItem(
(ImGui *)"Link All Y",
0LL,
(const char *)((*((_DWORD *)this + 1) >> 9) & 1),
1,
v7) )
*((_BYTE *)this + 5) ^= 2u;
ImGui::EndMenu((ImGui *)"Link All Y");
}
result = ImGui::BeginMenu((ImGui *)"Settings", (const char *)&dword_0 + 1, v3);
if ( (_BYTE)result )
{
if ( !*((_BYTE *)this + 305) )
{
ImGui::PushItemFlag((ImGui *)&stru_400, 1, v9);
Style = (float *)ImGui::GetStyle((ImGui *)&stru_400);
ImGui::PushStyleVar(0LL, 1, *Style * 0.25);
}
if ( (unsigned __int8)ImGui::MenuItem(
(ImGui *)"Title",
0LL,
(const char *)(*((_BYTE *)this + 305) & ((*((_DWORD *)this + 1) & 1) == 0)),
1,
v10) )
*((_BYTE *)this + 4) ^= 1u;
if ( !*((_BYTE *)this + 305) )
{
ImGui::PopItemFlag((ImGui *)"Title");
ImGui::PopStyleVar((ImGui *)((char *)&dword_0 + 1), 0);
}
if ( (unsigned __int8)ImGui::MenuItem(
(ImGui *)"Resizable",
0LL,
(const char *)((*((_BYTE *)this + 4) & 8) == 0),
1,
v12) )
*((_BYTE *)this + 4) ^= 8u;
if ( (unsigned __int8)ImGui::MenuItem(
(ImGui *)"Align",
0LL,
(const char *)((*((_BYTE *)this + 4) & 0x10) == 0),
1,
v13) )
*((_BYTE *)this + 4) ^= 0x10u;
if ( (unsigned __int8)ImGui::MenuItem(
(ImGui *)"Share Items",
0LL,
(const char *)((*((_DWORD *)this + 1) & 0x20u) >> 5),
1,
v14) )
*((_BYTE *)this + 4) ^= 0x20u;
return ImGui::EndMenu((ImGui *)"Share Items");
}
return result;
}
| ShowSubplotsContextMenu:
PUSH RBX
MOV RBX,RDI
LEA RDI,[0x39a587]
MOV ESI,0x1
CALL 0x0036cb24
TEST AL,AL
JZ 0x001b4620
MOV EDX,dword ptr [RBX + 0x4]
AND EDX,0x40
SHR EDX,0x6
LEA RDI,[0x39a58f]
XOR ESI,ESI
MOV ECX,0x1
CALL 0x0035a265
TEST AL,AL
JZ 0x001b45af
XOR byte ptr [RBX + 0x4],0x40
LAB_001b45af:
MOV AL,byte ptr [RBX + 0x4]
SHR AL,0x7
MOVZX EDX,AL
LEA RDI,[0x39a599]
XOR ESI,ESI
MOV ECX,0x1
CALL 0x0035a265
TEST AL,AL
JZ 0x001b45d3
XOR byte ptr [RBX + 0x4],0x80
LAB_001b45d3:
MOV EDX,dword ptr [RBX + 0x4]
SHR EDX,0x8
AND EDX,0x1
LEA RDI,[0x39a5a3]
XOR ESI,ESI
MOV ECX,0x1
CALL 0x0035a265
TEST AL,AL
JZ 0x001b45f7
XOR byte ptr [RBX + 0x5],0x1
LAB_001b45f7:
MOV EDX,dword ptr [RBX + 0x4]
SHR EDX,0x9
AND EDX,0x1
LEA RDI,[0x39a5ae]
XOR ESI,ESI
MOV ECX,0x1
CALL 0x0035a265
TEST AL,AL
JZ 0x001b461b
XOR byte ptr [RBX + 0x5],0x2
LAB_001b461b:
CALL 0x0036cb2d
LAB_001b4620:
LEA RDI,[0x3a5d61]
MOV ESI,0x1
CALL 0x0036cb24
TEST AL,AL
JZ 0x001b471f
CMP byte ptr [RBX + 0x131],0x0
JNZ 0x001b4669
MOV EDI,0x400
MOV ESI,0x1
CALL 0x00328f23
CALL 0x00315e75
MOVSS XMM0,dword ptr [RAX]
MULSS XMM0,dword ptr [0x00394378]
XOR EDI,EDI
CALL 0x003163bf
LAB_001b4669:
MOV EAX,dword ptr [RBX + 0x4]
TEST AL,0x1
SETZ AL
AND AL,byte ptr [RBX + 0x131]
MOVZX EDX,AL
LEA RDI,[0x394db5]
XOR ESI,ESI
MOV ECX,0x1
CALL 0x0035a265
TEST AL,AL
JZ 0x001b4695
XOR byte ptr [RBX + 0x4],0x1
LAB_001b4695:
CMP byte ptr [RBX + 0x131],0x0
JNZ 0x001b46ad
CALL 0x00328fef
MOV EDI,0x1
CALL 0x00316849
LAB_001b46ad:
XOR EDX,EDX
TEST byte ptr [RBX + 0x4],0x8
SETZ DL
LEA RDI,[0x39a5b9]
XOR ESI,ESI
MOV ECX,0x1
CALL 0x0035a265
TEST AL,AL
JZ 0x001b46d1
XOR byte ptr [RBX + 0x4],0x8
LAB_001b46d1:
XOR EDX,EDX
TEST byte ptr [RBX + 0x4],0x10
SETZ DL
LEA RDI,[0x39a5c3]
XOR ESI,ESI
MOV ECX,0x1
CALL 0x0035a265
TEST AL,AL
JZ 0x001b46f5
XOR byte ptr [RBX + 0x4],0x10
LAB_001b46f5:
MOV EDX,dword ptr [RBX + 0x4]
AND EDX,0x20
SHR EDX,0x5
LEA RDI,[0x39a5c9]
XOR ESI,ESI
MOV ECX,0x1
CALL 0x0035a265
TEST AL,AL
JZ 0x001b4719
XOR byte ptr [RBX + 0x4],0x20
LAB_001b4719:
POP RBX
JMP 0x0036cb2d
LAB_001b471f:
POP RBX
RET
|
/* ImPlot::ShowSubplotsContextMenu(ImPlotSubplot&) */
void ImPlot::ShowSubplotsContextMenu(ImPlotSubplot *param_1)
{
char cVar1;
float *pfVar2;
cVar1 = ImGui::BeginMenu("Linking",true);
if (cVar1 != '\0') {
cVar1 = ImGui::MenuItem("Link Rows",(char *)0x0,SUB41((*(uint *)(param_1 + 4) & 0x40) >> 6,0),
true);
if (cVar1 != '\0') {
param_1[4] = (ImPlotSubplot)((byte)param_1[4] ^ 0x40);
}
cVar1 = ImGui::MenuItem("Link Cols",(char *)0x0,(bool)((byte)param_1[4] >> 7),true);
if (cVar1 != '\0') {
param_1[4] = (ImPlotSubplot)((byte)param_1[4] ^ 0x80);
}
cVar1 = ImGui::MenuItem("Link All X",(char *)0x0,
(bool)((byte)((uint)*(int4 *)(param_1 + 4) >> 8) & 1),true);
if (cVar1 != '\0') {
param_1[5] = (ImPlotSubplot)((byte)param_1[5] ^ 1);
}
cVar1 = ImGui::MenuItem("Link All Y",(char *)0x0,(bool)((byte)(*(uint *)(param_1 + 4) >> 9) & 1)
,true);
if (cVar1 != '\0') {
param_1[5] = (ImPlotSubplot)((byte)param_1[5] ^ 2);
}
ImGui::EndMenu();
}
cVar1 = ImGui::BeginMenu("Settings",true);
if (cVar1 != '\0') {
if (param_1[0x131] == (ImPlotSubplot)0x0) {
ImGui::PushItemFlag(0x400,true);
pfVar2 = (float *)ImGui::GetStyle();
ImGui::PushStyleVar(0,*pfVar2 * DAT_00394378);
}
cVar1 = ImGui::MenuItem("Title",(char *)0x0,
(bool)((*(uint *)(param_1 + 4) & 1) == 0 & (byte)param_1[0x131]),true);
if (cVar1 != '\0') {
param_1[4] = (ImPlotSubplot)((byte)param_1[4] ^ 1);
}
if (param_1[0x131] == (ImPlotSubplot)0x0) {
ImGui::PopItemFlag();
ImGui::PopStyleVar(1);
}
cVar1 = ImGui::MenuItem("Resizable",(char *)0x0,((byte)param_1[4] & 8) == 0,true);
if (cVar1 != '\0') {
param_1[4] = (ImPlotSubplot)((byte)param_1[4] ^ 8);
}
cVar1 = ImGui::MenuItem("Align",(char *)0x0,((byte)param_1[4] & 0x10) == 0,true);
if (cVar1 != '\0') {
param_1[4] = (ImPlotSubplot)((byte)param_1[4] ^ 0x10);
}
cVar1 = ImGui::MenuItem("Share Items",(char *)0x0,SUB41((*(uint *)(param_1 + 4) & 0x20) >> 5,0),
true);
if (cVar1 != '\0') {
param_1[4] = (ImPlotSubplot)((byte)param_1[4] ^ 0x20);
}
ImGui::EndMenu();
return;
}
return;
}
| |
23,360 | minja::Parser::parseNumber(__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>&, __gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&) | monkey531[P]llama/common/minja.hpp | json parseNumber(CharIterator& it, const CharIterator& end) {
auto before = it;
consumeSpaces();
auto start = it;
bool hasDecimal = false;
bool hasExponent = false;
if (it != end && (*it == '-' || *it == '+')) ++it;
while (it != end) {
if (std::isdigit(*it)) {
++it;
} else if (*it == '.') {
if (hasDecimal) throw std::runtime_error("Multiple decimal points");
hasDecimal = true;
++it;
} else if (it != start && (*it == 'e' || *it == 'E')) {
if (hasExponent) throw std::runtime_error("Multiple exponents");
hasExponent = true;
++it;
} else {
break;
}
}
if (start == it) {
it = before;
return json(); // No valid characters found
}
std::string str(start, it);
try {
return json::parse(str);
} catch (json::parse_error& e) {
throw std::runtime_error("Failed to parse number: '" + str + "' (" + std::string(e.what()) + ")");
return json();
}
} | O3 | cpp | minja::Parser::parseNumber(__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>&, __gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xf8, %rsp
movq %rcx, %r15
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %rbx
movq (%rdx), %r9
movq 0x18(%rsi), %rbp
movq 0x20(%rsi), %r13
movq %r9, %rsi
cmpq %rbp, %r13
je 0x6f9be
movq %rbx, 0x8(%rsp)
movq %r9, %rbx
movsbl (%r13), %edi
callq 0x190b0
testl %eax, %eax
je 0x6f9b3
incq %r13
movq %r13, 0x20(%r12)
cmpq %rbp, %r13
jne 0x6f998
movq (%r14), %rsi
movq %rbx, %r9
movq 0x8(%rsp), %rbx
movq (%r15), %rax
cmpq %rsi, %rax
je 0x6faa8
movzbl (%rsi), %ecx
cmpl $0x2d, %ecx
je 0x6f9da
movq %rsi, %rdx
cmpl $0x2b, %ecx
jne 0x6f9e4
leaq 0x1(%rsi), %rdx
movq %rdx, (%r14)
movq (%r15), %rax
cmpq %rax, %rdx
je 0x6fa31
xorl %eax, %eax
xorl %ecx, %ecx
movsbl (%rdx), %edi
leal -0x30(%rdi), %r8d
cmpl $0xa, %r8d
jb 0x6fa26
movzbl %dil, %edi
cmpl $0x2e, %edi
jne 0x6fa0e
testb $0x1, %al
movb $0x1, %al
je 0x6fa26
jmp 0x6fae5
cmpq %rsi, %rdx
je 0x6fa31
orl $0x20, %edi
cmpl $0x65, %edi
jne 0x6fa31
testb $0x1, %cl
movb $0x1, %cl
jne 0x6fb03
incq %rdx
movq %rdx, (%r14)
cmpq (%r15), %rdx
jne 0x6f9ed
cmpq %rsi, %rdx
je 0x6faa8
leaq 0x20(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x10(%rsp), %rdi
callq 0x4cb3c
xorps %xmm0, %xmm0
leaq 0x90(%rsp), %rdx
movaps %xmm0, 0x10(%rdx)
movaps %xmm0, (%rdx)
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
movl $0x1, %ecx
xorl %r8d, %r8d
callq 0x7035c
movq 0xa0(%rsp), %rax
testq %rax, %rax
je 0x6fa8f
leaq 0x90(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x10(%rsp), %rdi
cmpq %r15, %rdi
je 0x6fad0
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x196b0
jmp 0x6fad0
movq %r9, (%r14)
movb $0x0, (%rbx)
movq $0x0, 0x8(%rbx)
movq %rbx, %rdi
movl $0x1, %esi
callq 0x284e2
movq %rbx, %rdi
movl $0x1, %esi
callq 0x284e2
movq %rbx, %rax
addq $0xf8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x19370
movq %rax, %rbx
leaq 0x4b7f5(%rip), %rsi # 0xbb2ee
movq %rax, %rdi
callq 0x19270
jmp 0x6fb1f
movl $0x10, %edi
callq 0x19370
movq %rax, %rbx
leaq 0x4b7ef(%rip), %rsi # 0xbb306
movq %rax, %rdi
callq 0x19270
movq 0x7c4c2(%rip), %rsi # 0xebfe8
movq 0x7c43b(%rip), %rdx # 0xebf68
movq %rbx, %rdi
callq 0x19b70
jmp 0x6fdaa
movq %rdx, %rbx
movq %rax, %r14
movq 0xa0(%rsp), %rax
testq %rax, %rax
je 0x6fb5f
leaq 0x90(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
cmpl $0x1, %ebx
jne 0x6fd8f
movq %r14, %rdi
callq 0x192b0
movq %rax, %r14
movl $0x10, %edi
callq 0x19370
movq %rax, %rbx
leaq 0x4b792(%rip), %rsi # 0xbb319
leaq 0x50(%rsp), %rdi
leaq 0x10(%rsp), %rdx
callq 0x4ca3d
leaq 0x4b796(%rip), %rsi # 0xbb333
leaq 0x50(%rsp), %rdi
callq 0x19d00
leaq 0x40(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
jne 0x6fbca
movups (%rcx), %xmm0
movups %xmm0, (%r12)
jmp 0x6fbd7
movq %rdx, 0x30(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x40(%rsp)
movq 0x8(%rax), %rdx
movq %rdx, 0x38(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq (%r14), %rax
movq %r14, %rdi
callq *0x10(%rax)
leaq 0xb8(%rsp), %rdi
leaq 0x7(%rsp), %rdx
movq %rax, %rsi
callq 0x35492
leaq 0xd8(%rsp), %rdi
leaq 0x30(%rsp), %rsi
leaq 0xb8(%rsp), %rdx
callq 0x4aa05
leaq 0x476d5(%rip), %rsi # 0xb7303
leaq 0xd8(%rsp), %rdi
callq 0x19d00
leaq 0x80(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
jne 0x6fc60
movups (%rcx), %xmm0
movups %xmm0, (%r13)
jmp 0x6fc70
movq %rdx, 0x70(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x80(%rsp)
movq 0x8(%rax), %rdx
leaq 0x70(%rsp), %rsi
movq %rdx, 0x8(%rsi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movb $0x1, %bpl
movq %rbx, %rdi
callq 0x19ac0
xorl %ebp, %ebp
movq 0x7c348(%rip), %rsi # 0xebfe8
movq 0x7c2c1(%rip), %rdx # 0xebf68
movq %rbx, %rdi
callq 0x19b70
movq %rax, %r14
movq 0x70(%rsp), %rdi
cmpq %r13, %rdi
je 0x6fcd4
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x196b0
jmp 0x6fcd4
movq %rax, %r14
movb $0x1, %bpl
leaq 0xe8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6fcfd
movq 0xe8(%rsp), %rsi
incq %rsi
callq 0x196b0
jmp 0x6fcfd
movq %rax, %r14
movb $0x1, %bpl
leaq 0xc8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6fd26
movq 0xc8(%rsp), %rsi
incq %rsi
callq 0x196b0
jmp 0x6fd26
movq %rax, %r14
movb $0x1, %bpl
movq 0x30(%rsp), %rdi
cmpq %r12, %rdi
je 0x6fd3d
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x196b0
leaq 0x60(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6fd58
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x196b0
testb %bpl, %bpl
jne 0x6fd82
jmp 0x6fd8a
movq %rax, %r14
leaq 0x60(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6fd82
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x196b0
jmp 0x6fd82
movq %rax, %r14
movq %rbx, %rdi
callq 0x19510
callq 0x19af0
movq 0x10(%rsp), %rdi
cmpq %r15, %rdi
je 0x6fdc4
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x196b0
jmp 0x6fdc4
jmp 0x6fdaa
movq %rax, %rdi
callq 0x27a01
movq %rax, %r14
jmp 0x6fdc4
jmp 0x6fdb9
movq %rax, %r14
movq %rbx, %rdi
callq 0x19510
movq %r14, %rdi
callq 0x19be0
| _ZN5minja6Parser11parseNumberERN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKSB_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0F8h
mov r15, rcx
mov r14, rdx
mov r12, rsi
mov rbx, rdi
mov r9, [rdx]
mov rbp, [rsi+18h]
mov r13, [rsi+20h]
mov rsi, r9
cmp r13, rbp
jz short loc_6F9BE
mov [rsp+128h+var_120], rbx
mov rbx, r9
loc_6F998:
movsx edi, byte ptr [r13+0]
call _isspace
test eax, eax
jz short loc_6F9B3
inc r13
mov [r12+20h], r13
cmp r13, rbp
jnz short loc_6F998
loc_6F9B3:
mov rsi, [r14]
mov r9, rbx
mov rbx, [rsp+128h+var_120]
loc_6F9BE:
mov rax, [r15]
cmp rax, rsi
jz loc_6FAA8
movzx ecx, byte ptr [rsi]
cmp ecx, 2Dh ; '-'
jz short loc_6F9DA
mov rdx, rsi
cmp ecx, 2Bh ; '+'
jnz short loc_6F9E4
loc_6F9DA:
lea rdx, [rsi+1]
mov [r14], rdx
mov rax, [r15]
loc_6F9E4:
cmp rdx, rax
jz short loc_6FA31
xor eax, eax
xor ecx, ecx
loc_6F9ED:
movsx edi, byte ptr [rdx]
lea r8d, [rdi-30h]
cmp r8d, 0Ah
jb short loc_6FA26
movzx edi, dil
cmp edi, 2Eh ; '.'
jnz short loc_6FA0E
test al, 1
mov al, 1
jz short loc_6FA26
jmp loc_6FAE5
loc_6FA0E:
cmp rdx, rsi
jz short loc_6FA31
or edi, 20h
cmp edi, 65h ; 'e'
jnz short loc_6FA31
test cl, 1
mov cl, 1
jnz loc_6FB03
loc_6FA26:
inc rdx
mov [r14], rdx
cmp rdx, [r15]
jnz short loc_6F9ED
loc_6FA31:
cmp rdx, rsi
jz short loc_6FAA8
lea r15, [rsp+128h+var_108]
mov [r15-10h], r15
lea rdi, [rsp+128h+var_118]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIN9__gnu_cxx17__normal_iteratorIPKcS4_EEEEvT_SB_St20forward_iterator_tag; std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::forward_iterator_tag)
xorps xmm0, xmm0
lea rdx, [rsp+128h+var_98]
movaps xmmword ptr [rdx+10h], xmm0
movaps xmmword ptr [rdx], xmm0
lea rsi, [rsp+128h+var_118]
mov rdi, rbx
mov ecx, 1
xor r8d, r8d
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5parseIRS9_EESD_OT_St8functionIFbiNS0_6detail13parse_event_tERSD_EEbb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::parse<std::string&>(std::string&,std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&)>,bool,bool)
mov rax, [rsp+128h+var_88]
test rax, rax
jz short loc_6FA8F
lea rdi, [rsp+128h+var_98]
mov rsi, rdi
mov edx, 3
call rax
loc_6FA8F:
mov rdi, [rsp+128h+var_118]; void *
cmp rdi, r15
jz short loc_6FAD0
mov rsi, [rsp+128h+var_108]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_6FAD0
loc_6FAA8:
mov [r14], r9
mov byte ptr [rbx], 0
mov qword ptr [rbx+8], 0
mov rdi, rbx
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 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)
loc_6FAD0:
mov rax, rbx
add rsp, 0F8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_6FAE5:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rsi, aMultipleDecima; "Multiple decimal points"
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
jmp short loc_6FB1F
loc_6FB03:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rsi, aMultipleExpone; "Multiple exponents"
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
loc_6FB1F:
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
jmp loc_6FDAA
mov rbx, rdx
mov r14, rax
mov rax, [rsp+128h+var_88]
test rax, rax
jz short loc_6FB5F
lea rdi, [rsp+128h+var_98]
mov rsi, rdi
mov edx, 3
call rax
loc_6FB5F:
cmp ebx, 1
jnz loc_6FD8F
mov rdi, r14; void *
call ___cxa_begin_catch
mov r14, rax
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rsi, aFailedToParseN; "Failed to parse number: '"
lea rdi, [rsp+128h+var_D8]
lea rdx, [rsp+128h+var_118]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
lea rsi, asc_BB333; "' ("
lea rdi, [rsp+128h+var_D8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea r12, [rsp+128h+var_E8]
mov [r12-10h], r12
mov rdx, [rax]
mov rcx, rax
add rcx, 10h
cmp rdx, rcx
jnz short loc_6FBCA
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [r12], xmm0
jmp short loc_6FBD7
loc_6FBCA:
mov [rsp+128h+var_F8], rdx
mov rdx, [rcx]
mov [rsp+128h+var_E8], rdx
loc_6FBD7:
mov rdx, [rax+8]
mov [rsp+128h+var_F0], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
mov rax, [r14]
mov rdi, r14
call qword ptr [rax+10h]
lea rdi, [rsp+128h+var_70]
lea rdx, [rsp+128h+var_121]
mov rsi, rax
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rdi, [rsp+128h+var_50]
lea rsi, [rsp+128h+var_F8]
lea rdx, [rsp+128h+var_70]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_S9_; std::operator+<char>(std::string&&,std::string&)
lea rsi, a09401910201912+51h; ")"
lea rdi, [rsp+128h+var_50]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea r13, [rsp+128h+var_A8]
mov [r13-10h], r13
mov rdx, [rax]
mov rcx, rax
add rcx, 10h
cmp rdx, rcx
jnz short loc_6FC60
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [r13+0], xmm0
jmp short loc_6FC70
loc_6FC60:
mov [rsp+128h+var_B8], rdx
mov rdx, [rcx]
mov [rsp+128h+var_A8], rdx
loc_6FC70:
mov rdx, [rax+8]
lea rsi, [rsp+128h+var_B8]
mov [rsi+8], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
mov bpl, 1
mov rdi, rbx
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
xor ebp, ebp
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
mov rdi, [rsp+128h+var_B8]; void *
cmp rdi, r13
jz short loc_6FCD4
mov rsi, [rsp+128h+var_A8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_6FCD4
mov r14, rax
mov bpl, 1
loc_6FCD4:
lea rax, [rsp+128h+var_40]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_6FCFD
mov rsi, [rsp+128h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_6FCFD
mov r14, rax
mov bpl, 1
loc_6FCFD:
lea rax, [rsp+128h+var_60]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_6FD26
mov rsi, [rsp+128h+var_60]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_6FD26
mov r14, rax
mov bpl, 1
loc_6FD26:
mov rdi, [rsp+128h+var_F8]; void *
cmp rdi, r12
jz short loc_6FD3D
mov rsi, [rsp+128h+var_E8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_6FD3D:
lea rax, [rsp+128h+var_C8]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_6FD58
mov rsi, [rsp+128h+var_C8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_6FD58:
test bpl, bpl
jnz short loc_6FD82
jmp short loc_6FD8A
mov r14, rax
lea rax, [rsp+128h+var_C8]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_6FD82
mov rsi, [rsp+128h+var_C8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_6FD82
mov r14, rax
loc_6FD82:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_6FD8A:
call ___cxa_end_catch
loc_6FD8F:
mov rdi, [rsp+128h+var_118]; void *
cmp rdi, r15
jz short loc_6FDC4
mov rsi, [rsp+128h+var_108]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_6FDC4
jmp short $+2
loc_6FDAA:
mov rdi, rax
call __clang_call_terminate
mov r14, rax
jmp short loc_6FDC4
jmp short $+2
loc_6FDB9:
mov r14, rax
mov rdi, rbx; void *
call ___cxa_free_exception
loc_6FDC4:
mov rdi, r14
call __Unwind_Resume
| long long minja::Parser::parseNumber(long long a1, long long a2, char **a3, char **a4)
{
long long v7; // rbx
char *v8; // r9
char *v9; // rbp
char *v10; // r13
char *v11; // rsi
char *v12; // rbx
char *v13; // rax
int v14; // ecx
char *v15; // rdx
char v16; // al
char v17; // cl
int v18; // edi
bool v19; // zf
std::runtime_error *exception; // rbx
void *v22[2]; // [rsp+10h] [rbp-118h] BYREF
_QWORD v23[2]; // [rsp+20h] [rbp-108h] BYREF
__int128 v24; // [rsp+90h] [rbp-98h] BYREF
__int128 v25; // [rsp+A0h] [rbp-88h]
v7 = a1;
v8 = *a3;
v9 = *(char **)(a2 + 24);
v10 = *(char **)(a2 + 32);
v11 = *a3;
if ( v10 != v9 )
{
v12 = *a3;
do
{
if ( !(unsigned int)isspace((unsigned int)*v10) )
break;
*(_QWORD *)(a2 + 32) = ++v10;
}
while ( v10 != v9 );
v11 = *a3;
v8 = v12;
v7 = a1;
}
v13 = *a4;
if ( *a4 == v11 )
goto LABEL_25;
v14 = (unsigned __int8)*v11;
if ( v14 == 45 || (v15 = v11, v14 == 43) )
{
v15 = v11 + 1;
*a3 = v11 + 1;
v13 = *a4;
}
if ( v15 != v13 )
{
v16 = 0;
v17 = 0;
do
{
v18 = *v15;
if ( (unsigned int)(v18 - 48) >= 0xA )
{
if ( (unsigned __int8)v18 == 46 )
{
v19 = (v16 & 1) == 0;
v16 = 1;
if ( !v19 )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Multiple decimal points");
goto LABEL_28;
}
}
else
{
if ( v15 == v11 || ((unsigned __int8)v18 | 0x20) != 0x65 )
break;
v19 = (v17 & 1) == 0;
v17 = 1;
if ( !v19 )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Multiple exponents");
LABEL_28:
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
}
}
*a3 = ++v15;
}
while ( v15 != *a4 );
}
if ( v15 == v11 )
{
LABEL_25:
*a3 = v8;
*(_BYTE *)v7 = 0;
*(_QWORD *)(v7 + 8) = 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 *)v7);
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 *)v7);
}
else
{
v22[0] = v23;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>((long long)v22, v11, (long long)v15);
v25 = 0LL;
v24 = 0LL;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::parse<std::string&>(
v7,
v22,
&v24,
1LL,
0LL);
if ( (_QWORD)v25 )
((void ( *)(__int128 *, __int128 *, long long))v25)(&v24, &v24, 3LL);
if ( v22[0] != v23 )
operator delete(v22[0], v23[0] + 1LL);
}
return v7;
}
| parseNumber:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xf8
MOV R15,RCX
MOV R14,RDX
MOV R12,RSI
MOV RBX,RDI
MOV R9,qword ptr [RDX]
MOV RBP,qword ptr [RSI + 0x18]
MOV R13,qword ptr [RSI + 0x20]
MOV RSI,R9
CMP R13,RBP
JZ 0x0016f9be
MOV qword ptr [RSP + 0x8],RBX
MOV RBX,R9
LAB_0016f998:
MOVSX EDI,byte ptr [R13]
CALL 0x001190b0
TEST EAX,EAX
JZ 0x0016f9b3
INC R13
MOV qword ptr [R12 + 0x20],R13
CMP R13,RBP
JNZ 0x0016f998
LAB_0016f9b3:
MOV RSI,qword ptr [R14]
MOV R9,RBX
MOV RBX,qword ptr [RSP + 0x8]
LAB_0016f9be:
MOV RAX,qword ptr [R15]
CMP RAX,RSI
JZ 0x0016faa8
MOVZX ECX,byte ptr [RSI]
CMP ECX,0x2d
JZ 0x0016f9da
MOV RDX,RSI
CMP ECX,0x2b
JNZ 0x0016f9e4
LAB_0016f9da:
LEA RDX,[RSI + 0x1]
MOV qword ptr [R14],RDX
MOV RAX,qword ptr [R15]
LAB_0016f9e4:
CMP RDX,RAX
JZ 0x0016fa31
XOR EAX,EAX
XOR ECX,ECX
LAB_0016f9ed:
MOVSX EDI,byte ptr [RDX]
LEA R8D,[RDI + -0x30]
CMP R8D,0xa
JC 0x0016fa26
MOVZX EDI,DIL
CMP EDI,0x2e
JNZ 0x0016fa0e
TEST AL,0x1
MOV AL,0x1
JZ 0x0016fa26
JMP 0x0016fae5
LAB_0016fa0e:
CMP RDX,RSI
JZ 0x0016fa31
OR EDI,0x20
CMP EDI,0x65
JNZ 0x0016fa31
TEST CL,0x1
MOV CL,0x1
JNZ 0x0016fb03
LAB_0016fa26:
INC RDX
MOV qword ptr [R14],RDX
CMP RDX,qword ptr [R15]
JNZ 0x0016f9ed
LAB_0016fa31:
CMP RDX,RSI
JZ 0x0016faa8
LEA R15,[RSP + 0x20]
MOV qword ptr [R15 + -0x10],R15
LAB_0016fa3f:
LEA RDI,[RSP + 0x10]
CALL 0x0014cb3c
XORPS XMM0,XMM0
LEA RDX,[RSP + 0x90]
MOVAPS xmmword ptr [RDX + 0x10],XMM0
MOVAPS xmmword ptr [RDX],XMM0
LAB_0016fa5b:
LEA RSI,[RSP + 0x10]
MOV RDI,RBX
MOV ECX,0x1
XOR R8D,R8D
CALL 0x0017035c
MOV RAX,qword ptr [RSP + 0xa0]
TEST RAX,RAX
JZ 0x0016fa8f
LAB_0016fa7d:
LEA RDI,[RSP + 0x90]
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_0016fa8f:
MOV RDI,qword ptr [RSP + 0x10]
CMP RDI,R15
JZ 0x0016fad0
MOV RSI,qword ptr [RSP + 0x20]
INC RSI
CALL 0x001196b0
JMP 0x0016fad0
LAB_0016faa8:
MOV qword ptr [R14],R9
MOV byte ptr [RBX],0x0
MOV qword ptr [RBX + 0x8],0x0
MOV RDI,RBX
MOV ESI,0x1
CALL 0x001284e2
MOV RDI,RBX
MOV ESI,0x1
CALL 0x001284e2
LAB_0016fad0:
MOV RAX,RBX
ADD RSP,0xf8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0016fae5:
MOV EDI,0x10
CALL 0x00119370
MOV RBX,RAX
LAB_0016faf2:
LEA RSI,[0x1bb2ee]
MOV RDI,RAX
CALL 0x00119270
LAB_0016fb01:
JMP 0x0016fb1f
LAB_0016fb03:
MOV EDI,0x10
CALL 0x00119370
MOV RBX,RAX
LAB_0016fb10:
LEA RSI,[0x1bb306]
MOV RDI,RAX
CALL 0x00119270
LAB_0016fb1f:
MOV RSI,qword ptr [0x001ebfe8]
MOV RDX,qword ptr [0x001ebf68]
MOV RDI,RBX
CALL 0x00119b70
|
/* minja::Parser::parseNumber(__gnu_cxx::__normal_iterator<char const*, std::__cxx11::string >&,
__gnu_cxx::__normal_iterator<char const*, std::__cxx11::string > const&) */
__normal_iterator *
minja::Parser::parseNumber(__normal_iterator *param_1,__normal_iterator *param_2)
{
byte bVar1;
byte *pbVar2;
char *pcVar3;
bool bVar4;
bool bVar5;
bool bVar6;
int iVar7;
byte *pbVar8;
runtime_error *this;
bool bVar9;
int8 *in_RCX;
long *in_RDX;
byte *pbVar10;
byte *pbVar11;
char *pcVar12;
long *local_118 [2];
long local_108 [14];
int8 local_98;
int8 uStack_90;
code *local_88;
int8 uStack_80;
pbVar2 = (byte *)*in_RDX;
pcVar3 = *(char **)(param_2 + 0x18);
pcVar12 = *(char **)(param_2 + 0x20);
pbVar11 = pbVar2;
if (pcVar12 != pcVar3) {
do {
iVar7 = isspace((int)*pcVar12);
if (iVar7 == 0) break;
pcVar12 = pcVar12 + 1;
*(char **)(param_2 + 0x20) = pcVar12;
} while (pcVar12 != pcVar3);
pbVar11 = (byte *)*in_RDX;
}
pbVar8 = (byte *)*in_RCX;
if (pbVar8 != pbVar11) {
if ((*pbVar11 == 0x2d) || (pbVar10 = pbVar11, *pbVar11 == 0x2b)) {
pbVar10 = pbVar11 + 1;
*in_RDX = (long)pbVar10;
pbVar8 = (byte *)*in_RCX;
}
if (pbVar10 != pbVar8) {
bVar6 = false;
bVar9 = false;
do {
bVar1 = *pbVar10;
bVar4 = bVar6;
bVar5 = bVar9;
if (9 < (int)(char)bVar1 - 0x30U) {
if (bVar1 == 0x2e) {
bVar4 = true;
if (bVar6) {
this = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0016faf2 to 0016fb00 has its CatchHandler @ 0016fdb9 */
std::runtime_error::runtime_error(this,"Multiple decimal points");
LAB_0016fb1f:
/* WARNING: Subroutine does not return */
__cxa_throw(this,PTR_typeinfo_001ebfe8,PTR__runtime_error_001ebf68);
}
}
else {
if ((pbVar10 == pbVar11) || ((bVar1 | 0x20) != 0x65)) break;
bVar5 = true;
if (bVar9) {
this = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0016fb10 to 0016fb1e has its CatchHandler @ 0016fdb7 */
std::runtime_error::runtime_error(this,"Multiple exponents");
goto LAB_0016fb1f;
}
}
}
bVar9 = bVar5;
bVar6 = bVar4;
pbVar10 = pbVar10 + 1;
*in_RDX = (long)pbVar10;
} while (pbVar10 != (byte *)*in_RCX);
}
if (pbVar10 != pbVar11) {
/* try { // try from 0016fa3f to 0016fa48 has its CatchHandler @ 0016fdb2 */
local_118[0] = local_108;
std::__cxx11::string::
_M_construct<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>(local_118);
local_88 = (code *)0x0;
uStack_80 = 0;
local_98 = 0;
uStack_90 = 0;
/* try { // try from 0016fa5b to 0016fa6f has its CatchHandler @ 0016fb3a */
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::parse<std::__cxx11::string&>
((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*)param_1,local_118,&local_98,1,0);
if (local_88 != (code *)0x0) {
/* try { // try from 0016fa7d to 0016fa8e has its CatchHandler @ 0016fb35 */
(*local_88)(&local_98,&local_98,3);
}
if (local_118[0] == local_108) {
return param_1;
}
operator_delete(local_118[0],local_108[0] + 1);
return param_1;
}
}
*in_RDX = (long)pbVar2;
*param_1 = 0;
*(int8 *)(param_1 + 8) = 0;
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(param_1,0));
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(param_1,0));
return param_1;
}
| |
23,361 | my_wc_to_printable_8bit | eloqsql/strings/ctype.c | int
my_wc_to_printable_8bit(CHARSET_INFO *cs, my_wc_t wc,
uchar *str, uchar *end)
{
/*
Special case: swe7 does not have the backslash character.
Use dot instead of backslash for escaping.
*/
uint bs= cs->tab_to_uni && cs->tab_to_uni['\\'] != '\\' ? '.' : '\\';
DBUG_ASSERT(cs->mbminlen == 1);
/*
Additionally, if the original swe7 string contains backslashes,
replace them to dots, so this error message:
Invalid swe7 character string: '\xEF\xBC\xB4'
is displayed as:
Invalid swe7 character string: '.xEF.xBC.xB4'
which is more readable than what would happen without '\'-to-dot mapping:
Invalid swe7 character string: '.005CxEF.005CxBC.005CxB4'
*/
if (bs == '.' && wc == '\\')
wc= '.';
return my_wc_to_printable_ex(cs, wc, str, end, bs, 1, 1);
} | O3 | c | my_wc_to_printable_8bit:
movq 0x68(%rdi), %rax
testq %rax, %rax
je 0x59d8d
cmpw $0x5c, 0xb8(%rax)
setne %al
movl $0x2e, %r9d
movl $0x5c, %r8d
cmovnel %r9d, %r8d
jmp 0x59d95
movl $0x5c, %r8d
xorl %eax, %eax
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
testb %al, %al
movl $0x2e, %eax
cmoveq %rsi, %rax
cmpq $0x5c, %rsi
cmovneq %rsi, %rax
movl $0x1, (%rsp)
movq %rax, %rsi
movl $0x1, %r9d
callq 0x59bc0
addq $0x10, %rsp
popq %rbp
retq
| my_wc_to_printable_8bit:
mov rax, [rdi+68h]
test rax, rax
jz short loc_59D8D
cmp word ptr [rax+0B8h], 5Ch ; '\'
setnz al
mov r9d, 2Eh ; '.'
mov r8d, 5Ch ; '\'
cmovnz r8d, r9d
jmp short loc_59D95
loc_59D8D:
mov r8d, 5Ch ; '\'
xor eax, eax
loc_59D95:
push rbp
mov rbp, rsp
sub rsp, 10h
test al, al
mov eax, 2Eh ; '.'
cmovz rax, rsi
cmp rsi, 5Ch ; '\'
cmovnz rax, rsi
mov [rsp+18h+var_18], 1
mov rsi, rax
mov r9d, 1
call my_wc_to_printable_ex
add rsp, 10h
pop rbp
retn
| long long my_wc_to_printable_8bit(long long a1, unsigned long long a2, _BYTE *a3, unsigned long long a4)
{
long long v4; // rax
bool v5; // zf
bool v6; // al
char v7; // r8
unsigned long long v8; // rax
v4 = *(_QWORD *)(a1 + 104);
if ( v4 )
{
v5 = *(_WORD *)(v4 + 184) == 92;
v6 = *(_WORD *)(v4 + 184) != 92;
v7 = 92;
if ( !v5 )
v7 = 46;
}
else
{
v7 = 92;
v6 = 0;
}
v5 = !v6;
v8 = 46LL;
if ( v5 )
v8 = a2;
if ( a2 != 92 )
v8 = a2;
return my_wc_to_printable_ex(a1, v8, a3, a4, v7, 1u, 1u);
}
| my_wc_to_printable_8bit:
MOV RAX,qword ptr [RDI + 0x68]
TEST RAX,RAX
JZ 0x00159d8d
CMP word ptr [RAX + 0xb8],0x5c
SETNZ AL
MOV R9D,0x2e
MOV R8D,0x5c
CMOVNZ R8D,R9D
JMP 0x00159d95
LAB_00159d8d:
MOV R8D,0x5c
XOR EAX,EAX
LAB_00159d95:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
TEST AL,AL
MOV EAX,0x2e
CMOVZ RAX,RSI
CMP RSI,0x5c
CMOVNZ RAX,RSI
MOV dword ptr [RSP],0x1
MOV RSI,RAX
MOV R9D,0x1
CALL 0x00159bc0
ADD RSP,0x10
POP RBP
RET
|
void my_wc_to_printable_8bit(long param_1,long param_2,int8 param_3,int8 param_4)
{
long lVar1;
int8 uVar2;
bool bVar3;
if (*(long *)(param_1 + 0x68) == 0) {
uVar2 = 0x5c;
bVar3 = false;
}
else {
bVar3 = *(short *)(*(long *)(param_1 + 0x68) + 0xb8) != 0x5c;
uVar2 = 0x5c;
if (bVar3) {
uVar2 = 0x2e;
}
}
lVar1 = 0x2e;
if (!bVar3) {
lVar1 = param_2;
}
if (param_2 != 0x5c) {
lVar1 = param_2;
}
my_wc_to_printable_ex(param_1,lVar1,param_3,param_4,uVar2,1,1);
return;
}
| |
23,362 | ps_fetch_int8 | eloqsql/libmariadb/libmariadb/ma_stmt_codec.c | static
void ps_fetch_int8(MYSQL_BIND *r_param, const MYSQL_FIELD * const field,
unsigned char **row)
{
switch(r_param->buffer_type) {
case MYSQL_TYPE_TINY:
ps_fetch_from_1_to_8_bytes(r_param, field, row, 1);
break;
default:
{
uchar val= **row;
longlong lval= field->flags & UNSIGNED_FLAG ? (longlong) val : (longlong)(signed char)val;
convert_from_long(r_param, field, lval, field->flags & UNSIGNED_FLAG);
(*row) += 1;
}
break;
}
} | O3 | c | ps_fetch_int8:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdx, %rbx
cmpl $0x1, 0x60(%rdi)
jne 0x23716
movb 0x64(%rsi), %al
shrb $0x5, %al
andb $0x1, %al
movq $0x1, 0x40(%rdi)
movq (%rbx), %rcx
movb (%rcx), %cl
movq 0x10(%rdi), %rdx
movb %cl, (%rdx)
cmpb 0x65(%rdi), %al
jne 0x23731
xorl %eax, %eax
jmp 0x2373a
movq (%rbx), %rax
movsbq (%rax), %rax
movl 0x64(%rsi), %ecx
andl $0x20, %ecx
movzbl %al, %edx
cmoveq %rax, %rdx
callq 0x2426b
jmp 0x23740
movq 0x10(%rdi), %rax
movb (%rax), %al
shrb $0x7, %al
movq 0x18(%rdi), %rcx
movb %al, (%rcx)
incq (%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| ps_fetch_int8:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdx
cmp dword ptr [rdi+60h], 1
jnz short loc_23716
mov al, [rsi+64h]
shr al, 5
and al, 1
mov qword ptr [rdi+40h], 1
mov rcx, [rbx]
mov cl, [rcx]
mov rdx, [rdi+10h]
mov [rdx], cl
cmp al, [rdi+65h]
jnz short loc_23731
xor eax, eax
jmp short loc_2373A
loc_23716:
mov rax, [rbx]
movsx rax, byte ptr [rax]
mov ecx, [rsi+64h]
and ecx, 20h
movzx edx, al
cmovz rdx, rax
call convert_from_long
jmp short loc_23740
loc_23731:
mov rax, [rdi+10h]
mov al, [rax]
shr al, 7
loc_2373A:
mov rcx, [rdi+18h]
mov [rcx], al
loc_23740:
inc qword ptr [rbx]
add rsp, 8
pop rbx
pop rbp
retn
| char ps_fetch_int8(long long a1, long long a2, _BYTE **a3)
{
char v4; // al
char result; // al
long long v6; // rdx
if ( *(_DWORD *)(a1 + 96) == 1 )
{
v4 = (*(_BYTE *)(a2 + 100) & 0x20) != 0;
*(_QWORD *)(a1 + 64) = 1LL;
**(_BYTE **)(a1 + 16) = **a3;
if ( v4 == *(_BYTE *)(a1 + 101) )
result = 0;
else
result = **(_BYTE **)(a1 + 16) >> 7;
**(_BYTE **)(a1 + 24) = result;
}
else
{
v6 = (unsigned __int8)**a3;
if ( (*(_DWORD *)(a2 + 100) & 0x20) == 0 )
v6 = (char)**a3;
result = convert_from_long(a1, a2, v6, *(_DWORD *)(a2 + 100) & 0x20);
}
++*a3;
return result;
}
| ps_fetch_int8:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RBX,RDX
CMP dword ptr [RDI + 0x60],0x1
JNZ 0x00123716
MOV AL,byte ptr [RSI + 0x64]
SHR AL,0x5
AND AL,0x1
MOV qword ptr [RDI + 0x40],0x1
MOV RCX,qword ptr [RBX]
MOV CL,byte ptr [RCX]
MOV RDX,qword ptr [RDI + 0x10]
MOV byte ptr [RDX],CL
CMP AL,byte ptr [RDI + 0x65]
JNZ 0x00123731
XOR EAX,EAX
JMP 0x0012373a
LAB_00123716:
MOV RAX,qword ptr [RBX]
MOVSX RAX,byte ptr [RAX]
MOV ECX,dword ptr [RSI + 0x64]
AND ECX,0x20
MOVZX EDX,AL
CMOVZ RDX,RAX
CALL 0x0012426b
JMP 0x00123740
LAB_00123731:
MOV RAX,qword ptr [RDI + 0x10]
MOV AL,byte ptr [RAX]
SHR AL,0x7
LAB_0012373a:
MOV RCX,qword ptr [RDI + 0x18]
MOV byte ptr [RCX],AL
LAB_00123740:
INC qword ptr [RBX]
ADD RSP,0x8
POP RBX
POP RBP
RET
|
void ps_fetch_int8(long param_1,long param_2,long *param_3)
{
byte bVar1;
ulong uVar2;
if (*(int *)(param_1 + 0x60) == 1) {
bVar1 = *(byte *)(param_2 + 100);
*(int8 *)(param_1 + 0x40) = 1;
**(int1 **)(param_1 + 0x10) = *(int1 *)*param_3;
if ((bVar1 >> 5 & 1) == *(byte *)(param_1 + 0x65)) {
bVar1 = 0;
}
else {
bVar1 = **(byte **)(param_1 + 0x10) >> 7;
}
**(byte **)(param_1 + 0x18) = bVar1;
}
else {
uVar2 = (ulong)*(byte *)*param_3;
if ((*(uint *)(param_2 + 100) & 0x20) == 0) {
uVar2 = (long)(char)*(byte *)*param_3;
}
convert_from_long(param_1,param_2,uVar2);
}
*param_3 = *param_3 + 1;
return;
}
| |
23,363 | tailoring_append | eloqsql/strings/ctype.c | static int
tailoring_append(MY_XML_PARSER *st,
const char *fmt, size_t len, const char *attr)
{
struct my_cs_file_info *i= (struct my_cs_file_info *) st->user_data;
size_t newlen= i->tailoring_length + len + 64; /* 64 for format */
if (MY_XML_OK == my_charset_file_tailoring_realloc(i, newlen))
{
char *dst= i->tailoring + i->tailoring_length;
sprintf(dst, fmt, (int) len, attr);
i->tailoring_length+= strlen(dst);
return MY_XML_OK;
}
return MY_XML_ERROR;
} | O3 | c | tailoring_append:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r9
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
movq 0x690(%rdi), %r13
leaq (%rdx,%r13), %rax
addq $0x40, %rax
cmpq %rax, 0x698(%rdi)
jbe 0x78193
movq 0x688(%rbx), %rax
jmp 0x781d7
movq %r9, %r14
addq %r15, %r13
movq 0x688(%rbx), %rdi
movq 0x7a8(%rbx), %rax
movq 0x90(%rax), %rax
addq $0x8040, %r13 # imm = 0x8040
movq %r13, 0x698(%rbx)
movq %r13, %rsi
callq *%rax
movq %rax, 0x688(%rbx)
testq %rax, %rax
je 0x7821a
movq 0x690(%rbx), %r13
movq %r14, %r9
addq %rax, %r13
xorl %r14d, %r14d
movq %r13, %rdi
movl $0x1, %esi
movq $-0x1, %rdx
movq %r12, %rcx
movl %r15d, %r8d
xorl %eax, %eax
callq 0x26200
movq %r13, %rdi
callq 0x26150
addq %rax, 0x690(%rbx)
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x1, %r14d
jmp 0x78208
| tailoring_append:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r9, rcx
mov r15, rdx
mov r12, rsi
mov rbx, rdi
mov r13, [rdi+690h]
lea rax, [rdx+r13]
add rax, 40h ; '@'
cmp [rdi+698h], rax
jbe short loc_78193
mov rax, [rbx+688h]
jmp short loc_781D7
loc_78193:
mov r14, r9
add r13, r15
mov rdi, [rbx+688h]
mov rax, [rbx+7A8h]
mov rax, [rax+90h]
add r13, 8040h
mov [rbx+698h], r13
mov rsi, r13
call rax
mov [rbx+688h], rax
test rax, rax
jz short loc_7821A
mov r13, [rbx+690h]
mov r9, r14
loc_781D7:
add r13, rax
xor r14d, r14d
mov rdi, r13
mov esi, 1
mov rdx, 0FFFFFFFFFFFFFFFFh
mov rcx, r12
mov r8d, r15d
xor eax, eax
call ___sprintf_chk
mov rdi, r13
call _strlen
add [rbx+690h], rax
loc_78208:
mov eax, r14d
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_7821A:
mov r14d, 1
jmp short loc_78208
| long long tailoring_append(_QWORD *a1, const char *a2, long long a3, long long a4)
{
long long v4; // rax
long long v5; // r9
unsigned int v6; // r15d
long long v8; // r13
long long v9; // rax
long long v11; // rdi
long long ( *v12)(long long, long long); // rax
long long v13; // r13
long long v14; // r13
unsigned int v15; // r14d
long long v17; // [rsp-8h] [rbp-30h]
v17 = v4;
v5 = a4;
v6 = a3;
v8 = a1[210];
if ( a1[211] <= (unsigned long long)(a3 + v8 + 64) )
{
v11 = a1[209];
v12 = *(long long ( **)(long long, long long))(a1[245] + 144LL);
v13 = a3 + v8 + 32832;
a1[211] = v13;
v9 = v12(v11, v13);
a1[209] = v9;
if ( !v9 )
return 1;
v8 = a1[210];
v5 = a4;
}
else
{
v9 = a1[209];
}
v14 = v9 + v8;
v15 = 0;
__sprintf_chk(v14, 1LL, -1LL, a2, v6, v5, v17);
a1[210] += strlen(v14);
return v15;
}
| tailoring_append:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R9,RCX
MOV R15,RDX
MOV R12,RSI
MOV RBX,RDI
MOV R13,qword ptr [RDI + 0x690]
LEA RAX,[RDX + R13*0x1]
ADD RAX,0x40
CMP qword ptr [RDI + 0x698],RAX
JBE 0x00178193
MOV RAX,qword ptr [RBX + 0x688]
JMP 0x001781d7
LAB_00178193:
MOV R14,R9
ADD R13,R15
MOV RDI,qword ptr [RBX + 0x688]
MOV RAX,qword ptr [RBX + 0x7a8]
MOV RAX,qword ptr [RAX + 0x90]
ADD R13,0x8040
MOV qword ptr [RBX + 0x698],R13
MOV RSI,R13
CALL RAX
MOV qword ptr [RBX + 0x688],RAX
TEST RAX,RAX
JZ 0x0017821a
MOV R13,qword ptr [RBX + 0x690]
MOV R9,R14
LAB_001781d7:
ADD R13,RAX
XOR R14D,R14D
MOV RDI,R13
MOV ESI,0x1
MOV RDX,-0x1
MOV RCX,R12
MOV R8D,R15D
XOR EAX,EAX
CALL 0x00126200
MOV RDI,R13
CALL 0x00126150
ADD qword ptr [RBX + 0x690],RAX
LAB_00178208:
MOV EAX,R14D
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0017821a:
MOV R14D,0x1
JMP 0x00178208
|
int8 tailoring_append(long param_1,int8 param_2,ulong param_3,int8 param_4)
{
code *pcVar1;
long lVar2;
size_t sVar3;
long lVar4;
lVar4 = *(long *)(param_1 + 0x690);
if (param_3 + lVar4 + 0x40 < *(ulong *)(param_1 + 0x698)) {
lVar2 = *(long *)(param_1 + 0x688);
}
else {
pcVar1 = *(code **)(*(long *)(param_1 + 0x7a8) + 0x90);
lVar4 = lVar4 + param_3 + 0x8040;
*(long *)(param_1 + 0x698) = lVar4;
lVar2 = (*pcVar1)(*(int8 *)(param_1 + 0x688),lVar4);
*(long *)(param_1 + 0x688) = lVar2;
if (lVar2 == 0) {
return 1;
}
lVar4 = *(long *)(param_1 + 0x690);
}
__sprintf_chk((char *)(lVar4 + lVar2),1,0xffffffffffffffff,param_2,param_3 & 0xffffffff,param_4);
sVar3 = strlen((char *)(lVar4 + lVar2));
*(long *)(param_1 + 0x690) = *(long *)(param_1 + 0x690) + sVar3;
return 0;
}
| |
23,364 | minja::Value::Value(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/./minja.hpp | Value(const json & v) {
if (v.is_object()) {
auto object = std::make_shared<ObjectType>();
for (auto it = v.begin(); it != v.end(); ++it) {
(*object)[it.key()] = it.value();
}
object_ = std::move(object);
} else if (v.is_array()) {
auto array = std::make_shared<ArrayType>();
for (const auto& item : v) {
array->push_back(Value(item));
}
array_ = array;
} else {
primitive_ = v;
}
} | O2 | cpp | minja::Value::Value(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 $0xb8, %rsp
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x40(%rdi), %r14
xorps %xmm0, %xmm0
movups %xmm0, 0x30(%rdi)
movups %xmm0, 0x20(%rdi)
movups %xmm0, 0x10(%rdi)
movups %xmm0, (%rdi)
movq %r14, %rdi
xorl %esi, %esi
callq 0x2c9ae
movzbl (%r15), %eax
cmpl $0x2, %eax
je 0x30b00
cmpl $0x1, %eax
jne 0x30b9e
movq %r14, (%rsp)
leaq 0x38(%rsp), %rdi
callq 0x3b9a1
leaq 0x20(%rbx), %r14
leaq 0x18(%rsp), %r13
movq %r13, %rdi
movq %r15, %rsi
callq 0x352dc
leaq 0x68(%rsp), %rbp
movq %rbp, %rdi
movq %r15, %rsi
callq 0x3533e
movq %r13, %rdi
movq %rbp, %rsi
callq 0x2f0a0
testb %al, %al
je 0x30be5
movq %r13, %rdi
callq 0x2f0aa
movq %rbp, %rdi
movq %rax, %rsi
callq 0x30a04
movq 0x38(%rsp), %r12
movq %r13, %rdi
callq 0x3ddba
movq %r12, %rdi
movq %rax, %rsi
callq 0x3dd62
movq %rax, %rdi
movq %rbp, %rsi
callq 0x3de52
movq %rbp, %rdi
callq 0x328fa
movq 0x18(%rsp), %rax
movzbl (%rax), %eax
cmpl $0x2, %eax
je 0x30aee
cmpl $0x1, %eax
jne 0x30af6
addq $0x30, 0x20(%rsp)
jmp 0x30a78
addq $0x10, 0x28(%rsp)
jmp 0x30a78
incq 0x30(%rsp)
jmp 0x30a78
movq %r14, (%rsp)
leaq 0x8(%rsp), %rdi
callq 0x3dec5
leaq 0x10(%rbx), %r12
leaq 0x18(%rsp), %r13
movq %r13, %rdi
movq %r15, %rsi
callq 0x352dc
leaq 0x38(%rsp), %rbp
movq %rbp, %rdi
movq %r15, %rsi
callq 0x3533e
leaq 0x68(%rsp), %r15
movq %r13, %rdi
movq %rbp, %rsi
callq 0x2f0a0
testb %al, %al
je 0x30bd1
movq %r13, %rdi
callq 0x2f0aa
movq 0x8(%rsp), %r14
movq %r15, %rdi
movq %rax, %rsi
callq 0x30a04
movq %r14, %rdi
movq %r15, %rsi
callq 0x3e358
movq %r15, %rdi
callq 0x328fa
movq 0x18(%rsp), %rax
movzbl (%rax), %eax
cmpl $0x2, %eax
je 0x30b8f
cmpl $0x1, %eax
jne 0x30b97
addq $0x30, 0x20(%rsp)
jmp 0x30b37
addq $0x10, 0x28(%rsp)
jmp 0x30b37
incq 0x30(%rsp)
jmp 0x30b37
leaq 0x58(%rsp), %rdi
movq %r15, %rsi
callq 0x2d362
movb 0x40(%rbx), %al
leaq 0x58(%rsp), %rdi
movb (%rdi), %cl
movb %cl, 0x40(%rbx)
movb %al, (%rdi)
movq 0x48(%rbx), %rax
movq 0x8(%rdi), %rcx
movq %rcx, 0x48(%rbx)
movq %rax, 0x8(%rdi)
callq 0x2cd5a
jmp 0x30bfc
leaq 0x8(%rsp), %rsi
movq %r12, %rdi
callq 0x3d898
leaq 0x10(%rsp), %rdi
jmp 0x30bf7
leaq 0x38(%rsp), %rsi
movq %r14, %rdi
callq 0x3e170
leaq 0x40(%rsp), %rdi
callq 0x341e0
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r14, (%rsp)
jmp 0x30c16
jmp 0x30c16
movq %rax, %r15
jmp 0x30c56
movq %rax, %r15
leaq 0x68(%rsp), %rdi
callq 0x328fa
jmp 0x30c33
jmp 0x30c30
jmp 0x30c30
jmp 0x30c49
movq %rax, %r15
leaq 0x10(%rsp), %rdi
jmp 0x30c51
movq %rax, %r15
leaq 0x68(%rsp), %rdi
callq 0x328fa
jmp 0x30c4c
movq %rax, %r15
leaq 0x40(%rsp), %rdi
callq 0x341e0
movq (%rsp), %rdi
callq 0x2cd5a
leaq 0x38(%rbx), %rdi
callq 0x341e0
leaq 0x28(%rbx), %rdi
callq 0x341e0
leaq 0x18(%rbx), %rdi
callq 0x341e0
addq $0x8, %rbx
movq %rbx, %rdi
callq 0x3ca5c
movq %r15, %rdi
callq 0x21e50
| _ZN5minja5ValueC2ERKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES5_IhSaIhEEvEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0B8h
mov r15, rsi
mov rbx, rdi
lea r14, [rdi+40h]
xorps xmm0, xmm0
movups xmmword ptr [rdi+30h], xmm0
movups xmmword ptr [rdi+20h], xmm0
movups xmmword ptr [rdi+10h], xmm0
movups xmmword ptr [rdi], xmm0
mov rdi, r14
xor esi, esi
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2EDn; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::basic_json(decltype(nullptr))
movzx eax, byte ptr [r15]
cmp eax, 2
jz loc_30B00
cmp eax, 1
jnz loc_30B9E
mov [rsp+0E8h+var_E8], r14
lea rdi, [rsp+0E8h+var_B0]
call _ZSt11make_sharedIN8nlohmann16json_abi_v3_11_311ordered_mapINS1_10basic_jsonIS2_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEN5minja5ValueESt4lessISE_ESaISt4pairIKSE_SG_EEEEJEESt10shared_ptrIT_EDpOT0_; std::make_shared<nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>>()
lea r14, [rbx+20h]
lea r13, [rsp+0E8h+var_D0]
mov rdi, r13
mov rsi, r15
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6cbeginEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::cbegin(void)
lea rbp, [rsp+0E8h+var_80]
loc_30A78:
mov rdi, rbp
mov rsi, r15
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4cendEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::cend(void)
mov rdi, r13
mov rsi, rbp
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_
test al, al
jz loc_30BE5
mov rdi, r13
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEdeEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::operator*(void)
mov rdi, rbp
mov rsi, rax
call _ZN5minja5ValueC2ERKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES5_IhSaIhEEvEE; minja::Value::Value(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
mov r12, [rsp+0E8h+var_B0]
mov rdi, r13
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE3keyEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::key(void)
mov rdi, r12
mov rsi, rax
call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEEixIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEERSF_OST_
mov rdi, rax
mov rsi, rbp
call _ZN5minja5ValueaSEOS0_; minja::Value::operator=(minja::Value&&)
mov rdi, rbp; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
mov rax, [rsp+0E8h+var_D0]
movzx eax, byte ptr [rax]
cmp eax, 2
jz short loc_30AEE
cmp eax, 1
jnz short loc_30AF6
add [rsp+0E8h+var_C8], 30h ; '0'
jmp short loc_30A78
loc_30AEE:
add [rsp+0E8h+var_C0], 10h
jmp short loc_30A78
loc_30AF6:
inc [rsp+0E8h+var_B8]
jmp loc_30A78
loc_30B00:
mov [rsp+0E8h+var_E8], r14
lea rdi, [rsp+0E8h+var_E0]
call _ZSt11make_sharedISt6vectorIN5minja5ValueESaIS2_EEJEESt10shared_ptrIT_EDpOT0_; std::make_shared<std::vector<minja::Value>>()
lea r12, [rbx+10h]
lea r13, [rsp+0E8h+var_D0]
mov rdi, r13
mov rsi, r15
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6cbeginEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::cbegin(void)
lea rbp, [rsp+0E8h+var_B0]
mov rdi, rbp
mov rsi, r15
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4cendEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::cend(void)
lea r15, [rsp+0E8h+var_80]
loc_30B37:
mov rdi, r13
mov rsi, rbp
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_
test al, al
jz loc_30BD1
mov rdi, r13
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEdeEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::operator*(void)
mov r14, [rsp+0E8h+var_E0]
mov rdi, r15
mov rsi, rax
call _ZN5minja5ValueC2ERKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES5_IhSaIhEEvEE; minja::Value::Value(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
mov rdi, r14
mov rsi, r15
call _ZNSt6vectorIN5minja5ValueESaIS1_EE12emplace_backIJS1_EEERS1_DpOT_; std::vector<minja::Value>::emplace_back<minja::Value>(minja::Value &&)
mov rdi, r15; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
mov rax, [rsp+0E8h+var_D0]
movzx eax, byte ptr [rax]
cmp eax, 2
jz short loc_30B8F
cmp eax, 1
jnz short loc_30B97
add [rsp+0E8h+var_C8], 30h ; '0'
jmp short loc_30B37
loc_30B8F:
add [rsp+0E8h+var_C0], 10h
jmp short loc_30B37
loc_30B97:
inc [rsp+0E8h+var_B8]
jmp short loc_30B37
loc_30B9E:
lea rdi, [rsp+0E8h+var_90]
mov rsi, r15
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ERKSD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::basic_json(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
mov al, [rbx+40h]
lea rdi, [rsp+0E8h+var_90]
mov cl, [rdi]
mov [rbx+40h], cl
mov [rdi], al
mov rax, [rbx+48h]
mov rcx, [rdi+8]
mov [rbx+48h], rcx
mov [rdi+8], rax
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
jmp short loc_30BFC
loc_30BD1:
lea rsi, [rsp+0E8h+var_E0]
mov rdi, r12
call _ZNSt12__shared_ptrISt6vectorIN5minja5ValueESaIS2_EELN9__gnu_cxx12_Lock_policyE2EEaSERKS7_; std::__shared_ptr<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2>::operator=(std::__shared_ptr<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2> const&)
lea rdi, [rsp+0E8h+var_D8]
jmp short loc_30BF7
loc_30BE5:
lea rsi, [rsp+0E8h+var_B0]
mov rdi, r14
call _ZNSt12__shared_ptrIN8nlohmann16json_abi_v3_11_311ordered_mapINS1_10basic_jsonIS2_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEN5minja5ValueESt4lessISE_ESaISt4pairIKSE_SG_EEEELN9__gnu_cxx12_Lock_policyE2EEaSEOSQ_; std::__shared_ptr<nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>,(__gnu_cxx::_Lock_policy)2>::operator=(std::__shared_ptr<nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>,(__gnu_cxx::_Lock_policy)2>&&)
lea rdi, [rsp+0E8h+var_A8]
loc_30BF7:
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
loc_30BFC:
add rsp, 0B8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov [rsp+0], r14
jmp short loc_30C16
jmp short $+2
loc_30C16:
mov r15, rax
jmp short loc_30C56
mov r15, rax
lea rdi, [rsp+arg_60]; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
jmp short loc_30C33
jmp short loc_30C30
jmp short loc_30C30
jmp short loc_30C49
loc_30C30:
mov r15, rax
loc_30C33:
lea rdi, [rsp+arg_8]
jmp short loc_30C51
mov r15, rax
lea rdi, [rsp+arg_60]; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
jmp short loc_30C4C
loc_30C49:
mov r15, rax
loc_30C4C:
lea rdi, [rsp+arg_38]
loc_30C51:
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
loc_30C56:
mov rdi, [rsp+0]
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()
lea rdi, [rbx+38h]
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
lea rdi, [rbx+28h]
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
lea rdi, [rbx+18h]
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
add rbx, 8
mov rdi, rbx
call _ZNSt12__weak_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__weak_count<(__gnu_cxx::_Lock_policy)2>::~__weak_count()
mov rdi, r15
call __Unwind_Resume
| long long minja::Value::Value(long long a1, unsigned __int8 *a2)
{
int v3; // edx
int v4; // ecx
int v5; // r8d
int v6; // r9d
int v7; // eax
int v8; // esi
int v9; // edx
int v10; // ecx
int v11; // r8d
int v12; // r9d
long long v13; // r12
long long v14; // rax
long long v15; // rax
int v16; // eax
int v17; // eax
long long v18; // r14
int v19; // edx
int v20; // ecx
int v21; // r8d
int v22; // r9d
int v23; // eax
char v24; // al
long long v25; // rax
int *v27; // rdi
int v28; // [rsp+0h] [rbp-E8h]
int v29; // [rsp+0h] [rbp-E8h]
long long v30; // [rsp+8h] [rbp-E0h] BYREF
int v31; // [rsp+10h] [rbp-D8h] BYREF
unsigned __int8 *v32; // [rsp+18h] [rbp-D0h] BYREF
long long v33; // [rsp+20h] [rbp-C8h]
long long v34; // [rsp+28h] [rbp-C0h]
long long v35; // [rsp+30h] [rbp-B8h]
long long v36; // [rsp+38h] [rbp-B0h] BYREF
int v37; // [rsp+40h] [rbp-A8h] BYREF
int v38; // [rsp+48h] [rbp-A0h]
int v39; // [rsp+50h] [rbp-98h]
int v40; // [rsp+58h] [rbp-90h] BYREF
long long v41; // [rsp+60h] [rbp-88h]
_BYTE v42[128]; // [rsp+68h] [rbp-80h] BYREF
*(_OWORD *)(a1 + 48) = 0LL;
*(_OWORD *)(a1 + 32) = 0LL;
*(_OWORD *)(a1 + 16) = 0LL;
*(_OWORD *)a1 = 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>::basic_json(a1 + 64);
v7 = *a2;
if ( v7 == 2 )
{
v29 = a1 + 64;
std::make_shared<std::vector<minja::Value>>(&v30, 0LL);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::cbegin(
&v32,
a2);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::cend(
&v36,
a2);
while ( ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_((long long)&v32) )
{
v17 = nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator*(&v32);
v18 = v30;
minja::Value::Value(
(unsigned int)v42,
v17,
v19,
v20,
v21,
v22,
v29,
v30,
v31,
(_DWORD)v32,
v33,
v34,
v35,
v36,
v37,
v38,
v39,
v40,
v41);
std::vector<minja::Value>::emplace_back<minja::Value>(v18, v42);
minja::Value::~Value((minja::Value *)v42);
v23 = *v32;
if ( v23 == 2 )
{
v34 += 16LL;
}
else if ( v23 == 1 )
{
v33 += 48LL;
}
else
{
++v35;
}
}
std::__shared_ptr<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2>::operator=(a1 + 16, &v30);
v27 = &v31;
}
else
{
if ( v7 != 1 )
{
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json(
(long long)&v40,
a2,
v3,
v4,
v5,
v6);
v24 = *(_BYTE *)(a1 + 64);
*(_BYTE *)(a1 + 64) = v40;
LOBYTE(v40) = v24;
v25 = *(_QWORD *)(a1 + 72);
*(_QWORD *)(a1 + 72) = v41;
v41 = v25;
return 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(&v40);
}
v28 = a1 + 64;
std::make_shared<nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>>(&v36);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::cbegin(
&v32,
a2);
while ( 1 )
{
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::cend(
v42,
a2);
if ( !ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_((long long)&v32) )
break;
v8 = nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator*(&v32);
minja::Value::Value(
(unsigned int)v42,
v8,
v9,
v10,
v11,
v12,
v28,
v30,
v31,
(_DWORD)v32,
v33,
v34,
v35,
v36,
v37,
v38,
v39,
v40,
v41);
v13 = v36;
v14 = nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::key(&v32);
v15 = ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEEixIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEERSF_OST_(
v13,
v14);
minja::Value::operator=(v15, v42);
minja::Value::~Value((minja::Value *)v42);
v16 = *v32;
if ( v16 == 2 )
{
v34 += 16LL;
}
else if ( v16 == 1 )
{
v33 += 48LL;
}
else
{
++v35;
}
}
std::__shared_ptr<nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>,(__gnu_cxx::_Lock_policy)2>::operator=(
a1 + 32,
&v36);
v27 = &v37;
}
return std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(v27);
}
| Value:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xb8
MOV R15,RSI
MOV RBX,RDI
LEA R14,[RDI + 0x40]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI + 0x30],XMM0
MOVUPS xmmword ptr [RDI + 0x20],XMM0
MOVUPS xmmword ptr [RDI + 0x10],XMM0
MOVUPS xmmword ptr [RDI],XMM0
MOV RDI,R14
XOR ESI,ESI
CALL 0x0012c9ae
MOVZX EAX,byte ptr [R15]
CMP EAX,0x2
JZ 0x00130b00
CMP EAX,0x1
JNZ 0x00130b9e
LAB_00130a51:
MOV qword ptr [RSP],R14
LEA RDI,[RSP + 0x38]
CALL 0x0013b9a1
LEA R14,[RBX + 0x20]
LEA R13,[RSP + 0x18]
MOV RDI,R13
MOV RSI,R15
CALL 0x001352dc
LEA RBP,[RSP + 0x68]
LAB_00130a78:
MOV RDI,RBP
MOV RSI,R15
CALL 0x0013533e
LAB_00130a83:
MOV RDI,R13
MOV RSI,RBP
CALL 0x0012f0a0
TEST AL,AL
JZ 0x00130be5
LAB_00130a96:
MOV RDI,R13
CALL 0x0012f0aa
MOV RDI,RBP
MOV RSI,RAX
CALL 0x00130a04
MOV R12,qword ptr [RSP + 0x38]
LAB_00130aae:
MOV RDI,R13
CALL 0x0013ddba
MOV RDI,R12
MOV RSI,RAX
CALL 0x0013dd62
MOV RDI,RAX
MOV RSI,RBP
CALL 0x0013de52
MOV RDI,RBP
CALL 0x001328fa
MOV RAX,qword ptr [RSP + 0x18]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x2
JZ 0x00130aee
CMP EAX,0x1
JNZ 0x00130af6
ADD qword ptr [RSP + 0x20],0x30
JMP 0x00130a78
LAB_00130aee:
ADD qword ptr [RSP + 0x28],0x10
JMP 0x00130a78
LAB_00130af6:
INC qword ptr [RSP + 0x30]
JMP 0x00130a78
LAB_00130b00:
MOV qword ptr [RSP],R14
LEA RDI,[RSP + 0x8]
CALL 0x0013dec5
LEA R12,[RBX + 0x10]
LEA R13,[RSP + 0x18]
MOV RDI,R13
MOV RSI,R15
CALL 0x001352dc
LEA RBP,[RSP + 0x38]
MOV RDI,RBP
MOV RSI,R15
CALL 0x0013533e
LEA R15,[RSP + 0x68]
LAB_00130b37:
MOV RDI,R13
MOV RSI,RBP
CALL 0x0012f0a0
TEST AL,AL
JZ 0x00130bd1
LAB_00130b4a:
MOV RDI,R13
CALL 0x0012f0aa
MOV R14,qword ptr [RSP + 0x8]
LAB_00130b57:
MOV RDI,R15
MOV RSI,RAX
CALL 0x00130a04
LAB_00130b62:
MOV RDI,R14
MOV RSI,R15
CALL 0x0013e358
MOV RDI,R15
CALL 0x001328fa
MOV RAX,qword ptr [RSP + 0x18]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x2
JZ 0x00130b8f
CMP EAX,0x1
JNZ 0x00130b97
ADD qword ptr [RSP + 0x20],0x30
JMP 0x00130b37
LAB_00130b8f:
ADD qword ptr [RSP + 0x28],0x10
JMP 0x00130b37
LAB_00130b97:
INC qword ptr [RSP + 0x30]
JMP 0x00130b37
LAB_00130b9e:
LEA RDI,[RSP + 0x58]
MOV RSI,R15
CALL 0x0012d362
LAB_00130bab:
MOV AL,byte ptr [RBX + 0x40]
LEA RDI,[RSP + 0x58]
MOV CL,byte ptr [RDI]
MOV byte ptr [RBX + 0x40],CL
MOV byte ptr [RDI],AL
MOV RAX,qword ptr [RBX + 0x48]
MOV RCX,qword ptr [RDI + 0x8]
MOV qword ptr [RBX + 0x48],RCX
MOV qword ptr [RDI + 0x8],RAX
CALL 0x0012cd5a
JMP 0x00130bfc
LAB_00130bd1:
LEA RSI,[RSP + 0x8]
MOV RDI,R12
CALL 0x0013d898
LEA RDI,[RSP + 0x10]
JMP 0x00130bf7
LAB_00130be5:
LEA RSI,[RSP + 0x38]
MOV RDI,R14
CALL 0x0013e170
LEA RDI,[RSP + 0x40]
LAB_00130bf7:
CALL 0x001341e0
LAB_00130bfc:
ADD RSP,0xb8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* minja::Value::Value(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const&) */
void __thiscall minja::Value::Value(Value *this,basic_json *param_1)
{
Value VVar1;
int8 uVar2;
vector<minja::Value,std::allocator<minja::Value>> *this_00;
char cVar3;
basic_json *pbVar4;
int8 uVar5;
Value *this_01;
__shared_count<(__gnu_cxx::_Lock_policy)2> *this_02;
vector<minja::Value,std::allocator<minja::Value>> *local_e0;
__shared_count<(__gnu_cxx::_Lock_policy)2> local_d8 [8];
char *local_d0;
long local_c8;
long local_c0;
long local_b8;
int8 local_b0;
__shared_count<(__gnu_cxx::_Lock_policy)2> local_a8 [24];
Value local_90 [8];
int8 local_88;
Value local_80 [80];
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::basic_json((_func_decltype_nullptr *)(this + 0x40));
if (*param_1 == (basic_json)0x2) {
/* try { // try from 00130b00 to 00130b0d has its CatchHandler @ 00130c14 */
std::make_shared<std::vector<minja::Value,std::allocator<minja::Value>>>();
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::cbegin();
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::cend();
/* try { // try from 00130b37 to 00130b41 has its CatchHandler @ 00130c30 */
while (cVar3 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_
((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_d0,&local_b0), cVar3 != '\0') {
/* try { // try from 00130b4a to 00130b51 has its CatchHandler @ 00130c2c */
pbVar4 = (basic_json *)
nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
::operator*((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_d0);
this_00 = local_e0;
/* try { // try from 00130b57 to 00130b61 has its CatchHandler @ 00130c2a */
Value(local_80,pbVar4);
/* try { // try from 00130b62 to 00130b6c has its CatchHandler @ 00130c1b */
std::vector<minja::Value,std::allocator<minja::Value>>::emplace_back<minja::Value>
(this_00,local_80);
~Value(local_80);
if (*local_d0 == '\x02') {
local_c0 = local_c0 + 0x10;
}
else if (*local_d0 == '\x01') {
local_c8 = local_c8 + 0x30;
}
else {
local_b8 = local_b8 + 1;
}
}
std::
__shared_ptr<std::vector<minja::Value,std::allocator<minja::Value>>,(__gnu_cxx::_Lock_policy)2>
::operator=((__shared_ptr<std::vector<minja::Value,std::allocator<minja::Value>>,(__gnu_cxx::_Lock_policy)2>
*)(this + 0x10),(__shared_ptr *)&local_e0);
this_02 = local_d8;
}
else {
if (*param_1 != (basic_json)0x1) {
/* try { // try from 00130b9e to 00130baa has its CatchHandler @ 00130c0e */
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::basic_json((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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_90,param_1);
VVar1 = this[0x40];
this[0x40] = local_90[0];
uVar2 = *(int8 *)(this + 0x48);
*(int8 *)(this + 0x48) = local_88;
local_90[0] = VVar1;
local_88 = uVar2;
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data((data *)local_90);
return;
}
/* try { // try from 00130a51 to 00130a5e has its CatchHandler @ 00130c16 */
std::
make_shared<nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>>>
();
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::cbegin();
while( true ) {
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::cend();
/* try { // try from 00130a83 to 00130a8d has its CatchHandler @ 00130c2e */
cVar3 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_
((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_d0,local_80);
if (cVar3 == '\0') break;
/* try { // try from 00130a96 to 00130aa8 has its CatchHandler @ 00130c49 */
pbVar4 = (basic_json *)
nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
::operator*((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_d0);
Value(local_80,pbVar4);
uVar2 = local_b0;
/* try { // try from 00130aae to 00130ac0 has its CatchHandler @ 00130c3a */
uVar5 = nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
::key((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_d0);
this_01 = (Value *)_ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEEixIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEERSF_OST_
(uVar2,uVar5);
operator=(this_01,local_80);
~Value(local_80);
if (*local_d0 == '\x02') {
local_c0 = local_c0 + 0x10;
}
else if (*local_d0 == '\x01') {
local_c8 = local_c8 + 0x30;
}
else {
local_b8 = local_b8 + 1;
}
}
std::
__shared_ptr<nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>>,(__gnu_cxx::_Lock_policy)2>
::operator=((__shared_ptr<nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>>,(__gnu_cxx::_Lock_policy)2>
*)(this + 0x20),(__shared_ptr *)&local_b0);
this_02 = local_a8;
}
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(this_02);
return;
}
| |
23,365 | minja::SetTemplateNode::SetTemplateNode(minja::Location const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::shared_ptr<minja::TemplateNode>&&) | monkey531[P]llama/common/./minja.hpp | SetTemplateNode(const Location & location, const std::string & name, std::shared_ptr<TemplateNode> && tv)
: TemplateNode(location), name(name), template_value(std::move(tv)) {} | O3 | cpp | minja::SetTemplateNode::SetTemplateNode(minja::Location const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::shared_ptr<minja::TemplateNode>&&):
pushq %r15
pushq %r14
pushq %rbx
movq %rcx, %r14
movq %rdi, %rbx
leaq 0x8cca8(%rip), %r15 # 0xeefe8
movq %r15, (%rdi)
movq (%rsi), %rax
movq %rax, 0x8(%rdi)
movq 0x8(%rsi), %rax
movq %rax, 0x10(%rdi)
testq %rax, %rax
je 0x6236c
movq 0x8dc42(%rip), %rcx # 0xeffa0
cmpb $0x0, (%rcx)
je 0x62368
incl 0x8(%rax)
jmp 0x6236c
lock
incl 0x8(%rax)
movq 0x10(%rsi), %rax
movq %rax, 0x18(%rbx)
leaq 0x8d06d(%rip), %rax # 0xef3e8
movq %rax, (%rbx)
leaq 0x20(%rbx), %rdi
leaq 0x30(%rbx), %rax
movq %rax, 0x20(%rbx)
movq (%rdx), %rsi
movq 0x8(%rdx), %rdx
addq %rsi, %rdx
callq 0x2bdf8
xorl %eax, %eax
movq %rax, 0x48(%rbx)
movups (%r14), %xmm0
movq %rax, 0x8(%r14)
movups %xmm0, 0x40(%rbx)
movq %rax, (%r14)
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq %r15, (%rbx)
movq 0x10(%rbx), %rdi
testq %rdi, %rdi
je 0x623c8
callq 0x2f80e
movq %r14, %rdi
callq 0x18b90
| _ZN5minja15SetTemplateNodeC2ERKNS_8LocationERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEOSt10shared_ptrINS_12TemplateNodeEE:
push r15
push r14
push rbx
mov r14, rcx
mov rbx, rdi
lea r15, off_EEFE8
mov [rdi], r15
mov rax, [rsi]
mov [rdi+8], rax
mov rax, [rsi+8]
mov [rdi+10h], rax
test rax, rax
jz short loc_6236C
mov rcx, cs:__libc_single_threaded_ptr
cmp byte ptr [rcx], 0
jz short loc_62368
inc dword ptr [rax+8]
jmp short loc_6236C
loc_62368:
lock inc dword ptr [rax+8]
loc_6236C:
mov rax, [rsi+10h]
mov [rbx+18h], rax
lea rax, off_EF3E8
mov [rbx], rax
lea rdi, [rbx+20h]
lea rax, [rbx+30h]
mov [rbx+20h], rax
mov rsi, [rdx]
mov rdx, [rdx+8]
add rdx, rsi
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
xor eax, eax
mov [rbx+48h], rax
movups xmm0, xmmword ptr [r14]
mov [r14+8], rax
movups xmmword ptr [rbx+40h], xmm0
mov [r14], rax
pop rbx
pop r14
pop r15
retn
mov r14, rax
mov [rbx], r15
mov rdi, [rbx+10h]
test rdi, rdi
jz short loc_623C8
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_623C8:
mov rdi, r14
call __Unwind_Resume
| long long minja::SetTemplateNode::SetTemplateNode(long long a1, _QWORD *a2, long long a3, __int128 *a4)
{
long long v5; // rax
long long result; // rax
__int128 v7; // xmm0
*(_QWORD *)a1 = &off_EEFE8;
*(_QWORD *)(a1 + 8) = *a2;
v5 = a2[1];
*(_QWORD *)(a1 + 16) = v5;
if ( v5 )
{
if ( _libc_single_threaded )
++*(_DWORD *)(v5 + 8);
else
_InterlockedIncrement((volatile signed __int32 *)(v5 + 8));
}
*(_QWORD *)(a1 + 24) = a2[2];
*(_QWORD *)a1 = &off_EF3E8;
*(_QWORD *)(a1 + 32) = a1 + 48;
std::string::_M_construct<char *>(a1 + 32, *(_BYTE **)a3, *(_QWORD *)a3 + *(_QWORD *)(a3 + 8));
result = 0LL;
*(_QWORD *)(a1 + 72) = 0LL;
v7 = *a4;
*((_QWORD *)a4 + 1) = 0LL;
*(_OWORD *)(a1 + 64) = v7;
*(_QWORD *)a4 = 0LL;
return result;
}
| SetTemplateNode:
PUSH R15
PUSH R14
PUSH RBX
MOV R14,RCX
MOV RBX,RDI
LEA R15,[0x1eefe8]
MOV qword ptr [RDI],R15
MOV RAX,qword ptr [RSI]
MOV qword ptr [RDI + 0x8],RAX
MOV RAX,qword ptr [RSI + 0x8]
MOV qword ptr [RDI + 0x10],RAX
TEST RAX,RAX
JZ 0x0016236c
MOV RCX,qword ptr [0x001effa0]
CMP byte ptr [RCX],0x0
JZ 0x00162368
INC dword ptr [RAX + 0x8]
JMP 0x0016236c
LAB_00162368:
INC.LOCK dword ptr [RAX + 0x8]
LAB_0016236c:
MOV RAX,qword ptr [RSI + 0x10]
MOV qword ptr [RBX + 0x18],RAX
LEA RAX,[0x1ef3e8]
MOV qword ptr [RBX],RAX
LEA RDI,[RBX + 0x20]
LEA RAX,[RBX + 0x30]
MOV qword ptr [RBX + 0x20],RAX
MOV RSI,qword ptr [RDX]
MOV RDX,qword ptr [RDX + 0x8]
ADD RDX,RSI
LAB_00162394:
CALL 0x0012bdf8
LAB_00162399:
XOR EAX,EAX
MOV qword ptr [RBX + 0x48],RAX
MOVUPS XMM0,xmmword ptr [R14]
MOV qword ptr [R14 + 0x8],RAX
MOVUPS xmmword ptr [RBX + 0x40],XMM0
MOV qword ptr [R14],RAX
POP RBX
POP R14
POP R15
RET
|
/* minja::SetTemplateNode::SetTemplateNode(minja::Location const&, std::__cxx11::string const&,
std::shared_ptr<minja::TemplateNode>&&) */
void __thiscall
minja::SetTemplateNode::SetTemplateNode
(SetTemplateNode *this,Location *param_1,string *param_2,shared_ptr *param_3)
{
long lVar1;
int8 uVar2;
*(int ***)this = &PTR___cxa_pure_virtual_001eefe8;
*(int8 *)(this + 8) = *(int8 *)param_1;
lVar1 = *(long *)(param_1 + 8);
*(long *)(this + 0x10) = lVar1;
if (lVar1 != 0) {
if (*PTR___libc_single_threaded_001effa0 == '\0') {
LOCK();
*(int *)(lVar1 + 8) = *(int *)(lVar1 + 8) + 1;
UNLOCK();
}
else {
*(int *)(lVar1 + 8) = *(int *)(lVar1 + 8) + 1;
}
}
*(int8 *)(this + 0x18) = *(int8 *)(param_1 + 0x10);
*(int ***)this = &PTR_do_render_001ef3e8;
*(SetTemplateNode **)(this + 0x20) = this + 0x30;
/* try { // try from 00162394 to 00162398 has its CatchHandler @ 001623b4 */
std::__cxx11::string::_M_construct<char*>
(this + 0x20,*(long *)param_2,*(long *)(param_2 + 8) + *(long *)param_2);
*(int8 *)(this + 0x48) = 0;
uVar2 = *(int8 *)(param_3 + 8);
*(int8 *)(param_3 + 8) = 0;
*(int8 *)(this + 0x40) = *(int8 *)param_3;
*(int8 *)(this + 0x48) = uVar2;
*(int8 *)param_3 = 0;
return;
}
| |
23,366 | minja::SequenceNode::do_render(std::__cxx11::basic_ostringstream<char, std::char_traits<char>, std::allocator<char>>&, std::shared_ptr<minja::Context> const&) const | monkey531[P]llama/common/minja.hpp | MacroNode(const Location & location, std::shared_ptr<VariableExpr> && n, Expression::Parameters && p, std::shared_ptr<TemplateNode> && b)
: TemplateNode(location), name(std::move(n)), params(std::move(p)), body(std::move(b)) {
for (size_t i = 0; i < params.size(); ++i) {
const auto & name = params[i].first;
if (!name.empty()) {
named_param_positions[name] = i;
}
}
} | O1 | cpp | minja::SequenceNode::do_render(std::__cxx11::basic_ostringstream<char, std::char_traits<char>, std::allocator<char>>&, std::shared_ptr<minja::Context> const&) const:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq 0x18(%rdi), %r15
movq 0x20(%rdi), %r12
cmpq %r12, %r15
setne %bl
je 0x78069
movq (%rsi), %r14
movq 0x8(%rsi), %r13
movq 0x8(%r15), %rdx
cmpq %r13, %rdx
jne 0x7805d
testq %rdx, %rdx
je 0x78069
movq (%r15), %rdi
movq %r14, %rsi
callq 0x186e0
testl %eax, %eax
je 0x78069
addq $0x70, %r15
cmpq %r12, %r15
setne %bl
jne 0x78040
andb $0x1, %bl
movl %ebx, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
| _ZN5minja14ArgumentsValue9has_namedERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push r15
push r14
push r13
push r12
push rbx
mov r15, [rdi+18h]
mov r12, [rdi+20h]
cmp r15, r12
setnz bl
jz short loc_78069
mov r14, [rsi]
mov r13, [rsi+8]
loc_78040:
mov rdx, [r15+8]
cmp rdx, r13
jnz short loc_7805D
test rdx, rdx
jz short loc_78069
mov rdi, [r15]
mov rsi, r14
call _bcmp
test eax, eax
jz short loc_78069
loc_7805D:
add r15, 70h ; 'p'
cmp r15, r12
setnz bl
jnz short loc_78040
loc_78069:
and bl, 1
mov eax, ebx
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| long long minja::ArgumentsValue::has_named(long long a1, long long *a2)
{
unsigned int v2; // ebx
_QWORD *v3; // r15
_QWORD *v4; // r12
long long v5; // r14
long long v6; // r13
long long v7; // rdx
v3 = *(_QWORD **)(a1 + 24);
v4 = *(_QWORD **)(a1 + 32);
LOBYTE(v2) = v3 != v4;
if ( v3 != v4 )
{
v5 = *a2;
v6 = a2[1];
do
{
v7 = v3[1];
if ( v7 == v6 && (!v7 || !(unsigned int)bcmp(*v3, v5, v7)) )
break;
v3 += 14;
LOBYTE(v2) = v3 != v4;
}
while ( v3 != v4 );
}
LOBYTE(v2) = v2 & 1;
return v2;
}
| has_named:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV R15,qword ptr [RDI + 0x18]
MOV R12,qword ptr [RDI + 0x20]
CMP R15,R12
SETNZ BL
JZ 0x00178069
MOV R14,qword ptr [RSI]
MOV R13,qword ptr [RSI + 0x8]
LAB_00178040:
MOV RDX,qword ptr [R15 + 0x8]
CMP RDX,R13
JNZ 0x0017805d
TEST RDX,RDX
JZ 0x00178069
MOV RDI,qword ptr [R15]
MOV RSI,R14
CALL 0x001186e0
TEST EAX,EAX
JZ 0x00178069
LAB_0017805d:
ADD R15,0x70
CMP R15,R12
SETNZ BL
JNZ 0x00178040
LAB_00178069:
AND BL,0x1
MOV EAX,EBX
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
/* minja::ArgumentsValue::has_named(std::__cxx11::string const&) */
ulong __thiscall minja::ArgumentsValue::has_named(ArgumentsValue *this,string *param_1)
{
int8 *puVar1;
void *__s2;
size_t sVar2;
size_t __n;
int iVar3;
int8 unaff_RBX;
int8 *puVar4;
bool bVar5;
puVar4 = *(int8 **)(this + 0x18);
puVar1 = *(int8 **)(this + 0x20);
bVar5 = puVar4 != puVar1;
if (bVar5) {
__s2 = *(void **)param_1;
sVar2 = *(size_t *)(param_1 + 8);
do {
__n = puVar4[1];
if (__n == sVar2) {
if (__n == 0) break;
iVar3 = bcmp((void *)*puVar4,__s2,__n);
if (iVar3 == 0) break;
}
puVar4 = puVar4 + 0xe;
bVar5 = puVar4 != puVar1;
} while (bVar5);
}
return CONCAT71((int7)((ulong)unaff_RBX >> 8),bVar5) & 0xffffffff;
}
| |
23,367 | open_cached_file | eloqsql/mysys/mf_cache.c | my_bool open_cached_file(IO_CACHE *cache, const char* dir, const char *prefix,
size_t cache_size, myf cache_myflags)
{
DBUG_ENTER("open_cached_file");
cache->dir= dir;
if (prefix)
{
DBUG_ASSERT(strlen(prefix) == 2);
memcpy(cache->prefix, prefix, 3);
}
else
cache->prefix[0]= 0;
cache->file_name=0;
cache->buffer=0; /* Mark that not open */
if (!init_io_cache(cache, -1, cache_size, WRITE_CACHE, 0L, 0,
MYF(cache_myflags | MY_NABP)))
{
DBUG_RETURN(0);
}
DBUG_RETURN(1);
} | O3 | c | open_cached_file:
movq %rsi, 0xc8(%rdi)
leaq 0xd0(%rdi), %rax
testq %rdx, %rdx
je 0x67dbb
movb 0x2(%rdx), %sil
movb %sil, 0x2(%rax)
movzwl (%rdx), %edx
movw %dx, (%rax)
jmp 0x67dbe
movb $0x0, (%rax)
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
xorl %eax, %eax
movq %rax, 0xc0(%rdi)
movq %rax, 0x20(%rdi)
orq $0x4, %r8
movq %r8, (%rsp)
movl $0xffffffff, %esi # imm = 0xFFFFFFFF
movq %rcx, %rdx
movl $0x2, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x53876
testl %eax, %eax
setne %al
addq $0x10, %rsp
popq %rbp
retq
| open_cached_file:
mov [rdi+0C8h], rsi
lea rax, [rdi+0D0h]
test rdx, rdx
jz short loc_67DBB
mov sil, [rdx+2]
mov [rax+2], sil
movzx edx, word ptr [rdx]
mov [rax], dx
jmp short loc_67DBE
loc_67DBB:
mov byte ptr [rax], 0
loc_67DBE:
push rbp
mov rbp, rsp
sub rsp, 10h
xor eax, eax
mov [rdi+0C0h], rax
mov [rdi+20h], rax
or r8, 4
mov [rsp+18h+var_18], r8
mov esi, 0FFFFFFFFh
mov rdx, rcx
mov ecx, 2
xor r8d, r8d
xor r9d, r9d
call init_io_cache
test eax, eax
setnz al
add rsp, 10h
pop rbp
retn
| bool open_cached_file(long long a1, long long a2, long long a3, unsigned long long a4, long long a5)
{
_WORD *v5; // rax
*(_QWORD *)(a1 + 200) = a2;
v5 = (_WORD *)(a1 + 208);
if ( a3 )
{
*(_BYTE *)(a1 + 210) = *(_BYTE *)(a3 + 2);
*v5 = *(_WORD *)a3;
}
else
{
*(_BYTE *)v5 = 0;
}
*(_QWORD *)(a1 + 192) = 0LL;
*(_QWORD *)(a1 + 32) = 0LL;
return (unsigned int)init_io_cache(a1, 0xFFFFFFFFLL, a4, 2, 0LL, 0, a5 | 4) != 0;
}
| open_cached_file:
MOV qword ptr [RDI + 0xc8],RSI
LEA RAX,[RDI + 0xd0]
TEST RDX,RDX
JZ 0x00167dbb
MOV SIL,byte ptr [RDX + 0x2]
MOV byte ptr [RAX + 0x2],SIL
MOVZX EDX,word ptr [RDX]
MOV word ptr [RAX],DX
JMP 0x00167dbe
LAB_00167dbb:
MOV byte ptr [RAX],0x0
LAB_00167dbe:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
XOR EAX,EAX
MOV qword ptr [RDI + 0xc0],RAX
MOV qword ptr [RDI + 0x20],RAX
OR R8,0x4
MOV qword ptr [RSP],R8
MOV ESI,0xffffffff
MOV RDX,RCX
MOV ECX,0x2
XOR R8D,R8D
XOR R9D,R9D
CALL 0x00153876
TEST EAX,EAX
SETNZ AL
ADD RSP,0x10
POP RBP
RET
|
bool open_cached_file(long param_1,int8 param_2,int2 *param_3,int8 param_4,
ulong param_5)
{
int iVar1;
*(int8 *)(param_1 + 200) = param_2;
if (param_3 == (int2 *)0x0) {
*(int1 *)(param_1 + 0xd0) = 0;
}
else {
*(int1 *)(param_1 + 0xd2) = *(int1 *)(param_3 + 1);
*(int2 *)(param_1 + 0xd0) = *param_3;
}
*(int8 *)(param_1 + 0xc0) = 0;
*(int8 *)(param_1 + 0x20) = 0;
iVar1 = init_io_cache(param_1,0xffffffff,param_4,2,0,0,param_5 | 4);
return iVar1 != 0;
}
| |
23,368 | ma_apply_redo_bitmap_new_page | eloqsql/storage/maria/ma_bitmap.c | my_bool _ma_apply_redo_bitmap_new_page(MARIA_HA *info,
LSN lsn __attribute__ ((unused)),
const uchar *header)
{
MARIA_SHARE *share= info->s;
MARIA_FILE_BITMAP *bitmap= &share->bitmap;
my_bool error;
pgcache_page_no_t from, to, min_from;
DBUG_ENTER("_ma_apply_redo_bitmap_new_page");
from= page_korr(header);
to= page_korr(header + PAGE_STORE_SIZE);
DBUG_PRINT("info", ("from: %lu to: %lu", (ulong)from, (ulong)to));
if ((from > to) ||
(from % bitmap->pages_covered) != 0 ||
(to % bitmap->pages_covered) != 0)
{
error= TRUE; /* corrupted log record */
goto err;
}
min_from= (share->state.state.data_file_length / bitmap->block_size - 1) /
bitmap->pages_covered + 1;
min_from*= bitmap->pages_covered;
if (from < min_from)
{
DBUG_PRINT("info", ("overwrite bitmap pages from %lu", (ulong)min_from));
/*
We have to overwrite. It could be that there was a bitmap page in
memory, covering a data page which went to disk, then crash: the
bitmap page is now full of zeros and is ==min_from, we have to overwrite
it with correct checksum.
*/
}
share->state.changed|= STATE_CHANGED;
bzero(info->buff, bitmap->block_size);
if (!(error=
_ma_bitmap_create_missing_into_pagecache(share, bitmap, from, to,
info->buff)))
share->state.state.data_file_length= (to + 1) * bitmap->block_size;
err:
DBUG_RETURN(error);
} | O0 | c | ma_apply_redo_bitmap_new_page:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
addq $0xa10, %rax # imm = 0xA10
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rdi
callq 0x3d8c0
movq %rax, -0x38(%rbp)
movq -0x18(%rbp), %rdi
addq $0x5, %rdi
callq 0x3d8c0
movq %rax, -0x40(%rbp)
jmp 0x3dd7d
movq -0x38(%rbp), %rax
cmpq -0x40(%rbp), %rax
ja 0x3ddb5
movq -0x38(%rbp), %rax
movq -0x28(%rbp), %rcx
xorl %edx, %edx
divq 0x138(%rcx)
cmpq $0x0, %rdx
jne 0x3ddb5
movq -0x40(%rbp), %rax
movq -0x28(%rbp), %rcx
xorl %edx, %edx
divq 0x138(%rcx)
cmpq $0x0, %rdx
je 0x3ddbe
movb $0x1, -0x29(%rbp)
jmp 0x3de8a
movq -0x20(%rbp), %rax
movq 0x40(%rax), %rax
movq -0x28(%rbp), %rcx
movl 0x134(%rcx), %ecx
xorl %edx, %edx
divq %rcx
subq $0x1, %rax
movq -0x28(%rbp), %rcx
xorl %edx, %edx
divq 0x138(%rcx)
addq $0x1, %rax
movq %rax, -0x48(%rbp)
movq -0x28(%rbp), %rax
movq 0x138(%rax), %rax
imulq -0x48(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x38(%rbp), %rax
cmpq -0x48(%rbp), %rax
jae 0x3de12
jmp 0x3de0e
jmp 0x3de10
jmp 0x3de12
movq -0x20(%rbp), %rax
movl 0x170(%rax), %ecx
orl $0x1, %ecx
movl %ecx, 0x170(%rax)
movq -0x8(%rbp), %rax
movq 0x378(%rax), %rdi
movq -0x28(%rbp), %rax
movl 0x134(%rax), %eax
movl %eax, %edx
xorl %esi, %esi
callq 0x2a2f0
movq -0x20(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x38(%rbp), %rdx
movq -0x40(%rbp), %rcx
movq -0x8(%rbp), %rax
movq 0x378(%rax), %r8
callq 0x3dea0
movb %al, -0x29(%rbp)
cmpb $0x0, %al
jne 0x3de88
movq -0x40(%rbp), %rcx
addq $0x1, %rcx
movq -0x28(%rbp), %rax
movl 0x134(%rax), %eax
imulq %rax, %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x40(%rax)
jmp 0x3de8a
jmp 0x3de8c
movb -0x29(%rbp), %al
movb %al, -0x49(%rbp)
movb -0x49(%rbp), %al
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| _ma_apply_redo_bitmap_new_page:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
add rax, 0A10h
mov [rbp+var_28], rax
mov rdi, [rbp+var_18]
call uint5korr_0
mov [rbp+var_38], rax
mov rdi, [rbp+var_18]
add rdi, 5
call uint5korr_0
mov [rbp+var_40], rax
jmp short $+2
loc_3DD7D:
mov rax, [rbp+var_38]
cmp rax, [rbp+var_40]
ja short loc_3DDB5
mov rax, [rbp+var_38]
mov rcx, [rbp+var_28]
xor edx, edx
div qword ptr [rcx+138h]
cmp rdx, 0
jnz short loc_3DDB5
mov rax, [rbp+var_40]
mov rcx, [rbp+var_28]
xor edx, edx
div qword ptr [rcx+138h]
cmp rdx, 0
jz short loc_3DDBE
loc_3DDB5:
mov [rbp+var_29], 1
jmp loc_3DE8A
loc_3DDBE:
mov rax, [rbp+var_20]
mov rax, [rax+40h]
mov rcx, [rbp+var_28]
mov ecx, [rcx+134h]
xor edx, edx
div rcx
sub rax, 1
mov rcx, [rbp+var_28]
xor edx, edx
div qword ptr [rcx+138h]
add rax, 1
mov [rbp+var_48], rax
mov rax, [rbp+var_28]
mov rax, [rax+138h]
imul rax, [rbp+var_48]
mov [rbp+var_48], rax
mov rax, [rbp+var_38]
cmp rax, [rbp+var_48]
jnb short loc_3DE12
jmp short $+2
loc_3DE0E:
jmp short $+2
loc_3DE10:
jmp short $+2
loc_3DE12:
mov rax, [rbp+var_20]
mov ecx, [rax+170h]
or ecx, 1
mov [rax+170h], ecx
mov rax, [rbp+var_8]
mov rdi, [rax+378h]
mov rax, [rbp+var_28]
mov eax, [rax+134h]
mov edx, eax
xor esi, esi
call _memset
mov rdi, [rbp+var_20]
mov rsi, [rbp+var_28]
mov rdx, [rbp+var_38]
mov rcx, [rbp+var_40]
mov rax, [rbp+var_8]
mov r8, [rax+378h]
call _ma_bitmap_create_missing_into_pagecache
mov [rbp+var_29], al
cmp al, 0
jnz short loc_3DE88
mov rcx, [rbp+var_40]
add rcx, 1
mov rax, [rbp+var_28]
mov eax, [rax+134h]
imul rcx, rax
mov rax, [rbp+var_20]
mov [rax+40h], rcx
loc_3DE88:
jmp short $+2
loc_3DE8A:
jmp short $+2
loc_3DE8C:
mov al, [rbp+var_29]
mov [rbp+var_49], al
mov al, [rbp+var_49]
add rsp, 50h
pop rbp
retn
| char ma_apply_redo_bitmap_new_page(long long *a1, long long a2, unsigned int *a3)
{
unsigned long long v4; // [rsp+10h] [rbp-40h]
unsigned long long v5; // [rsp+18h] [rbp-38h]
char missing_into_pagecache; // [rsp+27h] [rbp-29h]
long long v7; // [rsp+28h] [rbp-28h]
long long v8; // [rsp+30h] [rbp-20h]
v8 = *a1;
v7 = *a1 + 2576;
v5 = uint5korr_0(a3);
v4 = uint5korr_0((unsigned int *)((char *)a3 + 5));
if ( v5 > v4 || v5 % *(_QWORD *)(v7 + 312) || v4 % *(_QWORD *)(v7 + 312) )
return 1;
*(_DWORD *)(v8 + 368) |= 1u;
memset(a1[111], 0LL, *(unsigned int *)(v7 + 308));
missing_into_pagecache = ma_bitmap_create_missing_into_pagecache(v8, v7, v5, v4, a1[111]);
if ( !missing_into_pagecache )
*(_QWORD *)(v8 + 64) = *(unsigned int *)(v7 + 308) * (v4 + 1);
return missing_into_pagecache;
}
| _ma_apply_redo_bitmap_new_page:
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 RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0xa10
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x0013d8c0
MOV qword ptr [RBP + -0x38],RAX
MOV RDI,qword ptr [RBP + -0x18]
ADD RDI,0x5
CALL 0x0013d8c0
MOV qword ptr [RBP + -0x40],RAX
JMP 0x0013dd7d
LAB_0013dd7d:
MOV RAX,qword ptr [RBP + -0x38]
CMP RAX,qword ptr [RBP + -0x40]
JA 0x0013ddb5
MOV RAX,qword ptr [RBP + -0x38]
MOV RCX,qword ptr [RBP + -0x28]
XOR EDX,EDX
DIV qword ptr [RCX + 0x138]
CMP RDX,0x0
JNZ 0x0013ddb5
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RBP + -0x28]
XOR EDX,EDX
DIV qword ptr [RCX + 0x138]
CMP RDX,0x0
JZ 0x0013ddbe
LAB_0013ddb5:
MOV byte ptr [RBP + -0x29],0x1
JMP 0x0013de8a
LAB_0013ddbe:
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x40]
MOV RCX,qword ptr [RBP + -0x28]
MOV ECX,dword ptr [RCX + 0x134]
XOR EDX,EDX
DIV RCX
SUB RAX,0x1
MOV RCX,qword ptr [RBP + -0x28]
XOR EDX,EDX
DIV qword ptr [RCX + 0x138]
ADD RAX,0x1
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x138]
IMUL RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x38]
CMP RAX,qword ptr [RBP + -0x48]
JNC 0x0013de12
JMP 0x0013de0e
LAB_0013de0e:
JMP 0x0013de10
LAB_0013de10:
JMP 0x0013de12
LAB_0013de12:
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RAX + 0x170]
OR ECX,0x1
MOV dword ptr [RAX + 0x170],ECX
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX + 0x378]
MOV RAX,qword ptr [RBP + -0x28]
MOV EAX,dword ptr [RAX + 0x134]
MOV EDX,EAX
XOR ESI,ESI
CALL 0x0012a2f0
MOV RDI,qword ptr [RBP + -0x20]
MOV RSI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x38]
MOV RCX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RBP + -0x8]
MOV R8,qword ptr [RAX + 0x378]
CALL 0x0013dea0
MOV byte ptr [RBP + -0x29],AL
CMP AL,0x0
JNZ 0x0013de88
MOV RCX,qword ptr [RBP + -0x40]
ADD RCX,0x1
MOV RAX,qword ptr [RBP + -0x28]
MOV EAX,dword ptr [RAX + 0x134]
IMUL RCX,RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX + 0x40],RCX
LAB_0013de88:
JMP 0x0013de8a
LAB_0013de8a:
JMP 0x0013de8c
LAB_0013de8c:
MOV AL,byte ptr [RBP + -0x29]
MOV byte ptr [RBP + -0x49],AL
MOV AL,byte ptr [RBP + -0x49]
ADD RSP,0x50
POP RBP
RET
|
char _ma_apply_redo_bitmap_new_page(long *param_1,int8 param_2,long param_3)
{
long lVar1;
ulong uVar2;
ulong uVar3;
char local_31;
lVar1 = *param_1;
uVar2 = uint5korr(param_3);
uVar3 = uint5korr(param_3 + 5);
if (((uVar3 < uVar2) || (uVar2 % *(ulong *)(lVar1 + 0xb48) != 0)) ||
(uVar3 % *(ulong *)(lVar1 + 0xb48) != 0)) {
local_31 = '\x01';
}
else {
*(uint *)(lVar1 + 0x170) = *(uint *)(lVar1 + 0x170) | 1;
memset((void *)param_1[0x6f],0,(ulong)*(uint *)(lVar1 + 0xb44));
local_31 = _ma_bitmap_create_missing_into_pagecache
(lVar1,lVar1 + 0xa10,uVar2,uVar3,param_1[0x6f]);
if (local_31 == '\0') {
*(ulong *)(lVar1 + 0x40) = (uVar3 + 1) * (ulong)*(uint *)(lVar1 + 0xb44);
}
}
return local_31;
}
| |
23,369 | ma_apply_redo_bitmap_new_page | eloqsql/storage/maria/ma_bitmap.c | my_bool _ma_apply_redo_bitmap_new_page(MARIA_HA *info,
LSN lsn __attribute__ ((unused)),
const uchar *header)
{
MARIA_SHARE *share= info->s;
MARIA_FILE_BITMAP *bitmap= &share->bitmap;
my_bool error;
pgcache_page_no_t from, to, min_from;
DBUG_ENTER("_ma_apply_redo_bitmap_new_page");
from= page_korr(header);
to= page_korr(header + PAGE_STORE_SIZE);
DBUG_PRINT("info", ("from: %lu to: %lu", (ulong)from, (ulong)to));
if ((from > to) ||
(from % bitmap->pages_covered) != 0 ||
(to % bitmap->pages_covered) != 0)
{
error= TRUE; /* corrupted log record */
goto err;
}
min_from= (share->state.state.data_file_length / bitmap->block_size - 1) /
bitmap->pages_covered + 1;
min_from*= bitmap->pages_covered;
if (from < min_from)
{
DBUG_PRINT("info", ("overwrite bitmap pages from %lu", (ulong)min_from));
/*
We have to overwrite. It could be that there was a bitmap page in
memory, covering a data page which went to disk, then crash: the
bitmap page is now full of zeros and is ==min_from, we have to overwrite
it with correct checksum.
*/
}
share->state.changed|= STATE_CHANGED;
bzero(info->buff, bitmap->block_size);
if (!(error=
_ma_bitmap_create_missing_into_pagecache(share, bitmap, from, to,
info->buff)))
share->state.state.data_file_length= (to + 1) * bitmap->block_size;
err:
DBUG_RETURN(error);
} | O3 | c | ma_apply_redo_bitmap_new_page:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl (%rdx), %eax
movl 0x5(%rdx), %ecx
movzbl 0x4(%rdx), %r12d
shlq $0x20, %r12
orq %rax, %r12
movzbl 0x9(%rdx), %r14d
shlq $0x20, %r14
orq %rcx, %r14
movb $0x1, %bl
cmpq %r14, %r12
ja 0x3ef4d
movq %rdi, %r13
movq (%rdi), %r15
movq 0xb48(%r15), %rcx
movq %r12, %rax
xorl %edx, %edx
divq %rcx
testq %rdx, %rdx
jne 0x3ef4d
movq %r14, %rax
xorl %edx, %edx
divq %rcx
testq %rdx, %rdx
jne 0x3ef4d
orb $0x1, 0x170(%r15)
leaq 0xa10(%r15), %rax
movq %rax, -0x30(%rbp)
movq 0x378(%r13), %rdi
movl 0xb44(%r15), %edx
xorl %esi, %esi
callq 0x2a2e0
movq 0x378(%r13), %r8
movq %r15, %rdi
movq -0x30(%rbp), %rsi
movq %r12, %rdx
movq %r14, %rcx
callq 0x3ef5e
testb %al, %al
jne 0x3ef4d
incq %r14
movl 0xb44(%r15), %eax
imulq %r14, %rax
movq %rax, 0x40(%r15)
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| _ma_apply_redo_bitmap_new_page:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov eax, [rdx]
mov ecx, [rdx+5]
movzx r12d, byte ptr [rdx+4]
shl r12, 20h
or r12, rax
movzx r14d, byte ptr [rdx+9]
shl r14, 20h
or r14, rcx
mov bl, 1
cmp r12, r14
ja loc_3EF4D
mov r13, rdi
mov r15, [rdi]
mov rcx, [r15+0B48h]
mov rax, r12
xor edx, edx
div rcx
test rdx, rdx
jnz short loc_3EF4D
mov rax, r14
xor edx, edx
div rcx
test rdx, rdx
jnz short loc_3EF4D
or byte ptr [r15+170h], 1
lea rax, [r15+0A10h]
mov [rbp+var_30], rax
mov rdi, [r13+378h]
mov edx, [r15+0B44h]
xor esi, esi
call _memset
mov r8, [r13+378h]
mov rdi, r15
mov rsi, [rbp+var_30]
mov rdx, r12
mov rcx, r14
call _ma_bitmap_create_missing_into_pagecache
test al, al
jnz short loc_3EF4D
inc r14
mov eax, [r15+0B44h]
imul rax, r14
mov [r15+40h], rax
xor ebx, ebx
loc_3EF4D:
mov eax, ebx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long ma_apply_redo_bitmap_new_page(_QWORD *a1, long long a2, unsigned int *a3)
{
unsigned int v3; // ebx
unsigned long long v4; // r12
unsigned long long v5; // r14
long long v6; // r15
unsigned long long v7; // rcx
v4 = *a3 | ((unsigned long long)*((unsigned __int8 *)a3 + 4) << 32);
v5 = *(unsigned int *)((char *)a3 + 5) | ((unsigned long long)*((unsigned __int8 *)a3 + 9) << 32);
LOBYTE(v3) = 1;
if ( v4 <= v5 )
{
v6 = *a1;
v7 = *(_QWORD *)(*a1 + 2888LL);
if ( !(v4 % v7) && !(v5 % v7) )
{
*(_BYTE *)(v6 + 368) |= 1u;
memset(a1[111], 0LL, *(unsigned int *)(v6 + 2884));
if ( !(unsigned __int8)ma_bitmap_create_missing_into_pagecache(v6, v6 + 2576, v4, v5, a1[111]) )
{
*(_QWORD *)(v6 + 64) = (v5 + 1) * *(unsigned int *)(v6 + 2884);
return 0;
}
}
}
return v3;
}
| _ma_apply_redo_bitmap_new_page:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV EAX,dword ptr [RDX]
MOV ECX,dword ptr [RDX + 0x5]
MOVZX R12D,byte ptr [RDX + 0x4]
SHL R12,0x20
OR R12,RAX
MOVZX R14D,byte ptr [RDX + 0x9]
SHL R14,0x20
OR R14,RCX
MOV BL,0x1
CMP R12,R14
JA 0x0013ef4d
MOV R13,RDI
MOV R15,qword ptr [RDI]
MOV RCX,qword ptr [R15 + 0xb48]
MOV RAX,R12
XOR EDX,EDX
DIV RCX
TEST RDX,RDX
JNZ 0x0013ef4d
MOV RAX,R14
XOR EDX,EDX
DIV RCX
TEST RDX,RDX
JNZ 0x0013ef4d
OR byte ptr [R15 + 0x170],0x1
LEA RAX,[R15 + 0xa10]
MOV qword ptr [RBP + -0x30],RAX
MOV RDI,qword ptr [R13 + 0x378]
MOV EDX,dword ptr [R15 + 0xb44]
XOR ESI,ESI
CALL 0x0012a2e0
MOV R8,qword ptr [R13 + 0x378]
MOV RDI,R15
MOV RSI,qword ptr [RBP + -0x30]
MOV RDX,R12
MOV RCX,R14
CALL 0x0013ef5e
TEST AL,AL
JNZ 0x0013ef4d
INC R14
MOV EAX,dword ptr [R15 + 0xb44]
IMUL RAX,R14
MOV qword ptr [R15 + 0x40],RAX
XOR EBX,EBX
LAB_0013ef4d:
MOV EAX,EBX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
ulong _ma_apply_redo_bitmap_new_page(long *param_1,int8 param_2,uint5 *param_3)
{
long lVar1;
char cVar2;
int8 unaff_RBX;
ulong uVar3;
ulong uVar4;
ulong uVar5;
uVar4 = (ulong)*param_3;
uVar5 = (ulong)*(uint5 *)((long)param_3 + 5);
uVar3 = CONCAT71((int7)((ulong)unaff_RBX >> 8),1);
if (uVar4 <= uVar5) {
lVar1 = *param_1;
if ((uVar4 % *(ulong *)(lVar1 + 0xb48) == 0) && (uVar5 % *(ulong *)(lVar1 + 0xb48) == 0)) {
*(byte *)(lVar1 + 0x170) = *(byte *)(lVar1 + 0x170) | 1;
memset((void *)param_1[0x6f],0,(ulong)*(uint *)(lVar1 + 0xb44));
cVar2 = _ma_bitmap_create_missing_into_pagecache
(lVar1,lVar1 + 0xa10,uVar4,uVar5,param_1[0x6f]);
if (cVar2 == '\0') {
*(ulong *)(lVar1 + 0x40) = (ulong)*(uint *)(lVar1 + 0xb44) * (uVar5 + 1);
uVar3 = 0;
}
}
}
return uVar3 & 0xffffffff;
}
| |
23,370 | 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;
} | O3 | c | my_copy_8bit:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %rbx
movq 0x10(%rbp), %r15
cmpq %rdx, %r8
cmovbq %r8, %rbx
cmpq %r9, %rbx
cmovaeq %r9, %rbx
testq %rbx, %rbx
je 0x39a59
movq %rsi, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x24530
addq %rbx, %r14
movq %r14, (%r15)
movq $0x0, 0x8(%r15)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| my_copy_8bit:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov r14, rcx
mov rbx, rdx
mov r15, [rbp+arg_0]
cmp r8, rdx
cmovb rbx, r8
cmp rbx, r9
cmovnb rbx, r9
test rbx, rbx
jz short loc_39A59
mov rdi, rsi
mov rsi, r14
mov rdx, rbx
call _memmove
loc_39A59:
add r14, rbx
mov [r15], r14
mov qword ptr [r15+8], 0
mov rax, rbx
add rsp, 8
pop rbx
pop r14
pop r15
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; // rbx
v8 = a3;
if ( a5 < a3 )
v8 = a5;
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
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RCX
MOV RBX,RDX
MOV R15,qword ptr [RBP + 0x10]
CMP R8,RDX
CMOVC RBX,R8
CMP RBX,R9
CMOVNC RBX,R9
TEST RBX,RBX
JZ 0x00139a59
MOV RDI,RSI
MOV RSI,R14
MOV RDX,RBX
CALL 0x00124530
LAB_00139a59:
ADD R14,RBX
MOV qword ptr [R15],R14
MOV qword ptr [R15 + 0x8],0x0
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R14
POP R15
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)
{
if (param_5 < param_3) {
param_3 = param_5;
}
if (param_6 <= param_3) {
param_3 = param_6;
}
if (param_3 != 0) {
memmove(param_2,param_4,param_3);
}
*param_7 = (long)param_4 + param_3;
param_7[1] = 0;
return param_3;
}
| |
23,371 | ftb_find_relevance_parse | eloqsql/storage/myisam/ft_boolean_search.c | static int ftb_find_relevance_parse(MYSQL_FTPARSER_PARAM *param,
const char *doc, int len)
{
MY_FTB_FIND_PARAM *ftb_param= param->mysql_ftparam;
FT_INFO *ftb= ftb_param->ftb;
uchar *end= (uchar*) doc + len;
FT_WORD w;
while (ft_simple_get_word(ftb->charset, (uchar**) &doc, end, &w, TRUE))
param->mysql_add_word(param, (char*) w.pos, (int)w.len, 0);
return(0);
} | O0 | c | ftb_find_relevance_parse:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movq -0x28(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x30(%rbp), %rdx
leaq -0x10(%rbp), %rsi
leaq -0x48(%rbp), %rcx
movl $0x1, %r8d
callq 0xa2340
cmpb $0x0, %al
je 0x9f448
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x8(%rbp), %rdi
movq -0x48(%rbp), %rsi
movq -0x38(%rbp), %rcx
movl %ecx, %edx
xorl %ecx, %ecx
callq *%rax
jmp 0x9f409
xorl %eax, %eax
addq $0x50, %rsp
popq %rbp
retq
| ftb_find_relevance_parse:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
mov rax, [rbp+var_8]
mov rax, [rax+18h]
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
mov rax, [rax]
mov [rbp+var_28], rax
mov rax, [rbp+var_10]
movsxd rcx, [rbp+var_14]
add rax, rcx
mov [rbp+var_30], rax
loc_9F409:
mov rax, [rbp+var_28]
mov rdi, [rax+10h]
mov rdx, [rbp+var_30]
lea rsi, [rbp+var_10]
lea rcx, [rbp+var_48]
mov r8d, 1
call ft_simple_get_word
cmp al, 0
jz short loc_9F448
mov rax, [rbp+var_8]
mov rax, [rax+8]
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_48]
mov rcx, [rbp+var_38]
mov edx, ecx
xor ecx, ecx
call rax
jmp short loc_9F409
loc_9F448:
xor eax, eax
add rsp, 50h
pop rbp
retn
| long long ftb_find_relevance_parse(long long a1, long long a2, int a3)
{
long long v4; // [rsp+8h] [rbp-48h] BYREF
long long v5; // [rsp+18h] [rbp-38h]
long long v6; // [rsp+20h] [rbp-30h]
long long v7; // [rsp+28h] [rbp-28h]
long long *v8; // [rsp+30h] [rbp-20h]
int v9; // [rsp+3Ch] [rbp-14h]
long long v10; // [rsp+40h] [rbp-10h] BYREF
long long v11; // [rsp+48h] [rbp-8h]
v11 = a1;
v10 = a2;
v9 = a3;
v8 = *(long long **)(a1 + 24);
v7 = *v8;
v6 = a3 + a2;
while ( (unsigned __int8)ft_simple_get_word(*(_QWORD *)(v7 + 16), &v10, v6, &v4, 1LL) )
(*(void ( **)(long long, long long, _QWORD, _QWORD))(v11 + 8))(v11, v4, (unsigned int)v5, 0LL);
return 0LL;
}
| ftb_find_relevance_parse:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,dword ptr [RBP + -0x14]
ADD RAX,RCX
MOV qword ptr [RBP + -0x30],RAX
LAB_0019f409:
MOV RAX,qword ptr [RBP + -0x28]
MOV RDI,qword ptr [RAX + 0x10]
MOV RDX,qword ptr [RBP + -0x30]
LEA RSI,[RBP + -0x10]
LEA RCX,[RBP + -0x48]
MOV R8D,0x1
CALL 0x001a2340
CMP AL,0x0
JZ 0x0019f448
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x38]
MOV EDX,ECX
XOR ECX,ECX
CALL RAX
JMP 0x0019f409
LAB_0019f448:
XOR EAX,EAX
ADD RSP,0x50
POP RBP
RET
|
int8 ftb_find_relevance_parse(long param_1,long param_2,int param_3)
{
char cVar1;
int8 local_50 [2];
ulong local_40;
long local_38;
long local_30;
long *local_28;
int local_1c;
long local_18;
long local_10;
local_28 = *(long **)(param_1 + 0x18);
local_30 = *local_28;
local_38 = param_2 + param_3;
local_1c = param_3;
local_18 = param_2;
local_10 = param_1;
while( true ) {
cVar1 = ft_simple_get_word(*(int8 *)(local_30 + 0x10),&local_18,local_38,local_50,1);
if (cVar1 == '\0') break;
(**(code **)(local_10 + 8))(local_10,local_50[0],local_40 & 0xffffffff,0);
}
return 0;
}
| |
23,372 | void fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>, fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points) | aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h | FMT_CONSTEXPR void for_each_codepoint(string_view s, F f) {
auto decode = [f](const char* buf_ptr, const char* ptr) {
auto cp = uint32_t();
auto error = 0;
auto end = utf8_decode(buf_ptr, &cp, &error);
bool result = f(error ? invalid_code_point : cp,
string_view(ptr, error ? 1 : to_unsigned(end - buf_ptr)));
return result ? (error ? buf_ptr + 1 : end) : nullptr;
};
auto p = s.data();
const size_t block_size = 4; // utf8_decode always reads blocks of 4 chars.
if (s.size() >= block_size) {
for (auto end = p + s.size() - block_size + 1; p < end;) {
p = decode(p, p);
if (!p) return;
}
}
if (auto num_chars_left = s.data() + s.size() - p) {
char buf[2 * block_size - 1] = {};
copy_str<char>(p, p + num_chars_left, buf);
const char* buf_ptr = buf;
do {
auto end = decode(buf_ptr, p);
if (!end) return;
p += end - buf_ptr;
buf_ptr = end;
} while (buf_ptr - buf < num_chars_left);
}
} | O0 | c | void fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>, fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points):
subq $0x68, %rsp
movq %rdi, 0x58(%rsp)
movq %rsi, 0x60(%rsp)
movq %rdx, 0x50(%rsp)
movq 0x50(%rsp), %rax
movq %rax, 0x48(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x9f410
movq %rax, 0x40(%rsp)
movq $0x4, 0x38(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x9f3d0
cmpq $0x4, %rax
jb 0xc7517
movq 0x40(%rsp), %rax
movq %rax, 0x8(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x9f3d0
movq %rax, %rcx
movq 0x8(%rsp), %rax
addq %rcx, %rax
addq $-0x4, %rax
addq $0x1, %rax
movq %rax, 0x30(%rsp)
movq 0x40(%rsp), %rax
cmpq 0x30(%rsp), %rax
jae 0xc7515
movq 0x40(%rsp), %rsi
movq 0x40(%rsp), %rdx
leaq 0x48(%rsp), %rdi
callq 0xc75f0
movq %rax, 0x40(%rsp)
cmpq $0x0, 0x40(%rsp)
jne 0xc7513
jmp 0xc75e0
jmp 0xc74e1
jmp 0xc7517
leaq 0x58(%rsp), %rdi
callq 0x9f410
movq %rax, (%rsp)
leaq 0x58(%rsp), %rdi
callq 0x9f3d0
movq %rax, %rcx
movq (%rsp), %rax
addq %rcx, %rax
movq 0x40(%rsp), %rcx
subq %rcx, %rax
movq %rax, 0x28(%rsp)
cmpq $0x0, 0x28(%rsp)
je 0xc75e0
leaq 0x21(%rsp), %rdi
xorl %esi, %esi
movl $0x7, %edx
callq 0x8db70
movq 0x40(%rsp), %rdi
movq 0x40(%rsp), %rsi
addq 0x28(%rsp), %rsi
leaq 0x21(%rsp), %rdx
callq 0xc65e0
leaq 0x21(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rsi
movq 0x40(%rsp), %rdx
leaq 0x48(%rsp), %rdi
callq 0xc75f0
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
jne 0xc75a9
jmp 0xc75e0
movq 0x10(%rsp), %rax
movq 0x18(%rsp), %rcx
subq %rcx, %rax
addq 0x40(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x10(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rax
leaq 0x21(%rsp), %rcx
subq %rcx, %rax
cmpq 0x28(%rsp), %rax
jl 0xc7586
jmp 0xc75e0
addq $0x68, %rsp
retq
nopw %cs:(%rax,%rax)
nop
| _ZN3fmt3v106detail18for_each_codepointIZNS1_13compute_widthENS0_17basic_string_viewIcEEE17count_code_pointsEEvS4_T_:
sub rsp, 68h
mov [rsp+68h+var_10], rdi
mov [rsp+68h+var_8], rsi
mov [rsp+68h+var_18], rdx
mov rax, [rsp+68h+var_18]
mov [rsp+68h+var_20], rax
lea rdi, [rsp+68h+var_10]
call _ZNK3fmt3v1017basic_string_viewIcE4dataEv; fmt::v10::basic_string_view<char>::data(void)
mov [rsp+68h+var_28], rax
mov [rsp+68h+var_30], 4
lea rdi, [rsp+68h+var_10]
call _ZNK3fmt3v1017basic_string_viewIcE4sizeEv; fmt::v10::basic_string_view<char>::size(void)
cmp rax, 4
jb short loc_C7517
mov rax, [rsp+68h+var_28]
mov [rsp+68h+var_60], rax
lea rdi, [rsp+68h+var_10]
call _ZNK3fmt3v1017basic_string_viewIcE4sizeEv; fmt::v10::basic_string_view<char>::size(void)
mov rcx, rax
mov rax, [rsp+68h+var_60]
add rax, rcx
add rax, 0FFFFFFFFFFFFFFFCh
add rax, 1
mov [rsp+68h+var_38], rax
loc_C74E1:
mov rax, [rsp+68h+var_28]
cmp rax, [rsp+68h+var_38]
jnb short loc_C7515
mov rsi, [rsp+68h+var_28]
mov rdx, [rsp+68h+var_28]
lea rdi, [rsp+68h+var_20]
call _ZZN3fmt3v106detail18for_each_codepointIZNS1_13compute_widthENS0_17basic_string_viewIcEEE17count_code_pointsEEvS4_T_ENKUlPKcS8_E_clES8_S8_; fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>,fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points)::{lambda(char const*,char const*)#1}::operator()(char const*,char const*)
mov [rsp+68h+var_28], rax
cmp [rsp+68h+var_28], 0
jnz short loc_C7513
jmp loc_C75E0
loc_C7513:
jmp short loc_C74E1
loc_C7515:
jmp short $+2
loc_C7517:
lea rdi, [rsp+68h+var_10]
call _ZNK3fmt3v1017basic_string_viewIcE4dataEv; fmt::v10::basic_string_view<char>::data(void)
mov [rsp+68h+var_68], rax
lea rdi, [rsp+68h+var_10]
call _ZNK3fmt3v1017basic_string_viewIcE4sizeEv; fmt::v10::basic_string_view<char>::size(void)
mov rcx, rax
mov rax, [rsp+68h+var_68]
add rax, rcx
mov rcx, [rsp+68h+var_28]
sub rax, rcx
mov [rsp+68h+var_40], rax
cmp [rsp+68h+var_40], 0
jz loc_C75E0
lea rdi, [rsp+68h+var_47]
xor esi, esi
mov edx, 7
call _memset
mov rdi, [rsp+68h+var_28]
mov rsi, [rsp+68h+var_28]
add rsi, [rsp+68h+var_40]
lea rdx, [rsp+68h+var_47]
call _ZN3fmt3v106detail8copy_strIcKccTnNSt9enable_ifIXaasr3std7is_sameINSt12remove_constIT0_E4typeET1_EE5valuesr7is_charIS9_EE5valueEiE4typeELi0EEEPS9_PS6_SD_SC_
lea rax, [rsp+68h+var_47]
mov [rsp+68h+var_50], rax
loc_C7586:
mov rsi, [rsp+68h+var_50]
mov rdx, [rsp+68h+var_28]
lea rdi, [rsp+68h+var_20]
call _ZZN3fmt3v106detail18for_each_codepointIZNS1_13compute_widthENS0_17basic_string_viewIcEEE17count_code_pointsEEvS4_T_ENKUlPKcS8_E_clES8_S8_; fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>,fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points)::{lambda(char const*,char const*)#1}::operator()(char const*,char const*)
mov [rsp+68h+var_58], rax
cmp [rsp+68h+var_58], 0
jnz short loc_C75A9
jmp short loc_C75E0
loc_C75A9:
mov rax, [rsp+68h+var_58]
mov rcx, [rsp+68h+var_50]
sub rax, rcx
add rax, [rsp+68h+var_28]
mov [rsp+68h+var_28], rax
mov rax, [rsp+68h+var_58]
mov [rsp+68h+var_50], rax
mov rax, [rsp+68h+var_50]
lea rcx, [rsp+68h+var_47]
sub rax, rcx
cmp rax, [rsp+68h+var_40]
jl short loc_C7586
jmp short $+2
loc_C75E0:
add rsp, 68h
retn
| long long fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(
long long a1,
long long a2,
long long a3)
{
long long result; // rax
long long v4; // [rsp+0h] [rbp-68h]
long long v5; // [rsp+10h] [rbp-58h]
_BYTE *v6; // [rsp+18h] [rbp-50h]
_BYTE v7[7]; // [rsp+21h] [rbp-47h] BYREF
long long v8; // [rsp+28h] [rbp-40h]
unsigned long long v9; // [rsp+30h] [rbp-38h]
long long v10; // [rsp+38h] [rbp-30h]
unsigned long long v11; // [rsp+40h] [rbp-28h]
_QWORD v12[2]; // [rsp+48h] [rbp-20h] BYREF
_QWORD v13[2]; // [rsp+58h] [rbp-10h] BYREF
v13[0] = a1;
v13[1] = a2;
v12[1] = a3;
v12[0] = a3;
v11 = fmt::v10::basic_string_view<char>::data((long long)v13);
v10 = 4LL;
if ( (unsigned long long)fmt::v10::basic_string_view<char>::size((long long)v13) >= 4 )
{
v9 = fmt::v10::basic_string_view<char>::size((long long)v13) + v11 - 4 + 1;
while ( v11 < v9 )
{
result = fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>,fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points)::{lambda(char const*,char const*)#1}::operator()(
v12,
v11,
v11);
v11 = result;
if ( !result )
return result;
}
}
v4 = fmt::v10::basic_string_view<char>::data((long long)v13);
result = fmt::v10::basic_string_view<char>::size((long long)v13) + v4 - v11;
v8 = result;
if ( result )
{
memset(v7, 0LL, sizeof(v7));
ZN3fmt3v106detail8copy_strIcKccTnNSt9enable_ifIXaasr3std7is_sameINSt12remove_constIT0_E4typeET1_EE5valuesr7is_charIS9_EE5valueEiE4typeELi0EEEPS9_PS6_SD_SC_(
v11,
v8 + v11,
(long long)v7);
v6 = v7;
do
{
result = fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>,fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points)::{lambda(char const*,char const*)#1}::operator()(
v12,
v6,
v11);
v5 = result;
if ( !result )
break;
v11 += result - (_QWORD)v6;
v6 = (_BYTE *)result;
result -= (long long)v7;
}
while ( v5 - (long long)v7 < v8 );
}
return result;
}
| for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>:
SUB RSP,0x68
MOV qword ptr [RSP + 0x58],RDI
MOV qword ptr [RSP + 0x60],RSI
MOV qword ptr [RSP + 0x50],RDX
MOV RAX,qword ptr [RSP + 0x50]
MOV qword ptr [RSP + 0x48],RAX
LEA RDI,[RSP + 0x58]
CALL 0x0019f410
MOV qword ptr [RSP + 0x40],RAX
MOV qword ptr [RSP + 0x38],0x4
LEA RDI,[RSP + 0x58]
CALL 0x0019f3d0
CMP RAX,0x4
JC 0x001c7517
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP + 0x8],RAX
LEA RDI,[RSP + 0x58]
CALL 0x0019f3d0
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x8]
ADD RAX,RCX
ADD RAX,-0x4
ADD RAX,0x1
MOV qword ptr [RSP + 0x30],RAX
LAB_001c74e1:
MOV RAX,qword ptr [RSP + 0x40]
CMP RAX,qword ptr [RSP + 0x30]
JNC 0x001c7515
MOV RSI,qword ptr [RSP + 0x40]
MOV RDX,qword ptr [RSP + 0x40]
LEA RDI,[RSP + 0x48]
CALL 0x001c75f0
MOV qword ptr [RSP + 0x40],RAX
CMP qword ptr [RSP + 0x40],0x0
JNZ 0x001c7513
JMP 0x001c75e0
LAB_001c7513:
JMP 0x001c74e1
LAB_001c7515:
JMP 0x001c7517
LAB_001c7517:
LEA RDI,[RSP + 0x58]
CALL 0x0019f410
MOV qword ptr [RSP],RAX
LEA RDI,[RSP + 0x58]
CALL 0x0019f3d0
MOV RCX,RAX
MOV RAX,qword ptr [RSP]
ADD RAX,RCX
MOV RCX,qword ptr [RSP + 0x40]
SUB RAX,RCX
MOV qword ptr [RSP + 0x28],RAX
CMP qword ptr [RSP + 0x28],0x0
JZ 0x001c75e0
LEA RDI,[RSP + 0x21]
XOR ESI,ESI
MOV EDX,0x7
CALL 0x0018db70
MOV RDI,qword ptr [RSP + 0x40]
MOV RSI,qword ptr [RSP + 0x40]
ADD RSI,qword ptr [RSP + 0x28]
LEA RDX,[RSP + 0x21]
CALL 0x001c65e0
LEA RAX,[RSP + 0x21]
MOV qword ptr [RSP + 0x18],RAX
LAB_001c7586:
MOV RSI,qword ptr [RSP + 0x18]
MOV RDX,qword ptr [RSP + 0x40]
LEA RDI,[RSP + 0x48]
CALL 0x001c75f0
MOV qword ptr [RSP + 0x10],RAX
CMP qword ptr [RSP + 0x10],0x0
JNZ 0x001c75a9
JMP 0x001c75e0
LAB_001c75a9:
MOV RAX,qword ptr [RSP + 0x10]
MOV RCX,qword ptr [RSP + 0x18]
SUB RAX,RCX
ADD RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP + 0x40],RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x18],RAX
MOV RAX,qword ptr [RSP + 0x18]
LEA RCX,[RSP + 0x21]
SUB RAX,RCX
CMP RAX,qword ptr [RSP + 0x28]
JL 0x001c7586
JMP 0x001c75e0
LAB_001c75e0:
ADD RSP,0x68
RET
|
/* void
fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>,
fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points) */
void __thiscall
fmt::v10::detail::
for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>
(detail *this,int8 param_2,int8 param_3)
{
ulong uVar1;
long lVar2;
long lVar3;
char *pcVar4;
char *local_50;
char local_47 [7];
long local_40;
char *local_38;
int8 local_30;
char *local_28;
int8 local_20;
int8 local_18;
detail *local_10;
int8 local_8;
local_20 = param_3;
local_18 = param_3;
local_10 = this;
local_8 = param_2;
local_28 = (char *)basic_string_view<char>::data((basic_string_view<char> *)&local_10);
local_30 = 4;
uVar1 = basic_string_view<char>::size((basic_string_view<char> *)&local_10);
pcVar4 = local_28;
if (uVar1 < 4) {
LAB_001c7517:
lVar2 = basic_string_view<char>::data((basic_string_view<char> *)&local_10);
lVar3 = basic_string_view<char>::size((basic_string_view<char> *)&local_10);
local_40 = (lVar2 + lVar3) - (long)local_28;
if (local_40 != 0) {
memset(local_47,0,7);
_ZN3fmt3v106detail8copy_strIcKccTnNSt9enable_ifIXaasr3std7is_sameINSt12remove_constIT0_E4typeET1_EE5valuesr7is_charIS9_EE5valueEiE4typeELi0EEEPS9_PS6_SD_SC_
(local_28,local_28 + local_40,local_47);
local_50 = local_47;
do {
pcVar4 = (char *)for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>,fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points)
::{lambda(char_const*,char_const*)#1}::operator()
((_lambda_char_const__char_const___1_ *)&local_20,local_50,
local_28);
if (pcVar4 == (char *)0x0) {
return;
}
local_28 = local_28 + ((long)pcVar4 - (long)local_50);
local_50 = pcVar4;
} while ((long)pcVar4 - (long)local_47 < local_40);
}
}
else {
lVar2 = basic_string_view<char>::size((basic_string_view<char> *)&local_10);
local_38 = pcVar4 + lVar2 + -3;
do {
if (local_38 <= local_28) goto LAB_001c7517;
local_28 = (char *)for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>,fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points)
::{lambda(char_const*,char_const*)#1}::operator()
((_lambda_char_const__char_const___1_ *)&local_20,local_28,
local_28);
} while (local_28 != (char *)0x0);
}
return;
}
| |
23,373 | void fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>, fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points) | aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h | FMT_CONSTEXPR void for_each_codepoint(string_view s, F f) {
auto decode = [f](const char* buf_ptr, const char* ptr) {
auto cp = uint32_t();
auto error = 0;
auto end = utf8_decode(buf_ptr, &cp, &error);
bool result = f(error ? invalid_code_point : cp,
string_view(ptr, error ? 1 : to_unsigned(end - buf_ptr)));
return result ? (error ? buf_ptr + 1 : end) : nullptr;
};
auto p = s.data();
const size_t block_size = 4; // utf8_decode always reads blocks of 4 chars.
if (s.size() >= block_size) {
for (auto end = p + s.size() - block_size + 1; p < end;) {
p = decode(p, p);
if (!p) return;
}
}
if (auto num_chars_left = s.data() + s.size() - p) {
char buf[2 * block_size - 1] = {};
copy_str<char>(p, p + num_chars_left, buf);
const char* buf_ptr = buf;
do {
auto end = decode(buf_ptr, p);
if (!end) return;
p += end - buf_ptr;
buf_ptr = end;
} while (buf_ptr - buf < num_chars_left);
}
} | O3 | c | void fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>, fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %r14
movq %rdx, (%rsp)
movq %rdi, %rbx
cmpq $0x4, %rsi
jb 0x42c43
movq %rsi, 0x10(%rsp)
leaq (%r14,%rsi), %r13
addq $-0x3, %r13
leaq 0x11f1d9(%rip), %r15 # 0x161ce0
movq %rsp, %r12
movq %r14, %rbx
cmpq %r13, %rbx
jae 0x42c3e
movq %r14, %rbp
movzbl (%rbx), %ecx
movl %ecx, %esi
shrl $0x3, %esi
leaq 0x11fcd0(%rip), %rax # 0x1627f8
movsbq (%rsi,%rax), %rdx
xorl %eax, %eax
movl $0x80ff0000, %edi # imm = 0x80FF0000
btl %esi, %edi
setb %dil
leaq 0x11f13e(%rip), %rsi # 0x161c80
andl (%rsi,%rdx,4), %ecx
shll $0x12, %ecx
movzbl 0x1(%rbx), %esi
movl %esi, %r8d
andl $0x3f, %r8d
shll $0xc, %r8d
orl %ecx, %r8d
movzbl 0x2(%rbx), %r9d
movl %r9d, %ecx
andl $0x3f, %ecx
shll $0x6, %ecx
orl %r8d, %ecx
movzbl 0x3(%rbx), %r10d
movl %r10d, %r8d
andl $0x3f, %r8d
orl %ecx, %r8d
leaq 0x11f13f(%rip), %rcx # 0x161cc0
movb (%rcx,%rdx,4), %cl
shrl %cl, %r8d
xorl %ecx, %ecx
leaq 0x11f110(%rip), %r11 # 0x161ca0
cmpl (%r11,%rdx,4), %r8d
setb %cl
shll $0x6, %ecx
movl %r8d, %r14d
andl $0x7ffff800, %r14d # imm = 0x7FFFF800
xorl %r11d, %r11d
cmpl $0xd800, %r14d # imm = 0xD800
sete %r11b
shll $0x7, %r11d
xorl %r14d, %r14d
cmpl $0x110000, %r8d # imm = 0x110000
setae %r14b
shrl $0x2, %esi
andl $-0x10, %esi
shrl $0x6, %r9d
leal (%rsi,%r9,4), %r9d
shrl $0x6, %r10d
orl %r10d, %r9d
orl %ecx, %r9d
shll $0x8, %r14d
orl %r14d, %r9d
orl %r11d, %r9d
xorl $0x2a, %r9d
movb (%r15,%rdx,4), %cl
shrl %cl, %r9d
movl %r9d, %ecx
negl %ecx
movl $0x0, %esi
sbbl %esi, %esi
testl %r9d, %r9d
je 0x42c0d
leaq 0x1(%rbx), %r14
movl $0x1, %eax
jmp 0x42c1a
movb %dil, %al
leaq (%rbx,%rax), %r14
addq %rdx, %r14
addq %rdx, %rax
orl %r8d, %esi
movq %r12, %rdi
movq %rbx, %rdx
movq %rax, %rcx
callq 0x42dae
movq %r14, %rbx
testb %al, %al
movq %rbp, %r14
jne 0x42b0d
jmp 0x42d9e
movq 0x10(%rsp), %rsi
addq %rsi, %r14
subq %rbx, %r14
je 0x42d9e
xorl %eax, %eax
leaq 0x8(%rsp), %r13
movl %eax, 0x3(%r13)
movl %eax, (%r13)
movq %r13, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x2ceb0
movzbl (%r13), %eax
movl %eax, %ecx
shrl $0x3, %ecx
leaq 0x11fb7b(%rip), %rdx # 0x1627f8
movsbq (%rcx,%rdx), %r12
xorl %r15d, %r15d
movl $0x80ff0000, %edx # imm = 0x80FF0000
btl %ecx, %edx
setb %r15b
leaq 0x11efe8(%rip), %rcx # 0x161c80
andl (%rcx,%r12,4), %eax
shll $0x12, %eax
movzbl 0x1(%r13), %edx
movl %edx, %ecx
andl $0x3f, %ecx
shll $0xc, %ecx
orl %eax, %ecx
movzbl 0x2(%r13), %esi
movl %esi, %r8d
andl $0x3f, %r8d
shll $0x6, %r8d
orl %ecx, %r8d
movzbl 0x3(%r13), %edi
movl %edi, %eax
andl $0x3f, %eax
orl %r8d, %eax
leaq 0x11efeb(%rip), %rcx # 0x161cc0
movb (%rcx,%r12,4), %cl
shrl %cl, %eax
xorl %ecx, %ecx
leaq 0x11efbc(%rip), %r8 # 0x161ca0
cmpl (%r8,%r12,4), %eax
setb %cl
shll $0x6, %ecx
movl %eax, %r9d
andl $0x7ffff800, %r9d # imm = 0x7FFFF800
xorl %r8d, %r8d
cmpl $0xd800, %r9d # imm = 0xD800
sete %r8b
shll $0x7, %r8d
xorl %r9d, %r9d
cmpl $0x110000, %eax # imm = 0x110000
setae %r9b
shrl $0x2, %edx
andl $-0x10, %edx
shrl $0x6, %esi
leal (%rdx,%rsi,4), %ebp
shrl $0x6, %edi
orl %edi, %ebp
orl %ecx, %ebp
shll $0x8, %r9d
orl %r9d, %ebp
orl %r8d, %ebp
xorl $0x2a, %ebp
leaq 0x11efa3(%rip), %rcx # 0x161ce0
movb (%rcx,%r12,4), %cl
shrl %cl, %ebp
movl %ebp, %ecx
negl %ecx
movl $0x0, %esi
sbbl %esi, %esi
testl %ebp, %ebp
je 0x42d59
movl $0x1, %ecx
jmp 0x42d5d
leaq (%r15,%r12), %rcx
orl %eax, %esi
movq %rsp, %rdi
movq %rbx, %rdx
callq 0x42dae
testb %al, %al
je 0x42d9e
testl %ebp, %ebp
je 0x42d78
leaq 0x1(%r13), %r15
jmp 0x42d7e
addq %r13, %r15
addq %r12, %r15
movq %r15, %rax
subq %r13, %rax
addq %rax, %rbx
movq %r15, %rax
leaq 0x8(%rsp), %rcx
subq %rcx, %rax
movq %r15, %r13
cmpq %r14, %rax
jl 0x42c6c
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
| _ZN3fmt3v106detail18for_each_codepointIZNS1_13compute_widthENS0_17basic_string_viewIcEEE17count_code_pointsEEvS4_T_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov r14, rdi
mov [rsp+48h+var_48], rdx
mov rbx, rdi
cmp rsi, 4
jb loc_42C43
mov [rsp+48h+var_38], rsi
lea r13, [r14+rsi]
add r13, 0FFFFFFFFFFFFFFFDh
lea r15, dword_161CE0
mov r12, rsp
mov rbx, r14
loc_42B0D:
cmp rbx, r13
jnb loc_42C3E
mov rbp, r14
movzx ecx, byte ptr [rbx]
mov esi, ecx
shr esi, 3
lea rax, byte_1627F8
movsx rdx, byte ptr [rsi+rax]
xor eax, eax
mov edi, 80FF0000h
bt edi, esi
setb dil
lea rsi, dword_161C80
and ecx, [rsi+rdx*4]
shl ecx, 12h
movzx esi, byte ptr [rbx+1]
mov r8d, esi
and r8d, 3Fh
shl r8d, 0Ch
or r8d, ecx
movzx r9d, byte ptr [rbx+2]
mov ecx, r9d
and ecx, 3Fh
shl ecx, 6
or ecx, r8d
movzx r10d, byte ptr [rbx+3]
mov r8d, r10d
and r8d, 3Fh
or r8d, ecx
lea rcx, dword_161CC0
mov cl, [rcx+rdx*4]
shr r8d, cl
xor ecx, ecx
lea r11, dword_161CA0
cmp r8d, [r11+rdx*4]
setb cl
shl ecx, 6
mov r14d, r8d
and r14d, 7FFFF800h
xor r11d, r11d
cmp r14d, 0D800h
setz r11b
shl r11d, 7
xor r14d, r14d
cmp r8d, 110000h
setnb r14b
shr esi, 2
and esi, 0FFFFFFF0h
shr r9d, 6
lea r9d, [rsi+r9*4]
shr r10d, 6
or r9d, r10d
or r9d, ecx
shl r14d, 8
or r9d, r14d
or r9d, r11d
xor r9d, 2Ah
mov cl, [r15+rdx*4]
shr r9d, cl
mov ecx, r9d
neg ecx
mov esi, 0
sbb esi, esi
test r9d, r9d
jz short loc_42C0D
lea r14, [rbx+1]
mov eax, 1
jmp short loc_42C1A
loc_42C0D:
mov al, dil
lea r14, [rbx+rax]
add r14, rdx
add rax, rdx
loc_42C1A:
or esi, r8d
mov rdi, r12
mov rdx, rbx
mov rcx, rax
call _ZZN3fmt3v106detail13compute_widthENS0_17basic_string_viewIcEEENK17count_code_pointsclEjS3_; fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points::operator()(uint,fmt::v10::basic_string_view<char>)
mov rbx, r14
test al, al
mov r14, rbp
jnz loc_42B0D
jmp loc_42D9E
loc_42C3E:
mov rsi, [rsp+48h+var_38]
loc_42C43:
add r14, rsi
sub r14, rbx
jz loc_42D9E
xor eax, eax
lea r13, [rsp+48h+var_40]
mov [r13+3], eax
mov [r13+0], eax
mov rdi, r13
mov rsi, rbx
mov rdx, r14
call _memcpy
loc_42C6C:
movzx eax, byte ptr [r13+0]
mov ecx, eax
shr ecx, 3
lea rdx, byte_1627F8
movsx r12, byte ptr [rcx+rdx]
xor r15d, r15d
mov edx, 80FF0000h
bt edx, ecx
setb r15b
lea rcx, dword_161C80
and eax, [rcx+r12*4]
shl eax, 12h
movzx edx, byte ptr [r13+1]
mov ecx, edx
and ecx, 3Fh
shl ecx, 0Ch
or ecx, eax
movzx esi, byte ptr [r13+2]
mov r8d, esi
and r8d, 3Fh
shl r8d, 6
or r8d, ecx
movzx edi, byte ptr [r13+3]
mov eax, edi
and eax, 3Fh
or eax, r8d
lea rcx, dword_161CC0
mov cl, [rcx+r12*4]
shr eax, cl
xor ecx, ecx
lea r8, dword_161CA0
cmp eax, [r8+r12*4]
setb cl
shl ecx, 6
mov r9d, eax
and r9d, 7FFFF800h
xor r8d, r8d
cmp r9d, 0D800h
setz r8b
shl r8d, 7
xor r9d, r9d
cmp eax, 110000h
setnb r9b
shr edx, 2
and edx, 0FFFFFFF0h
shr esi, 6
lea ebp, [rdx+rsi*4]
shr edi, 6
or ebp, edi
or ebp, ecx
shl r9d, 8
or ebp, r9d
or ebp, r8d
xor ebp, 2Ah
lea rcx, dword_161CE0
mov cl, [rcx+r12*4]
shr ebp, cl
mov ecx, ebp
neg ecx
mov esi, 0
sbb esi, esi
test ebp, ebp
jz short loc_42D59
mov ecx, 1
jmp short loc_42D5D
loc_42D59:
lea rcx, [r15+r12]
loc_42D5D:
or esi, eax
mov rdi, rsp
mov rdx, rbx
call _ZZN3fmt3v106detail13compute_widthENS0_17basic_string_viewIcEEENK17count_code_pointsclEjS3_; fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points::operator()(uint,fmt::v10::basic_string_view<char>)
test al, al
jz short loc_42D9E
test ebp, ebp
jz short loc_42D78
lea r15, [r13+1]
jmp short loc_42D7E
loc_42D78:
add r15, r13
add r15, r12
loc_42D7E:
mov rax, r15
sub rax, r13
add rbx, rax
mov rax, r15
lea rcx, [rsp+48h+var_40]
sub rax, rcx
mov r13, r15
cmp rax, r14
jl loc_42C6C
loc_42D9E:
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| void fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(
unsigned __int8 *a1,
unsigned long long a2,
long long a3)
{
unsigned __int8 *v3; // r14
unsigned __int8 *v4; // rbx
unsigned long long v5; // r13
unsigned __int8 *v6; // rbp
long long v7; // rsi
long long v8; // rdx
long long v9; // rax
int v10; // edi
unsigned __int8 v11; // di
unsigned int v12; // r8d
int v13; // r11d
int v14; // r10d
int v15; // r14d
int v16; // esi
unsigned __int8 *v17; // r14
long long v18; // rax
char v19; // al
long long v20; // r14
unsigned __int8 *v21; // r13
long long v22; // rcx
long long v23; // r12
int v24; // edx
long long v25; // r15
unsigned int v26; // eax
int v27; // r8d
unsigned int v28; // edx
int v29; // edi
int v30; // r9d
unsigned int v31; // ebp
long long v32; // rcx
long long v33; // r15
long long v34; // [rsp+0h] [rbp-48h] BYREF
_DWORD v35[2]; // [rsp+8h] [rbp-40h] BYREF
unsigned long long v36; // [rsp+10h] [rbp-38h]
v3 = a1;
v34 = a3;
v4 = a1;
if ( a2 >= 4 )
{
v36 = a2;
v5 = (unsigned long long)&a1[a2 - 3];
v4 = a1;
while ( (unsigned long long)v4 < v5 )
{
v6 = v3;
v7 = *v4 >> 3;
v8 = byte_1627F8[v7];
v9 = 0LL;
v10 = -2130771968;
v11 = _bittest(&v10, v7);
v12 = (((dword_161C80[v8] & *v4) << 18) | ((v4[1] & 0x3F) << 12) | ((v4[2] & 0x3F) << 6) | v4[3] & 0x3Fu) >> LOBYTE(dword_161CC0[v8]);
v13 = ((v12 & 0x7FFFF800) == 55296) << 7;
v14 = v4[3] >> 6;
v15 = (v12 >= 0x110000) << 8;
v16 = -(((v13 | v15 | ((v12 < dword_161CA0[v8]) << 6) | v14 | (((v4[1] >> 2) & 0xFFFFFFF0) + 4 * (v4[2] >> 6))) ^ 0x2A) >> LOBYTE(dword_161CE0[v8]) != 0);
if ( ((v13 | v15 | ((v12 < dword_161CA0[v8]) << 6) | v14 | (((v4[1] >> 2) & 0xFFFFFFF0) + 4 * (v4[2] >> 6))) ^ 0x2A) >> LOBYTE(dword_161CE0[v8]) )
{
v17 = v4 + 1;
v18 = 1LL;
}
else
{
LOBYTE(v9) = v11;
v17 = &v4[v9 + v8];
v18 = v8 + v9;
}
v19 = fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points::operator()(
&v34,
v12 | v16,
v4,
v18);
v4 = v17;
v3 = v6;
if ( !v19 )
return;
}
a2 = v36;
}
v20 = &v3[a2] - v4;
if ( v20 )
{
v21 = (unsigned __int8 *)v35;
*(_DWORD *)((char *)v35 + 3) = 0;
v35[0] = 0;
memcpy(v35);
do
{
v22 = *v21 >> 3;
v23 = byte_1627F8[v22];
v24 = -2130771968;
v25 = _bittest(&v24, v22);
v26 = (((dword_161C80[v23] & *v21) << 18) | ((v21[1] & 0x3F) << 12) | ((v21[2] & 0x3F) << 6) | v21[3] & 0x3Fu) >> LOBYTE(dword_161CC0[v23]);
v27 = ((v26 & 0x7FFFF800) == 55296) << 7;
v28 = (v21[1] >> 2) & 0xFFFFFFF0;
v29 = v21[3] >> 6;
v30 = (v26 >= 0x110000) << 8;
v31 = ((v27 | v30 | ((v26 < dword_161CA0[v23]) << 6) | v29 | (v28 + 4 * (v21[2] >> 6))) ^ 0x2A) >> LOBYTE(dword_161CE0[v23]);
if ( v31 )
v32 = 1LL;
else
v32 = v25 + v23;
if ( !(unsigned __int8)fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points::operator()(
&v34,
((v27 | v30 | ((v26 < dword_161CA0[v23]) << 6) | v29 | (v28 + 4 * (v21[2] >> 6))) ^ 0x2A) >> LOBYTE(dword_161CE0[v23]) != 0
? -1
: v26,
v4,
v32) )
break;
v33 = (long long)(v31 ? v21 + 1 : &v21[v25 + v23]);
v4 += v33 - (_QWORD)v21;
v21 = (unsigned __int8 *)v33;
}
while ( v33 - (long long)v35 < v20 );
}
}
| for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV R14,RDI
MOV qword ptr [RSP],RDX
MOV RBX,RDI
CMP RSI,0x4
JC 0x00142c43
MOV qword ptr [RSP + 0x10],RSI
LEA R13,[R14 + RSI*0x1]
ADD R13,-0x3
LEA R15,[0x261ce0]
MOV R12,RSP
MOV RBX,R14
LAB_00142b0d:
CMP RBX,R13
JNC 0x00142c3e
MOV RBP,R14
MOVZX ECX,byte ptr [RBX]
MOV ESI,ECX
SHR ESI,0x3
LEA RAX,[0x2627f8]
MOVSX RDX,byte ptr [RSI + RAX*0x1]
XOR EAX,EAX
MOV EDI,0x80ff0000
BT EDI,ESI
SETC DIL
LEA RSI,[0x261c80]
AND ECX,dword ptr [RSI + RDX*0x4]
SHL ECX,0x12
MOVZX ESI,byte ptr [RBX + 0x1]
MOV R8D,ESI
AND R8D,0x3f
SHL R8D,0xc
OR R8D,ECX
MOVZX R9D,byte ptr [RBX + 0x2]
MOV ECX,R9D
AND ECX,0x3f
SHL ECX,0x6
OR ECX,R8D
MOVZX R10D,byte ptr [RBX + 0x3]
MOV R8D,R10D
AND R8D,0x3f
OR R8D,ECX
LEA RCX,[0x261cc0]
MOV CL,byte ptr [RCX + RDX*0x4]
SHR R8D,CL
XOR ECX,ECX
LEA R11,[0x261ca0]
CMP R8D,dword ptr [R11 + RDX*0x4]
SETC CL
SHL ECX,0x6
MOV R14D,R8D
AND R14D,0x7ffff800
XOR R11D,R11D
CMP R14D,0xd800
SETZ R11B
SHL R11D,0x7
XOR R14D,R14D
CMP R8D,0x110000
SETNC R14B
SHR ESI,0x2
AND ESI,0xfffffff0
SHR R9D,0x6
LEA R9D,[RSI + R9*0x4]
SHR R10D,0x6
OR R9D,R10D
OR R9D,ECX
SHL R14D,0x8
OR R9D,R14D
OR R9D,R11D
XOR R9D,0x2a
MOV CL,byte ptr [R15 + RDX*0x4]
SHR R9D,CL
MOV ECX,R9D
NEG ECX
MOV ESI,0x0
SBB ESI,ESI
TEST R9D,R9D
JZ 0x00142c0d
LEA R14,[RBX + 0x1]
MOV EAX,0x1
JMP 0x00142c1a
LAB_00142c0d:
MOV AL,DIL
LEA R14,[RBX + RAX*0x1]
ADD R14,RDX
ADD RAX,RDX
LAB_00142c1a:
OR ESI,R8D
MOV RDI,R12
MOV RDX,RBX
MOV RCX,RAX
CALL 0x00142dae
MOV RBX,R14
TEST AL,AL
MOV R14,RBP
JNZ 0x00142b0d
JMP 0x00142d9e
LAB_00142c3e:
MOV RSI,qword ptr [RSP + 0x10]
LAB_00142c43:
ADD R14,RSI
SUB R14,RBX
JZ 0x00142d9e
XOR EAX,EAX
LEA R13,[RSP + 0x8]
MOV dword ptr [R13 + 0x3],EAX
MOV dword ptr [R13],EAX
MOV RDI,R13
MOV RSI,RBX
MOV RDX,R14
CALL 0x0012ceb0
LAB_00142c6c:
MOVZX EAX,byte ptr [R13]
MOV ECX,EAX
SHR ECX,0x3
LEA RDX,[0x2627f8]
MOVSX R12,byte ptr [RCX + RDX*0x1]
XOR R15D,R15D
MOV EDX,0x80ff0000
BT EDX,ECX
SETC R15B
LEA RCX,[0x261c80]
AND EAX,dword ptr [RCX + R12*0x4]
SHL EAX,0x12
MOVZX EDX,byte ptr [R13 + 0x1]
MOV ECX,EDX
AND ECX,0x3f
SHL ECX,0xc
OR ECX,EAX
MOVZX ESI,byte ptr [R13 + 0x2]
MOV R8D,ESI
AND R8D,0x3f
SHL R8D,0x6
OR R8D,ECX
MOVZX EDI,byte ptr [R13 + 0x3]
MOV EAX,EDI
AND EAX,0x3f
OR EAX,R8D
LEA RCX,[0x261cc0]
MOV CL,byte ptr [RCX + R12*0x4]
SHR EAX,CL
XOR ECX,ECX
LEA R8,[0x261ca0]
CMP EAX,dword ptr [R8 + R12*0x4]
SETC CL
SHL ECX,0x6
MOV R9D,EAX
AND R9D,0x7ffff800
XOR R8D,R8D
CMP R9D,0xd800
SETZ R8B
SHL R8D,0x7
XOR R9D,R9D
CMP EAX,0x110000
SETNC R9B
SHR EDX,0x2
AND EDX,0xfffffff0
SHR ESI,0x6
LEA EBP,[RDX + RSI*0x4]
SHR EDI,0x6
OR EBP,EDI
OR EBP,ECX
SHL R9D,0x8
OR EBP,R9D
OR EBP,R8D
XOR EBP,0x2a
LEA RCX,[0x261ce0]
MOV CL,byte ptr [RCX + R12*0x4]
SHR EBP,CL
MOV ECX,EBP
NEG ECX
MOV ESI,0x0
SBB ESI,ESI
TEST EBP,EBP
JZ 0x00142d59
MOV ECX,0x1
JMP 0x00142d5d
LAB_00142d59:
LEA RCX,[R15 + R12*0x1]
LAB_00142d5d:
OR ESI,EAX
MOV RDI,RSP
MOV RDX,RBX
CALL 0x00142dae
TEST AL,AL
JZ 0x00142d9e
TEST EBP,EBP
JZ 0x00142d78
LEA R15,[R13 + 0x1]
JMP 0x00142d7e
LAB_00142d78:
ADD R15,R13
ADD R15,R12
LAB_00142d7e:
MOV RAX,R15
SUB RAX,R13
ADD RBX,RAX
MOV RAX,R15
LEA RCX,[RSP + 0x8]
SUB RAX,RCX
MOV R13,R15
CMP RAX,R14
JL 0x00142c6c
LAB_00142d9e:
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* void
fmt::v10::detail::for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>(fmt::v10::basic_string_view<char>,
fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points) */
void __thiscall
fmt::v10::detail::
for_each_codepoint<fmt::v10::detail::compute_width(fmt::v10::basic_string_view<char>)::count_code_points>
(detail *this,ulong param_2,int8 param_3)
{
byte bVar1;
char cVar2;
long lVar3;
ulong uVar4;
long lVar5;
detail *__src;
uint uVar6;
uint uVar7;
uint uVar8;
long lVar9;
byte *pbVar10;
detail *pdVar11;
byte *pbVar12;
int8 local_48;
byte local_40 [8];
ulong local_38;
__src = this;
local_48 = param_3;
if (param_2 < 4) {
LAB_00142c43:
this = this + (param_2 - (long)__src);
if (this != (detail *)0x0) {
local_40[4] = 0;
local_40[5] = 0;
local_40[6] = 0;
local_40[0] = 0;
local_40[1] = 0;
local_40[2] = 0;
local_40[3] = 0;
memcpy(local_40,__src,(size_t)this);
pbVar10 = local_40;
do {
uVar6 = (uint)(*pbVar10 >> 3);
lVar9 = (long)(char)(&DAT_002627f8)[uVar6];
uVar4 = (ulong)((0x80ff0000U >> uVar6 & 1) != 0);
uVar6 = (pbVar10[3] & 0x3f |
(pbVar10[2] & 0x3f) << 6 |
(pbVar10[1] & 0x3f) << 0xc |
((uint)*pbVar10 & *(uint *)(&DAT_00261c80 + lVar9 * 4)) << 0x12) >>
((&DAT_00261cc0)[lVar9 * 4] & 0x1f);
uVar7 = ((pbVar10[1] >> 2 & 0xfffffff0) + (uint)(pbVar10[2] >> 6) * 4 |
(uint)(pbVar10[3] >> 6) | (uint)(uVar6 < *(uint *)(&DAT_00261ca0 + lVar9 * 4)) << 6
| (uint)(0x10ffff < uVar6) << 8 | (uint)((uVar6 & 0x7ffff800) == 0xd800) << 7) ^
0x2a;
bVar1 = (&DAT_00261ce0)[lVar9 * 4] & 0x1f;
if (uVar7 >> bVar1 == 0) {
lVar5 = uVar4 + lVar9;
}
else {
lVar5 = 1;
}
cVar2 = compute_width(fmt::v10::basic_string_view<char>)::count_code_points::operator()
(&local_48,-(uint)(uVar7 >> bVar1 != 0) | uVar6,__src,lVar5);
if (cVar2 == '\0') {
return;
}
if (uVar7 >> bVar1 == 0) {
pbVar12 = pbVar10 + lVar9 + uVar4;
}
else {
pbVar12 = pbVar10 + 1;
}
__src = __src + ((long)pbVar12 - (long)pbVar10);
pbVar10 = pbVar12;
} while ((long)pbVar12 - (long)local_40 < (long)this);
}
}
else {
lVar9 = param_2 - 3;
local_38 = param_2;
do {
param_2 = local_38;
if (this + lVar9 <= __src) goto LAB_00142c43;
uVar6 = (uint)((byte)*__src >> 3);
lVar5 = (long)(char)(&DAT_002627f8)[uVar6];
uVar7 = ((byte)__src[3] & 0x3f |
((byte)__src[2] & 0x3f) << 6 |
((byte)__src[1] & 0x3f) << 0xc |
((uint)(byte)*__src & *(uint *)(&DAT_00261c80 + lVar5 * 4)) << 0x12) >>
((&DAT_00261cc0)[lVar5 * 4] & 0x1f);
uVar8 = (((byte)__src[1] >> 2 & 0xfffffff0) + (uint)((byte)__src[2] >> 6) * 4 |
(uint)((byte)__src[3] >> 6) |
(uint)(uVar7 < *(uint *)(&DAT_00261ca0 + lVar5 * 4)) << 6 |
(uint)(0x10ffff < uVar7) << 8 | (uint)((uVar7 & 0x7ffff800) == 0xd800) << 7) ^ 0x2a;
if (uVar8 >> ((&DAT_00261ce0)[lVar5 * 4] & 0x1f) == 0) {
uVar4 = (ulong)((0x80ff0000U >> uVar6 & 1) != 0);
pdVar11 = __src + lVar5 + uVar4;
lVar3 = uVar4 + lVar5;
}
else {
pdVar11 = __src + 1;
lVar3 = 1;
}
cVar2 = compute_width(fmt::v10::basic_string_view<char>)::count_code_points::operator()
(&local_48,
-(uint)(uVar8 >> ((&DAT_00261ce0)[lVar5 * 4] & 0x1f) != 0) | uVar7,__src,
lVar3);
__src = pdVar11;
} while (cVar2 != '\0');
}
return;
}
| |
23,374 | SchemaConverter::_resolve_ref(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | llama.cpp/common/json-schema-to-grammar.cpp | std::string _resolve_ref(const std::string & ref) {
std::string ref_name = ref.substr(ref.find_last_of('/') + 1);
if (_rules.find(ref_name) == _rules.end() && _refs_being_resolved.find(ref) == _refs_being_resolved.end()) {
_refs_being_resolved.insert(ref);
json resolved = _refs[ref];
ref_name = visit(resolved, ref_name);
_refs_being_resolved.erase(ref);
}
return ref_name;
} | O3 | cpp | SchemaConverter::_resolve_ref(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq %rdx, %rdi
movl $0x2f, %esi
movq $-0x1, %rdx
callq 0x1d5e0
leaq 0x1(%rax), %rdx
movq %rbx, %rdi
movq %r14, %rsi
movq $-0x1, %rcx
callq 0x1de20
leaq 0x28(%r15), %rdi
movq %rbx, %rsi
callq 0xbca46
leaq 0x30(%r15), %rcx
cmpq %rcx, %rax
jne 0xbf790
leaq 0x90(%r15), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0xc19d0
testq %rax, %rax
jne 0xbf790
leaq 0x18(%rsp), %rcx
movq %r12, (%rcx)
movq %r12, %rdi
movq %r14, %rsi
movq %r14, %rdx
callq 0xb5b64
leaq 0x58(%r15), %rdi
movq %r14, %rsi
callq 0xc1b14
leaq 0x8(%rsp), %rdi
movq %rax, %rsi
callq 0x56230
leaq 0x18(%rsp), %rdi
leaq 0x8(%rsp), %rdx
movq %r15, %rsi
movq %rbx, %rcx
callq 0xbcba0
leaq 0x18(%rsp), %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1d720
movq (%r15), %rdi
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0xbf76e
movq 0x28(%rsp), %rsi
incq %rsi
callq 0x1d160
movq %r12, %rdi
movq %r14, %rsi
callq 0xc1f6a
leaq 0x8(%rsp), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x60b38
movq %r14, %rdi
callq 0x60bd8
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0xbf7a1
movq %rax, %r14
leaq 0x8(%rsp), %r15
movq %r15, %rdi
xorl %esi, %esi
callq 0x60b38
movq %r15, %rdi
callq 0x60bd8
jmp 0xbf7c6
jmp 0xbf7c3
jmp 0xbf7c3
jmp 0xbf7c3
movq %rax, %r14
movq (%rbx), %rdi
addq $0x10, %rbx
cmpq %rbx, %rdi
je 0xbf7dd
movq (%rbx), %rsi
incq %rsi
callq 0x1d160
movq %r14, %rdi
callq 0x1d8e0
nop
| _ZN15SchemaConverter12_resolve_refERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push r15
push r14
push r12
push rbx
sub rsp, 38h
mov r14, rdx
mov r15, rsi
mov rbx, rdi
mov rdi, rdx
mov esi, 2Fh ; '/'
mov rdx, 0FFFFFFFFFFFFFFFFh
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5rfindEcm; std::string::rfind(char,ulong)
lea rdx, [rax+1]
mov rdi, rbx
mov rsi, r14
mov rcx, 0FFFFFFFFFFFFFFFFh
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong)
lea rdi, [r15+28h]
mov rsi, rbx
call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_S5_ESt10_Select1stIS8_ESt4lessIS5_ESaIS8_EE4findERS7_; std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::find(std::string const&)
lea rcx, [r15+30h]
cmp rax, rcx
jnz loc_BF790
lea r12, [r15+90h]
mov rdi, r12
mov rsi, r14
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_SaIS5_ENSt8__detail9_IdentityESt8equal_toIS5_ESt4hashIS5_ENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb1ELb1ELb1EEEE4findERKS5_; std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>::find(std::string const&)
test rax, rax
jnz loc_BF790
lea rcx, [rsp+58h+var_40]
mov [rcx], r12
mov rdi, r12
mov rsi, r14
mov rdx, r14
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_SaIS5_ENSt8__detail9_IdentityESt8equal_toIS5_ESt4hashIS5_ENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb1ELb1ELb1EEEE16_M_insert_uniqueIRKS5_SL_NS7_10_AllocNodeISaINS7_10_Hash_nodeIS5_Lb1EEEEEEEESt4pairINS7_14_Node_iteratorIS5_Lb1ELb1EEEbEOT_OT0_RKT1_; std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>::_M_insert_unique<std::string const&,std::string const&,std::__detail::_AllocNode<std::allocator<std::__detail::_Hash_node<std::string,true>>>>(std::string const&,std::string const&,std::__detail::_AllocNode<std::allocator<std::__detail::_Hash_node<std::string,true>>> const&)
lea rdi, [r15+58h]
mov rsi, r14
call _ZNSt8__detail9_Map_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS6_N8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS6_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESaISI_ENS_10_Select1stESt8equal_toIS6_ESt4hashIS6_ENS_18_Mod_range_hashingENS_20_Default_ranged_hashENS_20_Prime_rehash_policyENS_17_Hashtable_traitsILb1ELb0ELb1EEELb1EEixERS8_; std::__detail::_Map_base<std::string,std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>,true>::operator[](std::string const&)
lea rdi, [rsp+58h+var_50]
mov rsi, rax
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ERKSD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::basic_json(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
lea rdi, [rsp+58h+var_40]
lea rdx, [rsp+58h+var_50]
mov rsi, r15
mov rcx, rbx
call _ZN15SchemaConverter5visitERKN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEERKSA_; SchemaConverter::visit(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&,std::string const&)
lea r15, [rsp+58h+var_40]
mov rdi, rbx
mov rsi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&)
mov rdi, [r15]; void *
lea rax, [rsp+58h+var_30]
cmp rdi, rax
jz short loc_BF76E
mov rsi, [rsp+58h+var_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BF76E:
mov rdi, r12
mov rsi, r14
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_SaIS5_ENSt8__detail9_IdentityESt8equal_toIS5_ESt4hashIS5_ENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb1ELb1ELb1EEEE8_M_eraseESt17integral_constantIbLb1EERKS5_; std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>::_M_erase(std::integral_constant<bool,true>,std::string const&)
lea r14, [rsp+58h+var_50]
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
loc_BF790:
mov rax, rbx
add rsp, 38h
pop rbx
pop r12
pop r14
pop r15
retn
jmp short $+2
loc_BF7A1:
mov r14, rax
lea r15, [rsp+arg_0]
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()
jmp short loc_BF7C6
jmp short loc_BF7C3
jmp short loc_BF7C3
jmp short $+2
loc_BF7C3:
mov r14, rax
loc_BF7C6:
mov rdi, [rbx]; void *
add rbx, 10h
cmp rdi, rbx
jz short loc_BF7DD
mov rsi, [rbx]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BF7DD:
mov rdi, r14
call __Unwind_Resume
| long long SchemaConverter::_resolve_ref(long long a1, long long a2, long long *a3)
{
long long v4; // rax
int v5; // edx
int v6; // ecx
int v7; // r8d
int v8; // r9d
long long v9; // rax
char v11[16]; // [rsp+8h] [rbp-50h] BYREF
void *v12[2]; // [rsp+18h] [rbp-40h] BYREF
long long v13; // [rsp+28h] [rbp-30h] BYREF
v4 = std::string::rfind(a3, 47LL, -1LL);
std::string::substr(a1, a3, v4 + 1, -1LL);
if ( std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::find(
a2 + 40,
a1) == a2 + 48
&& !std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>::find(
a2 + 144,
a3) )
{
v12[0] = (void *)(a2 + 144);
std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>::_M_insert_unique<std::string const&,std::string const&,std::__detail::_AllocNode<std::allocator<std::__detail::_Hash_node<std::string,true>>>>(
(_QWORD *)(a2 + 144),
a3,
(long long)a3,
v12);
v9 = std::__detail::_Map_base<std::string,std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>,true>::operator[](
(int)a2 + 88,
(_DWORD)a3,
v5,
v6,
v7,
v8);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json(
(long long)v11,
v9);
SchemaConverter::visit(v12, (void *)a2, (long long)v11, a1);
std::string::operator=(a1, v12);
if ( v12[0] != &v13 )
operator delete(v12[0], v13 + 1);
std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>::_M_erase(
a2 + 144,
a3);
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(v11);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v11);
}
return a1;
}
| _resolve_ref:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
MOV RDI,RDX
MOV ESI,0x2f
MOV RDX,-0x1
CALL 0x0011d5e0
LEA RDX,[RAX + 0x1]
MOV RDI,RBX
MOV RSI,R14
MOV RCX,-0x1
CALL 0x0011de20
LEA RDI,[R15 + 0x28]
LAB_001bf6d0:
MOV RSI,RBX
CALL 0x001bca46
LEA RCX,[R15 + 0x30]
CMP RAX,RCX
JNZ 0x001bf790
LEA R12,[R15 + 0x90]
LAB_001bf6ec:
MOV RDI,R12
MOV RSI,R14
CALL 0x001c19d0
TEST RAX,RAX
JNZ 0x001bf790
LEA RCX,[RSP + 0x18]
MOV qword ptr [RCX],R12
LAB_001bf708:
MOV RDI,R12
MOV RSI,R14
MOV RDX,R14
CALL 0x001b5b64
LEA RDI,[R15 + 0x58]
LAB_001bf71a:
MOV RSI,R14
CALL 0x001c1b14
LEA RDI,[RSP + 0x8]
MOV RSI,RAX
CALL 0x00156230
LAB_001bf72f:
LEA RDI,[RSP + 0x18]
LEA RDX,[RSP + 0x8]
MOV RSI,R15
MOV RCX,RBX
CALL 0x001bcba0
LEA R15,[RSP + 0x18]
MOV RDI,RBX
MOV RSI,R15
CALL 0x0011d720
MOV RDI,qword ptr [R15]
LEA RAX,[RSP + 0x28]
CMP RDI,RAX
JZ 0x001bf76e
MOV RSI,qword ptr [RSP + 0x28]
INC RSI
CALL 0x0011d160
LAB_001bf76e:
MOV RDI,R12
MOV RSI,R14
CALL 0x001c1f6a
LAB_001bf779:
LEA R14,[RSP + 0x8]
MOV RDI,R14
XOR ESI,ESI
CALL 0x00160b38
MOV RDI,R14
CALL 0x00160bd8
LAB_001bf790:
MOV RAX,RBX
ADD RSP,0x38
POP RBX
POP R12
POP R14
POP R15
RET
|
/* SchemaConverter::_resolve_ref(std::__cxx11::string const&) */
string * SchemaConverter::_resolve_ref(string *param_1)
{
_Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>
*this;
string *psVar1;
long lVar2;
basic_json *pbVar3;
string *in_RDX;
string *in_RSI;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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_50 [16];
_Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>
*local_40 [2];
long local_30 [2];
std::__cxx11::string::rfind((char)in_RDX,0x2f);
std::__cxx11::string::substr((ulong)param_1,(ulong)in_RDX);
/* try { // try from 001bf6d0 to 001bf6d7 has its CatchHandler @ 001bf7c3 */
psVar1 = (string *)
std::
_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
::find((_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
*)(in_RSI + 0x28),param_1);
if (psVar1 == in_RSI + 0x30) {
this = (_Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>
*)(in_RSI + 0x90);
/* try { // try from 001bf6ec to 001bf6f6 has its CatchHandler @ 001bf7c1 */
lVar2 = std::
_Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>
::find(this,in_RDX);
if (lVar2 == 0) {
local_40[0] = this;
/* try { // try from 001bf708 to 001bf715 has its CatchHandler @ 001bf7bd */
std::
_Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>
::
_M_insert_unique<std::__cxx11::string_const&,std::__cxx11::string_const&,std::__detail::_AllocNode<std::allocator<std::__detail::_Hash_node<std::__cxx11::string,true>>>>
(this,in_RDX,in_RDX,(_AllocNode *)local_40);
/* try { // try from 001bf71a to 001bf72e has its CatchHandler @ 001bf7bf */
pbVar3 = (basic_json *)
std::__detail::
_Map_base<std::__cxx11::string,std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>,std::__detail::_Select1st,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>,true>
::operator[]((_Map_base<std::__cxx11::string,std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>,std::__detail::_Select1st,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>,true>
*)(in_RSI + 0x58),in_RDX);
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::basic_json(local_50,pbVar3);
/* try { // try from 001bf72f to 001bf743 has its CatchHandler @ 001bf7a1 */
visit((basic_json *)local_40,in_RSI);
std::__cxx11::string::operator=(param_1,(string *)local_40);
if (local_40[0] !=
(_Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>
*)local_30) {
operator_delete(local_40[0],local_30[0] + 1);
}
/* try { // try from 001bf76e to 001bf778 has its CatchHandler @ 001bf79f */
std::
_Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>
::_M_erase(this);
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>
::assert_invariant(SUB81((data *)local_50,0));
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data((data *)local_50);
}
}
return param_1;
}
| |
23,375 | my_wc_to_printable_8bit | eloqsql/strings/ctype.c | int
my_wc_to_printable_8bit(CHARSET_INFO *cs, my_wc_t wc,
uchar *str, uchar *end)
{
/*
Special case: swe7 does not have the backslash character.
Use dot instead of backslash for escaping.
*/
uint bs= cs->tab_to_uni && cs->tab_to_uni['\\'] != '\\' ? '.' : '\\';
DBUG_ASSERT(cs->mbminlen == 1);
/*
Additionally, if the original swe7 string contains backslashes,
replace them to dots, so this error message:
Invalid swe7 character string: '\xEF\xBC\xB4'
is displayed as:
Invalid swe7 character string: '.xEF.xBC.xB4'
which is more readable than what would happen without '\'-to-dot mapping:
Invalid swe7 character string: '.005CxEF.005CxBC.005CxB4'
*/
if (bs == '.' && wc == '\\')
wc= '.';
return my_wc_to_printable_ex(cs, wc, str, end, bs, 1, 1);
} | O0 | c | my_wc_to_printable_8bit:
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 -0x8(%rbp), %rcx
xorl %eax, %eax
cmpq $0x0, 0x68(%rcx)
movb %al, -0x25(%rbp)
je 0x7b610
movq -0x8(%rbp), %rax
movq 0x68(%rax), %rax
movzwl 0xb8(%rax), %eax
cmpl $0x5c, %eax
setne %al
movb %al, -0x25(%rbp)
movb -0x25(%rbp), %dl
movl $0x5c, %eax
movl $0x2e, %ecx
testb $0x1, %dl
cmovnel %ecx, %eax
movl %eax, -0x24(%rbp)
jmp 0x7b628
cmpl $0x2e, -0x24(%rbp)
jne 0x7b63d
cmpq $0x5c, -0x10(%rbp)
jne 0x7b63d
movq $0x2e, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
movl -0x24(%rbp), %r8d
movl $0x1, %r9d
movl $0x1, (%rsp)
callq 0x7b2a0
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
| my_wc_to_printable_8bit:
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 rcx, [rbp+var_8]
xor eax, eax
cmp qword ptr [rcx+68h], 0
mov [rbp+var_25], al
jz short loc_7B610
mov rax, [rbp+var_8]
mov rax, [rax+68h]
movzx eax, word ptr [rax+0B8h]
cmp eax, 5Ch ; '\'
setnz al
mov [rbp+var_25], al
loc_7B610:
mov dl, [rbp+var_25]
mov eax, 5Ch ; '\'
mov ecx, 2Eh ; '.'
test dl, 1
cmovnz eax, ecx
mov [rbp+var_24], eax
jmp short $+2
loc_7B628:
cmp [rbp+var_24], 2Eh ; '.'
jnz short loc_7B63D
cmp [rbp+var_10], 5Ch ; '\'
jnz short loc_7B63D
mov [rbp+var_10], 2Eh ; '.'
loc_7B63D:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov rcx, [rbp+var_20]
mov r8d, [rbp+var_24]
mov r9d, 1
mov [rsp+30h+var_30], 1
call my_wc_to_printable_ex
add rsp, 30h
pop rbp
retn
| long long my_wc_to_printable_8bit(long long a1, long long a2, long long a3, unsigned long long a4)
{
unsigned int v4; // eax
bool v6; // [rsp+Bh] [rbp-25h]
long long v7; // [rsp+20h] [rbp-10h]
v7 = a2;
v6 = 0;
if ( *(_QWORD *)(a1 + 104) )
v6 = *(unsigned __int16 *)(*(_QWORD *)(a1 + 104) + 184LL) != 92;
v4 = 92;
if ( v6 )
v4 = 46;
if ( v4 == 46 && a2 == 92 )
v7 = 46LL;
return my_wc_to_printable_ex(a1, v7, a3, a4, v4, 1u, 1u);
}
| my_wc_to_printable_8bit:
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 RCX,qword ptr [RBP + -0x8]
XOR EAX,EAX
CMP qword ptr [RCX + 0x68],0x0
MOV byte ptr [RBP + -0x25],AL
JZ 0x0017b610
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x68]
MOVZX EAX,word ptr [RAX + 0xb8]
CMP EAX,0x5c
SETNZ AL
MOV byte ptr [RBP + -0x25],AL
LAB_0017b610:
MOV DL,byte ptr [RBP + -0x25]
MOV EAX,0x5c
MOV ECX,0x2e
TEST DL,0x1
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x24],EAX
JMP 0x0017b628
LAB_0017b628:
CMP dword ptr [RBP + -0x24],0x2e
JNZ 0x0017b63d
CMP qword ptr [RBP + -0x10],0x5c
JNZ 0x0017b63d
MOV qword ptr [RBP + -0x10],0x2e
LAB_0017b63d:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x20]
MOV R8D,dword ptr [RBP + -0x24]
MOV R9D,0x1
MOV dword ptr [RSP],0x1
CALL 0x0017b2a0
ADD RSP,0x30
POP RBP
RET
|
void my_wc_to_printable_8bit(long param_1,long param_2,int8 param_3,int8 param_4)
{
int iVar1;
bool bVar2;
int8 local_18;
bVar2 = false;
if (*(long *)(param_1 + 0x68) != 0) {
bVar2 = *(short *)(*(long *)(param_1 + 0x68) + 0xb8) != 0x5c;
}
iVar1 = 0x5c;
if (bVar2) {
iVar1 = 0x2e;
}
local_18 = param_2;
if ((iVar1 == 0x2e) && (param_2 == 0x5c)) {
local_18 = 0x2e;
}
my_wc_to_printable_ex(param_1,local_18,param_3,param_4,iVar1,1,1);
return;
}
| |
23,376 | js_new_std_file | bluesky950520[P]quickjs/quickjs-libc.c | static JSValue js_new_std_file(JSContext *ctx, FILE *f, BOOL is_popen)
{
JSRuntime *rt = JS_GetRuntime(ctx);
JSThreadState *ts = js_get_thread_state(rt);
JSSTDFile *s;
JSValue obj;
obj = JS_NewObjectClass(ctx, ts->std_file_class_id);
if (JS_IsException(obj))
return obj;
s = js_mallocz(ctx, sizeof(*s));
if (!s) {
JS_FreeValue(ctx, obj);
return JS_EXCEPTION;
}
s->is_popen = is_popen;
s->f = f;
JS_SetOpaque(obj, s);
return obj;
} | O1 | c | js_new_std_file:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %edx, %ebp
movq %rsi, %r15
movq %rdi, %r12
callq 0x1f16a
xorl %edi, %edi
movq %rax, %rsi
xorl %eax, %eax
callq 0x399df
movl 0x78(%rax), %esi
movq %r12, %rdi
callq 0x203a0
movq %rax, %r14
movq %rdx, %rbx
cmpl $0x6, %ebx
je 0x151c0
movl $0x10, %esi
movq %r12, %rdi
callq 0xed7d
testq %rax, %rax
je 0x151e2
movl %ebp, 0x8(%rax)
movq %r15, (%rax)
movq %r14, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x26960
movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000
movq %r14, %rcx
andq %rax, %rcx
movl %r14d, %eax
orq %rcx, %rax
movq %rbx, %rdx
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %r12, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x1cc9f
movl $0x6, %ebx
xorl %r14d, %r14d
xorl %ecx, %ecx
jmp 0x151d0
| js_new_std_file:
push rbp
push r15
push r14
push r12
push rbx
mov ebp, edx
mov r15, rsi
mov r12, rdi
call JS_GetRuntime
xor edi, edi
mov rsi, rax
xor eax, eax
call js_std_cmd
mov esi, [rax+78h]
mov rdi, r12
call JS_NewObjectClass
mov r14, rax
mov rbx, rdx
cmp ebx, 6
jz short loc_151C0
mov esi, 10h
mov rdi, r12
call js_mallocz
test rax, rax
jz short loc_151E2
mov [rax+8], ebp
mov [rax], r15
mov rdi, r14
mov rsi, rbx
mov rdx, rax
call JS_SetOpaque
loc_151C0:
mov rax, 0FFFFFFFF00000000h
mov rcx, r14
and rcx, rax
loc_151D0:
mov eax, r14d
or rax, rcx
mov rdx, rbx
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_151E2:
mov rdi, r12
mov rsi, r14
mov rdx, rbx
call JS_FreeValue
mov ebx, 6
xor r14d, r14d
xor ecx, ecx
jmp short loc_151D0
| unsigned long long js_new_std_file(long long a1, long long a2, int a3)
{
int Runtime; // eax
int v5; // edx
int v6; // ecx
int v7; // r8d
int v8; // r9d
long long v9; // rax
long long v10; // r14
long long v11; // rdx
long long v12; // rbx
long long v13; // rax
unsigned long long v14; // rcx
Runtime = JS_GetRuntime(a1);
v9 = js_std_cmd(0, Runtime, v5, v6, v7, v8);
v10 = JS_NewObjectClass(a1, *(unsigned int *)(v9 + 120));
v12 = v11;
if ( (_DWORD)v11 != 6 )
{
v13 = js_mallocz(a1, 0x10uLL);
if ( !v13 )
{
JS_FreeValue(a1, v10, v12);
LODWORD(v10) = 0;
v14 = 0LL;
return v14 | (unsigned int)v10;
}
*(_DWORD *)(v13 + 8) = a3;
*(_QWORD *)v13 = a2;
JS_SetOpaque(v10, v12, v13);
}
v14 = v10 & 0xFFFFFFFF00000000LL;
return v14 | (unsigned int)v10;
}
| js_new_std_file:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV EBP,EDX
MOV R15,RSI
MOV R12,RDI
CALL 0x0011f16a
XOR EDI,EDI
MOV RSI,RAX
XOR EAX,EAX
CALL 0x001399df
MOV ESI,dword ptr [RAX + 0x78]
MOV RDI,R12
CALL 0x001203a0
MOV R14,RAX
MOV RBX,RDX
CMP EBX,0x6
JZ 0x001151c0
MOV ESI,0x10
MOV RDI,R12
CALL 0x0010ed7d
TEST RAX,RAX
JZ 0x001151e2
MOV dword ptr [RAX + 0x8],EBP
MOV qword ptr [RAX],R15
MOV RDI,R14
MOV RSI,RBX
MOV RDX,RAX
CALL 0x00126960
LAB_001151c0:
MOV RAX,-0x100000000
MOV RCX,R14
AND RCX,RAX
LAB_001151d0:
MOV EAX,R14D
OR RAX,RCX
MOV RDX,RBX
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_001151e2:
MOV RDI,R12
MOV RSI,R14
MOV RDX,RBX
CALL 0x0011cc9f
MOV EBX,0x6
XOR R14D,R14D
XOR ECX,ECX
JMP 0x001151d0
|
int1 [16] js_new_std_file(int8 param_1,int8 param_2,int4 param_3)
{
int8 uVar1;
long lVar2;
int8 *puVar3;
ulong uVar4;
int1 auVar5 [16];
int1 auVar6 [16];
uVar1 = JS_GetRuntime();
lVar2 = js_std_cmd(0,uVar1);
auVar5 = JS_NewObjectClass(param_1,*(int4 *)(lVar2 + 0x78));
uVar4 = auVar5._0_8_;
if (auVar5._8_4_ != 6) {
puVar3 = (int8 *)js_mallocz(param_1,0x10);
if (puVar3 == (int8 *)0x0) {
JS_FreeValue(param_1,uVar4,auVar5._8_8_);
auVar5 = ZEXT816(6) << 0x40;
uVar4 = 0;
goto LAB_001151d0;
}
*(int4 *)(puVar3 + 1) = param_3;
*puVar3 = param_2;
JS_SetOpaque(uVar4,auVar5._8_8_,puVar3);
}
uVar4 = uVar4 & 0xffffffff00000000;
LAB_001151d0:
auVar6._0_8_ = auVar5._0_8_ & 0xffffffff | uVar4;
auVar6._8_8_ = auVar5._8_8_;
return auVar6;
}
| |
23,377 | find_typeset | eloqsql/mysys/typelib.c | my_ulonglong find_typeset(const char *x, TYPELIB *lib, int *err)
{
my_ulonglong result;
int find;
const char *i;
DBUG_ENTER("find_set");
DBUG_PRINT("enter",("x: '%s' lib: %p", x, lib));
if (!lib->count)
{
DBUG_PRINT("exit",("no count"));
DBUG_RETURN(0);
}
result= 0;
*err= 0;
while (*x)
{
(*err)++;
i= x;
while (*x && *x != ',')
x++;
if (x[0] && x[1]) /* skip separator if found */
x++;
if ((find= find_type(i, lib, FIND_TYPE_COMMA_TERM) - 1) < 0)
DBUG_RETURN(0);
result|= (1ULL << find);
}
*err= 0;
DBUG_RETURN(result);
} | O3 | c | find_typeset:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
cmpl $0x0, (%rsi)
je 0x298cb
movq %rdi, %r13
movl $0x0, (%rdx)
cmpb $0x0, (%rdi)
je 0x298d0
movq %rsi, %r14
xorl %r12d, %r12d
xorl %r15d, %r15d
movq %rdx, -0x30(%rbp)
incl %r12d
movl %r12d, (%rdx)
leaq 0x1(%r13), %rax
movzbl -0x1(%rax), %ecx
testl %ecx, %ecx
je 0x2988a
cmpl $0x2c, %ecx
je 0x2987d
incq %rax
jmp 0x2986b
leaq -0x1(%rax), %rbx
cmpb $0x0, (%rax)
cmovneq %rax, %rbx
jmp 0x29890
decq %rax
movq %rax, %rbx
movq %r13, -0x38(%rbp)
movq %r13, %rdi
callq 0x24120
addq %rax, %r13
leaq -0x38(%rbp), %rdi
movq %r14, %rsi
movl $0x8, %edx
movq %r13, %rcx
callq 0x29689
testl %eax, %eax
jle 0x298cb
decb %al
btsq %rax, %r15
cmpb $0x0, (%rbx)
movq %rbx, %r13
movq -0x30(%rbp), %rdx
jne 0x29861
jmp 0x298d3
xorl %r15d, %r15d
jmp 0x298d9
xorl %r15d, %r15d
movl $0x0, (%rdx)
movq %r15, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| find_typeset:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
cmp dword ptr [rsi], 0
jz loc_298CB
mov r13, rdi
mov dword ptr [rdx], 0
cmp byte ptr [rdi], 0
jz short loc_298D0
mov r14, rsi
xor r12d, r12d
xor r15d, r15d
mov [rbp+var_30], rdx
loc_29861:
inc r12d
mov [rdx], r12d
lea rax, [r13+1]
loc_2986B:
movzx ecx, byte ptr [rax-1]
test ecx, ecx
jz short loc_2988A
cmp ecx, 2Ch ; ','
jz short loc_2987D
inc rax
jmp short loc_2986B
loc_2987D:
lea rbx, [rax-1]
cmp byte ptr [rax], 0
cmovnz rbx, rax
jmp short loc_29890
loc_2988A:
dec rax
mov rbx, rax
loc_29890:
mov [rbp+var_38], r13
mov rdi, r13
call _strlen
add r13, rax
lea rdi, [rbp+var_38]
mov rsi, r14
mov edx, 8
mov rcx, r13
call find_type_eol
test eax, eax
jle short loc_298CB
dec al
bts r15, rax
cmp byte ptr [rbx], 0
mov r13, rbx
mov rdx, [rbp+var_30]
jnz short loc_29861
jmp short loc_298D3
loc_298CB:
xor r15d, r15d
jmp short loc_298D9
loc_298D0:
xor r15d, r15d
loc_298D3:
mov dword ptr [rdx], 0
loc_298D9:
mov rax, r15
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long find_typeset(_BYTE *a1, _DWORD *a2, _DWORD *a3)
{
_BYTE *v3; // r13
int v4; // r12d
long long v5; // r15
_BYTE *i; // rax
_BYTE *v7; // rbx
long long v8; // rax
int type_eol; // eax
_BYTE *v11; // [rsp+8h] [rbp-38h] BYREF
_DWORD *v12; // [rsp+10h] [rbp-30h]
if ( !*a2 )
return 0LL;
v3 = a1;
*a3 = 0;
if ( *a1 )
{
v4 = 0;
v5 = 0LL;
v12 = a3;
while ( 1 )
{
*a3 = ++v4;
for ( i = v3 + 1; ; ++i )
{
if ( !*(i - 1) )
{
v7 = i - 1;
goto LABEL_12;
}
if ( *(i - 1) == 44 )
break;
}
v7 = i - 1;
if ( *i )
v7 = i;
LABEL_12:
v11 = v3;
v8 = strlen(v3);
type_eol = find_type_eol(&v11, (long long)a2, 8, &v3[v8]);
if ( type_eol <= 0 )
return 0LL;
v5 |= 1LL << ((unsigned __int8)type_eol - 1);
v3 = v7;
a3 = v12;
if ( !*v7 )
goto LABEL_17;
}
}
v5 = 0LL;
LABEL_17:
*a3 = 0;
return v5;
}
| find_typeset:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
CMP dword ptr [RSI],0x0
JZ 0x001298cb
MOV R13,RDI
MOV dword ptr [RDX],0x0
CMP byte ptr [RDI],0x0
JZ 0x001298d0
MOV R14,RSI
XOR R12D,R12D
XOR R15D,R15D
MOV qword ptr [RBP + -0x30],RDX
LAB_00129861:
INC R12D
MOV dword ptr [RDX],R12D
LEA RAX,[R13 + 0x1]
LAB_0012986b:
MOVZX ECX,byte ptr [RAX + -0x1]
TEST ECX,ECX
JZ 0x0012988a
CMP ECX,0x2c
JZ 0x0012987d
INC RAX
JMP 0x0012986b
LAB_0012987d:
LEA RBX,[RAX + -0x1]
CMP byte ptr [RAX],0x0
CMOVNZ RBX,RAX
JMP 0x00129890
LAB_0012988a:
DEC RAX
MOV RBX,RAX
LAB_00129890:
MOV qword ptr [RBP + -0x38],R13
MOV RDI,R13
CALL 0x00124120
ADD R13,RAX
LEA RDI,[RBP + -0x38]
MOV RSI,R14
MOV EDX,0x8
MOV RCX,R13
CALL 0x00129689
TEST EAX,EAX
JLE 0x001298cb
DEC AL
BTS R15,RAX
CMP byte ptr [RBX],0x0
MOV R13,RBX
MOV RDX,qword ptr [RBP + -0x30]
JNZ 0x00129861
JMP 0x001298d3
LAB_001298cb:
XOR R15D,R15D
JMP 0x001298d9
LAB_001298d0:
XOR R15D,R15D
LAB_001298d3:
MOV dword ptr [RDX],0x0
LAB_001298d9:
MOV RAX,R15
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
ulong find_typeset(char *param_1,int *param_2,int *param_3)
{
int iVar1;
char *pcVar2;
size_t sVar3;
char *pcVar4;
int iVar5;
ulong uVar6;
char *local_40;
int *local_38;
if (*param_2 == 0) {
LAB_001298cb:
uVar6 = 0;
}
else {
*param_3 = 0;
if (*param_1 == '\0') {
uVar6 = 0;
}
else {
iVar5 = 0;
uVar6 = 0;
local_38 = param_3;
do {
iVar5 = iVar5 + 1;
*local_38 = iVar5;
pcVar2 = param_1;
do {
pcVar4 = pcVar2;
pcVar2 = pcVar4 + 1;
if (*pcVar4 == '\0') goto LAB_00129890;
} while (*pcVar4 != ',');
if (*pcVar2 != '\0') {
pcVar4 = pcVar2;
}
LAB_00129890:
local_40 = param_1;
sVar3 = strlen(param_1);
iVar1 = find_type_eol(&local_40,param_2,8,param_1 + sVar3);
if (iVar1 < 1) goto LAB_001298cb;
uVar6 = uVar6 | 1L << ((ulong)(byte)((char)iVar1 - 1) & 0x3f);
param_3 = local_38;
param_1 = pcVar4;
} while (*pcVar4 != '\0');
}
*param_3 = 0;
}
return uVar6;
}
| |
23,378 | R3D_SetMaterialAlbedo | r3d/src/r3d_utils.c | void R3D_SetMaterialAlbedo(Material* material, Texture2D* texture, Color color)
{
if (material == NULL) {
return;
}
MaterialMap* map = &material->maps[MATERIAL_MAP_ALBEDO];
if (texture != NULL) {
map->texture = *texture;
}
else if (map->texture.id == 0) {
map->texture = R3D_GetWhiteTexture();
}
map->color = color;
} | O3 | c | R3D_SetMaterialAlbedo:
testq %rdi, %rdi
je 0xbfbe7
pushq %rbp
movq %rsp, %rbp
movq 0x10(%rdi), %rax
testq %rsi, %rsi
je 0xbfbc4
movl 0x10(%rsi), %ecx
movl %ecx, 0x10(%rax)
movups (%rsi), %xmm0
movups %xmm0, (%rax)
jmp 0xbfbe3
cmpl $0x0, (%rax)
jne 0xbfbe3
leaq 0x102970(%rip), %rcx # 0x1c2540
movl 0x1530(%rcx), %ecx
movl %ecx, (%rax)
movaps 0x239d1(%rip), %xmm0 # 0xe35b0
movups %xmm0, 0x4(%rax)
movl %edx, 0x14(%rax)
popq %rbp
retq
| R3D_SetMaterialAlbedo:
test rdi, rdi
jz short locret_BFBE7
push rbp
mov rbp, rsp
mov rax, [rdi+10h]
test rsi, rsi
jz short loc_BFBC4
mov ecx, [rsi+10h]
mov [rax+10h], ecx
movups xmm0, xmmword ptr [rsi]
movups xmmword ptr [rax], xmm0
jmp short loc_BFBE3
loc_BFBC4:
cmp dword ptr [rax], 0
jnz short loc_BFBE3
lea rcx, R3D
mov ecx, [rcx+1530h]
mov [rax], ecx
movaps xmm0, cs:xmmword_E35B0
movups xmmword ptr [rax+4], xmm0
loc_BFBE3:
mov [rax+14h], edx
pop rbp
locret_BFBE7:
retn
| void R3D_SetMaterialAlbedo(long long a1, long long a2, int a3)
{
long long v3; // rax
if ( a1 )
{
v3 = *(_QWORD *)(a1 + 16);
if ( a2 )
{
*(_DWORD *)(v3 + 16) = *(_DWORD *)(a2 + 16);
*(_OWORD *)v3 = *(_OWORD *)a2;
}
else if ( !*(_DWORD *)v3 )
{
*(_DWORD *)v3 = *((_DWORD *)&R3D + 1356);
*(_OWORD *)(v3 + 4) = xmmword_E35B0;
}
*(_DWORD *)(v3 + 20) = a3;
}
}
| R3D_SetMaterialAlbedo:
TEST RDI,RDI
JZ 0x001bfbe7
PUSH RBP
MOV RBP,RSP
MOV RAX,qword ptr [RDI + 0x10]
TEST RSI,RSI
JZ 0x001bfbc4
MOV ECX,dword ptr [RSI + 0x10]
MOV dword ptr [RAX + 0x10],ECX
MOVUPS XMM0,xmmword ptr [RSI]
MOVUPS xmmword ptr [RAX],XMM0
JMP 0x001bfbe3
LAB_001bfbc4:
CMP dword ptr [RAX],0x0
JNZ 0x001bfbe3
LEA RCX,[0x2c2540]
MOV ECX,dword ptr [RCX + 0x1530]
MOV dword ptr [RAX],ECX
MOVAPS XMM0,xmmword ptr [0x001e35b0]
MOVUPS xmmword ptr [RAX + 0x4],XMM0
LAB_001bfbe3:
MOV dword ptr [RAX + 0x14],EDX
POP RBP
LAB_001bfbe7:
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
void R3D_SetMaterialAlbedo(long param_1,int8 *param_2,int param_3)
{
int *piVar1;
int8 uVar2;
if (param_1 != 0) {
piVar1 = *(int **)(param_1 + 0x10);
if (param_2 == (int8 *)0x0) {
if (*piVar1 == 0) {
*piVar1 = DAT_002c3a70;
uVar2 = _UNK_001e35b8;
*(int8 *)(piVar1 + 1) = _DAT_001e35b0;
*(int8 *)(piVar1 + 3) = uVar2;
}
}
else {
piVar1[4] = *(int *)(param_2 + 2);
uVar2 = param_2[1];
*(int8 *)piVar1 = *param_2;
*(int8 *)(piVar1 + 2) = uVar2;
}
piVar1[5] = param_3;
}
return;
}
| |
23,379 | main | giladroyz[P]FindPeaks/examples/usage_cpp.cpp | int main()
{
std::cout << "===== Basic Example =====\n\n";
basic_example();
std::cout << "=========================\n\n";
std::cout << "===== Medium Example =====\n\n";
medium_example();
std::cout << "==========================\n\n";
std::cout << "===== Advance Example =====\n\n";
advance_example();
std::cout << "===========================\n\n";
} | O2 | cpp | main:
pushq %rbx
movq 0x770e(%rip), %rbx # 0x8fd8
leaq 0x383d(%rip), %rsi # 0x510e
movq %rbx, %rdi
callq 0x10d0
callq 0x126c
leaq 0x3882(%rip), %rsi # 0x5167
movq %rbx, %rdi
callq 0x10d0
leaq 0x3836(%rip), %rsi # 0x512a
movq %rbx, %rdi
callq 0x10d0
callq 0x1453
leaq 0x385e(%rip), %rsi # 0x5166
movq %rbx, %rdi
callq 0x10d0
leaq 0x3830(%rip), %rsi # 0x5147
movq %rbx, %rdi
callq 0x10d0
callq 0x1664
leaq 0x383a(%rip), %rsi # 0x5165
movq %rbx, %rdi
callq 0x10d0
xorl %eax, %eax
popq %rbx
retq
nop
| main:
push rbx
mov rbx, cs:_ZSt4cout_ptr
lea rsi, aBasicExample; "===== Basic Example =====\n\n"
mov rdi, rbx
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
call _Z13basic_examplev; basic_example(void)
lea rsi, asc_5165+2; "=========================\n\n"
mov rdi, rbx
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
lea rsi, aMediumExample; "===== Medium Example =====\n\n"
mov rdi, rbx
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
call _Z14medium_examplev; medium_example(void)
lea rsi, asc_5165+1; "==========================\n\n"
mov rdi, rbx
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
lea rsi, aAdvanceExample; "===== Advance Example =====\n\n"
mov rdi, rbx
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
call _Z15advance_examplev; advance_example(void)
lea rsi, asc_5165; "===========================\n\n"
mov rdi, rbx
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
xor eax, eax
pop rbx
retn
| int main(int argc, const char **argv, const char **envp)
{
long long v3; // rdx
long long v4; // rdx
long long v5; // rdx
long long v6; // rdx
long long v7; // rdx
std::operator<<<std::char_traits<char>>(&std::cout, "===== Basic Example =====\n\n", envp);
basic_example();
std::operator<<<std::char_traits<char>>(&std::cout, "=========================\n\n", v3);
std::operator<<<std::char_traits<char>>(&std::cout, "===== Medium Example =====\n\n", v4);
medium_example();
std::operator<<<std::char_traits<char>>(&std::cout, "==========================\n\n", v5);
std::operator<<<std::char_traits<char>>(&std::cout, "===== Advance Example =====\n\n", v6);
advance_example();
std::operator<<<std::char_traits<char>>(&std::cout, "===========================\n\n", v7);
return 0;
}
| main:
PUSH RBX
MOV RBX,qword ptr [0x00108fd8]
LEA RSI,[0x10510e]
MOV RDI,RBX
CALL 0x001010d0
CALL 0x0010126c
LEA RSI,[0x105167]
MOV RDI,RBX
CALL 0x001010d0
LEA RSI,[0x10512a]
MOV RDI,RBX
CALL 0x001010d0
CALL 0x00101453
LEA RSI,[0x105166]
MOV RDI,RBX
CALL 0x001010d0
LEA RSI,[0x105147]
MOV RDI,RBX
CALL 0x001010d0
CALL 0x00101664
LEA RSI,[0x105165]
MOV RDI,RBX
CALL 0x001010d0
XOR EAX,EAX
POP RBX
RET
|
int8 main(void)
{
int *puVar1;
puVar1 = PTR_cout_00108fd8;
std::operator<<((ostream *)PTR_cout_00108fd8,"===== Basic Example =====\n\n");
basic_example();
std::operator<<((ostream *)puVar1,"=========================\n\n");
std::operator<<((ostream *)puVar1,"===== Medium Example =====\n\n");
medium_example();
std::operator<<((ostream *)puVar1,"==========================\n\n");
std::operator<<((ostream *)puVar1,"===== Advance Example =====\n\n");
advance_example();
std::operator<<((ostream *)puVar1,"===========================\n\n");
return 0;
}
| |
23,380 | ModelLoader::init_from_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | 7CodeWizard[P]stablediffusion/model.cpp | bool ModelLoader::init_from_file(const std::string& file_path, const std::string& prefix) {
if (is_directory(file_path)) {
LOG_INFO("load %s using diffusers format", file_path.c_str());
return init_from_diffusers_file(file_path, prefix);
} else if (is_gguf_file(file_path)) {
LOG_INFO("load %s using gguf format", file_path.c_str());
return init_from_gguf_file(file_path, prefix);
} else if (is_safetensors_file(file_path)) {
LOG_INFO("load %s using safetensors format", file_path.c_str());
return init_from_safetensors_file(file_path, prefix);
} else if (is_zip_file(file_path)) {
LOG_INFO("load %s using checkpoint format", file_path.c_str());
return init_from_ckpt_file(file_path, prefix);
} else {
LOG_WARN("unknown format %s", file_path.c_str());
return false;
}
} | O0 | cpp | ModelLoader::init_from_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq %rsi, 0x10(%rsp)
movq %rdx, 0x8(%rsp)
movq 0x18(%rsp), %rax
movq %rax, (%rsp)
movq 0x10(%rsp), %rdi
callq 0xeac00
testb $0x1, %al
jne 0xbbd6c
jmp 0xbbdb6
movq 0x10(%rsp), %rdi
callq 0xb280
movq %rax, %r8
movl $0x1, %edi
leaq 0xc80de(%rip), %rsi # 0x183e63
movl $0x27b, %edx # imm = 0x27B
leaq 0xc8122(%rip), %rcx # 0x183eb3
movb $0x0, %al
callq 0xeb5e0
movq (%rsp), %rdi
movq 0x10(%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0xbbf00
andb $0x1, %al
movb %al, 0x27(%rsp)
jmp 0xbbef2
movq 0x10(%rsp), %rdi
callq 0xbb850
testb $0x1, %al
jne 0xbbdc6
jmp 0xbbe10
movq 0x10(%rsp), %rdi
callq 0xb280
movq %rax, %r8
movl $0x1, %edi
leaq 0xc8084(%rip), %rsi # 0x183e63
movl $0x27e, %edx # imm = 0x27E
leaq 0xc80e7(%rip), %rcx # 0x183ed2
movb $0x0, %al
callq 0xeb5e0
movq (%rsp), %rdi
movq 0x10(%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0xbc460
andb $0x1, %al
movb %al, 0x27(%rsp)
jmp 0xbbef2
movq 0x10(%rsp), %rdi
callq 0xbb9a0
testb $0x1, %al
jne 0xbbe20
jmp 0xbbe6a
movq 0x10(%rsp), %rdi
callq 0xb280
movq %rax, %r8
movl $0x1, %edi
leaq 0xc802a(%rip), %rsi # 0x183e63
movl $0x281, %edx # imm = 0x281
leaq 0xc80a7(%rip), %rcx # 0x183eec
movb $0x0, %al
callq 0xeb5e0
movq (%rsp), %rdi
movq 0x10(%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0xbc8d0
andb $0x1, %al
movb %al, 0x27(%rsp)
jmp 0xbbef2
movq 0x10(%rsp), %rdi
callq 0xbb800
testb $0x1, %al
jne 0xbbe7a
jmp 0xbbec1
movq 0x10(%rsp), %rdi
callq 0xb280
movq %rax, %r8
movl $0x1, %edi
leaq 0xc7fd0(%rip), %rsi # 0x183e63
movl $0x284, %edx # imm = 0x284
leaq 0xc806e(%rip), %rcx # 0x183f0d
movb $0x0, %al
callq 0xeb5e0
movq (%rsp), %rdi
movq 0x10(%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0xbd600
andb $0x1, %al
movb %al, 0x27(%rsp)
jmp 0xbbef2
movq 0x10(%rsp), %rdi
callq 0xb280
movq %rax, %r8
movl $0x2, %edi
leaq 0xc7f89(%rip), %rsi # 0x183e63
movl $0x287, %edx # imm = 0x287
leaq 0xc8047(%rip), %rcx # 0x183f2d
movb $0x0, %al
callq 0xeb5e0
movb $0x0, 0x27(%rsp)
movb 0x27(%rsp), %al
andb $0x1, %al
addq $0x28, %rsp
retq
nopl (%rax)
| _ZN11ModelLoader14init_from_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_:
sub rsp, 28h
mov [rsp+28h+var_10], rdi
mov [rsp+28h+var_18], rsi
mov [rsp+28h+var_20], rdx
mov rax, [rsp+28h+var_10]
mov [rsp+28h+var_28], rax
mov rdi, [rsp+28h+var_18]
call _Z12is_directoryRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_directory(std::string const&)
test al, 1
jnz short loc_BBD6C
jmp short loc_BBDB6
loc_BBD6C:
mov rdi, [rsp+28h+var_18]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov r8, rax
mov edi, 1
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
mov edx, 27Bh
lea rcx, aLoadSUsingDiff; "load %s using diffusers format"
mov al, 0
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, [rsp+28h+var_28]
mov rsi, [rsp+28h+var_18]
mov rdx, [rsp+28h+var_20]
call _ZN11ModelLoader24init_from_diffusers_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_diffusers_file(std::string const&,std::string const&)
and al, 1
mov [rsp+28h+var_1], al
jmp loc_BBEF2
loc_BBDB6:
mov rdi, [rsp+28h+var_18]
call _Z12is_gguf_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_gguf_file(std::string const&)
test al, 1
jnz short loc_BBDC6
jmp short loc_BBE10
loc_BBDC6:
mov rdi, [rsp+28h+var_18]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov r8, rax
mov edi, 1
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
mov edx, 27Eh
lea rcx, aLoadSUsingGguf; "load %s using gguf format"
mov al, 0
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, [rsp+28h+var_28]
mov rsi, [rsp+28h+var_18]
mov rdx, [rsp+28h+var_20]
call _ZN11ModelLoader19init_from_gguf_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_gguf_file(std::string const&,std::string const&)
and al, 1
mov [rsp+28h+var_1], al
jmp loc_BBEF2
loc_BBE10:
mov rdi, [rsp+28h+var_18]
call _Z19is_safetensors_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_safetensors_file(std::string const&)
test al, 1
jnz short loc_BBE20
jmp short loc_BBE6A
loc_BBE20:
mov rdi, [rsp+28h+var_18]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov r8, rax
mov edi, 1
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
mov edx, 281h
lea rcx, aLoadSUsingSafe; "load %s using safetensors format"
mov al, 0
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, [rsp+28h+var_28]
mov rsi, [rsp+28h+var_18]
mov rdx, [rsp+28h+var_20]
call _ZN11ModelLoader26init_from_safetensors_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_safetensors_file(std::string const&,std::string const&)
and al, 1
mov [rsp+28h+var_1], al
jmp loc_BBEF2
loc_BBE6A:
mov rdi, [rsp+28h+var_18]
call _Z11is_zip_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_zip_file(std::string const&)
test al, 1
jnz short loc_BBE7A
jmp short loc_BBEC1
loc_BBE7A:
mov rdi, [rsp+28h+var_18]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov r8, rax
mov edi, 1
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
mov edx, 284h
lea rcx, aLoadSUsingChec; "load %s using checkpoint format"
mov al, 0
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, [rsp+28h+var_28]
mov rsi, [rsp+28h+var_18]
mov rdx, [rsp+28h+var_20]
call _ZN11ModelLoader19init_from_ckpt_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_ckpt_file(std::string const&,std::string const&)
and al, 1
mov [rsp+28h+var_1], al
jmp short loc_BBEF2
loc_BBEC1:
mov rdi, [rsp+28h+var_18]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov r8, rax
mov edi, 2
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
mov edx, 287h
lea rcx, aUnknownFormatS; "unknown format %s"
mov al, 0
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov [rsp+28h+var_1], 0
loc_BBEF2:
mov al, [rsp+28h+var_1]
and al, 1
add rsp, 28h
retn
| init_from_file:
SUB RSP,0x28
MOV qword ptr [RSP + 0x18],RDI
MOV qword ptr [RSP + 0x10],RSI
MOV qword ptr [RSP + 0x8],RDX
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP],RAX
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x001eac00
TEST AL,0x1
JNZ 0x001bbd6c
JMP 0x001bbdb6
LAB_001bbd6c:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x0010b280
MOV R8,RAX
MOV EDI,0x1
LEA RSI,[0x283e63]
MOV EDX,0x27b
LEA RCX,[0x283eb3]
MOV AL,0x0
CALL 0x001eb5e0
MOV RDI,qword ptr [RSP]
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RSP + 0x8]
CALL 0x001bbf00
AND AL,0x1
MOV byte ptr [RSP + 0x27],AL
JMP 0x001bbef2
LAB_001bbdb6:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x001bb850
TEST AL,0x1
JNZ 0x001bbdc6
JMP 0x001bbe10
LAB_001bbdc6:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x0010b280
MOV R8,RAX
MOV EDI,0x1
LEA RSI,[0x283e63]
MOV EDX,0x27e
LEA RCX,[0x283ed2]
MOV AL,0x0
CALL 0x001eb5e0
MOV RDI,qword ptr [RSP]
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RSP + 0x8]
CALL 0x001bc460
AND AL,0x1
MOV byte ptr [RSP + 0x27],AL
JMP 0x001bbef2
LAB_001bbe10:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x001bb9a0
TEST AL,0x1
JNZ 0x001bbe20
JMP 0x001bbe6a
LAB_001bbe20:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x0010b280
MOV R8,RAX
MOV EDI,0x1
LEA RSI,[0x283e63]
MOV EDX,0x281
LEA RCX,[0x283eec]
MOV AL,0x0
CALL 0x001eb5e0
MOV RDI,qword ptr [RSP]
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RSP + 0x8]
CALL 0x001bc8d0
AND AL,0x1
MOV byte ptr [RSP + 0x27],AL
JMP 0x001bbef2
LAB_001bbe6a:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x001bb800
TEST AL,0x1
JNZ 0x001bbe7a
JMP 0x001bbec1
LAB_001bbe7a:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x0010b280
MOV R8,RAX
MOV EDI,0x1
LEA RSI,[0x283e63]
MOV EDX,0x284
LEA RCX,[0x283f0d]
MOV AL,0x0
CALL 0x001eb5e0
MOV RDI,qword ptr [RSP]
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RSP + 0x8]
CALL 0x001bd600
AND AL,0x1
MOV byte ptr [RSP + 0x27],AL
JMP 0x001bbef2
LAB_001bbec1:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x0010b280
MOV R8,RAX
MOV EDI,0x2
LEA RSI,[0x283e63]
MOV EDX,0x287
LEA RCX,[0x283f2d]
MOV AL,0x0
CALL 0x001eb5e0
MOV byte ptr [RSP + 0x27],0x0
LAB_001bbef2:
MOV AL,byte ptr [RSP + 0x27]
AND AL,0x1
ADD RSP,0x28
RET
|
/* ModelLoader::init_from_file(std::__cxx11::string const&, std::__cxx11::string const&) */
byte __thiscall ModelLoader::init_from_file(ModelLoader *this,string *param_1,string *param_2)
{
ulong uVar1;
int8 uVar2;
byte local_1;
uVar1 = is_directory(param_1);
if ((uVar1 & 1) == 0) {
uVar1 = is_gguf_file(param_1);
if ((uVar1 & 1) == 0) {
uVar1 = is_safetensors_file(param_1);
if ((uVar1 & 1) == 0) {
uVar1 = is_zip_file(param_1);
if ((uVar1 & 1) == 0) {
uVar2 = std::__cxx11::string::c_str();
log_printf(2,
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp"
,0x287,"unknown format %s",uVar2);
local_1 = 0;
}
else {
uVar2 = std::__cxx11::string::c_str();
log_printf(1,
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp"
,0x284,"load %s using checkpoint format",uVar2);
local_1 = init_from_ckpt_file(this,param_1,param_2);
local_1 = local_1 & 1;
}
}
else {
uVar2 = std::__cxx11::string::c_str();
log_printf(1,
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp"
,0x281,"load %s using safetensors format",uVar2);
local_1 = init_from_safetensors_file(this,param_1,param_2);
local_1 = local_1 & 1;
}
}
else {
uVar2 = std::__cxx11::string::c_str();
log_printf(1,"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp"
,0x27e,"load %s using gguf format",uVar2);
local_1 = init_from_gguf_file(this,param_1,param_2);
local_1 = local_1 & 1;
}
}
else {
uVar2 = std::__cxx11::string::c_str();
log_printf(1,"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
0x27b,"load %s using diffusers format",uVar2);
local_1 = init_from_diffusers_file(this,param_1,param_2);
local_1 = local_1 & 1;
}
return local_1;
}
| ||
23,381 | ModelLoader::init_from_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | 7CodeWizard[P]stablediffusion/model.cpp | bool ModelLoader::init_from_file(const std::string& file_path, const std::string& prefix) {
if (is_directory(file_path)) {
LOG_INFO("load %s using diffusers format", file_path.c_str());
return init_from_diffusers_file(file_path, prefix);
} else if (is_gguf_file(file_path)) {
LOG_INFO("load %s using gguf format", file_path.c_str());
return init_from_gguf_file(file_path, prefix);
} else if (is_safetensors_file(file_path)) {
LOG_INFO("load %s using safetensors format", file_path.c_str());
return init_from_safetensors_file(file_path, prefix);
} else if (is_zip_file(file_path)) {
LOG_INFO("load %s using checkpoint format", file_path.c_str());
return init_from_ckpt_file(file_path, prefix);
} else {
LOG_WARN("unknown format %s", file_path.c_str());
return false;
}
} | O2 | cpp | ModelLoader::init_from_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x55a58
testb %al, %al
je 0x4757a
movq (%rbx), %r8
leaq 0x5678f(%rip), %rsi # 0x9dce3
leaq 0x567d8(%rip), %rcx # 0x9dd33
pushq $0x1
popq %rdi
movl $0x27b, %edx # imm = 0x27B
xorl %eax, %eax
callq 0x55f59
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x47656
movq %rbx, %rdi
callq 0x47314
testb %al, %al
je 0x475b9
movq (%rbx), %r8
leaq 0x56753(%rip), %rsi # 0x9dce3
leaq 0x567bb(%rip), %rcx # 0x9dd52
pushq $0x1
popq %rdi
movl $0x27e, %edx # imm = 0x27E
xorl %eax, %eax
callq 0x55f59
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x47840
movq %rbx, %rdi
callq 0x473af
testb %al, %al
je 0x475f8
movq (%rbx), %r8
leaq 0x56714(%rip), %rsi # 0x9dce3
leaq 0x56796(%rip), %rcx # 0x9dd6c
pushq $0x1
popq %rdi
movl $0x281, %edx # imm = 0x281
xorl %eax, %eax
callq 0x55f59
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x47aae
movq %rbx, %rdi
callq 0x472ee
movq (%rbx), %r8
leaq 0x566d9(%rip), %rsi # 0x9dce3
testb %al, %al
je 0x47637
leaq 0x56778(%rip), %rcx # 0x9dd8d
pushq $0x1
popq %rdi
movl $0x284, %edx # imm = 0x284
xorl %eax, %eax
callq 0x55f59
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x48230
leaq 0x5676f(%rip), %rcx # 0x9ddad
pushq $0x2
popq %rdi
movl $0x287, %edx # imm = 0x287
xorl %eax, %eax
callq 0x55f59
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
nop
| _ZN11ModelLoader14init_from_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_:
push r15
push r14
push rbx
mov r15, rdx
mov rbx, rsi
mov r14, rdi
mov rdi, rsi
call _Z12is_directoryRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_directory(std::string const&)
test al, al
jz short loc_4757A
mov r8, [rbx]
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aLoadSUsingDiff; "load %s using diffusers format"
push 1
pop rdi
mov edx, 27Bh
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, r14
mov rsi, rbx
pop rbx
pop r14
pop r15
jmp _ZN11ModelLoader24init_from_diffusers_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_diffusers_file(std::string const&,std::string const&)
loc_4757A:
mov rdi, rbx
call _Z12is_gguf_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_gguf_file(std::string const&)
test al, al
jz short loc_475B9
mov r8, [rbx]
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aLoadSUsingGguf; "load %s using gguf format"
push 1
pop rdi
mov edx, 27Eh
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, r14
mov rsi, rbx
mov rdx, r15
pop rbx
pop r14
pop r15
jmp _ZN11ModelLoader19init_from_gguf_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_gguf_file(std::string const&,std::string const&)
loc_475B9:
mov rdi, rbx
call _Z19is_safetensors_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_safetensors_file(std::string const&)
test al, al
jz short loc_475F8
mov r8, [rbx]
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aLoadSUsingSafe; "load %s using safetensors format"
push 1
pop rdi
mov edx, 281h
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, r14
mov rsi, rbx
mov rdx, r15
pop rbx
pop r14
pop r15
jmp _ZN11ModelLoader26init_from_safetensors_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_safetensors_file(std::string const&,std::string const&)
loc_475F8:
mov rdi, rbx
call _Z11is_zip_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_zip_file(std::string const&)
mov r8, [rbx]
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
test al, al
jz short loc_47637
lea rcx, aLoadSUsingChec; "load %s using checkpoint format"
push 1
pop rdi
mov edx, 284h
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, r14
mov rsi, rbx
mov rdx, r15
pop rbx
pop r14
pop r15
jmp _ZN11ModelLoader19init_from_ckpt_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_ckpt_file(std::string const&,std::string const&)
loc_47637:
lea rcx, aUnknownFormatS; "unknown format %s"
push 2
pop rdi
mov edx, 287h
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
xor eax, eax
pop rbx
pop r14
pop r15
retn
| long long ModelLoader::init_from_file(
long long a1,
long long *a2,
long long a3,
long long a4,
long long a5,
long long a6,
int a7,
int a8,
int a9,
int a10,
int a11,
int a12,
int a13,
int a14,
int a15,
int a16,
int a17,
int a18,
int a19,
int a20,
char a21)
{
int v22; // r9d
int v23; // edx
int v24; // ecx
int v25; // r8d
int v26; // r9d
int v28; // r9d
int v29; // r9d
bool v30; // al
int v31; // r9d
long long v32; // r8
int v33; // ecx
int v34; // r8d
int v35; // r9d
if ( (unsigned __int8)is_directory(a2) )
{
log_printf(
1,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
635,
(unsigned int)"load %s using diffusers format",
*a2,
v22);
return ModelLoader::init_from_diffusers_file(
a1,
(_DWORD)a2,
v23,
v24,
v25,
v26,
a7,
a8,
a9,
a10,
a11,
a12,
a13,
a14,
a15,
a16,
a17,
a18,
a19,
a20);
}
else if ( (unsigned __int8)is_gguf_file((long long)a2) )
{
log_printf(
1,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
638,
(unsigned int)"load %s using gguf format",
*a2,
v28);
return ModelLoader::init_from_gguf_file(a1, a2, a3);
}
else if ( (unsigned __int8)is_safetensors_file((long long)a2) )
{
log_printf(
1,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
641,
(unsigned int)"load %s using safetensors format",
*a2,
v29);
return ModelLoader::init_from_safetensors_file(a1, a2, a3);
}
else
{
v30 = is_zip_file(a2);
v32 = *a2;
if ( v30 )
{
log_printf(
1,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
644,
(unsigned int)"load %s using checkpoint format",
v32,
v31);
return ModelLoader::init_from_ckpt_file(
a1,
(_DWORD)a2,
a3,
v33,
v34,
v35,
a7,
a8,
a9,
a10,
a11,
a12,
a13,
a14,
a15,
a16,
a17,
a18,
a19,
a20,
a21);
}
else
{
log_printf(
2,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
647,
(unsigned int)"unknown format %s",
v32,
v31);
return 0LL;
}
}
}
| init_from_file:
PUSH R15
PUSH R14
PUSH RBX
MOV R15,RDX
MOV RBX,RSI
MOV R14,RDI
MOV RDI,RSI
CALL 0x00155a58
TEST AL,AL
JZ 0x0014757a
MOV R8,qword ptr [RBX]
LEA RSI,[0x19dce3]
LEA RCX,[0x19dd33]
PUSH 0x1
POP RDI
MOV EDX,0x27b
XOR EAX,EAX
CALL 0x00155f59
MOV RDI,R14
MOV RSI,RBX
POP RBX
POP R14
POP R15
JMP 0x00147656
LAB_0014757a:
MOV RDI,RBX
CALL 0x00147314
TEST AL,AL
JZ 0x001475b9
MOV R8,qword ptr [RBX]
LEA RSI,[0x19dce3]
LEA RCX,[0x19dd52]
PUSH 0x1
POP RDI
MOV EDX,0x27e
XOR EAX,EAX
CALL 0x00155f59
MOV RDI,R14
MOV RSI,RBX
MOV RDX,R15
POP RBX
POP R14
POP R15
JMP 0x00147840
LAB_001475b9:
MOV RDI,RBX
CALL 0x001473af
TEST AL,AL
JZ 0x001475f8
MOV R8,qword ptr [RBX]
LEA RSI,[0x19dce3]
LEA RCX,[0x19dd6c]
PUSH 0x1
POP RDI
MOV EDX,0x281
XOR EAX,EAX
CALL 0x00155f59
MOV RDI,R14
MOV RSI,RBX
MOV RDX,R15
POP RBX
POP R14
POP R15
JMP 0x00147aae
LAB_001475f8:
MOV RDI,RBX
CALL 0x001472ee
MOV R8,qword ptr [RBX]
LEA RSI,[0x19dce3]
TEST AL,AL
JZ 0x00147637
LEA RCX,[0x19dd8d]
PUSH 0x1
POP RDI
MOV EDX,0x284
XOR EAX,EAX
CALL 0x00155f59
MOV RDI,R14
MOV RSI,RBX
MOV RDX,R15
POP RBX
POP R14
POP R15
JMP 0x00148230
LAB_00147637:
LEA RCX,[0x19ddad]
PUSH 0x2
POP RDI
MOV EDX,0x287
XOR EAX,EAX
CALL 0x00155f59
XOR EAX,EAX
POP RBX
POP R14
POP R15
RET
|
/* ModelLoader::init_from_file(std::__cxx11::string const&, std::__cxx11::string const&) */
int8 __thiscall ModelLoader::init_from_file(ModelLoader *this,string *param_1,string *param_2)
{
char cVar1;
int8 uVar2;
cVar1 = is_directory(param_1);
if (cVar1 != '\0') {
log_printf(1,"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
0x27b,"load %s using diffusers format",*(int8 *)param_1);
uVar2 = init_from_diffusers_file((string *)this,param_1);
return uVar2;
}
cVar1 = is_gguf_file(param_1);
if (cVar1 != '\0') {
log_printf(1,"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
0x27e,"load %s using gguf format",*(int8 *)param_1);
uVar2 = init_from_gguf_file(this,param_1,param_2);
return uVar2;
}
cVar1 = is_safetensors_file(param_1);
if (cVar1 != '\0') {
log_printf(1,"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
0x281,"load %s using safetensors format",*(int8 *)param_1);
uVar2 = init_from_safetensors_file(this,param_1,param_2);
return uVar2;
}
cVar1 = is_zip_file(param_1);
if (cVar1 != '\0') {
log_printf(1,"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
0x284,"load %s using checkpoint format",*(int8 *)param_1);
uVar2 = init_from_ckpt_file(this,param_1,param_2);
return uVar2;
}
log_printf(2,"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
0x287,"unknown format %s",*(int8 *)param_1);
return 0;
}
| |
23,382 | ModelLoader::init_from_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | 7CodeWizard[P]stablediffusion/model.cpp | bool ModelLoader::init_from_file(const std::string& file_path, const std::string& prefix) {
if (is_directory(file_path)) {
LOG_INFO("load %s using diffusers format", file_path.c_str());
return init_from_diffusers_file(file_path, prefix);
} else if (is_gguf_file(file_path)) {
LOG_INFO("load %s using gguf format", file_path.c_str());
return init_from_gguf_file(file_path, prefix);
} else if (is_safetensors_file(file_path)) {
LOG_INFO("load %s using safetensors format", file_path.c_str());
return init_from_safetensors_file(file_path, prefix);
} else if (is_zip_file(file_path)) {
LOG_INFO("load %s using checkpoint format", file_path.c_str());
return init_from_ckpt_file(file_path, prefix);
} else {
LOG_WARN("unknown format %s", file_path.c_str());
return false;
}
} | O3 | cpp | ModelLoader::init_from_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x78c47
testb %al, %al
je 0x67f60
movq (%rbx), %r8
leaq 0x58eab(%rip), %rsi # 0xc0de3
leaq 0x58ef4(%rip), %rcx # 0xc0e33
movl $0x1, %edi
movl $0x27b, %edx # imm = 0x27B
xorl %eax, %eax
callq 0x7947e
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x68044
movq %rbx, %rdi
callq 0x67ca2
testb %al, %al
je 0x67fa1
movq (%rbx), %r8
leaq 0x58e6d(%rip), %rsi # 0xc0de3
leaq 0x58ed5(%rip), %rcx # 0xc0e52
movl $0x1, %edi
movl $0x27e, %edx # imm = 0x27E
xorl %eax, %eax
callq 0x7947e
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x6833e
movq %rbx, %rdi
callq 0x67d41
testb %al, %al
je 0x67fe2
movq (%rbx), %r8
leaq 0x58e2c(%rip), %rsi # 0xc0de3
leaq 0x58eae(%rip), %rcx # 0xc0e6c
movl $0x1, %edi
movl $0x281, %edx # imm = 0x281
xorl %eax, %eax
callq 0x7947e
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x6868e
movq %rbx, %rdi
callq 0x67c7a
movq (%rbx), %r8
leaq 0x58def(%rip), %rsi # 0xc0de3
testb %al, %al
je 0x68023
leaq 0x58e8e(%rip), %rcx # 0xc0e8d
movl $0x1, %edi
movl $0x284, %edx # imm = 0x284
xorl %eax, %eax
callq 0x7947e
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x691c2
leaq 0x58e83(%rip), %rcx # 0xc0ead
movl $0x2, %edi
movl $0x287, %edx # imm = 0x287
xorl %eax, %eax
callq 0x7947e
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
nop
| _ZN11ModelLoader14init_from_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_:
push r15
push r14
push rbx
mov r15, rdx
mov rbx, rsi
mov r14, rdi
mov rdi, rsi
call _Z12is_directoryRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_directory(std::string const&)
test al, al
jz short loc_67F60
mov r8, [rbx]
lea rsi, aWorkspaceLlm4b_7; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aLoadSUsingDiff; "load %s using diffusers format"
mov edi, 1
mov edx, 27Bh
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, r14
mov rsi, rbx
pop rbx
pop r14
pop r15
jmp _ZN11ModelLoader24init_from_diffusers_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_diffusers_file(std::string const&,std::string const&)
loc_67F60:
mov rdi, rbx
call _Z12is_gguf_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_gguf_file(std::string const&)
test al, al
jz short loc_67FA1
mov r8, [rbx]
lea rsi, aWorkspaceLlm4b_7; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aLoadSUsingGguf; "load %s using gguf format"
mov edi, 1
mov edx, 27Eh
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, r14
mov rsi, rbx
mov rdx, r15
pop rbx
pop r14
pop r15
jmp _ZN11ModelLoader19init_from_gguf_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_gguf_file(std::string const&,std::string const&)
loc_67FA1:
mov rdi, rbx
call _Z19is_safetensors_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_safetensors_file(std::string const&)
test al, al
jz short loc_67FE2
mov r8, [rbx]
lea rsi, aWorkspaceLlm4b_7; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aLoadSUsingSafe; "load %s using safetensors format"
mov edi, 1
mov edx, 281h
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, r14
mov rsi, rbx
mov rdx, r15
pop rbx
pop r14
pop r15
jmp _ZN11ModelLoader26init_from_safetensors_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_safetensors_file(std::string const&,std::string const&)
loc_67FE2:
mov rdi, rbx
call _Z11is_zip_fileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; is_zip_file(std::string const&)
mov r8, [rbx]
lea rsi, aWorkspaceLlm4b_7; "/workspace/llm4binary/github/2025_star3"...
test al, al
jz short loc_68023
lea rcx, aLoadSUsingChec; "load %s using checkpoint format"
mov edi, 1
mov edx, 284h
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
mov rdi, r14; int
mov rsi, rbx
mov rdx, r15
pop rbx
pop r14
pop r15
jmp _ZN11ModelLoader19init_from_ckpt_fileERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; ModelLoader::init_from_ckpt_file(std::string const&,std::string const&)
loc_68023:
lea rcx, aUnknownFormatS; "unknown format %s"
mov edi, 2
mov edx, 287h
xor eax, eax
call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...)
xor eax, eax
pop rbx
pop r14
pop r15
retn
| long long ModelLoader::init_from_file(
long long a1,
long long *a2,
long long a3,
long long a4,
long long a5,
long long a6,
int a7,
int a8,
void *a9,
int a10,
long long a11,
int a12,
void *a13,
int a14,
long long a15,
int a16,
int a17,
int a18,
int a19,
int a20,
void *a21,
int a22,
long long a23)
{
int v24; // r9d
int v26; // r9d
int v27; // r9d
bool v28; // al
int v29; // r9d
long long v30; // r8
if ( (unsigned __int8)is_directory(a2) )
{
log_printf(
1,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
635,
(unsigned int)"load %s using diffusers format",
*a2,
v24);
return ModelLoader::init_from_diffusers_file(a1, a2);
}
else if ( (unsigned __int8)is_gguf_file((long long)a2) )
{
log_printf(
1,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
638,
(unsigned int)"load %s using gguf format",
*a2,
v26);
return ModelLoader::init_from_gguf_file(a1, a2, a3);
}
else if ( (unsigned __int8)is_safetensors_file((long long)a2) )
{
log_printf(
1,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
641,
(unsigned int)"load %s using safetensors format",
*a2,
v27);
return ModelLoader::init_from_safetensors_file(a1, a2, a3);
}
else
{
v28 = is_zip_file(a2);
v30 = *a2;
if ( v28 )
{
log_printf(
1,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
644,
(unsigned int)"load %s using checkpoint format",
v30,
v29);
return ModelLoader::init_from_ckpt_file(
a1,
a7,
a8,
a9,
a10,
a11,
a12,
a13,
a14,
a15,
a16,
a17,
a18,
a19,
a20,
a21,
a22,
a23);
}
else
{
log_printf(
2,
(unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/model.cpp",
647,
(unsigned int)"unknown format %s",
v30,
v29);
return 0LL;
}
}
}
| |||
23,383 | maria_page_get_lsn | eloqsql/storage/maria/ma_blockrec.c | TRANSLOG_ADDRESS
maria_page_get_lsn(uchar *page,
pgcache_page_no_t page_no __attribute__((unused)),
uchar* data_ptr __attribute__((unused)))
{
#ifndef DBUG_OFF
const MARIA_SHARE *share= (MARIA_SHARE*)data_ptr;
DBUG_ASSERT(share->page_type == PAGECACHE_LSN_PAGE &&
share->now_transactional);
#endif
return lsn_korr(page);
} | O3 | c | maria_page_get_lsn:
pushq %rbp
movq %rsp, %rbp
movzwl (%rdi), %eax
shlq $0x20, %rax
movzbl 0x2(%rdi), %ecx
shlq $0x30, %rcx
orq %rax, %rcx
movl 0x3(%rdi), %eax
orq %rcx, %rax
popq %rbp
retq
| maria_page_get_lsn:
push rbp
mov rbp, rsp
movzx eax, word ptr [rdi]
shl rax, 20h
movzx ecx, byte ptr [rdi+2]
shl rcx, 30h
or rcx, rax
mov eax, [rdi+3]
or rax, rcx
pop rbp
retn
| unsigned long long maria_page_get_lsn(unsigned __int16 *a1)
{
return ((unsigned long long)*a1 << 32) | ((unsigned long long)*((unsigned __int8 *)a1 + 2) << 48) | *(unsigned int *)((char *)a1 + 3);
}
| maria_page_get_lsn:
PUSH RBP
MOV RBP,RSP
MOVZX EAX,word ptr [RDI]
SHL RAX,0x20
MOVZX ECX,byte ptr [RDI + 0x2]
SHL RCX,0x30
OR RCX,RAX
MOV EAX,dword ptr [RDI + 0x3]
OR RAX,RCX
POP RBP
RET
|
ulong maria_page_get_lsn(ushort *param_1)
{
return (ulong)*(uint *)((long)param_1 + 3) |
(ulong)(byte)param_1[1] << 0x30 | (ulong)*param_1 << 0x20;
}
| |
23,384 | mul_sum_us8_pairs_float | Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu-quants.c | static inline __m256 mul_sum_us8_pairs_float(const __m256i ax, const __m256i sy) {
#if defined(__AVX512VNNI__) && defined(__AVX512VL__)
const __m256i zero = _mm256_setzero_si256();
const __m256i summed_pairs = _mm256_dpbusd_epi32(zero, ax, sy);
return _mm256_cvtepi32_ps(summed_pairs);
#elif defined(__AVXVNNI__)
const __m256i zero = _mm256_setzero_si256();
const __m256i summed_pairs = _mm256_dpbusd_avx_epi32(zero, ax, sy);
return _mm256_cvtepi32_ps(summed_pairs);
#else
// Perform multiplication and create 16-bit values
const __m256i dot = _mm256_maddubs_epi16(ax, sy);
return sum_i16_pairs_float(dot);
#endif
} | O0 | c | mul_sum_us8_pairs_float:
pushq %rbp
movq %rsp, %rbp
andq $-0x20, %rsp
subq $0xc0, %rsp
vmovdqa %ymm0, 0x40(%rsp)
vmovdqa %ymm1, 0x20(%rsp)
vmovdqa 0x40(%rsp), %ymm1
vmovdqa 0x20(%rsp), %ymm0
vmovdqa %ymm1, 0x80(%rsp)
vmovdqa %ymm0, 0x60(%rsp)
vmovdqa 0x80(%rsp), %ymm0
vmovdqa 0x60(%rsp), %ymm1
vpmaddubsw %ymm1, %ymm0, %ymm0
vmovdqa %ymm0, (%rsp)
vmovdqa (%rsp), %ymm0
callq 0x72030
movq %rbp, %rsp
popq %rbp
retq
nop
| mul_sum_us8_pairs_float:
push rbp
mov rbp, rsp
and rsp, 0FFFFFFFFFFFFFFE0h
sub rsp, 0C0h
vmovdqa [rsp+0C0h+var_80], ymm0
vmovdqa [rsp+0C0h+var_A0], ymm1
vmovdqa ymm1, [rsp+0C0h+var_80]
vmovdqa ymm0, [rsp+0C0h+var_A0]
vmovdqa [rsp+0C0h+var_40], ymm1
vmovdqa [rsp+0C0h+var_60], ymm0
vmovdqa ymm0, [rsp+0C0h+var_40]
vmovdqa ymm1, [rsp+0C0h+var_60]
vpmaddubsw ymm0, ymm0, ymm1
vmovdqa [rsp+0C0h+var_C0], ymm0
vmovdqa ymm0, [rsp+0C0h+var_C0]
call sum_i16_pairs_float
mov rsp, rbp
pop rbp
retn
| long long mul_sum_us8_pairs_float(long long a1, long long a2, long long a3, long long a4, long long a5, long long a6)
{
__m256 v15; // [rsp+0h] [rbp-C0h]
__m256 v16; // [rsp+20h] [rbp-A0h]
__m256 v17; // [rsp+40h] [rbp-80h]
__m256 v18; // [rsp+60h] [rbp-60h]
__asm
{
vmovdqa [rsp+0C0h+var_80], ymm0
vmovdqa [rsp+0C0h+var_A0], ymm1
vmovdqa ymm1, [rsp+0C0h+var_80]
vmovdqa ymm0, [rsp+0C0h+var_A0]
vmovdqa [rsp+0C0h+var_40], ymm1
vmovdqa [rsp+0C0h+var_60], ymm0
vmovdqa ymm0, [rsp+0C0h+var_40]
vmovdqa ymm1, [rsp+0C0h+var_60]
vpmaddubsw ymm0, ymm0, ymm1
vmovdqa [rsp+0C0h+var_C0], ymm0
vmovdqa ymm0, [rsp+0C0h+var_C0]
}
return sum_i16_pairs_float(
a1,
a2,
a3,
a4,
a5,
a6,
*(_QWORD *)v15.m256_f32,
*(_QWORD *)&v15.m256_f32[2],
*(_QWORD *)&v15.m256_f32[4],
*(_QWORD *)&v15.m256_f32[6],
*(_QWORD *)v16.m256_f32,
*(_QWORD *)&v16.m256_f32[2],
*(_QWORD *)&v16.m256_f32[4],
*(_QWORD *)&v16.m256_f32[6],
*(_QWORD *)v17.m256_f32,
*(_QWORD *)&v17.m256_f32[2],
*(_QWORD *)&v17.m256_f32[4],
*(_QWORD *)&v17.m256_f32[6],
*(_QWORD *)v18.m256_f32,
*(_QWORD *)&v18.m256_f32[2]);
}
| mul_sum_us8_pairs_float:
PUSH RBP
MOV RBP,RSP
AND RSP,-0x20
SUB RSP,0xc0
VMOVDQA ymmword ptr [RSP + 0x40],YMM0
VMOVDQA ymmword ptr [RSP + 0x20],YMM1
VMOVDQA YMM1,ymmword ptr [RSP + 0x40]
VMOVDQA YMM0,ymmword ptr [RSP + 0x20]
VMOVDQA ymmword ptr [RSP + 0x80],YMM1
VMOVDQA ymmword ptr [RSP + 0x60],YMM0
VMOVDQA YMM0,ymmword ptr [RSP + 0x80]
VMOVDQA YMM1,ymmword ptr [RSP + 0x60]
VPMADDUBSW YMM0,YMM0,YMM1
VMOVDQA ymmword ptr [RSP],YMM0
VMOVDQA YMM0,ymmword ptr [RSP]
CALL 0x00172030
MOV RSP,RBP
POP RBP
RET
|
void mul_sum_us8_pairs_float(int8 param_1,int8 param_2)
{
int1 auVar1 [32];
int1 auVar2 [32];
int8 in_XMM0_Qb;
int8 in_YMM0_H;
int8 in_register_00001218;
int8 in_XMM1_Qb;
int8 in_YMM1_H;
int8 in_register_00001258;
int8 local_e0;
auVar2._8_8_ = in_XMM0_Qb;
auVar2._0_8_ = param_1;
auVar2._16_8_ = in_YMM0_H;
auVar2._24_8_ = in_register_00001218;
auVar1._8_8_ = in_XMM1_Qb;
auVar1._0_8_ = param_2;
auVar1._16_8_ = in_YMM1_H;
auVar1._24_8_ = in_register_00001258;
auVar1 = vpmaddubsw_avx2(auVar2,auVar1);
local_e0 = auVar1._0_8_;
sum_i16_pairs_float(local_e0);
return;
}
| |
23,385 | my_read_charset_file | eloqsql/mysys/charset.c | static my_bool
my_read_charset_file(MY_CHARSET_LOADER *loader,
const char *filename,
myf myflags)
{
uchar *buf;
int fd;
size_t len, tmp_len;
MY_STAT stat_info;
if (!my_stat(filename, &stat_info, MYF(myflags)) ||
((len= (uint)stat_info.st_size) > MY_MAX_ALLOWED_BUF) ||
!(buf= (uchar*) my_malloc(key_memory_charset_loader,len,myflags)))
return TRUE;
if ((fd= mysql_file_open(key_file_charset, filename, O_RDONLY, myflags)) < 0)
goto error;
tmp_len= mysql_file_read(fd, buf, len, myflags);
mysql_file_close(fd, myflags);
if (tmp_len != len)
goto error;
if (my_parse_charset_xml(loader, (char *) buf, len))
{
my_printf_error(EE_UNKNOWN_CHARSET, "Error while parsing '%s': %s\n",
MYF(0), filename, loader->error);
goto error;
}
my_free(buf);
return FALSE;
error:
my_free(buf);
return TRUE;
} | O3 | c | my_read_charset_file:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xf8, %rsp
movq %rdx, %r12
movq %rsi, %r14
movq %rdi, %rbx
leaq -0x120(%rbp), %rsi
movq %r14, %rdi
callq 0x2acd7
testq %rax, %rax
je 0x2ef08
movl -0xf0(%rbp), %r13d
cmpq $0x100000, %r13 # imm = 0x100000
ja 0x2ef08
leaq 0x33c144(%rip), %rax # 0x36af34
movl (%rax), %edi
movq %r13, %rsi
movq %r12, %rdx
callq 0x2adb9
testq %rax, %rax
je 0x2ef08
movq %rax, %r15
movq %rbx, -0x38(%rbp)
leaq 0x33b7bc(%rip), %rax # 0x36a5d0
movl (%rax), %esi
leaq 0x2c4f4b(%rip), %rax # 0x2f3d68
movq (%rax), %rax
leaq -0x90(%rbp), %rdi
leaq -0x48(%rbp), %rbx
movl $0x2, %edx
movq %r14, %rcx
movq %rbx, %r8
callq *0x148(%rax)
movq %rax, (%rbx)
testq %rax, %rax
jne 0x2ef1a
movq %r14, %rdi
xorl %esi, %esi
movq %r12, %rdx
callq 0x30b28
movl %eax, %ebx
testl %ebx, %ebx
js 0x2ef00
leaq 0x2c4f02(%rip), %rax # 0x2f3d68
movq (%rax), %rax
leaq -0x90(%rbp), %rdi
movl %ebx, %esi
movl $0x6, %edx
callq *0x158(%rax)
testq %rax, %rax
jne 0x2ef63
movl %ebx, %edi
movq %r15, %rsi
movq %r13, %rdx
movq %r12, %rcx
callq 0x30da8
movq %rax, -0x30(%rbp)
leaq 0x2c4ec7(%rip), %rax # 0x2f3d68
movq (%rax), %rax
leaq -0x90(%rbp), %rdi
movl %ebx, %esi
movl $0x4, %edx
callq *0x158(%rax)
testq %rax, %rax
jne 0x2efd7
movl %ebx, %edi
movq %r12, %rsi
callq 0x30ccd
cmpq %r13, -0x30(%rbp)
jne 0x2ef00
movq -0x38(%rbp), %rdi
movq %r15, %rsi
movq %r13, %rdx
callq 0x57958
testb %al, %al
je 0x2ef00
leaq 0x31761(%rip), %rsi # 0x6064c
movl $0x16, %edi
xorl %edx, %edx
movq %r14, %rcx
movq -0x38(%rbp), %r8
xorl %eax, %eax
callq 0x307f9
movq %r15, %rdi
callq 0x2afe6
addq $0xf8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x2c4e47(%rip), %rcx # 0x2f3d68
movq (%rcx), %rcx
leaq 0x316e8(%rip), %rsi # 0x60613
movq %rax, %rdi
movl $0x223, %edx # imm = 0x223
callq *0x1f0(%rcx)
movq %r14, %rdi
xorl %esi, %esi
movq %r12, %rdx
callq 0x30b28
movl %eax, %ebx
leaq 0x2c4e19(%rip), %rax # 0x2f3d68
movq (%rax), %rax
movq -0x48(%rbp), %rdi
movl %ebx, %esi
callq *0x200(%rax)
jmp 0x2ee57
movq %rax, %rcx
leaq 0x2c4dfb(%rip), %rax # 0x2f3d68
movq (%rax), %rax
leaq 0x3169c(%rip), %rdx # 0x60613
movq %rcx, -0x40(%rbp)
movq %rcx, %rdi
movq %r13, %rsi
movl $0x225, %ecx # imm = 0x225
callq *0x210(%rax)
movl %ebx, %edi
movq %r15, %rsi
movq %r13, %rdx
movq %r12, %rcx
callq 0x30da8
xorl %esi, %esi
testq %rax, %rax
movl $0x0, %ecx
cmoveq %r13, %rcx
cmpq $-0x1, %rax
movq %rax, -0x30(%rbp)
cmovneq %rax, %rsi
testb $0x6, %r12b
cmovneq %rcx, %rsi
leaq 0x2c4da3(%rip), %rax # 0x2f3d68
movq (%rax), %rax
movq -0x40(%rbp), %rdi
callq *0x218(%rax)
jmp 0x2ee9a
movq %rax, %rdi
movl %ebx, %esi
movq %r12, %rdx
callq 0x254f0
jmp 0x2eecb
| my_read_charset_file:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0F8h
mov r12, rdx
mov r14, rsi
mov rbx, rdi
lea rsi, [rbp+var_120]
mov rdi, r14
call my_stat
test rax, rax
jz loc_2EF08
mov r13d, [rbp+var_F0]
cmp r13, offset unk_100000
ja loc_2EF08
lea rax, key_memory_charset_loader
mov edi, [rax]
mov rsi, r13
mov rdx, r12
call my_malloc
test rax, rax
jz loc_2EF08
mov r15, rax
mov [rbp+var_38], rbx
lea rax, key_file_charset
mov esi, [rax]
lea rax, PSI_server
mov rax, [rax]
lea rdi, [rbp+var_90]
lea rbx, [rbp+var_48]
mov edx, 2
mov rcx, r14
mov r8, rbx
call qword ptr [rax+148h]
mov [rbx], rax
test rax, rax
jnz loc_2EF1A
mov rdi, r14
xor esi, esi
mov rdx, r12
call my_open
mov ebx, eax
loc_2EE57:
test ebx, ebx
js loc_2EF00
lea rax, PSI_server
mov rax, [rax]
lea rdi, [rbp+var_90]
mov esi, ebx
mov edx, 6
call qword ptr [rax+158h]
test rax, rax
jnz loc_2EF63
mov edi, ebx
mov rsi, r15
mov rdx, r13
mov rcx, r12
call my_read
mov [rbp+var_30], rax
loc_2EE9A:
lea rax, PSI_server
mov rax, [rax]
lea rdi, [rbp+var_90]
mov esi, ebx
mov edx, 4
call qword ptr [rax+158h]
test rax, rax
jnz loc_2EFD7
mov edi, ebx
mov rsi, r12
call my_close
loc_2EECB:
cmp [rbp+var_30], r13
jnz short loc_2EF00
mov rdi, [rbp+var_38]
mov rsi, r15
mov rdx, r13
call my_parse_charset_xml
test al, al
jz short loc_2EF00
lea rsi, aErrorWhilePars; "Error while parsing '%s': %s\n"
mov edi, 16h
xor edx, edx
mov rcx, r14
mov r8, [rbp+var_38]
xor eax, eax
call my_printf_error
loc_2EF00:
mov rdi, r15
call my_free
loc_2EF08:
add rsp, 0F8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_2EF1A:
lea rcx, PSI_server
mov rcx, [rcx]
lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, rax
mov edx, 223h
call qword ptr [rcx+1F0h]
mov rdi, r14
xor esi, esi
mov rdx, r12
call my_open
mov ebx, eax
lea rax, PSI_server
mov rax, [rax]
mov rdi, [rbp+var_48]
mov esi, ebx
call qword ptr [rax+200h]
jmp loc_2EE57
loc_2EF63:
mov rcx, rax
lea rax, PSI_server
mov rax, [rax]
lea rdx, aWorkspaceLlm4b_1; "/workspace/llm4binary/github2025/eloqsq"...
mov [rbp+var_40], rcx
mov rdi, rcx
mov rsi, r13
mov ecx, 225h
call qword ptr [rax+210h]
mov edi, ebx
mov rsi, r15
mov rdx, r13
mov rcx, r12
call my_read
xor esi, esi
test rax, rax
mov ecx, 0
cmovz rcx, r13
cmp rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_30], rax
cmovnz rsi, rax
test r12b, 6
cmovnz rsi, rcx
lea rax, PSI_server
mov rax, [rax]
mov rdi, [rbp+var_40]
call qword ptr [rax+218h]
jmp loc_2EE9A
loc_2EFD7:
mov rdi, rax
mov esi, ebx
mov rdx, r12
call my_read_charset_file_cold_1
jmp loc_2EECB
| long long my_read_charset_file(long long a1, long long a2, long long a3)
{
int v4; // r14d
long long result; // rax
long long v6; // r13
long long v7; // r15
long long v8; // rax
long long v9; // rbx
long long v10; // rax
long long v11; // rax
int v12; // r9d
long long v13; // rax
long long v14; // rdx
long long v15; // rsi
long long v16; // rcx
char v17[48]; // [rsp+0h] [rbp-120h] BYREF
unsigned int v18; // [rsp+30h] [rbp-F0h]
_BYTE v19[72]; // [rsp+90h] [rbp-90h] BYREF
long long v20; // [rsp+D8h] [rbp-48h] BYREF
long long v21; // [rsp+E0h] [rbp-40h]
long long v22; // [rsp+E8h] [rbp-38h]
long long v23; // [rsp+F0h] [rbp-30h]
v4 = a2;
result = my_stat(a2, (long long)v17, a3);
if ( result )
{
v6 = v18;
if ( v18 <= (unsigned long long)&unk_100000 )
{
result = my_malloc(key_memory_charset_loader, v18, a3);
if ( result )
{
v7 = result;
v22 = a1;
v8 = (*((long long ( **)(_BYTE *, _QWORD, long long, long long, long long *))PSI_server[0] + 41))(
v19,
key_file_charset,
2LL,
a2,
&v20);
v20 = v8;
if ( v8 )
{
(*((void ( **)(long long, const char *, long long))PSI_server[0] + 62))(
v8,
"/workspace/llm4binary/github2025/eloqsql/mysys/charset.c",
547LL);
v9 = (unsigned int)my_open(a2, 0LL, a3);
(*((void ( **)(long long, long long))PSI_server[0] + 64))(v20, v9);
}
else
{
LODWORD(v9) = my_open(a2, 0LL, a3);
}
if ( (int)v9 >= 0 )
{
v10 = (*((long long ( **)(_BYTE *, _QWORD, long long))PSI_server[0] + 43))(v19, (unsigned int)v9, 6LL);
if ( v10 )
{
v21 = v10;
(*((void ( **)(long long, long long, const char *, long long))PSI_server[0] + 66))(
v10,
v6,
"/workspace/llm4binary/github2025/eloqsql/mysys/charset.c",
549LL);
v13 = my_read((unsigned int)v9, v7, v6, a3);
v15 = 0LL;
v16 = 0LL;
if ( !v13 )
v16 = v6;
v23 = v13;
if ( v13 != -1 )
v15 = v13;
if ( (a3 & 6) != 0 )
v15 = v16;
(*((void ( **)(long long, long long, long long, long long))PSI_server[0] + 67))(v21, v15, v14, v16);
}
else
{
v23 = my_read((unsigned int)v9, v7, v6, a3);
}
v11 = (*((long long ( **)(_BYTE *, _QWORD, long long))PSI_server[0] + 43))(v19, (unsigned int)v9, 4LL);
if ( v11 )
my_read_charset_file_cold_1(v11, v9, a3);
else
my_close((unsigned int)v9, a3);
if ( v23 == v6 )
{
if ( (unsigned __int8)my_parse_charset_xml(v22, v7, v6) )
my_printf_error(22, (unsigned int)"Error while parsing '%s': %s\n", 0, v4, v22, v12, v17[0]);
}
}
return my_free(v7);
}
}
}
return result;
}
| my_read_charset_file:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xf8
MOV R12,RDX
MOV R14,RSI
MOV RBX,RDI
LEA RSI,[RBP + -0x120]
MOV RDI,R14
CALL 0x0012acd7
TEST RAX,RAX
JZ 0x0012ef08
MOV R13D,dword ptr [RBP + -0xf0]
CMP R13,0x100000
JA 0x0012ef08
LEA RAX,[0x46af34]
MOV EDI,dword ptr [RAX]
MOV RSI,R13
MOV RDX,R12
CALL 0x0012adb9
TEST RAX,RAX
JZ 0x0012ef08
MOV R15,RAX
MOV qword ptr [RBP + -0x38],RBX
LEA RAX,[0x46a5d0]
MOV ESI,dword ptr [RAX]
LEA RAX,[0x3f3d68]
MOV RAX,qword ptr [RAX]
LEA RDI,[RBP + -0x90]
LEA RBX,[RBP + -0x48]
MOV EDX,0x2
MOV RCX,R14
MOV R8,RBX
CALL qword ptr [RAX + 0x148]
MOV qword ptr [RBX],RAX
TEST RAX,RAX
JNZ 0x0012ef1a
MOV RDI,R14
XOR ESI,ESI
MOV RDX,R12
CALL 0x00130b28
MOV EBX,EAX
LAB_0012ee57:
TEST EBX,EBX
JS 0x0012ef00
LEA RAX,[0x3f3d68]
MOV RAX,qword ptr [RAX]
LEA RDI,[RBP + -0x90]
MOV ESI,EBX
MOV EDX,0x6
CALL qword ptr [RAX + 0x158]
TEST RAX,RAX
JNZ 0x0012ef63
MOV EDI,EBX
MOV RSI,R15
MOV RDX,R13
MOV RCX,R12
CALL 0x00130da8
MOV qword ptr [RBP + -0x30],RAX
LAB_0012ee9a:
LEA RAX,[0x3f3d68]
MOV RAX,qword ptr [RAX]
LEA RDI,[RBP + -0x90]
MOV ESI,EBX
MOV EDX,0x4
CALL qword ptr [RAX + 0x158]
TEST RAX,RAX
JNZ 0x0012efd7
MOV EDI,EBX
MOV RSI,R12
CALL 0x00130ccd
LAB_0012eecb:
CMP qword ptr [RBP + -0x30],R13
JNZ 0x0012ef00
MOV RDI,qword ptr [RBP + -0x38]
MOV RSI,R15
MOV RDX,R13
CALL 0x00157958
TEST AL,AL
JZ 0x0012ef00
LEA RSI,[0x16064c]
MOV EDI,0x16
XOR EDX,EDX
MOV RCX,R14
MOV R8,qword ptr [RBP + -0x38]
XOR EAX,EAX
CALL 0x001307f9
LAB_0012ef00:
MOV RDI,R15
CALL 0x0012afe6
LAB_0012ef08:
ADD RSP,0xf8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0012ef1a:
LEA RCX,[0x3f3d68]
MOV RCX,qword ptr [RCX]
LEA RSI,[0x160613]
MOV RDI,RAX
MOV EDX,0x223
CALL qword ptr [RCX + 0x1f0]
MOV RDI,R14
XOR ESI,ESI
MOV RDX,R12
CALL 0x00130b28
MOV EBX,EAX
LEA RAX,[0x3f3d68]
MOV RAX,qword ptr [RAX]
MOV RDI,qword ptr [RBP + -0x48]
MOV ESI,EBX
CALL qword ptr [RAX + 0x200]
JMP 0x0012ee57
LAB_0012ef63:
MOV RCX,RAX
LEA RAX,[0x3f3d68]
MOV RAX,qword ptr [RAX]
LEA RDX,[0x160613]
MOV qword ptr [RBP + -0x40],RCX
MOV RDI,RCX
MOV RSI,R13
MOV ECX,0x225
CALL qword ptr [RAX + 0x210]
MOV EDI,EBX
MOV RSI,R15
MOV RDX,R13
MOV RCX,R12
CALL 0x00130da8
XOR ESI,ESI
TEST RAX,RAX
MOV ECX,0x0
CMOVZ RCX,R13
CMP RAX,-0x1
MOV qword ptr [RBP + -0x30],RAX
CMOVNZ RSI,RAX
TEST R12B,0x6
CMOVNZ RSI,RCX
LEA RAX,[0x3f3d68]
MOV RAX,qword ptr [RAX]
MOV RDI,qword ptr [RBP + -0x40]
CALL qword ptr [RAX + 0x218]
JMP 0x0012ee9a
LAB_0012efd7:
MOV RDI,RAX
MOV ESI,EBX
MOV RDX,R12
CALL 0x001254f0
JMP 0x0012eecb
|
void my_read_charset_file(int8 param_1,int8 param_2,ulong param_3)
{
char cVar1;
int iVar2;
long lVar3;
long lVar4;
ulong uVar5;
ulong uVar6;
ulong uVar7;
int1 local_128 [48];
uint local_f8;
int1 local_98 [72];
long local_50;
long local_48;
int8 local_40;
ulong local_38;
lVar3 = my_stat(param_2,local_128);
if ((lVar3 != 0) && (uVar7 = (ulong)local_f8, uVar7 < 0x100001)) {
lVar3 = my_malloc(key_memory_charset_loader,uVar7,param_3);
if (lVar3 != 0) {
local_40 = param_1;
local_50 = (**(code **)(PSI_server + 0x148))(local_98,key_file_charset,2,param_2,&local_50);
if (local_50 == 0) {
iVar2 = my_open(param_2,0,param_3);
}
else {
(**(code **)(PSI_server + 0x1f0))
(local_50,"/workspace/llm4binary/github2025/eloqsql/mysys/charset.c",0x223);
iVar2 = my_open(param_2,0,param_3);
(**(code **)(PSI_server + 0x200))(local_50,iVar2);
}
if (-1 < iVar2) {
lVar4 = (**(code **)(PSI_server + 0x158))(local_98,iVar2,6);
if (lVar4 == 0) {
local_38 = my_read(iVar2,lVar3,uVar7,param_3);
}
else {
local_48 = lVar4;
(**(code **)(PSI_server + 0x210))
(lVar4,uVar7,"/workspace/llm4binary/github2025/eloqsql/mysys/charset.c",0x225);
local_38 = my_read(iVar2,lVar3,uVar7,param_3);
uVar5 = 0;
if (local_38 == 0) {
uVar5 = uVar7;
}
uVar6 = 0;
if (local_38 != 0xffffffffffffffff) {
uVar6 = local_38;
}
if ((param_3 & 6) != 0) {
uVar6 = uVar5;
}
(**(code **)(PSI_server + 0x218))(local_48,uVar6);
}
lVar4 = (**(code **)(PSI_server + 0x158))(local_98,iVar2,4);
if (lVar4 == 0) {
my_close(iVar2,param_3);
}
else {
my_read_charset_file_cold_1(lVar4,iVar2,param_3);
}
if (local_38 == uVar7) {
cVar1 = my_parse_charset_xml(local_40,lVar3,uVar7);
if (cVar1 != '\0') {
my_printf_error(0x16,"Error while parsing \'%s\': %s\n",0,param_2,local_40);
}
}
}
my_free(lVar3);
}
}
return;
}
| |
23,386 | my_strntol_mb2_or_mb4 | eloqsql/strings/ctype-ucs2.c | static long
my_strntol_mb2_or_mb4(CHARSET_INFO *cs,
const char *nptr, size_t l, int base,
char **endptr, int *err)
{
int negative= 0;
int overflow;
int cnv;
my_wc_t wc;
my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc;
register unsigned int cutlim;
register uint32 cutoff;
register uint32 res;
register const uchar *s= (const uchar*) nptr;
register const uchar *e= (const uchar*) nptr+l;
const uchar *save;
*err= 0;
do
{
if ((cnv= mb_wc(cs, &wc, s, e)) > 0)
{
switch (wc)
{
case ' ' : break;
case '\t': break;
case '-' : negative= !negative; break;
case '+' : break;
default : goto bs;
}
}
else /* No more characters or bad multibyte sequence */
{
if (endptr != NULL )
*endptr= (char*) s;
err[0]= (cnv==MY_CS_ILSEQ) ? EILSEQ : EDOM;
return 0;
}
s+= cnv;
} while (1);
bs:
overflow= 0;
res= 0;
save= s;
cutoff= ((uint32)~0L) / (uint32) base;
cutlim= (uint) (((uint32)~0L) % (uint32) base);
do {
if ((cnv= mb_wc(cs, &wc, s, e)) > 0)
{
s+= cnv;
if (wc >= '0' && wc <= '9')
wc-= '0';
else if (wc >= 'A' && wc <= 'Z')
wc= wc - 'A' + 10;
else if (wc >= 'a' && wc <= 'z')
wc= wc - 'a' + 10;
else
break;
if ((int)wc >= base)
break;
if (res > cutoff || (res == cutoff && wc > cutlim))
overflow= 1;
else
{
res*= (uint32) base;
res+= wc;
}
}
else if (cnv == MY_CS_ILSEQ)
{
if (endptr !=NULL )
*endptr = (char*) s;
err[0]= EILSEQ;
return 0;
}
else
{
/* No more characters */
break;
}
} while(1);
if (endptr != NULL)
*endptr = (char *) s;
if (s == save)
{
err[0]= EDOM;
return 0L;
}
if (negative)
{
if (res > (uint32) INT_MIN32)
overflow= 1;
}
else if (res > INT_MAX32)
overflow= 1;
if (overflow)
{
err[0]= ERANGE;
return negative ? INT_MIN32 : INT_MAX32;
}
return (negative ? -((long) res) : (long) res);
} | O0 | c | my_strntol_mb2_or_mb4:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl %ecx, -0x24(%rbp)
movq %r8, -0x30(%rbp)
movq %r9, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
movq -0x10(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x18(%rbp), %rax
addq -0x20(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x38(%rbp), %rax
movl $0x0, (%rax)
movq -0x58(%rbp), %rax
movq -0x10(%rbp), %rdi
movq -0x70(%rbp), %rdx
movq -0x78(%rbp), %rcx
leaq -0x50(%rbp), %rsi
callq *%rax
movl %eax, -0x44(%rbp)
cmpl $0x0, %eax
jle 0x5c1f1
movq -0x50(%rbp), %rax
addq $-0x9, %rax
movq %rax, -0x88(%rbp)
subq $0x24, %rax
ja 0x5c1ed
movq -0x88(%rbp), %rax
leaq 0x157665(%rip), %rcx # 0x1b3830
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
jmp 0x5c1ef
jmp 0x5c1ef
cmpl $0x0, -0x3c(%rbp)
setne %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x3c(%rbp)
jmp 0x5c1ef
jmp 0x5c1ef
jmp 0x5c248
jmp 0x5c229
cmpq $0x0, -0x30(%rbp)
je 0x5c203
movq -0x70(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
movl -0x44(%rbp), %edx
movl $0x21, %ecx
movl $0x54, %eax
cmpl $0x0, %edx
cmovel %eax, %ecx
movq -0x38(%rbp), %rax
movl %ecx, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0x5c451
movl -0x44(%rbp), %ecx
movq -0x70(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x70(%rbp)
movb $0x1, %al
testb $0x1, %al
jne 0x5c18a
jmp 0x5c246
jmp 0x5c248
movl $0x0, -0x40(%rbp)
movl $0x0, -0x64(%rbp)
movq -0x70(%rbp), %rax
movq %rax, -0x80(%rbp)
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
xorl %edx, %edx
divl -0x24(%rbp)
movl %eax, -0x60(%rbp)
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
xorl %edx, %edx
divl -0x24(%rbp)
movl %edx, -0x5c(%rbp)
movq -0x58(%rbp), %rax
movq -0x10(%rbp), %rdi
movq -0x70(%rbp), %rdx
movq -0x78(%rbp), %rcx
leaq -0x50(%rbp), %rsi
callq *%rax
movl %eax, -0x44(%rbp)
cmpl $0x0, %eax
jle 0x5c359
movl -0x44(%rbp), %ecx
movq -0x70(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x70(%rbp)
cmpq $0x30, -0x50(%rbp)
jb 0x5c2c7
cmpq $0x39, -0x50(%rbp)
ja 0x5c2c7
movq -0x50(%rbp), %rax
subq $0x30, %rax
movq %rax, -0x50(%rbp)
jmp 0x5c310
cmpq $0x41, -0x50(%rbp)
jb 0x5c2e7
cmpq $0x5a, -0x50(%rbp)
ja 0x5c2e7
movq -0x50(%rbp), %rax
subq $0x41, %rax
addq $0xa, %rax
movq %rax, -0x50(%rbp)
jmp 0x5c30e
cmpq $0x61, -0x50(%rbp)
jb 0x5c307
cmpq $0x7a, -0x50(%rbp)
ja 0x5c307
movq -0x50(%rbp), %rax
subq $0x61, %rax
addq $0xa, %rax
movq %rax, -0x50(%rbp)
jmp 0x5c30c
jmp 0x5c398
jmp 0x5c30e
jmp 0x5c310
movq -0x50(%rbp), %rax
cmpl -0x24(%rbp), %eax
jl 0x5c31b
jmp 0x5c398
movl -0x64(%rbp), %eax
cmpl -0x60(%rbp), %eax
ja 0x5c337
movl -0x64(%rbp), %eax
cmpl -0x60(%rbp), %eax
jne 0x5c340
movq -0x50(%rbp), %rax
movl -0x5c(%rbp), %ecx
cmpq %rcx, %rax
jbe 0x5c340
movl $0x1, -0x40(%rbp)
jmp 0x5c357
movl -0x24(%rbp), %eax
imull -0x64(%rbp), %eax
movl %eax, -0x64(%rbp)
movq -0x50(%rbp), %rcx
movl -0x64(%rbp), %eax
addq %rcx, %rax
movl %eax, -0x64(%rbp)
jmp 0x5c38a
cmpl $0x0, -0x44(%rbp)
jne 0x5c388
cmpq $0x0, -0x30(%rbp)
je 0x5c371
movq -0x70(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
movq -0x38(%rbp), %rax
movl $0x54, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0x5c451
jmp 0x5c398
jmp 0x5c38c
movb $0x1, %al
testb $0x1, %al
jne 0x5c278
jmp 0x5c398
cmpq $0x0, -0x30(%rbp)
je 0x5c3aa
movq -0x70(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
movq -0x70(%rbp), %rax
cmpq -0x80(%rbp), %rax
jne 0x5c3cb
movq -0x38(%rbp), %rax
movl $0x21, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0x5c451
cmpl $0x0, -0x3c(%rbp)
je 0x5c3e3
cmpl $0x80000000, -0x64(%rbp) # imm = 0x80000000
jbe 0x5c3e1
movl $0x1, -0x40(%rbp)
jmp 0x5c3f7
movl -0x64(%rbp), %eax
cmpq $0x7fffffff, %rax # imm = 0x7FFFFFFF
jle 0x5c3f5
movl $0x1, -0x40(%rbp)
jmp 0x5c3f7
cmpl $0x0, -0x40(%rbp)
je 0x5c423
movq -0x38(%rbp), %rax
movl $0x22, (%rax)
movl -0x3c(%rbp), %edx
movl $0x7fffffff, %eax # imm = 0x7FFFFFFF
movq $-0x80000000, %rcx # imm = 0x80000000
cmpl $0x0, %edx
cmovneq %rcx, %rax
movq %rax, -0x8(%rbp)
jmp 0x5c451
cmpl $0x0, -0x3c(%rbp)
je 0x5c43c
movl -0x64(%rbp), %eax
movl %eax, %ecx
xorl %eax, %eax
subq %rcx, %rax
movq %rax, -0x90(%rbp)
jmp 0x5c446
movl -0x64(%rbp), %eax
movq %rax, -0x90(%rbp)
movq -0x90(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x90, %rsp
popq %rbp
retq
nop
| my_strntol_mb2_or_mb4:
push rbp
mov rbp, rsp
sub rsp, 90h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_24], ecx
mov [rbp+var_30], r8
mov [rbp+var_38], r9
mov [rbp+var_3C], 0
mov rax, [rbp+var_10]
mov rax, [rax+0B8h]
mov rax, [rax+28h]
mov [rbp+var_58], rax
mov rax, [rbp+var_18]
mov [rbp+var_70], rax
mov rax, [rbp+var_18]
add rax, [rbp+var_20]
mov [rbp+var_78], rax
mov rax, [rbp+var_38]
mov dword ptr [rax], 0
loc_5C18A:
mov rax, [rbp+var_58]
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_70]
mov rcx, [rbp+var_78]
lea rsi, [rbp+var_50]
call rax
mov [rbp+var_44], eax
cmp eax, 0
jle short loc_5C1F1
mov rax, [rbp+var_50]
add rax, 0FFFFFFFFFFFFFFF7h; switch 37 cases
mov [rbp+var_88], rax
sub rax, 24h
ja short def_5C1D2; jumptable 000000000005C1D2 default case, cases 10-31,33-42,44
mov rax, [rbp+var_88]
lea rcx, jpt_5C1D2
movsxd rax, ds:(jpt_5C1D2 - 1B3830h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_5C1D4:
jmp short loc_5C1EF; jumptable 000000000005C1D2 case 32
loc_5C1D6:
jmp short loc_5C1EF; jumptable 000000000005C1D2 case 9
loc_5C1D8:
cmp [rbp+var_3C], 0; jumptable 000000000005C1D2 case 45
setnz al
xor al, 0FFh
and al, 1
movzx eax, al
mov [rbp+var_3C], eax
jmp short loc_5C1EF
loc_5C1EB:
jmp short loc_5C1EF; jumptable 000000000005C1D2 case 43
def_5C1D2:
jmp short loc_5C248; jumptable 000000000005C1D2 default case, cases 10-31,33-42,44
loc_5C1EF:
jmp short loc_5C229
loc_5C1F1:
cmp [rbp+var_30], 0
jz short loc_5C203
mov rcx, [rbp+var_70]
mov rax, [rbp+var_30]
mov [rax], rcx
loc_5C203:
mov edx, [rbp+var_44]
mov ecx, 21h ; '!'
mov eax, 54h ; 'T'
cmp edx, 0
cmovz ecx, eax
mov rax, [rbp+var_38]
mov [rax], ecx
mov [rbp+var_8], 0
jmp loc_5C451
loc_5C229:
mov ecx, [rbp+var_44]
mov rax, [rbp+var_70]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_70], rax
mov al, 1
test al, 1
jnz loc_5C18A
jmp short $+2
loc_5C246:
jmp short $+2
loc_5C248:
mov [rbp+var_40], 0
mov [rbp+var_64], 0
mov rax, [rbp+var_70]
mov [rbp+var_80], rax
mov eax, 0FFFFFFFFh
xor edx, edx
div [rbp+var_24]
mov [rbp+var_60], eax
mov eax, 0FFFFFFFFh
xor edx, edx
div [rbp+var_24]
mov [rbp+var_5C], edx
loc_5C278:
mov rax, [rbp+var_58]
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_70]
mov rcx, [rbp+var_78]
lea rsi, [rbp+var_50]
call rax
mov [rbp+var_44], eax
cmp eax, 0
jle loc_5C359
mov ecx, [rbp+var_44]
mov rax, [rbp+var_70]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_70], rax
cmp [rbp+var_50], 30h ; '0'
jb short loc_5C2C7
cmp [rbp+var_50], 39h ; '9'
ja short loc_5C2C7
mov rax, [rbp+var_50]
sub rax, 30h ; '0'
mov [rbp+var_50], rax
jmp short loc_5C310
loc_5C2C7:
cmp [rbp+var_50], 41h ; 'A'
jb short loc_5C2E7
cmp [rbp+var_50], 5Ah ; 'Z'
ja short loc_5C2E7
mov rax, [rbp+var_50]
sub rax, 41h ; 'A'
add rax, 0Ah
mov [rbp+var_50], rax
jmp short loc_5C30E
loc_5C2E7:
cmp [rbp+var_50], 61h ; 'a'
jb short loc_5C307
cmp [rbp+var_50], 7Ah ; 'z'
ja short loc_5C307
mov rax, [rbp+var_50]
sub rax, 61h ; 'a'
add rax, 0Ah
mov [rbp+var_50], rax
jmp short loc_5C30C
loc_5C307:
jmp loc_5C398
loc_5C30C:
jmp short $+2
loc_5C30E:
jmp short $+2
loc_5C310:
mov rax, [rbp+var_50]
cmp eax, [rbp+var_24]
jl short loc_5C31B
jmp short loc_5C398
loc_5C31B:
mov eax, [rbp+var_64]
cmp eax, [rbp+var_60]
ja short loc_5C337
mov eax, [rbp+var_64]
cmp eax, [rbp+var_60]
jnz short loc_5C340
mov rax, [rbp+var_50]
mov ecx, [rbp+var_5C]
cmp rax, rcx
jbe short loc_5C340
loc_5C337:
mov [rbp+var_40], 1
jmp short loc_5C357
loc_5C340:
mov eax, [rbp+var_24]
imul eax, [rbp+var_64]
mov [rbp+var_64], eax
mov rcx, [rbp+var_50]
mov eax, [rbp+var_64]
add rax, rcx
mov [rbp+var_64], eax
loc_5C357:
jmp short loc_5C38A
loc_5C359:
cmp [rbp+var_44], 0
jnz short loc_5C388
cmp [rbp+var_30], 0
jz short loc_5C371
mov rcx, [rbp+var_70]
mov rax, [rbp+var_30]
mov [rax], rcx
loc_5C371:
mov rax, [rbp+var_38]
mov dword ptr [rax], 54h ; 'T'
mov [rbp+var_8], 0
jmp loc_5C451
loc_5C388:
jmp short loc_5C398
loc_5C38A:
jmp short $+2
loc_5C38C:
mov al, 1
test al, 1
jnz loc_5C278
jmp short $+2
loc_5C398:
cmp [rbp+var_30], 0
jz short loc_5C3AA
mov rcx, [rbp+var_70]
mov rax, [rbp+var_30]
mov [rax], rcx
loc_5C3AA:
mov rax, [rbp+var_70]
cmp rax, [rbp+var_80]
jnz short loc_5C3CB
mov rax, [rbp+var_38]
mov dword ptr [rax], 21h ; '!'
mov [rbp+var_8], 0
jmp loc_5C451
loc_5C3CB:
cmp [rbp+var_3C], 0
jz short loc_5C3E3
cmp [rbp+var_64], 80000000h
jbe short loc_5C3E1
mov [rbp+var_40], 1
loc_5C3E1:
jmp short loc_5C3F7
loc_5C3E3:
mov eax, [rbp+var_64]
cmp rax, 7FFFFFFFh
jle short loc_5C3F5
mov [rbp+var_40], 1
loc_5C3F5:
jmp short $+2
loc_5C3F7:
cmp [rbp+var_40], 0
jz short loc_5C423
mov rax, [rbp+var_38]
mov dword ptr [rax], 22h ; '"'
mov edx, [rbp+var_3C]
mov eax, 7FFFFFFFh
mov rcx, 0FFFFFFFF80000000h
cmp edx, 0
cmovnz rax, rcx
mov [rbp+var_8], rax
jmp short loc_5C451
loc_5C423:
cmp [rbp+var_3C], 0
jz short loc_5C43C
mov eax, [rbp+var_64]
mov ecx, eax
xor eax, eax
sub rax, rcx
mov [rbp+var_90], rax
jmp short loc_5C446
loc_5C43C:
mov eax, [rbp+var_64]
mov [rbp+var_90], rax
loc_5C446:
mov rax, [rbp+var_90]
mov [rbp+var_8], rax
loc_5C451:
mov rax, [rbp+var_8]
add rsp, 90h
pop rbp
retn
| long long my_strntol_mb2_or_mb4(long long a1, long long a2, long long a3, unsigned int a4, _QWORD *a5, int *a6)
{
int v6; // ecx
long long v7; // rax
long long v10; // [rsp+10h] [rbp-80h]
long long v11; // [rsp+18h] [rbp-78h]
long long v12; // [rsp+20h] [rbp-70h]
unsigned int v13; // [rsp+2Ch] [rbp-64h]
unsigned int v14; // [rsp+30h] [rbp-60h]
unsigned int v15; // [rsp+34h] [rbp-5Ch]
long long ( *v16)(long long, unsigned long long *, long long, long long); // [rsp+38h] [rbp-58h]
unsigned long long v17; // [rsp+40h] [rbp-50h] BYREF
int v18; // [rsp+4Ch] [rbp-44h]
int v19; // [rsp+50h] [rbp-40h]
BOOL v20; // [rsp+54h] [rbp-3Ch]
int *v21; // [rsp+58h] [rbp-38h]
_QWORD *v22; // [rsp+60h] [rbp-30h]
unsigned int v23; // [rsp+6Ch] [rbp-24h]
long long v24; // [rsp+70h] [rbp-20h]
long long v25; // [rsp+78h] [rbp-18h]
long long v26; // [rsp+80h] [rbp-10h]
v26 = a1;
v25 = a2;
v24 = a3;
v23 = a4;
v22 = a5;
v21 = a6;
v20 = 0;
v16 = *(long long ( **)(long long, unsigned long long *, long long, long long))(*(_QWORD *)(a1 + 184) + 40LL);
v12 = a2;
v11 = a3 + a2;
*a6 = 0;
while ( 2 )
{
v18 = v16(v26, &v17, v12, v11);
if ( v18 <= 0 )
{
if ( v22 )
*v22 = v12;
v6 = 33;
if ( !v18 )
v6 = 84;
*v21 = v6;
return 0LL;
}
else
{
switch ( v17 )
{
case 9uLL:
case 0x20uLL:
case 0x2BuLL:
goto LABEL_10;
case 0x2DuLL:
v20 = !v20;
LABEL_10:
v12 += v18;
continue;
default:
v19 = 0;
v13 = 0;
v10 = v12;
v14 = 0xFFFFFFFF / v23;
v15 = 0xFFFFFFFF % v23;
break;
}
while ( 1 )
{
v18 = v16(v26, &v17, v12, v11);
if ( v18 <= 0 )
break;
v12 += v18;
if ( v17 < 0x30 || v17 > 0x39 )
{
if ( v17 < 0x41 || v17 > 0x5A )
{
if ( v17 < 0x61 || v17 > 0x7A )
goto LABEL_33;
v17 = v17 - 97 + 10;
}
else
{
v17 = v17 - 65 + 10;
}
}
else
{
v17 -= 48LL;
}
if ( (int)v17 >= (int)v23 )
goto LABEL_33;
if ( v13 > v14 || v13 == v14 && v17 > v15 )
v19 = 1;
else
v13 = v17 + v13 * v23;
}
if ( v18 )
{
LABEL_33:
if ( v22 )
*v22 = v12;
if ( v12 == v10 )
{
*v21 = 33;
return 0LL;
}
else
{
if ( v20 )
{
if ( v13 > 0x80000000 )
v19 = 1;
}
else if ( v13 > 0x7FFFFFFFuLL )
{
v19 = 1;
}
if ( v19 )
{
*v21 = 34;
v7 = 0x7FFFFFFFLL;
if ( v20 )
return 0xFFFFFFFF80000000LL;
return v7;
}
else if ( v20 )
{
return -(long long)v13;
}
else
{
return v13;
}
}
}
if ( v22 )
*v22 = v12;
*v21 = 84;
return 0LL;
}
}
}
| my_strntol_mb2_or_mb4:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x24],ECX
MOV qword ptr [RBP + -0x30],R8
MOV qword ptr [RBP + -0x38],R9
MOV dword ptr [RBP + -0x3c],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x70],RAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x78],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x0
LAB_0015c18a:
MOV RAX,qword ptr [RBP + -0x58]
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x70]
MOV RCX,qword ptr [RBP + -0x78]
LEA RSI,[RBP + -0x50]
CALL RAX
MOV dword ptr [RBP + -0x44],EAX
CMP EAX,0x0
JLE 0x0015c1f1
MOV RAX,qword ptr [RBP + -0x50]
ADD RAX,-0x9
MOV qword ptr [RBP + -0x88],RAX
SUB RAX,0x24
JA 0x0015c1ed
MOV RAX,qword ptr [RBP + -0x88]
LEA RCX,[0x2b3830]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_20:
JMP 0x0015c1ef
caseD_9:
JMP 0x0015c1ef
caseD_2d:
CMP dword ptr [RBP + -0x3c],0x0
SETNZ AL
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
MOV dword ptr [RBP + -0x3c],EAX
JMP 0x0015c1ef
caseD_2b:
JMP 0x0015c1ef
caseD_a:
JMP 0x0015c248
LAB_0015c1ef:
JMP 0x0015c229
LAB_0015c1f1:
CMP qword ptr [RBP + -0x30],0x0
JZ 0x0015c203
MOV RCX,qword ptr [RBP + -0x70]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
LAB_0015c203:
MOV EDX,dword ptr [RBP + -0x44]
MOV ECX,0x21
MOV EAX,0x54
CMP EDX,0x0
CMOVZ ECX,EAX
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],ECX
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0015c451
LAB_0015c229:
MOV ECX,dword ptr [RBP + -0x44]
MOV RAX,qword ptr [RBP + -0x70]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x70],RAX
MOV AL,0x1
TEST AL,0x1
JNZ 0x0015c18a
JMP 0x0015c246
LAB_0015c246:
JMP 0x0015c248
LAB_0015c248:
MOV dword ptr [RBP + -0x40],0x0
MOV dword ptr [RBP + -0x64],0x0
MOV RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RBP + -0x80],RAX
MOV EAX,0xffffffff
XOR EDX,EDX
DIV dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x60],EAX
MOV EAX,0xffffffff
XOR EDX,EDX
DIV dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x5c],EDX
LAB_0015c278:
MOV RAX,qword ptr [RBP + -0x58]
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x70]
MOV RCX,qword ptr [RBP + -0x78]
LEA RSI,[RBP + -0x50]
CALL RAX
MOV dword ptr [RBP + -0x44],EAX
CMP EAX,0x0
JLE 0x0015c359
MOV ECX,dword ptr [RBP + -0x44]
MOV RAX,qword ptr [RBP + -0x70]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x70],RAX
CMP qword ptr [RBP + -0x50],0x30
JC 0x0015c2c7
CMP qword ptr [RBP + -0x50],0x39
JA 0x0015c2c7
MOV RAX,qword ptr [RBP + -0x50]
SUB RAX,0x30
MOV qword ptr [RBP + -0x50],RAX
JMP 0x0015c310
LAB_0015c2c7:
CMP qword ptr [RBP + -0x50],0x41
JC 0x0015c2e7
CMP qword ptr [RBP + -0x50],0x5a
JA 0x0015c2e7
MOV RAX,qword ptr [RBP + -0x50]
SUB RAX,0x41
ADD RAX,0xa
MOV qword ptr [RBP + -0x50],RAX
JMP 0x0015c30e
LAB_0015c2e7:
CMP qword ptr [RBP + -0x50],0x61
JC 0x0015c307
CMP qword ptr [RBP + -0x50],0x7a
JA 0x0015c307
MOV RAX,qword ptr [RBP + -0x50]
SUB RAX,0x61
ADD RAX,0xa
MOV qword ptr [RBP + -0x50],RAX
JMP 0x0015c30c
LAB_0015c307:
JMP 0x0015c398
LAB_0015c30c:
JMP 0x0015c30e
LAB_0015c30e:
JMP 0x0015c310
LAB_0015c310:
MOV RAX,qword ptr [RBP + -0x50]
CMP EAX,dword ptr [RBP + -0x24]
JL 0x0015c31b
JMP 0x0015c398
LAB_0015c31b:
MOV EAX,dword ptr [RBP + -0x64]
CMP EAX,dword ptr [RBP + -0x60]
JA 0x0015c337
MOV EAX,dword ptr [RBP + -0x64]
CMP EAX,dword ptr [RBP + -0x60]
JNZ 0x0015c340
MOV RAX,qword ptr [RBP + -0x50]
MOV ECX,dword ptr [RBP + -0x5c]
CMP RAX,RCX
JBE 0x0015c340
LAB_0015c337:
MOV dword ptr [RBP + -0x40],0x1
JMP 0x0015c357
LAB_0015c340:
MOV EAX,dword ptr [RBP + -0x24]
IMUL EAX,dword ptr [RBP + -0x64]
MOV dword ptr [RBP + -0x64],EAX
MOV RCX,qword ptr [RBP + -0x50]
MOV EAX,dword ptr [RBP + -0x64]
ADD RAX,RCX
MOV dword ptr [RBP + -0x64],EAX
LAB_0015c357:
JMP 0x0015c38a
LAB_0015c359:
CMP dword ptr [RBP + -0x44],0x0
JNZ 0x0015c388
CMP qword ptr [RBP + -0x30],0x0
JZ 0x0015c371
MOV RCX,qword ptr [RBP + -0x70]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
LAB_0015c371:
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x54
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0015c451
LAB_0015c388:
JMP 0x0015c398
LAB_0015c38a:
JMP 0x0015c38c
LAB_0015c38c:
MOV AL,0x1
TEST AL,0x1
JNZ 0x0015c278
JMP 0x0015c398
LAB_0015c398:
CMP qword ptr [RBP + -0x30],0x0
JZ 0x0015c3aa
MOV RCX,qword ptr [RBP + -0x70]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
LAB_0015c3aa:
MOV RAX,qword ptr [RBP + -0x70]
CMP RAX,qword ptr [RBP + -0x80]
JNZ 0x0015c3cb
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x21
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0015c451
LAB_0015c3cb:
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x0015c3e3
CMP dword ptr [RBP + -0x64],0x80000000
JBE 0x0015c3e1
MOV dword ptr [RBP + -0x40],0x1
LAB_0015c3e1:
JMP 0x0015c3f7
LAB_0015c3e3:
MOV EAX,dword ptr [RBP + -0x64]
CMP RAX,0x7fffffff
JLE 0x0015c3f5
MOV dword ptr [RBP + -0x40],0x1
LAB_0015c3f5:
JMP 0x0015c3f7
LAB_0015c3f7:
CMP dword ptr [RBP + -0x40],0x0
JZ 0x0015c423
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x22
MOV EDX,dword ptr [RBP + -0x3c]
MOV EAX,0x7fffffff
MOV RCX,-0x80000000
CMP EDX,0x0
CMOVNZ RAX,RCX
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0015c451
LAB_0015c423:
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x0015c43c
MOV EAX,dword ptr [RBP + -0x64]
MOV ECX,EAX
XOR EAX,EAX
SUB RAX,RCX
MOV qword ptr [RBP + -0x90],RAX
JMP 0x0015c446
LAB_0015c43c:
MOV EAX,dword ptr [RBP + -0x64]
MOV qword ptr [RBP + -0x90],RAX
LAB_0015c446:
MOV RAX,qword ptr [RBP + -0x90]
MOV qword ptr [RBP + -0x8],RAX
LAB_0015c451:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x90
POP RBP
RET
|
/* WARNING: Removing unreachable block (ram,0x0015c244) */
/* WARNING: Removing unreachable block (ram,0x0015c396) */
ulong my_strntol_mb2_or_mb4
(long param_1,long param_2,long param_3,uint param_4,long *param_5,
int4 *param_6)
{
code *pcVar1;
ulong uVar2;
long lVar3;
uint uVar4;
int4 uVar5;
ulong local_98;
long local_78;
uint local_6c;
ulong local_58;
int local_4c;
int local_48;
uint local_44;
int4 *local_40;
long *local_38;
uint local_2c;
long local_28;
long local_20;
long local_18;
ulong local_10;
local_44 = 0;
pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28);
*param_6 = 0;
local_78 = param_2;
local_40 = param_6;
local_38 = param_5;
local_2c = param_4;
local_28 = param_3;
local_20 = param_2;
local_18 = param_1;
do {
lVar3 = local_78;
local_4c = (*pcVar1)(local_18,&local_58,local_78,param_2 + param_3);
if (local_4c < 1) {
if (local_38 != (long *)0x0) {
*local_38 = local_78;
}
uVar5 = 0x21;
if (local_4c == 0) {
uVar5 = 0x54;
}
*local_40 = uVar5;
return 0;
}
switch(local_58) {
case 9:
break;
default:
local_48 = 0;
local_6c = 0;
uVar4 = (uint)(0xffffffff / (ulong)local_2c);
uVar2 = (ulong)local_2c;
goto LAB_0015c278;
case 0x20:
break;
case 0x2b:
break;
case 0x2d:
local_44 = (uint)((local_44 != 0 ^ 0xffU) & 1);
}
local_78 = local_78 + local_4c;
} while( true );
LAB_0015c278:
local_4c = (*pcVar1)(local_18,&local_58,local_78,param_2 + param_3);
if (local_4c < 1) {
if (local_4c == 0) {
if (local_38 != (long *)0x0) {
*local_38 = local_78;
}
*local_40 = 0x54;
local_10 = 0;
}
else {
LAB_0015c398:
if (local_38 != (long *)0x0) {
*local_38 = local_78;
}
if (local_78 == lVar3) {
*local_40 = 0x21;
local_10 = 0;
}
else {
if (local_44 == 0) {
if (0x7fffffff < local_6c) {
local_48 = 1;
}
}
else if (0x80000000 < local_6c) {
local_48 = 1;
}
if (local_48 == 0) {
if (local_44 == 0) {
local_98 = (ulong)local_6c;
}
else {
local_98 = -(ulong)local_6c;
}
local_10 = local_98;
}
else {
*local_40 = 0x22;
local_10 = 0x7fffffff;
if (local_44 != 0) {
local_10 = 0xffffffff80000000;
}
}
}
}
return local_10;
}
local_78 = local_78 + local_4c;
if ((local_58 < 0x30) || (0x39 < local_58)) {
if ((local_58 < 0x41) || (0x5a < local_58)) {
if ((local_58 < 0x61) || (0x7a < local_58)) goto LAB_0015c398;
local_58 = local_58 - 0x57;
}
else {
local_58 = local_58 - 0x37;
}
}
else {
local_58 = local_58 - 0x30;
}
if ((int)local_2c <= (int)local_58) goto LAB_0015c398;
if ((uVar4 < local_6c) || ((local_6c == uVar4 && (0xffffffffU % uVar2 < local_58)))) {
local_48 = 1;
}
else {
local_6c = local_2c * local_6c + (int)local_58;
}
goto LAB_0015c278;
}
| |
23,387 | my_strntol_mb2_or_mb4 | eloqsql/strings/ctype-ucs2.c | static long
my_strntol_mb2_or_mb4(CHARSET_INFO *cs,
const char *nptr, size_t l, int base,
char **endptr, int *err)
{
int negative= 0;
int overflow;
int cnv;
my_wc_t wc;
my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc;
register unsigned int cutlim;
register uint32 cutoff;
register uint32 res;
register const uchar *s= (const uchar*) nptr;
register const uchar *e= (const uchar*) nptr+l;
const uchar *save;
*err= 0;
do
{
if ((cnv= mb_wc(cs, &wc, s, e)) > 0)
{
switch (wc)
{
case ' ' : break;
case '\t': break;
case '-' : negative= !negative; break;
case '+' : break;
default : goto bs;
}
}
else /* No more characters or bad multibyte sequence */
{
if (endptr != NULL )
*endptr= (char*) s;
err[0]= (cnv==MY_CS_ILSEQ) ? EILSEQ : EDOM;
return 0;
}
s+= cnv;
} while (1);
bs:
overflow= 0;
res= 0;
save= s;
cutoff= ((uint32)~0L) / (uint32) base;
cutlim= (uint) (((uint32)~0L) % (uint32) base);
do {
if ((cnv= mb_wc(cs, &wc, s, e)) > 0)
{
s+= cnv;
if (wc >= '0' && wc <= '9')
wc-= '0';
else if (wc >= 'A' && wc <= 'Z')
wc= wc - 'A' + 10;
else if (wc >= 'a' && wc <= 'z')
wc= wc - 'a' + 10;
else
break;
if ((int)wc >= base)
break;
if (res > cutoff || (res == cutoff && wc > cutlim))
overflow= 1;
else
{
res*= (uint32) base;
res+= wc;
}
}
else if (cnv == MY_CS_ILSEQ)
{
if (endptr !=NULL )
*endptr = (char*) s;
err[0]= EILSEQ;
return 0;
}
else
{
/* No more characters */
break;
}
} while(1);
if (endptr != NULL)
*endptr = (char *) s;
if (s == save)
{
err[0]= EDOM;
return 0L;
}
if (negative)
{
if (res > (uint32) INT_MIN32)
overflow= 1;
}
else if (res > INT_MAX32)
overflow= 1;
if (overflow)
{
err[0]= ERANGE;
return negative ? INT_MIN32 : INT_MAX32;
}
return (negative ? -((long) res) : (long) res);
} | O3 | c | my_strntol_mb2_or_mb4:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %r8, -0x40(%rbp)
movl %ecx, -0x34(%rbp)
movq %rdx, %r13
movq %rsi, %r15
movq %rdi, %r14
movq 0xb8(%rdi), %rax
movq 0x28(%rax), %r12
addq %rsi, %r13
movq %r9, -0x50(%rbp)
movl $0x0, (%r9)
leaq -0x30(%rbp), %rsi
movq %r15, %rdx
movq %r13, %rcx
callq *%r12
testl %eax, %eax
jle 0x4801e
movl $0x0, -0x38(%rbp)
leaq -0x30(%rbp), %rbx
movq -0x30(%rbp), %rcx
cmpq $0x2a, %rcx
jg 0x47fee
cmpq $0x9, %rcx
je 0x48006
cmpq $0x20, %rcx
je 0x48006
jmp 0x48050
cmpq $0x2b, %rcx
je 0x48006
cmpq $0x2d, %rcx
jne 0x48050
xorl %ecx, %ecx
cmpl $0x0, -0x38(%rbp)
sete %cl
movl %ecx, -0x38(%rbp)
movl %eax, %eax
addq %rax, %r15
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
movq %r13, %rcx
callq *%r12
testl %eax, %eax
jg 0x47fd6
movq -0x40(%rbp), %rcx
testq %rcx, %rcx
je 0x4802a
movq %r15, (%rcx)
testl %eax, %eax
movl $0x54, %eax
movl $0x21, %ecx
cmovel %eax, %ecx
movq -0x50(%rbp), %rax
movl %ecx, (%rax)
xorl %eax, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
xorl %edx, %edx
divl -0x34(%rbp)
movl %edx, %ebx
movl %eax, -0x44(%rbp)
leaq -0x30(%rbp), %rsi
movq %r14, %rdi
movq %r15, %rdx
movq %r13, %rcx
callq *%r12
testl %eax, %eax
jle 0x48116
movl %ebx, %ecx
movq %rcx, -0x60(%rbp)
xorl %ecx, %ecx
movq %r15, %rbx
xorl %r8d, %r8d
movq %rbx, %rsi
movl %eax, %ebx
addq %rsi, %rbx
movq -0x30(%rbp), %rsi
leaq -0x30(%rsi), %rax
cmpq $0x9, %rax
ja 0x480a1
movq %rax, -0x30(%rbp)
jmp 0x480c6
leaq -0x41(%rsi), %rax
cmpq $0x19, %rax
ja 0x480b1
addq $-0x37, %rsi
jmp 0x480bf
leaq -0x61(%rsi), %rax
cmpq $0x19, %rax
ja 0x48126
addq $-0x57, %rsi
movq %rsi, -0x30(%rbp)
movq %rsi, %rax
cmpl -0x34(%rbp), %eax
jge 0x48126
movl $0x1, %esi
cmpl -0x44(%rbp), %ecx
ja 0x480e9
jne 0x480e0
movl -0x44(%rbp), %edi
cmpq -0x60(%rbp), %rax
ja 0x480eb
imull -0x34(%rbp), %ecx
addl %eax, %ecx
movl %r8d, %esi
movl %ecx, %edi
movl %edi, -0x54(%rbp)
movl %esi, -0x58(%rbp)
movq %r14, %rdi
leaq -0x30(%rbp), %rsi
movq %rbx, %rdx
movq %r13, %rcx
callq *%r12
movl -0x54(%rbp), %edi
movl -0x58(%rbp), %esi
movl %edi, %ecx
movl %esi, %r8d
testl %eax, %eax
jg 0x48085
jmp 0x4811d
xorl %edi, %edi
movq %r15, %rbx
xorl %esi, %esi
testl %eax, %eax
je 0x48185
movl %esi, %r8d
movl %edi, %ecx
movq -0x40(%rbp), %rax
testq %rax, %rax
je 0x48132
movq %rbx, (%rax)
cmpq %r15, %rbx
je 0x48176
cmpl $0x80000001, %ecx # imm = 0x80000001
movl $0x1, %eax
movl %r8d, %esi
cmovael %eax, %esi
testl %ecx, %ecx
cmovsl %eax, %r8d
movl -0x38(%rbp), %edi
testl %edi, %edi
cmovnel %esi, %r8d
testl %r8d, %r8d
je 0x481a0
testl %edi, %edi
movq -0x50(%rbp), %rax
movl $0x22, (%rax)
movl $0x7fffffff, %ecx # imm = 0x7FFFFFFF
movq $-0x80000000, %rax # imm = 0x80000000
jmp 0x481aa
movq -0x50(%rbp), %rax
movl $0x21, (%rax)
jmp 0x4803f
movq -0x40(%rbp), %rax
testq %rax, %rax
je 0x48191
movq %rbx, (%rax)
movq -0x50(%rbp), %rax
movl $0x54, (%rax)
jmp 0x4803f
movl %ecx, %ecx
movq %rcx, %rax
negq %rax
testl %edi, %edi
cmoveq %rcx, %rax
jmp 0x48041
| my_strntol_mb2_or_mb4:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov [rbp+var_40], r8
mov [rbp+var_34], ecx
mov r13, rdx
mov r15, rsi
mov r14, rdi
mov rax, [rdi+0B8h]
mov r12, [rax+28h]
add r13, rsi
mov [rbp+var_50], r9
mov dword ptr [r9], 0
lea rsi, [rbp+var_30]
mov rdx, r15
mov rcx, r13
call r12
test eax, eax
jle short loc_4801E
mov [rbp+var_38], 0
lea rbx, [rbp+var_30]
loc_47FD6:
mov rcx, [rbp+var_30]
cmp rcx, 2Ah ; '*'
jg short loc_47FEE
cmp rcx, 9
jz short loc_48006
cmp rcx, 20h ; ' '
jz short loc_48006
jmp short loc_48050
loc_47FEE:
cmp rcx, 2Bh ; '+'
jz short loc_48006
cmp rcx, 2Dh ; '-'
jnz short loc_48050
xor ecx, ecx
cmp [rbp+var_38], 0
setz cl
mov [rbp+var_38], ecx
loc_48006:
mov eax, eax
add r15, rax
mov rdi, r14
mov rsi, rbx
mov rdx, r15
mov rcx, r13
call r12
test eax, eax
jg short loc_47FD6
loc_4801E:
mov rcx, [rbp+var_40]
test rcx, rcx
jz short loc_4802A
mov [rcx], r15
loc_4802A:
test eax, eax
mov eax, 54h ; 'T'
mov ecx, 21h ; '!'
cmovz ecx, eax
mov rax, [rbp+var_50]
mov [rax], ecx
loc_4803F:
xor eax, eax
loc_48041:
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_48050:
mov eax, 0FFFFFFFFh
xor edx, edx
div [rbp+var_34]
mov ebx, edx
mov [rbp+var_44], eax
lea rsi, [rbp+var_30]
mov rdi, r14
mov rdx, r15
mov rcx, r13
call r12
test eax, eax
jle loc_48116
mov ecx, ebx
mov [rbp+var_60], rcx
xor ecx, ecx
mov rbx, r15
xor r8d, r8d
loc_48085:
mov rsi, rbx
mov ebx, eax
add rbx, rsi
mov rsi, [rbp+var_30]
lea rax, [rsi-30h]
cmp rax, 9
ja short loc_480A1
mov [rbp+var_30], rax
jmp short loc_480C6
loc_480A1:
lea rax, [rsi-41h]
cmp rax, 19h
ja short loc_480B1
add rsi, 0FFFFFFFFFFFFFFC9h
jmp short loc_480BF
loc_480B1:
lea rax, [rsi-61h]
cmp rax, 19h
ja short loc_48126
add rsi, 0FFFFFFFFFFFFFFA9h
loc_480BF:
mov [rbp+var_30], rsi
mov rax, rsi
loc_480C6:
cmp eax, [rbp+var_34]
jge short loc_48126
mov esi, 1
cmp ecx, [rbp+var_44]
ja short loc_480E9
jnz short loc_480E0
mov edi, [rbp+var_44]
cmp rax, [rbp+var_60]
ja short loc_480EB
loc_480E0:
imul ecx, [rbp+var_34]
add ecx, eax
mov esi, r8d
loc_480E9:
mov edi, ecx
loc_480EB:
mov [rbp+var_54], edi
mov [rbp+var_58], esi
mov rdi, r14
lea rsi, [rbp+var_30]
mov rdx, rbx
mov rcx, r13
call r12
mov edi, [rbp+var_54]
mov esi, [rbp+var_58]
mov ecx, edi
mov r8d, esi
test eax, eax
jg loc_48085
jmp short loc_4811D
loc_48116:
xor edi, edi
mov rbx, r15
xor esi, esi
loc_4811D:
test eax, eax
jz short loc_48185
mov r8d, esi
mov ecx, edi
loc_48126:
mov rax, [rbp+var_40]
test rax, rax
jz short loc_48132
mov [rax], rbx
loc_48132:
cmp rbx, r15
jz short loc_48176
cmp ecx, 80000001h
mov eax, 1
mov esi, r8d
cmovnb esi, eax
test ecx, ecx
cmovs r8d, eax
mov edi, [rbp+var_38]
test edi, edi
cmovnz r8d, esi
test r8d, r8d
jz short loc_481A0
test edi, edi
mov rax, [rbp+var_50]
mov dword ptr [rax], 22h ; '"'
mov ecx, 7FFFFFFFh
mov rax, 0FFFFFFFF80000000h
jmp short loc_481AA
loc_48176:
mov rax, [rbp+var_50]
mov dword ptr [rax], 21h ; '!'
jmp loc_4803F
loc_48185:
mov rax, [rbp+var_40]
test rax, rax
jz short loc_48191
mov [rax], rbx
loc_48191:
mov rax, [rbp+var_50]
mov dword ptr [rax], 54h ; 'T'
jmp loc_4803F
loc_481A0:
mov ecx, ecx
mov rax, rcx
neg rax
test edi, edi
loc_481AA:
cmovz rax, rcx
jmp loc_48041
| long long my_strntol_mb2_or_mb4(long long a1, long long a2, long long a3, unsigned int a4, _QWORD *a5, int *a6)
{
long long v6; // r15
long long ( *v8)(long long, _QWORD *, long long, long long); // r12
long long v9; // r13
int v10; // eax
int v11; // ecx
long long result; // rax
int v13; // eax
long long v14; // rcx
long long v15; // rbx
long long v16; // r8
unsigned long long v17; // rax
long long v18; // rsi
unsigned int v19; // esi
unsigned int v20; // edi
int v21; // esi
bool v22; // zf
unsigned int v24; // [rsp+1Ch] [rbp-44h]
BOOL v26; // [rsp+28h] [rbp-38h]
_QWORD v28[6]; // [rsp+30h] [rbp-30h] BYREF
v6 = a2;
v8 = *(long long ( **)(long long, _QWORD *, long long, long long))(*(_QWORD *)(a1 + 184) + 40LL);
v9 = a2 + a3;
*a6 = 0;
v10 = v8(a1, v28, a2, a2 + a3);
if ( v10 <= 0 )
{
LABEL_11:
if ( a5 )
*a5 = v6;
v11 = 33;
if ( !v10 )
v11 = 84;
*a6 = v11;
return 0LL;
}
v26 = 0;
while ( 1 )
{
if ( v28[0] > 42LL )
{
if ( v28[0] != 43LL )
{
if ( v28[0] != 45LL )
break;
v26 = !v26;
}
goto LABEL_10;
}
if ( v28[0] != 9LL && v28[0] != 32LL )
break;
LABEL_10:
v6 += (unsigned int)v10;
v10 = v8(a1, v28, v6, v9);
if ( v10 <= 0 )
goto LABEL_11;
}
v24 = 0xFFFFFFFF / a4;
v13 = v8(a1, v28, v6, v9);
if ( v13 > 0 )
{
LODWORD(v14) = 0;
v15 = v6;
v16 = 0LL;
while ( 1 )
{
v15 += (unsigned int)v13;
v17 = v28[0] - 48LL;
if ( (unsigned long long)(v28[0] - 48LL) > 9 )
{
if ( (unsigned long long)(v28[0] - 65LL) > 0x19 )
{
if ( (unsigned long long)(v28[0] - 97LL) > 0x19 )
goto LABEL_37;
v18 = v28[0] - 87LL;
}
else
{
v18 = v28[0] - 55LL;
}
v28[0] = v18;
v17 = v18;
}
else
{
v28[0] -= 48LL;
}
if ( (int)v17 >= (int)a4 )
goto LABEL_37;
v19 = 1;
if ( (unsigned int)v14 <= v24 )
{
if ( (_DWORD)v14 == v24 )
{
v20 = 0xFFFFFFFF / a4;
if ( v17 > 0xFFFFFFFF % a4 )
goto LABEL_32;
}
LODWORD(v14) = v17 + a4 * v14;
v19 = v16;
}
v20 = v14;
LABEL_32:
v13 = ((long long ( *)(long long, _QWORD *, long long, long long, long long))v8)(a1, v28, v15, v9, v16);
LODWORD(v14) = v20;
v16 = v19;
if ( v13 <= 0 )
goto LABEL_35;
}
}
v20 = 0;
v15 = v6;
v19 = 0;
LABEL_35:
if ( !v13 )
{
if ( a5 )
*a5 = v15;
*a6 = 84;
return 0LL;
}
LODWORD(v16) = v19;
LODWORD(v14) = v20;
LABEL_37:
if ( a5 )
*a5 = v15;
if ( v15 == v6 )
{
*a6 = 33;
return 0LL;
}
v21 = v16;
if ( (unsigned int)v14 >= 0x80000001 )
v21 = 1;
if ( (int)v14 < 0 )
LODWORD(v16) = 1;
if ( v26 )
LODWORD(v16) = v21;
if ( (_DWORD)v16 )
{
v22 = !v26;
*a6 = 34;
v14 = 0x7FFFFFFFLL;
result = 0xFFFFFFFF80000000LL;
}
else
{
v14 = (unsigned int)v14;
result = -(long long)(unsigned int)v14;
v22 = !v26;
}
if ( v22 )
return v14;
return result;
}
| my_strntol_mb2_or_mb4:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV qword ptr [RBP + -0x40],R8
MOV dword ptr [RBP + -0x34],ECX
MOV R13,RDX
MOV R15,RSI
MOV R14,RDI
MOV RAX,qword ptr [RDI + 0xb8]
MOV R12,qword ptr [RAX + 0x28]
ADD R13,RSI
MOV qword ptr [RBP + -0x50],R9
MOV dword ptr [R9],0x0
LEA RSI,[RBP + -0x30]
MOV RDX,R15
MOV RCX,R13
CALL R12
TEST EAX,EAX
JLE 0x0014801e
MOV dword ptr [RBP + -0x38],0x0
LEA RBX,[RBP + -0x30]
LAB_00147fd6:
MOV RCX,qword ptr [RBP + -0x30]
CMP RCX,0x2a
JG 0x00147fee
CMP RCX,0x9
JZ 0x00148006
CMP RCX,0x20
JZ 0x00148006
JMP 0x00148050
LAB_00147fee:
CMP RCX,0x2b
JZ 0x00148006
CMP RCX,0x2d
JNZ 0x00148050
XOR ECX,ECX
CMP dword ptr [RBP + -0x38],0x0
SETZ CL
MOV dword ptr [RBP + -0x38],ECX
LAB_00148006:
MOV EAX,EAX
ADD R15,RAX
MOV RDI,R14
MOV RSI,RBX
MOV RDX,R15
MOV RCX,R13
CALL R12
TEST EAX,EAX
JG 0x00147fd6
LAB_0014801e:
MOV RCX,qword ptr [RBP + -0x40]
TEST RCX,RCX
JZ 0x0014802a
MOV qword ptr [RCX],R15
LAB_0014802a:
TEST EAX,EAX
MOV EAX,0x54
MOV ECX,0x21
CMOVZ ECX,EAX
MOV RAX,qword ptr [RBP + -0x50]
MOV dword ptr [RAX],ECX
LAB_0014803f:
XOR EAX,EAX
LAB_00148041:
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00148050:
MOV EAX,0xffffffff
XOR EDX,EDX
DIV dword ptr [RBP + -0x34]
MOV EBX,EDX
MOV dword ptr [RBP + -0x44],EAX
LEA RSI,[RBP + -0x30]
MOV RDI,R14
MOV RDX,R15
MOV RCX,R13
CALL R12
TEST EAX,EAX
JLE 0x00148116
MOV ECX,EBX
MOV qword ptr [RBP + -0x60],RCX
XOR ECX,ECX
MOV RBX,R15
XOR R8D,R8D
LAB_00148085:
MOV RSI,RBX
MOV EBX,EAX
ADD RBX,RSI
MOV RSI,qword ptr [RBP + -0x30]
LEA RAX,[RSI + -0x30]
CMP RAX,0x9
JA 0x001480a1
MOV qword ptr [RBP + -0x30],RAX
JMP 0x001480c6
LAB_001480a1:
LEA RAX,[RSI + -0x41]
CMP RAX,0x19
JA 0x001480b1
ADD RSI,-0x37
JMP 0x001480bf
LAB_001480b1:
LEA RAX,[RSI + -0x61]
CMP RAX,0x19
JA 0x00148126
ADD RSI,-0x57
LAB_001480bf:
MOV qword ptr [RBP + -0x30],RSI
MOV RAX,RSI
LAB_001480c6:
CMP EAX,dword ptr [RBP + -0x34]
JGE 0x00148126
MOV ESI,0x1
CMP ECX,dword ptr [RBP + -0x44]
JA 0x001480e9
JNZ 0x001480e0
MOV EDI,dword ptr [RBP + -0x44]
CMP RAX,qword ptr [RBP + -0x60]
JA 0x001480eb
LAB_001480e0:
IMUL ECX,dword ptr [RBP + -0x34]
ADD ECX,EAX
MOV ESI,R8D
LAB_001480e9:
MOV EDI,ECX
LAB_001480eb:
MOV dword ptr [RBP + -0x54],EDI
MOV dword ptr [RBP + -0x58],ESI
MOV RDI,R14
LEA RSI,[RBP + -0x30]
MOV RDX,RBX
MOV RCX,R13
CALL R12
MOV EDI,dword ptr [RBP + -0x54]
MOV ESI,dword ptr [RBP + -0x58]
MOV ECX,EDI
MOV R8D,ESI
TEST EAX,EAX
JG 0x00148085
JMP 0x0014811d
LAB_00148116:
XOR EDI,EDI
MOV RBX,R15
XOR ESI,ESI
LAB_0014811d:
TEST EAX,EAX
JZ 0x00148185
MOV R8D,ESI
MOV ECX,EDI
LAB_00148126:
MOV RAX,qword ptr [RBP + -0x40]
TEST RAX,RAX
JZ 0x00148132
MOV qword ptr [RAX],RBX
LAB_00148132:
CMP RBX,R15
JZ 0x00148176
CMP ECX,0x80000001
MOV EAX,0x1
MOV ESI,R8D
CMOVNC ESI,EAX
TEST ECX,ECX
CMOVS R8D,EAX
MOV EDI,dword ptr [RBP + -0x38]
TEST EDI,EDI
CMOVNZ R8D,ESI
TEST R8D,R8D
JZ 0x001481a0
TEST EDI,EDI
MOV RAX,qword ptr [RBP + -0x50]
MOV dword ptr [RAX],0x22
MOV ECX,0x7fffffff
MOV RAX,-0x80000000
JMP 0x001481aa
LAB_00148176:
MOV RAX,qword ptr [RBP + -0x50]
MOV dword ptr [RAX],0x21
JMP 0x0014803f
LAB_00148185:
MOV RAX,qword ptr [RBP + -0x40]
TEST RAX,RAX
JZ 0x00148191
MOV qword ptr [RAX],RBX
LAB_00148191:
MOV RAX,qword ptr [RBP + -0x50]
MOV dword ptr [RAX],0x54
JMP 0x0014803f
LAB_001481a0:
MOV ECX,ECX
MOV RAX,RCX
NEG RAX
TEST EDI,EDI
LAB_001481aa:
CMOVZ RAX,RCX
JMP 0x00148041
|
ulong my_strntol_mb2_or_mb4
(long param_1,long param_2,long param_3,uint param_4,long *param_5,
int4 *param_6)
{
code *pcVar1;
bool bVar2;
bool bVar3;
bool bVar4;
uint uVar5;
uint uVar6;
ulong uVar7;
int4 uVar8;
uint uVar9;
ulong uVar10;
long lVar11;
ulong local_38;
pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28);
param_3 = param_3 + param_2;
*param_6 = 0;
uVar5 = (*pcVar1)(param_1,&local_38,param_2,param_3);
if (0 < (int)uVar5) {
bVar2 = false;
do {
if ((long)local_38 < 0x2b) {
if ((local_38 != 9) && (local_38 != 0x20)) {
LAB_00148050:
uVar5 = (uint)(0xffffffff / (ulong)param_4);
uVar6 = (*pcVar1)(param_1,&local_38,param_2,param_3);
lVar11 = param_2;
if ((int)uVar6 < 1) {
uVar9 = 0;
bVar3 = false;
goto LAB_0014811d;
}
uVar9 = 0;
bVar3 = false;
goto LAB_00148085;
}
}
else if (local_38 != 0x2b) {
if (local_38 != 0x2d) goto LAB_00148050;
bVar2 = !bVar2;
}
param_2 = param_2 + (ulong)uVar5;
uVar5 = (*pcVar1)(param_1,&local_38,param_2,param_3);
} while (0 < (int)uVar5);
}
if (param_5 != (long *)0x0) {
*param_5 = param_2;
}
uVar8 = 0x21;
if (uVar5 == 0) {
uVar8 = 0x54;
}
*param_6 = uVar8;
return 0;
while( true ) {
if ((int)param_4 <= (int)uVar7) goto LAB_00148126;
uVar6 = uVar9;
bVar4 = true;
if ((uVar9 <= uVar5) &&
((uVar9 != uVar5 || (uVar6 = uVar5, bVar4 = true, uVar7 <= 0xffffffffU % (ulong)param_4)))) {
uVar6 = uVar9 * param_4 + (int)uVar7;
bVar4 = bVar3;
}
bVar3 = bVar4;
uVar9 = uVar6;
local_38 = uVar7;
uVar6 = (*pcVar1)(param_1,&local_38,lVar11,param_3);
if ((int)uVar6 < 1) break;
LAB_00148085:
lVar11 = (ulong)uVar6 + lVar11;
uVar7 = local_38 - 0x30;
if (9 < uVar7) {
if (local_38 - 0x41 < 0x1a) {
uVar7 = local_38 - 0x37;
}
else {
if (0x19 < local_38 - 0x61) goto LAB_00148126;
uVar7 = local_38 - 0x57;
}
}
}
LAB_0014811d:
if (uVar6 == 0) {
if (param_5 != (long *)0x0) {
*param_5 = lVar11;
}
*param_6 = 0x54;
}
else {
LAB_00148126:
if (param_5 != (long *)0x0) {
*param_5 = lVar11;
}
if (lVar11 != param_2) {
bVar4 = bVar3;
if (0x80000000 < uVar9) {
bVar4 = true;
}
if ((int)uVar9 < 0) {
bVar3 = true;
}
if (bVar2) {
bVar3 = bVar4;
}
if (bVar3) {
*param_6 = 0x22;
uVar10 = 0x7fffffff;
uVar7 = 0xffffffff80000000;
}
else {
uVar10 = (ulong)uVar9;
uVar7 = -uVar10;
}
if (!bVar2) {
return uVar10;
}
return uVar7;
}
*param_6 = 0x21;
}
return 0;
}
| |
23,388 | 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>::push_back(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>&&) | monkey531[P]llama/common/json.hpp | void push_back(basic_json&& val)
{
// push_back only works for null objects or arrays
if (JSON_HEDLEY_UNLIKELY(!(is_null() || is_array())))
{
JSON_THROW(type_error::create(308, detail::concat("cannot use push_back() with ", type_name()), this));
}
// transform null object into an array
if (is_null())
{
m_data.m_type = value_t::array;
m_data.m_value = value_t::array;
assert_invariant();
}
// add element to array (move semantics)
const auto old_capacity = m_data.m_value.array->capacity();
m_data.m_value.array->push_back(std::move(val));
set_parent(m_data.m_value.array->back(), old_capacity);
// if val is moved from, basic_json move constructor marks it null, so we do not call the destructor
} | O2 | cpp | nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::push_back(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>&&):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movzbl (%rdi), %eax
testl %eax, %eax
jne 0x81343
movb $0x2, (%r14)
callq 0x2b2a8
movq %rax, 0x8(%r14)
pushq $0x1
popq %rsi
movq %r14, %rdi
callq 0x2b16e
jmp 0x81348
cmpl $0x2, %eax
jne 0x8135c
movq 0x8(%r14), %rdi
movq %rbx, %rsi
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
jmp 0x2f59a
pushq $0x20
popq %rdi
callq 0x213a0
movq %rax, %rbx
movq %r14, %rdi
callq 0x30c70
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
leaq 0x1cdf5(%rip), %rsi # 0x9e173
leaq 0x10(%rsp), %rdi
callq 0x4772a
movb $0x1, %bpl
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
movl $0x134, %esi # imm = 0x134
movq %r14, %rcx
callq 0x30b24
xorl %ebp, %ebp
leaq 0x58ba7(%rip), %rsi # 0xd9f50
leaq -0x53ba4(%rip), %rdx # 0x2d80c
movq %rbx, %rdi
callq 0x21b70
movq %rax, %r14
leaq 0x10(%rsp), %rdi
callq 0x21dc8
testb %bpl, %bpl
jne 0x813cf
jmp 0x813d7
movq %rax, %r14
movq %rbx, %rdi
callq 0x21530
movq %r14, %rdi
callq 0x21be0
nop
| _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backEOSD_:
push rbp; char
push r14; int
push rbx; int
sub rsp, 30h
mov rbx, rsi
mov r14, rdi
movzx eax, byte ptr [rdi]
test eax, eax
jnz short loc_81343
mov byte ptr [r14], 2
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createIS3_ISD_SaISD_EEJEEEPT_DpOT0_; 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>::create<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>>>()
mov [r14+8], rax
push 1
pop rsi
mov rdi, r14
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)
jmp short loc_81348
loc_81343:
cmp eax, 2
jnz short loc_8135C
loc_81348:
mov rdi, [r14+8]
mov rsi, rbx
add rsp, 30h
pop rbx
pop r14
pop rbp
jmp _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> &&)
loc_8135C:
push 20h ; ' '
pop rdi; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void)
lea rdx, [rsp+48h+var_40]
mov [rdx], rax
lea rsi, aCannotUsePushB; "cannot use push_back() with "
lea rdi, [rsp+48h+var_38]
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA29_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(char const(&)[29],char const* &&)
mov bpl, 1
lea rdx, [rsp+48h+var_38]
mov rdi, rbx; this
mov esi, 134h; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rdi, [rsp+48h+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
jnz short loc_813CF
jmp short loc_813D7
mov r14, rax
loc_813CF:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_813D7:
mov rdi, r14
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back(
long long a1,
long long a2)
{
nlohmann::json_abi_v3_11_3::detail::type_error *exception; // rbx
const char *v4; // [rsp+8h] [rbp-40h] BYREF
_BYTE v5[56]; // [rsp+10h] [rbp-38h] BYREF
if ( *(_BYTE *)a1 )
{
if ( *(_BYTE *)a1 != 2 )
{
exception = (nlohmann::json_abi_v3_11_3::detail::type_error *)__cxa_allocate_exception(0x20uLL);
v4 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name((unsigned __int8 *)a1);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(
(long long)v5,
(long long)"cannot use push_back() with ",
&v4);
ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
exception,
308,
(long long)v5);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
}
else
{
*(_BYTE *)a1 = 2;
*(_QWORD *)(a1 + 8) = 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>::create<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>>>();
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1);
}
return 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 *)(a1 + 8),
a2);
}
| push_back:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV RBX,RSI
MOV R14,RDI
MOVZX EAX,byte ptr [RDI]
TEST EAX,EAX
JNZ 0x00181343
MOV byte ptr [R14],0x2
CALL 0x0012b2a8
MOV qword ptr [R14 + 0x8],RAX
PUSH 0x1
POP RSI
MOV RDI,R14
CALL 0x0012b16e
JMP 0x00181348
LAB_00181343:
CMP EAX,0x2
JNZ 0x0018135c
LAB_00181348:
MOV RDI,qword ptr [R14 + 0x8]
MOV RSI,RBX
ADD RSP,0x30
POP RBX
POP R14
POP RBP
JMP 0x0012f59a
LAB_0018135c:
PUSH 0x20
POP RDI
CALL 0x001213a0
MOV RBX,RAX
MOV RDI,R14
CALL 0x00130c70
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],RAX
LAB_00181377:
LEA RSI,[0x19e173]
LEA RDI,[RSP + 0x10]
CALL 0x0014772a
MOV BPL,0x1
LAB_0018138b:
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
MOV ESI,0x134
MOV RCX,R14
CALL 0x00130b24
XOR EBP,EBP
LEA RSI,[0x1d9f50]
LEA RDX,[0x12d80c]
MOV RDI,RBX
CALL 0x00121b70
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >,
void>::push_back(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>&&) */
void __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::push_back(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,basic_json *param_1)
{
vector *pvVar1;
int8 uVar2;
char *local_40;
detail local_38 [32];
if (*this == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x0) {
*this = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2;
pvVar1 = create<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>>>>
();
*(vector **)(this + 8) = pvVar1;
assert_invariant(SUB81(this,0));
}
else if (*this != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2) {
uVar2 = __cxa_allocate_exception(0x20);
local_40 = (char *)type_name(this);
/* try { // try from 00181377 to 00181387 has its CatchHandler @ 001813cc */
detail::concat<std::__cxx11::string,char_const(&)[29],char_const*>
(local_38,"cannot use push_back() with ",&local_40);
/* try { // try from 0018138b to 001813b7 has its CatchHandler @ 001813b8 */
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar2,0x134,local_38,this);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar2,&detail::type_error::typeinfo,detail::exception::~exception);
}
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>>>
**)(this + 8),param_1);
return;
}
| |
23,389 | 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>::push_back(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>&&) | monkey531[P]llama/common/json.hpp | void push_back(basic_json&& val)
{
// push_back only works for null objects or arrays
if (JSON_HEDLEY_UNLIKELY(!(is_null() || is_array())))
{
JSON_THROW(type_error::create(308, detail::concat("cannot use push_back() with ", type_name()), this));
}
// transform null object into an array
if (is_null())
{
m_data.m_type = value_t::array;
m_data.m_value = value_t::array;
assert_invariant();
}
// add element to array (move semantics)
const auto old_capacity = m_data.m_value.array->capacity();
m_data.m_value.array->push_back(std::move(val));
set_parent(m_data.m_value.array->back(), old_capacity);
// if val is moved from, basic_json move constructor marks it null, so we do not call the destructor
} | O3 | cpp | nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::push_back(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>&&):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movzbl (%rdi), %eax
testl %eax, %eax
jne 0x983a0
movb $0x2, (%r14)
movl $0x18, %edi
callq 0x196a0
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
movq %rax, 0x8(%r14)
movq %r14, %rdi
movl $0x1, %esi
callq 0x284e2
jmp 0x983a5
cmpl $0x2, %eax
jne 0x983b9
movq 0x8(%r14), %rdi
movq %rbx, %rsi
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
jmp 0x2d06c
movl $0x20, %edi
callq 0x19370
movq %rax, %rbx
movq %r14, %rdi
callq 0x2e9dc
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
leaq 0x23d46(%rip), %rsi # 0xbc123
leaq 0x10(%rsp), %rdi
callq 0x4b972
movb $0x1, %bpl
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
movl $0x134, %esi # imm = 0x134
movq %r14, %rcx
callq 0x2e788
xorl %ebp, %ebp
leaq 0x51b48(%rip), %rsi # 0xe9f50
leaq -0x6d7bf(%rip), %rdx # 0x2ac50
movq %rbx, %rdi
callq 0x19b70
movq %rax, %r14
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x98435
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x196b0
testb %bpl, %bpl
jne 0x9843f
jmp 0x98447
movq %rax, %r14
movq %rbx, %rdi
callq 0x19510
movq %r14, %rdi
callq 0x19be0
nop
| _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backEOSD_:
push rbp; char
push r14; int
push rbx; __int64
sub rsp, 30h
mov rbx, rsi
mov r14, rdi
movzx eax, byte ptr [rdi]
test eax, eax
jnz short loc_983A0
mov byte ptr [r14], 2
mov edi, 18h; unsigned __int64
call __Znwm; operator new(ulong)
xorps xmm0, xmm0
movups xmmword ptr [rax], xmm0
mov qword ptr [rax+10h], 0
mov [r14+8], rax
mov rdi, r14
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
jmp short loc_983A5
loc_983A0:
cmp eax, 2
jnz short loc_983B9
loc_983A5:
mov rdi, [r14+8]
mov rsi, rbx
add rsp, 30h
pop rbx
pop r14
pop rbp
jmp _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> &&)
loc_983B9:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void)
lea rdx, [rsp+48h+var_40]
mov [rdx], rax
lea rsi, aCannotUsePushB; "cannot use push_back() with "
lea rdi, [rsp+48h+var_38]
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA29_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(char const(&)[29],char const* &&)
mov bpl, 1
lea rdx, [rsp+48h+var_38]
mov rdi, rbx; this
mov esi, 134h; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+48h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_98435
mov rsi, [rsp+48h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_98435:
test bpl, bpl
jnz short loc_9843F
jmp short loc_98447
mov r14, rax
loc_9843F:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_98447:
mov rdi, r14
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back(
long long a1,
long long a2)
{
long long v2; // rax
nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx
const char *v5; // [rsp+8h] [rbp-40h] BYREF
_QWORD v6[2]; // [rsp+10h] [rbp-38h] BYREF
if ( *(_BYTE *)a1 )
{
if ( *(_BYTE *)a1 != 2 )
{
exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL);
v5 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name((unsigned __int8 *)a1);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(
(long long)v6,
(long long)"cannot use push_back() with ",
&v5);
ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
exception,
308,
v6);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
}
else
{
*(_BYTE *)a1 = 2;
v2 = operator new(0x18uLL);
*(_OWORD *)v2 = 0LL;
*(_QWORD *)(v2 + 16) = 0LL;
*(_QWORD *)(a1 + 8) = v2;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1);
}
return 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 *)(a1 + 8),
a2);
}
| push_back:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV RBX,RSI
MOV R14,RDI
MOVZX EAX,byte ptr [RDI]
TEST EAX,EAX
JNZ 0x001983a0
MOV byte ptr [R14],0x2
MOV EDI,0x18
CALL 0x001196a0
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RAX],XMM0
MOV qword ptr [RAX + 0x10],0x0
MOV qword ptr [R14 + 0x8],RAX
MOV RDI,R14
MOV ESI,0x1
CALL 0x001284e2
JMP 0x001983a5
LAB_001983a0:
CMP EAX,0x2
JNZ 0x001983b9
LAB_001983a5:
MOV RDI,qword ptr [R14 + 0x8]
MOV RSI,RBX
ADD RSP,0x30
POP RBX
POP R14
POP RBP
JMP 0x0012d06c
LAB_001983b9:
MOV EDI,0x20
CALL 0x00119370
MOV RBX,RAX
MOV RDI,R14
CALL 0x0012e9dc
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],RAX
LAB_001983d6:
LEA RSI,[0x1bc123]
LEA RDI,[RSP + 0x10]
CALL 0x0014b972
MOV BPL,0x1
LAB_001983ea:
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
MOV ESI,0x134
MOV RCX,R14
CALL 0x0012e788
XOR EBP,EBP
LEA RSI,[0x1e9f50]
LEA RDX,[0x12ac50]
MOV RDI,RBX
CALL 0x00119b70
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >,
void>::push_back(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>&&) */
void __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::push_back(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,basic_json *param_1)
{
int8 *puVar1;
int8 uVar2;
char *local_40;
detail local_38 [32];
if (*this == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x0) {
*this = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2;
puVar1 = (int8 *)operator_new(0x18);
*puVar1 = 0;
puVar1[1] = 0;
puVar1[2] = 0;
*(int8 **)(this + 8) = puVar1;
assert_invariant(SUB81(this,0));
}
else if (*this != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2) {
uVar2 = __cxa_allocate_exception(0x20);
local_40 = (char *)type_name(this);
/* try { // try from 001983d6 to 001983e6 has its CatchHandler @ 0019843c */
detail::concat<std::__cxx11::string,char_const(&)[29],char_const*>
(local_38,"cannot use push_back() with ",&local_40);
/* try { // try from 001983ea to 00198416 has its CatchHandler @ 00198417 */
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar2,0x134,local_38,this);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar2,&detail::type_error::typeinfo,detail::exception::~exception);
}
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>>>
**)(this + 8),param_1);
return;
}
| |
23,390 | exchange_int16s | bluesky950520[P]quickjs/cutils.c | static void exchange_int16s(void *a, void *b, size_t size) {
uint16_t *ap = (uint16_t *)a;
uint16_t *bp = (uint16_t *)b;
for (size /= sizeof(uint16_t); size-- != 0;) {
uint16_t t = *ap;
*ap++ = *bp;
*bp++ = t;
}
} | O0 | c | exchange_int16s:
movq %rdi, -0x8(%rsp)
movq %rsi, -0x10(%rsp)
movq %rdx, -0x18(%rsp)
movq -0x8(%rsp), %rax
movq %rax, -0x20(%rsp)
movq -0x10(%rsp), %rax
movq %rax, -0x28(%rsp)
movq -0x18(%rsp), %rax
shrq %rax
movq %rax, -0x18(%rsp)
movq -0x18(%rsp), %rax
movq %rax, %rcx
addq $-0x1, %rcx
movq %rcx, -0x18(%rsp)
cmpq $0x0, %rax
je 0x2150b
movq -0x20(%rsp), %rax
movw (%rax), %ax
movw %ax, -0x2a(%rsp)
movq -0x28(%rsp), %rax
movw (%rax), %cx
movq -0x20(%rsp), %rax
movq %rax, %rdx
addq $0x2, %rdx
movq %rdx, -0x20(%rsp)
movw %cx, (%rax)
movw -0x2a(%rsp), %cx
movq -0x28(%rsp), %rax
movq %rax, %rdx
addq $0x2, %rdx
movq %rdx, -0x28(%rsp)
movw %cx, (%rax)
jmp 0x214b0
retq
nopl (%rax)
| exchange_int16s:
mov [rsp+var_8], rdi
mov [rsp+var_10], rsi
mov [rsp+var_18], rdx
mov rax, [rsp+var_8]
mov [rsp+var_20], rax
mov rax, [rsp+var_10]
mov [rsp+var_28], rax
mov rax, [rsp+var_18]
shr rax, 1
mov [rsp+var_18], rax
loc_214B0:
mov rax, [rsp+var_18]
mov rcx, rax
add rcx, 0FFFFFFFFFFFFFFFFh
mov [rsp+var_18], rcx
cmp rax, 0
jz short locret_2150B
mov rax, [rsp+var_20]
mov ax, [rax]
mov [rsp+var_2A], ax
mov rax, [rsp+var_28]
mov cx, [rax]
mov rax, [rsp+var_20]
mov rdx, rax
add rdx, 2
mov [rsp+var_20], rdx
mov [rax], cx
mov cx, [rsp+var_2A]
mov rax, [rsp+var_28]
mov rdx, rax
add rdx, 2
mov [rsp+var_28], rdx
mov [rax], cx
jmp short loc_214B0
locret_2150B:
retn
| long long exchange_int16s(__int16 *a1, __int16 *a2, unsigned long long a3)
{
long long result; // rax
__int16 *v4; // rax
__int16 *v5; // rax
__int16 v6; // [rsp+0h] [rbp-2Ah]
unsigned long long v9; // [rsp+12h] [rbp-18h]
v9 = a3 >> 1;
while ( 1 )
{
result = v9--;
if ( !result )
break;
v6 = *a1;
v4 = a1++;
*v4 = *a2;
v5 = a2++;
*v5 = v6;
}
return result;
}
| exchange_int16s:
MOV qword ptr [RSP + -0x8],RDI
MOV qword ptr [RSP + -0x10],RSI
MOV qword ptr [RSP + -0x18],RDX
MOV RAX,qword ptr [RSP + -0x8]
MOV qword ptr [RSP + -0x20],RAX
MOV RAX,qword ptr [RSP + -0x10]
MOV qword ptr [RSP + -0x28],RAX
MOV RAX,qword ptr [RSP + -0x18]
SHR RAX,0x1
MOV qword ptr [RSP + -0x18],RAX
LAB_001214b0:
MOV RAX,qword ptr [RSP + -0x18]
MOV RCX,RAX
ADD RCX,-0x1
MOV qword ptr [RSP + -0x18],RCX
CMP RAX,0x0
JZ 0x0012150b
MOV RAX,qword ptr [RSP + -0x20]
MOV AX,word ptr [RAX]
MOV word ptr [RSP + -0x2a],AX
MOV RAX,qword ptr [RSP + -0x28]
MOV CX,word ptr [RAX]
MOV RAX,qword ptr [RSP + -0x20]
MOV RDX,RAX
ADD RDX,0x2
MOV qword ptr [RSP + -0x20],RDX
MOV word ptr [RAX],CX
MOV CX,word ptr [RSP + -0x2a]
MOV RAX,qword ptr [RSP + -0x28]
MOV RDX,RAX
ADD RDX,0x2
MOV qword ptr [RSP + -0x28],RDX
MOV word ptr [RAX],CX
JMP 0x001214b0
LAB_0012150b:
RET
|
void exchange_int16s(int2 *param_1,int2 *param_2,ulong param_3)
{
int2 uVar1;
int2 *local_28;
int2 *local_20;
ulong local_18;
local_28 = param_2;
local_20 = param_1;
local_18 = param_3 >> 1;
while (local_18 != 0) {
uVar1 = *local_20;
*local_20 = *local_28;
*local_28 = uVar1;
local_28 = local_28 + 1;
local_20 = local_20 + 1;
local_18 = local_18 - 1;
}
return;
}
| |
23,391 | exchange_int16s | bluesky950520[P]quickjs/cutils.c | static void exchange_int16s(void *a, void *b, size_t size) {
uint16_t *ap = (uint16_t *)a;
uint16_t *bp = (uint16_t *)b;
for (size /= sizeof(uint16_t); size-- != 0;) {
uint16_t t = *ap;
*ap++ = *bp;
*bp++ = t;
}
} | O1 | c | exchange_int16s:
cmpq $0x2, %rdx
jb 0x1c969
shrq %rdx
xorl %eax, %eax
movzwl (%rdi,%rax,2), %ecx
movzwl (%rsi,%rax,2), %r8d
movw %r8w, (%rdi,%rax,2)
movw %cx, (%rsi,%rax,2)
incq %rax
cmpq %rax, %rdx
jne 0x1c94f
retq
| exchange_int16s:
cmp rdx, 2
jb short locret_1C969
shr rdx, 1
xor eax, eax
loc_1C94F:
movzx ecx, word ptr [rdi+rax*2]
movzx r8d, word ptr [rsi+rax*2]
mov [rdi+rax*2], r8w
mov [rsi+rax*2], cx
inc rax
cmp rdx, rax
jnz short loc_1C94F
locret_1C969:
retn
| void exchange_int16s(long long a1, long long a2, unsigned long long a3)
{
unsigned long long v3; // rdx
long long v4; // rax
__int16 v5; // cx
if ( a3 >= 2 )
{
v3 = a3 >> 1;
v4 = 0LL;
do
{
v5 = *(_WORD *)(a1 + 2 * v4);
*(_WORD *)(a1 + 2 * v4) = *(_WORD *)(a2 + 2 * v4);
*(_WORD *)(a2 + 2 * v4++) = v5;
}
while ( v3 != v4 );
}
}
| exchange_int16s:
CMP RDX,0x2
JC 0x0011c969
SHR RDX,0x1
XOR EAX,EAX
LAB_0011c94f:
MOVZX ECX,word ptr [RDI + RAX*0x2]
MOVZX R8D,word ptr [RSI + RAX*0x2]
MOV word ptr [RDI + RAX*0x2],R8W
MOV word ptr [RSI + RAX*0x2],CX
INC RAX
CMP RDX,RAX
JNZ 0x0011c94f
LAB_0011c969:
RET
|
void exchange_int16s(long param_1,long param_2,ulong param_3)
{
int2 uVar1;
ulong uVar2;
if (1 < param_3) {
uVar2 = 0;
do {
uVar1 = *(int2 *)(param_1 + uVar2 * 2);
*(int2 *)(param_1 + uVar2 * 2) = *(int2 *)(param_2 + uVar2 * 2);
*(int2 *)(param_2 + uVar2 * 2) = uVar1;
uVar2 = uVar2 + 1;
} while (param_3 >> 1 != uVar2);
}
return;
}
| |
23,392 | protocol::utils::make_entity_head(Dimension*, entt::entity, unsigned int) | untodesu[P]voxelius/game/shared/protocol.cc | ENetPacket *protocol::utils::make_entity_head(Dimension *dimension, entt::entity entity, enet_uint32 flags)
{
if(auto component = dimension->entities.try_get<HeadComponent>(entity)) {
protocol::EntityHead packet;
packet.entity = entity;
packet.angles = component->angles;
return protocol::encode(packet, flags);
}
return nullptr;
} | O3 | cpp | protocol::utils::make_entity_head(Dimension*, entt::entity, unsigned int):
pushq %rbp
pushq %rbx
subq $0x28, %rsp
movl %edx, %ebx
movl %esi, %ebp
addq $0x158, %rdi # imm = 0x158
callq 0x7de58
testq %rax, %rax
je 0x7da3f
leaq 0x8(%rsp), %rdi
movq $0x0, 0x8(%rdi)
leaq 0x1d1afd(%rip), %rcx # 0x24f520
movq %rcx, (%rdi)
movl %ebp, 0x10(%rdi)
movq (%rax), %rcx
movq %rcx, 0x14(%rdi)
movl 0x8(%rax), %eax
movl %eax, 0x1c(%rdi)
movl %ebx, %esi
callq 0x7c2d9
jmp 0x7da41
xorl %eax, %eax
addq $0x28, %rsp
popq %rbx
popq %rbp
retq
| _ZN8protocol5utils16make_entity_headEP9DimensionN4entt6entityEj:
push rbp
push rbx
sub rsp, 28h
mov ebx, edx
mov ebp, esi
add rdi, 158h
call _ZNK4entt14basic_registryINS_6entityESaIS1_EE7try_getIJ13HeadComponentEEEDaS1_
test rax, rax
jz short loc_7DA3F
lea rdi, [rsp+38h+var_30]; this
mov qword ptr [rdi+8], 0
lea rcx, off_24F520
mov [rdi], rcx
mov [rdi+10h], ebp
mov rcx, [rax]
mov [rdi+14h], rcx
mov eax, [rax+8]
mov [rdi+1Ch], eax
mov esi, ebx; protocol::EntityHead *
call _ZN8protocol6encodeERKNS_10EntityHeadEj; protocol::encode(protocol::EntityHead const&,uint)
jmp short loc_7DA41
loc_7DA3F:
xor eax, eax
loc_7DA41:
add rsp, 28h
pop rbx
pop rbp
retn
| long long protocol::utils::make_entity_head(long long a1, int a2, unsigned int a3)
{
long long v4; // rax
_QWORD v6[2]; // [rsp+8h] [rbp-30h] BYREF
int v7; // [rsp+18h] [rbp-20h]
long long v8; // [rsp+1Ch] [rbp-1Ch]
int v9; // [rsp+24h] [rbp-14h]
v4 = entt::basic_registry<entt::entity,std::allocator<entt::entity>>::try_get<HeadComponent>(a1 + 344);
if ( !v4 )
return 0LL;
v6[1] = 0LL;
v6[0] = &off_24F520;
v7 = a2;
v8 = *(_QWORD *)v4;
v9 = *(_DWORD *)(v4 + 8);
return protocol::encode((protocol *)v6, (const protocol::EntityHead *)a3);
}
| make_entity_head:
PUSH RBP
PUSH RBX
SUB RSP,0x28
MOV EBX,EDX
MOV EBP,ESI
ADD RDI,0x158
CALL 0x0017de58
TEST RAX,RAX
JZ 0x0017da3f
LEA RDI,[RSP + 0x8]
MOV qword ptr [RDI + 0x8],0x0
LEA RCX,[0x34f520]
MOV qword ptr [RDI],RCX
MOV dword ptr [RDI + 0x10],EBP
MOV RCX,qword ptr [RAX]
MOV qword ptr [RDI + 0x14],RCX
MOV EAX,dword ptr [RAX + 0x8]
MOV dword ptr [RDI + 0x1c],EAX
MOV ESI,EBX
CALL 0x0017c2d9
JMP 0x0017da41
LAB_0017da3f:
XOR EAX,EAX
LAB_0017da41:
ADD RSP,0x28
POP RBX
POP RBP
RET
|
/* protocol::utils::make_entity_head(Dimension*, entt::entity, unsigned int) */
int8 protocol::utils::make_entity_head(long param_1,int4 param_2,uint param_3)
{
int8 *puVar1;
int8 uVar2;
int **local_30;
int8 local_28;
int4 local_20;
int8 local_1c;
int4 local_14;
puVar1 = (int8 *)
entt::basic_registry<entt::entity,std::allocator<entt::entity>>::try_get<HeadComponent>
((basic_registry<entt::entity,std::allocator<entt::entity>> *)(param_1 + 0x158)
);
if (puVar1 == (int8 *)0x0) {
uVar2 = 0;
}
else {
local_28 = 0;
local_30 = &PTR__Base_0034f520;
local_1c = *puVar1;
local_14 = *(int4 *)(puVar1 + 1);
local_20 = param_2;
uVar2 = protocol::encode((EntityHead *)&local_30,param_3);
}
return uVar2;
}
| |
23,393 | dump_datapage | eloqsql/storage/maria/ma_loghandler.c | static void dump_datapage(uchar *buffer, File handler)
{
uchar *ptr;
ulong offset;
uint32 page, file;
uint header_len;
printf(" Page: %ld File number: %ld\n",
(ulong) (page= uint3korr(buffer)),
(ulong) (file= uint3korr(buffer + 3)));
if (page == 0)
printf(" WARNING: page == 0!!!\n");
if (file == 0)
printf(" WARNING: file == 0!!!\n");
offset= page * TRANSLOG_PAGE_SIZE;
printf(" Flags (0x%x):\n", (uint) buffer[TRANSLOG_PAGE_FLAGS]);
if (buffer[TRANSLOG_PAGE_FLAGS])
{
if (buffer[TRANSLOG_PAGE_FLAGS] & TRANSLOG_PAGE_CRC)
printf(" Page CRC\n");
if (buffer[TRANSLOG_PAGE_FLAGS] & TRANSLOG_SECTOR_PROTECTION)
printf(" Sector protection\n");
if (buffer[TRANSLOG_PAGE_FLAGS] & TRANSLOG_RECORD_CRC)
printf(" Record CRC (WARNING: not yet implemented!!!)\n");
if (buffer[TRANSLOG_PAGE_FLAGS] & ~(TRANSLOG_PAGE_CRC |
TRANSLOG_SECTOR_PROTECTION |
TRANSLOG_RECORD_CRC))
{
printf(" WARNING: unknown flags (stop interpretation)!!!\n");
return;
}
}
else
printf(" No flags\n");
printf(" Page header length: %u\n",
(header_len= page_overhead[buffer[TRANSLOG_PAGE_FLAGS]]));
if (buffer[TRANSLOG_PAGE_FLAGS] & TRANSLOG_RECORD_CRC)
{
uint32 crc= uint4korr(buffer + TRANSLOG_PAGE_FLAGS + 1);
uint32 ccrc;
printf (" Page CRC 0x%04lx\n", (ulong) crc);
ccrc= translog_crc(buffer + header_len, TRANSLOG_PAGE_SIZE - header_len);
if (crc != ccrc)
printf(" WARNING: calculated CRC: 0x%04lx!!!\n", (ulong) ccrc);
}
if (buffer[TRANSLOG_PAGE_FLAGS] & TRANSLOG_SECTOR_PROTECTION)
{
TRANSLOG_FILE tfile;
{
uchar *table= buffer + header_len -
TRANSLOG_PAGE_SIZE / DISK_DRIVE_SECTOR_SIZE;
uint i;
printf(" Sector protection current value: 0x%02x\n", (uint) table[0]);
for (i= 1; i < TRANSLOG_PAGE_SIZE / DISK_DRIVE_SECTOR_SIZE; i++)
{
printf(" Sector protection in sector: 0x%02x saved value 0x%02x\n",
(uint)buffer[i * DISK_DRIVE_SECTOR_SIZE],
(uint)table[i]);
}
}
tfile.number= file;
bzero(&tfile.handler, sizeof(tfile.handler));
tfile.handler.file= handler;
tfile.was_recovered= 0;
tfile.is_sync= 1;
if (translog_check_sector_protection(buffer, &tfile))
printf(" WARNING: sector protection found problems!!!\n");
}
ptr= buffer + header_len;
while (ptr && ptr < buffer + TRANSLOG_PAGE_SIZE)
{
printf(" Chunk %d %lld:\n",
file,((longlong) (ptr - buffer)+ offset));
ptr= dump_chunk(buffer, ptr);
}
} | O0 | c | dump_datapage:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
movzbl (%rax), %eax
movq -0x8(%rbp), %rcx
movzbl 0x1(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x8(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movl %eax, -0x24(%rbp)
movl %eax, %eax
movl %eax, %esi
movq -0x8(%rbp), %rax
movzbl 0x3(%rax), %eax
movq -0x8(%rbp), %rcx
movzbl 0x4(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x8(%rbp), %rcx
movzbl 0x5(%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movl %eax, -0x28(%rbp)
movl %eax, %eax
movl %eax, %edx
leaq 0x1230f3(%rip), %rdi # 0x15788d
movb $0x0, %al
callq 0x2a060
cmpl $0x0, -0x24(%rbp)
jne 0x347b5
leaq 0x1230fe(%rip), %rdi # 0x1578ac
movb $0x0, %al
callq 0x2a060
cmpl $0x0, -0x28(%rbp)
jne 0x347c9
leaq 0x123105(%rip), %rdi # 0x1578c7
movb $0x0, %al
callq 0x2a060
movl -0x24(%rbp), %eax
shll $0xd, %eax
movl %eax, %eax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %esi
leaq 0x1230fe(%rip), %rdi # 0x1578e2
movb $0x0, %al
callq 0x2a060
movq -0x8(%rbp), %rax
cmpb $0x0, 0x6(%rax)
je 0x34874
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x34813
leaq 0x1230e7(%rip), %rdi # 0x1578f3
movb $0x0, %al
callq 0x2a060
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x34831
leaq 0x1230d7(%rip), %rdi # 0x157901
movb $0x0, %al
callq 0x2a060
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %eax
andl $0x4, %eax
cmpl $0x0, %eax
je 0x3484f
leaq 0x1230d0(%rip), %rdi # 0x157918
movb $0x0, %al
callq 0x2a060
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %eax
andl $-0x8, %eax
cmpl $0x0, %eax
je 0x34872
leaq 0x1230e4(%rip), %rdi # 0x15794a
movb $0x0, %al
callq 0x2a060
jmp 0x34a6b
jmp 0x34882
leaq 0x123104(%rip), %rdi # 0x15797f
movb $0x0, %al
callq 0x2a060
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %eax
movl %eax, %ecx
leaq 0xc4c3ed(%rip), %rax # 0xc80c80
movl (%rax,%rcx,4), %esi
movl %esi, -0x2c(%rbp)
leaq 0x1230ed(%rip), %rdi # 0x15798d
movb $0x0, %al
callq 0x2a060
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %eax
andl $0x4, %eax
cmpl $0x0, %eax
je 0x3490b
movq -0x8(%rbp), %rax
movl 0x7(%rax), %eax
movl %eax, -0x30(%rbp)
movl -0x30(%rbp), %eax
movl %eax, %esi
leaq 0x1230da(%rip), %rdi # 0x1579a7
movb $0x0, %al
callq 0x2a060
movq -0x8(%rbp), %rdi
movl -0x2c(%rbp), %eax
addq %rax, %rdi
movl $0x2000, %esi # imm = 0x2000
subl -0x2c(%rbp), %esi
callq 0x34f20
movl %eax, -0x34(%rbp)
movl -0x30(%rbp), %eax
cmpl -0x34(%rbp), %eax
je 0x34909
movl -0x34(%rbp), %eax
movl %eax, %esi
leaq 0x1230b9(%rip), %rdi # 0x1579bb
movb $0x0, %al
callq 0x2a060
jmp 0x3490b
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x349f4
movq -0x8(%rbp), %rax
movl -0x2c(%rbp), %ecx
addq %rcx, %rax
addq $-0x10, %rax
movq %rax, -0x98(%rbp)
movq -0x98(%rbp), %rax
movzbl (%rax), %esi
leaq 0x12309f(%rip), %rdi # 0x1579e4
movb $0x0, %al
callq 0x2a060
movl $0x1, -0x9c(%rbp)
cmpl $0x10, -0x9c(%rbp)
jae 0x349a2
movq -0x8(%rbp), %rax
movl -0x9c(%rbp), %ecx
shll $0x9, %ecx
movl %ecx, %ecx
movzbl (%rax,%rcx), %esi
movq -0x98(%rbp), %rax
movl -0x9c(%rbp), %ecx
movzbl (%rax,%rcx), %edx
leaq 0x123087(%rip), %rdi # 0x157a11
movb $0x0, %al
callq 0x2a060
movl -0x9c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x9c(%rbp)
jmp 0x34956
movl -0x28(%rbp), %eax
movl %eax, -0x90(%rbp)
leaq -0x90(%rbp), %rdi
addq $0x8, %rdi
xorl %esi, %esi
movl $0x48, %edx
callq 0x2a2a0
movl -0xc(%rbp), %eax
movl %eax, -0x78(%rbp)
movb $0x0, -0x40(%rbp)
movb $0x1, -0x3f(%rbp)
movq -0x8(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0x34f50
cmpb $0x0, %al
je 0x349f2
leaq 0x123063(%rip), %rdi # 0x157a4e
movb $0x0, %al
callq 0x2a060
jmp 0x349f4
movq -0x8(%rbp), %rax
movl -0x2c(%rbp), %ecx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
xorl %eax, %eax
cmpq $0x0, -0x18(%rbp)
movb %al, -0x9d(%rbp)
je 0x34a2c
movq -0x18(%rbp), %rax
movq -0x8(%rbp), %rcx
addq $0x2000, %rcx # imm = 0x2000
cmpq %rcx, %rax
setb %al
movb %al, -0x9d(%rbp)
movb -0x9d(%rbp), %al
testb $0x1, %al
jne 0x34a38
jmp 0x34a6b
movl -0x28(%rbp), %esi
movq -0x18(%rbp), %rdx
movq -0x8(%rbp), %rax
subq %rax, %rdx
addq -0x20(%rbp), %rdx
leaq 0x12302f(%rip), %rdi # 0x157a80
movb $0x0, %al
callq 0x2a060
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x39160
movq %rax, -0x18(%rbp)
jmp 0x34a02
addq $0xa0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| dump_datapage:
push rbp
mov rbp, rsp
sub rsp, 0A0h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax]
mov rcx, [rbp+var_8]
movzx ecx, byte ptr [rcx+1]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_8]
movzx ecx, byte ptr [rcx+2]
shl ecx, 10h
or eax, ecx
mov [rbp+var_24], eax
mov eax, eax
mov esi, eax
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+3]
mov rcx, [rbp+var_8]
movzx ecx, byte ptr [rcx+4]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_8]
movzx ecx, byte ptr [rcx+5]
shl ecx, 10h
or eax, ecx
mov [rbp+var_28], eax
mov eax, eax
mov edx, eax
lea rdi, aPageLdFileNumb; " Page: %ld File number: %ld\n"
mov al, 0
call _printf
cmp [rbp+var_24], 0
jnz short loc_347B5
lea rdi, aWarningPage0; " WARNING: page == 0!!!\n"
mov al, 0
call _printf
loc_347B5:
cmp [rbp+var_28], 0
jnz short loc_347C9
lea rdi, aWarningFile0; " WARNING: file == 0!!!\n"
mov al, 0
call _printf
loc_347C9:
mov eax, [rbp+var_24]
shl eax, 0Dh
mov eax, eax
mov [rbp+var_20], rax
mov rax, [rbp+var_8]
movzx esi, byte ptr [rax+6]
lea rdi, aFlags0xX; " Flags (0x%x):\n"
mov al, 0
call _printf
mov rax, [rbp+var_8]
cmp byte ptr [rax+6], 0
jz short loc_34874
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+6]
and eax, 1
cmp eax, 0
jz short loc_34813
lea rdi, aPageCrc; " Page CRC\n"
mov al, 0
call _printf
loc_34813:
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+6]
and eax, 2
cmp eax, 0
jz short loc_34831
lea rdi, aSectorProtecti; " Sector protection\n"
mov al, 0
call _printf
loc_34831:
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+6]
and eax, 4
cmp eax, 0
jz short loc_3484F
lea rdi, aRecordCrcWarni; " Record CRC (WARNING: not yet implem"...
mov al, 0
call _printf
loc_3484F:
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+6]
and eax, 0FFFFFFF8h
cmp eax, 0
jz short loc_34872
lea rdi, aWarningUnknown; " WARNING: unknown flags (stop interp"...
mov al, 0
call _printf
jmp loc_34A6B
loc_34872:
jmp short loc_34882
loc_34874:
lea rdi, aNoFlags; " No flags\n"
mov al, 0
call _printf
loc_34882:
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+6]
mov ecx, eax
lea rax, page_overhead
mov esi, [rax+rcx*4]
mov [rbp+var_2C], esi
lea rdi, aPageHeaderLeng; " Page header length: %u\n"
mov al, 0
call _printf
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+6]
and eax, 4
cmp eax, 0
jz short loc_3490B
mov rax, [rbp+var_8]
mov eax, [rax+7]
mov [rbp+var_30], eax
mov eax, [rbp+var_30]
mov esi, eax
lea rdi, aPageCrc0x04lx; " Page CRC 0x%04lx\n"
mov al, 0
call _printf
mov rdi, [rbp+var_8]
mov eax, [rbp+var_2C]
add rdi, rax
mov esi, 2000h
sub esi, [rbp+var_2C]
call translog_crc
mov [rbp+var_34], eax
mov eax, [rbp+var_30]
cmp eax, [rbp+var_34]
jz short loc_34909
mov eax, [rbp+var_34]
mov esi, eax
lea rdi, aWarningCalcula; " WARNING: calculated CRC: 0x%04lx!!!"...
mov al, 0
call _printf
loc_34909:
jmp short $+2
loc_3490B:
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+6]
and eax, 2
cmp eax, 0
jz loc_349F4
mov rax, [rbp+var_8]
mov ecx, [rbp+var_2C]
add rax, rcx
add rax, 0FFFFFFFFFFFFFFF0h
mov [rbp+var_98], rax
mov rax, [rbp+var_98]
movzx esi, byte ptr [rax]
lea rdi, aSectorProtecti_0; " Sector protection current value: 0x"...
mov al, 0
call _printf
mov [rbp+var_9C], 1
loc_34956:
cmp [rbp+var_9C], 10h
jnb short loc_349A2
mov rax, [rbp+var_8]
mov ecx, [rbp+var_9C]
shl ecx, 9
mov ecx, ecx
movzx esi, byte ptr [rax+rcx]
mov rax, [rbp+var_98]
mov ecx, [rbp+var_9C]
movzx edx, byte ptr [rax+rcx]
lea rdi, aSectorProtecti_1; " Sector protection in sector: 0x%02x"...
mov al, 0
call _printf
mov eax, [rbp+var_9C]
add eax, 1
mov [rbp+var_9C], eax
jmp short loc_34956
loc_349A2:
mov eax, [rbp+var_28]
mov [rbp+var_90], eax
lea rdi, [rbp+var_90]
add rdi, 8
xor esi, esi
mov edx, 48h ; 'H'
call _memset
mov eax, [rbp+var_C]
mov [rbp+var_78], eax
mov [rbp+var_40], 0
mov [rbp+var_3F], 1
mov rdi, [rbp+var_8]
lea rsi, [rbp+var_90]
call translog_check_sector_protection
cmp al, 0
jz short loc_349F2
lea rdi, aWarningSectorP; " WARNING: sector protection found pr"...
mov al, 0
call _printf
loc_349F2:
jmp short $+2
loc_349F4:
mov rax, [rbp+var_8]
mov ecx, [rbp+var_2C]
add rax, rcx
mov [rbp+var_18], rax
loc_34A02:
xor eax, eax
cmp [rbp+var_18], 0
mov [rbp+var_9D], al
jz short loc_34A2C
mov rax, [rbp+var_18]
mov rcx, [rbp+var_8]
add rcx, 2000h
cmp rax, rcx
setb al
mov [rbp+var_9D], al
loc_34A2C:
mov al, [rbp+var_9D]
test al, 1
jnz short loc_34A38
jmp short loc_34A6B
loc_34A38:
mov esi, [rbp+var_28]
mov rdx, [rbp+var_18]
mov rax, [rbp+var_8]
sub rdx, rax
add rdx, [rbp+var_20]
lea rdi, aChunkDLld; " Chunk %d %lld:\n"
mov al, 0
call _printf
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_18]
call dump_chunk
mov [rbp+var_18], rax
jmp short loc_34A02
loc_34A6B:
add rsp, 0A0h
pop rbp
retn
| char dump_datapage(unsigned __int16 *a1, int a2)
{
char result; // al
bool v3; // [rsp+3h] [rbp-9Dh]
unsigned int i; // [rsp+4h] [rbp-9Ch]
unsigned int v5; // [rsp+10h] [rbp-90h] BYREF
_DWORD v6[18]; // [rsp+18h] [rbp-88h] BYREF
char v7; // [rsp+60h] [rbp-40h]
char v8; // [rsp+61h] [rbp-3Fh]
unsigned int v9; // [rsp+6Ch] [rbp-34h]
unsigned int v10; // [rsp+70h] [rbp-30h]
unsigned int v11; // [rsp+74h] [rbp-2Ch]
unsigned int v12; // [rsp+78h] [rbp-28h]
unsigned int v13; // [rsp+7Ch] [rbp-24h]
long long v14; // [rsp+80h] [rbp-20h]
unsigned long long j; // [rsp+88h] [rbp-18h]
int v16; // [rsp+94h] [rbp-Ch]
unsigned __int16 *v17; // [rsp+98h] [rbp-8h]
v17 = a1;
v16 = a2;
v13 = (*((unsigned __int8 *)a1 + 2) << 16) | *a1;
v12 = (*((unsigned __int8 *)a1 + 5) << 16) | *(unsigned __int16 *)((char *)a1 + 3);
printf(" Page: %ld File number: %ld\n", v13, v12);
if ( !v13 )
printf(" WARNING: page == 0!!!\n");
if ( !v12 )
printf(" WARNING: file == 0!!!\n");
v14 = v13 << 13;
printf(" Flags (0x%x):\n", *((unsigned __int8 *)v17 + 6));
if ( *((_BYTE *)v17 + 6) )
{
if ( (v17[3] & 1) != 0 )
printf(" Page CRC\n");
if ( (v17[3] & 2) != 0 )
printf(" Sector protection\n");
if ( (v17[3] & 4) != 0 )
printf(" Record CRC (WARNING: not yet implemented!!!)\n");
if ( (v17[3] & 0xF8) != 0 )
return printf(" WARNING: unknown flags (stop interpretation)!!!\n");
}
else
{
printf(" No flags\n");
}
v11 = page_overhead[*((unsigned __int8 *)v17 + 6)];
printf(" Page header length: %u\n", v11);
if ( (v17[3] & 4) != 0 )
{
v10 = *(_DWORD *)((char *)v17 + 7);
printf(" Page CRC 0x%04lx\n", v10);
v9 = translog_crc((char *)v17 + v11, 0x2000 - v11);
if ( v10 != v9 )
printf(" WARNING: calculated CRC: 0x%04lx!!!\n", v9);
}
if ( (v17[3] & 2) != 0 )
{
printf(" Sector protection current value: 0x%02x\n", *((unsigned __int8 *)v17 + v11 - 16));
for ( i = 1; i < 0x10; ++i )
printf(
" Sector protection in sector: 0x%02x saved value 0x%02x\n",
LOBYTE(v17[256 * i]),
*((unsigned __int8 *)v17 + v11 + i - 16));
v5 = v12;
memset(v6, 0LL, sizeof(v6));
v6[4] = v16;
v7 = 0;
v8 = 1;
if ( (unsigned __int8)translog_check_sector_protection(v17, &v5) )
printf(" WARNING: sector protection found problems!!!\n");
}
for ( j = (unsigned long long)v17 + v11; ; j = dump_chunk(v17, j) )
{
v3 = 0;
if ( j )
v3 = j < (unsigned long long)(v17 + 4096);
result = v3;
if ( !v3 )
break;
printf(" Chunk %d %lld:\n", v12, v14 + j - (_QWORD)v17);
}
return result;
}
| dump_datapage:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xa0
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX]
MOV RCX,qword ptr [RBP + -0x8]
MOVZX ECX,byte ptr [RCX + 0x1]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x8]
MOVZX ECX,byte ptr [RCX + 0x2]
SHL ECX,0x10
OR EAX,ECX
MOV dword ptr [RBP + -0x24],EAX
MOV EAX,EAX
MOV ESI,EAX
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x3]
MOV RCX,qword ptr [RBP + -0x8]
MOVZX ECX,byte ptr [RCX + 0x4]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x8]
MOVZX ECX,byte ptr [RCX + 0x5]
SHL ECX,0x10
OR EAX,ECX
MOV dword ptr [RBP + -0x28],EAX
MOV EAX,EAX
MOV EDX,EAX
LEA RDI,[0x25788d]
MOV AL,0x0
CALL 0x0012a060
CMP dword ptr [RBP + -0x24],0x0
JNZ 0x001347b5
LEA RDI,[0x2578ac]
MOV AL,0x0
CALL 0x0012a060
LAB_001347b5:
CMP dword ptr [RBP + -0x28],0x0
JNZ 0x001347c9
LEA RDI,[0x2578c7]
MOV AL,0x0
CALL 0x0012a060
LAB_001347c9:
MOV EAX,dword ptr [RBP + -0x24]
SHL EAX,0xd
MOV EAX,EAX
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOVZX ESI,byte ptr [RAX + 0x6]
LEA RDI,[0x2578e2]
MOV AL,0x0
CALL 0x0012a060
MOV RAX,qword ptr [RBP + -0x8]
CMP byte ptr [RAX + 0x6],0x0
JZ 0x00134874
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x6]
AND EAX,0x1
CMP EAX,0x0
JZ 0x00134813
LEA RDI,[0x2578f3]
MOV AL,0x0
CALL 0x0012a060
LAB_00134813:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x6]
AND EAX,0x2
CMP EAX,0x0
JZ 0x00134831
LEA RDI,[0x257901]
MOV AL,0x0
CALL 0x0012a060
LAB_00134831:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x6]
AND EAX,0x4
CMP EAX,0x0
JZ 0x0013484f
LEA RDI,[0x257918]
MOV AL,0x0
CALL 0x0012a060
LAB_0013484f:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x6]
AND EAX,0xfffffff8
CMP EAX,0x0
JZ 0x00134872
LEA RDI,[0x25794a]
MOV AL,0x0
CALL 0x0012a060
JMP 0x00134a6b
LAB_00134872:
JMP 0x00134882
LAB_00134874:
LEA RDI,[0x25797f]
MOV AL,0x0
CALL 0x0012a060
LAB_00134882:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x6]
MOV ECX,EAX
LEA RAX,[0xd80c80]
MOV ESI,dword ptr [RAX + RCX*0x4]
MOV dword ptr [RBP + -0x2c],ESI
LEA RDI,[0x25798d]
MOV AL,0x0
CALL 0x0012a060
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x6]
AND EAX,0x4
CMP EAX,0x0
JZ 0x0013490b
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x7]
MOV dword ptr [RBP + -0x30],EAX
MOV EAX,dword ptr [RBP + -0x30]
MOV ESI,EAX
LEA RDI,[0x2579a7]
MOV AL,0x0
CALL 0x0012a060
MOV RDI,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RBP + -0x2c]
ADD RDI,RAX
MOV ESI,0x2000
SUB ESI,dword ptr [RBP + -0x2c]
CALL 0x00134f20
MOV dword ptr [RBP + -0x34],EAX
MOV EAX,dword ptr [RBP + -0x30]
CMP EAX,dword ptr [RBP + -0x34]
JZ 0x00134909
MOV EAX,dword ptr [RBP + -0x34]
MOV ESI,EAX
LEA RDI,[0x2579bb]
MOV AL,0x0
CALL 0x0012a060
LAB_00134909:
JMP 0x0013490b
LAB_0013490b:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x6]
AND EAX,0x2
CMP EAX,0x0
JZ 0x001349f4
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RBP + -0x2c]
ADD RAX,RCX
ADD RAX,-0x10
MOV qword ptr [RBP + -0x98],RAX
MOV RAX,qword ptr [RBP + -0x98]
MOVZX ESI,byte ptr [RAX]
LEA RDI,[0x2579e4]
MOV AL,0x0
CALL 0x0012a060
MOV dword ptr [RBP + -0x9c],0x1
LAB_00134956:
CMP dword ptr [RBP + -0x9c],0x10
JNC 0x001349a2
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RBP + -0x9c]
SHL ECX,0x9
MOV ECX,ECX
MOVZX ESI,byte ptr [RAX + RCX*0x1]
MOV RAX,qword ptr [RBP + -0x98]
MOV ECX,dword ptr [RBP + -0x9c]
MOVZX EDX,byte ptr [RAX + RCX*0x1]
LEA RDI,[0x257a11]
MOV AL,0x0
CALL 0x0012a060
MOV EAX,dword ptr [RBP + -0x9c]
ADD EAX,0x1
MOV dword ptr [RBP + -0x9c],EAX
JMP 0x00134956
LAB_001349a2:
MOV EAX,dword ptr [RBP + -0x28]
MOV dword ptr [RBP + -0x90],EAX
LEA RDI,[RBP + -0x90]
ADD RDI,0x8
XOR ESI,ESI
MOV EDX,0x48
CALL 0x0012a2a0
MOV EAX,dword ptr [RBP + -0xc]
MOV dword ptr [RBP + -0x78],EAX
MOV byte ptr [RBP + -0x40],0x0
MOV byte ptr [RBP + -0x3f],0x1
MOV RDI,qword ptr [RBP + -0x8]
LEA RSI,[RBP + -0x90]
CALL 0x00134f50
CMP AL,0x0
JZ 0x001349f2
LEA RDI,[0x257a4e]
MOV AL,0x0
CALL 0x0012a060
LAB_001349f2:
JMP 0x001349f4
LAB_001349f4:
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RBP + -0x2c]
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
LAB_00134a02:
XOR EAX,EAX
CMP qword ptr [RBP + -0x18],0x0
MOV byte ptr [RBP + -0x9d],AL
JZ 0x00134a2c
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x8]
ADD RCX,0x2000
CMP RAX,RCX
SETC AL
MOV byte ptr [RBP + -0x9d],AL
LAB_00134a2c:
MOV AL,byte ptr [RBP + -0x9d]
TEST AL,0x1
JNZ 0x00134a38
JMP 0x00134a6b
LAB_00134a38:
MOV ESI,dword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x8]
SUB RDX,RAX
ADD RDX,qword ptr [RBP + -0x20]
LEA RDI,[0x257a80]
MOV AL,0x0
CALL 0x0012a060
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x00139160
MOV qword ptr [RBP + -0x18],RAX
JMP 0x00134a02
LAB_00134a6b:
ADD RSP,0xa0
POP RBP
RET
|
void dump_datapage(uint3 *param_1,int4 param_2)
{
uint3 *puVar1;
char cVar2;
ulong uVar3;
uint local_a4;
uint local_98 [2];
int1 auStack_90 [16];
int4 local_80;
int1 local_48;
int1 local_47;
uint local_3c;
uint local_38;
uint local_34;
uint local_30;
uint local_2c;
ulong local_28;
uint3 *local_20;
int4 local_14;
uint3 *local_10;
local_2c = (uint)*param_1;
local_30 = (uint)*(uint3 *)((long)param_1 + 3);
local_14 = param_2;
local_10 = param_1;
printf(" Page: %ld File number: %ld\n",(ulong)local_2c,(ulong)local_30);
if (local_2c == 0) {
printf(" WARNING: page == 0!!!\n");
}
if (local_30 == 0) {
printf(" WARNING: file == 0!!!\n");
}
local_28 = (ulong)(local_2c << 0xd);
printf(" Flags (0x%x):\n",(ulong)*(byte *)((long)local_10 + 6));
if (*(char *)((long)local_10 + 6) == '\0') {
printf(" No flags\n");
}
else {
if ((*(byte *)((long)local_10 + 6) & 1) != 0) {
printf(" Page CRC\n");
}
if ((*(byte *)((long)local_10 + 6) & 2) != 0) {
printf(" Sector protection\n");
}
if ((*(byte *)((long)local_10 + 6) & 4) != 0) {
printf(" Record CRC (WARNING: not yet implemented!!!)\n");
}
if ((*(byte *)((long)local_10 + 6) & 0xf8) != 0) {
printf(" WARNING: unknown flags (stop interpretation)!!!\n");
return;
}
}
local_34 = *(uint *)(page_overhead + (ulong)*(byte *)((long)local_10 + 6) * 4);
printf(" Page header length: %u\n");
if ((*(byte *)((long)local_10 + 6) & 4) != 0) {
local_38 = *(uint *)((long)local_10 + 7);
printf(" Page CRC 0x%04lx\n",(ulong)local_38);
local_3c = translog_crc((long)local_10 + (ulong)local_34,0x2000 - local_34);
if (local_38 != local_3c) {
printf(" WARNING: calculated CRC: 0x%04lx!!!\n",(ulong)local_3c);
}
}
puVar1 = local_10;
if ((*(byte *)((long)local_10 + 6) & 2) != 0) {
uVar3 = (ulong)local_34;
printf(" Sector protection current value: 0x%02x\n");
for (local_a4 = 1; local_a4 < 0x10; local_a4 = local_a4 + 1) {
printf(" Sector protection in sector: 0x%02x saved value 0x%02x\n",
(ulong)*(byte *)((long)local_10 + (ulong)(local_a4 << 9)),
(ulong)*(byte *)((long)puVar1 + (ulong)local_a4 + (uVar3 - 0x10)));
}
local_98[0] = local_30;
memset(auStack_90,0,0x48);
local_80 = local_14;
local_48 = 0;
local_47 = 1;
cVar2 = translog_check_sector_protection(local_10,local_98);
if (cVar2 != '\0') {
printf(" WARNING: sector protection found problems!!!\n");
}
}
for (local_20 = (uint3 *)((long)local_10 + (ulong)local_34);
local_20 != (uint3 *)0x0 && local_20 < local_10 + 0x800;
local_20 = (uint3 *)dump_chunk(local_10,local_20)) {
printf(" Chunk %d %lld:\n",(ulong)local_30,(long)local_20 + (local_28 - (long)local_10));
}
return;
}
| |
23,394 | nglog::tools::GetHex(char const*, char const*, unsigned long*) | ng-log[P]ng-log/src/symbolize.cc | static char* GetHex(const char* start, const char* end, uint64_t* hex) {
*hex = 0;
const char* p;
for (p = start; p < end; ++p) {
int ch = *p;
if ((ch >= '0' && ch <= '9') || (ch >= 'A' && ch <= 'F') ||
(ch >= 'a' && ch <= 'f')) {
*hex = (*hex << 4U) |
(ch < 'A' ? static_cast<uint64_t>(ch - '0') : (ch & 0xF) + 9U);
} else { // Encountered the first non-hex character.
break;
}
}
NGLOG_SAFE_ASSERT(p <= end);
return const_cast<char*>(p);
} | O2 | cpp | nglog::tools::GetHex(char const*, char const*, unsigned long*):
pushq %rax
andq $0x0, (%rdx)
xorl %eax, %eax
movabsq $0x3f0000003f, %rcx # imm = 0x3F0000003F
cmpq %rsi, %rdi
jae 0x1e0f6
movb (%rdi), %r8b
leal -0x30(%r8), %r9d
cmpb $0xa, %r9b
jb 0x1e0cc
movzbl %r8b, %r9d
addl $-0x41, %r9d
cmpl $0x25, %r9d
ja 0x1e0f6
btq %r9, %rcx
jae 0x1e0f6
movsbl %r8b, %r9d
shlq $0x4, %rax
leal -0x30(%r9), %r10d
andl $0xf, %r9d
addl $0x9, %r9d
cmpb $0x41, %r8b
movslq %r10d, %r8
cmovbq %r8, %r9
orq %r9, %rax
movq %rax, (%rdx)
incq %rdi
jmp 0x1e0a6
cmpq %rsi, %rdi
ja 0x1e100
movq %rdi, %rax
popq %rcx
retq
callq 0x8330
nop
| _ZN5nglog5toolsL6GetHexEPKcS2_Pm:
push rax
and qword ptr [rdx], 0
xor eax, eax
mov rcx, 3F0000003Fh
loc_1E0A6:
cmp rdi, rsi
jnb short loc_1E0F6
mov r8b, [rdi]
lea r9d, [r8-30h]
cmp r9b, 0Ah
jb short loc_1E0CC
movzx r9d, r8b
add r9d, 0FFFFFFBFh
cmp r9d, 25h ; '%'
ja short loc_1E0F6
bt rcx, r9
jnb short loc_1E0F6
loc_1E0CC:
movsx r9d, r8b
shl rax, 4
lea r10d, [r9-30h]
and r9d, 0Fh
add r9d, 9
cmp r8b, 41h ; 'A'
movsxd r8, r10d
cmovb r9, r8
or rax, r9
mov [rdx], rax
inc rdi
jmp short loc_1E0A6
loc_1E0F6:
cmp rdi, rsi
ja short loc_1E100
mov rax, rdi
pop rcx
retn
loc_1E100:
call _abort
| nglog::tools * nglog::tools::GetHex(nglog::tools *this, nglog::tools *a2, char *a3, unsigned long long *a4)
{
long long v4; // rax
long long v5; // rcx
unsigned __int8 v6; // r8
unsigned long long v7; // r9
long long v8; // rax
long long v9; // r9
*(_QWORD *)a3 = 0LL;
v4 = 0LL;
v5 = 0x3F0000003FLL;
while ( this < a2 )
{
v6 = *(_BYTE *)this;
if ( (unsigned __int8)(*(_BYTE *)this - 48) >= 0xAu )
{
v7 = (unsigned int)v6 - 65;
if ( (unsigned int)v7 > 0x25 || !_bittest64(&v5, v7) )
break;
}
v8 = 16 * v4;
v9 = ((char)v6 & 0xFu) + 9;
if ( v6 < 0x41u )
v9 = (char)v6 - 48;
v4 = v9 | v8;
*(_QWORD *)a3 = v4;
this = (nglog::tools *)((char *)this + 1);
}
if ( this > a2 )
abort(this);
return this;
}
| GetHex:
PUSH RAX
AND qword ptr [RDX],0x0
XOR EAX,EAX
MOV RCX,0x3f0000003f
LAB_0011e0a6:
CMP RDI,RSI
JNC 0x0011e0f6
MOV R8B,byte ptr [RDI]
LEA R9D,[R8 + -0x30]
CMP R9B,0xa
JC 0x0011e0cc
MOVZX R9D,R8B
ADD R9D,-0x41
CMP R9D,0x25
JA 0x0011e0f6
BT RCX,R9
JNC 0x0011e0f6
LAB_0011e0cc:
MOVSX R9D,R8B
SHL RAX,0x4
LEA R10D,[R9 + -0x30]
AND R9D,0xf
ADD R9D,0x9
CMP R8B,0x41
MOVSXD R8,R10D
CMOVC R9,R8
OR RAX,R9
MOV qword ptr [RDX],RAX
INC RDI
JMP 0x0011e0a6
LAB_0011e0f6:
CMP RDI,RSI
JA 0x0011e100
MOV RAX,RDI
POP RCX
RET
LAB_0011e100:
CALL 0x00108330
|
/* nglog::tools::GetHex(char const*, char const*, unsigned long*) */
byte * nglog::tools::GetHex(char *param_1,char *param_2,ulong *param_3)
{
byte bVar1;
ulong uVar2;
ulong uVar3;
*param_3 = 0;
uVar2 = 0;
while ((param_1 < param_2 &&
((bVar1 = *param_1, (byte)(bVar1 - 0x30) < 10 ||
((bVar1 - 0x41 < 0x26 && ((0x3f0000003fU >> ((ulong)(bVar1 - 0x41) & 0x3f) & 1) != 0))))))
) {
uVar3 = (ulong)(((int)(char)bVar1 & 0xfU) + 9);
if (bVar1 < 0x41) {
uVar3 = (long)(int)((int)(char)bVar1 - 0x30);
}
uVar2 = uVar2 << 4 | uVar3;
*param_3 = uVar2;
param_1 = (char *)((byte *)param_1 + 1);
}
if (param_1 <= param_2) {
return (byte *)param_1;
}
/* WARNING: Subroutine does not return */
abort();
}
| |
23,395 | nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::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>, minja::Value, std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, std::allocator<std::pair<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, minja::Value>>>::operator[](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 | T& operator[](const key_type& key)
{
return emplace(key, T{}).first->second;
} | O3 | cpp | nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::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>, minja::Value, std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, std::allocator<std::pair<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, minja::Value>>>::operator[](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 %r15
pushq %r14
pushq %rbx
subq $0x50, %rsp
movq %rsi, %rbx
movq %rdi, %r15
leaq 0x40(%rsp), %r14
movq $0x0, 0x8(%r14)
xorps %xmm0, %xmm0
movaps %xmm0, -0x40(%r14)
movaps %xmm0, -0x30(%r14)
movaps %xmm0, -0x20(%r14)
movaps %xmm0, -0x10(%r14)
movb $0x0, (%r14)
movq %r14, %rdi
movl $0x1, %esi
callq 0x5099a
movq %r14, %rdi
movl $0x1, %esi
callq 0x5099a
movq %rsp, %rdx
movq %r15, %rdi
movq %rbx, %rsi
callq 0x62e9a
movq %rax, %rbx
movq %r14, %rdi
xorl %esi, %esi
callq 0x5099a
movq %r14, %rdi
callq 0x5d0d4
movq 0x38(%rsp), %rdi
testq %rdi, %rdi
je 0x62e21
callq 0x31b9a
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x62e30
callq 0x31b9a
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x62e3f
callq 0x31b9a
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x62e75
movq 0x8e148(%rip), %rax # 0xf0f98
cmpb $0x0, (%rax)
je 0x62e60
movl 0xc(%rdi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0xc(%rdi)
jmp 0x62e6a
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
lock
xaddl %eax, 0xc(%rdi)
cmpl $0x1, %eax
jne 0x62e75
movq (%rdi), %rax
callq *0x18(%rax)
addq $0x10, %rbx
movq %rbx, %rax
addq $0x50, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
movq %rsp, %rdi
callq 0x5090e
movq %rbx, %rdi
callq 0x19dc0
nop
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEEixERSJ_:
push r15
push r14
push rbx
sub rsp, 50h
mov rbx, rsi
mov r15, rdi
lea r14, [rsp+68h+var_28]
mov qword ptr [r14+8], 0
xorps xmm0, xmm0
movaps xmmword ptr [r14-40h], xmm0
movaps xmmword ptr [r14-30h], xmm0
movaps xmmword ptr [r14-20h], xmm0
movaps xmmword ptr [r14-10h], xmm0
mov byte ptr [r14], 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)
mov rdx, rsp
mov rdi, r15
mov rsi, rbx
call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceERSJ_OSF_; nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>::emplace(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,minja::Value&&)
mov rbx, rax
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, [rsp+68h+var_30]
test rdi, rdi
jz short loc_62E21
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_62E21:
mov rdi, [rsp+68h+var_40]
test rdi, rdi
jz short loc_62E30
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_62E30:
mov rdi, [rsp+68h+var_50]
test rdi, rdi
jz short loc_62E3F
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_62E3F:
mov rdi, [rsp+68h+var_60]
test rdi, rdi
jz short loc_62E75
mov rax, cs:__libc_single_threaded_ptr
cmp byte ptr [rax], 0
jz short loc_62E60
mov eax, [rdi+0Ch]
lea ecx, [rax-1]
mov [rdi+0Ch], ecx
jmp short loc_62E6A
loc_62E60:
mov eax, 0FFFFFFFFh
lock xadd [rdi+0Ch], eax
loc_62E6A:
cmp eax, 1
jnz short loc_62E75
mov rax, [rdi]
call qword ptr [rax+18h]
loc_62E75:
add rbx, 10h
mov rax, rbx
add rsp, 50h
pop rbx
pop r14
pop r15
retn
mov rbx, rax
mov rdi, rsp; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
mov rdi, rbx
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>::operator[](
long long a1,
long long a2)
{
long long v2; // rbx
long long v3; // rdi
signed __int32 v4; // eax
__int128 v6; // [rsp+0h] [rbp-68h] BYREF
__int128 v7; // [rsp+10h] [rbp-58h]
__int128 v8; // [rsp+20h] [rbp-48h]
__int128 v9; // [rsp+30h] [rbp-38h]
void **v10[5]; // [rsp+40h] [rbp-28h] BYREF
v10[1] = 0LL;
v6 = 0LL;
v7 = 0LL;
v8 = 0LL;
v9 = 0LL;
LOBYTE(v10[0]) = 0;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v10);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v10);
v2 = nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>::emplace(
a1,
a2,
&v6);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v10);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v10);
if ( *((_QWORD *)&v9 + 1) )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(*((volatile signed __int32 **)&v9 + 1));
if ( *((_QWORD *)&v8 + 1) )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(*((volatile signed __int32 **)&v8 + 1));
if ( *((_QWORD *)&v7 + 1) )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(*((volatile signed __int32 **)&v7 + 1));
v3 = *((_QWORD *)&v6 + 1);
if ( *((_QWORD *)&v6 + 1) )
{
if ( _libc_single_threaded )
{
v4 = *(_DWORD *)(*((_QWORD *)&v6 + 1) + 12LL);
*(_DWORD *)(*((_QWORD *)&v6 + 1) + 12LL) = v4 - 1;
}
else
{
v4 = _InterlockedExchangeAdd((volatile signed __int32 *)(*((_QWORD *)&v6 + 1) + 12LL), 0xFFFFFFFF);
}
if ( v4 == 1 )
(*(void ( **)(long long, _QWORD))(*(_QWORD *)v3 + 24LL))(v3, 0LL);
}
return v2 + 16;
}
| operator[]:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x50
MOV RBX,RSI
MOV R15,RDI
LEA R14,[RSP + 0x40]
MOV qword ptr [R14 + 0x8],0x0
XORPS XMM0,XMM0
MOVAPS xmmword ptr [R14 + -0x40],XMM0
MOVAPS xmmword ptr [R14 + -0x30],XMM0
MOVAPS xmmword ptr [R14 + -0x20],XMM0
MOVAPS xmmword ptr [R14 + -0x10],XMM0
MOV byte ptr [R14],0x0
MOV RDI,R14
MOV ESI,0x1
CALL 0x0015099a
MOV RDI,R14
MOV ESI,0x1
CALL 0x0015099a
LAB_00162def:
MOV RDX,RSP
MOV RDI,R15
MOV RSI,RBX
CALL 0x00162e9a
LAB_00162dfd:
MOV RBX,RAX
MOV RDI,R14
XOR ESI,ESI
CALL 0x0015099a
MOV RDI,R14
CALL 0x0015d0d4
MOV RDI,qword ptr [RSP + 0x38]
TEST RDI,RDI
JZ 0x00162e21
CALL 0x00131b9a
LAB_00162e21:
MOV RDI,qword ptr [RSP + 0x28]
TEST RDI,RDI
JZ 0x00162e30
CALL 0x00131b9a
LAB_00162e30:
MOV RDI,qword ptr [RSP + 0x18]
TEST RDI,RDI
JZ 0x00162e3f
CALL 0x00131b9a
LAB_00162e3f:
MOV RDI,qword ptr [RSP + 0x8]
TEST RDI,RDI
JZ 0x00162e75
MOV RAX,qword ptr [0x001f0f98]
CMP byte ptr [RAX],0x0
JZ 0x00162e60
MOV EAX,dword ptr [RDI + 0xc]
LEA ECX,[RAX + -0x1]
MOV dword ptr [RDI + 0xc],ECX
JMP 0x00162e6a
LAB_00162e60:
MOV EAX,0xffffffff
XADD.LOCK dword ptr [RDI + 0xc],EAX
LAB_00162e6a:
CMP EAX,0x1
JNZ 0x00162e75
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x18]
LAB_00162e75:
ADD RBX,0x10
MOV RAX,RBX
ADD RSP,0x50
POP RBX
POP R14
POP R15
RET
|
/* nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>, minja::Value,
std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >,
std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const, minja::Value> >
>::operator[](nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const&) */
long __thiscall
nlohmann::json_abi_v3_11_3::
ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>>
::operator[](ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>>
*this,basic_json *param_1)
{
int *piVar1;
int iVar2;
long lVar3;
bool bVar4;
int8 local_68;
long *plStack_60;
int8 local_58;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Stack_50;
int8 local_48;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Stack_40;
int8 local_38;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Stack_30;
data local_28 [8];
int8 local_20;
local_20 = 0;
local_68 = 0;
plStack_60 = (long *)0x0;
local_58 = 0;
p_Stack_50 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0;
local_48 = 0;
p_Stack_40 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0;
local_38 = 0;
p_Stack_30 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0;
local_28[0] = (data)0x0;
bVar4 = SUB81(local_28,0);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(bVar4);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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(bVar4);
/* try { // try from 00162def to 00162dfc has its CatchHandler @ 00162e86 */
lVar3 = emplace(this,param_1,(Value *)&local_68);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(bVar4);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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(local_28);
if (p_Stack_30 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Stack_30);
}
if (p_Stack_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Stack_40);
}
if (p_Stack_50 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Stack_50);
}
if (plStack_60 != (long *)0x0) {
if (*PTR___libc_single_threaded_001f0f98 == '\0') {
LOCK();
piVar1 = (int *)((long)plStack_60 + 0xc);
iVar2 = *piVar1;
*piVar1 = *piVar1 + -1;
UNLOCK();
}
else {
iVar2 = *(int *)((long)plStack_60 + 0xc);
*(int *)((long)plStack_60 + 0xc) = iVar2 + -1;
}
if (iVar2 == 1) {
(**(code **)(*plStack_60 + 0x18))();
}
}
return lVar3 + 0x10;
}
| |
23,396 | rtree_delete_req | eloqsql/storage/myisam/rt_index.c | static int rtree_delete_req(MI_INFO *info, MI_KEYDEF *keyinfo, uchar *key,
uint key_length, my_off_t page, uint *page_size,
stPageList *ReinsertList, int level)
{
uchar *k;
uchar *last;
ulong i;
uint nod_flag;
uchar *page_buf;
int res;
DBUG_ENTER("rtree_delete_req");
if (!(page_buf = (uchar*)my_alloca((uint)keyinfo->block_length)))
{
my_errno = HA_ERR_OUT_OF_MEM;
DBUG_RETURN(-1); /* purecov: inspected */
}
if (!_mi_fetch_keypage(info, keyinfo, page, DFLT_INIT_HITS, page_buf, 0))
goto err1;
nod_flag = mi_test_if_nod(page_buf);
DBUG_PRINT("rtree", ("page: %lu level: %d nod_flag: %u",
(ulong) page, level, nod_flag));
k = rt_PAGE_FIRST_KEY(page_buf, nod_flag);
last = rt_PAGE_END(page_buf);
for (i = 0; k < last; k = rt_PAGE_NEXT_KEY(k, key_length, nod_flag), ++i)
{
if (nod_flag)
{
/* not leaf */
if (!rtree_key_cmp(keyinfo->seg, key, k, key_length, MBR_WITHIN))
{
switch ((res = rtree_delete_req(info, keyinfo, key, key_length,
_mi_kpos(nod_flag, k), page_size, ReinsertList, level + 1)))
{
case 0: /* deleted */
{
/* test page filling */
if (*page_size + key_length >= rt_PAGE_MIN_SIZE(keyinfo->block_length))
{
/* OK */
/* Calculate a new key value (MBR) for the shrinked block. */
if (rtree_set_key_mbr(info, keyinfo, k, key_length,
_mi_kpos(nod_flag, k)))
goto err1;
if (_mi_write_keypage(info, keyinfo, page,
DFLT_INIT_HITS, page_buf))
goto err1;
}
else
{
/*
Too small: delete key & add it descendant to reinsert list.
Store position and level of the block so that it can be
accessed later for inserting the remaining keys.
*/
DBUG_PRINT("rtree", ("too small. move block to reinsert list"));
if (rtree_fill_reinsert_list(ReinsertList, _mi_kpos(nod_flag, k),
level + 1))
goto err1;
/*
Delete the key that references the block. This makes the
block disappear from the index. Hence we need to insert
its remaining keys later. Note: if the block is a branch
block, we do not only remove this block, but the whole
subtree. So we need to re-insert its keys on the same
level later to reintegrate the subtrees.
*/
rtree_delete_key(info, page_buf, k, key_length, nod_flag);
if (_mi_write_keypage(info, keyinfo, page,
DFLT_INIT_HITS, page_buf))
goto err1;
*page_size = mi_getint(page_buf);
}
goto ok;
}
case 1: /* not found - continue searching */
{
break;
}
case 2: /* vacuous case: last key in the leaf */
{
rtree_delete_key(info, page_buf, k, key_length, nod_flag);
if (_mi_write_keypage(info, keyinfo, page,
DFLT_INIT_HITS, page_buf))
goto err1;
*page_size = mi_getint(page_buf);
res = 0;
goto ok;
}
default: /* error */
case -1:
{
goto err1;
}
}
}
}
else
{
/* leaf */
if (!rtree_key_cmp(keyinfo->seg, key, k, key_length, MBR_EQUAL | MBR_DATA))
{
rtree_delete_key(info, page_buf, k, key_length, nod_flag);
*page_size = mi_getint(page_buf);
if (*page_size == 2)
{
/* last key in the leaf */
res = 2;
if (_mi_dispose(info, keyinfo, page, DFLT_INIT_HITS))
goto err1;
}
else
{
res = 0;
if (_mi_write_keypage(info, keyinfo, page, DFLT_INIT_HITS, page_buf))
goto err1;
}
goto ok;
}
}
}
res = 1;
ok:
my_afree((uchar*)page_buf);
DBUG_RETURN(res);
err1:
my_afree((uchar*)page_buf);
DBUG_RETURN(-1); /* purecov: inspected */
} | O3 | c | rtree_delete_req:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r9, -0x60(%rbp)
movl %ecx, -0x34(%rbp)
movq %rdx, %r14
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
movzwl 0xe(%rsi), %eax
movq %rsp, %r12
addl $0xf, %eax
andl $-0x10, %eax
subq %rax, %r12
movq %r12, %rsp
xorl %ebx, %ebx
movq %rdi, -0x48(%rbp)
movq %rsi, -0x40(%rbp)
movq %r8, -0x50(%rbp)
movq %r8, %rdx
movl $0x3, %ecx
movq %r12, %r8
xorl %r9d, %r9d
callq 0x83c20
testq %rax, %rax
je 0x8ab54
movzbl (%r12), %r15d
testb %r15b, %r15b
jns 0x8a86f
movq -0x48(%rbp), %rax
movq (%rax), %rax
movl 0x17c(%rax), %ebx
movl %ebx, %r13d
leaq (%r12,%r13), %rbx
addq $0x2, %rbx
movzbl 0x1(%r12), %eax
andl $0x7f, %r15d
shll $0x8, %r15d
orq %rax, %r15
addq %r12, %r15
movl $0x1, %eax
cmpq %r15, %rbx
movq -0x40(%rbp), %rsi
movl -0x34(%rbp), %ecx
jae 0x8ab59
movq %r12, -0x58(%rbp)
movl 0x18(%rbp), %edx
incl %edx
movq %rdx, -0x68(%rbp)
movl %ecx, %r12d
movq 0x28(%rsi), %rdi
movq %r14, %rsi
movq %rbx, %rdx
testq %r13, %r13
je 0x8a90d
movl $0x800, %r8d # imm = 0x800
callq 0x8b3dc
movq %r13, %rcx
testl %eax, %eax
jne 0x8a92d
movl %r13d, %edi
movq %rbx, %rsi
callq 0x8459a
movq -0x48(%rbp), %rdi
movq -0x40(%rbp), %rsi
movq %r14, %rdx
movl -0x34(%rbp), %ecx
movq %rax, %r8
movq -0x60(%rbp), %r9
pushq -0x68(%rbp)
pushq 0x10(%rbp)
callq 0x8a7f3
addq $0x10, %rsp
movq %r13, %rcx
cmpl $0x1, %eax
je 0x8a92d
jmp 0x8a94d
movl $0x6000, %r8d # imm = 0x6000
callq 0x8b3dc
testl %eax, %eax
je 0x8a9f0
movq -0x48(%rbp), %rax
movq (%rax), %rax
movl 0x178(%rax), %ecx
addq %r12, %rbx
addq %rcx, %rbx
cmpq %r15, %rbx
movq -0x40(%rbp), %rsi
movl -0x34(%rbp), %ecx
jb 0x8a8b3
movl $0x1, %eax
jmp 0x8ab59
cmpl $0x2, %eax
je 0x8aa4e
testl %eax, %eax
jne 0x8ab54
movq -0x60(%rbp), %rax
movl (%rax), %r15d
addl -0x34(%rbp), %r15d
movq -0x40(%rbp), %r14
movzwl 0xe(%r14), %eax
imull $0xaaab, %eax, %r12d # imm = 0xAAAB
shrl $0x11, %r12d
movl %r13d, %edi
movq %rbx, %rsi
callq 0x8459a
movq %rax, %r8
cmpl %r12d, %r15d
jae 0x8aabe
movq 0x10(%rbp), %r14
movq (%r14), %rdx
cmpq 0x8(%r14), %rdx
jne 0x8aaf7
movq %r8, -0x70(%rbp)
addq $0xa, %rdx
movq %rdx, 0x8(%r14)
leaq 0xb74b3c(%rip), %rax # 0xbff4f4
movl (%rax), %edi
movq 0x10(%r14), %rsi
shlq $0x4, %rdx
movl $0x40, %ecx
callq 0x9ffc0
movq %rax, 0x10(%r14)
testq %rax, %rax
movq -0x58(%rbp), %r15
je 0x8ab54
movq (%r14), %rdx
movq -0x50(%rbp), %r12
movl -0x34(%rbp), %ecx
movq -0x70(%rbp), %r8
jmp 0x8ab06
movq -0x48(%rbp), %r15
movq %r15, %rdi
movq -0x58(%rbp), %r14
movq %r14, %rsi
movq %rbx, %rdx
movl -0x34(%rbp), %ecx
xorl %r8d, %r8d
callq 0x8b2e7
movzbl 0x1(%r14), %eax
movl (%r14), %ecx
andl $0x7f, %ecx
shll $0x8, %ecx
orl %eax, %ecx
movq -0x60(%rbp), %rax
movl %ecx, (%rax)
movq %r15, %rdi
cmpl $0x2, %ecx
jne 0x8aa97
movq -0x40(%rbp), %rsi
movq -0x50(%rbp), %rdx
movl $0x3, %ecx
callq 0x83d9f
testl %eax, %eax
jne 0x8ab54
movl $0x2, %eax
jmp 0x8ab59
movq -0x48(%rbp), %r15
movq %r15, %rdi
movq -0x58(%rbp), %r14
movq %r14, %rsi
movq %rbx, %rdx
movl -0x34(%rbp), %ecx
movl %r13d, %r8d
callq 0x8b2e7
movq %r15, %rdi
movq -0x40(%rbp), %rsi
movq -0x50(%rbp), %rdx
movl $0x3, %ecx
movq %r14, %r8
callq 0x83ccc
testl %eax, %eax
jne 0x8ab54
movzbl 0x1(%r14), %eax
movl (%r14), %ecx
jmp 0x8ab7f
movq -0x40(%rbp), %rsi
movq -0x50(%rbp), %rdx
movl $0x3, %ecx
movq %r14, %r8
callq 0x83ccc
testl %eax, %eax
movl $0x0, %eax
jne 0x8ab54
jmp 0x8ab59
movq -0x48(%rbp), %rdi
movq %r14, %rsi
movq %rbx, %rdx
movl -0x34(%rbp), %ecx
callq 0x8b374
testl %eax, %eax
movq -0x58(%rbp), %r8
jne 0x8ab54
movq -0x48(%rbp), %rdi
movq -0x40(%rbp), %rsi
movq -0x50(%rbp), %rdx
movl $0x3, %ecx
callq 0x83ccc
testl %eax, %eax
jne 0x8ab54
jmp 0x8ab8d
movq 0x10(%r14), %rax
movq -0x58(%rbp), %r15
movq -0x50(%rbp), %r12
movl -0x34(%rbp), %ecx
shlq $0x4, %rdx
movq %r8, 0x8(%rax,%rdx)
movq (%r14), %rax
movq 0x10(%r14), %rdx
shlq $0x4, %rax
movq -0x68(%rbp), %rsi
movl %esi, (%rdx,%rax)
incq (%r14)
movq -0x48(%rbp), %r14
movq %r14, %rdi
movq %r15, %rsi
movq %rbx, %rdx
movl %r13d, %r8d
callq 0x8b2e7
movq %r14, %rdi
movq -0x40(%rbp), %rsi
movq %r12, %rdx
movl $0x3, %ecx
movq %r15, %r8
callq 0x83ccc
testl %eax, %eax
je 0x8ab77
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
movq %fs:0x28, %rcx
cmpq -0x30(%rbp), %rcx
jne 0x8ab91
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movzbl 0x1(%r15), %eax
movl (%r15), %ecx
andl $0x7f, %ecx
shll $0x8, %ecx
orl %eax, %ecx
movq -0x60(%rbp), %rax
movl %ecx, (%rax)
xorl %eax, %eax
jmp 0x8ab59
callq 0x29250
| rtree_delete_req:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov [rbp+var_60], r9
mov [rbp+var_34], ecx
mov r14, rdx
mov rax, fs:28h
mov [rbp+var_30], rax
movzx eax, word ptr [rsi+0Eh]
mov r12, rsp
add eax, 0Fh
and eax, 0FFFFFFF0h
sub r12, rax
mov rsp, r12
xor ebx, ebx
mov [rbp+var_48], rdi
mov [rbp+var_40], rsi
mov [rbp+var_50], r8
mov rdx, r8
mov ecx, 3
mov r8, r12
xor r9d, r9d
call _mi_fetch_keypage
test rax, rax
jz loc_8AB54
movzx r15d, byte ptr [r12]
test r15b, r15b
jns short loc_8A86F
mov rax, [rbp+var_48]
mov rax, [rax]
mov ebx, [rax+17Ch]
loc_8A86F:
mov r13d, ebx
lea rbx, [r12+r13]
add rbx, 2
movzx eax, byte ptr [r12+1]
and r15d, 7Fh
shl r15d, 8
or r15, rax
add r15, r12
mov eax, 1
cmp rbx, r15
mov rsi, [rbp+var_40]
mov ecx, [rbp+var_34]
jnb loc_8AB59
mov [rbp+var_58], r12
mov edx, [rbp+arg_8]
inc edx
mov [rbp+var_68], rdx
mov r12d, ecx
loc_8A8B3:
mov rdi, [rsi+28h]
mov rsi, r14
mov rdx, rbx
test r13, r13
jz short loc_8A90D
mov r8d, 800h
call rtree_key_cmp
mov rcx, r13
test eax, eax
jnz short loc_8A92D
mov edi, r13d
mov rsi, rbx
call _mi_kpos
mov rdi, [rbp+var_48]
mov rsi, [rbp+var_40]
mov rdx, r14
mov ecx, [rbp+var_34]
mov r8, rax
mov r9, [rbp+var_60]
push [rbp+var_68]
push [rbp+arg_0]
call rtree_delete_req
add rsp, 10h
mov rcx, r13
cmp eax, 1
jz short loc_8A92D
jmp short loc_8A94D
loc_8A90D:
mov r8d, 6000h
call rtree_key_cmp
test eax, eax
jz loc_8A9F0
mov rax, [rbp+var_48]
mov rax, [rax]
mov ecx, [rax+178h]
loc_8A92D:
add rbx, r12
add rbx, rcx
cmp rbx, r15
mov rsi, [rbp+var_40]
mov ecx, [rbp+var_34]
jb loc_8A8B3
mov eax, 1
jmp loc_8AB59
loc_8A94D:
cmp eax, 2
jz loc_8AA4E
test eax, eax
jnz loc_8AB54
mov rax, [rbp+var_60]
mov r15d, [rax]
add r15d, [rbp+var_34]
mov r14, [rbp+var_40]
movzx eax, word ptr [r14+0Eh]
imul r12d, eax, 0AAABh
shr r12d, 11h
mov edi, r13d
mov rsi, rbx
call _mi_kpos
mov r8, rax
cmp r15d, r12d
jnb loc_8AABE
mov r14, [rbp+arg_0]
mov rdx, [r14]
cmp rdx, [r14+8]
jnz loc_8AAF7
mov [rbp+var_70], r8
add rdx, 0Ah
mov [r14+8], rdx
lea rax, mi_key_memory_stPageList_pages
mov edi, [rax]
mov rsi, [r14+10h]
shl rdx, 4
mov ecx, 40h ; '@'
call my_realloc
mov [r14+10h], rax
test rax, rax
mov r15, [rbp+var_58]
jz loc_8AB54
mov rdx, [r14]
mov r12, [rbp+var_50]
mov ecx, [rbp+var_34]
mov r8, [rbp+var_70]
jmp loc_8AB06
loc_8A9F0:
mov r15, [rbp+var_48]
mov rdi, r15
mov r14, [rbp+var_58]
mov rsi, r14
mov rdx, rbx
mov ecx, [rbp+var_34]
xor r8d, r8d
call rtree_delete_key
movzx eax, byte ptr [r14+1]
mov ecx, [r14]
and ecx, 7Fh
shl ecx, 8
or ecx, eax
mov rax, [rbp+var_60]
mov [rax], ecx
mov rdi, r15
cmp ecx, 2
jnz short loc_8AA97
mov rsi, [rbp+var_40]
mov rdx, [rbp+var_50]
mov ecx, 3
call _mi_dispose
test eax, eax
jnz loc_8AB54
mov eax, 2
jmp loc_8AB59
loc_8AA4E:
mov r15, [rbp+var_48]
mov rdi, r15
mov r14, [rbp+var_58]
mov rsi, r14
mov rdx, rbx
mov ecx, [rbp+var_34]
mov r8d, r13d
call rtree_delete_key
mov rdi, r15
mov rsi, [rbp+var_40]
mov rdx, [rbp+var_50]
mov ecx, 3
mov r8, r14
call _mi_write_keypage
test eax, eax
jnz loc_8AB54
movzx eax, byte ptr [r14+1]
mov ecx, [r14]
jmp loc_8AB7F
loc_8AA97:
mov rsi, [rbp+var_40]
mov rdx, [rbp+var_50]
mov ecx, 3
mov r8, r14
call _mi_write_keypage
test eax, eax
mov eax, 0
jnz loc_8AB54
jmp loc_8AB59
loc_8AABE:
mov rdi, [rbp+var_48]
mov rsi, r14
mov rdx, rbx
mov ecx, [rbp+var_34]
call rtree_set_key_mbr
test eax, eax
mov r8, [rbp+var_58]
jnz short loc_8AB54
mov rdi, [rbp+var_48]
mov rsi, [rbp+var_40]
mov rdx, [rbp+var_50]
mov ecx, 3
call _mi_write_keypage
test eax, eax
jnz short loc_8AB54
jmp loc_8AB8D
loc_8AAF7:
mov rax, [r14+10h]
mov r15, [rbp+var_58]
mov r12, [rbp+var_50]
mov ecx, [rbp+var_34]
loc_8AB06:
shl rdx, 4
mov [rax+rdx+8], r8
mov rax, [r14]
mov rdx, [r14+10h]
shl rax, 4
mov rsi, [rbp+var_68]
mov [rdx+rax], esi
inc qword ptr [r14]
mov r14, [rbp+var_48]
mov rdi, r14
mov rsi, r15
mov rdx, rbx
mov r8d, r13d
call rtree_delete_key
mov rdi, r14
mov rsi, [rbp+var_40]
mov rdx, r12
mov ecx, 3
mov r8, r15
call _mi_write_keypage
test eax, eax
jz short loc_8AB77
loc_8AB54:
mov eax, 0FFFFFFFFh
loc_8AB59:
mov rcx, fs:28h
cmp rcx, [rbp+var_30]
jnz short loc_8AB91
lea rsp, [rbp-28h]
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_8AB77:
movzx eax, byte ptr [r15+1]
mov ecx, [r15]
loc_8AB7F:
and ecx, 7Fh
shl ecx, 8
or ecx, eax
mov rax, [rbp+var_60]
mov [rax], ecx
loc_8AB8D:
xor eax, eax
jmp short loc_8AB59
loc_8AB91:
call ___stack_chk_fail
| long long rtree_delete_req(
long long *a1,
long long a2,
long long a3,
unsigned int a4,
long long a5,
int *a6,
long long *a7,
int a8)
{
char *v9; // r12
unsigned int v10; // ebx
long long v11; // r13
unsigned long long v12; // rbx
char *v13; // r15
long long result; // rax
long long v15; // rsi
long long v16; // rcx
long long v17; // r12
long long v18; // rdi
int v19; // eax
long long v20; // rcx
int v21; // eax
int v22; // eax
unsigned int v23; // r15d
long long v24; // r14
unsigned int v25; // r12d
unsigned long long v26; // rax
long long v27; // r9
unsigned long long v28; // r8
long long v29; // rdx
long long v30; // rdx
long long v31; // rax
_BYTE *v32; // r15
unsigned long long v33; // r12
long long v34; // rcx
long long *v35; // r15
_BYTE *v36; // r14
int v37; // ecx
long long *v38; // r15
_BYTE *v39; // r14
int v40; // eax
int v41; // ecx
bool v42; // zf
long long *v43; // r14
unsigned long long v44; // [rsp+0h] [rbp-70h] BYREF
long long v45; // [rsp+8h] [rbp-68h]
int *v46; // [rsp+10h] [rbp-60h]
_BYTE *v47; // [rsp+18h] [rbp-58h]
unsigned long long v48; // [rsp+20h] [rbp-50h]
long long *v49; // [rsp+28h] [rbp-48h]
long long v50; // [rsp+30h] [rbp-40h]
unsigned int v51; // [rsp+3Ch] [rbp-34h]
unsigned long long v52; // [rsp+40h] [rbp-30h]
v46 = a6;
v51 = a4;
v52 = __readfsqword(0x28u);
v9 = (char *)&v44 - ((*(unsigned __int16 *)(a2 + 14) + 15) & 0xFFFFFFF0);
v10 = 0;
v49 = a1;
v50 = a2;
v48 = a5;
if ( !mi_fetch_keypage(a1, a2, a5) )
return 0xFFFFFFFFLL;
if ( *v9 < 0 )
v10 = *(_DWORD *)(*v49 + 380);
v11 = v10;
v12 = (unsigned long long)&v9[v10 + 2];
v13 = &v9[(unsigned __int8)v9[1] | (unsigned long long)((unsigned __int8)(*v9 & 0x7F) << 8)];
result = 1LL;
v15 = v50;
v16 = v51;
if ( v12 < (unsigned long long)v13 )
{
v47 = v9;
v45 = (unsigned int)(a8 + 1);
v17 = v51;
while ( 1 )
{
v18 = *(_QWORD *)(v15 + 40);
if ( v11 )
{
v19 = rtree_key_cmp(v18, a3, v12, v16, 2048LL);
v20 = v11;
if ( !v19 )
{
v21 = mi_kpos(v11, v12);
v22 = rtree_delete_req((_DWORD)v49, v50, a3, v51, v21, (_DWORD)v46, (long long)a7, v45);
v20 = v11;
if ( v22 != 1 )
{
if ( v22 != 2 )
{
if ( v22 )
return 0xFFFFFFFFLL;
v23 = v51 + *v46;
v24 = v50;
v25 = *(unsigned __int16 *)(v50 + 14) / 3u;
v26 = mi_kpos(v11, v12);
v28 = v26;
if ( v23 >= v25 )
{
if ( (unsigned int)rtree_set_key_mbr(v49, v24, v12, v51, v26)
|| (unsigned int)mi_write_keypage(v49, v50, v48, 3u, v47) )
{
return 0xFFFFFFFFLL;
}
}
else
{
v29 = *a7;
if ( *a7 == a7[1] )
{
v44 = v26;
v30 = v29 + 10;
a7[1] = v30;
v31 = my_realloc(mi_key_memory_stPageList_pages, a7[2], 16 * v30, 64LL, v26, v27);
a7[2] = v31;
v32 = v47;
if ( !v31 )
return 0xFFFFFFFFLL;
v29 = *a7;
v33 = v48;
v34 = v51;
v28 = v44;
}
else
{
v31 = a7[2];
v32 = v47;
v33 = v48;
v34 = v51;
}
*(_QWORD *)(v31 + 16 * v29 + 8) = v28;
*(_DWORD *)(a7[2] + 16 * (*a7)++) = v45;
v43 = v49;
rtree_delete_key(v49, v32, v12, v34, (unsigned int)v11);
if ( (unsigned int)mi_write_keypage(v43, v50, v33, 3u, v32) )
return 0xFFFFFFFFLL;
v40 = (unsigned __int8)v32[1];
v41 = *(_DWORD *)v32;
LABEL_35:
*v46 = v40 | ((v41 & 0x7F) << 8);
}
return 0LL;
}
v38 = v49;
v39 = v47;
rtree_delete_key(v49, v47, v12, v51, (unsigned int)v11);
if ( (unsigned int)mi_write_keypage(v38, v50, v48, 3u, v39) )
return 0xFFFFFFFFLL;
v40 = (unsigned __int8)v39[1];
v41 = *(_DWORD *)v39;
goto LABEL_35;
}
}
}
else
{
if ( !(unsigned int)rtree_key_cmp(v18, a3, v12, v16, 24576LL) )
{
v35 = v49;
v36 = v47;
rtree_delete_key(v49, v47, v12, v51, 0LL);
v37 = (unsigned __int8)v36[1] | ((*(_DWORD *)v36 & 0x7F) << 8);
*v46 = v37;
if ( v37 == 2 )
{
if ( (unsigned int)mi_dispose(v35, v50, v48, 3u) )
return 0xFFFFFFFFLL;
return 2LL;
}
else
{
v42 = (unsigned int)mi_write_keypage(v35, v50, v48, 3u, v36) == 0;
result = 0LL;
if ( !v42 )
return 0xFFFFFFFFLL;
}
return result;
}
v20 = *(unsigned int *)(*v49 + 376);
}
v12 += v20 + v17;
v15 = v50;
v16 = v51;
if ( v12 >= (unsigned long long)v13 )
return 1LL;
}
}
return result;
}
| rtree_delete_req:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV qword ptr [RBP + -0x60],R9
MOV dword ptr [RBP + -0x34],ECX
MOV R14,RDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
MOVZX EAX,word ptr [RSI + 0xe]
MOV R12,RSP
ADD EAX,0xf
AND EAX,0xfffffff0
SUB R12,RAX
MOV RSP,R12
XOR EBX,EBX
MOV qword ptr [RBP + -0x48],RDI
MOV qword ptr [RBP + -0x40],RSI
MOV qword ptr [RBP + -0x50],R8
MOV RDX,R8
MOV ECX,0x3
MOV R8,R12
XOR R9D,R9D
CALL 0x00183c20
TEST RAX,RAX
JZ 0x0018ab54
MOVZX R15D,byte ptr [R12]
TEST R15B,R15B
JNS 0x0018a86f
MOV RAX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RAX]
MOV EBX,dword ptr [RAX + 0x17c]
LAB_0018a86f:
MOV R13D,EBX
LEA RBX,[R12 + R13*0x1]
ADD RBX,0x2
MOVZX EAX,byte ptr [R12 + 0x1]
AND R15D,0x7f
SHL R15D,0x8
OR R15,RAX
ADD R15,R12
MOV EAX,0x1
CMP RBX,R15
MOV RSI,qword ptr [RBP + -0x40]
MOV ECX,dword ptr [RBP + -0x34]
JNC 0x0018ab59
MOV qword ptr [RBP + -0x58],R12
MOV EDX,dword ptr [RBP + 0x18]
INC EDX
MOV qword ptr [RBP + -0x68],RDX
MOV R12D,ECX
LAB_0018a8b3:
MOV RDI,qword ptr [RSI + 0x28]
MOV RSI,R14
MOV RDX,RBX
TEST R13,R13
JZ 0x0018a90d
MOV R8D,0x800
CALL 0x0018b3dc
MOV RCX,R13
TEST EAX,EAX
JNZ 0x0018a92d
MOV EDI,R13D
MOV RSI,RBX
CALL 0x0018459a
MOV RDI,qword ptr [RBP + -0x48]
MOV RSI,qword ptr [RBP + -0x40]
MOV RDX,R14
MOV ECX,dword ptr [RBP + -0x34]
MOV R8,RAX
MOV R9,qword ptr [RBP + -0x60]
PUSH qword ptr [RBP + -0x68]
PUSH qword ptr [RBP + 0x10]
CALL 0x0018a7f3
ADD RSP,0x10
MOV RCX,R13
CMP EAX,0x1
JZ 0x0018a92d
JMP 0x0018a94d
LAB_0018a90d:
MOV R8D,0x6000
CALL 0x0018b3dc
TEST EAX,EAX
JZ 0x0018a9f0
MOV RAX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RAX]
MOV ECX,dword ptr [RAX + 0x178]
LAB_0018a92d:
ADD RBX,R12
ADD RBX,RCX
CMP RBX,R15
MOV RSI,qword ptr [RBP + -0x40]
MOV ECX,dword ptr [RBP + -0x34]
JC 0x0018a8b3
MOV EAX,0x1
JMP 0x0018ab59
LAB_0018a94d:
CMP EAX,0x2
JZ 0x0018aa4e
TEST EAX,EAX
JNZ 0x0018ab54
MOV RAX,qword ptr [RBP + -0x60]
MOV R15D,dword ptr [RAX]
ADD R15D,dword ptr [RBP + -0x34]
MOV R14,qword ptr [RBP + -0x40]
MOVZX EAX,word ptr [R14 + 0xe]
IMUL R12D,EAX,0xaaab
SHR R12D,0x11
MOV EDI,R13D
MOV RSI,RBX
CALL 0x0018459a
MOV R8,RAX
CMP R15D,R12D
JNC 0x0018aabe
MOV R14,qword ptr [RBP + 0x10]
MOV RDX,qword ptr [R14]
CMP RDX,qword ptr [R14 + 0x8]
JNZ 0x0018aaf7
MOV qword ptr [RBP + -0x70],R8
ADD RDX,0xa
MOV qword ptr [R14 + 0x8],RDX
LEA RAX,[0xcff4f4]
MOV EDI,dword ptr [RAX]
MOV RSI,qword ptr [R14 + 0x10]
SHL RDX,0x4
MOV ECX,0x40
CALL 0x0019ffc0
MOV qword ptr [R14 + 0x10],RAX
TEST RAX,RAX
MOV R15,qword ptr [RBP + -0x58]
JZ 0x0018ab54
MOV RDX,qword ptr [R14]
MOV R12,qword ptr [RBP + -0x50]
MOV ECX,dword ptr [RBP + -0x34]
MOV R8,qword ptr [RBP + -0x70]
JMP 0x0018ab06
LAB_0018a9f0:
MOV R15,qword ptr [RBP + -0x48]
MOV RDI,R15
MOV R14,qword ptr [RBP + -0x58]
MOV RSI,R14
MOV RDX,RBX
MOV ECX,dword ptr [RBP + -0x34]
XOR R8D,R8D
CALL 0x0018b2e7
MOVZX EAX,byte ptr [R14 + 0x1]
MOV ECX,dword ptr [R14]
AND ECX,0x7f
SHL ECX,0x8
OR ECX,EAX
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX],ECX
MOV RDI,R15
CMP ECX,0x2
JNZ 0x0018aa97
MOV RSI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x50]
MOV ECX,0x3
CALL 0x00183d9f
TEST EAX,EAX
JNZ 0x0018ab54
MOV EAX,0x2
JMP 0x0018ab59
LAB_0018aa4e:
MOV R15,qword ptr [RBP + -0x48]
MOV RDI,R15
MOV R14,qword ptr [RBP + -0x58]
MOV RSI,R14
MOV RDX,RBX
MOV ECX,dword ptr [RBP + -0x34]
MOV R8D,R13D
CALL 0x0018b2e7
MOV RDI,R15
MOV RSI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x50]
MOV ECX,0x3
MOV R8,R14
CALL 0x00183ccc
TEST EAX,EAX
JNZ 0x0018ab54
MOVZX EAX,byte ptr [R14 + 0x1]
MOV ECX,dword ptr [R14]
JMP 0x0018ab7f
LAB_0018aa97:
MOV RSI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x50]
MOV ECX,0x3
MOV R8,R14
CALL 0x00183ccc
TEST EAX,EAX
MOV EAX,0x0
JNZ 0x0018ab54
JMP 0x0018ab59
LAB_0018aabe:
MOV RDI,qword ptr [RBP + -0x48]
MOV RSI,R14
MOV RDX,RBX
MOV ECX,dword ptr [RBP + -0x34]
CALL 0x0018b374
TEST EAX,EAX
MOV R8,qword ptr [RBP + -0x58]
JNZ 0x0018ab54
MOV RDI,qword ptr [RBP + -0x48]
MOV RSI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x50]
MOV ECX,0x3
CALL 0x00183ccc
TEST EAX,EAX
JNZ 0x0018ab54
JMP 0x0018ab8d
LAB_0018aaf7:
MOV RAX,qword ptr [R14 + 0x10]
MOV R15,qword ptr [RBP + -0x58]
MOV R12,qword ptr [RBP + -0x50]
MOV ECX,dword ptr [RBP + -0x34]
LAB_0018ab06:
SHL RDX,0x4
MOV qword ptr [RAX + RDX*0x1 + 0x8],R8
MOV RAX,qword ptr [R14]
MOV RDX,qword ptr [R14 + 0x10]
SHL RAX,0x4
MOV RSI,qword ptr [RBP + -0x68]
MOV dword ptr [RDX + RAX*0x1],ESI
INC qword ptr [R14]
MOV R14,qword ptr [RBP + -0x48]
MOV RDI,R14
MOV RSI,R15
MOV RDX,RBX
MOV R8D,R13D
CALL 0x0018b2e7
MOV RDI,R14
MOV RSI,qword ptr [RBP + -0x40]
MOV RDX,R12
MOV ECX,0x3
MOV R8,R15
CALL 0x00183ccc
TEST EAX,EAX
JZ 0x0018ab77
LAB_0018ab54:
MOV EAX,0xffffffff
LAB_0018ab59:
MOV RCX,qword ptr FS:[0x28]
CMP RCX,qword ptr [RBP + -0x30]
JNZ 0x0018ab91
LEA RSP,[RBP + -0x28]
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0018ab77:
MOVZX EAX,byte ptr [R15 + 0x1]
MOV ECX,dword ptr [R15]
LAB_0018ab7f:
AND ECX,0x7f
SHL ECX,0x8
OR ECX,EAX
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX],ECX
LAB_0018ab8d:
XOR EAX,EAX
JMP 0x0018ab59
LAB_0018ab91:
CALL 0x00129250
|
int8
rtree_delete_req(long *param_1,long param_2,int8 param_3,uint param_4,int8 param_5,
uint *param_6,long *param_7,int param_8)
{
byte bVar1;
ushort uVar2;
long lVar3;
int8 uVar4;
long *plVar5;
uint uVar6;
int iVar7;
long lVar8;
int8 uVar9;
long lVar10;
uint uVar11;
ulong uVar12;
byte *pbVar13;
uint *puVar14;
ulong uVar15;
ulong uVar16;
uint uVar17;
byte *pbVar18;
long in_FS_OFFSET;
ulong auStack_90 [3];
int8 local_78;
ulong local_70;
uint *local_68;
uint *local_60;
int8 local_58;
long *local_50;
long local_48;
uint local_3c;
long local_38;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
lVar3 = -(ulong)(*(ushort *)(param_2 + 0xe) + 0xf & 0xfffffff0);
puVar14 = (uint *)((long)&local_78 + lVar3);
uVar11 = 0;
local_68 = param_6;
local_58 = param_5;
local_50 = param_1;
local_48 = param_2;
local_3c = param_4;
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18a84f;
lVar8 = _mi_fetch_keypage(param_1,param_2,param_5,3,puVar14,0);
if (lVar8 == 0) {
LAB_0018ab54:
uVar9 = 0xffffffff;
}
else {
if ((char)(byte)*puVar14 < '\0') {
uVar11 = *(uint *)(*local_50 + 0x17c);
}
uVar16 = (ulong)uVar11;
pbVar13 = (byte *)((long)puVar14 + uVar16 + 2);
pbVar18 = (byte *)(((ulong)(((byte)*puVar14 & 0x7f) << 8) |
(ulong)*(byte *)((long)&local_78 + lVar3 + 1)) + (long)puVar14);
uVar9 = 1;
if (pbVar13 < pbVar18) {
local_70 = (ulong)(param_8 + 1);
uVar15 = (ulong)local_3c;
local_60 = puVar14;
do {
uVar6 = local_3c;
uVar9 = *(int8 *)(local_48 + 0x28);
if (uVar16 == 0) {
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18a918;
iVar7 = rtree_key_cmp(uVar9,param_3,pbVar13,uVar6,0x6000);
uVar6 = local_3c;
plVar5 = local_50;
puVar14 = local_60;
if (iVar7 == 0) {
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18aa0c;
rtree_delete_key(plVar5,puVar14,pbVar13,uVar6,0);
lVar8 = local_48;
uVar9 = local_58;
uVar11 = (*puVar14 & 0x7f) << 8 | (uint)*(byte *)((long)puVar14 + 1);
*local_68 = uVar11;
if (uVar11 != 2) {
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18aaac;
iVar7 = _mi_write_keypage(plVar5,lVar8,uVar9,3,puVar14);
uVar9 = 0;
if (iVar7 == 0) goto LAB_0018ab59;
goto LAB_0018ab54;
}
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18aa3c;
iVar7 = _mi_dispose(plVar5,lVar8,uVar9,3);
if (iVar7 != 0) goto LAB_0018ab54;
uVar9 = 2;
goto LAB_0018ab59;
}
uVar12 = (ulong)*(uint *)(*local_50 + 0x178);
}
else {
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18a8cd;
iVar7 = rtree_key_cmp(uVar9,param_3,pbVar13,uVar6,0x800);
uVar12 = uVar16;
if (iVar7 == 0) {
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18a8df;
uVar9 = _mi_kpos(uVar16,pbVar13);
uVar6 = local_3c;
lVar8 = local_48;
plVar5 = local_50;
puVar14 = local_68;
*(ulong *)((long)auStack_90 + lVar3 + 0x10) = local_70;
*(long **)((long)auStack_90 + lVar3 + 8) = param_7;
*(int8 *)((long)auStack_90 + lVar3) = 0x18a8ff;
iVar7 = rtree_delete_req(plVar5,lVar8,param_3,uVar6,uVar9,puVar14);
uVar6 = local_3c;
lVar8 = local_48;
plVar5 = local_50;
puVar14 = local_60;
if (iVar7 != 1) {
if (iVar7 == 2) {
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18aa6a;
rtree_delete_key(plVar5,puVar14,pbVar13,uVar6,uVar11);
lVar8 = local_48;
uVar9 = local_58;
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18aa82;
iVar7 = _mi_write_keypage(plVar5,lVar8,uVar9,3,puVar14);
if (iVar7 != 0) goto LAB_0018ab54;
bVar1 = *(byte *)((long)puVar14 + 1);
uVar11 = *puVar14;
LAB_0018ab7f:
*local_68 = (uVar11 & 0x7f) << 8 | (uint)bVar1;
}
else {
if (iVar7 != 0) goto LAB_0018ab54;
uVar17 = *local_68 + local_3c;
uVar2 = *(ushort *)(local_48 + 0xe);
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18a988;
uVar9 = _mi_kpos(uVar16,pbVar13);
uVar6 = local_3c;
plVar5 = local_50;
if (uVar17 < uVar2 / 3) {
lVar8 = *param_7;
if (lVar8 == param_7[1]) {
param_7[1] = lVar8 + 10;
lVar10 = param_7[2];
local_78 = uVar9;
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18a9cc;
lVar10 = my_realloc(mi_key_memory_stPageList_pages,lVar10,(lVar8 + 10) * 0x10,
0x40);
param_7[2] = lVar10;
if (lVar10 == 0) goto LAB_0018ab54;
lVar8 = *param_7;
uVar9 = local_78;
}
else {
lVar10 = param_7[2];
}
uVar6 = local_3c;
plVar5 = local_50;
uVar4 = local_58;
puVar14 = local_60;
*(int8 *)(lVar10 + 8 + lVar8 * 0x10) = uVar9;
*(int *)(param_7[2] + *param_7 * 0x10) = (int)local_70;
*param_7 = *param_7 + 1;
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18ab39;
rtree_delete_key(plVar5,puVar14,pbVar13,uVar6,uVar11);
lVar8 = local_48;
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18ab50;
iVar7 = _mi_write_keypage(plVar5,lVar8,uVar4,3,puVar14);
if (iVar7 == 0) {
bVar1 = *(byte *)((long)puVar14 + 1);
uVar11 = *puVar14;
goto LAB_0018ab7f;
}
goto LAB_0018ab54;
}
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18aad0;
iVar7 = rtree_set_key_mbr(plVar5,lVar8,pbVar13,uVar6);
lVar8 = local_48;
plVar5 = local_50;
uVar9 = local_58;
puVar14 = local_60;
if (iVar7 != 0) goto LAB_0018ab54;
*(int8 *)((long)auStack_90 + lVar3 + 0x10) = 0x18aaee;
iVar7 = _mi_write_keypage(plVar5,lVar8,uVar9,3,puVar14);
if (iVar7 != 0) goto LAB_0018ab54;
}
uVar9 = 0;
goto LAB_0018ab59;
}
}
}
pbVar13 = pbVar13 + uVar12 + uVar15;
} while (pbVar13 < pbVar18);
uVar9 = 1;
}
}
LAB_0018ab59:
if (*(long *)(in_FS_OFFSET + 0x28) != local_38) {
/* WARNING: Subroutine does not return */
*(code **)((long)auStack_90 + lVar3 + 0x10) = rtree_estimate;
__stack_chk_fail();
}
return uVar9;
}
| |
23,397 | binding_system_resolve_binding | tsotchke[P]eshkol/src/frontend/binding/core/binding_management.c | uint64_t binding_system_resolve_binding(BindingSystem* system, StringId name) {
assert(system != NULL);
assert(name != NULL);
// Get current scope
uint64_t scope_id = system->current_scope_id;
// Search for binding in current scope and parent scopes
while (scope_id != 0) {
// Search for binding in current scope
for (size_t i = 0; i < system->binding_table.count; i++) {
if (system->binding_table.scope_ids[i] == scope_id &&
strcmp(system->binding_table.names[i], name) == 0) {
// Found binding
return system->binding_table.binding_ids[i];
}
}
// Get parent scope
scope_id = binding_system_get_parent_scope(system, scope_id);
}
// Binding not found
return 0;
} | O0 | c | binding_system_resolve_binding:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x115b9
jmp 0x115d8
leaq 0x580f(%rip), %rdi # 0x16dcf
leaq 0xa420(%rip), %rsi # 0x1b9e7
movl $0x56, %edx
leaq 0xa4c3(%rip), %rcx # 0x1ba96
callq 0x1120
cmpq $0x0, -0x18(%rbp)
je 0x115e1
jmp 0x11600
leaq 0x5ba2(%rip), %rdi # 0x1718a
leaq 0xa3f8(%rip), %rsi # 0x1b9e7
movl $0x57, %edx
leaq 0xa49b(%rip), %rcx # 0x1ba96
callq 0x1120
movq -0x10(%rbp), %rax
movq 0x110(%rax), %rax
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x116a0
movq $0x0, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x48(%rcx), %rax
jae 0x1168a
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rax
cmpq -0x20(%rbp), %rax
jne 0x1167a
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
movq -0x18(%rbp), %rsi
callq 0x1160
cmpl $0x0, %eax
jne 0x1167a
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x8(%rbp)
jmp 0x116a8
jmp 0x1167c
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x11622
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0x53e0
movq %rax, -0x20(%rbp)
jmp 0x1160f
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| binding_system_resolve_binding:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
cmp [rbp+var_10], 0
jz short loc_115B9
jmp short loc_115D8
loc_115B9:
lea rdi, aSystemNull; "system != NULL"
lea rsi, aWorkspaceLlm4b_20; "/workspace/llm4binary/github/2025_star3"...
mov edx, 56h ; 'V'
lea rcx, aUint64TBinding_3; "uint64_t binding_system_resolve_binding"...
call ___assert_fail
loc_115D8:
cmp [rbp+var_18], 0
jz short loc_115E1
jmp short loc_11600
loc_115E1:
lea rdi, aFunctionNameNu+9; "name != NULL"
lea rsi, aWorkspaceLlm4b_20; "/workspace/llm4binary/github/2025_star3"...
mov edx, 57h ; 'W'
lea rcx, aUint64TBinding_3; "uint64_t binding_system_resolve_binding"...
call ___assert_fail
loc_11600:
mov rax, [rbp+var_10]
mov rax, [rax+110h]
mov [rbp+var_20], rax
loc_1160F:
cmp [rbp+var_20], 0
jz loc_116A0
mov [rbp+var_28], 0
loc_11622:
mov rax, [rbp+var_28]
mov rcx, [rbp+var_10]
cmp rax, [rcx+48h]
jnb short loc_1168A
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov rcx, [rbp+var_28]
mov rax, [rax+rcx*8]
cmp rax, [rbp+var_20]
jnz short loc_1167A
mov rax, [rbp+var_10]
mov rax, [rax+10h]
mov rcx, [rbp+var_28]
mov rdi, [rax+rcx*8]
mov rsi, [rbp+var_18]
call _strcmp
cmp eax, 0
jnz short loc_1167A
mov rax, [rbp+var_10]
mov rax, [rax+18h]
mov rcx, [rbp+var_28]
mov rax, [rax+rcx*8]
mov [rbp+var_8], rax
jmp short loc_116A8
loc_1167A:
jmp short $+2
loc_1167C:
mov rax, [rbp+var_28]
add rax, 1
mov [rbp+var_28], rax
jmp short loc_11622
loc_1168A:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_20]
call binding_system_get_parent_scope
mov [rbp+var_20], rax
jmp loc_1160F
loc_116A0:
mov [rbp+var_8], 0
loc_116A8:
mov rax, [rbp+var_8]
add rsp, 30h
pop rbp
retn
| long long binding_system_resolve_binding(_QWORD *a1, long long a2)
{
unsigned long long j; // [rsp+8h] [rbp-28h]
long long i; // [rsp+10h] [rbp-20h]
if ( !a1 )
__assert_fail(
"system != NULL",
"/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/frontend/binding/core/binding_management.c",
86LL,
"uint64_t binding_system_resolve_binding(BindingSystem *, StringId)");
if ( !a2 )
__assert_fail(
"name != NULL",
"/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/frontend/binding/core/binding_management.c",
87LL,
"uint64_t binding_system_resolve_binding(BindingSystem *, StringId)");
for ( i = a1[34]; i; i = binding_system_get_parent_scope(a1, i) )
{
for ( j = 0LL; j < a1[9]; ++j )
{
if ( *(_QWORD *)(a1[4] + 8 * j) == i && !(unsigned int)strcmp(*(_QWORD *)(a1[2] + 8 * j), a2) )
return *(_QWORD *)(a1[3] + 8 * j);
}
}
return 0LL;
}
| binding_system_resolve_binding:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
CMP qword ptr [RBP + -0x10],0x0
JZ 0x001115b9
JMP 0x001115d8
LAB_001115b9:
LEA RDI,[0x116dcf]
LEA RSI,[0x11b9e7]
MOV EDX,0x56
LEA RCX,[0x11ba96]
CALL 0x00101120
LAB_001115d8:
CMP qword ptr [RBP + -0x18],0x0
JZ 0x001115e1
JMP 0x00111600
LAB_001115e1:
LEA RDI,[0x11718a]
LEA RSI,[0x11b9e7]
MOV EDX,0x57
LEA RCX,[0x11ba96]
CALL 0x00101120
LAB_00111600:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x110]
MOV qword ptr [RBP + -0x20],RAX
LAB_0011160f:
CMP qword ptr [RBP + -0x20],0x0
JZ 0x001116a0
MOV qword ptr [RBP + -0x28],0x0
LAB_00111622:
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RCX + 0x48]
JNC 0x0011168a
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + RCX*0x8]
CMP RAX,qword ptr [RBP + -0x20]
JNZ 0x0011167a
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x28]
MOV RDI,qword ptr [RAX + RCX*0x8]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x00101160
CMP EAX,0x0
JNZ 0x0011167a
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x18]
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001116a8
LAB_0011167a:
JMP 0x0011167c
LAB_0011167c:
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x1
MOV qword ptr [RBP + -0x28],RAX
JMP 0x00111622
LAB_0011168a:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x001053e0
MOV qword ptr [RBP + -0x20],RAX
JMP 0x0011160f
LAB_001116a0:
MOV qword ptr [RBP + -0x8],0x0
LAB_001116a8:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x30
POP RBP
RET
|
int8 binding_system_resolve_binding(long param_1,char *param_2)
{
int iVar1;
ulong local_30;
long local_28;
if (param_1 == 0) {
/* WARNING: Subroutine does not return */
__assert_fail("system != NULL",
"/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/frontend/binding/core/binding_management.c"
,0x56,"uint64_t binding_system_resolve_binding(BindingSystem *, StringId)");
}
if (param_2 != (char *)0x0) {
local_28 = *(long *)(param_1 + 0x110);
do {
if (local_28 == 0) {
return 0;
}
for (local_30 = 0; local_30 < *(ulong *)(param_1 + 0x48); local_30 = local_30 + 1) {
if ((*(long *)(*(long *)(param_1 + 0x20) + local_30 * 8) == local_28) &&
(iVar1 = strcmp(*(char **)(*(long *)(param_1 + 0x10) + local_30 * 8),param_2), iVar1 == 0
)) {
return *(int8 *)(*(long *)(param_1 + 0x18) + local_30 * 8);
}
}
local_28 = binding_system_get_parent_scope(param_1,local_28);
} while( true );
}
/* WARNING: Subroutine does not return */
__assert_fail("name != NULL",
"/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/frontend/binding/core/binding_management.c"
,0x57,"uint64_t binding_system_resolve_binding(BindingSystem *, StringId)");
}
| |
23,398 | expand_tilde | eloqsql/mysys/mf_pack.c | static char * expand_tilde(char **path)
{
if (path[0][0] == FN_LIBCHAR)
return home_dir; /* ~/ expanded to home */
#ifdef HAVE_GETPWNAM
{
char *str,save;
struct passwd *user_entry;
if (!(str=strchr(*path,FN_LIBCHAR)))
str=strend(*path);
save= *str; *str= '\0';
user_entry=getpwnam(*path);
*str=save;
endpwent();
if (user_entry)
{
*path=str;
return user_entry->pw_dir;
}
}
#endif
return (char *) 0;
} | O0 | c | expand_tilde:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movsbl (%rax), %eax
cmpl $0x2f, %eax
jne 0x407ae
leaq 0x360476(%rip), %rax # 0x3a0c18
movq (%rax), %rax
movq %rax, -0x8(%rbp)
jmp 0x4082f
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movl $0x2f, %esi
callq 0x25120
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
jne 0x407d9
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x86e10
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movb (%rax), %al
movb %al, -0x19(%rbp)
movq -0x18(%rbp), %rax
movb $0x0, (%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x25250
movq %rax, -0x28(%rbp)
movb -0x19(%rbp), %cl
movq -0x18(%rbp), %rax
movb %cl, (%rax)
callq 0x253b0
cmpq $0x0, -0x28(%rbp)
je 0x40827
movq -0x18(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x28(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x8(%rbp)
jmp 0x4082f
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
| expand_tilde:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov rax, [rbp+var_10]
mov rax, [rax]
movsx eax, byte ptr [rax]
cmp eax, 2Fh ; '/'
jnz short loc_407AE
lea rax, home_dir
mov rax, [rax]
mov [rbp+var_8], rax
jmp loc_4082F
loc_407AE:
mov rax, [rbp+var_10]
mov rdi, [rax]
mov esi, 2Fh ; '/'
call _strchr
mov [rbp+var_18], rax
cmp rax, 0
jnz short loc_407D9
mov rax, [rbp+var_10]
mov rdi, [rax]
call strend
mov [rbp+var_18], rax
loc_407D9:
mov rax, [rbp+var_18]
mov al, [rax]
mov [rbp+var_19], al
mov rax, [rbp+var_18]
mov byte ptr [rax], 0
mov rax, [rbp+var_10]
mov rdi, [rax]
call _getpwnam
mov [rbp+var_28], rax
mov cl, [rbp+var_19]
mov rax, [rbp+var_18]
mov [rax], cl
call _endpwent
cmp [rbp+var_28], 0
jz short loc_40827
mov rcx, [rbp+var_18]
mov rax, [rbp+var_10]
mov [rax], rcx
mov rax, [rbp+var_28]
mov rax, [rax+20h]
mov [rbp+var_8], rax
jmp short loc_4082F
loc_40827:
mov [rbp+var_8], 0
loc_4082F:
mov rax, [rbp+var_8]
add rsp, 30h
pop rbp
retn
| long long expand_tilde(char **a1)
{
long long v2; // [rsp+8h] [rbp-28h]
char v3; // [rsp+17h] [rbp-19h]
char *v4; // [rsp+18h] [rbp-18h]
if ( **a1 == 47 )
return home_dir;
v4 = (char *)strchr(*a1, 47LL);
if ( !v4 )
v4 = (char *)strend(*a1);
v3 = *v4;
*v4 = 0;
v2 = getpwnam(*a1);
*v4 = v3;
endpwent();
if ( !v2 )
return 0LL;
*a1 = v4;
return *(_QWORD *)(v2 + 32);
}
| expand_tilde:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x2f
JNZ 0x001407ae
LEA RAX,[0x4a0c18]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0014082f
LAB_001407ae:
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX]
MOV ESI,0x2f
CALL 0x00125120
MOV qword ptr [RBP + -0x18],RAX
CMP RAX,0x0
JNZ 0x001407d9
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX]
CALL 0x00186e10
MOV qword ptr [RBP + -0x18],RAX
LAB_001407d9:
MOV RAX,qword ptr [RBP + -0x18]
MOV AL,byte ptr [RAX]
MOV byte ptr [RBP + -0x19],AL
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX]
CALL 0x00125250
MOV qword ptr [RBP + -0x28],RAX
MOV CL,byte ptr [RBP + -0x19]
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX],CL
CALL 0x001253b0
CMP qword ptr [RBP + -0x28],0x0
JZ 0x00140827
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x20]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0014082f
LAB_00140827:
MOV qword ptr [RBP + -0x8],0x0
LAB_0014082f:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x30
POP RBP
RET
|
char * expand_tilde(int8 *param_1)
{
char cVar1;
passwd *ppVar2;
char *local_20;
char *local_10;
if (*(char *)*param_1 == '/') {
local_10 = home_dir;
}
else {
local_20 = strchr((char *)*param_1,0x2f);
if (local_20 == (char *)0x0) {
local_20 = (char *)strend(*param_1);
}
cVar1 = *local_20;
*local_20 = '\0';
ppVar2 = getpwnam((char *)*param_1);
*local_20 = cVar1;
endpwent();
if (ppVar2 == (passwd *)0x0) {
local_10 = (char *)0x0;
}
else {
*param_1 = local_20;
local_10 = ppVar2->pw_dir;
}
}
return local_10;
}
| |
23,399 | ma_store_length | eloqsql/storage/maria/ma_blockrec.c | uchar *ma_store_length(uchar *to, ulong nr)
{
if (nr < 251)
{
*to=(uchar) nr;
return to+1;
}
if (nr < 65536)
{
if (nr <= 255)
{
to[0]= (uchar) 251;
to[1]= (uchar) nr;
return to+2;
}
to[0]= (uchar) 252;
int2store(to+1, nr);
return to+3;
}
if (nr < 16777216)
{
*to++= (uchar) 253;
int3store(to, nr);
return to+3;
}
*to++= (uchar) 254;
int4store(to, nr);
return to+4;
} | O3 | c | ma_store_length:
pushq %rbp
movq %rsp, %rbp
movq %rsi, %rcx
movq %rdi, %rax
cmpq $0xfa, %rsi
ja 0x5ed21
movb %cl, (%rax)
movl $0x1, %ecx
addq %rcx, %rax
popq %rbp
retq
cmpq $0xffff, %rcx # imm = 0xFFFF
ja 0x5ed40
cmpq $0xff, %rcx
ja 0x5ed5f
movb $-0x5, (%rax)
movb %cl, 0x1(%rax)
movl $0x2, %ecx
jmp 0x5ed1c
cmpq $0xffffff, %rcx # imm = 0xFFFFFF
ja 0x5ed6d
movb $-0x3, (%rax)
movb %cl, 0x1(%rax)
movb %ch, 0x2(%rax)
shrl $0x10, %ecx
movb %cl, 0x3(%rax)
movl $0x4, %ecx
jmp 0x5ed1c
movb $-0x4, (%rax)
movw %cx, 0x1(%rax)
movl $0x3, %ecx
jmp 0x5ed1c
movb $-0x2, (%rax)
movl %ecx, 0x1(%rax)
movl $0x5, %ecx
jmp 0x5ed1c
| ma_store_length:
push rbp
mov rbp, rsp
mov rcx, rsi
mov rax, rdi
cmp rsi, 0FAh
ja short loc_5ED21
mov [rax], cl
mov ecx, 1
loc_5ED1C:
add rax, rcx
pop rbp
retn
loc_5ED21:
cmp rcx, 0FFFFh
ja short loc_5ED40
cmp rcx, 0FFh
ja short loc_5ED5F
mov byte ptr [rax], 0FBh
mov [rax+1], cl
mov ecx, 2
jmp short loc_5ED1C
loc_5ED40:
cmp rcx, 0FFFFFFh
ja short loc_5ED6D
mov byte ptr [rax], 0FDh
mov [rax+1], cl
mov [rax+2], ch
shr ecx, 10h
mov [rax+3], cl
mov ecx, 4
jmp short loc_5ED1C
loc_5ED5F:
mov byte ptr [rax], 0FCh
mov [rax+1], cx
mov ecx, 3
jmp short loc_5ED1C
loc_5ED6D:
mov byte ptr [rax], 0FEh
mov [rax+1], ecx
mov ecx, 5
jmp short loc_5ED1C
| long long ma_store_length(long long a1, unsigned long long a2)
{
long long v2; // rcx
if ( a2 > 0xFA )
{
if ( a2 > 0xFFFF )
{
if ( a2 > 0xFFFFFF )
{
*(_BYTE *)a1 = -2;
*(_DWORD *)(a1 + 1) = a2;
v2 = 5LL;
}
else
{
*(_BYTE *)a1 = -3;
*(_WORD *)(a1 + 1) = a2;
*(_BYTE *)(a1 + 3) = BYTE2(a2);
v2 = 4LL;
}
}
else if ( a2 > 0xFF )
{
*(_BYTE *)a1 = -4;
*(_WORD *)(a1 + 1) = a2;
v2 = 3LL;
}
else
{
*(_BYTE *)a1 = -5;
*(_BYTE *)(a1 + 1) = a2;
v2 = 2LL;
}
}
else
{
*(_BYTE *)a1 = a2;
v2 = 1LL;
}
return v2 + a1;
}
| ma_store_length:
PUSH RBP
MOV RBP,RSP
MOV RCX,RSI
MOV RAX,RDI
CMP RSI,0xfa
JA 0x0015ed21
MOV byte ptr [RAX],CL
MOV ECX,0x1
LAB_0015ed1c:
ADD RAX,RCX
POP RBP
RET
LAB_0015ed21:
CMP RCX,0xffff
JA 0x0015ed40
CMP RCX,0xff
JA 0x0015ed5f
MOV byte ptr [RAX],0xfb
MOV byte ptr [RAX + 0x1],CL
MOV ECX,0x2
JMP 0x0015ed1c
LAB_0015ed40:
CMP RCX,0xffffff
JA 0x0015ed6d
MOV byte ptr [RAX],0xfd
MOV byte ptr [RAX + 0x1],CL
MOV byte ptr [RAX + 0x2],CH
SHR ECX,0x10
MOV byte ptr [RAX + 0x3],CL
MOV ECX,0x4
JMP 0x0015ed1c
LAB_0015ed5f:
MOV byte ptr [RAX],0xfc
MOV word ptr [RAX + 0x1],CX
MOV ECX,0x3
JMP 0x0015ed1c
LAB_0015ed6d:
MOV byte ptr [RAX],0xfe
MOV dword ptr [RAX + 0x1],ECX
MOV ECX,0x5
JMP 0x0015ed1c
|
int1 * ma_store_length(int1 *param_1,ulong param_2)
{
int1 uVar1;
long lVar2;
uVar1 = (int1)param_2;
if (param_2 < 0xfb) {
*param_1 = uVar1;
lVar2 = 1;
}
else if (param_2 < 0x10000) {
if (param_2 < 0x100) {
*param_1 = 0xfb;
param_1[1] = uVar1;
lVar2 = 2;
}
else {
*param_1 = 0xfc;
*(short *)(param_1 + 1) = (short)param_2;
lVar2 = 3;
}
}
else if (param_2 < 0x1000000) {
*param_1 = 0xfd;
param_1[1] = uVar1;
param_1[2] = (char)(param_2 >> 8);
param_1[3] = (char)(param_2 >> 0x10);
lVar2 = 4;
}
else {
*param_1 = 0xfe;
*(int *)(param_1 + 1) = (int)param_2;
lVar2 = 5;
}
return param_1 + lVar2;
}
|
Subsets and Splits
C++ Functions Using STL
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++ STL Function Queries
Filters C++ code examples that use standard library containers and algorithms, helping identify common programming patterns and library usage in code generation tasks.
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.