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
|
---|---|---|---|---|---|---|---|---|---|---|---|
64,800 |
my_fill_ucs2
|
eloqsql/strings/ctype-ucs2.c
|
static void
my_fill_ucs2(CHARSET_INFO *cs __attribute__((unused)),
char *s, size_t l, int fill)
{
DBUG_ASSERT(fill <= 0xFFFF);
#ifdef WAITING_FOR_GCC_VECTORIZATION_BUG_TO_BE_FIXED
/*
This code with int2store() is known to be faster on some processors,
but crashes on other processors due to a possible bug in GCC's
-ftree-vectorization (which is enabled in -O3) in case of
a non-aligned memory. See here for details:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58039
*/
char *last= s + l - 2;
uint16 tmp= (fill >> 8) + ((fill & 0xFF) << 8); /* swap bytes */
DBUG_ASSERT(fill <= 0xFFFF);
for ( ; s <= last; s+= 2)
int2store(s, tmp); /* store little-endian */
#else
for ( ; l >= 2; s[0]= (fill >> 8), s[1]= (fill & 0xFF), s+= 2, l-= 2);
#endif
}
|
O3
|
c
|
my_fill_ucs2:
cmpq $0x2, %rdx
jb 0x2b386
pushq %rbp
movq %rsp, %rbp
movl %ecx, %eax
shrl $0x8, %eax
movb %al, (%rsi)
movb %cl, 0x1(%rsi)
addq $0x2, %rsi
addq $-0x2, %rdx
cmpq $0x1, %rdx
ja 0x2b372
popq %rbp
retq
|
my_fill_ucs2:
cmp rdx, 2
jb short locret_2B386
push rbp
mov rbp, rsp
mov eax, ecx
shr eax, 8
loc_2B372:
mov [rsi], al
mov [rsi+1], cl
add rsi, 2
add rdx, 0FFFFFFFFFFFFFFFEh
cmp rdx, 1
ja short loc_2B372
pop rbp
locret_2B386:
retn
|
void my_fill_ucs2(long long a1, _BYTE *a2, unsigned long long a3, __int16 a4)
{
bool v4; // cf
if ( a3 >= 2 )
{
do
{
*a2 = HIBYTE(a4);
a2[1] = a4;
a2 += 2;
v4 = a3 == 2;
a3 -= 2LL;
}
while ( !v4 && a3 != 1 );
}
}
|
my_fill_ucs2:
CMP RDX,0x2
JC 0x0012b386
PUSH RBP
MOV RBP,RSP
MOV EAX,ECX
SHR EAX,0x8
LAB_0012b372:
MOV byte ptr [RSI],AL
MOV byte ptr [RSI + 0x1],CL
ADD RSI,0x2
ADD RDX,-0x2
CMP RDX,0x1
JA 0x0012b372
POP RBP
LAB_0012b386:
RET
|
void my_fill_ucs2(int8 param_1,int1 *param_2,ulong param_3,int4 param_4)
{
if (1 < param_3) {
do {
*param_2 = (char)((uint)param_4 >> 8);
param_2[1] = (char)param_4;
param_2 = param_2 + 2;
param_3 = param_3 - 2;
} while (1 < param_3);
}
return;
}
|
|
64,801 |
httplib::ClientImpl::process_socket(httplib::ClientImpl::Socket const&, std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l>>>, std::function<bool (httplib::Stream&)>)
|
hkr04[P]cpp-mcp/common/httplib.h
|
inline bool ClientImpl::process_socket(
const Socket &socket,
std::chrono::time_point<std::chrono::steady_clock> start_time,
std::function<bool(Stream &strm)> callback) {
return detail::process_client_socket(
socket.sock, read_timeout_sec_, read_timeout_usec_, write_timeout_sec_,
write_timeout_usec_, max_timeout_msec_, start_time,
std::move(callback));
}
|
O1
|
c
|
httplib::ClientImpl::process_socket(httplib::ClientImpl::Socket const&, std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l>>>, std::function<bool (httplib::Stream&)>):
pushq %rbx
subq $0x90, %rsp
movl (%rsi), %eax
movups 0x198(%rdi), %xmm1
movups 0x1a8(%rdi), %xmm2
movq 0x1b8(%rdi), %rsi
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
movq 0x18(%rcx), %rdi
movq %rdi, 0x18(%rsp)
movq 0x10(%rcx), %rdi
testq %rdi, %rdi
je 0x16d80
movups (%rcx), %xmm3
addq $0x10, %rcx
movaps %xmm3, (%rsp)
movq %rdi, 0x10(%rsp)
movups %xmm0, (%rcx)
leaq 0x45791(%rip), %rcx # 0x5c518
movq %rcx, 0x28(%rsp)
movl %eax, 0x30(%rsp)
movups %xmm1, 0x38(%rsp)
movups %xmm2, 0x48(%rsp)
movq %rsi, 0x58(%rsp)
movq %rdx, 0x60(%rsp)
movups %xmm0, 0x68(%rsp)
movq $0x0, 0x78(%rsp)
movl $0x1000, %edi # imm = 0x1000
callq 0x8570
movq %rax, 0x68(%rsp)
movq %rax, 0x70(%rsp)
movq %rax, %rbx
addq $0x1000, %rbx # imm = 0x1000
movq %rbx, 0x78(%rsp)
movl $0x1000, %edx # imm = 0x1000
movq %rax, %rdi
xorl %esi, %esi
callq 0x82e0
movq %rbx, 0x70(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0x80(%rsp)
cmpq $0x0, 0x10(%rsp)
je 0x16e42
movq %rsp, %rdi
leaq 0x28(%rsp), %rsi
callq *0x18(%rdi)
movl %eax, %ebx
movq 0x68(%rsp), %rdi
testq %rdi, %rdi
je 0x16e20
movq 0x78(%rsp), %rsi
subq %rdi, %rsi
callq 0x8580
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0x16e37
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movl %ebx, %eax
addq $0x90, %rsp
popq %rbx
retq
callq 0x81c0
jmp 0x16e87
movq %rax, %rbx
jmp 0x16e68
movq %rax, %rbx
movq 0x68(%rsp), %rdi
testq %rdi, %rdi
je 0x16e68
movq 0x78(%rsp), %rsi
subq %rdi, %rsi
callq 0x8580
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0x16e7f
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rdi
callq 0x8960
movq %rax, %rdi
callq 0xae2d
nop
|
_ZN7httplib10ClientImpl14process_socketERKNS0_6SocketENSt6chrono10time_pointINS4_3_V212steady_clockENS4_8durationIlSt5ratioILl1ELl1000000000EEEEEESt8functionIFbRNS_6StreamEEE:
push rbx
sub rsp, 90h
mov eax, [rsi]
movups xmm1, xmmword ptr [rdi+198h]
movups xmm2, xmmword ptr [rdi+1A8h]
mov rsi, [rdi+1B8h]
xorps xmm0, xmm0
movaps [rsp+98h+var_98], xmm0
mov [rsp+98h+var_88], 0
mov rdi, [rcx+18h]
mov [rsp+98h+var_80], rdi
mov rdi, [rcx+10h]
test rdi, rdi
jz short loc_16D80
movups xmm3, xmmword ptr [rcx]
add rcx, 10h
movaps [rsp+98h+var_98], xmm3
mov [rsp+98h+var_88], rdi
movups xmmword ptr [rcx], xmm0
loc_16D80:
lea rcx, off_5C518
mov [rsp+98h+var_70], rcx
mov [rsp+98h+var_68], eax
movups [rsp+98h+var_60], xmm1
movups [rsp+98h+var_50], xmm2
mov [rsp+98h+var_40], rsi
mov [rsp+98h+var_38], rdx
movups xmmword ptr [rsp+98h+var_30], xmm0
mov [rsp+98h+var_20], 0
mov edi, 1000h; unsigned __int64
call __Znwm; operator new(ulong)
mov [rsp+98h+var_30], rax
mov [rsp+98h+var_30+8], rax
mov rbx, rax
add rbx, 1000h
mov [rsp+98h+var_20], rbx
mov edx, 1000h
mov rdi, rax
xor esi, esi
call _memset
mov [rsp+98h+var_30+8], rbx
xorps xmm0, xmm0
movups [rsp+98h+var_18], xmm0
cmp [rsp+98h+var_88], 0
jz short loc_16E42
mov rdi, rsp
lea rsi, [rsp+98h+var_70]
call qword ptr [rdi+18h]
mov ebx, eax
mov rdi, [rsp+98h+var_30]; void *
test rdi, rdi
jz short loc_16E20
mov rsi, [rsp+98h+var_20]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_16E20:
mov rax, [rsp+98h+var_88]
test rax, rax
jz short loc_16E37
mov rdi, rsp
mov rsi, rdi
mov edx, 3
call rax
loc_16E37:
mov eax, ebx
add rsp, 90h
pop rbx
retn
loc_16E42:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
jmp short loc_16E87
mov rbx, rax
jmp short loc_16E68
mov rbx, rax
mov rdi, [rsp+98h+var_30]; void *
test rdi, rdi
jz short loc_16E68
mov rsi, [rsp+98h+var_20]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_16E68:
mov rax, [rsp+98h+var_88]
test rax, rax
jz short loc_16E7F
mov rdi, rsp
mov rsi, rdi
mov edx, 3
call rax
loc_16E7F:
mov rdi, rbx
call __Unwind_Resume
loc_16E87:
mov rdi, rax
call __clang_call_terminate
|
long long httplib::ClientImpl::process_socket(long long a1, int *a2, long long a3, __int128 *a4)
{
int v4; // eax
__int128 v5; // xmm1
__int128 v6; // xmm2
long long v7; // rsi
void ( *v8)(__int128 *, __int128 *, long long); // rdi
unsigned int v9; // ebx
__int128 v11; // [rsp+0h] [rbp-98h] BYREF
void ( *v12)(__int128 *, __int128 *, long long); // [rsp+10h] [rbp-88h]
long long ( *v13)(__int128 *, void ( ***)(httplib::detail::SocketStream *__hidden)); // [rsp+18h] [rbp-80h]
void ( **v14)(httplib::detail::SocketStream *__hidden); // [rsp+28h] [rbp-70h] BYREF
int v15; // [rsp+30h] [rbp-68h]
__int128 v16; // [rsp+38h] [rbp-60h]
__int128 v17; // [rsp+48h] [rbp-50h]
long long v18; // [rsp+58h] [rbp-40h]
long long v19; // [rsp+60h] [rbp-38h]
void *v20[2]; // [rsp+68h] [rbp-30h]
char *v21; // [rsp+78h] [rbp-20h]
__int128 v22; // [rsp+80h] [rbp-18h]
v4 = *a2;
v5 = *(_OWORD *)(a1 + 408);
v6 = *(_OWORD *)(a1 + 424);
v7 = *(_QWORD *)(a1 + 440);
v11 = 0LL;
v12 = 0LL;
v13 = (long long ( *)(__int128 *, void ( ***)(httplib::detail::SocketStream *__hidden)))*((_QWORD *)a4 + 3);
v8 = (void ( *)(__int128 *, __int128 *, long long))*((_QWORD *)a4 + 2);
if ( v8 )
{
v11 = *a4;
v12 = v8;
a4[1] = 0LL;
}
v14 = off_5C518;
v15 = v4;
v16 = v5;
v17 = v6;
v18 = v7;
v19 = a3;
v20[0] = (void *)operator new(0x1000uLL);
v21 = (char *)v20[0] + 4096;
memset(v20[0], 0LL, 4096LL);
v20[1] = (char *)v20[0] + 4096;
v22 = 0LL;
if ( !v12 )
std::__throw_bad_function_call();
v9 = v13(&v11, &v14);
if ( v20[0] )
operator delete(v20[0], v21 - (char *)v20[0]);
if ( v12 )
v12(&v11, &v11, 3LL);
return v9;
}
|
process_socket:
PUSH RBX
SUB RSP,0x90
MOV EAX,dword ptr [RSI]
MOVUPS XMM1,xmmword ptr [RDI + 0x198]
MOVUPS XMM2,xmmword ptr [RDI + 0x1a8]
MOV RSI,qword ptr [RDI + 0x1b8]
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP],XMM0
MOV qword ptr [RSP + 0x10],0x0
MOV RDI,qword ptr [RCX + 0x18]
MOV qword ptr [RSP + 0x18],RDI
MOV RDI,qword ptr [RCX + 0x10]
TEST RDI,RDI
JZ 0x00116d80
MOVUPS XMM3,xmmword ptr [RCX]
ADD RCX,0x10
MOVAPS xmmword ptr [RSP],XMM3
MOV qword ptr [RSP + 0x10],RDI
MOVUPS xmmword ptr [RCX],XMM0
LAB_00116d80:
LEA RCX,[0x15c518]
MOV qword ptr [RSP + 0x28],RCX
MOV dword ptr [RSP + 0x30],EAX
MOVUPS xmmword ptr [RSP + 0x38],XMM1
MOVUPS xmmword ptr [RSP + 0x48],XMM2
MOV qword ptr [RSP + 0x58],RSI
MOV qword ptr [RSP + 0x60],RDX
MOVUPS xmmword ptr [RSP + 0x68],XMM0
MOV qword ptr [RSP + 0x78],0x0
LAB_00116db2:
MOV EDI,0x1000
CALL 0x00108570
LAB_00116dbc:
MOV qword ptr [RSP + 0x68],RAX
MOV qword ptr [RSP + 0x70],RAX
MOV RBX,RAX
ADD RBX,0x1000
MOV qword ptr [RSP + 0x78],RBX
MOV EDX,0x1000
MOV RDI,RAX
XOR ESI,ESI
CALL 0x001082e0
MOV qword ptr [RSP + 0x70],RBX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RSP + 0x80],XMM0
CMP qword ptr [RSP + 0x10],0x0
JZ 0x00116e42
LAB_00116dfc:
MOV RDI,RSP
LEA RSI,[RSP + 0x28]
CALL qword ptr [RDI + 0x18]
MOV EBX,EAX
MOV RDI,qword ptr [RSP + 0x68]
TEST RDI,RDI
JZ 0x00116e20
MOV RSI,qword ptr [RSP + 0x78]
SUB RSI,RDI
CALL 0x00108580
LAB_00116e20:
MOV RAX,qword ptr [RSP + 0x10]
TEST RAX,RAX
JZ 0x00116e37
LAB_00116e2a:
MOV RDI,RSP
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_00116e37:
MOV EAX,EBX
ADD RSP,0x90
POP RBX
RET
LAB_00116e42:
CALL 0x001081c0
|
/* httplib::ClientImpl::process_socket(httplib::ClientImpl::Socket const&,
std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long,
std::ratio<1l, 1000000000l> > >, std::function<bool (httplib::Stream&)>) */
int4 __thiscall
httplib::ClientImpl::process_socket
(ClientImpl *this,int4 *param_1,int8 param_3,int8 *param_4)
{
code *pcVar1;
int4 uVar2;
long lVar3;
int8 local_98;
int8 uStack_90;
code *local_88;
code *local_80;
int **local_70;
int4 local_68;
int8 local_60;
int8 uStack_58;
int8 local_50;
int8 uStack_48;
int8 local_40;
int8 local_38;
void *local_30;
void *pvStack_28;
long local_20;
int8 local_18;
int8 uStack_10;
local_68 = *param_1;
local_60 = *(int8 *)(this + 0x198);
uStack_58 = *(int8 *)(this + 0x1a0);
local_50 = *(int8 *)(this + 0x1a8);
uStack_48 = *(int8 *)(this + 0x1b0);
local_40 = *(int8 *)(this + 0x1b8);
local_98 = 0;
uStack_90 = 0;
local_88 = (code *)0x0;
local_80 = (code *)param_4[3];
pcVar1 = (code *)param_4[2];
if (pcVar1 != (code *)0x0) {
local_98 = *param_4;
uStack_90 = param_4[1];
param_4[2] = 0;
param_4[3] = 0;
local_88 = pcVar1;
}
local_70 = &PTR__SocketStream_0015c518;
local_30 = (void *)0x0;
pvStack_28 = (void *)0x0;
local_20 = 0;
local_38 = param_3;
/* try { // try from 00116db2 to 00116dbb has its CatchHandler @ 00116e49 */
local_30 = operator_new(0x1000);
lVar3 = (long)local_30 + 0x1000;
pvStack_28 = local_30;
local_20 = lVar3;
memset(local_30,0,0x1000);
local_18 = 0;
uStack_10 = 0;
pvStack_28 = (void *)lVar3;
if (local_88 != (code *)0x0) {
/* try { // try from 00116dfc to 00116e06 has its CatchHandler @ 00116e4e */
uVar2 = (*local_80)(&local_98,&local_70);
if (local_30 != (void *)0x0) {
operator_delete(local_30,local_20 - (long)local_30);
}
if (local_88 != (code *)0x0) {
/* try { // try from 00116e2a to 00116e36 has its CatchHandler @ 00116e47 */
(*local_88)(&local_98,&local_98,3);
}
return uVar2;
}
/* WARNING: Subroutine does not return */
/* try { // try from 00116e42 to 00116e46 has its CatchHandler @ 00116e4e */
std::__throw_bad_function_call();
}
|
|
64,802 |
httplib::ClientImpl::process_socket(httplib::ClientImpl::Socket const&, std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l>>>, std::function<bool (httplib::Stream&)>)
|
hkr04[P]cpp-mcp/common/httplib.h
|
inline bool ClientImpl::process_socket(
const Socket &socket,
std::chrono::time_point<std::chrono::steady_clock> start_time,
std::function<bool(Stream &strm)> callback) {
return detail::process_client_socket(
socket.sock, read_timeout_sec_, read_timeout_usec_, write_timeout_sec_,
write_timeout_usec_, max_timeout_msec_, start_time,
std::move(callback));
}
|
O2
|
c
|
httplib::ClientImpl::process_socket(httplib::ClientImpl::Socket const&, std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l>>>, std::function<bool (httplib::Stream&)>):
pushq %rbx
subq $0x20, %rsp
movq %rcx, %r10
movq %rdx, %rax
movq %rdi, %r9
movl (%rsi), %edi
movq 0x198(%r9), %rsi
movq 0x1a0(%r9), %rdx
movq 0x1a8(%r9), %rcx
movq 0x1b0(%r9), %r8
movq 0x1b8(%r9), %r9
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
andq $0x0, 0x10(%rsp)
movq 0x18(%r10), %r11
movq %r11, 0x18(%rsp)
movq 0x10(%r10), %r11
testq %r11, %r11
je 0x1376f
movups (%r10), %xmm1
addq $0x10, %r10
movaps %xmm1, (%rsp)
movq %r11, 0x10(%rsp)
movups %xmm0, (%r10)
movq %rsp, %r10
pushq %r10
pushq %rax
callq 0x2b7bf
popq %rcx
popq %rdx
movl %eax, %ebx
movq %rsp, %rdi
callq 0x35882
movl %ebx, %eax
addq $0x20, %rsp
popq %rbx
retq
movq %rax, %rbx
movq %rsp, %rdi
callq 0x35882
movq %rbx, %rdi
callq 0x89c0
nop
|
_ZN7httplib10ClientImpl14process_socketERKNS0_6SocketENSt6chrono10time_pointINS4_3_V212steady_clockENS4_8durationIlSt5ratioILl1ELl1000000000EEEEEESt8functionIFbRNS_6StreamEEE:
push rbx
sub rsp, 20h
mov r10, rcx
mov rax, rdx
mov r9, rdi
mov edi, [rsi]
mov rsi, [r9+198h]
mov rdx, [r9+1A0h]
mov rcx, [r9+1A8h]
mov r8, [r9+1B0h]
mov r9, [r9+1B8h]
xorps xmm0, xmm0
movaps [rsp+28h+var_28], xmm0
and [rsp+28h+var_18], 0
mov r11, [r10+18h]
mov [rsp+28h+var_10], r11
mov r11, [r10+10h]
test r11, r11
jz short loc_1376F
movups xmm1, xmmword ptr [r10]
add r10, 10h
movaps [rsp+28h+var_28], xmm1
mov [rsp+28h+var_18], r11
movups xmmword ptr [r10], xmm0
loc_1376F:
mov r10, rsp
push r10
push rax
call _ZN7httplib6detail21process_client_socketEilllllNSt6chrono10time_pointINS1_3_V212steady_clockENS1_8durationIlSt5ratioILl1ELl1000000000EEEEEESt8functionIFbRNS_6StreamEEE; httplib::detail::process_client_socket(int,long,long,long,long,long,std::chrono::time_point<std::chrono::_V2::steady_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>>,std::function<bool ()(httplib::Stream &)>)
pop rcx
pop rdx
mov ebx, eax
mov rdi, rsp; this
call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base()
mov eax, ebx
add rsp, 20h
pop rbx
retn
mov rbx, rax
mov rdi, rsp; this
call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base()
mov rdi, rbx
call __Unwind_Resume
|
long long httplib::ClientImpl::process_socket(_QWORD *a1, int *a2, long long a3, __int128 *a4)
{
int v7; // edi
long long v8; // rsi
long long v9; // rdx
long long v10; // rcx
long long v11; // r8
long long v12; // r9
long long v13; // r11
unsigned int v14; // ebx
__int128 v16; // [rsp+0h] [rbp-28h] BYREF
long long v17; // [rsp+10h] [rbp-18h]
long long v18; // [rsp+18h] [rbp-10h]
v7 = *a2;
v8 = a1[51];
v9 = a1[52];
v10 = a1[53];
v11 = a1[54];
v12 = a1[55];
v16 = 0LL;
v17 = 0LL;
v18 = *((_QWORD *)a4 + 3);
v13 = *((_QWORD *)a4 + 2);
if ( v13 )
{
v16 = *a4;
v17 = v13;
a4[1] = 0LL;
}
v14 = ((long long ( *)(int, _DWORD, _DWORD, _DWORD, _DWORD, _DWORD, long long, long long))httplib::detail::process_client_socket)(
v7,
v8,
v9,
v10,
v11,
v12,
a3,
(long long)&v16);
std::_Function_base::~_Function_base((std::_Function_base *)&v16);
return v14;
}
|
process_socket:
PUSH RBX
SUB RSP,0x20
MOV R10,RCX
MOV RAX,RDX
MOV R9,RDI
MOV EDI,dword ptr [RSI]
MOV RSI,qword ptr [R9 + 0x198]
MOV RDX,qword ptr [R9 + 0x1a0]
MOV RCX,qword ptr [R9 + 0x1a8]
MOV R8,qword ptr [R9 + 0x1b0]
MOV R9,qword ptr [R9 + 0x1b8]
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP],XMM0
AND qword ptr [RSP + 0x10],0x0
MOV R11,qword ptr [R10 + 0x18]
MOV qword ptr [RSP + 0x18],R11
MOV R11,qword ptr [R10 + 0x10]
TEST R11,R11
JZ 0x0011376f
MOVUPS XMM1,xmmword ptr [R10]
ADD R10,0x10
MOVAPS xmmword ptr [RSP],XMM1
MOV qword ptr [RSP + 0x10],R11
MOVUPS xmmword ptr [R10],XMM0
LAB_0011376f:
MOV R10,RSP
PUSH R10
PUSH RAX
CALL 0x0012b7bf
POP RCX
POP RDX
LAB_0011377c:
MOV EBX,EAX
MOV RDI,RSP
CALL 0x00135882
MOV EAX,EBX
ADD RSP,0x20
POP RBX
RET
|
/* httplib::ClientImpl::process_socket(httplib::ClientImpl::Socket const&,
std::chrono::time_point<std::chrono::_V2::steady_clock, std::chrono::duration<long,
std::ratio<1l, 1000000000l> > >, std::function<bool (httplib::Stream&)>) */
int4 __thiscall
httplib::ClientImpl::process_socket
(ClientImpl *this,int4 *param_1,int8 param_3,int8 *param_4)
{
int8 uVar1;
int8 uVar2;
int8 uVar3;
int8 uVar4;
int8 uVar5;
long lVar6;
int4 uVar7;
int8 local_28;
int8 uStack_20;
long local_18;
int8 local_10;
uVar7 = *param_1;
uVar1 = *(int8 *)(this + 0x198);
uVar2 = *(int8 *)(this + 0x1a0);
uVar3 = *(int8 *)(this + 0x1a8);
uVar4 = *(int8 *)(this + 0x1b0);
uVar5 = *(int8 *)(this + 0x1b8);
local_28 = 0;
uStack_20 = 0;
local_18 = 0;
local_10 = param_4[3];
lVar6 = param_4[2];
if (lVar6 != 0) {
local_28 = *param_4;
uStack_20 = param_4[1];
param_4[2] = 0;
param_4[3] = 0;
local_18 = lVar6;
}
/* try { // try from 0011376f to 0011377b has its CatchHandler @ 0011378e */
uVar7 = detail::process_client_socket(uVar7,uVar1,uVar2,uVar3,uVar4,uVar5,param_3,&local_28);
std::_Function_base::~_Function_base((_Function_base *)&local_28);
return uVar7;
}
|
|
64,803 |
uf_blob
|
eloqsql/storage/myisam/mi_packrec.c
|
static void uf_blob(MI_COLUMNDEF *rec, MI_BIT_BUFF *bit_buff,
uchar *to, uchar *end)
{
if (get_bit(bit_buff))
bzero((uchar*) to,(end-to));
else
{
ulong length=get_bits(bit_buff,rec->space_length_bits);
uint pack_length=(uint) (end-to)-portable_sizeof_char_ptr;
if (bit_buff->blob_pos+length > bit_buff->blob_end)
{
bit_buff->error=1;
bzero((uchar*) to,(end-to));
return;
}
decode_bytes(rec,bit_buff,bit_buff->blob_pos,bit_buff->blob_pos+length);
_mi_store_blob_length((uchar*) to,pack_length,length);
memcpy(to+pack_length, &bit_buff->blob_pos, sizeof(char*));
bit_buff->blob_pos+=length;
}
}
|
O0
|
c
|
uf_blob:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x0, 0x4(%rax)
je 0xbdaf7
movq -0x10(%rbp), %rax
movl (%rax), %eax
movq -0x10(%rbp), %rdx
movl 0x4(%rdx), %ecx
addl $-0x1, %ecx
movl %ecx, 0x4(%rdx)
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
jne 0xbdb1b
jmp 0xbdb36
movq -0x10(%rbp), %rdi
callq 0xbc370
movq -0x10(%rbp), %rax
movl $0x1f, 0x4(%rax)
movq -0x10(%rbp), %rax
movl (%rax), %eax
andl $0x80000000, %eax # imm = 0x80000000
cmpl $0x0, %eax
je 0xbdb36
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rdx
movq -0x18(%rbp), %rax
subq %rax, %rdx
xorl %esi, %esi
callq 0x2a2c0
jmp 0xbdc35
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movq -0x8(%rbp), %rcx
cmpl 0x1c(%rcx), %eax
jb 0xbdb79
movq -0x10(%rbp), %rax
movl (%rax), %eax
movq -0x8(%rbp), %rcx
movl 0x1c(%rcx), %esi
movq -0x10(%rbp), %rdx
movl 0x4(%rdx), %ecx
subl %esi, %ecx
movl %ecx, 0x4(%rdx)
shrl %cl, %eax
movq -0x8(%rbp), %rcx
movl 0x1c(%rcx), %ecx
movl %ecx, %edx
leaq 0x201acf(%rip), %rcx # 0x2bf640
andl (%rcx,%rdx,4), %eax
movl %eax, -0x30(%rbp)
jmp 0xbdb8c
movq -0x10(%rbp), %rdi
movq -0x8(%rbp), %rax
movl 0x1c(%rax), %esi
callq 0xbab20
movl %eax, -0x30(%rbp)
movl -0x30(%rbp), %eax
movl %eax, %eax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
subq %rcx, %rax
subl $0x8, %eax
movl %eax, -0x2c(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
addq -0x28(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x20(%rcx), %rax
jbe 0xbdbdf
movq -0x10(%rbp), %rax
movl $0x1, 0x28(%rax)
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rdx
movq -0x18(%rbp), %rax
subq %rax, %rdx
xorl %esi, %esi
callq 0x2a2c0
jmp 0xbdc35
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rdx
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rcx
addq -0x28(%rbp), %rcx
callq 0xbca80
movq -0x18(%rbp), %rdi
movl -0x2c(%rbp), %esi
movq -0x28(%rbp), %rax
movl %eax, %edx
callq 0xab740
movq -0x18(%rbp), %rax
movl -0x2c(%rbp), %ecx
movq -0x10(%rbp), %rdx
movq 0x18(%rdx), %rdx
movq %rdx, (%rax,%rcx)
movq -0x28(%rbp), %rcx
movq -0x10(%rbp), %rax
addq 0x18(%rax), %rcx
movq %rcx, 0x18(%rax)
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
uf_blob_0:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rax, [rbp+var_10]
cmp dword ptr [rax+4], 0
jz short loc_BDAF7
mov rax, [rbp+var_10]
mov eax, [rax]
mov rdx, [rbp+var_10]
mov ecx, [rdx+4]
add ecx, 0FFFFFFFFh
mov [rdx+4], ecx
mov edx, 1
shl edx, cl
mov ecx, edx
and eax, ecx
cmp eax, 0
jnz short loc_BDB1B
jmp short loc_BDB36
loc_BDAF7:
mov rdi, [rbp+var_10]
call fill_buffer_0
mov rax, [rbp+var_10]
mov dword ptr [rax+4], 1Fh
mov rax, [rbp+var_10]
mov eax, [rax]
and eax, 80000000h
cmp eax, 0
jz short loc_BDB36
loc_BDB1B:
mov rdi, [rbp+var_18]
mov rdx, [rbp+var_20]
mov rax, [rbp+var_18]
sub rdx, rax
xor esi, esi
call _memset
jmp loc_BDC35
loc_BDB36:
mov rax, [rbp+var_10]
mov eax, [rax+4]
mov rcx, [rbp+var_8]
cmp eax, [rcx+1Ch]
jb short loc_BDB79
mov rax, [rbp+var_10]
mov eax, [rax]
mov rcx, [rbp+var_8]
mov esi, [rcx+1Ch]
mov rdx, [rbp+var_10]
mov ecx, [rdx+4]
sub ecx, esi
mov [rdx+4], ecx
shr eax, cl
mov rcx, [rbp+var_8]
mov ecx, [rcx+1Ch]
mov edx, ecx
lea rcx, mask_0
and eax, [rcx+rdx*4]
mov [rbp+var_30], eax
jmp short loc_BDB8C
loc_BDB79:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_8]
mov esi, [rax+1Ch]
call fill_and_get_bits_0
mov [rbp+var_30], eax
loc_BDB8C:
mov eax, [rbp+var_30]
mov eax, eax
mov [rbp+var_28], rax
mov rax, [rbp+var_20]
mov rcx, [rbp+var_18]
sub rax, rcx
sub eax, 8
mov [rbp+var_2C], eax
mov rax, [rbp+var_10]
mov rax, [rax+18h]
add rax, [rbp+var_28]
mov rcx, [rbp+var_10]
cmp rax, [rcx+20h]
jbe short loc_BDBDF
mov rax, [rbp+var_10]
mov dword ptr [rax+28h], 1
mov rdi, [rbp+var_18]
mov rdx, [rbp+var_20]
mov rax, [rbp+var_18]
sub rdx, rax
xor esi, esi
call _memset
jmp short loc_BDC35
loc_BDBDF:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rax, [rbp+var_10]
mov rdx, [rax+18h]
mov rax, [rbp+var_10]
mov rcx, [rax+18h]
add rcx, [rbp+var_28]
call decode_bytes_0
mov rdi, [rbp+var_18]
mov esi, [rbp+var_2C]
mov rax, [rbp+var_28]
mov edx, eax
call _mi_store_blob_length
mov rax, [rbp+var_18]
mov ecx, [rbp+var_2C]
mov rdx, [rbp+var_10]
mov rdx, [rdx+18h]
mov [rax+rcx], rdx
mov rcx, [rbp+var_28]
mov rax, [rbp+var_10]
add rcx, [rax+18h]
mov [rax+18h], rcx
loc_BDC35:
add rsp, 30h
pop rbp
retn
|
long long uf_blob_0(long long a1, long long a2, _BYTE *a3, long long a4)
{
int v4; // eax
int v5; // ecx
long long result; // rax
unsigned int v7; // eax
int v8; // ecx
unsigned int bits_0; // [rsp+0h] [rbp-30h]
unsigned int v10; // [rsp+4h] [rbp-2Ch]
if ( *(_DWORD *)(a2 + 4) )
{
v4 = *(_DWORD *)a2;
v5 = *(_DWORD *)(a2 + 4) - 1;
*(_DWORD *)(a2 + 4) = v5;
if ( ((1 << v5) & v4) == 0 )
goto LABEL_6;
return memset(a3, 0LL, a4 - (_QWORD)a3);
}
fill_buffer_0(a2);
*(_DWORD *)(a2 + 4) = 31;
if ( *(int *)a2 < 0 )
return memset(a3, 0LL, a4 - (_QWORD)a3);
LABEL_6:
if ( *(_DWORD *)(a2 + 4) < *(_DWORD *)(a1 + 28) )
{
bits_0 = fill_and_get_bits_0((_DWORD *)a2, *(_DWORD *)(a1 + 28));
}
else
{
v7 = *(_DWORD *)a2;
v8 = *(_DWORD *)(a2 + 4) - *(_DWORD *)(a1 + 28);
*(_DWORD *)(a2 + 4) = v8;
bits_0 = mask_0[*(unsigned int *)(a1 + 28)] & (v7 >> v8);
}
v10 = a4 - (_DWORD)a3 - 8;
if ( (unsigned long long)bits_0 + *(_QWORD *)(a2 + 24) <= *(_QWORD *)(a2 + 32) )
{
decode_bytes_0(a1, a2, *(_BYTE **)(a2 + 24), (_BYTE *)(bits_0 + *(_QWORD *)(a2 + 24)));
mi_store_blob_length(a3, v10, bits_0);
*(_QWORD *)&a3[v10] = *(_QWORD *)(a2 + 24);
result = a2;
*(_QWORD *)(a2 + 24) += bits_0;
}
else
{
*(_DWORD *)(a2 + 40) = 1;
return memset(a3, 0LL, a4 - (_QWORD)a3);
}
return result;
}
|
uf_blob:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x4],0x0
JZ 0x001bdaf7
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX]
MOV RDX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RDX + 0x4]
ADD ECX,-0x1
MOV dword ptr [RDX + 0x4],ECX
MOV EDX,0x1
SHL EDX,CL
MOV ECX,EDX
AND EAX,ECX
CMP EAX,0x0
JNZ 0x001bdb1b
JMP 0x001bdb36
LAB_001bdaf7:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001bc370
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x4],0x1f
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX]
AND EAX,0x80000000
CMP EAX,0x0
JZ 0x001bdb36
LAB_001bdb1b:
MOV RDI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x18]
SUB RDX,RAX
XOR ESI,ESI
CALL 0x0012a2c0
JMP 0x001bdc35
LAB_001bdb36:
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x4]
MOV RCX,qword ptr [RBP + -0x8]
CMP EAX,dword ptr [RCX + 0x1c]
JC 0x001bdb79
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX]
MOV RCX,qword ptr [RBP + -0x8]
MOV ESI,dword ptr [RCX + 0x1c]
MOV RDX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RDX + 0x4]
SUB ECX,ESI
MOV dword ptr [RDX + 0x4],ECX
SHR EAX,CL
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x1c]
MOV EDX,ECX
LEA RCX,[0x3bf640]
AND EAX,dword ptr [RCX + RDX*0x4]
MOV dword ptr [RBP + -0x30],EAX
JMP 0x001bdb8c
LAB_001bdb79:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV ESI,dword ptr [RAX + 0x1c]
CALL 0x001bab20
MOV dword ptr [RBP + -0x30],EAX
LAB_001bdb8c:
MOV EAX,dword ptr [RBP + -0x30]
MOV EAX,EAX
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x18]
SUB RAX,RCX
SUB EAX,0x8
MOV dword ptr [RBP + -0x2c],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x18]
ADD RAX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RCX + 0x20]
JBE 0x001bdbdf
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x28],0x1
MOV RDI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x18]
SUB RDX,RAX
XOR ESI,ESI
CALL 0x0012a2c0
JMP 0x001bdc35
LAB_001bdbdf:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RAX + 0x18]
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x18]
ADD RCX,qword ptr [RBP + -0x28]
CALL 0x001bca80
MOV RDI,qword ptr [RBP + -0x18]
MOV ESI,dword ptr [RBP + -0x2c]
MOV RAX,qword ptr [RBP + -0x28]
MOV EDX,EAX
CALL 0x001ab740
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0x2c]
MOV RDX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RDX + 0x18]
MOV qword ptr [RAX + RCX*0x1],RDX
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x10]
ADD RCX,qword ptr [RAX + 0x18]
MOV qword ptr [RAX + 0x18],RCX
LAB_001bdc35:
ADD RSP,0x30
POP RBP
RET
|
void uf_blob(long param_1,uint *param_2,void *param_3,long param_4)
{
uint uVar1;
ulong uVar2;
uint local_38;
if (param_2[1] == 0) {
fill_buffer(param_2);
param_2[1] = 0x1f;
uVar1 = *param_2 & 0x80000000;
}
else {
uVar1 = param_2[1];
param_2[1] = uVar1 - 1;
uVar1 = *param_2 & 1 << ((byte)(uVar1 - 1) & 0x1f);
}
if (uVar1 == 0) {
if (param_2[1] < *(uint *)(param_1 + 0x1c)) {
local_38 = fill_and_get_bits(param_2);
}
else {
uVar1 = param_2[1] - *(int *)(param_1 + 0x1c);
param_2[1] = uVar1;
local_38 = *param_2 >> ((byte)uVar1 & 0x1f) &
*(uint *)(mask + (ulong)*(uint *)(param_1 + 0x1c) * 4);
}
uVar2 = (ulong)local_38;
uVar1 = ((int)param_4 - (int)param_3) - 8;
if (*(ulong *)(param_2 + 8) < *(long *)(param_2 + 6) + uVar2) {
param_2[10] = 1;
memset(param_3,0,param_4 - (long)param_3);
}
else {
decode_bytes(param_1,param_2,*(int8 *)(param_2 + 6),*(long *)(param_2 + 6) + uVar2);
_mi_store_blob_length(param_3,uVar1,uVar2);
*(int8 *)((long)param_3 + (ulong)uVar1) = *(int8 *)(param_2 + 6);
*(ulong *)(param_2 + 6) = uVar2 + *(long *)(param_2 + 6);
}
}
else {
memset(param_3,0,param_4 - (long)param_3);
}
return;
}
|
|
64,804 |
ma_ft_del
|
eloqsql/storage/maria/ma_ft_update.c
|
int _ma_ft_del(MARIA_HA *info, uint keynr, uchar *keybuf, const uchar *record,
my_off_t pos)
{
int error= -1;
FT_WORD *wlist;
DBUG_ENTER("_ma_ft_del");
DBUG_PRINT("enter",("keynr: %d",keynr));
if ((wlist= _ma_ft_parserecord(info, keynr, record, &info->ft_memroot)))
error= _ma_ft_erase(info,keynr,keybuf,wlist,pos);
free_root(&info->ft_memroot, MYF(MY_MARK_BLOCKS_FREE));
DBUG_PRINT("exit",("Return: %d",error));
DBUG_RETURN(error);
}
|
O0
|
c
|
ma_ft_del:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movl $0xffffffff, -0x2c(%rbp) # imm = 0xFFFFFFFF
jmp 0x78444
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movq -0x20(%rbp), %rdx
movq -0x8(%rbp), %rcx
addq $0x328, %rcx # imm = 0x328
callq 0x77cb0
movq %rax, -0x38(%rbp)
cmpq $0x0, %rax
je 0x78484
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movq -0x18(%rbp), %rdx
movq -0x38(%rbp), %rcx
movq -0x28(%rbp), %r8
callq 0x78280
movl %eax, -0x2c(%rbp)
movq -0x8(%rbp), %rdi
addq $0x328, %rdi # imm = 0x328
movl $0x2, %esi
callq 0xed920
jmp 0x7849b
jmp 0x7849d
movl -0x2c(%rbp), %eax
movl %eax, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
|
_ma_ft_del:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov [rbp+var_2C], 0FFFFFFFFh
jmp short $+2
loc_78444:
mov rdi, [rbp+var_8]
mov esi, [rbp+var_C]
mov rdx, [rbp+var_20]
mov rcx, [rbp+var_8]
add rcx, 328h
call _ma_ft_parserecord
mov [rbp+var_38], rax
cmp rax, 0
jz short loc_78484
mov rdi, [rbp+var_8]
mov esi, [rbp+var_C]
mov rdx, [rbp+var_18]
mov rcx, [rbp+var_38]
mov r8, [rbp+var_28]
call _ma_ft_erase
mov [rbp+var_2C], eax
loc_78484:
mov rdi, [rbp+var_8]
add rdi, 328h
mov esi, 2
call free_root
jmp short $+2
loc_7849B:
jmp short $+2
loc_7849D:
mov eax, [rbp+var_2C]
mov [rbp+var_3C], eax
mov eax, [rbp+var_3C]
add rsp, 40h
pop rbp
retn
|
long long ma_ft_del(long long *a1, unsigned int a2, _BYTE *a3, long long a4, long long a5)
{
_QWORD *v6; // [rsp+8h] [rbp-38h]
unsigned int v7; // [rsp+14h] [rbp-2Ch]
v7 = -1;
v6 = (_QWORD *)ma_ft_parserecord(a1, a2, a4, (long long)(a1 + 101));
if ( v6 )
v7 = ma_ft_erase(a1, a2, a3, v6, a5);
free_root(a1 + 101, 2LL);
return v7;
}
|
_ma_ft_del:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV dword ptr [RBP + -0x2c],0xffffffff
JMP 0x00178444
LAB_00178444:
MOV RDI,qword ptr [RBP + -0x8]
MOV ESI,dword ptr [RBP + -0xc]
MOV RDX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x8]
ADD RCX,0x328
CALL 0x00177cb0
MOV qword ptr [RBP + -0x38],RAX
CMP RAX,0x0
JZ 0x00178484
MOV RDI,qword ptr [RBP + -0x8]
MOV ESI,dword ptr [RBP + -0xc]
MOV RDX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x38]
MOV R8,qword ptr [RBP + -0x28]
CALL 0x00178280
MOV dword ptr [RBP + -0x2c],EAX
LAB_00178484:
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x328
MOV ESI,0x2
CALL 0x001ed920
JMP 0x0017849b
LAB_0017849b:
JMP 0x0017849d
LAB_0017849d:
MOV EAX,dword ptr [RBP + -0x2c]
MOV dword ptr [RBP + -0x3c],EAX
MOV EAX,dword ptr [RBP + -0x3c]
ADD RSP,0x40
POP RBP
RET
|
int4
_ma_ft_del(long param_1,int4 param_2,int8 param_3,int8 param_4,int8 param_5)
{
long lVar1;
int4 local_34;
local_34 = 0xffffffff;
lVar1 = _ma_ft_parserecord(param_1,param_2,param_4,param_1 + 0x328);
if (lVar1 != 0) {
local_34 = _ma_ft_erase(param_1,param_2,param_3,lVar1,param_5);
}
free_root(param_1 + 0x328,2);
return local_34;
}
|
|
64,805 |
dequantize_row_q3_K
|
ngxson[P]ggml-easy/ggml/src/ggml-quants.c
|
void dequantize_row_q3_K(const block_q3_K * GGML_RESTRICT x, float * GGML_RESTRICT y, int64_t k) {
assert(k % QK_K == 0);
const int nb = k / QK_K;
const uint32_t kmask1 = 0x03030303;
const uint32_t kmask2 = 0x0f0f0f0f;
uint32_t aux[4];
const int8_t * scales = (const int8_t*)aux;
for (int i = 0; i < nb; i++) {
const float d_all = GGML_FP16_TO_FP32(x[i].d);
const uint8_t * GGML_RESTRICT q = x[i].qs;
const uint8_t * GGML_RESTRICT hm = x[i].hmask;
uint8_t m = 1;
memcpy(aux, x[i].scales, 12);
uint32_t tmp = aux[2];
aux[2] = ((aux[0] >> 4) & kmask2) | (((tmp >> 4) & kmask1) << 4);
aux[3] = ((aux[1] >> 4) & kmask2) | (((tmp >> 6) & kmask1) << 4);
aux[0] = (aux[0] & kmask2) | (((tmp >> 0) & kmask1) << 4);
aux[1] = (aux[1] & kmask2) | (((tmp >> 2) & kmask1) << 4);
int is = 0;
float dl;
for (int n = 0; n < QK_K; n += 128) {
int shift = 0;
for (int j = 0; j < 4; ++j) {
dl = d_all * (scales[is++] - 32);
for (int l = 0; l < 16; ++l) {
*y++ = dl * ((int8_t)((q[l+ 0] >> shift) & 3) - ((hm[l+ 0] & m) ? 0 : 4));
}
dl = d_all * (scales[is++] - 32);
for (int l = 0; l < 16; ++l) {
*y++ = dl * ((int8_t)((q[l+16] >> shift) & 3) - ((hm[l+16] & m) ? 0 : 4));
}
shift += 2;
m <<= 1;
}
q += 32;
}
}
}
|
O2
|
c
|
dequantize_row_q3_K:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %rax
movl $0x100, %ecx # imm = 0x100
cqto
idivq %rcx
xorl %edx, %edx
testl %eax, %eax
cmovlel %edx, %eax
movq %rax, -0x8(%rsp)
movabsq $0x10, %r10
movq %rdi, %rbx
cmpq -0x8(%rsp), %rdx
je 0x3286a
imulq $0x6e, %rdx, %r8
leaq (%rdi,%r8), %r14
movzwl 0x6c(%rdi,%r8), %ecx
movq 0x3a8ab(%rip), %rax # 0x6cfa8
movss (%rax,%rcx,4), %xmm0
movl 0x68(%rdi,%r8), %ecx
movl %ecx, -0x10(%rsp)
movq 0x60(%rdi,%r8), %r8
movq %r8, -0x18(%rsp)
movl %r8d, %r11d
shrl $0x4, %r11d
movl $0xf0f0f0f, %eax # imm = 0xF0F0F0F
andl %eax, %r11d
movl %ecx, %ebp
movl $0x30303030, %r9d # imm = 0x30303030
andl %r9d, %ebp
orl %r11d, %ebp
movl %ebp, -0x10(%rsp)
movl -0x14(%rsp), %r11d
movl %r11d, %ebp
shrl $0x4, %ebp
andl %eax, %ebp
movl %ecx, %r15d
shrl $0x2, %r15d
andl %r9d, %r15d
orl %ebp, %r15d
movl %r15d, -0xc(%rsp)
andl %eax, %r8d
movl %ecx, %ebp
shll $0x4, %ebp
andl %r9d, %ebp
orl %r8d, %ebp
movl %ebp, -0x18(%rsp)
andl %eax, %r11d
andl $0xc0c0c0c, %ecx # imm = 0xC0C0C0C
leal (%r11,%rcx,4), %ecx
movl %ecx, -0x14(%rsp)
xorl %r15d, %r15d
movb $0x1, %bpl
xorl %r12d, %r12d
cmpl $0xff, %r12d
ja 0x3285e
leaq 0x20(%r14), %r13
movslq %r15d, %r15
xorl %ecx, %ecx
xorl %r8d, %r8d
cmpl $0x4, %r8d
je 0x32852
movsbl -0x18(%rsp,%r15), %r11d
addl $-0x20, %r11d
cvtsi2ss %r11d, %xmm1
mulss %xmm0, %xmm1
xorl %r11d, %r11d
cmpq $0x10, %r11
je 0x327f2
movzbl 0x20(%r14,%r11), %eax
shrl %cl, %eax
andl $0x3, %eax
xorl %r9d, %r9d
testb %bpl, (%rbx,%r11)
setne %r9b
leal (%rax,%r9,4), %eax
addl $-0x4, %eax
cvtsi2ss %eax, %xmm2
mulss %xmm1, %xmm2
movss %xmm2, (%rsi)
addq $0x4, %rsi
incq %r11
jmp 0x327ba
movsbl -0x17(%rsp,%r15), %r11d
addl $-0x20, %r11d
cvtsi2ss %r11d, %xmm1
mulss %xmm0, %xmm1
movq %r10, %r11
cmpq $0x20, %r11
je 0x32840
movzbl 0x20(%r14,%r11), %eax
shrl %cl, %eax
andl $0x3, %eax
xorl %r9d, %r9d
testb %bpl, (%rbx,%r11)
setne %r9b
leal (%rax,%r9,4), %eax
addl $-0x4, %eax
cvtsi2ss %eax, %xmm2
mulss %xmm1, %xmm2
movss %xmm2, (%rsi)
addq $0x4, %rsi
incq %r11
jmp 0x32808
addq $0x2, %r15
addl $0x2, %ecx
addb %bpl, %bpl
incl %r8d
jmp 0x3279a
subl $-0x80, %r12d
movq %r13, %r14
jmp 0x32781
incq %rdx
addq $0x6e, %rbx
jmp 0x326dd
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
dequantize_row_q3_K:
push rbp
push r15
push r14
push r13
push r12
push rbx
mov rax, rdx
mov ecx, 100h
cqo
idiv rcx
xor edx, edx
test eax, eax
cmovle eax, edx
mov [rsp+30h+var_38], rax
mov r10, 10h
mov rbx, rdi
loc_326DD:
cmp rdx, [rsp+30h+var_38]
jz loc_3286A
imul r8, rdx, 6Eh ; 'n'
lea r14, [rdi+r8]
movzx ecx, word ptr [rdi+r8+6Ch]
mov rax, cs:ggml_table_f32_f16_ptr
movss xmm0, dword ptr [rax+rcx*4]
mov ecx, [rdi+r8+68h]
mov [rsp+30h+var_40], ecx
mov r8, [rdi+r8+60h]
mov [rsp+30h+var_48], r8
mov r11d, r8d
shr r11d, 4
mov eax, 0F0F0F0Fh
and r11d, eax
mov ebp, ecx
mov r9d, 30303030h
and ebp, r9d
or ebp, r11d
mov [rsp+30h+var_40], ebp
mov r11d, dword ptr [rsp+30h+var_48+4]
mov ebp, r11d
shr ebp, 4
and ebp, eax
mov r15d, ecx
shr r15d, 2
and r15d, r9d
or r15d, ebp
mov [rsp+30h+var_3C], r15d
and r8d, eax
mov ebp, ecx
shl ebp, 4
and ebp, r9d
or ebp, r8d
mov dword ptr [rsp+30h+var_48], ebp
and r11d, eax
and ecx, 0C0C0C0Ch
lea ecx, [r11+rcx*4]
mov dword ptr [rsp+30h+var_48+4], ecx
xor r15d, r15d
mov bpl, 1
xor r12d, r12d
loc_32781:
cmp r12d, 0FFh
ja loc_3285E
lea r13, [r14+20h]
movsxd r15, r15d
xor ecx, ecx
xor r8d, r8d
loc_3279A:
cmp r8d, 4
jz loc_32852
movsx r11d, byte ptr [rsp+r15+30h+var_48]
add r11d, 0FFFFFFE0h
cvtsi2ss xmm1, r11d
mulss xmm1, xmm0
xor r11d, r11d
loc_327BA:
cmp r11, 10h
jz short loc_327F2
movzx eax, byte ptr [r14+r11+20h]
shr eax, cl
and eax, 3
xor r9d, r9d
test [rbx+r11], bpl
setnz r9b
lea eax, [rax+r9*4]
add eax, 0FFFFFFFCh
cvtsi2ss xmm2, eax
mulss xmm2, xmm1
movss dword ptr [rsi], xmm2
add rsi, 4
inc r11
jmp short loc_327BA
loc_327F2:
movsx r11d, byte ptr [rsp+r15+30h+var_48+1]
add r11d, 0FFFFFFE0h
cvtsi2ss xmm1, r11d
mulss xmm1, xmm0
mov r11, r10
loc_32808:
cmp r11, 20h ; ' '
jz short loc_32840
movzx eax, byte ptr [r14+r11+20h]
shr eax, cl
and eax, 3
xor r9d, r9d
test [rbx+r11], bpl
setnz r9b
lea eax, [rax+r9*4]
add eax, 0FFFFFFFCh
cvtsi2ss xmm2, eax
mulss xmm2, xmm1
movss dword ptr [rsi], xmm2
add rsi, 4
inc r11
jmp short loc_32808
loc_32840:
add r15, 2
add ecx, 2
add bpl, bpl
inc r8d
jmp loc_3279A
loc_32852:
sub r12d, 0FFFFFF80h
mov r14, r13
jmp loc_32781
loc_3285E:
inc rdx
add rbx, 6Eh ; 'n'
jmp loc_326DD
loc_3286A:
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long dequantize_row_q3_K(long long a1, float *a2, long long a3)
{
long long result; // rax
long long v4; // rdx
long long v5; // rbx
long long v6; // r14
float v7; // xmm0_4
unsigned int v8; // ecx
long long v9; // r8
long long v10; // r15
char v11; // bp
unsigned int i; // r12d
char v13; // cl
int j; // r8d
float v15; // xmm1_4
long long k; // r11
float v17; // xmm1_4
long long m; // r11
_DWORD v19[2]; // [rsp+0h] [rbp-48h]
unsigned int v20; // [rsp+8h] [rbp-40h]
int v21; // [rsp+Ch] [rbp-3Ch]
long long v22; // [rsp+10h] [rbp-38h]
result = a3 / 256;
v4 = 0LL;
if ( (int)result <= 0 )
result = 0LL;
v22 = result;
v5 = a1;
while ( v4 != v22 )
{
v6 = a1 + 110 * v4;
v7 = ggml_table_f32_f16[*(unsigned __int16 *)(v6 + 108)];
v8 = *(_DWORD *)(v6 + 104);
v20 = v8;
v9 = *(_QWORD *)(v6 + 96);
result = 252645135LL;
v20 = ((unsigned int)v9 >> 4) & 0xF0F0F0F | v8 & 0x30303030;
v21 = (HIDWORD(v9) >> 4) & 0xF0F0F0F | (v8 >> 2) & 0x30303030;
v19[0] = v9 & 0xF0F0F0F | (16 * v8) & 0x30303030;
v19[1] = (HIDWORD(v9) & 0xF0F0F0F) + 4 * (v8 & 0xC0C0C0C);
LODWORD(v10) = 0;
v11 = 1;
for ( i = 0; i <= 0xFF; i += 128 )
{
v10 = (int)v10;
v13 = 0;
for ( j = 0; j != 4; ++j )
{
v15 = (float)(*((char *)v19 + v10) - 32) * v7;
for ( k = 0LL; k != 16; ++k )
{
result = ((*(unsigned __int8 *)(v6 + k + 32) >> v13) & 3)
+ 4 * (unsigned int)(((unsigned __int8)v11 & *(_BYTE *)(v5 + k)) != 0)
- 4;
*a2++ = (float)(int)result * v15;
}
v17 = (float)(*((char *)v19 + v10 + 1) - 32) * v7;
for ( m = 16LL; m != 32; ++m )
{
result = ((*(unsigned __int8 *)(v6 + m + 32) >> v13) & 3)
+ 4 * (unsigned int)(((unsigned __int8)v11 & *(_BYTE *)(v5 + m)) != 0)
- 4;
*a2++ = (float)(int)result * v17;
}
v10 += 2LL;
v13 += 2;
v11 *= 2;
}
v6 += 32LL;
}
++v4;
v5 += 110LL;
}
return result;
}
|
dequantize_row_q3_K:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV RAX,RDX
MOV ECX,0x100
CQO
IDIV RCX
XOR EDX,EDX
TEST EAX,EAX
CMOVLE EAX,EDX
MOV qword ptr [RSP + -0x8],RAX
MOV R10,0x10
MOV RBX,RDI
LAB_001326dd:
CMP RDX,qword ptr [RSP + -0x8]
JZ 0x0013286a
IMUL R8,RDX,0x6e
LEA R14,[RDI + R8*0x1]
MOVZX ECX,word ptr [RDI + R8*0x1 + 0x6c]
MOV RAX,qword ptr [0x0016cfa8]
MOVSS XMM0,dword ptr [RAX + RCX*0x4]
MOV ECX,dword ptr [RDI + R8*0x1 + 0x68]
MOV dword ptr [RSP + -0x10],ECX
MOV R8,qword ptr [RDI + R8*0x1 + 0x60]
MOV qword ptr [RSP + -0x18],R8
MOV R11D,R8D
SHR R11D,0x4
MOV EAX,0xf0f0f0f
AND R11D,EAX
MOV EBP,ECX
MOV R9D,0x30303030
AND EBP,R9D
OR EBP,R11D
MOV dword ptr [RSP + -0x10],EBP
MOV R11D,dword ptr [RSP + -0x14]
MOV EBP,R11D
SHR EBP,0x4
AND EBP,EAX
MOV R15D,ECX
SHR R15D,0x2
AND R15D,R9D
OR R15D,EBP
MOV dword ptr [RSP + -0xc],R15D
AND R8D,EAX
MOV EBP,ECX
SHL EBP,0x4
AND EBP,R9D
OR EBP,R8D
MOV dword ptr [RSP + -0x18],EBP
AND R11D,EAX
AND ECX,0xc0c0c0c
LEA ECX,[R11 + RCX*0x4]
MOV dword ptr [RSP + -0x14],ECX
XOR R15D,R15D
MOV BPL,0x1
XOR R12D,R12D
LAB_00132781:
CMP R12D,0xff
JA 0x0013285e
LEA R13,[R14 + 0x20]
MOVSXD R15,R15D
XOR ECX,ECX
XOR R8D,R8D
LAB_0013279a:
CMP R8D,0x4
JZ 0x00132852
MOVSX R11D,byte ptr [RSP + R15*0x1 + -0x18]
ADD R11D,-0x20
CVTSI2SS XMM1,R11D
MULSS XMM1,XMM0
XOR R11D,R11D
LAB_001327ba:
CMP R11,0x10
JZ 0x001327f2
MOVZX EAX,byte ptr [R14 + R11*0x1 + 0x20]
SHR EAX,CL
AND EAX,0x3
XOR R9D,R9D
TEST byte ptr [RBX + R11*0x1],BPL
SETNZ R9B
LEA EAX,[RAX + R9*0x4]
ADD EAX,-0x4
CVTSI2SS XMM2,EAX
MULSS XMM2,XMM1
MOVSS dword ptr [RSI],XMM2
ADD RSI,0x4
INC R11
JMP 0x001327ba
LAB_001327f2:
MOVSX R11D,byte ptr [RSP + R15*0x1 + -0x17]
ADD R11D,-0x20
CVTSI2SS XMM1,R11D
MULSS XMM1,XMM0
MOV R11,R10
LAB_00132808:
CMP R11,0x20
JZ 0x00132840
MOVZX EAX,byte ptr [R14 + R11*0x1 + 0x20]
SHR EAX,CL
AND EAX,0x3
XOR R9D,R9D
TEST byte ptr [RBX + R11*0x1],BPL
SETNZ R9B
LEA EAX,[RAX + R9*0x4]
ADD EAX,-0x4
CVTSI2SS XMM2,EAX
MULSS XMM2,XMM1
MOVSS dword ptr [RSI],XMM2
ADD RSI,0x4
INC R11
JMP 0x00132808
LAB_00132840:
ADD R15,0x2
ADD ECX,0x2
ADD BPL,BPL
INC R8D
JMP 0x0013279a
LAB_00132852:
SUB R12D,-0x80
MOV R14,R13
JMP 0x00132781
LAB_0013285e:
INC RDX
ADD RBX,0x6e
JMP 0x001326dd
LAB_0013286a:
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void dequantize_row_q3_K(long param_1,float *param_2,long param_3)
{
float fVar1;
char cVar2;
ulong uVar3;
byte bVar4;
ulong uVar5;
long lVar6;
byte bVar7;
int iVar8;
long lVar9;
long lVar10;
uint uVar11;
long lVar12;
int4 local_48;
uint uStack_44;
uint local_40;
uint local_3c;
ulong local_38;
uVar5 = 0;
local_38 = param_3 / 0x100 & 0xffffffff;
if ((int)(param_3 / 0x100) < 1) {
local_38 = uVar5;
}
lVar6 = param_1;
for (; uVar5 != local_38; uVar5 = uVar5 + 1) {
lVar9 = uVar5 * 0x6e;
fVar1 = *(float *)(PTR_ggml_table_f32_f16_0016cfa8 +
(ulong)*(ushort *)(param_1 + 0x6c + lVar9) * 4);
uVar11 = *(uint *)(param_1 + 0x68 + lVar9);
uVar3 = *(ulong *)(param_1 + 0x60 + lVar9);
local_40 = uVar11 & 0x30303030 | (uint)(uVar3 >> 4) & 0xf0f0f0f;
uStack_44 = (uint)(uVar3 >> 0x20);
local_3c = uVar11 >> 2 & 0x30303030 | uStack_44 >> 4 & 0xf0f0f0f;
_local_48 = CONCAT44((uStack_44 & 0xf0f0f0f) + (uVar11 & 0xc0c0c0c) * 4,
(uVar11 & 0x3030303) << 4 | (uint)uVar3 & 0xf0f0f0f);
lVar12 = 0;
bVar7 = 1;
lVar9 = param_1 + lVar9;
for (uVar11 = 0; uVar11 < 0x100; uVar11 = uVar11 + 0x80) {
lVar12 = (long)(int)lVar12;
bVar4 = 0;
for (iVar8 = 0; iVar8 != 4; iVar8 = iVar8 + 1) {
cVar2 = *(char *)((long)&local_48 + lVar12);
for (lVar10 = 0; lVar10 != 0x10; lVar10 = lVar10 + 1) {
*param_2 = (float)(int)((*(byte *)(lVar9 + 0x20 + lVar10) >> (bVar4 & 0x1f) & 3) +
(uint)((*(byte *)(lVar6 + lVar10) & bVar7) != 0) * 4 + -4) *
(float)(cVar2 + -0x20) * fVar1;
param_2 = param_2 + 1;
}
cVar2 = *(char *)((long)&local_48 + lVar12 + 1);
for (lVar10 = 0x10; lVar10 != 0x20; lVar10 = lVar10 + 1) {
*param_2 = (float)(int)((*(byte *)(lVar9 + 0x20 + lVar10) >> (bVar4 & 0x1f) & 3) +
(uint)((*(byte *)(lVar6 + lVar10) & bVar7) != 0) * 4 + -4) *
(float)(cVar2 + -0x20) * fVar1;
param_2 = param_2 + 1;
}
lVar12 = lVar12 + 2;
bVar4 = bVar4 + 2;
bVar7 = bVar7 * '\x02';
}
lVar9 = lVar9 + 0x20;
}
lVar6 = lVar6 + 0x6e;
}
return;
}
|
|
64,806 |
minja::error_location_suffix(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long)
|
llama.cpp/common/minja/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();
}
|
O3
|
cpp
|
minja::error_location_suffix(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1b8, %rsp # imm = 0x1B8
movq %rdx, %r8
movq %rsi, %r14
movq %rdi, 0x38(%rsp)
movq (%rsi), %rsi
movq 0x8(%r14), %rax
testq %rdx, %rdx
je 0x9e0ba
xorl %ecx, %ecx
xorl %r12d, %r12d
xorl %edx, %edx
cmpb $0xa, (%rsi,%rcx)
sete %dl
addq %rdx, %r12
incq %rcx
cmpq %rcx, %r8
jne 0x9e0a4
jmp 0x9e0bd
xorl %r12d, %r12d
leaq (%rsi,%r8), %rdx
testq %rax, %rax
movq %r8, 0x28(%rsp)
je 0x9e0e7
xorl %ecx, %ecx
xorl %r15d, %r15d
xorl %edi, %edi
cmpb $0xa, (%rsi,%rcx)
sete %dil
addq %rdi, %r15
incq %rcx
cmpq %rcx, %rax
jne 0x9e0d0
jmp 0x9e0ea
xorl %r15d, %r15d
leaq 0x50(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq $0x0, -0x8(%rbp)
leaq 0x40(%rsp), %rbx
movq %rbx, %rdi
callq 0x723cc
movq %rbx, %rdi
movl $0xa, %esi
movq $-0x1, %rdx
callq 0x20710
movq %rax, %r13
movq (%rbx), %rdi
cmpq %rbp, %rdi
je 0x9e134
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x20180
leaq 0x40(%rsp), %rbx
movq %rbx, %rdi
callq 0x21010
leaq 0x823a2(%rip), %rsi # 0x1204ea
movl $0x8, %edx
movq %rbx, %rdi
callq 0x21070
movq 0x28(%rsp), %rbx
leaq 0x1(%r12), %rsi
leaq 0x40(%rsp), %rdi
movq %rsi, 0x30(%rsp)
callq 0x20630
movq %rax, %rbp
leaq 0x7ceb5(%rip), %rsi # 0x11b02d
movl $0x9, %edx
movq %rax, %rdi
callq 0x21070
subq %r13, %rbx
movq %rbp, %rdi
movq %rbx, %rsi
callq 0x20870
leaq 0x87b98(%rip), %rsi # 0x125d32
movl $0x2, %edx
movq %rax, %rdi
callq 0x21070
testq %r12, %r12
jle 0x9e25e
movq (%r14), %r13
cmpq $0x1, %r12
jne 0x9e1be
movq %r13, %rsi
jmp 0x9e1ea
leaq -0x1(%r12), %rbp
movq (%r14), %rsi
addq 0x8(%r14), %rsi
movb $0xa, 0x7(%rsp)
movq %r13, %rdi
leaq 0x7(%rsp), %rdx
callq 0xcd4a9
movq %rax, %r13
incq %r13
decq %rbp
jne 0x9e1c3
movq (%r14), %rsi
addq 0x8(%r14), %rsi
leaq 0x7(%rsp), %rdx
movb $0xa, (%rdx)
movq %r13, %rdi
callq 0xcd4a9
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq $0x0, -0x8(%rbp)
leaq 0x8(%rsp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x723cc
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0x21070
leaq 0x81be6(%rip), %rsi # 0x11fe20
movl $0x1, %edx
movq %rax, %rdi
callq 0x21070
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x9e25e
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x20180
movq (%r14), %r13
cmpq $0x2, 0x30(%rsp)
jb 0x9e2a2
movq %rbx, 0x28(%rsp)
leaq 0x7(%rsp), %rbp
movq %r12, %rbx
movq (%r14), %rsi
addq 0x8(%r14), %rsi
movb $0xa, 0x7(%rsp)
movq %r13, %rdi
movq %rbp, %rdx
callq 0xcd4a9
movq %rax, %r13
incq %r13
decq %rbx
jne 0x9e276
movq (%r14), %rsi
movq 0x28(%rsp), %rbx
jmp 0x9e2a5
movq %r13, %rsi
addq 0x8(%r14), %rsi
leaq 0x7(%rsp), %rdx
movb $0xa, (%rdx)
movq %r13, %rdi
callq 0xcd4a9
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq $0x0, -0x8(%rbp)
leaq 0x8(%rsp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x723cc
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0x21070
leaq 0x81b2b(%rip), %rsi # 0x11fe20
movl $0x1, %edx
movq %rax, %rdi
callq 0x21070
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x9e319
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x20180
decq %rbx
leaq 0x8(%rsp), %rdi
movq %rbp, (%rdi)
movq %rbx, %rsi
movl $0x20, %edx
callq 0x209e0
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0x21070
leaq 0x821a7(%rip), %rsi # 0x1204f3
movl $0x2, %edx
movq %rax, %rdi
callq 0x21070
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x9e370
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x20180
cmpq %r15, %r12
jge 0x9e424
movq (%r14), %r15
cmpq $-0x3, %r12
ja 0x9e3b3
leaq 0x7(%rsp), %r13
movq 0x30(%rsp), %rbx
movq (%r14), %rsi
addq 0x8(%r14), %rsi
movb $0xa, 0x7(%rsp)
movq %r15, %rdi
movq %r13, %rdx
callq 0xcd4a9
movq %rax, %r15
incq %r15
decq %rbx
jne 0x9e38c
movq (%r14), %rsi
jmp 0x9e3b6
movq %r15, %rsi
addq 0x8(%r14), %rsi
leaq 0x7(%rsp), %rdx
movb $0xa, (%rdx)
movq %r15, %rdi
callq 0xcd4a9
leaq 0x8(%rsp), %rdi
movq %rbp, (%rdi)
movq $0x0, 0x8(%rdi)
movq %r15, %rsi
movq %rax, %rdx
callq 0x723cc
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0x21070
leaq 0x81a20(%rip), %rsi # 0x11fe20
movl $0x1, %edx
movq %rax, %rdi
callq 0x21070
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x9e424
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x20180
leaq 0x48(%rsp), %rsi
movq 0x38(%rsp), %rdi
callq 0x20660
movq 0xc4b1e(%rip), %rsi # 0x162f58
leaq 0x40(%rsp), %rdi
callq 0x20c80
leaq 0xb0(%rsp), %rdi
callq 0x20c50
addq $0x1b8, %rsp # imm = 0x1B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x9e48d
jmp 0x9e48d
jmp 0x9e471
jmp 0x9e48d
jmp 0x9e48d
jmp 0x9e471
jmp 0x9e471
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x9e490
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x20180
jmp 0x9e490
movq %rax, %rbx
movq 0xc4ac1(%rip), %rsi # 0x162f58
leaq 0x40(%rsp), %rdi
callq 0x20c80
leaq 0xb0(%rsp), %rdi
callq 0x20c50
movq %rbx, %rdi
callq 0x20b00
|
_ZN5minjaL21error_location_suffixERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEm:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 1B8h
mov r8, rdx
mov r14, rsi
mov [rsp+1E8h+var_1B0], rdi
mov rsi, [rsi]
mov rax, [r14+8]
test rdx, rdx
jz short loc_9E0BA
xor ecx, ecx
xor r12d, r12d
loc_9E0A4:
xor edx, edx
cmp byte ptr [rsi+rcx], 0Ah
setz dl
add r12, rdx
inc rcx
cmp r8, rcx
jnz short loc_9E0A4
jmp short loc_9E0BD
loc_9E0BA:
xor r12d, r12d
loc_9E0BD:
lea rdx, [rsi+r8]
test rax, rax
mov [rsp+1E8h+var_1C0], r8
jz short loc_9E0E7
xor ecx, ecx
xor r15d, r15d
loc_9E0D0:
xor edi, edi
cmp byte ptr [rsi+rcx], 0Ah
setz dil
add r15, rdi
inc rcx
cmp rax, rcx
jnz short loc_9E0D0
jmp short loc_9E0EA
loc_9E0E7:
xor r15d, r15d
loc_9E0EA:
lea rbp, [rsp+1E8h+var_198]
mov [rbp-10h], rbp
mov qword ptr [rbp-8], 0
lea rbx, [rsp+1E8h+var_1A8]
mov rdi, rbx
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIN9__gnu_cxx17__normal_iteratorIPKcS4_EEEEvT_SB_St20forward_iterator_tag; std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::forward_iterator_tag)
mov rdi, rbx
mov esi, 0Ah
mov rdx, 0FFFFFFFFFFFFFFFFh
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5rfindEcm; std::string::rfind(char,ulong)
mov r13, rax
mov rdi, [rbx]; void *
cmp rdi, rbp
jz short loc_9E134
mov rsi, [rsp+1E8h+var_198]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_9E134:
lea rbx, [rsp+1E8h+var_1A8]
mov rdi, rbx
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::ostringstream::basic_ostringstream(void)
lea rsi, aAtRow; " at row "
mov edx, 8
mov rdi, rbx
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rbx, [rsp+1E8h+var_1C0]
lea rsi, [r12+1]
lea rdi, [rsp+1E8h+var_1A8]
mov [rsp+1E8h+var_1B8], rsi
call __ZNSo9_M_insertIlEERSoT_; std::ostream::_M_insert<long>(long)
mov rbp, rax
lea rsi, aColumn; ", column "
mov edx, 9
mov rdi, rax
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
sub rbx, r13
mov rdi, rbp
mov rsi, rbx
call __ZNSo9_M_insertImEERSoT_; std::ostream::_M_insert<ulong>(ulong)
lea rsi, aJsonSchemaConv+1Dh; ":\n"
mov edx, 2
mov rdi, rax
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
test r12, r12
jle loc_9E25E
mov r13, [r14]
cmp r12, 1
jnz short loc_9E1BE
mov rsi, r13
jmp short loc_9E1EA
loc_9E1BE:
lea rbp, [r12-1]
loc_9E1C3:
mov rsi, [r14]
add rsi, [r14+8]
mov [rsp+1E8h+var_1E1], 0Ah
mov rdi, r13
lea rdx, [rsp+1E8h+var_1E1]
call _ZSt9__find_ifIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEENS0_5__ops16_Iter_equals_valIS2_EEET_SE_SE_T0_St26random_access_iterator_tag; std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>,std::random_access_iterator_tag)
mov r13, rax
inc r13
dec rbp
jnz short loc_9E1C3
mov rsi, [r14]
loc_9E1EA:
add rsi, [r14+8]
lea rdx, [rsp+1E8h+var_1E1]
mov byte ptr [rdx], 0Ah
mov rdi, r13
call _ZSt9__find_ifIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEENS0_5__ops16_Iter_equals_valIS2_EEET_SE_SE_T0_St26random_access_iterator_tag; std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>,std::random_access_iterator_tag)
lea rbp, [rsp+1E8h+var_1D0]
mov [rbp-10h], rbp
mov qword ptr [rbp-8], 0
lea rdi, [rsp+1E8h+var_1E0]
mov rsi, r13
mov rdx, rax
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIN9__gnu_cxx17__normal_iteratorIPKcS4_EEEEvT_SB_St20forward_iterator_tag; std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::forward_iterator_tag)
mov rsi, [rsp+1E8h+var_1E0]
mov rdx, [rsp+1E8h+var_1D8]
lea rdi, [rsp+1E8h+var_1A8]
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
lea rsi, aExampleToolCal+1Ch; "\n"
mov edx, 1
mov rdi, rax
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rdi, [rsp+1E8h+var_1E0]; void *
cmp rdi, rbp
jz short loc_9E25E
mov rsi, [rsp+1E8h+var_1D0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_9E25E:
mov r13, [r14]
cmp [rsp+1E8h+var_1B8], 2
jb short loc_9E2A2
mov [rsp+1E8h+var_1C0], rbx
lea rbp, [rsp+1E8h+var_1E1]
mov rbx, r12
loc_9E276:
mov rsi, [r14]
add rsi, [r14+8]
mov [rsp+1E8h+var_1E1], 0Ah
mov rdi, r13
mov rdx, rbp
call _ZSt9__find_ifIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEENS0_5__ops16_Iter_equals_valIS2_EEET_SE_SE_T0_St26random_access_iterator_tag; std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>,std::random_access_iterator_tag)
mov r13, rax
inc r13
dec rbx
jnz short loc_9E276
mov rsi, [r14]
mov rbx, [rsp+1E8h+var_1C0]
jmp short loc_9E2A5
loc_9E2A2:
mov rsi, r13
loc_9E2A5:
add rsi, [r14+8]
lea rdx, [rsp+1E8h+var_1E1]
mov byte ptr [rdx], 0Ah
mov rdi, r13
call _ZSt9__find_ifIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEENS0_5__ops16_Iter_equals_valIS2_EEET_SE_SE_T0_St26random_access_iterator_tag; std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>,std::random_access_iterator_tag)
lea rbp, [rsp+1E8h+var_1D0]
mov [rbp-10h], rbp
mov qword ptr [rbp-8], 0
lea rdi, [rsp+1E8h+var_1E0]
mov rsi, r13
mov rdx, rax
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIN9__gnu_cxx17__normal_iteratorIPKcS4_EEEEvT_SB_St20forward_iterator_tag; std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::forward_iterator_tag)
mov rsi, [rsp+1E8h+var_1E0]
mov rdx, [rsp+1E8h+var_1D8]
lea rdi, [rsp+1E8h+var_1A8]
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
lea rsi, aExampleToolCal+1Ch; "\n"
mov edx, 1
mov rdi, rax
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rdi, [rsp+1E8h+var_1E0]; void *
cmp rdi, rbp
jz short loc_9E319
mov rsi, [rsp+1E8h+var_1D0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_9E319:
dec rbx
lea rdi, [rsp+1E8h+var_1E0]
mov [rdi], rbp
mov rsi, rbx
mov edx, 20h ; ' '
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructEmc; std::string::_M_construct(ulong,char)
mov rsi, [rsp+1E8h+var_1E0]
mov rdx, [rsp+1E8h+var_1D8]
lea rdi, [rsp+1E8h+var_1A8]
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
lea rsi, asc_1204F3; "^\n"
mov edx, 2
mov rdi, rax
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rdi, [rsp+1E8h+var_1E0]; void *
cmp rdi, rbp
jz short loc_9E370
mov rsi, [rsp+1E8h+var_1D0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_9E370:
cmp r12, r15
jge loc_9E424
mov r15, [r14]
cmp r12, 0FFFFFFFFFFFFFFFDh
ja short loc_9E3B3
lea r13, [rsp+1E8h+var_1E1]
mov rbx, [rsp+1E8h+var_1B8]
loc_9E38C:
mov rsi, [r14]
add rsi, [r14+8]
mov [rsp+1E8h+var_1E1], 0Ah
mov rdi, r15
mov rdx, r13
call _ZSt9__find_ifIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEENS0_5__ops16_Iter_equals_valIS2_EEET_SE_SE_T0_St26random_access_iterator_tag; std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>,std::random_access_iterator_tag)
mov r15, rax
inc r15
dec rbx
jnz short loc_9E38C
mov rsi, [r14]
jmp short loc_9E3B6
loc_9E3B3:
mov rsi, r15
loc_9E3B6:
add rsi, [r14+8]
lea rdx, [rsp+1E8h+var_1E1]
mov byte ptr [rdx], 0Ah
mov rdi, r15
call _ZSt9__find_ifIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEENS0_5__ops16_Iter_equals_valIS2_EEET_SE_SE_T0_St26random_access_iterator_tag; std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>,std::random_access_iterator_tag)
lea rdi, [rsp+1E8h+var_1E0]
mov [rdi], rbp
mov qword ptr [rdi+8], 0
mov rsi, r15
mov rdx, rax
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIN9__gnu_cxx17__normal_iteratorIPKcS4_EEEEvT_SB_St20forward_iterator_tag; std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::forward_iterator_tag)
mov rsi, [rsp+1E8h+var_1E0]
mov rdx, [rsp+1E8h+var_1D8]
lea rdi, [rsp+1E8h+var_1A8]
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
lea rsi, aExampleToolCal+1Ch; "\n"
mov edx, 1
mov rdi, rax
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rdi, [rsp+1E8h+var_1E0]; void *
cmp rdi, rbp
jz short loc_9E424
mov rsi, [rsp+1E8h+var_1D0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_9E424:
lea rsi, [rsp+1E8h+var_1A0]
mov rdi, [rsp+1E8h+var_1B0]
call __ZNKSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void)
mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+1E8h+var_1A8]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream()
lea rdi, [rsp+1E8h+var_138]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
add rsp, 1B8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_9E48D
jmp short loc_9E48D
jmp short loc_9E471
jmp short loc_9E48D
jmp short loc_9E48D
jmp short loc_9E471
jmp short $+2
loc_9E471:
mov rbx, rax
mov rdi, [rsp+arg_0]; void *
cmp rdi, rbp
jz short loc_9E490
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_9E490
loc_9E48D:
mov rbx, rax
loc_9E490:
mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+arg_38]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream()
lea rdi, [rsp+arg_A8]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
mov rdi, rbx
call __Unwind_Resume
|
void minja::error_location_suffix(long long a1, long long a2, long long a3)
{
_BYTE *v4; // rsi
long long v5; // rax
long long v6; // rcx
long long v7; // r12
long long v8; // rcx
long long v9; // r15
long long v10; // r13
long long v11; // rbp
long long v12; // rbx
long long v13; // rax
_BYTE *v14; // r13
_BYTE *v15; // rsi
long long v16; // rbp
long long v17; // rsi
_BYTE *v18; // rsi
long long v19; // rax
long long v20; // rax
_BYTE *v21; // r13
long long v22; // rbx
long long v23; // rsi
_BYTE *v24; // rsi
_BYTE *v25; // rsi
long long v26; // rax
long long v27; // rax
long long v28; // rax
_BYTE *v29; // r15
unsigned long long v30; // rbx
long long v31; // rsi
_BYTE *v32; // rsi
_BYTE *v33; // rsi
long long v34; // rax
long long v35; // rax
char v36; // [rsp+7h] [rbp-1E1h] BYREF
void *v37; // [rsp+8h] [rbp-1E0h] BYREF
long long v38; // [rsp+10h] [rbp-1D8h]
_QWORD v39[2]; // [rsp+18h] [rbp-1D0h] BYREF
long long v40; // [rsp+28h] [rbp-1C0h]
unsigned long long v41; // [rsp+30h] [rbp-1B8h]
long long v42; // [rsp+38h] [rbp-1B0h]
_QWORD *v43; // [rsp+40h] [rbp-1A8h] BYREF
long long v44; // [rsp+48h] [rbp-1A0h] BYREF
_QWORD v45[12]; // [rsp+50h] [rbp-198h] BYREF
char v46[312]; // [rsp+B0h] [rbp-138h] BYREF
v42 = a1;
v4 = *(_BYTE **)a2;
v5 = *(_QWORD *)(a2 + 8);
if ( a3 )
{
v6 = 0LL;
v7 = 0LL;
do
v7 += v4[v6++] == 10;
while ( a3 != v6 );
}
else
{
v7 = 0LL;
}
v40 = a3;
if ( v5 )
{
v8 = 0LL;
v9 = 0LL;
do
v9 += v4[v8++] == 10;
while ( v5 != v8 );
}
else
{
v9 = 0LL;
}
v43 = v45;
v44 = 0LL;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>((long long)&v43, v4, (long long)&v4[a3]);
v10 = std::string::rfind(&v43, 10LL, -1LL);
if ( v43 != v45 )
operator delete(v43, v45[0] + 1LL);
std::ostringstream::basic_ostringstream(&v43);
std::__ostream_insert<char,std::char_traits<char>>(&v43, " at row ", 8LL);
v41 = v7 + 1;
v11 = std::ostream::_M_insert<long>(&v43);
std::__ostream_insert<char,std::char_traits<char>>(v11, ", column ", 9LL);
v12 = v40 - v10;
v13 = std::ostream::_M_insert<unsigned long>(v11, v40 - v10);
std::__ostream_insert<char,std::char_traits<char>>(v13, ":\n", 2LL);
if ( v7 > 0 )
{
v14 = *(_BYTE **)a2;
if ( v7 == 1 )
{
v15 = *(_BYTE **)a2;
}
else
{
v16 = v7 - 1;
do
{
v17 = *(_QWORD *)(a2 + 8) + *(_QWORD *)a2;
v36 = 10;
v14 = (_BYTE *)(std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(
v14,
v17,
&v36)
+ 1);
--v16;
}
while ( v16 );
v15 = *(_BYTE **)a2;
}
v18 = &v15[*(_QWORD *)(a2 + 8)];
v36 = 10;
v19 = std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(
v14,
v18,
&v36);
v37 = v39;
v38 = 0LL;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>((long long)&v37, v14, v19);
v20 = std::__ostream_insert<char,std::char_traits<char>>(&v43, v37, v38);
std::__ostream_insert<char,std::char_traits<char>>(v20, "\n", 1LL);
if ( v37 != v39 )
operator delete(v37, v39[0] + 1LL);
}
v21 = *(_BYTE **)a2;
if ( v41 < 2 )
{
v24 = *(_BYTE **)a2;
}
else
{
v40 = v12;
v22 = v7;
do
{
v23 = *(_QWORD *)(a2 + 8) + *(_QWORD *)a2;
v36 = 10;
v21 = (_BYTE *)(std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(
v21,
v23,
&v36)
+ 1);
--v22;
}
while ( v22 );
v24 = *(_BYTE **)a2;
v12 = v40;
}
v25 = &v24[*(_QWORD *)(a2 + 8)];
v36 = 10;
v26 = std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(
v21,
v25,
&v36);
v37 = v39;
v38 = 0LL;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>((long long)&v37, v21, v26);
v27 = std::__ostream_insert<char,std::char_traits<char>>(&v43, v37, v38);
std::__ostream_insert<char,std::char_traits<char>>(v27, "\n", 1LL);
if ( v37 != v39 )
operator delete(v37, v39[0] + 1LL);
v37 = v39;
std::string::_M_construct(&v37, v12 - 1, 32LL);
v28 = std::__ostream_insert<char,std::char_traits<char>>(&v43, v37, v38);
std::__ostream_insert<char,std::char_traits<char>>(v28, "^\n", 2LL);
if ( v37 != v39 )
operator delete(v37, v39[0] + 1LL);
if ( v7 < v9 )
{
v29 = *(_BYTE **)a2;
if ( (unsigned long long)v7 > 0xFFFFFFFFFFFFFFFDLL )
{
v32 = *(_BYTE **)a2;
}
else
{
v30 = v41;
do
{
v31 = *(_QWORD *)(a2 + 8) + *(_QWORD *)a2;
v36 = 10;
v29 = (_BYTE *)(std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(
v29,
v31,
&v36)
+ 1);
--v30;
}
while ( v30 );
v32 = *(_BYTE **)a2;
}
v33 = &v32[*(_QWORD *)(a2 + 8)];
v36 = 10;
v34 = std::__find_if<__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__ops::_Iter_equals_val<char const>>(
v29,
v33,
&v36);
v37 = v39;
v38 = 0LL;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>((long long)&v37, v29, v34);
v35 = std::__ostream_insert<char,std::char_traits<char>>(&v43, v37, v38);
std::__ostream_insert<char,std::char_traits<char>>(v35, "\n", 1LL);
if ( v37 != v39 )
operator delete(v37, v39[0] + 1LL);
}
std::stringbuf::str(v42, &v44);
std::ostringstream::~ostringstream(&v43, &`VTT for'std::ostringstream);
std::ios_base::~ios_base((std::ios_base *)v46);
}
|
error_location_suffix:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x1b8
MOV R8,RDX
MOV R14,RSI
MOV qword ptr [RSP + 0x38],RDI
MOV RSI,qword ptr [RSI]
MOV RAX,qword ptr [R14 + 0x8]
TEST RDX,RDX
JZ 0x0019e0ba
XOR ECX,ECX
XOR R12D,R12D
LAB_0019e0a4:
XOR EDX,EDX
CMP byte ptr [RSI + RCX*0x1],0xa
SETZ DL
ADD R12,RDX
INC RCX
CMP R8,RCX
JNZ 0x0019e0a4
JMP 0x0019e0bd
LAB_0019e0ba:
XOR R12D,R12D
LAB_0019e0bd:
LEA RDX,[RSI + R8*0x1]
TEST RAX,RAX
MOV qword ptr [RSP + 0x28],R8
JZ 0x0019e0e7
XOR ECX,ECX
XOR R15D,R15D
LAB_0019e0d0:
XOR EDI,EDI
CMP byte ptr [RSI + RCX*0x1],0xa
SETZ DIL
ADD R15,RDI
INC RCX
CMP RAX,RCX
JNZ 0x0019e0d0
JMP 0x0019e0ea
LAB_0019e0e7:
XOR R15D,R15D
LAB_0019e0ea:
LEA RBP,[RSP + 0x50]
MOV qword ptr [RBP + -0x10],RBP
MOV qword ptr [RBP + -0x8],0x0
LEA RBX,[RSP + 0x40]
MOV RDI,RBX
CALL 0x001723cc
MOV RDI,RBX
MOV ESI,0xa
MOV RDX,-0x1
CALL 0x00120710
MOV R13,RAX
MOV RDI,qword ptr [RBX]
CMP RDI,RBP
JZ 0x0019e134
MOV RSI,qword ptr [RSP + 0x50]
INC RSI
CALL 0x00120180
LAB_0019e134:
LEA RBX,[RSP + 0x40]
MOV RDI,RBX
CALL 0x00121010
LAB_0019e141:
LEA RSI,[0x2204ea]
MOV EDX,0x8
MOV RDI,RBX
CALL 0x00121070
MOV RBX,qword ptr [RSP + 0x28]
LEA RSI,[R12 + 0x1]
LEA RDI,[RSP + 0x40]
MOV qword ptr [RSP + 0x30],RSI
CALL 0x00120630
MOV RBP,RAX
LEA RSI,[0x21b02d]
MOV EDX,0x9
MOV RDI,RAX
CALL 0x00121070
SUB RBX,R13
MOV RDI,RBP
MOV RSI,RBX
CALL 0x00120870
LEA RSI,[0x225d32]
MOV EDX,0x2
MOV RDI,RAX
CALL 0x00121070
TEST R12,R12
JLE 0x0019e25e
MOV R13,qword ptr [R14]
CMP R12,0x1
JNZ 0x0019e1be
MOV RSI,R13
JMP 0x0019e1ea
LAB_0019e1be:
LEA RBP,[R12 + -0x1]
LAB_0019e1c3:
MOV RSI,qword ptr [R14]
ADD RSI,qword ptr [R14 + 0x8]
MOV byte ptr [RSP + 0x7],0xa
MOV RDI,R13
LEA RDX,[RSP + 0x7]
CALL 0x001cd4a9
MOV R13,RAX
INC R13
DEC RBP
JNZ 0x0019e1c3
MOV RSI,qword ptr [R14]
LAB_0019e1ea:
ADD RSI,qword ptr [R14 + 0x8]
LEA RDX,[RSP + 0x7]
MOV byte ptr [RDX],0xa
MOV RDI,R13
CALL 0x001cd4a9
LEA RBP,[RSP + 0x18]
MOV qword ptr [RBP + -0x10],RBP
MOV qword ptr [RBP + -0x8],0x0
LAB_0019e20f:
LEA RDI,[RSP + 0x8]
MOV RSI,R13
MOV RDX,RAX
CALL 0x001723cc
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
LAB_0019e229:
LEA RDI,[RSP + 0x40]
CALL 0x00121070
LEA RSI,[0x21fe20]
MOV EDX,0x1
MOV RDI,RAX
CALL 0x00121070
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x0019e25e
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x00120180
LAB_0019e25e:
MOV R13,qword ptr [R14]
CMP qword ptr [RSP + 0x30],0x2
JC 0x0019e2a2
MOV qword ptr [RSP + 0x28],RBX
LEA RBP,[RSP + 0x7]
MOV RBX,R12
LAB_0019e276:
MOV RSI,qword ptr [R14]
ADD RSI,qword ptr [R14 + 0x8]
MOV byte ptr [RSP + 0x7],0xa
MOV RDI,R13
MOV RDX,RBP
CALL 0x001cd4a9
MOV R13,RAX
INC R13
DEC RBX
JNZ 0x0019e276
MOV RSI,qword ptr [R14]
MOV RBX,qword ptr [RSP + 0x28]
JMP 0x0019e2a5
LAB_0019e2a2:
MOV RSI,R13
LAB_0019e2a5:
ADD RSI,qword ptr [R14 + 0x8]
LEA RDX,[RSP + 0x7]
MOV byte ptr [RDX],0xa
MOV RDI,R13
CALL 0x001cd4a9
LEA RBP,[RSP + 0x18]
MOV qword ptr [RBP + -0x10],RBP
MOV qword ptr [RBP + -0x8],0x0
LAB_0019e2ca:
LEA RDI,[RSP + 0x8]
MOV RSI,R13
MOV RDX,RAX
CALL 0x001723cc
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
LAB_0019e2e4:
LEA RDI,[RSP + 0x40]
CALL 0x00121070
LEA RSI,[0x21fe20]
MOV EDX,0x1
MOV RDI,RAX
CALL 0x00121070
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x0019e319
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x00120180
LAB_0019e319:
DEC RBX
LEA RDI,[RSP + 0x8]
MOV qword ptr [RDI],RBP
LAB_0019e324:
MOV RSI,RBX
MOV EDX,0x20
CALL 0x001209e0
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
LAB_0019e33b:
LEA RDI,[RSP + 0x40]
CALL 0x00121070
LEA RSI,[0x2204f3]
MOV EDX,0x2
MOV RDI,RAX
CALL 0x00121070
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x0019e370
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x00120180
LAB_0019e370:
CMP R12,R15
JGE 0x0019e424
MOV R15,qword ptr [R14]
CMP R12,-0x3
JA 0x0019e3b3
LEA R13,[RSP + 0x7]
MOV RBX,qword ptr [RSP + 0x30]
LAB_0019e38c:
MOV RSI,qword ptr [R14]
ADD RSI,qword ptr [R14 + 0x8]
MOV byte ptr [RSP + 0x7],0xa
MOV RDI,R15
MOV RDX,R13
CALL 0x001cd4a9
MOV R15,RAX
INC R15
DEC RBX
JNZ 0x0019e38c
MOV RSI,qword ptr [R14]
JMP 0x0019e3b6
LAB_0019e3b3:
MOV RSI,R15
LAB_0019e3b6:
ADD RSI,qword ptr [R14 + 0x8]
LEA RDX,[RSP + 0x7]
MOV byte ptr [RDX],0xa
MOV RDI,R15
CALL 0x001cd4a9
LEA RDI,[RSP + 0x8]
MOV qword ptr [RDI],RBP
MOV qword ptr [RDI + 0x8],0x0
LAB_0019e3da:
MOV RSI,R15
MOV RDX,RAX
CALL 0x001723cc
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
LAB_0019e3ef:
LEA RDI,[RSP + 0x40]
CALL 0x00121070
LEA RSI,[0x21fe20]
MOV EDX,0x1
MOV RDI,RAX
CALL 0x00121070
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x0019e424
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x00120180
LAB_0019e424:
LEA RSI,[RSP + 0x48]
LAB_0019e429:
MOV RDI,qword ptr [RSP + 0x38]
CALL 0x00120660
LAB_0019e433:
MOV RSI,qword ptr [0x00262f58]
LEA RDI,[RSP + 0x40]
CALL 0x00120c80
LEA RDI,[RSP + 0xb0]
CALL 0x00120c50
ADD RSP,0x1b8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* minja::error_location_suffix(std::__cxx11::string const&, unsigned long) */
void __thiscall minja::error_location_suffix(minja *this,string *param_1,ulong param_2)
{
long lVar1;
ostream *poVar2;
int8 uVar3;
ulong uVar4;
long lVar5;
ulong uVar6;
long lVar7;
ulong uVar8;
long lVar9;
int1 local_1e1;
long *local_1e0;
long local_1d8;
long local_1d0 [2];
ulong local_1c0;
ulong local_1b8;
minja *local_1b0;
long *local_1a8;
int8 local_1a0;
long local_198 [12];
ios_base local_138 [264];
lVar1 = *(long *)param_1;
if (param_2 == 0) {
uVar8 = 0;
}
else {
uVar4 = 0;
uVar8 = 0;
do {
uVar8 = uVar8 + (*(char *)(lVar1 + uVar4) == '\n');
uVar4 = uVar4 + 1;
} while (param_2 != uVar4);
}
if (*(long *)(param_1 + 8) == 0) {
lVar9 = 0;
}
else {
lVar5 = 0;
lVar9 = 0;
do {
lVar9 = lVar9 + (ulong)(*(char *)(lVar1 + lVar5) == '\n');
lVar5 = lVar5 + 1;
} while (*(long *)(param_1 + 8) != lVar5);
}
local_1a0 = 0;
local_1c0 = param_2;
local_1b0 = this;
local_1a8 = local_198;
std::__cxx11::string::_M_construct<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>
(&local_1a8,lVar1,lVar1 + param_2);
lVar1 = std::__cxx11::string::rfind((char)&local_1a8,10);
if (local_1a8 != local_198) {
operator_delete(local_1a8,local_198[0] + 1);
}
std::__cxx11::ostringstream::ostringstream((ostringstream *)&local_1a8);
/* try { // try from 0019e141 to 0019e1a6 has its CatchHandler @ 0019e48d */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)&local_1a8," at row ",8);
uVar4 = local_1c0;
local_1b8 = uVar8 + 1;
poVar2 = std::ostream::_M_insert<long>((long)&local_1a8);
std::__ostream_insert<char,std::char_traits<char>>(poVar2,", column ",9);
uVar4 = uVar4 - lVar1;
poVar2 = std::ostream::_M_insert<unsigned_long>((ulong)poVar2);
std::__ostream_insert<char,std::char_traits<char>>(poVar2,":\n",2);
if (0 < (long)uVar8) {
lVar1 = *(long *)param_1;
lVar5 = lVar1;
if (uVar8 != 1) {
lVar7 = uVar8 - 1;
do {
local_1e1 = 10;
lVar5 = std::
__find_if<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,__gnu_cxx::__ops::_Iter_equals_val<char_const>>
(lVar5,*(long *)param_1 + *(long *)(param_1 + 8),&local_1e1);
lVar5 = lVar5 + 1;
lVar7 = lVar7 + -1;
} while (lVar7 != 0);
lVar1 = *(long *)param_1;
}
local_1e1 = 10;
uVar3 = std::
__find_if<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,__gnu_cxx::__ops::_Iter_equals_val<char_const>>
(lVar5,lVar1 + *(long *)(param_1 + 8));
local_1d8 = 0;
/* try { // try from 0019e20f to 0019e21e has its CatchHandler @ 0019e465 */
local_1e0 = local_1d0;
std::__cxx11::string::
_M_construct<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>
(&local_1e0,lVar5,uVar3);
/* try { // try from 0019e229 to 0019e246 has its CatchHandler @ 0019e46d */
poVar2 = std::__ostream_insert<char,std::char_traits<char>>
((ostream *)&local_1a8,(char *)local_1e0,local_1d8);
std::__ostream_insert<char,std::char_traits<char>>(poVar2,"\n",1);
if (local_1e0 != local_1d0) {
operator_delete(local_1e0,local_1d0[0] + 1);
}
}
lVar1 = *(long *)param_1;
lVar5 = lVar1;
if (1 < local_1b8) {
uVar6 = uVar8;
local_1c0 = uVar4;
do {
local_1e1 = 10;
lVar5 = std::
__find_if<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,__gnu_cxx::__ops::_Iter_equals_val<char_const>>
(lVar5,*(long *)param_1 + *(long *)(param_1 + 8),&local_1e1);
lVar5 = lVar5 + 1;
uVar6 = uVar6 - 1;
} while (uVar6 != 0);
lVar1 = *(long *)param_1;
uVar4 = local_1c0;
}
local_1e1 = 10;
uVar3 = std::
__find_if<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,__gnu_cxx::__ops::_Iter_equals_val<char_const>>
(lVar5,lVar1 + *(long *)(param_1 + 8));
local_1d8 = 0;
/* try { // try from 0019e2ca to 0019e2d9 has its CatchHandler @ 0019e46b */
local_1e0 = local_1d0;
std::__cxx11::string::_M_construct<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>
(&local_1e0,lVar5,uVar3);
/* try { // try from 0019e2e4 to 0019e301 has its CatchHandler @ 0019e471 */
poVar2 = std::__ostream_insert<char,std::char_traits<char>>
((ostream *)&local_1a8,(char *)local_1e0,local_1d8);
std::__ostream_insert<char,std::char_traits<char>>(poVar2,"\n",1);
if (local_1e0 != local_1d0) {
operator_delete(local_1e0,local_1d0[0] + 1);
}
local_1e0 = local_1d0;
/* try { // try from 0019e324 to 0019e330 has its CatchHandler @ 0019e469 */
std::__cxx11::string::_M_construct((ulong)&local_1e0,(char)uVar4 + -1);
/* try { // try from 0019e33b to 0019e358 has its CatchHandler @ 0019e46f */
poVar2 = std::__ostream_insert<char,std::char_traits<char>>
((ostream *)&local_1a8,(char *)local_1e0,local_1d8);
std::__ostream_insert<char,std::char_traits<char>>(poVar2,"^\n",2);
if (local_1e0 != local_1d0) {
operator_delete(local_1e0,local_1d0[0] + 1);
}
if ((long)uVar8 < lVar9) {
lVar1 = *(long *)param_1;
lVar9 = lVar1;
if (uVar8 < 0xfffffffffffffffe) {
uVar8 = local_1b8;
do {
local_1e1 = 10;
lVar9 = std::
__find_if<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,__gnu_cxx::__ops::_Iter_equals_val<char_const>>
(lVar9,*(long *)param_1 + *(long *)(param_1 + 8),&local_1e1);
lVar9 = lVar9 + 1;
uVar8 = uVar8 - 1;
} while (uVar8 != 0);
lVar1 = *(long *)param_1;
}
local_1e1 = 10;
uVar3 = std::
__find_if<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,__gnu_cxx::__ops::_Iter_equals_val<char_const>>
(lVar9,lVar1 + *(long *)(param_1 + 8));
local_1d8 = 0;
local_1e0 = local_1d0;
/* try { // try from 0019e3da to 0019e3e4 has its CatchHandler @ 0019e463 */
std::__cxx11::string::
_M_construct<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>
(&local_1e0,lVar9,uVar3);
/* try { // try from 0019e3ef to 0019e40c has its CatchHandler @ 0019e467 */
poVar2 = std::__ostream_insert<char,std::char_traits<char>>
((ostream *)&local_1a8,(char *)local_1e0,local_1d8);
std::__ostream_insert<char,std::char_traits<char>>(poVar2,"\n",1);
if (local_1e0 != local_1d0) {
operator_delete(local_1e0,local_1d0[0] + 1);
}
}
/* try { // try from 0019e429 to 0019e432 has its CatchHandler @ 0019e48d */
std::__cxx11::stringbuf::str();
std::__cxx11::ostringstream::~ostringstream((ostringstream *)&local_1a8);
std::ios_base::~ios_base(local_138);
return;
}
|
|
64,807 |
mi_unique_comp
|
eloqsql/storage/myisam/mi_unique.c
|
int mi_unique_comp(MI_UNIQUEDEF *def, const uchar *a, const uchar *b,
my_bool null_are_equal)
{
const uchar *pos_a, *pos_b, *end;
HA_KEYSEG *keyseg;
for (keyseg=def->seg ; keyseg < def->end ; keyseg++)
{
enum ha_base_keytype type=(enum ha_base_keytype) keyseg->type;
uint a_length, b_length;
a_length= b_length= keyseg->length;
/* If part is NULL it's regarded as different */
if (keyseg->null_bit)
{
uint tmp;
if ((tmp=(a[keyseg->null_pos] & keyseg->null_bit)) !=
(uint) (b[keyseg->null_pos] & keyseg->null_bit))
return 1;
if (tmp)
{
if (!null_are_equal)
return 1;
continue;
}
}
pos_a= a+keyseg->start;
pos_b= b+keyseg->start;
if (keyseg->flag & HA_VAR_LENGTH_PART)
{
uint pack_length= keyseg->bit_start;
if (pack_length == 1)
{
a_length= (uint) *(uchar*) pos_a++;
b_length= (uint) *(uchar*) pos_b++;
}
else
{
a_length= uint2korr(pos_a);
b_length= uint2korr(pos_b);
pos_a+= 2; /* Skip VARCHAR length */
pos_b+= 2;
}
set_if_smaller(a_length, keyseg->length); /* Safety */
set_if_smaller(b_length, keyseg->length); /* safety */
}
else if (keyseg->flag & HA_BLOB_PART)
{
/* Only compare 'length' characters if length != 0 */
a_length= _mi_calc_blob_length(keyseg->bit_start,pos_a);
b_length= _mi_calc_blob_length(keyseg->bit_start,pos_b);
/* Check that a and b are of equal length */
if (keyseg->length)
{
/*
This is used in some cases when we are not interested in comparing
the whole length of the blob.
*/
set_if_smaller(a_length, keyseg->length);
set_if_smaller(b_length, keyseg->length);
}
memcpy((char**) &pos_a, pos_a+keyseg->bit_start, sizeof(char*));
memcpy((char**) &pos_b, pos_b+keyseg->bit_start, sizeof(char*));
}
if (type == HA_KEYTYPE_TEXT || type == HA_KEYTYPE_VARTEXT1 ||
type == HA_KEYTYPE_VARTEXT2)
{
if (ha_compare_text(keyseg->charset, (uchar *) pos_a, a_length,
(uchar *) pos_b, b_length, 0))
return 1;
}
else
{
if (a_length != b_length)
return 1;
end= pos_a+a_length;
while (pos_a != end)
{
if (*pos_a++ != *pos_b++)
return 1;
}
}
}
return 0;
}
|
O3
|
c
|
mi_unique_comp:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq 0x8(%rdi), %r15
movq %rdi, -0x48(%rbp)
cmpq 0x10(%rdi), %r15
jae 0xa6f8b
movl %ecx, %r14d
movq %rdx, -0x40(%rbp)
movq %rsi, -0x38(%rbp)
movl %ecx, -0x2c(%rbp)
movzbl 0x18(%r15), %r12d
movzwl 0x14(%r15), %ecx
movb 0x19(%r15), %dil
testb %dil, %dil
je 0xa6e72
movl 0xc(%r15), %eax
movb (%rsi,%rax), %r8b
andb %dil, %r8b
andb (%rdx,%rax), %dil
movl $0x1, %eax
cmpb %dil, %r8b
jne 0xa6f8d
testb %r8b, %r8b
je 0xa6e72
testb %r14b, %r14b
jne 0xa6f48
jmp 0xa6f8d
movl 0x8(%r15), %r13d
leaq (%rsi,%r13), %rbx
addq %rdx, %r13
movzwl 0x12(%r15), %eax
testb $0x8, %al
jne 0xa6e91
testb $0x20, %al
jne 0xa6ea8
movl %ecx, %esi
jmp 0xa6f15
cmpb $0x1, 0x1a(%r15)
jne 0xa6ef7
movzbl (%rbx), %eax
incq %rbx
movzbl (%r13), %edx
incq %r13
jmp 0xa6f07
movzbl 0x1a(%r15), %edi
movq %rbx, %rsi
callq 0x981a1
movq %rax, %r14
movzbl 0x1a(%r15), %edi
movq %r13, %rsi
callq 0x981a1
movzwl 0x14(%r15), %edx
cmpl %edx, %r14d
movl %edx, %ecx
cmovbl %r14d, %ecx
cmpl %edx, %eax
movl %edx, %esi
cmovbl %eax, %esi
testl %edx, %edx
cmovel %r14d, %ecx
movl -0x2c(%rbp), %r14d
cmovel %eax, %esi
movzbl 0x1a(%r15), %eax
movq (%rbx,%rax), %rbx
movq (%r13,%rax), %r13
jmp 0xa6f15
movzwl (%rbx), %eax
movzwl (%r13), %edx
addq $0x2, %rbx
addq $0x2, %r13
cmpl %ecx, %eax
cmovael %ecx, %eax
cmpl %ecx, %edx
movl %ecx, %esi
cmovbl %edx, %esi
movl %eax, %ecx
cmpl $0x11, %r12d
ja 0xa6f5c
movl $0x28002, %eax # imm = 0x28002
btl %r12d, %eax
jae 0xa6f5c
movq (%r15), %rdi
movl %ecx, %edx
movl %esi, %r8d
movq %rbx, %rsi
movq %r13, %rcx
xorl %r9d, %r9d
callq 0xc251c
testl %eax, %eax
movq -0x40(%rbp), %rdx
movq -0x38(%rbp), %rsi
jne 0xa6f9c
addq $0x20, %r15
movq -0x48(%rbp), %rax
cmpq 0x10(%rax), %r15
jb 0xa6e2f
jmp 0xa6f8b
movl $0x1, %eax
cmpl %esi, %ecx
jne 0xa6f8d
movl %ecx, %ecx
xorl %r8d, %r8d
movq -0x40(%rbp), %rdx
movq -0x38(%rbp), %rsi
cmpq %r8, %rcx
je 0xa6f48
movb (%rbx,%r8), %r9b
leaq 0x1(%r8), %rdi
cmpb (%r13,%r8), %r9b
movq %rdi, %r8
je 0xa6f72
jmp 0xa6f8d
xorl %eax, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x1, %eax
jmp 0xa6f8d
nop
|
mi_unique_comp:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r15, [rdi+8]
mov [rbp+var_48], rdi
cmp r15, [rdi+10h]
jnb loc_A6F8B
mov r14d, ecx
mov [rbp+var_40], rdx
mov [rbp+var_38], rsi
mov [rbp+var_2C], ecx
loc_A6E2F:
movzx r12d, byte ptr [r15+18h]
movzx ecx, word ptr [r15+14h]
mov dil, [r15+19h]
test dil, dil
jz short loc_A6E72
mov eax, [r15+0Ch]
mov r8b, [rsi+rax]
and r8b, dil
and dil, [rdx+rax]
mov eax, 1
cmp r8b, dil
jnz loc_A6F8D
test r8b, r8b
jz short loc_A6E72
test r14b, r14b
jnz loc_A6F48
jmp loc_A6F8D
loc_A6E72:
mov r13d, [r15+8]
lea rbx, [rsi+r13]
add r13, rdx
movzx eax, word ptr [r15+12h]
test al, 8
jnz short loc_A6E91
test al, 20h
jnz short loc_A6EA8
mov esi, ecx
jmp loc_A6F15
loc_A6E91:
cmp byte ptr [r15+1Ah], 1
jnz short loc_A6EF7
movzx eax, byte ptr [rbx]
inc rbx
movzx edx, byte ptr [r13+0]
inc r13
jmp short loc_A6F07
loc_A6EA8:
movzx edi, byte ptr [r15+1Ah]
mov rsi, rbx
call _mi_calc_blob_length
mov r14, rax
movzx edi, byte ptr [r15+1Ah]
mov rsi, r13
call _mi_calc_blob_length
movzx edx, word ptr [r15+14h]
cmp r14d, edx
mov ecx, edx
cmovb ecx, r14d
cmp eax, edx
mov esi, edx
cmovb esi, eax
test edx, edx
cmovz ecx, r14d
mov r14d, [rbp+var_2C]
cmovz esi, eax
movzx eax, byte ptr [r15+1Ah]
mov rbx, [rbx+rax]
mov r13, [r13+rax+0]
jmp short loc_A6F15
loc_A6EF7:
movzx eax, word ptr [rbx]
movzx edx, word ptr [r13+0]
add rbx, 2
add r13, 2
loc_A6F07:
cmp eax, ecx
cmovnb eax, ecx
cmp edx, ecx
mov esi, ecx
cmovb esi, edx
mov ecx, eax
loc_A6F15:
cmp r12d, 11h
ja short loc_A6F5C
mov eax, 28002h
bt eax, r12d
jnb short loc_A6F5C
mov rdi, [r15]
mov edx, ecx
mov r8d, esi
mov rsi, rbx
mov rcx, r13
xor r9d, r9d
call ha_compare_text
test eax, eax
mov rdx, [rbp+var_40]
mov rsi, [rbp+var_38]
jnz short loc_A6F9C
loc_A6F48:
add r15, 20h ; ' '
mov rax, [rbp+var_48]
cmp r15, [rax+10h]
jb loc_A6E2F
jmp short loc_A6F8B
loc_A6F5C:
mov eax, 1
cmp ecx, esi
jnz short loc_A6F8D
mov ecx, ecx
xor r8d, r8d
mov rdx, [rbp+var_40]
mov rsi, [rbp+var_38]
loc_A6F72:
cmp rcx, r8
jz short loc_A6F48
mov r9b, [rbx+r8]
lea rdi, [r8+1]
cmp r9b, [r13+r8+0]
mov r8, rdi
jz short loc_A6F72
jmp short loc_A6F8D
loc_A6F8B:
xor eax, eax
loc_A6F8D:
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_A6F9C:
mov eax, 1
jmp short loc_A6F8D
|
long long mi_unique_comp(long long a1, long long a2, long long a3, char a4)
{
unsigned long long v4; // r15
char v5; // r14
unsigned int v6; // r12d
unsigned int v7; // ecx
char v8; // di
long long v9; // rax
char v10; // r8
char v11; // di
long long result; // rax
long long v13; // r13
unsigned __int8 *v14; // rbx
unsigned __int8 *v15; // r13
__int16 v16; // ax
unsigned int v17; // esi
unsigned int v18; // eax
unsigned int v19; // edx
unsigned int v20; // r14d
unsigned int v21; // eax
unsigned int v22; // edx
long long v23; // rax
int v24; // eax
int v25; // eax
long long v26; // r8
bool v27; // zf
long long v29; // [rsp+10h] [rbp-40h]
long long v30; // [rsp+18h] [rbp-38h]
v4 = *(_QWORD *)(a1 + 8);
if ( v4 < *(_QWORD *)(a1 + 16) )
{
v5 = a4;
v29 = a3;
v30 = a2;
do
{
v6 = *(unsigned __int8 *)(v4 + 24);
v7 = *(unsigned __int16 *)(v4 + 20);
v8 = *(_BYTE *)(v4 + 25);
if ( !v8 )
goto LABEL_8;
v9 = *(unsigned int *)(v4 + 12);
v10 = v8 & *(_BYTE *)(a2 + v9);
v11 = *(_BYTE *)(a3 + v9) & v8;
result = 1LL;
if ( v10 != v11 )
return result;
if ( v10 )
{
if ( !v5 )
return result;
}
else
{
LABEL_8:
v13 = *(unsigned int *)(v4 + 8);
v14 = (unsigned __int8 *)(a2 + v13);
v15 = (unsigned __int8 *)(a3 + v13);
v16 = *(_WORD *)(v4 + 18);
if ( (v16 & 8) != 0 )
{
if ( *(_BYTE *)(v4 + 26) == 1 )
{
v18 = *v14++;
v19 = *v15++;
}
else
{
v18 = *(unsigned __int16 *)v14;
v19 = *(unsigned __int16 *)v15;
v14 += 2;
v15 += 2;
}
if ( v18 >= v7 )
v18 = *(unsigned __int16 *)(v4 + 20);
v17 = *(unsigned __int16 *)(v4 + 20);
if ( v19 < v7 )
v17 = v19;
v7 = v18;
}
else if ( (v16 & 0x20) != 0 )
{
v20 = mi_calc_blob_length(*(unsigned __int8 *)(v4 + 26), v14);
v21 = mi_calc_blob_length(*(unsigned __int8 *)(v4 + 26), v15);
v22 = *(unsigned __int16 *)(v4 + 20);
v7 = v22;
if ( v20 < v22 )
v7 = v20;
v17 = *(unsigned __int16 *)(v4 + 20);
if ( v21 < v22 )
v17 = v21;
if ( !*(_WORD *)(v4 + 20) )
v7 = v20;
v5 = a4;
if ( !*(_WORD *)(v4 + 20) )
v17 = v21;
v23 = *(unsigned __int8 *)(v4 + 26);
v14 = *(unsigned __int8 **)&v14[v23];
v15 = *(unsigned __int8 **)&v15[v23];
}
else
{
v17 = *(unsigned __int16 *)(v4 + 20);
}
if ( v6 <= 0x11 && (v24 = 163842, _bittest(&v24, v6)) )
{
v25 = ha_compare_text(*(_QWORD *)v4, v14, v7, v15, v17, 0LL);
a3 = v29;
a2 = v30;
if ( v25 )
return 1LL;
}
else
{
result = 1LL;
if ( v7 != v17 )
return result;
v26 = 0LL;
a3 = v29;
a2 = v30;
while ( v7 != v26 )
{
v27 = v14[v26] == v15[v26];
++v26;
if ( !v27 )
return result;
}
}
}
v4 += 32LL;
}
while ( v4 < *(_QWORD *)(a1 + 16) );
}
return 0LL;
}
|
mi_unique_comp:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R15,qword ptr [RDI + 0x8]
MOV qword ptr [RBP + -0x48],RDI
CMP R15,qword ptr [RDI + 0x10]
JNC 0x001a6f8b
MOV R14D,ECX
MOV qword ptr [RBP + -0x40],RDX
MOV qword ptr [RBP + -0x38],RSI
MOV dword ptr [RBP + -0x2c],ECX
LAB_001a6e2f:
MOVZX R12D,byte ptr [R15 + 0x18]
MOVZX ECX,word ptr [R15 + 0x14]
MOV DIL,byte ptr [R15 + 0x19]
TEST DIL,DIL
JZ 0x001a6e72
MOV EAX,dword ptr [R15 + 0xc]
MOV R8B,byte ptr [RSI + RAX*0x1]
AND R8B,DIL
AND DIL,byte ptr [RDX + RAX*0x1]
MOV EAX,0x1
CMP R8B,DIL
JNZ 0x001a6f8d
TEST R8B,R8B
JZ 0x001a6e72
TEST R14B,R14B
JNZ 0x001a6f48
JMP 0x001a6f8d
LAB_001a6e72:
MOV R13D,dword ptr [R15 + 0x8]
LEA RBX,[RSI + R13*0x1]
ADD R13,RDX
MOVZX EAX,word ptr [R15 + 0x12]
TEST AL,0x8
JNZ 0x001a6e91
TEST AL,0x20
JNZ 0x001a6ea8
MOV ESI,ECX
JMP 0x001a6f15
LAB_001a6e91:
CMP byte ptr [R15 + 0x1a],0x1
JNZ 0x001a6ef7
MOVZX EAX,byte ptr [RBX]
INC RBX
MOVZX EDX,byte ptr [R13]
INC R13
JMP 0x001a6f07
LAB_001a6ea8:
MOVZX EDI,byte ptr [R15 + 0x1a]
MOV RSI,RBX
CALL 0x001981a1
MOV R14,RAX
MOVZX EDI,byte ptr [R15 + 0x1a]
MOV RSI,R13
CALL 0x001981a1
MOVZX EDX,word ptr [R15 + 0x14]
CMP R14D,EDX
MOV ECX,EDX
CMOVC ECX,R14D
CMP EAX,EDX
MOV ESI,EDX
CMOVC ESI,EAX
TEST EDX,EDX
CMOVZ ECX,R14D
MOV R14D,dword ptr [RBP + -0x2c]
CMOVZ ESI,EAX
MOVZX EAX,byte ptr [R15 + 0x1a]
MOV RBX,qword ptr [RBX + RAX*0x1]
MOV R13,qword ptr [R13 + RAX*0x1]
JMP 0x001a6f15
LAB_001a6ef7:
MOVZX EAX,word ptr [RBX]
MOVZX EDX,word ptr [R13]
ADD RBX,0x2
ADD R13,0x2
LAB_001a6f07:
CMP EAX,ECX
CMOVNC EAX,ECX
CMP EDX,ECX
MOV ESI,ECX
CMOVC ESI,EDX
MOV ECX,EAX
LAB_001a6f15:
CMP R12D,0x11
JA 0x001a6f5c
MOV EAX,0x28002
BT EAX,R12D
JNC 0x001a6f5c
MOV RDI,qword ptr [R15]
MOV EDX,ECX
MOV R8D,ESI
MOV RSI,RBX
MOV RCX,R13
XOR R9D,R9D
CALL 0x001c251c
TEST EAX,EAX
MOV RDX,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x38]
JNZ 0x001a6f9c
LAB_001a6f48:
ADD R15,0x20
MOV RAX,qword ptr [RBP + -0x48]
CMP R15,qword ptr [RAX + 0x10]
JC 0x001a6e2f
JMP 0x001a6f8b
LAB_001a6f5c:
MOV EAX,0x1
CMP ECX,ESI
JNZ 0x001a6f8d
MOV ECX,ECX
XOR R8D,R8D
MOV RDX,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x38]
LAB_001a6f72:
CMP RCX,R8
JZ 0x001a6f48
MOV R9B,byte ptr [RBX + R8*0x1]
LEA RDI,[R8 + 0x1]
CMP R9B,byte ptr [R13 + R8*0x1]
MOV R8,RDI
JZ 0x001a6f72
JMP 0x001a6f8d
LAB_001a6f8b:
XOR EAX,EAX
LAB_001a6f8d:
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001a6f9c:
MOV EAX,0x1
JMP 0x001a6f8d
|
int8 mi_unique_comp(long param_1,long param_2,long param_3,char param_4)
{
byte *pbVar1;
byte *pbVar2;
byte bVar3;
byte bVar4;
ushort uVar5;
uint uVar6;
uint uVar7;
uint uVar8;
int iVar9;
uint uVar10;
ulong uVar11;
uint uVar12;
ushort *puVar13;
byte bVar14;
ulong uVar15;
ushort *puVar16;
int8 *puVar17;
puVar17 = *(int8 **)(param_1 + 8);
if (puVar17 < *(int8 **)(param_1 + 0x10)) {
do {
bVar4 = *(byte *)(puVar17 + 3);
uVar5 = *(ushort *)((long)puVar17 + 0x14);
uVar11 = (ulong)uVar5;
bVar3 = *(byte *)((long)puVar17 + 0x19);
if (bVar3 == 0) {
LAB_001a6e72:
puVar13 = (ushort *)(param_2 + (ulong)*(uint *)(puVar17 + 1));
puVar16 = (ushort *)((ulong)*(uint *)(puVar17 + 1) + param_3);
if ((*(ushort *)((long)puVar17 + 0x12) & 8) == 0) {
if ((*(ushort *)((long)puVar17 + 0x12) & 0x20) == 0) {
uVar10 = (uint)uVar5;
}
else {
uVar7 = _mi_calc_blob_length(*(int1 *)((long)puVar17 + 0x1a),puVar13);
uVar8 = _mi_calc_blob_length(*(int1 *)((long)puVar17 + 0x1a),puVar16);
uVar5 = *(ushort *)((long)puVar17 + 0x14);
uVar6 = (uint)uVar5;
if (uVar7 < uVar5) {
uVar6 = uVar7;
}
uVar12 = (uint)uVar5;
uVar10 = uVar12;
if (uVar8 < uVar12) {
uVar10 = uVar8;
}
if (uVar12 == 0) {
uVar10 = uVar8;
uVar6 = uVar7;
}
uVar11 = (ulong)uVar6;
puVar13 = *(ushort **)((long)puVar13 + (ulong)*(byte *)((long)puVar17 + 0x1a));
puVar16 = *(ushort **)((long)puVar16 + (ulong)*(byte *)((long)puVar17 + 0x1a));
}
}
else {
if (*(char *)((long)puVar17 + 0x1a) == '\x01') {
uVar6 = (uint)(byte)*puVar13;
puVar13 = (ushort *)((long)puVar13 + 1);
uVar7 = (uint)(byte)*puVar16;
puVar16 = (ushort *)((long)puVar16 + 1);
}
else {
uVar6 = (uint)*puVar13;
uVar7 = (uint)*puVar16;
puVar13 = puVar13 + 1;
puVar16 = puVar16 + 1;
}
uVar10 = (uint)uVar5;
if (uVar10 <= uVar6) {
uVar6 = uVar10;
}
if (uVar7 < uVar10) {
uVar10 = uVar7;
}
uVar11 = (ulong)uVar6;
}
if ((bVar4 < 0x12) && ((0x28002U >> (bVar4 & 0x1f) & 1) != 0)) {
iVar9 = ha_compare_text(*puVar17,puVar13,uVar11,puVar16,uVar10,0);
if (iVar9 != 0) {
return 1;
}
}
else {
if ((uint)uVar11 != uVar10) {
return 1;
}
uVar15 = 0;
while (uVar11 != uVar15) {
pbVar1 = (byte *)((long)puVar13 + uVar15);
pbVar2 = (byte *)((long)puVar16 + uVar15);
uVar15 = uVar15 + 1;
if (*pbVar1 != *pbVar2) {
return 1;
}
}
}
}
else {
bVar14 = *(byte *)(param_2 + (ulong)*(uint *)((long)puVar17 + 0xc)) & bVar3;
if (bVar14 != (bVar3 & *(byte *)(param_3 + (ulong)*(uint *)((long)puVar17 + 0xc)))) {
return 1;
}
if (bVar14 == 0) goto LAB_001a6e72;
if (param_4 == '\0') {
return 1;
}
}
puVar17 = puVar17 + 4;
} while (puVar17 < *(int8 **)(param_1 + 0x10));
}
return 0;
}
|
|
64,808 |
test_bug21726
|
eloqsql/libmariadb/unittest/libmariadb/result.c
|
static int test_bug21726(MYSQL *mysql)
{
const char *create_table[]=
{
"DROP TABLE IF EXISTS t1",
"CREATE TABLE t1 (i INT)",
"INSERT INTO t1 VALUES (1)",
};
const char *update_query= "UPDATE t1 SET i= LAST_INSERT_ID(i + 1)";
int rc;
unsigned long long insert_id;
const char *select_query= "SELECT * FROM t1";
MYSQL_RES *result;
rc= mysql_query(mysql, create_table[0]);
check_mysql_rc(rc, mysql);
rc= mysql_query(mysql, create_table[1]);
check_mysql_rc(rc, mysql);
rc= mysql_query(mysql, create_table[2]);
check_mysql_rc(rc, mysql);
rc= mysql_query(mysql, update_query);
check_mysql_rc(rc, mysql);
insert_id= mysql_insert_id(mysql);
FAIL_UNLESS(insert_id == 2, "insert_id != 2");
rc= mysql_query(mysql, update_query);
check_mysql_rc(rc, mysql);
insert_id= mysql_insert_id(mysql);
FAIL_UNLESS(insert_id == 3, "insert_id != 3");
rc= mysql_query(mysql, select_query);
check_mysql_rc(rc, mysql);
insert_id= mysql_insert_id(mysql);
FAIL_UNLESS(insert_id == 3, "insert_id != 3");
result= mysql_store_result(mysql);
mysql_free_result(result);
return OK;
}
|
O0
|
c
|
test_bug21726:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0x10(%rbp)
movq 0x456fa(%rip), %rax # 0x5df70
movq %rax, -0x30(%rbp)
movq 0x456f7(%rip), %rax # 0x5df78
movq %rax, -0x28(%rbp)
movq 0x456f4(%rip), %rax # 0x5df80
movq %rax, -0x20(%rbp)
leaq 0x395c6(%rip), %rax # 0x51e5d
movq %rax, -0x38(%rbp)
leaq 0x395e2(%rip), %rax # 0x51e84
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rdi
movq -0x30(%rbp), %rsi
callq 0x23d80
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0x3c(%rbp)
je 0x18908
movl -0x3c(%rbp), %eax
movl %eax, -0x64(%rbp)
movq -0x10(%rbp), %rdi
callq 0x27700
movq %rax, -0x60(%rbp)
movq -0x10(%rbp), %rdi
callq 0x276d0
movl -0x64(%rbp), %esi
movq -0x60(%rbp), %rdx
movl %eax, %ecx
leaq 0x38981(%rip), %rdi # 0x51269
leaq 0x38fa5(%rip), %r8 # 0x51894
movl $0x258, %r9d # imm = 0x258
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x1890a
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x23d80
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0x3c(%rbp)
je 0x1896c
movl -0x3c(%rbp), %eax
movl %eax, -0x74(%rbp)
movq -0x10(%rbp), %rdi
callq 0x27700
movq %rax, -0x70(%rbp)
movq -0x10(%rbp), %rdi
callq 0x276d0
movl -0x74(%rbp), %esi
movq -0x70(%rbp), %rdx
movl %eax, %ecx
leaq 0x3891d(%rip), %rdi # 0x51269
leaq 0x38f41(%rip), %r8 # 0x51894
movl $0x25a, %r9d # imm = 0x25A
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x1896e
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0x23d80
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0x3c(%rbp)
je 0x189d6
movl -0x3c(%rbp), %eax
movl %eax, -0x84(%rbp)
movq -0x10(%rbp), %rdi
callq 0x27700
movq %rax, -0x80(%rbp)
movq -0x10(%rbp), %rdi
callq 0x276d0
movl -0x84(%rbp), %esi
movq -0x80(%rbp), %rdx
movl %eax, %ecx
leaq 0x388b3(%rip), %rdi # 0x51269
leaq 0x38ed7(%rip), %r8 # 0x51894
movl $0x25c, %r9d # imm = 0x25C
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x189d8
movq -0x10(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x23d80
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0x3c(%rbp)
je 0x18a46
movl -0x3c(%rbp), %eax
movl %eax, -0x94(%rbp)
movq -0x10(%rbp), %rdi
callq 0x27700
movq %rax, -0x90(%rbp)
movq -0x10(%rbp), %rdi
callq 0x276d0
movl -0x94(%rbp), %esi
movq -0x90(%rbp), %rdx
movl %eax, %ecx
leaq 0x38843(%rip), %rdi # 0x51269
leaq 0x38e67(%rip), %r8 # 0x51894
movl $0x25f, %r9d # imm = 0x25F
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x18a48
movq -0x10(%rbp), %rdi
callq 0x276b0
movq %rax, -0x48(%rbp)
cmpq $0x2, -0x48(%rbp)
je 0x18a89
leaq 0x386c1(%rip), %rdi # 0x51124
leaq 0x3942b(%rip), %rsi # 0x51e95
leaq 0x38e23(%rip), %rdx # 0x51894
movl $0x261, %ecx # imm = 0x261
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x18a8b
movq -0x10(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x23d80
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0x3c(%rbp)
je 0x18af9
movl -0x3c(%rbp), %eax
movl %eax, -0xa4(%rbp)
movq -0x10(%rbp), %rdi
callq 0x27700
movq %rax, -0xa0(%rbp)
movq -0x10(%rbp), %rdi
callq 0x276d0
movl -0xa4(%rbp), %esi
movq -0xa0(%rbp), %rdx
movl %eax, %ecx
leaq 0x38790(%rip), %rdi # 0x51269
leaq 0x38db4(%rip), %r8 # 0x51894
movl $0x264, %r9d # imm = 0x264
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x18afb
movq -0x10(%rbp), %rdi
callq 0x276b0
movq %rax, -0x48(%rbp)
cmpq $0x3, -0x48(%rbp)
je 0x18b3c
leaq 0x3860e(%rip), %rdi # 0x51124
leaq 0x39387(%rip), %rsi # 0x51ea4
leaq 0x38d70(%rip), %rdx # 0x51894
movl $0x266, %ecx # imm = 0x266
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x18b3e
movq -0x10(%rbp), %rdi
movq -0x50(%rbp), %rsi
callq 0x23d80
movl %eax, -0x3c(%rbp)
cmpl $0x0, -0x3c(%rbp)
je 0x18ba9
movl -0x3c(%rbp), %eax
movl %eax, -0xb4(%rbp)
movq -0x10(%rbp), %rdi
callq 0x27700
movq %rax, -0xb0(%rbp)
movq -0x10(%rbp), %rdi
callq 0x276d0
movl -0xb4(%rbp), %esi
movq -0xb0(%rbp), %rdx
movl %eax, %ecx
leaq 0x386dd(%rip), %rdi # 0x51269
leaq 0x38d01(%rip), %r8 # 0x51894
movl $0x269, %r9d # imm = 0x269
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x18bab
movq -0x10(%rbp), %rdi
callq 0x276b0
movq %rax, -0x48(%rbp)
cmpq $0x3, -0x48(%rbp)
je 0x18be9
leaq 0x3855e(%rip), %rdi # 0x51124
leaq 0x392d7(%rip), %rsi # 0x51ea4
leaq 0x38cc0(%rip), %rdx # 0x51894
movl $0x26b, %ecx # imm = 0x26B
movb $0x0, %al
callq 0x1af50
movl $0x1, -0x4(%rbp)
jmp 0x18c08
jmp 0x18beb
movq -0x10(%rbp), %rdi
callq 0x253d0
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rdi
callq 0x1cc10
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0xc0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
test_bug21726:
push rbp
mov rbp, rsp
sub rsp, 0C0h
mov [rbp+var_10], rdi
mov rax, cs:off_5DF70; "DROP TABLE IF EXISTS t1"
mov [rbp+var_30], rax
mov rax, cs:off_5DF78; "CREATE TABLE t1 (i INT)"
mov [rbp+var_28], rax
mov rax, cs:off_5DF80; "INSERT INTO t1 VALUES (1)"
mov [rbp+var_20], rax
lea rax, aUpdateT1SetILa; "UPDATE t1 SET i= LAST_INSERT_ID(i + 1)"
mov [rbp+var_38], rax
lea rax, aSelectFromT1; "SELECT * FROM t1"
mov [rbp+var_50], rax
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_30]
call mysql_query
mov [rbp+var_3C], eax
cmp [rbp+var_3C], 0
jz short loc_18908
mov eax, [rbp+var_3C]
mov [rbp+var_64], eax
mov rdi, [rbp+var_10]
call mysql_error
mov [rbp+var_60], rax
mov rdi, [rbp+var_10]
call mysql_errno
mov esi, [rbp+var_64]
mov rdx, [rbp+var_60]
mov ecx, eax
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov r9d, 258h
mov al, 0
call diag
mov [rbp+var_4], 1
jmp loc_18C08
loc_18908:
jmp short $+2
loc_1890A:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
call mysql_query
mov [rbp+var_3C], eax
cmp [rbp+var_3C], 0
jz short loc_1896C
mov eax, [rbp+var_3C]
mov [rbp+var_74], eax
mov rdi, [rbp+var_10]
call mysql_error
mov [rbp+var_70], rax
mov rdi, [rbp+var_10]
call mysql_errno
mov esi, [rbp+var_74]
mov rdx, [rbp+var_70]
mov ecx, eax
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov r9d, 25Ah
mov al, 0
call diag
mov [rbp+var_4], 1
jmp loc_18C08
loc_1896C:
jmp short $+2
loc_1896E:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_20]
call mysql_query
mov [rbp+var_3C], eax
cmp [rbp+var_3C], 0
jz short loc_189D6
mov eax, [rbp+var_3C]
mov [rbp+var_84], eax
mov rdi, [rbp+var_10]
call mysql_error
mov [rbp+var_80], rax
mov rdi, [rbp+var_10]
call mysql_errno
mov esi, [rbp+var_84]
mov rdx, [rbp+var_80]
mov ecx, eax
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov r9d, 25Ch
mov al, 0
call diag
mov [rbp+var_4], 1
jmp loc_18C08
loc_189D6:
jmp short $+2
loc_189D8:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_38]
call mysql_query
mov [rbp+var_3C], eax
cmp [rbp+var_3C], 0
jz short loc_18A46
mov eax, [rbp+var_3C]
mov [rbp+var_94], eax
mov rdi, [rbp+var_10]
call mysql_error
mov [rbp+var_90], rax
mov rdi, [rbp+var_10]
call mysql_errno
mov esi, [rbp+var_94]
mov rdx, [rbp+var_90]
mov ecx, eax
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov r9d, 25Fh
mov al, 0
call diag
mov [rbp+var_4], 1
jmp loc_18C08
loc_18A46:
jmp short $+2
loc_18A48:
mov rdi, [rbp+var_10]
call mysql_insert_id
mov [rbp+var_48], rax
cmp [rbp+var_48], 2
jz short loc_18A89
lea rdi, aErrorSSD; "Error: %s (%s: %d)"
lea rsi, aInsertId2; "insert_id != 2"
lea rdx, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov ecx, 261h
mov al, 0
call diag
mov [rbp+var_4], 1
jmp loc_18C08
loc_18A89:
jmp short $+2
loc_18A8B:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_38]
call mysql_query
mov [rbp+var_3C], eax
cmp [rbp+var_3C], 0
jz short loc_18AF9
mov eax, [rbp+var_3C]
mov [rbp+var_A4], eax
mov rdi, [rbp+var_10]
call mysql_error
mov [rbp+var_A0], rax
mov rdi, [rbp+var_10]
call mysql_errno
mov esi, [rbp+var_A4]
mov rdx, [rbp+var_A0]
mov ecx, eax
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov r9d, 264h
mov al, 0
call diag
mov [rbp+var_4], 1
jmp loc_18C08
loc_18AF9:
jmp short $+2
loc_18AFB:
mov rdi, [rbp+var_10]
call mysql_insert_id
mov [rbp+var_48], rax
cmp [rbp+var_48], 3
jz short loc_18B3C
lea rdi, aErrorSSD; "Error: %s (%s: %d)"
lea rsi, aInsertId3; "insert_id != 3"
lea rdx, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov ecx, 266h
mov al, 0
call diag
mov [rbp+var_4], 1
jmp loc_18C08
loc_18B3C:
jmp short $+2
loc_18B3E:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_50]
call mysql_query
mov [rbp+var_3C], eax
cmp [rbp+var_3C], 0
jz short loc_18BA9
mov eax, [rbp+var_3C]
mov [rbp+var_B4], eax
mov rdi, [rbp+var_10]
call mysql_error
mov [rbp+var_B0], rax
mov rdi, [rbp+var_10]
call mysql_errno
mov esi, [rbp+var_B4]
mov rdx, [rbp+var_B0]
mov ecx, eax
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov r9d, 269h
mov al, 0
call diag
mov [rbp+var_4], 1
jmp short loc_18C08
loc_18BA9:
jmp short $+2
loc_18BAB:
mov rdi, [rbp+var_10]
call mysql_insert_id
mov [rbp+var_48], rax
cmp [rbp+var_48], 3
jz short loc_18BE9
lea rdi, aErrorSSD; "Error: %s (%s: %d)"
lea rsi, aInsertId3; "insert_id != 3"
lea rdx, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov ecx, 26Bh
mov al, 0
call diag
mov [rbp+var_4], 1
jmp short loc_18C08
loc_18BE9:
jmp short $+2
loc_18BEB:
mov rdi, [rbp+var_10]
call mysql_store_result
mov [rbp+var_58], rax
mov rdi, [rbp+var_58]
call mysql_free_result
mov [rbp+var_4], 0
loc_18C08:
mov eax, [rbp+var_4]
add rsp, 0C0h
pop rbp
retn
|
long long test_bug21726(long long a1)
{
int v1; // eax
int v2; // eax
int v3; // eax
int v4; // eax
int v5; // r8d
int v6; // r9d
int v7; // eax
int v8; // r8d
int v9; // r9d
int v10; // eax
int v11; // r8d
int v12; // r9d
int v14; // [rsp+10h] [rbp-B0h]
int v15; // [rsp+20h] [rbp-A0h]
int v16; // [rsp+30h] [rbp-90h]
int v17; // [rsp+40h] [rbp-80h]
int v18; // [rsp+50h] [rbp-70h]
int v19; // [rsp+60h] [rbp-60h]
long long v20; // [rsp+68h] [rbp-58h]
int v21; // [rsp+84h] [rbp-3Ch]
int v22; // [rsp+84h] [rbp-3Ch]
int v23; // [rsp+84h] [rbp-3Ch]
int v24; // [rsp+84h] [rbp-3Ch]
int v25; // [rsp+84h] [rbp-3Ch]
int v26; // [rsp+84h] [rbp-3Ch]
v21 = mysql_query(a1, "DROP TABLE IF EXISTS t1");
if ( v21 )
{
v19 = mysql_error(a1);
v1 = mysql_errno(a1);
diag(
(unsigned int)"Error (%d): %s (%d) in %s line %d",
v21,
v19,
v1,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
600);
return 1;
}
else
{
v22 = mysql_query(a1, "CREATE TABLE t1 (i INT)");
if ( v22 )
{
v18 = mysql_error(a1);
v2 = mysql_errno(a1);
diag(
(unsigned int)"Error (%d): %s (%d) in %s line %d",
v22,
v18,
v2,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
602);
return 1;
}
else
{
v23 = mysql_query(a1, "INSERT INTO t1 VALUES (1)");
if ( v23 )
{
v17 = mysql_error(a1);
v3 = mysql_errno(a1);
diag(
(unsigned int)"Error (%d): %s (%d) in %s line %d",
v23,
v17,
v3,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
604);
return 1;
}
else
{
v24 = mysql_query(a1, "UPDATE t1 SET i= LAST_INSERT_ID(i + 1)");
if ( v24 )
{
v16 = mysql_error(a1);
v4 = mysql_errno(a1);
diag(
(unsigned int)"Error (%d): %s (%d) in %s line %d",
v24,
v16,
v4,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
607);
return 1;
}
else if ( mysql_insert_id(a1) == 2 )
{
v25 = mysql_query(a1, "UPDATE t1 SET i= LAST_INSERT_ID(i + 1)");
if ( v25 )
{
v15 = mysql_error(a1);
v7 = mysql_errno(a1);
diag(
(unsigned int)"Error (%d): %s (%d) in %s line %d",
v25,
v15,
v7,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
612);
return 1;
}
else if ( mysql_insert_id(a1) == 3 )
{
v26 = mysql_query(a1, "SELECT * FROM t1");
if ( v26 )
{
v14 = mysql_error(a1);
v10 = mysql_errno(a1);
diag(
(unsigned int)"Error (%d): %s (%d) in %s line %d",
v26,
v14,
v10,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
617);
return 1;
}
else if ( mysql_insert_id(a1) == 3 )
{
v20 = mysql_store_result(a1);
mysql_free_result(v20);
return 0;
}
else
{
diag(
(unsigned int)"Error: %s (%s: %d)",
(unsigned int)"insert_id != 3",
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
619,
v11,
v12);
return 1;
}
}
else
{
diag(
(unsigned int)"Error: %s (%s: %d)",
(unsigned int)"insert_id != 3",
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
614,
v8,
v9);
return 1;
}
}
else
{
diag(
(unsigned int)"Error: %s (%s: %d)",
(unsigned int)"insert_id != 2",
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
609,
v5,
v6);
return 1;
}
}
}
}
}
|
test_bug21726:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xc0
MOV qword ptr [RBP + -0x10],RDI
MOV RAX,qword ptr [0x0015df70]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [0x0015df78]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [0x0015df80]
MOV qword ptr [RBP + -0x20],RAX
LEA RAX,[0x151e5d]
MOV qword ptr [RBP + -0x38],RAX
LEA RAX,[0x151e84]
MOV qword ptr [RBP + -0x50],RAX
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x30]
CALL 0x00123d80
MOV dword ptr [RBP + -0x3c],EAX
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x00118908
MOV EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0x64],EAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00127700
MOV qword ptr [RBP + -0x60],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276d0
MOV ESI,dword ptr [RBP + -0x64]
MOV RDX,qword ptr [RBP + -0x60]
MOV ECX,EAX
LEA RDI,[0x151269]
LEA R8,[0x151894]
MOV R9D,0x258
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_00118908:
JMP 0x0011890a
LAB_0011890a:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
CALL 0x00123d80
MOV dword ptr [RBP + -0x3c],EAX
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x0011896c
MOV EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0x74],EAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00127700
MOV qword ptr [RBP + -0x70],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276d0
MOV ESI,dword ptr [RBP + -0x74]
MOV RDX,qword ptr [RBP + -0x70]
MOV ECX,EAX
LEA RDI,[0x151269]
LEA R8,[0x151894]
MOV R9D,0x25a
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_0011896c:
JMP 0x0011896e
LAB_0011896e:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x00123d80
MOV dword ptr [RBP + -0x3c],EAX
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x001189d6
MOV EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0x84],EAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00127700
MOV qword ptr [RBP + -0x80],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276d0
MOV ESI,dword ptr [RBP + -0x84]
MOV RDX,qword ptr [RBP + -0x80]
MOV ECX,EAX
LEA RDI,[0x151269]
LEA R8,[0x151894]
MOV R9D,0x25c
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_001189d6:
JMP 0x001189d8
LAB_001189d8:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x38]
CALL 0x00123d80
MOV dword ptr [RBP + -0x3c],EAX
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x00118a46
MOV EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0x94],EAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00127700
MOV qword ptr [RBP + -0x90],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276d0
MOV ESI,dword ptr [RBP + -0x94]
MOV RDX,qword ptr [RBP + -0x90]
MOV ECX,EAX
LEA RDI,[0x151269]
LEA R8,[0x151894]
MOV R9D,0x25f
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_00118a46:
JMP 0x00118a48
LAB_00118a48:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276b0
MOV qword ptr [RBP + -0x48],RAX
CMP qword ptr [RBP + -0x48],0x2
JZ 0x00118a89
LEA RDI,[0x151124]
LEA RSI,[0x151e95]
LEA RDX,[0x151894]
MOV ECX,0x261
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_00118a89:
JMP 0x00118a8b
LAB_00118a8b:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x38]
CALL 0x00123d80
MOV dword ptr [RBP + -0x3c],EAX
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x00118af9
MOV EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0xa4],EAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00127700
MOV qword ptr [RBP + -0xa0],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276d0
MOV ESI,dword ptr [RBP + -0xa4]
MOV RDX,qword ptr [RBP + -0xa0]
MOV ECX,EAX
LEA RDI,[0x151269]
LEA R8,[0x151894]
MOV R9D,0x264
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_00118af9:
JMP 0x00118afb
LAB_00118afb:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276b0
MOV qword ptr [RBP + -0x48],RAX
CMP qword ptr [RBP + -0x48],0x3
JZ 0x00118b3c
LEA RDI,[0x151124]
LEA RSI,[0x151ea4]
LEA RDX,[0x151894]
MOV ECX,0x266
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_00118b3c:
JMP 0x00118b3e
LAB_00118b3e:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x50]
CALL 0x00123d80
MOV dword ptr [RBP + -0x3c],EAX
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x00118ba9
MOV EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0xb4],EAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00127700
MOV qword ptr [RBP + -0xb0],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276d0
MOV ESI,dword ptr [RBP + -0xb4]
MOV RDX,qword ptr [RBP + -0xb0]
MOV ECX,EAX
LEA RDI,[0x151269]
LEA R8,[0x151894]
MOV R9D,0x269
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_00118ba9:
JMP 0x00118bab
LAB_00118bab:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001276b0
MOV qword ptr [RBP + -0x48],RAX
CMP qword ptr [RBP + -0x48],0x3
JZ 0x00118be9
LEA RDI,[0x151124]
LEA RSI,[0x151ea4]
LEA RDX,[0x151894]
MOV ECX,0x26b
MOV AL,0x0
CALL 0x0011af50
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00118c08
LAB_00118be9:
JMP 0x00118beb
LAB_00118beb:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001253d0
MOV qword ptr [RBP + -0x58],RAX
MOV RDI,qword ptr [RBP + -0x58]
CALL 0x0011cc10
MOV dword ptr [RBP + -0x4],0x0
LAB_00118c08:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0xc0
POP RBP
RET
|
int4 test_bug21726(int8 param_1)
{
int *puVar1;
int *puVar2;
int iVar3;
int4 uVar4;
int8 uVar5;
long lVar6;
int4 local_c;
puVar2 = PTR_s_INSERT_INTO_t1_VALUES__1__0015df80;
puVar1 = PTR_s_CREATE_TABLE_t1__i_INT__0015df78;
iVar3 = mysql_query(param_1,PTR_s_DROP_TABLE_IF_EXISTS_t1_0015df70);
if (iVar3 == 0) {
iVar3 = mysql_query(param_1,puVar1);
if (iVar3 == 0) {
iVar3 = mysql_query(param_1,puVar2);
if (iVar3 == 0) {
iVar3 = mysql_query(param_1,"UPDATE t1 SET i= LAST_INSERT_ID(i + 1)");
if (iVar3 == 0) {
lVar6 = mysql_insert_id(param_1);
if (lVar6 == 2) {
iVar3 = mysql_query(param_1,"UPDATE t1 SET i= LAST_INSERT_ID(i + 1)");
if (iVar3 == 0) {
lVar6 = mysql_insert_id(param_1);
if (lVar6 == 3) {
iVar3 = mysql_query(param_1,"SELECT * FROM t1");
if (iVar3 == 0) {
lVar6 = mysql_insert_id(param_1);
if (lVar6 == 3) {
uVar5 = mysql_store_result(param_1);
mysql_free_result(uVar5);
local_c = 0;
}
else {
diag("Error: %s (%s: %d)","insert_id != 3",
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c"
,0x26b);
local_c = 1;
}
}
else {
uVar5 = mysql_error(param_1);
uVar4 = mysql_errno(param_1);
diag("Error (%d): %s (%d) in %s line %d",iVar3,uVar5,uVar4,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c"
,0x269);
local_c = 1;
}
}
else {
diag("Error: %s (%s: %d)","insert_id != 3",
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c"
,0x266);
local_c = 1;
}
}
else {
uVar5 = mysql_error(param_1);
uVar4 = mysql_errno(param_1);
diag("Error (%d): %s (%d) in %s line %d",iVar3,uVar5,uVar4,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c"
,0x264);
local_c = 1;
}
}
else {
diag("Error: %s (%s: %d)","insert_id != 2",
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
0x261);
local_c = 1;
}
}
else {
uVar5 = mysql_error(param_1);
uVar4 = mysql_errno(param_1);
diag("Error (%d): %s (%d) in %s line %d",iVar3,uVar5,uVar4,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
0x25f);
local_c = 1;
}
}
else {
uVar5 = mysql_error(param_1);
uVar4 = mysql_errno(param_1);
diag("Error (%d): %s (%d) in %s line %d",iVar3,uVar5,uVar4,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",
0x25c);
local_c = 1;
}
}
else {
uVar5 = mysql_error(param_1);
uVar4 = mysql_errno(param_1);
diag("Error (%d): %s (%d) in %s line %d",iVar3,uVar5,uVar4,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",0x25a)
;
local_c = 1;
}
}
else {
uVar5 = mysql_error(param_1);
uVar4 = mysql_errno(param_1);
diag("Error (%d): %s (%d) in %s line %d",iVar3,uVar5,uVar4,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/result.c",600);
local_c = 1;
}
return local_c;
}
|
|
64,809 |
wait_for_flush
|
eloqsql/storage/maria/ma_pagecache.c
|
static void wait_for_flush(PAGECACHE *pagecache
__attribute__((unused)),
PAGECACHE_BLOCK_LINK *block
__attribute__((unused)))
{
struct st_my_thread_var *thread= my_thread_var;
DBUG_ENTER("wait_for_flush");
wqueue_add_to_queue(&block->wqueue[COND_FOR_SAVED], thread);
do
{
DBUG_PRINT("wait",
("suspend thread %s %ld", thread->name, (ulong) thread->id));
pagecache_pthread_cond_wait(&thread->suspend,
&pagecache->cache_lock);
}
while(thread->next);
DBUG_VOID_RETURN;
}
|
O0
|
c
|
wait_for_flush:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
callq 0xfc1b0
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
addq $0x48, %rdi
addq $0x8, %rdi
movq -0x18(%rbp), %rsi
callq 0x105ff0
jmp 0x3e760
jmp 0x3e762
movq -0x18(%rbp), %rdi
addq $0x8, %rdi
movq -0x8(%rbp), %rsi
addq $0xc8, %rsi
leaq 0x11970d(%rip), %rdx # 0x157e89
movl $0x665, %ecx # imm = 0x665
callq 0x3df50
movq -0x18(%rbp), %rax
cmpq $0x0, 0x88(%rax)
jne 0x3e75e
jmp 0x3e796
jmp 0x3e798
addq $0x20, %rsp
popq %rbp
retq
nop
|
wait_for_flush:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
call _my_thread_var
mov [rbp+var_18], rax
mov rdi, [rbp+var_10]
add rdi, 48h ; 'H'
add rdi, 8
mov rsi, [rbp+var_18]
call wqueue_add_to_queue
loc_3E75E:
jmp short $+2
loc_3E760:
jmp short $+2
loc_3E762:
mov rdi, [rbp+var_18]
add rdi, 8
mov rsi, [rbp+var_8]
add rsi, 0C8h
lea rdx, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov ecx, 665h
call inline_mysql_cond_wait_0
mov rax, [rbp+var_18]
cmp qword ptr [rax+88h], 0
jnz short loc_3E75E
jmp short $+2
loc_3E796:
jmp short $+2
loc_3E798:
add rsp, 20h
pop rbp
retn
|
long long wait_for_flush(long long a1, long long a2)
{
long long result; // rax
long long v3; // [rsp+8h] [rbp-18h]
v3 = my_thread_var();
wqueue_add_to_queue(a2 + 80, v3);
do
{
inline_mysql_cond_wait_0(
v3 + 8,
a1 + 200,
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c",
0x665u);
result = v3;
}
while ( *(_QWORD *)(v3 + 136) );
return result;
}
|
wait_for_flush:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
CALL 0x001fc1b0
MOV qword ptr [RBP + -0x18],RAX
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x48
ADD RDI,0x8
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x00205ff0
LAB_0013e75e:
JMP 0x0013e760
LAB_0013e760:
JMP 0x0013e762
LAB_0013e762:
MOV RDI,qword ptr [RBP + -0x18]
ADD RDI,0x8
MOV RSI,qword ptr [RBP + -0x8]
ADD RSI,0xc8
LEA RDX,[0x257e89]
MOV ECX,0x665
CALL 0x0013df50
MOV RAX,qword ptr [RBP + -0x18]
CMP qword ptr [RAX + 0x88],0x0
JNZ 0x0013e75e
JMP 0x0013e796
LAB_0013e796:
JMP 0x0013e798
LAB_0013e798:
ADD RSP,0x20
POP RBP
RET
|
void wait_for_flush(long param_1,long param_2)
{
long lVar1;
lVar1 = _my_thread_var();
wqueue_add_to_queue(param_2 + 0x50,lVar1);
do {
inline_mysql_cond_wait
(lVar1 + 8,param_1 + 200,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c",0x665);
} while (*(long *)(lVar1 + 0x88) != 0);
return;
}
|
|
64,810 |
minja::Value::to_bool() const
|
llama.cpp/common/minja/minja.hpp
|
bool to_bool() const {
if (is_null()) return false;
if (is_boolean()) return get<bool>();
if (is_number()) return get<double>() != 0;
if (is_string()) return !get<std::string>().empty();
if (is_array()) return !empty();
return true;
}
|
O3
|
cpp
|
minja::Value::to_bool() const:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rsi
cmpq $0x0, 0x20(%rdi)
movq 0x10(%rdi), %rax
movb 0x40(%rdi), %cl
jne 0xe41a8
testq %rax, %rax
jne 0xe41a8
testb %cl, %cl
jne 0xe41a8
cmpq $0x0, 0x30(%rsi)
jne 0xe41a8
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r14
retq
cmpb $0x4, %cl
jne 0xe41bc
movq %rsi, %rdi
addq $0x28, %rsp
popq %rbx
popq %r14
jmp 0xe4234
leal -0x5(%rcx), %edx
cmpb $0x2, %dl
ja 0xe41df
movq %rsi, %rdi
callq 0xe4344
xorpd %xmm1, %xmm1
cmpneqsd %xmm0, %xmm1
movq %xmm1, %rbx
andl $0x1, %ebx
jmp 0xe419e
cmpb $0x3, %cl
jne 0xe4215
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0xe445a
cmpq $0x0, 0x8(%r14)
setne %bl
movq (%r14), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0xe419e
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x231f0
jmp 0xe419e
testq %rax, %rax
je 0xe422c
movq %rsi, %rdi
callq 0xe4564
movl %eax, %ebx
xorb $0x1, %bl
jmp 0xe419e
movb $0x1, %bl
jmp 0xe419e
nop
|
_ZNK5minja5Value7to_boolEv:
push r14
push rbx
sub rsp, 28h
mov rsi, rdi
cmp qword ptr [rdi+20h], 0
mov rax, [rdi+10h]
mov cl, [rdi+40h]
jnz short loc_E41A8
test rax, rax
jnz short loc_E41A8
test cl, cl
jnz short loc_E41A8
cmp qword ptr [rsi+30h], 0
jnz short loc_E41A8
xor ebx, ebx
loc_E419E:
mov eax, ebx
add rsp, 28h
pop rbx
pop r14
retn
loc_E41A8:
cmp cl, 4
jnz short loc_E41BC
mov rdi, rsi
add rsp, 28h
pop rbx
pop r14
jmp _ZNK5minja5Value3getIbEET_v; minja::Value::get<bool>(void)
loc_E41BC:
lea edx, [rcx-5]
cmp dl, 2
ja short loc_E41DF
mov rdi, rsi
call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void)
xorpd xmm1, xmm1
cmpneqsd xmm1, xmm0
movq rbx, xmm1
and ebx, 1
jmp short loc_E419E
loc_E41DF:
cmp cl, 3
jnz short loc_E4215
lea r14, [rsp+38h+var_30]
mov rdi, r14
call _ZNK5minja5Value3getINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEET_v; minja::Value::get<std::string>(void)
cmp qword ptr [r14+8], 0
setnz bl
mov rdi, [r14]; void *
lea rax, [rsp+38h+var_20]
cmp rdi, rax
jz short loc_E419E
mov rsi, [rsp+38h+var_20]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_E419E
loc_E4215:
test rax, rax
jz short loc_E422C
mov rdi, rsi; this
call _ZNK5minja5Value5emptyEv; minja::Value::empty(void)
mov ebx, eax
xor bl, 1
jmp loc_E419E
loc_E422C:
mov bl, 1
jmp loc_E419E
|
long long minja::Value::to_bool(minja::Value *this)
{
unsigned int v1; // ebx
long long v2; // rax
char v3; // cl
__m128d v5; // xmm0
void *v6[2]; // [rsp+8h] [rbp-30h] BYREF
long long v7; // [rsp+18h] [rbp-20h] BYREF
v2 = *((_QWORD *)this + 2);
v3 = *((_BYTE *)this + 64);
if ( !*((_QWORD *)this + 4) && !v2 && !v3 && !*((_QWORD *)this + 6) )
return 0;
if ( v3 != 4 )
{
if ( (unsigned __int8)(v3 - 5) > 2u )
{
if ( v3 == 3 )
{
minja::Value::get<std::string>(v6, this);
LOBYTE(v1) = v6[1] != 0LL;
if ( v6[0] != &v7 )
operator delete(v6[0], v7 + 1);
}
else if ( v2 )
{
v1 = minja::Value::empty(this);
LOBYTE(v1) = v1 ^ 1;
}
else
{
LOBYTE(v1) = 1;
}
}
else
{
v5.m128d_f64[0] = minja::Value::get<double>(this);
return *(_OWORD *)&_mm_cmpneq_sd((__m128d)0LL, v5) & 1;
}
return v1;
}
return minja::Value::get<bool>(this);
}
|
to_bool:
PUSH R14
PUSH RBX
SUB RSP,0x28
MOV RSI,RDI
CMP qword ptr [RDI + 0x20],0x0
MOV RAX,qword ptr [RDI + 0x10]
MOV CL,byte ptr [RDI + 0x40]
JNZ 0x001e41a8
TEST RAX,RAX
JNZ 0x001e41a8
TEST CL,CL
JNZ 0x001e41a8
CMP qword ptr [RSI + 0x30],0x0
JNZ 0x001e41a8
XOR EBX,EBX
LAB_001e419e:
MOV EAX,EBX
ADD RSP,0x28
POP RBX
POP R14
RET
LAB_001e41a8:
CMP CL,0x4
JNZ 0x001e41bc
MOV RDI,RSI
ADD RSP,0x28
POP RBX
POP R14
JMP 0x001e4234
LAB_001e41bc:
LEA EDX,[RCX + -0x5]
CMP DL,0x2
JA 0x001e41df
MOV RDI,RSI
CALL 0x001e4344
XORPD XMM1,XMM1
CMPNEQSD XMM1,XMM0
MOVQ RBX,XMM1
AND EBX,0x1
JMP 0x001e419e
LAB_001e41df:
CMP CL,0x3
JNZ 0x001e4215
LEA R14,[RSP + 0x8]
MOV RDI,R14
CALL 0x001e445a
CMP qword ptr [R14 + 0x8],0x0
SETNZ BL
MOV RDI,qword ptr [R14]
LEA RAX,[RSP + 0x18]
CMP RDI,RAX
JZ 0x001e419e
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001231f0
JMP 0x001e419e
LAB_001e4215:
TEST RAX,RAX
JZ 0x001e422c
MOV RDI,RSI
CALL 0x001e4564
MOV EBX,EAX
XOR BL,0x1
JMP 0x001e419e
LAB_001e422c:
MOV BL,0x1
JMP 0x001e419e
|
/* minja::Value::to_bool() const */
byte __thiscall minja::Value::to_bool(Value *this)
{
Value VVar1;
bool bVar2;
byte bVar3;
double dVar4;
long *local_30;
long local_28;
long local_20 [2];
VVar1 = this[0x40];
if ((((*(long *)(this + 0x20) == 0) && (*(long *)(this + 0x10) == 0)) && (VVar1 == (Value)0x0)) &&
(*(long *)(this + 0x30) == 0)) {
bVar3 = 0;
}
else {
if (VVar1 == (Value)0x4) {
bVar2 = get<bool>(this);
return bVar2;
}
if ((byte)((char)VVar1 - 5U) < 3) {
dVar4 = get<double>(this);
bVar3 = -(dVar4 != 0.0) & 1;
}
else if (VVar1 == (Value)0x3) {
get<std::__cxx11::string>();
bVar3 = local_28 != 0;
if (local_30 != local_20) {
operator_delete(local_30,local_20[0] + 1);
}
}
else if (*(long *)(this + 0x10) == 0) {
bVar3 = 1;
}
else {
bVar3 = empty(this);
bVar3 = bVar3 ^ 1;
}
}
return bVar3;
}
|
|
64,811 |
ImPlot::PushStyleVar(int, ImVec2 const&)
|
zkingston[P]unknot/build_O1/_deps/implot-src/implot.cpp
|
static const ImPlotStyleVarInfo* GetPlotStyleVarInfo(ImPlotStyleVar idx) {
IM_ASSERT(idx >= 0 && idx < ImPlotStyleVar_COUNT);
IM_ASSERT(IM_ARRAYSIZE(GPlotStyleVarInfo) == ImPlotStyleVar_COUNT);
return &GPlotStyleVarInfo[idx];
}
|
O1
|
cpp
|
ImPlot::PushStyleVar(int, ImVec2 const&):
movslq %edi, %rax
leaq (%rax,%rax,2), %rax
leaq 0x1d6eb3(%rip), %rcx # 0x29a230
cmpl $0x8, (%rcx,%rax,4)
jne 0xc348f
leaq (%rcx,%rax,4), %rax
cmpl $0x1, 0x4(%rax)
jne 0xc348f
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl %edi, %ebx
movq 0x2738f6(%rip), %r15 # 0x336ca0
movl 0x8(%rax), %r12d
movss 0x104(%r15,%r12), %xmm1
movl 0x318(%r15), %ebp
movl 0x31c(%r15), %eax
cmpl %eax, %ebp
jne 0xc3457
incl %ebp
testl %eax, %eax
je 0xc33e1
movl %eax, %ecx
shrl $0x1f, %ecx
addl %eax, %ecx
sarl %ecx
addl %eax, %ecx
jmp 0xc33e6
movl $0x8, %ecx
cmpl %ebp, %ecx
cmovgl %ecx, %ebp
cmpl %ebp, %eax
jge 0xc3457
movss %xmm1, 0x8(%rsp)
movss %xmm0, 0xc(%rsp)
movslq %ebp, %rax
shlq $0x2, %rax
leaq (%rax,%rax,2), %rdi
callq 0x2130dc
movq %rax, %r14
movq 0x320(%r15), %rsi
testq %rsi, %rsi
je 0xc343d
movslq 0x318(%r15), %rax
shlq $0x2, %rax
leaq (%rax,%rax,2), %rdx
movq %r14, %rdi
callq 0xf810
movq 0x320(%r15), %rdi
callq 0x21318e
movq %r14, 0x320(%r15)
movl %ebp, 0x31c(%r15)
movss 0xc(%rsp), %xmm0
movss 0x8(%rsp), %xmm1
movq 0x320(%r15), %rax
movslq 0x318(%r15), %rcx
leaq (%rcx,%rcx,2), %rcx
movl %ebx, (%rax,%rcx,4)
movss %xmm1, 0x4(%rax,%rcx,4)
incl 0x318(%r15)
movss %xmm0, 0x104(%r15,%r12)
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
|
_ZN6ImPlot12PushStyleVarEif:
movsxd rax, edi
lea rax, [rax+rax*2]
lea rcx, _ZN6ImPlotL17GPlotStyleVarInfoE; ImPlot::GPlotStyleVarInfo
cmp dword ptr [rcx+rax*4], 8
jnz locret_C348F
lea rax, [rcx+rax*4]
cmp dword ptr [rax+4], 1
jnz locret_C348F
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 10h
mov ebx, edi
mov r15, cs:GImPlot
mov r12d, [rax+8]
movss xmm1, dword ptr [r15+r12+104h]
mov ebp, [r15+318h]
mov eax, [r15+31Ch]
cmp ebp, eax
jnz loc_C3457
inc ebp
test eax, eax
jz short loc_C33E1
mov ecx, eax
shr ecx, 1Fh
add ecx, eax
sar ecx, 1
add ecx, eax
jmp short loc_C33E6
loc_C33E1:
mov ecx, 8
loc_C33E6:
cmp ecx, ebp
cmovg ebp, ecx
cmp eax, ebp
jge short loc_C3457
movss [rsp+38h+var_30], xmm1
movss [rsp+38h+var_2C], xmm0
movsxd rax, ebp
shl rax, 2
lea rdi, [rax+rax*2]; this
call _ZN5ImGui8MemAllocEm; ImGui::MemAlloc(ulong)
mov r14, rax
mov rsi, [r15+320h]; void *
test rsi, rsi
jz short loc_C343D
movsxd rax, dword ptr [r15+318h]
shl rax, 2
lea rdx, [rax+rax*2]
mov rdi, r14
call _memcpy
mov rdi, [r15+320h]; this
call _ZN5ImGui7MemFreeEPv; ImGui::MemFree(void *)
loc_C343D:
mov [r15+320h], r14
mov [r15+31Ch], ebp
movss xmm0, [rsp+38h+var_2C]
movss xmm1, [rsp+38h+var_30]
loc_C3457:
mov rax, [r15+320h]
movsxd rcx, dword ptr [r15+318h]
lea rcx, [rcx+rcx*2]
mov [rax+rcx*4], ebx
movss dword ptr [rax+rcx*4+4], xmm1
inc dword ptr [r15+318h]
movss dword ptr [r15+r12+104h], xmm0
add rsp, 10h
pop rbx
pop r12
pop r14
pop r15
pop rbp
locret_C348F:
retn
|
long long ImPlot::PushStyleVar(ImPlot *this, unsigned long long a2, float a3)
{
long long result; // rax
ImGui *v4; // r15
long long v5; // r12
int v6; // xmm1_4
int v7; // ebp
int v8; // eax
int v9; // ebp
int v10; // ecx
long long v11; // r14
void *v12; // rsi
long long v13; // rcx
int v14; // [rsp+0h] [rbp-30h]
result = 3LL * (int)this;
if ( ImPlot::GPlotStyleVarInfo[3 * (int)this] == 8 )
{
result = (long long)&ImPlot::GPlotStyleVarInfo[3 * (int)this];
if ( *(_DWORD *)(result + 4) == 1 )
{
v4 = GImPlot;
v5 = *(unsigned int *)(result + 8);
v6 = *(_DWORD *)((char *)GImPlot + v5 + 260);
v7 = *((_DWORD *)GImPlot + 198);
v8 = *((_DWORD *)GImPlot + 199);
if ( v7 == v8 )
{
v9 = v7 + 1;
if ( v8 )
v10 = v8 + v8 / 2;
else
v10 = 8;
if ( v10 > v9 )
v9 = v10;
if ( v8 < v9 )
{
v14 = *(_DWORD *)((char *)GImPlot + v5 + 260);
v11 = ImGui::MemAlloc((ImGui *)(12LL * v9), a2);
v12 = (void *)*((_QWORD *)v4 + 100);
if ( v12 )
{
memcpy(v11, v12, 12LL * *((int *)v4 + 198));
ImGui::MemFree(*((ImGui **)v4 + 100), v12);
}
*((_QWORD *)v4 + 100) = v11;
*((_DWORD *)v4 + 199) = v9;
v6 = v14;
}
}
result = *((_QWORD *)v4 + 100);
v13 = 3LL * *((int *)v4 + 198);
*(_DWORD *)(result + 4 * v13) = (_DWORD)this;
*(_DWORD *)(result + 4 * v13 + 4) = v6;
++*((_DWORD *)v4 + 198);
*(float *)((char *)v4 + v5 + 260) = a3;
}
}
return result;
}
|
PushStyleVar:
MOVSXD RAX,EDI
LEA RAX,[RAX + RAX*0x2]
LEA RCX,[0x39a230]
CMP dword ptr [RCX + RAX*0x4],0x8
JNZ 0x001c348f
LEA RAX,[RCX + RAX*0x4]
CMP dword ptr [RAX + 0x4],0x1
JNZ 0x001c348f
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV EBX,EDI
MOV R15,qword ptr [0x00436ca0]
MOV R12D,dword ptr [RAX + 0x8]
MOVSS XMM1,dword ptr [R15 + R12*0x1 + 0x104]
MOV EBP,dword ptr [R15 + 0x318]
MOV EAX,dword ptr [R15 + 0x31c]
CMP EBP,EAX
JNZ 0x001c3457
INC EBP
TEST EAX,EAX
JZ 0x001c33e1
MOV ECX,EAX
SHR ECX,0x1f
ADD ECX,EAX
SAR ECX,0x1
ADD ECX,EAX
JMP 0x001c33e6
LAB_001c33e1:
MOV ECX,0x8
LAB_001c33e6:
CMP ECX,EBP
CMOVG EBP,ECX
CMP EAX,EBP
JGE 0x001c3457
MOVSS dword ptr [RSP + 0x8],XMM1
MOVSS dword ptr [RSP + 0xc],XMM0
MOVSXD RAX,EBP
SHL RAX,0x2
LEA RDI,[RAX + RAX*0x2]
CALL 0x003130dc
MOV R14,RAX
MOV RSI,qword ptr [R15 + 0x320]
TEST RSI,RSI
JZ 0x001c343d
MOVSXD RAX,dword ptr [R15 + 0x318]
SHL RAX,0x2
LEA RDX,[RAX + RAX*0x2]
MOV RDI,R14
CALL 0x0010f810
MOV RDI,qword ptr [R15 + 0x320]
CALL 0x0031318e
LAB_001c343d:
MOV qword ptr [R15 + 0x320],R14
MOV dword ptr [R15 + 0x31c],EBP
MOVSS XMM0,dword ptr [RSP + 0xc]
MOVSS XMM1,dword ptr [RSP + 0x8]
LAB_001c3457:
MOV RAX,qword ptr [R15 + 0x320]
MOVSXD RCX,dword ptr [R15 + 0x318]
LEA RCX,[RCX + RCX*0x2]
MOV dword ptr [RAX + RCX*0x4],EBX
MOVSS dword ptr [RAX + RCX*0x4 + 0x4],XMM1
INC dword ptr [R15 + 0x318]
MOVSS dword ptr [R15 + R12*0x1 + 0x104],XMM0
ADD RSP,0x10
POP RBX
POP R12
POP R14
POP R15
POP RBP
LAB_001c348f:
RET
|
/* ImPlot::PushStyleVar(int, float) */
void ImPlot::PushStyleVar(int param_1,float param_2)
{
long lVar1;
int4 uVar2;
uint uVar3;
int iVar4;
long lVar5;
void *__dest;
int iVar6;
int iVar7;
lVar5 = GImPlot;
if ((*(int *)(GPlotStyleVarInfo + (long)param_1 * 0xc) == 8) &&
(lVar1 = (long)param_1 * 0xc, *(int *)(GPlotStyleVarInfo + lVar1 + 4) == 1)) {
uVar3 = *(uint *)(GPlotStyleVarInfo + lVar1 + 8);
uVar2 = *(int4 *)(GImPlot + 0x104 + (ulong)uVar3);
iVar4 = *(int *)(GImPlot + 0x31c);
if (*(int *)(GImPlot + 0x318) == iVar4) {
iVar7 = *(int *)(GImPlot + 0x318) + 1;
if (iVar4 == 0) {
iVar6 = 8;
}
else {
iVar6 = iVar4 / 2 + iVar4;
}
if (iVar7 < iVar6) {
iVar7 = iVar6;
}
if (iVar4 < iVar7) {
__dest = (void *)ImGui::MemAlloc((long)iVar7 * 0xc);
if (*(void **)(lVar5 + 800) != (void *)0x0) {
memcpy(__dest,*(void **)(lVar5 + 800),(long)*(int *)(lVar5 + 0x318) * 0xc);
ImGui::MemFree(*(void **)(lVar5 + 800));
}
*(void **)(lVar5 + 800) = __dest;
*(int *)(lVar5 + 0x31c) = iVar7;
}
}
lVar1 = *(long *)(lVar5 + 800);
iVar4 = *(int *)(lVar5 + 0x318);
*(int *)(lVar1 + (long)iVar4 * 0xc) = param_1;
*(int4 *)(lVar1 + 4 + (long)iVar4 * 0xc) = uVar2;
*(int *)(lVar5 + 0x318) = *(int *)(lVar5 + 0x318) + 1;
*(float *)(lVar5 + 0x104 + (ulong)uVar3) = param_2;
}
return;
}
|
|
64,812 |
my_strnxfrm_8bit_bin
|
eloqsql/strings/ctype-bin.c
|
static size_t
my_strnxfrm_8bit_bin(CHARSET_INFO *cs,
uchar * dst, size_t dstlen, uint nweights,
const uchar *src, size_t srclen, uint flags)
{
set_if_smaller(srclen, dstlen);
set_if_smaller(srclen, nweights);
if (srclen && dst != src)
memcpy(dst, src, srclen);
return my_strxfrm_pad_desc_and_reverse(cs, dst, dst + srclen, dst + dstlen,
(uint)(nweights - srclen), flags, 0);
}
|
O0
|
c
|
my_strnxfrm_8bit_bin:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movl 0x10(%rbp), %eax
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x30(%rbp), %rax
cmpq -0x18(%rbp), %rax
jbe 0x8a364
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
jmp 0x8a366
jmp 0x8a368
movq -0x30(%rbp), %rax
movl -0x1c(%rbp), %ecx
cmpq %rcx, %rax
jbe 0x8a37b
movl -0x1c(%rbp), %eax
movq %rax, -0x30(%rbp)
jmp 0x8a37d
cmpq $0x0, -0x30(%rbp)
je 0x8a39f
movq -0x10(%rbp), %rax
cmpq -0x28(%rbp), %rax
je 0x8a39f
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x30(%rbp), %rdx
callq 0x370c0
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x10(%rbp), %rdx
addq -0x30(%rbp), %rdx
movq -0x10(%rbp), %rcx
addq -0x18(%rbp), %rcx
movl -0x1c(%rbp), %eax
subq -0x30(%rbp), %rax
movl %eax, %r8d
movl 0x10(%rbp), %r9d
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0x960e0
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
|
my_strnxfrm_8bit_bin:
push rbp
mov rbp, rsp
sub rsp, 40h
mov eax, [rbp+arg_0]
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_1C], ecx
mov [rbp+var_28], r8
mov [rbp+var_30], r9
mov rax, [rbp+var_30]
cmp rax, [rbp+var_18]
jbe short loc_8A364
mov rax, [rbp+var_18]
mov [rbp+var_30], rax
loc_8A364:
jmp short $+2
loc_8A366:
jmp short $+2
loc_8A368:
mov rax, [rbp+var_30]
mov ecx, [rbp+var_1C]
cmp rax, rcx
jbe short loc_8A37B
mov eax, [rbp+var_1C]
mov [rbp+var_30], rax
loc_8A37B:
jmp short $+2
loc_8A37D:
cmp [rbp+var_30], 0
jz short loc_8A39F
mov rax, [rbp+var_10]
cmp rax, [rbp+var_28]
jz short loc_8A39F
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
mov rdx, [rbp+var_30]
call _memcpy
loc_8A39F:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_10]
add rdx, [rbp+var_30]
mov rcx, [rbp+var_10]
add rcx, [rbp+var_18]
mov eax, [rbp+var_1C]
sub rax, [rbp+var_30]
mov r8d, eax
mov r9d, [rbp+arg_0]
xor eax, eax
mov [rsp+40h+var_40], 0
call my_strxfrm_pad_desc_and_reverse
add rsp, 40h
pop rbp
retn
|
long long my_strnxfrm_8bit_bin(
int a1,
long long a2,
unsigned long long a3,
unsigned int a4,
long long a5,
unsigned long long a6,
int a7)
{
unsigned long long v8; // [rsp+10h] [rbp-30h]
int v10; // [rsp+28h] [rbp-18h]
v10 = a3;
v8 = a6;
if ( a6 > a3 )
v8 = a3;
if ( v8 > a4 )
v8 = a4;
if ( v8 && a2 != a5 )
memcpy(a2, a5, v8);
return my_strxfrm_pad_desc_and_reverse(a1, a2, (int)v8 + (int)a2, v10 + (int)a2, a4 - (unsigned int)v8, a7, 0);
}
|
my_strnxfrm_8bit_bin:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV EAX,dword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV dword ptr [RBP + -0x1c],ECX
MOV qword ptr [RBP + -0x28],R8
MOV qword ptr [RBP + -0x30],R9
MOV RAX,qword ptr [RBP + -0x30]
CMP RAX,qword ptr [RBP + -0x18]
JBE 0x0018a364
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
LAB_0018a364:
JMP 0x0018a366
LAB_0018a366:
JMP 0x0018a368
LAB_0018a368:
MOV RAX,qword ptr [RBP + -0x30]
MOV ECX,dword ptr [RBP + -0x1c]
CMP RAX,RCX
JBE 0x0018a37b
MOV EAX,dword ptr [RBP + -0x1c]
MOV qword ptr [RBP + -0x30],RAX
LAB_0018a37b:
JMP 0x0018a37d
LAB_0018a37d:
CMP qword ptr [RBP + -0x30],0x0
JZ 0x0018a39f
MOV RAX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RBP + -0x28]
JZ 0x0018a39f
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x30]
CALL 0x001370c0
LAB_0018a39f:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x10]
ADD RDX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RBP + -0x10]
ADD RCX,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RBP + -0x1c]
SUB RAX,qword ptr [RBP + -0x30]
MOV R8D,EAX
MOV R9D,dword ptr [RBP + 0x10]
XOR EAX,EAX
MOV dword ptr [RSP],0x0
CALL 0x001960e0
ADD RSP,0x40
POP RBP
RET
|
void my_strnxfrm_8bit_bin
(int8 param_1,void *param_2,ulong param_3,uint param_4,void *param_5,
ulong param_6,int4 param_7)
{
int8 local_38;
local_38 = param_6;
if (param_3 < param_6) {
local_38 = param_3;
}
if (param_4 < local_38) {
local_38 = (ulong)param_4;
}
if ((local_38 != 0) && (param_2 != param_5)) {
memcpy(param_2,param_5,local_38);
}
my_strxfrm_pad_desc_and_reverse
(param_1,param_2,(long)param_2 + local_38,(long)param_2 + param_3,
param_4 - (int)local_38,param_7,0);
return;
}
|
|
64,813 |
common_init()::$_0::__invoke(ggml_log_level, char const*, void*)
|
llama.cpp/common/common.cpp
|
void common_init() {
llama_log_set([](ggml_log_level level, const char * text, void * /*user_data*/) {
if (LOG_DEFAULT_LLAMA <= common_log_verbosity_thold) {
common_log_add(common_log_main(), level, "%s", text);
}
}, NULL);
#ifdef NDEBUG
const char * build_type = "";
#else
const char * build_type = " (debug)";
#endif
LOG_INF("build: %d (%s) with %s for %s%s\n", LLAMA_BUILD_NUMBER, LLAMA_COMMIT, LLAMA_COMPILER, LLAMA_BUILD_TARGET, build_type);
}
|
O3
|
cpp
|
common_init()::$_0::__invoke(ggml_log_level, char const*, void*):
leaq 0x6a137(%rip), %rax # 0x1648f0
cmpl $0x0, (%rax)
js 0xfa7e7
pushq %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl %edi, %ebp
callq 0x10ce47
leaq 0x1d5fc(%rip), %rdx # 0x117dce
movq %rax, %rdi
movl %ebp, %esi
movq %rbx, %rcx
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x10cee4
retq
|
_ZZ11common_initvEN3$_08__invokeE14ggml_log_levelPKcPv:
lea rax, common_log_verbosity_thold
cmp dword ptr [rax], 0
js short locret_FA7E7
push rbp
push rbx
push rax
mov rbx, rsi
mov ebp, edi
call _Z15common_log_mainv; common_log_main(void)
lea rdx, aSetCustomJinja_0+0FEh; "%s"
mov rdi, rax
mov esi, ebp
mov rcx, rbx
xor eax, eax
add rsp, 8
pop rbx
pop rbp
jmp _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...)
locret_FA7E7:
retn
|
void * common_init(void)::$_0::__invoke(int a1, int a2)
{
void *result; // rax
int v3; // eax
int v4; // r8d
int v5; // r9d
result = &common_log_verbosity_thold;
if ( common_log_verbosity_thold >= 0 )
{
v3 = common_log_main();
return (void *)common_log_add(v3, a1, (unsigned int)"%s", a2, v4, v5);
}
return result;
}
|
__invoke:
LEA RAX,[0x2648f0]
CMP dword ptr [RAX],0x0
JS 0x001fa7e7
PUSH RBP
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV EBP,EDI
CALL 0x0020ce47
LEA RDX,[0x217dce]
MOV RDI,RAX
MOV ESI,EBP
MOV RCX,RBX
XOR EAX,EAX
ADD RSP,0x8
POP RBX
POP RBP
JMP 0x0020cee4
LAB_001fa7e7:
RET
|
/* __invoke(ggml_log_level, char const*, void*) */
void common_init()::$_0::__invoke(int4 param_1,int8 param_2)
{
int8 uVar1;
if (-1 < common_log_verbosity_thold) {
uVar1 = common_log_main();
common_log_add(uVar1,param_1,"%s",param_2);
return;
}
return;
}
|
|
64,814 |
parse_device_list(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
|
monkey531[P]llama/common/arg.cpp
|
static std::vector<ggml_backend_dev_t> parse_device_list(const std::string & value) {
std::vector<ggml_backend_dev_t> devices;
auto dev_names = string_split<std::string>(value, ',');
if (dev_names.empty()) {
throw std::invalid_argument("no devices specified");
}
if (dev_names.size() == 1 && dev_names[0] == "none") {
devices.push_back(nullptr);
} else {
for (const auto & device : dev_names) {
auto * dev = ggml_backend_dev_by_name(device.c_str());
if (!dev || ggml_backend_dev_type(dev) != GGML_BACKEND_DEVICE_TYPE_GPU) {
throw std::invalid_argument(string_format("invalid device: %s", device.c_str()));
}
devices.push_back(dev);
}
devices.push_back(nullptr);
}
return devices;
}
|
O0
|
cpp
|
parse_device_list(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
subq $0xd8, %rsp
movq %rdi, 0x28(%rsp)
movq %rdi, %rax
movq %rax, 0x30(%rsp)
movq %rdi, 0xd0(%rsp)
movq %rsi, 0xc8(%rsp)
movb $0x0, 0xc7(%rsp)
callq 0x67ba0
movq 0xc8(%rsp), %rsi
leaq 0xa8(%rsp), %rdi
movl $0x2c, %edx
callq 0x8b400
jmp 0x8f82d
leaq 0xa8(%rsp), %rdi
callq 0x67250
testb $0x1, %al
jne 0x8f843
jmp 0x8f8d8
movl $0x10, %edi
callq 0x5a710
movq %rax, %rdi
movq %rdi, %rax
movq %rax, 0x20(%rsp)
leaq 0x185c8c(%rip), %rsi # 0x2154eb
callq 0x5a360
jmp 0x8f866
movq 0x20(%rsp), %rdi
movq 0x21a6a6(%rip), %rsi # 0x2a9f18
movq 0x21a697(%rip), %rdx # 0x2a9f10
callq 0x5abb0
jmp 0x8fb39
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa0(%rsp)
movl %eax, 0x9c(%rsp)
jmp 0x8fb22
movq 0x20(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa0(%rsp)
movl %eax, 0x9c(%rsp)
callq 0x5b0e0
jmp 0x8fafc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa0(%rsp)
movl %eax, 0x9c(%rsp)
jmp 0x8fafc
leaq 0xa8(%rsp), %rdi
callq 0x96450
cmpq $0x1, %rax
jne 0x8f940
xorl %eax, %eax
movl %eax, %esi
leaq 0xa8(%rsp), %rdi
callq 0x95bd0
movq %rax, %rdi
leaq 0x180b2d(%rip), %rsi # 0x210433
callq 0x6af30
movb %al, 0x1f(%rsp)
jmp 0x8f911
movb 0x1f(%rsp), %al
testb $0x1, %al
jne 0x8f91b
jmp 0x8f940
movq 0x28(%rsp), %rdi
movq $0x0, 0x90(%rsp)
leaq 0x90(%rsp), %rsi
callq 0xc6930
jmp 0x8f93b
jmp 0x8fadb
leaq 0xa8(%rsp), %rax
movq %rax, 0x88(%rsp)
movq 0x88(%rsp), %rdi
callq 0x672a0
movq %rax, 0x80(%rsp)
movq 0x88(%rsp), %rdi
callq 0x672d0
movq %rax, 0x78(%rsp)
leaq 0x80(%rsp), %rdi
leaq 0x78(%rsp), %rsi
callq 0x67300
testb $0x1, %al
jne 0x8f992
jmp 0x8fabf
leaq 0x80(%rsp), %rdi
callq 0x67340
movq %rax, 0x70(%rsp)
movq 0x70(%rsp), %rdi
callq 0x5a1d0
movq %rax, %rdi
callq 0x5a410
movq %rax, 0x10(%rsp)
jmp 0x8f9bd
movq 0x10(%rsp), %rax
movq %rax, 0x68(%rsp)
cmpq $0x0, 0x68(%rsp)
je 0x8f9ec
movq 0x68(%rsp), %rdi
callq 0x5aac0
movl %eax, 0xc(%rsp)
jmp 0x8f9df
movl 0xc(%rsp), %eax
cmpl $0x1, %eax
je 0x8fa9a
movb $0x1, 0x47(%rsp)
movl $0x10, %edi
callq 0x5a710
movq %rax, (%rsp)
movq 0x70(%rsp), %rdi
callq 0x5a1d0
movq %rax, %rdx
leaq 0x185aed(%rip), %rsi # 0x215500
xorl %eax, %eax
leaq 0x48(%rsp), %rdi
callq 0xf3ba0
jmp 0x8fa21
movq (%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0x5aae0
jmp 0x8fa31
movq (%rsp), %rdi
movb $0x0, 0x47(%rsp)
movq 0x21a4d7(%rip), %rsi # 0x2a9f18
movq 0x21a4c8(%rip), %rdx # 0x2a9f10
callq 0x5abb0
jmp 0x8fb39
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa0(%rsp)
movl %eax, 0x9c(%rsp)
jmp 0x8fa86
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa0(%rsp)
movl %eax, 0x9c(%rsp)
leaq 0x48(%rsp), %rdi
callq 0x5b6f8
testb $0x1, 0x47(%rsp)
jne 0x8fa8f
jmp 0x8fa98
movq (%rsp), %rdi
callq 0x5b0e0
jmp 0x8fafc
movq 0x28(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0xc6960
jmp 0x8faab
jmp 0x8faad
leaq 0x80(%rsp), %rdi
callq 0x67350
jmp 0x8f977
movq 0x28(%rsp), %rdi
movq $0x0, 0x38(%rsp)
leaq 0x38(%rsp), %rsi
callq 0xc6930
jmp 0x8fad9
jmp 0x8fadb
movb $0x1, 0xc7(%rsp)
leaq 0xa8(%rsp), %rdi
callq 0x68580
testb $0x1, 0xc7(%rsp)
jne 0x8fb15
jmp 0x8fb0b
leaq 0xa8(%rsp), %rdi
callq 0x68580
jmp 0x8fb22
movq 0x28(%rsp), %rdi
callq 0x68850
movq 0x30(%rsp), %rax
addq $0xd8, %rsp
retq
movq 0x28(%rsp), %rdi
callq 0x68850
movq 0xa0(%rsp), %rdi
callq 0x5ac70
nopl (%rax)
|
_ZL17parse_device_listRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
sub rsp, 0D8h
mov [rsp+0D8h+var_B0], rdi
mov rax, rdi
mov [rsp+0D8h+var_A8], rax
mov [rsp+0D8h+var_8], rdi
mov [rsp+0D8h+var_10], rsi
mov [rsp+0D8h+var_11], 0
call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EEC2Ev; std::vector<ggml_backend_device *>::vector(void)
mov rsi, [rsp+0D8h+var_10]
lea rdi, [rsp+0D8h+var_30]
mov edx, 2Ch ; ','
call _ZL12string_splitINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEESt6vectorIT_SaIS7_EERKS5_c; string_split<std::string>(std::string const&,char)
jmp short $+2
loc_8F82D:
lea rdi, [rsp+0D8h+var_30]
call _ZNKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5emptyEv; std::vector<std::string>::empty(void)
test al, 1
jnz short loc_8F843
jmp loc_8F8D8
loc_8F843:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rdi, rax; this
mov rax, rdi
mov [rsp+0D8h+var_B8], rax
lea rsi, aNoDevicesSpeci; "no devices specified"
call __ZNSt16invalid_argumentC1EPKc; std::invalid_argument::invalid_argument(char const*)
jmp short $+2
loc_8F866:
mov rdi, [rsp+0D8h+var_B8]; void *
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *)
call ___cxa_throw
jmp loc_8FB39
mov rcx, rax
mov eax, edx
mov [rsp+arg_98], rcx
mov [rsp+arg_94], eax
jmp loc_8FB22
mov rdi, [rsp+arg_18]; void *
mov rcx, rax
mov eax, edx
mov [rsp+arg_98], rcx
mov [rsp+arg_94], eax
call ___cxa_free_exception
jmp loc_8FAFC
mov rcx, rax
mov eax, edx
mov [rsp+arg_98], rcx
mov [rsp+arg_94], eax
jmp loc_8FAFC
loc_8F8D8:
lea rdi, [rsp+0D8h+var_30]
call _ZNKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE4sizeEv; std::vector<std::string>::size(void)
cmp rax, 1
jnz short loc_8F940
xor eax, eax
mov esi, eax
lea rdi, [rsp+0D8h+var_30]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EEixEm; std::vector<std::string>::operator[](ulong)
mov rdi, rax
lea rsi, aNone; "none"
call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*)
mov [rsp+0D8h+var_B9], al
jmp short $+2
loc_8F911:
mov al, [rsp+0D8h+var_B9]
test al, 1
jnz short loc_8F91B
jmp short loc_8F940
loc_8F91B:
mov rdi, [rsp+0D8h+var_B0]
mov [rsp+0D8h+var_48], 0
lea rsi, [rsp+0D8h+var_48]
call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE9push_backEOS1_; std::vector<ggml_backend_device *>::push_back(ggml_backend_device *&&)
jmp short $+2
loc_8F93B:
jmp loc_8FADB
loc_8F940:
lea rax, [rsp+0D8h+var_30]
mov [rsp+0D8h+var_50], rax
mov rdi, [rsp+0D8h+var_50]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5beginEv; std::vector<std::string>::begin(void)
mov [rsp+0D8h+var_58], rax
mov rdi, [rsp+0D8h+var_50]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE3endEv; std::vector<std::string>::end(void)
mov [rsp+0D8h+var_60], rax
loc_8F977:
lea rdi, [rsp+0D8h+var_58]
lea rsi, [rsp+0D8h+var_60]
call _ZN9__gnu_cxxneIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEEbRKNS_17__normal_iteratorIT_T0_EESG_; __gnu_cxx::operator!=<std::string *,std::vector<std::string>>(__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&,__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&)
test al, 1
jnz short loc_8F992
jmp loc_8FABF
loc_8F992:
lea rdi, [rsp+0D8h+var_58]
call _ZNK9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEdeEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*(void)
mov [rsp+0D8h+var_68], rax
mov rdi, [rsp+0D8h+var_68]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov rdi, rax
call _ggml_backend_dev_by_name
mov [rsp+0D8h+var_C8], rax
jmp short $+2
loc_8F9BD:
mov rax, [rsp+0D8h+var_C8]
mov [rsp+0D8h+var_70], rax
cmp [rsp+0D8h+var_70], 0
jz short loc_8F9EC
mov rdi, [rsp+0D8h+var_70]
call _ggml_backend_dev_type
mov [rsp+0D8h+var_CC], eax
jmp short $+2
loc_8F9DF:
mov eax, [rsp+0D8h+var_CC]
cmp eax, 1
jz loc_8FA9A
loc_8F9EC:
mov [rsp+0D8h+var_91], 1
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov [rsp+0D8h+var_D8], rax
mov rdi, [rsp+0D8h+var_68]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov rdx, rax
lea rsi, aInvalidDeviceS; "invalid device: %s"
xor eax, eax
lea rdi, [rsp+0D8h+var_90]
call _Z13string_formatB5cxx11PKcz; string_format(char const*,...)
jmp short $+2
loc_8FA21:
mov rdi, [rsp+0D8h+var_D8]
lea rsi, [rsp+0D8h+var_90]
call __ZNSt16invalid_argumentC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::invalid_argument::invalid_argument(std::string const&)
jmp short $+2
loc_8FA31:
mov rdi, [rsp+0D8h+var_D8]; void *
mov [rsp+0D8h+var_91], 0
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *)
call ___cxa_throw
jmp loc_8FB39
mov rcx, rax
mov eax, edx
mov [rsp+arg_98], rcx
mov [rsp+arg_94], eax
jmp short loc_8FA86
mov rcx, rax
mov eax, edx
mov [rsp+arg_98], rcx
mov [rsp+arg_94], eax
lea rdi, [rsp+arg_40]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_8FA86:
test [rsp+arg_3F], 1
jnz short loc_8FA8F
jmp short loc_8FA98
loc_8FA8F:
mov rdi, [rsp+0]; void *
call ___cxa_free_exception
loc_8FA98:
jmp short loc_8FAFC
loc_8FA9A:
mov rdi, [rsp+0D8h+var_B0]
lea rsi, [rsp+0D8h+var_70]
call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE9push_backERKS1_; std::vector<ggml_backend_device *>::push_back(ggml_backend_device * const&)
jmp short $+2
loc_8FAAB:
jmp short $+2
loc_8FAAD:
lea rdi, [rsp+0D8h+var_58]
call _ZN9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEppEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(void)
jmp loc_8F977
loc_8FABF:
mov rdi, [rsp+0D8h+var_B0]
mov [rsp+0D8h+var_A0], 0
lea rsi, [rsp+0D8h+var_A0]
call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE9push_backEOS1_; std::vector<ggml_backend_device *>::push_back(ggml_backend_device *&&)
jmp short $+2
loc_8FAD9:
jmp short $+2
loc_8FADB:
mov [rsp+0D8h+var_11], 1
lea rdi, [rsp+0D8h+var_30]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
test [rsp+0D8h+var_11], 1
jnz short loc_8FB15
jmp short loc_8FB0B
loc_8FAFC:
lea rdi, [rsp+arg_A0]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
jmp short loc_8FB22
loc_8FB0B:
mov rdi, [rsp+0D8h+var_B0]
call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EED2Ev; std::vector<ggml_backend_device *>::~vector()
loc_8FB15:
mov rax, [rsp+0D8h+var_A8]
add rsp, 0D8h
retn
loc_8FB22:
mov rdi, [rsp+arg_20]
call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EED2Ev; std::vector<ggml_backend_device *>::~vector()
mov rdi, [rsp+arg_98]
call __Unwind_Resume
loc_8FB39:
nop dword ptr [rax+00000000h]
|
long long * parse_device_list(long long *a1, long long a2)
{
long long v2; // rax
long long v3; // rax
int v4; // eax
int v5; // ecx
int v6; // r8d
int v7; // r9d
void *v9; // [rsp+0h] [rbp-D8h]
std::invalid_argument *exception; // [rsp+20h] [rbp-B8h]
long long v11; // [rsp+38h] [rbp-A0h] BYREF
char v12; // [rsp+47h] [rbp-91h]
_BYTE v13[32]; // [rsp+48h] [rbp-90h] BYREF
long long v14; // [rsp+68h] [rbp-70h] BYREF
long long v15; // [rsp+70h] [rbp-68h]
long long v16; // [rsp+78h] [rbp-60h] BYREF
_QWORD v17[2]; // [rsp+80h] [rbp-58h] BYREF
_QWORD v18[3]; // [rsp+90h] [rbp-48h] BYREF
long long v19[3]; // [rsp+A8h] [rbp-30h] BYREF
char v20; // [rsp+C7h] [rbp-11h]
long long v21; // [rsp+C8h] [rbp-10h]
long long *v22; // [rsp+D0h] [rbp-8h]
v22 = a1;
v21 = a2;
v20 = 0;
std::vector<ggml_backend_device *>::vector((long long)a1);
string_split<std::string>((long long)v19, a2, 44);
if ( (std::vector<std::string>::empty((long long)v19) & 1) != 0 )
{
exception = (std::invalid_argument *)__cxa_allocate_exception(0x10uLL);
std::invalid_argument::invalid_argument(exception, "no devices specified");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::invalid_argument,
(void (*)(void *))&std::invalid_argument::~invalid_argument);
}
if ( std::vector<std::string>::size(v19) == 1
&& (v2 = std::vector<std::string>::operator[](v19, 0LL), std::operator==<char>(v2, (long long)"none")) )
{
v18[0] = 0LL;
std::vector<ggml_backend_device *>::push_back(a1, v18);
}
else
{
v17[1] = v19;
v17[0] = std::vector<std::string>::begin((long long)v19);
v16 = std::vector<std::string>::end((long long)v19);
while ( __gnu_cxx::operator!=<std::string *,std::vector<std::string>>((long long)v17, (long long)&v16) )
{
v15 = __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*((long long)v17);
v3 = std::string::c_str(v15);
v14 = ggml_backend_dev_by_name(v3);
if ( !v14 || (unsigned int)ggml_backend_dev_type(v14) != 1 )
{
v9 = __cxa_allocate_exception(0x10uLL);
v4 = std::string::c_str(v15);
string_format[abi:cxx11]((unsigned int)v13, (unsigned int)"invalid device: %s", v4, v5, v6, v7);
std::invalid_argument::invalid_argument(v9, v13);
v12 = 0;
__cxa_throw(
v9,
(struct type_info *)&`typeinfo for'std::invalid_argument,
(void (*)(void *))&std::invalid_argument::~invalid_argument);
}
std::vector<ggml_backend_device *>::push_back(a1, &v14);
__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(v17);
}
v11 = 0LL;
std::vector<ggml_backend_device *>::push_back(a1, &v11);
}
v20 = 1;
std::vector<std::string>::~vector(v19);
if ( (v20 & 1) == 0 )
std::vector<ggml_backend_device *>::~vector(a1);
return a1;
}
|
parse_device_list:
SUB RSP,0xd8
MOV qword ptr [RSP + 0x28],RDI
MOV RAX,RDI
MOV qword ptr [RSP + 0x30],RAX
MOV qword ptr [RSP + 0xd0],RDI
MOV qword ptr [RSP + 0xc8],RSI
MOV byte ptr [RSP + 0xc7],0x0
CALL 0x00167ba0
MOV RSI,qword ptr [RSP + 0xc8]
LAB_0018f819:
LEA RDI,[RSP + 0xa8]
MOV EDX,0x2c
CALL 0x0018b400
LAB_0018f82b:
JMP 0x0018f82d
LAB_0018f82d:
LEA RDI,[RSP + 0xa8]
CALL 0x00167250
TEST AL,0x1
JNZ 0x0018f843
JMP 0x0018f8d8
LAB_0018f843:
MOV EDI,0x10
CALL 0x0015a710
MOV RDI,RAX
MOV RAX,RDI
MOV qword ptr [RSP + 0x20],RAX
LAB_0018f858:
LEA RSI,[0x3154eb]
CALL 0x0015a360
JMP 0x0018f866
LAB_0018f866:
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [0x003a9f18]
MOV RDX,qword ptr [0x003a9f10]
CALL 0x0015abb0
LAB_0018f8d8:
LEA RDI,[RSP + 0xa8]
CALL 0x00196450
CMP RAX,0x1
JNZ 0x0018f940
XOR EAX,EAX
MOV ESI,EAX
LEA RDI,[RSP + 0xa8]
CALL 0x00195bd0
MOV RDI,RAX
LAB_0018f8ff:
LEA RSI,[0x310433]
CALL 0x0016af30
MOV byte ptr [RSP + 0x1f],AL
JMP 0x0018f911
LAB_0018f911:
MOV AL,byte ptr [RSP + 0x1f]
TEST AL,0x1
JNZ 0x0018f91b
JMP 0x0018f940
LAB_0018f91b:
MOV RDI,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x90],0x0
LEA RSI,[RSP + 0x90]
CALL 0x001c6930
JMP 0x0018f93b
LAB_0018f93b:
JMP 0x0018fadb
LAB_0018f940:
LEA RAX,[RSP + 0xa8]
MOV qword ptr [RSP + 0x88],RAX
MOV RDI,qword ptr [RSP + 0x88]
CALL 0x001672a0
MOV qword ptr [RSP + 0x80],RAX
MOV RDI,qword ptr [RSP + 0x88]
CALL 0x001672d0
MOV qword ptr [RSP + 0x78],RAX
LAB_0018f977:
LEA RDI,[RSP + 0x80]
LEA RSI,[RSP + 0x78]
CALL 0x00167300
TEST AL,0x1
JNZ 0x0018f992
JMP 0x0018fabf
LAB_0018f992:
LEA RDI,[RSP + 0x80]
CALL 0x00167340
MOV qword ptr [RSP + 0x70],RAX
MOV RDI,qword ptr [RSP + 0x70]
CALL 0x0015a1d0
MOV RDI,RAX
CALL 0x0015a410
MOV qword ptr [RSP + 0x10],RAX
JMP 0x0018f9bd
LAB_0018f9bd:
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x68],RAX
CMP qword ptr [RSP + 0x68],0x0
JZ 0x0018f9ec
MOV RDI,qword ptr [RSP + 0x68]
CALL 0x0015aac0
LAB_0018f9d9:
MOV dword ptr [RSP + 0xc],EAX
JMP 0x0018f9df
LAB_0018f9df:
MOV EAX,dword ptr [RSP + 0xc]
CMP EAX,0x1
JZ 0x0018fa9a
LAB_0018f9ec:
MOV byte ptr [RSP + 0x47],0x1
MOV EDI,0x10
CALL 0x0015a710
MOV qword ptr [RSP],RAX
MOV RDI,qword ptr [RSP + 0x70]
CALL 0x0015a1d0
MOV RDX,RAX
LAB_0018fa0c:
LEA RSI,[0x315500]
XOR EAX,EAX
LEA RDI,[RSP + 0x48]
CALL 0x001f3ba0
JMP 0x0018fa21
LAB_0018fa21:
MOV RDI,qword ptr [RSP]
LEA RSI,[RSP + 0x48]
CALL 0x0015aae0
JMP 0x0018fa31
LAB_0018fa31:
MOV RDI,qword ptr [RSP]
MOV byte ptr [RSP + 0x47],0x0
MOV RSI,qword ptr [0x003a9f18]
MOV RDX,qword ptr [0x003a9f10]
CALL 0x0015abb0
LAB_0018fa9a:
MOV RDI,qword ptr [RSP + 0x28]
LEA RSI,[RSP + 0x68]
CALL 0x001c6960
JMP 0x0018faab
LAB_0018faab:
JMP 0x0018faad
LAB_0018faad:
LEA RDI,[RSP + 0x80]
CALL 0x00167350
JMP 0x0018f977
LAB_0018fabf:
MOV RDI,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x38],0x0
LEA RSI,[RSP + 0x38]
CALL 0x001c6930
LAB_0018fad7:
JMP 0x0018fad9
LAB_0018fad9:
JMP 0x0018fadb
LAB_0018fadb:
MOV byte ptr [RSP + 0xc7],0x1
LEA RDI,[RSP + 0xa8]
CALL 0x00168580
TEST byte ptr [RSP + 0xc7],0x1
JNZ 0x0018fb15
JMP 0x0018fb0b
LAB_0018fb0b:
MOV RDI,qword ptr [RSP + 0x28]
CALL 0x00168850
LAB_0018fb15:
MOV RAX,qword ptr [RSP + 0x30]
ADD RSP,0xd8
RET
|
/* parse_device_list(std::__cxx11::string const&) */
string * parse_device_list(string *param_1)
{
bool bVar1;
int iVar2;
ulong uVar3;
long lVar4;
string *psVar5;
int8 uVar6;
invalid_argument *piVar7;
char in_SIL;
ggml_backend_device *local_a0;
int1 local_91;
string local_90 [32];
ggml_backend_device *local_70;
int8 local_68;
int8 local_60;
int8 local_58;
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *local_50;
ggml_backend_device *local_48 [3];
string local_30 [31];
byte local_11;
char local_10;
string *local_8;
local_11 = 0;
local_8 = param_1;
local_10 = in_SIL;
std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::vector
((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1);
/* try { // try from 0018f819 to 0018f82a has its CatchHandler @ 0018f883 */
string_split<std::__cxx11::string>(local_30,local_10);
uVar3 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::empty
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_30);
if ((uVar3 & 1) != 0) {
piVar7 = (invalid_argument *)__cxa_allocate_exception(0x10);
/* try { // try from 0018f858 to 0018f863 has its CatchHandler @ 0018f89c */
std::invalid_argument::invalid_argument(piVar7,"no devices specified");
/* try { // try from 0018f866 to 0018f87d has its CatchHandler @ 0018f8bf */
/* WARNING: Subroutine does not return */
__cxa_throw(piVar7,PTR_typeinfo_003a9f18,PTR__invalid_argument_003a9f10);
}
lVar4 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::size
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_30);
if (lVar4 == 1) {
psVar5 = (string *)
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::operator[]
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)
local_30,0);
/* try { // try from 0018f8ff to 0018f9d8 has its CatchHandler @ 0018f8bf */
bVar1 = std::operator==(psVar5,"none");
if (bVar1) {
local_48[0] = (ggml_backend_device *)0x0;
std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::push_back
((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1,
local_48);
goto LAB_0018fadb;
}
}
local_50 = (vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_30;
local_58 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::begin(local_50)
;
local_60 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::end(local_50);
while (bVar1 = __gnu_cxx::operator!=
((__normal_iterator *)&local_58,(__normal_iterator *)&local_60), bVar1) {
local_68 = __gnu_cxx::
__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::operator*((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_58);
uVar6 = std::__cxx11::string::c_str();
local_70 = (ggml_backend_device *)ggml_backend_dev_by_name(uVar6);
if ((local_70 == (ggml_backend_device *)0x0) ||
(iVar2 = ggml_backend_dev_type(local_70), iVar2 != 1)) {
local_91 = 1;
piVar7 = (invalid_argument *)__cxa_allocate_exception(0x10);
uVar6 = std::__cxx11::string::c_str();
/* try { // try from 0018fa0c to 0018fa1e has its CatchHandler @ 0018fa52 */
string_format_abi_cxx11_((char *)local_90,"invalid device: %s",uVar6);
/* try { // try from 0018fa21 to 0018fa4c has its CatchHandler @ 0018fa68 */
std::invalid_argument::invalid_argument(piVar7,local_90);
local_91 = 0;
/* WARNING: Subroutine does not return */
__cxa_throw(piVar7,PTR_typeinfo_003a9f18,PTR__invalid_argument_003a9f10);
}
/* try { // try from 0018fa9a to 0018fad6 has its CatchHandler @ 0018f8bf */
std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::push_back
((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1,
&local_70);
__gnu_cxx::
__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::operator++((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_58);
}
local_a0 = (ggml_backend_device *)0x0;
std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::push_back
((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1,&local_a0)
;
LAB_0018fadb:
local_11 = 1;
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_30);
if ((local_11 & 1) == 0) {
std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::~vector
((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1);
}
return param_1;
}
|
|
64,815 |
inline_mysql_mutex_init
|
eloqsql/include/mysql/psi/mysql_thread.h
|
static inline int inline_mysql_mutex_init(
#ifdef HAVE_PSI_MUTEX_INTERFACE
PSI_mutex_key key,
#endif
mysql_mutex_t *that,
const pthread_mutexattr_t *attr
#ifdef SAFE_MUTEX
, const char *src_name, const char *src_file, uint src_line
#endif
)
{
#ifdef HAVE_PSI_MUTEX_INTERFACE
that->m_psi= PSI_MUTEX_CALL(init_mutex)(key, &that->m_mutex);
#else
that->m_psi= NULL;
#endif
#ifdef COROUTINE_ENABLED
that->l.data= that;
that->l.prev= that->l.next= NULL;
#endif
#ifdef SAFE_MUTEX
return safe_mutex_init(&that->m_mutex, attr, src_name, src_file, src_line);
#else
return pthread_mutex_init(&that->m_mutex, attr);
#endif
}
|
O0
|
c
|
inline_mysql_mutex_init:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
leaq 0x1ca626(%rip), %rax # 0x238f90
movq (%rax), %rax
movq 0x40(%rax), %rax
movl -0x4(%rbp), %edi
movq -0x10(%rbp), %rsi
callq *%rax
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x40(%rax)
movq -0x10(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x38(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x30(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x28(%rax)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x28520
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
|
inline_mysql_mutex_init_0:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_4], edi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+40h]
mov edi, [rbp+var_4]
mov rsi, [rbp+var_10]
call rax
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+40h], rcx
mov rcx, [rbp+var_10]
mov rax, [rbp+var_10]
mov [rax+38h], rcx
mov rax, [rbp+var_10]
mov qword ptr [rax+30h], 0
mov rax, [rbp+var_10]
mov qword ptr [rax+28h], 0
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call _pthread_mutex_init
add rsp, 20h
pop rbp
retn
|
long long inline_mysql_mutex_init_0(unsigned int a1, _QWORD *a2, long long a3)
{
a2[8] = ((long long ( *)(_QWORD, _QWORD *))PSI_server[8])(a1, a2);
a2[7] = a2;
a2[6] = 0LL;
a2[5] = 0LL;
return pthread_mutex_init(a2, a3);
}
|
inline_mysql_mutex_init:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV dword ptr [RBP + -0x4],EDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
LEA RAX,[0x338f90]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x40]
MOV EDI,dword ptr [RBP + -0x4]
MOV RSI,qword ptr [RBP + -0x10]
CALL RAX
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x40],RCX
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x38],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x30],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x28],0x0
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x00128520
ADD RSP,0x20
POP RBP
RET
|
void inline_mysql_mutex_init
(int4 param_1,pthread_mutex_t *param_2,pthread_mutexattr_t *param_3)
{
int8 uVar1;
uVar1 = (**(code **)(PSI_server + 0x40))(param_1,param_2);
*(int8 *)((long)param_2 + 0x40) = uVar1;
*(pthread_mutex_t **)((long)param_2 + 0x38) = param_2;
*(int8 *)((long)param_2 + 0x30) = 0;
param_2[1].__align = 0;
pthread_mutex_init(param_2,param_3);
return;
}
|
|
64,816 |
raise_to_z_div_by_2
|
corpus-core[P]colibri-stateless/build_O1/_deps/blst-src/src/pairing.c
|
static void raise_to_z_div_by_2(vec384fp12 ret, const vec384fp12 a)
{
cyclotomic_sqr_fp12(ret, a); /* 0x2 */
mul_n_sqr(ret, a, 2); /* ..0xc */
mul_n_sqr(ret, a, 3); /* ..0x68 */
mul_n_sqr(ret, a, 9); /* ..0xd200 */
mul_n_sqr(ret, a, 32); /* ..0xd20100000000 */
mul_n_sqr(ret, a, 16-1); /* ..0x6900800000008000 */
conjugate_fp12(ret); /* account for z being negative */
}
|
O1
|
c
|
raise_to_z_div_by_2:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
callq 0x1f433
movl $0x2, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x28eb2
movl $0x3, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x28eb2
movl $0x9, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x28eb2
movl $0x20, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x28eb2
movl $0xf, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x28eb2
addq $0x120, %rbx # imm = 0x120
movq %rbx, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x28139
|
raise_to_z_div_by_2:
push rbp
mov rbp, rsp
push r14
push rbx
mov r14, rsi
mov rbx, rdi
call cyclotomic_sqr_fp12
mov edx, 2
mov rdi, rbx
mov rsi, r14
call mul_n_sqr
mov edx, 3
mov rdi, rbx
mov rsi, r14
call mul_n_sqr
mov edx, 9
mov rdi, rbx
mov rsi, r14
call mul_n_sqr
mov edx, 20h ; ' '
mov rdi, rbx
mov rsi, r14
call mul_n_sqr
mov edx, 0Fh
mov rdi, rbx
mov rsi, r14
call mul_n_sqr
add rbx, 120h
mov rdi, rbx
mov rsi, rbx
pop rbx
pop r14
pop rbp
jmp neg_fp6
|
long long raise_to_z_div_by_2(long long a1, long long a2)
{
cyclotomic_sqr_fp12(a1, a2);
mul_n_sqr(a1, a2, 2LL);
mul_n_sqr(a1, a2, 3LL);
mul_n_sqr(a1, a2, 9LL);
mul_n_sqr(a1, a2, 32LL);
mul_n_sqr(a1, a2, 15LL);
return neg_fp6(a1 + 288, a1 + 288);
}
|
raise_to_z_div_by_2:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV R14,RSI
MOV RBX,RDI
CALL 0x0011f433
MOV EDX,0x2
MOV RDI,RBX
MOV RSI,R14
CALL 0x00128eb2
MOV EDX,0x3
MOV RDI,RBX
MOV RSI,R14
CALL 0x00128eb2
MOV EDX,0x9
MOV RDI,RBX
MOV RSI,R14
CALL 0x00128eb2
MOV EDX,0x20
MOV RDI,RBX
MOV RSI,R14
CALL 0x00128eb2
MOV EDX,0xf
MOV RDI,RBX
MOV RSI,R14
CALL 0x00128eb2
ADD RBX,0x120
MOV RDI,RBX
MOV RSI,RBX
POP RBX
POP R14
POP RBP
JMP 0x00128139
|
void raise_to_z_div_by_2(long param_1,int8 param_2)
{
cyclotomic_sqr_fp12();
mul_n_sqr(param_1,param_2,2);
mul_n_sqr(param_1,param_2,3);
mul_n_sqr(param_1,param_2,9);
mul_n_sqr(param_1,param_2,0x20);
mul_n_sqr(param_1,param_2,0xf);
neg_fp6(param_1 + 0x120,param_1 + 0x120);
return;
}
|
|
64,817 |
void nlohmann::json_abi_v3_11_3::detail::get_arithmetic_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>, double, 0>(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&, double&)
|
monkey531[P]llama/common/json.hpp
|
void get_arithmetic_value(const BasicJsonType& j, ArithmeticType& val)
{
switch (static_cast<value_t>(j))
{
case value_t::number_unsigned:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_unsigned_t*>());
break;
}
case value_t::number_integer:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_integer_t*>());
break;
}
case value_t::number_float:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_float_t*>());
break;
}
case value_t::null:
case value_t::object:
case value_t::array:
case value_t::string:
case value_t::boolean:
case value_t::binary:
case value_t::discarded:
default:
JSON_THROW(type_error::create(302, concat("type must be number, but is ", j.type_name()), &j));
}
}
|
O0
|
cpp
|
void nlohmann::json_abi_v3_11_3::detail::get_arithmetic_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>, double, 0>(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&, double&):
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq %rsi, 0x48(%rsp)
movq 0x50(%rsp), %rdi
callq 0x11a2a0
movzbl %al, %ecx
movq %rcx, 0x8(%rsp)
subb $0x9, %al
ja 0x11b6b6
movq 0x8(%rsp), %rax
leaq 0xfb5e8(%rip), %rcx # 0x216c1c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq 0x50(%rsp), %rdi
callq 0x11a2b0
movq (%rax), %xmm0
movaps 0xfb55e(%rip), %xmm1 # 0x216bb0
punpckldq %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movapd 0xfb562(%rip), %xmm1 # 0x216bc0
subpd %xmm1, %xmm0
movaps %xmm0, %xmm1
unpckhpd %xmm0, %xmm0 # xmm0 = xmm0[1,1]
addsd %xmm1, %xmm0
movq 0x48(%rsp), %rax
movsd %xmm0, (%rax)
jmp 0x11b764
movq 0x50(%rsp), %rdi
callq 0x11a2d0
cvtsi2sdq (%rax), %xmm0
movq 0x48(%rsp), %rax
movsd %xmm0, (%rax)
jmp 0x11b764
movq 0x50(%rsp), %rdi
callq 0x11a2f0
movsd (%rax), %xmm0
movq 0x48(%rsp), %rax
movsd %xmm0, (%rax)
jmp 0x11b764
jmp 0x11b6b6
movb $0x1, 0x13(%rsp)
movl $0x20, %edi
callq 0x5a710
movq %rax, (%rsp)
movq 0x50(%rsp), %rdi
callq 0xbe8b0
movq %rax, 0x20(%rsp)
leaq 0xfcce0(%rip), %rsi # 0x2183bf
leaq 0x28(%rsp), %rdi
leaq 0x20(%rsp), %rdx
callq 0x11a4c0
jmp 0x11b6f0
movq (%rsp), %rdi
movq 0x50(%rsp), %rcx
movl $0x12e, %esi # imm = 0x12E
leaq 0x28(%rsp), %rdx
callq 0x11a310
jmp 0x11b70a
movq (%rsp), %rdi
movb $0x0, 0x13(%rsp)
leaq 0x18c65e(%rip), %rsi # 0x2a7d78
leaq -0x5cdc1(%rip), %rdx # 0xbe960
callq 0x5abb0
jmp 0x11b773
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
jmp 0x11b750
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
leaq 0x28(%rsp), %rdi
callq 0x5b6f8
testb $0x1, 0x13(%rsp)
jne 0x11b759
jmp 0x11b762
movq (%rsp), %rdi
callq 0x5b0e0
jmp 0x11b769
addq $0x58, %rsp
retq
movq 0x18(%rsp), %rdi
callq 0x5ac70
nopw %cs:(%rax,%rax)
nopl (%rax)
|
_ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_:
sub rsp, 58h
mov qword ptr [rsp+58h+var_8], rdi; char
mov qword ptr [rsp+58h+var_10], rsi; int
mov rdi, qword ptr [rsp+58h+var_8]
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEcvNS0_6detail7value_tEEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::operator nlohmann::json_abi_v3_11_3::detail::value_t(void)
movzx ecx, al
mov qword ptr [rsp+58h+var_50], rcx; int
sub al, 9; switch 10 cases
ja def_11B63B; jumptable 000000000011B63B default case
mov rax, qword ptr [rsp+58h+var_50]
lea rcx, jpt_11B63B
movsxd rax, ds:(jpt_11B63B - 216C1Ch)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_11B63D:
mov rdi, qword ptr [rsp+58h+var_8]; jumptable 000000000011B63B case 6
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE7get_ptrIPKmTnNSt9enable_ifIXaasr3std10is_pointerIT_EE5valuesr3std8is_constINSt14remove_pointerISI_E4typeEEE5valueEiE4typeELi0EEEDTcldtclL_ZSt7declvalIRKSD_EDTcl9__declvalISI_ELi0EEEvEE12get_impl_ptrclsr3stdE7declvalISI_EEEEv
movq xmm0, qword ptr [rax]
movaps xmm1, cs:xmmword_216BB0
punpckldq xmm0, xmm1
movapd xmm1, cs:xmmword_216BC0
subpd xmm0, xmm1
movaps xmm1, xmm0
unpckhpd xmm0, xmm0
addsd xmm0, xmm1
mov rax, qword ptr [rsp+58h+var_10]
movsd qword ptr [rax], xmm0
jmp loc_11B764
loc_11B67B:
mov rdi, qword ptr [rsp+58h+var_8]; jumptable 000000000011B63B case 5
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE7get_ptrIPKlTnNSt9enable_ifIXaasr3std10is_pointerIT_EE5valuesr3std8is_constINSt14remove_pointerISI_E4typeEEE5valueEiE4typeELi0EEEDTcldtclL_ZSt7declvalIRKSD_EDTcl9__declvalISI_ELi0EEEvEE12get_impl_ptrclsr3stdE7declvalISI_EEEEv
cvtsi2sd xmm0, qword ptr [rax]
mov rax, qword ptr [rsp+58h+var_10]
movsd qword ptr [rax], xmm0
jmp loc_11B764
loc_11B698:
mov rdi, qword ptr [rsp+58h+var_8]; jumptable 000000000011B63B case 7
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE7get_ptrIPKdTnNSt9enable_ifIXaasr3std10is_pointerIT_EE5valuesr3std8is_constINSt14remove_pointerISI_E4typeEEE5valueEiE4typeELi0EEEDTcldtclL_ZSt7declvalIRKSD_EDTcl9__declvalISI_ELi0EEEvEE12get_impl_ptrclsr3stdE7declvalISI_EEEEv
movsd xmm0, qword ptr [rax]
mov rax, qword ptr [rsp+58h+var_10]
movsd qword ptr [rax], xmm0
jmp loc_11B764
loc_11B6B4:
jmp short $+2; jumptable 000000000011B63B cases 0-4,8,9
def_11B63B:
mov [rsp+58h+var_45], 1; jumptable 000000000011B63B default case
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov [rsp+58h+var_58], rax; int
mov rdi, qword ptr [rsp+58h+var_8]
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void)
mov qword ptr [rsp+58h+var_38], rax; int
lea rsi, aTypeMustBeNumb; "type must be number, but is "
lea rdi, [rsp+58h+var_30]
lea rdx, [rsp+58h+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* &&)
jmp short $+2
loc_11B6F0:
mov rdi, [rsp+58h+var_58]; int
mov rcx, qword ptr [rsp+58h+var_8]
mov esi, 12Eh
lea rdx, [rsp+58h+var_30]
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
jmp short $+2
loc_11B70A:
mov rdi, [rsp+58h+var_58]; void *
mov [rsp+58h+var_45], 0
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail10type_errorD2Ev; void (*)(void *)
call ___cxa_throw
jmp short loc_11B773
mov rcx, rax
mov eax, edx
mov [rsp+arg_10], rcx
mov [rsp+arg_C], eax
jmp short loc_11B750
mov rcx, rax
mov eax, edx
mov [rsp+arg_10], rcx
mov [rsp+arg_C], eax
lea rdi, [rsp+arg_20]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_11B750:
test [rsp+arg_B], 1
jnz short loc_11B759
jmp short loc_11B762
loc_11B759:
mov rdi, [rsp+0]; void *
call ___cxa_free_exception
loc_11B762:
jmp short loc_11B769
loc_11B764:
add rsp, 58h
retn
loc_11B769:
mov rdi, [rsp+arg_10]
call __Unwind_Resume
loc_11B773:
nop word ptr [rax+rax+00000000h]
nop dword ptr [rax]
|
long long ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_(
long long a1,
long long a2)
{
__m128d v2; // xmm1
long long result; // rax
double v4; // xmm0_8
long long v5; // xmm0_8
nlohmann::json_abi_v3_11_3::detail::type_error *exception; // [rsp+0h] [rbp-58h]
int v7[2]; // [rsp+20h] [rbp-38h] BYREF
_BYTE v8[32]; // [rsp+28h] [rbp-30h] BYREF
int v9[2]; // [rsp+48h] [rbp-10h]
char v10[8]; // [rsp+50h] [rbp-8h]
*(_QWORD *)v10 = a1;
*(_QWORD *)v9 = a2;
switch ( 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 nlohmann::json_abi_v3_11_3::detail::value_t(a1) )
{
case 5:
v4 = (double)(int)*(_QWORD *)ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE7get_ptrIPKlTnNSt9enable_ifIXaasr3std10is_pointerIT_EE5valuesr3std8is_constINSt14remove_pointerISI_E4typeEEE5valueEiE4typeELi0EEEDTcldtclL_ZSt7declvalIRKSD_EDTcl9__declvalISI_ELi0EEEvEE12get_impl_ptrclsr3stdE7declvalISI_EEEEv(*(long long *)v10);
result = *(_QWORD *)v9;
**(double **)v9 = v4;
break;
case 6:
v2 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32(
_mm_loadl_epi64((const __m128i *)ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE7get_ptrIPKmTnNSt9enable_ifIXaasr3std10is_pointerIT_EE5valuesr3std8is_constINSt14remove_pointerISI_E4typeEEE5valueEiE4typeELi0EEEDTcldtclL_ZSt7declvalIRKSD_EDTcl9__declvalISI_ELi0EEEvEE12get_impl_ptrclsr3stdE7declvalISI_EEEEv(*(long long *)v10)),
(__m128i)xmmword_216BB0),
(__m128d)xmmword_216BC0);
result = *(_QWORD *)v9;
**(double **)v9 = _mm_unpackhi_pd(v2, v2).m128d_f64[0] + v2.m128d_f64[0];
break;
case 7:
v5 = *(_QWORD *)ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE7get_ptrIPKdTnNSt9enable_ifIXaasr3std10is_pointerIT_EE5valuesr3std8is_constINSt14remove_pointerISI_E4typeEEE5valueEiE4typeELi0EEEDTcldtclL_ZSt7declvalIRKSD_EDTcl9__declvalISI_ELi0EEEvEE12get_impl_ptrclsr3stdE7declvalISI_EEEEv(*(long long *)v10);
result = *(_QWORD *)v9;
**(_QWORD **)v9 = v5;
break;
default:
exception = (nlohmann::json_abi_v3_11_3::detail::type_error *)__cxa_allocate_exception(0x20uLL);
*(_QWORD *)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>::type_name(*(_BYTE **)v10);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(
(long long)v8,
(long long)"type must be number, but is ",
(nlohmann::json_abi_v3_11_3::detail **)v7);
ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_(
exception,
302,
(long long)v8,
*(long long *)v10);
__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::type_error::~type_error);
}
return result;
}
| |||
64,818 |
void nlohmann::json_abi_v3_11_3::detail::get_arithmetic_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>, double, 0>(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&, double&)
|
monkey531[P]llama/common/json.hpp
|
void get_arithmetic_value(const BasicJsonType& j, ArithmeticType& val)
{
switch (static_cast<value_t>(j))
{
case value_t::number_unsigned:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_unsigned_t*>());
break;
}
case value_t::number_integer:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_integer_t*>());
break;
}
case value_t::number_float:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_float_t*>());
break;
}
case value_t::null:
case value_t::object:
case value_t::array:
case value_t::string:
case value_t::boolean:
case value_t::binary:
case value_t::discarded:
default:
JSON_THROW(type_error::create(302, concat("type must be number, but is ", j.type_name()), &j));
}
}
|
O3
|
cpp
|
void nlohmann::json_abi_v3_11_3::detail::get_arithmetic_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>, double, 0>(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&, double&):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %r14
movzbl (%rdi), %eax
cmpl $0x5, %eax
je 0x8b07a
cmpl $0x7, %eax
je 0x8b080
cmpl $0x6, %eax
jne 0x8b092
movq 0x8(%r14), %rax
jmp 0x8b086
cvttsd2si 0x8(%r14), %rax
movq %rax, (%rsi)
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movl $0x20, %edi
callq 0x1b480
movq %rax, %rbx
movq %r14, %rdi
callq 0x63c50
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
leaq 0x6990e(%rip), %rsi # 0xf49c4
leaq 0x10(%rsp), %rdi
callq 0x8b2f7
movb $0x1, %bpl
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
movl $0x12e, %esi # imm = 0x12E
movq %r14, %rcx
callq 0x8b128
xorl %ebp, %ebp
leaq 0xa3e67(%rip), %rsi # 0x12ef48
leaq -0x2b262(%rip), %rdx # 0x5fe86
movq %rbx, %rdi
callq 0x1c040
movq %rax, %r14
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x8b10e
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x1b930
testb %bpl, %bpl
jne 0x8b118
jmp 0x8b120
movq %rax, %r14
movq %rbx, %rdi
callq 0x1b6c0
movq %r14, %rdi
callq 0x1c0d0
|
_ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_:
push rbp; char
push r14; int
push rbx; __int64
sub rsp, 30h
mov r14, rdi
movzx eax, byte ptr [rdi]
cmp eax, 5
jz short loc_8B07A
cmp eax, 7
jz short loc_8B080
cmp eax, 6
jnz short loc_8B092
loc_8B07A:
mov rax, [r14+8]
jmp short loc_8B086
loc_8B080:
cvttsd2si rax, qword ptr [r14+8]
loc_8B086:
mov [rsi], rax
add rsp, 30h
pop rbx
pop r14
pop rbp
retn
loc_8B092:
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, aTypeMustBeNumb; "type must be number, but is "
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, 12Eh; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+48h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_8B10E
mov rsi, [rsp+48h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8B10E:
test bpl, bpl
jnz short loc_8B118
jmp short loc_8B120
mov r14, rax
loc_8B118:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_8B120:
mov rdi, r14
call __Unwind_Resume
|
_ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV R14,RDI
MOVZX EAX,byte ptr [RDI]
CMP EAX,0x5
JZ 0x0018b07a
CMP EAX,0x7
JZ 0x0018b080
CMP EAX,0x6
JNZ 0x0018b092
LAB_0018b07a:
MOV RAX,qword ptr [R14 + 0x8]
JMP 0x0018b086
LAB_0018b080:
CVTTSD2SI RAX,qword ptr [R14 + 0x8]
LAB_0018b086:
MOV qword ptr [RSI],RAX
ADD RSP,0x30
POP RBX
POP R14
POP RBP
RET
LAB_0018b092:
MOV EDI,0x20
CALL 0x0011b480
MOV RBX,RAX
MOV RDI,R14
CALL 0x00163c50
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],RAX
LAB_0018b0af:
LEA RSI,[0x1f49c4]
LEA RDI,[RSP + 0x10]
CALL 0x0018b2f7
MOV BPL,0x1
LAB_0018b0c3:
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
MOV ESI,0x12e
MOV RCX,R14
CALL 0x0018b128
XOR EBP,EBP
LEA RSI,[0x22ef48]
LEA RDX,[0x15fe86]
MOV RDI,RBX
CALL 0x0011c040
|
void _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_
(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,long *param_2)
{
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
bVar1;
long lVar2;
int8 uVar3;
char *local_40;
detail local_38 [32];
bVar1 = *param_1;
if (bVar1 != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x5) {
if (bVar1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x7) {
lVar2 = (long)*(double *)(param_1 + 8);
goto LAB_0018b086;
}
if (bVar1 != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x6) {
uVar3 = __cxa_allocate_exception(0x20);
local_40 = (char *)nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::type_name(param_1);
/* try { // try from 0018b0af to 0018b0bf has its CatchHandler @ 0018b115 */
nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[29],char_const*>
(local_38,"type must be number, but is ",&local_40);
/* try { // try from 0018b0c3 to 0018b0ef has its CatchHandler @ 0018b0f0 */
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
(uVar3,0x12e,local_38,param_1);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar3,&nlohmann::json_abi_v3_11_3::detail::type_error::typeinfo,
nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
}
lVar2 = *(long *)(param_1 + 8);
LAB_0018b086:
*param_2 = lVar2;
return;
}
|
||
64,819 |
free_block
|
eloqsql/storage/maria/ma_pagecache.c
|
static my_bool free_block(PAGECACHE *pagecache, PAGECACHE_BLOCK_LINK *block,
my_bool abort_if_pinned)
{
uint status= block->status;
KEYCACHE_THREAD_TRACE("free block");
KEYCACHE_DBUG_PRINT("free_block",
("block: %u hash_link %p",
PCBLOCK_NUMBER(pagecache, block),
block->hash_link));
mysql_mutex_assert_owner(&pagecache->cache_lock);
if (block->hash_link)
{
/*
While waiting for readers to finish, new readers might request the
block. But since we set block->status|= PCBLOCK_REASSIGNED, they
will wait on block->wqueue[COND_FOR_SAVED]. They must be signaled
later.
*/
block->status|= PCBLOCK_REASSIGNED;
wait_for_readers(pagecache, block);
if (unlikely(abort_if_pinned) && unlikely(block->pins))
{
/*
Block got pinned while waiting for readers.
This can only happens when called from flush_pagecache_blocks_int()
when flushing blocks as part of prepare for maria_close() or from
flush_cached_blocks()
*/
block->status&= ~PCBLOCK_REASSIGNED;
unreg_request(pagecache, block, 0);
/* All pending requests for this page must be resubmitted. */
if (block->wqueue[COND_FOR_SAVED].last_thread)
wqueue_release_queue(&block->wqueue[COND_FOR_SAVED]);
return 1;
}
unlink_hash(pagecache, block->hash_link);
}
unlink_changed(block);
DBUG_ASSERT(block->wlocks == 0);
DBUG_ASSERT(block->rlocks == 0);
DBUG_ASSERT(block->rlocks_queue == 0);
DBUG_ASSERT(block->pins == 0);
DBUG_ASSERT((block->status & ~(PCBLOCK_ERROR | PCBLOCK_READ | PCBLOCK_IN_FLUSH | PCBLOCK_CHANGED | PCBLOCK_REASSIGNED | PCBLOCK_DEL_WRITE)) == 0);
DBUG_ASSERT(block->requests >= 1);
DBUG_ASSERT(block->next_used == NULL);
block->status= 0;
#ifdef DBUG_ASSERT_EXISTS
block->type= PAGECACHE_EMPTY_PAGE;
#endif
block->rec_lsn= LSN_MAX;
DBUG_PRINT("hash", ("block (Free): %p, hash_link: %p -> NULL",
block, block->hash_link));
block->hash_link= NULL;
if (block->temperature == PCBLOCK_WARM)
pagecache->warm_blocks--;
block->temperature= PCBLOCK_COLD;
KEYCACHE_THREAD_TRACE("free block");
KEYCACHE_DBUG_PRINT("free_block",
("block is freed"));
unreg_request(pagecache, block, 0);
/*
Block->requests is != 0 if unreg_requests()/link_block() gave the block
to a waiting thread
*/
if (!block->requests)
{
DBUG_ASSERT(block->next_used != 0);
/* Remove the free block from the LRU ring. */
unlink_block(pagecache, block);
/* Insert the free block in the free list. */
block->next_used= pagecache->free_block_list;
pagecache->free_block_list= block;
/* Keep track of the number of currently unused blocks. */
pagecache->blocks_unused++;
}
else
{
/* keep flag set by link_block() */
block->status= status & PCBLOCK_REASSIGNED;
}
/* All pending requests for this page must be resubmitted. */
if (block->wqueue[COND_FOR_SAVED].last_thread)
wqueue_release_queue(&block->wqueue[COND_FOR_SAVED]);
return 0;
}
|
O3
|
c
|
free_block:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movzwl 0x74(%rsi), %r12d
cmpq $0x0, 0x20(%rsi)
je 0x6f8cc
movl %edx, %r15d
movl %r12d, %eax
orl $0x8, %eax
movw %ax, 0x74(%rbx)
callq 0xa319a
movq 0x20(%rbx), %rcx
cmpl $0x0, 0x68(%rcx)
je 0x6f8b7
movq %rax, %rcx
addq $0x8, %rax
movq %rax, 0x28(%rbx)
leaq 0xc8(%r14), %rsi
cmpq $0x0, 0x38(%rcx)
jne 0x6f998
movq %rax, %rdi
callq 0x293d0
movq $0x0, 0x28(%rbx)
testb %r15b, %r15b
jne 0x6f978
movq 0x20(%rbx), %rsi
movq %r14, %rdi
callq 0x6f725
movq 0x10(%rbx), %rcx
movq 0x18(%rbx), %rax
testq %rcx, %rcx
je 0x6f8e3
movq %rax, 0x18(%rcx)
movq 0x10(%rbx), %rcx
jmp 0x6f8e5
xorl %ecx, %ecx
movq %rcx, (%rax)
movw $0x0, 0x74(%rbx)
movabsq $0xffffffffffffff, %rax # imm = 0xFFFFFFFFFFFFFF
movq %rax, 0x88(%rbx)
movq $0x0, 0x20(%rbx)
cmpl $0x1, 0x78(%rbx)
jne 0x6f911
decq 0x60(%r14)
movl $0x0, 0x78(%rbx)
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x6cc9f
cmpl $0x0, 0x60(%rbx)
je 0x6f936
andl $0x8, %r12d
movw %r12w, 0x74(%rbx)
jmp 0x6f956
movq %r14, %rdi
movq %rbx, %rsi
callq 0x6fb11
movq 0xa0(%r14), %rax
movq %rax, (%rbx)
movq %rbx, 0xa0(%r14)
incq 0x50(%r14)
xorl %r14d, %r14d
cmpq $0x0, 0x50(%rbx)
je 0x6f96c
addq $0x50, %rbx
movq %rbx, %rdi
callq 0xa7d5b
movl %r14d, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
cmpl $0x0, 0x64(%rbx)
je 0x6f8c0
andb $-0x9, 0x74(%rbx)
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x6cc9f
movb $0x1, %r14b
jmp 0x6f959
leaq 0x6bdb2(%rip), %rdx # 0xdb751
movq %rax, %rdi
movl $0x64d, %ecx # imm = 0x64D
callq 0x2f180
jmp 0x6f8af
|
free_block:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
mov rbx, rsi
mov r14, rdi
movzx r12d, word ptr [rsi+74h]
cmp qword ptr [rsi+20h], 0
jz short loc_6F8CC
mov r15d, edx
mov eax, r12d
or eax, 8
mov [rbx+74h], ax
call _my_thread_var
mov rcx, [rbx+20h]
cmp dword ptr [rcx+68h], 0
jz short loc_6F8B7
mov rcx, rax
add rax, 8
mov [rbx+28h], rax
lea rsi, [r14+0C8h]
cmp qword ptr [rcx+38h], 0
jnz loc_6F998
mov rdi, rax
call _pthread_cond_wait
loc_6F8AF:
mov qword ptr [rbx+28h], 0
loc_6F8B7:
test r15b, r15b
jnz loc_6F978
loc_6F8C0:
mov rsi, [rbx+20h]
mov rdi, r14
call unlink_hash
loc_6F8CC:
mov rcx, [rbx+10h]
mov rax, [rbx+18h]
test rcx, rcx
jz short loc_6F8E3
mov [rcx+18h], rax
mov rcx, [rbx+10h]
jmp short loc_6F8E5
loc_6F8E3:
xor ecx, ecx
loc_6F8E5:
mov [rax], rcx
mov word ptr [rbx+74h], 0
mov rax, 0FFFFFFFFFFFFFFh
mov [rbx+88h], rax
mov qword ptr [rbx+20h], 0
cmp dword ptr [rbx+78h], 1
jnz short loc_6F911
dec qword ptr [r14+60h]
loc_6F911:
mov dword ptr [rbx+78h], 0
mov rdi, r14
mov rsi, rbx
xor edx, edx
call unreg_request
cmp dword ptr [rbx+60h], 0
jz short loc_6F936
and r12d, 8
mov [rbx+74h], r12w
jmp short loc_6F956
loc_6F936:
mov rdi, r14
mov rsi, rbx
call unlink_block
mov rax, [r14+0A0h]
mov [rbx], rax
mov [r14+0A0h], rbx
inc qword ptr [r14+50h]
loc_6F956:
xor r14d, r14d
loc_6F959:
cmp qword ptr [rbx+50h], 0
jz short loc_6F96C
add rbx, 50h ; 'P'
mov rdi, rbx
call wqueue_release_queue
loc_6F96C:
mov eax, r14d
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_6F978:
cmp dword ptr [rbx+64h], 0
jz loc_6F8C0
and byte ptr [rbx+74h], 0F7h
mov rdi, r14
mov rsi, rbx
xor edx, edx
call unreg_request
mov r14b, 1
jmp short loc_6F959
loc_6F998:
lea rdx, aWorkspaceLlm4b_33; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, rax
mov ecx, 64Dh
call psi_cond_wait
jmp loc_6F8AF
|
long long free_block(_QWORD *a1, long long a2, char a3)
{
unsigned int v4; // r14d
__int16 v5; // r12
long long v7; // rax
long long v8; // rcx
long long v9; // rax
long long v10; // rsi
long long v11; // rcx
_QWORD *v12; // rax
long long v13; // rcx
v4 = (unsigned int)a1;
v5 = *(_WORD *)(a2 + 116);
if ( *(_QWORD *)(a2 + 32) )
{
*(_WORD *)(a2 + 116) = v5 | 8;
v7 = my_thread_var(a1);
if ( *(_DWORD *)(*(_QWORD *)(a2 + 32) + 104LL) )
{
v8 = v7;
v9 = v7 + 8;
*(_QWORD *)(a2 + 40) = v9;
v10 = (long long)(a1 + 25);
if ( *(_QWORD *)(v8 + 56) )
psi_cond_wait(v9, v10, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c", 0x64Du);
else
pthread_cond_wait(v9, v10);
*(_QWORD *)(a2 + 40) = 0LL;
}
if ( a3 && *(_DWORD *)(a2 + 100) )
{
*(_BYTE *)(a2 + 116) &= ~8u;
unreg_request(a1, a2, 0);
LOBYTE(v4) = 1;
goto LABEL_17;
}
unlink_hash(a1, *(long long **)(a2 + 32));
}
v11 = *(_QWORD *)(a2 + 16);
v12 = *(_QWORD **)(a2 + 24);
if ( v11 )
{
*(_QWORD *)(v11 + 24) = v12;
v13 = *(_QWORD *)(a2 + 16);
}
else
{
v13 = 0LL;
}
*v12 = v13;
*(_WORD *)(a2 + 116) = 0;
*(_QWORD *)(a2 + 136) = 0xFFFFFFFFFFFFFFLL;
*(_QWORD *)(a2 + 32) = 0LL;
if ( *(_DWORD *)(a2 + 120) == 1 )
--a1[12];
*(_DWORD *)(a2 + 120) = 0;
unreg_request(a1, a2, 0);
if ( *(_DWORD *)(a2 + 96) )
{
*(_WORD *)(a2 + 116) = v5 & 8;
}
else
{
unlink_block(a1, a2);
*(_QWORD *)a2 = a1[20];
a1[20] = a2;
++a1[10];
}
v4 = 0;
LABEL_17:
if ( *(_QWORD *)(a2 + 80) )
wqueue_release_queue(a2 + 80);
return v4;
}
|
free_block:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV RBX,RSI
MOV R14,RDI
MOVZX R12D,word ptr [RSI + 0x74]
CMP qword ptr [RSI + 0x20],0x0
JZ 0x0016f8cc
MOV R15D,EDX
MOV EAX,R12D
OR EAX,0x8
MOV word ptr [RBX + 0x74],AX
CALL 0x001a319a
MOV RCX,qword ptr [RBX + 0x20]
CMP dword ptr [RCX + 0x68],0x0
JZ 0x0016f8b7
MOV RCX,RAX
ADD RAX,0x8
MOV qword ptr [RBX + 0x28],RAX
LEA RSI,[R14 + 0xc8]
CMP qword ptr [RCX + 0x38],0x0
JNZ 0x0016f998
MOV RDI,RAX
CALL 0x001293d0
LAB_0016f8af:
MOV qword ptr [RBX + 0x28],0x0
LAB_0016f8b7:
TEST R15B,R15B
JNZ 0x0016f978
LAB_0016f8c0:
MOV RSI,qword ptr [RBX + 0x20]
MOV RDI,R14
CALL 0x0016f725
LAB_0016f8cc:
MOV RCX,qword ptr [RBX + 0x10]
MOV RAX,qword ptr [RBX + 0x18]
TEST RCX,RCX
JZ 0x0016f8e3
MOV qword ptr [RCX + 0x18],RAX
MOV RCX,qword ptr [RBX + 0x10]
JMP 0x0016f8e5
LAB_0016f8e3:
XOR ECX,ECX
LAB_0016f8e5:
MOV qword ptr [RAX],RCX
MOV word ptr [RBX + 0x74],0x0
MOV RAX,0xffffffffffffff
MOV qword ptr [RBX + 0x88],RAX
MOV qword ptr [RBX + 0x20],0x0
CMP dword ptr [RBX + 0x78],0x1
JNZ 0x0016f911
DEC qword ptr [R14 + 0x60]
LAB_0016f911:
MOV dword ptr [RBX + 0x78],0x0
MOV RDI,R14
MOV RSI,RBX
XOR EDX,EDX
CALL 0x0016cc9f
CMP dword ptr [RBX + 0x60],0x0
JZ 0x0016f936
AND R12D,0x8
MOV word ptr [RBX + 0x74],R12W
JMP 0x0016f956
LAB_0016f936:
MOV RDI,R14
MOV RSI,RBX
CALL 0x0016fb11
MOV RAX,qword ptr [R14 + 0xa0]
MOV qword ptr [RBX],RAX
MOV qword ptr [R14 + 0xa0],RBX
INC qword ptr [R14 + 0x50]
LAB_0016f956:
XOR R14D,R14D
LAB_0016f959:
CMP qword ptr [RBX + 0x50],0x0
JZ 0x0016f96c
ADD RBX,0x50
MOV RDI,RBX
CALL 0x001a7d5b
LAB_0016f96c:
MOV EAX,R14D
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_0016f978:
CMP dword ptr [RBX + 0x64],0x0
JZ 0x0016f8c0
AND byte ptr [RBX + 0x74],0xf7
MOV RDI,R14
MOV RSI,RBX
XOR EDX,EDX
CALL 0x0016cc9f
MOV R14B,0x1
JMP 0x0016f959
LAB_0016f998:
LEA RDX,[0x1db751]
MOV RDI,RAX
MOV ECX,0x64d
CALL 0x0012f180
JMP 0x0016f8af
|
ulong free_block(long param_1,int8 *param_2,char param_3)
{
ushort uVar1;
int8 *puVar2;
long lVar3;
pthread_cond_t *__cond;
int8 uVar4;
ulong uVar5;
uVar1 = *(ushort *)((long)param_2 + 0x74);
if (param_2[4] != 0) {
*(ushort *)((long)param_2 + 0x74) = uVar1 | 8;
lVar3 = _my_thread_var();
if (*(int *)(param_2[4] + 0x68) != 0) {
__cond = (pthread_cond_t *)(lVar3 + 8);
param_2[5] = __cond;
if (*(long *)(lVar3 + 0x38) == 0) {
pthread_cond_wait(__cond,(pthread_mutex_t *)(param_1 + 200));
}
else {
psi_cond_wait(__cond,(pthread_mutex_t *)(param_1 + 200),
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c",0x64d)
;
}
param_2[5] = 0;
}
if ((param_3 != '\0') && (*(int *)((long)param_2 + 100) != 0)) {
*(byte *)((long)param_2 + 0x74) = *(byte *)((long)param_2 + 0x74) & 0xf7;
unreg_request(param_1,param_2,0);
uVar5 = CONCAT71((int7)((ulong)param_1 >> 8),1);
goto LAB_0016f959;
}
unlink_hash(param_1,param_2[4]);
}
puVar2 = (int8 *)param_2[3];
if (param_2[2] == 0) {
uVar4 = 0;
}
else {
*(int8 **)(param_2[2] + 0x18) = puVar2;
uVar4 = param_2[2];
}
*puVar2 = uVar4;
*(int2 *)((long)param_2 + 0x74) = 0;
param_2[0x11] = 0xffffffffffffff;
param_2[4] = 0;
if (*(int *)(param_2 + 0xf) == 1) {
*(long *)(param_1 + 0x60) = *(long *)(param_1 + 0x60) + -1;
}
*(int4 *)(param_2 + 0xf) = 0;
unreg_request(param_1,param_2,0);
if (*(int *)(param_2 + 0xc) == 0) {
unlink_block(param_1,param_2);
*param_2 = *(int8 *)(param_1 + 0xa0);
*(int8 **)(param_1 + 0xa0) = param_2;
*(long *)(param_1 + 0x50) = *(long *)(param_1 + 0x50) + 1;
}
else {
*(ushort *)((long)param_2 + 0x74) = uVar1 & 8;
}
uVar5 = 0;
LAB_0016f959:
if (param_2[10] != 0) {
wqueue_release_queue(param_2 + 10);
}
return uVar5 & 0xffffffff;
}
|
|
64,820 |
coro::context::start()
|
tinyCoroLab/src/context.cpp
|
auto context::start() noexcept -> void
{
// TODO[lab2b]: Add you codes
m_job = make_unique<jthread>(
[this](stop_token token)
{
this->init();
this->run(token);
this->deinit();
});
}
|
O0
|
cpp
|
coro::context::start():
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movq %rax, 0x10(%rsp)
leaq 0x18(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x6a6e0
jmp 0x6a6a9
movq 0x8(%rsp), %rdi
addq $0x20240, %rdi # imm = 0x20240
leaq 0x18(%rsp), %rsi
callq 0x6aea0
leaq 0x18(%rsp), %rdi
callq 0xdc60
addq $0x28, %rsp
retq
movq %rax, %rdi
callq 0xca70
nopw %cs:(%rax,%rax)
|
_ZN4coro7context5startEv:
sub rsp, 28h
mov [rsp+28h+var_8], rdi
mov rax, [rsp+28h+var_8]
mov [rsp+28h+var_20], rax; void *
mov qword ptr [rsp+28h+var_18], rax; int
lea rdi, [rsp+28h+var_10]; int
lea rsi, [rsp+28h+var_18]
call _ZSt11make_uniqueISt7jthreadJZN4coro7context5startEvE3$_0EENSt9_MakeUniqIT_E15__single_objectEDpOT0_; std::make_unique<std::jthread,coro::context::start(void)::$_0>(coro::context::start(void)::$_0 &&)
jmp short $+2
loc_6A6A9:
mov rdi, [rsp+28h+var_20]
add rdi, 20240h
lea rsi, [rsp+28h+var_10]
call _ZNSt10unique_ptrISt7jthreadSt14default_deleteIS0_EEaSEOS3_; std::unique_ptr<std::jthread>::operator=(std::unique_ptr<std::jthread>&&)
lea rdi, [rsp+28h+var_10]
call _ZNSt10unique_ptrISt7jthreadSt14default_deleteIS0_EED2Ev; std::unique_ptr<std::jthread>::~unique_ptr()
add rsp, 28h
retn
mov rdi, rax
call __clang_call_terminate
|
_QWORD * coro::context::start(coro::context *this)
{
int v2; // [rsp+0h] [rbp-28h]
char *v3; // [rsp+8h] [rbp-20h]
long long v4[2]; // [rsp+18h] [rbp-10h] BYREF
v4[1] = (long long)this;
std::make_unique<std::jthread,coro::context::start(void)::$_0>((int)v4, v2, this, (int)this, v4[0]);
std::unique_ptr<std::jthread>::operator=(v3 + 131648, v4);
return std::unique_ptr<std::jthread>::~unique_ptr((long long)v4);
}
|
start:
SUB RSP,0x28
MOV qword ptr [RSP + 0x20],RDI
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x10],RAX
LAB_0016a698:
LEA RDI,[RSP + 0x18]
LEA RSI,[RSP + 0x10]
CALL 0x0016a6e0
JMP 0x0016a6a9
LAB_0016a6a9:
MOV RDI,qword ptr [RSP + 0x8]
ADD RDI,0x20240
LEA RSI,[RSP + 0x18]
CALL 0x0016aea0
LEA RDI,[RSP + 0x18]
CALL 0x0010dc60
ADD RSP,0x28
RET
|
/* coro::context::start() */
void __thiscall coro::context::start(context *this)
{
__0 local_10 [8];
context *local_8;
/* try { // try from 0016a698 to 0016a6a6 has its CatchHandler @ 0016a6ce */
local_8 = this;
std::make_unique<std::jthread,coro::context::start()::__0>(local_10);
std::unique_ptr<std::jthread,std::default_delete<std::jthread>>::operator=
((unique_ptr<std::jthread,std::default_delete<std::jthread>> *)(this + 0x20240),
(unique_ptr *)local_10);
std::unique_ptr<std::jthread,std::default_delete<std::jthread>>::~unique_ptr
((unique_ptr<std::jthread,std::default_delete<std::jthread>> *)local_10);
return;
}
|
|
64,821 |
mul_sum_us8_pairs_int32x16(long long vector[8], long long vector[8])
|
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu-aarch64.cpp
|
static inline __m512i mul_sum_us8_pairs_int32x16(const __m512i ax, const __m512i sy) {
#if defined(__AVX512VNNI__)
const __m512i zero = _mm512_setzero_si512();
return _mm512_dpbusd_epi32(zero, ax, sy);
#else
// Perform multiplication and create 16-bit values
const __m512i dot = _mm512_maddubs_epi16(ax, sy);
return sum_i16_pairs_int_32x16(dot);
#endif
}
|
O0
|
cpp
|
mul_sum_us8_pairs_int32x16(long long vector[8], long long vector[8]):
pushq %rbp
movq %rsp, %rbp
andq $-0x40, %rsp
subq $0x180, %rsp # imm = 0x180
vmovdqa64 %zmm0, 0x80(%rsp)
vmovdqa64 %zmm1, 0x40(%rsp)
vmovdqa64 0x80(%rsp), %zmm1
vmovdqa64 0x40(%rsp), %zmm0
vmovdqa64 %zmm1, 0x100(%rsp)
vmovdqa64 %zmm0, 0xc0(%rsp)
vmovdqa64 0x100(%rsp), %zmm0
vmovdqa64 0xc0(%rsp), %zmm1
vpmaddubsw %zmm1, %zmm0, %zmm0
vmovdqa64 %zmm0, (%rsp)
vmovdqa64 (%rsp), %zmm0
callq 0x4fab0
movq %rbp, %rsp
popq %rbp
retq
nopl (%rax)
|
_ZL26mul_sum_us8_pairs_int32x16Dv8_xS_:
push rbp
mov rbp, rsp
and rsp, 0FFFFFFFFFFFFFFC0h
sub rsp, 180h
vmovdqa64 zmmword ptr [rsp+180h+var_100], zmm0
vmovdqa64 zmmword ptr [rsp+180h+var_140], zmm1
vmovdqa64 zmm1, zmmword ptr [rsp+180h+var_100]
vmovdqa64 zmm0, zmmword ptr [rsp+180h+var_140]
vmovdqa64 zmmword ptr [rsp+180h+var_80], zmm1
vmovdqa64 zmmword ptr [rsp+180h+var_C0], zmm0
vmovdqa64 zmm0, zmmword ptr [rsp+180h+var_80]
vmovdqa64 zmm1, zmmword ptr [rsp+180h+var_C0]
vpmaddubsw zmm0, zmm0, zmm1
vmovdqa64 zmmword ptr [rsp+180h+var_180], zmm0
vmovdqa64 zmm0, zmmword ptr [rsp+180h+var_180]
call _ZL23sum_i16_pairs_int_32x16Dv8_x
mov rsp, rbp
pop rbp
retn
|
long long mul_sum_us8_pairs_int32x16(long long a1, long long a2, long long a3, long long a4)
{
__asm
{
vmovdqa64 zmmword ptr [rsp+180h+var_100], zmm0
vmovdqa64 zmmword ptr [rsp+180h+var_140], zmm1
vmovdqa64 zmm1, zmmword ptr [rsp+180h+var_100]
vmovdqa64 zmm0, zmmword ptr [rsp+180h+var_140]
vmovdqa64 zmmword ptr [rsp+180h+var_80], zmm1
vmovdqa64 zmmword ptr [rsp+180h+var_C0], zmm0
vmovdqa64 zmm0, zmmword ptr [rsp+180h+var_80]
vmovdqa64 zmm1, zmmword ptr [rsp+180h+var_C0]
vpmaddubsw zmm0, zmm0, zmm1
vmovdqa64 zmmword ptr [rsp+180h+var_180], zmm0
vmovdqa64 zmm0, zmmword ptr [rsp+180h+var_180]
}
return sum_i16_pairs_int_32x16(a1, a2, a3, a4);
}
|
mul_sum_us8_pairs_int32x16:
PUSH RBP
MOV RBP,RSP
AND RSP,-0x40
SUB RSP,0x180
VMOVDQA64 zmmword ptr [RSP + 0x80],ZMM0
VMOVDQA64 zmmword ptr [RSP + 0x40],ZMM1
VMOVDQA64 ZMM1,zmmword ptr [RSP + 0x80]
VMOVDQA64 ZMM0,zmmword ptr [RSP + 0x40]
VMOVDQA64 zmmword ptr [RSP + 0x100],ZMM1
VMOVDQA64 zmmword ptr [RSP + 0xc0],ZMM0
VMOVDQA64 ZMM0,zmmword ptr [RSP + 0x100]
VMOVDQA64 ZMM1,zmmword ptr [RSP + 0xc0]
VPMADDUBSW ZMM0,ZMM0,ZMM1
VMOVDQA64 zmmword ptr [RSP],ZMM0
VMOVDQA64 ZMM0,zmmword ptr [RSP]
CALL 0x0014fab0
MOV RSP,RBP
POP RBP
RET
|
/* mul_sum_us8_pairs_int32x16(long long __vector(8), long long __vector(8)) */
void mul_sum_us8_pairs_int32x16(_func_longlong_int *param_1,_func_longlong_int *param_2)
{
int1 auVar1 [64];
int1 auVar2 [64];
int1 in_ZMM0 [64];
int1 in_ZMM1 [64];
auVar1 = vmovdqa64_avx512f(in_ZMM0);
auVar2 = vmovdqa64_avx512f(in_ZMM1);
auVar1 = vmovdqa64_avx512f(auVar1);
auVar2 = vmovdqa64_avx512f(auVar2);
auVar1 = vmovdqa64_avx512f(auVar1);
auVar2 = vmovdqa64_avx512f(auVar2);
auVar1 = vmovdqa64_avx512f(auVar1);
auVar2 = vmovdqa64_avx512f(auVar2);
auVar1 = vpmaddubsw_avx512bw(auVar1,auVar2);
auVar1 = vmovdqa64_avx512f(auVar1);
vmovdqa64_avx512f(auVar1);
sum_i16_pairs_int_32x16(param_1);
return;
}
|
|
64,822 |
get_hash_link
|
eloqsql/mysys/mf_keycache.c
|
static HASH_LINK *get_hash_link(SIMPLE_KEY_CACHE_CB *keycache,
int file, my_off_t filepos)
{
reg1 HASH_LINK *hash_link, **start;
#if defined(KEYCACHE_DEBUG)
int cnt;
#endif
KEYCACHE_DBUG_PRINT("get_hash_link", ("fd: %u pos: %lu",
(uint) file,(ulong) filepos));
restart:
/*
Find the bucket in the hash table for the pair (file, filepos);
start contains the head of the bucket list,
hash_link points to the first member of the list
*/
hash_link= *(start= &keycache->hash_root[KEYCACHE_HASH(file, filepos)]);
#if defined(KEYCACHE_DEBUG)
cnt= 0;
#endif
/* Look for an element for the pair (file, filepos) in the bucket chain */
while (hash_link &&
(hash_link->diskpos != filepos || hash_link->file != file))
{
hash_link= hash_link->next;
#if defined(KEYCACHE_DEBUG)
cnt++;
if (! (cnt <= keycache->hash_links_used))
{
int i;
for (i=0, hash_link= *start ;
i < cnt ; i++, hash_link= hash_link->next)
{
KEYCACHE_DBUG_PRINT("get_hash_link", ("fd: %u pos: %lu",
(uint) hash_link->file,(ulong) hash_link->diskpos));
}
}
KEYCACHE_DBUG_ASSERT(cnt <= keycache->hash_links_used);
#endif
}
if (! hash_link)
{
/* There is no hash link in the hash table for the pair (file, filepos) */
if (keycache->free_hash_list)
{
hash_link= keycache->free_hash_list;
keycache->free_hash_list= hash_link->next;
}
else if (keycache->hash_links_used < keycache->hash_links)
{
hash_link= &keycache->hash_link_root[keycache->hash_links_used++];
}
else
{
/* Wait for a free hash link */
struct st_my_thread_var *thread= my_thread_var;
KEYCACHE_PAGE page;
KEYCACHE_DBUG_PRINT("get_hash_link", ("waiting"));
page.file= file;
page.filepos= filepos;
thread->keycache_link= (void *) &page;
link_into_queue(&keycache->waiting_for_hash_link, thread);
KEYCACHE_DBUG_PRINT("get_hash_link: wait",
("suspend thread %ld", (ulong) thread->id));
keycache_pthread_cond_wait(&thread->suspend,
&keycache->cache_lock);
thread->keycache_link= NULL;
goto restart;
}
hash_link->file= file;
hash_link->diskpos= filepos;
link_hash(start, hash_link);
}
/* Register the request for the page */
hash_link->requests++;
return hash_link;
}
|
O0
|
c
|
get_hash_link:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
jmp 0xe6815
jmp 0xe6817
movq -0x8(%rbp), %rax
movq 0x80(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x18(%rbp), %rax
movq -0x8(%rbp), %rcx
movl 0x18(%rcx), %ecx
xorl %edx, %edx
divq %rcx
movslq -0xc(%rbp), %rcx
addq %rcx, %rax
movq -0x8(%rbp), %rcx
movl 0x164(%rcx), %ecx
xorl %edx, %edx
divq %rcx
movq %rax, %rcx
movq -0x48(%rbp), %rax
movq -0x8(%rbp), %rdx
movl 0x38(%rdx), %edx
subl $0x1, %edx
movl %edx, %edx
andq %rdx, %rcx
movq %rcx, %rsi
shlq $0x3, %rsi
movq %rax, %rdx
addq %rsi, %rdx
movq %rdx, -0x28(%rbp)
movq (%rax,%rcx,8), %rax
movq %rax, -0x20(%rbp)
xorl %eax, %eax
cmpq $0x0, -0x20(%rbp)
movb %al, -0x49(%rbp)
je 0xe68b0
movq -0x20(%rbp), %rax
movq 0x20(%rax), %rcx
movb $0x1, %al
cmpq -0x18(%rbp), %rcx
movb %al, -0x4a(%rbp)
jne 0xe68aa
movq -0x20(%rbp), %rax
movl 0x18(%rax), %eax
cmpl -0xc(%rbp), %eax
setne %al
movb %al, -0x4a(%rbp)
movb -0x4a(%rbp), %al
movb %al, -0x49(%rbp)
movb -0x49(%rbp), %al
testb $0x1, %al
jne 0xe68b9
jmp 0xe68c6
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x20(%rbp)
jmp 0xe687b
cmpq $0x0, -0x20(%rbp)
jne 0xe69da
movq -0x8(%rbp), %rax
cmpq $0x0, 0x90(%rax)
je 0xe6905
movq -0x8(%rbp), %rax
movq 0x90(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x90(%rax)
jmp 0xe69b7
movq -0x8(%rbp), %rax
movl 0x44(%rax), %eax
movq -0x8(%rbp), %rcx
cmpl 0x40(%rcx), %eax
jge 0xe693f
movq -0x8(%rbp), %rax
movq 0x88(%rax), %rax
movq -0x8(%rbp), %rdx
movl 0x44(%rdx), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, 0x44(%rdx)
movslq %ecx, %rcx
imulq $0x30, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
jmp 0xe69b5
callq 0xf7b30
movq %rax, -0x30(%rbp)
jmp 0xe694a
movl -0xc(%rbp), %eax
movl %eax, -0x40(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rax
leaq -0x40(%rbp), %rcx
movq %rcx, 0xa8(%rax)
movq -0x8(%rbp), %rdi
addq $0x118, %rdi # imm = 0x118
movq -0x30(%rbp), %rsi
callq 0xe6bb0
jmp 0xe697d
movq -0x30(%rbp), %rdi
addq $0x8, %rdi
movq -0x8(%rbp), %rsi
addq $0xc0, %rsi
leaq 0x6e73b(%rip), %rdx # 0x1550d2
movl $0x71e, %ecx # imm = 0x71E
callq 0xe6790
movq -0x30(%rbp), %rax
movq $0x0, 0xa8(%rax)
jmp 0xe6817
jmp 0xe69b7
movl -0xc(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x18(%rax)
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x28(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0xe6ee0
movq -0x20(%rbp), %rax
movl 0x28(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x28(%rax)
movq -0x20(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
get_hash_link_0:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_18], rdx
jmp short $+2
loc_E6815:
jmp short $+2
loc_E6817:
mov rax, [rbp+var_8]
mov rax, [rax+80h]
mov [rbp+var_48], rax
mov rax, [rbp+var_18]
mov rcx, [rbp+var_8]
mov ecx, [rcx+18h]
xor edx, edx
div rcx
movsxd rcx, [rbp+var_C]
add rax, rcx
mov rcx, [rbp+var_8]
mov ecx, [rcx+164h]
xor edx, edx
div rcx
mov rcx, rax
mov rax, [rbp+var_48]
mov rdx, [rbp+var_8]
mov edx, [rdx+38h]
sub edx, 1
mov edx, edx
and rcx, rdx
mov rsi, rcx
shl rsi, 3
mov rdx, rax
add rdx, rsi
mov [rbp+var_28], rdx
mov rax, [rax+rcx*8]
mov [rbp+var_20], rax
loc_E687B:
xor eax, eax
cmp [rbp+var_20], 0
mov [rbp+var_49], al
jz short loc_E68B0
mov rax, [rbp+var_20]
mov rcx, [rax+20h]
mov al, 1
cmp rcx, [rbp+var_18]
mov [rbp+var_4A], al
jnz short loc_E68AA
mov rax, [rbp+var_20]
mov eax, [rax+18h]
cmp eax, [rbp+var_C]
setnz al
mov [rbp+var_4A], al
loc_E68AA:
mov al, [rbp+var_4A]
mov [rbp+var_49], al
loc_E68B0:
mov al, [rbp+var_49]
test al, 1
jnz short loc_E68B9
jmp short loc_E68C6
loc_E68B9:
mov rax, [rbp+var_20]
mov rax, [rax]
mov [rbp+var_20], rax
jmp short loc_E687B
loc_E68C6:
cmp [rbp+var_20], 0
jnz loc_E69DA
mov rax, [rbp+var_8]
cmp qword ptr [rax+90h], 0
jz short loc_E6905
mov rax, [rbp+var_8]
mov rax, [rax+90h]
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
mov rcx, [rax]
mov rax, [rbp+var_8]
mov [rax+90h], rcx
jmp loc_E69B7
loc_E6905:
mov rax, [rbp+var_8]
mov eax, [rax+44h]
mov rcx, [rbp+var_8]
cmp eax, [rcx+40h]
jge short loc_E693F
mov rax, [rbp+var_8]
mov rax, [rax+88h]
mov rdx, [rbp+var_8]
mov ecx, [rdx+44h]
mov esi, ecx
add esi, 1
mov [rdx+44h], esi
movsxd rcx, ecx
imul rcx, 30h ; '0'
add rax, rcx
mov [rbp+var_20], rax
jmp short loc_E69B5
loc_E693F:
call _my_thread_var
mov [rbp+var_30], rax
jmp short $+2
loc_E694A:
mov eax, [rbp+var_C]
mov [rbp+var_40], eax
mov rax, [rbp+var_18]
mov [rbp+var_38], rax
mov rax, [rbp+var_30]
lea rcx, [rbp+var_40]
mov [rax+0A8h], rcx
mov rdi, [rbp+var_8]
add rdi, 118h
mov rsi, [rbp+var_30]
call link_into_queue
jmp short $+2
loc_E697D:
mov rdi, [rbp+var_30]
add rdi, 8
mov rsi, [rbp+var_8]
add rsi, 0C0h
lea rdx, aWorkspaceLlm4b_38; "/workspace/llm4binary/github2025/eloqsq"...
mov ecx, 71Eh
call inline_mysql_cond_wait_5
mov rax, [rbp+var_30]
mov qword ptr [rax+0A8h], 0
jmp loc_E6817
loc_E69B5:
jmp short $+2
loc_E69B7:
mov ecx, [rbp+var_C]
mov rax, [rbp+var_20]
mov [rax+18h], ecx
mov rcx, [rbp+var_18]
mov rax, [rbp+var_20]
mov [rax+20h], rcx
mov rdi, [rbp+var_28]
mov rsi, [rbp+var_20]
call link_hash_0
loc_E69DA:
mov rax, [rbp+var_20]
mov ecx, [rax+28h]
add ecx, 1
mov [rax+28h], ecx
mov rax, [rbp+var_20]
add rsp, 50h
pop rbp
retn
|
long long * get_hash_link_0(long long a1, int a2, unsigned long long a3)
{
const char *v3; // rsi
long long v4; // rax
int v5; // ecx
bool v7; // [rsp+6h] [rbp-4Ah]
bool v8; // [rsp+7h] [rbp-49h]
int v9; // [rsp+10h] [rbp-40h] BYREF
unsigned long long v10; // [rsp+18h] [rbp-38h]
long long v11; // [rsp+20h] [rbp-30h]
const char *v12; // [rsp+28h] [rbp-28h]
long long *i; // [rsp+30h] [rbp-20h]
unsigned long long v14; // [rsp+38h] [rbp-18h]
int v15; // [rsp+44h] [rbp-Ch]
long long v16; // [rsp+48h] [rbp-8h]
v16 = a1;
v15 = a2;
v14 = a3;
while ( 1 )
{
v3 = (const char *)(8
* ((unsigned int)(*(_DWORD *)(v16 + 56) - 1) & ((v15 + v14 / *(unsigned int *)(v16 + 24))
/ *(unsigned int *)(v16 + 356))));
v12 = &v3[*(_QWORD *)(v16 + 128)];
for ( i = *(long long **)v12; ; i = (long long *)*i )
{
v8 = 0;
if ( i )
{
v7 = 1;
if ( i[4] == v14 )
v7 = *((_DWORD *)i + 6) != v15;
v8 = v7;
}
if ( !v8 )
break;
}
if ( i )
break;
if ( *(_QWORD *)(v16 + 144) )
{
i = *(long long **)(v16 + 144);
*(_QWORD *)(v16 + 144) = *i;
LABEL_15:
*((_DWORD *)i + 6) = v15;
i[4] = v14;
link_hash_0(v12, i);
break;
}
if ( *(_DWORD *)(v16 + 68) < *(_DWORD *)(v16 + 64) )
{
v4 = *(_QWORD *)(v16 + 136);
v5 = *(_DWORD *)(v16 + 68);
*(_DWORD *)(v16 + 68) = v5 + 1;
i = (long long *)(48LL * v5 + v4);
goto LABEL_15;
}
v11 = my_thread_var(a1, v3);
v9 = v15;
v10 = v14;
*(_QWORD *)(v11 + 168) = &v9;
link_into_queue(v16 + 280, v11);
a1 = v11 + 8;
inline_mysql_cond_wait_5(
v11 + 8,
v16 + 192,
(long long)"/workspace/llm4binary/github2025/eloqsql/mysys/mf_keycache.c",
0x71Eu);
*(_QWORD *)(v11 + 168) = 0LL;
}
++*((_DWORD *)i + 10);
return i;
}
|
get_hash_link:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV qword ptr [RBP + -0x18],RDX
JMP 0x001e6815
LAB_001e6815:
JMP 0x001e6817
LAB_001e6817:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x80]
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x18]
XOR EDX,EDX
DIV RCX
MOVSXD RCX,dword ptr [RBP + -0xc]
ADD RAX,RCX
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x164]
XOR EDX,EDX
DIV RCX
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV RDX,qword ptr [RBP + -0x8]
MOV EDX,dword ptr [RDX + 0x38]
SUB EDX,0x1
MOV EDX,EDX
AND RCX,RDX
MOV RSI,RCX
SHL RSI,0x3
MOV RDX,RAX
ADD RDX,RSI
MOV qword ptr [RBP + -0x28],RDX
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x20],RAX
LAB_001e687b:
XOR EAX,EAX
CMP qword ptr [RBP + -0x20],0x0
MOV byte ptr [RBP + -0x49],AL
JZ 0x001e68b0
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RAX + 0x20]
MOV AL,0x1
CMP RCX,qword ptr [RBP + -0x18]
MOV byte ptr [RBP + -0x4a],AL
JNZ 0x001e68aa
MOV RAX,qword ptr [RBP + -0x20]
MOV EAX,dword ptr [RAX + 0x18]
CMP EAX,dword ptr [RBP + -0xc]
SETNZ AL
MOV byte ptr [RBP + -0x4a],AL
LAB_001e68aa:
MOV AL,byte ptr [RBP + -0x4a]
MOV byte ptr [RBP + -0x49],AL
LAB_001e68b0:
MOV AL,byte ptr [RBP + -0x49]
TEST AL,0x1
JNZ 0x001e68b9
JMP 0x001e68c6
LAB_001e68b9:
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x20],RAX
JMP 0x001e687b
LAB_001e68c6:
CMP qword ptr [RBP + -0x20],0x0
JNZ 0x001e69da
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x90],0x0
JZ 0x001e6905
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x90]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x90],RCX
JMP 0x001e69b7
LAB_001e6905:
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x44]
MOV RCX,qword ptr [RBP + -0x8]
CMP EAX,dword ptr [RCX + 0x40]
JGE 0x001e693f
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x88]
MOV RDX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RDX + 0x44]
MOV ESI,ECX
ADD ESI,0x1
MOV dword ptr [RDX + 0x44],ESI
MOVSXD RCX,ECX
IMUL RCX,RCX,0x30
ADD RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
JMP 0x001e69b5
LAB_001e693f:
CALL 0x001f7b30
MOV qword ptr [RBP + -0x30],RAX
JMP 0x001e694a
LAB_001e694a:
MOV EAX,dword ptr [RBP + -0xc]
MOV dword ptr [RBP + -0x40],EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x30]
LEA RCX,[RBP + -0x40]
MOV qword ptr [RAX + 0xa8],RCX
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x118
MOV RSI,qword ptr [RBP + -0x30]
CALL 0x001e6bb0
JMP 0x001e697d
LAB_001e697d:
MOV RDI,qword ptr [RBP + -0x30]
ADD RDI,0x8
MOV RSI,qword ptr [RBP + -0x8]
ADD RSI,0xc0
LEA RDX,[0x2550d2]
MOV ECX,0x71e
CALL 0x001e6790
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX + 0xa8],0x0
JMP 0x001e6817
LAB_001e69b5:
JMP 0x001e69b7
LAB_001e69b7:
MOV ECX,dword ptr [RBP + -0xc]
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX + 0x18],ECX
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX + 0x20],RCX
MOV RDI,qword ptr [RBP + -0x28]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x001e6ee0
LAB_001e69da:
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RAX + 0x28]
ADD ECX,0x1
MOV dword ptr [RAX + 0x28],ECX
MOV RAX,qword ptr [RBP + -0x20]
ADD RSP,0x50
POP RBP
RET
|
int8 * get_hash_link(long param_1,int param_2,ulong param_3)
{
int iVar1;
ulong uVar2;
bool bVar3;
int local_48 [2];
ulong local_40;
long local_38;
long local_30;
int8 *local_28;
ulong local_20;
int local_14;
long local_10;
local_20 = param_3;
local_14 = param_2;
local_10 = param_1;
while( true ) {
uVar2 = (local_20 / *(uint *)(local_10 + 0x18) + (long)local_14) /
(ulong)*(uint *)(local_10 + 0x164) & (ulong)(*(int *)(local_10 + 0x38) - 1);
local_30 = *(long *)(local_10 + 0x80) + uVar2 * 8;
local_28 = *(int8 **)(*(long *)(local_10 + 0x80) + uVar2 * 8);
while( true ) {
bVar3 = false;
if ((local_28 != (int8 *)0x0) && (bVar3 = true, local_28[4] == local_20)) {
bVar3 = *(int *)(local_28 + 3) != local_14;
}
if (!bVar3) break;
local_28 = (int8 *)*local_28;
}
if (local_28 != (int8 *)0x0) goto LAB_001e69da;
if (*(long *)(local_10 + 0x90) != 0) break;
if (*(int *)(local_10 + 0x44) < *(int *)(local_10 + 0x40)) {
iVar1 = *(int *)(local_10 + 0x44);
*(int *)(local_10 + 0x44) = iVar1 + 1;
local_28 = (int8 *)(*(long *)(local_10 + 0x88) + (long)iVar1 * 0x30);
LAB_001e69b7:
*(int *)(local_28 + 3) = local_14;
local_28[4] = local_20;
link_hash(local_30,local_28);
LAB_001e69da:
*(int *)(local_28 + 5) = *(int *)(local_28 + 5) + 1;
return local_28;
}
local_38 = _my_thread_var();
local_48[0] = local_14;
local_40 = local_20;
*(int **)(local_38 + 0xa8) = local_48;
link_into_queue(local_10 + 0x118,local_38);
inline_mysql_cond_wait
(local_38 + 8,local_10 + 0xc0,
"/workspace/llm4binary/github2025/eloqsql/mysys/mf_keycache.c",0x71e);
*(int8 *)(local_38 + 0xa8) = 0;
}
local_28 = *(int8 **)(local_10 + 0x90);
*(int8 *)(local_10 + 0x90) = *local_28;
goto LAB_001e69b7;
}
|
|
64,823 |
google::protobuf::EnumValueDescriptorProto::_internal_has_options() const
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.pb.h
|
inline bool EnumValueDescriptorProto::_internal_has_options() const {
bool value = (_impl_._has_bits_[0] & 0x00000002u) != 0;
PROTOBUF_ASSUME(!value || _impl_.options_ != nullptr);
return value;
}
|
O0
|
c
|
google::protobuf::EnumValueDescriptorProto::_internal_has_options() const:
subq $0x98, %rsp
movq %rdi, 0x80(%rsp)
movq 0x80(%rsp), %rax
movq %rax, 0x20(%rsp)
addq $0x10, %rax
movq %rax, 0x90(%rsp)
movl $0x0, 0x8c(%rsp)
movq 0x90(%rsp), %rax
movslq 0x8c(%rsp), %rcx
movl (%rax,%rcx,4), %eax
andl $0x2, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movb %al, 0x7f(%rsp)
xorl %eax, %eax
testb $0x1, %al
jne 0x88a00
jmp 0x88aa6
movb 0x7f(%rsp), %al
movb $0x0, 0x3f(%rsp)
testb $0x1, %al
je 0x88a19
movq 0x20(%rsp), %rax
cmpq $0x0, 0x20(%rax)
je 0x88a1b
jmp 0x88a6b
leaq 0x167527(%rip), %rdx # 0x1eff49
leaq 0x40(%rsp), %rdi
movq %rdi, 0x10(%rsp)
movl $0x3, %esi
movl $0x2c14, %ecx # imm = 0x2C14
callq 0x237e0
movq 0x10(%rsp), %rdi
movb $0x1, 0x3f(%rsp)
leaq 0x1675a4(%rip), %rsi # 0x1efff0
callq 0x230a0
movq %rax, 0x18(%rsp)
jmp 0x88a58
movq 0x18(%rsp), %rsi
leaq 0x2b(%rsp), %rdi
callq 0x23250
jmp 0x88a69
jmp 0x88a6b
testb $0x1, 0x3f(%rsp)
jne 0x88a74
jmp 0x88a7e
leaq 0x40(%rsp), %rdi
callq 0x23820
jmp 0x889f5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x30(%rsp)
movl %eax, 0x2c(%rsp)
testb $0x1, 0x3f(%rsp)
jne 0x88a9a
jmp 0x88aa4
leaq 0x40(%rsp), %rdi
callq 0x23820
jmp 0x88ad6
movb $0x1, %al
testb $0x1, 0x7f(%rsp)
movb %al, 0xf(%rsp)
je 0x88ac4
movq 0x20(%rsp), %rax
cmpq $0x0, 0x20(%rax)
setne %al
movb %al, 0xf(%rsp)
movb 0xf(%rsp), %al
movb 0x7f(%rsp), %al
andb $0x1, %al
addq $0x98, %rsp
retq
movq 0x30(%rsp), %rdi
callq 0x13750
|
_ZNK6google8protobuf24EnumValueDescriptorProto21_internal_has_optionsEv:
sub rsp, 98h
mov [rsp+98h+var_18], rdi
mov rax, [rsp+98h+var_18]
mov [rsp+98h+var_78], rax
add rax, 10h
mov [rsp+98h+var_8], rax
mov [rsp+98h+var_C], 0
mov rax, [rsp+98h+var_8]
movsxd rcx, [rsp+98h+var_C]
mov eax, [rax+rcx*4]
and eax, 2
cmp eax, 0
setnz al
and al, 1
mov [rsp+98h+var_19], al
loc_889F5:
xor eax, eax
test al, 1
jnz short loc_88A00
jmp loc_88AA6
loc_88A00:
mov al, [rsp+98h+var_19]
mov [rsp+98h+var_59], 0
test al, 1
jz short loc_88A19
mov rax, [rsp+98h+var_78]
cmp qword ptr [rax+20h], 0
jz short loc_88A1B
loc_88A19:
jmp short loc_88A6B
loc_88A1B:
lea rdx, aWorkspaceLlm4b_7; "/workspace/llm4binary/github2025/aimrt_"...
lea rdi, [rsp+98h+var_58]
mov [rsp+98h+var_88], rdi
mov esi, 3
mov ecx, 2C14h
call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int)
mov rdi, [rsp+98h+var_88]
mov [rsp+98h+var_59], 1
lea rsi, aCheckFailedVal_2; "CHECK failed: !value || _impl_.options_"...
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
mov [rsp+98h+var_80], rax
jmp short $+2
loc_88A58:
mov rsi, [rsp+98h+var_80]
lea rdi, [rsp+98h+var_6D]
call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &)
jmp short $+2
loc_88A69:
jmp short $+2
loc_88A6B:
test [rsp+98h+var_59], 1
jnz short loc_88A74
jmp short loc_88A7E
loc_88A74:
lea rdi, [rsp+98h+var_58]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
loc_88A7E:
jmp loc_889F5
mov rcx, rax
mov eax, edx
mov [rsp+arg_28], rcx
mov [rsp+arg_24], eax
test [rsp+arg_37], 1
jnz short loc_88A9A
jmp short loc_88AA4
loc_88A9A:
lea rdi, [rsp+arg_38]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
loc_88AA4:
jmp short loc_88AD6
loc_88AA6:
mov al, 1
test [rsp+98h+var_19], 1
mov [rsp+98h+var_89], al
jz short loc_88AC4
mov rax, [rsp+98h+var_78]
cmp qword ptr [rax+20h], 0
setnz al
mov [rsp+98h+var_89], al
loc_88AC4:
mov al, [rsp+98h+var_89]
mov al, [rsp+98h+var_19]
and al, 1
add rsp, 98h
retn
loc_88AD6:
mov rdi, [rsp+arg_28]
call __Unwind_Resume
|
bool google::protobuf::EnumValueDescriptorProto::_internal_has_options(
google::protobuf::EnumValueDescriptorProto *this)
{
return (*((_DWORD *)this + 4) & 2) != 0;
}
|
_internal_has_options:
SUB RSP,0x98
MOV qword ptr [RSP + 0x80],RDI
MOV RAX,qword ptr [RSP + 0x80]
MOV qword ptr [RSP + 0x20],RAX
ADD RAX,0x10
MOV qword ptr [RSP + 0x90],RAX
MOV dword ptr [RSP + 0x8c],0x0
MOV RAX,qword ptr [RSP + 0x90]
MOVSXD RCX,dword ptr [RSP + 0x8c]
MOV EAX,dword ptr [RAX + RCX*0x4]
AND EAX,0x2
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOV byte ptr [RSP + 0x7f],AL
LAB_001889f5:
XOR EAX,EAX
TEST AL,0x1
JNZ 0x00188a00
JMP 0x00188aa6
LAB_00188a00:
MOV AL,byte ptr [RSP + 0x7f]
MOV byte ptr [RSP + 0x3f],0x0
TEST AL,0x1
JZ 0x00188a19
MOV RAX,qword ptr [RSP + 0x20]
CMP qword ptr [RAX + 0x20],0x0
JZ 0x00188a1b
LAB_00188a19:
JMP 0x00188a6b
LAB_00188a1b:
LEA RDX,[0x2eff49]
LEA RDI,[RSP + 0x40]
MOV qword ptr [RSP + 0x10],RDI
MOV ESI,0x3
MOV ECX,0x2c14
CALL 0x001237e0
MOV RDI,qword ptr [RSP + 0x10]
MOV byte ptr [RSP + 0x3f],0x1
LAB_00188a45:
LEA RSI,[0x2efff0]
CALL 0x001230a0
MOV qword ptr [RSP + 0x18],RAX
JMP 0x00188a58
LAB_00188a58:
MOV RSI,qword ptr [RSP + 0x18]
LEA RDI,[RSP + 0x2b]
CALL 0x00123250
LAB_00188a67:
JMP 0x00188a69
LAB_00188a69:
JMP 0x00188a6b
LAB_00188a6b:
TEST byte ptr [RSP + 0x3f],0x1
JNZ 0x00188a74
JMP 0x00188a7e
LAB_00188a74:
LEA RDI,[RSP + 0x40]
CALL 0x00123820
LAB_00188a7e:
JMP 0x001889f5
LAB_00188aa6:
MOV AL,0x1
TEST byte ptr [RSP + 0x7f],0x1
MOV byte ptr [RSP + 0xf],AL
JZ 0x00188ac4
MOV RAX,qword ptr [RSP + 0x20]
CMP qword ptr [RAX + 0x20],0x0
SETNZ AL
MOV byte ptr [RSP + 0xf],AL
LAB_00188ac4:
MOV AL,byte ptr [RSP + 0xf]
MOV AL,byte ptr [RSP + 0x7f]
AND AL,0x1
ADD RSP,0x98
RET
|
/* WARNING: Removing unreachable block (ram,0x00188a00) */
/* WARNING: Removing unreachable block (ram,0x00188a0d) */
/* WARNING: Removing unreachable block (ram,0x00188a19) */
/* WARNING: Removing unreachable block (ram,0x00188a1b) */
/* WARNING: Removing unreachable block (ram,0x00188a6b) */
/* WARNING: Removing unreachable block (ram,0x00188a74) */
/* WARNING: Removing unreachable block (ram,0x00188a72) */
/* WARNING: Removing unreachable block (ram,0x00188a7e) */
/* google::protobuf::EnumValueDescriptorProto::_internal_has_options() const */
int8 __thiscall
google::protobuf::EnumValueDescriptorProto::_internal_has_options(EnumValueDescriptorProto *this)
{
int7 uVar1;
bool bVar2;
bVar2 = (*(uint *)(this + 0x10) & 2) != 0;
uVar1 = 0;
if (bVar2) {
uVar1 = (int7)((ulong)this >> 8);
}
return CONCAT71(uVar1,bVar2);
}
|
|
64,824 |
my_hash_sort_ucs2_nopad
|
eloqsql/strings/ctype-ucs2.c
|
static void
my_hash_sort_ucs2_nopad(CHARSET_INFO *cs, const uchar *s, size_t slen,
ulong *nr1, ulong *nr2)
{
my_wc_t wc;
int res;
const uchar *e=s+slen;
MY_UNICASE_INFO *uni_plane= cs->caseinfo;
register ulong m1= *nr1, m2= *nr2;
while ((s < e) && (res=my_ucs2_uni(cs,&wc, (uchar *)s, (uchar*)e)) >0)
{
my_tosort_ucs2(uni_plane, &wc);
MY_HASH_ADD_16(m1, m2, wc);
s+=res;
}
*nr1= m1;
*nr2= m2;
}
|
O0
|
c
|
my_hash_sort_ucs2_nopad:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x10(%rbp), %rax
addq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x8(%rbp), %rax
movq 0x78(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x10(%rbp), %rcx
xorl %eax, %eax
cmpq -0x40(%rbp), %rcx
movb %al, -0x59(%rbp)
jae 0xb122a
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x40(%rbp), %rcx
leaq -0x30(%rbp), %rsi
callq 0xabb00
movl %eax, -0x34(%rbp)
cmpl $0x0, %eax
setg %al
movb %al, -0x59(%rbp)
movb -0x59(%rbp), %al
testb $0x1, %al
jne 0xb1236
jmp 0xb12d0
movq -0x48(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0xb12f0
jmp 0xb1245
movq -0x50(%rbp), %rax
andq $0x3f, %rax
addq -0x58(%rbp), %rax
movq -0x30(%rbp), %rcx
andq $0xff, %rcx
imulq %rcx, %rax
movq -0x50(%rbp), %rcx
shlq $0x8, %rcx
addq %rcx, %rax
xorq -0x50(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x58(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x58(%rbp)
jmp 0xb1281
movq -0x50(%rbp), %rax
andq $0x3f, %rax
addq -0x58(%rbp), %rax
movq -0x30(%rbp), %rcx
shrq $0x8, %rcx
imulq %rcx, %rax
movq -0x50(%rbp), %rcx
shlq $0x8, %rcx
addq %rcx, %rax
xorq -0x50(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x58(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x58(%rbp)
jmp 0xb12ba
movl -0x34(%rbp), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
jmp 0xb11fa
movq -0x50(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movq -0x58(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
|
my_hash_sort_ucs2_nopad:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov rax, [rbp+var_10]
add rax, [rbp+var_18]
mov [rbp+var_40], rax
mov rax, [rbp+var_8]
mov rax, [rax+78h]
mov [rbp+var_48], rax
mov rax, [rbp+var_20]
mov rax, [rax]
mov [rbp+var_50], rax
mov rax, [rbp+var_28]
mov rax, [rax]
mov [rbp+var_58], rax
loc_B11FA:
mov rcx, [rbp+var_10]
xor eax, eax
cmp rcx, [rbp+var_40]
mov [rbp+var_59], al
jnb short loc_B122A
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov rcx, [rbp+var_40]
lea rsi, [rbp+var_30]
call my_ucs2_uni
mov [rbp+var_34], eax
cmp eax, 0
setnle al
mov [rbp+var_59], al
loc_B122A:
mov al, [rbp+var_59]
test al, 1
jnz short loc_B1236
jmp loc_B12D0
loc_B1236:
mov rdi, [rbp+var_48]
lea rsi, [rbp+var_30]
call my_tosort_ucs2
jmp short $+2
loc_B1245:
mov rax, [rbp+var_50]
and rax, 3Fh
add rax, [rbp+var_58]
mov rcx, [rbp+var_30]
and rcx, 0FFh
imul rax, rcx
mov rcx, [rbp+var_50]
shl rcx, 8
add rax, rcx
xor rax, [rbp+var_50]
mov [rbp+var_50], rax
mov rax, [rbp+var_58]
add rax, 3
mov [rbp+var_58], rax
jmp short $+2
loc_B1281:
mov rax, [rbp+var_50]
and rax, 3Fh
add rax, [rbp+var_58]
mov rcx, [rbp+var_30]
shr rcx, 8
imul rax, rcx
mov rcx, [rbp+var_50]
shl rcx, 8
add rax, rcx
xor rax, [rbp+var_50]
mov [rbp+var_50], rax
mov rax, [rbp+var_58]
add rax, 3
mov [rbp+var_58], rax
jmp short $+2
loc_B12BA:
mov ecx, [rbp+var_34]
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
jmp loc_B11FA
loc_B12D0:
mov rcx, [rbp+var_50]
mov rax, [rbp+var_20]
mov [rax], rcx
mov rcx, [rbp+var_58]
mov rax, [rbp+var_28]
mov [rax], rcx
add rsp, 60h
pop rbp
retn
|
_QWORD * my_hash_sort_ucs2_nopad(
long long a1,
unsigned long long a2,
long long a3,
unsigned long long *a4,
_QWORD *a5,
long long a6)
{
_QWORD *result; // rax
bool v7; // [rsp+7h] [rbp-59h]
long long v8; // [rsp+8h] [rbp-58h]
long long v9; // [rsp+8h] [rbp-58h]
unsigned long long v10; // [rsp+10h] [rbp-50h]
long long v11; // [rsp+10h] [rbp-50h]
long long v12; // [rsp+18h] [rbp-48h]
unsigned long long v13; // [rsp+20h] [rbp-40h]
int v14; // [rsp+2Ch] [rbp-34h]
unsigned long long v15; // [rsp+30h] [rbp-30h] BYREF
_QWORD *v16; // [rsp+38h] [rbp-28h]
unsigned long long *v17; // [rsp+40h] [rbp-20h]
long long v18; // [rsp+48h] [rbp-18h]
unsigned long long v19; // [rsp+50h] [rbp-10h]
long long v20; // [rsp+58h] [rbp-8h]
v20 = a1;
v19 = a2;
v18 = a3;
v17 = a4;
v16 = a5;
v13 = a3 + a2;
v12 = *(_QWORD *)(a1 + 120);
v10 = *a4;
v8 = *a5;
while ( 1 )
{
v7 = 0;
if ( v19 < v13 )
{
v14 = my_ucs2_uni(v20, (long long)&v15, v19, v13, (long long)a5, a6);
v7 = v14 > 0;
}
if ( !v7 )
break;
my_tosort_ucs2(v12, &v15);
v11 = v10 ^ ((v10 << 8) + (unsigned __int8)v15 * (v8 + (v10 & 0x3F)));
v9 = v8 + 3;
v10 = v11 ^ ((v11 << 8) + (v15 >> 8) * (v9 + (v11 & 0x3F)));
v8 = v9 + 3;
v19 += v14;
}
*v17 = v10;
result = v16;
*v16 = v8;
return result;
}
|
my_hash_sort_ucs2_nopad:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x78]
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x58],RAX
LAB_001b11fa:
MOV RCX,qword ptr [RBP + -0x10]
XOR EAX,EAX
CMP RCX,qword ptr [RBP + -0x40]
MOV byte ptr [RBP + -0x59],AL
JNC 0x001b122a
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x40]
LEA RSI,[RBP + -0x30]
CALL 0x001abb00
MOV dword ptr [RBP + -0x34],EAX
CMP EAX,0x0
SETG AL
MOV byte ptr [RBP + -0x59],AL
LAB_001b122a:
MOV AL,byte ptr [RBP + -0x59]
TEST AL,0x1
JNZ 0x001b1236
JMP 0x001b12d0
LAB_001b1236:
MOV RDI,qword ptr [RBP + -0x48]
LEA RSI,[RBP + -0x30]
CALL 0x001b12f0
JMP 0x001b1245
LAB_001b1245:
MOV RAX,qword ptr [RBP + -0x50]
AND RAX,0x3f
ADD RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x30]
AND RCX,0xff
IMUL RAX,RCX
MOV RCX,qword ptr [RBP + -0x50]
SHL RCX,0x8
ADD RAX,RCX
XOR RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x3
MOV qword ptr [RBP + -0x58],RAX
JMP 0x001b1281
LAB_001b1281:
MOV RAX,qword ptr [RBP + -0x50]
AND RAX,0x3f
ADD RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x30]
SHR RCX,0x8
IMUL RAX,RCX
MOV RCX,qword ptr [RBP + -0x50]
SHL RCX,0x8
ADD RAX,RCX
XOR RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x3
MOV qword ptr [RBP + -0x58],RAX
JMP 0x001b12ba
LAB_001b12ba:
MOV ECX,dword ptr [RBP + -0x34]
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
JMP 0x001b11fa
LAB_001b12d0:
MOV RCX,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x58]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
ADD RSP,0x60
POP RBP
RET
|
void my_hash_sort_ucs2_nopad(long param_1,ulong param_2,long param_3,ulong *param_4,long *param_5)
{
int8 uVar1;
bool bVar2;
long local_60;
ulong local_58;
int local_3c;
ulong local_38;
long *local_30;
ulong *local_28;
long local_20;
ulong local_18;
long local_10;
uVar1 = *(int8 *)(param_1 + 0x78);
local_58 = *param_4;
local_60 = *param_5;
local_30 = param_5;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
while( true ) {
bVar2 = false;
if (local_18 < param_2 + param_3) {
local_3c = my_ucs2_uni(local_10,&local_38,local_18,param_2 + param_3);
bVar2 = 0 < local_3c;
}
if (!bVar2) break;
my_tosort_ucs2(uVar1,&local_38);
local_58 = ((local_58 & 0x3f) + local_60) * (local_38 & 0xff) + local_58 * 0x100 ^ local_58;
local_58 = ((local_58 & 0x3f) + local_60 + 3) * (local_38 >> 8) + local_58 * 0x100 ^ local_58;
local_60 = local_60 + 6;
local_18 = local_18 + (long)local_3c;
}
*local_28 = local_58;
*local_30 = local_60;
return;
}
|
|
64,825 |
my_hash_sort_ucs2_nopad
|
eloqsql/strings/ctype-ucs2.c
|
static void
my_hash_sort_ucs2_nopad(CHARSET_INFO *cs, const uchar *s, size_t slen,
ulong *nr1, ulong *nr2)
{
my_wc_t wc;
int res;
const uchar *e=s+slen;
MY_UNICASE_INFO *uni_plane= cs->caseinfo;
register ulong m1= *nr1, m2= *nr2;
while ((s < e) && (res=my_ucs2_uni(cs,&wc, (uchar *)s, (uchar*)e)) >0)
{
my_tosort_ucs2(uni_plane, &wc);
MY_HASH_ADD_16(m1, m2, wc);
s+=res;
}
*nr1= m1;
*nr2= m2;
}
|
O3
|
c
|
my_hash_sort_ucs2_nopad:
movq (%rcx), %r9
movq (%r8), %rax
cmpq $0x2, %rdx
jl 0x82615
pushq %rbp
movq %rsp, %rbp
pushq %rbx
addq %rsi, %rdx
movq 0x78(%rdi), %rdi
movq 0x8(%rdi), %rdi
movzbl (%rsi), %r10d
movzbl 0x1(%rsi), %r11d
movq (%rdi,%r10,8), %rbx
testq %rbx, %rbx
je 0x825b1
leaq (%r11,%r11,2), %r10
movl 0x8(%rbx,%r10,4), %r10d
jmp 0x825b8
shll $0x8, %r10d
orq %r11, %r10
movl %r9d, %r11d
andl $0x3f, %r11d
addq %rax, %r11
movzbl %r10b, %ebx
imulq %r11, %rbx
movq %r9, %r11
shlq $0x8, %r11
addq %rbx, %r11
xorq %r9, %r11
movl %r11d, %r9d
andl $0x3f, %r9d
addq %rax, %r9
addq $0x3, %r9
shrl $0x8, %r10d
imulq %r9, %r10
movq %r11, %r9
shlq $0x8, %r9
addq %r10, %r9
xorq %r11, %r9
addq $0x6, %rax
leaq 0x2(%rsi), %r10
cmpq %rdx, %r10
jae 0x82613
addq $0x4, %rsi
cmpq %rdx, %rsi
movq %r10, %rsi
jbe 0x82594
popq %rbx
popq %rbp
movq %r9, (%rcx)
movq %rax, (%r8)
retq
|
my_hash_sort_ucs2_nopad:
mov r9, [rcx]
mov rax, [r8]
cmp rdx, 2
jl loc_82615
push rbp
mov rbp, rsp
push rbx
add rdx, rsi
mov rdi, [rdi+78h]
mov rdi, [rdi+8]
loc_82594:
movzx r10d, byte ptr [rsi]
movzx r11d, byte ptr [rsi+1]
mov rbx, [rdi+r10*8]
test rbx, rbx
jz short loc_825B1
lea r10, [r11+r11*2]
mov r10d, [rbx+r10*4+8]
jmp short loc_825B8
loc_825B1:
shl r10d, 8
or r10, r11
loc_825B8:
mov r11d, r9d
and r11d, 3Fh
add r11, rax
movzx ebx, r10b
imul rbx, r11
mov r11, r9
shl r11, 8
add r11, rbx
xor r11, r9
mov r9d, r11d
and r9d, 3Fh
add r9, rax
add r9, 3
shr r10d, 8
imul r10, r9
mov r9, r11
shl r9, 8
add r9, r10
xor r9, r11
add rax, 6
lea r10, [rsi+2]
cmp r10, rdx
jnb short loc_82613
add rsi, 4
cmp rsi, rdx
mov rsi, r10
jbe short loc_82594
loc_82613:
pop rbx
pop rbp
loc_82615:
mov [rcx], r9
mov [r8], rax
retn
|
long long my_hash_sort_ucs2_nopad(long long a1, unsigned __int8 *a2, long long a3, long long *a4, long long *a5)
{
long long v5; // r9
long long result; // rax
unsigned long long v7; // rdx
long long v8; // rdi
long long v9; // r10
long long v10; // r11
long long v11; // rbx
unsigned int v12; // r10d
long long v13; // rbx
bool v14; // cc
v5 = *a4;
result = *a5;
if ( a3 >= 2 )
{
v7 = (unsigned long long)&a2[a3];
v8 = *(_QWORD *)(*(_QWORD *)(a1 + 120) + 8LL);
do
{
v9 = *a2;
v10 = a2[1];
v11 = *(_QWORD *)(v8 + 8 * v9);
if ( v11 )
v12 = *(_DWORD *)(v11 + 12 * v10 + 8);
else
v12 = v10 | ((_DWORD)v9 << 8);
v13 = (result + (v5 & 0x3F)) * (unsigned __int8)v12;
v5 ^= (v13 + (v5 << 8)) ^ ((result + (((unsigned __int8)v5 ^ (unsigned __int8)v13) & 0x3F) + 3) * (v12 >> 8)
+ ((v5 ^ (v13 + (v5 << 8))) << 8));
result += 6LL;
if ( (unsigned long long)(a2 + 2) >= v7 )
break;
v14 = (unsigned long long)(a2 + 4) <= v7;
a2 += 2;
}
while ( v14 );
}
*a4 = v5;
*a5 = result;
return result;
}
|
my_hash_sort_ucs2_nopad:
MOV R9,qword ptr [RCX]
MOV RAX,qword ptr [R8]
CMP RDX,0x2
JL 0x00182615
PUSH RBP
MOV RBP,RSP
PUSH RBX
ADD RDX,RSI
MOV RDI,qword ptr [RDI + 0x78]
MOV RDI,qword ptr [RDI + 0x8]
LAB_00182594:
MOVZX R10D,byte ptr [RSI]
MOVZX R11D,byte ptr [RSI + 0x1]
MOV RBX,qword ptr [RDI + R10*0x8]
TEST RBX,RBX
JZ 0x001825b1
LEA R10,[R11 + R11*0x2]
MOV R10D,dword ptr [RBX + R10*0x4 + 0x8]
JMP 0x001825b8
LAB_001825b1:
SHL R10D,0x8
OR R10,R11
LAB_001825b8:
MOV R11D,R9D
AND R11D,0x3f
ADD R11,RAX
MOVZX EBX,R10B
IMUL RBX,R11
MOV R11,R9
SHL R11,0x8
ADD R11,RBX
XOR R11,R9
MOV R9D,R11D
AND R9D,0x3f
ADD R9,RAX
ADD R9,0x3
SHR R10D,0x8
IMUL R10,R9
MOV R9,R11
SHL R9,0x8
ADD R9,R10
XOR R9,R11
ADD RAX,0x6
LEA R10,[RSI + 0x2]
CMP R10,RDX
JNC 0x00182613
ADD RSI,0x4
CMP RSI,RDX
MOV RSI,R10
JBE 0x00182594
LAB_00182613:
POP RBX
POP RBP
LAB_00182615:
MOV qword ptr [RCX],R9
MOV qword ptr [R8],RAX
RET
|
void my_hash_sort_ucs2_nopad(long param_1,byte *param_2,long param_3,ulong *param_4,long *param_5)
{
long lVar1;
long lVar2;
byte *pbVar3;
byte *pbVar4;
ulong uVar5;
ulong uVar6;
uVar6 = *param_4;
lVar2 = *param_5;
if (1 < param_3) {
pbVar3 = param_2;
do {
lVar1 = *(long *)(*(long *)(*(long *)(param_1 + 0x78) + 8) + (ulong)*pbVar3 * 8);
if (lVar1 == 0) {
uVar5 = (ulong)CONCAT11(*pbVar3,pbVar3[1]);
}
else {
uVar5 = (ulong)*(uint *)(lVar1 + 8 + (ulong)pbVar3[1] * 0xc);
}
uVar6 = uVar6 * 0x100 + (uVar5 & 0xff) * ((ulong)((uint)uVar6 & 0x3f) + lVar2) ^ uVar6;
uVar6 = uVar6 * 0x100 + (uVar5 >> 8) * ((ulong)((uint)uVar6 & 0x3f) + lVar2 + 3) ^ uVar6;
lVar2 = lVar2 + 6;
} while ((pbVar3 + 2 < param_2 + param_3) &&
(pbVar4 = pbVar3 + 4, pbVar3 = pbVar3 + 2, pbVar4 <= param_2 + param_3));
}
*param_4 = uVar6;
*param_5 = lVar2;
return;
}
|
|
64,826 |
ethash_keccak512_64
|
corpus-core[P]colibri-stateless/build_O0/_deps/ethhash_external-src/lib/keccak/keccak.c
|
union ethash_hash512 ethash_keccak512_64(const uint8_t data[64])
{
union ethash_hash512 hash;
keccak(hash.word64s, 512, data, 64);
return hash;
}
|
O0
|
c
|
ethash_keccak512_64:
pushq %rbp
movq %rsp, %rbp
subq $0x150, %rsp # imm = 0x150
movq %rdi, %rax
movq %rax, -0x150(%rbp)
movq %rsi, -0x148(%rbp)
movq -0x148(%rbp), %rax
movq %rdi, -0x28(%rbp)
movq $0x200, -0x30(%rbp) # imm = 0x200
movq %rax, -0x38(%rbp)
movq $0x40, -0x40(%rbp)
movq -0x30(%rbp), %rax
shrq $0x3, %rax
movq %rax, -0x48(%rbp)
movq -0x30(%rbp), %rcx
shlq %rcx
movl $0x640, %eax # imm = 0x640
subq %rcx, %rax
shrq $0x3, %rax
movq %rax, -0x50(%rbp)
movq $0x0, -0x68(%rbp)
leaq -0x68(%rbp), %rax
movq %rax, -0x70(%rbp)
leaq -0x140(%rbp), %rdi
xorl %esi, %esi
movl $0xc8, %edx
callq 0x231c0
movq -0x40(%rbp), %rax
cmpq -0x50(%rbp), %rax
jb 0x9b03a
movq $0x0, -0x58(%rbp)
movq -0x58(%rbp), %rax
movq -0x50(%rbp), %rcx
shrq $0x3, %rcx
cmpq %rcx, %rax
jae 0x9b019
movq -0x38(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rcx
movq -0x58(%rbp), %rax
xorq -0x140(%rbp,%rax,8), %rcx
movq %rcx, -0x140(%rbp,%rax,8)
movq -0x38(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x38(%rbp)
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0x9afc3
leaq -0x140(%rbp), %rdi
callq *0x9e462(%rip) # 0x139488
movq -0x50(%rbp), %rcx
movq -0x40(%rbp), %rax
subq %rcx, %rax
movq %rax, -0x40(%rbp)
jmp 0x9afb1
leaq -0x140(%rbp), %rax
movq %rax, -0x60(%rbp)
cmpq $0x8, -0x40(%rbp)
jb 0x9b093
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rcx
movq -0x60(%rbp), %rax
xorq (%rax), %rcx
movq %rcx, (%rax)
movq -0x60(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x60(%rbp)
movq -0x38(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x38(%rbp)
movq -0x40(%rbp), %rax
subq $0x8, %rax
movq %rax, -0x40(%rbp)
jmp 0x9b045
jmp 0x9b095
cmpq $0x0, -0x40(%rbp)
jbe 0x9b0ce
movq -0x38(%rbp), %rax
movb (%rax), %cl
movq -0x70(%rbp), %rax
movb %cl, (%rax)
movq -0x70(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x70(%rbp)
movq -0x38(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x38(%rbp)
movq -0x40(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0x9b095
movq -0x70(%rbp), %rax
movb $0x1, (%rax)
movq -0x68(%rbp), %rcx
movq -0x60(%rbp), %rax
xorq (%rax), %rcx
movq %rcx, (%rax)
movq -0x50(%rbp), %rax
shrq $0x3, %rax
subq $0x1, %rax
movabsq $-0x8000000000000000, %rcx # imm = 0x8000000000000000
xorq -0x140(%rbp,%rax,8), %rcx
movq %rcx, -0x140(%rbp,%rax,8)
leaq -0x140(%rbp), %rdi
callq *0x9e372(%rip) # 0x139488
movq $0x0, -0x58(%rbp)
movq -0x58(%rbp), %rax
movq -0x48(%rbp), %rcx
shrq $0x3, %rcx
cmpq %rcx, %rax
jae 0x9b155
movq -0x58(%rbp), %rax
movq -0x140(%rbp,%rax,8), %rdx
movq -0x28(%rbp), %rax
movq -0x58(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0x9b11e
movq -0x150(%rbp), %rax
addq $0x150, %rsp # imm = 0x150
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
ethash_keccak512_64:
push rbp
mov rbp, rsp
sub rsp, 150h
mov rax, rdi
mov [rbp+var_150], rax
mov [rbp+var_148], rsi
mov rax, [rbp+var_148]
mov [rbp+var_28], rdi
mov [rbp+var_30], 200h
mov [rbp+var_38], rax
mov [rbp+var_40], 40h ; '@'
mov rax, [rbp+var_30]
shr rax, 3
mov [rbp+var_48], rax
mov rcx, [rbp+var_30]
shl rcx, 1
mov eax, 640h
sub rax, rcx
shr rax, 3
mov [rbp+var_50], rax
mov [rbp+var_68], 0
lea rax, [rbp+var_68]
mov [rbp+var_70], rax
lea rdi, [rbp+var_140]
xor esi, esi
mov edx, 0C8h
call _memset
loc_9AFB1:
mov rax, [rbp+var_40]
cmp rax, [rbp+var_50]
jb short loc_9B03A
mov [rbp+var_58], 0
loc_9AFC3:
mov rax, [rbp+var_58]
mov rcx, [rbp+var_50]
shr rcx, 3
cmp rax, rcx
jnb short loc_9B019
mov rax, [rbp+var_38]
mov [rbp+var_18], rax
mov rax, [rbp+var_18]
mov rax, [rax]
mov [rbp+var_20], rax
mov rcx, [rbp+var_20]
mov rax, [rbp+var_58]
xor rcx, [rbp+rax*8+var_140]
mov [rbp+rax*8+var_140], rcx
mov rax, [rbp+var_38]
add rax, 8
mov [rbp+var_38], rax
mov rax, [rbp+var_58]
add rax, 1
mov [rbp+var_58], rax
jmp short loc_9AFC3
loc_9B019:
lea rdi, [rbp+var_140]
call cs:keccakf1600_best
mov rcx, [rbp+var_50]
mov rax, [rbp+var_40]
sub rax, rcx
mov [rbp+var_40], rax
jmp loc_9AFB1
loc_9B03A:
lea rax, [rbp+var_140]
mov [rbp+var_60], rax
loc_9B045:
cmp [rbp+var_40], 8
jb short loc_9B093
mov rax, [rbp+var_38]
mov [rbp+var_8], rax
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_10], rax
mov rcx, [rbp+var_10]
mov rax, [rbp+var_60]
xor rcx, [rax]
mov [rax], rcx
mov rax, [rbp+var_60]
add rax, 8
mov [rbp+var_60], rax
mov rax, [rbp+var_38]
add rax, 8
mov [rbp+var_38], rax
mov rax, [rbp+var_40]
sub rax, 8
mov [rbp+var_40], rax
jmp short loc_9B045
loc_9B093:
jmp short $+2
loc_9B095:
cmp [rbp+var_40], 0
jbe short loc_9B0CE
mov rax, [rbp+var_38]
mov cl, [rax]
mov rax, [rbp+var_70]
mov [rax], cl
mov rax, [rbp+var_70]
add rax, 1
mov [rbp+var_70], rax
mov rax, [rbp+var_38]
add rax, 1
mov [rbp+var_38], rax
mov rax, [rbp+var_40]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_40], rax
jmp short loc_9B095
loc_9B0CE:
mov rax, [rbp+var_70]
mov byte ptr [rax], 1
mov rcx, [rbp+var_68]
mov rax, [rbp+var_60]
xor rcx, [rax]
mov [rax], rcx
mov rax, [rbp+var_50]
shr rax, 3
sub rax, 1
mov rcx, 8000000000000000h
xor rcx, [rbp+rax*8+var_140]
mov [rbp+rax*8+var_140], rcx
lea rdi, [rbp+var_140]
call cs:keccakf1600_best
mov [rbp+var_58], 0
loc_9B11E:
mov rax, [rbp+var_58]
mov rcx, [rbp+var_48]
shr rcx, 3
cmp rax, rcx
jnb short loc_9B155
mov rax, [rbp+var_58]
mov rdx, [rbp+rax*8+var_140]
mov rax, [rbp+var_28]
mov rcx, [rbp+var_58]
mov [rax+rcx*8], rdx
mov rax, [rbp+var_58]
add rax, 1
mov [rbp+var_58], rax
jmp short loc_9B11E
loc_9B155:
mov rax, [rbp+var_150]
add rsp, 150h
pop rbp
retn
|
long long ethash_keccak512_64(long long a1, char *a2)
{
_QWORD v3[26]; // [rsp+10h] [rbp-140h] BYREF
char *v4; // [rsp+E0h] [rbp-70h]
long long v5; // [rsp+E8h] [rbp-68h] BYREF
_QWORD *v6; // [rsp+F0h] [rbp-60h]
unsigned long long i; // [rsp+F8h] [rbp-58h]
unsigned long long v8; // [rsp+100h] [rbp-50h]
unsigned long long v9; // [rsp+108h] [rbp-48h]
unsigned long long v10; // [rsp+110h] [rbp-40h]
char *v11; // [rsp+118h] [rbp-38h]
long long v12; // [rsp+120h] [rbp-30h]
long long v13; // [rsp+128h] [rbp-28h]
long long v14; // [rsp+130h] [rbp-20h]
char *v15; // [rsp+138h] [rbp-18h]
long long v16; // [rsp+140h] [rbp-10h]
char *v17; // [rsp+148h] [rbp-8h]
v13 = a1;
v12 = 512LL;
v11 = a2;
v10 = 64LL;
v9 = 64LL;
v8 = 72LL;
v5 = 0LL;
v4 = (char *)&v5;
memset(v3, 0LL, 200LL);
while ( v10 >= v8 )
{
for ( i = 0LL; i < v8 >> 3; ++i )
{
v15 = v11;
v14 = *(_QWORD *)v11;
v3[i] ^= v14;
v11 += 8;
}
keccakf1600_best();
v10 -= v8;
}
v6 = v3;
while ( v10 >= 8 )
{
v17 = v11;
v16 = *(_QWORD *)v11;
*v6++ ^= v16;
v11 += 8;
v10 -= 8LL;
}
qmemcpy(v4, v11, v10);
v11 += v10;
v4 += v10;
v10 = 0LL;
*v4 = 1;
*v6 ^= v5;
v3[(v8 >> 3) - 1] ^= 0x8000000000000000LL;
keccakf1600_best();
for ( i = 0LL; i < v9 >> 3; ++i )
*(_QWORD *)(v13 + 8 * i) = v3[i];
return a1;
}
|
ethash_keccak512_64:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x150
MOV RAX,RDI
MOV qword ptr [RBP + -0x150],RAX
MOV qword ptr [RBP + -0x148],RSI
MOV RAX,qword ptr [RBP + -0x148]
MOV qword ptr [RBP + -0x28],RDI
MOV qword ptr [RBP + -0x30],0x200
MOV qword ptr [RBP + -0x38],RAX
MOV qword ptr [RBP + -0x40],0x40
MOV RAX,qword ptr [RBP + -0x30]
SHR RAX,0x3
MOV qword ptr [RBP + -0x48],RAX
MOV RCX,qword ptr [RBP + -0x30]
SHL RCX,0x1
MOV EAX,0x640
SUB RAX,RCX
SHR RAX,0x3
MOV qword ptr [RBP + -0x50],RAX
MOV qword ptr [RBP + -0x68],0x0
LEA RAX,[RBP + -0x68]
MOV qword ptr [RBP + -0x70],RAX
LEA RDI,[RBP + -0x140]
XOR ESI,ESI
MOV EDX,0xc8
CALL 0x001231c0
LAB_0019afb1:
MOV RAX,qword ptr [RBP + -0x40]
CMP RAX,qword ptr [RBP + -0x50]
JC 0x0019b03a
MOV qword ptr [RBP + -0x58],0x0
LAB_0019afc3:
MOV RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x50]
SHR RCX,0x3
CMP RAX,RCX
JNC 0x0019b019
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x20],RAX
MOV RCX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x58]
XOR RCX,qword ptr [RBP + RAX*0x8 + -0x140]
MOV qword ptr [RBP + RAX*0x8 + -0x140],RCX
MOV RAX,qword ptr [RBP + -0x38]
ADD RAX,0x8
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x1
MOV qword ptr [RBP + -0x58],RAX
JMP 0x0019afc3
LAB_0019b019:
LEA RDI,[RBP + -0x140]
CALL qword ptr [0x00239488]
MOV RCX,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RBP + -0x40]
SUB RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
JMP 0x0019afb1
LAB_0019b03a:
LEA RAX,[RBP + -0x140]
MOV qword ptr [RBP + -0x60],RAX
LAB_0019b045:
CMP qword ptr [RBP + -0x40],0x8
JC 0x0019b093
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x8],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x10],RAX
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x60]
XOR RCX,qword ptr [RAX]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x60]
ADD RAX,0x8
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x38]
ADD RAX,0x8
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x40]
SUB RAX,0x8
MOV qword ptr [RBP + -0x40],RAX
JMP 0x0019b045
LAB_0019b093:
JMP 0x0019b095
LAB_0019b095:
CMP qword ptr [RBP + -0x40],0x0
JBE 0x0019b0ce
MOV RAX,qword ptr [RBP + -0x38]
MOV CL,byte ptr [RAX]
MOV RAX,qword ptr [RBP + -0x70]
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x70]
ADD RAX,0x1
MOV qword ptr [RBP + -0x70],RAX
MOV RAX,qword ptr [RBP + -0x38]
ADD RAX,0x1
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x40]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x40],RAX
JMP 0x0019b095
LAB_0019b0ce:
MOV RAX,qword ptr [RBP + -0x70]
MOV byte ptr [RAX],0x1
MOV RCX,qword ptr [RBP + -0x68]
MOV RAX,qword ptr [RBP + -0x60]
XOR RCX,qword ptr [RAX]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x50]
SHR RAX,0x3
SUB RAX,0x1
MOV RCX,-0x8000000000000000
XOR RCX,qword ptr [RBP + RAX*0x8 + -0x140]
MOV qword ptr [RBP + RAX*0x8 + -0x140],RCX
LEA RDI,[RBP + -0x140]
CALL qword ptr [0x00239488]
MOV qword ptr [RBP + -0x58],0x0
LAB_0019b11e:
MOV RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x48]
SHR RCX,0x3
CMP RAX,RCX
JNC 0x0019b155
MOV RAX,qword ptr [RBP + -0x58]
MOV RDX,qword ptr [RBP + RAX*0x8 + -0x140]
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RBP + -0x58]
MOV qword ptr [RAX + RCX*0x8],RDX
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x1
MOV qword ptr [RBP + -0x58],RAX
JMP 0x0019b11e
LAB_0019b155:
MOV RAX,qword ptr [RBP + -0x150]
ADD RSP,0x150
POP RBP
RET
|
long ethash_keccak512_64(long param_1,ulong *param_2)
{
long lVar1;
ulong local_148 [26];
ulong *local_78;
ulong local_70;
ulong *local_68;
ulong local_60;
ulong local_58;
ulong local_50;
ulong local_48;
ulong *local_40;
int8 local_38;
long local_30;
ulong local_28;
ulong *local_20;
ulong local_18;
ulong *local_10;
local_38 = 0x200;
local_48 = 0x40;
local_50 = 0x40;
local_58 = 0x48;
local_70 = 0;
local_78 = &local_70;
local_40 = param_2;
local_30 = param_1;
memset(local_148,0,200);
for (; local_58 <= local_48; local_48 = local_48 - local_58) {
for (local_60 = 0; local_60 < local_58 >> 3; local_60 = local_60 + 1) {
local_20 = local_40;
local_28 = *local_40;
local_148[local_60] = *local_40 ^ local_148[local_60];
local_40 = local_40 + 1;
}
(*(code *)keccakf1600_best)(local_148);
}
local_68 = local_148;
for (; 7 < local_48; local_48 = local_48 - 8) {
local_10 = local_40;
local_18 = *local_40;
*local_68 = *local_40 ^ *local_68;
local_68 = local_68 + 1;
local_40 = local_40 + 1;
}
for (; local_48 != 0; local_48 = local_48 - 1) {
*(char *)local_78 = (char)*local_40;
local_78 = (ulong *)((long)local_78 + 1);
local_40 = (ulong *)((long)local_40 + 1);
}
*(int1 *)local_78 = 1;
*local_68 = local_70 ^ *local_68;
lVar1 = (local_58 >> 3) - 1;
local_148[lVar1] = local_148[lVar1] ^ 0x8000000000000000;
(*(code *)keccakf1600_best)(local_148);
for (local_60 = 0; local_60 < local_50 >> 3; local_60 = local_60 + 1) {
*(ulong *)(local_30 + local_60 * 8) = local_148[local_60];
}
return param_1;
}
|
|
64,827 |
nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::~serializer()
|
monkey531[P]llama/common/json.hpp
|
~serializer() = default;
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::~serializer():
pushq %rbx
movq %rdi, %rbx
movq 0x260(%rdi), %rdi
leaq 0x270(%rbx), %rax
cmpq %rax, %rdi
je 0x7a41a
movq (%rax), %rsi
incq %rsi
callq 0x186a0
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x7a429
popq %rbx
jmp 0x2f99c
popq %rbx
retq
nop
|
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEED2Ev:
push rbx
mov rbx, rdi
mov rdi, [rdi+260h]; void *
lea rax, [rbx+270h]
cmp rdi, rax
jz short loc_7A41A
mov rsi, [rax]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_7A41A:
mov rdi, [rbx+8]
test rdi, rdi
jz short loc_7A429
pop rbx
jmp _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_7A429:
pop rbx
retn
|
void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::~serializer(
_QWORD *a1)
{
_QWORD *v2; // rdi
volatile signed __int32 *v3; // rdi
v2 = (_QWORD *)a1[76];
if ( v2 != a1 + 78 )
operator delete(v2, a1[78] + 1LL);
v3 = (volatile signed __int32 *)a1[1];
if ( v3 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v3);
}
|
~serializer:
PUSH RBX
MOV RBX,RDI
MOV RDI,qword ptr [RDI + 0x260]
LEA RAX,[RBX + 0x270]
CMP RDI,RAX
JZ 0x0017a41a
MOV RSI,qword ptr [RAX]
INC RSI
CALL 0x001186a0
LAB_0017a41a:
MOV RDI,qword ptr [RBX + 0x8]
TEST RDI,RDI
JZ 0x0017a429
POP RBX
JMP 0x0012f99c
LAB_0017a429:
POP RBX
RET
|
/* nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >::~serializer() */
void __thiscall
nlohmann::json_abi_v3_11_3::detail::
serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::~serializer(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*this)
{
if (*(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
**)(this + 0x260) != this + 0x270) {
operator_delete(*(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
**)(this + 0x260),*(long *)(this + 0x270) + 1);
}
if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 8) !=
(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release
(*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 8));
return;
}
return;
}
|
|
64,828 |
my_hash_sort_latin1_de
|
eloqsql/strings/ctype-latin1.c
|
void my_hash_sort_latin1_de(CHARSET_INFO *cs __attribute__((unused)),
const uchar *key, size_t len,
ulong *nr1, ulong *nr2)
{
const uchar *end;
register ulong m1= *nr1, m2= *nr2;
/*
Remove end space. We have to do this to be able to compare
'AE' and 'Ä' as identical
*/
end= skip_trailing_space(key, len);
for (; key < end ; key++)
{
uint X= (uint) combo1map[(uint) *key];
MY_HASH_ADD(m1, m2, X);
if ((X= combo2map[*key]))
{
MY_HASH_ADD(m1, m2, X);
}
}
*nr1= m1;
*nr2= m2;
}
|
O0
|
c
|
my_hash_sort_latin1_de:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x28c40
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
cmpq -0x30(%rbp), %rax
jae 0x28c21
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %eax
movl %eax, %ecx
leaq 0x5649d(%rip), %rax # 0x7f020
movzbl (%rax,%rcx), %eax
movl %eax, -0x44(%rbp)
movq -0x38(%rbp), %rax
andq $0x3f, %rax
addq -0x40(%rbp), %rax
movl -0x44(%rbp), %ecx
imulq %rcx, %rax
movq -0x38(%rbp), %rcx
shlq $0x8, %rcx
addq %rcx, %rax
xorq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x40(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %ecx
leaq 0x56554(%rip), %rax # 0x7f120
movzbl (%rax,%rcx), %eax
movl %eax, -0x44(%rbp)
cmpl $0x0, %eax
je 0x28c0e
jmp 0x28bda
movq -0x38(%rbp), %rax
andq $0x3f, %rax
addq -0x40(%rbp), %rax
movl -0x44(%rbp), %ecx
imulq %rcx, %rax
movq -0x38(%rbp), %rcx
shlq $0x8, %rcx
addq %rcx, %rax
xorq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x40(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x40(%rbp)
jmp 0x28c0e
jmp 0x28c10
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x28b63
movq -0x38(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movq -0x40(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax)
|
my_hash_sort_latin1_de:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov rax, [rbp+var_20]
mov rax, [rax]
mov [rbp+var_38], rax
mov rax, [rbp+var_28]
mov rax, [rax]
mov [rbp+var_40], rax
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call skip_trailing_space
mov [rbp+var_30], rax
loc_28B63:
mov rax, [rbp+var_10]
cmp rax, [rbp+var_30]
jnb loc_28C21
mov rax, [rbp+var_10]
movzx eax, byte ptr [rax]
mov eax, eax
mov ecx, eax
lea rax, combo1map
movzx eax, byte ptr [rax+rcx]
mov [rbp+var_44], eax
mov rax, [rbp+var_38]
and rax, 3Fh
add rax, [rbp+var_40]
mov ecx, [rbp+var_44]
imul rax, rcx
mov rcx, [rbp+var_38]
shl rcx, 8
add rax, rcx
xor rax, [rbp+var_38]
mov [rbp+var_38], rax
mov rax, [rbp+var_40]
add rax, 3
mov [rbp+var_40], rax
mov rax, [rbp+var_10]
movzx eax, byte ptr [rax]
mov ecx, eax
lea rax, combo2map
movzx eax, byte ptr [rax+rcx]
mov [rbp+var_44], eax
cmp eax, 0
jz short loc_28C0E
jmp short $+2
loc_28BDA:
mov rax, [rbp+var_38]
and rax, 3Fh
add rax, [rbp+var_40]
mov ecx, [rbp+var_44]
imul rax, rcx
mov rcx, [rbp+var_38]
shl rcx, 8
add rax, rcx
xor rax, [rbp+var_38]
mov [rbp+var_38], rax
mov rax, [rbp+var_40]
add rax, 3
mov [rbp+var_40], rax
jmp short $+2
loc_28C0E:
jmp short $+2
loc_28C10:
mov rax, [rbp+var_10]
add rax, 1
mov [rbp+var_10], rax
jmp loc_28B63
loc_28C21:
mov rcx, [rbp+var_38]
mov rax, [rbp+var_20]
mov [rax], rcx
mov rcx, [rbp+var_40]
mov rax, [rbp+var_28]
mov [rax], rcx
add rsp, 50h
pop rbp
retn
|
_QWORD * my_hash_sort_latin1_de(long long a1, unsigned __int8 *a2, long long a3, long long *a4, _QWORD *a5)
{
_QWORD *result; // rax
long long v6; // [rsp+10h] [rbp-40h]
long long v7; // [rsp+18h] [rbp-38h]
unsigned long long v8; // [rsp+20h] [rbp-30h]
unsigned __int8 *v11; // [rsp+40h] [rbp-10h]
v11 = a2;
v7 = *a4;
v6 = *a5;
v8 = skip_trailing_space(a2, a3);
while ( (unsigned long long)v11 < v8 )
{
v7 ^= (v7 << 8) + combo1map[*v11] * (v6 + (v7 & 0x3F));
v6 += 3LL;
if ( combo2map[*v11] )
{
v7 ^= (v7 << 8) + combo2map[*v11] * (v6 + (v7 & 0x3F));
v6 += 3LL;
}
++v11;
}
*a4 = v7;
result = a5;
*a5 = v6;
return result;
}
|
my_hash_sort_latin1_de:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x40],RAX
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x00128c40
MOV qword ptr [RBP + -0x30],RAX
LAB_00128b63:
MOV RAX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RBP + -0x30]
JNC 0x00128c21
MOV RAX,qword ptr [RBP + -0x10]
MOVZX EAX,byte ptr [RAX]
MOV EAX,EAX
MOV ECX,EAX
LEA RAX,[0x17f020]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV dword ptr [RBP + -0x44],EAX
MOV RAX,qword ptr [RBP + -0x38]
AND RAX,0x3f
ADD RAX,qword ptr [RBP + -0x40]
MOV ECX,dword ptr [RBP + -0x44]
IMUL RAX,RCX
MOV RCX,qword ptr [RBP + -0x38]
SHL RCX,0x8
ADD RAX,RCX
XOR RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x40]
ADD RAX,0x3
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOVZX EAX,byte ptr [RAX]
MOV ECX,EAX
LEA RAX,[0x17f120]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV dword ptr [RBP + -0x44],EAX
CMP EAX,0x0
JZ 0x00128c0e
JMP 0x00128bda
LAB_00128bda:
MOV RAX,qword ptr [RBP + -0x38]
AND RAX,0x3f
ADD RAX,qword ptr [RBP + -0x40]
MOV ECX,dword ptr [RBP + -0x44]
IMUL RAX,RCX
MOV RCX,qword ptr [RBP + -0x38]
SHL RCX,0x8
ADD RAX,RCX
XOR RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x40]
ADD RAX,0x3
MOV qword ptr [RBP + -0x40],RAX
JMP 0x00128c0e
LAB_00128c0e:
JMP 0x00128c10
LAB_00128c10:
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x1
MOV qword ptr [RBP + -0x10],RAX
JMP 0x00128b63
LAB_00128c21:
MOV RCX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
ADD RSP,0x50
POP RBP
RET
|
void my_hash_sort_latin1_de
(int8 param_1,byte *param_2,int8 param_3,ulong *param_4,long *param_5)
{
long lVar1;
byte *pbVar2;
long local_48;
ulong local_40;
byte *local_18;
local_40 = *param_4;
local_48 = *param_5;
pbVar2 = (byte *)skip_trailing_space(param_2,param_3);
for (local_18 = param_2; local_18 < pbVar2; local_18 = local_18 + 1) {
local_40 = ((local_40 & 0x3f) + local_48) * (ulong)(byte)combo1map[*local_18] + local_40 * 0x100
^ local_40;
lVar1 = local_48 + 3;
if ((byte)combo2map[*local_18] != 0) {
local_40 = ((local_40 & 0x3f) + local_48 + 3) * (ulong)(uint)(byte)combo2map[*local_18] +
local_40 * 0x100 ^ local_40;
lVar1 = local_48 + 6;
}
local_48 = lVar1;
}
*param_4 = local_40;
*param_5 = local_48;
return;
}
|
|
64,829 |
my_error_register
|
eloqsql/mysys/my_error.c
|
int my_error_register(const char** (*get_errmsgs)(int error), uint first,
uint last)
{
struct my_err_head *meh_p;
struct my_err_head **search_meh_pp;
/* Allocate a new header structure. */
if (! (meh_p= (struct my_err_head*) my_malloc(key_memory_my_err_head,
sizeof(struct my_err_head),
MYF(MY_WME))))
return 1;
meh_p->get_errmsgs= get_errmsgs;
meh_p->meh_first= first;
meh_p->meh_last= last;
/* Search for the right position in the list. */
for (search_meh_pp= &my_errmsgs_list;
*search_meh_pp;
search_meh_pp= &(*search_meh_pp)->meh_next)
{
if ((*search_meh_pp)->meh_last > first)
break;
}
/* Error numbers must be unique. No overlapping is allowed. */
if (*search_meh_pp && ((*search_meh_pp)->meh_first <= last))
{
my_free(meh_p);
return 1;
}
/* Insert header into the chain. */
meh_p->meh_next= *search_meh_pp;
*search_meh_pp= meh_p;
return 0;
}
|
O0
|
c
|
my_error_register:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
leaq 0x36e2b7(%rip), %rax # 0x3b1b40
movl (%rax), %edi
movl $0x18, %esi
movl $0x10, %edx
callq 0x30b00
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
jne 0x438b0
movl $0x1, -0x4(%rbp)
jmp 0x43950
movq -0x10(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x8(%rax)
movl -0x14(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x10(%rax)
movl -0x18(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x14(%rax)
leaq 0x1a6971(%rip), %rax # 0x1ea248
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
cmpq $0x0, (%rax)
je 0x43905
movq -0x28(%rbp), %rax
movq (%rax), %rax
movl 0x14(%rax), %eax
cmpl -0x14(%rbp), %eax
jbe 0x438f6
jmp 0x43905
jmp 0x438f8
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x28(%rbp)
jmp 0x438db
movq -0x28(%rbp), %rax
cmpq $0x0, (%rax)
je 0x43930
movq -0x28(%rbp), %rax
movq (%rax), %rax
movl 0x10(%rax), %eax
cmpl -0x18(%rbp), %eax
ja 0x43930
movq -0x20(%rbp), %rdi
callq 0x30e80
movl $0x1, -0x4(%rbp)
jmp 0x43950
movq -0x28(%rbp), %rax
movq (%rax), %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movq -0x20(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
|
my_error_register:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
lea rax, key_memory_my_err_head
mov edi, [rax]
mov esi, 18h
mov edx, 10h
call my_malloc
mov [rbp+var_20], rax
cmp rax, 0
jnz short loc_438B0
mov [rbp+var_4], 1
jmp loc_43950
loc_438B0:
mov rcx, [rbp+var_10]
mov rax, [rbp+var_20]
mov [rax+8], rcx
mov ecx, [rbp+var_14]
mov rax, [rbp+var_20]
mov [rax+10h], ecx
mov ecx, [rbp+var_18]
mov rax, [rbp+var_20]
mov [rax+14h], ecx
lea rax, my_errmsgs_list
mov [rbp+var_28], rax
loc_438DB:
mov rax, [rbp+var_28]
cmp qword ptr [rax], 0
jz short loc_43905
mov rax, [rbp+var_28]
mov rax, [rax]
mov eax, [rax+14h]
cmp eax, [rbp+var_14]
jbe short loc_438F6
jmp short loc_43905
loc_438F6:
jmp short $+2
loc_438F8:
mov rax, [rbp+var_28]
mov rax, [rax]
mov [rbp+var_28], rax
jmp short loc_438DB
loc_43905:
mov rax, [rbp+var_28]
cmp qword ptr [rax], 0
jz short loc_43930
mov rax, [rbp+var_28]
mov rax, [rax]
mov eax, [rax+10h]
cmp eax, [rbp+var_18]
ja short loc_43930
mov rdi, [rbp+var_20]
call my_free
mov [rbp+var_4], 1
jmp short loc_43950
loc_43930:
mov rax, [rbp+var_28]
mov rcx, [rax]
mov rax, [rbp+var_20]
mov [rax], rcx
mov rcx, [rbp+var_20]
mov rax, [rbp+var_28]
mov [rax], rcx
mov [rbp+var_4], 0
loc_43950:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
|
long long my_error_register(long long a1, unsigned int a2, unsigned int a3)
{
long long **i; // [rsp+8h] [rbp-28h]
long long v5; // [rsp+10h] [rbp-20h]
v5 = my_malloc(key_memory_my_err_head, 0x18uLL, 16);
if ( v5 )
{
*(_QWORD *)(v5 + 8) = a1;
*(_DWORD *)(v5 + 16) = a2;
*(_DWORD *)(v5 + 20) = a3;
for ( i = &my_errmsgs_list; *i && *((_DWORD *)*i + 5) <= a2; i = (long long **)*i )
;
if ( *i && *((_DWORD *)*i + 4) <= a3 )
{
my_free(v5);
return 1;
}
else
{
*(_QWORD *)v5 = *i;
*i = (long long *)v5;
return 0;
}
}
else
{
return 1;
}
}
|
my_error_register:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV dword ptr [RBP + -0x18],EDX
LEA RAX,[0x4b1b40]
MOV EDI,dword ptr [RAX]
MOV ESI,0x18
MOV EDX,0x10
CALL 0x00130b00
MOV qword ptr [RBP + -0x20],RAX
CMP RAX,0x0
JNZ 0x001438b0
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00143950
LAB_001438b0:
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX + 0x8],RCX
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX + 0x10],ECX
MOV ECX,dword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX + 0x14],ECX
LEA RAX,[0x2ea248]
MOV qword ptr [RBP + -0x28],RAX
LAB_001438db:
MOV RAX,qword ptr [RBP + -0x28]
CMP qword ptr [RAX],0x0
JZ 0x00143905
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX + 0x14]
CMP EAX,dword ptr [RBP + -0x14]
JBE 0x001438f6
JMP 0x00143905
LAB_001438f6:
JMP 0x001438f8
LAB_001438f8:
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x28],RAX
JMP 0x001438db
LAB_00143905:
MOV RAX,qword ptr [RBP + -0x28]
CMP qword ptr [RAX],0x0
JZ 0x00143930
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX + 0x10]
CMP EAX,dword ptr [RBP + -0x18]
JA 0x00143930
MOV RDI,qword ptr [RBP + -0x20]
CALL 0x00130e80
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00143950
LAB_00143930:
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x0
LAB_00143950:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
int4 my_error_register(long param_1,uint param_2,uint param_3)
{
long *plVar1;
int **local_30;
int4 local_c;
plVar1 = (long *)my_malloc(key_memory_my_err_head,0x18,0x10);
if (plVar1 == (long *)0x0) {
local_c = 1;
}
else {
plVar1[1] = param_1;
*(uint *)(plVar1 + 2) = param_2;
*(uint *)((long)plVar1 + 0x14) = param_3;
for (local_30 = &my_errmsgs_list;
(*local_30 != (int *)0x0 && (*(uint *)(*local_30 + 0x14) <= param_2));
local_30 = (int **)*local_30) {
}
if ((*local_30 == (int *)0x0) || (param_3 < *(uint *)(*local_30 + 0x10))) {
*plVar1 = (long)*local_30;
*local_30 = (int *)plVar1;
local_c = 0;
}
else {
my_free(plVar1);
local_c = 1;
}
}
return local_c;
}
|
|
64,830 |
mi_update_status
|
eloqsql/storage/myisam/mi_locking.c
|
void mi_update_status(void* param)
{
MI_INFO *info=(MI_INFO*) param;
DBUG_ENTER("mi_update_status");
/*
Because someone may have closed the table we point at, we only
update the state if its our own state. This isn't a problem as
we are always pointing at our own lock or at a read lock.
(This is enforced by thr_multi_lock.c)
*/
if (info->state == &info->save_state)
{
DBUG_PRINT("info",
("updating status: key_file: %lu data_file: %lu rows: %lu",
(ulong) info->state->key_file_length,
(ulong) info->state->data_file_length,
(ulong) info->state->records));
if (info->state->key_file_length < info->s->state.state.key_file_length ||
info->state->data_file_length < info->s->state.state.data_file_length)
DBUG_PRINT("warning",("old info: key_file: %ld data_file: %ld",
(long) info->s->state.state.key_file_length,
(long) info->s->state.state.data_file_length));
info->s->state.state= *info->state;
#ifdef HAVE_QUERY_CACHE
DBUG_PRINT("info", ("invalidator... '%s' (status update)",
info->filename));
DBUG_ASSERT(info->s->chst_invalidator != NULL);
(*info->s->chst_invalidator)((const char *)info->filename);
#endif
}
info->state= &info->s->state.state;
info->append_insert_at_end= 0;
/*
We have to flush the write cache here as other threads may start
reading the table before mi_lock_database() is called
*/
if (info->opt_flag & WRITE_CACHE_USED)
{
if (end_io_cache(&info->rec_cache))
{
mi_print_error(info->s, HA_ERR_CRASHED);
mi_mark_crashed(info);
}
info->opt_flag&= ~WRITE_CACHE_USED;
}
DBUG_VOID_RETURN;
}
|
O3
|
c
|
mi_update_status:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x8(%rdi), %rax
leaq 0x10(%rdi), %rcx
cmpq %rcx, %rax
jne 0x30092
movq (%rbx), %rcx
movq 0x30(%rax), %rdx
movq %rdx, 0x48(%rcx)
movups (%rax), %xmm0
movups 0x10(%rax), %xmm1
movups 0x20(%rax), %xmm2
movups %xmm2, 0x38(%rcx)
movups %xmm1, 0x28(%rcx)
movups %xmm0, 0x18(%rcx)
movq (%rbx), %rax
movq 0xf8(%rbx), %rdi
callq *0x2f8(%rax)
movq (%rbx), %rax
addq $0x18, %rax
movq %rax, 0x8(%rbx)
movb $0x0, 0x33a(%rbx)
testb $0x10, 0x1c8(%rbx)
je 0x300f8
leaq 0x220(%rbx), %rdi
callq 0x50f4f
testl %eax, %eax
je 0x300f1
movq (%rbx), %rax
movq 0x268(%rax), %rsi
movl $0x7e, %edi
callq 0x474b6
movq (%rbx), %rax
orb $0x2, 0xf0(%rax)
leaq 0x6448e(%rip), %rdx # 0x94570
movq %rbx, %rdi
xorl %esi, %esi
movl $0x164, %ecx # imm = 0x164
callq 0x2bc9a
andb $-0x11, 0x1c8(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
|
mi_update_status:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdi
mov rax, [rdi+8]
lea rcx, [rdi+10h]
cmp rax, rcx
jnz short loc_30092
mov rcx, [rbx]
mov rdx, [rax+30h]
mov [rcx+48h], rdx
movups xmm0, xmmword ptr [rax]
movups xmm1, xmmword ptr [rax+10h]
movups xmm2, xmmword ptr [rax+20h]
movups xmmword ptr [rcx+38h], xmm2
movups xmmword ptr [rcx+28h], xmm1
movups xmmword ptr [rcx+18h], xmm0
mov rax, [rbx]
mov rdi, [rbx+0F8h]
call qword ptr [rax+2F8h]
loc_30092:
mov rax, [rbx]
add rax, 18h
mov [rbx+8], rax
mov byte ptr [rbx+33Ah], 0
test byte ptr [rbx+1C8h], 10h
jz short loc_300F8
lea rdi, [rbx+220h]
call end_io_cache
test eax, eax
jz short loc_300F1
mov rax, [rbx]
mov rsi, [rax+268h]
mov edi, 7Eh ; '~'
call mi_report_error
mov rax, [rbx]
or byte ptr [rax+0F0h], 2
lea rdx, aWorkspaceLlm4b_1; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, rbx
xor esi, esi
mov ecx, 164h
call _mi_report_crashed
loc_300F1:
and byte ptr [rbx+1C8h], 0EFh
loc_300F8:
add rsp, 8
pop rbx
pop rbp
retn
|
void mi_update_status(_BYTE *a1)
{
__int128 *v1; // rax
long long v2; // rcx
__int128 v3; // xmm0
__int128 v4; // xmm1
v1 = (__int128 *)*((_QWORD *)a1 + 1);
if ( v1 == (__int128 *)(a1 + 16) )
{
v2 = *(_QWORD *)a1;
*(_QWORD *)(v2 + 72) = *((_QWORD *)v1 + 6);
v3 = *v1;
v4 = v1[1];
*(_OWORD *)(v2 + 56) = v1[2];
*(_OWORD *)(v2 + 40) = v4;
*(_OWORD *)(v2 + 24) = v3;
(*(void ( **)(_QWORD))(*(_QWORD *)a1 + 760LL))(*((_QWORD *)a1 + 31));
}
*((_QWORD *)a1 + 1) = *(_QWORD *)a1 + 24LL;
a1[826] = 0;
if ( (a1[456] & 0x10) != 0 )
{
if ( (unsigned int)end_io_cache(a1 + 544) )
{
mi_report_error(126LL, *(_QWORD *)(*(_QWORD *)a1 + 616LL));
*(_BYTE *)(*(_QWORD *)a1 + 240LL) |= 2u;
mi_report_crashed();
}
a1[456] &= ~0x10u;
}
}
|
mi_update_status:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV RAX,qword ptr [RDI + 0x8]
LEA RCX,[RDI + 0x10]
CMP RAX,RCX
JNZ 0x00130092
MOV RCX,qword ptr [RBX]
MOV RDX,qword ptr [RAX + 0x30]
MOV qword ptr [RCX + 0x48],RDX
MOVUPS XMM0,xmmword ptr [RAX]
MOVUPS XMM1,xmmword ptr [RAX + 0x10]
MOVUPS XMM2,xmmword ptr [RAX + 0x20]
MOVUPS xmmword ptr [RCX + 0x38],XMM2
MOVUPS xmmword ptr [RCX + 0x28],XMM1
MOVUPS xmmword ptr [RCX + 0x18],XMM0
MOV RAX,qword ptr [RBX]
MOV RDI,qword ptr [RBX + 0xf8]
CALL qword ptr [RAX + 0x2f8]
LAB_00130092:
MOV RAX,qword ptr [RBX]
ADD RAX,0x18
MOV qword ptr [RBX + 0x8],RAX
MOV byte ptr [RBX + 0x33a],0x0
TEST byte ptr [RBX + 0x1c8],0x10
JZ 0x001300f8
LEA RDI,[RBX + 0x220]
CALL 0x00150f4f
TEST EAX,EAX
JZ 0x001300f1
MOV RAX,qword ptr [RBX]
MOV RSI,qword ptr [RAX + 0x268]
MOV EDI,0x7e
CALL 0x001474b6
MOV RAX,qword ptr [RBX]
OR byte ptr [RAX + 0xf0],0x2
LEA RDX,[0x194570]
MOV RDI,RBX
XOR ESI,ESI
MOV ECX,0x164
CALL 0x0012bc9a
LAB_001300f1:
AND byte ptr [RBX + 0x1c8],0xef
LAB_001300f8:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
void mi_update_status(long *param_1)
{
long *plVar1;
long lVar2;
int4 uVar3;
int4 uVar4;
int4 uVar5;
int4 uVar6;
int4 uVar7;
int4 uVar8;
long lVar9;
long lVar10;
long lVar11;
long lVar12;
long lVar13;
int iVar14;
plVar1 = (long *)param_1[1];
if (plVar1 == param_1 + 2) {
lVar2 = *param_1;
*(long *)(lVar2 + 0x48) = plVar1[6];
lVar9 = *plVar1;
uVar3 = *(int4 *)((long)plVar1 + 4);
lVar10 = plVar1[1];
uVar4 = *(int4 *)((long)plVar1 + 0xc);
lVar11 = plVar1[2];
uVar5 = *(int4 *)((long)plVar1 + 0x14);
lVar12 = plVar1[3];
uVar6 = *(int4 *)((long)plVar1 + 0x1c);
uVar7 = *(int4 *)((long)plVar1 + 0x24);
lVar13 = plVar1[5];
uVar8 = *(int4 *)((long)plVar1 + 0x2c);
*(int *)(lVar2 + 0x38) = (int)plVar1[4];
*(int4 *)(lVar2 + 0x3c) = uVar7;
*(int *)(lVar2 + 0x40) = (int)lVar13;
*(int4 *)(lVar2 + 0x44) = uVar8;
*(int *)(lVar2 + 0x28) = (int)lVar11;
*(int4 *)(lVar2 + 0x2c) = uVar5;
*(int *)(lVar2 + 0x30) = (int)lVar12;
*(int4 *)(lVar2 + 0x34) = uVar6;
*(int *)(lVar2 + 0x18) = (int)lVar9;
*(int4 *)(lVar2 + 0x1c) = uVar3;
*(int *)(lVar2 + 0x20) = (int)lVar10;
*(int4 *)(lVar2 + 0x24) = uVar4;
(**(code **)(*param_1 + 0x2f8))(param_1[0x1f]);
}
param_1[1] = *param_1 + 0x18;
*(int1 *)((long)param_1 + 0x33a) = 0;
if ((*(byte *)(param_1 + 0x39) & 0x10) != 0) {
iVar14 = end_io_cache(param_1 + 0x44);
if (iVar14 != 0) {
mi_report_error(0x7e,*(int8 *)(*param_1 + 0x268));
*(byte *)(*param_1 + 0xf0) = *(byte *)(*param_1 + 0xf0) | 2;
_mi_report_crashed(param_1,0,
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_locking.c",
0x164);
}
*(byte *)(param_1 + 0x39) = *(byte *)(param_1 + 0x39) & 0xef;
}
return;
}
|
|
64,831 |
minja::UnaryOpExpr::UnaryOpExpr(minja::Location const&, std::shared_ptr<minja::Expression>&&, minja::UnaryOpExpr::Op)
|
monkey531[P]llama/common/minja.hpp
|
Expression(const Location & location) : location(location) {}
|
O3
|
cpp
|
minja::UnaryOpExpr::UnaryOpExpr(minja::Location const&, std::shared_ptr<minja::Expression>&&, minja::UnaryOpExpr::Op):
leaq 0x94efd(%rip), %rax # 0x12e3a8
addq $0x10, %rax
movq %rax, (%rdi)
movq (%rsi), %rax
movq %rax, 0x8(%rdi)
movq 0x8(%rsi), %rax
movq %rax, 0x10(%rdi)
testq %rax, %rax
je 0x994dc
movq 0x96aab(%rip), %r9 # 0x12ff78
cmpb $0x0, (%r9)
je 0x994d8
incl 0x8(%rax)
jmp 0x994dc
lock
incl 0x8(%rax)
movq 0x10(%rsi), %rax
movq %rax, 0x18(%rdi)
leaq 0x954dd(%rip), %rax # 0x12e9c8
addq $0x10, %rax
movq %rax, (%rdi)
xorl %eax, %eax
movq %rax, 0x28(%rdi)
movups (%rdx), %xmm0
movq %rax, 0x8(%rdx)
movups %xmm0, 0x20(%rdi)
movq %rax, (%rdx)
movq %rax, 0x38(%rdi)
movups (%rcx), %xmm0
movq %rax, 0x8(%rcx)
movups %xmm0, 0x30(%rdi)
movq %rax, (%rcx)
movl %r8d, 0x40(%rdi)
retq
nop
|
_ZN5minja12BinaryOpExprC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEES7_NS0_2OpE:
lea rax, _ZTVN5minja10ExpressionE; `vtable for'minja::Expression
add rax, 10h
mov [rdi], rax
mov rax, [rsi]
mov [rdi+8], rax
mov rax, [rsi+8]
mov [rdi+10h], rax
test rax, rax
jz short loc_994DC
mov r9, cs:__libc_single_threaded_ptr
cmp byte ptr [r9], 0
jz short loc_994D8
inc dword ptr [rax+8]
jmp short loc_994DC
loc_994D8:
lock inc dword ptr [rax+8]
loc_994DC:
mov rax, [rsi+10h]
mov [rdi+18h], rax
lea rax, _ZTVN5minja12BinaryOpExprE; `vtable for'minja::BinaryOpExpr
add rax, 10h
mov [rdi], rax
xor eax, eax
mov [rdi+28h], rax
movups xmm0, xmmword ptr [rdx]
mov [rdx+8], rax
movups xmmword ptr [rdi+20h], xmm0
mov [rdx], rax
mov [rdi+38h], rax
movups xmm0, xmmword ptr [rcx]
mov [rcx+8], rax
movups xmmword ptr [rdi+30h], xmm0
mov [rcx], rax
mov [rdi+40h], r8d
retn
|
long long minja::BinaryOpExpr::BinaryOpExpr(long long a1, _QWORD *a2, __int128 *a3, __int128 *a4, int a5)
{
long long v5; // rax
long long result; // rax
__int128 v7; // xmm0
__int128 v8; // xmm0
*(_QWORD *)a1 = &`vtable for'minja::Expression + 2;
*(_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 = &`vtable for'minja::BinaryOpExpr + 2;
result = 0LL;
*(_QWORD *)(a1 + 40) = 0LL;
v7 = *a3;
*((_QWORD *)a3 + 1) = 0LL;
*(_OWORD *)(a1 + 32) = v7;
*(_QWORD *)a3 = 0LL;
*(_QWORD *)(a1 + 56) = 0LL;
v8 = *a4;
*((_QWORD *)a4 + 1) = 0LL;
*(_OWORD *)(a1 + 48) = v8;
*(_QWORD *)a4 = 0LL;
*(_DWORD *)(a1 + 64) = a5;
return result;
}
|
BinaryOpExpr:
LEA RAX,[0x22e3a8]
ADD RAX,0x10
MOV qword ptr [RDI],RAX
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 0x001994dc
MOV R9,qword ptr [0x0022ff78]
CMP byte ptr [R9],0x0
JZ 0x001994d8
INC dword ptr [RAX + 0x8]
JMP 0x001994dc
LAB_001994d8:
INC.LOCK dword ptr [RAX + 0x8]
LAB_001994dc:
MOV RAX,qword ptr [RSI + 0x10]
MOV qword ptr [RDI + 0x18],RAX
LEA RAX,[0x22e9c8]
ADD RAX,0x10
MOV qword ptr [RDI],RAX
XOR EAX,EAX
MOV qword ptr [RDI + 0x28],RAX
MOVUPS XMM0,xmmword ptr [RDX]
MOV qword ptr [RDX + 0x8],RAX
MOVUPS xmmword ptr [RDI + 0x20],XMM0
MOV qword ptr [RDX],RAX
MOV qword ptr [RDI + 0x38],RAX
MOVUPS XMM0,xmmword ptr [RCX]
MOV qword ptr [RCX + 0x8],RAX
MOVUPS xmmword ptr [RDI + 0x30],XMM0
MOV qword ptr [RCX],RAX
MOV dword ptr [RDI + 0x40],R8D
RET
|
/* minja::BinaryOpExpr::BinaryOpExpr(minja::Location const&, std::shared_ptr<minja::Expression>&&,
std::shared_ptr<minja::Expression>&&, minja::BinaryOpExpr::Op) */
void __thiscall
minja::BinaryOpExpr::BinaryOpExpr
(BinaryOpExpr *this,int8 *param_1,int8 *param_2,int8 *param_3,
int4 param_5)
{
long lVar1;
int8 uVar2;
*(int ***)this = &PTR___cxa_pure_virtual_0022e3b8;
*(int8 *)(this + 8) = *param_1;
lVar1 = param_1[1];
*(long *)(this + 0x10) = lVar1;
if (lVar1 != 0) {
if (*PTR___libc_single_threaded_0022ff78 == '\0') {
LOCK();
*(int *)(lVar1 + 8) = *(int *)(lVar1 + 8) + 1;
UNLOCK();
}
else {
*(int *)(lVar1 + 8) = *(int *)(lVar1 + 8) + 1;
}
}
*(int8 *)(this + 0x18) = param_1[2];
*(int ***)this = &PTR_do_evaluate_0022e9d8;
*(int8 *)(this + 0x28) = 0;
uVar2 = param_2[1];
param_2[1] = 0;
*(int8 *)(this + 0x20) = *param_2;
*(int8 *)(this + 0x28) = uVar2;
*param_2 = 0;
*(int8 *)(this + 0x38) = 0;
uVar2 = param_3[1];
param_3[1] = 0;
*(int8 *)(this + 0x30) = *param_3;
*(int8 *)(this + 0x38) = uVar2;
*param_3 = 0;
*(int4 *)(this + 0x40) = param_5;
return;
}
|
|
64,832 |
my_end
|
eloqsql/mysys/my_init.c
|
void my_end(int infoflag)
{
/*
this code is suboptimal to workaround a bug in
Sun CC: Sun C++ 5.6 2004/06/02 for x86, and should not be
optimized until this compiler is not in use anymore
*/
FILE *info_file= DBUG_FILE;
my_bool print_info= (info_file != stderr);
if (!my_init_done)
return;
/*
We do not use DBUG_ENTER here, as after cleanup DBUG is no longer
operational, so we cannot use DBUG_RETURN.
*/
DBUG_PRINT("info",("Shutting down: infoflag: %d print_info: %d",
infoflag, print_info));
if (!info_file)
{
info_file= stderr;
print_info= 0;
}
if ((infoflag & MY_CHECK_ERROR) || print_info)
{ /* Test if some file is left open */
char ebuff[512];
uint i, open_files, open_streams;
for (open_streams= open_files= i= 0 ; i < my_file_limit ; i++)
{
if (my_file_info[i].type == UNOPEN)
continue;
if (my_file_info[i].type == STREAM_BY_FOPEN ||
my_file_info[i].type == STREAM_BY_FDOPEN)
open_streams++;
else
open_files++;
#ifdef EXTRA_DEBUG
fprintf(stderr, EE(EE_FILE_NOT_CLOSED), my_file_info[i].name, i);
fputc('\n', stderr);
#endif
}
if (open_files || open_streams)
{
my_snprintf(ebuff, sizeof(ebuff), EE(EE_OPEN_WARNING),
open_files, open_streams);
my_message_stderr(EE_OPEN_WARNING, ebuff, ME_BELL);
DBUG_PRINT("error", ("%s", ebuff));
}
#ifdef CHECK_UNLIKELY
end_my_likely(info_file);
#endif
}
free_charsets();
my_error_unregister_all();
my_once_free();
if ((infoflag & MY_GIVE_INFO) || print_info)
{
#ifdef HAVE_GETRUSAGE
struct rusage rus;
#ifdef HAVE_valgrind
/* Purify assumes that rus is uninitialized after getrusage call */
bzero((char*) &rus, sizeof(rus));
#endif
if (!getrusage(RUSAGE_SELF, &rus))
fprintf(info_file,"\n\
User time %.2f, System time %.2f\n\
Maximum resident set size %ld, Integral resident set size %ld\n\
Non-physical pagefaults %ld, Physical pagefaults %ld, Swaps %ld\n\
Blocks in %ld out %ld, Messages in %ld out %ld, Signals %ld\n\
Voluntary context switches %ld, Involuntary context switches %ld\n",
(rus.ru_utime.tv_sec * SCALE_SEC +
rus.ru_utime.tv_usec / SCALE_USEC) / 100.0,
(rus.ru_stime.tv_sec * SCALE_SEC +
rus.ru_stime.tv_usec / SCALE_USEC) / 100.0,
rus.ru_maxrss, rus.ru_idrss,
rus.ru_minflt, rus.ru_majflt,
rus.ru_nswap, rus.ru_inblock, rus.ru_oublock,
rus.ru_msgsnd, rus.ru_msgrcv, rus.ru_nsignals,
rus.ru_nvcsw, rus.ru_nivcsw);
#endif
#if defined(_MSC_VER)
_CrtSetReportMode( _CRT_WARN, _CRTDBG_MODE_FILE );
_CrtSetReportFile( _CRT_WARN, _CRTDBG_FILE_STDERR );
_CrtSetReportMode( _CRT_ERROR, _CRTDBG_MODE_FILE );
_CrtSetReportFile( _CRT_ERROR, _CRTDBG_FILE_STDERR );
_CrtSetReportMode( _CRT_ASSERT, _CRTDBG_MODE_FILE );
_CrtSetReportFile( _CRT_ASSERT, _CRTDBG_FILE_STDERR );
_CrtCheckMemory();
#endif
}
my_thread_end();
my_thread_global_end();
if (!(infoflag & MY_DONT_FREE_DBUG))
DBUG_END(); /* Must be done as late as possible */
my_mutex_end();
#if defined(SAFE_MUTEX)
/*
Check on destroying of mutexes. A few may be left that will get cleaned
up by C++ destructors
*/
safe_mutex_end((infoflag & (MY_GIVE_INFO | MY_CHECK_ERROR)) ? stderr :
(FILE *) 0);
#endif /* defined(SAFE_MUTEX) */
#ifdef _WIN32
WSACleanup();
#endif
/* At very last, delete mysys key, it is used everywhere including DBUG */
pthread_key_delete(THR_KEY_mysys);
my_init_done= my_thr_key_mysys_exists= 0;
}
|
O0
|
c
|
my_end:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x308, %rsp # imm = 0x308
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
movl %edi, -0x234(%rbp)
movq 0x1b1942(%rip), %rax # 0x1e2fe0
movq (%rax), %rax
movq %rax, -0x240(%rbp)
movq -0x240(%rbp), %rax
movq 0x1b192a(%rip), %rcx # 0x1e2fe0
cmpq (%rcx), %rax
setne %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x241(%rbp)
leaq 0x37464a(%rip), %rax # 0x3a5d18
cmpb $0x0, (%rax)
jne 0x316d8
jmp 0x319d1
jmp 0x316da
jmp 0x316dc
cmpq $0x0, -0x240(%rbp)
jne 0x316fe
movq 0x1b18f3(%rip), %rax # 0x1e2fe0
movq (%rax), %rax
movq %rax, -0x240(%rbp)
movb $0x0, -0x241(%rbp)
movl -0x234(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0x3171c
movsbl -0x241(%rbp), %eax
cmpl $0x0, %eax
je 0x3183a
movl $0x0, -0x248(%rbp)
movl $0x0, -0x24c(%rbp)
movl $0x0, -0x250(%rbp)
movl -0x248(%rbp), %eax
leaq 0x1b2239(%rip), %rcx # 0x1e3980
cmpl (%rcx), %eax
jae 0x317de
leaq 0x1b2232(%rip), %rax # 0x1e3988
movq (%rax), %rax
movl -0x248(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
cmpl $0x0, 0x8(%rax)
jne 0x3176e
jmp 0x317ca
leaq 0x1b2213(%rip), %rax # 0x1e3988
movq (%rax), %rax
movl -0x248(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
cmpl $0x3, 0x8(%rax)
je 0x317a8
leaq 0x1b21f6(%rip), %rax # 0x1e3988
movq (%rax), %rax
movl -0x248(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
cmpl $0x4, 0x8(%rax)
jne 0x317b9
movl -0x250(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x250(%rbp)
jmp 0x317c8
movl -0x24c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24c(%rbp)
jmp 0x317ca
movl -0x248(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x248(%rbp)
jmp 0x3173a
cmpl $0x0, -0x24c(%rbp)
jne 0x317f0
cmpl $0x0, -0x250(%rbp)
je 0x31838
leaq -0x230(%rbp), %rdi
leaq 0x1b26c2(%rip), %rax # 0x1e3ec0
movq 0x90(%rax), %rdx
movl -0x24c(%rbp), %ecx
movl -0x250(%rbp), %r8d
movl $0x200, %esi # imm = 0x200
movb $0x0, %al
callq 0x86db0
leaq -0x230(%rbp), %rsi
movl $0x13, %edi
movl $0x4, %edx
callq 0x327d0
jmp 0x31836
jmp 0x31838
jmp 0x3183a
callq 0x28db0
callq 0x2cf50
callq 0x32be0
movl -0x234(%rbp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
jne 0x31867
movsbl -0x241(%rbp), %eax
cmpl $0x0, %eax
je 0x3198c
xorl %edi, %edi
leaq -0x2e0(%rbp), %rsi
callq 0x251c0
cmpl $0x0, %eax
jne 0x3198a
movq -0x240(%rbp), %rdi
imulq $0x64, -0x2e0(%rbp), %rax
movq %rax, -0x2f0(%rbp)
movq -0x2d8(%rbp), %rax
movl $0x2710, %ecx # imm = 0x2710
cqto
idivq %rcx
movq %rax, %rcx
movq -0x2f0(%rbp), %rax
addq %rcx, %rax
cvtsi2sd %rax, %xmm0
movsd 0x5e871(%rip), %xmm1 # 0x90130
divsd %xmm1, %xmm0
imulq $0x64, -0x2d0(%rbp), %rax
movq %rax, -0x2e8(%rbp)
movq -0x2c8(%rbp), %rax
movl $0x2710, %ecx # imm = 0x2710
cqto
idivq %rcx
movq %rax, %rcx
movq -0x2e8(%rbp), %rax
addq %rcx, %rax
cvtsi2sd %rax, %xmm1
movsd 0x5e833(%rip), %xmm2 # 0x90130
divsd %xmm2, %xmm1
movq -0x2c0(%rbp), %rdx
movq -0x2b0(%rbp), %rcx
movq -0x2a0(%rbp), %r8
movq -0x298(%rbp), %r9
movq -0x290(%rbp), %r13
movq -0x288(%rbp), %r12
movq -0x280(%rbp), %r15
movq -0x278(%rbp), %r14
movq -0x270(%rbp), %rbx
movq -0x268(%rbp), %r11
movq -0x260(%rbp), %r10
movq -0x258(%rbp), %rax
leaq 0x59973(%rip), %rsi # 0x8b2cf
movq %r13, (%rsp)
movq %r12, 0x8(%rsp)
movq %r15, 0x10(%rsp)
movq %r14, 0x18(%rsp)
movq %rbx, 0x20(%rsp)
movq %r11, 0x28(%rsp)
movq %r10, 0x30(%rsp)
movq %rax, 0x38(%rsp)
movb $0x2, %al
callq 0x25470
jmp 0x3198c
callq 0x34310
callq 0x34080
movl -0x234(%rbp), %eax
andl $0x4, %eax
cmpl $0x0, %eax
jne 0x319aa
jmp 0x319a6
jmp 0x319a8
jmp 0x319aa
callq 0x34b10
leaq 0x37505e(%rip), %rax # 0x3a6a14
movl (%rax), %edi
callq 0x253a0
leaq 0x374d88(%rip), %rax # 0x3a674c
movb $0x0, (%rax)
leaq 0x37434a(%rip), %rax # 0x3a5d18
movb $0x0, (%rax)
movq %fs:0x28, %rax
movq -0x30(%rbp), %rcx
cmpq %rcx, %rax
jne 0x319f5
addq $0x308, %rsp # imm = 0x308
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x25340
nopw (%rax,%rax)
|
my_end:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 308h
mov rax, fs:28h
mov [rbp+var_30], rax
mov [rbp+var_234], edi
mov rax, cs:stderr_ptr
mov rax, [rax]
mov [rbp+var_240], rax
mov rax, [rbp+var_240]
mov rcx, cs:stderr_ptr
cmp rax, [rcx]
setnz al
and al, 1
movzx eax, al
mov [rbp+var_241], al
lea rax, my_init_done
cmp byte ptr [rax], 0
jnz short loc_316D8
jmp loc_319D1
loc_316D8:
jmp short $+2
loc_316DA:
jmp short $+2
loc_316DC:
cmp [rbp+var_240], 0
jnz short loc_316FE
mov rax, cs:stderr_ptr
mov rax, [rax]
mov [rbp+var_240], rax
mov [rbp+var_241], 0
loc_316FE:
mov eax, [rbp+var_234]
and eax, 1
cmp eax, 0
jnz short loc_3171C
movsx eax, [rbp+var_241]
cmp eax, 0
jz loc_3183A
loc_3171C:
mov [rbp+var_248], 0
mov [rbp+var_24C], 0
mov [rbp+var_250], 0
loc_3173A:
mov eax, [rbp+var_248]
lea rcx, my_file_limit
cmp eax, [rcx]
jnb loc_317DE
lea rax, my_file_info
mov rax, [rax]
mov ecx, [rbp+var_248]
shl rcx, 4
add rax, rcx
cmp dword ptr [rax+8], 0
jnz short loc_3176E
jmp short loc_317CA
loc_3176E:
lea rax, my_file_info
mov rax, [rax]
mov ecx, [rbp+var_248]
shl rcx, 4
add rax, rcx
cmp dword ptr [rax+8], 3
jz short loc_317A8
lea rax, my_file_info
mov rax, [rax]
mov ecx, [rbp+var_248]
shl rcx, 4
add rax, rcx
cmp dword ptr [rax+8], 4
jnz short loc_317B9
loc_317A8:
mov eax, [rbp+var_250]
add eax, 1
mov [rbp+var_250], eax
jmp short loc_317C8
loc_317B9:
mov eax, [rbp+var_24C]
add eax, 1
mov [rbp+var_24C], eax
loc_317C8:
jmp short $+2
loc_317CA:
mov eax, [rbp+var_248]
add eax, 1
mov [rbp+var_248], eax
jmp loc_3173A
loc_317DE:
cmp [rbp+var_24C], 0
jnz short loc_317F0
cmp [rbp+var_250], 0
jz short loc_31838
loc_317F0:
lea rdi, [rbp+var_230]
lea rax, globerrs
mov rdx, [rax+90h]
mov ecx, [rbp+var_24C]
mov r8d, [rbp+var_250]
mov esi, 200h
mov al, 0
call my_snprintf
lea rsi, [rbp+var_230]
mov edi, 13h
mov edx, 4
call my_message_stderr
jmp short $+2
loc_31836:
jmp short $+2
loc_31838:
jmp short $+2
loc_3183A:
call free_charsets
call my_error_unregister_all
call my_once_free
mov eax, [rbp+var_234]
and eax, 2
cmp eax, 0
jnz short loc_31867
movsx eax, [rbp+var_241]
cmp eax, 0
jz loc_3198C
loc_31867:
xor edi, edi
lea rsi, [rbp+var_2E0]
call _getrusage
cmp eax, 0
jnz loc_3198A
mov rdi, [rbp+var_240]
imul rax, [rbp+var_2E0], 64h ; 'd'
mov [rbp+var_2F0], rax
mov rax, [rbp+var_2D8]
mov ecx, 2710h
cqo
idiv rcx
mov rcx, rax
mov rax, [rbp+var_2F0]
add rax, rcx
cvtsi2sd xmm0, rax
movsd xmm1, cs:qword_90130
divsd xmm0, xmm1
imul rax, [rbp+var_2D0], 64h ; 'd'
mov [rbp+var_2E8], rax
mov rax, [rbp+var_2C8]
mov ecx, 2710h
cqo
idiv rcx
mov rcx, rax
mov rax, [rbp+var_2E8]
add rax, rcx
cvtsi2sd xmm1, rax
movsd xmm2, cs:qword_90130
divsd xmm1, xmm2
mov rdx, [rbp+var_2C0]
mov rcx, [rbp+var_2B0]
mov r8, [rbp+var_2A0]
mov r9, [rbp+var_298]
mov r13, [rbp+var_290]
mov r12, [rbp+var_288]
mov r15, [rbp+var_280]
mov r14, [rbp+var_278]
mov rbx, [rbp+var_270]
mov r11, [rbp+var_268]
mov r10, [rbp+var_260]
mov rax, [rbp+var_258]
lea rsi, aUserTime2fSyst; "\nUser time %.2f, System time %.2f\nMax"...
mov [rsp+330h+var_330], r13
mov [rsp+330h+var_328], r12
mov [rsp+330h+var_320], r15
mov [rsp+330h+var_318], r14
mov [rsp+330h+var_310], rbx
mov [rsp+330h+var_308], r11
mov [rsp+330h+var_300], r10
mov [rsp+330h+var_2F8], rax
mov al, 2
call _fprintf
loc_3198A:
jmp short $+2
loc_3198C:
call my_thread_end
call my_thread_global_end
mov eax, [rbp+var_234]
and eax, 4
cmp eax, 0
jnz short loc_319AA
jmp short $+2
loc_319A6:
jmp short $+2
loc_319A8:
jmp short $+2
loc_319AA:
call my_mutex_end
lea rax, THR_KEY_mysys
mov edi, [rax]
call _pthread_key_delete
lea rax, my_thr_key_mysys_exists
mov byte ptr [rax], 0
lea rax, my_init_done
mov byte ptr [rax], 0
loc_319D1:
mov rax, fs:28h
mov rcx, [rbp+var_30]
cmp rax, rcx
jnz short loc_319F5
add rsp, 308h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_319F5:
call ___stack_chk_fail
|
unsigned long long my_end(int a1, long long a2, long long a3, long long a4, long long a5, int a6)
{
_QWORD v7[2]; // [rsp+50h] [rbp-2E0h] BYREF
long long v8; // [rsp+60h] [rbp-2D0h]
long long v9; // [rsp+68h] [rbp-2C8h]
long long v10; // [rsp+70h] [rbp-2C0h]
long long v11; // [rsp+80h] [rbp-2B0h]
long long v12; // [rsp+90h] [rbp-2A0h]
long long v13; // [rsp+98h] [rbp-298h]
long long v14; // [rsp+A0h] [rbp-290h]
long long v15; // [rsp+A8h] [rbp-288h]
long long v16; // [rsp+B0h] [rbp-280h]
long long v17; // [rsp+B8h] [rbp-278h]
long long v18; // [rsp+C0h] [rbp-270h]
long long v19; // [rsp+C8h] [rbp-268h]
long long v20; // [rsp+D0h] [rbp-260h]
long long v21; // [rsp+D8h] [rbp-258h]
int v22; // [rsp+E0h] [rbp-250h]
int v23; // [rsp+E4h] [rbp-24Ch]
unsigned int v24; // [rsp+E8h] [rbp-248h]
char v25; // [rsp+EFh] [rbp-241h]
long long v26; // [rsp+F0h] [rbp-240h]
int v27; // [rsp+FCh] [rbp-234h]
_BYTE v28[512]; // [rsp+100h] [rbp-230h] BYREF
unsigned long long v29; // [rsp+300h] [rbp-30h]
v29 = __readfsqword(0x28u);
v27 = a1;
v26 = stderr;
v25 = 0;
if ( my_init_done )
{
if ( !v26 )
{
v26 = stderr;
v25 = 0;
}
if ( (v27 & 1) != 0 )
{
v24 = 0;
v23 = 0;
v22 = 0;
while ( v24 < my_file_limit )
{
if ( *((_DWORD *)my_file_info + 4 * v24 + 2) )
{
if ( *((_DWORD *)my_file_info + 4 * v24 + 2) == 3 || *((_DWORD *)my_file_info + 4 * v24 + 2) == 4 )
++v22;
else
++v23;
}
++v24;
}
if ( v23 || v22 )
{
my_snprintf((unsigned int)v28, 512, (unsigned int)globerrs[18], v23, v22, a6);
my_message_stderr(19LL, v28, 4LL);
}
}
free_charsets();
my_error_unregister_all();
my_once_free();
if ( (v27 & 2) != 0 && !(unsigned int)getrusage(0LL, v7) )
fprintf(
v26,
"\n"
"User time %.2f, System time %.2f\n"
"Maximum resident set size %ld, Integral resident set size %ld\n"
"Non-physical pagefaults %ld, Physical pagefaults %ld, Swaps %ld\n"
"Blocks in %ld out %ld, Messages in %ld out %ld, Signals %ld\n"
"Voluntary context switches %ld, Involuntary context switches %ld\n",
(double)(int)(v7[1] / 10000LL + 100 * LODWORD(v7[0])) / 100.0,
(double)(int)(v9 / 10000 + 100 * v8) / 100.0,
v10,
v11,
v12,
v13,
v14,
v15,
v16,
v17,
v18,
v19,
v20,
v21);
my_thread_end();
my_thread_global_end();
my_mutex_end();
pthread_key_delete(THR_KEY_mysys);
my_thr_key_mysys_exists = 0;
my_init_done = 0;
}
return __readfsqword(0x28u);
}
|
my_end:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x308
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
MOV dword ptr [RBP + -0x234],EDI
MOV RAX,qword ptr [0x002e2fe0]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x240],RAX
MOV RAX,qword ptr [RBP + -0x240]
MOV RCX,qword ptr [0x002e2fe0]
CMP RAX,qword ptr [RCX]
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x241],AL
LEA RAX,[0x4a5d18]
CMP byte ptr [RAX],0x0
JNZ 0x001316d8
JMP 0x001319d1
LAB_001316d8:
JMP 0x001316da
LAB_001316da:
JMP 0x001316dc
LAB_001316dc:
CMP qword ptr [RBP + -0x240],0x0
JNZ 0x001316fe
MOV RAX,qword ptr [0x002e2fe0]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x240],RAX
MOV byte ptr [RBP + -0x241],0x0
LAB_001316fe:
MOV EAX,dword ptr [RBP + -0x234]
AND EAX,0x1
CMP EAX,0x0
JNZ 0x0013171c
MOVSX EAX,byte ptr [RBP + -0x241]
CMP EAX,0x0
JZ 0x0013183a
LAB_0013171c:
MOV dword ptr [RBP + -0x248],0x0
MOV dword ptr [RBP + -0x24c],0x0
MOV dword ptr [RBP + -0x250],0x0
LAB_0013173a:
MOV EAX,dword ptr [RBP + -0x248]
LEA RCX,[0x2e3980]
CMP EAX,dword ptr [RCX]
JNC 0x001317de
LEA RAX,[0x2e3988]
MOV RAX,qword ptr [RAX]
MOV ECX,dword ptr [RBP + -0x248]
SHL RCX,0x4
ADD RAX,RCX
CMP dword ptr [RAX + 0x8],0x0
JNZ 0x0013176e
JMP 0x001317ca
LAB_0013176e:
LEA RAX,[0x2e3988]
MOV RAX,qword ptr [RAX]
MOV ECX,dword ptr [RBP + -0x248]
SHL RCX,0x4
ADD RAX,RCX
CMP dword ptr [RAX + 0x8],0x3
JZ 0x001317a8
LEA RAX,[0x2e3988]
MOV RAX,qword ptr [RAX]
MOV ECX,dword ptr [RBP + -0x248]
SHL RCX,0x4
ADD RAX,RCX
CMP dword ptr [RAX + 0x8],0x4
JNZ 0x001317b9
LAB_001317a8:
MOV EAX,dword ptr [RBP + -0x250]
ADD EAX,0x1
MOV dword ptr [RBP + -0x250],EAX
JMP 0x001317c8
LAB_001317b9:
MOV EAX,dword ptr [RBP + -0x24c]
ADD EAX,0x1
MOV dword ptr [RBP + -0x24c],EAX
LAB_001317c8:
JMP 0x001317ca
LAB_001317ca:
MOV EAX,dword ptr [RBP + -0x248]
ADD EAX,0x1
MOV dword ptr [RBP + -0x248],EAX
JMP 0x0013173a
LAB_001317de:
CMP dword ptr [RBP + -0x24c],0x0
JNZ 0x001317f0
CMP dword ptr [RBP + -0x250],0x0
JZ 0x00131838
LAB_001317f0:
LEA RDI,[RBP + -0x230]
LEA RAX,[0x2e3ec0]
MOV RDX,qword ptr [RAX + 0x90]
MOV ECX,dword ptr [RBP + -0x24c]
MOV R8D,dword ptr [RBP + -0x250]
MOV ESI,0x200
MOV AL,0x0
CALL 0x00186db0
LEA RSI,[RBP + -0x230]
MOV EDI,0x13
MOV EDX,0x4
CALL 0x001327d0
JMP 0x00131836
LAB_00131836:
JMP 0x00131838
LAB_00131838:
JMP 0x0013183a
LAB_0013183a:
CALL 0x00128db0
CALL 0x0012cf50
CALL 0x00132be0
MOV EAX,dword ptr [RBP + -0x234]
AND EAX,0x2
CMP EAX,0x0
JNZ 0x00131867
MOVSX EAX,byte ptr [RBP + -0x241]
CMP EAX,0x0
JZ 0x0013198c
LAB_00131867:
XOR EDI,EDI
LEA RSI,[RBP + -0x2e0]
CALL 0x001251c0
CMP EAX,0x0
JNZ 0x0013198a
MOV RDI,qword ptr [RBP + -0x240]
IMUL RAX,qword ptr [RBP + -0x2e0],0x64
MOV qword ptr [RBP + -0x2f0],RAX
MOV RAX,qword ptr [RBP + -0x2d8]
MOV ECX,0x2710
CQO
IDIV RCX
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x2f0]
ADD RAX,RCX
CVTSI2SD XMM0,RAX
MOVSD XMM1,qword ptr [0x00190130]
DIVSD XMM0,XMM1
IMUL RAX,qword ptr [RBP + -0x2d0],0x64
MOV qword ptr [RBP + -0x2e8],RAX
MOV RAX,qword ptr [RBP + -0x2c8]
MOV ECX,0x2710
CQO
IDIV RCX
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x2e8]
ADD RAX,RCX
CVTSI2SD XMM1,RAX
MOVSD XMM2,qword ptr [0x00190130]
DIVSD XMM1,XMM2
MOV RDX,qword ptr [RBP + -0x2c0]
MOV RCX,qword ptr [RBP + -0x2b0]
MOV R8,qword ptr [RBP + -0x2a0]
MOV R9,qword ptr [RBP + -0x298]
MOV R13,qword ptr [RBP + -0x290]
MOV R12,qword ptr [RBP + -0x288]
MOV R15,qword ptr [RBP + -0x280]
MOV R14,qword ptr [RBP + -0x278]
MOV RBX,qword ptr [RBP + -0x270]
MOV R11,qword ptr [RBP + -0x268]
MOV R10,qword ptr [RBP + -0x260]
MOV RAX,qword ptr [RBP + -0x258]
LEA RSI,[0x18b2cf]
MOV qword ptr [RSP],R13
MOV qword ptr [RSP + 0x8],R12
MOV qword ptr [RSP + 0x10],R15
MOV qword ptr [RSP + 0x18],R14
MOV qword ptr [RSP + 0x20],RBX
MOV qword ptr [RSP + 0x28],R11
MOV qword ptr [RSP + 0x30],R10
MOV qword ptr [RSP + 0x38],RAX
MOV AL,0x2
CALL 0x00125470
LAB_0013198a:
JMP 0x0013198c
LAB_0013198c:
CALL 0x00134310
CALL 0x00134080
MOV EAX,dword ptr [RBP + -0x234]
AND EAX,0x4
CMP EAX,0x0
JNZ 0x001319aa
JMP 0x001319a6
LAB_001319a6:
JMP 0x001319a8
LAB_001319a8:
JMP 0x001319aa
LAB_001319aa:
CALL 0x00134b10
LEA RAX,[0x4a6a14]
MOV EDI,dword ptr [RAX]
CALL 0x001253a0
LEA RAX,[0x4a674c]
MOV byte ptr [RAX],0x0
LEA RAX,[0x4a5d18]
MOV byte ptr [RAX],0x0
LAB_001319d1:
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x30]
CMP RAX,RCX
JNZ 0x001319f5
ADD RSP,0x308
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001319f5:
CALL 0x00125340
|
void my_end(uint param_1)
{
int iVar1;
long in_FS_OFFSET;
bool bVar2;
bool bVar3;
rusage local_2e8;
int local_258;
int local_254;
uint local_250;
bool local_249;
FILE *local_248;
uint local_23c;
int1 local_238 [512];
long local_38;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
local_248 = *(FILE **)PTR_stderr_002e2fe0;
bVar2 = local_248 != *(FILE **)PTR_stderr_002e2fe0;
local_249 = bVar2;
local_23c = param_1;
if (my_init_done != '\0') {
bVar3 = local_248 == (FILE *)0x0;
if (bVar3) {
local_248 = *(FILE **)PTR_stderr_002e2fe0;
}
bVar3 = !bVar3;
local_249 = bVar3 && bVar2;
if (((param_1 & 1) != 0) || (bVar3 && bVar2)) {
local_254 = 0;
local_258 = 0;
for (local_250 = 0; local_250 < my_file_limit; local_250 = local_250 + 1) {
if (*(int *)(my_file_info + (ulong)local_250 * 0x10 + 8) != 0) {
if ((*(int *)(my_file_info + (ulong)local_250 * 0x10 + 8) == 3) ||
(*(int *)(my_file_info + (ulong)local_250 * 0x10 + 8) == 4)) {
local_258 = local_258 + 1;
}
else {
local_254 = local_254 + 1;
}
}
}
if ((local_254 != 0) || (local_258 != 0)) {
my_snprintf(local_238,0x200,globerrs._144_8_,local_254,local_258);
my_message_stderr(0x13,local_238,4);
}
}
free_charsets();
my_error_unregister_all();
my_once_free();
if ((((local_23c & 2) != 0) || (local_249 != false)) &&
(iVar1 = getrusage(RUSAGE_SELF,&local_2e8), iVar1 == 0)) {
fprintf(local_248,
"\nUser time %.2f, System time %.2f\nMaximum resident set size %ld, Integral resident set size %ld\nNon-physical pagefaults %ld, Physical pagefaults %ld, Swaps %ld\nBlocks in %ld out %ld, Messages in %ld out %ld, Signals %ld\nVoluntary context switches %ld, Involuntary context switches %ld\n"
,(double)(local_2e8.ru_utime.tv_sec * 100 + local_2e8.ru_utime.tv_usec / 10000) /
DAT_00190130,
(double)(local_2e8.ru_stime.tv_sec * 100 + local_2e8.ru_stime.tv_usec / 10000) /
DAT_00190130,local_2e8.ru_maxrss,local_2e8.ru_idrss,local_2e8.ru_minflt,
local_2e8.ru_majflt,local_2e8.ru_nswap,local_2e8.ru_inblock,local_2e8.ru_oublock,
local_2e8.ru_msgsnd,local_2e8.ru_msgrcv,local_2e8.ru_nsignals,local_2e8.ru_nvcsw,
local_2e8.ru_nivcsw);
}
my_thread_end();
my_thread_global_end();
my_mutex_end();
pthread_key_delete(THR_KEY_mysys);
my_thr_key_mysys_exists = 0;
my_init_done = '\0';
}
if (*(long *)(in_FS_OFFSET + 0x28) == local_38) {
return;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
|
|
64,833 |
my_thread_global_reinit
|
eloqsql/mysys/my_thr_init.c
|
void my_thread_global_reinit(void)
{
struct st_my_thread_var *tmp;
DBUG_ASSERT(my_thread_global_init_done);
#ifdef HAVE_PSI_INTERFACE
my_init_mysys_psi_keys();
#endif
my_thread_destroy_common_mutex();
my_thread_init_common_mutex();
my_thread_destroy_internal_mutex();
my_thread_init_internal_mutex();
tmp= my_thread_var;
DBUG_ASSERT(tmp);
my_thread_destory_thr_mutex(tmp);
my_thread_init_thr_mutex(tmp);
}
|
O3
|
c
|
my_thread_global_reinit:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
callq 0xc3417
callq 0xc5824
callq 0xc5a5e
callq 0xc5987
callq 0xc5beb
leaq 0xb967f6(%rip), %rax # 0xc5c234
movl (%rax), %edi
callq 0x2ba10
movq %rax, %rbx
movq %rax, %rdi
callq 0xc5cad
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0xc5d17
|
my_thread_global_reinit:
push rbp
mov rbp, rsp
push rbx
push rax
call my_init_mysys_psi_keys
call my_thread_destroy_common_mutex
call my_thread_init_common_mutex
call my_thread_destroy_internal_mutex
call my_thread_init_internal_mutex
lea rax, THR_KEY_mysys
mov edi, [rax]
call _pthread_getspecific
mov rbx, rax
mov rdi, rax
call my_thread_destory_thr_mutex
mov rdi, rbx
add rsp, 8
pop rbx
pop rbp
jmp my_thread_init_thr_mutex
|
long long my_thread_global_reinit(long long a1)
{
long long v1; // rbx
my_init_mysys_psi_keys(a1);
my_thread_destroy_common_mutex();
my_thread_init_common_mutex();
my_thread_destroy_internal_mutex();
my_thread_init_internal_mutex();
v1 = pthread_getspecific(THR_KEY_mysys);
my_thread_destory_thr_mutex(v1);
return my_thread_init_thr_mutex(v1);
}
|
my_thread_global_reinit:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
CALL 0x001c3417
CALL 0x001c5824
CALL 0x001c5a5e
CALL 0x001c5987
CALL 0x001c5beb
LEA RAX,[0xd5c234]
MOV EDI,dword ptr [RAX]
CALL 0x0012ba10
MOV RBX,RAX
MOV RDI,RAX
CALL 0x001c5cad
MOV RDI,RBX
ADD RSP,0x8
POP RBX
POP RBP
JMP 0x001c5d17
|
void my_thread_global_reinit(void)
{
void *pvVar1;
my_init_mysys_psi_keys();
my_thread_destroy_common_mutex();
my_thread_init_common_mutex();
my_thread_destroy_internal_mutex();
my_thread_init_internal_mutex();
pvVar1 = pthread_getspecific(THR_KEY_mysys);
my_thread_destory_thr_mutex(pvVar1);
my_thread_init_thr_mutex(pvVar1);
return;
}
|
|
64,834 |
my_uni_ucs2
|
eloqsql/strings/ctype-ucs2.c
|
static int my_uni_ucs2(CHARSET_INFO *cs __attribute__((unused)) ,
my_wc_t wc, uchar *r, uchar *e)
{
if ( r+2 > e )
return MY_CS_TOOSMALL2;
if (wc > 0xFFFF) /* UCS2 does not support characters outside BMP */
return MY_CS_ILUNI;
r[0]= (uchar) (wc >> 8);
r[1]= (uchar) (wc & 0xFF);
return 2;
}
|
O0
|
c
|
my_uni_ucs2:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x20(%rbp), %rax
addq $0x2, %rax
cmpq -0x28(%rbp), %rax
jbe 0x61f5b
movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A
jmp 0x61f98
cmpq $0xffff, -0x18(%rbp) # imm = 0xFFFF
jbe 0x61f6e
movl $0x0, -0x4(%rbp)
jmp 0x61f98
movq -0x18(%rbp), %rax
shrq $0x8, %rax
movb %al, %cl
movq -0x20(%rbp), %rax
movb %cl, (%rax)
movq -0x18(%rbp), %rax
andq $0xff, %rax
movb %al, %cl
movq -0x20(%rbp), %rax
movb %cl, 0x1(%rax)
movl $0x2, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax)
|
my_uni_ucs2:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_20]
add rax, 2
cmp rax, [rbp+var_28]
jbe short loc_61F5B
mov [rbp+var_4], 0FFFFFF9Ah
jmp short loc_61F98
loc_61F5B:
cmp [rbp+var_18], 0FFFFh
jbe short loc_61F6E
mov [rbp+var_4], 0
jmp short loc_61F98
loc_61F6E:
mov rax, [rbp+var_18]
shr rax, 8
mov cl, al
mov rax, [rbp+var_20]
mov [rax], cl
mov rax, [rbp+var_18]
and rax, 0FFh
mov cl, al
mov rax, [rbp+var_20]
mov [rax+1], cl
mov [rbp+var_4], 2
loc_61F98:
mov eax, [rbp+var_4]
pop rbp
retn
|
long long my_uni_ucs2(long long a1, unsigned long long a2, _BYTE *a3, unsigned long long a4)
{
if ( (unsigned long long)(a3 + 2) <= a4 )
{
if ( a2 <= 0xFFFF )
{
*a3 = BYTE1(a2);
a3[1] = a2;
return 2;
}
else
{
return 0;
}
}
else
{
return (unsigned int)-102;
}
}
|
my_uni_ucs2:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x00161f5b
MOV dword ptr [RBP + -0x4],0xffffff9a
JMP 0x00161f98
LAB_00161f5b:
CMP qword ptr [RBP + -0x18],0xffff
JBE 0x00161f6e
MOV dword ptr [RBP + -0x4],0x0
JMP 0x00161f98
LAB_00161f6e:
MOV RAX,qword ptr [RBP + -0x18]
SHR RAX,0x8
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,0xff
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV byte ptr [RAX + 0x1],CL
MOV dword ptr [RBP + -0x4],0x2
LAB_00161f98:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int4 my_uni_ucs2(int8 param_1,ulong param_2,int1 *param_3,int1 *param_4)
{
int4 local_c;
if (param_4 < param_3 + 2) {
local_c = 0xffffff9a;
}
else if (param_2 < 0x10000) {
*param_3 = (char)(param_2 >> 8);
param_3[1] = (char)param_2;
local_c = 2;
}
else {
local_c = 0;
}
return local_c;
}
|
|
64,835 |
google::protobuf::Reflection::ClearField(google::protobuf::Message*, google::protobuf::FieldDescriptor const*) const
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/generated_message_reflection.cc
|
void Reflection::ClearField(Message* message,
const FieldDescriptor* field) const {
USAGE_CHECK_MESSAGE_TYPE(ClearField);
CheckInvalidAccess(schema_, field);
if (field->is_extension()) {
MutableExtensionSet(message)->ClearExtension(field->number());
} else if (!field->is_repeated()) {
if (schema_.InRealOneof(field)) {
ClearOneofField(message, field);
return;
}
if (HasBit(*message, field)) {
ClearBit(message, field);
// We need to set the field back to its default value.
switch (field->cpp_type()) {
#define CLEAR_TYPE(CPPTYPE, TYPE) \
case FieldDescriptor::CPPTYPE_##CPPTYPE: \
*MutableRaw<TYPE>(message, field) = field->default_value_##TYPE(); \
break;
CLEAR_TYPE(INT32, int32_t);
CLEAR_TYPE(INT64, int64_t);
CLEAR_TYPE(UINT32, uint32_t);
CLEAR_TYPE(UINT64, uint64_t);
CLEAR_TYPE(FLOAT, float);
CLEAR_TYPE(DOUBLE, double);
CLEAR_TYPE(BOOL, bool);
#undef CLEAR_TYPE
case FieldDescriptor::CPPTYPE_ENUM:
*MutableRaw<int>(message, field) =
field->default_value_enum()->number();
break;
case FieldDescriptor::CPPTYPE_STRING: {
switch (field->options().ctype()) {
default: // TODO(kenton): Support other string reps.
case FieldOptions::STRING:
if (IsInlined(field)) {
// Currently, string with default value can't be inlined. So we
// don't have to handle default value here.
MutableRaw<InlinedStringField>(message, field)->ClearToEmpty();
} else {
auto* str = MutableRaw<ArenaStringPtr>(message, field);
str->Destroy();
str->InitDefault();
}
break;
}
break;
}
case FieldDescriptor::CPPTYPE_MESSAGE:
if (schema_.HasBitIndex(field) == static_cast<uint32_t>(-1)) {
// Proto3 does not have has-bits and we need to set a message field
// to nullptr in order to indicate its un-presence.
if (message->GetArenaForAllocation() == nullptr) {
delete *MutableRaw<Message*>(message, field);
}
*MutableRaw<Message*>(message, field) = nullptr;
} else {
(*MutableRaw<Message*>(message, field))->Clear();
}
break;
}
}
} else {
switch (field->cpp_type()) {
#define HANDLE_TYPE(UPPERCASE, LOWERCASE) \
case FieldDescriptor::CPPTYPE_##UPPERCASE: \
MutableRaw<RepeatedField<LOWERCASE> >(message, field)->Clear(); \
break
HANDLE_TYPE(INT32, int32_t);
HANDLE_TYPE(INT64, int64_t);
HANDLE_TYPE(UINT32, uint32_t);
HANDLE_TYPE(UINT64, uint64_t);
HANDLE_TYPE(DOUBLE, double);
HANDLE_TYPE(FLOAT, float);
HANDLE_TYPE(BOOL, bool);
HANDLE_TYPE(ENUM, int);
#undef HANDLE_TYPE
case FieldDescriptor::CPPTYPE_STRING: {
switch (field->options().ctype()) {
default: // TODO(kenton): Support other string reps.
case FieldOptions::STRING:
MutableRaw<RepeatedPtrField<std::string> >(message, field)->Clear();
break;
}
break;
}
case FieldDescriptor::CPPTYPE_MESSAGE: {
if (IsMapFieldInApi(field)) {
MutableRaw<MapFieldBase>(message, field)->Clear();
} else {
// We don't know which subclass of RepeatedPtrFieldBase the type is,
// so we use RepeatedPtrFieldBase directly.
MutableRaw<RepeatedPtrFieldBase>(message, field)
->Clear<GenericTypeHandler<Message> >();
}
break;
}
}
}
}
|
O3
|
cpp
|
google::protobuf::Reflection::ClearField(google::protobuf::Message*, google::protobuf::FieldDescriptor const*) const:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rdx, %r14
movq %rsi, %rbx
movq %rdi, %r12
movq (%rdi), %rdi
cmpq %rdi, 0x20(%rdx)
je 0x64b76
leaq 0x5525e(%rip), %rdx # 0xb9dc5
leaq 0x5515b(%rip), %rcx # 0xb9cc9
movq %r14, %rsi
callq 0x65a82
movb 0x1(%r14), %al
testb $0x8, %al
jne 0x64bf8
leaq 0x8(%r12), %r15
movl %eax, %ecx
notb %cl
testb $0x60, %cl
jne 0x64c18
movq 0x18(%r14), %rdi
testq %rdi, %rdi
je 0x64bb5
leaq -0x29f80(%rip), %rax # 0x3ac20
leaq 0x18(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdx
movq %r14, (%rdx)
callq 0x3fc96
movzbl 0x2(%r14), %eax
leaq 0x5105f(%rip), %rcx # 0xb5c20
movl (%rcx,%rax,4), %eax
decl %eax
cmpl $0x9, %eax
ja 0x64f22
leaq 0x54cd2(%rip), %rcx # 0xb98a8
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movl $0x0, (%rbx,%rax)
jmp 0x64f22
movl 0x28(%r12), %eax
addq %rax, %rbx
movl 0x4(%r14), %esi
movq %rbx, %rdi
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x940ca
testb $0x10, %al
sete %al
movq 0x28(%r14), %rdx
testq %rdx, %rdx
sete %cl
orb %al, %cl
je 0x64cc4
movq %r12, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x6ca12
testb %al, %al
je 0x64f22
movq %r15, %rdi
movq %r14, %rsi
callq 0x6de24
cmpl $-0x1, %eax
je 0x64c6c
movl $0xfffffffe, %edx # imm = 0xFFFFFFFE
movl %eax, %ecx
roll %cl, %edx
movl 0x20(%r12), %ecx
addq %rbx, %rcx
shrl $0x5, %eax
andl %edx, (%rcx,%rax,4)
movq 0x18(%r14), %rdi
testq %rdi, %rdi
je 0x64c91
leaq -0x2a05c(%rip), %rax # 0x3ac20
leaq 0x18(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdx
movq %r14, (%rdx)
callq 0x3fc96
movzbl 0x2(%r14), %eax
leaq 0x50f83(%rip), %rcx # 0xb5c20
movl (%rcx,%rax,4), %eax
decl %eax
cmpl $0x9, %eax
ja 0x64f22
leaq 0x54bce(%rip), %rcx # 0xb9880
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl 0x40(%r14), %ebp
jmp 0x64e3e
cmpl $0x1, 0x4(%rdx)
jne 0x64cd8
movq 0x20(%rdx), %rax
testb $0x2, 0x1(%rax)
jne 0x64c2f
movq 0x10(%rdx), %rax
movq %rdx, %rcx
subq 0x30(%rax), %rcx
shrq $0x3, %rcx
imull $0x33333334, %ecx, %eax # imm = 0x33333334
addl 0x2c(%r12), %eax
movl (%rbx,%rax), %eax
cmpl 0x4(%r14), %eax
jne 0x64f22
movq %r12, %rdi
movq %rbx, %rsi
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x693a6
movq %r14, %rdi
callq 0x6454a
movl %eax, %ebp
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
addq %rax, %rbx
testb %bpl, %bpl
je 0x64da7
movq (%rbx), %rax
movq %rbx, %rdi
callq *0x58(%rax)
jmp 0x64f22
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movslq 0x8(%rbx,%rax), %rcx
testq %rcx, %rcx
jle 0x64f22
movq 0x10(%rbx,%rax), %rdx
xorl %esi, %esi
movq 0x8(%rdx,%rsi,8), %rdi
incq %rsi
movq $0x0, 0x8(%rdi)
movq (%rdi), %rdi
movb $0x0, (%rdi)
cmpq %rsi, %rcx
jne 0x64d65
movl $0x0, 0x8(%rbx,%rax)
jmp 0x64f22
movq 0x40(%r14), %r12
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movq %r12, (%rbx,%rax)
jmp 0x64f22
movslq 0x8(%rbx), %r14
testq %r14, %r14
jle 0x64f22
movq 0x10(%rbx), %r15
xorl %r12d, %r12d
movq 0x8(%r15,%r12,8), %rdi
incq %r12
movq (%rdi), %rax
callq *0x20(%rax)
cmpq %r12, %r14
jne 0x64dbb
movl $0x0, 0x8(%rbx)
jmp 0x64f22
movsd 0x40(%r14), %xmm0
movsd %xmm0, 0x8(%rsp)
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movsd 0x8(%rsp), %xmm0
movsd %xmm0, (%rbx,%rax)
jmp 0x64f22
movq %r15, %rdi
movq %r14, %rsi
callq 0x6de24
cmpl $-0x1, %eax
je 0x64edc
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movq (%rbx,%rax), %rdi
movq (%rdi), %rax
callq *0x20(%rax)
jmp 0x64f22
movq %r14, %rdi
callq 0x1fb14
movl 0x4(%rax), %ebp
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movl %ebp, (%rbx,%rax)
jmp 0x64f22
movss 0x40(%r14), %xmm0
movss %xmm0, 0x8(%rsp)
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movss 0x8(%rsp), %xmm0
movss %xmm0, (%rbx,%rax)
jmp 0x64f22
movb 0x40(%r14), %bpl
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movb %bpl, (%rbx,%rax)
jmp 0x64f22
movq %r15, %rdi
movq %r14, %rsi
callq 0x6e994
movl %eax, %ebp
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
addq %rax, %rbx
testb %bpl, %bpl
je 0x64ec8
movq $0x0, 0x8(%rbx)
movq (%rbx), %rax
movb $0x0, (%rax)
jmp 0x64f22
movq %rbx, %rdi
callq 0x933e4
leaq 0x9e3a1(%rip), %rax # 0x103278
movq %rax, (%rbx)
jmp 0x64f22
movq 0x8(%rbx), %rcx
movq %rcx, %rax
andq $-0x4, %rax
testb $0x1, %cl
jne 0x64f2f
testq %rax, %rax
jne 0x64f0d
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movq (%rbx,%rax), %rdi
testq %rdi, %rdi
je 0x64f0d
movq (%rdi), %rax
callq *0x8(%rax)
movq %r15, %rdi
movq %r14, %rsi
callq 0x6ea6a
movl %eax, %eax
movq $0x0, (%rbx,%rax)
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq (%rax), %rax
jmp 0x64eec
|
_ZNK6google8protobuf10Reflection10ClearFieldEPNS0_7MessageEPKNS0_15FieldDescriptorE:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 20h
mov r14, rdx
mov rbx, rsi
mov r12, rdi
mov rdi, [rdi]; this
cmp [rdx+20h], rdi
jz short loc_64B76
lea rdx, aClearfield; "ClearField"
lea rcx, aFieldDoesNotMa; "Field does not match message type."
mov rsi, r14; google::protobuf::Descriptor *
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_64B76:
mov al, [r14+1]
test al, 8
jnz short loc_64BF8
lea r15, [r12+8]
mov ecx, eax
not cl
test cl, 60h
jnz loc_64C18
mov rdi, [r14+18h]
test rdi, rdi
jz short loc_64BB5
lea rax, _ZN6google8protobuf15FieldDescriptor12TypeOnceInitEPKS1_; google::protobuf::FieldDescriptor::TypeOnceInit(google::protobuf::FieldDescriptor const*)
lea rsi, [rsp+48h+var_30]; google::protobuf::FieldDescriptor *
mov [rsi], rax
lea rdx, [rsp+48h+var_38]
mov [rdx], r14
call _ZSt9call_onceIPFvPKN6google8protobuf15FieldDescriptorEEJS4_EEvRSt9once_flagOT_DpOT0_; std::call_once<void (*)(google::protobuf::FieldDescriptor const*),google::protobuf::FieldDescriptor const*>(std::once_flag &,void (*)(google::protobuf::FieldDescriptor const*) &&,google::protobuf::FieldDescriptor const* &&)
loc_64BB5:
movzx eax, byte ptr [r14+2]
lea rcx, _ZN6google8protobuf15FieldDescriptor17kTypeToCppTypeMapE; google::protobuf::FieldDescriptor::kTypeToCppTypeMap
mov eax, [rcx+rax*4]
dec eax; switch 10 cases
cmp eax, 9
ja def_64BDD; jumptable 0000000000064BDD default case
lea rcx, jpt_64BDD
movsxd rax, ds:(jpt_64BDD - 0B98A8h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_64BDF:
mov rdi, r15; jumptable 0000000000064BDD cases 1-8
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
mov dword ptr [rbx+rax], 0
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64BF8:
mov eax, [r12+28h]
add rbx, rax
mov esi, [r14+4]; int
mov rdi, rbx; this
add rsp, 20h
pop rbx
pop r12
pop r14
pop r15
pop rbp
jmp _ZN6google8protobuf8internal12ExtensionSet14ClearExtensionEi; google::protobuf::internal::ExtensionSet::ClearExtension(int)
loc_64C18:
test al, 10h
setz al
mov rdx, [r14+28h]; google::protobuf::OneofDescriptor *
test rdx, rdx
setz cl
or cl, al
jz loc_64CC4
loc_64C2F:
mov rdi, r12; this
mov rsi, rbx; google::protobuf::Message *
mov rdx, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf10Reflection6HasBitERKNS0_7MessageEPKNS0_15FieldDescriptorE; google::protobuf::Reflection::HasBit(google::protobuf::Message const&,google::protobuf::FieldDescriptor const*)
test al, al
jz def_64BDD; jumptable 0000000000064BDD default case
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema11HasBitIndexEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::HasBitIndex(google::protobuf::FieldDescriptor const*)
cmp eax, 0FFFFFFFFh
jz short loc_64C6C
mov edx, 0FFFFFFFEh
mov ecx, eax
rol edx, cl
mov ecx, [r12+20h]
add rcx, rbx
shr eax, 5
and [rcx+rax*4], edx
loc_64C6C:
mov rdi, [r14+18h]
test rdi, rdi
jz short loc_64C91
lea rax, _ZN6google8protobuf15FieldDescriptor12TypeOnceInitEPKS1_; google::protobuf::FieldDescriptor::TypeOnceInit(google::protobuf::FieldDescriptor const*)
lea rsi, [rsp+48h+var_30]
mov [rsi], rax
lea rdx, [rsp+48h+var_38]
mov [rdx], r14
call _ZSt9call_onceIPFvPKN6google8protobuf15FieldDescriptorEEJS4_EEvRSt9once_flagOT_DpOT0_; std::call_once<void (*)(google::protobuf::FieldDescriptor const*),google::protobuf::FieldDescriptor const*>(std::once_flag &,void (*)(google::protobuf::FieldDescriptor const*) &&,google::protobuf::FieldDescriptor const* &&)
loc_64C91:
movzx eax, byte ptr [r14+2]
lea rcx, _ZN6google8protobuf15FieldDescriptor17kTypeToCppTypeMapE; google::protobuf::FieldDescriptor::kTypeToCppTypeMap
mov eax, [rcx+rax*4]
dec eax; switch 10 cases
cmp eax, 9
ja def_64BDD; jumptable 0000000000064BDD default case
lea rcx, jpt_64CB9
movsxd rax, ds:(jpt_64CB9 - 0B9880h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_64CBB:
mov ebp, [r14+40h]; jumptable 0000000000064CB9 cases 1,3
jmp loc_64E3E
loc_64CC4:
cmp dword ptr [rdx+4], 1
jnz short loc_64CD8
mov rax, [rdx+20h]
test byte ptr [rax+1], 2
jnz loc_64C2F
loc_64CD8:
mov rax, [rdx+10h]
mov rcx, rdx
sub rcx, [rax+30h]
shr rcx, 3
imul eax, ecx, 33333334h
add eax, [r12+2Ch]
mov eax, [rbx+rax]
cmp eax, [r14+4]
jnz def_64BDD; jumptable 0000000000064BDD default case
mov rdi, r12; this
mov rsi, rbx; google::protobuf::Message *
add rsp, 20h
pop rbx
pop r12
pop r14
pop r15
pop rbp
jmp _ZNK6google8protobuf10Reflection10ClearOneofEPNS0_7MessageEPKNS0_15OneofDescriptorE; google::protobuf::Reflection::ClearOneof(google::protobuf::Message *,google::protobuf::OneofDescriptor const*)
loc_64D16:
mov rdi, r14; jumptable 0000000000064BDD case 10
call _ZN6google8protobuf12_GLOBAL__N_115IsMapFieldInApiEPKNS0_15FieldDescriptorE_0; google::protobuf::`anonymous namespace'::IsMapFieldInApi(google::protobuf::FieldDescriptor const*)
mov ebp, eax
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
add rbx, rax
test bpl, bpl
jz short loc_64DA7
mov rax, [rbx]
mov rdi, rbx
call qword ptr [rax+58h]
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64D43:
mov rdi, r15; jumptable 0000000000064BDD case 9
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
movsxd rcx, dword ptr [rbx+rax+8]
test rcx, rcx
jle def_64BDD; jumptable 0000000000064BDD default case
mov rdx, [rbx+rax+10h]
xor esi, esi
loc_64D65:
mov rdi, [rdx+rsi*8+8]
inc rsi
mov qword ptr [rdi+8], 0
mov rdi, [rdi]
mov byte ptr [rdi], 0
cmp rcx, rsi
jnz short loc_64D65
mov dword ptr [rbx+rax+8], 0
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64D8D:
mov r12, [r14+40h]; jumptable 0000000000064CB9 cases 2,4
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
mov [rbx+rax], r12
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64DA7:
movsxd r14, dword ptr [rbx+8]
test r14, r14
jle def_64BDD; jumptable 0000000000064BDD default case
mov r15, [rbx+10h]
xor r12d, r12d
loc_64DBB:
mov rdi, [r15+r12*8+8]
inc r12
mov rax, [rdi]
call qword ptr [rax+20h]
cmp r14, r12
jnz short loc_64DBB
mov dword ptr [rbx+8], 0
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64DDA:
movsd xmm0, qword ptr [r14+40h]; jumptable 0000000000064CB9 case 5
movsd [rsp+48h+var_40], xmm0
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
movsd xmm0, [rsp+48h+var_40]
movsd qword ptr [rbx+rax], xmm0
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64E03:
mov rdi, r15; jumptable 0000000000064CB9 case 10
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema11HasBitIndexEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::HasBitIndex(google::protobuf::FieldDescriptor const*)
cmp eax, 0FFFFFFFFh
jz loc_64EDC
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
mov rdi, [rbx+rax]
mov rax, [rdi]
call qword ptr [rax+20h]
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64E33:
mov rdi, r14; jumptable 0000000000064CB9 case 8
call _ZNK6google8protobuf15FieldDescriptor18default_value_enumEv; google::protobuf::FieldDescriptor::default_value_enum(void)
mov ebp, [rax+4]
loc_64E3E:
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
mov [rbx+rax], ebp
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64E53:
movss xmm0, dword ptr [r14+40h]; jumptable 0000000000064CB9 case 6
movss dword ptr [rsp+48h+var_40], xmm0
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
movss xmm0, dword ptr [rsp+48h+var_40]
movss dword ptr [rbx+rax], xmm0
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64E7C:
mov bpl, [r14+40h]; jumptable 0000000000064CB9 case 7
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
mov [rbx+rax], bpl
jmp def_64BDD; jumptable 0000000000064BDD default case
loc_64E96:
mov rdi, r15; jumptable 0000000000064CB9 case 9
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14IsFieldInlinedEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::IsFieldInlined(google::protobuf::FieldDescriptor const*)
mov ebp, eax
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
add rbx, rax
test bpl, bpl
jz short loc_64EC8
mov qword ptr [rbx+8], 0
mov rax, [rbx]
mov byte ptr [rax], 0
jmp short def_64BDD; jumptable 0000000000064BDD default case
loc_64EC8:
mov rdi, rbx; this
call _ZN6google8protobuf8internal14ArenaStringPtr7DestroyEv; google::protobuf::internal::ArenaStringPtr::Destroy(void)
lea rax, _ZN6google8protobuf8internal26fixed_address_empty_stringB5cxx11E; google::protobuf::internal::fixed_address_empty_string
mov [rbx], rax
jmp short def_64BDD; jumptable 0000000000064BDD default case
loc_64EDC:
mov rcx, [rbx+8]
mov rax, rcx
and rax, 0FFFFFFFFFFFFFFFCh
test cl, 1
jnz short loc_64F2F
loc_64EEC:
test rax, rax
jnz short loc_64F0D
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
mov rdi, [rbx+rax]
test rdi, rdi
jz short loc_64F0D
mov rax, [rdi]
call qword ptr [rax+8]
loc_64F0D:
mov rdi, r15; this
mov rsi, r14; google::protobuf::FieldDescriptor *
call _ZNK6google8protobuf8internal16ReflectionSchema14GetFieldOffsetEPKNS0_15FieldDescriptorE; google::protobuf::internal::ReflectionSchema::GetFieldOffset(google::protobuf::FieldDescriptor const*)
mov eax, eax
mov qword ptr [rbx+rax], 0
def_64BDD:
add rsp, 20h; jumptable 0000000000064BDD default case
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_64F2F:
mov rax, [rax]
jmp short loc_64EEC
|
long long google::protobuf::Reflection::ClearField(
google::protobuf::_anonymous_namespace_ **this,
google::protobuf::Message *a2,
const google::protobuf::FieldDescriptor *a3,
long long a4,
const char *a5,
long long a6)
{
long long v6; // rax
google::protobuf::Message *v8; // rbx
google::protobuf::_anonymous_namespace_ *v10; // rdi
google::protobuf::internal::ReflectionSchema *v11; // r15
long long v12; // rcx
long long v13; // rdi
long long result; // rax
long long v15; // rdx
unsigned int HasBitIndex; // eax
long long v17; // rcx
long long v18; // r8
long long v19; // r9
long long v20; // rdi
int v21; // ebp
char IsMapFieldInApi; // bp
char *v23; // rbx
long long v24; // rcx
long long v25; // rdx
long long i; // rsi
long long v27; // rdi
long long v28; // r12
long long v29; // r14
long long v30; // r15
long long j; // r12
long long v32; // rdi
unsigned int FieldOffset; // eax
char v34; // bp
char IsFieldInlined; // bp
google::protobuf::internal::ArenaStringPtr *v36; // rbx
_QWORD *v37; // rax
long long v38; // rdi
long long v39; // [rsp+8h] [rbp-40h]
int v40; // [rsp+8h] [rbp-40h]
const google::protobuf::FieldDescriptor *v41; // [rsp+10h] [rbp-38h] BYREF
_QWORD v42[6]; // [rsp+18h] [rbp-30h] BYREF
v8 = a2;
v10 = *this;
if ( *((google::protobuf::_anonymous_namespace_ **)a3 + 4) != v10 )
{
a2 = a3;
v6 = google::protobuf::`anonymous namespace'::ReportReflectionUsageError(
v10,
a3,
(const google::protobuf::FieldDescriptor *)"ClearField",
"Field does not match message type.",
a5);
}
LOBYTE(v6) = *((_BYTE *)a3 + 1);
if ( (v6 & 8) != 0 )
return google::protobuf::internal::ExtensionSet::ClearExtension(
(google::protobuf::Message *)((char *)v8 + *((unsigned int *)this + 10)),
*((_DWORD *)a3 + 1));
v11 = (google::protobuf::internal::ReflectionSchema *)(this + 1);
v12 = (unsigned int)v6;
if ( (~(_BYTE)v6 & 0x60) != 0 )
{
v15 = *((_QWORD *)a3 + 5);
if ( (v6 & 0x10) == 0 || v15 == 0 || *(_DWORD *)(v15 + 4) == 1 && (*(_BYTE *)(*(_QWORD *)(v15 + 32) + 1LL) & 2) != 0 )
{
result = google::protobuf::Reflection::HasBit((google::protobuf::Reflection *)this, v8, a3);
if ( (_BYTE)result )
{
HasBitIndex = google::protobuf::internal::ReflectionSchema::HasBitIndex(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
if ( HasBitIndex != -1 )
{
v17 = (long long)v8 + *((unsigned int *)this + 8);
*(_DWORD *)(v17 + 4LL * (HasBitIndex >> 5)) &= __ROL4__(-2, HasBitIndex);
}
v20 = *((_QWORD *)a3 + 3);
if ( v20 )
{
v42[0] = google::protobuf::FieldDescriptor::TypeOnceInit;
v41 = a3;
std::call_once<void (*)(google::protobuf::FieldDescriptor const*),google::protobuf::FieldDescriptor const*>(
v20,
(long long)v42,
(long long)&v41,
v17,
v18,
v19);
}
result = (unsigned int)(google::protobuf::FieldDescriptor::kTypeToCppTypeMap[*((unsigned __int8 *)a3 + 2)] - 1);
switch ( *((_BYTE *)a3 + 2) )
{
case 1:
v39 = *((_QWORD *)a3 + 8);
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
*(_QWORD *)((char *)v8 + (unsigned int)result) = v39;
break;
case 2:
v40 = *((_DWORD *)a3 + 16);
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
*(_DWORD *)((char *)v8 + (unsigned int)result) = v40;
break;
case 3:
case 4:
case 6:
case 0x10:
case 0x12:
v28 = *((_QWORD *)a3 + 8);
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(v11, a3);
*(_QWORD *)((char *)v8 + (unsigned int)result) = v28;
break;
case 5:
case 7:
case 0xD:
case 0xF:
case 0x11:
v21 = *((_DWORD *)a3 + 16);
goto LABEL_37;
case 8:
v34 = *((_BYTE *)a3 + 64);
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
*((_BYTE *)v8 + (unsigned int)result) = v34;
break;
case 9:
case 0xC:
IsFieldInlined = google::protobuf::internal::ReflectionSchema::IsFieldInlined(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
v36 = (google::protobuf::Message *)((char *)v8
+ (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3));
if ( IsFieldInlined )
{
*((_QWORD *)v36 + 1) = 0LL;
result = *(_QWORD *)v36;
**(_BYTE **)v36 = 0;
}
else
{
google::protobuf::internal::ArenaStringPtr::Destroy(v36);
result = (long long)google::protobuf::internal::fixed_address_empty_string[abi:cxx11];
*(_QWORD *)v36 = google::protobuf::internal::fixed_address_empty_string[abi:cxx11];
}
break;
case 0xA:
case 0xB:
if ( (unsigned int)google::protobuf::internal::ReflectionSchema::HasBitIndex(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3) == -1 )
{
v37 = (_QWORD *)(*((_QWORD *)v8 + 1) & 0xFFFFFFFFFFFFFFFCLL);
if ( (*((_QWORD *)v8 + 1) & 1) != 0 )
v37 = (_QWORD *)*v37;
if ( !v37 )
{
v38 = *(_QWORD *)((char *)v8
+ (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3));
if ( v38 )
(*(void ( **)(long long))(*(_QWORD *)v38 + 8LL))(v38);
}
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
*(_QWORD *)((char *)v8 + (unsigned int)result) = 0LL;
}
else
{
FieldOffset = google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
result = (*(long long ( **)(_QWORD))(**(_QWORD **)((char *)v8 + FieldOffset) + 32LL))(*(_QWORD *)((char *)v8 + FieldOffset));
}
break;
case 0xE:
v21 = *(_DWORD *)(google::protobuf::FieldDescriptor::default_value_enum(a3) + 4);
LABEL_37:
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
*(_DWORD *)((char *)v8 + (unsigned int)result) = v21;
break;
default:
return result;
}
}
}
else
{
result = *(unsigned int *)((char *)v8
+ 858993460
* (unsigned int)((unsigned long long)(v15 - *(_QWORD *)(*(_QWORD *)(v15 + 16) + 48LL)) >> 3)
+ *((_DWORD *)this + 11));
if ( (_DWORD)result == *((_DWORD *)a3 + 1) )
return google::protobuf::Reflection::ClearOneof(
(google::protobuf::Reflection *)this,
v8,
(const google::protobuf::OneofDescriptor *)v15);
}
}
else
{
v13 = *((_QWORD *)a3 + 3);
if ( v13 )
{
a2 = (google::protobuf::Message *)v42;
v42[0] = google::protobuf::FieldDescriptor::TypeOnceInit;
v41 = a3;
LOBYTE(v12) = ~(_BYTE)v6;
std::call_once<void (*)(google::protobuf::FieldDescriptor const*),google::protobuf::FieldDescriptor const*>(
v13,
(long long)v42,
(long long)&v41,
v12,
(long long)a5,
a6);
}
result = (unsigned int)(google::protobuf::FieldDescriptor::kTypeToCppTypeMap[*((unsigned __int8 *)a3 + 2)] - 1);
switch ( *((_BYTE *)a3 + 2) )
{
case 1:
case 2:
case 3:
case 4:
case 5:
case 6:
case 7:
case 8:
case 0xD:
case 0xE:
case 0xF:
case 0x10:
case 0x11:
case 0x12:
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
*(_DWORD *)((char *)v8 + (unsigned int)result) = 0;
break;
case 9:
case 0xC:
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
v24 = *(int *)((char *)v8 + (unsigned int)result + 8);
if ( v24 > 0 )
{
v25 = *(_QWORD *)((char *)v8 + (unsigned int)result + 16);
for ( i = 0LL; i != v24; ++i )
{
v27 = *(_QWORD *)(v25 + 8 * i + 8);
*(_QWORD *)(v27 + 8) = 0LL;
**(_BYTE **)v27 = 0;
}
*(_DWORD *)((char *)v8 + (unsigned int)result + 8) = 0;
}
break;
case 0xA:
case 0xB:
IsMapFieldInApi = google::protobuf::`anonymous namespace'::IsMapFieldInApi(
a3,
a2,
(long long)a3,
(long long)google::protobuf::FieldDescriptor::kTypeToCppTypeMap,
(long long)a5,
a6);
result = (unsigned int)google::protobuf::internal::ReflectionSchema::GetFieldOffset(
(google::protobuf::internal::ReflectionSchema *)(this + 1),
a3);
v23 = (char *)v8 + (unsigned int)result;
if ( IsMapFieldInApi )
{
result = (*(long long ( **)(char *))(*(_QWORD *)v23 + 88LL))(v23);
}
else
{
v29 = *((int *)v23 + 2);
if ( v29 > 0 )
{
v30 = *((_QWORD *)v23 + 2);
for ( j = 0LL; j != v29; ++j )
{
v32 = *(_QWORD *)(v30 + 8 * j + 8);
result = (*(long long ( **)(long long))(*(_QWORD *)v32 + 32LL))(v32);
}
*((_DWORD *)v23 + 2) = 0;
}
}
break;
default:
return result;
}
}
return result;
}
|
ClearField:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x20
MOV R14,RDX
MOV RBX,RSI
MOV R12,RDI
MOV RDI,qword ptr [RDI]
CMP qword ptr [RDX + 0x20],RDI
JZ 0x00164b76
LEA RDX,[0x1b9dc5]
LEA RCX,[0x1b9cc9]
MOV RSI,R14
CALL 0x00165a82
LAB_00164b76:
MOV AL,byte ptr [R14 + 0x1]
TEST AL,0x8
JNZ 0x00164bf8
LEA R15,[R12 + 0x8]
MOV ECX,EAX
NOT CL
TEST CL,0x60
JNZ 0x00164c18
MOV RDI,qword ptr [R14 + 0x18]
TEST RDI,RDI
JZ 0x00164bb5
LEA RAX,[0x13ac20]
LEA RSI,[RSP + 0x18]
MOV qword ptr [RSI],RAX
LEA RDX,[RSP + 0x10]
MOV qword ptr [RDX],R14
CALL 0x0013fc96
LAB_00164bb5:
MOVZX EAX,byte ptr [R14 + 0x2]
LEA RCX,[0x1b5c20]
MOV EAX,dword ptr [RCX + RAX*0x4]
DEC EAX
CMP EAX,0x9
JA 0x00164f22
LEA RCX,[0x1b98a8]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_1:
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOV dword ptr [RBX + RAX*0x1],0x0
JMP 0x00164f22
LAB_00164bf8:
MOV EAX,dword ptr [R12 + 0x28]
ADD RBX,RAX
MOV ESI,dword ptr [R14 + 0x4]
MOV RDI,RBX
ADD RSP,0x20
POP RBX
POP R12
POP R14
POP R15
POP RBP
JMP 0x001940ca
LAB_00164c18:
TEST AL,0x10
SETZ AL
MOV RDX,qword ptr [R14 + 0x28]
TEST RDX,RDX
SETZ CL
OR CL,AL
JZ 0x00164cc4
LAB_00164c2f:
MOV RDI,R12
MOV RSI,RBX
MOV RDX,R14
CALL 0x0016ca12
TEST AL,AL
JZ 0x00164f22
MOV RDI,R15
MOV RSI,R14
CALL 0x0016de24
CMP EAX,-0x1
JZ 0x00164c6c
MOV EDX,0xfffffffe
MOV ECX,EAX
ROL EDX,CL
MOV ECX,dword ptr [R12 + 0x20]
ADD RCX,RBX
SHR EAX,0x5
AND dword ptr [RCX + RAX*0x4],EDX
LAB_00164c6c:
MOV RDI,qword ptr [R14 + 0x18]
TEST RDI,RDI
JZ 0x00164c91
LEA RAX,[0x13ac20]
LEA RSI,[RSP + 0x18]
MOV qword ptr [RSI],RAX
LEA RDX,[RSP + 0x10]
MOV qword ptr [RDX],R14
CALL 0x0013fc96
LAB_00164c91:
MOVZX EAX,byte ptr [R14 + 0x2]
LEA RCX,[0x1b5c20]
MOV EAX,dword ptr [RCX + RAX*0x4]
DEC EAX
CMP EAX,0x9
JA 0x00164f22
LEA RCX,[0x1b9880]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_1:
MOV EBP,dword ptr [R14 + 0x40]
JMP 0x00164e3e
LAB_00164cc4:
CMP dword ptr [RDX + 0x4],0x1
JNZ 0x00164cd8
MOV RAX,qword ptr [RDX + 0x20]
TEST byte ptr [RAX + 0x1],0x2
JNZ 0x00164c2f
LAB_00164cd8:
MOV RAX,qword ptr [RDX + 0x10]
MOV RCX,RDX
SUB RCX,qword ptr [RAX + 0x30]
SHR RCX,0x3
IMUL EAX,ECX,0x33333334
ADD EAX,dword ptr [R12 + 0x2c]
MOV EAX,dword ptr [RBX + RAX*0x1]
CMP EAX,dword ptr [R14 + 0x4]
JNZ 0x00164f22
MOV RDI,R12
MOV RSI,RBX
ADD RSP,0x20
POP RBX
POP R12
POP R14
POP R15
POP RBP
JMP 0x001693a6
caseD_a:
MOV RDI,R14
CALL 0x0016454a
MOV EBP,EAX
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
ADD RBX,RAX
TEST BPL,BPL
JZ 0x00164da7
MOV RAX,qword ptr [RBX]
MOV RDI,RBX
CALL qword ptr [RAX + 0x58]
JMP 0x00164f22
caseD_9:
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOVSXD RCX,dword ptr [RBX + RAX*0x1 + 0x8]
TEST RCX,RCX
JLE 0x00164f22
MOV RDX,qword ptr [RBX + RAX*0x1 + 0x10]
XOR ESI,ESI
LAB_00164d65:
MOV RDI,qword ptr [RDX + RSI*0x8 + 0x8]
INC RSI
MOV qword ptr [RDI + 0x8],0x0
MOV RDI,qword ptr [RDI]
MOV byte ptr [RDI],0x0
CMP RCX,RSI
JNZ 0x00164d65
MOV dword ptr [RBX + RAX*0x1 + 0x8],0x0
JMP 0x00164f22
caseD_2:
MOV R12,qword ptr [R14 + 0x40]
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOV qword ptr [RBX + RAX*0x1],R12
JMP 0x00164f22
LAB_00164da7:
MOVSXD R14,dword ptr [RBX + 0x8]
TEST R14,R14
JLE 0x00164f22
MOV R15,qword ptr [RBX + 0x10]
XOR R12D,R12D
LAB_00164dbb:
MOV RDI,qword ptr [R15 + R12*0x8 + 0x8]
INC R12
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x20]
CMP R14,R12
JNZ 0x00164dbb
MOV dword ptr [RBX + 0x8],0x0
JMP 0x00164f22
caseD_5:
MOVSD XMM0,qword ptr [R14 + 0x40]
MOVSD qword ptr [RSP + 0x8],XMM0
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOVSD XMM0,qword ptr [RSP + 0x8]
MOVSD qword ptr [RBX + RAX*0x1],XMM0
JMP 0x00164f22
caseD_a:
MOV RDI,R15
MOV RSI,R14
CALL 0x0016de24
CMP EAX,-0x1
JZ 0x00164edc
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOV RDI,qword ptr [RBX + RAX*0x1]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x20]
JMP 0x00164f22
caseD_8:
MOV RDI,R14
CALL 0x0011fb14
MOV EBP,dword ptr [RAX + 0x4]
LAB_00164e3e:
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOV dword ptr [RBX + RAX*0x1],EBP
JMP 0x00164f22
caseD_6:
MOVSS XMM0,dword ptr [R14 + 0x40]
MOVSS dword ptr [RSP + 0x8],XMM0
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOVSS XMM0,dword ptr [RSP + 0x8]
MOVSS dword ptr [RBX + RAX*0x1],XMM0
JMP 0x00164f22
caseD_7:
MOV BPL,byte ptr [R14 + 0x40]
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOV byte ptr [RBX + RAX*0x1],BPL
JMP 0x00164f22
caseD_9:
MOV RDI,R15
MOV RSI,R14
CALL 0x0016e994
MOV EBP,EAX
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
ADD RBX,RAX
TEST BPL,BPL
JZ 0x00164ec8
MOV qword ptr [RBX + 0x8],0x0
MOV RAX,qword ptr [RBX]
MOV byte ptr [RAX],0x0
JMP 0x00164f22
LAB_00164ec8:
MOV RDI,RBX
CALL 0x001933e4
LEA RAX,[0x203278]
MOV qword ptr [RBX],RAX
JMP 0x00164f22
LAB_00164edc:
MOV RCX,qword ptr [RBX + 0x8]
MOV RAX,RCX
AND RAX,-0x4
TEST CL,0x1
JNZ 0x00164f2f
LAB_00164eec:
TEST RAX,RAX
JNZ 0x00164f0d
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOV RDI,qword ptr [RBX + RAX*0x1]
TEST RDI,RDI
JZ 0x00164f0d
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x8]
LAB_00164f0d:
MOV RDI,R15
MOV RSI,R14
CALL 0x0016ea6a
MOV EAX,EAX
MOV qword ptr [RBX + RAX*0x1],0x0
default:
ADD RSP,0x20
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_00164f2f:
MOV RAX,qword ptr [RAX]
JMP 0x00164eec
|
/* google::protobuf::Reflection::ClearField(google::protobuf::Message*,
google::protobuf::FieldDescriptor const*) const */
void __thiscall
google::protobuf::Reflection::ClearField(Reflection *this,Message *param_1,FieldDescriptor *param_2)
{
ReflectionSchema *this_00;
long lVar1;
int8 uVar2;
FieldDescriptor FVar3;
OneofDescriptor *pOVar4;
byte bVar5;
char cVar6;
uint uVar7;
int iVar8;
ulong uVar9;
long lVar10;
int8 *puVar11;
Message *pMVar12;
ArenaStringPtr *this_01;
int4 uVar13;
long lVar14;
FieldDescriptor *local_38;
code *local_30;
if (*(Descriptor **)(param_2 + 0x20) != *(Descriptor **)this) {
(anonymous_namespace)::ReportReflectionUsageError
(*(Descriptor **)this,param_2,"ClearField","Field does not match message type.");
}
FVar3 = param_2[1];
if (((byte)FVar3 & 8) != 0) {
internal::ExtensionSet::ClearExtension
((ExtensionSet *)(param_1 + *(uint *)(this + 0x28)),*(int *)(param_2 + 4));
return;
}
this_00 = (ReflectionSchema *)(this + 8);
if ((~(byte)FVar3 & 0x60) == 0) {
if (*(once_flag **)(param_2 + 0x18) != (once_flag *)0x0) {
local_30 = FieldDescriptor::TypeOnceInit;
local_38 = param_2;
std::
call_once<void(*)(google::protobuf::FieldDescriptor_const*),google::protobuf::FieldDescriptor_const*>
(*(once_flag **)(param_2 + 0x18),(_func_void_FieldDescriptor_ptr *)&local_30,
&local_38);
}
switch(*(int4 *)(FieldDescriptor::kTypeToCppTypeMap + (ulong)(byte)param_2[2] * 4)) {
case 1:
case 2:
case 3:
case 4:
case 5:
case 6:
case 7:
case 8:
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
*(int4 *)(param_1 + uVar7) = 0;
return;
case 9:
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
uVar9 = (ulong)uVar7;
iVar8 = *(int *)(param_1 + uVar9 + 8);
if ((long)iVar8 < 1) {
return;
}
lVar10 = *(long *)(param_1 + uVar9 + 0x10);
lVar14 = 0;
do {
puVar11 = *(int8 **)(lVar10 + 8 + lVar14 * 8);
lVar14 = lVar14 + 1;
puVar11[1] = 0;
*(int1 *)*puVar11 = 0;
} while (iVar8 != lVar14);
*(int4 *)(param_1 + uVar9 + 8) = 0;
return;
case 10:
goto switchD_00164bdd_caseD_a;
default:
return;
}
}
pOVar4 = *(OneofDescriptor **)(param_2 + 0x28);
if ((pOVar4 != (OneofDescriptor *)0x0 && ((byte)FVar3 & 0x10) != 0) &&
((*(int *)(pOVar4 + 4) != 1 || ((*(byte *)(*(long *)(pOVar4 + 0x20) + 1) & 2) == 0)))) {
if (*(int *)(param_1 +
(uint)((int)((ulong)((long)pOVar4 - *(long *)(*(long *)(pOVar4 + 0x10) + 0x30)) >> 3
) * 0x33333334 + *(int *)(this + 0x2c))) != *(int *)(param_2 + 4)) {
return;
}
ClearOneof(this,param_1,pOVar4);
return;
}
cVar6 = HasBit(this,param_1,param_2);
if (cVar6 == '\0') {
return;
}
uVar7 = internal::ReflectionSchema::HasBitIndex(this_00,param_2);
if (uVar7 != 0xffffffff) {
bVar5 = (byte)uVar7 & 0x1f;
*(uint *)(param_1 + (ulong)(uVar7 >> 5) * 4 + (ulong)*(uint *)(this + 0x20)) =
*(uint *)(param_1 + (ulong)(uVar7 >> 5) * 4 + (ulong)*(uint *)(this + 0x20)) &
(-2 << bVar5 | 0xfffffffeU >> 0x20 - bVar5);
}
if (*(once_flag **)(param_2 + 0x18) != (once_flag *)0x0) {
local_30 = FieldDescriptor::TypeOnceInit;
local_38 = param_2;
std::
call_once<void(*)(google::protobuf::FieldDescriptor_const*),google::protobuf::FieldDescriptor_const*>
(*(once_flag **)(param_2 + 0x18),(_func_void_FieldDescriptor_ptr *)&local_30,&local_38
);
}
switch(*(int4 *)(FieldDescriptor::kTypeToCppTypeMap + (ulong)(byte)param_2[2] * 4)) {
case 1:
case 3:
uVar13 = *(int4 *)(param_2 + 0x40);
goto LAB_00164e3e;
case 2:
case 4:
uVar2 = *(int8 *)(param_2 + 0x40);
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
*(int8 *)(param_1 + uVar7) = uVar2;
break;
case 5:
uVar2 = *(int8 *)(param_2 + 0x40);
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
*(int8 *)(param_1 + uVar7) = uVar2;
break;
case 6:
uVar13 = *(int4 *)(param_2 + 0x40);
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
*(int4 *)(param_1 + uVar7) = uVar13;
break;
case 7:
FVar3 = param_2[0x40];
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
*(FieldDescriptor *)(param_1 + uVar7) = FVar3;
break;
case 8:
lVar10 = FieldDescriptor::default_value_enum(param_2);
uVar13 = *(int4 *)(lVar10 + 4);
LAB_00164e3e:
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
*(int4 *)(param_1 + uVar7) = uVar13;
break;
case 9:
cVar6 = internal::ReflectionSchema::IsFieldInlined(this_00,param_2);
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
this_01 = (ArenaStringPtr *)(param_1 + uVar7);
if (cVar6 == '\0') {
internal::ArenaStringPtr::Destroy(this_01);
*(int8 **)this_01 = &internal::fixed_address_empty_string_abi_cxx11_;
}
else {
*(int8 *)(this_01 + 8) = 0;
**(int1 **)this_01 = 0;
}
break;
case 10:
iVar8 = internal::ReflectionSchema::HasBitIndex(this_00,param_2);
if (iVar8 == -1) {
puVar11 = (int8 *)(*(ulong *)(param_1 + 8) & 0xfffffffffffffffc);
if ((*(ulong *)(param_1 + 8) & 1) != 0) {
puVar11 = (int8 *)*puVar11;
}
if (puVar11 == (int8 *)0x0) {
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
if (*(long **)(param_1 + uVar7) != (long *)0x0) {
(**(code **)(**(long **)(param_1 + uVar7) + 8))();
}
}
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
*(int8 *)(param_1 + uVar7) = 0;
}
else {
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
(**(code **)(**(long **)(param_1 + uVar7) + 0x20))();
}
}
return;
switchD_00164bdd_caseD_a:
cVar6 = (anonymous_namespace)::IsMapFieldInApi(param_2);
uVar7 = internal::ReflectionSchema::GetFieldOffset(this_00,param_2);
pMVar12 = param_1 + uVar7;
if (cVar6 != '\0') {
(**(code **)(*(long *)pMVar12 + 0x58))(pMVar12);
return;
}
iVar8 = *(int *)(pMVar12 + 8);
if ((long)iVar8 < 1) {
return;
}
lVar10 = *(long *)(pMVar12 + 0x10);
lVar14 = 0;
do {
lVar1 = lVar14 * 8;
lVar14 = lVar14 + 1;
(**(code **)(**(long **)(lVar10 + 8 + lVar1) + 0x20))();
} while (iVar8 != lVar14);
*(int4 *)(pMVar12 + 8) = 0;
return;
}
|
|
64,836 |
std::vector<int, std::allocator<int>> string_split<int>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char)
|
llama.cpp/common/common.h
|
static std::vector<T> string_split(const std::string & str, char delim) {
static_assert(!std::is_same<T, std::string>::value, "Please use the specialized version for std::string");
std::vector<T> values;
std::istringstream str_stream(str);
std::string token;
while (std::getline(str_stream, token, delim)) {
T value;
std::istringstream token_stream(token);
token_stream >> value;
values.push_back(value);
}
return values;
}
|
O3
|
c
|
std::vector<int, std::allocator<int>> string_split<int>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x328, %rsp # imm = 0x328
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
xorl %r14d, %r14d
movq %r14, 0x10(%rdi)
leaq 0x28(%rsp), %r15
movq %r15, %rdi
movl $0x8, %edx
callq 0x21810
leaq 0x18(%rsp), %rax
movq %rax, -0x10(%rax)
movq %r14, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x8(%rsp), %r12
leaq 0x1a8(%rsp), %r13
leaq 0x4(%rsp), %rbp
movq 0x1023a3(%rip), %r14 # 0x171fd0
movq %r15, %rdi
movq %r12, %rsi
movl $0x2c, %edx
callq 0x21040
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x6fca5
movq %r13, %rdi
movq %r12, %rsi
movl $0x8, %edx
callq 0x21810
movq %r13, %rdi
movq %rbp, %rsi
callq 0x22480
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0x6fc80
movl 0x4(%rsp), %eax
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rbx)
jmp 0x6fc8b
movq %rbx, %rdi
movq %rbp, %rdx
callq 0x9d154
movq %r13, %rdi
movq %r14, %rsi
callq 0x22080
leaq 0x220(%rsp), %rdi
callq 0x21cc0
jmp 0x6fc2d
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x6fcc1
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x21180
movq 0x102308(%rip), %rsi # 0x171fd0
leaq 0x28(%rsp), %rdi
callq 0x22080
leaq 0xa0(%rsp), %rdi
callq 0x21cc0
addq $0x328, %rsp # imm = 0x328
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x6fcf3
movq %rax, %r14
jmp 0x6fd1c
movq %rax, %r14
movq 0x1022ce(%rip), %rsi # 0x171fd0
leaq 0x1a8(%rsp), %rdi
callq 0x22080
leaq 0x220(%rsp), %rdi
callq 0x21cc0
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x6fd38
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x21180
movq 0x102291(%rip), %rsi # 0x171fd0
leaq 0x28(%rsp), %rdi
callq 0x22080
leaq 0xa0(%rsp), %rdi
callq 0x21cc0
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x6fd6a
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x21180
movq %r14, %rdi
callq 0x21b70
|
_ZL12string_splitIiESt6vectorIT_SaIS1_EERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEc:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 328h
mov rbx, rdi
xorps xmm0, xmm0
movups xmmword ptr [rdi], xmm0
xor r14d, r14d
mov [rdi+10h], r14
lea r15, [rsp+358h+var_330]
mov rdi, r15
mov edx, 8
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode; std::istringstream::basic_istringstream(std::string const&,std::_Ios_Openmode)
lea rax, [rsp+358h+var_340]
mov [rax-10h], rax
mov [rax-8], r14
mov byte ptr [rax], 0
lea r12, [rsp+358h+var_350]
lea r13, [rsp+358h+var_1B0]
lea rbp, [rsp+358h+var_354]
mov r14, cs:_ZTTNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEE_ptr
loc_6FC2D:
mov rdi, r15
mov rsi, r12
mov edx, 2Ch ; ','
call __ZSt7getlineIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EES4_; std::getline<char,std::char_traits<char>,std::allocator<char>>(std::istream &,std::string &,char)
mov rcx, [rax]
mov rcx, [rcx-18h]
test byte ptr [rax+rcx+20h], 5
jnz short loc_6FCA5
mov rdi, r13
mov rsi, r12
mov edx, 8
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode; std::istringstream::basic_istringstream(std::string const&,std::_Ios_Openmode)
mov rdi, r13
mov rsi, rbp
call __ZNSirsERi; std::istream::operator>>(int &)
mov rsi, [rbx+8]
cmp rsi, [rbx+10h]
jz short loc_6FC80
mov eax, [rsp+358h+var_354]
mov [rsi], eax
add rsi, 4
mov [rbx+8], rsi
jmp short loc_6FC8B
loc_6FC80:
mov rdi, rbx
mov rdx, rbp
call _ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRKiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_; std::vector<int>::_M_realloc_insert<int const&>(__gnu_cxx::__normal_iterator<int *,std::vector<int>>,int const&)
loc_6FC8B:
mov rdi, r13
mov rsi, r14
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED2Ev; std::istringstream::~istringstream()
lea rdi, [rsp+358h+var_138]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
jmp short loc_6FC2D
loc_6FCA5:
mov rdi, [rsp+358h+var_350]; void *
lea rax, [rsp+358h+var_340]
cmp rdi, rax
jz short loc_6FCC1
mov rsi, [rsp+358h+var_340]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_6FCC1:
mov rsi, cs:_ZTTNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+358h+var_330]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED2Ev; std::istringstream::~istringstream()
lea rdi, [rsp+358h+var_2B8]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
add rsp, 328h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short $+2
loc_6FCF3:
mov r14, rax
jmp short loc_6FD1C
mov r14, rax
mov rsi, cs:_ZTTNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+arg_1A0]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED2Ev; std::istringstream::~istringstream()
lea rdi, [rsp+arg_218]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
loc_6FD1C:
mov rdi, [rsp+arg_0]; void *
lea rax, [rsp+arg_10]
cmp rdi, rax
jz short loc_6FD38
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_6FD38:
mov rsi, cs:_ZTTNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+arg_20]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED2Ev; std::istringstream::~istringstream()
lea rdi, [rsp+arg_98]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
mov rdi, [rbx]; void *
test rdi, rdi
jz short loc_6FD6A
mov rsi, [rbx+10h]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_6FD6A:
mov rdi, r14
call __Unwind_Resume
|
void string_split<int>(long long a1, long long a2)
{
_QWORD *v2; // rax
_DWORD *v3; // rsi
int v4; // [rsp+4h] [rbp-354h] BYREF
void *v5[2]; // [rsp+8h] [rbp-350h] BYREF
_QWORD v6[2]; // [rsp+18h] [rbp-340h] BYREF
_BYTE v7[120]; // [rsp+28h] [rbp-330h] BYREF
_BYTE v8[264]; // [rsp+A0h] [rbp-2B8h] BYREF
_BYTE v9[120]; // [rsp+1A8h] [rbp-1B0h] BYREF
_BYTE v10[312]; // [rsp+220h] [rbp-138h] BYREF
*(_OWORD *)a1 = 0LL;
*(_QWORD *)(a1 + 16) = 0LL;
std::istringstream::basic_istringstream(v7, a2, 8LL);
v5[0] = v6;
v5[1] = 0LL;
LOBYTE(v6[0]) = 0;
while ( 1 )
{
v2 = (_QWORD *)std::getline<char,std::char_traits<char>,std::allocator<char>>(v7, v5, 44LL);
if ( (*((_BYTE *)v2 + *(_QWORD *)(*v2 - 24LL) + 32) & 5) != 0 )
break;
std::istringstream::basic_istringstream(v9, v5, 8LL);
std::istream::operator>>(v9, &v4);
v3 = *(_DWORD **)(a1 + 8);
if ( v3 == *(_DWORD **)(a1 + 16) )
{
std::vector<int>::_M_realloc_insert<int const&>(a1, v3, &v4);
}
else
{
*v3 = v4;
*(_QWORD *)(a1 + 8) = v3 + 1;
}
std::istringstream::~istringstream(v9, &`VTT for'std::istringstream);
std::ios_base::~ios_base((std::ios_base *)v10);
}
if ( v5[0] != v6 )
operator delete(v5[0], v6[0] + 1LL);
std::istringstream::~istringstream(v7, &`VTT for'std::istringstream);
std::ios_base::~ios_base((std::ios_base *)v8);
}
|
string_split<int>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x328
MOV RBX,RDI
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI],XMM0
XOR R14D,R14D
MOV qword ptr [RDI + 0x10],R14
LEA R15,[RSP + 0x28]
MOV RDI,R15
MOV EDX,0x8
CALL 0x00121810
LEA RAX,[RSP + 0x18]
MOV qword ptr [RAX + -0x10],RAX
MOV qword ptr [RAX + -0x8],R14
MOV byte ptr [RAX],0x0
LEA R12,[RSP + 0x8]
LEA R13,[RSP + 0x1a8]
LEA RBP,[RSP + 0x4]
MOV R14,qword ptr [0x00271fd0]
LAB_0016fc2d:
MOV RDI,R15
MOV RSI,R12
MOV EDX,0x2c
CALL 0x00121040
MOV RCX,qword ptr [RAX]
MOV RCX,qword ptr [RCX + -0x18]
TEST byte ptr [RAX + RCX*0x1 + 0x20],0x5
JNZ 0x0016fca5
LAB_0016fc4b:
MOV RDI,R13
MOV RSI,R12
MOV EDX,0x8
CALL 0x00121810
LAB_0016fc5b:
MOV RDI,R13
MOV RSI,RBP
CALL 0x00122480
MOV RSI,qword ptr [RBX + 0x8]
CMP RSI,qword ptr [RBX + 0x10]
JZ 0x0016fc80
MOV EAX,dword ptr [RSP + 0x4]
MOV dword ptr [RSI],EAX
ADD RSI,0x4
MOV qword ptr [RBX + 0x8],RSI
JMP 0x0016fc8b
LAB_0016fc80:
MOV RDI,RBX
MOV RDX,RBP
CALL 0x0019d154
LAB_0016fc8b:
MOV RDI,R13
MOV RSI,R14
CALL 0x00122080
LEA RDI,[RSP + 0x220]
CALL 0x00121cc0
JMP 0x0016fc2d
LAB_0016fca5:
MOV RDI,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x18]
CMP RDI,RAX
JZ 0x0016fcc1
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x00121180
LAB_0016fcc1:
MOV RSI,qword ptr [0x00271fd0]
LEA RDI,[RSP + 0x28]
CALL 0x00122080
LEA RDI,[RSP + 0xa0]
CALL 0x00121cc0
ADD RSP,0x328
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* std::vector<int, std::allocator<int> > string_split<int>(std::__cxx11::string const&, char) */
void string_split<int>(string *param_1,char param_2)
{
int *piVar1;
istream *piVar2;
int7 in_register_00000031;
int local_354;
int1 *local_350;
int8 local_348;
int1 local_340;
int7 uStack_33f;
istream local_330 [120];
ios_base local_2b8 [264];
istream local_1b0 [120];
ios_base local_138 [264];
*(int8 *)param_1 = 0;
*(int8 *)(param_1 + 8) = 0;
*(int8 *)(param_1 + 0x10) = 0;
std::__cxx11::istringstream::istringstream
((istringstream *)local_330,CONCAT71(in_register_00000031,param_2),8);
local_350 = &local_340;
local_348 = 0;
local_340 = 0;
while( true ) {
/* try { // try from 0016fc2d to 0016fc3c has its CatchHandler @ 0016fcf3 */
piVar2 = std::getline<char,std::char_traits<char>,std::allocator<char>>
(local_330,(string *)&local_350,',');
if (((byte)piVar2[*(long *)(*(long *)piVar2 + -0x18) + 0x20] & 5) != 0) break;
/* try { // try from 0016fc4b to 0016fc5a has its CatchHandler @ 0016fcf1 */
std::__cxx11::istringstream::istringstream((istringstream *)local_1b0,(string *)&local_350,8);
/* try { // try from 0016fc5b to 0016fc8a has its CatchHandler @ 0016fcf8 */
std::istream::operator>>(local_1b0,&local_354);
piVar1 = *(int **)(param_1 + 8);
if (piVar1 == *(int **)(param_1 + 0x10)) {
std::vector<int,std::allocator<int>>::_M_realloc_insert<int_const&>
((vector<int,std::allocator<int>> *)param_1,piVar1,&local_354);
}
else {
*piVar1 = local_354;
*(int **)(param_1 + 8) = piVar1 + 1;
}
std::__cxx11::istringstream::~istringstream((istringstream *)local_1b0);
std::ios_base::~ios_base(local_138);
}
if (local_350 != &local_340) {
operator_delete(local_350,CONCAT71(uStack_33f,local_340) + 1);
}
std::__cxx11::istringstream::~istringstream((istringstream *)local_330);
std::ios_base::~ios_base(local_2b8);
return;
}
|
|
64,837 |
ggml_rope_impl
|
7CodeWizard[P]stablediffusion/ggml/src/ggml.c
|
static struct ggml_tensor * ggml_rope_impl(
struct ggml_context * ctx,
struct ggml_tensor * a,
struct ggml_tensor * b,
int n_dims,
int mode,
int n_ctx,
int n_orig_ctx,
float freq_base,
float freq_scale,
float ext_factor,
float attn_factor,
float beta_fast,
float beta_slow,
float xpos_base,
bool xpos_down,
bool inplace) {
GGML_ASSERT(ggml_is_vector(b));
GGML_ASSERT(b->type == GGML_TYPE_I32);
GGML_ASSERT(a->ne[2] == b->ne[0]);
bool is_node = false;
if (a->grad) {
is_node = true;
}
struct ggml_tensor * result = inplace ? ggml_view_tensor(ctx, a) : ggml_dup_tensor(ctx, a);
int32_t params[13] = { /*n_past*/ 0, n_dims, mode, n_ctx, n_orig_ctx };
memcpy(params + 5, &freq_base, sizeof(float));
memcpy(params + 6, &freq_scale, sizeof(float));
memcpy(params + 7, &ext_factor, sizeof(float));
memcpy(params + 8, &attn_factor, sizeof(float));
memcpy(params + 9, &beta_fast, sizeof(float));
memcpy(params + 10, &beta_slow, sizeof(float));
memcpy(params + 11, &xpos_base, sizeof(float));
memcpy(params + 12, &xpos_down, sizeof(bool));
ggml_set_op_params(result, params, sizeof(params));
result->op = GGML_OP_ROPE;
result->grad = is_node ? ggml_dup_tensor(ctx, result) : NULL;
result->src[0] = a;
result->src[1] = b;
return result;
}
|
O0
|
c
|
ggml_rope_impl:
subq $0xc8, %rsp
movl %ecx, 0x2c(%rsp)
movq %rdx, %rax
movl 0x2c(%rsp), %edx
movq %rax, 0x30(%rsp)
movq %rsi, %rax
movq 0x30(%rsp), %rsi
movq %rax, 0x38(%rsp)
movq %rdi, %r10
movq 0x38(%rsp), %rdi
movb 0xe0(%rsp), %al
movb 0xd8(%rsp), %cl
movl 0xd0(%rsp), %r11d
movq %r10, 0xc0(%rsp)
movq %rdi, 0xb8(%rsp)
movq %rsi, 0xb0(%rsp)
movl %edx, 0xac(%rsp)
movl %r8d, 0xa8(%rsp)
movl %r9d, 0xa4(%rsp)
vmovss %xmm0, 0xa0(%rsp)
vmovss %xmm1, 0x9c(%rsp)
vmovss %xmm2, 0x98(%rsp)
vmovss %xmm3, 0x94(%rsp)
vmovss %xmm4, 0x90(%rsp)
vmovss %xmm5, 0x8c(%rsp)
vmovss %xmm6, 0x88(%rsp)
andb $0x1, %cl
movb %cl, 0x87(%rsp)
andb $0x1, %al
movb %al, 0x86(%rsp)
movq 0xb0(%rsp), %rdi
callq 0x11b270
testb $0x1, %al
jne 0x124688
movq 0xb38dd(%rip), %rax # 0x1d7f28
movq (%rax), %rdi
callq 0xb8e0
movq 0xb394e(%rip), %rax # 0x1d7fa8
movq (%rax), %rdi
leaq 0x5b5b6(%rip), %rsi # 0x17fc1a
leaq 0x65003(%rip), %rdx # 0x18966e
movl $0x139e, %ecx # imm = 0x139E
leaq 0x65753(%rip), %r8 # 0x189dca
movb $0x0, %al
callq 0xbae0
callq 0x11a4f0
callq 0xb3a0
jmp 0x12468a
jmp 0x12468c
movq 0xb0(%rsp), %rax
cmpl $0x12, (%rax)
je 0x1246dd
movq 0xb3888(%rip), %rax # 0x1d7f28
movq (%rax), %rdi
callq 0xb8e0
movq 0xb38f9(%rip), %rax # 0x1d7fa8
movq (%rax), %rdi
leaq 0x5b561(%rip), %rsi # 0x17fc1a
leaq 0x64fae(%rip), %rdx # 0x18966e
movl $0x139f, %ecx # imm = 0x139F
leaq 0x656ab(%rip), %r8 # 0x189d77
movb $0x0, %al
callq 0xbae0
callq 0x11a4f0
callq 0xb3a0
jmp 0x1246df
jmp 0x1246e1
movq 0xb8(%rsp), %rax
movq 0x20(%rax), %rax
movq 0xb0(%rsp), %rcx
cmpq 0x10(%rcx), %rax
je 0x12473f
movq 0xb3826(%rip), %rax # 0x1d7f28
movq (%rax), %rdi
callq 0xb8e0
movq 0xb3897(%rip), %rax # 0x1d7fa8
movq (%rax), %rdi
leaq 0x5b4ff(%rip), %rsi # 0x17fc1a
leaq 0x64f4c(%rip), %rdx # 0x18966e
movl $0x13a0, %ecx # imm = 0x13A0
leaq 0x656ae(%rip), %r8 # 0x189ddc
movb $0x0, %al
callq 0xbae0
callq 0x11a4f0
callq 0xb3a0
jmp 0x124741
movb $0x0, 0x85(%rsp)
movq 0xb8(%rsp), %rax
cmpq $0x0, 0x98(%rax)
je 0x124763
movb $0x1, 0x85(%rsp)
testb $0x1, 0x86(%rsp)
je 0x124789
movq 0xc0(%rsp), %rdi
movq 0xb8(%rsp), %rsi
callq 0x11e7e0
movq %rax, 0x20(%rsp)
jmp 0x1247a3
movq 0xc0(%rsp), %rdi
movq 0xb8(%rsp), %rsi
callq 0x11cfc0
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x78(%rsp)
movl $0x0, 0x40(%rsp)
movl 0xac(%rsp), %eax
movl %eax, 0x44(%rsp)
movl 0xa8(%rsp), %eax
movl %eax, 0x48(%rsp)
movl 0xa4(%rsp), %eax
movl %eax, 0x4c(%rsp)
movl 0xd0(%rsp), %eax
movl %eax, 0x50(%rsp)
leaq 0x40(%rsp), %rax
addq $0x14, %rax
leaq 0x40(%rsp), %rcx
addq $0x34, %rcx
movq %rcx, 0x10(%rsp)
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq 0x10(%rsp), %rcx
movl $0x0, (%rax)
addq $0x4, %rax
cmpq %rcx, %rax
movq %rax, 0x18(%rsp)
jne 0x1247fd
movl 0xa0(%rsp), %eax
movl %eax, 0x54(%rsp)
movl 0x9c(%rsp), %eax
movl %eax, 0x58(%rsp)
movl 0x98(%rsp), %eax
movl %eax, 0x5c(%rsp)
movl 0x94(%rsp), %eax
movl %eax, 0x60(%rsp)
movl 0x90(%rsp), %eax
movl %eax, 0x64(%rsp)
movl 0x8c(%rsp), %eax
movl %eax, 0x68(%rsp)
movl 0x88(%rsp), %eax
movl %eax, 0x6c(%rsp)
movb 0x87(%rsp), %al
movb %al, 0x70(%rsp)
movq 0x78(%rsp), %rdi
leaq 0x40(%rsp), %rsi
movl $0x34, %edx
callq 0x120a30
movq 0x78(%rsp), %rax
movl $0x29, 0x50(%rax)
testb $0x1, 0x85(%rsp)
je 0x1248b6
movq 0xc0(%rsp), %rdi
movq 0x78(%rsp), %rsi
callq 0x11cfc0
movq %rax, 0x8(%rsp)
jmp 0x1248bf
xorl %eax, %eax
movq %rax, 0x8(%rsp)
jmp 0x1248bf
movq 0x8(%rsp), %rcx
movq 0x78(%rsp), %rax
movq %rcx, 0x98(%rax)
movq 0xb8(%rsp), %rcx
movq 0x78(%rsp), %rax
movq %rcx, 0xa0(%rax)
movq 0xb0(%rsp), %rcx
movq 0x78(%rsp), %rax
movq %rcx, 0xa8(%rax)
movq 0x78(%rsp), %rax
addq $0xc8, %rsp
retq
nopw %cs:(%rax,%rax)
|
ggml_rope_impl:
sub rsp, 0C8h
mov [rsp+0C8h+var_9C], ecx
mov rax, rdx
mov edx, [rsp+0C8h+var_9C]
mov [rsp+0C8h+var_98], rax
mov rax, rsi
mov rsi, [rsp+0C8h+var_98]
mov [rsp+0C8h+var_90], rax
mov r10, rdi
mov rdi, [rsp+0C8h+var_90]
mov al, [rsp+0C8h+arg_10]
mov cl, [rsp+0C8h+arg_8]
mov r11d, [rsp+0C8h+arg_0]
mov [rsp+0C8h+var_8], r10
mov [rsp+0C8h+var_10], rdi
mov [rsp+0C8h+var_18], rsi
mov [rsp+0C8h+var_1C], edx
mov [rsp+0C8h+var_20], r8d
mov [rsp+0C8h+var_24], r9d
vmovss [rsp+0C8h+var_28], xmm0
vmovss [rsp+0C8h+var_2C], xmm1
vmovss [rsp+0C8h+var_30], xmm2
vmovss [rsp+0C8h+var_34], xmm3
vmovss [rsp+0C8h+var_38], xmm4
vmovss [rsp+0C8h+var_3C], xmm5
vmovss [rsp+0C8h+var_40], xmm6
and cl, 1
mov [rsp+0C8h+var_41], cl
and al, 1
mov [rsp+0C8h+var_42], al
mov rdi, [rsp+0C8h+var_18]
call ggml_is_vector
test al, 1
jnz short loc_124688
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_7; "/workspace/llm4binary/github/2025_star3"...
mov ecx, 139Eh
lea r8, aGgmlIsVectorB; "ggml_is_vector(b)"
mov al, 0
call _fprintf
call ggml_print_backtrace
call _abort
loc_124688:
jmp short $+2
loc_12468A:
jmp short $+2
loc_12468C:
mov rax, [rsp+0C8h+var_18]
cmp dword ptr [rax], 12h
jz short loc_1246DD
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_7; "/workspace/llm4binary/github/2025_star3"...
mov ecx, 139Fh
lea r8, aGgmlIsMatrixAG+2Ah; "b->type == GGML_TYPE_I32"
mov al, 0
call _fprintf
call ggml_print_backtrace
call _abort
loc_1246DD:
jmp short $+2
loc_1246DF:
jmp short $+2
loc_1246E1:
mov rax, [rsp+0C8h+var_10]
mov rax, [rax+20h]
mov rcx, [rsp+0C8h+var_18]
cmp rax, [rcx+10h]
jz short loc_12473F
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_7; "/workspace/llm4binary/github/2025_star3"...
mov ecx, 13A0h
lea r8, aANe2BNe0; "a->ne[2] == b->ne[0]"
mov al, 0
call _fprintf
call ggml_print_backtrace
call _abort
loc_12473F:
jmp short $+2
loc_124741:
mov [rsp+0C8h+var_43], 0
mov rax, [rsp+0C8h+var_10]
cmp qword ptr [rax+98h], 0
jz short loc_124763
mov [rsp+0C8h+var_43], 1
loc_124763:
test [rsp+0C8h+var_42], 1
jz short loc_124789
mov rdi, [rsp+0C8h+var_8]
mov rsi, [rsp+0C8h+var_10]
call ggml_view_tensor
mov [rsp+0C8h+var_A8], rax
jmp short loc_1247A3
loc_124789:
mov rdi, [rsp+0C8h+var_8]
mov rsi, [rsp+0C8h+var_10]
call ggml_dup_tensor
mov [rsp+0C8h+var_A8], rax
loc_1247A3:
mov rax, [rsp+0C8h+var_A8]
mov [rsp+0C8h+var_50], rax
mov [rsp+0C8h+var_88], 0
mov eax, [rsp+0C8h+var_1C]
mov [rsp+0C8h+var_84], eax
mov eax, [rsp+0C8h+var_20]
mov [rsp+0C8h+var_80], eax
mov eax, [rsp+0C8h+var_24]
mov [rsp+0C8h+var_7C], eax
mov eax, [rsp+0C8h+arg_0]
mov [rsp+0C8h+var_78], eax
lea rax, [rsp+0C8h+var_88]
add rax, 14h
lea rcx, [rsp+0C8h+var_88]
add rcx, 34h ; '4'
mov [rsp+0C8h+var_B8], rcx
mov [rsp+0C8h+var_B0], rax
loc_1247FD:
mov rax, [rsp+0C8h+var_B0]
mov rcx, [rsp+0C8h+var_B8]
mov dword ptr [rax], 0
add rax, 4
cmp rax, rcx
mov [rsp+0C8h+var_B0], rax
jnz short loc_1247FD
mov eax, [rsp+0C8h+var_28]
mov [rsp+0C8h+var_74], eax
mov eax, [rsp+0C8h+var_2C]
mov [rsp+0C8h+var_70], eax
mov eax, [rsp+0C8h+var_30]
mov [rsp+0C8h+var_6C], eax
mov eax, [rsp+0C8h+var_34]
mov [rsp+0C8h+var_68], eax
mov eax, [rsp+0C8h+var_38]
mov [rsp+0C8h+var_64], eax
mov eax, [rsp+0C8h+var_3C]
mov [rsp+0C8h+var_60], eax
mov eax, [rsp+0C8h+var_40]
mov [rsp+0C8h+var_5C], eax
mov al, [rsp+0C8h+var_41]
mov [rsp+0C8h+var_58], al
mov rdi, [rsp+0C8h+var_50]
lea rsi, [rsp+0C8h+var_88]
mov edx, 34h ; '4'
call ggml_set_op_params
mov rax, [rsp+0C8h+var_50]
mov dword ptr [rax+50h], 29h ; ')'
test [rsp+0C8h+var_43], 1
jz short loc_1248B6
mov rdi, [rsp+0C8h+var_8]
mov rsi, [rsp+0C8h+var_50]
call ggml_dup_tensor
mov [rsp+0C8h+var_C0], rax
jmp short loc_1248BF
loc_1248B6:
xor eax, eax
mov [rsp+0C8h+var_C0], rax
jmp short $+2
loc_1248BF:
mov rcx, [rsp+0C8h+var_C0]
mov rax, [rsp+0C8h+var_50]
mov [rax+98h], rcx
mov rcx, [rsp+0C8h+var_10]
mov rax, [rsp+0C8h+var_50]
mov [rax+0A0h], rcx
mov rcx, [rsp+0C8h+var_18]
mov rax, [rsp+0C8h+var_50]
mov [rax+0A8h], rcx
mov rax, [rsp+0C8h+var_50]
add rsp, 0C8h
retn
|
unsigned int * ggml_rope_impl(
long long a1,
unsigned int *a2,
_QWORD *a3,
int a4,
int a5,
int a6,
__m128 _XMM0,
__m128 _XMM1,
__m128 _XMM2,
__m128 _XMM3,
__m128 _XMM4,
__m128 _XMM5,
__m128 _XMM6,
__m128 a14,
int a15,
char a16,
char a17)
{
double v17; // xmm4_8
double v18; // xmm5_8
long long v19; // rdi
long long v20; // rdi
long long v21; // rdi
long long v23; // [rsp+8h] [rbp-C0h]
int *v24; // [rsp+18h] [rbp-B0h]
unsigned int *v25; // [rsp+20h] [rbp-A8h]
_DWORD v26[5]; // [rsp+40h] [rbp-88h] BYREF
_DWORD v27[7]; // [rsp+54h] [rbp-74h] BYREF
char v28; // [rsp+70h] [rbp-58h]
int v29; // [rsp+74h] [rbp-54h] BYREF
unsigned int *v30; // [rsp+78h] [rbp-50h]
bool v31; // [rsp+85h] [rbp-43h]
char v32; // [rsp+86h] [rbp-42h]
char v33; // [rsp+87h] [rbp-41h]
int v34; // [rsp+88h] [rbp-40h]
int v35; // [rsp+8Ch] [rbp-3Ch]
int v36; // [rsp+90h] [rbp-38h]
int v37; // [rsp+94h] [rbp-34h]
int v38; // [rsp+98h] [rbp-30h]
int v39; // [rsp+9Ch] [rbp-2Ch]
int v40; // [rsp+A0h] [rbp-28h]
int v41; // [rsp+A4h] [rbp-24h]
int v42; // [rsp+A8h] [rbp-20h]
int v43; // [rsp+ACh] [rbp-1Ch]
_QWORD *v44; // [rsp+B0h] [rbp-18h]
unsigned int *v45; // [rsp+B8h] [rbp-10h]
long long v46; // [rsp+C0h] [rbp-8h]
v46 = a1;
v45 = a2;
v44 = a3;
v43 = a4;
v42 = a5;
v41 = a6;
__asm
{
vmovss [rsp+0C8h+var_28], xmm0
vmovss [rsp+0C8h+var_2C], xmm1
vmovss [rsp+0C8h+var_30], xmm2
vmovss [rsp+0C8h+var_34], xmm3
vmovss [rsp+0C8h+var_38], xmm4
vmovss [rsp+0C8h+var_3C], xmm5
vmovss [rsp+0C8h+var_40], xmm6
}
v33 = a16 & 1;
v32 = a17 & 1;
if ( !ggml_is_vector(a3) )
{
fflush(stdout);
v19 = stderr;
fprintf(
stderr,
"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml/src/ggml.c",
5022,
"ggml_is_vector(b)");
ggml_print_backtrace();
abort(v19);
}
if ( *(_DWORD *)v44 != 18 )
{
fflush(stdout);
v20 = stderr;
fprintf(
stderr,
"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml/src/ggml.c",
5023,
"b->type == GGML_TYPE_I32");
ggml_print_backtrace();
abort(v20);
}
if ( *((_QWORD *)v45 + 4) != v44[2] )
{
fflush(stdout);
v21 = stderr;
fprintf(
stderr,
"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml/src/ggml.c",
5024,
"a->ne[2] == b->ne[0]");
ggml_print_backtrace();
abort(v21);
}
v31 = *((_QWORD *)v45 + 19) != 0LL;
if ( (v32 & 1) != 0 )
v25 = (unsigned int *)ggml_view_tensor(v46, (long long)v45, _XMM0, _XMM1, _XMM2, _XMM3, v17, v18, _XMM6, a14);
else
v25 = (unsigned int *)ggml_dup_tensor(v46, v45);
v30 = v25;
v26[0] = 0;
v26[1] = v43;
v26[2] = v42;
v26[3] = v41;
v26[4] = a15;
v24 = v27;
do
*v24++ = 0;
while ( v24 != &v29 );
v27[0] = v40;
v27[1] = v39;
v27[2] = v38;
v27[3] = v37;
v27[4] = v36;
v27[5] = v35;
v27[6] = v34;
v28 = v33;
ggml_set_op_params((long long)v30, (long long)v26, 52LL);
v30[20] = 41;
if ( v31 )
v23 = ggml_dup_tensor(v46, v30);
else
v23 = 0LL;
*((_QWORD *)v30 + 19) = v23;
*((_QWORD *)v30 + 20) = v45;
*((_QWORD *)v30 + 21) = v44;
return v30;
}
| |||
64,838 |
ggml_rope_impl
|
7CodeWizard[P]stablediffusion/ggml/src/ggml.c
|
static struct ggml_tensor * ggml_rope_impl(
struct ggml_context * ctx,
struct ggml_tensor * a,
struct ggml_tensor * b,
int n_dims,
int mode,
int n_ctx,
int n_orig_ctx,
float freq_base,
float freq_scale,
float ext_factor,
float attn_factor,
float beta_fast,
float beta_slow,
float xpos_base,
bool xpos_down,
bool inplace) {
GGML_ASSERT(ggml_is_vector(b));
GGML_ASSERT(b->type == GGML_TYPE_I32);
GGML_ASSERT(a->ne[2] == b->ne[0]);
bool is_node = false;
if (a->grad) {
is_node = true;
}
struct ggml_tensor * result = inplace ? ggml_view_tensor(ctx, a) : ggml_dup_tensor(ctx, a);
int32_t params[13] = { /*n_past*/ 0, n_dims, mode, n_ctx, n_orig_ctx };
memcpy(params + 5, &freq_base, sizeof(float));
memcpy(params + 6, &freq_scale, sizeof(float));
memcpy(params + 7, &ext_factor, sizeof(float));
memcpy(params + 8, &attn_factor, sizeof(float));
memcpy(params + 9, &beta_fast, sizeof(float));
memcpy(params + 10, &beta_slow, sizeof(float));
memcpy(params + 11, &xpos_base, sizeof(float));
memcpy(params + 12, &xpos_down, sizeof(bool));
ggml_set_op_params(result, params, sizeof(params));
result->op = GGML_OP_ROPE;
result->grad = is_node ? ggml_dup_tensor(ctx, result) : NULL;
result->src[0] = a;
result->src[1] = b;
return result;
}
|
O1
|
c
|
ggml_rope_impl:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
cmpq $0x1, 0x18(%rdx)
jne 0x93dac
movq %rdx, %rbx
cmpq $0x1, 0x20(%rdx)
jne 0x93dac
cmpq $0x1, 0x28(%rbx)
jne 0x93dac
cmpl $0x12, (%rbx)
jne 0x93db1
movq %rsi, %r14
movq 0x20(%rsi), %rax
cmpq 0x10(%rbx), %rax
jne 0x93db6
movl %ecx, %r12d
movl %r8d, %ebp
movl %r9d, %r15d
vmovss %xmm0, 0x4(%rsp)
vmovss %xmm1, 0x8(%rsp)
vmovss %xmm2, 0xc(%rsp)
vmovss %xmm3, 0x10(%rsp)
vmovss %xmm4, 0x14(%rsp)
vmovss %xmm5, 0x18(%rsp)
vmovss %xmm6, 0x1c(%rsp)
movq 0x98(%r14), %rax
movq %rax, 0x28(%rsp)
cmpb $0x0, 0xb0(%rsp)
movq %rdi, 0x20(%rsp)
je 0x93caa
movq %r14, %rsi
callq 0x90b1a
jmp 0x93cc1
movl (%r14), %esi
leaq 0x10(%r14), %rcx
movl $0x4, %edx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x8e8b7
movq %rax, %r13
leaq 0x30(%rsp), %rsi
movl $0x0, (%rsi)
movl %r12d, 0x4(%rsi)
movl %ebp, 0x8(%rsi)
movl %r15d, 0xc(%rsi)
movl 0xa0(%rsp), %eax
movl %eax, 0x10(%rsi)
vxorps %xmm0, %xmm0, %xmm0
vmovups %ymm0, 0x14(%rsi)
vmovss 0x4(%rsp), %xmm0
vmovss %xmm0, 0x14(%rsi)
vmovss 0x8(%rsp), %xmm0
vmovss %xmm0, 0x18(%rsi)
vmovss 0xc(%rsp), %xmm0
vmovss %xmm0, 0x1c(%rsi)
vmovss 0x10(%rsp), %xmm0
vmovss %xmm0, 0x20(%rsi)
vmovss 0x14(%rsp), %xmm0
vmovss %xmm0, 0x24(%rsi)
vmovss 0x18(%rsp), %xmm0
vmovss %xmm0, 0x28(%rsi)
vmovss 0x1c(%rsp), %xmm0
vmovss %xmm0, 0x2c(%rsi)
movb 0xa8(%rsp), %al
movb %al, 0x30(%rsi)
movl $0x34, %edx
movq %r13, %rdi
vzeroupper
callq 0x91e91
movl $0x29, 0x50(%r13)
cmpq $0x0, 0x28(%rsp)
je 0x93d83
movl (%r13), %esi
leaq 0x10(%r13), %rcx
movq 0x20(%rsp), %rdi
movl $0x4, %edx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x8e8b7
jmp 0x93d85
xorl %eax, %eax
movq %rax, 0x98(%r13)
movq %r14, 0xa0(%r13)
movq %rbx, 0xa8(%r13)
movq %r13, %rax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0xdefb
callq 0xdf40
callq 0xdf85
|
ggml_rope_impl:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 68h
cmp qword ptr [rdx+18h], 1
jnz loc_93DAC
mov rbx, rdx
cmp qword ptr [rdx+20h], 1
jnz loc_93DAC
cmp qword ptr [rbx+28h], 1
jnz loc_93DAC
cmp dword ptr [rbx], 12h
jnz loc_93DB1
mov r14, rsi
mov rax, [rsi+20h]
cmp rax, [rbx+10h]
jnz loc_93DB6
mov r12d, ecx
mov ebp, r8d
mov r15d, r9d
vmovss [rsp+98h+var_94], xmm0
vmovss [rsp+98h+var_90], xmm1
vmovss [rsp+98h+var_8C], xmm2
vmovss [rsp+98h+var_88], xmm3
vmovss [rsp+98h+var_84], xmm4
vmovss [rsp+98h+var_80], xmm5
vmovss [rsp+98h+var_7C], xmm6
mov rax, [r14+98h]
mov [rsp+98h+var_70], rax
cmp [rsp+98h+arg_10], 0
mov [rsp+98h+var_78], rdi
jz short loc_93CAA
mov rsi, r14
call ggml_view_tensor
jmp short loc_93CC1
loc_93CAA:
mov esi, [r14]
lea rcx, [r14+10h]
mov edx, 4
xor r8d, r8d
xor r9d, r9d
call ggml_new_tensor_impl
loc_93CC1:
mov r13, rax
lea rsi, [rsp+98h+var_68]
mov dword ptr [rsi], 0
mov [rsi+4], r12d
mov [rsi+8], ebp
mov [rsi+0Ch], r15d
mov eax, [rsp+98h+arg_0]
mov [rsi+10h], eax
vxorps xmm0, xmm0, xmm0
vmovups ymmword ptr [rsi+14h], ymm0
vmovss xmm0, [rsp+98h+var_94]
vmovss dword ptr [rsi+14h], xmm0
vmovss xmm0, [rsp+98h+var_90]
vmovss dword ptr [rsi+18h], xmm0
vmovss xmm0, [rsp+98h+var_8C]
vmovss dword ptr [rsi+1Ch], xmm0
vmovss xmm0, [rsp+98h+var_88]
vmovss dword ptr [rsi+20h], xmm0
vmovss xmm0, [rsp+98h+var_84]
vmovss dword ptr [rsi+24h], xmm0
vmovss xmm0, [rsp+98h+var_80]
vmovss dword ptr [rsi+28h], xmm0
vmovss xmm0, [rsp+98h+var_7C]
vmovss dword ptr [rsi+2Ch], xmm0
mov al, [rsp+98h+arg_8]
mov [rsi+30h], al
mov edx, 34h ; '4'
mov rdi, r13
vzeroupper
call ggml_set_op_params
mov dword ptr [r13+50h], 29h ; ')'
cmp [rsp+98h+var_70], 0
jz short loc_93D83
mov esi, [r13+0]
lea rcx, [r13+10h]
mov rdi, [rsp+98h+var_78]
mov edx, 4
xor r8d, r8d
xor r9d, r9d
call ggml_new_tensor_impl
jmp short loc_93D85
loc_93D83:
xor eax, eax
loc_93D85:
mov [r13+98h], rax
mov [r13+0A0h], r14
mov [r13+0A8h], rbx
mov rax, r13
add rsp, 68h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_93DAC:
call ggml_rope_impl_cold_1
loc_93DB1:
call ggml_rope_impl_cold_2
loc_93DB6:
call ggml_rope_impl_cold_3
|
long long ggml_rope_impl(
long long a1,
long long a2,
long long a3,
int a4,
int a5,
int a6,
__m128 _XMM0,
__m128 _XMM1,
__m128 _XMM2,
__m128 _XMM3,
__m128 _XMM4,
__m128 _XMM5,
__m128 _XMM6,
__m128 a14,
int a15,
char a16,
char a17)
{
long long v23; // rax
long long v24; // r13
long long v34; // rax
long long v43; // [rsp+28h] [rbp-70h]
_DWORD v44[12]; // [rsp+30h] [rbp-68h] BYREF
char v45; // [rsp+60h] [rbp-38h]
if ( *(_QWORD *)(a3 + 24) != 1LL || *(_QWORD *)(a3 + 32) != 1LL || *(_QWORD *)(a3 + 40) != 1LL )
ggml_rope_impl_cold_1();
if ( *(_DWORD *)a3 != 18 )
ggml_rope_impl_cold_2();
if ( *(_QWORD *)(a2 + 32) != *(_QWORD *)(a3 + 16) )
ggml_rope_impl_cold_3();
__asm
{
vmovss [rsp+98h+var_94], xmm0
vmovss [rsp+98h+var_90], xmm1
vmovss [rsp+98h+var_8C], xmm2
vmovss [rsp+98h+var_88], xmm3
vmovss [rsp+98h+var_84], xmm4
vmovss [rsp+98h+var_80], xmm5
vmovss [rsp+98h+var_7C], xmm6
}
v43 = *(_QWORD *)(a2 + 152);
if ( a17 )
v23 = ggml_view_tensor(
a1,
a2,
_XMM0,
_XMM1,
_XMM2,
_XMM3,
*(double *)_XMM4.m128_u64,
*(double *)_XMM5.m128_u64,
_XMM6,
a14);
else
v23 = ggml_new_tensor_impl(a1, *(_DWORD *)a2, 4, (_QWORD *)(a2 + 16), 0LL, 0LL, _XMM0, _XMM1);
v24 = v23;
_RSI = v44;
v44[0] = 0;
v44[1] = a4;
v44[2] = a5;
v44[3] = a6;
v44[4] = a15;
__asm
{
vxorps xmm0, xmm0, xmm0
vmovups ymmword ptr [rsi+14h], ymm0
vmovss xmm0, [rsp+98h+var_94]
vmovss dword ptr [rsi+14h], xmm0
vmovss xmm0, [rsp+98h+var_90]
vmovss dword ptr [rsi+18h], xmm0
vmovss xmm0, [rsp+98h+var_8C]
vmovss dword ptr [rsi+1Ch], xmm0
vmovss xmm0, [rsp+98h+var_88]
vmovss dword ptr [rsi+20h], xmm0
vmovss xmm0, [rsp+98h+var_84]
vmovss dword ptr [rsi+24h], xmm0
vmovss xmm0, [rsp+98h+var_80]
vmovss dword ptr [rsi+28h], xmm0
vmovss xmm0, [rsp+98h+var_7C]
vmovss dword ptr [rsi+2Ch], xmm0
}
v45 = a16;
__asm { vzeroupper }
ggml_set_op_params(v23, (long long)v44, 52LL);
*(_DWORD *)(v24 + 80) = 41;
if ( v43 )
v34 = ggml_new_tensor_impl(a1, *(_DWORD *)v24, 4, (_QWORD *)(v24 + 16), 0LL, 0LL, _XMM0, _XMM1);
else
v34 = 0LL;
*(_QWORD *)(v24 + 152) = v34;
*(_QWORD *)(v24 + 160) = a2;
*(_QWORD *)(v24 + 168) = a3;
return v24;
}
| |||
64,839 |
ggml_rope_impl
|
7CodeWizard[P]stablediffusion/ggml/src/ggml.c
|
static struct ggml_tensor * ggml_rope_impl(
struct ggml_context * ctx,
struct ggml_tensor * a,
struct ggml_tensor * b,
int n_dims,
int mode,
int n_ctx,
int n_orig_ctx,
float freq_base,
float freq_scale,
float ext_factor,
float attn_factor,
float beta_fast,
float beta_slow,
float xpos_base,
bool xpos_down,
bool inplace) {
GGML_ASSERT(ggml_is_vector(b));
GGML_ASSERT(b->type == GGML_TYPE_I32);
GGML_ASSERT(a->ne[2] == b->ne[0]);
bool is_node = false;
if (a->grad) {
is_node = true;
}
struct ggml_tensor * result = inplace ? ggml_view_tensor(ctx, a) : ggml_dup_tensor(ctx, a);
int32_t params[13] = { /*n_past*/ 0, n_dims, mode, n_ctx, n_orig_ctx };
memcpy(params + 5, &freq_base, sizeof(float));
memcpy(params + 6, &freq_scale, sizeof(float));
memcpy(params + 7, &ext_factor, sizeof(float));
memcpy(params + 8, &attn_factor, sizeof(float));
memcpy(params + 9, &beta_fast, sizeof(float));
memcpy(params + 10, &beta_slow, sizeof(float));
memcpy(params + 11, &xpos_base, sizeof(float));
memcpy(params + 12, &xpos_down, sizeof(bool));
ggml_set_op_params(result, params, sizeof(params));
result->op = GGML_OP_ROPE;
result->grad = is_node ? ggml_dup_tensor(ctx, result) : NULL;
result->src[0] = a;
result->src[1] = b;
return result;
}
|
O2
|
c
|
ggml_rope_impl:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
vmovss %xmm6, 0x24(%rsp)
vmovss %xmm5, 0x20(%rsp)
vmovss %xmm4, 0x1c(%rsp)
vmovss %xmm3, 0x18(%rsp)
vmovss %xmm2, 0x14(%rsp)
vmovss %xmm1, 0x10(%rsp)
vmovss %xmm0, 0xc(%rsp)
movl %r9d, %r12d
movl %r8d, %r13d
movl %ecx, %r15d
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, (%rsp)
movq %rdx, %rdi
callq 0x67cf4
testb %al, %al
je 0x6cf7a
cmpl $0x12, (%rbx)
jne 0x6cfaf
movq 0x20(%r14), %rax
cmpq 0x10(%rbx), %rax
jne 0x6cfe4
movl %r12d, %ebp
movq 0x98(%r14), %rax
movq %rax, 0x28(%rsp)
cmpb $0x0, 0xb0(%rsp)
je 0x6ce9d
movq (%rsp), %rdi
movq %r14, %rsi
callq 0x69922
jmp 0x6cea9
movq (%rsp), %rdi
movq %r14, %rsi
callq 0x68a65
movq %rax, %r12
leaq 0x30(%rsp), %rsi
andl $0x0, (%rsi)
movl %r15d, 0x4(%rsi)
movl %r13d, 0x8(%rsi)
movl %ebp, 0xc(%rsi)
movl 0xa0(%rsp), %eax
movl %eax, 0x10(%rsi)
andl $0x0, 0x30(%rsi)
vmovss 0xc(%rsp), %xmm0
vmovss %xmm0, 0x14(%rsi)
vmovss 0x10(%rsp), %xmm0
vmovss %xmm0, 0x18(%rsi)
vmovss 0x14(%rsp), %xmm0
vmovss %xmm0, 0x1c(%rsi)
vmovss 0x18(%rsp), %xmm0
vmovss %xmm0, 0x20(%rsi)
vmovss 0x1c(%rsp), %xmm0
vmovss %xmm0, 0x24(%rsi)
vmovss 0x20(%rsp), %xmm0
vmovss %xmm0, 0x28(%rsi)
vmovss 0x24(%rsp), %xmm0
vmovss %xmm0, 0x2c(%rsi)
movb 0xa8(%rsp), %al
movb %al, 0x30(%rsi)
pushq $0x34
popq %rdx
movq %r12, %rdi
callq 0x6ab3d
movl $0x29, 0x50(%r12)
cmpq $0x0, 0x28(%rsp)
je 0x6cf4e
movq (%rsp), %rdi
movq %r12, %rsi
callq 0x68a65
jmp 0x6cf50
xorl %eax, %eax
movq %rax, 0x98(%r12)
movq %r14, 0xa0(%r12)
movq %rbx, 0xa8(%r12)
movq %r12, %rax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x68fc7(%rip), %rax # 0xd5f48
movq (%rax), %rdi
callq 0xa6f0
movq 0x69018(%rip), %rax # 0xd5fa8
movq (%rax), %rdi
leaq 0x2d284(%rip), %rsi # 0x9a21e
leaq 0x348dd(%rip), %rdx # 0xa187e
leaq 0x34fcf(%rip), %r8 # 0xa1f77
movl $0x139e, %ecx # imm = 0x139E
jmp 0x6d017
movq 0x68f92(%rip), %rax # 0xd5f48
movq (%rax), %rdi
callq 0xa6f0
movq 0x68fe3(%rip), %rax # 0xd5fa8
movq (%rax), %rdi
leaq 0x2d24f(%rip), %rsi # 0x9a21e
leaq 0x348a8(%rip), %rdx # 0xa187e
leaq 0x34f47(%rip), %r8 # 0xa1f24
movl $0x139f, %ecx # imm = 0x139F
jmp 0x6d017
movq 0x68f5d(%rip), %rax # 0xd5f48
movq (%rax), %rdi
callq 0xa6f0
movq 0x68fae(%rip), %rax # 0xd5fa8
movq (%rax), %rdi
leaq 0x2d21a(%rip), %rsi # 0x9a21e
leaq 0x34873(%rip), %rdx # 0xa187e
leaq 0x34f77(%rip), %r8 # 0xa1f89
movl $0x13a0, %ecx # imm = 0x13A0
xorl %eax, %eax
callq 0xa8b0
callq 0x67550
callq 0xa300
|
ggml_rope_impl:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 68h
vmovss [rsp+98h+var_74], xmm6
vmovss [rsp+98h+var_78], xmm5
vmovss [rsp+98h+var_7C], xmm4
vmovss [rsp+98h+var_80], xmm3
vmovss [rsp+98h+var_84], xmm2
vmovss [rsp+98h+var_88], xmm1
vmovss [rsp+98h+var_8C], xmm0
mov r12d, r9d
mov r13d, r8d
mov r15d, ecx
mov rbx, rdx
mov r14, rsi
mov [rsp+98h+var_98], rdi
mov rdi, rdx
call ggml_is_vector
test al, al
jz loc_6CF7A
cmp dword ptr [rbx], 12h
jnz loc_6CFAF
mov rax, [r14+20h]
cmp rax, [rbx+10h]
jnz loc_6CFE4
mov ebp, r12d
mov rax, [r14+98h]
mov [rsp+98h+var_70], rax
cmp [rsp+98h+arg_10], 0
jz short loc_6CE9D
mov rdi, [rsp+98h+var_98]
mov rsi, r14
call ggml_view_tensor
jmp short loc_6CEA9
loc_6CE9D:
mov rdi, [rsp+98h+var_98]
mov rsi, r14
call ggml_dup_tensor
loc_6CEA9:
mov r12, rax
lea rsi, [rsp+98h+var_68]
and dword ptr [rsi], 0
mov [rsi+4], r15d
mov [rsi+8], r13d
mov [rsi+0Ch], ebp
mov eax, [rsp+98h+arg_0]
mov [rsi+10h], eax
and dword ptr [rsi+30h], 0
vmovss xmm0, [rsp+98h+var_8C]
vmovss dword ptr [rsi+14h], xmm0
vmovss xmm0, [rsp+98h+var_88]
vmovss dword ptr [rsi+18h], xmm0
vmovss xmm0, [rsp+98h+var_84]
vmovss dword ptr [rsi+1Ch], xmm0
vmovss xmm0, [rsp+98h+var_80]
vmovss dword ptr [rsi+20h], xmm0
vmovss xmm0, [rsp+98h+var_7C]
vmovss dword ptr [rsi+24h], xmm0
vmovss xmm0, [rsp+98h+var_78]
vmovss dword ptr [rsi+28h], xmm0
vmovss xmm0, [rsp+98h+var_74]
vmovss dword ptr [rsi+2Ch], xmm0
mov al, [rsp+98h+arg_8]
mov [rsi+30h], al
push 34h ; '4'
pop rdx
mov rdi, r12
call ggml_set_op_params
mov dword ptr [r12+50h], 29h ; ')'
cmp [rsp+98h+var_70], 0
jz short loc_6CF4E
mov rdi, [rsp+98h+var_98]
mov rsi, r12
call ggml_dup_tensor
jmp short loc_6CF50
loc_6CF4E:
xor eax, eax
loc_6CF50:
mov [r12+98h], rax
mov [r12+0A0h], r14
mov [r12+0A8h], rbx
mov rax, r12
add rsp, 68h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_6CF7A:
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_7; "/workspace/llm4binary/github/2025_star3"...
lea r8, aGgmlIsVectorB; "ggml_is_vector(b)"
mov ecx, 139Eh
jmp short loc_6D017
loc_6CFAF:
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_7; "/workspace/llm4binary/github/2025_star3"...
lea r8, aGgmlIsMatrixAG+2Ah; "b->type == GGML_TYPE_I32"
mov ecx, 139Fh
jmp short loc_6D017
loc_6CFE4:
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_7; "/workspace/llm4binary/github/2025_star3"...
lea r8, aANe2BNe0; "a->ne[2] == b->ne[0]"
mov ecx, 13A0h
loc_6D017:
xor eax, eax
call _fprintf
call ggml_print_backtrace
call _abort
|
long long ggml_rope_impl(
long long a1,
long long a2,
_QWORD *a3,
int a4,
int a5,
int a6,
__m128 _XMM0,
__m128 _XMM1,
__m128 _XMM2,
__m128 _XMM3,
__m128 _XMM4,
__m128 _XMM5,
__m128 _XMM6,
__m128 a14,
int a15,
char a16,
char a17)
{
double v22; // xmm4_8
double v23; // xmm5_8
int v24; // ebp
long long v25; // rax
long long v26; // r12
long long v35; // rax
long long v37; // rdi
long long v45; // [rsp+28h] [rbp-70h]
_DWORD v46[12]; // [rsp+30h] [rbp-68h] BYREF
int v47; // [rsp+60h] [rbp-38h]
__asm
{
vmovss [rsp+98h+var_74], xmm6
vmovss [rsp+98h+var_78], xmm5
vmovss [rsp+98h+var_7C], xmm4
vmovss [rsp+98h+var_80], xmm3
vmovss [rsp+98h+var_84], xmm2
vmovss [rsp+98h+var_88], xmm1
vmovss [rsp+98h+var_8C], xmm0
}
if ( !ggml_is_vector(a3) )
{
fflush(stdout);
v37 = stderr;
fprintf(
stderr,
"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml/src/ggml.c",
5022LL,
"ggml_is_vector(b)");
goto LABEL_14;
}
if ( *(_DWORD *)a3 != 18 )
{
fflush(stdout);
v37 = stderr;
fprintf(
stderr,
"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml/src/ggml.c",
5023LL,
"b->type == GGML_TYPE_I32");
goto LABEL_14;
}
if ( *(_QWORD *)(a2 + 32) != a3[2] )
{
fflush(stdout);
v37 = stderr;
fprintf(
stderr,
"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml/src/ggml.c",
5024LL,
"a->ne[2] == b->ne[0]");
LABEL_14:
ggml_print_backtrace();
abort(v37);
}
v24 = a6;
v45 = *(_QWORD *)(a2 + 152);
if ( a17 )
v25 = ggml_view_tensor(a1, a2, _XMM0, _XMM1, _XMM2, _XMM3, v22, v23, _XMM6, a14);
else
v25 = ggml_dup_tensor(a1, (unsigned int *)a2);
v26 = v25;
_RSI = v46;
v46[0] = 0;
v46[1] = a4;
v46[2] = a5;
v46[3] = v24;
v46[4] = a15;
v47 = 0;
__asm
{
vmovss xmm0, [rsp+98h+var_8C]
vmovss dword ptr [rsi+14h], xmm0
vmovss xmm0, [rsp+98h+var_88]
vmovss dword ptr [rsi+18h], xmm0
vmovss xmm0, [rsp+98h+var_84]
vmovss dword ptr [rsi+1Ch], xmm0
vmovss xmm0, [rsp+98h+var_80]
vmovss dword ptr [rsi+20h], xmm0
vmovss xmm0, [rsp+98h+var_7C]
vmovss dword ptr [rsi+24h], xmm0
vmovss xmm0, [rsp+98h+var_78]
vmovss dword ptr [rsi+28h], xmm0
vmovss xmm0, [rsp+98h+var_74]
vmovss dword ptr [rsi+2Ch], xmm0
}
LOBYTE(v47) = a16;
ggml_set_op_params(v25, (long long)v46, 52LL);
*(_DWORD *)(v26 + 80) = 41;
if ( v45 )
v35 = ggml_dup_tensor(a1, (unsigned int *)v26);
else
v35 = 0LL;
*(_QWORD *)(v26 + 152) = v35;
*(_QWORD *)(v26 + 160) = a2;
*(_QWORD *)(v26 + 168) = a3;
return v26;
}
|
ggml_rope_impl:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x68
VMOVSS dword ptr [RSP + 0x24],XMM6
VMOVSS dword ptr [RSP + 0x20],XMM5
VMOVSS dword ptr [RSP + 0x1c],XMM4
VMOVSS dword ptr [RSP + 0x18],XMM3
VMOVSS dword ptr [RSP + 0x14],XMM2
VMOVSS dword ptr [RSP + 0x10],XMM1
VMOVSS dword ptr [RSP + 0xc],XMM0
MOV R12D,R9D
MOV R13D,R8D
MOV R15D,ECX
MOV RBX,RDX
MOV R14,RSI
MOV qword ptr [RSP],RDI
MOV RDI,RDX
CALL 0x00167cf4
TEST AL,AL
JZ 0x0016cf7a
CMP dword ptr [RBX],0x12
JNZ 0x0016cfaf
MOV RAX,qword ptr [R14 + 0x20]
CMP RAX,qword ptr [RBX + 0x10]
JNZ 0x0016cfe4
MOV EBP,R12D
MOV RAX,qword ptr [R14 + 0x98]
MOV qword ptr [RSP + 0x28],RAX
CMP byte ptr [RSP + 0xb0],0x0
JZ 0x0016ce9d
MOV RDI,qword ptr [RSP]
MOV RSI,R14
CALL 0x00169922
JMP 0x0016cea9
LAB_0016ce9d:
MOV RDI,qword ptr [RSP]
MOV RSI,R14
CALL 0x00168a65
LAB_0016cea9:
MOV R12,RAX
LEA RSI,[RSP + 0x30]
AND dword ptr [RSI],0x0
MOV dword ptr [RSI + 0x4],R15D
MOV dword ptr [RSI + 0x8],R13D
MOV dword ptr [RSI + 0xc],EBP
MOV EAX,dword ptr [RSP + 0xa0]
MOV dword ptr [RSI + 0x10],EAX
AND dword ptr [RSI + 0x30],0x0
VMOVSS XMM0,dword ptr [RSP + 0xc]
VMOVSS dword ptr [RSI + 0x14],XMM0
VMOVSS XMM0,dword ptr [RSP + 0x10]
VMOVSS dword ptr [RSI + 0x18],XMM0
VMOVSS XMM0,dword ptr [RSP + 0x14]
VMOVSS dword ptr [RSI + 0x1c],XMM0
VMOVSS XMM0,dword ptr [RSP + 0x18]
VMOVSS dword ptr [RSI + 0x20],XMM0
VMOVSS XMM0,dword ptr [RSP + 0x1c]
VMOVSS dword ptr [RSI + 0x24],XMM0
VMOVSS XMM0,dword ptr [RSP + 0x20]
VMOVSS dword ptr [RSI + 0x28],XMM0
VMOVSS XMM0,dword ptr [RSP + 0x24]
VMOVSS dword ptr [RSI + 0x2c],XMM0
MOV AL,byte ptr [RSP + 0xa8]
MOV byte ptr [RSI + 0x30],AL
PUSH 0x34
POP RDX
MOV RDI,R12
CALL 0x0016ab3d
MOV dword ptr [R12 + 0x50],0x29
CMP qword ptr [RSP + 0x28],0x0
JZ 0x0016cf4e
MOV RDI,qword ptr [RSP]
MOV RSI,R12
CALL 0x00168a65
JMP 0x0016cf50
LAB_0016cf4e:
XOR EAX,EAX
LAB_0016cf50:
MOV qword ptr [R12 + 0x98],RAX
MOV qword ptr [R12 + 0xa0],R14
MOV qword ptr [R12 + 0xa8],RBX
MOV RAX,R12
ADD RSP,0x68
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0016cf7a:
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,[0x1a187e]
LEA R8,[0x1a1f77]
MOV ECX,0x139e
JMP 0x0016d017
LAB_0016cfaf:
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,[0x1a187e]
LEA R8,[0x1a1f24]
MOV ECX,0x139f
JMP 0x0016d017
LAB_0016cfe4:
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,[0x1a187e]
LEA R8,[0x1a1f89]
MOV ECX,0x13a0
LAB_0016d017:
XOR EAX,EAX
CALL 0x0010a8b0
CALL 0x00167550
CALL 0x0010a300
|
long ggml_rope_impl(int4 param_1,int4 param_2,int4 param_3,int4 param_4,
int4 param_5,int4 param_6,int4 param_7,int8 param_8,
long param_9,int *param_10,int4 param_11,int4 param_12,
int4 param_13,int4 param_14,byte param_15,char param_16)
{
long lVar1;
char cVar2;
long lVar3;
int8 uVar4;
FILE *__stream;
char *pcVar5;
int4 local_68;
int4 local_64;
int4 local_60;
int4 local_5c;
int4 local_58;
int4 local_54;
int4 local_50;
int4 local_4c;
int4 local_48;
int4 local_44;
int4 local_40;
int4 local_3c;
uint local_38;
cVar2 = ggml_is_vector(param_10);
if (cVar2 == '\0') {
fflush(*(FILE **)PTR_stdout_001d5f48);
__stream = *(FILE **)PTR_stderr_001d5fa8;
pcVar5 = "ggml_is_vector(b)";
uVar4 = 0x139e;
}
else if (*param_10 == 0x12) {
if (*(long *)(param_9 + 0x20) == *(long *)(param_10 + 4)) {
lVar1 = *(long *)(param_9 + 0x98);
if (param_16 == '\0') {
lVar3 = ggml_dup_tensor(param_8,param_9);
}
else {
lVar3 = ggml_view_tensor(param_8,param_9);
}
local_68 = 0;
local_58 = param_14;
local_38 = (uint)param_15;
local_64 = param_11;
local_60 = param_12;
local_5c = param_13;
local_54 = param_1;
local_50 = param_2;
local_4c = param_3;
local_48 = param_4;
local_44 = param_5;
local_40 = param_6;
local_3c = param_7;
ggml_set_op_params(lVar3,&local_68,0x34);
*(int4 *)(lVar3 + 0x50) = 0x29;
if (lVar1 == 0) {
uVar4 = 0;
}
else {
uVar4 = ggml_dup_tensor(param_8,lVar3);
}
*(int8 *)(lVar3 + 0x98) = uVar4;
*(long *)(lVar3 + 0xa0) = param_9;
*(int **)(lVar3 + 0xa8) = param_10;
return lVar3;
}
fflush(*(FILE **)PTR_stdout_001d5f48);
__stream = *(FILE **)PTR_stderr_001d5fa8;
pcVar5 = "a->ne[2] == b->ne[0]";
uVar4 = 0x13a0;
}
else {
fflush(*(FILE **)PTR_stdout_001d5f48);
__stream = *(FILE **)PTR_stderr_001d5fa8;
pcVar5 = "b->type == GGML_TYPE_I32";
uVar4 = 0x139f;
}
fprintf(__stream,"GGML_ASSERT: %s:%d: %s\n",
"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml/src/ggml.c",
uVar4,pcVar5);
ggml_print_backtrace();
/* WARNING: Subroutine does not return */
abort();
}
|
|
64,840 |
my_strntoull_8bit
|
eloqsql/strings/ctype-simple.c
|
ulonglong my_strntoull_8bit(CHARSET_INFO *cs,
const char *nptr, size_t l, int base,
char **endptr, int *err)
{
int negative;
register ulonglong cutoff;
register uint cutlim;
register ulonglong i;
register const char *s, *e;
const char *save;
int overflow;
*err= 0; /* Initialize error indicator */
s = nptr;
e = nptr+l;
for(; s<e && my_isspace(cs,*s); s++);
if (s == e)
{
goto noconv;
}
if (*s == '-')
{
negative = 1;
++s;
}
else if (*s == '+')
{
negative = 0;
++s;
}
else
negative = 0;
save = s;
cutoff = (~(ulonglong) 0) / (unsigned long int) base;
cutlim = (uint) ((~(ulonglong) 0) % (unsigned long int) base);
overflow = 0;
i = 0;
for ( ; s != e; s++)
{
register uchar c= *s;
if (c>='0' && c<='9')
c -= '0';
else if (c>='A' && c<='Z')
c = c - 'A' + 10;
else if (c>='a' && c<='z')
c = c - 'a' + 10;
else
break;
if (c >= base)
break;
if (i > cutoff || (i == cutoff && c > cutlim))
overflow = 1;
else
{
i *= (ulonglong) base;
i += c;
}
}
if (s == save)
goto noconv;
if (endptr != NULL)
*endptr = (char *) s;
if (overflow)
{
err[0]= ERANGE;
return (~(ulonglong) 0);
}
return (negative ? -((longlong) i) : (longlong) i);
noconv:
err[0]= EDOM;
if (endptr != NULL)
*endptr = (char *) nptr;
return 0L;
}
|
O0
|
c
|
my_strntoull_8bit:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl %ecx, -0x24(%rbp)
movq %r8, -0x30(%rbp)
movq %r9, -0x38(%rbp)
movq -0x38(%rbp), %rax
movl $0x0, (%rax)
movq -0x18(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x18(%rbp), %rax
addq -0x20(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x60(%rbp), %rcx
xorl %eax, %eax
cmpq -0x68(%rbp), %rcx
movb %al, -0x76(%rbp)
jae 0x46368
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rax
movq -0x60(%rbp), %rcx
movzbl (%rcx), %ecx
movzbl 0x1(%rax,%rcx), %eax
andl $0x8, %eax
cmpl $0x0, %eax
setne %al
movb %al, -0x76(%rbp)
movb -0x76(%rbp), %al
testb $0x1, %al
jne 0x46371
jmp 0x46381
jmp 0x46373
movq -0x60(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x60(%rbp)
jmp 0x46339
movq -0x60(%rbp), %rax
cmpq -0x68(%rbp), %rax
jne 0x46390
jmp 0x46551
movq -0x60(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2d, %eax
jne 0x463b1
movl $0x1, -0x3c(%rbp)
movq -0x60(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x60(%rbp)
jmp 0x463db
movq -0x60(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2b, %eax
jne 0x463d2
movl $0x0, -0x3c(%rbp)
movq -0x60(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x60(%rbp)
jmp 0x463d9
movl $0x0, -0x3c(%rbp)
jmp 0x463db
movq -0x60(%rbp), %rax
movq %rax, -0x70(%rbp)
movslq -0x24(%rbp), %rcx
movq $-0x1, %rax
xorl %edx, %edx
divq %rcx
movq %rax, -0x48(%rbp)
movslq -0x24(%rbp), %rcx
movq $-0x1, %rax
xorl %edx, %edx
divq %rcx
movl %edx, %eax
movl %eax, -0x4c(%rbp)
movl $0x0, -0x74(%rbp)
movq $0x0, -0x58(%rbp)
movq -0x60(%rbp), %rax
cmpq -0x68(%rbp), %rax
je 0x464f5
movq -0x60(%rbp), %rax
movb (%rax), %al
movb %al, -0x75(%rbp)
movzbl -0x75(%rbp), %eax
cmpl $0x30, %eax
jl 0x46450
movzbl -0x75(%rbp), %eax
cmpl $0x39, %eax
jg 0x46450
movzbl -0x75(%rbp), %eax
subl $0x30, %eax
movb %al, -0x75(%rbp)
jmp 0x46498
movzbl -0x75(%rbp), %eax
cmpl $0x41, %eax
jl 0x46471
movzbl -0x75(%rbp), %eax
cmpl $0x5a, %eax
jg 0x46471
movzbl -0x75(%rbp), %eax
subl $0x41, %eax
addl $0xa, %eax
movb %al, -0x75(%rbp)
jmp 0x46496
movzbl -0x75(%rbp), %eax
cmpl $0x61, %eax
jl 0x46492
movzbl -0x75(%rbp), %eax
cmpl $0x7a, %eax
jg 0x46492
movzbl -0x75(%rbp), %eax
subl $0x61, %eax
addl $0xa, %eax
movb %al, -0x75(%rbp)
jmp 0x46494
jmp 0x464f5
jmp 0x46496
jmp 0x46498
movzbl -0x75(%rbp), %eax
cmpl -0x24(%rbp), %eax
jl 0x464a3
jmp 0x464f5
movq -0x58(%rbp), %rax
cmpq -0x48(%rbp), %rax
ja 0x464c0
movq -0x58(%rbp), %rax
cmpq -0x48(%rbp), %rax
jne 0x464c9
movzbl -0x75(%rbp), %eax
cmpl -0x4c(%rbp), %eax
jbe 0x464c9
movl $0x1, -0x74(%rbp)
jmp 0x464e2
movslq -0x24(%rbp), %rax
imulq -0x58(%rbp), %rax
movq %rax, -0x58(%rbp)
movzbl -0x75(%rbp), %eax
addq -0x58(%rbp), %rax
movq %rax, -0x58(%rbp)
jmp 0x464e4
movq -0x60(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x60(%rbp)
jmp 0x4641b
movq -0x60(%rbp), %rax
cmpq -0x70(%rbp), %rax
jne 0x46501
jmp 0x46551
cmpq $0x0, -0x30(%rbp)
je 0x46513
movq -0x60(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
cmpl $0x0, -0x74(%rbp)
je 0x4652d
movq -0x38(%rbp), %rax
movl $0x22, (%rax)
movq $-0x1, -0x8(%rbp)
jmp 0x46575
cmpl $0x0, -0x3c(%rbp)
je 0x4653f
xorl %eax, %eax
subq -0x58(%rbp), %rax
movq %rax, -0x80(%rbp)
jmp 0x46547
movq -0x58(%rbp), %rax
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x46575
movq -0x38(%rbp), %rax
movl $0x21, (%rax)
cmpq $0x0, -0x30(%rbp)
je 0x4656d
movq -0x18(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
popq %rbp
retq
nopl (%rax,%rax)
|
my_strntoull_8bit:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_24], ecx
mov [rbp+var_30], r8
mov [rbp+var_38], r9
mov rax, [rbp+var_38]
mov dword ptr [rax], 0
mov rax, [rbp+var_18]
mov [rbp+var_60], rax
mov rax, [rbp+var_18]
add rax, [rbp+var_20]
mov [rbp+var_68], rax
loc_46339:
mov rcx, [rbp+var_60]
xor eax, eax
cmp rcx, [rbp+var_68]
mov [rbp+var_76], al
jnb short loc_46368
mov rax, [rbp+var_10]
mov rax, [rax+40h]
mov rcx, [rbp+var_60]
movzx ecx, byte ptr [rcx]
movzx eax, byte ptr [rax+rcx+1]
and eax, 8
cmp eax, 0
setnz al
mov [rbp+var_76], al
loc_46368:
mov al, [rbp+var_76]
test al, 1
jnz short loc_46371
jmp short loc_46381
loc_46371:
jmp short $+2
loc_46373:
mov rax, [rbp+var_60]
add rax, 1
mov [rbp+var_60], rax
jmp short loc_46339
loc_46381:
mov rax, [rbp+var_60]
cmp rax, [rbp+var_68]
jnz short loc_46390
jmp loc_46551
loc_46390:
mov rax, [rbp+var_60]
movsx eax, byte ptr [rax]
cmp eax, 2Dh ; '-'
jnz short loc_463B1
mov [rbp+var_3C], 1
mov rax, [rbp+var_60]
add rax, 1
mov [rbp+var_60], rax
jmp short loc_463DB
loc_463B1:
mov rax, [rbp+var_60]
movsx eax, byte ptr [rax]
cmp eax, 2Bh ; '+'
jnz short loc_463D2
mov [rbp+var_3C], 0
mov rax, [rbp+var_60]
add rax, 1
mov [rbp+var_60], rax
jmp short loc_463D9
loc_463D2:
mov [rbp+var_3C], 0
loc_463D9:
jmp short $+2
loc_463DB:
mov rax, [rbp+var_60]
mov [rbp+var_70], rax
movsxd rcx, [rbp+var_24]
mov rax, 0FFFFFFFFFFFFFFFFh
xor edx, edx
div rcx
mov [rbp+var_48], rax
movsxd rcx, [rbp+var_24]
mov rax, 0FFFFFFFFFFFFFFFFh
xor edx, edx
div rcx
mov eax, edx
mov [rbp+var_4C], eax
mov [rbp+var_74], 0
mov [rbp+var_58], 0
loc_4641B:
mov rax, [rbp+var_60]
cmp rax, [rbp+var_68]
jz loc_464F5
mov rax, [rbp+var_60]
mov al, [rax]
mov [rbp+var_75], al
movzx eax, [rbp+var_75]
cmp eax, 30h ; '0'
jl short loc_46450
movzx eax, [rbp+var_75]
cmp eax, 39h ; '9'
jg short loc_46450
movzx eax, [rbp+var_75]
sub eax, 30h ; '0'
mov [rbp+var_75], al
jmp short loc_46498
loc_46450:
movzx eax, [rbp+var_75]
cmp eax, 41h ; 'A'
jl short loc_46471
movzx eax, [rbp+var_75]
cmp eax, 5Ah ; 'Z'
jg short loc_46471
movzx eax, [rbp+var_75]
sub eax, 41h ; 'A'
add eax, 0Ah
mov [rbp+var_75], al
jmp short loc_46496
loc_46471:
movzx eax, [rbp+var_75]
cmp eax, 61h ; 'a'
jl short loc_46492
movzx eax, [rbp+var_75]
cmp eax, 7Ah ; 'z'
jg short loc_46492
movzx eax, [rbp+var_75]
sub eax, 61h ; 'a'
add eax, 0Ah
mov [rbp+var_75], al
jmp short loc_46494
loc_46492:
jmp short loc_464F5
loc_46494:
jmp short $+2
loc_46496:
jmp short $+2
loc_46498:
movzx eax, [rbp+var_75]
cmp eax, [rbp+var_24]
jl short loc_464A3
jmp short loc_464F5
loc_464A3:
mov rax, [rbp+var_58]
cmp rax, [rbp+var_48]
ja short loc_464C0
mov rax, [rbp+var_58]
cmp rax, [rbp+var_48]
jnz short loc_464C9
movzx eax, [rbp+var_75]
cmp eax, [rbp+var_4C]
jbe short loc_464C9
loc_464C0:
mov [rbp+var_74], 1
jmp short loc_464E2
loc_464C9:
movsxd rax, [rbp+var_24]
imul rax, [rbp+var_58]
mov [rbp+var_58], rax
movzx eax, [rbp+var_75]
add rax, [rbp+var_58]
mov [rbp+var_58], rax
loc_464E2:
jmp short $+2
loc_464E4:
mov rax, [rbp+var_60]
add rax, 1
mov [rbp+var_60], rax
jmp loc_4641B
loc_464F5:
mov rax, [rbp+var_60]
cmp rax, [rbp+var_70]
jnz short loc_46501
jmp short loc_46551
loc_46501:
cmp [rbp+var_30], 0
jz short loc_46513
mov rcx, [rbp+var_60]
mov rax, [rbp+var_30]
mov [rax], rcx
loc_46513:
cmp [rbp+var_74], 0
jz short loc_4652D
mov rax, [rbp+var_38]
mov dword ptr [rax], 22h ; '"'
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp short loc_46575
loc_4652D:
cmp [rbp+var_3C], 0
jz short loc_4653F
xor eax, eax
sub rax, [rbp+var_58]
mov [rbp+var_80], rax
jmp short loc_46547
loc_4653F:
mov rax, [rbp+var_58]
mov [rbp+var_80], rax
loc_46547:
mov rax, [rbp+var_80]
mov [rbp+var_8], rax
jmp short loc_46575
loc_46551:
mov rax, [rbp+var_38]
mov dword ptr [rax], 21h ; '!'
cmp [rbp+var_30], 0
jz short loc_4656D
mov rcx, [rbp+var_18]
mov rax, [rbp+var_30]
mov [rax], rcx
loc_4656D:
mov [rbp+var_8], 0
loc_46575:
mov rax, [rbp+var_8]
pop rbp
retn
|
long long my_strntoull_8bit(long long a1, _BYTE *a2, long long a3, int a4, _QWORD *a5, _DWORD *a6)
{
bool v8; // [rsp+Ah] [rbp-76h]
unsigned __int8 v9; // [rsp+Bh] [rbp-75h]
unsigned __int8 v10; // [rsp+Bh] [rbp-75h]
int v11; // [rsp+Ch] [rbp-74h]
_BYTE *v12; // [rsp+10h] [rbp-70h]
_BYTE *v13; // [rsp+18h] [rbp-68h]
_BYTE *v14; // [rsp+20h] [rbp-60h]
unsigned long long v15; // [rsp+28h] [rbp-58h]
unsigned long long v16; // [rsp+38h] [rbp-48h]
int v17; // [rsp+44h] [rbp-3Ch]
*a6 = 0;
v14 = a2;
v13 = &a2[a3];
while ( 1 )
{
v8 = 0;
if ( v14 < v13 )
v8 = (*(_BYTE *)(*(_QWORD *)(a1 + 64) + (unsigned __int8)*v14 + 1LL) & 8) != 0;
if ( !v8 )
break;
++v14;
}
if ( v14 == v13 )
goto LABEL_39;
if ( *v14 == 45 )
{
v17 = 1;
++v14;
}
else
{
v17 = 0;
if ( *v14 == 43 )
++v14;
}
v12 = v14;
v16 = 0xFFFFFFFFFFFFFFFFLL / a4;
v11 = 0;
v15 = 0LL;
while ( v14 != v13 )
{
v9 = *v14;
if ( (unsigned __int8)*v14 < 0x30u || v9 > 0x39u )
{
if ( v9 < 0x41u || v9 > 0x5Au )
{
if ( v9 < 0x61u || v9 > 0x7Au )
break;
v10 = v9 - 97 + 10;
}
else
{
v10 = v9 - 65 + 10;
}
}
else
{
v10 = v9 - 48;
}
if ( v10 >= a4 )
break;
if ( v15 > v16 || v15 == v16 && v10 > (unsigned int)(0xFFFFFFFFFFFFFFFFLL % a4) )
v11 = 1;
else
v15 = v15 * a4 + v10;
++v14;
}
if ( v14 == v12 )
{
LABEL_39:
*a6 = 33;
if ( a5 )
*a5 = a2;
return 0LL;
}
else
{
if ( a5 )
*a5 = v14;
if ( v11 )
{
*a6 = 34;
return -1LL;
}
else if ( v17 )
{
return -(long long)v15;
}
else
{
return v15;
}
}
}
|
my_strntoull_8bit:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x24],ECX
MOV qword ptr [RBP + -0x30],R8
MOV qword ptr [RBP + -0x38],R9
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x0
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x68],RAX
LAB_00146339:
MOV RCX,qword ptr [RBP + -0x60]
XOR EAX,EAX
CMP RCX,qword ptr [RBP + -0x68]
MOV byte ptr [RBP + -0x76],AL
JNC 0x00146368
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x40]
MOV RCX,qword ptr [RBP + -0x60]
MOVZX ECX,byte ptr [RCX]
MOVZX EAX,byte ptr [RAX + RCX*0x1 + 0x1]
AND EAX,0x8
CMP EAX,0x0
SETNZ AL
MOV byte ptr [RBP + -0x76],AL
LAB_00146368:
MOV AL,byte ptr [RBP + -0x76]
TEST AL,0x1
JNZ 0x00146371
JMP 0x00146381
LAB_00146371:
JMP 0x00146373
LAB_00146373:
MOV RAX,qword ptr [RBP + -0x60]
ADD RAX,0x1
MOV qword ptr [RBP + -0x60],RAX
JMP 0x00146339
LAB_00146381:
MOV RAX,qword ptr [RBP + -0x60]
CMP RAX,qword ptr [RBP + -0x68]
JNZ 0x00146390
JMP 0x00146551
LAB_00146390:
MOV RAX,qword ptr [RBP + -0x60]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x2d
JNZ 0x001463b1
MOV dword ptr [RBP + -0x3c],0x1
MOV RAX,qword ptr [RBP + -0x60]
ADD RAX,0x1
MOV qword ptr [RBP + -0x60],RAX
JMP 0x001463db
LAB_001463b1:
MOV RAX,qword ptr [RBP + -0x60]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x2b
JNZ 0x001463d2
MOV dword ptr [RBP + -0x3c],0x0
MOV RAX,qword ptr [RBP + -0x60]
ADD RAX,0x1
MOV qword ptr [RBP + -0x60],RAX
JMP 0x001463d9
LAB_001463d2:
MOV dword ptr [RBP + -0x3c],0x0
LAB_001463d9:
JMP 0x001463db
LAB_001463db:
MOV RAX,qword ptr [RBP + -0x60]
MOV qword ptr [RBP + -0x70],RAX
MOVSXD RCX,dword ptr [RBP + -0x24]
MOV RAX,-0x1
XOR EDX,EDX
DIV RCX
MOV qword ptr [RBP + -0x48],RAX
MOVSXD RCX,dword ptr [RBP + -0x24]
MOV RAX,-0x1
XOR EDX,EDX
DIV RCX
MOV EAX,EDX
MOV dword ptr [RBP + -0x4c],EAX
MOV dword ptr [RBP + -0x74],0x0
MOV qword ptr [RBP + -0x58],0x0
LAB_0014641b:
MOV RAX,qword ptr [RBP + -0x60]
CMP RAX,qword ptr [RBP + -0x68]
JZ 0x001464f5
MOV RAX,qword ptr [RBP + -0x60]
MOV AL,byte ptr [RAX]
MOV byte ptr [RBP + -0x75],AL
MOVZX EAX,byte ptr [RBP + -0x75]
CMP EAX,0x30
JL 0x00146450
MOVZX EAX,byte ptr [RBP + -0x75]
CMP EAX,0x39
JG 0x00146450
MOVZX EAX,byte ptr [RBP + -0x75]
SUB EAX,0x30
MOV byte ptr [RBP + -0x75],AL
JMP 0x00146498
LAB_00146450:
MOVZX EAX,byte ptr [RBP + -0x75]
CMP EAX,0x41
JL 0x00146471
MOVZX EAX,byte ptr [RBP + -0x75]
CMP EAX,0x5a
JG 0x00146471
MOVZX EAX,byte ptr [RBP + -0x75]
SUB EAX,0x41
ADD EAX,0xa
MOV byte ptr [RBP + -0x75],AL
JMP 0x00146496
LAB_00146471:
MOVZX EAX,byte ptr [RBP + -0x75]
CMP EAX,0x61
JL 0x00146492
MOVZX EAX,byte ptr [RBP + -0x75]
CMP EAX,0x7a
JG 0x00146492
MOVZX EAX,byte ptr [RBP + -0x75]
SUB EAX,0x61
ADD EAX,0xa
MOV byte ptr [RBP + -0x75],AL
JMP 0x00146494
LAB_00146492:
JMP 0x001464f5
LAB_00146494:
JMP 0x00146496
LAB_00146496:
JMP 0x00146498
LAB_00146498:
MOVZX EAX,byte ptr [RBP + -0x75]
CMP EAX,dword ptr [RBP + -0x24]
JL 0x001464a3
JMP 0x001464f5
LAB_001464a3:
MOV RAX,qword ptr [RBP + -0x58]
CMP RAX,qword ptr [RBP + -0x48]
JA 0x001464c0
MOV RAX,qword ptr [RBP + -0x58]
CMP RAX,qword ptr [RBP + -0x48]
JNZ 0x001464c9
MOVZX EAX,byte ptr [RBP + -0x75]
CMP EAX,dword ptr [RBP + -0x4c]
JBE 0x001464c9
LAB_001464c0:
MOV dword ptr [RBP + -0x74],0x1
JMP 0x001464e2
LAB_001464c9:
MOVSXD RAX,dword ptr [RBP + -0x24]
IMUL RAX,qword ptr [RBP + -0x58]
MOV qword ptr [RBP + -0x58],RAX
MOVZX EAX,byte ptr [RBP + -0x75]
ADD RAX,qword ptr [RBP + -0x58]
MOV qword ptr [RBP + -0x58],RAX
LAB_001464e2:
JMP 0x001464e4
LAB_001464e4:
MOV RAX,qword ptr [RBP + -0x60]
ADD RAX,0x1
MOV qword ptr [RBP + -0x60],RAX
JMP 0x0014641b
LAB_001464f5:
MOV RAX,qword ptr [RBP + -0x60]
CMP RAX,qword ptr [RBP + -0x70]
JNZ 0x00146501
JMP 0x00146551
LAB_00146501:
CMP qword ptr [RBP + -0x30],0x0
JZ 0x00146513
MOV RCX,qword ptr [RBP + -0x60]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
LAB_00146513:
CMP dword ptr [RBP + -0x74],0x0
JZ 0x0014652d
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x22
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00146575
LAB_0014652d:
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x0014653f
XOR EAX,EAX
SUB RAX,qword ptr [RBP + -0x58]
MOV qword ptr [RBP + -0x80],RAX
JMP 0x00146547
LAB_0014653f:
MOV RAX,qword ptr [RBP + -0x58]
MOV qword ptr [RBP + -0x80],RAX
LAB_00146547:
MOV RAX,qword ptr [RBP + -0x80]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x00146575
LAB_00146551:
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x21
CMP qword ptr [RBP + -0x30],0x0
JZ 0x0014656d
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
LAB_0014656d:
MOV qword ptr [RBP + -0x8],0x0
LAB_00146575:
MOV RAX,qword ptr [RBP + -0x8]
POP RBP
RET
|
ulong my_strntoull_8bit(long param_1,byte *param_2,long param_3,int param_4,int8 *param_5,
int4 *param_6)
{
int1 auVar1 [16];
int1 auVar2 [16];
bool bVar3;
byte *pbVar4;
byte *pbVar5;
ulong uVar6;
bool bVar7;
ulong local_88;
byte local_7d;
byte *local_68;
ulong local_60;
*param_6 = 0;
pbVar5 = param_2 + param_3;
local_68 = param_2;
while( true ) {
bVar7 = false;
if (local_68 < pbVar5) {
bVar7 = (*(byte *)(*(long *)(param_1 + 0x40) + 1 + (ulong)*local_68) & 8) != 0;
}
if (!bVar7) break;
local_68 = local_68 + 1;
}
if (local_68 != pbVar5) {
if (*local_68 == 0x2d) {
bVar7 = true;
local_68 = local_68 + 1;
}
else {
if (*local_68 == 0x2b) {
local_68 = local_68 + 1;
}
bVar7 = false;
}
pbVar4 = local_68;
auVar1._8_8_ = 0;
auVar1._0_8_ = (long)param_4;
uVar6 = SUB168((ZEXT816(0) << 0x40 | ZEXT816(0xffffffffffffffff)) / auVar1,0);
auVar2._8_8_ = 0;
auVar2._0_8_ = (long)param_4;
bVar3 = false;
local_60 = 0;
for (; local_68 != pbVar5; local_68 = local_68 + 1) {
local_7d = *local_68;
if ((local_7d < 0x30) || (0x39 < local_7d)) {
if ((local_7d < 0x41) || (0x5a < local_7d)) {
if ((local_7d < 0x61) || (0x7a < local_7d)) break;
local_7d = local_7d + 0xa9;
}
else {
local_7d = local_7d - 0x37;
}
}
else {
local_7d = local_7d - 0x30;
}
if (param_4 <= (int)(uint)local_7d) break;
if ((uVar6 < local_60) ||
((local_60 == uVar6 &&
(SUB164((ZEXT816(0) << 0x40 | ZEXT816(0xffffffffffffffff)) % auVar2,0) < (uint)local_7d)))
) {
bVar3 = true;
}
else {
local_60 = (ulong)local_7d + (long)param_4 * local_60;
}
}
if (local_68 != pbVar4) {
if (param_5 != (int8 *)0x0) {
*param_5 = local_68;
}
if (bVar3) {
*param_6 = 0x22;
return 0xffffffffffffffff;
}
if (bVar7) {
local_88 = -local_60;
}
else {
local_88 = local_60;
}
return local_88;
}
}
*param_6 = 0x21;
if (param_5 != (int8 *)0x0) {
*param_5 = param_2;
}
return 0;
}
|
|
64,841 |
my_strxfrm_flag_normalize
|
eloqsql/strings/ctype-simple.c
|
uint my_strxfrm_flag_normalize(uint flags, uint maximum)
{
DBUG_ASSERT(maximum >= 1 && maximum <= MY_STRXFRM_NLEVELS);
/* If levels are omitted, then 1-maximum is assumed*/
if (!(flags & MY_STRXFRM_LEVEL_ALL))
{
static uint def_level_flags[]= {0, 0x01, 0x03, 0x07, 0x0F, 0x1F, 0x3F };
uint flag_pad= flags &
(MY_STRXFRM_PAD_WITH_SPACE | MY_STRXFRM_PAD_TO_MAXLEN);
flags= def_level_flags[maximum] | flag_pad;
}
else
{
uint i;
uint flag_lev= flags & MY_STRXFRM_LEVEL_ALL;
uint flag_dsc= (flags >> MY_STRXFRM_DESC_SHIFT) & MY_STRXFRM_LEVEL_ALL;
uint flag_rev= (flags >> MY_STRXFRM_REVERSE_SHIFT) & MY_STRXFRM_LEVEL_ALL;
uint flag_pad= flags &
(MY_STRXFRM_PAD_WITH_SPACE | MY_STRXFRM_PAD_TO_MAXLEN);
/*
If any level number is greater than the maximum,
it is treated as the maximum.
*/
for (maximum--, flags= 0, i= 0; i < MY_STRXFRM_NLEVELS; i++)
{
uint src_bit= 1 << i;
if (flag_lev & src_bit)
{
uint dst_bit= 1 << MY_MIN(i, maximum);
flags|= dst_bit;
flags|= (flag_dsc & dst_bit) << MY_STRXFRM_DESC_SHIFT;
flags|= (flag_rev & dst_bit) << MY_STRXFRM_REVERSE_SHIFT;
}
}
flags|= flag_pad;
}
return flags;
}
|
O3
|
c
|
my_strxfrm_flag_normalize:
movl %edi, %eax
movl %edi, %edx
andl $0x3f, %edx
je 0x5a7f4
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
decl %esi
movl %eax, %r8d
andl $0x3f00, %r8d # imm = 0x3F00
movl %eax, %r9d
andl $0x3f0000, %r9d # imm = 0x3F0000
xorl %edi, %edi
xorl %r10d, %r10d
btl %r10d, %edx
jae 0x5a7df
cmpl %esi, %r10d
movl %esi, %ecx
cmovbl %r10d, %ecx
movl $0x1, %r11d
shll %cl, %r11d
movl $0x100, %ebx # imm = 0x100
shll %cl, %ebx
andl %r8d, %ebx
movl $0x10000, %r14d # imm = 0x10000
shll %cl, %r14d
addl %r11d, %ebx
andl %r9d, %r14d
addl %ebx, %r14d
orl %r14d, %edi
incl %r10d
cmpl $0x6, %r10d
jne 0x5a7a8
andl $0xc0, %eax
orl %edi, %eax
popq %rbx
popq %r14
popq %rbp
retq
andl $0xc0, %eax
movl %esi, %ecx
leaq 0x16af8e(%rip), %rdx # 0x1c5790
orl (%rdx,%rcx,4), %eax
retq
|
my_strxfrm_flag_normalize:
mov eax, edi
mov edx, edi
and edx, 3Fh
jz short loc_5A7F4
push rbp
mov rbp, rsp
push r14
push rbx
dec esi
mov r8d, eax
and r8d, 3F00h
mov r9d, eax
and r9d, 3F0000h
xor edi, edi
xor r10d, r10d
loc_5A7A8:
bt edx, r10d
jnb short loc_5A7DF
cmp r10d, esi
mov ecx, esi
cmovb ecx, r10d
mov r11d, 1
shl r11d, cl
mov ebx, 100h
shl ebx, cl
and ebx, r8d
mov r14d, offset stru_10000
shl r14d, cl
add ebx, r11d
and r14d, r9d
add r14d, ebx
or edi, r14d
loc_5A7DF:
inc r10d
cmp r10d, 6
jnz short loc_5A7A8
and eax, 0C0h
or eax, edi
pop rbx
pop r14
pop rbp
retn
loc_5A7F4:
and eax, 0C0h
mov ecx, esi
lea rdx, my_strxfrm_flag_normalize_def_level_flags
or eax, [rdx+rcx*4]
retn
|
long long my_strxfrm_flag_normalize(int a1, int a2)
{
int v3; // edx
unsigned int v4; // esi
int v5; // r8d
int v6; // edi
unsigned int i; // r10d
char v8; // cl
v3 = a1 & 0x3F;
if ( (a1 & 0x3F) == 0 )
return my_strxfrm_flag_normalize_def_level_flags[a2] | a1 & 0xC0u;
v4 = a2 - 1;
v5 = a1 & 0x3F00;
v6 = 0;
for ( i = 0; i != 6; ++i )
{
if ( _bittest(&v3, i) )
{
v8 = v4;
if ( i < v4 )
v8 = i;
v6 |= (1 << v8) + (v5 & (256 << v8)) + (a1 & 0x3F0000 & ((_DWORD)&stru_10000 << v8));
}
}
return v6 | a1 & 0xC0u;
}
|
my_strxfrm_flag_normalize:
MOV EAX,EDI
MOV EDX,EDI
AND EDX,0x3f
JZ 0x0015a7f4
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
DEC ESI
MOV R8D,EAX
AND R8D,0x3f00
MOV R9D,EAX
AND R9D,0x3f0000
XOR EDI,EDI
XOR R10D,R10D
LAB_0015a7a8:
BT EDX,R10D
JNC 0x0015a7df
CMP R10D,ESI
MOV ECX,ESI
CMOVC ECX,R10D
MOV R11D,0x1
SHL R11D,CL
MOV EBX,0x100
SHL EBX,CL
AND EBX,R8D
MOV R14D,0x10000
SHL R14D,CL
ADD EBX,R11D
AND R14D,R9D
ADD R14D,EBX
OR EDI,R14D
LAB_0015a7df:
INC R10D
CMP R10D,0x6
JNZ 0x0015a7a8
AND EAX,0xc0
OR EAX,EDI
POP RBX
POP R14
POP RBP
RET
LAB_0015a7f4:
AND EAX,0xc0
MOV ECX,ESI
LEA RDX,[0x2c5790]
OR EAX,dword ptr [RDX + RCX*0x4]
RET
|
uint my_strxfrm_flag_normalize(uint param_1,uint param_2)
{
uint uVar1;
byte bVar2;
uint uVar3;
uint uVar4;
if ((param_1 & 0x3f) != 0) {
uVar3 = 0;
uVar4 = 0;
do {
if (((param_1 & 0x3f) >> (uVar4 & 0x1f) & 1) != 0) {
uVar1 = param_2 - 1;
if (uVar4 < param_2 - 1) {
uVar1 = uVar4;
}
bVar2 = (byte)uVar1;
uVar3 = uVar3 | (0x10000 << (bVar2 & 0x1f) & param_1 & 0x3f0000) +
(0x100 << (bVar2 & 0x1f) & param_1 & 0x3f00) + (1 << (bVar2 & 0x1f));
}
uVar4 = uVar4 + 1;
} while (uVar4 != 6);
return param_1 & 0xc0 | uVar3;
}
return param_1 & 0xc0 | *(uint *)(my_strxfrm_flag_normalize_def_level_flags + (ulong)param_2 * 4);
}
|
|
64,842 |
my_dir
|
eloqsql/mysys/my_lib.c
|
MY_DIR *my_dir(const char *path, myf MyFlags)
{
MY_DIR_HANDLE *dirh;
FILEINFO finfo;
DIR *dirp;
struct dirent *dp;
char tmp_path[FN_REFLEN + 2], *tmp_file;
char dirent_tmp[sizeof(struct dirent)+_POSIX_PATH_MAX+1];
DBUG_ENTER("my_dir");
DBUG_PRINT("my",("path: '%s' MyFlags: %lu",path,MyFlags));
tmp_file= directory_file_name(tmp_path, path);
if (!(dirp= opendir(tmp_path)))
{
my_errno= errno;
goto err_open;
}
if (!(dirh= my_malloc(key_memory_MY_DIR, sizeof(*dirh),
MYF(MyFlags | MY_ZEROFILL))))
goto err_alloc;
if (my_init_dynamic_array(key_memory_MY_DIR, &dirh->array, sizeof(FILEINFO),
ENTRIES_START_SIZE, ENTRIES_INCREMENT,
MYF(MyFlags)))
goto error;
init_alloc_root(key_memory_MY_DIR, &dirh->root, NAMES_START_SIZE,
NAMES_START_SIZE, MYF(MyFlags));
dp= (struct dirent*) dirent_tmp;
while (!(READDIR(dirp,(struct dirent*) dirent_tmp,dp)))
{
MY_STAT statbuf, *mystat= 0;
if (dp->d_name[0] == '.' &&
(dp->d_name[1] == '\0' ||
(dp->d_name[1] == '.' && dp->d_name[2] == '\0')))
continue; /* . or .. */
if (MyFlags & MY_WANT_STAT)
{
mystat= &statbuf;
bzero(mystat, sizeof(*mystat));
(void) strmov(tmp_file, dp->d_name);
(void) my_stat(tmp_path, mystat, MyFlags);
if (!(mystat->st_mode & MY_S_IREAD))
continue;
}
if (!(finfo.name= strdup_root(&dirh->root, dp->d_name)))
goto error;
if (mystat &&
!((mystat= memdup_root(&dirh->root, mystat, sizeof(*mystat)))))
goto error;
finfo.mystat= mystat;
if (push_dynamic(&dirh->array, (uchar*)&finfo))
goto error;
}
(void) closedir(dirp);
if (MyFlags & MY_WANT_SORT)
sort_dynamic(&dirh->array, (qsort_cmp) comp_names);
dirh->dir.dir_entry= dynamic_element(&dirh->array, 0, FILEINFO *);
dirh->dir.number_of_files= dirh->array.elements;
DBUG_RETURN(&dirh->dir);
error:
my_dirend(&dirh->dir);
err_alloc:
(void) closedir(dirp);
err_open:
if (MyFlags & (MY_FAE | MY_WME))
my_error(EE_DIR, MYF(ME_BELL), path, my_errno);
DBUG_RETURN(NULL);
}
|
O3
|
c
|
my_dir:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x2e8, %rsp # imm = 0x2E8
movq %rdi, %r14
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
cmpb $0x0, (%rdi)
movq %rsi, %r15
leaq 0x32023(%rip), %rsi # 0x5d199
cmovneq %rdi, %rsi
leaq -0x240(%rbp), %rdi
movl $0x201, %edx # imm = 0x201
callq 0x5af10
movq %rax, %r12
cmpb $0x2f, -0x1(%rax)
je 0x2b19e
movw $0x2f, (%r12)
incq %r12
leaq -0x240(%rbp), %rdi
callq 0x24600
testq %rax, %rax
je 0x2b22e
movq %rax, %r13
leaq 0x33b4ab(%rip), %rbx # 0x366664
movl (%rbx), %edi
movq %r15, -0x248(%rbp)
orq $0x20, %r15
movl $0x78, %esi
movq %r15, %rdx
callq 0x2b4f5
testq %rax, %rax
je 0x2b21d
movq %rax, %r15
movq %r12, -0x268(%rbp)
movq %rbx, %r12
movl (%rbx), %edi
leaq 0x10(%rax), %rbx
movq -0x248(%rbp), %rax
movq %rax, (%rsp)
movq %rbx, %rsi
movl $0x10, %edx
xorl %ecx, %ecx
movl $0x200, %r8d # imm = 0x200
movl $0x1000, %r9d # imm = 0x1000
callq 0x2c288
testb %al, %al
je 0x2b26d
movq %r15, %rdi
callq 0x2b114
movq %r13, %rdi
callq 0x24680
movq -0x248(%rbp), %r15
jmp 0x2b23c
callq 0x24060
movl (%rax), %ebx
callq 0x26caa
movl %ebx, (%rax)
testb $0x18, %r15b
je 0x2b265
callq 0x26caa
movl (%rax), %ecx
xorl %r15d, %r15d
movl $0x4, %esi
movl $0xc, %edi
movq %r14, %rdx
xorl %eax, %eax
callq 0x2aaeb
jmp 0x2b3de
xorl %r15d, %r15d
jmp 0x2b3de
movq %rbx, -0x260(%rbp)
movq %r14, -0x258(%rbp)
movl (%r12), %edi
movq %r15, %rsi
addq $0x38, %rsi
movl $0x8000, %edx # imm = 0x8000
movl $0x8000, %ecx # imm = 0x8000
movq %rsi, -0x250(%rbp)
movq -0x248(%rbp), %r8
callq 0x2da1c
movq %r13, %rdi
callq 0x24210
testq %rax, %rax
je 0x2b3a5
movq %rax, %rbx
movq -0x248(%rbp), %r14
cmpb $0x2e, 0x13(%rbx)
jne 0x2b2df
movzbl 0x14(%rbx), %eax
testl %eax, %eax
je 0x2b391
cmpl $0x2e, %eax
jne 0x2b2df
cmpb $0x0, 0x15(%rbx)
je 0x2b391
addq $0x13, %rbx
btl $0xe, %r14d
jb 0x2b2ef
xorl %r12d, %r12d
jmp 0x2b32f
movl $0x90, %edx
leaq -0x308(%rbp), %r12
movq %r12, %rdi
xorl %esi, %esi
callq 0x241e0
movq -0x268(%rbp), %rdi
movq %rbx, %rsi
callq 0x24360
leaq -0x240(%rbp), %rdi
movq %r12, %rsi
movq %r14, %rdx
callq 0x2b413
testb $0x1, -0x2ef(%rbp)
je 0x2b391
movq -0x250(%rbp), %rdi
movq %rbx, %rsi
callq 0x2df0e
movq %rax, -0x278(%rbp)
testq %rax, %rax
je 0x2b402
testq %r12, %r12
je 0x2b371
movl $0x90, %edx
movq -0x250(%rbp), %rdi
movq %r12, %rsi
callq 0x2df7c
testq %rax, %rax
jne 0x2b373
jmp 0x2b402
xorl %eax, %eax
movq %rax, -0x270(%rbp)
movq -0x260(%rbp), %rdi
leaq -0x278(%rbp), %rsi
callq 0x2c326
testb %al, %al
jne 0x2b402
movq %r13, %rdi
callq 0x24210
movq %rax, %rbx
testq %rax, %rax
jne 0x2b2be
movq %r13, %rdi
callq 0x24680
btl $0xd, -0x248(%rbp)
jae 0x2b3cf
movq 0x10(%r15), %rdi
movl 0x18(%r15), %esi
movl 0x24(%r15), %edx
leaq 0xed(%rip), %rcx # 0x2b4b7
callq 0x2d1fc
movq 0x10(%r15), %rax
movq %rax, (%r15)
movl 0x18(%r15), %eax
movl %eax, 0x8(%r15)
movq %fs:0x28, %rax
cmpq -0x30(%rbp), %rax
jne 0x2b40e
movq %r15, %rax
addq $0x2e8, %rsp # imm = 0x2E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq -0x258(%rbp), %r14
jmp 0x2b215
callq 0x24420
|
my_dir:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 2E8h
mov r14, rdi
mov rax, fs:28h
mov [rbp+var_30], rax
cmp byte ptr [rdi], 0
mov r15, rsi
lea rsi, asc_5D198+1; "."
cmovnz rsi, rdi
lea rdi, [rbp+var_240]
mov edx, 201h
call strnmov
mov r12, rax
cmp byte ptr [rax-1], 2Fh ; '/'
jz short loc_2B19E
mov word ptr [r12], 2Fh ; '/'
inc r12
loc_2B19E:
lea rdi, [rbp+var_240]
call _opendir
test rax, rax
jz short loc_2B22E
mov r13, rax
lea rbx, key_memory_MY_DIR
mov edi, [rbx]
mov [rbp+var_248], r15
or r15, 20h
mov esi, 78h ; 'x'
mov rdx, r15
call my_malloc
test rax, rax
jz short loc_2B21D
mov r15, rax
mov [rbp+var_268], r12
mov r12, rbx
mov edi, [rbx]
lea rbx, [rax+10h]
mov rax, [rbp+var_248]
mov [rsp+310h+var_310], rax
mov rsi, rbx
mov edx, 10h
xor ecx, ecx
mov r8d, 200h
mov r9d, 1000h
call init_dynamic_array2
test al, al
jz short loc_2B26D
loc_2B215:
mov rdi, r15
call my_dirend
loc_2B21D:
mov rdi, r13
call _closedir
mov r15, [rbp+var_248]
jmp short loc_2B23C
loc_2B22E:
call ___errno_location
mov ebx, [rax]
call _my_thread_var
mov [rax], ebx
loc_2B23C:
test r15b, 18h
jz short loc_2B265
call _my_thread_var
mov ecx, [rax]
xor r15d, r15d
mov esi, 4
mov edi, 0Ch
mov rdx, r14
xor eax, eax
call my_error
jmp loc_2B3DE
loc_2B265:
xor r15d, r15d
jmp loc_2B3DE
loc_2B26D:
mov [rbp+var_260], rbx
mov [rbp+var_258], r14
mov edi, [r12]
mov rsi, r15
add rsi, 38h ; '8'
mov edx, 8000h
mov ecx, 8000h
mov [rbp+var_250], rsi
mov r8, [rbp+var_248]
call init_alloc_root
mov rdi, r13
call _readdir64
test rax, rax
jz loc_2B3A5
mov rbx, rax
mov r14, [rbp+var_248]
loc_2B2BE:
cmp byte ptr [rbx+13h], 2Eh ; '.'
jnz short loc_2B2DF
movzx eax, byte ptr [rbx+14h]
test eax, eax
jz loc_2B391
cmp eax, 2Eh ; '.'
jnz short loc_2B2DF
cmp byte ptr [rbx+15h], 0
jz loc_2B391
loc_2B2DF:
add rbx, 13h
bt r14d, 0Eh
jb short loc_2B2EF
xor r12d, r12d
jmp short loc_2B32F
loc_2B2EF:
mov edx, 90h
lea r12, [rbp+var_308]
mov rdi, r12
xor esi, esi
call _memset
mov rdi, [rbp+var_268]
mov rsi, rbx
call _strcpy
lea rdi, [rbp+var_240]
mov rsi, r12
mov rdx, r14
call my_stat
test [rbp+var_2EF], 1
jz short loc_2B391
loc_2B32F:
mov rdi, [rbp+var_250]
mov rsi, rbx
call strdup_root
mov [rbp+var_278], rax
test rax, rax
jz loc_2B402
test r12, r12
jz short loc_2B371
mov edx, 90h
mov rdi, [rbp+var_250]
mov rsi, r12
call memdup_root
test rax, rax
jnz short loc_2B373
jmp loc_2B402
loc_2B371:
xor eax, eax
loc_2B373:
mov [rbp+var_270], rax
mov rdi, [rbp+var_260]
lea rsi, [rbp+var_278]
call insert_dynamic
test al, al
jnz short loc_2B402
loc_2B391:
mov rdi, r13
call _readdir64
mov rbx, rax
test rax, rax
jnz loc_2B2BE
loc_2B3A5:
mov rdi, r13
call _closedir
bt dword ptr [rbp+var_248], 0Dh
jnb short loc_2B3CF
mov rdi, [r15+10h]
mov esi, [r15+18h]
mov edx, [r15+24h]
lea rcx, comp_names
call my_qsort
loc_2B3CF:
mov rax, [r15+10h]
mov [r15], rax
mov eax, [r15+18h]
mov [r15+8], eax
loc_2B3DE:
mov rax, fs:28h
cmp rax, [rbp+var_30]
jnz short loc_2B40E
mov rax, r15
add rsp, 2E8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_2B402:
mov r14, [rbp+var_258]
jmp loc_2B215
loc_2B40E:
call ___stack_chk_fail
|
long long my_dir(char *a1, long long a2)
{
char *v2; // r14
char *v4; // rsi
char *v5; // rax
char *v6; // r12
long long v7; // rax
long long v8; // r13
long long v9; // rax
long long v10; // r15
long long v11; // rbx
int v12; // ebx
unsigned int *v13; // rax
long long v14; // rax
_BYTE *v15; // rbx
__int16 v16; // r14
_BYTE *v17; // rbx
_BYTE *v18; // r12
long long v19; // rax
_BYTE v21[144]; // [rsp+8h] [rbp-308h] BYREF
_QWORD v22[2]; // [rsp+98h] [rbp-278h] BYREF
char *v23; // [rsp+A8h] [rbp-268h]
long long v24; // [rsp+B0h] [rbp-260h]
char *v25; // [rsp+B8h] [rbp-258h]
long long v26; // [rsp+C0h] [rbp-250h]
long long v27; // [rsp+C8h] [rbp-248h] BYREF
_BYTE v28[528]; // [rsp+D0h] [rbp-240h] BYREF
unsigned long long v29; // [rsp+2E0h] [rbp-30h]
v2 = a1;
v29 = __readfsqword(0x28u);
v4 = ".";
if ( *a1 )
v4 = a1;
v5 = (char *)strnmov(v28, v4, 513LL);
v6 = v5;
if ( *(v5 - 1) != 47 )
{
*(_WORD *)v5 = 47;
v6 = v5 + 1;
}
v7 = opendir(v28);
if ( !v7 )
{
v12 = *(_DWORD *)__errno_location(v28);
*(_DWORD *)my_thread_var() = v12;
goto LABEL_11;
}
v8 = v7;
v27 = a2;
v9 = my_malloc(key_memory_MY_DIR, 120LL, a2 | 0x20);
if ( !v9 )
goto LABEL_9;
v10 = v9;
v23 = v6;
v11 = v9 + 16;
if ( (unsigned __int8)init_dynamic_array2(key_memory_MY_DIR, (int)v9 + 16, 16, 0, 512, 4096, v27) )
goto LABEL_8;
v24 = v11;
v25 = a1;
v26 = v10 + 56;
init_alloc_root(key_memory_MY_DIR, v10 + 56, 0x8000LL, 0x8000LL, v27);
v14 = readdir64(v8);
if ( !v14 )
{
LABEL_30:
closedir(v8);
if ( _bittest((const signed __int32 *)&v27, 0xDu) )
my_qsort(*(_QWORD *)(v10 + 16), *(unsigned int *)(v10 + 24), *(unsigned int *)(v10 + 36), comp_names);
*(_QWORD *)v10 = *(_QWORD *)(v10 + 16);
*(_DWORD *)(v10 + 8) = *(_DWORD *)(v10 + 24);
return v10;
}
v15 = (_BYTE *)v14;
v16 = v27;
while ( 1 )
{
if ( v15[19] == 46 && (!v15[20] || v15[20] == 46 && !v15[21]) )
goto LABEL_29;
v17 = v15 + 19;
if ( (v16 & 0x4000) != 0 )
{
v18 = v21;
memset(v21, 0LL, sizeof(v21));
strcpy(v23, v17);
my_stat(v28, v21);
if ( (v21[25] & 1) == 0 )
goto LABEL_29;
}
else
{
v18 = 0LL;
}
v22[0] = strdup_root(v26, v17);
if ( !v22[0] )
break;
if ( v18 )
{
v19 = memdup_root(v26, v18, 144LL);
if ( !v19 )
break;
}
else
{
v19 = 0LL;
}
v22[1] = v19;
if ( (unsigned __int8)insert_dynamic(v24, v22) )
break;
LABEL_29:
v15 = (_BYTE *)readdir64(v8);
if ( !v15 )
goto LABEL_30;
}
v2 = v25;
LABEL_8:
my_dirend(v10);
LABEL_9:
closedir(v8);
LOBYTE(a2) = v27;
LABEL_11:
if ( (a2 & 0x18) == 0 )
return 0LL;
v13 = (unsigned int *)my_thread_var();
v10 = 0LL;
my_error(0xCu, 4, v2, *v13);
return v10;
}
|
my_dir:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x2e8
MOV R14,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
CMP byte ptr [RDI],0x0
MOV R15,RSI
LEA RSI,[0x15d199]
CMOVNZ RSI,RDI
LEA RDI,[RBP + -0x240]
MOV EDX,0x201
CALL 0x0015af10
MOV R12,RAX
CMP byte ptr [RAX + -0x1],0x2f
JZ 0x0012b19e
MOV word ptr [R12],0x2f
INC R12
LAB_0012b19e:
LEA RDI,[RBP + -0x240]
CALL 0x00124600
TEST RAX,RAX
JZ 0x0012b22e
MOV R13,RAX
LEA RBX,[0x466664]
MOV EDI,dword ptr [RBX]
MOV qword ptr [RBP + -0x248],R15
OR R15,0x20
MOV ESI,0x78
MOV RDX,R15
CALL 0x0012b4f5
TEST RAX,RAX
JZ 0x0012b21d
MOV R15,RAX
MOV qword ptr [RBP + -0x268],R12
MOV R12,RBX
MOV EDI,dword ptr [RBX]
LEA RBX,[RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x248]
MOV qword ptr [RSP],RAX
MOV RSI,RBX
MOV EDX,0x10
XOR ECX,ECX
MOV R8D,0x200
MOV R9D,0x1000
CALL 0x0012c288
TEST AL,AL
JZ 0x0012b26d
LAB_0012b215:
MOV RDI,R15
CALL 0x0012b114
LAB_0012b21d:
MOV RDI,R13
CALL 0x00124680
MOV R15,qword ptr [RBP + -0x248]
JMP 0x0012b23c
LAB_0012b22e:
CALL 0x00124060
MOV EBX,dword ptr [RAX]
CALL 0x00126caa
MOV dword ptr [RAX],EBX
LAB_0012b23c:
TEST R15B,0x18
JZ 0x0012b265
CALL 0x00126caa
MOV ECX,dword ptr [RAX]
XOR R15D,R15D
MOV ESI,0x4
MOV EDI,0xc
MOV RDX,R14
XOR EAX,EAX
CALL 0x0012aaeb
JMP 0x0012b3de
LAB_0012b265:
XOR R15D,R15D
JMP 0x0012b3de
LAB_0012b26d:
MOV qword ptr [RBP + -0x260],RBX
MOV qword ptr [RBP + -0x258],R14
MOV EDI,dword ptr [R12]
MOV RSI,R15
ADD RSI,0x38
MOV EDX,0x8000
MOV ECX,0x8000
MOV qword ptr [RBP + -0x250],RSI
MOV R8,qword ptr [RBP + -0x248]
CALL 0x0012da1c
MOV RDI,R13
CALL 0x00124210
TEST RAX,RAX
JZ 0x0012b3a5
MOV RBX,RAX
MOV R14,qword ptr [RBP + -0x248]
LAB_0012b2be:
CMP byte ptr [RBX + 0x13],0x2e
JNZ 0x0012b2df
MOVZX EAX,byte ptr [RBX + 0x14]
TEST EAX,EAX
JZ 0x0012b391
CMP EAX,0x2e
JNZ 0x0012b2df
CMP byte ptr [RBX + 0x15],0x0
JZ 0x0012b391
LAB_0012b2df:
ADD RBX,0x13
BT R14D,0xe
JC 0x0012b2ef
XOR R12D,R12D
JMP 0x0012b32f
LAB_0012b2ef:
MOV EDX,0x90
LEA R12,[RBP + -0x308]
MOV RDI,R12
XOR ESI,ESI
CALL 0x001241e0
MOV RDI,qword ptr [RBP + -0x268]
MOV RSI,RBX
CALL 0x00124360
LEA RDI,[RBP + -0x240]
MOV RSI,R12
MOV RDX,R14
CALL 0x0012b413
TEST byte ptr [RBP + -0x2ef],0x1
JZ 0x0012b391
LAB_0012b32f:
MOV RDI,qword ptr [RBP + -0x250]
MOV RSI,RBX
CALL 0x0012df0e
MOV qword ptr [RBP + -0x278],RAX
TEST RAX,RAX
JZ 0x0012b402
TEST R12,R12
JZ 0x0012b371
MOV EDX,0x90
MOV RDI,qword ptr [RBP + -0x250]
MOV RSI,R12
CALL 0x0012df7c
TEST RAX,RAX
JNZ 0x0012b373
JMP 0x0012b402
LAB_0012b371:
XOR EAX,EAX
LAB_0012b373:
MOV qword ptr [RBP + -0x270],RAX
MOV RDI,qword ptr [RBP + -0x260]
LEA RSI,[RBP + -0x278]
CALL 0x0012c326
TEST AL,AL
JNZ 0x0012b402
LAB_0012b391:
MOV RDI,R13
CALL 0x00124210
MOV RBX,RAX
TEST RAX,RAX
JNZ 0x0012b2be
LAB_0012b3a5:
MOV RDI,R13
CALL 0x00124680
BT dword ptr [RBP + -0x248],0xd
JNC 0x0012b3cf
MOV RDI,qword ptr [R15 + 0x10]
MOV ESI,dword ptr [R15 + 0x18]
MOV EDX,dword ptr [R15 + 0x24]
LEA RCX,[0x12b4b7]
CALL 0x0012d1fc
LAB_0012b3cf:
MOV RAX,qword ptr [R15 + 0x10]
MOV qword ptr [R15],RAX
MOV EAX,dword ptr [R15 + 0x18]
MOV dword ptr [R15 + 0x8],EAX
LAB_0012b3de:
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNZ 0x0012b40e
MOV RAX,R15
ADD RSP,0x2e8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0012b402:
MOV R14,qword ptr [RBP + -0x258]
JMP 0x0012b215
LAB_0012b40e:
CALL 0x00124420
|
int8 * my_dir(char *param_1,ulong param_2)
{
int iVar1;
ulong uVar2;
char cVar3;
char *pcVar4;
DIR *__dirp;
int8 *puVar5;
int *piVar6;
int4 *puVar7;
dirent64 *pdVar8;
long lVar9;
int1 *__s;
long in_FS_OFFSET;
int1 local_310 [25];
byte local_2f7;
long local_280;
long local_278;
char *local_270;
int8 *local_268;
char *local_260;
int8 *local_258;
ulong local_250;
char local_248 [528];
long local_38;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
pcVar4 = ".";
if (*param_1 != '\0') {
pcVar4 = param_1;
}
pcVar4 = (char *)strnmov(local_248,pcVar4,0x201);
if (pcVar4[-1] != '/') {
pcVar4[0] = '/';
pcVar4[1] = '\0';
pcVar4 = pcVar4 + 1;
}
__dirp = opendir(local_248);
if (__dirp == (DIR *)0x0) {
piVar6 = __errno_location();
iVar1 = *piVar6;
piVar6 = (int *)_my_thread_var();
*piVar6 = iVar1;
}
else {
local_250 = param_2;
puVar5 = (int8 *)my_malloc(key_memory_MY_DIR,0x78,param_2 | 0x20);
if (puVar5 != (int8 *)0x0) {
local_270 = pcVar4;
cVar3 = init_dynamic_array2(key_memory_MY_DIR,puVar5 + 2,0x10,0,0x200,0x1000,local_250);
if (cVar3 == '\0') {
local_258 = puVar5 + 7;
local_268 = puVar5 + 2;
local_260 = param_1;
init_alloc_root(key_memory_MY_DIR,local_258,0x8000,0x8000,local_250);
pdVar8 = readdir64(__dirp);
uVar2 = local_250;
while (pdVar8 != (dirent64 *)0x0) {
if ((pdVar8->d_name[0] != '.') ||
((pdVar8->d_name[1] != '\0' &&
((pdVar8->d_name[1] != '.' || (pdVar8->d_name[2] != '\0')))))) {
if (((uint)uVar2 >> 0xe & 1) == 0) {
__s = (int1 *)0x0;
}
else {
__s = local_310;
memset(__s,0,0x90);
strcpy(local_270,pdVar8->d_name);
my_stat(local_248,__s,uVar2);
if ((local_2f7 & 1) == 0) goto LAB_0012b391;
}
local_280 = strdup_root(local_258,pdVar8->d_name);
param_1 = local_260;
if (local_280 == 0) goto LAB_0012b215;
if (__s == (int1 *)0x0) {
lVar9 = 0;
}
else {
lVar9 = memdup_root(local_258,__s,0x90);
param_1 = local_260;
if (lVar9 == 0) goto LAB_0012b215;
}
local_278 = lVar9;
cVar3 = insert_dynamic(local_268);
param_1 = local_260;
if (cVar3 != '\0') goto LAB_0012b215;
}
LAB_0012b391:
pdVar8 = readdir64(__dirp);
}
closedir(__dirp);
if (((uint)local_250 >> 0xd & 1) != 0) {
my_qsort(puVar5[2],*(int4 *)(puVar5 + 3),*(int4 *)((long)puVar5 + 0x24),
comp_names);
}
*puVar5 = puVar5[2];
*(int4 *)(puVar5 + 1) = *(int4 *)(puVar5 + 3);
goto LAB_0012b3de;
}
LAB_0012b215:
my_dirend(puVar5);
}
closedir(__dirp);
param_2 = local_250;
}
if ((param_2 & 0x18) == 0) {
puVar5 = (int8 *)0x0;
}
else {
puVar7 = (int4 *)_my_thread_var();
puVar5 = (int8 *)0x0;
my_error(0xc,4,param_1,*puVar7);
}
LAB_0012b3de:
if (*(long *)(in_FS_OFFSET + 0x28) == local_38) {
return puVar5;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
|
|
64,843 |
PulseAudio::Init()
|
Dolphin-anty/Source/Core/AudioCommon/PulseAudioStream.cpp
|
bool PulseAudio::Init()
{
m_stereo = !Config::ShouldUseDPL2Decoder();
m_channels = m_stereo ? 2 : 6; // will tell PA we use a Stereo or 5.0 channel setup
NOTICE_LOG_FMT(AUDIO, "PulseAudio backend using {} channels", m_channels);
m_run_thread.Set();
m_thread = std::thread(&PulseAudio::SoundLoop, this);
return true;
}
|
O3
|
cpp
|
PulseAudio::Init():
pushq %r14
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
callq 0x1dec42
movzbl %al, %ecx
xorb $0x1, %al
movb %al, 0x19(%rbx)
leal 0x2(,%rcx,4), %eax
movl %eax, 0x20(%rbx)
leaq 0x10(%rsp), %rcx
movq %rax, (%rcx)
leaq 0x28(%rsp), %r14
movq $0x1, (%r14)
movq %rcx, 0x8(%r14)
movq %r14, (%rsp)
leaq 0x5d25c6(%rip), %rdx # 0xad0c20
leaq 0x5d265c(%rip), %r8 # 0xad0cbd
movl $0x24, %r9d
movl $0x1, %edi
movl $0x2, %esi
movl $0x1a, %ecx
callq 0x9bf26c
movb $0x1, %al
xchgb %al, 0x18(%rbx)
leaq 0x41(%rip), %rax # 0x4fe6c8
movq %rax, (%r14)
movq $0x0, 0x8(%r14)
leaq 0x20(%rsp), %rdx
movq %rbx, (%rdx)
leaq 0x10(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0x4fecda
cmpq $0x0, 0x10(%rbx)
jne 0x4fe6c3
movq 0x10(%rsp), %rax
movq %rax, 0x10(%rbx)
movb $0x1, %al
addq $0x38, %rsp
popq %rbx
popq %r14
retq
callq 0x111370
|
_ZN10PulseAudio4InitEv:
push r14
push rbx
sub rsp, 38h
mov rbx, rdi
call _ZN6Config20ShouldUseDPL2DecoderEv; Config::ShouldUseDPL2Decoder(void)
movzx ecx, al
xor al, 1
mov [rbx+19h], al
lea eax, ds:2[rcx*4]
mov [rbx+20h], eax
lea rcx, [rsp+48h+var_38]
mov [rcx], rax
lea r14, [rsp+48h+var_20]
mov qword ptr [r14], 1
mov [r14+8], rcx
mov [rsp+48h+var_48], r14
lea rdx, aWorkspaceLlm4b_338; "/workspace/llm4binary/github2025/Dolphi"...
lea r8, aPulseaudioBack; "PulseAudio backend using {} channels"
mov r9d, 24h ; '$'
mov edi, 1
mov esi, 2
mov ecx, 1Ah
call _ZN6Common3Log17GenericLogFmtImplENS0_8LogLevelENS0_7LogTypeEPKciN3fmt3v1017basic_string_viewIcEERKNS6_17basic_format_argsINS6_20basic_format_contextINS6_8appenderEcEEEE; Common::Log::GenericLogFmtImpl(Common::Log::LogLevel,Common::Log::LogType,char const*,int,fmt::v10::basic_string_view<char>,fmt::v10::basic_format_args<fmt::v10::basic_format_context<fmt::v10::appender,char>> const&)
mov al, 1
xchg al, [rbx+18h]
lea rax, _ZN10PulseAudio9SoundLoopEv; PulseAudio::SoundLoop(void)
mov [r14], rax
mov qword ptr [r14+8], 0
lea rdx, [rsp+48h+var_28]
mov [rdx], rbx
lea rdi, [rsp+48h+var_38]
lea rsi, [rsp+48h+var_20]
call _ZNSt6threadC2IM10PulseAudioFvvEJPS1_EvEEOT_DpOT0_; std::thread::thread<void (PulseAudio::*)(void),PulseAudio*,void>(void (PulseAudio::*)(void) &&,PulseAudio* &&)
cmp qword ptr [rbx+10h], 0
jnz short loc_4FE6C3
mov rax, [rsp+48h+var_38]
mov [rbx+10h], rax
mov al, 1
add rsp, 38h
pop rbx
pop r14
retn
loc_4FE6C3:
call __ZSt9terminatev; std::terminate(void)
|
char PulseAudio::Init(PulseAudio *this)
{
unsigned __int8 ShouldUseDPL2Decoder; // al
unsigned int v2; // eax
_QWORD v4[3]; // [rsp+10h] [rbp-38h] BYREF
long long ( *v5)(PulseAudio *__hidden); // [rsp+28h] [rbp-20h] BYREF
_QWORD *v6; // [rsp+30h] [rbp-18h]
ShouldUseDPL2Decoder = Config::ShouldUseDPL2Decoder(this);
*((_BYTE *)this + 25) = ShouldUseDPL2Decoder ^ 1;
v2 = 4 * ShouldUseDPL2Decoder + 2;
*((_DWORD *)this + 8) = v2;
v4[0] = v2;
v5 = (long long ( *)(PulseAudio *__hidden))(&dword_0 + 1);
v6 = v4;
Common::Log::GenericLogFmtImpl(
1,
2,
(unsigned int)"/workspace/llm4binary/github2025/Dolphin-anty/Source/Core/AudioCommon/PulseAudioStream.cpp",
26,
(unsigned int)"PulseAudio backend using {} channels",
36,
(long long)&v5);
*((_BYTE *)this + 24) = 1;
v5 = PulseAudio::SoundLoop;
v6 = 0LL;
v4[2] = this;
std::thread::thread<void (PulseAudio::*)(void),PulseAudio*,void>(v4, &v5);
if ( *((_QWORD *)this + 2) )
std::terminate();
*((_QWORD *)this + 2) = v4[0];
return 1;
}
|
format_custom_arg<BitField<4ul,3ul,unsigned_int,unsigned_int>,fmt::v10::formatter<BitField<4ul,3ul,unsigned_int,unsigned_int>,char,void>>:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV RBX,RDX
MOV R14,RSI
MOV R15,RDI
XORPS XMM0,XMM0
MOV R12,RSP
MOVAPS xmmword ptr [R12],XMM0
MOVAPS xmmword ptr [R12 + 0x10],XMM0
MOVAPS xmmword ptr [R12 + 0x30],XMM0
MOVAPS xmmword ptr [R12 + 0x20],XMM0
MOV dword ptr [R12 + 0x4],0xffffffff
MOV word ptr [R12 + 0x9],0x0
MOV byte ptr [R12 + 0xb],0x20
MOV byte ptr [R12 + 0xd],0x0
MOV byte ptr [R12 + 0xf],0x1
XOR EAX,EAX
MOV dword ptr [R12 + 0x18],EAX
MOV dword ptr [R12 + 0x30],EAX
MOV RDI,R12
CALL 0x003944b6
MOV RCX,qword ptr [R14]
MOV qword ptr [R14],RAX
SUB RCX,RAX
ADD qword ptr [R14 + 0x8],RCX
MOV RDI,R12
MOV RSI,R15
MOV RDX,RBX
CALL 0x004fe6a8
MOV qword ptr [RBX],RAX
ADD RSP,0x48
POP RBX
POP R12
POP R14
POP R15
RET
|
/* void fmt::v10::detail::value<fmt::v10::basic_format_context<fmt::v10::appender, char>
>::format_custom_arg<BitField<4ul, 3ul, unsigned int, unsigned int>,
fmt::v10::formatter<BitField<4ul, 3ul, unsigned int, unsigned int>, char, void> >(void*,
fmt::v10::basic_format_parse_context<char>&, fmt::v10::basic_format_context<fmt::v10::appender,
char>&) */
void fmt::v10::detail::value<fmt::v10::basic_format_context<fmt::v10::appender,char>>::
format_custom_arg<BitField<4ul,3ul,unsigned_int,unsigned_int>,fmt::v10::formatter<BitField<4ul,3ul,unsigned_int,unsigned_int>,char,void>>
(void *param_1,basic_format_parse_context *param_2,basic_format_context *param_3)
{
long lVar1;
char *pcVar2;
int8 uVar3;
int8 local_68;
int8 uStack_60;
int8 local_58;
int8 uStack_50;
int8 local_48;
int8 uStack_40;
int8 local_38;
int8 uStack_30;
local_58 = 0;
uStack_30 = 0;
local_48 = 0;
uStack_40 = 0;
local_68 = 0xffffffff00000000;
uStack_60 = 0x100000020000000;
uStack_50 = 0;
local_38 = 0;
pcVar2 = formatter<unsigned_int,char,void>::parse<fmt::v10::basic_format_parse_context<char>>
((formatter<unsigned_int,char,void> *)&local_68,param_2);
lVar1 = *(long *)param_2;
*(char **)param_2 = pcVar2;
*(long *)(param_2 + 8) = *(long *)(param_2 + 8) + (lVar1 - (long)pcVar2);
uVar3 = formatter<BitField<4ul,3ul,unsigned_int,unsigned_int>,char,void>::
format<fmt::v10::basic_format_context<fmt::v10::appender,char>>
((formatter<BitField<4ul,3ul,unsigned_int,unsigned_int>,char,void> *)&local_68,
(BitField *)param_1,param_3);
*(int8 *)param_3 = uVar3;
return;
}
|
|
64,844 |
my_pread
|
eloqsql/mysys/my_pread.c
|
size_t my_pread(File Filedes, uchar *Buffer, size_t Count, my_off_t offset,
myf MyFlags)
{
size_t readbytes, save_count= 0;
DBUG_ENTER("my_pread");
DBUG_PRINT("my",("fd: %d Seek: %llu Buffer: %p Count: %lu MyFlags: %lu",
Filedes, (ulonglong)offset, Buffer, (ulong)Count, MyFlags));
if (!(MyFlags & (MY_WME | MY_FAE | MY_FNABP)))
MyFlags|= my_global_flags;
for (;;)
{
errno= 0; /* Linux, Windows don't reset this on EOF/success */
#ifdef _WIN32
readbytes= my_win_pread(Filedes, Buffer, Count, offset);
#else
readbytes= pread(Filedes, Buffer, Count, offset);
#endif
if (readbytes != Count)
{
/* We should never read with wrong file descriptor! */
DBUG_ASSERT(readbytes != (size_t)-1 || errno != EBADF);
my_errno= errno;
if (errno == 0 || (readbytes != (size_t) -1 &&
(MyFlags & (MY_NABP | MY_FNABP))))
my_errno= HA_ERR_FILE_TOO_SHORT;
DBUG_PRINT("warning",("Read only %d bytes off %u from %d, errno: %d",
(int) readbytes, (uint) Count,Filedes,my_errno));
if ((readbytes == 0 || readbytes == (size_t) -1) && errno == EINTR)
{
DBUG_PRINT("debug", ("my_pread() was interrupted and returned %d",
(int) readbytes));
continue; /* Interrupted */
}
/* Do a read retry if we didn't get enough data on first read */
if (readbytes != (size_t) -1 && readbytes != 0 &&
(MyFlags & MY_FULL_IO))
{
Buffer+= readbytes;
Count-= readbytes;
save_count+= readbytes;
offset+= readbytes;
continue;
}
if (MyFlags & (MY_WME | MY_FAE | MY_FNABP))
{
if (readbytes == (size_t) -1)
my_error(EE_READ,
MYF(ME_BELL | (MyFlags & (ME_NOTE | ME_ERROR_LOG))),
my_filename(Filedes),my_errno);
else if (MyFlags & (MY_NABP | MY_FNABP))
my_error(EE_EOFERR,
MYF(ME_BELL | (MyFlags & (ME_NOTE | ME_ERROR_LOG))),
my_filename(Filedes),my_errno);
}
if (readbytes == (size_t) -1 || (MyFlags & (MY_FNABP | MY_NABP)))
DBUG_RETURN(MY_FILE_ERROR); /* Return with error */
}
if (MyFlags & (MY_NABP | MY_FNABP))
readbytes= 0; /* Read went ok; Return 0 */
else
readbytes+= save_count;
DBUG_RETURN(readbytes);
}
}
|
O3
|
c
|
my_pread:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rcx, -0x58(%rbp)
movq %rdx, -0x38(%rbp)
movq %rsi, -0x50(%rbp)
movl %edi, -0x2c(%rbp)
movq $0x0, -0x40(%rbp)
movl $0x0, %r15d
testb $0x1a, %r8b
jne 0xa0676
leaq 0xb67b55(%rip), %rax # 0xc081c8
movq (%rax), %r15
orq %r8, %r15
callq 0x297b0
movq %rax, %r14
movq %r15, -0x48(%rbp)
movl $0x0, (%r14)
movl -0x2c(%rbp), %edi
movq -0x50(%rbp), %rsi
movq -0x38(%rbp), %rbx
movq %rbx, %rdx
movq -0x58(%rbp), %rcx
callq 0x29650
subq %rax, %rbx
je 0xa076d
movq %rax, %r12
testb $0x6, %r15b
sete %r13b
movl (%r14), %r15d
callq 0xa1afa
movl %r15d, (%rax)
cmpq $-0x1, %r12
sete %al
cmpl $0x0, (%r14)
je 0xa06d4
orb %r13b, %al
jne 0xa06df
callq 0xa1afa
movl $0xaf, (%rax)
leaq 0x1(%r12), %rax
cmpq $0x1, %rax
ja 0xa06f6
cmpl $0x4, (%r14)
movq -0x48(%rbp), %r15
je 0xa0685
jmp 0xa071e
movq -0x48(%rbp), %r15
btl $0x9, %r15d
jae 0xa0716
addq %r12, -0x50(%rbp)
addq %r12, -0x40(%rbp)
addq %r12, -0x58(%rbp)
movq %rbx, -0x38(%rbp)
jmp 0xa0685
movq $0x0, -0x40(%rbp)
testb $0x1a, %r15b
je 0xa0754
cmpq $-0x1, %r12
je 0xa0781
testb $0x6, %r15b
je 0xa0754
andl $0x440, %r15d # imm = 0x440
orq $0x4, %r15
movl -0x2c(%rbp), %edi
callq 0xa8fd8
movq %rax, %rbx
callq 0xa1afa
movl (%rax), %ecx
movl $0x9, %edi
jmp 0xa07a3
movq $-0x1, %rax
cmpq $-0x1, %r12
je 0xa07b7
movl %r15d, %ecx
movq %r12, -0x38(%rbp)
andl $0x6, %ecx
jne 0xa07b7
movq -0x40(%rbp), %rcx
addq -0x38(%rbp), %rcx
xorl %eax, %eax
testb $0x6, %r15b
cmoveq %rcx, %rax
jmp 0xa07b7
andl $0x440, %r15d # imm = 0x440
orq $0x4, %r15
movl -0x2c(%rbp), %edi
callq 0xa8fd8
movq %rax, %rbx
callq 0xa1afa
movl (%rax), %ecx
movl $0x2, %edi
movq %r15, %rsi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x9e1af
movq $-0x1, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
my_pread:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov [rbp+var_58], rcx
mov [rbp+var_38], rdx
mov [rbp+var_50], rsi
mov [rbp+var_2C], edi
mov [rbp+var_40], 0
mov r15d, 0
test r8b, 1Ah
jnz short loc_A0676
lea rax, my_global_flags
mov r15, [rax]
loc_A0676:
or r15, r8
call ___errno_location
mov r14, rax
mov [rbp+var_48], r15
loc_A0685:
mov dword ptr [r14], 0
mov edi, [rbp+var_2C]
mov rsi, [rbp+var_50]
mov rbx, [rbp+var_38]
mov rdx, rbx
mov rcx, [rbp+var_58]
call _pread64
sub rbx, rax
jz loc_A076D
mov r12, rax
test r15b, 6
setz r13b
mov r15d, [r14]
call _my_thread_var
mov [rax], r15d
cmp r12, 0FFFFFFFFFFFFFFFFh
setz al
cmp dword ptr [r14], 0
jz short loc_A06D4
or al, r13b
jnz short loc_A06DF
loc_A06D4:
call _my_thread_var
mov dword ptr [rax], 0AFh
loc_A06DF:
lea rax, [r12+1]
cmp rax, 1
ja short loc_A06F6
cmp dword ptr [r14], 4
mov r15, [rbp+var_48]
jz short loc_A0685
jmp short loc_A071E
loc_A06F6:
mov r15, [rbp+var_48]
bt r15d, 9
jnb short loc_A0716
add [rbp+var_50], r12
add [rbp+var_40], r12
add [rbp+var_58], r12
mov [rbp+var_38], rbx
jmp loc_A0685
loc_A0716:
mov [rbp+var_40], 0
loc_A071E:
test r15b, 1Ah
jz short loc_A0754
cmp r12, 0FFFFFFFFFFFFFFFFh
jz short loc_A0781
test r15b, 6
jz short loc_A0754
and r15d, 440h
or r15, 4
mov edi, [rbp+var_2C]
call my_filename
mov rbx, rax
call _my_thread_var
mov ecx, [rax]
mov edi, 9
jmp short loc_A07A3
loc_A0754:
mov rax, 0FFFFFFFFFFFFFFFFh
cmp r12, 0FFFFFFFFFFFFFFFFh
jz short loc_A07B7
mov ecx, r15d
mov [rbp+var_38], r12
and ecx, 6
jnz short loc_A07B7
loc_A076D:
mov rcx, [rbp+var_40]
add rcx, [rbp+var_38]
xor eax, eax
test r15b, 6
cmovz rax, rcx
jmp short loc_A07B7
loc_A0781:
and r15d, 440h
or r15, 4
mov edi, [rbp+var_2C]
call my_filename
mov rbx, rax
call _my_thread_var
mov ecx, [rax]
mov edi, 2
loc_A07A3:
mov rsi, r15
mov rdx, rbx
xor eax, eax
call my_error
mov rax, 0FFFFFFFFFFFFFFFFh
loc_A07B7:
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long my_pread(long long a1, const char *a2, long long a3, long long a4, __int16 a5)
{
__int16 v5; // r15
__int16 v6; // r15
int *v7; // r14
long long v8; // rax
long long v9; // rbx
long long v10; // r12
bool v11; // r13
int v12; // r15d
long long v13; // r15
long long v14; // rbx
long long v15; // rcx
unsigned int v16; // edi
long long result; // rax
__int16 v20; // [rsp+18h] [rbp-48h]
long long v21; // [rsp+20h] [rbp-40h]
v21 = 0LL;
v5 = 0;
if ( (a5 & 0x1A) == 0 )
v5 = my_global_flags;
v6 = a5 | v5;
v7 = (int *)__errno_location(a1);
v20 = v6;
while ( 1 )
{
while ( 1 )
{
*v7 = 0;
v8 = pread64((unsigned int)a1, a2, a3, a4);
v9 = a3 - v8;
if ( a3 == v8 )
goto LABEL_20;
v10 = v8;
v11 = (v6 & 6) == 0;
v12 = *v7;
*(_DWORD *)my_thread_var((unsigned int)a1, a2) = v12;
if ( !*v7 || !v11 && v10 != -1 )
*(_DWORD *)my_thread_var((unsigned int)a1, a2) = 175;
if ( (unsigned long long)(v10 + 1) > 1 )
break;
v6 = v20;
if ( *v7 != 4 )
goto LABEL_14;
}
v6 = v20;
if ( (v20 & 0x200) == 0 )
break;
a2 += v10;
v21 += v10;
a4 += v10;
a3 = v9;
}
v21 = 0LL;
LABEL_14:
if ( (v6 & 0x1A) != 0 )
{
if ( v10 == -1 )
{
v13 = v6 & 0x440 | 4LL;
v14 = my_filename((unsigned int)a1);
v15 = *(unsigned int *)my_thread_var((unsigned int)a1, a2);
v16 = 2;
goto LABEL_24;
}
if ( (v6 & 6) != 0 )
{
v13 = v6 & 0x440 | 4LL;
v14 = my_filename((unsigned int)a1);
v15 = *(unsigned int *)my_thread_var((unsigned int)a1, a2);
v16 = 9;
LABEL_24:
my_error(v16, v13, v14, v15);
return -1LL;
}
}
result = -1LL;
if ( v10 != -1 )
{
a3 = v10;
if ( (v6 & 6) == 0 )
{
LABEL_20:
result = 0LL;
if ( (v6 & 6) == 0 )
return a3 + v21;
}
}
return result;
}
|
my_pread:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV qword ptr [RBP + -0x58],RCX
MOV qword ptr [RBP + -0x38],RDX
MOV qword ptr [RBP + -0x50],RSI
MOV dword ptr [RBP + -0x2c],EDI
MOV qword ptr [RBP + -0x40],0x0
MOV R15D,0x0
TEST R8B,0x1a
JNZ 0x001a0676
LEA RAX,[0xd081c8]
MOV R15,qword ptr [RAX]
LAB_001a0676:
OR R15,R8
CALL 0x001297b0
MOV R14,RAX
MOV qword ptr [RBP + -0x48],R15
LAB_001a0685:
MOV dword ptr [R14],0x0
MOV EDI,dword ptr [RBP + -0x2c]
MOV RSI,qword ptr [RBP + -0x50]
MOV RBX,qword ptr [RBP + -0x38]
MOV RDX,RBX
MOV RCX,qword ptr [RBP + -0x58]
CALL 0x00129650
SUB RBX,RAX
JZ 0x001a076d
MOV R12,RAX
TEST R15B,0x6
SETZ R13B
MOV R15D,dword ptr [R14]
CALL 0x001a1afa
MOV dword ptr [RAX],R15D
CMP R12,-0x1
SETZ AL
CMP dword ptr [R14],0x0
JZ 0x001a06d4
OR AL,R13B
JNZ 0x001a06df
LAB_001a06d4:
CALL 0x001a1afa
MOV dword ptr [RAX],0xaf
LAB_001a06df:
LEA RAX,[R12 + 0x1]
CMP RAX,0x1
JA 0x001a06f6
CMP dword ptr [R14],0x4
MOV R15,qword ptr [RBP + -0x48]
JZ 0x001a0685
JMP 0x001a071e
LAB_001a06f6:
MOV R15,qword ptr [RBP + -0x48]
BT R15D,0x9
JNC 0x001a0716
ADD qword ptr [RBP + -0x50],R12
ADD qword ptr [RBP + -0x40],R12
ADD qword ptr [RBP + -0x58],R12
MOV qword ptr [RBP + -0x38],RBX
JMP 0x001a0685
LAB_001a0716:
MOV qword ptr [RBP + -0x40],0x0
LAB_001a071e:
TEST R15B,0x1a
JZ 0x001a0754
CMP R12,-0x1
JZ 0x001a0781
TEST R15B,0x6
JZ 0x001a0754
AND R15D,0x440
OR R15,0x4
MOV EDI,dword ptr [RBP + -0x2c]
CALL 0x001a8fd8
MOV RBX,RAX
CALL 0x001a1afa
MOV ECX,dword ptr [RAX]
MOV EDI,0x9
JMP 0x001a07a3
LAB_001a0754:
MOV RAX,-0x1
CMP R12,-0x1
JZ 0x001a07b7
MOV ECX,R15D
MOV qword ptr [RBP + -0x38],R12
AND ECX,0x6
JNZ 0x001a07b7
LAB_001a076d:
MOV RCX,qword ptr [RBP + -0x40]
ADD RCX,qword ptr [RBP + -0x38]
XOR EAX,EAX
TEST R15B,0x6
CMOVZ RAX,RCX
JMP 0x001a07b7
LAB_001a0781:
AND R15D,0x440
OR R15,0x4
MOV EDI,dword ptr [RBP + -0x2c]
CALL 0x001a8fd8
MOV RBX,RAX
CALL 0x001a1afa
MOV ECX,dword ptr [RAX]
MOV EDI,0x2
LAB_001a07a3:
MOV RSI,R15
MOV RDX,RBX
XOR EAX,EAX
CALL 0x0019e1af
MOV RAX,-0x1
LAB_001a07b7:
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
long my_pread(int param_1,void *param_2,size_t param_3,long param_4,ulong param_5)
{
int iVar1;
int4 uVar2;
int *piVar3;
size_t sVar4;
int *piVar5;
int4 *puVar6;
int8 uVar7;
long lVar8;
int8 uVar9;
ulong uVar10;
long local_60;
void *local_58;
long local_48;
size_t local_40;
local_48 = 0;
uVar10 = 0;
if ((param_5 & 0x1a) == 0) {
uVar10 = my_global_flags;
}
uVar10 = uVar10 | param_5;
piVar3 = __errno_location();
local_60 = param_4;
local_58 = param_2;
local_40 = param_3;
do {
while( true ) {
*piVar3 = 0;
sVar4 = pread64(param_1,local_58,local_40,local_60);
if (local_40 - sVar4 == 0) goto LAB_001a076d;
iVar1 = *piVar3;
piVar5 = (int *)_my_thread_var();
*piVar5 = iVar1;
if ((*piVar3 == 0) || (sVar4 != 0xffffffffffffffff && (uVar10 & 6) != 0)) {
puVar6 = (int4 *)_my_thread_var();
*puVar6 = 0xaf;
}
if (sVar4 + 1 < 2) break;
if (((uint)uVar10 >> 9 & 1) == 0) {
local_48 = 0;
goto LAB_001a071e;
}
local_58 = (void *)((long)local_58 + sVar4);
local_48 = local_48 + sVar4;
local_60 = local_60 + sVar4;
local_40 = local_40 - sVar4;
}
} while (*piVar3 == 4);
LAB_001a071e:
if ((uVar10 & 0x1a) == 0) {
LAB_001a0754:
lVar8 = -1;
if ((sVar4 != 0xffffffffffffffff) && (local_40 = sVar4, (uVar10 & 6) == 0)) {
LAB_001a076d:
lVar8 = 0;
if ((uVar10 & 6) == 0) {
lVar8 = local_48 + local_40;
}
}
}
else {
if (sVar4 == 0xffffffffffffffff) {
uVar7 = my_filename(param_1);
puVar6 = (int4 *)_my_thread_var();
uVar2 = *puVar6;
uVar9 = 2;
}
else {
if ((uVar10 & 6) == 0) goto LAB_001a0754;
uVar7 = my_filename(param_1);
puVar6 = (int4 *)_my_thread_var();
uVar2 = *puVar6;
uVar9 = 9;
}
my_error(uVar9,(uint)uVar10 & 0x440 | 4,uVar7,uVar2);
lVar8 = -1;
}
return lVar8;
}
|
|
64,845 |
my_strntoull_mb2_or_mb4
|
eloqsql/strings/ctype-ucs2.c
|
static ulonglong
my_strntoull_mb2_or_mb4(CHARSET_INFO *cs,
const char *nptr, size_t l, int base,
char **endptr, int *err)
{
int negative= 0;
int overflow;
int cnv;
my_wc_t wc;
my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc;
register ulonglong cutoff;
register unsigned int cutlim;
register ulonglong res;
register const uchar *s= (const uchar*) nptr;
register const uchar *e= (const uchar*) nptr + l;
const uchar *save;
*err= 0;
do
{
if ((cnv= mb_wc(cs, &wc, s, e)) > 0)
{
switch (wc)
{
case ' ' : break;
case '\t': break;
case '-' : negative= !negative; break;
case '+' : break;
default : goto bs;
}
}
else /* No more characters or bad multibyte sequence */
{
if (endptr !=NULL )
*endptr = (char*)s;
err[0]= (cnv==MY_CS_ILSEQ) ? EILSEQ : EDOM;
return 0;
}
s+=cnv;
} while (1);
bs:
overflow = 0;
res = 0;
save = s;
cutoff = (~(ulonglong) 0) / (unsigned long int) base;
cutlim = (uint) ((~(ulonglong) 0) % (unsigned long int) base);
do
{
if ((cnv= mb_wc(cs, &wc, s, e)) > 0)
{
s+=cnv;
if ( wc>='0' && wc<='9')
wc -= '0';
else if ( wc>='A' && wc<='Z')
wc = wc - 'A' + 10;
else if ( wc>='a' && wc<='z')
wc = wc - 'a' + 10;
else
break;
if ((int)wc >= base)
break;
if (res > cutoff || (res == cutoff && wc > cutlim))
overflow = 1;
else
{
res *= (ulonglong) base;
res += wc;
}
}
else if (cnv==MY_CS_ILSEQ)
{
if (endptr !=NULL )
*endptr = (char*)s;
err[0]= EILSEQ;
return 0;
}
else
{
/* No more characters */
break;
}
} while(1);
if (endptr != NULL)
*endptr = (char *) s;
if (s == save)
{
err[0]= EDOM;
return 0L;
}
if (overflow)
{
err[0]= ERANGE;
return (~(ulonglong) 0);
}
return (negative ? -((longlong) res) : (longlong) res);
}
|
O0
|
c
|
my_strntoull_mb2_or_mb4:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl %ecx, -0x24(%rbp)
movq %r8, -0x30(%rbp)
movq %r9, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
movq -0x10(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x18(%rbp), %rax
addq -0x20(%rbp), %rax
movq %rax, -0x80(%rbp)
movq -0x38(%rbp), %rax
movl $0x0, (%rax)
movq -0x58(%rbp), %rax
movq -0x10(%rbp), %rdi
movq -0x78(%rbp), %rdx
movq -0x80(%rbp), %rcx
leaq -0x50(%rbp), %rsi
callq *%rax
movl %eax, -0x44(%rbp)
cmpl $0x0, %eax
jle 0xbc301
movq -0x50(%rbp), %rax
addq $-0x9, %rax
movq %rax, -0x90(%rbp)
subq $0x24, %rax
ja 0xbc2fd
movq -0x90(%rbp), %rax
leaq 0x15a861(%rip), %rcx # 0x216b3c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
jmp 0xbc2ff
jmp 0xbc2ff
cmpl $0x0, -0x3c(%rbp)
setne %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x3c(%rbp)
jmp 0xbc2ff
jmp 0xbc2ff
jmp 0xbc358
jmp 0xbc339
cmpq $0x0, -0x30(%rbp)
je 0xbc313
movq -0x78(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
movl -0x44(%rbp), %edx
movl $0x21, %ecx
movl $0x54, %eax
cmpl $0x0, %edx
cmovel %eax, %ecx
movq -0x38(%rbp), %rax
movl %ecx, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0xbc53c
movl -0x44(%rbp), %ecx
movq -0x78(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x78(%rbp)
movb $0x1, %al
testb $0x1, %al
jne 0xbc29a
jmp 0xbc356
jmp 0xbc358
movl $0x0, -0x40(%rbp)
movq $0x0, -0x70(%rbp)
movq -0x78(%rbp), %rax
movq %rax, -0x88(%rbp)
movslq -0x24(%rbp), %rcx
movq $-0x1, %rax
xorl %edx, %edx
divq %rcx
movq %rax, -0x60(%rbp)
movslq -0x24(%rbp), %rcx
movq $-0x1, %rax
xorl %edx, %edx
divq %rcx
movl %edx, %eax
movl %eax, -0x64(%rbp)
movq -0x58(%rbp), %rax
movq -0x10(%rbp), %rdi
movq -0x78(%rbp), %rdx
movq -0x80(%rbp), %rcx
leaq -0x50(%rbp), %rsi
callq *%rax
movl %eax, -0x44(%rbp)
cmpl $0x0, %eax
jle 0xbc485
movl -0x44(%rbp), %ecx
movq -0x78(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x78(%rbp)
cmpq $0x30, -0x50(%rbp)
jb 0xbc3ea
cmpq $0x39, -0x50(%rbp)
ja 0xbc3ea
movq -0x50(%rbp), %rax
subq $0x30, %rax
movq %rax, -0x50(%rbp)
jmp 0xbc433
cmpq $0x41, -0x50(%rbp)
jb 0xbc40a
cmpq $0x5a, -0x50(%rbp)
ja 0xbc40a
movq -0x50(%rbp), %rax
subq $0x41, %rax
addq $0xa, %rax
movq %rax, -0x50(%rbp)
jmp 0xbc431
cmpq $0x61, -0x50(%rbp)
jb 0xbc42a
cmpq $0x7a, -0x50(%rbp)
ja 0xbc42a
movq -0x50(%rbp), %rax
subq $0x61, %rax
addq $0xa, %rax
movq %rax, -0x50(%rbp)
jmp 0xbc42f
jmp 0xbc4c4
jmp 0xbc431
jmp 0xbc433
movq -0x50(%rbp), %rax
cmpl -0x24(%rbp), %eax
jl 0xbc441
jmp 0xbc4c4
movq -0x70(%rbp), %rax
cmpq -0x60(%rbp), %rax
ja 0xbc461
movq -0x70(%rbp), %rax
cmpq -0x60(%rbp), %rax
jne 0xbc46a
movq -0x50(%rbp), %rax
movl -0x64(%rbp), %ecx
cmpq %rcx, %rax
jbe 0xbc46a
movl $0x1, -0x40(%rbp)
jmp 0xbc483
movslq -0x24(%rbp), %rax
imulq -0x70(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x50(%rbp), %rax
addq -0x70(%rbp), %rax
movq %rax, -0x70(%rbp)
jmp 0xbc4b6
cmpl $0x0, -0x44(%rbp)
jne 0xbc4b4
cmpq $0x0, -0x30(%rbp)
je 0xbc49d
movq -0x78(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
movq -0x38(%rbp), %rax
movl $0x54, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0xbc53c
jmp 0xbc4c4
jmp 0xbc4b8
movb $0x1, %al
testb $0x1, %al
jne 0xbc39b
jmp 0xbc4c4
cmpq $0x0, -0x30(%rbp)
je 0xbc4d6
movq -0x78(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
movq -0x78(%rbp), %rax
cmpq -0x88(%rbp), %rax
jne 0xbc4f7
movq -0x38(%rbp), %rax
movl $0x21, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0xbc53c
cmpl $0x0, -0x40(%rbp)
je 0xbc511
movq -0x38(%rbp), %rax
movl $0x22, (%rax)
movq $-0x1, -0x8(%rbp)
jmp 0xbc53c
cmpl $0x0, -0x3c(%rbp)
je 0xbc526
xorl %eax, %eax
subq -0x70(%rbp), %rax
movq %rax, -0x98(%rbp)
jmp 0xbc531
movq -0x70(%rbp), %rax
movq %rax, -0x98(%rbp)
movq -0x98(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0xa0, %rsp
popq %rbp
retq
nopl (%rax)
|
my_strntoull_mb2_or_mb4:
push rbp
mov rbp, rsp
sub rsp, 0A0h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_24], ecx
mov [rbp+var_30], r8
mov [rbp+var_38], r9
mov [rbp+var_3C], 0
mov rax, [rbp+var_10]
mov rax, [rax+0B8h]
mov rax, [rax+28h]
mov [rbp+var_58], rax
mov rax, [rbp+var_18]
mov [rbp+var_78], rax
mov rax, [rbp+var_18]
add rax, [rbp+var_20]
mov [rbp+var_80], rax
mov rax, [rbp+var_38]
mov dword ptr [rax], 0
loc_BC29A:
mov rax, [rbp+var_58]
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_78]
mov rcx, [rbp+var_80]
lea rsi, [rbp+var_50]
call rax
mov [rbp+var_44], eax
cmp eax, 0
jle short loc_BC301
mov rax, [rbp+var_50]
add rax, 0FFFFFFFFFFFFFFF7h; switch 37 cases
mov [rbp+var_90], rax
sub rax, 24h
ja short def_BC2E2; jumptable 00000000000BC2E2 default case, cases 10-31,33-42,44
mov rax, [rbp+var_90]
lea rcx, jpt_BC2E2
movsxd rax, ds:(jpt_BC2E2 - 216B3Ch)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_BC2E4:
jmp short loc_BC2FF; jumptable 00000000000BC2E2 case 32
loc_BC2E6:
jmp short loc_BC2FF; jumptable 00000000000BC2E2 case 9
loc_BC2E8:
cmp [rbp+var_3C], 0; jumptable 00000000000BC2E2 case 45
setnz al
xor al, 0FFh
and al, 1
movzx eax, al
mov [rbp+var_3C], eax
jmp short loc_BC2FF
loc_BC2FB:
jmp short loc_BC2FF; jumptable 00000000000BC2E2 case 43
def_BC2E2:
jmp short loc_BC358; jumptable 00000000000BC2E2 default case, cases 10-31,33-42,44
loc_BC2FF:
jmp short loc_BC339
loc_BC301:
cmp [rbp+var_30], 0
jz short loc_BC313
mov rcx, [rbp+var_78]
mov rax, [rbp+var_30]
mov [rax], rcx
loc_BC313:
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_BC53C
loc_BC339:
mov ecx, [rbp+var_44]
mov rax, [rbp+var_78]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_78], rax
mov al, 1
test al, 1
jnz loc_BC29A
jmp short $+2
loc_BC356:
jmp short $+2
loc_BC358:
mov [rbp+var_40], 0
mov [rbp+var_70], 0
mov rax, [rbp+var_78]
mov [rbp+var_88], rax
movsxd rcx, [rbp+var_24]
mov rax, 0FFFFFFFFFFFFFFFFh
xor edx, edx
div rcx
mov [rbp+var_60], rax
movsxd rcx, [rbp+var_24]
mov rax, 0FFFFFFFFFFFFFFFFh
xor edx, edx
div rcx
mov eax, edx
mov [rbp+var_64], eax
loc_BC39B:
mov rax, [rbp+var_58]
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_78]
mov rcx, [rbp+var_80]
lea rsi, [rbp+var_50]
call rax
mov [rbp+var_44], eax
cmp eax, 0
jle loc_BC485
mov ecx, [rbp+var_44]
mov rax, [rbp+var_78]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_78], rax
cmp [rbp+var_50], 30h ; '0'
jb short loc_BC3EA
cmp [rbp+var_50], 39h ; '9'
ja short loc_BC3EA
mov rax, [rbp+var_50]
sub rax, 30h ; '0'
mov [rbp+var_50], rax
jmp short loc_BC433
loc_BC3EA:
cmp [rbp+var_50], 41h ; 'A'
jb short loc_BC40A
cmp [rbp+var_50], 5Ah ; 'Z'
ja short loc_BC40A
mov rax, [rbp+var_50]
sub rax, 41h ; 'A'
add rax, 0Ah
mov [rbp+var_50], rax
jmp short loc_BC431
loc_BC40A:
cmp [rbp+var_50], 61h ; 'a'
jb short loc_BC42A
cmp [rbp+var_50], 7Ah ; 'z'
ja short loc_BC42A
mov rax, [rbp+var_50]
sub rax, 61h ; 'a'
add rax, 0Ah
mov [rbp+var_50], rax
jmp short loc_BC42F
loc_BC42A:
jmp loc_BC4C4
loc_BC42F:
jmp short $+2
loc_BC431:
jmp short $+2
loc_BC433:
mov rax, [rbp+var_50]
cmp eax, [rbp+var_24]
jl short loc_BC441
jmp loc_BC4C4
loc_BC441:
mov rax, [rbp+var_70]
cmp rax, [rbp+var_60]
ja short loc_BC461
mov rax, [rbp+var_70]
cmp rax, [rbp+var_60]
jnz short loc_BC46A
mov rax, [rbp+var_50]
mov ecx, [rbp+var_64]
cmp rax, rcx
jbe short loc_BC46A
loc_BC461:
mov [rbp+var_40], 1
jmp short loc_BC483
loc_BC46A:
movsxd rax, [rbp+var_24]
imul rax, [rbp+var_70]
mov [rbp+var_70], rax
mov rax, [rbp+var_50]
add rax, [rbp+var_70]
mov [rbp+var_70], rax
loc_BC483:
jmp short loc_BC4B6
loc_BC485:
cmp [rbp+var_44], 0
jnz short loc_BC4B4
cmp [rbp+var_30], 0
jz short loc_BC49D
mov rcx, [rbp+var_78]
mov rax, [rbp+var_30]
mov [rax], rcx
loc_BC49D:
mov rax, [rbp+var_38]
mov dword ptr [rax], 54h ; 'T'
mov [rbp+var_8], 0
jmp loc_BC53C
loc_BC4B4:
jmp short loc_BC4C4
loc_BC4B6:
jmp short $+2
loc_BC4B8:
mov al, 1
test al, 1
jnz loc_BC39B
jmp short $+2
loc_BC4C4:
cmp [rbp+var_30], 0
jz short loc_BC4D6
mov rcx, [rbp+var_78]
mov rax, [rbp+var_30]
mov [rax], rcx
loc_BC4D6:
mov rax, [rbp+var_78]
cmp rax, [rbp+var_88]
jnz short loc_BC4F7
mov rax, [rbp+var_38]
mov dword ptr [rax], 21h ; '!'
mov [rbp+var_8], 0
jmp short loc_BC53C
loc_BC4F7:
cmp [rbp+var_40], 0
jz short loc_BC511
mov rax, [rbp+var_38]
mov dword ptr [rax], 22h ; '"'
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp short loc_BC53C
loc_BC511:
cmp [rbp+var_3C], 0
jz short loc_BC526
xor eax, eax
sub rax, [rbp+var_70]
mov [rbp+var_98], rax
jmp short loc_BC531
loc_BC526:
mov rax, [rbp+var_70]
mov [rbp+var_98], rax
loc_BC531:
mov rax, [rbp+var_98]
mov [rbp+var_8], rax
loc_BC53C:
mov rax, [rbp+var_8]
add rsp, 0A0h
pop rbp
retn
|
long long my_strntoull_mb2_or_mb4(long long a1, long long a2, long long a3, int a4, _QWORD *a5, int *a6)
{
int v6; // ecx
long long v9; // [rsp+18h] [rbp-88h]
long long v10; // [rsp+20h] [rbp-80h]
long long v11; // [rsp+28h] [rbp-78h]
unsigned long long v12; // [rsp+30h] [rbp-70h]
unsigned int v13; // [rsp+3Ch] [rbp-64h]
unsigned long long v14; // [rsp+40h] [rbp-60h]
long long ( *v15)(long long, unsigned long long *, long long, long long); // [rsp+48h] [rbp-58h]
unsigned long long v16; // [rsp+50h] [rbp-50h] BYREF
int v17; // [rsp+5Ch] [rbp-44h]
int v18; // [rsp+60h] [rbp-40h]
BOOL v19; // [rsp+64h] [rbp-3Ch]
int *v20; // [rsp+68h] [rbp-38h]
_QWORD *v21; // [rsp+70h] [rbp-30h]
int v22; // [rsp+7Ch] [rbp-24h]
long long v23; // [rsp+80h] [rbp-20h]
long long v24; // [rsp+88h] [rbp-18h]
long long v25; // [rsp+90h] [rbp-10h]
v25 = a1;
v24 = a2;
v23 = a3;
v22 = a4;
v21 = a5;
v20 = a6;
v19 = 0;
v15 = *(long long ( **)(long long, unsigned long long *, long long, long long))(*(_QWORD *)(a1 + 184) + 40LL);
v11 = a2;
v10 = a3 + a2;
*a6 = 0;
while ( 2 )
{
v17 = v15(v25, &v16, v11, v10);
if ( v17 <= 0 )
{
if ( v21 )
*v21 = v11;
v6 = 33;
if ( !v17 )
v6 = 84;
*v20 = v6;
return 0LL;
}
else
{
switch ( v16 )
{
case 9uLL:
case 0x20uLL:
case 0x2BuLL:
goto LABEL_10;
case 0x2DuLL:
v19 = !v19;
LABEL_10:
v11 += v17;
continue;
default:
v18 = 0;
v12 = 0LL;
v9 = v11;
v14 = 0xFFFFFFFFFFFFFFFFLL / v22;
v13 = 0xFFFFFFFFFFFFFFFFLL % v22;
break;
}
while ( 1 )
{
v17 = v15(v25, &v16, v11, v10);
if ( v17 <= 0 )
break;
v11 += v17;
if ( v16 < 0x30 || v16 > 0x39 )
{
if ( v16 < 0x41 || v16 > 0x5A )
{
if ( v16 < 0x61 || v16 > 0x7A )
goto LABEL_33;
v16 = v16 - 97 + 10;
}
else
{
v16 = v16 - 65 + 10;
}
}
else
{
v16 -= 48LL;
}
if ( (int)v16 >= v22 )
goto LABEL_33;
if ( v12 > v14 || v12 == v14 && v16 > v13 )
v18 = 1;
else
v12 = v12 * v22 + v16;
}
if ( v17 )
{
LABEL_33:
if ( v21 )
*v21 = v11;
if ( v11 == v9 )
{
*v20 = 33;
return 0LL;
}
else if ( v18 )
{
*v20 = 34;
return -1LL;
}
else if ( v19 )
{
return -(long long)v12;
}
else
{
return v12;
}
}
if ( v21 )
*v21 = v11;
*v20 = 84;
return 0LL;
}
}
}
|
my_strntoull_mb2_or_mb4:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xa0
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x24],ECX
MOV qword ptr [RBP + -0x30],R8
MOV qword ptr [RBP + -0x38],R9
MOV dword ptr [RBP + -0x3c],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x78],RAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x80],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x0
LAB_001bc29a:
MOV RAX,qword ptr [RBP + -0x58]
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x78]
MOV RCX,qword ptr [RBP + -0x80]
LEA RSI,[RBP + -0x50]
CALL RAX
MOV dword ptr [RBP + -0x44],EAX
CMP EAX,0x0
JLE 0x001bc301
MOV RAX,qword ptr [RBP + -0x50]
ADD RAX,-0x9
MOV qword ptr [RBP + -0x90],RAX
SUB RAX,0x24
JA 0x001bc2fd
MOV RAX,qword ptr [RBP + -0x90]
LEA RCX,[0x316b3c]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_20:
JMP 0x001bc2ff
caseD_9:
JMP 0x001bc2ff
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 0x001bc2ff
caseD_2b:
JMP 0x001bc2ff
caseD_a:
JMP 0x001bc358
LAB_001bc2ff:
JMP 0x001bc339
LAB_001bc301:
CMP qword ptr [RBP + -0x30],0x0
JZ 0x001bc313
MOV RCX,qword ptr [RBP + -0x78]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
LAB_001bc313:
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 0x001bc53c
LAB_001bc339:
MOV ECX,dword ptr [RBP + -0x44]
MOV RAX,qword ptr [RBP + -0x78]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x78],RAX
MOV AL,0x1
TEST AL,0x1
JNZ 0x001bc29a
JMP 0x001bc356
LAB_001bc356:
JMP 0x001bc358
LAB_001bc358:
MOV dword ptr [RBP + -0x40],0x0
MOV qword ptr [RBP + -0x70],0x0
MOV RAX,qword ptr [RBP + -0x78]
MOV qword ptr [RBP + -0x88],RAX
MOVSXD RCX,dword ptr [RBP + -0x24]
MOV RAX,-0x1
XOR EDX,EDX
DIV RCX
MOV qword ptr [RBP + -0x60],RAX
MOVSXD RCX,dword ptr [RBP + -0x24]
MOV RAX,-0x1
XOR EDX,EDX
DIV RCX
MOV EAX,EDX
MOV dword ptr [RBP + -0x64],EAX
LAB_001bc39b:
MOV RAX,qword ptr [RBP + -0x58]
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x78]
MOV RCX,qword ptr [RBP + -0x80]
LEA RSI,[RBP + -0x50]
CALL RAX
MOV dword ptr [RBP + -0x44],EAX
CMP EAX,0x0
JLE 0x001bc485
MOV ECX,dword ptr [RBP + -0x44]
MOV RAX,qword ptr [RBP + -0x78]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x78],RAX
CMP qword ptr [RBP + -0x50],0x30
JC 0x001bc3ea
CMP qword ptr [RBP + -0x50],0x39
JA 0x001bc3ea
MOV RAX,qword ptr [RBP + -0x50]
SUB RAX,0x30
MOV qword ptr [RBP + -0x50],RAX
JMP 0x001bc433
LAB_001bc3ea:
CMP qword ptr [RBP + -0x50],0x41
JC 0x001bc40a
CMP qword ptr [RBP + -0x50],0x5a
JA 0x001bc40a
MOV RAX,qword ptr [RBP + -0x50]
SUB RAX,0x41
ADD RAX,0xa
MOV qword ptr [RBP + -0x50],RAX
JMP 0x001bc431
LAB_001bc40a:
CMP qword ptr [RBP + -0x50],0x61
JC 0x001bc42a
CMP qword ptr [RBP + -0x50],0x7a
JA 0x001bc42a
MOV RAX,qword ptr [RBP + -0x50]
SUB RAX,0x61
ADD RAX,0xa
MOV qword ptr [RBP + -0x50],RAX
JMP 0x001bc42f
LAB_001bc42a:
JMP 0x001bc4c4
LAB_001bc42f:
JMP 0x001bc431
LAB_001bc431:
JMP 0x001bc433
LAB_001bc433:
MOV RAX,qword ptr [RBP + -0x50]
CMP EAX,dword ptr [RBP + -0x24]
JL 0x001bc441
JMP 0x001bc4c4
LAB_001bc441:
MOV RAX,qword ptr [RBP + -0x70]
CMP RAX,qword ptr [RBP + -0x60]
JA 0x001bc461
MOV RAX,qword ptr [RBP + -0x70]
CMP RAX,qword ptr [RBP + -0x60]
JNZ 0x001bc46a
MOV RAX,qword ptr [RBP + -0x50]
MOV ECX,dword ptr [RBP + -0x64]
CMP RAX,RCX
JBE 0x001bc46a
LAB_001bc461:
MOV dword ptr [RBP + -0x40],0x1
JMP 0x001bc483
LAB_001bc46a:
MOVSXD RAX,dword ptr [RBP + -0x24]
IMUL RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RBP + -0x70],RAX
MOV RAX,qword ptr [RBP + -0x50]
ADD RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RBP + -0x70],RAX
LAB_001bc483:
JMP 0x001bc4b6
LAB_001bc485:
CMP dword ptr [RBP + -0x44],0x0
JNZ 0x001bc4b4
CMP qword ptr [RBP + -0x30],0x0
JZ 0x001bc49d
MOV RCX,qword ptr [RBP + -0x78]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
LAB_001bc49d:
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x54
MOV qword ptr [RBP + -0x8],0x0
JMP 0x001bc53c
LAB_001bc4b4:
JMP 0x001bc4c4
LAB_001bc4b6:
JMP 0x001bc4b8
LAB_001bc4b8:
MOV AL,0x1
TEST AL,0x1
JNZ 0x001bc39b
JMP 0x001bc4c4
LAB_001bc4c4:
CMP qword ptr [RBP + -0x30],0x0
JZ 0x001bc4d6
MOV RCX,qword ptr [RBP + -0x78]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
LAB_001bc4d6:
MOV RAX,qword ptr [RBP + -0x78]
CMP RAX,qword ptr [RBP + -0x88]
JNZ 0x001bc4f7
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x21
MOV qword ptr [RBP + -0x8],0x0
JMP 0x001bc53c
LAB_001bc4f7:
CMP dword ptr [RBP + -0x40],0x0
JZ 0x001bc511
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX],0x22
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x001bc53c
LAB_001bc511:
CMP dword ptr [RBP + -0x3c],0x0
JZ 0x001bc526
XOR EAX,EAX
SUB RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RBP + -0x98],RAX
JMP 0x001bc531
LAB_001bc526:
MOV RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RBP + -0x98],RAX
LAB_001bc531:
MOV RAX,qword ptr [RBP + -0x98]
MOV qword ptr [RBP + -0x8],RAX
LAB_001bc53c:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0xa0
POP RBP
RET
|
/* WARNING: Removing unreachable block (ram,0x001bc354) */
/* WARNING: Removing unreachable block (ram,0x001bc4c2) */
ulong my_strntoull_mb2_or_mb4
(long param_1,long param_2,long param_3,int param_4,long *param_5,
int4 *param_6)
{
code *pcVar1;
int1 auVar2 [16];
int1 auVar3 [16];
long lVar4;
ulong uVar5;
int4 uVar6;
ulong local_a0;
long local_80;
ulong local_78;
ulong local_58;
int local_4c;
int local_48;
uint local_44;
int4 *local_40;
long *local_38;
int local_2c;
long local_28;
long local_20;
long local_18;
ulong local_10;
local_44 = 0;
pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28);
*param_6 = 0;
local_80 = param_2;
local_40 = param_6;
local_38 = param_5;
local_2c = param_4;
local_28 = param_3;
local_20 = param_2;
local_18 = param_1;
do {
lVar4 = local_80;
local_4c = (*pcVar1)(local_18,&local_58,local_80,param_2 + param_3);
if (local_4c < 1) {
if (local_38 != (long *)0x0) {
*local_38 = local_80;
}
uVar6 = 0x21;
if (local_4c == 0) {
uVar6 = 0x54;
}
*local_40 = uVar6;
return 0;
}
switch(local_58) {
case 9:
break;
default:
local_48 = 0;
local_78 = 0;
auVar2._8_8_ = 0;
auVar2._0_8_ = (long)local_2c;
uVar5 = SUB168((ZEXT816(0) << 0x40 | ZEXT816(0xffffffffffffffff)) / auVar2,0);
auVar3._8_8_ = 0;
auVar3._0_8_ = (long)local_2c;
goto LAB_001bc39b;
case 0x20:
break;
case 0x2b:
break;
case 0x2d:
local_44 = (uint)((local_44 != 0 ^ 0xffU) & 1);
}
local_80 = local_80 + local_4c;
} while( true );
LAB_001bc39b:
local_4c = (*pcVar1)(local_18,&local_58,local_80,param_2 + param_3);
if (local_4c < 1) {
if (local_4c == 0) {
if (local_38 != (long *)0x0) {
*local_38 = local_80;
}
*local_40 = 0x54;
local_10 = 0;
}
else {
LAB_001bc4c4:
if (local_38 != (long *)0x0) {
*local_38 = local_80;
}
if (local_80 == lVar4) {
*local_40 = 0x21;
local_10 = 0;
}
else if (local_48 == 0) {
if (local_44 == 0) {
local_a0 = local_78;
}
else {
local_a0 = -local_78;
}
local_10 = local_a0;
}
else {
*local_40 = 0x22;
local_10 = 0xffffffffffffffff;
}
}
return local_10;
}
local_80 = local_80 + local_4c;
if ((local_58 < 0x30) || (0x39 < local_58)) {
if ((local_58 < 0x41) || (0x5a < local_58)) {
if ((local_58 < 0x61) || (0x7a < local_58)) goto LAB_001bc4c4;
local_58 = local_58 - 0x57;
}
else {
local_58 = local_58 - 0x37;
}
}
else {
local_58 = local_58 - 0x30;
}
if (local_2c <= (int)local_58) goto LAB_001bc4c4;
if ((uVar5 < local_78) ||
((local_78 == uVar5 &&
(SUB164((ZEXT816(0) << 0x40 | ZEXT816(0xffffffffffffffff)) % auVar3,0) < local_58)))) {
local_48 = 1;
}
else {
local_78 = local_58 + (long)local_2c * local_78;
}
goto LAB_001bc39b;
}
|
|
64,846 |
js_symbol_for
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue js_symbol_for(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
JSValue str;
str = JS_ToString(ctx, argv[0]);
if (JS_IsException(str))
return JS_EXCEPTION;
return JS_NewSymbolInternal(ctx, JS_VALUE_GET_STRING(str), JS_ATOM_TYPE_GLOBAL_SYMBOL);
}
|
O1
|
c
|
js_symbol_for:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movq (%r8), %rsi
movq 0x8(%r8), %rdx
xorl %ebx, %ebx
xorl %ecx, %ecx
callq 0x27add
movq %rax, (%rsp)
cmpl $0x6, %edx
jne 0x7e7f4
movl $0x6, %edx
jmp 0x7e808
movq (%rsp), %rsi
movq %r14, %rdi
movl $0x2, %edx
callq 0x3bc1f
movq %rax, %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
|
js_symbol_for:
push r14
push rbx
push rax
mov r14, rdi
mov rsi, [r8]
mov rdx, [r8+8]
xor ebx, ebx
xor ecx, ecx
call JS_ToStringInternal
mov [rsp+18h+var_18], rax
cmp edx, 6
jnz short loc_7E7F4
mov edx, 6
jmp short loc_7E808
loc_7E7F4:
mov rsi, [rsp+18h+var_18]
mov rdi, r14
mov edx, 2
call JS_NewSymbolInternal
mov rbx, rax
loc_7E808:
mov rax, rbx
add rsp, 8
pop rbx
pop r14
retn
|
long long js_symbol_for(
long long a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
long long a10,
long long a11,
long long a12,
long long *a13,
long long a14)
{
long long v14; // rbx
int v15; // edx
unsigned long long v17; // [rsp+0h] [rbp-18h]
v14 = 0LL;
v17 = JS_ToStringInternal(a1, *a13, a13[1], 0, (long long)a13, a14, a2, a3, a4, a5, a6, a7, a8, a9);
if ( v15 != 6 )
return JS_NewSymbolInternal(a1, v17, 2LL);
return v14;
}
|
js_symbol_for:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RDI
MOV RSI,qword ptr [R8]
MOV RDX,qword ptr [R8 + 0x8]
XOR EBX,EBX
XOR ECX,ECX
CALL 0x00127add
MOV qword ptr [RSP],RAX
CMP EDX,0x6
JNZ 0x0017e7f4
MOV EDX,0x6
JMP 0x0017e808
LAB_0017e7f4:
MOV RSI,qword ptr [RSP]
MOV RDI,R14
MOV EDX,0x2
CALL 0x0013bc1f
MOV RBX,RAX
LAB_0017e808:
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R14
RET
|
int8 js_symbol_for(int8 param_1)
{
int8 uVar1;
int8 *in_R8;
int1 auVar2 [12];
uVar1 = 0;
auVar2 = JS_ToStringInternal(param_1,*in_R8,in_R8[1],0);
if (auVar2._8_4_ != 6) {
uVar1 = JS_NewSymbolInternal(param_1,auVar2._0_8_,2);
}
return uVar1;
}
|
|
64,847 |
stbi__check_png_header(stbi__context*)
|
llama.cpp/examples/llava/../../common/stb_image.h
|
static int stbi__check_png_header(stbi__context *s)
{
static const stbi_uc png_sig[8] = { 137,80,78,71,13,10,26,10 };
int i;
for (i=0; i < 8; ++i)
if (stbi__get8(s) != png_sig[i]) return stbi__err("bad png sig","Not a PNG");
return 1;
}
|
O3
|
c
|
stbi__check_png_header(stbi__context*):
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq 0xc0(%rdi), %rax
xorl %r14d, %r14d
leaq 0x1f8a7(%rip), %r15 # 0x46000
cmpq 0xc8(%rbx), %rax
jb 0x26777
cmpl $0x0, 0x30(%rbx)
je 0x26798
movq %rbx, %rdi
callq 0x26801
movq 0xc0(%rbx), %rax
leaq 0x1(%rax), %rdx
movq %rdx, 0xc0(%rbx)
movb (%rax), %cl
movq %rdx, %rax
cmpb (%r14,%r15), %cl
jne 0x2679c
incq %r14
cmpq $0x8, %r14
jne 0x26759
jmp 0x267ba
xorl %ecx, %ecx
jmp 0x26787
movq %fs:0x0, %rax
leaq 0x1fd02(%rip), %rcx # 0x464b1
movq %rcx, -0x20(%rax)
xorl %eax, %eax
jmp 0x267bf
movl $0x1, %eax
popq %rbx
popq %r14
popq %r15
retq
|
_ZL22stbi__check_png_headerP13stbi__context:
push r15
push r14
push rbx
mov rbx, rdi
mov rax, [rdi+0C0h]
xor r14d, r14d
lea r15, _ZZL22stbi__check_png_headerP13stbi__contextE7png_sig; stbi__check_png_header(stbi__context *)::png_sig
loc_26759:
cmp rax, [rbx+0C8h]
jb short loc_26777
cmp dword ptr [rbx+30h], 0
jz short loc_26798
mov rdi, rbx
call _ZL19stbi__refill_bufferP13stbi__context; stbi__refill_buffer(stbi__context *)
mov rax, [rbx+0C0h]
loc_26777:
lea rdx, [rax+1]
mov [rbx+0C0h], rdx
mov cl, [rax]
mov rax, rdx
loc_26787:
cmp cl, [r14+r15]
jnz short loc_2679C
inc r14
cmp r14, 8
jnz short loc_26759
jmp short loc_267BA
loc_26798:
xor ecx, ecx
jmp short loc_26787
loc_2679C:
mov rax, fs:0
lea rcx, aBadPngSig; "bad png sig"
mov [rax-20h], rcx
xor eax, eax
jmp short loc_267BF
loc_267BA:
mov eax, 1
loc_267BF:
pop rbx
pop r14
pop r15
retn
|
long long stbi__check_png_header(long long a1)
{
char *v1; // rax
long long v2; // r14
char v3; // cl
v1 = *(char **)(a1 + 192);
v2 = 0LL;
while ( 1 )
{
if ( (unsigned long long)v1 < *(_QWORD *)(a1 + 200) )
goto LABEL_5;
if ( *(_DWORD *)(a1 + 48) )
{
stbi__refill_buffer(a1);
v1 = *(char **)(a1 + 192);
LABEL_5:
*(_QWORD *)(a1 + 192) = v1 + 1;
v3 = *v1++;
goto LABEL_6;
}
v3 = 0;
LABEL_6:
if ( v3 != stbi__check_png_header(stbi__context *)::png_sig[v2] )
break;
if ( ++v2 == 8 )
return 1LL;
}
*(_QWORD *)(__readfsqword(0) - 32) = "bad png sig";
return 0LL;
}
|
stbi__check_png_header:
PUSH R15
PUSH R14
PUSH RBX
MOV RBX,RDI
MOV RAX,qword ptr [RDI + 0xc0]
XOR R14D,R14D
LEA R15,[0x146000]
LAB_00126759:
CMP RAX,qword ptr [RBX + 0xc8]
JC 0x00126777
CMP dword ptr [RBX + 0x30],0x0
JZ 0x00126798
MOV RDI,RBX
CALL 0x00126801
MOV RAX,qword ptr [RBX + 0xc0]
LAB_00126777:
LEA RDX,[RAX + 0x1]
MOV qword ptr [RBX + 0xc0],RDX
MOV CL,byte ptr [RAX]
MOV RAX,RDX
LAB_00126787:
CMP CL,byte ptr [R14 + R15*0x1]
JNZ 0x0012679c
INC R14
CMP R14,0x8
JNZ 0x00126759
JMP 0x001267ba
LAB_00126798:
XOR ECX,ECX
JMP 0x00126787
LAB_0012679c:
MOV RAX,qword ptr FS:[0x0]
LEA RCX,[0x1464b1]
MOV qword ptr [RAX + -0x20],RCX
XOR EAX,EAX
JMP 0x001267bf
LAB_001267ba:
MOV EAX,0x1
LAB_001267bf:
POP RBX
POP R14
POP R15
RET
|
/* stbi__check_png_header(stbi__context*) */
int8 stbi__check_png_header(stbi__context *param_1)
{
char *pcVar1;
char cVar2;
long lVar3;
long *in_FS_OFFSET;
pcVar1 = *(char **)(param_1 + 0xc0);
lVar3 = 0;
do {
if (pcVar1 < *(char **)(param_1 + 200)) {
LAB_00126777:
*(char **)(param_1 + 0xc0) = pcVar1 + 1;
cVar2 = *pcVar1;
pcVar1 = pcVar1 + 1;
}
else {
if (*(int *)(param_1 + 0x30) != 0) {
stbi__refill_buffer(param_1);
pcVar1 = *(char **)(param_1 + 0xc0);
goto LAB_00126777;
}
cVar2 = '\0';
}
if (cVar2 != (&stbi__check_png_header(stbi__context*)::png_sig)[lVar3]) {
*(char **)(*in_FS_OFFSET + -0x20) = "bad png sig";
return 0;
}
lVar3 = lVar3 + 1;
if (lVar3 == 8) {
return 1;
}
} while( true );
}
|
|
64,848 |
nglog::ColoredWriteToStderrOrStdout(_IO_FILE*, nglog::LogSeverity, char const*, unsigned long)
|
ng-log[P]ng-log/src/logging.cc
|
static void ColoredWriteToStderrOrStdout(FILE* output, LogSeverity severity,
const char* message, size_t len) {
bool is_stdout = (output == stdout);
const GLogColor color = (LogDestination::terminal_supports_color() &&
((!is_stdout && FLAGS_colorlogtostderr) ||
(is_stdout && FLAGS_colorlogtostdout)))
? SeverityToColor(severity)
: COLOR_DEFAULT;
// Avoid using cerr from this module since we may get called during
// exit code, and cerr may be partially or fully destroyed by then.
if (COLOR_DEFAULT == color) {
fwrite(message, len, 1, output);
return;
}
#ifdef NGLOG_OS_WINDOWS
const HANDLE output_handle =
GetStdHandle(is_stdout ? STD_OUTPUT_HANDLE : STD_ERROR_HANDLE);
// Gets the current text color.
CONSOLE_SCREEN_BUFFER_INFO buffer_info;
GetConsoleScreenBufferInfo(output_handle, &buffer_info);
const WORD old_color_attrs = buffer_info.wAttributes;
// We need to flush the stream buffers into the console before each
// SetConsoleTextAttribute call lest it affect the text that is already
// printed but has not yet reached the console.
fflush(output);
SetConsoleTextAttribute(output_handle,
GetColorAttribute(color) | FOREGROUND_INTENSITY);
fwrite(message, len, 1, output);
fflush(output);
// Restores the text color.
SetConsoleTextAttribute(output_handle, old_color_attrs);
#else
fprintf(output, "\033[0;3%sm", GetAnsiColorCode(color));
fwrite(message, len, 1, output);
fprintf(output, "\033[m"); // Resets the terminal to default.
#endif // NGLOG_OS_WINDOWS
}
|
O1
|
cpp
|
nglog::ColoredWriteToStderrOrStdout(_IO_FILE*, nglog::LogSeverity, char const*, unsigned long):
pushq %r15
pushq %r14
pushq %rbx
movq %rcx, %r14
movq %rdx, %r15
movq %rdi, %rbx
xorl %eax, %eax
cmpb $0x1, 0x1f63c(%rip) # 0x2fb90
jne 0x10591
movq 0x1e9c3(%rip), %rcx # 0x2ef20
cmpq %rbx, (%rcx)
je 0x10570
leaq 0x1f425(%rip), %rcx # 0x2f98e
cmpb $0x0, (%rcx)
jne 0x1057c
jmp 0x10591
leaq 0x1f419(%rip), %rcx # 0x2f990
cmpb $0x1, (%rcx)
jne 0x10591
cmpl $0x4, %esi
jae 0x1060b
movl %esi, %eax
leaq 0x11f42(%rip), %rcx # 0x224d0
movl (%rcx,%rax,4), %eax
movl %eax, %eax
leaq 0x11f46(%rip), %rcx # 0x224e0
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl $0x1, %edx
movq %r15, %rdi
movq %r14, %rsi
jmp 0x105fe
leaq 0x122ee(%rip), %rdx # 0x228a5
jmp 0x105c9
leaq 0x12dca(%rip), %rdx # 0x2338a
jmp 0x105c9
leaq 0x122cc(%rip), %rdx # 0x22895
leaq 0x12624(%rip), %rsi # 0x22bf4
movq %rbx, %rdi
xorl %eax, %eax
callq 0x77d0
movl $0x1, %edx
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rcx
callq 0x7a10
leaq 0x12609(%rip), %rdi # 0x22bfd
movl $0x3, %esi
movl $0x1, %edx
movq %rbx, %rcx
popq %rbx
popq %r14
popq %r15
jmp 0x7a10
leaq 0x11acf(%rip), %rdi # 0x220e1
leaq 0x12099(%rip), %rsi # 0x226b2
leaq 0x125e1(%rip), %rcx # 0x22c01
movl $0xeb, %edx
callq 0x7330
|
_ZN5nglogL28ColoredWriteToStderrOrStdoutEP8_IO_FILENS_11LogSeverityEPKcm:
push r15
push r14
push rbx
mov r14, rcx
mov r15, rdx
mov rbx, rdi
xor eax, eax
cmp cs:_ZN5nglog14LogDestination24terminal_supports_color_E, 1; nglog::LogDestination::terminal_supports_color_
jnz short loc_10591
mov rcx, cs:stdout_ptr
cmp [rcx], rbx
jz short loc_10570
lea rcx, _ZN3fLB22FLAGS_colorlogtostderrE; fLB::FLAGS_colorlogtostderr
cmp byte ptr [rcx], 0
jnz short loc_1057C
jmp short loc_10591
loc_10570:
lea rcx, _ZN3fLB22FLAGS_colorlogtostdoutE; fLB::FLAGS_colorlogtostdout
cmp byte ptr [rcx], 1
jnz short loc_10591
loc_1057C:
cmp esi, 4
jnb loc_1060B
mov eax, esi
lea rcx, unk_224D0
mov eax, [rcx+rax*4]
loc_10591:
mov eax, eax
lea rcx, jpt_105A1
movsxd rax, ds:(jpt_105A1 - 224E0h)[rcx+rax*4]; switch 4 cases
add rax, rcx
jmp rax; switch jump
loc_105A3:
mov edx, 1; jumptable 00000000000105A1 case 0
mov rdi, r15
mov rsi, r14
jmp short loc_105FE
loc_105B0:
lea rdx, aProcSelfFd2+0Eh; jumptable 00000000000105A1 case 2
jmp short loc_105C9
loc_105B9:
lea rdx, aDc3+2; jumptable 00000000000105A1 case 3
jmp short loc_105C9
loc_105C2:
lea rdx, aProcSelfFd1+0Eh; jumptable 00000000000105A1 case 1
loc_105C9:
lea rsi, a03Sm; "\x1B[0;3%sm"
mov rdi, rbx
xor eax, eax
call _fprintf
mov edx, 1
mov rdi, r15
mov rsi, r14
mov rcx, rbx
call _fwrite
lea rdi, aM; "\x1B[m"
mov esi, 3
mov edx, 1
loc_105FE:
mov rcx, rbx
pop rbx
pop r14
pop r15
jmp _fwrite
loc_1060B:
lea rdi, aFalse; "false"
lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aGlogcolorNglog; "GLogColor nglog::SeverityToColor(LogSev"...
mov edx, 0EBh
call ___assert_fail
|
long long nglog::ColoredWriteToStderrOrStdout(long long a1, unsigned int a2, const char *a3, long long a4)
{
int v7; // eax
const char *v8; // rdi
long long v9; // rsi
const char *v10; // rdx
v7 = 0;
if ( nglog::LogDestination::terminal_supports_color_ != 1 )
goto LABEL_8;
if ( stdout == a1 )
{
if ( fLB::FLAGS_colorlogtostdout != 1 )
goto LABEL_8;
}
else if ( !fLB::FLAGS_colorlogtostderr )
{
goto LABEL_8;
}
if ( a2 >= 4 )
__assert_fail(
"false",
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",
235LL,
"GLogColor nglog::SeverityToColor(LogSeverity)");
v7 = dword_224D0[a2];
LABEL_8:
switch ( v7 )
{
case 0:
v8 = a3;
v9 = a4;
return fwrite(v8, v9, 1LL, a1);
case 1:
v10 = "1";
goto LABEL_13;
case 2:
v10 = "2";
goto LABEL_13;
case 3:
v10 = "3";
LABEL_13:
fprintf(a1, "\x1B[0;3%sm", v10);
fwrite(a3, a4, 1LL, a1);
v8 = "\x1B[m";
v9 = 3LL;
return fwrite(v8, v9, 1LL, a1);
}
}
|
ColoredWriteToStderrOrStdout:
PUSH R15
PUSH R14
PUSH RBX
MOV R14,RCX
MOV R15,RDX
MOV RBX,RDI
XOR EAX,EAX
CMP byte ptr [0x0012fb90],0x1
JNZ 0x00110591
MOV RCX,qword ptr [0x0012ef20]
CMP qword ptr [RCX],RBX
JZ 0x00110570
LEA RCX,[0x12f98e]
CMP byte ptr [RCX],0x0
JNZ 0x0011057c
JMP 0x00110591
LAB_00110570:
LEA RCX,[0x12f990]
CMP byte ptr [RCX],0x1
JNZ 0x00110591
LAB_0011057c:
CMP ESI,0x4
JNC 0x0011060b
MOV EAX,ESI
LEA RCX,[0x1224d0]
MOV EAX,dword ptr [RCX + RAX*0x4]
LAB_00110591:
MOV EAX,EAX
LEA RCX,[0x1224e0]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
JMP RAX
LAB_0011060b:
LEA RDI,[0x1220e1]
LEA RSI,[0x1226b2]
LEA RCX,[0x122c01]
MOV EDX,0xeb
CALL 0x00107330
|
/* nglog::ColoredWriteToStderrOrStdout(_IO_FILE*, nglog::LogSeverity, char const*, unsigned long) */
void nglog::ColoredWriteToStderrOrStdout(long param_1,uint param_2)
{
uint uVar1;
uVar1 = 0;
if (LogDestination::terminal_supports_color_ == '\x01') {
uVar1 = 0;
if (*(long *)PTR_stdout_0012ef20 == param_1) {
if (fLB::FLAGS_colorlogtostdout != '\x01') goto LAB_00110591;
}
else if (fLB::FLAGS_colorlogtostderr == '\0') goto LAB_00110591;
if (3 < param_2) {
/* WARNING: Subroutine does not return */
__assert_fail("false","/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc"
,0xeb,"GLogColor nglog::SeverityToColor(LogSeverity)");
}
uVar1 = *(uint *)(&DAT_001224d0 + (ulong)param_2 * 4);
}
LAB_00110591:
/* WARNING: Could not recover jumptable at 0x001105a1. Too many branches */
/* WARNING: Treating indirect jump as call */
(*(code *)((long)&DAT_001224e0 + (long)(int)(&DAT_001224e0)[uVar1]))();
return;
}
|
|
64,849 |
nglog::ColoredWriteToStderrOrStdout(_IO_FILE*, nglog::LogSeverity, char const*, unsigned long)
|
ng-log[P]ng-log/src/logging.cc
|
static void ColoredWriteToStderrOrStdout(FILE* output, LogSeverity severity,
const char* message, size_t len) {
bool is_stdout = (output == stdout);
const GLogColor color = (LogDestination::terminal_supports_color() &&
((!is_stdout && FLAGS_colorlogtostderr) ||
(is_stdout && FLAGS_colorlogtostdout)))
? SeverityToColor(severity)
: COLOR_DEFAULT;
// Avoid using cerr from this module since we may get called during
// exit code, and cerr may be partially or fully destroyed by then.
if (COLOR_DEFAULT == color) {
fwrite(message, len, 1, output);
return;
}
#ifdef NGLOG_OS_WINDOWS
const HANDLE output_handle =
GetStdHandle(is_stdout ? STD_OUTPUT_HANDLE : STD_ERROR_HANDLE);
// Gets the current text color.
CONSOLE_SCREEN_BUFFER_INFO buffer_info;
GetConsoleScreenBufferInfo(output_handle, &buffer_info);
const WORD old_color_attrs = buffer_info.wAttributes;
// We need to flush the stream buffers into the console before each
// SetConsoleTextAttribute call lest it affect the text that is already
// printed but has not yet reached the console.
fflush(output);
SetConsoleTextAttribute(output_handle,
GetColorAttribute(color) | FOREGROUND_INTENSITY);
fwrite(message, len, 1, output);
fflush(output);
// Restores the text color.
SetConsoleTextAttribute(output_handle, old_color_attrs);
#else
fprintf(output, "\033[0;3%sm", GetAnsiColorCode(color));
fwrite(message, len, 1, output);
fprintf(output, "\033[m"); // Resets the terminal to default.
#endif // NGLOG_OS_WINDOWS
}
|
O2
|
cpp
|
nglog::ColoredWriteToStderrOrStdout(_IO_FILE*, nglog::LogSeverity, char const*, unsigned long):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %r15
movq %rdi, %rbx
cmpb $0x1, 0x210a5(%rip) # 0x2ebf0
jne 0xdb8d
movq 0x203ec(%rip), %rax # 0x2df40
cmpq %rbx, (%rax)
je 0xdb67
leaq 0x20e8e(%rip), %rax # 0x2e9ee
cmpb $0x0, (%rax)
jne 0xdb73
jmp 0xdb8d
leaq 0x20e82(%rip), %rax # 0x2e9f0
cmpb $0x1, (%rax)
jne 0xdb8d
leal -0x2(%rsi), %eax
cmpl $0x2, %eax
jb 0xdba9
testl %esi, %esi
je 0xdb8d
cmpl $0x1, %esi
jne 0xdbe5
leaq 0x117e4(%rip), %rdx # 0x1f36f
jmp 0xdbb0
pushq $0x1
popq %rdx
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x7aa0
leaq 0x10ccd(%rip), %rdx # 0x1e87d
leaq 0x11022(%rip), %rsi # 0x1ebd9
movq %rbx, %rdi
xorl %eax, %eax
callq 0x7850
pushq $0x1
popq %r12
movq %r15, %rdi
movq %r14, %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x7aa0
leaq 0x11005(%rip), %rdi # 0x1ebe2
pushq $0x3
popq %rsi
movq %r12, %rdx
jmp 0xdb96
leaq 0x104f5(%rip), %rdi # 0x1e0e1
leaq 0x10aa7(%rip), %rsi # 0x1e69a
leaq 0x10fec(%rip), %rcx # 0x1ebe6
movl $0xeb, %edx
callq 0x73a0
|
_ZN5nglogL28ColoredWriteToStderrOrStdoutEP8_IO_FILENS_11LogSeverityEPKcm:
push r15
push r14
push r12
push rbx
push rax
mov r14, rcx
mov r15, rdx
mov rbx, rdi
cmp cs:_ZN5nglog14LogDestination24terminal_supports_color_E, 1; nglog::LogDestination::terminal_supports_color_
jnz short loc_DB8D
mov rax, cs:stdout_ptr
cmp [rax], rbx
jz short loc_DB67
lea rax, _ZN3fLB22FLAGS_colorlogtostderrE; fLB::FLAGS_colorlogtostderr
cmp byte ptr [rax], 0
jnz short loc_DB73
jmp short loc_DB8D
loc_DB67:
lea rax, _ZN3fLB22FLAGS_colorlogtostdoutE; fLB::FLAGS_colorlogtostdout
cmp byte ptr [rax], 1
jnz short loc_DB8D
loc_DB73:
lea eax, [rsi-2]
cmp eax, 2
jb short loc_DBA9
test esi, esi
jz short loc_DB8D
cmp esi, 1
jnz short loc_DBE5
lea rdx, aDc3+2; "3"
jmp short loc_DBB0
loc_DB8D:
push 1
pop rdx
mov rdi, r15
mov rsi, r14
loc_DB96:
mov rcx, rbx
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
jmp _fwrite
loc_DBA9:
lea rdx, aProcSelfFd1+0Eh; "1"
loc_DBB0:
lea rsi, a03Sm; "\x1B[0;3%sm"
mov rdi, rbx
xor eax, eax
call _fprintf
push 1
pop r12
mov rdi, r15
mov rsi, r14
mov rdx, r12
mov rcx, rbx
call _fwrite
lea rdi, aM; "\x1B[m"
push 3
pop rsi
mov rdx, r12
jmp short loc_DB96
loc_DBE5:
lea rdi, aFalse; "false"
lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aGlogcolorNglog; "GLogColor nglog::SeverityToColor(LogSev"...
mov edx, 0EBh
call ___assert_fail
|
long long nglog::ColoredWriteToStderrOrStdout(long long a1, int a2, const char *a3, long long a4)
{
const char *v7; // rdx
const char *v8; // rdi
long long v9; // rsi
if ( nglog::LogDestination::terminal_supports_color_ != 1 )
goto LABEL_10;
if ( stdout == a1 )
{
if ( fLB::FLAGS_colorlogtostdout != 1 )
goto LABEL_10;
}
else if ( !fLB::FLAGS_colorlogtostderr )
{
goto LABEL_10;
}
if ( (unsigned int)(a2 - 2) < 2 )
{
v7 = "1";
LABEL_13:
fprintf(a1, "\x1B[0;3%sm", v7);
fwrite(a3, a4, 1LL, a1);
v8 = "\x1B[m";
v9 = 3LL;
return fwrite(v8, v9, 1LL, a1);
}
if ( a2 )
{
if ( a2 != 1 )
__assert_fail(
"false",
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",
235LL,
"GLogColor nglog::SeverityToColor(LogSeverity)");
v7 = "3";
goto LABEL_13;
}
LABEL_10:
v8 = a3;
v9 = a4;
return fwrite(v8, v9, 1LL, a1);
}
|
ColoredWriteToStderrOrStdout:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
MOV R14,RCX
MOV R15,RDX
MOV RBX,RDI
CMP byte ptr [0x0012ebf0],0x1
JNZ 0x0010db8d
MOV RAX,qword ptr [0x0012df40]
CMP qword ptr [RAX],RBX
JZ 0x0010db67
LEA RAX,[0x12e9ee]
CMP byte ptr [RAX],0x0
JNZ 0x0010db73
JMP 0x0010db8d
LAB_0010db67:
LEA RAX,[0x12e9f0]
CMP byte ptr [RAX],0x1
JNZ 0x0010db8d
LAB_0010db73:
LEA EAX,[RSI + -0x2]
CMP EAX,0x2
JC 0x0010dba9
TEST ESI,ESI
JZ 0x0010db8d
CMP ESI,0x1
JNZ 0x0010dbe5
LEA RDX,[0x11f36f]
JMP 0x0010dbb0
LAB_0010db8d:
PUSH 0x1
POP RDX
MOV RDI,R15
MOV RSI,R14
LAB_0010db96:
MOV RCX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
JMP 0x00107aa0
LAB_0010dba9:
LEA RDX,[0x11e87d]
LAB_0010dbb0:
LEA RSI,[0x11ebd9]
MOV RDI,RBX
XOR EAX,EAX
CALL 0x00107850
PUSH 0x1
POP R12
MOV RDI,R15
MOV RSI,R14
MOV RDX,R12
MOV RCX,RBX
CALL 0x00107aa0
LEA RDI,[0x11ebe2]
PUSH 0x3
POP RSI
MOV RDX,R12
JMP 0x0010db96
LAB_0010dbe5:
LEA RDI,[0x11e0e1]
LEA RSI,[0x11e69a]
LEA RCX,[0x11ebe6]
MOV EDX,0xeb
CALL 0x001073a0
|
/* nglog::ColoredWriteToStderrOrStdout(_IO_FILE*, nglog::LogSeverity, char const*, unsigned long) */
void nglog::ColoredWriteToStderrOrStdout
(FILE *param_1,int param_2,int *param_3,size_t param_4)
{
char *pcVar1;
size_t sStack_30;
sStack_30 = param_4;
if (LogDestination::terminal_supports_color_ == '\x01') {
if (*(FILE **)PTR_stdout_0012df40 == param_1) {
if (fLB::FLAGS_colorlogtostdout != '\x01') goto LAB_0010db96;
}
else if (fLB::FLAGS_colorlogtostderr == '\0') goto LAB_0010db96;
if (param_2 - 2U < 2) {
pcVar1 = "1";
}
else {
if (param_2 == 0) goto LAB_0010db96;
if (param_2 != 1) {
/* WARNING: Subroutine does not return */
__assert_fail("false",
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",0xeb,
"GLogColor nglog::SeverityToColor(LogSeverity)");
}
pcVar1 = "3";
}
fprintf(param_1,"\x1b[0;3%sm",pcVar1);
fwrite(param_3,param_4,1,param_1);
param_3 = &DAT_0011ebe2;
sStack_30 = 3;
}
LAB_0010db96:
fwrite(param_3,sStack_30,1,param_1);
return;
}
|
|
64,850 |
mysql_stmt_fetch_column
|
eloqsql/libmariadb/libmariadb/mariadb_stmt.c
|
int STDCALL mysql_stmt_fetch_column(MYSQL_STMT *stmt, MYSQL_BIND *bind, unsigned int column, unsigned long offset)
{
if (stmt->state < MYSQL_STMT_USER_FETCHING || column >= stmt->field_count ||
stmt->state == MYSQL_STMT_FETCH_DONE) {
SET_CLIENT_STMT_ERROR(stmt, CR_NO_DATA, SQLSTATE_UNKNOWN, 0);
return(1);
}
if (!stmt->bind[column].u.row_ptr)
{
/* we set row_ptr only for columns which contain data, so this must be a NULL column */
if (bind[0].is_null)
*bind[0].is_null= 1;
}
else
{
unsigned char *save_ptr;
if (bind[0].length)
*bind[0].length= *stmt->bind[column].length;
else
bind[0].length= &stmt->bind[column].length_value;
if (bind[0].is_null)
*bind[0].is_null= 0;
else
bind[0].is_null= &bind[0].is_null_value;
if (!bind[0].error)
bind[0].error= &bind[0].error_value;
*bind[0].error= 0;
bind[0].offset= offset;
save_ptr= stmt->bind[column].u.row_ptr;
mysql_ps_fetch_functions[stmt->fields[column].type].func(&bind[0], &stmt->fields[column], &stmt->bind[column].u.row_ptr);
stmt->bind[column].u.row_ptr= save_ptr;
}
return(0);
}
|
O0
|
c
|
mysql_stmt_fetch_column:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x5, 0x50(%rax)
jb 0x2ae57
movl -0x1c(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x60(%rcx), %eax
jae 0x2ae57
movq -0x10(%rbp), %rax
cmpl $0x6, 0x50(%rax)
jne 0x2aecb
jmp 0x2ae59
movq -0x10(%rbp), %rax
movl $0x803, 0x108(%rax) # imm = 0x803
movq -0x10(%rbp), %rdi
addq $0x30d, %rdi # imm = 0x30D
leaq 0x361e7(%rip), %rax # 0x61060
movq (%rax), %rsi
movl $0x5, %edx
callq 0x13210
movq -0x10(%rbp), %rax
movb $0x0, 0x312(%rax)
movq -0x10(%rbp), %rdi
addq $0x10c, %rdi # imm = 0x10C
leaq 0x361cd(%rip), %rax # 0x61070
movq 0x198(%rax), %rsi
movl $0x200, %edx # imm = 0x200
callq 0x13210
movq -0x10(%rbp), %rax
movb $0x0, 0x30b(%rax)
movl $0x1, -0x4(%rbp)
jmp 0x2b035
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
movl -0x1c(%rbp), %ecx
imulq $0x70, %rcx, %rcx
addq %rcx, %rax
cmpq $0x0, 0x20(%rax)
jne 0x2aeff
movq -0x18(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x2aefa
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movb $0x1, (%rax)
jmp 0x2b02e
movq -0x18(%rbp), %rax
cmpq $0x0, (%rax)
je 0x2af2d
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
movl -0x1c(%rbp), %ecx
imulq $0x70, %rcx, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq (%rax), %rcx
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq %rcx, (%rax)
jmp 0x2af4a
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rcx
movl -0x1c(%rbp), %eax
imulq $0x70, %rax, %rax
addq %rax, %rcx
addq $0x50, %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x2af62
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movb $0x0, (%rax)
jmp 0x2af72
movq -0x18(%rbp), %rcx
addq $0x67, %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x18(%rax)
jne 0x2af8d
movq -0x18(%rbp), %rcx
addq $0x64, %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movb $0x0, (%rax)
movq -0x28(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x48(%rax)
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
movl -0x1c(%rbp), %ecx
imulq $0x70, %rcx, %rcx
addq %rcx, %rax
movq 0x20(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
movl -0x1c(%rbp), %ecx
shlq $0x7, %rcx
addq %rcx, %rax
movl 0x70(%rax), %eax
movl %eax, %ecx
leaq 0x36604(%rip), %rax # 0x615e0
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rcx
movq 0x58(%rcx), %rsi
movl -0x1c(%rbp), %ecx
shlq $0x7, %rcx
addq %rcx, %rsi
movq -0x10(%rbp), %rcx
movq 0x78(%rcx), %rdx
movl -0x1c(%rbp), %ecx
imulq $0x70, %rcx, %rcx
addq %rcx, %rdx
addq $0x20, %rdx
callq *%rax
movq -0x30(%rbp), %rcx
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
movl -0x1c(%rbp), %edx
imulq $0x70, %rdx, %rdx
addq %rdx, %rax
movq %rcx, 0x20(%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nop
|
mysql_stmt_fetch_column:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_1C], edx
mov [rbp+var_28], rcx
mov rax, [rbp+var_10]
cmp dword ptr [rax+50h], 5
jb short loc_2AE57
mov eax, [rbp+var_1C]
mov rcx, [rbp+var_10]
cmp eax, [rcx+60h]
jnb short loc_2AE57
mov rax, [rbp+var_10]
cmp dword ptr [rax+50h], 6
jnz short loc_2AECB
loc_2AE57:
jmp short $+2
loc_2AE59:
mov rax, [rbp+var_10]
mov dword ptr [rax+108h], 803h
mov rdi, [rbp+var_10]
add rdi, 30Dh
lea rax, SQLSTATE_UNKNOWN
mov rsi, [rax]
mov edx, 5
call _strncpy
mov rax, [rbp+var_10]
mov byte ptr [rax+312h], 0
mov rdi, [rbp+var_10]
add rdi, 10Ch
lea rax, client_errors
mov rsi, [rax+198h]
mov edx, 200h
call _strncpy
mov rax, [rbp+var_10]
mov byte ptr [rax+30Bh], 0
mov [rbp+var_4], 1
jmp loc_2B035
loc_2AECB:
mov rax, [rbp+var_10]
mov rax, [rax+78h]
mov ecx, [rbp+var_1C]
imul rcx, 70h ; 'p'
add rax, rcx
cmp qword ptr [rax+20h], 0
jnz short loc_2AEFF
mov rax, [rbp+var_18]
cmp qword ptr [rax+8], 0
jz short loc_2AEFA
mov rax, [rbp+var_18]
mov rax, [rax+8]
mov byte ptr [rax], 1
loc_2AEFA:
jmp loc_2B02E
loc_2AEFF:
mov rax, [rbp+var_18]
cmp qword ptr [rax], 0
jz short loc_2AF2D
mov rax, [rbp+var_10]
mov rax, [rax+78h]
mov ecx, [rbp+var_1C]
imul rcx, 70h ; 'p'
add rax, rcx
mov rax, [rax]
mov rcx, [rax]
mov rax, [rbp+var_18]
mov rax, [rax]
mov [rax], rcx
jmp short loc_2AF4A
loc_2AF2D:
mov rax, [rbp+var_10]
mov rcx, [rax+78h]
mov eax, [rbp+var_1C]
imul rax, 70h ; 'p'
add rcx, rax
add rcx, 50h ; 'P'
mov rax, [rbp+var_18]
mov [rax], rcx
loc_2AF4A:
mov rax, [rbp+var_18]
cmp qword ptr [rax+8], 0
jz short loc_2AF62
mov rax, [rbp+var_18]
mov rax, [rax+8]
mov byte ptr [rax], 0
jmp short loc_2AF72
loc_2AF62:
mov rcx, [rbp+var_18]
add rcx, 67h ; 'g'
mov rax, [rbp+var_18]
mov [rax+8], rcx
loc_2AF72:
mov rax, [rbp+var_18]
cmp qword ptr [rax+18h], 0
jnz short loc_2AF8D
mov rcx, [rbp+var_18]
add rcx, 64h ; 'd'
mov rax, [rbp+var_18]
mov [rax+18h], rcx
loc_2AF8D:
mov rax, [rbp+var_18]
mov rax, [rax+18h]
mov byte ptr [rax], 0
mov rcx, [rbp+var_28]
mov rax, [rbp+var_18]
mov [rax+48h], rcx
mov rax, [rbp+var_10]
mov rax, [rax+78h]
mov ecx, [rbp+var_1C]
imul rcx, 70h ; 'p'
add rax, rcx
mov rax, [rax+20h]
mov [rbp+var_30], rax
mov rax, [rbp+var_10]
mov rax, [rax+58h]
mov ecx, [rbp+var_1C]
shl rcx, 7
add rax, rcx
mov eax, [rax+70h]
mov ecx, eax
lea rax, mysql_ps_fetch_functions
imul rcx, 18h
add rax, rcx
mov rax, [rax]
mov rdi, [rbp+var_18]
mov rcx, [rbp+var_10]
mov rsi, [rcx+58h]
mov ecx, [rbp+var_1C]
shl rcx, 7
add rsi, rcx
mov rcx, [rbp+var_10]
mov rdx, [rcx+78h]
mov ecx, [rbp+var_1C]
imul rcx, 70h ; 'p'
add rdx, rcx
add rdx, 20h ; ' '
call rax
mov rcx, [rbp+var_30]
mov rax, [rbp+var_10]
mov rax, [rax+78h]
mov edx, [rbp+var_1C]
imul rdx, 70h ; 'p'
add rax, rdx
mov [rax+20h], rcx
loc_2B02E:
mov [rbp+var_4], 0
loc_2B035:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
|
long long mysql_stmt_fetch_column(long long a1, long long a2, unsigned int a3, long long a4)
{
long long v5; // [rsp+0h] [rbp-30h]
if ( *(_DWORD *)(a1 + 80) < 5u || a3 >= *(_DWORD *)(a1 + 96) || *(_DWORD *)(a1 + 80) == 6 )
{
*(_DWORD *)(a1 + 264) = 2051;
strncpy(a1 + 781, SQLSTATE_UNKNOWN, 5LL);
*(_BYTE *)(a1 + 786) = 0;
strncpy(a1 + 268, client_errors[51], 512LL);
*(_BYTE *)(a1 + 779) = 0;
return 1;
}
else
{
if ( *(_QWORD *)(112LL * a3 + *(_QWORD *)(a1 + 120) + 32) )
{
if ( *(_QWORD *)a2 )
**(_QWORD **)a2 = **(_QWORD **)(112LL * a3 + *(_QWORD *)(a1 + 120));
else
*(_QWORD *)a2 = 112LL * a3 + *(_QWORD *)(a1 + 120) + 80;
if ( *(_QWORD *)(a2 + 8) )
**(_BYTE **)(a2 + 8) = 0;
else
*(_QWORD *)(a2 + 8) = a2 + 103;
if ( !*(_QWORD *)(a2 + 24) )
*(_QWORD *)(a2 + 24) = a2 + 100;
**(_BYTE **)(a2 + 24) = 0;
*(_QWORD *)(a2 + 72) = a4;
v5 = *(_QWORD *)(112LL * a3 + *(_QWORD *)(a1 + 120) + 32);
(*(void ( **)(long long, unsigned long long, long long))&mysql_ps_fetch_functions[6
* *(unsigned int *)(((unsigned long long)a3 << 7) + *(_QWORD *)(a1 + 88) + 112)])(
a2,
((unsigned long long)a3 << 7) + *(_QWORD *)(a1 + 88),
112LL * a3 + *(_QWORD *)(a1 + 120) + 32);
*(_QWORD *)(112LL * a3 + *(_QWORD *)(a1 + 120) + 32) = v5;
}
else if ( *(_QWORD *)(a2 + 8) )
{
**(_BYTE **)(a2 + 8) = 1;
}
return 0;
}
}
|
mysql_stmt_fetch_column:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV dword ptr [RBP + -0x1c],EDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x50],0x5
JC 0x0012ae57
MOV EAX,dword ptr [RBP + -0x1c]
MOV RCX,qword ptr [RBP + -0x10]
CMP EAX,dword ptr [RCX + 0x60]
JNC 0x0012ae57
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x50],0x6
JNZ 0x0012aecb
LAB_0012ae57:
JMP 0x0012ae59
LAB_0012ae59:
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x108],0x803
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x30d
LEA RAX,[0x161060]
MOV RSI,qword ptr [RAX]
MOV EDX,0x5
CALL 0x00113210
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x312],0x0
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x10c
LEA RAX,[0x161070]
MOV RSI,qword ptr [RAX + 0x198]
MOV EDX,0x200
CALL 0x00113210
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x30b],0x0
MOV dword ptr [RBP + -0x4],0x1
JMP 0x0012b035
LAB_0012aecb:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x78]
MOV ECX,dword ptr [RBP + -0x1c]
IMUL RCX,RCX,0x70
ADD RAX,RCX
CMP qword ptr [RAX + 0x20],0x0
JNZ 0x0012aeff
MOV RAX,qword ptr [RBP + -0x18]
CMP qword ptr [RAX + 0x8],0x0
JZ 0x0012aefa
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x8]
MOV byte ptr [RAX],0x1
LAB_0012aefa:
JMP 0x0012b02e
LAB_0012aeff:
MOV RAX,qword ptr [RBP + -0x18]
CMP qword ptr [RAX],0x0
JZ 0x0012af2d
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x78]
MOV ECX,dword ptr [RBP + -0x1c]
IMUL RCX,RCX,0x70
ADD RAX,RCX
MOV RAX,qword ptr [RAX]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RAX],RCX
JMP 0x0012af4a
LAB_0012af2d:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x78]
MOV EAX,dword ptr [RBP + -0x1c]
IMUL RAX,RAX,0x70
ADD RCX,RAX
ADD RCX,0x50
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
LAB_0012af4a:
MOV RAX,qword ptr [RBP + -0x18]
CMP qword ptr [RAX + 0x8],0x0
JZ 0x0012af62
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x8]
MOV byte ptr [RAX],0x0
JMP 0x0012af72
LAB_0012af62:
MOV RCX,qword ptr [RBP + -0x18]
ADD RCX,0x67
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x8],RCX
LAB_0012af72:
MOV RAX,qword ptr [RBP + -0x18]
CMP qword ptr [RAX + 0x18],0x0
JNZ 0x0012af8d
MOV RCX,qword ptr [RBP + -0x18]
ADD RCX,0x64
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x18],RCX
LAB_0012af8d:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x18]
MOV byte ptr [RAX],0x0
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x48],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x78]
MOV ECX,dword ptr [RBP + -0x1c]
IMUL RCX,RCX,0x70
ADD RAX,RCX
MOV RAX,qword ptr [RAX + 0x20]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x58]
MOV ECX,dword ptr [RBP + -0x1c]
SHL RCX,0x7
ADD RAX,RCX
MOV EAX,dword ptr [RAX + 0x70]
MOV ECX,EAX
LEA RAX,[0x1615e0]
IMUL RCX,RCX,0x18
ADD RAX,RCX
MOV RAX,qword ptr [RAX]
MOV RDI,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RCX + 0x58]
MOV ECX,dword ptr [RBP + -0x1c]
SHL RCX,0x7
ADD RSI,RCX
MOV RCX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RCX + 0x78]
MOV ECX,dword ptr [RBP + -0x1c]
IMUL RCX,RCX,0x70
ADD RDX,RCX
ADD RDX,0x20
CALL RAX
MOV RCX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x78]
MOV EDX,dword ptr [RBP + -0x1c]
IMUL RDX,RDX,0x70
ADD RAX,RDX
MOV qword ptr [RAX + 0x20],RCX
LAB_0012b02e:
MOV dword ptr [RBP + -0x4],0x0
LAB_0012b035:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
int4 mysql_stmt_fetch_column(long param_1,long *param_2,uint param_3,long param_4)
{
int8 uVar1;
int4 local_c;
if (((*(uint *)(param_1 + 0x50) < 5) || (*(uint *)(param_1 + 0x60) <= param_3)) ||
(*(int *)(param_1 + 0x50) == 6)) {
*(int4 *)(param_1 + 0x108) = 0x803;
strncpy((char *)(param_1 + 0x30d),SQLSTATE_UNKNOWN,5);
*(int1 *)(param_1 + 0x312) = 0;
strncpy((char *)(param_1 + 0x10c),PTR_s__00161208,0x200);
*(int1 *)(param_1 + 0x30b) = 0;
local_c = 1;
}
else {
if (*(long *)(*(long *)(param_1 + 0x78) + (ulong)param_3 * 0x70 + 0x20) == 0) {
if (param_2[1] != 0) {
*(int1 *)param_2[1] = 1;
}
}
else {
if (*param_2 == 0) {
*param_2 = *(long *)(param_1 + 0x78) + (ulong)param_3 * 0x70 + 0x50;
}
else {
*(int8 *)*param_2 =
**(int8 **)(*(long *)(param_1 + 0x78) + (ulong)param_3 * 0x70);
}
if (param_2[1] == 0) {
param_2[1] = (long)param_2 + 0x67;
}
else {
*(int1 *)param_2[1] = 0;
}
if (param_2[3] == 0) {
param_2[3] = (long)param_2 + 100;
}
*(int1 *)param_2[3] = 0;
param_2[9] = param_4;
uVar1 = *(int8 *)(*(long *)(param_1 + 0x78) + (ulong)param_3 * 0x70 + 0x20);
(*(code *)(&mysql_ps_fetch_functions)
[(ulong)*(uint *)(*(long *)(param_1 + 0x58) + (ulong)param_3 * 0x80 + 0x70) * 3])
(param_2,*(long *)(param_1 + 0x58) + (ulong)param_3 * 0x80,
*(long *)(param_1 + 0x78) + (ulong)param_3 * 0x70 + 0x20);
*(int8 *)(*(long *)(param_1 + 0x78) + (ulong)param_3 * 0x70 + 0x20) = uVar1;
}
local_c = 0;
}
return local_c;
}
|
|
64,851 |
fmt::v10::format_specs<char>::format_specs()
|
AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/fmt/bundled/core.h
|
constexpr format_specs()
: width(0),
precision(-1),
type(presentation_type::none),
align(align::none),
sign(sign::none),
alt(false),
localized(false) {}
|
O0
|
c
|
fmt::v10::format_specs<char>::format_specs():
pushq %rax
movq %rdi, (%rsp)
movq (%rsp), %rdi
movl $0x0, (%rdi)
movl $0xffffffff, 0x4(%rdi) # imm = 0xFFFFFFFF
movb $0x0, 0x8(%rdi)
movw 0x9(%rdi), %ax
andw $-0x10, %ax
orw $0x0, %ax
movw %ax, 0x9(%rdi)
movw 0x9(%rdi), %ax
andw $-0x71, %ax
orw $0x0, %ax
movw %ax, 0x9(%rdi)
movw 0x9(%rdi), %ax
andw $0xff7f, %ax # imm = 0xFF7F
orw $0x0, %ax
movw %ax, 0x9(%rdi)
movw 0x9(%rdi), %ax
andw $0xfeff, %ax # imm = 0xFEFF
orw $0x0, %ax
movw %ax, 0x9(%rdi)
addq $0xb, %rdi
callq 0xd1df0
popq %rax
retq
nopw %cs:(%rax,%rax)
nop
|
_ZN3fmt3v1012format_specsIcEC2Ev:
push rax
mov [rsp+8+var_8], rdi
mov rdi, [rsp+8+var_8]
mov dword ptr [rdi], 0
mov dword ptr [rdi+4], 0FFFFFFFFh
mov byte ptr [rdi+8], 0
mov ax, [rdi+9]
and ax, 0FFF0h
or ax, 0
mov [rdi+9], ax
mov ax, [rdi+9]
and ax, 0FF8Fh
or ax, 0
mov [rdi+9], ax
mov ax, [rdi+9]
and ax, 0FF7Fh
or ax, 0
mov [rdi+9], ax
mov ax, [rdi+9]
and ax, 0FEFFh
or ax, 0
mov [rdi+9], ax
add rdi, 0Bh
call _ZN3fmt3v106detail6fill_tIcEC2Ev; fmt::v10::detail::fill_t<char>::fill_t(void)
pop rax
retn
|
long long fmt::v10::format_specs<char>::format_specs(long long a1)
{
*(_DWORD *)a1 = 0;
*(_DWORD *)(a1 + 4) = -1;
*(_BYTE *)(a1 + 8) = 0;
*(_WORD *)(a1 + 9) &= 0xFFF0u;
*(_WORD *)(a1 + 9) &= 0xFF8Fu;
*(_WORD *)(a1 + 9) &= ~0x80u;
*(_WORD *)(a1 + 9) &= ~0x100u;
fmt::v10::detail::fill_t<char>::fill_t(a1 + 11);
return a1;
}
|
format_specs:
PUSH RAX
MOV qword ptr [RSP],RDI
MOV RDI,qword ptr [RSP]
MOV dword ptr [RDI],0x0
MOV dword ptr [RDI + 0x4],0xffffffff
MOV byte ptr [RDI + 0x8],0x0
MOV AX,word ptr [RDI + 0x9]
AND AX,0xfff0
OR AX,0x0
MOV word ptr [RDI + 0x9],AX
MOV AX,word ptr [RDI + 0x9]
AND AX,0xff8f
OR AX,0x0
MOV word ptr [RDI + 0x9],AX
MOV AX,word ptr [RDI + 0x9]
AND AX,0xff7f
OR AX,0x0
MOV word ptr [RDI + 0x9],AX
MOV AX,word ptr [RDI + 0x9]
AND AX,0xfeff
OR AX,0x0
MOV word ptr [RDI + 0x9],AX
ADD RDI,0xb
CALL 0x001d1df0
POP RAX
RET
|
/* fmt::v10::format_specs<char>::format_specs() */
format_specs<char> * __thiscall fmt::v10::format_specs<char>::format_specs(format_specs<char> *this)
{
*(int4 *)this = 0;
*(int4 *)(this + 4) = 0xffffffff;
this[8] = (format_specs<char>)0x0;
*(ushort *)(this + 9) = *(ushort *)(this + 9) & 0xfff0;
*(ushort *)(this + 9) = *(ushort *)(this + 9) & 0xff8f;
*(ushort *)(this + 9) = *(ushort *)(this + 9) & 0xff7f;
*(ushort *)(this + 9) = *(ushort *)(this + 9) & 0xfeff;
v10::detail::fill_t<char>::fill_t((fill_t<char> *)(this + 0xb));
return this;
}
|
|
64,852 |
js_parse_function_class_fields_init
|
bluesky950520[P]quickjs/quickjs.c
|
static JSFunctionDef *js_parse_function_class_fields_init(JSParseState *s)
{
JSFunctionDef *fd;
fd = js_new_function_def(s->ctx, s->cur_func, FALSE, FALSE,
s->filename, 0, 0);
if (!fd)
return NULL;
fd->func_name = JS_ATOM_NULL;
fd->has_prototype = FALSE;
fd->has_home_object = TRUE;
fd->has_arguments_binding = FALSE;
fd->has_this_binding = TRUE;
fd->is_derived_class_constructor = FALSE;
fd->new_target_allowed = TRUE;
fd->super_call_allowed = FALSE;
fd->super_allowed = fd->has_home_object;
fd->arguments_allowed = FALSE;
fd->func_kind = JS_FUNC_NORMAL;
fd->func_type = JS_PARSE_FUNC_METHOD;
return fd;
}
|
O0
|
c
|
js_parse_function_class_fields_init:
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq (%rax), %rdi
movq 0x18(%rsp), %rax
movq 0x90(%rax), %rsi
movq 0x18(%rsp), %rax
movq 0x18(%rax), %r8
xorl %r9d, %r9d
movl %r9d, %edx
movl %r9d, %ecx
movl $0x0, (%rsp)
callq 0xa1360
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
jne 0xb4d16
movq $0x0, 0x20(%rsp)
jmp 0xb4dd8
movq 0x10(%rsp), %rax
movl $0x0, 0x88(%rax)
movq 0x10(%rsp), %rax
movl $0x0, 0x4c(%rax)
movq 0x10(%rsp), %rax
movl $0x1, 0x48(%rax)
movq 0x10(%rsp), %rax
movl $0x0, 0x60(%rax)
movq 0x10(%rsp), %rax
movl $0x1, 0x64(%rax)
movq 0x10(%rsp), %rax
movl $0x0, 0x78(%rax)
movq 0x10(%rsp), %rax
movl $0x1, 0x68(%rax)
movq 0x10(%rsp), %rax
movl $0x0, 0x6c(%rax)
movq 0x10(%rsp), %rax
movl 0x48(%rax), %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x70(%rax)
movq 0x10(%rsp), %rax
movl $0x0, 0x74(%rax)
movq 0x10(%rsp), %rax
movw 0x84(%rax), %cx
andw $0xff00, %cx # imm = 0xFF00
orw $0x0, %cx
movw %cx, 0x84(%rax)
movq 0x10(%rsp), %rax
movw 0x84(%rax), %cx
andw $0x80ff, %cx # imm = 0x80FF
orw $0x600, %cx # imm = 0x600
movw %cx, 0x84(%rax)
movq 0x10(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rax
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
|
js_parse_function_class_fields_init:
sub rsp, 28h
mov [rsp+28h+var_10], rdi
mov rax, [rsp+28h+var_10]
mov rdi, [rax]
mov rax, [rsp+28h+var_10]
mov rsi, [rax+90h]
mov rax, [rsp+28h+var_10]
mov r8, [rax+18h]
xor r9d, r9d
mov edx, r9d
mov ecx, r9d
mov [rsp+28h+var_28], 0
call js_new_function_def
mov [rsp+28h+var_18], rax
cmp [rsp+28h+var_18], 0
jnz short loc_B4D16
mov [rsp+28h+var_8], 0
jmp loc_B4DD8
loc_B4D16:
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+88h], 0
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+4Ch], 0
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+48h], 1
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+60h], 0
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+64h], 1
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+78h], 0
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+68h], 1
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+6Ch], 0
mov rax, [rsp+28h+var_18]
mov ecx, [rax+48h]
mov rax, [rsp+28h+var_18]
mov [rax+70h], ecx
mov rax, [rsp+28h+var_18]
mov dword ptr [rax+74h], 0
mov rax, [rsp+28h+var_18]
mov cx, [rax+84h]
and cx, 0FF00h
or cx, 0
mov [rax+84h], cx
mov rax, [rsp+28h+var_18]
mov cx, [rax+84h]
and cx, 80FFh
or cx, 600h
mov [rax+84h], cx
mov rax, [rsp+28h+var_18]
mov [rsp+28h+var_8], rax
loc_B4DD8:
mov rax, [rsp+28h+var_8]
add rsp, 28h
retn
|
long long js_parse_function_class_fields_init(long long a1)
{
long long v2; // [rsp+10h] [rbp-18h]
v2 = js_new_function_def(*(_QWORD *)a1, *(_QWORD *)(a1 + 144), 0, 0, *(unsigned __int8 **)(a1 + 24), 0, 0);
if ( !v2 )
return 0LL;
*(_DWORD *)(v2 + 136) = 0;
*(_DWORD *)(v2 + 76) = 0;
*(_DWORD *)(v2 + 72) = 1;
*(_DWORD *)(v2 + 96) = 0;
*(_DWORD *)(v2 + 100) = 1;
*(_DWORD *)(v2 + 120) = 0;
*(_DWORD *)(v2 + 104) = 1;
*(_DWORD *)(v2 + 108) = 0;
*(_QWORD *)(v2 + 112) = *(unsigned int *)(v2 + 72);
*(_WORD *)(v2 + 132) &= 0xFF00u;
*(_WORD *)(v2 + 132) = *(_WORD *)(v2 + 132) & 0x80FF | 0x600;
return v2;
}
|
js_parse_function_class_fields_init:
SUB RSP,0x28
MOV qword ptr [RSP + 0x18],RDI
MOV RAX,qword ptr [RSP + 0x18]
MOV RDI,qword ptr [RAX]
MOV RAX,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RAX + 0x90]
MOV RAX,qword ptr [RSP + 0x18]
MOV R8,qword ptr [RAX + 0x18]
XOR R9D,R9D
MOV EDX,R9D
MOV ECX,R9D
MOV dword ptr [RSP],0x0
CALL 0x001a1360
MOV qword ptr [RSP + 0x10],RAX
CMP qword ptr [RSP + 0x10],0x0
JNZ 0x001b4d16
MOV qword ptr [RSP + 0x20],0x0
JMP 0x001b4dd8
LAB_001b4d16:
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x88],0x0
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x4c],0x0
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x48],0x1
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x60],0x0
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x64],0x1
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x78],0x0
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x68],0x1
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x6c],0x0
MOV RAX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RAX + 0x48]
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x70],ECX
MOV RAX,qword ptr [RSP + 0x10]
MOV dword ptr [RAX + 0x74],0x0
MOV RAX,qword ptr [RSP + 0x10]
MOV CX,word ptr [RAX + 0x84]
AND CX,0xff00
OR CX,0x0
MOV word ptr [RAX + 0x84],CX
MOV RAX,qword ptr [RSP + 0x10]
MOV CX,word ptr [RAX + 0x84]
AND CX,0x80ff
OR CX,0x600
MOV word ptr [RAX + 0x84],CX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x20],RAX
LAB_001b4dd8:
MOV RAX,qword ptr [RSP + 0x20]
ADD RSP,0x28
RET
|
long js_parse_function_class_fields_init(int8 *param_1)
{
long local_8;
local_8 = js_new_function_def(*param_1,param_1[0x12],0,0,param_1[3],0,0);
if (local_8 == 0) {
local_8 = 0;
}
else {
*(int4 *)(local_8 + 0x88) = 0;
*(int4 *)(local_8 + 0x4c) = 0;
*(int4 *)(local_8 + 0x48) = 1;
*(int4 *)(local_8 + 0x60) = 0;
*(int4 *)(local_8 + 100) = 1;
*(int4 *)(local_8 + 0x78) = 0;
*(int4 *)(local_8 + 0x68) = 1;
*(int4 *)(local_8 + 0x6c) = 0;
*(int4 *)(local_8 + 0x70) = *(int4 *)(local_8 + 0x48);
*(int4 *)(local_8 + 0x74) = 0;
*(ushort *)(local_8 + 0x84) = *(ushort *)(local_8 + 0x84) & 0xff00;
*(ushort *)(local_8 + 0x84) = *(ushort *)(local_8 + 0x84) & 0x80ff | 0x600;
}
return local_8;
}
|
|
64,853 |
mbr_join
|
eloqsql/storage/myisam/rt_split.c
|
static void mbr_join(double *a, const double *b, int n_dim)
{
double *end = a + n_dim * 2;
do
{
if (a[0] > b[0])
a[0] = b[0];
if (a[1] < b[1])
a[1] = b[1];
a += 2;
b += 2;
}while (a != end);
}
|
O0
|
c
|
mbr_join:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq -0x8(%rbp), %rax
movl -0x14(%rbp), %ecx
shll %ecx
movslq %ecx, %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movsd (%rax), %xmm0
movq -0x10(%rbp), %rax
ucomisd (%rax), %xmm0
jbe 0xd71b8
movq -0x10(%rbp), %rax
movsd (%rax), %xmm0
movq -0x8(%rbp), %rax
movsd %xmm0, (%rax)
movq -0x8(%rbp), %rax
movsd 0x8(%rax), %xmm1
movq -0x10(%rbp), %rax
movsd 0x8(%rax), %xmm0
ucomisd %xmm1, %xmm0
jbe 0xd71e2
movq -0x10(%rbp), %rax
movsd 0x8(%rax), %xmm0
movq -0x8(%rbp), %rax
movsd %xmm0, 0x8(%rax)
movq -0x8(%rbp), %rax
addq $0x10, %rax
movq %rax, -0x8(%rbp)
movq -0x10(%rbp), %rax
addq $0x10, %rax
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rax
cmpq -0x20(%rbp), %rax
jne 0xd7196
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
mbr_join_0:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
mov rax, [rbp+var_8]
mov ecx, [rbp+var_14]
shl ecx, 1
movsxd rcx, ecx
shl rcx, 3
add rax, rcx
mov [rbp+var_20], rax
loc_D7196:
mov rax, [rbp+var_8]
movsd xmm0, qword ptr [rax]
mov rax, [rbp+var_10]
ucomisd xmm0, qword ptr [rax]
jbe short loc_D71B8
mov rax, [rbp+var_10]
movsd xmm0, qword ptr [rax]
mov rax, [rbp+var_8]
movsd qword ptr [rax], xmm0
loc_D71B8:
mov rax, [rbp+var_8]
movsd xmm1, qword ptr [rax+8]
mov rax, [rbp+var_10]
movsd xmm0, qword ptr [rax+8]
ucomisd xmm0, xmm1
jbe short loc_D71E2
mov rax, [rbp+var_10]
movsd xmm0, qword ptr [rax+8]
mov rax, [rbp+var_8]
movsd qword ptr [rax+8], xmm0
loc_D71E2:
mov rax, [rbp+var_8]
add rax, 10h
mov [rbp+var_8], rax
mov rax, [rbp+var_10]
add rax, 10h
mov [rbp+var_10], rax
mov rax, [rbp+var_8]
cmp rax, [rbp+var_20]
jnz short loc_D7196
pop rbp
retn
|
double * mbr_join_0(double *a1, double *a2, int a3)
{
double *result; // rax
double *v5; // [rsp+18h] [rbp-8h]
v5 = a1;
do
{
if ( *v5 > *a2 )
*v5 = *a2;
if ( a2[1] > v5[1] )
v5[1] = a2[1];
v5 += 2;
a2 += 2;
result = v5;
}
while ( v5 != &a1[2 * a3] );
return result;
}
|
mbr_join:
PUSH RBP
MOV RBP,RSP
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 ECX,dword ptr [RBP + -0x14]
SHL ECX,0x1
MOVSXD RCX,ECX
SHL RCX,0x3
ADD RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
LAB_001d7196:
MOV RAX,qword ptr [RBP + -0x8]
MOVSD XMM0,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x10]
UCOMISD XMM0,qword ptr [RAX]
JBE 0x001d71b8
MOV RAX,qword ptr [RBP + -0x10]
MOVSD XMM0,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x8]
MOVSD qword ptr [RAX],XMM0
LAB_001d71b8:
MOV RAX,qword ptr [RBP + -0x8]
MOVSD XMM1,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x10]
MOVSD XMM0,qword ptr [RAX + 0x8]
UCOMISD XMM0,XMM1
JBE 0x001d71e2
MOV RAX,qword ptr [RBP + -0x10]
MOVSD XMM0,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x8]
MOVSD qword ptr [RAX + 0x8],XMM0
LAB_001d71e2:
MOV RAX,qword ptr [RBP + -0x8]
ADD RAX,0x10
MOV qword ptr [RBP + -0x8],RAX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x10
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x8]
CMP RAX,qword ptr [RBP + -0x20]
JNZ 0x001d7196
POP RBP
RET
|
void mbr_join(double *param_1,double *param_2,int param_3)
{
double *local_18;
double *local_10;
local_18 = param_2;
local_10 = param_1;
do {
if (*local_18 <= *local_10 && *local_10 != *local_18) {
*local_10 = *local_18;
}
if (local_10[1] < local_18[1]) {
local_10[1] = local_18[1];
}
local_10 = local_10 + 2;
local_18 = local_18 + 2;
} while (local_10 != param_1 + (param_3 << 1));
return;
}
|
|
64,854 |
my_wc_mb_filename
|
eloqsql/strings/ctype-utf8.c
|
static int
my_wc_mb_filename(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t wc, uchar *s, uchar *e)
{
int code;
static const char hex[]= "0123456789abcdef";
if (s >= e)
return MY_CS_TOOSMALL;
if (wc < 128 && filename_safe_char[wc])
{
*s= (uchar) wc;
return 1;
}
if (s + 3 > e)
return MY_CS_TOOSMALL3;
*s++= MY_FILENAME_ESCAPE;
if ((wc >= 0x00C0 && wc <= 0x05FF && (code= uni_0C00_05FF[wc - 0x00C0])) ||
(wc >= 0x1E00 && wc <= 0x1FFF && (code= uni_1E00_1FFF[wc - 0x1E00])) ||
(wc >= 0x2160 && wc <= 0x217F && (code= uni_2160_217F[wc - 0x2160])) ||
(wc >= 0x24B0 && wc <= 0x24EF && (code= uni_24B0_24EF[wc - 0x24B0])) ||
(wc >= 0xFF20 && wc <= 0xFF5F && (code= uni_FF20_FF5F[wc - 0xFF20])))
{
*s++= (code / 80) + 0x30;
*s++= (code % 80) + 0x30;
return 3;
}
/* Non letter */
if (s + 4 > e)
return MY_CS_TOOSMALL5;
*s++= hex[(wc >> 12) & 15];
*s++= hex[(wc >> 8) & 15];
*s++= hex[(wc >> 4) & 15];
*s++= hex[(wc) & 15];
return 5;
}
|
O3
|
c
|
my_wc_mb_filename:
pushq %rbp
movq %rsp, %rbp
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmpq %rcx, %rdx
jae 0x55c5e
cmpq $0x7f, %rsi
ja 0x55bbe
leaq 0x2823d5(%rip), %rax # 0x2d7f80
cmpb $0x0, (%rsi,%rax)
je 0x55bbe
movb %sil, (%rdx)
movl $0x1, %eax
jmp 0x55c5e
leaq 0x3(%rdx), %rdi
movl $0xffffff99, %eax # imm = 0xFFFFFF99
cmpq %rcx, %rdi
ja 0x55c5e
movb $0x40, (%rdx)
leaq -0xc0(%rsi), %rax
cmpq $0x53f, %rax # imm = 0x53F
ja 0x55bf6
leaq 0x285937(%rip), %rax # 0x2db520
movzwl -0x180(%rax,%rsi,2), %eax
testw %ax, %ax
jne 0x55c39
movq %rsi, %rax
andq $-0x200, %rax # imm = 0xFE00
cmpq $0x1e00, %rax # imm = 0x1E00
jne 0x55c1b
leaq 0x2853d2(%rip), %rax # 0x2dafe0
movzwl -0x3c00(%rax,%rsi,2), %eax
testw %ax, %ax
jne 0x55c39
movq %rsi, %rax
andq $-0x20, %rax
cmpq $0x2160, %rax # imm = 0x2160
jne 0x55c60
leaq 0x2857af(%rip), %rax # 0x2db3e0
movzwl -0x42c0(%rax,%rsi,2), %eax
movzwl %ax, %ecx
imull $0xcccd, %ecx, %ecx # imm = 0xCCCD
shrl $0x16, %ecx
leal 0x30(%rcx), %esi
movb %sil, 0x1(%rdx)
shll $0x4, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
addb $0x30, %al
movb %al, 0x2(%rdx)
movl $0x3, %eax
popq %rbp
retq
leaq -0x24b0(%rsi), %rax
cmpq $0x3f, %rax
ja 0x55c8b
leaq -0x24ea(%rsi), %rax
cmpq $-0x34, %rax
jb 0x55cb9
leaq 0x28579f(%rip), %rax # 0x2db420
movzwl -0x4960(%rax,%rsi,2), %eax
jmp 0x55c39
leaq -0xff20(%rsi), %rax
cmpq $0x3f, %rax
ja 0x55cb9
movabsq $-0x7fffffe07ffffff, %rdi # imm = 0xF8000001F8000001
btq %rax, %rdi
jb 0x55cb9
leaq 0x2857f1(%rip), %rax # 0x2db4a0
movzwl -0x1fe40(%rax,%rsi,2), %eax
jmp 0x55c39
leaq 0x5(%rdx), %rdi
movl $0xffffff97, %eax # imm = 0xFFFFFF97
cmpq %rcx, %rdi
ja 0x55c5e
movl %esi, %eax
shrl $0xc, %eax
andl $0xf, %eax
leaq 0x2862ca(%rip), %rcx # 0x2dbfa0
movb (%rax,%rcx), %al
movb %al, 0x1(%rdx)
movl %esi, %eax
shrl $0x8, %eax
andl $0xf, %eax
movb (%rax,%rcx), %al
movb %al, 0x2(%rdx)
movl %esi, %eax
shrl $0x4, %eax
andl $0xf, %eax
movb (%rax,%rcx), %al
movb %al, 0x3(%rdx)
andl $0xf, %esi
movb (%rsi,%rcx), %al
movb %al, 0x4(%rdx)
movl $0x5, %eax
jmp 0x55c5e
|
my_wc_mb_filename:
push rbp
mov rbp, rsp
mov eax, 0FFFFFF9Bh
cmp rdx, rcx
jnb loc_55C5E
cmp rsi, 7Fh
ja short loc_55BBE
lea rax, filename_safe_char
cmp byte ptr [rsi+rax], 0
jz short loc_55BBE
mov [rdx], sil
mov eax, 1
jmp loc_55C5E
loc_55BBE:
lea rdi, [rdx+3]
mov eax, 0FFFFFF99h
cmp rdi, rcx
ja loc_55C5E
mov byte ptr [rdx], 40h ; '@'
lea rax, [rsi-0C0h]
cmp rax, 53Fh
ja short loc_55BF6
lea rax, uni_0C00_05FF
movzx eax, word ptr [rax+rsi*2-180h]
test ax, ax
jnz short loc_55C39
loc_55BF6:
mov rax, rsi
and rax, 0FFFFFFFFFFFFFE00h
cmp rax, 1E00h
jnz short loc_55C1B
lea rax, uni_1E00_1FFF
movzx eax, word ptr [rax+rsi*2-3C00h]
test ax, ax
jnz short loc_55C39
loc_55C1B:
mov rax, rsi
and rax, 0FFFFFFFFFFFFFFE0h
cmp rax, 2160h
jnz short loc_55C60
lea rax, uni_2160_217F
movzx eax, word ptr [rax+rsi*2-42C0h]
loc_55C39:
movzx ecx, ax
imul ecx, 0CCCDh
shr ecx, 16h
lea esi, [rcx+30h]
mov [rdx+1], sil
shl ecx, 4
lea ecx, [rcx+rcx*4]
sub eax, ecx
add al, 30h ; '0'
mov [rdx+2], al
mov eax, 3
loc_55C5E:
pop rbp
retn
loc_55C60:
lea rax, [rsi-24B0h]
cmp rax, 3Fh ; '?'
ja short loc_55C8B
lea rax, [rsi-24EAh]
cmp rax, 0FFFFFFFFFFFFFFCCh
jb short loc_55CB9
lea rax, uni_24B0_24EF
movzx eax, word ptr [rax+rsi*2-4960h]
jmp short loc_55C39
loc_55C8B:
lea rax, [rsi-0FF20h]
cmp rax, 3Fh ; '?'
ja short loc_55CB9
mov rdi, 0F8000001F8000001h
bt rdi, rax
jb short loc_55CB9
lea rax, uni_FF20_FF5F
movzx eax, word ptr [rax+rsi*2-1FE40h]
jmp short loc_55C39
loc_55CB9:
lea rdi, [rdx+5]
mov eax, 0FFFFFF97h
cmp rdi, rcx
ja short loc_55C5E
mov eax, esi
shr eax, 0Ch
and eax, 0Fh
lea rcx, my_wc_mb_filename_hex; "0123456789abcdef"
mov al, [rax+rcx]
mov [rdx+1], al
mov eax, esi
shr eax, 8
and eax, 0Fh
mov al, [rax+rcx]
mov [rdx+2], al
mov eax, esi
shr eax, 4
and eax, 0Fh
mov al, [rax+rcx]
mov [rdx+3], al
and esi, 0Fh
mov al, [rsi+rcx]
mov [rdx+4], al
mov eax, 5
jmp loc_55C5E
|
long long my_wc_mb_filename(long long a1, unsigned long long a2, _BYTE *a3, unsigned long long a4)
{
long long result; // rax
unsigned __int16 v5; // ax
unsigned long long v6; // rdi
result = 4294967195LL;
if ( (unsigned long long)a3 < a4 )
{
if ( a2 <= 0x7F && filename_safe_char[a2] )
{
*a3 = a2;
return 1LL;
}
result = 4294967193LL;
if ( (unsigned long long)(a3 + 3) <= a4 )
{
*a3 = 64;
if ( a2 - 192 <= 0x53F )
{
v5 = uni_0C00_05FF[a2 - 192];
if ( v5 )
goto LABEL_12;
}
if ( (a2 & 0xFFFFFFFFFFFFFE00LL) == 0x1E00 )
{
v5 = uni_1E00_1FFF[a2 - 7680];
if ( v5 )
goto LABEL_12;
}
if ( (a2 & 0xFFFFFFFFFFFFFFE0LL) == 0x2160 )
{
v5 = uni_2160_217F[a2 - 8544];
LABEL_12:
a3[1] = v5 / 0x50u + 48;
a3[2] = v5 % 0x50u + 48;
return 3LL;
}
if ( a2 - 9392 > 0x3F )
{
if ( a2 - 65312 <= 0x3F )
{
v6 = 0xF8000001F8000001LL;
if ( !_bittest64((const long long *)&v6, a2 - 65312) )
{
v5 = uni_FF20_FF5F[a2 - 65312];
goto LABEL_12;
}
}
}
else if ( a2 - 9450 >= 0xFFFFFFFFFFFFFFCCLL )
{
v5 = uni_24B0_24EF[a2 - 9392];
goto LABEL_12;
}
result = 4294967191LL;
if ( (unsigned long long)(a3 + 5) <= a4 )
{
a3[1] = my_wc_mb_filename_hex[(unsigned __int16)a2 >> 12];
a3[2] = my_wc_mb_filename_hex[((unsigned int)a2 >> 8) & 0xF];
a3[3] = my_wc_mb_filename_hex[(unsigned __int8)a2 >> 4];
a3[4] = my_wc_mb_filename_hex[a2 & 0xF];
return 5LL;
}
}
}
return result;
}
|
my_wc_mb_filename:
PUSH RBP
MOV RBP,RSP
MOV EAX,0xffffff9b
CMP RDX,RCX
JNC 0x00155c5e
CMP RSI,0x7f
JA 0x00155bbe
LEA RAX,[0x3d7f80]
CMP byte ptr [RSI + RAX*0x1],0x0
JZ 0x00155bbe
MOV byte ptr [RDX],SIL
MOV EAX,0x1
JMP 0x00155c5e
LAB_00155bbe:
LEA RDI,[RDX + 0x3]
MOV EAX,0xffffff99
CMP RDI,RCX
JA 0x00155c5e
MOV byte ptr [RDX],0x40
LEA RAX,[RSI + -0xc0]
CMP RAX,0x53f
JA 0x00155bf6
LEA RAX,[0x3db520]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x180]
TEST AX,AX
JNZ 0x00155c39
LAB_00155bf6:
MOV RAX,RSI
AND RAX,-0x200
CMP RAX,0x1e00
JNZ 0x00155c1b
LEA RAX,[0x3dafe0]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x3c00]
TEST AX,AX
JNZ 0x00155c39
LAB_00155c1b:
MOV RAX,RSI
AND RAX,-0x20
CMP RAX,0x2160
JNZ 0x00155c60
LEA RAX,[0x3db3e0]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x42c0]
LAB_00155c39:
MOVZX ECX,AX
IMUL ECX,ECX,0xcccd
SHR ECX,0x16
LEA ESI,[RCX + 0x30]
MOV byte ptr [RDX + 0x1],SIL
SHL ECX,0x4
LEA ECX,[RCX + RCX*0x4]
SUB EAX,ECX
ADD AL,0x30
MOV byte ptr [RDX + 0x2],AL
MOV EAX,0x3
LAB_00155c5e:
POP RBP
RET
LAB_00155c60:
LEA RAX,[RSI + -0x24b0]
CMP RAX,0x3f
JA 0x00155c8b
LEA RAX,[RSI + -0x24ea]
CMP RAX,-0x34
JC 0x00155cb9
LEA RAX,[0x3db420]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x4960]
JMP 0x00155c39
LAB_00155c8b:
LEA RAX,[RSI + -0xff20]
CMP RAX,0x3f
JA 0x00155cb9
MOV RDI,-0x7fffffe07ffffff
BT RDI,RAX
JC 0x00155cb9
LEA RAX,[0x3db4a0]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x1fe40]
JMP 0x00155c39
LAB_00155cb9:
LEA RDI,[RDX + 0x5]
MOV EAX,0xffffff97
CMP RDI,RCX
JA 0x00155c5e
MOV EAX,ESI
SHR EAX,0xc
AND EAX,0xf
LEA RCX,[0x3dbfa0]
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x1],AL
MOV EAX,ESI
SHR EAX,0x8
AND EAX,0xf
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x2],AL
MOV EAX,ESI
SHR EAX,0x4
AND EAX,0xf
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x3],AL
AND ESI,0xf
MOV AL,byte ptr [RSI + RCX*0x1]
MOV byte ptr [RDX + 0x4],AL
MOV EAX,0x5
JMP 0x00155c5e
|
int8
my_wc_mb_filename(int8 param_1,ulong param_2,int1 *param_3,int1 *param_4)
{
ushort uVar1;
if (param_4 <= param_3) {
return 0xffffff9b;
}
if ((param_2 < 0x80) && (filename_safe_char[param_2] != '\0')) {
*param_3 = (char)param_2;
return 1;
}
if (param_4 < param_3 + 3) {
return 0xffffff99;
}
*param_3 = 0x40;
if (((0x53f < param_2 - 0xc0) ||
(uVar1 = *(ushort *)(uni_1E00_1FFF + param_2 * 2 + 0x3c0), uVar1 == 0)) &&
(((param_2 & 0xfffffffffffffe00) != 0x1e00 ||
(uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1f780), uVar1 == 0)))) {
if ((param_2 & 0xffffffffffffffe0) == 0x2160) {
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1f4c0);
}
else if (param_2 - 0x24b0 < 0x40) {
if (param_2 - 0x24ea < 0xffffffffffffffcc) {
LAB_00155cb9:
if (param_4 < param_3 + 5) {
return 0xffffff97;
}
param_3[1] = "0123456789abcdef"[(uint)(param_2 >> 0xc) & 0xf];
param_3[2] = "0123456789abcdef"[(uint)(param_2 >> 8) & 0xf];
param_3[3] = "0123456789abcdef"[(uint)(param_2 >> 4) & 0xf];
param_3[4] = "0123456789abcdef"[(uint)param_2 & 0xf];
return 5;
}
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1ee60);
}
else {
if ((0x3f < param_2 - 0xff20) || ((0xf8000001f8000001U >> (param_2 - 0xff20 & 0x3f) & 1) != 0)
) goto LAB_00155cb9;
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x3a00);
}
}
param_3[1] = (char)(uVar1 / 0x50) + '0';
param_3[2] = (char)uVar1 + (char)(uVar1 / 0x50 << 4) * -5 + '0';
return 3;
}
|
|
64,855 |
ma_update_state_lsns_sub
|
eloqsql/storage/maria/ma_create.c
|
int _ma_update_state_lsns_sub(MARIA_SHARE *share, LSN lsn, TrID create_trid,
my_bool do_sync,
my_bool update_create_rename_lsn)
{
uchar buf[LSN_STORE_SIZE * 3], *ptr;
uchar trid_buff[8];
File file= share->kfile.file;
DBUG_ENTER("_ma_update_state_lsns_sub");
DBUG_ASSERT(file >= 0);
CRASH_IF_S3_TABLE(share);
if (lsn == LSN_IMPOSSIBLE)
{
int res;
LEX_CUSTRING log_array[TRANSLOG_INTERNAL_PARTS + 1];
/* table name is logged only for information */
log_array[TRANSLOG_INTERNAL_PARTS + 0].str=
(uchar *)(share->open_file_name.str);
log_array[TRANSLOG_INTERNAL_PARTS + 0].length=
share->open_file_name.length + 1;
if ((res= translog_write_record(&lsn, LOGREC_IMPORTED_TABLE,
&dummy_transaction_object, NULL,
(translog_size_t)
log_array[TRANSLOG_INTERNAL_PARTS +
0].length,
sizeof(log_array)/sizeof(log_array[0]),
log_array, NULL, NULL)))
DBUG_RETURN(res);
}
for (ptr= buf; ptr < (buf + sizeof(buf)); ptr+= LSN_STORE_SIZE)
lsn_store(ptr, lsn);
share->state.skip_redo_lsn= share->state.is_of_horizon= lsn;
share->state.create_trid= create_trid;
mi_int8store(trid_buff, create_trid);
/*
Update create_rename_lsn if update was requested or if the old one had an
impossible value.
*/
if (update_create_rename_lsn ||
(share->state.create_rename_lsn > lsn && lsn != LSN_IMPOSSIBLE))
{
share->state.create_rename_lsn= lsn;
if (share->id != 0)
{
/*
If OP is the operation which is calling us, if table is later written,
we could see in the log:
FILE_ID ... REDO_OP ... REDO_INSERT.
(that can happen in real life at least with OP=REPAIR).
As FILE_ID will be ignored by Recovery because it is <
create_rename_lsn, REDO_INSERT would be ignored too, wrongly.
To avoid that, we force a LOGREC_FILE_ID to be logged at next write:
*/
translog_deassign_id_from_share(share);
}
}
else
lsn_store(buf, share->state.create_rename_lsn);
DBUG_RETURN(my_pwrite(file, buf, sizeof(buf),
sizeof(share->state.header) +
MARIA_FILE_CREATE_RENAME_LSN_OFFSET, MYF(MY_NABP)) ||
my_pwrite(file, trid_buff, sizeof(trid_buff),
sizeof(share->state.header) +
MARIA_FILE_CREATE_TRID_OFFSET, MYF(MY_NABP)) ||
(do_sync && mysql_file_sync(file, MYF(0))));
}
|
O0
|
c
|
ma_update_state_lsns_sub:
pushq %rbp
movq %rsp, %rbp
subq $0xe0, %rsp
movb %r8b, %al
movq %fs:0x28, %r8
movq %r8, -0x8(%rbp)
movq %rdi, -0x38(%rbp)
movq %rsi, -0x40(%rbp)
movq %rdx, -0x48(%rbp)
movb %cl, -0x49(%rbp)
movb %al, -0x4a(%rbp)
movq -0x38(%rbp), %rax
movl 0x760(%rax), %eax
movl %eax, -0x5c(%rbp)
jmp 0x75b9c
jmp 0x75b9e
jmp 0x75ba0
cmpq $0x0, -0x40(%rbp)
jne 0x75c24
movq -0x38(%rbp), %rax
movq 0x5e0(%rax), %rax
movq %rax, -0x70(%rbp)
movq -0x38(%rbp), %rax
movq 0x5e8(%rax), %rax
addq $0x1, %rax
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rax
movl %eax, %r8d
leaq -0x90(%rbp), %rax
leaq -0x40(%rbp), %rdi
movl $0x29, %esi
leaq 0x4020f9(%rip), %rdx # 0x477ce0
xorl %ecx, %ecx
movl $0x3, %r9d
movq %rax, (%rsp)
movq $0x0, 0x8(%rsp)
movq $0x0, 0x10(%rsp)
callq 0x32020
movsbl %al, %eax
movl %eax, -0x60(%rbp)
cmpl $0x0, %eax
je 0x75c22
jmp 0x75c17
movl -0x60(%rbp), %eax
movl %eax, -0x2c(%rbp)
jmp 0x75eea
jmp 0x75c24
leaq -0x20(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
leaq -0x20(%rbp), %rcx
addq $0x15, %rcx
cmpq %rcx, %rax
jae 0x75cb8
jmp 0x75c3f
jmp 0x75c41
movq -0x40(%rbp), %rax
sarq $0x20, %rax
movb %al, %cl
movq -0x58(%rbp), %rax
movb %cl, (%rax)
movq -0x40(%rbp), %rax
sarq $0x20, %rax
shrl $0x8, %eax
movb %al, %cl
movq -0x58(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0x40(%rbp), %rax
sarq $0x20, %rax
shrl $0x10, %eax
movb %al, %cl
movq -0x58(%rbp), %rax
movb %cl, 0x2(%rax)
jmp 0x75c7b
movq -0x58(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x98(%rbp)
movabsq $0xffffffff, %rax # imm = 0xFFFFFFFF
andq -0x40(%rbp), %rax
movl %eax, %ecx
movq -0x98(%rbp), %rax
movl %ecx, (%rax)
jmp 0x75ca5
jmp 0x75ca7
movq -0x58(%rbp), %rax
addq $0x7, %rax
movq %rax, -0x58(%rbp)
jmp 0x75c2c
movq -0x40(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x180(%rax)
movq -0x38(%rbp), %rax
movq %rcx, 0x188(%rax)
movq -0x48(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0xe0(%rax)
movq -0x48(%rbp), %rax
movq %rax, -0xa0(%rbp)
movq -0x48(%rbp), %rax
shrq $0x20, %rax
movq %rax, -0xa8(%rbp)
movq -0xa8(%rbp), %rax
movq %rax, -0xb0(%rbp)
movq -0xb0(%rbp), %rax
movb %al, -0x25(%rbp)
movq -0xb0(%rbp), %rax
shrq $0x8, %rax
movb %al, -0x26(%rbp)
movq -0xb0(%rbp), %rax
shrq $0x10, %rax
movb %al, -0x27(%rbp)
movq -0xb0(%rbp), %rax
shrq $0x18, %rax
movb %al, -0x28(%rbp)
movq -0xa0(%rbp), %rax
movq %rax, -0xb8(%rbp)
movq -0xb8(%rbp), %rax
movb %al, -0x21(%rbp)
movq -0xb8(%rbp), %rax
shrq $0x8, %rax
movb %al, -0x22(%rbp)
movq -0xb8(%rbp), %rax
shrq $0x10, %rax
movb %al, -0x23(%rbp)
movq -0xb8(%rbp), %rax
shrq $0x18, %rax
movb %al, -0x24(%rbp)
movsbl -0x4a(%rbp), %eax
cmpl $0x0, %eax
jne 0x75da0
movq -0x38(%rbp), %rax
movq 0x178(%rax), %rax
cmpq -0x40(%rbp), %rax
jle 0x75dca
cmpq $0x0, -0x40(%rbp)
je 0x75dca
movq -0x40(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x178(%rax)
movq -0x38(%rbp), %rax
movzwl 0x620(%rax), %eax
cmpl $0x0, %eax
je 0x75dc8
movq -0x38(%rbp), %rdi
callq 0x34ea0
jmp 0x75e3f
jmp 0x75dcc
jmp 0x75dce
movq -0x38(%rbp), %rax
movq 0x178(%rax), %rax
sarq $0x20, %rax
movb %al, -0x20(%rbp)
movq -0x38(%rbp), %rax
movq 0x178(%rax), %rax
sarq $0x20, %rax
shrl $0x8, %eax
movb %al, -0x1f(%rbp)
movq -0x38(%rbp), %rax
movq 0x178(%rax), %rax
sarq $0x20, %rax
shrl $0x10, %eax
movb %al, -0x1e(%rbp)
jmp 0x75e0c
leaq -0x20(%rbp), %rax
addq $0x3, %rax
movq %rax, -0xc0(%rbp)
movq -0x38(%rbp), %rcx
movabsq $0xffffffff, %rax # imm = 0xFFFFFFFF
andq 0x178(%rcx), %rax
movl %eax, %ecx
movq -0xc0(%rbp), %rax
movl %ecx, (%rax)
jmp 0x75e3d
jmp 0x75e3f
jmp 0x75e41
movl -0x5c(%rbp), %edi
leaq -0x20(%rbp), %rsi
movl $0x15, %edx
movl $0x1c, %ecx
movl $0x4, %r8d
callq 0xf4a20
movq %rax, %rcx
movb $0x1, %al
cmpq $0x0, %rcx
movb %al, -0xc1(%rbp)
jne 0x75edc
movl -0x5c(%rbp), %edi
leaq -0x28(%rbp), %rsi
movl $0x8, %edx
movl $0x89, %ecx
movl $0x4, %r8d
callq 0xf4a20
movq %rax, %rcx
movb $0x1, %al
cmpq $0x0, %rcx
movb %al, -0xc1(%rbp)
jne 0x75edc
movsbl -0x49(%rbp), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0xc2(%rbp)
je 0x75ed0
movl -0x5c(%rbp), %edx
leaq 0xdc70d(%rip), %rdi # 0x1525c3
movl $0x5f1, %esi # imm = 0x5F1
xorl %eax, %eax
movl %eax, %ecx
callq 0x76070
cmpl $0x0, %eax
setne %al
movb %al, -0xc2(%rbp)
movb -0xc2(%rbp), %al
movb %al, -0xc1(%rbp)
movb -0xc1(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movl %eax, -0xc8(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x75f14
movl -0xc8(%rbp), %eax
addq $0xe0, %rsp
popq %rbp
retq
callq 0x2a260
nopl (%rax)
|
_ma_update_state_lsns_sub:
push rbp
mov rbp, rsp
sub rsp, 0E0h
mov al, r8b
mov r8, fs:28h
mov [rbp+var_8], r8
mov [rbp+var_38], rdi
mov [rbp+var_40], rsi
mov [rbp+var_48], rdx
mov [rbp+var_49], cl
mov [rbp+var_4A], al
mov rax, [rbp+var_38]
mov eax, [rax+760h]
mov [rbp+var_5C], eax
jmp short $+2
loc_75B9C:
jmp short $+2
loc_75B9E:
jmp short $+2
loc_75BA0:
cmp [rbp+var_40], 0
jnz short loc_75C24
mov rax, [rbp+var_38]
mov rax, [rax+5E0h]
mov [rbp+var_70], rax
mov rax, [rbp+var_38]
mov rax, [rax+5E8h]
add rax, 1
mov [rbp+var_68], rax
mov rax, [rbp+var_68]
mov r8d, eax
lea rax, [rbp+var_90]
lea rdi, [rbp+var_40]
mov esi, 29h ; ')'
lea rdx, dummy_transaction_object
xor ecx, ecx
mov r9d, 3
mov [rsp+0E0h+var_E0], rax
mov [rsp+0E0h+var_D8], 0
mov [rsp+0E0h+var_D0], 0
call translog_write_record
movsx eax, al
mov [rbp+var_60], eax
cmp eax, 0
jz short loc_75C22
jmp short $+2
loc_75C17:
mov eax, [rbp+var_60]
mov [rbp+var_2C], eax
jmp loc_75EEA
loc_75C22:
jmp short $+2
loc_75C24:
lea rax, [rbp+var_20]
mov [rbp+var_58], rax
loc_75C2C:
mov rax, [rbp+var_58]
lea rcx, [rbp+var_20]
add rcx, 15h
cmp rax, rcx
jnb short loc_75CB8
jmp short $+2
loc_75C3F:
jmp short $+2
loc_75C41:
mov rax, [rbp+var_40]
sar rax, 20h
mov cl, al
mov rax, [rbp+var_58]
mov [rax], cl
mov rax, [rbp+var_40]
sar rax, 20h
shr eax, 8
mov cl, al
mov rax, [rbp+var_58]
mov [rax+1], cl
mov rax, [rbp+var_40]
sar rax, 20h
shr eax, 10h
mov cl, al
mov rax, [rbp+var_58]
mov [rax+2], cl
jmp short $+2
loc_75C7B:
mov rax, [rbp+var_58]
add rax, 3
mov [rbp+var_98], rax
mov rax, 0FFFFFFFFh
and rax, [rbp+var_40]
mov ecx, eax
mov rax, [rbp+var_98]
mov [rax], ecx
jmp short $+2
loc_75CA5:
jmp short $+2
loc_75CA7:
mov rax, [rbp+var_58]
add rax, 7
mov [rbp+var_58], rax
jmp loc_75C2C
loc_75CB8:
mov rcx, [rbp+var_40]
mov rax, [rbp+var_38]
mov [rax+180h], rcx
mov rax, [rbp+var_38]
mov [rax+188h], rcx
mov rcx, [rbp+var_48]
mov rax, [rbp+var_38]
mov [rax+0E0h], rcx
mov rax, [rbp+var_48]
mov [rbp+var_A0], rax
mov rax, [rbp+var_48]
shr rax, 20h
mov [rbp+var_A8], rax
mov rax, [rbp+var_A8]
mov [rbp+var_B0], rax
mov rax, [rbp+var_B0]
mov [rbp+var_25], al
mov rax, [rbp+var_B0]
shr rax, 8
mov [rbp+var_26], al
mov rax, [rbp+var_B0]
shr rax, 10h
mov [rbp+var_27], al
mov rax, [rbp+var_B0]
shr rax, 18h
mov [rbp+var_28], al
mov rax, [rbp+var_A0]
mov [rbp+var_B8], rax
mov rax, [rbp+var_B8]
mov [rbp+var_21], al
mov rax, [rbp+var_B8]
shr rax, 8
mov [rbp+var_22], al
mov rax, [rbp+var_B8]
shr rax, 10h
mov [rbp+var_23], al
mov rax, [rbp+var_B8]
shr rax, 18h
mov [rbp+var_24], al
movsx eax, [rbp+var_4A]
cmp eax, 0
jnz short loc_75DA0
mov rax, [rbp+var_38]
mov rax, [rax+178h]
cmp rax, [rbp+var_40]
jle short loc_75DCA
cmp [rbp+var_40], 0
jz short loc_75DCA
loc_75DA0:
mov rcx, [rbp+var_40]
mov rax, [rbp+var_38]
mov [rax+178h], rcx
mov rax, [rbp+var_38]
movzx eax, word ptr [rax+620h]
cmp eax, 0
jz short loc_75DC8
mov rdi, [rbp+var_38]
call translog_deassign_id_from_share
loc_75DC8:
jmp short loc_75E3F
loc_75DCA:
jmp short $+2
loc_75DCC:
jmp short $+2
loc_75DCE:
mov rax, [rbp+var_38]
mov rax, [rax+178h]
sar rax, 20h
mov [rbp+var_20], al
mov rax, [rbp+var_38]
mov rax, [rax+178h]
sar rax, 20h
shr eax, 8
mov [rbp+var_1F], al
mov rax, [rbp+var_38]
mov rax, [rax+178h]
sar rax, 20h
shr eax, 10h
mov [rbp+var_1E], al
jmp short $+2
loc_75E0C:
lea rax, [rbp+var_20]
add rax, 3
mov [rbp+var_C0], rax
mov rcx, [rbp+var_38]
mov rax, 0FFFFFFFFh
and rax, [rcx+178h]
mov ecx, eax
mov rax, [rbp+var_C0]
mov [rax], ecx
jmp short $+2
loc_75E3D:
jmp short $+2
loc_75E3F:
jmp short $+2
loc_75E41:
mov edi, [rbp+var_5C]
lea rsi, [rbp+var_20]
mov edx, 15h
mov ecx, 1Ch
mov r8d, 4
call my_pwrite
mov rcx, rax
mov al, 1
cmp rcx, 0
mov [rbp+var_C1], al
jnz short loc_75EDC
mov edi, [rbp+var_5C]
lea rsi, [rbp+var_28]
mov edx, 8
mov ecx, 89h
mov r8d, 4
call my_pwrite
mov rcx, rax
mov al, 1
cmp rcx, 0
mov [rbp+var_C1], al
jnz short loc_75EDC
movsx ecx, [rbp+var_49]
xor eax, eax
cmp ecx, 0
mov [rbp+var_C2], al
jz short loc_75ED0
mov edx, [rbp+var_5C]
lea rdi, aWorkspaceLlm4b_14; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 5F1h
xor eax, eax
mov ecx, eax
call inline_mysql_file_sync_4
cmp eax, 0
setnz al
mov [rbp+var_C2], al
loc_75ED0:
mov al, [rbp+var_C2]
mov [rbp+var_C1], al
loc_75EDC:
mov al, [rbp+var_C1]
and al, 1
movzx eax, al
mov [rbp+var_2C], eax
loc_75EEA:
mov eax, [rbp+var_2C]
mov [rbp+var_C8], eax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_75F14
mov eax, [rbp+var_C8]
add rsp, 0E0h
pop rbp
retn
loc_75F14:
call ___stack_chk_fail
|
long long ma_update_state_lsns_sub(long long a1, long long a2, long long a3, char a4, char a5)
{
char v5; // al
long long v6; // rcx
bool v8; // [rsp+1Eh] [rbp-C2h]
char v9; // [rsp+1Fh] [rbp-C1h]
_QWORD v10[5]; // [rsp+50h] [rbp-90h] BYREF
long long v11; // [rsp+78h] [rbp-68h]
unsigned int v12; // [rsp+80h] [rbp-60h]
unsigned int v13; // [rsp+84h] [rbp-5Ch]
_BYTE *i; // [rsp+88h] [rbp-58h]
char v15; // [rsp+96h] [rbp-4Ah]
char v16; // [rsp+97h] [rbp-49h]
long long v17; // [rsp+98h] [rbp-48h]
long long v18; // [rsp+A0h] [rbp-40h] BYREF
long long v19; // [rsp+A8h] [rbp-38h]
_BYTE v21[8]; // [rsp+B8h] [rbp-28h] BYREF
_BYTE v22[3]; // [rsp+C0h] [rbp-20h] BYREF
int v23; // [rsp+C3h] [rbp-1Dh]
_BYTE v24[11]; // [rsp+D5h] [rbp-Bh] BYREF
*(_QWORD *)&v24[3] = __readfsqword(0x28u);
v19 = a1;
v18 = a2;
v17 = a3;
v16 = a4;
v15 = a5;
v13 = *(_DWORD *)(a1 + 1888);
if ( a2
|| (v10[4] = *(_QWORD *)(v19 + 1504),
v11 = *(_QWORD *)(v19 + 1512) + 1LL,
v5 = translog_write_record((long long)&v18, 0x29u, (long long)dummy_transaction_object, 0LL, v11, 3u, v10, 0LL, 0LL),
(v12 = v5) == 0) )
{
for ( i = v22; i < v24; i += 7 )
{
*(_WORD *)i = WORD2(v18);
i[2] = BYTE6(v18);
*(_DWORD *)(i + 3) = v18;
}
v6 = v18;
*(_QWORD *)(v19 + 384) = v18;
*(_QWORD *)(v19 + 392) = v6;
*(_QWORD *)(v19 + 224) = v17;
v21[2] = BYTE5(v17);
v21[3] = BYTE4(v17);
v21[0] = HIBYTE(v17);
v21[1] = BYTE6(v17);
v21[6] = BYTE1(v17);
v21[7] = v17;
v21[4] = BYTE3(v17);
v21[5] = BYTE2(v17);
if ( v15 || *(_QWORD *)(v19 + 376) > v18 && v18 )
{
*(_QWORD *)(v19 + 376) = v18;
if ( *(_WORD *)(v19 + 1568) )
translog_deassign_id_from_share(v19);
}
else
{
v22[0] = BYTE4(*(_QWORD *)(v19 + 376));
v22[1] = (unsigned __int16)WORD2(*(_QWORD *)(v19 + 376)) >> 8;
v22[2] = BYTE6(*(_QWORD *)(v19 + 376));
v23 = *(_QWORD *)(v19 + 376);
}
v9 = 1;
if ( !my_pwrite(v13, v22, 21LL, 28LL, 4LL) )
{
v9 = 1;
if ( !my_pwrite(v13, v21, 8LL, 137LL, 4LL) )
{
v8 = 0;
if ( v16 )
v8 = (unsigned int)inline_mysql_file_sync_4(
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_create.c",
1521LL,
v13,
0LL) != 0;
v9 = v8;
}
}
return v9 & 1;
}
else
{
return v12;
}
}
|
_ma_update_state_lsns_sub:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xe0
MOV AL,R8B
MOV R8,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],R8
MOV qword ptr [RBP + -0x38],RDI
MOV qword ptr [RBP + -0x40],RSI
MOV qword ptr [RBP + -0x48],RDX
MOV byte ptr [RBP + -0x49],CL
MOV byte ptr [RBP + -0x4a],AL
MOV RAX,qword ptr [RBP + -0x38]
MOV EAX,dword ptr [RAX + 0x760]
MOV dword ptr [RBP + -0x5c],EAX
JMP 0x00175b9c
LAB_00175b9c:
JMP 0x00175b9e
LAB_00175b9e:
JMP 0x00175ba0
LAB_00175ba0:
CMP qword ptr [RBP + -0x40],0x0
JNZ 0x00175c24
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x5e0]
MOV qword ptr [RBP + -0x70],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x5e8]
ADD RAX,0x1
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RBP + -0x68]
MOV R8D,EAX
LEA RAX,[RBP + -0x90]
LEA RDI,[RBP + -0x40]
MOV ESI,0x29
LEA RDX,[0x577ce0]
XOR ECX,ECX
MOV R9D,0x3
MOV qword ptr [RSP],RAX
MOV qword ptr [RSP + 0x8],0x0
MOV qword ptr [RSP + 0x10],0x0
CALL 0x00132020
MOVSX EAX,AL
MOV dword ptr [RBP + -0x60],EAX
CMP EAX,0x0
JZ 0x00175c22
JMP 0x00175c17
LAB_00175c17:
MOV EAX,dword ptr [RBP + -0x60]
MOV dword ptr [RBP + -0x2c],EAX
JMP 0x00175eea
LAB_00175c22:
JMP 0x00175c24
LAB_00175c24:
LEA RAX,[RBP + -0x20]
MOV qword ptr [RBP + -0x58],RAX
LAB_00175c2c:
MOV RAX,qword ptr [RBP + -0x58]
LEA RCX,[RBP + -0x20]
ADD RCX,0x15
CMP RAX,RCX
JNC 0x00175cb8
JMP 0x00175c3f
LAB_00175c3f:
JMP 0x00175c41
LAB_00175c41:
MOV RAX,qword ptr [RBP + -0x40]
SAR RAX,0x20
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x58]
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x40]
SAR RAX,0x20
SHR EAX,0x8
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x58]
MOV byte ptr [RAX + 0x1],CL
MOV RAX,qword ptr [RBP + -0x40]
SAR RAX,0x20
SHR EAX,0x10
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x58]
MOV byte ptr [RAX + 0x2],CL
JMP 0x00175c7b
LAB_00175c7b:
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x3
MOV qword ptr [RBP + -0x98],RAX
MOV RAX,0xffffffff
AND RAX,qword ptr [RBP + -0x40]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x98]
MOV dword ptr [RAX],ECX
JMP 0x00175ca5
LAB_00175ca5:
JMP 0x00175ca7
LAB_00175ca7:
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x7
MOV qword ptr [RBP + -0x58],RAX
JMP 0x00175c2c
LAB_00175cb8:
MOV RCX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX + 0x180],RCX
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX + 0x188],RCX
MOV RCX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX + 0xe0],RCX
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RBP + -0xa0],RAX
MOV RAX,qword ptr [RBP + -0x48]
SHR RAX,0x20
MOV qword ptr [RBP + -0xa8],RAX
MOV RAX,qword ptr [RBP + -0xa8]
MOV qword ptr [RBP + -0xb0],RAX
MOV RAX,qword ptr [RBP + -0xb0]
MOV byte ptr [RBP + -0x25],AL
MOV RAX,qword ptr [RBP + -0xb0]
SHR RAX,0x8
MOV byte ptr [RBP + -0x26],AL
MOV RAX,qword ptr [RBP + -0xb0]
SHR RAX,0x10
MOV byte ptr [RBP + -0x27],AL
MOV RAX,qword ptr [RBP + -0xb0]
SHR RAX,0x18
MOV byte ptr [RBP + -0x28],AL
MOV RAX,qword ptr [RBP + -0xa0]
MOV qword ptr [RBP + -0xb8],RAX
MOV RAX,qword ptr [RBP + -0xb8]
MOV byte ptr [RBP + -0x21],AL
MOV RAX,qword ptr [RBP + -0xb8]
SHR RAX,0x8
MOV byte ptr [RBP + -0x22],AL
MOV RAX,qword ptr [RBP + -0xb8]
SHR RAX,0x10
MOV byte ptr [RBP + -0x23],AL
MOV RAX,qword ptr [RBP + -0xb8]
SHR RAX,0x18
MOV byte ptr [RBP + -0x24],AL
MOVSX EAX,byte ptr [RBP + -0x4a]
CMP EAX,0x0
JNZ 0x00175da0
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x178]
CMP RAX,qword ptr [RBP + -0x40]
JLE 0x00175dca
CMP qword ptr [RBP + -0x40],0x0
JZ 0x00175dca
LAB_00175da0:
MOV RCX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX + 0x178],RCX
MOV RAX,qword ptr [RBP + -0x38]
MOVZX EAX,word ptr [RAX + 0x620]
CMP EAX,0x0
JZ 0x00175dc8
MOV RDI,qword ptr [RBP + -0x38]
CALL 0x00134ea0
LAB_00175dc8:
JMP 0x00175e3f
LAB_00175dca:
JMP 0x00175dcc
LAB_00175dcc:
JMP 0x00175dce
LAB_00175dce:
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x178]
SAR RAX,0x20
MOV byte ptr [RBP + -0x20],AL
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x178]
SAR RAX,0x20
SHR EAX,0x8
MOV byte ptr [RBP + -0x1f],AL
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x178]
SAR RAX,0x20
SHR EAX,0x10
MOV byte ptr [RBP + -0x1e],AL
JMP 0x00175e0c
LAB_00175e0c:
LEA RAX,[RBP + -0x20]
ADD RAX,0x3
MOV qword ptr [RBP + -0xc0],RAX
MOV RCX,qword ptr [RBP + -0x38]
MOV RAX,0xffffffff
AND RAX,qword ptr [RCX + 0x178]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0xc0]
MOV dword ptr [RAX],ECX
JMP 0x00175e3d
LAB_00175e3d:
JMP 0x00175e3f
LAB_00175e3f:
JMP 0x00175e41
LAB_00175e41:
MOV EDI,dword ptr [RBP + -0x5c]
LEA RSI,[RBP + -0x20]
MOV EDX,0x15
MOV ECX,0x1c
MOV R8D,0x4
CALL 0x001f4a20
MOV RCX,RAX
MOV AL,0x1
CMP RCX,0x0
MOV byte ptr [RBP + -0xc1],AL
JNZ 0x00175edc
MOV EDI,dword ptr [RBP + -0x5c]
LEA RSI,[RBP + -0x28]
MOV EDX,0x8
MOV ECX,0x89
MOV R8D,0x4
CALL 0x001f4a20
MOV RCX,RAX
MOV AL,0x1
CMP RCX,0x0
MOV byte ptr [RBP + -0xc1],AL
JNZ 0x00175edc
MOVSX ECX,byte ptr [RBP + -0x49]
XOR EAX,EAX
CMP ECX,0x0
MOV byte ptr [RBP + -0xc2],AL
JZ 0x00175ed0
MOV EDX,dword ptr [RBP + -0x5c]
LEA RDI,[0x2525c3]
MOV ESI,0x5f1
XOR EAX,EAX
MOV ECX,EAX
CALL 0x00176070
CMP EAX,0x0
SETNZ AL
MOV byte ptr [RBP + -0xc2],AL
LAB_00175ed0:
MOV AL,byte ptr [RBP + -0xc2]
MOV byte ptr [RBP + -0xc1],AL
LAB_00175edc:
MOV AL,byte ptr [RBP + -0xc1]
AND AL,0x1
MOVZX EAX,AL
MOV dword ptr [RBP + -0x2c],EAX
LAB_00175eea:
MOV EAX,dword ptr [RBP + -0x2c]
MOV dword ptr [RBP + -0xc8],EAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x00175f14
MOV EAX,dword ptr [RBP + -0xc8]
ADD RSP,0xe0
POP RBP
RET
LAB_00175f14:
CALL 0x0012a260
|
uint _ma_update_state_lsns_sub
(long param_1,long param_2,int8 param_3,char param_4,char param_5)
{
char cVar1;
int iVar2;
long lVar3;
long in_FS_OFFSET;
bool local_ca;
bool local_c9;
int1 local_98 [32];
int8 local_78;
ulong local_70;
uint local_68;
int4 local_64;
int1 *local_60;
char local_52;
char local_51;
int8 local_50;
long local_48;
long local_40;
uint local_34;
int1 local_30;
int1 local_2f;
int1 local_2e;
int1 local_2d;
int1 local_2c;
int1 local_2b;
int1 local_2a;
int1 local_29;
int1 local_28;
int1 local_27;
int1 local_26;
int4 local_25;
int1 auStack_13 [3];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_64 = *(int4 *)(param_1 + 0x760);
local_52 = param_5;
local_51 = param_4;
local_50 = param_3;
local_48 = param_2;
local_40 = param_1;
if (param_2 == 0) {
local_78 = *(int8 *)(param_1 + 0x5e0);
local_70 = *(long *)(param_1 + 0x5e8) + 1;
cVar1 = translog_write_record
(&local_48,0x29,dummy_transaction_object,0,local_70 & 0xffffffff,3,local_98,0,
0);
local_68 = (uint)cVar1;
local_34 = local_68;
if (local_68 != 0) goto LAB_00175eea;
}
for (local_60 = &local_28; local_60 < auStack_13; local_60 = local_60 + 7) {
*local_60 = (char)((ulong)local_48 >> 0x20);
local_60[1] = (char)((ulong)local_48 >> 0x28);
local_60[2] = (char)((ulong)local_48 >> 0x30);
*(int *)(local_60 + 3) = (int)local_48;
}
*(long *)(local_40 + 0x180) = local_48;
*(long *)(local_40 + 0x188) = local_48;
*(int8 *)(local_40 + 0xe0) = local_50;
local_2d = (int1)((ulong)local_50 >> 0x20);
local_2e = (int1)((ulong)local_50 >> 0x28);
local_2f = (int1)((ulong)local_50 >> 0x30);
local_30 = (int1)((ulong)local_50 >> 0x38);
local_29 = (int1)local_50;
local_2a = (int1)((ulong)local_50 >> 8);
local_2b = (int1)((ulong)local_50 >> 0x10);
local_2c = (int1)((ulong)local_50 >> 0x18);
if ((local_52 == '\0') && ((*(long *)(local_40 + 0x178) <= local_48 || (local_48 == 0)))) {
local_28 = (int1)((ulong)*(int8 *)(local_40 + 0x178) >> 0x20);
local_27 = (int1)((ulong)*(int8 *)(local_40 + 0x178) >> 0x28);
local_26 = (int1)((ulong)*(int8 *)(local_40 + 0x178) >> 0x30);
local_25 = (int4)*(int8 *)(local_40 + 0x178);
}
else {
*(long *)(local_40 + 0x178) = local_48;
if (*(short *)(local_40 + 0x620) != 0) {
translog_deassign_id_from_share(local_40);
}
}
lVar3 = my_pwrite(local_64,&local_28,0x15,0x1c,4);
local_c9 = true;
if (lVar3 == 0) {
lVar3 = my_pwrite(local_64,&local_30,8,0x89,4);
local_c9 = true;
if (lVar3 == 0) {
local_ca = false;
if (local_51 != '\0') {
iVar2 = inline_mysql_file_sync
("/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_create.c",
0x5f1,local_64,0);
local_ca = iVar2 != 0;
}
local_c9 = local_ca;
}
}
local_34 = (uint)local_c9;
LAB_00175eea:
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return local_34;
}
|
|
64,856 |
re_parse_captures
|
bluesky950520[P]quickjs/libregexp.c
|
static int re_parse_captures(REParseState *s, int *phas_named_captures,
const char *capture_name)
{
const uint8_t *p;
int capture_index;
char name[TMP_BUF_SIZE];
capture_index = 1;
*phas_named_captures = 0;
for (p = s->buf_start; p < s->buf_end; p++) {
switch (*p) {
case '(':
if (p[1] == '?') {
if (p[2] == '<' && p[3] != '=' && p[3] != '!') {
*phas_named_captures = 1;
/* potential named capture */
if (capture_name) {
p += 3;
if (re_parse_group_name(name, sizeof(name), &p) == 0) {
if (!strcmp(name, capture_name))
return capture_index;
}
}
capture_index++;
if (capture_index >= CAPTURE_COUNT_MAX)
goto done;
}
} else {
capture_index++;
if (capture_index >= CAPTURE_COUNT_MAX)
goto done;
}
break;
case '\\':
p++;
break;
case '[':
for (p += 1 + (*p == ']'); p < s->buf_end && *p != ']'; p++) {
if (*p == '\\')
p++;
}
break;
}
}
done:
if (capture_name)
return -1;
else
return capture_index;
}
|
O1
|
c
|
re_parse_captures:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdx, %rbx
movl $0x0, (%rsi)
movq 0x40(%rdi), %rax
movq %rax, 0x8(%rsp)
movq 0x38(%rdi), %rcx
movl $0x1, %r14d
cmpq %rcx, %rax
jae 0x96b6a
movq %rsi, %r15
movq %rdi, %r12
movl $0x1, %r14d
leaq 0x10(%rsp), %r13
leaq 0x8(%rsp), %rbp
movzbl (%rax), %edx
cmpl $0x28, %edx
je 0x96af2
cmpl $0x5c, %edx
je 0x96ae8
cmpl $0x5b, %edx
jne 0x96b4f
leaq 0x1(%rax), %rdx
movq %rdx, 0x8(%rsp)
cmpq %rcx, %rdx
jae 0x96b4f
movzbl 0x1(%rax), %esi
cmpl $0x5c, %esi
je 0x96ad4
cmpl $0x5d, %esi
jne 0x96ae0
jmp 0x96b4f
addq $0x2, %rax
movq %rax, 0x8(%rsp)
movq %rax, %rdx
movq %rdx, %rax
incq %rdx
jmp 0x96ab6
incq %rax
movq %rax, 0x8(%rsp)
jmp 0x96b4f
cmpb $0x3f, 0x1(%rax)
jne 0x96b3f
cmpb $0x3c, 0x2(%rax)
jne 0x96b4f
movzbl 0x3(%rax), %ecx
cmpl $0x21, %ecx
je 0x96b4f
cmpl $0x3d, %ecx
je 0x96b4f
movl $0x1, (%r15)
testq %rbx, %rbx
je 0x96b3f
addq $0x3, %rax
movq %rax, 0x8(%rsp)
movq %r13, %rdi
movq %rbp, %rsi
callq 0x9680d
testl %eax, %eax
jne 0x96b3f
movq %r13, %rdi
movq %rbx, %rsi
callq 0xe500
testl %eax, %eax
je 0x96b77
leal 0x1(%r14), %eax
cmpl $0xfd, %r14d
movl %eax, %r14d
jg 0x96b6a
movq 0x8(%rsp), %rax
incq %rax
movq %rax, 0x8(%rsp)
movq 0x38(%r12), %rcx
cmpq %rcx, %rax
jb 0x96a9c
xorl %eax, %eax
negq %rbx
sbbl %eax, %eax
orl %r14d, %eax
movl %eax, %r14d
movl %r14d, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
re_parse_captures:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 98h
mov rbx, rdx
mov dword ptr [rsi], 0
mov rax, [rdi+40h]
mov [rsp+0C8h+var_C0], rax
mov rcx, [rdi+38h]
mov r14d, 1
cmp rax, rcx
jnb loc_96B6A
mov r15, rsi
mov r12, rdi
mov r14d, 1
lea r13, [rsp+0C8h+var_B8]
lea rbp, [rsp+0C8h+var_C0]
loc_96A9C:
movzx edx, byte ptr [rax]
cmp edx, 28h ; '('
jz short loc_96AF2
cmp edx, 5Ch ; '\'
jz short loc_96AE8
cmp edx, 5Bh ; '['
jnz loc_96B4F
lea rdx, [rax+1]
loc_96AB6:
mov [rsp+0C8h+var_C0], rdx
cmp rdx, rcx
jnb loc_96B4F
movzx esi, byte ptr [rax+1]
cmp esi, 5Ch ; '\'
jz short loc_96AD4
cmp esi, 5Dh ; ']'
jnz short loc_96AE0
jmp short loc_96B4F
loc_96AD4:
add rax, 2
mov [rsp+0C8h+var_C0], rax
mov rdx, rax
loc_96AE0:
mov rax, rdx
inc rdx
jmp short loc_96AB6
loc_96AE8:
inc rax
mov [rsp+0C8h+var_C0], rax
jmp short loc_96B4F
loc_96AF2:
cmp byte ptr [rax+1], 3Fh ; '?'
jnz short loc_96B3F
cmp byte ptr [rax+2], 3Ch ; '<'
jnz short loc_96B4F
movzx ecx, byte ptr [rax+3]
cmp ecx, 21h ; '!'
jz short loc_96B4F
cmp ecx, 3Dh ; '='
jz short loc_96B4F
mov dword ptr [r15], 1
test rbx, rbx
jz short loc_96B3F
add rax, 3
mov [rsp+0C8h+var_C0], rax
mov rdi, r13
mov rsi, rbp
call re_parse_group_name
test eax, eax
jnz short loc_96B3F
mov rdi, r13
mov rsi, rbx
call _strcmp
test eax, eax
jz short loc_96B77
loc_96B3F:
lea eax, [r14+1]
cmp r14d, 0FDh
mov r14d, eax
jg short loc_96B6A
loc_96B4F:
mov rax, [rsp+0C8h+var_C0]
inc rax
mov [rsp+0C8h+var_C0], rax
mov rcx, [r12+38h]
cmp rax, rcx
jb loc_96A9C
loc_96B6A:
xor eax, eax
neg rbx
sbb eax, eax
or eax, r14d
mov r14d, eax
loc_96B77:
mov eax, r14d
add rsp, 98h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long re_parse_captures(long long a1, _DWORD *a2, long long a3)
{
unsigned __int8 *v4; // rax
unsigned long long v5; // rcx
unsigned int v6; // r14d
int v8; // edx
unsigned __int8 *i; // rdx
int v10; // esi
int v11; // ecx
unsigned __int8 *v14; // [rsp+8h] [rbp-C0h] BYREF
_BYTE v15[184]; // [rsp+10h] [rbp-B8h] BYREF
*a2 = 0;
v4 = *(unsigned __int8 **)(a1 + 64);
v14 = v4;
v5 = *(_QWORD *)(a1 + 56);
v6 = 1;
if ( (unsigned long long)v4 < v5 )
{
v6 = 1;
do
{
v8 = *v4;
switch ( v8 )
{
case '(':
if ( v4[1] != 63 )
goto LABEL_21;
if ( v4[2] == 60 )
{
v11 = v4[3];
if ( v11 != 33 && v11 != 61 )
{
*a2 = 1;
if ( a3 )
{
v14 = v4 + 3;
if ( !(unsigned int)re_parse_group_name(v15, &v14) && !(unsigned int)strcmp(v15, a3) )
return v6;
}
LABEL_21:
if ( (int)v6++ > 253 )
goto LABEL_23;
}
}
break;
case '\\':
v14 = v4 + 1;
break;
case '[':
for ( i = v4 + 1; ; ++i )
{
v14 = i;
if ( (unsigned long long)i >= v5 )
break;
v10 = v4[1];
if ( v10 == 92 )
{
v14 = v4 + 2;
i = v4 + 2;
}
else if ( v10 == 93 )
{
goto LABEL_22;
}
v4 = i;
}
break;
}
LABEL_22:
v4 = v14 + 1;
v14 = v4;
v5 = *(_QWORD *)(a1 + 56);
}
while ( (unsigned long long)v4 < v5 );
}
LABEL_23:
v6 |= -(a3 != 0);
return v6;
}
|
re_parse_captures:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x98
MOV RBX,RDX
MOV dword ptr [RSI],0x0
MOV RAX,qword ptr [RDI + 0x40]
MOV qword ptr [RSP + 0x8],RAX
MOV RCX,qword ptr [RDI + 0x38]
MOV R14D,0x1
CMP RAX,RCX
JNC 0x00196b6a
MOV R15,RSI
MOV R12,RDI
MOV R14D,0x1
LEA R13,[RSP + 0x10]
LEA RBP,[RSP + 0x8]
LAB_00196a9c:
MOVZX EDX,byte ptr [RAX]
CMP EDX,0x28
JZ 0x00196af2
CMP EDX,0x5c
JZ 0x00196ae8
CMP EDX,0x5b
JNZ 0x00196b4f
LEA RDX,[RAX + 0x1]
LAB_00196ab6:
MOV qword ptr [RSP + 0x8],RDX
CMP RDX,RCX
JNC 0x00196b4f
MOVZX ESI,byte ptr [RAX + 0x1]
CMP ESI,0x5c
JZ 0x00196ad4
CMP ESI,0x5d
JNZ 0x00196ae0
JMP 0x00196b4f
LAB_00196ad4:
ADD RAX,0x2
MOV qword ptr [RSP + 0x8],RAX
MOV RDX,RAX
LAB_00196ae0:
MOV RAX,RDX
INC RDX
JMP 0x00196ab6
LAB_00196ae8:
INC RAX
MOV qword ptr [RSP + 0x8],RAX
JMP 0x00196b4f
LAB_00196af2:
CMP byte ptr [RAX + 0x1],0x3f
JNZ 0x00196b3f
CMP byte ptr [RAX + 0x2],0x3c
JNZ 0x00196b4f
MOVZX ECX,byte ptr [RAX + 0x3]
CMP ECX,0x21
JZ 0x00196b4f
CMP ECX,0x3d
JZ 0x00196b4f
MOV dword ptr [R15],0x1
TEST RBX,RBX
JZ 0x00196b3f
ADD RAX,0x3
MOV qword ptr [RSP + 0x8],RAX
MOV RDI,R13
MOV RSI,RBP
CALL 0x0019680d
TEST EAX,EAX
JNZ 0x00196b3f
MOV RDI,R13
MOV RSI,RBX
CALL 0x0010e500
TEST EAX,EAX
JZ 0x00196b77
LAB_00196b3f:
LEA EAX,[R14 + 0x1]
CMP R14D,0xfd
MOV R14D,EAX
JG 0x00196b6a
LAB_00196b4f:
MOV RAX,qword ptr [RSP + 0x8]
INC RAX
MOV qword ptr [RSP + 0x8],RAX
MOV RCX,qword ptr [R12 + 0x38]
CMP RAX,RCX
JC 0x00196a9c
LAB_00196b6a:
XOR EAX,EAX
NEG RBX
SBB EAX,EAX
OR EAX,R14D
MOV R14D,EAX
LAB_00196b77:
MOV EAX,R14D
ADD RSP,0x98
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
uint re_parse_captures(long param_1,int4 *param_2,char *param_3)
{
char *pcVar1;
char cVar2;
bool bVar3;
int iVar4;
uint uVar5;
char *pcVar6;
char *pcVar7;
uint uVar8;
char *local_c0;
char local_b8 [136];
*param_2 = 0;
local_c0 = *(char **)(param_1 + 0x40);
pcVar7 = *(char **)(param_1 + 0x38);
uVar5 = 1;
if (local_c0 < pcVar7) {
uVar8 = 1;
do {
cVar2 = *local_c0;
if (cVar2 == '(') {
if (local_c0[1] == '?') {
if (((local_c0[2] != '<') || (local_c0[3] == '!')) || (local_c0[3] == '='))
goto LAB_00196b4f;
*param_2 = 1;
if (param_3 != (char *)0x0) {
local_c0 = local_c0 + 3;
iVar4 = re_parse_group_name(local_b8,&local_c0);
if ((iVar4 == 0) && (iVar4 = strcmp(local_b8,param_3), iVar4 == 0)) {
return uVar8;
}
}
}
uVar5 = uVar8 + 1;
bVar3 = 0xfd < (int)uVar8;
uVar8 = uVar5;
if (bVar3) break;
}
else if (cVar2 == '\\') {
local_c0 = local_c0 + 1;
}
else {
pcVar6 = local_c0;
if (cVar2 == '[') {
do {
while( true ) {
local_c0 = pcVar6 + 1;
if (pcVar7 <= local_c0) goto LAB_00196b4f;
pcVar1 = pcVar6 + 1;
if (*pcVar1 != '\\') break;
pcVar6 = pcVar6 + 2;
}
pcVar6 = local_c0;
} while (*pcVar1 != ']');
}
}
LAB_00196b4f:
local_c0 = local_c0 + 1;
pcVar7 = *(char **)(param_1 + 0x38);
uVar5 = uVar8;
} while (local_c0 < pcVar7);
}
return -(uint)(param_3 != (char *)0x0) | uVar5;
}
|
|
64,857 |
re_parse_captures
|
bluesky950520[P]quickjs/libregexp.c
|
static int re_parse_captures(REParseState *s, int *phas_named_captures,
const char *capture_name)
{
const uint8_t *p;
int capture_index;
char name[TMP_BUF_SIZE];
capture_index = 1;
*phas_named_captures = 0;
for (p = s->buf_start; p < s->buf_end; p++) {
switch (*p) {
case '(':
if (p[1] == '?') {
if (p[2] == '<' && p[3] != '=' && p[3] != '!') {
*phas_named_captures = 1;
/* potential named capture */
if (capture_name) {
p += 3;
if (re_parse_group_name(name, sizeof(name), &p) == 0) {
if (!strcmp(name, capture_name))
return capture_index;
}
}
capture_index++;
if (capture_index >= CAPTURE_COUNT_MAX)
goto done;
}
} else {
capture_index++;
if (capture_index >= CAPTURE_COUNT_MAX)
goto done;
}
break;
case '\\':
p++;
break;
case '[':
for (p += 1 + (*p == ']'); p < s->buf_end && *p != ']'; p++) {
if (*p == '\\')
p++;
}
break;
}
}
done:
if (capture_name)
return -1;
else
return capture_index;
}
|
O3
|
c
|
re_parse_captures:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdx, %rbx
movl $0x0, (%rsi)
movq 0x40(%rdi), %rcx
movq %rcx, 0x8(%rsp)
movq 0x38(%rdi), %rax
movl $0x1, %edx
cmpq %rax, %rcx
jae 0x99451
movq %rsi, %r14
movq %rdi, %r15
movl $0x1, %ebp
leaq 0x10(%rsp), %r12
leaq 0x8(%rsp), %r13
movzbl (%rcx), %edx
cmpl $0x28, %edx
je 0x993c9
cmpl $0x5c, %edx
je 0x993c4
cmpl $0x5b, %edx
jne 0x9942f
leaq 0x1(%rcx), %rdx
movq %rdx, 0x8(%rsp)
cmpq %rax, %rdx
jae 0x9942c
movzbl 0x1(%rcx), %esi
cmpl $0x5c, %esi
je 0x993b5
cmpl $0x5d, %esi
jne 0x993bc
jmp 0x9942c
addq $0x2, %rcx
movq %rcx, %rdx
movq %rdx, %rcx
incq %rdx
jmp 0x99397
incq %rcx
jmp 0x9942f
cmpb $0x3f, 0x1(%rcx)
jne 0x99446
cmpb $0x3c, 0x2(%rcx)
jne 0x9942f
movzbl 0x3(%rcx), %edx
cmpl $0x21, %edx
je 0x9942f
cmpl $0x3d, %edx
je 0x9942f
movl $0x1, (%r14)
testq %rbx, %rbx
je 0x99416
addq $0x3, %rcx
movq %rcx, 0x8(%rsp)
movq %r12, %rdi
movq %r13, %rsi
callq 0x990f8
testl %eax, %eax
jne 0x99416
movq %r12, %rdi
movq %rbx, %rsi
callq 0xe500
testl %eax, %eax
je 0x9945a
leal 0x1(%rbp), %edx
cmpl $0xfd, %ebp
jg 0x99451
movq 0x8(%rsp), %rcx
movq 0x38(%r15), %rax
jmp 0x99431
movq %rdx, %rcx
movl %ebp, %edx
incq %rcx
movq %rcx, 0x8(%rsp)
movl %edx, %ebp
cmpq %rax, %rcx
jb 0x9937d
jmp 0x99451
leal 0x1(%rbp), %edx
cmpl $0xfd, %ebp
jle 0x99431
xorl %ebp, %ebp
negq %rbx
sbbl %ebp, %ebp
orl %edx, %ebp
movl %ebp, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
re_parse_captures:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 98h
mov rbx, rdx
mov dword ptr [rsi], 0
mov rcx, [rdi+40h]
mov [rsp+0C8h+var_C0], rcx
mov rax, [rdi+38h]
mov edx, 1
cmp rcx, rax
jnb loc_99451
mov r14, rsi
mov r15, rdi
mov ebp, 1
lea r12, [rsp+0C8h+var_B8]
lea r13, [rsp+0C8h+var_C0]
loc_9937D:
movzx edx, byte ptr [rcx]
cmp edx, 28h ; '('
jz short loc_993C9
cmp edx, 5Ch ; '\'
jz short loc_993C4
cmp edx, 5Bh ; '['
jnz loc_9942F
lea rdx, [rcx+1]
loc_99397:
mov [rsp+0C8h+var_C0], rdx
cmp rdx, rax
jnb loc_9942C
movzx esi, byte ptr [rcx+1]
cmp esi, 5Ch ; '\'
jz short loc_993B5
cmp esi, 5Dh ; ']'
jnz short loc_993BC
jmp short loc_9942C
loc_993B5:
add rcx, 2
mov rdx, rcx
loc_993BC:
mov rcx, rdx
inc rdx
jmp short loc_99397
loc_993C4:
inc rcx
jmp short loc_9942F
loc_993C9:
cmp byte ptr [rcx+1], 3Fh ; '?'
jnz short loc_99446
cmp byte ptr [rcx+2], 3Ch ; '<'
jnz short loc_9942F
movzx edx, byte ptr [rcx+3]
cmp edx, 21h ; '!'
jz short loc_9942F
cmp edx, 3Dh ; '='
jz short loc_9942F
mov dword ptr [r14], 1
test rbx, rbx
jz short loc_99416
add rcx, 3
mov [rsp+0C8h+var_C0], rcx
mov rdi, r12
mov rsi, r13
call re_parse_group_name
test eax, eax
jnz short loc_99416
mov rdi, r12
mov rsi, rbx
call _strcmp
test eax, eax
jz short loc_9945A
loc_99416:
lea edx, [rbp+1]
cmp ebp, 0FDh
jg short loc_99451
mov rcx, [rsp+0C8h+var_C0]
mov rax, [r15+38h]
jmp short loc_99431
loc_9942C:
mov rcx, rdx
loc_9942F:
mov edx, ebp
loc_99431:
inc rcx
mov [rsp+0C8h+var_C0], rcx
mov ebp, edx
cmp rcx, rax
jb loc_9937D
jmp short loc_99451
loc_99446:
lea edx, [rbp+1]
cmp ebp, 0FDh
jle short loc_99431
loc_99451:
xor ebp, ebp
neg rbx
sbb ebp, ebp
or ebp, edx
loc_9945A:
mov eax, ebp
add rsp, 98h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long re_parse_captures(long long a1, _DWORD *a2, long long a3)
{
unsigned __int8 *v4; // rcx
unsigned long long v5; // rax
int v6; // edx
int v8; // ebp
int v9; // edx
unsigned __int8 *i; // rdx
int v11; // esi
int v12; // edx
unsigned __int8 *v14; // [rsp+8h] [rbp-C0h] BYREF
_BYTE v15[184]; // [rsp+10h] [rbp-B8h] BYREF
*a2 = 0;
v4 = *(unsigned __int8 **)(a1 + 64);
v14 = v4;
v5 = *(_QWORD *)(a1 + 56);
v6 = 1;
if ( (unsigned long long)v4 < v5 )
{
v8 = 1;
while ( 1 )
{
v9 = *v4;
if ( v9 != 40 )
break;
if ( v4[1] == 63 )
{
if ( v4[2] != 60 )
goto LABEL_24;
v12 = v4[3];
if ( v12 == 33 || v12 == 61 )
goto LABEL_24;
*a2 = 1;
if ( a3 )
{
v14 = v4 + 3;
if ( !(unsigned int)re_parse_group_name(v15, &v14) && !(unsigned int)strcmp(v15, a3) )
return (unsigned int)v8;
}
v6 = v8 + 1;
if ( v8 > 253 )
return (unsigned int)(a3 != 0 ? -1 : v6);
v4 = v14;
v5 = *(_QWORD *)(a1 + 56);
}
else
{
v6 = v8 + 1;
if ( v8 > 253 )
return (unsigned int)(a3 != 0 ? -1 : v6);
}
LABEL_25:
v14 = ++v4;
v8 = v6;
if ( (unsigned long long)v4 >= v5 )
return (unsigned int)(a3 != 0 ? -1 : v6);
}
if ( v9 == 92 )
{
++v4;
}
else if ( v9 == 91 )
{
for ( i = v4 + 1; ; ++i )
{
v14 = i;
if ( (unsigned long long)i >= v5 )
break;
v11 = v4[1];
if ( v11 == 92 )
{
i = v4 + 2;
}
else if ( v11 == 93 )
{
break;
}
v4 = i;
}
v4 = i;
}
LABEL_24:
v6 = v8;
goto LABEL_25;
}
return (unsigned int)(a3 != 0 ? -1 : v6);
}
|
re_parse_captures:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x98
MOV RBX,RDX
MOV dword ptr [RSI],0x0
MOV RCX,qword ptr [RDI + 0x40]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RDI + 0x38]
MOV EDX,0x1
CMP RCX,RAX
JNC 0x00199451
MOV R14,RSI
MOV R15,RDI
MOV EBP,0x1
LEA R12,[RSP + 0x10]
LEA R13,[RSP + 0x8]
LAB_0019937d:
MOVZX EDX,byte ptr [RCX]
CMP EDX,0x28
JZ 0x001993c9
CMP EDX,0x5c
JZ 0x001993c4
CMP EDX,0x5b
JNZ 0x0019942f
LEA RDX,[RCX + 0x1]
LAB_00199397:
MOV qword ptr [RSP + 0x8],RDX
CMP RDX,RAX
JNC 0x0019942c
MOVZX ESI,byte ptr [RCX + 0x1]
CMP ESI,0x5c
JZ 0x001993b5
CMP ESI,0x5d
JNZ 0x001993bc
JMP 0x0019942c
LAB_001993b5:
ADD RCX,0x2
MOV RDX,RCX
LAB_001993bc:
MOV RCX,RDX
INC RDX
JMP 0x00199397
LAB_001993c4:
INC RCX
JMP 0x0019942f
LAB_001993c9:
CMP byte ptr [RCX + 0x1],0x3f
JNZ 0x00199446
CMP byte ptr [RCX + 0x2],0x3c
JNZ 0x0019942f
MOVZX EDX,byte ptr [RCX + 0x3]
CMP EDX,0x21
JZ 0x0019942f
CMP EDX,0x3d
JZ 0x0019942f
MOV dword ptr [R14],0x1
TEST RBX,RBX
JZ 0x00199416
ADD RCX,0x3
MOV qword ptr [RSP + 0x8],RCX
MOV RDI,R12
MOV RSI,R13
CALL 0x001990f8
TEST EAX,EAX
JNZ 0x00199416
MOV RDI,R12
MOV RSI,RBX
CALL 0x0010e500
TEST EAX,EAX
JZ 0x0019945a
LAB_00199416:
LEA EDX,[RBP + 0x1]
CMP EBP,0xfd
JG 0x00199451
MOV RCX,qword ptr [RSP + 0x8]
MOV RAX,qword ptr [R15 + 0x38]
JMP 0x00199431
LAB_0019942c:
MOV RCX,RDX
LAB_0019942f:
MOV EDX,EBP
LAB_00199431:
INC RCX
MOV qword ptr [RSP + 0x8],RCX
MOV EBP,EDX
CMP RCX,RAX
JC 0x0019937d
JMP 0x00199451
LAB_00199446:
LEA EDX,[RBP + 0x1]
CMP EBP,0xfd
JLE 0x00199431
LAB_00199451:
XOR EBP,EBP
NEG RBX
SBB EBP,EBP
OR EBP,EDX
LAB_0019945a:
MOV EAX,EBP
ADD RSP,0x98
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
uint re_parse_captures(long param_1,int4 *param_2,char *param_3)
{
char *pcVar1;
char cVar2;
int iVar3;
char *pcVar4;
char *pcVar5;
uint uVar6;
uint uVar7;
char *local_c0;
char local_b8 [136];
*param_2 = 0;
local_c0 = *(char **)(param_1 + 0x40);
pcVar4 = *(char **)(param_1 + 0x38);
uVar6 = 1;
if (local_c0 < pcVar4) {
uVar7 = 1;
do {
cVar2 = *local_c0;
uVar6 = uVar7;
if (cVar2 == '(') {
if (local_c0[1] == '?') {
if (((local_c0[2] == '<') && (local_c0[3] != '!')) && (local_c0[3] != '=')) {
*param_2 = 1;
if (param_3 != (char *)0x0) {
local_c0 = local_c0 + 3;
iVar3 = re_parse_group_name(local_b8,&local_c0);
if ((iVar3 == 0) && (iVar3 = strcmp(local_b8,param_3), iVar3 == 0)) {
return uVar7;
}
}
uVar6 = uVar7 + 1;
if (0xfd < (int)uVar7) break;
pcVar4 = *(char **)(param_1 + 0x38);
}
}
else {
uVar6 = uVar7 + 1;
if (0xfd < (int)uVar7) break;
}
}
else if (cVar2 == '\\') {
local_c0 = local_c0 + 1;
}
else {
pcVar5 = local_c0;
if (cVar2 == '[') {
do {
while( true ) {
local_c0 = pcVar5 + 1;
if (pcVar4 <= local_c0) goto LAB_00199431;
pcVar1 = pcVar5 + 1;
if (*pcVar1 != '\\') break;
pcVar5 = pcVar5 + 2;
}
pcVar5 = local_c0;
} while (*pcVar1 != ']');
}
}
LAB_00199431:
local_c0 = local_c0 + 1;
uVar7 = uVar6;
} while (local_c0 < pcVar4);
}
return -(uint)(param_3 != (char *)0x0) | uVar6;
}
|
|
64,858 |
mi_write_keypage
|
eloqsql/storage/myisam/mi_page.c
|
int _mi_write_keypage(register MI_INFO *info, register MI_KEYDEF *keyinfo,
my_off_t page, int level, uchar *buff)
{
reg3 uint length;
DBUG_ENTER("_mi_write_keypage");
#ifndef FAST /* Safety check */
if (page < info->s->base.keystart ||
page+keyinfo->block_length > info->state->key_file_length ||
(page & (MI_MIN_KEY_BLOCK_LENGTH-1)))
{
DBUG_PRINT("error",("Trying to write inside key status region: key_start: %lu length: %lu page: %lu",
(long) info->s->base.keystart,
(long) info->state->key_file_length,
(long) page));
my_errno=EINVAL;
DBUG_RETURN((-1));
}
DBUG_PRINT("page",("write page at: %lu",(long) page));
DBUG_DUMP("buff",(uchar*) buff,mi_getint(buff));
#endif
if ((length=keyinfo->block_length) > IO_SIZE*2 &&
info->state->key_file_length != page+length)
length= ((mi_getint(buff)+IO_SIZE-1) & (uint) ~(IO_SIZE-1));
DBUG_RETURN((key_cache_write(info->s->key_cache,
info->s->kfile, &info->s->dirty_part_map,
page, level, (uchar*) buff, length,
(uint) keyinfo->block_length,
(int) ((info->lock_type != F_UNLCK) ||
info->s->delay_key_write))));
}
|
O3
|
c
|
mi_write_keypage:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq (%rdi), %r11
cmpq %rdx, 0x108(%r11)
jbe 0x3ea38
callq 0x5ecfe
movl $0x16, (%rax)
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
jmp 0x3eade
movq %r8, %r9
movl %ecx, %r8d
movq %rdx, %rcx
testl $0x3ff, %ecx # imm = 0x3FF
jne 0x3ea23
movzwl 0xe(%rsi), %r10d
leaq (%r10,%rcx), %rax
movq 0x8(%rdi), %rdx
movq 0x20(%rdx), %rdx
cmpq %rdx, %rax
ja 0x3ea23
cmpl $0x2001, %r10d # imm = 0x2001
setb %sil
cmpq %rax, %rdx
sete %al
orb %sil, %al
movl %r10d, %ebx
jne 0x3ea96
movzbl 0x1(%r9), %eax
movzbl (%r9), %edx
andl $0x7f, %edx
shll $0x8, %edx
leal (%rax,%rdx), %ebx
addl $0xfff, %ebx # imm = 0xFFF
andl $0xf000, %ebx # imm = 0xF000
movq 0x278(%r11), %rax
movl 0x350(%r11), %esi
leaq 0x280(%r11), %rdx
movl $0x1, %r14d
cmpl $0x2, 0x1f4(%rdi)
jne 0x3eac9
xorl %r14d, %r14d
cmpb $0x0, 0x383(%r11)
setne %r14b
subq $0x8, %rsp
movq %rax, %rdi
pushq %r14
pushq %r10
pushq %rbx
callq 0x565f6
addq $0x20, %rsp
popq %rbx
popq %r14
popq %rbp
retq
|
_mi_write_keypage:
push rbp
mov rbp, rsp
push r14
push rbx
mov r11, [rdi]
cmp [r11+108h], rdx
jbe short loc_3EA38
loc_3EA23:
call _my_thread_var
mov dword ptr [rax], 16h
mov eax, 0FFFFFFFFh
jmp loc_3EADE
loc_3EA38:
mov r9, r8
mov r8d, ecx
mov rcx, rdx
test ecx, 3FFh
jnz short loc_3EA23
movzx r10d, word ptr [rsi+0Eh]
lea rax, [r10+rcx]
mov rdx, [rdi+8]
mov rdx, [rdx+20h]
cmp rax, rdx
ja short loc_3EA23
cmp r10d, 2001h
setb sil
cmp rdx, rax
setz al
or al, sil
mov ebx, r10d
jnz short loc_3EA96
movzx eax, byte ptr [r9+1]
movzx edx, byte ptr [r9]
and edx, 7Fh
shl edx, 8
lea ebx, [rax+rdx]
add ebx, 0FFFh
and ebx, 0F000h
loc_3EA96:
mov rax, [r11+278h]
mov esi, [r11+350h]
lea rdx, [r11+280h]
mov r14d, 1
cmp dword ptr [rdi+1F4h], 2
jnz short loc_3EAC9
xor r14d, r14d
cmp byte ptr [r11+383h], 0
setnz r14b
loc_3EAC9:
sub rsp, 8
mov rdi, rax
push r14
push r10
push rbx
call key_cache_write
add rsp, 20h
loc_3EADE:
pop rbx
pop r14
pop rbp
retn
|
long long mi_write_keypage(long long *a1, long long a2, unsigned long long a3, unsigned int a4, _BYTE *a5)
{
long long v5; // r11
long long v8; // r8
long long v10; // r10
long long v11; // rax
unsigned long long v12; // rdx
long long v13; // rbx
_BOOL8 v14; // r14
v5 = *a1;
if ( *(_QWORD *)(*a1 + 264) > a3
|| (v8 = a4, (a3 & 0x3FF) != 0)
|| (v10 = *(unsigned __int16 *)(a2 + 14), v11 = v10 + a3, v12 = *(_QWORD *)(a1[1] + 32), v10 + a3 > v12) )
{
*(_DWORD *)my_thread_var(a1, (const char *)a2) = 22;
return 0xFFFFFFFFLL;
}
else
{
v13 = *(unsigned __int16 *)(a2 + 14);
if ( (unsigned int)v10 >= 0x2001 && v12 != v11 )
v13 = (unsigned __int16)((unsigned __int8)a5[1] + ((*a5 & 0x7F) << 8) + 4095) & 0xF000;
v14 = 1LL;
if ( *((_DWORD *)a1 + 125) == 2 )
v14 = *(_BYTE *)(v5 + 899) != 0;
return key_cache_write(*(_QWORD *)(v5 + 632), *(unsigned int *)(v5 + 848), v5 + 640, a3, v8, a5, v13, v10, v14);
}
}
|
_mi_write_keypage:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV R11,qword ptr [RDI]
CMP qword ptr [R11 + 0x108],RDX
JBE 0x0013ea38
LAB_0013ea23:
CALL 0x0015ecfe
MOV dword ptr [RAX],0x16
MOV EAX,0xffffffff
JMP 0x0013eade
LAB_0013ea38:
MOV R9,R8
MOV R8D,ECX
MOV RCX,RDX
TEST ECX,0x3ff
JNZ 0x0013ea23
MOVZX R10D,word ptr [RSI + 0xe]
LEA RAX,[R10 + RCX*0x1]
MOV RDX,qword ptr [RDI + 0x8]
MOV RDX,qword ptr [RDX + 0x20]
CMP RAX,RDX
JA 0x0013ea23
CMP R10D,0x2001
SETC SIL
CMP RDX,RAX
SETZ AL
OR AL,SIL
MOV EBX,R10D
JNZ 0x0013ea96
MOVZX EAX,byte ptr [R9 + 0x1]
MOVZX EDX,byte ptr [R9]
AND EDX,0x7f
SHL EDX,0x8
LEA EBX,[RAX + RDX*0x1]
ADD EBX,0xfff
AND EBX,0xf000
LAB_0013ea96:
MOV RAX,qword ptr [R11 + 0x278]
MOV ESI,dword ptr [R11 + 0x350]
LEA RDX,[R11 + 0x280]
MOV R14D,0x1
CMP dword ptr [RDI + 0x1f4],0x2
JNZ 0x0013eac9
XOR R14D,R14D
CMP byte ptr [R11 + 0x383],0x0
SETNZ R14B
LAB_0013eac9:
SUB RSP,0x8
MOV RDI,RAX
PUSH R14
PUSH R10
PUSH RBX
CALL 0x001565f6
ADD RSP,0x20
LAB_0013eade:
POP RBX
POP R14
POP RBP
RET
|
int8
_mi_write_keypage(long *param_1,long param_2,ulong param_3,int4 param_4,byte *param_5)
{
ulong uVar1;
long lVar2;
int4 *puVar3;
int8 uVar4;
ushort uVar5;
ulong uVar6;
bool bVar7;
lVar2 = *param_1;
if ((*(ulong *)(lVar2 + 0x108) <= param_3) && ((param_3 & 0x3ff) == 0)) {
uVar5 = *(ushort *)(param_2 + 0xe);
uVar6 = (ulong)uVar5;
uVar1 = uVar6 + param_3;
if (uVar1 <= *(ulong *)(param_1[1] + 0x20)) {
if (*(ulong *)(param_1[1] + 0x20) != uVar1 && 0x2000 < uVar5) {
uVar5 = (ushort)param_5[1] + (*param_5 & 0x7f) * 0x100 + 0xfff & 0xf000;
}
bVar7 = true;
if (*(int *)((long)param_1 + 500) == 2) {
bVar7 = *(char *)(lVar2 + 899) != '\0';
}
uVar4 = key_cache_write(*(int8 *)(lVar2 + 0x278),*(int4 *)(lVar2 + 0x350),
lVar2 + 0x280,param_3,param_4,param_5,uVar5,uVar6,bVar7);
return uVar4;
}
}
puVar3 = (int4 *)_my_thread_var();
*puVar3 = 0x16;
return 0xffffffff;
}
|
|
64,859 |
my_strerror
|
eloqsql/strings/my_vsnprintf.c
|
const char* my_strerror(char *buf, size_t len, int nr)
{
char *msg= NULL;
buf[0]= '\0'; /* failsafe */
if (nr <= 0)
{
strmake(buf, (nr == 0 ?
"Internal error/check (Not system error)" :
"Internal error < 0 (Not system error)"),
len-1);
return buf;
}
/*
These (handler-) error messages are shared by perror, as required
by the principle of least surprise.
*/
if ((nr >= HA_ERR_FIRST) && (nr <= HA_ERR_LAST))
{
msg= (char *) handler_error_messages[nr - HA_ERR_FIRST];
strmake(buf, msg, len - 1);
}
else
{
/*
On Windows, do things the Windows way. On a system that supports both
the GNU and the XSI variant, use whichever was configured (GNU); if
this choice is not advertised, use the default (POSIX/XSI). Testing
for __GNUC__ is not sufficient to determine whether this choice exists.
*/
#if defined(_WIN32)
strerror_s(buf, len, nr);
#elif ((defined _POSIX_C_SOURCE && (_POSIX_C_SOURCE >= 200112L)) || \
(defined _XOPEN_SOURCE && (_XOPEN_SOURCE >= 600))) && \
! defined _GNU_SOURCE
strerror_r(nr, buf, len); /* I can build with or without GNU */
#elif defined(__GLIBC__) && defined (_GNU_SOURCE)
char *r= strerror_r(nr, buf, len);
if (r != buf) /* Want to help, GNU? */
strmake(buf, r, len - 1); /* Then don't. */
#else
strerror_r(nr, buf, len);
#endif
}
/*
strerror() return values are implementation-dependent, so let's
be pragmatic.
*/
if (!buf[0])
strmake(buf, "unknown error", len - 1);
return buf;
}
|
O0
|
c
|
my_strerror:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq $0x0, -0x28(%rbp)
movq -0x10(%rbp), %rax
movb $0x0, (%rax)
cmpl $0x0, -0x1c(%rbp)
jg 0x857be
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %ecx
leaq 0x6cd23(%rip), %rsi # 0xf24b9
leaq 0x6ccf4(%rip), %rax # 0xf2491
cmpl $0x0, %ecx
cmoveq %rax, %rsi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
callq 0x86440
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x8585a
cmpl $0x78, -0x1c(%rbp)
jl 0x857fc
cmpl $0xc6, -0x1c(%rbp)
jg 0x857fc
movl -0x1c(%rbp), %eax
subl $0x78, %eax
movslq %eax, %rcx
leaq 0x3781f3(%rip), %rax # 0x3fd9d0
movq (%rax,%rcx,8), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
callq 0x86440
jmp 0x85831
movl -0x1c(%rbp), %edi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x290d0
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
cmpq -0x10(%rbp), %rax
je 0x8582f
movq -0x10(%rbp), %rdi
movq -0x30(%rbp), %rsi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
callq 0x86440
jmp 0x85831
movq -0x10(%rbp), %rax
cmpb $0x0, (%rax)
jne 0x85852
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
leaq 0x6cc92(%rip), %rsi # 0xf24df
callq 0x86440
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
my_strerror:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_1C], edx
mov [rbp+var_28], 0
mov rax, [rbp+var_10]
mov byte ptr [rax], 0
cmp [rbp+var_1C], 0
jg short loc_857BE
mov rdi, [rbp+var_10]
mov ecx, [rbp+var_1C]
lea rsi, aInternalError0; "Internal error < 0 (Not system error)"
lea rax, aInternalErrorC; "Internal error/check (Not system error)"
cmp ecx, 0
cmovz rsi, rax
mov rdx, [rbp+var_18]
sub rdx, 1
call strmake
mov rax, [rbp+var_10]
mov [rbp+var_8], rax
jmp loc_8585A
loc_857BE:
cmp [rbp+var_1C], 78h ; 'x'
jl short loc_857FC
cmp [rbp+var_1C], 0C6h
jg short loc_857FC
mov eax, [rbp+var_1C]
sub eax, 78h ; 'x'
movsxd rcx, eax
lea rax, handler_error_messages
mov rax, [rax+rcx*8]
mov [rbp+var_28], rax
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
mov rdx, [rbp+var_18]
sub rdx, 1
call strmake
jmp short loc_85831
loc_857FC:
mov edi, [rbp+var_1C]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
call _strerror_r
mov [rbp+var_30], rax
mov rax, [rbp+var_30]
cmp rax, [rbp+var_10]
jz short loc_8582F
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_30]
mov rdx, [rbp+var_18]
sub rdx, 1
call strmake
loc_8582F:
jmp short $+2
loc_85831:
mov rax, [rbp+var_10]
cmp byte ptr [rax], 0
jnz short loc_85852
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_18]
sub rdx, 1
lea rsi, aUnknownError; "unknown error"
call strmake
loc_85852:
mov rax, [rbp+var_10]
mov [rbp+var_8], rax
loc_8585A:
mov rax, [rbp+var_8]
add rsp, 30h
pop rbp
retn
|
_BYTE * my_strerror(_BYTE *a1, long long a2, int a3)
{
const char *v3; // rsi
long long v5; // [rsp+0h] [rbp-30h]
*a1 = 0;
if ( a3 > 0 )
{
if ( a3 < 120 || a3 > 198 )
{
v5 = strerror_r((unsigned int)a3, a1, a2);
if ( (_BYTE *)v5 != a1 )
strmake(a1, v5, a2 - 1);
}
else
{
strmake(a1, handler_error_messages[a3 - 120], a2 - 1);
}
if ( !*a1 )
strmake(a1, "unknown error", a2 - 1);
return a1;
}
else
{
v3 = "Internal error < 0 (Not system error)";
if ( !a3 )
v3 = "Internal error/check (Not system error)";
strmake(a1, v3, a2 - 1);
return a1;
}
}
|
my_strerror:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV dword ptr [RBP + -0x1c],EDX
MOV qword ptr [RBP + -0x28],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],0x0
CMP dword ptr [RBP + -0x1c],0x0
JG 0x001857be
MOV RDI,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x1c]
LEA RSI,[0x1f24b9]
LEA RAX,[0x1f2491]
CMP ECX,0x0
CMOVZ RSI,RAX
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
CALL 0x00186440
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0018585a
LAB_001857be:
CMP dword ptr [RBP + -0x1c],0x78
JL 0x001857fc
CMP dword ptr [RBP + -0x1c],0xc6
JG 0x001857fc
MOV EAX,dword ptr [RBP + -0x1c]
SUB EAX,0x78
MOVSXD RCX,EAX
LEA RAX,[0x4fd9d0]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
CALL 0x00186440
JMP 0x00185831
LAB_001857fc:
MOV EDI,dword ptr [RBP + -0x1c]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
CALL 0x001290d0
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x30]
CMP RAX,qword ptr [RBP + -0x10]
JZ 0x0018582f
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x30]
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
CALL 0x00186440
LAB_0018582f:
JMP 0x00185831
LAB_00185831:
MOV RAX,qword ptr [RBP + -0x10]
CMP byte ptr [RAX],0x0
JNZ 0x00185852
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
LEA RSI,[0x1f24df]
CALL 0x00186440
LAB_00185852:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x8],RAX
LAB_0018585a:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x30
POP RBP
RET
|
char * my_strerror(char *param_1,size_t param_2,int param_3)
{
char *pcVar1;
*param_1 = '\0';
if (param_3 < 1) {
pcVar1 = "Internal error < 0 (Not system error)";
if (param_3 == 0) {
pcVar1 = "Internal error/check (Not system error)";
}
strmake(param_1,pcVar1,param_2 - 1);
}
else {
if ((param_3 < 0x78) || (0xc6 < param_3)) {
pcVar1 = strerror_r(param_3,param_1,param_2);
if (pcVar1 != param_1) {
strmake(param_1,pcVar1,param_2 - 1);
}
}
else {
strmake(param_1,*(int8 *)(handler_error_messages + (long)(param_3 + -0x78) * 8),
param_2 - 1);
}
if (*param_1 == '\0') {
strmake(param_1,"unknown error",param_2 - 1);
}
}
return param_1;
}
|
|
64,860 |
mi_memmap_file
|
eloqsql/storage/myisam/mi_packrec.c
|
my_bool _mi_memmap_file(MI_INFO *info)
{
MYISAM_SHARE *share=info->s;
my_bool eom;
DBUG_ENTER("mi_memmap_file");
if (!info->s->file_map)
{
my_off_t data_file_length= share->state.state.data_file_length;
if (myisam_mmap_size != SIZE_T_MAX)
{
mysql_mutex_lock(&THR_LOCK_myisam_mmap);
eom= data_file_length > myisam_mmap_size - myisam_mmap_used - MEMMAP_EXTRA_MARGIN;
if (!eom)
myisam_mmap_used+= data_file_length + MEMMAP_EXTRA_MARGIN;
mysql_mutex_unlock(&THR_LOCK_myisam_mmap);
}
else
eom= data_file_length > myisam_mmap_size - MEMMAP_EXTRA_MARGIN;
if (eom)
{
DBUG_PRINT("warning", ("File is too large for mmap"));
DBUG_RETURN(0);
}
if (mysql_file_seek(info->dfile, 0L, MY_SEEK_END, MYF(0)) <
share->state.state.data_file_length+MEMMAP_EXTRA_MARGIN)
{
DBUG_PRINT("warning",("File isn't extended for memmap"));
if (myisam_mmap_size != SIZE_T_MAX)
{
mysql_mutex_lock(&THR_LOCK_myisam_mmap);
myisam_mmap_used-= data_file_length + MEMMAP_EXTRA_MARGIN;
mysql_mutex_unlock(&THR_LOCK_myisam_mmap);
}
DBUG_RETURN(0);
}
if (mi_dynmap_file(info,
share->state.state.data_file_length +
MEMMAP_EXTRA_MARGIN))
{
if (myisam_mmap_size != SIZE_T_MAX)
{
mysql_mutex_lock(&THR_LOCK_myisam_mmap);
myisam_mmap_used-= data_file_length + MEMMAP_EXTRA_MARGIN;
mysql_mutex_unlock(&THR_LOCK_myisam_mmap);
}
DBUG_RETURN(0);
}
}
info->opt_flag|= MEMMAP_USED;
info->read_record= share->read_record= _mi_read_mempack_record;
share->read_rnd= _mi_read_rnd_mempack_record;
DBUG_RETURN(1);
}
|
O3
|
c
|
mi_memmap_file:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdi, %rbx
movq (%rdi), %r13
cmpq $0x0, 0x270(%r13)
je 0x81ad2
orb $0x20, 0x1c8(%rbx)
leaq 0x1cd(%rip), %rax # 0x81c7c
movq %rax, 0x298(%r13)
movq %rax, 0x140(%rbx)
leaq 0x259(%rip), %rax # 0x81d1d
movq %rax, 0x2b8(%r13)
movb $0x1, %al
jmp 0x81c1c
movq 0x40(%r13), %r12
leaq 0x30387b(%rip), %r14 # 0x385358
cmpq $-0x1, (%r14)
je 0x81b47
leaq 0xb86d1e(%rip), %r15 # 0xc08808
cmpq $0x0, 0x40(%r15)
jne 0x81c2b
leaq 0xb86d0c(%rip), %rdi # 0xc08808
callq 0x29220
movq (%r14), %r14
leaq 0xb7de55(%rip), %rax # 0xbff960
movq (%rax), %rcx
subq %rcx, %r14
addq $-0x7, %r14
cmpq %r14, %r12
ja 0x81b24
addq %r12, %rcx
addq $0x7, %rcx
movq %rcx, (%rax)
movq 0x40(%r15), %rdi
testq %rdi, %rdi
jne 0x81c35
leaq 0xb86cd0(%rip), %rdi # 0xc08808
callq 0x291e0
cmpq %r14, %r12
jbe 0x81b51
jmp 0x81c1a
cmpq $-0x8, %r12
ja 0x81c1a
movl 0x1c0(%rbx), %r14d
leaq 0x3044b1(%rip), %r15 # 0x386010
movq (%r15), %rax
leaq -0x78(%rbp), %rdi
movl %r14d, %esi
movl $0x8, %edx
callq *0x158(%rax)
testq %rax, %rax
jne 0x81c4a
movl %r14d, %edi
xorl %esi, %esi
movl $0x2, %edx
xorl %ecx, %ecx
callq 0xa06f0
movq 0x40(%r13), %rsi
addq $0x7, %rsi
cmpq %rsi, %rax
leaq 0x3037b8(%rip), %r14 # 0x385358
jae 0x81bbd
cmpq $-0x1, (%r14)
je 0x81c1a
leaq 0xb86c59(%rip), %rbx # 0xc08808
cmpq $0x0, 0x40(%rbx)
je 0x81be5
callq 0x2e56b
jmp 0x81bf1
movq %rbx, %rdi
callq 0x7656c
testb %al, %al
je 0x81aa1
cmpq $-0x1, (%r14)
je 0x81c1a
leaq 0xb86c2e(%rip), %rbx # 0xc08808
cmpq $0x0, 0x40(%rbx)
jne 0x81c72
leaq 0xb86c1c(%rip), %rdi # 0xc08808
callq 0x29220
leaq 0xb7dd68(%rip), %rax # 0xbff960
movq (%rax), %rcx
subq %r12, %rcx
addq $-0x7, %rcx
movq %rcx, (%rax)
movq 0x40(%rbx), %rdi
testq %rdi, %rdi
jne 0x81c67
leaq 0xb86bf3(%rip), %rdi # 0xc08808
callq 0x291e0
xorl %eax, %eax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x2e4d3
jmp 0x81b01
leaq 0x3043d4(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x81b31
leaq -0x30(%rbp), %rcx
movq %rax, %rdi
movl %r14d, %esi
movq %rcx, %r14
movq %rcx, %rdx
callq 0x2e4f0
movq (%r14), %rax
jmp 0x81b8e
movq (%r15), %rax
callq *0x160(%rax)
jmp 0x81c0e
callq 0x2e54d
jmp 0x81bf1
|
_mi_memmap_file:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 58h
mov rbx, rdi
mov r13, [rdi]
cmp qword ptr [r13+270h], 0
jz short loc_81AD2
loc_81AA1:
or byte ptr [rbx+1C8h], 20h
lea rax, _mi_read_mempack_record
mov [r13+298h], rax
mov [rbx+140h], rax
lea rax, _mi_read_rnd_mempack_record
mov [r13+2B8h], rax
mov al, 1
jmp loc_81C1C
loc_81AD2:
mov r12, [r13+40h]
lea r14, myisam_mmap_size
cmp qword ptr [r14], 0FFFFFFFFFFFFFFFFh
jz short loc_81B47
lea r15, THR_LOCK_myisam_mmap
cmp qword ptr [r15+40h], 0
jnz loc_81C2B
lea rdi, THR_LOCK_myisam_mmap
call _pthread_mutex_lock
loc_81B01:
mov r14, [r14]
lea rax, myisam_mmap_used
mov rcx, [rax]
sub r14, rcx
add r14, 0FFFFFFFFFFFFFFF9h
cmp r12, r14
ja short loc_81B24
add rcx, r12
add rcx, 7
mov [rax], rcx
loc_81B24:
mov rdi, [r15+40h]
test rdi, rdi
jnz loc_81C35
loc_81B31:
lea rdi, THR_LOCK_myisam_mmap
call _pthread_mutex_unlock
cmp r12, r14
jbe short loc_81B51
jmp loc_81C1A
loc_81B47:
cmp r12, 0FFFFFFFFFFFFFFF8h
ja loc_81C1A
loc_81B51:
mov r14d, [rbx+1C0h]
lea r15, PSI_server
mov rax, [r15]
lea rdi, [rbp+var_78]
mov esi, r14d
mov edx, 8
call qword ptr [rax+158h]
test rax, rax
jnz loc_81C4A
mov edi, r14d
xor esi, esi
mov edx, 2
xor ecx, ecx
call my_seek
loc_81B8E:
mov rsi, [r13+40h]
add rsi, 7
cmp rax, rsi
lea r14, myisam_mmap_size
jnb short loc_81BBD
cmp qword ptr [r14], 0FFFFFFFFFFFFFFFFh
jz short loc_81C1A
lea rbx, THR_LOCK_myisam_mmap
cmp qword ptr [rbx+40h], 0
jz short loc_81BE5
call _mi_memmap_file_cold_4
jmp short loc_81BF1
loc_81BBD:
mov rdi, rbx
call mi_dynmap_file
test al, al
jz loc_81AA1
cmp qword ptr [r14], 0FFFFFFFFFFFFFFFFh
jz short loc_81C1A
lea rbx, THR_LOCK_myisam_mmap
cmp qword ptr [rbx+40h], 0
jnz loc_81C72
loc_81BE5:
lea rdi, THR_LOCK_myisam_mmap
call _pthread_mutex_lock
loc_81BF1:
lea rax, myisam_mmap_used
mov rcx, [rax]
sub rcx, r12
add rcx, 0FFFFFFFFFFFFFFF9h
mov [rax], rcx
mov rdi, [rbx+40h]
test rdi, rdi
jnz short loc_81C67
loc_81C0E:
lea rdi, THR_LOCK_myisam_mmap
call _pthread_mutex_unlock
loc_81C1A:
xor eax, eax
loc_81C1C:
add rsp, 58h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_81C2B:
call _mi_memmap_file_cold_1
jmp loc_81B01
loc_81C35:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp loc_81B31
loc_81C4A:
lea rcx, [rbp+var_30]
mov rdi, rax
mov esi, r14d
mov r14, rcx
mov rdx, rcx
call _mi_memmap_file_cold_2
mov rax, [r14]
jmp loc_81B8E
loc_81C67:
mov rax, [r15]
call qword ptr [rax+160h]
jmp short loc_81C0E
loc_81C72:
call _mi_memmap_file_cold_3
jmp loc_81BF1
|
char mi_memmap_file(unsigned int *a1)
{
_QWORD *v1; // r13
unsigned long long v3; // r12
unsigned long long v4; // r14
unsigned int v5; // r14d
long long v6; // rax
unsigned long long v7; // rax
unsigned long long v8; // rsi
_BYTE v9[72]; // [rsp+8h] [rbp-78h] BYREF
unsigned long long v10[6]; // [rsp+50h] [rbp-30h] BYREF
v1 = *(_QWORD **)a1;
if ( *(_QWORD *)(*(_QWORD *)a1 + 624LL) )
goto LABEL_2;
v3 = v1[8];
if ( myisam_mmap_size == -1LL )
{
if ( v3 > 0xFFFFFFFFFFFFFFF8LL )
return 0;
}
else
{
if ( THR_LOCK_myisam_mmap[8] )
mi_memmap_file_cold_1();
else
pthread_mutex_lock(THR_LOCK_myisam_mmap);
v4 = myisam_mmap_size - myisam_mmap_used - 7LL;
if ( v3 <= v4 )
myisam_mmap_used += v3 + 7;
if ( THR_LOCK_myisam_mmap[8] )
PSI_server[44]();
pthread_mutex_unlock(THR_LOCK_myisam_mmap);
if ( v3 > v4 )
return 0;
}
v5 = a1[112];
v6 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v9, v5, 8LL);
if ( v6 )
{
mi_memmap_file_cold_2(v6, v5, v10);
v7 = v10[0];
}
else
{
v7 = my_seek(v5, 0LL, 2LL, 0LL);
}
v8 = v1[8] + 7LL;
if ( v7 >= v8 )
{
if ( !(unsigned __int8)mi_dynmap_file(a1, v8) )
{
LABEL_2:
*((_BYTE *)a1 + 456) |= 0x20u;
v1[83] = mi_read_mempack_record;
*((_QWORD *)a1 + 40) = mi_read_mempack_record;
v1[87] = mi_read_rnd_mempack_record;
return 1;
}
if ( myisam_mmap_size != -1LL )
{
if ( THR_LOCK_myisam_mmap[8] )
{
mi_memmap_file_cold_3();
goto LABEL_23;
}
goto LABEL_22;
}
}
else if ( myisam_mmap_size != -1LL )
{
if ( THR_LOCK_myisam_mmap[8] )
{
mi_memmap_file_cold_4();
LABEL_23:
myisam_mmap_used = myisam_mmap_used - v3 - 7;
if ( THR_LOCK_myisam_mmap[8] )
PSI_server[44]();
pthread_mutex_unlock(THR_LOCK_myisam_mmap);
return 0;
}
LABEL_22:
pthread_mutex_lock(THR_LOCK_myisam_mmap);
goto LABEL_23;
}
return 0;
}
|
_mi_memmap_file:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x58
MOV RBX,RDI
MOV R13,qword ptr [RDI]
CMP qword ptr [R13 + 0x270],0x0
JZ 0x00181ad2
LAB_00181aa1:
OR byte ptr [RBX + 0x1c8],0x20
LEA RAX,[0x181c7c]
MOV qword ptr [R13 + 0x298],RAX
MOV qword ptr [RBX + 0x140],RAX
LEA RAX,[0x181d1d]
MOV qword ptr [R13 + 0x2b8],RAX
MOV AL,0x1
JMP 0x00181c1c
LAB_00181ad2:
MOV R12,qword ptr [R13 + 0x40]
LEA R14,[0x485358]
CMP qword ptr [R14],-0x1
JZ 0x00181b47
LEA R15,[0xd08808]
CMP qword ptr [R15 + 0x40],0x0
JNZ 0x00181c2b
LEA RDI,[0xd08808]
CALL 0x00129220
LAB_00181b01:
MOV R14,qword ptr [R14]
LEA RAX,[0xcff960]
MOV RCX,qword ptr [RAX]
SUB R14,RCX
ADD R14,-0x7
CMP R12,R14
JA 0x00181b24
ADD RCX,R12
ADD RCX,0x7
MOV qword ptr [RAX],RCX
LAB_00181b24:
MOV RDI,qword ptr [R15 + 0x40]
TEST RDI,RDI
JNZ 0x00181c35
LAB_00181b31:
LEA RDI,[0xd08808]
CALL 0x001291e0
CMP R12,R14
JBE 0x00181b51
JMP 0x00181c1a
LAB_00181b47:
CMP R12,-0x8
JA 0x00181c1a
LAB_00181b51:
MOV R14D,dword ptr [RBX + 0x1c0]
LEA R15,[0x486010]
MOV RAX,qword ptr [R15]
LEA RDI,[RBP + -0x78]
MOV ESI,R14D
MOV EDX,0x8
CALL qword ptr [RAX + 0x158]
TEST RAX,RAX
JNZ 0x00181c4a
MOV EDI,R14D
XOR ESI,ESI
MOV EDX,0x2
XOR ECX,ECX
CALL 0x001a06f0
LAB_00181b8e:
MOV RSI,qword ptr [R13 + 0x40]
ADD RSI,0x7
CMP RAX,RSI
LEA R14,[0x485358]
JNC 0x00181bbd
CMP qword ptr [R14],-0x1
JZ 0x00181c1a
LEA RBX,[0xd08808]
CMP qword ptr [RBX + 0x40],0x0
JZ 0x00181be5
CALL 0x0012e56b
JMP 0x00181bf1
LAB_00181bbd:
MOV RDI,RBX
CALL 0x0017656c
TEST AL,AL
JZ 0x00181aa1
CMP qword ptr [R14],-0x1
JZ 0x00181c1a
LEA RBX,[0xd08808]
CMP qword ptr [RBX + 0x40],0x0
JNZ 0x00181c72
LAB_00181be5:
LEA RDI,[0xd08808]
CALL 0x00129220
LAB_00181bf1:
LEA RAX,[0xcff960]
MOV RCX,qword ptr [RAX]
SUB RCX,R12
ADD RCX,-0x7
MOV qword ptr [RAX],RCX
MOV RDI,qword ptr [RBX + 0x40]
TEST RDI,RDI
JNZ 0x00181c67
LAB_00181c0e:
LEA RDI,[0xd08808]
CALL 0x001291e0
LAB_00181c1a:
XOR EAX,EAX
LAB_00181c1c:
ADD RSP,0x58
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00181c2b:
CALL 0x0012e4d3
JMP 0x00181b01
LAB_00181c35:
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x00181b31
LAB_00181c4a:
LEA RCX,[RBP + -0x30]
MOV RDI,RAX
MOV ESI,R14D
MOV R14,RCX
MOV RDX,RCX
CALL 0x0012e4f0
MOV RAX,qword ptr [R14]
JMP 0x00181b8e
LAB_00181c67:
MOV RAX,qword ptr [R15]
CALL qword ptr [RAX + 0x160]
JMP 0x00181c0e
LAB_00181c72:
CALL 0x0012e54d
JMP 0x00181bf1
|
int8 _mi_memmap_file(long *param_1)
{
int4 uVar1;
long lVar2;
ulong uVar3;
char cVar4;
long lVar5;
ulong uVar6;
int1 local_80 [72];
ulong local_38;
lVar2 = *param_1;
if (*(long *)(lVar2 + 0x270) != 0) {
LAB_00181aa1:
*(byte *)(param_1 + 0x39) = *(byte *)(param_1 + 0x39) | 0x20;
*(code **)(lVar2 + 0x298) = _mi_read_mempack_record;
param_1[0x28] = (long)_mi_read_mempack_record;
*(code **)(lVar2 + 0x2b8) = _mi_read_rnd_mempack_record;
return 0x181d01;
}
uVar3 = *(ulong *)(lVar2 + 0x40);
if (myisam_mmap_size == -1) {
if (0xfffffffffffffff8 < uVar3) {
return 0;
}
}
else {
if (THR_LOCK_myisam_mmap._64_8_ == 0) {
pthread_mutex_lock((pthread_mutex_t *)THR_LOCK_myisam_mmap);
}
else {
_mi_memmap_file_cold_1();
}
uVar6 = (myisam_mmap_size - myisam_mmap_used) - 7;
if (uVar3 <= uVar6) {
myisam_mmap_used = myisam_mmap_used + uVar3 + 7;
}
if (THR_LOCK_myisam_mmap._64_8_ != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock((pthread_mutex_t *)THR_LOCK_myisam_mmap);
if (uVar6 < uVar3) {
return 0;
}
}
uVar1 = (int4)param_1[0x38];
lVar5 = (**(code **)(PSI_server + 0x158))(local_80,uVar1,8);
if (lVar5 == 0) {
local_38 = my_seek(uVar1,0,2,0);
}
else {
_mi_memmap_file_cold_2(lVar5,uVar1,&local_38);
}
if (local_38 < *(long *)(lVar2 + 0x40) + 7U) {
if (myisam_mmap_size == -1) {
return 0;
}
if (THR_LOCK_myisam_mmap._64_8_ != 0) {
_mi_memmap_file_cold_4();
goto LAB_00181bf1;
}
}
else {
cVar4 = mi_dynmap_file(param_1);
if (cVar4 == '\0') goto LAB_00181aa1;
if (myisam_mmap_size == -1) {
return 0;
}
if (THR_LOCK_myisam_mmap._64_8_ != 0) {
_mi_memmap_file_cold_3();
goto LAB_00181bf1;
}
}
pthread_mutex_lock((pthread_mutex_t *)THR_LOCK_myisam_mmap);
LAB_00181bf1:
myisam_mmap_used = (myisam_mmap_used - uVar3) + -7;
if (THR_LOCK_myisam_mmap._64_8_ != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock((pthread_mutex_t *)THR_LOCK_myisam_mmap);
return 0;
}
|
|
64,861 |
js_create_module_bytecode_function
|
bluesky950520[P]quickjs/quickjs.c
|
static int js_create_module_bytecode_function(JSContext *ctx, JSModuleDef *m)
{
JSFunctionBytecode *b;
int i;
JSVarRef **var_refs;
JSValue func_obj, bfunc;
JSObject *p;
bfunc = m->func_obj;
func_obj = JS_NewObjectProtoClass(ctx, ctx->function_proto,
JS_CLASS_BYTECODE_FUNCTION);
if (JS_IsException(func_obj))
return -1;
b = JS_VALUE_GET_PTR(bfunc);
p = JS_VALUE_GET_OBJ(func_obj);
p->u.func.function_bytecode = b;
b->header.ref_count++;
p->u.func.home_object = NULL;
p->u.func.var_refs = NULL;
if (b->closure_var_count) {
var_refs = js_mallocz(ctx, sizeof(var_refs[0]) * b->closure_var_count);
if (!var_refs)
goto fail;
p->u.func.var_refs = var_refs;
/* create the global variables. The other variables are
imported from other modules */
for(i = 0; i < b->closure_var_count; i++) {
JSClosureVar *cv = &b->closure_var[i];
JSVarRef *var_ref;
if (cv->is_local) {
var_ref = js_create_module_var(ctx, cv->is_lexical);
if (!var_ref)
goto fail;
module_trace(ctx, "local %d: %p\n", i, var_ref);
var_refs[i] = var_ref;
}
}
}
m->func_obj = func_obj;
JS_FreeValue(ctx, bfunc);
return 0;
fail:
JS_FreeValue(ctx, func_obj);
return -1;
}
|
O0
|
c
|
js_create_module_bytecode_function:
subq $0x78, %rsp
movq %rdi, 0x68(%rsp)
movq %rsi, 0x60(%rsp)
movq 0x60(%rsp), %rax
movq 0x68(%rax), %rcx
movq %rcx, 0x28(%rsp)
movq 0x70(%rax), %rax
movq %rax, 0x30(%rsp)
movq 0x68(%rsp), %rdi
movq 0x68(%rsp), %rax
movq 0x48(%rax), %rsi
movq 0x50(%rax), %rdx
movl $0xd, %ecx
callq 0x28be0
movq %rax, 0x10(%rsp)
movq %rdx, 0x18(%rsp)
movq 0x10(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x18(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x38(%rsp), %rdi
movq 0x40(%rsp), %rsi
callq 0x22a00
cmpl $0x0, %eax
je 0x74800
movl $0xffffffff, 0x74(%rsp) # imm = 0xFFFFFFFF
jmp 0x74965
movq 0x28(%rsp), %rax
movq %rax, 0x58(%rsp)
movq 0x38(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0x58(%rsp), %rcx
movq 0x20(%rsp), %rax
movq %rcx, 0x30(%rax)
movq 0x58(%rsp), %rax
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
movq 0x20(%rsp), %rax
movq $0x0, 0x40(%rax)
movq 0x20(%rsp), %rax
movq $0x0, 0x38(%rax)
movq 0x58(%rsp), %rax
cmpl $0x0, 0x5c(%rax)
je 0x74914
movq 0x68(%rsp), %rdi
movq 0x58(%rsp), %rax
movslq 0x5c(%rax), %rsi
shlq $0x3, %rsi
callq 0x20a70
movq %rax, 0x48(%rsp)
cmpq $0x0, 0x48(%rsp)
jne 0x74880
jmp 0x74949
movq 0x48(%rsp), %rcx
movq 0x20(%rsp), %rax
movq %rcx, 0x38(%rax)
movl $0x0, 0x54(%rsp)
movl 0x54(%rsp), %eax
movq 0x58(%rsp), %rcx
cmpl 0x5c(%rcx), %eax
jge 0x74912
movq 0x58(%rsp), %rax
movq 0x38(%rax), %rax
movslq 0x54(%rsp), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rax
movb (%rax), %al
andb $0x1, %al
cmpb $0x0, %al
je 0x74903
movq 0x68(%rsp), %rdi
movq 0x8(%rsp), %rax
movb (%rax), %al
shrb $0x3, %al
andb $0x1, %al
movzbl %al, %esi
callq 0x74690
movq %rax, (%rsp)
cmpq $0x0, (%rsp)
jne 0x748f1
jmp 0x74949
movq (%rsp), %rdx
movq 0x48(%rsp), %rax
movslq 0x54(%rsp), %rcx
movq %rdx, (%rax,%rcx,8)
jmp 0x74905
movl 0x54(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x54(%rsp)
jmp 0x74896
jmp 0x74914
movq 0x60(%rsp), %rax
movq 0x38(%rsp), %rcx
movq %rcx, 0x68(%rax)
movq 0x40(%rsp), %rcx
movq %rcx, 0x70(%rax)
movq 0x68(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rdx
callq 0x229d0
movl $0x0, 0x74(%rsp)
jmp 0x74965
movq 0x68(%rsp), %rdi
movq 0x38(%rsp), %rsi
movq 0x40(%rsp), %rdx
callq 0x229d0
movl $0xffffffff, 0x74(%rsp) # imm = 0xFFFFFFFF
movl 0x74(%rsp), %eax
addq $0x78, %rsp
retq
nop
|
js_create_module_bytecode_function:
sub rsp, 78h
mov [rsp+78h+var_10], rdi
mov [rsp+78h+var_18], rsi
mov rax, [rsp+78h+var_18]
mov rcx, [rax+68h]
mov [rsp+78h+var_50], rcx
mov rax, [rax+70h]
mov [rsp+78h+var_48], rax
mov rdi, [rsp+78h+var_10]
mov rax, [rsp+78h+var_10]
mov rsi, [rax+48h]
mov rdx, [rax+50h]
mov ecx, 0Dh
call JS_NewObjectProtoClass
mov [rsp+78h+var_68], rax
mov [rsp+78h+var_60], rdx
mov rax, [rsp+78h+var_68]
mov [rsp+78h+var_40], rax
mov rax, [rsp+78h+var_60]
mov [rsp+78h+var_38], rax
mov rdi, [rsp+78h+var_40]
mov rsi, [rsp+78h+var_38]
call JS_IsException_1
cmp eax, 0
jz short loc_74800
mov [rsp+78h+var_4], 0FFFFFFFFh
jmp loc_74965
loc_74800:
mov rax, [rsp+78h+var_50]
mov [rsp+78h+var_20], rax
mov rax, [rsp+78h+var_40]
mov [rsp+78h+var_58], rax
mov rcx, [rsp+78h+var_20]
mov rax, [rsp+78h+var_58]
mov [rax+30h], rcx
mov rax, [rsp+78h+var_20]
mov ecx, [rax]
add ecx, 1
mov [rax], ecx
mov rax, [rsp+78h+var_58]
mov qword ptr [rax+40h], 0
mov rax, [rsp+78h+var_58]
mov qword ptr [rax+38h], 0
mov rax, [rsp+78h+var_20]
cmp dword ptr [rax+5Ch], 0
jz loc_74914
mov rdi, [rsp+78h+var_10]
mov rax, [rsp+78h+var_20]
movsxd rsi, dword ptr [rax+5Ch]
shl rsi, 3
call js_mallocz
mov [rsp+78h+var_30], rax
cmp [rsp+78h+var_30], 0
jnz short loc_74880
jmp loc_74949
loc_74880:
mov rcx, [rsp+78h+var_30]
mov rax, [rsp+78h+var_58]
mov [rax+38h], rcx
mov [rsp+78h+var_24], 0
loc_74896:
mov eax, [rsp+78h+var_24]
mov rcx, [rsp+78h+var_20]
cmp eax, [rcx+5Ch]
jge short loc_74912
mov rax, [rsp+78h+var_20]
mov rax, [rax+38h]
movsxd rcx, [rsp+78h+var_24]
shl rcx, 3
add rax, rcx
mov [rsp+78h+var_70], rax
mov rax, [rsp+78h+var_70]
mov al, [rax]
and al, 1
cmp al, 0
jz short loc_74903
mov rdi, [rsp+78h+var_10]
mov rax, [rsp+78h+var_70]
mov al, [rax]
shr al, 3
and al, 1
movzx esi, al
call js_create_module_var
mov [rsp+78h+var_78], rax
cmp [rsp+78h+var_78], 0
jnz short loc_748F1
jmp short loc_74949
loc_748F1:
mov rdx, [rsp+78h+var_78]
mov rax, [rsp+78h+var_30]
movsxd rcx, [rsp+78h+var_24]
mov [rax+rcx*8], rdx
loc_74903:
jmp short $+2
loc_74905:
mov eax, [rsp+78h+var_24]
add eax, 1
mov [rsp+78h+var_24], eax
jmp short loc_74896
loc_74912:
jmp short $+2
loc_74914:
mov rax, [rsp+78h+var_18]
mov rcx, [rsp+78h+var_40]
mov [rax+68h], rcx
mov rcx, [rsp+78h+var_38]
mov [rax+70h], rcx
mov rdi, [rsp+78h+var_10]
mov rsi, [rsp+78h+var_50]
mov rdx, [rsp+78h+var_48]
call JS_FreeValue
mov [rsp+78h+var_4], 0
jmp short loc_74965
loc_74949:
mov rdi, [rsp+78h+var_10]
mov rsi, [rsp+78h+var_40]
mov rdx, [rsp+78h+var_38]
call JS_FreeValue
mov [rsp+78h+var_4], 0FFFFFFFFh
loc_74965:
mov eax, [rsp+78h+var_4]
add rsp, 78h
retn
|
long long js_create_module_bytecode_function(long long a1, long long a2)
{
long long v2; // rdx
long long module_var; // [rsp+0h] [rbp-78h]
_BYTE *v5; // [rsp+8h] [rbp-70h]
_QWORD *v6; // [rsp+10h] [rbp-68h]
long long v7; // [rsp+28h] [rbp-50h]
long long v8; // [rsp+30h] [rbp-48h]
long long v9; // [rsp+40h] [rbp-38h]
long long v10; // [rsp+48h] [rbp-30h]
int i; // [rsp+54h] [rbp-24h]
v7 = *(_QWORD *)(a2 + 104);
v8 = *(_QWORD *)(a2 + 112);
v6 = (_QWORD *)JS_NewObjectProtoClass(a1, *(_QWORD *)(a1 + 72), *(_QWORD *)(a1 + 80), 0xDu);
v9 = v2;
if ( JS_IsException_1((long long)v6, v2) )
{
return (unsigned int)-1;
}
else
{
v6[6] = v7;
++*(_DWORD *)v7;
v6[8] = 0LL;
v6[7] = 0LL;
if ( *(_DWORD *)(v7 + 92) )
{
v10 = js_mallocz(a1, 8LL * *(int *)(v7 + 92));
if ( !v10 )
{
LABEL_12:
JS_FreeValue(a1, (long long)v6, v9);
return (unsigned int)-1;
}
v6[7] = v10;
for ( i = 0; i < *(_DWORD *)(v7 + 92); ++i )
{
v5 = (_BYTE *)(8LL * i + *(_QWORD *)(v7 + 56));
if ( (*v5 & 1) != 0 )
{
module_var = js_create_module_var(a1, (*v5 & 8) != 0);
if ( !module_var )
goto LABEL_12;
*(_QWORD *)(v10 + 8LL * i) = module_var;
}
}
}
*(_QWORD *)(a2 + 104) = v6;
*(_QWORD *)(a2 + 112) = v9;
JS_FreeValue(a1, v7, v8);
return 0;
}
}
|
js_create_module_bytecode_function:
SUB RSP,0x78
MOV qword ptr [RSP + 0x68],RDI
MOV qword ptr [RSP + 0x60],RSI
MOV RAX,qword ptr [RSP + 0x60]
MOV RCX,qword ptr [RAX + 0x68]
MOV qword ptr [RSP + 0x28],RCX
MOV RAX,qword ptr [RAX + 0x70]
MOV qword ptr [RSP + 0x30],RAX
MOV RDI,qword ptr [RSP + 0x68]
MOV RAX,qword ptr [RSP + 0x68]
MOV RSI,qword ptr [RAX + 0x48]
MOV RDX,qword ptr [RAX + 0x50]
MOV ECX,0xd
CALL 0x00128be0
MOV qword ptr [RSP + 0x10],RAX
MOV qword ptr [RSP + 0x18],RDX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x38],RAX
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP + 0x40],RAX
MOV RDI,qword ptr [RSP + 0x38]
MOV RSI,qword ptr [RSP + 0x40]
CALL 0x00122a00
CMP EAX,0x0
JZ 0x00174800
MOV dword ptr [RSP + 0x74],0xffffffff
JMP 0x00174965
LAB_00174800:
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x58],RAX
MOV RAX,qword ptr [RSP + 0x38]
MOV qword ptr [RSP + 0x20],RAX
MOV RCX,qword ptr [RSP + 0x58]
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RAX + 0x30],RCX
MOV RAX,qword ptr [RSP + 0x58]
MOV ECX,dword ptr [RAX]
ADD ECX,0x1
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RAX + 0x40],0x0
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RAX + 0x38],0x0
MOV RAX,qword ptr [RSP + 0x58]
CMP dword ptr [RAX + 0x5c],0x0
JZ 0x00174914
MOV RDI,qword ptr [RSP + 0x68]
MOV RAX,qword ptr [RSP + 0x58]
MOVSXD RSI,dword ptr [RAX + 0x5c]
SHL RSI,0x3
CALL 0x00120a70
MOV qword ptr [RSP + 0x48],RAX
CMP qword ptr [RSP + 0x48],0x0
JNZ 0x00174880
JMP 0x00174949
LAB_00174880:
MOV RCX,qword ptr [RSP + 0x48]
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RAX + 0x38],RCX
MOV dword ptr [RSP + 0x54],0x0
LAB_00174896:
MOV EAX,dword ptr [RSP + 0x54]
MOV RCX,qword ptr [RSP + 0x58]
CMP EAX,dword ptr [RCX + 0x5c]
JGE 0x00174912
MOV RAX,qword ptr [RSP + 0x58]
MOV RAX,qword ptr [RAX + 0x38]
MOVSXD RCX,dword ptr [RSP + 0x54]
SHL RCX,0x3
ADD RAX,RCX
MOV qword ptr [RSP + 0x8],RAX
MOV RAX,qword ptr [RSP + 0x8]
MOV AL,byte ptr [RAX]
AND AL,0x1
CMP AL,0x0
JZ 0x00174903
MOV RDI,qword ptr [RSP + 0x68]
MOV RAX,qword ptr [RSP + 0x8]
MOV AL,byte ptr [RAX]
SHR AL,0x3
AND AL,0x1
MOVZX ESI,AL
CALL 0x00174690
MOV qword ptr [RSP],RAX
CMP qword ptr [RSP],0x0
JNZ 0x001748f1
JMP 0x00174949
LAB_001748f1:
MOV RDX,qword ptr [RSP]
MOV RAX,qword ptr [RSP + 0x48]
MOVSXD RCX,dword ptr [RSP + 0x54]
MOV qword ptr [RAX + RCX*0x8],RDX
LAB_00174903:
JMP 0x00174905
LAB_00174905:
MOV EAX,dword ptr [RSP + 0x54]
ADD EAX,0x1
MOV dword ptr [RSP + 0x54],EAX
JMP 0x00174896
LAB_00174912:
JMP 0x00174914
LAB_00174914:
MOV RAX,qword ptr [RSP + 0x60]
MOV RCX,qword ptr [RSP + 0x38]
MOV qword ptr [RAX + 0x68],RCX
MOV RCX,qword ptr [RSP + 0x40]
MOV qword ptr [RAX + 0x70],RCX
MOV RDI,qword ptr [RSP + 0x68]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,qword ptr [RSP + 0x30]
CALL 0x001229d0
MOV dword ptr [RSP + 0x74],0x0
JMP 0x00174965
LAB_00174949:
MOV RDI,qword ptr [RSP + 0x68]
MOV RSI,qword ptr [RSP + 0x38]
MOV RDX,qword ptr [RSP + 0x40]
CALL 0x001229d0
MOV dword ptr [RSP + 0x74],0xffffffff
LAB_00174965:
MOV EAX,dword ptr [RSP + 0x74]
ADD RSP,0x78
RET
|
int4 js_create_module_bytecode_function(long param_1,long param_2)
{
int *piVar1;
int8 uVar2;
int iVar3;
long lVar4;
long lVar5;
byte *pbVar6;
long lVar7;
int1 auVar8 [16];
int local_24;
int4 local_4;
piVar1 = *(int **)(param_2 + 0x68);
uVar2 = *(int8 *)(param_2 + 0x70);
auVar8 = JS_NewObjectProtoClass
(param_1,*(int8 *)(param_1 + 0x48),*(int8 *)(param_1 + 0x50),0xd);
lVar4 = auVar8._0_8_;
iVar3 = JS_IsException(lVar4,auVar8._8_8_);
if (iVar3 == 0) {
*(int **)(lVar4 + 0x30) = piVar1;
*piVar1 = *piVar1 + 1;
*(int8 *)(lVar4 + 0x40) = 0;
*(int8 *)(lVar4 + 0x38) = 0;
if (piVar1[0x17] != 0) {
lVar5 = js_mallocz(param_1,(long)piVar1[0x17] << 3);
if (lVar5 == 0) {
LAB_00174949:
JS_FreeValue(param_1,lVar4,auVar8._8_8_);
return 0xffffffff;
}
*(long *)(lVar4 + 0x38) = lVar5;
for (local_24 = 0; local_24 < piVar1[0x17]; local_24 = local_24 + 1) {
pbVar6 = (byte *)(*(long *)(piVar1 + 0xe) + (long)local_24 * 8);
if ((*pbVar6 & 1) != 0) {
lVar7 = js_create_module_var(param_1,*pbVar6 >> 3 & 1);
if (lVar7 == 0) goto LAB_00174949;
*(long *)(lVar5 + (long)local_24 * 8) = lVar7;
}
}
}
*(int1 (*) [16])(param_2 + 0x68) = auVar8;
JS_FreeValue(param_1,piVar1,uVar2);
local_4 = 0;
}
else {
local_4 = 0xffffffff;
}
return local_4;
}
|
|
64,862 |
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(char*, int, unsigned long, unsigned long, unsigned long, unsigned long)
|
monkey531[P]llama/common/json.hpp
|
inline void grisu2_round(char* buf, int len, std::uint64_t dist, std::uint64_t delta,
std::uint64_t rest, std::uint64_t ten_k)
{
JSON_ASSERT(len >= 1);
JSON_ASSERT(dist <= delta);
JSON_ASSERT(rest <= delta);
JSON_ASSERT(ten_k > 0);
// <--------------------------- delta ---->
// <---- dist --------->
// --------------[------------------+-------------------]--------------
// M- w M+
//
// ten_k
// <------>
// <---- rest ---->
// --------------[------------------+----+--------------]--------------
// w V
// = buf * 10^k
//
// ten_k represents a unit-in-the-last-place in the decimal representation
// stored in buf.
// Decrement buf by ten_k while this takes buf closer to w.
// The tests are written in this order to avoid overflow in unsigned
// integer arithmetic.
while (rest < dist
&& delta - rest >= ten_k
&& (rest + ten_k < dist || dist - rest > rest + ten_k - dist))
{
JSON_ASSERT(buf[len - 1] != '0');
buf[len - 1]--;
rest += ten_k;
}
}
|
O2
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(char*, int, unsigned long, unsigned long, unsigned long, unsigned long):
pushq %rax
testl %esi, %esi
jle 0x897a3
cmpq %rcx, %rdx
ja 0x897bf
subq %r8, %rcx
jb 0x897db
testq %r9, %r9
je 0x897f7
movl %esi, %eax
movq %r9, %rsi
subq %rdx, %rsi
movq %rdx, %r10
subq %r8, %r10
cmpq %rdx, %r8
jae 0x89780
subq %r9, %rcx
jb 0x89780
leaq (%r8,%r9), %r11
cmpq %rdx, %r11
jb 0x89765
addq %rsi, %r8
cmpq %r8, %r10
jbe 0x89780
movb -0x1(%rdi,%rax), %r8b
cmpb $0x30, %r8b
je 0x89782
decb %r8b
movb %r8b, -0x1(%rdi,%rax)
subq %r9, %r10
movq %r11, %r8
jmp 0x8974a
popq %rax
retq
leaq 0x27773(%rip), %rdi # 0xb0efc
leaq 0x21aa4(%rip), %rdx # 0xab234
leaq 0x2d0de(%rip), %rcx # 0xb6875
movl $0x444d, %esi # imm = 0x444D
xorl %eax, %eax
callq 0x23eb0
leaq 0x27752(%rip), %rdi # 0xb0efc
leaq 0x21a83(%rip), %rdx # 0xab234
leaq 0x2d08e(%rip), %rcx # 0xb6846
movl $0x4431, %esi # imm = 0x4431
jmp 0x8979c
leaq 0x27736(%rip), %rdi # 0xb0efc
leaq 0x21a67(%rip), %rdx # 0xab234
leaq 0x2d07b(%rip), %rcx # 0xb684f
movl $0x4432, %esi # imm = 0x4432
jmp 0x8979c
leaq 0x2771a(%rip), %rdi # 0xb0efc
leaq 0x21a4b(%rip), %rdx # 0xab234
leaq 0x2d06d(%rip), %rcx # 0xb685d
movl $0x4433, %esi # imm = 0x4433
jmp 0x8979c
leaq 0x276fe(%rip), %rdi # 0xb0efc
leaq 0x21a2f(%rip), %rdx # 0xab234
leaq 0x2d05f(%rip), %rcx # 0xb686b
movl $0x4434, %esi # imm = 0x4434
jmp 0x8979c
|
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl12grisu2_roundEPcimmmm:
push rax
test esi, esi
jle loc_897A3
cmp rdx, rcx
ja loc_897BF
sub rcx, r8
jb loc_897DB
test r9, r9
jz loc_897F7
mov eax, esi
mov rsi, r9
sub rsi, rdx
mov r10, rdx
sub r10, r8
loc_8974A:
cmp r8, rdx
jnb short loc_89780
sub rcx, r9
jb short loc_89780
lea r11, [r8+r9]
cmp r11, rdx
jb short loc_89765
add r8, rsi
cmp r10, r8
jbe short loc_89780
loc_89765:
mov r8b, [rdi+rax-1]
cmp r8b, 30h ; '0'
jz short loc_89782
dec r8b
mov [rdi+rax-1], r8b
sub r10, r9
mov r8, r11
jmp short loc_8974A
loc_89780:
pop rax
retn
loc_89782:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aBufLen10; "buf[len - 1] != '0'"
mov esi, 444Dh
loc_8979C:
xor eax, eax
call _ggml_abort
loc_897A3:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aLen1; "len >= 1"
mov esi, 4431h
jmp short loc_8979C
loc_897BF:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aDistDelta; "dist <= delta"
mov esi, 4432h
jmp short loc_8979C
loc_897DB:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aRestDelta; "rest <= delta"
mov esi, 4433h
jmp short loc_8979C
loc_897F7:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aTenK0; "ten_k > 0"
mov esi, 4434h
jmp short loc_8979C
|
void __spoils<rdx,rcx,r8,r9,r10,r11,xmm4,xmm5> nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *this,
char *a2,
unsigned long long a3,
unsigned long long a4,
unsigned long long a5,
unsigned long long a6)
{
bool v6; // cf
unsigned long long v7; // rcx
unsigned long long v8; // r10
unsigned long long v9; // r11
char v10; // r8
if ( (int)a2 <= 0 )
{
while ( 1 )
LABEL_14:
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17457LL,
"GGML_ASSERT(%s) failed",
"len >= 1");
}
if ( a3 > a4 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17458LL,
"GGML_ASSERT(%s) failed",
"dist <= delta");
goto LABEL_14;
}
v6 = a4 < a5;
v7 = a4 - a5;
if ( v6 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17459LL,
"GGML_ASSERT(%s) failed",
"rest <= delta");
goto LABEL_14;
}
if ( !a6 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17460LL,
"GGML_ASSERT(%s) failed",
"ten_k > 0");
goto LABEL_14;
}
v8 = a3 - a5;
while ( a5 < a3 )
{
v6 = v7 < a6;
v7 -= a6;
if ( v6 )
break;
v9 = a5 + a6;
if ( a5 + a6 >= a3 && v8 <= a6 - a3 + a5 )
break;
v10 = *((_BYTE *)this + (unsigned int)a2 - 1);
if ( v10 == 48 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17485LL,
"GGML_ASSERT(%s) failed",
"buf[len - 1] != '0'");
goto LABEL_14;
}
*((_BYTE *)this + (unsigned int)a2 - 1) = v10 - 1;
v8 -= a6;
a5 = v9;
}
}
|
grisu2_round:
PUSH RAX
TEST ESI,ESI
JLE 0x001897a3
CMP RDX,RCX
JA 0x001897bf
SUB RCX,R8
JC 0x001897db
TEST R9,R9
JZ 0x001897f7
MOV EAX,ESI
MOV RSI,R9
SUB RSI,RDX
MOV R10,RDX
SUB R10,R8
LAB_0018974a:
CMP R8,RDX
JNC 0x00189780
SUB RCX,R9
JC 0x00189780
LEA R11,[R8 + R9*0x1]
CMP R11,RDX
JC 0x00189765
ADD R8,RSI
CMP R10,R8
JBE 0x00189780
LAB_00189765:
MOV R8B,byte ptr [RDI + RAX*0x1 + -0x1]
CMP R8B,0x30
JZ 0x00189782
DEC R8B
MOV byte ptr [RDI + RAX*0x1 + -0x1],R8B
SUB R10,R9
MOV R8,R11
JMP 0x0018974a
LAB_00189780:
POP RAX
RET
LAB_00189782:
LEA RDI,[0x1b0efc]
LEA RDX,[0x1ab234]
LEA RCX,[0x1b6875]
MOV ESI,0x444d
LAB_0018979c:
XOR EAX,EAX
CALL 0x00123eb0
LAB_001897a3:
LEA RDI,[0x1b0efc]
LEA RDX,[0x1ab234]
LEA RCX,[0x1b6846]
MOV ESI,0x4431
JMP 0x0018979c
LAB_001897bf:
LEA RDI,[0x1b0efc]
LEA RDX,[0x1ab234]
LEA RCX,[0x1b684f]
MOV ESI,0x4432
JMP 0x0018979c
LAB_001897db:
LEA RDI,[0x1b0efc]
LEA RDX,[0x1ab234]
LEA RCX,[0x1b685d]
MOV ESI,0x4433
JMP 0x0018979c
LAB_001897f7:
LEA RDI,[0x1b0efc]
LEA RDX,[0x1ab234]
LEA RCX,[0x1b686b]
MOV ESI,0x4434
JMP 0x0018979c
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(char*, int, unsigned long, unsigned
long, unsigned long, unsigned long) */
int8
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round
(char *param_1,int param_2,ulong param_3,ulong param_4,ulong param_5,ulong param_6)
{
int8 in_RAX;
ulong uVar1;
char *pcVar2;
int8 uVar3;
ulong uVar4;
bool bVar5;
if (param_2 < 1) {
pcVar2 = "len >= 1";
uVar3 = 0x4431;
}
else if (param_4 < param_3) {
pcVar2 = "dist <= delta";
uVar3 = 0x4432;
}
else {
uVar1 = param_4 - param_5;
if (param_4 < param_5) {
pcVar2 = "rest <= delta";
uVar3 = 0x4433;
}
else if (param_6 == 0) {
pcVar2 = "ten_k > 0";
uVar3 = 0x4434;
}
else {
uVar4 = param_3 - param_5;
while( true ) {
if (((param_3 <= param_5) || (bVar5 = uVar1 < param_6, uVar1 = uVar1 - param_6, bVar5)) ||
((param_3 <= param_5 + param_6 && (uVar4 <= param_5 + (param_6 - param_3))))) {
return in_RAX;
}
if (param_1[(ulong)(uint)param_2 - 1] == '0') break;
param_1[(ulong)(uint)param_2 - 1] = param_1[(ulong)(uint)param_2 - 1] + -1;
uVar4 = uVar4 - param_6;
param_5 = param_5 + param_6;
}
pcVar2 = "buf[len - 1] != \'0\'";
uVar3 = 0x444d;
}
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
|
|
64,863 |
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
|
monkey531[P]llama/common/json.hpp
|
inline void grisu2(char* buf, int& len, int& decimal_exponent,
diyfp m_minus, diyfp v, diyfp m_plus)
{
JSON_ASSERT(m_plus.e == m_minus.e);
JSON_ASSERT(m_plus.e == v.e);
// --------(-----------------------+-----------------------)-------- (A)
// m- v m+
//
// --------------------(-----------+-----------------------)-------- (B)
// m- v m+
//
// First scale v (and m- and m+) such that the exponent is in the range
// [alpha, gamma].
const cached_power cached = get_cached_power_for_binary_exponent(m_plus.e);
const diyfp c_minus_k(cached.f, cached.e); // = c ~= 10^-k
// The exponent of the products is = v.e + c_minus_k.e + q and is in the range [alpha,gamma]
const diyfp w = diyfp::mul(v, c_minus_k);
const diyfp w_minus = diyfp::mul(m_minus, c_minus_k);
const diyfp w_plus = diyfp::mul(m_plus, c_minus_k);
// ----(---+---)---------------(---+---)---------------(---+---)----
// w- w w+
// = c*m- = c*v = c*m+
//
// diyfp::mul rounds its result and c_minus_k is approximated too. w, w- and
// w+ are now off by a small amount.
// In fact:
//
// w - v * 10^k < 1 ulp
//
// To account for this inaccuracy, add resp. subtract 1 ulp.
//
// --------+---[---------------(---+---)---------------]---+--------
// w- M- w M+ w+
//
// Now any number in [M-, M+] (bounds included) will round to w when input,
// regardless of how the input rounding algorithm breaks ties.
//
// And digit_gen generates the shortest possible such number in [M-, M+].
// Note that this does not mean that Grisu2 always generates the shortest
// possible number in the interval (m-, m+).
const diyfp M_minus(w_minus.f + 1, w_minus.e);
const diyfp M_plus (w_plus.f - 1, w_plus.e );
decimal_exponent = -cached.k; // = -(-k) = k
grisu2_digit_gen(buf, len, decimal_exponent, M_minus, w, M_plus);
}
|
O0
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp):
subq $0x138, %rsp # imm = 0x138
leaq 0x150(%rsp), %rax
movq %rax, 0x30(%rsp)
leaq 0x140(%rsp), %r9
movq %r9, 0x38(%rsp)
movq %rcx, 0x128(%rsp)
movl %r8d, 0x130(%rsp)
movq %rdi, 0x120(%rsp)
movq %rsi, 0x118(%rsp)
movq %rdx, 0x110(%rsp)
movl 0x8(%rax), %eax
cmpl 0x130(%rsp), %eax
je 0x1918e6
leaq 0x7cdd2(%rip), %rdi # 0x20e69e
movl $0x454b, %esi # imm = 0x454B
leaq 0x7ce10(%rip), %rdx # 0x20e6e8
leaq 0x82a7d(%rip), %rcx # 0x21435c
movb $0x0, %al
callq 0x59e90
movq 0x38(%rsp), %rcx
movq 0x30(%rsp), %rax
movl 0x8(%rax), %eax
cmpl 0x8(%rcx), %eax
je 0x191919
leaq 0x7cd9f(%rip), %rdi # 0x20e69e
movl $0x454c, %esi # imm = 0x454C
leaq 0x7cddd(%rip), %rdx # 0x20e6e8
leaq 0x82a60(%rip), %rcx # 0x214372
movb $0x0, %al
callq 0x59e90
movq 0x30(%rsp), %rax
movl 0x8(%rax), %edi
callq 0x191c90
movq %rax, 0x100(%rsp)
movq %rdx, 0x108(%rsp)
movq 0x100(%rsp), %rsi
movl 0x108(%rsp), %edx
leaq 0xf0(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0x191b20
movq 0x38(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x191e60
movq 0x28(%rsp), %rsi
movl %edx, 0xd8(%rsp)
movq %rax, 0xd0(%rsp)
movl 0xd8(%rsp), %eax
movl %eax, 0xe8(%rsp)
movq 0xd0(%rsp), %rax
movq %rax, 0xe0(%rsp)
leaq 0x128(%rsp), %rdi
callq 0x191e60
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl %edx, 0xb8(%rsp)
movq %rax, 0xb0(%rsp)
movl 0xb8(%rsp), %eax
movl %eax, 0xc8(%rsp)
movq 0xb0(%rsp), %rax
movq %rax, 0xc0(%rsp)
callq 0x191e60
movl %edx, 0x98(%rsp)
movq %rax, 0x90(%rsp)
movq 0x90(%rsp), %rax
movq %rax, 0xa0(%rsp)
movl 0x98(%rsp), %eax
movl %eax, 0xa8(%rsp)
movq 0xc0(%rsp), %rsi
addq $0x1, %rsi
movl 0xc8(%rsp), %edx
leaq 0x80(%rsp), %rdi
callq 0x191b20
movq 0xa0(%rsp), %rsi
subq $0x1, %rsi
movl 0xa8(%rsp), %edx
leaq 0x70(%rsp), %rdi
callq 0x191b20
xorl %ecx, %ecx
subl 0x10c(%rsp), %ecx
movq 0x110(%rsp), %rax
movl %ecx, (%rax)
movq 0x120(%rsp), %rdi
movq 0x118(%rsp), %rsi
movq 0x110(%rsp), %rdx
movq 0x80(%rsp), %rax
movq %rax, 0x60(%rsp)
movq 0x88(%rsp), %rax
movq %rax, 0x68(%rsp)
movq 0xe0(%rsp), %rax
movq %rax, 0x50(%rsp)
movq 0xe8(%rsp), %rax
movq %rax, 0x58(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x78(%rsp), %rax
movq %rax, 0x48(%rsp)
movq 0x60(%rsp), %rcx
movl 0x68(%rsp), %r8d
leaq 0x50(%rsp), %r9
leaq 0x40(%rsp), %rax
movq (%r9), %r10
movq %r10, (%rsp)
movq 0x8(%r9), %r9
movq %r9, 0x8(%rsp)
movq (%rax), %r9
movq %r9, 0x10(%rsp)
movq 0x8(%rax), %rax
movq %rax, 0x18(%rsp)
callq 0x191fc0
addq $0x138, %rsp # imm = 0x138
retq
|
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl6grisu2EPcRiS4_NS2_5diyfpES5_S5_:
sub rsp, 138h
lea rax, [rsp+138h+arg_10]
mov [rsp+138h+var_108], rax
lea r9, [rsp+138h+arg_0]
mov [rsp+138h+var_100], r9
mov [rsp+138h+var_10], rcx
mov [rsp+138h+var_8], r8d
mov [rsp+138h+var_18], rdi
mov [rsp+138h+var_20], rsi
mov [rsp+138h+var_28], rdx
mov eax, [rax+8]
cmp eax, [rsp+138h+var_8]
jz short loc_1918E6
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
mov esi, 454Bh
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEMMinusE; "m_plus.e == m_minus.e"
mov al, 0
call _ggml_abort
loc_1918E6:
mov rcx, [rsp+138h+var_100]
mov rax, [rsp+138h+var_108]
mov eax, [rax+8]
cmp eax, [rcx+8]
jz short loc_191919
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
mov esi, 454Ch; int
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEVE; "m_plus.e == v.e"
mov al, 0
call _ggml_abort
loc_191919:
mov rax, [rsp+138h+var_108]
mov edi, [rax+8]; this
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl36get_cached_power_for_binary_exponentEi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)
mov [rsp+138h+var_38], rax
mov qword ptr [rsp+138h+var_30], rdx
mov rsi, [rsp+138h+var_38]; unsigned __int64
mov edx, [rsp+138h+var_30]; int
lea rdi, [rsp+138h+var_48]; this
mov [rsp+138h+var_110], rdi
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfpC2Emi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::diyfp(ulong,int)
mov rdi, [rsp+138h+var_100]; this
mov rsi, [rsp+138h+var_110]; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov rsi, [rsp+138h+var_110]; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *
mov [rsp+138h+var_60], edx
mov [rsp+138h+var_68], rax
mov eax, [rsp+138h+var_60]
mov dword ptr [rsp+138h+var_50], eax
mov rax, [rsp+138h+var_68]
mov [rsp+138h+var_58], rax
lea rdi, [rsp+138h+var_10]; this
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov rdi, [rsp+138h+var_108]; this
mov rsi, [rsp+138h+var_110]; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *
mov [rsp+138h+var_80], edx
mov [rsp+138h+var_88], rax
mov eax, [rsp+138h+var_80]
mov [rsp+138h+var_70], eax
mov rax, [rsp+138h+var_88]
mov [rsp+138h+var_78], rax
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov [rsp+138h+var_A0], edx
mov [rsp+138h+var_A8], rax
mov rax, [rsp+138h+var_A8]
mov [rsp+138h+var_98], rax
mov eax, [rsp+138h+var_A0]
mov [rsp+138h+var_90], eax
mov rsi, [rsp+138h+var_78]
add rsi, 1; unsigned __int64
mov edx, [rsp+138h+var_70]; int
lea rdi, [rsp+138h+var_B8]; this
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfpC2Emi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::diyfp(ulong,int)
mov rsi, [rsp+138h+var_98]
sub rsi, 1; unsigned __int64
mov edx, [rsp+138h+var_90]; int
lea rdi, [rsp+138h+var_C8]; this
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfpC2Emi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::diyfp(ulong,int)
xor ecx, ecx
sub ecx, [rsp+138h+var_30+4]
mov rax, [rsp+138h+var_28]
mov [rax], ecx
mov rdi, [rsp+138h+var_18]
mov rsi, [rsp+138h+var_20]
mov rdx, [rsp+138h+var_28]
mov rax, [rsp+138h+var_B8]
mov [rsp+138h+var_D8], rax
mov rax, [rsp+138h+var_B0]
mov [rsp+138h+var_D0], rax
mov rax, [rsp+138h+var_58]
mov [rsp+138h+var_E8], rax
mov rax, [rsp+138h+var_50]
mov [rsp+138h+var_E0], rax
mov rax, [rsp+138h+var_C8]
mov [rsp+138h+var_F8], rax
mov rax, [rsp+138h+var_C0]
mov [rsp+138h+var_F0], rax
mov rcx, [rsp+138h+var_D8]
mov r8d, dword ptr [rsp+138h+var_D0]
lea r9, [rsp+138h+var_E8]
lea rax, [rsp+138h+var_F8]
mov r10, [r9]
mov [rsp+138h+var_138], r10
mov r9, [r9+8]
mov [rsp+138h+var_130], r9
mov r9, [rax]
mov [rsp+138h+var_128], r9
mov rax, [rax+8]
mov [rsp+138h+var_120], rax
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl16grisu2_digit_genEPcRiS4_NS2_5diyfpES5_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(char *,int &,int &,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
add rsp, 138h
retn
|
long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(
long long a1,
long long a2,
_DWORD *a3,
long long a4,
int a5,
long long a6,
char a7,
int a8,
char a9,
unsigned int a10)
{
long long v10; // rdx
const nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *v11; // rdx
long long v12; // rax
const nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *v13; // rdx
long long v14; // rax
const nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *v15; // rdx
long long v16; // rax
int v17; // edx
_QWORD v19[2]; // [rsp+70h] [rbp-C8h] BYREF
long long v20; // [rsp+80h] [rbp-B8h] BYREF
long long v21; // [rsp+88h] [rbp-B0h]
long long v22; // [rsp+90h] [rbp-A8h]
int v23; // [rsp+98h] [rbp-A0h]
long long v24; // [rsp+A0h] [rbp-98h]
int v25; // [rsp+A8h] [rbp-90h]
long long v26; // [rsp+B0h] [rbp-88h]
int v27; // [rsp+B8h] [rbp-80h]
long long v28; // [rsp+C0h] [rbp-78h]
int v29; // [rsp+C8h] [rbp-70h]
long long v30; // [rsp+D0h] [rbp-68h]
int v31; // [rsp+D8h] [rbp-60h]
long long v32; // [rsp+E0h] [rbp-58h]
long long v33; // [rsp+E8h] [rbp-50h]
_BYTE v34[16]; // [rsp+F0h] [rbp-48h] BYREF
unsigned long long cached_power_for_binary_exponent; // [rsp+100h] [rbp-38h]
int v36[2]; // [rsp+108h] [rbp-30h]
_DWORD *v37; // [rsp+110h] [rbp-28h]
long long v38; // [rsp+118h] [rbp-20h]
long long v39; // [rsp+120h] [rbp-18h]
long long v40; // [rsp+128h] [rbp-10h] BYREF
int v41; // [rsp+130h] [rbp-8h]
v40 = a4;
v41 = a5;
v39 = a1;
v38 = a2;
v37 = a3;
if ( a10 != a5 )
{
LODWORD(a2) = 17739;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17739LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == m_minus.e");
}
if ( a10 != a8 )
{
LODWORD(a2) = 17740;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17740LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == v.e");
}
cached_power_for_binary_exponent = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)a10,
a2);
*(_QWORD *)v36 = v10;
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::diyfp(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)v34,
cached_power_for_binary_exponent,
v10);
v12 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)&a7,
(const nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)v34,
v11);
v31 = (int)v13;
v30 = v12;
LODWORD(v33) = (_DWORD)v13;
v32 = v12;
v14 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)&v40,
(const nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)v34,
v13);
v27 = (int)v15;
v26 = v14;
v29 = (int)v15;
v28 = v14;
v16 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)&a9,
(const nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)v34,
v15);
v23 = v17;
v22 = v16;
v24 = v16;
v25 = v17;
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::diyfp(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)&v20,
v28 + 1,
v29);
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::diyfp(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp *)v19,
v24 - 1,
v25);
*v37 = -v36[1];
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(
v39,
v38,
v37,
v20,
(unsigned int)v21,
v19[0],
v32,
v33,
v19[0],
v19[1]);
}
| |||
64,864 |
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
|
monkey531[P]llama/common/json.hpp
|
inline void grisu2(char* buf, int& len, int& decimal_exponent,
diyfp m_minus, diyfp v, diyfp m_plus)
{
JSON_ASSERT(m_plus.e == m_minus.e);
JSON_ASSERT(m_plus.e == v.e);
// --------(-----------------------+-----------------------)-------- (A)
// m- v m+
//
// --------------------(-----------+-----------------------)-------- (B)
// m- v m+
//
// First scale v (and m- and m+) such that the exponent is in the range
// [alpha, gamma].
const cached_power cached = get_cached_power_for_binary_exponent(m_plus.e);
const diyfp c_minus_k(cached.f, cached.e); // = c ~= 10^-k
// The exponent of the products is = v.e + c_minus_k.e + q and is in the range [alpha,gamma]
const diyfp w = diyfp::mul(v, c_minus_k);
const diyfp w_minus = diyfp::mul(m_minus, c_minus_k);
const diyfp w_plus = diyfp::mul(m_plus, c_minus_k);
// ----(---+---)---------------(---+---)---------------(---+---)----
// w- w w+
// = c*m- = c*v = c*m+
//
// diyfp::mul rounds its result and c_minus_k is approximated too. w, w- and
// w+ are now off by a small amount.
// In fact:
//
// w - v * 10^k < 1 ulp
//
// To account for this inaccuracy, add resp. subtract 1 ulp.
//
// --------+---[---------------(---+---)---------------]---+--------
// w- M- w M+ w+
//
// Now any number in [M-, M+] (bounds included) will round to w when input,
// regardless of how the input rounding algorithm breaks ties.
//
// And digit_gen generates the shortest possible such number in [M-, M+].
// Note that this does not mean that Grisu2 always generates the shortest
// possible number in the interval (m-, m+).
const diyfp M_minus(w_minus.f + 1, w_minus.e);
const diyfp M_plus (w_plus.f - 1, w_plus.e );
decimal_exponent = -cached.k; // = -(-k) = k
grisu2_digit_gen(buf, len, decimal_exponent, M_minus, w, M_plus);
}
|
O2
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rcx, 0x58(%rsp)
movl %r8d, 0x60(%rsp)
cmpl %r8d, 0xc8(%rsp)
jne 0x887e6
movq %rdi, 0x20(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
leaq 0xb0(%rsp), %r13
cmpl %r8d, 0x8(%r13)
jne 0x88802
movl %r8d, %edi
callq 0x888bb
movq %rdx, %r12
leaq 0x68(%rsp), %r14
movq %rax, (%r14)
movl %r12d, 0x8(%r14)
movq %r13, %rdi
movq %r14, %rsi
callq 0x889f0
movq %rax, %r15
movl %edx, %ebx
leaq 0x58(%rsp), %rdi
movq %r14, %rsi
callq 0x889f0
movq %rax, %r13
movl %edx, %ebp
leaq 0xc0(%rsp), %rdi
movq %r14, %rsi
callq 0x889f0
incq %r13
decq %rax
shrq $0x20, %r12
negl %r12d
movq 0x30(%rsp), %rcx
movl %r12d, (%rcx)
movq %r15, 0x48(%rsp)
movl %ebx, 0x50(%rsp)
movq %rax, 0x38(%rsp)
movl %edx, 0x40(%rsp)
movups 0x38(%rsp), %xmm0
movups %xmm0, 0x10(%rsp)
movups 0x48(%rsp), %xmm0
movups %xmm0, (%rsp)
movq 0x20(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq %rcx, %rdx
movq %r13, %rcx
movl %ebp, %r8d
callq 0x88a4c
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x27915(%rip), %rdi # 0xb0102
leaq 0x27958(%rip), %rdx # 0xb014c
leaq 0x2d13a(%rip), %rcx # 0xb5935
movl $0x454b, %esi # imm = 0x454B
jmp 0x8881c
leaq 0x278f9(%rip), %rdi # 0xb0102
leaq 0x2793c(%rip), %rdx # 0xb014c
leaq 0x2d134(%rip), %rcx # 0xb594b
movl $0x454c, %esi # imm = 0x454C
xorl %eax, %eax
callq 0x23e50
nop
|
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl6grisu2EPcRiS4_NS2_5diyfpES5_S5_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 78h
mov [rsp+0A8h+var_50], rcx
mov [rsp+0A8h+var_48], r8d
cmp [rsp+0A8h+arg_18], r8d
jnz loc_887E6
mov [rsp+0A8h+var_88], rdi
mov [rsp+0A8h+var_80], rsi
mov [rsp+0A8h+var_78], rdx
lea r13, [rsp+0A8h+arg_0]
cmp [r13+8], r8d
jnz loc_88802
mov edi, r8d; this
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl36get_cached_power_for_binary_exponentEi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)
mov r12, rdx
lea r14, [rsp+0A8h+var_40]
mov [r14], rax
mov [r14+8], r12d
mov rdi, r13
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r15, rax
mov ebx, edx
lea rdi, [rsp+0A8h+var_50]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r13, rax
mov ebp, edx
lea rdi, [rsp+0A8h+arg_10]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
inc r13
dec rax
shr r12, 20h
neg r12d
mov rcx, [rsp+0A8h+var_78]
mov [rcx], r12d
mov qword ptr [rsp+0A8h+var_60], r15
mov dword ptr [rsp+0A8h+var_60+8], ebx
mov qword ptr [rsp+0A8h+var_70], rax
mov dword ptr [rsp+0A8h+var_70+8], edx
movups xmm0, [rsp+0A8h+var_70]
movups [rsp+0A8h+var_98], xmm0
movups xmm0, [rsp+0A8h+var_60]
movups [rsp+0A8h+var_A8], xmm0
mov rdi, [rsp+0A8h+var_88]
mov rsi, [rsp+0A8h+var_80]
mov rdx, rcx
mov rcx, r13
mov r8d, ebp
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl16grisu2_digit_genEPcRiS4_NS2_5diyfpES5_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(char *,int &,int &,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
add rsp, 78h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_887E6:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEMMinusE; "m_plus.e == m_minus.e"
mov esi, 454Bh
jmp short loc_8881C
loc_88802:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEVE; "m_plus.e == v.e"
mov esi, 454Ch
loc_8881C:
xor eax, eax
call _ggml_abort
nop
|
long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(
int a1,
int a2,
_DWORD *a3,
long long a4,
unsigned int a5,
long long a6,
char a7,
int a8,
char a9,
int a10)
{
long long cached_power_for_binary_exponent; // rax
int v11; // rdx^4
int v12; // r12^4
int v13; // edx
char v14; // r15
int v15; // edx
int v16; // ebx
int v17; // r13d
int v18; // edx
int v19; // ebp
char v20; // al
int v21; // edx
int v22; // r9d
long long v25; // [rsp+58h] [rbp-50h] BYREF
unsigned int v26; // [rsp+60h] [rbp-48h]
long long v27; // [rsp+68h] [rbp-40h] BYREF
int v28; // [rsp+70h] [rbp-38h]
v25 = a4;
v26 = a5;
if ( a10 == a5 )
{
if ( a8 == a5 )
{
cached_power_for_binary_exponent = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)a5,
a2);
v12 = v11;
v27 = cached_power_for_binary_exponent;
v28 = v13;
v14 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a7, &v27);
v16 = v15;
v17 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&v25, &v27);
v19 = v18;
v20 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a9, &v27);
*a3 = -v12;
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(
a1,
a2,
(_DWORD)a3,
v17 + 1,
v19,
v22,
v14,
v16,
v20 - 1,
v21);
}
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17740LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == v.e");
}
else
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17739LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == m_minus.e");
}
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::normalize("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp");
}
|
grisu2:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x78
MOV qword ptr [RSP + 0x58],RCX
MOV dword ptr [RSP + 0x60],R8D
CMP dword ptr [RSP + 0xc8],R8D
JNZ 0x001887e6
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x30],RDX
LEA R13,[RSP + 0xb0]
CMP dword ptr [R13 + 0x8],R8D
JNZ 0x00188802
MOV EDI,R8D
CALL 0x001888bb
MOV R12,RDX
LEA R14,[RSP + 0x68]
MOV qword ptr [R14],RAX
MOV dword ptr [R14 + 0x8],R12D
MOV RDI,R13
MOV RSI,R14
CALL 0x001889f0
MOV R15,RAX
MOV EBX,EDX
LEA RDI,[RSP + 0x58]
MOV RSI,R14
CALL 0x001889f0
MOV R13,RAX
MOV EBP,EDX
LEA RDI,[RSP + 0xc0]
MOV RSI,R14
CALL 0x001889f0
INC R13
DEC RAX
SHR R12,0x20
NEG R12D
MOV RCX,qword ptr [RSP + 0x30]
MOV dword ptr [RCX],R12D
MOV qword ptr [RSP + 0x48],R15
MOV dword ptr [RSP + 0x50],EBX
MOV qword ptr [RSP + 0x38],RAX
MOV dword ptr [RSP + 0x40],EDX
MOVUPS XMM0,xmmword ptr [RSP + 0x38]
MOVUPS xmmword ptr [RSP + 0x10],XMM0
MOVUPS XMM0,xmmword ptr [RSP + 0x48]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,RCX
MOV RCX,R13
MOV R8D,EBP
CALL 0x00188a4c
ADD RSP,0x78
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001887e6:
LEA RDI,[0x1b0102]
LEA RDX,[0x1b014c]
LEA RCX,[0x1b5935]
MOV ESI,0x454b
JMP 0x0018881c
LAB_00188802:
LEA RDI,[0x1b0102]
LEA RDX,[0x1b014c]
LEA RCX,[0x1b594b]
MOV ESI,0x454c
LAB_0018881c:
XOR EAX,EAX
CALL 0x00123e50
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp) */
void nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2
(int8 param_1,int8 param_2,int *param_3,int8 param_4,int param_5,
int8 param_6,int8 param_7,int param_8,int8 param_9,int param_10)
{
int4 uVar1;
char *pcVar2;
int4 extraout_EDX;
int8 uVar3;
int1 auVar4 [16];
int1 auVar5 [12];
int1 auVar6 [12];
int4 uStack_64;
int8 local_50;
int local_48;
int8 local_40;
int4 local_38;
local_50 = param_4;
local_48 = param_5;
if (param_10 == param_5) {
if (param_8 == param_5) {
auVar4 = get_cached_power_for_binary_exponent(param_5);
local_40 = auVar4._0_8_;
local_38 = auVar4._8_4_;
uVar1 = diyfp::mul((diyfp *)¶m_7,(diyfp *)&local_40);
auVar5 = diyfp::mul((diyfp *)&local_50,(diyfp *)&local_40);
auVar6 = diyfp::mul((diyfp *)¶m_9,(diyfp *)&local_40);
*param_3 = -auVar4._12_4_;
grisu2_digit_gen(param_1,param_2,param_3,auVar5._0_8_ + 1,auVar5._8_4_,param_6,uVar1,
extraout_EDX,auVar6._0_8_ + -1,CONCAT44(uStack_64,auVar6._8_4_));
return;
}
pcVar2 = "m_plus.e == v.e";
uVar3 = 0x454c;
}
else {
pcVar2 = "m_plus.e == m_minus.e";
uVar3 = 0x454b;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
|
|
64,865 |
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
|
monkey531[P]llama/common/json.hpp
|
inline void grisu2(char* buf, int& len, int& decimal_exponent,
diyfp m_minus, diyfp v, diyfp m_plus)
{
JSON_ASSERT(m_plus.e == m_minus.e);
JSON_ASSERT(m_plus.e == v.e);
// --------(-----------------------+-----------------------)-------- (A)
// m- v m+
//
// --------------------(-----------+-----------------------)-------- (B)
// m- v m+
//
// First scale v (and m- and m+) such that the exponent is in the range
// [alpha, gamma].
const cached_power cached = get_cached_power_for_binary_exponent(m_plus.e);
const diyfp c_minus_k(cached.f, cached.e); // = c ~= 10^-k
// The exponent of the products is = v.e + c_minus_k.e + q and is in the range [alpha,gamma]
const diyfp w = diyfp::mul(v, c_minus_k);
const diyfp w_minus = diyfp::mul(m_minus, c_minus_k);
const diyfp w_plus = diyfp::mul(m_plus, c_minus_k);
// ----(---+---)---------------(---+---)---------------(---+---)----
// w- w w+
// = c*m- = c*v = c*m+
//
// diyfp::mul rounds its result and c_minus_k is approximated too. w, w- and
// w+ are now off by a small amount.
// In fact:
//
// w - v * 10^k < 1 ulp
//
// To account for this inaccuracy, add resp. subtract 1 ulp.
//
// --------+---[---------------(---+---)---------------]---+--------
// w- M- w M+ w+
//
// Now any number in [M-, M+] (bounds included) will round to w when input,
// regardless of how the input rounding algorithm breaks ties.
//
// And digit_gen generates the shortest possible such number in [M-, M+].
// Note that this does not mean that Grisu2 always generates the shortest
// possible number in the interval (m-, m+).
const diyfp M_minus(w_minus.f + 1, w_minus.e);
const diyfp M_plus (w_plus.f - 1, w_plus.e );
decimal_exponent = -cached.k; // = -(-k) = k
grisu2_digit_gen(buf, len, decimal_exponent, M_minus, w, M_plus);
}
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rcx, 0x58(%rsp)
movl %r8d, 0x60(%rsp)
cmpl %r8d, 0xc8(%rsp)
jne 0xb8a8e
movq %rdi, 0x20(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
leaq 0xb0(%rsp), %r13
cmpl %r8d, 0x8(%r13)
jne 0xb8aaa
movl %r8d, %edi
callq 0xb8b65
movq %rdx, %r12
leaq 0x68(%rsp), %r14
movq %rax, (%r14)
movl %r12d, 0x8(%r14)
movq %r13, %rdi
movq %r14, %rsi
callq 0xb8ca6
movq %rax, %r15
movl %edx, %ebx
leaq 0x58(%rsp), %rdi
movq %r14, %rsi
callq 0xb8ca6
movq %rax, %r13
movl %edx, %ebp
leaq 0xc0(%rsp), %rdi
movq %r14, %rsi
callq 0xb8ca6
incq %r13
decq %rax
shrq $0x20, %r12
negl %r12d
movq 0x30(%rsp), %rcx
movl %r12d, (%rcx)
movq %r15, 0x48(%rsp)
movl %ebx, 0x50(%rsp)
movq %rax, 0x38(%rsp)
movl %edx, 0x40(%rsp)
movups 0x38(%rsp), %xmm0
movups %xmm0, 0x10(%rsp)
movups 0x48(%rsp), %xmm0
movups %xmm0, (%rsp)
movq 0x20(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq %rcx, %rdx
movq %r13, %rcx
movl %ebp, %r8d
callq 0xb8d02
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x3366a(%rip), %rdi # 0xec0ff
leaq 0x336ad(%rip), %rdx # 0xec149
leaq 0x38e66(%rip), %rcx # 0xf1909
movl $0x454b, %esi # imm = 0x454B
jmp 0xb8ac4
leaq 0x3364e(%rip), %rdi # 0xec0ff
leaq 0x33691(%rip), %rdx # 0xec149
leaq 0x38e60(%rip), %rcx # 0xf191f
movl $0x454c, %esi # imm = 0x454C
xorl %eax, %eax
callq 0x1ae30
nop
|
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl6grisu2EPcRiS4_NS2_5diyfpES5_S5_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 78h
mov [rsp+0A8h+var_50], rcx
mov [rsp+0A8h+var_48], r8d
cmp [rsp+0A8h+arg_18], r8d
jnz loc_B8A8E
mov [rsp+0A8h+var_88], rdi
mov [rsp+0A8h+var_80], rsi
mov [rsp+0A8h+var_78], rdx
lea r13, [rsp+0A8h+arg_0]
cmp [r13+8], r8d
jnz loc_B8AAA
mov edi, r8d; this
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl36get_cached_power_for_binary_exponentEi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)
mov r12, rdx
lea r14, [rsp+0A8h+var_40]
mov [r14], rax
mov [r14+8], r12d
mov rdi, r13
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r15, rax
mov ebx, edx
lea rdi, [rsp+0A8h+var_50]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r13, rax
mov ebp, edx
lea rdi, [rsp+0A8h+arg_10]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
inc r13
dec rax
shr r12, 20h
neg r12d
mov rcx, [rsp+0A8h+var_78]
mov [rcx], r12d
mov qword ptr [rsp+0A8h+var_60], r15
mov dword ptr [rsp+0A8h+var_60+8], ebx
mov qword ptr [rsp+0A8h+var_70], rax
mov dword ptr [rsp+0A8h+var_70+8], edx
movups xmm0, xmmword ptr [rsp+0A8h+var_70]
movups xmmword ptr [rsp+0A8h+var_98], xmm0; char
movups xmm0, xmmword ptr [rsp+0A8h+var_60]
movups xmmword ptr [rsp+0A8h+var_A8], xmm0; char
mov rdi, [rsp+0A8h+var_88]; this
mov rsi, [rsp+0A8h+var_80]
mov rdx, rcx
mov rcx, r13
mov r8d, ebp
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl16grisu2_digit_genEPcRiS4_NS2_5diyfpES5_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(char *,int &,int &,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
add rsp, 78h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_B8A8E:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEMMinusE; "m_plus.e == m_minus.e"
mov esi, 454Bh
jmp short loc_B8AC4
loc_B8AAA:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEVE; "m_plus.e == v.e"
mov esi, 454Ch
loc_B8AC4:
xor eax, eax
call _ggml_abort
nop
|
long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *a1,
int a2,
_DWORD *a3,
long long a4,
unsigned int a5,
long long a6,
char a7,
int a8,
char a9,
int a10)
{
long long cached_power_for_binary_exponent; // rax
int v11; // rdx^4
int v12; // r12^4
int v13; // edx
char v14; // r15
int v15; // edx
int v16; // ebx
char v17; // al
int v18; // edx
long long v20; // rsi
long long v22; // [rsp+58h] [rbp-50h] BYREF
unsigned int v23; // [rsp+60h] [rbp-48h]
long long v24; // [rsp+68h] [rbp-40h] BYREF
int v25; // [rsp+70h] [rbp-38h]
v22 = a4;
v23 = a5;
if ( a10 == a5 )
{
if ( a8 == a5 )
{
cached_power_for_binary_exponent = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)a5,
a2);
v12 = v11;
v24 = cached_power_for_binary_exponent;
v25 = v13;
v14 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a7, &v24);
v16 = v15;
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&v22, &v24);
v17 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a9, &v24);
*a3 = -v12;
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(a1, v14, v16, v17 - 1, v18);
}
v20 = 17740LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17740LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == v.e");
}
else
{
v20 = 17739LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17739LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == m_minus.e");
}
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::normalize(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
v20);
}
|
grisu2:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x78
MOV qword ptr [RSP + 0x58],RCX
MOV dword ptr [RSP + 0x60],R8D
CMP dword ptr [RSP + 0xc8],R8D
JNZ 0x001b8a8e
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x30],RDX
LEA R13,[RSP + 0xb0]
CMP dword ptr [R13 + 0x8],R8D
JNZ 0x001b8aaa
MOV EDI,R8D
CALL 0x001b8b65
MOV R12,RDX
LEA R14,[RSP + 0x68]
MOV qword ptr [R14],RAX
MOV dword ptr [R14 + 0x8],R12D
MOV RDI,R13
MOV RSI,R14
CALL 0x001b8ca6
MOV R15,RAX
MOV EBX,EDX
LEA RDI,[RSP + 0x58]
MOV RSI,R14
CALL 0x001b8ca6
MOV R13,RAX
MOV EBP,EDX
LEA RDI,[RSP + 0xc0]
MOV RSI,R14
CALL 0x001b8ca6
INC R13
DEC RAX
SHR R12,0x20
NEG R12D
MOV RCX,qword ptr [RSP + 0x30]
MOV dword ptr [RCX],R12D
MOV qword ptr [RSP + 0x48],R15
MOV dword ptr [RSP + 0x50],EBX
MOV qword ptr [RSP + 0x38],RAX
MOV dword ptr [RSP + 0x40],EDX
MOVUPS XMM0,xmmword ptr [RSP + 0x38]
MOVUPS xmmword ptr [RSP + 0x10],XMM0
MOVUPS XMM0,xmmword ptr [RSP + 0x48]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,RCX
MOV RCX,R13
MOV R8D,EBP
CALL 0x001b8d02
ADD RSP,0x78
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001b8a8e:
LEA RDI,[0x1ec0ff]
LEA RDX,[0x1ec149]
LEA RCX,[0x1f1909]
MOV ESI,0x454b
JMP 0x001b8ac4
LAB_001b8aaa:
LEA RDI,[0x1ec0ff]
LEA RDX,[0x1ec149]
LEA RCX,[0x1f191f]
MOV ESI,0x454c
LAB_001b8ac4:
XOR EAX,EAX
CALL 0x0011ae30
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp) */
void nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2
(int8 param_1,int8 param_2,int *param_3,int8 param_4,int param_5,
int8 param_6,int8 param_7,int param_8,int8 param_9,int param_10)
{
int4 uVar1;
char *pcVar2;
int4 extraout_EDX;
int8 uVar3;
int1 auVar4 [12];
int1 auVar5 [12];
int1 auVar6 [16];
int4 uStack_64;
int8 local_50;
int local_48;
int8 local_40;
int4 local_38;
local_50 = param_4;
local_48 = param_5;
if (param_10 == param_5) {
if (param_8 == param_5) {
auVar6 = get_cached_power_for_binary_exponent(param_5);
local_40 = auVar6._0_8_;
local_38 = auVar6._8_4_;
uVar1 = diyfp::mul((diyfp *)¶m_7,(diyfp *)&local_40);
auVar4 = diyfp::mul((diyfp *)&local_50,(diyfp *)&local_40);
auVar5 = diyfp::mul((diyfp *)¶m_9,(diyfp *)&local_40);
*param_3 = -auVar6._12_4_;
grisu2_digit_gen(param_1,param_2,param_3,auVar4._0_8_ + 1,auVar4._8_4_,param_6,uVar1,
extraout_EDX,auVar5._0_8_ + -1,CONCAT44(uStack_64,auVar5._8_4_));
return;
}
pcVar2 = "m_plus.e == v.e";
uVar3 = 0x454c;
}
else {
pcVar2 = "m_plus.e == m_minus.e";
uVar3 = 0x454b;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
|
|
64,866 |
sort_key_write
|
eloqsql/storage/myisam/mi_check.c
|
static int sort_key_write(MI_SORT_PARAM *sort_param, const void *a)
{
uint diff_pos[2];
char llbuff[22],llbuff2[22];
MI_SORT_INFO *sort_info=sort_param->sort_info;
HA_CHECK *param= sort_info->param;
int cmp;
if (sort_info->key_block->inited)
{
cmp=ha_key_cmp(sort_param->seg, (uchar*) sort_info->key_block->lastkey,
(uchar*) a, USE_WHOLE_KEY,
SEARCH_FIND | SEARCH_UPDATE | SEARCH_INSERT,
diff_pos);
if (param->stats_method == MI_STATS_METHOD_NULLS_NOT_EQUAL)
ha_key_cmp(sort_param->seg, (uchar*) sort_info->key_block->lastkey,
(uchar*) a, USE_WHOLE_KEY,
SEARCH_FIND | SEARCH_NULL_ARE_NOT_EQUAL, diff_pos);
else if (param->stats_method == MI_STATS_METHOD_IGNORE_NULLS)
{
diff_pos[0]= mi_collect_stats_nonulls_next(sort_param->seg,
sort_param->notnull,
(uchar*) sort_info->
key_block->lastkey,
(uchar*)a);
}
sort_param->unique[diff_pos[0]-1]++;
}
else
{
cmp= -1;
if (param->stats_method == MI_STATS_METHOD_IGNORE_NULLS)
mi_collect_stats_nonulls_first(sort_param->seg, sort_param->notnull,
(uchar*)a);
}
if ((sort_param->keyinfo->flag & HA_NOSAME) && cmp == 0)
{
sort_info->dupp++;
sort_info->info->lastpos=get_record_for_key(sort_info->info,
sort_param->keyinfo,
(uchar*) a);
if ((param->testflag & (T_CREATE_UNIQUE_BY_SORT | T_SUPPRESS_ERR_HANDLING))
== T_CREATE_UNIQUE_BY_SORT)
param->testflag|= T_SUPPRESS_ERR_HANDLING;
mi_check_print_warning(param,
"Duplicate key for record at %10s against record at %10s",
llstr(sort_info->info->lastpos,llbuff),
llstr(get_record_for_key(sort_info->info,
sort_param->keyinfo,
(uchar*) sort_info->
key_block->lastkey),
llbuff2));
param->testflag|=T_RETRY_WITHOUT_QUICK;
if (sort_info->param->testflag & T_VERBOSE)
_mi_print_key(stdout,sort_param->seg,(uchar*) a, USE_WHOLE_KEY);
return (sort_delete_record(sort_param));
}
#ifndef DBUG_OFF
if (cmp > 0)
{
mi_check_print_error(param,
"Internal error: Keys are not in order from sort");
return(1);
}
#endif
return (sort_insert_key(sort_param,sort_info->key_block,
(uchar*) a, HA_OFFSET_ERROR));
}
|
O0
|
c
|
sort_key_write:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x50(%rbp)
movq %rsi, -0x58(%rbp)
movq -0x50(%rbp), %rax
movq 0x380(%rax), %rax
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rax
movq 0x88(%rax), %rax
movq %rax, -0x70(%rbp)
movq -0x68(%rbp), %rax
movq 0x98(%rax), %rax
cmpl $0x0, 0x420(%rax)
je 0x3b2de
movq -0x50(%rbp), %rax
movq 0x388(%rax), %rdi
movq -0x68(%rbp), %rax
movq 0x98(%rax), %rsi
addq $0x10, %rsi
movq -0x58(%rbp), %rdx
leaq -0x60(%rbp), %r9
movl $0x970, %ecx # imm = 0x970
movl $0x20041, %r8d # imm = 0x20041
callq 0x9ced0
movl %eax, -0x74(%rbp)
movq -0x70(%rbp), %rax
cmpl $0x0, 0x20cc0(%rax)
jne 0x3b27c
movq -0x50(%rbp), %rax
movq 0x388(%rax), %rdi
movq -0x68(%rbp), %rax
movq 0x98(%rax), %rsi
addq $0x10, %rsi
movq -0x58(%rbp), %rdx
leaq -0x60(%rbp), %r9
movl $0x970, %ecx # imm = 0x970
movl $0x10001, %r8d # imm = 0x10001
callq 0x9ced0
jmp 0x3b2bc
movq -0x70(%rbp), %rax
cmpl $0x2, 0x20cc0(%rax)
jne 0x3b2ba
movq -0x50(%rbp), %rax
movq 0x388(%rax), %rdi
movq -0x50(%rbp), %rsi
addq $0x508, %rsi # imm = 0x508
movq -0x68(%rbp), %rax
movq 0x98(%rax), %rdx
addq $0x10, %rdx
movq -0x58(%rbp), %rcx
callq 0x3ef60
movl %eax, -0x60(%rbp)
jmp 0x3b2bc
movq -0x50(%rbp), %rax
movl -0x60(%rbp), %ecx
subl $0x1, %ecx
movl %ecx, %ecx
movq 0x400(%rax,%rcx,8), %rdx
addq $0x1, %rdx
movq %rdx, 0x400(%rax,%rcx,8)
jmp 0x3b313
movl $0xffffffff, -0x74(%rbp) # imm = 0xFFFFFFFF
movq -0x70(%rbp), %rax
cmpl $0x2, 0x20cc0(%rax)
jne 0x3b311
movq -0x50(%rbp), %rax
movq 0x388(%rax), %rdi
movq -0x50(%rbp), %rsi
addq $0x508, %rsi # imm = 0x508
movq -0x58(%rbp), %rdx
callq 0x3f010
jmp 0x3b313
movq -0x50(%rbp), %rax
movq 0x378(%rax), %rax
movzwl 0xa(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x3b4a6
cmpl $0x0, -0x74(%rbp)
jne 0x3b4a6
movq -0x68(%rbp), %rax
movq 0xb8(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0xb8(%rax)
movq -0x68(%rbp), %rax
movq 0x80(%rax), %rdi
movq -0x50(%rbp), %rax
movq 0x378(%rax), %rsi
movq -0x58(%rbp), %rdx
callq 0x3f080
movq %rax, %rcx
movq -0x68(%rbp), %rax
movq 0x80(%rax), %rax
movq %rcx, 0x170(%rax)
movq -0x70(%rbp), %rcx
movabsq $0x3000000000, %rax # imm = 0x3000000000
andq 0xb10(%rcx), %rax
movabsq $0x1000000000, %rcx # imm = 0x1000000000
cmpq %rcx, %rax
jne 0x3b3c2
movq -0x70(%rbp), %rax
movabsq $0x2000000000, %rcx # imm = 0x2000000000
orq 0xb10(%rax), %rcx
movq %rcx, 0xb10(%rax)
movq -0x70(%rbp), %rax
movq %rax, -0x88(%rbp)
movq -0x68(%rbp), %rax
movq 0x80(%rax), %rax
movq 0x170(%rax), %rdi
leaq -0x20(%rbp), %rsi
callq 0xf2d30
movq %rax, -0x80(%rbp)
movq -0x68(%rbp), %rax
movq 0x80(%rax), %rdi
movq -0x50(%rbp), %rax
movq 0x378(%rax), %rsi
movq -0x68(%rbp), %rax
movq 0x98(%rax), %rdx
addq $0x10, %rdx
callq 0x3f080
movq %rax, %rdi
leaq -0x40(%rbp), %rsi
callq 0xf2d30
movq -0x88(%rbp), %rdi
movq -0x80(%rbp), %rdx
movq %rax, %rcx
leaq 0xc2359(%rip), %rsi # 0xfd790
movb $0x0, %al
callq 0x2c5b0
movq -0x70(%rbp), %rax
movq 0xb10(%rax), %rcx
orq $0x100000, %rcx # imm = 0x100000
movq %rcx, 0xb10(%rax)
movq -0x68(%rbp), %rax
movq 0x88(%rax), %rax
movq 0xb10(%rax), %rax
andq $0x10000000, %rax # imm = 0x10000000
cmpq $0x0, %rax
je 0x3b498
movq 0x222b3c(%rip), %rax # 0x25dfb8
movq (%rax), %rdi
movq -0x50(%rbp), %rax
movq 0x388(%rax), %rsi
movq -0x58(%rbp), %rdx
movl $0x970, %ecx # imm = 0x970
callq 0x42620
movq -0x50(%rbp), %rdi
callq 0x3f0d0
movl %eax, -0x44(%rbp)
jmp 0x3b4c8
movq -0x50(%rbp), %rdi
movq -0x68(%rbp), %rax
movq 0x98(%rax), %rsi
movq -0x58(%rbp), %rdx
movq $-0x1, %rcx
callq 0x3d320
movl %eax, -0x44(%rbp)
movl -0x44(%rbp), %eax
movl %eax, -0x8c(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x3b4f2
movl -0x8c(%rbp), %eax
addq $0x90, %rsp
popq %rbp
retq
callq 0x2a420
nopw (%rax,%rax)
|
sort_key_write:
push rbp
mov rbp, rsp
sub rsp, 90h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_50], rdi
mov [rbp+var_58], rsi
mov rax, [rbp+var_50]
mov rax, [rax+380h]
mov [rbp+var_68], rax
mov rax, [rbp+var_68]
mov rax, [rax+88h]
mov [rbp+var_70], rax
mov rax, [rbp+var_68]
mov rax, [rax+98h]
cmp dword ptr [rax+420h], 0
jz loc_3B2DE
mov rax, [rbp+var_50]
mov rdi, [rax+388h]
mov rax, [rbp+var_68]
mov rsi, [rax+98h]
add rsi, 10h
mov rdx, [rbp+var_58]
lea r9, [rbp+var_60]
mov ecx, 970h
mov r8d, 20041h
call ha_key_cmp
mov [rbp+var_74], eax
mov rax, [rbp+var_70]
cmp dword ptr [rax+20CC0h], 0
jnz short loc_3B27C
mov rax, [rbp+var_50]
mov rdi, [rax+388h]
mov rax, [rbp+var_68]
mov rsi, [rax+98h]
add rsi, 10h
mov rdx, [rbp+var_58]
lea r9, [rbp+var_60]
mov ecx, 970h
mov r8d, 10001h
call ha_key_cmp
jmp short loc_3B2BC
loc_3B27C:
mov rax, [rbp+var_70]
cmp dword ptr [rax+20CC0h], 2
jnz short loc_3B2BA
mov rax, [rbp+var_50]
mov rdi, [rax+388h]
mov rsi, [rbp+var_50]
add rsi, 508h
mov rax, [rbp+var_68]
mov rdx, [rax+98h]
add rdx, 10h
mov rcx, [rbp+var_58]
call mi_collect_stats_nonulls_next
mov [rbp+var_60], eax
loc_3B2BA:
jmp short $+2
loc_3B2BC:
mov rax, [rbp+var_50]
mov ecx, [rbp+var_60]
sub ecx, 1
mov ecx, ecx
mov rdx, [rax+rcx*8+400h]
add rdx, 1
mov [rax+rcx*8+400h], rdx
jmp short loc_3B313
loc_3B2DE:
mov [rbp+var_74], 0FFFFFFFFh
mov rax, [rbp+var_70]
cmp dword ptr [rax+20CC0h], 2
jnz short loc_3B311
mov rax, [rbp+var_50]
mov rdi, [rax+388h]
mov rsi, [rbp+var_50]
add rsi, 508h
mov rdx, [rbp+var_58]
call mi_collect_stats_nonulls_first
loc_3B311:
jmp short $+2
loc_3B313:
mov rax, [rbp+var_50]
mov rax, [rax+378h]
movzx eax, word ptr [rax+0Ah]
and eax, 1
cmp eax, 0
jz loc_3B4A6
cmp [rbp+var_74], 0
jnz loc_3B4A6
mov rax, [rbp+var_68]
mov rcx, [rax+0B8h]
add rcx, 1
mov [rax+0B8h], rcx
mov rax, [rbp+var_68]
mov rdi, [rax+80h]
mov rax, [rbp+var_50]
mov rsi, [rax+378h]
mov rdx, [rbp+var_58]
call get_record_for_key
mov rcx, rax
mov rax, [rbp+var_68]
mov rax, [rax+80h]
mov [rax+170h], rcx
mov rcx, [rbp+var_70]
mov rax, 3000000000h
and rax, [rcx+0B10h]
mov rcx, 1000000000h
cmp rax, rcx
jnz short loc_3B3C2
mov rax, [rbp+var_70]
mov rcx, 2000000000h
or rcx, [rax+0B10h]
mov [rax+0B10h], rcx
loc_3B3C2:
mov rax, [rbp+var_70]
mov [rbp+var_88], rax
mov rax, [rbp+var_68]
mov rax, [rax+80h]
mov rdi, [rax+170h]
lea rsi, [rbp+var_20]
call llstr
mov [rbp+var_80], rax
mov rax, [rbp+var_68]
mov rdi, [rax+80h]
mov rax, [rbp+var_50]
mov rsi, [rax+378h]
mov rax, [rbp+var_68]
mov rdx, [rax+98h]
add rdx, 10h
call get_record_for_key
mov rdi, rax
lea rsi, [rbp+var_40]
call llstr
mov rdi, [rbp+var_88]
mov rdx, [rbp+var_80]
mov rcx, rax
lea rsi, aDuplicateKeyFo; "Duplicate key for record at %10s agains"...
mov al, 0
call mi_check_print_warning
mov rax, [rbp+var_70]
mov rcx, [rax+0B10h]
or rcx, 100000h
mov [rax+0B10h], rcx
mov rax, [rbp+var_68]
mov rax, [rax+88h]
mov rax, [rax+0B10h]
and rax, 10000000h
cmp rax, 0
jz short loc_3B498
mov rax, cs:stdout_ptr
mov rdi, [rax]
mov rax, [rbp+var_50]
mov rsi, [rax+388h]
mov rdx, [rbp+var_58]
mov ecx, 970h
call _mi_print_key
loc_3B498:
mov rdi, [rbp+var_50]
call sort_delete_record
mov [rbp+var_44], eax
jmp short loc_3B4C8
loc_3B4A6:
mov rdi, [rbp+var_50]
mov rax, [rbp+var_68]
mov rsi, [rax+98h]
mov rdx, [rbp+var_58]
mov rcx, 0FFFFFFFFFFFFFFFFh
call sort_insert_key
mov [rbp+var_44], eax
loc_3B4C8:
mov eax, [rbp+var_44]
mov [rbp+var_8C], eax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_3B4F2
mov eax, [rbp+var_8C]
add rsp, 90h
pop rbp
retn
loc_3B4F2:
call ___stack_chk_fail
|
long long sort_key_write(
long long a1,
long long a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
double a7,
double a8,
__m128 a9,
__m128 a10)
{
long long record_for_key; // rax
long long v11; // rax
long long v12; // r8
long long v13; // r9
__m128 v14; // xmm4
__m128 v15; // xmm5
char v17; // [rsp+0h] [rbp-90h]
long long v18; // [rsp+10h] [rbp-80h]
int v19; // [rsp+1Ch] [rbp-74h]
long long v20; // [rsp+20h] [rbp-70h]
_QWORD *v21; // [rsp+28h] [rbp-68h]
int v22; // [rsp+30h] [rbp-60h] BYREF
long long v23; // [rsp+38h] [rbp-58h]
long long v24; // [rsp+40h] [rbp-50h]
_BYTE v26[32]; // [rsp+50h] [rbp-40h] BYREF
_BYTE v27[24]; // [rsp+70h] [rbp-20h] BYREF
unsigned long long v28; // [rsp+88h] [rbp-8h]
v28 = __readfsqword(0x28u);
v24 = a1;
v23 = a2;
v21 = *(_QWORD **)(a1 + 896);
v20 = v21[17];
if ( *(_DWORD *)(v21[19] + 1056LL) )
{
v19 = ha_key_cmp(*(_QWORD *)(v24 + 904), v21[19] + 16LL, v23, 2416LL, 131137LL, &v22);
if ( *(_DWORD *)(v20 + 134336) )
{
if ( *(_DWORD *)(v20 + 134336) == 2 )
v22 = mi_collect_stats_nonulls_next(*(_QWORD *)(v24 + 904), v24 + 1288, v21[19] + 16LL, v23);
}
else
{
ha_key_cmp(*(_QWORD *)(v24 + 904), v21[19] + 16LL, v23, 2416LL, 65537LL, &v22);
}
++*(_QWORD *)(v24 + 8LL * (unsigned int)(v22 - 1) + 1024);
}
else
{
v19 = -1;
if ( *(_DWORD *)(v20 + 134336) == 2 )
mi_collect_stats_nonulls_first(*(_QWORD *)(v24 + 904), v24 + 1288, v23);
}
if ( (*(_WORD *)(*(_QWORD *)(v24 + 888) + 10LL) & 1) == 0 || v19 )
{
return (unsigned int)sort_insert_key(v24, v21[19], v23, -1LL);
}
else
{
++v21[23];
*(_QWORD *)(v21[16] + 368LL) = get_record_for_key(v21[16], *(_QWORD *)(v24 + 888), v23);
if ( (*(_QWORD *)(v20 + 2832) & 0x3000000000LL) == 0x1000000000LL )
*(_QWORD *)(v20 + 2832) |= 0x2000000000uLL;
v18 = llstr(*(_QWORD *)(v21[16] + 368LL), v27);
record_for_key = get_record_for_key(v21[16], *(_QWORD *)(v24 + 888), v21[19] + 16LL);
v11 = llstr(record_for_key, v26);
mi_check_print_warning(
v20,
(long long)"Duplicate key for record at %10s against record at %10s",
v18,
v11,
v12,
v13,
a3,
a4,
a5,
a6,
v14,
v15,
a9,
a10,
v17);
*(_QWORD *)(v20 + 2832) |= 0x100000uLL;
if ( (*(_QWORD *)(v21[17] + 2832LL) & 0x10000000LL) != 0 )
mi_print_key(stdout, *(_QWORD *)(v24 + 904), v23, 2416LL);
return (unsigned int)sort_delete_record(v24);
}
}
|
sort_key_write:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x50],RDI
MOV qword ptr [RBP + -0x58],RSI
MOV RAX,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RAX + 0x380]
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RBP + -0x68]
MOV RAX,qword ptr [RAX + 0x88]
MOV qword ptr [RBP + -0x70],RAX
MOV RAX,qword ptr [RBP + -0x68]
MOV RAX,qword ptr [RAX + 0x98]
CMP dword ptr [RAX + 0x420],0x0
JZ 0x0013b2de
MOV RAX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RAX + 0x388]
MOV RAX,qword ptr [RBP + -0x68]
MOV RSI,qword ptr [RAX + 0x98]
ADD RSI,0x10
MOV RDX,qword ptr [RBP + -0x58]
LEA R9,[RBP + -0x60]
MOV ECX,0x970
MOV R8D,0x20041
CALL 0x0019ced0
MOV dword ptr [RBP + -0x74],EAX
MOV RAX,qword ptr [RBP + -0x70]
CMP dword ptr [RAX + 0x20cc0],0x0
JNZ 0x0013b27c
MOV RAX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RAX + 0x388]
MOV RAX,qword ptr [RBP + -0x68]
MOV RSI,qword ptr [RAX + 0x98]
ADD RSI,0x10
MOV RDX,qword ptr [RBP + -0x58]
LEA R9,[RBP + -0x60]
MOV ECX,0x970
MOV R8D,0x10001
CALL 0x0019ced0
JMP 0x0013b2bc
LAB_0013b27c:
MOV RAX,qword ptr [RBP + -0x70]
CMP dword ptr [RAX + 0x20cc0],0x2
JNZ 0x0013b2ba
MOV RAX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RAX + 0x388]
MOV RSI,qword ptr [RBP + -0x50]
ADD RSI,0x508
MOV RAX,qword ptr [RBP + -0x68]
MOV RDX,qword ptr [RAX + 0x98]
ADD RDX,0x10
MOV RCX,qword ptr [RBP + -0x58]
CALL 0x0013ef60
MOV dword ptr [RBP + -0x60],EAX
LAB_0013b2ba:
JMP 0x0013b2bc
LAB_0013b2bc:
MOV RAX,qword ptr [RBP + -0x50]
MOV ECX,dword ptr [RBP + -0x60]
SUB ECX,0x1
MOV ECX,ECX
MOV RDX,qword ptr [RAX + RCX*0x8 + 0x400]
ADD RDX,0x1
MOV qword ptr [RAX + RCX*0x8 + 0x400],RDX
JMP 0x0013b313
LAB_0013b2de:
MOV dword ptr [RBP + -0x74],0xffffffff
MOV RAX,qword ptr [RBP + -0x70]
CMP dword ptr [RAX + 0x20cc0],0x2
JNZ 0x0013b311
MOV RAX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RAX + 0x388]
MOV RSI,qword ptr [RBP + -0x50]
ADD RSI,0x508
MOV RDX,qword ptr [RBP + -0x58]
CALL 0x0013f010
LAB_0013b311:
JMP 0x0013b313
LAB_0013b313:
MOV RAX,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RAX + 0x378]
MOVZX EAX,word ptr [RAX + 0xa]
AND EAX,0x1
CMP EAX,0x0
JZ 0x0013b4a6
CMP dword ptr [RBP + -0x74],0x0
JNZ 0x0013b4a6
MOV RAX,qword ptr [RBP + -0x68]
MOV RCX,qword ptr [RAX + 0xb8]
ADD RCX,0x1
MOV qword ptr [RAX + 0xb8],RCX
MOV RAX,qword ptr [RBP + -0x68]
MOV RDI,qword ptr [RAX + 0x80]
MOV RAX,qword ptr [RBP + -0x50]
MOV RSI,qword ptr [RAX + 0x378]
MOV RDX,qword ptr [RBP + -0x58]
CALL 0x0013f080
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x68]
MOV RAX,qword ptr [RAX + 0x80]
MOV qword ptr [RAX + 0x170],RCX
MOV RCX,qword ptr [RBP + -0x70]
MOV RAX,0x3000000000
AND RAX,qword ptr [RCX + 0xb10]
MOV RCX,0x1000000000
CMP RAX,RCX
JNZ 0x0013b3c2
MOV RAX,qword ptr [RBP + -0x70]
MOV RCX,0x2000000000
OR RCX,qword ptr [RAX + 0xb10]
MOV qword ptr [RAX + 0xb10],RCX
LAB_0013b3c2:
MOV RAX,qword ptr [RBP + -0x70]
MOV qword ptr [RBP + -0x88],RAX
MOV RAX,qword ptr [RBP + -0x68]
MOV RAX,qword ptr [RAX + 0x80]
MOV RDI,qword ptr [RAX + 0x170]
LEA RSI,[RBP + -0x20]
CALL 0x001f2d30
MOV qword ptr [RBP + -0x80],RAX
MOV RAX,qword ptr [RBP + -0x68]
MOV RDI,qword ptr [RAX + 0x80]
MOV RAX,qword ptr [RBP + -0x50]
MOV RSI,qword ptr [RAX + 0x378]
MOV RAX,qword ptr [RBP + -0x68]
MOV RDX,qword ptr [RAX + 0x98]
ADD RDX,0x10
CALL 0x0013f080
MOV RDI,RAX
LEA RSI,[RBP + -0x40]
CALL 0x001f2d30
MOV RDI,qword ptr [RBP + -0x88]
MOV RDX,qword ptr [RBP + -0x80]
MOV RCX,RAX
LEA RSI,[0x1fd790]
MOV AL,0x0
CALL 0x0012c5b0
MOV RAX,qword ptr [RBP + -0x70]
MOV RCX,qword ptr [RAX + 0xb10]
OR RCX,0x100000
MOV qword ptr [RAX + 0xb10],RCX
MOV RAX,qword ptr [RBP + -0x68]
MOV RAX,qword ptr [RAX + 0x88]
MOV RAX,qword ptr [RAX + 0xb10]
AND RAX,0x10000000
CMP RAX,0x0
JZ 0x0013b498
MOV RAX,qword ptr [0x0035dfb8]
MOV RDI,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x50]
MOV RSI,qword ptr [RAX + 0x388]
MOV RDX,qword ptr [RBP + -0x58]
MOV ECX,0x970
CALL 0x00142620
LAB_0013b498:
MOV RDI,qword ptr [RBP + -0x50]
CALL 0x0013f0d0
MOV dword ptr [RBP + -0x44],EAX
JMP 0x0013b4c8
LAB_0013b4a6:
MOV RDI,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RBP + -0x68]
MOV RSI,qword ptr [RAX + 0x98]
MOV RDX,qword ptr [RBP + -0x58]
MOV RCX,-0x1
CALL 0x0013d320
MOV dword ptr [RBP + -0x44],EAX
LAB_0013b4c8:
MOV EAX,dword ptr [RBP + -0x44]
MOV dword ptr [RBP + -0x8c],EAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x0013b4f2
MOV EAX,dword ptr [RBP + -0x8c]
ADD RSP,0x90
POP RBP
RET
LAB_0013b4f2:
CALL 0x0012a420
|
int4 sort_key_write(long param_1,int8 param_2)
{
long lVar1;
long lVar2;
int8 uVar3;
int8 uVar4;
long in_FS_OFFSET;
int local_7c;
int local_68 [2];
int8 local_60;
long local_58;
int4 local_4c;
int1 local_48 [32];
int1 local_28 [24];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
lVar1 = *(long *)(param_1 + 0x380);
lVar2 = *(long *)(lVar1 + 0x88);
local_60 = param_2;
local_58 = param_1;
if (*(int *)(*(long *)(lVar1 + 0x98) + 0x420) == 0) {
local_7c = -1;
if (*(int *)(lVar2 + 0x20cc0) == 2) {
mi_collect_stats_nonulls_first(*(int8 *)(param_1 + 0x388),param_1 + 0x508,param_2);
}
}
else {
local_7c = ha_key_cmp(*(int8 *)(param_1 + 0x388),*(long *)(lVar1 + 0x98) + 0x10,param_2,
0x970,0x20041,local_68);
if (*(int *)(lVar2 + 0x20cc0) == 0) {
ha_key_cmp(*(int8 *)(local_58 + 0x388),*(long *)(lVar1 + 0x98) + 0x10,local_60,0x970,
0x10001,local_68);
}
else if (*(int *)(lVar2 + 0x20cc0) == 2) {
local_68[0] = mi_collect_stats_nonulls_next
(*(int8 *)(local_58 + 0x388),local_58 + 0x508,
*(long *)(lVar1 + 0x98) + 0x10,local_60);
}
*(long *)(local_58 + 0x400 + (ulong)(local_68[0] - 1) * 8) =
*(long *)(local_58 + 0x400 + (ulong)(local_68[0] - 1) * 8) + 1;
}
if (((*(ushort *)(*(long *)(local_58 + 0x378) + 10) & 1) == 0) || (local_7c != 0)) {
local_4c = sort_insert_key(local_58,*(int8 *)(lVar1 + 0x98),local_60,0xffffffffffffffff);
}
else {
*(long *)(lVar1 + 0xb8) = *(long *)(lVar1 + 0xb8) + 1;
uVar3 = get_record_for_key(*(int8 *)(lVar1 + 0x80),*(int8 *)(local_58 + 0x378),
local_60);
*(int8 *)(*(long *)(lVar1 + 0x80) + 0x170) = uVar3;
if ((*(ulong *)(lVar2 + 0xb10) & 0x3000000000) == 0x1000000000) {
*(ulong *)(lVar2 + 0xb10) = *(ulong *)(lVar2 + 0xb10) | 0x2000000000;
}
uVar3 = llstr(*(int8 *)(*(long *)(lVar1 + 0x80) + 0x170),local_28);
uVar4 = get_record_for_key(*(int8 *)(lVar1 + 0x80),*(int8 *)(local_58 + 0x378),
*(long *)(lVar1 + 0x98) + 0x10);
uVar4 = llstr(uVar4,local_48);
mi_check_print_warning
(lVar2,"Duplicate key for record at %10s against record at %10s",uVar3,uVar4);
*(ulong *)(lVar2 + 0xb10) = *(ulong *)(lVar2 + 0xb10) | 0x100000;
if ((*(ulong *)(*(long *)(lVar1 + 0x88) + 0xb10) & 0x10000000) != 0) {
_mi_print_key(*(int8 *)PTR_stdout_0035dfb8,*(int8 *)(local_58 + 0x388),local_60,
0x970);
}
local_4c = sort_delete_record(local_58);
}
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return local_4c;
}
|
|
64,867 |
my_wc_mb_filename
|
eloqsql/strings/ctype-utf8.c
|
static int
my_wc_mb_filename(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t wc, uchar *s, uchar *e)
{
int code;
static const char hex[]= "0123456789abcdef";
if (s >= e)
return MY_CS_TOOSMALL;
if (wc < 128 && filename_safe_char[wc])
{
*s= (uchar) wc;
return 1;
}
if (s + 3 > e)
return MY_CS_TOOSMALL3;
*s++= MY_FILENAME_ESCAPE;
if ((wc >= 0x00C0 && wc <= 0x05FF && (code= uni_0C00_05FF[wc - 0x00C0])) ||
(wc >= 0x1E00 && wc <= 0x1FFF && (code= uni_1E00_1FFF[wc - 0x1E00])) ||
(wc >= 0x2160 && wc <= 0x217F && (code= uni_2160_217F[wc - 0x2160])) ||
(wc >= 0x24B0 && wc <= 0x24EF && (code= uni_24B0_24EF[wc - 0x24B0])) ||
(wc >= 0xFF20 && wc <= 0xFF5F && (code= uni_FF20_FF5F[wc - 0xFF20])))
{
*s++= (code / 80) + 0x30;
*s++= (code % 80) + 0x30;
return 3;
}
/* Non letter */
if (s + 4 > e)
return MY_CS_TOOSMALL5;
*s++= hex[(wc >> 12) & 15];
*s++= hex[(wc >> 8) & 15];
*s++= hex[(wc >> 4) & 15];
*s++= hex[(wc) & 15];
return 5;
}
|
O3
|
c
|
my_wc_mb_filename:
pushq %rbp
movq %rsp, %rbp
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmpq %rcx, %rdx
jae 0xd041a
cmpq $0x7f, %rsi
ja 0xd037a
leaq 0x287a29(%rip), %rax # 0x357d90
cmpb $0x0, (%rsi,%rax)
je 0xd037a
movb %sil, (%rdx)
movl $0x1, %eax
jmp 0xd041a
leaq 0x3(%rdx), %rdi
movl $0xffffff99, %eax # imm = 0xFFFFFF99
cmpq %rcx, %rdi
ja 0xd041a
movb $0x40, (%rdx)
leaq -0xc0(%rsi), %rax
cmpq $0x53f, %rax # imm = 0x53F
ja 0xd03b2
leaq 0x28af8b(%rip), %rax # 0x35b330
movzwl -0x180(%rax,%rsi,2), %eax
testw %ax, %ax
jne 0xd03f5
movq %rsi, %rax
andq $-0x200, %rax # imm = 0xFE00
cmpq $0x1e00, %rax # imm = 0x1E00
jne 0xd03d7
leaq 0x28aa26(%rip), %rax # 0x35adf0
movzwl -0x3c00(%rax,%rsi,2), %eax
testw %ax, %ax
jne 0xd03f5
movq %rsi, %rax
andq $-0x20, %rax
cmpq $0x2160, %rax # imm = 0x2160
jne 0xd041c
leaq 0x28ae03(%rip), %rax # 0x35b1f0
movzwl -0x42c0(%rax,%rsi,2), %eax
movzwl %ax, %ecx
imull $0xcccd, %ecx, %ecx # imm = 0xCCCD
shrl $0x16, %ecx
leal 0x30(%rcx), %esi
movb %sil, 0x1(%rdx)
shll $0x4, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
addb $0x30, %al
movb %al, 0x2(%rdx)
movl $0x3, %eax
popq %rbp
retq
leaq -0x24b0(%rsi), %rax
cmpq $0x3f, %rax
ja 0xd0447
leaq -0x24ea(%rsi), %rax
cmpq $-0x34, %rax
jb 0xd0475
leaq 0x28adf3(%rip), %rax # 0x35b230
movzwl -0x4960(%rax,%rsi,2), %eax
jmp 0xd03f5
leaq -0xff20(%rsi), %rax
cmpq $0x3f, %rax
ja 0xd0475
movabsq $-0x7fffffe07ffffff, %rdi # imm = 0xF8000001F8000001
btq %rax, %rdi
jb 0xd0475
leaq 0x28ae45(%rip), %rax # 0x35b2b0
movzwl -0x1fe40(%rax,%rsi,2), %eax
jmp 0xd03f5
leaq 0x5(%rdx), %rdi
movl $0xffffff97, %eax # imm = 0xFFFFFF97
cmpq %rcx, %rdi
ja 0xd041a
movl %esi, %eax
shrl $0xc, %eax
andl $0xf, %eax
leaq 0x28b91e(%rip), %rcx # 0x35bdb0
movb (%rax,%rcx), %al
movb %al, 0x1(%rdx)
movl %esi, %eax
shrl $0x8, %eax
andl $0xf, %eax
movb (%rax,%rcx), %al
movb %al, 0x2(%rdx)
movl %esi, %eax
shrl $0x4, %eax
andl $0xf, %eax
movb (%rax,%rcx), %al
movb %al, 0x3(%rdx)
andl $0xf, %esi
movb (%rsi,%rcx), %al
movb %al, 0x4(%rdx)
movl $0x5, %eax
jmp 0xd041a
|
my_wc_mb_filename:
push rbp
mov rbp, rsp
mov eax, 0FFFFFF9Bh
cmp rdx, rcx
jnb loc_D041A
cmp rsi, 7Fh
ja short loc_D037A
lea rax, filename_safe_char
cmp byte ptr [rsi+rax], 0
jz short loc_D037A
mov [rdx], sil
mov eax, 1
jmp loc_D041A
loc_D037A:
lea rdi, [rdx+3]
mov eax, 0FFFFFF99h
cmp rdi, rcx
ja loc_D041A
mov byte ptr [rdx], 40h ; '@'
lea rax, [rsi-0C0h]
cmp rax, 53Fh
ja short loc_D03B2
lea rax, uni_0C00_05FF
movzx eax, word ptr [rax+rsi*2-180h]
test ax, ax
jnz short loc_D03F5
loc_D03B2:
mov rax, rsi
and rax, 0FFFFFFFFFFFFFE00h
cmp rax, 1E00h
jnz short loc_D03D7
lea rax, uni_1E00_1FFF
movzx eax, word ptr [rax+rsi*2-3C00h]
test ax, ax
jnz short loc_D03F5
loc_D03D7:
mov rax, rsi
and rax, 0FFFFFFFFFFFFFFE0h
cmp rax, 2160h
jnz short loc_D041C
lea rax, uni_2160_217F
movzx eax, word ptr [rax+rsi*2-42C0h]
loc_D03F5:
movzx ecx, ax
imul ecx, 0CCCDh
shr ecx, 16h
lea esi, [rcx+30h]
mov [rdx+1], sil
shl ecx, 4
lea ecx, [rcx+rcx*4]
sub eax, ecx
add al, 30h ; '0'
mov [rdx+2], al
mov eax, 3
loc_D041A:
pop rbp
retn
loc_D041C:
lea rax, [rsi-24B0h]
cmp rax, 3Fh ; '?'
ja short loc_D0447
lea rax, [rsi-24EAh]
cmp rax, 0FFFFFFFFFFFFFFCCh
jb short loc_D0475
lea rax, uni_24B0_24EF
movzx eax, word ptr [rax+rsi*2-4960h]
jmp short loc_D03F5
loc_D0447:
lea rax, [rsi-0FF20h]
cmp rax, 3Fh ; '?'
ja short loc_D0475
mov rdi, 0F8000001F8000001h
bt rdi, rax
jb short loc_D0475
lea rax, uni_FF20_FF5F
movzx eax, word ptr [rax+rsi*2-1FE40h]
jmp short loc_D03F5
loc_D0475:
lea rdi, [rdx+5]
mov eax, 0FFFFFF97h
cmp rdi, rcx
ja short loc_D041A
mov eax, esi
shr eax, 0Ch
and eax, 0Fh
lea rcx, my_wc_mb_filename_hex; "0123456789abcdef"
mov al, [rax+rcx]
mov [rdx+1], al
mov eax, esi
shr eax, 8
and eax, 0Fh
mov al, [rax+rcx]
mov [rdx+2], al
mov eax, esi
shr eax, 4
and eax, 0Fh
mov al, [rax+rcx]
mov [rdx+3], al
and esi, 0Fh
mov al, [rsi+rcx]
mov [rdx+4], al
mov eax, 5
jmp loc_D041A
|
long long my_wc_mb_filename(long long a1, unsigned long long a2, _BYTE *a3, unsigned long long a4)
{
long long result; // rax
unsigned __int16 v5; // ax
unsigned long long v6; // rdi
result = 4294967195LL;
if ( (unsigned long long)a3 < a4 )
{
if ( a2 <= 0x7F && filename_safe_char[a2] )
{
*a3 = a2;
return 1LL;
}
result = 4294967193LL;
if ( (unsigned long long)(a3 + 3) <= a4 )
{
*a3 = 64;
if ( a2 - 192 <= 0x53F )
{
v5 = uni_0C00_05FF[a2 - 192];
if ( v5 )
goto LABEL_12;
}
if ( (a2 & 0xFFFFFFFFFFFFFE00LL) == 0x1E00 )
{
v5 = uni_1E00_1FFF[a2 - 7680];
if ( v5 )
goto LABEL_12;
}
if ( (a2 & 0xFFFFFFFFFFFFFFE0LL) == 0x2160 )
{
v5 = uni_2160_217F[a2 - 8544];
LABEL_12:
a3[1] = v5 / 0x50u + 48;
a3[2] = v5 % 0x50u + 48;
return 3LL;
}
if ( a2 - 9392 > 0x3F )
{
if ( a2 - 65312 <= 0x3F )
{
v6 = 0xF8000001F8000001LL;
if ( !_bittest64((const long long *)&v6, a2 - 65312) )
{
v5 = uni_FF20_FF5F[a2 - 65312];
goto LABEL_12;
}
}
}
else if ( a2 - 9450 >= 0xFFFFFFFFFFFFFFCCLL )
{
v5 = uni_24B0_24EF[a2 - 9392];
goto LABEL_12;
}
result = 4294967191LL;
if ( (unsigned long long)(a3 + 5) <= a4 )
{
a3[1] = my_wc_mb_filename_hex[(unsigned __int16)a2 >> 12];
a3[2] = my_wc_mb_filename_hex[((unsigned int)a2 >> 8) & 0xF];
a3[3] = my_wc_mb_filename_hex[(unsigned __int8)a2 >> 4];
a3[4] = my_wc_mb_filename_hex[a2 & 0xF];
return 5LL;
}
}
}
return result;
}
|
my_wc_mb_filename:
PUSH RBP
MOV RBP,RSP
MOV EAX,0xffffff9b
CMP RDX,RCX
JNC 0x001d041a
CMP RSI,0x7f
JA 0x001d037a
LEA RAX,[0x457d90]
CMP byte ptr [RSI + RAX*0x1],0x0
JZ 0x001d037a
MOV byte ptr [RDX],SIL
MOV EAX,0x1
JMP 0x001d041a
LAB_001d037a:
LEA RDI,[RDX + 0x3]
MOV EAX,0xffffff99
CMP RDI,RCX
JA 0x001d041a
MOV byte ptr [RDX],0x40
LEA RAX,[RSI + -0xc0]
CMP RAX,0x53f
JA 0x001d03b2
LEA RAX,[0x45b330]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x180]
TEST AX,AX
JNZ 0x001d03f5
LAB_001d03b2:
MOV RAX,RSI
AND RAX,-0x200
CMP RAX,0x1e00
JNZ 0x001d03d7
LEA RAX,[0x45adf0]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x3c00]
TEST AX,AX
JNZ 0x001d03f5
LAB_001d03d7:
MOV RAX,RSI
AND RAX,-0x20
CMP RAX,0x2160
JNZ 0x001d041c
LEA RAX,[0x45b1f0]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x42c0]
LAB_001d03f5:
MOVZX ECX,AX
IMUL ECX,ECX,0xcccd
SHR ECX,0x16
LEA ESI,[RCX + 0x30]
MOV byte ptr [RDX + 0x1],SIL
SHL ECX,0x4
LEA ECX,[RCX + RCX*0x4]
SUB EAX,ECX
ADD AL,0x30
MOV byte ptr [RDX + 0x2],AL
MOV EAX,0x3
LAB_001d041a:
POP RBP
RET
LAB_001d041c:
LEA RAX,[RSI + -0x24b0]
CMP RAX,0x3f
JA 0x001d0447
LEA RAX,[RSI + -0x24ea]
CMP RAX,-0x34
JC 0x001d0475
LEA RAX,[0x45b230]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x4960]
JMP 0x001d03f5
LAB_001d0447:
LEA RAX,[RSI + -0xff20]
CMP RAX,0x3f
JA 0x001d0475
MOV RDI,-0x7fffffe07ffffff
BT RDI,RAX
JC 0x001d0475
LEA RAX,[0x45b2b0]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x1fe40]
JMP 0x001d03f5
LAB_001d0475:
LEA RDI,[RDX + 0x5]
MOV EAX,0xffffff97
CMP RDI,RCX
JA 0x001d041a
MOV EAX,ESI
SHR EAX,0xc
AND EAX,0xf
LEA RCX,[0x45bdb0]
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x1],AL
MOV EAX,ESI
SHR EAX,0x8
AND EAX,0xf
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x2],AL
MOV EAX,ESI
SHR EAX,0x4
AND EAX,0xf
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x3],AL
AND ESI,0xf
MOV AL,byte ptr [RSI + RCX*0x1]
MOV byte ptr [RDX + 0x4],AL
MOV EAX,0x5
JMP 0x001d041a
|
int8
my_wc_mb_filename(int8 param_1,ulong param_2,int1 *param_3,int1 *param_4)
{
ushort uVar1;
if (param_4 <= param_3) {
return 0xffffff9b;
}
if ((param_2 < 0x80) && (filename_safe_char[param_2] != '\0')) {
*param_3 = (char)param_2;
return 1;
}
if (param_4 < param_3 + 3) {
return 0xffffff99;
}
*param_3 = 0x40;
if (((0x53f < param_2 - 0xc0) ||
(uVar1 = *(ushort *)(uni_1E00_1FFF + param_2 * 2 + 0x3c0), uVar1 == 0)) &&
(((param_2 & 0xfffffffffffffe00) != 0x1e00 ||
(uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1f780), uVar1 == 0)))) {
if ((param_2 & 0xffffffffffffffe0) == 0x2160) {
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1f4c0);
}
else if (param_2 - 0x24b0 < 0x40) {
if (param_2 - 0x24ea < 0xffffffffffffffcc) {
LAB_001d0475:
if (param_4 < param_3 + 5) {
return 0xffffff97;
}
param_3[1] = "0123456789abcdef"[(uint)(param_2 >> 0xc) & 0xf];
param_3[2] = "0123456789abcdef"[(uint)(param_2 >> 8) & 0xf];
param_3[3] = "0123456789abcdef"[(uint)(param_2 >> 4) & 0xf];
param_3[4] = "0123456789abcdef"[(uint)param_2 & 0xf];
return 5;
}
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1ee60);
}
else {
if ((0x3f < param_2 - 0xff20) || ((0xf8000001f8000001U >> (param_2 - 0xff20 & 0x3f) & 1) != 0)
) goto LAB_001d0475;
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x3a00);
}
}
param_3[1] = (char)(uVar1 / 0x50) + '0';
param_3[2] = (char)uVar1 + (char)(uVar1 / 0x50 << 4) * -5 + '0';
return 3;
}
|
|
64,868 |
minja::TemplateToken::typeToString[abi:cxx11](minja::TemplateToken::Type)
|
llama.cpp/common/minja/minja.hpp
|
static std::string typeToString(Type t) {
switch (t) {
case Type::Text: return "text";
case Type::Expression: return "expression";
case Type::If: return "if";
case Type::Else: return "else";
case Type::Elif: return "elif";
case Type::EndIf: return "endif";
case Type::For: return "for";
case Type::EndFor: return "endfor";
case Type::Set: return "set";
case Type::EndSet: return "endset";
case Type::Comment: return "comment";
case Type::Macro: return "macro";
case Type::EndMacro: return "endmacro";
case Type::Filter: return "filter";
case Type::EndFilter: return "endfilter";
case Type::Generation: return "generation";
case Type::EndGeneration: return "endgeneration";
case Type::Break: return "break";
case Type::Continue: return "continue";
}
return "Unknown";
}
|
O3
|
cpp
|
minja::TemplateToken::typeToString[abi:cxx11](minja::TemplateToken::Type):
pushq %rbx
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
cmpl $0x12, %esi
ja 0xefd39
movl %esi, %eax
leaq 0x30be1(%rip), %rcx # 0x1207c0
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x30cfb(%rip), %rsi # 0x1208ea
leaq 0x30cf8(%rip), %rdx # 0x1208ee
jmp 0xefd47
leaq 0x33177(%rip), %rsi # 0x122d79
leaq 0x33179(%rip), %rdx # 0x122d82
jmp 0xefd47
leaq 0x33137(%rip), %rsi # 0x122d4c
leaq 0x33138(%rip), %rdx # 0x122d54
jmp 0xefd47
leaq 0x330fa(%rip), %rsi # 0x122d22
leaq 0x330f9(%rip), %rdx # 0x122d28
jmp 0xefd47
leaq 0x32ffd(%rip), %rsi # 0x122c38
leaq 0x32ffa(%rip), %rdx # 0x122c3c
jmp 0xefd47
leaq 0x33172(%rip), %rsi # 0x122dc0
leaq 0x33172(%rip), %rdx # 0x122dc7
jmp 0xefd47
leaq 0x33062(%rip), %rsi # 0x122cc3
leaq 0x33068(%rip), %rdx # 0x122cd0
jmp 0xefd47
leaq 0x2618e(%rip), %rsi # 0x115e02
leaq 0x26189(%rip), %rdx # 0x115e04
jmp 0xefd47
leaq 0x330f5(%rip), %rsi # 0x122d7c
leaq 0x330f4(%rip), %rdx # 0x122d82
jmp 0xefd47
leaq 0x32fc4(%rip), %rsi # 0x122c5e
leaq 0x32fc1(%rip), %rdx # 0x122c62
jmp 0xefd47
leaq 0x3300f(%rip), %rsi # 0x122cbc
leaq 0x3300e(%rip), %rdx # 0x122cc2
jmp 0xefd47
leaq 0x331a1(%rip), %rsi # 0x122e61
leaq 0x331a4(%rip), %rdx # 0x122e6b
jmp 0xefd47
leaq 0x330b3(%rip), %rsi # 0x122d83
leaq 0x330b1(%rip), %rdx # 0x122d88
jmp 0xefd47
leaq 0x32f83(%rip), %rsi # 0x122c63
leaq 0x32f81(%rip), %rdx # 0x122c68
jmp 0xefd47
leaq 0x3305f(%rip), %rsi # 0x122d4f
leaq 0x3305d(%rip), %rdx # 0x122d54
jmp 0xefd47
leaq 0x32fbf(%rip), %rsi # 0x122cbf
leaq 0x32fbb(%rip), %rdx # 0x122cc2
jmp 0xefd47
leaq 0x33079(%rip), %rsi # 0x122d89
leaq 0x3307a(%rip), %rdx # 0x122d91
jmp 0xefd47
leaq 0x37a2f(%rip), %rsi # 0x12774f
leaq 0x37a2b(%rip), %rdx # 0x127752
jmp 0xefd47
leaq 0x2a519(%rip), %rsi # 0x11a249
leaq 0x2a51c(%rip), %rdx # 0x11a253
jmp 0xefd47
leaq 0x33e22(%rip), %rsi # 0x123b62
leaq 0x33e22(%rip), %rdx # 0x123b69
movq %rbx, %rdi
callq 0x289fc
movq %rbx, %rax
popq %rbx
retq
|
_ZN5minja13TemplateToken12typeToStringB5cxx11ENS0_4TypeE:
push rbx
mov rbx, rdi
lea rax, [rdi+10h]
mov [rdi], rax
cmp esi, 12h; switch 19 cases
ja def_EFBE6; jumptable 00000000000EFBE6 default case
mov eax, esi
lea rcx, jpt_EFBE6
movsxd rax, ds:(jpt_EFBE6 - 1207C0h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_EFBE8:
lea rsi, aText; jumptable 00000000000EFBE6 case 0
lea rdx, aText+4; ""
jmp loc_EFD47
loc_EFBFB:
lea rsi, aEndfilter; jumptable 00000000000EFBE6 case 16
lea rdx, aEndfilter+9; ""
jmp loc_EFD47
loc_EFC0E:
lea rsi, aEndmacro; jumptable 00000000000EFBE6 case 14
lea rdx, aEndmacro+8; ""
jmp loc_EFD47
loc_EFC21:
lea rsi, aEndset; jumptable 00000000000EFBE6 case 11
lea rdx, aEndset+6; ""
jmp loc_EFD47
loc_EFC34:
lea rsi, aElif; jumptable 00000000000EFBE6 case 4
lea rdx, aElif+4; ""
jmp loc_EFD47
loc_EFC47:
lea rsi, aInternalErrorE+1Bh; jumptable 00000000000EFBE6 case 12
lea rdx, aInternalErrorE+22h; ""
jmp loc_EFD47
loc_EFC5A:
lea rsi, aEndgeneration; jumptable 00000000000EFBE6 case 9
lea rdx, aEndgeneration+0Dh; ""
jmp loc_EFD47
loc_EFC6D:
lea rsi, aIf+1; jumptable 00000000000EFBE6 case 2
lea rdx, aIf+3; ""
jmp loc_EFD47
loc_EFC80:
lea rsi, aEndfilter+3; jumptable 00000000000EFBE6 case 15
lea rdx, aEndfilter+9; ""
jmp loc_EFD47
loc_EFC93:
lea rsi, aElse; jumptable 00000000000EFBE6 case 3
lea rdx, aElse+4; ""
jmp loc_EFD47
loc_EFCA6:
lea rsi, aEndfor; jumptable 00000000000EFBE6 case 7
lea rdx, aEndfor+6; ""
jmp loc_EFD47
loc_EFCB9:
lea rsi, aExpectedLeftSi_0+24h; jumptable 00000000000EFBE6 case 1
lea rdx, aExpectedLeftSi_0+2Eh; ""
jmp short loc_EFD47
loc_EFCC9:
lea rsi, aBreak; jumptable 00000000000EFBE6 case 17
lea rdx, aBreak+5; ""
jmp short loc_EFD47
loc_EFCD9:
lea rsi, aEndif; jumptable 00000000000EFBE6 case 5
lea rdx, aEndif+5; ""
jmp short loc_EFD47
loc_EFCE9:
lea rsi, aEndmacro+3; jumptable 00000000000EFBE6 case 13
lea rdx, aEndmacro+8; ""
jmp short loc_EFD47
loc_EFCF9:
lea rsi, aEndfor+3; jumptable 00000000000EFBE6 case 6
lea rdx, aEndfor+6; ""
jmp short loc_EFD47
loc_EFD09:
lea rsi, aContinue; jumptable 00000000000EFBE6 case 18
lea rdx, aContinue+8; ""
jmp short loc_EFD47
loc_EFD19:
lea rsi, aAtLeastOneOfMi+2Fh; jumptable 00000000000EFBE6 case 10
lea rdx, aAtLeastOneOfMi+32h; ""
jmp short loc_EFD47
loc_EFD29:
lea rsi, aSpeakerFilePat+1Ch; jumptable 00000000000EFBE6 case 8
lea rdx, aSpeakerFilePat+26h; ""
jmp short loc_EFD47
def_EFBE6:
lea rsi, aUnknown; jumptable 00000000000EFBE6 default case
lea rdx, aUnknown+7; ""
loc_EFD47:
mov rdi, rbx
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rax, rbx
pop rbx
retn
|
_QWORD * minja::TemplateToken::typeToString[abi:cxx11](_QWORD *a1, int a2)
{
char *v2; // rsi
char *v3; // rdx
*a1 = a1 + 2;
switch ( a2 )
{
case 0:
v2 = "text";
v3 = (char *)"";
break;
case 1:
v2 = (char *)"expression";
v3 = (char *)"";
break;
case 2:
v2 = "if";
v3 = "";
break;
case 3:
v2 = "else";
v3 = "";
break;
case 4:
v2 = "elif";
v3 = "";
break;
case 5:
v2 = "endif";
v3 = "";
break;
case 6:
v2 = "for";
v3 = "";
break;
case 7:
v2 = "endfor";
v3 = "";
break;
case 8:
v2 = "generation";
v3 = "";
break;
case 9:
v2 = "endgeneration";
v3 = "";
break;
case 10:
v2 = (char *)"set";
v3 = (char *)"";
break;
case 11:
v2 = "endset";
v3 = "";
break;
case 12:
v2 = (char *)"comment";
v3 = (char *)"";
break;
case 13:
v2 = "macro";
v3 = "";
break;
case 14:
v2 = "endmacro";
v3 = "";
break;
case 15:
v2 = "filter";
v3 = "";
break;
case 16:
v2 = "endfilter";
v3 = "";
break;
case 17:
v2 = "break";
v3 = "";
break;
case 18:
v2 = "continue";
v3 = "";
break;
default:
v2 = "Unknown";
v3 = "";
break;
}
std::string::_M_construct<char const*>((long long)a1, v2, (long long)v3);
return a1;
}
|
typeToString[abi:cxx11]:
PUSH RBX
MOV RBX,RDI
LEA RAX,[RDI + 0x10]
MOV qword ptr [RDI],RAX
CMP ESI,0x12
JA 0x001efd39
MOV EAX,ESI
LEA RCX,[0x2207c0]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_0:
LEA RSI,[0x2208ea]
LEA RDX,[0x2208ee]
JMP 0x001efd47
caseD_10:
LEA RSI,[0x222d79]
LEA RDX,[0x222d82]
JMP 0x001efd47
caseD_e:
LEA RSI,[0x222d4c]
LEA RDX,[0x222d54]
JMP 0x001efd47
caseD_b:
LEA RSI,[0x222d22]
LEA RDX,[0x222d28]
JMP 0x001efd47
caseD_4:
LEA RSI,[0x222c38]
LEA RDX,[0x222c3c]
JMP 0x001efd47
caseD_c:
LEA RSI,[0x222dc0]
LEA RDX,[0x222dc7]
JMP 0x001efd47
caseD_9:
LEA RSI,[0x222cc3]
LEA RDX,[0x222cd0]
JMP 0x001efd47
caseD_2:
LEA RSI,[0x215e02]
LEA RDX,[0x215e04]
JMP 0x001efd47
caseD_f:
LEA RSI,[0x222d7c]
LEA RDX,[0x222d82]
JMP 0x001efd47
caseD_3:
LEA RSI,[0x222c5e]
LEA RDX,[0x222c62]
JMP 0x001efd47
caseD_7:
LEA RSI,[0x222cbc]
LEA RDX,[0x222cc2]
JMP 0x001efd47
caseD_1:
LEA RSI,[0x222e61]
LEA RDX,[0x222e6b]
JMP 0x001efd47
caseD_11:
LEA RSI,[0x222d83]
LEA RDX,[0x222d88]
JMP 0x001efd47
caseD_5:
LEA RSI,[0x222c63]
LEA RDX,[0x222c68]
JMP 0x001efd47
caseD_d:
LEA RSI,[0x222d4f]
LEA RDX,[0x222d54]
JMP 0x001efd47
caseD_6:
LEA RSI,[0x222cbf]
LEA RDX,[0x222cc2]
JMP 0x001efd47
caseD_12:
LEA RSI,[0x222d89]
LEA RDX,[0x222d91]
JMP 0x001efd47
caseD_a:
LEA RSI,[0x22774f]
LEA RDX,[0x227752]
JMP 0x001efd47
caseD_8:
LEA RSI,[0x21a249]
LEA RDX,[0x21a253]
JMP 0x001efd47
default:
LEA RSI,[0x223b62]
LEA RDX,[0x223b69]
LAB_001efd47:
MOV RDI,RBX
CALL 0x001289fc
MOV RAX,RBX
POP RBX
RET
|
/* minja::TemplateToken::typeToString[abi:cxx11](minja::TemplateToken::Type) */
TemplateToken * __thiscall
minja::TemplateToken::typeToString_abi_cxx11_(TemplateToken *this,int4 param_2)
{
char *pcVar1;
char *pcVar2;
*(TemplateToken **)this = this + 0x10;
switch(param_2) {
case 0:
pcVar2 = "text";
pcVar1 = "";
break;
case 1:
pcVar2 = "expression";
pcVar1 = "";
break;
case 2:
pcVar2 = "if";
pcVar1 = "";
break;
case 3:
pcVar2 = "else";
pcVar1 = "";
break;
case 4:
pcVar2 = "elif";
pcVar1 = "";
break;
case 5:
pcVar2 = "endif";
pcVar1 = "";
break;
case 6:
pcVar2 = "for";
pcVar1 = "";
break;
case 7:
pcVar2 = "endfor";
pcVar1 = "";
break;
case 8:
pcVar2 = "generation";
pcVar1 = "";
break;
case 9:
pcVar2 = "endgeneration";
pcVar1 = "";
break;
case 10:
pcVar2 = "set";
pcVar1 = "";
break;
case 0xb:
pcVar2 = "endset";
pcVar1 = "";
break;
case 0xc:
pcVar2 = "comment";
pcVar1 = "";
break;
case 0xd:
pcVar2 = "macro";
pcVar1 = "";
break;
case 0xe:
pcVar2 = "endmacro";
pcVar1 = "";
break;
case 0xf:
pcVar2 = "filter";
pcVar1 = "";
break;
case 0x10:
pcVar2 = "endfilter";
pcVar1 = "";
break;
case 0x11:
pcVar2 = "break";
pcVar1 = "";
break;
case 0x12:
pcVar2 = "continue";
pcVar1 = "";
break;
default:
pcVar2 = "Unknown";
pcVar1 = "";
}
std::__cxx11::string::_M_construct<char_const*>(this,pcVar2,pcVar1);
return this;
}
|
|
64,869 |
fmt::v10::detail::fractional_part_rounding_thresholds(int)
|
AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/fmt/bundled/format.h
|
constexpr auto fractional_part_rounding_thresholds(int index) -> uint32_t {
// For checking rounding thresholds.
// The kth entry is chosen to be the smallest integer such that the
// upper 32-bits of 10^(k+1) times it is strictly bigger than 5 * 10^k.
// It is equal to ceil(2^31 + 2^32/10^(k + 1)).
// These are stored in a string literal because we cannot have static arrays
// in constexpr functions and non-static ones are poorly optimized.
return U"\x9999999a\x828f5c29\x80418938\x80068db9\x8000a7c6\x800010c7"
U"\x800001ae\x8000002b"[index];
}
|
O0
|
c
|
fmt::v10::detail::fractional_part_rounding_thresholds(int):
movl %edi, -0x4(%rsp)
movslq -0x4(%rsp), %rcx
leaq 0x65624(%rip), %rax # 0x110f34
movl (%rax,%rcx,4), %eax
retq
nopw %cs:(%rax,%rax)
nop
|
_ZN3fmt3v106detail35fractional_part_rounding_thresholdsEi:
mov [rsp+var_4], edi
movsxd rcx, [rsp+var_4]
lea rax, unk_110F34
mov eax, [rax+rcx*4]
retn
|
long long fmt::v10::detail::fractional_part_rounding_thresholds(fmt::v10::detail *this)
{
return dword_110F34[(int)this];
}
|
fractional_part_rounding_thresholds:
MOV dword ptr [RSP + -0x4],EDI
MOVSXD RCX,dword ptr [RSP + -0x4]
LEA RAX,[0x210f34]
MOV EAX,dword ptr [RAX + RCX*0x4]
RET
|
/* fmt::v10::detail::fractional_part_rounding_thresholds(int) */
int4 fmt::v10::detail::fractional_part_rounding_thresholds(int param_1)
{
return *(int4 *)(&DAT_00210f34 + (long)param_1 * 4);
}
|
|
64,870 |
ma_nommap_pread
|
eloqsql/storage/maria/ma_dynrec.c
|
size_t _ma_nommap_pread(MARIA_HA *info, uchar *Buffer,
size_t Count, my_off_t offset, myf MyFlags)
{
return mysql_file_pread(info->dfile.file, Buffer, Count, offset, MyFlags);
}
|
O3
|
c
|
ma_nommap_pread:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %r8, -0x30(%rbp)
movq %rcx, %r12
movq %rdx, %r14
movq %rsi, %r13
movl 0x480(%rdi), %ebx
leaq 0x3455e2(%rip), %rax # 0x38f258
movq (%rax), %rax
leaq -0x78(%rbp), %rdi
movl %ebx, %esi
movl $0x6, %edx
callq *0x158(%rax)
testq %rax, %rax
jne 0x49cb8
movl %ebx, %edi
movq %r13, %rsi
movq %r14, %rdx
movq %r12, %rcx
movq -0x30(%rbp), %r8
callq 0xa6c7c
movq %rax, %rbx
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r15
leaq 0x345596(%rip), %rax # 0x38f258
movq (%rax), %rax
leaq 0x980aa(%rip), %rdx # 0xe1d76
movq %r15, %rdi
movq %r14, %rsi
movl $0xa2, %ecx
callq *0x210(%rax)
movl %ebx, %edi
movq %r13, %rsi
movq %r14, %rdx
movq %r12, %rcx
movq -0x30(%rbp), %r12
movq %r12, %r8
callq 0xa6c7c
movq %rax, %rbx
xorl %esi, %esi
testq %rax, %rax
cmovneq %rsi, %r14
cmpq $-0x1, %rax
cmovneq %rax, %rsi
testb $0x6, %r12b
cmovneq %r14, %rsi
leaq 0x345541(%rip), %rax # 0x38f258
movq (%rax), %rax
movq %r15, %rdi
callq *0x218(%rax)
jmp 0x49ca6
|
_ma_nommap_pread:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 58h
mov [rbp+var_30], r8
mov r12, rcx
mov r14, rdx
mov r13, rsi
mov ebx, [rdi+480h]
lea rax, PSI_server
mov rax, [rax]
lea rdi, [rbp+var_78]
mov esi, ebx
mov edx, 6
call qword ptr [rax+158h]
test rax, rax
jnz short loc_49CB8
mov edi, ebx
mov rsi, r13
mov rdx, r14
mov rcx, r12
mov r8, [rbp+var_30]
call my_pread
mov rbx, rax
loc_49CA6:
mov rax, rbx
add rsp, 58h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_49CB8:
mov r15, rax
lea rax, PSI_server
mov rax, [rax]
lea rdx, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, r15
mov rsi, r14
mov ecx, 0A2h
call qword ptr [rax+210h]
mov edi, ebx
mov rsi, r13
mov rdx, r14
mov rcx, r12
mov r12, [rbp+var_30]
mov r8, r12
call my_pread
mov rbx, rax
xor esi, esi
test rax, rax
cmovnz r14, rsi
cmp rax, 0FFFFFFFFFFFFFFFFh
cmovnz rsi, rax
test r12b, 6
cmovnz rsi, r14
lea rax, PSI_server
mov rax, [rax]
mov rdi, r15
call qword ptr [rax+218h]
jmp short loc_49CA6
|
long long ma_nommap_pread(long long a1, long long a2, long long a3, long long a4, long long a5)
{
unsigned int v7; // ebx
long long v8; // rax
long long v9; // rbx
long long v11; // r15
_BYTE v12[72]; // [rsp+8h] [rbp-78h] BYREF
long long v13; // [rsp+50h] [rbp-30h]
v13 = a5;
v7 = *(_DWORD *)(a1 + 1152);
v8 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v12, v7, 6LL);
if ( !v8 )
return my_pread(v7, a2, a3, a4, v13);
v11 = v8;
((void ( *)(long long, long long, const char *, long long))PSI_server[66])(
v8,
a3,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_dynrec.c",
162LL);
v9 = my_pread(v7, a2, a3, a4, v13);
((void ( *)(long long))PSI_server[67])(v11);
return v9;
}
|
_ma_nommap_pread:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x58
MOV qword ptr [RBP + -0x30],R8
MOV R12,RCX
MOV R14,RDX
MOV R13,RSI
MOV EBX,dword ptr [RDI + 0x480]
LEA RAX,[0x48f258]
MOV RAX,qword ptr [RAX]
LEA RDI,[RBP + -0x78]
MOV ESI,EBX
MOV EDX,0x6
CALL qword ptr [RAX + 0x158]
TEST RAX,RAX
JNZ 0x00149cb8
MOV EDI,EBX
MOV RSI,R13
MOV RDX,R14
MOV RCX,R12
MOV R8,qword ptr [RBP + -0x30]
CALL 0x001a6c7c
MOV RBX,RAX
LAB_00149ca6:
MOV RAX,RBX
ADD RSP,0x58
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00149cb8:
MOV R15,RAX
LEA RAX,[0x48f258]
MOV RAX,qword ptr [RAX]
LEA RDX,[0x1e1d76]
MOV RDI,R15
MOV RSI,R14
MOV ECX,0xa2
CALL qword ptr [RAX + 0x210]
MOV EDI,EBX
MOV RSI,R13
MOV RDX,R14
MOV RCX,R12
MOV R12,qword ptr [RBP + -0x30]
MOV R8,R12
CALL 0x001a6c7c
MOV RBX,RAX
XOR ESI,ESI
TEST RAX,RAX
CMOVNZ R14,RSI
CMP RAX,-0x1
CMOVNZ RSI,RAX
TEST R12B,0x6
CMOVNZ RSI,R14
LEA RAX,[0x48f258]
MOV RAX,qword ptr [RAX]
MOV RDI,R15
CALL qword ptr [RAX + 0x218]
JMP 0x00149ca6
|
long _ma_nommap_pread(long param_1,int8 param_2,long param_3,int8 param_4,ulong param_5)
{
int4 uVar1;
ulong uVar2;
long lVar3;
long lVar4;
long lVar5;
int1 local_80 [72];
ulong local_38;
uVar1 = *(int4 *)(param_1 + 0x480);
local_38 = param_5;
lVar3 = (**(code **)(PSI_server + 0x158))(local_80,uVar1,6);
if (lVar3 == 0) {
lVar4 = my_pread(uVar1,param_2,param_3,param_4,local_38);
}
else {
(**(code **)(PSI_server + 0x210))
(lVar3,param_3,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_dynrec.c",
0xa2);
uVar2 = local_38;
lVar4 = my_pread(uVar1,param_2,param_3,param_4,local_38);
if (lVar4 != 0) {
param_3 = 0;
}
lVar5 = 0;
if (lVar4 != -1) {
lVar5 = lVar4;
}
if ((uVar2 & 6) != 0) {
lVar5 = param_3;
}
(**(code **)(PSI_server + 0x218))(lVar3,lVar5);
}
return lVar4;
}
|
|
64,871 |
inline_mysql_file_tell
|
eloqsql/include/mysql/psi/mysql_file.h
|
static inline my_off_t
inline_mysql_file_tell(
#ifdef HAVE_PSI_FILE_INTERFACE
const char *src_file, uint src_line,
#endif
File file, myf flags)
{
my_off_t result;
#ifdef HAVE_PSI_FILE_INTERFACE
struct PSI_file_locker *locker;
PSI_file_locker_state state;
locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_TELL);
if (psi_likely(locker != NULL))
{
PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line);
result= my_tell(file, flags);
PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0);
return result;
}
#endif
result= my_tell(file, flags);
return result;
}
|
O0
|
c
|
inline_mysql_file_tell:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
leaq 0x1e8d30(%rip), %rax # 0x2cdee0
movq (%rax), %rax
movq 0x158(%rax), %rax
movl -0x18(%rbp), %esi
leaq -0x78(%rbp), %rdi
movl $0x9, %edx
callq *%rax
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
setne %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0xe5241
leaq 0x1e8ced(%rip), %rax # 0x2cdee0
movq (%rax), %rax
movq 0x210(%rax), %rax
movq -0x30(%rbp), %rdi
movq -0x10(%rbp), %rdx
movl -0x14(%rbp), %ecx
xorl %esi, %esi
callq *%rax
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
callq 0xfd6d0
movq %rax, -0x28(%rbp)
leaq 0x1e8cbd(%rip), %rax # 0x2cdee0
movq (%rax), %rax
movq 0x218(%rax), %rax
movq -0x30(%rbp), %rdi
xorl %ecx, %ecx
movl %ecx, %esi
callq *%rax
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0xe5259
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
callq 0xfd6d0
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x80, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
inline_mysql_file_tell_0:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov [rbp+var_20], rcx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+158h]
mov esi, [rbp+var_18]
lea rdi, [rbp+var_78]
mov edx, 9
call rax
mov [rbp+var_30], rax
cmp [rbp+var_30], 0
setnz al
and al, 1
movzx eax, al
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_E5241
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+210h]
mov rdi, [rbp+var_30]
mov rdx, [rbp+var_10]
mov ecx, [rbp+var_14]
xor esi, esi
call rax
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
call my_tell
mov [rbp+var_28], rax
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+218h]
mov rdi, [rbp+var_30]
xor ecx, ecx
mov esi, ecx
call rax
mov rax, [rbp+var_28]
mov [rbp+var_8], rax
jmp short loc_E5259
loc_E5241:
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
call my_tell
mov [rbp+var_28], rax
mov rax, [rbp+var_28]
mov [rbp+var_8], rax
loc_E5259:
mov rax, [rbp+var_8]
add rsp, 80h
pop rbp
retn
|
long long inline_mysql_file_tell_0(long long a1, unsigned int a2, unsigned int a3, long long a4)
{
_BYTE v5[72]; // [rsp+8h] [rbp-78h] BYREF
long long v6; // [rsp+50h] [rbp-30h]
long long v7; // [rsp+58h] [rbp-28h]
long long v8; // [rsp+60h] [rbp-20h]
unsigned int v9; // [rsp+68h] [rbp-18h]
unsigned int v10; // [rsp+6Ch] [rbp-14h]
long long v11; // [rsp+70h] [rbp-10h]
v11 = a1;
v10 = a2;
v9 = a3;
v8 = a4;
v6 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v5, a3, 9LL);
if ( !v6 )
return my_tell(v9, v8);
((void ( *)(long long, _QWORD, long long, _QWORD))PSI_server[66])(v6, 0LL, v11, v10);
v7 = my_tell(v9, v8);
((void ( *)(long long, _QWORD))PSI_server[67])(v6, 0LL);
return v7;
}
|
inline_mysql_file_tell:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV dword ptr [RBP + -0x18],EDX
MOV qword ptr [RBP + -0x20],RCX
LEA RAX,[0x3cdee0]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x158]
MOV ESI,dword ptr [RBP + -0x18]
LEA RDI,[RBP + -0x78]
MOV EDX,0x9
CALL RAX
MOV qword ptr [RBP + -0x30],RAX
CMP qword ptr [RBP + -0x30],0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x001e5241
LEA RAX,[0x3cdee0]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x210]
MOV RDI,qword ptr [RBP + -0x30]
MOV RDX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x14]
XOR ESI,ESI
CALL RAX
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x001fd6d0
MOV qword ptr [RBP + -0x28],RAX
LEA RAX,[0x3cdee0]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x218]
MOV RDI,qword ptr [RBP + -0x30]
XOR ECX,ECX
MOV ESI,ECX
CALL RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001e5259
LAB_001e5241:
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x001fd6d0
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x8],RAX
LAB_001e5259:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x80
POP RBP
RET
|
int8
inline_mysql_file_tell(int8 param_1,int4 param_2,int4 param_3,int8 param_4)
{
int1 local_80 [72];
long local_38;
int8 local_30;
int8 local_28;
int4 local_20;
int4 local_1c;
int8 local_18;
int8 local_10;
local_28 = param_4;
local_20 = param_3;
local_1c = param_2;
local_18 = param_1;
local_38 = (**(code **)(PSI_server + 0x158))(local_80,param_3,9);
if (local_38 == 0) {
local_10 = my_tell(local_20,local_28);
}
else {
(**(code **)(PSI_server + 0x210))(local_38,0,local_18,local_1c);
local_30 = my_tell(local_20,local_28);
(**(code **)(PSI_server + 0x218))(local_38,0);
local_10 = local_30;
}
return local_10;
}
|
|
64,872 |
reset_key_cache_counters
|
eloqsql/mysys/mf_keycache.c
|
int reset_key_cache_counters(const char *name __attribute__((unused)),
KEY_CACHE *keycache,
void *unused __attribute__((unused)))
{
int rc= 0;
if (keycache->key_cache_inited)
{
pthread_mutex_lock(&keycache->op_lock);
rc= keycache->interface_funcs->reset_counters(name,
keycache->keycache_cb);
pthread_mutex_unlock(&keycache->op_lock);
}
return rc;
}
|
O3
|
c
|
reset_key_cache_counters:
cmpb $0x0, 0x48(%rsi)
je 0x9aeb5
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x58(%rsi), %r15
movq %r15, %rdi
callq 0x29200
movq 0x8(%r14), %rsi
movq 0x10(%r14), %rax
movq %rbx, %rdi
callq *0x38(%rax)
movl %eax, %ebx
movq %r15, %rdi
callq 0x291d0
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
xorl %eax, %eax
retq
|
reset_key_cache_counters:
cmp byte ptr [rsi+48h], 0
jz short loc_9AEB5
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov r14, rsi
mov rbx, rdi
lea r15, [rsi+58h]
mov rdi, r15
call _pthread_mutex_lock
mov rsi, [r14+8]
mov rax, [r14+10h]
mov rdi, rbx
call qword ptr [rax+38h]
mov ebx, eax
mov rdi, r15
call _pthread_mutex_unlock
mov eax, ebx
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
loc_9AEB5:
xor eax, eax
retn
|
long long reset_key_cache_counters(long long a1, long long a2)
{
unsigned int v2; // ebx
if ( !*(_BYTE *)(a2 + 72) )
return 0LL;
pthread_mutex_lock(a2 + 88);
v2 = (*(long long ( **)(long long, _QWORD))(*(_QWORD *)(a2 + 16) + 56LL))(a1, *(_QWORD *)(a2 + 8));
pthread_mutex_unlock(a2 + 88);
return v2;
}
|
reset_key_cache_counters:
CMP byte ptr [RSI + 0x48],0x0
JZ 0x0019aeb5
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RSI
MOV RBX,RDI
LEA R15,[RSI + 0x58]
MOV RDI,R15
CALL 0x00129200
MOV RSI,qword ptr [R14 + 0x8]
MOV RAX,qword ptr [R14 + 0x10]
MOV RDI,RBX
CALL qword ptr [RAX + 0x38]
MOV EBX,EAX
MOV RDI,R15
CALL 0x001291d0
MOV EAX,EBX
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_0019aeb5:
XOR EAX,EAX
RET
|
int4 reset_key_cache_counters(int8 param_1,long param_2)
{
int4 uVar1;
if (*(char *)(param_2 + 0x48) != '\0') {
pthread_mutex_lock((pthread_mutex_t *)(param_2 + 0x58));
uVar1 = (**(code **)(*(long *)(param_2 + 0x10) + 0x38))(param_1,*(int8 *)(param_2 + 8));
pthread_mutex_unlock((pthread_mutex_t *)(param_2 + 0x58));
return uVar1;
}
return 0;
}
|
|
64,873 |
JS_ReadArray
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue JS_ReadArray(BCReaderState *s, int tag)
{
JSContext *ctx = s->ctx;
JSValue obj;
uint32_t len, i;
JSValue val;
int ret, prop_flags;
BOOL is_template;
obj = JS_NewArray(ctx);
if (BC_add_object_ref(s, obj))
goto fail;
is_template = (tag == BC_TAG_TEMPLATE_OBJECT);
if (bc_get_leb128(s, &len))
goto fail;
for(i = 0; i < len; i++) {
val = JS_ReadObjectRec(s);
if (JS_IsException(val))
goto fail;
if (is_template)
prop_flags = JS_PROP_ENUMERABLE;
else
prop_flags = JS_PROP_C_W_E;
ret = JS_DefinePropertyValueUint32(ctx, obj, i, val,
prop_flags);
if (ret < 0)
goto fail;
}
if (is_template) {
val = JS_ReadObjectRec(s);
if (JS_IsException(val))
goto fail;
if (!JS_IsUndefined(val)) {
ret = JS_DefinePropertyValue(ctx, obj, JS_ATOM_raw, val, 0);
if (ret < 0)
goto fail;
}
JS_PreventExtensions(ctx, obj);
}
return obj;
fail:
JS_FreeValue(ctx, obj);
return JS_EXCEPTION;
}
|
O0
|
c
|
JS_ReadArray:
subq $0x98, %rsp
movq %rdi, 0x80(%rsp)
movl %esi, 0x7c(%rsp)
movq 0x80(%rsp), %rax
movq (%rax), %rax
movq %rax, 0x70(%rsp)
movq 0x70(%rsp), %rdi
callq 0x2a520
movq %rax, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x60(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x68(%rsp)
movq 0x80(%rsp), %rdi
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
callq 0x7d440
cmpl $0x0, %eax
je 0x7bb5c
jmp 0x7bd12
cmpl $0xb, 0x7c(%rsp)
sete %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, 0x3c(%rsp)
movq 0x80(%rsp), %rdi
leaq 0x5c(%rsp), %rsi
callq 0x7a1e0
cmpl $0x0, %eax
je 0x7bb89
jmp 0x7bd12
movl $0x0, 0x58(%rsp)
movl 0x58(%rsp), %eax
cmpl 0x5c(%rsp), %eax
jae 0x7bc47
movq 0x80(%rsp), %rdi
callq 0x4c0a0
movq %rax, 0x18(%rsp)
movq %rdx, 0x20(%rsp)
movq 0x18(%rsp), %rax
movq %rax, 0x48(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x50(%rsp)
movq 0x48(%rsp), %rdi
movq 0x50(%rsp), %rsi
callq 0x23cc0
cmpl $0x0, %eax
je 0x7bbe3
jmp 0x7bd12
cmpl $0x0, 0x3c(%rsp)
je 0x7bbf4
movl $0x4, 0x40(%rsp)
jmp 0x7bbfc
movl $0x7, 0x40(%rsp)
movq 0x70(%rsp), %rdi
movl 0x58(%rsp), %ecx
movl 0x40(%rsp), %eax
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
movq 0x48(%rsp), %r8
movq 0x50(%rsp), %r9
movl %eax, (%rsp)
callq 0x37370
movl %eax, 0x44(%rsp)
cmpl $0x0, 0x44(%rsp)
jge 0x7bc35
jmp 0x7bd12
jmp 0x7bc37
movl 0x58(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x58(%rsp)
jmp 0x7bb91
cmpl $0x0, 0x3c(%rsp)
je 0x7bcf6
movq 0x80(%rsp), %rdi
callq 0x4c0a0
movq %rax, 0x8(%rsp)
movq %rdx, 0x10(%rsp)
movq 0x8(%rsp), %rax
movq %rax, 0x48(%rsp)
movq 0x10(%rsp), %rax
movq %rax, 0x50(%rsp)
movq 0x48(%rsp), %rdi
movq 0x50(%rsp), %rsi
callq 0x23cc0
cmpl $0x0, %eax
je 0x7bc93
jmp 0x7bd12
movq 0x48(%rsp), %rdi
movq 0x50(%rsp), %rsi
callq 0x2e260
cmpl $0x0, %eax
jne 0x7bce2
movq 0x70(%rsp), %rdi
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
movq 0x48(%rsp), %r8
movq 0x50(%rsp), %r9
movl $0x71, %ecx
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0x371b0
movl %eax, 0x44(%rsp)
cmpl $0x0, 0x44(%rsp)
jge 0x7bce0
jmp 0x7bd12
jmp 0x7bce2
movq 0x70(%rsp), %rdi
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
callq 0x30cb0
movq 0x60(%rsp), %rax
movq %rax, 0x88(%rsp)
movq 0x68(%rsp), %rax
movq %rax, 0x90(%rsp)
jmp 0x7bd3d
movq 0x70(%rsp), %rdi
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
callq 0x23c90
movl $0x0, 0x88(%rsp)
movq $0x6, 0x90(%rsp)
movq 0x88(%rsp), %rax
movq 0x90(%rsp), %rdx
addq $0x98, %rsp
retq
nopw %cs:(%rax,%rax)
|
JS_ReadArray:
sub rsp, 98h
mov [rsp+98h+var_18], rdi
mov [rsp+98h+var_1C], esi
mov rax, [rsp+98h+var_18]
mov rax, [rax]
mov [rsp+98h+var_28], rax
mov rdi, [rsp+98h+var_28]
call JS_NewArray
mov [rsp+98h+var_70], rax
mov [rsp+98h+var_68], rdx
mov rax, [rsp+98h+var_70]
mov [rsp+98h+var_38], rax
mov rax, [rsp+98h+var_68]
mov [rsp+98h+var_30], rax
mov rdi, [rsp+98h+var_18]
mov rsi, [rsp+98h+var_38]
mov rdx, [rsp+98h+var_30]
call BC_add_object_ref
cmp eax, 0
jz short loc_7BB5C
jmp loc_7BD12
loc_7BB5C:
cmp [rsp+98h+var_1C], 0Bh
setz al
and al, 1
movzx eax, al
mov [rsp+98h+var_5C], eax
mov rdi, [rsp+98h+var_18]
lea rsi, [rsp+98h+var_3C]
call bc_get_leb128
cmp eax, 0
jz short loc_7BB89
jmp loc_7BD12
loc_7BB89:
mov [rsp+98h+var_40], 0
loc_7BB91:
mov eax, [rsp+98h+var_40]
cmp eax, [rsp+98h+var_3C]
jnb loc_7BC47
mov rdi, [rsp+98h+var_18]
call JS_ReadObjectRec
mov [rsp+98h+var_80], rax
mov [rsp+98h+var_78], rdx
mov rax, [rsp+98h+var_80]
mov [rsp+98h+var_50], rax
mov rax, [rsp+98h+var_78]
mov [rsp+98h+var_48], rax
mov rdi, [rsp+98h+var_50]
mov rsi, [rsp+98h+var_48]
call JS_IsException_1
cmp eax, 0
jz short loc_7BBE3
jmp loc_7BD12
loc_7BBE3:
cmp [rsp+98h+var_5C], 0
jz short loc_7BBF4
mov [rsp+98h+var_58], 4
jmp short loc_7BBFC
loc_7BBF4:
mov [rsp+98h+var_58], 7
loc_7BBFC:
mov rdi, [rsp+98h+var_28]
mov ecx, [rsp+98h+var_40]
mov eax, [rsp+98h+var_58]
mov rsi, [rsp+98h+var_38]
mov rdx, [rsp+98h+var_30]
mov r8, [rsp+98h+var_50]
mov r9, [rsp+98h+var_48]
mov [rsp+98h+var_98], eax
call JS_DefinePropertyValueUint32
mov [rsp+98h+var_54], eax
cmp [rsp+98h+var_54], 0
jge short loc_7BC35
jmp loc_7BD12
loc_7BC35:
jmp short $+2
loc_7BC37:
mov eax, [rsp+98h+var_40]
add eax, 1
mov [rsp+98h+var_40], eax
jmp loc_7BB91
loc_7BC47:
cmp [rsp+98h+var_5C], 0
jz loc_7BCF6
mov rdi, [rsp+98h+var_18]
call JS_ReadObjectRec
mov [rsp+98h+var_90], rax
mov [rsp+98h+var_88], rdx
mov rax, [rsp+98h+var_90]
mov [rsp+98h+var_50], rax
mov rax, [rsp+98h+var_88]
mov [rsp+98h+var_48], rax
mov rdi, [rsp+98h+var_50]
mov rsi, [rsp+98h+var_48]
call JS_IsException_1
cmp eax, 0
jz short loc_7BC93
jmp short loc_7BD12
loc_7BC93:
mov rdi, [rsp+98h+var_50]
mov rsi, [rsp+98h+var_48]
call JS_IsUndefined_0
cmp eax, 0
jnz short loc_7BCE2
mov rdi, [rsp+98h+var_28]
mov rsi, [rsp+98h+var_38]
mov rdx, [rsp+98h+var_30]
mov r8, [rsp+98h+var_50]
mov r9, [rsp+98h+var_48]
mov ecx, 71h ; 'q'
xor eax, eax
mov [rsp+98h+var_98], 0
call JS_DefinePropertyValue
mov [rsp+98h+var_54], eax
cmp [rsp+98h+var_54], 0
jge short loc_7BCE0
jmp short loc_7BD12
loc_7BCE0:
jmp short $+2
loc_7BCE2:
mov rdi, [rsp+98h+var_28]
mov rsi, [rsp+98h+var_38]
mov rdx, [rsp+98h+var_30]
call JS_PreventExtensions
loc_7BCF6:
mov rax, [rsp+98h+var_38]
mov [rsp+98h+var_10], rax
mov rax, [rsp+98h+var_30]
mov [rsp+98h+var_8], rax
jmp short loc_7BD3D
loc_7BD12:
mov rdi, [rsp+98h+var_28]
mov rsi, [rsp+98h+var_38]
mov rdx, [rsp+98h+var_30]
call JS_FreeValue
mov dword ptr [rsp+98h+var_10], 0
mov [rsp+98h+var_8], 6
loc_7BD3D:
mov rax, [rsp+98h+var_10]
mov rdx, [rsp+98h+var_8]
add rsp, 98h
retn
|
long long JS_ReadArray(
long long *a1,
int a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
double a7,
double a8,
__m128 a9,
__m128 a10)
{
long long v10; // rdx
double v11; // xmm4_8
double v12; // xmm5_8
long long v13; // rdx
double v14; // xmm4_8
double v15; // xmm5_8
int v16; // eax
long long v17; // rdx
__m128 v18; // xmm4
__m128 v19; // xmm5
_DWORD *v21; // [rsp+8h] [rbp-90h]
_DWORD *ObjectRec; // [rsp+18h] [rbp-80h]
BOOL v23; // [rsp+3Ch] [rbp-5Ch]
long long v24; // [rsp+50h] [rbp-48h]
long long v25; // [rsp+50h] [rbp-48h]
unsigned int i; // [rsp+58h] [rbp-40h]
unsigned int v27; // [rsp+5Ch] [rbp-3Ch] BYREF
long long v28; // [rsp+60h] [rbp-38h]
long long v29; // [rsp+68h] [rbp-30h]
long long v30; // [rsp+70h] [rbp-28h]
int v31; // [rsp+7Ch] [rbp-1Ch]
long long *v32; // [rsp+80h] [rbp-18h]
long long v33; // [rsp+88h] [rbp-10h]
long long v34; // [rsp+90h] [rbp-8h]
v32 = a1;
v31 = a2;
v30 = *a1;
v28 = JS_NewArray(v30);
v29 = v10;
if ( (unsigned int)BC_add_object_ref(a1, v28, v10) )
goto LABEL_17;
v23 = v31 == 11;
if ( (unsigned int)bc_get_leb128((long long)v32, &v27) )
goto LABEL_17;
for ( i = 0; i < v27; ++i )
{
ObjectRec = (_DWORD *)JS_ReadObjectRec(v32, a3, a4, a5, a6, v11, v12, a9, a10);
v24 = v13;
if ( JS_IsException_1((long long)ObjectRec, v13) )
goto LABEL_17;
v16 = v23
? JS_DefinePropertyValueUint32(v30, v28, v29, i, ObjectRec, v24, a3, a4, a5, a6, v14, v15, a9, a10, 4)
: JS_DefinePropertyValueUint32(v30, v28, v29, i, ObjectRec, v24, a3, a4, a5, a6, v14, v15, a9, a10, 7);
if ( v16 < 0 )
goto LABEL_17;
}
if ( !v23 )
goto LABEL_16;
v21 = (_DWORD *)JS_ReadObjectRec(v32, a3, a4, a5, a6, v11, v12, a9, a10);
v25 = v17;
if ( JS_IsException_1((long long)v21, v17)
|| !JS_IsUndefined_0((long long)v21, v25)
&& (int)JS_DefinePropertyValue(v30, v28, v29, 0x71u, v21, v25, a3, a4, a5, a6, v18, v19, a9, a10, 0) < 0 )
{
LABEL_17:
JS_FreeValue(v30, v28, v29);
LODWORD(v33) = 0;
v34 = 6LL;
return v33;
}
JS_PreventExtensions(v30, v28, v29);
LABEL_16:
v33 = v28;
v34 = v29;
return v33;
}
|
JS_ReadArray:
SUB RSP,0x98
MOV qword ptr [RSP + 0x80],RDI
MOV dword ptr [RSP + 0x7c],ESI
MOV RAX,qword ptr [RSP + 0x80]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0x70],RAX
MOV RDI,qword ptr [RSP + 0x70]
CALL 0x0012a520
MOV qword ptr [RSP + 0x28],RAX
MOV qword ptr [RSP + 0x30],RDX
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x60],RAX
MOV RAX,qword ptr [RSP + 0x30]
MOV qword ptr [RSP + 0x68],RAX
MOV RDI,qword ptr [RSP + 0x80]
MOV RSI,qword ptr [RSP + 0x60]
MOV RDX,qword ptr [RSP + 0x68]
CALL 0x0017d440
CMP EAX,0x0
JZ 0x0017bb5c
JMP 0x0017bd12
LAB_0017bb5c:
CMP dword ptr [RSP + 0x7c],0xb
SETZ AL
AND AL,0x1
MOVZX EAX,AL
MOV dword ptr [RSP + 0x3c],EAX
MOV RDI,qword ptr [RSP + 0x80]
LEA RSI,[RSP + 0x5c]
CALL 0x0017a1e0
CMP EAX,0x0
JZ 0x0017bb89
JMP 0x0017bd12
LAB_0017bb89:
MOV dword ptr [RSP + 0x58],0x0
LAB_0017bb91:
MOV EAX,dword ptr [RSP + 0x58]
CMP EAX,dword ptr [RSP + 0x5c]
JNC 0x0017bc47
MOV RDI,qword ptr [RSP + 0x80]
CALL 0x0014c0a0
MOV qword ptr [RSP + 0x18],RAX
MOV qword ptr [RSP + 0x20],RDX
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP + 0x48],RAX
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RSP + 0x50],RAX
MOV RDI,qword ptr [RSP + 0x48]
MOV RSI,qword ptr [RSP + 0x50]
CALL 0x00123cc0
CMP EAX,0x0
JZ 0x0017bbe3
JMP 0x0017bd12
LAB_0017bbe3:
CMP dword ptr [RSP + 0x3c],0x0
JZ 0x0017bbf4
MOV dword ptr [RSP + 0x40],0x4
JMP 0x0017bbfc
LAB_0017bbf4:
MOV dword ptr [RSP + 0x40],0x7
LAB_0017bbfc:
MOV RDI,qword ptr [RSP + 0x70]
MOV ECX,dword ptr [RSP + 0x58]
MOV EAX,dword ptr [RSP + 0x40]
MOV RSI,qword ptr [RSP + 0x60]
MOV RDX,qword ptr [RSP + 0x68]
MOV R8,qword ptr [RSP + 0x48]
MOV R9,qword ptr [RSP + 0x50]
MOV dword ptr [RSP],EAX
CALL 0x00137370
MOV dword ptr [RSP + 0x44],EAX
CMP dword ptr [RSP + 0x44],0x0
JGE 0x0017bc35
JMP 0x0017bd12
LAB_0017bc35:
JMP 0x0017bc37
LAB_0017bc37:
MOV EAX,dword ptr [RSP + 0x58]
ADD EAX,0x1
MOV dword ptr [RSP + 0x58],EAX
JMP 0x0017bb91
LAB_0017bc47:
CMP dword ptr [RSP + 0x3c],0x0
JZ 0x0017bcf6
MOV RDI,qword ptr [RSP + 0x80]
CALL 0x0014c0a0
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x10],RDX
MOV RAX,qword ptr [RSP + 0x8]
MOV qword ptr [RSP + 0x48],RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x50],RAX
MOV RDI,qword ptr [RSP + 0x48]
MOV RSI,qword ptr [RSP + 0x50]
CALL 0x00123cc0
CMP EAX,0x0
JZ 0x0017bc93
JMP 0x0017bd12
LAB_0017bc93:
MOV RDI,qword ptr [RSP + 0x48]
MOV RSI,qword ptr [RSP + 0x50]
CALL 0x0012e260
CMP EAX,0x0
JNZ 0x0017bce2
MOV RDI,qword ptr [RSP + 0x70]
MOV RSI,qword ptr [RSP + 0x60]
MOV RDX,qword ptr [RSP + 0x68]
MOV R8,qword ptr [RSP + 0x48]
MOV R9,qword ptr [RSP + 0x50]
MOV ECX,0x71
XOR EAX,EAX
MOV dword ptr [RSP],0x0
CALL 0x001371b0
MOV dword ptr [RSP + 0x44],EAX
CMP dword ptr [RSP + 0x44],0x0
JGE 0x0017bce0
JMP 0x0017bd12
LAB_0017bce0:
JMP 0x0017bce2
LAB_0017bce2:
MOV RDI,qword ptr [RSP + 0x70]
MOV RSI,qword ptr [RSP + 0x60]
MOV RDX,qword ptr [RSP + 0x68]
CALL 0x00130cb0
LAB_0017bcf6:
MOV RAX,qword ptr [RSP + 0x60]
MOV qword ptr [RSP + 0x88],RAX
MOV RAX,qword ptr [RSP + 0x68]
MOV qword ptr [RSP + 0x90],RAX
JMP 0x0017bd3d
LAB_0017bd12:
MOV RDI,qword ptr [RSP + 0x70]
MOV RSI,qword ptr [RSP + 0x60]
MOV RDX,qword ptr [RSP + 0x68]
CALL 0x00123c90
MOV dword ptr [RSP + 0x88],0x0
MOV qword ptr [RSP + 0x90],0x6
LAB_0017bd3d:
MOV RAX,qword ptr [RSP + 0x88]
MOV RDX,qword ptr [RSP + 0x90]
ADD RSP,0x98
RET
|
int1 [16] JS_ReadArray(int8 *param_1,int param_2)
{
int iVar1;
int8 uVar2;
int8 uVar3;
bool bVar4;
int1 auVar5 [16];
int4 local_58;
uint local_40;
uint local_3c;
int1 local_38 [16];
int8 local_28;
int local_1c;
int8 *local_18;
int4 local_10;
int4 uStack_c;
int8 local_8;
local_28 = *param_1;
local_1c = param_2;
local_18 = param_1;
local_38 = JS_NewArray(local_28);
iVar1 = BC_add_object_ref(local_18,local_38._0_8_,local_38._8_8_);
if (iVar1 == 0) {
bVar4 = local_1c == 0xb;
iVar1 = bc_get_leb128(local_18,&local_3c);
if (iVar1 == 0) {
for (local_40 = 0; local_40 < local_3c; local_40 = local_40 + 1) {
auVar5 = JS_ReadObjectRec(local_18);
iVar1 = JS_IsException(auVar5._0_8_,auVar5._8_8_);
if (iVar1 != 0) goto LAB_0017bd12;
if (bVar4) {
local_58 = 4;
}
else {
local_58 = 7;
}
iVar1 = JS_DefinePropertyValueUint32
(local_28,local_38._0_8_,local_38._8_8_,local_40,auVar5._0_8_,auVar5._8_8_
,local_58);
if (iVar1 < 0) goto LAB_0017bd12;
}
if (bVar4) {
auVar5 = JS_ReadObjectRec(local_18);
uVar3 = auVar5._8_8_;
uVar2 = auVar5._0_8_;
iVar1 = JS_IsException(uVar2,uVar3);
if (iVar1 != 0) goto LAB_0017bd12;
iVar1 = JS_IsUndefined(uVar2,uVar3);
if (iVar1 == 0) {
iVar1 = JS_DefinePropertyValue(local_28,local_38._0_8_,local_38._8_8_,0x71,uVar2,uVar3,0);
if (iVar1 < 0) goto LAB_0017bd12;
}
JS_PreventExtensions(local_28,local_38._0_8_,local_38._8_8_);
}
local_10 = local_38._0_4_;
uStack_c = local_38._4_4_;
local_8 = local_38._8_8_;
goto LAB_0017bd3d;
}
}
LAB_0017bd12:
JS_FreeValue(local_28,local_38._0_8_,local_38._8_8_);
local_10 = 0;
local_8 = 6;
LAB_0017bd3d:
auVar5._4_4_ = uStack_c;
auVar5._0_4_ = local_10;
auVar5._8_8_ = local_8;
return auVar5;
}
|
|
64,874 |
JS_ReadArray
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue JS_ReadArray(BCReaderState *s, int tag)
{
JSContext *ctx = s->ctx;
JSValue obj;
uint32_t len, i;
JSValue val;
int ret, prop_flags;
BOOL is_template;
obj = JS_NewArray(ctx);
if (BC_add_object_ref(s, obj))
goto fail;
is_template = (tag == BC_TAG_TEMPLATE_OBJECT);
if (bc_get_leb128(s, &len))
goto fail;
for(i = 0; i < len; i++) {
val = JS_ReadObjectRec(s);
if (JS_IsException(val))
goto fail;
if (is_template)
prop_flags = JS_PROP_ENUMERABLE;
else
prop_flags = JS_PROP_C_W_E;
ret = JS_DefinePropertyValueUint32(ctx, obj, i, val,
prop_flags);
if (ret < 0)
goto fail;
}
if (is_template) {
val = JS_ReadObjectRec(s);
if (JS_IsException(val))
goto fail;
if (!JS_IsUndefined(val)) {
ret = JS_DefinePropertyValue(ctx, obj, JS_ATOM_raw, val, 0);
if (ret < 0)
goto fail;
}
JS_PreventExtensions(ctx, obj);
}
return obj;
fail:
JS_FreeValue(ctx, obj);
return JS_EXCEPTION;
}
|
O1
|
c
|
JS_ReadArray:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %esi, 0x1c(%rsp)
movq %rdi, %r12
movq (%rdi), %r15
movq 0x38(%r15), %rsi
incl (%rsi)
pushq $0x2
popq %rdx
movq %r15, %rdi
callq 0xf516
movq %rax, %r14
movq %rdx, %rbx
movq %r12, %rdi
movq %rax, %rsi
callq 0x47091
testl %eax, %eax
jne 0x11301
leaq 0x24(%rsp), %rsi
movq %r12, %rdi
callq 0x45a75
testl %eax, %eax
je 0x1132b
movq 0x18(%r15), %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x1d8c6
pushq $0x6
popq %rbx
xorl %r14d, %r14d
movq %r14, %rax
movq %rbx, %rdx
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl 0x24(%rsp), %ebp
testq %rbp, %rbp
je 0x113ae
xorl %eax, %eax
cmpl $0xb, 0x1c(%rsp)
setne %al
leal (%rax,%rax,2), %eax
addl $0x4, %eax
movl %eax, 0x20(%rsp)
xorl %r13d, %r13d
movq %r12, %rdi
callq 0x32909
cmpl $0x6, %edx
je 0x11301
movq %rax, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
movslq %r13d, %rax
movq %rax, %r8
shrq $0x1f, %r8
testl %eax, %eax
movl %eax, %eax
cvtsi2sd %rax, %xmm0
movq %xmm0, %rcx
cmovnsq %r13, %rcx
andl $0x7, %r8d
movups 0x28(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movl 0x20(%rsp), %r9d
callq 0x26b2d
testl %eax, %eax
js 0x11301
incq %r13
cmpq %r13, %rbp
jne 0x1134b
cmpl $0xb, 0x1c(%rsp)
jne 0x11316
movq %r12, %rdi
callq 0x32909
movq %rdx, %r9
cmpl $0x6, %r9d
je 0x11301
cmpl $0x3, %r9d
je 0x113f4
andl $0x0, (%rsp)
pushq $0x71
popq %rcx
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movq %rax, %r8
callq 0x26abb
testl %eax, %eax
js 0x11301
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0xf726
jmp 0x11316
|
JS_ReadArray:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov [rsp+68h+var_4C], esi
mov r12, rdi
mov r15, [rdi]
mov rsi, [r15+38h]
inc dword ptr [rsi]
push 2
pop rdx
mov rdi, r15
call JS_NewObjectFromShape
mov r14, rax
mov rbx, rdx
mov rdi, r12
mov rsi, rax
call BC_add_object_ref1
test eax, eax
jnz short loc_11301
lea rsi, [rsp+68h+var_44]
mov rdi, r12
call bc_get_leb128
test eax, eax
jz short loc_1132B
loc_11301:
mov rdi, [r15+18h]
mov rsi, r14
mov rdx, rbx
call JS_FreeValueRT
push 6
pop rbx
xor r14d, r14d
loc_11316:
mov rax, r14
mov rdx, rbx
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_1132B:
mov ebp, [rsp+68h+var_44]
test rbp, rbp
jz short loc_113AE
xor eax, eax
cmp [rsp+68h+var_4C], 0Bh
setnz al
lea eax, [rax+rax*2]
add eax, 4
mov [rsp+68h+var_48], eax
xor r13d, r13d
loc_1134B:
mov rdi, r12
call JS_ReadObjectRec
cmp edx, 6
jz short loc_11301
mov qword ptr [rsp+68h+var_40], rax
mov qword ptr [rsp+68h+var_40+8], rdx
movsxd rax, r13d
mov r8, rax
shr r8, 1Fh
test eax, eax
mov eax, eax
cvtsi2sd xmm0, rax
movq rcx, xmm0
cmovns rcx, r13
and r8d, 7
movups xmm0, [rsp+68h+var_40]
movups [rsp+68h+var_68], xmm0
mov rdi, r15
mov rsi, r14
mov rdx, rbx
mov r9d, [rsp+68h+var_48]
call JS_DefinePropertyValueValue
test eax, eax
js loc_11301
inc r13
cmp rbp, r13
jnz short loc_1134B
loc_113AE:
cmp [rsp+68h+var_4C], 0Bh
jnz loc_11316
mov rdi, r12
call JS_ReadObjectRec
mov r9, rdx
cmp r9d, 6
jz loc_11301
cmp r9d, 3
jz short loc_113F4
and dword ptr [rsp+68h+var_68], 0
push 71h ; 'q'
pop rcx
mov rdi, r15
mov rsi, r14
mov rdx, rbx
mov r8, rax
call JS_DefinePropertyValue
test eax, eax
js loc_11301
loc_113F4:
mov rdi, r15
mov rsi, r14
mov rdx, rbx
call JS_PreventExtensions
jmp loc_11316
|
long long JS_ReadArray(long long *a1, int a2)
{
long long v2; // r15
_DWORD *v3; // rsi
long long v4; // r14
int v5; // edx
int v6; // ebx
long long v8; // rbp
long long v9; // r13
__int128 v10; // rax
double v11; // rcx
int ObjectRec; // eax
int v13; // edx
unsigned int v15; // [rsp+24h] [rbp-44h] BYREF
__int128 v16; // [rsp+28h] [rbp-40h]
v2 = *a1;
v3 = *(_DWORD **)(*a1 + 56);
++*v3;
v4 = JS_NewObjectFromShape(v2, v3, 2u);
v6 = v5;
if ( !(unsigned int)BC_add_object_ref1(a1, v4) && !(unsigned int)bc_get_leb128(a1, &v15) )
{
v8 = v15;
if ( v15 )
{
v9 = 0LL;
while ( 1 )
{
*(_QWORD *)&v10 = JS_ReadObjectRec(a1);
if ( DWORD2(v10) == 6 )
break;
v16 = v10;
v11 = (double)(int)v9;
if ( (int)v9 >= 0 )
LODWORD(v11) = v9;
if ( (int)JS_DefinePropertyValueValue(
v2,
v4,
v6,
LODWORD(v11),
((unsigned long long)(int)v9 >> 31) & 7,
3 * (unsigned int)(a2 != 11) + 4,
v16,
*((long long *)&v16 + 1)) < 0 )
break;
if ( v8 == ++v9 )
goto LABEL_12;
}
}
else
{
LABEL_12:
if ( a2 != 11 )
return v4;
ObjectRec = JS_ReadObjectRec(a1);
if ( v13 != 6 && (v13 == 3 || (int)JS_DefinePropertyValue(v2, v4, v6, 113, ObjectRec, v13, 0) >= 0) )
{
JS_PreventExtensions(v2, v4, v6);
return v4;
}
}
}
JS_FreeValueRT(*(_QWORD *)(v2 + 24), v4);
return 0LL;
}
| |||
64,875 |
ftxui::(anonymous namespace)::DBox::ComputeRequirement()
|
Andrewchistyakov[P]flashcards_lyc/build_O3/_deps/ftxui-src/src/ftxui/dom/dbox.cpp
|
void ComputeRequirement() override {
requirement_.min_x = 0;
requirement_.min_y = 0;
requirement_.flex_grow_x = 0;
requirement_.flex_grow_y = 0;
requirement_.flex_shrink_x = 0;
requirement_.flex_shrink_y = 0;
requirement_.selection = Requirement::NORMAL;
for (auto& child : children_) {
child->ComputeRequirement();
requirement_.min_x =
std::max(requirement_.min_x, child->requirement().min_x);
requirement_.min_y =
std::max(requirement_.min_y, child->requirement().min_y);
if (requirement_.selection < child->requirement().selection) {
requirement_.selection = child->requirement().selection;
requirement_.selected_box = child->requirement().selected_box;
}
}
}
|
O3
|
cpp
|
ftxui::(anonymous namespace)::DBox::ComputeRequirement():
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
xorps %xmm0, %xmm0
movups %xmm0, 0x2c(%rdi)
movups %xmm0, 0x20(%rdi)
movq 0x8(%rdi), %r14
movq 0x10(%rdi), %r15
cmpq %r15, %r14
je 0x37794
movq %rdi, %rbx
leaq 0x3c(%rdi), %r12
movq (%r14), %rdi
movq (%rdi), %rax
callq *0x10(%rax)
movq (%r14), %rax
movl 0x20(%rax), %ecx
movl 0x20(%rbx), %edx
movl 0x24(%rbx), %esi
cmpl %ecx, %edx
cmovgl %edx, %ecx
movl %ecx, 0x20(%rbx)
movl 0x24(%rax), %ecx
cmpl %ecx, %esi
cmovgl %esi, %ecx
movl %ecx, 0x24(%rbx)
movl 0x38(%rax), %ecx
cmpl %ecx, 0x38(%rbx)
jge 0x3778b
movl %ecx, 0x38(%rbx)
movups 0x3c(%rax), %xmm0
movups %xmm0, (%r12)
addq $0x10, %r14
cmpq %r15, %r14
jne 0x3774f
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
|
_ZN5ftxui12_GLOBAL__N_14DBox18ComputeRequirementEv:
push r15
push r14
push r12
push rbx
push rax
xorps xmm0, xmm0
movups xmmword ptr [rdi+2Ch], xmm0
movups xmmword ptr [rdi+20h], xmm0
mov r14, [rdi+8]
mov r15, [rdi+10h]
cmp r14, r15
jz short loc_37794
mov rbx, rdi
lea r12, [rdi+3Ch]
loc_3774F:
mov rdi, [r14]
mov rax, [rdi]
call qword ptr [rax+10h]
mov rax, [r14]
mov ecx, [rax+20h]
mov edx, [rbx+20h]
mov esi, [rbx+24h]
cmp edx, ecx
cmovg ecx, edx
mov [rbx+20h], ecx
mov ecx, [rax+24h]
cmp esi, ecx
cmovg ecx, esi
mov [rbx+24h], ecx
mov ecx, [rax+38h]
cmp [rbx+38h], ecx
jge short loc_3778B
mov [rbx+38h], ecx
movups xmm0, xmmword ptr [rax+3Ch]
movups xmmword ptr [r12], xmm0
loc_3778B:
add r14, 10h
cmp r14, r15
jnz short loc_3774F
loc_37794:
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
|
long long ftxui::`anonymous namespace'::DBox::ComputeRequirement(ftxui::_anonymous_namespace_::DBox *this)
{
long long result; // rax
_QWORD *v2; // r14
_QWORD *i; // r15
int v4; // ecx
int v5; // esi
int v6; // ecx
int v7; // ecx
*(_OWORD *)((char *)this + 44) = 0LL;
*((_OWORD *)this + 2) = 0LL;
v2 = (_QWORD *)*((_QWORD *)this + 1);
for ( i = (_QWORD *)*((_QWORD *)this + 2); v2 != i; v2 += 2 )
{
(*(void ( **)(_QWORD))(*(_QWORD *)*v2 + 16LL))(*v2);
result = *v2;
v4 = *(_DWORD *)(*v2 + 32LL);
v5 = *((_DWORD *)this + 9);
if ( *((_DWORD *)this + 8) > v4 )
v4 = *((_DWORD *)this + 8);
*((_DWORD *)this + 8) = v4;
v6 = *(_DWORD *)(result + 36);
if ( v5 > v6 )
v6 = v5;
*((_DWORD *)this + 9) = v6;
v7 = *(_DWORD *)(result + 56);
if ( *((_DWORD *)this + 14) < v7 )
{
*((_DWORD *)this + 14) = v7;
*(_OWORD *)((char *)this + 60) = *(_OWORD *)(result + 60);
}
}
return result;
}
|
ComputeRequirement:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI + 0x2c],XMM0
MOVUPS xmmword ptr [RDI + 0x20],XMM0
MOV R14,qword ptr [RDI + 0x8]
MOV R15,qword ptr [RDI + 0x10]
CMP R14,R15
JZ 0x00137794
MOV RBX,RDI
LEA R12,[RDI + 0x3c]
LAB_0013774f:
MOV RDI,qword ptr [R14]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x10]
MOV RAX,qword ptr [R14]
MOV ECX,dword ptr [RAX + 0x20]
MOV EDX,dword ptr [RBX + 0x20]
MOV ESI,dword ptr [RBX + 0x24]
CMP EDX,ECX
CMOVG ECX,EDX
MOV dword ptr [RBX + 0x20],ECX
MOV ECX,dword ptr [RAX + 0x24]
CMP ESI,ECX
CMOVG ECX,ESI
MOV dword ptr [RBX + 0x24],ECX
MOV ECX,dword ptr [RAX + 0x38]
CMP dword ptr [RBX + 0x38],ECX
JGE 0x0013778b
MOV dword ptr [RBX + 0x38],ECX
MOVUPS XMM0,xmmword ptr [RAX + 0x3c]
MOVUPS xmmword ptr [R12],XMM0
LAB_0013778b:
ADD R14,0x10
CMP R14,R15
JNZ 0x0013774f
LAB_00137794:
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
|
/* ftxui::(anonymous namespace)::DBox::ComputeRequirement() */
void __thiscall ftxui::(anonymous_namespace)::DBox::ComputeRequirement(DBox *this)
{
long *plVar1;
long lVar2;
int4 uVar3;
int4 uVar4;
int4 uVar5;
int iVar6;
long *plVar7;
*(int8 *)(this + 0x2c) = 0;
*(int8 *)(this + 0x34) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
plVar7 = *(long **)(this + 8);
plVar1 = *(long **)(this + 0x10);
if (plVar7 != plVar1) {
do {
(**(code **)(*(long *)*plVar7 + 0x10))();
lVar2 = *plVar7;
iVar6 = *(int *)(lVar2 + 0x20);
if (*(int *)(lVar2 + 0x20) < *(int *)(this + 0x20)) {
iVar6 = *(int *)(this + 0x20);
}
*(int *)(this + 0x20) = iVar6;
iVar6 = *(int *)(lVar2 + 0x24);
if (*(int *)(lVar2 + 0x24) < *(int *)(this + 0x24)) {
iVar6 = *(int *)(this + 0x24);
}
*(int *)(this + 0x24) = iVar6;
if (*(int *)(this + 0x38) < *(int *)(lVar2 + 0x38)) {
*(int *)(this + 0x38) = *(int *)(lVar2 + 0x38);
uVar3 = *(int4 *)(lVar2 + 0x40);
uVar4 = *(int4 *)(lVar2 + 0x44);
uVar5 = *(int4 *)(lVar2 + 0x48);
*(int4 *)(this + 0x3c) = *(int4 *)(lVar2 + 0x3c);
*(int4 *)(this + 0x40) = uVar3;
*(int4 *)(this + 0x44) = uVar4;
*(int4 *)(this + 0x48) = uVar5;
}
plVar7 = plVar7 + 2;
} while (plVar7 != plVar1);
}
return;
}
|
|
64,876 |
mi_mark_file_changed
|
eloqsql/storage/myisam/mi_locking.c
|
int _mi_mark_file_changed(MI_INFO *info)
{
uchar buff[3];
register MYISAM_SHARE *share=info->s;
DBUG_ENTER("_mi_mark_file_changed");
if (!(share->state.changed & STATE_CHANGED) || ! share->global_changed)
{
share->state.changed|=(STATE_CHANGED | STATE_NOT_ANALYZED |
STATE_NOT_OPTIMIZED_KEYS);
if (!share->global_changed)
{
share->global_changed=1;
share->state.open_count++;
}
if (!share->temporary)
{
mi_int2store(buff,share->state.open_count);
buff[2]=1; /* Mark that it's changed */
DBUG_RETURN((int)mysql_file_pwrite(share->kfile, buff, sizeof(buff),
sizeof(share->state.header),
MYF(MY_NABP)));
}
}
DBUG_RETURN(0);
}
|
O0
|
c
|
mi_mark_file_changed:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movzbl 0xf0(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xb315b
movq -0x20(%rbp), %rax
cmpb $0x0, 0x380(%rax)
jne 0xb3201
movq -0x20(%rbp), %rax
movzbl 0xf0(%rax), %ecx
orl $0x19, %ecx
movb %cl, 0xf0(%rax)
movq -0x20(%rbp), %rax
cmpb $0x0, 0x380(%rax)
jne 0xb319a
movq -0x20(%rbp), %rax
movb $0x1, 0x380(%rax)
movq -0x20(%rbp), %rax
movl 0xec(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0xec(%rax)
movq -0x20(%rbp), %rax
cmpb $0x0, 0x382(%rax)
jne 0xb31ff
movq -0x20(%rbp), %rax
movl 0xec(%rax), %eax
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movb %al, -0x12(%rbp)
movl -0x24(%rbp), %eax
shrl $0x8, %eax
movb %al, -0x13(%rbp)
movb $0x1, -0x11(%rbp)
movq -0x20(%rbp), %rax
movl 0x350(%rax), %edx
leaq -0x13(%rbp), %rcx
leaq 0xa9fdb(%rip), %rdi # 0x15d1b7
movl $0x26f, %esi # imm = 0x26F
movl $0x3, %r8d
movl $0x18, %r9d
movq $0x4, (%rsp)
callq 0xb3220
movl %eax, -0x4(%rbp)
jmp 0xb320a
jmp 0xb3201
jmp 0xb3203
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
_mi_mark_file_changed:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+0F0h]
and eax, 1
cmp eax, 0
jz short loc_B315B
mov rax, [rbp+var_20]
cmp byte ptr [rax+380h], 0
jnz loc_B3201
loc_B315B:
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+0F0h]
or ecx, 19h
mov [rax+0F0h], cl
mov rax, [rbp+var_20]
cmp byte ptr [rax+380h], 0
jnz short loc_B319A
mov rax, [rbp+var_20]
mov byte ptr [rax+380h], 1
mov rax, [rbp+var_20]
mov ecx, [rax+0ECh]
add ecx, 1
mov [rax+0ECh], ecx
loc_B319A:
mov rax, [rbp+var_20]
cmp byte ptr [rax+382h], 0
jnz short loc_B31FF
mov rax, [rbp+var_20]
mov eax, [rax+0ECh]
mov [rbp+var_24], eax
mov eax, [rbp+var_24]
mov [rbp+var_12], al
mov eax, [rbp+var_24]
shr eax, 8
mov [rbp+var_13], al
mov [rbp+var_11], 1
mov rax, [rbp+var_20]
mov edx, [rax+350h]
lea rcx, [rbp+var_13]
lea rdi, aWorkspaceLlm4b_27; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 26Fh
mov r8d, 3
mov r9d, 18h
mov [rsp+30h+var_30], 4
call inline_mysql_file_pwrite_1
mov [rbp+var_4], eax
jmp short loc_B320A
loc_B31FF:
jmp short $+2
loc_B3201:
jmp short $+2
loc_B3203:
mov [rbp+var_4], 0
loc_B320A:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
|
long long mi_mark_file_changed(long long *a1)
{
__int16 v1; // kr00_2
long long v3; // [rsp+10h] [rbp-20h]
_BYTE v4[3]; // [rsp+1Dh] [rbp-13h] BYREF
long long *v5; // [rsp+20h] [rbp-10h]
v5 = a1;
v3 = *a1;
if ( (*(_BYTE *)(*a1 + 240) & 1) != 0 && *(_BYTE *)(v3 + 896) )
return 0;
*(_BYTE *)(v3 + 240) |= 0x19u;
if ( !*(_BYTE *)(v3 + 896) )
{
*(_BYTE *)(v3 + 896) = 1;
++*(_DWORD *)(v3 + 236);
}
if ( *(_BYTE *)(v3 + 898) )
{
return 0;
}
else
{
v1 = *(_DWORD *)(v3 + 236);
v4[0] = HIBYTE(v1);
v4[1] = v1;
v4[2] = 1;
return (unsigned int)inline_mysql_file_pwrite_1(
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_locking.c",
623,
*(_DWORD *)(v3 + 848),
(unsigned int)v4,
3,
24,
4LL);
}
}
|
_mi_mark_file_changed:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0xf0]
AND EAX,0x1
CMP EAX,0x0
JZ 0x001b315b
MOV RAX,qword ptr [RBP + -0x20]
CMP byte ptr [RAX + 0x380],0x0
JNZ 0x001b3201
LAB_001b315b:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0xf0]
OR ECX,0x19
MOV byte ptr [RAX + 0xf0],CL
MOV RAX,qword ptr [RBP + -0x20]
CMP byte ptr [RAX + 0x380],0x0
JNZ 0x001b319a
MOV RAX,qword ptr [RBP + -0x20]
MOV byte ptr [RAX + 0x380],0x1
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RAX + 0xec]
ADD ECX,0x1
MOV dword ptr [RAX + 0xec],ECX
LAB_001b319a:
MOV RAX,qword ptr [RBP + -0x20]
CMP byte ptr [RAX + 0x382],0x0
JNZ 0x001b31ff
MOV RAX,qword ptr [RBP + -0x20]
MOV EAX,dword ptr [RAX + 0xec]
MOV dword ptr [RBP + -0x24],EAX
MOV EAX,dword ptr [RBP + -0x24]
MOV byte ptr [RBP + -0x12],AL
MOV EAX,dword ptr [RBP + -0x24]
SHR EAX,0x8
MOV byte ptr [RBP + -0x13],AL
MOV byte ptr [RBP + -0x11],0x1
MOV RAX,qword ptr [RBP + -0x20]
MOV EDX,dword ptr [RAX + 0x350]
LEA RCX,[RBP + -0x13]
LEA RDI,[0x25d1b7]
MOV ESI,0x26f
MOV R8D,0x3
MOV R9D,0x18
MOV qword ptr [RSP],0x4
CALL 0x001b3220
MOV dword ptr [RBP + -0x4],EAX
JMP 0x001b320a
LAB_001b31ff:
JMP 0x001b3201
LAB_001b3201:
JMP 0x001b3203
LAB_001b3203:
MOV dword ptr [RBP + -0x4],0x0
LAB_001b320a:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
int4 _mi_mark_file_changed(long *param_1)
{
long lVar1;
int4 uVar2;
int1 local_1b;
int1 local_1a;
int1 local_19;
long *local_18;
lVar1 = *param_1;
if (((*(byte *)(lVar1 + 0xf0) & 1) == 0) || (*(char *)(lVar1 + 0x380) == '\0')) {
*(byte *)(lVar1 + 0xf0) = *(byte *)(lVar1 + 0xf0) | 0x19;
if (*(char *)(lVar1 + 0x380) == '\0') {
*(int1 *)(lVar1 + 0x380) = 1;
*(int *)(lVar1 + 0xec) = *(int *)(lVar1 + 0xec) + 1;
}
if (*(char *)(lVar1 + 0x382) == '\0') {
local_1a = (int1)*(int4 *)(lVar1 + 0xec);
local_1b = (int1)((uint)*(int4 *)(lVar1 + 0xec) >> 8);
local_19 = 1;
local_18 = param_1;
uVar2 = inline_mysql_file_pwrite
("/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_locking.c",
0x26f,*(int4 *)(lVar1 + 0x350),&local_1b,3,0x18,4);
return uVar2;
}
}
return 0;
}
|
|
64,877 |
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::begin()
|
monkey531[P]llama/common/json.hpp
|
iterator begin() noexcept
{
iterator result(this);
result.set_begin();
return result;
}
|
O1
|
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>::begin():
pushq %rbx
movq %rdi, %rbx
movabsq $-0x8000000000000000, %rax # imm = 0x8000000000000000
movq %rsi, (%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rdi)
movq %rax, 0x18(%rdi)
movzbl (%rsi), %ecx
cmpl $0x2, %ecx
je 0x5cf74
cmpl $0x1, %ecx
jne 0x5cf7e
leaq 0x8(%rbx), %rax
movq $0x0, (%rax)
jmp 0x5cf82
movq $0x0, 0x10(%rbx)
jmp 0x5cf82
movq %rax, 0x18(%rbx)
movq %rbx, %rdi
callq 0x5ddf6
movq %rbx, %rax
popq %rbx
retq
nop
|
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5beginEv:
push rbx
mov rbx, rdi
mov rax, 8000000000000000h
mov [rdi], rsi
xorps xmm0, xmm0
movups xmmword ptr [rdi+8], xmm0
mov [rdi+18h], rax
movzx ecx, byte ptr [rsi]
cmp ecx, 2
jz short loc_5CF74
cmp ecx, 1
jnz short loc_5CF7E
lea rax, [rbx+8]
mov qword ptr [rax], 0
jmp short loc_5CF82
loc_5CF74:
mov qword ptr [rbx+10h], 0
jmp short loc_5CF82
loc_5CF7E:
mov [rbx+18h], rax
loc_5CF82:
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE9set_beginEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::set_begin(void)
mov rax, rbx
pop rbx
retn
|
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::begin(
long long a1,
unsigned __int8 *a2)
{
int v2; // ecx
*(_QWORD *)a1 = a2;
*(_OWORD *)(a1 + 8) = 0LL;
*(_QWORD *)(a1 + 24) = 0x8000000000000000LL;
v2 = *a2;
if ( v2 == 2 )
{
*(_QWORD *)(a1 + 16) = 0LL;
}
else if ( v2 == 1 )
{
*(_QWORD *)(a1 + 8) = 0LL;
}
else
{
*(_QWORD *)(a1 + 24) = 0x8000000000000000LL;
}
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::set_begin(a1);
return a1;
}
|
begin:
PUSH RBX
MOV RBX,RDI
MOV RAX,-0x8000000000000000
MOV qword ptr [RDI],RSI
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI + 0x8],XMM0
MOV qword ptr [RDI + 0x18],RAX
MOVZX ECX,byte ptr [RSI]
CMP ECX,0x2
JZ 0x0015cf74
CMP ECX,0x1
JNZ 0x0015cf7e
LEA RAX,[RBX + 0x8]
MOV qword ptr [RAX],0x0
JMP 0x0015cf82
LAB_0015cf74:
MOV qword ptr [RBX + 0x10],0x0
JMP 0x0015cf82
LAB_0015cf7e:
MOV qword ptr [RBX + 0x18],RAX
LAB_0015cf82:
MOV RDI,RBX
CALL 0x0015ddf6
MOV RAX,RBX
POP RBX
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>::begin() */
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>
::begin(void)
{
char *in_RSI;
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>>
*in_RDI;
*(char **)in_RDI = in_RSI;
*(int8 *)(in_RDI + 8) = 0;
*(int8 *)(in_RDI + 0x10) = 0;
*(int8 *)(in_RDI + 0x18) = 0x8000000000000000;
if (*in_RSI == '\x02') {
*(int8 *)(in_RDI + 0x10) = 0;
}
else if (*in_RSI == '\x01') {
*(int8 *)(in_RDI + 8) = 0;
}
else {
*(int8 *)(in_RDI + 0x18) = 0x8000000000000000;
}
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>>
::set_begin(in_RDI);
return;
}
|
|
64,878 |
insert_dynamic
|
eloqsql/mysys/array.c
|
my_bool insert_dynamic(DYNAMIC_ARRAY *array, const void * element)
{
void *buffer;
if (array->elements == array->max_element)
{ /* Call only when necessary */
if (!(buffer=alloc_dynamic(array)))
return TRUE;
}
else
{
buffer=array->buffer+(array->elements * array->size_of_element);
array->elements++;
}
memcpy(buffer,element,(size_t) array->size_of_element);
return FALSE;
}
|
O0
|
c
|
insert_dynamic:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movl 0x8(%rax), %eax
movq -0x10(%rbp), %rcx
cmpl 0xc(%rcx), %eax
jne 0x80e3b
movq -0x10(%rbp), %rdi
callq 0x80e90
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
jne 0x80e39
movb $0x1, -0x1(%rbp)
jmp 0x80e81
jmp 0x80e67
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq -0x10(%rbp), %rcx
movl 0x8(%rcx), %ecx
movq -0x10(%rbp), %rdx
imull 0x14(%rdx), %ecx
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movl 0x8(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x8(%rax)
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x10(%rbp), %rax
movl 0x14(%rax), %eax
movl %eax, %edx
callq 0x360b0
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
|
insert_dynamic:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rax, [rbp+var_10]
mov eax, [rax+8]
mov rcx, [rbp+var_10]
cmp eax, [rcx+0Ch]
jnz short loc_80E3B
mov rdi, [rbp+var_10]
call alloc_dynamic
mov [rbp+var_20], rax
cmp rax, 0
jnz short loc_80E39
mov [rbp+var_1], 1
jmp short loc_80E81
loc_80E39:
jmp short loc_80E67
loc_80E3B:
mov rax, [rbp+var_10]
mov rax, [rax]
mov rcx, [rbp+var_10]
mov ecx, [rcx+8]
mov rdx, [rbp+var_10]
imul ecx, [rdx+14h]
mov ecx, ecx
add rax, rcx
mov [rbp+var_20], rax
mov rax, [rbp+var_10]
mov ecx, [rax+8]
add ecx, 1
mov [rax+8], ecx
loc_80E67:
mov rdi, [rbp+var_20]
mov rsi, [rbp+var_18]
mov rax, [rbp+var_10]
mov eax, [rax+14h]
mov edx, eax
call _memcpy
mov [rbp+var_1], 0
loc_80E81:
mov al, [rbp+var_1]
add rsp, 20h
pop rbp
retn
|
char insert_dynamic(long long a1, long long a2)
{
long long v3; // [rsp+0h] [rbp-20h]
if ( *(_DWORD *)(a1 + 8) != *(_DWORD *)(a1 + 12) )
{
v3 = (unsigned int)(*(_DWORD *)(a1 + 20) * (*(_DWORD *)(a1 + 8))++) + *(_QWORD *)a1;
LABEL_6:
memcpy(v3, a2, *(unsigned int *)(a1 + 20));
return 0;
}
v3 = alloc_dynamic(a1);
if ( v3 )
goto LABEL_6;
return 1;
}
|
insert_dynamic:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x10]
CMP EAX,dword ptr [RCX + 0xc]
JNZ 0x00180e3b
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00180e90
MOV qword ptr [RBP + -0x20],RAX
CMP RAX,0x0
JNZ 0x00180e39
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00180e81
LAB_00180e39:
JMP 0x00180e67
LAB_00180e3b:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RCX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RCX + 0x8]
MOV RDX,qword ptr [RBP + -0x10]
IMUL ECX,dword ptr [RDX + 0x14]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x8]
ADD ECX,0x1
MOV dword ptr [RAX + 0x8],ECX
LAB_00180e67:
MOV RDI,qword ptr [RBP + -0x20]
MOV RSI,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x14]
MOV EDX,EAX
CALL 0x001360b0
MOV byte ptr [RBP + -0x1],0x0
LAB_00180e81:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x20
POP RBP
RET
|
int1 insert_dynamic(long *param_1,void *param_2)
{
void *local_28;
if ((int)param_1[1] == *(int *)((long)param_1 + 0xc)) {
local_28 = (void *)alloc_dynamic(param_1);
if (local_28 == (void *)0x0) {
return 1;
}
}
else {
local_28 = (void *)(*param_1 + (ulong)(uint)((int)param_1[1] * *(int *)((long)param_1 + 0x14)));
*(int *)(param_1 + 1) = (int)param_1[1] + 1;
}
memcpy(local_28,param_2,(ulong)*(uint *)((long)param_1 + 0x14));
return 0;
}
|
|
64,879 |
MNN::CreateQuantizedMatMul(flatbuffers::FlatBufferBuilder&, MNN::QuantizedMatMulT const*, std::__1::function<unsigned long (void*)> const*)
|
mnn-tts/MNN/schema/current/TFQuantizeOp_generated.h
|
inline flatbuffers::Offset<QuantizedMatMul> CreateQuantizedMatMul(flatbuffers::FlatBufferBuilder &_fbb, const QuantizedMatMulT *_o, const flatbuffers::rehasher_function_t *_rehasher) {
(void)_rehasher;
(void)_o;
struct _VectorArgs { flatbuffers::FlatBufferBuilder *__fbb; const QuantizedMatMulT* __o; const flatbuffers::rehasher_function_t *__rehasher; } _va = { &_fbb, _o, _rehasher}; (void)_va;
auto _transposeA = _o->transposeA;
auto _transposeB = _o->transposeB;
return MNN::CreateQuantizedMatMul(
_fbb,
_transposeA,
_transposeB);
}
|
O0
|
c
|
MNN::CreateQuantizedMatMul(flatbuffers::FlatBufferBuilder&, MNN::QuantizedMatMulT const*, std::__1::function<unsigned long (void*)> const*):
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq %rsi, 0x30(%rsp)
movq %rdx, 0x28(%rsp)
movq 0x38(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0x30(%rsp), %rax
movb (%rax), %al
andb $0x1, %al
movb %al, 0xf(%rsp)
movq 0x30(%rsp), %rax
movb 0x1(%rax), %al
andb $0x1, %al
movb %al, 0xe(%rsp)
movq 0x38(%rsp), %rdi
movb 0xf(%rsp), %cl
movb 0xe(%rsp), %al
andb $0x1, %cl
andb $0x1, %al
movzbl %cl, %esi
movzbl %al, %edx
callq 0x50e10
movl %eax, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
|
_ZN3MNN21CreateQuantizedMatMulERN11flatbuffers17FlatBufferBuilderEPKNS_16QuantizedMatMulTEPKNSt3__18functionIFmPvEEE:
sub rsp, 48h
mov [rsp+48h+var_10], rdi
mov [rsp+48h+var_18], rsi
mov [rsp+48h+var_20], rdx
mov rax, [rsp+48h+var_10]
mov [rsp+48h+var_38], rax
mov rax, [rsp+48h+var_18]
mov [rsp+48h+var_30], rax
mov rax, [rsp+48h+var_20]
mov [rsp+48h+var_28], rax
mov rax, [rsp+48h+var_18]
mov al, [rax]
and al, 1
mov [rsp+48h+var_39], al
mov rax, [rsp+48h+var_18]
mov al, [rax+1]
and al, 1
mov [rsp+48h+var_3A], al
mov rdi, [rsp+48h+var_10]; this
mov cl, [rsp+48h+var_39]
mov al, [rsp+48h+var_3A]
and cl, 1; bool
and al, 1
movzx esi, cl; flatbuffers::FlatBufferBuilder *
movzx edx, al; bool
call _ZN3MNN21CreateQuantizedMatMulERN11flatbuffers17FlatBufferBuilderEbb; MNN::CreateQuantizedMatMul(flatbuffers::FlatBufferBuilder &,bool,bool)
mov [rsp+48h+var_4], eax
mov eax, [rsp+48h+var_4]
add rsp, 48h
retn
|
long long MNN::CreateQuantizedMatMul(MNN *a1, _BYTE *a2)
{
return (unsigned int)MNN::CreateQuantizedMatMul(a1, (flatbuffers::FlatBufferBuilder *)(*a2 & 1), a2[1] & 1, *a2 & 1);
}
|
CreateQuantizedMatMul:
SUB RSP,0x48
MOV qword ptr [RSP + 0x38],RDI
MOV qword ptr [RSP + 0x30],RSI
MOV qword ptr [RSP + 0x28],RDX
MOV RAX,qword ptr [RSP + 0x38]
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [RSP + 0x30]
MOV qword ptr [RSP + 0x18],RAX
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x20],RAX
MOV RAX,qword ptr [RSP + 0x30]
MOV AL,byte ptr [RAX]
AND AL,0x1
MOV byte ptr [RSP + 0xf],AL
MOV RAX,qword ptr [RSP + 0x30]
MOV AL,byte ptr [RAX + 0x1]
AND AL,0x1
MOV byte ptr [RSP + 0xe],AL
MOV RDI,qword ptr [RSP + 0x38]
MOV CL,byte ptr [RSP + 0xf]
MOV AL,byte ptr [RSP + 0xe]
AND CL,0x1
AND AL,0x1
MOVZX ESI,CL
MOVZX EDX,AL
CALL 0x00150e10
MOV dword ptr [RSP + 0x44],EAX
MOV EAX,dword ptr [RSP + 0x44]
ADD RSP,0x48
RET
|
/* MNN::CreateQuantizedMatMul(flatbuffers::FlatBufferBuilder&, MNN::QuantizedMatMulT const*,
std::function<unsigned long (void*)> const*) */
int4
MNN::CreateQuantizedMatMul(FlatBufferBuilder *param_1,QuantizedMatMulT *param_2,function *param_3)
{
int4 uVar1;
uVar1 = CreateQuantizedMatMul(param_1,(bool)((byte)*param_2 & 1),(bool)((byte)param_2[1] & 1));
return uVar1;
}
|
|
64,880 |
check_skipped_lsn
|
eloqsql/storage/maria/ma_loghandler.c
|
void check_skipped_lsn(MARIA_HA *info, LSN lsn, my_bool index_file,
pgcache_page_no_t page)
{
if (lsn <= log_descriptor.horizon)
{
DBUG_PRINT("info", ("Page is up to date, skipping redo"));
}
else
{
/* Give error, but don't flood the log */
if (skipped_lsn_err_count++ < MAX_LSN_ERRORS &&
! info->s->redo_error_given++)
{
eprint(tracef, "Table %s has wrong LSN: " LSN_FMT " on page: %llu",
(index_file ? info->s->data_file_name.str :
info->s->index_file_name.str),
LSN_IN_PARTS(lsn), (ulonglong) page);
recovery_found_crashed_tables++;
}
}
}
|
O0
|
c
|
check_skipped_lsn:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movb %dl, %al
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movb %al, -0x11(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x10(%rbp), %rax
cmpq 0xbf8db4(%rip), %rax # 0xc89068
jg 0x902bf
jmp 0x902b8
jmp 0x902ba
jmp 0x9038b
leaq 0xbf937a(%rip), %rax # 0xc89640
movl (%rax), %eax
movl %eax, %edx
addl $0x1, %edx
leaq 0xbf936c(%rip), %rcx # 0xc89640
movl %edx, (%rcx)
cmpl $0xa, %eax
jae 0x90389
movq -0x8(%rbp), %rax
movq (%rax), %rcx
movb 0x7eb(%rcx), %al
movb %al, %dl
addb $0x1, %dl
movb %dl, 0x7eb(%rcx)
cmpb $0x0, %al
jne 0x90389
leaq 0xbf932a(%rip), %rax # 0xc89630
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movsbl -0x11(%rbp), %eax
cmpl $0x0, %eax
je 0x9032a
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq 0x5c0(%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0x9033c
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq 0x5d0(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x28(%rbp), %rdi
movq -0x30(%rbp), %rdx
movq -0x10(%rbp), %rax
sarq $0x20, %rax
movl %eax, %ecx
movabsq $0xffffffff, %rax # imm = 0xFFFFFFFF
andq -0x10(%rbp), %rax
movl %eax, %r8d
movq -0x20(%rbp), %r9
leaq 0xcd219(%rip), %rsi # 0x15d583
movb $0x0, %al
callq 0x9f8f0
leaq 0xbf92c0(%rip), %rax # 0xc89638
movq (%rax), %rcx
addq $0x1, %rcx
leaq 0xbf92b2(%rip), %rax # 0xc89638
movq %rcx, (%rax)
jmp 0x9038b
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
check_skipped_lsn:
push rbp
mov rbp, rsp
sub rsp, 30h
mov al, dl
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_11], al
mov [rbp+var_20], rcx
mov rax, [rbp+var_10]
cmp rax, cs:qword_C89068
jg short loc_902BF
jmp short $+2
loc_902B8:
jmp short $+2
loc_902BA:
jmp loc_9038B
loc_902BF:
lea rax, skipped_lsn_err_count
mov eax, [rax]
mov edx, eax
add edx, 1
lea rcx, skipped_lsn_err_count
mov [rcx], edx
cmp eax, 0Ah
jnb loc_90389
mov rax, [rbp+var_8]
mov rcx, [rax]
mov al, [rcx+7EBh]
mov dl, al
add dl, 1
mov [rcx+7EBh], dl
cmp al, 0
jnz loc_90389
lea rax, tracef
mov rax, [rax]
mov [rbp+var_28], rax
movsx eax, [rbp+var_11]
cmp eax, 0
jz short loc_9032A
mov rax, [rbp+var_8]
mov rax, [rax]
mov rax, [rax+5C0h]
mov [rbp+var_30], rax
jmp short loc_9033C
loc_9032A:
mov rax, [rbp+var_8]
mov rax, [rax]
mov rax, [rax+5D0h]
mov [rbp+var_30], rax
loc_9033C:
mov rdi, [rbp+var_28]
mov rdx, [rbp+var_30]
mov rax, [rbp+var_10]
sar rax, 20h
mov ecx, eax
mov rax, 0FFFFFFFFh
and rax, [rbp+var_10]
mov r8d, eax
mov r9, [rbp+var_20]
lea rsi, aTableSHasWrong; "Table %s has wrong LSN: (%u,0x%x) on pa"...
mov al, 0
call eprint
lea rax, recovery_found_crashed_tables
mov rcx, [rax]
add rcx, 1
lea rax, recovery_found_crashed_tables
mov [rax], rcx
loc_90389:
jmp short $+2
loc_9038B:
add rsp, 30h
pop rbp
retn
|
char check_skipped_lsn(long long a1, long long a2, char a3, int a4)
{
_QWORD *v4; // rax
LOBYTE(v4) = a2;
if ( a2 > qword_C89068 )
{
LODWORD(v4) = skipped_lsn_err_count++;
if ( (unsigned int)v4 < 0xA )
{
LOBYTE(v4) = *(_BYTE *)(*(_QWORD *)a1 + 2027LL);
*(_BYTE *)(*(_QWORD *)a1 + 2027LL) = (_BYTE)v4 + 1;
if ( !(_BYTE)v4 )
{
if ( a3 )
eprint(
tracef,
(unsigned int)"Table %s has wrong LSN: (%u,0x%x) on page: %llu",
*(_QWORD *)(*(_QWORD *)a1 + 1472LL),
HIDWORD(a2),
a2,
a4,
*(_QWORD *)(*(_QWORD *)a1 + 1472LL));
else
eprint(
tracef,
(unsigned int)"Table %s has wrong LSN: (%u,0x%x) on page: %llu",
*(_QWORD *)(*(_QWORD *)a1 + 1488LL),
HIDWORD(a2),
a2,
a4,
*(_QWORD *)(*(_QWORD *)a1 + 1488LL));
v4 = &recovery_found_crashed_tables;
++recovery_found_crashed_tables;
}
}
}
return (char)v4;
}
|
check_skipped_lsn:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV AL,DL
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV byte ptr [RBP + -0x11],AL
MOV qword ptr [RBP + -0x20],RCX
MOV RAX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [0x00d89068]
JG 0x001902bf
JMP 0x001902b8
LAB_001902b8:
JMP 0x001902ba
LAB_001902ba:
JMP 0x0019038b
LAB_001902bf:
LEA RAX,[0xd89640]
MOV EAX,dword ptr [RAX]
MOV EDX,EAX
ADD EDX,0x1
LEA RCX,[0xd89640]
MOV dword ptr [RCX],EDX
CMP EAX,0xa
JNC 0x00190389
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX]
MOV AL,byte ptr [RCX + 0x7eb]
MOV DL,AL
ADD DL,0x1
MOV byte ptr [RCX + 0x7eb],DL
CMP AL,0x0
JNZ 0x00190389
LEA RAX,[0xd89630]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x28],RAX
MOVSX EAX,byte ptr [RBP + -0x11]
CMP EAX,0x0
JZ 0x0019032a
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x5c0]
MOV qword ptr [RBP + -0x30],RAX
JMP 0x0019033c
LAB_0019032a:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x5d0]
MOV qword ptr [RBP + -0x30],RAX
LAB_0019033c:
MOV RDI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x10]
SAR RAX,0x20
MOV ECX,EAX
MOV RAX,0xffffffff
AND RAX,qword ptr [RBP + -0x10]
MOV R8D,EAX
MOV R9,qword ptr [RBP + -0x20]
LEA RSI,[0x25d583]
MOV AL,0x0
CALL 0x0019f8f0
LEA RAX,[0xd89638]
MOV RCX,qword ptr [RAX]
ADD RCX,0x1
LEA RAX,[0xd89638]
MOV qword ptr [RAX],RCX
LAB_00190389:
JMP 0x0019038b
LAB_0019038b:
ADD RSP,0x30
POP RBP
RET
|
void check_skipped_lsn(long *param_1,ulong param_2,char param_3,int8 param_4)
{
char cVar1;
uint uVar2;
bool bVar3;
int8 local_38;
if (((DAT_00d89068 < (long)param_2) &&
(uVar2 = skipped_lsn_err_count + 1, bVar3 = skipped_lsn_err_count < 10,
skipped_lsn_err_count = uVar2, bVar3)) &&
(cVar1 = *(char *)(*param_1 + 0x7eb), *(char *)(*param_1 + 0x7eb) = cVar1 + '\x01',
cVar1 == '\0')) {
if (param_3 == '\0') {
local_38 = *(int8 *)(*param_1 + 0x5d0);
}
else {
local_38 = *(int8 *)(*param_1 + 0x5c0);
}
eprint(tracef,"Table %s has wrong LSN: (%u,0x%x) on page: %llu",local_38,
(long)param_2 >> 0x20 & 0xffffffff,param_2 & 0xffffffff,param_4);
recovery_found_crashed_tables = recovery_found_crashed_tables + 1;
}
return;
}
|
|
64,881 |
JS_InvokeFree
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue JS_InvokeFree(JSContext *ctx, JSValue this_val, JSAtom atom,
int argc, JSValue *argv)
{
JSValue res = JS_Invoke(ctx, this_val, atom, argc, argv);
JS_FreeValue(ctx, this_val);
return res;
}
|
O3
|
c
|
JS_InvokeFree:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r13
callq 0x30ab8
movq %rax, %r15
movq %rdx, %r12
cmpl $-0x9, %ebx
jb 0x565a4
movq 0x18(%r13), %rdi
movl (%r14), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%r14)
cmpl $0x1, %eax
jg 0x565a4
movq %r14, %rsi
movq %rbx, %rdx
callq 0x219cc
movq %r15, %rax
movq %r12, %rdx
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
|
JS_InvokeFree:
push r15
push r14
push r13
push r12
push rbx
mov rbx, rdx
mov r14, rsi
mov r13, rdi
call JS_Invoke
mov r15, rax
mov r12, rdx
cmp ebx, 0FFFFFFF7h
jb short loc_565A4
mov rdi, [r13+18h]
mov eax, [r14]
lea ecx, [rax-1]
mov [r14], ecx
cmp eax, 1
jg short loc_565A4
mov rsi, r14
mov rdx, rbx
call js_free_value_rt
loc_565A4:
mov rax, r15
mov rdx, r12
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
|
_QWORD * JS_InvokeFree(long long a1, _QWORD *a2, long long a3, unsigned int a4, int a5, long long a6)
{
unsigned int v6; // ebx
_QWORD *v7; // r15
long long v8; // rdi
int v9; // eax
v6 = a3;
v7 = JS_Invoke(a1, (long long)a2, a3, a4, a5, a6);
if ( v6 >= 0xFFFFFFF7 )
{
v8 = *(_QWORD *)(a1 + 24);
v9 = (*(_DWORD *)a2)--;
if ( v9 <= 1 )
js_free_value_rt(v8, a2, v6);
}
return v7;
}
|
JS_InvokeFree:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV RBX,RDX
MOV R14,RSI
MOV R13,RDI
CALL 0x00130ab8
MOV R15,RAX
MOV R12,RDX
CMP EBX,-0x9
JC 0x001565a4
MOV RDI,qword ptr [R13 + 0x18]
MOV EAX,dword ptr [R14]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R14],ECX
CMP EAX,0x1
JG 0x001565a4
MOV RSI,R14
MOV RDX,RBX
CALL 0x001219cc
LAB_001565a4:
MOV RAX,R15
MOV RDX,R12
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
int1 [16] JS_InvokeFree(long param_1,int *param_2,int8 param_3)
{
int iVar1;
int8 uVar2;
int1 auVar3 [16];
auVar3 = JS_Invoke();
if (0xfffffff6 < (uint)param_3) {
uVar2 = *(int8 *)(param_1 + 0x18);
iVar1 = *param_2;
*param_2 = iVar1 + -1;
if (iVar1 < 2) {
js_free_value_rt(uVar2,param_2,param_3);
}
}
return auVar3;
}
|
|
64,882 |
my_symlink
|
eloqsql/mysys/my_symlink.c
|
int my_symlink(const char *content, const char *linkname, myf MyFlags)
{
#ifndef HAVE_READLINK
return 0;
#else
int result;
DBUG_ENTER("my_symlink");
DBUG_PRINT("enter",("content: %s linkname: %s", content, linkname));
result= 0;
if (symlink(content, linkname))
{
result= -1;
my_errno=errno;
if (MyFlags & MY_WME)
my_error(EE_CANT_SYMLINK, MYF(0), linkname, content, errno);
}
else if ((MyFlags & MY_SYNC_DIR) && my_sync_dir_by_file(linkname, MyFlags))
result= -1;
DBUG_RETURN(result);
#endif /* HAVE_READLINK */
}
|
O0
|
c
|
my_symlink:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
jmp 0x2f296
movl $0x0, -0x1c(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x24080
cmpl $0x0, %eax
je 0x2f30a
movl $0xffffffff, -0x1c(%rbp) # imm = 0xFFFFFFFF
callq 0x24050
movl (%rax), %eax
movl %eax, -0x20(%rbp)
callq 0x26900
movl -0x20(%rbp), %ecx
movl %ecx, (%rax)
movq -0x18(%rbp), %rax
andq $0x10, %rax
cmpq $0x0, %rax
je 0x2f308
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x28(%rbp)
callq 0x24050
movq -0x30(%rbp), %rdx
movq -0x28(%rbp), %rcx
movl (%rax), %r8d
movl $0x19, %edi
xorl %eax, %eax
movl %eax, %esi
movb $0x0, %al
callq 0x2dc70
jmp 0x2f335
movq -0x18(%rbp), %rax
andq $0x8000, %rax # imm = 0x8000
cmpq $0x0, %rax
je 0x2f333
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x2fa00
cmpl $0x0, %eax
je 0x2f333
movl $0xffffffff, -0x1c(%rbp) # imm = 0xFFFFFFFF
jmp 0x2f335
jmp 0x2f337
movl -0x1c(%rbp), %eax
movl %eax, -0x34(%rbp)
movl -0x34(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
my_symlink:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
jmp short $+2
loc_2F296:
mov [rbp+var_1C], 0
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
call _symlink
cmp eax, 0
jz short loc_2F30A
mov [rbp+var_1C], 0FFFFFFFFh
call ___errno_location
mov eax, [rax]
mov [rbp+var_20], eax
call _my_thread_var
mov ecx, [rbp+var_20]
mov [rax], ecx
mov rax, [rbp+var_18]
and rax, 10h
cmp rax, 0
jz short loc_2F308
mov rax, [rbp+var_10]
mov [rbp+var_30], rax
mov rax, [rbp+var_8]
mov [rbp+var_28], rax
call ___errno_location
mov rdx, [rbp+var_30]
mov rcx, [rbp+var_28]
mov r8d, [rax]
mov edi, 19h
xor eax, eax
mov esi, eax
mov al, 0
call my_error
loc_2F308:
jmp short loc_2F335
loc_2F30A:
mov rax, [rbp+var_18]
and rax, 8000h
cmp rax, 0
jz short loc_2F333
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call my_sync_dir_by_file
cmp eax, 0
jz short loc_2F333
mov [rbp+var_1C], 0FFFFFFFFh
loc_2F333:
jmp short $+2
loc_2F335:
jmp short $+2
loc_2F337:
mov eax, [rbp+var_1C]
mov [rbp+var_34], eax
mov eax, [rbp+var_34]
add rsp, 40h
pop rbp
retn
|
long long my_symlink(long long a1, long long a2, long long a3)
{
unsigned int *v3; // rax
int v5; // [rsp+20h] [rbp-20h]
unsigned int v6; // [rsp+24h] [rbp-1Ch]
v6 = 0;
if ( (unsigned int)symlink(a1, a2) )
{
v6 = -1;
v5 = *(_DWORD *)__errno_location();
*(_DWORD *)my_thread_var() = v5;
if ( (a3 & 0x10) != 0 )
{
v3 = (unsigned int *)__errno_location();
my_error(0x19u, 0LL, a2, a1, *v3);
}
}
else if ( (a3 & 0x8000) != 0 && (unsigned int)my_sync_dir_by_file(a2, a3) )
{
return (unsigned int)-1;
}
return v6;
}
|
my_symlink:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
JMP 0x0012f296
LAB_0012f296:
MOV dword ptr [RBP + -0x1c],0x0
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
CALL 0x00124080
CMP EAX,0x0
JZ 0x0012f30a
MOV dword ptr [RBP + -0x1c],0xffffffff
CALL 0x00124050
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x20],EAX
CALL 0x00126900
MOV ECX,dword ptr [RBP + -0x20]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,0x10
CMP RAX,0x0
JZ 0x0012f308
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x28],RAX
CALL 0x00124050
MOV RDX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RBP + -0x28]
MOV R8D,dword ptr [RAX]
MOV EDI,0x19
XOR EAX,EAX
MOV ESI,EAX
MOV AL,0x0
CALL 0x0012dc70
LAB_0012f308:
JMP 0x0012f335
LAB_0012f30a:
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,0x8000
CMP RAX,0x0
JZ 0x0012f333
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x0012fa00
CMP EAX,0x0
JZ 0x0012f333
MOV dword ptr [RBP + -0x1c],0xffffffff
LAB_0012f333:
JMP 0x0012f335
LAB_0012f335:
JMP 0x0012f337
LAB_0012f337:
MOV EAX,dword ptr [RBP + -0x1c]
MOV dword ptr [RBP + -0x34],EAX
MOV EAX,dword ptr [RBP + -0x34]
ADD RSP,0x40
POP RBP
RET
|
int4 my_symlink(char *param_1,char *param_2,ulong param_3)
{
int iVar1;
int *piVar2;
int4 local_24;
local_24 = 0;
iVar1 = symlink(param_1,param_2);
if (iVar1 == 0) {
if (((param_3 & 0x8000) != 0) && (iVar1 = my_sync_dir_by_file(param_2,param_3), iVar1 != 0)) {
local_24 = 0xffffffff;
}
}
else {
local_24 = 0xffffffff;
piVar2 = __errno_location();
iVar1 = *piVar2;
piVar2 = (int *)_my_thread_var();
*piVar2 = iVar1;
if ((param_3 & 0x10) != 0) {
piVar2 = __errno_location();
my_error(0x19,0,param_2,param_1,*piVar2);
}
}
return local_24;
}
|
|
64,883 |
cli::value_base<cli::value>::get_option_help(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, cli::option_map&) const
|
msxemulator/build_O0/_deps/picotool-src/cli.h
|
bool get_option_help(string major_group, string minor_group, option_map &options) const override {
if (this->doc().empty()) {
return false;
}
options.add(major_group, minor_group, string("<") + this->_name + ">", this->doc());
return true;
}
|
O0
|
c
|
cli::value_base<cli::value>::get_option_help(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, cli::option_map&) const:
subq $0x118, %rsp # imm = 0x118
movq %rsi, 0x18(%rsp)
movq %rdx, 0x20(%rsp)
movq %rdi, 0x108(%rsp)
movq %rsi, 0x100(%rsp)
movq %rdx, 0xf8(%rsp)
movq %rcx, 0xf0(%rsp)
movq 0x108(%rsp), %rsi
movq %rsi, 0x28(%rsp)
leaq 0xd0(%rsp), %rdi
callq 0x75f40
leaq 0xd0(%rsp), %rdi
callq 0xf950
movb %al, 0x37(%rsp)
leaq 0xd0(%rsp), %rdi
callq 0xfb10
movb 0x37(%rsp), %al
testb $0x1, %al
jne 0x79b33
jmp 0x79b40
movb $0x0, 0x117(%rsp)
jmp 0x79cb0
movq 0xf0(%rsp), %rax
movq %rax, 0x8(%rsp)
leaq 0x6f(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0xf9f0
movq 0x10(%rsp), %rdx
leaq 0xf5cf0(%rip), %rsi # 0x16f858
leaq 0x70(%rsp), %rdi
callq 0xf7c0
jmp 0x79b74
movq 0x28(%rsp), %rdx
addq $0x48, %rdx
leaq 0x90(%rsp), %rdi
leaq 0x70(%rsp), %rsi
callq 0x795d0
jmp 0x79b91
leaq 0xf7c9b(%rip), %rdx # 0x171833
leaq 0xb0(%rsp), %rdi
leaq 0x90(%rsp), %rsi
callq 0x57950
jmp 0x79baf
movq 0x28(%rsp), %rsi
leaq 0x38(%rsp), %rdi
callq 0x75f40
jmp 0x79bc0
movq 0x20(%rsp), %rdx
movq 0x18(%rsp), %rsi
movq 0x8(%rsp), %rdi
leaq 0xb0(%rsp), %rcx
leaq 0x38(%rsp), %r8
callq 0x75f70
jmp 0x79be3
leaq 0x38(%rsp), %rdi
callq 0xfb10
leaq 0xb0(%rsp), %rdi
callq 0xfb10
leaq 0x90(%rsp), %rdi
callq 0xfb10
leaq 0x70(%rsp), %rdi
callq 0xfb10
leaq 0x6f(%rsp), %rdi
callq 0xf630
movb $0x1, 0x117(%rsp)
jmp 0x79cb0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0x79ca4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0x79c9a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0x79c8d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0x79c80
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
leaq 0x38(%rsp), %rdi
callq 0xfb10
leaq 0xb0(%rsp), %rdi
callq 0xfb10
leaq 0x90(%rsp), %rdi
callq 0xfb10
leaq 0x70(%rsp), %rdi
callq 0xfb10
leaq 0x6f(%rsp), %rdi
callq 0xf630
jmp 0x79cc1
movb 0x117(%rsp), %al
andb $0x1, %al
addq $0x118, %rsp # imm = 0x118
retq
movq 0x60(%rsp), %rdi
callq 0xf9e0
nopl (%rax,%rax)
|
_ZNK3cli10value_baseINS_5valueEE15get_option_helpENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_RNS_10option_mapE:
sub rsp, 118h
mov [rsp+118h+var_100], rsi
mov [rsp+118h+var_F8], rdx
mov [rsp+118h+var_10], rdi
mov [rsp+118h+var_18], rsi
mov [rsp+118h+var_20], rdx
mov [rsp+118h+var_28], rcx
mov rsi, [rsp+118h+var_10]
mov [rsp+118h+var_F0], rsi
lea rdi, [rsp+118h+var_48]
call _ZNK3cli9matchable3docB5cxx11Ev; cli::matchable::doc(void)
lea rdi, [rsp+118h+var_48]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5emptyEv; std::string::empty(void)
mov [rsp+118h+var_E1], al
lea rdi, [rsp+118h+var_48]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov al, [rsp+118h+var_E1]
test al, 1
jnz short loc_79B33
jmp short loc_79B40
loc_79B33:
mov [rsp+118h+var_1], 0
jmp loc_79CB0
loc_79B40:
mov rax, [rsp+118h+var_28]
mov [rsp+118h+var_110], rax
lea rdi, [rsp+118h+var_A9]
mov [rsp+118h+var_108], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rsp+118h+var_108]
lea rsi, aMissing+8; "<"
lea rdi, [rsp+118h+var_A8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EPKcRKS3_; std::string::basic_string(char const*,std::allocator<char> const&)
jmp short $+2
loc_79B74:
mov rdx, [rsp+118h+var_F0]
add rdx, 48h ; 'H'
lea rdi, [rsp+118h+var_88]
lea rsi, [rsp+118h+var_A8]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_RKS8_; std::operator+<char>(std::string&&,std::string const&)
jmp short $+2
loc_79B91:
lea rdx, asc_171832+1; ">"
lea rdi, [rsp+118h+var_68]
lea rsi, [rsp+118h+var_88]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_PKS5_; std::operator+<char>(std::string&&,char const*)
jmp short $+2
loc_79BAF:
mov rsi, [rsp+118h+var_F0]
lea rdi, [rsp+118h+var_E0]
call _ZNK3cli9matchable3docB5cxx11Ev; cli::matchable::doc(void)
jmp short $+2
loc_79BC0:
mov rdx, [rsp+118h+var_F8]
mov rsi, [rsp+118h+var_100]
mov rdi, [rsp+118h+var_110]
lea rcx, [rsp+118h+var_68]
lea r8, [rsp+118h+var_E0]
call _ZN3cli10option_map3addERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_S8_S8_; cli::option_map::add(std::string const&,std::string const&,std::string const&,std::string const&)
jmp short $+2
loc_79BE3:
lea rdi, [rsp+118h+var_E0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+118h+var_68]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+118h+var_88]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+118h+var_A8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+118h+var_A9]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov [rsp+118h+var_1], 1
jmp loc_79CB0
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_79CA4
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_79C9A
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_79C8D
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_79C80
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
lea rdi, [rsp+arg_30]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_79C80:
lea rdi, [rsp+arg_A8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_79C8D:
lea rdi, [rsp+arg_88]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_79C9A:
lea rdi, [rsp+arg_68]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_79CA4:
lea rdi, [rsp+arg_67]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_79CC1
loc_79CB0:
mov al, [rsp+118h+var_1]
and al, 1
add rsp, 118h
retn
loc_79CC1:
mov rdi, [rsp+arg_58]
call __Unwind_Resume
|
char cli::value_base<cli::value>::get_option_help(long long a1, long long a2, long long a3, long long a4)
{
long long v5; // [rsp+8h] [rbp-110h]
char v7; // [rsp+37h] [rbp-E1h]
_BYTE v8[55]; // [rsp+38h] [rbp-E0h] BYREF
char v9; // [rsp+6Fh] [rbp-A9h] BYREF
_BYTE v10[32]; // [rsp+70h] [rbp-A8h] BYREF
_BYTE v11[32]; // [rsp+90h] [rbp-88h] BYREF
_BYTE v12[32]; // [rsp+B0h] [rbp-68h] BYREF
_BYTE v13[32]; // [rsp+D0h] [rbp-48h] BYREF
long long v14; // [rsp+F0h] [rbp-28h]
long long v15; // [rsp+F8h] [rbp-20h]
long long v16; // [rsp+100h] [rbp-18h]
long long v17; // [rsp+108h] [rbp-10h]
v17 = a1;
v16 = a2;
v15 = a3;
v14 = a4;
cli::matchable::doc[abi:cxx11]((long long)v13, a1);
v7 = std::string::empty(v13);
std::string::~string(v13);
if ( (v7 & 1) != 0 )
return 0;
v5 = v14;
std::allocator<char>::allocator(&v9, a1);
std::string::basic_string(v10, "<", &v9);
std::operator+<char>((long long)v11, (long long)v10, a1 + 72);
std::operator+<char>((long long)v12, (long long)v11, (long long)">");
cli::matchable::doc[abi:cxx11]((long long)v8, a1);
cli::option_map::add(v5, a2, a3, (long long)v12, (long long)v8);
std::string::~string(v8);
std::string::~string(v12);
std::string::~string(v11);
std::string::~string(v10);
std::allocator<char>::~allocator(&v9);
return 1;
}
|
get_option_help:
SUB RSP,0x118
MOV qword ptr [RSP + 0x18],RSI
MOV qword ptr [RSP + 0x20],RDX
MOV qword ptr [RSP + 0x108],RDI
MOV qword ptr [RSP + 0x100],RSI
MOV qword ptr [RSP + 0xf8],RDX
MOV qword ptr [RSP + 0xf0],RCX
MOV RSI,qword ptr [RSP + 0x108]
MOV qword ptr [RSP + 0x28],RSI
LEA RDI,[RSP + 0xd0]
CALL 0x00175f40
LEA RDI,[RSP + 0xd0]
CALL 0x0010f950
MOV byte ptr [RSP + 0x37],AL
LEA RDI,[RSP + 0xd0]
CALL 0x0010fb10
MOV AL,byte ptr [RSP + 0x37]
TEST AL,0x1
JNZ 0x00179b33
JMP 0x00179b40
LAB_00179b33:
MOV byte ptr [RSP + 0x117],0x0
JMP 0x00179cb0
LAB_00179b40:
MOV RAX,qword ptr [RSP + 0xf0]
MOV qword ptr [RSP + 0x8],RAX
LEA RDI,[RSP + 0x6f]
MOV qword ptr [RSP + 0x10],RDI
CALL 0x0010f9f0
MOV RDX,qword ptr [RSP + 0x10]
LAB_00179b61:
LEA RSI,[0x26f858]
LEA RDI,[RSP + 0x70]
CALL 0x0010f7c0
JMP 0x00179b74
LAB_00179b74:
MOV RDX,qword ptr [RSP + 0x28]
ADD RDX,0x48
LAB_00179b7d:
LEA RDI,[RSP + 0x90]
LEA RSI,[RSP + 0x70]
CALL 0x001795d0
JMP 0x00179b91
LAB_00179b91:
LEA RDX,[0x271833]
LEA RDI,[RSP + 0xb0]
LEA RSI,[RSP + 0x90]
CALL 0x00157950
JMP 0x00179baf
LAB_00179baf:
MOV RSI,qword ptr [RSP + 0x28]
LEA RDI,[RSP + 0x38]
CALL 0x00175f40
JMP 0x00179bc0
LAB_00179bc0:
MOV RDX,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x18]
MOV RDI,qword ptr [RSP + 0x8]
LEA RCX,[RSP + 0xb0]
LEA R8,[RSP + 0x38]
CALL 0x00175f70
LAB_00179be1:
JMP 0x00179be3
LAB_00179be3:
LEA RDI,[RSP + 0x38]
CALL 0x0010fb10
LEA RDI,[RSP + 0xb0]
CALL 0x0010fb10
LEA RDI,[RSP + 0x90]
CALL 0x0010fb10
LEA RDI,[RSP + 0x70]
CALL 0x0010fb10
LEA RDI,[RSP + 0x6f]
CALL 0x0010f630
MOV byte ptr [RSP + 0x117],0x1
JMP 0x00179cb0
LAB_00179cb0:
MOV AL,byte ptr [RSP + 0x117]
AND AL,0x1
ADD RSP,0x118
RET
|
/* cli::value_base<cli::value>::get_option_help(std::__cxx11::string, std::__cxx11::string,
cli::option_map&) const */
int8 __thiscall
cli::value_base<cli::value>::get_option_help
(value_base<cli::value> *this,string *param_2,string *param_3,option_map *param_4)
{
option_map *this_00;
byte bVar1;
int8 uVar2;
int7 uVar3;
int7 extraout_var;
bool bVar4;
string local_e0 [55];
allocator local_a9;
string local_a8 [32];
string local_88 [32];
string local_68 [32];
string local_48 [32];
option_map *local_28;
string *local_20;
string *local_18;
value_base<cli::value> *local_10;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = this;
matchable::doc_abi_cxx11_();
bVar1 = std::__cxx11::string::empty();
uVar2 = std::__cxx11::string::~string(local_48);
this_00 = local_28;
uVar3 = (int7)((ulong)uVar2 >> 8);
bVar4 = (bVar1 & 1) == 0;
if (bVar4) {
std::allocator<char>::allocator();
/* try { // try from 00179b61 to 00179b71 has its CatchHandler @ 00179c28 */
std::__cxx11::string::string(local_a8,"<",&local_a9);
/* try { // try from 00179b7d to 00179b8e has its CatchHandler @ 00179c38 */
std::operator+(local_88,local_a8);
/* try { // try from 00179b91 to 00179bac has its CatchHandler @ 00179c48 */
std::operator+(local_68,(char *)local_88);
/* try { // try from 00179baf to 00179bbd has its CatchHandler @ 00179c58 */
matchable::doc_abi_cxx11_();
/* try { // try from 00179bc0 to 00179be0 has its CatchHandler @ 00179c68 */
option_map::add(this_00,param_2,param_3,local_68,local_e0);
std::__cxx11::string::~string(local_e0);
std::__cxx11::string::~string(local_68);
std::__cxx11::string::~string(local_88);
std::__cxx11::string::~string(local_a8);
std::allocator<char>::~allocator((allocator<char> *)&local_a9);
uVar3 = extraout_var;
}
return CONCAT71(uVar3,bVar4);
}
|
|
64,884 |
nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::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_12_0::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::basic_json(nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::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_12_0::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&)
|
shubhamoy[P]dir2txt/include/nlohmann/json.hpp
|
basic_json(const basic_json& other)
: json_base_class_t(other)
#if JSON_DIAGNOSTIC_POSITIONS
, start_position(other.start_position)
, end_position(other.end_position)
#endif
{
m_data.m_type = other.m_data.m_type;
// check of passed value is valid
other.assert_invariant();
switch (m_data.m_type)
{
case value_t::object:
{
m_data.m_value = *other.m_data.m_value.object;
break;
}
case value_t::array:
{
m_data.m_value = *other.m_data.m_value.array;
break;
}
case value_t::string:
{
m_data.m_value = *other.m_data.m_value.string;
break;
}
case value_t::boolean:
{
m_data.m_value = other.m_data.m_value.boolean;
break;
}
case value_t::number_integer:
{
m_data.m_value = other.m_data.m_value.number_integer;
break;
}
case value_t::number_unsigned:
{
m_data.m_value = other.m_data.m_value.number_unsigned;
break;
}
case value_t::number_float:
{
m_data.m_value = other.m_data.m_value.number_float;
break;
}
case value_t::binary:
{
m_data.m_value = *other.m_data.m_value.binary;
break;
}
case value_t::null:
case value_t::discarded:
default:
break;
}
set_parents();
assert_invariant();
}
|
O1
|
cpp
|
nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::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_12_0::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::basic_json(nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::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_12_0::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&):
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movb (%rsi), %al
movb %al, (%rdi)
movq %rsi, %rdi
movl $0x1, %esi
callq 0x2ab56
movzbl (%rbx), %eax
decl %eax
cmpl $0x7, %eax
ja 0x2b1c9
leaq 0xbed4(%rip), %rcx # 0x37048
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq 0x8(%r14), %rax
jmp 0x2b1c5
movq 0x8(%r14), %rdi
callq 0x2b5aa
jmp 0x2b1c5
movq 0x8(%r14), %rdi
callq 0x2b5fa
jmp 0x2b1c5
movzbl 0x8(%r14), %eax
jmp 0x2b1c5
movq 0x8(%r14), %rdi
callq 0x2b1f6
jmp 0x2b1c5
movq 0x8(%r14), %rdi
callq 0x2b41a
jmp 0x2b1c5
movsd 0x8(%r14), %xmm0
movsd %xmm0, (%rsp)
movq (%rsp), %rax
movq %rax, 0x8(%rbx)
movq %rbx, %rdi
movl $0x1, %esi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x2ab56
jmp 0x2b1e3
jmp 0x2b1e3
jmp 0x2b1e3
movq %rax, %r14
movq %rbx, %rdi
callq 0x2ac2c
movq %r14, %rdi
callq 0x85d0
|
_ZN8nlohmann16json_abi_v3_12_010basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ERKSD_:
push r14
push rbx
push rax
mov r14, rsi
mov rbx, rdi
xorps xmm0, xmm0
movups xmmword ptr [rdi], xmm0
mov al, [rsi]
mov [rdi], al
mov rdi, rsi
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_12_010basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
movzx eax, byte ptr [rbx]
dec eax; switch 8 cases
cmp eax, 7
ja short def_2B17B; jumptable 000000000002B17B default case
lea rcx, jpt_2B17B
movsxd rax, ds:(jpt_2B17B - 37048h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_2B17D:
mov rax, [r14+8]; jumptable 000000000002B17B cases 5,6
jmp short loc_2B1C5
loc_2B183:
mov rdi, [r14+8]; jumptable 000000000002B17B case 3
call _ZN8nlohmann16json_abi_v3_12_010basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createIS9_JRKS9_EEEPT_DpOT0_; nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>::create<std::string,std::string const&>(std::string const&)
jmp short loc_2B1C5
loc_2B18E:
mov rdi, [r14+8]; jumptable 000000000002B17B case 8
call _ZN8nlohmann16json_abi_v3_12_010basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createINS0_27byte_container_with_subtypeISC_EEJRKSG_EEEPT_DpOT0_; nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>::create<nlohmann::json_abi_v3_12_0::byte_container_with_subtype<std::vector<uchar>>,nlohmann::json_abi_v3_12_0::byte_container_with_subtype<std::vector<uchar>> const&>(nlohmann::json_abi_v3_12_0::byte_container_with_subtype<std::vector<uchar>> const&)
jmp short loc_2B1C5
loc_2B199:
movzx eax, byte ptr [r14+8]; jumptable 000000000002B17B case 4
jmp short loc_2B1C5
loc_2B1A0:
mov rdi, [r14+8]; jumptable 000000000002B17B case 1
call _ZN8nlohmann16json_abi_v3_12_010basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createINS2_IS9_SD_St4lessIvESaISt4pairIKS9_SD_EEEEJRKSL_EEEPT_DpOT0_; nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>::create<nlohmann::json_abi_v3_12_0::ordered_map<std::string,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>>>>,nlohmann::json_abi_v3_12_0::ordered_map<std::string,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>>>> const&>(nlohmann::json_abi_v3_12_0::ordered_map<std::string,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>>>> const&)
jmp short loc_2B1C5
loc_2B1AB:
mov rdi, [r14+8]; jumptable 000000000002B17B case 2
call _ZN8nlohmann16json_abi_v3_12_010basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createIS3_ISD_SaISD_EEJRKSG_EEEPT_DpOT0_; nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>::create<std::vector<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>>,std::vector<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>> const&>(std::vector<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>> const&)
jmp short loc_2B1C5
loc_2B1B6:
movsd xmm0, qword ptr [r14+8]; jumptable 000000000002B17B case 7
movsd [rsp+18h+var_18], xmm0
mov rax, [rsp+18h+var_18]
loc_2B1C5:
mov [rbx+8], rax
def_2B17B:
mov rdi, rbx; jumptable 000000000002B17B default case
mov esi, 1
add rsp, 8
pop rbx
pop r14
jmp _ZNK8nlohmann16json_abi_v3_12_010basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
jmp short loc_2B1E3
jmp short loc_2B1E3
jmp short $+2
loc_2B1E3:
mov r14, rax
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_12_010basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rdi, r14
call __Unwind_Resume
|
long long nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>::basic_json(
unsigned __int8 *a1,
unsigned __int8 *a2)
{
long long result; // rax
*(_OWORD *)a1 = 0LL;
*a1 = *a2;
nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a2);
result = (unsigned int)*a1 - 1;
switch ( *a1 )
{
case 1u:
result = nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>::create<nlohmann::json_abi_v3_12_0::ordered_map<std::string,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>>>>,nlohmann::json_abi_v3_12_0::ordered_map<std::string,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>>>> const&>(
*((_QWORD *)a2 + 1),
1LL);
goto LABEL_9;
case 2u:
result = nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>::create<std::vector<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>>,std::vector<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>> const&>(
*((_QWORD *)a2 + 1),
1LL);
goto LABEL_9;
case 3u:
result = nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>::create<std::string,std::string const&>(
*((_QWORD *)a2 + 1),
1LL);
goto LABEL_9;
case 4u:
result = a2[8];
goto LABEL_9;
case 5u:
case 6u:
result = *((_QWORD *)a2 + 1);
goto LABEL_9;
case 7u:
result = *((_QWORD *)a2 + 1);
goto LABEL_9;
case 8u:
result = nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>::create<nlohmann::json_abi_v3_12_0::byte_container_with_subtype<std::vector<unsigned char>>,nlohmann::json_abi_v3_12_0::byte_container_with_subtype<std::vector<unsigned char>> const&>(
*((_QWORD *)a2 + 1),
1LL);
LABEL_9:
*((_QWORD *)a1 + 1) = result;
break;
default:
break;
}
nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1);
return result;
}
|
basic_json:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RSI
MOV RBX,RDI
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI],XMM0
MOV AL,byte ptr [RSI]
MOV byte ptr [RDI],AL
MOV RDI,RSI
MOV ESI,0x1
CALL 0x0012ab56
MOVZX EAX,byte ptr [RBX]
DEC EAX
CMP EAX,0x7
JA 0x0012b1c9
LEA RCX,[0x137048]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_5:
MOV RAX,qword ptr [R14 + 0x8]
JMP 0x0012b1c5
caseD_3:
MOV RDI,qword ptr [R14 + 0x8]
LAB_0012b187:
CALL 0x0012b5aa
JMP 0x0012b1c5
caseD_8:
MOV RDI,qword ptr [R14 + 0x8]
LAB_0012b192:
CALL 0x0012b5fa
JMP 0x0012b1c5
caseD_4:
MOVZX EAX,byte ptr [R14 + 0x8]
JMP 0x0012b1c5
caseD_1:
MOV RDI,qword ptr [R14 + 0x8]
LAB_0012b1a4:
CALL 0x0012b1f6
JMP 0x0012b1c5
caseD_2:
MOV RDI,qword ptr [R14 + 0x8]
LAB_0012b1af:
CALL 0x0012b41a
LAB_0012b1b4:
JMP 0x0012b1c5
caseD_7:
MOVSD XMM0,qword ptr [R14 + 0x8]
MOVSD qword ptr [RSP],XMM0
MOV RAX,qword ptr [RSP]
LAB_0012b1c5:
MOV qword ptr [RBX + 0x8],RAX
default:
MOV RDI,RBX
MOV ESI,0x1
ADD RSP,0x8
POP RBX
POP R14
JMP 0x0012ab56
|
/* nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_12_0::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >,
void>::basic_json(nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_12_0::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const&) */
void __thiscall
nlohmann::json_abi_v3_12_0::
basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::basic_json(basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,basic_json *param_1)
{
string *psVar1;
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
*this = (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)*param_1;
assert_invariant(SUB81(param_1,0));
switch(*this) {
case (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x1:
/* try { // try from 0012b1a4 to 0012b1a8 has its CatchHandler @ 0012b1df */
psVar1 = (string *)
create<nlohmann::json_abi_v3_12_0::ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>,nlohmann::json_abi_v3_12_0::ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>const&>
(*(ordered_map **)(param_1 + 8));
break;
case (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2:
/* try { // try from 0012b1af to 0012b1b3 has its CatchHandler @ 0012b1dd */
psVar1 = (string *)
create<std::vector<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>,std::vector<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_12_0::basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>const&>
(*(vector **)(param_1 + 8));
break;
case (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x3:
/* try { // try from 0012b187 to 0012b18b has its CatchHandler @ 0012b1e3 */
psVar1 = create<std::__cxx11::string,std::__cxx11::string_const&>(*(string **)(param_1 + 8));
break;
case (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x4:
psVar1 = (string *)(ulong)(byte)param_1[8];
break;
case (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x5:
case (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x6:
psVar1 = *(string **)(param_1 + 8);
break;
case (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x7:
psVar1 = *(string **)(param_1 + 8);
break;
case (basic_json<nlohmann::json_abi_v3_12_0::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_12_0::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x8:
/* try { // try from 0012b192 to 0012b196 has its CatchHandler @ 0012b1e1 */
psVar1 = (string *)
create<nlohmann::json_abi_v3_12_0::byte_container_with_subtype<std::vector<unsigned_char,std::allocator<unsigned_char>>>,nlohmann::json_abi_v3_12_0::byte_container_with_subtype<std::vector<unsigned_char,std::allocator<unsigned_char>>>const&>
(*(byte_container_with_subtype **)(param_1 + 8));
break;
default:
goto switchD_0012b17b_default;
}
*(string **)(this + 8) = psVar1;
switchD_0012b17b_default:
assert_invariant(SUB81(this,0));
return;
}
|
|
64,885 |
my_error_register
|
eloqsql/mysys/my_error.c
|
int my_error_register(const char** (*get_errmsgs)(int error), uint first,
uint last)
{
struct my_err_head *meh_p;
struct my_err_head **search_meh_pp;
/* Allocate a new header structure. */
if (! (meh_p= (struct my_err_head*) my_malloc(key_memory_my_err_head,
sizeof(struct my_err_head),
MYF(MY_WME))))
return 1;
meh_p->get_errmsgs= get_errmsgs;
meh_p->meh_first= first;
meh_p->meh_last= last;
/* Search for the right position in the list. */
for (search_meh_pp= &my_errmsgs_list;
*search_meh_pp;
search_meh_pp= &(*search_meh_pp)->meh_next)
{
if ((*search_meh_pp)->meh_last > first)
break;
}
/* Error numbers must be unique. No overlapping is allowed. */
if (*search_meh_pp && ((*search_meh_pp)->meh_first <= last))
{
my_free(meh_p);
return 1;
}
/* Insert header into the chain. */
meh_p->meh_next= *search_meh_pp;
*search_meh_pp= meh_p;
return 0;
}
|
O0
|
c
|
my_error_register:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
leaq 0xb93357(%rip), %rax # 0xc845a0
movl (%rax), %edi
movl $0x18, %esi
movl $0x10, %edx
callq 0xf4be0
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
jne 0xf1270
movl $0x1, -0x4(%rbp)
jmp 0xf1310
movq -0x10(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x8(%rax)
movl -0x14(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x10(%rax)
movl -0x18(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x14(%rax)
leaq 0x1cf651(%rip), %rax # 0x2c08e8
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
cmpq $0x0, (%rax)
je 0xf12c5
movq -0x28(%rbp), %rax
movq (%rax), %rax
movl 0x14(%rax), %eax
cmpl -0x14(%rbp), %eax
jbe 0xf12b6
jmp 0xf12c5
jmp 0xf12b8
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x28(%rbp)
jmp 0xf129b
movq -0x28(%rbp), %rax
cmpq $0x0, (%rax)
je 0xf12f0
movq -0x28(%rbp), %rax
movq (%rax), %rax
movl 0x10(%rax), %eax
cmpl -0x18(%rbp), %eax
ja 0xf12f0
movq -0x20(%rbp), %rdi
callq 0xf4f60
movl $0x1, -0x4(%rbp)
jmp 0xf1310
movq -0x28(%rbp), %rax
movq (%rax), %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movq -0x20(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
|
my_error_register:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
lea rax, key_memory_my_err_head
mov edi, [rax]
mov esi, 18h
mov edx, 10h
call my_malloc
mov [rbp+var_20], rax
cmp rax, 0
jnz short loc_F1270
mov [rbp+var_4], 1
jmp loc_F1310
loc_F1270:
mov rcx, [rbp+var_10]
mov rax, [rbp+var_20]
mov [rax+8], rcx
mov ecx, [rbp+var_14]
mov rax, [rbp+var_20]
mov [rax+10h], ecx
mov ecx, [rbp+var_18]
mov rax, [rbp+var_20]
mov [rax+14h], ecx
lea rax, my_errmsgs_list
mov [rbp+var_28], rax
loc_F129B:
mov rax, [rbp+var_28]
cmp qword ptr [rax], 0
jz short loc_F12C5
mov rax, [rbp+var_28]
mov rax, [rax]
mov eax, [rax+14h]
cmp eax, [rbp+var_14]
jbe short loc_F12B6
jmp short loc_F12C5
loc_F12B6:
jmp short $+2
loc_F12B8:
mov rax, [rbp+var_28]
mov rax, [rax]
mov [rbp+var_28], rax
jmp short loc_F129B
loc_F12C5:
mov rax, [rbp+var_28]
cmp qword ptr [rax], 0
jz short loc_F12F0
mov rax, [rbp+var_28]
mov rax, [rax]
mov eax, [rax+10h]
cmp eax, [rbp+var_18]
ja short loc_F12F0
mov rdi, [rbp+var_20]
call my_free
mov [rbp+var_4], 1
jmp short loc_F1310
loc_F12F0:
mov rax, [rbp+var_28]
mov rcx, [rax]
mov rax, [rbp+var_20]
mov [rax], rcx
mov rcx, [rbp+var_20]
mov rax, [rbp+var_28]
mov [rax], rcx
mov [rbp+var_4], 0
loc_F1310:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
|
long long my_error_register(long long a1, unsigned int a2, unsigned int a3)
{
long long **i; // [rsp+8h] [rbp-28h]
long long v5; // [rsp+10h] [rbp-20h]
v5 = my_malloc(key_memory_my_err_head, 24LL, 16LL);
if ( v5 )
{
*(_QWORD *)(v5 + 8) = a1;
*(_DWORD *)(v5 + 16) = a2;
*(_DWORD *)(v5 + 20) = a3;
for ( i = &my_errmsgs_list; *i && *((_DWORD *)*i + 5) <= a2; i = (long long **)*i )
;
if ( *i && *((_DWORD *)*i + 4) <= a3 )
{
my_free(v5);
return 1;
}
else
{
*(_QWORD *)v5 = *i;
*i = (long long *)v5;
return 0;
}
}
else
{
return 1;
}
}
|
my_error_register:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV dword ptr [RBP + -0x18],EDX
LEA RAX,[0xd845a0]
MOV EDI,dword ptr [RAX]
MOV ESI,0x18
MOV EDX,0x10
CALL 0x001f4be0
MOV qword ptr [RBP + -0x20],RAX
CMP RAX,0x0
JNZ 0x001f1270
MOV dword ptr [RBP + -0x4],0x1
JMP 0x001f1310
LAB_001f1270:
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX + 0x8],RCX
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX + 0x10],ECX
MOV ECX,dword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX + 0x14],ECX
LEA RAX,[0x3c08e8]
MOV qword ptr [RBP + -0x28],RAX
LAB_001f129b:
MOV RAX,qword ptr [RBP + -0x28]
CMP qword ptr [RAX],0x0
JZ 0x001f12c5
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX + 0x14]
CMP EAX,dword ptr [RBP + -0x14]
JBE 0x001f12b6
JMP 0x001f12c5
LAB_001f12b6:
JMP 0x001f12b8
LAB_001f12b8:
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x28],RAX
JMP 0x001f129b
LAB_001f12c5:
MOV RAX,qword ptr [RBP + -0x28]
CMP qword ptr [RAX],0x0
JZ 0x001f12f0
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX + 0x10]
CMP EAX,dword ptr [RBP + -0x18]
JA 0x001f12f0
MOV RDI,qword ptr [RBP + -0x20]
CALL 0x001f4f60
MOV dword ptr [RBP + -0x4],0x1
JMP 0x001f1310
LAB_001f12f0:
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x0
LAB_001f1310:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
int4 my_error_register(long param_1,uint param_2,uint param_3)
{
long *plVar1;
int **local_30;
int4 local_c;
plVar1 = (long *)my_malloc(key_memory_my_err_head,0x18,0x10);
if (plVar1 == (long *)0x0) {
local_c = 1;
}
else {
plVar1[1] = param_1;
*(uint *)(plVar1 + 2) = param_2;
*(uint *)((long)plVar1 + 0x14) = param_3;
for (local_30 = &my_errmsgs_list;
(*local_30 != (int *)0x0 && (*(uint *)(*local_30 + 0x14) <= param_2));
local_30 = (int **)*local_30) {
}
if ((*local_30 == (int *)0x0) || (param_3 < *(uint *)(*local_30 + 0x10))) {
*plVar1 = (long)*local_30;
*local_30 = (int *)plVar1;
local_c = 0;
}
else {
my_free(plVar1);
local_c = 1;
}
}
return local_c;
}
|
|
64,886 |
nglog::LogDestination::FlushLogFiles(int)
|
ng-log[P]ng-log/src/logging.cc
|
inline void LogDestination::FlushLogFiles(int min_severity) {
// Prevent any subtle race conditions by wrapping a mutex lock around
// all this stuff.
std::lock_guard<std::mutex> l{log_mutex};
for (int i = min_severity; i < NUM_SEVERITIES; i++) {
LogDestination* log = log_destination(static_cast<LogSeverity>(i));
if (log != nullptr) {
log->logger_->Flush();
}
}
}
|
O3
|
cpp
|
nglog::LogDestination::FlushLogFiles(int):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl %edi, %ebx
leaq 0x2f220(%rip), %rdi # 0x40d48
callq 0x7840
testl %eax, %eax
jne 0x11bca
cmpl $0x3, %ebx
jg 0x11bb0
leaq 0x2014f(%rip), %r13 # 0x31c90
leaq 0x8(%rsp), %r14
movl %ebx, %r12d
movq (%r13,%r12,8), %rax
testq %rax, %rax
jne 0x11b9c
movl $0xd0, %edi
callq 0x8eb0
movq %rax, %r15
movq %rax, %rdi
movl %ebx, %esi
xorl %edx, %edx
callq 0xa6c4
leaq (,%r12,8), %r12
addq %r13, %r12
movq $0x0, 0x8(%rsp)
movq %r12, %rdi
movq %r15, %rsi
callq 0x129ba
movq %r14, %rdi
callq 0x115d4
movq (%r12), %rax
testq %rax, %rax
je 0x11ba9
movq 0xc8(%rax), %rdi
movq (%rdi), %rax
callq *0x18(%rax)
incl %ebx
cmpl $0x4, %ebx
jne 0x11b46
leaq 0x2f191(%rip), %rdi # 0x40d48
callq 0x73e0
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movl %eax, %edi
callq 0x7350
movq %rax, %rbx
movl $0xd0, %esi
movq %r15, %rdi
callq 0x8efc
jmp 0x11be6
movq %rax, %rbx
leaq 0x2f15b(%rip), %rdi # 0x40d48
callq 0x73e0
movq %rbx, %rdi
callq 0x79b0
|
_ZN5nglog14LogDestination13FlushLogFilesEi:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 10h
mov ebx, edi
lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex
call _pthread_mutex_lock
test eax, eax
jnz loc_11BCA
cmp ebx, 3
jg short loc_11BB0
lea r13, _ZN5nglog14LogDestination17log_destinations_E; nglog::LogDestination::log_destinations_
lea r14, [rsp+38h+var_30]
loc_11B46:
mov r12d, ebx
mov rax, [r13+r12*8+0]
test rax, rax
jnz short loc_11B9C
mov edi, 0D0h; unsigned __int64
call _Znwm; operator new(ulong)
mov r15, rax
mov rdi, rax
mov esi, ebx
xor edx, edx
call _ZN5nglog14LogDestinationC2ENS_11LogSeverityEPKc; nglog::LogDestination::LogDestination(nglog::LogSeverity,char const*)
lea r12, ds:0[r12*8]
add r12, r13
mov [rsp+38h+var_30], 0
mov rdi, r12
mov rsi, r15
call _ZNSt15__uniq_ptr_implIN5nglog14LogDestinationESt14default_deleteIS1_EE5resetEPS1_; std::__uniq_ptr_impl<nglog::LogDestination,std::default_delete<nglog::LogDestination>>::reset(nglog::LogDestination*)
mov rdi, r14
call _ZNSt10unique_ptrIN5nglog14LogDestinationESt14default_deleteIS1_EED2Ev; std::unique_ptr<nglog::LogDestination>::~unique_ptr()
mov rax, [r12]
test rax, rax
jz short loc_11BA9
loc_11B9C:
mov rdi, [rax+0C8h]
mov rax, [rdi]
call qword ptr [rax+18h]
loc_11BA9:
inc ebx
cmp ebx, 4
jnz short loc_11B46
loc_11BB0:
lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex
call _pthread_mutex_unlock
add rsp, 10h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
loc_11BCA:
mov edi, eax; int
call __ZSt20__throw_system_errori; std::__throw_system_error(int)
mov rbx, rax
mov esi, 0D0h; unsigned __int64
mov rdi, r15; void *
call _ZdlPvm; operator delete(void *,ulong)
jmp short loc_11BE6
mov rbx, rax
loc_11BE6:
lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex
call _pthread_mutex_unlock
mov rdi, rbx
call __Unwind_Resume
|
long long nglog::LogDestination::FlushLogFiles(nglog::LogDestination *this)
{
int v1; // ebx
int v2; // eax
long long v3; // rax
long long v4; // r15
nglog::LogDestination *v6; // [rsp+8h] [rbp-30h] BYREF
v1 = (int)this;
v2 = pthread_mutex_lock(&nglog::log_mutex);
if ( v2 )
std::__throw_system_error(v2);
if ( (int)this <= 3 )
{
do
{
v3 = nglog::LogDestination::log_destinations_[v1];
if ( v3
|| (v4 = operator new(208LL),
nglog::LogDestination::LogDestination(v4, v1, 0LL),
v6 = 0LL,
std::__uniq_ptr_impl<nglog::LogDestination,std::default_delete<nglog::LogDestination>>::reset(
&nglog::LogDestination::log_destinations_[v1],
v4),
std::unique_ptr<nglog::LogDestination>::~unique_ptr(&v6),
(v3 = nglog::LogDestination::log_destinations_[v1]) != 0) )
{
(*(void ( **)(_QWORD))(**(_QWORD **)(v3 + 200) + 24LL))(*(_QWORD *)(v3 + 200));
}
++v1;
}
while ( v1 != 4 );
}
return pthread_mutex_unlock(&nglog::log_mutex);
}
|
FlushLogFiles:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV EBX,EDI
LEA RDI,[0x140d48]
CALL 0x00107840
TEST EAX,EAX
JNZ 0x00111bca
CMP EBX,0x3
JG 0x00111bb0
LEA R13,[0x131c90]
LEA R14,[RSP + 0x8]
LAB_00111b46:
MOV R12D,EBX
MOV RAX,qword ptr [R13 + R12*0x8]
TEST RAX,RAX
JNZ 0x00111b9c
LAB_00111b53:
MOV EDI,0xd0
CALL 0x00108eb0
LAB_00111b5d:
MOV R15,RAX
MOV RDI,RAX
MOV ESI,EBX
XOR EDX,EDX
CALL 0x0010a6c4
LEA R12,[R12*0x8]
ADD R12,R13
MOV qword ptr [RSP + 0x8],0x0
MOV RDI,R12
MOV RSI,R15
CALL 0x001129ba
MOV RDI,R14
CALL 0x001115d4
MOV RAX,qword ptr [R12]
TEST RAX,RAX
JZ 0x00111ba9
LAB_00111b9c:
MOV RDI,qword ptr [RAX + 0xc8]
MOV RAX,qword ptr [RDI]
LAB_00111ba6:
CALL qword ptr [RAX + 0x18]
LAB_00111ba9:
INC EBX
CMP EBX,0x4
JNZ 0x00111b46
LAB_00111bb0:
LEA RDI,[0x140d48]
CALL 0x001073e0
ADD RSP,0x10
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
LAB_00111bca:
MOV EDI,EAX
CALL 0x00107350
|
/* nglog::LogDestination::FlushLogFiles(int) */
void nglog::LogDestination::FlushLogFiles(int param_1)
{
int iVar1;
LogDestination *pLVar2;
long lVar3;
uint uVar4;
int8 local_30;
ulong uVar5;
uVar5 = (ulong)(uint)param_1;
iVar1 = pthread_mutex_lock((pthread_mutex_t *)log_mutex);
if (iVar1 != 0) {
/* WARNING: Subroutine does not return */
std::__throw_system_error(iVar1);
}
if (param_1 < 4) {
do {
lVar3 = (&log_destinations_)[uVar5];
if (lVar3 == 0) {
/* try { // try from 00111b53 to 00111b5c has its CatchHandler @ 00111be3 */
pLVar2 = (LogDestination *)operator_new(0xd0);
/* try { // try from 00111b5d to 00111b6b has its CatchHandler @ 00111bd1 */
LogDestination(pLVar2,uVar5,0);
local_30 = 0;
std::__uniq_ptr_impl<nglog::LogDestination,std::default_delete<nglog::LogDestination>>::
reset((__uniq_ptr_impl<nglog::LogDestination,std::default_delete<nglog::LogDestination>> *)
(&log_destinations_ + uVar5),pLVar2);
std::unique_ptr<nglog::LogDestination,std::default_delete<nglog::LogDestination>>::
~unique_ptr((unique_ptr<nglog::LogDestination,std::default_delete<nglog::LogDestination>> *)
&local_30);
lVar3 = *(long *)(&log_destinations_ + uVar5);
if (lVar3 != 0) goto LAB_00111b9c;
}
else {
LAB_00111b9c:
/* try { // try from 00111ba6 to 00111ba8 has its CatchHandler @ 00111be3 */
(**(code **)(**(long **)(lVar3 + 200) + 0x18))();
}
uVar4 = (int)uVar5 + 1;
uVar5 = (ulong)uVar4;
} while (uVar4 != 4);
}
pthread_mutex_unlock((pthread_mutex_t *)log_mutex);
return;
}
|
|
64,887 |
nglog::(anonymous namespace)::LogCleaner::Run(std::chrono::time_point<std::chrono::_V2::system_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l>>> const&, bool, 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&)
|
ng-log[P]ng-log/src/logging.cc
|
void LogCleaner::Run(const std::chrono::system_clock::time_point& current_time,
bool base_filename_selected, const string& base_filename,
const string& filename_extension) {
assert(enabled_);
assert(!base_filename_selected || !base_filename.empty());
// avoid scanning logs too frequently
if (current_time < next_cleanup_time_) {
return;
}
next_cleanup_time_ =
current_time +
std::chrono::duration_cast<std::chrono::system_clock::duration>(
std::chrono::duration<int32>{FLAGS_logcleansecs});
vector<string> dirs;
if (!base_filename_selected) {
dirs = GetLoggingDirectories();
} else {
size_t pos = base_filename.find_last_of(possible_dir_delim, string::npos,
sizeof(possible_dir_delim));
if (pos != string::npos) {
string dir = base_filename.substr(0, pos + 1);
dirs.push_back(dir);
} else {
dirs.emplace_back(".");
}
}
for (const std::string& dir : dirs) {
vector<string> logs = GetOverdueLogNames(dir, current_time, base_filename,
filename_extension);
for (const std::string& log : logs) {
// NOTE May fail on Windows if the file is still open
int result = unlink(log.c_str());
if (result != 0) {
perror(("Could not remove overdue log " + log).c_str());
}
}
}
}
|
O0
|
cpp
|
nglog::(anonymous namespace)::LogCleaner::Run(std::chrono::time_point<std::chrono::_V2::system_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l>>> const&, bool, 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 %rbp
movq %rsp, %rbp
subq $0x150, %rsp # imm = 0x150
movb %dl, %al
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
andb $0x1, %al
movb %al, -0x11(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x138(%rbp)
testb $0x1, (%rax)
je 0x1b364
jmp 0x1b383
leaq 0x36a7c(%rip), %rdi # 0x51de7
leaq 0x36628(%rip), %rsi # 0x5199a
movl $0x51a, %edx # imm = 0x51A
leaq 0x36a72(%rip), %rcx # 0x51df0
callq 0x94a0
movb $0x1, %al
testb $0x1, -0x11(%rbp)
movb %al, -0x139(%rbp)
je 0x1b3a2
movq -0x20(%rbp), %rdi
callq 0x9c70
xorb $-0x1, %al
movb %al, -0x139(%rbp)
movb -0x139(%rbp), %al
testb $0x1, %al
jne 0x1b3ae
jmp 0x1b3b0
jmp 0x1b3cf
leaq 0x36ac1(%rip), %rdi # 0x51e78
leaq 0x365dc(%rip), %rsi # 0x5199a
movl $0x51b, %edx # imm = 0x51B
leaq 0x36a26(%rip), %rcx # 0x51df0
callq 0x94a0
movq -0x138(%rbp), %rsi
movq -0x10(%rbp), %rdi
addq $0x10, %rsi
callq 0x1f4c0
testb $0x1, %al
jne 0x1b3e9
jmp 0x1b3ee
jmp 0x1b714
movq -0x10(%rbp), %rax
movq %rax, -0x148(%rbp)
leaq -0x3c(%rbp), %rdi
leaq 0x5c8e4(%rip), %rsi # 0x77ce8
callq 0x1f4a0
leaq -0x3c(%rbp), %rdi
callq 0x1f5e0
movq -0x148(%rbp), %rdi
movq %rax, -0x38(%rbp)
leaq -0x38(%rbp), %rsi
callq 0x1f590
movq %rax, %rcx
movq -0x138(%rbp), %rax
movq %rcx, -0x30(%rbp)
movq -0x30(%rbp), %rcx
movq %rcx, 0x10(%rax)
leaq -0x58(%rbp), %rdi
callq 0xcea0
testb $0x1, -0x11(%rbp)
jne 0x1b481
callq 0x17520
movq %rax, -0x150(%rbp)
jmp 0x1b459
movq -0x150(%rbp), %rsi
leaq -0x58(%rbp), %rdi
callq 0x1f700
jmp 0x1b46b
jmp 0x1b518
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x1b71d
movq -0x20(%rbp), %rdi
leaq 0x3627c(%rip), %rsi # 0x51708
movq $-0x1, %rdx
movl $0x1, %ecx
callq 0x9ed0
movq %rax, -0x70(%rbp)
cmpq $-0x1, -0x70(%rbp)
je 0x1b502
movq -0x20(%rbp), %rsi
movq -0x70(%rbp), %rcx
incq %rcx
xorl %eax, %eax
movl %eax, %edx
leaq -0x90(%rbp), %rdi
callq 0x9740
jmp 0x1b4c5
leaq -0x58(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0x1ea60
jmp 0x1b4d7
leaq -0x90(%rbp), %rdi
callq 0x9ee8
jmp 0x1b516
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x90(%rbp), %rdi
callq 0x9ee8
jmp 0x1b71d
leaq 0x37cac(%rip), %rsi # 0x531b5
leaq -0x58(%rbp), %rdi
callq 0x1f950
jmp 0x1b514
jmp 0x1b516
jmp 0x1b518
leaq -0x58(%rbp), %rax
movq %rax, -0x98(%rbp)
movq -0x98(%rbp), %rdi
callq 0xd110
movq %rax, -0xa0(%rbp)
movq -0x98(%rbp), %rdi
callq 0x1eb40
movq %rax, -0xa8(%rbp)
leaq -0xa0(%rbp), %rdi
leaq -0xa8(%rbp), %rsi
callq 0x1eb00
testb $0x1, %al
jne 0x1b565
jmp 0x1b70b
leaq -0xa0(%rbp), %rdi
callq 0xd140
movq %rax, -0xb0(%rbp)
movq -0xb0(%rbp), %rsi
leaq -0xe8(%rbp), %rdi
callq 0x92d0
jmp 0x1b58d
movq -0x138(%rbp), %rsi
movq -0x10(%rbp), %rcx
movq -0x20(%rbp), %r8
movq -0x28(%rbp), %r9
leaq -0xc8(%rbp), %rdi
leaq -0xe8(%rbp), %rdx
callq 0x1b730
jmp 0x1b5b5
leaq -0xe8(%rbp), %rdi
callq 0x9ee8
leaq -0xc8(%rbp), %rax
movq %rax, -0xf0(%rbp)
movq -0xf0(%rbp), %rdi
callq 0xd110
movq %rax, -0xf8(%rbp)
movq -0xf0(%rbp), %rdi
callq 0x1eb40
movq %rax, -0x100(%rbp)
leaq -0xf8(%rbp), %rdi
leaq -0x100(%rbp), %rsi
callq 0x1eb00
testb $0x1, %al
jne 0x1b611
jmp 0x1b6e0
leaq -0xf8(%rbp), %rdi
callq 0xd140
movq %rax, -0x108(%rbp)
movq -0x108(%rbp), %rdi
callq 0x92b0
movq %rax, %rdi
callq 0x9320
movl %eax, -0x10c(%rbp)
cmpl $0x0, -0x10c(%rbp)
je 0x1b6cd
movq -0x108(%rbp), %rdx
leaq 0x36851(%rip), %rsi # 0x51eaa
leaq -0x130(%rbp), %rdi
callq 0x1f9d0
jmp 0x1b667
leaq -0x130(%rbp), %rdi
callq 0x92b0
movq %rax, %rdi
callq 0x95b0
jmp 0x1b67d
leaq -0x130(%rbp), %rdi
callq 0x9ee8
jmp 0x1b6cd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0xe8(%rbp), %rdi
callq 0x9ee8
jmp 0x1b71d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x1b6fd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x130(%rbp), %rdi
callq 0x9ee8
jmp 0x1b6fd
jmp 0x1b6cf
leaq -0xf8(%rbp), %rdi
callq 0x1ec40
jmp 0x1b5f5
leaq -0xc8(%rbp), %rdi
callq 0xcf30
leaq -0xa0(%rbp), %rdi
callq 0x1ec40
jmp 0x1b549
leaq -0xc8(%rbp), %rdi
callq 0xcf30
jmp 0x1b71d
leaq -0x58(%rbp), %rdi
callq 0xcf30
addq $0x150, %rsp # imm = 0x150
popq %rbp
retq
leaq -0x58(%rbp), %rdi
callq 0xcf30
movq -0x60(%rbp), %rdi
callq 0x9d40
nop
|
_ZN5nglog12_GLOBAL__N_110LogCleaner3RunERKNSt6chrono10time_pointINS2_3_V212system_clockENS2_8durationIlSt5ratioILl1ELl1000000000EEEEEEbRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESK_:
push rbp
mov rbp, rsp
sub rsp, 150h
mov al, dl
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
and al, 1
mov [rbp+var_11], al
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov rax, [rbp+var_8]
mov [rbp+var_138], rax
test byte ptr [rax], 1
jz short loc_1B364
jmp short loc_1B383
loc_1B364:
lea rdi, aEnabled; "enabled_"
lea rsi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
mov edx, 51Ah
lea rcx, aVoidNglogAnony; "void nglog::(anonymous namespace)::LogC"...
call ___assert_fail
loc_1B383:
mov al, 1
test [rbp+var_11], 1
mov [rbp+var_139], al
jz short loc_1B3A2
mov rdi, [rbp+var_20]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5emptyEv; std::string::empty(void)
xor al, 0FFh
mov [rbp+var_139], al
loc_1B3A2:
mov al, [rbp+var_139]
test al, 1
jnz short loc_1B3AE
jmp short loc_1B3B0
loc_1B3AE:
jmp short loc_1B3CF
loc_1B3B0:
lea rdi, aBaseFilenameSe; "!base_filename_selected || !base_filena"...
lea rsi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
mov edx, 51Bh
lea rcx, aVoidNglogAnony; "void nglog::(anonymous namespace)::LogC"...
call ___assert_fail
loc_1B3CF:
mov rsi, [rbp+var_138]
mov rdi, [rbp+var_10]
add rsi, 10h
call _ZNSt6chronoltINS_3_V212system_clockENS_8durationIlSt5ratioILl1ELl1000000000EEEES6_EEbRKNS_10time_pointIT_T0_EERKNS7_IS8_T1_EE; std::chrono::operator<<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>,std::chrono::duration<long,std::ratio<1l,1000000000l>>>(std::chrono::time_point<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>> const&,std::chrono::time_point<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>> const&)
test al, 1
jnz short loc_1B3E9
jmp short loc_1B3EE
loc_1B3E9:
jmp loc_1B714
loc_1B3EE:
mov rax, [rbp+var_10]
mov [rbp+var_148], rax
lea rdi, [rbp+var_3C]
lea rsi, _ZN3fLI18FLAGS_logcleansecsE; fLI::FLAGS_logcleansecs
call _ZNSt6chrono8durationIiSt5ratioILl1ELl1EEEC2IivEERKT_; std::chrono::duration<int,std::ratio<1l,1l>>::duration<int,void>(int const&)
lea rdi, [rbp+var_3C]
call _ZNSt6chrono13duration_castINS_8durationIlSt5ratioILl1ELl1000000000EEEEiS2_ILl1ELl1EEEENSt9enable_ifIXsr13__is_durationIT_EE5valueES7_E4typeERKNS1_IT0_T1_EE
mov rdi, [rbp+var_148]
mov [rbp+var_38], rax
lea rsi, [rbp+var_38]
call _ZNSt6chronoplINS_3_V212system_clockENS_8durationIlSt5ratioILl1ELl1000000000EEEElS5_EENS_10time_pointIT_NSt11common_typeIJT0_NS3_IT1_T2_EEEE4typeEEERKNS7_IS8_SA_EERKSD_; std::chrono::operator+<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>,long,std::ratio<1l,1000000000l>>(std::chrono::time_point<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>> const&,std::chrono::duration<long,std::ratio<1l,1000000000l>> const&)
mov rcx, rax
mov rax, [rbp+var_138]
mov [rbp+var_30], rcx
mov rcx, [rbp+var_30]
mov [rax+10h], rcx
lea rdi, [rbp+var_58]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EEC2Ev; std::vector<std::string>::vector(void)
test [rbp+var_11], 1
jnz short loc_1B481
call _ZN5nglog21GetLoggingDirectoriesB5cxx11Ev; nglog::GetLoggingDirectories(void)
mov [rbp+var_150], rax
jmp short $+2
loc_1B459:
mov rsi, [rbp+var_150]
lea rdi, [rbp+var_58]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EEaSERKS7_; std::vector<std::string>::operator=(std::vector<std::string> const&)
jmp short $+2
loc_1B46B:
jmp loc_1B518
mov rcx, rax
mov eax, edx
mov [rbp+var_60], rcx
mov [rbp+var_64], eax
jmp loc_1B71D
loc_1B481:
mov rdi, [rbp+var_20]
lea rsi, _ZN5nglog12_GLOBAL__N_118possible_dir_delimE; nglog::`anonymous namespace'::possible_dir_delim
mov rdx, 0FFFFFFFFFFFFFFFFh
mov ecx, 1
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12find_last_ofEPKcmm; std::string::find_last_of(char const*,ulong,ulong)
mov [rbp+var_70], rax
cmp [rbp+var_70], 0FFFFFFFFFFFFFFFFh
jz short loc_1B502
mov rsi, [rbp+var_20]
mov rcx, [rbp+var_70]
inc rcx
xor eax, eax
mov edx, eax
lea rdi, [rbp+var_90]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong)
jmp short $+2
loc_1B4C5:
lea rdi, [rbp+var_58]
lea rsi, [rbp+var_90]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE9push_backERKS5_; std::vector<std::string>::push_back(std::string const&)
jmp short $+2
loc_1B4D7:
lea rdi, [rbp+var_90]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_1B516
mov rcx, rax
mov eax, edx
mov [rbp+var_60], rcx
mov [rbp+var_64], eax
lea rdi, [rbp+var_90]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_1B71D
loc_1B502:
lea rsi, aSectionNameSIs+50h; "."
lea rdi, [rbp+var_58]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJRA2_KcEEERS5_DpOT_; std::vector<std::string>::emplace_back<char const(&)[2]>(char const(&)[2] &&)
jmp short $+2
loc_1B514:
jmp short $+2
loc_1B516:
jmp short $+2
loc_1B518:
lea rax, [rbp+var_58]
mov [rbp+var_98], rax
mov rdi, [rbp+var_98]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5beginEv; std::vector<std::string>::begin(void)
mov [rbp+var_A0], rax
mov rdi, [rbp+var_98]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE3endEv; std::vector<std::string>::end(void)
mov [rbp+var_A8], rax
loc_1B549:
lea rdi, [rbp+var_A0]
lea rsi, [rbp+var_A8]
call _ZN9__gnu_cxxneIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEEbRKNS_17__normal_iteratorIT_T0_EESG_; __gnu_cxx::operator!=<std::string *,std::vector<std::string>>(__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&,__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&)
test al, 1
jnz short loc_1B565
jmp loc_1B70B
loc_1B565:
lea rdi, [rbp+var_A0]
call _ZNK9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEdeEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*(void)
mov [rbp+var_B0], rax
mov rsi, [rbp+var_B0]
lea rdi, [rbp+var_E8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1ERKS4_; std::string::basic_string(std::string const&)
jmp short $+2
loc_1B58D:
mov rsi, [rbp+var_138]
mov rcx, [rbp+var_10]
mov r8, [rbp+var_20]
mov r9, [rbp+var_28]
lea rdi, [rbp+var_C8]
lea rdx, [rbp+var_E8]
call _ZNK5nglog12_GLOBAL__N_110LogCleaner18GetOverdueLogNamesENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNSt6chrono10time_pointINS8_3_V212system_clockENS8_8durationIlSt5ratioILl1ELl1000000000EEEEEERKS7_SK_; nglog::`anonymous namespace'::LogCleaner::GetOverdueLogNames(std::string,std::chrono::time_point<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>> const&,std::string const&,std::string const&)
jmp short $+2
loc_1B5B5:
lea rdi, [rbp+var_E8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rax, [rbp+var_C8]
mov [rbp+var_F0], rax
mov rdi, [rbp+var_F0]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5beginEv; std::vector<std::string>::begin(void)
mov [rbp+var_F8], rax
mov rdi, [rbp+var_F0]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE3endEv; std::vector<std::string>::end(void)
mov [rbp+var_100], rax
loc_1B5F5:
lea rdi, [rbp+var_F8]
lea rsi, [rbp+var_100]
call _ZN9__gnu_cxxneIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEEbRKNS_17__normal_iteratorIT_T0_EESG_; __gnu_cxx::operator!=<std::string *,std::vector<std::string>>(__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&,__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&)
test al, 1
jnz short loc_1B611
jmp loc_1B6E0
loc_1B611:
lea rdi, [rbp+var_F8]
call _ZNK9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEdeEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*(void)
mov [rbp+var_108], rax
mov rdi, [rbp+var_108]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov rdi, rax
call _unlink
mov [rbp+var_10C], eax
cmp [rbp+var_10C], 0
jz loc_1B6CD
mov rdx, [rbp+var_108]
lea rsi, aCouldNotRemove; "Could not remove overdue log "
lea rdi, [rbp+var_130]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
jmp short $+2
loc_1B667:
lea rdi, [rbp+var_130]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov rdi, rax
call _perror
jmp short $+2
loc_1B67D:
lea rdi, [rbp+var_130]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_1B6CD
mov rcx, rax
mov eax, edx
mov [rbp+var_60], rcx
mov [rbp+var_64], eax
lea rdi, [rbp+var_E8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_1B71D
mov rcx, rax
mov eax, edx
mov [rbp+var_60], rcx
mov [rbp+var_64], eax
jmp short loc_1B6FD
mov rcx, rax
mov eax, edx
mov [rbp+var_60], rcx
mov [rbp+var_64], eax
lea rdi, [rbp+var_130]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_1B6FD
loc_1B6CD:
jmp short $+2
loc_1B6CF:
lea rdi, [rbp+var_F8]
call _ZN9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEppEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(void)
jmp loc_1B5F5
loc_1B6E0:
lea rdi, [rbp+var_C8]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
lea rdi, [rbp+var_A0]
call _ZN9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEppEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(void)
jmp loc_1B549
loc_1B6FD:
lea rdi, [rbp+var_C8]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
jmp short loc_1B71D
loc_1B70B:
lea rdi, [rbp+var_58]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
loc_1B714:
add rsp, 150h
pop rbp
retn
loc_1B71D:
lea rdi, [rbp+var_58]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, [rbp+var_60]
call __Unwind_Resume
|
long long nglog::`anonymous namespace'::LogCleaner::Run(
long long a1,
long long a2,
char a3,
long long a4,
long long a5)
{
long long result; // rax
long long v6; // rax
long long v7; // rax
long long v8; // [rsp+0h] [rbp-150h]
long long v9; // [rsp+8h] [rbp-148h]
char v10; // [rsp+17h] [rbp-139h]
_BYTE v11[36]; // [rsp+20h] [rbp-130h] BYREF
long long v13; // [rsp+48h] [rbp-108h]
long long v14; // [rsp+50h] [rbp-100h] BYREF
long long v15; // [rsp+58h] [rbp-F8h] BYREF
long long *v16; // [rsp+60h] [rbp-F0h]
_BYTE v17[32]; // [rsp+68h] [rbp-E8h] BYREF
long long v18[3]; // [rsp+88h] [rbp-C8h] BYREF
long long v19; // [rsp+A0h] [rbp-B0h]
long long v20; // [rsp+A8h] [rbp-A8h] BYREF
_QWORD v21[2]; // [rsp+B0h] [rbp-A0h] BYREF
_BYTE v22[32]; // [rsp+C0h] [rbp-90h] BYREF
long long last_of; // [rsp+E0h] [rbp-70h]
long long v24[3]; // [rsp+F8h] [rbp-58h] BYREF
_BYTE v25[4]; // [rsp+114h] [rbp-3Ch] BYREF
long long v26; // [rsp+118h] [rbp-38h] BYREF
long long v27; // [rsp+120h] [rbp-30h]
long long v28; // [rsp+128h] [rbp-28h]
long long v29; // [rsp+130h] [rbp-20h]
char v30; // [rsp+13Fh] [rbp-11h]
long long v31; // [rsp+140h] [rbp-10h]
long long v32; // [rsp+148h] [rbp-8h]
v32 = a1;
v31 = a2;
v30 = a3 & 1;
v29 = a4;
v28 = a5;
if ( (*(_BYTE *)a1 & 1) == 0 )
__assert_fail(
"enabled_",
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",
1306LL,
"void nglog::(anonymous namespace)::LogCleaner::Run(const std::chrono::system_clock::time_point &, bool, const stri"
"ng &, const string &)");
v10 = 1;
if ( (v30 & 1) != 0 )
v10 = ~(unsigned __int8)std::string::empty(v29);
if ( (v10 & 1) == 0 )
__assert_fail(
"!base_filename_selected || !base_filename.empty()",
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",
1307LL,
"void nglog::(anonymous namespace)::LogCleaner::Run(const std::chrono::system_clock::time_point &, bool, const stri"
"ng &, const string &)");
result = std::chrono::operator<<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>,std::chrono::duration<long,std::ratio<1l,1000000000l>>>(
v31,
a1 + 16);
if ( (result & 1) == 0 )
{
v9 = v31;
std::chrono::duration<int,std::ratio<1l,1l>>::duration<int,void>(v25, &fLI::FLAGS_logcleansecs);
v26 = std::chrono::duration_cast<std::chrono::duration<long,std::ratio<1l,1000000000l>>,int,std::ratio<1l,1l>>(v25);
v27 = std::chrono::operator+<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>,long,std::ratio<1l,1000000000l>>(
v9,
&v26);
*(_QWORD *)(a1 + 16) = v27;
std::vector<std::string>::vector((long long)v24);
if ( (v30 & 1) != 0 )
{
last_of = std::string::find_last_of(v29, &nglog::`anonymous namespace'::possible_dir_delim, -1LL, 1LL);
if ( last_of == -1 )
{
std::vector<std::string>::emplace_back<char const(&)[2]>(v24, ".");
}
else
{
std::string::substr(v22, v29, 0LL, last_of + 1);
std::vector<std::string>::push_back(v24, v22);
std::string::~string(v22);
}
}
else
{
v8 = nglog::GetLoggingDirectories[abi:cxx11]();
std::vector<std::string>::operator=(v24, v8);
}
v21[1] = v24;
v21[0] = std::vector<std::string>::begin((long long)v24);
v20 = std::vector<std::string>::end(v24);
while ( (__gnu_cxx::operator!=<std::string *,std::vector<std::string>>(v21, &v20) & 1) != 0 )
{
v19 = __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*((long long)v21);
std::string::basic_string(v17, v19);
nglog::`anonymous namespace'::LogCleaner::GetOverdueLogNames(v18, a1, v17, v31, v29, v28);
std::string::~string(v17);
v16 = v18;
v15 = std::vector<std::string>::begin((long long)v18);
v14 = std::vector<std::string>::end(v16);
while ( (__gnu_cxx::operator!=<std::string *,std::vector<std::string>>(&v15, &v14) & 1) != 0 )
{
v13 = __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*((long long)&v15);
v6 = std::string::c_str(v13);
if ( (unsigned int)unlink(v6) )
{
std::operator+<char>(v11, "Could not remove overdue log ", v13);
v7 = std::string::c_str(v11);
perror(v7);
std::string::~string(v11);
}
__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(&v15);
}
std::vector<std::string>::~vector(v18);
__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(v21);
}
return std::vector<std::string>::~vector(v24);
}
return result;
}
|
Run:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x150
MOV AL,DL
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
AND AL,0x1
MOV byte ptr [RBP + -0x11],AL
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x138],RAX
TEST byte ptr [RAX],0x1
JZ 0x0011b364
JMP 0x0011b383
LAB_0011b364:
LEA RDI,[0x151de7]
LEA RSI,[0x15199a]
MOV EDX,0x51a
LEA RCX,[0x151df0]
CALL 0x001094a0
LAB_0011b383:
MOV AL,0x1
TEST byte ptr [RBP + -0x11],0x1
MOV byte ptr [RBP + -0x139],AL
JZ 0x0011b3a2
MOV RDI,qword ptr [RBP + -0x20]
CALL 0x00109c70
XOR AL,0xff
MOV byte ptr [RBP + -0x139],AL
LAB_0011b3a2:
MOV AL,byte ptr [RBP + -0x139]
TEST AL,0x1
JNZ 0x0011b3ae
JMP 0x0011b3b0
LAB_0011b3ae:
JMP 0x0011b3cf
LAB_0011b3b0:
LEA RDI,[0x151e78]
LEA RSI,[0x15199a]
MOV EDX,0x51b
LEA RCX,[0x151df0]
CALL 0x001094a0
LAB_0011b3cf:
MOV RSI,qword ptr [RBP + -0x138]
MOV RDI,qword ptr [RBP + -0x10]
ADD RSI,0x10
CALL 0x0011f4c0
TEST AL,0x1
JNZ 0x0011b3e9
JMP 0x0011b3ee
LAB_0011b3e9:
JMP 0x0011b714
LAB_0011b3ee:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x148],RAX
LEA RDI,[RBP + -0x3c]
LEA RSI,[0x177ce8]
CALL 0x0011f4a0
LEA RDI,[RBP + -0x3c]
CALL 0x0011f5e0
MOV RDI,qword ptr [RBP + -0x148]
MOV qword ptr [RBP + -0x38],RAX
LEA RSI,[RBP + -0x38]
CALL 0x0011f590
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x138]
MOV qword ptr [RBP + -0x30],RCX
MOV RCX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX + 0x10],RCX
LEA RDI,[RBP + -0x58]
CALL 0x0010cea0
TEST byte ptr [RBP + -0x11],0x1
JNZ 0x0011b481
LAB_0011b44b:
CALL 0x00117520
MOV qword ptr [RBP + -0x150],RAX
JMP 0x0011b459
LAB_0011b459:
MOV RSI,qword ptr [RBP + -0x150]
LEA RDI,[RBP + -0x58]
CALL 0x0011f700
JMP 0x0011b46b
LAB_0011b46b:
JMP 0x0011b518
LAB_0011b481:
MOV RDI,qword ptr [RBP + -0x20]
LEA RSI,[0x151708]
MOV RDX,-0x1
MOV ECX,0x1
CALL 0x00109ed0
MOV qword ptr [RBP + -0x70],RAX
CMP qword ptr [RBP + -0x70],-0x1
JZ 0x0011b502
MOV RSI,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x70]
INC RCX
XOR EAX,EAX
MOV EDX,EAX
LEA RDI,[RBP + -0x90]
CALL 0x00109740
JMP 0x0011b4c5
LAB_0011b4c5:
LEA RDI,[RBP + -0x58]
LEA RSI,[RBP + -0x90]
CALL 0x0011ea60
JMP 0x0011b4d7
LAB_0011b4d7:
LEA RDI,[RBP + -0x90]
CALL 0x00109ee8
JMP 0x0011b516
LAB_0011b502:
LEA RSI,[0x1531b5]
LEA RDI,[RBP + -0x58]
CALL 0x0011f950
JMP 0x0011b514
LAB_0011b514:
JMP 0x0011b516
LAB_0011b516:
JMP 0x0011b518
LAB_0011b518:
LEA RAX,[RBP + -0x58]
MOV qword ptr [RBP + -0x98],RAX
MOV RDI,qword ptr [RBP + -0x98]
CALL 0x0010d110
MOV qword ptr [RBP + -0xa0],RAX
MOV RDI,qword ptr [RBP + -0x98]
CALL 0x0011eb40
MOV qword ptr [RBP + -0xa8],RAX
LAB_0011b549:
LEA RDI,[RBP + -0xa0]
LEA RSI,[RBP + -0xa8]
CALL 0x0011eb00
TEST AL,0x1
JNZ 0x0011b565
JMP 0x0011b70b
LAB_0011b565:
LEA RDI,[RBP + -0xa0]
CALL 0x0010d140
MOV qword ptr [RBP + -0xb0],RAX
MOV RSI,qword ptr [RBP + -0xb0]
LEA RDI,[RBP + -0xe8]
CALL 0x001092d0
JMP 0x0011b58d
LAB_0011b58d:
MOV RSI,qword ptr [RBP + -0x138]
MOV RCX,qword ptr [RBP + -0x10]
MOV R8,qword ptr [RBP + -0x20]
MOV R9,qword ptr [RBP + -0x28]
LAB_0011b5a0:
LEA RDI,[RBP + -0xc8]
LEA RDX,[RBP + -0xe8]
CALL 0x0011b730
JMP 0x0011b5b5
LAB_0011b5b5:
LEA RDI,[RBP + -0xe8]
CALL 0x00109ee8
LEA RAX,[RBP + -0xc8]
MOV qword ptr [RBP + -0xf0],RAX
MOV RDI,qword ptr [RBP + -0xf0]
CALL 0x0010d110
MOV qword ptr [RBP + -0xf8],RAX
MOV RDI,qword ptr [RBP + -0xf0]
CALL 0x0011eb40
MOV qword ptr [RBP + -0x100],RAX
LAB_0011b5f5:
LEA RDI,[RBP + -0xf8]
LEA RSI,[RBP + -0x100]
CALL 0x0011eb00
TEST AL,0x1
JNZ 0x0011b611
JMP 0x0011b6e0
LAB_0011b611:
LEA RDI,[RBP + -0xf8]
CALL 0x0010d140
MOV qword ptr [RBP + -0x108],RAX
MOV RDI,qword ptr [RBP + -0x108]
CALL 0x001092b0
MOV RDI,RAX
CALL 0x00109320
MOV dword ptr [RBP + -0x10c],EAX
CMP dword ptr [RBP + -0x10c],0x0
JZ 0x0011b6cd
MOV RDX,qword ptr [RBP + -0x108]
LAB_0011b652:
LEA RSI,[0x151eaa]
LEA RDI,[RBP + -0x130]
CALL 0x0011f9d0
JMP 0x0011b667
LAB_0011b667:
LEA RDI,[RBP + -0x130]
CALL 0x001092b0
MOV RDI,RAX
LAB_0011b676:
CALL 0x001095b0
LAB_0011b67b:
JMP 0x0011b67d
LAB_0011b67d:
LEA RDI,[RBP + -0x130]
CALL 0x00109ee8
JMP 0x0011b6cd
LAB_0011b6cd:
JMP 0x0011b6cf
LAB_0011b6cf:
LEA RDI,[RBP + -0xf8]
CALL 0x0011ec40
JMP 0x0011b5f5
LAB_0011b6e0:
LEA RDI,[RBP + -0xc8]
CALL 0x0010cf30
LEA RDI,[RBP + -0xa0]
CALL 0x0011ec40
JMP 0x0011b549
LAB_0011b70b:
LEA RDI,[RBP + -0x58]
CALL 0x0010cf30
LAB_0011b714:
ADD RSP,0x150
POP RBP
RET
|
/* nglog::(anonymous
namespace)::LogCleaner::Run(std::chrono::time_point<std::chrono::_V2::system_clock,
std::chrono::duration<long, std::ratio<1l, 1000000000l> > > const&, bool, std::__cxx11::string
const&, std::__cxx11::string const&) */
void __thiscall
nglog::(anonymous_namespace)::LogCleaner::Run
(LogCleaner *this,time_point *param_1,bool param_2,string *param_3,string *param_4)
{
time_point *ptVar1;
bool bVar2;
vector *pvVar3;
char *pcVar4;
byte local_141;
string local_138 [36];
int local_114;
int8 local_110;
int8 local_108;
int8 local_100;
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *local_f8;
string local_f0 [32];
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> local_d0 [24];
string *local_b8;
int8 local_b0;
int8 local_a8;
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *local_a0;
string local_98 [32];
long local_78;
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> local_60 [28];
duration<int,std::ratio<1l,1l>> local_44 [4];
int8 local_40;
int8 local_38;
string *local_30;
string *local_28;
byte local_19;
time_point *local_18;
LogCleaner *local_10;
local_30 = param_4;
local_28 = param_3;
local_19 = param_2;
local_18 = param_1;
local_10 = this;
if (((byte)*this & 1) == 0) {
/* WARNING: Subroutine does not return */
__assert_fail("enabled_",
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",0x51a,
"void nglog::(anonymous namespace)::LogCleaner::Run(const std::chrono::system_clock::time_point &, bool, const string &, const string &)"
);
}
local_141 = 1;
if (param_2) {
local_141 = std::__cxx11::string::empty();
local_141 = local_141 ^ 0xff;
}
if ((local_141 & 1) != 0) {
bVar2 = std::chrono::operator<(local_18,this + 0x10);
ptVar1 = local_18;
if (!bVar2) {
std::chrono::duration<int,std::ratio<1l,1l>>::duration<int,void>
(local_44,&fLI::FLAGS_logcleansecs);
local_40 = std::chrono::
duration_cast<std::chrono::duration<long,std::ratio<1l,1000000000l>>,int,std::ratio<1l,1l>>
((duration *)local_44);
local_38 = std::chrono::operator+(ptVar1,(duration *)&local_40);
*(int8 *)(this + 0x10) = local_38;
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::vector(local_60);
if ((local_19 & 1) == 0) {
/* try { // try from 0011b44b to 0011b4c2 has its CatchHandler @ 0011b470 */
pvVar3 = (vector *)GetLoggingDirectories_abi_cxx11_();
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::operator=
(local_60,pvVar3);
}
else {
local_78 = std::__cxx11::string::find_last_of((char *)local_28,0x151708,0xffffffffffffffff);
if (local_78 == -1) {
/* try { // try from 0011b502 to 0011b58a has its CatchHandler @ 0011b470 */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<char_const(&)[2]>(local_60,".");
}
else {
std::__cxx11::string::substr((ulong)local_98,(ulong)local_28);
/* try { // try from 0011b4c5 to 0011b4d4 has its CatchHandler @ 0011b4e5 */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::push_back
(local_60,local_98);
std::__cxx11::string::~string(local_98);
}
}
local_a0 = local_60;
local_a8 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::begin
(local_a0);
local_b0 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::end
(local_a0);
while (bVar2 = __gnu_cxx::operator!=
((__normal_iterator *)&local_a8,(__normal_iterator *)&local_b0),
bVar2) {
local_b8 = (string *)
__gnu_cxx::
__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::operator*((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_a8);
std::__cxx11::string::string(local_f0,local_b8);
/* try { // try from 0011b5a0 to 0011b5b2 has its CatchHandler @ 0011b68b */
GetOverdueLogNames(local_d0,this,local_f0,local_18,local_28,local_30);
std::__cxx11::string::~string(local_f0);
local_f8 = local_d0;
local_100 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::begin
(local_f8);
local_108 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::end
(local_f8);
while (bVar2 = __gnu_cxx::operator!=
((__normal_iterator *)&local_100,(__normal_iterator *)&local_108),
bVar2) {
local_110 = __gnu_cxx::
__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::operator*((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_100);
pcVar4 = (char *)std::__cxx11::string::c_str();
local_114 = unlink(pcVar4);
if (local_114 != 0) {
/* try { // try from 0011b652 to 0011b664 has its CatchHandler @ 0011b6a5 */
std::operator+((char *)local_138,(string *)"Could not remove overdue log ");
pcVar4 = (char *)std::__cxx11::string::c_str();
/* try { // try from 0011b676 to 0011b67a has its CatchHandler @ 0011b6b3 */
perror(pcVar4);
std::__cxx11::string::~string(local_138);
}
__gnu_cxx::
__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::operator++((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_100);
}
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector(local_d0);
__gnu_cxx::
__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::operator++((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_a8);
}
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector(local_60);
}
return;
}
/* WARNING: Subroutine does not return */
__assert_fail("!base_filename_selected || !base_filename.empty()",
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",0x51b,
"void nglog::(anonymous namespace)::LogCleaner::Run(const std::chrono::system_clock::time_point &, bool, const string &, const string &)"
);
}
|
|
64,888 |
nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int)
|
ng-log[P]ng-log/src/vlog_is_on.cc
|
bool InitializeVLOG3(SiteFlag* site_flag, int32* level_default,
const char* fname, int32 verbose_level) {
std::lock_guard<std::mutex> l(vmodule_mutex);
bool read_vmodule_flag = inited_vmodule;
if (!read_vmodule_flag) {
VLOG2Initializer();
}
// protect the errno global in case someone writes:
// VLOG(..) << "The last error was " << strerror(errno)
int old_errno = errno;
// site_default normally points to FLAGS_v
int32* site_flag_value = level_default;
// Get basename for file
const char* base = strrchr(fname, '/');
#ifdef _WIN32
if (!base) {
base = strrchr(fname, '\\');
}
#endif
base = base ? (base + 1) : fname;
const char* base_end = strchr(base, '.');
size_t base_length =
base_end ? static_cast<size_t>(base_end - base) : strlen(base);
// Trim out trailing "-inl" if any
if (base_length >= 4 && (memcmp(base + base_length - 4, "-inl", 4) == 0)) {
base_length -= 4;
}
// TODO: Trim out _unittest suffix? Perhaps it is better to have
// the extra control and just leave it there.
// find target in vector of modules, replace site_flag_value with
// a module-specific verbose level, if any.
for (const VModuleInfo* info = vmodule_list; info != nullptr;
info = info->next) {
if (SafeFNMatch_(info->module_pattern.c_str(), info->module_pattern.size(),
base, base_length)) {
site_flag_value = &info->vlog_level;
// value at info->vlog_level is now what controls
// the VLOG at the caller site forever
break;
}
}
// Cache the vlog value pointer if --vmodule flag has been parsed.
ANNOTATE_BENIGN_RACE(site_flag,
"*site_flag may be written by several threads,"
" but the value will be the same");
if (read_vmodule_flag) {
site_flag->level = site_flag_value;
// If VLOG flag has been cached to the default site pointer,
// we want to add to the cached list in order to invalidate in case
// SetVModule is called afterwards with new modules.
// The performance penalty here is neglible, because InitializeVLOG3 is
// called once per site.
if (site_flag_value == level_default && !site_flag->base_name) {
site_flag->base_name = base;
site_flag->base_len = base_length;
site_flag->next = cached_site_list;
cached_site_list = site_flag;
}
}
// restore the errno in case something recoverable went wrong during
// the initialization of the VLOG mechanism (see above note "protect the..")
errno = old_errno;
return *site_flag_value >= verbose_level;
}
|
O1
|
cpp
|
nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %ecx, %ebp
movq %rdx, %r14
movq %rsi, %r13
movq %rdi, %r15
leaq 0x203a9(%rip), %rdi # 0x42b70
callq 0x77f0
testl %eax, %eax
jne 0x229f4
movb 0x2038e(%rip), %al # 0x42b68
movb %al, 0x7(%rsp)
testb %al, %al
jne 0x22913
movq %r14, 0x10(%rsp)
movq %r13, 0x18(%rsp)
movq %r15, 0x20(%rsp)
movl %ebp, 0x8(%rsp)
movb $0x0, 0x20368(%rip) # 0x42b68
leaq 0xdd31(%rip), %rax # 0x30538
movq (%rax), %rax
movq (%rax), %r15
leaq 0x38(%rsp), %r12
leaq 0x28(%rsp), %r13
xorl %ebp, %ebp
xorl %ebx, %ebx
movq %r15, %rdi
movl $0x3d, %esi
callq 0x71b0
testq %rax, %rax
je 0x228e2
movq %rax, %r14
movq %r12, 0x28(%rsp)
movq %r13, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0xa556
movq %r14, %rdi
leaq 0x2bad(%rip), %rsi # 0x253fe
leaq 0xc(%rsp), %rdx
xorl %eax, %eax
callq 0x7500
cmpl $0x1, %eax
jne 0x228a7
movl $0x30, %edi
callq 0x9450
movq %rax, %r15
addq $0x10, %rax
movq %rax, (%r15)
movq $0x0, 0x8(%r15)
movb $0x0, 0x10(%r15)
movq %r15, %rdi
movq %r13, %rsi
callq 0x72a0
movl 0xc(%rsp), %eax
movl %eax, 0x20(%r15)
testq %rbp, %rbp
je 0x228a1
movq %r15, 0x28(%rbx)
jmp 0x228a4
movq %r15, %rbp
movq %r15, %rbx
movq %r14, %rdi
movl $0x2c, %esi
callq 0x71b0
movq %rax, %r14
leaq 0x1(%rax), %r15
testq %rax, %rax
cmoveq %rax, %r15
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0x228d9
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x949c
testq %r14, %r14
jne 0x2281b
testq %rbp, %rbp
je 0x228f9
movq 0x2024a(%rip), %rax # 0x42b38
movq %rax, 0x28(%rbx)
movq %rbp, 0x2023f(%rip) # 0x42b38
movb $0x1, 0x20268(%rip) # 0x42b68
movl 0x8(%rsp), %ebp
movq 0x20(%rsp), %r15
movq 0x18(%rsp), %r13
movq 0x10(%rsp), %r14
movq %r14, %rdi
movl $0x2f, %esi
callq 0x75b0
leaq 0x1(%rax), %rbx
testq %rax, %rax
cmoveq %r14, %rbx
movq %rbx, %rdi
movl $0x2e, %esi
callq 0x71b0
testq %rax, %rax
je 0x22945
movq %rax, %r12
subq %rbx, %r12
jmp 0x22950
movq %rbx, %rdi
callq 0x7200
movq %rax, %r12
cmpq $0x4, %r12
jb 0x22968
leaq -0x4(%r12), %rax
cmpl $0x6c6e692d, -0x4(%rbx,%r12) # imm = 0x6C6E692D
cmoveq %rax, %r12
movq 0x201c9(%rip), %r14 # 0x42b38
movq %r13, %rax
testq %r14, %r14
je 0x229a2
movq (%r14), %rdi
movq 0x8(%r14), %rsi
movq %rbx, %rdx
movq %r12, %rcx
callq 0x22504
testb %al, %al
jne 0x2299b
movq 0x28(%r14), %r14
testq %r14, %r14
jne 0x22977
movq %r13, %rax
jmp 0x229a2
addq $0x20, %r14
movq %r14, %rax
cmpb $0x0, 0x7(%rsp)
je 0x229d2
movq %rax, (%r15)
cmpq %r13, %rax
jne 0x229d2
cmpq $0x0, 0x8(%r15)
jne 0x229d2
movq %rbx, 0x8(%r15)
movq %r12, 0x10(%r15)
movq 0x20179(%rip), %rcx # 0x42b40
movq %rcx, 0x18(%r15)
movq %r15, 0x2016e(%rip) # 0x42b40
cmpl %ebp, (%rax)
setge %bl
leaq 0x20192(%rip), %rdi # 0x42b70
callq 0x73f0
movl %ebx, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x7350
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0x22a1a
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x949c
jmp 0x22a1a
movq %rax, %rbx
leaq 0x2014f(%rip), %rdi # 0x42b70
callq 0x73f0
movq %rbx, %rdi
callq 0x7950
|
_ZN5nglog15InitializeVLOG3EPNS_8SiteFlagEPiPKci:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov ebp, ecx
mov r14, rdx
mov r13, rsi
mov r15, rdi
lea rdi, _ZN5nglogL13vmodule_mutexE; nglog::vmodule_mutex
call _pthread_mutex_lock
test eax, eax
jnz loc_229F4
mov al, cs:_ZN5nglogL14inited_vmoduleE; nglog::inited_vmodule
mov [rsp+78h+var_71], al
test al, al
jnz loc_22913
mov [rsp+78h+var_68], r14
mov [rsp+78h+var_60], r13
mov [rsp+78h+var_58], r15
mov [rsp+78h+var_70], ebp
mov cs:_ZN5nglogL14inited_vmoduleE, 0; nglog::inited_vmodule
lea rax, _ZN3fLS13FLAGS_vmoduleB5cxx11E; fLS::FLAGS_vmodule
mov rax, [rax]
mov r15, [rax]
lea r12, [rsp+78h+var_40]
lea r13, [rsp+78h+var_50]
xor ebp, ebp
xor ebx, ebx
loc_2281B:
mov rdi, r15
mov esi, 3Dh ; '='
call _strchr
test rax, rax
jz loc_228E2
mov r14, rax
mov [rsp+78h+var_50], r12
mov rdi, r13
mov rsi, r15
mov rdx, rax
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rdi, r14
lea rsi, aD; "=%d"
lea rdx, [rsp+78h+var_6C]
xor eax, eax
call ___isoc99_sscanf
cmp eax, 1
jnz short loc_228A7
mov edi, 30h ; '0'; unsigned __int64
call _Znwm; operator new(ulong)
mov r15, rax
add rax, 10h
mov [r15], rax
mov qword ptr [r15+8], 0
mov byte ptr [r15+10h], 0
mov rdi, r15
mov rsi, r13
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&)
mov eax, [rsp+78h+var_6C]
mov [r15+20h], eax
test rbp, rbp
jz short loc_228A1
mov [rbx+28h], r15
jmp short loc_228A4
loc_228A1:
mov rbp, r15
loc_228A4:
mov rbx, r15
loc_228A7:
mov rdi, r14
mov esi, 2Ch ; ','
call _strchr
mov r14, rax
lea r15, [rax+1]
test rax, rax
cmovz r15, rax
mov rdi, [rsp+78h+var_50]; void *
cmp rdi, r12
jz short loc_228D9
mov rsi, [rsp+78h+var_40]
inc rsi; unsigned __int64
call _ZdlPvm; operator delete(void *,ulong)
loc_228D9:
test r14, r14
jnz loc_2281B
loc_228E2:
test rbp, rbp
jz short loc_228F9
mov rax, cs:_ZN5nglogL12vmodule_listE; nglog::vmodule_list
mov [rbx+28h], rax
mov cs:_ZN5nglogL12vmodule_listE, rbp; nglog::vmodule_list
loc_228F9:
mov cs:_ZN5nglogL14inited_vmoduleE, 1; nglog::inited_vmodule
mov ebp, [rsp+78h+var_70]
mov r15, [rsp+78h+var_58]
mov r13, [rsp+78h+var_60]
mov r14, [rsp+78h+var_68]
loc_22913:
mov rdi, r14
mov esi, 2Fh ; '/'
call _strrchr
lea rbx, [rax+1]
test rax, rax
cmovz rbx, r14
mov rdi, rbx
mov esi, 2Eh ; '.'
call _strchr
test rax, rax
jz short loc_22945
mov r12, rax
sub r12, rbx
jmp short loc_22950
loc_22945:
mov rdi, rbx
call _strlen
mov r12, rax
loc_22950:
cmp r12, 4
jb short loc_22968
lea rax, [r12-4]
cmp dword ptr [rbx+r12-4], 6C6E692Dh
cmovz r12, rax
loc_22968:
mov r14, cs:_ZN5nglogL12vmodule_listE; nglog::vmodule_list
mov rax, r13
test r14, r14
jz short loc_229A2
loc_22977:
mov rdi, [r14]; this
mov rsi, [r14+8]; char *
mov rdx, rbx; unsigned __int64
mov rcx, r12; char *
call _ZN5nglog5tools12SafeFNMatch_EPKcmS2_m; nglog::tools::SafeFNMatch_(char const*,ulong,char const*,ulong)
test al, al
jnz short loc_2299B
mov r14, [r14+28h]
test r14, r14
jnz short loc_22977
mov rax, r13
jmp short loc_229A2
loc_2299B:
add r14, 20h ; ' '
mov rax, r14
loc_229A2:
cmp [rsp+78h+var_71], 0
jz short loc_229D2
mov [r15], rax
cmp rax, r13
jnz short loc_229D2
cmp qword ptr [r15+8], 0
jnz short loc_229D2
mov [r15+8], rbx
mov [r15+10h], r12
mov rcx, cs:_ZN5nglogL16cached_site_listE; nglog::cached_site_list
mov [r15+18h], rcx
mov cs:_ZN5nglogL16cached_site_listE, r15; nglog::cached_site_list
loc_229D2:
cmp [rax], ebp
setnl bl
lea rdi, _ZN5nglogL13vmodule_mutexE; nglog::vmodule_mutex
call _pthread_mutex_unlock
mov eax, ebx
add rsp, 48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_229F4:
mov edi, eax; int
call __ZSt20__throw_system_errori; std::__throw_system_error(int)
mov rbx, rax
mov rdi, [rsp+78h+var_50]; void *
cmp rdi, r12
jz short loc_22A1A
mov rsi, [rsp+78h+var_40]
inc rsi; unsigned __int64
call _ZdlPvm; operator delete(void *,ulong)
jmp short loc_22A1A
mov rbx, rax
loc_22A1A:
lea rdi, _ZN5nglogL13vmodule_mutexE; nglog::vmodule_mutex
call _pthread_mutex_unlock
mov rdi, rbx
call __Unwind_Resume
|
long long nglog::InitializeVLOG3(_QWORD *a1, _DWORD *a2, long long a3, int a4)
{
_DWORD *v6; // r13
_QWORD *v7; // r15
int v8; // eax
_BYTE *v9; // r15
long long v10; // rbp
long long v11; // rbx
long long v12; // rax
long long v13; // r14
long long v14; // r15
long long v15; // r14
long long v16; // rax
long long v17; // rbx
long long v18; // rax
unsigned long long v19; // r8
const char *v20; // r12
long long v21; // r14
_DWORD *v22; // rax
char v24; // [rsp+7h] [rbp-71h]
int v25; // [rsp+8h] [rbp-70h]
int v26; // [rsp+Ch] [rbp-6Ch] BYREF
long long v27; // [rsp+10h] [rbp-68h]
_DWORD *v28; // [rsp+18h] [rbp-60h]
_QWORD *v29; // [rsp+20h] [rbp-58h]
void *v30[2]; // [rsp+28h] [rbp-50h] BYREF
_QWORD v31[8]; // [rsp+38h] [rbp-40h] BYREF
v6 = a2;
v7 = a1;
v8 = pthread_mutex_lock(&nglog::vmodule_mutex);
if ( v8 )
std::__throw_system_error(v8);
v24 = nglog::inited_vmodule;
if ( !nglog::inited_vmodule )
{
v27 = a3;
v28 = a2;
v29 = a1;
v25 = a4;
nglog::inited_vmodule = 0;
v9 = (_BYTE *)fLS::FLAGS_vmodule_buf[abi:cxx11];
v10 = 0LL;
v11 = 0LL;
do
{
v12 = strchr(v9, 61LL);
if ( !v12 )
break;
v13 = v12;
v30[0] = v31;
std::string::_M_construct<char const*>(v30, v9, v12);
if ( (unsigned int)__isoc99_sscanf(v13, "=%d", &v26) == 1 )
{
v14 = operator new(48LL);
*(_QWORD *)v14 = v14 + 16;
*(_QWORD *)(v14 + 8) = 0LL;
*(_BYTE *)(v14 + 16) = 0;
std::string::_M_assign(v14, v30);
*(_DWORD *)(v14 + 32) = v26;
if ( v10 )
*(_QWORD *)(v11 + 40) = v14;
else
v10 = v14;
v11 = v14;
}
v15 = strchr(v13, 44LL);
v9 = (_BYTE *)(v15 + 1);
if ( !v15 )
v9 = 0LL;
if ( v30[0] != v31 )
operator delete(v30[0]);
}
while ( v15 );
if ( v10 )
{
*(_QWORD *)(v11 + 40) = nglog::vmodule_list;
nglog::vmodule_list = v10;
}
nglog::inited_vmodule = 1;
a4 = v25;
v7 = v29;
v6 = v28;
a3 = v27;
}
v16 = strrchr(a3, 47LL);
v17 = v16 + 1;
if ( !v16 )
v17 = a3;
v18 = strchr(v17, 46LL);
if ( v18 )
v20 = (const char *)(v18 - v17);
else
v20 = (const char *)strlen(v17);
if ( (unsigned long long)v20 >= 4 && *(_DWORD *)&v20[v17 - 4] == 1819175213 )
v20 -= 4;
v21 = nglog::vmodule_list;
v22 = v6;
if ( nglog::vmodule_list )
{
while ( !nglog::tools::SafeFNMatch_(*(nglog::tools **)v21, *(const char **)(v21 + 8), v17, v20, v19) )
{
v21 = *(_QWORD *)(v21 + 40);
if ( !v21 )
{
v22 = v6;
goto LABEL_31;
}
}
v22 = (_DWORD *)(v21 + 32);
}
LABEL_31:
if ( v24 )
{
*v7 = v22;
if ( v22 == v6 && !v7[1] )
{
v7[1] = v17;
v7[2] = v20;
v7[3] = nglog::cached_site_list;
nglog::cached_site_list = (long long)v7;
}
}
LOBYTE(v17) = *v22 >= a4;
pthread_mutex_unlock(&nglog::vmodule_mutex);
return (unsigned int)v17;
}
|
InitializeVLOG3:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV EBP,ECX
MOV R14,RDX
MOV R13,RSI
MOV R15,RDI
LEA RDI,[0x142b70]
CALL 0x001077f0
TEST EAX,EAX
JNZ 0x001229f4
MOV AL,byte ptr [0x00142b68]
MOV byte ptr [RSP + 0x7],AL
TEST AL,AL
JNZ 0x00122913
MOV qword ptr [RSP + 0x10],R14
MOV qword ptr [RSP + 0x18],R13
MOV qword ptr [RSP + 0x20],R15
MOV dword ptr [RSP + 0x8],EBP
MOV byte ptr [0x00142b68],0x0
LEA RAX,[0x130538]
MOV RAX,qword ptr [RAX]
MOV R15,qword ptr [RAX]
LEA R12,[RSP + 0x38]
LEA R13,[RSP + 0x28]
XOR EBP,EBP
XOR EBX,EBX
LAB_0012281b:
MOV RDI,R15
MOV ESI,0x3d
CALL 0x001071b0
TEST RAX,RAX
JZ 0x001228e2
MOV R14,RAX
MOV qword ptr [RSP + 0x28],R12
LAB_00122839:
MOV RDI,R13
MOV RSI,R15
MOV RDX,RAX
CALL 0x0010a556
MOV RDI,R14
LEA RSI,[0x1253fe]
LEA RDX,[RSP + 0xc]
XOR EAX,EAX
CALL 0x00107500
CMP EAX,0x1
JNZ 0x001228a7
LAB_00122862:
MOV EDI,0x30
CALL 0x00109450
MOV R15,RAX
ADD RAX,0x10
MOV qword ptr [R15],RAX
MOV qword ptr [R15 + 0x8],0x0
MOV byte ptr [R15 + 0x10],0x0
MOV RDI,R15
MOV RSI,R13
CALL 0x001072a0
LAB_0012288e:
MOV EAX,dword ptr [RSP + 0xc]
MOV dword ptr [R15 + 0x20],EAX
TEST RBP,RBP
JZ 0x001228a1
MOV qword ptr [RBX + 0x28],R15
JMP 0x001228a4
LAB_001228a1:
MOV RBP,R15
LAB_001228a4:
MOV RBX,R15
LAB_001228a7:
MOV RDI,R14
MOV ESI,0x2c
CALL 0x001071b0
MOV R14,RAX
LEA R15,[RAX + 0x1]
TEST RAX,RAX
CMOVZ R15,RAX
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R12
JZ 0x001228d9
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x0010949c
LAB_001228d9:
TEST R14,R14
JNZ 0x0012281b
LAB_001228e2:
TEST RBP,RBP
JZ 0x001228f9
MOV RAX,qword ptr [0x00142b38]
MOV qword ptr [RBX + 0x28],RAX
MOV qword ptr [0x00142b38],RBP
LAB_001228f9:
MOV byte ptr [0x00142b68],0x1
MOV EBP,dword ptr [RSP + 0x8]
MOV R15,qword ptr [RSP + 0x20]
MOV R13,qword ptr [RSP + 0x18]
MOV R14,qword ptr [RSP + 0x10]
LAB_00122913:
MOV RDI,R14
MOV ESI,0x2f
CALL 0x001075b0
LEA RBX,[RAX + 0x1]
TEST RAX,RAX
CMOVZ RBX,R14
MOV RDI,RBX
MOV ESI,0x2e
CALL 0x001071b0
TEST RAX,RAX
JZ 0x00122945
MOV R12,RAX
SUB R12,RBX
JMP 0x00122950
LAB_00122945:
MOV RDI,RBX
CALL 0x00107200
MOV R12,RAX
LAB_00122950:
CMP R12,0x4
JC 0x00122968
LEA RAX,[R12 + -0x4]
CMP dword ptr [RBX + R12*0x1 + -0x4],0x6c6e692d
CMOVZ R12,RAX
LAB_00122968:
MOV R14,qword ptr [0x00142b38]
MOV RAX,R13
TEST R14,R14
JZ 0x001229a2
LAB_00122977:
MOV RDI,qword ptr [R14]
MOV RSI,qword ptr [R14 + 0x8]
MOV RDX,RBX
MOV RCX,R12
CALL 0x00122504
TEST AL,AL
JNZ 0x0012299b
MOV R14,qword ptr [R14 + 0x28]
TEST R14,R14
JNZ 0x00122977
MOV RAX,R13
JMP 0x001229a2
LAB_0012299b:
ADD R14,0x20
MOV RAX,R14
LAB_001229a2:
CMP byte ptr [RSP + 0x7],0x0
JZ 0x001229d2
MOV qword ptr [R15],RAX
CMP RAX,R13
JNZ 0x001229d2
CMP qword ptr [R15 + 0x8],0x0
JNZ 0x001229d2
MOV qword ptr [R15 + 0x8],RBX
MOV qword ptr [R15 + 0x10],R12
MOV RCX,qword ptr [0x00142b40]
MOV qword ptr [R15 + 0x18],RCX
MOV qword ptr [0x00142b40],R15
LAB_001229d2:
CMP dword ptr [RAX],EBP
SETGE BL
LEA RDI,[0x142b70]
CALL 0x001073f0
MOV EAX,EBX
ADD RSP,0x48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001229f4:
MOV EDI,EAX
CALL 0x00107350
|
/* nglog::InitializeVLOG3(nglog::SiteFlag*, int*, char const*, int) */
ulong nglog::InitializeVLOG3(SiteFlag *param_1,int *param_2,char *param_3,int param_4)
{
char cVar1;
char cVar2;
int iVar3;
char *pcVar4;
string *psVar5;
string *psVar6;
char *pcVar7;
string *psVar8;
ulong uVar9;
string *psVar10;
int4 local_6c;
char *local_68;
string *local_60;
SiteFlag *local_58;
long *local_50 [2];
long local_40 [2];
iVar3 = pthread_mutex_lock((pthread_mutex_t *)vmodule_mutex);
cVar1 = inited_vmodule;
if (iVar3 != 0) {
/* WARNING: Subroutine does not return */
std::__throw_system_error(iVar3);
}
if (inited_vmodule == '\0') {
inited_vmodule = 0;
pcVar7 = *(char **)fLS::FLAGS_vmodule_abi_cxx11_;
psVar6 = (string *)0x0;
psVar10 = (string *)0x0;
local_68 = param_3;
local_60 = (string *)param_2;
local_58 = param_1;
do {
pcVar4 = strchr(pcVar7,0x3d);
psVar5 = psVar6;
psVar8 = psVar10;
if (pcVar4 == (char *)0x0) break;
local_50[0] = local_40;
/* try { // try from 00122839 to 00122846 has its CatchHandler @ 00122a17 */
std::__cxx11::string::_M_construct<char_const*>(local_50,pcVar7,pcVar4);
iVar3 = __isoc99_sscanf(pcVar4,&DAT_001253fe,&local_6c);
if (iVar3 == 1) {
/* try { // try from 00122862 to 0012288d has its CatchHandler @ 001229fb */
psVar5 = (string *)operator_new(0x30);
*(string **)psVar5 = psVar5 + 0x10;
*(int8 *)(psVar5 + 8) = 0;
psVar5[0x10] = (string)0x0;
std::__cxx11::string::_M_assign(psVar5);
*(int4 *)(psVar5 + 0x20) = local_6c;
psVar8 = psVar5;
if (psVar10 != (string *)0x0) {
*(string **)(psVar6 + 0x28) = psVar5;
psVar8 = psVar10;
}
}
pcVar4 = strchr(pcVar4,0x2c);
pcVar7 = pcVar4 + 1;
if (pcVar4 == (char *)0x0) {
pcVar7 = (char *)0x0;
}
if (local_50[0] != local_40) {
operator_delete(local_50[0],local_40[0] + 1);
}
psVar6 = psVar5;
psVar10 = psVar8;
} while (pcVar4 != (char *)0x0);
if (psVar8 != (string *)0x0) {
*(string **)(psVar5 + 0x28) = vmodule_list;
vmodule_list = psVar8;
}
inited_vmodule = '\x01';
param_2 = (int *)local_60;
param_3 = local_68;
param_1 = local_58;
}
pcVar4 = strrchr(param_3,0x2f);
pcVar7 = pcVar4 + 1;
if (pcVar4 == (char *)0x0) {
pcVar7 = param_3;
}
pcVar4 = strchr(pcVar7,0x2e);
if (pcVar4 == (char *)0x0) {
uVar9 = strlen(pcVar7);
}
else {
uVar9 = (long)pcVar4 - (long)pcVar7;
}
psVar6 = vmodule_list;
if ((3 < uVar9) && (*(int *)(pcVar7 + (uVar9 - 4)) == 0x6c6e692d)) {
uVar9 = uVar9 - 4;
}
do {
psVar10 = (string *)param_2;
if (psVar6 == (string *)0x0) {
LAB_001229a2:
if (((cVar1 != '\0') && (*(string **)param_1 = psVar10, psVar10 == (string *)param_2)) &&
(*(long *)(param_1 + 8) == 0)) {
*(char **)(param_1 + 8) = pcVar7;
*(ulong *)(param_1 + 0x10) = uVar9;
*(SiteFlag **)(param_1 + 0x18) = cached_site_list;
cached_site_list = param_1;
}
iVar3 = *(int *)psVar10;
pthread_mutex_unlock((pthread_mutex_t *)vmodule_mutex);
return CONCAT71((int7)((ulong)pcVar7 >> 8),param_4 <= iVar3) & 0xffffffff;
}
cVar2 = tools::SafeFNMatch_(*(char **)psVar6,*(ulong *)(psVar6 + 8),pcVar7,uVar9);
if (cVar2 != '\0') {
psVar10 = psVar6 + 0x20;
goto LAB_001229a2;
}
psVar6 = *(string **)(psVar6 + 0x28);
} while( true );
}
|
|
64,889 |
minja::Expression::evaluate(std::shared_ptr<minja::Context> const&) const
|
monkey531[P]llama/common/minja.hpp
|
Value evaluate(const std::shared_ptr<Context> & context) const {
try {
return do_evaluate(context);
} catch (const std::exception & e) {
std::ostringstream out;
out << e.what();
if (location.source) out << error_location_suffix(*location.source, location.pos);
throw std::runtime_error(out.str());
}
}
|
O3
|
cpp
|
minja::Expression::evaluate(std::shared_ptr<minja::Context> const&) const:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x1a0, %rsp # imm = 0x1A0
movq %rsi, %r14
movq %rdi, %rbx
movq (%rsi), %rax
callq *(%rax)
movq %rbx, %rax
addq $0x1a0, %rsp # imm = 0x1A0
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
cmpl $0x1, %edx
jne 0x3eaa8
movq %rbx, %rdi
callq 0x182a0
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x188a0
movq (%rbx), %rax
movq %rbx, %rdi
callq *0x10(%rax)
leaq 0x28(%rsp), %rdi
movq %rax, %rsi
callq 0x18670
movq 0x8(%r14), %rsi
testq %rsi, %rsi
jne 0x3e9e7
movl $0x10, %edi
callq 0x18350
movq %rax, %r14
leaq 0x30(%rsp), %rsi
leaq 0x8(%rsp), %rdi
callq 0x18a60
movb $0x1, %bpl
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
callq 0x18aa0
xorl %ebp, %ebp
movq 0x9f618(%rip), %rsi # 0xddff0
movq 0x9f591(%rip), %rdx # 0xddf70
movq %r14, %rdi
callq 0x18b50
movq 0x18(%r14), %rdx
leaq 0x8(%rsp), %rdi
callq 0x2510c
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x28(%rsp), %rdi
callq 0x18770
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3e9a3
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
jmp 0x3e9a3
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3ea80
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
jmp 0x3ea80
jmp 0x3ea7d
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x3ea69
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
testb %bpl, %bpl
jne 0x3ea73
jmp 0x3ea80
movq %rax, %rbx
movq %r14, %rdi
callq 0x184f0
jmp 0x3ea80
movq %rax, %rbx
movq 0x9f501(%rip), %rsi # 0xddf88
leaq 0x28(%rsp), %rdi
callq 0x183a0
leaq 0x98(%rsp), %rdi
callq 0x18200
jmp 0x3eaa3
movq %rax, %rbx
callq 0x18ad0
movq %rbx, %rdi
callq 0x18bc0
movq %rax, %rdi
callq 0x1d81b
|
_ZNK5minja10Expression8evaluateERKSt10shared_ptrINS_7ContextEE:
push rbp
push r14
push rbx
sub rsp, 1A0h
mov r14, rsi
mov rbx, rdi
mov rax, [rsi]
call qword ptr [rax]
mov rax, rbx
add rsp, 1A0h
pop rbx
pop r14
pop rbp
retn
mov rbx, rax
cmp edx, 1
jnz loc_3EAA8
mov rdi, rbx; void *
call ___cxa_begin_catch
mov rbx, rax
lea rdi, [rsp+arg_20]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::ostringstream::basic_ostringstream(void)
mov rax, [rbx]
mov rdi, rbx
call qword ptr [rax+10h]
lea rdi, [rsp+arg_20]
mov rsi, rax
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov rsi, [r14+8]; int
test rsi, rsi
jnz short loc_3E9E7
loc_3E9A3:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r14, rax
lea rsi, [rsp+arg_28]
lea rdi, [rsp+arg_0]
call __ZNKSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void)
mov bpl, 1
lea rsi, [rsp+arg_0]
mov rdi, r14
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
xor ebp, ebp
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r14; void *
call ___cxa_throw
loc_3E9E7:
mov rdx, [r14+18h]; int
lea rdi, [rsp+arg_0]; int
call _ZN5minjaL21error_location_suffixERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEm; minja::error_location_suffix(std::string const&,ulong)
mov rsi, qword ptr [rsp+arg_0]
mov rdx, [rsp+arg_8]
lea rdi, [rsp+arg_20]
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_3E9A3
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp loc_3E9A3
mov rbx, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_3EA80
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_3EA80
jmp short loc_3EA7D
mov rbx, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_3EA69
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_3EA69:
test bpl, bpl
jnz short loc_3EA73
jmp short loc_3EA80
mov rbx, rax
loc_3EA73:
mov rdi, r14; void *
call ___cxa_free_exception
jmp short loc_3EA80
loc_3EA7D:
mov rbx, rax
loc_3EA80:
mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+arg_20]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream()
lea rdi, [rsp+arg_90]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
jmp short loc_3EAA3
mov rbx, rax
loc_3EAA3:
call ___cxa_end_catch
loc_3EAA8:
mov rdi, rbx
call __Unwind_Resume
mov rdi, rax
call __clang_call_terminate
|
long long minja::Expression::evaluate(long long a1, void (***a2)(void))
{
(**a2)();
return a1;
}
|
evaluate:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x1a0
MOV R14,RSI
MOV RBX,RDI
MOV RAX,qword ptr [RSI]
LAB_0013e952:
CALL qword ptr [RAX]
LAB_0013e954:
MOV RAX,RBX
ADD RSP,0x1a0
POP RBX
POP R14
POP RBP
RET
|
/* minja::Expression::evaluate(std::shared_ptr<minja::Context> const&) const */
Expression * __thiscall minja::Expression::evaluate(Expression *this,shared_ptr *param_1)
{
/* try { // try from 0013e952 to 0013e953 has its CatchHandler @ 0013e963 */
(*(code *)**(int8 **)param_1)();
return this;
}
|
|
64,890 |
PFS_buffer_scalable_container<PFS_table_share, 4096, 4096, PFS_buffer_default_array<PFS_table_share>, PFS_buffer_default_allocator<PFS_table_share>>::apply(PFS_buffer_processor<PFS_table_share>&)
|
eloqsql/storage/perfschema/pfs_buffer_container.h
|
void apply(processor_type & proc)
{
uint i;
array_type *page;
value_type *pfs;
value_type *pfs_last;
for (i=0 ; i < PFS_PAGE_COUNT; i++)
{
page= m_pages[i];
if (page != NULL)
{
pfs= page->get_first();
pfs_last= page->get_last();
while (pfs < pfs_last)
{
if (pfs->m_lock.is_populated())
{
proc(pfs);
}
pfs++;
}
}
}
}
|
O0
|
c
|
PFS_buffer_scalable_container<PFS_table_share, 4096, 4096, PFS_buffer_default_array<PFS_table_share>, PFS_buffer_default_allocator<PFS_table_share>>::apply(PFS_buffer_processor<PFS_table_share>&):
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x38(%rbp)
movl $0x0, -0x14(%rbp)
cmpl $0x400, -0x14(%rbp) # imm = 0x400
jae 0x48b05
movq -0x38(%rbp), %rax
movl -0x14(%rbp), %ecx
movq 0xa8(%rax,%rcx,8), %rax
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x48af5
movq -0x20(%rbp), %rdi
callq 0x48e10
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rdi
callq 0x48e30
movq %rax, -0x30(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x30(%rbp), %rax
jae 0x48af3
movq -0x28(%rbp), %rdi
callq 0x2d950
testb $0x1, %al
jne 0x48ad5
jmp 0x48ae3
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq (%rdi), %rax
callq *0x10(%rax)
movq -0x28(%rbp), %rax
addq $0x340, %rax # imm = 0x340
movq %rax, -0x28(%rbp)
jmp 0x48abc
jmp 0x48af5
jmp 0x48af7
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x48a7f
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
_ZN29PFS_buffer_scalable_containerI15PFS_setup_actorLi128ELi1024E24PFS_buffer_default_arrayIS0_E28PFS_buffer_default_allocatorIS0_EE5applyER20PFS_buffer_processorIS0_E:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_8]
mov [rbp+var_38], rax
mov [rbp+var_14], 0
loc_48A7F:
cmp [rbp+var_14], 400h
jnb short loc_48B05
mov rax, [rbp+var_38]
mov ecx, [rbp+var_14]
mov rax, [rax+rcx*8+0A8h]
mov [rbp+var_20], rax
cmp [rbp+var_20], 0
jz short loc_48AF5
mov rdi, [rbp+var_20]
call _ZN24PFS_buffer_default_arrayI15PFS_setup_actorE9get_firstEv; PFS_buffer_default_array<PFS_setup_actor>::get_first(void)
mov [rbp+var_28], rax
mov rdi, [rbp+var_20]
call _ZN24PFS_buffer_default_arrayI15PFS_setup_actorE8get_lastEv; PFS_buffer_default_array<PFS_setup_actor>::get_last(void)
mov [rbp+var_30], rax
loc_48ABC:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_30]
jnb short loc_48AF3
mov rdi, [rbp+var_28]; this
call _ZN8pfs_lock12is_populatedEv; pfs_lock::is_populated(void)
test al, 1
jnz short loc_48AD5
jmp short loc_48AE3
loc_48AD5:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
mov rax, [rdi]
call qword ptr [rax+10h]
loc_48AE3:
mov rax, [rbp+var_28]
add rax, 340h
mov [rbp+var_28], rax
jmp short loc_48ABC
loc_48AF3:
jmp short $+2
loc_48AF5:
jmp short $+2
loc_48AF7:
mov eax, [rbp+var_14]
add eax, 1
mov [rbp+var_14], eax
jmp loc_48A7F
loc_48B05:
add rsp, 40h
pop rbp
retn
|
long long PFS_buffer_scalable_container<PFS_setup_actor,128,1024,PFS_buffer_default_array<PFS_setup_actor>,PFS_buffer_default_allocator<PFS_setup_actor>>::apply(
long long a1,
unsigned int *a2)
{
long long result; // rax
unsigned long long last; // [rsp+10h] [rbp-30h]
pfs_lock *first; // [rsp+18h] [rbp-28h]
long long v5; // [rsp+20h] [rbp-20h]
unsigned int i; // [rsp+2Ch] [rbp-14h]
unsigned int *v7; // [rsp+30h] [rbp-10h]
v7 = a2;
result = a1;
for ( i = 0; i < 0x400; ++i )
{
v5 = *(_QWORD *)(a1 + 8LL * i + 168);
if ( v5 )
{
first = (pfs_lock *)PFS_buffer_default_array<PFS_setup_actor>::get_first(v5);
last = PFS_buffer_default_array<PFS_setup_actor>::get_last(v5);
while ( (unsigned long long)first < last )
{
if ( pfs_lock::is_populated(first, a2) )
{
a2 = (unsigned int *)first;
(*(void ( **)(unsigned int *, pfs_lock *))(*(_QWORD *)v7 + 16LL))(v7, first);
}
first = (pfs_lock *)((char *)first + 832);
}
}
result = i + 1;
}
return result;
}
|
apply:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x38],RAX
MOV dword ptr [RBP + -0x14],0x0
LAB_00148a7f:
CMP dword ptr [RBP + -0x14],0x400
JNC 0x00148b05
MOV RAX,qword ptr [RBP + -0x38]
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RAX + RCX*0x8 + 0xa8]
MOV qword ptr [RBP + -0x20],RAX
CMP qword ptr [RBP + -0x20],0x0
JZ 0x00148af5
MOV RDI,qword ptr [RBP + -0x20]
CALL 0x00148e10
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x20]
CALL 0x00148e30
MOV qword ptr [RBP + -0x30],RAX
LAB_00148abc:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNC 0x00148af3
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x0012d950
TEST AL,0x1
JNZ 0x00148ad5
JMP 0x00148ae3
LAB_00148ad5:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x10]
LAB_00148ae3:
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x340
MOV qword ptr [RBP + -0x28],RAX
JMP 0x00148abc
LAB_00148af3:
JMP 0x00148af5
LAB_00148af5:
JMP 0x00148af7
LAB_00148af7:
MOV EAX,dword ptr [RBP + -0x14]
ADD EAX,0x1
MOV dword ptr [RBP + -0x14],EAX
JMP 0x00148a7f
LAB_00148b05:
ADD RSP,0x40
POP RBP
RET
|
/* PFS_buffer_scalable_container<PFS_setup_actor, 128, 1024,
PFS_buffer_default_array<PFS_setup_actor>, PFS_buffer_default_allocator<PFS_setup_actor>
>::apply(PFS_buffer_processor<PFS_setup_actor>&) */
void __thiscall
PFS_buffer_scalable_container<PFS_setup_actor,128,1024,PFS_buffer_default_array<PFS_setup_actor>,PFS_buffer_default_allocator<PFS_setup_actor>>
::apply(PFS_buffer_scalable_container<PFS_setup_actor,128,1024,PFS_buffer_default_array<PFS_setup_actor>,PFS_buffer_default_allocator<PFS_setup_actor>>
*this,PFS_buffer_processor *param_1)
{
PFS_buffer_default_array<PFS_setup_actor> *this_00;
pfs_lock *ppVar1;
ulong uVar2;
pfs_lock *local_30;
uint local_1c;
for (local_1c = 0; local_1c < 0x400; local_1c = local_1c + 1) {
this_00 = *(PFS_buffer_default_array<PFS_setup_actor> **)(this + (ulong)local_1c * 8 + 0xa8);
if (this_00 != (PFS_buffer_default_array<PFS_setup_actor> *)0x0) {
local_30 = (pfs_lock *)PFS_buffer_default_array<PFS_setup_actor>::get_first(this_00);
ppVar1 = (pfs_lock *)PFS_buffer_default_array<PFS_setup_actor>::get_last(this_00);
for (; local_30 < ppVar1; local_30 = local_30 + 0x340) {
uVar2 = pfs_lock::is_populated(local_30);
if ((uVar2 & 1) != 0) {
(**(code **)(*(long *)param_1 + 0x10))(param_1,local_30);
}
}
}
}
return;
}
|
|
64,891 |
ftxui::focusCursorUnderline(std::shared_ptr<ftxui::Node>)
|
Andrewchistyakov[P]flashcards_lyc/build_O3/_deps/ftxui-src/src/ftxui/dom/frame.cpp
|
Element focusCursorUnderline(Element child) {
return std::make_shared<FocusCursor>(unpack(std::move(child)),
Screen::Cursor::Underline);
}
|
O3
|
cpp
|
ftxui::focusCursorUnderline(std::shared_ptr<ftxui::Node>):
pushq %r15
pushq %r14
pushq %rbx
subq $0x70, %rsp
movq %rdi, %rbx
movups (%rsi), %xmm0
xorl %ecx, %ecx
movq %rcx, 0x8(%rsi)
leaq 0x20(%rsp), %rax
movaps %xmm0, (%rax)
movq %rcx, (%rsi)
movq %rsp, %rdi
movq %rax, %rsi
callq 0x22adb
movl $0x70, %edi
callq 0xb3e0
movq %rax, %r14
movabsq $0x100000001, %rax # imm = 0x100000001
movq %rax, 0x8(%r14)
leaq 0x20742(%rip), %rax # 0x58b68
movq %rax, (%r14)
movq %r14, %r15
addq $0x10, %r15
movq 0x10(%rsp), %rax
movaps (%rsp), %xmm0
xorl %ecx, %ecx
movq %rcx, 0x10(%rsp)
xorps %xmm1, %xmm1
movaps %xmm1, (%rsp)
leaq 0x50(%rsp), %rsi
movaps %xmm0, (%rsi)
movq %rax, 0x10(%rsi)
movaps %xmm1, 0x30(%rsp)
movq %rcx, 0x40(%rsp)
movq %r15, %rdi
callq 0x386a6
leaq 0x205fc(%rip), %rax # 0x58a68
movq %rax, 0x10(%r14)
leaq 0x50(%rsp), %rdi
callq 0x1503a
leaq 0x20737(%rip), %rax # 0x58bb8
movq %rax, 0x10(%r14)
movl $0x4, 0x6c(%r14)
leaq 0x30(%rsp), %rdi
callq 0x1503a
movq %r15, (%rbx)
movq %r14, 0x8(%rbx)
movq %rsp, %rdi
callq 0x1503a
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x384b5
callq 0x14af8
movq %rbx, %rax
addq $0x70, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x1503a
leaq 0x30(%rsp), %rdi
callq 0x1503a
movl $0x70, %esi
movq %r14, %rdi
callq 0xb400
jmp 0x384eb
movq %rax, %rbx
movq %rsp, %rdi
callq 0x1503a
jmp 0x384f8
movq %rax, %rbx
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x38507
callq 0x14af8
movq %rbx, %rdi
callq 0xb780
|
_ZN5ftxui20focusCursorUnderlineESt10shared_ptrINS_4NodeEE:
push r15
push r14
push rbx
sub rsp, 70h
mov rbx, rdi
movups xmm0, xmmword ptr [rsi]
xor ecx, ecx
mov [rsi+8], rcx
lea rax, [rsp+88h+var_68]
movaps xmmword ptr [rax], xmm0
mov [rsi], rcx
mov rdi, rsp
mov rsi, rax
call _ZN5ftxui6unpackIJSt10shared_ptrINS_4NodeEEEEESt6vectorIS3_SaIS3_EEDpT_; ftxui::unpack<std::shared_ptr<ftxui::Node>>(std::shared_ptr<ftxui::Node>)
mov edi, 70h ; 'p'; unsigned __int64
call __Znwm; operator new(ulong)
mov r14, rax
mov rax, 100000001h
mov [r14+8], rax
lea rax, off_58B68
mov [r14], rax
mov r15, r14
add r15, 10h
mov rax, [rsp+88h+var_78]
movaps xmm0, [rsp+88h+var_88]
xor ecx, ecx
mov [rsp+88h+var_78], rcx
xorps xmm1, xmm1
movaps [rsp+88h+var_88], xmm1
lea rsi, [rsp+88h+var_38]
movaps xmmword ptr [rsi], xmm0
mov [rsi+10h], rax
movaps [rsp+88h+var_58], xmm1
mov [rsp+88h+var_48], rcx
mov rdi, r15
call _ZN5ftxui12_GLOBAL__N_16SelectC2ESt6vectorISt10shared_ptrINS_4NodeEESaIS5_EE; ftxui::`anonymous namespace'::Select::Select(std::vector<std::shared_ptr<ftxui::Node>>)
lea rax, off_58A68
mov [r14+10h], rax
lea rdi, [rsp+88h+var_38]
call _ZNSt6vectorISt10shared_ptrIN5ftxui4NodeEESaIS3_EED2Ev; std::vector<std::shared_ptr<ftxui::Node>>::~vector()
lea rax, off_58BB8
mov [r14+10h], rax
mov dword ptr [r14+6Ch], 4
lea rdi, [rsp+88h+var_58]
call _ZNSt6vectorISt10shared_ptrIN5ftxui4NodeEESaIS3_EED2Ev; std::vector<std::shared_ptr<ftxui::Node>>::~vector()
mov [rbx], r15
mov [rbx+8], r14
mov rdi, rsp
call _ZNSt6vectorISt10shared_ptrIN5ftxui4NodeEESaIS3_EED2Ev; std::vector<std::shared_ptr<ftxui::Node>>::~vector()
mov rdi, [rsp+88h+var_60]
test rdi, rdi
jz short loc_384B5
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_384B5:
mov rax, rbx
add rsp, 70h
pop rbx
pop r14
pop r15
retn
mov rbx, rax
lea rdi, [rsp+arg_48]
call _ZNSt6vectorISt10shared_ptrIN5ftxui4NodeEESaIS3_EED2Ev; std::vector<std::shared_ptr<ftxui::Node>>::~vector()
lea rdi, [rsp+arg_28]
call _ZNSt6vectorISt10shared_ptrIN5ftxui4NodeEESaIS3_EED2Ev; std::vector<std::shared_ptr<ftxui::Node>>::~vector()
mov esi, 70h ; 'p'; unsigned __int64
mov rdi, r14; void *
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_384EB
mov rbx, rax
loc_384EB:
mov rdi, rsp
call _ZNSt6vectorISt10shared_ptrIN5ftxui4NodeEESaIS3_EED2Ev; std::vector<std::shared_ptr<ftxui::Node>>::~vector()
jmp short loc_384F8
mov rbx, rax
loc_384F8:
mov rdi, [rsp+arg_20]
test rdi, rdi
jz short loc_38507
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_38507:
mov rdi, rbx
call __Unwind_Resume
|
_QWORD * ftxui::focusCursorUnderline(_QWORD *a1, __int128 *a2)
{
__int128 v2; // xmm0
long long v3; // r14
long long v4; // rdx
long long v5; // r8
long long v6; // r9
__int128 v8; // [rsp+0h] [rbp-88h] BYREF
long long v9; // [rsp+10h] [rbp-78h]
__int128 v10; // [rsp+20h] [rbp-68h] BYREF
__int128 v11; // [rsp+30h] [rbp-58h] BYREF
long long v12; // [rsp+40h] [rbp-48h]
__int128 v13; // [rsp+50h] [rbp-38h] BYREF
long long v14; // [rsp+60h] [rbp-28h]
v2 = *a2;
*((_QWORD *)a2 + 1) = 0LL;
v10 = v2;
*(_QWORD *)a2 = 0LL;
ftxui::unpack<std::shared_ptr<ftxui::Node>>((long long)&v8, (long long)&v10);
v3 = operator new(0x70uLL);
*(_QWORD *)(v3 + 8) = 0x100000001LL;
*(_QWORD *)v3 = off_58B68;
v13 = v8;
v14 = v9;
v11 = 0LL;
v12 = 0LL;
ftxui::`anonymous namespace'::Select::Select(v3 + 16, &v13, v4, 0LL, v5, v6, 0LL, 0LL, 0LL);
*(_QWORD *)(v3 + 16) = off_58A68;
std::vector<std::shared_ptr<ftxui::Node>>::~vector((long long)&v13);
*(_QWORD *)(v3 + 16) = off_58BB8;
*(_DWORD *)(v3 + 108) = 4;
std::vector<std::shared_ptr<ftxui::Node>>::~vector((long long)&v11);
*a1 = v3 + 16;
a1[1] = v3;
std::vector<std::shared_ptr<ftxui::Node>>::~vector((long long)&v8);
if ( *((_QWORD *)&v10 + 1) )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(*((volatile signed __int32 **)&v10 + 1));
return a1;
}
|
focusCursorUnderline:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x70
MOV RBX,RDI
MOVUPS XMM0,xmmword ptr [RSI]
XOR ECX,ECX
MOV qword ptr [RSI + 0x8],RCX
LEA RAX,[RSP + 0x20]
MOVAPS xmmword ptr [RAX],XMM0
MOV qword ptr [RSI],RCX
LAB_001383f9:
MOV RDI,RSP
MOV RSI,RAX
CALL 0x00122adb
LAB_00138404:
MOV EDI,0x70
CALL 0x0010b3e0
MOV R14,RAX
MOV RAX,0x100000001
MOV qword ptr [R14 + 0x8],RAX
LEA RAX,[0x158b68]
MOV qword ptr [R14],RAX
MOV R15,R14
ADD R15,0x10
MOV RAX,qword ptr [RSP + 0x10]
MOVAPS XMM0,xmmword ptr [RSP]
XOR ECX,ECX
MOV qword ptr [RSP + 0x10],RCX
XORPS XMM1,XMM1
MOVAPS xmmword ptr [RSP],XMM1
LEA RSI,[RSP + 0x50]
MOVAPS xmmword ptr [RSI],XMM0
MOV qword ptr [RSI + 0x10],RAX
MOVAPS xmmword ptr [RSP + 0x30],XMM1
MOV qword ptr [RSP + 0x40],RCX
LAB_0013845d:
MOV RDI,R15
CALL 0x001386a6
LAB_00138465:
LEA RAX,[0x158a68]
MOV qword ptr [R14 + 0x10],RAX
LEA RDI,[RSP + 0x50]
CALL 0x0011503a
LEA RAX,[0x158bb8]
MOV qword ptr [R14 + 0x10],RAX
MOV dword ptr [R14 + 0x6c],0x4
LEA RDI,[RSP + 0x30]
CALL 0x0011503a
MOV qword ptr [RBX],R15
MOV qword ptr [RBX + 0x8],R14
MOV RDI,RSP
CALL 0x0011503a
MOV RDI,qword ptr [RSP + 0x28]
TEST RDI,RDI
JZ 0x001384b5
CALL 0x00114af8
LAB_001384b5:
MOV RAX,RBX
ADD RSP,0x70
POP RBX
POP R14
POP R15
RET
|
/* ftxui::focusCursorUnderline(std::shared_ptr<ftxui::Node>) */
ftxui * __thiscall ftxui::focusCursorUnderline(ftxui *this,int8 *param_2)
{
int8 *puVar1;
int8 local_88;
int8 uStack_80;
int8 local_78;
int4 local_68;
int4 uStack_64;
int4 uStack_60;
int4 uStack_5c;
int8 local_58;
int8 uStack_50;
int8 local_48;
int4 local_38;
int4 uStack_34;
int4 uStack_30;
int4 uStack_2c;
int8 local_28;
local_68 = *(int4 *)param_2;
uStack_64 = *(int4 *)((long)param_2 + 4);
uStack_60 = *(int4 *)(param_2 + 1);
uStack_5c = *(int4 *)((long)param_2 + 0xc);
param_2[1] = 0;
*param_2 = 0;
/* try { // try from 001383f9 to 00138403 has its CatchHandler @ 001384f5 */
unpack<std::shared_ptr<ftxui::Node>>((ftxui *)&local_88,&local_68);
/* try { // try from 00138404 to 0013840d has its CatchHandler @ 001384e8 */
puVar1 = (int8 *)operator_new(0x70);
local_28 = local_78;
puVar1[1] = 0x100000001;
*puVar1 = &PTR___Sp_counted_ptr_inplace_00158b68;
local_38 = (int4)local_88;
uStack_34 = local_88._4_4_;
uStack_30 = (int4)uStack_80;
uStack_2c = uStack_80._4_4_;
local_78 = 0;
local_88 = 0;
uStack_80 = 0;
local_58 = 0;
uStack_50 = 0;
local_48 = 0;
/* try { // try from 0013845d to 00138464 has its CatchHandler @ 001384c2 */
(anonymous_namespace)::Select::Select((Select *)(puVar1 + 2));
puVar1[2] = &PTR__Node_00158a68;
std::vector<std::shared_ptr<ftxui::Node>,std::allocator<std::shared_ptr<ftxui::Node>>>::~vector
((vector<std::shared_ptr<ftxui::Node>,std::allocator<std::shared_ptr<ftxui::Node>>> *)
&local_38);
puVar1[2] = &PTR__Node_00158bb8;
*(int4 *)((long)puVar1 + 0x6c) = 4;
std::vector<std::shared_ptr<ftxui::Node>,std::allocator<std::shared_ptr<ftxui::Node>>>::~vector
((vector<std::shared_ptr<ftxui::Node>,std::allocator<std::shared_ptr<ftxui::Node>>> *)
&local_58);
*(Select **)this = (Select *)(puVar1 + 2);
*(int8 **)(this + 8) = puVar1;
std::vector<std::shared_ptr<ftxui::Node>,std::allocator<std::shared_ptr<ftxui::Node>>>::~vector
((vector<std::shared_ptr<ftxui::Node>,std::allocator<std::shared_ptr<ftxui::Node>>> *)
&local_88);
if ((_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)CONCAT44(uStack_5c,uStack_60) !=
(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release
((_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)CONCAT44(uStack_5c,uStack_60));
}
return this;
}
|
|
64,892 |
ma_bitmap_flush_all
|
eloqsql/storage/maria/ma_bitmap.c
|
my_bool _ma_bitmap_flush_all(MARIA_SHARE *share)
{
my_bool res= 0;
uint send_signal= 0;
MARIA_FILE_BITMAP *bitmap= &share->bitmap;
DBUG_ENTER("_ma_bitmap_flush_all");
#ifdef EXTRA_DEBUG_BITMAP
{
char buff[160];
uint len= my_sprintf(buff,
(buff, "bitmap_flush: fd: %d id: %u "
"changed: %d changed_not_flushed: %d "
"flush_all_requested: %d",
share->bitmap.file.file,
share->id,
bitmap->changed,
bitmap->changed_not_flushed,
bitmap->flush_all_requested));
(void) translog_log_debug_info(0, LOGREC_DEBUG_INFO_QUERY,
(uchar*) buff, len);
}
#endif
mysql_mutex_lock(&bitmap->bitmap_lock);
if (!bitmap->changed && !bitmap->changed_not_flushed)
{
mysql_mutex_unlock(&bitmap->bitmap_lock);
DBUG_RETURN(0);
}
_ma_bitmap_mark_file_changed(share, 0);
/*
The following should be true as it was tested above. We have to test
this again as _ma_bitmap_mark_file_changed() did temporarly release
the bitmap mutex.
*/
if (bitmap->changed || bitmap->changed_not_flushed)
{
bitmap->flush_all_requested++;
bitmap->waiting_for_non_flushable++;
#if !WRONG_BITMAP_FLUSH
while (bitmap->non_flushable > 0)
{
DBUG_PRINT("info", ("waiting for bitmap to be flushable"));
mysql_cond_wait(&bitmap->bitmap_cond, &bitmap->bitmap_lock);
}
#endif
bitmap->waiting_for_non_flushable--;
#ifdef EXTRA_DEBUG_BITMAP
{
char tmp[MAX_BITMAP_INFO_LENGTH];
size_t len;
len= _ma_get_bitmap_description(bitmap, bitmap->map, bitmap->page, tmp);
(void) translog_log_debug_info(0, LOGREC_DEBUG_INFO_QUERY,
(uchar*) tmp, len);
}
#endif
DBUG_ASSERT(bitmap->flush_all_requested == 1);
/*
Bitmap is in a flushable state: its contents in memory are reflected by
log records (complete REDO-UNDO groups) and all bitmap pages are
unpinned. We keep the mutex to preserve this situation, and flush to the
file.
*/
if (bitmap->changed)
{
bitmap->changed= FALSE;
res= write_changed_bitmap(share, bitmap);
}
/*
We do NOT use FLUSH_KEEP_LAZY because we must be sure that bitmap
pages have been flushed. That's a condition of correctness of
Recovery: data pages may have been all flushed, if we write the
checkpoint record Recovery will start from after their REDOs. If
bitmap page was not flushed, as the REDOs about it will be skipped, it
will wrongly not be recovered. If bitmap pages had a rec_lsn it would
be different.
There should be no pinned pages as bitmap->non_flushable==0.
*/
if (flush_pagecache_blocks_with_filter(share->pagecache,
&bitmap->file, FLUSH_KEEP,
filter_flush_bitmap_pages,
&bitmap->pages_covered) &
PCFLUSH_PINNED_AND_ERROR)
res= TRUE;
bitmap->changed_not_flushed= FALSE;
bitmap->flush_all_requested--;
/*
Some well-behaved threads may be waiting for flush_all_requested to
become false, wake them up.
*/
DBUG_PRINT("info", ("bitmap flusher waking up others"));
send_signal= (bitmap->waiting_for_flush_all_requested |
bitmap->waiting_for_non_flushable);
}
mysql_mutex_unlock(&bitmap->bitmap_lock);
if (send_signal)
mysql_cond_broadcast(&bitmap->bitmap_cond);
DBUG_RETURN(res);
}
|
O3
|
c
|
ma_bitmap_flush_all:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdi, %rbx
leaq 0xa98(%rdi), %r14
cmpq $0x0, 0xad8(%rdi)
jne 0x3ff0e
movq %r14, %rdi
callq 0x29220
movb 0xa30(%rbx), %al
testb %al, %al
jne 0x3fd55
cmpb $0x0, 0xa31(%rbx)
je 0x3fedb
cmpb $0x0, 0x7df(%rbx)
jne 0x3fd6b
testb $0x1, 0x170(%rbx)
jne 0x3ff4e
testb %al, %al
jne 0x3fd7c
cmpb $0x0, 0xa31(%rbx)
je 0x3ff06
incl 0xa40(%rbx)
movl 0xa4c(%rbx), %ecx
leal 0x1(%rcx), %edx
movl %edx, 0xa4c(%rbx)
cmpl $0x0, 0xa48(%rbx)
je 0x3fdeb
leaq 0xae0(%rbx), %r15
leaq 0x99a6c(%rip), %r12 # 0xd9814
cmpq $0x0, 0xb10(%rbx)
jne 0x3fdc8
movq %r15, %rdi
movq %r14, %rsi
callq 0x29430
cmpl $0x0, 0xa48(%rbx)
jne 0x3fda8
jmp 0x3fddd
movq %r15, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl $0x204, %ecx # imm = 0x204
callq 0x2eea0
jmp 0x3fdbd
movl 0xa4c(%rbx), %ecx
movb 0xa30(%rbx), %al
decl %ecx
movl %ecx, 0xa4c(%rbx)
xorl %r15d, %r15d
testb %al, %al
je 0x3fe55
movw $0x100, 0xa30(%rbx) # imm = 0x100
movq 0x600(%rbx), %rdi
leaq 0xa50(%rbx), %rsi
movq 0xa20(%rbx), %rdx
movq 0xa18(%rbx), %r8
movl 0x80(%rdi), %eax
movl %eax, 0x30(%rsp)
movl %r15d, 0x28(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0x18(%rsp)
movl %r15d, 0x10(%rsp)
movl %r15d, (%rsp)
movl $0x1, 0x8(%rsp)
xorl %ecx, %ecx
movl $0x1, %r9d
callq 0x33a9e
movl %eax, %r15d
movq 0x600(%rbx), %rdi
leaq 0xa50(%rbx), %rsi
leaq 0xb48(%rbx), %r8
leaq 0x158(%rip), %rcx # 0x3ffc9
xorl %edx, %edx
callq 0x34194
testb $0x3, %al
movzbl %r15b, %eax
movl $0x1, %r15d
cmovel %eax, %r15d
movb $0x0, 0xa31(%rbx)
decl 0xa40(%rbx)
movl 0xa4c(%rbx), %eax
orl 0xa44(%rbx), %eax
sete %r12b
movq 0xad8(%rbx), %rdi
testq %rdi, %rdi
jne 0x3ff27
movq %r14, %rdi
callq 0x291e0
testb %r12b, %r12b
jne 0x3fef6
movq 0xb10(%rbx), %rdi
addq $0xae0, %rbx # imm = 0xAE0
testq %rdi, %rdi
jne 0x3ff3c
movq %rbx, %rdi
callq 0x296f0
jmp 0x3fef6
movq 0xad8(%rbx), %rdi
testq %rdi, %rdi
jne 0x3ff82
movq %r14, %rdi
callq 0x291e0
xorl %r15d, %r15d
movl %r15d, %eax
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movb $0x1, %r12b
xorl %r15d, %r15d
jmp 0x3fea5
leaq 0x998ff(%rip), %rsi # 0xd9814
movq %r14, %rdi
movl $0x1ee, %edx # imm = 0x1EE
callq 0x2eb8f
jmp 0x3fd3e
leaq 0x3460e2(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x3feb1
leaq 0x3460cd(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x178(%rax)
jmp 0x3fed1
movq 0xad8(%rbx), %rdi
testq %rdi, %rdi
jne 0x3ff97
movq %r14, %rdi
callq 0x291e0
movq %rbx, %rdi
callq 0x37efb
movq %r14, %rdi
movl $0x184, %esi # imm = 0x184
callq 0x3fcef
movb 0xa30(%rbx), %al
jmp 0x3fd6b
leaq 0x346087(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x3feeb
leaq 0x346072(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x3ff5a
|
_ma_bitmap_flush_all:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
sub rsp, 40h
mov rbx, rdi
lea r14, [rdi+0A98h]
cmp qword ptr [rdi+0AD8h], 0
jnz loc_3FF0E
mov rdi, r14
call _pthread_mutex_lock
loc_3FD3E:
mov al, [rbx+0A30h]
test al, al
jnz short loc_3FD55
cmp byte ptr [rbx+0A31h], 0
jz loc_3FEDB
loc_3FD55:
cmp byte ptr [rbx+7DFh], 0
jnz short loc_3FD6B
test byte ptr [rbx+170h], 1
jnz loc_3FF4E
loc_3FD6B:
test al, al
jnz short loc_3FD7C
cmp byte ptr [rbx+0A31h], 0
jz loc_3FF06
loc_3FD7C:
inc dword ptr [rbx+0A40h]
mov ecx, [rbx+0A4Ch]
lea edx, [rcx+1]
mov [rbx+0A4Ch], edx
cmp dword ptr [rbx+0A48h], 0
jz short loc_3FDEB
lea r15, [rbx+0AE0h]
lea r12, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/eloqsq"...
loc_3FDA8:
cmp qword ptr [rbx+0B10h], 0
jnz short loc_3FDC8
mov rdi, r15
mov rsi, r14
call _pthread_cond_wait
loc_3FDBD:
cmp dword ptr [rbx+0A48h], 0
jnz short loc_3FDA8
jmp short loc_3FDDD
loc_3FDC8:
mov rdi, r15
mov rsi, r14
mov rdx, r12
mov ecx, 204h
call psi_cond_wait
jmp short loc_3FDBD
loc_3FDDD:
mov ecx, [rbx+0A4Ch]
mov al, [rbx+0A30h]
dec ecx
loc_3FDEB:
mov [rbx+0A4Ch], ecx
xor r15d, r15d
test al, al
jz short loc_3FE55
mov word ptr [rbx+0A30h], 100h
mov rdi, [rbx+600h]
lea rsi, [rbx+0A50h]
mov rdx, [rbx+0A20h]
mov r8, [rbx+0A18h]
mov eax, [rdi+80h]
mov [rsp+60h+var_30], eax
mov [rsp+60h+var_38], r15d
xorps xmm0, xmm0
movups [rsp+60h+var_48], xmm0
mov [rsp+60h+var_50], r15d
mov [rsp+60h+var_60], r15d
mov [rsp+60h+var_58], 1
xor ecx, ecx
mov r9d, 1
call pagecache_write_part
mov r15d, eax
loc_3FE55:
mov rdi, [rbx+600h]
lea rsi, [rbx+0A50h]
lea r8, [rbx+0B48h]
lea rcx, filter_flush_bitmap_pages
xor edx, edx
call flush_pagecache_blocks_with_filter
test al, 3
movzx eax, r15b
mov r15d, 1
cmovz r15d, eax
mov byte ptr [rbx+0A31h], 0
dec dword ptr [rbx+0A40h]
mov eax, [rbx+0A4Ch]
or eax, [rbx+0A44h]
setz r12b
loc_3FEA5:
mov rdi, [rbx+0AD8h]
test rdi, rdi
jnz short loc_3FF27
loc_3FEB1:
mov rdi, r14
call _pthread_mutex_unlock
test r12b, r12b
jnz short loc_3FEF6
mov rdi, [rbx+0B10h]
add rbx, 0AE0h
test rdi, rdi
jnz short loc_3FF3C
loc_3FED1:
mov rdi, rbx
call _pthread_cond_broadcast
jmp short loc_3FEF6
loc_3FEDB:
mov rdi, [rbx+0AD8h]
test rdi, rdi
jnz loc_3FF82
loc_3FEEB:
mov rdi, r14
call _pthread_mutex_unlock
xor r15d, r15d
loc_3FEF6:
mov eax, r15d
add rsp, 40h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_3FF06:
mov r12b, 1
xor r15d, r15d
jmp short loc_3FEA5
loc_3FF0E:
lea rsi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, r14
mov edx, 1EEh
call psi_mutex_lock
jmp loc_3FD3E
loc_3FF27:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp loc_3FEB1
loc_3FF3C:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+178h]
jmp short loc_3FED1
loc_3FF4E:
mov rdi, [rbx+0AD8h]
test rdi, rdi
jnz short loc_3FF97
loc_3FF5A:
mov rdi, r14
call _pthread_mutex_unlock
mov rdi, rbx
call _ma_mark_file_changed_now
mov rdi, r14
mov esi, 184h
call inline_mysql_mutex_lock_0
mov al, [rbx+0A30h]
jmp loc_3FD6B
loc_3FF82:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp loc_3FEEB
loc_3FF97:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp short loc_3FF5A
|
long long ma_bitmap_flush_all(long long a1)
{
long long v1; // r14
char v2; // al
int v3; // ecx
unsigned __int8 v4; // r15
bool v5; // zf
unsigned int v6; // eax
unsigned int v7; // r15d
bool v8; // r12
v1 = a1 + 2712;
if ( *(_QWORD *)(a1 + 2776) )
psi_mutex_lock(a1 + 2712, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 0x1EEu);
else
pthread_mutex_lock(a1 + 2712);
v2 = *(_BYTE *)(a1 + 2608);
if ( v2 || *(_BYTE *)(a1 + 2609) )
{
if ( !*(_BYTE *)(a1 + 2015) && (*(_BYTE *)(a1 + 368) & 1) != 0 )
{
if ( *(_QWORD *)(a1 + 2776) )
PSI_server[44]();
pthread_mutex_unlock(v1);
ma_mark_file_changed_now(a1);
inline_mysql_mutex_lock_0(v1, 0x184u);
v2 = *(_BYTE *)(a1 + 2608);
}
if ( v2 || *(_BYTE *)(a1 + 2609) )
{
++*(_DWORD *)(a1 + 2624);
v3 = *(_DWORD *)(a1 + 2636);
*(_DWORD *)(a1 + 2636) = v3 + 1;
if ( *(_DWORD *)(a1 + 2632) )
{
do
{
if ( *(_QWORD *)(a1 + 2832) )
psi_cond_wait(
a1 + 2784,
v1,
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c",
0x204u);
else
pthread_cond_wait(a1 + 2784, v1);
}
while ( *(_DWORD *)(a1 + 2632) );
v2 = *(_BYTE *)(a1 + 2608);
v3 = *(_DWORD *)(a1 + 2636) - 1;
}
*(_DWORD *)(a1 + 2636) = v3;
v4 = 0;
if ( v2 )
{
*(_WORD *)(a1 + 2608) = 256;
v4 = pagecache_write_part(
*(__m128i **)(a1 + 1536),
(char *)(a1 + 2640),
*(_QWORD *)(a1 + 2592),
0,
*(char **)(a1 + 2584),
1,
0,
1u,
0,
0LL,
0LL,
0,
*(_DWORD *)(*(_QWORD *)(a1 + 1536) + 128LL));
}
v5 = (flush_pagecache_blocks_with_filter(
*(_QWORD *)(a1 + 1536),
a1 + 2640,
0,
(long long ( *)(long long, long long, _QWORD, long long))filter_flush_bitmap_pages,
a1 + 2888) & 3) == 0;
v6 = v4;
v7 = 1;
if ( v5 )
v7 = v6;
*(_BYTE *)(a1 + 2609) = 0;
--*(_DWORD *)(a1 + 2624);
v8 = (*(_DWORD *)(a1 + 2628) | *(_DWORD *)(a1 + 2636)) == 0;
}
else
{
v8 = 1;
v7 = 0;
}
if ( *(_QWORD *)(a1 + 2776) )
PSI_server[44]();
pthread_mutex_unlock(v1);
if ( !v8 )
{
if ( *(_QWORD *)(a1 + 2832) )
PSI_server[47]();
pthread_cond_broadcast(a1 + 2784);
}
}
else
{
if ( *(_QWORD *)(a1 + 2776) )
PSI_server[44]();
pthread_mutex_unlock(v1);
return 0;
}
return v7;
}
|
_ma_bitmap_flush_all:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x40
MOV RBX,RDI
LEA R14,[RDI + 0xa98]
CMP qword ptr [RDI + 0xad8],0x0
JNZ 0x0013ff0e
MOV RDI,R14
CALL 0x00129220
LAB_0013fd3e:
MOV AL,byte ptr [RBX + 0xa30]
TEST AL,AL
JNZ 0x0013fd55
CMP byte ptr [RBX + 0xa31],0x0
JZ 0x0013fedb
LAB_0013fd55:
CMP byte ptr [RBX + 0x7df],0x0
JNZ 0x0013fd6b
TEST byte ptr [RBX + 0x170],0x1
JNZ 0x0013ff4e
LAB_0013fd6b:
TEST AL,AL
JNZ 0x0013fd7c
CMP byte ptr [RBX + 0xa31],0x0
JZ 0x0013ff06
LAB_0013fd7c:
INC dword ptr [RBX + 0xa40]
MOV ECX,dword ptr [RBX + 0xa4c]
LEA EDX,[RCX + 0x1]
MOV dword ptr [RBX + 0xa4c],EDX
CMP dword ptr [RBX + 0xa48],0x0
JZ 0x0013fdeb
LEA R15,[RBX + 0xae0]
LEA R12,[0x1d9814]
LAB_0013fda8:
CMP qword ptr [RBX + 0xb10],0x0
JNZ 0x0013fdc8
MOV RDI,R15
MOV RSI,R14
CALL 0x00129430
LAB_0013fdbd:
CMP dword ptr [RBX + 0xa48],0x0
JNZ 0x0013fda8
JMP 0x0013fddd
LAB_0013fdc8:
MOV RDI,R15
MOV RSI,R14
MOV RDX,R12
MOV ECX,0x204
CALL 0x0012eea0
JMP 0x0013fdbd
LAB_0013fddd:
MOV ECX,dword ptr [RBX + 0xa4c]
MOV AL,byte ptr [RBX + 0xa30]
DEC ECX
LAB_0013fdeb:
MOV dword ptr [RBX + 0xa4c],ECX
XOR R15D,R15D
TEST AL,AL
JZ 0x0013fe55
MOV word ptr [RBX + 0xa30],0x100
MOV RDI,qword ptr [RBX + 0x600]
LEA RSI,[RBX + 0xa50]
MOV RDX,qword ptr [RBX + 0xa20]
MOV R8,qword ptr [RBX + 0xa18]
MOV EAX,dword ptr [RDI + 0x80]
MOV dword ptr [RSP + 0x30],EAX
MOV dword ptr [RSP + 0x28],R15D
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RSP + 0x18],XMM0
MOV dword ptr [RSP + 0x10],R15D
MOV dword ptr [RSP],R15D
MOV dword ptr [RSP + 0x8],0x1
XOR ECX,ECX
MOV R9D,0x1
CALL 0x00133a9e
MOV R15D,EAX
LAB_0013fe55:
MOV RDI,qword ptr [RBX + 0x600]
LEA RSI,[RBX + 0xa50]
LEA R8,[RBX + 0xb48]
LEA RCX,[0x13ffc9]
XOR EDX,EDX
CALL 0x00134194
TEST AL,0x3
MOVZX EAX,R15B
MOV R15D,0x1
CMOVZ R15D,EAX
MOV byte ptr [RBX + 0xa31],0x0
DEC dword ptr [RBX + 0xa40]
MOV EAX,dword ptr [RBX + 0xa4c]
OR EAX,dword ptr [RBX + 0xa44]
SETZ R12B
LAB_0013fea5:
MOV RDI,qword ptr [RBX + 0xad8]
TEST RDI,RDI
JNZ 0x0013ff27
LAB_0013feb1:
MOV RDI,R14
CALL 0x001291e0
TEST R12B,R12B
JNZ 0x0013fef6
MOV RDI,qword ptr [RBX + 0xb10]
ADD RBX,0xae0
TEST RDI,RDI
JNZ 0x0013ff3c
LAB_0013fed1:
MOV RDI,RBX
CALL 0x001296f0
JMP 0x0013fef6
LAB_0013fedb:
MOV RDI,qword ptr [RBX + 0xad8]
TEST RDI,RDI
JNZ 0x0013ff82
LAB_0013feeb:
MOV RDI,R14
CALL 0x001291e0
XOR R15D,R15D
LAB_0013fef6:
MOV EAX,R15D
ADD RSP,0x40
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_0013ff06:
MOV R12B,0x1
XOR R15D,R15D
JMP 0x0013fea5
LAB_0013ff0e:
LEA RSI,[0x1d9814]
MOV RDI,R14
MOV EDX,0x1ee
CALL 0x0012eb8f
JMP 0x0013fd3e
LAB_0013ff27:
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x0013feb1
LAB_0013ff3c:
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x178]
JMP 0x0013fed1
LAB_0013ff4e:
MOV RDI,qword ptr [RBX + 0xad8]
TEST RDI,RDI
JNZ 0x0013ff97
LAB_0013ff5a:
MOV RDI,R14
CALL 0x001291e0
MOV RDI,RBX
CALL 0x00137efb
MOV RDI,R14
MOV ESI,0x184
CALL 0x0013fcef
MOV AL,byte ptr [RBX + 0xa30]
JMP 0x0013fd6b
LAB_0013ff82:
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x0013feeb
LAB_0013ff97:
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x0013ff5a
|
int1 _ma_bitmap_flush_all(long param_1)
{
pthread_mutex_t *__mutex;
char cVar1;
int1 uVar2;
ulong uVar3;
int iVar4;
int1 uVar5;
bool bVar6;
__mutex = (pthread_mutex_t *)(param_1 + 0xa98);
if (*(long *)(param_1 + 0xad8) == 0) {
pthread_mutex_lock(__mutex);
}
else {
psi_mutex_lock(__mutex,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c",
0x1ee);
}
cVar1 = *(char *)(param_1 + 0xa30);
if ((cVar1 == '\0') && (*(char *)(param_1 + 0xa31) == '\0')) {
if (*(long *)(param_1 + 0xad8) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
uVar5 = 0;
}
else {
if ((*(char *)(param_1 + 0x7df) == '\0') && ((*(byte *)(param_1 + 0x170) & 1) != 0)) {
if (*(long *)(param_1 + 0xad8) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
_ma_mark_file_changed_now(param_1);
inline_mysql_mutex_lock(__mutex,0x184);
cVar1 = *(char *)(param_1 + 0xa30);
}
if ((cVar1 == '\0') && (*(char *)(param_1 + 0xa31) == '\0')) {
bVar6 = true;
uVar5 = 0;
}
else {
*(int *)(param_1 + 0xa40) = *(int *)(param_1 + 0xa40) + 1;
iVar4 = *(int *)(param_1 + 0xa4c);
*(int *)(param_1 + 0xa4c) = iVar4 + 1;
if (*(int *)(param_1 + 0xa48) != 0) {
do {
if (*(long *)(param_1 + 0xb10) == 0) {
pthread_cond_wait((pthread_cond_t *)(param_1 + 0xae0),__mutex);
}
else {
psi_cond_wait((pthread_cond_t *)(param_1 + 0xae0),__mutex,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c",0x204
);
}
} while (*(int *)(param_1 + 0xa48) != 0);
cVar1 = *(char *)(param_1 + 0xa30);
iVar4 = *(int *)(param_1 + 0xa4c) + -1;
}
*(int *)(param_1 + 0xa4c) = iVar4;
uVar2 = 0;
if (cVar1 != '\0') {
*(int2 *)(param_1 + 0xa30) = 0x100;
uVar2 = pagecache_write_part
(*(long *)(param_1 + 0x600),param_1 + 0xa50,
*(int8 *)(param_1 + 0xa20),0,*(int8 *)(param_1 + 0xa18),1,0,1
,0,0,0,0,*(int4 *)(*(long *)(param_1 + 0x600) + 0x80));
}
uVar3 = flush_pagecache_blocks_with_filter
(*(int8 *)(param_1 + 0x600),param_1 + 0xa50,0,
filter_flush_bitmap_pages,param_1 + 0xb48);
uVar5 = 1;
if ((uVar3 & 3) == 0) {
uVar5 = uVar2;
}
*(int1 *)(param_1 + 0xa31) = 0;
*(int *)(param_1 + 0xa40) = *(int *)(param_1 + 0xa40) + -1;
bVar6 = *(int *)(param_1 + 0xa4c) == 0 && *(int *)(param_1 + 0xa44) == 0;
}
if (*(long *)(param_1 + 0xad8) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
if (!bVar6) {
if (*(long *)(param_1 + 0xb10) != 0) {
(**(code **)(PSI_server + 0x178))();
}
pthread_cond_broadcast((pthread_cond_t *)(param_1 + 0xae0));
}
}
return uVar5;
}
|
|
64,893 |
my_is_symlink
|
eloqsql/mysys/my_symlink.c
|
int my_is_symlink(const char *filename __attribute__((unused)))
{
#if defined (HAVE_LSTAT) && defined (S_ISLNK)
struct stat stat_buff;
if (lstat(filename, &stat_buff))
return 0;
MSAN_STAT_WORKAROUND(&stat_buff);
return !!S_ISLNK(stat_buff.st_mode);
#elif defined (_WIN32)
DWORD dwAttr = GetFileAttributes(filename);
return (dwAttr != INVALID_FILE_ATTRIBUTES) &&
(dwAttr & FILE_ATTRIBUTE_REPARSE_POINT);
#else /* No symlinks */
return 0;
#endif
}
|
O0
|
c
|
my_is_symlink:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
callq 0x25460
cmpl $0x0, %eax
je 0x3344d
movl $0x0, -0x4(%rbp)
jmp 0x3346c
movl -0x88(%rbp), %eax
andl $0xf000, %eax # imm = 0xF000
cmpl $0xa000, %eax # imm = 0xA000
sete %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0xa0, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
my_is_symlink:
push rbp
mov rbp, rsp
sub rsp, 0A0h
mov [rbp+var_10], rdi
mov rdi, [rbp+var_10]
lea rsi, [rbp+var_A0]
call _lstat64
cmp eax, 0
jz short loc_3344D
mov [rbp+var_4], 0
jmp short loc_3346C
loc_3344D:
mov eax, [rbp+var_88]
and eax, 0F000h
cmp eax, 0A000h
setz al
xor al, 0FFh
xor al, 0FFh
and al, 1
movzx eax, al
mov [rbp+var_4], eax
loc_3346C:
mov eax, [rbp+var_4]
add rsp, 0A0h
pop rbp
retn
|
_BOOL8 my_is_symlink(long long a1)
{
_BYTE v2[24]; // [rsp+0h] [rbp-A0h] BYREF
int v3; // [rsp+18h] [rbp-88h]
long long v4; // [rsp+90h] [rbp-10h]
v4 = a1;
return !(unsigned int)lstat64(a1, v2) && (v3 & 0xF000) == 40960;
}
|
my_is_symlink:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xa0
MOV qword ptr [RBP + -0x10],RDI
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[RBP + -0xa0]
CALL 0x00125460
CMP EAX,0x0
JZ 0x0013344d
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0013346c
LAB_0013344d:
MOV EAX,dword ptr [RBP + -0x88]
AND EAX,0xf000
CMP EAX,0xa000
SETZ AL
XOR AL,0xff
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
MOV dword ptr [RBP + -0x4],EAX
LAB_0013346c:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0xa0
POP RBP
RET
|
bool my_is_symlink(char *param_1)
{
int iVar1;
stat64 local_a8;
char *local_18;
local_18 = param_1;
iVar1 = lstat64(param_1,&local_a8);
return iVar1 == 0 && (local_a8.st_mode & 0xf000) == 0xa000;
}
|
|
64,894 |
my_is_symlink
|
eloqsql/mysys/my_symlink.c
|
int my_is_symlink(const char *filename __attribute__((unused)))
{
#if defined (HAVE_LSTAT) && defined (S_ISLNK)
struct stat stat_buff;
if (lstat(filename, &stat_buff))
return 0;
MSAN_STAT_WORKAROUND(&stat_buff);
return !!S_ISLNK(stat_buff.st_mode);
#elif defined (_WIN32)
DWORD dwAttr = GetFileAttributes(filename);
return (dwAttr != INVALID_FILE_ATTRIBUTES) &&
(dwAttr & FILE_ATTRIBUTE_REPARSE_POINT);
#else /* No symlinks */
return 0;
#endif
}
|
O3
|
c
|
my_is_symlink:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x98, %rsp
leaq -0x98(%rbp), %rbx
movq %rbx, %rsi
callq 0x244a0
movl 0x18(%rbx), %edx
andl $0xf000, %edx # imm = 0xF000
xorl $0xa000, %edx # imm = 0xA000
xorl %ecx, %ecx
orl %eax, %edx
sete %cl
movl %ecx, %eax
addq $0x98, %rsp
popq %rbx
popq %rbp
retq
|
my_is_symlink:
push rbp
mov rbp, rsp
push rbx
sub rsp, 98h
lea rbx, [rbp+var_98]
mov rsi, rbx
call _lstat64
mov edx, [rbx+18h]
and edx, 0F000h
xor edx, 0A000h
xor ecx, ecx
or edx, eax
setz cl
mov eax, ecx
add rsp, 98h
pop rbx
pop rbp
retn
|
_BOOL8 my_is_symlink(long long a1)
{
int v1; // eax
_BYTE v3[24]; // [rsp+8h] [rbp-98h] BYREF
__int16 v4; // [rsp+20h] [rbp-80h]
v1 = lstat64(a1, v3);
return (v1 | v4 & 0xF000 ^ 0xA000) == 0;
}
|
my_is_symlink:
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x98
LEA RBX,[RBP + -0x98]
MOV RSI,RBX
CALL 0x001244a0
MOV EDX,dword ptr [RBX + 0x18]
AND EDX,0xf000
XOR EDX,0xa000
XOR ECX,ECX
OR EDX,EAX
SETZ CL
MOV EAX,ECX
ADD RSP,0x98
POP RBX
POP RBP
RET
|
bool my_is_symlink(char *param_1)
{
int iVar1;
stat64 local_a0;
iVar1 = lstat64(param_1,&local_a0);
return (local_a0.st_mode & 0xf000) == 0xa000 && iVar1 == 0;
}
|
|
64,895 |
ftb_find_relevance_add_word
|
eloqsql/storage/myisam/ft_boolean_search.c
|
static int ftb_find_relevance_add_word(MYSQL_FTPARSER_PARAM *param,
const char *word, int len,
MYSQL_FTPARSER_BOOLEAN_INFO *boolean_info __attribute__((unused)))
{
MY_FTB_FIND_PARAM *ftb_param= param->mysql_ftparam;
FT_INFO *ftb= ftb_param->ftb;
FTB_WORD *ftbw;
int a, b, c;
/*
Find right-most element in the array of query words matching this
word from a document.
*/
for (a= 0, b= ftb->queue.elements, c= (a+b)/2; b-a>1; c= (a+b)/2)
{
ftbw= ftb->list[c];
if (ha_compare_text(ftb->charset, (uchar*)word, len,
(uchar*)ftbw->word+1, ftbw->len-1,
(my_bool) (ftbw->flags & FTB_FLAG_TRUNC)) < 0)
b= c;
else
a= c;
}
/*
If there were no words with truncation operator, we iterate to the
beginning of an array until array element is equal to the word from
a document. This is done mainly because the same word may be
mentioned twice (or more) in the query.
In case query has words with truncation operator we must iterate
to the beginning of the array. There may be non-matching query words
between matching word with truncation operator and the right-most
matching element. E.g., if we're looking for 'aaa15' in an array of
'aaa1* aaa14 aaa15 aaa16'.
Worse of that there still may be match even if the binary search
above didn't find matching element. E.g., if we're looking for
'aaa15' in an array of 'aaa1* aaa14 aaa16'. The binary search will
stop at 'aaa16'.
*/
for (; c >= 0; c--)
{
ftbw= ftb->list[c];
if (ha_compare_text(ftb->charset, (uchar*)word, len,
(uchar*)ftbw->word + 1,ftbw->len - 1,
(my_bool)(ftbw->flags & FTB_FLAG_TRUNC)))
{
if (ftb->with_scan & FTB_FLAG_TRUNC)
continue;
else
break;
}
if (ftbw->docid[1] == ftb->info->lastpos)
continue;
ftbw->docid[1]= ftb->info->lastpos;
if (unlikely(_ftb_climb_the_tree(ftb, ftbw, ftb_param->ftsi)))
return 1;
}
return(0);
}
|
O0
|
c
|
ftb_find_relevance_add_word:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %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 (%rax), %rax
movq %rax, -0x38(%rbp)
movl $0x0, -0x44(%rbp)
movq -0x38(%rbp), %rax
movl 0x80(%rax), %eax
movl %eax, -0x48(%rbp)
movl -0x44(%rbp), %eax
addl -0x48(%rbp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, -0x4c(%rbp)
movl -0x48(%rbp), %eax
subl -0x44(%rbp), %eax
cmpl $0x1, %eax
jle 0xa23db
movq -0x38(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x4c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x40(%rbp)
movq -0x38(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x18(%rbp), %rsi
movslq -0x1c(%rbp), %rdx
movq -0x40(%rbp), %rcx
addq $0x4d, %rcx
addq $0x1, %rcx
movq -0x40(%rbp), %rax
movl 0x48(%rax), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %r8d
movq -0x40(%rbp), %rax
movl 0x8(%rax), %eax
andl $0x1, %eax
movsbl %al, %r9d
callq 0xf6c40
cmpl $0x0, %eax
jge 0xa23bd
movl -0x4c(%rbp), %eax
movl %eax, -0x48(%rbp)
jmp 0xa23c3
movl -0x4c(%rbp), %eax
movl %eax, -0x44(%rbp)
jmp 0xa23c5
movl -0x44(%rbp), %eax
addl -0x48(%rbp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, -0x4c(%rbp)
jmp 0xa2353
jmp 0xa23dd
cmpl $0x0, -0x4c(%rbp)
jl 0xa24c8
movq -0x38(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x4c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, -0x40(%rbp)
movq -0x38(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x18(%rbp), %rsi
movslq -0x1c(%rbp), %rdx
movq -0x40(%rbp), %rcx
addq $0x4d, %rcx
addq $0x1, %rcx
movq -0x40(%rbp), %rax
movl 0x48(%rax), %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %r8d
movq -0x40(%rbp), %rax
movl 0x8(%rax), %eax
andl $0x1, %eax
movsbl %al, %r9d
callq 0xf6c40
cmpl $0x0, %eax
je 0xa2455
movq -0x38(%rbp), %rax
movzbl 0x344(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xa2453
jmp 0xa24ba
jmp 0xa24c8
movq -0x40(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x38(%rbp), %rcx
movq 0x8(%rcx), %rcx
cmpq 0x170(%rcx), %rax
jne 0xa2470
jmp 0xa24ba
movq -0x38(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x170(%rax), %rcx
movq -0x40(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x38(%rbp), %rdi
movq -0x40(%rbp), %rsi
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rdx
callq 0xa1b00
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0xa24b8
movl $0x1, -0x4(%rbp)
jmp 0xa24cf
jmp 0xa24ba
movl -0x4c(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x4c(%rbp)
jmp 0xa23dd
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
ftb_find_relevance_add_word:
push rbp
mov rbp, rsp
sub rsp, 50h
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]
mov [rbp+var_38], rax
mov [rbp+var_44], 0
mov rax, [rbp+var_38]
mov eax, [rax+80h]
mov [rbp+var_48], eax
mov eax, [rbp+var_44]
add eax, [rbp+var_48]
mov ecx, 2
cdq
idiv ecx
mov [rbp+var_4C], eax
loc_A2353:
mov eax, [rbp+var_48]
sub eax, [rbp+var_44]
cmp eax, 1
jle short loc_A23DB
mov rax, [rbp+var_38]
mov rax, [rax+20h]
movsxd rcx, [rbp+var_4C]
mov rax, [rax+rcx*8]
mov [rbp+var_40], rax
mov rax, [rbp+var_38]
mov rdi, [rax+10h]
mov rsi, [rbp+var_18]
movsxd rdx, [rbp+var_1C]
mov rcx, [rbp+var_40]
add rcx, 4Dh ; 'M'
add rcx, 1
mov rax, [rbp+var_40]
mov eax, [rax+48h]
sub eax, 1
mov eax, eax
mov r8d, eax
mov rax, [rbp+var_40]
mov eax, [rax+8]
and eax, 1
movsx r9d, al
call ha_compare_text
cmp eax, 0
jge short loc_A23BD
mov eax, [rbp+var_4C]
mov [rbp+var_48], eax
jmp short loc_A23C3
loc_A23BD:
mov eax, [rbp+var_4C]
mov [rbp+var_44], eax
loc_A23C3:
jmp short $+2
loc_A23C5:
mov eax, [rbp+var_44]
add eax, [rbp+var_48]
mov ecx, 2
cdq
idiv ecx
mov [rbp+var_4C], eax
jmp loc_A2353
loc_A23DB:
jmp short $+2
loc_A23DD:
cmp [rbp+var_4C], 0
jl loc_A24C8
mov rax, [rbp+var_38]
mov rax, [rax+20h]
movsxd rcx, [rbp+var_4C]
mov rax, [rax+rcx*8]
mov [rbp+var_40], rax
mov rax, [rbp+var_38]
mov rdi, [rax+10h]
mov rsi, [rbp+var_18]
movsxd rdx, [rbp+var_1C]
mov rcx, [rbp+var_40]
add rcx, 4Dh ; 'M'
add rcx, 1
mov rax, [rbp+var_40]
mov eax, [rax+48h]
sub eax, 1
mov eax, eax
mov r8d, eax
mov rax, [rbp+var_40]
mov eax, [rax+8]
and eax, 1
movsx r9d, al
call ha_compare_text
cmp eax, 0
jz short loc_A2455
mov rax, [rbp+var_38]
movzx eax, byte ptr [rax+344h]
and eax, 1
cmp eax, 0
jz short loc_A2453
jmp short loc_A24BA
loc_A2453:
jmp short loc_A24C8
loc_A2455:
mov rax, [rbp+var_40]
mov rax, [rax+18h]
mov rcx, [rbp+var_38]
mov rcx, [rcx+8]
cmp rax, [rcx+170h]
jnz short loc_A2470
jmp short loc_A24BA
loc_A2470:
mov rax, [rbp+var_38]
mov rax, [rax+8]
mov rcx, [rax+170h]
mov rax, [rbp+var_40]
mov [rax+18h], rcx
mov rdi, [rbp+var_38]
mov rsi, [rbp+var_40]
mov rax, [rbp+var_30]
mov rdx, [rax+8]
call _ftb_climb_the_tree
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_A24B8
mov [rbp+var_4], 1
jmp short loc_A24CF
loc_A24B8:
jmp short $+2
loc_A24BA:
mov eax, [rbp+var_4C]
add eax, 0FFFFFFFFh
mov [rbp+var_4C], eax
jmp loc_A23DD
loc_A24C8:
mov [rbp+var_4], 0
loc_A24CF:
mov eax, [rbp+var_4]
add rsp, 50h
pop rbp
retn
|
long long ftb_find_relevance_add_word(long long a1, long long a2, int a3)
{
int v4; // [rsp+4h] [rbp-4Ch]
int v5; // [rsp+8h] [rbp-48h]
int v6; // [rsp+Ch] [rbp-44h]
long long v7; // [rsp+10h] [rbp-40h]
long long v8; // [rsp+10h] [rbp-40h]
long long v9; // [rsp+18h] [rbp-38h]
long long *v10; // [rsp+20h] [rbp-30h]
v10 = *(long long **)(a1 + 24);
v9 = *v10;
v6 = 0;
v5 = *(_DWORD *)(*v10 + 128);
v4 = v5 / 2;
while ( v5 - v6 > 1 )
{
v7 = *(_QWORD *)(*(_QWORD *)(v9 + 32) + 8LL * v4);
if ( (int)ha_compare_text(
*(_QWORD *)(v9 + 16),
a2,
a3,
v7 + 78,
(unsigned int)(*(_DWORD *)(v7 + 72) - 1),
*(_BYTE *)(v7 + 8) & 1) >= 0 )
v6 = v4;
else
v5 = v4;
v4 = (v5 + v6) / 2;
}
while ( v4 >= 0 )
{
v8 = *(_QWORD *)(*(_QWORD *)(v9 + 32) + 8LL * v4);
if ( (unsigned int)ha_compare_text(
*(_QWORD *)(v9 + 16),
a2,
a3,
v8 + 78,
(unsigned int)(*(_DWORD *)(v8 + 72) - 1),
*(_BYTE *)(v8 + 8) & 1) )
{
if ( (*(_BYTE *)(v9 + 836) & 1) == 0 )
break;
}
else if ( *(_QWORD *)(v8 + 24) != *(_QWORD *)(*(_QWORD *)(v9 + 8) + 368LL) )
{
*(_QWORD *)(v8 + 24) = *(_QWORD *)(*(_QWORD *)(v9 + 8) + 368LL);
if ( (unsigned int)ftb_climb_the_tree(v9, v8, (_QWORD *)v10[1]) )
return 1;
}
--v4;
}
return 0;
}
|
ftb_find_relevance_add_word:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
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]
MOV qword ptr [RBP + -0x38],RAX
MOV dword ptr [RBP + -0x44],0x0
MOV RAX,qword ptr [RBP + -0x38]
MOV EAX,dword ptr [RAX + 0x80]
MOV dword ptr [RBP + -0x48],EAX
MOV EAX,dword ptr [RBP + -0x44]
ADD EAX,dword ptr [RBP + -0x48]
MOV ECX,0x2
CDQ
IDIV ECX
MOV dword ptr [RBP + -0x4c],EAX
LAB_001a2353:
MOV EAX,dword ptr [RBP + -0x48]
SUB EAX,dword ptr [RBP + -0x44]
CMP EAX,0x1
JLE 0x001a23db
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x20]
MOVSXD RCX,dword ptr [RBP + -0x4c]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RDI,qword ptr [RAX + 0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOVSXD RDX,dword ptr [RBP + -0x1c]
MOV RCX,qword ptr [RBP + -0x40]
ADD RCX,0x4d
ADD RCX,0x1
MOV RAX,qword ptr [RBP + -0x40]
MOV EAX,dword ptr [RAX + 0x48]
SUB EAX,0x1
MOV EAX,EAX
MOV R8D,EAX
MOV RAX,qword ptr [RBP + -0x40]
MOV EAX,dword ptr [RAX + 0x8]
AND EAX,0x1
MOVSX R9D,AL
CALL 0x001f6c40
CMP EAX,0x0
JGE 0x001a23bd
MOV EAX,dword ptr [RBP + -0x4c]
MOV dword ptr [RBP + -0x48],EAX
JMP 0x001a23c3
LAB_001a23bd:
MOV EAX,dword ptr [RBP + -0x4c]
MOV dword ptr [RBP + -0x44],EAX
LAB_001a23c3:
JMP 0x001a23c5
LAB_001a23c5:
MOV EAX,dword ptr [RBP + -0x44]
ADD EAX,dword ptr [RBP + -0x48]
MOV ECX,0x2
CDQ
IDIV ECX
MOV dword ptr [RBP + -0x4c],EAX
JMP 0x001a2353
LAB_001a23db:
JMP 0x001a23dd
LAB_001a23dd:
CMP dword ptr [RBP + -0x4c],0x0
JL 0x001a24c8
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x20]
MOVSXD RCX,dword ptr [RBP + -0x4c]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RDI,qword ptr [RAX + 0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOVSXD RDX,dword ptr [RBP + -0x1c]
MOV RCX,qword ptr [RBP + -0x40]
ADD RCX,0x4d
ADD RCX,0x1
MOV RAX,qword ptr [RBP + -0x40]
MOV EAX,dword ptr [RAX + 0x48]
SUB EAX,0x1
MOV EAX,EAX
MOV R8D,EAX
MOV RAX,qword ptr [RBP + -0x40]
MOV EAX,dword ptr [RAX + 0x8]
AND EAX,0x1
MOVSX R9D,AL
CALL 0x001f6c40
CMP EAX,0x0
JZ 0x001a2455
MOV RAX,qword ptr [RBP + -0x38]
MOVZX EAX,byte ptr [RAX + 0x344]
AND EAX,0x1
CMP EAX,0x0
JZ 0x001a2453
JMP 0x001a24ba
LAB_001a2453:
JMP 0x001a24c8
LAB_001a2455:
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x18]
MOV RCX,qword ptr [RBP + -0x38]
MOV RCX,qword ptr [RCX + 0x8]
CMP RAX,qword ptr [RCX + 0x170]
JNZ 0x001a2470
JMP 0x001a24ba
LAB_001a2470:
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RAX + 0x170]
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RAX + 0x18],RCX
MOV RDI,qword ptr [RBP + -0x38]
MOV RSI,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RBP + -0x30]
MOV RDX,qword ptr [RAX + 0x8]
CALL 0x001a1b00
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x001a24b8
MOV dword ptr [RBP + -0x4],0x1
JMP 0x001a24cf
LAB_001a24b8:
JMP 0x001a24ba
LAB_001a24ba:
MOV EAX,dword ptr [RBP + -0x4c]
ADD EAX,-0x1
MOV dword ptr [RBP + -0x4c],EAX
JMP 0x001a23dd
LAB_001a24c8:
MOV dword ptr [RBP + -0x4],0x0
LAB_001a24cf:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x50
POP RBP
RET
|
int4 ftb_find_relevance_add_word(long param_1,int8 param_2,int param_3)
{
long *plVar1;
long lVar2;
long lVar3;
int iVar4;
int local_54;
int local_50;
int local_4c;
plVar1 = *(long **)(param_1 + 0x18);
lVar2 = *plVar1;
local_4c = 0;
local_50 = *(int *)(lVar2 + 0x80);
local_54 = local_50;
while (local_54 = local_54 / 2, 1 < local_50 - local_4c) {
lVar3 = *(long *)(*(long *)(lVar2 + 0x20) + (long)local_54 * 8);
iVar4 = ha_compare_text(*(int8 *)(lVar2 + 0x10),param_2,(long)param_3,lVar3 + 0x4e,
*(int *)(lVar3 + 0x48) + -1,(byte)*(int4 *)(lVar3 + 8) & 1);
if (iVar4 < 0) {
local_50 = local_54;
}
else {
local_4c = local_54;
}
local_54 = local_4c + local_50;
}
do {
if (local_54 < 0) {
return 0;
}
lVar3 = *(long *)(*(long *)(lVar2 + 0x20) + (long)local_54 * 8);
iVar4 = ha_compare_text(*(int8 *)(lVar2 + 0x10),param_2,(long)param_3,lVar3 + 0x4e,
*(int *)(lVar3 + 0x48) + -1,(byte)*(int4 *)(lVar3 + 8) & 1);
if (iVar4 == 0) {
if (*(long *)(lVar3 + 0x18) != *(long *)(*(long *)(lVar2 + 8) + 0x170)) {
*(int8 *)(lVar3 + 0x18) = *(int8 *)(*(long *)(lVar2 + 8) + 0x170);
iVar4 = _ftb_climb_the_tree(lVar2,lVar3,plVar1[1]);
if (iVar4 != 0) {
return 1;
}
}
}
else if ((*(byte *)(lVar2 + 0x344) & 1) == 0) {
return 0;
}
local_54 = local_54 + -1;
} while( true );
}
|
|
64,896 |
my_dir
|
eloqsql/mysys/my_lib.c
|
MY_DIR *my_dir(const char *path, myf MyFlags)
{
MY_DIR_HANDLE *dirh;
FILEINFO finfo;
DIR *dirp;
struct dirent *dp;
char tmp_path[FN_REFLEN + 2], *tmp_file;
char dirent_tmp[sizeof(struct dirent)+_POSIX_PATH_MAX+1];
DBUG_ENTER("my_dir");
DBUG_PRINT("my",("path: '%s' MyFlags: %lu",path,MyFlags));
tmp_file= directory_file_name(tmp_path, path);
if (!(dirp= opendir(tmp_path)))
{
my_errno= errno;
goto err_open;
}
if (!(dirh= my_malloc(key_memory_MY_DIR, sizeof(*dirh),
MYF(MyFlags | MY_ZEROFILL))))
goto err_alloc;
if (my_init_dynamic_array(key_memory_MY_DIR, &dirh->array, sizeof(FILEINFO),
ENTRIES_START_SIZE, ENTRIES_INCREMENT,
MYF(MyFlags)))
goto error;
init_alloc_root(key_memory_MY_DIR, &dirh->root, NAMES_START_SIZE,
NAMES_START_SIZE, MYF(MyFlags));
dp= (struct dirent*) dirent_tmp;
while (!(READDIR(dirp,(struct dirent*) dirent_tmp,dp)))
{
MY_STAT statbuf, *mystat= 0;
if (dp->d_name[0] == '.' &&
(dp->d_name[1] == '\0' ||
(dp->d_name[1] == '.' && dp->d_name[2] == '\0')))
continue; /* . or .. */
if (MyFlags & MY_WANT_STAT)
{
mystat= &statbuf;
bzero(mystat, sizeof(*mystat));
(void) strmov(tmp_file, dp->d_name);
(void) my_stat(tmp_path, mystat, MyFlags);
if (!(mystat->st_mode & MY_S_IREAD))
continue;
}
if (!(finfo.name= strdup_root(&dirh->root, dp->d_name)))
goto error;
if (mystat &&
!((mystat= memdup_root(&dirh->root, mystat, sizeof(*mystat)))))
goto error;
finfo.mystat= mystat;
if (push_dynamic(&dirh->array, (uchar*)&finfo))
goto error;
}
(void) closedir(dirp);
if (MyFlags & MY_WANT_SORT)
sort_dynamic(&dirh->array, (qsort_cmp) comp_names);
dirh->dir.dir_entry= dynamic_element(&dirh->array, 0, FILEINFO *);
dirh->dir.number_of_files= dirh->array.elements;
DBUG_RETURN(&dirh->dir);
error:
my_dirend(&dirh->dir);
err_alloc:
(void) closedir(dirp);
err_open:
if (MyFlags & (MY_FAE | MY_WME))
my_error(EE_DIR, MYF(ME_BELL), path, my_errno);
DBUG_RETURN(NULL);
}
|
O3
|
c
|
my_dir:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x2e8, %rsp # imm = 0x2E8
movq %rdi, %r14
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
cmpb $0x0, (%rdi)
movq %rsi, %r15
leaq 0x348e1(%rip), %rsi # 0x5f31b
cmovneq %rdi, %rsi
leaq -0x240(%rbp), %rdi
movl $0x201, %edx # imm = 0x201
callq 0x5dfa4
movq %rax, %r12
cmpb $0x2f, -0x1(%rax)
je 0x2aa62
movw $0x2f, (%r12)
incq %r12
leaq -0x240(%rbp), %rdi
callq 0x244e0
testq %rax, %rax
je 0x2aaf2
movq %rax, %r13
leaq 0x340497(%rip), %rbx # 0x36af14
movl (%rbx), %edi
movq %r15, -0x248(%rbp)
orq $0x20, %r15
movl $0x78, %esi
movq %r15, %rdx
callq 0x2adb9
testq %rax, %rax
je 0x2aae1
movq %rax, %r15
movq %r12, -0x268(%rbp)
movq %rbx, %r12
movl (%rbx), %edi
leaq 0x10(%rax), %rbx
movq -0x248(%rbp), %rax
movq %rax, (%rsp)
movq %rbx, %rsi
movl $0x10, %edx
xorl %ecx, %ecx
movl $0x200, %r8d # imm = 0x200
movl $0x1000, %r9d # imm = 0x1000
callq 0x2d014
testb %al, %al
je 0x2ab31
movq %r15, %rdi
callq 0x2a9d8
movq %r13, %rdi
callq 0x24570
movq -0x248(%rbp), %r15
jmp 0x2ab00
callq 0x24050
movl (%rax), %ebx
callq 0x2bd8a
movl %ebx, (%rax)
testb $0x18, %r15b
je 0x2ab29
callq 0x2bd8a
movl (%rax), %ecx
xorl %r15d, %r15d
movl $0x4, %esi
movl $0xc, %edi
movq %r14, %rdx
xorl %eax, %eax
callq 0x306df
jmp 0x2aca2
xorl %r15d, %r15d
jmp 0x2aca2
movq %rbx, -0x260(%rbp)
movq %r14, -0x258(%rbp)
movl (%r12), %edi
movq %r15, %rsi
addq $0x38, %rsi
movl $0x8000, %edx # imm = 0x8000
movl $0x8000, %ecx # imm = 0x8000
movq %rsi, -0x250(%rbp)
movq -0x248(%rbp), %r8
callq 0x27410
movq %r13, %rdi
callq 0x241b0
testq %rax, %rax
je 0x2ac69
movq %rax, %rbx
movq -0x248(%rbp), %r14
cmpb $0x2e, 0x13(%rbx)
jne 0x2aba3
movzbl 0x14(%rbx), %eax
testl %eax, %eax
je 0x2ac55
cmpl $0x2e, %eax
jne 0x2aba3
cmpb $0x0, 0x15(%rbx)
je 0x2ac55
addq $0x13, %rbx
btl $0xe, %r14d
jb 0x2abb3
xorl %r12d, %r12d
jmp 0x2abf3
movl $0x90, %edx
leaq -0x308(%rbp), %r12
movq %r12, %rdi
xorl %esi, %esi
callq 0x24180
movq -0x268(%rbp), %rdi
movq %rbx, %rsi
callq 0x24270
leaq -0x240(%rbp), %rdi
movq %r12, %rsi
movq %r14, %rdx
callq 0x2acd7
testb $0x1, -0x2ef(%rbp)
je 0x2ac55
movq -0x250(%rbp), %rdi
movq %rbx, %rsi
callq 0x27902
movq %rax, -0x278(%rbp)
testq %rax, %rax
je 0x2acc6
testq %r12, %r12
je 0x2ac35
movl $0x90, %edx
movq -0x250(%rbp), %rdi
movq %r12, %rsi
callq 0x27970
testq %rax, %rax
jne 0x2ac37
jmp 0x2acc6
xorl %eax, %eax
movq %rax, -0x270(%rbp)
movq -0x260(%rbp), %rdi
leaq -0x278(%rbp), %rsi
callq 0x2d0b2
testb %al, %al
jne 0x2acc6
movq %r13, %rdi
callq 0x241b0
movq %rax, %rbx
testq %rax, %rax
jne 0x2ab82
movq %r13, %rdi
callq 0x24570
btl $0xd, -0x248(%rbp)
jae 0x2ac93
movq 0x10(%r15), %rdi
movl 0x18(%r15), %esi
movl 0x24(%r15), %edx
leaq 0xed(%rip), %rcx # 0x2ad7b
callq 0x2fe28
movq 0x10(%r15), %rax
movq %rax, (%r15)
movl 0x18(%r15), %eax
movl %eax, 0x8(%r15)
movq %fs:0x28, %rax
cmpq -0x30(%rbp), %rax
jne 0x2acd2
movq %r15, %rax
addq $0x2e8, %rsp # imm = 0x2E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq -0x258(%rbp), %r14
jmp 0x2aad9
callq 0x24350
|
my_dir:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 2E8h
mov r14, rdi
mov rax, fs:28h
mov [rbp+var_30], rax
cmp byte ptr [rdi], 0
mov r15, rsi
lea rsi, aReturnAnEmptyS+2Bh; "."
cmovnz rsi, rdi
lea rdi, [rbp+var_240]
mov edx, 201h
call strnmov
mov r12, rax
cmp byte ptr [rax-1], 2Fh ; '/'
jz short loc_2AA62
mov word ptr [r12], 2Fh ; '/'
inc r12
loc_2AA62:
lea rdi, [rbp+var_240]
call _opendir
test rax, rax
jz short loc_2AAF2
mov r13, rax
lea rbx, key_memory_MY_DIR
mov edi, [rbx]
mov [rbp+var_248], r15
or r15, 20h
mov esi, 78h ; 'x'
mov rdx, r15
call my_malloc
test rax, rax
jz short loc_2AAE1
mov r15, rax
mov [rbp+var_268], r12
mov r12, rbx
mov edi, [rbx]
lea rbx, [rax+10h]
mov rax, [rbp+var_248]
mov [rsp+310h+var_310], rax
mov rsi, rbx
mov edx, 10h
xor ecx, ecx
mov r8d, 200h
mov r9d, 1000h
call init_dynamic_array2
test al, al
jz short loc_2AB31
loc_2AAD9:
mov rdi, r15
call my_dirend
loc_2AAE1:
mov rdi, r13
call _closedir
mov r15, [rbp+var_248]
jmp short loc_2AB00
loc_2AAF2:
call ___errno_location
mov ebx, [rax]
call _my_thread_var
mov [rax], ebx
loc_2AB00:
test r15b, 18h
jz short loc_2AB29
call _my_thread_var
mov ecx, [rax]
xor r15d, r15d
mov esi, 4
mov edi, 0Ch
mov rdx, r14
xor eax, eax
call my_error
jmp loc_2ACA2
loc_2AB29:
xor r15d, r15d
jmp loc_2ACA2
loc_2AB31:
mov [rbp+var_260], rbx
mov [rbp+var_258], r14
mov edi, [r12]
mov rsi, r15
add rsi, 38h ; '8'
mov edx, 8000h
mov ecx, 8000h
mov [rbp+var_250], rsi
mov r8, [rbp+var_248]
call init_alloc_root
mov rdi, r13
call _readdir64
test rax, rax
jz loc_2AC69
mov rbx, rax
mov r14, [rbp+var_248]
loc_2AB82:
cmp byte ptr [rbx+13h], 2Eh ; '.'
jnz short loc_2ABA3
movzx eax, byte ptr [rbx+14h]
test eax, eax
jz loc_2AC55
cmp eax, 2Eh ; '.'
jnz short loc_2ABA3
cmp byte ptr [rbx+15h], 0
jz loc_2AC55
loc_2ABA3:
add rbx, 13h
bt r14d, 0Eh
jb short loc_2ABB3
xor r12d, r12d
jmp short loc_2ABF3
loc_2ABB3:
mov edx, 90h
lea r12, [rbp+var_308]
mov rdi, r12
xor esi, esi
call _memset
mov rdi, [rbp+var_268]
mov rsi, rbx
call _strcpy
lea rdi, [rbp+var_240]
mov rsi, r12
mov rdx, r14
call my_stat
test [rbp+var_2EF], 1
jz short loc_2AC55
loc_2ABF3:
mov rdi, [rbp+var_250]
mov rsi, rbx
call strdup_root
mov [rbp+var_278], rax
test rax, rax
jz loc_2ACC6
test r12, r12
jz short loc_2AC35
mov edx, 90h
mov rdi, [rbp+var_250]
mov rsi, r12
call memdup_root
test rax, rax
jnz short loc_2AC37
jmp loc_2ACC6
loc_2AC35:
xor eax, eax
loc_2AC37:
mov [rbp+var_270], rax
mov rdi, [rbp+var_260]
lea rsi, [rbp+var_278]
call insert_dynamic
test al, al
jnz short loc_2ACC6
loc_2AC55:
mov rdi, r13
call _readdir64
mov rbx, rax
test rax, rax
jnz loc_2AB82
loc_2AC69:
mov rdi, r13
call _closedir
bt dword ptr [rbp+var_248], 0Dh
jnb short loc_2AC93
mov rdi, [r15+10h]
mov esi, [r15+18h]
mov edx, [r15+24h]
lea rcx, comp_names
call my_qsort
loc_2AC93:
mov rax, [r15+10h]
mov [r15], rax
mov eax, [r15+18h]
mov [r15+8], eax
loc_2ACA2:
mov rax, fs:28h
cmp rax, [rbp+var_30]
jnz short loc_2ACD2
mov rax, r15
add rsp, 2E8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_2ACC6:
mov r14, [rbp+var_258]
jmp loc_2AAD9
loc_2ACD2:
call ___stack_chk_fail
|
long long my_dir(char *a1, long long a2)
{
char *v2; // r14
char *v4; // rsi
char *v5; // rax
char *v6; // r12
_BYTE *v7; // rdi
long long v8; // rax
_BYTE *v9; // r13
long long v10; // rax
long long v11; // r15
long long v12; // rbx
int v13; // ebx
_DWORD *v14; // rax
int v15; // r8d
int v16; // r9d
long long v17; // rax
_BYTE *v18; // rbx
long long v19; // r14
long long v20; // rbx
_BYTE *v21; // r12
char *v22; // rax
_BYTE v24[144]; // [rsp+8h] [rbp-308h] BYREF
_QWORD v25[2]; // [rsp+98h] [rbp-278h] BYREF
char *v26; // [rsp+A8h] [rbp-268h]
long long v27; // [rsp+B0h] [rbp-260h]
char *v28; // [rsp+B8h] [rbp-258h]
long long v29; // [rsp+C0h] [rbp-250h]
long long v30; // [rsp+C8h] [rbp-248h] BYREF
_BYTE v31[528]; // [rsp+D0h] [rbp-240h] BYREF
unsigned long long v32; // [rsp+2E0h] [rbp-30h]
v2 = a1;
v32 = __readfsqword(0x28u);
v4 = ".";
if ( *a1 )
v4 = a1;
v5 = (char *)strnmov(v31, v4, 513LL);
v6 = v5;
if ( *(v5 - 1) != 47 )
{
*(_WORD *)v5 = 47;
v6 = v5 + 1;
}
v7 = v31;
v8 = opendir(v31);
if ( !v8 )
{
v13 = *(_DWORD *)__errno_location(v31);
*(_DWORD *)my_thread_var(v31) = v13;
goto LABEL_11;
}
v9 = (_BYTE *)v8;
v30 = a2;
v10 = my_malloc(key_memory_MY_DIR, 120LL);
if ( !v10 )
goto LABEL_9;
v11 = v10;
v26 = v6;
v12 = v10 + 16;
if ( (unsigned __int8)init_dynamic_array2(key_memory_MY_DIR, (int)v10 + 16, 16, 0, 512, 4096, v30) )
goto LABEL_8;
v27 = v12;
v28 = v2;
v29 = v11 + 56;
init_alloc_root(key_memory_MY_DIR, (long long *)(v11 + 56), 0x8000LL, 0x8000LL, v30);
v17 = readdir64(v9);
if ( !v17 )
{
LABEL_30:
closedir(v9);
if ( _bittest((const signed __int32 *)&v30, 0xDu) )
my_qsort(*(_QWORD *)(v11 + 16), *(unsigned int *)(v11 + 24), *(unsigned int *)(v11 + 36), comp_names);
*(_QWORD *)v11 = *(_QWORD *)(v11 + 16);
*(_DWORD *)(v11 + 8) = *(_DWORD *)(v11 + 24);
return v11;
}
v18 = (_BYTE *)v17;
v19 = v30;
while ( 1 )
{
if ( v18[19] == 46 && (!v18[20] || v18[20] == 46 && !v18[21]) )
goto LABEL_29;
v20 = (long long)(v18 + 19);
if ( (v19 & 0x4000) != 0 )
{
v21 = v24;
memset(v24, 0LL, sizeof(v24));
strcpy(v26, v20);
my_stat(v31, v24, v19);
if ( (v24[25] & 1) == 0 )
goto LABEL_29;
}
else
{
v21 = 0LL;
}
v25[0] = strdup_root(v29, v20);
if ( !v25[0] )
break;
if ( v21 )
{
v22 = memdup_root(v29, (long long)v21, 144LL);
if ( !v22 )
break;
}
else
{
v22 = 0LL;
}
v25[1] = v22;
if ( (unsigned __int8)insert_dynamic(v27, v25) )
break;
LABEL_29:
v18 = (_BYTE *)readdir64(v9);
if ( !v18 )
goto LABEL_30;
}
LODWORD(v2) = (_DWORD)v28;
LABEL_8:
my_dirend(v11);
LABEL_9:
v7 = v9;
closedir(v9);
LOBYTE(a2) = v30;
LABEL_11:
if ( (a2 & 0x18) == 0 )
return 0LL;
v14 = (_DWORD *)my_thread_var(v7);
v11 = 0LL;
my_error(12, 4, (_DWORD)v2, *v14, v15, v16);
return v11;
}
|
my_dir:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x2e8
MOV R14,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
CMP byte ptr [RDI],0x0
MOV R15,RSI
LEA RSI,[0x15f31b]
CMOVNZ RSI,RDI
LEA RDI,[RBP + -0x240]
MOV EDX,0x201
CALL 0x0015dfa4
MOV R12,RAX
CMP byte ptr [RAX + -0x1],0x2f
JZ 0x0012aa62
MOV word ptr [R12],0x2f
INC R12
LAB_0012aa62:
LEA RDI,[RBP + -0x240]
CALL 0x001244e0
TEST RAX,RAX
JZ 0x0012aaf2
MOV R13,RAX
LEA RBX,[0x46af14]
MOV EDI,dword ptr [RBX]
MOV qword ptr [RBP + -0x248],R15
OR R15,0x20
MOV ESI,0x78
MOV RDX,R15
CALL 0x0012adb9
TEST RAX,RAX
JZ 0x0012aae1
MOV R15,RAX
MOV qword ptr [RBP + -0x268],R12
MOV R12,RBX
MOV EDI,dword ptr [RBX]
LEA RBX,[RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x248]
MOV qword ptr [RSP],RAX
MOV RSI,RBX
MOV EDX,0x10
XOR ECX,ECX
MOV R8D,0x200
MOV R9D,0x1000
CALL 0x0012d014
TEST AL,AL
JZ 0x0012ab31
LAB_0012aad9:
MOV RDI,R15
CALL 0x0012a9d8
LAB_0012aae1:
MOV RDI,R13
CALL 0x00124570
MOV R15,qword ptr [RBP + -0x248]
JMP 0x0012ab00
LAB_0012aaf2:
CALL 0x00124050
MOV EBX,dword ptr [RAX]
CALL 0x0012bd8a
MOV dword ptr [RAX],EBX
LAB_0012ab00:
TEST R15B,0x18
JZ 0x0012ab29
CALL 0x0012bd8a
MOV ECX,dword ptr [RAX]
XOR R15D,R15D
MOV ESI,0x4
MOV EDI,0xc
MOV RDX,R14
XOR EAX,EAX
CALL 0x001306df
JMP 0x0012aca2
LAB_0012ab29:
XOR R15D,R15D
JMP 0x0012aca2
LAB_0012ab31:
MOV qword ptr [RBP + -0x260],RBX
MOV qword ptr [RBP + -0x258],R14
MOV EDI,dword ptr [R12]
MOV RSI,R15
ADD RSI,0x38
MOV EDX,0x8000
MOV ECX,0x8000
MOV qword ptr [RBP + -0x250],RSI
MOV R8,qword ptr [RBP + -0x248]
CALL 0x00127410
MOV RDI,R13
CALL 0x001241b0
TEST RAX,RAX
JZ 0x0012ac69
MOV RBX,RAX
MOV R14,qword ptr [RBP + -0x248]
LAB_0012ab82:
CMP byte ptr [RBX + 0x13],0x2e
JNZ 0x0012aba3
MOVZX EAX,byte ptr [RBX + 0x14]
TEST EAX,EAX
JZ 0x0012ac55
CMP EAX,0x2e
JNZ 0x0012aba3
CMP byte ptr [RBX + 0x15],0x0
JZ 0x0012ac55
LAB_0012aba3:
ADD RBX,0x13
BT R14D,0xe
JC 0x0012abb3
XOR R12D,R12D
JMP 0x0012abf3
LAB_0012abb3:
MOV EDX,0x90
LEA R12,[RBP + -0x308]
MOV RDI,R12
XOR ESI,ESI
CALL 0x00124180
MOV RDI,qword ptr [RBP + -0x268]
MOV RSI,RBX
CALL 0x00124270
LEA RDI,[RBP + -0x240]
MOV RSI,R12
MOV RDX,R14
CALL 0x0012acd7
TEST byte ptr [RBP + -0x2ef],0x1
JZ 0x0012ac55
LAB_0012abf3:
MOV RDI,qword ptr [RBP + -0x250]
MOV RSI,RBX
CALL 0x00127902
MOV qword ptr [RBP + -0x278],RAX
TEST RAX,RAX
JZ 0x0012acc6
TEST R12,R12
JZ 0x0012ac35
MOV EDX,0x90
MOV RDI,qword ptr [RBP + -0x250]
MOV RSI,R12
CALL 0x00127970
TEST RAX,RAX
JNZ 0x0012ac37
JMP 0x0012acc6
LAB_0012ac35:
XOR EAX,EAX
LAB_0012ac37:
MOV qword ptr [RBP + -0x270],RAX
MOV RDI,qword ptr [RBP + -0x260]
LEA RSI,[RBP + -0x278]
CALL 0x0012d0b2
TEST AL,AL
JNZ 0x0012acc6
LAB_0012ac55:
MOV RDI,R13
CALL 0x001241b0
MOV RBX,RAX
TEST RAX,RAX
JNZ 0x0012ab82
LAB_0012ac69:
MOV RDI,R13
CALL 0x00124570
BT dword ptr [RBP + -0x248],0xd
JNC 0x0012ac93
MOV RDI,qword ptr [R15 + 0x10]
MOV ESI,dword ptr [R15 + 0x18]
MOV EDX,dword ptr [R15 + 0x24]
LEA RCX,[0x12ad7b]
CALL 0x0012fe28
LAB_0012ac93:
MOV RAX,qword ptr [R15 + 0x10]
MOV qword ptr [R15],RAX
MOV EAX,dword ptr [R15 + 0x18]
MOV dword ptr [R15 + 0x8],EAX
LAB_0012aca2:
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNZ 0x0012acd2
MOV RAX,R15
ADD RSP,0x2e8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0012acc6:
MOV R14,qword ptr [RBP + -0x258]
JMP 0x0012aad9
LAB_0012acd2:
CALL 0x00124350
|
int8 * my_dir(char *param_1,ulong param_2)
{
int iVar1;
ulong uVar2;
char cVar3;
char *pcVar4;
DIR *__dirp;
int8 *puVar5;
int *piVar6;
int4 *puVar7;
dirent64 *pdVar8;
long lVar9;
int1 *__s;
long in_FS_OFFSET;
int1 local_310 [25];
byte local_2f7;
long local_280;
long local_278;
char *local_270;
int8 *local_268;
char *local_260;
int8 *local_258;
ulong local_250;
char local_248 [528];
long local_38;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
pcVar4 = ".";
if (*param_1 != '\0') {
pcVar4 = param_1;
}
pcVar4 = (char *)strnmov(local_248,pcVar4,0x201);
if (pcVar4[-1] != '/') {
pcVar4[0] = '/';
pcVar4[1] = '\0';
pcVar4 = pcVar4 + 1;
}
__dirp = opendir(local_248);
if (__dirp == (DIR *)0x0) {
piVar6 = __errno_location();
iVar1 = *piVar6;
piVar6 = (int *)_my_thread_var();
*piVar6 = iVar1;
}
else {
local_250 = param_2;
puVar5 = (int8 *)my_malloc(key_memory_MY_DIR,0x78,param_2 | 0x20);
if (puVar5 != (int8 *)0x0) {
local_270 = pcVar4;
cVar3 = init_dynamic_array2(key_memory_MY_DIR,puVar5 + 2,0x10,0,0x200,0x1000,local_250);
if (cVar3 == '\0') {
local_258 = puVar5 + 7;
local_268 = puVar5 + 2;
local_260 = param_1;
init_alloc_root(key_memory_MY_DIR,local_258,0x8000,0x8000,local_250);
pdVar8 = readdir64(__dirp);
uVar2 = local_250;
while (pdVar8 != (dirent64 *)0x0) {
if ((pdVar8->d_name[0] != '.') ||
((pdVar8->d_name[1] != '\0' &&
((pdVar8->d_name[1] != '.' || (pdVar8->d_name[2] != '\0')))))) {
if (((uint)uVar2 >> 0xe & 1) == 0) {
__s = (int1 *)0x0;
}
else {
__s = local_310;
memset(__s,0,0x90);
strcpy(local_270,pdVar8->d_name);
my_stat(local_248,__s,uVar2);
if ((local_2f7 & 1) == 0) goto LAB_0012ac55;
}
local_280 = strdup_root(local_258,pdVar8->d_name);
param_1 = local_260;
if (local_280 == 0) goto LAB_0012aad9;
if (__s == (int1 *)0x0) {
lVar9 = 0;
}
else {
lVar9 = memdup_root(local_258,__s,0x90);
param_1 = local_260;
if (lVar9 == 0) goto LAB_0012aad9;
}
local_278 = lVar9;
cVar3 = insert_dynamic(local_268);
param_1 = local_260;
if (cVar3 != '\0') goto LAB_0012aad9;
}
LAB_0012ac55:
pdVar8 = readdir64(__dirp);
}
closedir(__dirp);
if (((uint)local_250 >> 0xd & 1) != 0) {
my_qsort(puVar5[2],*(int4 *)(puVar5 + 3),*(int4 *)((long)puVar5 + 0x24),
comp_names);
}
*puVar5 = puVar5[2];
*(int4 *)(puVar5 + 1) = *(int4 *)(puVar5 + 3);
goto LAB_0012aca2;
}
LAB_0012aad9:
my_dirend(puVar5);
}
closedir(__dirp);
param_2 = local_250;
}
if ((param_2 & 0x18) == 0) {
puVar5 = (int8 *)0x0;
}
else {
puVar7 = (int4 *)_my_thread_var();
puVar5 = (int8 *)0x0;
my_error(0xc,4,param_1,*puVar7);
}
LAB_0012aca2:
if (*(long *)(in_FS_OFFSET + 0x28) == local_38) {
return puVar5;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
|
|
64,897 |
my_strxfrm_pad_nweights_unicode
|
eloqsql/strings/ctype-utf8.c
|
size_t
my_strxfrm_pad_nweights_unicode(uchar *str, uchar *strend, size_t nweights)
{
uchar *str0;
DBUG_ASSERT(str && str <= strend);
for (str0= str; str < strend && nweights; nweights--)
{
*str++= 0x00;
if (str < strend)
*str++= 0x20;
}
return str - str0;
}
|
O3
|
c
|
my_strxfrm_pad_nweights_unicode:
cmpq %rsi, %rdi
setae %al
testq %rdx, %rdx
sete %cl
orb %al, %cl
movq %rdi, %rax
jne 0x554e5
pushq %rbp
movq %rsp, %rbp
decq %rdx
movq %rdi, %rcx
leaq 0x1(%rcx), %rax
movb $0x0, (%rcx)
cmpq %rsi, %rax
jae 0x554cf
movb $0x20, 0x1(%rcx)
addq $0x2, %rcx
movq %rcx, %rax
addq $-0x1, %rdx
setb %r8b
cmpq %rsi, %rax
jae 0x554e4
movq %rax, %rcx
testb %r8b, %r8b
jne 0x554b8
popq %rbp
subq %rdi, %rax
retq
|
my_strxfrm_pad_nweights_unicode:
cmp rdi, rsi
setnb al
test rdx, rdx
setz cl
or cl, al
mov rax, rdi
jnz short loc_554E5
push rbp
mov rbp, rsp
dec rdx
mov rcx, rdi
loc_554B8:
lea rax, [rcx+1]
mov byte ptr [rcx], 0
cmp rax, rsi
jnb short loc_554CF
mov byte ptr [rcx+1], 20h ; ' '
add rcx, 2
mov rax, rcx
loc_554CF:
add rdx, 0FFFFFFFFFFFFFFFFh
setb r8b
cmp rax, rsi
jnb short loc_554E4
mov rcx, rax
test r8b, r8b
jnz short loc_554B8
loc_554E4:
pop rbp
loc_554E5:
sub rax, rdi
retn
|
long long my_strxfrm_pad_nweights_unicode(_BYTE *a1, unsigned long long a2, long long a3)
{
_BYTE *v3; // rax
long long v4; // rdx
_BYTE *v5; // rcx
bool v6; // cf
v3 = a1;
if ( (unsigned long long)a1 < a2 && a3 != 0 )
{
v4 = a3 - 1;
v5 = a1;
do
{
v3 = v5 + 1;
*v5 = 0;
if ( (unsigned long long)(v5 + 1) < a2 )
{
v5[1] = 32;
v3 = v5 + 2;
}
v6 = v4-- != 0;
if ( (unsigned long long)v3 >= a2 )
break;
v5 = v3;
}
while ( v6 );
}
return v3 - a1;
}
|
my_strxfrm_pad_nweights_unicode:
CMP RDI,RSI
SETNC AL
TEST RDX,RDX
SETZ CL
OR CL,AL
MOV RAX,RDI
JNZ 0x001554e5
PUSH RBP
MOV RBP,RSP
DEC RDX
MOV RCX,RDI
LAB_001554b8:
LEA RAX,[RCX + 0x1]
MOV byte ptr [RCX],0x0
CMP RAX,RSI
JNC 0x001554cf
MOV byte ptr [RCX + 0x1],0x20
ADD RCX,0x2
MOV RAX,RCX
LAB_001554cf:
ADD RDX,-0x1
SETC R8B
CMP RAX,RSI
JNC 0x001554e4
MOV RCX,RAX
TEST R8B,R8B
JNZ 0x001554b8
LAB_001554e4:
POP RBP
LAB_001554e5:
SUB RAX,RDI
RET
|
long my_strxfrm_pad_nweights_unicode(int1 *param_1,int1 *param_2,long param_3)
{
int1 *puVar1;
int1 *puVar2;
bool bVar3;
puVar2 = param_1;
if (param_3 != 0 && param_1 < param_2) {
param_3 = param_3 + -1;
puVar1 = param_1;
do {
puVar2 = puVar1 + 1;
*puVar1 = 0;
if (puVar2 < param_2) {
puVar1[1] = 0x20;
puVar2 = puVar1 + 2;
}
bVar3 = param_3 != 0;
param_3 = param_3 + -1;
} while ((puVar2 < param_2) && (puVar1 = puVar2, bVar3));
}
return (long)puVar2 - (long)param_1;
}
|
|
64,898 |
testing::internal::FilePath::Normalize()
|
AlayaLite/build_O0/_deps/googletest-src/googletest/src/gtest-filepath.cc
|
void FilePath::Normalize() {
auto out = pathname_.begin();
auto i = pathname_.cbegin();
#ifdef GTEST_OS_WINDOWS
// UNC paths are treated specially
if (pathname_.end() - i >= 3 && IsPathSeparator(*i) &&
IsPathSeparator(*(i + 1)) && !IsPathSeparator(*(i + 2))) {
*(out++) = kPathSeparator;
*(out++) = kPathSeparator;
}
#endif
while (i != pathname_.end()) {
const char character = *i;
if (!IsPathSeparator(character)) {
*(out++) = character;
} else if (out == pathname_.begin() || *std::prev(out) != kPathSeparator) {
*(out++) = kPathSeparator;
}
++i;
}
pathname_.erase(out, pathname_.end());
}
|
O0
|
cpp
|
testing::internal::FilePath::Normalize():
subq $0x88, %rsp
movq %rdi, 0x80(%rsp)
movq 0x80(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x1245f0
movq 0x10(%rsp), %rdi
movq %rax, 0x78(%rsp)
callq 0x124620
movq %rax, 0x70(%rsp)
movq 0x10(%rsp), %rdi
callq 0x124690
movq %rax, 0x68(%rsp)
leaq 0x70(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0x124650
xorb $-0x1, %al
testb $0x1, %al
jne 0xf85de
jmp 0xf86c3
leaq 0x70(%rsp), %rdi
callq 0x7e280
movb (%rax), %al
movb %al, 0x67(%rsp)
movsbl 0x67(%rsp), %edi
callq 0xf7860
testb $0x1, %al
jne 0xf862a
movb 0x67(%rsp), %al
movb %al, 0xf(%rsp)
leaq 0x78(%rsp), %rdi
xorl %esi, %esi
callq 0x1246e0
movq %rax, 0x58(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x124720
movb 0xf(%rsp), %cl
movb %cl, (%rax)
jmp 0xf86b4
movq 0x10(%rsp), %rdi
callq 0x1245f0
movq %rax, 0x50(%rsp)
leaq 0x78(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0x124730
movb %al, %cl
movb $0x1, %al
testb $0x1, %cl
movb %al, 0xe(%rsp)
jne 0xf868a
movq 0x78(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x40(%rsp), %rdi
movl $0x1, %esi
callq 0x124770
movq %rax, 0x48(%rsp)
leaq 0x48(%rsp), %rdi
callq 0x124720
movsbl (%rax), %eax
cmpl $0x2f, %eax
setne %al
movb %al, 0xe(%rsp)
movb 0xe(%rsp), %al
testb $0x1, %al
jne 0xf8694
jmp 0xf86b2
leaq 0x78(%rsp), %rdi
xorl %esi, %esi
callq 0x1246e0
movq %rax, 0x38(%rsp)
leaq 0x38(%rsp), %rdi
callq 0x124720
movb $0x2f, (%rax)
jmp 0xf86b4
leaq 0x70(%rsp), %rdi
callq 0x7e290
jmp 0xf85b5
leaq 0x30(%rsp), %rdi
leaq 0x78(%rsp), %rsi
callq 0x124880
movq 0x10(%rsp), %rdi
callq 0x124690
movq %rax, 0x20(%rsp)
leaq 0x28(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x124880
movq 0x10(%rsp), %rdi
movq 0x30(%rsp), %rsi
movq 0x28(%rsp), %rdx
callq 0x1247b0
movq %rax, 0x18(%rsp)
addq $0x88, %rsp
retq
nopw %cs:(%rax,%rax)
|
_ZN7testing8internal8FilePath9NormalizeEv:
sub rsp, 88h
mov [rsp+88h+var_8], rdi
mov rdi, [rsp+88h+var_8]
mov [rsp+88h+var_78], rdi
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5beginEv; std::string::begin(void)
mov rdi, [rsp+88h+var_78]
mov [rsp+88h+var_10], rax
call _ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6cbeginEv; std::string::cbegin(void)
mov [rsp+88h+var_18], rax
loc_F85B5:
mov rdi, [rsp+88h+var_78]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE3endEv; std::string::end(void)
mov qword ptr [rsp+88h+var_20], rax
lea rdi, [rsp+88h+var_18]
lea rsi, [rsp+88h+var_20]; char
call _ZN9__gnu_cxxeqIPKcPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEQrQT_T0__XeqfL0p_fL0p0_RSt14convertible_toIbEEEEbRKNS_17__normal_iteratorISA_T1_EERKNSD_ISB_SE_EE
xor al, 0FFh
test al, 1
jnz short loc_F85DE
jmp loc_F86C3
loc_F85DE:
lea rdi, [rsp+88h+var_18]
call _ZNK9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEdeEv; __gnu_cxx::__normal_iterator<char const*,std::string>::operator*(void)
mov al, [rax]
mov [rsp+88h+var_21], al
movsx edi, [rsp+88h+var_21]; this
call _ZN7testing8internalL15IsPathSeparatorEc; testing::internal::IsPathSeparator(char)
test al, 1
jnz short loc_F862A
mov al, [rsp+88h+var_21]
mov [rsp+88h+var_79], al
lea rdi, [rsp+88h+var_10]
xor esi, esi
call _ZN9__gnu_cxx17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEppEi; __gnu_cxx::__normal_iterator<char *,std::string>::operator++(int)
mov [rsp+88h+var_30], rax
lea rdi, [rsp+88h+var_30]
call _ZNK9__gnu_cxx17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEdeEv; __gnu_cxx::__normal_iterator<char *,std::string>::operator*(void)
mov cl, [rsp+88h+var_79]
mov [rax], cl
jmp loc_F86B4
loc_F862A:
mov rdi, [rsp+88h+var_78]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5beginEv; std::string::begin(void)
mov [rsp+88h+var_38], rax
lea rdi, [rsp+88h+var_10]
lea rsi, [rsp+88h+var_38]
call _ZN9__gnu_cxxeqIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEbRKNS_17__normal_iteratorIT_T0_EESD_QrqXeqcldtfp_4baseEcldtfp0_4baseERSt14convertible_toIbEE
mov cl, al
mov al, 1
test cl, 1
mov [rsp+88h+var_7A], al
jnz short loc_F868A
mov rax, [rsp+88h+var_10]
mov [rsp+88h+var_48], rax
mov rdi, [rsp+88h+var_48]
mov esi, 1
call _ZSt4prevIN9__gnu_cxx17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEET_SA_NSt15iterator_traitsISA_E15difference_typeE; std::prev<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>,std::iterator_traits<__gnu_cxx::__normal_iterator<char *,std::string>>::difference_type)
mov [rsp+88h+var_40], rax
lea rdi, [rsp+88h+var_40]
call _ZNK9__gnu_cxx17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEdeEv; __gnu_cxx::__normal_iterator<char *,std::string>::operator*(void)
movsx eax, byte ptr [rax]
cmp eax, 2Fh ; '/'
setnz al
mov [rsp+88h+var_7A], al
loc_F868A:
mov al, [rsp+88h+var_7A]
test al, 1
jnz short loc_F8694
jmp short loc_F86B2
loc_F8694:
lea rdi, [rsp+88h+var_10]
xor esi, esi
call _ZN9__gnu_cxx17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEppEi; __gnu_cxx::__normal_iterator<char *,std::string>::operator++(int)
mov [rsp+88h+var_50], rax
lea rdi, [rsp+88h+var_50]
call _ZNK9__gnu_cxx17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEdeEv; __gnu_cxx::__normal_iterator<char *,std::string>::operator*(void)
mov byte ptr [rax], 2Fh ; '/'
loc_F86B2:
jmp short $+2
loc_F86B4:
lea rdi, [rsp+88h+var_18]
call _ZN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEppEv; __gnu_cxx::__normal_iterator<char const*,std::string>::operator++(void)
jmp loc_F85B5
loc_F86C3:
lea rdi, [rsp+88h+var_58]
lea rsi, [rsp+88h+var_10]
call _ZN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPcEERKNS0_IT_NS_11__enable_ifIXsr3std10__are_sameISC_SB_EE7__valueES8_E6__typeEEE
mov rdi, [rsp+88h+var_78]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE3endEv; std::string::end(void)
mov [rsp+88h+var_68], rax
lea rdi, [rsp+88h+var_60]
lea rsi, [rsp+88h+var_68]
call _ZN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPcEERKNS0_IT_NS_11__enable_ifIXsr3std10__are_sameISC_SB_EE7__valueES8_E6__typeEEE
mov rdi, [rsp+88h+var_78]
mov rsi, [rsp+88h+var_58]
mov rdx, [rsp+88h+var_60]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5eraseEN9__gnu_cxx17__normal_iteratorIPKcS4_EES9_; std::string::erase(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>)
mov [rsp+88h+var_70], rax
add rsp, 88h
retn
|
long long testing::internal::FilePath::Normalize(testing::internal::FilePath *this)
{
bool v2; // [rsp+Eh] [rbp-7Ah]
char v3; // [rsp+Fh] [rbp-79h]
long long v4; // [rsp+20h] [rbp-68h] BYREF
long long v5; // [rsp+28h] [rbp-60h] BYREF
long long v6; // [rsp+30h] [rbp-58h] BYREF
_QWORD v7[2]; // [rsp+38h] [rbp-50h] BYREF
long long v8; // [rsp+48h] [rbp-40h] BYREF
long long v9; // [rsp+50h] [rbp-38h] BYREF
long long v10; // [rsp+58h] [rbp-30h] BYREF
char v11; // [rsp+67h] [rbp-21h]
char v12[8]; // [rsp+68h] [rbp-20h] BYREF
long long i; // [rsp+70h] [rbp-18h] BYREF
_QWORD v14[2]; // [rsp+78h] [rbp-10h] BYREF
v14[1] = this;
v14[0] = ((long long (*)(void))std::string::begin)();
for ( i = std::string::cbegin(this); ; __gnu_cxx::__normal_iterator<char const*,std::string>::operator++(&i) )
{
*(_QWORD *)v12 = std::string::end(this);
if ( (ZN9__gnu_cxxeqIPKcPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEQrQT_T0__XeqfL0p_fL0p0_RSt14convertible_toIbEEEEbRKNS_17__normal_iteratorISA_T1_EERKNSD_ISB_SE_EE(
&i,
v12) & 1) != 0 )
break;
v11 = *(_BYTE *)__gnu_cxx::__normal_iterator<char const*,std::string>::operator*((long long)&i);
if ( testing::internal::IsPathSeparator((testing::internal *)(unsigned int)v11) )
{
v9 = std::string::begin(this);
v2 = 1;
if ( (__gnu_cxx::operator==<char *,std::string>(v14, &v9) & 1) == 0 )
{
v7[1] = v14[0];
v8 = std::prev<__gnu_cxx::__normal_iterator<char *,std::string>>(v14[0], 1LL);
v2 = *(_BYTE *)__gnu_cxx::__normal_iterator<char *,std::string>::operator*(&v8) != 47;
}
if ( v2 )
{
v7[0] = __gnu_cxx::__normal_iterator<char *,std::string>::operator++(v14, 0LL);
*(_BYTE *)__gnu_cxx::__normal_iterator<char *,std::string>::operator*(v7) = 47;
}
}
else
{
v3 = v11;
v10 = __gnu_cxx::__normal_iterator<char *,std::string>::operator++(v14, 0LL);
*(_BYTE *)__gnu_cxx::__normal_iterator<char *,std::string>::operator*(&v10) = v3;
}
}
__gnu_cxx::__normal_iterator<char const*,std::string>::__normal_iterator<char *>(&v6, v14);
v4 = std::string::end(this);
__gnu_cxx::__normal_iterator<char const*,std::string>::__normal_iterator<char *>(&v5, &v4);
return std::string::erase(this, v6, v5);
}
|
Normalize:
SUB RSP,0x88
MOV qword ptr [RSP + 0x80],RDI
MOV RDI,qword ptr [RSP + 0x80]
MOV qword ptr [RSP + 0x10],RDI
CALL 0x002245f0
MOV RDI,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x78],RAX
CALL 0x00224620
MOV qword ptr [RSP + 0x70],RAX
LAB_001f85b5:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x00224690
MOV qword ptr [RSP + 0x68],RAX
LEA RDI,[RSP + 0x70]
LEA RSI,[RSP + 0x68]
CALL 0x00224650
XOR AL,0xff
TEST AL,0x1
JNZ 0x001f85de
JMP 0x001f86c3
LAB_001f85de:
LEA RDI,[RSP + 0x70]
CALL 0x0017e280
MOV AL,byte ptr [RAX]
MOV byte ptr [RSP + 0x67],AL
MOVSX EDI,byte ptr [RSP + 0x67]
CALL 0x001f7860
TEST AL,0x1
JNZ 0x001f862a
MOV AL,byte ptr [RSP + 0x67]
MOV byte ptr [RSP + 0xf],AL
LEA RDI,[RSP + 0x78]
XOR ESI,ESI
CALL 0x002246e0
MOV qword ptr [RSP + 0x58],RAX
LEA RDI,[RSP + 0x58]
CALL 0x00224720
MOV CL,byte ptr [RSP + 0xf]
MOV byte ptr [RAX],CL
JMP 0x001f86b4
LAB_001f862a:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x002245f0
MOV qword ptr [RSP + 0x50],RAX
LEA RDI,[RSP + 0x78]
LEA RSI,[RSP + 0x50]
CALL 0x00224730
MOV CL,AL
MOV AL,0x1
TEST CL,0x1
MOV byte ptr [RSP + 0xe],AL
JNZ 0x001f868a
MOV RAX,qword ptr [RSP + 0x78]
MOV qword ptr [RSP + 0x40],RAX
MOV RDI,qword ptr [RSP + 0x40]
MOV ESI,0x1
CALL 0x00224770
MOV qword ptr [RSP + 0x48],RAX
LEA RDI,[RSP + 0x48]
CALL 0x00224720
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x2f
SETNZ AL
MOV byte ptr [RSP + 0xe],AL
LAB_001f868a:
MOV AL,byte ptr [RSP + 0xe]
TEST AL,0x1
JNZ 0x001f8694
JMP 0x001f86b2
LAB_001f8694:
LEA RDI,[RSP + 0x78]
XOR ESI,ESI
CALL 0x002246e0
MOV qword ptr [RSP + 0x38],RAX
LEA RDI,[RSP + 0x38]
CALL 0x00224720
MOV byte ptr [RAX],0x2f
LAB_001f86b2:
JMP 0x001f86b4
LAB_001f86b4:
LEA RDI,[RSP + 0x70]
CALL 0x0017e290
JMP 0x001f85b5
LAB_001f86c3:
LEA RDI,[RSP + 0x30]
LEA RSI,[RSP + 0x78]
CALL 0x00224880
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x00224690
MOV qword ptr [RSP + 0x20],RAX
LEA RDI,[RSP + 0x28]
LEA RSI,[RSP + 0x20]
CALL 0x00224880
MOV RDI,qword ptr [RSP + 0x10]
MOV RSI,qword ptr [RSP + 0x30]
MOV RDX,qword ptr [RSP + 0x28]
CALL 0x002247b0
MOV qword ptr [RSP + 0x18],RAX
ADD RSP,0x88
RET
|
/* testing::internal::FilePath::Normalize() */
void __thiscall testing::internal::FilePath::Normalize(FilePath *this)
{
char cVar1;
byte bVar2;
char *pcVar3;
ulong uVar4;
int1 *puVar5;
bool bVar6;
int8 local_68;
int8 local_60;
int8 local_58;
int8 local_50;
int8 local_48;
int8 local_40;
int8 local_38;
int8 local_30;
char local_21;
int8 local_20;
int8 local_18;
int8 local_10;
FilePath *local_8;
local_8 = this;
local_10 = std::__cxx11::string::begin((string *)this);
local_18 = std::__cxx11::string::cbegin((string *)this);
while( true ) {
local_20 = std::__cxx11::string::end((string *)this);
bVar2 = _ZN9__gnu_cxxeqIPKcPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEQrQT_T0__XeqfL0p_fL0p0_RSt14convertible_toIbEEEEbRKNS_17__normal_iteratorISA_T1_EERKNSD_ISB_SE_EE
(&local_18);
if (((bVar2 ^ 0xff) & 1) == 0) break;
pcVar3 = (char *)__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::operator*
((__normal_iterator<char_const*,std::__cxx11::string> *)&local_18);
local_21 = *pcVar3;
uVar4 = IsPathSeparator(local_21);
cVar1 = local_21;
if ((uVar4 & 1) == 0) {
local_30 = __gnu_cxx::__normal_iterator<char*,std::__cxx11::string>::operator++
((__normal_iterator<char*,std::__cxx11::string> *)&local_10,0);
pcVar3 = (char *)__gnu_cxx::__normal_iterator<char*,std::__cxx11::string>::operator*
((__normal_iterator<char*,std::__cxx11::string> *)&local_30);
*pcVar3 = cVar1;
}
else {
local_38 = std::__cxx11::string::begin((string *)this);
bVar2 = _ZN9__gnu_cxxeqIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEbRKNS_17__normal_iteratorIT_T0_EESD_QrqXeqcldtfp_4baseEcldtfp0_4baseERSt14convertible_toIbEE
(&local_10);
bVar6 = true;
if ((bVar2 & 1) == 0) {
local_48 = local_10;
local_40 = std::prev<__gnu_cxx::__normal_iterator<char*,std::__cxx11::string>>(local_10);
pcVar3 = (char *)__gnu_cxx::__normal_iterator<char*,std::__cxx11::string>::operator*
((__normal_iterator<char*,std::__cxx11::string> *)&local_40);
bVar6 = *pcVar3 != '/';
}
if (bVar6) {
local_50 = __gnu_cxx::__normal_iterator<char*,std::__cxx11::string>::operator++
((__normal_iterator<char*,std::__cxx11::string> *)&local_10,0);
puVar5 = (int1 *)
__gnu_cxx::__normal_iterator<char*,std::__cxx11::string>::operator*
((__normal_iterator<char*,std::__cxx11::string> *)&local_50);
*puVar5 = 0x2f;
}
}
__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::operator++
((__normal_iterator<char_const*,std::__cxx11::string> *)&local_18);
}
__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::__normal_iterator<char*>
((__normal_iterator<char_const*,std::__cxx11::string> *)&local_58,
(__normal_iterator *)&local_10);
local_68 = std::__cxx11::string::end((string *)this);
__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::__normal_iterator<char*>
((__normal_iterator<char_const*,std::__cxx11::string> *)&local_60,
(__normal_iterator *)&local_68);
std::__cxx11::string::erase((string *)this,local_58,local_60);
return;
}
|
|
64,899 |
ma_zlib_ctx_init
|
eloqsql/libmariadb/plugins/compress/c_zlib.c
|
static ma_compress_ctx *ma_zlib_ctx_init(int compression_level)
{
ma_compress_ctx *ctx;
if (!(ctx = (ma_compress_ctx *)calloc(1, sizeof(ma_compress_ctx))))
return NULL;
ctx->compression_level= (compression_level == COMPRESSION_LEVEL_DEFAULT) ?
Z_DEFAULT_COMPRESSION : compression_level;
return ctx;
}
|
O3
|
c
|
ma_zlib_ctx_init:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %edi, %ebx
movl $0x1, %edi
movl $0x20, %esi
callq 0x132e0
testq %rax, %rax
je 0x3565e
cmpl $0x7fffffff, %ebx # imm = 0x7FFFFFFF
movl $0xffffffff, %ecx # imm = 0xFFFFFFFF
cmovnel %ebx, %ecx
movl %ecx, 0x10(%rax)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
|
ma_zlib_ctx_init:
push rbp
mov rbp, rsp
push rbx
push rax
mov ebx, edi
mov edi, 1
mov esi, 20h ; ' '
call _calloc
test rax, rax
jz short loc_3565E
cmp ebx, 7FFFFFFFh
mov ecx, 0FFFFFFFFh
cmovnz ecx, ebx
mov [rax+10h], ecx
loc_3565E:
add rsp, 8
pop rbx
pop rbp
retn
|
long long ma_zlib_ctx_init(int a1)
{
long long result; // rax
int v2; // ecx
result = calloc(1LL, 32LL);
if ( result )
{
v2 = -1;
if ( a1 != 0x7FFFFFFF )
v2 = a1;
*(_DWORD *)(result + 16) = v2;
}
return result;
}
|
ma_zlib_ctx_init:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV EBX,EDI
MOV EDI,0x1
MOV ESI,0x20
CALL 0x001132e0
TEST RAX,RAX
JZ 0x0013565e
CMP EBX,0x7fffffff
MOV ECX,0xffffffff
CMOVNZ ECX,EBX
MOV dword ptr [RAX + 0x10],ECX
LAB_0013565e:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
void ma_zlib_ctx_init(int param_1)
{
void *pvVar1;
int iVar2;
pvVar1 = calloc(1,0x20);
if (pvVar1 != (void *)0x0) {
iVar2 = -1;
if (param_1 != 0x7fffffff) {
iVar2 = param_1;
}
*(int *)((long)pvVar1 + 0x10) = iVar2;
}
return;
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.