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
|
---|---|---|---|---|---|---|---|---|---|---|---|
7,800 |
mysql_close_slow_part
|
eloqsql/libmariadb/libmariadb/mariadb_lib.c
|
void mysql_close_slow_part(MYSQL *mysql)
{
if (mysql->net.pvio)
{
free_old_query(mysql);
mysql->status=MYSQL_STATUS_READY; /* Force command */
mysql->options.reconnect=0;
if (mysql->net.pvio && mysql->net.buff)
ma_simple_command(mysql, COM_QUIT,NullS,0,1,0);
end_server(mysql);
}
/* there is an ongoing async operation */
else if (mysql->options.extension && mysql->options.extension->async_context)
{
if (mysql->options.extension->async_context->pending_gai_res)
{
freeaddrinfo(mysql->options.extension->async_context->pending_gai_res);
mysql->options.extension->async_context->pending_gai_res = 0;
}
if (mysql->options.extension->async_context->pvio)
{
ma_pvio_close(mysql->options.extension->async_context->pvio);
mysql->options.extension->async_context->pvio = 0;
}
}
}
|
O0
|
c
|
mysql_close_slow_part:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, (%rax)
je 0x44f68
movq -0x8(%rbp), %rdi
callq 0x45030
movq -0x8(%rbp), %rax
movl $0x0, 0x488(%rax)
movq -0x8(%rbp), %rax
movb $0x0, 0x43b(%rax)
movq -0x8(%rbp), %rax
cmpq $0x0, (%rax)
je 0x44f5a
movq -0x8(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x44f5a
movq -0x8(%rbp), %rdi
movl $0x1, %r8d
xorl %eax, %eax
movl %eax, %r9d
movl %r8d, %esi
movq %r9, %rdx
movq %r9, %rcx
callq 0x3dce0
movq -0x8(%rbp), %rdi
callq 0x3ce40
jmp 0x4501e
movq -0x8(%rbp), %rax
cmpq $0x0, 0x480(%rax)
je 0x4501c
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
cmpq $0x0, 0x28(%rax)
je 0x4501c
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
cmpq $0x0, 0x30(%rax)
je 0x44fd5
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x37680
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq $0x0, 0x30(%rax)
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
cmpq $0x0, 0x18(%rax)
je 0x4501a
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq 0x18(%rax), %rdi
callq 0x4aa30
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq $0x0, 0x18(%rax)
jmp 0x4501c
jmp 0x4501e
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
mysql_close_slow_part:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
cmp qword ptr [rax], 0
jz short loc_44F68
mov rdi, [rbp+var_8]
call free_old_query
mov rax, [rbp+var_8]
mov dword ptr [rax+488h], 0
mov rax, [rbp+var_8]
mov byte ptr [rax+43Bh], 0
mov rax, [rbp+var_8]
cmp qword ptr [rax], 0
jz short loc_44F5A
mov rax, [rbp+var_8]
cmp qword ptr [rax+8], 0
jz short loc_44F5A
mov rdi, [rbp+var_8]
mov r8d, 1
xor eax, eax
mov r9d, eax
mov esi, r8d
mov rdx, r9
mov rcx, r9
call ma_simple_command
loc_44F5A:
mov rdi, [rbp+var_8]
call end_server
jmp loc_4501E
loc_44F68:
mov rax, [rbp+var_8]
cmp qword ptr [rax+480h], 0
jz loc_4501C
mov rax, [rbp+var_8]
mov rax, [rax+480h]
cmp qword ptr [rax+28h], 0
jz loc_4501C
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
cmp qword ptr [rax+30h], 0
jz short loc_44FD5
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov rdi, [rax+30h]
call _freeaddrinfo
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov qword ptr [rax+30h], 0
loc_44FD5:
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
cmp qword ptr [rax+18h], 0
jz short loc_4501A
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov rdi, [rax+18h]
call ma_pvio_close
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov qword ptr [rax+18h], 0
loc_4501A:
jmp short $+2
loc_4501C:
jmp short $+2
loc_4501E:
add rsp, 10h
pop rbp
retn
|
long long mysql_close_slow_part(long long a1)
{
long long result; // rax
if ( *(_QWORD *)a1 )
{
free_old_query(a1);
*(_DWORD *)(a1 + 1160) = 0;
*(_BYTE *)(a1 + 1083) = 0;
if ( *(_QWORD *)a1 )
{
if ( *(_QWORD *)(a1 + 8) )
ma_simple_command(a1, 1u, 0LL, 0LL, 1, 0LL);
}
return end_server((_QWORD *)a1);
}
else
{
result = a1;
if ( *(_QWORD *)(a1 + 1152) )
{
result = *(_QWORD *)(a1 + 1152);
if ( *(_QWORD *)(result + 40) )
{
if ( *(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL) )
{
freeaddrinfo(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL));
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL) = 0LL;
}
result = *(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL);
if ( *(_QWORD *)(result + 24) )
{
ma_pvio_close(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 24LL));
result = *(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL);
*(_QWORD *)(result + 24) = 0LL;
}
}
}
}
return result;
}
|
mysql_close_slow_part:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX],0x0
JZ 0x00144f68
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00145030
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x488],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x43b],0x0
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX],0x0
JZ 0x00144f5a
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x8],0x0
JZ 0x00144f5a
MOV RDI,qword ptr [RBP + -0x8]
MOV R8D,0x1
XOR EAX,EAX
MOV R9D,EAX
MOV ESI,R8D
MOV RDX,R9
MOV RCX,R9
CALL 0x0013dce0
LAB_00144f5a:
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x0013ce40
JMP 0x0014501e
LAB_00144f68:
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x480],0x0
JZ 0x0014501c
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
CMP qword ptr [RAX + 0x28],0x0
JZ 0x0014501c
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
CMP qword ptr [RAX + 0x30],0x0
JZ 0x00144fd5
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV RDI,qword ptr [RAX + 0x30]
CALL 0x00137680
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RAX + 0x30],0x0
LAB_00144fd5:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
CMP qword ptr [RAX + 0x18],0x0
JZ 0x0014501a
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
CALL 0x0014aa30
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RAX + 0x18],0x0
LAB_0014501a:
JMP 0x0014501c
LAB_0014501c:
JMP 0x0014501e
LAB_0014501e:
ADD RSP,0x10
POP RBP
RET
|
void mysql_close_slow_part(long *param_1)
{
if (*param_1 == 0) {
if ((param_1[0x90] != 0) && (*(long *)(param_1[0x90] + 0x28) != 0)) {
if (*(long *)(*(long *)(param_1[0x90] + 0x28) + 0x30) != 0) {
freeaddrinfo(*(addrinfo **)(*(long *)(param_1[0x90] + 0x28) + 0x30));
*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x30) = 0;
}
if (*(long *)(*(long *)(param_1[0x90] + 0x28) + 0x18) != 0) {
ma_pvio_close(*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x18));
*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x18) = 0;
}
}
}
else {
free_old_query(param_1);
*(int4 *)(param_1 + 0x91) = 0;
*(int1 *)((long)param_1 + 0x43b) = 0;
if ((*param_1 != 0) && (param_1[1] != 0)) {
ma_simple_command(param_1,1,0,0);
}
end_server(param_1);
}
return;
}
|
|
7,801 |
pvio_socket_has_data
|
eloqsql/libmariadb/plugins/pvio/pvio_socket.c
|
my_bool pvio_socket_has_data(MARIADB_PVIO *pvio, ssize_t *data_len)
{
struct st_pvio_socket *csock= NULL;
char tmp_buf;
ssize_t len;
my_bool mode;
if (!pvio || !pvio->data)
return 0;
csock= (struct st_pvio_socket *)pvio->data;
/* MSG_PEEK: Peeks at the incoming data. The data is copied into the buffer,
but is not removed from the input queue.
*/
pvio_socket_blocking(pvio, 0, &mode);
len= recv(csock->socket, &tmp_buf, sizeof(tmp_buf), MSG_PEEK);
pvio_socket_blocking(pvio, mode, 0);
if (len < 0)
return 1;
*data_len= len;
return 0;
}
|
O0
|
c
|
pvio_socket_has_data:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x1ab29
movq -0x10(%rbp), %rax
cmpq $0x0, (%rax)
jne 0x1ab2f
movb $0x0, -0x1(%rbp)
jmp 0x1ab93
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rdi
xorl %esi, %esi
leaq -0x31(%rbp), %rdx
callq 0x19ad0
movq -0x20(%rbp), %rax
movl (%rax), %edi
leaq -0x21(%rbp), %rsi
movl $0x1, %edx
movl $0x2, %ecx
callq 0x171c0
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rdi
xorl %eax, %eax
movl %eax, %edx
movsbl -0x31(%rbp), %esi
callq 0x19ad0
cmpq $0x0, -0x30(%rbp)
jge 0x1ab84
movb $0x1, -0x1(%rbp)
jmp 0x1ab93
movq -0x30(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
|
pvio_socket_has_data:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], 0
cmp [rbp+var_10], 0
jz short loc_1AB29
mov rax, [rbp+var_10]
cmp qword ptr [rax], 0
jnz short loc_1AB2F
loc_1AB29:
mov [rbp+var_1], 0
jmp short loc_1AB93
loc_1AB2F:
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_20], rax
mov rdi, [rbp+var_10]
xor esi, esi
lea rdx, [rbp+var_31]
call pvio_socket_blocking
mov rax, [rbp+var_20]
mov edi, [rax]
lea rsi, [rbp+var_21]
mov edx, 1
mov ecx, 2
call _recv
mov [rbp+var_30], rax
mov rdi, [rbp+var_10]
xor eax, eax
mov edx, eax
movsx esi, [rbp+var_31]
call pvio_socket_blocking
cmp [rbp+var_30], 0
jge short loc_1AB84
mov [rbp+var_1], 1
jmp short loc_1AB93
loc_1AB84:
mov rcx, [rbp+var_30]
mov rax, [rbp+var_18]
mov [rax], rcx
mov [rbp+var_1], 0
loc_1AB93:
mov al, [rbp+var_1]
add rsp, 40h
pop rbp
retn
|
char pvio_socket_has_data(unsigned int **a1, long long *a2)
{
char v3; // [rsp+Fh] [rbp-31h] BYREF
long long v4; // [rsp+10h] [rbp-30h]
char v5; // [rsp+1Fh] [rbp-21h] BYREF
unsigned int *v6; // [rsp+20h] [rbp-20h]
long long *v7; // [rsp+28h] [rbp-18h]
unsigned int **v8; // [rsp+30h] [rbp-10h]
v8 = a1;
v7 = a2;
v6 = 0LL;
if ( !a1 || !*v8 )
return 0;
v6 = *v8;
pvio_socket_blocking(v8, 0, &v3);
v4 = recv(*v6, &v5, 1LL, 2LL);
pvio_socket_blocking(v8, v3, 0LL);
if ( v4 < 0 )
return 1;
*v7 = v4;
return 0;
}
|
pvio_socket_has_data:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],0x0
CMP qword ptr [RBP + -0x10],0x0
JZ 0x0011ab29
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX],0x0
JNZ 0x0011ab2f
LAB_0011ab29:
MOV byte ptr [RBP + -0x1],0x0
JMP 0x0011ab93
LAB_0011ab2f:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x20],RAX
MOV RDI,qword ptr [RBP + -0x10]
XOR ESI,ESI
LEA RDX,[RBP + -0x31]
CALL 0x00119ad0
MOV RAX,qword ptr [RBP + -0x20]
MOV EDI,dword ptr [RAX]
LEA RSI,[RBP + -0x21]
MOV EDX,0x1
MOV ECX,0x2
CALL 0x001171c0
MOV qword ptr [RBP + -0x30],RAX
MOV RDI,qword ptr [RBP + -0x10]
XOR EAX,EAX
MOV EDX,EAX
MOVSX ESI,byte ptr [RBP + -0x31]
CALL 0x00119ad0
CMP qword ptr [RBP + -0x30],0x0
JGE 0x0011ab84
MOV byte ptr [RBP + -0x1],0x1
JMP 0x0011ab93
LAB_0011ab84:
MOV RCX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV byte ptr [RBP + -0x1],0x0
LAB_0011ab93:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x40
POP RBP
RET
|
int1 pvio_socket_has_data(long *param_1,long *param_2)
{
char local_39;
long local_38;
int1 local_29;
int *local_28;
long *local_20;
long *local_18;
int1 local_9;
if ((param_1 == (long *)0x0) || (*param_1 == 0)) {
local_9 = 0;
}
else {
local_28 = (int *)*param_1;
local_20 = param_2;
local_18 = param_1;
pvio_socket_blocking(param_1,0,&local_39);
local_38 = recv(*local_28,&local_29,1,2);
pvio_socket_blocking(local_18,(int)local_39,0);
if (local_38 < 0) {
local_9 = 1;
}
else {
*local_20 = local_38;
local_9 = 0;
}
}
return local_9;
}
|
|
7,802 |
google::protobuf::RepeatedField<unsigned int>::AddNAlreadyReserved(int)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/repeated_field.h
|
inline Element* RepeatedField<Element>::AddNAlreadyReserved(int elements) {
GOOGLE_DCHECK_GE(total_size_ - current_size_, elements)
<< total_size_ << ", " << current_size_;
// Warning: sometimes people call this when elements == 0 and
// total_size_ == 0. In this case the return pointer points to a zero size
// array (n == 0). Hence we can just use unsafe_elements(), because the user
// cannot dereference the pointer anyway.
Element* ret = unsafe_elements() + current_size_;
current_size_ += elements;
return ret;
}
|
O0
|
c
|
google::protobuf::RepeatedField<unsigned int>::AddNAlreadyReserved(int):
subq $0x98, %rsp
movq %rdi, 0x90(%rsp)
movl %esi, 0x8c(%rsp)
movq 0x90(%rsp), %rax
movq %rax, 0x28(%rsp)
xorl %eax, %eax
testb $0x1, %al
jne 0x19029e
jmp 0x19038f
movq 0x28(%rsp), %rcx
movl 0x4(%rcx), %eax
subl (%rcx), %eax
movl 0x8c(%rsp), %ecx
movb $0x0, 0x4f(%rsp)
cmpl %ecx, %eax
jl 0x1902bd
jmp 0x190354
leaq 0x253dec(%rip), %rdx # 0x3e40b0
leaq 0x50(%rsp), %rdi
movq %rdi, 0x18(%rsp)
movl $0x3, %esi
movl $0x276, %ecx # imm = 0x276
callq 0x19a670
movq 0x18(%rsp), %rdi
movb $0x1, 0x4f(%rsp)
leaq 0x253fd0(%rip), %rsi # 0x3e42be
callq 0x199f30
movq %rax, 0x20(%rsp)
jmp 0x1902fa
movq 0x20(%rsp), %rdi
movq 0x28(%rsp), %rax
movl 0x4(%rax), %esi
callq 0x19a440
movq %rax, 0x10(%rsp)
jmp 0x190313
movq 0x10(%rsp), %rdi
leaq 0x25c24f(%rip), %rsi # 0x3ec56e
callq 0x199f30
movq %rax, 0x8(%rsp)
jmp 0x19032b
movq 0x8(%rsp), %rdi
movq 0x28(%rsp), %rax
movl (%rax), %esi
callq 0x19a440
movq %rax, (%rsp)
jmp 0x190342
movq (%rsp), %rsi
leaq 0x3b(%rsp), %rdi
callq 0x19a0e0
jmp 0x190352
jmp 0x190354
testb $0x1, 0x4f(%rsp)
jne 0x19035d
jmp 0x190367
leaq 0x50(%rsp), %rdi
callq 0x19a6b0
jmp 0x190293
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x40(%rsp)
movl %eax, 0x3c(%rsp)
testb $0x1, 0x4f(%rsp)
jne 0x190383
jmp 0x19038d
leaq 0x50(%rsp), %rdi
callq 0x19a6b0
jmp 0x1903c8
movq 0x28(%rsp), %rdi
callq 0x191c70
movq %rax, %rcx
movq 0x28(%rsp), %rax
movslq (%rax), %rdx
shlq $0x3, %rdx
addq %rdx, %rcx
movq %rcx, 0x30(%rsp)
movl 0x8c(%rsp), %ecx
addl (%rax), %ecx
movl %ecx, (%rax)
movq 0x30(%rsp), %rax
addq $0x98, %rsp
retq
movq 0x40(%rsp), %rdi
callq 0x90db0
nopw %cs:(%rax,%rax)
nopl (%rax)
|
_ZN6google8protobuf13RepeatedFieldIdE19AddNAlreadyReservedEi:
sub rsp, 98h
mov [rsp+98h+var_8], rdi
mov [rsp+98h+var_C], esi
mov rax, [rsp+98h+var_8]
mov [rsp+98h+var_70], rax
loc_190293:
xor eax, eax
test al, 1
jnz short loc_19029E
jmp loc_19038F
loc_19029E:
mov rcx, [rsp+98h+var_70]
mov eax, [rcx+4]
sub eax, [rcx]
mov ecx, [rsp+98h+var_C]
mov [rsp+98h+var_49], 0
cmp eax, ecx
jl short loc_1902BD
jmp loc_190354
loc_1902BD:
lea rdx, aWorkspaceLlm4b_21; "/workspace/llm4binary/github2025/aimrt_"...
lea rdi, [rsp+98h+var_48]
mov [rsp+98h+var_80], rdi
mov esi, 3
mov ecx, 276h
call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int)
mov rdi, [rsp+98h+var_80]
mov [rsp+98h+var_49], 1
lea rsi, aCheckFailedTot; "CHECK failed: (total_size_ - current_si"...
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
mov [rsp+98h+var_78], rax
jmp short $+2
loc_1902FA:
mov rdi, [rsp+98h+var_78]
mov rax, [rsp+98h+var_70]
mov esi, [rax+4]
call _ZN6google8protobuf8internal10LogMessagelsEi; google::protobuf::internal::LogMessage::operator<<(int)
mov [rsp+98h+var_88], rax
jmp short $+2
loc_190313:
mov rdi, [rsp+98h+var_88]
lea rsi, a0_0+4; ", "
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
mov [rsp+98h+var_90], rax
jmp short $+2
loc_19032B:
mov rdi, [rsp+98h+var_90]
mov rax, [rsp+98h+var_70]
mov esi, [rax]
call _ZN6google8protobuf8internal10LogMessagelsEi; google::protobuf::internal::LogMessage::operator<<(int)
mov [rsp+98h+var_98], rax
jmp short $+2
loc_190342:
mov rsi, [rsp+98h+var_98]
lea rdi, [rsp+98h+var_5D]
call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &)
jmp short $+2
loc_190352:
jmp short $+2
loc_190354:
test [rsp+98h+var_49], 1
jnz short loc_19035D
jmp short loc_190367
loc_19035D:
lea rdi, [rsp+98h+var_48]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
loc_190367:
jmp loc_190293
mov rcx, rax
mov eax, edx
mov [rsp+arg_38], rcx
mov [rsp+arg_34], eax
test [rsp+arg_47], 1
jnz short loc_190383
jmp short loc_19038D
loc_190383:
lea rdi, [rsp+arg_48]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
loc_19038D:
jmp short loc_1903C8
loc_19038F:
mov rdi, [rsp+98h+var_70]
call _ZNK6google8protobuf13RepeatedFieldIdE15unsafe_elementsEv; google::protobuf::RepeatedField<double>::unsafe_elements(void)
mov rcx, rax
mov rax, [rsp+98h+var_70]
movsxd rdx, dword ptr [rax]
shl rdx, 3
add rcx, rdx
mov [rsp+98h+var_68], rcx
mov ecx, [rsp+98h+var_C]
add ecx, [rax]
mov [rax], ecx
mov rax, [rsp+98h+var_68]
add rsp, 98h
retn
loc_1903C8:
mov rdi, [rsp+arg_38]
call __Unwind_Resume
|
long long google::protobuf::RepeatedField<double>::AddNAlreadyReserved(int *a1, int a2)
{
long long v3; // [rsp+30h] [rbp-68h]
int v4; // [rsp+8Ch] [rbp-Ch]
int *v5; // [rsp+90h] [rbp-8h]
v5 = a1;
v4 = a2;
v3 = 8LL * *a1 + google::protobuf::RepeatedField<double>::unsafe_elements(a1);
*a1 += v4;
return v3;
}
| |||
7,803 |
google::protobuf::RepeatedField<unsigned int>::AddNAlreadyReserved(int)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/repeated_field.h
|
inline Element* RepeatedField<Element>::AddNAlreadyReserved(int elements) {
GOOGLE_DCHECK_GE(total_size_ - current_size_, elements)
<< total_size_ << ", " << current_size_;
// Warning: sometimes people call this when elements == 0 and
// total_size_ == 0. In this case the return pointer points to a zero size
// array (n == 0). Hence we can just use unsafe_elements(), because the user
// cannot dereference the pointer anyway.
Element* ret = unsafe_elements() + current_size_;
current_size_ += elements;
return ret;
}
|
O3
|
c
|
google::protobuf::RepeatedField<unsigned int>::AddNAlreadyReserved(int):
movslq (%rdi), %rax
addl %eax, %esi
shlq $0x3, %rax
addq 0x8(%rdi), %rax
movl %esi, (%rdi)
retq
|
_ZN6google8protobuf13RepeatedFieldIdE19AddNAlreadyReservedEi:
movsxd rax, dword ptr [rdi]
add esi, eax
shl rax, 3
add rax, [rdi+8]
mov [rdi], esi
retn
|
long long google::protobuf::RepeatedField<double>::AddNAlreadyReserved(int *a1, int a2)
{
long long v2; // rax
int v3; // esi
long long result; // rax
v2 = *a1;
v3 = v2 + a2;
result = *((_QWORD *)a1 + 1) + 8 * v2;
*a1 = v3;
return result;
}
|
AddNAlreadyReserved:
MOVSXD RAX,dword ptr [RDI]
ADD ESI,EAX
SHL RAX,0x3
ADD RAX,qword ptr [RDI + 0x8]
MOV dword ptr [RDI],ESI
RET
|
/* google::protobuf::RepeatedField<double>::AddNAlreadyReserved(int) */
long __thiscall
google::protobuf::RepeatedField<double>::AddNAlreadyReserved
(RepeatedField<double> *this,int param_1)
{
int iVar1;
iVar1 = *(int *)this;
*(int *)this = param_1 + iVar1;
return (long)iVar1 * 8 + *(long *)(this + 8);
}
|
|
7,804 |
ma_multi_malloc
|
eloqsql/libmariadb/libmariadb/ma_alloc.c
|
void *ma_multi_malloc(myf myFlags, ...)
{
va_list args;
char **ptr,*start,*res;
size_t tot_length,length;
va_start(args,myFlags);
tot_length=0;
while ((ptr=va_arg(args, char **)))
{
length=va_arg(args, size_t);
tot_length+=ALIGN_SIZE(length);
}
va_end(args);
if (!(start=(char *)malloc(tot_length)))
return 0;
va_start(args,myFlags);
res=start;
while ((ptr=va_arg(args, char **)))
{
*ptr=res;
length=va_arg(args,size_t);
res+=ALIGN_SIZE(length);
}
va_end(args);
return start;
}
|
O3
|
c
|
ma_multi_malloc:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0xd0, %rsp
leaq -0xe0(%rbp), %rbx
movq %rsi, 0x8(%rbx)
movq %rdx, 0x10(%rbx)
movq %rcx, 0x18(%rbx)
movq %r8, 0x20(%rbx)
movq %r9, 0x28(%rbx)
testb %al, %al
je 0x2f69e
movaps %xmm0, -0xb0(%rbp)
movaps %xmm1, -0xa0(%rbp)
movaps %xmm2, -0x90(%rbp)
movaps %xmm3, -0x80(%rbp)
movaps %xmm4, -0x70(%rbp)
movaps %xmm5, -0x60(%rbp)
movaps %xmm6, -0x50(%rbp)
movaps %xmm7, -0x40(%rbp)
movq %rbx, -0x20(%rbp)
leaq 0x10(%rbp), %rcx
movq %rcx, -0x28(%rbp)
movabsq $0x3000000008, %r14 # imm = 0x3000000008
movq %r14, -0x30(%rbp)
movl $0x8, %eax
xorl %edi, %edi
cmpl $0x28, %eax
ja 0x2f6d4
movq %rcx, %rdx
movl %eax, %ecx
addq %rbx, %rcx
addl $0x8, %eax
movl %eax, -0x30(%rbp)
jmp 0x2f6dc
leaq 0x8(%rcx), %rdx
movq %rdx, -0x28(%rbp)
cmpq $0x0, (%rcx)
je 0x2f70f
cmpl $0x28, %eax
ja 0x2f6f7
movq %rdx, %rcx
movl %eax, %edx
addq %rbx, %rdx
addl $0x8, %eax
movl %eax, -0x30(%rbp)
jmp 0x2f6ff
leaq 0x8(%rdx), %rcx
movq %rcx, -0x28(%rbp)
movq (%rdx), %rdx
addq $0x7, %rdx
andq $-0x8, %rdx
addq %rdx, %rdi
jmp 0x2f6bf
callq 0x14620
testq %rax, %rax
je 0x2f78f
movq %rbx, -0x20(%rbp)
leaq 0x10(%rbp), %rcx
movq %rcx, -0x28(%rbp)
movq %r14, -0x30(%rbp)
movl $0x8, %edx
movq %rax, %rcx
cmpl $0x28, %edx
ja 0x2f744
movl %edx, %esi
addq -0x20(%rbp), %rsi
addl $0x8, %edx
movl %edx, -0x30(%rbp)
jmp 0x2f750
movq -0x28(%rbp), %rsi
leaq 0x8(%rsi), %rdx
movq %rdx, -0x28(%rbp)
movq (%rsi), %rdx
testq %rdx, %rdx
je 0x2f78f
movq %rcx, (%rdx)
movl -0x30(%rbp), %edx
cmpq $0x28, %rdx
ja 0x2f773
movq %rdx, %rsi
addq -0x20(%rbp), %rsi
addl $0x8, %edx
movl %edx, -0x30(%rbp)
jmp 0x2f77f
movq -0x28(%rbp), %rsi
leaq 0x8(%rsi), %rdi
movq %rdi, -0x28(%rbp)
movq (%rsi), %rsi
addq $0x7, %rsi
andq $-0x8, %rsi
addq %rsi, %rcx
jmp 0x2f731
addq $0xd0, %rsp
popq %rbx
popq %r14
popq %rbp
retq
nop
|
ma_multi_malloc:
push rbp
mov rbp, rsp
push r14
push rbx
sub rsp, 0D0h
lea rbx, [rbp+var_E0]
mov [rbx+8], rsi
mov [rbx+10h], rdx
mov [rbx+18h], rcx
mov [rbx+20h], r8
mov [rbx+28h], r9
test al, al
jz short loc_2F69E
movaps [rbp+var_B0], xmm0
movaps [rbp+var_A0], xmm1
movaps [rbp+var_90], xmm2
movaps [rbp+var_80], xmm3
movaps [rbp+var_70], xmm4
movaps [rbp+var_60], xmm5
movaps [rbp+var_50], xmm6
movaps [rbp+var_40], xmm7
loc_2F69E:
mov [rbp+var_20], rbx
lea rcx, [rbp+arg_0]
mov [rbp+var_28], rcx
mov r14, 3000000008h
mov [rbp+var_30], r14
mov eax, 8
xor edi, edi
loc_2F6BF:
cmp eax, 28h ; '('
ja short loc_2F6D4
mov rdx, rcx
mov ecx, eax
add rcx, rbx
add eax, 8
mov dword ptr [rbp+var_30], eax
jmp short loc_2F6DC
loc_2F6D4:
lea rdx, [rcx+8]
mov [rbp+var_28], rdx
loc_2F6DC:
cmp qword ptr [rcx], 0
jz short loc_2F70F
cmp eax, 28h ; '('
ja short loc_2F6F7
mov rcx, rdx
mov edx, eax
add rdx, rbx
add eax, 8
mov dword ptr [rbp+var_30], eax
jmp short loc_2F6FF
loc_2F6F7:
lea rcx, [rdx+8]
mov [rbp+var_28], rcx
loc_2F6FF:
mov rdx, [rdx]
add rdx, 7
and rdx, 0FFFFFFFFFFFFFFF8h
add rdi, rdx
jmp short loc_2F6BF
loc_2F70F:
call _malloc
test rax, rax
jz short loc_2F78F
mov [rbp+var_20], rbx
lea rcx, [rbp+arg_0]
mov [rbp+var_28], rcx
mov [rbp+var_30], r14
mov edx, 8
mov rcx, rax
loc_2F731:
cmp edx, 28h ; '('
ja short loc_2F744
mov esi, edx
add rsi, [rbp+var_20]
add edx, 8
mov dword ptr [rbp+var_30], edx
jmp short loc_2F750
loc_2F744:
mov rsi, [rbp+var_28]
lea rdx, [rsi+8]
mov [rbp+var_28], rdx
loc_2F750:
mov rdx, [rsi]
test rdx, rdx
jz short loc_2F78F
mov [rdx], rcx
mov edx, dword ptr [rbp+var_30]
cmp rdx, 28h ; '('
ja short loc_2F773
mov rsi, rdx
add rsi, [rbp+var_20]
add edx, 8
mov dword ptr [rbp+var_30], edx
jmp short loc_2F77F
loc_2F773:
mov rsi, [rbp+var_28]
lea rdi, [rsi+8]
mov [rbp+var_28], rdi
loc_2F77F:
mov rsi, [rsi]
add rsi, 7
and rsi, 0FFFFFFFFFFFFFFF8h
add rcx, rsi
jmp short loc_2F731
loc_2F78F:
add rsp, 0D0h
pop rbx
pop r14
pop rbp
retn
|
long long ma_multi_malloc(
_DWORD a1,
long long a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14,
char a15)
{
char *v15; // rcx
unsigned int v16; // eax
long long i; // rdi
char *v18; // rdx
long long result; // rax
unsigned int v20; // edx
long long j; // rcx
char *v22; // rsi
char *v23; // rsi
_BYTE v24[8]; // [rsp+0h] [rbp-E0h] BYREF
long long v25; // [rsp+8h] [rbp-D8h]
long long v26; // [rsp+10h] [rbp-D0h]
long long v27; // [rsp+18h] [rbp-C8h]
long long v28; // [rsp+20h] [rbp-C0h]
long long v29; // [rsp+28h] [rbp-B8h]
__m128 v30; // [rsp+30h] [rbp-B0h]
__m128 v31; // [rsp+40h] [rbp-A0h]
__m128 v32; // [rsp+50h] [rbp-90h]
__m128 v33; // [rsp+60h] [rbp-80h]
__m128 v34; // [rsp+70h] [rbp-70h]
__m128 v35; // [rsp+80h] [rbp-60h]
__m128 v36; // [rsp+90h] [rbp-50h]
__m128 v37; // [rsp+A0h] [rbp-40h]
long long v38; // [rsp+B0h] [rbp-30h]
char *v39; // [rsp+B8h] [rbp-28h]
_BYTE *v40; // [rsp+C0h] [rbp-20h]
v30 = a7;
v31 = a8;
v32 = a9;
v33 = a10;
v34 = a11;
v35 = a12;
v36 = a13;
v37 = a14;
v25 = a2;
v26 = a3;
v27 = a4;
v28 = a5;
v29 = a6;
v40 = v24;
v15 = &a15;
v39 = &a15;
v38 = 0x3000000008LL;
v16 = 8;
for ( i = 0LL; ; i += (*(_QWORD *)v18 + 7LL) & 0xFFFFFFFFFFFFFFF8LL )
{
if ( v16 > 0x28 )
{
v18 = v15 + 8;
v39 = v15 + 8;
}
else
{
v18 = v15;
v15 = &v24[v16];
v16 += 8;
LODWORD(v38) = v16;
}
if ( !*(_QWORD *)v15 )
break;
if ( v16 > 0x28 )
{
v15 = v18 + 8;
v39 = v18 + 8;
}
else
{
v15 = v18;
v18 = &v24[v16];
v16 += 8;
LODWORD(v38) = v16;
}
}
result = malloc(i);
if ( result )
{
v40 = v24;
v39 = &a15;
v38 = 0x3000000008LL;
v20 = 8;
for ( j = result; ; j += (*(_QWORD *)v23 + 7LL) & 0xFFFFFFFFFFFFFFF8LL )
{
if ( v20 > 0x28 )
{
v22 = v39;
v39 += 8;
}
else
{
v22 = &v40[v20];
LODWORD(v38) = v20 + 8;
}
if ( !*(_QWORD *)v22 )
break;
**(_QWORD **)v22 = j;
v20 = v38;
if ( (unsigned int)v38 > 0x28uLL )
{
v23 = v39;
v39 += 8;
}
else
{
v23 = &v40[(unsigned int)v38];
v20 = v38 + 8;
LODWORD(v38) = v38 + 8;
}
}
}
return result;
}
|
ma_multi_malloc:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
SUB RSP,0xd0
LEA RBX,[RBP + -0xe0]
MOV qword ptr [RBX + 0x8],RSI
MOV qword ptr [RBX + 0x10],RDX
MOV qword ptr [RBX + 0x18],RCX
MOV qword ptr [RBX + 0x20],R8
MOV qword ptr [RBX + 0x28],R9
TEST AL,AL
JZ 0x0012f69e
MOVAPS xmmword ptr [RBP + -0xb0],XMM0
MOVAPS xmmword ptr [RBP + -0xa0],XMM1
MOVAPS xmmword ptr [RBP + -0x90],XMM2
MOVAPS xmmword ptr [RBP + -0x80],XMM3
MOVAPS xmmword ptr [RBP + -0x70],XMM4
MOVAPS xmmword ptr [RBP + -0x60],XMM5
MOVAPS xmmword ptr [RBP + -0x50],XMM6
MOVAPS xmmword ptr [RBP + -0x40],XMM7
LAB_0012f69e:
MOV qword ptr [RBP + -0x20],RBX
LEA RCX,[RBP + 0x10]
MOV qword ptr [RBP + -0x28],RCX
MOV R14,0x3000000008
MOV qword ptr [RBP + -0x30],R14
MOV EAX,0x8
XOR EDI,EDI
LAB_0012f6bf:
CMP EAX,0x28
JA 0x0012f6d4
MOV RDX,RCX
MOV ECX,EAX
ADD RCX,RBX
ADD EAX,0x8
MOV dword ptr [RBP + -0x30],EAX
JMP 0x0012f6dc
LAB_0012f6d4:
LEA RDX,[RCX + 0x8]
MOV qword ptr [RBP + -0x28],RDX
LAB_0012f6dc:
CMP qword ptr [RCX],0x0
JZ 0x0012f70f
CMP EAX,0x28
JA 0x0012f6f7
MOV RCX,RDX
MOV EDX,EAX
ADD RDX,RBX
ADD EAX,0x8
MOV dword ptr [RBP + -0x30],EAX
JMP 0x0012f6ff
LAB_0012f6f7:
LEA RCX,[RDX + 0x8]
MOV qword ptr [RBP + -0x28],RCX
LAB_0012f6ff:
MOV RDX,qword ptr [RDX]
ADD RDX,0x7
AND RDX,-0x8
ADD RDI,RDX
JMP 0x0012f6bf
LAB_0012f70f:
CALL 0x00114620
TEST RAX,RAX
JZ 0x0012f78f
MOV qword ptr [RBP + -0x20],RBX
LEA RCX,[RBP + 0x10]
MOV qword ptr [RBP + -0x28],RCX
MOV qword ptr [RBP + -0x30],R14
MOV EDX,0x8
MOV RCX,RAX
LAB_0012f731:
CMP EDX,0x28
JA 0x0012f744
MOV ESI,EDX
ADD RSI,qword ptr [RBP + -0x20]
ADD EDX,0x8
MOV dword ptr [RBP + -0x30],EDX
JMP 0x0012f750
LAB_0012f744:
MOV RSI,qword ptr [RBP + -0x28]
LEA RDX,[RSI + 0x8]
MOV qword ptr [RBP + -0x28],RDX
LAB_0012f750:
MOV RDX,qword ptr [RSI]
TEST RDX,RDX
JZ 0x0012f78f
MOV qword ptr [RDX],RCX
MOV EDX,dword ptr [RBP + -0x30]
CMP RDX,0x28
JA 0x0012f773
MOV RSI,RDX
ADD RSI,qword ptr [RBP + -0x20]
ADD EDX,0x8
MOV dword ptr [RBP + -0x30],EDX
JMP 0x0012f77f
LAB_0012f773:
MOV RSI,qword ptr [RBP + -0x28]
LEA RDI,[RSI + 0x8]
MOV qword ptr [RBP + -0x28],RDI
LAB_0012f77f:
MOV RSI,qword ptr [RSI]
ADD RSI,0x7
AND RSI,-0x8
ADD RCX,RSI
JMP 0x0012f731
LAB_0012f78f:
ADD RSP,0xd0
POP RBX
POP R14
POP RBP
RET
|
void ma_multi_malloc(int8 param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5,int8 param_6,int8 param_7,int8 param_8,
int8 param_9,int8 param_10,int8 param_11,int8 param_12,
int8 param_13,int8 param_14)
{
char in_AL;
uint uVar1;
void *pvVar2;
long *plVar3;
long *plVar4;
ulong uVar5;
long *plVar6;
size_t __size;
long local_e8 [4];
int8 local_c8;
int8 local_c0;
int8 local_b8;
int8 local_a8;
int8 local_98;
int8 local_88;
int8 local_78;
int8 local_68;
int8 local_58;
int8 local_48;
uint local_38;
int4 uStack_34;
long *local_30;
long *local_28;
local_e8[1] = param_10;
local_e8[2] = param_11;
local_e8[3] = param_12;
local_c8 = param_13;
local_c0 = param_14;
if (in_AL != '\0') {
local_b8 = param_1;
local_a8 = param_2;
local_98 = param_3;
local_88 = param_4;
local_78 = param_5;
local_68 = param_6;
local_58 = param_7;
local_48 = param_8;
}
local_28 = local_e8;
plVar6 = (long *)&stack0x00000008;
local_30 = plVar6;
local_38 = 8;
uStack_34 = 0x30;
uVar1 = 8;
__size = 0;
while( true ) {
if (uVar1 < 0x29) {
uVar5 = (ulong)uVar1;
uVar1 = uVar1 + 8;
local_38 = uVar1;
plVar3 = (long *)((long)local_e8 + uVar5);
plVar4 = plVar6;
}
else {
plVar4 = plVar6 + 1;
local_30 = plVar4;
plVar3 = plVar6;
}
if (*plVar3 == 0) break;
if (uVar1 < 0x29) {
uVar5 = (ulong)uVar1;
uVar1 = uVar1 + 8;
local_38 = uVar1;
plVar6 = plVar4;
plVar4 = (long *)((long)local_e8 + uVar5);
}
else {
plVar6 = plVar4 + 1;
local_30 = plVar6;
}
__size = __size + (*plVar4 + 7U & 0xfffffffffffffff8);
}
pvVar2 = malloc(__size);
if (pvVar2 != (void *)0x0) {
local_30 = (long *)&stack0x00000008;
uVar1 = 8;
uVar5 = 8;
while( true ) {
if ((uint)uVar5 < 0x29) {
uVar1 = (uint)uVar5 + 8;
plVar6 = (long *)((long)local_e8 + uVar5);
}
else {
plVar6 = local_30;
local_30 = local_30 + 1;
}
if ((int8 *)*plVar6 == (int8 *)0x0) break;
*(int8 *)*plVar6 = pvVar2;
uVar5 = (ulong)uVar1;
if (uVar5 < 0x29) {
plVar6 = (long *)((long)local_e8 + uVar5);
uVar1 = uVar1 + 8;
uVar5 = (ulong)uVar1;
}
else {
plVar6 = local_30;
local_30 = local_30 + 1;
}
pvVar2 = (void *)((long)pvVar2 + (*plVar6 + 7U & 0xfffffffffffffff8));
}
}
return;
}
|
|
7,805 |
testing::internal::StreamingListener::OnTestSuiteStart(testing::TestSuite const&)
|
seiftnesse[P]memoryallocator/build_O1/_deps/googletest-src/googletest/src/gtest-internal-inl.h
|
void OnTestSuiteStart(const TestSuite& test_suite) override {
SendLn(std::string("event=TestCaseStart&name=") + test_suite.name());
}
|
O1
|
c
|
testing::internal::StreamingListener::OnTestSuiteStart(testing::TestSuite const&):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x38(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x951a(%rip), %rsi # 0x44728
leaq 0x952c(%rip), %rdx # 0x44741
leaq 0x28(%rsp), %r15
movq %r15, %rdi
callq 0xfdfe
movq 0x8(%r14), %rsi
movq %r15, %rdi
callq 0x9a70
leaq 0x18(%rsp), %r14
movq %r14, -0x10(%r14)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x3b255
movq %rdx, 0x8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x18(%rsp)
jmp 0x3b25c
movups (%rcx), %xmm0
movups %xmm0, (%r14)
movq 0x8(%rax), %rdx
leaq 0x8(%rsp), %rsi
movq %rdx, 0x8(%rsi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq 0x8(%rbx), %rdi
callq 0x3c7ae
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x3b298
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x94c0
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0x3b2af
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x94c0
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x3b2da
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x94c0
jmp 0x3b2da
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0x3b2f1
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x94c0
movq %rbx, %rdi
callq 0x99a0
nop
|
_ZN7testing8internal17StreamingListener16OnTestSuiteStartERKNS_9TestSuiteE:
push r15
push r14
push r12
push rbx
sub rsp, 48h
mov r14, rsi
mov rbx, rdi
lea r12, [rsp+68h+var_30]
mov [r12-10h], r12
lea rsi, aEventTestcases; "event=TestCaseStart&name="
lea rdx, aEventTestcases+19h; ""
lea r15, [rsp+68h+var_40]
mov rdi, r15
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rsi, [r14+8]
mov rdi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea r14, [rsp+68h+var_50]
mov [r14-10h], r14
mov rdx, [rax]
mov rcx, rax
add rcx, 10h
cmp rdx, rcx
jz short loc_3B255
mov [rsp+68h+var_60], rdx
mov rdx, [rcx]
mov [rsp+68h+var_50], rdx
jmp short loc_3B25C
loc_3B255:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [r14], xmm0
loc_3B25C:
mov rdx, [rax+8]
lea rsi, [rsp+68h+var_60]
mov [rsi+8], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
mov rdi, [rbx+8]
call _ZN7testing8internal17StreamingListener20AbstractSocketWriter6SendLnERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; testing::internal::StreamingListener::AbstractSocketWriter::SendLn(std::string const&)
mov rdi, [rsp+68h+var_60]; void *
cmp rdi, r14
jz short loc_3B298
mov rsi, [rsp+68h+var_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_3B298:
mov rdi, [rsp+68h+var_40]; void *
cmp rdi, r12
jz short loc_3B2AF
mov rsi, [rsp+68h+var_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_3B2AF:
add rsp, 48h
pop rbx
pop r12
pop r14
pop r15
retn
mov rbx, rax
mov rdi, [rsp+arg_0]; void *
cmp rdi, r14
jz short loc_3B2DA
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_3B2DA
mov rbx, rax
loc_3B2DA:
mov rdi, [rsp+arg_20]; void *
cmp rdi, r12
jz short loc_3B2F1
mov rsi, [rsp+arg_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_3B2F1:
mov rdi, rbx
call __Unwind_Resume
|
void testing::internal::StreamingListener::OnTestSuiteStart(
testing::internal::StreamingListener *this,
const char **a2)
{
long long v2; // rax
int v3; // r8d
int v4; // r9d
__int128 *v5; // rcx
int v6; // edx
void *v7; // [rsp+8h] [rbp-60h] BYREF
long long v8; // [rsp+10h] [rbp-58h]
__int128 v9; // [rsp+18h] [rbp-50h] BYREF
void *v10[2]; // [rsp+28h] [rbp-40h] BYREF
_QWORD v11[6]; // [rsp+38h] [rbp-30h] BYREF
v10[0] = v11;
std::string::_M_construct<char const*>(v10, "event=TestCaseStart&name=", (long long)"");
v2 = std::string::append(v10, a2[1]);
v7 = &v9;
v5 = (__int128 *)(v2 + 16);
if ( *(_QWORD *)v2 == v2 + 16 )
{
v9 = *v5;
}
else
{
v7 = *(void **)v2;
*(_QWORD *)&v9 = *(_QWORD *)v5;
}
v8 = *(_QWORD *)(v2 + 8);
v6 = v8;
*(_QWORD *)v2 = v5;
*(_QWORD *)(v2 + 8) = 0LL;
*(_BYTE *)(v2 + 16) = 0;
testing::internal::StreamingListener::AbstractSocketWriter::SendLn(
*((_QWORD *)this + 1),
(unsigned int)&v7,
v6,
(_DWORD)v5,
v3,
v4);
if ( v7 != &v9 )
operator delete(v7, v9 + 1);
if ( v10[0] != v11 )
operator delete(v10[0], v11[0] + 1LL);
}
|
OnTestSuiteStart:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV R14,RSI
MOV RBX,RDI
LEA R12,[RSP + 0x38]
MOV qword ptr [R12 + -0x10],R12
LEA RSI,[0x144728]
LEA RDX,[0x144741]
LEA R15,[RSP + 0x28]
MOV RDI,R15
CALL 0x0010fdfe
MOV RSI,qword ptr [R14 + 0x8]
LAB_0013b226:
MOV RDI,R15
CALL 0x00109a70
LEA R14,[RSP + 0x18]
MOV qword ptr [R14 + -0x10],R14
MOV RDX,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RDX,RCX
JZ 0x0013b255
MOV qword ptr [RSP + 0x8],RDX
MOV RDX,qword ptr [RCX]
MOV qword ptr [RSP + 0x18],RDX
JMP 0x0013b25c
LAB_0013b255:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [R14],XMM0
LAB_0013b25c:
MOV RDX,qword ptr [RAX + 0x8]
LEA RSI,[RSP + 0x8]
MOV qword ptr [RSI + 0x8],RDX
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV byte ptr [RAX + 0x10],0x0
MOV RDI,qword ptr [RBX + 0x8]
LAB_0013b27c:
CALL 0x0013c7ae
LAB_0013b281:
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,R14
JZ 0x0013b298
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001094c0
LAB_0013b298:
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R12
JZ 0x0013b2af
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x001094c0
LAB_0013b2af:
ADD RSP,0x48
POP RBX
POP R12
POP R14
POP R15
RET
|
/* testing::internal::StreamingListener::OnTestSuiteStart(testing::TestSuite const&) */
void testing::internal::StreamingListener::OnTestSuiteStart(TestSuite *param_1)
{
long *plVar1;
long *plVar2;
long *local_60;
long local_58;
long local_50;
long lStack_48;
long *local_40 [2];
long local_30 [2];
local_40[0] = local_30;
std::__cxx11::string::_M_construct<char_const*>(local_40,"event=TestCaseStart&name=","");
/* try { // try from 0013b226 to 0013b22d has its CatchHandler @ 0013b2d7 */
plVar1 = (long *)std::__cxx11::string::append((char *)local_40);
plVar2 = plVar1 + 2;
if ((long *)*plVar1 == plVar2) {
local_50 = *plVar2;
lStack_48 = plVar1[3];
local_60 = &local_50;
}
else {
local_50 = *plVar2;
local_60 = (long *)*plVar1;
}
local_58 = plVar1[1];
*plVar1 = (long)plVar2;
plVar1[1] = 0;
*(int1 *)(plVar1 + 2) = 0;
/* try { // try from 0013b27c to 0013b280 has its CatchHandler @ 0013b2bb */
AbstractSocketWriter::SendLn(*(AbstractSocketWriter **)(param_1 + 8),(string *)&local_60);
if (local_60 != &local_50) {
operator_delete(local_60,local_50 + 1);
}
if (local_40[0] != local_30) {
operator_delete(local_40[0],local_30[0] + 1);
}
return;
}
|
|
7,806 |
google::protobuf::Message::DebugString[abi:cxx11]() const
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/text_format.cc
|
std::string Message::DebugString() const {
std::string debug_string;
TextFormat::Printer printer;
printer.SetExpandAny(true);
printer.SetInsertSilentMarker(internal::enable_debug_text_format_marker.load(
std::memory_order_relaxed));
printer.PrintToString(*this, &debug_string);
return debug_string;
}
|
O0
|
cpp
|
google::protobuf::Message::DebugString[abi:cxx11]() const:
subq $0xc8, %rsp
movq %rdi, (%rsp)
movq %rdi, %rax
movq %rax, 0x8(%rsp)
movq %rdi, 0xc0(%rsp)
movq %rsi, 0xb8(%rsp)
movq 0xb8(%rsp), %rax
movq %rax, 0x10(%rsp)
movb $0x0, 0xb7(%rsp)
callq 0x192180
leaq 0x28(%rsp), %rdi
callq 0x56a280
jmp 0x567789
leaq 0x28(%rsp), %rdi
movl $0x1, %esi
callq 0x4e2dc0
jmp 0x56779a
leaq 0x20d862(%rip), %rdi # 0x775003
xorl %esi, %esi
callq 0x18fb10
movzbl %al, %esi
leaq 0x28(%rsp), %rdi
callq 0x5705e0
jmp 0x5677b7
movq (%rsp), %rdx
movq 0x10(%rsp), %rsi
leaq 0x28(%rsp), %rdi
callq 0x567840
jmp 0x5677cc
movb $0x1, 0xb7(%rsp)
leaq 0x28(%rsp), %rdi
callq 0x4e2e00
testb $0x1, 0xb7(%rsp)
jne 0x56781d
jmp 0x567814
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x20(%rsp)
movl %eax, 0x1c(%rsp)
jmp 0x56782a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x20(%rsp)
movl %eax, 0x1c(%rsp)
leaq 0x28(%rsp), %rdi
callq 0x4e2e00
jmp 0x56782a
movq (%rsp), %rdi
callq 0x19b990
movq 0x8(%rsp), %rax
addq $0xc8, %rsp
retq
movq (%rsp), %rdi
callq 0x19b990
movq 0x20(%rsp), %rdi
callq 0x198ce0
nopl (%rax)
|
_ZNK6google8protobuf7Message11DebugStringB5cxx11Ev:
sub rsp, 0C8h
mov [rsp+0C8h+var_C8], rdi
mov rax, rdi
mov [rsp+0C8h+var_C0], rax
mov [rsp+0C8h+var_8], rdi
mov [rsp+0C8h+var_10], rsi
mov rax, [rsp+0C8h+var_10]
mov [rsp+0C8h+var_B8], rax
mov [rsp+0C8h+var_11], 0
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev; std::string::basic_string(void)
lea rdi, [rsp+0C8h+var_A0]; this
call _ZN6google8protobuf10TextFormat7PrinterC2Ev; google::protobuf::TextFormat::Printer::Printer(void)
jmp short $+2
loc_567789:
lea rdi, [rsp+0C8h+var_A0]; this
mov esi, 1; bool
call _ZN6google8protobuf10TextFormat7Printer12SetExpandAnyEb; google::protobuf::TextFormat::Printer::SetExpandAny(bool)
jmp short $+2
loc_56779A:
lea rdi, _ZN6google8protobuf8internal31enable_debug_text_format_markerE; google::protobuf::internal::enable_debug_text_format_marker
xor esi, esi
call __ZNKSt6atomicIbE4loadESt12memory_order; std::atomic<bool>::load(std::memory_order)
movzx esi, al; bool
lea rdi, [rsp+0C8h+var_A0]; this
call _ZN6google8protobuf10TextFormat7Printer21SetInsertSilentMarkerEb; google::protobuf::TextFormat::Printer::SetInsertSilentMarker(bool)
jmp short $+2
loc_5677B7:
mov rdx, [rsp+0C8h+var_C8]
mov rsi, [rsp+0C8h+var_B8]
lea rdi, [rsp+0C8h+var_A0]
call _ZNK6google8protobuf10TextFormat7Printer13PrintToStringERKNS0_7MessageEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::TextFormat::Printer::PrintToString(google::protobuf::Message const&,std::string *)
jmp short $+2
loc_5677CC:
mov [rsp+0C8h+var_11], 1
lea rdi, [rsp+0C8h+var_A0]; this
call _ZN6google8protobuf10TextFormat7PrinterD2Ev; google::protobuf::TextFormat::Printer::~Printer()
test [rsp+0C8h+var_11], 1
jnz short loc_56781D
jmp short loc_567814
mov rcx, rax
mov eax, edx
mov [rsp+arg_18], rcx
mov [rsp+arg_14], eax
jmp short loc_56782A
mov rcx, rax
mov eax, edx
mov [rsp+arg_18], rcx
mov [rsp+arg_14], eax
lea rdi, [rsp+arg_20]; this
call _ZN6google8protobuf10TextFormat7PrinterD2Ev; google::protobuf::TextFormat::Printer::~Printer()
jmp short loc_56782A
loc_567814:
mov rdi, [rsp+0C8h+var_C8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_56781D:
mov rax, [rsp+0C8h+var_C0]
add rsp, 0C8h
retn
loc_56782A:
mov rdi, [rsp+0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rdi, [rsp+arg_18]
call __Unwind_Resume
|
long long google::protobuf::Message::DebugString[abi:cxx11](long long a1, long long a2)
{
char v2; // al
int v3; // ecx
int v4; // r8d
int v5; // r9d
long long v7; // [rsp+0h] [rbp-C8h]
long long v8; // [rsp+8h] [rbp-C0h]
_BYTE v9[143]; // [rsp+28h] [rbp-A0h] BYREF
char v10; // [rsp+B7h] [rbp-11h]
long long v11; // [rsp+B8h] [rbp-10h]
long long v12; // [rsp+C0h] [rbp-8h]
v12 = a1;
v11 = a2;
v10 = 0;
std::string::basic_string(a1);
google::protobuf::TextFormat::Printer::Printer((google::protobuf::TextFormat::Printer *)v9);
google::protobuf::TextFormat::Printer::SetExpandAny((google::protobuf::TextFormat::Printer *)v9, 1);
v2 = std::atomic<bool>::load(&google::protobuf::internal::enable_debug_text_format_marker, 0LL);
google::protobuf::TextFormat::Printer::SetInsertSilentMarker((google::protobuf::TextFormat::Printer *)v9, v2);
google::protobuf::TextFormat::Printer::PrintToString((unsigned int)v9, a2, a1, v3, v4, v5, a1, a1, a2);
v10 = 1;
google::protobuf::TextFormat::Printer::~Printer((google::protobuf::TextFormat::Printer *)v9);
if ( (v10 & 1) == 0 )
std::string::~string(v7);
return v8;
}
|
SharedCtor:
SUB RSP,0x28
MOV AL,DL
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x18],RSI
AND AL,0x1
MOV byte ptr [RSP + 0x17],AL
MOV RAX,qword ptr [RSP + 0x20]
MOV RDI,RAX
ADD RDI,0x10
MOV qword ptr [RAX + 0x10],0x0
ADD RDI,0x8
MOV qword ptr [RSP + 0x8],RDI
XOR ESI,ESI
MOV EDX,0x4
CALL 0x002914a0
MOV RDI,qword ptr [RSP + 0x8]
CALL 0x004b6830
ADD RSP,0x28
RET
|
/* google::protobuf::Int64Value::SharedCtor(google::protobuf::Arena*, bool) */
void google::protobuf::Int64Value::SharedCtor(Arena *param_1,bool param_2)
{
*(int8 *)(param_1 + 0x10) = 0;
memset((CachedSize *)(param_1 + 0x18),0,4);
internal::CachedSize::CachedSize((CachedSize *)(param_1 + 0x18));
return;
}
|
|
7,807 |
used_buffs_add
|
eloqsql/storage/maria/ma_loghandler.c
|
static void
used_buffs_add(TRUNSLOG_USED_BUFFERS *buffs,
struct st_translog_buffer *buff)
{
DBUG_ENTER("used_buffs_add");
DBUG_PRINT("enter", ("ADD buffs: %p unlk %u (%p) wrt_ptr: %u (%p)"
" buff %p (%u)",
buffs,
buffs->wrt_ptr, buffs->buff[buffs->wrt_ptr],
buffs->unlck_ptr, buffs->buff[buffs->unlck_ptr],
buff, buff->buffer_no));
DBUG_ASSERT(buffs->wrt_ptr < MAX_TRUNSLOG_USED_BUFFERS);
buffs->buff[buffs->wrt_ptr++]= buff;
DBUG_VOID_RETURN;
}
|
O0
|
c
|
used_buffs_add:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
jmp 0x3829e
jmp 0x382a0
jmp 0x382a2
movq -0x10(%rbp), %rdx
movq -0x8(%rbp), %rax
movq -0x8(%rbp), %rsi
movb 0x18(%rsi), %cl
movb %cl, %dil
addb $0x1, %dil
movb %dil, 0x18(%rsi)
movzbl %cl, %ecx
movq %rdx, (%rax,%rcx,8)
jmp 0x382c5
popq %rbp
retq
nopw (%rax,%rax)
|
used_buffs_add:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
jmp short $+2
loc_3829E:
jmp short $+2
loc_382A0:
jmp short $+2
loc_382A2:
mov rdx, [rbp+var_10]
mov rax, [rbp+var_8]
mov rsi, [rbp+var_8]
mov cl, [rsi+18h]
mov dil, cl
add dil, 1
mov [rsi+18h], dil
movzx ecx, cl
mov [rax+rcx*8], rdx
jmp short $+2
loc_382C5:
pop rbp
retn
|
long long used_buffs_add(long long a1, long long a2)
{
long long result; // rax
unsigned __int8 v3; // cl
result = a1;
v3 = *(_BYTE *)(a1 + 24);
*(_BYTE *)(a1 + 24) = v3 + 1;
*(_QWORD *)(a1 + 8LL * v3) = a2;
return result;
}
|
used_buffs_add:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
JMP 0x0013829e
LAB_0013829e:
JMP 0x001382a0
LAB_001382a0:
JMP 0x001382a2
LAB_001382a2:
MOV RDX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x8]
MOV CL,byte ptr [RSI + 0x18]
MOV DIL,CL
ADD DIL,0x1
MOV byte ptr [RSI + 0x18],DIL
MOVZX ECX,CL
MOV qword ptr [RAX + RCX*0x8],RDX
JMP 0x001382c5
LAB_001382c5:
POP RBP
RET
|
void used_buffs_add(long param_1,int8 param_2)
{
byte bVar1;
bVar1 = *(byte *)(param_1 + 0x18);
*(byte *)(param_1 + 0x18) = bVar1 + 1;
*(int8 *)(param_1 + (ulong)bVar1 * 8) = param_2;
return;
}
|
|
7,808 |
testing::internal::GetArgvs[abi:cxx11]()
|
AlayaLite/build_O0/_deps/googletest-src/googletest/src/gtest.cc
|
::std::vector<std::string> GetArgvs() {
#if defined(GTEST_CUSTOM_GET_ARGVS_)
// GTEST_CUSTOM_GET_ARGVS_() may return a container of std::string or
// ::string. This code converts it to the appropriate type.
const auto& custom = GTEST_CUSTOM_GET_ARGVS_();
return ::std::vector<std::string>(custom.begin(), custom.end());
#else // defined(GTEST_CUSTOM_GET_ARGVS_)
return g_argvs;
#endif // defined(GTEST_CUSTOM_GET_ARGVS_)
}
|
O0
|
cpp
|
testing::internal::GetArgvs[abi:cxx11]():
subq $0x18, %rsp
movq %rdi, %rax
movq %rax, 0x8(%rsp)
movq %rdi, 0x10(%rsp)
leaq 0xc3f90(%rip), %rsi # 0x185d28
callq 0xec580
movq 0x8(%rsp), %rax
addq $0x18, %rsp
retq
nopw (%rax,%rax)
|
_ZN7testing8internal8GetArgvsB5cxx11Ev:
sub rsp, 18h
mov rax, rdi
mov [rsp+18h+var_10], rax
mov [rsp+18h+var_8], rdi
lea rsi, _ZN7testing8internalL7g_argvsB5cxx11E; testing::internal::g_argvs
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EEC2ERKS7_; std::vector<std::string>::vector(std::vector<std::string> const&)
mov rax, [rsp+18h+var_10]
add rsp, 18h
retn
|
GetArgvs[abi:cxx11]:
SUB RSP,0x18
MOV RAX,RDI
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x10],RDI
LEA RSI,[0x285d28]
CALL 0x001ec580
MOV RAX,qword ptr [RSP + 0x8]
ADD RSP,0x18
RET
|
/* testing::internal::GetArgvs[abi:cxx11]() */
internal * __thiscall testing::internal::GetArgvs_abi_cxx11_(internal *this)
{
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::vector
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)this,
(vector *)g_argvs_abi_cxx11_);
return this;
}
|
||
7,809 |
Binary_string::append(char const*, unsigned long)
|
eloqsql/sql/sql_string.h
|
bool append(const char *s, size_t size)
{
if (!size)
return false;
if (realloc_with_extra_if_needed(str_length + size))
return true;
q_append(s, size);
return false;
}
|
O3
|
c
|
Binary_string::append(char const*, unsigned long):
testq %rdx, %rdx
je 0x27d71
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movl 0x8(%rdi), %esi
movl 0xc(%rdi), %eax
addq %rdx, %rsi
cmpq %rax, %rsi
jae 0x27d74
movq (%r14), %rax
movb $0x0, (%rax,%rsi)
jmp 0x27d84
xorl %eax, %eax
retq
movq %r14, %rdi
callq 0x27da8
movl %eax, %ecx
movb $0x1, %al
testb %cl, %cl
jne 0x27d9c
movl 0x8(%r14), %edi
addq (%r14), %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq 0x24290
addl %ebx, 0x8(%r14)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
|
_ZN13Binary_string6appendEPKcm:
test rdx, rdx
jz short loc_27D71
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov rbx, rdx
mov r15, rsi
mov r14, rdi
mov esi, [rdi+8]
mov eax, [rdi+0Ch]
add rsi, rdx; unsigned __int64
cmp rsi, rax
jnb short loc_27D74
mov rax, [r14]
mov byte ptr [rax+rsi], 0
jmp short loc_27D84
loc_27D71:
xor eax, eax
retn
loc_27D74:
mov rdi, r14; this
call _ZN13Binary_string18realloc_with_extraEm; Binary_string::realloc_with_extra(ulong)
mov ecx, eax
mov al, 1
test cl, cl
jnz short loc_27D9C
loc_27D84:
mov edi, [r14+8]
add rdi, [r14]
mov rsi, r15
mov rdx, rbx
call _memcpy
add [r14+8], ebx
xor eax, eax
loc_27D9C:
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
|
char Binary_string::append(Binary_string *this, const char *a2, long long a3)
{
int v3; // ebx
unsigned long long v5; // rsi
char result; // al
char v7; // cl
if ( !a3 )
return 0;
v3 = a3;
v5 = a3 + *((unsigned int *)this + 2);
if ( v5 >= *((unsigned int *)this + 3) )
{
v7 = Binary_string::realloc_with_extra(this, v5);
result = 1;
if ( v7 )
return result;
}
else
{
*(_BYTE *)(*(_QWORD *)this + v5) = 0;
}
memcpy(*(_QWORD *)this + *((unsigned int *)this + 2), a2);
*((_DWORD *)this + 2) += v3;
return 0;
}
|
append:
TEST RDX,RDX
JZ 0x00127d71
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDX
MOV R15,RSI
MOV R14,RDI
MOV ESI,dword ptr [RDI + 0x8]
MOV EAX,dword ptr [RDI + 0xc]
ADD RSI,RDX
CMP RSI,RAX
JNC 0x00127d74
MOV RAX,qword ptr [R14]
MOV byte ptr [RAX + RSI*0x1],0x0
JMP 0x00127d84
LAB_00127d71:
XOR EAX,EAX
RET
LAB_00127d74:
MOV RDI,R14
CALL 0x00127da8
MOV ECX,EAX
MOV AL,0x1
TEST CL,CL
JNZ 0x00127d9c
LAB_00127d84:
MOV EDI,dword ptr [R14 + 0x8]
ADD RDI,qword ptr [R14]
MOV RSI,R15
MOV RDX,RBX
CALL 0x00124290
ADD dword ptr [R14 + 0x8],EBX
XOR EAX,EAX
LAB_00127d9c:
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
|
/* Binary_string::append(char const*, unsigned long) */
int8 __thiscall Binary_string::append(Binary_string *this,char *param_1,ulong param_2)
{
char cVar1;
ulong uVar2;
if (param_2 == 0) {
return 0;
}
uVar2 = *(uint *)(this + 8) + param_2;
if (uVar2 < *(uint *)(this + 0xc)) {
*(int1 *)(*(long *)this + uVar2) = 0;
}
else {
cVar1 = realloc_with_extra(this,uVar2);
if (cVar1 != '\0') {
return 1;
}
}
memcpy((void *)((ulong)*(uint *)(this + 8) + *(long *)this),param_1,param_2);
*(int *)(this + 8) = *(int *)(this + 8) + (int)param_2;
return 0;
}
|
|
7,810 |
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::end_object()
|
monkey531[P]llama/common/./json.hpp
|
bool end_object()
{
if (ref_stack.back())
{
if (!callback(static_cast<int>(ref_stack.size()) - 1, parse_event_t::object_end, *ref_stack.back()))
{
// discard object
*ref_stack.back() = discarded;
}
else
{
ref_stack.back()->set_parents();
}
}
JSON_ASSERT(!ref_stack.empty());
JSON_ASSERT(!keep_stack.empty());
ref_stack.pop_back();
keep_stack.pop_back();
if (!ref_stack.empty() && ref_stack.back() && ref_stack.back()->is_structured())
{
// remove discarded value
for (auto it = ref_stack.back()->begin(); it != ref_stack.back()->end(); ++it)
{
if (it->is_discarded())
{
ref_stack.back()->erase(it);
break;
}
}
}
return true;
}
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::end_object():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rdi, %rbx
movq 0x10(%rdi), %rax
movq -0x8(%rax), %rcx
testq %rcx, %rcx
je 0x34cc0
subq 0x8(%rbx), %rax
shrq $0x3, %rax
decl %eax
movl %eax, 0x28(%rsp)
movb $0x1, 0x8(%rsp)
cmpq $0x0, 0x90(%rbx)
je 0x34e6b
leaq 0x80(%rbx), %rdi
leaq 0x28(%rsp), %rsi
leaq 0x8(%rsp), %rdx
callq *0x98(%rbx)
testb %al, %al
jne 0x34cc0
leaq 0xa8(%rbx), %rsi
leaq 0x48(%rsp), %r14
movq %r14, %rdi
callq 0x35fd8
movq 0x10(%rbx), %rax
movq -0x8(%rax), %rdi
movq %r14, %rsi
callq 0x337a2
movq %r14, %rdi
xorl %esi, %esi
callq 0x31156
movq %r14, %rdi
callq 0x364a4
movq 0x8(%rbx), %rcx
movq 0x10(%rbx), %rax
cmpq %rax, %rcx
je 0x34e2e
movq 0x30(%rbx), %rdx
movl 0x38(%rbx), %esi
cmpq %rdx, 0x20(%rbx)
sete %dil
testl %esi, %esi
sete %r8b
andb %dil, %r8b
cmpb $0x1, %r8b
je 0x34e4a
leaq -0x8(%rax), %rdi
movq %rdi, 0x10(%rbx)
subl $0x1, %esi
movl %esi, 0x38(%rbx)
jae 0x34d12
movl $0x3f, 0x38(%rbx)
addq $-0x8, %rdx
movq %rdx, 0x30(%rbx)
cmpq %rdi, %rcx
je 0x34e1d
movq -0x10(%rax), %rax
testq %rax, %rax
je 0x34e1d
movb (%rax), %cl
decb %cl
cmpb $0x1, %cl
ja 0x34e1d
movabsq $-0x8000000000000000, %r12 # imm = 0x8000000000000000
leaq 0x28(%rsp), %r14
movq %rax, (%r14)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%r14)
movq %r12, 0x18(%r14)
movq %r14, %rdi
callq 0x36ec4
movq 0x10(%rbx), %rax
movq -0x8(%rax), %rax
leaq 0x8(%rsp), %r15
movq %rax, (%r15)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%r15)
movq %r12, 0x18(%r15)
movq %r15, %rdi
callq 0x37238
movq %r14, %rdi
movq %r15, %rsi
callq 0x36f36
testb %al, %al
jne 0x34e1d
leaq 0x30(%rsp), %r13
leaq 0x10(%rsp), %rbp
leaq 0x28(%rsp), %r14
leaq 0x8(%rsp), %r15
movq %r14, %rdi
callq 0x3607c
cmpb $0x9, (%rax)
je 0x34ded
movq %r14, %rdi
callq 0x36456
movq 0x10(%rbx), %rax
movq -0x8(%rax), %rax
movq %rax, 0x8(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, (%rbp)
movq %r12, 0x20(%rsp)
movq %r15, %rdi
callq 0x37238
movq %r14, %rdi
movq %r15, %rsi
callq 0x36f36
testb %al, %al
je 0x34da6
jmp 0x34e1d
movq 0x10(%rbx), %rax
movq -0x8(%rax), %rsi
movq 0x28(%rsp), %rax
leaq 0x58(%rsp), %rdx
movq %rax, (%rdx)
movups (%r13), %xmm0
movups %xmm0, 0x8(%rdx)
movq 0x10(%r13), %rax
movq %rax, 0x18(%rdx)
leaq 0x8(%rsp), %rdi
callq 0x361c8
movb $0x1, %al
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x80301(%rip), %rdi # 0xb5136
leaq 0x80346(%rip), %rdx # 0xb5182
leaq 0x812f7(%rip), %rcx # 0xb613a
movl $0x1bbd, %esi # imm = 0x1BBD
jmp 0x34e64
leaq 0x802e5(%rip), %rdi # 0xb5136
leaq 0x8032a(%rip), %rdx # 0xb5182
leaq 0x81255(%rip), %rcx # 0xb60b4
movl $0x1bbe, %esi # imm = 0x1BBE
xorl %eax, %eax
callq 0x19b30
callq 0x19270
|
_ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE10end_objectEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 78h
mov rbx, rdi
mov rax, [rdi+10h]
mov rcx, [rax-8]
test rcx, rcx
jz short loc_34CC0
sub rax, [rbx+8]
shr rax, 3
dec eax
mov dword ptr [rsp+0A8h+var_80], eax
mov byte ptr [rsp+0A8h+var_A0], 1
cmp qword ptr [rbx+90h], 0
jz loc_34E6B
lea rdi, [rbx+80h]
lea rsi, [rsp+0A8h+var_80]
lea rdx, [rsp+0A8h+var_A0]
call qword ptr [rbx+98h]
test al, al
jnz short loc_34CC0
lea rsi, [rbx+0A8h]
lea r14, [rsp+0A8h+var_60]
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ERKSD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::basic_json(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
mov rax, [rbx+10h]
mov rdi, [rax-8]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::operator=(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>)
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
loc_34CC0:
mov rcx, [rbx+8]
mov rax, [rbx+10h]
cmp rcx, rax
jz loc_34E2E
mov rdx, [rbx+30h]
mov esi, [rbx+38h]
cmp [rbx+20h], rdx
setz dil
test esi, esi
setz r8b
and r8b, dil
cmp r8b, 1
jz loc_34E4A
lea rdi, [rax-8]
mov [rbx+10h], rdi
sub esi, 1
mov [rbx+38h], esi
jnb short loc_34D12
mov dword ptr [rbx+38h], 3Fh ; '?'
add rdx, 0FFFFFFFFFFFFFFF8h
mov [rbx+30h], rdx
loc_34D12:
cmp rcx, rdi
jz loc_34E1D
mov rax, [rax-10h]
test rax, rax
jz loc_34E1D
mov cl, [rax]
dec cl
cmp cl, 1
ja loc_34E1D
mov r12, 8000000000000000h
lea r14, [rsp+0A8h+var_80]
mov [r14], rax
xorps xmm0, xmm0
movups xmmword ptr [r14+8], xmm0
mov [r14+18h], r12
mov rdi, r14
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+10h]
mov rax, [rax-8]
lea r15, [rsp+0A8h+var_A0]
mov [r15], rax
xorps xmm0, xmm0
movups xmmword ptr [r15+8], xmm0
mov [r15+18h], r12
mov rdi, r15
call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; 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_end(void)
mov rdi, r14
mov rsi, r15
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_
test al, al
jnz loc_34E1D
lea r13, [rsp+0A8h+var_78]
lea rbp, [rsp+0A8h+var_98]
lea r14, [rsp+0A8h+var_80]
lea r15, [rsp+0A8h+var_A0]
loc_34DA6:
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEptEv; 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>>::operator->(void)
cmp byte ptr [rax], 9
jz short loc_34DED
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEppEv; 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>>::operator++(void)
mov rax, [rbx+10h]
mov rax, [rax-8]
mov [rsp+0A8h+var_A0], rax
xorps xmm0, xmm0
movups xmmword ptr [rbp+0], xmm0
mov [rsp+0A8h+var_88], r12
mov rdi, r15
call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; 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_end(void)
mov rdi, r14
mov rsi, r15
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_
test al, al
jz short loc_34DA6
jmp short loc_34E1D
loc_34DED:
mov rax, [rbx+10h]
mov rsi, [rax-8]
mov rax, [rsp+0A8h+var_80]
lea rdx, [rsp+0A8h+var_50]
mov [rdx], rax
movups xmm0, xmmword ptr [r13+0]
movups xmmword ptr [rdx+8], xmm0
mov rax, [r13+10h]
mov [rdx+18h], rax
lea rdi, [rsp+0A8h+var_A0]
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_
loc_34E1D:
mov al, 1
add rsp, 78h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_34E2E:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aRefStackEmpty; "!ref_stack.empty()"
mov esi, 1BBDh
jmp short loc_34E64
loc_34E4A:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aKeepStackEmpty; "!keep_stack.empty()"
mov esi, 1BBEh
loc_34E64:
xor eax, eax
call _ggml_abort
loc_34E6B:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
|
char nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::end_object(
long long a1)
{
long long v1; // rax
long long v2; // rcx
long long v3; // rax
long long v4; // rdx
int v5; // esi
_BYTE *v6; // rax
long long v7; // rsi
long long v9; // [rsp+8h] [rbp-A0h] BYREF
__int128 v10; // [rsp+10h] [rbp-98h]
unsigned long long v11; // [rsp+20h] [rbp-88h]
_BYTE *v12; // [rsp+28h] [rbp-80h] BYREF
__int128 v13; // [rsp+30h] [rbp-78h]
unsigned long long v14; // [rsp+40h] [rbp-68h]
char v15[16]; // [rsp+48h] [rbp-60h] BYREF
_BYTE *v16; // [rsp+58h] [rbp-50h]
__int128 v17; // [rsp+60h] [rbp-48h]
unsigned long long v18; // [rsp+70h] [rbp-38h]
v1 = *(_QWORD *)(a1 + 16);
if ( *(_QWORD *)(v1 - 8) )
{
LODWORD(v12) = ((unsigned long long)(v1 - *(_QWORD *)(a1 + 8)) >> 3) - 1;
LOBYTE(v9) = 1;
if ( !*(_QWORD *)(a1 + 144) )
goto LABEL_20;
if ( !(*(unsigned __int8 ( **)(long long, _BYTE **, long long *))(a1 + 152))(a1 + 128, &v12, &v9) )
{
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json(
v15,
a1 + 168);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator=(
*(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL),
(long long)v15);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant(v15);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v15);
}
}
v2 = *(_QWORD *)(a1 + 8);
v3 = *(_QWORD *)(a1 + 16);
if ( v2 == v3 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
7101LL,
"GGML_ASSERT(%s) failed",
"!ref_stack.empty()");
goto LABEL_20;
}
v4 = *(_QWORD *)(a1 + 48);
v5 = *(_DWORD *)(a1 + 56);
if ( *(_QWORD *)(a1 + 32) == v4 && v5 == 0 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
7102LL,
"GGML_ASSERT(%s) failed",
"!keep_stack.empty()");
LABEL_20:
std::__throw_bad_function_call();
}
*(_QWORD *)(a1 + 16) = v3 - 8;
*(_DWORD *)(a1 + 56) = v5 - 1;
if ( !v5 )
{
*(_DWORD *)(a1 + 56) = 63;
*(_QWORD *)(a1 + 48) = v4 - 8;
}
if ( v2 != v3 - 8 )
{
v6 = *(_BYTE **)(v3 - 16);
if ( v6 )
{
if ( (unsigned __int8)(*v6 - 1) <= 1u )
{
v12 = v6;
v13 = 0LL;
v14 = 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(&v12);
v9 = *(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL);
v10 = 0LL;
v11 = 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_end(&v9);
if ( !(unsigned __int8)ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_(
&v12,
&v9) )
{
while ( *(_BYTE *)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>>::operator->(&v12) != 9 )
{
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>>::operator++(&v12);
v9 = *(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL);
v10 = 0LL;
v11 = 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_end(&v9);
if ( (unsigned __int8)ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_(
&v12,
&v9) )
return 1;
}
v7 = *(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL);
v16 = v12;
v17 = v13;
v18 = v14;
ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_(
&v9,
v7);
}
}
}
}
return 1;
}
|
end_object:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x78
MOV RBX,RDI
MOV RAX,qword ptr [RDI + 0x10]
MOV RCX,qword ptr [RAX + -0x8]
TEST RCX,RCX
JZ 0x00134cc0
SUB RAX,qword ptr [RBX + 0x8]
SHR RAX,0x3
DEC EAX
MOV dword ptr [RSP + 0x28],EAX
MOV byte ptr [RSP + 0x8],0x1
CMP qword ptr [RBX + 0x90],0x0
JZ 0x00134e6b
LEA RDI,[RBX + 0x80]
LEA RSI,[RSP + 0x28]
LEA RDX,[RSP + 0x8]
CALL qword ptr [RBX + 0x98]
TEST AL,AL
JNZ 0x00134cc0
LEA RSI,[RBX + 0xa8]
LEA R14,[RSP + 0x48]
MOV RDI,R14
CALL 0x00135fd8
MOV RAX,qword ptr [RBX + 0x10]
MOV RDI,qword ptr [RAX + -0x8]
MOV RSI,R14
CALL 0x001337a2
MOV RDI,R14
XOR ESI,ESI
CALL 0x00131156
MOV RDI,R14
CALL 0x001364a4
LAB_00134cc0:
MOV RCX,qword ptr [RBX + 0x8]
MOV RAX,qword ptr [RBX + 0x10]
CMP RCX,RAX
JZ 0x00134e2e
MOV RDX,qword ptr [RBX + 0x30]
MOV ESI,dword ptr [RBX + 0x38]
CMP qword ptr [RBX + 0x20],RDX
SETZ DIL
TEST ESI,ESI
SETZ R8B
AND R8B,DIL
CMP R8B,0x1
JZ 0x00134e4a
LEA RDI,[RAX + -0x8]
MOV qword ptr [RBX + 0x10],RDI
SUB ESI,0x1
MOV dword ptr [RBX + 0x38],ESI
JNC 0x00134d12
MOV dword ptr [RBX + 0x38],0x3f
ADD RDX,-0x8
MOV qword ptr [RBX + 0x30],RDX
LAB_00134d12:
CMP RCX,RDI
JZ 0x00134e1d
MOV RAX,qword ptr [RAX + -0x10]
TEST RAX,RAX
JZ 0x00134e1d
MOV CL,byte ptr [RAX]
DEC CL
CMP CL,0x1
JA 0x00134e1d
MOV R12,-0x8000000000000000
LEA R14,[RSP + 0x28]
MOV qword ptr [R14],RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R14 + 0x8],XMM0
MOV qword ptr [R14 + 0x18],R12
MOV RDI,R14
CALL 0x00136ec4
MOV RAX,qword ptr [RBX + 0x10]
MOV RAX,qword ptr [RAX + -0x8]
LEA R15,[RSP + 0x8]
MOV qword ptr [R15],RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R15 + 0x8],XMM0
MOV qword ptr [R15 + 0x18],R12
MOV RDI,R15
CALL 0x00137238
MOV RDI,R14
MOV RSI,R15
CALL 0x00136f36
TEST AL,AL
JNZ 0x00134e1d
LEA R13,[RSP + 0x30]
LEA RBP,[RSP + 0x10]
LEA R14,[RSP + 0x28]
LEA R15,[RSP + 0x8]
LAB_00134da6:
MOV RDI,R14
CALL 0x0013607c
CMP byte ptr [RAX],0x9
JZ 0x00134ded
MOV RDI,R14
CALL 0x00136456
MOV RAX,qword ptr [RBX + 0x10]
MOV RAX,qword ptr [RAX + -0x8]
MOV qword ptr [RSP + 0x8],RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBP],XMM0
MOV qword ptr [RSP + 0x20],R12
MOV RDI,R15
CALL 0x00137238
MOV RDI,R14
MOV RSI,R15
CALL 0x00136f36
TEST AL,AL
JZ 0x00134da6
JMP 0x00134e1d
LAB_00134ded:
MOV RAX,qword ptr [RBX + 0x10]
MOV RSI,qword ptr [RAX + -0x8]
MOV RAX,qword ptr [RSP + 0x28]
LEA RDX,[RSP + 0x58]
MOV qword ptr [RDX],RAX
MOVUPS XMM0,xmmword ptr [R13]
MOVUPS xmmword ptr [RDX + 0x8],XMM0
MOV RAX,qword ptr [R13 + 0x10]
MOV qword ptr [RDX + 0x18],RAX
LEA RDI,[RSP + 0x8]
CALL 0x001361c8
LAB_00134e1d:
MOV AL,0x1
ADD RSP,0x78
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00134e2e:
LEA RDI,[0x1b5136]
LEA RDX,[0x1b5182]
LEA RCX,[0x1b613a]
MOV ESI,0x1bbd
JMP 0x00134e64
LAB_00134e4a:
LEA RDI,[0x1b5136]
LEA RDX,[0x1b5182]
LEA RCX,[0x1b60b4]
MOV ESI,0x1bbe
LAB_00134e64:
XOR EAX,EAX
CALL 0x00119b30
LAB_00134e6b:
CALL 0x00119270
|
/* nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >::end_object() */
int8 __thiscall
nlohmann::json_abi_v3_11_3::detail::
json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::end_object(json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*this)
{
int iVar1;
long lVar2;
char cVar3;
char *pcVar4;
int8 uVar5;
int8 local_a0;
int8 local_98;
int8 uStack_90;
int8 local_88;
char *local_80;
int8 local_78;
int8 uStack_70;
int8 local_68;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
local_60 [16];
char *local_50;
int4 local_48;
int4 uStack_44;
int4 uStack_40;
int4 uStack_3c;
int8 local_38;
if (*(long *)(*(long *)(this + 0x10) + -8) != 0) {
local_80 = (char *)CONCAT44(local_80._4_4_,
(int)((ulong)(*(long *)(this + 0x10) - *(long *)(this + 8)) >> 3) +
-1);
local_a0 = CONCAT71(local_a0._1_7_,1);
if (*(long *)(this + 0x90) == 0) {
/* WARNING: Subroutine does not return */
std::__throw_bad_function_call();
}
cVar3 = (**(code **)(this + 0x98))(this + 0x80,&local_80,&local_a0);
if (cVar3 == '\0') {
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::basic_json(local_60,(basic_json *)(this + 0xa8));
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::operator=(*(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
**)(*(long *)(this + 0x10) + -8),local_60);
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(local_60,0));
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data((data *)local_60);
}
}
lVar2 = *(long *)(this + 0x10);
if (*(long *)(this + 8) == lVar2) {
pcVar4 = "!ref_stack.empty()";
uVar5 = 0x1bbd;
}
else {
iVar1 = *(int *)(this + 0x38);
if (iVar1 != 0 || *(long *)(this + 0x20) != *(long *)(this + 0x30)) {
*(long *)(this + 0x10) = lVar2 + -8;
*(int *)(this + 0x38) = iVar1 + -1;
if (iVar1 == 0) {
*(int4 *)(this + 0x38) = 0x3f;
*(long *)(this + 0x30) = *(long *)(this + 0x30) + -8;
}
if (((*(long *)(this + 8) != lVar2 + -8) &&
(local_80 = *(char **)(lVar2 + -0x10), local_80 != (char *)0x0)) &&
((byte)(*local_80 - 1U) < 2)) {
local_78 = 0;
uStack_70 = 0;
local_68 = 0x8000000000000000;
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::set_begin((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*)&local_80);
local_a0 = *(int8 *)(*(long *)(this + 0x10) + -8);
local_98 = 0;
uStack_90 = 0;
local_88 = 0x8000000000000000;
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::set_end((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>>
*)&local_a0);
cVar3 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_
((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>>
*)&local_80,
(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>>
*)&local_a0);
if (cVar3 == '\0') {
do {
pcVar4 = (char *)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>>
::operator->((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*)&local_80);
if (*pcVar4 == '\t') {
local_50 = local_80;
local_48 = (int4)local_78;
uStack_44 = local_78._4_4_;
uStack_40 = (int4)uStack_70;
uStack_3c = uStack_70._4_4_;
local_38 = local_68;
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_
(&local_a0,*(int8 *)(*(long *)(this + 0x10) + -8));
return 1;
}
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>>
::operator++((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*)&local_80);
local_a0 = *(int8 *)(*(long *)(this + 0x10) + -8);
local_98 = 0;
uStack_90 = 0;
local_88 = 0x8000000000000000;
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::set_end((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>>
*)&local_a0);
cVar3 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_
((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>>
*)&local_80,
(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>>
*)&local_a0);
} while (cVar3 == '\0');
}
}
return 1;
}
pcVar4 = "!keep_stack.empty()";
uVar5 = 0x1bbe;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",uVar5,
"GGML_ASSERT(%s) failed",pcVar4);
}
|
|
7,811 |
func_gb2312_uni_onechar
|
eloqsql/strings/ctype-gb2312.c
|
static int func_gb2312_uni_onechar(int code){
if ((code>=0x2121)&&(code<=0x2658))
return(tab_gb2312_uni0[code-0x2121]);
if ((code>=0x2721)&&(code<=0x296F))
return(tab_gb2312_uni1[code-0x2721]);
if ((code>=0x3021)&&(code<=0x777E))
return(tab_gb2312_uni2[code-0x3021]);
return(0);
}
|
O0
|
c
|
func_gb2312_uni_onechar:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x8(%rbp)
cmpl $0x2121, -0x8(%rbp) # imm = 0x2121
jl 0x4ac44
cmpl $0x2658, -0x8(%rbp) # imm = 0x2658
jg 0x4ac44
movl -0x8(%rbp), %eax
subl $0x2121, %eax # imm = 0x2121
movslq %eax, %rcx
leaq 0xc59f5(%rip), %rax # 0x110630
movzwl (%rax,%rcx,2), %eax
movl %eax, -0x4(%rbp)
jmp 0x4aca5
cmpl $0x2721, -0x8(%rbp) # imm = 0x2721
jl 0x4ac71
cmpl $0x296f, -0x8(%rbp) # imm = 0x296F
jg 0x4ac71
movl -0x8(%rbp), %eax
subl $0x2721, %eax # imm = 0x2721
movslq %eax, %rcx
leaq 0xc6438(%rip), %rax # 0x1110a0
movzwl (%rax,%rcx,2), %eax
movl %eax, -0x4(%rbp)
jmp 0x4aca5
cmpl $0x3021, -0x8(%rbp) # imm = 0x3021
jl 0x4ac9e
cmpl $0x777e, -0x8(%rbp) # imm = 0x777E
jg 0x4ac9e
movl -0x8(%rbp), %eax
subl $0x3021, %eax # imm = 0x3021
movslq %eax, %rcx
leaq 0xc68ab(%rip), %rax # 0x111540
movzwl (%rax,%rcx,2), %eax
movl %eax, -0x4(%rbp)
jmp 0x4aca5
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopw (%rax,%rax)
|
func_gb2312_uni_onechar:
push rbp
mov rbp, rsp
mov [rbp+var_8], edi
cmp [rbp+var_8], 2121h
jl short loc_4AC44
cmp [rbp+var_8], 2658h
jg short loc_4AC44
mov eax, [rbp+var_8]
sub eax, 2121h
movsxd rcx, eax
lea rax, tab_gb2312_uni0
movzx eax, word ptr [rax+rcx*2]
mov [rbp+var_4], eax
jmp short loc_4ACA5
loc_4AC44:
cmp [rbp+var_8], 2721h
jl short loc_4AC71
cmp [rbp+var_8], 296Fh
jg short loc_4AC71
mov eax, [rbp+var_8]
sub eax, 2721h
movsxd rcx, eax
lea rax, tab_gb2312_uni1
movzx eax, word ptr [rax+rcx*2]
mov [rbp+var_4], eax
jmp short loc_4ACA5
loc_4AC71:
cmp [rbp+var_8], 3021h
jl short loc_4AC9E
cmp [rbp+var_8], 777Eh
jg short loc_4AC9E
mov eax, [rbp+var_8]
sub eax, 3021h
movsxd rcx, eax
lea rax, tab_gb2312_uni2
movzx eax, word ptr [rax+rcx*2]
mov [rbp+var_4], eax
jmp short loc_4ACA5
loc_4AC9E:
mov [rbp+var_4], 0
loc_4ACA5:
mov eax, [rbp+var_4]
pop rbp
retn
|
long long func_gb2312_uni_onechar(int a1)
{
if ( a1 < 8481 || a1 > 9816 )
{
if ( a1 < 10017 || a1 > 10607 )
{
if ( a1 < 12321 || a1 > 30590 )
return 0;
else
return tab_gb2312_uni2[a1 - 12321];
}
else
{
return tab_gb2312_uni1[a1 - 10017];
}
}
else
{
return tab_gb2312_uni0[a1 - 8481];
}
}
|
func_gb2312_uni_onechar:
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x8],EDI
CMP dword ptr [RBP + -0x8],0x2121
JL 0x0014ac44
CMP dword ptr [RBP + -0x8],0x2658
JG 0x0014ac44
MOV EAX,dword ptr [RBP + -0x8]
SUB EAX,0x2121
MOVSXD RCX,EAX
LEA RAX,[0x210630]
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014aca5
LAB_0014ac44:
CMP dword ptr [RBP + -0x8],0x2721
JL 0x0014ac71
CMP dword ptr [RBP + -0x8],0x296f
JG 0x0014ac71
MOV EAX,dword ptr [RBP + -0x8]
SUB EAX,0x2721
MOVSXD RCX,EAX
LEA RAX,[0x2110a0]
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014aca5
LAB_0014ac71:
CMP dword ptr [RBP + -0x8],0x3021
JL 0x0014ac9e
CMP dword ptr [RBP + -0x8],0x777e
JG 0x0014ac9e
MOV EAX,dword ptr [RBP + -0x8]
SUB EAX,0x3021
MOVSXD RCX,EAX
LEA RAX,[0x211540]
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014aca5
LAB_0014ac9e:
MOV dword ptr [RBP + -0x4],0x0
LAB_0014aca5:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int2 func_gb2312_uni_onechar(int param_1)
{
int2 uVar1;
if ((param_1 < 0x2121) || (0x2658 < param_1)) {
if ((param_1 < 0x2721) || (0x296f < param_1)) {
if ((param_1 < 0x3021) || (0x777e < param_1)) {
uVar1 = 0;
}
else {
uVar1 = *(int2 *)(tab_gb2312_uni2 + (long)(param_1 + -0x3021) * 2);
}
}
else {
uVar1 = *(int2 *)(tab_gb2312_uni1 + (long)(param_1 + -0x2721) * 2);
}
}
else {
uVar1 = *(int2 *)(tab_gb2312_uni0 + (long)(param_1 + -0x2121) * 2);
}
return uVar1;
}
|
|
7,812 |
core_tensor_logic_init_2d_Test::~core_tensor_logic_init_2d_Test()
|
magnetron/test/unittests/tensor/core_logic.cpp
|
TEST(core_tensor_logic, init_2d) {
context ctx {compute_device::cpu};
tensor t {ctx, dtype::e8m23, 10, 10};
ASSERT_EQ(t.dtype(), dtype::e8m23);
ASSERT_EQ(t.rank(), 2);
ASSERT_EQ(t.shape()[0], 10);
ASSERT_EQ(t.shape()[1], 10);
ASSERT_EQ(t.shape()[2], 1);
ASSERT_EQ(t.shape()[3], 1);
ASSERT_EQ(t.shape()[4], 1);
ASSERT_EQ(t.shape()[5], 1);
ASSERT_EQ(t.strides()[0], 1);
ASSERT_EQ(t.strides()[1], 10);
ASSERT_EQ(t.strides()[2], 100);
ASSERT_EQ(t.strides()[3], 100);
ASSERT_EQ(t.strides()[4], 100);
ASSERT_EQ(t.strides()[5], 100);
ASSERT_NE(t.data_ptr(), nullptr);
ASSERT_EQ(t.numel(), 10*10);
ASSERT_EQ(t.data_size(), t.numel() * sizeof(e8m23_t));
ASSERT_EQ(t.data_size(), 10*10 * sizeof(e8m23_t));
ASSERT_EQ(t.refcount(), 1);
// now check some internal data
mag_tensor_t* internal {&*t};
ASSERT_NE(internal->storage->alignment, 0);
ASSERT_NE(internal->storage->base, 0);
ASSERT_NE(internal->storage->size, 0);
ASSERT_NE(internal->storage->host, nullptr);
ASSERT_NE(internal->storage->broadcast, nullptr);
ASSERT_NE(internal->storage->transfer, nullptr);
ASSERT_EQ(internal->view_offs, 0);
ASSERT_EQ(internal->view_uplink, nullptr);
ASSERT_EQ(internal->op, MAG_OP_NOP);
ASSERT_EQ(internal->init_op, MAG_IOP_NOP);
for (std::size_t i {}; i < k_max_input_tensors; ++i) {
ASSERT_EQ(internal->op_inputs[i], nullptr);
}
for (std::size_t i {}; i < k_max_op_params; ++i) {
ASSERT_EQ(mag_opp_unpack_type(internal->op_params[i]), MAG_OPP_NONE);
}
ASSERT_EQ(internal->init_op, MAG_IOP_NOP);
for (std::size_t i {}; i < k_max_op_params; ++i) {
ASSERT_EQ(mag_opp_unpack_type(internal->init_op_params[i]), MAG_OPP_NONE);
}
ASSERT_EQ(internal->flags, MAG_TFLAG_OWNER|MAG_TFLAG_REQUIRES_GRAD);
ASSERT_EQ(internal->grad, nullptr); // gradient is allocated lazily
ASSERT_EQ(internal->ud, nullptr);
}
|
O0
|
cpp
|
core_tensor_logic_init_2d_Test::~core_tensor_logic_init_2d_Test():
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
callq 0x9ede0
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
_ZN30core_tensor_logic_init_2d_TestD2Ev:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov rdi, [rbp+var_8]; this
call _ZN7testing4TestD2Ev; testing::Test::~Test()
add rsp, 10h
pop rbp
retn
|
void core_tensor_logic_init_2d_Test::~core_tensor_logic_init_2d_Test(core_tensor_logic_init_2d_Test *this)
{
testing::Test::~Test(this);
}
|
~core_tensor_logic_init_2d_Test:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x0019ede0
ADD RSP,0x10
POP RBP
RET
|
/* core_tensor_logic_init_2d_Test::~core_tensor_logic_init_2d_Test() */
void __thiscall
core_tensor_logic_init_2d_Test::~core_tensor_logic_init_2d_Test
(core_tensor_logic_init_2d_Test *this)
{
testing::Test::~Test((Test *)this);
return;
}
|
|
7,813 |
string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int>> const&)
|
monkey531[P]llama/common/common.cpp
|
std::string string_from(const struct llama_context * ctx, const std::vector<llama_token> & tokens) {
std::stringstream buf;
buf << "[ ";
bool first = true;
for (const auto & token : tokens) {
if (!first) {
buf << ", ";
} else {
first = false;
}
auto detokenized = common_token_to_piece(ctx, token);
detokenized.erase(
std::remove_if(
detokenized.begin(),
detokenized.end(),
[](const unsigned char c) { return !std::isprint(c); }),
detokenized.end());
buf << "'" << detokenized << "'"
<< ":" << std::to_string(token);
}
buf << " ]";
return buf.str();
}
|
O0
|
cpp
|
string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int>> const&):
subq $0x2a8, %rsp # imm = 0x2A8
movq %rdi, 0x48(%rsp)
movq %rdi, %rax
movq %rax, 0x50(%rsp)
movq %rdi, 0x2a0(%rsp)
movq %rsi, 0x298(%rsp)
movq %rdx, 0x290(%rsp)
leaq 0x108(%rsp), %rdi
callq 0x5a560
leaq 0x118(%rsp), %rdi
leaq 0x12329b(%rip), %rsi # 0x211df3
callq 0x5aa30
jmp 0xeeb5f
movb $0x1, 0xfb(%rsp)
movq 0x290(%rsp), %rax
movq %rax, 0xf0(%rsp)
movq 0xf0(%rsp), %rdi
callq 0x928a0
movq %rax, 0xe8(%rsp)
movq 0xf0(%rsp), %rdi
callq 0x928d0
movq %rax, 0xe0(%rsp)
leaq 0xe8(%rsp), %rdi
leaq 0xe0(%rsp), %rsi
callq 0xf9490
testb $0x1, %al
jne 0xeebbf
jmp 0xeedf8
leaq 0xe8(%rsp), %rdi
callq 0xf94d0
movq %rax, 0xd8(%rsp)
testb $0x1, 0xfb(%rsp)
jne 0xeec0f
leaq 0x118(%rsp), %rdi
leaq 0x123bbd(%rip), %rsi # 0x2127aa
callq 0x5aa30
jmp 0xeebf4
jmp 0xeec17
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
jmp 0xeee3c
movb $0x0, 0xfb(%rsp)
movq 0x298(%rsp), %rsi
movq 0xd8(%rsp), %rax
movl (%rax), %edx
leaq 0xb8(%rsp), %rdi
movl $0x1, %ecx
callq 0xeee60
jmp 0xeec3d
leaq 0xb8(%rsp), %rdi
movq %rdi, 0x38(%rsp)
callq 0x5a860
movq 0x38(%rsp), %rdi
movq %rax, 0xa0(%rsp)
callq 0x5a970
movq %rax, 0x98(%rsp)
movq 0xa0(%rsp), %rdi
movq 0x98(%rsp), %rsi
callq 0xeeed0
movq %rax, 0x40(%rsp)
jmp 0xeec85
movq 0x40(%rsp), %rax
movq %rax, 0xa8(%rsp)
leaq 0xb0(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
callq 0xc0160
leaq 0xb8(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0x5a970
movq %rax, 0x80(%rsp)
leaq 0x88(%rsp), %rdi
leaq 0x80(%rsp), %rsi
callq 0xc0160
movq 0x28(%rsp), %rdi
movq 0xb0(%rsp), %rsi
movq 0x88(%rsp), %rdx
callq 0x5a7a0
movq %rax, 0x30(%rsp)
jmp 0xeecf7
movq 0x30(%rsp), %rax
movq %rax, 0x78(%rsp)
leaq 0x118(%rsp), %rdi
leaq 0x121d58(%rip), %rsi # 0x210a68
callq 0x5aa30
movq %rax, 0x20(%rsp)
jmp 0xeed1c
movq 0x20(%rsp), %rdi
leaq 0xb8(%rsp), %rsi
callq 0x5a550
movq %rax, 0x18(%rsp)
jmp 0xeed35
movq 0x18(%rsp), %rdi
leaq 0x121d27(%rip), %rsi # 0x210a68
callq 0x5aa30
movq %rax, 0x10(%rsp)
jmp 0xeed4d
movq 0x10(%rsp), %rdi
leaq 0x123b9c(%rip), %rsi # 0x2128f5
callq 0x5aa30
movq %rax, 0x8(%rsp)
jmp 0xeed65
movq 0xd8(%rsp), %rax
movl (%rax), %esi
leaq 0x58(%rsp), %rdi
callq 0xa4460
jmp 0xeed7b
movq 0x8(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x5a550
jmp 0xeed8c
leaq 0x58(%rsp), %rdi
callq 0x5b568
leaq 0xb8(%rsp), %rdi
callq 0x5b568
leaq 0xe8(%rsp), %rdi
callq 0xf94e0
jmp 0xeeba1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
jmp 0xeede9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
leaq 0x58(%rsp), %rdi
callq 0x5b568
leaq 0xb8(%rsp), %rdi
callq 0x5b568
jmp 0xeee3c
leaq 0x118(%rsp), %rdi
leaq 0x122fef(%rip), %rsi # 0x211df6
callq 0x5aa30
jmp 0xeee0e
movq 0x48(%rsp), %rdi
leaq 0x108(%rsp), %rsi
callq 0x5ac90
jmp 0xeee22
leaq 0x108(%rsp), %rdi
callq 0x5a680
movq 0x50(%rsp), %rax
addq $0x2a8, %rsp # imm = 0x2A8
retq
leaq 0x108(%rsp), %rdi
callq 0x5a680
movq 0x100(%rsp), %rdi
callq 0x5abc0
nopw %cs:(%rax,%rax)
|
_Z11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEE:
sub rsp, 2A8h
mov [rsp+2A8h+var_260], rdi
mov rax, rdi
mov [rsp+2A8h+var_258], rax
mov [rsp+2A8h+var_8], rdi
mov [rsp+2A8h+var_10], rsi
mov [rsp+2A8h+var_18], rdx
lea rdi, [rsp+2A8h+var_1A0]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::basic_stringstream(void)
lea rdi, [rsp+2A8h+var_190]
lea rsi, asc_211DF3; "[ "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_EEB5F:
mov [rsp+2A8h+var_1AD], 1
mov rax, [rsp+2A8h+var_18]
mov [rsp+2A8h+var_1B8], rax
mov rdi, [rsp+2A8h+var_1B8]
call _ZNKSt6vectorIiSaIiEE5beginEv; std::vector<int>::begin(void)
mov [rsp+2A8h+var_1C0], rax
mov rdi, [rsp+2A8h+var_1B8]
call _ZNKSt6vectorIiSaIiEE3endEv; std::vector<int>::end(void)
mov [rsp+2A8h+var_1C8], rax
loc_EEBA1:
lea rdi, [rsp+2A8h+var_1C0]
lea rsi, [rsp+2A8h+var_1C8]
call _ZN9__gnu_cxxneIPKiSt6vectorIiSaIiEEEEbRKNS_17__normal_iteratorIT_T0_EESB_; __gnu_cxx::operator!=<int const*,std::vector<int>>(__gnu_cxx::__normal_iterator<int const*,std::vector<int>> const&,__gnu_cxx::__normal_iterator<int const*,std::vector<int>> const&)
test al, 1
jnz short loc_EEBBF
jmp loc_EEDF8
loc_EEBBF:
lea rdi, [rsp+2A8h+var_1C0]
call _ZNK9__gnu_cxx17__normal_iteratorIPKiSt6vectorIiSaIiEEEdeEv; __gnu_cxx::__normal_iterator<int const*,std::vector<int>>::operator*(void)
mov [rsp+2A8h+var_1D0], rax
test [rsp+2A8h+var_1AD], 1
jnz short loc_EEC0F
lea rdi, [rsp+2A8h+var_190]
lea rsi, aZuD+6; ", "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_EEBF4:
jmp short loc_EEC17
mov rcx, rax
mov eax, edx
mov [rsp+arg_F8], rcx
mov [rsp+arg_F4], eax
jmp loc_EEE3C
loc_EEC0F:
mov [rsp+2A8h+var_1AD], 0
loc_EEC17:
mov rsi, [rsp+2A8h+var_10]
mov rax, [rsp+2A8h+var_1D0]
mov edx, [rax]
lea rdi, [rsp+2A8h+var_1F0]
mov ecx, 1
call _Z21common_token_to_pieceB5cxx11PK13llama_contextib; common_token_to_piece(llama_context const*,int,bool)
jmp short $+2
loc_EEC3D:
lea rdi, [rsp+2A8h+var_1F0]
mov [rsp+2A8h+var_270], rdi
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5beginEv; std::string::begin(void)
mov rdi, [rsp+2A8h+var_270]
mov [rsp+2A8h+var_208], rax
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE3endEv; std::string::end(void)
mov [rsp+2A8h+var_210], rax
mov rdi, [rsp+2A8h+var_208]
mov rsi, [rsp+2A8h+var_210]
call _ZSt9remove_ifIN9__gnu_cxx17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEZ11string_fromPK13llama_contextRKSt6vectorIiSaIiEEE3$_0ET_SJ_SJ_T0_; std::remove_if<__gnu_cxx::__normal_iterator<char *,std::string>,string_from(llama_context const*,std::vector<int> const&)::$_0>(__gnu_cxx::__normal_iterator<char *,std::string>,__gnu_cxx::__normal_iterator<char *,std::string>,string_from(llama_context const*,std::vector<int> const&)::$_0)
mov [rsp+2A8h+var_268], rax
jmp short $+2
loc_EEC85:
mov rax, [rsp+2A8h+var_268]
mov [rsp+2A8h+var_200], rax
lea rdi, [rsp+2A8h+var_1F8]
lea rsi, [rsp+2A8h+var_200]
call _ZN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPcEERKNS0_IT_NS_11__enable_ifIXsr3std10__are_sameISC_SB_EE7__valueES8_E6__typeEEE
lea rdi, [rsp+2A8h+var_1F0]
mov [rsp+2A8h+var_280], rdi
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE3endEv; std::string::end(void)
mov [rsp+2A8h+var_228], rax
lea rdi, [rsp+2A8h+var_220]
lea rsi, [rsp+2A8h+var_228]
call _ZN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEC2IPcEERKNS0_IT_NS_11__enable_ifIXsr3std10__are_sameISC_SB_EE7__valueES8_E6__typeEEE
mov rdi, [rsp+2A8h+var_280]
mov rsi, [rsp+2A8h+var_1F8]
mov rdx, [rsp+2A8h+var_220]
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+2A8h+var_278], rax
jmp short $+2
loc_EECF7:
mov rax, [rsp+2A8h+var_278]
mov [rsp+2A8h+var_230], rax
lea rdi, [rsp+2A8h+var_190]
lea rsi, asc_210A66+2; "'"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rsp+2A8h+var_288], rax
jmp short $+2
loc_EED1C:
mov rdi, [rsp+2A8h+var_288]
lea rsi, [rsp+2A8h+var_1F0]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rsp+2A8h+var_290], rax
jmp short $+2
loc_EED35:
mov rdi, [rsp+2A8h+var_290]
lea rsi, asc_210A66+2; "'"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rsp+2A8h+var_298], rax
jmp short $+2
loc_EED4D:
mov rdi, [rsp+2A8h+var_298]
lea rsi, aArgumentNeedle_0+11h; ":"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rsp+2A8h+var_2A0], rax
jmp short $+2
loc_EED65:
mov rax, [rsp+2A8h+var_1D0]
mov esi, [rax]; int
lea rdi, [rsp+2A8h+var_250]; this
call _ZNSt7__cxx119to_stringEi; std::to_string(int)
jmp short $+2
loc_EED7B:
mov rdi, [rsp+2A8h+var_2A0]
lea rsi, [rsp+2A8h+var_250]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
jmp short $+2
loc_EED8C:
lea rdi, [rsp+2A8h+var_250]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+2A8h+var_1F0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+2A8h+var_1C0]
call _ZN9__gnu_cxx17__normal_iteratorIPKiSt6vectorIiSaIiEEEppEv; __gnu_cxx::__normal_iterator<int const*,std::vector<int>>::operator++(void)
jmp loc_EEBA1
mov rcx, rax
mov eax, edx
mov [rsp+arg_F8], rcx
mov [rsp+arg_F4], eax
jmp short loc_EEDE9
mov rcx, rax
mov eax, edx
mov [rsp+arg_F8], rcx
mov [rsp+arg_F4], eax
lea rdi, [rsp+arg_50]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_EEDE9:
lea rdi, [rsp+arg_B0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_EEE3C
loc_EEDF8:
lea rdi, [rsp+2A8h+var_190]
lea rsi, asc_211DF6; " ]"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_EEE0E:
mov rdi, [rsp+2A8h+var_260]
lea rsi, [rsp+2A8h+var_1A0]
call __ZNKSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEE3strEv; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::str(void)
jmp short $+2
loc_EEE22:
lea rdi, [rsp+2A8h+var_1A0]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED1Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream()
mov rax, [rsp+2A8h+var_258]
add rsp, 2A8h
retn
loc_EEE3C:
lea rdi, [rsp+arg_100]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED1Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream()
mov rdi, [rsp+arg_F8]
call __Unwind_Resume
|
long long string_from[abi:cxx11](long long a1, long long a2, long long a3)
{
long long v4; // [rsp+8h] [rbp-2A0h]
long long v5; // [rsp+10h] [rbp-298h]
long long v6; // [rsp+18h] [rbp-290h]
long long v7; // [rsp+20h] [rbp-288h]
_BYTE v8[32]; // [rsp+58h] [rbp-250h] BYREF
long long v9; // [rsp+78h] [rbp-230h]
long long v10; // [rsp+80h] [rbp-228h] BYREF
long long v11; // [rsp+88h] [rbp-220h] BYREF
long long v12; // [rsp+98h] [rbp-210h]
long long v13; // [rsp+A0h] [rbp-208h]
long long v14; // [rsp+A8h] [rbp-200h] BYREF
long long v15; // [rsp+B0h] [rbp-1F8h] BYREF
_BYTE v16[32]; // [rsp+B8h] [rbp-1F0h] BYREF
int *v17; // [rsp+D8h] [rbp-1D0h]
long long v18; // [rsp+E0h] [rbp-1C8h] BYREF
long long v19; // [rsp+E8h] [rbp-1C0h] BYREF
long long v20; // [rsp+F0h] [rbp-1B8h]
char v21; // [rsp+FBh] [rbp-1ADh]
_BYTE v22[16]; // [rsp+108h] [rbp-1A0h] BYREF
_BYTE v23[376]; // [rsp+118h] [rbp-190h] BYREF
long long v24; // [rsp+290h] [rbp-18h]
long long v25; // [rsp+298h] [rbp-10h]
long long v26; // [rsp+2A0h] [rbp-8h]
v26 = a1;
v25 = a2;
v24 = a3;
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::basic_stringstream(v22);
std::operator<<<std::char_traits<char>>(v23, "[ ");
v21 = 1;
v20 = v24;
v19 = std::vector<int>::begin(v24);
v18 = std::vector<int>::end(v20);
while ( (__gnu_cxx::operator!=<int const*,std::vector<int>>(&v19, &v18) & 1) != 0 )
{
v17 = (int *)__gnu_cxx::__normal_iterator<int const*,std::vector<int>>::operator*(&v19);
if ( (v21 & 1) != 0 )
v21 = 0;
else
std::operator<<<std::char_traits<char>>(v23, ", ");
common_token_to_piece[abi:cxx11](v16, v25, (unsigned int)*v17, 1LL);
v13 = std::string::begin(v16);
v12 = std::string::end(v16);
v14 = std::remove_if<__gnu_cxx::__normal_iterator<char *,std::string>,string_from(llama_context const*,std::vector<int> const&)::$_0>(
v13,
v12);
__gnu_cxx::__normal_iterator<char const*,std::string>::__normal_iterator<char *>(&v15, (long long)&v14);
v10 = std::string::end(v16);
__gnu_cxx::__normal_iterator<char const*,std::string>::__normal_iterator<char *>(&v11, (long long)&v10);
v9 = std::string::erase(v16, v15, v11);
v7 = std::operator<<<std::char_traits<char>>(v23, "'");
v6 = std::operator<<<char>(v7, v16);
v5 = std::operator<<<std::char_traits<char>>(v6, "'");
v4 = std::operator<<<std::char_traits<char>>(v5, ":");
std::to_string((std::__cxx11 *)v8, *v17);
std::operator<<<char>(v4, v8);
std::string::~string(v8);
std::string::~string(v16);
__gnu_cxx::__normal_iterator<int const*,std::vector<int>>::operator++(&v19);
}
std::operator<<<std::char_traits<char>>(v23, " ]");
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::str(a1, v22);
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream(v22);
return a1;
}
|
string_from[abi:cxx11]:
SUB RSP,0x2a8
MOV qword ptr [RSP + 0x48],RDI
MOV RAX,RDI
MOV qword ptr [RSP + 0x50],RAX
MOV qword ptr [RSP + 0x2a0],RDI
MOV qword ptr [RSP + 0x298],RSI
MOV qword ptr [RSP + 0x290],RDX
LEA RDI,[RSP + 0x108]
CALL 0x0015a560
LEA RDI,[RSP + 0x118]
LAB_001eeb51:
LEA RSI,[0x311df3]
CALL 0x0015aa30
JMP 0x001eeb5f
LAB_001eeb5f:
MOV byte ptr [RSP + 0xfb],0x1
MOV RAX,qword ptr [RSP + 0x290]
MOV qword ptr [RSP + 0xf0],RAX
MOV RDI,qword ptr [RSP + 0xf0]
CALL 0x001928a0
MOV qword ptr [RSP + 0xe8],RAX
MOV RDI,qword ptr [RSP + 0xf0]
CALL 0x001928d0
MOV qword ptr [RSP + 0xe0],RAX
LAB_001eeba1:
LEA RDI,[RSP + 0xe8]
LEA RSI,[RSP + 0xe0]
CALL 0x001f9490
TEST AL,0x1
JNZ 0x001eebbf
JMP 0x001eedf8
LAB_001eebbf:
LEA RDI,[RSP + 0xe8]
CALL 0x001f94d0
MOV qword ptr [RSP + 0xd8],RAX
TEST byte ptr [RSP + 0xfb],0x1
JNZ 0x001eec0f
LEA RDI,[RSP + 0x118]
LEA RSI,[0x3127aa]
CALL 0x0015aa30
JMP 0x001eebf4
LAB_001eebf4:
JMP 0x001eec17
LAB_001eec0f:
MOV byte ptr [RSP + 0xfb],0x0
LAB_001eec17:
MOV RSI,qword ptr [RSP + 0x298]
MOV RAX,qword ptr [RSP + 0xd8]
MOV EDX,dword ptr [RAX]
LEA RDI,[RSP + 0xb8]
MOV ECX,0x1
CALL 0x001eee60
JMP 0x001eec3d
LAB_001eec3d:
LEA RDI,[RSP + 0xb8]
MOV qword ptr [RSP + 0x38],RDI
CALL 0x0015a860
MOV RDI,qword ptr [RSP + 0x38]
MOV qword ptr [RSP + 0xa0],RAX
CALL 0x0015a970
MOV qword ptr [RSP + 0x98],RAX
MOV RDI,qword ptr [RSP + 0xa0]
MOV RSI,qword ptr [RSP + 0x98]
LAB_001eec79:
CALL 0x001eeed0
MOV qword ptr [RSP + 0x40],RAX
JMP 0x001eec85
LAB_001eec85:
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP + 0xa8],RAX
LEA RDI,[RSP + 0xb0]
LEA RSI,[RSP + 0xa8]
CALL 0x001c0160
LEA RDI,[RSP + 0xb8]
MOV qword ptr [RSP + 0x28],RDI
CALL 0x0015a970
MOV qword ptr [RSP + 0x80],RAX
LEA RDI,[RSP + 0x88]
LEA RSI,[RSP + 0x80]
CALL 0x001c0160
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,qword ptr [RSP + 0xb0]
MOV RDX,qword ptr [RSP + 0x88]
CALL 0x0015a7a0
MOV qword ptr [RSP + 0x30],RAX
JMP 0x001eecf7
LAB_001eecf7:
MOV RAX,qword ptr [RSP + 0x30]
MOV qword ptr [RSP + 0x78],RAX
LEA RDI,[RSP + 0x118]
LEA RSI,[0x310a68]
CALL 0x0015aa30
MOV qword ptr [RSP + 0x20],RAX
JMP 0x001eed1c
LAB_001eed1c:
MOV RDI,qword ptr [RSP + 0x20]
LEA RSI,[RSP + 0xb8]
CALL 0x0015a550
MOV qword ptr [RSP + 0x18],RAX
JMP 0x001eed35
LAB_001eed35:
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[0x310a68]
CALL 0x0015aa30
MOV qword ptr [RSP + 0x10],RAX
JMP 0x001eed4d
LAB_001eed4d:
MOV RDI,qword ptr [RSP + 0x10]
LEA RSI,[0x3128f5]
CALL 0x0015aa30
MOV qword ptr [RSP + 0x8],RAX
JMP 0x001eed65
LAB_001eed65:
MOV RAX,qword ptr [RSP + 0xd8]
MOV ESI,dword ptr [RAX]
LEA RDI,[RSP + 0x58]
CALL 0x001a4460
JMP 0x001eed7b
LAB_001eed7b:
MOV RDI,qword ptr [RSP + 0x8]
LEA RSI,[RSP + 0x58]
CALL 0x0015a550
JMP 0x001eed8c
LAB_001eed8c:
LEA RDI,[RSP + 0x58]
CALL 0x0015b568
LEA RDI,[RSP + 0xb8]
CALL 0x0015b568
LEA RDI,[RSP + 0xe8]
CALL 0x001f94e0
JMP 0x001eeba1
LAB_001eedf8:
LEA RDI,[RSP + 0x118]
LAB_001eee00:
LEA RSI,[0x311df6]
CALL 0x0015aa30
JMP 0x001eee0e
LAB_001eee0e:
MOV RDI,qword ptr [RSP + 0x48]
LEA RSI,[RSP + 0x108]
CALL 0x0015ac90
LAB_001eee20:
JMP 0x001eee22
LAB_001eee22:
LEA RDI,[RSP + 0x108]
CALL 0x0015a680
MOV RAX,qword ptr [RSP + 0x50]
ADD RSP,0x2a8
RET
|
/* string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int> > const&) */
llama_context * string_from_abi_cxx11_(llama_context *param_1,vector *param_2)
{
bool bVar1;
ostream *poVar2;
vector<int,std::allocator<int>> *in_RDX;
__cxx11 local_250 [32];
int8 local_230;
int8 local_228;
int8 local_220 [2];
int8 local_210;
int8 local_208;
int8 local_200;
int8 local_1f8;
llama_context local_1f0 [32];
int *local_1d0;
int8 local_1c8;
int8 local_1c0;
vector<int,std::allocator<int>> *local_1b8;
byte local_1ad;
stringstream local_1a0 [16];
ostream local_190 [376];
vector<int,std::allocator<int>> *local_18;
vector *local_10;
llama_context *local_8;
local_18 = in_RDX;
local_10 = param_2;
local_8 = param_1;
std::__cxx11::stringstream::stringstream(local_1a0);
/* try { // try from 001eeb51 to 001eec3a has its CatchHandler @ 001eebf6 */
std::operator<<(local_190,"[ ");
local_1ad = 1;
local_1b8 = local_18;
local_1c0 = std::vector<int,std::allocator<int>>::begin(local_18);
local_1c8 = std::vector<int,std::allocator<int>>::end(local_1b8);
while( true ) {
bVar1 = __gnu_cxx::operator!=((__normal_iterator *)&local_1c0,(__normal_iterator *)&local_1c8);
if (!bVar1) break;
local_1d0 = (int *)__gnu_cxx::__normal_iterator<int_const*,std::vector<int,std::allocator<int>>>
::operator*((__normal_iterator<int_const*,std::vector<int,std::allocator<int>>>
*)&local_1c0);
if ((local_1ad & 1) == 0) {
std::operator<<(local_190,", ");
}
else {
local_1ad = 0;
}
common_token_to_piece_abi_cxx11_(local_1f0,(int)local_10,SUB41(*local_1d0,0));
local_208 = std::__cxx11::string::begin();
local_210 = std::__cxx11::string::end();
/* try { // try from 001eec79 to 001eed78 has its CatchHandler @ 001eedb5 */
local_200 = std::
remove_if<__gnu_cxx::__normal_iterator<char*,std::__cxx11::string>,string_from(llama_context_const*,std::vector<int,std::allocator<int>>const&)::__0>
(local_208,local_210);
__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::__normal_iterator<char*>
((__normal_iterator<char_const*,std::__cxx11::string> *)&local_1f8,
(__normal_iterator *)&local_200);
local_228 = std::__cxx11::string::end();
__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::__normal_iterator<char*>
((__normal_iterator<char_const*,std::__cxx11::string> *)local_220,
(__normal_iterator *)&local_228);
local_230 = std::__cxx11::string::erase(local_1f0,local_1f8,local_220[0]);
poVar2 = std::operator<<(local_190,"\'");
poVar2 = std::operator<<(poVar2,(string *)local_1f0);
poVar2 = std::operator<<(poVar2,"\'");
poVar2 = std::operator<<(poVar2,":");
std::__cxx11::to_string(local_250,*local_1d0);
/* try { // try from 001eed7b to 001eed89 has its CatchHandler @ 001eedcb */
std::operator<<(poVar2,(string *)local_250);
std::__cxx11::string::~string((string *)local_250);
std::__cxx11::string::~string((string *)local_1f0);
__gnu_cxx::__normal_iterator<int_const*,std::vector<int,std::allocator<int>>>::operator++
((__normal_iterator<int_const*,std::vector<int,std::allocator<int>>> *)&local_1c0);
}
/* try { // try from 001eee00 to 001eee1f has its CatchHandler @ 001eebf6 */
std::operator<<(local_190," ]");
std::__cxx11::stringstream::str();
std::__cxx11::stringstream::~stringstream(local_1a0);
return param_1;
}
|
|
7,814 |
string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int>> const&)
|
monkey531[P]llama/common/common.cpp
|
std::string string_from(const struct llama_context * ctx, const std::vector<llama_token> & tokens) {
std::stringstream buf;
buf << "[ ";
bool first = true;
for (const auto & token : tokens) {
if (!first) {
buf << ", ";
} else {
first = false;
}
auto detokenized = common_token_to_piece(ctx, token);
detokenized.erase(
std::remove_if(
detokenized.begin(),
detokenized.end(),
[](const unsigned char c) { return !std::isprint(c); }),
detokenized.end());
buf << "'" << detokenized << "'"
<< ":" << std::to_string(token);
}
buf << " ]";
return buf.str();
}
|
O3
|
cpp
|
string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int>> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1e8, %rsp # imm = 0x1E8
movq %rdx, %rbx
movq %rsi, 0x58(%rsp)
movq %rdi, 0x48(%rsp)
leaq 0x60(%rsp), %rdi
callq 0x1a660
leaq 0x70(%rsp), %r14
leaq 0x7ca78(%rip), %rsi # 0xef42f
movl $0x2, %edx
movq %r14, %rdi
callq 0x1aa10
movq (%rbx), %r13
movq 0x8(%rbx), %rax
movq %rax, 0x50(%rsp)
cmpq %rax, %r13
je 0x72c91
movb $0x1, %al
testb $0x1, %al
jne 0x729f3
movl $0x2, %edx
movq %r14, %rdi
leaq 0x7d3e5(%rip), %rsi # 0xefdd3
callq 0x1aa10
movl (%r13), %ebx
movq 0x58(%rsp), %rdi
callq 0x1a7b0
movq %rax, %rdi
callq 0x1b160
leaq 0x8(%rsp), %rdi
movq %rax, %rsi
movl %ebx, %edx
movl $0x1, %ecx
callq 0x75b2d
movq 0x8(%rsp), %r15
movq 0x10(%rsp), %rax
leaq (%r15,%rax), %rbx
movq %rax, %r14
sarq $0x2, %r14
movq %r15, %rbp
testq %r14, %r14
jle 0x72a9b
andq $-0x4, %rax
movq %rax, %rbp
addq %r15, %rbp
incq %r14
leaq 0x3(%r15), %r12
movzbl -0x3(%r12), %edi
callq 0x1afc0
testl %eax, %eax
je 0x72af0
movzbl -0x2(%r12), %edi
callq 0x1afc0
testl %eax, %eax
je 0x72af6
movzbl -0x1(%r12), %edi
callq 0x1afc0
testl %eax, %eax
je 0x72afc
movzbl (%r12), %edi
callq 0x1afc0
testl %eax, %eax
je 0x72aff
decq %r14
addq $0x4, %r12
cmpq $0x1, %r14
jg 0x72a4b
movq %rbx, %rax
subq %rbp, %rax
cmpq $0x1, %rax
je 0x72adc
cmpq $0x2, %rax
leaq 0x70(%rsp), %r14
je 0x72acc
cmpq $0x3, %rax
jne 0x72c89
movzbl (%rbp), %edi
callq 0x1afc0
testl %eax, %eax
je 0x72aeb
incq %rbp
movzbl (%rbp), %edi
callq 0x1afc0
testl %eax, %eax
je 0x72aeb
incq %rbp
movzbl (%rbp), %edi
callq 0x1afc0
testl %eax, %eax
cmovneq %rbx, %rbp
movq %rbp, %r12
jmp 0x72aff
addq $-0x3, %r12
jmp 0x72aff
addq $-0x2, %r12
jmp 0x72aff
decq %r12
cmpq %rbx, %r12
sete %al
leaq 0x1(%r12), %r14
cmpq %rbx, %r14
sete %cl
orb %al, %cl
jne 0x72b38
movb (%r14), %bpl
movzbl %bpl, %edi
callq 0x1afc0
testl %eax, %eax
je 0x72b2b
movb %bpl, (%r12)
incq %r12
incq %r14
cmpq %rbx, %r14
jne 0x72b14
movq 0x8(%rsp), %r15
leaq 0x70(%rsp), %r14
movq %r12, %rax
subq %r15, %rax
movq %rax, 0x10(%rsp)
movb $0x0, (%r12)
movl $0x1, %edx
movq %r14, %rdi
leaq 0x7b985(%rip), %rsi # 0xee4e1
callq 0x1aa10
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
movq %r14, %rdi
callq 0x1aa10
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
leaq 0x7b95c(%rip), %rsi # 0xee4e1
callq 0x1aa10
movl $0x1, %edx
movq %r12, %rdi
leaq 0x7d385(%rip), %rsi # 0xeff1e
callq 0x1aa10
movl (%r13), %ebp
movl %ebp, %ebx
negl %ebx
cmovsl %ebp, %ebx
movl $0x1, %r15d
cmpl $0xa, %ebx
jb 0x72bfa
movl $0x4, %r15d
movl %ebx, %eax
cmpl $0x63, %eax
jbe 0x72bf1
cmpl $0x3e7, %eax # imm = 0x3E7
jbe 0x72bf7
cmpl $0x2710, %eax # imm = 0x2710
jb 0x72bfa
movl %eax, %ecx
movl $0xd1b71759, %edx # imm = 0xD1B71759
imulq %rdx, %rcx
shrq $0x2d, %rcx
addl $0x4, %r15d
cmpl $0x1869f, %eax # imm = 0x1869F
movl %ecx, %eax
ja 0x72bbc
addl $-0x3, %r15d
jmp 0x72bfa
addl $-0x2, %r15d
jmp 0x72bfa
decl %r15d
shrl $0x1f, %ebp
leal (%r15,%rbp), %esi
leaq 0x38(%rsp), %rax
movq %rax, 0x28(%rsp)
leaq 0x28(%rsp), %rdi
movl $0x2d, %edx
callq 0x1aa50
addq 0x28(%rsp), %rbp
movq %rbp, %rdi
movl %r15d, %esi
movl %ebx, %edx
callq 0x58e0b
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rdx
movq %r12, %rdi
callq 0x1aa10
movq 0x28(%rsp), %rdi
leaq 0x38(%rsp), %rax
cmpq %rax, %rdi
je 0x72c5a
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1a8f0
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x72c76
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a8f0
addq $0x4, %r13
xorl %eax, %eax
cmpq 0x50(%rsp), %r13
jne 0x729db
jmp 0x72c91
movq %rbx, %r12
jmp 0x72b3d
leaq 0x7c79a(%rip), %rsi # 0xef432
movl $0x2, %edx
movq %r14, %rdi
callq 0x1aa10
movq 0x48(%rsp), %rbx
leaq 0x78(%rsp), %rsi
movq %rbx, %rdi
callq 0x1add0
movq 0xb926a(%rip), %rsi # 0x12bf28
leaq 0x60(%rsp), %rdi
callq 0x1a6a0
leaq 0xe0(%rsp), %rdi
callq 0x1a2c0
movq %rbx, %rax
addq $0x1e8, %rsp # imm = 0x1E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x72d13
jmp 0x72d13
jmp 0x72d13
jmp 0x72d18
movq %rax, %rbx
movq 0x28(%rsp), %rdi
leaq 0x38(%rsp), %rax
cmpq %rax, %rdi
je 0x72d1b
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1a8f0
jmp 0x72d1b
movq %rax, %rbx
jmp 0x72d37
movq %rax, %rbx
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x72d37
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a8f0
movq 0xb91ea(%rip), %rsi # 0x12bf28
leaq 0x60(%rsp), %rdi
callq 0x1a6a0
leaq 0xe0(%rsp), %rdi
callq 0x1a2c0
movq %rbx, %rdi
callq 0x1afb0
|
_Z11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 1E8h
mov rbx, rdx
mov [rsp+218h+var_1C0], rsi
mov [rsp+218h+var_1D0], rdi
lea rdi, [rsp+218h+var_1B8]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::basic_stringstream(void)
lea r14, [rsp+218h+var_1A8]
lea rsi, asc_EF42F; "[ "
mov edx, 2
mov rdi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov r13, [rbx]
mov rax, [rbx+8]
mov [rsp+218h+var_1C8], rax
cmp r13, rax
jz loc_72C91
mov al, 1
loc_729DB:
test al, 1
jnz short loc_729F3
mov edx, 2
mov rdi, r14
lea rsi, aZuD+6; ", "
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
loc_729F3:
mov ebx, [r13+0]
mov rdi, [rsp+218h+var_1C0]
call _llama_get_model
mov rdi, rax
call _llama_model_get_vocab
lea rdi, [rsp+218h+var_210]
mov rsi, rax
mov edx, ebx
mov ecx, 1
call _Z21common_token_to_pieceB5cxx11PK11llama_vocabib; common_token_to_piece(llama_vocab const*,int,bool)
mov r15, [rsp+218h+var_210]
mov rax, [rsp+218h+var_208]
lea rbx, [r15+rax]
mov r14, rax
sar r14, 2
mov rbp, r15
test r14, r14
jle short loc_72A9B
and rax, 0FFFFFFFFFFFFFFFCh
mov rbp, rax
add rbp, r15
inc r14
lea r12, [r15+3]
loc_72A4B:
movzx edi, byte ptr [r12-3]
call _isprint
test eax, eax
jz loc_72AF0
movzx edi, byte ptr [r12-2]
call _isprint
test eax, eax
jz loc_72AF6
movzx edi, byte ptr [r12-1]
call _isprint
test eax, eax
jz short loc_72AFC
movzx edi, byte ptr [r12]
call _isprint
test eax, eax
jz short loc_72AFF
dec r14
add r12, 4
cmp r14, 1
jg short loc_72A4B
loc_72A9B:
mov rax, rbx
sub rax, rbp
cmp rax, 1
jz short loc_72ADC
cmp rax, 2
lea r14, [rsp+218h+var_1A8]
jz short loc_72ACC
cmp rax, 3
jnz loc_72C89
movzx edi, byte ptr [rbp+0]
call _isprint
test eax, eax
jz short loc_72AEB
inc rbp
loc_72ACC:
movzx edi, byte ptr [rbp+0]
call _isprint
test eax, eax
jz short loc_72AEB
inc rbp
loc_72ADC:
movzx edi, byte ptr [rbp+0]
call _isprint
test eax, eax
cmovnz rbp, rbx
loc_72AEB:
mov r12, rbp
jmp short loc_72AFF
loc_72AF0:
add r12, 0FFFFFFFFFFFFFFFDh
jmp short loc_72AFF
loc_72AF6:
add r12, 0FFFFFFFFFFFFFFFEh
jmp short loc_72AFF
loc_72AFC:
dec r12
loc_72AFF:
cmp r12, rbx
setz al
lea r14, [r12+1]
cmp r14, rbx
setz cl
or cl, al
jnz short loc_72B38
loc_72B14:
mov bpl, [r14]
movzx edi, bpl
call _isprint
test eax, eax
jz short loc_72B2B
mov [r12], bpl
inc r12
loc_72B2B:
inc r14
cmp r14, rbx
jnz short loc_72B14
mov r15, [rsp+218h+var_210]
loc_72B38:
lea r14, [rsp+218h+var_1A8]
loc_72B3D:
mov rax, r12
sub rax, r15
mov [rsp+218h+var_208], rax
mov byte ptr [r12], 0
mov edx, 1
mov rdi, r14
lea rsi, asc_EE4DF+2; "'"
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rsi, [rsp+218h+var_210]
mov rdx, [rsp+218h+var_208]
mov rdi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov r12, rax
mov edx, 1
mov rdi, rax
lea rsi, asc_EE4DF+2; "'"
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov edx, 1
mov rdi, r12
lea rsi, aArgumentNeedle_0+11h; ":"
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov ebp, [r13+0]
mov ebx, ebp
neg ebx
cmovs ebx, ebp
mov r15d, 1
cmp ebx, 0Ah
jb short loc_72BFA
mov r15d, 4
mov eax, ebx
loc_72BBC:
cmp eax, 63h ; 'c'
jbe short loc_72BF1
cmp eax, 3E7h
jbe short loc_72BF7
cmp eax, 2710h
jb short loc_72BFA
mov ecx, eax
mov edx, 0D1B71759h
imul rcx, rdx
shr rcx, 2Dh
add r15d, 4
cmp eax, 1869Fh
mov eax, ecx
ja short loc_72BBC
add r15d, 0FFFFFFFDh
jmp short loc_72BFA
loc_72BF1:
add r15d, 0FFFFFFFEh
jmp short loc_72BFA
loc_72BF7:
dec r15d
loc_72BFA:
shr ebp, 1Fh
lea esi, [r15+rbp]
lea rax, [rsp+218h+var_1E0]
mov [rsp+218h+var_1F0], rax
lea rdi, [rsp+218h+var_1F0]
mov edx, 2Dh ; '-'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructEmc; std::string::_M_construct(ulong,char)
add rbp, [rsp+218h+var_1F0]
mov rdi, rbp
mov esi, r15d
mov edx, ebx
call _ZNSt8__detail18__to_chars_10_implIjEEvPcjT_; std::__detail::__to_chars_10_impl<uint>(char *,uint,uint)
mov rsi, [rsp+218h+var_1F0]
mov rdx, [rsp+218h+var_1E8]
mov rdi, r12
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+218h+var_1F0]; void *
lea rax, [rsp+218h+var_1E0]
cmp rdi, rax
jz short loc_72C5A
mov rsi, [rsp+218h+var_1E0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_72C5A:
mov rdi, [rsp+218h+var_210]; void *
lea rax, [rsp+218h+var_200]
cmp rdi, rax
jz short loc_72C76
mov rsi, [rsp+218h+var_200]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_72C76:
add r13, 4
xor eax, eax
cmp r13, [rsp+218h+var_1C8]
jnz loc_729DB
jmp short loc_72C91
loc_72C89:
mov r12, rbx
jmp loc_72B3D
loc_72C91:
lea rsi, asc_EF432; " ]"
mov edx, 2
mov rdi, r14
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+218h+var_1D0]
lea rsi, [rsp+218h+var_1A0]
mov rdi, rbx
call __ZNKSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void)
mov rsi, cs:_ZTTNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+218h+var_1B8]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED2Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream()
lea rdi, [rsp+218h+var_138]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
mov rax, rbx
add rsp, 1E8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_72D13
jmp short loc_72D13
jmp short loc_72D13
jmp short loc_72D18
mov rbx, rax
mov rdi, [rsp+arg_20]; void *
lea rax, [rsp+arg_30]
cmp rdi, rax
jz short loc_72D1B
mov rsi, [rsp+arg_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_72D1B
loc_72D13:
mov rbx, rax
jmp short loc_72D37
loc_72D18:
mov rbx, rax
loc_72D1B:
mov rdi, [rsp+arg_0]; void *
lea rax, [rsp+arg_10]
cmp rdi, rax
jz short loc_72D37
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_72D37:
mov rsi, cs:_ZTTNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+arg_58]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED2Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream()
lea rdi, [rsp+arg_D8]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
mov rdi, rbx
call __Unwind_Resume
|
long long string_from[abi:cxx11](long long a1, long long a2, unsigned int **a3)
{
unsigned int *v4; // r13
char v5; // al
unsigned int v6; // ebx
long long model; // rax
long long vocab; // rax
_BYTE *v9; // r15
char *v10; // rbx
char *v11; // rbp
long long v12; // r14
char *v13; // r12
signed long long v14; // rax
char *v15; // r14
char v16; // bp
long long v17; // r12
unsigned int v18; // ebx
int v19; // r15d
unsigned int v20; // eax
bool v21; // cc
unsigned int v22; // ebp
long long v23; // rbx
void *v25; // [rsp+8h] [rbp-210h] BYREF
long long v26; // [rsp+10h] [rbp-208h]
long long v27; // [rsp+18h] [rbp-200h] BYREF
void *v28[2]; // [rsp+28h] [rbp-1F0h] BYREF
_QWORD v29[2]; // [rsp+38h] [rbp-1E0h] BYREF
long long v30; // [rsp+48h] [rbp-1D0h]
unsigned int *v31; // [rsp+50h] [rbp-1C8h]
long long v32; // [rsp+58h] [rbp-1C0h]
_BYTE v33[16]; // [rsp+60h] [rbp-1B8h] BYREF
char v34[8]; // [rsp+70h] [rbp-1A8h] BYREF
char v35[104]; // [rsp+78h] [rbp-1A0h] BYREF
char v36[312]; // [rsp+E0h] [rbp-138h] BYREF
v32 = a2;
v30 = a1;
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::basic_stringstream(v33);
std::__ostream_insert<char,std::char_traits<char>>(v34, "[ ", 2LL);
v4 = *a3;
v31 = a3[1];
if ( v4 != v31 )
{
v5 = 1;
while ( 1 )
{
if ( (v5 & 1) == 0 )
std::__ostream_insert<char,std::char_traits<char>>(v34, ", ", 2LL);
v6 = *v4;
model = llama_get_model(v32);
vocab = llama_model_get_vocab(model);
common_token_to_piece[abi:cxx11](&v25, vocab, v6, 1LL);
v9 = v25;
v10 = (char *)v25 + v26;
v11 = (char *)v25;
if ( v26 >> 2 > 0 )
break;
LABEL_12:
v14 = v10 - v11;
if ( v10 - v11 == 1 )
goto LABEL_19;
if ( v14 == 2 )
goto LABEL_17;
if ( v14 == 3 )
{
if ( (unsigned int)isprint((unsigned __int8)*v11) )
{
++v11;
LABEL_17:
if ( (unsigned int)isprint((unsigned __int8)*v11) )
{
++v11;
LABEL_19:
if ( (unsigned int)isprint((unsigned __int8)*v11) )
v11 = v10;
}
}
v13 = v11;
LABEL_25:
v15 = v13 + 1;
if ( v13 != v10 && v13 + 1 != v10 )
{
do
{
v16 = *v15;
if ( (unsigned int)isprint((unsigned __int8)*v15) )
*v13++ = v16;
++v15;
}
while ( v15 != v10 );
v9 = v25;
}
goto LABEL_30;
}
v13 = v10;
LABEL_30:
v26 = v13 - v9;
*v13 = 0;
std::__ostream_insert<char,std::char_traits<char>>(v34, "'", 1LL);
v17 = std::__ostream_insert<char,std::char_traits<char>>(v34, v25, v26);
std::__ostream_insert<char,std::char_traits<char>>(v17, "'", 1LL);
std::__ostream_insert<char,std::char_traits<char>>(v17, ":", 1LL);
v18 = -*v4;
if ( (int)*v4 > 0 )
v18 = *v4;
v19 = 1;
if ( v18 >= 0xA )
{
v19 = 4;
v20 = v18;
while ( 1 )
{
if ( v20 <= 0x63 )
{
v19 -= 2;
goto LABEL_41;
}
if ( v20 <= 0x3E7 )
break;
if ( v20 < 0x2710 )
goto LABEL_41;
v19 += 4;
v21 = v20 <= 0x1869F;
v20 /= 0x2710u;
if ( v21 )
{
v19 -= 3;
goto LABEL_41;
}
}
--v19;
}
LABEL_41:
v22 = *v4 >> 31;
v28[0] = v29;
std::string::_M_construct(v28, v19 + v22, 45LL);
std::__detail::__to_chars_10_impl<unsigned int>((char *)v28[0] + v22, v19, v18);
std::__ostream_insert<char,std::char_traits<char>>(v17, v28[0], v28[1]);
if ( v28[0] != v29 )
operator delete(v28[0], v29[0] + 1LL);
if ( v25 != &v27 )
operator delete(v25, v27 + 1);
++v4;
v5 = 0;
if ( v4 == v31 )
goto LABEL_48;
}
v11 = (char *)v25 + (v26 & 0xFFFFFFFFFFFFFFFCLL);
v12 = (v26 >> 2) + 1;
v13 = (char *)v25 + 3;
while ( 1 )
{
if ( !(unsigned int)isprint((unsigned __int8)*(v13 - 3)) )
{
v13 -= 3;
goto LABEL_25;
}
if ( !(unsigned int)isprint((unsigned __int8)*(v13 - 2)) )
{
v13 -= 2;
goto LABEL_25;
}
if ( !(unsigned int)isprint((unsigned __int8)*(v13 - 1)) )
break;
if ( !(unsigned int)isprint((unsigned __int8)*v13) )
goto LABEL_25;
--v12;
v13 += 4;
if ( v12 <= 1 )
goto LABEL_12;
}
--v13;
goto LABEL_25;
}
LABEL_48:
std::__ostream_insert<char,std::char_traits<char>>(v34, " ]", 2LL);
v23 = v30;
std::stringbuf::str(v30, v35);
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream(
v33,
&`VTT for'std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>);
std::ios_base::~ios_base((std::ios_base *)v36);
return v23;
}
|
string_from[abi:cxx11]:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x1e8
MOV RBX,RDX
MOV qword ptr [RSP + 0x58],RSI
MOV qword ptr [RSP + 0x48],RDI
LEA RDI,[RSP + 0x60]
CALL 0x0011a660
LEA R14,[RSP + 0x70]
LAB_001729b0:
LEA RSI,[0x1ef42f]
MOV EDX,0x2
MOV RDI,R14
CALL 0x0011aa10
MOV R13,qword ptr [RBX]
MOV RAX,qword ptr [RBX + 0x8]
MOV qword ptr [RSP + 0x50],RAX
CMP R13,RAX
JZ 0x00172c91
MOV AL,0x1
LAB_001729db:
TEST AL,0x1
JNZ 0x001729f3
LAB_001729df:
MOV EDX,0x2
MOV RDI,R14
LEA RSI,[0x1efdd3]
CALL 0x0011aa10
LAB_001729f3:
MOV EBX,dword ptr [R13]
LAB_001729f7:
MOV RDI,qword ptr [RSP + 0x58]
CALL 0x0011a7b0
MOV RDI,RAX
CALL 0x0011b160
LEA RDI,[RSP + 0x8]
MOV RSI,RAX
MOV EDX,EBX
MOV ECX,0x1
CALL 0x00175b2d
MOV R15,qword ptr [RSP + 0x8]
MOV RAX,qword ptr [RSP + 0x10]
LEA RBX,[R15 + RAX*0x1]
MOV R14,RAX
SAR R14,0x2
MOV RBP,R15
TEST R14,R14
JLE 0x00172a9b
AND RAX,-0x4
MOV RBP,RAX
ADD RBP,R15
INC R14
LEA R12,[R15 + 0x3]
LAB_00172a4b:
MOVZX EDI,byte ptr [R12 + -0x3]
CALL 0x0011afc0
TEST EAX,EAX
JZ 0x00172af0
MOVZX EDI,byte ptr [R12 + -0x2]
CALL 0x0011afc0
TEST EAX,EAX
JZ 0x00172af6
MOVZX EDI,byte ptr [R12 + -0x1]
CALL 0x0011afc0
TEST EAX,EAX
JZ 0x00172afc
MOVZX EDI,byte ptr [R12]
CALL 0x0011afc0
TEST EAX,EAX
JZ 0x00172aff
DEC R14
ADD R12,0x4
CMP R14,0x1
JG 0x00172a4b
LAB_00172a9b:
MOV RAX,RBX
SUB RAX,RBP
CMP RAX,0x1
JZ 0x00172adc
CMP RAX,0x2
LEA R14,[RSP + 0x70]
JZ 0x00172acc
CMP RAX,0x3
JNZ 0x00172c89
MOVZX EDI,byte ptr [RBP]
CALL 0x0011afc0
TEST EAX,EAX
JZ 0x00172aeb
INC RBP
LAB_00172acc:
MOVZX EDI,byte ptr [RBP]
CALL 0x0011afc0
TEST EAX,EAX
JZ 0x00172aeb
INC RBP
LAB_00172adc:
MOVZX EDI,byte ptr [RBP]
CALL 0x0011afc0
TEST EAX,EAX
CMOVNZ RBP,RBX
LAB_00172aeb:
MOV R12,RBP
JMP 0x00172aff
LAB_00172af0:
ADD R12,-0x3
JMP 0x00172aff
LAB_00172af6:
ADD R12,-0x2
JMP 0x00172aff
LAB_00172afc:
DEC R12
LAB_00172aff:
CMP R12,RBX
SETZ AL
LEA R14,[R12 + 0x1]
CMP R14,RBX
SETZ CL
OR CL,AL
JNZ 0x00172b38
LAB_00172b14:
MOV BPL,byte ptr [R14]
MOVZX EDI,BPL
CALL 0x0011afc0
TEST EAX,EAX
JZ 0x00172b2b
MOV byte ptr [R12],BPL
INC R12
LAB_00172b2b:
INC R14
CMP R14,RBX
JNZ 0x00172b14
MOV R15,qword ptr [RSP + 0x8]
LAB_00172b38:
LEA R14,[RSP + 0x70]
LAB_00172b3d:
MOV RAX,R12
SUB RAX,R15
MOV qword ptr [RSP + 0x10],RAX
MOV byte ptr [R12],0x0
LAB_00172b4d:
MOV EDX,0x1
MOV RDI,R14
LEA RSI,[0x1ee4e1]
CALL 0x0011aa10
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
MOV RDI,R14
CALL 0x0011aa10
MOV R12,RAX
MOV EDX,0x1
MOV RDI,RAX
LEA RSI,[0x1ee4e1]
CALL 0x0011aa10
MOV EDX,0x1
MOV RDI,R12
LEA RSI,[0x1eff1e]
CALL 0x0011aa10
MOV EBP,dword ptr [R13]
MOV EBX,EBP
NEG EBX
CMOVS EBX,EBP
MOV R15D,0x1
CMP EBX,0xa
JC 0x00172bfa
MOV R15D,0x4
MOV EAX,EBX
LAB_00172bbc:
CMP EAX,0x63
JBE 0x00172bf1
CMP EAX,0x3e7
JBE 0x00172bf7
CMP EAX,0x2710
JC 0x00172bfa
MOV ECX,EAX
MOV EDX,0xd1b71759
IMUL RCX,RDX
SHR RCX,0x2d
ADD R15D,0x4
CMP EAX,0x1869f
MOV EAX,ECX
JA 0x00172bbc
ADD R15D,-0x3
JMP 0x00172bfa
LAB_00172bf1:
ADD R15D,-0x2
JMP 0x00172bfa
LAB_00172bf7:
DEC R15D
LAB_00172bfa:
SHR EBP,0x1f
LEA ESI,[R15 + RBP*0x1]
LEA RAX,[RSP + 0x38]
MOV qword ptr [RSP + 0x28],RAX
LAB_00172c0b:
LEA RDI,[RSP + 0x28]
MOV EDX,0x2d
CALL 0x0011aa50
ADD RBP,qword ptr [RSP + 0x28]
MOV RDI,RBP
MOV ESI,R15D
MOV EDX,EBX
CALL 0x00158e0b
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,qword ptr [RSP + 0x30]
LAB_00172c36:
MOV RDI,R12
CALL 0x0011aa10
MOV RDI,qword ptr [RSP + 0x28]
LEA RAX,[RSP + 0x38]
CMP RDI,RAX
JZ 0x00172c5a
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x0011a8f0
LAB_00172c5a:
MOV RDI,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x18]
CMP RDI,RAX
JZ 0x00172c76
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011a8f0
LAB_00172c76:
ADD R13,0x4
XOR EAX,EAX
CMP R13,qword ptr [RSP + 0x50]
JNZ 0x001729db
JMP 0x00172c91
LAB_00172c89:
MOV R12,RBX
JMP 0x00172b3d
LAB_00172c91:
LEA RSI,[0x1ef432]
MOV EDX,0x2
MOV RDI,R14
CALL 0x0011aa10
MOV RBX,qword ptr [RSP + 0x48]
LEA RSI,[RSP + 0x78]
MOV RDI,RBX
CALL 0x0011add0
LAB_00172cb7:
MOV RSI,qword ptr [0x0022bf28]
LEA RDI,[RSP + 0x60]
CALL 0x0011a6a0
LEA RDI,[RSP + 0xe0]
CALL 0x0011a2c0
MOV RAX,RBX
ADD RSP,0x1e8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int> > const&) */
llama_context * string_from_abi_cxx11_(llama_context *param_1,vector *param_2)
{
byte *pbVar1;
byte bVar2;
uint uVar3;
uint uVar4;
llama_context *plVar5;
uint uVar6;
bool bVar7;
int iVar8;
uint uVar9;
int8 uVar10;
ostream *poVar11;
ulong uVar12;
int8 *in_RDX;
byte *pbVar13;
byte *pbVar14;
uint *puVar15;
long lVar16;
uint uVar17;
byte *pbVar18;
byte *local_210;
ulong local_208;
long local_200 [2];
long *local_1f0;
long local_1e8;
long local_1e0 [2];
llama_context *local_1d0;
uint *local_1c8;
vector *local_1c0;
stringstream local_1b8 [16];
ostream local_1a8 [112];
ios_base local_138 [264];
local_1d0 = param_1;
local_1c0 = param_2;
std::__cxx11::stringstream::stringstream(local_1b8);
/* try { // try from 001729b0 to 001729c3 has its CatchHandler @ 00172cea */
std::__ostream_insert<char,std::char_traits<char>>(local_1a8,"[ ",2);
puVar15 = (uint *)*in_RDX;
local_1c8 = (uint *)in_RDX[1];
if (puVar15 != local_1c8) {
bVar7 = true;
do {
if (!bVar7) {
/* try { // try from 001729df to 001729f2 has its CatchHandler @ 00172cee */
std::__ostream_insert<char,std::char_traits<char>>(local_1a8,", ",2);
}
uVar3 = *puVar15;
/* try { // try from 001729f7 to 00172a1c has its CatchHandler @ 00172d13 */
uVar10 = llama_get_model(local_1c0);
iVar8 = llama_model_get_vocab(uVar10);
common_token_to_piece_abi_cxx11_((llama_vocab *)&local_210,iVar8,SUB41(uVar3,0));
pbVar18 = local_210;
pbVar1 = local_210 + local_208;
pbVar13 = local_210;
if (0 < (long)local_208 >> 2) {
pbVar13 = local_210 + (local_208 & 0xfffffffffffffffc);
lVar16 = ((long)local_208 >> 2) + 1;
pbVar14 = local_210 + 3;
do {
iVar8 = isprint((uint)pbVar14[-3]);
if (iVar8 == 0) {
pbVar14 = pbVar14 + -3;
goto LAB_00172aff;
}
iVar8 = isprint((uint)pbVar14[-2]);
if (iVar8 == 0) {
pbVar14 = pbVar14 + -2;
goto LAB_00172aff;
}
iVar8 = isprint((uint)pbVar14[-1]);
if (iVar8 == 0) {
pbVar14 = pbVar14 + -1;
goto LAB_00172aff;
}
iVar8 = isprint((uint)*pbVar14);
if (iVar8 == 0) goto LAB_00172aff;
lVar16 = lVar16 + -1;
pbVar14 = pbVar14 + 4;
} while (1 < lVar16);
}
lVar16 = (long)pbVar1 - (long)pbVar13;
if (lVar16 == 1) {
LAB_00172adc:
iVar8 = isprint((uint)*pbVar13);
pbVar14 = pbVar13;
if (iVar8 != 0) {
pbVar14 = pbVar1;
}
LAB_00172aff:
pbVar13 = pbVar14 + 1;
if (pbVar13 != pbVar1 && pbVar14 != pbVar1) {
do {
bVar2 = *pbVar13;
iVar8 = isprint((uint)bVar2);
if (iVar8 != 0) {
*pbVar14 = bVar2;
pbVar14 = pbVar14 + 1;
}
pbVar13 = pbVar13 + 1;
pbVar18 = local_210;
} while (pbVar13 != pbVar1);
}
}
else {
if (lVar16 == 2) {
LAB_00172acc:
iVar8 = isprint((uint)*pbVar13);
pbVar14 = pbVar13;
if (iVar8 != 0) {
pbVar13 = pbVar13 + 1;
goto LAB_00172adc;
}
goto LAB_00172aff;
}
pbVar14 = pbVar1;
if (lVar16 == 3) {
iVar8 = isprint((uint)*pbVar13);
pbVar14 = pbVar13;
if (iVar8 != 0) {
pbVar13 = pbVar13 + 1;
goto LAB_00172acc;
}
goto LAB_00172aff;
}
}
local_208 = (long)pbVar14 - (long)pbVar18;
*pbVar14 = 0;
/* try { // try from 00172b4d to 00172b9d has its CatchHandler @ 00172d18 */
std::__ostream_insert<char,std::char_traits<char>>(local_1a8,"\'",1);
poVar11 = std::__ostream_insert<char,std::char_traits<char>>
(local_1a8,(char *)local_210,local_208);
std::__ostream_insert<char,std::char_traits<char>>(poVar11,"\'",1);
std::__ostream_insert<char,std::char_traits<char>>(poVar11,":",1);
uVar3 = *puVar15;
uVar4 = -uVar3;
if (0 < (int)uVar3) {
uVar4 = uVar3;
}
uVar17 = 1;
if (9 < uVar4) {
uVar12 = (ulong)uVar4;
uVar6 = 4;
do {
uVar17 = uVar6;
uVar9 = (uint)uVar12;
if (uVar9 < 100) {
uVar17 = uVar17 - 2;
goto LAB_00172bfa;
}
if (uVar9 < 1000) {
uVar17 = uVar17 - 1;
goto LAB_00172bfa;
}
if (uVar9 < 10000) goto LAB_00172bfa;
uVar12 = uVar12 / 10000;
uVar6 = uVar17 + 4;
} while (99999 < uVar9);
uVar17 = uVar17 + 1;
}
LAB_00172bfa:
local_1f0 = local_1e0;
/* try { // try from 00172c0b to 00172c19 has its CatchHandler @ 00172cf0 */
std::__cxx11::string::_M_construct
((ulong)&local_1f0,(char)uVar17 - (char)((int)uVar3 >> 0x1f));
std::__detail::__to_chars_10_impl<unsigned_int>
((char *)((long)local_1f0 + (ulong)(uVar3 >> 0x1f)),uVar17,uVar4);
/* try { // try from 00172c36 to 00172c3d has its CatchHandler @ 00172cf2 */
std::__ostream_insert<char,std::char_traits<char>>(poVar11,(char *)local_1f0,local_1e8);
if (local_1f0 != local_1e0) {
operator_delete(local_1f0,local_1e0[0] + 1);
}
if (local_210 != (byte *)local_200) {
operator_delete(local_210,local_200[0] + 1);
}
puVar15 = puVar15 + 1;
bVar7 = false;
} while (puVar15 != local_1c8);
}
/* try { // try from 00172c91 to 00172cb6 has its CatchHandler @ 00172cec */
std::__ostream_insert<char,std::char_traits<char>>(local_1a8," ]",2);
plVar5 = local_1d0;
std::__cxx11::stringbuf::str();
std::__cxx11::stringstream::~stringstream(local_1b8);
std::ios_base::~ios_base(local_138);
return plVar5;
}
|
|
7,815 |
unlink_hash
|
eloqsql/mysys/mf_keycache.c
|
static void unlink_hash(SIMPLE_KEY_CACHE_CB *keycache, HASH_LINK *hash_link)
{
KEYCACHE_DBUG_PRINT("unlink_hash", ("fd: %u pos_ %lu #requests=%u",
(uint) hash_link->file,(ulong) hash_link->diskpos, hash_link->requests));
KEYCACHE_DBUG_ASSERT(hash_link->requests == 0);
if ((*hash_link->prev= hash_link->next))
hash_link->next->prev= hash_link->prev;
hash_link->block= NULL;
if (keycache->waiting_for_hash_link.last_thread)
{
/* Signal that a free hash link has appeared */
struct st_my_thread_var *last_thread=
keycache->waiting_for_hash_link.last_thread;
struct st_my_thread_var *first_thread= last_thread->next;
struct st_my_thread_var *next_thread= first_thread;
KEYCACHE_PAGE *first_page= (KEYCACHE_PAGE *) (first_thread->keycache_link);
struct st_my_thread_var *thread;
hash_link->file= first_page->file;
hash_link->diskpos= first_page->filepos;
do
{
KEYCACHE_PAGE *page;
thread= next_thread;
page= (KEYCACHE_PAGE *) thread->keycache_link;
next_thread= thread->next;
/*
We notify about the event all threads that ask
for the same page as the first thread in the queue
*/
if (page->file == hash_link->file && page->filepos == hash_link->diskpos)
{
KEYCACHE_DBUG_PRINT("unlink_hash: signal",
("thread %ld", (ulong) thread->id));
keycache_pthread_cond_signal(&thread->suspend);
unlink_from_queue(&keycache->waiting_for_hash_link, thread);
}
}
while (thread != last_thread);
link_hash(&keycache->hash_root[KEYCACHE_HASH(hash_link->file,
hash_link->diskpos)],
hash_link);
return;
}
hash_link->next= keycache->free_hash_list;
keycache->free_hash_list= hash_link;
}
|
O0
|
c
|
unlink_hash:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
jmp 0xe50b2
jmp 0xe50b4
jmp 0xe50b6
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
movq %rax, (%rcx)
cmpq $0x0, %rax
je 0xe50e1
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x10(%rax)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x118(%rax)
je 0xe5223
movq -0x8(%rbp), %rax
movq 0x118(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq 0x88(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq 0xa8(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x18(%rax)
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x28(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq 0xa8(%rax), %rax
movq %rax, -0x40(%rbp)
movq -0x38(%rbp), %rax
movq 0x88(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x40(%rbp), %rax
movl (%rax), %eax
movq -0x10(%rbp), %rcx
cmpl 0x18(%rcx), %eax
jne 0xe51bd
movq -0x40(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
cmpq 0x20(%rcx), %rax
jne 0xe51bd
jmp 0xe519a
jmp 0xe519c
movq -0x38(%rbp), %rdi
addq $0x8, %rdi
callq 0xe55d0
movq -0x8(%rbp), %rdi
addq $0x118, %rdi # imm = 0x118
movq -0x38(%rbp), %rsi
callq 0xe5630
jmp 0xe51bf
movq -0x38(%rbp), %rax
cmpq -0x18(%rbp), %rax
jne 0xe5151
movq -0x8(%rbp), %rax
movq 0x80(%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x8(%rbp), %rcx
movl 0x18(%rcx), %ecx
xorl %edx, %edx
divq %rcx
movq -0x10(%rbp), %rcx
movslq 0x18(%rcx), %rcx
addq %rcx, %rax
movq -0x8(%rbp), %rcx
movl 0x164(%rcx), %ecx
xorl %edx, %edx
divq %rcx
movq -0x8(%rbp), %rcx
movl 0x38(%rcx), %ecx
subl $0x1, %ecx
movl %ecx, %ecx
andq %rcx, %rax
shlq $0x3, %rax
addq %rax, %rdi
movq -0x10(%rbp), %rsi
callq 0xe5580
jmp 0xe5244
movq -0x8(%rbp), %rax
movq 0x90(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x90(%rax)
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)
|
unlink_hash_0:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
jmp short $+2
loc_E50B2:
jmp short $+2
loc_E50B4:
jmp short $+2
loc_E50B6:
mov rax, [rbp+var_10]
mov rax, [rax]
mov rcx, [rbp+var_10]
mov rcx, [rcx+8]
mov [rcx], rax
cmp rax, 0
jz short loc_E50E1
mov rax, [rbp+var_10]
mov rcx, [rax+8]
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rax+8], rcx
loc_E50E1:
mov rax, [rbp+var_10]
mov qword ptr [rax+10h], 0
mov rax, [rbp+var_8]
cmp qword ptr [rax+118h], 0
jz loc_E5223
mov rax, [rbp+var_8]
mov rax, [rax+118h]
mov [rbp+var_18], rax
mov rax, [rbp+var_18]
mov rax, [rax+88h]
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
mov [rbp+var_28], rax
mov rax, [rbp+var_20]
mov rax, [rax+0A8h]
mov [rbp+var_30], rax
mov rax, [rbp+var_30]
mov ecx, [rax]
mov rax, [rbp+var_10]
mov [rax+18h], ecx
mov rax, [rbp+var_30]
mov rcx, [rax+8]
mov rax, [rbp+var_10]
mov [rax+20h], rcx
loc_E5151:
mov rax, [rbp+var_28]
mov [rbp+var_38], rax
mov rax, [rbp+var_38]
mov rax, [rax+0A8h]
mov [rbp+var_40], rax
mov rax, [rbp+var_38]
mov rax, [rax+88h]
mov [rbp+var_28], rax
mov rax, [rbp+var_40]
mov eax, [rax]
mov rcx, [rbp+var_10]
cmp eax, [rcx+18h]
jnz short loc_E51BD
mov rax, [rbp+var_40]
mov rax, [rax+8]
mov rcx, [rbp+var_10]
cmp rax, [rcx+20h]
jnz short loc_E51BD
jmp short $+2
loc_E519A:
jmp short $+2
loc_E519C:
mov rdi, [rbp+var_38]
add rdi, 8
call inline_mysql_cond_signal_2
mov rdi, [rbp+var_8]
add rdi, 118h
mov rsi, [rbp+var_38]
call unlink_from_queue
loc_E51BD:
jmp short $+2
loc_E51BF:
mov rax, [rbp+var_38]
cmp rax, [rbp+var_18]
jnz short loc_E5151
mov rax, [rbp+var_8]
mov rdi, [rax+80h]
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov rcx, [rbp+var_8]
mov ecx, [rcx+18h]
xor edx, edx
div rcx
mov rcx, [rbp+var_10]
movsxd rcx, dword ptr [rcx+18h]
add rax, rcx
mov rcx, [rbp+var_8]
mov ecx, [rcx+164h]
xor edx, edx
div rcx
mov rcx, [rbp+var_8]
mov ecx, [rcx+38h]
sub ecx, 1
mov ecx, ecx
and rax, rcx
shl rax, 3
add rdi, rax
mov rsi, [rbp+var_10]
call link_hash_0
jmp short loc_E5244
loc_E5223:
mov rax, [rbp+var_8]
mov rcx, [rax+90h]
mov rax, [rbp+var_10]
mov [rax], rcx
mov rcx, [rbp+var_10]
mov rax, [rbp+var_8]
mov [rax+90h], rcx
loc_E5244:
add rsp, 40h
pop rbp
retn
|
long long unlink_hash_0(long long a1, long long *a2)
{
long long v2; // rax
long long result; // rax
long long v4; // [rsp+0h] [rbp-40h]
long long v5; // [rsp+8h] [rbp-38h]
long long v6; // [rsp+10h] [rbp-30h]
long long v7; // [rsp+18h] [rbp-28h]
long long v8; // [rsp+28h] [rbp-18h]
v2 = *a2;
*(_QWORD *)a2[1] = *a2;
if ( v2 )
*(_QWORD *)(*a2 + 8) = a2[1];
a2[2] = 0LL;
if ( *(_QWORD *)(a1 + 280) )
{
v8 = *(_QWORD *)(a1 + 280);
v7 = *(_QWORD *)(v8 + 136);
v6 = *(_QWORD *)(v7 + 168);
*((_DWORD *)a2 + 6) = *(_DWORD *)v6;
a2[4] = *(_QWORD *)(v6 + 8);
do
{
v5 = v7;
v4 = *(_QWORD *)(v7 + 168);
v7 = *(_QWORD *)(v7 + 136);
if ( *(_DWORD *)v4 == *((_DWORD *)a2 + 6) && *(_QWORD *)(v4 + 8) == a2[4] )
{
inline_mysql_cond_signal_2(v5 + 8);
unlink_from_queue(a1 + 280, v5);
}
}
while ( v5 != v8 );
return link_hash_0(
8
* ((unsigned int)(*(_DWORD *)(a1 + 56) - 1) & ((*((int *)a2 + 6)
+ a2[4] / (unsigned long long)*(unsigned int *)(a1 + 24))
/ *(unsigned int *)(a1 + 356)))
+ *(_QWORD *)(a1 + 128),
a2);
}
else
{
*a2 = *(_QWORD *)(a1 + 144);
result = a1;
*(_QWORD *)(a1 + 144) = a2;
}
return result;
}
|
unlink_hash:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
JMP 0x001e50b2
LAB_001e50b2:
JMP 0x001e50b4
LAB_001e50b4:
JMP 0x001e50b6
LAB_001e50b6:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x8]
MOV qword ptr [RCX],RAX
CMP RAX,0x0
JZ 0x001e50e1
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RAX + 0x8],RCX
LAB_001e50e1:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x10],0x0
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x118],0x0
JZ 0x001e5223
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x118]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x88]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0xa8]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOV ECX,dword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x18],ECX
MOV RAX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x20],RCX
LAB_001e5151:
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0xa8]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX + 0x88]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x40]
MOV EAX,dword ptr [RAX]
MOV RCX,qword ptr [RBP + -0x10]
CMP EAX,dword ptr [RCX + 0x18]
JNZ 0x001e51bd
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RCX + 0x20]
JNZ 0x001e51bd
JMP 0x001e519a
LAB_001e519a:
JMP 0x001e519c
LAB_001e519c:
MOV RDI,qword ptr [RBP + -0x38]
ADD RDI,0x8
CALL 0x001e55d0
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x118
MOV RSI,qword ptr [RBP + -0x38]
CALL 0x001e5630
LAB_001e51bd:
JMP 0x001e51bf
LAB_001e51bf:
MOV RAX,qword ptr [RBP + -0x38]
CMP RAX,qword ptr [RBP + -0x18]
JNZ 0x001e5151
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX + 0x80]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x18]
XOR EDX,EDX
DIV RCX
MOV RCX,qword ptr [RBP + -0x10]
MOVSXD RCX,dword ptr [RCX + 0x18]
ADD RAX,RCX
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x164]
XOR EDX,EDX
DIV RCX
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x38]
SUB ECX,0x1
MOV ECX,ECX
AND RAX,RCX
SHL RAX,0x3
ADD RDI,RAX
MOV RSI,qword ptr [RBP + -0x10]
CALL 0x001e5580
JMP 0x001e5244
LAB_001e5223:
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x90]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x90],RCX
LAB_001e5244:
ADD RSP,0x40
POP RBP
RET
|
void unlink_hash(long param_1,long *param_2)
{
long lVar1;
int4 *puVar2;
long lVar3;
ulong uVar4;
bool bVar5;
long local_30;
lVar1 = *param_2;
*(long *)param_2[1] = lVar1;
if (lVar1 != 0) {
*(long *)(*param_2 + 8) = param_2[1];
}
param_2[2] = 0;
if (*(long *)(param_1 + 0x118) == 0) {
*param_2 = *(long *)(param_1 + 0x90);
*(long **)(param_1 + 0x90) = param_2;
}
else {
lVar1 = *(long *)(param_1 + 0x118);
local_30 = *(long *)(lVar1 + 0x88);
puVar2 = *(int4 **)(local_30 + 0xa8);
*(int4 *)(param_2 + 3) = *puVar2;
param_2[4] = *(long *)(puVar2 + 2);
do {
lVar3 = *(long *)(local_30 + 0x88);
if ((**(int **)(local_30 + 0xa8) == (int)param_2[3]) &&
(*(long *)(*(int **)(local_30 + 0xa8) + 2) == param_2[4])) {
inline_mysql_cond_signal(local_30 + 8);
unlink_from_queue(param_1 + 0x118,local_30);
}
bVar5 = local_30 != lVar1;
local_30 = lVar3;
} while (bVar5);
uVar4 = (ulong)param_2[4] / (ulong)*(uint *)(param_1 + 0x18) + (long)(int)param_2[3];
link_hash(*(long *)(param_1 + 0x80) +
(uVar4 / *(uint *)(param_1 + 0x164) & (ulong)(*(int *)(param_1 + 0x38) - 1)) * 8,
param_2,uVar4 % (ulong)*(uint *)(param_1 + 0x164));
}
return;
}
|
|
7,816 |
copy_uca_collation
|
eloqsql/mysys/charset.c
|
static void
copy_uca_collation(struct charset_info_st *to, CHARSET_INFO *from,
CHARSET_INFO *loaded)
{
to->cset= from->cset;
to->coll= from->coll;
/*
Single-level UCA collation have strnxfrm_multiple=8.
In case of a multi-level UCA collation we use strnxfrm_multiply=4.
That means MY_COLLATION_HANDLER::strnfrmlen() will request the caller
to allocate a buffer smaller size for each level, for performance purpose,
and to fit longer VARCHARs to @@max_sort_length.
This makes filesort produce non-precise order for some rare Unicode
characters that produce more than 4 weights (long expansions).
UCA requires 2 bytes per weight multiplied by the number of levels.
In case of a 2-level collation, each character requires 4*2=8 bytes.
Therefore, the longest VARCHAR that fits into the default @@max_sort_length
is 1024/8=VARCHAR(128). With strnxfrm_multiply==8, only VARCHAR(64)
would fit.
Note, the built-in collation utf8_thai_520_w2 also uses strnxfrm_multiply=4,
for the same purpose.
TODO: we could add a new LDML syntax to choose strxfrm_multiply value.
*/
to->strxfrm_multiply= loaded->levels_for_order > 1 ?
4 : from->strxfrm_multiply;
to->min_sort_char= from->min_sort_char;
to->max_sort_char= from->max_sort_char;
to->mbminlen= from->mbminlen;
to->mbmaxlen= from->mbmaxlen;
to->caseup_multiply= from->caseup_multiply;
to->casedn_multiply= from->casedn_multiply;
to->state|= MY_CS_AVAILABLE | MY_CS_LOADED |
MY_CS_STRNXFRM | MY_CS_UNICODE;
}
|
O0
|
c
|
copy_uca_collation:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0xb8(%rax), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0xb8(%rax)
movq -0x10(%rbp), %rax
movq 0xc0(%rax), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0xc0(%rax)
movq -0x18(%rbp), %rax
movzbl 0xb2(%rax), %eax
cmpl $0x1, %eax
jle 0xded96
movl $0x4, %eax
movl %eax, -0x1c(%rbp)
jmp 0xdeda3
movq -0x10(%rbp), %rax
movl 0x90(%rax), %eax
movl %eax, -0x1c(%rbp)
movl -0x1c(%rbp), %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x90(%rax)
movq -0x10(%rbp), %rax
movq 0xa0(%rax), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0xa0(%rax)
movq -0x10(%rbp), %rax
movq 0xa8(%rax), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0xa8(%rax)
movq -0x10(%rbp), %rax
movl 0x98(%rax), %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x98(%rax)
movq -0x10(%rbp), %rax
movl 0x9c(%rax), %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x9c(%rax)
movq -0x10(%rbp), %rax
movb 0x94(%rax), %cl
movq -0x8(%rbp), %rax
movb %cl, 0x94(%rax)
movq -0x10(%rbp), %rax
movb 0x95(%rax), %cl
movq -0x8(%rbp), %rax
movb %cl, 0x95(%rax)
movq -0x8(%rbp), %rax
movl 0xc(%rax), %ecx
orl $0x2c8, %ecx # imm = 0x2C8
movl %ecx, 0xc(%rax)
popq %rbp
retq
nop
|
copy_uca_collation:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov rax, [rbp+var_10]
mov rcx, [rax+0B8h]
mov rax, [rbp+var_8]
mov [rax+0B8h], rcx
mov rax, [rbp+var_10]
mov rcx, [rax+0C0h]
mov rax, [rbp+var_8]
mov [rax+0C0h], rcx
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax+0B2h]
cmp eax, 1
jle short loc_DED96
mov eax, 4
mov [rbp+var_1C], eax
jmp short loc_DEDA3
loc_DED96:
mov rax, [rbp+var_10]
mov eax, [rax+90h]
mov [rbp+var_1C], eax
loc_DEDA3:
mov ecx, [rbp+var_1C]
mov rax, [rbp+var_8]
mov [rax+90h], ecx
mov rax, [rbp+var_10]
mov rcx, [rax+0A0h]
mov rax, [rbp+var_8]
mov [rax+0A0h], rcx
mov rax, [rbp+var_10]
mov rcx, [rax+0A8h]
mov rax, [rbp+var_8]
mov [rax+0A8h], rcx
mov rax, [rbp+var_10]
mov ecx, [rax+98h]
mov rax, [rbp+var_8]
mov [rax+98h], ecx
mov rax, [rbp+var_10]
mov ecx, [rax+9Ch]
mov rax, [rbp+var_8]
mov [rax+9Ch], ecx
mov rax, [rbp+var_10]
mov cl, [rax+94h]
mov rax, [rbp+var_8]
mov [rax+94h], cl
mov rax, [rbp+var_10]
mov cl, [rax+95h]
mov rax, [rbp+var_8]
mov [rax+95h], cl
mov rax, [rbp+var_8]
mov ecx, [rax+0Ch]
or ecx, 2C8h
mov [rax+0Ch], ecx
pop rbp
retn
|
long long copy_uca_collation(long long a1, long long a2, long long a3)
{
long long result; // rax
int v4; // [rsp+0h] [rbp-1Ch]
*(_QWORD *)(a1 + 184) = *(_QWORD *)(a2 + 184);
*(_QWORD *)(a1 + 192) = *(_QWORD *)(a2 + 192);
if ( *(unsigned __int8 *)(a3 + 178) <= 1u )
v4 = *(_DWORD *)(a2 + 144);
else
v4 = 4;
*(_DWORD *)(a1 + 144) = v4;
*(_QWORD *)(a1 + 160) = *(_QWORD *)(a2 + 160);
*(_QWORD *)(a1 + 168) = *(_QWORD *)(a2 + 168);
*(_DWORD *)(a1 + 152) = *(_DWORD *)(a2 + 152);
*(_DWORD *)(a1 + 156) = *(_DWORD *)(a2 + 156);
*(_BYTE *)(a1 + 148) = *(_BYTE *)(a2 + 148);
*(_BYTE *)(a1 + 149) = *(_BYTE *)(a2 + 149);
result = a1;
*(_DWORD *)(a1 + 12) |= 0x2C8u;
return result;
}
|
copy_uca_collation:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0xb8],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0xc0]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0xc0],RCX
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0xb2]
CMP EAX,0x1
JLE 0x001ded96
MOV EAX,0x4
MOV dword ptr [RBP + -0x1c],EAX
JMP 0x001deda3
LAB_001ded96:
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x90]
MOV dword ptr [RBP + -0x1c],EAX
LAB_001deda3:
MOV ECX,dword ptr [RBP + -0x1c]
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x90],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0xa0]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0xa0],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0xa8]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0xa8],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x98]
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x98],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x9c]
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x9c],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV CL,byte ptr [RAX + 0x94]
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x94],CL
MOV RAX,qword ptr [RBP + -0x10]
MOV CL,byte ptr [RAX + 0x95]
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x95],CL
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0xc]
OR ECX,0x2c8
MOV dword ptr [RAX + 0xc],ECX
POP RBP
RET
|
void copy_uca_collation(long param_1,long param_2,long param_3)
{
int4 local_24;
*(int8 *)(param_1 + 0xb8) = *(int8 *)(param_2 + 0xb8);
*(int8 *)(param_1 + 0xc0) = *(int8 *)(param_2 + 0xc0);
if (*(byte *)(param_3 + 0xb2) < 2) {
local_24 = *(int4 *)(param_2 + 0x90);
}
else {
local_24 = 4;
}
*(int4 *)(param_1 + 0x90) = local_24;
*(int8 *)(param_1 + 0xa0) = *(int8 *)(param_2 + 0xa0);
*(int8 *)(param_1 + 0xa8) = *(int8 *)(param_2 + 0xa8);
*(int4 *)(param_1 + 0x98) = *(int4 *)(param_2 + 0x98);
*(int4 *)(param_1 + 0x9c) = *(int4 *)(param_2 + 0x9c);
*(int1 *)(param_1 + 0x94) = *(int1 *)(param_2 + 0x94);
*(int1 *)(param_1 + 0x95) = *(int1 *)(param_2 + 0x95);
*(uint *)(param_1 + 0xc) = *(uint *)(param_1 + 0xc) | 0x2c8;
return;
}
|
|
7,817 |
check_eol_junk(char const*)
|
eloqsql/client/mysqltest.cc
|
void check_eol_junk(const char *eol)
{
const char *p= eol;
DBUG_ENTER("check_eol_junk");
DBUG_PRINT("enter", ("eol: %s", eol));
/* Skip past all spacing chars and comments */
while (*p && (my_isspace(charset_info, *p) || *p == '#' || *p == '\n'))
{
/* Skip past comments started with # and ended with newline */
if (*p && *p == '#')
{
p++;
while (*p && *p != '\n')
p++;
}
/* Check this line */
if (*p && *p == '\n')
check_eol_junk_line(p);
if (*p)
p++;
}
check_eol_junk_line(p);
DBUG_VOID_RETURN;
}
|
O3
|
cpp
|
check_eol_junk(char const*):
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movb (%rdi), %cl
testb %cl, %cl
je 0x6a87d
movq 0x36fb5d(%rip), %rax # 0x3da388
movq 0x40(%rax), %rsi
movzbl %cl, %edx
testb $0x8, 0x1(%rsi,%rdx)
jne 0x6a845
cmpb $0xa, %cl
je 0x6a85f
cmpl $0x23, %edx
je 0x6a84a
jmp 0x6a87d
cmpb $0x23, %cl
jne 0x6a85a
movzbl 0x1(%rbx), %ecx
incq %rbx
cmpl $0xa, %ecx
je 0x6a85a
testl %ecx, %ecx
jne 0x6a84a
cmpb $0xa, %cl
jne 0x6a870
movq %rbx, %rdi
callq 0x680be
movq 0x36fb1a(%rip), %rax # 0x3da388
movb (%rbx), %cl
cmpb $0x1, %cl
sbbq $-0x1, %rbx
movb (%rbx), %cl
testb %cl, %cl
jne 0x6a82b
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x680be
|
_Z14check_eol_junkPKc:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdi
mov cl, [rdi]
test cl, cl
jz short loc_6A87D
mov rax, cs:_ZL12charset_info; charset_info
loc_6A82B:
mov rsi, [rax+40h]
movzx edx, cl
test byte ptr [rsi+rdx+1], 8
jnz short loc_6A845
cmp cl, 0Ah
jz short loc_6A85F
cmp edx, 23h ; '#'
jz short loc_6A84A
jmp short loc_6A87D
loc_6A845:
cmp cl, 23h ; '#'
jnz short loc_6A85A
loc_6A84A:
movzx ecx, byte ptr [rbx+1]
inc rbx
cmp ecx, 0Ah
jz short loc_6A85A
test ecx, ecx
jnz short loc_6A84A
loc_6A85A:
cmp cl, 0Ah
jnz short loc_6A870
loc_6A85F:
mov rdi, rbx; char *
call _Z19check_eol_junk_linePKc; check_eol_junk_line(char const*)
mov rax, cs:_ZL12charset_info; charset_info
mov cl, [rbx]
loc_6A870:
cmp cl, 1
sbb rbx, 0FFFFFFFFFFFFFFFFh
mov cl, [rbx]
test cl, cl
jnz short loc_6A82B
loc_6A87D:
mov rdi, rbx; char *
add rsp, 8
pop rbx
pop rbp
jmp _Z19check_eol_junk_linePKc; check_eol_junk_line(char const*)
|
void check_eol_junk(
char *a1,
long long a2,
long long a3,
long long a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
double a9,
double a10,
__m128 a11,
__m128 a12)
{
char *v12; // rbx
_QWORD *v13; // rax
v12 = a1;
LOBYTE(a4) = *a1;
if ( *a1 )
{
v13 = charset_info;
do
{
a2 = v13[8];
a3 = (unsigned __int8)a4;
if ( (*(_BYTE *)(a2 + (unsigned __int8)a4 + 1) & 8) != 0 )
{
if ( (_BYTE)a4 != 35 )
goto LABEL_10;
}
else
{
if ( (_BYTE)a4 == 10 )
goto LABEL_11;
if ( (unsigned __int8)a4 != 35 )
break;
}
do
a4 = (unsigned __int8)*++v12;
while ( (_DWORD)a4 != 10 && (_DWORD)a4 );
LABEL_10:
if ( (_BYTE)a4 == 10 )
{
LABEL_11:
check_eol_junk_line(v12, a5, a6, a7, a8, a9, a10, a11, a12, a2, a3, a4);
v13 = charset_info;
LOBYTE(a4) = *v12;
}
v12 += -((_BYTE)a4 == 0) + 1;
LOBYTE(a4) = *v12;
}
while ( *v12 );
}
check_eol_junk_line(v12, a5, a6, a7, a8, a9, a10, a11, a12, a2, a3, a4);
}
|
check_eol_junk:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV CL,byte ptr [RDI]
TEST CL,CL
JZ 0x0016a87d
MOV RAX,qword ptr [0x004da388]
LAB_0016a82b:
MOV RSI,qword ptr [RAX + 0x40]
MOVZX EDX,CL
TEST byte ptr [RSI + RDX*0x1 + 0x1],0x8
JNZ 0x0016a845
CMP CL,0xa
JZ 0x0016a85f
CMP EDX,0x23
JZ 0x0016a84a
JMP 0x0016a87d
LAB_0016a845:
CMP CL,0x23
JNZ 0x0016a85a
LAB_0016a84a:
MOVZX ECX,byte ptr [RBX + 0x1]
INC RBX
CMP ECX,0xa
JZ 0x0016a85a
TEST ECX,ECX
JNZ 0x0016a84a
LAB_0016a85a:
CMP CL,0xa
JNZ 0x0016a870
LAB_0016a85f:
MOV RDI,RBX
CALL 0x001680be
MOV RAX,qword ptr [0x004da388]
MOV CL,byte ptr [RBX]
LAB_0016a870:
CMP CL,0x1
SBB RBX,-0x1
MOV CL,byte ptr [RBX]
TEST CL,CL
JNZ 0x0016a82b
LAB_0016a87d:
MOV RDI,RBX
ADD RSP,0x8
POP RBX
POP RBP
JMP 0x001680be
|
/* check_eol_junk(char const*) */
void check_eol_junk(char *param_1)
{
int *puVar1;
byte bVar2;
bVar2 = *param_1;
puVar1 = charset_info;
do {
if (bVar2 == 0) {
LAB_0016a87d:
check_eol_junk_line(param_1);
return;
}
if ((*(byte *)(*(long *)(puVar1 + 0x40) + 1 + (ulong)bVar2) & 8) == 0) {
if (bVar2 != 10) {
if (bVar2 == 0x23) {
LAB_0016a84a:
do {
bVar2 = ((byte *)param_1)[1];
param_1 = (char *)((byte *)param_1 + 1);
if (bVar2 == 10) break;
} while (bVar2 != 0);
goto LAB_0016a85a;
}
goto LAB_0016a87d;
}
LAB_0016a85f:
check_eol_junk_line(param_1);
bVar2 = *param_1;
puVar1 = charset_info;
}
else {
if (bVar2 == 0x23) goto LAB_0016a84a;
LAB_0016a85a:
if (bVar2 == 10) goto LAB_0016a85f;
}
param_1 = (char *)((byte *)param_1 + (bVar2 != 0));
bVar2 = *param_1;
} while( true );
}
|
|
7,818 |
LefDefParser::lefwMacroObsLayerWidth(double)
|
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp
|
int
lefwMacroObsLayerWidth(double width)
{
if (!lefwFile)
return LEFW_UNINITIALIZED;
if (!lefwDidInit)
return LEFW_BAD_ORDER;
if (!lefwIsMacroObsLayer)
return LEFW_BAD_ORDER;
if (lefwWriteEncrypt)
encPrint(lefwFile, (char*) " WIDTH %.11g ;\n", width);
else
fprintf(lefwFile, " WIDTH %.11g ;\n", width);
lefwLines++;
lefwIsMacroObsLayer = 1;
return LEFW_OK;
}
|
O3
|
cpp
|
LefDefParser::lefwMacroObsLayerWidth(double):
pushq %rbx
leaq 0xe0eb(%rip), %rax # 0x24e00
movq (%rax), %rdi
testq %rdi, %rdi
je 0x16d53
leaq 0xe330(%rip), %rax # 0x25054
cmpl $0x0, (%rax)
movl $0x2, %eax
je 0x16d79
leaq 0xe367(%rip), %rbx # 0x2509c
cmpl $0x0, (%rbx)
je 0x16d79
cmpb $0x1, 0xe3ab(%rip) # 0x250ec
jne 0x16d5a
leaq 0x50e4(%rip), %rsi # 0x1be2e
movb $0x1, %al
callq 0x18c35
jmp 0x16d68
movl $0x1, %eax
jmp 0x16d79
leaq 0x50cd(%rip), %rsi # 0x1be2e
movb $0x1, %al
callq 0x10f0
leaq 0xe2dd(%rip), %rax # 0x2504c
incl (%rax)
movl $0x1, (%rbx)
xorl %eax, %eax
popq %rbx
retq
|
_ZN12LefDefParser22lefwMacroObsLayerWidthEd:
push rbx
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
test rdi, rdi
jz short loc_16D53
lea rax, _ZN12LefDefParser11lefwDidInitE; LefDefParser::lefwDidInit
cmp dword ptr [rax], 0
mov eax, 2
jz short loc_16D79
lea rbx, _ZN12LefDefParser19lefwIsMacroObsLayerE; LefDefParser::lefwIsMacroObsLayer
cmp dword ptr [rbx], 0
jz short loc_16D79
cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 1; LefDefParser::lefwWriteEncrypt
jnz short loc_16D5A
lea rsi, aWidth11g+3; " WIDTH %.11g ;\n"
mov al, 1
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
jmp short loc_16D68
loc_16D53:
mov eax, 1
jmp short loc_16D79
loc_16D5A:
lea rsi, aWidth11g+3; " WIDTH %.11g ;\n"
mov al, 1
call _fprintf
loc_16D68:
lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines
inc dword ptr [rax]
mov dword ptr [rbx], 1
xor eax, eax
loc_16D79:
pop rbx
retn
|
long long LefDefParser::lefwMacroObsLayerWidth(
LefDefParser *this,
double a2,
long long a3,
int a4,
int a5,
int a6,
int a7)
{
long long result; // rax
if ( !*(_QWORD *)&LefDefParser::lefwFile )
return 1LL;
result = 2LL;
if ( LefDefParser::lefwDidInit && LefDefParser::lefwIsMacroObsLayer )
{
if ( LefDefParser::lefwWriteEncrypt == 1 )
LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)" WIDTH %.11g ;\n", a4, a5, a6, a7);
else
fprintf(*(_QWORD *)&LefDefParser::lefwFile, " WIDTH %.11g ;\n", a2);
++LefDefParser::lefwLines;
LefDefParser::lefwIsMacroObsLayer = 1;
return 0LL;
}
return result;
}
|
lefwMacroObsLayerWidth:
PUSH RBX
LEA RAX,[0x124e00]
MOV RDI,qword ptr [RAX]
TEST RDI,RDI
JZ 0x00116d53
LEA RAX,[0x125054]
CMP dword ptr [RAX],0x0
MOV EAX,0x2
JZ 0x00116d79
LEA RBX,[0x12509c]
CMP dword ptr [RBX],0x0
JZ 0x00116d79
CMP byte ptr [0x001250ec],0x1
JNZ 0x00116d5a
LEA RSI,[0x11be2e]
MOV AL,0x1
CALL 0x00118c35
JMP 0x00116d68
LAB_00116d53:
MOV EAX,0x1
JMP 0x00116d79
LAB_00116d5a:
LEA RSI,[0x11be2e]
MOV AL,0x1
CALL 0x001010f0
LAB_00116d68:
LEA RAX,[0x12504c]
INC dword ptr [RAX]
MOV dword ptr [RBX],0x1
XOR EAX,EAX
LAB_00116d79:
POP RBX
RET
|
/* LefDefParser::lefwMacroObsLayerWidth(double) */
int8 LefDefParser::lefwMacroObsLayerWidth(double param_1)
{
int8 uVar1;
if (lefwFile == (_IO_FILE *)0x0) {
uVar1 = 1;
}
else {
uVar1 = 2;
if ((lefwDidInit != 0) && (lefwIsMacroObsLayer != 0)) {
if (lefwWriteEncrypt == '\x01') {
encPrint(lefwFile," WIDTH %.11g ;\n");
}
else {
fprintf(lefwFile," WIDTH %.11g ;\n");
}
lefwLines = lefwLines + 1;
lefwIsMacroObsLayer = 1;
uVar1 = 0;
}
}
return uVar1;
}
|
|
7,819 |
translog_mark_file_finished
|
eloqsql/storage/maria/ma_loghandler.c
|
static void translog_mark_file_finished(uint32 file)
{
int i;
struct st_file_counter *UNINIT_VAR(fc_ptr);
DBUG_ENTER("translog_mark_file_finished");
DBUG_PRINT("enter", ("file: %lu", (ulong) file));
mysql_mutex_lock(&log_descriptor.unfinished_files_lock);
DBUG_ASSERT(log_descriptor.unfinished_files.elements > 0);
for (i= 0;
i < (int) log_descriptor.unfinished_files.elements;
i++)
{
fc_ptr= dynamic_element(&log_descriptor.unfinished_files,
i, struct st_file_counter *);
if (fc_ptr->file == file)
{
break;
}
}
DBUG_ASSERT(i < (int) log_descriptor.unfinished_files.elements);
if (! --fc_ptr->counter)
delete_dynamic_element(&log_descriptor.unfinished_files, i);
mysql_mutex_unlock(&log_descriptor.unfinished_files_lock);
DBUG_VOID_RETURN;
}
|
O3
|
c
|
translog_mark_file_finished:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %edi, %ebx
cmpq $0x0, 0xbafa3a(%rip) # 0xbff608
jne 0x4fc32
leaq 0xbaf9f1(%rip), %rdi # 0xbff5c8
callq 0x29220
movl 0xbafa36(%rip), %esi # 0xbff618
movq 0xbafa27(%rip), %rax # 0xbff610
leal -0x1(%rsi), %edx
xorl %ecx, %ecx
cmpl %ebx, (%rax,%rcx,8)
je 0x4fc00
incq %rcx
cmpq %rcx, %rsi
jne 0x4fbee
movq %rdx, %rcx
jmp 0x4fc02
movl %ecx, %esi
decl 0x4(%rax,%rcx,8)
jne 0x4fc14
leaq 0xbafa01(%rip), %rdi # 0xbff610
callq 0x91999
movq 0xbaf9ed(%rip), %rdi # 0xbff608
testq %rdi, %rdi
jne 0x4fc39
leaq 0xbaf9a1(%rip), %rdi # 0xbff5c8
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x291e0
callq 0x2cece
jmp 0x4fbdc
leaq 0x3363d0(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x4fc20
|
translog_mark_file_finished:
push rbp
mov rbp, rsp
push rbx
push rax
mov ebx, edi
cmp cs:qword_BFF608, 0
jnz short loc_4FC32
lea rdi, unk_BFF5C8
call _pthread_mutex_lock
loc_4FBDC:
mov esi, cs:dword_BFF618
mov rax, cs:qword_BFF610
lea edx, [rsi-1]
xor ecx, ecx
loc_4FBEE:
cmp [rax+rcx*8], ebx
jz short loc_4FC00
inc rcx
cmp rsi, rcx
jnz short loc_4FBEE
mov rcx, rdx
jmp short loc_4FC02
loc_4FC00:
mov esi, ecx
loc_4FC02:
dec dword ptr [rax+rcx*8+4]
jnz short loc_4FC14
lea rdi, qword_BFF610
call delete_dynamic_element
loc_4FC14:
mov rdi, cs:qword_BFF608
test rdi, rdi
jnz short loc_4FC39
loc_4FC20:
lea rdi, unk_BFF5C8
add rsp, 8
pop rbx
pop rbp
jmp _pthread_mutex_unlock
loc_4FC32:
call translog_mark_file_finished_cold_1
jmp short loc_4FBDC
loc_4FC39:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp short loc_4FC20
|
long long translog_mark_file_finished(long long a1)
{
long long v1; // rsi
long long v2; // rdx
long long v3; // rcx
if ( qword_BFF608 )
translog_mark_file_finished_cold_1(a1);
else
pthread_mutex_lock(&unk_BFF5C8);
v1 = (unsigned int)dword_BFF618;
v2 = (unsigned int)(dword_BFF618 - 1);
v3 = 0LL;
while ( *(_DWORD *)(qword_BFF610 + 8 * v3) != (_DWORD)a1 )
{
if ( dword_BFF618 == ++v3 )
{
v3 = (unsigned int)(dword_BFF618 - 1);
goto LABEL_8;
}
}
v1 = (unsigned int)v3;
LABEL_8:
if ( (*(_DWORD *)(qword_BFF610 + 8 * v3 + 4))-- == 1 )
delete_dynamic_element(&qword_BFF610, v1, v2);
if ( qword_BFF608 )
((void ( *)(long long, long long, long long))PSI_server[44])(qword_BFF608, v1, v2);
return pthread_mutex_unlock(&unk_BFF5C8);
}
|
translog_mark_file_finished:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV EBX,EDI
CMP qword ptr [0x00cff608],0x0
JNZ 0x0014fc32
LEA RDI,[0xcff5c8]
CALL 0x00129220
LAB_0014fbdc:
MOV ESI,dword ptr [0x00cff618]
MOV RAX,qword ptr [0x00cff610]
LEA EDX,[RSI + -0x1]
XOR ECX,ECX
LAB_0014fbee:
CMP dword ptr [RAX + RCX*0x8],EBX
JZ 0x0014fc00
INC RCX
CMP RSI,RCX
JNZ 0x0014fbee
MOV RCX,RDX
JMP 0x0014fc02
LAB_0014fc00:
MOV ESI,ECX
LAB_0014fc02:
DEC dword ptr [RAX + RCX*0x8 + 0x4]
JNZ 0x0014fc14
LEA RDI,[0xcff610]
CALL 0x00191999
LAB_0014fc14:
MOV RDI,qword ptr [0x00cff608]
TEST RDI,RDI
JNZ 0x0014fc39
LAB_0014fc20:
LEA RDI,[0xcff5c8]
ADD RSP,0x8
POP RBX
POP RBP
JMP 0x001291e0
LAB_0014fc32:
CALL 0x0012cece
JMP 0x0014fbdc
LAB_0014fc39:
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x0014fc20
|
void translog_mark_file_finished(int param_1)
{
int *piVar1;
ulong uVar2;
ulong uVar3;
ulong uVar4;
if (DAT_00cff608 == 0) {
pthread_mutex_lock((pthread_mutex_t *)&DAT_00cff5c8);
}
else {
translog_mark_file_finished_cold_1();
}
uVar4 = (ulong)DAT_00cff618;
uVar3 = (ulong)(DAT_00cff618 - 1);
uVar2 = 0;
do {
if (*(int *)(DAT_00cff610 + uVar2 * 8) == param_1) {
uVar4 = uVar2 & 0xffffffff;
uVar3 = uVar2;
break;
}
uVar2 = uVar2 + 1;
} while (uVar4 != uVar2);
piVar1 = (int *)(DAT_00cff610 + 4 + uVar3 * 8);
*piVar1 = *piVar1 + -1;
if (*piVar1 == 0) {
delete_dynamic_element(&DAT_00cff610,uVar4);
}
if (DAT_00cff608 != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock((pthread_mutex_t *)&DAT_00cff5c8);
return;
}
|
|
7,820 |
google::protobuf::MessageLite::SerializePartialToCodedStream(google::protobuf::io::CodedOutputStream*) const
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc
|
bool MessageLite::SerializePartialToCodedStream(
io::CodedOutputStream* output) const {
const size_t size = ByteSizeLong(); // Force size to be cached.
if (size > INT_MAX) {
GOOGLE_LOG(ERROR) << GetTypeName()
<< " exceeded maximum protobuf size of 2GB: " << size;
return false;
}
int original_byte_count = output->ByteCount();
SerializeWithCachedSizes(output);
if (output->HadError()) {
return false;
}
int final_byte_count = output->ByteCount();
if (final_byte_count - original_byte_count != static_cast<int64_t>(size)) {
ByteSizeConsistencyError(size, ByteSizeLong(),
final_byte_count - original_byte_count, *this);
}
return true;
}
|
O3
|
cpp
|
google::protobuf::MessageLite::SerializePartialToCodedStream(google::protobuf::io::CodedOutputStream*) const:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, %r12
movq %rdi, %r14
movq (%rdi), %rax
callq *0x40(%rax)
movq %rax, %r15
testq $-0x80000000, %rax # imm = 0x80000000
je 0x9e0b6
leaq 0x1ff1b(%rip), %rdx # 0xbdf55
leaq 0x30(%rsp), %rdi
movl $0x2, %esi
movl $0x174, %ecx # imm = 0x174
callq 0x169ca
movq (%r14), %rax
leaq 0x10(%rsp), %rdi
movq %r14, %rsi
callq *0x10(%rax)
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x164da
leaq 0x1ff52(%rip), %rsi # 0xbdfc4
movq %rax, %rdi
callq 0x164c8
movq %rax, %rdi
movq %r15, %rsi
callq 0x168b8
leaq 0xf(%rsp), %rdi
movq %rax, %rsi
callq 0x165a2
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x9e0a5
callq 0xf330
leaq 0x30(%rsp), %rdi
callq 0x169e8
xorl %ebx, %ebx
jmp 0x9e28f
movq 0x40(%r12), %rsi
movq %r12, %rdi
callq 0x15a34
movq %rax, %r13
movq 0x40(%r12), %rsi
movq 0x48(%r12), %rbp
movq (%r14), %rax
movq %r14, %rdi
movq %r12, %rdx
callq *0x60(%rax)
movq %rax, 0x40(%r12)
movq %r12, %rdi
movq %rax, %rsi
callq 0x15ba0
movq %rax, 0x40(%r12)
movb 0x38(%r12), %bl
testb %bl, %bl
jne 0x9e28c
movq %r12, %rdi
movq %rax, %rsi
callq 0x15a34
addl 0x48(%r12), %r13d
addl %eax, %ebp
subl %r13d, %ebp
movslq %ebp, %rax
cmpq %rax, %r15
je 0x9e28c
movq (%r14), %rax
movq %r14, %rdi
callq *0x40(%rax)
cmpq %rax, %r15
je 0x9e1b5
leaq 0x1fe1d(%rip), %rdx # 0xbdf55
leaq 0x30(%rsp), %r15
movq %r15, %rdi
movl $0x3, %esi
movl $0x53, %ecx
callq 0x169ca
leaq 0x1fedb(%rip), %rsi # 0xbe031
movq %r15, %rdi
callq 0x164c8
movq %rax, %r15
movq (%r14), %rax
leaq 0x10(%rsp), %rdi
movq %r14, %rsi
callq *0x10(%rax)
leaq 0x10(%rsp), %rsi
movq %r15, %rdi
callq 0x164da
leaq 0x1ff02(%rip), %rsi # 0xbe085
movq %rax, %rdi
callq 0x164c8
leaq 0xf(%rsp), %rdi
movq %rax, %rsi
callq 0x165a2
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x9e1ab
callq 0xf330
leaq 0x30(%rsp), %rdi
callq 0x169e8
leaq 0x1fd99(%rip), %rdx # 0xbdf55
leaq 0x30(%rsp), %r15
movq %r15, %rdi
movl $0x3, %esi
movl $0x56, %ecx
callq 0x169ca
leaq 0x1fedc(%rip), %rsi # 0xbe0b6
movq %r15, %rdi
callq 0x164c8
leaq 0x1ff23(%rip), %rsi # 0xbe10c
movq %rax, %rdi
callq 0x164c8
movq %rax, %r15
movq (%r14), %rax
leaq 0x10(%rsp), %rdi
movq %r14, %rsi
callq *0x10(%rax)
leaq 0x10(%rsp), %rsi
movq %r15, %rdi
callq 0x164da
leaq 0x182c8(%rip), %rsi # 0xb64de
movq %rax, %rdi
callq 0x164c8
leaq 0xf(%rsp), %rdi
movq %rax, %rsi
callq 0x165a2
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x9e23e
callq 0xf330
leaq 0x30(%rsp), %rdi
callq 0x169e8
leaq 0x1fd06(%rip), %rdx # 0xbdf55
leaq 0x30(%rsp), %r14
movq %r14, %rdi
movl $0x3, %esi
movl $0x5b, %ecx
callq 0x169ca
leaq 0x1ff3a(%rip), %rsi # 0xbe1a7
movq %r14, %rdi
callq 0x164c8
leaq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x165a2
leaq 0x30(%rsp), %rdi
callq 0x169e8
xorb $0x1, %bl
movl %ebx, %eax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x9e2bb
jmp 0x9e2b6
jmp 0x9e2b6
jmp 0x9e2b6
jmp 0x9e2b6
jmp 0x9e2bb
jmp 0x9e2b6
jmp 0x9e2bb
jmp 0x9e2bb
jmp 0x9e2b6
jmp 0x9e2bb
movq %rax, %rbx
jmp 0x9e2d1
movq %rax, %rbx
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x9e2d1
callq 0xf330
leaq 0x30(%rsp), %rdi
callq 0x169e8
movq %rbx, %rdi
callq 0xf570
nop
|
_ZNK6google8protobuf11MessageLite29SerializePartialToCodedStreamEPNS0_2io17CodedOutputStreamE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 68h
mov r12, rsi
mov r14, rdi
mov rax, [rdi]
call qword ptr [rax+40h]
mov r15, rax
test rax, 0FFFFFFFF80000000h
jz loc_9E0B6
lea rdx, aWorkspaceLlm4b_25; "/workspace/llm4binary/github2025/aimrt_"...
lea rdi, [rsp+98h+var_68]
mov esi, 2
mov ecx, 174h
call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int)
mov rax, [r14]
lea rdi, [rsp+98h+var_88]
mov rsi, r14
call qword ptr [rax+10h]
lea rdi, [rsp+98h+var_68]
lea rsi, [rsp+98h+var_88]
call _ZN6google8protobuf8internal10LogMessagelsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::internal::LogMessage::operator<<(std::string const&)
lea rsi, aExceededMaximu; " exceeded maximum protobuf size of 2GB:"...
mov rdi, rax
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
mov rdi, rax
mov rsi, r15
call _ZN6google8protobuf8internal10LogMessagelsEm; google::protobuf::internal::LogMessage::operator<<(ulong)
lea rdi, [rsp+98h+var_89]
mov rsi, rax
call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &)
lea rax, [rsp+98h+var_78]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_9E0A5
call __ZdlPv; operator delete(void *)
loc_9E0A5:
lea rdi, [rsp+98h+var_68]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
xor ebx, ebx
jmp loc_9E28F
loc_9E0B6:
mov rsi, [r12+40h]; unsigned __int8 *
mov rdi, r12; this
call _ZNK6google8protobuf2io19EpsCopyOutputStream9ByteCountEPh; google::protobuf::io::EpsCopyOutputStream::ByteCount(uchar *)
mov r13, rax
mov rsi, [r12+40h]
mov rbp, [r12+48h]
mov rax, [r14]
mov rdi, r14
mov rdx, r12
call qword ptr [rax+60h]
mov [r12+40h], rax
mov rdi, r12; this
mov rsi, rax; unsigned __int8 *
call _ZN6google8protobuf2io19EpsCopyOutputStream19FlushAndResetBufferEPh; google::protobuf::io::EpsCopyOutputStream::FlushAndResetBuffer(uchar *)
mov [r12+40h], rax
mov bl, [r12+38h]
test bl, bl
jnz loc_9E28C
mov rdi, r12; this
mov rsi, rax; unsigned __int8 *
call _ZNK6google8protobuf2io19EpsCopyOutputStream9ByteCountEPh; google::protobuf::io::EpsCopyOutputStream::ByteCount(uchar *)
add r13d, [r12+48h]
add ebp, eax
sub ebp, r13d
movsxd rax, ebp
cmp r15, rax
jz loc_9E28C
mov rax, [r14]
mov rdi, r14
call qword ptr [rax+40h]
cmp r15, rax
jz loc_9E1B5
lea rdx, aWorkspaceLlm4b_25; "/workspace/llm4binary/github2025/aimrt_"...
lea r15, [rsp+98h+var_68]
mov rdi, r15
mov esi, 3
mov ecx, 53h ; 'S'
call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int)
lea rsi, aCheckFailedByt; "CHECK failed: (byte_size_before_seriali"...
mov rdi, r15
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
mov r15, rax
mov rax, [r14]
lea rdi, [rsp+98h+var_88]
mov rsi, r14
call qword ptr [rax+10h]
lea rsi, [rsp+98h+var_88]
mov rdi, r15
call _ZN6google8protobuf8internal10LogMessagelsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::internal::LogMessage::operator<<(std::string const&)
lea rsi, aWasModifiedCon; " was modified concurrently during seria"...
mov rdi, rax
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
lea rdi, [rsp+98h+var_89]
mov rsi, rax
call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &)
lea rax, [rsp+98h+var_78]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_9E1AB
call __ZdlPv; operator delete(void *)
loc_9E1AB:
lea rdi, [rsp+98h+var_68]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
loc_9E1B5:
lea rdx, aWorkspaceLlm4b_25; "/workspace/llm4binary/github2025/aimrt_"...
lea r15, [rsp+98h+var_68]
mov rdi, r15
mov esi, 3
mov ecx, 56h ; 'V'
call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int)
lea rsi, aCheckFailedByt_0; "CHECK failed: (bytes_produced_by_serial"...
mov rdi, r15
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
lea rsi, aByteSizeCalcul; "Byte size calculation and serialization"...
mov rdi, rax
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
mov r15, rax
mov rax, [r14]
lea rdi, [rsp+98h+var_88]
mov rsi, r14
call qword ptr [rax+10h]
lea rsi, [rsp+98h+var_88]
mov rdi, r15
call _ZN6google8protobuf8internal10LogMessagelsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::internal::LogMessage::operator<<(std::string const&)
lea rsi, aWhichIsNotDefi+77h; "."
mov rdi, rax
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
lea rdi, [rsp+98h+var_89]
mov rsi, rax
call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &)
lea rax, [rsp+98h+var_78]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_9E23E
call __ZdlPv; operator delete(void *)
loc_9E23E:
lea rdi, [rsp+98h+var_68]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
lea rdx, aWorkspaceLlm4b_25; "/workspace/llm4binary/github2025/aimrt_"...
lea r14, [rsp+98h+var_68]
mov rdi, r14
mov esi, 3
mov ecx, 5Bh ; '['
call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int)
lea rsi, aThisShouldnTBe; "This shouldn't be called if all the siz"...
mov rdi, r14
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
lea rdi, [rsp+98h+var_88]
mov rsi, rax
call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &)
lea rdi, [rsp+98h+var_68]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
loc_9E28C:
xor bl, 1
loc_9E28F:
mov eax, ebx
add rsp, 68h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_9E2BB
jmp short loc_9E2B6
jmp short loc_9E2B6
jmp short loc_9E2B6
jmp short loc_9E2B6
jmp short loc_9E2BB
jmp short loc_9E2B6
jmp short loc_9E2BB
jmp short loc_9E2BB
jmp short loc_9E2B6
jmp short loc_9E2BB
loc_9E2B6:
mov rbx, rax
jmp short loc_9E2D1
loc_9E2BB:
mov rbx, rax
lea rax, [rsp+arg_18]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_9E2D1
call __ZdlPv; operator delete(void *)
loc_9E2D1:
lea rdi, [rsp+arg_28]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
mov rdi, rbx
call __Unwind_Resume
|
long long google::protobuf::MessageLite::SerializePartialToCodedStream(
google::protobuf::MessageLite *this,
unsigned __int8 **a2)
{
unsigned int v2; // ebx
google::protobuf *v3; // r15
long long v4; // rax
long long v5; // rax
char *v6; // rdx
google::protobuf::internal::LogMessage *v7; // rax
int v8; // r13d
unsigned __int8 *v9; // rbp
unsigned __int8 *v10; // rax
unsigned __int8 *v11; // rax
char v12; // bl
long long v13; // r15
long long v14; // rax
google::protobuf::internal::LogMessage *v15; // rax
long long v16; // rax
long long v17; // r15
long long v18; // rax
google::protobuf::internal::LogMessage *v19; // rax
google::protobuf::internal::LogMessage *v20; // rax
char v22; // [rsp+Fh] [rbp-89h] BYREF
void *v23[2]; // [rsp+10h] [rbp-88h] BYREF
_BYTE v24[16]; // [rsp+20h] [rbp-78h] BYREF
_BYTE v25[104]; // [rsp+30h] [rbp-68h] BYREF
v3 = (google::protobuf *)(*(long long ( **)(google::protobuf::MessageLite *))(*(_QWORD *)this + 64LL))(this);
if ( ((unsigned long long)v3 & 0xFFFFFFFF80000000LL) != 0 )
{
google::protobuf::internal::LogMessage::LogMessage(
(long long)v25,
2,
(long long)"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc",
372);
(*(void ( **)(void **, google::protobuf::MessageLite *))(*(_QWORD *)this + 16LL))(v23, this);
v4 = google::protobuf::internal::LogMessage::operator<<((long long)v25, (long long)v23);
v5 = google::protobuf::internal::LogMessage::operator<<(v4, (long long)" exceeded maximum protobuf size of 2GB: ");
v7 = (google::protobuf::internal::LogMessage *)google::protobuf::internal::LogMessage::operator<<(v5, v3, v6);
google::protobuf::internal::LogFinisher::operator=((long long)&v22, v7);
if ( v23[0] != v24 )
operator delete(v23[0]);
google::protobuf::internal::LogMessage::~LogMessage((google::protobuf::internal::LogMessage *)v25);
return 0;
}
else
{
v8 = google::protobuf::io::EpsCopyOutputStream::ByteCount((google::protobuf::io::EpsCopyOutputStream *)a2, a2[8]);
v9 = a2[9];
v10 = (unsigned __int8 *)(*(long long ( **)(google::protobuf::MessageLite *, unsigned __int8 *, unsigned __int8 **))(*(_QWORD *)this + 96LL))(
this,
a2[8],
a2);
a2[8] = v10;
v11 = (unsigned __int8 *)google::protobuf::io::EpsCopyOutputStream::FlushAndResetBuffer(
(google::protobuf::io::EpsCopyOutputStream *)a2,
v10);
a2[8] = v11;
v12 = *((_BYTE *)a2 + 56);
if ( !v12
&& v3 != (google::protobuf *)(int)(google::protobuf::io::EpsCopyOutputStream::ByteCount(
(google::protobuf::io::EpsCopyOutputStream *)a2,
v11)
+ (_DWORD)v9
- (*((_DWORD *)a2 + 18)
+ v8)) )
{
if ( v3 != (google::protobuf *)(*(long long ( **)(google::protobuf::MessageLite *))(*(_QWORD *)this + 64LL))(this) )
{
google::protobuf::internal::LogMessage::LogMessage(
(long long)v25,
3,
(long long)"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc",
83);
v13 = google::protobuf::internal::LogMessage::operator<<(
(long long)v25,
(long long)"CHECK failed: (byte_size_before_serialization) == (byte_size_after_serialization): ");
(*(void ( **)(void **, google::protobuf::MessageLite *))(*(_QWORD *)this + 16LL))(v23, this);
v14 = google::protobuf::internal::LogMessage::operator<<(v13, (long long)v23);
v15 = (google::protobuf::internal::LogMessage *)google::protobuf::internal::LogMessage::operator<<(
v14,
(long long)" was modified concurrently during serialization.");
google::protobuf::internal::LogFinisher::operator=((long long)&v22, v15);
if ( v23[0] != v24 )
operator delete(v23[0]);
google::protobuf::internal::LogMessage::~LogMessage((google::protobuf::internal::LogMessage *)v25);
}
google::protobuf::internal::LogMessage::LogMessage(
(long long)v25,
3,
(long long)"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc",
86);
v16 = google::protobuf::internal::LogMessage::operator<<(
(long long)v25,
(long long)"CHECK failed: (bytes_produced_by_serialization) == (byte_size_before_serialization): ");
v17 = google::protobuf::internal::LogMessage::operator<<(
v16,
(long long)"Byte size calculation and serialization were inconsistent. This may indicate a bug in protocol b"
"uffers or it may be caused by concurrent modification of ");
(*(void ( **)(void **, google::protobuf::MessageLite *))(*(_QWORD *)this + 16LL))(v23, this);
v18 = google::protobuf::internal::LogMessage::operator<<(v17, (long long)v23);
v19 = (google::protobuf::internal::LogMessage *)google::protobuf::internal::LogMessage::operator<<(
v18,
(long long)".");
google::protobuf::internal::LogFinisher::operator=((long long)&v22, v19);
if ( v23[0] != v24 )
operator delete(v23[0]);
google::protobuf::internal::LogMessage::~LogMessage((google::protobuf::internal::LogMessage *)v25);
google::protobuf::internal::LogMessage::LogMessage(
(long long)v25,
3,
(long long)"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc",
91);
v20 = (google::protobuf::internal::LogMessage *)google::protobuf::internal::LogMessage::operator<<(
(long long)v25,
(long long)"This shouldn't be called if all the sizes are equal.");
google::protobuf::internal::LogFinisher::operator=((long long)v23, v20);
google::protobuf::internal::LogMessage::~LogMessage((google::protobuf::internal::LogMessage *)v25);
}
LOBYTE(v2) = v12 ^ 1;
}
return v2;
}
|
SerializePartialToCodedStream:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x68
MOV R12,RSI
MOV R14,RDI
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x40]
MOV R15,RAX
TEST RAX,-0x80000000
JZ 0x0019e0b6
LEA RDX,[0x1bdf55]
LEA RDI,[RSP + 0x30]
MOV ESI,0x2
MOV ECX,0x174
CALL 0x001169ca
MOV RAX,qword ptr [R14]
LAB_0019e051:
LEA RDI,[RSP + 0x10]
MOV RSI,R14
CALL qword ptr [RAX + 0x10]
LAB_0019e05c:
LEA RDI,[RSP + 0x30]
LEA RSI,[RSP + 0x10]
CALL 0x001164da
LEA RSI,[0x1bdfc4]
MOV RDI,RAX
CALL 0x001164c8
MOV RDI,RAX
MOV RSI,R15
CALL 0x001168b8
LAB_0019e085:
LEA RDI,[RSP + 0xf]
MOV RSI,RAX
CALL 0x001165a2
LAB_0019e092:
LEA RAX,[RSP + 0x20]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0019e0a5
CALL 0x0010f330
LAB_0019e0a5:
LEA RDI,[RSP + 0x30]
CALL 0x001169e8
XOR EBX,EBX
JMP 0x0019e28f
LAB_0019e0b6:
MOV RSI,qword ptr [R12 + 0x40]
MOV RDI,R12
CALL 0x00115a34
MOV R13,RAX
MOV RSI,qword ptr [R12 + 0x40]
MOV RBP,qword ptr [R12 + 0x48]
MOV RAX,qword ptr [R14]
MOV RDI,R14
MOV RDX,R12
CALL qword ptr [RAX + 0x60]
MOV qword ptr [R12 + 0x40],RAX
MOV RDI,R12
MOV RSI,RAX
CALL 0x00115ba0
MOV qword ptr [R12 + 0x40],RAX
MOV BL,byte ptr [R12 + 0x38]
TEST BL,BL
JNZ 0x0019e28c
MOV RDI,R12
MOV RSI,RAX
CALL 0x00115a34
ADD R13D,dword ptr [R12 + 0x48]
ADD EBP,EAX
SUB EBP,R13D
MOVSXD RAX,EBP
CMP R15,RAX
JZ 0x0019e28c
MOV RAX,qword ptr [R14]
MOV RDI,R14
CALL qword ptr [RAX + 0x40]
CMP R15,RAX
JZ 0x0019e1b5
LEA RDX,[0x1bdf55]
LEA R15,[RSP + 0x30]
MOV RDI,R15
MOV ESI,0x3
MOV ECX,0x53
CALL 0x001169ca
LAB_0019e14f:
LEA RSI,[0x1be031]
MOV RDI,R15
CALL 0x001164c8
MOV R15,RAX
MOV RAX,qword ptr [R14]
LAB_0019e164:
LEA RDI,[RSP + 0x10]
MOV RSI,R14
CALL qword ptr [RAX + 0x10]
LAB_0019e16f:
LEA RSI,[RSP + 0x10]
MOV RDI,R15
CALL 0x001164da
LEA RSI,[0x1be085]
MOV RDI,RAX
CALL 0x001164c8
LAB_0019e18b:
LEA RDI,[RSP + 0xf]
MOV RSI,RAX
CALL 0x001165a2
LAB_0019e198:
LEA RAX,[RSP + 0x20]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0019e1ab
CALL 0x0010f330
LAB_0019e1ab:
LEA RDI,[RSP + 0x30]
CALL 0x001169e8
LAB_0019e1b5:
LEA RDX,[0x1bdf55]
LEA R15,[RSP + 0x30]
MOV RDI,R15
MOV ESI,0x3
MOV ECX,0x56
CALL 0x001169ca
LAB_0019e1d3:
LEA RSI,[0x1be0b6]
MOV RDI,R15
CALL 0x001164c8
LEA RSI,[0x1be10c]
MOV RDI,RAX
CALL 0x001164c8
MOV R15,RAX
MOV RAX,qword ptr [R14]
LAB_0019e1f7:
LEA RDI,[RSP + 0x10]
MOV RSI,R14
CALL qword ptr [RAX + 0x10]
LAB_0019e202:
LEA RSI,[RSP + 0x10]
MOV RDI,R15
CALL 0x001164da
LEA RSI,[0x1b64de]
MOV RDI,RAX
CALL 0x001164c8
LAB_0019e21e:
LEA RDI,[RSP + 0xf]
MOV RSI,RAX
CALL 0x001165a2
LAB_0019e22b:
LEA RAX,[RSP + 0x20]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0019e23e
CALL 0x0010f330
LAB_0019e23e:
LEA RDI,[RSP + 0x30]
CALL 0x001169e8
LEA RDX,[0x1bdf55]
LEA R14,[RSP + 0x30]
MOV RDI,R14
MOV ESI,0x3
MOV ECX,0x5b
CALL 0x001169ca
LAB_0019e266:
LEA RSI,[0x1be1a7]
MOV RDI,R14
CALL 0x001164c8
LAB_0019e275:
LEA RDI,[RSP + 0x10]
MOV RSI,RAX
CALL 0x001165a2
LAB_0019e282:
LEA RDI,[RSP + 0x30]
CALL 0x001169e8
LAB_0019e28c:
XOR BL,0x1
LAB_0019e28f:
MOV EAX,EBX
ADD RSP,0x68
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* google::protobuf::MessageLite::SerializePartialToCodedStream(google::protobuf::io::CodedOutputStream*)
const */
ulong __thiscall
google::protobuf::MessageLite::SerializePartialToCodedStream
(MessageLite *this,CodedOutputStream *param_1)
{
CodedOutputStream CVar1;
int8 uVar2;
int iVar3;
int iVar4;
ulong uVar5;
LogMessage *pLVar6;
uchar *puVar7;
ulong uVar8;
int8 unaff_RBX;
LogFinisher local_89;
int1 *local_88 [2];
int1 local_78 [16];
LogMessage local_68 [56];
uVar5 = (**(code **)(*(long *)this + 0x40))();
if ((uVar5 & 0xffffffff80000000) == 0) {
iVar3 = io::EpsCopyOutputStream::ByteCount
((EpsCopyOutputStream *)param_1,*(uchar **)(param_1 + 0x40));
uVar2 = *(int8 *)(param_1 + 0x48);
puVar7 = (uchar *)(**(code **)(*(long *)this + 0x60))
(this,*(int8 *)(param_1 + 0x40),param_1);
*(uchar **)(param_1 + 0x40) = puVar7;
puVar7 = (uchar *)io::EpsCopyOutputStream::FlushAndResetBuffer
((EpsCopyOutputStream *)param_1,puVar7);
*(uchar **)(param_1 + 0x40) = puVar7;
CVar1 = param_1[0x38];
if (CVar1 == (CodedOutputStream)0x0) {
iVar4 = io::EpsCopyOutputStream::ByteCount((EpsCopyOutputStream *)param_1,puVar7);
if (uVar5 != (long)(((int)uVar2 + iVar4) - (iVar3 + *(int *)(param_1 + 0x48)))) {
uVar8 = (**(code **)(*(long *)this + 0x40))(this);
if (uVar5 != uVar8) {
internal::LogMessage::LogMessage
(local_68,3,
"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc"
,0x53);
/* try { // try from 0019e14f to 0019e15d has its CatchHandler @ 0019e2a4 */
pLVar6 = (LogMessage *)
internal::LogMessage::operator<<
(local_68,
"CHECK failed: (byte_size_before_serialization) == (byte_size_after_serialization): "
);
/* try { // try from 0019e164 to 0019e16e has its CatchHandler @ 0019e2a2 */
(**(code **)(*(long *)this + 0x10))(local_88,this);
/* try { // try from 0019e16f to 0019e18a has its CatchHandler @ 0019e2ae */
pLVar6 = (LogMessage *)internal::LogMessage::operator<<(pLVar6,(string *)local_88);
pLVar6 = (LogMessage *)
internal::LogMessage::operator<<
(pLVar6," was modified concurrently during serialization.");
/* try { // try from 0019e18b to 0019e197 has its CatchHandler @ 0019e2a0 */
internal::LogFinisher::operator=(&local_89,pLVar6);
if (local_88[0] != local_78) {
operator_delete(local_88[0]);
}
internal::LogMessage::~LogMessage(local_68);
}
internal::LogMessage::LogMessage
(local_68,3,
"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc"
,0x56);
/* try { // try from 0019e1d3 to 0019e1f0 has its CatchHandler @ 0019e2b2 */
pLVar6 = (LogMessage *)
internal::LogMessage::operator<<
(local_68,
"CHECK failed: (bytes_produced_by_serialization) == (byte_size_before_serialization): "
);
pLVar6 = (LogMessage *)
internal::LogMessage::operator<<
(pLVar6,
"Byte size calculation and serialization were inconsistent. This may indicate a bug in protocol buffers or it may be caused by concurrent modification of "
);
/* try { // try from 0019e1f7 to 0019e201 has its CatchHandler @ 0019e2ac */
(**(code **)(*(long *)this + 0x10))(local_88,this);
/* try { // try from 0019e202 to 0019e21d has its CatchHandler @ 0019e2b0 */
pLVar6 = (LogMessage *)internal::LogMessage::operator<<(pLVar6,(string *)local_88);
pLVar6 = (LogMessage *)internal::LogMessage::operator<<(pLVar6,".");
/* try { // try from 0019e21e to 0019e22a has its CatchHandler @ 0019e2aa */
internal::LogFinisher::operator=(&local_89,pLVar6);
if (local_88[0] != local_78) {
operator_delete(local_88[0]);
}
internal::LogMessage::~LogMessage(local_68);
internal::LogMessage::LogMessage
(local_68,3,
"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc"
,0x5b);
/* try { // try from 0019e266 to 0019e274 has its CatchHandler @ 0019e2a8 */
pLVar6 = (LogMessage *)
internal::LogMessage::operator<<
(local_68,"This shouldn\'t be called if all the sizes are equal.");
/* try { // try from 0019e275 to 0019e281 has its CatchHandler @ 0019e2a6 */
internal::LogFinisher::operator=((LogFinisher *)local_88,pLVar6);
internal::LogMessage::~LogMessage(local_68);
}
}
uVar5 = CONCAT71((int7)((ulong)unaff_RBX >> 8),CVar1) ^ 1;
}
else {
internal::LogMessage::LogMessage
(local_68,2,
"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc"
,0x174);
/* try { // try from 0019e051 to 0019e05b has its CatchHandler @ 0019e2b6 */
(**(code **)(*(long *)this + 0x10))(local_88,this);
/* try { // try from 0019e05c to 0019e084 has its CatchHandler @ 0019e2bb */
pLVar6 = (LogMessage *)internal::LogMessage::operator<<(local_68,(string *)local_88);
pLVar6 = (LogMessage *)
internal::LogMessage::operator<<(pLVar6," exceeded maximum protobuf size of 2GB: ");
pLVar6 = (LogMessage *)internal::LogMessage::operator<<(pLVar6,uVar5);
/* try { // try from 0019e085 to 0019e091 has its CatchHandler @ 0019e2b4 */
internal::LogFinisher::operator=(&local_89,pLVar6);
if (local_88[0] != local_78) {
operator_delete(local_88[0]);
}
internal::LogMessage::~LogMessage(local_68);
uVar5 = 0;
}
return uVar5 & 0xffffffff;
}
|
|
7,821 |
common_arg::set_env(char const*)
|
monkey531[P]llama/common/arg.cpp
|
common_arg & common_arg::set_env(const char * env) {
help = help + "\n(env: " + env + ")";
this->env = env;
return *this;
}
|
O1
|
cpp
|
common_arg::set_env(char const*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x18(%rsp), %r12
movq %r12, -0x10(%r12)
movq 0x90(%rdi), %rsi
movq 0x98(%rdi), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x4d38c
leaq 0xad209(%rip), %rsi # 0x154e50
movq %r15, %rdi
callq 0x20520
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x20520
leaq 0x38(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0xa7c83
movq %rdx, 0x28(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x38(%rsp)
jmp 0xa7c8b
movups (%rcx), %xmm0
movups %xmm0, (%r13)
movq 0x8(%rax), %rdx
leaq 0x28(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0xb9489(%rip), %rsi # 0x161137
callq 0x20520
leaq 0x90(%rbx), %rdi
leaq 0x58(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0xa7ce1
movq %rdx, 0x48(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x58(%rsp)
jmp 0xa7ce8
movups (%rcx), %xmm0
movups %xmm0, (%rbp)
movq 0x8(%rax), %rdx
leaq 0x48(%rsp), %r15
movq %rdx, 0x8(%r15)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq %r15, %rsi
callq 0x1fd10
movq (%r15), %rdi
cmpq %rbp, %rdi
je 0xa7d21
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x1fae0
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0xa7d38
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1fae0
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0xa7d4f
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1fae0
movq %r14, 0x88(%rbx)
movq %rbx, %rax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0xa7d89
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1fae0
jmp 0xa7d89
jmp 0xa7d86
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0xa7da0
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1fae0
movq %rbx, %rdi
callq 0x20380
|
_ZN10common_arg7set_envEPKc:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 68h
mov r14, rsi
mov rbx, rdi
lea r12, [rsp+98h+var_80]
mov [r12-10h], r12
mov rsi, [rdi+90h]
mov rdx, [rdi+98h]
add rdx, rsi
lea r15, [rsp+98h+var_90]
mov rdi, r15
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
lea rsi, aEnv; "\n(env: "
mov rdi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea rdi, [rsp+98h+var_90]
mov rsi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea r13, [rsp+98h+var_60]
mov [r13-10h], r13
mov rdx, [rax]
mov rcx, rax
add rcx, 10h
cmp rdx, rcx
jz short loc_A7C83
mov [rsp+98h+var_70], rdx
mov rdx, [rcx]
mov [rsp+98h+var_60], rdx
jmp short loc_A7C8B
loc_A7C83:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [r13+0], xmm0
loc_A7C8B:
mov rdx, [rax+8]
lea rdi, [rsp+98h+var_70]
mov [rdi+8], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
lea rsi, a09401910201912+51h; ")"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea rdi, [rbx+90h]
lea rbp, [rsp+98h+var_40]
mov [rbp-10h], rbp
mov rdx, [rax]
mov rcx, rax
add rcx, 10h
cmp rdx, rcx
jz short loc_A7CE1
mov [rsp+98h+var_50], rdx
mov rdx, [rcx]
mov [rsp+98h+var_40], rdx
jmp short loc_A7CE8
loc_A7CE1:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [rbp+0], xmm0
loc_A7CE8:
mov rdx, [rax+8]
lea r15, [rsp+98h+var_50]
mov [r15+8], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
mov rsi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&)
mov rdi, [r15]; void *
cmp rdi, rbp
jz short loc_A7D21
mov rsi, [rsp+98h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A7D21:
mov rdi, [rsp+98h+var_70]; void *
cmp rdi, r13
jz short loc_A7D38
mov rsi, [rsp+98h+var_60]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A7D38:
mov rdi, [rsp+98h+var_90]; void *
cmp rdi, r12
jz short loc_A7D4F
mov rsi, [rsp+98h+var_80]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A7D4F:
mov [rbx+88h], r14
mov rax, rbx
add rsp, 68h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
mov rdi, [rsp+arg_20]; void *
cmp rdi, r13
jz short loc_A7D89
mov rsi, [rsp+arg_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_A7D89
jmp short $+2
loc_A7D86:
mov rbx, rax
loc_A7D89:
mov rdi, [rsp+arg_0]; void *
cmp rdi, r12
jz short loc_A7DA0
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A7DA0:
mov rdi, rbx
call __Unwind_Resume
|
common_arg * common_arg::set_env(common_arg *this, const char *a2)
{
long long v2; // rax
__int128 *v3; // rcx
long long v4; // rax
_OWORD *v5; // rcx
void *v7[2]; // [rsp+8h] [rbp-90h] BYREF
_QWORD v8[2]; // [rsp+18h] [rbp-80h] BYREF
void *v9[2]; // [rsp+28h] [rbp-70h] BYREF
__int128 v10; // [rsp+38h] [rbp-60h] BYREF
void *v11[2]; // [rsp+48h] [rbp-50h] BYREF
_OWORD v12[4]; // [rsp+58h] [rbp-40h] BYREF
v7[0] = v8;
std::string::_M_construct<char *>(v7, *((_BYTE **)this + 18), *((_QWORD *)this + 18) + *((_QWORD *)this + 19));
std::string::append(v7, "\n(env: ");
v2 = std::string::append(v7, a2);
v9[0] = &v10;
v3 = (__int128 *)(v2 + 16);
if ( *(_QWORD *)v2 == v2 + 16 )
{
v10 = *v3;
}
else
{
v9[0] = *(void **)v2;
*(_QWORD *)&v10 = *(_QWORD *)v3;
}
v9[1] = *(void **)(v2 + 8);
*(_QWORD *)v2 = v3;
*(_QWORD *)(v2 + 8) = 0LL;
*(_BYTE *)(v2 + 16) = 0;
v4 = std::string::append(v9, ")");
v11[0] = v12;
v5 = (_OWORD *)(v4 + 16);
if ( *(_QWORD *)v4 == v4 + 16 )
{
v12[0] = *v5;
}
else
{
v11[0] = *(void **)v4;
*(_QWORD *)&v12[0] = *(_QWORD *)v5;
}
v11[1] = *(void **)(v4 + 8);
*(_QWORD *)v4 = v5;
*(_QWORD *)(v4 + 8) = 0LL;
*(_BYTE *)(v4 + 16) = 0;
std::string::operator=((char *)this + 144, v11);
if ( v11[0] != v12 )
operator delete(v11[0], *(_QWORD *)&v12[0] + 1LL);
if ( v9[0] != &v10 )
operator delete(v9[0], v10 + 1);
if ( v7[0] != v8 )
operator delete(v7[0], v8[0] + 1LL);
*((_QWORD *)this + 17) = a2;
return this;
}
|
set_env:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x68
MOV R14,RSI
MOV RBX,RDI
LEA R12,[RSP + 0x18]
MOV qword ptr [R12 + -0x10],R12
MOV RSI,qword ptr [RDI + 0x90]
MOV RDX,qword ptr [RDI + 0x98]
ADD RDX,RSI
LEA R15,[RSP + 0x8]
MOV RDI,R15
CALL 0x0014d38c
LAB_001a7c40:
LEA RSI,[0x254e50]
MOV RDI,R15
CALL 0x00120520
LAB_001a7c4f:
LEA RDI,[RSP + 0x8]
MOV RSI,R14
CALL 0x00120520
LEA R13,[RSP + 0x38]
MOV qword ptr [R13 + -0x10],R13
MOV RDX,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RDX,RCX
JZ 0x001a7c83
MOV qword ptr [RSP + 0x28],RDX
MOV RDX,qword ptr [RCX]
MOV qword ptr [RSP + 0x38],RDX
JMP 0x001a7c8b
LAB_001a7c83:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [R13],XMM0
LAB_001a7c8b:
MOV RDX,qword ptr [RAX + 0x8]
LEA RDI,[RSP + 0x28]
MOV qword ptr [RDI + 0x8],RDX
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV byte ptr [RAX + 0x10],0x0
LAB_001a7ca7:
LEA RSI,[0x261137]
CALL 0x00120520
LAB_001a7cb3:
LEA RDI,[RBX + 0x90]
LEA RBP,[RSP + 0x58]
MOV qword ptr [RBP + -0x10],RBP
MOV RDX,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RDX,RCX
JZ 0x001a7ce1
MOV qword ptr [RSP + 0x48],RDX
MOV RDX,qword ptr [RCX]
MOV qword ptr [RSP + 0x58],RDX
JMP 0x001a7ce8
LAB_001a7ce1:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [RBP],XMM0
LAB_001a7ce8:
MOV RDX,qword ptr [RAX + 0x8]
LEA R15,[RSP + 0x48]
MOV qword ptr [R15 + 0x8],RDX
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV byte ptr [RAX + 0x10],0x0
MOV RSI,R15
CALL 0x0011fd10
MOV RDI,qword ptr [R15]
CMP RDI,RBP
JZ 0x001a7d21
MOV RSI,qword ptr [RSP + 0x58]
INC RSI
CALL 0x0011fae0
LAB_001a7d21:
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R13
JZ 0x001a7d38
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x0011fae0
LAB_001a7d38:
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,R12
JZ 0x001a7d4f
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011fae0
LAB_001a7d4f:
MOV qword ptr [RBX + 0x88],R14
MOV RAX,RBX
ADD RSP,0x68
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* common_arg::set_env(char const*) */
common_arg * __thiscall common_arg::set_env(common_arg *this,char *param_1)
{
long *plVar1;
long *plVar2;
long *local_90 [2];
long local_80 [2];
long *local_70;
long local_68;
long local_60;
long lStack_58;
long *local_50;
long local_48;
long local_40;
long lStack_38;
local_90[0] = local_80;
std::__cxx11::string::_M_construct<char*>
(local_90,*(long *)(this + 0x90),*(long *)(this + 0x98) + *(long *)(this + 0x90));
/* try { // try from 001a7c40 to 001a7c4e has its CatchHandler @ 001a7d86 */
std::__cxx11::string::append((char *)local_90);
/* try { // try from 001a7c4f to 001a7c5b has its CatchHandler @ 001a7d84 */
plVar1 = (long *)std::__cxx11::string::append((char *)local_90);
plVar2 = plVar1 + 2;
if ((long *)*plVar1 == plVar2) {
local_60 = *plVar2;
lStack_58 = plVar1[3];
local_70 = &local_60;
}
else {
local_60 = *plVar2;
local_70 = (long *)*plVar1;
}
local_68 = plVar1[1];
*plVar1 = (long)plVar2;
plVar1[1] = 0;
*(int1 *)(plVar1 + 2) = 0;
/* try { // try from 001a7ca7 to 001a7cb2 has its CatchHandler @ 001a7d68 */
plVar1 = (long *)std::__cxx11::string::append((char *)&local_70);
plVar2 = plVar1 + 2;
if ((long *)*plVar1 == plVar2) {
local_40 = *plVar2;
lStack_38 = plVar1[3];
local_50 = &local_40;
}
else {
local_40 = *plVar2;
local_50 = (long *)*plVar1;
}
local_48 = plVar1[1];
*plVar1 = (long)plVar2;
plVar1[1] = 0;
*(int1 *)(plVar1 + 2) = 0;
std::__cxx11::string::operator=((string *)(this + 0x90),(string *)&local_50);
if (local_50 != &local_40) {
operator_delete(local_50,local_40 + 1);
}
if (local_70 != &local_60) {
operator_delete(local_70,local_60 + 1);
}
if (local_90[0] != local_80) {
operator_delete(local_90[0],local_80[0] + 1);
}
*(char **)(this + 0x88) = param_1;
return this;
}
|
|
7,822 |
common_arg::set_env(char const*)
|
monkey531[P]llama/common/arg.cpp
|
common_arg & common_arg::set_env(const char * env) {
help = help + "\n(env: " + env + ")";
this->env = env;
return *this;
}
|
O2
|
cpp
|
common_arg::set_env(char const*):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x90(%rdi), %r15
leaq 0x6cc49(%rip), %rdx # 0xfac80
leaq 0x28(%rsp), %r12
movq %r12, %rdi
movq %r15, %rsi
callq 0x5dad0
leaq 0x8(%rsp), %rdi
movq %r12, %rsi
movq %r14, %rdx
callq 0x3bd40
leaq 0x78ec9(%rip), %rdx # 0x106f27
leaq 0x48(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x3bd40
leaq 0x48(%rsp), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x28d80
movq %r12, %rdi
callq 0x29678
leaq 0x8(%rsp), %rdi
callq 0x29678
leaq 0x28(%rsp), %rdi
callq 0x29678
movq %r14, 0x88(%rbx)
movq %rbx, %rax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x29678
jmp 0x8e0c1
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x29678
movq %rbx, %rdi
callq 0x293c0
nop
|
_ZN10common_arg7set_envEPKc:
push r15
push r14
push r12
push rbx
sub rsp, 68h
mov r14, rsi
mov rbx, rdi
lea r15, [rdi+90h]
lea rdx, aEnv; "\n(env: "
lea r12, [rsp+88h+var_60]
mov rdi, r12
mov rsi, r15
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EERKS8_PKS5_; std::operator+<char>(std::string const&,char const*)
lea rdi, [rsp+88h+var_80]
mov rsi, r12
mov rdx, r14
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_PKS5_; std::operator+<char>(std::string&&,char const*)
lea rdx, a09401910201912+51h; ")"
lea rdi, [rsp+88h+var_40]
lea rsi, [rsp+88h+var_80]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_PKS5_; std::operator+<char>(std::string&&,char const*)
lea r12, [rsp+88h+var_40]
mov rdi, r15
mov rsi, r12
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&)
mov rdi, r12; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+88h+var_80]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+88h+var_60]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov [rbx+88h], r14
mov rax, rbx
add rsp, 68h
pop rbx
pop r12
pop r14
pop r15
retn
mov rbx, rax
lea rdi, [rsp+arg_0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_8E0C1
mov rbx, rax
loc_8E0C1:
lea rdi, [rsp+arg_20]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, rbx
call __Unwind_Resume
|
common_arg * common_arg::set_env(common_arg *this, const char *a2)
{
_BYTE v3[32]; // [rsp+8h] [rbp-80h] BYREF
_BYTE v4[32]; // [rsp+28h] [rbp-60h] BYREF
_BYTE v5[64]; // [rsp+48h] [rbp-40h] BYREF
std::operator+<char>((long long)v4, (long long)this + 144, (long long)"\n(env: ");
std::operator+<char>((long long)v3, (long long)v4, (long long)a2);
std::operator+<char>((long long)v5, (long long)v3, (long long)")");
std::string::operator=((char *)this + 144, v5);
std::string::~string(v5);
std::string::~string(v3);
std::string::~string(v4);
*((_QWORD *)this + 17) = a2;
return this;
}
|
set_env:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x68
MOV R14,RSI
MOV RBX,RDI
LEA R15,[RDI + 0x90]
LEA RDX,[0x1fac80]
LEA R12,[RSP + 0x28]
MOV RDI,R12
MOV RSI,R15
CALL 0x0015dad0
LAB_0018e047:
LEA RDI,[RSP + 0x8]
MOV RSI,R12
MOV RDX,R14
CALL 0x0013bd40
LAB_0018e057:
LEA RDX,[0x206f27]
LEA RDI,[RSP + 0x48]
LEA RSI,[RSP + 0x8]
CALL 0x0013bd40
LAB_0018e06d:
LEA R12,[RSP + 0x48]
MOV RDI,R15
MOV RSI,R12
CALL 0x00128d80
MOV RDI,R12
CALL 0x00129678
LEA RDI,[RSP + 0x8]
CALL 0x00129678
LEA RDI,[RSP + 0x28]
CALL 0x00129678
MOV qword ptr [RBX + 0x88],R14
MOV RAX,RBX
ADD RSP,0x68
POP RBX
POP R12
POP R14
POP R15
RET
|
/* common_arg::set_env(char const*) */
common_arg * __thiscall common_arg::set_env(common_arg *this,char *param_1)
{
string local_80 [32];
string local_60 [32];
string local_40 [32];
std::operator+(local_60,(char *)(this + 0x90));
/* try { // try from 0018e047 to 0018e056 has its CatchHandler @ 0018e0be */
std::operator+(local_80,(char *)local_60);
/* try { // try from 0018e057 to 0018e06c has its CatchHandler @ 0018e0af */
std::operator+(local_40,(char *)local_80);
std::__cxx11::string::operator=((string *)(this + 0x90),local_40);
std::__cxx11::string::~string(local_40);
std::__cxx11::string::~string(local_80);
std::__cxx11::string::~string(local_60);
*(char **)(this + 0x88) = param_1;
return this;
}
|
|
7,823 |
JS_ToPrimitiveFree
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue JS_ToPrimitiveFree(JSContext *ctx, JSValue val, int hint)
{
int i;
BOOL force_ordinary;
JSAtom method_name;
JSValue method, ret;
if (JS_VALUE_GET_TAG(val) != JS_TAG_OBJECT)
return val;
force_ordinary = hint & HINT_FORCE_ORDINARY;
hint &= ~HINT_FORCE_ORDINARY;
if (!force_ordinary) {
method = JS_GetProperty(ctx, val, JS_ATOM_Symbol_toPrimitive);
if (JS_IsException(method))
goto exception;
/* ECMA says *If exoticToPrim is not undefined* but tests in
test262 use null as a non callable converter */
if (!JS_IsUndefined(method) && !JS_IsNull(method)) {
JSAtom atom;
JSValue arg;
switch(hint) {
case HINT_STRING:
atom = JS_ATOM_string;
break;
case HINT_NUMBER:
atom = JS_ATOM_number;
break;
default:
case HINT_NONE:
atom = JS_ATOM_default;
break;
}
arg = JS_AtomToString(ctx, atom);
ret = JS_CallFree(ctx, method, val, 1, &arg);
JS_FreeValue(ctx, arg);
if (JS_IsException(ret))
goto exception;
JS_FreeValue(ctx, val);
if (JS_VALUE_GET_TAG(ret) != JS_TAG_OBJECT)
return ret;
JS_FreeValue(ctx, ret);
return JS_ThrowTypeError(ctx, "toPrimitive");
}
}
if (hint != HINT_STRING)
hint = HINT_NUMBER;
for(i = 0; i < 2; i++) {
if ((i ^ hint) == 0) {
method_name = JS_ATOM_toString;
} else {
method_name = JS_ATOM_valueOf;
}
method = JS_GetProperty(ctx, val, method_name);
if (JS_IsException(method))
goto exception;
if (JS_IsFunction(ctx, method)) {
ret = JS_CallFree(ctx, method, val, 0, NULL);
if (JS_IsException(ret))
goto exception;
if (JS_VALUE_GET_TAG(ret) != JS_TAG_OBJECT) {
JS_FreeValue(ctx, val);
return ret;
}
JS_FreeValue(ctx, ret);
} else {
JS_FreeValue(ctx, method);
}
}
JS_ThrowTypeError(ctx, "toPrimitive");
exception:
JS_FreeValue(ctx, val);
return JS_EXCEPTION;
}
|
O1
|
c
|
JS_ToPrimitiveFree:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdx, %r13
movq %rsi, %rbp
cmpl $-0x1, %r13d
jne 0x3d536
movq %rdi, %r14
movl %ecx, %ebx
andl $-0x11, %ebx
testb $0x10, %cl
movq %r13, 0x20(%rsp)
movq %rbp, 0x28(%rsp)
jne 0x3d42d
movl $0x0, 0x8(%rsp)
movq $0x0, (%rsp)
movq %r14, %rdi
movq %rbp, %rsi
movq %r13, %rdx
movl $0xd3, %ecx
movq %rbp, %r8
movq %r13, %r9
callq 0x2238f
leal -0x2(%rdx), %ecx
cmpl $0x2, %ecx
jae 0x3d56e
xorl %eax, %eax
testl %ebx, %ebx
setne %al
movl %eax, 0x34(%rsp)
xorl %ebx, %ebx
movq %r14, %r15
xorl %eax, %eax
cmpl %ebx, 0x34(%rsp)
setne %al
leal 0x38(%rax,%rax), %ecx
movl $0x0, 0x8(%rsp)
movq $0x0, (%rsp)
movq %r15, %rdi
movq %rbp, %rsi
movq %r13, %rdx
movq %rbp, %r8
movq %r13, %r9
callq 0x2238f
movq %rdx, %rbp
cmpl $0x6, %ebp
je 0x3d64f
movq %rax, %r14
movq %r15, %rdi
movq %rax, %rsi
movq %rbp, %rdx
callq 0x221aa
testl %eax, %eax
je 0x3d4fc
movl $0x0, 0x38(%rsp)
movq $0x3, 0x40(%rsp)
movups 0x38(%rsp), %xmm0
movups %xmm0, (%rsp)
movl $0x2, 0x18(%rsp)
movq $0x0, 0x10(%rsp)
movq %r15, %rdi
movq %r14, %rsi
movq %rbp, %rdx
movq 0x28(%rsp), %rcx
movq 0x20(%rsp), %r8
xorl %r9d, %r9d
callq 0x278b6
movq %rax, %r12
movq %rdx, %r13
movq 0x18(%r15), %rdi
movq %r14, %rsi
movq %rbp, %rdx
callq 0x1ccb2
cmpl $-0x1, %r13d
jne 0x3d545
movq 0x18(%r15), %rdi
movq %r12, %rsi
movq %r13, %rdx
jmp 0x3d506
movq 0x18(%r15), %rdi
movq %r14, %rsi
movq %rbp, %rdx
callq 0x1ccb2
incl %ebx
cmpl $0x1, %ebx
movq 0x20(%rsp), %r13
movq 0x28(%rsp), %rbp
je 0x3d43d
leaq 0x60584(%rip), %rsi # 0x9daab
movq %r15, %rdi
xorl %eax, %eax
callq 0x21953
jmp 0x3d64f
movq %rbp, %rcx
shrq $0x20, %rcx
movq %rbp, %r12
jmp 0x3d671
cmpl $0x6, %r13d
je 0x3d64f
movq 0x18(%r15), %rdi
movq 0x28(%rsp), %rsi
movq 0x20(%rsp), %rdx
callq 0x1ccb2
movq %r12, %rcx
shrq $0x20, %rcx
jmp 0x3d671
movq %rdx, %r12
cmpl $0x6, %r12d
movq %r14, %r15
je 0x3d64f
cmpl $0x1, %ebx
movl $0x47, %edx
movl $0x16, %ecx
cmovel %edx, %ecx
testl %ebx, %ebx
movq %rax, %r13
movl $0x49, %esi
cmovnel %ecx, %esi
movq %r15, %rdi
movl $0x1, %edx
callq 0x1fb46
leaq 0x38(%rsp), %rbx
movq %rax, (%rbx)
movq %rdx, 0x8(%rbx)
movq %rbx, (%rsp)
movq %r15, %rdi
movq %r13, %rsi
movq %r12, %rdx
movq 0x28(%rsp), %rbp
movq %rbp, %rcx
movq 0x20(%rsp), %r8
movl $0x1, %r9d
callq 0x22089
movq %rax, %r12
movq %rdx, %r13
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
movq 0x18(%r15), %rdi
callq 0x1ccb2
movl %r13d, %ebx
cmpq $0x6, %rbx
jne 0x3d5fd
xorl %r12d, %r12d
jmp 0x3d647
movq 0x18(%r15), %rdi
movq %rbp, %rsi
movq 0x20(%rsp), %rdx
callq 0x1ccb2
cmpl $-0x1, %ebx
jne 0x3d640
movq 0x18(%r15), %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x1ccb2
leaq 0x60482(%rip), %rsi # 0x9daab
xorl %r12d, %r12d
movq %r15, %rdi
xorl %eax, %eax
callq 0x21953
movl $0x6, %r13d
xorl %ecx, %ecx
jmp 0x3d647
movq %r12, %rcx
shrq $0x20, %rcx
cmpl $0x6, %ebx
movq %r14, %r15
jne 0x3d671
movq 0x18(%r15), %rdi
movq 0x28(%rsp), %rsi
movq 0x20(%rsp), %rdx
movq %rcx, %rbx
callq 0x1ccb2
movq %rbx, %rcx
movl $0x6, %r13d
xorl %r12d, %r12d
shlq $0x20, %rcx
movl %r12d, %eax
orq %rcx, %rax
movq %r13, %rdx
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
JS_ToPrimitiveFree:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov r13, rdx
mov rbp, rsi
cmp r13d, 0FFFFFFFFh
jnz loc_3D536
mov r14, rdi
mov ebx, ecx
and ebx, 0FFFFFFEFh
test cl, 10h
mov [rsp+78h+var_58], r13
mov [rsp+78h+var_50], rbp
jnz short loc_3D42D
mov dword ptr [rsp+78h+var_78+8], 0
mov qword ptr [rsp+78h+var_78], 0
mov rdi, r14
mov rsi, rbp
mov rdx, r13
mov ecx, 0D3h
mov r8, rbp
mov r9, r13
call JS_GetPropertyInternal2
lea ecx, [rdx-2]
cmp ecx, 2
jnb loc_3D56E
loc_3D42D:
xor eax, eax
test ebx, ebx
setnz al
mov [rsp+78h+var_44], eax
xor ebx, ebx
mov r15, r14
loc_3D43D:
xor eax, eax
cmp [rsp+78h+var_44], ebx
setnz al
lea ecx, [rax+rax+38h]
mov dword ptr [rsp+78h+var_78+8], 0
mov qword ptr [rsp+78h+var_78], 0
mov rdi, r15
mov rsi, rbp
mov rdx, r13
mov r8, rbp
mov r9, r13
call JS_GetPropertyInternal2
mov rbp, rdx
cmp ebp, 6
jz loc_3D64F
mov r14, rax
mov rdi, r15
mov rsi, rax
mov rdx, rbp
call JS_IsFunction
test eax, eax
jz short loc_3D4FC
mov dword ptr [rsp+78h+var_40], 0
mov qword ptr [rsp+78h+var_40+8], 3
movups xmm0, [rsp+78h+var_40]
movups [rsp+78h+var_78], xmm0
mov [rsp+78h+var_60], 2
mov [rsp+78h+var_68], 0
mov rdi, r15
mov rsi, r14
mov rdx, rbp
mov rcx, [rsp+78h+var_50]
mov r8, [rsp+78h+var_58]
xor r9d, r9d
call JS_CallInternal
mov r12, rax
mov r13, rdx
mov rdi, [r15+18h]
mov rsi, r14
mov rdx, rbp
call JS_FreeValueRT
cmp r13d, 0FFFFFFFFh
jnz short loc_3D545
mov rdi, [r15+18h]
mov rsi, r12
mov rdx, r13
jmp short loc_3D506
loc_3D4FC:
mov rdi, [r15+18h]
mov rsi, r14
mov rdx, rbp
loc_3D506:
call JS_FreeValueRT
inc ebx
cmp ebx, 1
mov r13, [rsp+78h+var_58]
mov rbp, [rsp+78h+var_50]
jz loc_3D43D
lea rsi, aToprimitive; "toPrimitive"
mov rdi, r15
xor eax, eax
call JS_ThrowTypeError
jmp loc_3D64F
loc_3D536:
mov rcx, rbp
shr rcx, 20h
mov r12, rbp
jmp loc_3D671
loc_3D545:
cmp r13d, 6
jz loc_3D64F
mov rdi, [r15+18h]
mov rsi, [rsp+78h+var_50]
mov rdx, [rsp+78h+var_58]
call JS_FreeValueRT
mov rcx, r12
shr rcx, 20h
jmp loc_3D671
loc_3D56E:
mov r12, rdx
cmp r12d, 6
mov r15, r14
jz loc_3D64F
cmp ebx, 1
mov edx, 47h ; 'G'
mov ecx, 16h
cmovz ecx, edx
test ebx, ebx
mov r13, rax
mov esi, 49h ; 'I'
cmovnz esi, ecx
mov rdi, r15
mov edx, 1
call __JS_AtomToValue
lea rbx, [rsp+78h+var_40]
mov [rbx], rax
mov [rbx+8], rdx
mov qword ptr [rsp+78h+var_78], rbx
mov rdi, r15
mov rsi, r13
mov rdx, r12
mov rbp, [rsp+78h+var_50]
mov rcx, rbp
mov r8, [rsp+78h+var_58]
mov r9d, 1
call JS_CallFree
mov r12, rax
mov r13, rdx
mov rsi, [rbx]
mov rdx, [rbx+8]
mov rdi, [r15+18h]
call JS_FreeValueRT
mov ebx, r13d
cmp rbx, 6
jnz short loc_3D5FD
xor r12d, r12d
jmp short loc_3D647
loc_3D5FD:
mov rdi, [r15+18h]
mov rsi, rbp
mov rdx, [rsp+78h+var_58]
call JS_FreeValueRT
cmp ebx, 0FFFFFFFFh
jnz short loc_3D640
mov rdi, [r15+18h]
mov rsi, r12
mov rdx, r13
call JS_FreeValueRT
lea rsi, aToprimitive; "toPrimitive"
xor r12d, r12d
mov rdi, r15
xor eax, eax
call JS_ThrowTypeError
mov r13d, 6
xor ecx, ecx
jmp short loc_3D647
loc_3D640:
mov rcx, r12
shr rcx, 20h
loc_3D647:
cmp ebx, 6
mov r15, r14
jnz short loc_3D671
loc_3D64F:
mov rdi, [r15+18h]
mov rsi, [rsp+78h+var_50]
mov rdx, [rsp+78h+var_58]
mov rbx, rcx
call JS_FreeValueRT
mov rcx, rbx
mov r13d, 6
xor r12d, r12d
loc_3D671:
shl rcx, 20h
mov eax, r12d
or rax, rcx
mov rdx, r13
add rsp, 48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
unsigned long long JS_ToPrimitiveFree(
long long a1,
unsigned long long a2,
long long a3,
int a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
double a9,
double a10,
__m128 a11,
__m128 a12)
{
long long v12; // r13
long long v13; // rbp
unsigned int v14; // ebx
unsigned long long v15; // rax
long long v16; // rdx
unsigned long long v17; // rcx
int v18; // ebx
long long v19; // r15
unsigned long long PropertyInternal2; // rax
long long v21; // rdx
long long v22; // rbp
_DWORD *v23; // r14
__m128 v24; // xmm4
__m128 v25; // xmm5
unsigned long long v26; // r12
long long v27; // rdx
long long v28; // r13
long long v29; // rdi
_DWORD *v30; // rsi
long long v31; // rdx
long long v32; // rdx
long long v33; // rcx
long long v34; // r8
long long v35; // r9
__m128 v36; // xmm4
__m128 v37; // xmm5
long long v38; // r12
int v39; // ecx
_DWORD *v40; // r13
int v41; // esi
__m128 v42; // rax
long long v43; // rdx
long long v44; // r13
long long v45; // rdx
long long v46; // rcx
long long v47; // r8
long long v48; // r9
__m128 v49; // xmm4
__m128 v50; // xmm5
unsigned long long v51; // rbx
char v53; // [rsp+0h] [rbp-78h]
char v54; // [rsp+0h] [rbp-78h]
int v57; // [rsp+34h] [rbp-44h]
__m128 v58; // [rsp+38h] [rbp-40h] BYREF
v12 = a3;
v13 = a2;
if ( (_DWORD)a3 == -1 )
{
v14 = a4 & 0xFFFFFFEF;
if ( (a4 & 0x10) != 0
|| (v15 = JS_GetPropertyInternal2(a1, a2, a3, 0xD3u, a2, a3, 0LL, 0),
v17 = (unsigned int)(v16 - 2),
(unsigned int)v17 < 2) )
{
v57 = v14 != 0;
v18 = 0;
v19 = a1;
while ( 1 )
{
PropertyInternal2 = JS_GetPropertyInternal2(
v19,
v13,
v12,
2 * (unsigned int)(v57 != v18) + 56,
v13,
v12,
0LL,
0);
v22 = v21;
if ( (_DWORD)v21 == 6 )
goto LABEL_26;
v23 = (_DWORD *)PropertyInternal2;
if ( (unsigned int)JS_IsFunction(v19, PropertyInternal2, v21) )
{
v58.m128_i32[0] = 0;
v58.m128_u64[1] = 3LL;
a5 = v58;
v26 = JS_CallInternal(v19, (long long)v23, v22, a2, a3, 0LL, v58, a6, a7, a8, v24, v25, a11, a12, 0, 3, 0LL, 2u);
v28 = v27;
JS_FreeValueRT(*(_QWORD *)(v19 + 24), v23, v22);
if ( (_DWORD)v28 != -1 )
{
if ( (_DWORD)v28 == 6 )
goto LABEL_26;
JS_FreeValueRT(*(_QWORD *)(v19 + 24), (_DWORD *)a2, a3);
v17 = HIDWORD(v26);
return (v17 << 32) | (unsigned int)v26;
}
v29 = *(_QWORD *)(v19 + 24);
v30 = (_DWORD *)v26;
v31 = v28;
}
else
{
v29 = *(_QWORD *)(v19 + 24);
v30 = v23;
v31 = v22;
}
JS_FreeValueRT(v29, v30, v31);
++v18;
v12 = a3;
v13 = a2;
if ( v18 != 1 )
{
JS_ThrowTypeError(v19, (long long)"toPrimitive", v32, v33, v34, v35, a5, a6, a7, a8, v36, v37, a11, a12, v53);
goto LABEL_26;
}
}
}
v38 = v16;
v19 = a1;
if ( (_DWORD)v16 == 6 )
goto LABEL_26;
v39 = 22;
if ( v14 == 1 )
v39 = 71;
v40 = (_DWORD *)v15;
v41 = 73;
if ( v14 )
v41 = v39;
v42.m128_u64[0] = _JS_AtomToValue(a1, v41, 1);
v58 = v42;
v26 = JS_CallFree(a1, v40, v38, a2, a3, 1, (long long)&v58);
v44 = v43;
JS_FreeValueRT(*(_QWORD *)(a1 + 24), v58.m128_u64[0], v58.m128_i64[1]);
if ( (unsigned int)v44 == 6LL )
{
LODWORD(v26) = 0;
}
else
{
JS_FreeValueRT(*(_QWORD *)(a1 + 24), (_DWORD *)a2, a3);
if ( (_DWORD)v44 == -1 )
{
JS_FreeValueRT(*(_QWORD *)(a1 + 24), (_DWORD *)v26, v44);
LODWORD(v26) = 0;
JS_ThrowTypeError(a1, (long long)"toPrimitive", v45, v46, v47, v48, a5, a6, a7, a8, v49, v50, a11, a12, v54);
v17 = 0LL;
}
else
{
v17 = HIDWORD(v26);
}
}
v19 = a1;
if ( (_DWORD)v44 == 6 )
{
LABEL_26:
v51 = v17;
JS_FreeValueRT(*(_QWORD *)(v19 + 24), (_DWORD *)a2, a3);
v17 = v51;
LODWORD(v26) = 0;
}
}
else
{
v17 = HIDWORD(a2);
LODWORD(v26) = a2;
}
return (v17 << 32) | (unsigned int)v26;
}
|
JS_ToPrimitiveFree:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV R13,RDX
MOV RBP,RSI
CMP R13D,-0x1
JNZ 0x0013d536
MOV R14,RDI
MOV EBX,ECX
AND EBX,0xffffffef
TEST CL,0x10
MOV qword ptr [RSP + 0x20],R13
MOV qword ptr [RSP + 0x28],RBP
JNZ 0x0013d42d
MOV dword ptr [RSP + 0x8],0x0
MOV qword ptr [RSP],0x0
MOV RDI,R14
MOV RSI,RBP
MOV RDX,R13
MOV ECX,0xd3
MOV R8,RBP
MOV R9,R13
CALL 0x0012238f
LEA ECX,[RDX + -0x2]
CMP ECX,0x2
JNC 0x0013d56e
LAB_0013d42d:
XOR EAX,EAX
TEST EBX,EBX
SETNZ AL
MOV dword ptr [RSP + 0x34],EAX
XOR EBX,EBX
MOV R15,R14
LAB_0013d43d:
XOR EAX,EAX
CMP dword ptr [RSP + 0x34],EBX
SETNZ AL
LEA ECX,[RAX + RAX*0x1 + 0x38]
MOV dword ptr [RSP + 0x8],0x0
MOV qword ptr [RSP],0x0
MOV RDI,R15
MOV RSI,RBP
MOV RDX,R13
MOV R8,RBP
MOV R9,R13
CALL 0x0012238f
MOV RBP,RDX
CMP EBP,0x6
JZ 0x0013d64f
MOV R14,RAX
MOV RDI,R15
MOV RSI,RAX
MOV RDX,RBP
CALL 0x001221aa
TEST EAX,EAX
JZ 0x0013d4fc
MOV dword ptr [RSP + 0x38],0x0
MOV qword ptr [RSP + 0x40],0x3
MOVUPS XMM0,xmmword ptr [RSP + 0x38]
MOVUPS xmmword ptr [RSP],XMM0
MOV dword ptr [RSP + 0x18],0x2
MOV qword ptr [RSP + 0x10],0x0
MOV RDI,R15
MOV RSI,R14
MOV RDX,RBP
MOV RCX,qword ptr [RSP + 0x28]
MOV R8,qword ptr [RSP + 0x20]
XOR R9D,R9D
CALL 0x001278b6
MOV R12,RAX
MOV R13,RDX
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,R14
MOV RDX,RBP
CALL 0x0011ccb2
CMP R13D,-0x1
JNZ 0x0013d545
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,R12
MOV RDX,R13
JMP 0x0013d506
LAB_0013d4fc:
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,R14
MOV RDX,RBP
LAB_0013d506:
CALL 0x0011ccb2
INC EBX
CMP EBX,0x1
MOV R13,qword ptr [RSP + 0x20]
MOV RBP,qword ptr [RSP + 0x28]
JZ 0x0013d43d
LEA RSI,[0x19daab]
MOV RDI,R15
XOR EAX,EAX
CALL 0x00121953
JMP 0x0013d64f
LAB_0013d536:
MOV RCX,RBP
SHR RCX,0x20
MOV R12,RBP
JMP 0x0013d671
LAB_0013d545:
CMP R13D,0x6
JZ 0x0013d64f
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,qword ptr [RSP + 0x20]
CALL 0x0011ccb2
MOV RCX,R12
SHR RCX,0x20
JMP 0x0013d671
LAB_0013d56e:
MOV R12,RDX
CMP R12D,0x6
MOV R15,R14
JZ 0x0013d64f
CMP EBX,0x1
MOV EDX,0x47
MOV ECX,0x16
CMOVZ ECX,EDX
TEST EBX,EBX
MOV R13,RAX
MOV ESI,0x49
CMOVNZ ESI,ECX
MOV RDI,R15
MOV EDX,0x1
CALL 0x0011fb46
LEA RBX,[RSP + 0x38]
MOV qword ptr [RBX],RAX
MOV qword ptr [RBX + 0x8],RDX
MOV qword ptr [RSP],RBX
MOV RDI,R15
MOV RSI,R13
MOV RDX,R12
MOV RBP,qword ptr [RSP + 0x28]
MOV RCX,RBP
MOV R8,qword ptr [RSP + 0x20]
MOV R9D,0x1
CALL 0x00122089
MOV R12,RAX
MOV R13,RDX
MOV RSI,qword ptr [RBX]
MOV RDX,qword ptr [RBX + 0x8]
MOV RDI,qword ptr [R15 + 0x18]
CALL 0x0011ccb2
MOV EBX,R13D
CMP RBX,0x6
JNZ 0x0013d5fd
XOR R12D,R12D
JMP 0x0013d647
LAB_0013d5fd:
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,RBP
MOV RDX,qword ptr [RSP + 0x20]
CALL 0x0011ccb2
CMP EBX,-0x1
JNZ 0x0013d640
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,R12
MOV RDX,R13
CALL 0x0011ccb2
LEA RSI,[0x19daab]
XOR R12D,R12D
MOV RDI,R15
XOR EAX,EAX
CALL 0x00121953
MOV R13D,0x6
XOR ECX,ECX
JMP 0x0013d647
LAB_0013d640:
MOV RCX,R12
SHR RCX,0x20
LAB_0013d647:
CMP EBX,0x6
MOV R15,R14
JNZ 0x0013d671
LAB_0013d64f:
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,qword ptr [RSP + 0x20]
MOV RBX,RCX
CALL 0x0011ccb2
MOV RCX,RBX
MOV R13D,0x6
XOR R12D,R12D
LAB_0013d671:
SHL RCX,0x20
MOV EAX,R12D
OR RAX,RCX
MOV RDX,R13
ADD RSP,0x48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int1 [16] JS_ToPrimitiveFree(long param_1,ulong param_2,int8 param_3,uint param_4)
{
int8 uVar1;
int iVar2;
uint uVar3;
ulong uVar4;
int8 uVar5;
uint uVar6;
int8 uVar7;
ulong uVar8;
ulong uVar9;
bool bVar10;
int1 auVar11 [16];
int1 auVar12 [16];
int1 local_40 [16];
auVar11._8_8_ = param_3;
auVar11._0_8_ = param_2;
if ((int)param_3 != -1) {
uVar4 = param_2 >> 0x20;
goto LAB_0013d671;
}
uVar6 = param_4 & 0xffffffef;
if ((param_4 & 0x10) == 0) {
auVar11 = JS_GetPropertyInternal2(param_1,param_2,param_3,0xd3,param_2,param_3,0,0);
uVar3 = auVar11._8_4_ - 2;
uVar4 = (ulong)uVar3;
if (uVar3 < 2) goto LAB_0013d42d;
if (auVar11._8_4_ != 6) {
uVar5 = 0x16;
if (uVar6 == 1) {
uVar5 = 0x47;
}
uVar7 = 0x49;
if (uVar6 != 0) {
uVar7 = uVar5;
}
local_40 = __JS_AtomToValue(param_1,uVar7,1);
uVar4 = param_2;
auVar12 = JS_CallFree(param_1,auVar11._0_8_,auVar11._8_8_,param_2,param_3,1,local_40);
uVar9 = auVar12._8_8_;
uVar8 = auVar12._0_8_;
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),local_40._0_8_,local_40._8_8_);
if ((uVar9 & 0xffffffff) == 6) {
uVar8 = 0;
}
else {
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),param_2,param_3);
if (auVar12._8_4_ == -1) {
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),uVar8,uVar9);
uVar8 = 0;
JS_ThrowTypeError(param_1,"toPrimitive");
uVar9 = 6;
uVar4 = 0;
}
else {
uVar4 = uVar8 >> 0x20;
}
}
auVar11._8_8_ = uVar9;
auVar11._0_8_ = uVar8;
if (auVar12._8_4_ != 6) goto LAB_0013d671;
}
}
else {
LAB_0013d42d:
uVar3 = 0;
do {
bVar10 = (uVar6 != 0) != uVar3;
uVar4 = (ulong)(bVar10 + 0x38 + (uint)bVar10);
auVar11 = JS_GetPropertyInternal2(param_1,param_2,param_3,uVar4,param_2,param_3,0,0);
uVar7 = auVar11._8_8_;
uVar5 = auVar11._0_8_;
if (auVar11._8_4_ == 6) goto LAB_0013d64f;
iVar2 = JS_IsFunction(param_1,uVar5,uVar7);
uVar1 = local_40._0_8_;
if (iVar2 == 0) {
uVar5 = *(int8 *)(param_1 + 0x18);
}
else {
local_40._0_8_ = local_40._0_8_ & 0xffffffff00000000;
local_40._8_8_ = 3;
uVar4 = param_2;
auVar11 = JS_CallInternal(param_1,uVar5,uVar7,param_2,param_3,0,uVar1 & 0xffffffff00000000,3
,0,2);
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),uVar5,uVar7);
if (auVar11._8_4_ != -1) {
if (auVar11._8_4_ == 6) goto LAB_0013d64f;
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),param_2,param_3);
uVar4 = auVar11._0_8_ >> 0x20;
goto LAB_0013d671;
}
uVar5 = *(int8 *)(param_1 + 0x18);
}
JS_FreeValueRT(uVar5,auVar11._0_8_,auVar11._8_8_);
uVar3 = uVar3 + 1;
} while (uVar3 == 1);
JS_ThrowTypeError(param_1,"toPrimitive");
}
LAB_0013d64f:
JS_FreeValueRT(*(int8 *)(param_1 + 0x18),param_2,param_3);
auVar11 = ZEXT816(6) << 0x40;
LAB_0013d671:
auVar12._0_8_ = auVar11._0_8_ & 0xffffffff | uVar4 << 0x20;
auVar12._8_8_ = auVar11._8_8_;
return auVar12;
}
|
|
7,824 |
JS_ToPrimitiveFree
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue JS_ToPrimitiveFree(JSContext *ctx, JSValue val, int hint)
{
int i;
BOOL force_ordinary;
JSAtom method_name;
JSValue method, ret;
if (JS_VALUE_GET_TAG(val) != JS_TAG_OBJECT)
return val;
force_ordinary = hint & HINT_FORCE_ORDINARY;
hint &= ~HINT_FORCE_ORDINARY;
if (!force_ordinary) {
method = JS_GetProperty(ctx, val, JS_ATOM_Symbol_toPrimitive);
if (JS_IsException(method))
goto exception;
/* ECMA says *If exoticToPrim is not undefined* but tests in
test262 use null as a non callable converter */
if (!JS_IsUndefined(method) && !JS_IsNull(method)) {
JSAtom atom;
JSValue arg;
switch(hint) {
case HINT_STRING:
atom = JS_ATOM_string;
break;
case HINT_NUMBER:
atom = JS_ATOM_number;
break;
default:
case HINT_NONE:
atom = JS_ATOM_default;
break;
}
arg = JS_AtomToString(ctx, atom);
ret = JS_CallFree(ctx, method, val, 1, &arg);
JS_FreeValue(ctx, arg);
if (JS_IsException(ret))
goto exception;
JS_FreeValue(ctx, val);
if (JS_VALUE_GET_TAG(ret) != JS_TAG_OBJECT)
return ret;
JS_FreeValue(ctx, ret);
return JS_ThrowTypeError(ctx, "toPrimitive");
}
}
if (hint != HINT_STRING)
hint = HINT_NUMBER;
for(i = 0; i < 2; i++) {
if ((i ^ hint) == 0) {
method_name = JS_ATOM_toString;
} else {
method_name = JS_ATOM_valueOf;
}
method = JS_GetProperty(ctx, val, method_name);
if (JS_IsException(method))
goto exception;
if (JS_IsFunction(ctx, method)) {
ret = JS_CallFree(ctx, method, val, 0, NULL);
if (JS_IsException(ret))
goto exception;
if (JS_VALUE_GET_TAG(ret) != JS_TAG_OBJECT) {
JS_FreeValue(ctx, val);
return ret;
}
JS_FreeValue(ctx, ret);
} else {
JS_FreeValue(ctx, method);
}
}
JS_ThrowTypeError(ctx, "toPrimitive");
exception:
JS_FreeValue(ctx, val);
return JS_EXCEPTION;
}
|
O2
|
c
|
JS_ToPrimitiveFree:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r14
movq %rsi, %rbp
cmpl $-0x1, %r14d
jne 0x35c56
movq %rdi, %r15
movl %ecx, %ebx
andl $-0x11, %ebx
testb $0x10, %cl
movq %rbp, 0x10(%rsp)
jne 0x35bc4
movq %r15, %rdi
movq %rbp, %rsi
movq %r14, %rdx
movl $0xd3, %ecx
callq 0x1a4c7
movq %rax, %r12
leal -0x2(%rdx), %eax
cmpl $0x2, %eax
jae 0x35c9d
xorl %ebp, %ebp
testl %ebx, %ebx
setne %bpl
xorl %ebx, %ebx
cmpl $0x2, %ebx
je 0x35d4f
xorl %eax, %eax
cmpl %ebx, %ebp
setne %al
leal 0x38(,%rax,2), %ecx
movq %r15, %rdi
movq 0x10(%rsp), %rsi
movq %r14, %rdx
callq 0x1a4c7
movq %rdx, %r12
cmpl $0x6, %r12d
je 0x35d60
movq %rax, %r13
movq %r15, %rdi
movq %rax, %rsi
movq %r12, %rdx
callq 0x1c301
testl %eax, %eax
je 0x35c41
andq $0x0, (%rsp)
movq %r15, %rdi
movq %r13, %rsi
movq %r12, %rdx
movq 0x10(%rsp), %rcx
movq %r14, %r8
xorl %r9d, %r9d
callq 0x1c212
movq %rax, %r13
movq %rdx, %r12
cmpl $-0x1, %r12d
jne 0x35c68
movq %r15, %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x174a2
incl %ebx
jmp 0x35bce
movabsq $-0x100000000, %rcx # imm = 0xFFFFFFFF00000000
andq %rbp, %rcx
jmp 0x35d78
cmpl $0x6, %r12d
je 0x35d60
movq %r15, %rdi
movq 0x10(%rsp), %rsi
movq %r14, %rdx
callq 0x174a2
movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000
movq %r13, %rcx
andq %rax, %rcx
movq %r13, %rbp
movq %r12, %r14
jmp 0x35d78
movq %rdx, %r13
cmpl $0x6, %r13d
je 0x35d60
cmpl $0x1, %ebx
pushq $0x47
popq %rax
pushq $0x16
popq %rcx
cmovel %eax, %ecx
testl %ebx, %ebx
pushq $0x49
popq %rsi
cmovnel %ecx, %esi
movq %r15, %rdi
callq 0x19e14
leaq 0x18(%rsp), %rbx
movq %rax, (%rbx)
movq %rdx, 0x8(%rbx)
movq %rbx, (%rsp)
pushq $0x1
popq %r9
movq %r15, %rdi
movq %r12, %rsi
movq %r13, %rdx
movq 0x10(%rsp), %rbp
movq %rbp, %rcx
movq %r14, %r8
callq 0x1c212
movq %rax, %r13
movq %rdx, %r12
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
movq %r15, %rdi
callq 0x174a2
movl %r12d, %ebx
cmpq $0x6, %rbx
je 0x35d60
movq %r15, %rdi
movq %rbp, %rsi
movq %r14, %rdx
callq 0x174a2
cmpl $-0x1, %ebx
jne 0x35c82
movq %r15, %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x174a2
leaq 0x4ecce(%rip), %rsi # 0x84a0b
xorl %ebp, %ebp
movq %r15, %rdi
xorl %eax, %eax
callq 0x1bad1
pushq $0x6
popq %r14
jmp 0x35d76
leaq 0x4ecb5(%rip), %rsi # 0x84a0b
movq %r15, %rdi
xorl %eax, %eax
callq 0x1bad1
movq %r15, %rdi
movq 0x10(%rsp), %rsi
movq %r14, %rdx
callq 0x174a2
pushq $0x6
popq %r14
xorl %ebp, %ebp
xorl %ecx, %ecx
movl %ebp, %eax
orq %rcx, %rax
movq %r14, %rdx
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
JS_ToPrimitiveFree:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r14, rdx
mov rbp, rsi
cmp r14d, 0FFFFFFFFh
jnz loc_35C56
mov r15, rdi
mov ebx, ecx
and ebx, 0FFFFFFEFh
test cl, 10h
mov [rsp+58h+var_48], rbp
jnz short loc_35BC4
mov rdi, r15
mov rsi, rbp
mov rdx, r14
mov ecx, 0D3h
call JS_GetProperty
mov r12, rax
lea eax, [rdx-2]
cmp eax, 2
jnb loc_35C9D
loc_35BC4:
xor ebp, ebp
test ebx, ebx
setnz bpl
xor ebx, ebx
loc_35BCE:
cmp ebx, 2
jz loc_35D4F
xor eax, eax
cmp ebp, ebx
setnz al
lea ecx, ds:38h[rax*2]
mov rdi, r15
mov rsi, [rsp+58h+var_48]
mov rdx, r14
call JS_GetProperty
mov r12, rdx
cmp r12d, 6
jz loc_35D60
mov r13, rax
mov rdi, r15
mov rsi, rax
mov rdx, r12
call JS_IsFunction
test eax, eax
jz short loc_35C41
and [rsp+58h+var_58], 0
mov rdi, r15
mov rsi, r13
mov rdx, r12
mov rcx, [rsp+58h+var_48]
mov r8, r14
xor r9d, r9d
call JS_CallFree
mov r13, rax
mov r12, rdx
cmp r12d, 0FFFFFFFFh
jnz short loc_35C68
loc_35C41:
mov rdi, r15
mov rsi, r13
mov rdx, r12
call JS_FreeValue
inc ebx
jmp loc_35BCE
loc_35C56:
mov rcx, 0FFFFFFFF00000000h
and rcx, rbp
jmp loc_35D78
loc_35C68:
cmp r12d, 6
jz loc_35D60
mov rdi, r15
mov rsi, [rsp+58h+var_48]
mov rdx, r14
call JS_FreeValue
loc_35C82:
mov rax, 0FFFFFFFF00000000h
mov rcx, r13
and rcx, rax
mov rbp, r13
mov r14, r12
jmp loc_35D78
loc_35C9D:
mov r13, rdx
cmp r13d, 6
jz loc_35D60
cmp ebx, 1
push 47h ; 'G'
pop rax
push 16h
pop rcx
cmovz ecx, eax
test ebx, ebx
push 49h ; 'I'
pop rsi
cmovnz esi, ecx
mov rdi, r15
call JS_AtomToString
lea rbx, [rsp+58h+var_40]
mov [rbx], rax
mov [rbx+8], rdx
mov [rsp+58h+var_58], rbx
push 1
pop r9
mov rdi, r15
mov rsi, r12
mov rdx, r13
mov rbp, [rsp+58h+var_48]
mov rcx, rbp
mov r8, r14
call JS_CallFree
mov r13, rax
mov r12, rdx
mov rsi, [rbx]
mov rdx, [rbx+8]
mov rdi, r15
call JS_FreeValue
mov ebx, r12d
cmp rbx, 6
jz short loc_35D60
mov rdi, r15
mov rsi, rbp
mov rdx, r14
call JS_FreeValue
cmp ebx, 0FFFFFFFFh
jnz loc_35C82
mov rdi, r15
mov rsi, r13
mov rdx, r12
call JS_FreeValue
lea rsi, aToprimitive; "toPrimitive"
xor ebp, ebp
mov rdi, r15
xor eax, eax
call JS_ThrowTypeError
push 6
pop r14
jmp short loc_35D76
loc_35D4F:
lea rsi, aToprimitive; "toPrimitive"
mov rdi, r15
xor eax, eax
call JS_ThrowTypeError
loc_35D60:
mov rdi, r15
mov rsi, [rsp+58h+var_48]
mov rdx, r14
call JS_FreeValue
push 6
pop r14
xor ebp, ebp
loc_35D76:
xor ecx, ecx
loc_35D78:
mov eax, ebp
or rax, rcx
mov rdx, r14
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
unsigned long long JS_ToPrimitiveFree(
long long a1,
long long a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14)
{
unsigned int v15; // ebp
int v16; // ebx
long long v17; // r12
int v18; // ebp
int i; // ebx
long long Property; // rax
long long v21; // rdx
long long v22; // r12
long long v23; // r13
long long v24; // rdx
unsigned long long v25; // rcx
long long v26; // r13
int v27; // ecx
int v28; // esi
long long v29; // rdx
long long v30; // rdx
long long v31; // r12
long long v32; // rdx
long long v33; // rcx
long long v34; // r8
long long v35; // r9
__m128 v36; // xmm4
__m128 v37; // xmm5
char v39; // [rsp+0h] [rbp-58h]
char v40; // [rsp+0h] [rbp-58h]
long long v42; // [rsp+18h] [rbp-40h] BYREF
long long v43; // [rsp+20h] [rbp-38h]
v15 = a2;
if ( (_DWORD)a3 == -1 )
{
v16 = a4 & 0xFFFFFFEF;
if ( (a4 & 0x10) != 0 || (v17 = JS_GetProperty(a1, a2, -1, 211), (unsigned int)(a3 - 2) < 2) )
{
v18 = v16 != 0;
for ( i = 0; ; ++i )
{
if ( i == 2 )
{
JS_ThrowTypeError(a1, (long long)"toPrimitive", a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v39);
goto LABEL_23;
}
Property = JS_GetProperty(a1, a2, a3, 2 * (unsigned int)(v18 != i) + 56);
v22 = v21;
if ( (_DWORD)v21 == 6 )
goto LABEL_23;
v23 = Property;
if ( (unsigned int)JS_IsFunction(a1, Property, v21) )
{
v23 = JS_CallFree(a1, v23, v22, a2, a3, 0, 0LL);
v22 = v24;
if ( (_DWORD)v24 != -1 )
break;
}
JS_FreeValue(a1, v23, v22);
}
if ( (_DWORD)v24 == 6 )
goto LABEL_23;
JS_FreeValue(a1, a2, a3);
goto LABEL_13;
}
v26 = a3;
if ( (_DWORD)a3 == 6 )
goto LABEL_23;
v27 = 22;
if ( v16 == 1 )
v27 = 71;
v28 = 73;
if ( v16 )
v28 = v27;
v42 = JS_AtomToString(a1, v28);
v43 = v29;
v23 = JS_CallFree(a1, v17, v26, a2, a3, 1, (long long)&v42);
v31 = v30;
JS_FreeValue(a1, v42, v43);
if ( (unsigned int)v31 == 6LL )
{
LABEL_23:
JS_FreeValue(a1, a2, a3);
v15 = 0;
}
else
{
JS_FreeValue(a1, a2, a3);
if ( (_DWORD)v31 != -1 )
{
LABEL_13:
v25 = v23 & 0xFFFFFFFF00000000LL;
v15 = v23;
return v25 | v15;
}
JS_FreeValue(a1, v23, v31);
v15 = 0;
JS_ThrowTypeError(a1, (long long)"toPrimitive", v32, v33, v34, v35, a7, a8, a9, a10, v36, v37, a13, a14, v40);
}
v25 = 0LL;
return v25 | v15;
}
v25 = a2 & 0xFFFFFFFF00000000LL;
return v25 | v15;
}
|
JS_ToPrimitiveFree:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R14,RDX
MOV RBP,RSI
CMP R14D,-0x1
JNZ 0x00135c56
MOV R15,RDI
MOV EBX,ECX
AND EBX,0xffffffef
TEST CL,0x10
MOV qword ptr [RSP + 0x10],RBP
JNZ 0x00135bc4
MOV RDI,R15
MOV RSI,RBP
MOV RDX,R14
MOV ECX,0xd3
CALL 0x0011a4c7
MOV R12,RAX
LEA EAX,[RDX + -0x2]
CMP EAX,0x2
JNC 0x00135c9d
LAB_00135bc4:
XOR EBP,EBP
TEST EBX,EBX
SETNZ BPL
XOR EBX,EBX
LAB_00135bce:
CMP EBX,0x2
JZ 0x00135d4f
XOR EAX,EAX
CMP EBP,EBX
SETNZ AL
LEA ECX,[0x38 + RAX*0x2]
MOV RDI,R15
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,R14
CALL 0x0011a4c7
MOV R12,RDX
CMP R12D,0x6
JZ 0x00135d60
MOV R13,RAX
MOV RDI,R15
MOV RSI,RAX
MOV RDX,R12
CALL 0x0011c301
TEST EAX,EAX
JZ 0x00135c41
AND qword ptr [RSP],0x0
MOV RDI,R15
MOV RSI,R13
MOV RDX,R12
MOV RCX,qword ptr [RSP + 0x10]
MOV R8,R14
XOR R9D,R9D
CALL 0x0011c212
MOV R13,RAX
MOV R12,RDX
CMP R12D,-0x1
JNZ 0x00135c68
LAB_00135c41:
MOV RDI,R15
MOV RSI,R13
MOV RDX,R12
CALL 0x001174a2
INC EBX
JMP 0x00135bce
LAB_00135c56:
MOV RCX,-0x100000000
AND RCX,RBP
JMP 0x00135d78
LAB_00135c68:
CMP R12D,0x6
JZ 0x00135d60
MOV RDI,R15
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,R14
CALL 0x001174a2
LAB_00135c82:
MOV RAX,-0x100000000
MOV RCX,R13
AND RCX,RAX
MOV RBP,R13
MOV R14,R12
JMP 0x00135d78
LAB_00135c9d:
MOV R13,RDX
CMP R13D,0x6
JZ 0x00135d60
CMP EBX,0x1
PUSH 0x47
POP RAX
PUSH 0x16
POP RCX
CMOVZ ECX,EAX
TEST EBX,EBX
PUSH 0x49
POP RSI
CMOVNZ ESI,ECX
MOV RDI,R15
CALL 0x00119e14
LEA RBX,[RSP + 0x18]
MOV qword ptr [RBX],RAX
MOV qword ptr [RBX + 0x8],RDX
MOV qword ptr [RSP],RBX
PUSH 0x1
POP R9
MOV RDI,R15
MOV RSI,R12
MOV RDX,R13
MOV RBP,qword ptr [RSP + 0x10]
MOV RCX,RBP
MOV R8,R14
CALL 0x0011c212
MOV R13,RAX
MOV R12,RDX
MOV RSI,qword ptr [RBX]
MOV RDX,qword ptr [RBX + 0x8]
MOV RDI,R15
CALL 0x001174a2
MOV EBX,R12D
CMP RBX,0x6
JZ 0x00135d60
MOV RDI,R15
MOV RSI,RBP
MOV RDX,R14
CALL 0x001174a2
CMP EBX,-0x1
JNZ 0x00135c82
MOV RDI,R15
MOV RSI,R13
MOV RDX,R12
CALL 0x001174a2
LEA RSI,[0x184a0b]
XOR EBP,EBP
MOV RDI,R15
XOR EAX,EAX
CALL 0x0011bad1
PUSH 0x6
POP R14
JMP 0x00135d76
LAB_00135d4f:
LEA RSI,[0x184a0b]
MOV RDI,R15
XOR EAX,EAX
CALL 0x0011bad1
LAB_00135d60:
MOV RDI,R15
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,R14
CALL 0x001174a2
PUSH 0x6
POP R14
XOR EBP,EBP
LAB_00135d76:
XOR ECX,ECX
LAB_00135d78:
MOV EAX,EBP
OR RAX,RCX
MOV RDX,R14
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int1 [16]
JS_ToPrimitiveFree(int8 param_1,ulong param_2,int8 param_3,uint param_4)
{
int8 uVar1;
int8 uVar2;
int iVar3;
uint uVar4;
int1 auVar5 [16];
int1 auVar6 [16];
int1 local_40 [16];
auVar5._8_8_ = param_3;
auVar5._0_8_ = param_2;
if ((int)param_3 != -1) {
param_2 = param_2 & 0xffffffff00000000;
goto LAB_00135d78;
}
if ((param_4 & 0x10) == 0) {
auVar5 = JS_GetProperty(param_1,param_2,param_3,0xd3);
if (auVar5._8_4_ - 2U < 2) goto LAB_00135bc4;
if (auVar5._8_4_ == 6) goto LAB_00135d60;
uVar1 = 0x16;
if ((param_4 & 0xffffffef) == 1) {
uVar1 = 0x47;
}
uVar2 = 0x49;
if ((param_4 & 0xffffffef) != 0) {
uVar2 = uVar1;
}
local_40 = JS_AtomToString(param_1,uVar2);
auVar5 = JS_CallFree(param_1,auVar5._0_8_,auVar5._8_8_,param_2,param_3,1,local_40);
JS_FreeValue(param_1,local_40._0_8_,local_40._8_8_);
if ((auVar5._8_8_ & 0xffffffff) == 6) goto LAB_00135d60;
JS_FreeValue(param_1,param_2,param_3);
if (auVar5._8_4_ != -1) {
LAB_00135c82:
param_2 = auVar5._0_8_ & 0xffffffff00000000;
goto LAB_00135d78;
}
JS_FreeValue(param_1,auVar5._0_8_,auVar5._8_8_);
JS_ThrowTypeError(param_1,"toPrimitive");
}
else {
LAB_00135bc4:
for (uVar4 = 0; uVar4 != 2; uVar4 = uVar4 + 1) {
auVar5 = JS_GetProperty(param_1,param_2,param_3,
(((param_4 & 0xffffffef) != 0) != uVar4) * '\x02' + '8');
if (auVar5._8_4_ == 6) goto LAB_00135d60;
iVar3 = JS_IsFunction(param_1,auVar5._0_8_,auVar5._8_8_);
if (iVar3 != 0) {
auVar5 = JS_CallFree(param_1,auVar5._0_8_,auVar5._8_8_,param_2,param_3,0,0);
if (auVar5._8_4_ != -1) {
if (auVar5._8_4_ == 6) goto LAB_00135d60;
JS_FreeValue(param_1,param_2,param_3);
goto LAB_00135c82;
}
}
JS_FreeValue(param_1,auVar5._0_8_,auVar5._8_8_);
}
JS_ThrowTypeError(param_1,"toPrimitive");
LAB_00135d60:
JS_FreeValue(param_1,param_2,param_3);
}
auVar5 = ZEXT816(6) << 0x40;
param_2 = 0;
LAB_00135d78:
auVar6._0_8_ = auVar5._0_8_ & 0xffffffff | param_2;
auVar6._8_8_ = auVar5._8_8_;
return auVar6;
}
|
|
7,825 |
JS_ToPrimitiveFree
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue JS_ToPrimitiveFree(JSContext *ctx, JSValue val, int hint)
{
int i;
BOOL force_ordinary;
JSAtom method_name;
JSValue method, ret;
if (JS_VALUE_GET_TAG(val) != JS_TAG_OBJECT)
return val;
force_ordinary = hint & HINT_FORCE_ORDINARY;
hint &= ~HINT_FORCE_ORDINARY;
if (!force_ordinary) {
method = JS_GetProperty(ctx, val, JS_ATOM_Symbol_toPrimitive);
if (JS_IsException(method))
goto exception;
/* ECMA says *If exoticToPrim is not undefined* but tests in
test262 use null as a non callable converter */
if (!JS_IsUndefined(method) && !JS_IsNull(method)) {
JSAtom atom;
JSValue arg;
switch(hint) {
case HINT_STRING:
atom = JS_ATOM_string;
break;
case HINT_NUMBER:
atom = JS_ATOM_number;
break;
default:
case HINT_NONE:
atom = JS_ATOM_default;
break;
}
arg = JS_AtomToString(ctx, atom);
ret = JS_CallFree(ctx, method, val, 1, &arg);
JS_FreeValue(ctx, arg);
if (JS_IsException(ret))
goto exception;
JS_FreeValue(ctx, val);
if (JS_VALUE_GET_TAG(ret) != JS_TAG_OBJECT)
return ret;
JS_FreeValue(ctx, ret);
return JS_ThrowTypeError(ctx, "toPrimitive");
}
}
if (hint != HINT_STRING)
hint = HINT_NUMBER;
for(i = 0; i < 2; i++) {
if ((i ^ hint) == 0) {
method_name = JS_ATOM_toString;
} else {
method_name = JS_ATOM_valueOf;
}
method = JS_GetProperty(ctx, val, method_name);
if (JS_IsException(method))
goto exception;
if (JS_IsFunction(ctx, method)) {
ret = JS_CallFree(ctx, method, val, 0, NULL);
if (JS_IsException(ret))
goto exception;
if (JS_VALUE_GET_TAG(ret) != JS_TAG_OBJECT) {
JS_FreeValue(ctx, val);
return ret;
}
JS_FreeValue(ctx, ret);
} else {
JS_FreeValue(ctx, method);
}
}
JS_ThrowTypeError(ctx, "toPrimitive");
exception:
JS_FreeValue(ctx, val);
return JS_EXCEPTION;
}
|
O3
|
c
|
JS_ToPrimitiveFree:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, 0x28(%rsp)
cmpl $-0x1, %ebx
jne 0x3ebf0
movl %ecx, %ebp
andl $-0x11, %ebp
testb $0x10, %cl
jne 0x3ea4f
movl $0x0, 0x8(%rsp)
movq $0x0, (%rsp)
movq 0x28(%rsp), %rdi
movq %r15, %rsi
movq %rbx, %rdx
movl $0xd3, %ecx
movq %r15, %r8
movq %rbx, %r9
callq 0x22c0f
movq %rax, %r12
leal -0x2(%rdx), %eax
cmpl $0x2, %eax
jae 0x3ec08
xorl %r13d, %r13d
testl %ebp, %ebp
setne %r13b
xorl %eax, %eax
movb $0x1, %r14b
movl %r13d, 0x34(%rsp)
xorl %ecx, %ecx
cmpl %r13d, %eax
setne %cl
leal 0x38(,%rcx,2), %ecx
movl $0x0, 0x8(%rsp)
movq $0x0, (%rsp)
movq 0x28(%rsp), %rdi
movq %r15, %rsi
movq %rbx, %rdx
movq %r15, %r8
movq %rbx, %r9
callq 0x22c0f
movq %rax, %r12
movq %rdx, %rbp
movl %ebp, %eax
cmpq $0x6, %rax
je 0x3ed2c
cmpl $-0x1, %eax
jne 0x3eb9a
movzwl 0x6(%r12), %eax
cmpl $0xd, %eax
je 0x3eaf4
cmpl $0x30, %eax
jne 0x3eacd
movq 0x30(%r12), %rax
movzbl 0x20(%rax), %eax
jmp 0x3eaec
movq 0x28(%rsp), %rcx
movq 0x18(%rcx), %rcx
movq 0x80(%rcx), %rcx
leaq (%rax,%rax,4), %rdx
xorl %eax, %eax
cmpq $0x0, 0x18(%rcx,%rdx,8)
setne %al
testl %eax, %eax
je 0x3eb9a
movq %rbx, %r8
movq %r15, %rcx
movl $0x0, 0x38(%rsp)
movq $0x3, 0x40(%rsp)
movups 0x38(%rsp), %xmm0
movups %xmm0, (%rsp)
movl $0x2, 0x18(%rsp)
movq $0x0, 0x10(%rsp)
movq 0x28(%rsp), %r13
movq %r13, %rdi
movq %r12, %rsi
movq %rbp, %rdx
xorl %r9d, %r9d
callq 0x27eca
movq %rax, %r9
movq %rdx, %r8
movq 0x18(%r13), %rdi
movl (%r12), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%r12)
cmpl $0x1, %eax
jg 0x3eb6c
movq %r12, %rsi
movq %rbp, %rdx
movq %r8, %r12
movq %r9, %r13
callq 0x20d90
movq %r13, %r9
movq %r12, %r8
cmpl $-0x1, %r8d
jne 0x3ed26
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rdi
movl (%r9), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%r9)
cmpl $0x1, %eax
movl 0x34(%rsp), %r13d
jg 0x3ebc3
movq %r9, %rsi
movq %r8, %rdx
jmp 0x3ebbe
cmpl $-0x9, %ebp
jb 0x3ebc3
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rdi
movl (%r12), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%r12)
cmpl $0x1, %eax
jg 0x3ebc3
movq %r12, %rsi
movq %rbp, %rdx
callq 0x20d90
movl $0x1, %eax
testb $0x1, %r14b
movl $0x0, %r14d
jne 0x3ea62
leaq 0x61e9c(%rip), %rsi # 0xa0a7b
movq 0x28(%rsp), %rdi
xorl %eax, %eax
callq 0x2214f
jmp 0x3ed2c
movabsq $-0x100000000, %rcx # imm = 0xFFFFFFFF00000000
andq %r15, %rcx
movq %r15, %r9
movq %rbx, %r8
jmp 0x3ed5f
movq %rdx, %r13
cmpl $0x6, %r13d
je 0x3ed2c
cmpl $0x1, %ebp
movl $0x47, %eax
movl $0x16, %ecx
cmovel %eax, %ecx
testl %ebp, %ebp
movl $0x49, %esi
cmovnel %ecx, %esi
movq 0x28(%rsp), %rbp
movq %rbp, %rdi
movl $0x1, %edx
callq 0x20277
leaq 0x38(%rsp), %r14
movq %rax, (%r14)
movq %rdx, 0x8(%r14)
movq %r14, (%rsp)
movq %rbp, %rdi
movq %r12, %rsi
movq %r13, %rdx
movq %r15, %rcx
movq %rbx, %r8
movl $0x1, %r9d
callq 0x228ab
movq %rax, %r9
movq %rdx, %r8
movq 0x8(%r14), %rdx
cmpl $-0x9, %edx
jb 0x3eca5
movq 0x38(%rsp), %rsi
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rdi
movl (%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%rsi)
cmpl $0x1, %eax
jg 0x3eca5
movq %r8, %r14
movq %r9, %r12
callq 0x20d90
movq %r12, %r9
movq %r14, %r8
movl %r8d, %r14d
cmpq $0x6, %r14
je 0x3ed2c
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rdi
movl (%r15), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%r15)
cmpl $0x1, %eax
jg 0x3ecdc
movq %r15, %rsi
movq %rbx, %rdx
movq %r8, %rbx
movq %r9, %r15
callq 0x20d90
movq %r15, %r9
movq %rbx, %r8
cmpl $-0x1, %r14d
jne 0x3eda5
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rdi
movl (%r9), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%r9)
cmpl $0x1, %eax
jg 0x3ed08
movq %r9, %rsi
movq %r8, %rdx
callq 0x20d90
leaq 0x61d6c(%rip), %rsi # 0xa0a7b
movq 0x28(%rsp), %rdi
xorl %eax, %eax
callq 0x2214f
xorl %r9d, %r9d
movl $0x6, %r8d
jmp 0x3ed5d
cmpl $0x6, %r8d
jne 0x3ed77
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rdi
movl (%r15), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%r15)
movl $0x6, %r8d
cmpl $0x1, %eax
jg 0x3ed5a
movq %r15, %rsi
movq %rbx, %rdx
callq 0x20d90
movl $0x6, %r8d
xorl %r9d, %r9d
xorl %ecx, %ecx
movl %r9d, %eax
orq %rcx, %rax
movq %r8, %rdx
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rdi
movl (%r15), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%r15)
cmpl $0x1, %eax
jg 0x3eda5
movq %r15, %rsi
movq %rbx, %rdx
movq %r8, %rbx
movq %r9, %r14
callq 0x20d90
movq %r14, %r9
movq %rbx, %r8
movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000
movq %r9, %rcx
andq %rax, %rcx
jmp 0x3ed5f
|
JS_ToPrimitiveFree:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov rbx, rdx
mov r15, rsi
mov [rsp+78h+var_50], rdi
cmp ebx, 0FFFFFFFFh
jnz loc_3EBF0
mov ebp, ecx
and ebp, 0FFFFFFEFh
test cl, 10h
jnz short loc_3EA4F
mov dword ptr [rsp+78h+var_78+8], 0
mov qword ptr [rsp+78h+var_78], 0
mov rdi, [rsp+78h+var_50]
mov rsi, r15
mov rdx, rbx
mov ecx, 0D3h
mov r8, r15
mov r9, rbx
call JS_GetPropertyInternal2
mov r12, rax
lea eax, [rdx-2]
cmp eax, 2
jnb loc_3EC08
loc_3EA4F:
xor r13d, r13d
test ebp, ebp
setnz r13b
xor eax, eax
mov r14b, 1
mov [rsp+78h+var_44], r13d
loc_3EA62:
xor ecx, ecx
cmp eax, r13d
setnz cl
lea ecx, ds:38h[rcx*2]
mov dword ptr [rsp+78h+var_78+8], 0
mov qword ptr [rsp+78h+var_78], 0
mov rdi, [rsp+78h+var_50]
mov rsi, r15
mov rdx, rbx
mov r8, r15
mov r9, rbx
call JS_GetPropertyInternal2
mov r12, rax
mov rbp, rdx
mov eax, ebp
cmp rax, 6
jz loc_3ED2C
cmp eax, 0FFFFFFFFh
jnz loc_3EB9A
movzx eax, word ptr [r12+6]
cmp eax, 0Dh
jz short loc_3EAF4
cmp eax, 30h ; '0'
jnz short loc_3EACD
mov rax, [r12+30h]
movzx eax, byte ptr [rax+20h]
jmp short loc_3EAEC
loc_3EACD:
mov rcx, [rsp+78h+var_50]
mov rcx, [rcx+18h]
mov rcx, [rcx+80h]
lea rdx, [rax+rax*4]
xor eax, eax
cmp qword ptr [rcx+rdx*8+18h], 0
setnz al
loc_3EAEC:
test eax, eax
jz loc_3EB9A
loc_3EAF4:
mov r8, rbx
mov rcx, r15
mov dword ptr [rsp+78h+var_40], 0
mov qword ptr [rsp+78h+var_40+8], 3
movups xmm0, [rsp+78h+var_40]
movups [rsp+78h+var_78], xmm0
mov [rsp+78h+var_60], 2
mov [rsp+78h+var_68], 0
mov r13, [rsp+78h+var_50]
mov rdi, r13
mov rsi, r12
mov rdx, rbp
xor r9d, r9d
call JS_CallInternal
mov r9, rax
mov r8, rdx
mov rdi, [r13+18h]
mov eax, [r12]
lea ecx, [rax-1]
mov [r12], ecx
cmp eax, 1
jg short loc_3EB6C
mov rsi, r12
mov rdx, rbp
mov r12, r8
mov r13, r9
call js_free_value_rt
mov r9, r13
mov r8, r12
loc_3EB6C:
cmp r8d, 0FFFFFFFFh
jnz loc_3ED26
mov rax, [rsp+78h+var_50]
mov rdi, [rax+18h]
mov eax, [r9]
lea ecx, [rax-1]
mov [r9], ecx
cmp eax, 1
mov r13d, [rsp+78h+var_44]
jg short loc_3EBC3
mov rsi, r9
mov rdx, r8
jmp short loc_3EBBE
loc_3EB9A:
cmp ebp, 0FFFFFFF7h
jb short loc_3EBC3
mov rax, [rsp+78h+var_50]
mov rdi, [rax+18h]
mov eax, [r12]
lea ecx, [rax-1]
mov [r12], ecx
cmp eax, 1
jg short loc_3EBC3
mov rsi, r12
mov rdx, rbp
loc_3EBBE:
call js_free_value_rt
loc_3EBC3:
mov eax, 1
test r14b, 1
mov r14d, 0
jnz loc_3EA62
lea rsi, aToprimitive; "toPrimitive"
mov rdi, [rsp+78h+var_50]
xor eax, eax
call JS_ThrowTypeError
jmp loc_3ED2C
loc_3EBF0:
mov rcx, 0FFFFFFFF00000000h
and rcx, r15
mov r9, r15
mov r8, rbx
jmp loc_3ED5F
loc_3EC08:
mov r13, rdx
cmp r13d, 6
jz loc_3ED2C
cmp ebp, 1
mov eax, 47h ; 'G'
mov ecx, 16h
cmovz ecx, eax
test ebp, ebp
mov esi, 49h ; 'I'
cmovnz esi, ecx
mov rbp, [rsp+78h+var_50]
mov rdi, rbp
mov edx, 1
call __JS_AtomToValue
lea r14, [rsp+78h+var_40]
mov [r14], rax
mov [r14+8], rdx
mov qword ptr [rsp+78h+var_78], r14
mov rdi, rbp
mov rsi, r12
mov rdx, r13
mov rcx, r15
mov r8, rbx
mov r9d, 1
call JS_CallFree
mov r9, rax
mov r8, rdx
mov rdx, [r14+8]
cmp edx, 0FFFFFFF7h
jb short loc_3ECA5
mov rsi, qword ptr [rsp+78h+var_40]
mov rax, [rsp+78h+var_50]
mov rdi, [rax+18h]
mov eax, [rsi]
lea ecx, [rax-1]
mov [rsi], ecx
cmp eax, 1
jg short loc_3ECA5
mov r14, r8
mov r12, r9
call js_free_value_rt
mov r9, r12
mov r8, r14
loc_3ECA5:
mov r14d, r8d
cmp r14, 6
jz short loc_3ED2C
mov rax, [rsp+78h+var_50]
mov rdi, [rax+18h]
mov eax, [r15]
lea ecx, [rax-1]
mov [r15], ecx
cmp eax, 1
jg short loc_3ECDC
mov rsi, r15
mov rdx, rbx
mov rbx, r8
mov r15, r9
call js_free_value_rt
mov r9, r15
mov r8, rbx
loc_3ECDC:
cmp r14d, 0FFFFFFFFh
jnz loc_3EDA5
mov rax, [rsp+78h+var_50]
mov rdi, [rax+18h]
mov eax, [r9]
lea ecx, [rax-1]
mov [r9], ecx
cmp eax, 1
jg short loc_3ED08
mov rsi, r9
mov rdx, r8
call js_free_value_rt
loc_3ED08:
lea rsi, aToprimitive; "toPrimitive"
mov rdi, [rsp+78h+var_50]
xor eax, eax
call JS_ThrowTypeError
xor r9d, r9d
mov r8d, 6
jmp short loc_3ED5D
loc_3ED26:
cmp r8d, 6
jnz short loc_3ED77
loc_3ED2C:
mov rax, [rsp+78h+var_50]
mov rdi, [rax+18h]
mov eax, [r15]
lea ecx, [rax-1]
mov [r15], ecx
mov r8d, 6
cmp eax, 1
jg short loc_3ED5A
mov rsi, r15
mov rdx, rbx
call js_free_value_rt
mov r8d, 6
loc_3ED5A:
xor r9d, r9d
loc_3ED5D:
xor ecx, ecx
loc_3ED5F:
mov eax, r9d
or rax, rcx
mov rdx, r8
add rsp, 48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3ED77:
mov rax, [rsp+78h+var_50]
mov rdi, [rax+18h]
mov eax, [r15]
lea ecx, [rax-1]
mov [r15], ecx
cmp eax, 1
jg short loc_3EDA5
mov rsi, r15
mov rdx, rbx
mov rbx, r8
mov r14, r9
call js_free_value_rt
mov r9, r14
mov r8, rbx
loc_3EDA5:
mov rax, 0FFFFFFFF00000000h
mov rcx, r9
and rcx, rax
jmp short loc_3ED5F
|
unsigned long long JS_ToPrimitiveFree(
long long a1,
long long a2,
long long a3,
int a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
double a9,
double a10,
__m128 a11,
__m128 a12)
{
unsigned int v14; // ebp
long long v15; // rdx
long long v16; // r9
_QWORD *v17; // r12
int v18; // r13d
int v19; // eax
char v20; // r14
long long v21; // rdx
long long v22; // rcx
long long v23; // r8
unsigned long long PropertyInternal2; // r12
__m128 v25; // xmm4
__m128 v26; // xmm5
long long v27; // rbp
long long v28; // rax
int v29; // eax
long long v30; // rdi
int v31; // eax
long long v32; // rcx
_QWORD *v33; // rsi
long long v34; // r12
long long v35; // r13
long long v36; // rdi
int v37; // eax
_QWORD *v38; // rsi
long long v39; // rdx
int v40; // eax
bool v41; // zf
unsigned long long v42; // rcx
long long v43; // r13
int v44; // ecx
int v45; // esi
__m128i v46; // rax
__m128 v47; // xmm4
__m128 v48; // xmm5
long long v49; // rdx
long long v50; // r8
long long v51; // rdx
_QWORD *v52; // rsi
long long v53; // rdi
int v54; // eax
long long v55; // rcx
long long v56; // r14
long long v57; // r12
int v58; // r14d
long long v59; // rdi
int v60; // eax
long long v61; // rcx
_QWORD *v62; // rsi
long long v63; // rdx
long long v64; // rbx
long long v65; // r15
long long v66; // rdi
int v67; // eax
long long v68; // rcx
long long v69; // rdi
int v70; // eax
long long v71; // rcx
long long v73; // rdi
int v74; // eax
long long v75; // rcx
long long v76; // r14
char v77; // [rsp+0h] [rbp-78h]
char v78; // [rsp+0h] [rbp-78h]
int v80; // [rsp+34h] [rbp-44h]
__m128 v81; // [rsp+38h] [rbp-40h] BYREF
if ( (_DWORD)a3 == -1 )
{
v14 = a4 & 0xFFFFFFEF;
if ( (a4 & 0x10) != 0
|| (v17 = (_QWORD *)JS_GetPropertyInternal2(a1, a2, -1, 0xD3u, a2, a3, 0LL, 0), (unsigned int)(v15 - 2) < 2) )
{
v18 = v14 != 0;
v19 = 0;
v20 = 1;
v80 = v18;
while ( 1 )
{
PropertyInternal2 = JS_GetPropertyInternal2(a1, a2, a3, 2 * (unsigned int)(v19 != v18) + 56, a2, a3, 0LL, 0);
v27 = v21;
if ( (unsigned int)v21 == 6LL )
goto LABEL_40;
if ( (_DWORD)v21 != -1 )
break;
v28 = *(unsigned __int16 *)(PropertyInternal2 + 6);
if ( (_DWORD)v28 != 13 )
{
if ( (_DWORD)v28 == 48 )
{
v29 = *(unsigned __int8 *)(*(_QWORD *)(PropertyInternal2 + 48) + 32LL);
}
else
{
v22 = *(_QWORD *)(*(_QWORD *)(a1 + 24) + 128LL);
v21 = 5 * v28;
v29 = *(_QWORD *)(v22 + 40 * v28 + 24) != 0LL;
}
if ( !v29 )
break;
}
v81.m128_i32[0] = 0;
v81.m128_u64[1] = 3LL;
a5 = v81;
v16 = JS_CallInternal(
a1,
PropertyInternal2,
v27,
a2,
a3,
0LL,
(__m128i)v81,
a6,
a7,
a8,
v25,
v26,
a11,
a12,
0,
3,
0LL,
2u);
v23 = v21;
v30 = *(_QWORD *)(a1 + 24);
v31 = *(_DWORD *)PropertyInternal2;
v32 = (unsigned int)(*(_DWORD *)PropertyInternal2 - 1);
*(_DWORD *)PropertyInternal2 = v32;
if ( v31 <= 1 )
{
v33 = (_QWORD *)PropertyInternal2;
v34 = v21;
v35 = v16;
js_free_value_rt(v30, v33, v27, v32, v21, v16);
v16 = v35;
v23 = v34;
}
if ( (_DWORD)v23 != -1 )
{
if ( (_DWORD)v23 == 6 )
goto LABEL_40;
v73 = *(_QWORD *)(a1 + 24);
v74 = *(_DWORD *)a2;
v75 = (unsigned int)(*(_DWORD *)a2 - 1);
*(_DWORD *)a2 = v75;
if ( v74 <= 1 )
{
v76 = v16;
js_free_value_rt(v73, (_QWORD *)a2, a3, v75, v23, v16);
v16 = v76;
}
goto LABEL_47;
}
v36 = *(_QWORD *)(a1 + 24);
v37 = *(_DWORD *)v16;
v22 = (unsigned int)(*(_DWORD *)v16 - 1);
*(_DWORD *)v16 = v22;
v18 = v80;
if ( v37 <= 1 )
{
v38 = (_QWORD *)v16;
v39 = v23;
LABEL_20:
js_free_value_rt(v36, v38, v39, v22, v23, v16);
}
LABEL_21:
v19 = 1;
v41 = (v20 & 1) == 0;
v20 = 0;
if ( v41 )
{
JS_ThrowTypeError(a1, (long long)"toPrimitive", v21, v22, v23, v16, a5, a6, a7, a8, v25, v26, a11, a12, v77);
goto LABEL_40;
}
}
if ( (unsigned int)v27 < 0xFFFFFFF7 )
goto LABEL_21;
v36 = *(_QWORD *)(a1 + 24);
v40 = *(_DWORD *)PropertyInternal2;
v22 = (unsigned int)(*(_DWORD *)PropertyInternal2 - 1);
*(_DWORD *)PropertyInternal2 = v22;
if ( v40 > 1 )
goto LABEL_21;
v38 = (_QWORD *)PropertyInternal2;
v39 = v27;
goto LABEL_20;
}
v43 = v15;
if ( (_DWORD)v15 == 6 )
goto LABEL_40;
v44 = 22;
if ( v14 == 1 )
v44 = 71;
v45 = 73;
if ( v14 )
v45 = v44;
v46.m128i_i64[0] = _JS_AtomToValue(a1, v45, 1);
v81 = (__m128)v46;
v16 = JS_CallFree(a1, v17, v43, a2, a3, 1, (long long)&v81);
v50 = v49;
v51 = v81.m128_i64[1];
if ( v81.m128_i32[2] >= 0xFFFFFFF7 )
{
v52 = (_QWORD *)v81.m128_u64[0];
v53 = *(_QWORD *)(a1 + 24);
v54 = *(_DWORD *)v81.m128_u64[0];
v55 = (unsigned int)(*(_DWORD *)v81.m128_u64[0] - 1);
*(_DWORD *)v81.m128_u64[0] = v55;
if ( v54 <= 1 )
{
v56 = v50;
v57 = v16;
js_free_value_rt(v53, v52, v51, v55, v50, v16);
v16 = v57;
v50 = v56;
}
}
v58 = v50;
if ( (unsigned int)v50 == 6LL )
{
LABEL_40:
v69 = *(_QWORD *)(a1 + 24);
v70 = *(_DWORD *)a2;
v71 = (unsigned int)(*(_DWORD *)a2 - 1);
*(_DWORD *)a2 = v71;
if ( v70 <= 1 )
js_free_value_rt(v69, (_QWORD *)a2, a3, v71, 6LL, v16);
LODWORD(v16) = 0;
}
else
{
v59 = *(_QWORD *)(a1 + 24);
v60 = *(_DWORD *)a2;
v61 = (unsigned int)(*(_DWORD *)a2 - 1);
*(_DWORD *)a2 = v61;
if ( v60 <= 1 )
{
v62 = (_QWORD *)a2;
v63 = a3;
v64 = v50;
v65 = v16;
js_free_value_rt(v59, v62, v63, v61, v50, v16);
v16 = v65;
v50 = v64;
}
if ( v58 != -1 )
{
LABEL_47:
v42 = v16 & 0xFFFFFFFF00000000LL;
return v42 | (unsigned int)v16;
}
v66 = *(_QWORD *)(a1 + 24);
v67 = *(_DWORD *)v16;
v68 = (unsigned int)(*(_DWORD *)v16 - 1);
*(_DWORD *)v16 = v68;
if ( v67 <= 1 )
js_free_value_rt(v66, (_QWORD *)v16, v50, v68, v50, v16);
JS_ThrowTypeError(a1, (long long)"toPrimitive", v51, v68, v50, v16, a5, a6, a7, a8, v47, v48, a11, a12, v78);
LODWORD(v16) = 0;
}
v42 = 0LL;
}
else
{
v42 = a2 & 0xFFFFFFFF00000000LL;
LODWORD(v16) = a2;
}
return v42 | (unsigned int)v16;
}
|
JS_ToPrimitiveFree:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV RBX,RDX
MOV R15,RSI
MOV qword ptr [RSP + 0x28],RDI
CMP EBX,-0x1
JNZ 0x0013ebf0
MOV EBP,ECX
AND EBP,0xffffffef
TEST CL,0x10
JNZ 0x0013ea4f
MOV dword ptr [RSP + 0x8],0x0
MOV qword ptr [RSP],0x0
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,R15
MOV RDX,RBX
MOV ECX,0xd3
MOV R8,R15
MOV R9,RBX
CALL 0x00122c0f
MOV R12,RAX
LEA EAX,[RDX + -0x2]
CMP EAX,0x2
JNC 0x0013ec08
LAB_0013ea4f:
XOR R13D,R13D
TEST EBP,EBP
SETNZ R13B
XOR EAX,EAX
MOV R14B,0x1
MOV dword ptr [RSP + 0x34],R13D
LAB_0013ea62:
XOR ECX,ECX
CMP EAX,R13D
SETNZ CL
LEA ECX,[0x38 + RCX*0x2]
MOV dword ptr [RSP + 0x8],0x0
MOV qword ptr [RSP],0x0
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,R15
MOV RDX,RBX
MOV R8,R15
MOV R9,RBX
CALL 0x00122c0f
MOV R12,RAX
MOV RBP,RDX
MOV EAX,EBP
CMP RAX,0x6
JZ 0x0013ed2c
CMP EAX,-0x1
JNZ 0x0013eb9a
MOVZX EAX,word ptr [R12 + 0x6]
CMP EAX,0xd
JZ 0x0013eaf4
CMP EAX,0x30
JNZ 0x0013eacd
MOV RAX,qword ptr [R12 + 0x30]
MOVZX EAX,byte ptr [RAX + 0x20]
JMP 0x0013eaec
LAB_0013eacd:
MOV RCX,qword ptr [RSP + 0x28]
MOV RCX,qword ptr [RCX + 0x18]
MOV RCX,qword ptr [RCX + 0x80]
LEA RDX,[RAX + RAX*0x4]
XOR EAX,EAX
CMP qword ptr [RCX + RDX*0x8 + 0x18],0x0
SETNZ AL
LAB_0013eaec:
TEST EAX,EAX
JZ 0x0013eb9a
LAB_0013eaf4:
MOV R8,RBX
MOV RCX,R15
MOV dword ptr [RSP + 0x38],0x0
MOV qword ptr [RSP + 0x40],0x3
MOVUPS XMM0,xmmword ptr [RSP + 0x38]
MOVUPS xmmword ptr [RSP],XMM0
MOV dword ptr [RSP + 0x18],0x2
MOV qword ptr [RSP + 0x10],0x0
MOV R13,qword ptr [RSP + 0x28]
MOV RDI,R13
MOV RSI,R12
MOV RDX,RBP
XOR R9D,R9D
CALL 0x00127eca
MOV R9,RAX
MOV R8,RDX
MOV RDI,qword ptr [R13 + 0x18]
MOV EAX,dword ptr [R12]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R12],ECX
CMP EAX,0x1
JG 0x0013eb6c
MOV RSI,R12
MOV RDX,RBP
MOV R12,R8
MOV R13,R9
CALL 0x00120d90
MOV R9,R13
MOV R8,R12
LAB_0013eb6c:
CMP R8D,-0x1
JNZ 0x0013ed26
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
MOV EAX,dword ptr [R9]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R9],ECX
CMP EAX,0x1
MOV R13D,dword ptr [RSP + 0x34]
JG 0x0013ebc3
MOV RSI,R9
MOV RDX,R8
JMP 0x0013ebbe
LAB_0013eb9a:
CMP EBP,-0x9
JC 0x0013ebc3
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
MOV EAX,dword ptr [R12]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R12],ECX
CMP EAX,0x1
JG 0x0013ebc3
MOV RSI,R12
MOV RDX,RBP
LAB_0013ebbe:
CALL 0x00120d90
LAB_0013ebc3:
MOV EAX,0x1
TEST R14B,0x1
MOV R14D,0x0
JNZ 0x0013ea62
LEA RSI,[0x1a0a7b]
MOV RDI,qword ptr [RSP + 0x28]
XOR EAX,EAX
CALL 0x0012214f
JMP 0x0013ed2c
LAB_0013ebf0:
MOV RCX,-0x100000000
AND RCX,R15
MOV R9,R15
MOV R8,RBX
JMP 0x0013ed5f
LAB_0013ec08:
MOV R13,RDX
CMP R13D,0x6
JZ 0x0013ed2c
CMP EBP,0x1
MOV EAX,0x47
MOV ECX,0x16
CMOVZ ECX,EAX
TEST EBP,EBP
MOV ESI,0x49
CMOVNZ ESI,ECX
MOV RBP,qword ptr [RSP + 0x28]
MOV RDI,RBP
MOV EDX,0x1
CALL 0x00120277
LEA R14,[RSP + 0x38]
MOV qword ptr [R14],RAX
MOV qword ptr [R14 + 0x8],RDX
MOV qword ptr [RSP],R14
MOV RDI,RBP
MOV RSI,R12
MOV RDX,R13
MOV RCX,R15
MOV R8,RBX
MOV R9D,0x1
CALL 0x001228ab
MOV R9,RAX
MOV R8,RDX
MOV RDX,qword ptr [R14 + 0x8]
CMP EDX,-0x9
JC 0x0013eca5
MOV RSI,qword ptr [RSP + 0x38]
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
MOV EAX,dword ptr [RSI]
LEA ECX,[RAX + -0x1]
MOV dword ptr [RSI],ECX
CMP EAX,0x1
JG 0x0013eca5
MOV R14,R8
MOV R12,R9
CALL 0x00120d90
MOV R9,R12
MOV R8,R14
LAB_0013eca5:
MOV R14D,R8D
CMP R14,0x6
JZ 0x0013ed2c
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
MOV EAX,dword ptr [R15]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R15],ECX
CMP EAX,0x1
JG 0x0013ecdc
MOV RSI,R15
MOV RDX,RBX
MOV RBX,R8
MOV R15,R9
CALL 0x00120d90
MOV R9,R15
MOV R8,RBX
LAB_0013ecdc:
CMP R14D,-0x1
JNZ 0x0013eda5
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
MOV EAX,dword ptr [R9]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R9],ECX
CMP EAX,0x1
JG 0x0013ed08
MOV RSI,R9
MOV RDX,R8
CALL 0x00120d90
LAB_0013ed08:
LEA RSI,[0x1a0a7b]
MOV RDI,qword ptr [RSP + 0x28]
XOR EAX,EAX
CALL 0x0012214f
XOR R9D,R9D
MOV R8D,0x6
JMP 0x0013ed5d
LAB_0013ed26:
CMP R8D,0x6
JNZ 0x0013ed77
LAB_0013ed2c:
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
MOV EAX,dword ptr [R15]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R15],ECX
MOV R8D,0x6
CMP EAX,0x1
JG 0x0013ed5a
MOV RSI,R15
MOV RDX,RBX
CALL 0x00120d90
MOV R8D,0x6
LAB_0013ed5a:
XOR R9D,R9D
LAB_0013ed5d:
XOR ECX,ECX
LAB_0013ed5f:
MOV EAX,R9D
OR RAX,RCX
MOV RDX,R8
ADD RSP,0x48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0013ed77:
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
MOV EAX,dword ptr [R15]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R15],ECX
CMP EAX,0x1
JG 0x0013eda5
MOV RSI,R15
MOV RDX,RBX
MOV RBX,R8
MOV R14,R9
CALL 0x00120d90
MOV R9,R14
MOV R8,RBX
LAB_0013eda5:
MOV RAX,-0x100000000
MOV RCX,R9
AND RCX,RAX
JMP 0x0013ed5f
|
int1 [16] JS_ToPrimitiveFree(long param_1,int *param_2,int8 param_3,uint param_4)
{
ushort uVar1;
int iVar2;
bool bVar3;
bool bVar4;
int *piVar5;
int8 uVar6;
ulong uVar7;
int8 uVar8;
bool bVar9;
char cVar10;
int1 auVar11 [16];
int1 auVar12 [16];
int1 local_40 [16];
auVar11._8_8_ = param_3;
auVar11._0_8_ = param_2;
if ((int)param_3 != -1) {
uVar7 = (ulong)param_2 & 0xffffffff00000000;
goto LAB_0013ed5f;
}
if ((param_4 & 0x10) == 0) {
auVar11 = JS_GetPropertyInternal2(param_1,param_2,param_3,0xd3,param_2,param_3,0,0);
if (auVar11._8_4_ - 2U < 2) goto LAB_0013ea4f;
if (auVar11._8_4_ == 6) goto LAB_0013ed2c;
uVar6 = 0x16;
if ((param_4 & 0xffffffef) == 1) {
uVar6 = 0x47;
}
uVar8 = 0x49;
if ((param_4 & 0xffffffef) != 0) {
uVar8 = uVar6;
}
local_40 = __JS_AtomToValue(param_1,uVar8,1);
auVar11 = JS_CallFree(param_1,auVar11._0_8_,auVar11._8_8_,param_2,param_3,1,local_40);
piVar5 = auVar11._0_8_;
if (0xfffffff6 < local_40._8_4_) {
uVar6 = *(int8 *)(param_1 + 0x18);
iVar2 = *(int *)local_40._0_8_;
*(int *)local_40._0_8_ = iVar2 + -1;
if (iVar2 < 2) {
js_free_value_rt(uVar6);
}
}
if ((auVar11._8_8_ & 0xffffffff) == 6) goto LAB_0013ed2c;
uVar6 = *(int8 *)(param_1 + 0x18);
iVar2 = *param_2;
*param_2 = iVar2 + -1;
if (iVar2 < 2) {
js_free_value_rt(uVar6,param_2,param_3);
}
if (auVar11._8_4_ != -1) {
LAB_0013eda5:
uVar7 = auVar11._0_8_ & 0xffffffff00000000;
goto LAB_0013ed5f;
}
uVar6 = *(int8 *)(param_1 + 0x18);
iVar2 = *piVar5;
*piVar5 = iVar2 + -1;
if (iVar2 < 2) {
js_free_value_rt(uVar6,piVar5,auVar11._8_8_);
}
JS_ThrowTypeError(param_1,"toPrimitive");
}
else {
LAB_0013ea4f:
bVar4 = false;
bVar3 = true;
do {
bVar9 = bVar3;
auVar11 = JS_GetPropertyInternal2
(param_1,param_2,param_3,
(bVar4 != ((param_4 & 0xffffffef) != 0)) * '\x02' + '8',param_2,param_3,0
,0);
uVar6 = local_40._0_8_;
uVar7 = auVar11._8_8_;
piVar5 = auVar11._0_8_;
if ((uVar7 & 0xffffffff) == 6) goto LAB_0013ed2c;
if (auVar11._8_4_ == 0xffffffff) {
uVar1 = *(ushort *)((long)piVar5 + 6);
if (uVar1 != 0xd) {
if (uVar1 == 0x30) {
cVar10 = *(char *)(*(long *)(piVar5 + 0xc) + 0x20);
}
else {
cVar10 = *(long *)(*(long *)(*(long *)(param_1 + 0x18) + 0x80) + 0x18 +
(ulong)uVar1 * 0x28) != 0;
}
if (cVar10 == '\0') goto LAB_0013eb9a;
}
local_40._0_8_ = local_40._0_8_ & 0xffffffff00000000;
local_40._8_8_ = 3;
auVar11 = JS_CallInternal(param_1,piVar5,uVar7,param_2,param_3,0,uVar6 & 0xffffffff00000000,
3,0,2);
uVar6 = *(int8 *)(param_1 + 0x18);
iVar2 = *piVar5;
*piVar5 = iVar2 + -1;
if (iVar2 < 2) {
js_free_value_rt(uVar6,piVar5,uVar7);
}
if (auVar11._8_4_ != -1) {
if (auVar11._8_4_ == 6) goto LAB_0013ed2c;
uVar6 = *(int8 *)(param_1 + 0x18);
iVar2 = *param_2;
*param_2 = iVar2 + -1;
if (iVar2 < 2) {
js_free_value_rt(uVar6,param_2,param_3);
}
goto LAB_0013eda5;
}
uVar6 = *(int8 *)(param_1 + 0x18);
iVar2 = *auVar11._0_8_;
*auVar11._0_8_ = iVar2 + -1;
joined_r0x0013ebb6:
if (iVar2 < 2) {
js_free_value_rt(uVar6,auVar11._0_8_,auVar11._8_8_);
}
}
else {
LAB_0013eb9a:
if (0xfffffff6 < auVar11._8_4_) {
uVar6 = *(int8 *)(param_1 + 0x18);
iVar2 = *piVar5;
*piVar5 = iVar2 + -1;
goto joined_r0x0013ebb6;
}
}
bVar4 = true;
bVar3 = false;
} while (bVar9);
JS_ThrowTypeError(param_1,"toPrimitive");
LAB_0013ed2c:
uVar6 = *(int8 *)(param_1 + 0x18);
iVar2 = *param_2;
*param_2 = iVar2 + -1;
if (iVar2 < 2) {
js_free_value_rt(uVar6,param_2,param_3);
}
}
auVar11 = ZEXT816(6) << 0x40;
uVar7 = 0;
LAB_0013ed5f:
auVar12._0_8_ = auVar11._0_8_ & 0xffffffff | uVar7;
auVar12._8_8_ = auVar11._8_8_;
return auVar12;
}
|
|
7,826 |
UpdateSound
|
csit-sgu[P]mit-game-2025-team-tyler/Libraries/raylib/src/raudio.c
|
void UpdateSound(Sound sound, const void *data, int frameCount)
{
if (sound.stream.buffer != NULL)
{
StopAudioBuffer(sound.stream.buffer);
memcpy(sound.stream.buffer->data, data, frameCount*ma_get_bytes_per_frame(sound.stream.buffer->converter.formatIn, sound.stream.buffer->converter.channelsIn));
}
}
|
O3
|
c
|
UpdateSound:
pushq %r15
pushq %r14
pushq %rbx
movq 0x20(%rsp), %r15
testq %r15, %r15
je 0x435db
movl %esi, %ebx
movq %rdi, %r14
movq %r15, %rdi
callq 0x42cc8
movl (%r15), %eax
leaq 0x8c815(%rip), %rcx # 0xcfdd0
imull 0x8(%r15), %ebx
imull (%rcx,%rax,4), %ebx
movq 0x170(%r15), %rdi
movq %r14, %rsi
movq %rbx, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0xa410
popq %rbx
popq %r14
popq %r15
retq
|
UpdateSound:
push r15
push r14
push rbx
mov r15, [rsp+18h+arg_0]
test r15, r15
jz short loc_435DB
mov ebx, esi
mov r14, rdi
mov rdi, r15
call StopAudioBuffer
mov eax, [r15]
lea rcx, dword_CFDD0
imul ebx, [r15+8]
imul ebx, [rcx+rax*4]
mov rdi, [r15+170h]
mov rsi, r14
mov rdx, rbx
pop rbx
pop r14
pop r15
jmp _memcpy
loc_435DB:
pop rbx
pop r14
pop r15
retn
|
long long UpdateSound(long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, long long a7)
{
long long result; // rax
if ( a7 )
{
StopAudioBuffer(a7);
return memcpy(*(_QWORD *)(a7 + 368));
}
return result;
}
|
UpdateSound:
PUSH R15
PUSH R14
PUSH RBX
MOV R15,qword ptr [RSP + 0x20]
TEST R15,R15
JZ 0x001435db
MOV EBX,ESI
MOV R14,RDI
MOV RDI,R15
CALL 0x00142cc8
MOV EAX,dword ptr [R15]
LEA RCX,[0x1cfdd0]
IMUL EBX,dword ptr [R15 + 0x8]
IMUL EBX,dword ptr [RCX + RAX*0x4]
MOV RDI,qword ptr [R15 + 0x170]
MOV RSI,R14
MOV RDX,RBX
POP RBX
POP R14
POP R15
JMP 0x0010a410
LAB_001435db:
POP RBX
POP R14
POP R15
RET
|
void UpdateSound(void *param_1,int param_2)
{
uint *in_stack_00000008;
if (in_stack_00000008 != (uint *)0x0) {
StopAudioBuffer(in_stack_00000008);
memcpy(*(void **)(in_stack_00000008 + 0x5c),param_1,
(ulong)(param_2 * in_stack_00000008[2] * (&DAT_001cfdd0)[*in_stack_00000008]));
return;
}
return;
}
|
|
7,827 |
HKDF_Expand
|
corpus-core[P]colibri-stateless/build_O0/_deps/blst-src/src/keygen.c
|
static void HKDF_Expand(unsigned char *OKM, size_t L,
const unsigned char PRK[32],
const void *info, size_t info_len,
#ifndef __BLST_HKDF_TESTMODE__
int info_fixup,
#endif
HMAC_SHA256_CTX *ctx)
{
#if !defined(__STDC_VERSION__) || __STDC_VERSION__<199901 \
|| defined(__STDC_NO_VLA__)
unsigned char *info_prime = alloca(info_len + 2 + 1);
#else
unsigned char info_prime[info_len + 2 + 1];
#endif
HMAC_init(ctx, PRK, 32);
if (info_len != 0)
sha256_bcopy(info_prime, info, info_len);
#ifndef __BLST_HKDF_TESTMODE__
if (info_fixup) {
/* Section 2.3 KeyGen in BLS-signature draft */
info_prime[info_len + 0] = (unsigned char)(L >> 8);
info_prime[info_len + 1] = (unsigned char)(L);
info_len += 2;
}
#endif
info_prime[info_len] = 1; /* counter */
HMAC_update(ctx, info_prime, info_len + 1);
HMAC_final(ctx->tail.c, ctx);
while (L > 32) {
sha256_hcopy((unsigned int *)OKM, (const unsigned int *)ctx->tail.c);
OKM += 32; L -= 32;
++info_prime[info_len]; /* counter */
HMAC_init(ctx, NULL, 0);
HMAC_update(ctx, ctx->tail.c, 32);
HMAC_update(ctx, info_prime, info_len + 1);
HMAC_final(ctx->tail.c, ctx);
}
sha256_bcopy(OKM, ctx->tail.c, L);
}
|
O0
|
c
|
HKDF_Expand:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq 0x10(%rbp), %rax
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movl %r9d, -0x2c(%rbp)
movq -0x28(%rbp), %rdx
movq %rdx, %rax
addq $0x3, %rax
movq %rsp, %rcx
movq %rcx, -0x38(%rbp)
addq $0x12, %rdx
andq $-0x10, %rdx
movq %rsp, %rcx
subq %rdx, %rcx
movq %rcx, -0x48(%rbp)
movq %rcx, %rsp
movq %rax, -0x40(%rbp)
movq 0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movl $0x20, %edx
callq 0xb7f30
cmpq $0x0, -0x28(%rbp)
je 0xb7df9
movq -0x48(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
callq 0xc3870
cmpl $0x0, -0x2c(%rbp)
je 0xb7e2e
movq -0x48(%rbp), %rax
movq -0x10(%rbp), %rcx
shrq $0x8, %rcx
movb %cl, %dl
movq -0x28(%rbp), %rcx
movb %dl, (%rax,%rcx)
movq -0x10(%rbp), %rcx
movb %cl, %dl
movq -0x28(%rbp), %rcx
movb %dl, 0x1(%rax,%rcx)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
movq -0x48(%rbp), %rsi
movq -0x28(%rbp), %rax
movb $0x1, (%rsi,%rax)
movq 0x10(%rbp), %rdi
movq -0x28(%rbp), %rdx
addq $0x1, %rdx
callq 0xb8110
movq 0x10(%rbp), %rdi
addq $0xb0, %rdi
movq 0x10(%rbp), %rsi
callq 0xb8140
cmpq $0x20, -0x10(%rbp)
jbe 0xb7efe
movq -0x8(%rbp), %rdi
movq 0x10(%rbp), %rsi
addq $0xb0, %rsi
callq 0xc3890
movq -0x48(%rbp), %rax
movq -0x8(%rbp), %rcx
addq $0x20, %rcx
movq %rcx, -0x8(%rbp)
movq -0x10(%rbp), %rcx
subq $0x20, %rcx
movq %rcx, -0x10(%rbp)
movq -0x28(%rbp), %rcx
movb (%rax,%rcx), %dl
addb $0x1, %dl
movb %dl, (%rax,%rcx)
movq 0x10(%rbp), %rdi
xorl %eax, %eax
movl %eax, %edx
movq %rdx, %rsi
callq 0xb7f30
movq 0x10(%rbp), %rdi
movq 0x10(%rbp), %rsi
addq $0xb0, %rsi
movl $0x20, %edx
callq 0xb8110
movq -0x48(%rbp), %rsi
movq 0x10(%rbp), %rdi
movq -0x28(%rbp), %rdx
addq $0x1, %rdx
callq 0xb8110
movq 0x10(%rbp), %rdi
addq $0xb0, %rdi
movq 0x10(%rbp), %rsi
callq 0xb8140
jmp 0xb7e5f
movq -0x8(%rbp), %rdi
movq 0x10(%rbp), %rsi
addq $0xb0, %rsi
movq -0x10(%rbp), %rdx
callq 0xc3870
movq -0x38(%rbp), %rax
movq %rax, %rsp
movq %rbp, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
|
HKDF_Expand:
push rbp
mov rbp, rsp
sub rsp, 50h
mov rax, [rbp+arg_0]
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov [rbp+var_2C], r9d
mov rdx, [rbp+var_28]
mov rax, rdx
add rax, 3
mov rcx, rsp
mov [rbp+var_38], rcx
add rdx, 12h
and rdx, 0FFFFFFFFFFFFFFF0h
mov rcx, rsp
sub rcx, rdx
mov [rbp+var_48], rcx
mov rsp, rcx
mov [rbp+var_40], rax
mov rdi, [rbp+arg_0]
mov rsi, [rbp+var_18]
mov edx, 20h ; ' '
call HMAC_init
cmp [rbp+var_28], 0
jz short loc_B7DF9
mov rdi, [rbp+var_48]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_28]
call blst_sha256_bcopy
loc_B7DF9:
cmp [rbp+var_2C], 0
jz short loc_B7E2E
mov rax, [rbp+var_48]
mov rcx, [rbp+var_10]
shr rcx, 8
mov dl, cl
mov rcx, [rbp+var_28]
mov [rax+rcx], dl
mov rcx, [rbp+var_10]
mov dl, cl
mov rcx, [rbp+var_28]
mov [rax+rcx+1], dl
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
loc_B7E2E:
mov rsi, [rbp+var_48]
mov rax, [rbp+var_28]
mov byte ptr [rsi+rax], 1
mov rdi, [rbp+arg_0]
mov rdx, [rbp+var_28]
add rdx, 1
call HMAC_update
mov rdi, [rbp+arg_0]
add rdi, 0B0h
mov rsi, [rbp+arg_0]
call HMAC_final
loc_B7E5F:
cmp [rbp+var_10], 20h ; ' '
jbe loc_B7EFE
mov rdi, [rbp+var_8]
mov rsi, [rbp+arg_0]
add rsi, 0B0h
call blst_sha256_hcopy
mov rax, [rbp+var_48]
mov rcx, [rbp+var_8]
add rcx, 20h ; ' '
mov [rbp+var_8], rcx
mov rcx, [rbp+var_10]
sub rcx, 20h ; ' '
mov [rbp+var_10], rcx
mov rcx, [rbp+var_28]
mov dl, [rax+rcx]
add dl, 1
mov [rax+rcx], dl
mov rdi, [rbp+arg_0]
xor eax, eax
mov edx, eax
mov rsi, rdx
call HMAC_init
mov rdi, [rbp+arg_0]
mov rsi, [rbp+arg_0]
add rsi, 0B0h
mov edx, 20h ; ' '
call HMAC_update
mov rsi, [rbp+var_48]
mov rdi, [rbp+arg_0]
mov rdx, [rbp+var_28]
add rdx, 1
call HMAC_update
mov rdi, [rbp+arg_0]
add rdi, 0B0h
mov rsi, [rbp+arg_0]
call HMAC_final
jmp loc_B7E5F
loc_B7EFE:
mov rdi, [rbp+var_8]
mov rsi, [rbp+arg_0]
add rsi, 0B0h
mov rdx, [rbp+var_10]
call blst_sha256_bcopy
mov rax, [rbp+var_38]
mov rsp, rax
mov rsp, rbp
pop rbp
retn
|
long long * HKDF_Expand(
long long a1,
unsigned long long a2,
long long a3,
long long a4,
long long a5,
int a6,
long long a7)
{
char *v7; // rax
char *v8; // rsi
long long v10; // [rsp+0h] [rbp-50h] BYREF
char *v11; // [rsp+8h] [rbp-48h]
long long v12; // [rsp+10h] [rbp-40h]
long long *v13; // [rsp+18h] [rbp-38h]
int v14; // [rsp+24h] [rbp-2Ch]
long long v15; // [rsp+28h] [rbp-28h]
long long v16; // [rsp+30h] [rbp-20h]
long long v17; // [rsp+38h] [rbp-18h]
unsigned long long v18; // [rsp+40h] [rbp-10h]
long long v19; // [rsp+48h] [rbp-8h]
v19 = a1;
v18 = a2;
v17 = a3;
v16 = a4;
v15 = a5;
v14 = a6;
v13 = &v10;
v11 = (char *)&v10 - ((a5 + 18) & 0xFFFFFFFFFFFFFFF0LL);
v12 = a5 + 3;
HMAC_init(a7, a3, 32LL);
if ( v15 )
blst_sha256_bcopy(v11, v16, v15);
if ( v14 )
{
v7 = v11;
v11[v15] = BYTE1(v18);
v7[v15 + 1] = v18;
v15 += 2LL;
}
v8 = v11;
v11[v15] = 1;
HMAC_update(a7, v8, v15 + 1);
HMAC_final(a7 + 176, a7);
while ( v18 > 0x20 )
{
blst_sha256_hcopy(v19, a7 + 176);
v19 += 32LL;
v18 -= 32LL;
++v11[v15];
HMAC_init(a7, 0LL, 0LL);
HMAC_update(a7, a7 + 176, 32LL);
HMAC_update(a7, v11, v15 + 1);
HMAC_final(a7 + 176, a7);
}
blst_sha256_bcopy(v19, a7 + 176, v18);
return v13;
}
|
HKDF_Expand:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV dword ptr [RBP + -0x2c],R9D
MOV RDX,qword ptr [RBP + -0x28]
MOV RAX,RDX
ADD RAX,0x3
MOV RCX,RSP
MOV qword ptr [RBP + -0x38],RCX
ADD RDX,0x12
AND RDX,-0x10
MOV RCX,RSP
SUB RCX,RDX
MOV qword ptr [RBP + -0x48],RCX
MOV RSP,RCX
MOV qword ptr [RBP + -0x40],RAX
MOV RDI,qword ptr [RBP + 0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV EDX,0x20
CALL 0x001b7f30
CMP qword ptr [RBP + -0x28],0x0
JZ 0x001b7df9
MOV RDI,qword ptr [RBP + -0x48]
MOV RSI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x28]
CALL 0x001c3870
LAB_001b7df9:
CMP dword ptr [RBP + -0x2c],0x0
JZ 0x001b7e2e
MOV RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x10]
SHR RCX,0x8
MOV DL,CL
MOV RCX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + RCX*0x1],DL
MOV RCX,qword ptr [RBP + -0x10]
MOV DL,CL
MOV RCX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + RCX*0x1 + 0x1],DL
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
LAB_001b7e2e:
MOV RSI,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RSI + RAX*0x1],0x1
MOV RDI,qword ptr [RBP + 0x10]
MOV RDX,qword ptr [RBP + -0x28]
ADD RDX,0x1
CALL 0x001b8110
MOV RDI,qword ptr [RBP + 0x10]
ADD RDI,0xb0
MOV RSI,qword ptr [RBP + 0x10]
CALL 0x001b8140
LAB_001b7e5f:
CMP qword ptr [RBP + -0x10],0x20
JBE 0x001b7efe
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + 0x10]
ADD RSI,0xb0
CALL 0x001c3890
MOV RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x8]
ADD RCX,0x20
MOV qword ptr [RBP + -0x8],RCX
MOV RCX,qword ptr [RBP + -0x10]
SUB RCX,0x20
MOV qword ptr [RBP + -0x10],RCX
MOV RCX,qword ptr [RBP + -0x28]
MOV DL,byte ptr [RAX + RCX*0x1]
ADD DL,0x1
MOV byte ptr [RAX + RCX*0x1],DL
MOV RDI,qword ptr [RBP + 0x10]
XOR EAX,EAX
MOV EDX,EAX
MOV RSI,RDX
CALL 0x001b7f30
MOV RDI,qword ptr [RBP + 0x10]
MOV RSI,qword ptr [RBP + 0x10]
ADD RSI,0xb0
MOV EDX,0x20
CALL 0x001b8110
MOV RSI,qword ptr [RBP + -0x48]
MOV RDI,qword ptr [RBP + 0x10]
MOV RDX,qword ptr [RBP + -0x28]
ADD RDX,0x1
CALL 0x001b8110
MOV RDI,qword ptr [RBP + 0x10]
ADD RDI,0xb0
MOV RSI,qword ptr [RBP + 0x10]
CALL 0x001b8140
JMP 0x001b7e5f
LAB_001b7efe:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + 0x10]
ADD RSI,0xb0
MOV RDX,qword ptr [RBP + -0x10]
CALL 0x001c3870
MOV RAX,qword ptr [RBP + -0x38]
MOV RSP,RAX
MOV RSP,RBP
POP RBP
RET
|
int1 *
HKDF_Expand(long param_1,ulong param_2,int8 param_3,int8 param_4,long param_5,
int param_6,long param_7)
{
long lVar1;
int1 *puVar2;
int8 uVar3;
ulong uVar4;
long lVar5;
int8 uStack_60;
int1 auStack_58 [8];
int1 *local_50;
long local_48;
int1 *local_40;
int local_34;
long local_30;
int8 local_28;
int8 local_20;
ulong local_18;
long local_10;
local_40 = auStack_58;
local_48 = param_5 + 3;
lVar1 = -(param_5 + 0x12U & 0xfffffffffffffff0);
local_50 = auStack_58 + lVar1;
local_34 = param_6;
local_30 = param_5;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7de1;
HMAC_init(param_7,param_3,0x20);
uVar3 = local_28;
lVar5 = local_30;
puVar2 = local_50;
if (local_30 != 0) {
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7df9;
blst_sha256_bcopy(puVar2,uVar3,lVar5);
}
puVar2 = local_50;
if (local_34 != 0) {
local_50[local_30] = (char)(local_18 >> 8);
local_50[local_30 + 1] = (char)local_18;
local_30 = local_30 + 2;
}
local_50[local_30] = 1;
lVar5 = local_30 + 1;
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7e4b;
HMAC_update(param_7,puVar2,lVar5);
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7e5f;
HMAC_final(param_7 + 0xb0,param_7);
while (lVar5 = local_10, uVar4 = local_18, 0x20 < local_18) {
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7e7e;
blst_sha256_hcopy(lVar5,param_7 + 0xb0);
local_10 = local_10 + 0x20;
local_18 = local_18 - 0x20;
local_50[local_30] = local_50[local_30] + '\x01';
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7eb7;
HMAC_init(param_7,0);
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7ed0;
HMAC_update(param_7,param_7 + 0xb0,0x20);
puVar2 = local_50;
lVar5 = local_30 + 1;
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7ee5;
HMAC_update(param_7,puVar2,lVar5);
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7ef9;
HMAC_final(param_7 + 0xb0,param_7);
}
*(int8 *)((long)&uStack_60 + lVar1) = 0x1b7f16;
blst_sha256_bcopy(lVar5,param_7 + 0xb0,uVar4);
return local_40;
}
|
|
7,828 |
google::protobuf::DescriptorBuilder::OptionInterpreter::SetInt32(int, int, google::protobuf::FieldDescriptor::Type, google::protobuf::UnknownFieldSet*)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc
|
void DescriptorBuilder::OptionInterpreter::SetInt32(
int number, int32_t value, FieldDescriptor::Type type,
UnknownFieldSet* unknown_fields) {
switch (type) {
case FieldDescriptor::TYPE_INT32:
unknown_fields->AddVarint(
number, static_cast<uint64_t>(static_cast<int64_t>(value)));
break;
case FieldDescriptor::TYPE_SFIXED32:
unknown_fields->AddFixed32(number, static_cast<uint32_t>(value));
break;
case FieldDescriptor::TYPE_SINT32:
unknown_fields->AddVarint(
number, internal::WireFormatLite::ZigZagEncode32(value));
break;
default:
GOOGLE_LOG(FATAL) << "Invalid wire type for CPPTYPE_INT32: " << type;
break;
}
}
|
O3
|
cpp
|
google::protobuf::DescriptorBuilder::OptionInterpreter::SetInt32(int, int, google::protobuf::FieldDescriptor::Type, google::protobuf::UnknownFieldSet*):
pushq %r14
pushq %rbx
subq $0x48, %rsp
cmpl $0x11, %ecx
je 0x39d6e
movl %ecx, %ebx
cmpl $0xf, %ecx
je 0x39d5f
cmpl $0x5, %ebx
jne 0x39d85
movslq %edx, %rdx
jmp 0x39d76
movq %r8, %rdi
addq $0x48, %rsp
popq %rbx
popq %r14
jmp 0x87cb0
leal (%rdx,%rdx), %eax
sarl $0x1f, %edx
xorl %eax, %edx
movq %r8, %rdi
addq $0x48, %rsp
popq %rbx
popq %r14
jmp 0x87c72
leaq 0x7c058(%rip), %rdx # 0xb5de4
leaq 0x10(%rsp), %r14
movq %r14, %rdi
movl $0x3, %esi
movl $0x1f95, %ecx # imm = 0x1F95
callq 0x169ca
leaq 0x7e580(%rip), %rsi # 0xb832a
movq %r14, %rdi
callq 0x164c8
movq %rax, %rdi
movl %ebx, %esi
callq 0x167f0
leaq 0xf(%rsp), %rdi
movq %rax, %rsi
callq 0x165a2
leaq 0x10(%rsp), %rdi
callq 0x169e8
addq $0x48, %rsp
popq %rbx
popq %r14
retq
jmp 0x39ddd
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x169e8
movq %rbx, %rdi
callq 0xf570
|
_ZN6google8protobuf17DescriptorBuilder17OptionInterpreter8SetInt32EiiNS0_15FieldDescriptor4TypeEPNS0_15UnknownFieldSetE:
push r14
push rbx
sub rsp, 48h
cmp ecx, 11h
jz short loc_39D6E
mov ebx, ecx
cmp ecx, 0Fh
jz short loc_39D5F
cmp ebx, 5
jnz short loc_39D85
movsxd rdx, edx; unsigned int
jmp short loc_39D76
loc_39D5F:
mov rdi, r8; this
add rsp, 48h
pop rbx
pop r14
jmp _ZN6google8protobuf15UnknownFieldSet10AddFixed32Eij; google::protobuf::UnknownFieldSet::AddFixed32(int,uint)
loc_39D6E:
lea eax, [rdx+rdx]
sar edx, 1Fh
xor edx, eax; unsigned __int64
loc_39D76:
mov rdi, r8; this
add rsp, 48h
pop rbx
pop r14
jmp _ZN6google8protobuf15UnknownFieldSet9AddVarintEim; google::protobuf::UnknownFieldSet::AddVarint(int,ulong)
loc_39D85:
lea rdx, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/aimrt_"...
lea r14, [rsp+58h+var_48]
mov rdi, r14
mov esi, 3
mov ecx, 1F95h
call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int)
lea rsi, aInvalidWireTyp_0; "Invalid wire type for CPPTYPE_INT32: "
mov rdi, r14
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
mov rdi, rax
mov esi, ebx
call _ZN6google8protobuf8internal10LogMessagelsEi; google::protobuf::internal::LogMessage::operator<<(int)
lea rdi, [rsp+58h+var_49]
mov rsi, rax
call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &)
lea rdi, [rsp+58h+var_48]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
add rsp, 48h
pop rbx
pop r14
retn
jmp short $+2
loc_39DDD:
mov rbx, rax
lea rdi, [rsp+arg_8]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
mov rdi, rbx
call __Unwind_Resume
|
void google::protobuf::DescriptorBuilder::OptionInterpreter::SetInt32(
long long a1,
int a2,
unsigned long long a3,
unsigned int a4,
google::protobuf::UnknownFieldSet *a5)
{
long long v6; // rax
char *v7; // rdx
google::protobuf::internal::LogMessage *v8; // rax
char v9; // [rsp+Fh] [rbp-49h] BYREF
_BYTE v10[72]; // [rsp+10h] [rbp-48h] BYREF
switch ( a4 )
{
case 0x11u:
a3 = (2 * (_DWORD)a3) ^ (unsigned int)((int)a3 >> 31);
goto LABEL_7;
case 0xFu:
google::protobuf::UnknownFieldSet::AddFixed32(a5, a2, a3);
return;
case 5u:
a3 = (int)a3;
LABEL_7:
google::protobuf::UnknownFieldSet::AddVarint(a5, a2, a3);
return;
}
google::protobuf::internal::LogMessage::LogMessage(
(long long)v10,
3,
(long long)"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc",
8085);
v6 = google::protobuf::internal::LogMessage::operator<<(
(long long)v10,
(long long)"Invalid wire type for CPPTYPE_INT32: ");
v8 = (google::protobuf::internal::LogMessage *)google::protobuf::internal::LogMessage::operator<<(v6, a4, v7);
google::protobuf::internal::LogFinisher::operator=((long long)&v9, v8);
google::protobuf::internal::LogMessage::~LogMessage((google::protobuf::internal::LogMessage *)v10);
}
|
SetInt32:
PUSH R14
PUSH RBX
SUB RSP,0x48
CMP ECX,0x11
JZ 0x00139d6e
MOV EBX,ECX
CMP ECX,0xf
JZ 0x00139d5f
CMP EBX,0x5
JNZ 0x00139d85
MOVSXD RDX,EDX
JMP 0x00139d76
LAB_00139d5f:
MOV RDI,R8
ADD RSP,0x48
POP RBX
POP R14
JMP 0x00187cb0
LAB_00139d6e:
LEA EAX,[RDX + RDX*0x1]
SAR EDX,0x1f
XOR EDX,EAX
LAB_00139d76:
MOV RDI,R8
ADD RSP,0x48
POP RBX
POP R14
JMP 0x00187c72
LAB_00139d85:
LEA RDX,[0x1b5de4]
LEA R14,[RSP + 0x10]
MOV RDI,R14
MOV ESI,0x3
MOV ECX,0x1f95
CALL 0x001169ca
LAB_00139da3:
LEA RSI,[0x1b832a]
MOV RDI,R14
CALL 0x001164c8
MOV RDI,RAX
MOV ESI,EBX
CALL 0x001167f0
LAB_00139dbc:
LEA RDI,[RSP + 0xf]
MOV RSI,RAX
CALL 0x001165a2
LAB_00139dc9:
LEA RDI,[RSP + 0x10]
CALL 0x001169e8
ADD RSP,0x48
POP RBX
POP R14
RET
|
/* google::protobuf::DescriptorBuilder::OptionInterpreter::SetInt32(int, int,
google::protobuf::FieldDescriptor::Type, google::protobuf::UnknownFieldSet*) */
void __thiscall
google::protobuf::DescriptorBuilder::OptionInterpreter::SetInt32
(int8 param_1_00,int param_1,uint param_2,int param_4,UnknownFieldSet *param_5)
{
LogMessage *pLVar1;
ulong uVar2;
LogFinisher local_49;
LogMessage local_48 [56];
if (param_4 == 0x11) {
uVar2 = (ulong)((int)param_2 >> 0x1f ^ param_2 * 2);
}
else {
if (param_4 == 0xf) {
UnknownFieldSet::AddFixed32(param_5,param_1,param_2);
return;
}
if (param_4 != 5) {
internal::LogMessage::LogMessage
(local_48,3,
"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc"
,0x1f95);
/* try { // try from 00139da3 to 00139dbb has its CatchHandler @ 00139ddd */
pLVar1 = (LogMessage *)
internal::LogMessage::operator<<(local_48,"Invalid wire type for CPPTYPE_INT32: ");
pLVar1 = (LogMessage *)internal::LogMessage::operator<<(pLVar1,param_4);
/* try { // try from 00139dbc to 00139dc8 has its CatchHandler @ 00139ddb */
internal::LogFinisher::operator=(&local_49,pLVar1);
internal::LogMessage::~LogMessage(local_48);
return;
}
uVar2 = (ulong)(int)param_2;
}
UnknownFieldSet::AddVarint(param_5,param_1,uVar2);
return;
}
|
|
7,829 |
js_regexp_string_iterator_next
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue js_regexp_string_iterator_next(JSContext *ctx,
JSValue this_val,
int argc, JSValue *argv,
BOOL *pdone, int magic)
{
JSRegExpStringIteratorData *it;
JSValue R, S;
JSValue matchStr = JS_UNDEFINED, match = JS_UNDEFINED;
JSString *sp;
it = JS_GetOpaque2(ctx, this_val, JS_CLASS_REGEXP_STRING_ITERATOR);
if (!it)
goto exception;
if (it->done) {
*pdone = TRUE;
return JS_UNDEFINED;
}
R = it->iterating_regexp;
S = it->iterated_string;
match = JS_RegExpExec(ctx, R, S);
if (JS_IsException(match))
goto exception;
if (JS_IsNull(match)) {
it->done = TRUE;
*pdone = TRUE;
return JS_UNDEFINED;
} else if (it->global) {
matchStr = JS_ToStringFree(ctx, JS_GetPropertyInt64(ctx, match, 0));
if (JS_IsException(matchStr))
goto exception;
if (JS_IsEmptyString(matchStr)) {
int64_t thisIndex, nextIndex;
if (JS_ToLengthFree(ctx, &thisIndex,
JS_GetProperty(ctx, R, JS_ATOM_lastIndex)) < 0)
goto exception;
sp = JS_VALUE_GET_STRING(S);
nextIndex = string_advance_index(sp, thisIndex, it->unicode);
if (JS_SetProperty(ctx, R, JS_ATOM_lastIndex, js_int64(nextIndex)) < 0)
goto exception;
}
JS_FreeValue(ctx, matchStr);
} else {
it->done = TRUE;
}
*pdone = FALSE;
return match;
exception:
JS_FreeValue(ctx, match);
JS_FreeValue(ctx, matchStr);
*pdone = FALSE;
return JS_EXCEPTION;
}
|
O1
|
c
|
js_regexp_string_iterator_next:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %r9, %rbx
movq %rdi, %r15
movl $0x2e, %ecx
callq 0x275b5
movl $0x3, %r13d
testq %rax, %rax
je 0x4c8ed
movq %rax, %r12
cmpl $0x0, 0x28(%rax)
je 0x4c937
movl $0x1, (%rbx)
movl $0x3, %r14d
jmp 0x4c91e
xorl %esi, %esi
movl $0x3, %r14d
xorl %ebp, %ebp
movq 0x18(%r15), %rdi
movq %r14, %rdx
callq 0x1d8c6
movq 0x18(%r15), %rdi
movq %rbp, %rsi
movq %r13, %rdx
callq 0x1d8c6
movl $0x0, (%rbx)
movl $0x6, %r14d
xorl %eax, %eax
xorl %ecx, %ecx
orq %rcx, %rax
movq %r14, %rdx
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq (%r12), %rbp
movq 0x8(%r12), %rdx
movq 0x10(%r12), %xmm0
movq %xmm0, 0x60(%rsp)
movq 0x18(%r12), %r8
movq %xmm0, %rcx
movq %r15, %rdi
movq %rbp, %rsi
movq %rdx, 0x30(%rsp)
callq 0x4b761
movq %rax, %rsi
movq %rdx, %r14
cmpl $0x6, %r14d
je 0x4c8f5
cmpl $0x2, %r14d
jne 0x4c98a
movl $0x1, %eax
movl %eax, 0x28(%r12)
movl %eax, (%rbx)
jmp 0x4c8e5
cmpl $0x0, 0x20(%r12)
je 0x4c9ec
movq %rbp, 0x28(%rsp)
movq %r15, %rdi
movq %rsi, 0x20(%rsp)
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x241b4
movq %rax, 0x50(%rsp)
movq %rdx, 0x48(%rsp)
movq %r15, %rdi
movq %rax, %rsi
xorl %ecx, %ecx
callq 0x27add
movq %rax, %rbp
movq %rdx, %r13
movq 0x18(%r15), %rdi
movq 0x50(%rsp), %rsi
movq 0x48(%rsp), %rdx
callq 0x1d8c6
movl %r13d, %eax
cmpq $0x6, %rax
jne 0x4c9f7
movq 0x20(%rsp), %rsi
jmp 0x4c8f7
movl $0x1, 0x28(%r12)
jmp 0x4ca24
movq %rbp, 0x38(%rsp)
cmpl $-0x7, %eax
jne 0x4ca10
movq 0x38(%rsp), %rax
movq 0x4(%rax), %rax
shlq $0x21, %rax
je 0x4ca41
movq 0x18(%r15), %rdi
movq %rbp, %rsi
movq %r13, %rdx
callq 0x1d8c6
movq 0x20(%rsp), %rsi
movl $0x0, (%rbx)
movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000
movq %rsi, %rcx
andq %rax, %rcx
movl %esi, %eax
jmp 0x4c922
movl $0x0, 0x8(%rsp)
movq $0x0, (%rsp)
movq %r15, %rdi
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rdx
movl $0x56, %ecx
movq %rsi, %r8
movq %rdx, %r9
callq 0x22fa3
movq %rdx, %rcx
leaq 0x58(%rsp), %rsi
movq %r15, %rdi
movq %rax, %rdx
callq 0x475c4
testl %eax, %eax
js 0x4c9e2
movq 0x60(%rsp), %rdi
movq 0x58(%rsp), %rsi
movl 0x24(%r12), %edx
callq 0x4bf9b
movslq %eax, %rcx
xorl %edx, %edx
cmpq %rax, %rcx
movl %ecx, %ecx
cvtsi2sd %rax, %xmm0
movq %xmm0, %r8
cmoveq %rcx, %r8
movl $0x7, %r9d
cmoveq %rdx, %r9
movq 0x28(%rsp), %rsi
movq %rsi, 0x38(%rsp)
movq 0x30(%rsp), %rdx
movq %rdx, 0x40(%rsp)
movdqu 0x38(%rsp), %xmm0
movdqu %xmm0, (%rsp)
movq $0x0, 0x18(%rsp)
movl $0x4000, 0x10(%rsp) # imm = 0x4000
movq %r15, %rdi
movl $0x56, %ecx
callq 0x24388
testl %eax, %eax
jns 0x4ca10
jmp 0x4c9e2
|
js_regexp_string_iterator_next:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 68h
mov rbx, r9
mov r15, rdi
mov ecx, 2Eh ; '.'
call JS_GetOpaque2
mov r13d, 3
test rax, rax
jz short loc_4C8ED
mov r12, rax
cmp dword ptr [rax+28h], 0
jz short loc_4C937
mov dword ptr [rbx], 1
loc_4C8E5:
mov r14d, 3
jmp short loc_4C91E
loc_4C8ED:
xor esi, esi
mov r14d, 3
loc_4C8F5:
xor ebp, ebp
loc_4C8F7:
mov rdi, [r15+18h]
mov rdx, r14
call JS_FreeValueRT
mov rdi, [r15+18h]
mov rsi, rbp
mov rdx, r13
call JS_FreeValueRT
mov dword ptr [rbx], 0
mov r14d, 6
loc_4C91E:
xor eax, eax
xor ecx, ecx
loc_4C922:
or rax, rcx
mov rdx, r14
add rsp, 68h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_4C937:
mov rbp, [r12]
mov rdx, [r12+8]
movq xmm0, qword ptr [r12+10h]
movq [rsp+98h+var_38], xmm0
mov r8, [r12+18h]
movq rcx, xmm0
mov rdi, r15
mov rsi, rbp
mov [rsp+98h+var_68], rdx
call JS_RegExpExec
mov rsi, rax
mov r14, rdx
cmp r14d, 6
jz short loc_4C8F5
cmp r14d, 2
jnz short loc_4C98A
mov eax, 1
mov [r12+28h], eax
mov [rbx], eax
jmp loc_4C8E5
loc_4C98A:
cmp dword ptr [r12+20h], 0
jz short loc_4C9EC
mov [rsp+98h+var_70], rbp
mov rdi, r15
mov [rsp+98h+var_78], rsi
mov rdx, r14
xor ecx, ecx
call JS_GetPropertyInt64
mov [rsp+98h+var_48], rax
mov [rsp+98h+var_50], rdx
mov rdi, r15
mov rsi, rax
xor ecx, ecx
call JS_ToStringInternal
mov rbp, rax
mov r13, rdx
mov rdi, [r15+18h]
mov rsi, [rsp+98h+var_48]
mov rdx, [rsp+98h+var_50]
call JS_FreeValueRT
mov eax, r13d
cmp rax, 6
jnz short loc_4C9F7
loc_4C9E2:
mov rsi, [rsp+98h+var_78]
jmp loc_4C8F7
loc_4C9EC:
mov dword ptr [r12+28h], 1
jmp short loc_4CA24
loc_4C9F7:
mov qword ptr [rsp+98h+var_60], rbp
cmp eax, 0FFFFFFF9h
jnz short loc_4CA10
mov rax, qword ptr [rsp+98h+var_60]
mov rax, [rax+4]
shl rax, 21h
jz short loc_4CA41
loc_4CA10:
mov rdi, [r15+18h]
mov rsi, rbp
mov rdx, r13
call JS_FreeValueRT
mov rsi, [rsp+98h+var_78]
loc_4CA24:
mov dword ptr [rbx], 0
mov rax, 0FFFFFFFF00000000h
mov rcx, rsi
and rcx, rax
mov eax, esi
jmp loc_4C922
loc_4CA41:
mov dword ptr [rsp+98h+var_98+8], 0
mov qword ptr [rsp+98h+var_98], 0
mov rdi, r15
mov rsi, [rsp+98h+var_70]
mov rdx, [rsp+98h+var_68]
mov ecx, 56h ; 'V'
mov r8, rsi
mov r9, rdx
call JS_GetPropertyInternal2
mov rcx, rdx
lea rsi, [rsp+98h+var_40]
mov rdi, r15
mov rdx, rax
call JS_ToLengthFree
test eax, eax
js loc_4C9E2
mov rdi, [rsp+98h+var_38]
mov rsi, [rsp+98h+var_40]
mov edx, [r12+24h]
call string_advance_index
movsxd rcx, eax
xor edx, edx
cmp rcx, rax
mov ecx, ecx
cvtsi2sd xmm0, rax
movq r8, xmm0
cmovz r8, rcx
mov r9d, 7
cmovz r9, rdx
mov rsi, [rsp+98h+var_70]
mov qword ptr [rsp+98h+var_60], rsi
mov rdx, [rsp+98h+var_68]
mov qword ptr [rsp+98h+var_60+8], rdx
movdqu xmm0, [rsp+98h+var_60]
movdqu [rsp+98h+var_98], xmm0
mov [rsp+98h+var_80], 0
mov [rsp+98h+var_88], 4000h
mov rdi, r15
mov ecx, 56h ; 'V'
call JS_SetPropertyInternal2
test eax, eax
jns loc_4CA10
jmp loc_4C9E2
|
unsigned long long js_regexp_string_iterator_next(
long long a1,
long long a2,
int a3,
double a4,
__m128 a5,
__m128 a6,
__m128 a7,
double a8,
double a9,
__m128 a10,
__m128 a11,
long long a12,
long long a13,
_DWORD *a14)
{
const __m128i *Opaque2; // rax
double v16; // xmm4_8
double v17; // xmm5_8
long long v18; // r13
const __m128i *v19; // r12
long long v20; // rsi
long long v21; // r14
_DWORD *v22; // rbp
long long v23; // rax
unsigned long long v24; // rcx
long long v26; // rbp
unsigned long long v27; // rdx
__m128 v28; // xmm0
long long v29; // rax
long long v30; // rdx
long long v31; // rdx
long long v32; // r8
long long v33; // r9
__m128 v34; // xmm4
__m128 v35; // xmm5
long long v36; // rdx
_DWORD *PropertyInternal2; // rax
long long v38; // rdx
long long v39; // rax
double v40; // xmm4_8
double v41; // xmm5_8
double v42; // r8
long long v43; // r9
__m128 v44; // xmm0
_DWORD *v45; // [rsp+20h] [rbp-78h]
__m128i v46; // [rsp+28h] [rbp-70h]
__m128i v47; // [rsp+38h] [rbp-60h] BYREF
long long v48; // [rsp+48h] [rbp-50h]
_DWORD *PropertyInt64; // [rsp+50h] [rbp-48h]
long long v50; // [rsp+58h] [rbp-40h] BYREF
long long v51; // [rsp+60h] [rbp-38h]
Opaque2 = (const __m128i *)JS_GetOpaque2(a1, a2, a3, 0x2Eu);
v18 = 3LL;
if ( !Opaque2 )
{
v20 = 0LL;
v21 = 3LL;
goto LABEL_5;
}
v19 = Opaque2;
if ( !Opaque2[2].m128i_i32[2] )
{
v26 = Opaque2->m128i_i64[0];
v27 = Opaque2->m128i_u64[1];
v28 = (__m128)_mm_loadl_epi64(Opaque2 + 1);
v51 = v28.m128_u64[0];
v46.m128i_i64[1] = v27;
v29 = JS_RegExpExec(a1, v26, v27, v28.m128_i64[0], Opaque2[1].m128i_i64[1], v28, a5, a6, a7, v16, v17, a10, a11);
v20 = v29;
v21 = v30;
if ( (_DWORD)v30 != 6 )
{
if ( (_DWORD)v30 == 2 )
{
v19[2].m128i_i32[2] = 1;
*a14 = 1;
goto LABEL_7;
}
if ( v19[2].m128i_i32[0] )
{
v46.m128i_i64[0] = v26;
v45 = (_DWORD *)v29;
PropertyInt64 = (_DWORD *)JS_GetPropertyInt64(a1, v29, v30, 0LL);
v48 = v31;
v22 = (_DWORD *)JS_ToStringInternal(
a1,
(long long)PropertyInt64,
v31,
0,
v32,
v33,
v28,
a5,
a6,
a7,
v34,
v35,
a10,
a11);
v18 = v36;
JS_FreeValueRT(*(_QWORD *)(a1 + 24), PropertyInt64, v48);
if ( (unsigned int)v18 == 6LL )
goto LABEL_14;
v47.m128i_i64[0] = (long long)v22;
if ( (_DWORD)v18 == -7 && !(*(_QWORD *)(v47.m128i_i64[0] + 4) << 33) )
{
PropertyInternal2 = (_DWORD *)JS_GetPropertyInternal2(
a1,
v46.m128i_i64[0],
v46.m128i_i64[1],
0x56u,
v46.m128i_i64[0],
v46.m128i_i64[1],
0LL,
0);
if ( (int)JS_ToLengthFree(a1, (unsigned long long *)&v50, PropertyInternal2, v38) < 0 )
goto LABEL_14;
v39 = string_advance_index(v51, v50, v19[2].m128i_i32[1]);
v42 = (double)(int)v39;
if ( (int)v39 == v39 )
*(_QWORD *)&v42 = (unsigned int)v39;
v43 = 7LL;
if ( (int)v39 == v39 )
v43 = 0LL;
v47 = v46;
v44 = (__m128)_mm_loadu_si128(&v47);
if ( (int)JS_SetPropertyInternal2(
a1,
v46.m128i_i64[0],
v46.m128i_i64[1],
0x56u,
*(_DWORD **)&v42,
v43,
v44,
a5,
a6,
a7,
v40,
v41,
a10,
a11,
v44.m128_i64[0],
v44.m128_i32[2],
0x4000u,
0LL) < 0 )
{
LABEL_14:
v20 = (long long)v45;
goto LABEL_6;
}
}
JS_FreeValueRT(*(_QWORD *)(a1 + 24), v22, v18);
v20 = (long long)v45;
}
else
{
v19[2].m128i_i32[2] = 1;
}
*a14 = 0;
v24 = v20 & 0xFFFFFFFF00000000LL;
v23 = (unsigned int)v20;
return v24 | v23;
}
LABEL_5:
v22 = 0LL;
LABEL_6:
JS_FreeValueRT(*(_QWORD *)(a1 + 24), (_DWORD *)v20, v21);
JS_FreeValueRT(*(_QWORD *)(a1 + 24), v22, v18);
*a14 = 0;
goto LABEL_7;
}
*a14 = 1;
LABEL_7:
v23 = 0LL;
v24 = 0LL;
return v24 | v23;
}
| |||
7,830 |
js_regexp_string_iterator_next
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue js_regexp_string_iterator_next(JSContext *ctx,
JSValue this_val,
int argc, JSValue *argv,
BOOL *pdone, int magic)
{
JSRegExpStringIteratorData *it;
JSValue R, S;
JSValue matchStr = JS_UNDEFINED, match = JS_UNDEFINED;
JSString *sp;
it = JS_GetOpaque2(ctx, this_val, JS_CLASS_REGEXP_STRING_ITERATOR);
if (!it)
goto exception;
if (it->done) {
*pdone = TRUE;
return JS_UNDEFINED;
}
R = it->iterating_regexp;
S = it->iterated_string;
match = JS_RegExpExec(ctx, R, S);
if (JS_IsException(match))
goto exception;
if (JS_IsNull(match)) {
it->done = TRUE;
*pdone = TRUE;
return JS_UNDEFINED;
} else if (it->global) {
matchStr = JS_ToStringFree(ctx, JS_GetPropertyInt64(ctx, match, 0));
if (JS_IsException(matchStr))
goto exception;
if (JS_IsEmptyString(matchStr)) {
int64_t thisIndex, nextIndex;
if (JS_ToLengthFree(ctx, &thisIndex,
JS_GetProperty(ctx, R, JS_ATOM_lastIndex)) < 0)
goto exception;
sp = JS_VALUE_GET_STRING(S);
nextIndex = string_advance_index(sp, thisIndex, it->unicode);
if (JS_SetProperty(ctx, R, JS_ATOM_lastIndex, js_int64(nextIndex)) < 0)
goto exception;
}
JS_FreeValue(ctx, matchStr);
} else {
it->done = TRUE;
}
*pdone = FALSE;
return match;
exception:
JS_FreeValue(ctx, match);
JS_FreeValue(ctx, matchStr);
*pdone = FALSE;
return JS_EXCEPTION;
}
|
O2
|
c
|
js_regexp_string_iterator_next:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r9, %rbx
movq %rdi, %r15
pushq $0x2e
popq %rcx
callq 0x21207
pushq $0x3
popq %r13
testq %rax, %rax
je 0x41d00
movq %rax, %r12
cmpl $0x0, 0x28(%rax)
je 0x41d40
movl $0x1, (%rbx)
pushq $0x3
jmp 0x41d25
xorl %esi, %esi
movq %r13, %r14
xorl %ebp, %ebp
movq %r15, %rdi
movq %r14, %rdx
callq 0x1801e
movq %r15, %rdi
movq %rbp, %rsi
movq %r13, %rdx
callq 0x1801e
andl $0x0, (%rbx)
pushq $0x6
popq %r14
xorl %eax, %eax
xorl %ecx, %ecx
orq %rcx, %rax
movq %r14, %rdx
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq (%r12), %rbp
movq 0x8(%r12), %rdx
movq 0x10(%r12), %rcx
movq 0x18(%r12), %r8
movq %r15, %rdi
movq %rbp, %rsi
movq %rdx, 0x10(%rsp)
movq %rcx, 0x18(%rsp)
callq 0x4133b
movq %rax, %rsi
movq %rdx, %r14
cmpl $0x6, %r14d
je 0x41d05
cmpl $0x2, %r14d
jne 0x41d89
pushq $0x1
popq %rax
movl %eax, 0x28(%r12)
movl %eax, (%rbx)
jmp 0x41cfc
cmpl $0x0, 0x20(%r12)
je 0x41de5
movq %rbp, 0x8(%rsp)
movq %r15, %rdi
movq %rsi, (%rsp)
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x1e178
movq %r15, %rdi
movq %rax, %rsi
callq 0x2e049
movq %rax, %rbp
movq %rdx, %r13
cmpl $0x6, %r13d
je 0x41e73
cmpl $-0x7, %r13d
jne 0x41dd1
testl $0x7fffffff, 0x4(%rbp) # imm = 0x7FFFFFFF
je 0x41e08
movq %r15, %rdi
movq %rbp, %rsi
movq %r13, %rdx
callq 0x1801e
movq (%rsp), %rsi
jmp 0x41dee
movl $0x1, 0x28(%r12)
andl $0x0, (%rbx)
movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000
movq %rsi, %rcx
andq %rax, %rcx
movl %esi, %eax
jmp 0x41d2b
pushq $0x56
popq %rcx
movq %r15, %rdi
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
callq 0x1b043
movq %rdx, %rcx
leaq 0x20(%rsp), %rsi
movq %r15, %rdi
movq %rax, %rdx
callq 0x3daf8
testl %eax, %eax
js 0x41e73
movq 0x20(%rsp), %rsi
movl 0x24(%r12), %edx
movq 0x18(%rsp), %rdi
callq 0x41551
movq %rax, %rdi
callq 0x20a0b
movq %rdx, %r9
pushq $0x56
popq %rcx
movq %r15, %rdi
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
movq %rax, %r8
callq 0x1e446
testl %eax, %eax
jns 0x41dd1
movq (%rsp), %rsi
jmp 0x41d07
|
js_regexp_string_iterator_next:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov rbx, r9
mov r15, rdi
push 2Eh ; '.'
pop rcx
call JS_GetOpaque2
push 3
pop r13
test rax, rax
jz short loc_41D00
mov r12, rax
cmp dword ptr [rax+28h], 0
jz short loc_41D40
mov dword ptr [rbx], 1
loc_41CFC:
push 3
jmp short loc_41D25
loc_41D00:
xor esi, esi
mov r14, r13
loc_41D05:
xor ebp, ebp
loc_41D07:
mov rdi, r15
mov rdx, r14
call JS_FreeValue
mov rdi, r15
mov rsi, rbp
mov rdx, r13
call JS_FreeValue
and dword ptr [rbx], 0
push 6
loc_41D25:
pop r14
xor eax, eax
xor ecx, ecx
loc_41D2B:
or rax, rcx
mov rdx, r14
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_41D40:
mov rbp, [r12]
mov rdx, [r12+8]
mov rcx, [r12+10h]
mov r8, [r12+18h]
mov rdi, r15
mov rsi, rbp
mov [rsp+58h+var_48], rdx
mov [rsp+58h+var_40], rcx
call JS_RegExpExec
mov rsi, rax
mov r14, rdx
cmp r14d, 6
jz short loc_41D05
cmp r14d, 2
jnz short loc_41D89
push 1
pop rax
mov [r12+28h], eax
mov [rbx], eax
jmp loc_41CFC
loc_41D89:
cmp dword ptr [r12+20h], 0
jz short loc_41DE5
mov [rsp+58h+var_50], rbp
mov rdi, r15
mov [rsp+58h+var_58], rsi
mov rdx, r14
xor ecx, ecx
call JS_GetPropertyInt64
mov rdi, r15
mov rsi, rax
call JS_ToStringFree
mov rbp, rax
mov r13, rdx
cmp r13d, 6
jz loc_41E73
cmp r13d, 0FFFFFFF9h
jnz short loc_41DD1
test dword ptr [rbp+4], 7FFFFFFFh
jz short loc_41E08
loc_41DD1:
mov rdi, r15
mov rsi, rbp
mov rdx, r13
call JS_FreeValue
mov rsi, [rsp+58h+var_58]
jmp short loc_41DEE
loc_41DE5:
mov dword ptr [r12+28h], 1
loc_41DEE:
and dword ptr [rbx], 0
mov rax, 0FFFFFFFF00000000h
mov rcx, rsi
and rcx, rax
mov eax, esi
jmp loc_41D2B
loc_41E08:
push 56h ; 'V'
pop rcx
mov rdi, r15
mov rsi, [rsp+58h+var_50]
mov rdx, [rsp+58h+var_48]
call JS_GetProperty
mov rcx, rdx
lea rsi, [rsp+58h+var_38]
mov rdi, r15
mov rdx, rax
call JS_ToLengthFree
test eax, eax
js short loc_41E73
mov rsi, [rsp+58h+var_38]
mov edx, [r12+24h]
mov rdi, [rsp+58h+var_40]
call string_advance_index
mov rdi, rax
call js_int64
mov r9, rdx
push 56h ; 'V'
pop rcx
mov rdi, r15
mov rsi, [rsp+58h+var_50]
mov rdx, [rsp+58h+var_48]
mov r8, rax
call JS_SetProperty
test eax, eax
jns loc_41DD1
loc_41E73:
mov rsi, [rsp+58h+var_58]
jmp loc_41D07
|
unsigned long long js_regexp_string_iterator_next(
long long a1,
long long a2,
int a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
double a8,
double a9,
__m128 a10,
__m128 a11,
long long a12,
long long a13,
_DWORD *a14)
{
long long Opaque2; // rax
double v16; // xmm4_8
double v17; // xmm5_8
long long v18; // r13
_DWORD *v19; // r12
long long v20; // rsi
long long v21; // r14
long long v22; // rbp
long long v23; // rax
unsigned long long v24; // rcx
long long v26; // rbp
long long v27; // rax
long long v28; // rdx
unsigned long long PropertyInt64; // rax
long long v30; // rdx
long long v31; // rax
long long v32; // rdx
_DWORD *Property; // rax
long long v34; // rdx
long long v35; // rax
int v36; // eax
int v37; // edx
long long v38; // [rsp+0h] [rbp-58h]
int v39; // [rsp+8h] [rbp-50h]
long long v40; // [rsp+10h] [rbp-48h]
long long v41; // [rsp+18h] [rbp-40h]
unsigned long long v42[7]; // [rsp+20h] [rbp-38h] BYREF
Opaque2 = JS_GetOpaque2(a1, a2, a3, 0x2Eu);
v18 = 3LL;
if ( !Opaque2 )
{
v20 = 0LL;
v21 = 3LL;
goto LABEL_5;
}
v19 = (_DWORD *)Opaque2;
if ( !*(_DWORD *)(Opaque2 + 40) )
{
v26 = *(_QWORD *)Opaque2;
v40 = *(_QWORD *)(Opaque2 + 8);
v41 = *(_QWORD *)(Opaque2 + 16);
v27 = JS_RegExpExec(a1, *(_QWORD *)Opaque2, v40, v41, *(_QWORD *)(Opaque2 + 24), a4, a5, a6, a7, v16, v17, a10, a11);
v20 = v27;
v21 = v28;
if ( (_DWORD)v28 != 6 )
{
if ( (_DWORD)v28 == 2 )
{
v19[10] = 1;
*a14 = 1;
goto LABEL_7;
}
if ( v19[8] )
{
v39 = v26;
v38 = v27;
PropertyInt64 = JS_GetPropertyInt64(a1, v27, v28, 0LL);
v31 = JS_ToStringFree(a1, PropertyInt64, v30);
v22 = v31;
v18 = v32;
if ( (_DWORD)v32 == 6
|| (_DWORD)v32 == -7
&& (*(_DWORD *)(v31 + 4) & 0x7FFFFFFF) == 0
&& ((Property = (_DWORD *)JS_GetProperty(a1, v39, v40, 86), (int)JS_ToLengthFree(a1, v42, Property, v34) < 0)
|| (v35 = string_advance_index(v41, v42[0], v19[9]),
v36 = js_int64(v35),
(int)JS_SetProperty(a1, v39, v40, 86, v36, v37) < 0)) )
{
v20 = v38;
goto LABEL_6;
}
JS_FreeValue(a1, v22, v18);
v20 = v38;
}
else
{
v19[10] = 1;
}
*a14 = 0;
v24 = v20 & 0xFFFFFFFF00000000LL;
v23 = (unsigned int)v20;
return v24 | v23;
}
LABEL_5:
v22 = 0LL;
LABEL_6:
JS_FreeValue(a1, v20, v21);
JS_FreeValue(a1, v22, v18);
*a14 = 0;
goto LABEL_7;
}
*a14 = 1;
LABEL_7:
v23 = 0LL;
v24 = 0LL;
return v24 | v23;
}
|
js_regexp_string_iterator_next:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV RBX,R9
MOV R15,RDI
PUSH 0x2e
POP RCX
CALL 0x00121207
PUSH 0x3
POP R13
TEST RAX,RAX
JZ 0x00141d00
MOV R12,RAX
CMP dword ptr [RAX + 0x28],0x0
JZ 0x00141d40
MOV dword ptr [RBX],0x1
LAB_00141cfc:
PUSH 0x3
JMP 0x00141d25
LAB_00141d00:
XOR ESI,ESI
MOV R14,R13
LAB_00141d05:
XOR EBP,EBP
LAB_00141d07:
MOV RDI,R15
MOV RDX,R14
CALL 0x0011801e
MOV RDI,R15
MOV RSI,RBP
MOV RDX,R13
CALL 0x0011801e
AND dword ptr [RBX],0x0
PUSH 0x6
LAB_00141d25:
POP R14
XOR EAX,EAX
XOR ECX,ECX
LAB_00141d2b:
OR RAX,RCX
MOV RDX,R14
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00141d40:
MOV RBP,qword ptr [R12]
MOV RDX,qword ptr [R12 + 0x8]
MOV RCX,qword ptr [R12 + 0x10]
MOV R8,qword ptr [R12 + 0x18]
MOV RDI,R15
MOV RSI,RBP
MOV qword ptr [RSP + 0x10],RDX
MOV qword ptr [RSP + 0x18],RCX
CALL 0x0014133b
MOV RSI,RAX
MOV R14,RDX
CMP R14D,0x6
JZ 0x00141d05
CMP R14D,0x2
JNZ 0x00141d89
PUSH 0x1
POP RAX
MOV dword ptr [R12 + 0x28],EAX
MOV dword ptr [RBX],EAX
JMP 0x00141cfc
LAB_00141d89:
CMP dword ptr [R12 + 0x20],0x0
JZ 0x00141de5
MOV qword ptr [RSP + 0x8],RBP
MOV RDI,R15
MOV qword ptr [RSP],RSI
MOV RDX,R14
XOR ECX,ECX
CALL 0x0011e178
MOV RDI,R15
MOV RSI,RAX
CALL 0x0012e049
MOV RBP,RAX
MOV R13,RDX
CMP R13D,0x6
JZ 0x00141e73
CMP R13D,-0x7
JNZ 0x00141dd1
TEST dword ptr [RBP + 0x4],0x7fffffff
JZ 0x00141e08
LAB_00141dd1:
MOV RDI,R15
MOV RSI,RBP
MOV RDX,R13
CALL 0x0011801e
MOV RSI,qword ptr [RSP]
JMP 0x00141dee
LAB_00141de5:
MOV dword ptr [R12 + 0x28],0x1
LAB_00141dee:
AND dword ptr [RBX],0x0
MOV RAX,-0x100000000
MOV RCX,RSI
AND RCX,RAX
MOV EAX,ESI
JMP 0x00141d2b
LAB_00141e08:
PUSH 0x56
POP RCX
MOV RDI,R15
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
CALL 0x0011b043
MOV RCX,RDX
LEA RSI,[RSP + 0x20]
MOV RDI,R15
MOV RDX,RAX
CALL 0x0013daf8
TEST EAX,EAX
JS 0x00141e73
MOV RSI,qword ptr [RSP + 0x20]
MOV EDX,dword ptr [R12 + 0x24]
MOV RDI,qword ptr [RSP + 0x18]
CALL 0x00141551
MOV RDI,RAX
CALL 0x00120a0b
MOV R9,RDX
PUSH 0x56
POP RCX
MOV RDI,R15
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
MOV R8,RAX
CALL 0x0011e446
TEST EAX,EAX
JNS 0x00141dd1
LAB_00141e73:
MOV RSI,qword ptr [RSP]
JMP 0x00141d07
|
int1 [16] js_regexp_string_iterator_next(int8 param_1)
{
int8 uVar1;
int8 uVar2;
int iVar3;
int8 *puVar4;
ulong uVar5;
int8 uVar6;
int8 uVar7;
ulong uVar8;
int4 *in_R9;
int1 auVar9 [16];
int1 auVar10 [16];
int1 auVar11 [16];
int8 uStack_60;
int8 local_38;
puVar4 = (int8 *)JS_GetOpaque2();
if (puVar4 == (int8 *)0x0) {
auVar9 = ZEXT816(3) << 0x40;
LAB_00141d05:
auVar10 = ZEXT816(3) << 0x40;
LAB_00141d07:
JS_FreeValue(param_1,auVar9._0_8_,auVar9._8_8_);
JS_FreeValue(param_1,auVar10._0_8_,auVar10._8_8_);
*in_R9 = 0;
uStack_60 = 6;
}
else {
if (*(int *)(puVar4 + 5) == 0) {
uVar1 = *puVar4;
uVar2 = puVar4[1];
uVar7 = puVar4[2];
auVar9 = JS_RegExpExec(param_1,uVar1,uVar2,uVar7,puVar4[3]);
uStack_60 = auVar9._8_8_;
uVar5 = auVar9._0_8_;
if (auVar9._8_4_ == 6) goto LAB_00141d05;
if (auVar9._8_4_ == 2) {
*(int4 *)(puVar4 + 5) = 1;
*in_R9 = 1;
goto LAB_00141cfc;
}
if (*(int *)(puVar4 + 4) == 0) {
*(int4 *)(puVar4 + 5) = 1;
LAB_00141dee:
*in_R9 = 0;
uVar8 = uVar5 & 0xffffffff00000000;
uVar5 = uVar5 & 0xffffffff;
goto LAB_00141d2b;
}
uVar6 = JS_GetPropertyInt64(param_1,uVar5,uStack_60,0);
auVar10 = JS_ToStringFree(param_1,uVar6);
if (auVar10._8_4_ != 6) {
if ((auVar10._8_4_ != -7) || ((*(uint *)(auVar10._0_8_ + 4) & 0x7fffffff) != 0)) {
LAB_00141dd1:
JS_FreeValue(param_1,auVar10._0_8_,auVar10._8_8_);
goto LAB_00141dee;
}
auVar11 = JS_GetProperty(param_1,uVar1,uVar2,0x56);
iVar3 = JS_ToLengthFree(param_1,&local_38,auVar11._0_8_,auVar11._8_8_);
if (-1 < iVar3) {
uVar7 = string_advance_index(uVar7,local_38,*(int4 *)((long)puVar4 + 0x24));
auVar11 = js_int64(uVar7);
iVar3 = JS_SetProperty(param_1,uVar1,uVar2,0x56,auVar11._0_8_,auVar11._8_8_);
if (-1 < iVar3) goto LAB_00141dd1;
}
}
goto LAB_00141d07;
}
*in_R9 = 1;
LAB_00141cfc:
uStack_60 = 3;
}
uVar5 = 0;
uVar8 = 0;
LAB_00141d2b:
auVar9._0_8_ = uVar5 | uVar8;
auVar9._8_8_ = uStack_60;
return auVar9;
}
|
|
7,831 |
fmt::v10::appender fmt::v10::detail::write<char, fmt::v10::appender>(fmt::v10::appender, char const*)
|
AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/fmt/bundled/format.h
|
FMT_CONSTEXPR_CHAR_TRAITS auto write(OutputIt out, const Char* value)
-> OutputIt {
if (value) return write(out, basic_string_view<Char>(value));
throw_format_error("string pointer is null");
return out;
}
|
O0
|
c
|
fmt::v10::appender fmt::v10::detail::write<char, fmt::v10::appender>(fmt::v10::appender, char const*):
subq $0x48, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
cmpq $0x0, 0x20(%rsp)
je 0xde69d
movq 0x28(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rax
leaq 0x8(%rsp), %rcx
movq %rcx, 0x40(%rsp)
movq %rax, 0x38(%rsp)
movq 0x40(%rsp), %rax
movq %rax, (%rsp)
movq 0x38(%rsp), %rcx
movq %rcx, (%rax)
movq 0x38(%rsp), %rdi
callq 0x152e0
movq %rax, %rcx
movq (%rsp), %rax
movq %rcx, 0x8(%rax)
movq 0x18(%rsp), %rdi
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
callq 0xde6b0
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
addq $0x48, %rsp
retq
leaq 0x73e0f(%rip), %rdi # 0x1524b3
callq 0xc62f0
nopl (%rax)
|
_ZN3fmt3v106detail5writeIcNS0_8appenderEEET0_S4_PKT_:
sub rsp, 48h
mov [rsp+48h+var_20], rdi
mov [rsp+48h+var_28], rsi
cmp [rsp+48h+var_28], 0
jz short loc_DE69D
mov rax, [rsp+48h+var_20]
mov [rsp+48h+var_30], rax
mov rax, [rsp+48h+var_28]
lea rcx, [rsp+48h+var_40]
mov [rsp+48h+var_8], rcx
mov [rsp+48h+var_10], rax
mov rax, [rsp+48h+var_8]
mov [rsp+48h+var_48], rax
mov rcx, [rsp+48h+var_10]
mov [rax], rcx
mov rdi, [rsp+48h+var_10]
call _strlen
mov rcx, rax
mov rax, [rsp+48h+var_48]
mov [rax+8], rcx
mov rdi, [rsp+48h+var_30]
mov rsi, [rsp+48h+var_40]; char *
mov rdx, [rsp+48h+var_38]
call _ZN3fmt3v106detail5writeIcNS0_8appenderEEET0_S4_NS0_17basic_string_viewIT_EE; fmt::v10::detail::write<char,fmt::v10::appender>(fmt::v10::appender,fmt::v10::basic_string_view<char>)
mov [rsp+48h+var_18], rax
mov rax, [rsp+48h+var_18]
add rsp, 48h
retn
loc_DE69D:
lea rdi, aStringPointerI; "string pointer is null"
call _ZN3fmt3v106detail18throw_format_errorEPKc; fmt::v10::detail::throw_format_error(char const*)
|
long long fmt::v10::detail::write<char,fmt::v10::appender>(long long a1, char *a2)
{
long long v2; // rax
long long v3; // r8
long long v4; // r9
long long result; // rax
char *v6; // [rsp+8h] [rbp-40h] BYREF
long long v7; // [rsp+18h] [rbp-30h]
char *v8; // [rsp+20h] [rbp-28h]
long long v9; // [rsp+28h] [rbp-20h]
long long v10; // [rsp+30h] [rbp-18h]
char *v11; // [rsp+38h] [rbp-10h]
char **v12; // [rsp+40h] [rbp-8h]
v9 = a1;
v8 = a2;
if ( !a2 )
fmt::v10::detail::throw_format_error((fmt::v10::detail *)"string pointer is null", 0LL);
v7 = v9;
v12 = &v6;
v11 = v8;
v6 = v8;
v2 = strlen(v8);
result = fmt::v10::detail::write<char,fmt::v10::appender>(v7, v6, v2, v2, v3, v4, &v6, v6, v2, v7, v8, v9);
v10 = result;
return result;
}
|
write<char,fmt::v10::appender>:
SUB RSP,0x48
MOV qword ptr [RSP + 0x28],RDI
MOV qword ptr [RSP + 0x20],RSI
CMP qword ptr [RSP + 0x20],0x0
JZ 0x001de69d
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x18],RAX
MOV RAX,qword ptr [RSP + 0x20]
LEA RCX,[RSP + 0x8]
MOV qword ptr [RSP + 0x40],RCX
MOV qword ptr [RSP + 0x38],RAX
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP],RAX
MOV RCX,qword ptr [RSP + 0x38]
MOV qword ptr [RAX],RCX
MOV RDI,qword ptr [RSP + 0x38]
CALL 0x001152e0
MOV RCX,RAX
MOV RAX,qword ptr [RSP]
MOV qword ptr [RAX + 0x8],RCX
MOV RDI,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
CALL 0x001de6b0
MOV qword ptr [RSP + 0x30],RAX
MOV RAX,qword ptr [RSP + 0x30]
ADD RSP,0x48
RET
LAB_001de69d:
LEA RDI,[0x2524b3]
CALL 0x001c62f0
|
/* fmt::v10::appender fmt::v10::detail::write<char, fmt::v10::appender>(fmt::v10::appender, char
const*) */
int8 fmt::v10::detail::write<char,fmt::v10::appender>(detail *param_1,char *param_2)
{
size_t sVar1;
int8 uVar2;
char *local_40 [2];
detail *local_30;
char *local_28;
detail *local_20;
char *local_10;
char **local_8;
local_28 = param_2;
local_20 = param_1;
if (param_2 != (char *)0x0) {
local_8 = local_40;
local_40[0] = param_2;
local_30 = param_1;
local_10 = param_2;
sVar1 = strlen(param_2);
uVar2 = write<char,fmt::v10::appender>(local_30,local_40[0],sVar1);
return uVar2;
}
/* WARNING: Subroutine does not return */
throw_format_error("string pointer is null");
}
|
|
7,832 |
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::operator->() const
|
hkr04[P]cpp-mcp/common/json.hpp
|
pointer operator->() const
{
JSON_ASSERT(m_object != nullptr);
switch (m_object->m_data.m_type)
{
case value_t::object:
{
JSON_ASSERT(m_it.object_iterator != m_object->m_data.m_value.object->end());
return &(m_it.object_iterator->second);
}
case value_t::array:
{
JSON_ASSERT(m_it.array_iterator != m_object->m_data.m_value.array->end());
return &*m_it.array_iterator;
}
case value_t::null:
case value_t::string:
case value_t::boolean:
case value_t::number_integer:
case value_t::number_unsigned:
case value_t::number_float:
case value_t::binary:
case value_t::discarded:
default:
{
if (JSON_HEDLEY_LIKELY(m_it.primitive_iterator.is_begin()))
{
return m_object;
}
JSON_THROW(invalid_iterator::create(214, "cannot get value", m_object));
}
}
}
|
O0
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::operator->() const:
subq $0x68, %rsp
movq %rdi, 0x58(%rsp)
movq 0x58(%rsp), %rax
movq %rax, 0x10(%rsp)
movq (%rax), %rax
movzbl (%rax), %eax
movq %rax, 0x18(%rsp)
subq $0x9, %rax
ja 0xbb8e3
movq 0x18(%rsp), %rax
leaq 0x17490(%rip), %rcx # 0xd2d30
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq 0x10(%rsp), %rdi
addq $0x8, %rdi
callq 0x72130
addq $0x20, %rax
movq %rax, 0x60(%rsp)
jmp 0xbb9cc
movq 0x10(%rsp), %rdi
addq $0x8, %rdi
addq $0x8, %rdi
callq 0x6c6e0
movq %rax, 0x60(%rsp)
jmp 0xbb9cc
jmp 0xbb8e3
movq 0x10(%rsp), %rdi
addq $0x8, %rdi
addq $0x10, %rdi
callq 0xacce0
xorb $-0x1, %al
xorb $-0x1, %al
testb $0x1, %al
jne 0xbb8ff
jmp 0xbb911
movq 0x10(%rsp), %rax
movq (%rax), %rax
movq %rax, 0x60(%rsp)
jmp 0xbb9cc
movb $0x1, 0x23(%rsp)
movl $0x20, %edi
callq 0xb3d0
movq %rax, (%rsp)
leaq 0x37(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0xbe20
movq 0x8(%rsp), %rdx
leaq 0x18017(%rip), %rsi # 0xd3956
leaq 0x38(%rsp), %rdi
callq 0xf160
jmp 0xbb94b
movq (%rsp), %rdi
movq 0x10(%rsp), %rax
movq (%rax), %rcx
movl $0xd6, %esi
leaq 0x38(%rsp), %rdx
callq 0xac8a0
jmp 0xbb968
movq (%rsp), %rdi
movb $0x0, 0x23(%rsp)
leaq 0x5f120(%rip), %rsi # 0x11aa98
leaq -0xef2f(%rip), %rdx # 0xaca50
callq 0xbd90
jmp 0xbb9e0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x28(%rsp)
movl %eax, 0x24(%rsp)
jmp 0xbb9ae
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x28(%rsp)
movl %eax, 0x24(%rsp)
leaq 0x38(%rsp), %rdi
callq 0xbfb0
leaq 0x37(%rsp), %rdi
callq 0xb8e0
testb $0x1, 0x23(%rsp)
jne 0xbb9c1
jmp 0xbb9ca
movq (%rsp), %rdi
callq 0xb5f0
jmp 0xbb9d6
movq 0x60(%rsp), %rax
addq $0x68, %rsp
retq
movq 0x28(%rsp), %rdi
callq 0xbe10
|
_ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEptEv:
sub rsp, 68h
mov qword ptr [rsp+68h+var_10], rdi; int
mov rax, qword ptr [rsp+68h+var_10]
mov qword ptr [rsp+68h+var_58], rax; int
mov rax, [rax]
movzx eax, byte ptr [rax]
mov qword ptr [rsp+68h+var_50], rax; char
sub rax, 9; switch 10 cases
ja short def_BB8A7; jumptable 00000000000BB8A7 default case
mov rax, qword ptr [rsp+68h+var_50]
lea rcx, jpt_BB8A7
movsxd rax, ds:(jpt_BB8A7 - 0D2D30h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_BB8A9:
mov rdi, qword ptr [rsp+68h+var_58]; jumptable 00000000000BB8A7 case 1
add rdi, 8
call _ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEptEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator->(void)
add rax, 20h ; ' '
mov [rsp+68h+var_8], rax
jmp loc_BB9CC
loc_BB8C5:
mov rdi, qword ptr [rsp+68h+var_58]; jumptable 00000000000BB8A7 case 2
add rdi, 8
add rdi, 8
call _ZNK9__gnu_cxx17__normal_iteratorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES5_IhSaIhEEvEES5_ISF_SaISF_EEEdeEv; __gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::operator*(void)
mov [rsp+68h+var_8], rax
jmp loc_BB9CC
loc_BB8E1:
jmp short $+2; jumptable 00000000000BB8A7 cases 0,3-9
def_BB8A7:
mov rdi, qword ptr [rsp+68h+var_58]; jumptable 00000000000BB8A7 default case
add rdi, 8
add rdi, 10h; this
call _ZNK8nlohmann16json_abi_v3_11_36detail20primitive_iterator_t8is_beginEv; nlohmann::json_abi_v3_11_3::detail::primitive_iterator_t::is_begin(void)
xor al, 0FFh
xor al, 0FFh
test al, 1
jnz short loc_BB8FF
jmp short loc_BB911
loc_BB8FF:
mov rax, qword ptr [rsp+68h+var_58]
mov rax, [rax]
mov [rsp+68h+var_8], rax
jmp loc_BB9CC
loc_BB911:
mov [rsp+68h+var_45], 1
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov [rsp+68h+var_68], rax; int
lea rdi, [rsp+68h+var_31]
mov qword ptr [rsp+68h+var_60], rdi; int
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, qword ptr [rsp+68h+var_60]
lea rsi, aCannotGetValue; "cannot get value"
lea rdi, [rsp+68h+var_31+1]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_BB94B:
mov rdi, [rsp+68h+var_68]; int
mov rax, qword ptr [rsp+68h+var_58]
mov rcx, [rax]
mov esi, 0D6h
lea rdx, [rsp+68h+var_31+1]
call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
jmp short $+2
loc_BB968:
mov rdi, [rsp+68h+var_68]; int
mov [rsp+68h+var_45], 0
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorD2Ev; void (*)(void *)
call ___cxa_throw
jmp short _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_
mov rcx, rax
mov eax, edx
mov [rsp+arg_20], rcx
mov [rsp+arg_1C], eax
jmp short loc_BB9AE
mov rcx, rax
mov eax, edx
mov [rsp+arg_20], rcx
mov [rsp+arg_1C], eax
lea rdi, [rsp+arg_30]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_BB9AE:
lea rdi, [rsp+arg_2F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
test [rsp+arg_1B], 1
jnz short loc_BB9C1
jmp short loc_BB9CA
loc_BB9C1:
mov rdi, [rsp+0]; void *
call ___cxa_free_exception
loc_BB9CA:
jmp short loc_BB9D6
loc_BB9CC:
mov rax, [rsp+68h+var_8]
add rsp, 68h
retn
loc_BB9D6:
mov rdi, [rsp+arg_20]
call __Unwind_Resume
|
long long 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>>::operator->(
long long *a1,
long long a2)
{
long long v2; // rdx
nlohmann::json_abi_v3_11_3::detail::invalid_iterator *exception; // [rsp+0h] [rbp-68h]
int v5[8]; // [rsp+37h] [rbp-31h] BYREF
int v6[2]; // [rsp+58h] [rbp-10h]
long long v7; // [rsp+60h] [rbp-8h]
*(_QWORD *)v6 = a1;
switch ( *(_BYTE *)*a1 )
{
case 1:
v7 = __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator->((long long)(a1 + 1))
+ 32;
break;
case 2:
v7 = __gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *,std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::operator*((long long)(a1 + 2));
break;
default:
if ( !nlohmann::json_abi_v3_11_3::detail::primitive_iterator_t::is_begin((nlohmann::json_abi_v3_11_3::detail::primitive_iterator_t *)(a1 + 3)) )
{
exception = (nlohmann::json_abi_v3_11_3::detail::invalid_iterator *)__cxa_allocate_exception(0x20uLL);
std::allocator<char>::allocator(v5, a2, v2);
std::string::basic_string<std::allocator<char>>((long long)v5 + 1, (long long)"cannot get value", (long long)v5);
ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
exception,
214LL,
(long long)v5 + 1,
*a1);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::invalid_iterator,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::invalid_iterator::~invalid_iterator);
}
v7 = *a1;
break;
}
return v7;
}
|
operator->:
SUB RSP,0x68
MOV qword ptr [RSP + 0x58],RDI
MOV RAX,qword ptr [RSP + 0x58]
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [RAX]
MOVZX EAX,byte ptr [RAX]
MOV qword ptr [RSP + 0x18],RAX
SUB RAX,0x9
JA 0x001bb8e3
MOV RAX,qword ptr [RSP + 0x18]
LEA RCX,[0x1d2d30]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_1:
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0x8
CALL 0x00172130
ADD RAX,0x20
MOV qword ptr [RSP + 0x60],RAX
JMP 0x001bb9cc
caseD_2:
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0x8
ADD RDI,0x8
CALL 0x0016c6e0
MOV qword ptr [RSP + 0x60],RAX
JMP 0x001bb9cc
caseD_0:
JMP 0x001bb8e3
default:
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0x8
ADD RDI,0x10
CALL 0x001acce0
XOR AL,0xff
XOR AL,0xff
TEST AL,0x1
JNZ 0x001bb8ff
JMP 0x001bb911
LAB_001bb8ff:
MOV RAX,qword ptr [RSP + 0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0x60],RAX
JMP 0x001bb9cc
LAB_001bb911:
MOV byte ptr [RSP + 0x23],0x1
MOV EDI,0x20
CALL 0x0010b3d0
MOV qword ptr [RSP],RAX
LEA RDI,[RSP + 0x37]
MOV qword ptr [RSP + 0x8],RDI
CALL 0x0010be20
MOV RDX,qword ptr [RSP + 0x8]
LAB_001bb938:
LEA RSI,[0x1d3956]
LEA RDI,[RSP + 0x38]
CALL 0x0010f160
JMP 0x001bb94b
LAB_001bb94b:
MOV RDI,qword ptr [RSP]
MOV RAX,qword ptr [RSP + 0x10]
MOV RCX,qword ptr [RAX]
LAB_001bb957:
MOV ESI,0xd6
LEA RDX,[RSP + 0x38]
CALL 0x001ac8a0
JMP 0x001bb968
LAB_001bb968:
MOV RDI,qword ptr [RSP]
MOV byte ptr [RSP + 0x23],0x0
LEA RSI,[0x21aa98]
LEA RDX,[0x1aca50]
CALL 0x0010bd90
LAB_001bb9cc:
MOV RAX,qword ptr [RSP + 0x60]
ADD RSP,0x68
RET
|
/* nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >::TEMPNAMEPLACEHOLDERVALUE() const */
long __thiscall
nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::operator->(iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*this)
{
byte bVar1;
int8 uVar2;
allocator local_31;
string local_30 [32];
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>>
*local_10;
long local_8;
local_10 = this;
switch(**(int1 **)this) {
case 0:
case 3:
case 4:
case 5:
case 6:
case 7:
case 8:
case 9:
default:
bVar1 = primitive_iterator_t::is_begin((primitive_iterator_t *)(this + 0x18));
if ((bVar1 & 1) == 0) {
uVar2 = __cxa_allocate_exception(0x20);
std::allocator<char>::allocator();
/* try { // try from 001bb938 to 001bb948 has its CatchHandler @ 001bb986 */
std::__cxx11::string::string<std::allocator<char>>(local_30,"cannot get value",&local_31);
/* try { // try from 001bb957 to 001bb983 has its CatchHandler @ 001bb996 */
_ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar2,0xd6,local_30,*(int8 *)this);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar2,&invalid_iterator::typeinfo,invalid_iterator::~invalid_iterator);
}
local_8 = *(long *)this;
break;
case 1:
local_8 = __gnu_cxx::
__normal_iterator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>*,std::vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>>
::operator->((__normal_iterator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>*,std::vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>>
*)(this + 8));
local_8 = local_8 + 0x20;
break;
case 2:
local_8 = __gnu_cxx::
__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
::operator*((__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
*)(this + 0x10));
}
return local_8;
}
|
|
7,833 |
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::operator->() const
|
hkr04[P]cpp-mcp/common/json.hpp
|
pointer operator->() const
{
JSON_ASSERT(m_object != nullptr);
switch (m_object->m_data.m_type)
{
case value_t::object:
{
JSON_ASSERT(m_it.object_iterator != m_object->m_data.m_value.object->end());
return &(m_it.object_iterator->second);
}
case value_t::array:
{
JSON_ASSERT(m_it.array_iterator != m_object->m_data.m_value.array->end());
return &*m_it.array_iterator;
}
case value_t::null:
case value_t::string:
case value_t::boolean:
case value_t::number_integer:
case value_t::number_unsigned:
case value_t::number_float:
case value_t::binary:
case value_t::discarded:
default:
{
if (JSON_HEDLEY_LIKELY(m_it.primitive_iterator.is_begin()))
{
return m_object;
}
JSON_THROW(invalid_iterator::create(214, "cannot get value", m_object));
}
}
}
|
O1
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::operator->() const:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %r14
movq (%rdi), %rax
movzbl (%rax), %ecx
cmpl $0x2, %ecx
je 0x3c681
cmpl $0x1, %ecx
jne 0x3c687
movq 0x8(%r14), %rax
addq $0x20, %rax
jmp 0x3c68e
movq 0x10(%r14), %rax
jmp 0x3c68e
cmpq $0x0, 0x18(%r14)
jne 0x3c699
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl $0x20, %edi
callq 0x8280
movq %rax, %rbx
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x8633(%rip), %rsi # 0x44ce9
leaq 0x863c(%rip), %rdx # 0x44cf9
leaq 0x8(%rsp), %rdi
callq 0xba4e
movq (%r14), %rcx
movb $0x1, %bpl
leaq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl $0xd6, %esi
callq 0x3624c
xorl %ebp, %ebp
leaq 0x203c0(%rip), %rsi # 0x5caa8
leaq -0x2fdbb(%rip), %rdx # 0xc934
movq %rbx, %rdi
callq 0x8900
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x3c719
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x8580
jmp 0x3c719
movq %rax, %r14
movb $0x1, %bpl
testb %bpl, %bpl
je 0x3c726
movq %rbx, %rdi
callq 0x83e0
movq %r14, %rdi
callq 0x8960
|
_ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEptEv:
push rbp; char
push r15; int
push r14; __int64
push rbx; int
sub rsp, 28h
mov r14, rdi
mov rax, [rdi]
movzx ecx, byte ptr [rax]
cmp ecx, 2
jz short loc_3C681
cmp ecx, 1
jnz short loc_3C687
mov rax, [r14+8]
add rax, 20h ; ' '
jmp short loc_3C68E
loc_3C681:
mov rax, [r14+10h]
jmp short loc_3C68E
loc_3C687:
cmp qword ptr [r14+18h], 0
jnz short loc_3C699
loc_3C68E:
add rsp, 28h
pop rbx
pop r14
pop r15
pop rbp
retn
loc_3C699:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea r15, [rsp+48h+var_30]
mov [r15-10h], r15
lea rsi, aCannotGetValue; "cannot get value"
lea rdx, aCannotGetValue+10h; ""
lea rdi, [rsp+48h+var_40]
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 rcx, [r14]
mov bpl, 1
lea rdx, [rsp+48h+var_40]
mov rdi, rbx; this
mov esi, 0D6h; int
call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
mov rdi, [rsp+48h+var_40]; void *
cmp rdi, r15
jz short loc_3C719
mov rsi, [rsp+48h+var_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_3C719
mov r14, rax
mov bpl, 1
loc_3C719:
test bpl, bpl
jz short loc_3C726
mov rdi, rbx; void *
call ___cxa_free_exception
loc_3C726:
mov rdi, r14
call __Unwind_Resume
|
long long 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>>::operator->(
long long *a1)
{
long long result; // rax
int v2; // ecx
nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx
void *v4[2]; // [rsp+8h] [rbp-40h] BYREF
long long v5; // [rsp+18h] [rbp-30h] BYREF
result = *a1;
v2 = *(unsigned __int8 *)*a1;
if ( v2 == 2 )
return a1[2];
if ( v2 == 1 )
return a1[1] + 32;
if ( a1[3] )
{
exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL);
v4[0] = &v5;
std::string::_M_construct<char const*>(v4, "cannot get value", (long long)"");
ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
exception,
214,
v4);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::invalid_iterator,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
return result;
}
|
operator->:
PUSH RBP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x28
MOV R14,RDI
MOV RAX,qword ptr [RDI]
MOVZX ECX,byte ptr [RAX]
CMP ECX,0x2
JZ 0x0013c681
CMP ECX,0x1
JNZ 0x0013c687
MOV RAX,qword ptr [R14 + 0x8]
ADD RAX,0x20
JMP 0x0013c68e
LAB_0013c681:
MOV RAX,qword ptr [R14 + 0x10]
JMP 0x0013c68e
LAB_0013c687:
CMP qword ptr [R14 + 0x18],0x0
JNZ 0x0013c699
LAB_0013c68e:
ADD RSP,0x28
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_0013c699:
MOV EDI,0x20
CALL 0x00108280
MOV RBX,RAX
LEA R15,[RSP + 0x18]
MOV qword ptr [R15 + -0x10],R15
LAB_0013c6af:
LEA RSI,[0x144ce9]
LEA RDX,[0x144cf9]
LEA RDI,[RSP + 0x8]
CALL 0x0010ba4e
MOV RCX,qword ptr [R14]
MOV BPL,0x1
LAB_0013c6cd:
LEA RDX,[RSP + 0x8]
MOV RDI,RBX
MOV ESI,0xd6
CALL 0x0013624c
XOR EBP,EBP
LEA RSI,[0x15caa8]
LEA RDX,[0x10c934]
MOV RDI,RBX
CALL 0x00108900
|
/* nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >::TEMPNAMEPLACEHOLDERVALUE() const */
char * __thiscall
nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::operator->(iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*this)
{
char *pcVar1;
int8 uVar2;
int1 *local_40 [2];
int1 local_30 [16];
pcVar1 = *(char **)this;
if (*pcVar1 == '\x02') {
pcVar1 = *(char **)(this + 0x10);
}
else if (*pcVar1 == '\x01') {
pcVar1 = (char *)(*(long *)(this + 8) + 0x20);
}
else if (*(long *)(this + 0x18) != 0) {
uVar2 = __cxa_allocate_exception(0x20);
local_40[0] = local_30;
/* try { // try from 0013c6af to 0013c6c6 has its CatchHandler @ 0013c713 */
std::__cxx11::string::_M_construct<char_const*>(local_40,"cannot get value","");
/* try { // try from 0013c6cd to 0013c6f6 has its CatchHandler @ 0013c6f7 */
_ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar2,0xd6,local_40,*(int8 *)this);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar2,&invalid_iterator::typeinfo,exception::~exception);
}
return pcVar1;
}
|
|
7,834 |
mi_state_info_read
|
eloqsql/storage/myisam/mi_open.c
|
uchar *mi_state_info_read(uchar *ptr, MI_STATE_INFO *state)
{
uint i,keys,key_parts,key_blocks;
memcpy(&state->header, ptr, sizeof(state->header));
ptr +=sizeof(state->header);
keys=(uint) state->header.keys;
key_parts=mi_uint2korr(state->header.key_parts);
key_blocks=state->header.max_block_size_index;
state->open_count = mi_uint2korr(ptr); ptr +=2;
state->changed= *ptr++;
state->sortkey = (uint) *ptr++;
state->state.records= mi_rowkorr(ptr); ptr +=8;
state->state.del = mi_rowkorr(ptr); ptr +=8;
state->split = mi_rowkorr(ptr); ptr +=8;
state->dellink= mi_sizekorr(ptr); ptr +=8;
state->state.key_file_length = mi_sizekorr(ptr); ptr +=8;
state->state.data_file_length= mi_sizekorr(ptr); ptr +=8;
state->state.empty = mi_sizekorr(ptr); ptr +=8;
state->state.key_empty= mi_sizekorr(ptr); ptr +=8;
state->auto_increment=mi_uint8korr(ptr); ptr +=8;
state->state.checksum=(ha_checksum) mi_uint8korr(ptr); ptr +=8;
state->process= mi_uint4korr(ptr); ptr +=4;
state->unique = mi_uint4korr(ptr); ptr +=4;
state->status = mi_uint4korr(ptr); ptr +=4;
state->update_count=mi_uint4korr(ptr); ptr +=4;
ptr+= state->state_diff_length;
if (!state->rec_per_key_part)
{
if (!my_multi_malloc(mi_key_memory_MYISAM_SHARE, MYF(MY_WME),
&state->rec_per_key_part,sizeof(long)*key_parts,
&state->key_root, keys*sizeof(my_off_t),
&state->key_del, key_blocks*sizeof(my_off_t),
NullS))
return(0);
}
for (i=0; i < keys; i++)
{
state->key_root[i]= mi_sizekorr(ptr); ptr +=8;
}
for (i=0; i < key_blocks; i++)
{
state->key_del[i] = mi_sizekorr(ptr); ptr +=8;
}
state->sec_index_changed = mi_uint4korr(ptr); ptr +=4;
state->sec_index_used = mi_uint4korr(ptr); ptr +=4;
state->version = mi_uint4korr(ptr); ptr +=4;
state->key_map = mi_uint8korr(ptr); ptr +=8;
state->create_time = (time_t) mi_sizekorr(ptr); ptr +=8;
state->recover_time =(time_t) mi_sizekorr(ptr); ptr +=8;
state->check_time = (time_t) mi_sizekorr(ptr); ptr +=8;
state->rec_per_key_rows=mi_sizekorr(ptr); ptr +=8;
for (i=0 ; i < key_parts ; i++)
{
state->rec_per_key_part[i]= mi_uint4korr(ptr); ptr+=4;
}
return ptr;
}
|
O3
|
c
|
mi_state_info_read:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %rbx
movq %rdi, %r12
movq 0x10(%rdi), %rax
movq %rax, 0x10(%rsi)
movups (%rdi), %xmm0
movups %xmm0, (%rsi)
movzbl 0x12(%rsi), %r14d
movzbl 0xf(%rsi), %edi
movzbl 0xe(%rsi), %esi
shll $0x8, %esi
leal (%rsi,%rdi), %r8d
movzbl 0x15(%rbx), %r13d
movzwl 0x18(%r12), %eax
rolw $0x8, %ax
movzwl %ax, %eax
movl %eax, 0xec(%rbx)
movb 0x1a(%r12), %al
movb %al, 0xf0(%rbx)
movzbl 0x1b(%r12), %eax
movl %eax, 0xe8(%rbx)
movq 0x1c(%r12), %rax
bswapq %rax
movq %rax, 0x18(%rbx)
movq 0x24(%r12), %rax
bswapq %rax
movq %rax, 0x20(%rbx)
movq 0x2c(%r12), %rax
bswapq %rax
movq %rax, 0x50(%rbx)
movq 0x34(%r12), %rax
bswapq %rax
movq %rax, 0x58(%rbx)
movq 0x3c(%r12), %rax
bswapq %rax
movq %rax, 0x38(%rbx)
movq 0x44(%r12), %rax
bswapq %rax
movq %rax, 0x40(%rbx)
movq 0x4c(%r12), %rax
bswapq %rax
movq %rax, 0x28(%rbx)
movq 0x54(%r12), %rax
bswapq %rax
movq %rax, 0x30(%rbx)
movq 0x5c(%r12), %rax
bswapq %rax
movq %rax, 0x60(%rbx)
movl 0x68(%r12), %eax
bswapl %eax
movl %eax, 0x48(%rbx)
movl 0x6c(%r12), %eax
bswapl %eax
movq %rax, 0x68(%rbx)
movl 0x70(%r12), %eax
bswapl %eax
movq %rax, 0x70(%rbx)
movl 0x74(%r12), %eax
bswapl %eax
movq %rax, 0x80(%rbx)
movl 0x78(%r12), %eax
bswapl %eax
movq %rax, 0x78(%rbx)
movl 0xf4(%rbx), %eax
leaq 0x88(%rbx), %r9
cmpq $0x0, 0x88(%rbx)
jne 0x7fcc8
movq %rax, -0x38(%rbp)
leaq 0xb7f996(%rip), %rax # 0xbff5e8
movq %rdi, -0x48(%rbp)
movl (%rax), %edi
leal (,%r8,8), %ecx
movq %r8, -0x40(%rbp)
leaq 0x98(%rbx), %r8
movq %r9, -0x30(%rbp)
leal (,%r14,8), %r9d
leaq 0xa0(%rbx), %r10
leal (,%r13,8), %r11d
subq $0x8, %rsp
xorl %r15d, %r15d
movq %rsi, -0x50(%rbp)
movl $0x10, %esi
movq -0x30(%rbp), %rdx
xorl %eax, %eax
pushq $0x0
pushq %r11
pushq %r10
callq 0x9cfd8
movq -0x30(%rbp), %r9
movq -0x40(%rbp), %r8
movq -0x48(%rbp), %rdi
movq -0x50(%rbp), %rsi
addq $0x20, %rsp
testq %rax, %rax
movq -0x38(%rbp), %rax
je 0x7fdb7
leaq (%r12,%rax), %r15
addq $0x7c, %r15
testq %r14, %r14
je 0x7fcf9
shll $0x3, %r14d
xorl %eax, %eax
movq (%r15,%rax), %rcx
bswapq %rcx
movq 0x98(%rbx), %rdx
movq %rcx, (%rdx,%rax)
addq $0x8, %rax
cmpq %rax, %r14
jne 0x7fcdb
addq %rax, %r15
testq %r13, %r13
je 0x7fd22
shll $0x3, %r13d
xorl %eax, %eax
movq (%r15,%rax), %rcx
bswapq %rcx
movq 0xa0(%rbx), %rdx
movq %rcx, (%rdx,%rax)
addq $0x8, %rax
cmpq %rax, %r13
jne 0x7fd04
addq %rax, %r15
movl (%r15), %eax
bswapl %eax
movq %rax, 0xb0(%rbx)
movl 0x4(%r15), %eax
bswapl %eax
movq %rax, 0xb8(%rbx)
movl 0x8(%r15), %eax
bswapl %eax
movq %rax, 0xc8(%rbx)
movq 0xc(%r15), %rax
bswapq %rax
movq %rax, 0xc0(%rbx)
movq 0x14(%r15), %rax
bswapq %rax
movq %rax, 0xd0(%rbx)
movq 0x1c(%r15), %rax
bswapq %rax
movq %rax, 0xd8(%rbx)
movq 0x24(%r15), %rax
bswapq %rax
movq %rax, 0xe0(%rbx)
movq 0x2c(%r15), %rax
bswapq %rax
movq %rax, 0xa8(%rbx)
addq $0x34, %r15
testl %r8d, %r8d
je 0x7fdb7
orl %edi, %esi
shll $0x2, %esi
xorl %eax, %eax
movl (%r15,%rax), %ecx
bswapl %ecx
movq (%r9), %rdx
movq %rcx, (%rdx,%rax,2)
addq $0x4, %rax
cmpq %rax, %rsi
jne 0x7fd9e
addq %rax, %r15
movq %r15, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
mi_state_info_read:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov rbx, rsi
mov r12, rdi
mov rax, [rdi+10h]
mov [rsi+10h], rax
movups xmm0, xmmword ptr [rdi]
movups xmmword ptr [rsi], xmm0
movzx r14d, byte ptr [rsi+12h]
movzx edi, byte ptr [rsi+0Fh]
movzx esi, byte ptr [rsi+0Eh]
shl esi, 8
lea r8d, [rsi+rdi]
movzx r13d, byte ptr [rbx+15h]
movzx eax, word ptr [r12+18h]
rol ax, 8
movzx eax, ax
mov [rbx+0ECh], eax
mov al, [r12+1Ah]
mov [rbx+0F0h], al
movzx eax, byte ptr [r12+1Bh]
mov [rbx+0E8h], eax
mov rax, [r12+1Ch]
bswap rax
mov [rbx+18h], rax
mov rax, [r12+24h]
bswap rax
mov [rbx+20h], rax
mov rax, [r12+2Ch]
bswap rax
mov [rbx+50h], rax
mov rax, [r12+34h]
bswap rax
mov [rbx+58h], rax
mov rax, [r12+3Ch]
bswap rax
mov [rbx+38h], rax
mov rax, [r12+44h]
bswap rax
mov [rbx+40h], rax
mov rax, [r12+4Ch]
bswap rax
mov [rbx+28h], rax
mov rax, [r12+54h]
bswap rax
mov [rbx+30h], rax
mov rax, [r12+5Ch]
bswap rax
mov [rbx+60h], rax
mov eax, [r12+68h]
bswap eax
mov [rbx+48h], eax
mov eax, [r12+6Ch]
bswap eax
mov [rbx+68h], rax
mov eax, [r12+70h]
bswap eax
mov [rbx+70h], rax
mov eax, [r12+74h]
bswap eax
mov [rbx+80h], rax
mov eax, [r12+78h]
bswap eax
mov [rbx+78h], rax
mov eax, [rbx+0F4h]
lea r9, [rbx+88h]
cmp qword ptr [rbx+88h], 0
jnz loc_7FCC8
mov [rbp+var_38], rax
lea rax, mi_key_memory_MYISAM_SHARE
mov [rbp+var_48], rdi
mov edi, [rax]
lea ecx, ds:0[r8*8]
mov [rbp+var_40], r8
lea r8, [rbx+98h]
mov [rbp+var_30], r9
lea r9d, ds:0[r14*8]
lea r10, [rbx+0A0h]
lea r11d, ds:0[r13*8]
sub rsp, 8
xor r15d, r15d
mov [rbp+var_50], rsi
mov esi, 10h
mov rdx, [rbp+var_30]
xor eax, eax
push 0
push r11
push r10
call my_multi_malloc
mov r9, [rbp+var_30]
mov r8, [rbp+var_40]
mov rdi, [rbp+var_48]
mov rsi, [rbp+var_50]
add rsp, 20h
test rax, rax
mov rax, [rbp+var_38]
jz loc_7FDB7
loc_7FCC8:
lea r15, [r12+rax]
add r15, 7Ch ; '|'
test r14, r14
jz short loc_7FCF9
shl r14d, 3
xor eax, eax
loc_7FCDB:
mov rcx, [r15+rax]
bswap rcx
mov rdx, [rbx+98h]
mov [rdx+rax], rcx
add rax, 8
cmp r14, rax
jnz short loc_7FCDB
add r15, rax
loc_7FCF9:
test r13, r13
jz short loc_7FD22
shl r13d, 3
xor eax, eax
loc_7FD04:
mov rcx, [r15+rax]
bswap rcx
mov rdx, [rbx+0A0h]
mov [rdx+rax], rcx
add rax, 8
cmp r13, rax
jnz short loc_7FD04
add r15, rax
loc_7FD22:
mov eax, [r15]
bswap eax
mov [rbx+0B0h], rax
mov eax, [r15+4]
bswap eax
mov [rbx+0B8h], rax
mov eax, [r15+8]
bswap eax
mov [rbx+0C8h], rax
mov rax, [r15+0Ch]
bswap rax
mov [rbx+0C0h], rax
mov rax, [r15+14h]
bswap rax
mov [rbx+0D0h], rax
mov rax, [r15+1Ch]
bswap rax
mov [rbx+0D8h], rax
mov rax, [r15+24h]
bswap rax
mov [rbx+0E0h], rax
mov rax, [r15+2Ch]
bswap rax
mov [rbx+0A8h], rax
add r15, 34h ; '4'
test r8d, r8d
jz short loc_7FDB7
or esi, edi
shl esi, 2
xor eax, eax
loc_7FD9E:
mov ecx, [r15+rax]
bswap ecx
mov rdx, [r9]
mov [rdx+rax*2], rcx
add rax, 4
cmp rsi, rax
jnz short loc_7FD9E
add r15, rax
loc_7FDB7:
mov rax, r15
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long mi_state_info_read(long long a1, long long a2)
{
long long v4; // r14
int v5; // edi
int v6; // esi
int v7; // r8d
long long v8; // r13
long long v9; // rax
_QWORD *v10; // r9
long long v11; // r15
long long v12; // rax
bool v13; // zf
long long v14; // r15
long long v15; // r14
long long v16; // rax
long long v17; // r13
long long v18; // rax
long long v19; // rsi
long long v20; // rax
long long v22; // [rsp+18h] [rbp-38h]
*(_QWORD *)(a2 + 16) = *(_QWORD *)(a1 + 16);
*(_OWORD *)a2 = *(_OWORD *)a1;
v4 = *(unsigned __int8 *)(a2 + 18);
v5 = *(unsigned __int8 *)(a2 + 15);
v6 = *(unsigned __int8 *)(a2 + 14) << 8;
v7 = v6 + v5;
v8 = *(unsigned __int8 *)(a2 + 21);
*(_DWORD *)(a2 + 236) = (unsigned __int16)__ROL2__(*(_WORD *)(a1 + 24), 8);
*(_BYTE *)(a2 + 240) = *(_BYTE *)(a1 + 26);
*(_DWORD *)(a2 + 232) = *(unsigned __int8 *)(a1 + 27);
*(_QWORD *)(a2 + 24) = _byteswap_uint64(*(_QWORD *)(a1 + 28));
*(_QWORD *)(a2 + 32) = _byteswap_uint64(*(_QWORD *)(a1 + 36));
*(_QWORD *)(a2 + 80) = _byteswap_uint64(*(_QWORD *)(a1 + 44));
*(_QWORD *)(a2 + 88) = _byteswap_uint64(*(_QWORD *)(a1 + 52));
*(_QWORD *)(a2 + 56) = _byteswap_uint64(*(_QWORD *)(a1 + 60));
*(_QWORD *)(a2 + 64) = _byteswap_uint64(*(_QWORD *)(a1 + 68));
*(_QWORD *)(a2 + 40) = _byteswap_uint64(*(_QWORD *)(a1 + 76));
*(_QWORD *)(a2 + 48) = _byteswap_uint64(*(_QWORD *)(a1 + 84));
*(_QWORD *)(a2 + 96) = _byteswap_uint64(*(_QWORD *)(a1 + 92));
*(_DWORD *)(a2 + 72) = _byteswap_ulong(*(_DWORD *)(a1 + 104));
*(_QWORD *)(a2 + 104) = _byteswap_ulong(*(_DWORD *)(a1 + 108));
*(_QWORD *)(a2 + 112) = _byteswap_ulong(*(_DWORD *)(a1 + 112));
*(_QWORD *)(a2 + 128) = _byteswap_ulong(*(_DWORD *)(a1 + 116));
*(_QWORD *)(a2 + 120) = _byteswap_ulong(*(_DWORD *)(a1 + 120));
v9 = *(unsigned int *)(a2 + 244);
v10 = (_QWORD *)(a2 + 136);
if ( *(_QWORD *)(a2 + 136)
|| (v22 = *(unsigned int *)(a2 + 244),
v11 = 0LL,
v12 = my_multi_malloc(
mi_key_memory_MYISAM_SHARE,
16,
(int)a2 + 136,
8 * v7,
(int)a2 + 152,
8 * (int)v4,
a2 + 160,
(unsigned int)(8 * v8),
0LL),
v10 = (_QWORD *)(a2 + 136),
v7 = v6 + v5,
v13 = v12 == 0,
v9 = v22,
!v13) )
{
v14 = a1 + v9 + 124;
if ( v4 )
{
v15 = (unsigned int)(8 * v4);
v16 = 0LL;
do
{
*(_QWORD *)(*(_QWORD *)(a2 + 152) + v16) = _byteswap_uint64(*(_QWORD *)(v14 + v16));
v16 += 8LL;
}
while ( v15 != v16 );
v14 += v16;
}
if ( v8 )
{
v17 = (unsigned int)(8 * v8);
v18 = 0LL;
do
{
*(_QWORD *)(*(_QWORD *)(a2 + 160) + v18) = _byteswap_uint64(*(_QWORD *)(v14 + v18));
v18 += 8LL;
}
while ( v17 != v18 );
v14 += v18;
}
*(_QWORD *)(a2 + 176) = _byteswap_ulong(*(_DWORD *)v14);
*(_QWORD *)(a2 + 184) = _byteswap_ulong(*(_DWORD *)(v14 + 4));
*(_QWORD *)(a2 + 200) = _byteswap_ulong(*(_DWORD *)(v14 + 8));
*(_QWORD *)(a2 + 192) = _byteswap_uint64(*(_QWORD *)(v14 + 12));
*(_QWORD *)(a2 + 208) = _byteswap_uint64(*(_QWORD *)(v14 + 20));
*(_QWORD *)(a2 + 216) = _byteswap_uint64(*(_QWORD *)(v14 + 28));
*(_QWORD *)(a2 + 224) = _byteswap_uint64(*(_QWORD *)(v14 + 36));
*(_QWORD *)(a2 + 168) = _byteswap_uint64(*(_QWORD *)(v14 + 44));
v11 = v14 + 52;
if ( v7 )
{
v19 = 4 * (v5 | (unsigned int)v6);
v20 = 0LL;
do
{
*(_QWORD *)(*v10 + 2 * v20) = _byteswap_ulong(*(_DWORD *)(v11 + v20));
v20 += 4LL;
}
while ( v19 != v20 );
v11 += v20;
}
}
return v11;
}
|
mi_state_info_read:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV RBX,RSI
MOV R12,RDI
MOV RAX,qword ptr [RDI + 0x10]
MOV qword ptr [RSI + 0x10],RAX
MOVUPS XMM0,xmmword ptr [RDI]
MOVUPS xmmword ptr [RSI],XMM0
MOVZX R14D,byte ptr [RSI + 0x12]
MOVZX EDI,byte ptr [RSI + 0xf]
MOVZX ESI,byte ptr [RSI + 0xe]
SHL ESI,0x8
LEA R8D,[RSI + RDI*0x1]
MOVZX R13D,byte ptr [RBX + 0x15]
MOVZX EAX,word ptr [R12 + 0x18]
ROL AX,0x8
MOVZX EAX,AX
MOV dword ptr [RBX + 0xec],EAX
MOV AL,byte ptr [R12 + 0x1a]
MOV byte ptr [RBX + 0xf0],AL
MOVZX EAX,byte ptr [R12 + 0x1b]
MOV dword ptr [RBX + 0xe8],EAX
MOV RAX,qword ptr [R12 + 0x1c]
BSWAP RAX
MOV qword ptr [RBX + 0x18],RAX
MOV RAX,qword ptr [R12 + 0x24]
BSWAP RAX
MOV qword ptr [RBX + 0x20],RAX
MOV RAX,qword ptr [R12 + 0x2c]
BSWAP RAX
MOV qword ptr [RBX + 0x50],RAX
MOV RAX,qword ptr [R12 + 0x34]
BSWAP RAX
MOV qword ptr [RBX + 0x58],RAX
MOV RAX,qword ptr [R12 + 0x3c]
BSWAP RAX
MOV qword ptr [RBX + 0x38],RAX
MOV RAX,qword ptr [R12 + 0x44]
BSWAP RAX
MOV qword ptr [RBX + 0x40],RAX
MOV RAX,qword ptr [R12 + 0x4c]
BSWAP RAX
MOV qword ptr [RBX + 0x28],RAX
MOV RAX,qword ptr [R12 + 0x54]
BSWAP RAX
MOV qword ptr [RBX + 0x30],RAX
MOV RAX,qword ptr [R12 + 0x5c]
BSWAP RAX
MOV qword ptr [RBX + 0x60],RAX
MOV EAX,dword ptr [R12 + 0x68]
BSWAP EAX
MOV dword ptr [RBX + 0x48],EAX
MOV EAX,dword ptr [R12 + 0x6c]
BSWAP EAX
MOV qword ptr [RBX + 0x68],RAX
MOV EAX,dword ptr [R12 + 0x70]
BSWAP EAX
MOV qword ptr [RBX + 0x70],RAX
MOV EAX,dword ptr [R12 + 0x74]
BSWAP EAX
MOV qword ptr [RBX + 0x80],RAX
MOV EAX,dword ptr [R12 + 0x78]
BSWAP EAX
MOV qword ptr [RBX + 0x78],RAX
MOV EAX,dword ptr [RBX + 0xf4]
LEA R9,[RBX + 0x88]
CMP qword ptr [RBX + 0x88],0x0
JNZ 0x0017fcc8
MOV qword ptr [RBP + -0x38],RAX
LEA RAX,[0xcff5e8]
MOV qword ptr [RBP + -0x48],RDI
MOV EDI,dword ptr [RAX]
LEA ECX,[R8*0x8]
MOV qword ptr [RBP + -0x40],R8
LEA R8,[RBX + 0x98]
MOV qword ptr [RBP + -0x30],R9
LEA R9D,[R14*0x8]
LEA R10,[RBX + 0xa0]
LEA R11D,[R13*0x8]
SUB RSP,0x8
XOR R15D,R15D
MOV qword ptr [RBP + -0x50],RSI
MOV ESI,0x10
MOV RDX,qword ptr [RBP + -0x30]
XOR EAX,EAX
PUSH 0x0
PUSH R11
PUSH R10
CALL 0x0019cfd8
MOV R9,qword ptr [RBP + -0x30]
MOV R8,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [RBP + -0x48]
MOV RSI,qword ptr [RBP + -0x50]
ADD RSP,0x20
TEST RAX,RAX
MOV RAX,qword ptr [RBP + -0x38]
JZ 0x0017fdb7
LAB_0017fcc8:
LEA R15,[R12 + RAX*0x1]
ADD R15,0x7c
TEST R14,R14
JZ 0x0017fcf9
SHL R14D,0x3
XOR EAX,EAX
LAB_0017fcdb:
MOV RCX,qword ptr [R15 + RAX*0x1]
BSWAP RCX
MOV RDX,qword ptr [RBX + 0x98]
MOV qword ptr [RDX + RAX*0x1],RCX
ADD RAX,0x8
CMP R14,RAX
JNZ 0x0017fcdb
ADD R15,RAX
LAB_0017fcf9:
TEST R13,R13
JZ 0x0017fd22
SHL R13D,0x3
XOR EAX,EAX
LAB_0017fd04:
MOV RCX,qword ptr [R15 + RAX*0x1]
BSWAP RCX
MOV RDX,qword ptr [RBX + 0xa0]
MOV qword ptr [RDX + RAX*0x1],RCX
ADD RAX,0x8
CMP R13,RAX
JNZ 0x0017fd04
ADD R15,RAX
LAB_0017fd22:
MOV EAX,dword ptr [R15]
BSWAP EAX
MOV qword ptr [RBX + 0xb0],RAX
MOV EAX,dword ptr [R15 + 0x4]
BSWAP EAX
MOV qword ptr [RBX + 0xb8],RAX
MOV EAX,dword ptr [R15 + 0x8]
BSWAP EAX
MOV qword ptr [RBX + 0xc8],RAX
MOV RAX,qword ptr [R15 + 0xc]
BSWAP RAX
MOV qword ptr [RBX + 0xc0],RAX
MOV RAX,qword ptr [R15 + 0x14]
BSWAP RAX
MOV qword ptr [RBX + 0xd0],RAX
MOV RAX,qword ptr [R15 + 0x1c]
BSWAP RAX
MOV qword ptr [RBX + 0xd8],RAX
MOV RAX,qword ptr [R15 + 0x24]
BSWAP RAX
MOV qword ptr [RBX + 0xe0],RAX
MOV RAX,qword ptr [R15 + 0x2c]
BSWAP RAX
MOV qword ptr [RBX + 0xa8],RAX
ADD R15,0x34
TEST R8D,R8D
JZ 0x0017fdb7
OR ESI,EDI
SHL ESI,0x2
XOR EAX,EAX
LAB_0017fd9e:
MOV ECX,dword ptr [R15 + RAX*0x1]
BSWAP ECX
MOV RDX,qword ptr [R9]
MOV qword ptr [RDX + RAX*0x2],RCX
ADD RAX,0x4
CMP RSI,RAX
JNZ 0x0017fd9e
ADD R15,RAX
LAB_0017fdb7:
MOV RAX,R15
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
uint * mi_state_info_read(int4 *param_1,int4 *param_2)
{
byte bVar1;
byte bVar2;
byte bVar3;
byte bVar4;
uint uVar5;
ulong uVar6;
int4 uVar7;
int4 uVar8;
int4 uVar9;
long lVar10;
int iVar11;
uint *puVar12;
*(int8 *)(param_2 + 4) = *(int8 *)(param_1 + 4);
uVar7 = param_1[1];
uVar8 = param_1[2];
uVar9 = param_1[3];
*param_2 = *param_1;
param_2[1] = uVar7;
param_2[2] = uVar8;
param_2[3] = uVar9;
bVar1 = *(byte *)((long)param_2 + 0x12);
bVar2 = *(byte *)((long)param_2 + 0xf);
bVar3 = *(byte *)((long)param_2 + 0xe);
iVar11 = (uint)bVar3 * 0x100 + (uint)bVar2;
bVar4 = *(byte *)((long)param_2 + 0x15);
param_2[0x3b] = (uint)(ushort)(*(ushort *)(param_1 + 6) << 8 | *(ushort *)(param_1 + 6) >> 8);
*(int1 *)(param_2 + 0x3c) = *(int1 *)((long)param_1 + 0x1a);
param_2[0x3a] = (uint)*(byte *)((long)param_1 + 0x1b);
uVar6 = *(ulong *)(param_1 + 7);
*(ulong *)(param_2 + 6) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(param_1 + 9);
*(ulong *)(param_2 + 8) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(param_1 + 0xb);
*(ulong *)(param_2 + 0x14) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(param_1 + 0xd);
*(ulong *)(param_2 + 0x16) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(param_1 + 0xf);
*(ulong *)(param_2 + 0xe) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(param_1 + 0x11);
*(ulong *)(param_2 + 0x10) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(param_1 + 0x13);
*(ulong *)(param_2 + 10) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(param_1 + 0x15);
*(ulong *)(param_2 + 0xc) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(param_1 + 0x17);
*(ulong *)(param_2 + 0x18) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar5 = param_1[0x1a];
param_2[0x12] = uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18;
uVar5 = param_1[0x1b];
*(ulong *)(param_2 + 0x1a) =
(ulong)(uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18);
uVar5 = param_1[0x1c];
*(ulong *)(param_2 + 0x1c) =
(ulong)(uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18);
uVar5 = param_1[0x1d];
*(ulong *)(param_2 + 0x20) =
(ulong)(uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18);
uVar5 = param_1[0x1e];
*(ulong *)(param_2 + 0x1e) =
(ulong)(uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18);
uVar5 = param_2[0x3d];
if ((*(long *)(param_2 + 0x22) == 0) &&
(lVar10 = my_multi_malloc(mi_key_memory_MYISAM_SHARE,0x10,param_2 + 0x22,iVar11 * 8,
param_2 + 0x26,(uint)bVar1 * 8,param_2 + 0x28,(uint)bVar4 * 8,0),
lVar10 == 0)) {
return (uint *)0x0;
}
puVar12 = (uint *)((long)param_1 + (ulong)uVar5 + 0x7c);
if (bVar1 != 0) {
lVar10 = 0;
do {
uVar6 = *(ulong *)((long)puVar12 + lVar10);
*(ulong *)(*(long *)(param_2 + 0x26) + lVar10) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
lVar10 = lVar10 + 8;
} while ((ulong)bVar1 * 8 != lVar10);
puVar12 = (uint *)((long)puVar12 + lVar10);
}
if (bVar4 != 0) {
lVar10 = 0;
do {
uVar6 = *(ulong *)((long)puVar12 + lVar10);
*(ulong *)(*(long *)(param_2 + 0x28) + lVar10) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
lVar10 = lVar10 + 8;
} while ((ulong)bVar4 * 8 != lVar10);
puVar12 = (uint *)((long)puVar12 + lVar10);
}
uVar5 = *puVar12;
*(ulong *)(param_2 + 0x2c) =
(ulong)(uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18);
uVar5 = puVar12[1];
*(ulong *)(param_2 + 0x2e) =
(ulong)(uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18);
uVar5 = puVar12[2];
*(ulong *)(param_2 + 0x32) =
(ulong)(uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18);
uVar6 = *(ulong *)(puVar12 + 3);
*(ulong *)(param_2 + 0x30) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(puVar12 + 5);
*(ulong *)(param_2 + 0x34) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(puVar12 + 7);
*(ulong *)(param_2 + 0x36) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(puVar12 + 9);
*(ulong *)(param_2 + 0x38) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
uVar6 = *(ulong *)(puVar12 + 0xb);
*(ulong *)(param_2 + 0x2a) =
uVar6 >> 0x38 | (uVar6 & 0xff000000000000) >> 0x28 | (uVar6 & 0xff0000000000) >> 0x18 |
(uVar6 & 0xff00000000) >> 8 | (uVar6 & 0xff000000) << 8 | (uVar6 & 0xff0000) << 0x18 |
(uVar6 & 0xff00) << 0x28 | uVar6 << 0x38;
puVar12 = puVar12 + 0xd;
if (iVar11 != 0) {
lVar10 = 0;
do {
uVar5 = *(uint *)((long)puVar12 + lVar10);
*(ulong *)(*(long *)(param_2 + 0x22) + lVar10 * 2) =
(ulong)(uVar5 >> 0x18 | (uVar5 & 0xff0000) >> 8 | (uVar5 & 0xff00) << 8 | uVar5 << 0x18);
lVar10 = lVar10 + 4;
} while ((ulong)CONCAT11(bVar3,bVar2) << 2 != lVar10);
puVar12 = (uint *)((long)puVar12 + lVar10);
}
return puVar12;
}
|
|
7,835 |
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::parse<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, std::function<bool (int, nlohmann::json_abi_v3_11_3::detail::parse_event_t, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__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>&)>, bool, bool)
|
monkey531[P]llama/common/json.hpp
|
JSON_HEDLEY_WARN_UNUSED_RESULT
static basic_json parse(InputType&& i,
const parser_callback_t cb = nullptr,
const bool allow_exceptions = true,
const bool ignore_comments = false)
{
basic_json result;
parser(detail::input_adapter(std::forward<InputType>(i)), cb, allow_exceptions, ignore_comments).parse(true, result);
return result;
}
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::parse<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, std::function<bool (int, nlohmann::json_abi_v3_11_3::detail::parse_event_t, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__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>&)>, bool, bool):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movl %r8d, %ebp
movl %ecx, %r14d
movq %rdx, %r13
movq %rsi, %r12
movq %rdi, %rbx
movb $0x0, (%rdi)
movq $0x0, 0x8(%rdi)
movl $0x1, %esi
callq 0x58f20
movq %rbx, %rdi
movl $0x1, %esi
callq 0x58f20
movq (%r12), %r15
movq 0x8(%r12), %r12
movq %rsp, %rdi
movq %r13, %rsi
callq 0x588c2
addq %r15, %r12
movzbl %r14b, %r8d
movzbl %bpl, %r9d
leaq 0x20(%rsp), %rdi
movq %rsp, %rcx
movq %r15, %rsi
movq %r12, %rdx
callq 0x58816
leaq 0x20(%rsp), %rdi
movl $0x1, %esi
movq %rbx, %rdx
callq 0x58920
leaq 0x48(%rsp), %r14
movq %r14, %rdi
callq 0x59452
movq -0x18(%r14), %rax
testq %rax, %rax
je 0x8c8af
leaq 0x20(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0x8c8c6
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x8c90a
jmp 0x8c90a
movq %rax, %r14
leaq 0x20(%rsp), %rdi
callq 0x58ef2
jmp 0x8c8f1
movq %rax, %r14
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0x8c915
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x8c915
movq %rax, %rdi
callq 0x22203
movq %rax, %r14
movq %rbx, %rdi
xorl %esi, %esi
callq 0x58f20
movq %rbx, %rdi
callq 0x5e40e
movq %r14, %rdi
callq 0x1af90
nop
|
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5parseIRS9_EESD_OT_St8functionIFbiNS0_6detail13parse_event_tERSD_EEbb:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0E8h
mov ebp, r8d
mov r14d, ecx
mov r13, rdx
mov r12, rsi
mov rbx, rdi
mov byte ptr [rdi], 0
mov qword ptr [rdi+8], 0
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, rbx
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov r15, [r12]
mov r12, [r12+8]
mov rdi, rsp
mov rsi, r13
call _ZNSt8functionIFbiN8nlohmann16json_abi_v3_11_36detail13parse_event_tERNS1_10basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES6_IhSaIhEEvEEEEC2ERKSJ_; std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &)>::function(std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &)> const&)
add r12, r15
movzx r8d, r14b
movzx r9d, bpl
lea rdi, [rsp+118h+var_F8]
mov rcx, rsp
mov rsi, r15
mov rdx, r12
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6parserINS0_6detail22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcS9_EEEEEENSF_6parserISD_T_EESO_St8functionIFbiNSF_13parse_event_tERSD_EEbb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>(nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>,std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&)>,bool,bool)
lea rdi, [rsp+118h+var_F8]; int
mov esi, 1
mov rdx, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail6parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE5parseEbRSF_; nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::parse(bool,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>&)
lea r14, [rsp+118h+var_D0]
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEED2Ev; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::~lexer()
mov rax, [r14-18h]
test rax, rax
jz short loc_8C8AF
lea rdi, [rsp+118h+var_F8]
mov rsi, rdi
mov edx, 3
call rax
loc_8C8AF:
mov rax, [rsp+118h+var_108]
test rax, rax
jz short loc_8C8C6
mov rdi, rsp
mov rsi, rdi
mov edx, 3
call rax
loc_8C8C6:
mov rax, rbx
add rsp, 0E8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_8C90A
jmp short loc_8C90A
mov r14, rax
lea rdi, [rsp+118h+var_F8]
call _ZN8nlohmann16json_abi_v3_11_36detail6parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEED2Ev; nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::~parser()
jmp short loc_8C8F1
mov r14, rax
loc_8C8F1:
mov rax, [rsp+118h+var_108]
test rax, rax
jz short loc_8C915
mov rdi, rsp
mov rsi, rdi
mov edx, 3
call rax
jmp short loc_8C915
loc_8C90A:
mov rdi, rax
call __clang_call_terminate
mov r14, rax
loc_8C915:
mov rdi, rbx
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rdi, r14
call __Unwind_Resume
|
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::parse<std::string&>(
long long a1,
long long *a2,
long long a3,
unsigned __int8 a4,
unsigned __int8 a5)
{
long long v8; // r15
long long v9; // r12
__int128 v11; // [rsp+0h] [rbp-118h] BYREF
void ( *v12)(__int128 *, __int128 *, long long); // [rsp+10h] [rbp-108h]
int v13[4]; // [rsp+20h] [rbp-F8h] BYREF
void ( *v14)(int *, int *, long long); // [rsp+30h] [rbp-E8h]
_QWORD v15[26]; // [rsp+48h] [rbp-D0h] BYREF
*(_BYTE *)a1 = 0;
*(_QWORD *)(a1 + 8) = 0LL;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1);
v8 = *a2;
v9 = a2[1];
std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> &)>::function(
&v11,
a3);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>(
(long long)v13,
v8,
v8 + v9,
&v11,
a4,
a5);
nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::parse(
(long long)v13,
1,
(_BYTE *)a1);
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::~lexer(v15);
if ( v14 )
v14(v13, v13, 3LL);
if ( v12 )
v12(&v11, &v11, 3LL);
return a1;
}
|
parse<std::__cxx11::string&>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xe8
MOV EBP,R8D
MOV R14D,ECX
MOV R13,RDX
MOV R12,RSI
MOV RBX,RDI
MOV byte ptr [RDI],0x0
MOV qword ptr [RDI + 0x8],0x0
MOV ESI,0x1
CALL 0x00158f20
MOV RDI,RBX
MOV ESI,0x1
CALL 0x00158f20
MOV R15,qword ptr [R12]
MOV R12,qword ptr [R12 + 0x8]
LAB_0018c84f:
MOV RDI,RSP
MOV RSI,R13
CALL 0x001588c2
ADD R12,R15
LAB_0018c85d:
MOVZX R8D,R14B
MOVZX R9D,BPL
LEA RDI,[RSP + 0x20]
MOV RCX,RSP
MOV RSI,R15
MOV RDX,R12
CALL 0x00158816
LAB_0018c878:
LEA RDI,[RSP + 0x20]
MOV ESI,0x1
MOV RDX,RBX
CALL 0x00158920
LEA R14,[RSP + 0x48]
MOV RDI,R14
CALL 0x00159452
MOV RAX,qword ptr [R14 + -0x18]
TEST RAX,RAX
JZ 0x0018c8af
LAB_0018c8a0:
LEA RDI,[RSP + 0x20]
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_0018c8af:
MOV RAX,qword ptr [RSP + 0x10]
TEST RAX,RAX
JZ 0x0018c8c6
LAB_0018c8b9:
MOV RDI,RSP
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_0018c8c6:
MOV RAX,RBX
ADD RSP,0xe8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>::parse<std::__cxx11::string&>(std::__cxx11::string&, std::function<bool (int,
nlohmann::json_abi_v3_11_3::detail::parse_event_t,
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__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>&)>, bool, bool) */
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>
* __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::parse<std::__cxx11::string&>
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,long *param_1,function *param_3,int1 param_4,int1 param_5)
{
long lVar1;
long lVar2;
function<bool(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__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>&)>
afStack_118 [16];
code *local_108;
parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
local_f8 [16];
code *local_e8;
lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
local_d0 [160];
*this = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x0;
*(int8 *)(this + 8) = 0;
assert_invariant(SUB81(this,0));
assert_invariant(SUB81(this,0));
lVar1 = *param_1;
lVar2 = param_1[1];
/* try { // try from 0018c84f to 0018c859 has its CatchHandler @ 0018c912 */
std::
function<bool(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__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>&)>
::function(afStack_118,param_3);
/* try { // try from 0018c85d to 0018c877 has its CatchHandler @ 0018c8ee */
parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
(local_f8,lVar1,lVar2 + lVar1,afStack_118,param_4,param_5);
/* try { // try from 0018c878 to 0018c889 has its CatchHandler @ 0018c8df */
detail::
parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
::parse(local_f8,true,(basic_json *)this);
detail::
lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
::~lexer(local_d0);
if (local_e8 != (code *)0x0) {
/* try { // try from 0018c8a0 to 0018c8ae has its CatchHandler @ 0018c8dd */
(*local_e8)(local_f8,local_f8,3);
}
if (local_108 != (code *)0x0) {
/* try { // try from 0018c8b9 to 0018c8c5 has its CatchHandler @ 0018c8db */
(*local_108)(afStack_118,afStack_118,3);
}
return this;
}
|
|
7,836 |
inline_mysql_file_pread
|
eloqsql/include/mysql/psi/mysql_file.h
|
static inline size_t
inline_mysql_file_pread(
#ifdef HAVE_PSI_FILE_INTERFACE
const char *src_file, uint src_line,
#endif
File file, uchar *buffer, size_t count, my_off_t offset, myf flags)
{
size_t result;
#ifdef HAVE_PSI_FILE_INTERFACE
struct PSI_file_locker *locker;
PSI_file_locker_state state;
size_t bytes_read;
locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_READ);
if (psi_likely(locker != NULL))
{
PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line);
result= my_pread(file, buffer, count, offset, flags);
if (flags & (MY_NABP | MY_FNABP))
bytes_read= (result == 0) ? count : 0;
else
bytes_read= (result != MY_FILE_ERROR) ? result : 0;
PSI_FILE_CALL(end_file_wait)(locker, bytes_read);
return result;
}
#endif
result= my_pread(file, buffer, count, offset, flags);
return result;
}
|
O0
|
c
|
inline_mysql_file_pread:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq 0x10(%rbp), %rax
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
leaq 0x29ea34(%rip), %rax # 0x2ceb20
movq (%rax), %rax
movq 0x158(%rax), %rax
movl -0x18(%rbp), %esi
leaq -0x88(%rbp), %rdi
movl $0x6, %edx
callq *%rax
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x40(%rbp)
setne %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x301ff
leaq 0x29e9ea(%rip), %rax # 0x2ceb20
movq (%rax), %rax
movq 0x210(%rax), %rax
movq -0x40(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x10(%rbp), %rdx
movl -0x14(%rbp), %ecx
callq *%rax
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
movq -0x30(%rbp), %rcx
movq 0x10(%rbp), %r8
callq 0xfd640
movq %rax, -0x38(%rbp)
movq 0x10(%rbp), %rax
andq $0x6, %rax
cmpq $0x0, %rax
je 0x301aa
cmpq $0x0, -0x38(%rbp)
jne 0x3018f
movq -0x28(%rbp), %rax
movq %rax, -0x98(%rbp)
jmp 0x3019a
xorl %eax, %eax
movq %rax, -0x98(%rbp)
jmp 0x3019a
movq -0x98(%rbp), %rax
movq %rax, -0x90(%rbp)
jmp 0x301d7
cmpq $-0x1, -0x38(%rbp)
je 0x301be
movq -0x38(%rbp), %rax
movq %rax, -0xa0(%rbp)
jmp 0x301c9
xorl %eax, %eax
movq %rax, -0xa0(%rbp)
jmp 0x301c9
movq -0xa0(%rbp), %rax
movq %rax, -0x90(%rbp)
leaq 0x29e942(%rip), %rax # 0x2ceb20
movq (%rax), %rax
movq 0x218(%rax), %rax
movq -0x40(%rbp), %rdi
movq -0x90(%rbp), %rsi
callq *%rax
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x30223
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
movq -0x30(%rbp), %rcx
movq 0x10(%rbp), %r8
callq 0xfd640
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0xa0, %rsp
popq %rbp
retq
|
inline_mysql_file_pread:
push rbp
mov rbp, rsp
sub rsp, 0A0h
mov rax, [rbp+arg_0]
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov [rbp+var_30], r9
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+158h]
mov esi, [rbp+var_18]
lea rdi, [rbp+var_88]
mov edx, 6
call rax
mov [rbp+var_40], rax
cmp [rbp+var_40], 0
setnz al
and al, 1
movzx eax, al
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz loc_301FF
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+210h]
mov rdi, [rbp+var_40]
mov rsi, [rbp+var_28]
mov rdx, [rbp+var_10]
mov ecx, [rbp+var_14]
call rax
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_28]
mov rcx, [rbp+var_30]
mov r8, [rbp+arg_0]
call my_pread
mov [rbp+var_38], rax
mov rax, [rbp+arg_0]
and rax, 6
cmp rax, 0
jz short loc_301AA
cmp [rbp+var_38], 0
jnz short loc_3018F
mov rax, [rbp+var_28]
mov [rbp+var_98], rax
jmp short loc_3019A
loc_3018F:
xor eax, eax
mov [rbp+var_98], rax
jmp short $+2
loc_3019A:
mov rax, [rbp+var_98]
mov [rbp+var_90], rax
jmp short loc_301D7
loc_301AA:
cmp [rbp+var_38], 0FFFFFFFFFFFFFFFFh
jz short loc_301BE
mov rax, [rbp+var_38]
mov [rbp+var_A0], rax
jmp short loc_301C9
loc_301BE:
xor eax, eax
mov [rbp+var_A0], rax
jmp short $+2
loc_301C9:
mov rax, [rbp+var_A0]
mov [rbp+var_90], rax
loc_301D7:
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+218h]
mov rdi, [rbp+var_40]
mov rsi, [rbp+var_90]
call rax
mov rax, [rbp+var_38]
mov [rbp+var_8], rax
jmp short loc_30223
loc_301FF:
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_28]
mov rcx, [rbp+var_30]
mov r8, [rbp+arg_0]
call my_pread
mov [rbp+var_38], rax
mov rax, [rbp+var_38]
mov [rbp+var_8], rax
loc_30223:
mov rax, [rbp+var_8]
add rsp, 0A0h
pop rbp
retn
|
long long inline_mysql_file_pread(
long long a1,
unsigned int a2,
unsigned int a3,
long long a4,
long long a5,
long long a6,
long long a7)
{
long long v8; // [rsp+0h] [rbp-A0h]
long long v9; // [rsp+8h] [rbp-98h]
_BYTE v10[72]; // [rsp+18h] [rbp-88h] BYREF
long long v11; // [rsp+60h] [rbp-40h]
long long v12; // [rsp+68h] [rbp-38h]
long long v13; // [rsp+70h] [rbp-30h]
long long v14; // [rsp+78h] [rbp-28h]
long long v15; // [rsp+80h] [rbp-20h]
unsigned int v16; // [rsp+88h] [rbp-18h]
unsigned int v17; // [rsp+8Ch] [rbp-14h]
long long v18; // [rsp+90h] [rbp-10h]
v18 = a1;
v17 = a2;
v16 = a3;
v15 = a4;
v14 = a5;
v13 = a6;
v11 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v10, a3, 6LL);
if ( v11 )
{
((void ( *)(long long, long long, long long, _QWORD))PSI_server[66])(v11, v14, v18, v17);
v12 = my_pread(v16, v15, v14, v13, a7);
if ( (a7 & 6) != 0 )
{
if ( v12 )
v9 = 0LL;
else
v9 = v14;
((void ( *)(long long, long long))PSI_server[67])(v11, v9);
}
else
{
if ( v12 == -1 )
v8 = 0LL;
else
v8 = v12;
((void ( *)(long long, long long))PSI_server[67])(v11, v8);
}
return v12;
}
else
{
return my_pread(v16, v15, v14, v13, a7);
}
}
|
inline_mysql_file_pread:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xa0
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV dword ptr [RBP + -0x18],EDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV qword ptr [RBP + -0x30],R9
LEA RAX,[0x3ceb20]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x158]
MOV ESI,dword ptr [RBP + -0x18]
LEA RDI,[RBP + -0x88]
MOV EDX,0x6
CALL RAX
MOV qword ptr [RBP + -0x40],RAX
CMP qword ptr [RBP + -0x40],0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x001301ff
LEA RAX,[0x3ceb20]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x210]
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x14]
CALL RAX
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RBP + -0x30]
MOV R8,qword ptr [RBP + 0x10]
CALL 0x001fd640
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + 0x10]
AND RAX,0x6
CMP RAX,0x0
JZ 0x001301aa
CMP qword ptr [RBP + -0x38],0x0
JNZ 0x0013018f
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x98],RAX
JMP 0x0013019a
LAB_0013018f:
XOR EAX,EAX
MOV qword ptr [RBP + -0x98],RAX
JMP 0x0013019a
LAB_0013019a:
MOV RAX,qword ptr [RBP + -0x98]
MOV qword ptr [RBP + -0x90],RAX
JMP 0x001301d7
LAB_001301aa:
CMP qword ptr [RBP + -0x38],-0x1
JZ 0x001301be
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0xa0],RAX
JMP 0x001301c9
LAB_001301be:
XOR EAX,EAX
MOV qword ptr [RBP + -0xa0],RAX
JMP 0x001301c9
LAB_001301c9:
MOV RAX,qword ptr [RBP + -0xa0]
MOV qword ptr [RBP + -0x90],RAX
LAB_001301d7:
LEA RAX,[0x3ceb20]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x218]
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x90]
CALL RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x00130223
LAB_001301ff:
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RBP + -0x30]
MOV R8,qword ptr [RBP + 0x10]
CALL 0x001fd640
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x8],RAX
LAB_00130223:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0xa0
POP RBP
RET
|
long inline_mysql_file_pread
(int8 param_1,int4 param_2,int4 param_3,int8 param_4,
long param_5,int8 param_6,ulong param_7)
{
long local_a8;
long local_a0;
long local_98;
int1 local_90 [72];
long local_48;
long local_40;
int8 local_38;
long local_30;
int8 local_28;
int4 local_20;
int4 local_1c;
int8 local_18;
long local_10;
local_38 = param_6;
local_30 = param_5;
local_28 = param_4;
local_20 = param_3;
local_1c = param_2;
local_18 = param_1;
local_48 = (**(code **)(PSI_server + 0x158))(local_90,param_3,6);
if (local_48 == 0) {
local_10 = my_pread(local_20,local_28,local_30,local_38,param_7);
}
else {
(**(code **)(PSI_server + 0x210))(local_48,local_30,local_18,local_1c);
local_40 = my_pread(local_20,local_28,local_30,local_38,param_7);
if ((param_7 & 6) == 0) {
local_a8 = local_40;
if (local_40 == -1) {
local_a8 = 0;
}
local_98 = local_a8;
}
else {
if (local_40 == 0) {
local_a0 = local_30;
}
else {
local_a0 = 0;
}
local_98 = local_a0;
}
(**(code **)(PSI_server + 0x218))(local_48,local_98);
local_10 = local_40;
}
return local_10;
}
|
|
7,837 |
maria_ftparser_call_deinitializer
|
eloqsql/storage/maria/ma_ft_parser.c
|
void maria_ftparser_call_deinitializer(MARIA_HA *info)
{
uint i, j, keys= info->s->state.header.keys;
free_root(&info->ft_memroot, MYF(0));
if (! info->ftparser_param)
return;
for (i= 0; i < keys; i++)
{
MARIA_KEYDEF *keyinfo= &info->s->keyinfo[i];
for (j=0; j < MAX_PARAM_NR; j++)
{
MYSQL_FTPARSER_PARAM *ftparser_param=
&info->ftparser_param[keyinfo->ftkey_nr*MAX_PARAM_NR + j];
if (keyinfo->flag & HA_FULLTEXT && ftparser_param->mysql_add_word)
{
if (keyinfo->parser->deinit)
keyinfo->parser->deinit(ftparser_param);
ftparser_param->mysql_add_word= 0;
}
else
break;
}
}
}
|
O3
|
c
|
maria_ftparser_call_deinitializer:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
movb 0x12(%rax), %r14b
addq $0x328, %rdi # imm = 0x328
xorl %esi, %esi
callq 0x9ddef
cmpq $0x0, 0x368(%rbx)
setne %al
testb %r14b, %r14b
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x477fa
movzbl %r14b, %eax
movq %rax, -0x30(%rbp)
xorl %r12d, %r12d
movq (%rbx), %rax
imulq $0x118, %r12, %r13 # imm = 0x118
addq 0x570(%rax), %r13
movb $0x1, %r15b
xorl %eax, %eax
testb $-0x80, 0xa2(%r13)
je 0x477f1
movl 0xbc(%r13), %ecx
leal (%rax,%rcx,2), %r14d
shlq $0x6, %r14
addq 0x368(%rbx), %r14
cmpq $0x0, 0x8(%r14)
je 0x477f1
movq 0xd0(%r13), %rax
movq 0x18(%rax), %rax
testq %rax, %rax
je 0x477d8
movq %r14, %rdi
callq *%rax
movq $0x0, 0x8(%r14)
movl $0x1, %eax
testb $0x1, %r15b
movl $0x0, %r15d
jne 0x4779c
incq %r12
cmpq -0x30(%rbp), %r12
jne 0x47786
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopl (%rax)
|
maria_ftparser_call_deinitializer:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rdi
mov rax, [rdi]
mov r14b, [rax+12h]
add rdi, 328h
xor esi, esi
call free_root
cmp qword ptr [rbx+368h], 0
setnz al
test r14b, r14b
setnz cl
and cl, al
cmp cl, 1
jnz short loc_477FA
movzx eax, r14b
mov [rbp+var_30], rax
xor r12d, r12d
loc_47786:
mov rax, [rbx]
imul r13, r12, 118h
add r13, [rax+570h]
mov r15b, 1
xor eax, eax
loc_4779C:
test byte ptr [r13+0A2h], 80h
jz short loc_477F1
mov ecx, [r13+0BCh]
lea r14d, [rax+rcx*2]
shl r14, 6
add r14, [rbx+368h]
cmp qword ptr [r14+8], 0
jz short loc_477F1
mov rax, [r13+0D0h]
mov rax, [rax+18h]
test rax, rax
jz short loc_477D8
mov rdi, r14
call rax
loc_477D8:
mov qword ptr [r14+8], 0
mov eax, 1
test r15b, 1
mov r15d, 0
jnz short loc_4779C
loc_477F1:
inc r12
cmp r12, [rbp+var_30]
jnz short loc_47786
loc_477FA:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
char maria_ftparser_call_deinitializer(_QWORD *a1)
{
unsigned __int8 v1; // r14
int v2; // eax
long long v3; // r12
long long v4; // r13
char v5; // r15
unsigned long long v6; // r14
void ( *v7)(unsigned long long); // rax
bool v8; // zf
long long v10; // [rsp+0h] [rbp-30h]
v1 = *(_BYTE *)(*a1 + 18LL);
free_root(a1 + 101, 0LL);
LOBYTE(v2) = a1[109] != 0LL;
if ( ((unsigned __int8)v2 & (v1 != 0)) == 1 )
{
v10 = v1;
v3 = 0LL;
do
{
v4 = *(_QWORD *)(*a1 + 1392LL) + 280 * v3;
v5 = 1;
v2 = 0;
do
{
if ( *(char *)(v4 + 162) >= 0 )
break;
v6 = a1[109] + ((unsigned long long)(unsigned int)(v2 + 2 * *(_DWORD *)(v4 + 188)) << 6);
if ( !*(_QWORD *)(v6 + 8) )
break;
v7 = *(void ( **)(unsigned long long))(*(_QWORD *)(v4 + 208) + 24LL);
if ( v7 )
v7(v6);
*(_QWORD *)(v6 + 8) = 0LL;
v2 = 1;
v8 = (v5 & 1) == 0;
v5 = 0;
}
while ( !v8 );
++v3;
}
while ( v3 != v10 );
}
return v2;
}
|
maria_ftparser_call_deinitializer:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV RAX,qword ptr [RDI]
MOV R14B,byte ptr [RAX + 0x12]
ADD RDI,0x328
XOR ESI,ESI
CALL 0x0019ddef
CMP qword ptr [RBX + 0x368],0x0
SETNZ AL
TEST R14B,R14B
SETNZ CL
AND CL,AL
CMP CL,0x1
JNZ 0x001477fa
MOVZX EAX,R14B
MOV qword ptr [RBP + -0x30],RAX
XOR R12D,R12D
LAB_00147786:
MOV RAX,qword ptr [RBX]
IMUL R13,R12,0x118
ADD R13,qword ptr [RAX + 0x570]
MOV R15B,0x1
XOR EAX,EAX
LAB_0014779c:
TEST byte ptr [R13 + 0xa2],0x80
JZ 0x001477f1
MOV ECX,dword ptr [R13 + 0xbc]
LEA R14D,[RAX + RCX*0x2]
SHL R14,0x6
ADD R14,qword ptr [RBX + 0x368]
CMP qword ptr [R14 + 0x8],0x0
JZ 0x001477f1
MOV RAX,qword ptr [R13 + 0xd0]
MOV RAX,qword ptr [RAX + 0x18]
TEST RAX,RAX
JZ 0x001477d8
MOV RDI,R14
CALL RAX
LAB_001477d8:
MOV qword ptr [R14 + 0x8],0x0
MOV EAX,0x1
TEST R15B,0x1
MOV R15D,0x0
JNZ 0x0014779c
LAB_001477f1:
INC R12
CMP R12,qword ptr [RBP + -0x30]
JNZ 0x00147786
LAB_001477fa:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void maria_ftparser_call_deinitializer(long *param_1)
{
byte bVar1;
code *pcVar2;
bool bVar3;
int iVar4;
ulong uVar5;
long lVar6;
long lVar7;
bool bVar8;
bVar1 = *(byte *)(*param_1 + 0x12);
free_root(param_1 + 0x65,0);
if (bVar1 != 0 && param_1[0x6d] != 0) {
uVar5 = 0;
do {
lVar6 = uVar5 * 0x118 + *(long *)(*param_1 + 0x570);
iVar4 = 0;
bVar3 = true;
do {
bVar8 = bVar3;
if ((*(byte *)(lVar6 + 0xa2) & 0x80) == 0) break;
lVar7 = (ulong)(uint)(iVar4 + *(int *)(lVar6 + 0xbc) * 2) * 0x40 + param_1[0x6d];
if (*(long *)(lVar7 + 8) == 0) break;
pcVar2 = *(code **)(*(long *)(lVar6 + 0xd0) + 0x18);
if (pcVar2 != (code *)0x0) {
(*pcVar2)(lVar7);
}
*(int8 *)(lVar7 + 8) = 0;
iVar4 = 1;
bVar3 = false;
} while (bVar8);
uVar5 = uVar5 + 1;
} while (uVar5 != bVar1);
}
return;
}
|
|
7,838 |
my_getwd
|
eloqsql/mysys/my_getwd.c
|
int my_getwd(char * buf, size_t size, myf MyFlags)
{
char * pos;
DBUG_ENTER("my_getwd");
DBUG_PRINT("my",("buf:%p size: %u MyFlags %lu",
buf, (uint) size, MyFlags));
if (size < 1)
DBUG_RETURN(-1);
if (curr_dir[0]) /* Current pos is saved here */
(void) strmake(buf,&curr_dir[0],size-1);
else
{
#if defined(HAVE_GETCWD)
if (size < 2)
DBUG_RETURN(-1);
if (!getcwd(buf,(uint) (size-2)) && MyFlags & MY_WME)
{
my_errno=errno;
my_error(EE_GETWD,MYF(ME_BELL),errno);
DBUG_RETURN(-1);
}
#elif defined(HAVE_GETWD)
{
char pathname[MAXPATHLEN];
getwd(pathname);
strmake(buf,pathname,size-1);
}
#else
#error "No way to get current directory"
#endif
if (*((pos=strend(buf))-1) != FN_LIBCHAR) /* End with FN_LIBCHAR */
{
pos[0]= FN_LIBCHAR;
pos[1]=0;
}
(void) strmake(&curr_dir[0],buf, (size_t) (FN_REFLEN-1));
}
DBUG_RETURN(0);
}
|
O0
|
c
|
my_getwd:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
jmp 0xf0166
cmpq $0x1, -0x18(%rbp)
jae 0xf017b
jmp 0xf016f
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xf025a
leaq 0xb924ee(%rip), %rax # 0xc82670
cmpb $0x0, (%rax)
je 0xf01a4
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
leaq 0xb924d6(%rip), %rsi # 0xc82670
callq 0x14dd80
jmp 0xf0251
cmpq $0x2, -0x18(%rbp)
jae 0xf01b9
jmp 0xf01ad
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xf025a
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
subq $0x2, %rax
movl %eax, %eax
movl %eax, %esi
callq 0x2a310
cmpq $0x0, %rax
jne 0xf0217
movq -0x20(%rbp), %rax
andq $0x10, %rax
cmpq $0x0, %rax
je 0xf0217
callq 0x2a740
movl (%rax), %eax
movl %eax, -0x2c(%rbp)
callq 0xf6080
movl -0x2c(%rbp), %ecx
movl %ecx, (%rax)
callq 0x2a740
movl (%rax), %edx
movl $0x10, %edi
movl $0x4, %esi
movb $0x0, %al
callq 0xef8b0
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xf025a
movq -0x10(%rbp), %rdi
callq 0x14dd00
movq %rax, -0x28(%rbp)
movsbl -0x1(%rax), %eax
cmpl $0x2f, %eax
je 0xf023c
movq -0x28(%rbp), %rax
movb $0x2f, (%rax)
movq -0x28(%rbp), %rax
movb $0x0, 0x1(%rax)
movq -0x10(%rbp), %rsi
leaq 0xb92429(%rip), %rdi # 0xc82670
movl $0x1ff, %edx # imm = 0x1FF
callq 0x14dd80
jmp 0xf0253
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
my_getwd:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
jmp short $+2
loc_F0166:
cmp [rbp+var_18], 1
jnb short loc_F017B
jmp short $+2
loc_F016F:
mov [rbp+var_4], 0FFFFFFFFh
jmp loc_F025A
loc_F017B:
lea rax, curr_dir
cmp byte ptr [rax], 0
jz short loc_F01A4
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_18]
sub rdx, 1
lea rsi, curr_dir
call strmake
jmp loc_F0251
loc_F01A4:
cmp [rbp+var_18], 2
jnb short loc_F01B9
jmp short $+2
loc_F01AD:
mov [rbp+var_4], 0FFFFFFFFh
jmp loc_F025A
loc_F01B9:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_18]
sub rax, 2
mov eax, eax
mov esi, eax
call _getcwd
cmp rax, 0
jnz short loc_F0217
mov rax, [rbp+var_20]
and rax, 10h
cmp rax, 0
jz short loc_F0217
call ___errno_location
mov eax, [rax]
mov [rbp+var_2C], eax
call _my_thread_var
mov ecx, [rbp+var_2C]
mov [rax], ecx
call ___errno_location
mov edx, [rax]
mov edi, 10h
mov esi, 4
mov al, 0
call my_error
mov [rbp+var_4], 0FFFFFFFFh
jmp short loc_F025A
loc_F0217:
mov rdi, [rbp+var_10]
call strend
mov [rbp+var_28], rax
movsx eax, byte ptr [rax-1]
cmp eax, 2Fh ; '/'
jz short loc_F023C
mov rax, [rbp+var_28]
mov byte ptr [rax], 2Fh ; '/'
mov rax, [rbp+var_28]
mov byte ptr [rax+1], 0
loc_F023C:
mov rsi, [rbp+var_10]
lea rdi, curr_dir
mov edx, 1FFh
call strmake
loc_F0251:
jmp short $+2
loc_F0253:
mov [rbp+var_4], 0
loc_F025A:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
|
long long my_getwd(long long a1, unsigned long long a2, char a3)
{
const char *v3; // rsi
unsigned int *v4; // rax
int v6; // [rsp+4h] [rbp-2Ch]
_BYTE *v7; // [rsp+8h] [rbp-28h]
if ( a2 )
{
if ( curr_dir[0] )
{
strmake(a1, curr_dir, a2 - 1);
}
else
{
if ( a2 < 2 )
return (unsigned int)-1;
v3 = (const char *)(unsigned int)(a2 - 2);
if ( !getcwd(a1, v3) && (a3 & 0x10) != 0 )
{
v6 = *(_DWORD *)__errno_location();
*(_DWORD *)my_thread_var(a1, v3) = v6;
v4 = (unsigned int *)__errno_location();
my_error(0x10u, 4LL, *v4);
return (unsigned int)-1;
}
v7 = (_BYTE *)strend(a1);
if ( *(v7 - 1) != 47 )
{
*v7 = 47;
v7[1] = 0;
}
strmake(curr_dir, a1, 511LL);
}
return 0;
}
return (unsigned int)-1;
}
|
my_getwd:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
JMP 0x001f0166
LAB_001f0166:
CMP qword ptr [RBP + -0x18],0x1
JNC 0x001f017b
JMP 0x001f016f
LAB_001f016f:
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x001f025a
LAB_001f017b:
LEA RAX,[0xd82670]
CMP byte ptr [RAX],0x0
JZ 0x001f01a4
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
LEA RSI,[0xd82670]
CALL 0x0024dd80
JMP 0x001f0251
LAB_001f01a4:
CMP qword ptr [RBP + -0x18],0x2
JNC 0x001f01b9
JMP 0x001f01ad
LAB_001f01ad:
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x001f025a
LAB_001f01b9:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x18]
SUB RAX,0x2
MOV EAX,EAX
MOV ESI,EAX
CALL 0x0012a310
CMP RAX,0x0
JNZ 0x001f0217
MOV RAX,qword ptr [RBP + -0x20]
AND RAX,0x10
CMP RAX,0x0
JZ 0x001f0217
CALL 0x0012a740
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x2c],EAX
CALL 0x001f6080
MOV ECX,dword ptr [RBP + -0x2c]
MOV dword ptr [RAX],ECX
CALL 0x0012a740
MOV EDX,dword ptr [RAX]
MOV EDI,0x10
MOV ESI,0x4
MOV AL,0x0
CALL 0x001ef8b0
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x001f025a
LAB_001f0217:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0024dd00
MOV qword ptr [RBP + -0x28],RAX
MOVSX EAX,byte ptr [RAX + -0x1]
CMP EAX,0x2f
JZ 0x001f023c
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX],0x2f
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x1],0x0
LAB_001f023c:
MOV RSI,qword ptr [RBP + -0x10]
LEA RDI,[0xd82670]
MOV EDX,0x1ff
CALL 0x0024dd80
LAB_001f0251:
JMP 0x001f0253
LAB_001f0253:
MOV dword ptr [RBP + -0x4],0x0
LAB_001f025a:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
int4 my_getwd(char *param_1,ulong param_2,ulong param_3)
{
int iVar1;
char *pcVar2;
int *piVar3;
int1 *puVar4;
if (param_2 == 0) {
return 0xffffffff;
}
if (curr_dir == '\0') {
if (param_2 < 2) {
return 0xffffffff;
}
pcVar2 = getcwd(param_1,(ulong)((int)param_2 - 2));
if ((pcVar2 == (char *)0x0) && ((param_3 & 0x10) != 0)) {
piVar3 = __errno_location();
iVar1 = *piVar3;
piVar3 = (int *)_my_thread_var();
*piVar3 = iVar1;
piVar3 = __errno_location();
my_error(0x10,4,*piVar3);
return 0xffffffff;
}
puVar4 = (int1 *)strend(param_1);
if (puVar4[-1] != '/') {
*puVar4 = 0x2f;
puVar4[1] = 0;
}
strmake(&curr_dir,param_1,0x1ff);
}
else {
strmake(param_1,&curr_dir,param_2 - 1);
}
return 0;
}
|
|
7,839 |
purge_sys_t::purge_sys_t()
|
eloqsql/storage/innobase/include/trx0purge.h
|
purge_sys_t(): m_enabled(false), heap(nullptr) {}
|
O3
|
c
|
purge_sys_t::purge_sys_t():
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
xorl %eax, %eax
movq %rax, 0x10(%rdi)
leaq 0x20(%rdi), %r14
movl $0x0, 0x20(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%rdi)
movq %rax, 0x38(%rdi)
movb $0x0, 0x48(%rdi)
movq 0x123ff9f(%rip), %rax # 0x1e17300
movq %rax, 0xa0(%rdi)
addq $0xa8, %rdi
leaq 0x123ff92(%rip), %rsi # 0x1e17308
callq 0xbd75b4
movq 0xb0(%rbx), %rax
movq %rax, 0xc8(%rbx)
xorps %xmm0, %xmm0
movaps %xmm0, 0xd0(%rbx)
movaps %xmm0, 0xe0(%rbx)
movaps %xmm0, 0xf0(%rbx)
movaps %xmm0, 0x100(%rbx)
xorl %eax, %eax
movq %rax, 0x110(%rbx)
movq %rax, 0x170(%rbx)
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
movq %r14, %rdi
callq 0xbd751c
movq %rbx, %rdi
callq 0x61c170
|
_ZN11purge_sys_tC2Ev:
push rbp
mov rbp, rsp
push r14
push rbx
mov rbx, rdi
xor eax, eax
mov [rdi+10h], rax
lea r14, [rdi+20h]
mov dword ptr [rdi+20h], 0
xorps xmm0, xmm0
movups xmmword ptr [rdi+28h], xmm0
mov [rdi+38h], rax
mov byte ptr [rdi+48h], 0
mov rax, qword ptr cs:_ZL11NullElement; NullElement
mov [rdi+0A0h], rax
add rdi, 0A8h
lea rsi, _ZL11NullElement+8; NullElement
call _ZNSt6vectorIP10trx_rseg_t12ut_allocatorIS1_Lb1EEEC2ERKS4_; std::vector<trx_rseg_t *,ut_allocator<trx_rseg_t *,true>>::vector(std::vector<trx_rseg_t *,ut_allocator<trx_rseg_t *,true>> const&)
mov rax, [rbx+0B0h]
mov [rbx+0C8h], rax
xorps xmm0, xmm0
movaps xmmword ptr [rbx+0D0h], xmm0
movaps xmmword ptr [rbx+0E0h], xmm0
movaps xmmword ptr [rbx+0F0h], xmm0
movaps xmmword ptr [rbx+100h], xmm0
xor eax, eax
mov [rbx+110h], rax
mov [rbx+170h], rax
pop rbx
pop r14
pop rbp
retn
mov rbx, rax
mov rdi, r14
call _ZNSt12_Vector_baseIm12ut_allocatorImLb1EEED2Ev; std::_Vector_base<ulong,ut_allocator<ulong,true>>::~_Vector_base()
mov rdi, rbx
call __Unwind_Resume
|
void purge_sys_t::purge_sys_t(purge_sys_t *this)
{
*((_QWORD *)this + 2) = 0LL;
*((_DWORD *)this + 8) = 0;
*(_OWORD *)((char *)this + 40) = 0LL;
*((_QWORD *)this + 7) = 0LL;
*((_BYTE *)this + 72) = 0;
*((_QWORD *)this + 20) = NullElement;
std::vector<trx_rseg_t *,ut_allocator<trx_rseg_t *,true>>::vector((char *)this + 168, (char *)&NullElement + 8);
*((_QWORD *)this + 25) = *((_QWORD *)this + 22);
*((_OWORD *)this + 13) = 0LL;
*((_OWORD *)this + 14) = 0LL;
*((_OWORD *)this + 15) = 0LL;
*((_OWORD *)this + 16) = 0LL;
*((_QWORD *)this + 34) = 0LL;
*((_QWORD *)this + 46) = 0LL;
}
|
visit_thread:
PUSH RBP
MOV RBP,RSP
MOVDQU XMM0,xmmword ptr [RDI + 0x8]
PCMPEQD XMM1,XMM1
PSUBQ XMM0,XMM1
MOVDQU xmmword ptr [RDI + 0x8],XMM0
POP RBP
RET
|
/* PFS_connection_stat_visitor::visit_thread(PFS_thread*) */
void PFS_connection_stat_visitor::visit_thread(PFS_thread *param_1)
{
*(long *)(param_1 + 8) = *(long *)(param_1 + 8) + 1;
*(long *)(param_1 + 0x10) = *(long *)(param_1 + 0x10) + 1;
return;
}
|
|
7,840 |
async_func_init
|
bluesky950520[P]quickjs/quickjs.c
|
static __exception int async_func_init(JSContext *ctx, JSAsyncFunctionState *s,
JSValue func_obj, JSValue this_obj,
int argc, JSValue *argv)
{
JSObject *p;
JSFunctionBytecode *b;
JSStackFrame *sf;
int local_count, i, arg_buf_len, n;
sf = &s->frame;
init_list_head(&sf->var_ref_list);
p = JS_VALUE_GET_OBJ(func_obj);
b = p->u.func.function_bytecode;
sf->is_strict_mode = b->is_strict_mode;
sf->cur_pc = b->byte_code_buf;
arg_buf_len = max_int(b->arg_count, argc);
local_count = arg_buf_len + b->var_count + b->stack_size;
sf->arg_buf = js_malloc(ctx, sizeof(JSValue) * max_int(local_count, 1));
if (!sf->arg_buf)
return -1;
sf->cur_func = js_dup(func_obj);
s->this_val = js_dup(this_obj);
s->argc = argc;
sf->arg_count = arg_buf_len;
sf->var_buf = sf->arg_buf + arg_buf_len;
sf->cur_sp = sf->var_buf + b->var_count;
for(i = 0; i < argc; i++)
sf->arg_buf[i] = js_dup(argv[i]);
n = arg_buf_len + b->var_count;
for(i = argc; i < n; i++)
sf->arg_buf[i] = JS_UNDEFINED;
return 0;
}
|
O0
|
c
|
async_func_init:
subq $0xc8, %rsp
movq 0xd8(%rsp), %rax
movl 0xd0(%rsp), %eax
movq %rdx, 0xb0(%rsp)
movq %rcx, 0xb8(%rsp)
movq %r8, 0xa0(%rsp)
movq %r9, 0xa8(%rsp)
movq %rdi, 0x98(%rsp)
movq %rsi, 0x90(%rsp)
movq 0x90(%rsp), %rax
addq $0x18, %rax
movq %rax, 0x78(%rsp)
movq 0x78(%rsp), %rdi
addq $0x28, %rdi
callq 0x28680
movq 0xb0(%rsp), %rax
movq %rax, 0x88(%rsp)
movq 0x88(%rsp), %rax
movq 0x30(%rax), %rax
movq %rax, 0x80(%rsp)
movq 0x80(%rsp), %rax
movw 0x18(%rax), %ax
andw $0x1, %ax
movzbl %al, %edx
movq 0x78(%rsp), %rax
movl 0x40(%rax), %ecx
andl $0x1, %edx
shll $0x1f, %edx
andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF
orl %edx, %ecx
movl %ecx, 0x40(%rax)
movq 0x80(%rsp), %rax
movq 0x20(%rax), %rcx
movq 0x78(%rsp), %rax
movq %rcx, 0x38(%rax)
movq 0x80(%rsp), %rax
movzwl 0x40(%rax), %edi
movl 0xd0(%rsp), %esi
callq 0x63600
movl %eax, 0x6c(%rsp)
movl 0x6c(%rsp), %eax
movq 0x80(%rsp), %rcx
movzwl 0x42(%rcx), %ecx
addl %ecx, %eax
movq 0x80(%rsp), %rcx
movzwl 0x46(%rcx), %ecx
addl %ecx, %eax
movl %eax, 0x74(%rsp)
movq 0x98(%rsp), %rax
movq %rax, 0x20(%rsp)
movl 0x74(%rsp), %edi
movl $0x1, %esi
callq 0x63600
movq 0x20(%rsp), %rdi
movslq %eax, %rsi
shlq $0x4, %rsi
callq 0x27fa0
movq %rax, %rcx
movq 0x78(%rsp), %rax
movq %rcx, 0x18(%rax)
movq 0x78(%rsp), %rax
cmpq $0x0, 0x18(%rax)
jne 0x783fe
movl $0xffffffff, 0xc4(%rsp) # imm = 0xFFFFFFFF
jmp 0x785f3
movq 0x78(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0xb0(%rsp), %rdi
movq 0xb8(%rsp), %rsi
callq 0x279c0
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq %rcx, 0x58(%rsp)
movq %rdx, 0x60(%rsp)
movq 0x58(%rsp), %rcx
movq %rcx, 0x8(%rax)
movq 0x60(%rsp), %rcx
movq %rcx, 0x10(%rax)
movq 0x90(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0xa0(%rsp), %rdi
movq 0xa8(%rsp), %rsi
callq 0x279c0
movq %rax, %rcx
movq 0x18(%rsp), %rax
movq %rcx, 0x48(%rsp)
movq %rdx, 0x50(%rsp)
movq 0x48(%rsp), %rcx
movq %rcx, (%rax)
movq 0x50(%rsp), %rcx
movq %rcx, 0x8(%rax)
movl 0xd0(%rsp), %ecx
movq 0x90(%rsp), %rax
movl %ecx, 0x10(%rax)
movl 0x6c(%rsp), %edx
movq 0x78(%rsp), %rax
movl 0x40(%rax), %ecx
andl $0x7fffffff, %edx # imm = 0x7FFFFFFF
andl $0x80000000, %ecx # imm = 0x80000000
orl %edx, %ecx
movl %ecx, 0x40(%rax)
movq 0x78(%rsp), %rax
movq 0x18(%rax), %rcx
movslq 0x6c(%rsp), %rax
shlq $0x4, %rax
addq %rax, %rcx
movq 0x78(%rsp), %rax
movq %rcx, 0x20(%rax)
movq 0x78(%rsp), %rax
movq 0x20(%rax), %rcx
movq 0x80(%rsp), %rax
movzwl 0x42(%rax), %eax
cltq
shlq $0x4, %rax
addq %rax, %rcx
movq 0x78(%rsp), %rax
movq %rcx, 0x48(%rax)
movl $0x0, 0x70(%rsp)
movl 0x70(%rsp), %eax
cmpl 0xd0(%rsp), %eax
jge 0x78579
movq 0x78(%rsp), %rax
movq 0x18(%rax), %rax
movslq 0x70(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, 0x8(%rsp)
movq 0xd8(%rsp), %rax
movslq 0x70(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rdi
movq 0x8(%rax), %rsi
callq 0x279c0
movq %rax, %rcx
movq 0x8(%rsp), %rax
movq %rcx, 0x38(%rsp)
movq %rdx, 0x40(%rsp)
movq 0x38(%rsp), %rcx
movq %rcx, (%rax)
movq 0x40(%rsp), %rcx
movq %rcx, 0x8(%rax)
movl 0x70(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x70(%rsp)
jmp 0x78502
movl 0x6c(%rsp), %eax
movq 0x80(%rsp), %rcx
movzwl 0x42(%rcx), %ecx
addl %ecx, %eax
movl %eax, 0x68(%rsp)
movl 0xd0(%rsp), %eax
movl %eax, 0x70(%rsp)
movl 0x70(%rsp), %eax
cmpl 0x68(%rsp), %eax
jge 0x785e8
movq 0x78(%rsp), %rax
movq 0x18(%rax), %rax
movslq 0x70(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movl $0x0, 0x28(%rsp)
movq $0x3, 0x30(%rsp)
movq 0x28(%rsp), %rcx
movq %rcx, (%rax)
movq 0x30(%rsp), %rcx
movq %rcx, 0x8(%rax)
movl 0x70(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x70(%rsp)
jmp 0x7859a
movl $0x0, 0xc4(%rsp)
movl 0xc4(%rsp), %eax
addq $0xc8, %rsp
retq
nopw %cs:(%rax,%rax)
|
async_func_init:
sub rsp, 0C8h
mov rax, [rsp+0C8h+arg_8]
mov eax, [rsp+0C8h+arg_0]
mov [rsp+0C8h+var_18], rdx
mov [rsp+0C8h+var_10], rcx
mov [rsp+0C8h+var_28], r8
mov [rsp+0C8h+var_20], r9
mov [rsp+0C8h+var_30], rdi
mov [rsp+0C8h+var_38], rsi
mov rax, [rsp+0C8h+var_38]
add rax, 18h
mov [rsp+0C8h+var_50], rax
mov rdi, [rsp+0C8h+var_50]
add rdi, 28h ; '('
call init_list_head_1
mov rax, [rsp+0C8h+var_18]
mov [rsp+0C8h+var_40], rax
mov rax, [rsp+0C8h+var_40]
mov rax, [rax+30h]
mov [rsp+0C8h+var_48], rax
mov rax, [rsp+0C8h+var_48]
mov ax, [rax+18h]
and ax, 1
movzx edx, al
mov rax, [rsp+0C8h+var_50]
mov ecx, [rax+40h]
and edx, 1
shl edx, 1Fh
and ecx, 7FFFFFFFh
or ecx, edx
mov [rax+40h], ecx
mov rax, [rsp+0C8h+var_48]
mov rcx, [rax+20h]
mov rax, [rsp+0C8h+var_50]
mov [rax+38h], rcx
mov rax, [rsp+0C8h+var_48]
movzx edi, word ptr [rax+40h]
mov esi, [rsp+0C8h+arg_0]
call max_int_1
mov [rsp+0C8h+var_5C], eax
mov eax, [rsp+0C8h+var_5C]
mov rcx, [rsp+0C8h+var_48]
movzx ecx, word ptr [rcx+42h]
add eax, ecx
mov rcx, [rsp+0C8h+var_48]
movzx ecx, word ptr [rcx+46h]
add eax, ecx
mov [rsp+0C8h+var_54], eax
mov rax, [rsp+0C8h+var_30]
mov [rsp+0C8h+var_A8], rax
mov edi, [rsp+0C8h+var_54]
mov esi, 1
call max_int_1
mov rdi, [rsp+0C8h+var_A8]
movsxd rsi, eax
shl rsi, 4
call js_malloc
mov rcx, rax
mov rax, [rsp+0C8h+var_50]
mov [rax+18h], rcx
mov rax, [rsp+0C8h+var_50]
cmp qword ptr [rax+18h], 0
jnz short loc_783FE
mov [rsp+0C8h+var_4], 0FFFFFFFFh
jmp loc_785F3
loc_783FE:
mov rax, [rsp+0C8h+var_50]
mov [rsp+0C8h+var_B8], rax
mov rdi, [rsp+0C8h+var_18]
mov rsi, [rsp+0C8h+var_10]
call js_dup
mov rcx, rax
mov rax, [rsp+0C8h+var_B8]
mov [rsp+0C8h+var_70], rcx
mov [rsp+0C8h+var_68], rdx
mov rcx, [rsp+0C8h+var_70]
mov [rax+8], rcx
mov rcx, [rsp+0C8h+var_68]
mov [rax+10h], rcx
mov rax, [rsp+0C8h+var_38]
mov [rsp+0C8h+var_B0], rax
mov rdi, [rsp+0C8h+var_28]
mov rsi, [rsp+0C8h+var_20]
call js_dup
mov rcx, rax
mov rax, [rsp+0C8h+var_B0]
mov [rsp+0C8h+var_80], rcx
mov [rsp+0C8h+var_78], rdx
mov rcx, [rsp+0C8h+var_80]
mov [rax], rcx
mov rcx, [rsp+0C8h+var_78]
mov [rax+8], rcx
mov ecx, [rsp+0C8h+arg_0]
mov rax, [rsp+0C8h+var_38]
mov [rax+10h], ecx
mov edx, [rsp+0C8h+var_5C]
mov rax, [rsp+0C8h+var_50]
mov ecx, [rax+40h]
and edx, 7FFFFFFFh
and ecx, 80000000h
or ecx, edx
mov [rax+40h], ecx
mov rax, [rsp+0C8h+var_50]
mov rcx, [rax+18h]
movsxd rax, [rsp+0C8h+var_5C]
shl rax, 4
add rcx, rax
mov rax, [rsp+0C8h+var_50]
mov [rax+20h], rcx
mov rax, [rsp+0C8h+var_50]
mov rcx, [rax+20h]
mov rax, [rsp+0C8h+var_48]
movzx eax, word ptr [rax+42h]
cdqe
shl rax, 4
add rcx, rax
mov rax, [rsp+0C8h+var_50]
mov [rax+48h], rcx
mov [rsp+0C8h+var_58], 0
loc_78502:
mov eax, [rsp+0C8h+var_58]
cmp eax, [rsp+0C8h+arg_0]
jge short loc_78579
mov rax, [rsp+0C8h+var_50]
mov rax, [rax+18h]
movsxd rcx, [rsp+0C8h+var_58]
shl rcx, 4
add rax, rcx
mov [rsp+0C8h+var_C0], rax
mov rax, [rsp+0C8h+arg_8]
movsxd rcx, [rsp+0C8h+var_58]
shl rcx, 4
add rax, rcx
mov rdi, [rax]
mov rsi, [rax+8]
call js_dup
mov rcx, rax
mov rax, [rsp+0C8h+var_C0]
mov [rsp+0C8h+var_90], rcx
mov [rsp+0C8h+var_88], rdx
mov rcx, [rsp+0C8h+var_90]
mov [rax], rcx
mov rcx, [rsp+0C8h+var_88]
mov [rax+8], rcx
mov eax, [rsp+0C8h+var_58]
add eax, 1
mov [rsp+0C8h+var_58], eax
jmp short loc_78502
loc_78579:
mov eax, [rsp+0C8h+var_5C]
mov rcx, [rsp+0C8h+var_48]
movzx ecx, word ptr [rcx+42h]
add eax, ecx
mov [rsp+0C8h+var_60], eax
mov eax, [rsp+0C8h+arg_0]
mov [rsp+0C8h+var_58], eax
loc_7859A:
mov eax, [rsp+0C8h+var_58]
cmp eax, [rsp+0C8h+var_60]
jge short loc_785E8
mov rax, [rsp+0C8h+var_50]
mov rax, [rax+18h]
movsxd rcx, [rsp+0C8h+var_58]
shl rcx, 4
add rax, rcx
mov dword ptr [rsp+0C8h+var_A0], 0
mov [rsp+0C8h+var_98], 3
mov rcx, [rsp+0C8h+var_A0]
mov [rax], rcx
mov rcx, [rsp+0C8h+var_98]
mov [rax+8], rcx
mov eax, [rsp+0C8h+var_58]
add eax, 1
mov [rsp+0C8h+var_58], eax
jmp short loc_7859A
loc_785E8:
mov [rsp+0C8h+var_4], 0
loc_785F3:
mov eax, [rsp+0C8h+var_4]
add rsp, 0C8h
retn
|
long long async_func_init(
long long a1,
long long a2,
long long a3,
unsigned int a4,
_DWORD *a5,
unsigned int a6,
signed int a7,
long long a8)
{
int v8; // eax
long long v9; // rdx
long long v10; // rdx
long long v11; // rdx
_QWORD *v12; // rax
_QWORD *v14; // [rsp+8h] [rbp-C0h]
long long v15; // [rsp+28h] [rbp-A0h]
signed int v16; // [rsp+68h] [rbp-60h]
int v17; // [rsp+6Ch] [rbp-5Ch]
signed int i; // [rsp+70h] [rbp-58h]
signed int j; // [rsp+70h] [rbp-58h]
long long v20; // [rsp+80h] [rbp-48h]
init_list_head_1((_QWORD *)(a2 + 64));
v20 = *(_QWORD *)(a3 + 48);
*(_DWORD *)(a2 + 88) = ((*(_WORD *)(v20 + 24) & 1) << 31) | *(_DWORD *)(a2 + 88) & 0x7FFFFFFF;
*(_QWORD *)(a2 + 80) = *(_QWORD *)(v20 + 32);
v17 = max_int_1(*(unsigned __int16 *)(v20 + 64), a7);
v8 = max_int_1(*(unsigned __int16 *)(v20 + 70) + (unsigned int)*(unsigned __int16 *)(v20 + 66) + v17, 1u);
*(_QWORD *)(a2 + 48) = js_malloc(a1, 16LL * v8);
if ( *(_QWORD *)(a2 + 48) )
{
*(_QWORD *)(a2 + 32) = js_dup((_DWORD *)a3, a4);
*(_QWORD *)(a2 + 40) = v9;
*(_QWORD *)a2 = js_dup(a5, a6);
*(_QWORD *)(a2 + 8) = v10;
*(_DWORD *)(a2 + 16) = a7;
*(_DWORD *)(a2 + 88) = v17 & 0x7FFFFFFF | *(_DWORD *)(a2 + 88) & 0x80000000;
*(_QWORD *)(a2 + 56) = 16LL * v17 + *(_QWORD *)(a2 + 48);
*(_QWORD *)(a2 + 96) = 16LL * *(unsigned __int16 *)(v20 + 66) + *(_QWORD *)(a2 + 56);
for ( i = 0; i < a7; ++i )
{
v14 = (_QWORD *)(16LL * i + *(_QWORD *)(a2 + 48));
*v14 = js_dup(*(_DWORD **)(16LL * i + a8), *(_QWORD *)(16LL * i + a8 + 8));
v14[1] = v11;
}
v16 = *(unsigned __int16 *)(v20 + 66) + v17;
for ( j = a7; j < v16; ++j )
{
v12 = (_QWORD *)(16LL * j + *(_QWORD *)(a2 + 48));
LODWORD(v15) = 0;
*v12 = v15;
v12[1] = 3LL;
}
return 0;
}
else
{
return (unsigned int)-1;
}
}
|
async_func_init:
SUB RSP,0xc8
MOV RAX,qword ptr [RSP + 0xd8]
MOV EAX,dword ptr [RSP + 0xd0]
MOV qword ptr [RSP + 0xb0],RDX
MOV qword ptr [RSP + 0xb8],RCX
MOV qword ptr [RSP + 0xa0],R8
MOV qword ptr [RSP + 0xa8],R9
MOV qword ptr [RSP + 0x98],RDI
MOV qword ptr [RSP + 0x90],RSI
MOV RAX,qword ptr [RSP + 0x90]
ADD RAX,0x18
MOV qword ptr [RSP + 0x78],RAX
MOV RDI,qword ptr [RSP + 0x78]
ADD RDI,0x28
CALL 0x00128680
MOV RAX,qword ptr [RSP + 0xb0]
MOV qword ptr [RSP + 0x88],RAX
MOV RAX,qword ptr [RSP + 0x88]
MOV RAX,qword ptr [RAX + 0x30]
MOV qword ptr [RSP + 0x80],RAX
MOV RAX,qword ptr [RSP + 0x80]
MOV AX,word ptr [RAX + 0x18]
AND AX,0x1
MOVZX EDX,AL
MOV RAX,qword ptr [RSP + 0x78]
MOV ECX,dword ptr [RAX + 0x40]
AND EDX,0x1
SHL EDX,0x1f
AND ECX,0x7fffffff
OR ECX,EDX
MOV dword ptr [RAX + 0x40],ECX
MOV RAX,qword ptr [RSP + 0x80]
MOV RCX,qword ptr [RAX + 0x20]
MOV RAX,qword ptr [RSP + 0x78]
MOV qword ptr [RAX + 0x38],RCX
MOV RAX,qword ptr [RSP + 0x80]
MOVZX EDI,word ptr [RAX + 0x40]
MOV ESI,dword ptr [RSP + 0xd0]
CALL 0x00163600
MOV dword ptr [RSP + 0x6c],EAX
MOV EAX,dword ptr [RSP + 0x6c]
MOV RCX,qword ptr [RSP + 0x80]
MOVZX ECX,word ptr [RCX + 0x42]
ADD EAX,ECX
MOV RCX,qword ptr [RSP + 0x80]
MOVZX ECX,word ptr [RCX + 0x46]
ADD EAX,ECX
MOV dword ptr [RSP + 0x74],EAX
MOV RAX,qword ptr [RSP + 0x98]
MOV qword ptr [RSP + 0x20],RAX
MOV EDI,dword ptr [RSP + 0x74]
MOV ESI,0x1
CALL 0x00163600
MOV RDI,qword ptr [RSP + 0x20]
MOVSXD RSI,EAX
SHL RSI,0x4
CALL 0x00127fa0
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x78]
MOV qword ptr [RAX + 0x18],RCX
MOV RAX,qword ptr [RSP + 0x78]
CMP qword ptr [RAX + 0x18],0x0
JNZ 0x001783fe
MOV dword ptr [RSP + 0xc4],0xffffffff
JMP 0x001785f3
LAB_001783fe:
MOV RAX,qword ptr [RSP + 0x78]
MOV qword ptr [RSP + 0x10],RAX
MOV RDI,qword ptr [RSP + 0xb0]
MOV RSI,qword ptr [RSP + 0xb8]
CALL 0x001279c0
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x58],RCX
MOV qword ptr [RSP + 0x60],RDX
MOV RCX,qword ptr [RSP + 0x58]
MOV qword ptr [RAX + 0x8],RCX
MOV RCX,qword ptr [RSP + 0x60]
MOV qword ptr [RAX + 0x10],RCX
MOV RAX,qword ptr [RSP + 0x90]
MOV qword ptr [RSP + 0x18],RAX
MOV RDI,qword ptr [RSP + 0xa0]
MOV RSI,qword ptr [RSP + 0xa8]
CALL 0x001279c0
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP + 0x48],RCX
MOV qword ptr [RSP + 0x50],RDX
MOV RCX,qword ptr [RSP + 0x48]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RSP + 0x50]
MOV qword ptr [RAX + 0x8],RCX
MOV ECX,dword ptr [RSP + 0xd0]
MOV RAX,qword ptr [RSP + 0x90]
MOV dword ptr [RAX + 0x10],ECX
MOV EDX,dword ptr [RSP + 0x6c]
MOV RAX,qword ptr [RSP + 0x78]
MOV ECX,dword ptr [RAX + 0x40]
AND EDX,0x7fffffff
AND ECX,0x80000000
OR ECX,EDX
MOV dword ptr [RAX + 0x40],ECX
MOV RAX,qword ptr [RSP + 0x78]
MOV RCX,qword ptr [RAX + 0x18]
MOVSXD RAX,dword ptr [RSP + 0x6c]
SHL RAX,0x4
ADD RCX,RAX
MOV RAX,qword ptr [RSP + 0x78]
MOV qword ptr [RAX + 0x20],RCX
MOV RAX,qword ptr [RSP + 0x78]
MOV RCX,qword ptr [RAX + 0x20]
MOV RAX,qword ptr [RSP + 0x80]
MOVZX EAX,word ptr [RAX + 0x42]
CDQE
SHL RAX,0x4
ADD RCX,RAX
MOV RAX,qword ptr [RSP + 0x78]
MOV qword ptr [RAX + 0x48],RCX
MOV dword ptr [RSP + 0x70],0x0
LAB_00178502:
MOV EAX,dword ptr [RSP + 0x70]
CMP EAX,dword ptr [RSP + 0xd0]
JGE 0x00178579
MOV RAX,qword ptr [RSP + 0x78]
MOV RAX,qword ptr [RAX + 0x18]
MOVSXD RCX,dword ptr [RSP + 0x70]
SHL RCX,0x4
ADD RAX,RCX
MOV qword ptr [RSP + 0x8],RAX
MOV RAX,qword ptr [RSP + 0xd8]
MOVSXD RCX,dword ptr [RSP + 0x70]
SHL RCX,0x4
ADD RAX,RCX
MOV RDI,qword ptr [RAX]
MOV RSI,qword ptr [RAX + 0x8]
CALL 0x001279c0
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x8]
MOV qword ptr [RSP + 0x38],RCX
MOV qword ptr [RSP + 0x40],RDX
MOV RCX,qword ptr [RSP + 0x38]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RSP + 0x40]
MOV qword ptr [RAX + 0x8],RCX
MOV EAX,dword ptr [RSP + 0x70]
ADD EAX,0x1
MOV dword ptr [RSP + 0x70],EAX
JMP 0x00178502
LAB_00178579:
MOV EAX,dword ptr [RSP + 0x6c]
MOV RCX,qword ptr [RSP + 0x80]
MOVZX ECX,word ptr [RCX + 0x42]
ADD EAX,ECX
MOV dword ptr [RSP + 0x68],EAX
MOV EAX,dword ptr [RSP + 0xd0]
MOV dword ptr [RSP + 0x70],EAX
LAB_0017859a:
MOV EAX,dword ptr [RSP + 0x70]
CMP EAX,dword ptr [RSP + 0x68]
JGE 0x001785e8
MOV RAX,qword ptr [RSP + 0x78]
MOV RAX,qword ptr [RAX + 0x18]
MOVSXD RCX,dword ptr [RSP + 0x70]
SHL RCX,0x4
ADD RAX,RCX
MOV dword ptr [RSP + 0x28],0x0
MOV qword ptr [RSP + 0x30],0x3
MOV RCX,qword ptr [RSP + 0x28]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RSP + 0x30]
MOV qword ptr [RAX + 0x8],RCX
MOV EAX,dword ptr [RSP + 0x70]
ADD EAX,0x1
MOV dword ptr [RSP + 0x70],EAX
JMP 0x0017859a
LAB_001785e8:
MOV dword ptr [RSP + 0xc4],0x0
LAB_001785f3:
MOV EAX,dword ptr [RSP + 0xc4]
ADD RSP,0xc8
RET
|
int4
async_func_init(int8 param_1,int1 (*param_2) [16],long param_3,int8 param_4,
int8 param_5,int8 param_6,int param_7,long param_8)
{
ushort uVar1;
long lVar2;
long lVar3;
uint uVar4;
int iVar5;
int8 uVar6;
int8 *puVar7;
long *plVar8;
int1 auVar9 [16];
uint uStack_9c;
int local_58;
int4 local_4;
init_list_head(param_2 + 4);
lVar2 = *(long *)(param_3 + 0x30);
*(uint *)(param_2[5] + 8) =
*(uint *)(param_2[5] + 8) & 0x7fffffff |
(uint)((byte)*(int2 *)(lVar2 + 0x18) & 1) << 0x1f;
*(int8 *)param_2[5] = *(int8 *)(lVar2 + 0x20);
uVar4 = max_int(*(int2 *)(lVar2 + 0x40),param_7);
iVar5 = max_int(uVar4 + *(ushort *)(lVar2 + 0x42) + (uint)*(ushort *)(lVar2 + 0x46),1);
uVar6 = js_malloc(param_1,(long)iVar5 << 4);
*(int8 *)param_2[3] = uVar6;
if (*(long *)param_2[3] == 0) {
local_4 = 0xffffffff;
}
else {
auVar9 = js_dup(param_3,param_4);
param_2[2] = auVar9;
auVar9 = js_dup(param_5,param_6);
*param_2 = auVar9;
*(int *)param_2[1] = param_7;
*(uint *)(param_2[5] + 8) = *(uint *)(param_2[5] + 8) & 0x80000000 | uVar4 & 0x7fffffff;
*(long *)(param_2[3] + 8) = *(long *)param_2[3] + (long)(int)uVar4 * 0x10;
*(long *)param_2[6] =
*(long *)(param_2[3] + 8) + (long)(int)(uint)*(ushort *)(lVar2 + 0x42) * 0x10;
for (local_58 = 0; local_58 < param_7; local_58 = local_58 + 1) {
lVar3 = *(long *)param_2[3];
puVar7 = (int8 *)(param_8 + (long)local_58 * 0x10);
auVar9 = js_dup(*puVar7,puVar7[1]);
*(int1 (*) [16])(lVar3 + (long)local_58 * 0x10) = auVar9;
}
uVar1 = *(ushort *)(lVar2 + 0x42);
for (local_58 = param_7; local_58 < (int)(uVar4 + uVar1); local_58 = local_58 + 1) {
plVar8 = (long *)(*(long *)param_2[3] + (long)local_58 * 0x10);
*plVar8 = (ulong)uStack_9c << 0x20;
plVar8[1] = 3;
}
local_4 = 0;
}
return local_4;
}
|
|
7,841 |
async_func_init
|
bluesky950520[P]quickjs/quickjs.c
|
static __exception int async_func_init(JSContext *ctx, JSAsyncFunctionState *s,
JSValue func_obj, JSValue this_obj,
int argc, JSValue *argv)
{
JSObject *p;
JSFunctionBytecode *b;
JSStackFrame *sf;
int local_count, i, arg_buf_len, n;
sf = &s->frame;
init_list_head(&sf->var_ref_list);
p = JS_VALUE_GET_OBJ(func_obj);
b = p->u.func.function_bytecode;
sf->is_strict_mode = b->is_strict_mode;
sf->cur_pc = b->byte_code_buf;
arg_buf_len = max_int(b->arg_count, argc);
local_count = arg_buf_len + b->var_count + b->stack_size;
sf->arg_buf = js_malloc(ctx, sizeof(JSValue) * max_int(local_count, 1));
if (!sf->arg_buf)
return -1;
sf->cur_func = js_dup(func_obj);
s->this_val = js_dup(this_obj);
s->argc = argc;
sf->arg_count = arg_buf_len;
sf->var_buf = sf->arg_buf + arg_buf_len;
sf->cur_sp = sf->var_buf + b->var_count;
for(i = 0; i < argc; i++)
sf->arg_buf[i] = js_dup(argv[i]);
n = arg_buf_len + b->var_count;
for(i = argc; i < n; i++)
sf->arg_buf[i] = JS_UNDEFINED;
return 0;
}
|
O1
|
c
|
async_func_init:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, 0x10(%rsp)
movq %r8, %r15
movq %rcx, %r12
movq %rdx, %r13
movq %rsi, %rbx
movl 0x50(%rsp), %edx
leaq 0x40(%rsi), %rax
movq %rax, 0x40(%rsi)
movq %rax, 0x48(%rsi)
movq 0x30(%r13), %rbp
movl 0x18(%rbp), %eax
shll $0x1f, %eax
movl $0x7fffffff, %ecx # imm = 0x7FFFFFFF
andl 0x58(%rsi), %ecx
orl %eax, %ecx
movl %ecx, 0x58(%rsi)
movq 0x20(%rbp), %rax
movq %rax, 0x50(%rsi)
movzwl 0x40(%rbp), %r14d
cmpl %edx, %r14d
cmovlel %edx, %r14d
movzwl 0x42(%rbp), %eax
movzwl 0x46(%rbp), %ecx
addl %eax, %ecx
addl %r14d, %ecx
cmpl $0x2, %ecx
pushq $0x1
popq %rsi
cmovgel %ecx, %esi
shlq $0x4, %rsi
callq 0xf082
movq %rax, 0x30(%rbx)
testq %rax, %rax
je 0x10ff2
movq %r13, 0x8(%rsp)
cmpl $-0x9, %r12d
jb 0x10f14
movq 0x8(%rsp), %rcx
incl (%rcx)
movq %r13, 0x20(%rbx)
movq %r12, 0x28(%rbx)
movq %r15, 0x8(%rsp)
movq 0x10(%rsp), %rdx
cmpl $-0x9, %edx
movl 0x50(%rsp), %r11d
jb 0x10f37
movq 0x8(%rsp), %rcx
incl (%rcx)
movq %r15, (%rbx)
movq %rdx, 0x8(%rbx)
movl %r11d, 0x10(%rbx)
movl $0x80000000, %ecx # imm = 0x80000000
andl 0x58(%rbx), %ecx
orl %r14d, %ecx
movl %ecx, 0x58(%rbx)
movl %r14d, %ecx
movq %rcx, %rdx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rax, 0x38(%rbx)
movzwl 0x42(%rbp), %edx
shll $0x4, %edx
addq %rax, %rdx
movq %rdx, 0x60(%rbx)
testl %r11d, %r11d
jle 0x10fb4
movq 0x58(%rsp), %rax
movl %r11d, %edx
shlq $0x4, %rdx
xorl %esi, %esi
movq 0x30(%rbx), %rdi
movq (%rax,%rsi), %r8
movq 0x8(%rax,%rsi), %r9
movq %r8, 0x8(%rsp)
cmpl $-0x9, %r9d
jb 0x10fa2
movq 0x8(%rsp), %r10
incl (%r10)
movq %r8, (%rdi,%rsi)
movq %r9, 0x8(%rdi,%rsi)
addq $0x10, %rsi
cmpq %rsi, %rdx
jne 0x10f82
movzwl 0x42(%rbp), %edx
addl %edx, %r14d
xorl %eax, %eax
cmpl %r11d, %r14d
jle 0x10ff5
movslq %r11d, %rsi
addq %rdx, %rcx
subq %rsi, %rcx
movq %rsi, %rdx
shlq $0x4, %rdx
orq $0x8, %rdx
movq 0x30(%rbx), %rsi
andl $0x0, -0x8(%rsi,%rdx)
movq $0x3, (%rsi,%rdx)
addq $0x10, %rdx
decq %rcx
jne 0x10fd6
jmp 0x10ff5
pushq $-0x1
popq %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
async_func_init:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov [rsp+48h+var_38], r9
mov r15, r8
mov r12, rcx
mov r13, rdx
mov rbx, rsi
mov edx, [rsp+48h+arg_0]
lea rax, [rsi+40h]
mov [rsi+40h], rax
mov [rsi+48h], rax
mov rbp, [r13+30h]
mov eax, [rbp+18h]
shl eax, 1Fh
mov ecx, 7FFFFFFFh
and ecx, [rsi+58h]
or ecx, eax
mov [rsi+58h], ecx
mov rax, [rbp+20h]
mov [rsi+50h], rax
movzx r14d, word ptr [rbp+40h]
cmp r14d, edx
cmovle r14d, edx
movzx eax, word ptr [rbp+42h]
movzx ecx, word ptr [rbp+46h]
add ecx, eax
add ecx, r14d
cmp ecx, 2
push 1
pop rsi
cmovge esi, ecx
shl rsi, 4
call js_malloc
mov [rbx+30h], rax
test rax, rax
jz loc_10FF2
mov [rsp+48h+var_40], r13
cmp r12d, 0FFFFFFF7h
jb short loc_10F14
mov rcx, [rsp+48h+var_40]
inc dword ptr [rcx]
loc_10F14:
mov [rbx+20h], r13
mov [rbx+28h], r12
mov [rsp+48h+var_40], r15
mov rdx, [rsp+48h+var_38]
cmp edx, 0FFFFFFF7h
mov r11d, [rsp+48h+arg_0]
jb short loc_10F37
mov rcx, [rsp+48h+var_40]
inc dword ptr [rcx]
loc_10F37:
mov [rbx], r15
mov [rbx+8], rdx
mov [rbx+10h], r11d
mov ecx, 80000000h
and ecx, [rbx+58h]
or ecx, r14d
mov [rbx+58h], ecx
mov ecx, r14d
mov rdx, rcx
shl rdx, 4
add rax, rdx
mov [rbx+38h], rax
movzx edx, word ptr [rbp+42h]
shl edx, 4
add rdx, rax
mov [rbx+60h], rdx
test r11d, r11d
jle short loc_10FB4
mov rax, [rsp+48h+arg_8]
mov edx, r11d
shl rdx, 4
xor esi, esi
loc_10F82:
mov rdi, [rbx+30h]
mov r8, [rax+rsi]
mov r9, [rax+rsi+8]
mov [rsp+48h+var_40], r8
cmp r9d, 0FFFFFFF7h
jb short loc_10FA2
mov r10, [rsp+48h+var_40]
inc dword ptr [r10]
loc_10FA2:
mov [rdi+rsi], r8
mov [rdi+rsi+8], r9
add rsi, 10h
cmp rdx, rsi
jnz short loc_10F82
loc_10FB4:
movzx edx, word ptr [rbp+42h]
add r14d, edx
xor eax, eax
cmp r14d, r11d
jle short loc_10FF5
movsxd rsi, r11d
add rcx, rdx
sub rcx, rsi
mov rdx, rsi
shl rdx, 4
or rdx, 8
loc_10FD6:
mov rsi, [rbx+30h]
and dword ptr [rsi+rdx-8], 0
mov qword ptr [rsi+rdx], 3
add rdx, 10h
dec rcx
jnz short loc_10FD6
jmp short loc_10FF5
loc_10FF2:
push 0FFFFFFFFFFFFFFFFh
pop rax
loc_10FF5:
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long async_func_init(
long long a1,
long long a2,
long long a3,
long long a4,
_DWORD *a5,
long long a6,
int a7,
long long a8)
{
long long v12; // rbp
unsigned int v13; // r14d
int v14; // ecx
long long v15; // rsi
long long v16; // rax
long long v17; // rax
long long v18; // rsi
long long v19; // rdi
long long v20; // r8
long long v21; // r9
long long v22; // rdx
long long result; // rax
long long v24; // rcx
long long v25; // rdx
long long v26; // rsi
*(_QWORD *)(a2 + 64) = a2 + 64;
*(_QWORD *)(a2 + 72) = a2 + 64;
v12 = *(_QWORD *)(a3 + 48);
*(_DWORD *)(a2 + 88) = (*(_DWORD *)(v12 + 24) << 31) | *(_DWORD *)(a2 + 88) & 0x7FFFFFFF;
*(_QWORD *)(a2 + 80) = *(_QWORD *)(v12 + 32);
v13 = *(unsigned __int16 *)(v12 + 64);
if ( (int)v13 <= a7 )
v13 = a7;
v14 = v13 + *(unsigned __int16 *)(v12 + 66) + *(unsigned __int16 *)(v12 + 70);
v15 = 1LL;
if ( v14 >= 2 )
v15 = (unsigned int)v14;
v16 = js_malloc(a1, 16 * v15);
*(_QWORD *)(a2 + 48) = v16;
if ( !v16 )
return -1LL;
if ( (unsigned int)a4 >= 0xFFFFFFF7 )
++*(_DWORD *)a3;
*(_QWORD *)(a2 + 32) = a3;
*(_QWORD *)(a2 + 40) = a4;
if ( (unsigned int)a6 >= 0xFFFFFFF7 )
++*a5;
*(_QWORD *)a2 = a5;
*(_QWORD *)(a2 + 8) = a6;
*(_DWORD *)(a2 + 16) = a7;
*(_DWORD *)(a2 + 88) = v13 | *(_DWORD *)(a2 + 88) & 0x80000000;
v17 = 16LL * v13 + v16;
*(_QWORD *)(a2 + 56) = v17;
*(_QWORD *)(a2 + 96) = v17 + 16 * (unsigned int)*(unsigned __int16 *)(v12 + 66);
if ( a7 > 0 )
{
v18 = 0LL;
do
{
v19 = *(_QWORD *)(a2 + 48);
v20 = *(_QWORD *)(a8 + v18);
v21 = *(_QWORD *)(a8 + v18 + 8);
if ( (unsigned int)v21 >= 0xFFFFFFF7 )
++**(_DWORD **)(a8 + v18);
*(_QWORD *)(v19 + v18) = v20;
*(_QWORD *)(v19 + v18 + 8) = v21;
v18 += 16LL;
}
while ( 16LL * (unsigned int)a7 != v18 );
}
v22 = *(unsigned __int16 *)(v12 + 66);
result = 0LL;
if ( (int)(v22 + v13) > a7 )
{
v24 = v22 + v13 - a7;
v25 = (16LL * a7) | 8;
do
{
v26 = *(_QWORD *)(a2 + 48);
*(_DWORD *)(v26 + v25 - 8) = 0;
*(_QWORD *)(v26 + v25) = 3LL;
v25 += 16LL;
--v24;
}
while ( v24 );
}
return result;
}
|
async_func_init:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV qword ptr [RSP + 0x10],R9
MOV R15,R8
MOV R12,RCX
MOV R13,RDX
MOV RBX,RSI
MOV EDX,dword ptr [RSP + 0x50]
LEA RAX,[RSI + 0x40]
MOV qword ptr [RSI + 0x40],RAX
MOV qword ptr [RSI + 0x48],RAX
MOV RBP,qword ptr [R13 + 0x30]
MOV EAX,dword ptr [RBP + 0x18]
SHL EAX,0x1f
MOV ECX,0x7fffffff
AND ECX,dword ptr [RSI + 0x58]
OR ECX,EAX
MOV dword ptr [RSI + 0x58],ECX
MOV RAX,qword ptr [RBP + 0x20]
MOV qword ptr [RSI + 0x50],RAX
MOVZX R14D,word ptr [RBP + 0x40]
CMP R14D,EDX
CMOVLE R14D,EDX
MOVZX EAX,word ptr [RBP + 0x42]
MOVZX ECX,word ptr [RBP + 0x46]
ADD ECX,EAX
ADD ECX,R14D
CMP ECX,0x2
PUSH 0x1
POP RSI
CMOVGE ESI,ECX
SHL RSI,0x4
CALL 0x0010f082
MOV qword ptr [RBX + 0x30],RAX
TEST RAX,RAX
JZ 0x00110ff2
MOV qword ptr [RSP + 0x8],R13
CMP R12D,-0x9
JC 0x00110f14
MOV RCX,qword ptr [RSP + 0x8]
INC dword ptr [RCX]
LAB_00110f14:
MOV qword ptr [RBX + 0x20],R13
MOV qword ptr [RBX + 0x28],R12
MOV qword ptr [RSP + 0x8],R15
MOV RDX,qword ptr [RSP + 0x10]
CMP EDX,-0x9
MOV R11D,dword ptr [RSP + 0x50]
JC 0x00110f37
MOV RCX,qword ptr [RSP + 0x8]
INC dword ptr [RCX]
LAB_00110f37:
MOV qword ptr [RBX],R15
MOV qword ptr [RBX + 0x8],RDX
MOV dword ptr [RBX + 0x10],R11D
MOV ECX,0x80000000
AND ECX,dword ptr [RBX + 0x58]
OR ECX,R14D
MOV dword ptr [RBX + 0x58],ECX
MOV ECX,R14D
MOV RDX,RCX
SHL RDX,0x4
ADD RAX,RDX
MOV qword ptr [RBX + 0x38],RAX
MOVZX EDX,word ptr [RBP + 0x42]
SHL EDX,0x4
ADD RDX,RAX
MOV qword ptr [RBX + 0x60],RDX
TEST R11D,R11D
JLE 0x00110fb4
MOV RAX,qword ptr [RSP + 0x58]
MOV EDX,R11D
SHL RDX,0x4
XOR ESI,ESI
LAB_00110f82:
MOV RDI,qword ptr [RBX + 0x30]
MOV R8,qword ptr [RAX + RSI*0x1]
MOV R9,qword ptr [RAX + RSI*0x1 + 0x8]
MOV qword ptr [RSP + 0x8],R8
CMP R9D,-0x9
JC 0x00110fa2
MOV R10,qword ptr [RSP + 0x8]
INC dword ptr [R10]
LAB_00110fa2:
MOV qword ptr [RDI + RSI*0x1],R8
MOV qword ptr [RDI + RSI*0x1 + 0x8],R9
ADD RSI,0x10
CMP RDX,RSI
JNZ 0x00110f82
LAB_00110fb4:
MOVZX EDX,word ptr [RBP + 0x42]
ADD R14D,EDX
XOR EAX,EAX
CMP R14D,R11D
JLE 0x00110ff5
MOVSXD RSI,R11D
ADD RCX,RDX
SUB RCX,RSI
MOV RDX,RSI
SHL RDX,0x4
OR RDX,0x8
LAB_00110fd6:
MOV RSI,qword ptr [RBX + 0x30]
AND dword ptr [RSI + RDX*0x1 + -0x8],0x0
MOV qword ptr [RSI + RDX*0x1],0x3
ADD RDX,0x10
DEC RCX
JNZ 0x00110fd6
JMP 0x00110ff5
LAB_00110ff2:
PUSH -0x1
POP RAX
LAB_00110ff5:
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8
async_func_init(int8 param_1,int8 *param_2,int *param_3,int8 param_4,int *param_5,
int8 param_6,uint param_7,long param_8)
{
long lVar1;
int *piVar2;
long lVar3;
int8 uVar4;
long lVar5;
ulong uVar6;
uint uVar7;
param_2[8] = param_2 + 8;
param_2[9] = param_2 + 8;
lVar5 = *(long *)(param_3 + 0xc);
*(uint *)(param_2 + 0xb) = *(uint *)(param_2 + 0xb) & 0x7fffffff | *(int *)(lVar5 + 0x18) << 0x1f;
param_2[10] = *(int8 *)(lVar5 + 0x20);
uVar7 = (uint)*(ushort *)(lVar5 + 0x40);
if ((int)(uint)*(ushort *)(lVar5 + 0x40) <= (int)param_7) {
uVar7 = param_7;
}
lVar3 = js_malloc();
param_2[6] = lVar3;
if (lVar3 == 0) {
uVar4 = 0xffffffffffffffff;
}
else {
if (0xfffffff6 < (uint)param_4) {
*param_3 = *param_3 + 1;
}
param_2[4] = param_3;
param_2[5] = param_4;
if (0xfffffff6 < (uint)param_6) {
*param_5 = *param_5 + 1;
}
*param_2 = param_5;
param_2[1] = param_6;
*(uint *)(param_2 + 2) = param_7;
*(uint *)(param_2 + 0xb) = *(uint *)(param_2 + 0xb) & 0x80000000 | uVar7;
lVar3 = lVar3 + (ulong)uVar7 * 0x10;
param_2[7] = lVar3;
param_2[0xc] = (ulong)*(ushort *)(lVar5 + 0x42) * 0x10 + lVar3;
if (0 < (int)param_7) {
lVar3 = 0;
do {
lVar1 = param_2[6];
piVar2 = *(int **)(param_8 + lVar3);
uVar4 = *(int8 *)(param_8 + 8 + lVar3);
if (0xfffffff6 < (uint)uVar4) {
*piVar2 = *piVar2 + 1;
}
*(int **)(lVar1 + lVar3) = piVar2;
*(int8 *)(lVar1 + 8 + lVar3) = uVar4;
lVar3 = lVar3 + 0x10;
} while ((ulong)param_7 << 4 != lVar3);
}
uVar4 = 0;
if ((int)param_7 < (int)(uVar7 + *(ushort *)(lVar5 + 0x42))) {
lVar5 = ((ulong)uVar7 + (ulong)*(ushort *)(lVar5 + 0x42)) - (long)(int)param_7;
uVar6 = (long)(int)param_7 << 4 | 8;
do {
lVar3 = param_2[6];
*(int4 *)(lVar3 + -8 + uVar6) = 0;
*(int8 *)(lVar3 + uVar6) = 3;
uVar6 = uVar6 + 0x10;
lVar5 = lVar5 + -1;
} while (lVar5 != 0);
}
}
return uVar4;
}
|
|
7,842 |
async_func_init
|
bluesky950520[P]quickjs/quickjs.c
|
static __exception int async_func_init(JSContext *ctx, JSAsyncFunctionState *s,
JSValue func_obj, JSValue this_obj,
int argc, JSValue *argv)
{
JSObject *p;
JSFunctionBytecode *b;
JSStackFrame *sf;
int local_count, i, arg_buf_len, n;
sf = &s->frame;
init_list_head(&sf->var_ref_list);
p = JS_VALUE_GET_OBJ(func_obj);
b = p->u.func.function_bytecode;
sf->is_strict_mode = b->is_strict_mode;
sf->cur_pc = b->byte_code_buf;
arg_buf_len = max_int(b->arg_count, argc);
local_count = arg_buf_len + b->var_count + b->stack_size;
sf->arg_buf = js_malloc(ctx, sizeof(JSValue) * max_int(local_count, 1));
if (!sf->arg_buf)
return -1;
sf->cur_func = js_dup(func_obj);
s->this_val = js_dup(this_obj);
s->argc = argc;
sf->arg_count = arg_buf_len;
sf->var_buf = sf->arg_buf + arg_buf_len;
sf->cur_sp = sf->var_buf + b->var_count;
for(i = 0; i < argc; i++)
sf->arg_buf[i] = js_dup(argv[i]);
n = arg_buf_len + b->var_count;
for(i = argc; i < n; i++)
sf->arg_buf[i] = JS_UNDEFINED;
return 0;
}
|
O2
|
c
|
async_func_init:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r9, %r14
movq %r8, (%rsp)
movq %rcx, %r12
movq %rdx, %r13
movq %rsi, %rbx
movl 0x40(%rsp), %edx
leaq 0x40(%rsi), %rax
movq %rax, 0x40(%rsi)
movq %rax, 0x48(%rsi)
movq 0x30(%r13), %r15
movl 0x18(%r15), %eax
shll $0x1f, %eax
movl $0x7fffffff, %ecx # imm = 0x7FFFFFFF
andl 0x58(%rsi), %ecx
orl %eax, %ecx
movl %ecx, 0x58(%rsi)
movq 0x20(%r15), %rax
movq %rax, 0x50(%rsi)
movzwl 0x40(%r15), %ebp
cmpl %edx, %ebp
cmovlel %edx, %ebp
movzwl 0x42(%r15), %esi
addl %ebp, %esi
movzwl 0x46(%r15), %eax
leal (%rsi,%rax), %ecx
cmpl $0x1, %ecx
adcl %eax, %esi
shlq $0x4, %rsi
callq 0x1adc4
movq %rax, 0x30(%rbx)
testq %rax, %rax
je 0x3e965
cmpl $-0x9, %r12d
jb 0x3e8a0
incl (%r13)
movq %r13, 0x20(%rbx)
movq %r12, 0x28(%rbx)
cmpl $-0x9, %r14d
movl 0x40(%rsp), %r9d
movq (%rsp), %rdx
jb 0x3e8b9
incl (%rdx)
movq 0x48(%rsp), %rcx
movq %rdx, (%rbx)
movq %r14, 0x8(%rbx)
movl %r9d, 0x10(%rbx)
movl $0x80000000, %edx # imm = 0x80000000
andl 0x58(%rbx), %edx
orl %ebp, %edx
movl %edx, 0x58(%rbx)
movl %ebp, %edx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rax, 0x38(%rbx)
movzwl 0x42(%r15), %edx
shll $0x4, %edx
addq %rax, %rdx
movq %rdx, 0x60(%rbx)
xorl %eax, %eax
testl %r9d, %r9d
movl $0x0, %edx
cmovgl %r9d, %edx
shlq $0x4, %rdx
cmpq %rax, %rdx
je 0x3e92d
movq 0x30(%rbx), %rsi
movq (%rcx,%rax), %rdi
movq 0x8(%rcx,%rax), %r8
cmpl $-0x9, %r8d
jb 0x3e91e
incl (%rdi)
movq %rdi, (%rsi,%rax)
movq %r8, 0x8(%rsi,%rax)
addq $0x10, %rax
jmp 0x3e904
movzwl 0x42(%r15), %eax
addl %eax, %ebp
movslq %r9d, %rax
movq %rax, %rcx
shlq $0x4, %rcx
orq $0x8, %rcx
cmpq %rbp, %rax
jge 0x3e961
movq 0x30(%rbx), %rdx
andl $0x0, -0x8(%rdx,%rcx)
movq $0x3, (%rdx,%rcx)
incq %rax
addq $0x10, %rcx
jmp 0x3e942
xorl %eax, %eax
jmp 0x3e968
pushq $-0x1
popq %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
async_func_init:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r14, r9
mov [rsp+38h+var_38], r8
mov r12, rcx
mov r13, rdx
mov rbx, rsi
mov edx, [rsp+38h+arg_0]
lea rax, [rsi+40h]
mov [rsi+40h], rax
mov [rsi+48h], rax
mov r15, [r13+30h]
mov eax, [r15+18h]
shl eax, 1Fh
mov ecx, 7FFFFFFFh
and ecx, [rsi+58h]
or ecx, eax
mov [rsi+58h], ecx
mov rax, [r15+20h]
mov [rsi+50h], rax
movzx ebp, word ptr [r15+40h]
cmp ebp, edx
cmovle ebp, edx
movzx esi, word ptr [r15+42h]
add esi, ebp
movzx eax, word ptr [r15+46h]
lea ecx, [rsi+rax]
cmp ecx, 1
adc esi, eax
shl rsi, 4
call js_malloc
mov [rbx+30h], rax
test rax, rax
jz loc_3E965
cmp r12d, 0FFFFFFF7h
jb short loc_3E8A0
inc dword ptr [r13+0]
loc_3E8A0:
mov [rbx+20h], r13
mov [rbx+28h], r12
cmp r14d, 0FFFFFFF7h
mov r9d, [rsp+38h+arg_0]
mov rdx, [rsp+38h+var_38]
jb short loc_3E8B9
inc dword ptr [rdx]
loc_3E8B9:
mov rcx, [rsp+38h+arg_8]
mov [rbx], rdx
mov [rbx+8], r14
mov [rbx+10h], r9d
mov edx, 80000000h
and edx, [rbx+58h]
or edx, ebp
mov [rbx+58h], edx
mov edx, ebp
shl rdx, 4
add rax, rdx
mov [rbx+38h], rax
movzx edx, word ptr [r15+42h]
shl edx, 4
add rdx, rax
mov [rbx+60h], rdx
xor eax, eax
test r9d, r9d
mov edx, 0
cmovg edx, r9d
shl rdx, 4
loc_3E904:
cmp rdx, rax
jz short loc_3E92D
mov rsi, [rbx+30h]
mov rdi, [rcx+rax]
mov r8, [rcx+rax+8]
cmp r8d, 0FFFFFFF7h
jb short loc_3E91E
inc dword ptr [rdi]
loc_3E91E:
mov [rsi+rax], rdi
mov [rsi+rax+8], r8
add rax, 10h
jmp short loc_3E904
loc_3E92D:
movzx eax, word ptr [r15+42h]
add ebp, eax
movsxd rax, r9d
mov rcx, rax
shl rcx, 4
or rcx, 8
loc_3E942:
cmp rax, rbp
jge short loc_3E961
mov rdx, [rbx+30h]
and dword ptr [rdx+rcx-8], 0
mov qword ptr [rdx+rcx], 3
inc rax
add rcx, 10h
jmp short loc_3E942
loc_3E961:
xor eax, eax
jmp short loc_3E968
loc_3E965:
push 0FFFFFFFFFFFFFFFFh
pop rax
loc_3E968:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long async_func_init(
long long a1,
long long a2,
long long a3,
long long a4,
_DWORD *a5,
long long a6,
int a7,
long long a8)
{
long long v12; // r15
int v13; // ebp
long long v14; // rax
long long v15; // rax
long long v16; // rax
long long v17; // rdx
long long v18; // rdx
long long v19; // rsi
_DWORD *v20; // rdi
long long v21; // r8
long long v22; // rbp
long long v23; // rax
long long v24; // rcx
long long v25; // rdx
*(_QWORD *)(a2 + 64) = a2 + 64;
*(_QWORD *)(a2 + 72) = a2 + 64;
v12 = *(_QWORD *)(a3 + 48);
*(_DWORD *)(a2 + 88) = (*(_DWORD *)(v12 + 24) << 31) | *(_DWORD *)(a2 + 88) & 0x7FFFFFFF;
*(_QWORD *)(a2 + 80) = *(_QWORD *)(v12 + 32);
v13 = *(unsigned __int16 *)(v12 + 64);
if ( v13 <= a7 )
v13 = a7;
v14 = js_malloc(
a1,
16LL
* (*(unsigned __int16 *)(v12 + 70)
+ (v13 + *(unsigned __int16 *)(v12 + 66) + *(unsigned __int16 *)(v12 + 70) == 0)
+ v13
+ (unsigned int)*(unsigned __int16 *)(v12 + 66)));
*(_QWORD *)(a2 + 48) = v14;
if ( !v14 )
return -1LL;
if ( (unsigned int)a4 >= 0xFFFFFFF7 )
++*(_DWORD *)a3;
*(_QWORD *)(a2 + 32) = a3;
*(_QWORD *)(a2 + 40) = a4;
if ( (unsigned int)a6 >= 0xFFFFFFF7 )
++*a5;
*(_QWORD *)a2 = a5;
*(_QWORD *)(a2 + 8) = a6;
*(_DWORD *)(a2 + 16) = a7;
*(_DWORD *)(a2 + 88) = v13 | *(_DWORD *)(a2 + 88) & 0x80000000;
v15 = 16LL * (unsigned int)v13 + v14;
*(_QWORD *)(a2 + 56) = v15;
*(_QWORD *)(a2 + 96) = v15 + 16 * (unsigned int)*(unsigned __int16 *)(v12 + 66);
v16 = 0LL;
v17 = 0LL;
if ( a7 > 0 )
v17 = (unsigned int)a7;
v18 = 16 * v17;
while ( v18 != v16 )
{
v19 = *(_QWORD *)(a2 + 48);
v20 = *(_DWORD **)(a8 + v16);
v21 = *(_QWORD *)(a8 + v16 + 8);
if ( (unsigned int)v21 >= 0xFFFFFFF7 )
++*v20;
*(_QWORD *)(v19 + v16) = v20;
*(_QWORD *)(v19 + v16 + 8) = v21;
v16 += 16LL;
}
v22 = (unsigned int)*(unsigned __int16 *)(v12 + 66) + v13;
v23 = a7;
v24 = (16LL * a7) | 8;
while ( v23 < v22 )
{
v25 = *(_QWORD *)(a2 + 48);
*(_DWORD *)(v25 + v24 - 8) = 0;
*(_QWORD *)(v25 + v24) = 3LL;
++v23;
v24 += 16LL;
}
return 0LL;
}
|
async_func_init:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R14,R9
MOV qword ptr [RSP],R8
MOV R12,RCX
MOV R13,RDX
MOV RBX,RSI
MOV EDX,dword ptr [RSP + 0x40]
LEA RAX,[RSI + 0x40]
MOV qword ptr [RSI + 0x40],RAX
MOV qword ptr [RSI + 0x48],RAX
MOV R15,qword ptr [R13 + 0x30]
MOV EAX,dword ptr [R15 + 0x18]
SHL EAX,0x1f
MOV ECX,0x7fffffff
AND ECX,dword ptr [RSI + 0x58]
OR ECX,EAX
MOV dword ptr [RSI + 0x58],ECX
MOV RAX,qword ptr [R15 + 0x20]
MOV qword ptr [RSI + 0x50],RAX
MOVZX EBP,word ptr [R15 + 0x40]
CMP EBP,EDX
CMOVLE EBP,EDX
MOVZX ESI,word ptr [R15 + 0x42]
ADD ESI,EBP
MOVZX EAX,word ptr [R15 + 0x46]
LEA ECX,[RSI + RAX*0x1]
CMP ECX,0x1
ADC ESI,EAX
SHL RSI,0x4
CALL 0x0011adc4
MOV qword ptr [RBX + 0x30],RAX
TEST RAX,RAX
JZ 0x0013e965
CMP R12D,-0x9
JC 0x0013e8a0
INC dword ptr [R13]
LAB_0013e8a0:
MOV qword ptr [RBX + 0x20],R13
MOV qword ptr [RBX + 0x28],R12
CMP R14D,-0x9
MOV R9D,dword ptr [RSP + 0x40]
MOV RDX,qword ptr [RSP]
JC 0x0013e8b9
INC dword ptr [RDX]
LAB_0013e8b9:
MOV RCX,qword ptr [RSP + 0x48]
MOV qword ptr [RBX],RDX
MOV qword ptr [RBX + 0x8],R14
MOV dword ptr [RBX + 0x10],R9D
MOV EDX,0x80000000
AND EDX,dword ptr [RBX + 0x58]
OR EDX,EBP
MOV dword ptr [RBX + 0x58],EDX
MOV EDX,EBP
SHL RDX,0x4
ADD RAX,RDX
MOV qword ptr [RBX + 0x38],RAX
MOVZX EDX,word ptr [R15 + 0x42]
SHL EDX,0x4
ADD RDX,RAX
MOV qword ptr [RBX + 0x60],RDX
XOR EAX,EAX
TEST R9D,R9D
MOV EDX,0x0
CMOVG EDX,R9D
SHL RDX,0x4
LAB_0013e904:
CMP RDX,RAX
JZ 0x0013e92d
MOV RSI,qword ptr [RBX + 0x30]
MOV RDI,qword ptr [RCX + RAX*0x1]
MOV R8,qword ptr [RCX + RAX*0x1 + 0x8]
CMP R8D,-0x9
JC 0x0013e91e
INC dword ptr [RDI]
LAB_0013e91e:
MOV qword ptr [RSI + RAX*0x1],RDI
MOV qword ptr [RSI + RAX*0x1 + 0x8],R8
ADD RAX,0x10
JMP 0x0013e904
LAB_0013e92d:
MOVZX EAX,word ptr [R15 + 0x42]
ADD EBP,EAX
MOVSXD RAX,R9D
MOV RCX,RAX
SHL RCX,0x4
OR RCX,0x8
LAB_0013e942:
CMP RAX,RBP
JGE 0x0013e961
MOV RDX,qword ptr [RBX + 0x30]
AND dword ptr [RDX + RCX*0x1 + -0x8],0x0
MOV qword ptr [RDX + RCX*0x1],0x3
INC RAX
ADD RCX,0x10
JMP 0x0013e942
LAB_0013e961:
XOR EAX,EAX
JMP 0x0013e968
LAB_0013e965:
PUSH -0x1
POP RAX
LAB_0013e968:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8
async_func_init(int8 param_1,int8 *param_2,int *param_3,int8 param_4,int *param_5,
int8 param_6,uint param_7,long param_8)
{
ushort uVar1;
long lVar2;
int *piVar3;
long lVar4;
long lVar5;
int8 uVar6;
ulong uVar7;
uint uVar8;
int iVar9;
param_2[8] = param_2 + 8;
param_2[9] = param_2 + 8;
lVar5 = *(long *)(param_3 + 0xc);
*(uint *)(param_2 + 0xb) = *(uint *)(param_2 + 0xb) & 0x7fffffff | *(int *)(lVar5 + 0x18) << 0x1f;
param_2[10] = *(int8 *)(lVar5 + 0x20);
uVar8 = (uint)*(ushort *)(lVar5 + 0x40);
if ((int)(uint)*(ushort *)(lVar5 + 0x40) <= (int)param_7) {
uVar8 = param_7;
}
iVar9 = *(ushort *)(lVar5 + 0x42) + uVar8;
lVar4 = js_malloc(param_1,(ulong)(iVar9 + (uint)*(ushort *)(lVar5 + 0x46) +
(uint)(iVar9 + (uint)*(ushort *)(lVar5 + 0x46) == 0)) << 4);
param_2[6] = lVar4;
if (lVar4 == 0) {
uVar6 = 0xffffffffffffffff;
}
else {
if (0xfffffff6 < (uint)param_4) {
*param_3 = *param_3 + 1;
}
param_2[4] = param_3;
param_2[5] = param_4;
if (0xfffffff6 < (uint)param_6) {
*param_5 = *param_5 + 1;
}
*param_2 = param_5;
param_2[1] = param_6;
*(uint *)(param_2 + 2) = param_7;
*(uint *)(param_2 + 0xb) = *(uint *)(param_2 + 0xb) & 0x80000000 | uVar8;
lVar4 = lVar4 + (ulong)uVar8 * 0x10;
param_2[7] = lVar4;
param_2[0xc] = (ulong)*(ushort *)(lVar5 + 0x42) * 0x10 + lVar4;
lVar4 = 0;
uVar7 = 0;
if (0 < (int)param_7) {
uVar7 = (ulong)param_7;
}
for (; uVar7 * 0x10 != lVar4; lVar4 = lVar4 + 0x10) {
lVar2 = param_2[6];
piVar3 = *(int **)(param_8 + lVar4);
uVar6 = *(int8 *)(param_8 + 8 + lVar4);
if (0xfffffff6 < (uint)uVar6) {
*piVar3 = *piVar3 + 1;
}
*(int **)(lVar2 + lVar4) = piVar3;
*(int8 *)(lVar2 + 8 + lVar4) = uVar6;
}
uVar1 = *(ushort *)(lVar5 + 0x42);
lVar5 = (long)(int)param_7;
uVar7 = lVar5 << 4 | 8;
for (; lVar5 < (long)(ulong)(uVar8 + uVar1); lVar5 = lVar5 + 1) {
lVar4 = param_2[6];
*(int4 *)(lVar4 + -8 + uVar7) = 0;
*(int8 *)(lVar4 + uVar7) = 3;
uVar7 = uVar7 + 0x10;
}
uVar6 = 0;
}
return uVar6;
}
|
|
7,843 |
google::protobuf::io::FileInputStream::CopyingFileInputStream::Skip(int)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/io/zero_copy_stream_impl.cc
|
int FileInputStream::CopyingFileInputStream::Skip(int count) {
GOOGLE_CHECK(!is_closed_);
if (!previous_seek_failed_ && lseek(file_, count, SEEK_CUR) != (off_t)-1) {
// Seek succeeded.
return count;
} else {
// Failed to seek.
// Note to self: Don't seek again. This file descriptor doesn't
// support it.
previous_seek_failed_ = true;
// Use the default implementation.
return CopyingInputStream::Skip(count);
}
}
|
O3
|
cpp
|
google::protobuf::io::FileInputStream::CopyingFileInputStream::Skip(int):
pushq %r15
pushq %r14
pushq %rbx
subq $0x40, %rsp
movl %esi, %ebx
movq %rdi, %r14
cmpb $0x1, 0xd(%rdi)
jne 0xfbb2a
leaq 0xf0666(%rip), %rdx # 0x1ec153
leaq 0x8(%rsp), %r15
movq %r15, %rdi
movl $0x3, %esi
movl $0x9a, %ecx
callq 0x1072ba
leaq 0xf06ce(%rip), %rsi # 0x1ec1d9
movq %r15, %rdi
callq 0x106db8
leaq 0x7(%rsp), %rdi
movq %rax, %rsi
callq 0x106e92
leaq 0x8(%rsp), %rdi
callq 0x1072d8
cmpb $0x0, 0x14(%r14)
jne 0xfbb48
movl 0x8(%r14), %edi
movslq %ebx, %rsi
movl $0x1, %edx
callq 0x1f8d0
cmpq $-0x1, %rax
jne 0xfbb59
movb $0x1, 0x14(%r14)
movq %r14, %rdi
movl %ebx, %esi
callq 0xfc81a
movl %eax, %ebx
movl %ebx, %eax
addq $0x40, %rsp
popq %rbx
popq %r14
popq %r15
retq
jmp 0xfbb67
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x1072d8
movq %rbx, %rdi
callq 0x1f860
|
_ZN6google8protobuf2io15FileInputStream22CopyingFileInputStream4SkipEi:
push r15
push r14
push rbx
sub rsp, 40h
mov ebx, esi
mov r14, rdi
cmp byte ptr [rdi+0Dh], 1
jnz short loc_FBB2A
lea rdx, aWorkspaceLlm4b_50; "/workspace/llm4binary/github2025/aimrt_"...
lea r15, [rsp+58h+var_50]
mov rdi, r15
mov esi, 3
mov ecx, 9Ah
call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int)
lea rsi, aCheckFailedIsC; "CHECK failed: !is_closed_: "
mov rdi, r15
call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*)
lea rdi, [rsp+58h+var_51]
mov rsi, rax
call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &)
lea rdi, [rsp+58h+var_50]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
loc_FBB2A:
cmp byte ptr [r14+14h], 0
jnz short loc_FBB48
mov edi, [r14+8]
movsxd rsi, ebx
mov edx, 1
call _lseek
cmp rax, 0FFFFFFFFFFFFFFFFh
jnz short loc_FBB59
loc_FBB48:
mov byte ptr [r14+14h], 1
mov rdi, r14; this
mov esi, ebx; int
call _ZN6google8protobuf2io18CopyingInputStream4SkipEi; google::protobuf::io::CopyingInputStream::Skip(int)
mov ebx, eax
loc_FBB59:
mov eax, ebx
add rsp, 40h
pop rbx
pop r14
pop r15
retn
jmp short $+2
loc_FBB67:
mov rbx, rax
lea rdi, [rsp+arg_0]; this
call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage()
mov rdi, rbx
call __Unwind_Resume
|
long long google::protobuf::io::FileInputStream::CopyingFileInputStream::Skip(
google::protobuf::io::FileInputStream::CopyingFileInputStream *this,
int a2)
{
unsigned int v2; // ebx
long long v3; // rax
char v5; // [rsp+7h] [rbp-51h] BYREF
_BYTE v6[80]; // [rsp+8h] [rbp-50h] BYREF
v2 = a2;
if ( *((_BYTE *)this + 13) == 1 )
{
google::protobuf::internal::LogMessage::LogMessage(
v6,
3LL,
"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/io/zero_copy_stream_impl.cc",
154LL);
v3 = google::protobuf::internal::LogMessage::operator<<(v6, "CHECK failed: !is_closed_: ");
google::protobuf::internal::LogFinisher::operator=(&v5, v3);
google::protobuf::internal::LogMessage::~LogMessage((google::protobuf::internal::LogMessage *)v6);
}
if ( *((_BYTE *)this + 20) || lseek(*((unsigned int *)this + 2), a2, 1LL) == -1 )
{
*((_BYTE *)this + 20) = 1;
return (unsigned int)google::protobuf::io::CopyingInputStream::Skip(this, a2);
}
return v2;
}
|
Skip:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x40
MOV EBX,ESI
MOV R14,RDI
CMP byte ptr [RDI + 0xd],0x1
JNZ 0x001fbb2a
LEA RDX,[0x2ec153]
LEA R15,[RSP + 0x8]
MOV RDI,R15
MOV ESI,0x3
MOV ECX,0x9a
CALL 0x002072ba
LAB_001fbb04:
LEA RSI,[0x2ec1d9]
MOV RDI,R15
CALL 0x00206db8
LAB_001fbb13:
LEA RDI,[RSP + 0x7]
MOV RSI,RAX
CALL 0x00206e92
LAB_001fbb20:
LEA RDI,[RSP + 0x8]
CALL 0x002072d8
LAB_001fbb2a:
CMP byte ptr [R14 + 0x14],0x0
JNZ 0x001fbb48
MOV EDI,dword ptr [R14 + 0x8]
MOVSXD RSI,EBX
MOV EDX,0x1
CALL 0x0011f8d0
CMP RAX,-0x1
JNZ 0x001fbb59
LAB_001fbb48:
MOV byte ptr [R14 + 0x14],0x1
MOV RDI,R14
MOV ESI,EBX
CALL 0x001fc81a
MOV EBX,EAX
LAB_001fbb59:
MOV EAX,EBX
ADD RSP,0x40
POP RBX
POP R14
POP R15
RET
|
/* google::protobuf::io::FileInputStream::CopyingFileInputStream::Skip(int) */
int __thiscall
google::protobuf::io::FileInputStream::CopyingFileInputStream::Skip
(CopyingFileInputStream *this,int param_1)
{
int iVar1;
LogMessage *pLVar2;
__off_t _Var3;
LogFinisher local_51;
LogMessage local_50 [56];
if (this[0xd] == (CopyingFileInputStream)0x1) {
internal::LogMessage::LogMessage
(local_50,3,
"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/io/zero_copy_stream_impl.cc"
,0x9a);
/* try { // try from 001fbb04 to 001fbb12 has its CatchHandler @ 001fbb67 */
pLVar2 = (LogMessage *)internal::LogMessage::operator<<(local_50,"CHECK failed: !is_closed_: ");
/* try { // try from 001fbb13 to 001fbb1f has its CatchHandler @ 001fbb65 */
internal::LogFinisher::operator=(&local_51,pLVar2);
internal::LogMessage::~LogMessage(local_50);
}
if ((this[0x14] == (CopyingFileInputStream)0x0) &&
(_Var3 = lseek(*(int *)(this + 8),(long)param_1,1), _Var3 != -1)) {
return param_1;
}
this[0x14] = (CopyingFileInputStream)0x1;
iVar1 = CopyingInputStream::Skip((CopyingInputStream *)this,param_1);
return iVar1;
}
|
|
7,844 |
long minja::Value::get<long>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, long) const
|
llama.cpp/common/minja/minja.hpp
|
T get(const std::string & key, T default_value) const {
if (!contains(key)) return default_value;
return at(key).get<T>();
}
|
O3
|
cpp
|
long minja::Value::get<long>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, long) const:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rcx, %r14
movq %rdx, %r12
movq %rsi, %r15
movq %rdi, %rbx
movq %rsi, %rdi
movq %rdx, %rsi
callq 0x78f6c
testb %al, %al
je 0x7bc0e
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movq %r12, %rsi
callq 0x729ee
movq %r15, %rdi
movq %r14, %rsi
callq 0x775c6
movq %rbx, %rdi
movq %rax, %rsi
callq 0x75e92
leaq 0x48(%rsp), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x732fc
movq %r14, %rdi
callq 0x300e0
leaq 0x40(%rsp), %rdi
callq 0x34564
leaq 0x30(%rsp), %rdi
callq 0x34564
leaq 0x20(%rsp), %r14
movq %r14, %rdi
callq 0x34564
movq -0x10(%r14), %rdi
testq %rdi, %rdi
je 0x7bc6e
movq 0x84392(%rip), %rax # 0xfff90
cmpb $0x0, (%rax)
je 0x7bc59
movl 0xc(%rdi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0xc(%rdi)
jmp 0x7bc63
leaq 0x10(%rbx), %rdi
movq %rdi, (%rbx)
movq (%r14), %rax
leaq 0x10(%r14), %r15
cmpq %r15, %rax
je 0x7bc32
movq %rax, (%rbx)
movq 0x10(%r14), %rax
movq %rax, 0x10(%rbx)
movq 0x8(%r14), %r12
jmp 0x7bc43
movq 0x8(%r14), %r12
leaq 0x1(%r12), %rdx
movq %r15, %rsi
callq 0x1c0b0
movq %r12, 0x8(%rbx)
movq %r15, (%r14)
movq $0x0, 0x8(%r14)
movb $0x0, 0x10(%r14)
jmp 0x7bc6e
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
lock
xaddl %eax, 0xc(%rdi)
cmpl $0x1, %eax
jne 0x7bc6e
movq (%rdi), %rax
callq *0x18(%rax)
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x6cc36
movq %rbx, %rdi
callq 0x1c7d0
|
_ZNK5minja5Value3getINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEET_RKS7_S8_:
push r15
push r14
push r12
push rbx
sub rsp, 58h
mov r14, rcx
mov r12, rdx
mov r15, rsi
mov rbx, rdi
mov rdi, rsi
mov rsi, rdx
call _ZNK5minja5Value8containsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; minja::Value::contains(std::string const&)
test al, al
jz short loc_7BC0E
lea r14, [rsp+78h+var_70]
mov rdi, r14
mov rsi, r12
call _ZN5minja5ValueC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; minja::Value::Value(std::string const&)
mov rdi, r15; this
mov rsi, r14; minja::Value *
call _ZN5minja5Value2atERKS0_; minja::Value::at(minja::Value const&)
mov rdi, rbx
mov rsi, rax
call _ZNK5minja5Value3getINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEET_v; minja::Value::get<std::string>(void)
lea r14, [rsp+78h+var_30]
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
lea rdi, [rsp+78h+var_38]
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
lea rdi, [rsp+78h+var_48]
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
lea r14, [rsp+78h+var_58]
mov rdi, r14
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
mov rdi, [r14-10h]
test rdi, rdi
jz short loc_7BC6E
mov rax, cs:_ZTISt19_Sp_make_shared_tag; `typeinfo for'std::_Sp_make_shared_tag
cmp byte ptr [rax], 0
jz short loc_7BC59
mov eax, [rdi+0Ch]
lea ecx, [rax-1]
mov [rdi+0Ch], ecx
jmp short loc_7BC63
loc_7BC0E:
lea rdi, [rbx+10h]
mov [rbx], rdi
mov rax, [r14]
lea r15, [r14+10h]
cmp rax, r15
jz short loc_7BC32
mov [rbx], rax
mov rax, [r14+10h]
mov [rbx+10h], rax
mov r12, [r14+8]
jmp short loc_7BC43
loc_7BC32:
mov r12, [r14+8]
lea rdx, [r12+1]
mov rsi, r15
call _memcpy
loc_7BC43:
mov [rbx+8], r12
mov [r14], r15
mov qword ptr [r14+8], 0
mov byte ptr [r14+10h], 0
jmp short loc_7BC6E
loc_7BC59:
mov eax, 0FFFFFFFFh
lock xadd [rdi+0Ch], eax
loc_7BC63:
cmp eax, 1
jnz short loc_7BC6E
mov rax, [rdi]
call qword ptr [rax+18h]
loc_7BC6E:
mov rax, rbx
add rsp, 58h
pop rbx
pop r12
pop r14
pop r15
retn
mov rbx, rax
lea rdi, [rsp+arg_0]; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
mov rdi, rbx
call __Unwind_Resume
|
_QWORD * minja::Value::get<std::string>(_QWORD *a1, minja::Value *a2, __m128d a3, long long a4, _QWORD *a5)
{
_QWORD *v7; // rax
long long v8; // rdi
signed __int32 v9; // eax
_QWORD *v10; // rdi
long long v11; // r12
__int128 v13; // [rsp+8h] [rbp-70h] BYREF
volatile signed __int32 *v14; // [rsp+20h] [rbp-58h] BYREF
volatile signed __int32 *v15; // [rsp+30h] [rbp-48h] BYREF
volatile signed __int32 *v16; // [rsp+40h] [rbp-38h] BYREF
char v17[48]; // [rsp+48h] [rbp-30h] BYREF
if ( minja::Value::contains((long long)a2, a3) )
{
minja::Value::Value(&v13);
v7 = (_QWORD *)minja::Value::at(a2, (const minja::Value *)&v13);
minja::Value::get<std::string>((long long)a1, v7);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant(v17);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v17);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(&v16);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(&v15);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(&v14);
v8 = *((_QWORD *)&v13 + 1);
if ( *((_QWORD *)&v13 + 1) )
{
if ( _libc_single_threaded )
{
v9 = *(_DWORD *)(*((_QWORD *)&v13 + 1) + 12LL);
*(_DWORD *)(*((_QWORD *)&v13 + 1) + 12LL) = v9 - 1;
}
else
{
v9 = _InterlockedExchangeAdd((volatile signed __int32 *)(*((_QWORD *)&v13 + 1) + 12LL), 0xFFFFFFFF);
}
if ( v9 == 1 )
(*(void ( **)(long long, _QWORD))(*(_QWORD *)v8 + 24LL))(v8, 0LL);
}
}
else
{
v10 = a1 + 2;
*a1 = a1 + 2;
if ( (_QWORD *)*a5 == a5 + 2 )
{
v11 = a5[1];
memcpy(v10, a5 + 2, v11 + 1);
}
else
{
*a1 = *a5;
a1[2] = a5[2];
v11 = a5[1];
}
a1[1] = v11;
*a5 = a5 + 2;
a5[1] = 0LL;
*((_BYTE *)a5 + 16) = 0;
}
return a1;
}
|
get<std::__cxx11::string>:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x58
MOV R14,RCX
MOV R12,RDX
MOV R15,RSI
MOV RBX,RDI
MOV RDI,RSI
MOV RSI,RDX
CALL 0x00178f6c
TEST AL,AL
JZ 0x0017bc0e
LEA R14,[RSP + 0x8]
MOV RDI,R14
MOV RSI,R12
CALL 0x001729ee
LAB_0017bba0:
MOV RDI,R15
MOV RSI,R14
CALL 0x001775c6
MOV RDI,RBX
MOV RSI,RAX
CALL 0x00175e92
LAB_0017bbb6:
LEA R14,[RSP + 0x48]
MOV RDI,R14
XOR ESI,ESI
CALL 0x001732fc
MOV RDI,R14
CALL 0x001300e0
LEA RDI,[RSP + 0x40]
CALL 0x00134564
LEA RDI,[RSP + 0x30]
CALL 0x00134564
LEA R14,[RSP + 0x20]
MOV RDI,R14
CALL 0x00134564
MOV RDI,qword ptr [R14 + -0x10]
TEST RDI,RDI
JZ 0x0017bc6e
MOV RAX,qword ptr [0x001fff90]
CMP byte ptr [RAX],0x0
JZ 0x0017bc59
MOV EAX,dword ptr [RDI + 0xc]
LEA ECX,[RAX + -0x1]
MOV dword ptr [RDI + 0xc],ECX
JMP 0x0017bc63
LAB_0017bc0e:
LEA RDI,[RBX + 0x10]
MOV qword ptr [RBX],RDI
MOV RAX,qword ptr [R14]
LEA R15,[R14 + 0x10]
CMP RAX,R15
JZ 0x0017bc32
MOV qword ptr [RBX],RAX
MOV RAX,qword ptr [R14 + 0x10]
MOV qword ptr [RBX + 0x10],RAX
MOV R12,qword ptr [R14 + 0x8]
JMP 0x0017bc43
LAB_0017bc32:
MOV R12,qword ptr [R14 + 0x8]
LEA RDX,[R12 + 0x1]
MOV RSI,R15
CALL 0x0011c0b0
LAB_0017bc43:
MOV qword ptr [RBX + 0x8],R12
MOV qword ptr [R14],R15
MOV qword ptr [R14 + 0x8],0x0
MOV byte ptr [R14 + 0x10],0x0
JMP 0x0017bc6e
LAB_0017bc59:
MOV EAX,0xffffffff
XADD.LOCK dword ptr [RDI + 0xc],EAX
LAB_0017bc63:
CMP EAX,0x1
JNZ 0x0017bc6e
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x18]
LAB_0017bc6e:
MOV RAX,RBX
ADD RSP,0x58
POP RBX
POP R12
POP R14
POP R15
RET
|
/* std::__cxx11::string minja::Value::get<std::__cxx11::string >(std::__cxx11::string const&,
std::__cxx11::string) const */
int8 *
minja::Value::get<std::__cxx11::string>
(int8 *param_1,Value *param_2,string *param_3,int8 *param_4)
{
int8 *__src;
int *piVar1;
char cVar2;
int iVar3;
long lVar4;
Value local_70 [8];
long *local_68;
__shared_count<(__gnu_cxx::_Lock_policy)2> local_58 [16];
__shared_count<(__gnu_cxx::_Lock_policy)2> local_48 [16];
__shared_count<(__gnu_cxx::_Lock_policy)2> local_38 [8];
data local_30 [16];
cVar2 = contains(param_2,param_3);
if (cVar2 == '\0') {
*param_1 = param_1 + 2;
__src = param_4 + 2;
if ((int8 *)*param_4 == __src) {
lVar4 = param_4[1];
memcpy(param_1 + 2,__src,lVar4 + 1);
}
else {
*param_1 = (void *)*param_4;
param_1[2] = param_4[2];
lVar4 = param_4[1];
}
param_1[1] = lVar4;
*param_4 = __src;
param_4[1] = 0;
*(int1 *)(param_4 + 2) = 0;
}
else {
Value(local_70,param_3);
/* try { // try from 0017bba0 to 0017bbb5 has its CatchHandler @ 0017bc7d */
at(param_2,local_70);
get<std::__cxx11::string>();
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(local_30,0));
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data(local_30);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(local_38);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(local_48);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(local_58);
if (local_68 != (long *)0x0) {
if (*PTR___libc_single_threaded_001fff90 == '\0') {
LOCK();
piVar1 = (int *)((long)local_68 + 0xc);
iVar3 = *piVar1;
*piVar1 = *piVar1 + -1;
UNLOCK();
}
else {
iVar3 = *(int *)((long)local_68 + 0xc);
*(int *)((long)local_68 + 0xc) = iVar3 + -1;
}
if (iVar3 == 1) {
(**(code **)(*local_68 + 0x18))();
}
}
}
return param_1;
}
|
|
7,845 |
wait_for_lock
|
eloqsql/mysys/thr_lock.c
|
static enum enum_thr_lock_result
wait_for_lock(struct st_lock_list *wait, THR_LOCK_DATA *data,
my_bool in_wait_list, ulong lock_wait_timeout)
{
struct st_my_thread_var *thread_var= my_thread_var;
mysql_cond_t *cond= &thread_var->suspend;
struct timespec wait_timeout;
enum enum_thr_lock_result result= THR_LOCK_ABORTED;
PSI_stage_info old_stage;
my_bool use_wait_callbacks= FALSE;
DBUG_ENTER("wait_for_lock");
/*
One can use this to signal when a thread is going to wait for a lock.
See debug_sync.cc.
Beware of waiting for a signal here. The lock has acquired its mutex.
While waiting on a signal here, the locking thread could not acquire
the mutex to release the lock. One could lock up the table
completely.
In detail it works so: When thr_lock() tries to acquire a table
lock, it locks the lock->mutex, checks if it can have the lock, and
if not, it calls wait_for_lock(). Here it unlocks the table lock
while waiting on a condition. The sync point is located before this
wait for condition. If we have a waiting action here, we hold the
the table locks mutex all the time. Any attempt to look at the table
lock by another thread blocks it immediately on lock->mutex. This
can easily become an unexpected and unobvious blockage. So be
warned: Do not request a WAIT_FOR action for the 'wait_for_lock'
sync point unless you really know what you do.
*/
DEBUG_SYNC_C("wait_for_lock");
if (!in_wait_list)
{
(*wait->last)=data; /* Wait for lock */
data->prev= wait->last;
wait->last= &data->next;
}
statistic_increment(locks_waited, &THR_LOCK_lock);
/* Set up control struct to allow others to abort locks */
thread_var->current_mutex= &data->lock->mutex;
thread_var->current_cond= cond;
data->cond= cond;
proc_info_hook(NULL, &stage_waiting_for_table_level_lock,
&old_stage,
__func__, __FILE__, __LINE__);
/*
Since before_lock_wait potentially can create more threads to
scheduler work for, we don't want to call the before_lock_wait
callback unless it will really start to wait.
For similar reasons, we do not want to call before_lock_wait and
after_lock_wait for each lap around the loop, so we restrict
ourselves to call it before_lock_wait once before starting to wait
and once after the thread has exited the wait loop.
*/
if ((!thread_var->abort || in_wait_list) && before_lock_wait)
{
use_wait_callbacks= TRUE;
(*before_lock_wait)();
}
set_timespec(wait_timeout, lock_wait_timeout);
while (!thread_var->abort || in_wait_list)
{
int rc= mysql_cond_timedwait(cond, &data->lock->mutex, &wait_timeout);
/*
We must break the wait if one of the following occurs:
- the connection has been aborted (!thread_var->abort), but
this is not a delayed insert thread (in_wait_list). For a delayed
insert thread the proper action at shutdown is, apparently, to
acquire the lock and complete the insert.
- the lock has been granted (data->cond is set to NULL by the granter),
or the waiting has been aborted (additionally data->type is set to
TL_UNLOCK).
- the wait has timed out (rc == ETIMEDOUT)
Order of checks below is important to not report about timeout
if the predicate is true.
*/
if (data->cond == 0)
{
DBUG_PRINT("thr_lock", ("lock granted/aborted"));
break;
}
if (rc == ETIMEDOUT || rc == ETIME)
{
/* purecov: begin inspected */
DBUG_PRINT("thr_lock", ("lock timed out"));
result= THR_LOCK_WAIT_TIMEOUT;
break;
/* purecov: end */
}
}
/*
We call the after_lock_wait callback once the wait loop has
finished.
*/
if (after_lock_wait && use_wait_callbacks)
(*after_lock_wait)();
DBUG_PRINT("thr_lock", ("aborted: %d in_wait_list: %d",
thread_var->abort, in_wait_list));
if (data->cond || data->type == TL_UNLOCK)
{
if (data->cond) /* aborted or timed out */
{
if (((*data->prev)=data->next)) /* remove from wait-list */
data->next->prev= data->prev;
else
wait->last=data->prev;
data->type= TL_UNLOCK; /* No lock */
check_locks(data->lock, "killed or timed out wait_for_lock", data->type,
1);
wake_up_waiters(data->lock);
}
else
{
DBUG_PRINT("thr_lock", ("lock aborted"));
check_locks(data->lock, "aborted wait_for_lock", data->type, 0);
}
}
else
{
result= THR_LOCK_SUCCESS;
if (data->lock->get_status &&
(*data->lock->get_status)(data->status_param,
data->type == TL_WRITE_CONCURRENT_INSERT))
result= THR_LOCK_ABORTED;
check_locks(data->lock,"got wait_for_lock", data->type, 0);
}
mysql_mutex_unlock(&data->lock->mutex);
/* The following must be done after unlock of lock->mutex */
mysql_mutex_lock(&thread_var->mutex);
thread_var->current_mutex= 0;
thread_var->current_cond= 0;
mysql_mutex_unlock(&thread_var->mutex);
proc_info_hook(NULL, &old_stage, NULL, __func__, __FILE__, __LINE__);
DBUG_RETURN(result);
}
|
O3
|
c
|
wait_for_lock:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rcx, %r15
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, -0x38(%rbp)
callq 0xa2f62
movq %rax, %r13
movq %rax, -0x40(%rbp)
leaq 0x8(%rax), %r12
testb %bl, %bl
jne 0xa4e45
movq -0x38(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %r14, (%rax)
movq 0x8(%rcx), %rax
movq %rax, 0x10(%r14)
leaq 0x8(%r14), %rax
movq %rax, 0x8(%rcx)
leaq 0xb65704(%rip), %rax # 0xc0a550
incq (%rax)
movq 0x18(%r14), %rax
addq $0x18, %rax
movq %rax, 0x98(%r13)
movq %r12, 0xa0(%r13)
movq %r12, 0x20(%r14)
leaq 0x2e2ce0(%rip), %rax # 0x387b50
leaq 0x2e2961(%rip), %rsi # 0x3877d8
leaq 0x37002(%rip), %rcx # 0xdbe80
leaq 0x38f44(%rip), %r8 # 0xdddc9
leaq -0x68(%rbp), %rdx
xorl %edi, %edi
movl $0x219, %r9d # imm = 0x219
callq *(%rax)
cmpl $0x0, 0xe0(%r13)
sete %al
testb %bl, %bl
setne %cl
orb %al, %cl
movq 0xb656ac(%rip), %rax # 0xc0a558
testq %rax, %rax
setne %dl
andb %cl, %dl
movb %dl, -0x29(%rbp)
cmpb $0x1, %dl
jne 0xa4ebe
callq *%rax
callq 0x9f9c8
imulq $0x3e8, %rax, %rax # imm = 0x3E8
imulq $0x3b9aca00, %r15, %rcx # imm = 0x3B9ACA00
addq %rax, %rcx
movq %rcx, %rax
shrq $0x9, %rax
movabsq $0x44b82fa09b5a53, %rdx # imm = 0x44B82FA09B5A53
mulq %rdx
shrq $0xb, %rdx
leaq -0x50(%rbp), %rsi
movq %rdx, (%rsi)
imulq $0x3b9aca00, %rdx, %rax # imm = 0x3B9ACA00
subq %rax, %rcx
movq %rcx, 0x8(%rsi)
movl 0xe0(%r13), %eax
movl $0x1, %r15d
testb %bl, %bl
jne 0xa4f16
testl %eax, %eax
jne 0xa4f65
movq 0x18(%r14), %rsi
addq $0x18, %rsi
cmpq $0x0, 0x38(%r13)
jne 0xa4f4a
movq %r12, %rdi
leaq -0x50(%rbp), %rdx
callq 0x29660
cmpq $0x0, 0x20(%r14)
je 0xa4f65
movl $0x2, %r15d
cmpl $0x6e, %eax
je 0xa4f65
cmpl $0x3e, %eax
jne 0xa4f01
jmp 0xa4f65
movq %r12, %rdi
leaq -0x50(%rbp), %rdx
leaq 0x38e71(%rip), %rcx # 0xdddc9
movl $0x22e, %r8d # imm = 0x22E
callq 0x2ef00
jmp 0xa4f31
movq 0xb655f4(%rip), %rax # 0xc0a560
testq %rax, %rax
sete %cl
movb -0x29(%rbp), %dl
xorb $0x1, %dl
orb %cl, %dl
jne 0xa4f7e
callq *%rax
cmpq $0x0, 0x20(%r14)
je 0xa5059
movq 0x8(%r14), %rax
movq 0x10(%r14), %rcx
movq %rax, (%rcx)
movq -0x38(%rbp), %rdx
addq $0x8, %rdx
leaq 0x10(%rax), %rcx
testq %rax, %rax
cmoveq %rdx, %rcx
movq 0x10(%r14), %rax
movq %rax, (%rcx)
movl $0x0, 0x40(%r14)
movq 0x18(%r14), %rdi
callq 0xa3c91
movq 0x18(%r14), %rbx
movq 0x58(%rbx), %rdi
addq $0x18, %rbx
testq %rdi, %rdi
jne 0xa509a
movq %rbx, %rdi
callq 0x291c0
movq -0x40(%rbp), %rbx
addq $0x40, %rbx
cmpq $0x0, 0x80(%r13)
jne 0xa50af
movq %rbx, %rdi
callq 0x29200
xorl %eax, %eax
movq %rax, 0x98(%r13)
movq %rax, 0xa0(%r13)
movq 0x80(%r13), %rdi
testq %rdi, %rdi
jne 0xa50c8
movq %rbx, %rdi
callq 0x291c0
leaq 0x36e57(%rip), %rcx # 0xdbe80
leaq 0x38d99(%rip), %r8 # 0xdddc9
leaq -0x68(%rbp), %rsi
xorl %edi, %edi
xorl %edx, %edx
movl $0x279, %r9d # imm = 0x279
leaq 0x2e2b0b(%rip), %rax # 0x387b50
callq *(%rax)
movl %r15d, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl 0x40(%r14), %eax
testl %eax, %eax
je 0xa4fbf
movq 0x18(%r14), %rcx
movq 0xb0(%rcx), %rcx
testq %rcx, %rcx
je 0xa5092
movq 0x28(%r14), %rdi
xorl %esi, %esi
cmpl $0x8, %eax
sete %sil
callq *%rcx
xorl %r15d, %r15d
testb %al, %al
setne %r15b
jmp 0xa4fbf
xorl %r15d, %r15d
jmp 0xa4fbf
leaq 0x2e2f6f(%rip), %rax # 0x388010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0xa4fd4
leaq 0x38d13(%rip), %rsi # 0xdddc9
movq %rbx, %rdi
movl $0x274, %edx # imm = 0x274
callq 0x2eb7f
jmp 0xa4ffa
leaq 0x2e2f41(%rip), %rax # 0x388010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0xa501a
|
wait_for_lock:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov r15, rcx
mov ebx, edx
mov r14, rsi
mov [rbp+var_38], rdi
call _my_thread_var
mov r13, rax
mov [rbp+var_40], rax
lea r12, [rax+8]
test bl, bl
jnz short loc_A4E45
mov rcx, [rbp+var_38]
mov rax, [rcx+8]
mov [rax], r14
mov rax, [rcx+8]
mov [r14+10h], rax
lea rax, [r14+8]
mov [rcx+8], rax
loc_A4E45:
lea rax, locks_waited
inc qword ptr [rax]
mov rax, [r14+18h]
add rax, 18h
mov [r13+98h], rax
mov [r13+0A0h], r12
mov [r14+20h], r12
lea rax, proc_info_hook
lea rsi, stage_waiting_for_table_level_lock
lea rcx, aUnknown; "<unknown>"
lea r8, aWorkspaceLlm4b_23; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, [rbp+var_68]
xor edi, edi
mov r9d, 219h
call qword ptr [rax]
cmp dword ptr [r13+0E0h], 0
setz al
test bl, bl
setnz cl
or cl, al
mov rax, cs:before_lock_wait
test rax, rax
setnz dl
and dl, cl
mov [rbp+var_29], dl
cmp dl, 1
jnz short loc_A4EBE
call rax ; before_lock_wait
loc_A4EBE:
call my_hrtime
imul rax, 3E8h
imul rcx, r15, 3B9ACA00h
add rcx, rax
mov rax, rcx
shr rax, 9
mov rdx, 44B82FA09B5A53h
mul rdx
shr rdx, 0Bh
lea rsi, [rbp+var_50]
mov [rsi], rdx
imul rax, rdx, 3B9ACA00h
sub rcx, rax
mov [rsi+8], rcx
loc_A4F01:
mov eax, [r13+0E0h]
mov r15d, 1
test bl, bl
jnz short loc_A4F16
test eax, eax
jnz short loc_A4F65
loc_A4F16:
mov rsi, [r14+18h]
add rsi, 18h
cmp qword ptr [r13+38h], 0
jnz short loc_A4F4A
mov rdi, r12
lea rdx, [rbp+var_50]
call _pthread_cond_timedwait
loc_A4F31:
cmp qword ptr [r14+20h], 0
jz short loc_A4F65
mov r15d, 2
cmp eax, 6Eh ; 'n'
jz short loc_A4F65
cmp eax, 3Eh ; '>'
jnz short loc_A4F01
jmp short loc_A4F65
loc_A4F4A:
mov rdi, r12
lea rdx, [rbp+var_50]
lea rcx, aWorkspaceLlm4b_23; "/workspace/llm4binary/github2025/eloqsq"...
mov r8d, 22Eh
call psi_cond_timedwait
jmp short loc_A4F31
loc_A4F65:
mov rax, cs:after_lock_wait
test rax, rax
setz cl
mov dl, [rbp+var_29]
xor dl, 1
or dl, cl
jnz short loc_A4F7E
call rax ; after_lock_wait
loc_A4F7E:
cmp qword ptr [r14+20h], 0
jz loc_A5059
mov rax, [r14+8]
mov rcx, [r14+10h]
mov [rcx], rax
mov rdx, [rbp+var_38]
add rdx, 8
lea rcx, [rax+10h]
test rax, rax
cmovz rcx, rdx
mov rax, [r14+10h]
mov [rcx], rax
mov dword ptr [r14+40h], 0
mov rdi, [r14+18h]
call wake_up_waiters
loc_A4FBF:
mov rbx, [r14+18h]
mov rdi, [rbx+58h]
add rbx, 18h
test rdi, rdi
jnz loc_A509A
loc_A4FD4:
mov rdi, rbx
call _pthread_mutex_unlock
mov rbx, [rbp+var_40]
add rbx, 40h ; '@'
cmp qword ptr [r13+80h], 0
jnz loc_A50AF
mov rdi, rbx
call _pthread_mutex_lock
loc_A4FFA:
xor eax, eax
mov [r13+98h], rax
mov [r13+0A0h], rax
mov rdi, [r13+80h]
test rdi, rdi
jnz loc_A50C8
loc_A501A:
mov rdi, rbx
call _pthread_mutex_unlock
lea rcx, aUnknown; "<unknown>"
lea r8, aWorkspaceLlm4b_23; "/workspace/llm4binary/github2025/eloqsq"...
lea rsi, [rbp+var_68]
xor edi, edi
xor edx, edx
mov r9d, 279h
lea rax, proc_info_hook
call qword ptr [rax]
mov eax, r15d
add rsp, 48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_A5059:
mov eax, [r14+40h]
test eax, eax
jz loc_A4FBF
mov rcx, [r14+18h]
mov rcx, [rcx+0B0h]
test rcx, rcx
jz short loc_A5092
mov rdi, [r14+28h]
xor esi, esi
cmp eax, 8
setz sil
call rcx
xor r15d, r15d
test al, al
setnz r15b
jmp loc_A4FBF
loc_A5092:
xor r15d, r15d
jmp loc_A4FBF
loc_A509A:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp loc_A4FD4
loc_A50AF:
lea rsi, aWorkspaceLlm4b_23; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, rbx
mov edx, 274h
call psi_mutex_lock
jmp loc_A4FFA
loc_A50C8:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp loc_A501A
|
long long wait_for_lock(long long a1, long long a2, char a3, long long a4)
{
long long v7; // r13
long long v8; // r12
long long v9; // rcx
long long v10; // rdi
unsigned long long v11; // rcx
unsigned int v12; // r15d
long long v13; // rsi
int v14; // eax
long long v15; // rax
_QWORD *v16; // rcx
long long v17; // rbx
long long v18; // rdi
long long v19; // rbx
long long v20; // rbx
int v22; // eax
unsigned __int8 ( *v23)(_QWORD, bool); // rcx
_QWORD v24[2]; // [rsp+20h] [rbp-50h] BYREF
long long v25; // [rsp+30h] [rbp-40h]
long long v26; // [rsp+38h] [rbp-38h]
bool v27; // [rsp+47h] [rbp-29h]
v26 = a1;
v7 = my_thread_var();
v25 = v7;
v8 = v7 + 8;
if ( !a3 )
{
v9 = v26;
**(_QWORD **)(v26 + 8) = a2;
*(_QWORD *)(a2 + 16) = *(_QWORD *)(v9 + 8);
*(_QWORD *)(v9 + 8) = a2 + 8;
}
++locks_waited;
*(_QWORD *)(v7 + 152) = *(_QWORD *)(a2 + 24) + 24LL;
*(_QWORD *)(v7 + 160) = v8;
*(_QWORD *)(a2 + 32) = v8;
v10 = 0LL;
proc_info_hook();
v27 = (*(_DWORD *)(v7 + 224) == 0 || a3 != 0) && before_lock_wait != 0;
if ( v27 )
((void ( *)(_QWORD, void *))before_lock_wait)(0LL, &stage_waiting_for_table_level_lock);
v11 = 1000 * my_hrtime() + 1000000000 * a4;
v24[0] = v11 / 0x3B9ACA00;
v24[1] = v11 % 0x3B9ACA00;
do
{
v12 = 1;
if ( !a3 && *(_DWORD *)(v7 + 224) )
break;
v13 = *(_QWORD *)(a2 + 24) + 24LL;
v10 = v7 + 8;
v14 = *(_QWORD *)(v7 + 56)
? psi_cond_timedwait(
v8,
v13,
(long long)v24,
(long long)"/workspace/llm4binary/github2025/eloqsql/mysys/thr_lock.c",
0x22Eu)
: pthread_cond_timedwait(v8, v13, v24);
if ( !*(_QWORD *)(a2 + 32) )
break;
v12 = 2;
if ( v14 == 110 )
break;
}
while ( v14 != 62 );
if ( after_lock_wait != 0 && v27 )
((void ( *)(long long))after_lock_wait)(v10);
if ( *(_QWORD *)(a2 + 32) )
{
v15 = *(_QWORD *)(a2 + 8);
**(_QWORD **)(a2 + 16) = v15;
v16 = (_QWORD *)(v15 + 16);
if ( !v15 )
v16 = (_QWORD *)(v26 + 8);
*v16 = *(_QWORD *)(a2 + 16);
*(_DWORD *)(a2 + 64) = 0;
wake_up_waiters(*(_QWORD *)(a2 + 24));
}
else
{
v22 = *(_DWORD *)(a2 + 64);
if ( v22 )
{
v23 = *(unsigned __int8 ( **)(_QWORD, bool))(*(_QWORD *)(a2 + 24) + 176LL);
if ( v23 )
v12 = v23(*(_QWORD *)(a2 + 40), v22 == 8) != 0;
else
v12 = 0;
}
}
v17 = *(_QWORD *)(a2 + 24);
v18 = *(_QWORD *)(v17 + 88);
v19 = v17 + 24;
if ( v18 )
PSI_server[44]();
pthread_mutex_unlock(v19);
v20 = v25 + 64;
if ( *(_QWORD *)(v7 + 128) )
psi_mutex_lock(v25 + 64, (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/thr_lock.c", 0x274u);
else
pthread_mutex_lock(v25 + 64);
*(_QWORD *)(v7 + 152) = 0LL;
*(_QWORD *)(v7 + 160) = 0LL;
if ( *(_QWORD *)(v7 + 128) )
PSI_server[44]();
pthread_mutex_unlock(v20);
proc_info_hook();
return v12;
}
|
wait_for_lock:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV R15,RCX
MOV EBX,EDX
MOV R14,RSI
MOV qword ptr [RBP + -0x38],RDI
CALL 0x001a2f62
MOV R13,RAX
MOV qword ptr [RBP + -0x40],RAX
LEA R12,[RAX + 0x8]
TEST BL,BL
JNZ 0x001a4e45
MOV RCX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RCX + 0x8]
MOV qword ptr [RAX],R14
MOV RAX,qword ptr [RCX + 0x8]
MOV qword ptr [R14 + 0x10],RAX
LEA RAX,[R14 + 0x8]
MOV qword ptr [RCX + 0x8],RAX
LAB_001a4e45:
LEA RAX,[0xd0a550]
INC qword ptr [RAX]
MOV RAX,qword ptr [R14 + 0x18]
ADD RAX,0x18
MOV qword ptr [R13 + 0x98],RAX
MOV qword ptr [R13 + 0xa0],R12
MOV qword ptr [R14 + 0x20],R12
LEA RAX,[0x487b50]
LEA RSI,[0x4877d8]
LEA RCX,[0x1dbe80]
LEA R8,[0x1dddc9]
LEA RDX,[RBP + -0x68]
XOR EDI,EDI
MOV R9D,0x219
CALL qword ptr [RAX]
CMP dword ptr [R13 + 0xe0],0x0
SETZ AL
TEST BL,BL
SETNZ CL
OR CL,AL
MOV RAX,qword ptr [0x00d0a558]
TEST RAX,RAX
SETNZ DL
AND DL,CL
MOV byte ptr [RBP + -0x29],DL
CMP DL,0x1
JNZ 0x001a4ebe
CALL RAX
LAB_001a4ebe:
CALL 0x0019f9c8
IMUL RAX,RAX,0x3e8
IMUL RCX,R15,0x3b9aca00
ADD RCX,RAX
MOV RAX,RCX
SHR RAX,0x9
MOV RDX,0x44b82fa09b5a53
MUL RDX
SHR RDX,0xb
LEA RSI,[RBP + -0x50]
MOV qword ptr [RSI],RDX
IMUL RAX,RDX,0x3b9aca00
SUB RCX,RAX
MOV qword ptr [RSI + 0x8],RCX
LAB_001a4f01:
MOV EAX,dword ptr [R13 + 0xe0]
MOV R15D,0x1
TEST BL,BL
JNZ 0x001a4f16
TEST EAX,EAX
JNZ 0x001a4f65
LAB_001a4f16:
MOV RSI,qword ptr [R14 + 0x18]
ADD RSI,0x18
CMP qword ptr [R13 + 0x38],0x0
JNZ 0x001a4f4a
MOV RDI,R12
LEA RDX,[RBP + -0x50]
CALL 0x00129660
LAB_001a4f31:
CMP qword ptr [R14 + 0x20],0x0
JZ 0x001a4f65
MOV R15D,0x2
CMP EAX,0x6e
JZ 0x001a4f65
CMP EAX,0x3e
JNZ 0x001a4f01
JMP 0x001a4f65
LAB_001a4f4a:
MOV RDI,R12
LEA RDX,[RBP + -0x50]
LEA RCX,[0x1dddc9]
MOV R8D,0x22e
CALL 0x0012ef00
JMP 0x001a4f31
LAB_001a4f65:
MOV RAX,qword ptr [0x00d0a560]
TEST RAX,RAX
SETZ CL
MOV DL,byte ptr [RBP + -0x29]
XOR DL,0x1
OR DL,CL
JNZ 0x001a4f7e
CALL RAX
LAB_001a4f7e:
CMP qword ptr [R14 + 0x20],0x0
JZ 0x001a5059
MOV RAX,qword ptr [R14 + 0x8]
MOV RCX,qword ptr [R14 + 0x10]
MOV qword ptr [RCX],RAX
MOV RDX,qword ptr [RBP + -0x38]
ADD RDX,0x8
LEA RCX,[RAX + 0x10]
TEST RAX,RAX
CMOVZ RCX,RDX
MOV RAX,qword ptr [R14 + 0x10]
MOV qword ptr [RCX],RAX
MOV dword ptr [R14 + 0x40],0x0
MOV RDI,qword ptr [R14 + 0x18]
CALL 0x001a3c91
LAB_001a4fbf:
MOV RBX,qword ptr [R14 + 0x18]
MOV RDI,qword ptr [RBX + 0x58]
ADD RBX,0x18
TEST RDI,RDI
JNZ 0x001a509a
LAB_001a4fd4:
MOV RDI,RBX
CALL 0x001291c0
MOV RBX,qword ptr [RBP + -0x40]
ADD RBX,0x40
CMP qword ptr [R13 + 0x80],0x0
JNZ 0x001a50af
MOV RDI,RBX
CALL 0x00129200
LAB_001a4ffa:
XOR EAX,EAX
MOV qword ptr [R13 + 0x98],RAX
MOV qword ptr [R13 + 0xa0],RAX
MOV RDI,qword ptr [R13 + 0x80]
TEST RDI,RDI
JNZ 0x001a50c8
LAB_001a501a:
MOV RDI,RBX
CALL 0x001291c0
LEA RCX,[0x1dbe80]
LEA R8,[0x1dddc9]
LEA RSI,[RBP + -0x68]
XOR EDI,EDI
XOR EDX,EDX
MOV R9D,0x279
LEA RAX,[0x487b50]
CALL qword ptr [RAX]
MOV EAX,R15D
ADD RSP,0x48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001a5059:
MOV EAX,dword ptr [R14 + 0x40]
TEST EAX,EAX
JZ 0x001a4fbf
MOV RCX,qword ptr [R14 + 0x18]
MOV RCX,qword ptr [RCX + 0xb0]
TEST RCX,RCX
JZ 0x001a5092
MOV RDI,qword ptr [R14 + 0x28]
XOR ESI,ESI
CMP EAX,0x8
SETZ SIL
CALL RCX
XOR R15D,R15D
TEST AL,AL
SETNZ R15B
JMP 0x001a4fbf
LAB_001a5092:
XOR R15D,R15D
JMP 0x001a4fbf
LAB_001a509a:
LEA RAX,[0x488010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x001a4fd4
LAB_001a50af:
LEA RSI,[0x1dddc9]
MOV RDI,RBX
MOV EDX,0x274
CALL 0x0012eb7f
JMP 0x001a4ffa
LAB_001a50c8:
LEA RAX,[0x488010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x001a501a
|
int1 wait_for_lock(long param_1,long param_2,char param_3,long param_4)
{
pthread_cond_t *__cond;
code *pcVar1;
char cVar2;
int iVar3;
long lVar4;
long lVar5;
int8 *puVar6;
pthread_mutex_t *ppVar7;
bool bVar8;
int1 uVar9;
int1 local_70 [24];
timespec local_58;
long local_48;
long local_40;
char local_31;
local_40 = param_1;
lVar4 = _my_thread_var();
__cond = (pthread_cond_t *)(lVar4 + 8);
if (param_3 == '\0') {
**(long **)(local_40 + 8) = param_2;
*(int8 *)(param_2 + 0x10) = *(int8 *)(local_40 + 8);
*(long *)(local_40 + 8) = param_2 + 8;
}
locks_waited = locks_waited + 1;
*(long *)(lVar4 + 0x98) = *(long *)(param_2 + 0x18) + 0x18;
*(pthread_cond_t **)(lVar4 + 0xa0) = __cond;
*(pthread_cond_t **)(param_2 + 0x20) = __cond;
local_48 = lVar4;
(*(code *)proc_info_hook)
(0,stage_waiting_for_table_level_lock,local_70,"<unknown>",
"/workspace/llm4binary/github2025/eloqsql/mysys/thr_lock.c",0x219);
bVar8 = *(int *)(lVar4 + 0xe0) == 0;
local_31 = before_lock_wait != (code *)0x0 && (param_3 != '\0' || bVar8);
if (before_lock_wait != (code *)0x0 && (param_3 != '\0' || bVar8)) {
(*before_lock_wait)();
}
lVar5 = my_hrtime();
local_58.tv_nsec = param_4 * 1000000000 + lVar5 * 1000;
local_58.tv_sec = (ulong)local_58.tv_nsec / 1000000000;
local_58.tv_nsec = (ulong)local_58.tv_nsec % 1000000000;
while( true ) {
uVar9 = 1;
if ((param_3 == '\0') && (*(int *)(lVar4 + 0xe0) != 0)) break;
ppVar7 = (pthread_mutex_t *)(*(long *)(param_2 + 0x18) + 0x18);
if (*(long *)(lVar4 + 0x38) == 0) {
iVar3 = pthread_cond_timedwait(__cond,ppVar7,&local_58);
}
else {
iVar3 = psi_cond_timedwait(__cond,ppVar7,&local_58,
"/workspace/llm4binary/github2025/eloqsql/mysys/thr_lock.c",0x22e);
}
if (((*(long *)(param_2 + 0x20) == 0) || (uVar9 = 2, iVar3 == 0x6e)) || (iVar3 == 0x3e)) break;
}
if (local_31 == '\x01' && after_lock_wait != (code *)0x0) {
(*after_lock_wait)();
}
if (*(long *)(param_2 + 0x20) == 0) {
if (*(int *)(param_2 + 0x40) != 0) {
pcVar1 = *(code **)(*(long *)(param_2 + 0x18) + 0xb0);
if (pcVar1 == (code *)0x0) {
uVar9 = 0;
}
else {
cVar2 = (*pcVar1)(*(int8 *)(param_2 + 0x28),*(int *)(param_2 + 0x40) == 8);
uVar9 = cVar2 != '\0';
}
}
}
else {
lVar5 = *(long *)(param_2 + 8);
**(long **)(param_2 + 0x10) = lVar5;
puVar6 = (int8 *)(lVar5 + 0x10);
if (lVar5 == 0) {
puVar6 = (int8 *)(local_40 + 8);
}
*puVar6 = *(int8 *)(param_2 + 0x10);
*(int4 *)(param_2 + 0x40) = 0;
wake_up_waiters(*(int8 *)(param_2 + 0x18));
}
lVar5 = *(long *)(param_2 + 0x18);
if (*(long *)(lVar5 + 0x58) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock((pthread_mutex_t *)(lVar5 + 0x18));
ppVar7 = (pthread_mutex_t *)(local_48 + 0x40);
if (*(long *)(lVar4 + 0x80) == 0) {
pthread_mutex_lock(ppVar7);
}
else {
psi_mutex_lock(ppVar7,"/workspace/llm4binary/github2025/eloqsql/mysys/thr_lock.c",0x274);
}
*(int8 *)(lVar4 + 0x98) = 0;
*(int8 *)(lVar4 + 0xa0) = 0;
if (*(long *)(lVar4 + 0x80) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(ppVar7);
(*(code *)proc_info_hook)
(0,local_70,0,"<unknown>","/workspace/llm4binary/github2025/eloqsql/mysys/thr_lock.c",
0x279);
return uVar9;
}
|
|
7,846 |
my_scan_8bit
|
eloqsql/strings/ctype-simple.c
|
size_t my_scan_8bit(CHARSET_INFO *cs, const char *str, const char *end, int sq)
{
const char *str0= str;
switch (sq)
{
case MY_SEQ_INTTAIL:
if (*str == '.')
{
for(str++ ; str != end && *str == '0' ; str++);
return (size_t) (str - str0);
}
return 0;
case MY_SEQ_SPACES:
for ( ; str < end ; str++)
{
if (!my_isspace(cs,*str))
break;
}
return (size_t) (str - str0);
case MY_SEQ_NONSPACES:
for ( ; str < end ; str++)
{
if (my_isspace(cs, *str))
break;
}
return (size_t) (str - str0);
default:
return 0;
}
}
|
O3
|
c
|
my_scan_8bit:
pushq %rbp
movq %rsp, %rbp
movq %rdx, %rax
cmpl $0x1, %ecx
je 0x715b2
cmpl $0x2, %ecx
je 0x71586
cmpl $0x3, %ecx
jne 0x715d7
movq %rsi, %rcx
cmpq %rax, %rsi
jae 0x715aa
movq 0x40(%rdi), %rdx
movq %rsi, %rcx
movzbl (%rcx), %edi
testb $0x8, 0x1(%rdx,%rdi)
jne 0x715aa
incq %rcx
cmpq %rax, %rcx
jne 0x71572
jmp 0x715a7
movq %rsi, %rcx
cmpq %rax, %rsi
jae 0x715aa
movq 0x40(%rdi), %rdx
movq %rsi, %rcx
movzbl (%rcx), %edi
testb $0x8, 0x1(%rdx,%rdi)
je 0x715aa
incq %rcx
cmpq %rax, %rcx
jne 0x71595
movq %rax, %rcx
subq %rsi, %rcx
movq %rcx, %rax
jmp 0x715d9
cmpb $0x2e, (%rsi)
jne 0x715d7
leaq 0x1(%rsi), %rcx
cmpq %rax, %rcx
je 0x715d2
leaq 0x1(%rcx), %rdx
cmpb $0x30, (%rcx)
movq %rdx, %rcx
je 0x715bb
decq %rdx
movq %rdx, %rax
subq %rsi, %rax
jmp 0x715d9
xorl %eax, %eax
popq %rbp
retq
|
my_scan_8bit:
push rbp
mov rbp, rsp
mov rax, rdx
cmp ecx, 1
jz short loc_715B2
cmp ecx, 2
jz short loc_71586
cmp ecx, 3
jnz short loc_715D7
mov rcx, rsi
cmp rsi, rax
jnb short loc_715AA
mov rdx, [rdi+40h]
mov rcx, rsi
loc_71572:
movzx edi, byte ptr [rcx]
test byte ptr [rdx+rdi+1], 8
jnz short loc_715AA
inc rcx
cmp rcx, rax
jnz short loc_71572
jmp short loc_715A7
loc_71586:
mov rcx, rsi
cmp rsi, rax
jnb short loc_715AA
mov rdx, [rdi+40h]
mov rcx, rsi
loc_71595:
movzx edi, byte ptr [rcx]
test byte ptr [rdx+rdi+1], 8
jz short loc_715AA
inc rcx
cmp rcx, rax
jnz short loc_71595
loc_715A7:
mov rcx, rax
loc_715AA:
sub rcx, rsi
mov rax, rcx
jmp short loc_715D9
loc_715B2:
cmp byte ptr [rsi], 2Eh ; '.'
jnz short loc_715D7
lea rcx, [rsi+1]
loc_715BB:
cmp rcx, rax
jz short loc_715D2
lea rdx, [rcx+1]
cmp byte ptr [rcx], 30h ; '0'
mov rcx, rdx
jz short loc_715BB
dec rdx
mov rax, rdx
loc_715D2:
sub rax, rsi
jmp short loc_715D9
loc_715D7:
xor eax, eax
loc_715D9:
pop rbp
retn
|
long long my_scan_8bit(long long a1, unsigned __int8 *a2, unsigned __int8 *a3, int a4)
{
unsigned __int8 *v4; // rax
unsigned __int8 *v5; // rcx
unsigned __int8 *v7; // rcx
_BYTE *v8; // rdx
v4 = a3;
if ( a4 != 1 )
{
if ( a4 == 2 )
{
v5 = a2;
if ( a2 < a3 )
{
v5 = a2;
while ( (*(_BYTE *)(*(_QWORD *)(a1 + 64) + *v5 + 1LL) & 8) != 0 )
{
if ( ++v5 == a3 )
{
LABEL_13:
v5 = a3;
return v5 - a2;
}
}
}
return v5 - a2;
}
if ( a4 == 3 )
{
v5 = a2;
if ( a2 < a3 )
{
v5 = a2;
while ( (*(_BYTE *)(*(_QWORD *)(a1 + 64) + *v5 + 1LL) & 8) == 0 )
{
if ( ++v5 == a3 )
goto LABEL_13;
}
}
return v5 - a2;
}
return 0LL;
}
if ( *a2 != 46 )
return 0LL;
v7 = a2 + 1;
while ( v7 != v4 )
{
v8 = v7 + 1;
if ( *v7++ != 48 )
{
v4 = v8 - 1;
return v4 - a2;
}
}
return v4 - a2;
}
|
my_scan_8bit:
PUSH RBP
MOV RBP,RSP
MOV RAX,RDX
CMP ECX,0x1
JZ 0x001715b2
CMP ECX,0x2
JZ 0x00171586
CMP ECX,0x3
JNZ 0x001715d7
MOV RCX,RSI
CMP RSI,RAX
JNC 0x001715aa
MOV RDX,qword ptr [RDI + 0x40]
MOV RCX,RSI
LAB_00171572:
MOVZX EDI,byte ptr [RCX]
TEST byte ptr [RDX + RDI*0x1 + 0x1],0x8
JNZ 0x001715aa
INC RCX
CMP RCX,RAX
JNZ 0x00171572
JMP 0x001715a7
LAB_00171586:
MOV RCX,RSI
CMP RSI,RAX
JNC 0x001715aa
MOV RDX,qword ptr [RDI + 0x40]
MOV RCX,RSI
LAB_00171595:
MOVZX EDI,byte ptr [RCX]
TEST byte ptr [RDX + RDI*0x1 + 0x1],0x8
JZ 0x001715aa
INC RCX
CMP RCX,RAX
JNZ 0x00171595
LAB_001715a7:
MOV RCX,RAX
LAB_001715aa:
SUB RCX,RSI
MOV RAX,RCX
JMP 0x001715d9
LAB_001715b2:
CMP byte ptr [RSI],0x2e
JNZ 0x001715d7
LEA RCX,[RSI + 0x1]
LAB_001715bb:
CMP RCX,RAX
JZ 0x001715d2
LEA RDX,[RCX + 0x1]
CMP byte ptr [RCX],0x30
MOV RCX,RDX
JZ 0x001715bb
DEC RDX
MOV RAX,RDX
LAB_001715d2:
SUB RAX,RSI
JMP 0x001715d9
LAB_001715d7:
XOR EAX,EAX
LAB_001715d9:
POP RBP
RET
|
long my_scan_8bit(long param_1,byte *param_2,byte *param_3,int param_4)
{
byte bVar1;
byte *pbVar2;
long lVar3;
byte *pbVar4;
if (param_4 == 1) {
if (*param_2 == 0x2e) {
pbVar4 = param_2 + 1;
do {
pbVar2 = param_3;
if (pbVar4 == param_3) break;
bVar1 = *pbVar4;
pbVar2 = pbVar4;
pbVar4 = pbVar4 + 1;
} while (bVar1 == 0x30);
return (long)pbVar2 - (long)param_2;
}
LAB_001715d7:
lVar3 = 0;
}
else {
pbVar4 = param_2;
if (param_4 == 2) {
if (param_2 < param_3) {
pbVar2 = param_2;
do {
pbVar4 = pbVar2;
if ((*(byte *)(*(long *)(param_1 + 0x40) + 1 + (ulong)*pbVar2) & 8) == 0) break;
pbVar2 = pbVar2 + 1;
pbVar4 = param_3;
} while (pbVar2 != param_3);
}
}
else {
if (param_4 != 3) goto LAB_001715d7;
if (param_2 < param_3) {
pbVar2 = param_2;
do {
pbVar4 = pbVar2;
if ((*(byte *)(*(long *)(param_1 + 0x40) + 1 + (ulong)*pbVar2) & 8) != 0) break;
pbVar2 = pbVar2 + 1;
pbVar4 = param_3;
} while (pbVar2 != param_3);
}
}
lVar3 = (long)pbVar4 - (long)param_2;
}
return lVar3;
}
|
|
7,847 |
my_b_safe_write
|
eloqsql/mysys/mf_iocache.c
|
int my_b_safe_write(IO_CACHE *info, const uchar *Buffer, size_t Count)
{
/*
Sasha: We are not writing this with the ? operator to avoid hitting
a possible compiler bug. At least gcc 2.95 cannot deal with
several layers of ternary operators that evaluated comma(,) operator
expressions inside - I do have a test case if somebody wants it
*/
if (info->type == SEQ_READ_APPEND)
return my_b_append(info, Buffer, Count);
return my_b_write(info, Buffer, Count);
}
|
O0
|
c
|
my_b_safe_write:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x3, 0xb0(%rax)
jne 0xe6147
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0xe5df0
movl %eax, -0x4(%rbp)
jmp 0xe615b
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0xe6170
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
my_b_safe_write:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov rax, [rbp+var_10]
cmp dword ptr [rax+0B0h], 3
jnz short loc_E6147
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_20]
call my_b_append
mov [rbp+var_4], eax
jmp short loc_E615B
loc_E6147:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_20]
call my_b_write_3
mov [rbp+var_4], eax
loc_E615B:
mov eax, [rbp+var_4]
add rsp, 20h
pop rbp
retn
|
long long my_b_safe_write(long long a1, long long a2, unsigned long long a3)
{
if ( *(_DWORD *)(a1 + 176) == 3 )
return (unsigned int)my_b_append(a1, a2, a3);
else
return (unsigned int)my_b_write_3(a1, a2, a3);
}
|
my_b_safe_write:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0xb0],0x3
JNZ 0x001e6147
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
CALL 0x001e5df0
MOV dword ptr [RBP + -0x4],EAX
JMP 0x001e615b
LAB_001e6147:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
CALL 0x001e6170
MOV dword ptr [RBP + -0x4],EAX
LAB_001e615b:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x20
POP RBP
RET
|
int4 my_b_safe_write(long param_1,int8 param_2,int8 param_3)
{
int4 local_c;
if (*(int *)(param_1 + 0xb0) == 3) {
local_c = my_b_append(param_1,param_2,param_3);
}
else {
local_c = my_b_write(param_1,param_2,param_3);
}
return local_c;
}
|
|
7,848 |
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)
|
monkey531[P]llama/common/json.hpp
|
inline void grisu2_digit_gen(char* buffer, int& length, int& decimal_exponent,
diyfp M_minus, diyfp w, diyfp M_plus)
{
static_assert(kAlpha >= -60, "internal error");
static_assert(kGamma <= -32, "internal error");
// Generates the digits (and the exponent) of a decimal floating-point
// number V = buffer * 10^decimal_exponent in the range [M-, M+]. The diyfp's
// w, M- and M+ share the same exponent e, which satisfies alpha <= e <= gamma.
//
// <--------------------------- delta ---->
// <---- dist --------->
// --------------[------------------+-------------------]--------------
// M- w M+
//
// Grisu2 generates the digits of M+ from left to right and stops as soon as
// V is in [M-,M+].
JSON_ASSERT(M_plus.e >= kAlpha);
JSON_ASSERT(M_plus.e <= kGamma);
std::uint64_t delta = diyfp::sub(M_plus, M_minus).f; // (significand of (M+ - M-), implicit exponent is e)
std::uint64_t dist = diyfp::sub(M_plus, w ).f; // (significand of (M+ - w ), implicit exponent is e)
// Split M+ = f * 2^e into two parts p1 and p2 (note: e < 0):
//
// M+ = f * 2^e
// = ((f div 2^-e) * 2^-e + (f mod 2^-e)) * 2^e
// = ((p1 ) * 2^-e + (p2 )) * 2^e
// = p1 + p2 * 2^e
const diyfp one(std::uint64_t{1} << -M_plus.e, M_plus.e);
auto p1 = static_cast<std::uint32_t>(M_plus.f >> -one.e); // p1 = f div 2^-e (Since -e >= 32, p1 fits into a 32-bit int.)
std::uint64_t p2 = M_plus.f & (one.f - 1); // p2 = f mod 2^-e
// 1)
//
// Generate the digits of the integral part p1 = d[n-1]...d[1]d[0]
JSON_ASSERT(p1 > 0);
std::uint32_t pow10{};
const int k = find_largest_pow10(p1, pow10);
// 10^(k-1) <= p1 < 10^k, pow10 = 10^(k-1)
//
// p1 = (p1 div 10^(k-1)) * 10^(k-1) + (p1 mod 10^(k-1))
// = (d[k-1] ) * 10^(k-1) + (p1 mod 10^(k-1))
//
// M+ = p1 + p2 * 2^e
// = d[k-1] * 10^(k-1) + (p1 mod 10^(k-1)) + p2 * 2^e
// = d[k-1] * 10^(k-1) + ((p1 mod 10^(k-1)) * 2^-e + p2) * 2^e
// = d[k-1] * 10^(k-1) + ( rest) * 2^e
//
// Now generate the digits d[n] of p1 from left to right (n = k-1,...,0)
//
// p1 = d[k-1]...d[n] * 10^n + d[n-1]...d[0]
//
// but stop as soon as
//
// rest * 2^e = (d[n-1]...d[0] * 2^-e + p2) * 2^e <= delta * 2^e
int n = k;
while (n > 0)
{
// Invariants:
// M+ = buffer * 10^n + (p1 + p2 * 2^e) (buffer = 0 for n = k)
// pow10 = 10^(n-1) <= p1 < 10^n
//
const std::uint32_t d = p1 / pow10; // d = p1 div 10^(n-1)
const std::uint32_t r = p1 % pow10; // r = p1 mod 10^(n-1)
//
// M+ = buffer * 10^n + (d * 10^(n-1) + r) + p2 * 2^e
// = (buffer * 10 + d) * 10^(n-1) + (r + p2 * 2^e)
//
JSON_ASSERT(d <= 9);
buffer[length++] = static_cast<char>('0' + d); // buffer := buffer * 10 + d
//
// M+ = buffer * 10^(n-1) + (r + p2 * 2^e)
//
p1 = r;
n--;
//
// M+ = buffer * 10^n + (p1 + p2 * 2^e)
// pow10 = 10^n
//
// Now check if enough digits have been generated.
// Compute
//
// p1 + p2 * 2^e = (p1 * 2^-e + p2) * 2^e = rest * 2^e
//
// Note:
// Since rest and delta share the same exponent e, it suffices to
// compare the significands.
const std::uint64_t rest = (std::uint64_t{p1} << -one.e) + p2;
if (rest <= delta)
{
// V = buffer * 10^n, with M- <= V <= M+.
decimal_exponent += n;
// We may now just stop. But instead look if the buffer could be
// decremented to bring V closer to w.
//
// pow10 = 10^n is now 1 ulp in the decimal representation V.
// The rounding procedure works with diyfp's with an implicit
// exponent of e.
//
// 10^n = (10^n * 2^-e) * 2^e = ulp * 2^e
//
const std::uint64_t ten_n = std::uint64_t{pow10} << -one.e;
grisu2_round(buffer, length, dist, delta, rest, ten_n);
return;
}
pow10 /= 10;
//
// pow10 = 10^(n-1) <= p1 < 10^n
// Invariants restored.
}
// 2)
//
// The digits of the integral part have been generated:
//
// M+ = d[k-1]...d[1]d[0] + p2 * 2^e
// = buffer + p2 * 2^e
//
// Now generate the digits of the fractional part p2 * 2^e.
//
// Note:
// No decimal point is generated: the exponent is adjusted instead.
//
// p2 actually represents the fraction
//
// p2 * 2^e
// = p2 / 2^-e
// = d[-1] / 10^1 + d[-2] / 10^2 + ...
//
// Now generate the digits d[-m] of p1 from left to right (m = 1,2,...)
//
// p2 * 2^e = d[-1]d[-2]...d[-m] * 10^-m
// + 10^-m * (d[-m-1] / 10^1 + d[-m-2] / 10^2 + ...)
//
// using
//
// 10^m * p2 = ((10^m * p2) div 2^-e) * 2^-e + ((10^m * p2) mod 2^-e)
// = ( d) * 2^-e + ( r)
//
// or
// 10^m * p2 * 2^e = d + r * 2^e
//
// i.e.
//
// M+ = buffer + p2 * 2^e
// = buffer + 10^-m * (d + r * 2^e)
// = (buffer * 10^m + d) * 10^-m + 10^-m * r * 2^e
//
// and stop as soon as 10^-m * r * 2^e <= delta * 2^e
JSON_ASSERT(p2 > delta);
int m = 0;
for (;;)
{
// Invariant:
// M+ = buffer * 10^-m + 10^-m * (d[-m-1] / 10 + d[-m-2] / 10^2 + ...) * 2^e
// = buffer * 10^-m + 10^-m * (p2 ) * 2^e
// = buffer * 10^-m + 10^-m * (1/10 * (10 * p2) ) * 2^e
// = buffer * 10^-m + 10^-m * (1/10 * ((10*p2 div 2^-e) * 2^-e + (10*p2 mod 2^-e)) * 2^e
//
JSON_ASSERT(p2 <= (std::numeric_limits<std::uint64_t>::max)() / 10);
p2 *= 10;
const std::uint64_t d = p2 >> -one.e; // d = (10 * p2) div 2^-e
const std::uint64_t r = p2 & (one.f - 1); // r = (10 * p2) mod 2^-e
//
// M+ = buffer * 10^-m + 10^-m * (1/10 * (d * 2^-e + r) * 2^e
// = buffer * 10^-m + 10^-m * (1/10 * (d + r * 2^e))
// = (buffer * 10 + d) * 10^(-m-1) + 10^(-m-1) * r * 2^e
//
JSON_ASSERT(d <= 9);
buffer[length++] = static_cast<char>('0' + d); // buffer := buffer * 10 + d
//
// M+ = buffer * 10^(-m-1) + 10^(-m-1) * r * 2^e
//
p2 = r;
m++;
//
// M+ = buffer * 10^-m + 10^-m * p2 * 2^e
// Invariant restored.
// Check if enough digits have been generated.
//
// 10^-m * p2 * 2^e <= delta * 2^e
// p2 * 2^e <= 10^m * delta * 2^e
// p2 <= 10^m * delta
delta *= 10;
dist *= 10;
if (p2 <= delta)
{
break;
}
}
// V = buffer * 10^-m, with M- <= V <= M+.
decimal_exponent -= m;
// 1 ulp in the decimal representation is now 10^-m.
// Since delta and dist are now scaled by 10^m, we need to do the
// same with ulp in order to keep the units in sync.
//
// 10^m * 10^-m = 1 = 2^-e * 2^e = ten_m * 2^e
//
const std::uint64_t ten_m = one.f;
grisu2_round(buffer, length, dist, delta, p2, ten_m);
// By construction this algorithm generates the shortest possible decimal
// number (Loitsch, Theorem 6.2) which rounds back to w.
// For an input number of precision p, at least
//
// N = 1 + ceil(p * log_10(2))
//
// decimal digits are sufficient to identify all binary floating-point
// numbers (Matula, "In-and-Out conversions").
// This implies that the algorithm does not produce more than N decimal
// digits.
//
// N = 17 for p = 53 (IEEE double precision)
// N = 9 for p = 24 (IEEE single precision)
}
|
O2
|
cpp
|
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):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rcx, 0x28(%rsp)
movl %r8d, 0x30(%rsp)
movl 0x88(%rsp), %eax
cmpl $-0x3d, %eax
jle 0x6ca03
movq %rdx, 0x8(%rsp)
movq %rdi, 0x20(%rsp)
cmpl $-0x1f, %eax
jge 0x6ca1f
movq %rsi, %r14
leaq 0x80(%rsp), %rbx
leaq 0x70(%rsp), %r15
leaq 0x28(%rsp), %rsi
movq %rbx, %rdi
callq 0x6ca74
movq %rax, %r12
movq %rbx, %rdi
movq %r15, %rsi
callq 0x6ca74
xorl %ebp, %ebp
subl 0x8(%rbx), %ebp
pushq $0x1
popq %rdx
movl %ebp, %ecx
shlq %cl, %rdx
movq (%rbx), %r15
movq %r15, %rbx
shrq %cl, %rbx
testl %ebx, %ebx
je 0x6ca3b
movq %rax, %r13
movq %rdx, 0x10(%rsp)
leaq -0x1(%rdx), %rax
movq %rax, 0x18(%rsp)
andq %rax, %r15
leaq 0x4(%rsp), %rsi
andl $0x0, (%rsi)
movl %ebx, %edi
callq 0x6cabe
movl %eax, %esi
leaq 0x4(%rsp), %rax
movl (%rax), %r10d
pushq $0xa
popq %r9
movq 0x20(%rsp), %rdi
testl %esi, %esi
jle 0x6c901
movl %ebx, %eax
xorl %edx, %edx
divl %r10d
cmpl $0xa, %eax
jae 0x6c9e2
movl %edx, %ebx
movslq (%r14), %rdx
leal 0x1(%rdx), %ecx
movl %ecx, (%r14)
movl %ebx, %r8d
movl %ebp, %ecx
shlq %cl, %r8
orb $0x30, %al
movb %al, (%rdi,%rdx)
addq %r15, %r8
cmpq %r12, %r8
jbe 0x6c978
movl %r10d, %eax
xorl %edx, %edx
divl %r9d
movl %eax, %r10d
movl %eax, 0x4(%rsp)
decl %esi
jmp 0x6c8b6
cmpq %r12, %r15
jbe 0x6ca57
xorl %eax, %eax
movabsq $0x199999999999999a, %rdx # imm = 0x199999999999999A
movq 0x18(%rsp), %r9
cmpq %rdx, %r15
jae 0x6c9aa
imulq $0xa, %r15, %r15
movq %r15, %rsi
movl %ebp, %ecx
shrq %cl, %rsi
cmpq $0xa, %rsi
jae 0x6c9c6
andq %r9, %r15
orb $0x30, %sil
movslq (%r14), %rcx
leal 0x1(%rcx), %r8d
movl %r8d, (%r14)
movb %sil, (%rdi,%rcx)
imulq $0xa, %r12, %r12
imulq $0xa, %r13, %r13
decl %eax
cmpq %r12, %r15
ja 0x6c91b
movq 0x8(%rsp), %rcx
addl %eax, (%rcx)
movl (%r14), %esi
movq %r13, %rdx
movq %r12, %rcx
movq %r15, %r8
movq 0x10(%rsp), %r9
jmp 0x6c996
movq 0x8(%rsp), %rcx
movl (%rcx), %eax
addl %esi, %eax
decl %eax
movl %eax, (%rcx)
movl %r10d, %r9d
movl %ebp, %ecx
shlq %cl, %r9
movl (%r14), %esi
movq %r13, %rdx
movq %r12, %rcx
callq 0x6cb5e
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x21d16(%rip), %rdi # 0x8e6c7
leaq 0x204c9(%rip), %rdx # 0x8ce81
leaq 0x24ae1(%rip), %rcx # 0x914a0
movl $0x4505, %esi # imm = 0x4505
jmp 0x6c9fc
leaq 0x21cfa(%rip), %rdi # 0x8e6c7
leaq 0x204ad(%rip), %rdx # 0x8ce81
leaq 0x24ab3(%rip), %rcx # 0x9148e
movl $0x450e, %esi # imm = 0x450E
jmp 0x6c9fc
leaq 0x21cde(%rip), %rdi # 0x8e6c7
leaq 0x20491(%rip), %rdx # 0x8ce81
leaq 0x24a97(%rip), %rcx # 0x9148e
movl $0x44a3, %esi # imm = 0x44A3
xorl %eax, %eax
callq 0x20af0
leaq 0x21cbd(%rip), %rdi # 0x8e6c7
leaq 0x20470(%rip), %rdx # 0x8ce81
leaq 0x24a49(%rip), %rcx # 0x91461
movl $0x4469, %esi # imm = 0x4469
jmp 0x6c9fc
leaq 0x21ca1(%rip), %rdi # 0x8e6c7
leaq 0x20454(%rip), %rdx # 0x8ce81
leaq 0x24a40(%rip), %rcx # 0x91474
movl $0x446a, %esi # imm = 0x446A
jmp 0x6c9fc
leaq 0x21c85(%rip), %rdi # 0x8e6c7
leaq 0x20438(%rip), %rdx # 0x8ce81
leaq 0x24a37(%rip), %rcx # 0x91487
movl $0x447f, %esi # imm = 0x447F
jmp 0x6c9fc
leaq 0x21c69(%rip), %rdi # 0x8e6c7
leaq 0x2041c(%rip), %rdx # 0x8ce81
leaq 0x24a29(%rip), %rcx # 0x91495
movl $0x44fa, %esi # imm = 0x44FA
jmp 0x6c9fc
nop
|
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl16grisu2_digit_genEPcRiS4_NS2_5diyfpES5_S5_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov [rsp+68h+var_40], rcx
mov [rsp+68h+var_38], r8d
mov eax, [rsp+68h+arg_18]
cmp eax, 0FFFFFFC3h
jle loc_6CA03
mov [rsp+68h+var_60], rdx
mov [rsp+68h+var_48], rdi
cmp eax, 0FFFFFFE1h
jge loc_6CA1F
mov r14, rsi
lea rbx, [rsp+68h+arg_10]
lea r15, [rsp+68h+arg_0]
lea rsi, [rsp+68h+var_40]
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3subERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::sub(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r12, rax
mov rdi, rbx
mov rsi, r15
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3subERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::sub(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
xor ebp, ebp
sub ebp, [rbx+8]
push 1
pop rdx
mov ecx, ebp
shl rdx, cl; unsigned int *
mov r15, [rbx]
mov rbx, r15
shr rbx, cl
test ebx, ebx
jz loc_6CA3B
mov r13, rax
mov [rsp+68h+var_58], rdx
lea rax, [rdx-1]
mov [rsp+68h+var_50], rax
and r15, rax
lea rsi, [rsp+68h+var_64]; unsigned int
and dword ptr [rsi], 0
mov edi, ebx; this
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl18find_largest_pow10EjRj; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::find_largest_pow10(uint,uint &)
mov esi, eax
lea rax, [rsp+68h+var_64]
mov r10d, [rax]
push 0Ah
pop r9
mov rdi, [rsp+68h+var_48]; this
loc_6C8B6:
test esi, esi
jle short loc_6C901
mov eax, ebx
xor edx, edx
div r10d
cmp eax, 0Ah
jnb loc_6C9E2
mov ebx, edx
movsxd rdx, dword ptr [r14]
lea ecx, [rdx+1]
mov [r14], ecx
mov r8d, ebx
mov ecx, ebp
shl r8, cl
or al, 30h
mov [rdi+rdx], al
add r8, r15; unsigned __int64
cmp r8, r12
jbe loc_6C978
mov eax, r10d
xor edx, edx
div r9d
mov r10d, eax
mov [rsp+68h+var_64], eax
dec esi
jmp short loc_6C8B6
loc_6C901:
cmp r15, r12
jbe loc_6CA57
xor eax, eax
mov rdx, 199999999999999Ah
mov r9, [rsp+68h+var_50]
loc_6C91B:
cmp r15, rdx
jnb loc_6C9AA
imul r15, 0Ah
mov rsi, r15
mov ecx, ebp
shr rsi, cl
cmp rsi, 0Ah
jnb loc_6C9C6
and r15, r9
or sil, 30h
movsxd rcx, dword ptr [r14]
lea r8d, [rcx+1]
mov [r14], r8d
mov [rdi+rcx], sil
imul r12, 0Ah
imul r13, 0Ah
dec eax
cmp r15, r12
ja short loc_6C91B
mov rcx, [rsp+68h+var_60]
add [rcx], eax
mov esi, [r14]
mov rdx, r13
mov rcx, r12
mov r8, r15
mov r9, [rsp+68h+var_58]
jmp short loc_6C996
loc_6C978:
mov rcx, [rsp+68h+var_60]
mov eax, [rcx]
add eax, esi
dec eax
mov [rcx], eax
mov r9d, r10d
mov ecx, ebp
shl r9, cl; unsigned __int64
mov esi, [r14]; char *
mov rdx, r13; int
mov rcx, r12; unsigned __int64
loc_6C996:
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl12grisu2_roundEPcimmmm; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(char *,int,ulong,ulong,ulong,ulong)
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_6C9AA:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aP2StdNumericLi; "p2 <= (std::numeric_limits<std::uint64_"...
mov esi, 4505h
jmp short loc_6C9FC
loc_6C9C6:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aD9; "d <= 9"
mov esi, 450Eh
jmp short loc_6C9FC
loc_6C9E2:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aD9; "d <= 9"
mov esi, 44A3h
loc_6C9FC:
xor eax, eax
call _ggml_abort
loc_6CA03:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEKalpha; "M_plus.e >= kAlpha"
mov esi, 4469h
jmp short loc_6C9FC
loc_6CA1F:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEKgamma; "M_plus.e <= kGamma"
mov esi, 446Ah
jmp short loc_6C9FC
loc_6CA3B:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aP10; "p1 > 0"
mov esi, 447Fh
jmp short loc_6C9FC
loc_6CA57:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aP2Delta; "p2 > delta"
mov esi, 44FAh
jmp short loc_6C9FC
|
long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *a1,
unsigned int *a2,
_DWORD *a3,
long long a4,
int a5,
long long a6,
char a7,
int a8,
unsigned long long a9,
int a10)
{
unsigned long long v11; // r12
int v12; // eax
int v13; // ebp
unsigned int *v14; // rdx
unsigned long long v15; // rbx
int v16; // r13d
unsigned long long v17; // r15
int largest_pow10; // esi
unsigned int v19; // r10d
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *v20; // rdi
unsigned int v21; // eax
long long v22; // rdx
unsigned long long v23; // r8
int v24; // eax
unsigned long long v25; // r9
unsigned long long v26; // r15
unsigned long long v27; // rsi
long long v28; // rcx
char *v29; // rsi
int v30; // edx
unsigned long long v31; // rcx
unsigned long long v32; // r9
unsigned long long v34; // [rsp+0h] [rbp-68h] BYREF
_DWORD *v35; // [rsp+8h] [rbp-60h]
long long v36; // [rsp+10h] [rbp-58h]
char *v37; // [rsp+18h] [rbp-50h]
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *v38; // [rsp+20h] [rbp-48h]
long long v39; // [rsp+28h] [rbp-40h] BYREF
int v40; // [rsp+30h] [rbp-38h]
v39 = a4;
v40 = a5;
if ( a10 <= -61 )
{
while ( 1 )
LABEL_20:
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17513LL,
"GGML_ASSERT(%s) failed",
"M_plus.e >= kAlpha");
}
v35 = a3;
v38 = a1;
if ( a10 >= -31 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17514LL,
"GGML_ASSERT(%s) failed",
"M_plus.e <= kGamma");
goto LABEL_20;
}
v11 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::sub(&a9, &v39);
v12 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::sub(&a9, &a7);
v13 = -a10;
v14 = (unsigned int *)(1LL << -(char)a10);
v15 = a9 >> -(char)a10;
if ( !(_DWORD)v15 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17535LL,
"GGML_ASSERT(%s) failed",
"p1 > 0");
goto LABEL_20;
}
v16 = v12;
v36 = 1LL << -(char)a10;
v37 = (char *)v14 - 1;
v17 = ((unsigned long long)v14 - 1) & a9;
HIDWORD(v34) = 0;
largest_pow10 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::find_largest_pow10(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)(unsigned int)v15,
(unsigned int)&v34 + 4,
v14);
v19 = HIDWORD(v34);
v20 = v38;
while ( largest_pow10 > 0 )
{
v21 = (unsigned int)v15 / v19;
if ( (unsigned int)v15 / v19 >= 0xA )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17571LL,
"GGML_ASSERT(%s) failed",
"d <= 9");
goto LABEL_20;
}
LODWORD(v15) = (unsigned int)v15 % v19;
v22 = (int)*a2;
*a2 = v22 + 1;
*((_BYTE *)v20 + v22) = v21 | 0x30;
v23 = v17 + ((unsigned long long)(unsigned int)v15 << v13);
if ( v23 <= v11 )
{
*v35 = largest_pow10 + *v35 - 1;
v32 = (unsigned long long)v19 << v13;
v29 = (char *)*a2;
v30 = v16;
v31 = v11;
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(v20, v29, v30, v31, v23, v32, v34);
}
v19 /= 0xAu;
HIDWORD(v34) = v19;
--largest_pow10;
}
if ( v17 <= v11 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17658LL,
"GGML_ASSERT(%s) failed",
"p2 > delta");
goto LABEL_20;
}
v24 = 0;
v25 = (unsigned long long)v37;
do
{
if ( v17 >= 0x199999999999999ALL )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17669LL,
"GGML_ASSERT(%s) failed",
"p2 <= (std::numeric_limits<std::uint64_t>::max)() / 10");
goto LABEL_20;
}
v26 = 10 * v17;
v27 = v26 >> v13;
if ( v26 >> v13 >= 0xA )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17678LL,
"GGML_ASSERT(%s) failed",
"d <= 9");
goto LABEL_20;
}
v17 = v25 & v26;
v28 = (int)*a2;
*a2 = v28 + 1;
*((_BYTE *)v20 + v28) = v27 | 0x30;
v11 *= 10LL;
v16 *= 10;
--v24;
}
while ( v17 > v11 );
*v35 += v24;
v29 = (char *)*a2;
v30 = v16;
v31 = v11;
v23 = v17;
v32 = v36;
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(v20, v29, v30, v31, v23, v32, v34);
}
|
grisu2_digit_gen:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV qword ptr [RSP + 0x28],RCX
MOV dword ptr [RSP + 0x30],R8D
MOV EAX,dword ptr [RSP + 0x88]
CMP EAX,-0x3d
JLE 0x0016ca03
MOV qword ptr [RSP + 0x8],RDX
MOV qword ptr [RSP + 0x20],RDI
CMP EAX,-0x1f
JGE 0x0016ca1f
MOV R14,RSI
LEA RBX,[RSP + 0x80]
LEA R15,[RSP + 0x70]
LEA RSI,[RSP + 0x28]
MOV RDI,RBX
CALL 0x0016ca74
MOV R12,RAX
MOV RDI,RBX
MOV RSI,R15
CALL 0x0016ca74
XOR EBP,EBP
SUB EBP,dword ptr [RBX + 0x8]
PUSH 0x1
POP RDX
MOV ECX,EBP
SHL RDX,CL
MOV R15,qword ptr [RBX]
MOV RBX,R15
SHR RBX,CL
TEST EBX,EBX
JZ 0x0016ca3b
MOV R13,RAX
MOV qword ptr [RSP + 0x10],RDX
LEA RAX,[RDX + -0x1]
MOV qword ptr [RSP + 0x18],RAX
AND R15,RAX
LEA RSI,[RSP + 0x4]
AND dword ptr [RSI],0x0
MOV EDI,EBX
CALL 0x0016cabe
MOV ESI,EAX
LEA RAX,[RSP + 0x4]
MOV R10D,dword ptr [RAX]
PUSH 0xa
POP R9
MOV RDI,qword ptr [RSP + 0x20]
LAB_0016c8b6:
TEST ESI,ESI
JLE 0x0016c901
MOV EAX,EBX
XOR EDX,EDX
DIV R10D
CMP EAX,0xa
JNC 0x0016c9e2
MOV EBX,EDX
MOVSXD RDX,dword ptr [R14]
LEA ECX,[RDX + 0x1]
MOV dword ptr [R14],ECX
MOV R8D,EBX
MOV ECX,EBP
SHL R8,CL
OR AL,0x30
MOV byte ptr [RDI + RDX*0x1],AL
ADD R8,R15
CMP R8,R12
JBE 0x0016c978
MOV EAX,R10D
XOR EDX,EDX
DIV R9D
MOV R10D,EAX
MOV dword ptr [RSP + 0x4],EAX
DEC ESI
JMP 0x0016c8b6
LAB_0016c901:
CMP R15,R12
JBE 0x0016ca57
XOR EAX,EAX
MOV RDX,0x199999999999999a
MOV R9,qword ptr [RSP + 0x18]
LAB_0016c91b:
CMP R15,RDX
JNC 0x0016c9aa
IMUL R15,R15,0xa
MOV RSI,R15
MOV ECX,EBP
SHR RSI,CL
CMP RSI,0xa
JNC 0x0016c9c6
AND R15,R9
OR SIL,0x30
MOVSXD RCX,dword ptr [R14]
LEA R8D,[RCX + 0x1]
MOV dword ptr [R14],R8D
MOV byte ptr [RDI + RCX*0x1],SIL
IMUL R12,R12,0xa
IMUL R13,R13,0xa
DEC EAX
CMP R15,R12
JA 0x0016c91b
MOV RCX,qword ptr [RSP + 0x8]
ADD dword ptr [RCX],EAX
MOV ESI,dword ptr [R14]
MOV RDX,R13
MOV RCX,R12
MOV R8,R15
MOV R9,qword ptr [RSP + 0x10]
JMP 0x0016c996
LAB_0016c978:
MOV RCX,qword ptr [RSP + 0x8]
MOV EAX,dword ptr [RCX]
ADD EAX,ESI
DEC EAX
MOV dword ptr [RCX],EAX
MOV R9D,R10D
MOV ECX,EBP
SHL R9,CL
MOV ESI,dword ptr [R14]
MOV RDX,R13
MOV RCX,R12
LAB_0016c996:
CALL 0x0016cb5e
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0016c9aa:
LEA RDI,[0x18e6c7]
LEA RDX,[0x18ce81]
LEA RCX,[0x1914a0]
MOV ESI,0x4505
JMP 0x0016c9fc
LAB_0016c9c6:
LEA RDI,[0x18e6c7]
LEA RDX,[0x18ce81]
LEA RCX,[0x19148e]
MOV ESI,0x450e
JMP 0x0016c9fc
LAB_0016c9e2:
LEA RDI,[0x18e6c7]
LEA RDX,[0x18ce81]
LEA RCX,[0x19148e]
MOV ESI,0x44a3
LAB_0016c9fc:
XOR EAX,EAX
CALL 0x00120af0
LAB_0016ca03:
LEA RDI,[0x18e6c7]
LEA RDX,[0x18ce81]
LEA RCX,[0x191461]
MOV ESI,0x4469
JMP 0x0016c9fc
LAB_0016ca1f:
LEA RDI,[0x18e6c7]
LEA RDX,[0x18ce81]
LEA RCX,[0x191474]
MOV ESI,0x446a
JMP 0x0016c9fc
LAB_0016ca3b:
LEA RDI,[0x18e6c7]
LEA RDX,[0x18ce81]
LEA RCX,[0x191487]
MOV ESI,0x447f
JMP 0x0016c9fc
LAB_0016ca57:
LEA RDI,[0x18e6c7]
LEA RDX,[0x18ce81]
LEA RCX,[0x191495]
MOV ESI,0x44fa
JMP 0x0016c9fc
|
/* 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) */
void nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen
(char *param_1,int *param_2,int *param_3,int8 param_4,int4 param_5)
{
int iVar1;
int iVar2;
ulong uVar3;
ulong uVar4;
byte bVar5;
char *pcVar6;
ulong uVar7;
ulong uVar8;
int8 uVar9;
ulong uVar10;
ulong in_stack_00000018;
int in_stack_00000020;
uint local_64;
int *local_60;
ulong local_58;
ulong local_50;
char *local_48;
int8 local_40;
int4 local_38;
local_40 = param_4;
local_38 = param_5;
if (in_stack_00000020 < -0x3c) {
pcVar6 = "M_plus.e >= kAlpha";
uVar9 = 0x4469;
}
else {
local_60 = param_3;
local_48 = param_1;
if (in_stack_00000020 < -0x1f) {
uVar3 = diyfp::sub((diyfp *)&stack0x00000018,(diyfp *)&local_40);
uVar4 = diyfp::sub((diyfp *)&stack0x00000018,&stack0x00000008);
bVar5 = -(char)in_stack_00000020;
uVar7 = 1L << (bVar5 & 0x3f);
uVar8 = in_stack_00000018 >> (bVar5 & 0x3f);
if ((uint)uVar8 == 0) {
pcVar6 = "p1 > 0";
uVar9 = 0x447f;
}
else {
local_50 = uVar7 - 1;
uVar10 = in_stack_00000018 & local_50;
local_64 = 0;
local_58 = uVar7;
for (iVar2 = find_largest_pow10((uint)uVar8,&local_64); 0 < iVar2; iVar2 = iVar2 + -1) {
uVar7 = (uVar8 & 0xffffffff) / (ulong)local_64;
uVar8 = (uVar8 & 0xffffffff) % (ulong)local_64;
if (9 < (uint)uVar7) {
pcVar6 = "d <= 9";
uVar9 = 0x44a3;
goto LAB_0016c9fc;
}
iVar1 = *param_2;
*param_2 = iVar1 + 1;
local_48[iVar1] = (byte)uVar7 | 0x30;
uVar7 = (uVar8 << (bVar5 & 0x3f)) + uVar10;
if (uVar7 <= uVar3) {
*local_60 = *local_60 + iVar2 + -1;
iVar2 = *param_2;
uVar8 = (ulong)local_64 << (bVar5 & 0x3f);
goto LAB_0016c996;
}
local_64 = local_64 / 10;
}
if (uVar3 < uVar10) {
iVar2 = 0;
uVar7 = uVar10;
while( true ) {
if (0x1999999999999999 < uVar7) {
pcVar6 = "p2 <= (std::numeric_limits<std::uint64_t>::max)() / 10";
uVar9 = 0x4505;
goto LAB_0016c9fc;
}
uVar8 = uVar7 * 10 >> (bVar5 & 0x3f);
if (9 < uVar8) break;
uVar7 = uVar7 * 10 & local_50;
iVar1 = *param_2;
*param_2 = iVar1 + 1;
local_48[iVar1] = (byte)uVar8 | 0x30;
uVar3 = uVar3 * 10;
uVar4 = uVar4 * 10;
iVar2 = iVar2 + -1;
if (uVar7 <= uVar3) {
*local_60 = *local_60 + iVar2;
iVar2 = *param_2;
uVar8 = local_58;
LAB_0016c996:
grisu2_round(local_48,iVar2,uVar4,uVar3,uVar7,uVar8);
return;
}
}
pcVar6 = "d <= 9";
uVar9 = 0x450e;
}
else {
pcVar6 = "p2 > delta";
uVar9 = 0x44fa;
}
}
}
else {
pcVar6 = "M_plus.e <= kGamma";
uVar9 = 0x446a;
}
}
LAB_0016c9fc:
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar9,
"GGML_ASSERT(%s) failed",pcVar6);
}
|
|
7,849 |
minja::Parser::parseStringConcat()
|
llama.cpp/common/minja/minja.hpp
|
std::shared_ptr<Expression> parseStringConcat() {
auto left = parseMathPow();
if (!left) throw std::runtime_error("Expected left side of 'string concat' expression");
static std::regex concat_tok(R"(~(?!\}))");
if (!consumeToken(concat_tok).empty()) {
auto right = parseLogicalAnd();
if (!right) throw std::runtime_error("Expected right side of 'string concat' expression");
left = std::make_shared<BinaryOpExpr>(get_location(), std::move(left), std::move(right), BinaryOpExpr::Op::StrConcat);
}
return left;
}
|
O3
|
cpp
|
minja::Parser::parseStringConcat():
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x50, %rsp
movq %rsi, %r14
movq %rdi, %rbx
callq 0xea1f2
cmpq $0x0, (%rbx)
je 0xea0d0
leaq 0x8563d(%rip), %rax # 0x16f5d8
movb (%rax), %al
testb %al, %al
je 0xea107
leaq 0x8560c(%rip), %rdx # 0x16f5b8
leaq 0x10(%rsp), %rdi
movq %r14, %rsi
movl $0x1, %ecx
callq 0xe76bc
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
movq -0x8(%rax), %r15
cmpq %rax, %rdi
je 0xe9fdd
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x21180
testq %r15, %r15
je 0xea0bf
movq %rsp, %rdi
movq %r14, %rsi
callq 0xe8da8
cmpq $0x0, (%rsp)
je 0xea15e
movq (%r14), %rax
movq %rax, 0x10(%rsp)
movq 0x8(%r14), %rax
movq %rax, 0x18(%rsp)
testq %rax, %rax
je 0xea027
movq 0x83f7f(%rip), %rcx # 0x16df98
cmpb $0x0, (%rcx)
je 0xea023
incl 0x8(%rax)
jmp 0xea027
lock
incl 0x8(%rax)
leaq 0x18(%rsp), %r15
movq 0x20(%r14), %rax
subq 0x10(%r14), %rax
movq %rax, 0x8(%r15)
movl $0x58, %edi
callq 0x21220
movq %rax, %r12
leaq 0x38(%rsp), %r14
movabsq $0x100000001, %rax # imm = 0x100000001
movq %rax, 0x8(%r12)
leaq 0x82eb0(%rip), %rax # 0x16cf10
addq $0x10, %rax
movq %rax, (%r12)
movq %r12, %r13
addq $0x10, %r13
leaq 0x10(%rsp), %rsi
movq %rsp, %rcx
movq %r13, %rdi
movq %rbx, %rdx
xorl %r8d, %r8d
callq 0xf4dd4
leaq 0x48(%rsp), %rdi
xorps %xmm0, %xmm0
movaps %xmm0, -0x8(%r14)
movups (%rbx), %xmm0
movq %r13, (%rbx)
movq %r12, 0x8(%rbx)
movaps %xmm0, -0x8(%rdi)
callq 0x46496
movq %r14, %rdi
callq 0x46496
movq %r15, %rdi
callq 0x46496
leaq 0x8(%rsp), %rdi
callq 0x46496
movq %rbx, %rax
addq $0x50, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movl $0x10, %edi
callq 0x21660
movq %rax, %r15
leaq 0x41451(%rip), %rsi # 0x12b535
movq %rax, %rdi
callq 0x21430
movq 0x83ecd(%rip), %rsi # 0x16dfc0
movq 0x83e86(%rip), %rdx # 0x16df80
movq %r15, %rdi
callq 0x21a80
jmp 0xea190
leaq 0x854ca(%rip), %rdi # 0x16f5d8
callq 0x215a0
testl %eax, %eax
je 0xe9fa5
leaq 0x85496(%rip), %rdi # 0x16f5b8
leaq 0x4143d(%rip), %rsi # 0x12b566
movl $0x10, %edx
callq 0x2d298
leaq -0x65f1a(%rip), %rdi # 0x84220
leaq 0x85477(%rip), %rsi # 0x16f5b8
leaq 0x84950(%rip), %rdx # 0x16ea98
callq 0x21f30
leaq 0x85484(%rip), %rdi # 0x16f5d8
callq 0x21990
jmp 0xe9fa5
movl $0x10, %edi
callq 0x21660
movq %rax, %r15
leaq 0x413fc(%rip), %rsi # 0x12b56e
movq %rax, %rdi
callq 0x21430
movq 0x83e3f(%rip), %rsi # 0x16dfc0
movq 0x83df8(%rip), %rdx # 0x16df80
movq %r15, %rdi
callq 0x21a80
movq %rax, %r14
leaq 0x8543e(%rip), %rdi # 0x16f5d8
callq 0x216e0
jmp 0xea1de
movq %rax, %r14
jmp 0xea1cd
movq %rax, %r14
movq %r15, %rdi
callq 0x21f50
jmp 0xea1cd
jmp 0xea1db
movq %rax, %r14
movq %r15, %rdi
callq 0x21f50
jmp 0xea1de
movq %rax, %r14
movq %r15, %rdi
callq 0x46496
leaq 0x8(%rsp), %rdi
callq 0x46496
jmp 0xea1de
jmp 0xea1db
movq %rax, %r14
addq $0x8, %rbx
movq %rbx, %rdi
callq 0x46496
movq %r14, %rdi
callq 0x21b20
|
_ZN5minja6Parser17parseStringConcatEv:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 50h
mov r14, rsi
mov rbx, rdi
call _ZN5minja6Parser12parseMathPowEv; minja::Parser::parseMathPow(void)
cmp qword ptr [rbx], 0
jz loc_EA0D0
lea rax, _ZGVZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; `guard variable for'minja::Parser::parseStringConcat(void)::concat_tok
mov al, [rax]
test al, al
jz loc_EA107
loc_E9FA5:
lea rdx, _ZZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; int
lea rdi, [rsp+78h+var_68]; int
mov rsi, r14; int
mov ecx, 1; int
call _ZN5minja6Parser12consumeTokenERKNSt7__cxx1111basic_regexIcNS1_12regex_traitsIcEEEENS_13SpaceHandlingE; minja::Parser::consumeToken(std::basic_regex<char,std::regex_traits<char>> const&,minja::SpaceHandling)
lea rax, [rsp+78h+var_58]
mov rdi, [rax-10h]; void *
mov r15, [rax-8]
cmp rdi, rax
jz short loc_E9FDD
mov rsi, [rsp+78h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_E9FDD:
test r15, r15
jz loc_EA0BF
mov rdi, rsp; this
mov rsi, r14
call _ZN5minja6Parser15parseLogicalAndEv; minja::Parser::parseLogicalAnd(void)
cmp [rsp+78h+var_78], 0
jz loc_EA15E
mov rax, [r14]
mov qword ptr [rsp+78h+var_68], rax
mov rax, [r14+8]
mov [rsp+78h+var_60], rax
test rax, rax
jz short loc_EA027
mov rcx, cs:_ZTISt19_Sp_make_shared_tag; `typeinfo for'std::_Sp_make_shared_tag
cmp byte ptr [rcx], 0
jz short loc_EA023
inc dword ptr [rax+8]
jmp short loc_EA027
loc_EA023:
lock inc dword ptr [rax+8]
loc_EA027:
lea r15, [rsp+78h+var_60]
mov rax, [r14+20h]
sub rax, [r14+10h]
mov [r15+8], rax
mov edi, 58h ; 'X'; unsigned __int64
call __Znwm; operator new(ulong)
mov r12, rax
lea r14, [rsp+78h+var_40]
mov rax, 100000001h
mov [r12+8], rax
lea rax, _ZTVSt23_Sp_counted_ptr_inplaceIN5minja12BinaryOpExprESaIvELN9__gnu_cxx12_Lock_policyE2EE; `vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<void>,(__gnu_cxx::_Lock_policy)2>
add rax, 10h
mov [r12], rax
mov r13, r12
add r13, 10h
lea rsi, [rsp+78h+var_68]
mov rcx, rsp
mov rdi, r13
mov rdx, rbx
xor r8d, r8d
call _ZN5minja12BinaryOpExprC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEES7_NS0_2OpE; minja::BinaryOpExpr::BinaryOpExpr(minja::Location const&,std::shared_ptr<minja::Expression> &&,std::shared_ptr<minja::Expression> &,minja::BinaryOpExpr::Op)
lea rdi, [rsp+78h+var_30]
xorps xmm0, xmm0
movaps xmmword ptr [r14-8], xmm0
movups xmm0, xmmword ptr [rbx]
mov [rbx], r13
mov [rbx+8], r12
movaps xmmword ptr [rdi-8], xmm0
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
mov rdi, r14
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
mov rdi, r15
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
lea rdi, [rsp+78h+var_70]
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
loc_EA0BF:
mov rax, rbx
add rsp, 50h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
loc_EA0D0:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedLeftSi_2; "Expected left side of 'string concat' e"...
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
jmp loc_EA190
loc_EA107:
lea rdi, _ZGVZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; __guard *
call ___cxa_guard_acquire
test eax, eax
jz loc_E9FA5
lea rdi, _ZZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; minja::Parser::parseStringConcat(void)::concat_tok
lea rsi, asc_12B566; "~(?!\\})"
mov edx, 10h
call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEEC2EPKcNSt15regex_constants18syntax_option_typeE; std::basic_regex<char,std::regex_traits<char>>::basic_regex(char const*,std::regex_constants::syntax_option_type)
lea rdi, _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; lpfunc
lea rsi, _ZZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; obj
lea rdx, __dso_handle; lpdso_handle
call ___cxa_atexit
lea rdi, _ZGVZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; __guard *
call ___cxa_guard_release
jmp loc_E9FA5
loc_EA15E:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedRightS_2; "Expected right side of 'string concat' "...
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
loc_EA190:
mov r14, rax
lea rdi, _ZGVZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; __guard *
call ___cxa_guard_abort
jmp short loc_EA1DE
mov r14, rax
jmp short loc_EA1CD
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_EA1CD
jmp short loc_EA1DB
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_EA1DE
mov r14, rax
mov rdi, r15
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
loc_EA1CD:
lea rdi, [rsp+78h+var_70]
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
jmp short loc_EA1DE
jmp short $+2
loc_EA1DB:
mov r14, rax
loc_EA1DE:
add rbx, 8
mov rdi, rbx
call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count()
mov rdi, r14
call __Unwind_Resume
|
minja::Parser * minja::Parser::parseStringConcat(minja::Parser *this, long long *a2)
{
volatile signed __int32 *v2; // r15
volatile signed __int32 *v3; // rax
_QWORD *v4; // r12
__int128 v5; // xmm0
std::runtime_error *exception; // r15
std::runtime_error *v8; // r15
long long v9; // [rsp+0h] [rbp-78h] BYREF
volatile signed __int32 *v10; // [rsp+8h] [rbp-70h] BYREF
int v11[2]; // [rsp+10h] [rbp-68h] BYREF
volatile signed __int32 *v12; // [rsp+18h] [rbp-60h] BYREF
long long v13; // [rsp+20h] [rbp-58h] BYREF
__int128 v14; // [rsp+30h] [rbp-48h] BYREF
__int128 v15; // [rsp+40h] [rbp-38h] BYREF
minja::Parser::parseMathPow(this);
if ( !*(_QWORD *)this )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Expected left side of 'string concat' expression");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
if ( !(_BYTE)`guard variable for'minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11]
&& __cxa_guard_acquire(&`guard variable for'minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11]) )
{
std::basic_regex<char,std::regex_traits<char>>::basic_regex(
(long long)&minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11],
(long long)"~(?!\\})",
0x10u);
__cxa_atexit(
(void (*)(void *))std::basic_regex<char,std::regex_traits<char>>::~basic_regex,
&minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11],
&_dso_handle);
__cxa_guard_release(&`guard variable for'minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11]);
}
minja::Parser::consumeToken(
v11,
(long long)a2,
(long long)&minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11],
1u);
v2 = v12;
if ( *(long long **)v11 != &v13 )
operator delete(*(void **)v11, v13 + 1);
if ( v2 )
{
minja::Parser::parseLogicalAnd((minja::Parser *)&v9, a2);
if ( !v9 )
{
v8 = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(v8, "Expected right side of 'string concat' expression");
__cxa_throw(
v8,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
*(_QWORD *)v11 = *a2;
v3 = (volatile signed __int32 *)a2[1];
v12 = v3;
if ( v3 )
{
if ( _libc_single_threaded )
++*((_DWORD *)v3 + 2);
else
_InterlockedIncrement(v3 + 2);
}
v13 = a2[4] - a2[2];
v4 = (_QWORD *)operator new(0x58uLL);
v4[1] = 0x100000001LL;
*v4 = &`vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<void>,(__gnu_cxx::_Lock_policy)2>
+ 2;
minja::BinaryOpExpr::BinaryOpExpr(v4 + 2, v11, this, &v9, 0LL);
v14 = 0LL;
v5 = *(_OWORD *)this;
*(_QWORD *)this = v4 + 2;
*((_QWORD *)this + 1) = v4;
v15 = v5;
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count((volatile signed __int32 **)&v15 + 1);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count((volatile signed __int32 **)&v14 + 1);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(&v12);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(&v10);
}
return this;
}
|
parseStringConcat:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x50
MOV R14,RSI
MOV RBX,RDI
CALL 0x001ea1f2
CMP qword ptr [RBX],0x0
JZ 0x001ea0d0
LEA RAX,[0x26f5d8]
MOV AL,byte ptr [RAX]
TEST AL,AL
JZ 0x001ea107
LAB_001e9fa5:
LEA RDX,[0x26f5b8]
LEA RDI,[RSP + 0x10]
MOV RSI,R14
MOV ECX,0x1
CALL 0x001e76bc
LEA RAX,[RSP + 0x20]
MOV RDI,qword ptr [RAX + -0x10]
MOV R15,qword ptr [RAX + -0x8]
CMP RDI,RAX
JZ 0x001e9fdd
MOV RSI,qword ptr [RSP + 0x20]
INC RSI
CALL 0x00121180
LAB_001e9fdd:
TEST R15,R15
JZ 0x001ea0bf
LAB_001e9fe6:
MOV RDI,RSP
MOV RSI,R14
CALL 0x001e8da8
CMP qword ptr [RSP],0x0
JZ 0x001ea15e
MOV RAX,qword ptr [R14]
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [R14 + 0x8]
MOV qword ptr [RSP + 0x18],RAX
TEST RAX,RAX
JZ 0x001ea027
MOV RCX,qword ptr [0x0026df98]
CMP byte ptr [RCX],0x0
JZ 0x001ea023
INC dword ptr [RAX + 0x8]
JMP 0x001ea027
LAB_001ea023:
INC.LOCK dword ptr [RAX + 0x8]
LAB_001ea027:
LEA R15,[RSP + 0x18]
MOV RAX,qword ptr [R14 + 0x20]
SUB RAX,qword ptr [R14 + 0x10]
MOV qword ptr [R15 + 0x8],RAX
LAB_001ea038:
MOV EDI,0x58
CALL 0x00121220
LAB_001ea042:
MOV R12,RAX
LEA R14,[RSP + 0x38]
MOV RAX,0x100000001
MOV qword ptr [R12 + 0x8],RAX
LEA RAX,[0x26cf10]
ADD RAX,0x10
MOV qword ptr [R12],RAX
MOV R13,R12
ADD R13,0x10
LEA RSI,[RSP + 0x10]
MOV RCX,RSP
MOV RDI,R13
MOV RDX,RBX
XOR R8D,R8D
CALL 0x001f4dd4
LEA RDI,[RSP + 0x48]
XORPS XMM0,XMM0
MOVAPS xmmword ptr [R14 + -0x8],XMM0
MOVUPS XMM0,xmmword ptr [RBX]
MOV qword ptr [RBX],R13
MOV qword ptr [RBX + 0x8],R12
MOVAPS xmmword ptr [RDI + -0x8],XMM0
CALL 0x00146496
MOV RDI,R14
CALL 0x00146496
MOV RDI,R15
CALL 0x00146496
LEA RDI,[RSP + 0x8]
CALL 0x00146496
LAB_001ea0bf:
MOV RAX,RBX
ADD RSP,0x50
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
LAB_001ea0d0:
MOV EDI,0x10
CALL 0x00121660
MOV R15,RAX
LAB_001ea0dd:
LEA RSI,[0x22b535]
MOV RDI,RAX
CALL 0x00121430
LAB_001ea0ec:
MOV RSI,qword ptr [0x0026dfc0]
MOV RDX,qword ptr [0x0026df80]
MOV RDI,R15
CALL 0x00121a80
LAB_001ea107:
LEA RDI,[0x26f5d8]
CALL 0x001215a0
TEST EAX,EAX
JZ 0x001e9fa5
LAB_001ea11b:
LEA RDI,[0x26f5b8]
LEA RSI,[0x22b566]
MOV EDX,0x10
CALL 0x0012d298
LAB_001ea133:
LEA RDI,[0x184220]
LEA RSI,[0x26f5b8]
LEA RDX,[0x26ea98]
CALL 0x00121f30
LEA RDI,[0x26f5d8]
CALL 0x00121990
JMP 0x001e9fa5
LAB_001ea15e:
MOV EDI,0x10
CALL 0x00121660
MOV R15,RAX
LAB_001ea16b:
LEA RSI,[0x22b56e]
MOV RDI,RAX
CALL 0x00121430
LAB_001ea17a:
MOV RSI,qword ptr [0x0026dfc0]
MOV RDX,qword ptr [0x0026df80]
MOV RDI,R15
CALL 0x00121a80
|
/* minja::Parser::parseStringConcat() */
void minja::Parser::parseStringConcat(void)
{
int iVar1;
int8 *puVar2;
runtime_error *prVar3;
int8 *in_RSI;
long *in_RDI;
long local_78;
__shared_count<(__gnu_cxx::_Lock_policy)2> local_70 [8];
long *local_68;
long local_60;
long local_58 [2];
int8 local_48;
int8 uStack_40;
long local_38;
long lStack_30;
parseMathPow();
if (*in_RDI == 0) {
prVar3 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 001ea0dd to 001ea0eb has its CatchHandler @ 001ea1b5 */
std::runtime_error::runtime_error(prVar3,"Expected left side of \'string concat\' expression");
/* try { // try from 001ea0ec to 001ea101 has its CatchHandler @ 001ea1b3 */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar3,PTR_typeinfo_0026dfc0,PTR__runtime_error_0026df80);
}
if (parseStringConcat()::concat_tok_abi_cxx11_ == '\0') {
iVar1 = __cxa_guard_acquire(&parseStringConcat()::concat_tok_abi_cxx11_);
if (iVar1 != 0) {
/* try { // try from 001ea11b to 001ea132 has its CatchHandler @ 001ea190 */
std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::basic_regex
((basic_regex<char,std::__cxx11::regex_traits<char>> *)
parseStringConcat()::concat_tok_abi_cxx11_,"~(?!\\})",0x10);
__cxa_atexit(std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex,
parseStringConcat()::concat_tok_abi_cxx11_,&__dso_handle);
__cxa_guard_release(&parseStringConcat()::concat_tok_abi_cxx11_);
}
}
/* try { // try from 001e9fa5 to 001e9fbd has its CatchHandler @ 001ea1db */
consumeToken(&local_68);
if (local_68 != local_58) {
operator_delete(local_68,local_58[0] + 1);
}
if (local_60 != 0) {
/* try { // try from 001e9fe6 to 001e9ff0 has its CatchHandler @ 001ea1d9 */
parseLogicalAnd();
if (local_78 == 0) {
prVar3 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 001ea16b to 001ea179 has its CatchHandler @ 001ea1a6 */
std::runtime_error::runtime_error
(prVar3,"Expected right side of \'string concat\' expression");
/* try { // try from 001ea17a to 001ea18f has its CatchHandler @ 001ea1a1 */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar3,PTR_typeinfo_0026dfc0,PTR__runtime_error_0026df80);
}
local_68 = (long *)*in_RSI;
local_60 = in_RSI[1];
if (local_60 != 0) {
if (*PTR___libc_single_threaded_0026df98 == '\0') {
LOCK();
*(int *)(local_60 + 8) = *(int *)(local_60 + 8) + 1;
UNLOCK();
}
else {
*(int *)(local_60 + 8) = *(int *)(local_60 + 8) + 1;
}
}
local_58[0] = in_RSI[4] - in_RSI[2];
/* try { // try from 001ea038 to 001ea041 has its CatchHandler @ 001ea1c2 */
puVar2 = (int8 *)operator_new(0x58);
puVar2[1] = 0x100000001;
*puVar2 = &PTR___Sp_counted_base_0026cf20;
BinaryOpExpr::BinaryOpExpr((BinaryOpExpr *)(puVar2 + 2),&local_68);
local_48 = 0;
uStack_40 = 0;
local_38 = *in_RDI;
lStack_30 = in_RDI[1];
*in_RDI = (long)(puVar2 + 2);
in_RDI[1] = (long)puVar2;
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count
((__shared_count<(__gnu_cxx::_Lock_policy)2> *)&lStack_30);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count
((__shared_count<(__gnu_cxx::_Lock_policy)2> *)&uStack_40);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count
((__shared_count<(__gnu_cxx::_Lock_policy)2> *)&local_60);
std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count(local_70);
}
return;
}
|
|
7,850 |
my_strtoll10_mb2
|
eloqsql/strings/ctype-ucs2.c
|
static longlong
my_strtoll10_mb2(CHARSET_INFO *cs __attribute__((unused)),
const char *nptr, char **endptr, int *error)
{
const uchar *s, *end, *start, *n_end, *true_end;
uchar UNINIT_VAR(c);
unsigned long i, j, k;
ulonglong li;
int negative;
ulong cutoff, cutoff2, cutoff3;
my_wc_t wc;
int res;
my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc;
s= (const uchar *) nptr;
/* If fixed length string */
if (endptr)
{
/*
Make sure string length is even.
Odd length indicates a bug in the caller.
Assert in debug, round in production.
*/
DBUG_ASSERT((*endptr - (const char *) s) % 2 == 0);
end= s + ((*endptr - (const char*) s) / 2) * 2;
for ( ; ; ) /* Skip leading spaces and tabs */
{
if ((res= mb_wc(cs, &wc, s, end)) <= 0)
goto no_conv;
s+= res;
if (wc != ' ' && wc != '\t')
break;
}
}
else
{
/* We don't support null terminated strings in UCS2 */
goto no_conv;
}
/* Check for a sign. */
negative= 0;
if (wc == '-')
{
*error= -1; /* Mark as negative number */
negative= 1;
if ((res= mb_wc(cs, &wc, s, end)) <= 0)
goto no_conv;
s+= res; /* wc is now expected to hold the first digit. */
cutoff= MAX_NEGATIVE_NUMBER / LFACTOR2;
cutoff2= (MAX_NEGATIVE_NUMBER % LFACTOR2) / 100;
cutoff3= MAX_NEGATIVE_NUMBER % 100;
}
else
{
*error= 0;
if (wc == '+')
{
if ((res= mb_wc(cs, &wc, s, end)) <= 0)
goto no_conv;
s+= res; /* wc is now expected to hold the first digit. */
}
cutoff= ULONGLONG_MAX / LFACTOR2;
cutoff2= ULONGLONG_MAX % LFACTOR2 / 100;
cutoff3= ULONGLONG_MAX % 100;
}
/*
The code below assumes that 'wc' holds the first digit
and 's' points to the next character after it.
Scan pre-zeros if any.
*/
if (wc == '0')
{
i= 0;
for ( ; ; s+= res)
{
if (s == end)
goto end_i; /* Return 0 */
if ((res= mb_wc(cs, &wc, s, end)) <= 0)
goto no_conv;
if (wc != '0')
break;
}
n_end= s + 2 * INIT_CNT;
}
else
{
/* Read first digit to check that it's a valid number */
if ((i= (wc - '0')) > 9)
goto no_conv;
n_end= s + 2 * (INIT_CNT-1);
}
/* Handle first 9 digits and store them in i */
if (n_end > end)
n_end= end;
for ( ; ; s+= res)
{
if ((res= mb_wc(cs, &wc, s, n_end)) <= 0)
break;
if (wc2digit_uchar(&c, wc))
goto end_i;
i= i*10+c;
}
if (s == end)
goto end_i;
/* Handle next 9 digits and store them in j */
j= 0;
start= s; /* Used to know how much to shift i */
n_end= true_end= s + 2 * INIT_CNT;
if (n_end > end)
n_end= end;
do
{
if ((res= mb_wc(cs, &wc, s, end)) <= 0)
goto no_conv;
if (wc2digit_uchar(&c, wc))
goto end_i_and_j;
s+= res;
j= j * 10 + c;
} while (s != n_end);
if (s == end)
{
if (s != true_end)
goto end_i_and_j;
goto end3;
}
/* Handle the next 1 or 2 digits and store them in k */
if ((res= mb_wc(cs, &wc, s, end)) <= 0)
goto no_conv;
if ((k= (wc - '0')) > 9)
goto end3;
s+= res;
if (s == end)
goto end4;
if ((res= mb_wc(cs, &wc, s, end)) <= 0)
goto no_conv;
if (wc2digit_uchar(&c, wc))
goto end4;
s+= res;
k= k*10+c;
*endptr= (char*) s;
/* number string should have ended here */
if (s != end && mb_wc(cs, &wc, s, end) > 0 && ((uchar) (wc - '0')) <= 9)
goto overflow;
/* Check that we didn't get an overflow with the last digit */
if (i > cutoff || (i == cutoff && ((j > cutoff2 || j == cutoff2) &&
k > cutoff3)))
goto overflow;
li=i*LFACTOR2+ (ulonglong) j*100 + k;
return (longlong) li;
overflow: /* *endptr is set here */
*error= MY_ERRNO_ERANGE;
return negative ? LONGLONG_MIN : (longlong) ULONGLONG_MAX;
end_i:
*endptr= (char*) s;
return (negative ? ((longlong) -(long) i) : (longlong) i);
end_i_and_j:
li= (ulonglong) i * lfactor[(size_t) (s-start) / 2] + j;
*endptr= (char*) s;
return (negative ? -((longlong) li) : (longlong) li);
end3:
li=(ulonglong) i*LFACTOR+ (ulonglong) j;
*endptr= (char*) s;
return (negative ? -((longlong) li) : (longlong) li);
end4:
li=(ulonglong) i*LFACTOR1+ (ulonglong) j * 10 + k;
*endptr= (char*) s;
if (negative)
{
if (li > MAX_NEGATIVE_NUMBER)
goto overflow;
return -((longlong) li);
}
return (longlong) li;
no_conv:
/* There was no number to convert. */
*error= MY_ERRNO_EDOM;
*endptr= (char *) nptr;
return 0;
}
|
O3
|
c
|
my_strtoll10_mb2:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rcx, -0x60(%rbp)
movq %rsi, -0x68(%rbp)
movq %rdx, -0x48(%rbp)
testq %rdx, %rdx
je 0xc8f19
movq %rdi, %r12
movq 0xb8(%rdi), %rax
movq 0x28(%rax), %r8
movq -0x48(%rbp), %rax
movq (%rax), %rax
movq -0x68(%rbp), %rdx
subq %rdx, %rax
movq %rax, %r15
shrq $0x3f, %r15
addq %rax, %r15
andq $-0x2, %r15
addq %rdx, %r15
leaq -0x30(%rbp), %rsi
movq %r15, %rcx
movq %r8, -0x38(%rbp)
callq *%r8
testl %eax, %eax
jle 0xc8f19
leaq -0x30(%rbp), %rbx
movq -0x68(%rbp), %r13
movq %r13, %rcx
movl %eax, %r13d
addq %rcx, %r13
movq -0x30(%rbp), %r14
cmpq $0x20, %r14
je 0xc8f06
cmpq $0x9, %r14
jne 0xc8f3f
movq %r12, %rdi
movq %rbx, %rsi
movq %r13, %rdx
movq %r15, %rcx
callq *-0x38(%rbp)
testl %eax, %eax
jg 0xc8eed
movq -0x60(%rbp), %rax
movl $0x21, (%rax)
movq -0x48(%rbp), %rax
movq -0x68(%rbp), %rcx
movq %rcx, (%rax)
xorl %eax, %eax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpq $0x2d, %r14
jne 0xc8f85
movq -0x60(%rbp), %rax
movl $0xffffffff, (%rax) # imm = 0xFFFFFFFF
leaq -0x30(%rbp), %rsi
movq %r12, %rdi
movq %r13, %rdx
movq %r15, %rcx
callq *-0x38(%rbp)
testl %eax, %eax
jle 0xc8f19
movl %eax, %eax
addq %rax, %r13
movl $0x8, %eax
movq %rax, -0x70(%rbp)
movl $0x15f797ae, %eax # imm = 0x15F797AE
movq %rax, -0x78(%rbp)
movl $0x57f5ff8, %eax # imm = 0x57F5FF8
movq %rax, -0x58(%rbp)
jmp 0xc8fcd
movq -0x60(%rbp), %rax
movl $0x0, (%rax)
movl $0xf, %eax
movq %rax, -0x70(%rbp)
movl $0x2bef2f5c, %eax # imm = 0x2BEF2F5C
movq %rax, -0x78(%rbp)
movl $0xafebff0, %eax # imm = 0xAFEBFF0
movq %rax, -0x58(%rbp)
cmpq $0x2b, %r14
jne 0xc8fcd
leaq -0x30(%rbp), %rsi
movq %r12, %rdi
movq %r13, %rdx
movq %r15, %rcx
callq *-0x38(%rbp)
testl %eax, %eax
jle 0xc8f19
movl %eax, %eax
addq %rax, %r13
movq -0x30(%rbp), %rax
cmpq $0x30, %rax
jne 0xc900f
cmpq %r15, %r13
je 0xc9008
leaq -0x30(%rbp), %rbx
movq %r12, %rdi
movq %rbx, %rsi
movq %r13, %rdx
movq %r15, %rcx
callq *-0x38(%rbp)
testl %eax, %eax
jle 0xc8f19
cmpq $0x30, -0x30(%rbp)
jne 0xc9026
movl %eax, %eax
addq %rax, %r13
cmpq %r15, %r13
jne 0xc8fe0
xorl %ebx, %ebx
jmp 0xc91dc
addq $-0x30, %rax
cmpq $0x9, %rax
ja 0xc8f19
movq %rax, %rbx
leaq 0x10(%r13), %rcx
jmp 0xc902c
leaq 0x12(%r13), %rcx
xorl %ebx, %ebx
cmpq %r15, %rcx
cmovaq %r15, %rcx
leaq -0x30(%rbp), %rsi
movq %r12, %rdi
movq %r13, %rdx
movq %rcx, -0x40(%rbp)
callq *-0x38(%rbp)
testl %eax, %eax
jle 0xc9082
movq -0x30(%rbp), %rcx
cmpq $0x39, %rcx
ja 0xc91d9
addb $-0x30, %cl
cmpb $0x9, %cl
ja 0xc91d9
leaq (%rbx,%rbx,4), %rdx
movzbl %cl, %ecx
leaq (%rcx,%rdx,2), %rbx
movl %eax, %eax
addq %rax, %r13
movq %r12, %rdi
leaq -0x30(%rbp), %rsi
movq %r13, %rdx
movq -0x40(%rbp), %rcx
jmp 0xc9041
cmpq %r15, %r13
je 0xc91dc
movq %rbx, -0x50(%rbp)
leaq 0x12(%r13), %rax
cmpq %r15, %rax
cmovaq %r15, %rax
movq %rax, -0x80(%rbp)
xorl %ebx, %ebx
xorl %esi, %esi
movq %rsi, -0x40(%rbp)
leaq (%rbx,%r13), %rdx
movq %r12, %rdi
leaq -0x30(%rbp), %rsi
movq %rdx, -0x88(%rbp)
movq %r15, %rcx
callq *-0x38(%rbp)
testl %eax, %eax
jle 0xc8f19
movq -0x30(%rbp), %rcx
cmpq $0x39, %rcx
ja 0xc91f6
addb $-0x30, %cl
cmpb $0x9, %cl
movq -0x40(%rbp), %rsi
ja 0xc91fa
movl %eax, %eax
addq %rax, %rbx
leaq (%rbx,%r13), %r8
leaq (%rsi,%rsi,4), %rax
movzbl %cl, %ecx
leaq (%rcx,%rax,2), %rsi
cmpq -0x80(%rbp), %r8
jne 0xc90a2
cmpq %r15, -0x80(%rbp)
je 0xc9238
movq %rsi, -0x40(%rbp)
leaq -0x30(%rbp), %rsi
movq %r12, %rdi
movq %r8, %rbx
movq %r8, %rdx
movq %r15, %rcx
callq *-0x38(%rbp)
testl %eax, %eax
jle 0xc8f19
movq -0x30(%rbp), %r13
addq $-0x30, %r13
cmpq $0x9, %r13
movq -0x40(%rbp), %rsi
movq %rbx, %r8
ja 0xc923e
movl %eax, %eax
addq %rax, %r8
cmpq %r15, %r8
je 0xc9263
leaq -0x30(%rbp), %rsi
movq %r12, %rdi
movq %r8, %rbx
movq %r8, %rdx
movq %r15, %rcx
callq *-0x38(%rbp)
testl %eax, %eax
jle 0xc8f19
movq -0x30(%rbp), %rcx
cmpq $0x39, %rcx
movq -0x40(%rbp), %rsi
movq %rbx, %r8
ja 0xc9263
addb $-0x30, %cl
cmpb $0x9, %cl
ja 0xc9263
movq %rcx, %rbx
movl %eax, %eax
addq %rax, %r8
movq -0x48(%rbp), %rax
movq %r8, (%rax)
cmpq %r15, %r8
je 0xc92c8
movq %r8, %rdx
leaq -0x30(%rbp), %rsi
movq %r12, %rdi
movq %r15, %rcx
callq *-0x38(%rbp)
testl %eax, %eax
jle 0xc92c8
movl $0xd0, %eax
addl -0x30(%rbp), %eax
andl $0xfe, %eax
cmpl $0xa, %eax
movq -0x50(%rbp), %rdx
jae 0xc92cc
jmp 0xc92a0
movq %r13, %r15
movq %rbx, %rax
negq %rax
cmpq $0x2d, %r14
movq -0x48(%rbp), %rcx
movq %r15, (%rcx)
cmovneq %rbx, %rax
jmp 0xc8f30
movq -0x40(%rbp), %rsi
movq -0x88(%rbp), %r15
movq %r15, %rax
subq %r13, %rax
andq $-0x2, %rax
leaq 0x2120fe(%rip), %rcx # 0x2db310
movq -0x50(%rbp), %rdx
imulq (%rcx,%rax,4), %rdx
addq %rsi, %rdx
movq %rdx, %rax
negq %rax
cmpq $0x2d, %r14
movq -0x48(%rbp), %rcx
movq %r15, (%rcx)
cmovneq %rdx, %rax
jmp 0xc8f30
cmpq $0x12, %rbx
jne 0xc9201
imulq $0x3b9aca00, -0x50(%rbp), %rax # imm = 0x3B9ACA00
addq %rax, %rsi
movq %rsi, %rax
negq %rax
cmpq $0x2d, %r14
movq -0x48(%rbp), %rcx
movq %r8, (%rcx)
cmovneq %rsi, %rax
jmp 0xc8f30
movabsq $0x2540be400, %rax # imm = 0x2540BE400
movq -0x50(%rbp), %rcx
imulq %rax, %rcx
leaq (%rsi,%rsi,4), %rax
leaq (%rcx,%rax,2), %rax
addq %r13, %rax
movq -0x48(%rbp), %rcx
movq %r8, (%rcx)
cmpq $0x2d, %r14
jne 0xc8f30
movabsq $-0x8000000000000000, %rcx # imm = 0x8000000000000000
cmpq %rcx, %rax
jbe 0xc92c0
xorl %eax, %eax
cmpq $0x2d, %r14
setne %al
movq -0x60(%rbp), %rcx
movl $0x22, (%rcx)
negq %rax
btsq $0x3f, %rax
jmp 0xc8f30
negq %rax
jmp 0xc8f30
movq -0x50(%rbp), %rdx
cmpq -0x58(%rbp), %rdx
ja 0xc92a0
leaq (,%r13,4), %rax
addq %r13, %rax
movzbl %bl, %ecx
leaq (%rcx,%rax,2), %rax
cmpq -0x58(%rbp), %rdx
jne 0xc92fa
movq -0x40(%rbp), %rcx
cmpq -0x78(%rbp), %rcx
jb 0xc92fa
cmpq -0x70(%rbp), %rax
ja 0xc92a0
movabsq $0x174876e800, %rcx # imm = 0x174876E800
imulq %rcx, %rdx
imulq $0x64, -0x40(%rbp), %rcx
addq %rax, %rdx
addq %rcx, %rdx
movq %rdx, %rax
jmp 0xc8f30
|
my_strtoll10_mb2:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 68h
mov [rbp+var_60], rcx
mov [rbp+var_68], rsi
mov [rbp+var_48], rdx
test rdx, rdx
jz short loc_C8F19
mov r12, rdi
mov rax, [rdi+0B8h]
mov r8, [rax+28h]
mov rax, [rbp+var_48]
mov rax, [rax]
mov rdx, [rbp+var_68]
sub rax, rdx
mov r15, rax
shr r15, 3Fh
add r15, rax
and r15, 0FFFFFFFFFFFFFFFEh
add r15, rdx
lea rsi, [rbp+var_30]
mov rcx, r15
mov [rbp+var_38], r8
call r8
test eax, eax
jle short loc_C8F19
lea rbx, [rbp+var_30]
mov r13, [rbp+var_68]
loc_C8EED:
mov rcx, r13
mov r13d, eax
add r13, rcx
mov r14, [rbp+var_30]
cmp r14, 20h ; ' '
jz short loc_C8F06
cmp r14, 9
jnz short loc_C8F3F
loc_C8F06:
mov rdi, r12
mov rsi, rbx
mov rdx, r13
mov rcx, r15
call [rbp+var_38]
test eax, eax
jg short loc_C8EED
loc_C8F19:
mov rax, [rbp+var_60]
mov dword ptr [rax], 21h ; '!'
mov rax, [rbp+var_48]
mov rcx, [rbp+var_68]
mov [rax], rcx
xor eax, eax
loc_C8F30:
add rsp, 68h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_C8F3F:
cmp r14, 2Dh ; '-'
jnz short loc_C8F85
mov rax, [rbp+var_60]
mov dword ptr [rax], 0FFFFFFFFh
lea rsi, [rbp+var_30]
mov rdi, r12
mov rdx, r13
mov rcx, r15
call [rbp+var_38]
test eax, eax
jle short loc_C8F19
mov eax, eax
add r13, rax
mov eax, 8
mov [rbp+var_70], rax
mov eax, 15F797AEh
mov [rbp+var_78], rax
mov eax, 57F5FF8h
mov [rbp+var_58], rax
jmp short loc_C8FCD
loc_C8F85:
mov rax, [rbp+var_60]
mov dword ptr [rax], 0
mov eax, 0Fh
mov [rbp+var_70], rax
mov eax, 2BEF2F5Ch
mov [rbp+var_78], rax
mov eax, 0AFEBFF0h
mov [rbp+var_58], rax
cmp r14, 2Bh ; '+'
jnz short loc_C8FCD
lea rsi, [rbp+var_30]
mov rdi, r12
mov rdx, r13
mov rcx, r15
call [rbp+var_38]
test eax, eax
jle loc_C8F19
mov eax, eax
add r13, rax
loc_C8FCD:
mov rax, [rbp+var_30]
cmp rax, 30h ; '0'
jnz short loc_C900F
cmp r13, r15
jz short loc_C9008
lea rbx, [rbp+var_30]
loc_C8FE0:
mov rdi, r12
mov rsi, rbx
mov rdx, r13
mov rcx, r15
call [rbp+var_38]
test eax, eax
jle loc_C8F19
cmp [rbp+var_30], 30h ; '0'
jnz short loc_C9026
mov eax, eax
add r13, rax
cmp r13, r15
jnz short loc_C8FE0
loc_C9008:
xor ebx, ebx
jmp loc_C91DC
loc_C900F:
add rax, 0FFFFFFFFFFFFFFD0h
cmp rax, 9
ja loc_C8F19
mov rbx, rax
lea rcx, [r13+10h]
jmp short loc_C902C
loc_C9026:
lea rcx, [r13+12h]
xor ebx, ebx
loc_C902C:
cmp rcx, r15
cmova rcx, r15
lea rsi, [rbp+var_30]
mov rdi, r12
mov rdx, r13
mov [rbp+var_40], rcx
loc_C9041:
call [rbp+var_38]
test eax, eax
jle short loc_C9082
mov rcx, [rbp+var_30]
cmp rcx, 39h ; '9'
ja loc_C91D9
add cl, 0D0h
cmp cl, 9
ja loc_C91D9
lea rdx, [rbx+rbx*4]
movzx ecx, cl
lea rbx, [rcx+rdx*2]
mov eax, eax
add r13, rax
mov rdi, r12
lea rsi, [rbp+var_30]
mov rdx, r13
mov rcx, [rbp+var_40]
jmp short loc_C9041
loc_C9082:
cmp r13, r15
jz loc_C91DC
mov [rbp+var_50], rbx
lea rax, [r13+12h]
cmp rax, r15
cmova rax, r15
mov [rbp+var_80], rax
xor ebx, ebx
xor esi, esi
loc_C90A2:
mov [rbp+var_40], rsi
lea rdx, [rbx+r13]
mov rdi, r12
lea rsi, [rbp+var_30]
mov [rbp+var_88], rdx
mov rcx, r15
call [rbp+var_38]
test eax, eax
jle loc_C8F19
mov rcx, [rbp+var_30]
cmp rcx, 39h ; '9'
ja loc_C91F6
add cl, 0D0h
cmp cl, 9
mov rsi, [rbp+var_40]
ja loc_C91FA
mov eax, eax
add rbx, rax
lea r8, [rbx+r13]
lea rax, [rsi+rsi*4]
movzx ecx, cl
lea rsi, [rcx+rax*2]
cmp r8, [rbp+var_80]
jnz short loc_C90A2
cmp [rbp+var_80], r15
jz loc_C9238
mov [rbp+var_40], rsi
lea rsi, [rbp+var_30]
mov rdi, r12
mov rbx, r8
mov rdx, r8
mov rcx, r15
call [rbp+var_38]
test eax, eax
jle loc_C8F19
mov r13, [rbp+var_30]
add r13, 0FFFFFFFFFFFFFFD0h
cmp r13, 9
mov rsi, [rbp+var_40]
mov r8, rbx
ja loc_C923E
mov eax, eax
add r8, rax
cmp r8, r15
jz loc_C9263
lea rsi, [rbp+var_30]
mov rdi, r12
mov rbx, r8
mov rdx, r8
mov rcx, r15
call [rbp+var_38]
test eax, eax
jle loc_C8F19
mov rcx, [rbp+var_30]
cmp rcx, 39h ; '9'
mov rsi, [rbp+var_40]
mov r8, rbx
ja loc_C9263
add cl, 0D0h
cmp cl, 9
ja loc_C9263
mov rbx, rcx
mov eax, eax
add r8, rax
mov rax, [rbp+var_48]
mov [rax], r8
cmp r8, r15
jz loc_C92C8
mov rdx, r8
lea rsi, [rbp+var_30]
mov rdi, r12
mov rcx, r15
call [rbp+var_38]
test eax, eax
jle loc_C92C8
mov eax, 0D0h
add eax, dword ptr [rbp+var_30]
and eax, 0FEh
cmp eax, 0Ah
mov rdx, [rbp+var_50]
jnb loc_C92CC
jmp loc_C92A0
loc_C91D9:
mov r15, r13
loc_C91DC:
mov rax, rbx
neg rax
cmp r14, 2Dh ; '-'
mov rcx, [rbp+var_48]
mov [rcx], r15
cmovnz rax, rbx
jmp loc_C8F30
loc_C91F6:
mov rsi, [rbp+var_40]
loc_C91FA:
mov r15, [rbp+var_88]
loc_C9201:
mov rax, r15
sub rax, r13
and rax, 0FFFFFFFFFFFFFFFEh
lea rcx, lfactor
mov rdx, [rbp+var_50]
imul rdx, [rcx+rax*4]
add rdx, rsi
mov rax, rdx
neg rax
cmp r14, 2Dh ; '-'
mov rcx, [rbp+var_48]
mov [rcx], r15
cmovnz rax, rdx
jmp loc_C8F30
loc_C9238:
cmp rbx, 12h
jnz short loc_C9201
loc_C923E:
imul rax, [rbp+var_50], 3B9ACA00h
add rsi, rax
mov rax, rsi
neg rax
cmp r14, 2Dh ; '-'
mov rcx, [rbp+var_48]
mov [rcx], r8
cmovnz rax, rsi
jmp loc_C8F30
loc_C9263:
mov rax, 2540BE400h
mov rcx, [rbp+var_50]
imul rcx, rax
lea rax, [rsi+rsi*4]
lea rax, [rcx+rax*2]
add rax, r13
mov rcx, [rbp+var_48]
mov [rcx], r8
cmp r14, 2Dh ; '-'
jnz loc_C8F30
mov rcx, 8000000000000000h
cmp rax, rcx
jbe short loc_C92C0
loc_C92A0:
xor eax, eax
cmp r14, 2Dh ; '-'
setnz al
mov rcx, [rbp+var_60]
mov dword ptr [rcx], 22h ; '"'
neg rax
bts rax, 3Fh ; '?'
jmp loc_C8F30
loc_C92C0:
neg rax
jmp loc_C8F30
loc_C92C8:
mov rdx, [rbp+var_50]
loc_C92CC:
cmp rdx, [rbp+var_58]
ja short loc_C92A0
lea rax, ds:0[r13*4]
add rax, r13
movzx ecx, bl
lea rax, [rcx+rax*2]
cmp rdx, [rbp+var_58]
jnz short loc_C92FA
mov rcx, [rbp+var_40]
cmp rcx, [rbp+var_78]
jb short loc_C92FA
cmp rax, [rbp+var_70]
ja short loc_C92A0
loc_C92FA:
mov rcx, 174876E800h
imul rdx, rcx
imul rcx, [rbp+var_40], 64h ; 'd'
add rdx, rax
add rdx, rcx
mov rax, rdx
jmp loc_C8F30
|
unsigned long long my_strtoll10_mb2(long long a1, long long a2, unsigned long long *a3, _DWORD *a4)
{
long long v4; // r12
unsigned long long v5; // r15
int v6; // eax
unsigned long long v7; // r13
long long v8; // r14
unsigned long long result; // rax
int v10; // eax
int v11; // eax
int v12; // eax
long long v13; // rbx
unsigned long long i; // rdx
int v15; // eax
unsigned long long v16; // rax
long long v17; // rbx
long long v18; // rsi
int v19; // eax
unsigned long long v20; // r8
unsigned long long v21; // rbx
int v22; // eax
long long v23; // r13
unsigned long long v24; // r8
unsigned long long v25; // rbx
int v26; // eax
unsigned __int8 v27; // bl
unsigned long long v28; // r8
unsigned long long v29; // rdx
long long v30; // rdx
long long v31; // rsi
unsigned long long v32; // rax
unsigned long long v33; // [rsp+10h] [rbp-80h]
unsigned long long v34; // [rsp+18h] [rbp-78h]
unsigned long long v35; // [rsp+20h] [rbp-70h]
unsigned long long v38; // [rsp+38h] [rbp-58h]
long long v39; // [rsp+40h] [rbp-50h]
long long v41; // [rsp+50h] [rbp-40h]
unsigned long long v42; // [rsp+50h] [rbp-40h]
long long ( *v43)(long long, _QWORD *, long long, unsigned long long); // [rsp+58h] [rbp-38h]
_QWORD v44[6]; // [rsp+60h] [rbp-30h] BYREF
if ( !a3 )
goto LABEL_7;
v4 = a1;
v5 = a2 + ((*a3 - a2 + ((*a3 - a2) >> 63)) & 0xFFFFFFFFFFFFFFFELL);
v43 = *(long long ( **)(long long, _QWORD *, long long, unsigned long long))(*(_QWORD *)(a1 + 184) + 40LL);
v6 = v43(a1, v44, a2, v5);
if ( v6 <= 0 )
goto LABEL_7;
v7 = a2;
while ( 1 )
{
v7 += (unsigned int)v6;
v8 = v44[0];
if ( v44[0] != 32LL && v44[0] != 9LL )
break;
v6 = v43(a1, v44, v7, v5);
if ( v6 <= 0 )
goto LABEL_7;
}
if ( v44[0] == 45LL )
{
*a4 = -1;
v10 = v43(a1, v44, v7, v5);
if ( v10 <= 0 )
goto LABEL_7;
v7 += (unsigned int)v10;
v35 = 8LL;
v34 = 368547758LL;
v38 = 92233720LL;
}
else
{
*a4 = 0;
v35 = 15LL;
v34 = 737095516LL;
v38 = 184467440LL;
if ( v8 == 43 )
{
v11 = v43(a1, v44, v7, v5);
if ( v11 <= 0 )
goto LABEL_7;
v7 += (unsigned int)v11;
}
}
if ( v44[0] == 48LL )
{
if ( v7 == v5 )
{
LABEL_20:
v13 = 0LL;
goto LABEL_49;
}
while ( 1 )
{
v12 = v43(a1, v44, v7, v5);
if ( v12 <= 0 )
goto LABEL_7;
if ( v44[0] != 48LL )
break;
v7 += (unsigned int)v12;
if ( v7 == v5 )
goto LABEL_20;
}
v13 = 0LL;
goto LABEL_24;
}
if ( (unsigned long long)(v44[0] - 48LL) > 9 )
{
LABEL_7:
*a4 = 33;
*a3 = a2;
return 0LL;
}
v13 = v44[0] - 48LL;
LABEL_24:
for ( i = v7; ; i = v7 )
{
v15 = ((long long ( *)(long long, _QWORD *, unsigned long long))v43)(a1, v44, i);
if ( v15 <= 0 )
break;
if ( v44[0] > 0x39uLL || (unsigned __int8)(LOBYTE(v44[0]) - 48) > 9u )
{
v5 = v7;
LABEL_49:
result = -v13;
*a3 = v5;
if ( v8 != 45 )
return v13;
return result;
}
v13 = (unsigned __int8)(LOBYTE(v44[0]) - 48) + 10 * v13;
v7 += (unsigned int)v15;
a1 = v4;
}
if ( v7 == v5 )
goto LABEL_49;
v39 = v13;
v16 = v7 + 18;
if ( v7 + 18 > v5 )
v16 = v5;
v33 = v16;
v17 = 0LL;
v18 = 0LL;
do
{
v41 = v18;
v19 = v43(v4, v44, v17 + v7, v5);
if ( v19 <= 0 )
goto LABEL_7;
if ( v44[0] > 0x39uLL || (unsigned __int8)(LOBYTE(v44[0]) - 48) > 9u )
{
v5 = v17 + v7;
goto LABEL_53;
}
v17 += (unsigned int)v19;
v20 = v17 + v7;
v18 = (unsigned __int8)(LOBYTE(v44[0]) - 48) + 10 * v18;
}
while ( v17 + v7 != v33 );
if ( v33 == v5 )
{
if ( v17 == 18 )
{
LABEL_57:
v31 = 1000000000 * v39 + v18;
result = -v31;
*a3 = v20;
if ( v8 != 45 )
return v31;
return result;
}
LABEL_53:
v30 = v18 + *(_QWORD *)((char *)&lfactor + 4 * ((v5 - v7) & 0xFFFFFFFFFFFFFFFELL)) * v39;
result = -v30;
*a3 = v5;
if ( v8 != 45 )
return v30;
return result;
}
v42 = (unsigned __int8)(LOBYTE(v44[0]) - 48) + 10 * v41;
v21 = v17 + v7;
v22 = v43(v4, v44, v20, v5);
if ( v22 <= 0 )
goto LABEL_7;
v23 = v44[0] - 48LL;
v20 = v21;
if ( (unsigned long long)(v44[0] - 48LL) > 9 )
goto LABEL_57;
v24 = (unsigned int)v22 + v21;
if ( v24 == v5 )
goto LABEL_60;
v25 = (unsigned int)v22 + v21;
v26 = v43(v4, v44, v24, v5);
if ( v26 <= 0 )
goto LABEL_7;
v24 = v25;
if ( v44[0] > 0x39uLL || (unsigned __int8)(LOBYTE(v44[0]) - 48) > 9u )
{
LABEL_60:
result = v23 + 10000000000LL * v39 + 10 * v18;
*a3 = v24;
if ( v8 != 45 )
return result;
if ( result > 0x8000000000000000LL )
goto LABEL_62;
return -(long long)result;
}
else
{
v27 = LOBYTE(v44[0]) - 48;
v28 = (unsigned int)v26 + v24;
*a3 = v28;
if ( v28 == v5 || (int)v43(v4, v44, v28, v5) <= 0 )
{
v29 = v39;
}
else
{
v29 = v39;
if ( ((LOBYTE(v44[0]) - 48) & 0xFEu) < 0xA )
{
LABEL_62:
*a4 = 34;
return -(long long)(v8 != 45) | 0x8000000000000000LL;
}
}
if ( v29 > v38 )
goto LABEL_62;
v32 = v27 + 10 * v23;
if ( v29 == v38 && v42 >= v34 && v32 > v35 )
goto LABEL_62;
return 100 * v42 + v32 + 100000000000LL * v29;
}
}
|
my_strtoll10_mb2:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x68
MOV qword ptr [RBP + -0x60],RCX
MOV qword ptr [RBP + -0x68],RSI
MOV qword ptr [RBP + -0x48],RDX
TEST RDX,RDX
JZ 0x001c8f19
MOV R12,RDI
MOV RAX,qword ptr [RDI + 0xb8]
MOV R8,qword ptr [RAX + 0x28]
MOV RAX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RAX]
MOV RDX,qword ptr [RBP + -0x68]
SUB RAX,RDX
MOV R15,RAX
SHR R15,0x3f
ADD R15,RAX
AND R15,-0x2
ADD R15,RDX
LEA RSI,[RBP + -0x30]
MOV RCX,R15
MOV qword ptr [RBP + -0x38],R8
CALL R8
TEST EAX,EAX
JLE 0x001c8f19
LEA RBX,[RBP + -0x30]
MOV R13,qword ptr [RBP + -0x68]
LAB_001c8eed:
MOV RCX,R13
MOV R13D,EAX
ADD R13,RCX
MOV R14,qword ptr [RBP + -0x30]
CMP R14,0x20
JZ 0x001c8f06
CMP R14,0x9
JNZ 0x001c8f3f
LAB_001c8f06:
MOV RDI,R12
MOV RSI,RBX
MOV RDX,R13
MOV RCX,R15
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JG 0x001c8eed
LAB_001c8f19:
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX],0x21
MOV RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x68]
MOV qword ptr [RAX],RCX
XOR EAX,EAX
LAB_001c8f30:
ADD RSP,0x68
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001c8f3f:
CMP R14,0x2d
JNZ 0x001c8f85
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX],0xffffffff
LEA RSI,[RBP + -0x30]
MOV RDI,R12
MOV RDX,R13
MOV RCX,R15
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JLE 0x001c8f19
MOV EAX,EAX
ADD R13,RAX
MOV EAX,0x8
MOV qword ptr [RBP + -0x70],RAX
MOV EAX,0x15f797ae
MOV qword ptr [RBP + -0x78],RAX
MOV EAX,0x57f5ff8
MOV qword ptr [RBP + -0x58],RAX
JMP 0x001c8fcd
LAB_001c8f85:
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX],0x0
MOV EAX,0xf
MOV qword ptr [RBP + -0x70],RAX
MOV EAX,0x2bef2f5c
MOV qword ptr [RBP + -0x78],RAX
MOV EAX,0xafebff0
MOV qword ptr [RBP + -0x58],RAX
CMP R14,0x2b
JNZ 0x001c8fcd
LEA RSI,[RBP + -0x30]
MOV RDI,R12
MOV RDX,R13
MOV RCX,R15
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JLE 0x001c8f19
MOV EAX,EAX
ADD R13,RAX
LAB_001c8fcd:
MOV RAX,qword ptr [RBP + -0x30]
CMP RAX,0x30
JNZ 0x001c900f
CMP R13,R15
JZ 0x001c9008
LEA RBX,[RBP + -0x30]
LAB_001c8fe0:
MOV RDI,R12
MOV RSI,RBX
MOV RDX,R13
MOV RCX,R15
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JLE 0x001c8f19
CMP qword ptr [RBP + -0x30],0x30
JNZ 0x001c9026
MOV EAX,EAX
ADD R13,RAX
CMP R13,R15
JNZ 0x001c8fe0
LAB_001c9008:
XOR EBX,EBX
JMP 0x001c91dc
LAB_001c900f:
ADD RAX,-0x30
CMP RAX,0x9
JA 0x001c8f19
MOV RBX,RAX
LEA RCX,[R13 + 0x10]
JMP 0x001c902c
LAB_001c9026:
LEA RCX,[R13 + 0x12]
XOR EBX,EBX
LAB_001c902c:
CMP RCX,R15
CMOVA RCX,R15
LEA RSI,[RBP + -0x30]
MOV RDI,R12
MOV RDX,R13
MOV qword ptr [RBP + -0x40],RCX
LAB_001c9041:
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JLE 0x001c9082
MOV RCX,qword ptr [RBP + -0x30]
CMP RCX,0x39
JA 0x001c91d9
ADD CL,0xd0
CMP CL,0x9
JA 0x001c91d9
LEA RDX,[RBX + RBX*0x4]
MOVZX ECX,CL
LEA RBX,[RCX + RDX*0x2]
MOV EAX,EAX
ADD R13,RAX
MOV RDI,R12
LEA RSI,[RBP + -0x30]
MOV RDX,R13
MOV RCX,qword ptr [RBP + -0x40]
JMP 0x001c9041
LAB_001c9082:
CMP R13,R15
JZ 0x001c91dc
MOV qword ptr [RBP + -0x50],RBX
LEA RAX,[R13 + 0x12]
CMP RAX,R15
CMOVA RAX,R15
MOV qword ptr [RBP + -0x80],RAX
XOR EBX,EBX
XOR ESI,ESI
LAB_001c90a2:
MOV qword ptr [RBP + -0x40],RSI
LEA RDX,[RBX + R13*0x1]
MOV RDI,R12
LEA RSI,[RBP + -0x30]
MOV qword ptr [RBP + -0x88],RDX
MOV RCX,R15
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JLE 0x001c8f19
MOV RCX,qword ptr [RBP + -0x30]
CMP RCX,0x39
JA 0x001c91f6
ADD CL,0xd0
CMP CL,0x9
MOV RSI,qword ptr [RBP + -0x40]
JA 0x001c91fa
MOV EAX,EAX
ADD RBX,RAX
LEA R8,[RBX + R13*0x1]
LEA RAX,[RSI + RSI*0x4]
MOVZX ECX,CL
LEA RSI,[RCX + RAX*0x2]
CMP R8,qword ptr [RBP + -0x80]
JNZ 0x001c90a2
CMP qword ptr [RBP + -0x80],R15
JZ 0x001c9238
MOV qword ptr [RBP + -0x40],RSI
LEA RSI,[RBP + -0x30]
MOV RDI,R12
MOV RBX,R8
MOV RDX,R8
MOV RCX,R15
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JLE 0x001c8f19
MOV R13,qword ptr [RBP + -0x30]
ADD R13,-0x30
CMP R13,0x9
MOV RSI,qword ptr [RBP + -0x40]
MOV R8,RBX
JA 0x001c923e
MOV EAX,EAX
ADD R8,RAX
CMP R8,R15
JZ 0x001c9263
LEA RSI,[RBP + -0x30]
MOV RDI,R12
MOV RBX,R8
MOV RDX,R8
MOV RCX,R15
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JLE 0x001c8f19
MOV RCX,qword ptr [RBP + -0x30]
CMP RCX,0x39
MOV RSI,qword ptr [RBP + -0x40]
MOV R8,RBX
JA 0x001c9263
ADD CL,0xd0
CMP CL,0x9
JA 0x001c9263
MOV RBX,RCX
MOV EAX,EAX
ADD R8,RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RAX],R8
CMP R8,R15
JZ 0x001c92c8
MOV RDX,R8
LEA RSI,[RBP + -0x30]
MOV RDI,R12
MOV RCX,R15
CALL qword ptr [RBP + -0x38]
TEST EAX,EAX
JLE 0x001c92c8
MOV EAX,0xd0
ADD EAX,dword ptr [RBP + -0x30]
AND EAX,0xfe
CMP EAX,0xa
MOV RDX,qword ptr [RBP + -0x50]
JNC 0x001c92cc
JMP 0x001c92a0
LAB_001c91d9:
MOV R15,R13
LAB_001c91dc:
MOV RAX,RBX
NEG RAX
CMP R14,0x2d
MOV RCX,qword ptr [RBP + -0x48]
MOV qword ptr [RCX],R15
CMOVNZ RAX,RBX
JMP 0x001c8f30
LAB_001c91f6:
MOV RSI,qword ptr [RBP + -0x40]
LAB_001c91fa:
MOV R15,qword ptr [RBP + -0x88]
LAB_001c9201:
MOV RAX,R15
SUB RAX,R13
AND RAX,-0x2
LEA RCX,[0x3db310]
MOV RDX,qword ptr [RBP + -0x50]
IMUL RDX,qword ptr [RCX + RAX*0x4]
ADD RDX,RSI
MOV RAX,RDX
NEG RAX
CMP R14,0x2d
MOV RCX,qword ptr [RBP + -0x48]
MOV qword ptr [RCX],R15
CMOVNZ RAX,RDX
JMP 0x001c8f30
LAB_001c9238:
CMP RBX,0x12
JNZ 0x001c9201
LAB_001c923e:
IMUL RAX,qword ptr [RBP + -0x50],0x3b9aca00
ADD RSI,RAX
MOV RAX,RSI
NEG RAX
CMP R14,0x2d
MOV RCX,qword ptr [RBP + -0x48]
MOV qword ptr [RCX],R8
CMOVNZ RAX,RSI
JMP 0x001c8f30
LAB_001c9263:
MOV RAX,0x2540be400
MOV RCX,qword ptr [RBP + -0x50]
IMUL RCX,RAX
LEA RAX,[RSI + RSI*0x4]
LEA RAX,[RCX + RAX*0x2]
ADD RAX,R13
MOV RCX,qword ptr [RBP + -0x48]
MOV qword ptr [RCX],R8
CMP R14,0x2d
JNZ 0x001c8f30
MOV RCX,-0x8000000000000000
CMP RAX,RCX
JBE 0x001c92c0
LAB_001c92a0:
XOR EAX,EAX
CMP R14,0x2d
SETNZ AL
MOV RCX,qword ptr [RBP + -0x60]
MOV dword ptr [RCX],0x22
NEG RAX
BTS RAX,0x3f
JMP 0x001c8f30
LAB_001c92c0:
NEG RAX
JMP 0x001c8f30
LAB_001c92c8:
MOV RDX,qword ptr [RBP + -0x50]
LAB_001c92cc:
CMP RDX,qword ptr [RBP + -0x58]
JA 0x001c92a0
LEA RAX,[R13*0x4]
ADD RAX,R13
MOVZX ECX,BL
LEA RAX,[RCX + RAX*0x2]
CMP RDX,qword ptr [RBP + -0x58]
JNZ 0x001c92fa
MOV RCX,qword ptr [RBP + -0x40]
CMP RCX,qword ptr [RBP + -0x78]
JC 0x001c92fa
CMP RAX,qword ptr [RBP + -0x70]
JA 0x001c92a0
LAB_001c92fa:
MOV RCX,0x174876e800
IMUL RDX,RCX
IMUL RCX,qword ptr [RBP + -0x40],0x64
ADD RDX,RAX
ADD RDX,RCX
MOV RAX,RDX
JMP 0x001c8f30
|
ulong my_strtoll10_mb2(long param_1,ulong param_2,ulong *param_3,int4 *param_4)
{
code *pcVar1;
long lVar2;
uint uVar3;
int iVar4;
ulong uVar5;
ulong uVar6;
byte bVar7;
long lVar8;
ulong uVar9;
ulong uVar10;
ulong uVar11;
ulong uVar12;
ulong uVar13;
ulong local_80;
ulong local_78;
ulong local_60;
int local_38;
int4 uStack_34;
if (param_3 != (ulong *)0x0) {
pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28);
uVar12 = ((*param_3 - param_2) - ((long)(*param_3 - param_2) >> 0x3f) & 0xfffffffffffffffe) +
param_2;
uVar3 = (*pcVar1)(param_1,&local_38,param_2,uVar12);
if (0 < (int)uVar3) {
uVar11 = param_2;
do {
uVar11 = uVar3 + uVar11;
lVar2 = CONCAT44(uStack_34,local_38);
if ((lVar2 != 0x20) && (lVar2 != 9)) {
if (lVar2 == 0x2d) {
*param_4 = 0xffffffff;
uVar3 = (*pcVar1)(param_1,&local_38,uVar11,uVar12);
if ((int)uVar3 < 1) break;
uVar11 = uVar11 + uVar3;
local_78 = 8;
local_80 = 0x15f797ae;
local_60 = 0x57f5ff8;
}
else {
*param_4 = 0;
local_78 = 0xf;
local_80 = 0x2bef2f5c;
local_60 = 0xafebff0;
if (lVar2 == 0x2b) {
uVar3 = (*pcVar1)(param_1,&local_38,uVar11,uVar12);
if ((int)uVar3 < 1) break;
uVar11 = uVar11 + uVar3;
}
}
if (CONCAT44(uStack_34,local_38) == 0x30) {
if (uVar11 == uVar12) goto LAB_001c9008;
goto LAB_001c8fe0;
}
uVar5 = CONCAT44(uStack_34,local_38) - 0x30;
if (uVar5 < 10) {
uVar9 = uVar11 + 0x10;
goto LAB_001c902c;
}
break;
}
uVar3 = (*pcVar1)(param_1,&local_38,uVar11,uVar12);
} while (0 < (int)uVar3);
}
}
LAB_001c8f19:
*param_4 = 0x21;
*param_3 = param_2;
return 0;
LAB_001c8fe0:
uVar3 = (*pcVar1)(param_1,&local_38,uVar11,uVar12);
if ((int)uVar3 < 1) goto LAB_001c8f19;
if (CONCAT44(uStack_34,local_38) != 0x30) {
uVar9 = uVar11 + 0x12;
uVar5 = 0;
LAB_001c902c:
if (uVar12 < uVar9) {
uVar9 = uVar12;
}
while (uVar3 = (*pcVar1)(param_1,&local_38,uVar11,uVar9), 0 < (int)uVar3) {
uVar6 = uVar11;
if ((0x39 < CONCAT44(uStack_34,local_38)) || (bVar7 = (char)local_38 - 0x30, 9 < bVar7))
goto LAB_001c91dc;
uVar5 = (ulong)bVar7 + uVar5 * 10;
uVar11 = uVar11 + uVar3;
}
uVar6 = uVar12;
if (uVar11 == uVar12) goto LAB_001c91dc;
uVar6 = uVar11 + 0x12;
if (uVar12 < uVar11 + 0x12) {
uVar6 = uVar12;
}
lVar8 = 0;
uVar9 = 0;
while( true ) {
uVar13 = lVar8 + uVar11;
uVar3 = (*pcVar1)(param_1,&local_38,uVar13,uVar12);
if ((int)uVar3 < 1) break;
if ((0x39 < CONCAT44(uStack_34,local_38)) || (bVar7 = (char)local_38 - 0x30, 9 < bVar7)) {
LAB_001c9201:
uVar9 = uVar5 * *(long *)((long)&lfactor + (uVar13 - uVar11 & 0xfffffffffffffffe) * 4) +
uVar9;
*param_3 = uVar13;
if (lVar2 == 0x2d) {
return -uVar9;
}
return uVar9;
}
lVar8 = lVar8 + (ulong)uVar3;
uVar10 = lVar8 + uVar11;
uVar9 = (ulong)bVar7 + uVar9 * 10;
if (uVar10 == uVar6) {
if (uVar6 == uVar12) {
uVar13 = uVar12;
if (lVar8 == 0x12) {
LAB_001c923e:
uVar9 = uVar9 + uVar5 * 1000000000;
*param_3 = uVar10;
if (lVar2 == 0x2d) {
return -uVar9;
}
return uVar9;
}
goto LAB_001c9201;
}
uVar3 = (*pcVar1)(param_1,&local_38,uVar10,uVar12);
if ((int)uVar3 < 1) break;
uVar11 = CONCAT44(uStack_34,local_38) - 0x30;
if (9 < uVar11) goto LAB_001c923e;
uVar10 = uVar10 + uVar3;
if (uVar10 != uVar12) {
uVar3 = (*pcVar1)(param_1,&local_38,uVar10,uVar12);
if ((int)uVar3 < 1) break;
if ((CONCAT44(uStack_34,local_38) < 0x3a) && (bVar7 = (char)local_38 - 0x30, bVar7 < 10))
{
uVar10 = uVar10 + uVar3;
*param_3 = uVar10;
if ((((uVar10 == uVar12) ||
(iVar4 = (*pcVar1)(param_1,&local_38,uVar10,uVar12), iVar4 < 1)) ||
(9 < (local_38 + 0xd0U & 0xfe))) &&
((uVar5 <= local_60 &&
(((uVar12 = (ulong)bVar7 + uVar11 * 10, uVar5 != local_60 || (uVar9 < local_80)) ||
(uVar12 <= local_78)))))) {
return uVar5 * 100000000000 + uVar12 + uVar9 * 100;
}
goto LAB_001c92a0;
}
}
uVar11 = uVar5 * 10000000000 + uVar9 * 10 + uVar11;
*param_3 = uVar10;
if (lVar2 != 0x2d) {
return uVar11;
}
if (uVar11 < 0x8000000000000001) {
return -uVar11;
}
LAB_001c92a0:
*param_4 = 0x22;
return -(ulong)(lVar2 != 0x2d) | 0x8000000000000000;
}
}
goto LAB_001c8f19;
}
uVar11 = uVar11 + uVar3;
if (uVar11 == uVar12) {
LAB_001c9008:
uVar5 = 0;
uVar6 = uVar12;
LAB_001c91dc:
*param_3 = uVar6;
if (lVar2 == 0x2d) {
return -uVar5;
}
return uVar5;
}
goto LAB_001c8fe0;
}
|
|
7,851 |
lunasvg::Element::render(lunasvg::Bitmap&, lunasvg::Matrix const&) const
|
dmazzella[P]pylunasvg/lunasvg/source/lunasvg.cpp
|
void Element::render(Bitmap& bitmap, const Matrix& matrix) const
{
if(m_node == nullptr || bitmap.isNull())
return;
auto canvas = Canvas::create(bitmap);
SVGRenderState state(nullptr, nullptr, matrix, SVGRenderMode::Painting, canvas);
element(true)->render(state);
}
|
O0
|
cpp
|
lunasvg::Element::render(lunasvg::Bitmap&, lunasvg::Matrix const&) const:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0xa8(%rbp)
cmpq $0x0, (%rax)
je 0xd5c7
movq -0x10(%rbp), %rdi
callq 0xbec0
testb $0x1, %al
jne 0xd5c7
jmp 0xd5cc
jmp 0xd66f
movq -0x10(%rbp), %rsi
leaq -0x28(%rbp), %rdi
callq 0x13440
movq -0x18(%rbp), %rsi
leaq -0x80(%rbp), %rdi
callq 0x117f0
jmp 0xd5e8
leaq -0xa0(%rbp), %rdi
movq %rdi, -0xb0(%rbp)
leaq -0x28(%rbp), %rsi
callq 0xe750
movq -0xb0(%rbp), %r9
xorl %r8d, %r8d
movl %r8d, %edx
leaq -0x68(%rbp), %rdi
leaq -0x80(%rbp), %rcx
movq %rdx, %rsi
callq 0xe780
jmp 0xd61e
leaq -0xa0(%rbp), %rdi
callq 0xe7f0
movq -0xa8(%rbp), %rdi
movl $0x1, %esi
callq 0xd470
movq %rax, -0xb8(%rbp)
jmp 0xd644
movq -0xb8(%rbp), %rdi
movq (%rdi), %rax
movq 0x88(%rax), %rax
leaq -0x68(%rbp), %rsi
callq *%rax
jmp 0xd65d
leaq -0x68(%rbp), %rdi
callq 0xe810
leaq -0x28(%rbp), %rdi
callq 0xe7f0
addq $0xc0, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
jmp 0xd6c7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
leaq -0xa0(%rbp), %rdi
callq 0xe7f0
jmp 0xd6c7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x88(%rbp)
movl %eax, -0x8c(%rbp)
leaq -0x68(%rbp), %rdi
callq 0xe810
leaq -0x28(%rbp), %rdi
callq 0xe7f0
movq -0x88(%rbp), %rdi
callq 0xb6c0
nopl (%rax)
|
_ZNK7lunasvg7Element6renderERNS_6BitmapERKNS_6MatrixE:
push rbp
mov rbp, rsp
sub rsp, 0C0h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov rax, [rbp+var_8]
mov [rbp+var_A8], rax
cmp qword ptr [rax], 0
jz short loc_D5C7
mov rdi, [rbp+var_10]; this
call _ZNK7lunasvg6Bitmap6isNullEv; lunasvg::Bitmap::isNull(void)
test al, 1
jnz short loc_D5C7
jmp short loc_D5CC
loc_D5C7:
jmp loc_D66F
loc_D5CC:
mov rsi, [rbp+var_10]; lunasvg::Bitmap *
lea rdi, [rbp+var_28]; this
call _ZN7lunasvg6Canvas6createERKNS_6BitmapE; lunasvg::Canvas::create(lunasvg::Bitmap const&)
mov rsi, [rbp+var_18]; lunasvg::Matrix *
lea rdi, [rbp+var_80]; this
call _ZN7lunasvg9TransformC2ERKNS_6MatrixE; lunasvg::Transform::Transform(lunasvg::Matrix const&)
jmp short $+2
loc_D5E8:
lea rdi, [rbp+var_A0]
mov [rbp+var_B0], rdi
lea rsi, [rbp+var_28]
call _ZNSt10shared_ptrIN7lunasvg6CanvasEEC2ERKS2_; std::shared_ptr<lunasvg::Canvas>::shared_ptr(std::shared_ptr<lunasvg::Canvas> const&)
mov r9, [rbp+var_B0]
xor r8d, r8d
mov edx, r8d
lea rdi, [rbp+var_68]
lea rcx, [rbp+var_80]
mov rsi, rdx
call _ZN7lunasvg14SVGRenderStateC2EPKNS_10SVGElementEPKS0_RKNS_9TransformENS_13SVGRenderModeESt10shared_ptrINS_6CanvasEE; lunasvg::SVGRenderState::SVGRenderState(lunasvg::SVGElement const*,lunasvg::SVGRenderState const*,lunasvg::Transform const&,lunasvg::SVGRenderMode,std::shared_ptr<lunasvg::Canvas>)
jmp short $+2
loc_D61E:
lea rdi, [rbp+var_A0]
call _ZNSt10shared_ptrIN7lunasvg6CanvasEED2Ev; std::shared_ptr<lunasvg::Canvas>::~shared_ptr()
mov rdi, [rbp+var_A8]; this
mov esi, 1; bool
call _ZNK7lunasvg7Element7elementEb; lunasvg::Element::element(bool)
mov [rbp+var_B8], rax
jmp short $+2
loc_D644:
mov rdi, [rbp+var_B8]
mov rax, [rdi]
mov rax, [rax+88h]
lea rsi, [rbp+var_68]
call rax
jmp short $+2
loc_D65D:
lea rdi, [rbp+var_68]; this
call _ZN7lunasvg14SVGRenderStateD2Ev; lunasvg::SVGRenderState::~SVGRenderState()
lea rdi, [rbp+var_28]
call _ZNSt10shared_ptrIN7lunasvg6CanvasEED2Ev; std::shared_ptr<lunasvg::Canvas>::~shared_ptr()
loc_D66F:
add rsp, 0C0h
pop rbp
retn
mov rcx, rax
mov eax, edx
mov [rbp+var_88], rcx
mov [rbp+var_8C], eax
jmp short loc_D6C7
mov rcx, rax
mov eax, edx
mov [rbp+var_88], rcx
mov [rbp+var_8C], eax
lea rdi, [rbp+var_A0]
call _ZNSt10shared_ptrIN7lunasvg6CanvasEED2Ev; std::shared_ptr<lunasvg::Canvas>::~shared_ptr()
jmp short loc_D6C7
mov rcx, rax
mov eax, edx
mov [rbp+var_88], rcx
mov [rbp+var_8C], eax
lea rdi, [rbp+var_68]; this
call _ZN7lunasvg14SVGRenderStateD2Ev; lunasvg::SVGRenderState::~SVGRenderState()
loc_D6C7:
lea rdi, [rbp+var_28]
call _ZNSt10shared_ptrIN7lunasvg6CanvasEED2Ev; std::shared_ptr<lunasvg::Canvas>::~shared_ptr()
mov rdi, [rbp+var_88]
call __Unwind_Resume
|
char lunasvg::Element::render(lunasvg::SVGNode **this, lunasvg::Bitmap *a2, const lunasvg::Matrix *a3)
{
char result; // al
lunasvg::SVGNode *v4; // [rsp+8h] [rbp-B8h]
_BYTE v5[20]; // [rsp+20h] [rbp-A0h] BYREF
_BYTE v6[24]; // [rsp+40h] [rbp-80h] BYREF
_BYTE v7[64]; // [rsp+58h] [rbp-68h] BYREF
_BYTE v8[16]; // [rsp+98h] [rbp-28h] BYREF
lunasvg::Matrix *v9; // [rsp+A8h] [rbp-18h]
lunasvg::Bitmap *v10; // [rsp+B0h] [rbp-10h]
lunasvg::SVGNode **v11; // [rsp+B8h] [rbp-8h]
v11 = this;
v10 = a2;
v9 = a3;
result = (char)this;
if ( *this )
{
result = lunasvg::Bitmap::isNull(v10);
if ( (result & 1) == 0 )
{
lunasvg::Canvas::create((lunasvg::Canvas *)v8, v10);
lunasvg::Transform::Transform((lunasvg::Transform *)v6, v9);
std::shared_ptr<lunasvg::Canvas>::shared_ptr(v5, v8);
lunasvg::SVGRenderState::SVGRenderState(v7, 0LL, 0LL, v6, 0LL, v5);
std::shared_ptr<lunasvg::Canvas>::~shared_ptr(v5);
v4 = lunasvg::Element::element(this, 1);
(*(void ( **)(lunasvg::SVGNode *, _BYTE *))(*(_QWORD *)v4 + 136LL))(v4, v7);
lunasvg::SVGRenderState::~SVGRenderState((lunasvg::SVGRenderState *)v7);
return std::shared_ptr<lunasvg::Canvas>::~shared_ptr(v8);
}
}
return result;
}
|
render:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xc0
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0xa8],RAX
CMP qword ptr [RAX],0x0
JZ 0x0010d5c7
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0010bec0
TEST AL,0x1
JNZ 0x0010d5c7
JMP 0x0010d5cc
LAB_0010d5c7:
JMP 0x0010d66f
LAB_0010d5cc:
MOV RSI,qword ptr [RBP + -0x10]
LEA RDI,[RBP + -0x28]
CALL 0x00113440
MOV RSI,qword ptr [RBP + -0x18]
LAB_0010d5dd:
LEA RDI,[RBP + -0x80]
CALL 0x001117f0
JMP 0x0010d5e8
LAB_0010d5e8:
LEA RDI,[RBP + -0xa0]
MOV qword ptr [RBP + -0xb0],RDI
LEA RSI,[RBP + -0x28]
CALL 0x0010e750
MOV R9,qword ptr [RBP + -0xb0]
LAB_0010d606:
XOR R8D,R8D
MOV EDX,R8D
LEA RDI,[RBP + -0x68]
LEA RCX,[RBP + -0x80]
MOV RSI,RDX
CALL 0x0010e780
JMP 0x0010d61e
LAB_0010d61e:
LEA RDI,[RBP + -0xa0]
CALL 0x0010e7f0
MOV RDI,qword ptr [RBP + -0xa8]
LAB_0010d631:
MOV ESI,0x1
CALL 0x0010d470
MOV qword ptr [RBP + -0xb8],RAX
JMP 0x0010d644
LAB_0010d644:
MOV RDI,qword ptr [RBP + -0xb8]
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX + 0x88]
LEA RSI,[RBP + -0x68]
CALL RAX
LAB_0010d65b:
JMP 0x0010d65d
LAB_0010d65d:
LEA RDI,[RBP + -0x68]
CALL 0x0010e810
LEA RDI,[RBP + -0x28]
CALL 0x0010e7f0
LAB_0010d66f:
ADD RSP,0xc0
POP RBP
RET
|
/* lunasvg::Element::render(lunasvg::Bitmap&, lunasvg::Matrix const&) const */
void __thiscall lunasvg::Element::render(Element *this,Bitmap *param_1,Matrix *param_2)
{
ulong uVar1;
long *plVar2;
shared_ptr<lunasvg::Canvas> local_a8 [32];
Transform local_88 [24];
SVGRenderState local_70 [64];
Canvas local_30 [16];
Matrix *local_20;
Bitmap *local_18;
Element *local_10;
if ((*(long *)this != 0) &&
(local_20 = param_2, local_18 = param_1, local_10 = this, uVar1 = Bitmap::isNull(param_1),
(uVar1 & 1) == 0)) {
Canvas::create(local_30,local_18);
/* try { // try from 0010d5dd to 0010d5e5 has its CatchHandler @ 0010d678 */
Transform::Transform(local_88,local_20);
std::shared_ptr<lunasvg::Canvas>::shared_ptr(local_a8,(shared_ptr *)local_30);
/* try { // try from 0010d606 to 0010d61b has its CatchHandler @ 0010d68c */
SVGRenderState::SVGRenderState(local_70,0,0,local_88,0,local_a8);
std::shared_ptr<lunasvg::Canvas>::~shared_ptr(local_a8);
/* try { // try from 0010d631 to 0010d65a has its CatchHandler @ 0010d6ac */
plVar2 = (long *)element(this,true);
(**(code **)(*plVar2 + 0x88))(plVar2,local_70);
SVGRenderState::~SVGRenderState(local_70);
std::shared_ptr<lunasvg::Canvas>::~shared_ptr((shared_ptr<lunasvg::Canvas> *)local_30);
}
return;
}
|
|
7,852 |
lunasvg::Element::render(lunasvg::Bitmap&, lunasvg::Matrix const&) const
|
dmazzella[P]pylunasvg/lunasvg/source/lunasvg.cpp
|
void Element::render(Bitmap& bitmap, const Matrix& matrix) const
{
if(m_node == nullptr || bitmap.isNull())
return;
auto canvas = Canvas::create(bitmap);
SVGRenderState state(nullptr, nullptr, matrix, SVGRenderMode::Painting, canvas);
element(true)->render(state);
}
|
O1
|
cpp
|
lunasvg::Element::render(lunasvg::Bitmap&, lunasvg::Matrix const&) const:
pushq %r14
pushq %rbx
subq $0x68, %rsp
cmpq $0x0, (%rdi)
je 0xba4e
cmpq $0x0, (%rsi)
je 0xba4e
movq %rdx, %r14
movq %rdi, %rbx
movq %rsp, %rdi
callq 0xd886
leaq 0x50(%rsp), %rdi
movq %r14, %rsi
callq 0xc8f8
movq (%rsp), %rax
movq 0x8(%rsp), %rcx
testq %rcx, %rcx
je 0xb9dd
movq 0x505f9(%rip), %rdx # 0x5bfc8
cmpb $0x0, (%rdx)
je 0xb9d9
incl 0x8(%rcx)
jmp 0xb9dd
lock
incl 0x8(%rcx)
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movups 0x50(%rsp), %xmm0
movaps %xmm0, 0x20(%rsp)
movq 0x60(%rsp), %rdx
movq %rdx, 0x30(%rsp)
movl $0x0, 0x38(%rsp)
movq %rax, 0x40(%rsp)
movq %rcx, 0x48(%rsp)
movq (%rbx), %rbx
testq %rbx, %rbx
je 0xba1f
movq 0x8(%rbx), %rax
movq (%rax), %rdi
callq 0x10abe
movq (%rbx), %rax
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq *0x88(%rax)
movq 0x48(%rsp), %rdi
testq %rdi, %rdi
je 0xba3f
callq 0xc49a
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0xba4e
callq 0xc49a
addq $0x68, %rsp
popq %rbx
popq %r14
retq
movq %rax, %rbx
jmp 0xba6d
movq %rax, %rbx
movq 0x48(%rsp), %rdi
testq %rdi, %rdi
je 0xba6d
callq 0xc49a
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0xba7c
callq 0xc49a
movq %rbx, %rdi
callq 0xa5c0
|
_ZNK7lunasvg7Element6renderERNS_6BitmapERKNS_6MatrixE:
push r14
push rbx
sub rsp, 68h
cmp qword ptr [rdi], 0
jz loc_BA4E
cmp qword ptr [rsi], 0
jz loc_BA4E
mov r14, rdx
mov rbx, rdi
mov rdi, rsp; this
call _ZN7lunasvg6Canvas6createERKNS_6BitmapE; lunasvg::Canvas::create(lunasvg::Bitmap const&)
lea rdi, [rsp+78h+var_28]; this
mov rsi, r14; lunasvg::Matrix *
call _ZN7lunasvg9TransformC2ERKNS_6MatrixE; lunasvg::Transform::Transform(lunasvg::Matrix const&)
mov rax, [rsp+78h+var_78]
mov rcx, [rsp+78h+var_70]
test rcx, rcx
jz short loc_B9DD
mov rdx, cs:__libc_single_threaded_ptr
cmp byte ptr [rdx], 0
jz short loc_B9D9
inc dword ptr [rcx+8]
jmp short loc_B9DD
loc_B9D9:
lock inc dword ptr [rcx+8]
loc_B9DD:
xorps xmm0, xmm0
movaps [rsp+78h+var_68], xmm0
movups xmm0, [rsp+78h+var_28]
movaps [rsp+78h+var_58], xmm0
mov rdx, [rsp+78h+var_18]
mov [rsp+78h+var_48], rdx
mov [rsp+78h+var_40], 0
mov [rsp+78h+var_38], rax
mov [rsp+78h+var_30], rcx
mov rbx, [rbx]
test rbx, rbx
jz short loc_BA1F
mov rax, [rbx+8]
mov rdi, [rax]; this
call _ZN7lunasvg14SVGRootElement12updateLayoutEv; lunasvg::SVGRootElement::updateLayout(void)
loc_BA1F:
mov rax, [rbx]
lea rsi, [rsp+78h+var_68]
mov rdi, rbx
call qword ptr [rax+88h]
mov rdi, [rsp+78h+var_30]
test rdi, rdi
jz short loc_BA3F
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_BA3F:
mov rdi, [rsp+78h+var_70]
test rdi, rdi
jz short loc_BA4E
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_BA4E:
add rsp, 68h
pop rbx
pop r14
retn
mov rbx, rax
jmp short loc_BA6D
mov rbx, rax
mov rdi, [rsp+arg_40]
test rdi, rdi
jz short loc_BA6D
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_BA6D:
mov rdi, [rsp+arg_0]
test rdi, rdi
jz short loc_BA7C
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_BA7C:
mov rdi, rbx
call __Unwind_Resume
|
void lunasvg::Element::render(
lunasvg::SVGRootElement ****this,
lunasvg::Bitmap *a2,
const lunasvg::Matrix *a3)
{
long long v4; // rax
long long v5; // rcx
lunasvg::SVGRootElement ***v6; // rbx
long long v7; // [rsp+0h] [rbp-78h] BYREF
long long v8; // [rsp+8h] [rbp-70h]
_OWORD v9[2]; // [rsp+10h] [rbp-68h] BYREF
long long v10; // [rsp+30h] [rbp-48h]
int v11; // [rsp+38h] [rbp-40h]
long long v12; // [rsp+40h] [rbp-38h]
long long v13; // [rsp+48h] [rbp-30h]
__int128 v14; // [rsp+50h] [rbp-28h] BYREF
long long v15; // [rsp+60h] [rbp-18h]
if ( *this && *(_QWORD *)a2 )
{
lunasvg::Canvas::create((lunasvg::Canvas *)&v7, a2);
lunasvg::Transform::Transform((lunasvg::Transform *)&v14, a3);
v4 = v7;
v5 = v8;
if ( v8 )
{
if ( _libc_single_threaded )
++*(_DWORD *)(v8 + 8);
else
_InterlockedIncrement((volatile signed __int32 *)(v8 + 8));
}
v9[0] = 0LL;
v9[1] = v14;
v10 = v15;
v11 = 0;
v12 = v4;
v13 = v5;
v6 = *this;
if ( *this )
lunasvg::SVGRootElement::updateLayout(*v6[1]);
((void ( *)(lunasvg::SVGRootElement ***, _OWORD *))(*v6)[17])(v6, v9);
if ( v13 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release();
if ( v8 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release();
}
}
|
render:
PUSH R14
PUSH RBX
SUB RSP,0x68
CMP qword ptr [RDI],0x0
JZ 0x0010ba4e
CMP qword ptr [RSI],0x0
JZ 0x0010ba4e
MOV R14,RDX
MOV RBX,RDI
MOV RDI,RSP
CALL 0x0010d886
LAB_0010b9ad:
LEA RDI,[RSP + 0x50]
MOV RSI,R14
CALL 0x0010c8f8
MOV RAX,qword ptr [RSP]
MOV RCX,qword ptr [RSP + 0x8]
TEST RCX,RCX
JZ 0x0010b9dd
MOV RDX,qword ptr [0x0015bfc8]
CMP byte ptr [RDX],0x0
JZ 0x0010b9d9
INC dword ptr [RCX + 0x8]
JMP 0x0010b9dd
LAB_0010b9d9:
INC.LOCK dword ptr [RCX + 0x8]
LAB_0010b9dd:
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP + 0x10],XMM0
MOVUPS XMM0,xmmword ptr [RSP + 0x50]
MOVAPS xmmword ptr [RSP + 0x20],XMM0
MOV RDX,qword ptr [RSP + 0x60]
MOV qword ptr [RSP + 0x30],RDX
MOV dword ptr [RSP + 0x38],0x0
MOV qword ptr [RSP + 0x40],RAX
MOV qword ptr [RSP + 0x48],RCX
MOV RBX,qword ptr [RBX]
TEST RBX,RBX
JZ 0x0010ba1f
MOV RAX,qword ptr [RBX + 0x8]
MOV RDI,qword ptr [RAX]
LAB_0010ba1a:
CALL 0x00110abe
LAB_0010ba1f:
MOV RAX,qword ptr [RBX]
LEA RSI,[RSP + 0x10]
MOV RDI,RBX
CALL qword ptr [RAX + 0x88]
LAB_0010ba30:
MOV RDI,qword ptr [RSP + 0x48]
TEST RDI,RDI
JZ 0x0010ba3f
CALL 0x0010c49a
LAB_0010ba3f:
MOV RDI,qword ptr [RSP + 0x8]
TEST RDI,RDI
JZ 0x0010ba4e
CALL 0x0010c49a
LAB_0010ba4e:
ADD RSP,0x68
POP RBX
POP R14
RET
|
/* lunasvg::Element::render(lunasvg::Bitmap&, lunasvg::Matrix const&) const */
void __thiscall lunasvg::Element::render(Element *this,Bitmap *param_1,Matrix *param_2)
{
long *plVar1;
int8 local_78;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_70;
int8 local_68;
int8 uStack_60;
int4 local_58;
int4 uStack_54;
int4 uStack_50;
int4 uStack_4c;
int8 local_48;
int4 local_40;
int8 local_38;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_30;
int4 local_28;
int4 uStack_24;
int4 uStack_20;
int4 uStack_1c;
int8 local_18;
if ((*(long *)this != 0) && (*(long *)param_1 != 0)) {
Canvas::create((Canvas *)&local_78,param_1);
/* try { // try from 0010b9ad to 0010b9b9 has its CatchHandler @ 0010ba56 */
Transform::Transform((Transform *)&local_28,param_2);
if (local_70 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
if (*PTR___libc_single_threaded_0015bfc8 == '\0') {
LOCK();
*(int *)(local_70 + 8) = *(int *)(local_70 + 8) + 1;
UNLOCK();
}
else {
*(int *)(local_70 + 8) = *(int *)(local_70 + 8) + 1;
}
}
local_68 = 0;
uStack_60 = 0;
local_58 = local_28;
uStack_54 = uStack_24;
uStack_50 = uStack_20;
uStack_4c = uStack_1c;
local_48 = local_18;
local_40 = 0;
local_38 = local_78;
local_30 = local_70;
plVar1 = *(long **)this;
if (plVar1 != (long *)0x0) {
/* try { // try from 0010ba1a to 0010ba2f has its CatchHandler @ 0010ba5b */
SVGRootElement::updateLayout(*(SVGRootElement **)plVar1[1]);
}
(**(code **)(*plVar1 + 0x88))(plVar1,&local_68);
if (local_30 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_30);
}
if (local_70 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_70);
}
}
return;
}
|
|
7,853 |
my_numcells_cp932
|
eloqsql/strings/ctype-cp932.c
|
static
size_t my_numcells_cp932(CHARSET_INFO *cs __attribute__((unused)),
const char *str, const char *str_end)
{
size_t clen= 0;
const uchar *b= (const uchar *) str;
const uchar *e= (const uchar *) str_end;
for (clen= 0; b < e; )
{
if (*b >= 0xA1 && *b <= 0xDF)
{
clen++;
b++;
}
else if (*b > 0x7F)
{
clen+= 2;
b+= 2;
}
else
{
clen++;
b++;
}
}
return clen;
}
|
O0
|
c
|
my_numcells_cp932:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x30(%rbp), %rax
jae 0x39395
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0xa1, %eax
jl 0x39350
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0xdf, %eax
jg 0x39350
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x39390
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x7f, %eax
jle 0x39376
movq -0x20(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
jmp 0x3938e
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x39390
jmp 0x39310
movq -0x20(%rbp), %rax
popq %rbp
retq
nopl (%rax,%rax)
|
my_numcells_cp932:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], 0
mov rax, [rbp+var_10]
mov [rbp+var_28], rax
mov rax, [rbp+var_18]
mov [rbp+var_30], rax
mov [rbp+var_20], 0
loc_39310:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_30]
jnb short loc_39395
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 0A1h
jl short loc_39350
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 0DFh
jg short loc_39350
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 1
mov [rbp+var_28], rax
jmp short loc_39390
loc_39350:
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 7Fh
jle short loc_39376
mov rax, [rbp+var_20]
add rax, 2
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
jmp short loc_3938E
loc_39376:
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 1
mov [rbp+var_28], rax
loc_3938E:
jmp short $+2
loc_39390:
jmp loc_39310
loc_39395:
mov rax, [rbp+var_20]
pop rbp
retn
|
long long my_numcells_cp932(long long a1, unsigned __int8 *a2, unsigned long long a3)
{
long long v5; // [rsp+10h] [rbp-20h]
v5 = 0LL;
while ( (unsigned long long)a2 < a3 )
{
if ( *a2 < 0xA1u || *a2 > 0xDFu )
{
if ( *a2 <= 0x7Fu )
{
++v5;
++a2;
}
else
{
v5 += 2LL;
a2 += 2;
}
}
else
{
++v5;
++a2;
}
}
return v5;
}
|
my_numcells_cp932:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
MOV qword ptr [RBP + -0x20],0x0
LAB_00139310:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNC 0x00139395
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xa1
JL 0x00139350
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xdf
JG 0x00139350
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x1
MOV qword ptr [RBP + -0x28],RAX
JMP 0x00139390
LAB_00139350:
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x7f
JLE 0x00139376
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
JMP 0x0013938e
LAB_00139376:
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x1
MOV qword ptr [RBP + -0x28],RAX
LAB_0013938e:
JMP 0x00139390
LAB_00139390:
JMP 0x00139310
LAB_00139395:
MOV RAX,qword ptr [RBP + -0x20]
POP RBP
RET
|
long my_numcells_cp932(int8 param_1,byte *param_2,byte *param_3)
{
byte *local_30;
long local_28;
local_28 = 0;
local_30 = param_2;
while (local_30 < param_3) {
if ((*local_30 < 0xa1) || (0xdf < *local_30)) {
if (*local_30 < 0x80) {
local_28 = local_28 + 1;
local_30 = local_30 + 1;
}
else {
local_28 = local_28 + 2;
local_30 = local_30 + 2;
}
}
else {
local_28 = local_28 + 1;
local_30 = local_30 + 1;
}
}
return local_28;
}
|
|
7,854 |
my_strnncoll_win1250ch
|
eloqsql/strings/ctype-win1250ch.c
|
static int my_strnncoll_win1250ch(CHARSET_INFO *cs __attribute__((unused)),
const uchar *s1, size_t len1,
const uchar *s2, size_t len2,
my_bool s2_is_prefix)
{
int v1, v2;
const uchar *p1, * p2;
int pass1 = 0, pass2 = 0;
int diff;
if (s2_is_prefix && len1 > len2)
len1=len2;
p1 = s1; p2 = s2;
do
{
NEXT_CMP_VALUE(s1, p1, pass1, v1, (int)len1);
NEXT_CMP_VALUE(s2, p2, pass2, v2, (int)len2);
if ((diff = v1 - v2))
return diff;
} while (v1);
return 0;
}
|
O0
|
c
|
my_strnncoll_win1250ch:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movb %r9b, %al
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movb %al, -0x31(%rbp)
movl $0x0, -0x54(%rbp)
movl $0x0, -0x58(%rbp)
movsbl -0x31(%rbp), %eax
cmpl $0x0, %eax
je 0x6c0fb
movq -0x20(%rbp), %rax
cmpq -0x30(%rbp), %rax
jbe 0x6c0fb
movq -0x30(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0x50(%rbp)
jmp 0x6c10d
movq -0x48(%rbp), %rax
movq -0x18(%rbp), %rcx
subq %rcx, %rax
movq -0x20(%rbp), %rcx
movslq %ecx, %rcx
cmpq %rcx, %rax
jl 0x6c154
cmpl $0x0, -0x54(%rbp)
jne 0x6c146
movq -0x20(%rbp), %rax
cmpl $0x0, %eax
jle 0x6c146
movq -0x18(%rbp), %rax
movq %rax, -0x48(%rbp)
movl -0x54(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x54(%rbp)
jmp 0x6c152
movl $0x0, -0x38(%rbp)
jmp 0x6c2c8
jmp 0x6c154
cmpl $0x0, -0x54(%rbp)
jne 0x6c176
movq -0x48(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %ecx
leaq 0x14a686(%rip), %rax # 0x1b67f0
movzbl (%rax,%rcx), %eax
movl %eax, -0x8c(%rbp)
jmp 0x6c190
movq -0x48(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %ecx
leaq 0x319eba(%rip), %rax # 0x386040
movzbl (%rax,%rcx), %eax
movl %eax, -0x8c(%rbp)
movl -0x8c(%rbp), %eax
movl %eax, -0x38(%rbp)
cmpl $0xff, -0x38(%rbp)
jne 0x6c2bc
movl $0x0, -0x60(%rbp)
cmpl $0x50, -0x60(%rbp)
jge 0x6c2ba
movslq -0x60(%rbp), %rcx
leaq 0x1623ae(%rip), %rax # 0x1ce570
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq %rax, -0x68(%rbp)
movq -0x48(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x68(%rbp), %rax
movzbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x8d(%rbp)
je 0x6c224
movq -0x70(%rbp), %rcx
movq -0x18(%rbp), %rax
subq %rax, %rcx
movq -0x20(%rbp), %rax
movslq %eax, %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
movb %al, -0x8d(%rbp)
jge 0x6c224
movq -0x68(%rbp), %rax
movzbl (%rax), %eax
movq -0x70(%rbp), %rcx
movzbl (%rcx), %ecx
cmpl %ecx, %eax
sete %al
movb %al, -0x8d(%rbp)
movb -0x8d(%rbp), %al
testb $0x1, %al
jne 0x6c230
jmp 0x6c24a
movq -0x68(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x68(%rbp)
movq -0x70(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x70(%rbp)
jmp 0x6c1d8
movq -0x68(%rbp), %rax
cmpb $0x0, (%rax)
jne 0x6c2aa
cmpl $0x0, -0x54(%rbp)
jne 0x6c277
movslq -0x60(%rbp), %rcx
leaq 0x16230c(%rip), %rax # 0x1ce570
shlq $0x4, %rcx
addq %rcx, %rax
movzbl 0x8(%rax), %eax
movl %eax, -0x94(%rbp)
jmp 0x6c293
movslq -0x60(%rbp), %rcx
leaq 0x1622ee(%rip), %rax # 0x1ce570
shlq $0x4, %rcx
addq %rcx, %rax
movzbl 0x9(%rax), %eax
movl %eax, -0x94(%rbp)
movl -0x94(%rbp), %eax
movl %eax, -0x38(%rbp)
movq -0x70(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0x6c2ba
jmp 0x6c2ac
movl -0x60(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x6c1ad
jmp 0x6c2bc
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0x6c2ca
movq -0x50(%rbp), %rax
movq -0x28(%rbp), %rcx
subq %rcx, %rax
movq -0x30(%rbp), %rcx
movslq %ecx, %rcx
cmpq %rcx, %rax
jl 0x6c311
cmpl $0x0, -0x58(%rbp)
jne 0x6c303
movq -0x30(%rbp), %rax
cmpl $0x0, %eax
jle 0x6c303
movq -0x28(%rbp), %rax
movq %rax, -0x50(%rbp)
movl -0x58(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x58(%rbp)
jmp 0x6c30f
movl $0x0, -0x3c(%rbp)
jmp 0x6c497
jmp 0x6c311
cmpl $0x0, -0x58(%rbp)
jne 0x6c333
movq -0x50(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %ecx
leaq 0x14a4c9(%rip), %rax # 0x1b67f0
movzbl (%rax,%rcx), %eax
movl %eax, -0x98(%rbp)
jmp 0x6c34d
movq -0x50(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %ecx
leaq 0x319cfd(%rip), %rax # 0x386040
movzbl (%rax,%rcx), %eax
movl %eax, -0x98(%rbp)
movl -0x98(%rbp), %eax
movl %eax, -0x3c(%rbp)
cmpl $0xff, -0x3c(%rbp)
jne 0x6c48b
movl $0x0, -0x74(%rbp)
cmpl $0x50, -0x74(%rbp)
jge 0x6c489
movslq -0x74(%rbp), %rcx
leaq 0x1621f1(%rip), %rax # 0x1ce570
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq %rax, -0x80(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x88(%rbp)
movq -0x80(%rbp), %rax
movzbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x99(%rbp)
je 0x6c3ea
movq -0x88(%rbp), %rcx
movq -0x28(%rbp), %rax
subq %rax, %rcx
movq -0x30(%rbp), %rax
movslq %eax, %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
movb %al, -0x99(%rbp)
jge 0x6c3ea
movq -0x80(%rbp), %rax
movzbl (%rax), %eax
movq -0x88(%rbp), %rcx
movzbl (%rcx), %ecx
cmpl %ecx, %eax
sete %al
movb %al, -0x99(%rbp)
movb -0x99(%rbp), %al
testb $0x1, %al
jne 0x6c3f6
jmp 0x6c416
movq -0x80(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x80(%rbp)
movq -0x88(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x88(%rbp)
jmp 0x6c398
movq -0x80(%rbp), %rax
cmpb $0x0, (%rax)
jne 0x6c479
cmpl $0x0, -0x58(%rbp)
jne 0x6c443
movslq -0x74(%rbp), %rcx
leaq 0x162140(%rip), %rax # 0x1ce570
shlq $0x4, %rcx
addq %rcx, %rax
movzbl 0x8(%rax), %eax
movl %eax, -0xa0(%rbp)
jmp 0x6c45f
movslq -0x74(%rbp), %rcx
leaq 0x162122(%rip), %rax # 0x1ce570
shlq $0x4, %rcx
addq %rcx, %rax
movzbl 0x9(%rax), %eax
movl %eax, -0xa0(%rbp)
movl -0xa0(%rbp), %eax
movl %eax, -0x3c(%rbp)
movq -0x88(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x50(%rbp)
jmp 0x6c489
jmp 0x6c47b
movl -0x74(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x74(%rbp)
jmp 0x6c36a
jmp 0x6c48b
movq -0x50(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x50(%rbp)
movl -0x38(%rbp), %eax
subl -0x3c(%rbp), %eax
movl %eax, -0x5c(%rbp)
cmpl $0x0, %eax
je 0x6c4ad
movl -0x5c(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x6c4c0
jmp 0x6c4af
cmpl $0x0, -0x38(%rbp)
jne 0x6c10b
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
|
my_strnncoll_win1250ch:
push rbp
mov rbp, rsp
sub rsp, 20h
mov al, r9b
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov [rbp+var_30], r8
mov [rbp+var_31], al
mov [rbp+var_54], 0
mov [rbp+var_58], 0
movsx eax, [rbp+var_31]
cmp eax, 0
jz short loc_6C0FB
mov rax, [rbp+var_20]
cmp rax, [rbp+var_30]
jbe short loc_6C0FB
mov rax, [rbp+var_30]
mov [rbp+var_20], rax
loc_6C0FB:
mov rax, [rbp+var_18]
mov [rbp+var_48], rax
mov rax, [rbp+var_28]
mov [rbp+var_50], rax
loc_6C10B:
jmp short $+2
loc_6C10D:
mov rax, [rbp+var_48]
mov rcx, [rbp+var_18]
sub rax, rcx
mov rcx, [rbp+var_20]
movsxd rcx, ecx
cmp rax, rcx
jl short loc_6C154
cmp [rbp+var_54], 0
jnz short loc_6C146
mov rax, [rbp+var_20]
cmp eax, 0
jle short loc_6C146
mov rax, [rbp+var_18]
mov [rbp+var_48], rax
mov eax, [rbp+var_54]
add eax, 1
mov [rbp+var_54], eax
jmp short loc_6C152
loc_6C146:
mov [rbp+var_38], 0
jmp loc_6C2C8
loc_6C152:
jmp short $+2
loc_6C154:
cmp [rbp+var_54], 0
jnz short loc_6C176
mov rax, [rbp+var_48]
movzx eax, byte ptr [rax]
mov ecx, eax
lea rax, _sort_order_win1250ch1
movzx eax, byte ptr [rax+rcx]
mov [rbp+var_8C], eax
jmp short loc_6C190
loc_6C176:
mov rax, [rbp+var_48]
movzx eax, byte ptr [rax]
mov ecx, eax
lea rax, _sort_order_win1250ch2
movzx eax, byte ptr [rax+rcx]
mov [rbp+var_8C], eax
loc_6C190:
mov eax, [rbp+var_8C]
mov [rbp+var_38], eax
cmp [rbp+var_38], 0FFh
jnz loc_6C2BC
mov [rbp+var_60], 0
loc_6C1AD:
cmp [rbp+var_60], 50h ; 'P'
jge loc_6C2BA
movsxd rcx, [rbp+var_60]
lea rax, doubles_0
shl rcx, 4
add rax, rcx
mov rax, [rax]
mov [rbp+var_68], rax
mov rax, [rbp+var_48]
mov [rbp+var_70], rax
loc_6C1D8:
mov rax, [rbp+var_68]
movzx ecx, byte ptr [rax]
xor eax, eax
cmp ecx, 0
mov [rbp+var_8D], al
jz short loc_6C224
mov rcx, [rbp+var_70]
mov rax, [rbp+var_18]
sub rcx, rax
mov rax, [rbp+var_20]
movsxd rdx, eax
xor eax, eax
cmp rcx, rdx
mov [rbp+var_8D], al
jge short loc_6C224
mov rax, [rbp+var_68]
movzx eax, byte ptr [rax]
mov rcx, [rbp+var_70]
movzx ecx, byte ptr [rcx]
cmp eax, ecx
setz al
mov [rbp+var_8D], al
loc_6C224:
mov al, [rbp+var_8D]
test al, 1
jnz short loc_6C230
jmp short loc_6C24A
loc_6C230:
mov rax, [rbp+var_68]
add rax, 1
mov [rbp+var_68], rax
mov rax, [rbp+var_70]
add rax, 1
mov [rbp+var_70], rax
jmp short loc_6C1D8
loc_6C24A:
mov rax, [rbp+var_68]
cmp byte ptr [rax], 0
jnz short loc_6C2AA
cmp [rbp+var_54], 0
jnz short loc_6C277
movsxd rcx, [rbp+var_60]
lea rax, doubles_0
shl rcx, 4
add rax, rcx
movzx eax, byte ptr [rax+8]
mov [rbp+var_94], eax
jmp short loc_6C293
loc_6C277:
movsxd rcx, [rbp+var_60]
lea rax, doubles_0
shl rcx, 4
add rax, rcx
movzx eax, byte ptr [rax+9]
mov [rbp+var_94], eax
loc_6C293:
mov eax, [rbp+var_94]
mov [rbp+var_38], eax
mov rax, [rbp+var_70]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_48], rax
jmp short loc_6C2BA
loc_6C2AA:
jmp short $+2
loc_6C2AC:
mov eax, [rbp+var_60]
add eax, 1
mov [rbp+var_60], eax
jmp loc_6C1AD
loc_6C2BA:
jmp short $+2
loc_6C2BC:
mov rax, [rbp+var_48]
add rax, 1
mov [rbp+var_48], rax
loc_6C2C8:
jmp short $+2
loc_6C2CA:
mov rax, [rbp+var_50]
mov rcx, [rbp+var_28]
sub rax, rcx
mov rcx, [rbp+var_30]
movsxd rcx, ecx
cmp rax, rcx
jl short loc_6C311
cmp [rbp+var_58], 0
jnz short loc_6C303
mov rax, [rbp+var_30]
cmp eax, 0
jle short loc_6C303
mov rax, [rbp+var_28]
mov [rbp+var_50], rax
mov eax, [rbp+var_58]
add eax, 1
mov [rbp+var_58], eax
jmp short loc_6C30F
loc_6C303:
mov [rbp+var_3C], 0
jmp loc_6C497
loc_6C30F:
jmp short $+2
loc_6C311:
cmp [rbp+var_58], 0
jnz short loc_6C333
mov rax, [rbp+var_50]
movzx eax, byte ptr [rax]
mov ecx, eax
lea rax, _sort_order_win1250ch1
movzx eax, byte ptr [rax+rcx]
mov [rbp+var_98], eax
jmp short loc_6C34D
loc_6C333:
mov rax, [rbp+var_50]
movzx eax, byte ptr [rax]
mov ecx, eax
lea rax, _sort_order_win1250ch2
movzx eax, byte ptr [rax+rcx]
mov [rbp+var_98], eax
loc_6C34D:
mov eax, [rbp+var_98]
mov [rbp+var_3C], eax
cmp [rbp+var_3C], 0FFh
jnz loc_6C48B
mov [rbp+var_74], 0
loc_6C36A:
cmp [rbp+var_74], 50h ; 'P'
jge loc_6C489
movsxd rcx, [rbp+var_74]
lea rax, doubles_0
shl rcx, 4
add rax, rcx
mov rax, [rax]
mov [rbp+var_80], rax
mov rax, [rbp+var_50]
mov [rbp+var_88], rax
loc_6C398:
mov rax, [rbp+var_80]
movzx ecx, byte ptr [rax]
xor eax, eax
cmp ecx, 0
mov [rbp+var_99], al
jz short loc_6C3EA
mov rcx, [rbp+var_88]
mov rax, [rbp+var_28]
sub rcx, rax
mov rax, [rbp+var_30]
movsxd rdx, eax
xor eax, eax
cmp rcx, rdx
mov [rbp+var_99], al
jge short loc_6C3EA
mov rax, [rbp+var_80]
movzx eax, byte ptr [rax]
mov rcx, [rbp+var_88]
movzx ecx, byte ptr [rcx]
cmp eax, ecx
setz al
mov [rbp+var_99], al
loc_6C3EA:
mov al, [rbp+var_99]
test al, 1
jnz short loc_6C3F6
jmp short loc_6C416
loc_6C3F6:
mov rax, [rbp+var_80]
add rax, 1
mov [rbp+var_80], rax
mov rax, [rbp+var_88]
add rax, 1
mov [rbp+var_88], rax
jmp short loc_6C398
loc_6C416:
mov rax, [rbp+var_80]
cmp byte ptr [rax], 0
jnz short loc_6C479
cmp [rbp+var_58], 0
jnz short loc_6C443
movsxd rcx, [rbp+var_74]
lea rax, doubles_0
shl rcx, 4
add rax, rcx
movzx eax, byte ptr [rax+8]
mov [rbp+var_A0], eax
jmp short loc_6C45F
loc_6C443:
movsxd rcx, [rbp+var_74]
lea rax, doubles_0
shl rcx, 4
add rax, rcx
movzx eax, byte ptr [rax+9]
mov [rbp+var_A0], eax
loc_6C45F:
mov eax, [rbp+var_A0]
mov [rbp+var_3C], eax
mov rax, [rbp+var_88]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_50], rax
jmp short loc_6C489
loc_6C479:
jmp short $+2
loc_6C47B:
mov eax, [rbp+var_74]
add eax, 1
mov [rbp+var_74], eax
jmp loc_6C36A
loc_6C489:
jmp short $+2
loc_6C48B:
mov rax, [rbp+var_50]
add rax, 1
mov [rbp+var_50], rax
loc_6C497:
mov eax, [rbp+var_38]
sub eax, [rbp+var_3C]
mov [rbp+var_5C], eax
cmp eax, 0
jz short loc_6C4AD
mov eax, [rbp+var_5C]
mov [rbp+var_4], eax
jmp short loc_6C4C0
loc_6C4AD:
jmp short $+2
loc_6C4AF:
cmp [rbp+var_38], 0
jnz loc_6C10B
mov [rbp+var_4], 0
loc_6C4C0:
mov eax, [rbp+var_4]
add rsp, 20h
pop rbp
retn
|
long long my_strnncoll_win1250ch(
long long a1,
unsigned __int8 *a2,
unsigned long long a3,
unsigned __int8 *a4,
unsigned long long a5,
char a6)
{
int v7; // [rsp+0h] [rbp-A0h]
bool v8; // [rsp+7h] [rbp-99h]
int v9; // [rsp+8h] [rbp-98h]
int v10; // [rsp+Ch] [rbp-94h]
bool v11; // [rsp+13h] [rbp-8Dh]
int v12; // [rsp+14h] [rbp-8Ch]
unsigned __int8 *m; // [rsp+18h] [rbp-88h]
_BYTE *v14; // [rsp+20h] [rbp-80h]
int k; // [rsp+2Ch] [rbp-74h]
unsigned __int8 *j; // [rsp+30h] [rbp-70h]
_BYTE *v17; // [rsp+38h] [rbp-68h]
int i; // [rsp+40h] [rbp-60h]
int v19; // [rsp+48h] [rbp-58h]
int v20; // [rsp+4Ch] [rbp-54h]
unsigned __int8 *v21; // [rsp+50h] [rbp-50h]
unsigned __int8 *v22; // [rsp+58h] [rbp-48h]
int v23; // [rsp+64h] [rbp-3Ch]
int v24; // [rsp+68h] [rbp-38h]
int v25; // [rsp+80h] [rbp-20h]
v25 = a3;
v20 = 0;
v19 = 0;
if ( a6 && a3 > a5 )
v25 = a5;
v22 = a2;
v21 = a4;
do
{
if ( v22 - a2 >= v25 )
{
if ( v20 || v25 <= 0 )
{
v24 = 0;
goto LABEL_29;
}
v22 = a2;
v20 = 1;
}
if ( v20 )
v12 = sort_order_win1250ch2[*v22];
else
v12 = sort_order_win1250ch1[*v22];
v24 = v12;
if ( v12 == 255 )
{
for ( i = 0; i < 80; ++i )
{
v17 = *(&doubles_0 + 2 * i);
for ( j = v22; ; ++j )
{
v11 = 0;
if ( *v17 )
{
v11 = 0;
if ( j - a2 < v25 )
v11 = (unsigned __int8)*v17 == *j;
}
if ( !v11 )
break;
++v17;
}
if ( !*v17 )
{
if ( v20 )
v10 = *((unsigned __int8 *)&doubles_0 + 16 * i + 9);
else
v10 = *((unsigned __int8 *)&doubles_0 + 16 * i + 8);
v24 = v10;
v22 = j - 1;
break;
}
}
}
++v22;
LABEL_29:
if ( v21 - a4 >= (int)a5 )
{
if ( v19 || (int)a5 <= 0 )
{
v23 = 0;
goto LABEL_53;
}
v21 = a4;
v19 = 1;
}
if ( v19 )
v9 = sort_order_win1250ch2[*v21];
else
v9 = sort_order_win1250ch1[*v21];
v23 = v9;
if ( v9 == 255 )
{
for ( k = 0; k < 80; ++k )
{
v14 = *(&doubles_0 + 2 * k);
for ( m = v21; ; ++m )
{
v8 = 0;
if ( *v14 )
{
v8 = 0;
if ( m - a4 < (int)a5 )
v8 = (unsigned __int8)*v14 == *m;
}
if ( !v8 )
break;
++v14;
}
if ( !*v14 )
{
if ( v19 )
v7 = *((unsigned __int8 *)&doubles_0 + 16 * k + 9);
else
v7 = *((unsigned __int8 *)&doubles_0 + 16 * k + 8);
v23 = v7;
v21 = m - 1;
break;
}
}
}
++v21;
LABEL_53:
if ( v24 != v23 )
return (unsigned int)(v24 - v23);
}
while ( v24 );
return 0;
}
|
my_strnncoll_win1250ch:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV AL,R9B
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 qword ptr [RBP + -0x30],R8
MOV byte ptr [RBP + -0x31],AL
MOV dword ptr [RBP + -0x54],0x0
MOV dword ptr [RBP + -0x58],0x0
MOVSX EAX,byte ptr [RBP + -0x31]
CMP EAX,0x0
JZ 0x0016c0fb
MOV RAX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RBP + -0x30]
JBE 0x0016c0fb
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x20],RAX
LAB_0016c0fb:
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x50],RAX
LAB_0016c10b:
JMP 0x0016c10d
LAB_0016c10d:
MOV RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x18]
SUB RAX,RCX
MOV RCX,qword ptr [RBP + -0x20]
MOVSXD RCX,ECX
CMP RAX,RCX
JL 0x0016c154
CMP dword ptr [RBP + -0x54],0x0
JNZ 0x0016c146
MOV RAX,qword ptr [RBP + -0x20]
CMP EAX,0x0
JLE 0x0016c146
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x48],RAX
MOV EAX,dword ptr [RBP + -0x54]
ADD EAX,0x1
MOV dword ptr [RBP + -0x54],EAX
JMP 0x0016c152
LAB_0016c146:
MOV dword ptr [RBP + -0x38],0x0
JMP 0x0016c2c8
LAB_0016c152:
JMP 0x0016c154
LAB_0016c154:
CMP dword ptr [RBP + -0x54],0x0
JNZ 0x0016c176
MOV RAX,qword ptr [RBP + -0x48]
MOVZX EAX,byte ptr [RAX]
MOV ECX,EAX
LEA RAX,[0x2b67f0]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV dword ptr [RBP + -0x8c],EAX
JMP 0x0016c190
LAB_0016c176:
MOV RAX,qword ptr [RBP + -0x48]
MOVZX EAX,byte ptr [RAX]
MOV ECX,EAX
LEA RAX,[0x486040]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV dword ptr [RBP + -0x8c],EAX
LAB_0016c190:
MOV EAX,dword ptr [RBP + -0x8c]
MOV dword ptr [RBP + -0x38],EAX
CMP dword ptr [RBP + -0x38],0xff
JNZ 0x0016c2bc
MOV dword ptr [RBP + -0x60],0x0
LAB_0016c1ad:
CMP dword ptr [RBP + -0x60],0x50
JGE 0x0016c2ba
MOVSXD RCX,dword ptr [RBP + -0x60]
LEA RAX,[0x2ce570]
SHL RCX,0x4
ADD RAX,RCX
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RBP + -0x70],RAX
LAB_0016c1d8:
MOV RAX,qword ptr [RBP + -0x68]
MOVZX ECX,byte ptr [RAX]
XOR EAX,EAX
CMP ECX,0x0
MOV byte ptr [RBP + -0x8d],AL
JZ 0x0016c224
MOV RCX,qword ptr [RBP + -0x70]
MOV RAX,qword ptr [RBP + -0x18]
SUB RCX,RAX
MOV RAX,qword ptr [RBP + -0x20]
MOVSXD RDX,EAX
XOR EAX,EAX
CMP RCX,RDX
MOV byte ptr [RBP + -0x8d],AL
JGE 0x0016c224
MOV RAX,qword ptr [RBP + -0x68]
MOVZX EAX,byte ptr [RAX]
MOV RCX,qword ptr [RBP + -0x70]
MOVZX ECX,byte ptr [RCX]
CMP EAX,ECX
SETZ AL
MOV byte ptr [RBP + -0x8d],AL
LAB_0016c224:
MOV AL,byte ptr [RBP + -0x8d]
TEST AL,0x1
JNZ 0x0016c230
JMP 0x0016c24a
LAB_0016c230:
MOV RAX,qword ptr [RBP + -0x68]
ADD RAX,0x1
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RBP + -0x70]
ADD RAX,0x1
MOV qword ptr [RBP + -0x70],RAX
JMP 0x0016c1d8
LAB_0016c24a:
MOV RAX,qword ptr [RBP + -0x68]
CMP byte ptr [RAX],0x0
JNZ 0x0016c2aa
CMP dword ptr [RBP + -0x54],0x0
JNZ 0x0016c277
MOVSXD RCX,dword ptr [RBP + -0x60]
LEA RAX,[0x2ce570]
SHL RCX,0x4
ADD RAX,RCX
MOVZX EAX,byte ptr [RAX + 0x8]
MOV dword ptr [RBP + -0x94],EAX
JMP 0x0016c293
LAB_0016c277:
MOVSXD RCX,dword ptr [RBP + -0x60]
LEA RAX,[0x2ce570]
SHL RCX,0x4
ADD RAX,RCX
MOVZX EAX,byte ptr [RAX + 0x9]
MOV dword ptr [RBP + -0x94],EAX
LAB_0016c293:
MOV EAX,dword ptr [RBP + -0x94]
MOV dword ptr [RBP + -0x38],EAX
MOV RAX,qword ptr [RBP + -0x70]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x48],RAX
JMP 0x0016c2ba
LAB_0016c2aa:
JMP 0x0016c2ac
LAB_0016c2ac:
MOV EAX,dword ptr [RBP + -0x60]
ADD EAX,0x1
MOV dword ptr [RBP + -0x60],EAX
JMP 0x0016c1ad
LAB_0016c2ba:
JMP 0x0016c2bc
LAB_0016c2bc:
MOV RAX,qword ptr [RBP + -0x48]
ADD RAX,0x1
MOV qword ptr [RBP + -0x48],RAX
LAB_0016c2c8:
JMP 0x0016c2ca
LAB_0016c2ca:
MOV RAX,qword ptr [RBP + -0x50]
MOV RCX,qword ptr [RBP + -0x28]
SUB RAX,RCX
MOV RCX,qword ptr [RBP + -0x30]
MOVSXD RCX,ECX
CMP RAX,RCX
JL 0x0016c311
CMP dword ptr [RBP + -0x58],0x0
JNZ 0x0016c303
MOV RAX,qword ptr [RBP + -0x30]
CMP EAX,0x0
JLE 0x0016c303
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x50],RAX
MOV EAX,dword ptr [RBP + -0x58]
ADD EAX,0x1
MOV dword ptr [RBP + -0x58],EAX
JMP 0x0016c30f
LAB_0016c303:
MOV dword ptr [RBP + -0x3c],0x0
JMP 0x0016c497
LAB_0016c30f:
JMP 0x0016c311
LAB_0016c311:
CMP dword ptr [RBP + -0x58],0x0
JNZ 0x0016c333
MOV RAX,qword ptr [RBP + -0x50]
MOVZX EAX,byte ptr [RAX]
MOV ECX,EAX
LEA RAX,[0x2b67f0]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV dword ptr [RBP + -0x98],EAX
JMP 0x0016c34d
LAB_0016c333:
MOV RAX,qword ptr [RBP + -0x50]
MOVZX EAX,byte ptr [RAX]
MOV ECX,EAX
LEA RAX,[0x486040]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV dword ptr [RBP + -0x98],EAX
LAB_0016c34d:
MOV EAX,dword ptr [RBP + -0x98]
MOV dword ptr [RBP + -0x3c],EAX
CMP dword ptr [RBP + -0x3c],0xff
JNZ 0x0016c48b
MOV dword ptr [RBP + -0x74],0x0
LAB_0016c36a:
CMP dword ptr [RBP + -0x74],0x50
JGE 0x0016c489
MOVSXD RCX,dword ptr [RBP + -0x74]
LEA RAX,[0x2ce570]
SHL RCX,0x4
ADD RAX,RCX
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x80],RAX
MOV RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x88],RAX
LAB_0016c398:
MOV RAX,qword ptr [RBP + -0x80]
MOVZX ECX,byte ptr [RAX]
XOR EAX,EAX
CMP ECX,0x0
MOV byte ptr [RBP + -0x99],AL
JZ 0x0016c3ea
MOV RCX,qword ptr [RBP + -0x88]
MOV RAX,qword ptr [RBP + -0x28]
SUB RCX,RAX
MOV RAX,qword ptr [RBP + -0x30]
MOVSXD RDX,EAX
XOR EAX,EAX
CMP RCX,RDX
MOV byte ptr [RBP + -0x99],AL
JGE 0x0016c3ea
MOV RAX,qword ptr [RBP + -0x80]
MOVZX EAX,byte ptr [RAX]
MOV RCX,qword ptr [RBP + -0x88]
MOVZX ECX,byte ptr [RCX]
CMP EAX,ECX
SETZ AL
MOV byte ptr [RBP + -0x99],AL
LAB_0016c3ea:
MOV AL,byte ptr [RBP + -0x99]
TEST AL,0x1
JNZ 0x0016c3f6
JMP 0x0016c416
LAB_0016c3f6:
MOV RAX,qword ptr [RBP + -0x80]
ADD RAX,0x1
MOV qword ptr [RBP + -0x80],RAX
MOV RAX,qword ptr [RBP + -0x88]
ADD RAX,0x1
MOV qword ptr [RBP + -0x88],RAX
JMP 0x0016c398
LAB_0016c416:
MOV RAX,qword ptr [RBP + -0x80]
CMP byte ptr [RAX],0x0
JNZ 0x0016c479
CMP dword ptr [RBP + -0x58],0x0
JNZ 0x0016c443
MOVSXD RCX,dword ptr [RBP + -0x74]
LEA RAX,[0x2ce570]
SHL RCX,0x4
ADD RAX,RCX
MOVZX EAX,byte ptr [RAX + 0x8]
MOV dword ptr [RBP + -0xa0],EAX
JMP 0x0016c45f
LAB_0016c443:
MOVSXD RCX,dword ptr [RBP + -0x74]
LEA RAX,[0x2ce570]
SHL RCX,0x4
ADD RAX,RCX
MOVZX EAX,byte ptr [RAX + 0x9]
MOV dword ptr [RBP + -0xa0],EAX
LAB_0016c45f:
MOV EAX,dword ptr [RBP + -0xa0]
MOV dword ptr [RBP + -0x3c],EAX
MOV RAX,qword ptr [RBP + -0x88]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x50],RAX
JMP 0x0016c489
LAB_0016c479:
JMP 0x0016c47b
LAB_0016c47b:
MOV EAX,dword ptr [RBP + -0x74]
ADD EAX,0x1
MOV dword ptr [RBP + -0x74],EAX
JMP 0x0016c36a
LAB_0016c489:
JMP 0x0016c48b
LAB_0016c48b:
MOV RAX,qword ptr [RBP + -0x50]
ADD RAX,0x1
MOV qword ptr [RBP + -0x50],RAX
LAB_0016c497:
MOV EAX,dword ptr [RBP + -0x38]
SUB EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0x5c],EAX
CMP EAX,0x0
JZ 0x0016c4ad
MOV EAX,dword ptr [RBP + -0x5c]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0016c4c0
LAB_0016c4ad:
JMP 0x0016c4af
LAB_0016c4af:
CMP dword ptr [RBP + -0x38],0x0
JNZ 0x0016c10b
MOV dword ptr [RBP + -0x4],0x0
LAB_0016c4c0:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x20
POP RBP
RET
|
int my_strnncoll_win1250ch
(int8 param_1,byte *param_2,ulong param_3,byte *param_4,ulong param_5,
char param_6)
{
byte bVar1;
bool bVar2;
bool bVar3;
int iVar4;
bool bVar5;
uint local_a8;
uint local_a0;
uint local_9c;
uint local_94;
byte *local_90;
byte *local_88;
int local_7c;
byte *local_78;
byte *local_70;
int local_68;
byte *local_58;
byte *local_50;
uint local_44;
uint local_40;
ulong local_28;
bVar2 = false;
bVar3 = false;
local_58 = param_4;
local_50 = param_2;
local_28 = param_3;
if ((param_6 != '\0') && (param_5 < param_3)) {
local_28 = param_5;
}
do {
iVar4 = (int)local_28;
if ((long)local_50 - (long)param_2 < (long)iVar4) {
LAB_0016c154:
if (bVar2) {
bVar1 = _sort_order_win1250ch2[*local_50];
}
else {
bVar1 = _sort_order_win1250ch1[*local_50];
}
local_94 = (uint)bVar1;
local_40 = local_94;
if (local_94 == 0xff) {
for (local_68 = 0; local_68 < 0x50; local_68 = local_68 + 1) {
local_70 = *(byte **)(doubles + (long)local_68 * 0x10);
local_78 = local_50;
while( true ) {
bVar5 = false;
if ((*local_70 != 0) && (bVar5 = false, (long)local_78 - (long)param_2 < (long)iVar4)) {
bVar5 = *local_70 == *local_78;
}
if (!bVar5) break;
local_70 = local_70 + 1;
local_78 = local_78 + 1;
}
if (*local_70 == 0) {
if (bVar2) {
bVar1 = doubles[(long)local_68 * 0x10 + 9];
}
else {
bVar1 = doubles[(long)local_68 * 0x10 + 8];
}
local_9c = (uint)bVar1;
local_40 = local_9c;
local_50 = local_78 + -1;
break;
}
}
}
local_50 = local_50 + 1;
}
else {
if ((!bVar2) && (0 < iVar4)) {
bVar2 = true;
local_50 = param_2;
goto LAB_0016c154;
}
local_40 = 0;
}
iVar4 = (int)param_5;
if ((long)local_58 - (long)param_4 < (long)iVar4) {
LAB_0016c311:
if (bVar3) {
bVar1 = _sort_order_win1250ch2[*local_58];
}
else {
bVar1 = _sort_order_win1250ch1[*local_58];
}
local_a0 = (uint)bVar1;
local_44 = local_a0;
if (local_a0 == 0xff) {
for (local_7c = 0; local_7c < 0x50; local_7c = local_7c + 1) {
local_88 = *(byte **)(doubles + (long)local_7c * 0x10);
local_90 = local_58;
while( true ) {
bVar5 = false;
if ((*local_88 != 0) && (bVar5 = false, (long)local_90 - (long)param_4 < (long)iVar4)) {
bVar5 = *local_88 == *local_90;
}
if (!bVar5) break;
local_88 = local_88 + 1;
local_90 = local_90 + 1;
}
if (*local_88 == 0) {
if (bVar3) {
bVar1 = doubles[(long)local_7c * 0x10 + 9];
}
else {
bVar1 = doubles[(long)local_7c * 0x10 + 8];
}
local_a8 = (uint)bVar1;
local_44 = local_a8;
local_58 = local_90 + -1;
break;
}
}
}
local_58 = local_58 + 1;
}
else {
if ((!bVar3) && (0 < iVar4)) {
bVar3 = true;
local_58 = param_4;
goto LAB_0016c311;
}
local_44 = 0;
}
if (local_40 - local_44 != 0) {
return local_40 - local_44;
}
if (local_40 == 0) {
return 0;
}
} while( true );
}
|
|
7,855 |
SetTextureFilter
|
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtextures.c
|
void SetTextureFilter(Texture2D texture, int filter)
{
switch (filter)
{
case TEXTURE_FILTER_POINT:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_MIP_NEAREST - tex filter: POINT, mipmaps filter: POINT (sharp switching between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_MIP_NEAREST);
// RL_TEXTURE_FILTER_NEAREST - tex filter: POINT (no filter), no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_NEAREST);
}
else
{
// RL_TEXTURE_FILTER_NEAREST - tex filter: POINT (no filter), no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_NEAREST);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_NEAREST);
}
} break;
case TEXTURE_FILTER_BILINEAR:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST - tex filter: BILINEAR, mipmaps filter: POINT (sharp switching between mipmaps)
// Alternative: RL_TEXTURE_FILTER_NEAREST_MIP_LINEAR - tex filter: POINT, mipmaps filter: BILINEAR (smooth transition between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
else
{
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
} break;
case TEXTURE_FILTER_TRILINEAR:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_MIP_LINEAR - tex filter: BILINEAR, mipmaps filter: BILINEAR (smooth transition between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_MIP_LINEAR);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
else
{
TRACELOG(LOG_WARNING, "TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering", texture.id);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
} break;
case TEXTURE_FILTER_ANISOTROPIC_4X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 4); break;
case TEXTURE_FILTER_ANISOTROPIC_8X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 8); break;
case TEXTURE_FILTER_ANISOTROPIC_16X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 16); break;
default: break;
}
}
|
O0
|
c
|
SetTextureFilter:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
leaq 0x10(%rbp), %rax
movq %rax, -0x18(%rbp)
movl %edi, -0x4(%rbp)
movl -0x4(%rbp), %eax
movq %rax, -0x10(%rbp)
subq $0x5, %rax
ja 0x10a3c2
movq -0x10(%rbp), %rax
leaq 0xb4f75(%rip), %rcx # 0x1bf1a4
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x18(%rbp), %rax
cmpl $0x1, 0xc(%rax)
jle 0x10a26e
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2700, %edx # imm = 0x2700
callq 0xb26d0
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2600, %edx # imm = 0x2600
callq 0xb26d0
jmp 0x10a298
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2600, %edx # imm = 0x2600
callq 0xb26d0
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2600, %edx # imm = 0x2600
callq 0xb26d0
jmp 0x10a3c4
movq -0x18(%rbp), %rax
cmpl $0x1, 0xc(%rax)
jle 0x10a2d3
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2701, %edx # imm = 0x2701
callq 0xb26d0
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2601, %edx # imm = 0x2601
callq 0xb26d0
jmp 0x10a2fd
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2601, %edx # imm = 0x2601
callq 0xb26d0
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2601, %edx # imm = 0x2601
callq 0xb26d0
jmp 0x10a3c4
movq -0x18(%rbp), %rax
cmpl $0x1, 0xc(%rax)
jle 0x10a338
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2703, %edx # imm = 0x2703
callq 0xb26d0
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2601, %edx # imm = 0x2601
callq 0xb26d0
jmp 0x10a37b
movq -0x18(%rbp), %rax
movl (%rax), %edx
movl $0x4, %edi
leaq 0xb7a61(%rip), %rsi # 0x1c1dab
movb $0x0, %al
callq 0x182c40
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2601, %edx # imm = 0x2601
callq 0xb26d0
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2601, %edx # imm = 0x2601
callq 0xb26d0
jmp 0x10a3c4
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x4, %edx
callq 0xb26d0
jmp 0x10a3c4
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x8, %edx
callq 0xb26d0
jmp 0x10a3c4
movq -0x18(%rbp), %rax
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x10, %edx
callq 0xb26d0
jmp 0x10a3c4
jmp 0x10a3c4
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
|
SetTextureFilter:
push rbp
mov rbp, rsp
sub rsp, 20h
lea rax, [rbp+arg_0]
mov [rbp+var_18], rax
mov [rbp+var_4], edi
mov eax, [rbp+var_4]
mov [rbp+var_10], rax
sub rax, 5; switch 6 cases
ja def_10A236; jumptable 000000000010A236 default case
mov rax, [rbp+var_10]
lea rcx, jpt_10A236
movsxd rax, ds:(jpt_10A236 - 1BF1A4h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_10A238:
mov rax, [rbp+var_18]; jumptable 000000000010A236 case 0
cmp dword ptr [rax+0Ch], 1
jle short loc_10A26E
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2801h
mov edx, 2700h
call rlTextureParameters
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2800h
mov edx, 2600h
call rlTextureParameters
jmp short loc_10A298
loc_10A26E:
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2801h
mov edx, 2600h
call rlTextureParameters
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2800h
mov edx, 2600h
call rlTextureParameters
loc_10A298:
jmp loc_10A3C4
loc_10A29D:
mov rax, [rbp+var_18]; jumptable 000000000010A236 case 1
cmp dword ptr [rax+0Ch], 1
jle short loc_10A2D3
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2801h
mov edx, 2701h
call rlTextureParameters
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2800h
mov edx, 2601h
call rlTextureParameters
jmp short loc_10A2FD
loc_10A2D3:
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2801h
mov edx, 2601h
call rlTextureParameters
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2800h
mov edx, 2601h
call rlTextureParameters
loc_10A2FD:
jmp loc_10A3C4
loc_10A302:
mov rax, [rbp+var_18]; jumptable 000000000010A236 case 2
cmp dword ptr [rax+0Ch], 1
jle short loc_10A338
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2801h
mov edx, 2703h
call rlTextureParameters
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2800h
mov edx, 2601h
call rlTextureParameters
jmp short loc_10A37B
loc_10A338:
mov rax, [rbp+var_18]
mov edx, [rax]
mov edi, 4
lea rsi, aTextureIdINoMi; "TEXTURE: [ID %i] No mipmaps available f"...
mov al, 0
call TraceLog
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2801h
mov edx, 2601h
call rlTextureParameters
mov rax, [rbp+var_18]
mov edi, [rax]
mov esi, 2800h
mov edx, 2601h
call rlTextureParameters
loc_10A37B:
jmp short loc_10A3C4
loc_10A37D:
mov rax, [rbp+var_18]; jumptable 000000000010A236 case 3
mov edi, [rax]
mov esi, 3000h
mov edx, 4
call rlTextureParameters
jmp short loc_10A3C4
loc_10A394:
mov rax, [rbp+var_18]; jumptable 000000000010A236 case 4
mov edi, [rax]
mov esi, 3000h
mov edx, 8
call rlTextureParameters
jmp short loc_10A3C4
loc_10A3AB:
mov rax, [rbp+var_18]; jumptable 000000000010A236 case 5
mov edi, [rax]
mov esi, 3000h
mov edx, 10h
call rlTextureParameters
jmp short loc_10A3C4
def_10A236:
jmp short $+2; jumptable 000000000010A236 default case
loc_10A3C4:
add rsp, 20h
pop rbp
retn
|
long long SetTextureFilter(
unsigned int a1,
_DWORD a2,
_DWORD a3,
int a4,
int a5,
int a6,
unsigned int a7,
long long a8)
{
long long result; // rax
result = a1;
switch ( a1 )
{
case 0u:
if ( SHIDWORD(a8) <= 1 )
rlTextureParameters(a7, 0x2801u, 9728);
else
rlTextureParameters(a7, 0x2801u, 9984);
result = rlTextureParameters(a7, 0x2800u, 9728);
break;
case 1u:
if ( SHIDWORD(a8) <= 1 )
rlTextureParameters(a7, 0x2801u, 9729);
else
rlTextureParameters(a7, 0x2801u, 9985);
goto LABEL_8;
case 2u:
if ( SHIDWORD(a8) <= 1 )
{
TraceLog(
4,
(unsigned int)"TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering",
a7,
a4,
a5,
a6);
rlTextureParameters(a7, 0x2801u, 9729);
}
else
{
rlTextureParameters(a7, 0x2801u, 9987);
}
LABEL_8:
result = rlTextureParameters(a7, 0x2800u, 9729);
break;
case 3u:
result = rlTextureParameters(a7, 0x3000u, 4);
break;
case 4u:
result = rlTextureParameters(a7, 0x3000u, 8);
break;
case 5u:
result = rlTextureParameters(a7, 0x3000u, 16);
break;
default:
return result;
}
return result;
}
| |||
7,856 |
SetTextureFilter
|
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtextures.c
|
void SetTextureFilter(Texture2D texture, int filter)
{
switch (filter)
{
case TEXTURE_FILTER_POINT:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_MIP_NEAREST - tex filter: POINT, mipmaps filter: POINT (sharp switching between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_MIP_NEAREST);
// RL_TEXTURE_FILTER_NEAREST - tex filter: POINT (no filter), no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_NEAREST);
}
else
{
// RL_TEXTURE_FILTER_NEAREST - tex filter: POINT (no filter), no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_NEAREST);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_NEAREST);
}
} break;
case TEXTURE_FILTER_BILINEAR:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST - tex filter: BILINEAR, mipmaps filter: POINT (sharp switching between mipmaps)
// Alternative: RL_TEXTURE_FILTER_NEAREST_MIP_LINEAR - tex filter: POINT, mipmaps filter: BILINEAR (smooth transition between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
else
{
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
} break;
case TEXTURE_FILTER_TRILINEAR:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_MIP_LINEAR - tex filter: BILINEAR, mipmaps filter: BILINEAR (smooth transition between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_MIP_LINEAR);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
else
{
TRACELOG(LOG_WARNING, "TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering", texture.id);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
} break;
case TEXTURE_FILTER_ANISOTROPIC_4X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 4); break;
case TEXTURE_FILTER_ANISOTROPIC_8X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 8); break;
case TEXTURE_FILTER_ANISOTROPIC_16X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 16); break;
default: break;
}
}
|
O1
|
c
|
SetTextureFilter:
pushq %rbx
cmpl $0x5, %edi
ja 0xa171d
leaq 0x10(%rsp), %rax
movl %edi, %ecx
leaq 0x4e27e(%rip), %rdx # 0xef91c
movslq (%rdx,%rcx,4), %rcx
addq %rdx, %rcx
jmpq *%rcx
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0xa1753
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2700, %edx # imm = 0x2700
jmp 0xa175f
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x8, %edx
jmp 0xa1770
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0xa171f
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2703, %edx # imm = 0x2703
jmp 0xa1740
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x4, %edx
jmp 0xa1770
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0xa1734
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2701, %edx # imm = 0x2701
jmp 0xa1740
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x10, %edx
jmp 0xa1770
popq %rbx
retq
leaq 0x51d55(%rip), %rsi # 0xf347b
movl $0x4, %edi
movl %ebx, %edx
xorl %eax, %eax
callq 0xbfa73
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2601, %edx # imm = 0x2601
callq 0x64278
movl %ebx, %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2601, %edx # imm = 0x2601
jmp 0xa1770
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2600, %edx # imm = 0x2600
callq 0x64278
movl %ebx, %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2600, %edx # imm = 0x2600
popq %rbx
jmp 0x64278
|
SetTextureFilter:
push rbx
cmp edi, 5; switch 6 cases
ja def_A16A5; jumptable 00000000000A16A5 default case
lea rax, [rsp+8+arg_0]
mov ecx, edi
lea rdx, jpt_A16A5
movsxd rcx, ds:(jpt_A16A5 - 0EF91Ch)[rdx+rcx*4]
add rcx, rdx
jmp rcx; switch jump
loc_A16A7:
mov ebx, [rax]; jumptable 00000000000A16A5 case 0
cmp dword ptr [rax+0Ch], 2
jl loc_A1753
mov edi, ebx
mov esi, 2801h
mov edx, 2700h
jmp loc_A175F
loc_A16C4:
mov edi, [rax]; jumptable 00000000000A16A5 case 4
mov esi, 3000h
mov edx, 8
jmp loc_A1770
loc_A16D5:
mov ebx, [rax]; jumptable 00000000000A16A5 case 2
cmp dword ptr [rax+0Ch], 2
jl short loc_A171F
mov edi, ebx
mov esi, 2801h
mov edx, 2703h
jmp short loc_A1740
loc_A16EB:
mov edi, [rax]; jumptable 00000000000A16A5 case 3
mov esi, 3000h
mov edx, 4
jmp short loc_A1770
loc_A16F9:
mov ebx, [rax]; jumptable 00000000000A16A5 case 1
cmp dword ptr [rax+0Ch], 2
jl short loc_A1734
mov edi, ebx
mov esi, 2801h
mov edx, 2701h
jmp short loc_A1740
loc_A170F:
mov edi, [rax]; jumptable 00000000000A16A5 case 5
mov esi, 3000h
mov edx, 10h
jmp short loc_A1770
def_A16A5:
pop rbx; jumptable 00000000000A16A5 default case
retn
loc_A171F:
lea rsi, aTextureIdINoMi; "TEXTURE: [ID %i] No mipmaps available f"...
mov edi, 4
mov edx, ebx
xor eax, eax
call TraceLog
loc_A1734:
mov edi, ebx
mov esi, 2801h
mov edx, 2601h
loc_A1740:
call rlTextureParameters
mov edi, ebx
mov esi, 2800h
mov edx, 2601h
jmp short loc_A1770
loc_A1753:
mov edi, ebx
mov esi, 2801h
mov edx, 2600h
loc_A175F:
call rlTextureParameters
mov edi, ebx
mov esi, 2800h
mov edx, 2600h
loc_A1770:
pop rbx
jmp rlTextureParameters
|
unsigned int * SetTextureFilter(
int a1,
_DWORD a2,
_DWORD a3,
_DWORD a4,
int a5,
int a6,
unsigned int a7,
long long a8)
{
unsigned int *result; // rax
unsigned int v9; // ebx
int v10; // edx
unsigned int v11; // ebx
unsigned int v12; // edi
int v13; // edx
result = &a7;
switch ( a1 )
{
case 0:
v9 = a7;
if ( SHIDWORD(a8) < 2 )
v10 = 9728;
else
v10 = 9984;
rlTextureParameters(a7, 10241LL, v10);
result = (unsigned int *)rlTextureParameters(v9, 10240LL, 9728);
break;
case 1:
v11 = a7;
if ( SHIDWORD(a8) < 2 )
goto LABEL_12;
v12 = a7;
v13 = 9985;
goto LABEL_13;
case 2:
v11 = a7;
if ( SHIDWORD(a8) < 2 )
{
TraceLog(
4,
(unsigned int)"TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering",
a7,
a1,
a5,
a6);
LABEL_12:
v12 = v11;
v13 = 9729;
}
else
{
v12 = a7;
v13 = 9987;
}
LABEL_13:
rlTextureParameters(v12, 10241LL, v13);
result = (unsigned int *)rlTextureParameters(v11, 10240LL, 9729);
break;
case 3:
result = (unsigned int *)rlTextureParameters(a7, 12288LL, 4);
break;
case 4:
result = (unsigned int *)rlTextureParameters(a7, 12288LL, 8);
break;
case 5:
result = (unsigned int *)rlTextureParameters(a7, 12288LL, 16);
break;
default:
return result;
}
return result;
}
|
SetTextureFilter:
PUSH RBX
CMP EDI,0x5
JA 0x001a171d
LEA RAX,[RSP + 0x10]
MOV ECX,EDI
LEA RDX,[0x1ef91c]
MOVSXD RCX,dword ptr [RDX + RCX*0x4]
ADD RCX,RDX
switchD:
JMP RCX
caseD_0:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x001a1753
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2700
JMP 0x001a175f
caseD_4:
MOV EDI,dword ptr [RAX]
MOV ESI,0x3000
MOV EDX,0x8
JMP 0x001a1770
caseD_2:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x001a171f
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2703
JMP 0x001a1740
caseD_3:
MOV EDI,dword ptr [RAX]
MOV ESI,0x3000
MOV EDX,0x4
JMP 0x001a1770
caseD_1:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x001a1734
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2701
JMP 0x001a1740
caseD_5:
MOV EDI,dword ptr [RAX]
MOV ESI,0x3000
MOV EDX,0x10
JMP 0x001a1770
default:
POP RBX
RET
LAB_001a171f:
LEA RSI,[0x1f347b]
MOV EDI,0x4
MOV EDX,EBX
XOR EAX,EAX
CALL 0x001bfa73
LAB_001a1734:
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2601
LAB_001a1740:
CALL 0x00164278
MOV EDI,EBX
MOV ESI,0x2800
MOV EDX,0x2601
JMP 0x001a1770
LAB_001a1753:
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2600
LAB_001a175f:
CALL 0x00164278
MOV EDI,EBX
MOV ESI,0x2800
MOV EDX,0x2600
LAB_001a1770:
POP RBX
JMP 0x00164278
|
void SetTextureFilter(int4 param_1)
{
int8 uVar1;
int8 uVar2;
int4 in_stack_00000008;
int8 in_stack_00000010;
switch(param_1) {
case 0:
if (in_stack_00000010._4_4_ < 2) {
uVar1 = 0x2600;
}
else {
uVar1 = 0x2700;
}
rlTextureParameters(in_stack_00000008,0x2801,uVar1);
uVar2 = 0x2800;
uVar1 = 0x2600;
break;
case 1:
if (in_stack_00000010._4_4_ < 2) {
LAB_001a1734:
uVar1 = 0x2601;
}
else {
uVar1 = 0x2701;
}
goto LAB_001a1740;
case 2:
if (in_stack_00000010._4_4_ < 2) {
TraceLog(4,"TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering",
in_stack_00000008);
goto LAB_001a1734;
}
uVar1 = 0x2703;
LAB_001a1740:
rlTextureParameters(in_stack_00000008,0x2801,uVar1);
uVar2 = 0x2800;
uVar1 = 0x2601;
break;
case 3:
uVar2 = 0x3000;
uVar1 = 4;
break;
case 4:
uVar2 = 0x3000;
uVar1 = 8;
break;
case 5:
uVar2 = 0x3000;
uVar1 = 0x10;
break;
default:
return;
}
rlTextureParameters(in_stack_00000008,uVar2,uVar1);
return;
}
|
|
7,857 |
SetTextureFilter
|
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtextures.c
|
void SetTextureFilter(Texture2D texture, int filter)
{
switch (filter)
{
case TEXTURE_FILTER_POINT:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_MIP_NEAREST - tex filter: POINT, mipmaps filter: POINT (sharp switching between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_MIP_NEAREST);
// RL_TEXTURE_FILTER_NEAREST - tex filter: POINT (no filter), no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_NEAREST);
}
else
{
// RL_TEXTURE_FILTER_NEAREST - tex filter: POINT (no filter), no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_NEAREST);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_NEAREST);
}
} break;
case TEXTURE_FILTER_BILINEAR:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST - tex filter: BILINEAR, mipmaps filter: POINT (sharp switching between mipmaps)
// Alternative: RL_TEXTURE_FILTER_NEAREST_MIP_LINEAR - tex filter: POINT, mipmaps filter: BILINEAR (smooth transition between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
else
{
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
} break;
case TEXTURE_FILTER_TRILINEAR:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_MIP_LINEAR - tex filter: BILINEAR, mipmaps filter: BILINEAR (smooth transition between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_MIP_LINEAR);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
else
{
TRACELOG(LOG_WARNING, "TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering", texture.id);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
} break;
case TEXTURE_FILTER_ANISOTROPIC_4X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 4); break;
case TEXTURE_FILTER_ANISOTROPIC_8X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 8); break;
case TEXTURE_FILTER_ANISOTROPIC_16X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 16); break;
default: break;
}
}
|
O2
|
c
|
SetTextureFilter:
pushq %rbx
cmpl $0x5, %edi
ja 0x87085
leaq 0x10(%rsp), %rax
movl %edi, %ecx
leaq 0x48bf1(%rip), %rdx # 0xcfc0c
movslq (%rdx,%rcx,4), %rcx
addq %rdx, %rcx
jmpq *%rcx
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0x870b9
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2700, %edx # imm = 0x2700
jmp 0x870c5
movl (%rax), %edi
pushq $0x8
jmp 0x8707d
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0x87087
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2703, %edx # imm = 0x2703
jmp 0x870a6
movl (%rax), %edi
pushq $0x4
jmp 0x8707d
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0x8709a
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2701, %edx # imm = 0x2701
jmp 0x870a6
movl (%rax), %edi
pushq $0x10
popq %rdx
movl $0x3000, %esi # imm = 0x3000
jmp 0x870d6
popq %rbx
retq
leaq 0x4c6e5(%rip), %rsi # 0xd3773
pushq $0x4
popq %rdi
movl %ebx, %edx
xorl %eax, %eax
callq 0xa128b
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2601, %edx # imm = 0x2601
callq 0x52d29
movl %ebx, %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2601, %edx # imm = 0x2601
jmp 0x870d6
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2600, %edx # imm = 0x2600
callq 0x52d29
movl %ebx, %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2600, %edx # imm = 0x2600
popq %rbx
jmp 0x52d29
|
SetTextureFilter:
push rbx
cmp edi, 5; switch 6 cases
ja short def_87022; jumptable 0000000000087022 default case
lea rax, [rsp+8+arg_0]
mov ecx, edi
lea rdx, jpt_87022
movsxd rcx, ds:(jpt_87022 - 0CFC0Ch)[rdx+rcx*4]
add rcx, rdx
jmp rcx; switch jump
loc_87024:
mov ebx, [rax]; jumptable 0000000000087022 case 0
cmp dword ptr [rax+0Ch], 2
jl loc_870B9
mov edi, ebx
mov esi, 2801h
mov edx, 2700h
jmp loc_870C5
loc_87041:
mov edi, [rax]; jumptable 0000000000087022 case 4
push 8
jmp short loc_8707D
loc_87047:
mov ebx, [rax]; jumptable 0000000000087022 case 2
cmp dword ptr [rax+0Ch], 2
jl short loc_87087
mov edi, ebx
mov esi, 2801h
mov edx, 2703h
jmp short loc_870A6
loc_8705D:
mov edi, [rax]; jumptable 0000000000087022 case 3
push 4
jmp short loc_8707D
loc_87063:
mov ebx, [rax]; jumptable 0000000000087022 case 1
cmp dword ptr [rax+0Ch], 2
jl short loc_8709A
mov edi, ebx
mov esi, 2801h
mov edx, 2701h
jmp short loc_870A6
loc_87079:
mov edi, [rax]; jumptable 0000000000087022 case 5
push 10h
loc_8707D:
pop rdx
mov esi, 3000h
jmp short loc_870D6
def_87022:
pop rbx; jumptable 0000000000087022 default case
retn
loc_87087:
lea rsi, aTextureIdINoMi; "TEXTURE: [ID %i] No mipmaps available f"...
push 4
pop rdi
mov edx, ebx
xor eax, eax
call TraceLog
loc_8709A:
mov edi, ebx
mov esi, 2801h
mov edx, 2601h
loc_870A6:
call rlTextureParameters
mov edi, ebx
mov esi, 2800h
mov edx, 2601h
jmp short loc_870D6
loc_870B9:
mov edi, ebx
mov esi, 2801h
mov edx, 2600h
loc_870C5:
call rlTextureParameters
mov edi, ebx
mov esi, 2800h
mov edx, 2600h
loc_870D6:
pop rbx
jmp rlTextureParameters
|
unsigned int * SetTextureFilter(
int a1,
_DWORD a2,
_DWORD a3,
_DWORD a4,
int a5,
int a6,
unsigned int a7,
long long a8)
{
unsigned int *result; // rax
unsigned int v9; // ebx
int v10; // edx
unsigned int v11; // edi
unsigned int v12; // ebx
unsigned int v13; // edi
int v14; // edx
int v15; // edx
long long v16; // rsi
int v17; // [rsp-8h] [rbp-10h]
result = &a7;
switch ( a1 )
{
case 0:
v9 = a7;
if ( SHIDWORD(a8) < 2 )
v10 = 9728;
else
v10 = 9984;
rlTextureParameters(a7, 10241LL, v10);
v11 = v9;
v16 = 10240LL;
v15 = 9728;
goto LABEL_17;
case 1:
v12 = a7;
if ( SHIDWORD(a8) < 2 )
goto LABEL_13;
v13 = a7;
v14 = 9985;
goto LABEL_14;
case 2:
v12 = a7;
if ( SHIDWORD(a8) < 2 )
{
TraceLog(
4,
(unsigned int)"TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering",
a7,
a1,
a5,
a6);
LABEL_13:
v13 = v12;
v14 = 9729;
}
else
{
v13 = a7;
v14 = 9987;
}
LABEL_14:
rlTextureParameters(v13, 10241LL, v14);
result = (unsigned int *)rlTextureParameters(v12, 10240LL, 9729);
break;
case 3:
v11 = a7;
v17 = 4;
goto LABEL_11;
case 4:
v11 = a7;
v17 = 8;
goto LABEL_11;
case 5:
v11 = a7;
v17 = 16;
LABEL_11:
v15 = v17;
v16 = 12288LL;
LABEL_17:
result = (unsigned int *)rlTextureParameters(v11, v16, v15);
break;
default:
return result;
}
return result;
}
|
SetTextureFilter:
PUSH RBX
CMP EDI,0x5
JA 0x00187085
LEA RAX,[RSP + 0x10]
MOV ECX,EDI
LEA RDX,[0x1cfc0c]
MOVSXD RCX,dword ptr [RDX + RCX*0x4]
ADD RCX,RDX
switchD:
JMP RCX
caseD_0:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x001870b9
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2700
JMP 0x001870c5
caseD_4:
MOV EDI,dword ptr [RAX]
PUSH 0x8
JMP 0x0018707d
caseD_2:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x00187087
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2703
JMP 0x001870a6
caseD_3:
MOV EDI,dword ptr [RAX]
PUSH 0x4
JMP 0x0018707d
caseD_1:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x0018709a
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2701
JMP 0x001870a6
caseD_5:
MOV EDI,dword ptr [RAX]
PUSH 0x10
LAB_0018707d:
POP RDX
MOV ESI,0x3000
JMP 0x001870d6
default:
POP RBX
RET
LAB_00187087:
LEA RSI,[0x1d3773]
PUSH 0x4
POP RDI
MOV EDX,EBX
XOR EAX,EAX
CALL 0x001a128b
LAB_0018709a:
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2601
LAB_001870a6:
CALL 0x00152d29
MOV EDI,EBX
MOV ESI,0x2800
MOV EDX,0x2601
JMP 0x001870d6
LAB_001870b9:
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2600
LAB_001870c5:
CALL 0x00152d29
MOV EDI,EBX
MOV ESI,0x2800
MOV EDX,0x2600
LAB_001870d6:
POP RBX
JMP 0x00152d29
|
void SetTextureFilter(int4 param_1)
{
int8 uVar1;
int4 in_stack_00000008;
int8 in_stack_00000010;
int8 uStack_10;
switch(param_1) {
case 0:
if (in_stack_00000010._4_4_ < 2) {
uVar1 = 0x2600;
}
else {
uVar1 = 0x2700;
}
rlTextureParameters(in_stack_00000008,0x2801,uVar1);
uVar1 = 0x2800;
uStack_10 = 0x2600;
goto LAB_001870d6;
case 1:
if (in_stack_00000010._4_4_ < 2) {
LAB_0018709a:
uVar1 = 0x2601;
}
else {
uVar1 = 0x2701;
}
goto LAB_001870a6;
case 2:
if (in_stack_00000010._4_4_ < 2) {
TraceLog(4,"TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering",
in_stack_00000008);
goto LAB_0018709a;
}
uVar1 = 0x2703;
LAB_001870a6:
rlTextureParameters(in_stack_00000008,0x2801,uVar1);
uVar1 = 0x2800;
uStack_10 = 0x2601;
goto LAB_001870d6;
case 3:
uStack_10 = 4;
break;
case 4:
uStack_10 = 8;
break;
case 5:
uStack_10 = 0x10;
break;
default:
return;
}
uVar1 = 0x3000;
LAB_001870d6:
rlTextureParameters(in_stack_00000008,uVar1,uStack_10);
return;
}
|
|
7,858 |
SetTextureFilter
|
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtextures.c
|
void SetTextureFilter(Texture2D texture, int filter)
{
switch (filter)
{
case TEXTURE_FILTER_POINT:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_MIP_NEAREST - tex filter: POINT, mipmaps filter: POINT (sharp switching between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_MIP_NEAREST);
// RL_TEXTURE_FILTER_NEAREST - tex filter: POINT (no filter), no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_NEAREST);
}
else
{
// RL_TEXTURE_FILTER_NEAREST - tex filter: POINT (no filter), no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_NEAREST);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_NEAREST);
}
} break;
case TEXTURE_FILTER_BILINEAR:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST - tex filter: BILINEAR, mipmaps filter: POINT (sharp switching between mipmaps)
// Alternative: RL_TEXTURE_FILTER_NEAREST_MIP_LINEAR - tex filter: POINT, mipmaps filter: BILINEAR (smooth transition between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR_MIP_NEAREST);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
else
{
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
} break;
case TEXTURE_FILTER_TRILINEAR:
{
if (texture.mipmaps > 1)
{
// RL_TEXTURE_FILTER_MIP_LINEAR - tex filter: BILINEAR, mipmaps filter: BILINEAR (smooth transition between mipmaps)
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_MIP_LINEAR);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
else
{
TRACELOG(LOG_WARNING, "TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering", texture.id);
// RL_TEXTURE_FILTER_LINEAR - tex filter: BILINEAR, no mipmaps
rlTextureParameters(texture.id, RL_TEXTURE_MIN_FILTER, RL_TEXTURE_FILTER_LINEAR);
rlTextureParameters(texture.id, RL_TEXTURE_MAG_FILTER, RL_TEXTURE_FILTER_LINEAR);
}
} break;
case TEXTURE_FILTER_ANISOTROPIC_4X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 4); break;
case TEXTURE_FILTER_ANISOTROPIC_8X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 8); break;
case TEXTURE_FILTER_ANISOTROPIC_16X: rlTextureParameters(texture.id, RL_TEXTURE_FILTER_ANISOTROPIC, 16); break;
default: break;
}
}
|
O3
|
c
|
SetTextureFilter:
pushq %rbx
cmpl $0x5, %edi
ja 0x9bd2b
leaq 0x10(%rsp), %rax
movl %edi, %ecx
leaq 0x4de70(%rip), %rdx # 0xe9b1c
movslq (%rdx,%rcx,4), %rcx
addq %rdx, %rcx
jmpq *%rcx
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0x9bd61
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2700, %edx # imm = 0x2700
jmp 0x9bd6d
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x8, %edx
jmp 0x9bd7e
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0x9bd2d
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2703, %edx # imm = 0x2703
jmp 0x9bd4e
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x4, %edx
jmp 0x9bd7e
movl (%rax), %ebx
cmpl $0x2, 0xc(%rax)
jl 0x9bd42
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2701, %edx # imm = 0x2701
jmp 0x9bd4e
movl (%rax), %edi
movl $0x3000, %esi # imm = 0x3000
movl $0x10, %edx
jmp 0x9bd7e
popq %rbx
retq
leaq 0x51947(%rip), %rsi # 0xed67b
movl $0x4, %edi
movl %ebx, %edx
xorl %eax, %eax
callq 0xb9db7
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2601, %edx # imm = 0x2601
callq 0x62a99
movl %ebx, %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2601, %edx # imm = 0x2601
jmp 0x9bd7e
movl %ebx, %edi
movl $0x2801, %esi # imm = 0x2801
movl $0x2600, %edx # imm = 0x2600
callq 0x62a99
movl %ebx, %edi
movl $0x2800, %esi # imm = 0x2800
movl $0x2600, %edx # imm = 0x2600
popq %rbx
jmp 0x62a99
|
SetTextureFilter:
push rbx
cmp edi, 5; switch 6 cases
ja def_9BCB3; jumptable 000000000009BCB3 default case
lea rax, [rsp+8+arg_0]
mov ecx, edi
lea rdx, jpt_9BCB3
movsxd rcx, ds:(jpt_9BCB3 - 0E9B1Ch)[rdx+rcx*4]
add rcx, rdx
jmp rcx; switch jump
loc_9BCB5:
mov ebx, [rax]; jumptable 000000000009BCB3 case 0
cmp dword ptr [rax+0Ch], 2
jl loc_9BD61
mov edi, ebx
mov esi, 2801h
mov edx, 2700h
jmp loc_9BD6D
loc_9BCD2:
mov edi, [rax]; jumptable 000000000009BCB3 case 4
mov esi, 3000h
mov edx, 8
jmp loc_9BD7E
loc_9BCE3:
mov ebx, [rax]; jumptable 000000000009BCB3 case 2
cmp dword ptr [rax+0Ch], 2
jl short loc_9BD2D
mov edi, ebx
mov esi, 2801h
mov edx, 2703h
jmp short loc_9BD4E
loc_9BCF9:
mov edi, [rax]; jumptable 000000000009BCB3 case 3
mov esi, 3000h
mov edx, 4
jmp short loc_9BD7E
loc_9BD07:
mov ebx, [rax]; jumptable 000000000009BCB3 case 1
cmp dword ptr [rax+0Ch], 2
jl short loc_9BD42
mov edi, ebx
mov esi, 2801h
mov edx, 2701h
jmp short loc_9BD4E
loc_9BD1D:
mov edi, [rax]; jumptable 000000000009BCB3 case 5
mov esi, 3000h
mov edx, 10h
jmp short loc_9BD7E
def_9BCB3:
pop rbx; jumptable 000000000009BCB3 default case
retn
loc_9BD2D:
lea rsi, aTextureIdINoMi; "TEXTURE: [ID %i] No mipmaps available f"...
mov edi, 4
mov edx, ebx
xor eax, eax
call TraceLog
loc_9BD42:
mov edi, ebx
mov esi, 2801h
mov edx, 2601h
loc_9BD4E:
call rlTextureParameters
mov edi, ebx
mov esi, 2800h
mov edx, 2601h
jmp short loc_9BD7E
loc_9BD61:
mov edi, ebx
mov esi, 2801h
mov edx, 2600h
loc_9BD6D:
call rlTextureParameters
mov edi, ebx
mov esi, 2800h
mov edx, 2600h
loc_9BD7E:
pop rbx
jmp rlTextureParameters
|
unsigned int * SetTextureFilter(
int a1,
_DWORD a2,
_DWORD a3,
_DWORD a4,
int a5,
int a6,
unsigned int a7,
long long a8)
{
unsigned int *result; // rax
unsigned int v9; // ebx
int v10; // edx
unsigned int v11; // ebx
unsigned int v12; // edi
int v13; // edx
result = &a7;
switch ( a1 )
{
case 0:
v9 = a7;
if ( SHIDWORD(a8) < 2 )
v10 = 9728;
else
v10 = 9984;
rlTextureParameters(a7, 10241LL, v10);
result = (unsigned int *)rlTextureParameters(v9, 10240LL, 9728);
break;
case 1:
v11 = a7;
if ( SHIDWORD(a8) < 2 )
goto LABEL_12;
v12 = a7;
v13 = 9985;
goto LABEL_13;
case 2:
v11 = a7;
if ( SHIDWORD(a8) < 2 )
{
TraceLog(
4,
(unsigned int)"TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering",
a7,
a1,
a5,
a6);
LABEL_12:
v12 = v11;
v13 = 9729;
}
else
{
v12 = a7;
v13 = 9987;
}
LABEL_13:
rlTextureParameters(v12, 10241LL, v13);
result = (unsigned int *)rlTextureParameters(v11, 10240LL, 9729);
break;
case 3:
result = (unsigned int *)rlTextureParameters(a7, 12288LL, 4);
break;
case 4:
result = (unsigned int *)rlTextureParameters(a7, 12288LL, 8);
break;
case 5:
result = (unsigned int *)rlTextureParameters(a7, 12288LL, 16);
break;
default:
return result;
}
return result;
}
|
SetTextureFilter:
PUSH RBX
CMP EDI,0x5
JA 0x0019bd2b
LEA RAX,[RSP + 0x10]
MOV ECX,EDI
LEA RDX,[0x1e9b1c]
MOVSXD RCX,dword ptr [RDX + RCX*0x4]
ADD RCX,RDX
switchD:
JMP RCX
caseD_0:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x0019bd61
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2700
JMP 0x0019bd6d
caseD_4:
MOV EDI,dword ptr [RAX]
MOV ESI,0x3000
MOV EDX,0x8
JMP 0x0019bd7e
caseD_2:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x0019bd2d
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2703
JMP 0x0019bd4e
caseD_3:
MOV EDI,dword ptr [RAX]
MOV ESI,0x3000
MOV EDX,0x4
JMP 0x0019bd7e
caseD_1:
MOV EBX,dword ptr [RAX]
CMP dword ptr [RAX + 0xc],0x2
JL 0x0019bd42
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2701
JMP 0x0019bd4e
caseD_5:
MOV EDI,dword ptr [RAX]
MOV ESI,0x3000
MOV EDX,0x10
JMP 0x0019bd7e
default:
POP RBX
RET
LAB_0019bd2d:
LEA RSI,[0x1ed67b]
MOV EDI,0x4
MOV EDX,EBX
XOR EAX,EAX
CALL 0x001b9db7
LAB_0019bd42:
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2601
LAB_0019bd4e:
CALL 0x00162a99
MOV EDI,EBX
MOV ESI,0x2800
MOV EDX,0x2601
JMP 0x0019bd7e
LAB_0019bd61:
MOV EDI,EBX
MOV ESI,0x2801
MOV EDX,0x2600
LAB_0019bd6d:
CALL 0x00162a99
MOV EDI,EBX
MOV ESI,0x2800
MOV EDX,0x2600
LAB_0019bd7e:
POP RBX
JMP 0x00162a99
|
void SetTextureFilter(int4 param_1)
{
int8 uVar1;
int8 uVar2;
int4 in_stack_00000008;
int8 in_stack_00000010;
switch(param_1) {
case 0:
if (in_stack_00000010._4_4_ < 2) {
uVar1 = 0x2600;
}
else {
uVar1 = 0x2700;
}
rlTextureParameters(in_stack_00000008,0x2801,uVar1);
uVar2 = 0x2800;
uVar1 = 0x2600;
break;
case 1:
if (in_stack_00000010._4_4_ < 2) {
LAB_0019bd42:
uVar1 = 0x2601;
}
else {
uVar1 = 0x2701;
}
goto LAB_0019bd4e;
case 2:
if (in_stack_00000010._4_4_ < 2) {
TraceLog(4,"TEXTURE: [ID %i] No mipmaps available for TRILINEAR texture filtering",
in_stack_00000008);
goto LAB_0019bd42;
}
uVar1 = 0x2703;
LAB_0019bd4e:
rlTextureParameters(in_stack_00000008,0x2801,uVar1);
uVar2 = 0x2800;
uVar1 = 0x2601;
break;
case 3:
uVar2 = 0x3000;
uVar1 = 4;
break;
case 4:
uVar2 = 0x3000;
uVar1 = 8;
break;
case 5:
uVar2 = 0x3000;
uVar1 = 0x10;
break;
default:
return;
}
rlTextureParameters(in_stack_00000008,uVar2,uVar1);
return;
}
|
|
7,859 |
LefDefParser::lefiTiming::addRiseFallSlew(double, double, double, double)
|
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefiMacro.cpp
|
void
lefiTiming::addRiseFallSlew(double one,
double two,
double three,
double four)
{
if (nowRise_) {
hasRiseSlew_ = 1;
riseSlewOne_ = one;
riseSlewTwo_ = two;
riseSlewThree_ = three;
riseSlewFour_ = four;
} else {
hasFallSlew_ = 1;
fallSlewOne_ = one;
fallSlewTwo_ = two;
fallSlewThree_ = three;
fallSlewFour_ = four;
}
}
|
O3
|
cpp
|
LefDefParser::lefiTiming::addRiseFallSlew(double, double, double, double):
pushq %rbx
leaq 0x138(%rdi), %rax
leaq 0x170(%rdi), %rcx
leaq 0x140(%rdi), %rdx
leaq 0x178(%rdi), %rsi
leaq 0x148(%rdi), %r8
leaq 0x180(%rdi), %r9
leaq 0x150(%rdi), %r10
leaq 0x188(%rdi), %r11
xorl %ebx, %ebx
cmpl $0x0, 0x80(%rdi)
sete %bl
movl $0x1, 0x2c(%rdi,%rbx,8)
cmoveq %rcx, %rax
cmovneq %rdx, %rsi
movsd %xmm0, (%rax)
movsd %xmm1, (%rsi)
cmovneq %r8, %r9
movsd %xmm2, (%r9)
cmovneq %r10, %r11
movsd %xmm3, (%r11)
popq %rbx
retq
nop
|
_ZN12LefDefParser10lefiTiming15addRiseFallSlewEdddd:
push rbx
lea rax, [rdi+138h]
lea rcx, [rdi+170h]
lea rdx, [rdi+140h]
lea rsi, [rdi+178h]
lea r8, [rdi+148h]
lea r9, [rdi+180h]
lea r10, [rdi+150h]
lea r11, [rdi+188h]
xor ebx, ebx
cmp dword ptr [rdi+80h], 0
setz bl
mov dword ptr [rdi+rbx*8+2Ch], 1
cmovz rax, rcx
cmovnz rsi, rdx
movsd qword ptr [rax], xmm0
movsd qword ptr [rsi], xmm1
cmovnz r9, r8
movsd qword ptr [r9], xmm2
cmovnz r11, r10
movsd qword ptr [r11], xmm3
pop rbx
retn
|
double * LefDefParser::lefiTiming::addRiseFallSlew(
LefDefParser::lefiTiming *this,
double a2,
double a3,
double a4,
double a5)
{
double *result; // rax
double *v6; // rsi
double *v7; // r9
double *v8; // r11
bool v9; // zf
result = (double *)((char *)this + 312);
v6 = (double *)((char *)this + 376);
v7 = (double *)((char *)this + 384);
v8 = (double *)((char *)this + 392);
v9 = *((_DWORD *)this + 32) == 0;
*((_DWORD *)this + 2 * v9 + 11) = 1;
if ( v9 )
result = (double *)((char *)this + 368);
else
v6 = (double *)((char *)this + 320);
*result = a2;
*v6 = a3;
if ( !v9 )
v7 = (double *)((char *)this + 328);
*v7 = a4;
if ( !v9 )
v8 = (double *)((char *)this + 336);
*v8 = a5;
return result;
}
|
addRiseFallSlew:
PUSH RBX
LEA RAX,[RDI + 0x138]
LEA RCX,[RDI + 0x170]
LEA RDX,[RDI + 0x140]
LEA RSI,[RDI + 0x178]
LEA R8,[RDI + 0x148]
LEA R9,[RDI + 0x180]
LEA R10,[RDI + 0x150]
LEA R11,[RDI + 0x188]
XOR EBX,EBX
CMP dword ptr [RDI + 0x80],0x0
SETZ BL
MOV dword ptr [RDI + RBX*0x8 + 0x2c],0x1
CMOVZ RAX,RCX
CMOVNZ RSI,RDX
MOVSD qword ptr [RAX],XMM0
MOVSD qword ptr [RSI],XMM1
CMOVNZ R9,R8
MOVSD qword ptr [R9],XMM2
CMOVNZ R11,R10
MOVSD qword ptr [R11],XMM3
POP RBX
RET
|
/* LefDefParser::lefiTiming::addRiseFallSlew(double, double, double, double) */
void __thiscall
LefDefParser::lefiTiming::addRiseFallSlew
(lefiTiming *this,double param_1,double param_2,double param_3,double param_4)
{
lefiTiming *plVar1;
lefiTiming *plVar2;
bool bVar3;
plVar2 = this + 0x170;
plVar1 = this + 0x178;
bVar3 = *(int *)(this + 0x80) == 0;
*(int4 *)(this + (ulong)bVar3 * 8 + 0x2c) = 1;
if (!bVar3) {
plVar1 = this + 0x140;
plVar2 = this + 0x138;
}
*(double *)plVar2 = param_1;
*(double *)plVar1 = param_2;
plVar2 = this + 0x180;
if (!bVar3) {
plVar2 = this + 0x148;
}
*(double *)plVar2 = param_3;
plVar2 = this + 0x188;
if (!bVar3) {
plVar2 = this + 0x150;
}
*(double *)plVar2 = param_4;
return;
}
|
|
7,860 |
verify_blockhash_proof
|
corpus-core[P]colibri-stateless/src/chains/eth/verifier/verify_blockhash_proof.c
|
bool verify_blockhash_proof(verify_ctx_t* ctx) {
ssz_ob_t header = ssz_get(&ctx->proof, "header");
ssz_ob_t blockhash_proof = ssz_get(&ctx->proof, "blockhash_proof");
ssz_ob_t sync_committee_bits = ssz_get(&ctx->proof, "sync_committee_bits");
ssz_ob_t sync_committee_signature = ssz_get(&ctx->proof, "sync_committee_signature");
if (ssz_is_error(header) || ssz_is_error(blockhash_proof)) RETURN_VERIFY_ERROR(ctx, "invalid proof, missing header or blockhash_proof!");
if (ssz_is_error(sync_committee_bits) || sync_committee_bits.bytes.len != 64 || ssz_is_error(sync_committee_signature) || sync_committee_signature.bytes.len != 96) RETURN_VERIFY_ERROR(ctx, "invalid proof, missing sync committee bits or signature!");
if (!ctx->data.def || !ssz_is_type(&ctx->data, &ssz_bytes32) || ctx->data.bytes.data == NULL || ctx->data.bytes.len != 32) RETURN_VERIFY_ERROR(ctx, "invalid data, data is not a bytes32!");
if (!verify_beacon_header(&header, ctx->data.bytes.data, blockhash_proof.bytes)) RETURN_VERIFY_ERROR(ctx, "invalid merkle proof for blockhash!");
if (c4_verify_blockroot_signature(ctx, &header, &sync_committee_bits, &sync_committee_signature, 0) != C4_SUCCESS) return false;
ctx->success = true;
return true;
}
|
O0
|
c
|
verify_blockhash_proof:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rsi
addq $0x20, %rsi
leaq -0x28(%rbp), %rdi
leaq 0xac573(%rip), %rdx # 0xdc6f5
callq 0xa1c10
movq -0x10(%rbp), %rsi
addq $0x20, %rsi
leaq -0x40(%rbp), %rdi
leaq 0xad9fd(%rip), %rdx # 0xddb97
callq 0xa1c10
movq -0x10(%rbp), %rsi
addq $0x20, %rsi
leaq -0x58(%rbp), %rdi
leaq 0xaca5a(%rip), %rdx # 0xdcc0c
callq 0xa1c10
movq -0x10(%rbp), %rsi
addq $0x20, %rsi
leaq -0x70(%rbp), %rdi
leaq 0xaca56(%rip), %rdx # 0xdcc20
callq 0xa1c10
leaq -0x28(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x303a0
testb $0x1, %al
jne 0x3021d
leaq -0x40(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x303a0
testb $0x1, %al
jne 0x3021d
jmp 0x30244
jmp 0x3021f
movq -0x10(%rbp), %rdi
addq $0x70, %rdi
leaq 0xad0c3(%rip), %rsi # 0xdd2f1
callq 0xa79c0
movq -0x10(%rbp), %rax
movb $0x0, 0x68(%rax)
movb $0x0, -0x1(%rbp)
jmp 0x30392
leaq -0x58(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x303a0
testb $0x1, %al
jne 0x3029c
cmpl $0x40, -0x58(%rbp)
jne 0x3029c
leaq -0x70(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x303a0
testb $0x1, %al
jne 0x3029c
cmpl $0x60, -0x70(%rbp)
je 0x302c3
jmp 0x3029e
movq -0x10(%rbp), %rdi
addq $0x70, %rdi
leaq 0xad076(%rip), %rsi # 0xdd323
callq 0xa79c0
movq -0x10(%rbp), %rax
movb $0x0, 0x68(%rax)
movb $0x0, -0x1(%rbp)
jmp 0x30392
movq -0x10(%rbp), %rax
cmpq $0x0, 0x48(%rax)
je 0x302fd
movq -0x10(%rbp), %rdi
addq $0x38, %rdi
leaq 0x10896b(%rip), %rsi # 0x138c48
callq 0xa09a0
testb $0x1, %al
jne 0x302e8
jmp 0x302fd
movq -0x10(%rbp), %rax
cmpq $0x0, 0x40(%rax)
je 0x302fd
movq -0x10(%rbp), %rax
cmpl $0x20, 0x38(%rax)
je 0x30321
jmp 0x302ff
movq -0x10(%rbp), %rdi
addq $0x70, %rdi
leaq 0xad899(%rip), %rsi # 0xddba7
callq 0xa79c0
movq -0x10(%rbp), %rax
movb $0x0, 0x68(%rax)
movb $0x0, -0x1(%rbp)
jmp 0x30392
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rsi
movl -0x40(%rbp), %edx
movq -0x38(%rbp), %rcx
leaq -0x28(%rbp), %rdi
callq 0x303d0
testb $0x1, %al
jne 0x30361
jmp 0x3033f
movq -0x10(%rbp), %rdi
addq $0x70, %rdi
leaq 0xad87e(%rip), %rsi # 0xddbcc
callq 0xa79c0
movq -0x10(%rbp), %rax
movb $0x0, 0x68(%rax)
movb $0x0, -0x1(%rbp)
jmp 0x30392
movq -0x10(%rbp), %rdi
leaq -0x28(%rbp), %rsi
leaq -0x58(%rbp), %rdx
leaq -0x70(%rbp), %rcx
xorl %eax, %eax
movl %eax, %r8d
callq 0x2fec0
cmpl $0x0, %eax
je 0x30386
movb $0x0, -0x1(%rbp)
jmp 0x30392
movq -0x10(%rbp), %rax
movb $0x1, 0x68(%rax)
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x90, %rsp
popq %rbp
retq
|
verify_blockhash_proof:
push rbp
mov rbp, rsp
sub rsp, 90h
mov [rbp+var_10], rdi
mov rsi, [rbp+var_10]
add rsi, 20h ; ' '
lea rdi, [rbp+var_28]
lea rdx, aInvalidRespons+15h; "header"
call ssz_get
mov rsi, [rbp+var_10]
add rsi, 20h ; ' '
lea rdi, [rbp+var_40]
lea rdx, aBlockhashProof; "blockhash_proof"
call ssz_get
mov rsi, [rbp+var_10]
add rsi, 20h ; ' '
lea rdi, [rbp+var_58]
lea rdx, aSyncCommitteeB; "sync_committee_bits"
call ssz_get
mov rsi, [rbp+var_10]
add rsi, 20h ; ' '
lea rdi, [rbp+var_70]
lea rdx, aSyncCommitteeS; "sync_committee_signature"
call ssz_get
lea rax, [rbp+var_28]
mov rcx, [rax]
mov [rsp+90h+var_90], rcx
mov rcx, [rax+8]
mov [rsp+90h+var_88], rcx
mov rax, [rax+10h]
mov [rsp+90h+var_80], rax
call ssz_is_error_2
test al, 1
jnz short loc_3021D
lea rax, [rbp+var_40]
mov rcx, [rax]
mov [rsp+90h+var_90], rcx
mov rcx, [rax+8]
mov [rsp+90h+var_88], rcx
mov rax, [rax+10h]
mov [rsp+90h+var_80], rax
call ssz_is_error_2
test al, 1
jnz short loc_3021D
jmp short loc_30244
loc_3021D:
jmp short $+2
loc_3021F:
mov rdi, [rbp+var_10]
add rdi, 70h ; 'p'
lea rsi, aInvalidProofMi; "invalid proof, missing header or blockh"...
call c4_state_add_error
mov rax, [rbp+var_10]
mov byte ptr [rax+68h], 0
mov [rbp+var_1], 0
jmp loc_30392
loc_30244:
lea rax, [rbp+var_58]
mov rcx, [rax]
mov [rsp+90h+var_90], rcx
mov rcx, [rax+8]
mov [rsp+90h+var_88], rcx
mov rax, [rax+10h]
mov [rsp+90h+var_80], rax
call ssz_is_error_2
test al, 1
jnz short loc_3029C
cmp [rbp+var_58], 40h ; '@'
jnz short loc_3029C
lea rax, [rbp+var_70]
mov rcx, [rax]
mov [rsp+90h+var_90], rcx
mov rcx, [rax+8]
mov [rsp+90h+var_88], rcx
mov rax, [rax+10h]
mov [rsp+90h+var_80], rax
call ssz_is_error_2
test al, 1
jnz short loc_3029C
cmp [rbp+var_70], 60h ; '`'
jz short loc_302C3
loc_3029C:
jmp short $+2
loc_3029E:
mov rdi, [rbp+var_10]
add rdi, 70h ; 'p'
lea rsi, aInvalidProofMi_0; "invalid proof, missing sync committee b"...
call c4_state_add_error
mov rax, [rbp+var_10]
mov byte ptr [rax+68h], 0
mov [rbp+var_1], 0
jmp loc_30392
loc_302C3:
mov rax, [rbp+var_10]
cmp qword ptr [rax+48h], 0
jz short loc_302FD
mov rdi, [rbp+var_10]
add rdi, 38h ; '8'
lea rsi, ssz_bytes32
call ssz_is_type
test al, 1
jnz short loc_302E8
jmp short loc_302FD
loc_302E8:
mov rax, [rbp+var_10]
cmp qword ptr [rax+40h], 0
jz short loc_302FD
mov rax, [rbp+var_10]
cmp dword ptr [rax+38h], 20h ; ' '
jz short loc_30321
loc_302FD:
jmp short $+2
loc_302FF:
mov rdi, [rbp+var_10]
add rdi, 70h ; 'p'
lea rsi, aInvalidDataDat; "invalid data, data is not a bytes32!"
call c4_state_add_error
mov rax, [rbp+var_10]
mov byte ptr [rax+68h], 0
mov [rbp+var_1], 0
jmp short loc_30392
loc_30321:
mov rax, [rbp+var_10]
mov rsi, [rax+40h]
mov edx, [rbp+var_40]
mov rcx, [rbp+var_38]
lea rdi, [rbp+var_28]
call verify_beacon_header
test al, 1
jnz short loc_30361
jmp short $+2
loc_3033F:
mov rdi, [rbp+var_10]
add rdi, 70h ; 'p'
lea rsi, aInvalidMerkleP; "invalid merkle proof for blockhash!"
call c4_state_add_error
mov rax, [rbp+var_10]
mov byte ptr [rax+68h], 0
mov [rbp+var_1], 0
jmp short loc_30392
loc_30361:
mov rdi, [rbp+var_10]
lea rsi, [rbp+var_28]
lea rdx, [rbp+var_58]
lea rcx, [rbp+var_70]
xor eax, eax
mov r8d, eax
call c4_verify_blockroot_signature
cmp eax, 0
jz short loc_30386
mov [rbp+var_1], 0
jmp short loc_30392
loc_30386:
mov rax, [rbp+var_10]
mov byte ptr [rax+68h], 1
mov [rbp+var_1], 1
loc_30392:
mov al, [rbp+var_1]
and al, 1
add rsp, 90h
pop rbp
retn
|
char verify_blockhash_proof(long long a1)
{
int v1; // esi
int v2; // edx
int v3; // r8d
int v4; // r9d
int v5; // edx
int v6; // r8d
int v7; // r9d
int v8; // edx
int v9; // r8d
int v10; // r9d
int v11; // edx
int v12; // r8d
int v13; // r9d
long long v15; // [rsp+20h] [rbp-70h] BYREF
long long v16; // [rsp+28h] [rbp-68h]
long long v17; // [rsp+30h] [rbp-60h]
long long v18; // [rsp+38h] [rbp-58h] BYREF
long long v19; // [rsp+40h] [rbp-50h]
long long v20; // [rsp+48h] [rbp-48h]
long long v21; // [rsp+50h] [rbp-40h] BYREF
long long v22; // [rsp+58h] [rbp-38h]
long long v23; // [rsp+60h] [rbp-30h]
long long v24; // [rsp+68h] [rbp-28h] BYREF
long long v25; // [rsp+70h] [rbp-20h]
long long v26; // [rsp+78h] [rbp-18h]
long long v27; // [rsp+80h] [rbp-10h]
v27 = a1;
ssz_get(&v24, a1 + 32, "header");
ssz_get(&v21, v27 + 32, "blockhash_proof");
ssz_get(&v18, v27 + 32, "sync_committee_bits");
v1 = v27 + 32;
ssz_get(&v15, v27 + 32, "sync_committee_signature");
if ( (ssz_is_error_2((unsigned int)&v15, v1, v2, v25, v3, v4, v24, v25, v26) & 1) != 0
|| (ssz_is_error_2((unsigned int)&v15, v1, v5, v22, v6, v7, v21, v22, v23) & 1) != 0 )
{
c4_state_add_error(v27 + 112, "invalid proof, missing header or blockhash_proof!");
*(_BYTE *)(v27 + 104) = 0;
return 0;
}
else if ( (ssz_is_error_2((unsigned int)&v15, v1, v8, v19, v9, v10, v18, v19, v20) & 1) == 0
&& (_DWORD)v18 == 64
&& (ssz_is_error_2((unsigned int)&v15, v1, v11, v16, v12, v13, v15, v16, v17) & 1) == 0
&& (_DWORD)v15 == 96 )
{
if ( *(_QWORD *)(v27 + 72)
&& (ssz_is_type(v27 + 56, &ssz_bytes32) & 1) != 0
&& *(_QWORD *)(v27 + 64)
&& *(_DWORD *)(v27 + 56) == 32 )
{
if ( (verify_beacon_header(&v24, *(_QWORD *)(v27 + 64), (unsigned int)v21, v22) & 1) != 0 )
{
if ( (unsigned int)c4_verify_blockroot_signature(v27, &v24, (long long)&v18, (long long)&v15, 0LL) )
{
return 0;
}
else
{
*(_BYTE *)(v27 + 104) = 1;
return 1;
}
}
else
{
c4_state_add_error(v27 + 112, "invalid merkle proof for blockhash!");
*(_BYTE *)(v27 + 104) = 0;
return 0;
}
}
else
{
c4_state_add_error(v27 + 112, "invalid data, data is not a bytes32!");
*(_BYTE *)(v27 + 104) = 0;
return 0;
}
}
else
{
c4_state_add_error(v27 + 112, "invalid proof, missing sync committee bits or signature!");
*(_BYTE *)(v27 + 104) = 0;
return 0;
}
}
|
verify_blockhash_proof:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
MOV qword ptr [RBP + -0x10],RDI
MOV RSI,qword ptr [RBP + -0x10]
ADD RSI,0x20
LEA RDI,[RBP + -0x28]
LEA RDX,[0x1dc6f5]
CALL 0x001a1c10
MOV RSI,qword ptr [RBP + -0x10]
ADD RSI,0x20
LEA RDI,[RBP + -0x40]
LEA RDX,[0x1ddb97]
CALL 0x001a1c10
MOV RSI,qword ptr [RBP + -0x10]
ADD RSI,0x20
LEA RDI,[RBP + -0x58]
LEA RDX,[0x1dcc0c]
CALL 0x001a1c10
MOV RSI,qword ptr [RBP + -0x10]
ADD RSI,0x20
LEA RDI,[RBP + -0x70]
LEA RDX,[0x1dcc20]
CALL 0x001a1c10
LEA RAX,[RBP + -0x28]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x001303a0
TEST AL,0x1
JNZ 0x0013021d
LEA RAX,[RBP + -0x40]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x001303a0
TEST AL,0x1
JNZ 0x0013021d
JMP 0x00130244
LAB_0013021d:
JMP 0x0013021f
LAB_0013021f:
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x70
LEA RSI,[0x1dd2f1]
CALL 0x001a79c0
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x68],0x0
MOV byte ptr [RBP + -0x1],0x0
JMP 0x00130392
LAB_00130244:
LEA RAX,[RBP + -0x58]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x001303a0
TEST AL,0x1
JNZ 0x0013029c
CMP dword ptr [RBP + -0x58],0x40
JNZ 0x0013029c
LEA RAX,[RBP + -0x70]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x001303a0
TEST AL,0x1
JNZ 0x0013029c
CMP dword ptr [RBP + -0x70],0x60
JZ 0x001302c3
LAB_0013029c:
JMP 0x0013029e
LAB_0013029e:
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x70
LEA RSI,[0x1dd323]
CALL 0x001a79c0
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x68],0x0
MOV byte ptr [RBP + -0x1],0x0
JMP 0x00130392
LAB_001302c3:
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x48],0x0
JZ 0x001302fd
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x38
LEA RSI,[0x238c48]
CALL 0x001a09a0
TEST AL,0x1
JNZ 0x001302e8
JMP 0x001302fd
LAB_001302e8:
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x40],0x0
JZ 0x001302fd
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x38],0x20
JZ 0x00130321
LAB_001302fd:
JMP 0x001302ff
LAB_001302ff:
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x70
LEA RSI,[0x1ddba7]
CALL 0x001a79c0
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x68],0x0
MOV byte ptr [RBP + -0x1],0x0
JMP 0x00130392
LAB_00130321:
MOV RAX,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RAX + 0x40]
MOV EDX,dword ptr [RBP + -0x40]
MOV RCX,qword ptr [RBP + -0x38]
LEA RDI,[RBP + -0x28]
CALL 0x001303d0
TEST AL,0x1
JNZ 0x00130361
JMP 0x0013033f
LAB_0013033f:
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x70
LEA RSI,[0x1ddbcc]
CALL 0x001a79c0
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x68],0x0
MOV byte ptr [RBP + -0x1],0x0
JMP 0x00130392
LAB_00130361:
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[RBP + -0x28]
LEA RDX,[RBP + -0x58]
LEA RCX,[RBP + -0x70]
XOR EAX,EAX
MOV R8D,EAX
CALL 0x0012fec0
CMP EAX,0x0
JZ 0x00130386
MOV byte ptr [RBP + -0x1],0x0
JMP 0x00130392
LAB_00130386:
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x68],0x1
MOV byte ptr [RBP + -0x1],0x1
LAB_00130392:
MOV AL,byte ptr [RBP + -0x1]
AND AL,0x1
ADD RSP,0x90
POP RBP
RET
|
int1 verify_blockhash_proof(long param_1)
{
int iVar1;
ulong uVar2;
int8 in_R9;
int8 uVar3;
int local_78;
int4 uStack_74;
int8 local_70;
int8 local_68;
int local_60 [6];
int4 local_48 [2];
int8 local_40;
int1 local_30 [24];
long local_18;
local_18 = param_1;
ssz_get(local_30,param_1 + 0x20,"header");
ssz_get(local_48,local_18 + 0x20,"blockhash_proof");
ssz_get(local_60,local_18 + 0x20,"sync_committee_bits");
ssz_get(&local_78,local_18 + 0x20,"sync_committee_signature");
uVar2 = ssz_is_error();
if (((uVar2 & 1) == 0) && (uVar2 = ssz_is_error(), (uVar2 & 1) == 0)) {
uVar2 = ssz_is_error();
if (((uVar2 & 1) == 0) && (local_60[0] == 0x40)) {
uVar3 = CONCAT44(uStack_74,local_78);
uVar2 = ssz_is_error();
if (((uVar2 & 1) == 0) && (local_78 == 0x60)) {
if ((((*(long *)(local_18 + 0x48) == 0) ||
(uVar2 = ssz_is_type(local_18 + 0x38,ssz_bytes32), (uVar2 & 1) == 0)) ||
(*(long *)(local_18 + 0x40) == 0)) || (*(int *)(local_18 + 0x38) != 0x20)) {
c4_state_add_error(local_18 + 0x70,"invalid data, data is not a bytes32!");
*(int1 *)(local_18 + 0x68) = 0;
return 0;
}
uVar2 = verify_beacon_header(local_30,*(int8 *)(local_18 + 0x40),local_48[0],local_40)
;
if ((uVar2 & 1) == 0) {
c4_state_add_error(local_18 + 0x70,"invalid merkle proof for blockhash!");
*(int1 *)(local_18 + 0x68) = 0;
return 0;
}
iVar1 = c4_verify_blockroot_signature
(local_18,local_30,local_60,&local_78,0,in_R9,uVar3,local_70,local_68);
if (iVar1 != 0) {
return 0;
}
*(int1 *)(local_18 + 0x68) = 1;
return 1;
}
}
c4_state_add_error(local_18 + 0x70,"invalid proof, missing sync committee bits or signature!");
*(int1 *)(local_18 + 0x68) = 0;
}
else {
c4_state_add_error(local_18 + 0x70,"invalid proof, missing header or blockhash_proof!");
*(int1 *)(local_18 + 0x68) = 0;
}
return 0;
}
|
|
7,861 |
verify_blockhash_proof
|
corpus-core[P]colibri-stateless/src/chains/eth/verifier/verify_blockhash_proof.c
|
bool verify_blockhash_proof(verify_ctx_t* ctx) {
ssz_ob_t header = ssz_get(&ctx->proof, "header");
ssz_ob_t blockhash_proof = ssz_get(&ctx->proof, "blockhash_proof");
ssz_ob_t sync_committee_bits = ssz_get(&ctx->proof, "sync_committee_bits");
ssz_ob_t sync_committee_signature = ssz_get(&ctx->proof, "sync_committee_signature");
if (ssz_is_error(header) || ssz_is_error(blockhash_proof)) RETURN_VERIFY_ERROR(ctx, "invalid proof, missing header or blockhash_proof!");
if (ssz_is_error(sync_committee_bits) || sync_committee_bits.bytes.len != 64 || ssz_is_error(sync_committee_signature) || sync_committee_signature.bytes.len != 96) RETURN_VERIFY_ERROR(ctx, "invalid proof, missing sync committee bits or signature!");
if (!ctx->data.def || !ssz_is_type(&ctx->data, &ssz_bytes32) || ctx->data.bytes.data == NULL || ctx->data.bytes.len != 32) RETURN_VERIFY_ERROR(ctx, "invalid data, data is not a bytes32!");
if (!verify_beacon_header(&header, ctx->data.bytes.data, blockhash_proof.bytes)) RETURN_VERIFY_ERROR(ctx, "invalid merkle proof for blockhash!");
if (c4_verify_blockroot_signature(ctx, &header, &sync_committee_bits, &sync_committee_signature, 0) != C4_SUCCESS) return false;
ctx->success = true;
return true;
}
|
O1
|
c
|
verify_blockhash_proof:
pushq %r15
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %rdi, %rbx
leaq 0x20(%rdi), %r14
leaq 0x59907(%rip), %rdx # 0x8566d
leaq 0x48(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x594b1
leaq 0x5ac3c(%rip), %rdx # 0x869b9
leaq 0x30(%rsp), %rdi
movq %r14, %rsi
callq 0x594b1
leaq 0x59ea7(%rip), %rdx # 0x85c38
leaq 0x18(%rsp), %rdi
movq %r14, %rsi
callq 0x594b1
leaq 0x59ea7(%rip), %rdx # 0x85c4c
movq %rsp, %rdi
movq %r14, %rsi
callq 0x594b1
cmpq $0x0, 0x10(%r15)
leaq 0x5a575(%rip), %r14 # 0x86331
je 0x2bea2
cmpq $0x0, 0x50(%rsp)
je 0x2bea2
cmpq $0x0, 0x40(%rsp)
je 0x2bea2
cmpq $0x0, 0x38(%rsp)
je 0x2bea2
cmpq $0x0, 0x28(%rsp)
leaq 0x5a570(%rip), %r14 # 0x86363
je 0x2bea2
cmpq $0x0, 0x20(%rsp)
je 0x2bea2
cmpl $0x40, 0x18(%rsp)
jne 0x2bea2
cmpq $0x0, 0x10(%rsp)
je 0x2bea2
cmpq $0x0, 0x8(%rsp)
je 0x2bea2
cmpl $0x60, (%rsp)
jne 0x2bea2
leaq 0x5ab98(%rip), %r14 # 0x869c9
cmpq $0x0, 0x48(%rbx)
je 0x2bea2
leaq 0x38(%rbx), %r15
leaq 0x98e05(%rip), %rsi # 0xc4c48
movq %r15, %rdi
callq 0x58a79
testb %al, %al
je 0x2bea2
movq 0x40(%rbx), %rsi
testq %rsi, %rsi
je 0x2bea2
cmpl $0x20, (%r15)
jne 0x2bea2
movl 0x30(%rsp), %edx
movq 0x38(%rsp), %rcx
leaq 0x48(%rsp), %rdi
callq 0x2bec3
testb %al, %al
je 0x2be9b
xorl %r14d, %r14d
leaq 0x48(%rsp), %rsi
leaq 0x18(%rsp), %rdx
movq %rsp, %rcx
movq %rbx, %rdi
xorl %r8d, %r8d
callq 0x2bbd2
testl %eax, %eax
jne 0x2beb6
movb $0x1, %al
movb $0x1, %r14b
jmp 0x2beb3
leaq 0x5ab4c(%rip), %r14 # 0x869ee
leaq 0x70(%rbx), %rdi
movq %r14, %rsi
callq 0x5cf4d
xorl %eax, %eax
xorl %r14d, %r14d
movb %al, 0x68(%rbx)
movl %r14d, %eax
addq $0x60, %rsp
popq %rbx
popq %r14
popq %r15
retq
|
verify_blockhash_proof:
push r15
push r14
push rbx
sub rsp, 60h
mov rbx, rdi
lea r14, [rdi+20h]
lea rdx, aInvalidRespons+15h; "header"
lea r15, [rsp+78h+var_30]
mov rdi, r15
mov rsi, r14
call ssz_get
lea rdx, aBlockhashProof; "blockhash_proof"
lea rdi, [rsp+78h+var_48]
mov rsi, r14
call ssz_get
lea rdx, aSyncCommitteeB; "sync_committee_bits"
lea rdi, [rsp+78h+var_60]
mov rsi, r14
call ssz_get
lea rdx, aSyncCommitteeS; "sync_committee_signature"
mov rdi, rsp
mov rsi, r14
call ssz_get
cmp qword ptr [r15+10h], 0
lea r14, aInvalidProofMi; "invalid proof, missing header or blockh"...
jz loc_2BEA2
cmp [rsp+78h+var_28], 0
jz loc_2BEA2
cmp [rsp+78h+var_38], 0
jz loc_2BEA2
cmp [rsp+78h+var_40], 0
jz loc_2BEA2
cmp [rsp+78h+var_50], 0
lea r14, aInvalidProofMi_0; "invalid proof, missing sync committee b"...
jz loc_2BEA2
cmp [rsp+78h+var_58], 0
jz loc_2BEA2
cmp [rsp+78h+var_60], 40h ; '@'
jnz loc_2BEA2
cmp [rsp+78h+var_68], 0
jz loc_2BEA2
cmp [rsp+78h+var_70], 0
jz short loc_2BEA2
cmp [rsp+78h+var_78], 60h ; '`'
jnz short loc_2BEA2
lea r14, aInvalidDataDat; "invalid data, data is not a bytes32!"
cmp qword ptr [rbx+48h], 0
jz short loc_2BEA2
lea r15, [rbx+38h]
lea rsi, ssz_bytes32
mov rdi, r15
call ssz_is_type
test al, al
jz short loc_2BEA2
mov rsi, [rbx+40h]
test rsi, rsi
jz short loc_2BEA2
cmp dword ptr [r15], 20h ; ' '
jnz short loc_2BEA2
mov edx, [rsp+78h+var_48]
mov rcx, [rsp+78h+var_40]
lea rdi, [rsp+78h+var_30]
call verify_beacon_header
test al, al
jz short loc_2BE9B
xor r14d, r14d
lea rsi, [rsp+78h+var_30]
lea rdx, [rsp+78h+var_60]
mov rcx, rsp
mov rdi, rbx
xor r8d, r8d
call c4_verify_blockroot_signature
test eax, eax
jnz short loc_2BEB6
mov al, 1
mov r14b, 1
jmp short loc_2BEB3
loc_2BE9B:
lea r14, aInvalidMerkleP; "invalid merkle proof for blockhash!"
loc_2BEA2:
lea rdi, [rbx+70h]
mov rsi, r14
call c4_state_add_error
xor eax, eax
xor r14d, r14d
loc_2BEB3:
mov [rbx+68h], al
loc_2BEB6:
mov eax, r14d
add rsp, 60h
pop rbx
pop r14
pop r15
retn
|
long long verify_blockhash_proof(long long a1)
{
const char *v1; // r14
long long v2; // rsi
unsigned int v3; // r14d
char v4; // al
int v6; // [rsp+0h] [rbp-78h] BYREF
long long v7; // [rsp+8h] [rbp-70h]
long long v8; // [rsp+10h] [rbp-68h]
int v9; // [rsp+18h] [rbp-60h] BYREF
long long v10; // [rsp+20h] [rbp-58h]
long long v11; // [rsp+28h] [rbp-50h]
unsigned int v12; // [rsp+30h] [rbp-48h] BYREF
long long v13; // [rsp+38h] [rbp-40h]
long long v14; // [rsp+40h] [rbp-38h]
_QWORD v15[6]; // [rsp+48h] [rbp-30h] BYREF
ssz_get(v15, a1 + 32, "header");
ssz_get(&v12, a1 + 32, "blockhash_proof");
ssz_get(&v9, a1 + 32, "sync_committee_bits");
ssz_get(&v6, a1 + 32, "sync_committee_signature");
v1 = "invalid proof, missing header or blockhash_proof!";
if ( !v15[2] )
goto LABEL_19;
if ( !v15[1] )
goto LABEL_19;
if ( !v14 )
goto LABEL_19;
if ( !v13 )
goto LABEL_19;
v1 = "invalid proof, missing sync committee bits or signature!";
if ( !v11 )
goto LABEL_19;
if ( !v10 )
goto LABEL_19;
if ( v9 != 64 )
goto LABEL_19;
if ( !v8 )
goto LABEL_19;
if ( !v7 )
goto LABEL_19;
if ( v6 != 96 )
goto LABEL_19;
v1 = "invalid data, data is not a bytes32!";
if ( !*(_QWORD *)(a1 + 72) )
goto LABEL_19;
if ( !(unsigned __int8)ssz_is_type(a1 + 56, &ssz_bytes32) )
goto LABEL_19;
v2 = *(_QWORD *)(a1 + 64);
if ( !v2 || *(_DWORD *)(a1 + 56) != 32 )
goto LABEL_19;
if ( !(unsigned __int8)verify_beacon_header(v15, v2, v12, v13) )
{
v1 = "invalid merkle proof for blockhash!";
LABEL_19:
c4_state_add_error(a1 + 112, v1);
v4 = 0;
v3 = 0;
goto LABEL_20;
}
v3 = 0;
if ( !(unsigned int)c4_verify_blockroot_signature(a1, v15, (long long)&v9, (long long)&v6, 0LL) )
{
v4 = 1;
LOBYTE(v3) = 1;
LABEL_20:
*(_BYTE *)(a1 + 104) = v4;
}
return v3;
}
|
verify_blockhash_proof:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x60
MOV RBX,RDI
LEA R14,[RDI + 0x20]
LEA RDX,[0x18566d]
LEA R15,[RSP + 0x48]
MOV RDI,R15
MOV RSI,R14
CALL 0x001594b1
LEA RDX,[0x1869b9]
LEA RDI,[RSP + 0x30]
MOV RSI,R14
CALL 0x001594b1
LEA RDX,[0x185c38]
LEA RDI,[RSP + 0x18]
MOV RSI,R14
CALL 0x001594b1
LEA RDX,[0x185c4c]
MOV RDI,RSP
MOV RSI,R14
CALL 0x001594b1
CMP qword ptr [R15 + 0x10],0x0
LEA R14,[0x186331]
JZ 0x0012bea2
CMP qword ptr [RSP + 0x50],0x0
JZ 0x0012bea2
CMP qword ptr [RSP + 0x40],0x0
JZ 0x0012bea2
CMP qword ptr [RSP + 0x38],0x0
JZ 0x0012bea2
CMP qword ptr [RSP + 0x28],0x0
LEA R14,[0x186363]
JZ 0x0012bea2
CMP qword ptr [RSP + 0x20],0x0
JZ 0x0012bea2
CMP dword ptr [RSP + 0x18],0x40
JNZ 0x0012bea2
CMP qword ptr [RSP + 0x10],0x0
JZ 0x0012bea2
CMP qword ptr [RSP + 0x8],0x0
JZ 0x0012bea2
CMP dword ptr [RSP],0x60
JNZ 0x0012bea2
LEA R14,[0x1869c9]
CMP qword ptr [RBX + 0x48],0x0
JZ 0x0012bea2
LEA R15,[RBX + 0x38]
LEA RSI,[0x1c4c48]
MOV RDI,R15
CALL 0x00158a79
TEST AL,AL
JZ 0x0012bea2
MOV RSI,qword ptr [RBX + 0x40]
TEST RSI,RSI
JZ 0x0012bea2
CMP dword ptr [R15],0x20
JNZ 0x0012bea2
MOV EDX,dword ptr [RSP + 0x30]
MOV RCX,qword ptr [RSP + 0x38]
LEA RDI,[RSP + 0x48]
CALL 0x0012bec3
TEST AL,AL
JZ 0x0012be9b
XOR R14D,R14D
LEA RSI,[RSP + 0x48]
LEA RDX,[RSP + 0x18]
MOV RCX,RSP
MOV RDI,RBX
XOR R8D,R8D
CALL 0x0012bbd2
TEST EAX,EAX
JNZ 0x0012beb6
MOV AL,0x1
MOV R14B,0x1
JMP 0x0012beb3
LAB_0012be9b:
LEA R14,[0x1869ee]
LAB_0012bea2:
LEA RDI,[RBX + 0x70]
MOV RSI,R14
CALL 0x0015cf4d
XOR EAX,EAX
XOR R14D,R14D
LAB_0012beb3:
MOV byte ptr [RBX + 0x68],AL
LAB_0012beb6:
MOV EAX,R14D
ADD RSP,0x60
POP RBX
POP R14
POP R15
RET
|
int8 verify_blockhash_proof(long param_1)
{
long lVar1;
char cVar2;
int1 uVar3;
int iVar4;
char *pcVar5;
int8 uVar6;
int local_78 [2];
long local_70;
long local_68;
int local_60 [2];
long local_58;
long local_50;
int4 local_48 [2];
long local_40;
long local_38;
int1 local_30 [8];
long local_28;
long local_20;
lVar1 = param_1 + 0x20;
ssz_get(local_30,lVar1,"header");
ssz_get(local_48,lVar1,"blockhash_proof");
ssz_get(local_60,lVar1,"sync_committee_bits");
ssz_get(local_78,lVar1,"sync_committee_signature");
pcVar5 = "invalid proof, missing header or blockhash_proof!";
if (((((((local_20 != 0) && (local_28 != 0)) && (local_38 != 0)) &&
((local_40 != 0 &&
(pcVar5 = "invalid proof, missing sync committee bits or signature!", local_50 != 0)))) &&
((local_58 != 0 && ((local_60[0] == 0x40 && (local_68 != 0)))))) && (local_70 != 0)) &&
((local_78[0] == 0x60 &&
(pcVar5 = "invalid data, data is not a bytes32!", *(long *)(param_1 + 0x48) != 0)))) {
cVar2 = ssz_is_type((int *)(param_1 + 0x38),ssz_bytes32);
if ((cVar2 != '\0') && ((*(long *)(param_1 + 0x40) != 0 && (*(int *)(param_1 + 0x38) == 0x20))))
{
cVar2 = verify_beacon_header(local_30,*(long *)(param_1 + 0x40),local_48[0],local_40);
if (cVar2 != '\0') {
iVar4 = c4_verify_blockroot_signature(param_1,local_30,local_60,local_78,0);
if (iVar4 != 0) {
return 0;
}
uVar3 = 1;
uVar6 = 1;
goto LAB_0012beb3;
}
pcVar5 = "invalid merkle proof for blockhash!";
}
}
c4_state_add_error(param_1 + 0x70,pcVar5);
uVar3 = 0;
uVar6 = 0;
LAB_0012beb3:
*(int1 *)(param_1 + 0x68) = uVar3;
return uVar6;
}
|
|
7,862 |
verify_blockhash_proof
|
corpus-core[P]colibri-stateless/src/chains/eth/verifier/verify_blockhash_proof.c
|
bool verify_blockhash_proof(verify_ctx_t* ctx) {
ssz_ob_t header = ssz_get(&ctx->proof, "header");
ssz_ob_t blockhash_proof = ssz_get(&ctx->proof, "blockhash_proof");
ssz_ob_t sync_committee_bits = ssz_get(&ctx->proof, "sync_committee_bits");
ssz_ob_t sync_committee_signature = ssz_get(&ctx->proof, "sync_committee_signature");
if (ssz_is_error(header) || ssz_is_error(blockhash_proof)) RETURN_VERIFY_ERROR(ctx, "invalid proof, missing header or blockhash_proof!");
if (ssz_is_error(sync_committee_bits) || sync_committee_bits.bytes.len != 64 || ssz_is_error(sync_committee_signature) || sync_committee_signature.bytes.len != 96) RETURN_VERIFY_ERROR(ctx, "invalid proof, missing sync committee bits or signature!");
if (!ctx->data.def || !ssz_is_type(&ctx->data, &ssz_bytes32) || ctx->data.bytes.data == NULL || ctx->data.bytes.len != 32) RETURN_VERIFY_ERROR(ctx, "invalid data, data is not a bytes32!");
if (!verify_beacon_header(&header, ctx->data.bytes.data, blockhash_proof.bytes)) RETURN_VERIFY_ERROR(ctx, "invalid merkle proof for blockhash!");
if (c4_verify_blockroot_signature(ctx, &header, &sync_committee_bits, &sync_committee_signature, 0) != C4_SUCCESS) return false;
ctx->success = true;
return true;
}
|
O2
|
c
|
verify_blockhash_proof:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xa0, %rsp
movq %rdi, %rbx
leaq 0x20(%rdi), %r14
leaq 0x4a1f3(%rip), %rdx # 0x7466d
leaq 0x50(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x4d119
leaq 0x4b528(%rip), %rdx # 0x759b9
leaq 0x38(%rsp), %rdi
movq %r14, %rsi
callq 0x4d119
leaq 0x4a793(%rip), %rdx # 0x74c38
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
callq 0x4d119
leaq 0x4a793(%rip), %rdx # 0x74c4c
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x4d119
cmpq $0x0, 0x10(%r15)
leaq 0x4ae5f(%rip), %r14 # 0x75331
je 0x2a5f6
cmpq $0x0, 0x58(%rsp)
je 0x2a5f6
cmpq $0x0, 0x48(%rsp)
je 0x2a5f6
cmpq $0x0, 0x40(%rsp)
je 0x2a5f6
cmpq $0x0, 0x30(%rsp)
leaq 0x4ae5a(%rip), %r14 # 0x75363
je 0x2a5f6
cmpq $0x0, 0x28(%rsp)
je 0x2a5f6
cmpl $0x40, 0x20(%rsp)
jne 0x2a5f6
cmpq $0x0, 0x18(%rsp)
je 0x2a5f6
cmpq $0x0, 0x10(%rsp)
je 0x2a5f6
cmpl $0x60, 0x8(%rsp)
jne 0x2a5f6
leaq 0x4b479(%rip), %r14 # 0x759c9
cmpq $0x0, 0x48(%rbx)
je 0x2a5f6
leaq 0x38(%rbx), %r12
leaq 0x916e2(%rip), %rsi # 0xbbc48
movq %r12, %rdi
callq 0x4c6fc
testb %al, %al
je 0x2a5f6
movq 0x40(%rbx), %r15
testq %r15, %r15
je 0x2a5f6
cmpl $0x20, (%r12)
jne 0x2a5f6
movl 0x38(%rsp), %ebp
movq 0x40(%rsp), %r14
leaq 0x4a9ee(%rip), %rdx # 0x74f84
leaq 0x68(%rsp), %r12
leaq 0x50(%rsp), %rsi
movq %r12, %rdi
callq 0x4d119
leaq 0x80(%rsp), %r8
movl $0x32c, %ecx # imm = 0x32C
movl %ebp, %edi
movq %r14, %rsi
movq %r15, %rdx
callq 0x4db7a
cmpq $0x0, 0x10(%r12)
je 0x2a5ef
movq 0x70(%rsp), %rsi
testq %rsi, %rsi
je 0x2a5ef
cmpl $0x20, 0x68(%rsp)
jne 0x2a5ef
leaq 0x80(%rsp), %rdi
pushq $0x20
popq %rdx
callq 0x22380
testl %eax, %eax
je 0x2a61d
leaq 0x4b3f8(%rip), %r14 # 0x759ee
leaq 0x70(%rbx), %rdi
movq %r14, %rsi
callq 0x50675
xorl %eax, %eax
xorl %r14d, %r14d
movb %al, 0x68(%rbx)
movl %r14d, %eax
addq $0xa0, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
xorl %r14d, %r14d
leaq 0x50(%rsp), %rsi
leaq 0x20(%rsp), %rdx
leaq 0x8(%rsp), %rcx
movq %rbx, %rdi
xorl %r8d, %r8d
callq 0x2a2e4
testl %eax, %eax
jne 0x2a60a
movb $0x1, %al
movb $0x1, %r14b
jmp 0x2a607
nopl (%rax)
|
verify_blockhash_proof:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 0A0h
mov rbx, rdi
lea r14, [rdi+20h]
lea rdx, aInvalidRespons+15h; "header"
lea r15, [rsp+0C8h+var_78]
mov rdi, r15
mov rsi, r14
call ssz_get
lea rdx, aBlockhashProof; "blockhash_proof"
lea rdi, [rsp+0C8h+var_90]
mov rsi, r14
call ssz_get
lea rdx, aSyncCommitteeB; "sync_committee_bits"
lea rdi, [rsp+0C8h+var_A8]
mov rsi, r14
call ssz_get
lea rdx, aSyncCommitteeS; "sync_committee_signature"
lea rdi, [rsp+0C8h+var_C0]
mov rsi, r14
call ssz_get
cmp qword ptr [r15+10h], 0
lea r14, aInvalidProofMi; "invalid proof, missing header or blockh"...
jz loc_2A5F6
cmp [rsp+0C8h+var_70], 0
jz loc_2A5F6
cmp [rsp+0C8h+var_80], 0
jz loc_2A5F6
cmp [rsp+0C8h+var_88], 0
jz loc_2A5F6
cmp [rsp+0C8h+var_98], 0
lea r14, aInvalidProofMi_0; "invalid proof, missing sync committee b"...
jz loc_2A5F6
cmp [rsp+0C8h+var_A0], 0
jz loc_2A5F6
cmp [rsp+0C8h+var_A8], 40h ; '@'
jnz loc_2A5F6
cmp [rsp+0C8h+var_B0], 0
jz loc_2A5F6
cmp [rsp+0C8h+var_B8], 0
jz loc_2A5F6
cmp [rsp+0C8h+var_C0], 60h ; '`'
jnz loc_2A5F6
lea r14, aInvalidDataDat; "invalid data, data is not a bytes32!"
cmp qword ptr [rbx+48h], 0
jz loc_2A5F6
lea r12, [rbx+38h]
lea rsi, ssz_bytes32
mov rdi, r12
call ssz_is_type
test al, al
jz loc_2A5F6
mov r15, [rbx+40h]
test r15, r15
jz short loc_2A5F6
cmp dword ptr [r12], 20h ; ' '
jnz short loc_2A5F6
mov ebp, [rsp+0C8h+var_90]
mov r14, [rsp+0C8h+var_88]
lea rdx, aBodyroot; "bodyRoot"
lea r12, [rsp+0C8h+var_60]
lea rsi, [rsp+0C8h+var_78]
mov rdi, r12
call ssz_get
lea r8, [rsp+0C8h+var_48]
mov ecx, 32Ch
mov edi, ebp
mov rsi, r14
mov rdx, r15
call ssz_verify_single_merkle_proof
cmp qword ptr [r12+10h], 0
jz short loc_2A5EF
mov rsi, [rsp+0C8h+var_58]
test rsi, rsi
jz short loc_2A5EF
cmp [rsp+0C8h+var_60], 20h ; ' '
jnz short loc_2A5EF
lea rdi, [rsp+0C8h+var_48]
push 20h ; ' '
pop rdx
call _bcmp
test eax, eax
jz short loc_2A61D
loc_2A5EF:
lea r14, aInvalidMerkleP; "invalid merkle proof for blockhash!"
loc_2A5F6:
lea rdi, [rbx+70h]
mov rsi, r14
call c4_state_add_error
xor eax, eax
xor r14d, r14d
loc_2A607:
mov [rbx+68h], al
loc_2A60A:
mov eax, r14d
add rsp, 0A0h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_2A61D:
xor r14d, r14d
lea rsi, [rsp+0C8h+var_78]
lea rdx, [rsp+0C8h+var_A8]
lea rcx, [rsp+0C8h+var_C0]
mov rdi, rbx
xor r8d, r8d
call c4_verify_blockroot_signature
test eax, eax
jnz short loc_2A60A
mov al, 1
mov r14b, 1
jmp short loc_2A607
|
long long verify_blockhash_proof(long long a1)
{
const char *v1; // r14
long long v2; // r15
unsigned int v3; // ebp
long long v4; // r14
char v5; // al
unsigned int v6; // r14d
int v8; // [rsp+8h] [rbp-C0h] BYREF
long long v9; // [rsp+10h] [rbp-B8h]
long long v10; // [rsp+18h] [rbp-B0h]
int v11; // [rsp+20h] [rbp-A8h] BYREF
long long v12; // [rsp+28h] [rbp-A0h]
long long v13; // [rsp+30h] [rbp-98h]
unsigned int v14; // [rsp+38h] [rbp-90h] BYREF
long long v15; // [rsp+40h] [rbp-88h]
long long v16; // [rsp+48h] [rbp-80h]
_QWORD v17[3]; // [rsp+50h] [rbp-78h] BYREF
int v18; // [rsp+68h] [rbp-60h] BYREF
long long v19; // [rsp+70h] [rbp-58h]
long long v20; // [rsp+78h] [rbp-50h]
_BYTE v21[72]; // [rsp+80h] [rbp-48h] BYREF
ssz_get(v17, a1 + 32, "header");
ssz_get(&v14, a1 + 32, "blockhash_proof");
ssz_get(&v11, a1 + 32, "sync_committee_bits");
ssz_get(&v8, a1 + 32, "sync_committee_signature");
v1 = "invalid proof, missing header or blockhash_proof!";
if ( !v17[2] )
goto LABEL_20;
if ( !v17[1] )
goto LABEL_20;
if ( !v16 )
goto LABEL_20;
if ( !v15 )
goto LABEL_20;
v1 = "invalid proof, missing sync committee bits or signature!";
if ( !v13 )
goto LABEL_20;
if ( !v12 )
goto LABEL_20;
if ( v11 != 64 )
goto LABEL_20;
if ( !v10 )
goto LABEL_20;
if ( !v9 )
goto LABEL_20;
if ( v8 != 96 )
goto LABEL_20;
v1 = "invalid data, data is not a bytes32!";
if ( !*(_QWORD *)(a1 + 72) )
goto LABEL_20;
if ( !(unsigned __int8)ssz_is_type(a1 + 56, &ssz_bytes32) )
goto LABEL_20;
v2 = *(_QWORD *)(a1 + 64);
if ( !v2 || *(_DWORD *)(a1 + 56) != 32 )
goto LABEL_20;
v3 = v14;
v4 = v15;
ssz_get(&v18, v17, "bodyRoot");
ssz_verify_single_merkle_proof(v3, v4, v2, 812LL, v21);
if ( !v20 || !v19 || v18 != 32 || (unsigned int)bcmp(v21, v19, 32LL) )
{
v1 = "invalid merkle proof for blockhash!";
LABEL_20:
c4_state_add_error(a1 + 112, v1);
v5 = 0;
v6 = 0;
goto LABEL_21;
}
v6 = 0;
if ( (unsigned int)c4_verify_blockroot_signature(a1, v17, (long long)&v11, (long long)&v8, 0LL) )
return v6;
v5 = 1;
LOBYTE(v6) = 1;
LABEL_21:
*(_BYTE *)(a1 + 104) = v5;
return v6;
}
|
verify_blockhash_proof:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0xa0
MOV RBX,RDI
LEA R14,[RDI + 0x20]
LEA RDX,[0x17466d]
LEA R15,[RSP + 0x50]
MOV RDI,R15
MOV RSI,R14
CALL 0x0014d119
LEA RDX,[0x1759b9]
LEA RDI,[RSP + 0x38]
MOV RSI,R14
CALL 0x0014d119
LEA RDX,[0x174c38]
LEA RDI,[RSP + 0x20]
MOV RSI,R14
CALL 0x0014d119
LEA RDX,[0x174c4c]
LEA RDI,[RSP + 0x8]
MOV RSI,R14
CALL 0x0014d119
CMP qword ptr [R15 + 0x10],0x0
LEA R14,[0x175331]
JZ 0x0012a5f6
CMP qword ptr [RSP + 0x58],0x0
JZ 0x0012a5f6
CMP qword ptr [RSP + 0x48],0x0
JZ 0x0012a5f6
CMP qword ptr [RSP + 0x40],0x0
JZ 0x0012a5f6
CMP qword ptr [RSP + 0x30],0x0
LEA R14,[0x175363]
JZ 0x0012a5f6
CMP qword ptr [RSP + 0x28],0x0
JZ 0x0012a5f6
CMP dword ptr [RSP + 0x20],0x40
JNZ 0x0012a5f6
CMP qword ptr [RSP + 0x18],0x0
JZ 0x0012a5f6
CMP qword ptr [RSP + 0x10],0x0
JZ 0x0012a5f6
CMP dword ptr [RSP + 0x8],0x60
JNZ 0x0012a5f6
LEA R14,[0x1759c9]
CMP qword ptr [RBX + 0x48],0x0
JZ 0x0012a5f6
LEA R12,[RBX + 0x38]
LEA RSI,[0x1bbc48]
MOV RDI,R12
CALL 0x0014c6fc
TEST AL,AL
JZ 0x0012a5f6
MOV R15,qword ptr [RBX + 0x40]
TEST R15,R15
JZ 0x0012a5f6
CMP dword ptr [R12],0x20
JNZ 0x0012a5f6
MOV EBP,dword ptr [RSP + 0x38]
MOV R14,qword ptr [RSP + 0x40]
LEA RDX,[0x174f84]
LEA R12,[RSP + 0x68]
LEA RSI,[RSP + 0x50]
MOV RDI,R12
CALL 0x0014d119
LEA R8,[RSP + 0x80]
MOV ECX,0x32c
MOV EDI,EBP
MOV RSI,R14
MOV RDX,R15
CALL 0x0014db7a
CMP qword ptr [R12 + 0x10],0x0
JZ 0x0012a5ef
MOV RSI,qword ptr [RSP + 0x70]
TEST RSI,RSI
JZ 0x0012a5ef
CMP dword ptr [RSP + 0x68],0x20
JNZ 0x0012a5ef
LEA RDI,[RSP + 0x80]
PUSH 0x20
POP RDX
CALL 0x00122380
TEST EAX,EAX
JZ 0x0012a61d
LAB_0012a5ef:
LEA R14,[0x1759ee]
LAB_0012a5f6:
LEA RDI,[RBX + 0x70]
MOV RSI,R14
CALL 0x00150675
XOR EAX,EAX
XOR R14D,R14D
LAB_0012a607:
MOV byte ptr [RBX + 0x68],AL
LAB_0012a60a:
MOV EAX,R14D
ADD RSP,0xa0
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_0012a61d:
XOR R14D,R14D
LEA RSI,[RSP + 0x50]
LEA RDX,[RSP + 0x20]
LEA RCX,[RSP + 0x8]
MOV RDI,RBX
XOR R8D,R8D
CALL 0x0012a2e4
TEST EAX,EAX
JNZ 0x0012a60a
MOV AL,0x1
MOV R14B,0x1
JMP 0x0012a607
|
int8 verify_blockhash_proof(long param_1)
{
long lVar1;
char cVar2;
int1 uVar3;
int iVar4;
char *pcVar5;
int8 uVar6;
int local_c0 [2];
long local_b8;
long local_b0;
int local_a8 [2];
long local_a0;
long local_98;
int4 local_90 [2];
long local_88;
long local_80;
int1 local_78 [8];
long local_70;
long local_68;
int local_60 [2];
void *local_58;
long local_50;
int1 local_48 [32];
lVar1 = param_1 + 0x20;
ssz_get(local_78,lVar1,"header");
ssz_get(local_90,lVar1,"blockhash_proof");
ssz_get(local_a8,lVar1,"sync_committee_bits");
ssz_get(local_c0,lVar1,"sync_committee_signature");
pcVar5 = "invalid proof, missing header or blockhash_proof!";
if ((((((local_68 != 0) && (local_70 != 0)) && (local_80 != 0)) &&
(((local_88 != 0 &&
(pcVar5 = "invalid proof, missing sync committee bits or signature!", local_98 != 0)) &&
((local_a0 != 0 && ((local_a8[0] == 0x40 && (local_b0 != 0)))))))) && (local_b8 != 0)) &&
((local_c0[0] == 0x60 &&
(pcVar5 = "invalid data, data is not a bytes32!", *(long *)(param_1 + 0x48) != 0)))) {
cVar2 = ssz_is_type((int *)(param_1 + 0x38),ssz_bytes32);
if ((cVar2 != '\0') &&
((lVar1 = *(long *)(param_1 + 0x40), lVar1 != 0 && (*(int *)(param_1 + 0x38) == 0x20)))) {
ssz_get(local_60,local_78,"bodyRoot");
ssz_verify_single_merkle_proof(local_90[0],local_88,lVar1,0x32c,local_48);
if ((local_50 != 0) &&
(((local_58 != (void *)0x0 && (local_60[0] == 0x20)) &&
(iVar4 = bcmp(local_48,local_58,0x20), iVar4 == 0)))) {
iVar4 = c4_verify_blockroot_signature(param_1,local_78,local_a8,local_c0,0);
if (iVar4 != 0) {
return 0;
}
uVar3 = 1;
uVar6 = 1;
goto LAB_0012a607;
}
pcVar5 = "invalid merkle proof for blockhash!";
}
}
c4_state_add_error(param_1 + 0x70,pcVar5);
uVar3 = 0;
uVar6 = 0;
LAB_0012a607:
*(int1 *)(param_1 + 0x68) = uVar3;
return uVar6;
}
|
|
7,863 |
verify_blockhash_proof
|
corpus-core[P]colibri-stateless/src/chains/eth/verifier/verify_blockhash_proof.c
|
bool verify_blockhash_proof(verify_ctx_t* ctx) {
ssz_ob_t header = ssz_get(&ctx->proof, "header");
ssz_ob_t blockhash_proof = ssz_get(&ctx->proof, "blockhash_proof");
ssz_ob_t sync_committee_bits = ssz_get(&ctx->proof, "sync_committee_bits");
ssz_ob_t sync_committee_signature = ssz_get(&ctx->proof, "sync_committee_signature");
if (ssz_is_error(header) || ssz_is_error(blockhash_proof)) RETURN_VERIFY_ERROR(ctx, "invalid proof, missing header or blockhash_proof!");
if (ssz_is_error(sync_committee_bits) || sync_committee_bits.bytes.len != 64 || ssz_is_error(sync_committee_signature) || sync_committee_signature.bytes.len != 96) RETURN_VERIFY_ERROR(ctx, "invalid proof, missing sync committee bits or signature!");
if (!ctx->data.def || !ssz_is_type(&ctx->data, &ssz_bytes32) || ctx->data.bytes.data == NULL || ctx->data.bytes.len != 32) RETURN_VERIFY_ERROR(ctx, "invalid data, data is not a bytes32!");
if (!verify_beacon_header(&header, ctx->data.bytes.data, blockhash_proof.bytes)) RETURN_VERIFY_ERROR(ctx, "invalid merkle proof for blockhash!");
if (c4_verify_blockroot_signature(ctx, &header, &sync_committee_bits, &sync_committee_signature, 0) != C4_SUCCESS) return false;
ctx->success = true;
return true;
}
|
O3
|
c
|
verify_blockhash_proof:
pushq %r15
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %rdi, %rbx
leaq 0x20(%rdi), %r14
leaq 0x55e82(%rip), %rdx # 0x8166d
leaq 0x48(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x5525d
leaq 0x571b7(%rip), %rdx # 0x829b9
leaq 0x30(%rsp), %rdi
movq %r14, %rsi
callq 0x5525d
leaq 0x56422(%rip), %rdx # 0x81c38
leaq 0x18(%rsp), %rdi
movq %r14, %rsi
callq 0x5525d
leaq 0x56422(%rip), %rdx # 0x81c4c
movq %rsp, %rdi
movq %r14, %rsi
callq 0x5525d
cmpq $0x0, 0x10(%r15)
leaq 0x56af0(%rip), %r14 # 0x82331
je 0x2b927
cmpq $0x0, 0x50(%rsp)
je 0x2b927
cmpq $0x0, 0x40(%rsp)
je 0x2b927
cmpq $0x0, 0x38(%rsp)
je 0x2b927
cmpq $0x0, 0x28(%rsp)
leaq 0x56aeb(%rip), %r14 # 0x82363
je 0x2b927
cmpq $0x0, 0x20(%rsp)
je 0x2b927
cmpl $0x40, 0x18(%rsp)
jne 0x2b927
cmpq $0x0, 0x10(%rsp)
je 0x2b927
cmpq $0x0, 0x8(%rsp)
je 0x2b927
cmpl $0x60, (%rsp)
jne 0x2b927
leaq 0x57113(%rip), %r14 # 0x829c9
cmpq $0x0, 0x48(%rbx)
je 0x2b927
leaq 0x38(%rbx), %r15
leaq 0x95380(%rip), %rsi # 0xc0c48
movq %r15, %rdi
callq 0x5488d
testb %al, %al
je 0x2b927
movq 0x40(%rbx), %rsi
testq %rsi, %rsi
je 0x2b927
cmpl $0x20, (%r15)
jne 0x2b927
movl 0x30(%rsp), %edx
movq 0x38(%rsp), %rcx
leaq 0x48(%rsp), %rdi
callq 0x2b948
testb %al, %al
je 0x2b920
xorl %r14d, %r14d
leaq 0x48(%rsp), %rsi
leaq 0x18(%rsp), %rdx
movq %rsp, %rcx
movq %rbx, %rdi
xorl %r8d, %r8d
callq 0x2b65b
testl %eax, %eax
jne 0x2b93b
movb $0x1, %al
movb $0x1, %r14b
jmp 0x2b938
leaq 0x570c7(%rip), %r14 # 0x829ee
leaq 0x70(%rbx), %rdi
movq %r14, %rsi
callq 0x589cd
xorl %eax, %eax
xorl %r14d, %r14d
movb %al, 0x68(%rbx)
movl %r14d, %eax
addq $0x60, %rsp
popq %rbx
popq %r14
popq %r15
retq
|
verify_blockhash_proof:
push r15
push r14
push rbx
sub rsp, 60h
mov rbx, rdi
lea r14, [rdi+20h]
lea rdx, aInvalidRespons+15h; "header"
lea r15, [rsp+78h+var_30]
mov rdi, r15
mov rsi, r14
call ssz_get
lea rdx, aBlockhashProof; "blockhash_proof"
lea rdi, [rsp+78h+var_48]
mov rsi, r14
call ssz_get
lea rdx, aSyncCommitteeB; "sync_committee_bits"
lea rdi, [rsp+78h+var_60]
mov rsi, r14
call ssz_get
lea rdx, aSyncCommitteeS; "sync_committee_signature"
mov rdi, rsp
mov rsi, r14
call ssz_get
cmp qword ptr [r15+10h], 0
lea r14, aInvalidProofMi; "invalid proof, missing header or blockh"...
jz loc_2B927
cmp [rsp+78h+var_28], 0
jz loc_2B927
cmp [rsp+78h+var_38], 0
jz loc_2B927
cmp [rsp+78h+var_40], 0
jz loc_2B927
cmp [rsp+78h+var_50], 0
lea r14, aInvalidProofMi_0; "invalid proof, missing sync committee b"...
jz loc_2B927
cmp [rsp+78h+var_58], 0
jz loc_2B927
cmp [rsp+78h+var_60], 40h ; '@'
jnz loc_2B927
cmp [rsp+78h+var_68], 0
jz loc_2B927
cmp [rsp+78h+var_70], 0
jz short loc_2B927
cmp [rsp+78h+var_78], 60h ; '`'
jnz short loc_2B927
lea r14, aInvalidDataDat; "invalid data, data is not a bytes32!"
cmp qword ptr [rbx+48h], 0
jz short loc_2B927
lea r15, [rbx+38h]
lea rsi, ssz_bytes32
mov rdi, r15
call ssz_is_type
test al, al
jz short loc_2B927
mov rsi, [rbx+40h]
test rsi, rsi
jz short loc_2B927
cmp dword ptr [r15], 20h ; ' '
jnz short loc_2B927
mov edx, [rsp+78h+var_48]
mov rcx, [rsp+78h+var_40]
lea rdi, [rsp+78h+var_30]
call verify_beacon_header
test al, al
jz short loc_2B920
xor r14d, r14d
lea rsi, [rsp+78h+var_30]
lea rdx, [rsp+78h+var_60]
mov rcx, rsp
mov rdi, rbx
xor r8d, r8d
call c4_verify_blockroot_signature
test eax, eax
jnz short loc_2B93B
mov al, 1
mov r14b, 1
jmp short loc_2B938
loc_2B920:
lea r14, aInvalidMerkleP; "invalid merkle proof for blockhash!"
loc_2B927:
lea rdi, [rbx+70h]
mov rsi, r14
call c4_state_add_error
xor eax, eax
xor r14d, r14d
loc_2B938:
mov [rbx+68h], al
loc_2B93B:
mov eax, r14d
add rsp, 60h
pop rbx
pop r14
pop r15
retn
|
long long verify_blockhash_proof(long long a1)
{
const char *v1; // r14
long long v2; // rsi
unsigned int v3; // r14d
char v4; // al
int v6; // [rsp+0h] [rbp-78h] BYREF
long long v7; // [rsp+8h] [rbp-70h]
long long v8; // [rsp+10h] [rbp-68h]
int v9; // [rsp+18h] [rbp-60h] BYREF
long long v10; // [rsp+20h] [rbp-58h]
long long v11; // [rsp+28h] [rbp-50h]
unsigned int v12; // [rsp+30h] [rbp-48h] BYREF
long long v13; // [rsp+38h] [rbp-40h]
long long v14; // [rsp+40h] [rbp-38h]
_QWORD v15[6]; // [rsp+48h] [rbp-30h] BYREF
ssz_get(v15, a1 + 32, "header");
ssz_get(&v12, a1 + 32, "blockhash_proof");
ssz_get(&v9, a1 + 32, "sync_committee_bits");
ssz_get(&v6, a1 + 32, "sync_committee_signature");
v1 = "invalid proof, missing header or blockhash_proof!";
if ( !v15[2] )
goto LABEL_19;
if ( !v15[1] )
goto LABEL_19;
if ( !v14 )
goto LABEL_19;
if ( !v13 )
goto LABEL_19;
v1 = "invalid proof, missing sync committee bits or signature!";
if ( !v11 )
goto LABEL_19;
if ( !v10 )
goto LABEL_19;
if ( v9 != 64 )
goto LABEL_19;
if ( !v8 )
goto LABEL_19;
if ( !v7 )
goto LABEL_19;
if ( v6 != 96 )
goto LABEL_19;
v1 = "invalid data, data is not a bytes32!";
if ( !*(_QWORD *)(a1 + 72) )
goto LABEL_19;
if ( !(unsigned __int8)ssz_is_type(a1 + 56, &ssz_bytes32) )
goto LABEL_19;
v2 = *(_QWORD *)(a1 + 64);
if ( !v2 || *(_DWORD *)(a1 + 56) != 32 )
goto LABEL_19;
if ( !(unsigned __int8)verify_beacon_header(v15, v2, v12, v13) )
{
v1 = "invalid merkle proof for blockhash!";
LABEL_19:
c4_state_add_error(a1 + 112, v1);
v4 = 0;
v3 = 0;
goto LABEL_20;
}
v3 = 0;
if ( !(unsigned int)c4_verify_blockroot_signature(a1, v15, (long long)&v9, (long long)&v6, 0LL) )
{
v4 = 1;
LOBYTE(v3) = 1;
LABEL_20:
*(_BYTE *)(a1 + 104) = v4;
}
return v3;
}
|
verify_blockhash_proof:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x60
MOV RBX,RDI
LEA R14,[RDI + 0x20]
LEA RDX,[0x18166d]
LEA R15,[RSP + 0x48]
MOV RDI,R15
MOV RSI,R14
CALL 0x0015525d
LEA RDX,[0x1829b9]
LEA RDI,[RSP + 0x30]
MOV RSI,R14
CALL 0x0015525d
LEA RDX,[0x181c38]
LEA RDI,[RSP + 0x18]
MOV RSI,R14
CALL 0x0015525d
LEA RDX,[0x181c4c]
MOV RDI,RSP
MOV RSI,R14
CALL 0x0015525d
CMP qword ptr [R15 + 0x10],0x0
LEA R14,[0x182331]
JZ 0x0012b927
CMP qword ptr [RSP + 0x50],0x0
JZ 0x0012b927
CMP qword ptr [RSP + 0x40],0x0
JZ 0x0012b927
CMP qword ptr [RSP + 0x38],0x0
JZ 0x0012b927
CMP qword ptr [RSP + 0x28],0x0
LEA R14,[0x182363]
JZ 0x0012b927
CMP qword ptr [RSP + 0x20],0x0
JZ 0x0012b927
CMP dword ptr [RSP + 0x18],0x40
JNZ 0x0012b927
CMP qword ptr [RSP + 0x10],0x0
JZ 0x0012b927
CMP qword ptr [RSP + 0x8],0x0
JZ 0x0012b927
CMP dword ptr [RSP],0x60
JNZ 0x0012b927
LEA R14,[0x1829c9]
CMP qword ptr [RBX + 0x48],0x0
JZ 0x0012b927
LEA R15,[RBX + 0x38]
LEA RSI,[0x1c0c48]
MOV RDI,R15
CALL 0x0015488d
TEST AL,AL
JZ 0x0012b927
MOV RSI,qword ptr [RBX + 0x40]
TEST RSI,RSI
JZ 0x0012b927
CMP dword ptr [R15],0x20
JNZ 0x0012b927
MOV EDX,dword ptr [RSP + 0x30]
MOV RCX,qword ptr [RSP + 0x38]
LEA RDI,[RSP + 0x48]
CALL 0x0012b948
TEST AL,AL
JZ 0x0012b920
XOR R14D,R14D
LEA RSI,[RSP + 0x48]
LEA RDX,[RSP + 0x18]
MOV RCX,RSP
MOV RDI,RBX
XOR R8D,R8D
CALL 0x0012b65b
TEST EAX,EAX
JNZ 0x0012b93b
MOV AL,0x1
MOV R14B,0x1
JMP 0x0012b938
LAB_0012b920:
LEA R14,[0x1829ee]
LAB_0012b927:
LEA RDI,[RBX + 0x70]
MOV RSI,R14
CALL 0x001589cd
XOR EAX,EAX
XOR R14D,R14D
LAB_0012b938:
MOV byte ptr [RBX + 0x68],AL
LAB_0012b93b:
MOV EAX,R14D
ADD RSP,0x60
POP RBX
POP R14
POP R15
RET
|
int8 verify_blockhash_proof(long param_1)
{
long lVar1;
char cVar2;
int1 uVar3;
int iVar4;
char *pcVar5;
int8 uVar6;
int local_78 [2];
long local_70;
long local_68;
int local_60 [2];
long local_58;
long local_50;
int4 local_48 [2];
long local_40;
long local_38;
int1 local_30 [8];
long local_28;
long local_20;
lVar1 = param_1 + 0x20;
ssz_get(local_30,lVar1,"header");
ssz_get(local_48,lVar1,"blockhash_proof");
ssz_get(local_60,lVar1,"sync_committee_bits");
ssz_get(local_78,lVar1,"sync_committee_signature");
pcVar5 = "invalid proof, missing header or blockhash_proof!";
if (((((((local_20 != 0) && (local_28 != 0)) && (local_38 != 0)) &&
((local_40 != 0 &&
(pcVar5 = "invalid proof, missing sync committee bits or signature!", local_50 != 0)))) &&
((local_58 != 0 && ((local_60[0] == 0x40 && (local_68 != 0)))))) && (local_70 != 0)) &&
((local_78[0] == 0x60 &&
(pcVar5 = "invalid data, data is not a bytes32!", *(long *)(param_1 + 0x48) != 0)))) {
cVar2 = ssz_is_type((int *)(param_1 + 0x38),ssz_bytes32);
if ((cVar2 != '\0') && ((*(long *)(param_1 + 0x40) != 0 && (*(int *)(param_1 + 0x38) == 0x20))))
{
cVar2 = verify_beacon_header(local_30,*(long *)(param_1 + 0x40),local_48[0],local_40);
if (cVar2 != '\0') {
iVar4 = c4_verify_blockroot_signature(param_1,local_30,local_60,local_78,0);
if (iVar4 != 0) {
return 0;
}
uVar3 = 1;
uVar6 = 1;
goto LAB_0012b938;
}
pcVar5 = "invalid merkle proof for blockhash!";
}
}
c4_state_add_error(param_1 + 0x70,pcVar5);
uVar3 = 0;
uVar6 = 0;
LAB_0012b938:
*(int1 *)(param_1 + 0x68) = uVar3;
return uVar6;
}
|
|
7,864 |
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&)
|
monkey531[P]llama/common/json.hpp
|
static diyfp mul(const diyfp& x, const diyfp& y) noexcept
{
static_assert(kPrecision == 64, "internal error");
// Computes:
// f = round((x.f * y.f) / 2^q)
// e = x.e + y.e + q
// Emulate the 64-bit * 64-bit multiplication:
//
// p = u * v
// = (u_lo + 2^32 u_hi) (v_lo + 2^32 v_hi)
// = (u_lo v_lo ) + 2^32 ((u_lo v_hi ) + (u_hi v_lo )) + 2^64 (u_hi v_hi )
// = (p0 ) + 2^32 ((p1 ) + (p2 )) + 2^64 (p3 )
// = (p0_lo + 2^32 p0_hi) + 2^32 ((p1_lo + 2^32 p1_hi) + (p2_lo + 2^32 p2_hi)) + 2^64 (p3 )
// = (p0_lo ) + 2^32 (p0_hi + p1_lo + p2_lo ) + 2^64 (p1_hi + p2_hi + p3)
// = (p0_lo ) + 2^32 (Q ) + 2^64 (H )
// = (p0_lo ) + 2^32 (Q_lo + 2^32 Q_hi ) + 2^64 (H )
//
// (Since Q might be larger than 2^32 - 1)
//
// = (p0_lo + 2^32 Q_lo) + 2^64 (Q_hi + H)
//
// (Q_hi + H does not overflow a 64-bit int)
//
// = p_lo + 2^64 p_hi
const std::uint64_t u_lo = x.f & 0xFFFFFFFFu;
const std::uint64_t u_hi = x.f >> 32u;
const std::uint64_t v_lo = y.f & 0xFFFFFFFFu;
const std::uint64_t v_hi = y.f >> 32u;
const std::uint64_t p0 = u_lo * v_lo;
const std::uint64_t p1 = u_lo * v_hi;
const std::uint64_t p2 = u_hi * v_lo;
const std::uint64_t p3 = u_hi * v_hi;
const std::uint64_t p0_hi = p0 >> 32u;
const std::uint64_t p1_lo = p1 & 0xFFFFFFFFu;
const std::uint64_t p1_hi = p1 >> 32u;
const std::uint64_t p2_lo = p2 & 0xFFFFFFFFu;
const std::uint64_t p2_hi = p2 >> 32u;
std::uint64_t Q = p0_hi + p1_lo + p2_lo;
// The full product might now be computed as
//
// p_hi = p3 + p2_hi + p1_hi + (Q >> 32)
// p_lo = p0_lo + (Q << 32)
//
// But in this particular case here, the full p_lo is not required.
// Effectively we only need to add the highest bit in p_lo to p_hi (and
// Q_hi + 1 does not overflow).
Q += std::uint64_t{1} << (64u - 32u - 1u); // round, ties up
const std::uint64_t h = p3 + p2_hi + p1_hi + (Q >> 32u);
return {h, x.e + y.e + 64};
}
|
O3
|
cpp
|
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&):
movq (%rdi), %rax
movl %eax, %ecx
shrq $0x20, %rax
movq (%rsi), %r8
movl %r8d, %edx
shrq $0x20, %r8
movq %rdx, %r9
imulq %rcx, %r9
imulq %r8, %rcx
imulq %rax, %rdx
imulq %rax, %r8
shrq $0x20, %r9
movl %ecx, %r10d
addq %r9, %r10
shrq $0x20, %rcx
movl %edx, %eax
addq %r10, %rax
shrq $0x20, %rdx
addq %r8, %rdx
addq %rcx, %rdx
subq $-0x80000000, %rax # imm = 0x80000000
shrq $0x20, %rax
addq %rdx, %rax
movl 0x8(%rdi), %ecx
movl 0x8(%rsi), %edx
addl %ecx, %edx
addl $0x40, %edx
retq
|
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_:
mov rax, [rdi]
mov ecx, eax
shr rax, 20h
mov r8, [rsi]
mov edx, r8d
shr r8, 20h
mov r9, rdx
imul r9, rcx
imul rcx, r8
imul rdx, rax
imul r8, rax
shr r9, 20h
mov r10d, ecx
add r10, r9
shr rcx, 20h
mov eax, edx
add rax, r10
shr rdx, 20h
add rdx, r8
add rdx, rcx
sub rax, 0FFFFFFFF80000000h
shr rax, 20h
add rax, rdx
mov ecx, [rdi+8]
mov edx, [rsi+8]
add edx, ecx
add edx, 40h ; '@'
retn
|
unsigned long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(_QWORD *a1, _QWORD *a2)
{
long long v2; // rcx
v2 = (unsigned int)*a1;
return ((unsigned long long)(HIDWORD(*a2) * v2) >> 32)
+ HIDWORD(*a1) * HIDWORD(*a2)
+ ((HIDWORD(*a1) * (unsigned long long)(unsigned int)*a2) >> 32)
+ ((((v2 * (unsigned long long)(unsigned int)*a2) >> 32)
+ (unsigned int)(HIDWORD(*a2) * v2)
+ (unsigned int)(HIDWORD(*a1) * *a2)
+ 0x80000000) >> 32);
}
|
mul:
MOV RAX,qword ptr [RDI]
MOV ECX,EAX
SHR RAX,0x20
MOV R8,qword ptr [RSI]
MOV EDX,R8D
SHR R8,0x20
MOV R9,RDX
IMUL R9,RCX
IMUL RCX,R8
IMUL RDX,RAX
IMUL R8,RAX
SHR R9,0x20
MOV R10D,ECX
ADD R10,R9
SHR RCX,0x20
MOV EAX,EDX
ADD RAX,R10
SHR RDX,0x20
ADD RDX,R8
ADD RDX,RCX
SUB RAX,-0x80000000
SHR RAX,0x20
ADD RAX,RDX
MOV ECX,dword ptr [RDI + 0x8]
MOV EDX,dword ptr [RSI + 0x8]
ADD EDX,ECX
ADD EDX,0x40
RET
|
/* 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&) */
int1 [16]
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(diyfp *param_1,diyfp *param_2)
{
ulong uVar1;
ulong uVar2;
ulong uVar3;
ulong uVar4;
ulong uVar5;
ulong uVar6;
int1 auVar7 [16];
uVar2 = *(ulong *)param_1 & 0xffffffff;
uVar1 = *(ulong *)param_1 >> 0x20;
uVar4 = *(ulong *)param_2 & 0xffffffff;
uVar6 = *(ulong *)param_2 >> 0x20;
uVar3 = uVar2 * uVar6;
uVar5 = uVar4 * uVar1;
auVar7._0_8_ = ((uVar5 & 0xffffffff) + (uVar3 & 0xffffffff) + (uVar4 * uVar2 >> 0x20) + 0x80000000
>> 0x20) + (uVar5 >> 0x20) + uVar6 * uVar1 + (uVar3 >> 0x20);
auVar7._8_4_ = *(int *)(param_2 + 8) + *(int *)(param_1 + 8) + 0x40;
auVar7._12_4_ = 0;
return auVar7;
}
|
|
7,865 |
mi_store_blob_length
|
eloqsql/storage/myisam/mi_dynrec.c
|
void _mi_store_blob_length(uchar *pos,uint pack_length,uint length)
{
switch (pack_length) {
case 1:
*pos= (uchar) length;
break;
case 2:
int2store(pos,length);
break;
case 3:
int3store(pos,length);
break;
case 4:
int4store(pos,length);
default:
break;
}
return;
}
|
O0
|
c
|
mi_store_blob_length:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl -0xc(%rbp), %eax
decl %eax
movl %eax, %ecx
movq %rcx, -0x28(%rbp)
subl $0x3, %eax
ja 0xaadda
movq -0x28(%rbp), %rax
leaq 0xad393(%rip), %rcx # 0x1580fc
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl -0x10(%rbp), %eax
movb %al, %cl
movq -0x8(%rbp), %rax
movb %cl, (%rax)
jmp 0xaaddc
jmp 0xaad81
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movl -0x10(%rbp), %eax
movw %ax, %cx
movq -0x18(%rbp), %rax
movw %cx, (%rax)
jmp 0xaaddc
jmp 0xaad9a
movl -0x10(%rbp), %eax
movb %al, %cl
movq -0x8(%rbp), %rax
movb %cl, (%rax)
movl -0x10(%rbp), %eax
shrl $0x8, %eax
movb %al, %cl
movq -0x8(%rbp), %rax
movb %cl, 0x1(%rax)
movl -0x10(%rbp), %eax
shrl $0x10, %eax
movb %al, %cl
movq -0x8(%rbp), %rax
movb %cl, 0x2(%rax)
jmp 0xaaddc
jmp 0xaadc7
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
movl -0x10(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
jmp 0xaadda
jmp 0xaaddc
popq %rbp
retq
nop
|
_mi_store_blob_length:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_10], edx
mov eax, [rbp+var_C]
dec eax; switch 4 cases
mov ecx, eax
mov [rbp+var_28], rcx
sub eax, 3
ja short def_AAD70; jumptable 00000000000AAD70 default case
mov rax, [rbp+var_28]
lea rcx, jpt_AAD70
movsxd rax, ds:(jpt_AAD70 - 1580FCh)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_AAD72:
mov eax, [rbp+var_10]; jumptable 00000000000AAD70 case 1
mov cl, al
mov rax, [rbp+var_8]
mov [rax], cl
jmp short loc_AADDC
loc_AAD7F:
jmp short $+2; jumptable 00000000000AAD70 case 2
loc_AAD81:
mov rax, [rbp+var_8]
mov [rbp+var_18], rax
mov eax, [rbp+var_10]
mov cx, ax
mov rax, [rbp+var_18]
mov [rax], cx
jmp short loc_AADDC
loc_AAD98:
jmp short $+2; jumptable 00000000000AAD70 case 3
loc_AAD9A:
mov eax, [rbp+var_10]
mov cl, al
mov rax, [rbp+var_8]
mov [rax], cl
mov eax, [rbp+var_10]
shr eax, 8
mov cl, al
mov rax, [rbp+var_8]
mov [rax+1], cl
mov eax, [rbp+var_10]
shr eax, 10h
mov cl, al
mov rax, [rbp+var_8]
mov [rax+2], cl
jmp short loc_AADDC
loc_AADC5:
jmp short $+2; jumptable 00000000000AAD70 case 4
loc_AADC7:
mov rax, [rbp+var_8]
mov [rbp+var_20], rax
mov ecx, [rbp+var_10]
mov rax, [rbp+var_20]
mov [rax], ecx
jmp short $+2; jumptable 00000000000AAD70 default case
def_AAD70:
jmp short $+2; jumptable 00000000000AAD70 default case
loc_AADDC:
pop rbp
retn
|
unsigned long long mi_store_blob_length(_BYTE *a1, int a2, int a3)
{
unsigned long long result; // rax
result = (unsigned int)(a2 - 1);
switch ( a2 )
{
case 1:
result = (unsigned long long)a1;
*a1 = a3;
break;
case 2:
result = (unsigned long long)a1;
*(_WORD *)a1 = a3;
break;
case 3:
*(_WORD *)a1 = a3;
result = (unsigned long long)a1;
a1[2] = BYTE2(a3);
break;
case 4:
result = (unsigned long long)a1;
*(_DWORD *)a1 = a3;
break;
default:
return result;
}
return result;
}
|
_mi_store_blob_length:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV dword ptr [RBP + -0x10],EDX
MOV EAX,dword ptr [RBP + -0xc]
DEC EAX
MOV ECX,EAX
MOV qword ptr [RBP + -0x28],RCX
SUB EAX,0x3
JA 0x001aadda
MOV RAX,qword ptr [RBP + -0x28]
LEA RCX,[0x2580fc]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_1:
MOV EAX,dword ptr [RBP + -0x10]
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX],CL
JMP 0x001aaddc
caseD_2:
JMP 0x001aad81
LAB_001aad81:
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x18],RAX
MOV EAX,dword ptr [RBP + -0x10]
MOV CX,AX
MOV RAX,qword ptr [RBP + -0x18]
MOV word ptr [RAX],CX
JMP 0x001aaddc
caseD_3:
JMP 0x001aad9a
LAB_001aad9a:
MOV EAX,dword ptr [RBP + -0x10]
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX],CL
MOV EAX,dword ptr [RBP + -0x10]
SHR EAX,0x8
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x1],CL
MOV EAX,dword ptr [RBP + -0x10]
SHR EAX,0x10
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x2],CL
JMP 0x001aaddc
caseD_4:
JMP 0x001aadc7
LAB_001aadc7:
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x20],RAX
MOV ECX,dword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX],ECX
JMP 0x001aadda
LAB_001aadda:
JMP 0x001aaddc
default:
POP RBP
RET
|
void _mi_store_blob_length(int4 *param_1,int4 param_2,int4 param_3)
{
switch(param_2) {
case 1:
*(char *)param_1 = (char)param_3;
break;
case 2:
*(short *)param_1 = (short)param_3;
break;
case 3:
*(char *)param_1 = (char)param_3;
*(char *)((long)param_1 + 1) = (char)((uint)param_3 >> 8);
*(char *)((long)param_1 + 2) = (char)((uint)param_3 >> 0x10);
break;
case 4:
*param_1 = param_3;
}
return;
}
|
|
7,866 |
mi_end_bulk_insert
|
eloqsql/storage/myisam/mi_write.c
|
int mi_end_bulk_insert(MI_INFO *info, my_bool abort)
{
int first_error= 0;
if (info->bulk_insert)
{
uint i;
for (i=0 ; i < info->s->base.keys ; i++)
{
if (is_tree_inited(& info->bulk_insert[i]))
{
int error;
if ((error= delete_tree(& info->bulk_insert[i], abort)))
{
first_error= first_error ? first_error : error;
abort= 1;
}
}
}
my_free(info->bulk_insert);
info->bulk_insert=0;
}
return first_error;
}
|
O3
|
c
|
mi_end_bulk_insert:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x80(%rdi), %rdi
testq %rdi, %rdi
je 0x8ad11
movq (%rbx), %rax
cmpl $0x0, 0x180(%rax)
je 0x8ad16
xorl %r12d, %r12d
xorl %r13d, %r13d
xorl %r14d, %r14d
movq 0x80(%rbx), %rdi
cmpq $0x0, (%rdi,%r12)
je 0x8acf3
addq %r12, %rdi
movsbl %sil, %r15d
movl %r15d, %esi
callq 0xa5b9e
testl %r14d, %r14d
movl %r14d, %ecx
cmovel %eax, %ecx
testl %eax, %eax
cmovnel %ecx, %r14d
movzbl %r15b, %esi
movl $0x1, %eax
cmovnel %eax, %esi
movq (%rbx), %rax
incq %r13
movl 0x180(%rax), %ecx
addq $0x298, %r12 # imm = 0x298
cmpq %rcx, %r13
jb 0x8acb8
movq 0x80(%rbx), %rdi
jmp 0x8ad19
xorl %r14d, %r14d
jmp 0x8ad29
xorl %r14d, %r14d
callq 0xa1412
movq $0x0, 0x80(%rbx)
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
|
mi_end_bulk_insert:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rdi
mov rdi, [rdi+80h]
test rdi, rdi
jz short loc_8AD11
mov rax, [rbx]
cmp dword ptr [rax+180h], 0
jz short loc_8AD16
xor r12d, r12d
xor r13d, r13d
xor r14d, r14d
loc_8ACB8:
mov rdi, [rbx+80h]
cmp qword ptr [rdi+r12], 0
jz short loc_8ACF3
add rdi, r12
movsx r15d, sil
mov esi, r15d
call delete_tree
test r14d, r14d
mov ecx, r14d
cmovz ecx, eax
test eax, eax
cmovnz r14d, ecx
movzx esi, r15b
mov eax, 1
cmovnz esi, eax
mov rax, [rbx]
loc_8ACF3:
inc r13
mov ecx, [rax+180h]
add r12, 298h
cmp r13, rcx
jb short loc_8ACB8
mov rdi, [rbx+80h]
jmp short loc_8AD19
loc_8AD11:
xor r14d, r14d
jmp short loc_8AD29
loc_8AD16:
xor r14d, r14d
loc_8AD19:
call my_free
mov qword ptr [rbx+80h], 0
loc_8AD29:
mov eax, r14d
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long mi_end_bulk_insert(_QWORD *a1, char a2)
{
long long v3; // rdi
long long v4; // rax
long long v5; // r12
unsigned long long v6; // r13
unsigned int v7; // r14d
long long v8; // rdi
int v9; // eax
int v10; // ecx
v3 = a1[16];
if ( v3 )
{
v4 = *a1;
if ( *(_DWORD *)(*a1 + 384LL) )
{
v5 = 0LL;
v6 = 0LL;
v7 = 0;
do
{
v8 = a1[16];
if ( *(_QWORD *)(v8 + v5) )
{
v9 = delete_tree(v5 + v8, (unsigned int)a2);
v10 = v7;
if ( !v7 )
v10 = v9;
if ( v9 )
{
v7 = v10;
a2 = 1;
}
v4 = *a1;
}
++v6;
v5 += 664LL;
}
while ( v6 < *(unsigned int *)(v4 + 384) );
v3 = a1[16];
}
else
{
v7 = 0;
}
my_free(v3);
a1[16] = 0LL;
}
else
{
return 0;
}
return v7;
}
|
mi_end_bulk_insert:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV RDI,qword ptr [RDI + 0x80]
TEST RDI,RDI
JZ 0x0018ad11
MOV RAX,qword ptr [RBX]
CMP dword ptr [RAX + 0x180],0x0
JZ 0x0018ad16
XOR R12D,R12D
XOR R13D,R13D
XOR R14D,R14D
LAB_0018acb8:
MOV RDI,qword ptr [RBX + 0x80]
CMP qword ptr [RDI + R12*0x1],0x0
JZ 0x0018acf3
ADD RDI,R12
MOVSX R15D,SIL
MOV ESI,R15D
CALL 0x001a5b9e
TEST R14D,R14D
MOV ECX,R14D
CMOVZ ECX,EAX
TEST EAX,EAX
CMOVNZ R14D,ECX
MOVZX ESI,R15B
MOV EAX,0x1
CMOVNZ ESI,EAX
MOV RAX,qword ptr [RBX]
LAB_0018acf3:
INC R13
MOV ECX,dword ptr [RAX + 0x180]
ADD R12,0x298
CMP R13,RCX
JC 0x0018acb8
MOV RDI,qword ptr [RBX + 0x80]
JMP 0x0018ad19
LAB_0018ad11:
XOR R14D,R14D
JMP 0x0018ad29
LAB_0018ad16:
XOR R14D,R14D
LAB_0018ad19:
CALL 0x001a1412
MOV qword ptr [RBX + 0x80],0x0
LAB_0018ad29:
MOV EAX,R14D
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int mi_end_bulk_insert(long *param_1,char param_2)
{
int iVar1;
long lVar2;
int iVar3;
long lVar4;
ulong uVar5;
int iVar6;
lVar4 = param_1[0x10];
if (lVar4 == 0) {
iVar6 = 0;
}
else {
lVar2 = *param_1;
if (*(int *)(lVar2 + 0x180) == 0) {
iVar6 = 0;
}
else {
lVar4 = 0;
uVar5 = 0;
iVar6 = 0;
do {
if (*(long *)(param_1[0x10] + lVar4) != 0) {
iVar1 = delete_tree(param_1[0x10] + lVar4,(int)param_2);
iVar3 = iVar6;
if (iVar6 == 0) {
iVar3 = iVar1;
}
if (iVar1 != 0) {
iVar6 = iVar3;
}
if (iVar1 != 0) {
param_2 = '\x01';
}
lVar2 = *param_1;
}
uVar5 = uVar5 + 1;
lVar4 = lVar4 + 0x298;
} while (uVar5 < *(uint *)(lVar2 + 0x180));
lVar4 = param_1[0x10];
}
my_free(lVar4);
param_1[0x10] = 0;
}
return iVar6;
}
|
|
7,867 |
fn_format
|
eloqsql/mysys/mf_format.c
|
char * fn_format(char * to, const char *name, const char *dir,
const char *extension, uint flag)
{
char dev[FN_REFLEN], buff[FN_REFLEN], *pos, *startpos;
const char *ext;
reg1 size_t length;
size_t dev_length;
DBUG_ENTER("fn_format");
DBUG_ASSERT(name != NULL);
DBUG_ASSERT(extension != NULL);
DBUG_PRINT("enter",("name: %s dir: %s extension: %s flag: %d",
name,dir,extension,flag));
/* Copy and skip directory */
name+=(length=dirname_part(dev, (startpos=(char *) name), &dev_length));
if (length == 0 || (flag & MY_REPLACE_DIR))
{
/* Use given directory */
convert_dirname(dev,dir,NullS); /* Fix to this OS */
}
else if ((flag & MY_RELATIVE_PATH) && !test_if_hard_path(dev))
{
/* Put 'dir' before the given path */
strmake_buf(buff, dev);
pos=convert_dirname(dev,dir,NullS);
strmake(pos,buff,sizeof(buff)-1- (int) (pos-dev));
}
if (flag & MY_PACK_FILENAME)
pack_dirname(dev,dev); /* Put in ./.. and ~/.. */
if (flag & MY_UNPACK_FILENAME)
(void) unpack_dirname(dev,dev); /* Replace ~/.. with dir */
if (!(flag & MY_APPEND_EXT) &&
(pos= (char*) strchr(name,FN_EXTCHAR)) != NullS)
{
if ((flag & MY_REPLACE_EXT) == 0) /* If we should keep old ext */
{
length=strlength(name); /* Use old extension */
ext = "";
}
else
{
length= (size_t) (pos-(char*) name); /* Change extension */
ext= extension;
}
}
else
{
length=strlength(name); /* No ext, use the now one */
ext=extension;
}
if (strlen(dev)+length+strlen(ext) >= FN_REFLEN || length >= FN_LEN )
{
/* To long path, return original or NULL */
size_t tmp_length;
if (flag & MY_SAFE_PATH)
DBUG_RETURN(NullS);
tmp_length= strlength(startpos);
DBUG_PRINT("error",("dev: '%s' ext: '%s' length: %u",dev,ext,
(uint) length));
(void) strmake(to,startpos,MY_MIN(tmp_length,FN_REFLEN-1));
}
else
{
if (to == startpos)
{
bmove(buff,(uchar*) name,length); /* Save name for last copy */
name=buff;
}
pos=strmake(strmov(to,dev),name,length);
(void) strmov(pos,ext); /* Don't convert extension */
}
if (flag & MY_RETURN_REAL_PATH)
(void) my_realpath(to, to, MYF(0));
else if (flag & MY_RESOLVE_SYMLINKS)
{
strmov(buff,to);
(void) my_readlink(to, buff, MYF(0));
}
DBUG_RETURN(to);
}
|
O0
|
c
|
fn_format:
pushq %rbp
movq %rsp, %rbp
subq $0x6a0, %rsp # imm = 0x6A0
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x620(%rbp)
movq %rsi, -0x628(%rbp)
movq %rdx, -0x630(%rbp)
movq %rcx, -0x638(%rbp)
movl %r8d, -0x63c(%rbp)
jmp 0xdf53d
jmp 0xdf53f
jmp 0xdf541
jmp 0xdf543
jmp 0xdf545
leaq -0x210(%rbp), %rdi
movq -0x628(%rbp), %rsi
movq %rsi, -0x650(%rbp)
leaq -0x668(%rbp), %rdx
callq 0xdf3e0
movq %rax, -0x660(%rbp)
addq -0x628(%rbp), %rax
movq %rax, -0x628(%rbp)
cmpq $0x0, -0x660(%rbp)
je 0xdf593
movl -0x63c(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0xdf5af
leaq -0x210(%rbp), %rdi
movq -0x630(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0xdf440
jmp 0xdf65f
movl -0x63c(%rbp), %eax
andl $0x80, %eax
cmpl $0x0, %eax
je 0xdf65d
leaq -0x210(%rbp), %rdi
callq 0xf03a0
cmpl $0x0, %eax
jne 0xdf65d
leaq -0x610(%rbp), %rdi
xorl %esi, %esi
movl $0x200, %edx # imm = 0x200
callq 0x2a2a0
movb $0x2, -0x610(%rbp)
leaq -0x410(%rbp), %rdi
leaq -0x210(%rbp), %rsi
movl $0x1ff, %edx # imm = 0x1FF
callq 0x14dd80
movq %rax, -0x670(%rbp)
leaq -0x210(%rbp), %rdi
movq -0x630(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0xdf440
movq %rax, -0x648(%rbp)
movq -0x648(%rbp), %rdi
leaq -0x410(%rbp), %rsi
movq -0x648(%rbp), %rax
leaq -0x210(%rbp), %rcx
subq %rcx, %rax
cltq
movl $0x1ff, %edx # imm = 0x1FF
subq %rax, %rdx
callq 0x14dd80
jmp 0xdf65f
movl -0x63c(%rbp), %eax
andl $0x8, %eax
cmpl $0x0, %eax
je 0xdf680
leaq -0x210(%rbp), %rdi
leaq -0x210(%rbp), %rsi
callq 0xe8660
movl -0x63c(%rbp), %eax
andl $0x4, %eax
cmpl $0x0, %eax
je 0xdf6a1
leaq -0x210(%rbp), %rdi
leaq -0x210(%rbp), %rsi
callq 0xe90e0
movl -0x63c(%rbp), %eax
andl $0x100, %eax # imm = 0x100
cmpl $0x0, %eax
jne 0xdf728
movq -0x628(%rbp), %rdi
movl $0x2e, %esi
callq 0x2a400
movq %rax, -0x648(%rbp)
cmpq $0x0, %rax
je 0xdf728
movl -0x63c(%rbp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
jne 0xdf700
movq -0x628(%rbp), %rdi
callq 0xdf950
movq %rax, -0x660(%rbp)
leaq 0x783a8(%rip), %rax # 0x157a9f
movq %rax, -0x658(%rbp)
jmp 0xdf726
movq -0x648(%rbp), %rax
movq -0x628(%rbp), %rcx
subq %rcx, %rax
movq %rax, -0x660(%rbp)
movq -0x638(%rbp), %rax
movq %rax, -0x658(%rbp)
jmp 0xdf749
movq -0x628(%rbp), %rdi
callq 0xdf950
movq %rax, -0x660(%rbp)
movq -0x638(%rbp), %rax
movq %rax, -0x658(%rbp)
leaq -0x210(%rbp), %rdi
callq 0x2a340
addq -0x660(%rbp), %rax
movq %rax, -0x680(%rbp)
movq -0x658(%rbp), %rdi
callq 0x2a340
movq %rax, %rcx
movq -0x680(%rbp), %rax
addq %rcx, %rax
cmpq $0x200, %rax # imm = 0x200
jae 0xdf795
cmpq $0x100, -0x660(%rbp) # imm = 0x100
jb 0xdf82d
movl -0x63c(%rbp), %eax
andl $0x40, %eax
cmpl $0x0, %eax
je 0xdf7b5
jmp 0xdf7a5
movq $0x0, -0x618(%rbp)
jmp 0xdf919
movq -0x650(%rbp), %rdi
callq 0xdf950
movq %rax, -0x678(%rbp)
jmp 0xdf7ca
movq -0x620(%rbp), %rax
movq %rax, -0x690(%rbp)
movq -0x650(%rbp), %rax
movq %rax, -0x688(%rbp)
cmpq $0x1ff, -0x678(%rbp) # imm = 0x1FF
jae 0xdf803
movq -0x678(%rbp), %rax
movq %rax, -0x698(%rbp)
jmp 0xdf811
movl $0x1ff, %eax # imm = 0x1FF
movq %rax, -0x698(%rbp)
jmp 0xdf811
movq -0x688(%rbp), %rsi
movq -0x690(%rbp), %rdi
movq -0x698(%rbp), %rdx
callq 0x14dd80
jmp 0xdf8a8
movq -0x620(%rbp), %rax
cmpq -0x650(%rbp), %rax
jne 0xdf865
leaq -0x410(%rbp), %rdi
movq -0x628(%rbp), %rsi
movq -0x660(%rbp), %rdx
callq 0x2a120
leaq -0x410(%rbp), %rax
movq %rax, -0x628(%rbp)
movq -0x620(%rbp), %rdi
leaq -0x210(%rbp), %rsi
callq 0x2a710
movq %rax, %rdi
movq -0x628(%rbp), %rsi
movq -0x660(%rbp), %rdx
callq 0x14dd80
movq %rax, -0x648(%rbp)
movq -0x648(%rbp), %rdi
movq -0x658(%rbp), %rsi
callq 0x2a710
movl -0x63c(%rbp), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0xdf8cf
movq -0x620(%rbp), %rdi
movq -0x620(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0xf5040
jmp 0xdf909
movl -0x63c(%rbp), %eax
andl $0x10, %eax
cmpl $0x0, %eax
je 0xdf907
leaq -0x410(%rbp), %rdi
movq -0x620(%rbp), %rsi
callq 0x2a710
movq -0x620(%rbp), %rdi
leaq -0x410(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0xf4e40
jmp 0xdf909
jmp 0xdf90b
movq -0x620(%rbp), %rax
movq %rax, -0x618(%rbp)
movq -0x618(%rbp), %rax
movq %rax, -0x6a0(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0xdf949
movq -0x6a0(%rbp), %rax
addq $0x6a0, %rsp # imm = 0x6A0
popq %rbp
retq
callq 0x2a250
nop
|
fn_format:
push rbp
mov rbp, rsp
sub rsp, 6A0h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_620], rdi
mov [rbp+var_628], rsi
mov [rbp+var_630], rdx
mov [rbp+var_638], rcx
mov [rbp+var_63C], r8d
jmp short $+2
loc_DF53D:
jmp short $+2
loc_DF53F:
jmp short $+2
loc_DF541:
jmp short $+2
loc_DF543:
jmp short $+2
loc_DF545:
lea rdi, [rbp+var_210]
mov rsi, [rbp+var_628]
mov [rbp+var_650], rsi
lea rdx, [rbp+var_668]
call dirname_part
mov [rbp+var_660], rax
add rax, [rbp+var_628]
mov [rbp+var_628], rax
cmp [rbp+var_660], 0
jz short loc_DF593
mov eax, [rbp+var_63C]
and eax, 1
cmp eax, 0
jz short loc_DF5AF
loc_DF593:
lea rdi, [rbp+var_210]
mov rsi, [rbp+var_630]
xor eax, eax
mov edx, eax
call convert_dirname
jmp loc_DF65F
loc_DF5AF:
mov eax, [rbp+var_63C]
and eax, 80h
cmp eax, 0
jz loc_DF65D
lea rdi, [rbp+var_210]
call test_if_hard_path
cmp eax, 0
jnz loc_DF65D
lea rdi, [rbp+var_610]
xor esi, esi
mov edx, 200h
call _memset
mov [rbp+var_610], 2
lea rdi, [rbp+var_410]
lea rsi, [rbp+var_210]
mov edx, 1FFh
call strmake
mov [rbp+var_670], rax
lea rdi, [rbp+var_210]
mov rsi, [rbp+var_630]
xor eax, eax
mov edx, eax
call convert_dirname
mov [rbp+var_648], rax
mov rdi, [rbp+var_648]
lea rsi, [rbp+var_410]
mov rax, [rbp+var_648]
lea rcx, [rbp+var_210]
sub rax, rcx
cdqe
mov edx, 1FFh
sub rdx, rax
call strmake
loc_DF65D:
jmp short $+2
loc_DF65F:
mov eax, [rbp+var_63C]
and eax, 8
cmp eax, 0
jz short loc_DF680
lea rdi, [rbp+var_210]
lea rsi, [rbp+var_210]
call pack_dirname
loc_DF680:
mov eax, [rbp+var_63C]
and eax, 4
cmp eax, 0
jz short loc_DF6A1
lea rdi, [rbp+var_210]
lea rsi, [rbp+var_210]
call unpack_dirname
loc_DF6A1:
mov eax, [rbp+var_63C]
and eax, 100h
cmp eax, 0
jnz short loc_DF728
mov rdi, [rbp+var_628]
mov esi, 2Eh ; '.'
call _strchr
mov [rbp+var_648], rax
cmp rax, 0
jz short loc_DF728
mov eax, [rbp+var_63C]
and eax, 2
cmp eax, 0
jnz short loc_DF700
mov rdi, [rbp+var_628]
call strlength
mov [rbp+var_660], rax
lea rax, asc_157A9B+4; ""
mov [rbp+var_658], rax
jmp short loc_DF726
loc_DF700:
mov rax, [rbp+var_648]
mov rcx, [rbp+var_628]
sub rax, rcx
mov [rbp+var_660], rax
mov rax, [rbp+var_638]
mov [rbp+var_658], rax
loc_DF726:
jmp short loc_DF749
loc_DF728:
mov rdi, [rbp+var_628]
call strlength
mov [rbp+var_660], rax
mov rax, [rbp+var_638]
mov [rbp+var_658], rax
loc_DF749:
lea rdi, [rbp+var_210]
call _strlen
add rax, [rbp+var_660]
mov [rbp+var_680], rax
mov rdi, [rbp+var_658]
call _strlen
mov rcx, rax
mov rax, [rbp+var_680]
add rax, rcx
cmp rax, 200h
jnb short loc_DF795
cmp [rbp+var_660], 100h
jb loc_DF82D
loc_DF795:
mov eax, [rbp+var_63C]
and eax, 40h
cmp eax, 0
jz short loc_DF7B5
jmp short $+2
loc_DF7A5:
mov [rbp+var_618], 0
jmp loc_DF919
loc_DF7B5:
mov rdi, [rbp+var_650]
call strlength
mov [rbp+var_678], rax
jmp short $+2
loc_DF7CA:
mov rax, [rbp+var_620]
mov [rbp+var_690], rax
mov rax, [rbp+var_650]
mov [rbp+var_688], rax
cmp [rbp+var_678], 1FFh
jnb short loc_DF803
mov rax, [rbp+var_678]
mov [rbp+var_698], rax
jmp short loc_DF811
loc_DF803:
mov eax, 1FFh
mov [rbp+var_698], rax
jmp short $+2
loc_DF811:
mov rsi, [rbp+var_688]
mov rdi, [rbp+var_690]
mov rdx, [rbp+var_698]
call strmake
jmp short loc_DF8A8
loc_DF82D:
mov rax, [rbp+var_620]
cmp rax, [rbp+var_650]
jnz short loc_DF865
lea rdi, [rbp+var_410]
mov rsi, [rbp+var_628]
mov rdx, [rbp+var_660]
call _memmove
lea rax, [rbp+var_410]
mov [rbp+var_628], rax
loc_DF865:
mov rdi, [rbp+var_620]
lea rsi, [rbp+var_210]
call _stpcpy
mov rdi, rax
mov rsi, [rbp+var_628]
mov rdx, [rbp+var_660]
call strmake
mov [rbp+var_648], rax
mov rdi, [rbp+var_648]
mov rsi, [rbp+var_658]
call _stpcpy
loc_DF8A8:
mov eax, [rbp+var_63C]
and eax, 20h
cmp eax, 0
jz short loc_DF8CF
mov rdi, [rbp+var_620]
mov rsi, [rbp+var_620]
xor eax, eax
mov edx, eax
call my_realpath
jmp short loc_DF909
loc_DF8CF:
mov eax, [rbp+var_63C]
and eax, 10h
cmp eax, 0
jz short loc_DF907
lea rdi, [rbp+var_410]
mov rsi, [rbp+var_620]
call _stpcpy
mov rdi, [rbp+var_620]
lea rsi, [rbp+var_410]
xor eax, eax
mov edx, eax
call my_readlink
loc_DF907:
jmp short $+2
loc_DF909:
jmp short $+2
loc_DF90B:
mov rax, [rbp+var_620]
mov [rbp+var_618], rax
loc_DF919:
mov rax, [rbp+var_618]
mov [rbp+var_6A0], rax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_DF949
mov rax, [rbp+var_6A0]
add rsp, 6A0h
pop rbp
retn
loc_DF949:
call ___stack_chk_fail
|
_BYTE * fn_format(_BYTE *a1, _BYTE *a2, long long a3, char *a4, int a5)
{
long long v5; // rax
long long v6; // rax
unsigned long long v8; // [rsp+20h] [rbp-680h]
unsigned long long v9; // [rsp+28h] [rbp-678h]
long long v10; // [rsp+38h] [rbp-668h] BYREF
unsigned long long v11; // [rsp+40h] [rbp-660h]
char *v12; // [rsp+48h] [rbp-658h]
_BYTE *v13; // [rsp+50h] [rbp-650h]
_BYTE *v14; // [rsp+58h] [rbp-648h]
int v15; // [rsp+64h] [rbp-63Ch]
char *v16; // [rsp+68h] [rbp-638h]
long long v17; // [rsp+70h] [rbp-630h]
_BYTE *v18; // [rsp+78h] [rbp-628h]
_BYTE *v19; // [rsp+80h] [rbp-620h]
char v21[512]; // [rsp+90h] [rbp-610h] BYREF
_BYTE v22[512]; // [rsp+290h] [rbp-410h] BYREF
_BYTE v23[520]; // [rsp+490h] [rbp-210h] BYREF
unsigned long long v24; // [rsp+698h] [rbp-8h]
v24 = __readfsqword(0x28u);
v19 = a1;
v18 = a2;
v17 = a3;
v16 = a4;
v15 = a5;
v13 = a2;
v11 = dirname_part((long long)v23, a2, &v10);
v18 += v11;
if ( v11 && (v15 & 1) == 0 )
{
if ( (v15 & 0x80) != 0 && !(unsigned int)test_if_hard_path(v23) )
{
memset(v21, 0LL, sizeof(v21));
v21[0] = 2;
strmake(v22, v23, 511LL);
v14 = convert_dirname(v23, v17, 0LL);
strmake(v14, v22, 511LL - (int)((_DWORD)v14 - (unsigned int)v23));
}
}
else
{
convert_dirname(v23, v17, 0LL);
}
if ( (v15 & 8) != 0 )
pack_dirname(v23, v23);
if ( (v15 & 4) != 0 )
unpack_dirname(v23, v23);
if ( (v15 & 0x100) != 0 || (v14 = (_BYTE *)strchr(v18, 46LL)) == 0LL )
{
v11 = strlength(v18);
v12 = v16;
}
else if ( (v15 & 2) != 0 )
{
v11 = v14 - v18;
v12 = v16;
}
else
{
v11 = strlength(v18);
v12 = "";
}
v5 = strlen(v23);
v8 = v11 + v5;
if ( strlen(v12) + v8 < 0x200 && v11 < 0x100 )
{
if ( v19 == v13 )
{
memmove(v22, v18, v11);
v18 = v22;
}
v6 = stpcpy(v19, v23);
v14 = (_BYTE *)strmake(v6, v18, v11);
stpcpy(v14, v12);
}
else
{
if ( (v15 & 0x40) != 0 )
return 0LL;
v9 = strlength(v13);
if ( v9 >= 0x1FF )
strmake(v19, v13, 511LL);
else
strmake(v19, v13, v9);
}
if ( (v15 & 0x20) != 0 )
{
my_realpath(v19, v19, 0LL);
}
else if ( (v15 & 0x10) != 0 )
{
stpcpy(v22, v19);
my_readlink(v19, v22, 0LL);
}
return v19;
}
|
fn_format:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x6a0
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x620],RDI
MOV qword ptr [RBP + -0x628],RSI
MOV qword ptr [RBP + -0x630],RDX
MOV qword ptr [RBP + -0x638],RCX
MOV dword ptr [RBP + -0x63c],R8D
JMP 0x001df53d
LAB_001df53d:
JMP 0x001df53f
LAB_001df53f:
JMP 0x001df541
LAB_001df541:
JMP 0x001df543
LAB_001df543:
JMP 0x001df545
LAB_001df545:
LEA RDI,[RBP + -0x210]
MOV RSI,qword ptr [RBP + -0x628]
MOV qword ptr [RBP + -0x650],RSI
LEA RDX,[RBP + -0x668]
CALL 0x001df3e0
MOV qword ptr [RBP + -0x660],RAX
ADD RAX,qword ptr [RBP + -0x628]
MOV qword ptr [RBP + -0x628],RAX
CMP qword ptr [RBP + -0x660],0x0
JZ 0x001df593
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x1
CMP EAX,0x0
JZ 0x001df5af
LAB_001df593:
LEA RDI,[RBP + -0x210]
MOV RSI,qword ptr [RBP + -0x630]
XOR EAX,EAX
MOV EDX,EAX
CALL 0x001df440
JMP 0x001df65f
LAB_001df5af:
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x80
CMP EAX,0x0
JZ 0x001df65d
LEA RDI,[RBP + -0x210]
CALL 0x001f03a0
CMP EAX,0x0
JNZ 0x001df65d
LEA RDI,[RBP + -0x610]
XOR ESI,ESI
MOV EDX,0x200
CALL 0x0012a2a0
MOV byte ptr [RBP + -0x610],0x2
LEA RDI,[RBP + -0x410]
LEA RSI,[RBP + -0x210]
MOV EDX,0x1ff
CALL 0x0024dd80
MOV qword ptr [RBP + -0x670],RAX
LEA RDI,[RBP + -0x210]
MOV RSI,qword ptr [RBP + -0x630]
XOR EAX,EAX
MOV EDX,EAX
CALL 0x001df440
MOV qword ptr [RBP + -0x648],RAX
MOV RDI,qword ptr [RBP + -0x648]
LEA RSI,[RBP + -0x410]
MOV RAX,qword ptr [RBP + -0x648]
LEA RCX,[RBP + -0x210]
SUB RAX,RCX
CDQE
MOV EDX,0x1ff
SUB RDX,RAX
CALL 0x0024dd80
LAB_001df65d:
JMP 0x001df65f
LAB_001df65f:
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x8
CMP EAX,0x0
JZ 0x001df680
LEA RDI,[RBP + -0x210]
LEA RSI,[RBP + -0x210]
CALL 0x001e8660
LAB_001df680:
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x4
CMP EAX,0x0
JZ 0x001df6a1
LEA RDI,[RBP + -0x210]
LEA RSI,[RBP + -0x210]
CALL 0x001e90e0
LAB_001df6a1:
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x100
CMP EAX,0x0
JNZ 0x001df728
MOV RDI,qword ptr [RBP + -0x628]
MOV ESI,0x2e
CALL 0x0012a400
MOV qword ptr [RBP + -0x648],RAX
CMP RAX,0x0
JZ 0x001df728
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x2
CMP EAX,0x0
JNZ 0x001df700
MOV RDI,qword ptr [RBP + -0x628]
CALL 0x001df950
MOV qword ptr [RBP + -0x660],RAX
LEA RAX,[0x257a9f]
MOV qword ptr [RBP + -0x658],RAX
JMP 0x001df726
LAB_001df700:
MOV RAX,qword ptr [RBP + -0x648]
MOV RCX,qword ptr [RBP + -0x628]
SUB RAX,RCX
MOV qword ptr [RBP + -0x660],RAX
MOV RAX,qword ptr [RBP + -0x638]
MOV qword ptr [RBP + -0x658],RAX
LAB_001df726:
JMP 0x001df749
LAB_001df728:
MOV RDI,qword ptr [RBP + -0x628]
CALL 0x001df950
MOV qword ptr [RBP + -0x660],RAX
MOV RAX,qword ptr [RBP + -0x638]
MOV qword ptr [RBP + -0x658],RAX
LAB_001df749:
LEA RDI,[RBP + -0x210]
CALL 0x0012a340
ADD RAX,qword ptr [RBP + -0x660]
MOV qword ptr [RBP + -0x680],RAX
MOV RDI,qword ptr [RBP + -0x658]
CALL 0x0012a340
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x680]
ADD RAX,RCX
CMP RAX,0x200
JNC 0x001df795
CMP qword ptr [RBP + -0x660],0x100
JC 0x001df82d
LAB_001df795:
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x40
CMP EAX,0x0
JZ 0x001df7b5
JMP 0x001df7a5
LAB_001df7a5:
MOV qword ptr [RBP + -0x618],0x0
JMP 0x001df919
LAB_001df7b5:
MOV RDI,qword ptr [RBP + -0x650]
CALL 0x001df950
MOV qword ptr [RBP + -0x678],RAX
JMP 0x001df7ca
LAB_001df7ca:
MOV RAX,qword ptr [RBP + -0x620]
MOV qword ptr [RBP + -0x690],RAX
MOV RAX,qword ptr [RBP + -0x650]
MOV qword ptr [RBP + -0x688],RAX
CMP qword ptr [RBP + -0x678],0x1ff
JNC 0x001df803
MOV RAX,qword ptr [RBP + -0x678]
MOV qword ptr [RBP + -0x698],RAX
JMP 0x001df811
LAB_001df803:
MOV EAX,0x1ff
MOV qword ptr [RBP + -0x698],RAX
JMP 0x001df811
LAB_001df811:
MOV RSI,qword ptr [RBP + -0x688]
MOV RDI,qword ptr [RBP + -0x690]
MOV RDX,qword ptr [RBP + -0x698]
CALL 0x0024dd80
JMP 0x001df8a8
LAB_001df82d:
MOV RAX,qword ptr [RBP + -0x620]
CMP RAX,qword ptr [RBP + -0x650]
JNZ 0x001df865
LEA RDI,[RBP + -0x410]
MOV RSI,qword ptr [RBP + -0x628]
MOV RDX,qword ptr [RBP + -0x660]
CALL 0x0012a120
LEA RAX,[RBP + -0x410]
MOV qword ptr [RBP + -0x628],RAX
LAB_001df865:
MOV RDI,qword ptr [RBP + -0x620]
LEA RSI,[RBP + -0x210]
CALL 0x0012a710
MOV RDI,RAX
MOV RSI,qword ptr [RBP + -0x628]
MOV RDX,qword ptr [RBP + -0x660]
CALL 0x0024dd80
MOV qword ptr [RBP + -0x648],RAX
MOV RDI,qword ptr [RBP + -0x648]
MOV RSI,qword ptr [RBP + -0x658]
CALL 0x0012a710
LAB_001df8a8:
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x20
CMP EAX,0x0
JZ 0x001df8cf
MOV RDI,qword ptr [RBP + -0x620]
MOV RSI,qword ptr [RBP + -0x620]
XOR EAX,EAX
MOV EDX,EAX
CALL 0x001f5040
JMP 0x001df909
LAB_001df8cf:
MOV EAX,dword ptr [RBP + -0x63c]
AND EAX,0x10
CMP EAX,0x0
JZ 0x001df907
LEA RDI,[RBP + -0x410]
MOV RSI,qword ptr [RBP + -0x620]
CALL 0x0012a710
MOV RDI,qword ptr [RBP + -0x620]
LEA RSI,[RBP + -0x410]
XOR EAX,EAX
MOV EDX,EAX
CALL 0x001f4e40
LAB_001df907:
JMP 0x001df909
LAB_001df909:
JMP 0x001df90b
LAB_001df90b:
MOV RAX,qword ptr [RBP + -0x620]
MOV qword ptr [RBP + -0x618],RAX
LAB_001df919:
MOV RAX,qword ptr [RBP + -0x618]
MOV qword ptr [RBP + -0x6a0],RAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x001df949
MOV RAX,qword ptr [RBP + -0x6a0]
ADD RSP,0x6a0
POP RBP
RET
LAB_001df949:
CALL 0x0012a250
|
char * fn_format(char *param_1,char *param_2,int8 param_3,char *param_4,uint param_5)
{
int iVar1;
size_t sVar2;
long lVar3;
char *pcVar4;
long in_FS_OFFSET;
ulong local_6a0;
int1 local_670 [8];
ulong local_668;
char *local_660;
char *local_658;
char *local_650;
uint local_644;
char *local_640;
int8 local_638;
char *local_630;
char *local_628;
char *local_620;
int1 local_618 [512];
char local_418 [512];
char local_218 [520];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_658 = param_2;
local_644 = param_5;
local_640 = param_4;
local_638 = param_3;
local_630 = param_2;
local_628 = param_1;
local_668 = dirname_part(local_218,param_2,local_670);
local_630 = local_630 + local_668;
if ((local_668 == 0) || ((local_644 & 1) != 0)) {
convert_dirname(local_218,local_638,0);
}
else if (((local_644 & 0x80) != 0) && (iVar1 = test_if_hard_path(local_218), iVar1 == 0)) {
memset(local_618,0,0x200);
local_618[0] = 2;
strmake(local_418,local_218,0x1ff);
local_650 = (char *)convert_dirname(local_218,local_638,0);
strmake(local_650,local_418,0x1ff - (long)((int)local_650 - (int)local_218));
}
if ((local_644 & 8) != 0) {
pack_dirname(local_218,local_218);
}
if ((local_644 & 4) != 0) {
unpack_dirname(local_218,local_218);
}
if (((local_644 & 0x100) == 0) && (local_650 = strchr(local_630,0x2e), local_650 != (char *)0x0))
{
if ((local_644 & 2) == 0) {
local_668 = strlength(local_630);
local_660 = "";
}
else {
local_668 = (long)local_650 - (long)local_630;
local_660 = local_640;
}
}
else {
local_668 = strlength(local_630);
local_660 = local_640;
}
sVar2 = strlen(local_218);
lVar3 = sVar2 + local_668;
sVar2 = strlen(local_660);
if ((lVar3 + sVar2 < 0x200) && (local_668 < 0x100)) {
if (local_628 == local_658) {
memmove(local_418,local_630,local_668);
local_630 = local_418;
}
pcVar4 = stpcpy(local_628,local_218);
local_650 = (char *)strmake(pcVar4,local_630,local_668);
stpcpy(local_650,local_660);
}
else {
if ((local_644 & 0x40) != 0) {
local_620 = (char *)0x0;
goto LAB_001df919;
}
local_6a0 = strlength(local_658);
if (0x1fe < local_6a0) {
local_6a0 = 0x1ff;
}
strmake(local_628,local_658,local_6a0);
}
if ((local_644 & 0x20) == 0) {
if ((local_644 & 0x10) != 0) {
stpcpy(local_418,local_628);
my_readlink(local_628,local_418,0);
}
}
else {
my_realpath(local_628,local_628,0);
}
local_620 = local_628;
LAB_001df919:
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return local_620;
}
|
|
7,868 |
CLI::App::_process_callbacks()
|
MikePodsytnik[P]TCRtrie/build_O0/_deps/cli11-src/include/CLI/impl/App_inl.hpp
|
CLI11_INLINE void App::_process_callbacks() {
for(App_p &sub : subcommands_) {
// process the priority option_groups first
if(sub->get_name().empty() && sub->parse_complete_callback_) {
if(sub->count_all() > 0) {
sub->_process_callbacks();
sub->run_callback();
}
}
}
for(const Option_p &opt : options_) {
if((*opt) && !opt->get_callback_run()) {
opt->run_callback();
}
}
for(App_p &sub : subcommands_) {
if(!sub->parse_complete_callback_) {
sub->_process_callbacks();
}
}
}
|
O0
|
cpp
|
CLI::App::_process_callbacks():
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x70(%rbp)
addq $0x280, %rax # imm = 0x280
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x33d20
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
callq 0x33d50
movq %rax, -0x20(%rbp)
leaq -0x18(%rbp), %rdi
leaq -0x20(%rbp), %rsi
callq 0x33d80
testb $0x1, %al
jne 0x3a97e
jmp 0x3aa14
leaq -0x18(%rbp), %rdi
callq 0x33dc0
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
callq 0x33de0
movq %rax, %rdi
callq 0xd650
movq %rax, %rdi
callq 0x99c0
testb $0x1, %al
jne 0x3a9aa
jmp 0x3aa04
movq -0x28(%rbp), %rdi
callq 0x33de0
movq %rax, %rdi
addq $0x70, %rdi
callq 0x32e20
testb $0x1, %al
jne 0x3a9c5
jmp 0x3aa04
movq -0x28(%rbp), %rdi
callq 0x33de0
movq %rax, %rdi
callq 0x3d530
cmpq $0x0, %rax
jbe 0x3aa02
movq -0x28(%rbp), %rdi
callq 0x33de0
movq %rax, %rdi
callq 0x3a930
movq -0x28(%rbp), %rdi
callq 0x33de0
movq %rax, %rdi
xorl %edx, %edx
movl %edx, %esi
callq 0x33a70
jmp 0x3aa04
jmp 0x3aa06
leaq -0x18(%rbp), %rdi
callq 0x33e00
jmp 0x3a968
movq -0x70(%rbp), %rax
addq $0xd8, %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
callq 0x280f0
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rdi
callq 0x28120
movq %rax, -0x40(%rbp)
leaq -0x38(%rbp), %rdi
leaq -0x40(%rbp), %rsi
callq 0x28150
testb $0x1, %al
jne 0x3aa4f
jmp 0x3aaa6
leaq -0x38(%rbp), %rdi
callq 0x28190
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rdi
callq 0x301c0
movq %rax, %rdi
callq 0x3d660
testb $0x1, %al
jne 0x3aa73
jmp 0x3aa99
movq -0x48(%rbp), %rdi
callq 0x195d0
movq %rax, %rdi
callq 0x3d6a0
testb $0x1, %al
jne 0x3aa99
movq -0x48(%rbp), %rdi
callq 0x195d0
movq %rax, %rdi
callq 0x3d6c0
jmp 0x3aa9b
leaq -0x38(%rbp), %rdi
callq 0x28310
jmp 0x3aa3c
movq -0x70(%rbp), %rax
addq $0x280, %rax # imm = 0x280
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rdi
callq 0x33d20
movq %rax, -0x58(%rbp)
movq -0x50(%rbp), %rdi
callq 0x33d50
movq %rax, -0x60(%rbp)
leaq -0x58(%rbp), %rdi
leaq -0x60(%rbp), %rsi
callq 0x33d80
testb $0x1, %al
jne 0x3aae1
jmp 0x3ab25
leaq -0x58(%rbp), %rdi
callq 0x33dc0
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rdi
callq 0x33de0
movq %rax, %rdi
addq $0x70, %rdi
callq 0x32e20
testb $0x1, %al
jne 0x3ab18
movq -0x68(%rbp), %rdi
callq 0x33de0
movq %rax, %rdi
callq 0x3a930
jmp 0x3ab1a
leaq -0x58(%rbp), %rdi
callq 0x33e00
jmp 0x3aace
addq $0x70, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
_ZN3CLI3App18_process_callbacksEv:
push rbp
mov rbp, rsp
sub rsp, 70h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov [rbp+var_70], rax
add rax, 280h
mov [rbp+var_10], rax
mov rdi, [rbp+var_10]
call _ZNSt6vectorISt10shared_ptrIN3CLI3AppEESaIS3_EE5beginEv; std::vector<std::shared_ptr<CLI::App>>::begin(void)
mov [rbp+var_18], rax
mov rdi, [rbp+var_10]
call _ZNSt6vectorISt10shared_ptrIN3CLI3AppEESaIS3_EE3endEv; std::vector<std::shared_ptr<CLI::App>>::end(void)
mov [rbp+var_20], rax
loc_3A968:
lea rdi, [rbp+var_18]
lea rsi, [rbp+var_20]
call _ZN9__gnu_cxxneIPSt10shared_ptrIN3CLI3AppEESt6vectorIS4_SaIS4_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_; __gnu_cxx::operator!=<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>(__gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>> const&,__gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>> const&)
test al, 1
jnz short loc_3A97E
jmp loc_3AA14
loc_3A97E:
lea rdi, [rbp+var_18]
call _ZNK9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3CLI3AppEESt6vectorIS4_SaIS4_EEEdeEv; __gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>::operator*(void)
mov [rbp+var_28], rax
mov rdi, [rbp+var_28]
call _ZNKSt19__shared_ptr_accessIN3CLI3AppELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax
call _ZNK3CLI3App8get_nameB5cxx11Ev; CLI::App::get_name(void)
mov rdi, rax
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5emptyEv; std::string::empty(void)
test al, 1
jnz short loc_3A9AA
jmp short loc_3AA04
loc_3A9AA:
mov rdi, [rbp+var_28]
call _ZNKSt19__shared_ptr_accessIN3CLI3AppELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax
add rdi, 70h ; 'p'
call _ZNKSt8functionIFvvEEcvbEv; std::function<void ()(void)>::operator bool(void)
test al, 1
jnz short loc_3A9C5
jmp short loc_3AA04
loc_3A9C5:
mov rdi, [rbp+var_28]
call _ZNKSt19__shared_ptr_accessIN3CLI3AppELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax; this
call _ZNK3CLI3App9count_allEv; CLI::App::count_all(void)
cmp rax, 0
jbe short loc_3AA02
mov rdi, [rbp+var_28]
call _ZNKSt19__shared_ptr_accessIN3CLI3AppELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax; this
call _ZN3CLI3App18_process_callbacksEv; CLI::App::_process_callbacks(void)
mov rdi, [rbp+var_28]
call _ZNKSt19__shared_ptr_accessIN3CLI3AppELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax; this
xor edx, edx; bool
mov esi, edx; bool
call _ZN3CLI3App12run_callbackEbb; CLI::App::run_callback(bool,bool)
loc_3AA02:
jmp short $+2
loc_3AA04:
jmp short $+2
loc_3AA06:
lea rdi, [rbp+var_18]
call _ZN9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3CLI3AppEESt6vectorIS4_SaIS4_EEEppEv; __gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>::operator++(void)
jmp loc_3A968
loc_3AA14:
mov rax, [rbp+var_70]
add rax, 0D8h
mov [rbp+var_30], rax
mov rdi, [rbp+var_30]
call _ZNSt6vectorISt10unique_ptrIN3CLI6OptionESt14default_deleteIS2_EESaIS5_EE5beginEv; std::vector<std::unique_ptr<CLI::Option>>::begin(void)
mov [rbp+var_38], rax
mov rdi, [rbp+var_30]
call _ZNSt6vectorISt10unique_ptrIN3CLI6OptionESt14default_deleteIS2_EESaIS5_EE3endEv; std::vector<std::unique_ptr<CLI::Option>>::end(void)
mov [rbp+var_40], rax
loc_3AA3C:
lea rdi, [rbp+var_38]
lea rsi, [rbp+var_40]
call _ZN9__gnu_cxxneIPSt10unique_ptrIN3CLI6OptionESt14default_deleteIS3_EESt6vectorIS6_SaIS6_EEEEbRKNS_17__normal_iteratorIT_T0_EESG_; __gnu_cxx::operator!=<std::unique_ptr<CLI::Option> *,std::vector<std::unique_ptr<CLI::Option>>>(__gnu_cxx::__normal_iterator<std::unique_ptr<CLI::Option> *,std::vector<std::unique_ptr<CLI::Option>>> const&,__gnu_cxx::__normal_iterator<std::unique_ptr<CLI::Option> *,std::vector<std::unique_ptr<CLI::Option>>> const&)
test al, 1
jnz short loc_3AA4F
jmp short loc_3AAA6
loc_3AA4F:
lea rdi, [rbp+var_38]
call _ZNK9__gnu_cxx17__normal_iteratorIPSt10unique_ptrIN3CLI6OptionESt14default_deleteIS3_EESt6vectorIS6_SaIS6_EEEdeEv; __gnu_cxx::__normal_iterator<std::unique_ptr<CLI::Option> *,std::vector<std::unique_ptr<CLI::Option>>>::operator*(void)
mov [rbp+var_48], rax
mov rdi, [rbp+var_48]
call _ZNKSt10unique_ptrIN3CLI6OptionESt14default_deleteIS1_EEdeEv; std::unique_ptr<CLI::Option>::operator*(void)
mov rdi, rax
call _ZNK3CLI6OptioncvbEv; CLI::Option::operator bool(void)
test al, 1
jnz short loc_3AA73
jmp short loc_3AA99
loc_3AA73:
mov rdi, [rbp+var_48]
call _ZNKSt10unique_ptrIN3CLI6OptionESt14default_deleteIS1_EEptEv; std::unique_ptr<CLI::Option>::operator->(void)
mov rdi, rax; this
call _ZNK3CLI6Option16get_callback_runEv; CLI::Option::get_callback_run(void)
test al, 1
jnz short loc_3AA99
mov rdi, [rbp+var_48]
call _ZNKSt10unique_ptrIN3CLI6OptionESt14default_deleteIS1_EEptEv; std::unique_ptr<CLI::Option>::operator->(void)
mov rdi, rax; this
call _ZN3CLI6Option12run_callbackEv; CLI::Option::run_callback(void)
loc_3AA99:
jmp short $+2
loc_3AA9B:
lea rdi, [rbp+var_38]
call _ZN9__gnu_cxx17__normal_iteratorIPSt10unique_ptrIN3CLI6OptionESt14default_deleteIS3_EESt6vectorIS6_SaIS6_EEEppEv; __gnu_cxx::__normal_iterator<std::unique_ptr<CLI::Option> *,std::vector<std::unique_ptr<CLI::Option>>>::operator++(void)
jmp short loc_3AA3C
loc_3AAA6:
mov rax, [rbp+var_70]
add rax, 280h
mov [rbp+var_50], rax
mov rdi, [rbp+var_50]
call _ZNSt6vectorISt10shared_ptrIN3CLI3AppEESaIS3_EE5beginEv; std::vector<std::shared_ptr<CLI::App>>::begin(void)
mov [rbp+var_58], rax
mov rdi, [rbp+var_50]
call _ZNSt6vectorISt10shared_ptrIN3CLI3AppEESaIS3_EE3endEv; std::vector<std::shared_ptr<CLI::App>>::end(void)
mov [rbp+var_60], rax
loc_3AACE:
lea rdi, [rbp+var_58]
lea rsi, [rbp+var_60]
call _ZN9__gnu_cxxneIPSt10shared_ptrIN3CLI3AppEESt6vectorIS4_SaIS4_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_; __gnu_cxx::operator!=<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>(__gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>> const&,__gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>> const&)
test al, 1
jnz short loc_3AAE1
jmp short loc_3AB25
loc_3AAE1:
lea rdi, [rbp+var_58]
call _ZNK9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3CLI3AppEESt6vectorIS4_SaIS4_EEEdeEv; __gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>::operator*(void)
mov [rbp+var_68], rax
mov rdi, [rbp+var_68]
call _ZNKSt19__shared_ptr_accessIN3CLI3AppELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax
add rdi, 70h ; 'p'
call _ZNKSt8functionIFvvEEcvbEv; std::function<void ()(void)>::operator bool(void)
test al, 1
jnz short loc_3AB18
mov rdi, [rbp+var_68]
call _ZNKSt19__shared_ptr_accessIN3CLI3AppELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax; this
call _ZN3CLI3App18_process_callbacksEv; CLI::App::_process_callbacks(void)
loc_3AB18:
jmp short $+2
loc_3AB1A:
lea rdi, [rbp+var_58]
call _ZN9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN3CLI3AppEESt6vectorIS4_SaIS4_EEEppEv; __gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>::operator++(void)
jmp short loc_3AACE
loc_3AB25:
add rsp, 70h
pop rbp
retn
|
bool CLI::App::_process_callbacks(CLI::App *this)
{
long long v1; // rax
long long v2; // rax
long long v3; // rax
CLI::App *v4; // rax
CLI::App *v5; // rax
CLI::App *v6; // rax
long long v7; // rax
CLI::Option *v8; // rax
CLI::Option *v9; // rax
bool result; // al
long long v11; // rax
CLI::App *v12; // rax
long long v13; // [rsp+8h] [rbp-68h]
long long v14; // [rsp+10h] [rbp-60h] BYREF
_QWORD v15[2]; // [rsp+18h] [rbp-58h] BYREF
long long v16; // [rsp+28h] [rbp-48h]
long long v17; // [rsp+30h] [rbp-40h] BYREF
_QWORD v18[2]; // [rsp+38h] [rbp-38h] BYREF
long long v19; // [rsp+48h] [rbp-28h]
long long v20; // [rsp+50h] [rbp-20h] BYREF
_QWORD v21[3]; // [rsp+58h] [rbp-18h] BYREF
v21[2] = this;
v21[1] = (char *)this + 640;
v21[0] = std::vector<std::shared_ptr<CLI::App>>::begin((long long)this + 640);
v20 = std::vector<std::shared_ptr<CLI::App>>::end((long long)this + 640);
while ( __gnu_cxx::operator!=<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>(
(long long)v21,
(long long)&v20) )
{
v19 = __gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>::operator*((long long)v21);
v1 = std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v19);
v2 = CLI::App::get_name[abi:cxx11](v1);
if ( (std::string::empty(v2) & 1) != 0 )
{
v3 = std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v19);
if ( std::function<void ()(void)>::operator bool((std::_Function_base *)(v3 + 112)) )
{
v4 = (CLI::App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v19);
if ( CLI::App::count_all(v4) )
{
v5 = (CLI::App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v19);
CLI::App::_process_callbacks(v5);
v6 = (CLI::App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v19);
CLI::App::run_callback(v6, 0, 0);
}
}
}
__gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>::operator++(v21);
}
v18[1] = (char *)this + 216;
v18[0] = std::vector<std::unique_ptr<CLI::Option>>::begin((long long)this + 216);
v17 = std::vector<std::unique_ptr<CLI::Option>>::end((long long)this + 216);
while ( __gnu_cxx::operator!=<std::unique_ptr<CLI::Option> *,std::vector<std::unique_ptr<CLI::Option>>>(
(long long)v18,
(long long)&v17) )
{
v16 = __gnu_cxx::__normal_iterator<std::unique_ptr<CLI::Option> *,std::vector<std::unique_ptr<CLI::Option>>>::operator*((long long)v18);
v7 = std::unique_ptr<CLI::Option>::operator*();
if ( (CLI::Option::operator bool(v7) & 1) != 0 )
{
v8 = (CLI::Option *)std::unique_ptr<CLI::Option>::operator->(v16);
if ( (CLI::Option::get_callback_run(v8) & 1) == 0 )
{
v9 = (CLI::Option *)std::unique_ptr<CLI::Option>::operator->(v16);
CLI::Option::run_callback(v9);
}
}
__gnu_cxx::__normal_iterator<std::unique_ptr<CLI::Option> *,std::vector<std::unique_ptr<CLI::Option>>>::operator++(v18);
}
v15[1] = (char *)this + 640;
v15[0] = std::vector<std::shared_ptr<CLI::App>>::begin((long long)this + 640);
v14 = std::vector<std::shared_ptr<CLI::App>>::end((long long)this + 640);
while ( 1 )
{
result = __gnu_cxx::operator!=<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>(
(long long)v15,
(long long)&v14);
if ( !result )
break;
v13 = __gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>::operator*((long long)v15);
v11 = std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v13);
if ( !std::function<void ()(void)>::operator bool((std::_Function_base *)(v11 + 112)) )
{
v12 = (CLI::App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v13);
CLI::App::_process_callbacks(v12);
}
__gnu_cxx::__normal_iterator<std::shared_ptr<CLI::App> *,std::vector<std::shared_ptr<CLI::App>>>::operator++(v15);
}
return result;
}
|
_process_callbacks:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x70
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x70],RAX
ADD RAX,0x280
MOV qword ptr [RBP + -0x10],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00133d20
MOV qword ptr [RBP + -0x18],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00133d50
MOV qword ptr [RBP + -0x20],RAX
LAB_0013a968:
LEA RDI,[RBP + -0x18]
LEA RSI,[RBP + -0x20]
CALL 0x00133d80
TEST AL,0x1
JNZ 0x0013a97e
JMP 0x0013aa14
LAB_0013a97e:
LEA RDI,[RBP + -0x18]
CALL 0x00133dc0
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x00133de0
MOV RDI,RAX
CALL 0x0010d650
MOV RDI,RAX
CALL 0x001099c0
TEST AL,0x1
JNZ 0x0013a9aa
JMP 0x0013aa04
LAB_0013a9aa:
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x00133de0
MOV RDI,RAX
ADD RDI,0x70
CALL 0x00132e20
TEST AL,0x1
JNZ 0x0013a9c5
JMP 0x0013aa04
LAB_0013a9c5:
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x00133de0
MOV RDI,RAX
CALL 0x0013d530
CMP RAX,0x0
JBE 0x0013aa02
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x00133de0
MOV RDI,RAX
CALL 0x0013a930
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x00133de0
MOV RDI,RAX
XOR EDX,EDX
MOV ESI,EDX
CALL 0x00133a70
LAB_0013aa02:
JMP 0x0013aa04
LAB_0013aa04:
JMP 0x0013aa06
LAB_0013aa06:
LEA RDI,[RBP + -0x18]
CALL 0x00133e00
JMP 0x0013a968
LAB_0013aa14:
MOV RAX,qword ptr [RBP + -0x70]
ADD RAX,0xd8
MOV qword ptr [RBP + -0x30],RAX
MOV RDI,qword ptr [RBP + -0x30]
CALL 0x001280f0
MOV qword ptr [RBP + -0x38],RAX
MOV RDI,qword ptr [RBP + -0x30]
CALL 0x00128120
MOV qword ptr [RBP + -0x40],RAX
LAB_0013aa3c:
LEA RDI,[RBP + -0x38]
LEA RSI,[RBP + -0x40]
CALL 0x00128150
TEST AL,0x1
JNZ 0x0013aa4f
JMP 0x0013aaa6
LAB_0013aa4f:
LEA RDI,[RBP + -0x38]
CALL 0x00128190
MOV qword ptr [RBP + -0x48],RAX
MOV RDI,qword ptr [RBP + -0x48]
CALL 0x001301c0
MOV RDI,RAX
CALL 0x0013d660
TEST AL,0x1
JNZ 0x0013aa73
JMP 0x0013aa99
LAB_0013aa73:
MOV RDI,qword ptr [RBP + -0x48]
CALL 0x001195d0
MOV RDI,RAX
CALL 0x0013d6a0
TEST AL,0x1
JNZ 0x0013aa99
MOV RDI,qword ptr [RBP + -0x48]
CALL 0x001195d0
MOV RDI,RAX
CALL 0x0013d6c0
LAB_0013aa99:
JMP 0x0013aa9b
LAB_0013aa9b:
LEA RDI,[RBP + -0x38]
CALL 0x00128310
JMP 0x0013aa3c
LAB_0013aaa6:
MOV RAX,qword ptr [RBP + -0x70]
ADD RAX,0x280
MOV qword ptr [RBP + -0x50],RAX
MOV RDI,qword ptr [RBP + -0x50]
CALL 0x00133d20
MOV qword ptr [RBP + -0x58],RAX
MOV RDI,qword ptr [RBP + -0x50]
CALL 0x00133d50
MOV qword ptr [RBP + -0x60],RAX
LAB_0013aace:
LEA RDI,[RBP + -0x58]
LEA RSI,[RBP + -0x60]
CALL 0x00133d80
TEST AL,0x1
JNZ 0x0013aae1
JMP 0x0013ab25
LAB_0013aae1:
LEA RDI,[RBP + -0x58]
CALL 0x00133dc0
MOV qword ptr [RBP + -0x68],RAX
MOV RDI,qword ptr [RBP + -0x68]
CALL 0x00133de0
MOV RDI,RAX
ADD RDI,0x70
CALL 0x00132e20
TEST AL,0x1
JNZ 0x0013ab18
MOV RDI,qword ptr [RBP + -0x68]
CALL 0x00133de0
MOV RDI,RAX
CALL 0x0013a930
LAB_0013ab18:
JMP 0x0013ab1a
LAB_0013ab1a:
LEA RDI,[RBP + -0x58]
CALL 0x00133e00
JMP 0x0013aace
LAB_0013ab25:
ADD RSP,0x70
POP RBP
RET
|
/* CLI::App::_process_callbacks() */
void __thiscall CLI::App::_process_callbacks(App *this)
{
bool bVar1;
Option *pOVar2;
ulong uVar3;
__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false> *this_00;
long lVar4;
App *pAVar5;
int8 local_68;
int8 local_60;
vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>> *local_58;
unique_ptr<CLI::Option,std::default_delete<CLI::Option>> *local_50;
int8 local_48;
int8 local_40;
vector<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>,std::allocator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>>>
*local_38;
__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false> *local_30;
int8 local_28;
int8 local_20;
vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>> *local_18;
App *local_10;
local_18 = (vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>> *)
(this + 0x280);
local_10 = this;
local_20 = std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>::begin
(local_18);
local_28 = std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>::end
(local_18);
while (bVar1 = __gnu_cxx::operator!=
((__normal_iterator *)&local_20,(__normal_iterator *)&local_28), bVar1) {
local_30 = (__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false> *)
__gnu_cxx::
__normal_iterator<std::shared_ptr<CLI::App>*,std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>>
::operator*((__normal_iterator<std::shared_ptr<CLI::App>*,std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>>
*)&local_20);
pAVar5 = (App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::
operator->(local_30);
get_name_abi_cxx11_(pAVar5);
uVar3 = std::__cxx11::string::empty();
if ((uVar3 & 1) != 0) {
lVar4 = std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->
(local_30);
bVar1 = std::function::operator_cast_to_bool((function *)(lVar4 + 0x70));
if (bVar1) {
pAVar5 = (App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::
operator->(local_30);
lVar4 = count_all(pAVar5);
if (lVar4 != 0) {
pAVar5 = (App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>
::operator->(local_30);
_process_callbacks(pAVar5);
pAVar5 = (App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>
::operator->(local_30);
run_callback(pAVar5,false,false);
}
}
}
__gnu_cxx::
__normal_iterator<std::shared_ptr<CLI::App>*,std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>>
::operator++((__normal_iterator<std::shared_ptr<CLI::App>*,std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>>
*)&local_20);
}
local_38 = (vector<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>,std::allocator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>>>
*)(this + 0xd8);
local_40 = std::
vector<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>,std::allocator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>>>
::begin(local_38);
local_48 = std::
vector<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>,std::allocator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>>>
::end(local_38);
while (bVar1 = __gnu_cxx::operator!=
((__normal_iterator *)&local_40,(__normal_iterator *)&local_48), bVar1) {
local_50 = (unique_ptr<CLI::Option,std::default_delete<CLI::Option>> *)
__gnu_cxx::
__normal_iterator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>*,std::vector<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>,std::allocator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>>>>
::operator*((__normal_iterator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>*,std::vector<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>,std::allocator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>>>>
*)&local_40);
pOVar2 = (Option *)
std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>::operator*(local_50);
bVar1 = Option::operator_cast_to_bool(pOVar2);
if (bVar1) {
pOVar2 = (Option *)
std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>::operator->(local_50);
uVar3 = Option::get_callback_run(pOVar2);
if ((uVar3 & 1) == 0) {
pOVar2 = (Option *)
std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>::operator->(local_50)
;
Option::run_callback(pOVar2);
}
}
__gnu_cxx::
__normal_iterator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>*,std::vector<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>,std::allocator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>>>>
::operator++((__normal_iterator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>*,std::vector<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>,std::allocator<std::unique_ptr<CLI::Option,std::default_delete<CLI::Option>>>>>
*)&local_40);
}
local_58 = (vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>> *)
(this + 0x280);
local_60 = std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>::begin
(local_58);
local_68 = std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>::end
(local_58);
while (bVar1 = __gnu_cxx::operator!=
((__normal_iterator *)&local_60,(__normal_iterator *)&local_68), bVar1) {
this_00 = (__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false> *)
__gnu_cxx::
__normal_iterator<std::shared_ptr<CLI::App>*,std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>>
::operator*((__normal_iterator<std::shared_ptr<CLI::App>*,std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>>
*)&local_60);
lVar4 = std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::operator->
(this_00);
bVar1 = std::function::operator_cast_to_bool((function *)(lVar4 + 0x70));
if (!bVar1) {
pAVar5 = (App *)std::__shared_ptr_access<CLI::App,(__gnu_cxx::_Lock_policy)2,false,false>::
operator->(this_00);
_process_callbacks(pAVar5);
}
__gnu_cxx::
__normal_iterator<std::shared_ptr<CLI::App>*,std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>>
::operator++((__normal_iterator<std::shared_ptr<CLI::App>*,std::vector<std::shared_ptr<CLI::App>,std::allocator<std::shared_ptr<CLI::App>>>>
*)&local_60);
}
return;
}
|
|
7,869 |
ggml_easy::ctx::get_weight(char const*, ...)
|
ngxson[P]ggml-easy/ggml-easy.h
|
ggml_tensor * get_weight(const char *fmt, ...) {
std::vector<char> str(128);
va_list va;
va_start(va, fmt);
vsnprintf(str.data(), 128, fmt, va);
va_end(va);
auto it = tensors.find(str.data());
if (it == tensors.end()) {
throw std::runtime_error(string_format("weight tensor not found: %s", str.data()));
}
return it->second;
}
|
O0
|
c
|
ggml_easy::ctx::get_weight(char const*, ...):
subq $0x1b8, %rsp # imm = 0x1B8
testb %al, %al
je 0x1b65b
movaps %xmm0, 0x80(%rsp)
movaps %xmm1, 0x90(%rsp)
movaps %xmm2, 0xa0(%rsp)
movaps %xmm3, 0xb0(%rsp)
movaps %xmm4, 0xc0(%rsp)
movaps %xmm5, 0xd0(%rsp)
movaps %xmm6, 0xe0(%rsp)
movaps %xmm7, 0xf0(%rsp)
movq %r9, 0x78(%rsp)
movq %r8, 0x70(%rsp)
movq %rcx, 0x68(%rsp)
movq %rdx, 0x60(%rsp)
movq %rdi, 0x1b0(%rsp)
movq %rsi, 0x1a8(%rsp)
movq 0x1b0(%rsp), %rax
movq %rax, 0x40(%rsp)
leaq 0x18f(%rsp), %rdi
movq %rdi, 0x48(%rsp)
callq 0xa950
movq 0x48(%rsp), %rdx
leaq 0x190(%rsp), %rdi
movl $0x80, %esi
callq 0xf570
jmp 0x1b6b7
leaq 0x18f(%rsp), %rdi
callq 0xa560
leaq 0x50(%rsp), %rax
movq %rax, 0x170(%rsp)
leaq 0x1c0(%rsp), %rax
movq %rax, 0x168(%rsp)
movl $0x30, 0x164(%rsp)
movl $0x10, 0x160(%rsp)
leaq 0x190(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0xf5f0
movq %rax, %rdi
movq 0x1a8(%rsp), %rdx
movl $0x80, %esi
leaq 0x160(%rsp), %rcx
callq 0xa3a0
movq 0x20(%rsp), %rdi
movq 0x40(%rsp), %rax
addq $0x8, %rax
movq %rax, 0x28(%rsp)
callq 0xf5f0
movq %rax, 0x30(%rsp)
leaq 0x137(%rsp), %rdi
movq %rdi, 0x38(%rsp)
callq 0xa950
movq 0x30(%rsp), %rsi
movq 0x38(%rsp), %rdx
leaq 0x138(%rsp), %rdi
callq 0x11c60
jmp 0x1b76e
movq 0x28(%rsp), %rdi
leaq 0x138(%rsp), %rsi
callq 0x1c300
movq %rax, 0x18(%rsp)
jmp 0x1b787
movq 0x18(%rsp), %rax
movq %rax, 0x158(%rsp)
leaq 0x138(%rsp), %rdi
callq 0xa380
leaq 0x137(%rsp), %rdi
callq 0xa560
movq 0x40(%rsp), %rdi
addq $0x8, %rdi
callq 0x1c350
movq %rax, 0x128(%rsp)
leaq 0x158(%rsp), %rdi
leaq 0x128(%rsp), %rsi
callq 0x1c330
testb $0x1, %al
jne 0x1b7e2
jmp 0x1b915
movb $0x1, 0x107(%rsp)
movl $0x10, %edi
callq 0xa2c0
movq %rax, 0x10(%rsp)
leaq 0x190(%rsp), %rdi
callq 0xf5f0
movq %rax, %rdx
leaq 0x8f57(%rip), %rsi # 0x24767
xorl %eax, %eax
leaq 0x108(%rsp), %rdi
callq 0xbfd0
jmp 0x1b821
movq 0x10(%rsp), %rdi
leaq 0x108(%rsp), %rsi
callq 0xa850
jmp 0x1b835
movq 0x10(%rsp), %rdi
movb $0x0, 0x107(%rsp)
movq 0x157a7(%rip), %rsi # 0x30ff0
movq 0x15770(%rip), %rdx # 0x30fc0
callq 0xa8f0
jmp 0x1b95f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x180(%rsp)
movl %eax, 0x17c(%rsp)
leaq 0x18f(%rsp), %rdi
callq 0xa560
jmp 0x1b952
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x180(%rsp)
movl %eax, 0x17c(%rsp)
jmp 0x1b8b7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x180(%rsp)
movl %eax, 0x17c(%rsp)
leaq 0x138(%rsp), %rdi
callq 0xa380
leaq 0x137(%rsp), %rdi
callq 0xa560
jmp 0x1b945
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x180(%rsp)
movl %eax, 0x17c(%rsp)
jmp 0x1b8fd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x180(%rsp)
movl %eax, 0x17c(%rsp)
leaq 0x108(%rsp), %rdi
callq 0xa380
testb $0x1, 0x107(%rsp)
jne 0x1b909
jmp 0x1b913
movq 0x10(%rsp), %rdi
callq 0xa420
jmp 0x1b945
leaq 0x158(%rsp), %rdi
callq 0x1c380
movq 0x20(%rax), %rax
movq %rax, 0x8(%rsp)
leaq 0x190(%rsp), %rdi
callq 0xf4b0
movq 0x8(%rsp), %rax
addq $0x1b8, %rsp # imm = 0x1B8
retq
leaq 0x190(%rsp), %rdi
callq 0xf4b0
movq 0x180(%rsp), %rdi
callq 0xa930
nop
|
_ZN9ggml_easy3ctx10get_weightEPKcz:
sub rsp, 1B8h
test al, al
jz short loc_1B65B
movaps [rsp+1B8h+var_138], xmm0
movaps [rsp+1B8h+var_128], xmm1
movaps [rsp+1B8h+var_118], xmm2
movaps [rsp+1B8h+var_108], xmm3
movaps [rsp+1B8h+var_F8], xmm4
movaps [rsp+1B8h+var_E8], xmm5
movaps [rsp+1B8h+var_D8], xmm6
movaps [rsp+1B8h+var_C8], xmm7
loc_1B65B:
mov [rsp+1B8h+var_140], r9
mov [rsp+1B8h+var_148], r8
mov [rsp+1B8h+var_150], rcx
mov [rsp+1B8h+var_158], rdx
mov [rsp+1B8h+var_8], rdi
mov [rsp+1B8h+var_10], rsi
mov rax, [rsp+1B8h+var_8]
mov [rsp+1B8h+var_178], rax
lea rdi, [rsp+1B8h+var_29]
mov [rsp+1B8h+var_170], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rsp+1B8h+var_170]
lea rdi, [rsp+1B8h+var_28]
mov esi, 80h
call _ZNSt6vectorIcSaIcEEC2EmRKS0_; std::vector<char>::vector(ulong,std::allocator<char> const&)
jmp short $+2
loc_1B6B7:
lea rdi, [rsp+1B8h+var_29]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
lea rax, [rsp+1B8h+var_168]
mov [rsp+1B8h+var_48], rax
lea rax, [rsp+1B8h+arg_0]
mov [rsp+1B8h+var_50], rax
mov [rsp+1B8h+var_54], 30h ; '0'
mov [rsp+1B8h+var_58], 10h
lea rdi, [rsp+1B8h+var_28]
mov [rsp+1B8h+var_198], rdi
call _ZNSt6vectorIcSaIcEE4dataEv; std::vector<char>::data(void)
mov rdi, rax
mov rdx, [rsp+1B8h+var_10]
mov esi, 80h
lea rcx, [rsp+1B8h+var_58]
call _vsnprintf
mov rdi, [rsp+1B8h+var_198]
mov rax, [rsp+1B8h+var_178]
add rax, 8
mov [rsp+1B8h+var_190], rax
call _ZNSt6vectorIcSaIcEE4dataEv; std::vector<char>::data(void)
mov [rsp+1B8h+var_188], rax
lea rdi, [rsp+1B8h+var_81]
mov [rsp+1B8h+var_180], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rsi, [rsp+1B8h+var_188]
mov rdx, [rsp+1B8h+var_180]
lea rdi, [rsp+1B8h+var_80]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_1B76E:
mov rdi, [rsp+1B8h+var_190]
lea rsi, [rsp+1B8h+var_80]
call _ZNSt13unordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP11ggml_tensorSt4hashIS5_ESt8equal_toIS5_ESaISt4pairIKS5_S7_EEE4findERSD_; std::unordered_map<std::string,ggml_tensor *>::find(std::string const&)
mov [rsp+1B8h+var_1A0], rax
jmp short $+2
loc_1B787:
mov rax, [rsp+1B8h+var_1A0]
mov [rsp+1B8h+var_60], rax
lea rdi, [rsp+1B8h+var_80]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+1B8h+var_81]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rdi, [rsp+1B8h+var_178]
add rdi, 8
call _ZNSt13unordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP11ggml_tensorSt4hashIS5_ESt8equal_toIS5_ESaISt4pairIKS5_S7_EEE3endEv; std::unordered_map<std::string,ggml_tensor *>::end(void)
mov [rsp+1B8h+var_90], rax
lea rdi, [rsp+1B8h+var_60]
lea rsi, [rsp+1B8h+var_90]
call _ZNSt8__detaileqERKNS_19_Node_iterator_baseISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP11ggml_tensorELb1EEESE_; std::__detail::operator==(std::__detail::_Node_iterator_base<std::pair<std::string const,ggml_tensor *>,true> const&,std::__detail::_Node_iterator_base<std::pair<std::string const,ggml_tensor *>,true> const&)
test al, 1
jnz short loc_1B7E2
jmp loc_1B915
loc_1B7E2:
mov [rsp+1B8h+var_B1], 1
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov [rsp+1B8h+var_1A8], rax
lea rdi, [rsp+1B8h+var_28]
call _ZNSt6vectorIcSaIcEE4dataEv; std::vector<char>::data(void)
mov rdx, rax
lea rsi, aWeightTensorNo; "weight tensor not found: %s"
xor eax, eax
lea rdi, [rsp+1B8h+var_B0]
call _ZN9ggml_easy13string_formatB5cxx11EPKcz; ggml_easy::string_format(char const*,...)
jmp short $+2
loc_1B821:
mov rdi, [rsp+1B8h+var_1A8]
lea rsi, [rsp+1B8h+var_B0]
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
jmp short $+2
loc_1B835:
mov rdi, [rsp+1B8h+var_1A8]; void *
mov [rsp+1B8h+var_B1], 0
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
call ___cxa_throw
jmp loc_1B95F
mov rcx, rax
mov eax, edx
mov [rsp+arg_178], rcx
mov [rsp+arg_174], eax
lea rdi, [rsp+arg_187]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_1B952
mov rcx, rax
mov eax, edx
mov [rsp+arg_178], rcx
mov [rsp+arg_174], eax
jmp short loc_1B8B7
mov rcx, rax
mov eax, edx
mov [rsp+arg_178], rcx
mov [rsp+arg_174], eax
lea rdi, [rsp+arg_130]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_1B8B7:
lea rdi, [rsp+arg_12F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_1B945
mov rcx, rax
mov eax, edx
mov [rsp+arg_178], rcx
mov [rsp+arg_174], eax
jmp short loc_1B8FD
mov rcx, rax
mov eax, edx
mov [rsp+arg_178], rcx
mov [rsp+arg_174], eax
lea rdi, [rsp+arg_100]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_1B8FD:
test [rsp+arg_FF], 1
jnz short loc_1B909
jmp short loc_1B913
loc_1B909:
mov rdi, [rsp+arg_8]; void *
call ___cxa_free_exception
loc_1B913:
jmp short loc_1B945
loc_1B915:
lea rdi, [rsp+1B8h+var_60]
call _ZNKSt8__detail14_Node_iteratorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP11ggml_tensorELb0ELb1EEptEv; std::__detail::_Node_iterator<std::pair<std::string const,ggml_tensor *>,false,true>::operator->(void)
mov rax, [rax+20h]
mov [rsp+1B8h+var_1B0], rax
lea rdi, [rsp+1B8h+var_28]
call _ZNSt6vectorIcSaIcEED2Ev; std::vector<char>::~vector()
mov rax, [rsp+1B8h+var_1B0]
add rsp, 1B8h
retn
loc_1B945:
lea rdi, [rsp+arg_188]
call _ZNSt6vectorIcSaIcEED2Ev; std::vector<char>::~vector()
loc_1B952:
mov rdi, [rsp+arg_178]
call __Unwind_Resume
loc_1B95F:
nop
|
long long ggml_easy::ctx::get_weight(
ggml_easy::ctx *this,
const char *a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14,
char a15)
{
long long v15; // rax
long long v16; // rax
long long v17; // rcx
long long v18; // r8
long long v19; // r9
__m128 v20; // xmm4
__m128 v21; // xmm5
char v23; // [rsp+0h] [rbp-1B8h]
long long v24; // [rsp+8h] [rbp-1B0h]
void *exception; // [rsp+10h] [rbp-1A8h]
long long v26; // [rsp+30h] [rbp-188h]
char v27; // [rsp+50h] [rbp-168h] BYREF
long long v28; // [rsp+60h] [rbp-158h]
long long v29; // [rsp+68h] [rbp-150h]
long long v30; // [rsp+70h] [rbp-148h]
long long v31; // [rsp+78h] [rbp-140h]
__m128 v32; // [rsp+80h] [rbp-138h]
__m128 v33; // [rsp+90h] [rbp-128h]
__m128 v34; // [rsp+A0h] [rbp-118h]
__m128 v35; // [rsp+B0h] [rbp-108h]
__m128 v36; // [rsp+C0h] [rbp-F8h]
__m128 v37; // [rsp+D0h] [rbp-E8h]
__m128 v38; // [rsp+E0h] [rbp-D8h]
__m128 v39; // [rsp+F0h] [rbp-C8h]
char v40; // [rsp+107h] [rbp-B1h]
_BYTE v41[32]; // [rsp+108h] [rbp-B0h] BYREF
long long v42; // [rsp+128h] [rbp-90h] BYREF
char v43; // [rsp+137h] [rbp-81h] BYREF
_BYTE v44[32]; // [rsp+138h] [rbp-80h] BYREF
long long v45; // [rsp+158h] [rbp-60h] BYREF
_DWORD v46[2]; // [rsp+160h] [rbp-58h] BYREF
char *v47; // [rsp+168h] [rbp-50h]
char *v48; // [rsp+170h] [rbp-48h]
char v49; // [rsp+18Fh] [rbp-29h] BYREF
long long v50[3]; // [rsp+190h] [rbp-28h] BYREF
const char *v51; // [rsp+1A8h] [rbp-10h]
ggml_easy::ctx *v52; // [rsp+1B0h] [rbp-8h]
v32 = a7;
v33 = a8;
v34 = a9;
v35 = a10;
v36 = a11;
v37 = a12;
v38 = a13;
v39 = a14;
v31 = a6;
v30 = a5;
v29 = a4;
v28 = a3;
v52 = this;
v51 = a2;
std::allocator<char>::allocator();
std::vector<char>::vector((long long)v50, 128LL, (long long)&v49);
std::allocator<char>::~allocator(&v49);
v48 = &v27;
v47 = &a15;
v46[1] = 48;
v46[0] = 16;
v15 = std::vector<char>::data(v50);
vsnprintf(v15, 128LL, v51, v46);
v26 = std::vector<char>::data(v50);
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>((long long)v44, v26, (long long)&v43);
v45 = std::unordered_map<std::string,ggml_tensor *>::find((char *)this + 8, v44);
std::string::~string(v44);
std::allocator<char>::~allocator(&v43);
v42 = std::unordered_map<std::string,ggml_tensor *>::end((char *)this + 8);
if ( (std::__detail::operator==(&v45, &v42) & 1) != 0 )
{
v40 = 1;
exception = __cxa_allocate_exception(0x10uLL);
v16 = std::vector<char>::data(v50);
ggml_easy::string_format[abi:cxx11](
(long long)v41,
(long long)"weight tensor not found: %s",
v16,
v17,
v18,
v19,
a7,
a8,
a9,
a10,
v20,
v21,
a13,
a14,
v23);
std::runtime_error::runtime_error(exception, v41);
v40 = 0;
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
v24 = *(_QWORD *)(std::__detail::_Node_iterator<std::pair<std::string const,ggml_tensor *>,false,true>::operator->(&v45)
+ 32);
std::vector<char>::~vector(v50);
return v24;
}
|
get_weight:
SUB RSP,0x1b8
TEST AL,AL
JZ 0x0011b65b
MOVAPS xmmword ptr [RSP + 0x80],XMM0
MOVAPS xmmword ptr [RSP + 0x90],XMM1
MOVAPS xmmword ptr [RSP + 0xa0],XMM2
MOVAPS xmmword ptr [RSP + 0xb0],XMM3
MOVAPS xmmword ptr [RSP + 0xc0],XMM4
MOVAPS xmmword ptr [RSP + 0xd0],XMM5
MOVAPS xmmword ptr [RSP + 0xe0],XMM6
MOVAPS xmmword ptr [RSP + 0xf0],XMM7
LAB_0011b65b:
MOV qword ptr [RSP + 0x78],R9
MOV qword ptr [RSP + 0x70],R8
MOV qword ptr [RSP + 0x68],RCX
MOV qword ptr [RSP + 0x60],RDX
MOV qword ptr [RSP + 0x1b0],RDI
MOV qword ptr [RSP + 0x1a8],RSI
MOV RAX,qword ptr [RSP + 0x1b0]
MOV qword ptr [RSP + 0x40],RAX
LEA RDI,[RSP + 0x18f]
MOV qword ptr [RSP + 0x48],RDI
CALL 0x0010a950
MOV RDX,qword ptr [RSP + 0x48]
LAB_0011b6a3:
LEA RDI,[RSP + 0x190]
MOV ESI,0x80
CALL 0x0010f570
JMP 0x0011b6b7
LAB_0011b6b7:
LEA RDI,[RSP + 0x18f]
CALL 0x0010a560
LEA RAX,[RSP + 0x50]
MOV qword ptr [RSP + 0x170],RAX
LEA RAX,[RSP + 0x1c0]
MOV qword ptr [RSP + 0x168],RAX
MOV dword ptr [RSP + 0x164],0x30
MOV dword ptr [RSP + 0x160],0x10
LEA RDI,[RSP + 0x190]
MOV qword ptr [RSP + 0x20],RDI
CALL 0x0010f5f0
MOV RDI,RAX
MOV RDX,qword ptr [RSP + 0x1a8]
MOV ESI,0x80
LEA RCX,[RSP + 0x160]
CALL 0x0010a3a0
MOV RDI,qword ptr [RSP + 0x20]
MOV RAX,qword ptr [RSP + 0x40]
ADD RAX,0x8
MOV qword ptr [RSP + 0x28],RAX
CALL 0x0010f5f0
MOV qword ptr [RSP + 0x30],RAX
LEA RDI,[RSP + 0x137]
MOV qword ptr [RSP + 0x38],RDI
CALL 0x0010a950
MOV RSI,qword ptr [RSP + 0x30]
MOV RDX,qword ptr [RSP + 0x38]
LAB_0011b75f:
LEA RDI,[RSP + 0x138]
CALL 0x00111c60
JMP 0x0011b76e
LAB_0011b76e:
MOV RDI,qword ptr [RSP + 0x28]
LEA RSI,[RSP + 0x138]
CALL 0x0011c300
LAB_0011b780:
MOV qword ptr [RSP + 0x18],RAX
JMP 0x0011b787
LAB_0011b787:
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP + 0x158],RAX
LEA RDI,[RSP + 0x138]
CALL 0x0010a380
LEA RDI,[RSP + 0x137]
CALL 0x0010a560
MOV RDI,qword ptr [RSP + 0x40]
ADD RDI,0x8
CALL 0x0011c350
MOV qword ptr [RSP + 0x128],RAX
LEA RDI,[RSP + 0x158]
LEA RSI,[RSP + 0x128]
CALL 0x0011c330
TEST AL,0x1
JNZ 0x0011b7e2
JMP 0x0011b915
LAB_0011b7e2:
MOV byte ptr [RSP + 0x107],0x1
MOV EDI,0x10
CALL 0x0010a2c0
MOV qword ptr [RSP + 0x10],RAX
LEA RDI,[RSP + 0x190]
CALL 0x0010f5f0
MOV RDX,RAX
LAB_0011b809:
LEA RSI,[0x124767]
XOR EAX,EAX
LEA RDI,[RSP + 0x108]
CALL 0x0010bfd0
JMP 0x0011b821
LAB_0011b821:
MOV RDI,qword ptr [RSP + 0x10]
LEA RSI,[RSP + 0x108]
CALL 0x0010a850
JMP 0x0011b835
LAB_0011b835:
MOV RDI,qword ptr [RSP + 0x10]
MOV byte ptr [RSP + 0x107],0x0
MOV RSI,qword ptr [0x00130ff0]
MOV RDX,qword ptr [0x00130fc0]
CALL 0x0010a8f0
LAB_0011b915:
LEA RDI,[RSP + 0x158]
CALL 0x0011c380
MOV RAX,qword ptr [RAX + 0x20]
MOV qword ptr [RSP + 0x8],RAX
LEA RDI,[RSP + 0x190]
CALL 0x0010f4b0
MOV RAX,qword ptr [RSP + 0x8]
ADD RSP,0x1b8
RET
|
/* ggml_easy::ctx::get_weight(char const*, ...) */
int8 ggml_easy::ctx::get_weight(char *param_1,...)
{
char in_AL;
char *pcVar1;
ulong uVar2;
runtime_error *this;
int8 uVar3;
long lVar4;
int8 in_RCX;
int8 in_RDX;
char *in_RSI;
int8 in_R8;
int8 in_R9;
int8 in_XMM0_Qa;
int8 in_XMM1_Qa;
int8 in_XMM2_Qa;
int8 in_XMM3_Qa;
int8 in_XMM4_Qa;
int8 in_XMM5_Qa;
int8 in_XMM6_Qa;
int8 in_XMM7_Qa;
int1 local_168 [16];
int8 local_158;
int8 local_150;
int8 local_148;
int8 local_140;
int8 local_138;
int8 local_128;
int8 local_118;
int8 local_108;
int8 local_f8;
int8 local_e8;
int8 local_d8;
int8 local_c8;
int1 local_b1;
string local_b0 [32];
int8 local_90;
allocator local_81;
string local_80 [32];
int8 local_60;
int4 local_58;
int4 local_54;
int1 *local_50;
int1 *local_48;
allocator local_29;
vector<char,std::allocator<char>> local_28 [24];
char *local_10;
char *local_8;
if (in_AL != '\0') {
local_138 = in_XMM0_Qa;
local_128 = in_XMM1_Qa;
local_118 = in_XMM2_Qa;
local_108 = in_XMM3_Qa;
local_f8 = in_XMM4_Qa;
local_e8 = in_XMM5_Qa;
local_d8 = in_XMM6_Qa;
local_c8 = in_XMM7_Qa;
}
local_158 = in_RDX;
local_150 = in_RCX;
local_148 = in_R8;
local_140 = in_R9;
local_10 = in_RSI;
local_8 = param_1;
std::allocator<char>::allocator();
/* try { // try from 0011b6a3 to 0011b6b4 has its CatchHandler @ 0011b85a */
std::vector<char,std::allocator<char>>::vector(local_28,0x80,&local_29);
std::allocator<char>::~allocator((allocator<char> *)&local_29);
local_48 = local_168;
local_50 = &stack0x00000008;
local_54 = 0x30;
local_58 = 0x10;
pcVar1 = (char *)std::vector<char,std::allocator<char>>::data(local_28);
vsnprintf(pcVar1,0x80,local_10,&local_58);
pcVar1 = (char *)std::vector<char,std::allocator<char>>::data(local_28);
std::allocator<char>::allocator();
/* try { // try from 0011b75f to 0011b76b has its CatchHandler @ 0011b880 */
std::__cxx11::string::string<std::allocator<char>>(local_80,pcVar1,&local_81);
/* try { // try from 0011b76e to 0011b77f has its CatchHandler @ 0011b896 */
local_60 = std::
unordered_map<std::__cxx11::string,ggml_tensor*,std::hash<std::__cxx11::string>,std::equal_to<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
::find((unordered_map<std::__cxx11::string,ggml_tensor*,std::hash<std::__cxx11::string>,std::equal_to<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
*)(param_1 + 8),local_80);
std::__cxx11::string::~string(local_80);
std::allocator<char>::~allocator((allocator<char> *)&local_81);
local_90 = std::
unordered_map<std::__cxx11::string,ggml_tensor*,std::hash<std::__cxx11::string>,std::equal_to<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
::end();
uVar2 = std::__detail::operator==
((_Node_iterator_base *)&local_60,(_Node_iterator_base *)&local_90);
if ((uVar2 & 1) == 0) {
lVar4 = std::__detail::
_Node_iterator<std::pair<std::__cxx11::string_const,ggml_tensor*>,false,true>::
operator->((_Node_iterator<std::pair<std::__cxx11::string_const,ggml_tensor*>,false,true>
*)&local_60);
uVar3 = *(int8 *)(lVar4 + 0x20);
std::vector<char,std::allocator<char>>::~vector(local_28);
return uVar3;
}
local_b1 = 1;
this = (runtime_error *)__cxa_allocate_exception(0x10);
uVar3 = std::vector<char,std::allocator<char>>::data(local_28);
/* try { // try from 0011b809 to 0011b81e has its CatchHandler @ 0011b8c6 */
string_format_abi_cxx11_((char *)local_b0,"weight tensor not found: %s",uVar3);
/* try { // try from 0011b821 to 0011b854 has its CatchHandler @ 0011b8dc */
std::runtime_error::runtime_error(this,local_b0);
local_b1 = 0;
/* WARNING: Subroutine does not return */
__cxa_throw(this,PTR_typeinfo_00130ff0,PTR__runtime_error_00130fc0);
}
|
|
7,870 |
ggml_easy::ctx::get_weight(char const*, ...)
|
ngxson[P]ggml-easy/ggml-easy.h
|
ggml_tensor * get_weight(const char *fmt, ...) {
std::vector<char> str(128);
va_list va;
va_start(va, fmt);
vsnprintf(str.data(), 128, fmt, va);
va_end(va);
auto it = tensors.find(str.data());
if (it == tensors.end()) {
throw std::runtime_error(string_format("weight tensor not found: %s", str.data()));
}
return it->second;
}
|
O2
|
c
|
ggml_easy::ctx::get_weight(char const*, ...):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x110, %rsp # imm = 0x110
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x60(%rsp), %r12
movq %rdx, 0x10(%r12)
movq %rcx, 0x18(%r12)
movq %r8, 0x20(%r12)
movq %r9, 0x28(%r12)
testb %al, %al
je 0xab16
movaps %xmm0, 0x90(%rsp)
movaps %xmm1, 0xa0(%rsp)
movaps %xmm2, 0xb0(%rsp)
movaps %xmm3, 0xc0(%rsp)
movaps %xmm4, 0xd0(%rsp)
movaps %xmm5, 0xe0(%rsp)
movaps %xmm6, 0xf0(%rsp)
movaps %xmm7, 0x100(%rsp)
leaq 0x28(%rsp), %r15
leaq 0x8(%rsp), %rdx
movl $0x80, %esi
movq %r15, %rdi
callq 0x785a
leaq 0x40(%rsp), %rcx
movq %r12, 0x10(%rcx)
leaq 0x140(%rsp), %rax
movq %rax, 0x8(%rcx)
movabsq $0x3000000010, %rax # imm = 0x3000000010
movq %rax, (%rcx)
movq (%r15), %rdi
movl $0x80, %esi
movq %r14, %rdx
callq 0x5330
movq (%r15), %rsi
leaq 0x8(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0x8b04
addq $0x8, %rbx
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0xadfc
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x5230
testq %rbx, %rbx
je 0xabb5
movq 0x28(%rbx), %rbx
leaq 0x28(%rsp), %rdi
callq 0xb5d8
movq %rbx, %rax
addq $0x110, %rsp # imm = 0x110
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
pushq $0x10
popq %rdi
callq 0x5270
movq %rax, %rbx
movq 0x28(%rsp), %rdx
leaq 0x2b91(%rip), %rsi # 0xd75d
leaq 0x8(%rsp), %rdi
xorl %eax, %eax
callq 0x64eb
movb $0x1, %bpl
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x5730
xorl %ebp, %ebp
movq 0x83ff(%rip), %rsi # 0x12ff0
movq 0x83c8(%rip), %rdx # 0x12fc0
movq %rbx, %rdi
callq 0x57b0
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x5230
testb %bpl, %bpl
jne 0xac17
jmp 0xac33
movq %rax, %r14
movq %rbx, %rdi
callq 0x5390
jmp 0xac33
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x5230
jmp 0xac33
movq %rax, %r14
leaq 0x28(%rsp), %rdi
callq 0xb5d8
movq %r14, %rdi
callq 0x57e0
nop
|
_ZN9ggml_easy3ctx10get_weightEPKcz:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 110h
mov r14, rsi
mov rbx, rdi
lea r12, [rsp+138h+var_D8]
mov [r12+10h], rdx
mov [r12+18h], rcx
mov [r12+20h], r8
mov [r12+28h], r9
test al, al
jz short loc_AB16
movaps [rsp+138h+var_A8], xmm0
movaps [rsp+138h+var_98], xmm1
movaps [rsp+138h+var_88], xmm2
movaps [rsp+138h+var_78], xmm3
movaps [rsp+138h+var_68], xmm4
movaps [rsp+138h+var_58], xmm5
movaps [rsp+138h+var_48], xmm6
movaps [rsp+138h+var_38], xmm7
loc_AB16:
lea r15, [rsp+138h+var_110]
lea rdx, [rsp+138h+var_130]
mov esi, 80h
mov rdi, r15
call _ZNSt6vectorIcSaIcEEC2EmRKS0_; std::vector<char>::vector(ulong,std::allocator<char> const&)
lea rcx, [rsp+138h+var_F8]
mov [rcx+10h], r12
lea rax, [rsp+138h+arg_0]
mov [rcx+8], rax
mov rax, 3000000010h
mov [rcx], rax
mov rdi, [r15]
mov esi, 80h
mov rdx, r14
call _vsnprintf
mov rsi, [r15]
lea rdi, [rsp+138h+var_130]
lea rdx, [rsp+138h+var_131]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
add rbx, 8
lea rsi, [rsp+138h+var_130]
mov rdi, rbx
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P11ggml_tensorESaISA_ENSt8__detail10_Select1stESt8equal_toIS5_ESt4hashIS5_ENSC_18_Mod_range_hashingENSC_20_Default_ranged_hashENSC_20_Prime_rehash_policyENSC_17_Hashtable_traitsILb1ELb0ELb1EEEE4findERS7_; std::_Hashtable<std::string,std::pair<std::string const,ggml_tensor *>,std::allocator<std::pair<std::string const,ggml_tensor *>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::find(std::string const&)
mov rbx, rax
lea rdi, [rsp+138h+var_130]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test rbx, rbx
jz short loc_ABB5
mov rbx, [rbx+28h]
lea rdi, [rsp+138h+var_110]
call _ZNSt12_Vector_baseIcSaIcEED2Ev; std::_Vector_base<char>::~_Vector_base()
mov rax, rbx
add rsp, 110h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_ABB5:
push 10h
pop rdi; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdx, [rsp+138h+var_110]
lea rsi, aWeightTensorNo; "weight tensor not found: %s"
lea rdi, [rsp+138h+var_130]
xor eax, eax
call _ZN9ggml_easy13string_formatB5cxx11EPKcz; ggml_easy::string_format(char const*,...)
mov bpl, 1
lea rsi, [rsp+138h+var_130]
mov rdi, rbx
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
xor ebp, ebp
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rdi, [rsp+138h+var_130]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
jnz short loc_AC17
jmp short loc_AC33
mov r14, rax
loc_AC17:
mov rdi, rbx; void *
call ___cxa_free_exception
jmp short loc_AC33
mov r14, rax
lea rdi, [rsp+138h+var_130]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_AC33
mov r14, rax
loc_AC33:
lea rdi, [rsp+138h+var_110]
call _ZNSt12_Vector_baseIcSaIcEED2Ev; std::_Vector_base<char>::~_Vector_base()
mov rdi, r14
call __Unwind_Resume
|
long long ggml_easy::ctx::get_weight(
ggml_easy::ctx *this,
const char *a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14,
char a15)
{
long long v15; // rbx
long long v16; // rbx
void *exception; // rbx
long long v19; // rcx
long long v20; // r8
long long v21; // r9
__m128 v22; // xmm4
__m128 v23; // xmm5
char v24; // [rsp+0h] [rbp-138h]
_QWORD v25[4]; // [rsp+8h] [rbp-130h] BYREF
long long v26[3]; // [rsp+28h] [rbp-110h] BYREF
_QWORD v27[4]; // [rsp+40h] [rbp-F8h] BYREF
char v28; // [rsp+60h] [rbp-D8h] BYREF
long long v29; // [rsp+70h] [rbp-C8h]
long long v30; // [rsp+78h] [rbp-C0h]
long long v31; // [rsp+80h] [rbp-B8h]
long long v32; // [rsp+88h] [rbp-B0h]
__m128 v33; // [rsp+90h] [rbp-A8h]
__m128 v34; // [rsp+A0h] [rbp-98h]
__m128 v35; // [rsp+B0h] [rbp-88h]
__m128 v36; // [rsp+C0h] [rbp-78h]
__m128 v37; // [rsp+D0h] [rbp-68h]
__m128 v38; // [rsp+E0h] [rbp-58h]
__m128 v39; // [rsp+F0h] [rbp-48h]
__m128 v40; // [rsp+100h] [rbp-38h]
v33 = a7;
v34 = a8;
v35 = a9;
v36 = a10;
v37 = a11;
v38 = a12;
v39 = a13;
v40 = a14;
v29 = a3;
v30 = a4;
v31 = a5;
v32 = a6;
std::vector<char>::vector((long long)v26, 128LL, (long long)v25);
v27[2] = &v28;
v27[1] = &a15;
v27[0] = 0x3000000010LL;
vsnprintf(v26[0], 128LL, a2, v27);
std::string::basic_string<std::allocator<char>>(v25, v26[0]);
v15 = std::_Hashtable<std::string,std::pair<std::string const,ggml_tensor *>,std::allocator<std::pair<std::string const,ggml_tensor *>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::find(
(char *)this + 8,
v25);
std::string::~string(v25);
if ( !v15 )
{
exception = __cxa_allocate_exception(0x10uLL);
ggml_easy::string_format[abi:cxx11](
v25,
(long long)"weight tensor not found: %s",
v26[0],
v19,
v20,
v21,
a7,
a8,
a9,
a10,
v22,
v23,
a13,
a14,
v24);
std::runtime_error::runtime_error(exception, v25);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
v16 = *(_QWORD *)(v15 + 40);
std::_Vector_base<char>::~_Vector_base(v26);
return v16;
}
|
get_weight:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x110
MOV R14,RSI
MOV RBX,RDI
LEA R12,[RSP + 0x60]
MOV qword ptr [R12 + 0x10],RDX
MOV qword ptr [R12 + 0x18],RCX
MOV qword ptr [R12 + 0x20],R8
MOV qword ptr [R12 + 0x28],R9
TEST AL,AL
JZ 0x0010ab16
MOVAPS xmmword ptr [RSP + 0x90],XMM0
MOVAPS xmmword ptr [RSP + 0xa0],XMM1
MOVAPS xmmword ptr [RSP + 0xb0],XMM2
MOVAPS xmmword ptr [RSP + 0xc0],XMM3
MOVAPS xmmword ptr [RSP + 0xd0],XMM4
MOVAPS xmmword ptr [RSP + 0xe0],XMM5
MOVAPS xmmword ptr [RSP + 0xf0],XMM6
MOVAPS xmmword ptr [RSP + 0x100],XMM7
LAB_0010ab16:
LEA R15,[RSP + 0x28]
LEA RDX,[RSP + 0x8]
MOV ESI,0x80
MOV RDI,R15
CALL 0x0010785a
LEA RCX,[RSP + 0x40]
MOV qword ptr [RCX + 0x10],R12
LEA RAX,[RSP + 0x140]
MOV qword ptr [RCX + 0x8],RAX
MOV RAX,0x3000000010
MOV qword ptr [RCX],RAX
MOV RDI,qword ptr [R15]
MOV ESI,0x80
MOV RDX,R14
CALL 0x00105330
MOV RSI,qword ptr [R15]
LAB_0010ab62:
LEA RDI,[RSP + 0x8]
LEA RDX,[RSP + 0x7]
CALL 0x00108b04
ADD RBX,0x8
LAB_0010ab75:
LEA RSI,[RSP + 0x8]
MOV RDI,RBX
CALL 0x0010adfc
LAB_0010ab82:
MOV RBX,RAX
LEA RDI,[RSP + 0x8]
CALL 0x00105230
TEST RBX,RBX
JZ 0x0010abb5
MOV RBX,qword ptr [RBX + 0x28]
LEA RDI,[RSP + 0x28]
CALL 0x0010b5d8
MOV RAX,RBX
ADD RSP,0x110
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_0010abb5:
PUSH 0x10
POP RDI
CALL 0x00105270
MOV RBX,RAX
MOV RDX,qword ptr [RSP + 0x28]
LAB_0010abc5:
LEA RSI,[0x10d75d]
LEA RDI,[RSP + 0x8]
XOR EAX,EAX
CALL 0x001064eb
MOV BPL,0x1
LAB_0010abdb:
LEA RSI,[RSP + 0x8]
MOV RDI,RBX
CALL 0x00105730
XOR EBP,EBP
MOV RSI,qword ptr [0x00112ff0]
MOV RDX,qword ptr [0x00112fc0]
MOV RDI,RBX
CALL 0x001057b0
|
/* ggml_easy::ctx::get_weight(char const*, ...) */
int8 ggml_easy::ctx::get_weight(char *param_1,...)
{
int8 uVar1;
char in_AL;
long lVar2;
runtime_error *this;
int8 in_RCX;
int8 in_RDX;
char *in_RSI;
int8 in_R8;
int8 in_R9;
int8 in_XMM0_Qa;
int8 in_XMM1_Qa;
int8 in_XMM2_Qa;
int8 in_XMM3_Qa;
int8 in_XMM4_Qa;
int8 in_XMM5_Qa;
int8 in_XMM6_Qa;
int8 in_XMM7_Qa;
allocator local_131;
allocator local_130 [32];
char *local_110 [3];
int8 local_f8;
int1 *local_f0;
int1 *local_e8;
int1 local_d8 [16];
int8 local_c8;
int8 local_c0;
int8 local_b8;
int8 local_b0;
int8 local_a8;
int8 local_98;
int8 local_88;
int8 local_78;
int8 local_68;
int8 local_58;
int8 local_48;
int8 local_38;
if (in_AL != '\0') {
local_a8 = in_XMM0_Qa;
local_98 = in_XMM1_Qa;
local_88 = in_XMM2_Qa;
local_78 = in_XMM3_Qa;
local_68 = in_XMM4_Qa;
local_58 = in_XMM5_Qa;
local_48 = in_XMM6_Qa;
local_38 = in_XMM7_Qa;
}
local_c8 = in_RDX;
local_c0 = in_RCX;
local_b8 = in_R8;
local_b0 = in_R9;
std::vector<char,std::allocator<char>>::vector
((vector<char,std::allocator<char>> *)local_110,0x80,local_130);
local_f0 = &stack0x00000008;
local_f8 = 0x3000000010;
local_e8 = local_d8;
vsnprintf(local_110[0],0x80,in_RSI,&local_f8);
/* try { // try from 0010ab62 to 0010ab70 has its CatchHandler @ 0010ac30 */
std::__cxx11::string::string<std::allocator<char>>((string *)local_130,local_110[0],&local_131);
/* try { // try from 0010ab75 to 0010ab81 has its CatchHandler @ 0010ac21 */
lVar2 = std::
_Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,ggml_tensor*>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>,std::__detail::_Select1st,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>
::find((_Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,ggml_tensor*>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>,std::__detail::_Select1st,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>
*)(param_1 + 8),(string *)local_130);
std::__cxx11::string::~string((string *)local_130);
if (lVar2 != 0) {
uVar1 = *(int8 *)(lVar2 + 0x28);
std::_Vector_base<char,std::allocator<char>>::~_Vector_base
((_Vector_base<char,std::allocator<char>> *)local_110);
return uVar1;
}
this = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0010abc5 to 0010abd7 has its CatchHandler @ 0010ac14 */
string_format_abi_cxx11_((char *)local_130,"weight tensor not found: %s",local_110[0]);
/* try { // try from 0010abdb to 0010abff has its CatchHandler @ 0010ac00 */
std::runtime_error::runtime_error(this,(string *)local_130);
/* WARNING: Subroutine does not return */
__cxa_throw(this,PTR_typeinfo_00112ff0,PTR__runtime_error_00112fc0);
}
|
|
7,871 |
spdlog::details::short_filename_formatter<spdlog::details::scoped_padder>::format(spdlog::details::log_msg const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char>>&)
|
AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/pattern_formatter-inl.h
|
void format(const details::log_msg &msg, const std::tm &, memory_buf_t &dest) override {
if (msg.source.empty()) {
ScopedPadder p(0, padinfo_, dest);
return;
}
auto filename = basename(msg.source.filename);
size_t text_size = padinfo_.enabled() ? std::char_traits<char>::length(filename) : 0;
ScopedPadder p(text_size, padinfo_, dest);
fmt_helper::append_string_view(filename, dest);
}
|
O0
|
c
|
spdlog::details::short_filename_formatter<spdlog::details::scoped_padder>::format(spdlog::details::log_msg const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char>>&):
subq $0xc8, %rsp
movq %rdi, 0xb0(%rsp)
movq %rsi, 0xa8(%rsp)
movq %rdx, 0xa0(%rsp)
movq %rcx, 0x98(%rsp)
movq 0xb0(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0xa8(%rsp), %rdi
addq $0x38, %rdi
callq 0x4d490
testb $0x1, %al
jne 0x5efeb
jmp 0x5f019
movq 0x10(%rsp), %rdx
addq $0x8, %rdx
movq 0x98(%rsp), %rcx
leaq 0x70(%rsp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x539a0
leaq 0x70(%rsp), %rdi
callq 0x53a90
jmp 0x5f0f3
movq 0xa8(%rsp), %rax
movq 0x38(%rax), %rdi
callq 0x5f120
movq 0x10(%rsp), %rdi
movq %rax, 0x68(%rsp)
addq $0x8, %rdi
callq 0x3b750
testb $0x1, %al
jne 0x5f043
jmp 0x5f054
movq 0x68(%rsp), %rdi
callq 0x1e520
movq %rax, 0x8(%rsp)
jmp 0x5f05d
xorl %eax, %eax
movq %rax, 0x8(%rsp)
jmp 0x5f05d
movq 0x10(%rsp), %rdx
movq 0x8(%rsp), %rax
movq %rax, 0x60(%rsp)
movq 0x60(%rsp), %rsi
addq $0x8, %rdx
movq 0x98(%rsp), %rcx
leaq 0x38(%rsp), %rdi
callq 0x539a0
movq 0x68(%rsp), %rax
leaq 0x28(%rsp), %rcx
movq %rcx, 0xc0(%rsp)
movq %rax, 0xb8(%rsp)
movq 0xc0(%rsp), %rax
movq %rax, (%rsp)
movq 0xb8(%rsp), %rcx
movq %rcx, (%rax)
movq 0xb8(%rsp), %rdi
callq 0x14280
movq %rax, %rcx
movq (%rsp), %rax
movq %rcx, 0x8(%rax)
movq 0x98(%rsp), %rdx
movq 0x28(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x3b4e0
jmp 0x5f0e9
leaq 0x38(%rsp), %rdi
callq 0x53a90
addq $0xc8, %rsp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x20(%rsp)
movl %eax, 0x1c(%rsp)
leaq 0x38(%rsp), %rdi
callq 0x53a90
movq 0x20(%rsp), %rdi
callq 0x14c80
nopl (%rax)
|
_ZN6spdlog7details24short_filename_formatterINS0_13scoped_padderEE6formatERKNS0_7log_msgERK2tmRN3fmt3v1019basic_memory_bufferIcLm250ESaIcEEE:
sub rsp, 0C8h
mov [rsp+0C8h+var_18], rdi
mov [rsp+0C8h+var_20], rsi
mov [rsp+0C8h+var_28], rdx
mov [rsp+0C8h+var_30], rcx
mov rax, [rsp+0C8h+var_18]
mov [rsp+0C8h+var_B8], rax
mov rdi, [rsp+0C8h+var_20]
add rdi, 38h ; '8'; this
call _ZNK6spdlog10source_loc5emptyEv; spdlog::source_loc::empty(void)
test al, 1
jnz short loc_5EFEB
jmp short loc_5F019
loc_5EFEB:
mov rdx, [rsp+0C8h+var_B8]
add rdx, 8
mov rcx, [rsp+0C8h+var_30]
lea rdi, [rsp+0C8h+var_58]
xor eax, eax
mov esi, eax
call _ZN6spdlog7details13scoped_padderC2EmRKNS0_12padding_infoERN3fmt3v1019basic_memory_bufferIcLm250ESaIcEEE; spdlog::details::scoped_padder::scoped_padder(ulong,spdlog::details::padding_info const&,fmt::v10::basic_memory_buffer<char,250ul,std::allocator<char>> &)
lea rdi, [rsp+0C8h+var_58]; this
call _ZN6spdlog7details13scoped_padderD2Ev; spdlog::details::scoped_padder::~scoped_padder()
jmp loc_5F0F3
loc_5F019:
mov rax, [rsp+0C8h+var_20]
mov rdi, [rax+38h]
call _ZN6spdlog7details24short_filename_formatterINS0_13scoped_padderEE8basenameEPKc; spdlog::details::short_filename_formatter<spdlog::details::scoped_padder>::basename(char const*)
mov rdi, [rsp+0C8h+var_B8]
mov [rsp+0C8h+var_60], rax
add rdi, 8; this
call _ZNK6spdlog7details12padding_info7enabledEv; spdlog::details::padding_info::enabled(void)
test al, 1
jnz short loc_5F043
jmp short loc_5F054
loc_5F043:
mov rdi, [rsp+0C8h+var_60]
call _ZNSt11char_traitsIcE6lengthEPKc; std::char_traits<char>::length(char const*)
mov [rsp+0C8h+var_C0], rax
jmp short loc_5F05D
loc_5F054:
xor eax, eax
mov [rsp+0C8h+var_C0], rax
jmp short $+2
loc_5F05D:
mov rdx, [rsp+0C8h+var_B8]
mov rax, [rsp+0C8h+var_C0]
mov [rsp+0C8h+var_68], rax
mov rsi, [rsp+0C8h+var_68]
add rdx, 8
mov rcx, [rsp+0C8h+var_30]
lea rdi, [rsp+0C8h+var_90]
call _ZN6spdlog7details13scoped_padderC2EmRKNS0_12padding_infoERN3fmt3v1019basic_memory_bufferIcLm250ESaIcEEE; spdlog::details::scoped_padder::scoped_padder(ulong,spdlog::details::padding_info const&,fmt::v10::basic_memory_buffer<char,250ul,std::allocator<char>> &)
mov rax, [rsp+0C8h+var_60]
lea rcx, [rsp+0C8h+var_A0]
mov [rsp+0C8h+var_8], rcx
mov [rsp+0C8h+var_10], rax
mov rax, [rsp+0C8h+var_8]
mov [rsp+0C8h+var_C8], rax
mov rcx, [rsp+0C8h+var_10]
mov [rax], rcx
mov rdi, [rsp+0C8h+var_10]
call _strlen
mov rcx, rax
mov rax, [rsp+0C8h+var_C8]
mov [rax+8], rcx
mov rdx, [rsp+0C8h+var_30]
mov rdi, [rsp+0C8h+var_A0]
mov rsi, [rsp+0C8h+var_98]
call _ZN6spdlog7details10fmt_helper18append_string_viewEN3fmt3v1017basic_string_viewIcEERNS3_19basic_memory_bufferIcLm250ESaIcEEE; spdlog::details::fmt_helper::append_string_view(fmt::v10::basic_string_view<char>,fmt::v10::basic_memory_buffer<char,250ul,std::allocator<char>> &)
jmp short $+2
loc_5F0E9:
lea rdi, [rsp+0C8h+var_90]; this
call _ZN6spdlog7details13scoped_padderD2Ev; spdlog::details::scoped_padder::~scoped_padder()
loc_5F0F3:
add rsp, 0C8h
retn
mov rcx, rax
mov eax, edx
mov [rsp+arg_18], rcx
mov [rsp+arg_14], eax
lea rdi, [rsp+arg_30]; this
call _ZN6spdlog7details13scoped_padderD2Ev; spdlog::details::scoped_padder::~scoped_padder()
mov rdi, [rsp+arg_18]
call __Unwind_Resume
|
void spdlog::details::short_filename_formatter<spdlog::details::scoped_padder>::format(
long long a1,
long long a2,
long long a3,
_QWORD *a4)
{
long long v4; // [rsp+8h] [rbp-C0h]
long long v5; // [rsp+28h] [rbp-A0h] BYREF
long long v6; // [rsp+30h] [rbp-98h]
_BYTE v7[40]; // [rsp+38h] [rbp-90h] BYREF
long long v8; // [rsp+60h] [rbp-68h]
long long v9; // [rsp+68h] [rbp-60h]
_BYTE v10[40]; // [rsp+70h] [rbp-58h] BYREF
_QWORD *v11; // [rsp+98h] [rbp-30h]
long long v12; // [rsp+A0h] [rbp-28h]
long long v13; // [rsp+A8h] [rbp-20h]
long long v14; // [rsp+B0h] [rbp-18h]
long long v15; // [rsp+B8h] [rbp-10h]
long long *v16; // [rsp+C0h] [rbp-8h]
v14 = a1;
v13 = a2;
v12 = a3;
v11 = a4;
if ( spdlog::source_loc::empty((spdlog::source_loc *)(a2 + 56)) )
{
spdlog::details::scoped_padder::scoped_padder(
(spdlog::details::scoped_padder *)v10,
0LL,
(_QWORD *)(a1 + 8),
(long long)v11);
spdlog::details::scoped_padder::~scoped_padder((spdlog::details::scoped_padder *)v10);
}
else
{
v9 = spdlog::details::short_filename_formatter<spdlog::details::scoped_padder>::basename(*(_QWORD *)(v13 + 56));
if ( (spdlog::details::padding_info::enabled((spdlog::details::padding_info *)(a1 + 8)) & 1) != 0 )
v4 = std::char_traits<char>::length(v9);
else
v4 = 0LL;
v8 = v4;
spdlog::details::scoped_padder::scoped_padder(
(spdlog::details::scoped_padder *)v7,
v4,
(_QWORD *)(a1 + 8),
(long long)v11);
v16 = &v5;
v15 = v9;
v5 = v9;
v6 = strlen(v9);
spdlog::details::fmt_helper::append_string_view(v5, v6, v11);
spdlog::details::scoped_padder::~scoped_padder((spdlog::details::scoped_padder *)v7);
}
}
|
format:
SUB RSP,0xc8
MOV qword ptr [RSP + 0xb0],RDI
MOV qword ptr [RSP + 0xa8],RSI
MOV qword ptr [RSP + 0xa0],RDX
MOV qword ptr [RSP + 0x98],RCX
MOV RAX,qword ptr [RSP + 0xb0]
MOV qword ptr [RSP + 0x10],RAX
MOV RDI,qword ptr [RSP + 0xa8]
ADD RDI,0x38
CALL 0x0014d490
TEST AL,0x1
JNZ 0x0015efeb
JMP 0x0015f019
LAB_0015efeb:
MOV RDX,qword ptr [RSP + 0x10]
ADD RDX,0x8
MOV RCX,qword ptr [RSP + 0x98]
LEA RDI,[RSP + 0x70]
XOR EAX,EAX
MOV ESI,EAX
CALL 0x001539a0
LEA RDI,[RSP + 0x70]
CALL 0x00153a90
JMP 0x0015f0f3
LAB_0015f019:
MOV RAX,qword ptr [RSP + 0xa8]
MOV RDI,qword ptr [RAX + 0x38]
CALL 0x0015f120
MOV RDI,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x68],RAX
ADD RDI,0x8
CALL 0x0013b750
TEST AL,0x1
JNZ 0x0015f043
JMP 0x0015f054
LAB_0015f043:
MOV RDI,qword ptr [RSP + 0x68]
CALL 0x0011e520
MOV qword ptr [RSP + 0x8],RAX
JMP 0x0015f05d
LAB_0015f054:
XOR EAX,EAX
MOV qword ptr [RSP + 0x8],RAX
JMP 0x0015f05d
LAB_0015f05d:
MOV RDX,qword ptr [RSP + 0x10]
MOV RAX,qword ptr [RSP + 0x8]
MOV qword ptr [RSP + 0x60],RAX
MOV RSI,qword ptr [RSP + 0x60]
ADD RDX,0x8
MOV RCX,qword ptr [RSP + 0x98]
LEA RDI,[RSP + 0x38]
CALL 0x001539a0
MOV RAX,qword ptr [RSP + 0x68]
LEA RCX,[RSP + 0x28]
MOV qword ptr [RSP + 0xc0],RCX
MOV qword ptr [RSP + 0xb8],RAX
MOV RAX,qword ptr [RSP + 0xc0]
MOV qword ptr [RSP],RAX
MOV RCX,qword ptr [RSP + 0xb8]
MOV qword ptr [RAX],RCX
MOV RDI,qword ptr [RSP + 0xb8]
CALL 0x00114280
MOV RCX,RAX
MOV RAX,qword ptr [RSP]
MOV qword ptr [RAX + 0x8],RCX
MOV RDX,qword ptr [RSP + 0x98]
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,qword ptr [RSP + 0x30]
LAB_0015f0e2:
CALL 0x0013b4e0
LAB_0015f0e7:
JMP 0x0015f0e9
LAB_0015f0e9:
LEA RDI,[RSP + 0x38]
CALL 0x00153a90
LAB_0015f0f3:
ADD RSP,0xc8
RET
|
/* spdlog::details::short_filename_formatter<spdlog::details::scoped_padder>::format(spdlog::details::log_msg
const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char> >&) */
void __thiscall
spdlog::details::short_filename_formatter<spdlog::details::scoped_padder>::format
(short_filename_formatter<spdlog::details::scoped_padder> *this,log_msg *param_1,
tm *param_2,basic_memory_buffer *param_3)
{
ulong uVar1;
size_t sVar2;
ulong local_c0;
fmt_helper *local_a0 [2];
scoped_padder local_90 [40];
ulong local_68;
fmt_helper *local_60;
scoped_padder local_58 [40];
basic_memory_buffer *local_30;
tm *local_28;
log_msg *local_20;
short_filename_formatter<spdlog::details::scoped_padder> *local_18;
fmt_helper *local_10;
fmt_helper **local_8;
local_30 = param_3;
local_28 = param_2;
local_20 = param_1;
local_18 = this;
uVar1 = source_loc::empty((source_loc *)(param_1 + 0x38));
if ((uVar1 & 1) == 0) {
local_60 = (fmt_helper *)basename(*(char **)(local_20 + 0x38));
uVar1 = padding_info::enabled((padding_info *)(this + 8));
if ((uVar1 & 1) == 0) {
local_c0 = 0;
}
else {
local_c0 = std::char_traits<char>::length((char *)local_60);
}
local_68 = local_c0;
scoped_padder::scoped_padder(local_90,local_c0,(padding_info *)(this + 8),local_30);
local_8 = local_a0;
local_10 = local_60;
local_a0[0] = local_60;
sVar2 = strlen((char *)local_60);
/* try { // try from 0015f0e2 to 0015f0e6 has its CatchHandler @ 0015f0fb */
fmt_helper::append_string_view(local_a0[0],sVar2,local_30);
scoped_padder::~scoped_padder(local_90);
}
else {
scoped_padder::scoped_padder(local_58,0,(padding_info *)(this + 8),local_30);
scoped_padder::~scoped_padder(local_58);
}
return;
}
|
|
7,872 |
google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(google::protobuf::Descriptor const*)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/generated_message_reflection.cc
|
void AssignMessageDescriptor(const Descriptor* descriptor) {
for (int i = 0; i < descriptor->nested_type_count(); i++) {
AssignMessageDescriptor(descriptor->nested_type(i));
}
file_level_metadata_->descriptor = descriptor;
file_level_metadata_->reflection =
new Reflection(descriptor,
MigrationToReflectionSchema(default_instance_data_,
offsets_, *schemas_),
DescriptorPool::internal_generated_pool(), factory_);
for (int i = 0; i < descriptor->enum_type_count(); i++) {
AssignEnumDescriptor(descriptor->enum_type(i));
}
schemas_++;
default_instance_data_++;
file_level_metadata_++;
}
|
O0
|
cpp
|
google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(google::protobuf::Descriptor const*):
subq $0xa8, %rsp
movq %rdi, 0xa0(%rsp)
movq %rsi, 0x98(%rsp)
movq 0xa0(%rsp), %rax
movq %rax, 0x28(%rsp)
movl $0x0, 0x94(%rsp)
movl 0x94(%rsp), %eax
movl %eax, 0x24(%rsp)
movq 0x98(%rsp), %rdi
callq 0x1c3340
movl %eax, %ecx
movl 0x24(%rsp), %eax
cmpl %ecx, %eax
jge 0x1c30f5
movq 0x98(%rsp), %rdi
movl 0x94(%rsp), %esi
callq 0x1c3350
movq 0x28(%rsp), %rdi
movq %rax, %rsi
callq 0x1c3070
movl 0x94(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x94(%rsp)
jmp 0x1c309f
movq 0x28(%rsp), %rax
movq 0x98(%rsp), %rcx
movq 0x8(%rax), %rax
movq %rcx, (%rax)
movl $0x60, %edi
callq 0x8c1d0
movq 0x28(%rsp), %rcx
movq %rax, 0x10(%rsp)
movq 0x98(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rcx), %rax
movq 0x20(%rcx), %rsi
movq 0x28(%rcx), %rdx
movups (%rax), %xmm0
movaps %xmm0, 0x40(%rsp)
movq 0x40(%rsp), %rcx
movq 0x48(%rsp), %r8
leaq 0x50(%rsp), %rdi
callq 0x1b8330
jmp 0x1c3154
callq 0x242b30
movq %rax, 0x8(%rsp)
jmp 0x1c3160
movq 0x8(%rsp), %rcx
movq 0x18(%rsp), %rsi
movq 0x10(%rsp), %rdi
movq 0x28(%rsp), %rax
movq (%rax), %r8
leaq 0x50(%rsp), %rdx
callq 0x1abe50
jmp 0x1c3183
movq 0x10(%rsp), %rcx
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rax
movq %rcx, 0x8(%rax)
movl $0x0, 0x30(%rsp)
movl 0x30(%rsp), %eax
movl %eax, 0x4(%rsp)
movq 0x98(%rsp), %rdi
callq 0x1c3380
movl %eax, %ecx
movl 0x4(%rsp), %eax
cmpl %ecx, %eax
jge 0x1c3201
movq 0x98(%rsp), %rdi
movl 0x30(%rsp), %esi
callq 0x1c3390
movq 0x28(%rsp), %rdi
movq %rax, %rsi
callq 0x1c3280
movl 0x30(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x30(%rsp)
jmp 0x1c319d
movq 0x10(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x38(%rsp)
movl %eax, 0x34(%rsp)
callq 0x8fb70
jmp 0x1c3232
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rcx
addq $0x10, %rcx
movq %rcx, 0x18(%rax)
movq 0x20(%rax), %rcx
addq $0x8, %rcx
movq %rcx, 0x20(%rax)
movq 0x8(%rax), %rcx
addq $0x10, %rcx
movq %rcx, 0x8(%rax)
addq $0xa8, %rsp
retq
movq 0x38(%rsp), %rdi
callq 0x90db0
nopl (%rax)
|
_ZN6google8protobuf23AssignDescriptorsHelper23AssignMessageDescriptorEPKNS0_10DescriptorE:
sub rsp, 0A8h
mov [rsp+0A8h+var_8], rdi
mov [rsp+0A8h+var_10], rsi
mov rax, [rsp+0A8h+var_8]
mov [rsp+0A8h+var_80], rax
mov [rsp+0A8h+var_14], 0
loc_1C309F:
mov eax, [rsp+0A8h+var_14]
mov [rsp+0A8h+var_84], eax
mov rdi, [rsp+0A8h+var_10]; this
call _ZNK6google8protobuf10Descriptor17nested_type_countEv; google::protobuf::Descriptor::nested_type_count(void)
mov ecx, eax
mov eax, [rsp+0A8h+var_84]
cmp eax, ecx
jge short loc_1C30F5
mov rdi, [rsp+0A8h+var_10]; this
mov esi, [rsp+0A8h+var_14]; int
call _ZNK6google8protobuf10Descriptor11nested_typeEi; google::protobuf::Descriptor::nested_type(int)
mov rdi, [rsp+0A8h+var_80]; this
mov rsi, rax; google::protobuf::Descriptor *
call _ZN6google8protobuf23AssignDescriptorsHelper23AssignMessageDescriptorEPKNS0_10DescriptorE; google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(google::protobuf::Descriptor const*)
mov eax, [rsp+0A8h+var_14]
add eax, 1
mov [rsp+0A8h+var_14], eax
jmp short loc_1C309F
loc_1C30F5:
mov rax, [rsp+0A8h+var_80]
mov rcx, [rsp+0A8h+var_10]
mov rax, [rax+8]
mov [rax], rcx
mov edi, 60h ; '`'; unsigned __int64
call __Znwm; operator new(ulong)
mov rcx, [rsp+0A8h+var_80]
mov [rsp+0A8h+var_98], rax
mov rax, [rsp+0A8h+var_10]
mov [rsp+0A8h+var_90], rax
mov rax, [rcx+18h]
mov rsi, [rcx+20h]
mov rdx, [rcx+28h]
movups xmm0, xmmword ptr [rax]
movaps [rsp+0A8h+var_68], xmm0
mov rcx, qword ptr [rsp+0A8h+var_68]
mov r8, qword ptr [rsp+0A8h+var_68+8]
lea rdi, [rsp+0A8h+var_58]; this
call _ZN6google8protobuf12_GLOBAL__N_127MigrationToReflectionSchemaEPKPKNS0_7MessageEPKjNS0_8internal15MigrationSchemaE; google::protobuf::`anonymous namespace'::MigrationToReflectionSchema(google::protobuf::Message const* const*,uint const*,google::protobuf::internal::MigrationSchema)
jmp short $+2
loc_1C3154:
call _ZN6google8protobuf14DescriptorPool23internal_generated_poolEv; google::protobuf::DescriptorPool::internal_generated_pool(void)
mov [rsp+0A8h+var_A0], rax
jmp short $+2
loc_1C3160:
mov rcx, [rsp+0A8h+var_A0]; google::protobuf::DescriptorPool *
mov rsi, [rsp+0A8h+var_90]; google::protobuf::Descriptor *
mov rdi, [rsp+0A8h+var_98]; this
mov rax, [rsp+0A8h+var_80]
mov r8, [rax]; google::protobuf::MessageFactory *
lea rdx, [rsp+0A8h+var_58]; google::protobuf::internal::ReflectionSchema *
call _ZN6google8protobuf10ReflectionC2EPKNS0_10DescriptorERKNS0_8internal16ReflectionSchemaEPKNS0_14DescriptorPoolEPNS0_14MessageFactoryE; google::protobuf::Reflection::Reflection(google::protobuf::Descriptor const*,google::protobuf::internal::ReflectionSchema const&,google::protobuf::DescriptorPool const*,google::protobuf::MessageFactory *)
jmp short $+2
loc_1C3183:
mov rcx, [rsp+0A8h+var_98]
mov rax, [rsp+0A8h+var_80]
mov rax, [rax+8]
mov [rax+8], rcx
mov [rsp+0A8h+var_78], 0
loc_1C319D:
mov eax, [rsp+0A8h+var_78]
mov [rsp+0A8h+var_A4], eax
mov rdi, [rsp+0A8h+var_10]; this
call _ZNK6google8protobuf10Descriptor15enum_type_countEv; google::protobuf::Descriptor::enum_type_count(void)
mov ecx, eax
mov eax, [rsp+0A8h+var_A4]
cmp eax, ecx
jge short loc_1C3201
mov rdi, [rsp+0A8h+var_10]; this
mov esi, [rsp+0A8h+var_78]; int
call _ZNK6google8protobuf10Descriptor9enum_typeEi; google::protobuf::Descriptor::enum_type(int)
mov rdi, [rsp+0A8h+var_80]
mov rsi, rax
call _ZN6google8protobuf23AssignDescriptorsHelper20AssignEnumDescriptorEPKNS0_14EnumDescriptorE; google::protobuf::AssignDescriptorsHelper::AssignEnumDescriptor(google::protobuf::EnumDescriptor const*)
mov eax, [rsp+0A8h+var_78]
add eax, 1
mov [rsp+0A8h+var_78], eax
jmp short loc_1C319D
mov rdi, [rsp+arg_8]; void *
mov rcx, rax
mov eax, edx
mov [rsp+arg_30], rcx
mov [rsp+arg_2C], eax
call __ZdlPv; operator delete(void *)
jmp short loc_1C3232
loc_1C3201:
mov rax, [rsp+0A8h+var_80]
mov rcx, [rax+18h]
add rcx, 10h
mov [rax+18h], rcx
mov rcx, [rax+20h]
add rcx, 8
mov [rax+20h], rcx
mov rcx, [rax+8]
add rcx, 10h
mov [rax+8], rcx
add rsp, 0A8h
retn
loc_1C3232:
mov rdi, [rsp+arg_30]
call __Unwind_Resume
|
google::protobuf::AssignDescriptorsHelper * google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(
google::protobuf::AssignDescriptorsHelper *this,
const google::protobuf::Descriptor *a2)
{
const google::protobuf::Descriptor *v2; // rax
const google::protobuf::EnumDescriptor *v3; // rax
google::protobuf::AssignDescriptorsHelper *result; // rax
google::protobuf::DescriptorPool *v5; // [rsp+8h] [rbp-A0h]
google::protobuf::Reflection *v6; // [rsp+10h] [rbp-98h]
const google::protobuf::Descriptor *v7; // [rsp+18h] [rbp-90h]
int j; // [rsp+30h] [rbp-78h]
_BYTE v9[68]; // [rsp+50h] [rbp-58h] BYREF
int i; // [rsp+94h] [rbp-14h]
google::protobuf::Descriptor *v11; // [rsp+98h] [rbp-10h]
google::protobuf::AssignDescriptorsHelper *v12; // [rsp+A0h] [rbp-8h]
v12 = this;
v11 = a2;
for ( i = 0; i < (int)google::protobuf::Descriptor::nested_type_count(v11); ++i )
{
v2 = (const google::protobuf::Descriptor *)google::protobuf::Descriptor::nested_type(v11, i);
google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(this, v2);
}
**((_QWORD **)this + 1) = v11;
v6 = (google::protobuf::Reflection *)operator new(0x60uLL);
v7 = v11;
google::protobuf::`anonymous namespace'::MigrationToReflectionSchema(
(long long)v9,
*((_QWORD **)this + 4),
*((_QWORD *)this + 5),
**((_QWORD **)this + 3),
*(_QWORD *)(*((_QWORD *)this + 3) + 8LL));
v5 = (google::protobuf::DescriptorPool *)google::protobuf::DescriptorPool::internal_generated_pool((google::protobuf::DescriptorPool *)v9);
google::protobuf::Reflection::Reflection(
v6,
v7,
(const google::protobuf::internal::ReflectionSchema *)v9,
v5,
*(google::protobuf::MessageFactory **)this);
*(_QWORD *)(*((_QWORD *)this + 1) + 8LL) = v6;
for ( j = 0; j < (int)google::protobuf::Descriptor::enum_type_count(v11); ++j )
{
v3 = (const google::protobuf::EnumDescriptor *)google::protobuf::Descriptor::enum_type(v11, j);
google::protobuf::AssignDescriptorsHelper::AssignEnumDescriptor(this, v3);
}
result = this;
*((_QWORD *)this + 3) += 16LL;
*((_QWORD *)this + 4) += 8LL;
*((_QWORD *)this + 1) += 16LL;
return result;
}
| |||
7,873 |
google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(google::protobuf::Descriptor const*)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/generated_message_reflection.cc
|
void AssignMessageDescriptor(const Descriptor* descriptor) {
for (int i = 0; i < descriptor->nested_type_count(); i++) {
AssignMessageDescriptor(descriptor->nested_type(i));
}
file_level_metadata_->descriptor = descriptor;
file_level_metadata_->reflection =
new Reflection(descriptor,
MigrationToReflectionSchema(default_instance_data_,
offsets_, *schemas_),
DescriptorPool::internal_generated_pool(), factory_);
for (int i = 0; i < descriptor->enum_type_count(); i++) {
AssignEnumDescriptor(descriptor->enum_type(i));
}
schemas_++;
default_instance_data_++;
file_level_metadata_++;
}
|
O3
|
cpp
|
google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(google::protobuf::Descriptor const*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movq %rdi, %rbx
cmpl $0x0, 0x70(%rsi)
jle 0x980f4
xorl %r15d, %r15d
xorl %r12d, %r12d
movq 0x38(%r14), %rsi
addq %r15, %rsi
movq %rbx, %rdi
callq 0x980b2
incq %r12
movslq 0x70(%r14), %rax
addq $0x88, %r15
cmpq %rax, %r12
jl 0x980d2
movq 0x8(%rbx), %rax
movq %r14, (%rax)
movl $0x60, %edi
callq 0x2d270
movq %rax, %r15
movq 0x18(%rbx), %rax
movq 0x20(%rbx), %rcx
movq 0x28(%rbx), %rbp
movq (%rax), %r13
movq 0x8(%rax), %rax
movq %rax, 0x20(%rsp)
movq (%rcx), %rax
movq %rax, 0x18(%rsp)
movq %r13, %r12
shlq $0x20, %r12
movabsq $0x100000000, %rax # imm = 0x100000000
addq %r12, %rax
movabsq $0x200000000, %rcx # imm = 0x200000000
addq %r12, %rcx
movabsq $0x300000000, %rdx # imm = 0x300000000
addq %r12, %rdx
movabsq $0x400000000, %rsi # imm = 0x400000000
addq %r12, %rsi
movabsq $0x500000000, %rdi # imm = 0x500000000
addq %r12, %rdi
sarq $0x1e, %r12
movl (%rbp,%r12), %r8d
movl %r8d, 0x14(%rsp)
sarq $0x1e, %rax
movl (%rbp,%rax), %eax
movl %eax, 0x10(%rsp)
sarq $0x1e, %rcx
movl (%rbp,%rcx), %eax
movl %eax, 0xc(%rsp)
sarq $0x1e, %rdx
movl (%rbp,%rdx), %eax
movl %eax, 0x4(%rsp)
sarq $0x1e, %rsi
movl (%rbp,%rsi), %eax
movl %eax, 0x8(%rsp)
sarq $0x1e, %rdi
movl (%rbp,%rdi), %eax
movl %eax, (%rsp)
callq 0xc0306
addq %rbp, %r12
movq 0x20(%rsp), %rsi
movslq %esi, %rcx
leaq (,%rcx,4), %rcx
addq %rbp, %rcx
sarq $0x20, %r13
leaq (,%r13,4), %rdx
addq %rbp, %rdx
movq (%rbx), %r13
movq %r14, (%r15)
movq 0x18(%rsp), %rdi
movq %rdi, 0x8(%r15)
addq $0x18, %r12
movq %r12, 0x10(%r15)
movq %rdx, 0x18(%r15)
movl 0x14(%rsp), %edx
movl %edx, 0x20(%r15)
movl 0x10(%rsp), %edx
movl %edx, 0x24(%r15)
movl 0xc(%rsp), %edx
movl %edx, 0x28(%r15)
movl 0x4(%rsp), %edx
movl %edx, 0x2c(%r15)
shrq $0x20, %rsi
movl %esi, 0x30(%r15)
movl 0x8(%rsp), %edx
movl %edx, 0x34(%r15)
movq %rcx, 0x38(%r15)
movl (%rsp), %ecx
movl %ecx, 0x40(%r15)
movq %r14, %rcx
testq %rax, %rax
jne 0x98249
callq 0xc0306
movq (%r15), %rcx
movq %rax, 0x48(%r15)
movq %r13, 0x50(%r15)
movl 0x4(%rcx), %eax
decl %eax
movl %eax, 0x58(%r15)
movq 0x8(%rbx), %rax
movq %r15, 0x8(%rax)
movslq 0x74(%r14), %rcx
testq %rcx, %rcx
jle 0x9829c
movq 0x10(%rbx), %rax
shlq $0x3, %rcx
leaq (%rcx,%rcx,8), %rcx
xorl %edx, %edx
movq 0x40(%r14), %rsi
addq %rdx, %rsi
movq %rsi, (%rax)
movq 0x10(%rbx), %rax
addq $0x8, %rax
movq %rax, 0x10(%rbx)
addq $0x48, %rdx
cmpq %rdx, %rcx
jne 0x98279
movq 0x8(%rbx), %rax
movdqu 0x18(%rbx), %xmm0
paddq 0xd0087(%rip), %xmm0 # 0x168330
movdqu %xmm0, 0x18(%rbx)
addq $0x10, %rax
movq %rax, 0x8(%rbx)
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq %r15, %rdi
callq 0x2d160
movq %rbx, %rdi
callq 0x2e220
|
_ZN6google8protobuf23AssignDescriptorsHelper23AssignMessageDescriptorEPKNS0_10DescriptorE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r14, rsi
mov rbx, rdi
cmp dword ptr [rsi+70h], 0
jle short loc_980F4
xor r15d, r15d
xor r12d, r12d
loc_980D2:
mov rsi, [r14+38h]
add rsi, r15; google::protobuf::Descriptor *
mov rdi, rbx; this
call _ZN6google8protobuf23AssignDescriptorsHelper23AssignMessageDescriptorEPKNS0_10DescriptorE; google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(google::protobuf::Descriptor const*)
inc r12
movsxd rax, dword ptr [r14+70h]
add r15, 88h
cmp r12, rax
jl short loc_980D2
loc_980F4:
mov rax, [rbx+8]
mov [rax], r14
mov edi, 60h ; '`'; unsigned __int64
call __Znwm; operator new(ulong)
mov r15, rax
mov rax, [rbx+18h]
mov rcx, [rbx+20h]
mov rbp, [rbx+28h]
mov r13, [rax]
mov rax, [rax+8]
mov [rsp+58h+var_38], rax
mov rax, [rcx]
mov [rsp+58h+var_40], rax
mov r12, r13
shl r12, 20h
mov rax, 100000000h
add rax, r12
mov rcx, 200000000h
add rcx, r12
mov rdx, 300000000h
add rdx, r12
mov rsi, 400000000h
add rsi, r12
mov rdi, 500000000h
add rdi, r12
sar r12, 1Eh
mov r8d, [rbp+r12+0]
mov [rsp+58h+var_44], r8d
sar rax, 1Eh
mov eax, [rbp+rax+0]
mov [rsp+58h+var_48], eax
sar rcx, 1Eh
mov eax, [rbp+rcx+0]
mov [rsp+58h+var_4C], eax
sar rdx, 1Eh
mov eax, [rbp+rdx+0]
mov [rsp+58h+var_54], eax
sar rsi, 1Eh
mov eax, [rbp+rsi+0]
mov [rsp+58h+var_50], eax
sar rdi, 1Eh; this
mov eax, [rbp+rdi+0]
mov [rsp+58h+var_58], eax
call _ZN6google8protobuf14DescriptorPool23internal_generated_poolEv; google::protobuf::DescriptorPool::internal_generated_pool(void)
add r12, rbp
mov rsi, [rsp+58h+var_38]
movsxd rcx, esi
lea rcx, ds:0[rcx*4]
add rcx, rbp
sar r13, 20h
lea rdx, ds:0[r13*4]
add rdx, rbp
mov r13, [rbx]
mov [r15], r14
mov rdi, [rsp+58h+var_40]; this
mov [r15+8], rdi
add r12, 18h
mov [r15+10h], r12
mov [r15+18h], rdx
mov edx, [rsp+58h+var_44]
mov [r15+20h], edx
mov edx, [rsp+58h+var_48]
mov [r15+24h], edx
mov edx, [rsp+58h+var_4C]
mov [r15+28h], edx
mov edx, [rsp+58h+var_54]
mov [r15+2Ch], edx
shr rsi, 20h
mov [r15+30h], esi
mov edx, [rsp+58h+var_50]
mov [r15+34h], edx
mov [r15+38h], rcx
mov ecx, [rsp+58h+var_58]
mov [r15+40h], ecx
mov rcx, r14
test rax, rax
jnz short loc_98249
call _ZN6google8protobuf14DescriptorPool23internal_generated_poolEv; google::protobuf::DescriptorPool::internal_generated_pool(void)
mov rcx, [r15]
loc_98249:
mov [r15+48h], rax
mov [r15+50h], r13
mov eax, [rcx+4]
dec eax
mov [r15+58h], eax
mov rax, [rbx+8]
mov [rax+8], r15
movsxd rcx, dword ptr [r14+74h]
test rcx, rcx
jle short loc_9829C
mov rax, [rbx+10h]
shl rcx, 3
lea rcx, [rcx+rcx*8]
xor edx, edx
loc_98279:
mov rsi, [r14+40h]
add rsi, rdx
mov [rax], rsi
mov rax, [rbx+10h]
add rax, 8
mov [rbx+10h], rax
add rdx, 48h ; 'H'
cmp rcx, rdx
jnz short loc_98279
mov rax, [rbx+8]
loc_9829C:
movdqu xmm0, xmmword ptr [rbx+18h]
paddq xmm0, cs:xmmword_168330
movdqu xmmword ptr [rbx+18h], xmm0
add rax, 10h
mov [rbx+8], rax
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
mov rdi, r15; void *
call __ZdlPv; operator delete(void *)
mov rdi, rbx
call __Unwind_Resume
|
long long google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(
google::protobuf::AssignDescriptorsHelper *this,
const google::protobuf::Descriptor *a2)
{
long long v3; // r15
long long v4; // r12
long long v5; // r15
long long *v6; // rax
long long v7; // rbp
long long v8; // r13
long long v9; // r12
long long v10; // rdi
long long v11; // rax
long long v12; // rdx
long long v13; // r13
const google::protobuf::Descriptor *v14; // rcx
long long v15; // rax
long long v16; // rcx
_QWORD *v17; // rax
long long v18; // rcx
long long v19; // rdx
long long result; // rax
int v21; // [rsp+0h] [rbp-58h]
int v22; // [rsp+4h] [rbp-54h]
int v23; // [rsp+8h] [rbp-50h]
int v24; // [rsp+Ch] [rbp-4Ch]
int v25; // [rsp+10h] [rbp-48h]
int v26; // [rsp+14h] [rbp-44h]
google::protobuf::DescriptorPool *v27; // [rsp+18h] [rbp-40h]
long long v28; // [rsp+20h] [rbp-38h]
if ( *((int *)a2 + 28) > 0 )
{
v3 = 0LL;
v4 = 0LL;
do
{
google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(
this,
(const google::protobuf::Descriptor *)(v3 + *((_QWORD *)a2 + 7)));
++v4;
v3 += 136LL;
}
while ( v4 < *((int *)a2 + 28) );
}
**((_QWORD **)this + 1) = a2;
v5 = operator new(0x60uLL);
v6 = (long long *)*((_QWORD *)this + 3);
v7 = *((_QWORD *)this + 5);
v8 = *v6;
v28 = v6[1];
v27 = (google::protobuf::DescriptorPool *)**((_QWORD **)this + 4);
v9 = 4LL * (int)*v6;
v26 = *(_DWORD *)(v7 + v9);
v25 = *(_DWORD *)(v7 + (((*v6 << 32) + 0x100000000LL) >> 30));
v24 = *(_DWORD *)(v7 + (((*v6 << 32) + 0x200000000LL) >> 30));
v22 = *(_DWORD *)(v7 + (((*v6 << 32) + 0x300000000LL) >> 30));
v23 = *(_DWORD *)(v7 + (((*v6 << 32) + 0x400000000LL) >> 30));
v10 = ((*v6 << 32) + 0x500000000LL) >> 30;
v21 = *(_DWORD *)(v7 + v10);
v11 = google::protobuf::DescriptorPool::internal_generated_pool((google::protobuf::DescriptorPool *)v10);
v12 = v7 + 4 * (v8 >> 32);
v13 = *(_QWORD *)this;
*(_QWORD *)v5 = a2;
*(_QWORD *)(v5 + 8) = v27;
*(_QWORD *)(v5 + 16) = v7 + v9 + 24;
*(_QWORD *)(v5 + 24) = v12;
*(_DWORD *)(v5 + 32) = v26;
*(_DWORD *)(v5 + 36) = v25;
*(_DWORD *)(v5 + 40) = v24;
*(_DWORD *)(v5 + 44) = v22;
*(_DWORD *)(v5 + 48) = HIDWORD(v28);
*(_DWORD *)(v5 + 52) = v23;
*(_QWORD *)(v5 + 56) = v7 + 4LL * (int)v28;
*(_DWORD *)(v5 + 64) = v21;
v14 = a2;
if ( !v11 )
{
v11 = google::protobuf::DescriptorPool::internal_generated_pool(v27);
v14 = *(const google::protobuf::Descriptor **)v5;
}
*(_QWORD *)(v5 + 72) = v11;
*(_QWORD *)(v5 + 80) = v13;
*(_DWORD *)(v5 + 88) = *((_DWORD *)v14 + 1) - 1;
v15 = *((_QWORD *)this + 1);
*(_QWORD *)(v15 + 8) = v5;
v16 = *((int *)a2 + 29);
if ( v16 > 0 )
{
v17 = (_QWORD *)*((_QWORD *)this + 2);
v18 = 72 * v16;
v19 = 0LL;
do
{
*v17 = v19 + *((_QWORD *)a2 + 8);
v17 = (_QWORD *)(*((_QWORD *)this + 2) + 8LL);
*((_QWORD *)this + 2) = v17;
v19 += 72LL;
}
while ( v18 != v19 );
v15 = *((_QWORD *)this + 1);
}
*(__m128i *)((char *)this + 24) = _mm_add_epi64(
_mm_loadu_si128((const __m128i *)((char *)this + 24)),
(__m128i)xmmword_168330);
result = v15 + 16;
*((_QWORD *)this + 1) = result;
return result;
}
|
AssignMessageDescriptor:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R14,RSI
MOV RBX,RDI
CMP dword ptr [RSI + 0x70],0x0
JLE 0x001980f4
XOR R15D,R15D
XOR R12D,R12D
LAB_001980d2:
MOV RSI,qword ptr [R14 + 0x38]
ADD RSI,R15
MOV RDI,RBX
CALL 0x001980b2
INC R12
MOVSXD RAX,dword ptr [R14 + 0x70]
ADD R15,0x88
CMP R12,RAX
JL 0x001980d2
LAB_001980f4:
MOV RAX,qword ptr [RBX + 0x8]
MOV qword ptr [RAX],R14
MOV EDI,0x60
CALL 0x0012d270
MOV R15,RAX
MOV RAX,qword ptr [RBX + 0x18]
MOV RCX,qword ptr [RBX + 0x20]
MOV RBP,qword ptr [RBX + 0x28]
MOV R13,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x20],RAX
MOV RAX,qword ptr [RCX]
MOV qword ptr [RSP + 0x18],RAX
MOV R12,R13
SHL R12,0x20
MOV RAX,0x100000000
ADD RAX,R12
MOV RCX,0x200000000
ADD RCX,R12
MOV RDX,0x300000000
ADD RDX,R12
MOV RSI,0x400000000
ADD RSI,R12
MOV RDI,0x500000000
ADD RDI,R12
SAR R12,0x1e
MOV R8D,dword ptr [RBP + R12*0x1]
MOV dword ptr [RSP + 0x14],R8D
SAR RAX,0x1e
MOV EAX,dword ptr [RBP + RAX*0x1]
MOV dword ptr [RSP + 0x10],EAX
SAR RCX,0x1e
MOV EAX,dword ptr [RBP + RCX*0x1]
MOV dword ptr [RSP + 0xc],EAX
SAR RDX,0x1e
MOV EAX,dword ptr [RBP + RDX*0x1]
MOV dword ptr [RSP + 0x4],EAX
SAR RSI,0x1e
MOV EAX,dword ptr [RBP + RSI*0x1]
MOV dword ptr [RSP + 0x8],EAX
SAR RDI,0x1e
MOV EAX,dword ptr [RBP + RDI*0x1]
MOV dword ptr [RSP],EAX
LAB_001981b9:
CALL 0x001c0306
ADD R12,RBP
MOV RSI,qword ptr [RSP + 0x20]
MOVSXD RCX,ESI
LEA RCX,[RCX*0x4]
ADD RCX,RBP
SAR R13,0x20
LEA RDX,[R13*0x4]
ADD RDX,RBP
MOV R13,qword ptr [RBX]
MOV qword ptr [R15],R14
MOV RDI,qword ptr [RSP + 0x18]
MOV qword ptr [R15 + 0x8],RDI
ADD R12,0x18
MOV qword ptr [R15 + 0x10],R12
MOV qword ptr [R15 + 0x18],RDX
MOV EDX,dword ptr [RSP + 0x14]
MOV dword ptr [R15 + 0x20],EDX
MOV EDX,dword ptr [RSP + 0x10]
MOV dword ptr [R15 + 0x24],EDX
MOV EDX,dword ptr [RSP + 0xc]
MOV dword ptr [R15 + 0x28],EDX
MOV EDX,dword ptr [RSP + 0x4]
MOV dword ptr [R15 + 0x2c],EDX
SHR RSI,0x20
MOV dword ptr [R15 + 0x30],ESI
MOV EDX,dword ptr [RSP + 0x8]
MOV dword ptr [R15 + 0x34],EDX
MOV qword ptr [R15 + 0x38],RCX
MOV ECX,dword ptr [RSP]
MOV dword ptr [R15 + 0x40],ECX
MOV RCX,R14
TEST RAX,RAX
JNZ 0x00198249
CALL 0x001c0306
LAB_00198246:
MOV RCX,qword ptr [R15]
LAB_00198249:
MOV qword ptr [R15 + 0x48],RAX
MOV qword ptr [R15 + 0x50],R13
MOV EAX,dword ptr [RCX + 0x4]
DEC EAX
MOV dword ptr [R15 + 0x58],EAX
MOV RAX,qword ptr [RBX + 0x8]
MOV qword ptr [RAX + 0x8],R15
MOVSXD RCX,dword ptr [R14 + 0x74]
TEST RCX,RCX
JLE 0x0019829c
MOV RAX,qword ptr [RBX + 0x10]
SHL RCX,0x3
LEA RCX,[RCX + RCX*0x8]
XOR EDX,EDX
LAB_00198279:
MOV RSI,qword ptr [R14 + 0x40]
ADD RSI,RDX
MOV qword ptr [RAX],RSI
MOV RAX,qword ptr [RBX + 0x10]
ADD RAX,0x8
MOV qword ptr [RBX + 0x10],RAX
ADD RDX,0x48
CMP RCX,RDX
JNZ 0x00198279
MOV RAX,qword ptr [RBX + 0x8]
LAB_0019829c:
MOVDQU XMM0,xmmword ptr [RBX + 0x18]
PADDQ XMM0,xmmword ptr [0x00268330]
MOVDQU xmmword ptr [RBX + 0x18],XMM0
ADD RAX,0x10
MOV qword ptr [RBX + 0x8],RAX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor(google::protobuf::Descriptor
const*) */
void __thiscall
google::protobuf::AssignDescriptorsHelper::AssignMessageDescriptor
(AssignDescriptorsHelper *this,Descriptor *param_1)
{
int4 uVar1;
int4 uVar2;
int4 uVar3;
int4 uVar4;
int4 uVar5;
int4 uVar6;
int iVar7;
long lVar8;
long lVar9;
long lVar10;
long *plVar11;
long lVar12;
Descriptor *pDVar13;
long lVar14;
long lVar15;
long lVar16;
if (0 < *(int *)(param_1 + 0x70)) {
lVar16 = 0;
lVar14 = 0;
do {
AssignMessageDescriptor(this,(Descriptor *)(*(long *)(param_1 + 0x38) + lVar16));
lVar14 = lVar14 + 1;
lVar16 = lVar16 + 0x88;
} while (lVar14 < *(int *)(param_1 + 0x70));
}
**(int8 **)(this + 8) = param_1;
plVar11 = (long *)operator_new(0x60);
lVar14 = *(long *)(this + 0x28);
lVar16 = **(long **)(this + 0x18);
lVar8 = (*(long **)(this + 0x18))[1];
lVar9 = **(long **)(this + 0x20);
lVar15 = lVar16 << 0x20;
uVar1 = *(int4 *)(lVar14 + (lVar15 >> 0x1e));
uVar2 = *(int4 *)(lVar14 + (lVar15 + 0x100000000 >> 0x1e));
uVar3 = *(int4 *)(lVar14 + (lVar15 + 0x200000000 >> 0x1e));
uVar4 = *(int4 *)(lVar14 + (lVar15 + 0x300000000 >> 0x1e));
uVar5 = *(int4 *)(lVar14 + (lVar15 + 0x400000000 >> 0x1e));
uVar6 = *(int4 *)(lVar14 + (lVar15 + 0x500000000 >> 0x1e));
/* try { // try from 001981b9 to 00198245 has its CatchHandler @ 001982c5 */
lVar12 = DescriptorPool::internal_generated_pool();
lVar10 = *(long *)this;
*plVar11 = (long)param_1;
plVar11[1] = lVar9;
plVar11[2] = (lVar15 >> 0x1e) + lVar14 + 0x18;
plVar11[3] = (lVar16 >> 0x20) * 4 + lVar14;
*(int4 *)(plVar11 + 4) = uVar1;
*(int4 *)((long)plVar11 + 0x24) = uVar2;
*(int4 *)(plVar11 + 5) = uVar3;
*(int4 *)((long)plVar11 + 0x2c) = uVar4;
*(int *)(plVar11 + 6) = (int)((ulong)lVar8 >> 0x20);
*(int4 *)((long)plVar11 + 0x34) = uVar5;
plVar11[7] = (long)(int)lVar8 * 4 + lVar14;
*(int4 *)(plVar11 + 8) = uVar6;
pDVar13 = param_1;
if (lVar12 == 0) {
lVar12 = DescriptorPool::internal_generated_pool();
pDVar13 = (Descriptor *)*plVar11;
}
plVar11[9] = lVar12;
plVar11[10] = lVar10;
*(int *)(plVar11 + 0xb) = *(int *)(pDVar13 + 4) + -1;
lVar14 = *(long *)(this + 8);
*(long **)(lVar14 + 8) = plVar11;
iVar7 = *(int *)(param_1 + 0x74);
if (0 < (long)iVar7) {
plVar11 = *(long **)(this + 0x10);
lVar14 = 0;
do {
*plVar11 = *(long *)(param_1 + 0x40) + lVar14;
plVar11 = (long *)(*(long *)(this + 0x10) + 8);
*(long **)(this + 0x10) = plVar11;
lVar14 = lVar14 + 0x48;
} while ((long)iVar7 * 0x48 != lVar14);
lVar14 = *(long *)(this + 8);
}
lVar16 = *(long *)(this + 0x20) + _UNK_00268338;
*(long *)(this + 0x18) = *(long *)(this + 0x18) + _DAT_00268330;
*(long *)(this + 0x20) = lVar16;
*(long *)(this + 8) = lVar14 + 0x10;
return;
}
|
|
7,874 |
MainWindow::MainWindow(QWidget*)
|
LeafBlue[P]myElevetor/mainwindow.cpp
|
MainWindow::MainWindow(QWidget *parent)
: QMainWindow(parent),ele_A(),ele_B()
{
ele_A.up_out = ele_B.up_out = new QVector<int>();
ele_A.down_out = ele_B.down_out = new QVector<int>();
ele_A.outbtn_up = ele_B.outbtn_up = new QMap<int,QPushButton*>();
ele_A.outbtn_down = ele_B.outbtn_down = new QMap<int,QPushButton*>();
move_v = 16;//假设60像素需1000毫秒
setWindow();
setcenter();
//接收信号
connect(&ele_A,&Elevetor::send_update,this,&MainWindow::update_endstair);
connect(&ele_B,&Elevetor::send_update,this,&MainWindow::update_endstair);
}
|
O0
|
cpp
|
MainWindow::MainWindow(QWidget*):
pushq %rbp
movq %rsp, %rbp
subq $0xe0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x88(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0xa0(%rbp)
leaq -0x14(%rbp), %rdi
callq 0xcb20
movq -0xa0(%rbp), %rsi
movq -0x88(%rbp), %rdi
movl -0x14(%rbp), %edx
callq 0x50f0
movq -0x88(%rbp), %rdi
leaq 0x19cea(%rip), %rax # 0x1faf0
movq %rax, %rcx
addq $0x10, %rcx
movq %rcx, (%rdi)
addq $0x1c8, %rax # imm = 0x1C8
movq %rax, 0x10(%rdi)
addq $0x28, %rdi
movq %rdi, -0x98(%rbp)
callq 0xcb40
movq -0x88(%rbp), %rdi
addq $0x40, %rdi
movq %rdi, -0x90(%rbp)
callq 0xcb40
movq -0x88(%rbp), %rdi
addq $0x58, %rdi
movq %rdi, -0x80(%rbp)
xorl %eax, %eax
movl %eax, %esi
callq 0x11b10
jmp 0x5e5b
movq -0x88(%rbp), %rdi
addq $0xf8, %rdi
movq %rdi, -0xa8(%rbp)
xorl %eax, %eax
movl %eax, %esi
callq 0x11b10
jmp 0x5e7b
movl $0x18, %edi
callq 0x53a0
movq %rax, -0xb0(%rbp)
jmp 0x5e8e
movq -0xb0(%rbp), %rdi
xorps %xmm0, %xmm0
movaps %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
callq 0xcb40
movq -0xb0(%rbp), %rcx
movq -0x88(%rbp), %rax
movq %rcx, 0x108(%rax)
movq %rcx, 0x68(%rax)
movl $0x18, %edi
callq 0x53a0
movq %rax, -0xb8(%rbp)
jmp 0x5ed4
movq -0xb8(%rbp), %rdi
xorps %xmm0, %xmm0
movaps %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
callq 0xcb40
movq -0xb8(%rbp), %rcx
movq -0x88(%rbp), %rax
movq %rcx, 0x110(%rax)
movq %rcx, 0x70(%rax)
movl $0x8, %edi
callq 0x53a0
movq %rax, -0xc0(%rbp)
jmp 0x5f1a
movq -0xc0(%rbp), %rdi
movq $0x0, (%rdi)
callq 0xcb60
movq -0xc0(%rbp), %rcx
movq -0x88(%rbp), %rax
movq %rcx, 0x120(%rax)
movq %rcx, 0x80(%rax)
movl $0x8, %edi
callq 0x53a0
movq %rax, -0xc8(%rbp)
jmp 0x5f5c
movq -0xc8(%rbp), %rdi
movq $0x0, (%rdi)
callq 0xcb60
movq -0xc8(%rbp), %rax
movq -0x88(%rbp), %rdi
movq %rax, 0x128(%rdi)
movq %rax, 0x88(%rdi)
movl $0x10, 0x198(%rdi)
callq 0x60e0
jmp 0x5f9c
movq -0x88(%rbp), %rdi
callq 0x6110
jmp 0x5faa
movq -0x88(%rbp), %r8
movq %r8, %rsi
addq $0x58, %rsi
leaq -0x84f(%rip), %rax # 0x5770
movq %rax, -0x40(%rbp)
movq $0x0, -0x38(%rbp)
movq -0x40(%rbp), %rdx
movq -0x38(%rbp), %rcx
leaq 0x316(%rip), %rax # 0x62f0
movq %rax, -0x50(%rbp)
movq $0x0, -0x48(%rbp)
movups -0x50(%rbp), %xmm0
movq %rsp, %rax
movups %xmm0, (%rax)
leaq -0x30(%rbp), %rdi
xorl %r9d, %r9d
callq 0xcb80
jmp 0x5ffe
leaq -0x30(%rbp), %rdi
callq 0x51d0
movq -0x88(%rbp), %r8
movq %r8, %rsi
addq $0xf8, %rsi
leaq -0x8af(%rip), %rax # 0x5770
movq %rax, -0x68(%rbp)
movq $0x0, -0x60(%rbp)
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
leaq 0x2b6(%rip), %rax # 0x62f0
movq %rax, -0x78(%rbp)
movq $0x0, -0x70(%rbp)
movups -0x78(%rbp), %xmm0
movq %rsp, %rax
movups %xmm0, (%rax)
leaq -0x58(%rbp), %rdi
xorl %r9d, %r9d
callq 0xcb80
jmp 0x605e
leaq -0x58(%rbp), %rdi
callq 0x51d0
addq $0xe0, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x60ad
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x60a4
movq -0xa8(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
callq 0x11a30
movq -0x80(%rbp), %rdi
callq 0x11a30
movq -0x90(%rbp), %rdi
callq 0xccd0
movq -0x98(%rbp), %rdi
callq 0xccd0
movq -0x88(%rbp), %rdi
callq 0x5240
movq -0x20(%rbp), %rdi
callq 0x51e0
nopw (%rax,%rax)
|
_ZN10MainWindowC2EP7QWidget:
push rbp; Alternative name is 'MainWindow::MainWindow(QWidget *)'
mov rbp, rsp
sub rsp, 0E0h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_8]
mov [rbp+var_88], rax
mov rax, [rbp+var_10]
mov [rbp+var_A0], rax
lea rdi, [rbp+var_14]
call _ZN6QFlagsIN2Qt10WindowTypeEEC2Ev; QFlags<Qt::WindowType>::QFlags(void)
mov rsi, [rbp+var_A0]
mov rdi, [rbp+var_88]
mov edx, [rbp+var_14]
call __ZN11QMainWindowC2EP7QWidget6QFlagsIN2Qt10WindowTypeEE; QMainWindow::QMainWindow(QWidget *,QFlags<Qt::WindowType>)
mov rdi, [rbp+var_88]
lea rax, _ZTV10MainWindow; `vtable for'MainWindow
mov rcx, rax
add rcx, 10h
mov [rdi], rcx
add rax, 1C8h
mov [rdi+10h], rax
add rdi, 28h ; '('
mov [rbp+var_98], rdi
call _ZN5QListIiEC2Ev; QList<int>::QList(void)
mov rdi, [rbp+var_88]
add rdi, 40h ; '@'
mov [rbp+var_90], rdi
call _ZN5QListIiEC2Ev; QList<int>::QList(void)
mov rdi, [rbp+var_88]
add rdi, 58h ; 'X'; this
mov [rbp+var_80], rdi
xor eax, eax
mov esi, eax; QObject *
call _ZN8ElevetorC2EP7QObject; Elevetor::Elevetor(QObject *)
jmp short $+2
loc_5E5B:
mov rdi, [rbp+var_88]
add rdi, 0F8h; this
mov [rbp+var_A8], rdi
xor eax, eax
mov esi, eax; QObject *
call _ZN8ElevetorC2EP7QObject; Elevetor::Elevetor(QObject *)
jmp short $+2
loc_5E7B:
mov edi, 18h; unsigned __int64
call __Znwm; operator new(ulong)
mov [rbp+var_B0], rax
jmp short $+2
loc_5E8E:
mov rdi, [rbp+var_B0]
xorps xmm0, xmm0
movaps xmmword ptr [rdi], xmm0
mov qword ptr [rdi+10h], 0
call _ZN5QListIiEC2Ev; QList<int>::QList(void)
mov rcx, [rbp+var_B0]
mov rax, [rbp+var_88]
mov [rax+108h], rcx
mov [rax+68h], rcx
mov edi, 18h; unsigned __int64
call __Znwm; operator new(ulong)
mov [rbp+var_B8], rax
jmp short $+2
loc_5ED4:
mov rdi, [rbp+var_B8]
xorps xmm0, xmm0
movaps xmmword ptr [rdi], xmm0
mov qword ptr [rdi+10h], 0
call _ZN5QListIiEC2Ev; QList<int>::QList(void)
mov rcx, [rbp+var_B8]
mov rax, [rbp+var_88]
mov [rax+110h], rcx
mov [rax+70h], rcx
mov edi, 8; unsigned __int64
call __Znwm; operator new(ulong)
mov [rbp+var_C0], rax
jmp short $+2
loc_5F1A:
mov rdi, [rbp+var_C0]
mov qword ptr [rdi], 0
call _ZN4QMapIiP11QPushButtonEC2Ev; QMap<int,QPushButton *>::QMap(void)
mov rcx, [rbp+var_C0]
mov rax, [rbp+var_88]
mov [rax+120h], rcx
mov [rax+80h], rcx
mov edi, 8; unsigned __int64
call __Znwm; operator new(ulong)
mov [rbp+var_C8], rax
jmp short $+2
loc_5F5C:
mov rdi, [rbp+var_C8]
mov qword ptr [rdi], 0
call _ZN4QMapIiP11QPushButtonEC2Ev; QMap<int,QPushButton *>::QMap(void)
mov rax, [rbp+var_C8]
mov rdi, [rbp+var_88]; this
mov [rdi+128h], rax
mov [rdi+88h], rax
mov dword ptr [rdi+198h], 10h
call _ZN10MainWindow9setWindowEv; MainWindow::setWindow(void)
jmp short $+2
loc_5F9C:
mov rdi, [rbp+var_88]; this
call _ZN10MainWindow9setcenterEv; MainWindow::setcenter(void)
jmp short $+2
loc_5FAA:
mov r8, [rbp+var_88]
mov rsi, r8
add rsi, 58h ; 'X'
lea rax, _ZN8Elevetor11send_updateERS_; Elevetor::send_update(Elevetor&)
mov [rbp+var_40], rax
mov [rbp+var_38], 0
mov rdx, [rbp+var_40]
mov rcx, [rbp+var_38]
lea rax, _ZN10MainWindow15update_endstairER8Elevetor; MainWindow::update_endstair(Elevetor &)
mov qword ptr [rbp+var_50], rax
mov qword ptr [rbp+var_50+8], 0
movups xmm0, [rbp+var_50]
mov rax, rsp
movups xmmword ptr [rax], xmm0
lea rdi, [rbp+var_30]
xor r9d, r9d
call _ZN7QObject7connectIM8ElevetorFvRS1_EM10MainWindowFvS2_EEEN11QMetaObject10ConnectionEPKN9QtPrivate15FunctionPointerIT_E6ObjectESC_PKNSB_IT0_E6ObjectESH_N2Qt14ConnectionTypeE; QObject::connect<void (Elevetor::*)(Elevetor&),void (MainWindow::*)(Elevetor&)>(QtPrivate::FunctionPointer<void (Elevetor::*)(Elevetor&)>::Object const*,void (Elevetor::*)(Elevetor&),QtPrivate::FunctionPointer<void (MainWindow::*)(Elevetor&)>::Object const*,void (MainWindow::*)(Elevetor&),Qt::ConnectionType)
jmp short $+2
loc_5FFE:
lea rdi, [rbp+var_30]; this
call __ZN11QMetaObject10ConnectionD1Ev; QMetaObject::Connection::~Connection()
mov r8, [rbp+var_88]
mov rsi, r8
add rsi, 0F8h
lea rax, _ZN8Elevetor11send_updateERS_; Elevetor::send_update(Elevetor&)
mov [rbp+var_68], rax
mov [rbp+var_60], 0
mov rdx, [rbp+var_68]
mov rcx, [rbp+var_60]
lea rax, _ZN10MainWindow15update_endstairER8Elevetor; MainWindow::update_endstair(Elevetor &)
mov qword ptr [rbp+var_78], rax
mov qword ptr [rbp+var_78+8], 0
movups xmm0, [rbp+var_78]
mov rax, rsp
movups xmmword ptr [rax], xmm0
lea rdi, [rbp+var_58]
xor r9d, r9d
call _ZN7QObject7connectIM8ElevetorFvRS1_EM10MainWindowFvS2_EEEN11QMetaObject10ConnectionEPKN9QtPrivate15FunctionPointerIT_E6ObjectESC_PKNSB_IT0_E6ObjectESH_N2Qt14ConnectionTypeE; QObject::connect<void (Elevetor::*)(Elevetor&),void (MainWindow::*)(Elevetor&)>(QtPrivate::FunctionPointer<void (Elevetor::*)(Elevetor&)>::Object const*,void (Elevetor::*)(Elevetor&),QtPrivate::FunctionPointer<void (MainWindow::*)(Elevetor&)>::Object const*,void (MainWindow::*)(Elevetor&),Qt::ConnectionType)
jmp short $+2
loc_605E:
lea rdi, [rbp+var_58]; this
call __ZN11QMetaObject10ConnectionD1Ev; QMetaObject::Connection::~Connection()
add rsp, 0E0h
pop rbp
retn
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
jmp short loc_60AD
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
jmp short loc_60A4
mov rdi, [rbp+var_A8]; this
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
call _ZN8ElevetorD2Ev; Elevetor::~Elevetor()
loc_60A4:
mov rdi, [rbp+var_80]; this
call _ZN8ElevetorD2Ev; Elevetor::~Elevetor()
loc_60AD:
mov rdi, [rbp+var_90]
call _ZN5QListIiED2Ev; QList<int>::~QList()
mov rdi, [rbp+var_98]
call _ZN5QListIiED2Ev; QList<int>::~QList()
mov rdi, [rbp+var_88]; this
call __ZN11QMainWindowD2Ev; QMainWindow::~QMainWindow()
mov rdi, [rbp+var_20]
call __Unwind_Resume
|
void MainWindow::MainWindow(MainWindow *this, QWidget *a2)
{
long long v2; // rdi
long long v3; // rdi
_QWORD *v4; // [rsp+18h] [rbp-C8h]
_QWORD *v5; // [rsp+20h] [rbp-C0h]
_BYTE v7[8]; // [rsp+88h] [rbp-58h] BYREF
long long ( *v8)(MainWindow *__hidden, Elevetor *); // [rsp+90h] [rbp-50h]
long long v9; // [rsp+98h] [rbp-48h]
long long ( *v10)(Elevetor *, Elevetor *, long long, long long, void **); // [rsp+A0h] [rbp-40h]
long long v11; // [rsp+A8h] [rbp-38h]
_BYTE v12[12]; // [rsp+B0h] [rbp-30h] BYREF
unsigned int v13; // [rsp+CCh] [rbp-14h] BYREF
QWidget *v14; // [rsp+D0h] [rbp-10h]
MainWindow *v15; // [rsp+D8h] [rbp-8h]
v15 = this;
v14 = a2;
QFlags<Qt::WindowType>::QFlags(&v13);
QMainWindow::QMainWindow(this, a2, v13);
*(_QWORD *)this = &`vtable for'MainWindow + 2;
*((_QWORD *)this + 2) = &`vtable for'MainWindow + 57;
QList<int>::QList();
QList<int>::QList();
Elevetor::Elevetor((MainWindow *)((char *)this + 88), 0LL);
Elevetor::Elevetor((MainWindow *)((char *)this + 248), 0LL);
v2 = operator new(0x18uLL);
*(_OWORD *)v2 = 0LL;
*(_QWORD *)(v2 + 16) = 0LL;
QList<int>::QList();
*((_QWORD *)this + 33) = v2;
*((_QWORD *)this + 13) = v2;
v3 = operator new(0x18uLL);
*(_OWORD *)v3 = 0LL;
*(_QWORD *)(v3 + 16) = 0LL;
QList<int>::QList();
*((_QWORD *)this + 34) = v3;
*((_QWORD *)this + 14) = v3;
v5 = (_QWORD *)operator new(8uLL);
*v5 = 0LL;
QMap<int,QPushButton *>::QMap();
*((_QWORD *)this + 36) = v5;
*((_QWORD *)this + 16) = v5;
v4 = (_QWORD *)operator new(8uLL);
*v4 = 0LL;
QMap<int,QPushButton *>::QMap();
*((_QWORD *)this + 37) = v4;
*((_QWORD *)this + 17) = v4;
*((_DWORD *)this + 102) = 16;
MainWindow::setWindow(this);
MainWindow::setcenter(this);
v10 = Elevetor::send_update;
v11 = 0LL;
v8 = MainWindow::update_endstair;
v9 = 0LL;
QObject::connect<void (Elevetor::*)(Elevetor&),void (MainWindow::*)(Elevetor&)>(
(unsigned int)v12,
(_DWORD)this + 88,
(unsigned int)Elevetor::send_update,
0,
(_DWORD)this,
0,
MainWindow::update_endstair,
0LL);
QMetaObject::Connection::~Connection((QMetaObject::Connection *)v12);
QObject::connect<void (Elevetor::*)(Elevetor&),void (MainWindow::*)(Elevetor&)>(
(unsigned int)v7,
(_DWORD)this + 248,
(unsigned int)Elevetor::send_update,
0,
(_DWORD)this,
0,
MainWindow::update_endstair,
0LL);
QMetaObject::Connection::~Connection((QMetaObject::Connection *)v7);
}
|
MainWindow:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xe0
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x88],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0xa0],RAX
LEA RDI,[RBP + -0x14]
CALL 0x0010cb20
MOV RSI,qword ptr [RBP + -0xa0]
MOV RDI,qword ptr [RBP + -0x88]
MOV EDX,dword ptr [RBP + -0x14]
CALL 0x001050f0
MOV RDI,qword ptr [RBP + -0x88]
LEA RAX,[0x11faf0]
MOV RCX,RAX
ADD RCX,0x10
MOV qword ptr [RDI],RCX
ADD RAX,0x1c8
MOV qword ptr [RDI + 0x10],RAX
ADD RDI,0x28
MOV qword ptr [RBP + -0x98],RDI
CALL 0x0010cb40
MOV RDI,qword ptr [RBP + -0x88]
ADD RDI,0x40
MOV qword ptr [RBP + -0x90],RDI
CALL 0x0010cb40
MOV RDI,qword ptr [RBP + -0x88]
ADD RDI,0x58
MOV qword ptr [RBP + -0x80],RDI
LAB_00105e50:
XOR EAX,EAX
MOV ESI,EAX
CALL 0x00111b10
JMP 0x00105e5b
LAB_00105e5b:
MOV RDI,qword ptr [RBP + -0x88]
ADD RDI,0xf8
MOV qword ptr [RBP + -0xa8],RDI
LAB_00105e70:
XOR EAX,EAX
MOV ESI,EAX
CALL 0x00111b10
JMP 0x00105e7b
LAB_00105e7b:
MOV EDI,0x18
CALL 0x001053a0
MOV qword ptr [RBP + -0xb0],RAX
JMP 0x00105e8e
LAB_00105e8e:
MOV RDI,qword ptr [RBP + -0xb0]
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RDI],XMM0
MOV qword ptr [RDI + 0x10],0x0
CALL 0x0010cb40
MOV RCX,qword ptr [RBP + -0xb0]
MOV RAX,qword ptr [RBP + -0x88]
MOV qword ptr [RAX + 0x108],RCX
MOV qword ptr [RAX + 0x68],RCX
MOV EDI,0x18
CALL 0x001053a0
MOV qword ptr [RBP + -0xb8],RAX
JMP 0x00105ed4
LAB_00105ed4:
MOV RDI,qword ptr [RBP + -0xb8]
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RDI],XMM0
MOV qword ptr [RDI + 0x10],0x0
CALL 0x0010cb40
MOV RCX,qword ptr [RBP + -0xb8]
MOV RAX,qword ptr [RBP + -0x88]
MOV qword ptr [RAX + 0x110],RCX
MOV qword ptr [RAX + 0x70],RCX
MOV EDI,0x8
CALL 0x001053a0
MOV qword ptr [RBP + -0xc0],RAX
JMP 0x00105f1a
LAB_00105f1a:
MOV RDI,qword ptr [RBP + -0xc0]
MOV qword ptr [RDI],0x0
CALL 0x0010cb60
MOV RCX,qword ptr [RBP + -0xc0]
MOV RAX,qword ptr [RBP + -0x88]
MOV qword ptr [RAX + 0x120],RCX
MOV qword ptr [RAX + 0x80],RCX
MOV EDI,0x8
CALL 0x001053a0
MOV qword ptr [RBP + -0xc8],RAX
JMP 0x00105f5c
LAB_00105f5c:
MOV RDI,qword ptr [RBP + -0xc8]
MOV qword ptr [RDI],0x0
CALL 0x0010cb60
MOV RAX,qword ptr [RBP + -0xc8]
MOV RDI,qword ptr [RBP + -0x88]
MOV qword ptr [RDI + 0x128],RAX
MOV qword ptr [RDI + 0x88],RAX
MOV dword ptr [RDI + 0x198],0x10
CALL 0x001060e0
JMP 0x00105f9c
LAB_00105f9c:
MOV RDI,qword ptr [RBP + -0x88]
CALL 0x00106110
JMP 0x00105faa
LAB_00105faa:
MOV R8,qword ptr [RBP + -0x88]
MOV RSI,R8
ADD RSI,0x58
LEA RAX,[0x105770]
MOV qword ptr [RBP + -0x40],RAX
MOV qword ptr [RBP + -0x38],0x0
MOV RDX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RBP + -0x38]
LEA RAX,[0x1062f0]
MOV qword ptr [RBP + -0x50],RAX
MOV qword ptr [RBP + -0x48],0x0
MOVUPS XMM0,xmmword ptr [RBP + -0x50]
MOV RAX,RSP
MOVUPS xmmword ptr [RAX],XMM0
LEA RDI,[RBP + -0x30]
XOR R9D,R9D
CALL 0x0010cb80
JMP 0x00105ffe
LAB_00105ffe:
LEA RDI,[RBP + -0x30]
CALL 0x001051d0
MOV R8,qword ptr [RBP + -0x88]
MOV RSI,R8
ADD RSI,0xf8
LEA RAX,[0x105770]
MOV qword ptr [RBP + -0x68],RAX
MOV qword ptr [RBP + -0x60],0x0
MOV RDX,qword ptr [RBP + -0x68]
MOV RCX,qword ptr [RBP + -0x60]
LEA RAX,[0x1062f0]
MOV qword ptr [RBP + -0x78],RAX
MOV qword ptr [RBP + -0x70],0x0
MOVUPS XMM0,xmmword ptr [RBP + -0x78]
MOV RAX,RSP
MOVUPS xmmword ptr [RAX],XMM0
LEA RDI,[RBP + -0x58]
XOR R9D,R9D
CALL 0x0010cb80
LAB_0010605c:
JMP 0x0010605e
LAB_0010605e:
LEA RDI,[RBP + -0x58]
CALL 0x001051d0
ADD RSP,0xe0
POP RBP
RET
|
/* MainWindow::MainWindow(QWidget*) */
void __thiscall MainWindow::MainWindow(MainWindow *this,QWidget *param_1)
{
QList<int> *pQVar1;
QMap<int,QPushButton*> *pQVar2;
Connection local_60 [8];
code *local_58;
int8 uStack_50;
code *local_48;
int8 local_40;
Connection local_38 [28];
int4 local_1c;
QWidget *local_18;
MainWindow *local_10;
local_18 = param_1;
local_10 = this;
QFlags<Qt::WindowType>::QFlags((QFlags<Qt::WindowType> *)&local_1c);
QMainWindow::QMainWindow((QMainWindow *)this,param_1,local_1c);
*(int ***)this = &PTR_metaObject_0011fb00;
*(int ***)(this + 0x10) = &PTR__MainWindow_0011fcb8;
QList<int>::QList((QList<int> *)(this + 0x28));
QList<int>::QList((QList<int> *)(this + 0x40));
/* try { // try from 00105e50 to 00105e58 has its CatchHandler @ 00106070 */
Elevetor::Elevetor((Elevetor *)(this + 0x58),(QObject *)0x0);
/* try { // try from 00105e70 to 00105e78 has its CatchHandler @ 0010607e */
Elevetor::Elevetor((Elevetor *)(this + 0xf8),(QObject *)0x0);
/* try { // try from 00105e7b to 0010605b has its CatchHandler @ 0010608c */
pQVar1 = (QList<int> *)operator_new(0x18);
*(int8 *)pQVar1 = 0;
*(int8 *)(pQVar1 + 8) = 0;
*(int8 *)(pQVar1 + 0x10) = 0;
QList<int>::QList(pQVar1);
*(QList<int> **)(this + 0x108) = pQVar1;
*(QList<int> **)(this + 0x68) = pQVar1;
pQVar1 = (QList<int> *)operator_new(0x18);
*(int8 *)pQVar1 = 0;
*(int8 *)(pQVar1 + 8) = 0;
*(int8 *)(pQVar1 + 0x10) = 0;
QList<int>::QList(pQVar1);
*(QList<int> **)(this + 0x110) = pQVar1;
*(QList<int> **)(this + 0x70) = pQVar1;
pQVar2 = (QMap<int,QPushButton*> *)operator_new(8);
*(int8 *)pQVar2 = 0;
QMap<int,QPushButton*>::QMap(pQVar2);
*(QMap<int,QPushButton*> **)(this + 0x120) = pQVar2;
*(QMap<int,QPushButton*> **)(this + 0x80) = pQVar2;
pQVar2 = (QMap<int,QPushButton*> *)operator_new(8);
*(int8 *)pQVar2 = 0;
QMap<int,QPushButton*>::QMap(pQVar2);
*(QMap<int,QPushButton*> **)(this + 0x128) = pQVar2;
*(QMap<int,QPushButton*> **)(this + 0x88) = pQVar2;
*(int4 *)(this + 0x198) = 0x10;
setWindow(this);
setcenter(this);
local_48 = Elevetor::send_update;
local_40 = 0;
local_58 = update_endstair;
uStack_50 = 0;
QObject::connect<void(Elevetor::*)(Elevetor&),void(MainWindow::*)(Elevetor&)>
(local_38,this + 0x58,Elevetor::send_update,0,this,0,0x1062f0,0);
QMetaObject::Connection::~Connection(local_38);
QObject::connect<void(Elevetor::*)(Elevetor&),void(MainWindow::*)(Elevetor&)>
(local_60,this + 0xf8,Elevetor::send_update,0,this,0,0x1062f0,0);
QMetaObject::Connection::~Connection(local_60);
return;
}
|
|
7,875 |
MainWindow::MainWindow(QWidget*)
|
LeafBlue[P]myElevetor/mainwindow.cpp
|
MainWindow::MainWindow(QWidget *parent)
: QMainWindow(parent),ele_A(),ele_B()
{
ele_A.up_out = ele_B.up_out = new QVector<int>();
ele_A.down_out = ele_B.down_out = new QVector<int>();
ele_A.outbtn_up = ele_B.outbtn_up = new QMap<int,QPushButton*>();
ele_A.outbtn_down = ele_B.outbtn_down = new QMap<int,QPushButton*>();
move_v = 16;//假设60像素需1000毫秒
setWindow();
setcenter();
//接收信号
connect(&ele_A,&Elevetor::send_update,this,&MainWindow::update_endstair);
connect(&ele_B,&Elevetor::send_update,this,&MainWindow::update_endstair);
}
|
O1
|
cpp
|
MainWindow::MainWindow(QWidget*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
xorl %edx, %edx
callq 0x40f0
leaq 0xaef9(%rip), %rax # 0xfaf0
leaq 0x10(%rax), %rcx
movq %rcx, (%rbx)
addq $0x1c8, %rax # imm = 0x1C8
movq %rax, 0x10(%rbx)
leaq 0x58(%rbx), %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%rbx)
movups %xmm0, 0x38(%rbx)
movups %xmm0, 0x48(%rbx)
movq %rdi, 0x10(%rsp)
xorl %esi, %esi
callq 0x8a54
leaq 0xf8(%rbx), %r15
movq %r15, %rdi
xorl %esi, %esi
callq 0x8a54
movl $0x18, %edi
callq 0x4380
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
movq %rax, 0x108(%rbx)
movq %rax, 0x68(%rbx)
movl $0x18, %edi
callq 0x4380
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
movq %rax, 0x110(%rbx)
movq %rax, 0x70(%rbx)
movl $0x8, %edi
callq 0x4380
movq $0x0, (%rax)
movq %rax, 0x120(%rbx)
movq %rax, 0x80(%rbx)
movl $0x8, %edi
callq 0x4380
movq $0x0, (%rax)
movq %rax, 0x128(%rbx)
movq %rax, 0x88(%rbx)
movl $0x10, 0x198(%rbx)
movabsq $0x2d0000003e8, %rax # imm = 0x2D0000003E8
movq %rsp, %rsi
movq %rax, (%rsi)
movq %rbx, %rdi
callq 0x4550
movq %rbx, %rdi
callq 0x4e42
leaq -0x369(%rip), %rbp # 0x4984
movq %rbp, (%rsp)
xorl %eax, %eax
movq %rax, 0x8(%rsp)
leaq 0x267(%rip), %r12 # 0x4f66
movq %r12, 0x18(%rsp)
movq %rax, 0x20(%rsp)
movl $0x20, %edi
callq 0x4380
movl $0x1, (%rax)
leaq 0x32ae(%rip), %r14 # 0x7fce
movq %r14, 0x8(%rax)
movq %r12, 0x10(%rax)
xorl %r10d, %r10d
movq %r10, 0x18(%rax)
subq $0x8, %rsp
leaq 0xacbe(%rip), %r13 # 0xf9f8
leaq 0x38(%rsp), %rdi
leaq 0x8(%rsp), %rdx
leaq 0x20(%rsp), %r8
movq 0x18(%rsp), %rsi
movq %rbx, %rcx
movq %rax, %r9
pushq %r13
pushq %r10
pushq $0x0
callq 0x42a0
addq $0x20, %rsp
leaq 0x30(%rsp), %rdi
callq 0x41c0
movq %rbp, (%rsp)
xorl %eax, %eax
movq %rax, 0x8(%rsp)
movq %r12, 0x18(%rsp)
movq %rax, 0x20(%rsp)
movl $0x20, %edi
callq 0x4380
movl $0x1, (%rax)
movq %r14, 0x8(%rax)
movq %r12, 0x10(%rax)
xorl %r10d, %r10d
movq %r10, 0x18(%rax)
subq $0x8, %rsp
leaq 0x30(%rsp), %rdi
leaq 0x8(%rsp), %rdx
leaq 0x20(%rsp), %r8
movq %r15, %rsi
movq %rbx, %rcx
movq %rax, %r9
pushq %r13
pushq %r10
pushq $0x0
callq 0x42a0
addq $0x20, %rsp
leaq 0x28(%rsp), %rdi
callq 0x41c0
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r12
jmp 0x4dfa
movq %rax, %r12
jmp 0x4e04
movq %rax, %r12
movq %r15, %rdi
callq 0x899c
movq 0x10(%rsp), %rdi
callq 0x899c
leaq 0x28(%rbx), %r14
leaq 0x40(%rbx), %rdi
callq 0x7d82
movq %r14, %rdi
callq 0x7d82
movq %rbx, %rdi
callq 0x4230
movq %r12, %rdi
callq 0x41d0
nop
|
_ZN10MainWindowC2EP7QWidget:
push rbp; Alternative name is 'MainWindow::MainWindow(QWidget *)'
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov rbx, rdi
xor edx, edx
call __ZN11QMainWindowC2EP7QWidget6QFlagsIN2Qt10WindowTypeEE; QMainWindow::QMainWindow(QWidget *,QFlags<Qt::WindowType>)
lea rax, _ZTV10MainWindow; `vtable for'MainWindow
lea rcx, [rax+10h]
mov [rbx], rcx
add rax, 1C8h
mov [rbx+10h], rax
lea rdi, [rbx+58h]; this
xorps xmm0, xmm0
movups xmmword ptr [rbx+28h], xmm0
movups xmmword ptr [rbx+38h], xmm0
movups xmmword ptr [rbx+48h], xmm0
mov [rsp+68h+var_58], rdi
xor esi, esi; QObject *
call _ZN8ElevetorC2EP7QObject; Elevetor::Elevetor(QObject *)
lea r15, [rbx+0F8h]
mov rdi, r15; this
xor esi, esi; QObject *
call _ZN8ElevetorC2EP7QObject; Elevetor::Elevetor(QObject *)
mov edi, 18h; unsigned __int64
call __Znwm; operator new(ulong)
xorps xmm0, xmm0
movups xmmword ptr [rax], xmm0
mov qword ptr [rax+10h], 0
mov [rbx+108h], rax
mov [rbx+68h], rax
mov edi, 18h; unsigned __int64
call __Znwm; operator new(ulong)
xorps xmm0, xmm0
movups xmmword ptr [rax], xmm0
mov qword ptr [rax+10h], 0
mov [rbx+110h], rax
mov [rbx+70h], rax
mov edi, 8; unsigned __int64
call __Znwm; operator new(ulong)
mov qword ptr [rax], 0
mov [rbx+120h], rax
mov [rbx+80h], rax
mov edi, 8; unsigned __int64
call __Znwm; operator new(ulong)
mov qword ptr [rax], 0
mov [rbx+128h], rax
mov [rbx+88h], rax
mov dword ptr [rbx+198h], 10h
mov rax, 2D0000003E8h
mov rsi, rsp
mov [rsi], rax
mov rdi, rbx
call __ZN7QWidget6resizeERK5QSize; QWidget::resize(QSize const&)
mov rdi, rbx; this
call _ZN10MainWindow9setcenterEv; MainWindow::setcenter(void)
lea rbp, _ZN8Elevetor11send_updateERS_; Elevetor::send_update(Elevetor&)
mov [rsp+68h+var_68], rbp
xor eax, eax
mov [rsp+68h+var_60], rax
lea r12, _ZN10MainWindow15update_endstairER8Elevetor; MainWindow::update_endstair(Elevetor &)
mov [rsp+68h+var_50], r12
mov [rsp+68h+var_48], rax
mov edi, 20h ; ' '; unsigned __int64
call __Znwm; operator new(ulong)
mov dword ptr [rax], 1
lea r14, _ZN9QtPrivate11QSlotObjectIM10MainWindowFvR8ElevetorENS_4ListIJS3_EEEvE4implEiPNS_15QSlotObjectBaseEP7QObjectPPvPb; QtPrivate::QSlotObject<void (MainWindow::*)(Elevetor &),QtPrivate::List<Elevetor &>,void>::impl(int,QtPrivate::QSlotObjectBase *,QObject *,void **,bool *)
mov [rax+8], r14
mov [rax+10h], r12
xor r10d, r10d
mov [rax+18h], r10
sub rsp, 8
lea r13, _ZN8Elevetor16staticMetaObjectE; Elevetor::staticMetaObject
lea rdi, [rsp+70h+var_38]
lea rdx, [rsp+70h+var_68]
lea r8, [rsp+70h+var_50]
mov rsi, [rsp+70h+var_58]
mov rcx, rbx
mov r9, rax
push r13
push r10
push 0
call __ZN7QObject11connectImplEPKS_PPvS1_S3_PN9QtPrivate15QSlotObjectBaseEN2Qt14ConnectionTypeEPKiPK11QMetaObject; QObject::connectImpl(QObject const*,void **,QObject const*,void **,QtPrivate::QSlotObjectBase *,Qt::ConnectionType,int const*,QMetaObject const*)
add rsp, 20h
lea rdi, [rsp+68h+var_38]; this
call __ZN11QMetaObject10ConnectionD1Ev; QMetaObject::Connection::~Connection()
mov [rsp+68h+var_68], rbp
xor eax, eax
mov [rsp+68h+var_60], rax
mov [rsp+68h+var_50], r12
mov [rsp+68h+var_48], rax
mov edi, 20h ; ' '; unsigned __int64
call __Znwm; operator new(ulong)
mov dword ptr [rax], 1
mov [rax+8], r14
mov [rax+10h], r12
xor r10d, r10d
mov [rax+18h], r10
sub rsp, 8
lea rdi, [rsp+70h+var_40]
lea rdx, [rsp+70h+var_68]
lea r8, [rsp+70h+var_50]
mov rsi, r15
mov rcx, rbx
mov r9, rax
push r13
push r10
push 0
call __ZN7QObject11connectImplEPKS_PPvS1_S3_PN9QtPrivate15QSlotObjectBaseEN2Qt14ConnectionTypeEPKiPK11QMetaObject; QObject::connectImpl(QObject const*,void **,QObject const*,void **,QtPrivate::QSlotObjectBase *,Qt::ConnectionType,int const*,QMetaObject const*)
add rsp, 20h
lea rdi, [rsp+68h+var_40]; this
call __ZN11QMetaObject10ConnectionD1Ev; QMetaObject::Connection::~Connection()
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r12, rax
jmp short loc_4DFA
mov r12, rax
jmp short loc_4E04
mov r12, rax
mov rdi, r15; this
call _ZN8ElevetorD2Ev; Elevetor::~Elevetor()
loc_4DFA:
mov rdi, [rsp+arg_8]; this
call _ZN8ElevetorD2Ev; Elevetor::~Elevetor()
loc_4E04:
lea r14, [rbx+28h]
lea rdi, [rbx+40h]
call _ZN5QListIiED2Ev; QList<int>::~QList()
mov rdi, r14
call _ZN5QListIiED2Ev; QList<int>::~QList()
mov rdi, rbx; this
call __ZN11QMainWindowD2Ev; QMainWindow::~QMainWindow()
mov rdi, r12
call __Unwind_Resume
|
void MainWindow::MainWindow(MainWindow *this, QWidget *a2)
{
long long v2; // rax
long long v3; // rax
_QWORD *v4; // rax
_QWORD *v5; // rax
long long v6; // rax
long long v7; // rax
long long v8; // [rsp+0h] [rbp-68h] BYREF
long long v9; // [rsp+8h] [rbp-60h]
char *v10; // [rsp+10h] [rbp-58h]
long long ( *v11)(MainWindow *__hidden, Elevetor *); // [rsp+18h] [rbp-50h] BYREF
long long v12; // [rsp+20h] [rbp-48h]
_BYTE v13[8]; // [rsp+28h] [rbp-40h] BYREF
_BYTE v14[56]; // [rsp+30h] [rbp-38h] BYREF
QMainWindow::QMainWindow(this, a2, 0LL);
*(_QWORD *)this = &`vtable for'MainWindow + 2;
*((_QWORD *)this + 2) = &`vtable for'MainWindow + 57;
*(_OWORD *)((char *)this + 40) = 0LL;
*(_OWORD *)((char *)this + 56) = 0LL;
*(_OWORD *)((char *)this + 72) = 0LL;
v10 = (char *)this + 88;
Elevetor::Elevetor((MainWindow *)((char *)this + 88), 0LL);
Elevetor::Elevetor((MainWindow *)((char *)this + 248), 0LL);
v2 = operator new(0x18uLL);
*(_OWORD *)v2 = 0LL;
*(_QWORD *)(v2 + 16) = 0LL;
*((_QWORD *)this + 33) = v2;
*((_QWORD *)this + 13) = v2;
v3 = operator new(0x18uLL);
*(_OWORD *)v3 = 0LL;
*(_QWORD *)(v3 + 16) = 0LL;
*((_QWORD *)this + 34) = v3;
*((_QWORD *)this + 14) = v3;
v4 = (_QWORD *)operator new(8uLL);
*v4 = 0LL;
*((_QWORD *)this + 36) = v4;
*((_QWORD *)this + 16) = v4;
v5 = (_QWORD *)operator new(8uLL);
*v5 = 0LL;
*((_QWORD *)this + 37) = v5;
*((_QWORD *)this + 17) = v5;
*((_DWORD *)this + 102) = 16;
v8 = 0x2D0000003E8LL;
QWidget::resize(this, &v8);
MainWindow::setcenter(this);
v8 = (long long)Elevetor::send_update;
v9 = 0LL;
v11 = MainWindow::update_endstair;
v12 = 0LL;
v6 = operator new(0x20uLL);
*(_DWORD *)v6 = 1;
*(_QWORD *)(v6 + 8) = &QtPrivate::QSlotObject<void (MainWindow::*)(Elevetor &),QtPrivate::List<Elevetor &>,void>::impl;
*(_QWORD *)(v6 + 16) = MainWindow::update_endstair;
*(_QWORD *)(v6 + 24) = 0LL;
QObject::connectImpl(v14, v10, &v8, this, &v11, v6, 0LL, 0LL, &Elevetor::staticMetaObject);
QMetaObject::Connection::~Connection((QMetaObject::Connection *)v14);
v8 = (long long)Elevetor::send_update;
v9 = 0LL;
v11 = MainWindow::update_endstair;
v12 = 0LL;
v7 = operator new(0x20uLL);
*(_DWORD *)v7 = 1;
*(_QWORD *)(v7 + 8) = &QtPrivate::QSlotObject<void (MainWindow::*)(Elevetor &),QtPrivate::List<Elevetor &>,void>::impl;
*(_QWORD *)(v7 + 16) = MainWindow::update_endstair;
*(_QWORD *)(v7 + 24) = 0LL;
QObject::connectImpl(v13, (char *)this + 248, &v8, this, &v11, v7, 0LL, 0LL, &Elevetor::staticMetaObject);
QMetaObject::Connection::~Connection((QMetaObject::Connection *)v13);
}
|
MainWindow:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV RBX,RDI
XOR EDX,EDX
CALL 0x001040f0
LEA RAX,[0x10faf0]
LEA RCX,[RAX + 0x10]
MOV qword ptr [RBX],RCX
ADD RAX,0x1c8
MOV qword ptr [RBX + 0x10],RAX
LEA RDI,[RBX + 0x58]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x28],XMM0
MOVUPS xmmword ptr [RBX + 0x38],XMM0
MOVUPS xmmword ptr [RBX + 0x48],XMM0
LAB_00104c1b:
MOV qword ptr [RSP + 0x10],RDI
XOR ESI,ESI
CALL 0x00108a54
LEA R15,[RBX + 0xf8]
LAB_00104c2e:
MOV RDI,R15
XOR ESI,ESI
CALL 0x00108a54
LAB_00104c38:
MOV EDI,0x18
CALL 0x00104380
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RAX],XMM0
MOV qword ptr [RAX + 0x10],0x0
MOV qword ptr [RBX + 0x108],RAX
MOV qword ptr [RBX + 0x68],RAX
MOV EDI,0x18
CALL 0x00104380
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RAX],XMM0
MOV qword ptr [RAX + 0x10],0x0
MOV qword ptr [RBX + 0x110],RAX
MOV qword ptr [RBX + 0x70],RAX
MOV EDI,0x8
CALL 0x00104380
MOV qword ptr [RAX],0x0
MOV qword ptr [RBX + 0x120],RAX
MOV qword ptr [RBX + 0x80],RAX
MOV EDI,0x8
CALL 0x00104380
MOV qword ptr [RAX],0x0
MOV qword ptr [RBX + 0x128],RAX
MOV qword ptr [RBX + 0x88],RAX
MOV dword ptr [RBX + 0x198],0x10
MOV RAX,0x2d0000003e8
MOV RSI,RSP
MOV qword ptr [RSI],RAX
MOV RDI,RBX
CALL 0x00104550
MOV RDI,RBX
CALL 0x00104e42
LEA RBP,[0x104984]
MOV qword ptr [RSP],RBP
XOR EAX,EAX
MOV qword ptr [RSP + 0x8],RAX
LEA R12,[0x104f66]
MOV qword ptr [RSP + 0x18],R12
MOV qword ptr [RSP + 0x20],RAX
MOV EDI,0x20
CALL 0x00104380
MOV dword ptr [RAX],0x1
LEA R14,[0x107fce]
MOV qword ptr [RAX + 0x8],R14
MOV qword ptr [RAX + 0x10],R12
XOR R10D,R10D
MOV qword ptr [RAX + 0x18],R10
SUB RSP,0x8
LEA R13,[0x10f9f8]
LEA RDI,[RSP + 0x38]
LEA RDX,[RSP + 0x8]
LEA R8,[RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x18]
MOV RCX,RBX
MOV R9,RAX
PUSH R13
PUSH R10
PUSH 0x0
CALL 0x001042a0
ADD RSP,0x20
LEA RDI,[RSP + 0x30]
CALL 0x001041c0
MOV qword ptr [RSP],RBP
XOR EAX,EAX
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x18],R12
MOV qword ptr [RSP + 0x20],RAX
MOV EDI,0x20
CALL 0x00104380
MOV dword ptr [RAX],0x1
MOV qword ptr [RAX + 0x8],R14
MOV qword ptr [RAX + 0x10],R12
XOR R10D,R10D
MOV qword ptr [RAX + 0x18],R10
SUB RSP,0x8
LEA RDI,[RSP + 0x30]
LEA RDX,[RSP + 0x8]
LEA R8,[RSP + 0x20]
MOV RSI,R15
MOV RCX,RBX
MOV R9,RAX
PUSH R13
PUSH R10
PUSH 0x0
CALL 0x001042a0
ADD RSP,0x20
LAB_00104dcc:
LEA RDI,[RSP + 0x28]
CALL 0x001041c0
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* MainWindow::MainWindow(QWidget*) */
void __thiscall MainWindow::MainWindow(MainWindow *this,QWidget *param_1)
{
int8 *puVar1;
int4 *puVar2;
code *local_68;
int8 local_60;
Elevetor *local_58;
code *local_50;
int8 local_48;
Connection local_40 [8];
Connection local_38 [8];
QMainWindow::QMainWindow((QMainWindow *)this,param_1,0);
*(int ***)this = &PTR_metaObject_0010fb00;
*(int ***)(this + 0x10) = &PTR__MainWindow_0010fcb8;
local_58 = (Elevetor *)(this + 0x58);
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
*(int8 *)(this + 0x50) = 0;
/* try { // try from 00104c1b to 00104c26 has its CatchHandler @ 00104dea */
Elevetor::Elevetor(local_58,(QObject *)0x0);
/* try { // try from 00104c2e to 00104c37 has its CatchHandler @ 00104de5 */
Elevetor::Elevetor((Elevetor *)(this + 0xf8),(QObject *)0x0);
/* try { // try from 00104c38 to 00104dcb has its CatchHandler @ 00104def */
puVar1 = (int8 *)operator_new(0x18);
*puVar1 = 0;
puVar1[1] = 0;
puVar1[2] = 0;
*(int8 **)(this + 0x108) = puVar1;
*(int8 **)(this + 0x68) = puVar1;
puVar1 = (int8 *)operator_new(0x18);
*puVar1 = 0;
puVar1[1] = 0;
puVar1[2] = 0;
*(int8 **)(this + 0x110) = puVar1;
*(int8 **)(this + 0x70) = puVar1;
puVar1 = (int8 *)operator_new(8);
*puVar1 = 0;
*(int8 **)(this + 0x120) = puVar1;
*(int8 **)(this + 0x80) = puVar1;
puVar1 = (int8 *)operator_new(8);
*puVar1 = 0;
*(int8 **)(this + 0x128) = puVar1;
*(int8 **)(this + 0x88) = puVar1;
*(int4 *)(this + 0x198) = 0x10;
local_68 = (code *)0x2d0000003e8;
QWidget::resize((QSize *)this);
setcenter(this);
local_68 = Elevetor::send_update;
local_60 = 0;
local_50 = update_endstair;
local_48 = 0;
puVar2 = (int4 *)operator_new(0x20);
*puVar2 = 1;
*(code **)(puVar2 + 2) =
QtPrivate::QSlotObject<void(MainWindow::*)(Elevetor&),QtPrivate::List<Elevetor&>,void>::impl;
*(code **)(puVar2 + 4) = update_endstair;
*(int8 *)(puVar2 + 6) = 0;
QObject::connectImpl
(local_38,local_58,&local_68,this,&local_50,puVar2,0,0,Elevetor::staticMetaObject);
QMetaObject::Connection::~Connection(local_38);
local_68 = Elevetor::send_update;
local_60 = 0;
local_50 = update_endstair;
local_48 = 0;
puVar2 = (int4 *)operator_new(0x20);
*puVar2 = 1;
*(code **)(puVar2 + 2) =
QtPrivate::QSlotObject<void(MainWindow::*)(Elevetor&),QtPrivate::List<Elevetor&>,void>::impl;
*(code **)(puVar2 + 4) = update_endstair;
*(int8 *)(puVar2 + 6) = 0;
QObject::connectImpl
(local_40,(Elevetor *)(this + 0xf8),&local_68,this,&local_50,puVar2,0,0,
Elevetor::staticMetaObject);
QMetaObject::Connection::~Connection(local_40);
return;
}
|
|
7,876 |
MainWindow::MainWindow(QWidget*)
|
LeafBlue[P]myElevetor/mainwindow.cpp
|
MainWindow::MainWindow(QWidget *parent)
: QMainWindow(parent),ele_A(),ele_B()
{
ele_A.up_out = ele_B.up_out = new QVector<int>();
ele_A.down_out = ele_B.down_out = new QVector<int>();
ele_A.outbtn_up = ele_B.outbtn_up = new QMap<int,QPushButton*>();
ele_A.outbtn_down = ele_B.outbtn_down = new QMap<int,QPushButton*>();
move_v = 16;//假设60像素需1000毫秒
setWindow();
setcenter();
//接收信号
connect(&ele_A,&Elevetor::send_update,this,&MainWindow::update_endstair);
connect(&ele_B,&Elevetor::send_update,this,&MainWindow::update_endstair);
}
|
O2
|
cpp
|
MainWindow::MainWindow(QWidget*):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
xorl %edx, %edx
callq 0x40f0
leaq 0xa1b0(%rip), %rax # 0xeaf0
leaq 0x10(%rax), %rcx
movq %rcx, (%rbx)
addq $0x1c8, %rax # imm = 0x1C8
movq %rax, 0x10(%rbx)
leaq 0x58(%rbx), %r14
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%rbx)
movups %xmm0, 0x38(%rbx)
movups %xmm0, 0x48(%rbx)
movq %r14, %rdi
xorl %esi, %esi
callq 0x7eec
leaq 0xf8(%rbx), %r15
movq %r15, %rdi
xorl %esi, %esi
callq 0x7eec
pushq $0x18
popq %rdi
callq 0x4390
andq $0x0, 0x10(%rax)
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq %rax, 0x108(%rbx)
movq %rax, 0x68(%rbx)
pushq $0x18
popq %rdi
callq 0x4390
andq $0x0, 0x10(%rax)
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq %rax, 0x110(%rbx)
movq %rax, 0x70(%rbx)
pushq $0x8
popq %rdi
callq 0x4390
andq $0x0, (%rax)
movq %rax, 0x120(%rbx)
movq %rax, 0x80(%rbx)
pushq $0x8
popq %rdi
callq 0x4390
andq $0x0, (%rax)
movq %rax, 0x128(%rbx)
movq %rax, 0x88(%rbx)
movl $0x10, 0x198(%rbx)
movq %rbx, %rdi
callq 0x4ad2
movq %rbx, %rdi
callq 0x4ae2
leaq 0x1e8(%rip), %r12 # 0x4bf8
movq %r12, 0x18(%rsp)
andq $0x0, 0x20(%rsp)
movups 0x18(%rsp), %xmm0
movups %xmm0, (%rsp)
leaq -0x339(%rip), %rdx # 0x46f2
leaq 0x30(%rsp), %rdi
movq %r14, %rsi
xorl %ecx, %ecx
movq %rbx, %r8
xorl %r9d, %r9d
callq 0x6efa
leaq 0x30(%rsp), %rdi
callq 0x41c0
movq %r12, 0x18(%rsp)
andq $0x0, 0x20(%rsp)
movups 0x18(%rsp), %xmm0
movups %xmm0, (%rsp)
leaq -0x373(%rip), %rdx # 0x46f2
leaq 0x28(%rsp), %rdi
movq %r15, %rsi
xorl %ecx, %ecx
movq %rbx, %r8
xorl %r9d, %r9d
callq 0x6efa
leaq 0x28(%rsp), %rdi
callq 0x41c0
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %r12
jmp 0x4aa5
movq %rax, %r12
jmp 0x4aad
movq %rax, %r12
movq %r15, %rdi
callq 0x7e68
movq %r14, %rdi
callq 0x7e68
leaq 0x28(%rbx), %r14
leaq 0x40(%rbx), %rdi
callq 0x7228
movq %r14, %rdi
callq 0x7228
movq %rbx, %rdi
callq 0x4230
movq %r12, %rdi
callq 0x41d0
|
_ZN10MainWindowC2EP7QWidget:
push r15; Alternative name is 'MainWindow::MainWindow(QWidget *)'
push r14
push r12
push rbx
sub rsp, 38h
mov rbx, rdi
xor edx, edx
call __ZN11QMainWindowC2EP7QWidget6QFlagsIN2Qt10WindowTypeEE; QMainWindow::QMainWindow(QWidget *,QFlags<Qt::WindowType>)
lea rax, _ZTV10MainWindow; `vtable for'MainWindow
lea rcx, [rax+10h]
mov [rbx], rcx
add rax, 1C8h
mov [rbx+10h], rax
lea r14, [rbx+58h]
xorps xmm0, xmm0
movups xmmword ptr [rbx+28h], xmm0
movups xmmword ptr [rbx+38h], xmm0
movups xmmword ptr [rbx+48h], xmm0
mov rdi, r14; this
xor esi, esi; QObject *
call _ZN8ElevetorC2EP7QObject; Elevetor::Elevetor(QObject *)
lea r15, [rbx+0F8h]
mov rdi, r15; this
xor esi, esi; QObject *
call _ZN8ElevetorC2EP7QObject; Elevetor::Elevetor(QObject *)
push 18h
pop rdi; unsigned __int64
call __Znwm; operator new(ulong)
and qword ptr [rax+10h], 0
xorps xmm0, xmm0
movups xmmword ptr [rax], xmm0
mov [rbx+108h], rax
mov [rbx+68h], rax
push 18h
pop rdi; unsigned __int64
call __Znwm; operator new(ulong)
and qword ptr [rax+10h], 0
xorps xmm0, xmm0
movups xmmword ptr [rax], xmm0
mov [rbx+110h], rax
mov [rbx+70h], rax
push 8
pop rdi; unsigned __int64
call __Znwm; operator new(ulong)
and qword ptr [rax], 0
mov [rbx+120h], rax
mov [rbx+80h], rax
push 8
pop rdi; unsigned __int64
call __Znwm; operator new(ulong)
and qword ptr [rax], 0
mov [rbx+128h], rax
mov [rbx+88h], rax
mov dword ptr [rbx+198h], 10h
mov rdi, rbx; this
call _ZN10MainWindow9setWindowEv; MainWindow::setWindow(void)
mov rdi, rbx; this
call _ZN10MainWindow9setcenterEv; MainWindow::setcenter(void)
lea r12, _ZN10MainWindow15update_endstairER8Elevetor; MainWindow::update_endstair(Elevetor &)
mov qword ptr [rsp+58h+var_40], r12
and qword ptr [rsp+58h+var_40+8], 0
movups xmm0, [rsp+58h+var_40]
movups [rsp+58h+var_58], xmm0
lea rdx, _ZN8Elevetor11send_updateERS_; Elevetor::send_update(Elevetor&)
lea rdi, [rsp+58h+var_28]
mov rsi, r14
xor ecx, ecx
mov r8, rbx
xor r9d, r9d
call _ZN7QObject7connectIM8ElevetorFvRS1_EM10MainWindowFvS2_EEEN11QMetaObject10ConnectionEPKN9QtPrivate15FunctionPointerIT_E6ObjectESC_PKNSB_IT0_E6ObjectESH_N2Qt14ConnectionTypeE; QObject::connect<void (Elevetor::*)(Elevetor&),void (MainWindow::*)(Elevetor&)>(QtPrivate::FunctionPointer<void (Elevetor::*)(Elevetor&)>::Object const*,void (Elevetor::*)(Elevetor&),QtPrivate::FunctionPointer<void (MainWindow::*)(Elevetor&)>::Object const*,void (MainWindow::*)(Elevetor&),Qt::ConnectionType)
lea rdi, [rsp+58h+var_28]; this
call __ZN11QMetaObject10ConnectionD1Ev; QMetaObject::Connection::~Connection()
mov qword ptr [rsp+58h+var_40], r12
and qword ptr [rsp+58h+var_40+8], 0
movups xmm0, [rsp+58h+var_40]
movups [rsp+58h+var_58], xmm0
lea rdx, _ZN8Elevetor11send_updateERS_; Elevetor::send_update(Elevetor&)
lea rdi, [rsp+58h+var_30]
mov rsi, r15
xor ecx, ecx
mov r8, rbx
xor r9d, r9d
call _ZN7QObject7connectIM8ElevetorFvRS1_EM10MainWindowFvS2_EEEN11QMetaObject10ConnectionEPKN9QtPrivate15FunctionPointerIT_E6ObjectESC_PKNSB_IT0_E6ObjectESH_N2Qt14ConnectionTypeE; QObject::connect<void (Elevetor::*)(Elevetor&),void (MainWindow::*)(Elevetor&)>(QtPrivate::FunctionPointer<void (Elevetor::*)(Elevetor&)>::Object const*,void (Elevetor::*)(Elevetor&),QtPrivate::FunctionPointer<void (MainWindow::*)(Elevetor&)>::Object const*,void (MainWindow::*)(Elevetor&),Qt::ConnectionType)
lea rdi, [rsp+58h+var_30]; this
call __ZN11QMetaObject10ConnectionD1Ev; QMetaObject::Connection::~Connection()
add rsp, 38h
pop rbx
pop r12
pop r14
pop r15
retn
mov r12, rax
jmp short loc_4AA5
mov r12, rax
jmp short loc_4AAD
mov r12, rax
mov rdi, r15; this
call _ZN8ElevetorD2Ev; Elevetor::~Elevetor()
loc_4AA5:
mov rdi, r14; this
call _ZN8ElevetorD2Ev; Elevetor::~Elevetor()
loc_4AAD:
lea r14, [rbx+28h]
lea rdi, [rbx+40h]
call _ZN17QArrayDataPointerIiED2Ev; QArrayDataPointer<int>::~QArrayDataPointer()
mov rdi, r14
call _ZN17QArrayDataPointerIiED2Ev; QArrayDataPointer<int>::~QArrayDataPointer()
mov rdi, rbx; this
call __ZN11QMainWindowD2Ev; QMainWindow::~QMainWindow()
mov rdi, r12
call __Unwind_Resume
|
void MainWindow::MainWindow(MainWindow *this, QWidget *a2)
{
int v2; // ebx
long long v3; // rax
long long v4; // rax
_QWORD *v5; // rax
_QWORD *v6; // rax
_BYTE v7[8]; // [rsp+28h] [rbp-30h] BYREF
_BYTE v8[40]; // [rsp+30h] [rbp-28h] BYREF
v2 = (int)this;
QMainWindow::QMainWindow(this, a2, 0LL);
*(_QWORD *)this = &`vtable for'MainWindow + 2;
*((_QWORD *)this + 2) = &`vtable for'MainWindow + 57;
*(_OWORD *)((char *)this + 40) = 0LL;
*(_OWORD *)((char *)this + 56) = 0LL;
*(_OWORD *)((char *)this + 72) = 0LL;
Elevetor::Elevetor((MainWindow *)((char *)this + 88), 0LL);
Elevetor::Elevetor((MainWindow *)((char *)this + 248), 0LL);
v3 = operator new(0x18uLL);
*(_QWORD *)(v3 + 16) = 0LL;
*(_OWORD *)v3 = 0LL;
*((_QWORD *)this + 33) = v3;
*((_QWORD *)this + 13) = v3;
v4 = operator new(0x18uLL);
*(_QWORD *)(v4 + 16) = 0LL;
*(_OWORD *)v4 = 0LL;
*((_QWORD *)this + 34) = v4;
*((_QWORD *)this + 14) = v4;
v5 = (_QWORD *)operator new(8uLL);
*v5 = 0LL;
*((_QWORD *)this + 36) = v5;
*((_QWORD *)this + 16) = v5;
v6 = (_QWORD *)operator new(8uLL);
*v6 = 0LL;
*((_QWORD *)this + 37) = v6;
*((_QWORD *)this + 17) = v6;
*((_DWORD *)this + 102) = 16;
MainWindow::setWindow(this);
MainWindow::setcenter(this);
QObject::connect<void (Elevetor::*)(Elevetor&),void (MainWindow::*)(Elevetor&)>(
(unsigned int)v8,
v2 + 88,
(unsigned int)Elevetor::send_update,
0,
v2,
0,
(long long)MainWindow::update_endstair,
0LL);
QMetaObject::Connection::~Connection((QMetaObject::Connection *)v8);
QObject::connect<void (Elevetor::*)(Elevetor&),void (MainWindow::*)(Elevetor&)>(
(unsigned int)v7,
v2 + 248,
(unsigned int)Elevetor::send_update,
0,
v2,
0,
(long long)MainWindow::update_endstair,
0LL);
QMetaObject::Connection::~Connection((QMetaObject::Connection *)v7);
}
|
MainWindow:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV RBX,RDI
XOR EDX,EDX
CALL 0x001040f0
LEA RAX,[0x10eaf0]
LEA RCX,[RAX + 0x10]
MOV qword ptr [RBX],RCX
ADD RAX,0x1c8
MOV qword ptr [RBX + 0x10],RAX
LEA R14,[RBX + 0x58]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x28],XMM0
MOVUPS xmmword ptr [RBX + 0x38],XMM0
MOVUPS xmmword ptr [RBX + 0x48],XMM0
LAB_00104964:
MOV RDI,R14
XOR ESI,ESI
CALL 0x00107eec
LEA R15,[RBX + 0xf8]
LAB_00104975:
MOV RDI,R15
XOR ESI,ESI
CALL 0x00107eec
LAB_0010497f:
PUSH 0x18
POP RDI
CALL 0x00104390
AND qword ptr [RAX + 0x10],0x0
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RAX],XMM0
MOV qword ptr [RBX + 0x108],RAX
MOV qword ptr [RBX + 0x68],RAX
PUSH 0x18
POP RDI
CALL 0x00104390
AND qword ptr [RAX + 0x10],0x0
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RAX],XMM0
MOV qword ptr [RBX + 0x110],RAX
MOV qword ptr [RBX + 0x70],RAX
PUSH 0x8
POP RDI
CALL 0x00104390
AND qword ptr [RAX],0x0
MOV qword ptr [RBX + 0x120],RAX
MOV qword ptr [RBX + 0x80],RAX
PUSH 0x8
POP RDI
CALL 0x00104390
AND qword ptr [RAX],0x0
MOV qword ptr [RBX + 0x128],RAX
MOV qword ptr [RBX + 0x88],RAX
MOV dword ptr [RBX + 0x198],0x10
MOV RDI,RBX
CALL 0x00104ad2
MOV RDI,RBX
CALL 0x00104ae2
LEA R12,[0x104bf8]
MOV qword ptr [RSP + 0x18],R12
AND qword ptr [RSP + 0x20],0x0
MOVUPS XMM0,xmmword ptr [RSP + 0x18]
MOVUPS xmmword ptr [RSP],XMM0
LEA RDX,[0x1046f2]
LEA RDI,[RSP + 0x30]
MOV RSI,R14
XOR ECX,ECX
MOV R8,RBX
XOR R9D,R9D
CALL 0x00106efa
LEA RDI,[RSP + 0x30]
CALL 0x001041c0
MOV qword ptr [RSP + 0x18],R12
AND qword ptr [RSP + 0x20],0x0
MOVUPS XMM0,xmmword ptr [RSP + 0x18]
MOVUPS xmmword ptr [RSP],XMM0
LEA RDX,[0x1046f2]
LEA RDI,[RSP + 0x28]
MOV RSI,R15
XOR ECX,ECX
MOV R8,RBX
XOR R9D,R9D
CALL 0x00106efa
LAB_00104a7a:
LEA RDI,[RSP + 0x28]
CALL 0x001041c0
ADD RSP,0x38
POP RBX
POP R12
POP R14
POP R15
RET
|
/* MainWindow::MainWindow(QWidget*) */
void __thiscall MainWindow::MainWindow(MainWindow *this,QWidget *param_1)
{
int8 *puVar1;
Connection local_30 [8];
Connection local_28 [8];
QMainWindow::QMainWindow((QMainWindow *)this,param_1,0);
*(int ***)this = &PTR_metaObject_0010eb00;
*(int ***)(this + 0x10) = &PTR__MainWindow_0010ecb8;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
*(int8 *)(this + 0x50) = 0;
/* try { // try from 00104964 to 0010496d has its CatchHandler @ 00104a95 */
Elevetor::Elevetor((Elevetor *)(this + 0x58),(QObject *)0x0);
/* try { // try from 00104975 to 0010497e has its CatchHandler @ 00104a90 */
Elevetor::Elevetor((Elevetor *)(this + 0xf8),(QObject *)0x0);
/* try { // try from 0010497f to 00104a79 has its CatchHandler @ 00104a9a */
puVar1 = (int8 *)operator_new(0x18);
puVar1[2] = 0;
*puVar1 = 0;
puVar1[1] = 0;
*(int8 **)(this + 0x108) = puVar1;
*(int8 **)(this + 0x68) = puVar1;
puVar1 = (int8 *)operator_new(0x18);
puVar1[2] = 0;
*puVar1 = 0;
puVar1[1] = 0;
*(int8 **)(this + 0x110) = puVar1;
*(int8 **)(this + 0x70) = puVar1;
puVar1 = (int8 *)operator_new(8);
*puVar1 = 0;
*(int8 **)(this + 0x120) = puVar1;
*(int8 **)(this + 0x80) = puVar1;
puVar1 = (int8 *)operator_new(8);
*puVar1 = 0;
*(int8 **)(this + 0x128) = puVar1;
*(int8 **)(this + 0x88) = puVar1;
*(int4 *)(this + 0x198) = 0x10;
setWindow(this);
setcenter(this);
QObject::connect<void(Elevetor::*)(Elevetor&),void(MainWindow::*)(Elevetor&)>
(local_28,(Elevetor *)(this + 0x58),Elevetor::send_update,0,this,0,0x104bf8,0);
QMetaObject::Connection::~Connection(local_28);
QObject::connect<void(Elevetor::*)(Elevetor&),void(MainWindow::*)(Elevetor&)>
(local_30,(Elevetor *)(this + 0xf8),Elevetor::send_update,0,this,0,0x104bf8,0);
QMetaObject::Connection::~Connection(local_30);
return;
}
|
|
7,877 |
open_logfile_by_number_no_cache
|
eloqsql/storage/maria/ma_loghandler.c
|
static File open_logfile_by_number_no_cache(uint32 file_no)
{
File file;
char path[FN_REFLEN];
DBUG_ENTER("open_logfile_by_number_no_cache");
/* TODO: add O_DIRECT to open flags (when buffer is aligned) */
/* TODO: use mysql_file_create() */
if ((file= mysql_file_open(key_file_translog,
translog_filename_by_fileno(file_no, path),
log_descriptor.open_flags | O_CLOEXEC,
MYF(MY_WME))) < 0)
{
DBUG_PRINT("error", ("Error %d during opening file '%s'", errno, path));
DBUG_RETURN(-1);
}
DBUG_PRINT("info", ("File: '%s' handler: %d", path, file));
DBUG_RETURN(file);
}
|
O0
|
c
|
open_logfile_by_number_no_cache:
pushq %rbp
movq %rsp, %rbp
subq $0x230, %rsp # imm = 0x230
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movl %edi, -0x218(%rbp)
leaq 0x427e1f(%rip), %rax # 0x478fb4
movl (%rax), %eax
movl %eax, -0x220(%rbp)
movl -0x218(%rbp), %edi
leaq -0x210(%rbp), %rsi
callq 0x50ba0
movl -0x220(%rbp), %edi
movq %rax, %rcx
movl 0x4294ad(%rip), %r8d # 0x47a66c
orl $0x80000, %r8d # imm = 0x80000
leaq 0x101dec(%rip), %rsi # 0x152fb9
movl $0x406, %edx # imm = 0x406
movl $0x10, %r9d
callq 0x59bd0
movl %eax, -0x21c(%rbp)
cmpl $0x0, %eax
jge 0x511fa
jmp 0x511ea
jmp 0x511ec
jmp 0x511ee
movl $0xffffffff, -0x214(%rbp) # imm = 0xFFFFFFFF
jmp 0x5120c
jmp 0x511fc
jmp 0x511fe
jmp 0x51200
movl -0x21c(%rbp), %eax
movl %eax, -0x214(%rbp)
movl -0x214(%rbp), %eax
movl %eax, -0x224(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x51239
movl -0x224(%rbp), %eax
addq $0x230, %rsp # imm = 0x230
popq %rbp
retq
callq 0x2a270
nop
|
open_logfile_by_number_no_cache:
push rbp
mov rbp, rsp
sub rsp, 230h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_218], edi
lea rax, key_file_translog
mov eax, [rax]
mov [rbp+var_220], eax
mov edi, [rbp+var_218]
lea rsi, [rbp+var_210]
call translog_filename_by_fileno
mov edi, [rbp+var_220]
mov rcx, rax
mov r8d, cs:dword_47A66C
or r8d, 80000h
lea rsi, aWorkspaceLlm4b_11; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 406h
mov r9d, 10h
call inline_mysql_file_open_0
mov [rbp+var_21C], eax
cmp eax, 0
jge short loc_511FA
jmp short $+2
loc_511EA:
jmp short $+2
loc_511EC:
jmp short $+2
loc_511EE:
mov [rbp+var_214], 0FFFFFFFFh
jmp short loc_5120C
loc_511FA:
jmp short $+2
loc_511FC:
jmp short $+2
loc_511FE:
jmp short $+2
loc_51200:
mov eax, [rbp+var_21C]
mov [rbp+var_214], eax
loc_5120C:
mov eax, [rbp+var_214]
mov [rbp+var_224], eax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_51239
mov eax, [rbp+var_224]
add rsp, 230h
pop rbp
retn
loc_51239:
call ___stack_chk_fail
|
long long open_logfile_by_number_no_cache(unsigned int a1, long long a2, long long a3, long long a4, int a5, int a6)
{
long long v6; // rax
unsigned int v8; // [rsp+10h] [rbp-220h]
int v9; // [rsp+14h] [rbp-21Ch]
_BYTE v11[520]; // [rsp+20h] [rbp-210h] BYREF
unsigned long long v12; // [rsp+228h] [rbp-8h]
v12 = __readfsqword(0x28u);
v8 = key_file_translog;
v6 = translog_filename_by_fileno(a1, (long long)v11, a3, a4, a5, a6);
v9 = inline_mysql_file_open_0(
v8,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_loghandler.c",
1030LL,
v6,
dword_47A66C | 0x80000u,
16LL);
if ( v9 >= 0 )
return (unsigned int)v9;
else
return (unsigned int)-1;
}
|
open_logfile_by_number_no_cache:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x230
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV dword ptr [RBP + -0x218],EDI
LEA RAX,[0x578fb4]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x220],EAX
MOV EDI,dword ptr [RBP + -0x218]
LEA RSI,[RBP + -0x210]
CALL 0x00150ba0
MOV EDI,dword ptr [RBP + -0x220]
MOV RCX,RAX
MOV R8D,dword ptr [0x0057a66c]
OR R8D,0x80000
LEA RSI,[0x252fb9]
MOV EDX,0x406
MOV R9D,0x10
CALL 0x00159bd0
MOV dword ptr [RBP + -0x21c],EAX
CMP EAX,0x0
JGE 0x001511fa
JMP 0x001511ea
LAB_001511ea:
JMP 0x001511ec
LAB_001511ec:
JMP 0x001511ee
LAB_001511ee:
MOV dword ptr [RBP + -0x214],0xffffffff
JMP 0x0015120c
LAB_001511fa:
JMP 0x001511fc
LAB_001511fc:
JMP 0x001511fe
LAB_001511fe:
JMP 0x00151200
LAB_00151200:
MOV EAX,dword ptr [RBP + -0x21c]
MOV dword ptr [RBP + -0x214],EAX
LAB_0015120c:
MOV EAX,dword ptr [RBP + -0x214]
MOV dword ptr [RBP + -0x224],EAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x00151239
MOV EAX,dword ptr [RBP + -0x224]
ADD RSP,0x230
POP RBP
RET
LAB_00151239:
CALL 0x0012a270
|
int open_logfile_by_number_no_cache(int4 param_1)
{
int4 uVar1;
int8 uVar2;
long in_FS_OFFSET;
int local_21c;
int1 local_218 [520];
long local_10;
uVar1 = key_file_translog;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
uVar2 = translog_filename_by_fileno(param_1,local_218);
local_21c = inline_mysql_file_open
(uVar1,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_loghandler.c",
0x406,uVar2,DAT_0057a66c | 0x80000,0x10);
if (local_21c < 0) {
local_21c = -1;
}
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return local_21c;
}
|
|
7,878 |
ft_stroke_border_grow
|
dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-ft-stroker.c
|
static PVG_FT_Error ft_stroke_border_grow(PVG_FT_StrokeBorder border,
PVG_FT_UInt new_points)
{
PVG_FT_UInt old_max = border->max_points;
PVG_FT_UInt new_max = border->num_points + new_points;
PVG_FT_Error error = 0;
if (new_max > old_max) {
PVG_FT_UInt cur_max = old_max;
while (cur_max < new_max) cur_max += (cur_max >> 1) + 16;
border->points = (PVG_FT_Vector*)realloc(border->points,
cur_max * sizeof(PVG_FT_Vector));
border->tags =
(PVG_FT_Byte*)realloc(border->tags, cur_max * sizeof(PVG_FT_Byte));
if (!border->points || !border->tags) goto Exit;
border->max_points = cur_max;
}
Exit:
return error;
}
|
O3
|
c
|
ft_stroke_border_grow:
pushq %r15
pushq %r14
pushq %rbx
movl 0x4(%rdi), %r15d
addl (%rdi), %esi
cmpl %r15d, %esi
jbe 0x3ece2
movq %rdi, %rbx
movl %r15d, %eax
shrl %eax
addl %eax, %r15d
addl $0x10, %r15d
cmpl %esi, %r15d
jb 0x3ec9a
movq 0x8(%rbx), %rdi
movl %r15d, %r14d
movq %r14, %rsi
shlq $0x4, %rsi
callq 0xa510
movq %rax, 0x8(%rbx)
movq 0x10(%rbx), %rdi
movq %r14, %rsi
callq 0xa510
movq %rax, 0x10(%rbx)
testq %rax, %rax
je 0x3ece2
cmpq $0x0, 0x8(%rbx)
je 0x3ece2
movl %r15d, 0x4(%rbx)
popq %rbx
popq %r14
popq %r15
retq
|
ft_stroke_border_grow:
push r15
push r14
push rbx
mov r15d, [rdi+4]
add esi, [rdi]
cmp esi, r15d
jbe short loc_3ECE2
mov rbx, rdi
loc_3EC9A:
mov eax, r15d
shr eax, 1
add r15d, eax
add r15d, 10h
cmp r15d, esi
jb short loc_3EC9A
mov rdi, [rbx+8]
mov r14d, r15d
mov rsi, r14
shl rsi, 4
call _realloc
mov [rbx+8], rax
mov rdi, [rbx+10h]
mov rsi, r14
call _realloc
mov [rbx+10h], rax
test rax, rax
jz short loc_3ECE2
cmp qword ptr [rbx+8], 0
jz short loc_3ECE2
mov [rbx+4], r15d
loc_3ECE2:
pop rbx
pop r14
pop r15
retn
|
void ft_stroke_border_grow(long long a1, int a2)
{
unsigned int v2; // r15d
unsigned int v3; // esi
long long v4; // rax
v2 = *(_DWORD *)(a1 + 4);
v3 = *(_DWORD *)a1 + a2;
if ( v3 > v2 )
{
do
v2 += (v2 >> 1) + 16;
while ( v2 < v3 );
*(_QWORD *)(a1 + 8) = realloc(*(_QWORD *)(a1 + 8), 16LL * v2);
v4 = realloc(*(_QWORD *)(a1 + 16), v2);
*(_QWORD *)(a1 + 16) = v4;
if ( v4 )
{
if ( *(_QWORD *)(a1 + 8) )
*(_DWORD *)(a1 + 4) = v2;
}
}
}
|
ft_stroke_border_grow:
PUSH R15
PUSH R14
PUSH RBX
MOV R15D,dword ptr [RDI + 0x4]
ADD ESI,dword ptr [RDI]
CMP ESI,R15D
JBE 0x0013ece2
MOV RBX,RDI
LAB_0013ec9a:
MOV EAX,R15D
SHR EAX,0x1
ADD R15D,EAX
ADD R15D,0x10
CMP R15D,ESI
JC 0x0013ec9a
MOV RDI,qword ptr [RBX + 0x8]
MOV R14D,R15D
MOV RSI,R14
SHL RSI,0x4
CALL 0x0010a510
MOV qword ptr [RBX + 0x8],RAX
MOV RDI,qword ptr [RBX + 0x10]
MOV RSI,R14
CALL 0x0010a510
MOV qword ptr [RBX + 0x10],RAX
TEST RAX,RAX
JZ 0x0013ece2
CMP qword ptr [RBX + 0x8],0x0
JZ 0x0013ece2
MOV dword ptr [RBX + 0x4],R15D
LAB_0013ece2:
POP RBX
POP R14
POP R15
RET
|
void ft_stroke_border_grow(int *param_1,int param_2)
{
void *pvVar1;
uint uVar2;
uVar2 = param_1[1];
if (uVar2 < (uint)(param_2 + *param_1)) {
do {
uVar2 = uVar2 + (uVar2 >> 1) + 0x10;
} while (uVar2 < (uint)(param_2 + *param_1));
pvVar1 = realloc(*(void **)(param_1 + 2),(ulong)uVar2 << 4);
*(void **)(param_1 + 2) = pvVar1;
pvVar1 = realloc(*(void **)(param_1 + 4),(ulong)uVar2);
*(void **)(param_1 + 4) = pvVar1;
if ((pvVar1 != (void *)0x0) && (*(long *)(param_1 + 2) != 0)) {
param_1[1] = uVar2;
}
}
return;
}
|
|
7,879 |
mi_check_index_tuple
|
eloqsql/storage/myisam/mi_key.c
|
check_result_t mi_check_index_tuple(MI_INFO *info, uint keynr, uchar *record)
{
int need_unpack= TRUE;
check_result_t res= CHECK_POS;
if (info->index_cond_func)
{
if (mi_unpack_index_tuple(info, keynr, record))
res= CHECK_ERROR;
else if ((res= info->index_cond_func(info->index_cond_func_arg)) ==
CHECK_OUT_OF_RANGE)
{
/* We got beyond the end of scanned range */
info->lastpos= HA_OFFSET_ERROR; /* No active record */
my_errno= HA_ERR_END_OF_FILE;
}
/*
If we got an error, out-of-range condition, or ICP condition computed to
FALSE - we don't need to check the Rowid Filter.
*/
if (res != CHECK_POS)
return res;
need_unpack= FALSE;
}
/* Check the Rowid Filter, if present */
if (mi_check_rowid_filter_is_active(info))
{
/* Unpack the index tuple if we haven't done it already */
if (need_unpack && mi_unpack_index_tuple(info, keynr, record))
res= CHECK_ERROR;
else
{
if ((res= info->rowid_filter_func(info->rowid_filter_func_arg)) ==
CHECK_OUT_OF_RANGE)
{
/* We got beyond the end of scanned range */
info->lastpos= HA_OFFSET_ERROR; /* No active record */
my_errno= HA_ERR_END_OF_FILE;
}
}
}
return res;
}
|
O0
|
c
|
mi_check_index_tuple:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
movl $0x1, -0x24(%rbp)
movl $0x1, -0x28(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x340(%rax)
je 0xafb4e
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
movq -0x20(%rbp), %rdx
callq 0xafbd0
cmpl $0x0, %eax
je 0xafafd
movl $0xffffffff, -0x28(%rbp) # imm = 0xFFFFFFFF
jmp 0xafb39
movq -0x10(%rbp), %rax
movq 0x340(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x348(%rcx), %rdi
callq *%rax
movl %eax, -0x28(%rbp)
cmpl $0x2, %eax
jne 0xafb37
movq -0x10(%rbp), %rax
movq $-0x1, 0x170(%rax)
callq 0xf60c0
movl $0x89, (%rax)
jmp 0xafb39
cmpl $0x1, -0x28(%rbp)
je 0xafb47
movl -0x28(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xafbc4
movl $0x0, -0x24(%rbp)
movq -0x10(%rbp), %rdi
callq 0xafc50
cmpl $0x0, %eax
je 0xafbbe
cmpl $0x0, -0x24(%rbp)
je 0xafb80
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
movq -0x20(%rbp), %rdx
callq 0xafbd0
cmpl $0x0, %eax
je 0xafb80
movl $0xffffffff, -0x28(%rbp) # imm = 0xFFFFFFFF
jmp 0xafbbc
movq -0x10(%rbp), %rax
movq 0x350(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x360(%rcx), %rdi
callq *%rax
movl %eax, -0x28(%rbp)
cmpl $0x2, %eax
jne 0xafbba
movq -0x10(%rbp), %rax
movq $-0x1, 0x170(%rax)
callq 0xf60c0
movl $0x89, (%rax)
jmp 0xafbbc
jmp 0xafbbe
movl -0x28(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
|
mi_check_index_tuple:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_20], rdx
mov [rbp+var_24], 1
mov [rbp+var_28], 1
mov rax, [rbp+var_10]
cmp qword ptr [rax+340h], 0
jz short loc_AFB4E
mov rdi, [rbp+var_10]
mov esi, [rbp+var_14]
mov rdx, [rbp+var_20]
call mi_unpack_index_tuple
cmp eax, 0
jz short loc_AFAFD
mov [rbp+var_28], 0FFFFFFFFh
jmp short loc_AFB39
loc_AFAFD:
mov rax, [rbp+var_10]
mov rax, [rax+340h]
mov rcx, [rbp+var_10]
mov rdi, [rcx+348h]
call rax
mov [rbp+var_28], eax
cmp eax, 2
jnz short loc_AFB37
mov rax, [rbp+var_10]
mov qword ptr [rax+170h], 0FFFFFFFFFFFFFFFFh
call _my_thread_var
mov dword ptr [rax], 89h
loc_AFB37:
jmp short $+2
loc_AFB39:
cmp [rbp+var_28], 1
jz short loc_AFB47
mov eax, [rbp+var_28]
mov [rbp+var_4], eax
jmp short loc_AFBC4
loc_AFB47:
mov [rbp+var_24], 0
loc_AFB4E:
mov rdi, [rbp+var_10]
call mi_check_rowid_filter_is_active
cmp eax, 0
jz short loc_AFBBE
cmp [rbp+var_24], 0
jz short loc_AFB80
mov rdi, [rbp+var_10]
mov esi, [rbp+var_14]
mov rdx, [rbp+var_20]
call mi_unpack_index_tuple
cmp eax, 0
jz short loc_AFB80
mov [rbp+var_28], 0FFFFFFFFh
jmp short loc_AFBBC
loc_AFB80:
mov rax, [rbp+var_10]
mov rax, [rax+350h]
mov rcx, [rbp+var_10]
mov rdi, [rcx+360h]
call rax
mov [rbp+var_28], eax
cmp eax, 2
jnz short loc_AFBBA
mov rax, [rbp+var_10]
mov qword ptr [rax+170h], 0FFFFFFFFFFFFFFFFh
call _my_thread_var
mov dword ptr [rax], 89h
loc_AFBBA:
jmp short $+2
loc_AFBBC:
jmp short $+2
loc_AFBBE:
mov eax, [rbp+var_28]
mov [rbp+var_4], eax
loc_AFBC4:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
|
long long mi_check_index_tuple(long long a1, const char *a2, long long a3)
{
long long v3; // rdi
long long v4; // rdi
unsigned int v6; // [rsp+8h] [rbp-28h]
int v7; // [rsp+Ch] [rbp-24h]
v7 = 1;
v6 = 1;
if ( *(_QWORD *)(a1 + 832) )
{
a2 = (const char *)(unsigned int)a2;
if ( (unsigned int)mi_unpack_index_tuple(a1, (unsigned int)a2, a3) )
{
v6 = -1;
}
else
{
v3 = *(_QWORD *)(a1 + 840);
v6 = (*(long long ( **)(long long))(a1 + 832))(v3);
if ( v6 == 2 )
{
*(_QWORD *)(a1 + 368) = -1LL;
*(_DWORD *)my_thread_var(v3, (const char *)(unsigned int)a2) = 137;
}
}
if ( v6 != 1 )
return v6;
v7 = 0;
}
if ( (unsigned int)mi_check_rowid_filter_is_active(a1) )
{
if ( v7 && (a2 = (const char *)(unsigned int)a2, (unsigned int)mi_unpack_index_tuple(a1, (unsigned int)a2, a3)) )
{
return (unsigned int)-1;
}
else
{
v4 = *(_QWORD *)(a1 + 864);
v6 = (*(long long ( **)(long long))(a1 + 848))(v4);
if ( v6 == 2 )
{
*(_QWORD *)(a1 + 368) = -1LL;
*(_DWORD *)my_thread_var(v4, a2) = 137;
}
}
}
return v6;
}
|
mi_check_index_tuple:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x24],0x1
MOV dword ptr [RBP + -0x28],0x1
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x340],0x0
JZ 0x001afb4e
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RBP + -0x14]
MOV RDX,qword ptr [RBP + -0x20]
CALL 0x001afbd0
CMP EAX,0x0
JZ 0x001afafd
MOV dword ptr [RBP + -0x28],0xffffffff
JMP 0x001afb39
LAB_001afafd:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x340]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RCX + 0x348]
CALL RAX
MOV dword ptr [RBP + -0x28],EAX
CMP EAX,0x2
JNZ 0x001afb37
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x170],-0x1
CALL 0x001f60c0
MOV dword ptr [RAX],0x89
LAB_001afb37:
JMP 0x001afb39
LAB_001afb39:
CMP dword ptr [RBP + -0x28],0x1
JZ 0x001afb47
MOV EAX,dword ptr [RBP + -0x28]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x001afbc4
LAB_001afb47:
MOV dword ptr [RBP + -0x24],0x0
LAB_001afb4e:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001afc50
CMP EAX,0x0
JZ 0x001afbbe
CMP dword ptr [RBP + -0x24],0x0
JZ 0x001afb80
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RBP + -0x14]
MOV RDX,qword ptr [RBP + -0x20]
CALL 0x001afbd0
CMP EAX,0x0
JZ 0x001afb80
MOV dword ptr [RBP + -0x28],0xffffffff
JMP 0x001afbbc
LAB_001afb80:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x350]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RCX + 0x360]
CALL RAX
MOV dword ptr [RBP + -0x28],EAX
CMP EAX,0x2
JNZ 0x001afbba
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x170],-0x1
CALL 0x001f60c0
MOV dword ptr [RAX],0x89
LAB_001afbba:
JMP 0x001afbbc
LAB_001afbbc:
JMP 0x001afbbe
LAB_001afbbe:
MOV EAX,dword ptr [RBP + -0x28]
MOV dword ptr [RBP + -0x4],EAX
LAB_001afbc4:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
int mi_check_index_tuple(long param_1,int4 param_2,int8 param_3)
{
bool bVar1;
int iVar2;
int4 *puVar3;
int local_30;
bVar1 = true;
local_30 = 1;
if (*(long *)(param_1 + 0x340) != 0) {
iVar2 = mi_unpack_index_tuple(param_1,param_2,param_3);
if (iVar2 == 0) {
local_30 = (**(code **)(param_1 + 0x340))(*(int8 *)(param_1 + 0x348));
if (local_30 == 2) {
*(int8 *)(param_1 + 0x170) = 0xffffffffffffffff;
puVar3 = (int4 *)_my_thread_var();
*puVar3 = 0x89;
}
}
else {
local_30 = -1;
}
if (local_30 != 1) {
return local_30;
}
bVar1 = false;
}
iVar2 = mi_check_rowid_filter_is_active(param_1);
if (iVar2 != 0) {
if ((bVar1) && (iVar2 = mi_unpack_index_tuple(param_1,param_2,param_3), iVar2 != 0)) {
local_30 = -1;
}
else {
local_30 = (**(code **)(param_1 + 0x350))(*(int8 *)(param_1 + 0x360));
if (local_30 == 2) {
*(int8 *)(param_1 + 0x170) = 0xffffffffffffffff;
puVar3 = (int4 *)_my_thread_var();
*puVar3 = 0x89;
}
}
}
return local_30;
}
|
|
7,880 |
my_wc_mb_tis620
|
eloqsql/strings/ctype-tis620.c
|
static
int my_wc_mb_tis620(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t wc,
uchar *str,
uchar *end __attribute__((unused)))
{
const uchar *pl;
if (str >= end)
return MY_CS_TOOSMALL;
pl= uni_to_cs[(wc>>8) & 0xFF];
str[0]= pl ? pl[wc & 0xFF] : '\0';
return (!str[0] && wc) ? MY_CS_ILUNI : 1;
}
|
O0
|
c
|
my_wc_mb_tis620:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x20(%rbp), %rax
cmpq -0x28(%rbp), %rax
jb 0x48207
movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B
jmp 0x48282
movq -0x18(%rbp), %rcx
shrq $0x8, %rcx
andq $0xff, %rcx
leaq 0x180f93(%rip), %rax # 0x1c91b0
movq (%rax,%rcx,8), %rax
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
je 0x48244
movq -0x30(%rbp), %rax
movq -0x18(%rbp), %rcx
andq $0xff, %rcx
movzbl (%rax,%rcx), %eax
movl %eax, -0x34(%rbp)
jmp 0x4824b
xorl %eax, %eax
movl %eax, -0x34(%rbp)
jmp 0x4824b
movl -0x34(%rbp), %eax
movb %al, %cl
movq -0x20(%rbp), %rax
movb %cl, (%rax)
movq -0x20(%rbp), %rcx
xorl %eax, %eax
cmpb $0x0, (%rcx)
movb %al, -0x35(%rbp)
jne 0x4826f
cmpq $0x0, -0x18(%rbp)
setne %al
movb %al, -0x35(%rbp)
movb -0x35(%rbp), %dl
movl $0x1, %eax
xorl %ecx, %ecx
testb $0x1, %dl
cmovnel %ecx, %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopw (%rax,%rax)
|
my_wc_mb_tis620:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_20]
cmp rax, [rbp+var_28]
jb short loc_48207
mov [rbp+var_4], 0FFFFFF9Bh
jmp short loc_48282
loc_48207:
mov rcx, [rbp+var_18]
shr rcx, 8
and rcx, 0FFh
lea rax, uni_to_cs_0
mov rax, [rax+rcx*8]
mov [rbp+var_30], rax
cmp [rbp+var_30], 0
jz short loc_48244
mov rax, [rbp+var_30]
mov rcx, [rbp+var_18]
and rcx, 0FFh
movzx eax, byte ptr [rax+rcx]
mov [rbp+var_34], eax
jmp short loc_4824B
loc_48244:
xor eax, eax
mov [rbp+var_34], eax
jmp short $+2
loc_4824B:
mov eax, [rbp+var_34]
mov cl, al
mov rax, [rbp+var_20]
mov [rax], cl
mov rcx, [rbp+var_20]
xor eax, eax
cmp byte ptr [rcx], 0
mov [rbp+var_35], al
jnz short loc_4826F
cmp [rbp+var_18], 0
setnz al
mov [rbp+var_35], al
loc_4826F:
mov dl, [rbp+var_35]
mov eax, 1
xor ecx, ecx
test dl, 1
cmovnz eax, ecx
mov [rbp+var_4], eax
loc_48282:
mov eax, [rbp+var_4]
pop rbp
retn
|
long long my_wc_mb_tis620(long long a1, long long a2, _BYTE *a3, unsigned long long a4)
{
bool v5; // [rsp+1h] [rbp-35h]
char v6; // [rsp+2h] [rbp-34h]
long long v7; // [rsp+6h] [rbp-30h]
if ( (unsigned long long)a3 < a4 )
{
v7 = (long long)*(&uni_to_cs_0 + BYTE1(a2));
if ( v7 )
v6 = *(_BYTE *)(v7 + (unsigned __int8)a2);
else
v6 = 0;
*a3 = v6;
v5 = 0;
if ( !*a3 )
v5 = a2 != 0;
return !v5;
}
else
{
return (unsigned int)-101;
}
}
|
my_wc_mb_tis620:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RBP + -0x28]
JC 0x00148207
MOV dword ptr [RBP + -0x4],0xffffff9b
JMP 0x00148282
LAB_00148207:
MOV RCX,qword ptr [RBP + -0x18]
SHR RCX,0x8
AND RCX,0xff
LEA RAX,[0x2c91b0]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x30],RAX
CMP qword ptr [RBP + -0x30],0x0
JZ 0x00148244
MOV RAX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RBP + -0x18]
AND RCX,0xff
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV dword ptr [RBP + -0x34],EAX
JMP 0x0014824b
LAB_00148244:
XOR EAX,EAX
MOV dword ptr [RBP + -0x34],EAX
JMP 0x0014824b
LAB_0014824b:
MOV EAX,dword ptr [RBP + -0x34]
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV byte ptr [RAX],CL
MOV RCX,qword ptr [RBP + -0x20]
XOR EAX,EAX
CMP byte ptr [RCX],0x0
MOV byte ptr [RBP + -0x35],AL
JNZ 0x0014826f
CMP qword ptr [RBP + -0x18],0x0
SETNZ AL
MOV byte ptr [RBP + -0x35],AL
LAB_0014826f:
MOV DL,byte ptr [RBP + -0x35]
MOV EAX,0x1
XOR ECX,ECX
TEST DL,0x1
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x4],EAX
LAB_00148282:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
uint my_wc_mb_tis620(int8 param_1,ulong param_2,char *param_3,char *param_4)
{
char cVar1;
uint local_c;
if (param_3 < param_4) {
if (*(long *)(uni_to_cs + (param_2 >> 8 & 0xff) * 8) == 0) {
cVar1 = '\0';
}
else {
cVar1 = *(char *)(*(long *)(uni_to_cs + (param_2 >> 8 & 0xff) * 8) + (param_2 & 0xff));
}
*param_3 = cVar1;
local_c = (uint)(*param_3 != '\0' || param_2 == 0);
}
else {
local_c = 0xffffff9b;
}
return local_c;
}
|
|
7,881 |
non-virtual thunk to THD::exit_cond(PSI_stage_info_v1 const*, char const*, char const*, int)
|
eloqsql/sql/sql_class.h
|
inline void exit_cond(const PSI_stage_info *stage,
const char *src_function, const char *src_file,
int src_line)
{
/*
Putting the mutex unlock in thd->exit_cond() ensures that
mysys_var->current_mutex is always unlocked _before_ mysys_var->mutex is
locked (if that would not be the case, you'll get a deadlock if someone
does a THD::awake() on you).
*/
mysql_mutex_unlock(mysys_var->current_mutex);
mysql_mutex_lock(&mysys_var->mutex);
mysys_var->current_mutex = 0;
mysys_var->current_cond = 0;
if (stage)
enter_stage(stage, src_function, src_file, src_line);
mysql_mutex_unlock(&mysys_var->mutex);
return;
}
|
O0
|
c
|
non-virtual thunk to THD::exit_cond(PSI_stage_info_v1 const*, char const*, char const*, int):
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movq -0x8(%rbp), %rdi
addq $-0xe0, %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
movl -0x24(%rbp), %r8d
popq %rbp
jmp 0x8940e0
nopl (%rax)
|
_ZThn224_N3THD9exit_condEPK17PSI_stage_info_v1PKcS4_i:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_24], r8d
mov rdi, [rbp+var_8]
add rdi, 0FFFFFFFFFFFFFF20h
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov rcx, [rbp+var_20]
mov r8d, [rbp+var_24]
pop rbp
jmp _ZN3THD9exit_condEPK17PSI_stage_info_v1PKcS4_i; THD::exit_cond(PSI_stage_info_v1 const*,char const*,char const*,int)
|
long long `non-virtual thunk to'THD::exit_cond(
long long a1,
long long a2,
const char *a3,
const char *a4,
unsigned int a5)
{
return THD::exit_cond(a1 - 224, a2, a3, a4, a5);
}
|
__cxx_global_var_init.11:
PUSH RBP
MOV RBP,RSP
LEA RDI,[0x1dfbc80]
MOV ESI,0x20
CALL 0x008db920
POP RBP
RET
|
void __cxx_global_var_init_11(void)
{
time_round_mode_t::time_round_mode_t((time_round_mode_t *)&TIME_FRAC_TRUNCATE,0x20);
return;
}
|
|
7,882 |
free_block
|
eloqsql/mysys/mf_keycache.c
|
static void free_block(SIMPLE_KEY_CACHE_CB *keycache, BLOCK_LINK *block)
{
KEYCACHE_THREAD_TRACE("free block");
KEYCACHE_DBUG_PRINT("free_block",
("block %u to be freed, hash_link %p status: %u",
BLOCK_NUMBER(block), block->hash_link,
block->status));
/*
Assert that the block is not free already. And that it is in a clean
state. Note that the block might just be assigned to a hash_link and
not yet read (BLOCK_READ may not be set here). In this case a reader
is registered in the hash_link and free_block() will wait for it
below.
*/
DBUG_ASSERT((block->status & BLOCK_IN_USE) &&
!(block->status & (BLOCK_IN_EVICTION | BLOCK_IN_SWITCH |
BLOCK_REASSIGNED | BLOCK_IN_FLUSH |
BLOCK_CHANGED | BLOCK_FOR_UPDATE)));
/* Assert that the block is in a file_blocks chain. */
DBUG_ASSERT(block->prev_changed && *block->prev_changed == block);
/* Assert that the block is not in the LRU ring. */
DBUG_ASSERT(!block->next_used && !block->prev_used);
/*
IMHO the below condition (if()) makes no sense. I can't see how it
could be possible that free_block() is entered with a NULL hash_link
pointer. The only place where it can become NULL is in free_block()
(or before its first use ever, but for those blocks free_block() is
not called). I don't remove the conditional as it cannot harm, but
place an DBUG_ASSERT to confirm my hypothesis. Eventually the
condition (if()) can be removed.
*/
DBUG_ASSERT(block->hash_link && block->hash_link->block == block);
if (block->hash_link)
{
/*
While waiting for readers to finish, new readers might request the
block. But since we set block->status|= BLOCK_REASSIGNED, they
will wait on block->wqueue[COND_FOR_SAVED]. They must be signalled
later.
*/
block->status|= BLOCK_REASSIGNED;
wait_for_readers(keycache, block);
/*
The block must not have been freed by another thread. Repeat some
checks. An additional requirement is that it must be read now
(BLOCK_READ).
*/
DBUG_ASSERT(block->hash_link && block->hash_link->block == block);
DBUG_ASSERT((block->status & (BLOCK_READ | BLOCK_IN_USE |
BLOCK_REASSIGNED)) &&
!(block->status & (BLOCK_IN_EVICTION | BLOCK_IN_SWITCH |
BLOCK_IN_FLUSH | BLOCK_CHANGED |
BLOCK_FOR_UPDATE)));
DBUG_ASSERT(block->prev_changed && *block->prev_changed == block);
DBUG_ASSERT(!block->prev_used);
/*
Unset BLOCK_REASSIGNED again. If we hand the block to an evicting
thread (through unreg_request() below), other threads must not see
this flag. They could become confused.
*/
block->status&= ~BLOCK_REASSIGNED;
/*
Do not release the hash_link until the block is off all lists.
At least not if we hand it over for eviction in unreg_request().
*/
}
/*
Unregister the block request and link the block into the LRU ring.
This enables eviction for the block. If the LRU ring was empty and
threads are waiting for a block, then the block wil be handed over
for eviction immediately. Otherwise we will unlink it from the LRU
ring again, without releasing the lock in between. So decrementing
the request counter and updating statistics are the only relevant
operation in this case. Assert that there are no other requests
registered.
*/
DBUG_ASSERT(block->requests == 1);
unreg_request(keycache, block, 0);
/*
Note that even without releasing the cache lock it is possible that
the block is immediately selected for eviction by link_block() and
thus not added to the LRU ring. In this case we must not touch the
block any more.
*/
if (block->status & BLOCK_IN_EVICTION)
return;
/* Error blocks are not put into the LRU ring. */
if (!(block->status & BLOCK_ERROR))
{
/* Here the block must be in the LRU ring. Unlink it again. */
DBUG_ASSERT(block->next_used && block->prev_used &&
*block->prev_used == block);
unlink_block(keycache, block);
}
if (block->temperature == BLOCK_WARM)
keycache->warm_blocks--;
block->temperature= BLOCK_COLD;
/* Remove from file_blocks hash. */
unlink_changed(block);
/* Remove reference to block from hash table. */
unlink_hash(keycache, block->hash_link);
block->hash_link= NULL;
block->status= 0;
block->length= 0;
block->offset= keycache->key_cache_block_size;
KEYCACHE_THREAD_TRACE("free block");
KEYCACHE_DBUG_PRINT("free_block", ("block is freed"));
/* Enforced by unlink_changed(), but just to be sure. */
DBUG_ASSERT(!block->next_changed && !block->prev_changed);
/* Enforced by unlink_block(): not in LRU ring nor in free_block_list. */
DBUG_ASSERT(!block->next_used && !block->prev_used);
/* Insert the free block in the free list. */
block->next_used= keycache->free_block_list;
keycache->free_block_list= block;
/* Keep track of the number of currently unused blocks. */
keycache->blocks_unused++;
/* All pending requests for this page must be resubmitted. */
release_whole_queue(&block->wqueue[COND_FOR_SAVED]);
}
|
O3
|
c
|
free_block:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
cmpq $0x0, 0x20(%rsi)
je 0x9f8ef
orb $0x8, 0x50(%rbx)
movq %r14, %rdi
movq %rbx, %rsi
callq 0xa0147
andb $-0x9, 0x50(%rbx)
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x9f7c0
movl 0x50(%rbx), %eax
testb %al, %al
js 0x9f93a
testb $0x1, %al
jne 0x9f912
movq %r14, %rdi
movq %rbx, %rsi
callq 0xa01d0
cmpl $0x1, 0x54(%rbx)
jne 0x9f91c
decq 0x68(%r14)
movl $0x0, 0x54(%rbx)
movq 0x10(%rbx), %rcx
movq 0x18(%rbx), %rax
testq %rcx, %rcx
je 0x9f93f
movq %rax, 0x18(%rcx)
movq 0x10(%rbx), %rcx
jmp 0x9f941
popq %rbx
popq %r14
popq %rbp
retq
xorl %ecx, %ecx
movq %rcx, (%rax)
movq 0x20(%rbx), %rsi
movq %r14, %rdi
callq 0x9fee5
xorl %eax, %eax
movq %rax, 0x20(%rbx)
movq %rax, 0x4c(%rbx)
movl 0x18(%r14), %eax
movl %eax, 0x48(%rbx)
movq 0x98(%r14), %rax
movq %rax, (%rbx)
movq %rbx, 0x98(%r14)
incq 0x58(%r14)
addq $0x30, %rbx
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0xa00cd
|
free_block_0:
push rbp
mov rbp, rsp
push r14
push rbx
mov rbx, rsi
mov r14, rdi
cmp qword ptr [rsi+20h], 0
jz short loc_9F8EF
or byte ptr [rbx+50h], 8
mov rdi, r14
mov rsi, rbx
call wait_for_readers_0
and byte ptr [rbx+50h], 0F7h
loc_9F8EF:
mov rdi, r14
mov rsi, rbx
xor edx, edx
call unreg_request_0
mov eax, [rbx+50h]
test al, al
js short loc_9F93A
test al, 1
jnz short loc_9F912
mov rdi, r14
mov rsi, rbx
call unlink_block_0
loc_9F912:
cmp dword ptr [rbx+54h], 1
jnz short loc_9F91C
dec qword ptr [r14+68h]
loc_9F91C:
mov dword ptr [rbx+54h], 0
mov rcx, [rbx+10h]
mov rax, [rbx+18h]
test rcx, rcx
jz short loc_9F93F
mov [rcx+18h], rax
mov rcx, [rbx+10h]
jmp short loc_9F941
loc_9F93A:
pop rbx
pop r14
pop rbp
retn
loc_9F93F:
xor ecx, ecx
loc_9F941:
mov [rax], rcx
mov rsi, [rbx+20h]
mov rdi, r14
call unlink_hash_0
xor eax, eax
mov [rbx+20h], rax
mov [rbx+4Ch], rax
mov eax, [r14+18h]
mov [rbx+48h], eax
mov rax, [r14+98h]
mov [rbx], rax
mov [r14+98h], rbx
inc qword ptr [r14+58h]
add rbx, 30h ; '0'
mov rdi, rbx
pop rbx
pop r14
pop rbp
jmp release_whole_queue
|
long long free_block_0(long long a1, long long a2)
{
long long v2; // rdx
long long result; // rax
long long v4; // rcx
_QWORD *v5; // rax
long long v6; // rcx
if ( *(_QWORD *)(a2 + 32) )
{
*(_BYTE *)(a2 + 80) |= 8u;
wait_for_readers_0(a1, a2);
*(_BYTE *)(a2 + 80) &= ~8u;
}
unreg_request_0((_QWORD *)a1, a2, 0LL);
result = *(unsigned int *)(a2 + 80);
if ( (result & 0x80u) == 0LL )
{
if ( (result & 1) == 0 )
unlink_block_0(a1, a2, v2);
if ( *(_DWORD *)(a2 + 84) == 1 )
--*(_QWORD *)(a1 + 104);
*(_DWORD *)(a2 + 84) = 0;
v4 = *(_QWORD *)(a2 + 16);
v5 = *(_QWORD **)(a2 + 24);
if ( v4 )
{
*(_QWORD *)(v4 + 24) = v5;
v6 = *(_QWORD *)(a2 + 16);
}
else
{
v6 = 0LL;
}
*v5 = v6;
unlink_hash_0(a1, *(_QWORD *)(a2 + 32));
*(_QWORD *)(a2 + 32) = 0LL;
*(_QWORD *)(a2 + 76) = 0LL;
*(_DWORD *)(a2 + 72) = *(_DWORD *)(a1 + 24);
*(_QWORD *)a2 = *(_QWORD *)(a1 + 152);
*(_QWORD *)(a1 + 152) = a2;
++*(_QWORD *)(a1 + 88);
return release_whole_queue(a2 + 48);
}
return result;
}
|
free_block:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV RBX,RSI
MOV R14,RDI
CMP qword ptr [RSI + 0x20],0x0
JZ 0x0019f8ef
OR byte ptr [RBX + 0x50],0x8
MOV RDI,R14
MOV RSI,RBX
CALL 0x001a0147
AND byte ptr [RBX + 0x50],0xf7
LAB_0019f8ef:
MOV RDI,R14
MOV RSI,RBX
XOR EDX,EDX
CALL 0x0019f7c0
MOV EAX,dword ptr [RBX + 0x50]
TEST AL,AL
JS 0x0019f93a
TEST AL,0x1
JNZ 0x0019f912
MOV RDI,R14
MOV RSI,RBX
CALL 0x001a01d0
LAB_0019f912:
CMP dword ptr [RBX + 0x54],0x1
JNZ 0x0019f91c
DEC qword ptr [R14 + 0x68]
LAB_0019f91c:
MOV dword ptr [RBX + 0x54],0x0
MOV RCX,qword ptr [RBX + 0x10]
MOV RAX,qword ptr [RBX + 0x18]
TEST RCX,RCX
JZ 0x0019f93f
MOV qword ptr [RCX + 0x18],RAX
MOV RCX,qword ptr [RBX + 0x10]
JMP 0x0019f941
LAB_0019f93a:
POP RBX
POP R14
POP RBP
RET
LAB_0019f93f:
XOR ECX,ECX
LAB_0019f941:
MOV qword ptr [RAX],RCX
MOV RSI,qword ptr [RBX + 0x20]
MOV RDI,R14
CALL 0x0019fee5
XOR EAX,EAX
MOV qword ptr [RBX + 0x20],RAX
MOV qword ptr [RBX + 0x4c],RAX
MOV EAX,dword ptr [R14 + 0x18]
MOV dword ptr [RBX + 0x48],EAX
MOV RAX,qword ptr [R14 + 0x98]
MOV qword ptr [RBX],RAX
MOV qword ptr [R14 + 0x98],RBX
INC qword ptr [R14 + 0x58]
ADD RBX,0x30
MOV RDI,RBX
POP RBX
POP R14
POP RBP
JMP 0x001a00cd
|
void free_block(long param_1,int8 *param_2)
{
int8 *puVar1;
int8 uVar2;
if (param_2[4] != 0) {
*(byte *)(param_2 + 10) = *(byte *)(param_2 + 10) | 8;
wait_for_readers(param_1,param_2);
*(byte *)(param_2 + 10) = *(byte *)(param_2 + 10) & 0xf7;
}
unreg_request(param_1,param_2,0);
if (-1 < (char)*(uint *)(param_2 + 10)) {
if ((*(uint *)(param_2 + 10) & 1) == 0) {
unlink_block(param_1,param_2);
}
if (*(int *)((long)param_2 + 0x54) == 1) {
*(long *)(param_1 + 0x68) = *(long *)(param_1 + 0x68) + -1;
}
*(int4 *)((long)param_2 + 0x54) = 0;
puVar1 = (int8 *)param_2[3];
if (param_2[2] == 0) {
uVar2 = 0;
}
else {
*(int8 **)(param_2[2] + 0x18) = puVar1;
uVar2 = param_2[2];
}
*puVar1 = uVar2;
unlink_hash(param_1,param_2[4]);
param_2[4] = 0;
*(int8 *)((long)param_2 + 0x4c) = 0;
*(int4 *)(param_2 + 9) = *(int4 *)(param_1 + 0x18);
*param_2 = *(int8 *)(param_1 + 0x98);
*(int8 **)(param_1 + 0x98) = param_2;
*(long *)(param_1 + 0x58) = *(long *)(param_1 + 0x58) + 1;
release_whole_queue(param_2 + 6);
return;
}
return;
}
|
|
7,883 |
Simulator::getRegInfoStr[abi:cxx11]()
|
EnderturtleOrz[P]CSC3050-2025-Spring-Project-3/src/Simulator.cpp
|
std::string Simulator::getRegInfoStr() {
std::string str;
char buf[65536];
str += "------------ CPU STATE ------------\n";
sprintf(buf, "PC: 0x%llx\n", this->pc);
str += buf;
for (uint32_t i = 0; i < 32; ++i) {
sprintf(buf, "%s: 0x%.8llx(%lld) ", REGNAME[i], this->reg[i], this->reg[i]);
str += buf;
if (i % 4 == 3) {
str += "\n";
}
}
str += "-----------------------------------\n";
return str;
}
|
O0
|
cpp
|
Simulator::getRegInfoStr[abi:cxx11]():
subq $0x10058, %rsp # imm = 0x10058
movq %rdi, 0x28(%rsp)
movq %rdi, %rax
movq %rax, 0x18(%rsp)
movq %rdi, 0x10050(%rsp)
movq %rsi, 0x10048(%rsp)
movq 0x10048(%rsp), %rax
movq %rax, 0x20(%rsp)
movb $0x0, 0x10047(%rsp)
callq 0x152f0
movq 0x28(%rsp), %rdi
leaq 0x652c(%rip), %rsi # 0x29f56
callq 0x151d0
jmp 0x23a31
movq 0x20(%rsp), %rax
movq 0x8(%rax), %rdx
leaq 0x653a(%rip), %rsi # 0x29f7b
xorl %eax, %eax
leaq 0x40(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x15060
movq 0x28(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0x151d0
jmp 0x23a63
movl $0x0, 0x30(%rsp)
cmpl $0x20, 0x30(%rsp)
jae 0x23b08
movq 0x20(%rsp), %rax
movl 0x30(%rsp), %ecx
leaq 0xf7aa(%rip), %rdx # 0x33230
movq (%rdx,%rcx,8), %rdx
movq 0x10(%rax,%rcx,8), %r8
leaq 0x64f1(%rip), %rsi # 0x29f87
xorl %eax, %eax
leaq 0x40(%rsp), %rdi
movq %rdi, 0x8(%rsp)
movq %r8, %rcx
callq 0x15060
movq 0x28(%rsp), %rdi
movq 0x8(%rsp), %rsi
callq 0x151d0
jmp 0x23abb
movl 0x30(%rsp), %eax
andl $0x3, %eax
cmpl $0x3, %eax
jne 0x23af6
movq 0x28(%rsp), %rdi
leaq 0x5ae7(%rip), %rsi # 0x295ba
callq 0x151d0
jmp 0x23ada
jmp 0x23af6
movq 0x28(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x38(%rsp)
movl %eax, 0x34(%rsp)
callq 0x15140
jmp 0x23b44
jmp 0x23af8
movl 0x30(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x30(%rsp)
jmp 0x23a6b
movq 0x28(%rsp), %rdi
leaq 0x6487(%rip), %rsi # 0x29f9b
callq 0x151d0
jmp 0x23b1b
movb $0x1, 0x10047(%rsp)
testb $0x1, 0x10047(%rsp)
jne 0x23b37
movq 0x28(%rsp), %rdi
callq 0x15140
movq 0x18(%rsp), %rax
addq $0x10058, %rsp # imm = 0x10058
retq
movq 0x38(%rsp), %rdi
callq 0x153a0
nop
|
_ZN9Simulator13getRegInfoStrB5cxx11Ev:
sub rsp, 10058h
mov [rsp+10058h+var_10030], rdi
mov rax, rdi
mov [rsp+10058h+var_10040], rax
mov [rsp+10058h+var_8], rdi
mov [rsp+10058h+var_10], rsi
mov rax, [rsp+10058h+var_10]
mov [rsp+10058h+var_10038], rax
mov [rsp+10058h+var_11], 0
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev; std::string::basic_string(void)
mov rdi, [rsp+10058h+var_10030]
lea rsi, aCpuState; "------------ CPU STATE ------------\n"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc; std::string::operator+=(char const*)
jmp short $+2
loc_23A31:
mov rax, [rsp+10058h+var_10038]
mov rdx, [rax+8]
lea rsi, aPc0xLlx; "PC: 0x%llx\n"
xor eax, eax
lea rdi, [rsp+10058h+var_10018]
mov [rsp+10058h+var_10048], rdi
call _sprintf
mov rdi, [rsp+10058h+var_10030]
mov rsi, [rsp+10058h+var_10048]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc; std::string::operator+=(char const*)
jmp short $+2
loc_23A63:
mov [rsp+10058h+var_10028], 0
loc_23A6B:
cmp [rsp+10058h+var_10028], 20h ; ' '
jnb loc_23B08
mov rax, [rsp+10058h+var_10038]
mov ecx, [rsp+10058h+var_10028]
lea rdx, _ZN5RISCV7REGNAMEE; RISCV::REGNAME
mov rdx, [rdx+rcx*8]
mov r8, [rax+rcx*8+10h]
lea rsi, aS0x8llxLld; "%s: 0x%.8llx(%lld) "
xor eax, eax
lea rdi, [rsp+10058h+var_10018]
mov [rsp+10058h+var_10050], rdi
mov rcx, r8
call _sprintf
mov rdi, [rsp+10058h+var_10030]
mov rsi, [rsp+10058h+var_10050]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc; std::string::operator+=(char const*)
jmp short $+2
loc_23ABB:
mov eax, [rsp+10058h+var_10028]
and eax, 3
cmp eax, 3
jnz short loc_23AF6
mov rdi, [rsp+10058h+var_10030]
lea rsi, aMemoryInfo+0Dh; "\n"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc; std::string::operator+=(char const*)
jmp short $+2
loc_23ADA:
jmp short loc_23AF6
mov rdi, [rsp+arg_20]
mov rcx, rax
mov eax, edx
mov [rsp+arg_30], rcx
mov [rsp+arg_2C], eax
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_23B44
loc_23AF6:
jmp short $+2
loc_23AF8:
mov eax, [rsp+10058h+var_10028]
add eax, 1
mov [rsp+10058h+var_10028], eax
jmp loc_23A6B
loc_23B08:
mov rdi, [rsp+10058h+var_10030]
lea rsi, asc_29F9B; "-----------------------------------\n"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLEPKc; std::string::operator+=(char const*)
jmp short $+2
loc_23B1B:
mov [rsp+10058h+var_11], 1
test [rsp+10058h+var_11], 1
jnz short loc_23B37
mov rdi, [rsp+10058h+var_10030]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_23B37:
mov rax, [rsp+10058h+var_10040]
add rsp, 10058h
retn
loc_23B44:
mov rdi, [rsp+arg_30]
call __Unwind_Resume
|
long long Simulator::getRegInfoStr[abi:cxx11](long long a1, long long a2)
{
unsigned int i; // [rsp+30h] [rbp-10028h]
_BYTE v4[65544]; // [rsp+40h] [rbp-10018h] BYREF
long long v5; // [rsp+10048h] [rbp-10h]
long long v6; // [rsp+10050h] [rbp-8h]
v6 = a1;
v5 = a2;
v4[65543] = 0;
std::string::basic_string(a1);
std::string::operator+=(a1, "------------ CPU STATE ------------\n");
sprintf(v4, "PC: 0x%llx\n", *(_QWORD *)(a2 + 8));
std::string::operator+=(a1, v4);
for ( i = 0; i < 0x20; ++i )
{
sprintf(
v4,
"%s: 0x%.8llx(%lld) ",
(&RISCV::REGNAME)[i],
*(_QWORD *)(a2 + 8LL * i + 16),
*(_QWORD *)(a2 + 8LL * i + 16));
std::string::operator+=(a1, v4);
if ( (i & 3) == 3 )
std::string::operator+=(a1, "\n");
}
std::string::operator+=(a1, "-----------------------------------\n");
return a1;
}
|
getRegInfoStr[abi:cxx11]:
SUB RSP,0x10058
MOV qword ptr [RSP + 0x28],RDI
MOV RAX,RDI
MOV qword ptr [RSP + 0x18],RAX
MOV qword ptr [RSP + 0x10050],RDI
MOV qword ptr [RSP + 0x10048],RSI
MOV RAX,qword ptr [RSP + 0x10048]
MOV qword ptr [RSP + 0x20],RAX
MOV byte ptr [RSP + 0x10047],0x0
CALL 0x001152f0
MOV RDI,qword ptr [RSP + 0x28]
LAB_00123a23:
LEA RSI,[0x129f56]
CALL 0x001151d0
JMP 0x00123a31
LAB_00123a31:
MOV RAX,qword ptr [RSP + 0x20]
MOV RDX,qword ptr [RAX + 0x8]
LEA RSI,[0x129f7b]
XOR EAX,EAX
LEA RDI,[RSP + 0x40]
MOV qword ptr [RSP + 0x10],RDI
CALL 0x00115060
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,qword ptr [RSP + 0x10]
CALL 0x001151d0
JMP 0x00123a63
LAB_00123a63:
MOV dword ptr [RSP + 0x30],0x0
LAB_00123a6b:
CMP dword ptr [RSP + 0x30],0x20
JNC 0x00123b08
MOV RAX,qword ptr [RSP + 0x20]
MOV ECX,dword ptr [RSP + 0x30]
LEA RDX,[0x133230]
MOV RDX,qword ptr [RDX + RCX*0x8]
MOV R8,qword ptr [RAX + RCX*0x8 + 0x10]
LEA RSI,[0x129f87]
XOR EAX,EAX
LEA RDI,[RSP + 0x40]
MOV qword ptr [RSP + 0x8],RDI
MOV RCX,R8
CALL 0x00115060
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,qword ptr [RSP + 0x8]
CALL 0x001151d0
JMP 0x00123abb
LAB_00123abb:
MOV EAX,dword ptr [RSP + 0x30]
AND EAX,0x3
CMP EAX,0x3
JNZ 0x00123af6
MOV RDI,qword ptr [RSP + 0x28]
LEA RSI,[0x1295ba]
CALL 0x001151d0
JMP 0x00123ada
LAB_00123ada:
JMP 0x00123af6
LAB_00123af6:
JMP 0x00123af8
LAB_00123af8:
MOV EAX,dword ptr [RSP + 0x30]
ADD EAX,0x1
MOV dword ptr [RSP + 0x30],EAX
JMP 0x00123a6b
LAB_00123b08:
MOV RDI,qword ptr [RSP + 0x28]
LEA RSI,[0x129f9b]
CALL 0x001151d0
LAB_00123b19:
JMP 0x00123b1b
LAB_00123b1b:
MOV byte ptr [RSP + 0x10047],0x1
TEST byte ptr [RSP + 0x10047],0x1
JNZ 0x00123b37
MOV RDI,qword ptr [RSP + 0x28]
CALL 0x00115140
LAB_00123b37:
MOV RAX,qword ptr [RSP + 0x18]
ADD RSP,0x10058
RET
|
/* WARNING: Removing unreachable block (ram,0x00123b2d) */
/* Simulator::getRegInfoStr[abi:cxx11]() */
string * Simulator::getRegInfoStr_abi_cxx11_(void)
{
long in_RSI;
string *in_RDI;
uint uStack_10028;
char acStack_10018 [65560];
std::__cxx11::string::string(in_RDI);
/* try { // try from 00123a23 to 00123b18 has its CatchHandler @ 00123adc */
std::__cxx11::string::operator+=(in_RDI,"------------ CPU STATE ------------\n");
sprintf(acStack_10018,"PC: 0x%llx\n",*(int8 *)(in_RSI + 8));
std::__cxx11::string::operator+=(in_RDI,acStack_10018);
for (uStack_10028 = 0; uStack_10028 < 0x20; uStack_10028 = uStack_10028 + 1) {
sprintf(acStack_10018,"%s: 0x%.8llx(%lld) ",
*(int8 *)(RISCV::REGNAME + (ulong)uStack_10028 * 8),
*(int8 *)(in_RSI + 0x10 + (ulong)uStack_10028 * 8));
std::__cxx11::string::operator+=(in_RDI,acStack_10018);
if ((uStack_10028 & 3) == 3) {
std::__cxx11::string::operator+=(in_RDI,"\n");
}
}
std::__cxx11::string::operator+=(in_RDI,"-----------------------------------\n");
return in_RDI;
}
|
|
7,884 |
Simulator::getRegInfoStr[abi:cxx11]()
|
EnderturtleOrz[P]CSC3050-2025-Spring-Project-3/src/Simulator.cpp
|
std::string Simulator::getRegInfoStr() {
std::string str;
char buf[65536];
str += "------------ CPU STATE ------------\n";
sprintf(buf, "PC: 0x%llx\n", this->pc);
str += buf;
for (uint32_t i = 0; i < 32; ++i) {
sprintf(buf, "%s: 0x%.8llx(%lld) ", REGNAME[i], this->reg[i], this->reg[i]);
str += buf;
if (i % 4 == 3) {
str += "\n";
}
}
str += "-----------------------------------\n";
return str;
}
|
O1
|
cpp
|
Simulator::getRegInfoStr[abi:cxx11]():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10018, %rsp # imm = 0x10018
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, 0x8(%rsp)
movq %rax, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
leaq 0x3625(%rip), %rsi # 0x15cff
callq 0xb380
movq 0x8(%r14), %rdx
leaq 0x363a(%rip), %rsi # 0x15d24
leaq 0x10(%rsp), %r15
movq %r15, %rdi
xorl %eax, %eax
callq 0xb060
movq %rbx, %rdi
movq %r15, %rsi
callq 0xb380
leaq 0x9af5(%rip), %rbp # 0x1c200
leaq 0x361e(%rip), %r15 # 0x15d30
leaq 0x10(%rsp), %r12
xorl %r13d, %r13d
movq (%rbp), %rdx
movq 0x10(%r14,%r13,8), %rcx
movq %r12, %rdi
movq %r15, %rsi
movq %rcx, %r8
xorl %eax, %eax
callq 0xb060
movq %rbx, %rdi
movq %r12, %rsi
callq 0xb380
movl %r13d, %eax
notl %eax
testb $0x3, %al
jne 0x12756
movq %rbx, %rdi
leaq 0x2e3c(%rip), %rsi # 0x1558d
callq 0xb380
incq %r13
addq $0x8, %rbp
cmpq $0x20, %r13
jne 0x1271a
leaq 0x35da(%rip), %rsi # 0x15d44
movq %rbx, %rdi
callq 0xb380
movq %rbx, %rax
addq $0x10018, %rsp # imm = 0x10018
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x12789
movq %rax, %r14
movq (%rbx), %rdi
cmpq 0x8(%rsp), %rdi
je 0x1279b
callq 0xb1a0
movq %r14, %rdi
callq 0xb360
nop
|
_ZN9Simulator13getRegInfoStrB5cxx11Ev:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 10018h
mov r14, rsi
mov rbx, rdi
lea rax, [rdi+10h]
mov [rsp+10048h+var_10040], rax
mov [rdi], rax
mov qword ptr [rdi+8], 0
mov byte ptr [rdi+10h], 0
lea rsi, aCpuState; "------------ CPU STATE ------------\n"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov rdx, [r14+8]
lea rsi, aPc0xLlx; "PC: 0x%llx\n"
lea r15, [rsp+10048h+var_10038]
mov rdi, r15
xor eax, eax
call _sprintf
mov rdi, rbx
mov rsi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea rbp, _ZN5RISCV7REGNAMEE; RISCV::REGNAME
lea r15, aS0x8llxLld; "%s: 0x%.8llx(%lld) "
lea r12, [rsp+10048h+var_10038]
xor r13d, r13d
loc_1271A:
mov rdx, [rbp+0]
mov rcx, [r14+r13*8+10h]
mov rdi, r12
mov rsi, r15
mov r8, rcx
xor eax, eax
call _sprintf
mov rdi, rbx
mov rsi, r12
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov eax, r13d
not eax
test al, 3
jnz short loc_12756
mov rdi, rbx
lea rsi, aMemoryDump+0Dh; "\n"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
loc_12756:
inc r13
add rbp, 8
cmp r13, 20h ; ' '
jnz short loc_1271A
lea rsi, asc_15D44; "-----------------------------------\n"
mov rdi, rbx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov rax, rbx
add rsp, 10018h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short $+2
loc_12789:
mov r14, rax
mov rdi, [rbx]; void *
cmp rdi, [rsp+arg_0]
jz short loc_1279B
call __ZdlPv; operator delete(void *)
loc_1279B:
mov rdi, r14
call __Unwind_Resume
|
long long Simulator::getRegInfoStr[abi:cxx11](long long a1, long long a2)
{
const char **v2; // rbp
long long i; // r13
_BYTE v5[65592]; // [rsp+10h] [rbp-10038h] BYREF
*(_QWORD *)a1 = a1 + 16;
*(_QWORD *)(a1 + 8) = 0LL;
*(_BYTE *)(a1 + 16) = 0;
std::string::append(a1, "------------ CPU STATE ------------\n");
sprintf(v5, "PC: 0x%llx\n", *(_QWORD *)(a2 + 8));
std::string::append(a1, v5);
v2 = (const char **)&RISCV::REGNAME;
for ( i = 0LL; i != 32; ++i )
{
sprintf(v5, "%s: 0x%.8llx(%lld) ", *v2, *(_QWORD *)(a2 + 8 * i + 16), *(_QWORD *)(a2 + 8 * i + 16));
std::string::append(a1, v5);
if ( (~(_BYTE)i & 3) == 0 )
std::string::append(a1, "\n");
++v2;
}
std::string::append(a1, "-----------------------------------\n");
return a1;
}
|
getRegInfoStr[abi:cxx11]:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x10018
MOV R14,RSI
MOV RBX,RDI
LEA RAX,[RDI + 0x10]
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RDI],RAX
MOV qword ptr [RDI + 0x8],0x0
MOV byte ptr [RDI + 0x10],0x0
LAB_001126d3:
LEA RSI,[0x115cff]
CALL 0x0010b380
MOV RDX,qword ptr [R14 + 0x8]
LEA RSI,[0x115d24]
LEA R15,[RSP + 0x10]
MOV RDI,R15
XOR EAX,EAX
CALL 0x0010b060
MOV RDI,RBX
MOV RSI,R15
CALL 0x0010b380
LEA RBP,[0x11c200]
LEA R15,[0x115d30]
LEA R12,[RSP + 0x10]
XOR R13D,R13D
LAB_0011271a:
MOV RDX,qword ptr [RBP]
MOV RCX,qword ptr [R14 + R13*0x8 + 0x10]
MOV RDI,R12
MOV RSI,R15
MOV R8,RCX
XOR EAX,EAX
CALL 0x0010b060
LAB_00112733:
MOV RDI,RBX
MOV RSI,R12
CALL 0x0010b380
MOV EAX,R13D
NOT EAX
TEST AL,0x3
JNZ 0x00112756
MOV RDI,RBX
LEA RSI,[0x11558d]
CALL 0x0010b380
LAB_00112756:
INC R13
ADD RBP,0x8
CMP R13,0x20
JNZ 0x0011271a
LAB_00112763:
LEA RSI,[0x115d44]
MOV RDI,RBX
CALL 0x0010b380
LAB_00112772:
MOV RAX,RBX
ADD RSP,0x10018
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* Simulator::getRegInfoStr[abi:cxx11]() */
void Simulator::getRegInfoStr_abi_cxx11_(void)
{
int8 uVar1;
int **ppuVar2;
long in_RSI;
long *in_RDI;
long lVar3;
char acStack_10038 [65544];
*in_RDI = (long)(in_RDI + 2);
in_RDI[1] = 0;
*(int1 *)(in_RDI + 2) = 0;
/* try { // try from 001126d3 to 00112703 has its CatchHandler @ 00112787 */
std::__cxx11::string::append((char *)in_RDI);
sprintf(acStack_10038,"PC: 0x%llx\n",*(int8 *)(in_RSI + 8));
std::__cxx11::string::append((char *)in_RDI);
ppuVar2 = &RISCV::REGNAME;
lVar3 = 0;
do {
uVar1 = *(int8 *)(in_RSI + 0x10 + lVar3 * 8);
sprintf(acStack_10038,"%s: 0x%.8llx(%lld) ",*ppuVar2,uVar1,uVar1);
/* try { // try from 00112733 to 00112755 has its CatchHandler @ 00112789 */
std::__cxx11::string::append((char *)in_RDI);
if ((~(uint)lVar3 & 3) == 0) {
std::__cxx11::string::append((char *)in_RDI);
}
lVar3 = lVar3 + 1;
ppuVar2 = ppuVar2 + 1;
} while (lVar3 != 0x20);
/* try { // try from 00112763 to 00112771 has its CatchHandler @ 00112787 */
std::__cxx11::string::append((char *)in_RDI);
return;
}
|
|
7,885 |
Simulator::getRegInfoStr[abi:cxx11]()
|
EnderturtleOrz[P]CSC3050-2025-Spring-Project-3/src/Simulator.cpp
|
std::string Simulator::getRegInfoStr() {
std::string str;
char buf[65536];
str += "------------ CPU STATE ------------\n";
sprintf(buf, "PC: 0x%llx\n", this->pc);
str += buf;
for (uint32_t i = 0; i < 32; ++i) {
sprintf(buf, "%s: 0x%.8llx(%lld) ", REGNAME[i], this->reg[i], this->reg[i]);
str += buf;
if (i % 4 == 3) {
str += "\n";
}
}
str += "-----------------------------------\n";
return str;
}
|
O2
|
cpp
|
Simulator::getRegInfoStr[abi:cxx11]():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10008, %rsp # imm = 0x10008
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
leaq 0x34f7(%rip), %rsi # 0x15cd3
callq 0xc350
movq 0x8(%r14), %rdx
leaq 0x350c(%rip), %rsi # 0x15cf8
movq %rsp, %r15
movq %r15, %rdi
xorl %eax, %eax
callq 0xc050
movq %rbx, %rdi
movq %r15, %rsi
callq 0xc350
leaq 0x99f5(%rip), %rbp # 0x1c200
leaq 0x34f2(%rip), %r15 # 0x15d04
movq %rsp, %r12
xorl %r13d, %r13d
cmpq $0x20, %r13
je 0x12863
movq (%rbp), %rdx
movq 0x10(%r14,%r13,8), %rcx
movq %r12, %rdi
movq %r15, %rsi
movq %rcx, %r8
xorl %eax, %eax
callq 0xc050
movq %rbx, %rdi
movq %r12, %rsi
callq 0xc350
movl %r13d, %eax
notl %eax
testb $0x3, %al
jne 0x1285a
movq %rbx, %rdi
leaq 0x2d0e(%rip), %rsi # 0x15563
callq 0xc350
incq %r13
addq $0x8, %rbp
jmp 0x12818
leaq 0x34ae(%rip), %rsi # 0x15d18
movq %rbx, %rdi
callq 0xc350
movq %rbx, %rax
addq $0x10008, %rsp # imm = 0x10008
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x12889
movq %rax, %r14
movq %rbx, %rdi
callq 0xc0d0
movq %r14, %rdi
callq 0xc340
|
_ZN9Simulator13getRegInfoStrB5cxx11Ev:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 10008h
mov r14, rsi
mov rbx, rdi
lea rax, [rdi+10h]
mov [rdi], rax
and qword ptr [rdi+8], 0
mov byte ptr [rdi+10h], 0
lea rsi, aCpuState; "------------ CPU STATE ------------\n"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov rdx, [r14+8]
lea rsi, aPc0xLlx; "PC: 0x%llx\n"
mov r15, rsp
mov rdi, r15
xor eax, eax
call _sprintf
mov rdi, rbx
mov rsi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea rbp, _ZN5RISCV7REGNAMEE; RISCV::REGNAME
lea r15, aS0x8llxLld; "%s: 0x%.8llx(%lld) "
mov r12, rsp
xor r13d, r13d
loc_12818:
cmp r13, 20h ; ' '
jz short loc_12863
mov rdx, [rbp+0]
mov rcx, [r14+r13*8+10h]
mov rdi, r12
mov rsi, r15
mov r8, rcx
xor eax, eax
call _sprintf
mov rdi, rbx
mov rsi, r12
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov eax, r13d
not eax
test al, 3
jnz short loc_1285A
mov rdi, rbx
lea rsi, aMemoryDump+0Dh; "\n"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
loc_1285A:
inc r13
add rbp, 8
jmp short loc_12818
loc_12863:
lea rsi, asc_15D18; "-----------------------------------\n"
mov rdi, rbx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov rax, rbx
add rsp, 10008h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short $+2
loc_12889:
mov r14, rax
mov rdi, rbx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, r14
call __Unwind_Resume
|
long long Simulator::getRegInfoStr[abi:cxx11](long long a1, long long a2)
{
const char **v2; // rbp
long long i; // r13
_BYTE v5[65592]; // [rsp+0h] [rbp-10038h] BYREF
*(_QWORD *)a1 = a1 + 16;
*(_QWORD *)(a1 + 8) = 0LL;
*(_BYTE *)(a1 + 16) = 0;
std::string::append(a1, "------------ CPU STATE ------------\n");
sprintf(v5, "PC: 0x%llx\n", *(_QWORD *)(a2 + 8));
std::string::append(a1, v5);
v2 = (const char **)&RISCV::REGNAME;
for ( i = 0LL; i != 32; ++i )
{
sprintf(v5, "%s: 0x%.8llx(%lld) ", *v2, *(_QWORD *)(a2 + 8 * i + 16), *(_QWORD *)(a2 + 8 * i + 16));
std::string::append(a1, v5);
if ( (~(_BYTE)i & 3) == 0 )
std::string::append(a1, "\n");
++v2;
}
std::string::append(a1, "-----------------------------------\n");
return a1;
}
|
getRegInfoStr[abi:cxx11]:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x10008
MOV R14,RSI
MOV RBX,RDI
LEA RAX,[RDI + 0x10]
MOV qword ptr [RDI],RAX
AND qword ptr [RDI + 0x8],0x0
MOV byte ptr [RDI + 0x10],0x0
LAB_001127d5:
LEA RSI,[0x115cd3]
CALL 0x0010c350
MOV RDX,qword ptr [R14 + 0x8]
LEA RSI,[0x115cf8]
MOV R15,RSP
MOV RDI,R15
XOR EAX,EAX
CALL 0x0010c050
MOV RDI,RBX
MOV RSI,R15
CALL 0x0010c350
LEA RBP,[0x11c200]
LEA R15,[0x115d04]
MOV R12,RSP
XOR R13D,R13D
LAB_00112818:
CMP R13,0x20
JZ 0x00112863
MOV RDX,qword ptr [RBP]
MOV RCX,qword ptr [R14 + R13*0x8 + 0x10]
MOV RDI,R12
MOV RSI,R15
MOV R8,RCX
XOR EAX,EAX
CALL 0x0010c050
LAB_00112837:
MOV RDI,RBX
MOV RSI,R12
CALL 0x0010c350
MOV EAX,R13D
NOT EAX
TEST AL,0x3
JNZ 0x0011285a
MOV RDI,RBX
LEA RSI,[0x115563]
CALL 0x0010c350
LAB_0011285a:
INC R13
ADD RBP,0x8
JMP 0x00112818
LAB_00112863:
LEA RSI,[0x115d18]
MOV RDI,RBX
CALL 0x0010c350
LAB_00112872:
MOV RAX,RBX
ADD RSP,0x10008
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* Simulator::getRegInfoStr[abi:cxx11]() */
void Simulator::getRegInfoStr_abi_cxx11_(void)
{
int8 uVar1;
int **ppuVar2;
long in_RSI;
long *in_RDI;
long lVar3;
char acStack_10038 [65544];
*in_RDI = (long)(in_RDI + 2);
in_RDI[1] = 0;
*(int1 *)(in_RDI + 2) = 0;
/* try { // try from 001127d5 to 00112803 has its CatchHandler @ 00112887 */
std::__cxx11::string::append((char *)in_RDI);
sprintf(acStack_10038,"PC: 0x%llx\n",*(int8 *)(in_RSI + 8));
std::__cxx11::string::append((char *)in_RDI);
ppuVar2 = &RISCV::REGNAME;
for (lVar3 = 0; lVar3 != 0x20; lVar3 = lVar3 + 1) {
uVar1 = *(int8 *)(in_RSI + 0x10 + lVar3 * 8);
sprintf(acStack_10038,"%s: 0x%.8llx(%lld) ",*ppuVar2,uVar1,uVar1);
/* try { // try from 00112837 to 00112859 has its CatchHandler @ 00112889 */
std::__cxx11::string::append((char *)in_RDI);
if ((~(uint)lVar3 & 3) == 0) {
std::__cxx11::string::append((char *)in_RDI);
}
ppuVar2 = ppuVar2 + 1;
}
/* try { // try from 00112863 to 00112871 has its CatchHandler @ 00112887 */
std::__cxx11::string::append((char *)in_RDI);
return;
}
|
|
7,886 |
testing::internal::JsonUnitTestResultPrinter::PrintJsonTestList(std::ostream*, std::vector<testing::TestSuite*, std::allocator<testing::TestSuite*>> const&)
|
AlayaLite/build_O0/_deps/googletest-src/googletest/src/gtest.cc
|
void JsonUnitTestResultPrinter::PrintJsonTestList(
std::ostream* stream, const std::vector<TestSuite*>& test_suites) {
const std::string kTestsuites = "testsuites";
const std::string kIndent = Indent(2);
*stream << "{\n";
int total_tests = 0;
for (auto test_suite : test_suites) {
total_tests += test_suite->total_test_count();
}
OutputJsonKey(stream, kTestsuites, "tests", total_tests, kIndent);
OutputJsonKey(stream, kTestsuites, "name", "AllTests", kIndent);
*stream << kIndent << "\"" << kTestsuites << "\": [\n";
for (size_t i = 0; i < test_suites.size(); ++i) {
if (i != 0) {
*stream << ",\n";
}
PrintJsonTestSuite(stream, *test_suites[i]);
}
*stream << "\n"
<< kIndent << "]\n"
<< "}\n";
}
|
O0
|
cpp
|
testing::internal::JsonUnitTestResultPrinter::PrintJsonTestList(std::ostream*, std::vector<testing::TestSuite*, std::allocator<testing::TestSuite*>> const&):
subq $0x188, %rsp # imm = 0x188
movq %rdi, 0x180(%rsp)
movq %rsi, 0x178(%rsp)
leaq 0x157(%rsp), %rdi
movq %rdi, 0x70(%rsp)
callq 0xb920
movq 0x70(%rsp), %rdx
leaq 0x3aa9c(%rip), %rsi # 0x75511
leaq 0x158(%rsp), %rdi
callq 0xe840
jmp 0x3aa84
leaq 0x157(%rsp), %rdi
callq 0xb500
leaq 0x120(%rsp), %rdi
movl $0x2, %esi
callq 0x379c0
jmp 0x3aaa5
movq 0x180(%rsp), %rdi
leaq 0x3ab69(%rip), %rsi # 0x7561d
callq 0xb460
jmp 0x3aabb
movl $0x0, 0x11c(%rsp)
movq 0x178(%rsp), %rax
movq %rax, 0x110(%rsp)
movq 0x110(%rsp), %rdi
callq 0x4ccd0
movq %rax, 0x108(%rsp)
movq 0x110(%rsp), %rdi
callq 0x4cd00
movq %rax, 0x100(%rsp)
leaq 0x108(%rsp), %rdi
leaq 0x100(%rsp), %rsi
callq 0x4cd30
xorb $-0x1, %al
testb $0x1, %al
jne 0x3ab20
jmp 0x3abba
leaq 0x108(%rsp), %rdi
callq 0x4cd70
movq (%rax), %rax
movq %rax, 0xf8(%rsp)
movq 0xf8(%rsp), %rdi
callq 0x22cb0
addl 0x11c(%rsp), %eax
movl %eax, 0x11c(%rsp)
leaq 0x108(%rsp), %rdi
callq 0x4cd80
jmp 0x3ab00
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
leaq 0x157(%rsp), %rdi
callq 0xb500
jmp 0x3af64
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x3af57
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x3af4a
movq 0x180(%rsp), %rax
movq %rax, 0x60(%rsp)
leaq 0xd7(%rsp), %rdi
movq %rdi, 0x68(%rsp)
callq 0xb920
movq 0x68(%rsp), %rdx
leaq 0x3994f(%rip), %rsi # 0x74534
leaq 0xd8(%rsp), %rdi
callq 0xe840
jmp 0x3abf4
movq 0x60(%rsp), %rdi
movl 0x11c(%rsp), %ecx
leaq 0x158(%rsp), %rsi
leaq 0xd8(%rsp), %rdx
leaq 0x120(%rsp), %r8
movl $0x1, %r9d
callq 0x35890
jmp 0x3ac25
leaq 0xd8(%rsp), %rdi
callq 0xec60
leaq 0xd7(%rsp), %rdi
callq 0xb500
movq 0x180(%rsp), %rax
movq %rax, 0x50(%rsp)
leaq 0xaf(%rsp), %rdi
movq %rdi, 0x58(%rsp)
callq 0xb920
movq 0x58(%rsp), %rdx
leaq 0x3a7f9(%rip), %rsi # 0x75463
leaq 0xb0(%rsp), %rdi
callq 0xe840
jmp 0x3ac79
leaq 0x87(%rsp), %rdi
movq %rdi, 0x48(%rsp)
callq 0xb920
movq 0x48(%rsp), %rdx
leaq 0x3a8ad(%rip), %rsi # 0x75544
leaq 0x88(%rsp), %rdi
callq 0xe840
jmp 0x3aca6
movq 0x50(%rsp), %rdi
leaq 0x158(%rsp), %rsi
leaq 0xb0(%rsp), %rdx
leaq 0x88(%rsp), %rcx
leaq 0x120(%rsp), %r8
movl $0x1, %r9d
callq 0x35560
jmp 0x3acd8
leaq 0x88(%rsp), %rdi
callq 0xec60
leaq 0x87(%rsp), %rdi
callq 0xb500
leaq 0xb0(%rsp), %rdi
callq 0xec60
leaq 0xaf(%rsp), %rdi
callq 0xb500
movq 0x180(%rsp), %rdi
leaq 0x120(%rsp), %rsi
callq 0xb3f0
movq %rax, 0x40(%rsp)
jmp 0x3ad28
movq 0x40(%rsp), %rdi
leaq 0x3a924(%rip), %rsi # 0x75658
callq 0xb460
movq %rax, 0x38(%rsp)
jmp 0x3ad40
movq 0x38(%rsp), %rdi
leaq 0x158(%rsp), %rsi
callq 0xb3f0
movq %rax, 0x30(%rsp)
jmp 0x3ad59
movq 0x30(%rsp), %rdi
leaq 0x3a889(%rip), %rsi # 0x755ee
callq 0xb460
jmp 0x3ad6c
movq $0x0, 0x78(%rsp)
movq 0x78(%rsp), %rax
movq %rax, 0x28(%rsp)
movq 0x178(%rsp), %rdi
callq 0x48500
movq %rax, %rcx
movq 0x28(%rsp), %rax
cmpq %rcx, %rax
jae 0x3aec9
cmpq $0x0, 0x78(%rsp)
je 0x3ae86
movq 0x180(%rsp), %rdi
leaq 0x3a87a(%rip), %rsi # 0x75632
callq 0xb460
jmp 0x3adbf
jmp 0x3ae86
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x3adfb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
leaq 0xd8(%rsp), %rdi
callq 0xec60
leaq 0xd7(%rsp), %rdi
callq 0xb500
jmp 0x3af4a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x3ae74
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x3ae5a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
leaq 0x88(%rsp), %rdi
callq 0xec60
leaq 0x87(%rsp), %rdi
callq 0xb500
leaq 0xb0(%rsp), %rdi
callq 0xec60
leaq 0xaf(%rsp), %rdi
callq 0xb500
jmp 0x3af4a
movq 0x180(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0x178(%rsp), %rdi
movq 0x78(%rsp), %rsi
callq 0x4cda0
movq 0x20(%rsp), %rdi
movq (%rax), %rsi
callq 0x39e30
jmp 0x3aeb4
jmp 0x3aeb6
movq 0x78(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x78(%rsp)
jmp 0x3ad75
movq 0x180(%rsp), %rdi
leaq 0x3a345(%rip), %rsi # 0x7521d
callq 0xb460
movq %rax, 0x18(%rsp)
jmp 0x3aee4
movq 0x18(%rsp), %rdi
leaq 0x120(%rsp), %rsi
callq 0xb3f0
movq %rax, 0x10(%rsp)
jmp 0x3aefd
movq 0x10(%rsp), %rdi
leaq 0x3a6f5(%rip), %rsi # 0x755fe
callq 0xb460
movq %rax, 0x8(%rsp)
jmp 0x3af15
movq 0x8(%rsp), %rdi
leaq 0x3a739(%rip), %rsi # 0x7565a
callq 0xb460
jmp 0x3af28
leaq 0x120(%rsp), %rdi
callq 0xec60
leaq 0x158(%rsp), %rdi
callq 0xec60
addq $0x188, %rsp # imm = 0x188
retq
leaq 0x120(%rsp), %rdi
callq 0xec60
leaq 0x158(%rsp), %rdi
callq 0xec60
movq 0x148(%rsp), %rdi
callq 0xb910
nopw %cs:(%rax,%rax)
|
_ZN7testing8internal25JsonUnitTestResultPrinter17PrintJsonTestListEPSoRKSt6vectorIPNS_9TestSuiteESaIS5_EE:
sub rsp, 188h
mov [rsp+188h+var_8], rdi
mov [rsp+188h+var_10], rsi
lea rdi, [rsp+188h+var_31]
mov [rsp+188h+var_118], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rsp+188h+var_118]
lea rsi, aTestsuites; "testsuites"
lea rdi, [rsp+188h+var_30]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_3AA84:
lea rdi, [rsp+188h+var_31]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
lea rdi, [rsp+188h+var_68]
mov esi, 2
call _ZN7testing8internalL6IndentB5cxx11Em; testing::internal::Indent(ulong)
jmp short $+2
loc_3AAA5:
mov rdi, [rsp+188h+var_8]
lea rsi, asc_7561B+2; "{\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_3AABB:
mov [rsp+188h+var_6C], 0
mov rax, [rsp+188h+var_10]
mov [rsp+188h+var_78], rax
mov rdi, [rsp+188h+var_78]
call _ZNKSt6vectorIPN7testing9TestSuiteESaIS2_EE5beginEv; std::vector<testing::TestSuite *>::begin(void)
mov [rsp+188h+var_80], rax
mov rdi, [rsp+188h+var_78]
call _ZNKSt6vectorIPN7testing9TestSuiteESaIS2_EE3endEv; std::vector<testing::TestSuite *>::end(void)
mov [rsp+188h+var_88], rax
loc_3AB00:
lea rdi, [rsp+188h+var_80]
lea rsi, [rsp+188h+var_88]
call _ZN9__gnu_cxxeqIPKPN7testing9TestSuiteESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_QrqXeqcldtfp_4baseEcldtfp0_4baseERSt14convertible_toIbEE
xor al, 0FFh
test al, 1
jnz short loc_3AB20
jmp loc_3ABBA
loc_3AB20:
lea rdi, [rsp+188h+var_80]
call _ZNK9__gnu_cxx17__normal_iteratorIPKPN7testing9TestSuiteESt6vectorIS3_SaIS3_EEEdeEv; __gnu_cxx::__normal_iterator<testing::TestSuite * const*,std::vector<testing::TestSuite *>>::operator*(void)
mov rax, [rax]
mov [rsp+188h+var_90], rax
mov rdi, [rsp+188h+var_90]; this
call _ZNK7testing9TestSuite16total_test_countEv; testing::TestSuite::total_test_count(void)
add eax, [rsp+188h+var_6C]
mov [rsp+188h+var_6C], eax
lea rdi, [rsp+188h+var_80]
call _ZN9__gnu_cxx17__normal_iteratorIPKPN7testing9TestSuiteESt6vectorIS3_SaIS3_EEEppEv; __gnu_cxx::__normal_iterator<testing::TestSuite * const*,std::vector<testing::TestSuite *>>::operator++(void)
jmp short loc_3AB00
mov rcx, rax
mov eax, edx
mov [rsp+arg_140], rcx
mov [rsp+arg_13C], eax
lea rdi, [rsp+arg_14F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_3AF64
mov rcx, rax
mov eax, edx
mov [rsp+arg_140], rcx
mov [rsp+arg_13C], eax
jmp loc_3AF57
mov rcx, rax
mov eax, edx
mov [rsp+arg_140], rcx
mov [rsp+arg_13C], eax
jmp loc_3AF4A
loc_3ABBA:
mov rax, [rsp+188h+var_8]
mov [rsp+188h+var_128], rax
lea rdi, [rsp+188h+var_B1]
mov [rsp+188h+var_120], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rsp+188h+var_120]
lea rsi, aAlsoRunDisable+12h; "tests"
lea rdi, [rsp+188h+var_B0]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_3ABF4:
mov rdi, [rsp+188h+var_128]
mov ecx, [rsp+188h+var_6C]
lea rsi, [rsp+188h+var_30]
lea rdx, [rsp+188h+var_B0]
lea r8, [rsp+188h+var_68]
mov r9d, 1
call _ZN7testing8internal25JsonUnitTestResultPrinter13OutputJsonKeyEPSoRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESA_iSA_b; testing::internal::JsonUnitTestResultPrinter::OutputJsonKey(std::ostream *,std::string const&,std::string const&,int,std::string const&,bool)
jmp short $+2
loc_3AC25:
lea rdi, [rsp+188h+var_B0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+188h+var_B1]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rax, [rsp+188h+var_8]
mov [rsp+188h+var_138], rax
lea rdi, [rsp+188h+var_D9]
mov [rsp+188h+var_130], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rsp+188h+var_130]
lea rsi, aClassname+5; "name"
lea rdi, [rsp+188h+var_D8]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_3AC79:
lea rdi, [rsp+188h+var_101]
mov [rsp+188h+var_140], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rsp+188h+var_140]
lea rsi, aAlltests; "AllTests"
lea rdi, [rsp+188h+var_100]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_3ACA6:
mov rdi, [rsp+188h+var_138]
lea rsi, [rsp+188h+var_30]
lea rdx, [rsp+188h+var_D8]
lea rcx, [rsp+188h+var_100]
lea r8, [rsp+188h+var_68]
mov r9d, 1
call _ZN7testing8internal25JsonUnitTestResultPrinter13OutputJsonKeyEPSoRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESA_SA_SA_b; testing::internal::JsonUnitTestResultPrinter::OutputJsonKey(std::ostream *,std::string const&,std::string const&,std::string const&,std::string const&,bool)
jmp short $+2
loc_3ACD8:
lea rdi, [rsp+188h+var_100]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+188h+var_101]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
lea rdi, [rsp+188h+var_D8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+188h+var_D9]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rdi, [rsp+188h+var_8]
lea rsi, [rsp+188h+var_68]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rsp+188h+var_148], rax
jmp short $+2
loc_3AD28:
mov rdi, [rsp+188h+var_148]
lea rsi, aMessage+0Fh; "\""
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rsp+188h+var_150], rax
jmp short $+2
loc_3AD40:
mov rdi, [rsp+188h+var_150]
lea rsi, [rsp+188h+var_30]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rsp+188h+var_158], rax
jmp short $+2
loc_3AD59:
mov rdi, [rsp+188h+var_158]
lea rsi, aTestsuite_1+0Ah; "\": [\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_3AD6C:
mov [rsp+188h+var_110], 0
loc_3AD75:
mov rax, [rsp+188h+var_110]
mov [rsp+188h+var_160], rax
mov rdi, [rsp+188h+var_10]
call _ZNKSt6vectorIPN7testing9TestSuiteESaIS2_EE4sizeEv; std::vector<testing::TestSuite *>::size(void)
mov rcx, rax
mov rax, [rsp+188h+var_160]
cmp rax, rcx
jnb loc_3AEC9
cmp [rsp+188h+var_110], 0
jz loc_3AE86
mov rdi, [rsp+188h+var_8]
lea rsi, asc_75631+1; ",\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_3ADBF:
jmp loc_3AE86
mov rcx, rax
mov eax, edx
mov [rsp+arg_140], rcx
mov [rsp+arg_13C], eax
jmp short loc_3ADFB
mov rcx, rax
mov eax, edx
mov [rsp+arg_140], rcx
mov [rsp+arg_13C], eax
lea rdi, [rsp+arg_D0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_3ADFB:
lea rdi, [rsp+arg_CF]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_3AF4A
mov rcx, rax
mov eax, edx
mov [rsp+arg_140], rcx
mov [rsp+arg_13C], eax
jmp short loc_3AE74
mov rcx, rax
mov eax, edx
mov [rsp+arg_140], rcx
mov [rsp+arg_13C], eax
jmp short loc_3AE5A
mov rcx, rax
mov eax, edx
mov [rsp+arg_140], rcx
mov [rsp+arg_13C], eax
lea rdi, [rsp+arg_80]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_3AE5A:
lea rdi, [rsp+arg_7F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
lea rdi, [rsp+arg_A8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_3AE74:
lea rdi, [rsp+arg_A7]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_3AF4A
loc_3AE86:
mov rax, [rsp+188h+var_8]
mov [rsp+188h+var_168], rax
mov rdi, [rsp+188h+var_10]
mov rsi, [rsp+188h+var_110]
call _ZNKSt6vectorIPN7testing9TestSuiteESaIS2_EEixEm; std::vector<testing::TestSuite *>::operator[](ulong)
mov rdi, [rsp+188h+var_168]; this
mov rsi, [rax]; std::ostream *
call _ZN7testing8internal25JsonUnitTestResultPrinter18PrintJsonTestSuiteEPSoRKNS_9TestSuiteE; testing::internal::JsonUnitTestResultPrinter::PrintJsonTestSuite(std::ostream *,testing::TestSuite const&)
jmp short $+2
loc_3AEB4:
jmp short $+2
loc_3AEB6:
mov rax, [rsp+188h+var_110]
add rax, 1
mov [rsp+188h+var_110], rax
jmp loc_3AD75
loc_3AEC9:
mov rdi, [rsp+188h+var_8]
lea rsi, aSFromSSMsTotal+19h; "\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rsp+188h+var_170], rax
jmp short $+2
loc_3AEE4:
mov rdi, [rsp+188h+var_170]
lea rsi, [rsp+188h+var_68]
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov [rsp+188h+var_178], rax
jmp short $+2
loc_3AEFD:
mov rdi, [rsp+188h+var_178]
lea rsi, asc_755FE; "]\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rsp+188h+var_180], rax
jmp short $+2
loc_3AF15:
mov rdi, [rsp+188h+var_180]
lea rsi, asc_7565A; "}\n"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
jmp short $+2
loc_3AF28:
lea rdi, [rsp+188h+var_68]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+188h+var_30]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
add rsp, 188h
retn
loc_3AF4A:
lea rdi, [rsp+arg_118]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_3AF57:
lea rdi, [rsp+arg_150]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_3AF64:
mov rdi, [rsp+arg_140]
call __Unwind_Resume
|
void testing::internal::JsonUnitTestResultPrinter::PrintJsonTestList(
testing::internal::JsonUnitTestResultPrinter *a1,
long long a2,
long long a3)
{
long long v3; // rdx
long long v4; // rdx
int v5; // eax
long long v6; // rdx
long long v7; // rdx
std::ostream **v8; // rax
const testing::TestSuite *v9; // rdx
long long v10; // [rsp+8h] [rbp-180h]
long long v11; // [rsp+10h] [rbp-178h]
long long v12; // [rsp+18h] [rbp-170h]
testing::internal::JsonUnitTestResultPrinter *v13; // [rsp+20h] [rbp-168h]
long long v14; // [rsp+30h] [rbp-158h]
long long v15; // [rsp+38h] [rbp-150h]
long long v16; // [rsp+40h] [rbp-148h]
long long v17; // [rsp+50h] [rbp-138h]
long long v18; // [rsp+60h] [rbp-128h]
unsigned long long i; // [rsp+78h] [rbp-110h]
char v20; // [rsp+87h] [rbp-101h] BYREF
_BYTE v21[39]; // [rsp+88h] [rbp-100h] BYREF
char v22; // [rsp+AFh] [rbp-D9h] BYREF
_BYTE v23[39]; // [rsp+B0h] [rbp-D8h] BYREF
char v24; // [rsp+D7h] [rbp-B1h] BYREF
_BYTE v25[32]; // [rsp+D8h] [rbp-B0h] BYREF
testing::TestSuite *v26; // [rsp+F8h] [rbp-90h]
long long v27; // [rsp+100h] [rbp-88h] BYREF
long long v28; // [rsp+108h] [rbp-80h] BYREF
long long v29; // [rsp+110h] [rbp-78h]
int v30; // [rsp+11Ch] [rbp-6Ch]
_BYTE v31[55]; // [rsp+120h] [rbp-68h] BYREF
char v32; // [rsp+157h] [rbp-31h] BYREF
_BYTE v33[32]; // [rsp+158h] [rbp-30h] BYREF
long long v34; // [rsp+178h] [rbp-10h]
testing::internal::JsonUnitTestResultPrinter *v35; // [rsp+180h] [rbp-8h]
v35 = a1;
v34 = a2;
std::allocator<char>::allocator(&v32, a2, a3);
std::string::basic_string<std::allocator<char>>((long long)v33, (long long)"testsuites", (long long)&v32);
std::allocator<char>::~allocator(&v32, "testsuites");
testing::internal::Indent[abi:cxx11]((long long)v31, 2LL, v3);
std::operator<<<std::char_traits<char>>(v35, "{\n");
v30 = 0;
v29 = v34;
v28 = std::vector<testing::TestSuite *>::begin(v34);
v27 = std::vector<testing::TestSuite *>::end(v29);
while ( (__gnu_cxx::operator==<testing::TestSuite * const*,std::vector<testing::TestSuite *>>(&v28, &v27) & 1) == 0 )
{
v26 = *(testing::TestSuite **)__gnu_cxx::__normal_iterator<testing::TestSuite * const*,std::vector<testing::TestSuite *>>::operator*(&v28);
v5 = testing::TestSuite::total_test_count(v26);
v30 += v5;
__gnu_cxx::__normal_iterator<testing::TestSuite * const*,std::vector<testing::TestSuite *>>::operator++(&v28);
}
v18 = (long long)v35;
std::allocator<char>::allocator(&v24, &v27, v4);
std::string::basic_string<std::allocator<char>>((long long)v25, (long long)"tests", (long long)&v24);
testing::internal::JsonUnitTestResultPrinter::OutputJsonKey(v18, (long long)v33, (long long)v25, v30, (long long)v31, 1);
std::string::~string(v25);
std::allocator<char>::~allocator(&v24, v33);
v17 = (long long)v35;
std::allocator<char>::allocator(&v22, v33, v6);
std::string::basic_string<std::allocator<char>>((long long)v23, (long long)"name", (long long)&v22);
std::allocator<char>::allocator(&v20, "name", v7);
std::string::basic_string<std::allocator<char>>((long long)v21, (long long)"AllTests", (long long)&v20);
testing::internal::JsonUnitTestResultPrinter::OutputJsonKey(
v17,
(long long)v33,
(long long)v23,
(long long)v21,
(long long)v31,
1);
std::string::~string(v21);
std::allocator<char>::~allocator(&v20, v33);
std::string::~string(v23);
std::allocator<char>::~allocator(&v22, v33);
v16 = std::operator<<<char>(v35, v31);
v15 = std::operator<<<std::char_traits<char>>(v16, "\"");
v14 = std::operator<<<char>(v15, v33);
std::operator<<<std::char_traits<char>>(v14, "\": [\n");
for ( i = 0LL; i < std::vector<testing::TestSuite *>::size(v34); ++i )
{
if ( i )
std::operator<<<std::char_traits<char>>(v35, ",\n");
v13 = v35;
v8 = (std::ostream **)std::vector<testing::TestSuite *>::operator[](v34, i);
testing::internal::JsonUnitTestResultPrinter::PrintJsonTestSuite(v13, *v8, v9);
}
v12 = std::operator<<<std::char_traits<char>>(v35, "\n");
v11 = std::operator<<<char>(v12, v31);
v10 = std::operator<<<std::char_traits<char>>(v11, "]\n");
std::operator<<<std::char_traits<char>>(v10, "}\n");
std::string::~string(v31);
std::string::~string(v33);
}
|
PrintJsonTestList:
SUB RSP,0x188
MOV qword ptr [RSP + 0x180],RDI
MOV qword ptr [RSP + 0x178],RSI
LEA RDI,[RSP + 0x157]
MOV qword ptr [RSP + 0x70],RDI
CALL 0x0010b920
MOV RDX,qword ptr [RSP + 0x70]
LAB_0013aa6e:
LEA RSI,[0x175511]
LEA RDI,[RSP + 0x158]
CALL 0x0010e840
JMP 0x0013aa84
LAB_0013aa84:
LEA RDI,[RSP + 0x157]
CALL 0x0010b500
LAB_0013aa91:
LEA RDI,[RSP + 0x120]
MOV ESI,0x2
CALL 0x001379c0
JMP 0x0013aaa5
LAB_0013aaa5:
MOV RDI,qword ptr [RSP + 0x180]
LAB_0013aaad:
LEA RSI,[0x17561d]
CALL 0x0010b460
JMP 0x0013aabb
LAB_0013aabb:
MOV dword ptr [RSP + 0x11c],0x0
MOV RAX,qword ptr [RSP + 0x178]
MOV qword ptr [RSP + 0x110],RAX
MOV RDI,qword ptr [RSP + 0x110]
CALL 0x0014ccd0
MOV qword ptr [RSP + 0x108],RAX
MOV RDI,qword ptr [RSP + 0x110]
CALL 0x0014cd00
MOV qword ptr [RSP + 0x100],RAX
LAB_0013ab00:
LEA RDI,[RSP + 0x108]
LEA RSI,[RSP + 0x100]
CALL 0x0014cd30
XOR AL,0xff
TEST AL,0x1
JNZ 0x0013ab20
JMP 0x0013abba
LAB_0013ab20:
LEA RDI,[RSP + 0x108]
CALL 0x0014cd70
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0xf8],RAX
MOV RDI,qword ptr [RSP + 0xf8]
CALL 0x00122cb0
ADD EAX,dword ptr [RSP + 0x11c]
MOV dword ptr [RSP + 0x11c],EAX
LEA RDI,[RSP + 0x108]
CALL 0x0014cd80
JMP 0x0013ab00
LAB_0013abba:
MOV RAX,qword ptr [RSP + 0x180]
MOV qword ptr [RSP + 0x60],RAX
LEA RDI,[RSP + 0xd7]
MOV qword ptr [RSP + 0x68],RDI
CALL 0x0010b920
MOV RDX,qword ptr [RSP + 0x68]
LAB_0013abde:
LEA RSI,[0x174534]
LEA RDI,[RSP + 0xd8]
CALL 0x0010e840
JMP 0x0013abf4
LAB_0013abf4:
MOV RDI,qword ptr [RSP + 0x60]
MOV ECX,dword ptr [RSP + 0x11c]
LAB_0013ac00:
LEA RSI,[RSP + 0x158]
LEA RDX,[RSP + 0xd8]
LEA R8,[RSP + 0x120]
MOV R9D,0x1
CALL 0x00135890
JMP 0x0013ac25
LAB_0013ac25:
LEA RDI,[RSP + 0xd8]
CALL 0x0010ec60
LEA RDI,[RSP + 0xd7]
CALL 0x0010b500
MOV RAX,qword ptr [RSP + 0x180]
MOV qword ptr [RSP + 0x50],RAX
LEA RDI,[RSP + 0xaf]
MOV qword ptr [RSP + 0x58],RDI
CALL 0x0010b920
MOV RDX,qword ptr [RSP + 0x58]
LAB_0013ac63:
LEA RSI,[0x175463]
LEA RDI,[RSP + 0xb0]
CALL 0x0010e840
JMP 0x0013ac79
LAB_0013ac79:
LEA RDI,[RSP + 0x87]
MOV qword ptr [RSP + 0x48],RDI
CALL 0x0010b920
MOV RDX,qword ptr [RSP + 0x48]
LAB_0013ac90:
LEA RSI,[0x175544]
LEA RDI,[RSP + 0x88]
CALL 0x0010e840
JMP 0x0013aca6
LAB_0013aca6:
MOV RDI,qword ptr [RSP + 0x50]
LEA RSI,[RSP + 0x158]
LEA RDX,[RSP + 0xb0]
LEA RCX,[RSP + 0x88]
LEA R8,[RSP + 0x120]
MOV R9D,0x1
CALL 0x00135560
JMP 0x0013acd8
LAB_0013acd8:
LEA RDI,[RSP + 0x88]
CALL 0x0010ec60
LEA RDI,[RSP + 0x87]
CALL 0x0010b500
LEA RDI,[RSP + 0xb0]
CALL 0x0010ec60
LEA RDI,[RSP + 0xaf]
CALL 0x0010b500
MOV RDI,qword ptr [RSP + 0x180]
LAB_0013ad14:
LEA RSI,[RSP + 0x120]
CALL 0x0010b3f0
MOV qword ptr [RSP + 0x40],RAX
JMP 0x0013ad28
LAB_0013ad28:
MOV RDI,qword ptr [RSP + 0x40]
LEA RSI,[0x175658]
CALL 0x0010b460
MOV qword ptr [RSP + 0x38],RAX
JMP 0x0013ad40
LAB_0013ad40:
MOV RDI,qword ptr [RSP + 0x38]
LEA RSI,[RSP + 0x158]
CALL 0x0010b3f0
MOV qword ptr [RSP + 0x30],RAX
JMP 0x0013ad59
LAB_0013ad59:
MOV RDI,qword ptr [RSP + 0x30]
LEA RSI,[0x1755ee]
CALL 0x0010b460
JMP 0x0013ad6c
LAB_0013ad6c:
MOV qword ptr [RSP + 0x78],0x0
LAB_0013ad75:
MOV RAX,qword ptr [RSP + 0x78]
MOV qword ptr [RSP + 0x28],RAX
MOV RDI,qword ptr [RSP + 0x178]
CALL 0x00148500
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x28]
CMP RAX,RCX
JNC 0x0013aec9
CMP qword ptr [RSP + 0x78],0x0
JZ 0x0013ae86
MOV RDI,qword ptr [RSP + 0x180]
LEA RSI,[0x175632]
CALL 0x0010b460
JMP 0x0013adbf
LAB_0013adbf:
JMP 0x0013ae86
LAB_0013ae86:
MOV RAX,qword ptr [RSP + 0x180]
MOV qword ptr [RSP + 0x20],RAX
MOV RDI,qword ptr [RSP + 0x178]
MOV RSI,qword ptr [RSP + 0x78]
CALL 0x0014cda0
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RAX]
CALL 0x00139e30
JMP 0x0013aeb4
LAB_0013aeb4:
JMP 0x0013aeb6
LAB_0013aeb6:
MOV RAX,qword ptr [RSP + 0x78]
ADD RAX,0x1
MOV qword ptr [RSP + 0x78],RAX
JMP 0x0013ad75
LAB_0013aec9:
MOV RDI,qword ptr [RSP + 0x180]
LEA RSI,[0x17521d]
CALL 0x0010b460
MOV qword ptr [RSP + 0x18],RAX
JMP 0x0013aee4
LAB_0013aee4:
MOV RDI,qword ptr [RSP + 0x18]
LEA RSI,[RSP + 0x120]
CALL 0x0010b3f0
MOV qword ptr [RSP + 0x10],RAX
JMP 0x0013aefd
LAB_0013aefd:
MOV RDI,qword ptr [RSP + 0x10]
LEA RSI,[0x1755fe]
CALL 0x0010b460
MOV qword ptr [RSP + 0x8],RAX
JMP 0x0013af15
LAB_0013af15:
MOV RDI,qword ptr [RSP + 0x8]
LEA RSI,[0x17565a]
CALL 0x0010b460
LAB_0013af26:
JMP 0x0013af28
LAB_0013af28:
LEA RDI,[RSP + 0x120]
CALL 0x0010ec60
LEA RDI,[RSP + 0x158]
CALL 0x0010ec60
ADD RSP,0x188
RET
|
/* testing::internal::JsonUnitTestResultPrinter::PrintJsonTestList(std::ostream*,
std::vector<testing::TestSuite*, std::allocator<testing::TestSuite*> > const&) */
void testing::internal::JsonUnitTestResultPrinter::PrintJsonTestList
(ostream *param_1,vector *param_2)
{
byte bVar1;
int iVar2;
ostream *poVar3;
ulong uVar4;
int8 *puVar5;
ulong local_110;
allocator local_101;
string local_100 [39];
allocator local_d9;
string local_d8 [39];
allocator local_b1;
string local_b0 [32];
TestSuite *local_90;
int8 local_88;
int8 local_80;
vector<testing::TestSuite*,std::allocator<testing::TestSuite*>> *local_78;
int local_6c;
internal local_68 [55];
allocator local_31;
string local_30 [32];
vector *local_10;
ostream *local_8;
local_10 = param_2;
local_8 = param_1;
std::allocator<char>::allocator();
/* try { // try from 0013aa6e to 0013aa81 has its CatchHandler @ 0013ab62 */
std::__cxx11::string::string<std::allocator<char>>(local_30,"testsuites",&local_31);
std::allocator<char>::~allocator((allocator<char> *)&local_31);
/* try { // try from 0013aa91 to 0013aaa2 has its CatchHandler @ 0013ab88 */
Indent_abi_cxx11_(local_68,2);
/* try { // try from 0013aaad to 0013aab8 has its CatchHandler @ 0013aba1 */
std::operator<<(local_8,"{\n");
local_6c = 0;
local_78 = (vector<testing::TestSuite*,std::allocator<testing::TestSuite*>> *)local_10;
local_80 = std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>::begin
((vector<testing::TestSuite*,std::allocator<testing::TestSuite*>> *)local_10)
;
local_88 = std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>::end(local_78);
while( true ) {
bVar1 = _ZN9__gnu_cxxeqIPKPN7testing9TestSuiteESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_QrqXeqcldtfp_4baseEcldtfp0_4baseERSt14convertible_toIbEE
(&local_80,&local_88);
poVar3 = local_8;
if (((bVar1 ^ 0xff) & 1) == 0) break;
puVar5 = (int8 *)
__gnu_cxx::
__normal_iterator<testing::TestSuite*const*,std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>>
::operator*((__normal_iterator<testing::TestSuite*const*,std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>>
*)&local_80);
local_90 = (TestSuite *)*puVar5;
iVar2 = TestSuite::total_test_count(local_90);
local_6c = iVar2 + local_6c;
__gnu_cxx::
__normal_iterator<testing::TestSuite*const*,std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>>
::operator++((__normal_iterator<testing::TestSuite*const*,std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>>
*)&local_80);
}
std::allocator<char>::allocator();
/* try { // try from 0013abde to 0013abf1 has its CatchHandler @ 0013adc4 */
std::__cxx11::string::string<std::allocator<char>>(local_b0,"tests",&local_b1);
/* try { // try from 0013ac00 to 0013ac22 has its CatchHandler @ 0013adda */
OutputJsonKey(poVar3,local_30,local_b0,local_6c,(string *)local_68,true);
std::__cxx11::string::~string(local_b0);
std::allocator<char>::~allocator((allocator<char> *)&local_b1);
poVar3 = local_8;
std::allocator<char>::allocator();
/* try { // try from 0013ac63 to 0013ac76 has its CatchHandler @ 0013ae0d */
std::__cxx11::string::string<std::allocator<char>>(local_d8,"name",&local_d9);
std::allocator<char>::allocator();
/* try { // try from 0013ac90 to 0013aca3 has its CatchHandler @ 0013ae23 */
std::__cxx11::string::string<std::allocator<char>>(local_100,"AllTests",&local_101);
/* try { // try from 0013aca6 to 0013acd5 has its CatchHandler @ 0013ae39 */
OutputJsonKey(poVar3,local_30,local_d8,local_100,(string *)local_68,true);
std::__cxx11::string::~string(local_100);
std::allocator<char>::~allocator((allocator<char> *)&local_101);
std::__cxx11::string::~string(local_d8);
std::allocator<char>::~allocator((allocator<char> *)&local_d9);
/* try { // try from 0013ad14 to 0013af25 has its CatchHandler @ 0013aba1 */
poVar3 = std::operator<<(local_8,(string *)local_68);
poVar3 = std::operator<<(poVar3,"\"");
poVar3 = std::operator<<(poVar3,local_30);
std::operator<<(poVar3,"\": [\n");
local_110 = 0;
while( true ) {
uVar4 = std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>::size
((vector<testing::TestSuite*,std::allocator<testing::TestSuite*>> *)local_10);
if (uVar4 <= local_110) break;
if (local_110 != 0) {
std::operator<<(local_8,",\n");
}
poVar3 = local_8;
puVar5 = (int8 *)
std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>::operator[]
((vector<testing::TestSuite*,std::allocator<testing::TestSuite*>> *)local_10,
local_110);
PrintJsonTestSuite(poVar3,(TestSuite *)*puVar5);
local_110 = local_110 + 1;
}
poVar3 = std::operator<<(local_8,"\n");
poVar3 = std::operator<<(poVar3,(string *)local_68);
poVar3 = std::operator<<(poVar3,"]\n");
std::operator<<(poVar3,"}\n");
std::__cxx11::string::~string((string *)local_68);
std::__cxx11::string::~string(local_30);
return;
}
|
|
7,887 |
lex2str
|
eloqsql/strings/xml.c
|
static const char *lex2str(int lex)
{
switch(lex)
{
case MY_XML_EOF: return "END-OF-INPUT";
case MY_XML_STRING: return "STRING";
case MY_XML_IDENT: return "IDENT";
case MY_XML_CDATA: return "CDATA";
case MY_XML_EQ: return "'='";
case MY_XML_LT: return "'<'";
case MY_XML_GT: return "'>'";
case MY_XML_SLASH: return "'/'";
case MY_XML_COMMENT: return "COMMENT";
case MY_XML_TEXT: return "TEXT";
case MY_XML_QUESTION: return "'?'";
case MY_XML_EXCLAM: return "'!'";
}
return "unknown token";
}
|
O3
|
c
|
lex2str:
pushq %rbp
movq %rsp, %rbp
leal -0x3c(%rdi), %eax
cmpl $0x18, %eax
ja 0xd79ff
leaq 0x284413(%rip), %rcx # 0x35be00
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x8ecc(%rip), %rax # 0xe08c9
jmp 0xd7a73
cmpl $0x21, %edi
je 0xd7a6c
cmpl $0x2f, %edi
jne 0xd7a12
leaq 0x8ec1(%rip), %rax # 0xe08d1
jmp 0xd7a73
leaq 0x8ed1(%rip), %rax # 0xe08ea
jmp 0xd7a73
leaq 0x8e97(%rip), %rax # 0xe08b9
jmp 0xd7a73
leaq 0x8e87(%rip), %rax # 0xe08b2
jmp 0xd7a73
leaq 0x8eae(%rip), %rax # 0xe08e2
jmp 0xd7a73
leaq 0x8e88(%rip), %rax # 0xe08c5
jmp 0xd7a73
leaq 0x8e87(%rip), %rax # 0xe08cd
jmp 0xd7a73
leaq 0x8e86(%rip), %rax # 0xe08d5
jmp 0xd7a73
leaq 0x8e33(%rip), %rax # 0xe088b
jmp 0xd7a73
leaq 0x8e5e(%rip), %rax # 0xe08bf
jmp 0xd7a73
leaq 0x8e73(%rip), %rax # 0xe08dd
jmp 0xd7a73
leaq 0x8e73(%rip), %rax # 0xe08e6
popq %rbp
retq
|
lex2str:
push rbp
mov rbp, rsp
lea eax, [rdi-3Ch]; switch 25 cases
cmp eax, 18h
ja short def_D79F4; jumptable 00000000000D79F4 default case
lea rcx, jpt_D79F4
movsxd rax, ds:(jpt_D79F4 - 35BE00h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_D79F6:
lea rax, asc_E08C9; jumptable 00000000000D79F4 case 60
jmp short loc_D7A73
def_D79F4:
cmp edi, 21h ; '!'; jumptable 00000000000D79F4 default case
jz short loc_D7A6C
cmp edi, 2Fh ; '/'
jnz short loc_D7A12; jumptable 00000000000D79F4 cases 64-66,70-72,74-82
lea rax, asc_E08D1; "'/'"
jmp short loc_D7A73
loc_D7A12:
lea rax, aUnknownToken; jumptable 00000000000D79F4 cases 64-66,70-72,74-82
jmp short loc_D7A73
loc_D7A1B:
lea rax, aIdent; jumptable 00000000000D79F4 case 73
jmp short loc_D7A73
loc_D7A24:
lea rax, aString; jumptable 00000000000D79F4 case 83
jmp short loc_D7A73
loc_D7A2D:
lea rax, asc_E08E2; jumptable 00000000000D79F4 case 63
jmp short loc_D7A73
loc_D7A36:
lea rax, asc_E08C5; jumptable 00000000000D79F4 case 61
jmp short loc_D7A73
loc_D7A3F:
lea rax, asc_E08CD; jumptable 00000000000D79F4 case 62
jmp short loc_D7A73
loc_D7A48:
lea rax, aComment; jumptable 00000000000D79F4 case 67
jmp short loc_D7A73
loc_D7A51:
lea rax, aUnexpectedEndO+0Bh; jumptable 00000000000D79F4 case 69
jmp short loc_D7A73
loc_D7A5A:
lea rax, aCdata; jumptable 00000000000D79F4 case 68
jmp short loc_D7A73
loc_D7A63:
lea rax, aText; jumptable 00000000000D79F4 case 84
jmp short loc_D7A73
loc_D7A6C:
lea rax, asc_E08E6; "'!'"
loc_D7A73:
pop rbp
retn
|
char * lex2str(int a1)
{
char *result; // rax
switch ( a1 )
{
case '<':
result = "'<'";
break;
case '=':
result = "'='";
break;
case '>':
result = "'>'";
break;
case '?':
result = "'?'";
break;
case '@':
case 'A':
case 'B':
case 'F':
case 'G':
case 'H':
case 'J':
case 'K':
case 'L':
case 'M':
case 'N':
case 'O':
case 'P':
case 'Q':
case 'R':
goto LABEL_6;
case 'C':
result = "COMMENT";
break;
case 'D':
result = "CDATA";
break;
case 'E':
result = "END-OF-INPUT";
break;
case 'I':
result = "IDENT";
break;
case 'S':
result = "STRING";
break;
case 'T':
result = "TEXT";
break;
default:
if ( a1 == 33 )
{
result = "'!'";
}
else if ( a1 == 47 )
{
result = "'/'";
}
else
{
LABEL_6:
result = "unknown token";
}
break;
}
return result;
}
|
lex2str:
PUSH RBP
MOV RBP,RSP
LEA EAX,[RDI + -0x3c]
CMP EAX,0x18
JA 0x001d79ff
LEA RCX,[0x45be00]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_3c:
LEA RAX,[0x1e08c9]
JMP 0x001d7a73
default:
CMP EDI,0x21
JZ 0x001d7a6c
CMP EDI,0x2f
JNZ 0x001d7a12
LEA RAX,[0x1e08d1]
JMP 0x001d7a73
caseD_40:
LEA RAX,[0x1e08ea]
JMP 0x001d7a73
caseD_49:
LEA RAX,[0x1e08b9]
JMP 0x001d7a73
caseD_53:
LEA RAX,[0x1e08b2]
JMP 0x001d7a73
caseD_3f:
LEA RAX,[0x1e08e2]
JMP 0x001d7a73
caseD_3d:
LEA RAX,[0x1e08c5]
JMP 0x001d7a73
caseD_3e:
LEA RAX,[0x1e08cd]
JMP 0x001d7a73
caseD_43:
LEA RAX,[0x1e08d5]
JMP 0x001d7a73
caseD_45:
LEA RAX,[0x1e088b]
JMP 0x001d7a73
caseD_44:
LEA RAX,[0x1e08bf]
JMP 0x001d7a73
caseD_54:
LEA RAX,[0x1e08dd]
JMP 0x001d7a73
LAB_001d7a6c:
LEA RAX,[0x1e08e6]
LAB_001d7a73:
POP RBP
RET
|
char * lex2str(int param_1)
{
char *pcVar1;
switch(param_1) {
case 0x3c:
pcVar1 = "\'<\'";
break;
case 0x3d:
pcVar1 = "\'=\'";
break;
case 0x3e:
pcVar1 = "\'>\'";
break;
case 0x3f:
pcVar1 = "\'?\'";
break;
case 0x43:
pcVar1 = "COMMENT";
break;
case 0x44:
pcVar1 = "CDATA";
break;
case 0x45:
pcVar1 = "END-OF-INPUT";
break;
case 0x49:
pcVar1 = "IDENT";
break;
case 0x53:
pcVar1 = "STRING";
break;
case 0x54:
pcVar1 = "TEXT";
break;
default:
if (param_1 == 0x21) {
return "\'!\'";
}
if (param_1 == 0x2f) {
return "\'/\'";
}
case 0x40:
case 0x41:
case 0x42:
case 0x46:
case 0x47:
case 0x48:
case 0x4a:
case 0x4b:
case 0x4c:
case 0x4d:
case 0x4e:
case 0x4f:
case 0x50:
case 0x51:
case 0x52:
pcVar1 = "unknown token";
}
return pcVar1;
}
|
|
7,888 |
size_to_tail_pattern
|
eloqsql/storage/maria/ma_bitmap.c
|
static uint size_to_tail_pattern(MARIA_FILE_BITMAP *bitmap, uint size)
{
if (size <= bitmap->sizes[6])
return 6;
if (size <= bitmap->sizes[5])
return 5;
DBUG_ASSERT(size <= bitmap->sizes[0]);
return 0;
}
|
O0
|
c
|
size_to_tail_pattern:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl -0x14(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x120(%rcx), %eax
ja 0x456c3
movl $0x6, -0x4(%rbp)
jmp 0x456e6
movl -0x14(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x11c(%rcx), %eax
ja 0x456db
movl $0x5, -0x4(%rbp)
jmp 0x456e6
jmp 0x456dd
jmp 0x456df
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax,%rax)
|
size_to_tail_pattern:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov eax, [rbp+var_14]
mov rcx, [rbp+var_10]
cmp eax, [rcx+120h]
ja short loc_456C3
mov [rbp+var_4], 6
jmp short loc_456E6
loc_456C3:
mov eax, [rbp+var_14]
mov rcx, [rbp+var_10]
cmp eax, [rcx+11Ch]
ja short loc_456DB
mov [rbp+var_4], 5
jmp short loc_456E6
loc_456DB:
jmp short $+2
loc_456DD:
jmp short $+2
loc_456DF:
mov [rbp+var_4], 0
loc_456E6:
mov eax, [rbp+var_4]
pop rbp
retn
|
long long size_to_tail_pattern(long long a1, unsigned int a2)
{
if ( a2 > *(_DWORD *)(a1 + 288) )
{
if ( a2 > *(_DWORD *)(a1 + 284) )
return 0;
else
return 5;
}
else
{
return 6;
}
}
|
size_to_tail_pattern:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV EAX,dword ptr [RBP + -0x14]
MOV RCX,qword ptr [RBP + -0x10]
CMP EAX,dword ptr [RCX + 0x120]
JA 0x001456c3
MOV dword ptr [RBP + -0x4],0x6
JMP 0x001456e6
LAB_001456c3:
MOV EAX,dword ptr [RBP + -0x14]
MOV RCX,qword ptr [RBP + -0x10]
CMP EAX,dword ptr [RCX + 0x11c]
JA 0x001456db
MOV dword ptr [RBP + -0x4],0x5
JMP 0x001456e6
LAB_001456db:
JMP 0x001456dd
LAB_001456dd:
JMP 0x001456df
LAB_001456df:
MOV dword ptr [RBP + -0x4],0x0
LAB_001456e6:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int4 size_to_tail_pattern(long param_1,uint param_2)
{
int4 local_c;
if (*(uint *)(param_1 + 0x120) < param_2) {
if (*(uint *)(param_1 + 0x11c) < param_2) {
local_c = 0;
}
else {
local_c = 5;
}
}
else {
local_c = 6;
}
return local_c;
}
|
|
7,889 |
google::protobuf::compiler::cpp::(anonymous namespace)::SortFieldsByNumber(google::protobuf::Descriptor const*)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/cpp/message.cc
|
std::vector<const FieldDescriptor*> SortFieldsByNumber(
const Descriptor* descriptor) {
std::vector<const FieldDescriptor*> fields(descriptor->field_count());
for (int i = 0; i < descriptor->field_count(); i++) {
fields[i] = descriptor->field(i);
}
std::sort(fields.begin(), fields.end(), FieldOrderingByNumber());
return fields;
}
|
O3
|
cpp
|
google::protobuf::compiler::cpp::(anonymous namespace)::SortFieldsByNumber(google::protobuf::Descriptor const*):
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movslq 0x4(%rsi), %rsi
leaq 0xf(%rsp), %rdx
callq 0x90eac
movslq 0x4(%r14), %rax
testq %rax, %rax
jle 0x8ec60
xorl %ecx, %ecx
leaq (%rcx,%rcx,8), %rdx
shlq $0x3, %rdx
addq 0x28(%r14), %rdx
movq (%rbx), %rsi
movq %rdx, (%rsi,%rcx,8)
incq %rcx
cmpq %rax, %rcx
jne 0x8ec45
movq (%rbx), %r15
movq 0x8(%rbx), %rbx
cmpq %rbx, %r15
je 0x8ecea
movq %rbx, %r14
subq %r15, %r14
movq %r14, %rax
sarq $0x3, %rax
bsrq %rax, %rdx
xorl $0x3f, %edx
addl %edx, %edx
xorq $0x7e, %rdx
movq %r15, %rdi
movq %rbx, %rsi
callq 0x8eea2
cmpq $0x81, %r14
jl 0x8ecdf
leaq 0x80(%r15), %r14
movq %r15, %rdi
movq %r14, %rsi
callq 0x8f0dd
cmpq %rbx, %r14
je 0x8ecea
movq -0x8(%r14), %rcx
movq (%r14), %rax
movl 0x4(%rax), %edx
movq %r14, %rsi
cmpl %edx, 0x4(%rcx)
jle 0x8ecd6
movq %r14, %rsi
movq %rcx, (%rsi)
movq -0x10(%rsi), %rcx
addq $-0x8, %rsi
cmpl %edx, 0x4(%rcx)
jg 0x8ecc6
movq %rax, (%rsi)
addq $0x8, %r14
jmp 0x8ecac
movq %r15, %rdi
movq %rbx, %rsi
callq 0x8f0dd
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
|
_ZN6google8protobuf8compiler3cpp12_GLOBAL__N_118SortFieldsByNumberEPKNS0_10DescriptorE:
push r15
push r14
push rbx
sub rsp, 10h
mov r14, rsi
mov rbx, rdi
movsxd rsi, dword ptr [rsi+4]
lea rdx, [rsp+28h+var_19]
call _ZNSt6vectorIPKN6google8protobuf15FieldDescriptorESaIS4_EEC2EmRKS5_; std::vector<google::protobuf::FieldDescriptor const*>::vector(ulong,std::allocator<google::protobuf::FieldDescriptor const*> const&)
movsxd rax, dword ptr [r14+4]
test rax, rax
jle short loc_8EC60
xor ecx, ecx
loc_8EC45:
lea rdx, [rcx+rcx*8]
shl rdx, 3
add rdx, [r14+28h]
mov rsi, [rbx]
mov [rsi+rcx*8], rdx
inc rcx
cmp rcx, rax
jnz short loc_8EC45
loc_8EC60:
mov r15, [rbx]
mov rbx, [rbx+8]
cmp r15, rbx
jz short loc_8ECEA
mov r14, rbx
sub r14, r15
mov rax, r14
sar rax, 3
bsr rdx, rax
xor edx, 3Fh
add edx, edx
xor rdx, 7Eh
mov rdi, r15
mov rsi, rbx
call _ZSt16__introsort_loopIN9__gnu_cxx17__normal_iteratorIPPKN6google8protobuf15FieldDescriptorESt6vectorIS6_SaIS6_EEEElNS0_5__ops15_Iter_comp_iterINS3_8compiler3cpp12_GLOBAL__N_121FieldOrderingByNumberEEEEvT_SJ_T0_T1_; std::__introsort_loop<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,long,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>>(__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,long,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>)
cmp r14, 81h
jl short loc_8ECDF
lea r14, [r15+80h]
mov rdi, r15
mov rsi, r14
call _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPPKN6google8protobuf15FieldDescriptorESt6vectorIS6_SaIS6_EEEENS0_5__ops15_Iter_comp_iterINS3_8compiler3cpp12_GLOBAL__N_121FieldOrderingByNumberEEEEvT_SJ_T0_; std::__insertion_sort<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>>(__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>)
loc_8ECAC:
cmp r14, rbx
jz short loc_8ECEA
mov rcx, [r14-8]
mov rax, [r14]
mov edx, [rax+4]
mov rsi, r14
cmp [rcx+4], edx
jle short loc_8ECD6
mov rsi, r14
loc_8ECC6:
mov [rsi], rcx
mov rcx, [rsi-10h]
add rsi, 0FFFFFFFFFFFFFFF8h
cmp [rcx+4], edx
jg short loc_8ECC6
loc_8ECD6:
mov [rsi], rax
add r14, 8
jmp short loc_8ECAC
loc_8ECDF:
mov rdi, r15
mov rsi, rbx
call _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPPKN6google8protobuf15FieldDescriptorESt6vectorIS6_SaIS6_EEEENS0_5__ops15_Iter_comp_iterINS3_8compiler3cpp12_GLOBAL__N_121FieldOrderingByNumberEEEEvT_SJ_T0_; std::__insertion_sort<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>>(__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>)
loc_8ECEA:
add rsp, 10h
pop rbx
pop r14
pop r15
retn
|
long long google::protobuf::compiler::cpp::`anonymous namespace'::SortFieldsByNumber(
google::protobuf::compiler::cpp::_anonymous_namespace_ *this,
const google::protobuf::Descriptor *a2)
{
long long result; // rax
long long i; // rcx
long long v4; // r15
_QWORD *v5; // rbx
unsigned long long v6; // rdx
_QWORD *v7; // r14
long long v8; // rcx
int v9; // edx
_QWORD *v10; // rsi
char v11[25]; // [rsp+Fh] [rbp-19h] BYREF
std::vector<google::protobuf::FieldDescriptor const*>::vector(this, *((int *)a2 + 1), v11);
result = *((int *)a2 + 1);
if ( result > 0 )
{
for ( i = 0LL; i != result; ++i )
*(_QWORD *)(*(_QWORD *)this + 8 * i) = *((_QWORD *)a2 + 5) + 72 * i;
}
v4 = *(_QWORD *)this;
v5 = (_QWORD *)*((_QWORD *)this + 1);
if ( *(_QWORD **)this != v5 )
{
_BitScanReverse64(&v6, ((long long)v5 - v4) >> 3);
std::__introsort_loop<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,long,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>>(
v4,
v5,
(2 * ((unsigned int)v6 ^ 0x3F)) ^ 0x7ELL);
if ( (long long)v5 - v4 < 129 )
{
return std::__insertion_sort<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>>(
v4,
v5);
}
else
{
v7 = (_QWORD *)(v4 + 128);
result = std::__insertion_sort<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor const**,std::vector<google::protobuf::FieldDescriptor const*>>,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::`anonymous namespace'::FieldOrderingByNumber>>(
v4,
v4 + 128);
while ( v7 != v5 )
{
v8 = *(v7 - 1);
result = *v7;
v9 = *(_DWORD *)(*v7 + 4LL);
v10 = v7;
if ( *(_DWORD *)(v8 + 4) > v9 )
{
v10 = v7;
do
{
*v10 = v8;
v8 = *(v10 - 2);
--v10;
}
while ( *(_DWORD *)(v8 + 4) > v9 );
}
*v10 = result;
++v7;
}
}
}
return result;
}
|
SortFieldsByNumber:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x10
MOV R14,RSI
MOV RBX,RDI
MOVSXD RSI,dword ptr [RSI + 0x4]
LEA RDX,[RSP + 0xf]
CALL 0x00190eac
MOVSXD RAX,dword ptr [R14 + 0x4]
TEST RAX,RAX
JLE 0x0018ec60
XOR ECX,ECX
LAB_0018ec45:
LEA RDX,[RCX + RCX*0x8]
SHL RDX,0x3
ADD RDX,qword ptr [R14 + 0x28]
MOV RSI,qword ptr [RBX]
MOV qword ptr [RSI + RCX*0x8],RDX
INC RCX
CMP RCX,RAX
JNZ 0x0018ec45
LAB_0018ec60:
MOV R15,qword ptr [RBX]
MOV RBX,qword ptr [RBX + 0x8]
CMP R15,RBX
JZ 0x0018ecea
MOV R14,RBX
SUB R14,R15
MOV RAX,R14
SAR RAX,0x3
BSR RDX,RAX
XOR EDX,0x3f
ADD EDX,EDX
XOR RDX,0x7e
MOV RDI,R15
MOV RSI,RBX
CALL 0x0018eea2
CMP R14,0x81
JL 0x0018ecdf
LEA R14,[R15 + 0x80]
MOV RDI,R15
MOV RSI,R14
CALL 0x0018f0dd
LAB_0018ecac:
CMP R14,RBX
JZ 0x0018ecea
MOV RCX,qword ptr [R14 + -0x8]
MOV RAX,qword ptr [R14]
MOV EDX,dword ptr [RAX + 0x4]
MOV RSI,R14
CMP dword ptr [RCX + 0x4],EDX
JLE 0x0018ecd6
MOV RSI,R14
LAB_0018ecc6:
MOV qword ptr [RSI],RCX
MOV RCX,qword ptr [RSI + -0x10]
ADD RSI,-0x8
CMP dword ptr [RCX + 0x4],EDX
JG 0x0018ecc6
LAB_0018ecd6:
MOV qword ptr [RSI],RAX
ADD R14,0x8
JMP 0x0018ecac
LAB_0018ecdf:
MOV RDI,R15
MOV RSI,RBX
CALL 0x0018f0dd
LAB_0018ecea:
ADD RSP,0x10
POP RBX
POP R14
POP R15
RET
|
/* google::protobuf::compiler::cpp::(anonymous
namespace)::SortFieldsByNumber(google::protobuf::Descriptor const*) */
void __thiscall
google::protobuf::compiler::cpp::(anonymous_namespace)::SortFieldsByNumber
(_anonymous_namespace_ *this,Descriptor *param_1)
{
int iVar1;
int iVar2;
long *plVar3;
long lVar4;
ulong uVar5;
long lVar6;
long *plVar7;
long *plVar8;
std::
vector<google::protobuf::FieldDescriptor_const*,std::allocator<google::protobuf::FieldDescriptor_const*>>
::vector((ulong)this,(allocator *)(long)*(int *)(param_1 + 4));
iVar1 = *(int *)(param_1 + 4);
if (0 < (long)iVar1) {
lVar6 = 0;
do {
*(long *)(*(long *)this + lVar6 * 8) = lVar6 * 0x48 + *(long *)(param_1 + 0x28);
lVar6 = lVar6 + 1;
} while (lVar6 != iVar1);
}
plVar7 = *(long **)this;
plVar3 = *(long **)(this + 8);
if (plVar7 != plVar3) {
uVar5 = (long)plVar3 - (long)plVar7 >> 3;
lVar6 = 0x3f;
if (uVar5 != 0) {
for (; uVar5 >> lVar6 == 0; lVar6 = lVar6 + -1) {
}
}
std::
__introsort_loop<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor_const**,std::vector<google::protobuf::FieldDescriptor_const*,std::allocator<google::protobuf::FieldDescriptor_const*>>>,long,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::(anonymous_namespace)::FieldOrderingByNumber>>
(plVar7,plVar3,((uint)lVar6 ^ 0x3f) * 2 ^ 0x7e);
if ((long)plVar3 - (long)plVar7 < 0x81) {
std::
__insertion_sort<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor_const**,std::vector<google::protobuf::FieldDescriptor_const*,std::allocator<google::protobuf::FieldDescriptor_const*>>>,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::(anonymous_namespace)::FieldOrderingByNumber>>
(plVar7,plVar3);
}
else {
plVar8 = plVar7 + 0x10;
std::
__insertion_sort<__gnu_cxx::__normal_iterator<google::protobuf::FieldDescriptor_const**,std::vector<google::protobuf::FieldDescriptor_const*,std::allocator<google::protobuf::FieldDescriptor_const*>>>,__gnu_cxx::__ops::_Iter_comp_iter<google::protobuf::compiler::cpp::(anonymous_namespace)::FieldOrderingByNumber>>
(plVar7,plVar8);
for (; plVar8 != plVar3; plVar8 = plVar8 + 1) {
lVar6 = plVar8[-1];
lVar4 = *plVar8;
iVar1 = *(int *)(lVar4 + 4);
iVar2 = *(int *)(lVar6 + 4);
plVar7 = plVar8;
while (iVar1 < iVar2) {
*plVar7 = lVar6;
lVar6 = plVar7[-2];
plVar7 = plVar7 + -1;
iVar2 = *(int *)(lVar6 + 4);
}
*plVar7 = lVar4;
}
}
}
return;
}
|
|
7,890 |
string_split(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&)
|
llama.cpp/common/common.cpp
|
std::vector<std::string> string_split(const std::string & str, const std::string & delimiter) {
std::vector<std::string> parts;
size_t start = 0;
size_t end = str.find(delimiter);
while (end != std::string::npos) {
parts.push_back(str.substr(start, end - start));
start = end + delimiter.length();
end = str.find(delimiter, start);
}
parts.push_back(str.substr(start));
return parts;
}
|
O3
|
cpp
|
string_split(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
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq (%rdx), %rsi
movq 0x8(%rdx), %rcx
xorl %ebp, %ebp
movq %r14, %rdi
xorl %edx, %edx
callq 0x15340
cmpq $-0x1, %rax
je 0x1807c
movq %rax, %r12
xorl %ebp, %ebp
leaq 0x8(%rsp), %r13
movq %r12, %rcx
subq %rbp, %rcx
movq %r13, %rdi
movq %r14, %rsi
movq %rbp, %rdx
callq 0x159e0
movq %rbx, %rdi
movq %r13, %rsi
callq 0x29f64
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x1805b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x150e0
movq (%r15), %rsi
movq 0x8(%r15), %rcx
movq %r12, %rbp
addq %rcx, %rbp
movq %r14, %rdi
movq %rbp, %rdx
callq 0x15340
movq %rax, %r12
cmpq $-0x1, %rax
jne 0x18020
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
movq %rbp, %rdx
movq $-0x1, %rcx
callq 0x159e0
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x29f64
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x180bb
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x150e0
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
jmp 0x180ef
jmp 0x180dd
movq %rax, %r14
jmp 0x18101
movq %rax, %r14
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x18101
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x150e0
movq %rbx, %rdi
callq 0x1bd48
movq %r14, %rdi
callq 0x15640
|
_Z12string_splitRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES6_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r15, rdx
mov r14, rsi
mov rbx, rdi
xorps xmm0, xmm0
movups xmmword ptr [rdi], xmm0
mov qword ptr [rdi+10h], 0
mov rsi, [rdx]
mov rcx, [rdx+8]
xor ebp, ebp
mov rdi, r14
xor edx, edx
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEPKcmm; std::string::find(char const*,ulong,ulong)
cmp rax, 0FFFFFFFFFFFFFFFFh
jz short loc_1807C
mov r12, rax
xor ebp, ebp
lea r13, [rsp+58h+var_50]
loc_18020:
mov rcx, r12
sub rcx, rbp
mov rdi, r13
mov rsi, r14
mov rdx, rbp
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong)
mov rdi, rbx
mov rsi, r13
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&)
mov rdi, [rsp+58h+var_50]; void *
lea rax, [rsp+58h+var_40]
cmp rdi, rax
jz short loc_1805B
mov rsi, [rsp+58h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_1805B:
mov rsi, [r15]
mov rcx, [r15+8]
mov rbp, r12
add rbp, rcx
mov rdi, r14
mov rdx, rbp
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEPKcmm; std::string::find(char const*,ulong,ulong)
mov r12, rax
cmp rax, 0FFFFFFFFFFFFFFFFh
jnz short loc_18020
loc_1807C:
lea rdi, [rsp+58h+var_50]
mov rsi, r14
mov rdx, rbp
mov rcx, 0FFFFFFFFFFFFFFFFh
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong)
lea rsi, [rsp+58h+var_50]
mov rdi, rbx
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&)
lea rax, [rsp+58h+var_40]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_180BB
mov rsi, [rsp+58h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_180BB:
mov rax, rbx
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r14, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]
jmp short loc_180EF
jmp short $+2
loc_180DD:
mov r14, rax
jmp short loc_18101
mov r14, rax
mov rdi, [rsp+arg_0]; void *
lea rax, [rsp+arg_10]
loc_180EF:
cmp rdi, rax
jz short loc_18101
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_18101:
mov rdi, rbx
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, r14
call __Unwind_Resume
|
long long string_split(long long a1, long long a2, _QWORD *a3)
{
long long v4; // rbp
long long v5; // rax
long long v6; // r12
long long v7; // rcx
void *v9[2]; // [rsp+8h] [rbp-50h] BYREF
_QWORD v10[8]; // [rsp+18h] [rbp-40h] BYREF
*(_OWORD *)a1 = 0LL;
*(_QWORD *)(a1 + 16) = 0LL;
v4 = 0LL;
v5 = std::string::find(a2, *a3, 0LL, a3[1]);
if ( v5 != -1 )
{
v6 = v5;
v4 = 0LL;
do
{
std::string::substr(v9, a2, v4, v6 - v4);
std::vector<std::string>::emplace_back<std::string>(a1, v9);
if ( v9[0] != v10 )
operator delete(v9[0], v10[0] + 1LL);
v7 = a3[1];
v4 = v7 + v6;
v6 = std::string::find(a2, *a3, v7 + v6, v7);
}
while ( v6 != -1 );
}
std::string::substr(v9, a2, v4, -1LL);
std::vector<std::string>::emplace_back<std::string>(a1, v9);
if ( v9[0] != v10 )
operator delete(v9[0], v10[0] + 1LL);
return a1;
}
|
string_split:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R15,RDX
MOV R14,RSI
MOV RBX,RDI
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI],XMM0
MOV qword ptr [RDI + 0x10],0x0
MOV RSI,qword ptr [RDX]
MOV RCX,qword ptr [RDX + 0x8]
XOR EBP,EBP
MOV RDI,R14
XOR EDX,EDX
CALL 0x00115340
CMP RAX,-0x1
JZ 0x0011807c
MOV R12,RAX
XOR EBP,EBP
LEA R13,[RSP + 0x8]
LAB_00118020:
MOV RCX,R12
SUB RCX,RBP
LAB_00118026:
MOV RDI,R13
MOV RSI,R14
MOV RDX,RBP
CALL 0x001159e0
LAB_00118034:
MOV RDI,RBX
MOV RSI,R13
CALL 0x00129f64
MOV RDI,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x18]
CMP RDI,RAX
JZ 0x0011805b
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001150e0
LAB_0011805b:
MOV RSI,qword ptr [R15]
MOV RCX,qword ptr [R15 + 0x8]
MOV RBP,R12
ADD RBP,RCX
MOV RDI,R14
MOV RDX,RBP
CALL 0x00115340
MOV R12,RAX
CMP RAX,-0x1
JNZ 0x00118020
LAB_0011807c:
LEA RDI,[RSP + 0x8]
MOV RSI,R14
MOV RDX,RBP
MOV RCX,-0x1
CALL 0x001159e0
LAB_00118093:
LEA RSI,[RSP + 0x8]
MOV RDI,RBX
CALL 0x00129f64
LAB_001180a0:
LEA RAX,[RSP + 0x18]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x001180bb
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001150e0
LAB_001180bb:
MOV RAX,RBX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* string_split(std::__cxx11::string const&, std::__cxx11::string const&) */
string * string_split(string *param_1,string *param_2)
{
long lVar1;
ulong *in_RDX;
long *local_50 [2];
long local_40 [2];
*(int8 *)param_1 = 0;
*(int8 *)(param_1 + 8) = 0;
*(int8 *)(param_1 + 0x10) = 0;
lVar1 = std::__cxx11::string::find((char *)param_2,*in_RDX,0);
if (lVar1 != -1) {
do {
/* try { // try from 00118026 to 00118033 has its CatchHandler @ 001180dd */
std::__cxx11::string::substr((ulong)local_50,(ulong)param_2);
/* try { // try from 00118034 to 0011803e has its CatchHandler @ 001180e2 */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<std::__cxx11::string>
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1,
(string *)local_50);
if (local_50[0] != local_40) {
operator_delete(local_50[0],local_40[0] + 1);
}
lVar1 = std::__cxx11::string::find((char *)param_2,*in_RDX,lVar1 + in_RDX[1]);
} while (lVar1 != -1);
}
/* try { // try from 0011807c to 00118092 has its CatchHandler @ 001180db */
std::__cxx11::string::substr((ulong)local_50,(ulong)param_2);
/* try { // try from 00118093 to 0011809f has its CatchHandler @ 001180cd */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<std::__cxx11::string>
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1,
(string *)local_50);
if (local_50[0] != local_40) {
operator_delete(local_50[0],local_40[0] + 1);
}
return param_1;
}
|
|
7,891 |
minja::error_location_suffix(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long)
|
monkey531[P]llama/common/minja.hpp
|
static std::string error_location_suffix(const std::string & source, size_t pos) {
auto get_line = [&](size_t line) {
auto start = source.begin();
for (size_t i = 1; i < line; ++i) {
start = std::find(start, source.end(), '\n') + 1;
}
auto end = std::find(start, source.end(), '\n');
return std::string(start, end);
};
auto start = source.begin();
auto end = source.end();
auto it = start + pos;
auto line = std::count(start, it, '\n') + 1;
auto max_line = std::count(start, end, '\n') + 1;
auto col = pos - std::string(start, it).rfind('\n');
std::ostringstream out;
out << " at row " << line << ", column " << col << ":\n";
if (line > 1) out << get_line(line - 1) << "\n";
out << get_line(line) << "\n";
out << std::string(col - 1, ' ') << "^\n";
if (line < max_line) out << get_line(line + 1) << "\n";
return out.str();
}
|
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 0x28bc7
xorl %ecx, %ecx
xorl %r12d, %r12d
xorl %edx, %edx
cmpb $0xa, (%rsi,%rcx)
sete %dl
addq %rdx, %r12
incq %rcx
cmpq %rcx, %r8
jne 0x28bb1
jmp 0x28bca
xorl %r12d, %r12d
leaq (%rsi,%r8), %rdx
testq %rax, %rax
movq %r8, 0x28(%rsp)
je 0x28bf4
xorl %ecx, %ecx
xorl %r15d, %r15d
xorl %edi, %edi
cmpb $0xa, (%rsi,%rcx)
sete %dil
addq %rdi, %r15
incq %rcx
cmpq %rcx, %rax
jne 0x28bdd
jmp 0x28bf7
xorl %r15d, %r15d
leaq 0x50(%rsp), %rbp
movq %rbp, -0x10(%rbp)
leaq 0x40(%rsp), %rbx
movq %rbx, %rdi
callq 0x61208
movq %rbx, %rdi
movl $0xa, %esi
movq $-0x1, %rdx
callq 0x1aeb0
movq %rax, %r13
movq (%rbx), %rdi
cmpq %rbp, %rdi
je 0x28c39
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x1a740
leaq 0x40(%rsp), %rbx
movq %rbx, %rdi
callq 0x1a9d0
leaq 0x88935(%rip), %rsi # 0xb1582
movl $0x8, %edx
movq %rbx, %rdi
callq 0x1a870
movq 0x28(%rsp), %rbx
leaq 0x1(%r12), %rsi
leaq 0x40(%rsp), %rdi
movq %rsi, 0x30(%rsp)
callq 0x1a6c0
movq %rax, %rbp
leaq 0x87ece(%rip), %rsi # 0xb0b4b
movl $0x9, %edx
movq %rax, %rdi
callq 0x1a870
subq %r13, %rbx
movq %rbp, %rdi
movq %rbx, %rsi
callq 0x1a4d0
leaq 0x8eb8c(%rip), %rsi # 0xb782b
movl $0x2, %edx
movq %rax, %rdi
callq 0x1a870
testq %r12, %r12
jle 0x28d5b
movq (%r14), %r13
cmpq $0x1, %r12
jne 0x28cc3
movq %r13, %rsi
jmp 0x28cef
leaq -0x1(%r12), %rbp
movq (%r14), %rsi
addq 0x8(%r14), %rsi
movb $0xa, 0x7(%rsp)
movq %r13, %rdi
leaq 0x7(%rsp), %rdx
callq 0x613c0
movq %rax, %r13
incq %r13
decq %rbp
jne 0x28cc8
movq (%r14), %rsi
addq 0x8(%r14), %rsi
leaq 0x7(%rsp), %rdx
movb $0xa, (%rdx)
movq %r13, %rdi
callq 0x613c0
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
leaq 0x8(%rsp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x61208
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0x1a870
leaq 0x83396(%rip), %rsi # 0xac0cd
movl $0x1, %edx
movq %rax, %rdi
callq 0x1a870
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x28d5b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a740
movq (%r14), %r13
cmpq $0x2, 0x30(%rsp)
jb 0x28d9f
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 0x613c0
movq %rax, %r13
incq %r13
decq %rbx
jne 0x28d73
movq (%r14), %rsi
movq 0x28(%rsp), %rbx
jmp 0x28da2
movq %r13, %rsi
addq 0x8(%r14), %rsi
leaq 0x7(%rsp), %rdx
movb $0xa, (%rdx)
movq %r13, %rdi
callq 0x613c0
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
leaq 0x8(%rsp), %rdi
movq %r13, %rsi
movq %rax, %rdx
callq 0x61208
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0x1a870
leaq 0x832e3(%rip), %rsi # 0xac0cd
movl $0x1, %edx
movq %rax, %rdi
callq 0x1a870
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x28e0e
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a740
decq %rbx
leaq 0x8(%rsp), %rdi
movq %rbp, (%rdi)
movq %rbx, %rsi
movl $0x20, %edx
callq 0x1a8a0
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0x1a870
leaq 0x8874a(%rip), %rsi # 0xb158b
movl $0x2, %edx
movq %rax, %rdi
callq 0x1a870
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x28e65
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a740
cmpq %r15, %r12
jge 0x28f11
movq (%r14), %r15
cmpq $-0x3, %r12
ja 0x28ea8
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 0x613c0
movq %rax, %r15
incq %r15
decq %rbx
jne 0x28e81
movq (%r14), %rsi
jmp 0x28eab
movq %r15, %rsi
addq 0x8(%r14), %rsi
leaq 0x7(%rsp), %rdx
movb $0xa, (%rdx)
movq %r15, %rdi
callq 0x613c0
leaq 0x8(%rsp), %rdi
movq %rbp, (%rdi)
movq %r15, %rsi
movq %rax, %rdx
callq 0x61208
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x40(%rsp), %rdi
callq 0x1a870
leaq 0x831e0(%rip), %rsi # 0xac0cd
movl $0x1, %edx
movq %rax, %rdi
callq 0x1a870
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x28f11
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a740
leaq 0x48(%rsp), %rsi
movq 0x38(%rsp), %rdi
callq 0x1abc0
movq 0xba061(%rip), %rsi # 0xe2f88
leaq 0x40(%rsp), %rdi
callq 0x1a3e0
leaq 0xb0(%rsp), %rdi
callq 0x1a220
addq $0x1b8, %rsp # imm = 0x1B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x28f7a
jmp 0x28f7a
jmp 0x28f5e
jmp 0x28f7a
jmp 0x28f7a
jmp 0x28f5e
jmp 0x28f5e
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0x28f7d
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a740
jmp 0x28f7d
movq %rax, %rbx
movq 0xba004(%rip), %rsi # 0xe2f88
leaq 0x40(%rsp), %rdi
callq 0x1a3e0
leaq 0xb0(%rsp), %rdi
callq 0x1a220
movq %rbx, %rdi
callq 0x1ad30
|
_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_28BC7
xor ecx, ecx
xor r12d, r12d
loc_28BB1:
xor edx, edx
cmp byte ptr [rsi+rcx], 0Ah
setz dl
add r12, rdx
inc rcx
cmp r8, rcx
jnz short loc_28BB1
jmp short loc_28BCA
loc_28BC7:
xor r12d, r12d
loc_28BCA:
lea rdx, [rsi+r8]
test rax, rax
mov [rsp+1E8h+var_1C0], r8
jz short loc_28BF4
xor ecx, ecx
xor r15d, r15d
loc_28BDD:
xor edi, edi
cmp byte ptr [rsi+rcx], 0Ah
setz dil
add r15, rdi
inc rcx
cmp rax, rcx
jnz short loc_28BDD
jmp short loc_28BF7
loc_28BF4:
xor r15d, r15d
loc_28BF7:
lea rbp, [rsp+1E8h+var_198]
mov [rbp-10h], rbp
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_28C39
mov rsi, [rsp+1E8h+var_198]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_28C39:
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_28D5B
mov r13, [r14]
cmp r12, 1
jnz short loc_28CC3
mov rsi, r13
jmp short loc_28CEF
loc_28CC3:
lea rbp, [r12-1]
loc_28CC8:
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_28CC8
mov rsi, [r14]
loc_28CEF:
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
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, aSUnableToOpenT+2Ah; "\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_28D5B
mov rsi, [rsp+1E8h+var_1D0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_28D5B:
mov r13, [r14]
cmp [rsp+1E8h+var_1B8], 2
jb short loc_28D9F
mov [rsp+1E8h+var_1C0], rbx
lea rbp, [rsp+1E8h+var_1E1]
mov rbx, r12
loc_28D73:
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_28D73
mov rsi, [r14]
mov rbx, [rsp+1E8h+var_1C0]
jmp short loc_28DA2
loc_28D9F:
mov rsi, r13
loc_28DA2:
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
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, aSUnableToOpenT+2Ah; "\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_28E0E
mov rsi, [rsp+1E8h+var_1D0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_28E0E:
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_B158B; "^\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_28E65
mov rsi, [rsp+1E8h+var_1D0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_28E65:
cmp r12, r15
jge loc_28F11
mov r15, [r14]
cmp r12, 0FFFFFFFFFFFFFFFDh
ja short loc_28EA8
lea r13, [rsp+1E8h+var_1E1]
mov rbx, [rsp+1E8h+var_1B8]
loc_28E81:
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_28E81
mov rsi, [r14]
jmp short loc_28EAB
loc_28EA8:
mov rsi, r15
loc_28EAB:
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 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, aSUnableToOpenT+2Ah; "\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_28F11
mov rsi, [rsp+1E8h+var_1D0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_28F11:
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_28F7A
jmp short loc_28F7A
jmp short loc_28F5E
jmp short loc_28F7A
jmp short loc_28F7A
jmp short loc_28F5E
jmp short $+2
loc_28F5E:
mov rbx, rax
mov rdi, [rsp+arg_0]; void *
cmp rdi, rbp
jz short loc_28F7D
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_28F7D
loc_28F7A:
mov rbx, rax
loc_28F7D:
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)
{
long long 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
long long v14; // r13
long long v15; // rsi
long long v16; // rbp
long long v17; // rsi
long long v18; // rsi
long long v19; // rax
long long v20; // rax
long long v21; // r13
long long v22; // rbx
long long v23; // rsi
long long v24; // rsi
long long v25; // rsi
long long v26; // rax
long long v27; // rax
long long v28; // rax
long long v29; // r15
unsigned long long v30; // rbx
long long v31; // rsi
long long v32; // rsi
long long 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
char v44[8]; // [rsp+48h] [rbp-1A0h] BYREF
_QWORD v45[12]; // [rsp+50h] [rbp-198h] BYREF
char v46[312]; // [rsp+B0h] [rbp-138h] BYREF
v42 = a1;
v4 = *a2;
v5 = a2[1];
if ( a3 )
{
v6 = 0LL;
v7 = 0LL;
do
v7 += *(_BYTE *)(v4 + v6++) == 10;
while ( a3 != v6 );
}
else
{
v7 = 0LL;
}
v40 = a3;
if ( v5 )
{
v8 = 0LL;
v9 = 0LL;
do
v9 += *(_BYTE *)(v4 + v8++) == 10;
while ( v5 != v8 );
}
else
{
v9 = 0LL;
}
v43 = v45;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(&v43, v4, 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 = *a2;
if ( v7 == 1 )
{
v15 = *a2;
}
else
{
v16 = v7 - 1;
do
{
v17 = a2[1] + *a2;
v36 = 10;
v14 = 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 = *a2;
}
v18 = a2[1] + v15;
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;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(&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 = *a2;
if ( v41 < 2 )
{
v24 = *a2;
}
else
{
v40 = v12;
v22 = v7;
do
{
v23 = a2[1] + *a2;
v36 = 10;
v21 = 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 = *a2;
v12 = v40;
}
v25 = a2[1] + v24;
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;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(&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 = *a2;
if ( (unsigned long long)v7 > 0xFFFFFFFFFFFFFFFDLL )
{
v32 = *a2;
}
else
{
v30 = v41;
do
{
v31 = a2[1] + *a2;
v36 = 10;
v29 = 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 = *a2;
}
v33 = a2[1] + v32;
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;
std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(&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 0x00128bc7
XOR ECX,ECX
XOR R12D,R12D
LAB_00128bb1:
XOR EDX,EDX
CMP byte ptr [RSI + RCX*0x1],0xa
SETZ DL
ADD R12,RDX
INC RCX
CMP R8,RCX
JNZ 0x00128bb1
JMP 0x00128bca
LAB_00128bc7:
XOR R12D,R12D
LAB_00128bca:
LEA RDX,[RSI + R8*0x1]
TEST RAX,RAX
MOV qword ptr [RSP + 0x28],R8
JZ 0x00128bf4
XOR ECX,ECX
XOR R15D,R15D
LAB_00128bdd:
XOR EDI,EDI
CMP byte ptr [RSI + RCX*0x1],0xa
SETZ DIL
ADD R15,RDI
INC RCX
CMP RAX,RCX
JNZ 0x00128bdd
JMP 0x00128bf7
LAB_00128bf4:
XOR R15D,R15D
LAB_00128bf7:
LEA RBP,[RSP + 0x50]
MOV qword ptr [RBP + -0x10],RBP
LEA RBX,[RSP + 0x40]
MOV RDI,RBX
CALL 0x00161208
MOV RDI,RBX
MOV ESI,0xa
MOV RDX,-0x1
CALL 0x0011aeb0
MOV R13,RAX
MOV RDI,qword ptr [RBX]
CMP RDI,RBP
JZ 0x00128c39
MOV RSI,qword ptr [RSP + 0x50]
INC RSI
CALL 0x0011a740
LAB_00128c39:
LEA RBX,[RSP + 0x40]
MOV RDI,RBX
CALL 0x0011a9d0
LAB_00128c46:
LEA RSI,[0x1b1582]
MOV EDX,0x8
MOV RDI,RBX
CALL 0x0011a870
MOV RBX,qword ptr [RSP + 0x28]
LEA RSI,[R12 + 0x1]
LEA RDI,[RSP + 0x40]
MOV qword ptr [RSP + 0x30],RSI
CALL 0x0011a6c0
MOV RBP,RAX
LEA RSI,[0x1b0b4b]
MOV EDX,0x9
MOV RDI,RAX
CALL 0x0011a870
SUB RBX,R13
MOV RDI,RBP
MOV RSI,RBX
CALL 0x0011a4d0
LEA RSI,[0x1b782b]
MOV EDX,0x2
MOV RDI,RAX
CALL 0x0011a870
TEST R12,R12
JLE 0x00128d5b
MOV R13,qword ptr [R14]
CMP R12,0x1
JNZ 0x00128cc3
MOV RSI,R13
JMP 0x00128cef
LAB_00128cc3:
LEA RBP,[R12 + -0x1]
LAB_00128cc8:
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 0x001613c0
MOV R13,RAX
INC R13
DEC RBP
JNZ 0x00128cc8
MOV RSI,qword ptr [R14]
LAB_00128cef:
ADD RSI,qword ptr [R14 + 0x8]
LEA RDX,[RSP + 0x7]
MOV byte ptr [RDX],0xa
MOV RDI,R13
CALL 0x001613c0
LEA RBP,[RSP + 0x18]
MOV qword ptr [RBP + -0x10],RBP
LAB_00128d0c:
LEA RDI,[RSP + 0x8]
MOV RSI,R13
MOV RDX,RAX
CALL 0x00161208
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
LAB_00128d26:
LEA RDI,[RSP + 0x40]
CALL 0x0011a870
LEA RSI,[0x1ac0cd]
MOV EDX,0x1
MOV RDI,RAX
CALL 0x0011a870
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x00128d5b
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011a740
LAB_00128d5b:
MOV R13,qword ptr [R14]
CMP qword ptr [RSP + 0x30],0x2
JC 0x00128d9f
MOV qword ptr [RSP + 0x28],RBX
LEA RBP,[RSP + 0x7]
MOV RBX,R12
LAB_00128d73:
MOV RSI,qword ptr [R14]
ADD RSI,qword ptr [R14 + 0x8]
MOV byte ptr [RSP + 0x7],0xa
MOV RDI,R13
MOV RDX,RBP
CALL 0x001613c0
MOV R13,RAX
INC R13
DEC RBX
JNZ 0x00128d73
MOV RSI,qword ptr [R14]
MOV RBX,qword ptr [RSP + 0x28]
JMP 0x00128da2
LAB_00128d9f:
MOV RSI,R13
LAB_00128da2:
ADD RSI,qword ptr [R14 + 0x8]
LEA RDX,[RSP + 0x7]
MOV byte ptr [RDX],0xa
MOV RDI,R13
CALL 0x001613c0
LEA RBP,[RSP + 0x18]
MOV qword ptr [RBP + -0x10],RBP
LAB_00128dbf:
LEA RDI,[RSP + 0x8]
MOV RSI,R13
MOV RDX,RAX
CALL 0x00161208
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
LAB_00128dd9:
LEA RDI,[RSP + 0x40]
CALL 0x0011a870
LEA RSI,[0x1ac0cd]
MOV EDX,0x1
MOV RDI,RAX
CALL 0x0011a870
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x00128e0e
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011a740
LAB_00128e0e:
DEC RBX
LEA RDI,[RSP + 0x8]
MOV qword ptr [RDI],RBP
LAB_00128e19:
MOV RSI,RBX
MOV EDX,0x20
CALL 0x0011a8a0
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
LAB_00128e30:
LEA RDI,[RSP + 0x40]
CALL 0x0011a870
LEA RSI,[0x1b158b]
MOV EDX,0x2
MOV RDI,RAX
CALL 0x0011a870
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x00128e65
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011a740
LAB_00128e65:
CMP R12,R15
JGE 0x00128f11
MOV R15,qword ptr [R14]
CMP R12,-0x3
JA 0x00128ea8
LEA R13,[RSP + 0x7]
MOV RBX,qword ptr [RSP + 0x30]
LAB_00128e81:
MOV RSI,qword ptr [R14]
ADD RSI,qword ptr [R14 + 0x8]
MOV byte ptr [RSP + 0x7],0xa
MOV RDI,R15
MOV RDX,R13
CALL 0x001613c0
MOV R15,RAX
INC R15
DEC RBX
JNZ 0x00128e81
MOV RSI,qword ptr [R14]
JMP 0x00128eab
LAB_00128ea8:
MOV RSI,R15
LAB_00128eab:
ADD RSI,qword ptr [R14 + 0x8]
LEA RDX,[RSP + 0x7]
MOV byte ptr [RDX],0xa
MOV RDI,R15
CALL 0x001613c0
LEA RDI,[RSP + 0x8]
MOV qword ptr [RDI],RBP
LAB_00128ec7:
MOV RSI,R15
MOV RDX,RAX
CALL 0x00161208
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
LAB_00128edc:
LEA RDI,[RSP + 0x40]
CALL 0x0011a870
LEA RSI,[0x1ac0cd]
MOV EDX,0x1
MOV RDI,RAX
CALL 0x0011a870
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x00128f11
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011a740
LAB_00128f11:
LEA RSI,[RSP + 0x48]
LAB_00128f16:
MOV RDI,qword ptr [RSP + 0x38]
CALL 0x0011abc0
LAB_00128f20:
MOV RSI,qword ptr [0x001e2f88]
LEA RDI,[RSP + 0x40]
CALL 0x0011a3e0
LEA RDI,[RSP + 0xb0]
CALL 0x0011a220
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 [2];
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_1c0 = param_2;
local_1b0 = this;
local_1a8[0] = 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[0] != local_198) {
operator_delete(local_1a8[0],local_198[0] + 1);
}
std::__cxx11::ostringstream::ostringstream((ostringstream *)local_1a8);
/* try { // try from 00128c46 to 00128cab has its CatchHandler @ 00128f7a */
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));
/* try { // try from 00128d0c to 00128d1b has its CatchHandler @ 00128f52 */
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 00128d26 to 00128d43 has its CatchHandler @ 00128f5a */
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));
/* try { // try from 00128dbf to 00128dce has its CatchHandler @ 00128f58 */
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 00128dd9 to 00128df6 has its CatchHandler @ 00128f5e */
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 00128e19 to 00128e25 has its CatchHandler @ 00128f56 */
std::__cxx11::string::_M_construct((ulong)&local_1e0,(char)uVar4 + -1);
/* try { // try from 00128e30 to 00128e4d has its CatchHandler @ 00128f5c */
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_1e0 = local_1d0;
/* try { // try from 00128ec7 to 00128ed1 has its CatchHandler @ 00128f50 */
std::__cxx11::string::
_M_construct<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>
(&local_1e0,lVar9,uVar3);
/* try { // try from 00128edc to 00128ef9 has its CatchHandler @ 00128f54 */
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 00128f16 to 00128f1f has its CatchHandler @ 00128f7a */
std::__cxx11::stringbuf::str();
std::__cxx11::ostringstream::~ostringstream((ostringstream *)local_1a8);
std::ios_base::~ios_base(local_138);
return;
}
|
|
7,892 |
ma_mmap_pread
|
eloqsql/storage/maria/ma_dynrec.c
|
size_t _ma_mmap_pread(MARIA_HA *info, uchar *Buffer,
size_t Count, my_off_t offset, myf MyFlags)
{
DBUG_PRINT("info", ("maria_read with mmap %d\n", info->dfile.file));
if (info->s->lock_key_trees)
mysql_rwlock_rdlock(&info->s->mmap_lock);
/*
The following test may fail in the following cases:
- We failed to remap a memory area (fragmented memory?)
- This thread has done some writes, but not yet extended the
memory mapped area.
*/
if (info->s->mmaped_length >= offset + Count)
{
memcpy(Buffer, info->s->file_map + offset, Count);
if (info->s->lock_key_trees)
mysql_rwlock_unlock(&info->s->mmap_lock);
return 0;
}
else
{
if (info->s->lock_key_trees)
mysql_rwlock_unlock(&info->s->mmap_lock);
return mysql_file_pread(info->dfile.file, Buffer, Count, offset, MyFlags);
}
}
|
O3
|
c
|
ma_mmap_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, %r15
movq %rdx, %rbx
movq %rsi, %r12
movq %rdi, %r13
movq (%rdi), %rax
cmpb $0x0, 0x7e3(%rax)
je 0x48010
leaq 0xb78(%rax), %rdi
cmpq $0x0, 0xc08(%rax)
jne 0x480e6
callq 0xa57ec
movq (%r13), %r14
leaq (%r15,%rbx), %rax
cmpq %rax, 0xa00(%r14)
jae 0x48090
cmpb $0x0, 0x7e3(%r14)
je 0x4804a
movq 0xc08(%r14), %rdi
addq $0xb78, %r14 # imm = 0xB78
testq %rdi, %rdi
jne 0x4816d
movq %r14, %rdi
callq 0xa591a
movl 0x480(%r13), %r14d
leaq 0x33ffb8(%rip), %rax # 0x388010
movq (%rax), %rax
leaq -0x78(%rbp), %rdi
movl %r14d, %esi
movl $0x6, %edx
callq *0x158(%rax)
testq %rax, %rax
jne 0x480fc
movl %r14d, %edi
movq %r12, %rsi
movq %rbx, %rdx
movq %r15, %rcx
movq -0x30(%rbp), %r8
callq 0xa1a94
movq %rax, %r15
jmp 0x480d4
addq 0x5f0(%r14), %r15
movq %r12, %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq 0x29080
movq (%r13), %rbx
cmpb $0x0, 0x7e3(%rbx)
je 0x480d1
movq 0xc08(%rbx), %rdi
addq $0xb78, %rbx # imm = 0xB78
testq %rdi, %rdi
jne 0x48182
movq %rbx, %rdi
callq 0xa591a
xorl %r15d, %r15d
movq %r15, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x93c14(%rip), %rsi # 0xdbd01
movl $0x84, %edx
callq 0x2ec40
jmp 0x48010
movq %rax, %r13
leaq 0x33ff0a(%rip), %rax # 0x388010
movq (%rax), %rax
leaq 0x93bf1(%rip), %rdx # 0xdbd01
movq %r13, %rdi
movq %rbx, %rsi
movl $0x98, %ecx
callq *0x210(%rax)
movl %r14d, %edi
movq %r12, %rsi
movq %rbx, %rdx
movq %r15, %rcx
movq -0x30(%rbp), %r14
movq %r14, %r8
callq 0xa1a94
movq %rax, %r15
xorl %esi, %esi
testq %rax, %rax
cmovneq %rsi, %rbx
cmpq $-0x1, %rax
cmovneq %rax, %rsi
testb $0x6, %r14b
cmovneq %rbx, %rsi
leaq 0x33feb4(%rip), %rax # 0x388010
movq (%rax), %rax
movq %r13, %rdi
callq *0x218(%rax)
jmp 0x480d4
leaq 0x33fe9c(%rip), %rax # 0x388010
movq (%rax), %rax
callq *0x168(%rax)
jmp 0x48042
leaq 0x33fe87(%rip), %rax # 0x388010
movq (%rax), %rax
callq *0x168(%rax)
jmp 0x480c9
|
_ma_mmap_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 r15, rcx
mov rbx, rdx
mov r12, rsi
mov r13, rdi
mov rax, [rdi]
cmp byte ptr [rax+7E3h], 0
jz short loc_48010
lea rdi, [rax+0B78h]
cmp qword ptr [rax+0C08h], 0
jnz loc_480E6
call my_rw_rdlock
loc_48010:
mov r14, [r13+0]
lea rax, [r15+rbx]
cmp [r14+0A00h], rax
jnb short loc_48090
cmp byte ptr [r14+7E3h], 0
jz short loc_4804A
mov rdi, [r14+0C08h]
add r14, 0B78h
test rdi, rdi
jnz loc_4816D
loc_48042:
mov rdi, r14
call my_rw_unlock
loc_4804A:
mov r14d, [r13+480h]
lea rax, PSI_server
mov rax, [rax]
lea rdi, [rbp+var_78]
mov esi, r14d
mov edx, 6
call qword ptr [rax+158h]
test rax, rax
jnz loc_480FC
mov edi, r14d
mov rsi, r12
mov rdx, rbx
mov rcx, r15
mov r8, [rbp+var_30]
call my_pread
mov r15, rax
jmp short loc_480D4
loc_48090:
add r15, [r14+5F0h]
mov rdi, r12
mov rsi, r15
mov rdx, rbx
call _memcpy
mov rbx, [r13+0]
cmp byte ptr [rbx+7E3h], 0
jz short loc_480D1
mov rdi, [rbx+0C08h]
add rbx, 0B78h
test rdi, rdi
jnz loc_48182
loc_480C9:
mov rdi, rbx
call my_rw_unlock
loc_480D1:
xor r15d, r15d
loc_480D4:
mov rax, r15
add rsp, 58h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_480E6:
lea rsi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 84h
call psi_rwlock_rdlock
jmp loc_48010
loc_480FC:
mov r13, rax
lea rax, PSI_server
mov rax, [rax]
lea rdx, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, r13
mov rsi, rbx
mov ecx, 98h
call qword ptr [rax+210h]
mov edi, r14d
mov rsi, r12
mov rdx, rbx
mov rcx, r15
mov r14, [rbp+var_30]
mov r8, r14
call my_pread
mov r15, rax
xor esi, esi
test rax, rax
cmovnz rbx, rsi
cmp rax, 0FFFFFFFFFFFFFFFFh
cmovnz rsi, rax
test r14b, 6
cmovnz rsi, rbx
lea rax, PSI_server
mov rax, [rax]
mov rdi, r13
call qword ptr [rax+218h]
jmp loc_480D4
loc_4816D:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+168h]
jmp loc_48042
loc_48182:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+168h]
jmp loc_480C9
|
long long ma_mmap_pread(_DWORD *a1, long long a2, long long a3, long long a4, long long a5)
{
long long v8; // rax
long long v9; // rdi
long long v10; // r14
long long v11; // rdi
long long v12; // r14
unsigned int v13; // r14d
long long v14; // rax
long long v15; // r15
long long v16; // rbx
long long v17; // rdi
long long v18; // rbx
long long v20; // r13
_BYTE v21[72]; // [rsp+8h] [rbp-78h] BYREF
long long v22; // [rsp+50h] [rbp-30h]
v22 = a5;
v8 = *(_QWORD *)a1;
if ( *(_BYTE *)(*(_QWORD *)a1 + 2019LL) )
{
v9 = v8 + 2936;
if ( *(_QWORD *)(v8 + 3080) )
psi_rwlock_rdlock(v9, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_dynrec.c", 0x84u);
else
my_rw_rdlock(v9);
}
v10 = *(_QWORD *)a1;
if ( *(_QWORD *)(*(_QWORD *)a1 + 2560LL) >= (unsigned long long)(a4 + a3) )
{
memcpy(a2, *(_QWORD *)(v10 + 1520) + a4, a3);
v16 = *(_QWORD *)a1;
if ( *(_BYTE *)(*(_QWORD *)a1 + 2019LL) )
{
v17 = *(_QWORD *)(v16 + 3080);
v18 = v16 + 2936;
if ( v17 )
PSI_server[45]();
my_rw_unlock(v18);
}
return 0LL;
}
else
{
if ( *(_BYTE *)(v10 + 2019) )
{
v11 = *(_QWORD *)(v10 + 3080);
v12 = v10 + 2936;
if ( v11 )
PSI_server[45]();
my_rw_unlock(v12);
}
v13 = a1[288];
v14 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v21, v13, 6LL);
if ( v14 )
{
v20 = v14;
((void ( *)(long long, long long, const char *, long long))PSI_server[66])(
v14,
a3,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_dynrec.c",
152LL);
v15 = my_pread(v13, a2, a3, a4, v22);
((void ( *)(long long))PSI_server[67])(v20);
}
else
{
return my_pread(v13, a2, a3, a4, v22);
}
}
return v15;
}
|
_ma_mmap_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 R15,RCX
MOV RBX,RDX
MOV R12,RSI
MOV R13,RDI
MOV RAX,qword ptr [RDI]
CMP byte ptr [RAX + 0x7e3],0x0
JZ 0x00148010
LEA RDI,[RAX + 0xb78]
CMP qword ptr [RAX + 0xc08],0x0
JNZ 0x001480e6
CALL 0x001a57ec
LAB_00148010:
MOV R14,qword ptr [R13]
LEA RAX,[R15 + RBX*0x1]
CMP qword ptr [R14 + 0xa00],RAX
JNC 0x00148090
CMP byte ptr [R14 + 0x7e3],0x0
JZ 0x0014804a
MOV RDI,qword ptr [R14 + 0xc08]
ADD R14,0xb78
TEST RDI,RDI
JNZ 0x0014816d
LAB_00148042:
MOV RDI,R14
CALL 0x001a591a
LAB_0014804a:
MOV R14D,dword ptr [R13 + 0x480]
LEA RAX,[0x488010]
MOV RAX,qword ptr [RAX]
LEA RDI,[RBP + -0x78]
MOV ESI,R14D
MOV EDX,0x6
CALL qword ptr [RAX + 0x158]
TEST RAX,RAX
JNZ 0x001480fc
MOV EDI,R14D
MOV RSI,R12
MOV RDX,RBX
MOV RCX,R15
MOV R8,qword ptr [RBP + -0x30]
CALL 0x001a1a94
MOV R15,RAX
JMP 0x001480d4
LAB_00148090:
ADD R15,qword ptr [R14 + 0x5f0]
MOV RDI,R12
MOV RSI,R15
MOV RDX,RBX
CALL 0x00129080
MOV RBX,qword ptr [R13]
CMP byte ptr [RBX + 0x7e3],0x0
JZ 0x001480d1
MOV RDI,qword ptr [RBX + 0xc08]
ADD RBX,0xb78
TEST RDI,RDI
JNZ 0x00148182
LAB_001480c9:
MOV RDI,RBX
CALL 0x001a591a
LAB_001480d1:
XOR R15D,R15D
LAB_001480d4:
MOV RAX,R15
ADD RSP,0x58
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001480e6:
LEA RSI,[0x1dbd01]
MOV EDX,0x84
CALL 0x0012ec40
JMP 0x00148010
LAB_001480fc:
MOV R13,RAX
LEA RAX,[0x488010]
MOV RAX,qword ptr [RAX]
LEA RDX,[0x1dbd01]
MOV RDI,R13
MOV RSI,RBX
MOV ECX,0x98
CALL qword ptr [RAX + 0x210]
MOV EDI,R14D
MOV RSI,R12
MOV RDX,RBX
MOV RCX,R15
MOV R14,qword ptr [RBP + -0x30]
MOV R8,R14
CALL 0x001a1a94
MOV R15,RAX
XOR ESI,ESI
TEST RAX,RAX
CMOVNZ RBX,RSI
CMP RAX,-0x1
CMOVNZ RSI,RAX
TEST R14B,0x6
CMOVNZ RSI,RBX
LEA RAX,[0x488010]
MOV RAX,qword ptr [RAX]
MOV RDI,R13
CALL qword ptr [RAX + 0x218]
JMP 0x001480d4
LAB_0014816d:
LEA RAX,[0x488010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x168]
JMP 0x00148042
LAB_00148182:
LEA RAX,[0x488010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x168]
JMP 0x001480c9
|
size_t _ma_mmap_pread(long *param_1,void *param_2,size_t param_3,long param_4,ulong param_5)
{
int4 uVar1;
ulong uVar2;
long lVar3;
size_t sVar4;
size_t sVar5;
int1 local_80 [72];
ulong local_38;
lVar3 = *param_1;
local_38 = param_5;
if (*(char *)(lVar3 + 0x7e3) != '\0') {
if (*(long *)(lVar3 + 0xc08) == 0) {
my_rw_rdlock();
}
else {
psi_rwlock_rdlock(lVar3 + 0xb78,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_dynrec.c",0x84);
}
}
lVar3 = *param_1;
if (*(ulong *)(lVar3 + 0xa00) < param_4 + param_3) {
if (*(char *)(lVar3 + 0x7e3) != '\0') {
if (*(long *)(lVar3 + 0xc08) != 0) {
(**(code **)(PSI_server + 0x168))();
}
my_rw_unlock(lVar3 + 0xb78);
}
uVar1 = (int4)param_1[0x90];
lVar3 = (**(code **)(PSI_server + 0x158))(local_80,uVar1,6);
if (lVar3 == 0) {
sVar4 = 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",
0x98);
uVar2 = local_38;
sVar4 = my_pread(uVar1,param_2,param_3,param_4,local_38);
if (sVar4 != 0) {
param_3 = 0;
}
sVar5 = 0;
if (sVar4 != 0xffffffffffffffff) {
sVar5 = sVar4;
}
if ((uVar2 & 6) != 0) {
sVar5 = param_3;
}
(**(code **)(PSI_server + 0x218))(lVar3,sVar5);
}
}
else {
memcpy(param_2,(void *)(param_4 + *(long *)(lVar3 + 0x5f0)),param_3);
lVar3 = *param_1;
if (*(char *)(lVar3 + 0x7e3) != '\0') {
if (*(long *)(lVar3 + 0xc08) != 0) {
(**(code **)(PSI_server + 0x168))();
}
my_rw_unlock(lVar3 + 0xb78);
}
sVar4 = 0;
}
return sVar4;
}
|
|
7,893 |
ggml_arange
|
llama.cpp/ggml/src/ggml.c
|
struct ggml_tensor * ggml_arange(
struct ggml_context * ctx,
float start,
float stop,
float step) {
GGML_ASSERT(stop > start);
const int64_t steps = (int64_t) ceilf((stop - start) / step);
struct ggml_tensor * result = ggml_new_tensor_1d(ctx, GGML_TYPE_F32, steps);
ggml_set_op_params_f32(result, 0, start);
ggml_set_op_params_f32(result, 1, stop);
ggml_set_op_params_f32(result, 2, step);
result->op = GGML_OP_ARANGE;
return result;
}
|
O3
|
c
|
ggml_arange:
pushq %rbx
subq $0x20, %rsp
ucomiss %xmm0, %xmm1
jbe 0x1ddf8
movaps %xmm0, %xmm3
movq %rdi, %rbx
movaps %xmm1, %xmm0
subss %xmm3, %xmm0
divss %xmm2, %xmm0
movss %xmm2, 0x14(%rsp)
movss %xmm1, 0x10(%rsp)
movss %xmm3, 0xc(%rsp)
callq 0x168b0
cvttss2si %xmm0, %rax
leaq 0x18(%rsp), %rcx
movq %rax, (%rcx)
movq %rbx, %rdi
xorl %esi, %esi
movl $0x1, %edx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x19be7
movss 0xc(%rsp), %xmm0
movss %xmm0, 0x54(%rax)
movss 0x10(%rsp), %xmm0
movss %xmm0, 0x58(%rax)
movss 0x14(%rsp), %xmm0
movss %xmm0, 0x5c(%rax)
movl $0x3a, 0x50(%rax)
addq $0x20, %rsp
popq %rbx
retq
leaq 0x2c814(%rip), %rdi # 0x4a613
leaq 0x2c848(%rip), %rdx # 0x4a64e
leaq 0x2cf5e(%rip), %rcx # 0x4ad6b
movl $0x10b0, %esi # imm = 0x10B0
xorl %eax, %eax
callq 0x17c80
|
ggml_arange:
push rbx
sub rsp, 20h
ucomiss xmm1, xmm0
jbe short loc_1DDF8
movaps xmm3, xmm0
mov rbx, rdi
movaps xmm0, xmm1
subss xmm0, xmm3
divss xmm0, xmm2
movss [rsp+28h+var_14], xmm2
movss [rsp+28h+var_18], xmm1
movss [rsp+28h+var_1C], xmm3
call _ceilf
cvttss2si rax, xmm0
lea rcx, [rsp+28h+var_10]
mov [rcx], rax
mov rdi, rbx
xor esi, esi
mov edx, 1
xor r8d, r8d
xor r9d, r9d
call ggml_new_tensor_impl
movss xmm0, [rsp+28h+var_1C]
movss dword ptr [rax+54h], xmm0
movss xmm0, [rsp+28h+var_18]
movss dword ptr [rax+58h], xmm0
movss xmm0, [rsp+28h+var_14]
movss dword ptr [rax+5Ch], xmm0
mov dword ptr [rax+50h], 3Ah ; ':'
add rsp, 20h
pop rbx
retn
loc_1DDF8:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github2025/llama."...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aStopStart; "stop > start"
mov esi, 10B0h
xor eax, eax
call _ggml_abort
|
long long ggml_arange(
long long a1,
float a2,
double a3,
float a4,
long long a5,
long long a6,
long long a7,
int a8,
int a9)
{
double v10; // xmm0_8
long long result; // rax
long long v12; // [rsp+18h] [rbp-10h] BYREF
if ( *(float *)&a3 <= a2 )
ggml_abort(
(unsigned int)"/workspace/llm4binary/github2025/llama.cpp/ggml/src/ggml.c",
4272,
(unsigned int)"GGML_ASSERT(%s) failed",
(unsigned int)"stop > start",
a8,
a9);
HIDWORD(v10) = HIDWORD(a3);
*(float *)&v10 = (float)(*(float *)&a3 - a2) / a4;
v12 = (unsigned int)(int)ceilf(v10);
result = ggml_new_tensor_impl(a1, 0, 1u, &v12, 0LL, 0LL);
*(float *)(result + 84) = a2;
*(_DWORD *)(result + 88) = LODWORD(a3);
*(float *)(result + 92) = a4;
*(_DWORD *)(result + 80) = 58;
return result;
}
|
ggml_arange:
PUSH RBX
SUB RSP,0x20
UCOMISS XMM1,XMM0
JBE 0x0011ddf8
MOVAPS XMM3,XMM0
MOV RBX,RDI
MOVAPS XMM0,XMM1
SUBSS XMM0,XMM3
DIVSS XMM0,XMM2
MOVSS dword ptr [RSP + 0x14],XMM2
MOVSS dword ptr [RSP + 0x10],XMM1
MOVSS dword ptr [RSP + 0xc],XMM3
CALL 0x001168b0
CVTTSS2SI RAX,XMM0
LEA RCX,[RSP + 0x18]
MOV qword ptr [RCX],RAX
MOV RDI,RBX
XOR ESI,ESI
MOV EDX,0x1
XOR R8D,R8D
XOR R9D,R9D
CALL 0x00119be7
MOVSS XMM0,dword ptr [RSP + 0xc]
MOVSS dword ptr [RAX + 0x54],XMM0
MOVSS XMM0,dword ptr [RSP + 0x10]
MOVSS dword ptr [RAX + 0x58],XMM0
MOVSS XMM0,dword ptr [RSP + 0x14]
MOVSS dword ptr [RAX + 0x5c],XMM0
MOV dword ptr [RAX + 0x50],0x3a
ADD RSP,0x20
POP RBX
RET
LAB_0011ddf8:
LEA RDI,[0x14a613]
LEA RDX,[0x14a64e]
LEA RCX,[0x14ad6b]
MOV ESI,0x10b0
XOR EAX,EAX
CALL 0x00117c80
|
void ggml_arange(float param_1,float param_2,float param_3,int8 param_4)
{
long lVar1;
float fVar2;
long local_10;
if (param_1 < param_2) {
fVar2 = ceilf((param_2 - param_1) / param_3);
local_10 = (long)fVar2;
lVar1 = ggml_new_tensor_impl(param_4,0,1,&local_10,0,0);
*(float *)(lVar1 + 0x54) = param_1;
*(float *)(lVar1 + 0x58) = param_2;
*(float *)(lVar1 + 0x5c) = param_3;
*(int4 *)(lVar1 + 0x50) = 0x3a;
return;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github2025/llama.cpp/ggml/src/ggml.c",0x10b0,
"GGML_ASSERT(%s) failed","stop > start");
}
|
|
7,894 |
No_such_table_error_handler::handle_condition(THD*, unsigned int, char const*, Sql_state_errno_level::enum_warning_level*, char const*, Sql_condition**)
|
eloqsql/sql/sql_base.cc
|
bool
No_such_table_error_handler::handle_condition(THD *,
uint sql_errno,
const char*,
Sql_condition::enum_warning_level *level,
const char*,
Sql_condition ** cond_hdl)
{
*cond_hdl= NULL;
if (sql_errno == ER_NO_SUCH_TABLE || sql_errno == ER_NO_SUCH_TABLE_IN_ENGINE)
{
m_handled_errors++;
return TRUE;
}
if (*level == Sql_condition::WARN_LEVEL_ERROR)
m_unhandled_errors++;
return FALSE;
}
|
O0
|
cpp
|
No_such_table_error_handler::handle_condition(THD*, unsigned int, char const*, Sql_state_errno_level::enum_warning_level*, char const*, Sql_condition**):
pushq %rbp
movq %rsp, %rbp
movq 0x10(%rbp), %rax
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movq %r9, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x40(%rbp)
movq 0x10(%rbp), %rax
movq $0x0, (%rax)
cmpl $0x47a, -0x1c(%rbp) # imm = 0x47A
je 0x85e1d4
cmpl $0x78c, -0x1c(%rbp) # imm = 0x78C
jne 0x85e1e7
movq -0x40(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
movb $0x1, -0x1(%rbp)
jmp 0x85e201
movq -0x30(%rbp), %rax
cmpl $0x2, (%rax)
jne 0x85e1fd
movq -0x40(%rbp), %rax
movl 0x14(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x14(%rax)
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
popq %rbp
retq
nopl (%rax,%rax)
|
_ZN27No_such_table_error_handler16handle_conditionEP3THDjPKcPN21Sql_state_errno_level18enum_warning_levelES3_PP13Sql_condition:
push rbp
mov rbp, rsp
mov rax, [rbp+arg_0]
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_1C], edx
mov [rbp+var_28], rcx
mov [rbp+var_30], r8
mov [rbp+var_38], r9
mov rax, [rbp+var_10]
mov [rbp+var_40], rax
mov rax, [rbp+arg_0]
mov qword ptr [rax], 0
cmp [rbp+var_1C], 47Ah
jz short loc_85E1D4
cmp [rbp+var_1C], 78Ch
jnz short loc_85E1E7
loc_85E1D4:
mov rax, [rbp+var_40]
mov ecx, [rax+10h]
add ecx, 1
mov [rax+10h], ecx
mov [rbp+var_1], 1
jmp short loc_85E201
loc_85E1E7:
mov rax, [rbp+var_30]
cmp dword ptr [rax], 2
jnz short loc_85E1FD
mov rax, [rbp+var_40]
mov ecx, [rax+14h]
add ecx, 1
mov [rax+14h], ecx
loc_85E1FD:
mov [rbp+var_1], 0
loc_85E201:
mov al, [rbp+var_1]
and al, 1
pop rbp
retn
|
char No_such_table_error_handler::handle_condition(
long long a1,
long long a2,
int a3,
long long a4,
_DWORD *a5,
long long a6,
_QWORD *a7)
{
*a7 = 0LL;
if ( a3 == 1146 || a3 == 1932 )
{
++*(_DWORD *)(a1 + 16);
return 1;
}
else
{
if ( *a5 == 2 )
++*(_DWORD *)(a1 + 20);
return 0;
}
}
|
__cxx_global_var_init:
PUSH RBP
MOV RBP,RSP
LEA RDI,[0x1dd0bc0]
XOR EAX,EAX
MOV ESI,EAX
CALL 0x008db900
POP RBP
RET
|
void __cxx_global_var_init(void)
{
date_conv_mode_t::date_conv_mode_t((date_conv_mode_t *)&TIME_CONV_NONE,0);
return;
}
|
|
7,895 |
cr_sort_and_remove_overlap
|
bluesky950520[P]quickjs/libunicode.c
|
static void cr_sort_and_remove_overlap(CharRange *cr)
{
uint32_t start, end, start1, end1, i, j;
/* the resulting ranges are not necessarily sorted and may overlap */
rqsort(cr->points, cr->len / 2, sizeof(cr->points[0]) * 2, point_cmp, NULL);
j = 0;
for(i = 0; i < cr->len; ) {
start = cr->points[i];
end = cr->points[i + 1];
i += 2;
while (i < cr->len) {
start1 = cr->points[i];
end1 = cr->points[i + 1];
if (start1 > end) {
/* |------|
* |-------| */
break;
} else if (end1 <= end) {
/* |------|
* |--| */
i += 2;
} else {
/* |------|
* |-------| */
end = end1;
i += 2;
}
}
cr->points[j] = start;
cr->points[j + 1] = end;
j += 2;
}
cr->len = j;
}
|
O1
|
c
|
cr_sort_and_remove_overlap:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x8(%rdi), %rdi
movl (%rbx), %eax
movl %eax, %ecx
shrl $0x1f, %ecx
addl %eax, %ecx
sarl %ecx
movslq %ecx, %rsi
leaq 0xe1e(%rip), %rcx # 0x9a907
xorl %r14d, %r14d
movl $0x8, %edx
xorl %r8d, %r8d
callq 0x1c031
movl (%rbx), %ecx
testl %ecx, %ecx
je 0x99b4d
movq 0x8(%rbx), %rax
xorl %r14d, %r14d
xorl %edx, %edx
leal 0x1(%rdx), %esi
movl (%rax,%rsi,4), %edi
leal 0x2(%rdx), %esi
cmpl %ecx, %esi
jae 0x99b32
movl %esi, %r8d
cmpl %edi, (%rax,%r8,4)
ja 0x99b32
leal 0x1(%rsi), %r8d
movl (%rax,%r8,4), %r8d
cmpl %edi, %r8d
cmoval %r8d, %edi
addl $0x2, %esi
jmp 0x99b11
movl %edx, %ecx
movl (%rax,%rcx,4), %ecx
movl %r14d, %edx
movl %ecx, (%rax,%rdx,4)
movl %edi, 0x4(%rax,%rdx,4)
addl $0x2, %r14d
movl (%rbx), %ecx
movl %esi, %edx
cmpl %ecx, %esi
jb 0x99b08
movl %r14d, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
|
cr_sort_and_remove_overlap:
push r14
push rbx
push rax
mov rbx, rdi
mov rdi, [rdi+8]
mov eax, [rbx]
mov ecx, eax
shr ecx, 1Fh
add ecx, eax
sar ecx, 1
movsxd rsi, ecx
lea rcx, point_cmp
xor r14d, r14d
mov edx, 8
xor r8d, r8d
call rqsort
mov ecx, [rbx]
test ecx, ecx
jz short loc_99B4D
mov rax, [rbx+8]
xor r14d, r14d
xor edx, edx
loc_99B08:
lea esi, [rdx+1]
mov edi, [rax+rsi*4]
lea esi, [rdx+2]
loc_99B11:
cmp esi, ecx
jnb short loc_99B32
mov r8d, esi
cmp [rax+r8*4], edi
ja short loc_99B32
lea r8d, [rsi+1]
mov r8d, [rax+r8*4]
cmp r8d, edi
cmova edi, r8d
add esi, 2
jmp short loc_99B11
loc_99B32:
mov ecx, edx
mov ecx, [rax+rcx*4]
mov edx, r14d
mov [rax+rdx*4], ecx
mov [rax+rdx*4+4], edi
add r14d, 2
mov ecx, [rbx]
mov edx, esi
cmp esi, ecx
jb short loc_99B08
loc_99B4D:
mov [rbx], r14d
add rsp, 8
pop rbx
pop r14
retn
|
char cr_sort_and_remove_overlap(unsigned int *a1)
{
unsigned int v2; // r14d
long long v3; // rax
unsigned int v4; // ecx
unsigned int v5; // edx
unsigned int v6; // edi
unsigned int i; // esi
v2 = 0;
LOBYTE(v3) = rqsort(
*((_QWORD *)a1 + 1),
(int)*a1 / 2,
8LL,
(long long ( *)(unsigned long long, unsigned long long, long long))point_cmp,
0LL);
v4 = *a1;
if ( *a1 )
{
v3 = *((_QWORD *)a1 + 1);
v2 = 0;
v5 = 0;
do
{
v6 = *(_DWORD *)(v3 + 4LL * (v5 + 1));
for ( i = v5 + 2; i < v4 && *(_DWORD *)(v3 + 4LL * i) <= v6; i += 2 )
{
if ( *(_DWORD *)(v3 + 4LL * (i + 1)) > v6 )
v6 = *(_DWORD *)(v3 + 4LL * (i + 1));
}
*(_DWORD *)(v3 + 4LL * v2) = *(_DWORD *)(v3 + 4LL * v5);
*(_DWORD *)(v3 + 4LL * v2 + 4) = v6;
v2 += 2;
v4 = *a1;
v5 = i;
}
while ( i < *a1 );
}
*a1 = v2;
return v3;
}
|
cr_sort_and_remove_overlap:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV RDI,qword ptr [RDI + 0x8]
MOV EAX,dword ptr [RBX]
MOV ECX,EAX
SHR ECX,0x1f
ADD ECX,EAX
SAR ECX,0x1
MOVSXD RSI,ECX
LEA RCX,[0x19a907]
XOR R14D,R14D
MOV EDX,0x8
XOR R8D,R8D
CALL 0x0011c031
MOV ECX,dword ptr [RBX]
TEST ECX,ECX
JZ 0x00199b4d
MOV RAX,qword ptr [RBX + 0x8]
XOR R14D,R14D
XOR EDX,EDX
LAB_00199b08:
LEA ESI,[RDX + 0x1]
MOV EDI,dword ptr [RAX + RSI*0x4]
LEA ESI,[RDX + 0x2]
LAB_00199b11:
CMP ESI,ECX
JNC 0x00199b32
MOV R8D,ESI
CMP dword ptr [RAX + R8*0x4],EDI
JA 0x00199b32
LEA R8D,[RSI + 0x1]
MOV R8D,dword ptr [RAX + R8*0x4]
CMP R8D,EDI
CMOVA EDI,R8D
ADD ESI,0x2
JMP 0x00199b11
LAB_00199b32:
MOV ECX,EDX
MOV ECX,dword ptr [RAX + RCX*0x4]
MOV EDX,R14D
MOV dword ptr [RAX + RDX*0x4],ECX
MOV dword ptr [RAX + RDX*0x4 + 0x4],EDI
ADD R14D,0x2
MOV ECX,dword ptr [RBX]
MOV EDX,ESI
CMP ESI,ECX
JC 0x00199b08
LAB_00199b4d:
MOV dword ptr [RBX],R14D
ADD RSP,0x8
POP RBX
POP R14
RET
|
void cr_sort_and_remove_overlap(uint *param_1)
{
uint uVar1;
long lVar2;
uint uVar3;
uint uVar4;
uint uVar5;
uint uVar6;
uint uVar7;
ulong uVar8;
uVar7 = 0;
rqsort(*(int8 *)(param_1 + 2),(long)((int)*param_1 / 2),8,point_cmp,0);
uVar4 = *param_1;
if (uVar4 != 0) {
lVar2 = *(long *)(param_1 + 2);
uVar8 = 0;
uVar5 = 0;
do {
uVar6 = *(uint *)(lVar2 + (ulong)(uVar5 + 1) * 4);
uVar7 = uVar5;
while( true ) {
uVar3 = uVar7 + 2;
if ((uVar4 <= uVar3) || (uVar6 < *(uint *)(lVar2 + (ulong)uVar3 * 4))) break;
uVar1 = *(uint *)(lVar2 + (ulong)(uVar7 + 3) * 4);
uVar7 = uVar3;
if (uVar6 < uVar1) {
uVar6 = uVar1;
}
}
*(int4 *)(lVar2 + uVar8 * 4) = *(int4 *)(lVar2 + (ulong)uVar5 * 4);
*(uint *)(lVar2 + 4 + uVar8 * 4) = uVar6;
uVar7 = (int)uVar8 + 2;
uVar8 = (ulong)uVar7;
uVar4 = *param_1;
uVar5 = uVar3;
} while (uVar3 < uVar4);
}
*param_1 = uVar7;
return;
}
|
|
7,896 |
rtree_find_first
|
eloqsql/storage/myisam/rt_index.c
|
int rtree_find_first(MI_INFO *info, uint keynr, uchar *key, uint key_length,
uint search_flag)
{
my_off_t root;
uint nod_cmp_flag;
MI_KEYDEF *keyinfo = info->s->keyinfo + keynr;
/*
At the moment index can only properly handle the
MBR_INTERSECT, so we use it for all sorts of queries.
TODO: better searsh for CONTAINS/WITHIN.
*/
search_flag= nod_cmp_flag= MBR_INTERSECT;
if ((root = info->s->state.key_root[keynr]) == HA_OFFSET_ERROR)
{
my_errno= HA_ERR_END_OF_FILE;
return -1;
}
/*
Save searched key, include data pointer.
The data pointer is required if the search_flag contains MBR_DATA.
(minimum bounding rectangle)
*/
memcpy(info->first_mbr_key, key, keyinfo->keylength);
info->last_rkey_length = key_length;
info->rtree_recursion_depth = -1;
info->buff_used = 1;
/*
TODO better search for CONTAINS/WITHIN.
nod_cmp_flag= ((search_flag & (MBR_EQUAL | MBR_WITHIN)) ?
MBR_WITHIN : MBR_INTERSECT);
*/
return rtree_find_req(info, keyinfo, search_flag, nod_cmp_flag, root, 0);
}
|
O0
|
c
|
rtree_find_first:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
movl %ecx, -0x24(%rbp)
movl %r8d, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x218(%rax), %rax
movl -0x14(%rbp), %ecx
imulq $0x70, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movl $0x400, -0x34(%rbp) # imm = 0x400
movl $0x400, -0x28(%rbp) # imm = 0x400
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x98(%rax), %rax
movl -0x14(%rbp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, -0x30(%rbp)
cmpq $-0x1, %rax
jne 0xca097
callq 0xf7b30
movl $0x89, (%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xca0f8
movq -0x10(%rbp), %rax
movq 0x118(%rax), %rdi
movq -0x20(%rbp), %rsi
movq -0x40(%rbp), %rax
movzwl 0x12(%rax), %eax
movl %eax, %edx
callq 0x29090
movl -0x24(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x1dc(%rax)
movq -0x10(%rbp), %rax
movl $0xffffffff, 0x3c0(%rax) # imm = 0xFFFFFFFF
movq -0x10(%rbp), %rax
movb $0x1, 0x33d(%rax)
movq -0x10(%rbp), %rdi
movq -0x40(%rbp), %rsi
movl -0x28(%rbp), %edx
movl -0x34(%rbp), %ecx
movq -0x30(%rbp), %r8
xorl %r9d, %r9d
callq 0xca110
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
rtree_find_first:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_20], rdx
mov [rbp+var_24], ecx
mov [rbp+var_28], r8d
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+218h]
mov ecx, [rbp+var_14]
imul rcx, 70h ; 'p'
add rax, rcx
mov [rbp+var_40], rax
mov [rbp+var_34], 400h
mov [rbp+var_28], 400h
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+98h]
mov ecx, [rbp+var_14]
mov rax, [rax+rcx*8]
mov [rbp+var_30], rax
cmp rax, 0FFFFFFFFFFFFFFFFh
jnz short loc_CA097
call _my_thread_var
mov dword ptr [rax], 89h
mov [rbp+var_4], 0FFFFFFFFh
jmp short loc_CA0F8
loc_CA097:
mov rax, [rbp+var_10]
mov rdi, [rax+118h]
mov rsi, [rbp+var_20]
mov rax, [rbp+var_40]
movzx eax, word ptr [rax+12h]
mov edx, eax
call _memcpy
mov ecx, [rbp+var_24]
mov rax, [rbp+var_10]
mov [rax+1DCh], ecx
mov rax, [rbp+var_10]
mov dword ptr [rax+3C0h], 0FFFFFFFFh
mov rax, [rbp+var_10]
mov byte ptr [rax+33Dh], 1
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_40]
mov edx, [rbp+var_28]
mov ecx, [rbp+var_34]
mov r8, [rbp+var_30]
xor r9d, r9d
call rtree_find_req
mov [rbp+var_4], eax
loc_CA0F8:
mov eax, [rbp+var_4]
add rsp, 40h
pop rbp
retn
|
long long rtree_find_first(long long a1, const char *a2, long long a3, int a4)
{
long long v5; // [rsp+0h] [rbp-40h]
long long v6; // [rsp+10h] [rbp-30h]
v5 = 112LL * (unsigned int)a2 + *(_QWORD *)(*(_QWORD *)a1 + 536LL);
v6 = *(_QWORD *)(*(_QWORD *)(*(_QWORD *)a1 + 152LL) + 8LL * (unsigned int)a2);
if ( v6 == -1 )
{
*(_DWORD *)my_thread_var(a1, a2) = 137;
return (unsigned int)-1;
}
else
{
memcpy(*(_QWORD *)(a1 + 280), a3, *(unsigned __int16 *)(v5 + 18));
*(_DWORD *)(a1 + 476) = a4;
*(_DWORD *)(a1 + 960) = -1;
*(_BYTE *)(a1 + 829) = 1;
return (unsigned int)rtree_find_req(a1, v5, 1024LL, 1024LL, v6, 0LL);
}
}
|
rtree_find_first:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x24],ECX
MOV dword ptr [RBP + -0x28],R8D
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x218]
MOV ECX,dword ptr [RBP + -0x14]
IMUL RCX,RCX,0x70
ADD RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
MOV dword ptr [RBP + -0x34],0x400
MOV dword ptr [RBP + -0x28],0x400
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x98]
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x30],RAX
CMP RAX,-0x1
JNZ 0x001ca097
CALL 0x001f7b30
MOV dword ptr [RAX],0x89
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x001ca0f8
LAB_001ca097:
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX + 0x118]
MOV RSI,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x40]
MOVZX EAX,word ptr [RAX + 0x12]
MOV EDX,EAX
CALL 0x00129090
MOV ECX,dword ptr [RBP + -0x24]
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x1dc],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x3c0],0xffffffff
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x33d],0x1
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x40]
MOV EDX,dword ptr [RBP + -0x28]
MOV ECX,dword ptr [RBP + -0x34]
MOV R8,qword ptr [RBP + -0x30]
XOR R9D,R9D
CALL 0x001ca110
MOV dword ptr [RBP + -0x4],EAX
LAB_001ca0f8:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x40
POP RBP
RET
|
int4 rtree_find_first(long *param_1,uint param_2,void *param_3,int4 param_4)
{
long lVar1;
long lVar2;
int4 *puVar3;
int4 local_c;
lVar2 = *(long *)(*param_1 + 0x218) + (ulong)param_2 * 0x70;
lVar1 = *(long *)(*(long *)(*param_1 + 0x98) + (ulong)param_2 * 8);
if (lVar1 == -1) {
puVar3 = (int4 *)_my_thread_var();
*puVar3 = 0x89;
local_c = 0xffffffff;
}
else {
memcpy((void *)param_1[0x23],param_3,(ulong)*(ushort *)(lVar2 + 0x12));
*(int4 *)((long)param_1 + 0x1dc) = param_4;
*(int4 *)(param_1 + 0x78) = 0xffffffff;
*(int1 *)((long)param_1 + 0x33d) = 1;
local_c = rtree_find_req(param_1,lVar2,0x400,0x400,lVar1,0);
}
return local_c;
}
|
|
7,897 |
ma_scan_init_block_record
|
eloqsql/storage/maria/ma_blockrec.c
|
my_bool _ma_scan_init_block_record(MARIA_HA *info)
{
MARIA_SHARE *share= info->s;
myf flag= MY_WME | (share->temporary ? MY_THREAD_SPECIFIC : 0);
DBUG_ENTER("_ma_scan_init_block_record");
DBUG_ASSERT(info->dfile.file == share->bitmap.file.file);
/*
bitmap_buff may already be allocated if this is the second call to
rnd_init() without a rnd_end() in between, see sql/handler.h
*/
if (!(info->scan.bitmap_buff ||
((info->scan.bitmap_buff=
(uchar *) my_malloc(PSI_INSTRUMENT_ME, share->block_size * 2,
flag)))))
DBUG_RETURN(1);
info->scan.page_buff= info->scan.bitmap_buff + share->block_size;
info->scan.bitmap_end= info->scan.bitmap_buff + share->bitmap.max_total_size;
/* Set scan variables to get _ma_scan_block() to start with reading bitmap */
info->scan.number_of_rows= 0;
info->scan.bitmap_pos= info->scan.bitmap_end;
info->scan.bitmap_page= (pgcache_page_no_t) 0 - share->bitmap.pages_covered;
info->scan.max_page= share->state.state.data_file_length / share->block_size;
/*
We need to flush what's in memory (bitmap.map) to page cache otherwise, as
we are going to read bitmaps from page cache in table scan (see
_ma_scan_block_record()), we may miss recently inserted rows (bitmap page
in page cache would be too old).
*/
DBUG_RETURN(_ma_bitmap_flush(info->s));
}
|
O0
|
c
|
ma_scan_init_block_record:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movsbl 0x7d9(%rax), %edx
xorl %eax, %eax
movl $0x10000, %ecx # imm = 0x10000
cmpl $0x0, %edx
cmovnel %ecx, %eax
orl $0x10, %eax
movl %eax, %eax
movq %rax, -0x20(%rbp)
jmp 0x8331a
movq -0x10(%rbp), %rax
cmpq $0x0, 0x220(%rax)
jne 0x8335f
movq -0x18(%rbp), %rax
movl 0x7bc(%rax), %eax
shll %eax
movl %eax, %eax
movl %eax, %esi
movq -0x20(%rbp), %rdx
xorl %edi, %edi
callq 0xbe600
movq -0x10(%rbp), %rcx
movq %rax, 0x220(%rcx)
cmpq $0x0, %rax
jne 0x8335f
jmp 0x83356
movb $0x1, -0x1(%rbp)
jmp 0x83415
movq -0x10(%rbp), %rax
movq 0x220(%rax), %rcx
movq -0x18(%rbp), %rax
movl 0x7bc(%rax), %eax
addq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x238(%rax)
movq -0x10(%rbp), %rax
movq 0x220(%rax), %rcx
movq -0x18(%rbp), %rax
movl 0xb3c(%rax), %eax
addq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x230(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x268(%rax)
movq -0x10(%rbp), %rax
movq 0x230(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x228(%rax)
movq -0x18(%rbp), %rax
xorl %ecx, %ecx
subq 0xb48(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x250(%rax)
movq -0x18(%rbp), %rax
movq 0x40(%rax), %rax
movq -0x18(%rbp), %rcx
movl 0x7bc(%rcx), %ecx
xorl %edx, %edx
divq %rcx
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x258(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x46c70
movb %al, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x20, %rsp
popq %rbp
retq
nop
|
_ma_scan_init_block_record:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_18], rax
mov rax, [rbp+var_18]
movsx edx, byte ptr [rax+7D9h]
xor eax, eax
mov ecx, offset stru_10000
cmp edx, 0
cmovnz eax, ecx
or eax, 10h
mov eax, eax
mov [rbp+var_20], rax
jmp short $+2
loc_8331A:
mov rax, [rbp+var_10]
cmp qword ptr [rax+220h], 0
jnz short loc_8335F
mov rax, [rbp+var_18]
mov eax, [rax+7BCh]
shl eax, 1
mov eax, eax
mov esi, eax
mov rdx, [rbp+var_20]
xor edi, edi
call my_malloc
mov rcx, [rbp+var_10]
mov [rcx+220h], rax
cmp rax, 0
jnz short loc_8335F
jmp short $+2
loc_83356:
mov [rbp+var_1], 1
jmp loc_83415
loc_8335F:
mov rax, [rbp+var_10]
mov rcx, [rax+220h]
mov rax, [rbp+var_18]
mov eax, [rax+7BCh]
add rcx, rax
mov rax, [rbp+var_10]
mov [rax+238h], rcx
mov rax, [rbp+var_10]
mov rcx, [rax+220h]
mov rax, [rbp+var_18]
mov eax, [rax+0B3Ch]
add rcx, rax
mov rax, [rbp+var_10]
mov [rax+230h], rcx
mov rax, [rbp+var_10]
mov dword ptr [rax+268h], 0
mov rax, [rbp+var_10]
mov rcx, [rax+230h]
mov rax, [rbp+var_10]
mov [rax+228h], rcx
mov rax, [rbp+var_18]
xor ecx, ecx
sub rcx, [rax+0B48h]
mov rax, [rbp+var_10]
mov [rax+250h], rcx
mov rax, [rbp+var_18]
mov rax, [rax+40h]
mov rcx, [rbp+var_18]
mov ecx, [rcx+7BCh]
xor edx, edx
div rcx
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+258h], rcx
mov rax, [rbp+var_10]
mov rdi, [rax]
call _ma_bitmap_flush
mov [rbp+var_1], al
loc_83415:
mov al, [rbp+var_1]
add rsp, 20h
pop rbp
retn
|
char ma_scan_init_block_record(long long *a1)
{
unsigned int v1; // eax
long long v2; // rax
long long v4; // [rsp+8h] [rbp-18h]
v4 = *a1;
v1 = 0;
if ( *(_BYTE *)(*a1 + 2009) )
v1 = (unsigned int)&stru_10000;
if ( !a1[68] )
{
v2 = my_malloc(0LL, (unsigned int)(2 * *(_DWORD *)(v4 + 1980)), v1 | 0x10);
a1[68] = v2;
if ( !v2 )
return 1;
}
a1[71] = *(unsigned int *)(v4 + 1980) + a1[68];
a1[70] = *(unsigned int *)(v4 + 2876) + a1[68];
*((_DWORD *)a1 + 154) = 0;
a1[69] = a1[70];
a1[74] = -*(_QWORD *)(v4 + 2888);
a1[75] = *(_QWORD *)(v4 + 64) / (unsigned long long)*(unsigned int *)(v4 + 1980);
return ma_bitmap_flush(*a1);
}
|
_ma_scan_init_block_record:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOVSX EDX,byte ptr [RAX + 0x7d9]
XOR EAX,EAX
MOV ECX,0x10000
CMP EDX,0x0
CMOVNZ EAX,ECX
OR EAX,0x10
MOV EAX,EAX
MOV qword ptr [RBP + -0x20],RAX
JMP 0x0018331a
LAB_0018331a:
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x220],0x0
JNZ 0x0018335f
MOV RAX,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RAX + 0x7bc]
SHL EAX,0x1
MOV EAX,EAX
MOV ESI,EAX
MOV RDX,qword ptr [RBP + -0x20]
XOR EDI,EDI
CALL 0x001be600
MOV RCX,qword ptr [RBP + -0x10]
MOV qword ptr [RCX + 0x220],RAX
CMP RAX,0x0
JNZ 0x0018335f
JMP 0x00183356
LAB_00183356:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00183415
LAB_0018335f:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x220]
MOV RAX,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RAX + 0x7bc]
ADD RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x238],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x220]
MOV RAX,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RAX + 0xb3c]
ADD RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x230],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x268],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x230]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x228],RCX
MOV RAX,qword ptr [RBP + -0x18]
XOR ECX,ECX
SUB RCX,qword ptr [RAX + 0xb48]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x250],RCX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x40]
MOV RCX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RCX + 0x7bc]
XOR EDX,EDX
DIV RCX
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x258],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX]
CALL 0x00146c70
MOV byte ptr [RBP + -0x1],AL
LAB_00183415:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x20
POP RBP
RET
|
int1 _ma_scan_init_block_record(long *param_1)
{
long lVar1;
int1 uVar2;
uint uVar3;
long lVar4;
lVar1 = *param_1;
uVar3 = 0;
if (*(char *)(lVar1 + 0x7d9) != '\0') {
uVar3 = 0x10000;
}
if (param_1[0x44] == 0) {
lVar4 = my_malloc(0,*(int *)(lVar1 + 0x7bc) << 1,uVar3 | 0x10);
param_1[0x44] = lVar4;
if (lVar4 == 0) {
return 1;
}
}
param_1[0x47] = param_1[0x44] + (ulong)*(uint *)(lVar1 + 0x7bc);
param_1[0x46] = param_1[0x44] + (ulong)*(uint *)(lVar1 + 0xb3c);
*(int4 *)(param_1 + 0x4d) = 0;
param_1[0x45] = param_1[0x46];
param_1[0x4a] = -*(long *)(lVar1 + 0xb48);
param_1[0x4b] = *(ulong *)(lVar1 + 0x40) / (ulong)*(uint *)(lVar1 + 0x7bc);
uVar2 = _ma_bitmap_flush(*param_1);
return uVar2;
}
|
|
7,898 |
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const& nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator[]<char const>(char const*) const
|
monkey531[P]llama/common/json.hpp
|
const_reference operator[](T* key) const
{
return operator[](typename object_t::key_type(key));
}
|
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> const& nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator[]<char const>(char const*) const:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
leaq 0x7(%rsp), %rdx
movq %r14, %rdi
callq 0x1c718
movq %rbx, %rdi
movq %r14, %rsi
callq 0x6fb0a
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x69817
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r14
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x69840
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
movq %rbx, %rdi
callq 0x18ba0
|
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_PT_:
push r14
push rbx
sub rsp, 28h
mov rbx, rdi
lea r14, [rsp+38h+var_30]
lea rdx, [rsp+38h+var_31]
mov rdi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
mov rdi, rbx
mov rsi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixERKS9_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::operator[](std::string const&)
mov rbx, rax
lea rax, [rsp+38h+var_20]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_69817
mov rsi, [rsp+38h+var_20]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_69817:
mov rax, rbx
add rsp, 28h
pop rbx
pop r14
retn
mov rbx, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_69840
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_69840:
mov rdi, rbx
call __Unwind_Resume
|
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator[]<char const>(
long long a1,
long long a2)
{
long long v2; // rbx
void *v4[2]; // [rsp+8h] [rbp-30h] BYREF
long long v5; // [rsp+18h] [rbp-20h] BYREF
std::string::basic_string<std::allocator<char>>(v4, a2);
v2 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator[](
a1,
v4);
if ( v4[0] != &v5 )
operator delete(v4[0], v5 + 1);
return v2;
}
|
operator[]<char_const>:
PUSH R14
PUSH RBX
SUB RSP,0x28
MOV RBX,RDI
LEA R14,[RSP + 0x8]
LEA RDX,[RSP + 0x7]
MOV RDI,R14
CALL 0x0011c718
LAB_001697ee:
MOV RDI,RBX
MOV RSI,R14
CALL 0x0016fb0a
LAB_001697f9:
MOV RBX,RAX
LEA RAX,[RSP + 0x18]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x00169817
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001186a0
LAB_00169817:
MOV RAX,RBX
ADD RSP,0x28
POP RBX
POP R14
RET
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const&
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>::operator[]<char const>(char const*) const */
basic_json * __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::operator[]<char_const>
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,char *param_1)
{
basic_json *pbVar1;
allocator local_31;
long *local_30 [2];
long local_20 [2];
std::__cxx11::string::string<std::allocator<char>>((string *)local_30,param_1,&local_31);
/* try { // try from 001697ee to 001697f8 has its CatchHandler @ 00169822 */
pbVar1 = (basic_json *)operator[](this,(string *)local_30);
if (local_30[0] != local_20) {
operator_delete(local_30[0],local_20[0] + 1);
}
return pbVar1;
}
|
|
7,899 |
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const& nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator[]<char const>(char const*) const
|
monkey531[P]llama/common/json.hpp
|
const_reference operator[](T* key) const
{
return operator[](typename object_t::key_type(key));
}
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const& nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator[]<char const>(char const*) const:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
leaq 0x7(%rsp), %rdx
movq %r14, %rdi
callq 0x1c6e0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x6e82c
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x686d7
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r14
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x68700
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186a0
movq %rbx, %rdi
callq 0x18ba0
|
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_PT_:
push r14
push rbx
sub rsp, 28h
mov rbx, rdi
lea r14, [rsp+38h+var_30]
lea rdx, [rsp+38h+var_31]
mov rdi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
mov rdi, rbx
mov rsi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixERKS9_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::operator[](std::string const&)
mov rbx, rax
lea rax, [rsp+38h+var_20]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_686D7
mov rsi, [rsp+38h+var_20]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_686D7:
mov rax, rbx
add rsp, 28h
pop rbx
pop r14
retn
mov rbx, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_68700
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_68700:
mov rdi, rbx
call __Unwind_Resume
|
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator[]<char const>(
long long a1,
long long a2)
{
long long v2; // rbx
void *v4[2]; // [rsp+8h] [rbp-30h] BYREF
long long v5; // [rsp+18h] [rbp-20h] BYREF
std::string::basic_string<std::allocator<char>>(v4, a2);
v2 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator[](
a1,
v4);
if ( v4[0] != &v5 )
operator delete(v4[0], v5 + 1);
return v2;
}
|
operator[]<char_const>:
PUSH R14
PUSH RBX
SUB RSP,0x28
MOV RBX,RDI
LEA R14,[RSP + 0x8]
LEA RDX,[RSP + 0x7]
MOV RDI,R14
CALL 0x0011c6e0
LAB_001686ae:
MOV RDI,RBX
MOV RSI,R14
CALL 0x0016e82c
LAB_001686b9:
MOV RBX,RAX
LEA RAX,[RSP + 0x18]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x001686d7
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001186a0
LAB_001686d7:
MOV RAX,RBX
ADD RSP,0x28
POP RBX
POP R14
RET
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const&
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>::operator[]<char const>(char const*) const */
basic_json * __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::operator[]<char_const>
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,char *param_1)
{
basic_json *pbVar1;
allocator local_31;
long *local_30 [2];
long local_20 [2];
std::__cxx11::string::string<std::allocator<char>>((string *)local_30,param_1,&local_31);
/* try { // try from 001686ae to 001686b8 has its CatchHandler @ 001686e2 */
pbVar1 = (basic_json *)operator[](this,(string *)local_30);
if (local_30[0] != local_20) {
operator_delete(local_30[0],local_20[0] + 1);
}
return pbVar1;
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.