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
|
|---|---|---|---|---|---|---|---|---|---|---|---|
19,900
|
inline_mysql_mutex_init(unsigned int, st_mysql_mutex*, pthread_mutexattr_t const*)
|
eloqsql/include/mysql/psi/mysql_thread.h
|
static inline int inline_mysql_mutex_init(
#ifdef HAVE_PSI_MUTEX_INTERFACE
PSI_mutex_key key,
#endif
mysql_mutex_t *that,
const pthread_mutexattr_t *attr
#ifdef SAFE_MUTEX
, const char *src_name, const char *src_file, uint src_line
#endif
)
{
#ifdef HAVE_PSI_MUTEX_INTERFACE
that->m_psi= PSI_MUTEX_CALL(init_mutex)(key, &that->m_mutex);
#else
that->m_psi= NULL;
#endif
#ifdef COROUTINE_ENABLED
that->l.data= that;
that->l.prev= that->l.next= NULL;
#endif
#ifdef SAFE_MUTEX
return safe_mutex_init(&that->m_mutex, attr, src_name, src_file, src_line);
#else
return pthread_mutex_init(&that->m_mutex, attr);
#endif
}
|
O0
|
c
|
inline_mysql_mutex_init(unsigned int, st_mysql_mutex*, pthread_mutexattr_t const*):
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
leaq 0x1a71c6(%rip), %rax # 0x1ce530
movq (%rax), %rax
movq 0x40(%rax), %rax
movl -0x4(%rbp), %edi
movq -0x10(%rbp), %rsi
callq *%rax
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x40(%rax)
movq -0x10(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x38(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x30(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x28(%rax)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x244a0
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
|
inline_mysql_mutex_init:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_4], edi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+40h]
mov edi, [rbp+var_4]
mov rsi, [rbp+var_10]
call rax
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+40h], rcx
mov rcx, [rbp+var_10]
mov rax, [rbp+var_10]
mov [rax+38h], rcx
mov rax, [rbp+var_10]
mov qword ptr [rax+30h], 0
mov rax, [rbp+var_10]
mov qword ptr [rax+28h], 0
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call _pthread_mutex_init
add rsp, 20h
pop rbp
retn
|
long long inline_mysql_mutex_init(unsigned int a1, _QWORD *a2, long long a3)
{
a2[8] = ((long long ( *)(_QWORD, _QWORD *))PSI_server[8])(a1, a2);
a2[7] = a2;
a2[6] = 0LL;
a2[5] = 0LL;
return pthread_mutex_init(a2, a3);
}
|
inline_mysql_mutex_init:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV dword ptr [RBP + -0x4],EDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
LEA RAX,[0x2ce530]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x40]
MOV EDI,dword ptr [RBP + -0x4]
MOV RSI,qword ptr [RBP + -0x10]
CALL RAX
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x40],RCX
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x38],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x30],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x28],0x0
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x001244a0
ADD RSP,0x20
POP RBP
RET
|
void inline_mysql_mutex_init
(int4 param_1,pthread_mutex_t *param_2,pthread_mutexattr_t *param_3)
{
int8 uVar1;
uVar1 = (**(code **)(PSI_server + 0x40))(param_1,param_2);
*(int8 *)((long)param_2 + 0x40) = uVar1;
*(pthread_mutex_t **)((long)param_2 + 0x38) = param_2;
*(int8 *)((long)param_2 + 0x30) = 0;
param_2[1].__align = 0;
pthread_mutex_init(param_2,param_3);
return;
}
|
|
19,901
|
js_os_dup2
|
bluesky950520[P]quickjs/quickjs-libc.c
|
static JSValue js_os_dup2(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
int fd, fd2, ret;
if (JS_ToInt32(ctx, &fd, argv[0]))
return JS_EXCEPTION;
if (JS_ToInt32(ctx, &fd2, argv[1]))
return JS_EXCEPTION;
ret = js_get_errno(dup2(fd, fd2));
return JS_NewInt32(ctx, ret);
}
|
O2
|
c
|
js_os_dup2:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %r8, %r15
movq %rdi, %r14
movq (%r8), %rdx
movq 0x8(%r8), %rcx
leaq 0xc(%rsp), %rsi
callq 0x215d7
pushq $0x6
popq %rbx
testl %eax, %eax
jne 0x1572a
movq 0x10(%r15), %rdx
movq 0x18(%r15), %rcx
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
callq 0x215d7
testl %eax, %eax
je 0x15739
xorl %eax, %eax
movq %rbx, %rdx
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
movl 0xc(%rsp), %edi
movl 0x8(%rsp), %esi
callq 0xe270
movslq %eax, %rdi
callq 0x113ab
movl %eax, %eax
xorl %ebx, %ebx
jmp 0x1572c
|
js_os_dup2:
push r15
push r14
push rbx
sub rsp, 10h
mov r15, r8
mov r14, rdi
mov rdx, [r8]
mov rcx, [r8+8]
lea rsi, [rsp+28h+var_1C]
call JS_ToInt32
push 6
pop rbx
test eax, eax
jnz short loc_1572A
mov rdx, [r15+10h]
mov rcx, [r15+18h]
lea rsi, [rsp+28h+var_20]
mov rdi, r14
call JS_ToInt32
test eax, eax
jz short loc_15739
loc_1572A:
xor eax, eax
loc_1572C:
mov rdx, rbx
add rsp, 10h
pop rbx
pop r14
pop r15
retn
loc_15739:
mov edi, [rsp+28h+var_1C]
mov esi, [rsp+28h+var_20]
call _dup2
movsxd rdi, eax
call js_get_errno
mov eax, eax
xor ebx, ebx
jmp short loc_1572C
|
long long js_os_dup2(long long a1, long long a2, long long a3, long long a4, _QWORD *a5)
{
int v7; // eax
unsigned int v8; // [rsp+8h] [rbp-20h] BYREF
_DWORD v9[7]; // [rsp+Ch] [rbp-1Ch] BYREF
if ( (unsigned int)JS_ToInt32(a1, v9, *a5, a5[1]) || (unsigned int)JS_ToInt32(a1, &v8, a5[2], a5[3]) )
return 0LL;
v7 = dup2(v9[0], v8);
return (unsigned int)js_get_errno(v7);
}
|
js_os_dup2:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x10
MOV R15,R8
MOV R14,RDI
MOV RDX,qword ptr [R8]
MOV RCX,qword ptr [R8 + 0x8]
LEA RSI,[RSP + 0xc]
CALL 0x001215d7
PUSH 0x6
POP RBX
TEST EAX,EAX
JNZ 0x0011572a
MOV RDX,qword ptr [R15 + 0x10]
MOV RCX,qword ptr [R15 + 0x18]
LEA RSI,[RSP + 0x8]
MOV RDI,R14
CALL 0x001215d7
TEST EAX,EAX
JZ 0x00115739
LAB_0011572a:
XOR EAX,EAX
LAB_0011572c:
MOV RDX,RBX
ADD RSP,0x10
POP RBX
POP R14
POP R15
RET
LAB_00115739:
MOV EDI,dword ptr [RSP + 0xc]
MOV ESI,dword ptr [RSP + 0x8]
CALL 0x0010e270
MOVSXD RDI,EAX
CALL 0x001113ab
MOV EAX,EAX
XOR EBX,EBX
JMP 0x0011572c
|
int4 js_os_dup2(int8 param_1)
{
int iVar1;
int4 uVar2;
int8 *in_R8;
int local_20;
int local_1c;
iVar1 = JS_ToInt32(param_1,&local_1c,*in_R8,in_R8[1]);
if ((iVar1 == 0) && (iVar1 = JS_ToInt32(param_1,&local_20,in_R8[2],in_R8[3]), iVar1 == 0)) {
iVar1 = dup2(local_1c,local_20);
uVar2 = js_get_errno((long)iVar1);
return uVar2;
}
return 0;
}
|
|
19,902
|
js_os_dup2
|
bluesky950520[P]quickjs/quickjs-libc.c
|
static JSValue js_os_dup2(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
int fd, fd2, ret;
if (JS_ToInt32(ctx, &fd, argv[0]))
return JS_EXCEPTION;
if (JS_ToInt32(ctx, &fd2, argv[1]))
return JS_EXCEPTION;
ret = js_get_errno(dup2(fd, fd2));
return JS_NewInt32(ctx, ret);
}
|
O3
|
c
|
js_os_dup2:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %r8, %r15
movq %rdi, %r14
movq (%r8), %rdx
movq 0x8(%r8), %rcx
leaq 0xc(%rsp), %rsi
callq 0x2803b
movl $0x6, %ebx
testl %eax, %eax
jne 0x1b3f1
movq 0x10(%r15), %rdx
movq 0x18(%r15), %rcx
leaq 0x8(%rsp), %rsi
movq %r14, %rdi
callq 0x2803b
testl %eax, %eax
je 0x1b400
xorl %eax, %eax
movq %rbx, %rdx
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
movl 0xc(%rsp), %edi
movl 0x8(%rsp), %esi
callq 0xe260
cmpl $-0x1, %eax
jne 0x1b41e
callq 0xe0b0
movq %rax, %rcx
xorl %eax, %eax
subl (%rcx), %eax
movl %eax, %eax
xorl %ebx, %ebx
jmp 0x1b3f3
|
js_os_dup2:
push r15
push r14
push rbx
sub rsp, 10h
mov r15, r8
mov r14, rdi
mov rdx, [r8]
mov rcx, [r8+8]
lea rsi, [rsp+28h+var_1C]
call JS_ToInt32
mov ebx, 6
test eax, eax
jnz short loc_1B3F1
mov rdx, [r15+10h]
mov rcx, [r15+18h]
lea rsi, [rsp+28h+var_20]
mov rdi, r14
call JS_ToInt32
test eax, eax
jz short loc_1B400
loc_1B3F1:
xor eax, eax
loc_1B3F3:
mov rdx, rbx
add rsp, 10h
pop rbx
pop r14
pop r15
retn
loc_1B400:
mov edi, [rsp+28h+var_1C]
mov esi, [rsp+28h+var_20]
call _dup2
cmp eax, 0FFFFFFFFh
jnz short loc_1B41E
call ___errno_location
mov rcx, rax
xor eax, eax
sub eax, [rcx]
loc_1B41E:
mov eax, eax
xor ebx, ebx
jmp short loc_1B3F3
|
long long js_os_dup2(long long a1, long long a2, long long a3, long long a4, _QWORD *a5)
{
long long result; // rax
long long v7; // rdi
unsigned int v8; // [rsp+8h] [rbp-20h] BYREF
_DWORD v9[7]; // [rsp+Ch] [rbp-1Ch] BYREF
if ( (unsigned int)JS_ToInt32(a1, v9, *a5, a5[1]) || (unsigned int)JS_ToInt32(a1, &v8, a5[2], a5[3]) )
return 0LL;
v7 = v9[0];
LODWORD(result) = dup2(v9[0], v8);
if ( (_DWORD)result == -1 )
LODWORD(result) = -*(_DWORD *)__errno_location(v7);
return (unsigned int)result;
}
|
js_os_dup2:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x10
MOV R15,R8
MOV R14,RDI
MOV RDX,qword ptr [R8]
MOV RCX,qword ptr [R8 + 0x8]
LEA RSI,[RSP + 0xc]
CALL 0x0012803b
MOV EBX,0x6
TEST EAX,EAX
JNZ 0x0011b3f1
MOV RDX,qword ptr [R15 + 0x10]
MOV RCX,qword ptr [R15 + 0x18]
LEA RSI,[RSP + 0x8]
MOV RDI,R14
CALL 0x0012803b
TEST EAX,EAX
JZ 0x0011b400
LAB_0011b3f1:
XOR EAX,EAX
LAB_0011b3f3:
MOV RDX,RBX
ADD RSP,0x10
POP RBX
POP R14
POP R15
RET
LAB_0011b400:
MOV EDI,dword ptr [RSP + 0xc]
MOV ESI,dword ptr [RSP + 0x8]
CALL 0x0010e260
CMP EAX,-0x1
JNZ 0x0011b41e
CALL 0x0010e0b0
MOV RCX,RAX
XOR EAX,EAX
SUB EAX,dword ptr [RCX]
LAB_0011b41e:
MOV EAX,EAX
XOR EBX,EBX
JMP 0x0011b3f3
|
int js_os_dup2(int8 param_1)
{
int iVar1;
int *piVar2;
int8 *in_R8;
int local_20;
int local_1c;
iVar1 = JS_ToInt32(param_1,&local_1c,*in_R8,in_R8[1]);
if ((iVar1 == 0) && (iVar1 = JS_ToInt32(param_1,&local_20,in_R8[2],in_R8[3]), iVar1 == 0)) {
iVar1 = dup2(local_1c,local_20);
if (iVar1 == -1) {
piVar2 = __errno_location();
iVar1 = -*piVar2;
}
}
else {
iVar1 = 0;
}
return iVar1;
}
|
|
19,903
|
store_page_range
|
eloqsql/storage/maria/ma_blockrec.c
|
static uchar *store_page_range(MARIA_SHARE *share,
uchar *to, MARIA_BITMAP_BLOCK *block,
ulong length,
uint *tot_ranges)
{
uint data_size= FULL_PAGE_SIZE(share);
ulong pages_left= (length + data_size -1) / data_size;
uint page_count, ranges, empty_space;
uchar *to_start;
DBUG_ENTER("store_page_range");
to_start= to;
to+= SUB_RANGE_SIZE;
/* Store number of unused bytes at last page */
empty_space= (uint) (pages_left * data_size - length);
int2store(to, empty_space);
to+= BLOCK_FILLER_SIZE;
ranges= 0;
do
{
pgcache_page_no_t page;
page= block->page;
page_count= block->page_count;
block++;
if (page_count > pages_left)
page_count= pages_left;
page_store(to, page);
to+= PAGE_STORE_SIZE;
pagerange_store(to, page_count);
to+= PAGERANGE_STORE_SIZE;
ranges++;
} while ((pages_left-= page_count));
/* Store number of ranges for this block */
int2store(to_start, ranges);
(*tot_ranges)+= ranges;
DBUG_RETURN(to);
}
|
O0
|
c
|
store_page_range:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x8(%rbp), %rax
movl 0x7bc(%rax), %eax
movq -0x8(%rbp), %rcx
movl 0xc18(%rcx), %ecx
addl $0x8, %ecx
subl %ecx, %eax
subl $0x4, %eax
movl %eax, -0x2c(%rbp)
movq -0x20(%rbp), %rax
movl -0x2c(%rbp), %ecx
addq %rcx, %rax
subq $0x1, %rax
movl -0x2c(%rbp), %ecx
xorl %edx, %edx
divq %rcx
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x10(%rbp)
movq -0x38(%rbp), %rax
movl -0x2c(%rbp), %ecx
imulq %rcx, %rax
subq -0x20(%rbp), %rax
movl %eax, -0x44(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x58(%rbp)
movl -0x44(%rbp), %eax
movw %ax, %cx
movq -0x58(%rbp), %rax
movw %cx, (%rax)
movq -0x10(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x10(%rbp)
movl $0x0, -0x40(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x60(%rbp)
movq -0x18(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0x3c(%rbp)
movq -0x18(%rbp), %rax
addq $0x18, %rax
movq %rax, -0x18(%rbp)
movl -0x3c(%rbp), %eax
cmpq -0x38(%rbp), %rax
jbe 0x5eb60
movq -0x38(%rbp), %rax
movl %eax, -0x3c(%rbp)
jmp 0x5eb62
movq -0x10(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x60(%rbp), %rax
movl %eax, %ecx
movq -0x68(%rbp), %rax
movl %ecx, (%rax)
movq -0x60(%rbp), %rax
shrq $0x20, %rax
movb %al, %cl
movq -0x68(%rbp), %rax
movb %cl, 0x4(%rax)
movq -0x10(%rbp), %rax
addq $0x5, %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x70(%rbp)
movl -0x3c(%rbp), %eax
movw %ax, %cx
movq -0x70(%rbp), %rax
movw %cx, (%rax)
movq -0x10(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x10(%rbp)
movl -0x40(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x40(%rbp)
movl -0x3c(%rbp), %eax
movl %eax, %ecx
movq -0x38(%rbp), %rax
subq %rcx, %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, %rax
jne 0x5eb2f
jmp 0x5ebd9
movq -0x50(%rbp), %rax
movq %rax, -0x78(%rbp)
movl -0x40(%rbp), %eax
movw %ax, %cx
movq -0x78(%rbp), %rax
movw %cx, (%rax)
movl -0x40(%rbp), %ecx
movq -0x28(%rbp), %rax
addl (%rax), %ecx
movl %ecx, (%rax)
movq -0x10(%rbp), %rax
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
popq %rbp
retq
nopw (%rax,%rax)
|
store_page_range:
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_28], r8
mov rax, [rbp+var_8]
mov eax, [rax+7BCh]
mov rcx, [rbp+var_8]
mov ecx, [rcx+0C18h]
add ecx, 8
sub eax, ecx
sub eax, 4
mov [rbp+var_2C], eax
mov rax, [rbp+var_20]
mov ecx, [rbp+var_2C]
add rax, rcx
sub rax, 1
mov ecx, [rbp+var_2C]
xor edx, edx
div rcx
mov [rbp+var_38], rax
mov rax, [rbp+var_10]
mov [rbp+var_50], rax
mov rax, [rbp+var_10]
add rax, 2
mov [rbp+var_10], rax
mov rax, [rbp+var_38]
mov ecx, [rbp+var_2C]
imul rax, rcx
sub rax, [rbp+var_20]
mov [rbp+var_44], eax
mov rax, [rbp+var_10]
mov [rbp+var_58], rax
mov eax, [rbp+var_44]
mov cx, ax
mov rax, [rbp+var_58]
mov [rax], cx
mov rax, [rbp+var_10]
add rax, 2
mov [rbp+var_10], rax
mov [rbp+var_40], 0
loc_5EB2F:
mov rax, [rbp+var_18]
mov rax, [rax]
mov [rbp+var_60], rax
mov rax, [rbp+var_18]
mov eax, [rax+8]
mov [rbp+var_3C], eax
mov rax, [rbp+var_18]
add rax, 18h
mov [rbp+var_18], rax
mov eax, [rbp+var_3C]
cmp rax, [rbp+var_38]
jbe short loc_5EB60
mov rax, [rbp+var_38]
mov [rbp+var_3C], eax
loc_5EB60:
jmp short $+2
loc_5EB62:
mov rax, [rbp+var_10]
mov [rbp+var_68], rax
mov rax, [rbp+var_60]
mov ecx, eax
mov rax, [rbp+var_68]
mov [rax], ecx
mov rax, [rbp+var_60]
shr rax, 20h
mov cl, al
mov rax, [rbp+var_68]
mov [rax+4], cl
mov rax, [rbp+var_10]
add rax, 5
mov [rbp+var_10], rax
mov rax, [rbp+var_10]
mov [rbp+var_70], rax
mov eax, [rbp+var_3C]
mov cx, ax
mov rax, [rbp+var_70]
mov [rax], cx
mov rax, [rbp+var_10]
add rax, 2
mov [rbp+var_10], rax
mov eax, [rbp+var_40]
add eax, 1
mov [rbp+var_40], eax
mov eax, [rbp+var_3C]
mov ecx, eax
mov rax, [rbp+var_38]
sub rax, rcx
mov [rbp+var_38], rax
cmp rax, 0
jnz loc_5EB2F
jmp short $+2
loc_5EBD9:
mov rax, [rbp+var_50]
mov [rbp+var_78], rax
mov eax, [rbp+var_40]
mov cx, ax
mov rax, [rbp+var_78]
mov [rax], cx
mov ecx, [rbp+var_40]
mov rax, [rbp+var_28]
add ecx, [rax]
mov [rax], ecx
mov rax, [rbp+var_10]
mov [rbp+var_80], rax
mov rax, [rbp+var_80]
pop rbp
retn
|
_WORD * store_page_range(long long a1, _WORD *a2, long long *a3, long long a4, _DWORD *a5)
{
long long v6; // [rsp+20h] [rbp-60h]
int v7; // [rsp+40h] [rbp-40h]
unsigned int v8; // [rsp+44h] [rbp-3Ch]
unsigned long long v9; // [rsp+48h] [rbp-38h]
unsigned int v10; // [rsp+54h] [rbp-2Ch]
_WORD *v12; // [rsp+70h] [rbp-10h]
v10 = *(_DWORD *)(a1 + 1980) - (*(_DWORD *)(a1 + 3096) + 8) - 4;
v9 = ((unsigned long long)v10 + a4 - 1) / v10;
a2[1] = v10 * v9 - a4;
v12 = a2 + 2;
v7 = 0;
do
{
v6 = *a3;
v8 = *((_DWORD *)a3 + 2);
a3 += 3;
if ( v8 > v9 )
v8 = v9;
*(_DWORD *)v12 = v6;
*((_BYTE *)v12 + 4) = BYTE4(v6);
*(_WORD *)((char *)v12 + 5) = v8;
v12 = (_WORD *)((char *)v12 + 7);
++v7;
v9 -= v8;
}
while ( v9 );
*a2 = v7;
*a5 += v7;
return v12;
}
|
store_page_range:
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],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x7bc]
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0xc18]
ADD ECX,0x8
SUB EAX,ECX
SUB EAX,0x4
MOV dword ptr [RBP + -0x2c],EAX
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RBP + -0x2c]
ADD RAX,RCX
SUB RAX,0x1
MOV ECX,dword ptr [RBP + -0x2c]
XOR EDX,EDX
DIV RCX
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x2
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV ECX,dword ptr [RBP + -0x2c]
IMUL RAX,RCX
SUB RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RBP + -0x44],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x58],RAX
MOV EAX,dword ptr [RBP + -0x44]
MOV CX,AX
MOV RAX,qword ptr [RBP + -0x58]
MOV word ptr [RAX],CX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x2
MOV qword ptr [RBP + -0x10],RAX
MOV dword ptr [RBP + -0x40],0x0
LAB_0015eb2f:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RAX + 0x8]
MOV dword ptr [RBP + -0x3c],EAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x18
MOV qword ptr [RBP + -0x18],RAX
MOV EAX,dword ptr [RBP + -0x3c]
CMP RAX,qword ptr [RBP + -0x38]
JBE 0x0015eb60
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RBP + -0x3c],EAX
LAB_0015eb60:
JMP 0x0015eb62
LAB_0015eb62:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RBP + -0x60]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x68]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x60]
SHR RAX,0x20
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x68]
MOV byte ptr [RAX + 0x4],CL
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x5
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x70],RAX
MOV EAX,dword ptr [RBP + -0x3c]
MOV CX,AX
MOV RAX,qword ptr [RBP + -0x70]
MOV word ptr [RAX],CX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x2
MOV qword ptr [RBP + -0x10],RAX
MOV EAX,dword ptr [RBP + -0x40]
ADD EAX,0x1
MOV dword ptr [RBP + -0x40],EAX
MOV EAX,dword ptr [RBP + -0x3c]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x38]
SUB RAX,RCX
MOV qword ptr [RBP + -0x38],RAX
CMP RAX,0x0
JNZ 0x0015eb2f
JMP 0x0015ebd9
LAB_0015ebd9:
MOV RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x78],RAX
MOV EAX,dword ptr [RBP + -0x40]
MOV CX,AX
MOV RAX,qword ptr [RBP + -0x78]
MOV word ptr [RAX],CX
MOV ECX,dword ptr [RBP + -0x40]
MOV RAX,qword ptr [RBP + -0x28]
ADD ECX,dword ptr [RAX]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x80],RAX
MOV RAX,qword ptr [RBP + -0x80]
POP RBP
RET
|
int4 *
store_page_range(long param_1,int2 *param_2,int8 *param_3,long param_4,int *param_5)
{
int8 uVar1;
uint uVar2;
int local_48;
uint local_44;
ulong local_40;
int8 *local_20;
int4 *local_18;
uVar2 = (*(int *)(param_1 + 0x7bc) - (*(int *)(param_1 + 0xc18) + 8)) - 4;
local_40 = ((param_4 + (ulong)uVar2) - 1) / (ulong)uVar2;
param_2[1] = (short)local_40 * (short)uVar2 - (short)param_4;
local_18 = (int4 *)(param_2 + 2);
local_48 = 0;
local_20 = param_3;
do {
uVar1 = *local_20;
local_44 = *(uint *)(local_20 + 1);
local_20 = local_20 + 3;
if (local_40 < local_44) {
local_44 = (uint)local_40;
}
*local_18 = (int)uVar1;
*(char *)(local_18 + 1) = (char)((ulong)uVar1 >> 0x20);
*(short *)((long)local_18 + 5) = (short)local_44;
local_18 = (int4 *)((long)local_18 + 7);
local_48 = local_48 + 1;
local_40 = local_40 - local_44;
} while (local_40 != 0);
*param_2 = (short)local_48;
*param_5 = local_48 + *param_5;
return local_18;
}
|
|
19,904
|
ma_sp_make_key
|
eloqsql/storage/maria/ma_sp_key.c
|
MARIA_KEY *_ma_sp_make_key(MARIA_HA *info, MARIA_KEY *ret_key, uint keynr,
uchar *key, const uchar *record, my_off_t filepos,
ulonglong trid)
{
HA_KEYSEG *keyseg;
MARIA_KEYDEF *keyinfo = &info->s->keyinfo[keynr];
uint len = 0;
const uchar *pos;
uint dlen;
uchar *dptr;
double mbr[SPDIMS * 2];
uint i;
DBUG_ENTER("_ma_sp_make_key");
keyseg = &keyinfo->seg[-1];
pos = record + keyseg->start;
ret_key->data= key;
dlen = _ma_calc_blob_length(keyseg->bit_start, pos);
memcpy(&dptr, pos + keyseg->bit_start, sizeof(char*));
if (!dptr)
{
my_errno= HA_ERR_NULL_IN_SPATIAL;
DBUG_RETURN(0);
}
sp_mbr_from_wkb(dptr + 4, dlen - 4, SPDIMS, mbr); /* SRID */
for (i = 0, keyseg = keyinfo->seg; keyseg->type; keyseg++, i++)
{
uint length = keyseg->length, start= keyseg->start;
double val;
DBUG_ASSERT(length == 8);
DBUG_ASSERT(!(start % 8));
DBUG_ASSERT(start < sizeof(mbr));
DBUG_ASSERT(keyseg->type == HA_KEYTYPE_DOUBLE);
val= mbr[start / sizeof (double)];
if (isnan(val))
{
bzero(key, length);
key+= length;
len+= length;
continue;
}
if (keyseg->flag & HA_SWAP_KEY)
{
mi_float8store(key, val);
}
else
{
float8store((uchar *)key, val);
}
key += length;
len+= length;
}
_ma_dpointer(info->s, key, filepos);
ret_key->keyinfo= keyinfo;
ret_key->data_length= len;
ret_key->ref_length= info->s->rec_reflength;
ret_key->flag= 0;
if (_ma_have_versioning(info) && trid)
{
ret_key->ref_length+= transid_store_packed(info,
key + ret_key->ref_length,
trid);
}
DBUG_EXECUTE("key", _ma_print_key(DBUG_FILE, ret_key););
DBUG_RETURN(ret_key);
}
|
O3
|
c
|
ma_sp_make_key:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r9, -0x38(%rbp)
movq %rcx, %r14
movq %rdi, -0x40(%rbp)
movq (%rdi), %rax
movq 0x570(%rax), %rbx
movl %edx, %eax
imulq $0x118, %rax, %r12 # imm = 0x118
movq 0xc0(%rbx,%r12), %r15
movl -0x18(%r15), %r13d
addq %r8, %r13
movq %rsi, -0x48(%rbp)
movq %rcx, (%rsi)
movzbl -0x6(%r15), %edi
movq %r13, %rsi
callq 0x4956f
movzbl -0x6(%r15), %ecx
movq (%rcx,%r13), %rcx
testq %rcx, %rcx
je 0x720f9
addq %r12, %rbx
leaq 0x4(%rcx), %rdx
addl $-0x4, %eax
leaq -0x50(%rbp), %rdi
movq %rdx, (%rdi)
movapd 0x73743(%rip), %xmm0 # 0xe5750
leaq -0x70(%rbp), %rdx
movapd %xmm0, (%rdx)
movapd %xmm0, 0x10(%rdx)
leaq (%rcx,%rax), %rsi
addq $0x4, %rsi
movl $0x1, %ecx
callq 0x7217c
movq 0xc0(%rbx), %r12
cmpb $0x0, 0x18(%r12)
movq %rbx, -0x30(%rbp)
je 0x72108
addq $0x8, %r12
xorl %r15d, %r15d
movzwl 0xc(%r12), %ebx
movl (%r12), %eax
andl $-0x8, %eax
movsd -0x70(%rbp,%rax), %xmm0
ucomisd %xmm0, %xmm0
jp 0x720e7
testb $0x40, 0xa(%r12)
jne 0x72076
movsd %xmm0, (%r14)
jmp 0x720cb
movq %xmm0, %rax
movq %rax, %rcx
shrq $0x38, %rcx
movq %rax, %rdx
shrq $0x30, %rdx
movq %rax, %rsi
shrq $0x28, %rsi
movq %rax, %rdi
shrq $0x20, %rdi
movl %eax, %r8d
shrl $0x18, %r8d
movl %eax, %r9d
shrl $0x10, %r9d
movl %eax, %r10d
shrl $0x8, %r10d
movb %cl, (%r14)
movb %dl, 0x1(%r14)
movb %sil, 0x2(%r14)
movb %dil, 0x3(%r14)
movb %r8b, 0x4(%r14)
movb %r9b, 0x5(%r14)
movb %r10b, 0x6(%r14)
movb %al, 0x7(%r14)
movq %rbx, %r13
addq %r13, %r14
addl %ebx, %r15d
cmpb $0x0, 0x30(%r12)
leaq 0x20(%r12), %r12
jne 0x7204a
jmp 0x7210b
movl %ebx, %r13d
movq %r14, %rdi
xorl %esi, %esi
movq %r13, %rdx
callq 0x2a290
jmp 0x720ce
callq 0xa63fe
movl $0x9e, (%rax)
xorl %ebx, %ebx
jmp 0x7216a
xorl %r15d, %r15d
movq -0x40(%rbp), %r12
movq (%r12), %rdi
movq %r14, %rsi
movq -0x38(%rbp), %rdx
callq 0x6ecb8
movq -0x48(%rbp), %rbx
movq -0x30(%rbp), %rax
movq %rax, 0x8(%rbx)
movl %r15d, 0x10(%rbx)
movq (%r12), %rax
movl 0x740(%rax), %eax
movl %eax, 0x14(%rbx)
movl $0x0, 0x18(%rbx)
movq 0x10(%rbp), %rdx
testq %rdx, %rdx
je 0x7216a
movl 0x618(%r12), %ecx
andl $0x1, %ecx
je 0x7216a
addq %rax, %r14
movq %r12, %rdi
movq %r14, %rsi
callq 0x41d78
addl %eax, 0x14(%rbx)
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
_ma_sp_make_key:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov [rbp+var_38], r9
mov r14, rcx
mov [rbp+var_40], rdi
mov rax, [rdi]
mov rbx, [rax+570h]
mov eax, edx
imul r12, rax, 118h
mov r15, [rbx+r12+0C0h]
mov r13d, [r15-18h]
add r13, r8
mov [rbp+var_48], rsi
mov [rsi], rcx
movzx edi, byte ptr [r15-6]
mov rsi, r13
call _ma_calc_blob_length
movzx ecx, byte ptr [r15-6]
mov rcx, [rcx+r13]
test rcx, rcx
jz loc_720F9
add rbx, r12
lea rdx, [rcx+4]
add eax, 0FFFFFFFCh
lea rdi, [rbp+var_50]
mov [rdi], rdx
movapd xmm0, cs:xmmword_E5750
lea rdx, [rbp+var_70]
movapd xmmword ptr [rdx], xmm0
movapd xmmword ptr [rdx+10h], xmm0
lea rsi, [rcx+rax]
add rsi, 4
mov ecx, 1
call sp_get_geometry_mbr
mov r12, [rbx+0C0h]
cmp byte ptr [r12+18h], 0
mov [rbp+var_30], rbx
jz loc_72108
add r12, 8
xor r15d, r15d
loc_7204A:
movzx ebx, word ptr [r12+0Ch]
mov eax, [r12]
and eax, 0FFFFFFF8h
movsd xmm0, [rbp+rax+var_70]
ucomisd xmm0, xmm0
jp loc_720E7
test byte ptr [r12+0Ah], 40h
jnz short loc_72076
movsd qword ptr [r14], xmm0
jmp short loc_720CB
loc_72076:
movq rax, xmm0
mov rcx, rax
shr rcx, 38h
mov rdx, rax
shr rdx, 30h
mov rsi, rax
shr rsi, 28h
mov rdi, rax
shr rdi, 20h
mov r8d, eax
shr r8d, 18h
mov r9d, eax
shr r9d, 10h
mov r10d, eax
shr r10d, 8
mov [r14], cl
mov [r14+1], dl
mov [r14+2], sil
mov [r14+3], dil
mov [r14+4], r8b
mov [r14+5], r9b
mov [r14+6], r10b
mov [r14+7], al
loc_720CB:
mov r13, rbx
loc_720CE:
add r14, r13
add r15d, ebx
cmp byte ptr [r12+30h], 0
lea r12, [r12+20h]
jnz loc_7204A
jmp short loc_7210B
loc_720E7:
mov r13d, ebx
mov rdi, r14
xor esi, esi
mov rdx, r13
call _memset
jmp short loc_720CE
loc_720F9:
call _my_thread_var
mov dword ptr [rax], 9Eh
xor ebx, ebx
jmp short loc_7216A
loc_72108:
xor r15d, r15d
loc_7210B:
mov r12, [rbp+var_40]
mov rdi, [r12]
mov rsi, r14
mov rdx, [rbp+var_38]
call _ma_dpointer
mov rbx, [rbp+var_48]
mov rax, [rbp+var_30]
mov [rbx+8], rax
mov [rbx+10h], r15d
mov rax, [r12]
mov eax, [rax+740h]
mov [rbx+14h], eax
mov dword ptr [rbx+18h], 0
mov rdx, [rbp+arg_0]
test rdx, rdx
jz short loc_7216A
mov ecx, [r12+618h]
and ecx, 1
jz short loc_7216A
add r14, rax
mov rdi, r12
mov rsi, r14
call transid_store_packed
add [rbx+14h], eax
loc_7216A:
mov rax, rbx
add rsp, 48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
_QWORD * ma_sp_make_key(
long long *a1,
_QWORD *a2,
unsigned int a3,
_BYTE *a4,
long long a5,
long long a6,
long long a7)
{
_BYTE *v7; // r14
long long v8; // rbx
long long v9; // r12
long long v10; // r15
unsigned __int8 *v11; // r13
long long v12; // rdi
int v13; // eax
long long v14; // rcx
long long v15; // rbx
long long v16; // r12
bool v17; // zf
long long v18; // r12
int v19; // r15d
long long v20; // rbx
long long v21; // xmm0_8
_QWORD *v22; // rbx
long long *v23; // r12
long long v24; // rax
_OWORD v26[2]; // [rsp+0h] [rbp-70h] BYREF
long long v27; // [rsp+20h] [rbp-50h] BYREF
_QWORD *v28; // [rsp+28h] [rbp-48h]
long long *v29; // [rsp+30h] [rbp-40h]
long long v30; // [rsp+38h] [rbp-38h]
long long v31; // [rsp+40h] [rbp-30h]
v30 = a6;
v7 = a4;
v29 = a1;
v8 = *(_QWORD *)(*a1 + 1392);
v9 = 280LL * a3;
v10 = *(_QWORD *)(v8 + v9 + 192);
v11 = (unsigned __int8 *)(a5 + *(unsigned int *)(v10 - 24));
v28 = a2;
*a2 = a4;
v12 = *(unsigned __int8 *)(v10 - 6);
v13 = ma_calc_blob_length(v12, v11);
v14 = *(_QWORD *)&v11[*(unsigned __int8 *)(v10 - 6)];
if ( v14 )
{
v15 = v9 + v8;
v27 = v14 + 4;
v26[0] = xmmword_E5750;
v26[1] = xmmword_E5750;
((void ( *)(long long *, long long, _OWORD *, long long))sp_get_geometry_mbr)(
&v27,
v14 + (unsigned int)(v13 - 4) + 4,
v26,
1LL);
v16 = *(_QWORD *)(v15 + 192);
v17 = *(_BYTE *)(v16 + 24) == 0;
v31 = v15;
if ( v17 )
{
v19 = 0;
}
else
{
v18 = v16 + 8;
v19 = 0;
do
{
v20 = *(unsigned __int16 *)(v18 + 12);
v21 = *(_QWORD *)((char *)v26 + (*(_DWORD *)v18 & 0xFFFFFFF8));
if ( (*(_BYTE *)(v18 + 10) & 0x40) != 0 )
{
*v7 = HIBYTE(v21);
v7[1] = BYTE6(v21);
v7[2] = BYTE5(v21);
v7[3] = BYTE4(v21);
v7[4] = BYTE3(v21);
v7[5] = BYTE2(v21);
v7[6] = BYTE1(v21);
v7[7] = v21;
}
else
{
*(_QWORD *)v7 = v21;
}
v7 += v20;
v19 += v20;
v17 = *(_BYTE *)(v18 + 48) == 0;
v18 += 32LL;
}
while ( !v17 );
}
v23 = v29;
ma_dpointer(*v29, (long long)v7, v30);
v22 = v28;
v28[1] = v31;
*((_DWORD *)v22 + 4) = v19;
v24 = *(unsigned int *)(*v23 + 1856);
*(_QWORD *)((char *)v22 + 20) = (unsigned int)v24;
if ( a7 && (v23[195] & 1) != 0 )
*((_DWORD *)v22 + 5) += transid_store_packed((long long)v23, &v7[v24], a7);
}
else
{
*(_DWORD *)my_thread_var(v12, (const char *)v11) = 158;
return 0LL;
}
return v22;
}
|
_ma_sp_make_key:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV qword ptr [RBP + -0x38],R9
MOV R14,RCX
MOV qword ptr [RBP + -0x40],RDI
MOV RAX,qword ptr [RDI]
MOV RBX,qword ptr [RAX + 0x570]
MOV EAX,EDX
IMUL R12,RAX,0x118
MOV R15,qword ptr [RBX + R12*0x1 + 0xc0]
MOV R13D,dword ptr [R15 + -0x18]
ADD R13,R8
MOV qword ptr [RBP + -0x48],RSI
MOV qword ptr [RSI],RCX
MOVZX EDI,byte ptr [R15 + -0x6]
MOV RSI,R13
CALL 0x0014956f
MOVZX ECX,byte ptr [R15 + -0x6]
MOV RCX,qword ptr [RCX + R13*0x1]
TEST RCX,RCX
JZ 0x001720f9
ADD RBX,R12
LEA RDX,[RCX + 0x4]
ADD EAX,-0x4
LEA RDI,[RBP + -0x50]
MOV qword ptr [RDI],RDX
MOVAPD XMM0,xmmword ptr [0x001e5750]
LEA RDX,[RBP + -0x70]
MOVAPD xmmword ptr [RDX],XMM0
MOVAPD xmmword ptr [RDX + 0x10],XMM0
LEA RSI,[RCX + RAX*0x1]
ADD RSI,0x4
MOV ECX,0x1
CALL 0x0017217c
MOV R12,qword ptr [RBX + 0xc0]
CMP byte ptr [R12 + 0x18],0x0
MOV qword ptr [RBP + -0x30],RBX
JZ 0x00172108
ADD R12,0x8
XOR R15D,R15D
LAB_0017204a:
MOVZX EBX,word ptr [R12 + 0xc]
MOV EAX,dword ptr [R12]
AND EAX,0xfffffff8
MOVSD XMM0,qword ptr [RBP + RAX*0x1 + -0x70]
UCOMISD XMM0,XMM0
JP 0x001720e7
TEST byte ptr [R12 + 0xa],0x40
JNZ 0x00172076
MOVSD qword ptr [R14],XMM0
JMP 0x001720cb
LAB_00172076:
MOVQ RAX,XMM0
MOV RCX,RAX
SHR RCX,0x38
MOV RDX,RAX
SHR RDX,0x30
MOV RSI,RAX
SHR RSI,0x28
MOV RDI,RAX
SHR RDI,0x20
MOV R8D,EAX
SHR R8D,0x18
MOV R9D,EAX
SHR R9D,0x10
MOV R10D,EAX
SHR R10D,0x8
MOV byte ptr [R14],CL
MOV byte ptr [R14 + 0x1],DL
MOV byte ptr [R14 + 0x2],SIL
MOV byte ptr [R14 + 0x3],DIL
MOV byte ptr [R14 + 0x4],R8B
MOV byte ptr [R14 + 0x5],R9B
MOV byte ptr [R14 + 0x6],R10B
MOV byte ptr [R14 + 0x7],AL
LAB_001720cb:
MOV R13,RBX
LAB_001720ce:
ADD R14,R13
ADD R15D,EBX
CMP byte ptr [R12 + 0x30],0x0
LEA R12,[R12 + 0x20]
JNZ 0x0017204a
JMP 0x0017210b
LAB_001720e7:
MOV R13D,EBX
MOV RDI,R14
XOR ESI,ESI
MOV RDX,R13
CALL 0x0012a290
JMP 0x001720ce
LAB_001720f9:
CALL 0x001a63fe
MOV dword ptr [RAX],0x9e
XOR EBX,EBX
JMP 0x0017216a
LAB_00172108:
XOR R15D,R15D
LAB_0017210b:
MOV R12,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [R12]
MOV RSI,R14
MOV RDX,qword ptr [RBP + -0x38]
CALL 0x0016ecb8
MOV RBX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBX + 0x8],RAX
MOV dword ptr [RBX + 0x10],R15D
MOV RAX,qword ptr [R12]
MOV EAX,dword ptr [RAX + 0x740]
MOV dword ptr [RBX + 0x14],EAX
MOV dword ptr [RBX + 0x18],0x0
MOV RDX,qword ptr [RBP + 0x10]
TEST RDX,RDX
JZ 0x0017216a
MOV ECX,dword ptr [R12 + 0x618]
AND ECX,0x1
JZ 0x0017216a
ADD R14,RAX
MOV RDI,R12
MOV RSI,R14
CALL 0x00141d78
ADD dword ptr [RBX + 0x14],EAX
LAB_0017216a:
MOV RAX,RBX
ADD RSP,0x48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
int8 *
_ma_sp_make_key(long *param_1,int8 *param_2,ulong param_3,double *param_4,long param_5,
int8 param_6,long param_7)
{
uint *puVar1;
double dVar2;
ushort uVar3;
uint uVar4;
long lVar5;
long *plVar6;
int4 *puVar7;
long lVar8;
int8 *puVar9;
long lVar10;
uint *puVar11;
int iVar12;
double local_78 [4];
long local_58;
int8 *local_50;
long *local_48;
int8 local_40;
long local_38;
lVar8 = *(long *)(*param_1 + 0x570);
lVar10 = (param_3 & 0xffffffff) * 0x118;
lVar5 = *(long *)(lVar8 + 0xc0 + lVar10);
param_5 = (ulong)*(uint *)(lVar5 + -0x18) + param_5;
*param_2 = param_4;
local_50 = param_2;
local_48 = param_1;
local_40 = param_6;
_ma_calc_blob_length(*(int1 *)(lVar5 + -6),param_5);
local_58 = *(long *)((ulong)*(byte *)(lVar5 + -6) + param_5);
if (local_58 == 0) {
puVar7 = (int4 *)_my_thread_var();
*puVar7 = 0x9e;
puVar9 = (int8 *)0x0;
}
else {
lVar8 = lVar8 + lVar10;
local_58 = local_58 + 4;
local_78[0] = _DAT_001e5750;
local_78[1] = (double)_UNK_001e5758;
local_78[2] = _DAT_001e5750;
local_78[3] = (double)_UNK_001e5758;
sp_get_geometry_mbr();
lVar5 = *(long *)(lVar8 + 0xc0);
local_38 = lVar8;
if (*(char *)(lVar5 + 0x18) == '\0') {
iVar12 = 0;
}
else {
puVar11 = (uint *)(lVar5 + 8);
iVar12 = 0;
do {
uVar3 = (ushort)puVar11[3];
dVar2 = *(double *)((long)local_78 + (ulong)(*puVar11 & 0xfffffff8));
if (NAN(dVar2)) {
memset(param_4,0,(ulong)uVar3);
}
else if ((*(byte *)((long)puVar11 + 10) & 0x40) == 0) {
*param_4 = dVar2;
}
else {
*(char *)param_4 = (char)((ulong)dVar2 >> 0x38);
*(char *)((long)param_4 + 1) = (char)((ulong)dVar2 >> 0x30);
*(char *)((long)param_4 + 2) = (char)((ulong)dVar2 >> 0x28);
*(char *)((long)param_4 + 3) = (char)((ulong)dVar2 >> 0x20);
*(char *)((long)param_4 + 4) = (char)((ulong)dVar2 >> 0x18);
*(char *)((long)param_4 + 5) = (char)((ulong)dVar2 >> 0x10);
*(char *)((long)param_4 + 6) = (char)((ulong)dVar2 >> 8);
*(char *)((long)param_4 + 7) = SUB81(dVar2,0);
}
param_4 = (double *)((long)param_4 + (ulong)uVar3);
iVar12 = iVar12 + (uint)uVar3;
puVar1 = puVar11 + 0xc;
puVar11 = puVar11 + 8;
} while ((char)*puVar1 != '\0');
}
plVar6 = local_48;
_ma_dpointer(*local_48,param_4,local_40);
puVar9 = local_50;
local_50[1] = local_38;
*(int *)(local_50 + 2) = iVar12;
uVar4 = *(uint *)(*plVar6 + 0x740);
*(uint *)((long)local_50 + 0x14) = uVar4;
*(int4 *)(local_50 + 3) = 0;
if ((param_7 != 0) && ((*(uint *)(plVar6 + 0xc3) & 1) != 0)) {
iVar12 = transid_store_packed(plVar6,(long)param_4 + (ulong)uVar4);
*(int *)((long)puVar9 + 0x14) = *(int *)((long)puVar9 + 0x14) + iVar12;
}
}
return puVar9;
}
|
|
19,905
|
list_delete
|
eloqsql/mysys/list.c
|
LIST *list_delete(LIST *root, LIST *element)
{
if (element->prev)
element->prev->next=element->next;
else
root=element->next;
if (element->next)
element->next->prev=element->prev;
return root;
}
|
O0
|
c
|
list_delete:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, (%rax)
je 0x6d8bb
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rcx, 0x8(%rax)
jmp 0x6d8c7
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x8(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x6d8e4
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rcx, (%rax)
movq -0x8(%rbp), %rax
popq %rbp
retq
nopw (%rax,%rax)
|
list_delete:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_10]
cmp qword ptr [rax], 0
jz short loc_6D8BB
mov rax, [rbp+var_10]
mov rcx, [rax+8]
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rax+8], rcx
jmp short loc_6D8C7
loc_6D8BB:
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov [rbp+var_8], rax
loc_6D8C7:
mov rax, [rbp+var_10]
cmp qword ptr [rax+8], 0
jz short loc_6D8E4
mov rax, [rbp+var_10]
mov rcx, [rax]
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov [rax], rcx
loc_6D8E4:
mov rax, [rbp+var_8]
pop rbp
retn
|
long long list_delete(long long a1, _QWORD *a2)
{
if ( *a2 )
*(_QWORD *)(*a2 + 8LL) = a2[1];
else
a1 = a2[1];
if ( a2[1] )
*(_QWORD *)a2[1] = *a2;
return a1;
}
|
list_delete:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX],0x0
JZ 0x0016d8bb
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
JMP 0x0016d8c7
LAB_0016d8bb:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x8],RAX
LAB_0016d8c7:
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x8],0x0
JZ 0x0016d8e4
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RAX],RCX
LAB_0016d8e4:
MOV RAX,qword ptr [RBP + -0x8]
POP RBP
RET
|
long list_delete(long param_1,long *param_2)
{
long local_10;
if (*param_2 == 0) {
local_10 = param_2[1];
}
else {
*(long *)(*param_2 + 8) = param_2[1];
local_10 = param_1;
}
if (param_2[1] != 0) {
*(long *)param_2[1] = *param_2;
}
return local_10;
}
|
|
19,906
|
my_convert_fix
|
eloqsql/strings/ctype.c
|
size_t
my_convert_fix(CHARSET_INFO *to_cs, char *to, size_t to_length,
CHARSET_INFO *from_cs, const char *from, size_t from_length,
size_t nchars,
MY_STRCOPY_STATUS *copy_status,
MY_STRCONV_STATUS *conv_status)
{
int cnvres;
my_wc_t wc;
my_charset_conv_mb_wc mb_wc= from_cs->cset->mb_wc;
my_charset_conv_wc_mb wc_mb= to_cs->cset->wc_mb;
const uchar *from_end= (const uchar*) from + from_length;
uchar *to_end= (uchar*) to + to_length;
char *to_start= to;
DBUG_ASSERT(to_cs != &my_charset_bin);
DBUG_ASSERT(from_cs != &my_charset_bin);
copy_status->m_well_formed_error_pos= NULL;
conv_status->m_cannot_convert_error_pos= NULL;
for ( ; nchars; nchars--)
{
const char *from_prev= from;
if ((cnvres= (*mb_wc)(from_cs, &wc, (uchar*) from, from_end)) > 0)
from+= cnvres;
else if (cnvres == MY_CS_ILSEQ)
{
if (!copy_status->m_well_formed_error_pos)
copy_status->m_well_formed_error_pos= from;
from++;
wc= '?';
}
else if (cnvres > MY_CS_TOOSMALL)
{
/*
A correct multibyte sequence detected
But it doesn't have Unicode mapping.
*/
if (!conv_status->m_cannot_convert_error_pos)
conv_status->m_cannot_convert_error_pos= from;
from+= (-cnvres);
wc= '?';
}
else
{
if ((uchar *) from >= from_end)
break; // End of line
// Incomplete byte sequence
if (!copy_status->m_well_formed_error_pos)
copy_status->m_well_formed_error_pos= from;
from++;
wc= '?';
}
outp:
if ((cnvres= (*wc_mb)(to_cs, wc, (uchar*) to, to_end)) > 0)
to+= cnvres;
else if (cnvres == MY_CS_ILUNI && wc != '?')
{
if (!conv_status->m_cannot_convert_error_pos)
conv_status->m_cannot_convert_error_pos= from_prev;
wc= '?';
goto outp;
}
else
{
from= from_prev;
break;
}
}
copy_status->m_source_end_pos= from;
return to - to_start;
}
|
O3
|
c
|
my_convert_fix:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %r8, %r14
movq %rdx, %r12
movq %rdi, %r13
movq 0x20(%rbp), %rdi
movq 0x18(%rbp), %rdx
movq 0x10(%rbp), %r8
movq %rcx, -0x60(%rbp)
movq 0xb8(%rcx), %rax
movq 0x28(%rax), %rax
movq %rax, -0x58(%rbp)
movq 0xb8(%r13), %rax
movq 0x30(%rax), %rax
movq %rax, -0x40(%rbp)
xorl %eax, %eax
movq %rax, 0x8(%rdx)
movq %rax, (%rdi)
testq %r8, %r8
movq %rsi, -0x48(%rbp)
je 0xd33bf
movq %r8, -0x50(%rbp)
addq %r14, %r9
movq %r9, -0x38(%rbp)
addq %rsi, %r12
movq %rsi, %rbx
movq -0x60(%rbp), %rdi
leaq -0x30(%rbp), %rsi
movq %r14, %rdx
movq -0x38(%rbp), %rcx
callq *-0x58(%rbp)
movl %eax, %r15d
testl %eax, %eax
jle 0xd3337
movl %r15d, %r15d
addq %r14, %r15
movq -0x30(%rbp), %rsi
jmp 0xd336f
je 0xd335a
cmpl $-0x64, %r15d
jb 0xd3354
movq 0x20(%rbp), %rax
cmpq $0x0, (%rax)
jne 0xd334c
movq %r14, (%rax)
negl %r15d
addq %r14, %r15
jmp 0xd3397
cmpq -0x38(%rbp), %r14
jae 0xd33ba
movq 0x18(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0xd3369
movq %r14, 0x8(%rax)
leaq 0x1(%r14), %r15
jmp 0xd3397
movq %r13, %rdi
movq %rbx, %rdx
movq %r12, %rcx
callq *-0x40(%rbp)
testl %eax, %eax
jg 0xd33a6
testl %eax, %eax
jne 0xd33ba
cmpq $0x3f, -0x30(%rbp)
je 0xd33ba
movq 0x20(%rbp), %rax
cmpq $0x0, (%rax)
jne 0xd3397
movq %r14, (%rax)
movq $0x3f, -0x30(%rbp)
movl $0x3f, %esi
jmp 0xd336f
movl %eax, %eax
addq %rax, %rbx
movq %r15, %r14
decq -0x50(%rbp)
jne 0xd3312
jmp 0xd33c5
movq %r14, %r15
jmp 0xd33c5
movq %r14, %r15
movq %rsi, %rbx
movq 0x18(%rbp), %rax
movq %r15, (%rax)
subq -0x48(%rbp), %rbx
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
my_convert_fix:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov r14, r8
mov r12, rdx
mov r13, rdi
mov rdi, [rbp+arg_10]
mov rdx, [rbp+arg_8]
mov r8, [rbp+arg_0]
mov [rbp+var_60], rcx
mov rax, [rcx+0B8h]
mov rax, [rax+28h]
mov [rbp+var_58], rax
mov rax, [r13+0B8h]
mov rax, [rax+30h]
mov [rbp+var_40], rax
xor eax, eax
mov [rdx+8], rax
mov [rdi], rax
test r8, r8
mov [rbp+var_48], rsi
jz loc_D33BF
mov [rbp+var_50], r8
add r9, r14
mov [rbp+var_38], r9
add r12, rsi
mov rbx, rsi
loc_D3312:
mov rdi, [rbp+var_60]
lea rsi, [rbp+var_30]
mov rdx, r14
mov rcx, [rbp+var_38]
call [rbp+var_58]
mov r15d, eax
test eax, eax
jle short loc_D3337
mov r15d, r15d
add r15, r14
mov rsi, [rbp+var_30]
jmp short loc_D336F
loc_D3337:
jz short loc_D335A
cmp r15d, 0FFFFFF9Ch
jb short loc_D3354
mov rax, [rbp+arg_10]
cmp qword ptr [rax], 0
jnz short loc_D334C
mov [rax], r14
loc_D334C:
neg r15d
add r15, r14
jmp short loc_D3397
loc_D3354:
cmp r14, [rbp+var_38]
jnb short loc_D33BA
loc_D335A:
mov rax, [rbp+arg_8]
cmp qword ptr [rax+8], 0
jnz short loc_D3369
mov [rax+8], r14
loc_D3369:
lea r15, [r14+1]
jmp short loc_D3397
loc_D336F:
mov rdi, r13
mov rdx, rbx
mov rcx, r12
call [rbp+var_40]
test eax, eax
jg short loc_D33A6
test eax, eax
jnz short loc_D33BA
cmp [rbp+var_30], 3Fh ; '?'
jz short loc_D33BA
mov rax, [rbp+arg_10]
cmp qword ptr [rax], 0
jnz short loc_D3397
mov [rax], r14
loc_D3397:
mov [rbp+var_30], 3Fh ; '?'
mov esi, 3Fh ; '?'
jmp short loc_D336F
loc_D33A6:
mov eax, eax
add rbx, rax
mov r14, r15
dec [rbp+var_50]
jnz loc_D3312
jmp short loc_D33C5
loc_D33BA:
mov r15, r14
jmp short loc_D33C5
loc_D33BF:
mov r15, r14
mov rbx, rsi
loc_D33C5:
mov rax, [rbp+arg_8]
mov [rax], r15
sub rbx, [rbp+var_48]
mov rax, rbx
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long my_convert_fix(
long long a1,
long long a2,
long long a3,
long long a4,
unsigned long long a5,
long long a6,
long long a7,
unsigned long long *a8,
unsigned long long *a9)
{
unsigned long long v9; // r14
long long v10; // r12
long long v11; // rbx
int v12; // eax
unsigned long long v13; // r15
long long v14; // rsi
int v15; // eax
long long ( *v18)(long long, long long *, unsigned long long, unsigned long long); // [rsp+8h] [rbp-58h]
long long v19; // [rsp+10h] [rbp-50h]
long long ( *v21)(long long, long long, long long, long long); // [rsp+20h] [rbp-40h]
unsigned long long v22; // [rsp+28h] [rbp-38h]
long long v23[6]; // [rsp+30h] [rbp-30h] BYREF
v9 = a5;
v18 = *(long long ( **)(long long, long long *, unsigned long long, unsigned long long))(*(_QWORD *)(a4 + 184) + 40LL);
v21 = *(long long ( **)(long long, long long, long long, long long))(*(_QWORD *)(a1 + 184) + 48LL);
a8[1] = 0LL;
*a9 = 0LL;
if ( a7 )
{
v19 = a7;
v22 = a5 + a6;
v10 = a2 + a3;
v11 = a2;
while ( 1 )
{
v12 = v18(a4, v23, v9, v22);
if ( v12 > 0 )
{
v13 = v9 + (unsigned int)v12;
v14 = v23[0];
goto LABEL_14;
}
if ( !v12 )
goto LABEL_11;
if ( (unsigned int)v12 < 0xFFFFFF9C )
break;
if ( !*a9 )
*a9 = v9;
v13 = v9 + (unsigned int)-v12;
LABEL_19:
while ( 1 )
{
v23[0] = 63LL;
v14 = 63LL;
LABEL_14:
v15 = v21(a1, v14, v11, v10);
if ( v15 > 0 )
break;
if ( v15 || v23[0] == 63 )
goto LABEL_22;
if ( !*a9 )
*a9 = v9;
}
v11 += (unsigned int)v15;
v9 = v13;
if ( !--v19 )
goto LABEL_24;
}
if ( v9 < v22 )
{
LABEL_11:
if ( !a8[1] )
a8[1] = v9;
v13 = v9 + 1;
goto LABEL_19;
}
LABEL_22:
v13 = v9;
}
else
{
v13 = a5;
v11 = a2;
}
LABEL_24:
*a8 = v13;
return v11 - a2;
}
|
my_convert_fix:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV R14,R8
MOV R12,RDX
MOV R13,RDI
MOV RDI,qword ptr [RBP + 0x20]
MOV RDX,qword ptr [RBP + 0x18]
MOV R8,qword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x60],RCX
MOV RAX,qword ptr [RCX + 0xb8]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [R13 + 0xb8]
MOV RAX,qword ptr [RAX + 0x30]
MOV qword ptr [RBP + -0x40],RAX
XOR EAX,EAX
MOV qword ptr [RDX + 0x8],RAX
MOV qword ptr [RDI],RAX
TEST R8,R8
MOV qword ptr [RBP + -0x48],RSI
JZ 0x001d33bf
MOV qword ptr [RBP + -0x50],R8
ADD R9,R14
MOV qword ptr [RBP + -0x38],R9
ADD R12,RSI
MOV RBX,RSI
LAB_001d3312:
MOV RDI,qword ptr [RBP + -0x60]
LEA RSI,[RBP + -0x30]
MOV RDX,R14
MOV RCX,qword ptr [RBP + -0x38]
CALL qword ptr [RBP + -0x58]
MOV R15D,EAX
TEST EAX,EAX
JLE 0x001d3337
MOV R15D,R15D
ADD R15,R14
MOV RSI,qword ptr [RBP + -0x30]
JMP 0x001d336f
LAB_001d3337:
JZ 0x001d335a
CMP R15D,-0x64
JC 0x001d3354
MOV RAX,qword ptr [RBP + 0x20]
CMP qword ptr [RAX],0x0
JNZ 0x001d334c
MOV qword ptr [RAX],R14
LAB_001d334c:
NEG R15D
ADD R15,R14
JMP 0x001d3397
LAB_001d3354:
CMP R14,qword ptr [RBP + -0x38]
JNC 0x001d33ba
LAB_001d335a:
MOV RAX,qword ptr [RBP + 0x18]
CMP qword ptr [RAX + 0x8],0x0
JNZ 0x001d3369
MOV qword ptr [RAX + 0x8],R14
LAB_001d3369:
LEA R15,[R14 + 0x1]
JMP 0x001d3397
LAB_001d336f:
MOV RDI,R13
MOV RDX,RBX
MOV RCX,R12
CALL qword ptr [RBP + -0x40]
TEST EAX,EAX
JG 0x001d33a6
TEST EAX,EAX
JNZ 0x001d33ba
CMP qword ptr [RBP + -0x30],0x3f
JZ 0x001d33ba
MOV RAX,qword ptr [RBP + 0x20]
CMP qword ptr [RAX],0x0
JNZ 0x001d3397
MOV qword ptr [RAX],R14
LAB_001d3397:
MOV qword ptr [RBP + -0x30],0x3f
MOV ESI,0x3f
JMP 0x001d336f
LAB_001d33a6:
MOV EAX,EAX
ADD RBX,RAX
MOV R14,R15
DEC qword ptr [RBP + -0x50]
JNZ 0x001d3312
JMP 0x001d33c5
LAB_001d33ba:
MOV R15,R14
JMP 0x001d33c5
LAB_001d33bf:
MOV R15,R14
MOV RBX,RSI
LAB_001d33c5:
MOV RAX,qword ptr [RBP + 0x18]
MOV qword ptr [RAX],R15
SUB RBX,qword ptr [RBP + -0x48]
MOV RAX,RBX
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
long my_convert_fix(long param_1,long param_2,long param_3,long param_4,ulong param_5,long param_6,
long param_7,ulong *param_8,ulong *param_9)
{
code *pcVar1;
code *pcVar2;
uint uVar3;
long lVar4;
ulong uVar5;
ulong uVar6;
long local_58;
long local_38;
pcVar1 = *(code **)(*(long *)(param_4 + 0xb8) + 0x28);
pcVar2 = *(code **)(*(long *)(param_1 + 0xb8) + 0x30);
param_8[1] = 0;
*param_9 = 0;
lVar4 = param_2;
uVar5 = param_5;
if (param_7 != 0) {
local_58 = param_7;
while( true ) {
uVar3 = (*pcVar1)(param_4,&local_38,uVar5,param_6 + param_5);
if ((int)uVar3 < 1) break;
uVar6 = uVar3 + uVar5;
while (uVar3 = (*pcVar2)(param_1,local_38,lVar4,param_3 + param_2), (int)uVar3 < 1) {
if ((uVar3 != 0) || (local_38 == 0x3f)) goto LAB_001d33c5;
if (*param_9 == 0) {
*param_9 = uVar5;
}
LAB_001d3397:
local_38 = 0x3f;
}
lVar4 = lVar4 + (ulong)uVar3;
local_58 = local_58 + -1;
uVar5 = uVar6;
if (local_58 == 0) goto LAB_001d33c5;
}
if (uVar3 != 0) {
if (0xffffff9b < uVar3) {
if (*param_9 == 0) {
*param_9 = uVar5;
}
uVar6 = -uVar3 + uVar5;
goto LAB_001d3397;
}
if (param_6 + param_5 <= uVar5) goto LAB_001d33c5;
}
if (param_8[1] == 0) {
param_8[1] = uVar5;
}
uVar6 = uVar5 + 1;
goto LAB_001d3397;
}
LAB_001d33c5:
*param_8 = uVar5;
return lVar4 - param_2;
}
|
|
19,907
|
fct_reset_events_statements_history(PFS_thread*)
|
eloqsql/storage/perfschema/pfs_events_statements.cc
|
static void fct_reset_events_statements_history(PFS_thread *pfs_thread)
{
PFS_events_statements *pfs= pfs_thread->m_statements_history;
PFS_events_statements *pfs_last= pfs + events_statements_history_per_thread;
pfs_thread->m_statements_history_index= 0;
pfs_thread->m_statements_history_full= false;
for ( ; pfs < pfs_last; pfs++)
pfs->m_event.m_class= nullptr;
}
|
O0
|
cpp
|
fct_reset_events_statements_history(PFS_thread*):
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0xcc0(%rax), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
leaq 0x3b62d6(%rip), %rcx # 0x40daa8
imulq $0x590, (%rcx), %rcx # imm = 0x590
addq %rcx, %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl $0x0, 0xcbc(%rax)
movq -0x8(%rbp), %rax
movb $0x0, 0xcb8(%rax)
movq -0x10(%rbp), %rax
cmpq -0x18(%rbp), %rax
jae 0x5781f
movq -0x10(%rbp), %rax
movq $0x0, 0x30(%rax)
movq -0x10(%rbp), %rax
addq $0x590, %rax # imm = 0x590
movq %rax, -0x10(%rbp)
jmp 0x577f9
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
_ZL35fct_reset_events_statements_historyP10PFS_thread:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov rax, [rax+0CC0h]
mov [rbp+var_10], rax
mov rax, [rbp+var_10]
lea rcx, events_statements_history_per_thread
imul rcx, [rcx], 590h
add rax, rcx
mov [rbp+var_18], rax
mov rax, [rbp+var_8]
mov dword ptr [rax+0CBCh], 0
mov rax, [rbp+var_8]
mov byte ptr [rax+0CB8h], 0
loc_577F9:
mov rax, [rbp+var_10]
cmp rax, [rbp+var_18]
jnb short loc_5781F
mov rax, [rbp+var_10]
mov qword ptr [rax+30h], 0
mov rax, [rbp+var_10]
add rax, 590h
mov [rbp+var_10], rax
jmp short loc_577F9
loc_5781F:
pop rbp
retn
|
unsigned long long fct_reset_events_statements_history(PFS_thread *a1)
{
unsigned long long result; // rax
unsigned long long v2; // [rsp+0h] [rbp-18h]
unsigned long long v3; // [rsp+8h] [rbp-10h]
v3 = *((_QWORD *)a1 + 408);
v2 = 1424 * events_statements_history_per_thread + v3;
*((_DWORD *)a1 + 815) = 0;
*((_BYTE *)a1 + 3256) = 0;
while ( 1 )
{
result = v3;
if ( v3 >= v2 )
break;
*(_QWORD *)(v3 + 48) = 0LL;
v3 += 1424LL;
}
return result;
}
|
fct_reset_events_statements_history:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xcc0]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x10]
LEA RCX,[0x50daa8]
IMUL RCX,qword ptr [RCX],0x590
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0xcbc],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0xcb8],0x0
LAB_001577f9:
MOV RAX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RBP + -0x18]
JNC 0x0015781f
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x30],0x0
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x590
MOV qword ptr [RBP + -0x10],RAX
JMP 0x001577f9
LAB_0015781f:
POP RBP
RET
|
/* fct_reset_events_statements_history(PFS_thread*) */
void fct_reset_events_statements_history(PFS_thread *param_1)
{
ulong uVar1;
ulong local_18;
local_18 = *(ulong *)(param_1 + 0xcc0);
uVar1 = local_18 + events_statements_history_per_thread * 0x590;
*(int4 *)(param_1 + 0xcbc) = 0;
param_1[0xcb8] = (PFS_thread)0x0;
for (; local_18 < uVar1; local_18 = local_18 + 0x590) {
*(int8 *)(local_18 + 0x30) = 0;
}
return;
}
|
|
19,908
|
truncateString(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
|
mihussein[P]Hlemon/src/functions.cpp
|
std::string truncateString(const std::string& str) {
return (str.length() > 15) ? str.substr(0, 12) + "..." : str;
}
|
O1
|
cpp
|
truncateString(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
movq 0x8(%rsi), %r15
cmpq $0x10, %r15
jb 0x65cf
movq %rsp, %r14
movl $0xc, %ecx
movq %r14, %rdi
xorl %edx, %edx
callq 0x43a0
leaq 0x5dff(%rip), %rsi # 0xc3a4
movq %r14, %rdi
callq 0x46d0
leaq 0x10(%rbx), %rdx
movq %rdx, (%rbx)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0x65e7
movq %rsi, (%rbx)
movq (%rcx), %rdx
movq %rdx, 0x10(%rbx)
jmp 0x65ed
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq (%rsi), %rsi
leaq (%rsi,%r15), %rdx
movq %rbx, %rdi
callq 0x664c
jmp 0x6604
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq 0x8(%rax), %rdx
movq %rdx, 0x8(%rbx)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
cmpq $0x10, %r15
jb 0x6625
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6625
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x4380
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
cmpq $0x10, %r15
jb 0x6643
movq %rsp, %rdi
callq 0x4701
movq %rbx, %rdi
callq 0x4660
nop
|
_Z14truncateStringRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push r15
push r14
push rbx
sub rsp, 20h
mov rbx, rdi
mov r15, [rsi+8]
cmp r15, 10h
jb short loc_65CF
mov r14, rsp
mov ecx, 0Ch
mov rdi, r14
xor edx, edx
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong)
lea rsi, asc_C3A4; "..."
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea rdx, [rbx+10h]
mov [rbx], rdx
mov rsi, [rax]
mov rcx, rax
add rcx, 10h
cmp rsi, rcx
jz short loc_65E7
mov [rbx], rsi
mov rdx, [rcx]
mov [rbx+10h], rdx
jmp short loc_65ED
loc_65CF:
lea rax, [rbx+10h]
mov [rbx], rax
mov rsi, [rsi]
lea rdx, [rsi+r15]
mov rdi, rbx
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
jmp short loc_6604
loc_65E7:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [rdx], xmm0
loc_65ED:
mov rdx, [rax+8]
mov [rbx+8], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
loc_6604:
cmp r15, 10h
jb short loc_6625
lea rax, [rsp+38h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_6625
mov rsi, [rsp+38h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_6625:
mov rax, rbx
add rsp, 20h
pop rbx
pop r14
pop r15
retn
mov rbx, rax
cmp r15, 10h
jb short loc_6643
mov rdi, rsp
call _Z14truncateStringRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE_cold_1; truncateString(std::string const&) [clone]
loc_6643:
mov rdi, rbx
call __Unwind_Resume
|
long long truncateString(long long a1, _QWORD *a2)
{
unsigned long long v2; // r15
long long v3; // rax
_OWORD *v4; // rcx
void *v6[2]; // [rsp+0h] [rbp-38h] BYREF
long long v7; // [rsp+10h] [rbp-28h] BYREF
v2 = a2[1];
if ( v2 < 0x10 )
{
*(_QWORD *)a1 = a1 + 16;
std::string::_M_construct<char *>(a1, *a2, *a2 + v2);
}
else
{
std::string::substr(v6, a2, 0LL, 12LL);
v3 = std::string::append(v6, "...");
*(_QWORD *)a1 = a1 + 16;
v4 = (_OWORD *)(v3 + 16);
if ( *(_QWORD *)v3 == v3 + 16 )
{
*(_OWORD *)(a1 + 16) = *v4;
}
else
{
*(_QWORD *)a1 = *(_QWORD *)v3;
*(_QWORD *)(a1 + 16) = *(_QWORD *)v4;
}
*(_QWORD *)(a1 + 8) = *(_QWORD *)(v3 + 8);
*(_QWORD *)v3 = v4;
*(_QWORD *)(v3 + 8) = 0LL;
*(_BYTE *)(v3 + 16) = 0;
}
if ( v2 >= 0x10 && v6[0] != &v7 )
operator delete(v6[0], v7 + 1);
return a1;
}
|
truncateString:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x20
MOV RBX,RDI
MOV R15,qword ptr [RSI + 0x8]
CMP R15,0x10
JC 0x001065cf
MOV R14,RSP
MOV ECX,0xc
MOV RDI,R14
XOR EDX,EDX
CALL 0x001043a0
LAB_0010659e:
LEA RSI,[0x10c3a4]
MOV RDI,R14
CALL 0x001046d0
LEA RDX,[RBX + 0x10]
MOV qword ptr [RBX],RDX
MOV RSI,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RSI,RCX
JZ 0x001065e7
MOV qword ptr [RBX],RSI
MOV RDX,qword ptr [RCX]
MOV qword ptr [RBX + 0x10],RDX
JMP 0x001065ed
LAB_001065cf:
LEA RAX,[RBX + 0x10]
MOV qword ptr [RBX],RAX
MOV RSI,qword ptr [RSI]
LEA RDX,[RSI + R15*0x1]
MOV RDI,RBX
CALL 0x0010664c
LAB_001065e5:
JMP 0x00106604
LAB_001065e7:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [RDX],XMM0
LAB_001065ed:
MOV RDX,qword ptr [RAX + 0x8]
MOV qword ptr [RBX + 0x8],RDX
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV byte ptr [RAX + 0x10],0x0
LAB_00106604:
CMP R15,0x10
JC 0x00106625
LEA RAX,[RSP + 0x10]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x00106625
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x00104380
LAB_00106625:
MOV RAX,RBX
ADD RSP,0x20
POP RBX
POP R14
POP R15
RET
|
/* truncateString(std::__cxx11::string const&) */
string * truncateString(string *param_1)
{
ulong uVar1;
long lVar2;
long *plVar3;
long *plVar4;
long *in_RSI;
long *local_38 [2];
long local_28 [2];
uVar1 = in_RSI[1];
if (uVar1 < 0x10) {
*(string **)param_1 = param_1 + 0x10;
std::__cxx11::string::_M_construct<char*>(param_1,*in_RSI,*in_RSI + uVar1);
}
else {
std::__cxx11::string::substr((ulong)local_38,(ulong)in_RSI);
/* try { // try from 0010659e to 001065e4 has its CatchHandler @ 00106632 */
plVar3 = (long *)std::__cxx11::string::append((char *)local_38);
*(string **)param_1 = param_1 + 0x10;
plVar4 = plVar3 + 2;
if ((long *)*plVar3 == plVar4) {
lVar2 = plVar3[3];
*(long *)(param_1 + 0x10) = *plVar4;
*(long *)(param_1 + 0x18) = lVar2;
}
else {
*(long **)param_1 = (long *)*plVar3;
*(long *)(param_1 + 0x10) = *plVar4;
}
*(long *)(param_1 + 8) = plVar3[1];
*plVar3 = (long)plVar4;
plVar3[1] = 0;
*(int1 *)(plVar3 + 2) = 0;
}
if ((0xf < uVar1) && (local_38[0] != local_28)) {
operator_delete(local_38[0],local_28[0] + 1);
}
return param_1;
}
|
|
19,909
|
mi_memmap_file
|
eloqsql/storage/myisam/mi_packrec.c
|
my_bool _mi_memmap_file(MI_INFO *info)
{
MYISAM_SHARE *share=info->s;
my_bool eom;
DBUG_ENTER("mi_memmap_file");
if (!info->s->file_map)
{
my_off_t data_file_length= share->state.state.data_file_length;
if (myisam_mmap_size != SIZE_T_MAX)
{
mysql_mutex_lock(&THR_LOCK_myisam_mmap);
eom= data_file_length > myisam_mmap_size - myisam_mmap_used - MEMMAP_EXTRA_MARGIN;
if (!eom)
myisam_mmap_used+= data_file_length + MEMMAP_EXTRA_MARGIN;
mysql_mutex_unlock(&THR_LOCK_myisam_mmap);
}
else
eom= data_file_length > myisam_mmap_size - MEMMAP_EXTRA_MARGIN;
if (eom)
{
DBUG_PRINT("warning", ("File is too large for mmap"));
DBUG_RETURN(0);
}
if (mysql_file_seek(info->dfile, 0L, MY_SEEK_END, MYF(0)) <
share->state.state.data_file_length+MEMMAP_EXTRA_MARGIN)
{
DBUG_PRINT("warning",("File isn't extended for memmap"));
if (myisam_mmap_size != SIZE_T_MAX)
{
mysql_mutex_lock(&THR_LOCK_myisam_mmap);
myisam_mmap_used-= data_file_length + MEMMAP_EXTRA_MARGIN;
mysql_mutex_unlock(&THR_LOCK_myisam_mmap);
}
DBUG_RETURN(0);
}
if (mi_dynmap_file(info,
share->state.state.data_file_length +
MEMMAP_EXTRA_MARGIN))
{
if (myisam_mmap_size != SIZE_T_MAX)
{
mysql_mutex_lock(&THR_LOCK_myisam_mmap);
myisam_mmap_used-= data_file_length + MEMMAP_EXTRA_MARGIN;
mysql_mutex_unlock(&THR_LOCK_myisam_mmap);
}
DBUG_RETURN(0);
}
}
info->opt_flag|= MEMMAP_USED;
info->read_record= share->read_record= _mi_read_mempack_record;
share->read_rnd= _mi_read_rnd_mempack_record;
DBUG_RETURN(1);
}
|
O0
|
c
|
mi_memmap_file:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpq $0x0, 0x270(%rax)
jne 0xbbb68
movq -0x18(%rbp), %rax
movq 0x40(%rax), %rax
movq %rax, -0x28(%rbp)
leaq 0x2039a9(%rip), %rax # 0x2bf358
cmpq $-0x1, (%rax)
je 0xbba27
leaq 0xbc770c(%rip), %rdi # 0xc830c8
leaq 0x98020(%rip), %rsi # 0x1539e3
movl $0x5e5, %edx # imm = 0x5E5
callq 0xbbbc0
movq -0x28(%rbp), %rax
leaq 0x203980(%rip), %rcx # 0x2bf358
movq (%rcx), %rcx
leaq 0xbbe83e(%rip), %rdx # 0xc7a220
subq (%rdx), %rcx
subq $0x7, %rcx
cmpq %rcx, %rax
seta %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x19(%rbp)
cmpb $0x0, -0x19(%rbp)
jne 0xbba19
movq -0x28(%rbp), %rcx
addq $0x7, %rcx
leaq 0xbbe814(%rip), %rax # 0xc7a220
addq (%rax), %rcx
leaq 0xbbe80a(%rip), %rax # 0xc7a220
movq %rcx, (%rax)
leaq 0xbc76a8(%rip), %rdi # 0xc830c8
callq 0xbbc30
jmp 0xbba47
movq -0x28(%rbp), %rax
leaq 0x203926(%rip), %rcx # 0x2bf358
movq (%rcx), %rcx
subq $0x7, %rcx
cmpq %rcx, %rax
seta %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x19(%rbp)
cmpb $0x0, -0x19(%rbp)
je 0xbba5c
jmp 0xbba4f
jmp 0xbba51
jmp 0xbba53
movb $0x0, -0x1(%rbp)
jmp 0xbbbb5
movq -0x10(%rbp), %rax
movl 0x1c0(%rax), %edx
leaq 0x97f76(%rip), %rdi # 0x1539e3
movl $0x5f3, %esi # imm = 0x5F3
xorl %eax, %eax
movl %eax, %r9d
movl $0x2, %r8d
movq %r9, %rcx
callq 0xbb7c0
movq -0x18(%rbp), %rcx
movq 0x40(%rcx), %rcx
addq $0x7, %rcx
cmpq %rcx, %rax
jae 0xbbaf5
jmp 0xbba98
jmp 0xbba9a
leaq 0x2038b7(%rip), %rax # 0x2bf358
cmpq $-0x1, (%rax)
je 0xbbaea
leaq 0xbc761a(%rip), %rdi # 0xc830c8
leaq 0x97f2e(%rip), %rsi # 0x1539e3
movl $0x5f9, %edx # imm = 0x5F9
callq 0xbbbc0
movq -0x28(%rbp), %rax
addq $0x7, %rax
leaq 0xbbe752(%rip), %rcx # 0xc7a220
movq (%rcx), %rcx
subq %rax, %rcx
leaq 0xbbe745(%rip), %rax # 0xc7a220
movq %rcx, (%rax)
leaq 0xbc75e3(%rip), %rdi # 0xc830c8
callq 0xbbc30
jmp 0xbbaec
movb $0x0, -0x1(%rbp)
jmp 0xbbbb5
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x40(%rax), %rsi
addq $0x7, %rsi
callq 0xa6d40
cmpb $0x0, %al
je 0xbbb66
leaq 0x203843(%rip), %rax # 0x2bf358
cmpq $-0x1, (%rax)
je 0xbbb5e
leaq 0xbc75a6(%rip), %rdi # 0xc830c8
leaq 0x97eba(%rip), %rsi # 0x1539e3
movl $0x605, %edx # imm = 0x605
callq 0xbbbc0
movq -0x28(%rbp), %rax
addq $0x7, %rax
leaq 0xbbe6de(%rip), %rcx # 0xc7a220
movq (%rcx), %rcx
subq %rax, %rcx
leaq 0xbbe6d1(%rip), %rax # 0xc7a220
movq %rcx, (%rax)
leaq 0xbc756f(%rip), %rdi # 0xc830c8
callq 0xbbc30
jmp 0xbbb60
movb $0x0, -0x1(%rbp)
jmp 0xbbbb5
jmp 0xbbb68
movq -0x10(%rbp), %rax
movl 0x1c8(%rax), %ecx
orl $0x20, %ecx
movl %ecx, 0x1c8(%rax)
movq -0x18(%rbp), %rax
leaq 0x10a(%rip), %rcx # 0xbbc90
movq %rcx, 0x298(%rax)
movq -0x10(%rbp), %rax
leaq 0xf8(%rip), %rcx # 0xbbc90
movq %rcx, 0x140(%rax)
movq -0x18(%rbp), %rax
leaq 0x1d6(%rip), %rcx # 0xbbd80
movq %rcx, 0x2b8(%rax)
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x30, %rsp
popq %rbp
retq
nop
|
_mi_memmap_file:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_18], rax
mov rax, [rbp+var_10]
mov rax, [rax]
cmp qword ptr [rax+270h], 0
jnz loc_BBB68
mov rax, [rbp+var_18]
mov rax, [rax+40h]
mov [rbp+var_28], rax
lea rax, myisam_mmap_size
cmp qword ptr [rax], 0FFFFFFFFFFFFFFFFh
jz short loc_BBA27
lea rdi, THR_LOCK_myisam_mmap
lea rsi, aWorkspaceLlm4b_30; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 5E5h
call inline_mysql_mutex_lock_20
mov rax, [rbp+var_28]
lea rcx, myisam_mmap_size
mov rcx, [rcx]
lea rdx, myisam_mmap_used
sub rcx, [rdx]
sub rcx, 7
cmp rax, rcx
setnbe al
and al, 1
movzx eax, al
mov [rbp+var_19], al
cmp [rbp+var_19], 0
jnz short loc_BBA19
mov rcx, [rbp+var_28]
add rcx, 7
lea rax, myisam_mmap_used
add rcx, [rax]
lea rax, myisam_mmap_used
mov [rax], rcx
loc_BBA19:
lea rdi, THR_LOCK_myisam_mmap
call inline_mysql_mutex_unlock_21
jmp short loc_BBA47
loc_BBA27:
mov rax, [rbp+var_28]
lea rcx, myisam_mmap_size
mov rcx, [rcx]
sub rcx, 7
cmp rax, rcx
setnbe al
and al, 1
movzx eax, al
mov [rbp+var_19], al
loc_BBA47:
cmp [rbp+var_19], 0
jz short loc_BBA5C
jmp short $+2
loc_BBA4F:
jmp short $+2
loc_BBA51:
jmp short $+2
loc_BBA53:
mov [rbp+var_1], 0
jmp loc_BBBB5
loc_BBA5C:
mov rax, [rbp+var_10]
mov edx, [rax+1C0h]
lea rdi, aWorkspaceLlm4b_30; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 5F3h
xor eax, eax
mov r9d, eax
mov r8d, 2
mov rcx, r9
call inline_mysql_file_seek_5
mov rcx, [rbp+var_18]
mov rcx, [rcx+40h]
add rcx, 7
cmp rax, rcx
jnb short loc_BBAF5
jmp short $+2
loc_BBA98:
jmp short $+2
loc_BBA9A:
lea rax, myisam_mmap_size
cmp qword ptr [rax], 0FFFFFFFFFFFFFFFFh
jz short loc_BBAEA
lea rdi, THR_LOCK_myisam_mmap
lea rsi, aWorkspaceLlm4b_30; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 5F9h
call inline_mysql_mutex_lock_20
mov rax, [rbp+var_28]
add rax, 7
lea rcx, myisam_mmap_used
mov rcx, [rcx]
sub rcx, rax
lea rax, myisam_mmap_used
mov [rax], rcx
lea rdi, THR_LOCK_myisam_mmap
call inline_mysql_mutex_unlock_21
loc_BBAEA:
jmp short $+2
loc_BBAEC:
mov [rbp+var_1], 0
jmp loc_BBBB5
loc_BBAF5:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_18]
mov rsi, [rax+40h]
add rsi, 7
call mi_dynmap_file
cmp al, 0
jz short loc_BBB66
lea rax, myisam_mmap_size
cmp qword ptr [rax], 0FFFFFFFFFFFFFFFFh
jz short loc_BBB5E
lea rdi, THR_LOCK_myisam_mmap
lea rsi, aWorkspaceLlm4b_30; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 605h
call inline_mysql_mutex_lock_20
mov rax, [rbp+var_28]
add rax, 7
lea rcx, myisam_mmap_used
mov rcx, [rcx]
sub rcx, rax
lea rax, myisam_mmap_used
mov [rax], rcx
lea rdi, THR_LOCK_myisam_mmap
call inline_mysql_mutex_unlock_21
loc_BBB5E:
jmp short $+2
loc_BBB60:
mov [rbp+var_1], 0
jmp short loc_BBBB5
loc_BBB66:
jmp short $+2
loc_BBB68:
mov rax, [rbp+var_10]
mov ecx, [rax+1C8h]
or ecx, 20h
mov [rax+1C8h], ecx
mov rax, [rbp+var_18]
lea rcx, _mi_read_mempack_record
mov [rax+298h], rcx
mov rax, [rbp+var_10]
lea rcx, _mi_read_mempack_record
mov [rax+140h], rcx
mov rax, [rbp+var_18]
lea rcx, _mi_read_rnd_mempack_record
mov [rax+2B8h], rcx
mov [rbp+var_1], 1
loc_BBBB5:
mov al, [rbp+var_1]
add rsp, 30h
pop rbp
retn
|
char mi_memmap_file(unsigned int *a1)
{
unsigned long long v1; // rcx
unsigned long long v3; // [rsp+8h] [rbp-28h]
bool v4; // [rsp+17h] [rbp-19h]
_QWORD *v5; // [rsp+18h] [rbp-18h]
v5 = *(_QWORD **)a1;
if ( *(_QWORD *)(*(_QWORD *)a1 + 624LL) )
goto LABEL_17;
v3 = v5[8];
if ( myisam_mmap_size == -1LL )
{
v4 = v3 > 0xFFFFFFFFFFFFFFF8LL;
}
else
{
inline_mysql_mutex_lock_20(
&THR_LOCK_myisam_mmap,
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_packrec.c",
1509LL);
v1 = myisam_mmap_size - myisam_mmap_used - 7LL;
v4 = v3 > v1;
if ( v3 <= v1 )
myisam_mmap_used += v3 + 7;
inline_mysql_mutex_unlock_21(&THR_LOCK_myisam_mmap);
}
if ( v4 )
return 0;
if ( inline_mysql_file_seek_5(
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_packrec.c",
0x5F3u,
a1[112],
0LL,
2u,
0LL) < (unsigned long long)(v5[8] + 7LL) )
{
if ( myisam_mmap_size != -1LL )
{
inline_mysql_mutex_lock_20(
&THR_LOCK_myisam_mmap,
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_packrec.c",
1529LL);
myisam_mmap_used -= v3 + 7;
inline_mysql_mutex_unlock_21(&THR_LOCK_myisam_mmap);
}
return 0;
}
if ( !mi_dynmap_file(a1, v5[8] + 7LL) )
{
LABEL_17:
a1[114] |= 0x20u;
v5[83] = mi_read_mempack_record;
*((_QWORD *)a1 + 40) = mi_read_mempack_record;
v5[87] = mi_read_rnd_mempack_record;
return 1;
}
if ( myisam_mmap_size != -1LL )
{
inline_mysql_mutex_lock_20(
&THR_LOCK_myisam_mmap,
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_packrec.c",
1541LL);
myisam_mmap_used -= v3 + 7;
inline_mysql_mutex_unlock_21(&THR_LOCK_myisam_mmap);
}
return 0;
}
|
_mi_memmap_file:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
CMP qword ptr [RAX + 0x270],0x0
JNZ 0x001bbb68
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x40]
MOV qword ptr [RBP + -0x28],RAX
LEA RAX,[0x3bf358]
CMP qword ptr [RAX],-0x1
JZ 0x001bba27
LEA RDI,[0xd830c8]
LEA RSI,[0x2539e3]
MOV EDX,0x5e5
CALL 0x001bbbc0
MOV RAX,qword ptr [RBP + -0x28]
LEA RCX,[0x3bf358]
MOV RCX,qword ptr [RCX]
LEA RDX,[0xd7a220]
SUB RCX,qword ptr [RDX]
SUB RCX,0x7
CMP RAX,RCX
SETA AL
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x19],AL
CMP byte ptr [RBP + -0x19],0x0
JNZ 0x001bba19
MOV RCX,qword ptr [RBP + -0x28]
ADD RCX,0x7
LEA RAX,[0xd7a220]
ADD RCX,qword ptr [RAX]
LEA RAX,[0xd7a220]
MOV qword ptr [RAX],RCX
LAB_001bba19:
LEA RDI,[0xd830c8]
CALL 0x001bbc30
JMP 0x001bba47
LAB_001bba27:
MOV RAX,qword ptr [RBP + -0x28]
LEA RCX,[0x3bf358]
MOV RCX,qword ptr [RCX]
SUB RCX,0x7
CMP RAX,RCX
SETA AL
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x19],AL
LAB_001bba47:
CMP byte ptr [RBP + -0x19],0x0
JZ 0x001bba5c
JMP 0x001bba4f
LAB_001bba4f:
JMP 0x001bba51
LAB_001bba51:
JMP 0x001bba53
LAB_001bba53:
MOV byte ptr [RBP + -0x1],0x0
JMP 0x001bbbb5
LAB_001bba5c:
MOV RAX,qword ptr [RBP + -0x10]
MOV EDX,dword ptr [RAX + 0x1c0]
LEA RDI,[0x2539e3]
MOV ESI,0x5f3
XOR EAX,EAX
MOV R9D,EAX
MOV R8D,0x2
MOV RCX,R9
CALL 0x001bb7c0
MOV RCX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RCX + 0x40]
ADD RCX,0x7
CMP RAX,RCX
JNC 0x001bbaf5
JMP 0x001bba98
LAB_001bba98:
JMP 0x001bba9a
LAB_001bba9a:
LEA RAX,[0x3bf358]
CMP qword ptr [RAX],-0x1
JZ 0x001bbaea
LEA RDI,[0xd830c8]
LEA RSI,[0x2539e3]
MOV EDX,0x5f9
CALL 0x001bbbc0
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x7
LEA RCX,[0xd7a220]
MOV RCX,qword ptr [RCX]
SUB RCX,RAX
LEA RAX,[0xd7a220]
MOV qword ptr [RAX],RCX
LEA RDI,[0xd830c8]
CALL 0x001bbc30
LAB_001bbaea:
JMP 0x001bbaec
LAB_001bbaec:
MOV byte ptr [RBP + -0x1],0x0
JMP 0x001bbbb5
LAB_001bbaf5:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RAX + 0x40]
ADD RSI,0x7
CALL 0x001a6d40
CMP AL,0x0
JZ 0x001bbb66
LEA RAX,[0x3bf358]
CMP qword ptr [RAX],-0x1
JZ 0x001bbb5e
LEA RDI,[0xd830c8]
LEA RSI,[0x2539e3]
MOV EDX,0x605
CALL 0x001bbbc0
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x7
LEA RCX,[0xd7a220]
MOV RCX,qword ptr [RCX]
SUB RCX,RAX
LEA RAX,[0xd7a220]
MOV qword ptr [RAX],RCX
LEA RDI,[0xd830c8]
CALL 0x001bbc30
LAB_001bbb5e:
JMP 0x001bbb60
LAB_001bbb60:
MOV byte ptr [RBP + -0x1],0x0
JMP 0x001bbbb5
LAB_001bbb66:
JMP 0x001bbb68
LAB_001bbb68:
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x1c8]
OR ECX,0x20
MOV dword ptr [RAX + 0x1c8],ECX
MOV RAX,qword ptr [RBP + -0x18]
LEA RCX,[0x1bbc90]
MOV qword ptr [RAX + 0x298],RCX
MOV RAX,qword ptr [RBP + -0x10]
LEA RCX,[0x1bbc90]
MOV qword ptr [RAX + 0x140],RCX
MOV RAX,qword ptr [RBP + -0x18]
LEA RCX,[0x1bbd80]
MOV qword ptr [RAX + 0x2b8],RCX
MOV byte ptr [RBP + -0x1],0x1
LAB_001bbbb5:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x30
POP RBP
RET
|
int1 _mi_memmap_file(long *param_1)
{
long lVar1;
ulong uVar2;
bool bVar3;
char cVar4;
ulong uVar5;
lVar1 = *param_1;
if (*(long *)(*param_1 + 0x270) == 0) {
uVar2 = *(ulong *)(lVar1 + 0x40);
if (myisam_mmap_size == -1) {
bVar3 = 0xfffffffffffffff8 < uVar2;
}
else {
inline_mysql_mutex_lock
(THR_LOCK_myisam_mmap,
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_packrec.c",0x5e5);
bVar3 = (myisam_mmap_size - myisam_mmap_used) - 7U < uVar2;
if (!bVar3) {
myisam_mmap_used = uVar2 + 7 + myisam_mmap_used;
}
inline_mysql_mutex_unlock(THR_LOCK_myisam_mmap);
}
if (bVar3) {
return 0;
}
uVar5 = inline_mysql_file_seek
("/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_packrec.c",0x5f3,
(int)param_1[0x38],0,2);
if (uVar5 < *(long *)(lVar1 + 0x40) + 7U) {
if (myisam_mmap_size != -1) {
inline_mysql_mutex_lock
(THR_LOCK_myisam_mmap,
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_packrec.c",0x5f9);
myisam_mmap_used = myisam_mmap_used - (uVar2 + 7);
inline_mysql_mutex_unlock(THR_LOCK_myisam_mmap);
}
return 0;
}
cVar4 = mi_dynmap_file(param_1,*(long *)(lVar1 + 0x40) + 7);
if (cVar4 != '\0') {
if (myisam_mmap_size != -1) {
inline_mysql_mutex_lock
(THR_LOCK_myisam_mmap,
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_packrec.c",0x605);
myisam_mmap_used = myisam_mmap_used - (uVar2 + 7);
inline_mysql_mutex_unlock(THR_LOCK_myisam_mmap);
}
return 0;
}
}
*(uint *)(param_1 + 0x39) = *(uint *)(param_1 + 0x39) | 0x20;
*(code **)(lVar1 + 0x298) = _mi_read_mempack_record;
param_1[0x28] = (long)_mi_read_mempack_record;
*(code **)(lVar1 + 0x2b8) = _mi_read_rnd_mempack_record;
return 1;
}
|
|
19,910
|
translog_read_record_header_scan
|
eloqsql/storage/maria/ma_loghandler.c
|
int translog_read_record_header_scan(TRANSLOG_SCANNER_DATA *scanner,
TRANSLOG_HEADER_BUFFER *buff,
my_bool move_scanner)
{
translog_size_t res;
DBUG_ENTER("translog_read_record_header_scan");
DBUG_PRINT("enter", ("Scanner: Cur: " LSN_FMT " Hrz: " LSN_FMT " "
"Lst: " LSN_FMT " Offset: %u(%x) fixed %d",
LSN_IN_PARTS(scanner->page_addr),
LSN_IN_PARTS(scanner->horizon),
LSN_IN_PARTS(scanner->last_file_page),
(uint) scanner->page_offset,
(uint) scanner->page_offset, scanner->fixed_horizon));
DBUG_ASSERT(translog_status == TRANSLOG_OK ||
translog_status == TRANSLOG_READONLY);
buff->groups_no= 0;
buff->lsn= scanner->page_addr;
buff->lsn+= scanner->page_offset; /* offset increasing */
res= translog_read_record_header_from_buffer(scanner->page,
scanner->page_offset,
buff,
(move_scanner ?
scanner : 0));
DBUG_RETURN(res);
}
|
O0
|
c
|
translog_read_record_header_scan:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movb %dl, %al
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movb %al, -0x11(%rbp)
jmp 0x35117
jmp 0x35119
jmp 0x3511b
movq -0x10(%rbp), %rax
movl $0x0, 0x418(%rax)
movq -0x8(%rbp), %rax
movq 0x2000(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x8(%rbp), %rax
movl 0x2028(%rax), %eax
movl %eax, %ecx
movq -0x10(%rbp), %rax
addq (%rax), %rcx
movq %rcx, (%rax)
movq -0x8(%rbp), %rax
movq 0x2018(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movl 0x2028(%rax), %eax
movw %ax, -0x22(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movsbl -0x11(%rbp), %eax
cmpl $0x0, %eax
je 0x35189
movq -0x8(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x35191
xorl %eax, %eax
movq %rax, -0x38(%rbp)
jmp 0x35191
movq -0x20(%rbp), %rdx
movw -0x22(%rbp), %ax
movq -0x30(%rbp), %rdi
movq -0x38(%rbp), %rcx
movzwl %ax, %esi
callq 0x34620
movl %eax, -0x18(%rbp)
movl -0x18(%rbp), %eax
movl %eax, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
translog_read_record_header_scan:
push rbp
mov rbp, rsp
sub rsp, 40h
mov al, dl
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_11], al
jmp short $+2
loc_35117:
jmp short $+2
loc_35119:
jmp short $+2
loc_3511B:
mov rax, [rbp+var_10]
mov dword ptr [rax+418h], 0
mov rax, [rbp+var_8]
mov rcx, [rax+2000h]
mov rax, [rbp+var_10]
mov [rax], rcx
mov rax, [rbp+var_8]
mov eax, [rax+2028h]
mov ecx, eax
mov rax, [rbp+var_10]
add rcx, [rax]
mov [rax], rcx
mov rax, [rbp+var_8]
mov rax, [rax+2018h]
mov [rbp+var_30], rax
mov rax, [rbp+var_8]
mov eax, [rax+2028h]
mov [rbp+var_22], ax
mov rax, [rbp+var_10]
mov [rbp+var_20], rax
movsx eax, [rbp+var_11]
cmp eax, 0
jz short loc_35189
mov rax, [rbp+var_8]
mov [rbp+var_38], rax
jmp short loc_35191
loc_35189:
xor eax, eax
mov [rbp+var_38], rax
jmp short $+2
loc_35191:
mov rdx, [rbp+var_20]
mov ax, [rbp+var_22]
mov rdi, [rbp+var_30]
mov rcx, [rbp+var_38]
movzx esi, ax
call translog_read_record_header_from_buffer
mov [rbp+var_18], eax
mov eax, [rbp+var_18]
mov [rbp+var_3C], eax
mov eax, [rbp+var_3C]
add rsp, 40h
pop rbp
retn
|
long long translog_read_record_header_scan(long long a1, long long a2, char a3)
{
long long result; // rax
long long v4; // [rsp+10h] [rbp-30h]
unsigned __int16 v5; // [rsp+1Eh] [rbp-22h]
*(_DWORD *)(a2 + 1048) = 0;
*(_QWORD *)a2 = *(_QWORD *)(a1 + 0x2000);
*(_QWORD *)a2 += *(unsigned int *)(a1 + 8232);
v4 = *(_QWORD *)(a1 + 8216);
v5 = *(_DWORD *)(a1 + 8232);
if ( a3 )
LODWORD(result) = translog_read_record_header_from_buffer(v4, v5, a2, a1);
else
LODWORD(result) = translog_read_record_header_from_buffer(v4, v5, a2, 0LL);
return (unsigned int)result;
}
|
translog_read_record_header_scan:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV AL,DL
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV byte ptr [RBP + -0x11],AL
JMP 0x00135117
LAB_00135117:
JMP 0x00135119
LAB_00135119:
JMP 0x0013511b
LAB_0013511b:
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x418],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x2000]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x2028]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x10]
ADD RCX,qword ptr [RAX]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x2018]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x2028]
MOV word ptr [RBP + -0x22],AX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x20],RAX
MOVSX EAX,byte ptr [RBP + -0x11]
CMP EAX,0x0
JZ 0x00135189
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x38],RAX
JMP 0x00135191
LAB_00135189:
XOR EAX,EAX
MOV qword ptr [RBP + -0x38],RAX
JMP 0x00135191
LAB_00135191:
MOV RDX,qword ptr [RBP + -0x20]
MOV AX,word ptr [RBP + -0x22]
MOV RDI,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RBP + -0x38]
MOVZX ESI,AX
CALL 0x00134620
MOV dword ptr [RBP + -0x18],EAX
MOV EAX,dword ptr [RBP + -0x18]
MOV dword ptr [RBP + -0x3c],EAX
MOV EAX,dword ptr [RBP + -0x3c]
ADD RSP,0x40
POP RBP
RET
|
int4 translog_read_record_header_scan(long param_1,long *param_2,char param_3)
{
int4 uVar1;
long local_40;
*(int4 *)(param_2 + 0x83) = 0;
*param_2 = *(long *)(param_1 + 0x2000);
*param_2 = (ulong)*(uint *)(param_1 + 0x2028) + *param_2;
local_40 = param_1;
if (param_3 == '\0') {
local_40 = 0;
}
uVar1 = translog_read_record_header_from_buffer
(*(int8 *)(param_1 + 0x2018),(short)*(int4 *)(param_1 + 0x2028),
param_2,local_40);
return uVar1;
}
|
|
19,911
|
nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&)
|
monkey531[P]llama/common/./json.hpp
|
friend bool operator==(const_reference lhs, const_reference rhs) noexcept
{
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wfloat-equal"
#endif
JSON_IMPLEMENT_OPERATOR( ==, true, false, false)
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
}
|
O0
|
cpp
|
nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, 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&):
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq 0x28(%rsp), %rdi
callq 0xc8ae0
movb %al, 0x1f(%rsp)
movq 0x20(%rsp), %rdi
callq 0xc8ae0
movb %al, 0x1e(%rsp)
movb 0x1f(%rsp), %al
cmpb 0x1e(%rsp), %al
jne 0xc891f
movzbl 0x1f(%rsp), %eax
movq %rax, 0x10(%rsp)
subq $0x9, %rax
ja 0xc8915
movq 0x10(%rsp), %rax
leaq 0xfa62c(%rip), %rcx # 0x1c2df4
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rdi
movq 0x20(%rsp), %rax
movq 0x8(%rax), %rsi
callq 0xc8af0
movb %al, 0xf(%rsp)
jmp 0xc87ee
movb 0xf(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rdi
movq 0x20(%rsp), %rax
movq 0x8(%rax), %rsi
callq 0xc8b80
movb %al, 0xe(%rsp)
jmp 0xc881a
movb 0xe(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
movb $0x1, 0x37(%rsp)
jmp 0xc8ac8
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rdi
movq 0x20(%rsp), %rax
movq 0x8(%rax), %rsi
callq 0x62020
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
movq 0x28(%rsp), %rax
movb 0x8(%rax), %al
andb $0x1, %al
movzbl %al, %eax
movq 0x20(%rsp), %rcx
movb 0x8(%rcx), %cl
andb $0x1, %cl
movzbl %cl, %ecx
cmpl %ecx, %eax
sete %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rax
movq 0x20(%rsp), %rcx
cmpq 0x8(%rcx), %rax
sete %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rax
movq 0x20(%rsp), %rcx
cmpq 0x8(%rcx), %rax
sete %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
movq 0x28(%rsp), %rax
movsd 0x8(%rax), %xmm0
movq 0x20(%rsp), %rax
ucomisd 0x8(%rax), %xmm0
sete %al
setnp %cl
andb %cl, %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rdi
movq 0x20(%rsp), %rax
movq 0x8(%rax), %rsi
callq 0xc8c10
movb %al, 0xd(%rsp)
jmp 0xc8904
movb 0xd(%rsp), %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
jmp 0xc8915
movb $0x0, 0x37(%rsp)
jmp 0xc8ac8
cmpb $0x5, 0x1f(%rsp)
jne 0xc8955
cmpb $0x7, 0x1e(%rsp)
jne 0xc8955
movq 0x28(%rsp), %rax
cvtsi2sdq 0x8(%rax), %xmm0
movq 0x20(%rsp), %rax
ucomisd 0x8(%rax), %xmm0
sete %al
setnp %cl
andb %cl, %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
cmpb $0x7, 0x1f(%rsp)
jne 0xc898f
cmpb $0x5, 0x1e(%rsp)
jne 0xc898f
movq 0x28(%rsp), %rax
movsd 0x8(%rax), %xmm0
movq 0x20(%rsp), %rax
cvtsi2sdq 0x8(%rax), %xmm1
ucomisd %xmm1, %xmm0
sete %al
setnp %cl
andb %cl, %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
cmpb $0x6, 0x1f(%rsp)
jne 0xc89e6
cmpb $0x7, 0x1e(%rsp)
jne 0xc89e6
movq 0x28(%rsp), %rax
movq 0x8(%rax), %xmm0
movaps 0xf9822(%rip), %xmm1 # 0x1c21d0
punpckldq %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movapd 0xf9826(%rip), %xmm1 # 0x1c21e0
subpd %xmm1, %xmm0
movaps %xmm0, %xmm1
unpckhpd %xmm0, %xmm0 # xmm0 = xmm0[1,1]
addsd %xmm1, %xmm0
movq 0x20(%rsp), %rax
ucomisd 0x8(%rax), %xmm0
sete %al
setnp %cl
andb %cl, %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
cmpb $0x7, 0x1f(%rsp)
jne 0xc8a41
cmpb $0x6, 0x1e(%rsp)
jne 0xc8a41
movq 0x28(%rsp), %rax
movsd 0x8(%rax), %xmm0
movq 0x20(%rsp), %rax
movq 0x8(%rax), %xmm1
movaps 0xf97c1(%rip), %xmm2 # 0x1c21d0
punpckldq %xmm2, %xmm1 # xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
movapd 0xf97c5(%rip), %xmm2 # 0x1c21e0
subpd %xmm2, %xmm1
movaps %xmm1, %xmm2
unpckhpd %xmm1, %xmm1 # xmm1 = xmm1[1,1]
addsd %xmm2, %xmm1
ucomisd %xmm1, %xmm0
sete %al
setnp %cl
andb %cl, %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
cmpb $0x6, 0x1f(%rsp)
jne 0xc8a6c
cmpb $0x5, 0x1e(%rsp)
jne 0xc8a6c
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rax
movq 0x20(%rsp), %rcx
cmpq 0x8(%rcx), %rax
sete %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
cmpb $0x5, 0x1f(%rsp)
jne 0xc8a97
cmpb $0x6, 0x1e(%rsp)
jne 0xc8a97
movq 0x28(%rsp), %rax
movq 0x8(%rax), %rax
movq 0x20(%rsp), %rcx
cmpq 0x8(%rcx), %rax
sete %al
andb $0x1, %al
movb %al, 0x37(%rsp)
jmp 0xc8ac8
movq 0x28(%rsp), %rdi
movq 0x20(%rsp), %rsi
xorl %edx, %edx
callq 0xc8c80
testb $0x1, %al
jne 0xc8aae
jmp 0xc8ab5
movb $0x0, 0x37(%rsp)
jmp 0xc8ac8
jmp 0xc8ab7
jmp 0xc8ab9
jmp 0xc8abb
jmp 0xc8abd
jmp 0xc8abf
jmp 0xc8ac1
jmp 0xc8ac3
movb $0x0, 0x37(%rsp)
movb 0x37(%rsp), %al
andb $0x1, %al
addq $0x38, %rsp
retq
movq %rax, %rdi
callq 0x6e170
nopl (%rax,%rax)
|
_ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_:
sub rsp, 38h
mov [rsp+38h+var_10], rdi
mov [rsp+38h+var_18], rsi
mov rdi, [rsp+38h+var_10]
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4typeEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type(void)
mov [rsp+38h+var_19], al
mov rdi, [rsp+38h+var_18]
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4typeEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type(void)
mov [rsp+38h+var_1A], al
mov al, [rsp+38h+var_19]
cmp al, [rsp+38h+var_1A]
jnz loc_C891F
movzx eax, [rsp+38h+var_19]
mov [rsp+38h+var_28], rax
sub rax, 9; switch 10 cases
ja def_C87CF; jumptable 00000000000C87CF default case
mov rax, [rsp+38h+var_28]
lea rcx, jpt_C87CF
movsxd rax, ds:(jpt_C87CF - 1C2DF4h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_C87D1:
mov rax, [rsp+38h+var_10]; jumptable 00000000000C87CF case 2
mov rdi, [rax+8]
mov rax, [rsp+38h+var_18]
mov rsi, [rax+8]
call _ZSteqIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEESaISE_EEbRKS4_IT_T0_ESK_; std::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>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>(std::vector const&<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,std::allocator<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 const&<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,std::allocator<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 [rsp+38h+var_29], al
jmp short $+2
loc_C87EE:
mov al, [rsp+38h+var_29]
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C87FD:
mov rax, [rsp+38h+var_10]; jumptable 00000000000C87CF case 1
mov rdi, [rax+8]
mov rax, [rsp+38h+var_18]
mov rsi, [rax+8]
call _ZSteqISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapESt6vectorS6_blmdSaNS9_14adl_serializerESC_IhSaIhEEvEEESaISH_EEbRKSC_IT_T0_ESN_; std::operator==<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>(std::vector const&<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>,std::vector const&<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>)
mov [rsp+38h+var_2A], al
jmp short $+2
loc_C881A:
mov al, [rsp+38h+var_2A]
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C8829:
mov [rsp+38h+var_1], 1; jumptable 00000000000C87CF case 0
jmp loc_C8AC8
loc_C8833:
mov rax, [rsp+38h+var_10]; jumptable 00000000000C87CF case 3
mov rdi, [rax+8]
mov rax, [rsp+38h+var_18]
mov rsi, [rax+8]
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C8855:
mov rax, [rsp+38h+var_10]; jumptable 00000000000C87CF case 4
mov al, [rax+8]
and al, 1
movzx eax, al
mov rcx, [rsp+38h+var_18]
mov cl, [rcx+8]
and cl, 1
movzx ecx, cl
cmp eax, ecx
setz al
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C8880:
mov rax, [rsp+38h+var_10]; jumptable 00000000000C87CF case 5
mov rax, [rax+8]
mov rcx, [rsp+38h+var_18]
cmp rax, [rcx+8]
setz al
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C88A0:
mov rax, [rsp+38h+var_10]; jumptable 00000000000C87CF case 6
mov rax, [rax+8]
mov rcx, [rsp+38h+var_18]
cmp rax, [rcx+8]
setz al
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C88C0:
mov rax, [rsp+38h+var_10]; jumptable 00000000000C87CF case 7
movsd xmm0, qword ptr [rax+8]
mov rax, [rsp+38h+var_18]
ucomisd xmm0, qword ptr [rax+8]
setz al
setnp cl
and al, cl
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C88E7:
mov rax, [rsp+38h+var_10]; jumptable 00000000000C87CF case 8
mov rdi, [rax+8]
mov rax, [rsp+38h+var_18]
mov rsi, [rax+8]
call _ZNK8nlohmann16json_abi_v3_11_327byte_container_with_subtypeISt6vectorIhSaIhEEEeqERKS5_; nlohmann::json_abi_v3_11_3::byte_container_with_subtype<std::vector<uchar>>::operator==(nlohmann::json_abi_v3_11_3::byte_container_with_subtype<std::vector<uchar>> const&)
mov [rsp+38h+var_2B], al
jmp short $+2
loc_C8904:
mov al, [rsp+38h+var_2B]
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C8913:
jmp short $+2; jumptable 00000000000C87CF case 9
def_C87CF:
mov [rsp+38h+var_1], 0; jumptable 00000000000C87CF default case
jmp loc_C8AC8
loc_C891F:
cmp [rsp+38h+var_19], 5
jnz short loc_C8955
cmp [rsp+38h+var_1A], 7
jnz short loc_C8955
mov rax, [rsp+38h+var_10]
cvtsi2sd xmm0, qword ptr [rax+8]
mov rax, [rsp+38h+var_18]
ucomisd xmm0, qword ptr [rax+8]
setz al
setnp cl
and al, cl
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C8955:
cmp [rsp+38h+var_19], 7
jnz short loc_C898F
cmp [rsp+38h+var_1A], 5
jnz short loc_C898F
mov rax, [rsp+38h+var_10]
movsd xmm0, qword ptr [rax+8]
mov rax, [rsp+38h+var_18]
cvtsi2sd xmm1, qword ptr [rax+8]
ucomisd xmm0, xmm1
setz al
setnp cl
and al, cl
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C898F:
cmp [rsp+38h+var_19], 6
jnz short loc_C89E6
cmp [rsp+38h+var_1A], 7
jnz short loc_C89E6
mov rax, [rsp+38h+var_10]
movq xmm0, qword ptr [rax+8]
movaps xmm1, cs:xmmword_1C21D0
punpckldq xmm0, xmm1
movapd xmm1, cs:xmmword_1C21E0
subpd xmm0, xmm1
movaps xmm1, xmm0
unpckhpd xmm0, xmm0
addsd xmm0, xmm1
mov rax, [rsp+38h+var_18]
ucomisd xmm0, qword ptr [rax+8]
setz al
setnp cl
and al, cl
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C89E6:
cmp [rsp+38h+var_19], 7
jnz short loc_C8A41
cmp [rsp+38h+var_1A], 6
jnz short loc_C8A41
mov rax, [rsp+38h+var_10]
movsd xmm0, qword ptr [rax+8]
mov rax, [rsp+38h+var_18]
movq xmm1, qword ptr [rax+8]
movaps xmm2, cs:xmmword_1C21D0
punpckldq xmm1, xmm2
movapd xmm2, cs:xmmword_1C21E0
subpd xmm1, xmm2
movaps xmm2, xmm1
unpckhpd xmm1, xmm1
addsd xmm1, xmm2
ucomisd xmm0, xmm1
setz al
setnp cl
and al, cl
and al, 1
mov [rsp+38h+var_1], al
jmp loc_C8AC8
loc_C8A41:
cmp [rsp+38h+var_19], 6
jnz short loc_C8A6C
cmp [rsp+38h+var_1A], 5
jnz short loc_C8A6C
mov rax, [rsp+38h+var_10]
mov rax, [rax+8]
mov rcx, [rsp+38h+var_18]
cmp rax, [rcx+8]
setz al
and al, 1
mov [rsp+38h+var_1], al
jmp short loc_C8AC8
loc_C8A6C:
cmp [rsp+38h+var_19], 5
jnz short loc_C8A97
cmp [rsp+38h+var_1A], 6
jnz short loc_C8A97
mov rax, [rsp+38h+var_10]
mov rax, [rax+8]
mov rcx, [rsp+38h+var_18]
cmp rax, [rcx+8]
setz al
and al, 1
mov [rsp+38h+var_1], al
jmp short loc_C8AC8
loc_C8A97:
mov rdi, [rsp+38h+var_10]
mov rsi, [rsp+38h+var_18]
xor edx, edx
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE18compares_unorderedERKSD_SF_b; 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>::compares_unordered(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&,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&,bool)
test al, 1
jnz short loc_C8AAE
jmp short loc_C8AB5
loc_C8AAE:
mov [rsp+38h+var_1], 0
jmp short loc_C8AC8
loc_C8AB5:
jmp short $+2
loc_C8AB7:
jmp short $+2
loc_C8AB9:
jmp short $+2
loc_C8ABB:
jmp short $+2
loc_C8ABD:
jmp short $+2
loc_C8ABF:
jmp short $+2
loc_C8AC1:
jmp short $+2
loc_C8AC3:
mov [rsp+38h+var_1], 0
loc_C8AC8:
mov al, [rsp+38h+var_1]
and al, 1
add rsp, 38h
retn
mov rdi, rax
call __clang_call_terminate
|
char nlohmann::json_abi_v3_11_3::operator==(long long a1, long long a2)
{
__m128d v2; // xmm1
__m128d v3; // xmm2
char v5; // [rsp+1Eh] [rbp-1Ah]
char v6; // [rsp+1Fh] [rbp-19h]
char v7; // [rsp+37h] [rbp-1h]
v6 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type(a1);
v5 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type(a2);
if ( v6 == v5 )
{
switch ( v6 )
{
case 0:
v7 = 1;
break;
case 1:
v7 = std::operator==<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>(
*(_QWORD *)(a1 + 8),
*(_QWORD *)(a2 + 8)) & 1;
break;
case 2:
v7 = std::operator==<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>(
*(_QWORD *)(a1 + 8),
*(_QWORD *)(a2 + 8)) & 1;
break;
case 3:
v7 = std::operator==<char>(*(_QWORD *)(a1 + 8), *(_QWORD *)(a2 + 8)) & 1;
break;
case 4:
v7 = (*(_BYTE *)(a1 + 8) & 1) == (*(_BYTE *)(a2 + 8) & 1);
break;
case 5:
v7 = *(_QWORD *)(a1 + 8) == *(_QWORD *)(a2 + 8);
break;
case 6:
v7 = *(_QWORD *)(a1 + 8) == *(_QWORD *)(a2 + 8);
break;
case 7:
v7 = *(double *)(a1 + 8) == *(double *)(a2 + 8);
break;
case 8:
v7 = nlohmann::json_abi_v3_11_3::byte_container_with_subtype<std::vector<unsigned char>>::operator==(
*(_QWORD *)(a1 + 8),
*(_QWORD *)(a2 + 8)) & 1;
break;
default:
v7 = 0;
break;
}
}
else if ( v6 == 5 && v5 == 7 )
{
v7 = (double)(int)*(_QWORD *)(a1 + 8) == *(double *)(a2 + 8);
}
else if ( v6 == 7 && v5 == 5 )
{
v7 = *(double *)(a1 + 8) == (double)(int)*(_QWORD *)(a2 + 8);
}
else if ( v6 == 6 && v5 == 7 )
{
v2 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32(_mm_loadl_epi64((const __m128i *)(a1 + 8)), (__m128i)xmmword_1C21D0),
(__m128d)xmmword_1C21E0);
v7 = _mm_unpackhi_pd(v2, v2).m128d_f64[0] + v2.m128d_f64[0] == *(double *)(a2 + 8);
}
else if ( v6 == 7 && v5 == 6 )
{
v3 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32(_mm_loadl_epi64((const __m128i *)(a2 + 8)), (__m128i)xmmword_1C21D0),
(__m128d)xmmword_1C21E0);
v7 = *(double *)(a1 + 8) == _mm_unpackhi_pd(v3, v3).m128d_f64[0] + v3.m128d_f64[0];
}
else if ( v6 == 6 && v5 == 5 )
{
v7 = *(_QWORD *)(a1 + 8) == *(_QWORD *)(a2 + 8);
}
else if ( v6 == 5 && v5 == 6 )
{
v7 = *(_QWORD *)(a1 + 8) == *(_QWORD *)(a2 + 8);
}
else
{
v7 = 0;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::compares_unordered(
a1,
a2,
0LL);
}
return v7 & 1;
}
|
operator==:
SUB RSP,0x38
MOV qword ptr [RSP + 0x28],RDI
MOV qword ptr [RSP + 0x20],RSI
MOV RDI,qword ptr [RSP + 0x28]
CALL 0x001c8ae0
MOV byte ptr [RSP + 0x1f],AL
MOV RDI,qword ptr [RSP + 0x20]
CALL 0x001c8ae0
MOV byte ptr [RSP + 0x1e],AL
MOV AL,byte ptr [RSP + 0x1f]
CMP AL,byte ptr [RSP + 0x1e]
JNZ 0x001c891f
MOVZX EAX,byte ptr [RSP + 0x1f]
MOV qword ptr [RSP + 0x10],RAX
SUB RAX,0x9
JA 0x001c8915
MOV RAX,qword ptr [RSP + 0x10]
LEA RCX,[0x2c2df4]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_1c87d1:
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RAX + 0x8]
LAB_001c87e3:
CALL 0x001c8af0
MOV byte ptr [RSP + 0xf],AL
JMP 0x001c87ee
LAB_001c87ee:
MOV AL,byte ptr [RSP + 0xf]
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
caseD_1c87fd:
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RAX + 0x8]
CALL 0x001c8b80
MOV byte ptr [RSP + 0xe],AL
JMP 0x001c881a
LAB_001c881a:
MOV AL,byte ptr [RSP + 0xe]
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
caseD_1c8829:
MOV byte ptr [RSP + 0x37],0x1
JMP 0x001c8ac8
caseD_1c8833:
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RAX + 0x8]
CALL 0x00162020
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
caseD_1c8855:
MOV RAX,qword ptr [RSP + 0x28]
MOV AL,byte ptr [RAX + 0x8]
AND AL,0x1
MOVZX EAX,AL
MOV RCX,qword ptr [RSP + 0x20]
MOV CL,byte ptr [RCX + 0x8]
AND CL,0x1
MOVZX ECX,CL
CMP EAX,ECX
SETZ AL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
caseD_1c8880:
MOV RAX,qword ptr [RSP + 0x28]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RSP + 0x20]
CMP RAX,qword ptr [RCX + 0x8]
SETZ AL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
caseD_1c88a0:
MOV RAX,qword ptr [RSP + 0x28]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RSP + 0x20]
CMP RAX,qword ptr [RCX + 0x8]
SETZ AL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
caseD_1c88c0:
MOV RAX,qword ptr [RSP + 0x28]
MOVSD XMM0,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RSP + 0x20]
UCOMISD XMM0,qword ptr [RAX + 0x8]
SETZ AL
SETNP CL
AND AL,CL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
caseD_1c88e7:
MOV RAX,qword ptr [RSP + 0x28]
MOV RDI,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RAX + 0x8]
CALL 0x001c8c10
MOV byte ptr [RSP + 0xd],AL
JMP 0x001c8904
LAB_001c8904:
MOV AL,byte ptr [RSP + 0xd]
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
caseD_1c8913:
JMP 0x001c8915
LAB_001c8915:
MOV byte ptr [RSP + 0x37],0x0
JMP 0x001c8ac8
LAB_001c891f:
CMP byte ptr [RSP + 0x1f],0x5
JNZ 0x001c8955
CMP byte ptr [RSP + 0x1e],0x7
JNZ 0x001c8955
MOV RAX,qword ptr [RSP + 0x28]
CVTSI2SD XMM0,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RSP + 0x20]
UCOMISD XMM0,qword ptr [RAX + 0x8]
SETZ AL
SETNP CL
AND AL,CL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
LAB_001c8955:
CMP byte ptr [RSP + 0x1f],0x7
JNZ 0x001c898f
CMP byte ptr [RSP + 0x1e],0x5
JNZ 0x001c898f
MOV RAX,qword ptr [RSP + 0x28]
MOVSD XMM0,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RSP + 0x20]
CVTSI2SD XMM1,qword ptr [RAX + 0x8]
UCOMISD XMM0,XMM1
SETZ AL
SETNP CL
AND AL,CL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
LAB_001c898f:
CMP byte ptr [RSP + 0x1f],0x6
JNZ 0x001c89e6
CMP byte ptr [RSP + 0x1e],0x7
JNZ 0x001c89e6
MOV RAX,qword ptr [RSP + 0x28]
MOVQ XMM0,qword ptr [RAX + 0x8]
MOVAPS XMM1,xmmword ptr [0x002c21d0]
PUNPCKLDQ XMM0,XMM1
MOVAPD XMM1,xmmword ptr [0x002c21e0]
SUBPD XMM0,XMM1
MOVAPS XMM1,XMM0
UNPCKHPD XMM0,XMM0
ADDSD XMM0,XMM1
MOV RAX,qword ptr [RSP + 0x20]
UCOMISD XMM0,qword ptr [RAX + 0x8]
SETZ AL
SETNP CL
AND AL,CL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
LAB_001c89e6:
CMP byte ptr [RSP + 0x1f],0x7
JNZ 0x001c8a41
CMP byte ptr [RSP + 0x1e],0x6
JNZ 0x001c8a41
MOV RAX,qword ptr [RSP + 0x28]
MOVSD XMM0,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RSP + 0x20]
MOVQ XMM1,qword ptr [RAX + 0x8]
MOVAPS XMM2,xmmword ptr [0x002c21d0]
PUNPCKLDQ XMM1,XMM2
MOVAPD XMM2,xmmword ptr [0x002c21e0]
SUBPD XMM1,XMM2
MOVAPS XMM2,XMM1
UNPCKHPD XMM1,XMM1
ADDSD XMM1,XMM2
UCOMISD XMM0,XMM1
SETZ AL
SETNP CL
AND AL,CL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
LAB_001c8a41:
CMP byte ptr [RSP + 0x1f],0x6
JNZ 0x001c8a6c
CMP byte ptr [RSP + 0x1e],0x5
JNZ 0x001c8a6c
MOV RAX,qword ptr [RSP + 0x28]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RSP + 0x20]
CMP RAX,qword ptr [RCX + 0x8]
SETZ AL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
LAB_001c8a6c:
CMP byte ptr [RSP + 0x1f],0x5
JNZ 0x001c8a97
CMP byte ptr [RSP + 0x1e],0x6
JNZ 0x001c8a97
MOV RAX,qword ptr [RSP + 0x28]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RSP + 0x20]
CMP RAX,qword ptr [RCX + 0x8]
SETZ AL
AND AL,0x1
MOV byte ptr [RSP + 0x37],AL
JMP 0x001c8ac8
LAB_001c8a97:
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,qword ptr [RSP + 0x20]
XOR EDX,EDX
CALL 0x001c8c80
TEST AL,0x1
JNZ 0x001c8aae
JMP 0x001c8ab5
LAB_001c8aae:
MOV byte ptr [RSP + 0x37],0x0
JMP 0x001c8ac8
LAB_001c8ab5:
JMP 0x001c8ab7
LAB_001c8ab7:
JMP 0x001c8ab9
LAB_001c8ab9:
JMP 0x001c8abb
LAB_001c8abb:
JMP 0x001c8abd
LAB_001c8abd:
JMP 0x001c8abf
LAB_001c8abf:
JMP 0x001c8ac1
LAB_001c8ac1:
JMP 0x001c8ac3
LAB_001c8ac3:
MOV byte ptr [RSP + 0x37],0x0
LAB_001c8ac8:
MOV AL,byte ptr [RSP + 0x37]
AND AL,0x1
ADD RSP,0x38
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* nlohmann::json_abi_v3_11_3::TEMPNAMEPLACEHOLDERVALUE(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> const&) */
bool nlohmann::json_abi_v3_11_3::operator==(basic_json *param_1,basic_json *param_2)
{
int8 uVar1;
byte bVar2;
byte bVar3;
ulong uVar4;
int1 auVar5 [16];
int1 auVar6 [16];
bool local_1;
bVar2 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::type((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*)param_1);
bVar3 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::type((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*)param_2);
if (bVar2 != bVar3) {
if ((bVar2 == 5) && (bVar3 == 7)) {
return (double)*(long *)(param_1 + 8) == *(double *)(param_2 + 8);
}
if ((bVar2 == 7) && (bVar3 == 5)) {
return *(double *)(param_1 + 8) == (double)*(long *)(param_2 + 8);
}
if ((bVar2 == 6) && (bVar3 == 7)) {
uVar1 = *(int8 *)(param_1 + 8);
auVar5._8_4_ = (int)((ulong)uVar1 >> 0x20);
auVar5._0_8_ = uVar1;
auVar5._12_4_ = _UNK_002c21d4;
return (auVar5._8_8_ - _UNK_002c21e8) +
((double)CONCAT44(_DAT_002c21d0,(int)uVar1) - _DAT_002c21e0) ==
*(double *)(param_2 + 8);
}
if ((bVar2 == 7) && (bVar3 == 6)) {
uVar1 = *(int8 *)(param_2 + 8);
auVar6._8_4_ = (int)((ulong)uVar1 >> 0x20);
auVar6._0_8_ = uVar1;
auVar6._12_4_ = _UNK_002c21d4;
return *(double *)(param_1 + 8) ==
(auVar6._8_8_ - _UNK_002c21e8) +
((double)CONCAT44(_DAT_002c21d0,(int)uVar1) - _DAT_002c21e0);
}
if ((bVar2 == 6) && (bVar3 == 5)) {
return *(long *)(param_1 + 8) == *(long *)(param_2 + 8);
}
if ((bVar2 == 5) && (bVar3 == 6)) {
return *(long *)(param_1 + 8) == *(long *)(param_2 + 8);
}
uVar4 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::compares_unordered(param_1,param_2,false);
if ((uVar4 & 1) == 0) {
return false;
}
return false;
}
if ((ulong)bVar2 < 10) {
switch((long)&switchD_001c87cf::switchdataD_002c2df4 +
(long)(int)(&switchD_001c87cf::switchdataD_002c2df4)[bVar2]) {
case 0x1c87d1:
/* try { // try from 001c87e3 to 001c88fd has its CatchHandler @ 001c8ad3 */
local_1 = std::operator==(*(vector **)(param_1 + 8),*(vector **)(param_2 + 8));
break;
case 0x1c87fd:
local_1 = std::operator==(*(vector **)(param_1 + 8),*(vector **)(param_2 + 8));
break;
case 0x1c8829:
local_1 = true;
break;
case 0x1c8833:
bVar2 = std::operator==(*(string **)(param_1 + 8),*(string **)(param_2 + 8));
local_1 = (bool)(bVar2 & 1);
break;
case 0x1c8855:
local_1 = ((byte)param_1[8] & 1) == ((byte)param_2[8] & 1);
break;
case 0x1c8880:
local_1 = *(long *)(param_1 + 8) == *(long *)(param_2 + 8);
break;
case 0x1c88a0:
local_1 = *(long *)(param_1 + 8) == *(long *)(param_2 + 8);
break;
case 0x1c88c0:
local_1 = *(double *)(param_1 + 8) == *(double *)(param_2 + 8);
break;
case 0x1c88e7:
bVar2 = byte_container_with_subtype<std::vector<unsigned_char,std::allocator<unsigned_char>>>
::operator==(*(byte_container_with_subtype<std::vector<unsigned_char,std::allocator<unsigned_char>>>
**)(param_1 + 8),*(byte_container_with_subtype **)(param_2 + 8));
local_1 = (bool)(bVar2 & 1);
break;
case 0x1c8913:
goto LAB_001c8915;
}
}
else {
LAB_001c8915:
local_1 = false;
}
return local_1;
}
|
|
19,912
|
mi_uint7korr
|
eloqsql/include/byte_order_generic_x86_64.h
|
static inline ulonglong mi_uint7korr(const void *p)
{
ulonglong a= *(uint32 *) p;
ulonglong b= *(uint16 *) (4 + (char *) p);
ulonglong c= *(6 + (uchar *) p);
ulonglong v= (a | (b << 32) | (c << 48)) << 8;
asm ("bswapq %0" : "=r" (v) : "0" (v));
return v;
}
|
O0
|
c
|
mi_uint7korr:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %eax
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rax
movzwl 0x4(%rax), %eax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movzbl 0x6(%rax), %eax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq -0x18(%rbp), %rcx
shlq $0x20, %rcx
orq %rcx, %rax
movq -0x20(%rbp), %rcx
shlq $0x30, %rcx
orq %rcx, %rax
shlq $0x8, %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
bswapq %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
popq %rbp
retq
nopl (%rax)
|
mi_uint7korr_0:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov eax, [rax]
mov [rbp+var_10], rax
mov rax, [rbp+var_8]
movzx eax, word ptr [rax+4]
mov [rbp+var_18], rax
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+6]
mov [rbp+var_20], rax
mov rax, [rbp+var_10]
mov rcx, [rbp+var_18]
shl rcx, 20h
or rax, rcx
mov rcx, [rbp+var_20]
shl rcx, 30h
or rax, rcx
shl rax, 8
mov [rbp+var_28], rax
mov rax, [rbp+var_28]
bswap rax
mov [rbp+var_28], rax
mov rax, [rbp+var_28]
pop rbp
retn
|
unsigned long long mi_uint7korr_0(unsigned int *a1)
{
return _byteswap_uint64((((unsigned long long)*((unsigned __int8 *)a1 + 6) << 48) | ((unsigned long long)*((unsigned __int16 *)a1 + 2) << 32) | *a1) << 8);
}
|
mi_uint7korr:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,word ptr [RAX + 0x4]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0x6]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x18]
SHL RCX,0x20
OR RAX,RCX
MOV RCX,qword ptr [RBP + -0x20]
SHL RCX,0x30
OR RAX,RCX
SHL RAX,0x8
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x28]
BSWAP RAX
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x28]
POP RBP
RET
|
ulong mi_uint7korr(uint7 *param_1)
{
ulong uVar1;
uVar1 = (ulong)*param_1 << 8;
return uVar1 >> 0x38 | (uVar1 & 0xff000000000000) >> 0x28 | (uVar1 & 0xff0000000000) >> 0x18 |
(uVar1 & 0xff00000000) >> 8 | (uVar1 & 0xff000000) << 8 | (uVar1 & 0xff0000) << 0x18 |
(uVar1 & 0xff00) << 0x28;
}
|
|
19,913
|
llama_sampler_temp_impl(llama_token_data_array*, float)
|
monkey531[P]llama/src/llama-sampling.cpp
|
static void llama_sampler_temp_impl(llama_token_data_array * cur_p, float temp) {
if (temp <= 0.0f) {
// find the token with the highest logit and set the rest to -inf
size_t max_i = 0;
float max_l = cur_p->data[0].logit;
for (size_t i = 1; i < cur_p->size; ++i) {
if (cur_p->data[i ].logit > max_l) {
cur_p->data[max_i].logit = -INFINITY;
max_i = i;
max_l = cur_p->data[i].logit;
} else {
cur_p->data[i].logit = -INFINITY;
}
}
return;
}
for (size_t i = 0; i < cur_p->size; ++i) {
cur_p->data[i].logit /= temp;
}
}
|
O3
|
cpp
|
llama_sampler_temp_impl(llama_token_data_array*, float):
xorps %xmm1, %xmm1
ucomiss %xmm0, %xmm1
jae 0xdee59
movq 0x8(%rdi), %rax
testq %rax, %rax
je 0xdeea6
movq (%rdi), %rcx
addq $0x4, %rcx
movss (%rcx), %xmm1
divss %xmm0, %xmm1
movss %xmm1, (%rcx)
addq $0xc, %rcx
decq %rax
jne 0xdee42
jmp 0xdeea6
movq 0x8(%rdi), %rax
cmpq $0x2, %rax
jb 0xdeea6
movq (%rdi), %rcx
movss 0x4(%rcx), %xmm0
leaq 0x10(%rcx), %rdx
movl $0x1, %esi
xorl %edi, %edi
movss (%rdx), %xmm1
ucomiss %xmm0, %xmm1
jbe 0xdee94
leaq (%rdi,%rdi,2), %rdi
movl $0xff800000, 0x4(%rcx,%rdi,4) # imm = 0xFF800000
movss (%rdx), %xmm0
movq %rsi, %rdi
jmp 0xdee9a
movl $0xff800000, (%rdx) # imm = 0xFF800000
incq %rsi
addq $0xc, %rdx
cmpq %rsi, %rax
jne 0xdee76
retq
|
_ZL23llama_sampler_temp_implP22llama_token_data_arrayf:
xorps xmm1, xmm1
ucomiss xmm1, xmm0
jnb short loc_DEE59
mov rax, [rdi+8]
test rax, rax
jz short locret_DEEA6
mov rcx, [rdi]
add rcx, 4
loc_DEE42:
movss xmm1, dword ptr [rcx]
divss xmm1, xmm0
movss dword ptr [rcx], xmm1
add rcx, 0Ch
dec rax
jnz short loc_DEE42
jmp short locret_DEEA6
loc_DEE59:
mov rax, [rdi+8]
cmp rax, 2
jb short locret_DEEA6
mov rcx, [rdi]
movss xmm0, dword ptr [rcx+4]
lea rdx, [rcx+10h]
mov esi, 1
xor edi, edi
loc_DEE76:
movss xmm1, dword ptr [rdx]
ucomiss xmm1, xmm0
jbe short loc_DEE94
lea rdi, [rdi+rdi*2]
mov dword ptr [rcx+rdi*4+4], 0FF800000h
movss xmm0, dword ptr [rdx]
mov rdi, rsi
jmp short loc_DEE9A
loc_DEE94:
mov dword ptr [rdx], 0FF800000h
loc_DEE9A:
inc rsi
add rdx, 0Ch
cmp rax, rsi
jnz short loc_DEE76
locret_DEEA6:
retn
|
unsigned long long llama_sampler_temp_impl(_QWORD *a1, float a2)
{
unsigned long long result; // rax
float *v3; // rcx
long long v4; // rcx
float v5; // xmm0_4
float *v6; // rdx
long long v7; // rsi
long long v8; // rdi
if ( a2 <= 0.0 )
{
result = a1[1];
if ( result >= 2 )
{
v4 = *a1;
v5 = *(float *)(*a1 + 4LL);
v6 = (float *)(*a1 + 16LL);
v7 = 1LL;
v8 = 0LL;
do
{
if ( *v6 <= v5 )
{
*v6 = -INFINITY;
}
else
{
*(_DWORD *)(v4 + 12 * v8 + 4) = -8388608;
v5 = *v6;
v8 = v7;
}
++v7;
v6 += 3;
}
while ( result != v7 );
}
}
else
{
result = a1[1];
if ( result )
{
v3 = (float *)(*a1 + 4LL);
do
{
*v3 = *v3 / a2;
v3 += 3;
--result;
}
while ( result );
}
}
return result;
}
|
llama_sampler_temp_impl:
XORPS XMM1,XMM1
UCOMISS XMM1,XMM0
JNC 0x001dee59
MOV RAX,qword ptr [RDI + 0x8]
TEST RAX,RAX
JZ 0x001deea6
MOV RCX,qword ptr [RDI]
ADD RCX,0x4
LAB_001dee42:
MOVSS XMM1,dword ptr [RCX]
DIVSS XMM1,XMM0
MOVSS dword ptr [RCX],XMM1
ADD RCX,0xc
DEC RAX
JNZ 0x001dee42
JMP 0x001deea6
LAB_001dee59:
MOV RAX,qword ptr [RDI + 0x8]
CMP RAX,0x2
JC 0x001deea6
MOV RCX,qword ptr [RDI]
MOVSS XMM0,dword ptr [RCX + 0x4]
LEA RDX,[RCX + 0x10]
MOV ESI,0x1
XOR EDI,EDI
LAB_001dee76:
MOVSS XMM1,dword ptr [RDX]
UCOMISS XMM1,XMM0
JBE 0x001dee94
LEA RDI,[RDI + RDI*0x2]
MOV dword ptr [RCX + RDI*0x4 + 0x4],0xff800000
MOVSS XMM0,dword ptr [RDX]
MOV RDI,RSI
JMP 0x001dee9a
LAB_001dee94:
MOV dword ptr [RDX],0xff800000
LAB_001dee9a:
INC RSI
ADD RDX,0xc
CMP RAX,RSI
JNZ 0x001dee76
LAB_001deea6:
RET
|
/* llama_sampler_temp_impl(llama_token_data_array*, float) */
void llama_sampler_temp_impl(llama_token_data_array *param_1,float param_2)
{
ulong uVar1;
long lVar2;
float *pfVar3;
ulong uVar4;
ulong uVar5;
float fVar6;
if (param_2 <= 0.0) {
uVar1 = *(ulong *)(param_1 + 8);
if (1 < uVar1) {
lVar2 = *(long *)param_1;
fVar6 = *(float *)(lVar2 + 4);
pfVar3 = (float *)(lVar2 + 0x10);
uVar4 = 1;
uVar5 = 0;
do {
if (*pfVar3 <= fVar6) {
*pfVar3 = -INFINITY;
}
else {
*(int4 *)(lVar2 + 4 + uVar5 * 0xc) = 0xff800000;
fVar6 = *pfVar3;
uVar5 = uVar4;
}
uVar4 = uVar4 + 1;
pfVar3 = pfVar3 + 3;
} while (uVar1 != uVar4);
}
}
else {
lVar2 = *(long *)(param_1 + 8);
if (lVar2 != 0) {
pfVar3 = (float *)(*(long *)param_1 + 4);
do {
*pfVar3 = *pfVar3 / param_2;
pfVar3 = pfVar3 + 3;
lVar2 = lVar2 + -1;
} while (lVar2 != 0);
}
}
return;
}
|
|
19,914
|
resize_key_cache
|
eloqsql/mysys/mf_keycache.c
|
int resize_key_cache(KEY_CACHE *keycache, uint key_cache_block_size,
size_t use_mem, uint division_limit, uint age_threshold,
uint changed_blocks_hash_size)
{
int blocks= -1;
if (keycache->key_cache_inited)
{
pthread_mutex_lock(&keycache->op_lock);
if ((uint) keycache->param_partitions != keycache->partitions && use_mem)
blocks= repartition_key_cache_internal(keycache,
key_cache_block_size, use_mem,
division_limit, age_threshold,
changed_blocks_hash_size,
(uint) keycache->param_partitions,
0);
else
{
blocks= keycache->interface_funcs->resize(keycache->keycache_cb,
key_cache_block_size,
use_mem, division_limit,
age_threshold,
changed_blocks_hash_size);
if (keycache->partitions)
keycache->partitions=
((PARTITIONED_KEY_CACHE_CB *)(keycache->keycache_cb))->partitions;
}
keycache->key_cache_mem_size=
keycache->partitions ?
((PARTITIONED_KEY_CACHE_CB *)(keycache->keycache_cb))->key_cache_mem_size :
((SIMPLE_KEY_CACHE_CB *)(keycache->keycache_cb))->key_cache_mem_size;
keycache->can_be_used= (blocks >= 0);
pthread_mutex_unlock(&keycache->op_lock);
}
return blocks;
}
|
O0
|
c
|
resize_key_cache:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movl %r8d, -0x20(%rbp)
movl %r9d, -0x24(%rbp)
movl $0xffffffff, -0x28(%rbp) # imm = 0xFFFFFFFF
movq -0x8(%rbp), %rax
cmpb $0x0, 0x48(%rax)
je 0xe4811
movq -0x8(%rbp), %rdi
addq $0x58, %rdi
callq 0x2a210
movq -0x8(%rbp), %rax
movq 0x38(%rax), %rax
movq -0x8(%rbp), %rcx
cmpl 0x4c(%rcx), %eax
je 0xe476e
cmpq $0x0, -0x18(%rbp)
je 0xe476e
movq -0x8(%rbp), %rdi
movl -0xc(%rbp), %esi
movq -0x18(%rbp), %rdx
movl -0x1c(%rbp), %ecx
movl -0x20(%rbp), %r8d
movl -0x24(%rbp), %r9d
movq -0x8(%rbp), %rax
movq 0x38(%rax), %rax
xorl %r10d, %r10d
movl %eax, (%rsp)
movl $0x0, 0x8(%rsp)
callq 0xe4820
movl %eax, -0x28(%rbp)
jmp 0xe47b7
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x8(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x8(%rcx), %rdi
movl -0xc(%rbp), %esi
movq -0x18(%rbp), %rdx
movl -0x1c(%rbp), %ecx
movl -0x20(%rbp), %r8d
movl -0x24(%rbp), %r9d
callq *%rax
movl %eax, -0x28(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x0, 0x4c(%rax)
je 0xe47b5
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movl 0x1c(%rax), %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x4c(%rax)
jmp 0xe47b7
movq -0x8(%rbp), %rax
cmpl $0x0, 0x4c(%rax)
je 0xe47d3
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x10(%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0xe47e3
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x50(%rax)
cmpl $0x0, -0x28(%rbp)
setge %al
andb $0x1, %al
movzbl %al, %eax
movb %al, %cl
movq -0x8(%rbp), %rax
movb %cl, 0x49(%rax)
movq -0x8(%rbp), %rdi
addq $0x58, %rdi
callq 0x2a1e0
movl -0x28(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)
|
resize_key_cache:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_18], rdx
mov [rbp+var_1C], ecx
mov [rbp+var_20], r8d
mov [rbp+var_24], r9d
mov [rbp+var_28], 0FFFFFFFFh
mov rax, [rbp+var_8]
cmp byte ptr [rax+48h], 0
jz loc_E4811
mov rdi, [rbp+var_8]
add rdi, 58h ; 'X'
call _pthread_mutex_lock
mov rax, [rbp+var_8]
mov rax, [rax+38h]
mov rcx, [rbp+var_8]
cmp eax, [rcx+4Ch]
jz short loc_E476E
cmp [rbp+var_18], 0
jz short loc_E476E
mov rdi, [rbp+var_8]
mov esi, [rbp+var_C]
mov rdx, [rbp+var_18]
mov ecx, [rbp+var_1C]
mov r8d, [rbp+var_20]
mov r9d, [rbp+var_24]
mov rax, [rbp+var_8]
mov rax, [rax+38h]
xor r10d, r10d
mov [rsp+40h+var_40], eax
mov [rsp+40h+var_38], 0
call repartition_key_cache_internal
mov [rbp+var_28], eax
jmp short loc_E47B7
loc_E476E:
mov rax, [rbp+var_8]
mov rax, [rax+10h]
mov rax, [rax+8]
mov rcx, [rbp+var_8]
mov rdi, [rcx+8]
mov esi, [rbp+var_C]
mov rdx, [rbp+var_18]
mov ecx, [rbp+var_1C]
mov r8d, [rbp+var_20]
mov r9d, [rbp+var_24]
call rax
mov [rbp+var_28], eax
mov rax, [rbp+var_8]
cmp dword ptr [rax+4Ch], 0
jz short loc_E47B5
mov rax, [rbp+var_8]
mov rax, [rax+8]
mov ecx, [rax+1Ch]
mov rax, [rbp+var_8]
mov [rax+4Ch], ecx
loc_E47B5:
jmp short $+2
loc_E47B7:
mov rax, [rbp+var_8]
cmp dword ptr [rax+4Ch], 0
jz short loc_E47D3
mov rax, [rbp+var_8]
mov rax, [rax+8]
mov rax, [rax+10h]
mov [rbp+var_30], rax
jmp short loc_E47E3
loc_E47D3:
mov rax, [rbp+var_8]
mov rax, [rax+8]
mov rax, [rax+8]
mov [rbp+var_30], rax
loc_E47E3:
mov rcx, [rbp+var_30]
mov rax, [rbp+var_8]
mov [rax+50h], rcx
cmp [rbp+var_28], 0
setnl al
and al, 1
movzx eax, al
mov cl, al
mov rax, [rbp+var_8]
mov [rax+49h], cl
mov rdi, [rbp+var_8]
add rdi, 58h ; 'X'
call _pthread_mutex_unlock
loc_E4811:
mov eax, [rbp+var_28]
add rsp, 40h
pop rbp
retn
|
long long resize_key_cache(
long long a1,
unsigned int a2,
long long a3,
unsigned int a4,
unsigned int a5,
unsigned int a6)
{
long long v7; // [rsp+10h] [rbp-30h]
int v8; // [rsp+18h] [rbp-28h]
v8 = -1;
if ( *(_BYTE *)(a1 + 72) )
{
pthread_mutex_lock(a1 + 88);
if ( (unsigned int)*(_QWORD *)(a1 + 56) == *(_DWORD *)(a1 + 76) || !a3 )
{
v8 = (*(long long ( **)(_QWORD, _QWORD, long long, _QWORD, _QWORD, _QWORD))(*(_QWORD *)(a1 + 16) + 8LL))(
*(_QWORD *)(a1 + 8),
a2,
a3,
a4,
a5,
a6);
if ( *(_DWORD *)(a1 + 76) )
*(_DWORD *)(a1 + 76) = *(_DWORD *)(*(_QWORD *)(a1 + 8) + 28LL);
}
else
{
v8 = repartition_key_cache_internal(a1, a2, a3, a4, a5, a6, *(_QWORD *)(a1 + 56), 0);
}
if ( *(_DWORD *)(a1 + 76) )
v7 = *(_QWORD *)(*(_QWORD *)(a1 + 8) + 16LL);
else
v7 = *(_QWORD *)(*(_QWORD *)(a1 + 8) + 8LL);
*(_QWORD *)(a1 + 80) = v7;
*(_BYTE *)(a1 + 73) = v8 >= 0;
pthread_mutex_unlock(a1 + 88);
}
return (unsigned int)v8;
}
|
resize_key_cache:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV qword ptr [RBP + -0x18],RDX
MOV dword ptr [RBP + -0x1c],ECX
MOV dword ptr [RBP + -0x20],R8D
MOV dword ptr [RBP + -0x24],R9D
MOV dword ptr [RBP + -0x28],0xffffffff
MOV RAX,qword ptr [RBP + -0x8]
CMP byte ptr [RAX + 0x48],0x0
JZ 0x001e4811
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x58
CALL 0x0012a210
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x38]
MOV RCX,qword ptr [RBP + -0x8]
CMP EAX,dword ptr [RCX + 0x4c]
JZ 0x001e476e
CMP qword ptr [RBP + -0x18],0x0
JZ 0x001e476e
MOV RDI,qword ptr [RBP + -0x8]
MOV ESI,dword ptr [RBP + -0xc]
MOV RDX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0x1c]
MOV R8D,dword ptr [RBP + -0x20]
MOV R9D,dword ptr [RBP + -0x24]
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x38]
XOR R10D,R10D
MOV dword ptr [RSP],EAX
MOV dword ptr [RSP + 0x8],0x0
CALL 0x001e4820
MOV dword ptr [RBP + -0x28],EAX
JMP 0x001e47b7
LAB_001e476e:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RCX + 0x8]
MOV ESI,dword ptr [RBP + -0xc]
MOV RDX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0x1c]
MOV R8D,dword ptr [RBP + -0x20]
MOV R9D,dword ptr [RBP + -0x24]
CALL RAX
MOV dword ptr [RBP + -0x28],EAX
MOV RAX,qword ptr [RBP + -0x8]
CMP dword ptr [RAX + 0x4c],0x0
JZ 0x001e47b5
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV ECX,dword ptr [RAX + 0x1c]
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x4c],ECX
LAB_001e47b5:
JMP 0x001e47b7
LAB_001e47b7:
MOV RAX,qword ptr [RBP + -0x8]
CMP dword ptr [RAX + 0x4c],0x0
JZ 0x001e47d3
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x30],RAX
JMP 0x001e47e3
LAB_001e47d3:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x30],RAX
LAB_001e47e3:
MOV RCX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x50],RCX
CMP dword ptr [RBP + -0x28],0x0
SETGE AL
AND AL,0x1
MOVZX EAX,AL
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x49],CL
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x58
CALL 0x0012a1e0
LAB_001e4811:
MOV EAX,dword ptr [RBP + -0x28]
ADD RSP,0x40
POP RBP
RET
|
int resize_key_cache(long param_1,int4 param_2,long param_3,int4 param_4,
int4 param_5,int4 param_6)
{
int8 local_38;
int4 local_30;
local_30 = -1;
if (*(char *)(param_1 + 0x48) != '\0') {
pthread_mutex_lock((pthread_mutex_t *)(param_1 + 0x58));
if (((int)*(int8 *)(param_1 + 0x38) == *(int *)(param_1 + 0x4c)) || (param_3 == 0)) {
local_30 = (**(code **)(*(long *)(param_1 + 0x10) + 8))
(*(int8 *)(param_1 + 8),param_2,param_3,param_4,param_5,param_6);
if (*(int *)(param_1 + 0x4c) != 0) {
*(int4 *)(param_1 + 0x4c) = *(int4 *)(*(long *)(param_1 + 8) + 0x1c);
}
}
else {
local_30 = repartition_key_cache_internal
(param_1,param_2,param_3,param_4,param_5,param_6,
(int)*(int8 *)(param_1 + 0x38),0);
}
if (*(int *)(param_1 + 0x4c) == 0) {
local_38 = *(int8 *)(*(long *)(param_1 + 8) + 8);
}
else {
local_38 = *(int8 *)(*(long *)(param_1 + 8) + 0x10);
}
*(int8 *)(param_1 + 0x50) = local_38;
*(bool *)(param_1 + 0x49) = -1 < local_30;
pthread_mutex_unlock((pthread_mutex_t *)(param_1 + 0x58));
}
return local_30;
}
|
|
19,915
|
verify_segment_integrity
|
seiftnesse[P]memoryallocator/src/custom_alloc_util.c
|
int verify_segment_integrity(segment_t *s, int repair) {
if (!s) return 0;
int errors = 0;
// Basic check - magic number (always performed)
if (s->magic != SEGMENT_MAGIC) {
HEAP_LOG("CORRUPTION: Invalid magic number in segment %p: 0x%08X != 0x%08X\n",
s, s->magic, SEGMENT_MAGIC);
errors++;
if (repair) {
s->magic = SEGMENT_MAGIC;
HEAP_LOG("Repaired: Reset magic number for segment %p\n", s);
}
}
// Size sanity check (basic)
if (s->size <= 0 || s->size > MAX_REASONABLE_BLOCKS) {
HEAP_LOG("CORRUPTION: Unreasonable size in segment %p: %d blocks\n", s, s->size);
errors++;
if (repair && s->next) {
// Try to determine reasonable size from distance to next segment
uintptr_t next_addr = (uintptr_t)(s->next);
uintptr_t this_addr = (uintptr_t)(s);
int corrected_size = (next_addr - this_addr) / BLOCK_SIZE;
if (corrected_size > 0 && corrected_size <= MAX_REASONABLE_BLOCKS) {
s->size = corrected_size;
HEAP_LOG("Repaired: Corrected size for segment %p to %d blocks based on next segment\n",
s, s->size);
}
}
}
// Stop here if only basic checks are enabled
if (integrity_check_level < 2) return errors;
// Get the integrity structure - ВАЖНО: добавлен детальный вывод для отладки
segment_integrity_t *integrity = get_segment_integrity(s);
if (!integrity) {
HEAP_LOG("WARNING: Could not get integrity structure for segment %p\n", s);
if (repair) {
HEAP_LOG("Attempting to initialize integrity for segment %p\n", s);
initialize_segment_integrity(s);
integrity = get_segment_integrity(s);
}
if (!integrity) {
HEAP_LOG("CRITICAL: Cannot perform integrity checks - no integrity structure available\n");
return errors;
}
}
HEAP_LOG("Checking integrity for segment %p: header_guard=0x%08X, checksum=0x%08X\n",
s, integrity->header_guard, integrity->checksum);
// Check header guard
if (integrity->header_guard != HEADER_GUARD_VALUE) {
HEAP_LOG("CORRUPTION: Invalid header guard in segment %p: 0x%08X != 0x%08X\n",
s, integrity->header_guard, HEADER_GUARD_VALUE);
errors++;
if (repair) {
integrity->header_guard = HEADER_GUARD_VALUE;
HEAP_LOG("Repaired: Reset header guard for segment %p\n", s);
}
}
// Check checksum
uint32_t current_checksum = calculate_segment_checksum(s);
if (integrity->checksum != current_checksum) {
HEAP_LOG("CORRUPTION: Invalid checksum in segment %p: 0x%08X != 0x%08X\n",
s, integrity->checksum, current_checksum);
errors++;
if (repair) {
integrity->checksum = current_checksum;
HEAP_LOG("Repaired: Reset checksum for segment %p\n", s);
}
}
// Check footer guard only if level 3 checks are enabled
if (integrity_check_level >= 3) {
uint32_t *footer = get_segment_footer(s);
if (footer) {
HEAP_LOG("Footer guard check for segment %p: current=0x%08X, expected=0x%08X\n",
s, *footer, FOOTER_GUARD_VALUE);
if (*footer != FOOTER_GUARD_VALUE) {
HEAP_LOG("CORRUPTION: Invalid footer guard in segment %p: 0x%08X != 0x%08X\n",
s, *footer, FOOTER_GUARD_VALUE);
errors++;
if (repair) {
*footer = FOOTER_GUARD_VALUE;
HEAP_LOG("Repaired: Reset footer guard for segment %p\n", s);
}
}
} else {
HEAP_LOG("WARNING: Could not get footer pointer for segment %p\n", s);
}
// Linked list checks - добавлена проверка на null
if (s->next) {
HEAP_LOG("Checking next segment link: %p->next = %p, %p->next->prev = %p\n",
s, s->next, s->next, s->next->prev);
if (s->next->prev != s) {
HEAP_LOG("CORRUPTION: Broken linked list: s->next->prev != s for segment %p\n", s);
errors++;
if (repair) {
s->next->prev = s;
HEAP_LOG("Repaired: Fixed broken linked list for segment %p\n", s);
}
}
}
if (s->prev) {
HEAP_LOG("Checking prev segment link: %p->prev = %p, %p->prev->next = %p\n",
s, s->prev, s->prev, s->prev->next);
if (s->prev->next != s) {
HEAP_LOG("CORRUPTION: Broken linked list: s->prev->next != s for segment %p\n", s);
errors++;
if (repair) {
s->prev->next = s;
HEAP_LOG("Repaired: Fixed broken linked list for segment %p\n", s);
}
}
}
// Check that segment is within heap bounds
uintptr_t heap_start = (uintptr_t)(memory);
uintptr_t heap_end = heap_start + HEAP_SIZE;
uintptr_t segment_addr = (uintptr_t)(s);
if (segment_addr < heap_start || segment_addr >= heap_end) {
HEAP_LOG("CORRUPTION: Segment %p is outside heap bounds [%p-%p]\n",
s, (void*)heap_start, (void*)heap_end);
errors++;
// Cannot repair this automatically
}
}
return errors;
}
|
O1
|
c
|
verify_segment_integrity:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x3dc4
movq %rdi, %r14
xorl %ebx, %ebx
cmpl $0xcafebafe, 0x28(%rdi) # imm = 0xCAFEBAFE
je 0x3d44
movl $0x1, %ebx
testl %esi, %esi
je 0x3d44
movl $0xcafebafe, 0x28(%r14) # imm = 0xCAFEBAFE
movl $0xffffbfff, %eax # imm = 0xFFFFBFFF
movl 0x4(%r14), %ecx
addl %eax, %ecx
cmpl %eax, %ecx
ja 0x3d78
incl %ebx
testl %esi, %esi
je 0x3d78
movq 0x8(%r14), %rax
testq %rax, %rax
je 0x3d78
subq %r14, %rax
shrq $0xc, %rax
leal -0x1(%rax), %ecx
cmpl $0x3fff, %ecx # imm = 0x3FFF
ja 0x3d78
movl %eax, 0x4(%r14)
cmpl $0x2, 0x4385(%rip) # 0x8104
jl 0x3ebe
leaq 0x3f(%r14), %r13
andq $-0x10, %r13
leaq 0x3c(%r14), %rbp
leaq 0x30(%r14), %r12
xorl %r15d, %r15d
cmpq %r13, %rbp
cmovbeq %r12, %r15
testq %r15, %r15
jne 0x3dd7
testl %esi, %esi
je 0x3dcb
movq %r14, %rdi
movl %esi, %r15d
callq 0x3af7
movl %r15d, %esi
xorl %eax, %eax
cmpq %r13, %rbp
cmovaq %rax, %r12
movq %r12, %r15
jmp 0x3dce
xorl %ebx, %ebx
jmp 0x3ebe
xorl %r15d, %r15d
testq %r15, %r15
je 0x3ebe
cmpl $0xfeedface, (%r15) # imm = 0xFEEDFACE
je 0x3df1
incl %ebx
testl %esi, %esi
je 0x3df1
movl %esi, %ebp
movl $0xfeedface, (%r15) # imm = 0xFEEDFACE
jmp 0x3df3
movl %esi, %ebp
movq %r14, %rdi
callq 0x3c15
cmpl %eax, 0x4(%r15)
jne 0x3e05
movl %ebp, %esi
jmp 0x3e11
incl %ebx
movl %ebp, %esi
testl %ebp, %ebp
je 0x3e11
movl %eax, 0x4(%r15)
cmpl $0x3, 0x42ec(%rip) # 0x8104
jl 0x3ebe
movl 0x4(%r14), %ecx
leal -0x4001(%rcx), %eax
cmpl $0xffffc000, %eax # imm = 0xFFFFC000
jae 0x3e33
xorl %eax, %eax
jmp 0x3e53
shlq $0xc, %rcx
leaq (%rcx,%r14), %rax
addq $-0x4, %rax
addq %r14, %rcx
xorl %edx, %edx
cmpq %r14, %rax
cmovbeq %rdx, %rax
cmpq $0x4, %rcx
cmovbq %rdx, %rax
testq %rax, %rax
je 0x3e6c
cmpl $0xdeadc0de, (%rax) # imm = 0xDEADC0DE
je 0x3e6c
incl %ebx
testl %esi, %esi
je 0x3e6c
movl $0xdeadc0de, (%rax) # imm = 0xDEADC0DE
movq 0x8(%r14), %rax
testq %rax, %rax
je 0x3e85
cmpq %r14, 0x10(%rax)
je 0x3e85
incl %ebx
testl %esi, %esi
je 0x3e85
movq %r14, 0x10(%rax)
movq 0x10(%r14), %rax
testq %rax, %rax
je 0x3e9e
cmpq %r14, 0x8(%rax)
je 0x3e9e
incl %ebx
testl %esi, %esi
je 0x3e9e
movq %r14, 0x8(%rax)
leaq 0x10429b(%rip), %rax # 0x108140
cmpq %rax, %r14
setb %cl
addq $0x4000000, %rax # imm = 0x4000000
cmpq %rax, %r14
setae %al
orb %cl, %al
movzbl %al, %eax
addl %eax, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
verify_segment_integrity:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
test rdi, rdi
jz loc_3DC4
mov r14, rdi
xor ebx, ebx
cmp dword ptr [rdi+28h], 0CAFEBAFEh
jz short loc_3D44
mov ebx, 1
test esi, esi
jz short loc_3D44
mov dword ptr [r14+28h], 0CAFEBAFEh
loc_3D44:
mov eax, 0FFFFBFFFh
mov ecx, [r14+4]
add ecx, eax
cmp ecx, eax
ja short loc_3D78
inc ebx
test esi, esi
jz short loc_3D78
mov rax, [r14+8]
test rax, rax
jz short loc_3D78
sub rax, r14
shr rax, 0Ch
lea ecx, [rax-1]
cmp ecx, 3FFFh
ja short loc_3D78
mov [r14+4], eax
loc_3D78:
cmp cs:integrity_check_level, 2
jl loc_3EBE
lea r13, [r14+3Fh]
and r13, 0FFFFFFFFFFFFFFF0h
lea rbp, [r14+3Ch]
lea r12, [r14+30h]
xor r15d, r15d
cmp rbp, r13
cmovbe r15, r12
test r15, r15
jnz short loc_3DD7
test esi, esi
jz short loc_3DCB
mov rdi, r14
mov r15d, esi
call initialize_segment_integrity
mov esi, r15d
xor eax, eax
cmp rbp, r13
cmova r12, rax
mov r15, r12
jmp short loc_3DCE
loc_3DC4:
xor ebx, ebx
jmp loc_3EBE
loc_3DCB:
xor r15d, r15d
loc_3DCE:
test r15, r15
jz loc_3EBE
loc_3DD7:
cmp dword ptr [r15], 0FEEDFACEh
jz short loc_3DF1
inc ebx
test esi, esi
jz short loc_3DF1
mov ebp, esi
mov dword ptr [r15], 0FEEDFACEh
jmp short loc_3DF3
loc_3DF1:
mov ebp, esi
loc_3DF3:
mov rdi, r14
call calculate_segment_checksum
cmp [r15+4], eax
jnz short loc_3E05
mov esi, ebp
jmp short loc_3E11
loc_3E05:
inc ebx
mov esi, ebp
test ebp, ebp
jz short loc_3E11
mov [r15+4], eax
loc_3E11:
cmp cs:integrity_check_level, 3
jl loc_3EBE
mov ecx, [r14+4]
lea eax, [rcx-4001h]
cmp eax, 0FFFFC000h
jnb short loc_3E33
xor eax, eax
jmp short loc_3E53
loc_3E33:
shl rcx, 0Ch
lea rax, [rcx+r14]
add rax, 0FFFFFFFFFFFFFFFCh
add rcx, r14
xor edx, edx
cmp rax, r14
cmovbe rax, rdx
cmp rcx, 4
cmovb rax, rdx
loc_3E53:
test rax, rax
jz short loc_3E6C
cmp dword ptr [rax], 0DEADC0DEh
jz short loc_3E6C
inc ebx
test esi, esi
jz short loc_3E6C
mov dword ptr [rax], 0DEADC0DEh
loc_3E6C:
mov rax, [r14+8]
test rax, rax
jz short loc_3E85
cmp [rax+10h], r14
jz short loc_3E85
inc ebx
test esi, esi
jz short loc_3E85
mov [rax+10h], r14
loc_3E85:
mov rax, [r14+10h]
test rax, rax
jz short loc_3E9E
cmp [rax+8], r14
jz short loc_3E9E
inc ebx
test esi, esi
jz short loc_3E9E
mov [rax+8], r14
loc_3E9E:
lea rax, memory
cmp r14, rax
setb cl
add rax, 4000000h
cmp r14, rax
setnb al
or al, cl
movzx eax, al
add ebx, eax
loc_3EBE:
mov eax, ebx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long verify_segment_integrity(unsigned long long a1, int a2)
{
unsigned int v2; // ebx
long long v3; // rax
unsigned long long v4; // rax
unsigned long long v5; // r13
_DWORD *v6; // r12
_DWORD *v7; // r15
int v8; // ebp
int v9; // eax
int v10; // esi
long long v11; // rcx
_DWORD *v12; // rax
long long v13; // rcx
unsigned long long v14; // rcx
long long v15; // rax
long long v16; // rax
if ( a1 )
{
v2 = 0;
if ( *(_DWORD *)(a1 + 40) != -889275650 )
{
v2 = 1;
if ( a2 )
*(_DWORD *)(a1 + 40) = -889275650;
}
if ( (unsigned int)(*(_DWORD *)(a1 + 4) - 16385) <= 0xFFFFBFFF )
{
++v2;
if ( a2 )
{
v3 = *(_QWORD *)(a1 + 8);
if ( v3 )
{
v4 = (v3 - a1) >> 12;
if ( (unsigned int)(v4 - 1) <= 0x3FFF )
*(_DWORD *)(a1 + 4) = v4;
}
}
}
if ( integrity_check_level >= 2 )
{
v5 = (a1 + 63) & 0xFFFFFFFFFFFFFFF0LL;
v6 = (_DWORD *)(a1 + 48);
v7 = 0LL;
if ( a1 + 60 <= v5 )
v7 = (_DWORD *)(a1 + 48);
if ( v7 )
goto LABEL_52;
if ( a2 )
{
initialize_segment_integrity(a1);
if ( a1 + 60 > v5 )
v6 = 0LL;
v7 = v6;
}
else
{
v7 = 0LL;
}
if ( v7 )
{
LABEL_52:
if ( *v7 == -17958194 || (++v2, !a2) )
{
v8 = a2;
}
else
{
v8 = a2;
*v7 = -17958194;
}
v9 = calculate_segment_checksum(a1);
if ( v7[1] == v9 )
{
v10 = v8;
}
else
{
++v2;
v10 = v8;
if ( v8 )
v7[1] = v9;
}
if ( integrity_check_level >= 3 )
{
v11 = *(unsigned int *)(a1 + 4);
if ( (unsigned int)(v11 - 16385) >= 0xFFFFC000 )
{
v13 = v11 << 12;
v12 = (_DWORD *)(v13 + a1 - 4);
v14 = a1 + v13;
if ( (unsigned long long)v12 <= a1 )
v12 = 0LL;
if ( v14 < 4 )
v12 = 0LL;
}
else
{
v12 = 0LL;
}
if ( v12 )
{
if ( *v12 != -559038242 )
{
++v2;
if ( v10 )
*v12 = -559038242;
}
}
v15 = *(_QWORD *)(a1 + 8);
if ( v15 )
{
if ( *(_QWORD *)(v15 + 16) != a1 )
{
++v2;
if ( v10 )
*(_QWORD *)(v15 + 16) = a1;
}
}
v16 = *(_QWORD *)(a1 + 16);
if ( v16 )
{
if ( *(_QWORD *)(v16 + 8) != a1 )
{
++v2;
if ( v10 )
*(_QWORD *)(v16 + 8) = a1;
}
}
v2 += a1 < (unsigned long long)&memory || a1 >= (unsigned long long)&memory + 0x4000000;
}
}
}
}
else
{
return 0;
}
return v2;
}
|
verify_segment_integrity:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
TEST RDI,RDI
JZ 0x00103dc4
MOV R14,RDI
XOR EBX,EBX
CMP dword ptr [RDI + 0x28],0xcafebafe
JZ 0x00103d44
MOV EBX,0x1
TEST ESI,ESI
JZ 0x00103d44
MOV dword ptr [R14 + 0x28],0xcafebafe
LAB_00103d44:
MOV EAX,0xffffbfff
MOV ECX,dword ptr [R14 + 0x4]
ADD ECX,EAX
CMP ECX,EAX
JA 0x00103d78
INC EBX
TEST ESI,ESI
JZ 0x00103d78
MOV RAX,qword ptr [R14 + 0x8]
TEST RAX,RAX
JZ 0x00103d78
SUB RAX,R14
SHR RAX,0xc
LEA ECX,[RAX + -0x1]
CMP ECX,0x3fff
JA 0x00103d78
MOV dword ptr [R14 + 0x4],EAX
LAB_00103d78:
CMP dword ptr [0x00108104],0x2
JL 0x00103ebe
LEA R13,[R14 + 0x3f]
AND R13,-0x10
LEA RBP,[R14 + 0x3c]
LEA R12,[R14 + 0x30]
XOR R15D,R15D
CMP RBP,R13
CMOVBE R15,R12
TEST R15,R15
JNZ 0x00103dd7
TEST ESI,ESI
JZ 0x00103dcb
MOV RDI,R14
MOV R15D,ESI
CALL 0x00103af7
MOV ESI,R15D
XOR EAX,EAX
CMP RBP,R13
CMOVA R12,RAX
MOV R15,R12
JMP 0x00103dce
LAB_00103dc4:
XOR EBX,EBX
JMP 0x00103ebe
LAB_00103dcb:
XOR R15D,R15D
LAB_00103dce:
TEST R15,R15
JZ 0x00103ebe
LAB_00103dd7:
CMP dword ptr [R15],0xfeedface
JZ 0x00103df1
INC EBX
TEST ESI,ESI
JZ 0x00103df1
MOV EBP,ESI
MOV dword ptr [R15],0xfeedface
JMP 0x00103df3
LAB_00103df1:
MOV EBP,ESI
LAB_00103df3:
MOV RDI,R14
CALL 0x00103c15
CMP dword ptr [R15 + 0x4],EAX
JNZ 0x00103e05
MOV ESI,EBP
JMP 0x00103e11
LAB_00103e05:
INC EBX
MOV ESI,EBP
TEST EBP,EBP
JZ 0x00103e11
MOV dword ptr [R15 + 0x4],EAX
LAB_00103e11:
CMP dword ptr [0x00108104],0x3
JL 0x00103ebe
MOV ECX,dword ptr [R14 + 0x4]
LEA EAX,[RCX + -0x4001]
CMP EAX,0xffffc000
JNC 0x00103e33
XOR EAX,EAX
JMP 0x00103e53
LAB_00103e33:
SHL RCX,0xc
LEA RAX,[RCX + R14*0x1]
ADD RAX,-0x4
ADD RCX,R14
XOR EDX,EDX
CMP RAX,R14
CMOVBE RAX,RDX
CMP RCX,0x4
CMOVC RAX,RDX
LAB_00103e53:
TEST RAX,RAX
JZ 0x00103e6c
CMP dword ptr [RAX],0xdeadc0de
JZ 0x00103e6c
INC EBX
TEST ESI,ESI
JZ 0x00103e6c
MOV dword ptr [RAX],0xdeadc0de
LAB_00103e6c:
MOV RAX,qword ptr [R14 + 0x8]
TEST RAX,RAX
JZ 0x00103e85
CMP qword ptr [RAX + 0x10],R14
JZ 0x00103e85
INC EBX
TEST ESI,ESI
JZ 0x00103e85
MOV qword ptr [RAX + 0x10],R14
LAB_00103e85:
MOV RAX,qword ptr [R14 + 0x10]
TEST RAX,RAX
JZ 0x00103e9e
CMP qword ptr [RAX + 0x8],R14
JZ 0x00103e9e
INC EBX
TEST ESI,ESI
JZ 0x00103e9e
MOV qword ptr [RAX + 0x8],R14
LAB_00103e9e:
LEA RAX,[0x208140]
CMP R14,RAX
SETC CL
ADD RAX,0x4000000
CMP R14,RAX
SETNC AL
OR AL,CL
MOVZX EAX,AL
ADD EBX,EAX
LAB_00103ebe:
MOV EAX,EBX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
char verify_segment_integrity(int *param_1,int param_2)
{
uint uVar1;
long lVar2;
int iVar3;
int *piVar4;
char cVar5;
int *piVar6;
if (param_1 == (int *)0x0) {
cVar5 = '\0';
}
else {
cVar5 = '\0';
if ((param_1[10] != -0x35014502) && (cVar5 = '\x01', param_2 != 0)) {
param_1[10] = -0x35014502;
}
if ((((param_1[1] - 0x4001U < 0xffffc000) && (cVar5 = cVar5 + '\x01', param_2 != 0)) &&
(*(long *)(param_1 + 2) != 0)) &&
(iVar3 = (int)((ulong)(*(long *)(param_1 + 2) - (long)param_1) >> 0xc), iVar3 - 1U < 0x4000))
{
param_1[1] = iVar3;
}
if (1 < integrity_check_level) {
piVar6 = (int *)((long)param_1 + 0x3fU & 0xfffffffffffffff0);
piVar4 = (int *)0x0;
if (param_1 + 0xf <= piVar6) {
piVar4 = param_1 + 0xc;
}
if (piVar4 == (int *)0x0) {
if (param_2 == 0) {
piVar4 = (int *)0x0;
}
else {
initialize_segment_integrity(param_1);
piVar4 = param_1 + 0xc;
if (piVar6 < param_1 + 0xf) {
piVar4 = (int *)0x0;
}
}
if (piVar4 == (int *)0x0) {
return cVar5;
}
}
if ((*piVar4 != -0x1120532) && (cVar5 = cVar5 + '\x01', param_2 != 0)) {
*piVar4 = -0x1120532;
}
iVar3 = calculate_segment_checksum(param_1);
if ((piVar4[1] != iVar3) && (cVar5 = cVar5 + '\x01', param_2 != 0)) {
piVar4[1] = iVar3;
}
if (2 < integrity_check_level) {
uVar1 = param_1[1];
if (uVar1 - 0x4001 < 0xffffc000) {
piVar4 = (int *)0x0;
}
else {
piVar4 = param_1 + (ulong)uVar1 * 0x400 + -1;
if (param_1 + (ulong)uVar1 * 0x400 + -1 <= param_1) {
piVar4 = (int *)0x0;
}
if (param_1 + (ulong)uVar1 * 0x400 < (int *)0x4) {
piVar4 = (int *)0x0;
}
}
if (((piVar4 != (int *)0x0) && (*piVar4 != -0x21523f22)) &&
(cVar5 = cVar5 + '\x01', param_2 != 0)) {
*piVar4 = -0x21523f22;
}
lVar2 = *(long *)(param_1 + 2);
if (((lVar2 != 0) && (*(int **)(lVar2 + 0x10) != param_1)) &&
(cVar5 = cVar5 + '\x01', param_2 != 0)) {
*(int **)(lVar2 + 0x10) = param_1;
}
lVar2 = *(long *)(param_1 + 4);
if (((lVar2 != 0) && (*(int **)(lVar2 + 8) != param_1)) &&
(cVar5 = cVar5 + '\x01', param_2 != 0)) {
*(int **)(lVar2 + 8) = param_1;
}
cVar5 = cVar5 + (memory + 0x3ffffff < param_1 || param_1 < memory);
}
}
}
return cVar5;
}
|
|
19,916
|
nglog::LogMessage::SaveOrSendToLog()
|
ng-log[P]ng-log/src/logging.cc
|
EXCLUSIVE_LOCKS_REQUIRED(log_mutex) {
if (data_->outvec_ != nullptr) {
RAW_DCHECK(data_->num_chars_to_log_ > 0 &&
data_->message_text_[data_->num_chars_to_log_ - 1] == '\n',
"");
// Omit prefix of message and trailing newline when recording in outvec_.
const char* start = data_->message_text_ + data_->num_prefix_chars_;
size_t len = data_->num_chars_to_log_ - data_->num_prefix_chars_ - 1;
data_->outvec_->push_back(string(start, len));
} else {
SendToLog();
}
}
|
O0
|
cpp
|
nglog::LogMessage::SaveOrSendToLog():
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x58(%rbp)
movq 0x8(%rax), %rax
cmpq $0x0, 0x76b0(%rax)
je 0x10ff9
jmp 0x10ecb
movq -0x58(%rbp), %rax
movq 0x8(%rax), %rax
cmpq $0x0, 0x76c0(%rax)
jbe 0x10efe
movq -0x58(%rbp), %rcx
movq 0x8(%rcx), %rax
movq 0x8(%rcx), %rcx
movq 0x76c0(%rcx), %rcx
subq $0x1, %rcx
movsbl 0x4(%rax,%rcx), %eax
cmpl $0xa, %eax
je 0x10f2f
jmp 0x10f00
movl $0x3, %edi
leaq 0x3d81e(%rip), %rsi # 0x4e72a
movl $0x77e, %edx # imm = 0x77E
leaq 0x3d859(%rip), %rcx # 0x4e771
leaq 0x3d866(%rip), %r8 # 0x4e785
leaq 0x3dd81(%rip), %r9 # 0x4eca7
movb $0x0, %al
callq 0x48db0
jmp 0x10f2f
jmp 0x10f31
movq -0x58(%rbp), %rax
movq 0x8(%rax), %rcx
movq 0x76b8(%rcx), %rdx
leaq 0x4(%rcx,%rdx), %rcx
movq %rcx, -0x10(%rbp)
movq 0x8(%rax), %rdx
movq 0x76b8(%rdx), %rcx
movq 0x76c0(%rdx), %rdx
notq %rcx
addq %rdx, %rcx
movq %rcx, -0x18(%rbp)
movq 0x8(%rax), %rax
movq 0x76b0(%rax), %rax
movq %rax, -0x78(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x68(%rbp)
leaq -0x39(%rbp), %rdi
movq %rdi, -0x60(%rbp)
callq 0x9cd0
movq -0x70(%rbp), %rsi
movq -0x68(%rbp), %rdx
movq -0x60(%rbp), %rcx
leaq -0x38(%rbp), %rdi
callq 0x9810
jmp 0x10fa8
movq -0x78(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x1a280
jmp 0x10fb7
leaq -0x38(%rbp), %rdi
callq 0x9e68
leaq -0x39(%rbp), %rdi
callq 0x9780
jmp 0x11002
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x10fee
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x38(%rbp), %rdi
callq 0x9e68
leaq -0x39(%rbp), %rdi
callq 0x9780
jmp 0x1100b
movq -0x58(%rbp), %rdi
callq 0x106c0
addq $0x80, %rsp
popq %rbp
retq
movq -0x48(%rbp), %rdi
callq 0x9cc0
nopw %cs:(%rax,%rax)
|
_ZN5nglog10LogMessage15SaveOrSendToLogEv:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov [rbp+var_58], rax
mov rax, [rax+8]
cmp qword ptr [rax+76B0h], 0
jz loc_10FF9
jmp short $+2
loc_10ECB:
mov rax, [rbp+var_58]
mov rax, [rax+8]
cmp qword ptr [rax+76C0h], 0
jbe short loc_10EFE
mov rcx, [rbp+var_58]
mov rax, [rcx+8]
mov rcx, [rcx+8]
mov rcx, [rcx+76C0h]
sub rcx, 1
movsx eax, byte ptr [rax+rcx+4]
cmp eax, 0Ah
jz short loc_10F2F
loc_10EFE:
jmp short $+2
loc_10F00:
mov edi, 3
lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
mov edx, 77Eh
lea rcx, aCheckSFailedS; "Check %s failed: %s"
lea r8, aDataNumCharsTo; "data_->num_chars_to_log_ > 0 && data_->"...
lea r9, asc_4ECA5+2; ""
mov al, 0
call _ZN5nglog6RawLogENS_11LogSeverityEPKciS2_z; nglog::RawLog(nglog::LogSeverity,char const*,int,char const*,...)
jmp short $+2
loc_10F2F:
jmp short $+2
loc_10F31:
mov rax, [rbp+var_58]
mov rcx, [rax+8]
mov rdx, [rcx+76B8h]
lea rcx, [rcx+rdx+4]
mov [rbp+var_10], rcx
mov rdx, [rax+8]
mov rcx, [rdx+76B8h]
mov rdx, [rdx+76C0h]
not rcx
add rcx, rdx
mov [rbp+var_18], rcx
mov rax, [rax+8]
mov rax, [rax+76B0h]
mov [rbp+var_78], rax
mov rax, [rbp+var_10]
mov [rbp+var_70], rax
mov rax, [rbp+var_18]
mov [rbp+var_68], rax
lea rdi, [rbp+var_39]
mov [rbp+var_60], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rsi, [rbp+var_70]
mov rdx, [rbp+var_68]
mov rcx, [rbp+var_60]
lea rdi, [rbp+var_38]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EPKcmRKS3_; std::string::basic_string(char const*,ulong,std::allocator<char> const&)
jmp short $+2
loc_10FA8:
mov rdi, [rbp+var_78]
lea rsi, [rbp+var_38]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE9push_backEOS5_; std::vector<std::string>::push_back(std::string&&)
jmp short $+2
loc_10FB7:
lea rdi, [rbp+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rbp+var_39]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_11002
mov rcx, rax
mov eax, edx
mov [rbp+var_48], rcx
mov [rbp+var_4C], eax
jmp short loc_10FEE
mov rcx, rax
mov eax, edx
mov [rbp+var_48], rcx
mov [rbp+var_4C], eax
lea rdi, [rbp+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_10FEE:
lea rdi, [rbp+var_39]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_1100B
loc_10FF9:
mov rdi, [rbp+var_58]; this
call _ZN5nglog10LogMessage9SendToLogEv; nglog::LogMessage::SendToLog(void)
loc_11002:
add rsp, 80h
pop rbp
retn
loc_1100B:
mov rdi, [rbp+var_48]
call __Unwind_Resume
|
nglog::LogDestination * nglog::LogMessage::SaveOrSendToLog(nglog::LogMessage *this)
{
long long v2; // [rsp+8h] [rbp-78h]
long long v3; // [rsp+10h] [rbp-70h]
long long v4; // [rsp+18h] [rbp-68h]
char v5; // [rsp+47h] [rbp-39h] BYREF
_BYTE v6[32]; // [rsp+48h] [rbp-38h] BYREF
long long v7; // [rsp+68h] [rbp-18h]
long long v8; // [rsp+70h] [rbp-10h]
nglog::LogMessage *v9; // [rsp+78h] [rbp-8h]
v9 = this;
if ( !*(_QWORD *)(*((_QWORD *)this + 1) + 30384LL) )
return nglog::LogMessage::SendToLog(this);
if ( !*(_QWORD *)(*((_QWORD *)this + 1) + 30400LL)
|| *(_BYTE *)(*((_QWORD *)this + 1) + *(_QWORD *)(*((_QWORD *)this + 1) + 30400LL) - 1LL + 4) != 10 )
{
nglog::RawLog(
3,
(unsigned int)"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",
1918,
(unsigned int)"Check %s failed: %s",
(unsigned int)"data_->num_chars_to_log_ > 0 && data_->message_text_[data_->num_chars_to_log_ - 1] == '\\n'",
(unsigned int)"");
}
v8 = *((_QWORD *)this + 1) + *(_QWORD *)(*((_QWORD *)this + 1) + 30392LL) + 4LL;
v7 = *(_QWORD *)(*((_QWORD *)this + 1) + 30400LL) + ~*(_QWORD *)(*((_QWORD *)this + 1) + 30392LL);
v2 = *(_QWORD *)(*((_QWORD *)this + 1) + 30384LL);
v3 = v8;
v4 = v7;
std::allocator<char>::allocator();
std::string::basic_string(v6, v3, v4, &v5);
std::vector<std::string>::push_back(v2, v6);
std::string::~string(v6);
return (nglog::LogDestination *)std::allocator<char>::~allocator(&v5);
}
|
SaveOrSendToLog:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RAX + 0x8]
CMP qword ptr [RAX + 0x76b0],0x0
JZ 0x00110ff9
JMP 0x00110ecb
LAB_00110ecb:
MOV RAX,qword ptr [RBP + -0x58]
MOV RAX,qword ptr [RAX + 0x8]
CMP qword ptr [RAX + 0x76c0],0x0
JBE 0x00110efe
MOV RCX,qword ptr [RBP + -0x58]
MOV RAX,qword ptr [RCX + 0x8]
MOV RCX,qword ptr [RCX + 0x8]
MOV RCX,qword ptr [RCX + 0x76c0]
SUB RCX,0x1
MOVSX EAX,byte ptr [RAX + RCX*0x1 + 0x4]
CMP EAX,0xa
JZ 0x00110f2f
LAB_00110efe:
JMP 0x00110f00
LAB_00110f00:
MOV EDI,0x3
LEA RSI,[0x14e72a]
MOV EDX,0x77e
LEA RCX,[0x14e771]
LEA R8,[0x14e785]
LEA R9,[0x14eca7]
MOV AL,0x0
CALL 0x00148db0
JMP 0x00110f2f
LAB_00110f2f:
JMP 0x00110f31
LAB_00110f31:
MOV RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RAX + 0x8]
MOV RDX,qword ptr [RCX + 0x76b8]
LEA RCX,[RCX + RDX*0x1 + 0x4]
MOV qword ptr [RBP + -0x10],RCX
MOV RDX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RDX + 0x76b8]
MOV RDX,qword ptr [RDX + 0x76c0]
NOT RCX
ADD RCX,RDX
MOV qword ptr [RBP + -0x18],RCX
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX + 0x76b0]
MOV qword ptr [RBP + -0x78],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x70],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x68],RAX
LEA RDI,[RBP + -0x39]
MOV qword ptr [RBP + -0x60],RDI
CALL 0x00109cd0
MOV RSI,qword ptr [RBP + -0x70]
MOV RDX,qword ptr [RBP + -0x68]
MOV RCX,qword ptr [RBP + -0x60]
LAB_00110f9d:
LEA RDI,[RBP + -0x38]
CALL 0x00109810
JMP 0x00110fa8
LAB_00110fa8:
MOV RDI,qword ptr [RBP + -0x78]
LEA RSI,[RBP + -0x38]
CALL 0x0011a280
LAB_00110fb5:
JMP 0x00110fb7
LAB_00110fb7:
LEA RDI,[RBP + -0x38]
CALL 0x00109e68
LEA RDI,[RBP + -0x39]
CALL 0x00109780
JMP 0x00111002
LAB_00110ff9:
MOV RDI,qword ptr [RBP + -0x58]
CALL 0x001106c0
LAB_00111002:
ADD RSP,0x80
POP RBP
RET
|
/* nglog::LogMessage::SaveOrSendToLog() */
void __thiscall nglog::LogMessage::SaveOrSendToLog(LogMessage *this)
{
char *pcVar1;
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *this_00;
ulong uVar2;
allocator local_41;
string local_40 [32];
ulong local_20;
char *local_18;
LogMessage *local_10;
local_10 = this;
if (*(long *)(*(long *)(this + 8) + 0x76b0) == 0) {
SendToLog(this);
}
else {
if ((*(long *)(*(long *)(this + 8) + 0x76c0) == 0) ||
(*(char *)(*(long *)(this + 8) + *(long *)(*(long *)(this + 8) + 0x76c0) + 3) != '\n')) {
RawLog(3,"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",0x77e,
"Check %s failed: %s",
"data_->num_chars_to_log_ > 0 && data_->message_text_[data_->num_chars_to_log_ - 1] == \'\\n\'"
,&DAT_0014eca7);
}
pcVar1 = (char *)(*(long *)(this + 8) + 4 + *(long *)(*(long *)(this + 8) + 0x76b8));
uVar2 = ~*(ulong *)(*(long *)(this + 8) + 0x76b8) + *(long *)(*(long *)(this + 8) + 0x76c0);
this_00 = *(vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> **)
(*(long *)(this + 8) + 0x76b0);
local_20 = uVar2;
local_18 = pcVar1;
std::allocator<char>::allocator();
/* try { // try from 00110f9d to 00110fa5 has its CatchHandler @ 00110fcb */
std::__cxx11::string::string(local_40,pcVar1,uVar2,&local_41);
/* try { // try from 00110fa8 to 00110fb4 has its CatchHandler @ 00110fd9 */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::push_back
(this_00,local_40);
std::__cxx11::string::~string(local_40);
std::allocator<char>::~allocator((allocator<char> *)&local_41);
}
return;
}
|
|
19,917
|
nglog::LogMessage::SaveOrSendToLog()
|
ng-log[P]ng-log/src/logging.cc
|
EXCLUSIVE_LOCKS_REQUIRED(log_mutex) {
if (data_->outvec_ != nullptr) {
RAW_DCHECK(data_->num_chars_to_log_ > 0 &&
data_->message_text_[data_->num_chars_to_log_ - 1] == '\n',
"");
// Omit prefix of message and trailing newline when recording in outvec_.
const char* start = data_->message_text_ + data_->num_prefix_chars_;
size_t len = data_->num_chars_to_log_ - data_->num_prefix_chars_ - 1;
data_->outvec_->push_back(string(start, len));
} else {
SendToLog();
}
}
|
O1
|
cpp
|
nglog::LogMessage::SaveOrSendToLog():
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
movq 0x8(%rdi), %rax
cmpq $0x0, 0x76b0(%rax)
je 0xac45
movq 0x76c0(%rax), %rcx
testq %rcx, %rcx
je 0xabaf
cmpb $0xa, 0x3(%rcx,%rax)
je 0xabdc
leaq 0x17a5c(%rip), %rsi # 0x22612
leaq 0x17a9c(%rip), %rcx # 0x22659
leaq 0x17aa9(%rip), %r8 # 0x2266d
leaq 0x17fbb(%rip), %r9 # 0x22b86
movl $0x3, %edi
movl $0x77e, %edx # imm = 0x77E
xorl %eax, %eax
callq 0x1f648
movq 0x8(%rbx), %rax
movq 0x76b0(%rax), %rbx
movq 0x76b8(%rax), %rcx
leaq (%rax,%rcx), %rsi
addq $0x4, %rsi
notq %rcx
movq 0x76c0(%rax), %rdx
addq %rsi, %rdx
addq %rcx, %rdx
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
movq %rsp, %r14
movq %r14, %rdi
callq 0x9902
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1f3c8
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0xac3b
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x8fcc
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rbx, %rdi
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
jmp 0xa4ae
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0xac6f
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x8fcc
movq %rbx, %rdi
callq 0x7930
nop
|
_ZN5nglog10LogMessage15SaveOrSendToLogEv:
push r15
push r14
push rbx
sub rsp, 20h
mov rbx, rdi
mov rax, [rdi+8]
cmp qword ptr [rax+76B0h], 0
jz loc_AC45
mov rcx, [rax+76C0h]
test rcx, rcx
jz short loc_ABAF
cmp byte ptr [rcx+rax+3], 0Ah
jz short loc_ABDC
loc_ABAF:
lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aCheckSFailedS; "Check %s failed: %s"
lea r8, aDataNumCharsTo; "data_->num_chars_to_log_ > 0 && data_->"...
lea r9, asc_22B84+2; ""
mov edi, 3
mov edx, 77Eh
xor eax, eax
call _ZN5nglog6RawLogENS_11LogSeverityEPKciS2_z; nglog::RawLog(nglog::LogSeverity,char const*,int,char const*,...)
loc_ABDC:
mov rax, [rbx+8]
mov rbx, [rax+76B0h]
mov rcx, [rax+76B8h]
lea rsi, [rax+rcx]
add rsi, 4
not rcx
mov rdx, [rax+76C0h]
add rdx, rsi
add rdx, rcx
lea r15, [rsp+38h+var_28]
mov [r15-10h], r15
mov r14, rsp
mov rdi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rdi, rbx
mov rsi, r14
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&)
mov rdi, [rsp+38h+var_38]; void *
cmp rdi, r15
jz short loc_AC3B
mov rsi, [rsp+38h+var_28]
inc rsi; unsigned __int64
call _ZdlPvm; operator delete(void *,ulong)
loc_AC3B:
add rsp, 20h
pop rbx
pop r14
pop r15
retn
loc_AC45:
mov rdi, rbx; this
add rsp, 20h
pop rbx
pop r14
pop r15
jmp _ZN5nglog10LogMessage9SendToLogEv; nglog::LogMessage::SendToLog(void)
mov rbx, rax
mov rdi, [rsp+0]; void *
cmp rdi, r15
jz short loc_AC6F
mov rsi, [rsp+arg_8]
inc rsi; unsigned __int64
call _ZdlPvm; operator delete(void *,ulong)
loc_AC6F:
mov rdi, rbx
call __Unwind_Resume
|
void nglog::LogMessage::SaveOrSendToLog(nglog::LogMessage *this)
{
long long v1; // rax
long long v2; // rcx
_QWORD *v3; // rax
long long v4; // rbx
long long v5; // rcx
_BYTE *v6; // rsi
long long v7; // rdx
void *v8[2]; // [rsp+0h] [rbp-38h] BYREF
_QWORD v9[5]; // [rsp+10h] [rbp-28h] BYREF
v1 = *((_QWORD *)this + 1);
if ( *(_QWORD *)(v1 + 30384) )
{
v2 = *(_QWORD *)(v1 + 30400);
if ( !v2 || *(_BYTE *)(v2 + v1 + 3) != 10 )
nglog::RawLog(
3,
(unsigned int)"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",
1918,
(unsigned int)"Check %s failed: %s",
(unsigned int)"data_->num_chars_to_log_ > 0 && data_->message_text_[data_->num_chars_to_log_ - 1] == '\\n'",
(unsigned int)"",
(char)v8[0]);
v3 = (_QWORD *)*((_QWORD *)this + 1);
v4 = v3[3798];
v5 = v3[3799];
v6 = (char *)v3 + v5 + 4;
v7 = (long long)&v6[v3[3800] + ~v5];
v8[0] = v9;
std::string::_M_construct<char const*>(v8, v6, v7);
std::vector<std::string>::emplace_back<std::string>(v4, v8);
if ( v8[0] != v9 )
operator delete(v8[0]);
}
else
{
nglog::LogMessage::SendToLog(this);
}
}
|
SaveOrSendToLog:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x20
MOV RBX,RDI
MOV RAX,qword ptr [RDI + 0x8]
CMP qword ptr [RAX + 0x76b0],0x0
JZ 0x0010ac45
MOV RCX,qword ptr [RAX + 0x76c0]
TEST RCX,RCX
JZ 0x0010abaf
CMP byte ptr [RCX + RAX*0x1 + 0x3],0xa
JZ 0x0010abdc
LAB_0010abaf:
LEA RSI,[0x122612]
LEA RCX,[0x122659]
LEA R8,[0x12266d]
LEA R9,[0x122b86]
MOV EDI,0x3
MOV EDX,0x77e
XOR EAX,EAX
CALL 0x0011f648
LAB_0010abdc:
MOV RAX,qword ptr [RBX + 0x8]
MOV RBX,qword ptr [RAX + 0x76b0]
MOV RCX,qword ptr [RAX + 0x76b8]
LEA RSI,[RAX + RCX*0x1]
ADD RSI,0x4
NOT RCX
MOV RDX,qword ptr [RAX + 0x76c0]
ADD RDX,RSI
ADD RDX,RCX
LEA R15,[RSP + 0x10]
MOV qword ptr [R15 + -0x10],R15
MOV R14,RSP
MOV RDI,R14
CALL 0x00109902
LAB_0010ac1a:
MOV RDI,RBX
MOV RSI,R14
CALL 0x0011f3c8
LAB_0010ac25:
MOV RDI,qword ptr [RSP]
CMP RDI,R15
JZ 0x0010ac3b
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x00108fcc
LAB_0010ac3b:
ADD RSP,0x20
POP RBX
POP R14
POP R15
RET
LAB_0010ac45:
MOV RDI,RBX
ADD RSP,0x20
POP RBX
POP R14
POP R15
JMP 0x0010a4ae
|
/* nglog::LogMessage::SaveOrSendToLog() */
void __thiscall nglog::LogMessage::SaveOrSendToLog(LogMessage *this)
{
long lVar1;
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *this_00;
long lVar2;
long *local_38 [2];
long local_28 [2];
lVar1 = *(long *)(this + 8);
if (*(long *)(lVar1 + 0x76b0) != 0) {
if ((*(long *)(lVar1 + 0x76c0) == 0) ||
(*(char *)(*(long *)(lVar1 + 0x76c0) + 3 + lVar1) != '\n')) {
RawLog(3,"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/logging.cc",0x77e,
"Check %s failed: %s",
"data_->num_chars_to_log_ > 0 && data_->message_text_[data_->num_chars_to_log_ - 1] == \'\\n\'"
,&DAT_00122b86);
}
lVar1 = *(long *)(this + 8);
this_00 = *(vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> **)
(lVar1 + 0x76b0);
lVar2 = lVar1 + *(ulong *)(lVar1 + 0x76b8) + 4;
local_38[0] = local_28;
std::__cxx11::string::_M_construct<char_const*>
(local_38,lVar2,*(long *)(lVar1 + 0x76c0) + lVar2 + ~*(ulong *)(lVar1 + 0x76b8));
/* try { // try from 0010ac1a to 0010ac24 has its CatchHandler @ 0010ac56 */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<std::__cxx11::string>(this_00,(string *)local_38);
if (local_38[0] != local_28) {
operator_delete(local_38[0],local_28[0] + 1);
}
return;
}
SendToLog(this);
return;
}
|
|
19,918
|
uf_varchar1
|
eloqsql/storage/myisam/mi_packrec.c
|
static void uf_varchar1(MI_COLUMNDEF *rec, MI_BIT_BUFF *bit_buff,
uchar *to, uchar *end __attribute__((unused)))
{
if (get_bit(bit_buff))
to[0]= 0; /* Zero lengths */
else
{
ulong length=get_bits(bit_buff,rec->space_length_bits);
*to= (uchar) length;
decode_bytes(rec,bit_buff,to+1,to+1+length);
}
}
|
O0
|
c
|
uf_varchar1:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x0, 0x4(%rax)
je 0xc0b67
movq -0x10(%rbp), %rax
movl (%rax), %eax
movq -0x10(%rbp), %rdx
movl 0x4(%rdx), %ecx
addl $-0x1, %ecx
movl %ecx, 0x4(%rdx)
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
jne 0xc0b8b
jmp 0xc0b97
movq -0x10(%rbp), %rdi
callq 0xbf250
movq -0x10(%rbp), %rax
movl $0x1f, 0x4(%rax)
movq -0x10(%rbp), %rax
movl (%rax), %eax
andl $0x80000000, %eax # imm = 0x80000000
cmpl $0x0, %eax
je 0xc0b97
movq -0x18(%rbp), %rax
movb $0x0, (%rax)
jmp 0xc0c23
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movq -0x8(%rbp), %rcx
cmpl 0x1c(%rcx), %eax
jb 0xc0bda
movq -0x10(%rbp), %rax
movl (%rax), %eax
movq -0x8(%rbp), %rcx
movl 0x1c(%rcx), %esi
movq -0x10(%rbp), %rdx
movl 0x4(%rdx), %ecx
subl %esi, %ecx
movl %ecx, 0x4(%rdx)
shrl %cl, %eax
movq -0x8(%rbp), %rcx
movl 0x1c(%rcx), %ecx
movl %ecx, %edx
leaq 0x209dee(%rip), %rcx # 0x2ca9c0
andl (%rcx,%rdx,4), %eax
movl %eax, -0x2c(%rbp)
jmp 0xc0bed
movq -0x10(%rbp), %rdi
movq -0x8(%rbp), %rax
movl 0x1c(%rax), %esi
callq 0xbda00
movl %eax, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movl %eax, %eax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movb %al, %cl
movq -0x18(%rbp), %rax
movb %cl, (%rax)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
addq $0x1, %rdx
movq -0x18(%rbp), %rcx
addq $0x1, %rcx
addq -0x28(%rbp), %rcx
callq 0xbf960
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
|
uf_varchar1_0:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rax, [rbp+var_10]
cmp dword ptr [rax+4], 0
jz short loc_C0B67
mov rax, [rbp+var_10]
mov eax, [rax]
mov rdx, [rbp+var_10]
mov ecx, [rdx+4]
add ecx, 0FFFFFFFFh
mov [rdx+4], ecx
mov edx, 1
shl edx, cl
mov ecx, edx
and eax, ecx
cmp eax, 0
jnz short loc_C0B8B
jmp short loc_C0B97
loc_C0B67:
mov rdi, [rbp+var_10]
call fill_buffer_0
mov rax, [rbp+var_10]
mov dword ptr [rax+4], 1Fh
mov rax, [rbp+var_10]
mov eax, [rax]
and eax, 80000000h
cmp eax, 0
jz short loc_C0B97
loc_C0B8B:
mov rax, [rbp+var_18]
mov byte ptr [rax], 0
jmp loc_C0C23
loc_C0B97:
mov rax, [rbp+var_10]
mov eax, [rax+4]
mov rcx, [rbp+var_8]
cmp eax, [rcx+1Ch]
jb short loc_C0BDA
mov rax, [rbp+var_10]
mov eax, [rax]
mov rcx, [rbp+var_8]
mov esi, [rcx+1Ch]
mov rdx, [rbp+var_10]
mov ecx, [rdx+4]
sub ecx, esi
mov [rdx+4], ecx
shr eax, cl
mov rcx, [rbp+var_8]
mov ecx, [rcx+1Ch]
mov edx, ecx
lea rcx, mask_0
and eax, [rcx+rdx*4]
mov [rbp+var_2C], eax
jmp short loc_C0BED
loc_C0BDA:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_8]
mov esi, [rax+1Ch]
call fill_and_get_bits_0
mov [rbp+var_2C], eax
loc_C0BED:
mov eax, [rbp+var_2C]
mov eax, eax
mov [rbp+var_28], rax
mov rax, [rbp+var_28]
mov cl, al
mov rax, [rbp+var_18]
mov [rax], cl
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
add rdx, 1
mov rcx, [rbp+var_18]
add rcx, 1
add rcx, [rbp+var_28]
call decode_bytes_0
loc_C0C23:
add rsp, 30h
pop rbp
retn
|
long long uf_varchar1_0(long long a1, int *a2, _BYTE *a3)
{
int v3; // eax
int v4; // ecx
long long result; // rax
unsigned int v6; // eax
int v7; // ecx
int bits_0; // [rsp+4h] [rbp-2Ch]
if ( a2[1] )
{
v3 = *a2;
v4 = a2[1] - 1;
a2[1] = v4;
if ( ((1 << v4) & v3) == 0 )
goto LABEL_6;
LABEL_5:
result = (long long)a3;
*a3 = 0;
return result;
}
fill_buffer_0((long long)a2);
a2[1] = 31;
if ( *a2 < 0 )
goto LABEL_5;
LABEL_6:
if ( (unsigned int)a2[1] < *(_DWORD *)(a1 + 28) )
{
bits_0 = fill_and_get_bits_0(a2, *(_DWORD *)(a1 + 28));
}
else
{
v6 = *a2;
v7 = a2[1] - *(_DWORD *)(a1 + 28);
a2[1] = v7;
bits_0 = mask_0[*(unsigned int *)(a1 + 28)] & (v6 >> v7);
}
*a3 = bits_0;
return decode_bytes_0(a1, (long long)a2, a3 + 1, &a3[bits_0 + 1]);
}
|
uf_varchar1:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x4],0x0
JZ 0x001c0b67
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX]
MOV RDX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RDX + 0x4]
ADD ECX,-0x1
MOV dword ptr [RDX + 0x4],ECX
MOV EDX,0x1
SHL EDX,CL
MOV ECX,EDX
AND EAX,ECX
CMP EAX,0x0
JNZ 0x001c0b8b
JMP 0x001c0b97
LAB_001c0b67:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001bf250
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x4],0x1f
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX]
AND EAX,0x80000000
CMP EAX,0x0
JZ 0x001c0b97
LAB_001c0b8b:
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX],0x0
JMP 0x001c0c23
LAB_001c0b97:
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x4]
MOV RCX,qword ptr [RBP + -0x8]
CMP EAX,dword ptr [RCX + 0x1c]
JC 0x001c0bda
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX]
MOV RCX,qword ptr [RBP + -0x8]
MOV ESI,dword ptr [RCX + 0x1c]
MOV RDX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RDX + 0x4]
SUB ECX,ESI
MOV dword ptr [RDX + 0x4],ECX
SHR EAX,CL
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x1c]
MOV EDX,ECX
LEA RCX,[0x3ca9c0]
AND EAX,dword ptr [RCX + RDX*0x4]
MOV dword ptr [RBP + -0x2c],EAX
JMP 0x001c0bed
LAB_001c0bda:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV ESI,dword ptr [RAX + 0x1c]
CALL 0x001bda00
MOV dword ptr [RBP + -0x2c],EAX
LAB_001c0bed:
MOV EAX,dword ptr [RBP + -0x2c]
MOV EAX,EAX
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX],CL
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
ADD RDX,0x1
MOV RCX,qword ptr [RBP + -0x18]
ADD RCX,0x1
ADD RCX,qword ptr [RBP + -0x28]
CALL 0x001bf960
LAB_001c0c23:
ADD RSP,0x30
POP RBP
RET
|
void uf_varchar1(long param_1,uint *param_2,int1 *param_3)
{
uint uVar1;
uint local_34;
if (param_2[1] == 0) {
fill_buffer(param_2);
param_2[1] = 0x1f;
uVar1 = *param_2 & 0x80000000;
}
else {
uVar1 = param_2[1];
param_2[1] = uVar1 - 1;
uVar1 = *param_2 & 1 << ((byte)(uVar1 - 1) & 0x1f);
}
if (uVar1 == 0) {
if (param_2[1] < *(uint *)(param_1 + 0x1c)) {
local_34 = fill_and_get_bits(param_2,*(int4 *)(param_1 + 0x1c));
}
else {
uVar1 = param_2[1] - *(int *)(param_1 + 0x1c);
param_2[1] = uVar1;
local_34 = *param_2 >> ((byte)uVar1 & 0x1f) &
*(uint *)(mask + (ulong)*(uint *)(param_1 + 0x1c) * 4);
}
*param_3 = (char)local_34;
decode_bytes(param_1,param_2,param_3 + 1,param_3 + (ulong)local_34 + 1);
}
else {
*param_3 = 0;
}
return;
}
|
|
19,919
|
maria_delete_all_rows
|
eloqsql/storage/maria/ma_delete_all.c
|
int maria_delete_all_rows(MARIA_HA *info)
{
MARIA_SHARE *share= info->s;
my_bool log_record;
LSN lsn;
#ifdef HAVE_MMAP
my_bool mmap_file= share->file_map != 0;
#endif
DBUG_ENTER("maria_delete_all_rows");
if (share->options & HA_OPTION_READ_ONLY_DATA)
{
DBUG_RETURN(my_errno=EACCES);
}
/**
@todo LOCK take X-lock on table here.
When we have versioning, if some other thread is looking at this table,
we cannot shrink the file like this.
*/
if (_ma_readinfo(info,F_WRLCK,1))
DBUG_RETURN(my_errno);
log_record= share->now_transactional && !share->temporary;
if (log_record)
{
/*
This record will be used by Recovery to finish the deletion if it
crashed. We force it to have a complete history in the log.
*/
LEX_CUSTRING log_array[TRANSLOG_INTERNAL_PARTS + 1];
uchar log_data[FILEID_STORE_SIZE];
log_array[TRANSLOG_INTERNAL_PARTS + 0].str= log_data;
log_array[TRANSLOG_INTERNAL_PARTS + 0].length= sizeof(log_data);
if (unlikely(translog_write_record(&lsn, LOGREC_REDO_DELETE_ALL,
info->trn, info, 0,
sizeof(log_array)/sizeof(log_array[0]),
log_array, log_data, NULL) ||
translog_flush(lsn)))
goto err;
/*
If we fail in this function after this point, log and table will be
inconsistent.
*/
if (_ma_mark_file_changed(share))
goto err;
}
else
{
if (_ma_mark_file_changed(share))
goto err;
/* Other branch called function below when writing log record, in hook */
_ma_reset_status(info);
}
/* Remove old history as the table is now empty for everyone */
_ma_reset_state(info);
share->state.changed= 0;
/*
If we are using delayed keys or if the user has done changes to the tables
since it was locked then there may be key blocks in the page cache. Or
there may be data blocks there. We need to throw them away or they may
re-enter the emptied table or another table later.
*/
#ifdef HAVE_MMAP
if (mmap_file)
_ma_unmap_file(info);
#endif
if (_ma_flush_table_files(info, MARIA_FLUSH_DATA|MARIA_FLUSH_INDEX,
FLUSH_IGNORE_CHANGED, FLUSH_IGNORE_CHANGED) ||
mysql_file_chsize(info->dfile.file, 0, 0, MYF(MY_WME)) ||
mysql_file_chsize(share->kfile.file, share->base.keystart, 0, MYF(MY_WME)))
goto err;
if (_ma_initialize_data_file(share, info->dfile.file))
goto err;
if (log_record)
{
/*
Because LOGREC_REDO_DELETE_ALL does not operate on pages, it has the
following problem:
delete_all; inserts (redo_insert); all pages get flushed; checkpoint:
the dirty pages list will be empty. In recovery, delete_all is executed,
but redo_insert are skipped (dirty pages list is empty).
To avoid this, we need to set skip_redo_lsn now, and thus need to sync
files.
Also fixes the problem of:
bulk insert; insert; delete_all; crash:
"bulk insert" is skipped (no REDOs), so if "insert" would not be skipped
(if we didn't update skip_redo_lsn below) then "insert" would be tried
and fail, saying that it sees that the first page has to be created
though the inserted row has rownr>0.
*/
my_bool error= _ma_state_info_write(share,
MA_STATE_INFO_WRITE_DONT_MOVE_OFFSET |
MA_STATE_INFO_WRITE_LOCK) ||
_ma_update_state_lsns(share, lsn, info->trn->trid, FALSE, FALSE) ||
_ma_sync_table_files(info);
info->trn->rec_lsn= LSN_IMPOSSIBLE;
if (error)
goto err;
}
if (info->opt_flag & WRITE_CACHE_USED)
reinit_io_cache(&info->rec_cache, WRITE_CACHE, 0, 1, 1);
_ma_writeinfo(info, WRITEINFO_UPDATE_KEYFILE);
#ifdef HAVE_MMAP
/* Map again */
if (mmap_file)
_ma_dynmap_file(info, (my_off_t) 0);
#endif
DBUG_RETURN(0);
err:
{
int save_errno=my_errno;
_ma_writeinfo(info, WRITEINFO_UPDATE_KEYFILE);
info->update|=HA_STATE_WRITTEN; /* Buffer changed */
DBUG_RETURN(my_errno=save_errno);
}
}
|
O0
|
c
|
maria_delete_all_rows:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x5f0(%rax)
setne %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x29(%rbp)
movq -0x18(%rbp), %rax
movq 0x720(%rax), %rax
andq $0x10000, %rax # imm = 0x10000
cmpq $0x0, %rax
je 0x762b1
jmp 0x7629a
callq 0xf6080
movl $0xd, (%rax)
movl $0xd, -0x4(%rbp)
jmp 0x765c0
movq -0x10(%rbp), %rdi
movl $0x1, %edx
movl %edx, %esi
callq 0x48c90
cmpl $0x0, %eax
je 0x762d7
jmp 0x762c8
callq 0xf6080
movl (%rax), %eax
movl %eax, -0x4(%rbp)
jmp 0x765c0
movq -0x18(%rbp), %rax
movsbl 0x7e7(%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x69(%rbp)
je 0x762ff
movq -0x18(%rbp), %rax
cmpb $0x0, 0x7d9(%rax)
setne %al
xorb $-0x1, %al
movb %al, -0x69(%rbp)
movb -0x69(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x19(%rbp)
cmpb $0x0, -0x19(%rbp)
je 0x763bb
leaq -0x62(%rbp), %rax
movq %rax, -0x40(%rbp)
movq $0x2, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdx
movq -0x10(%rbp), %rcx
leaq -0x60(%rbp), %r10
leaq -0x62(%rbp), %rax
leaq -0x28(%rbp), %rdi
movl $0x21, %esi
xorl %r8d, %r8d
movl $0x3, %r9d
xorl %r11d, %r11d
movq %r10, (%rsp)
movq %rax, 0x8(%rsp)
movq $0x0, 0x10(%rsp)
callq 0x31e50
movsbl %al, %ecx
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x6a(%rbp)
jne 0x76386
movq -0x28(%rbp), %rdi
callq 0x34660
movsbl %al, %eax
cmpl $0x0, %eax
setne %al
movb %al, -0x6a(%rbp)
movb -0x6a(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x763a6
jmp 0x7657f
movq -0x18(%rbp), %rdi
callq 0x48d70
cmpl $0x0, %eax
je 0x763b9
jmp 0x7657f
jmp 0x763d7
movq -0x18(%rbp), %rdi
callq 0x48d70
cmpl $0x0, %eax
je 0x763ce
jmp 0x7657f
movq -0x10(%rbp), %rdi
callq 0x765d0
movq -0x10(%rbp), %rdi
callq 0x497b0
movq -0x18(%rbp), %rax
movl $0x0, 0x170(%rax)
cmpb $0x0, -0x29(%rbp)
je 0x763fd
movq -0x10(%rbp), %rdi
callq 0x4bcb0
movq -0x10(%rbp), %rdi
movl $0x3, %esi
movl $0x2, %ecx
movl %ecx, %edx
callq 0x430e0
cmpl $0x0, %eax
jne 0x76478
movq -0x10(%rbp), %rax
movl 0x480(%rax), %edx
leaq 0xdc256(%rip), %rdi # 0x15267e
movl $0x6b, %esi
xorl %eax, %eax
movl %eax, %ecx
xorl %r8d, %r8d
movl $0x10, %r9d
callq 0x76720
cmpl $0x0, %eax
jne 0x76478
movq -0x18(%rbp), %rax
movl 0x760(%rax), %edx
movq -0x18(%rbp), %rax
movq 0x360(%rax), %rcx
leaq 0xdc21e(%rip), %rdi # 0x15267e
movl $0x6c, %esi
xorl %r8d, %r8d
movl $0x10, %r9d
callq 0x76720
cmpl $0x0, %eax
je 0x7647d
jmp 0x7657f
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movl 0x480(%rax), %esi
callq 0x75d50
cmpl $0x0, %eax
je 0x7649a
jmp 0x7657f
cmpb $0x0, -0x19(%rbp)
je 0x7651f
movq -0x18(%rbp), %rdi
movl $0x5, %esi
callq 0x8fe70
movl %eax, %ecx
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x6b(%rbp)
jne 0x764f7
movq -0x18(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x78(%rax), %rdx
xorl %r8d, %r8d
movl %r8d, %ecx
callq 0x76190
movl %eax, %ecx
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x6b(%rbp)
jne 0x764f7
movq -0x10(%rbp), %rdi
callq 0x43350
cmpl $0x0, %eax
setne %al
movb %al, -0x6b(%rbp)
movb -0x6b(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x63(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq $0x0, 0x90(%rax)
cmpb $0x0, -0x63(%rbp)
je 0x7651d
jmp 0x7657f
jmp 0x7651f
movq -0x10(%rbp), %rax
movl 0x61c(%rax), %eax
andl $0x10, %eax
cmpl $0x0, %eax
je 0x76553
movq -0x10(%rbp), %rdi
addq $0x4b8, %rdi # imm = 0x4B8
movl $0x2, %esi
xorl %eax, %eax
movl %eax, %edx
movl $0x1, %r8d
movl %r8d, %ecx
callq 0xe0590
movq -0x10(%rbp), %rdi
movl $0x1, %esi
callq 0x48cb0
cmpb $0x0, -0x29(%rbp)
je 0x76574
movq -0x10(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x4e3e0
jmp 0x76576
movl $0x0, -0x4(%rbp)
jmp 0x765c0
callq 0xf6080
movl (%rax), %eax
movl %eax, -0x68(%rbp)
movq -0x10(%rbp), %rdi
movl $0x1, %esi
callq 0x48cb0
movq -0x10(%rbp), %rax
movl 0x624(%rax), %ecx
orl $0x4, %ecx
movl %ecx, 0x624(%rax)
movl -0x68(%rbp), %eax
movl %eax, -0x70(%rbp)
callq 0xf6080
movq %rax, %rcx
movl -0x70(%rbp), %eax
movl %eax, (%rcx)
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x90, %rsp
popq %rbp
retq
nopl (%rax)
|
maria_delete_all_rows:
push rbp
mov rbp, rsp
sub rsp, 90h
mov [rbp+var_10], rdi
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_18], rax
mov rax, [rbp+var_18]
cmp qword ptr [rax+5F0h], 0
setnz al
and al, 1
movzx eax, al
mov [rbp+var_29], al
mov rax, [rbp+var_18]
mov rax, [rax+720h]
and rax, 10000h
cmp rax, 0
jz short loc_762B1
jmp short $+2
loc_7629A:
call _my_thread_var
mov dword ptr [rax], 0Dh
mov [rbp+var_4], 0Dh
jmp loc_765C0
loc_762B1:
mov rdi, [rbp+var_10]
mov edx, 1
mov esi, edx
call _ma_readinfo
cmp eax, 0
jz short loc_762D7
jmp short $+2
loc_762C8:
call _my_thread_var
mov eax, [rax]
mov [rbp+var_4], eax
jmp loc_765C0
loc_762D7:
mov rax, [rbp+var_18]
movsx ecx, byte ptr [rax+7E7h]
xor eax, eax
cmp ecx, 0
mov [rbp+var_69], al
jz short loc_762FF
mov rax, [rbp+var_18]
cmp byte ptr [rax+7D9h], 0
setnz al
xor al, 0FFh
mov [rbp+var_69], al
loc_762FF:
mov al, [rbp+var_69]
and al, 1
movzx eax, al
mov [rbp+var_19], al
cmp [rbp+var_19], 0
jz loc_763BB
lea rax, [rbp+var_62]
mov [rbp+var_40], rax
mov [rbp+var_38], 2
mov rax, [rbp+var_10]
mov rdx, [rax+8]
mov rcx, [rbp+var_10]
lea r10, [rbp+var_60]
lea rax, [rbp+var_62]
lea rdi, [rbp+var_28]
mov esi, 21h ; '!'
xor r8d, r8d
mov r9d, 3
xor r11d, r11d
mov [rsp+90h+var_90], r10
mov [rsp+90h+var_88], rax
mov [rsp+90h+var_80], 0
call translog_write_record
movsx ecx, al
mov al, 1
cmp ecx, 0
mov [rbp+var_6A], al
jnz short loc_76386
mov rdi, [rbp+var_28]
call translog_flush
movsx eax, al
cmp eax, 0
setnz al
mov [rbp+var_6A], al
loc_76386:
mov al, [rbp+var_6A]
and al, 1
movzx eax, al
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_763A6
jmp loc_7657F
loc_763A6:
mov rdi, [rbp+var_18]
call _ma_mark_file_changed
cmp eax, 0
jz short loc_763B9
jmp loc_7657F
loc_763B9:
jmp short loc_763D7
loc_763BB:
mov rdi, [rbp+var_18]
call _ma_mark_file_changed
cmp eax, 0
jz short loc_763CE
jmp loc_7657F
loc_763CE:
mov rdi, [rbp+var_10]
call _ma_reset_status
loc_763D7:
mov rdi, [rbp+var_10]
call _ma_reset_state
mov rax, [rbp+var_18]
mov dword ptr [rax+170h], 0
cmp [rbp+var_29], 0
jz short loc_763FD
mov rdi, [rbp+var_10]
call _ma_unmap_file
loc_763FD:
mov rdi, [rbp+var_10]
mov esi, 3
mov ecx, 2
mov edx, ecx
call _ma_flush_table_files
cmp eax, 0
jnz short loc_76478
mov rax, [rbp+var_10]
mov edx, [rax+480h]
lea rdi, aWorkspaceLlm4b_15; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 6Bh ; 'k'
xor eax, eax
mov ecx, eax
xor r8d, r8d
mov r9d, 10h
call inline_mysql_file_chsize_2
cmp eax, 0
jnz short loc_76478
mov rax, [rbp+var_18]
mov edx, [rax+760h]
mov rax, [rbp+var_18]
mov rcx, [rax+360h]
lea rdi, aWorkspaceLlm4b_15; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 6Ch ; 'l'
xor r8d, r8d
mov r9d, 10h
call inline_mysql_file_chsize_2
cmp eax, 0
jz short loc_7647D
loc_76478:
jmp loc_7657F
loc_7647D:
mov rdi, [rbp+var_18]
mov rax, [rbp+var_10]
mov esi, [rax+480h]
call _ma_initialize_data_file
cmp eax, 0
jz short loc_7649A
jmp loc_7657F
loc_7649A:
cmp [rbp+var_19], 0
jz short loc_7651F
mov rdi, [rbp+var_18]
mov esi, 5
call _ma_state_info_write
mov ecx, eax
mov al, 1
cmp ecx, 0
mov [rbp+var_6B], al
jnz short loc_764F7
mov rdi, [rbp+var_18]
mov rsi, [rbp+var_28]
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov rdx, [rax+78h]
xor r8d, r8d
mov ecx, r8d
call _ma_update_state_lsns
mov ecx, eax
mov al, 1
cmp ecx, 0
mov [rbp+var_6B], al
jnz short loc_764F7
mov rdi, [rbp+var_10]
call _ma_sync_table_files
cmp eax, 0
setnz al
mov [rbp+var_6B], al
loc_764F7:
mov al, [rbp+var_6B]
and al, 1
movzx eax, al
mov [rbp+var_63], al
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov qword ptr [rax+90h], 0
cmp [rbp+var_63], 0
jz short loc_7651D
jmp short loc_7657F
loc_7651D:
jmp short $+2
loc_7651F:
mov rax, [rbp+var_10]
mov eax, [rax+61Ch]
and eax, 10h
cmp eax, 0
jz short loc_76553
mov rdi, [rbp+var_10]
add rdi, 4B8h
mov esi, 2
xor eax, eax
mov edx, eax
mov r8d, 1
mov ecx, r8d
call reinit_io_cache
loc_76553:
mov rdi, [rbp+var_10]
mov esi, 1
call _ma_writeinfo
cmp [rbp+var_29], 0
jz short loc_76574
mov rdi, [rbp+var_10]
xor eax, eax
mov esi, eax
call _ma_dynmap_file
loc_76574:
jmp short $+2
loc_76576:
mov [rbp+var_4], 0
jmp short loc_765C0
loc_7657F:
call _my_thread_var
mov eax, [rax]
mov [rbp+var_68], eax
mov rdi, [rbp+var_10]
mov esi, 1
call _ma_writeinfo
mov rax, [rbp+var_10]
mov ecx, [rax+624h]
or ecx, 4
mov [rax+624h], ecx
mov eax, [rbp+var_68]
mov [rbp+var_70], eax
call _my_thread_var
mov rcx, rax
mov eax, [rbp+var_70]
mov [rcx], eax
mov [rbp+var_4], eax
loc_765C0:
mov eax, [rbp+var_4]
add rsp, 90h
pop rbp
retn
|
long long maria_delete_all_rows(long long *a1, const char *a2)
{
long long v2; // rsi
long long *v3; // rdi
long long *v4; // rdi
bool v6; // [rsp+25h] [rbp-6Bh]
bool v7; // [rsp+26h] [rbp-6Ah]
char v8; // [rsp+27h] [rbp-69h]
unsigned int v9; // [rsp+28h] [rbp-68h]
__int16 v10; // [rsp+2Eh] [rbp-62h] BYREF
_QWORD v11[6]; // [rsp+30h] [rbp-60h] BYREF
bool v12; // [rsp+67h] [rbp-29h]
long long *v13; // [rsp+68h] [rbp-28h] BYREF
char v14; // [rsp+77h] [rbp-19h]
_DWORD *v15; // [rsp+78h] [rbp-18h]
long long *v16; // [rsp+80h] [rbp-10h]
v16 = a1;
v15 = (_DWORD *)*a1;
v12 = *((_QWORD *)v15 + 190) != 0LL;
if ( (*((_QWORD *)v15 + 228) & 0x10000LL) != 0 )
{
*(_DWORD *)my_thread_var(a1, a2) = 13;
return 13;
}
v2 = 1LL;
if ( (unsigned int)ma_readinfo() )
return *(unsigned int *)my_thread_var(v16, (_BYTE *)&dword_0 + 1);
v8 = 0;
if ( *((_BYTE *)v15 + 2023) )
v8 = ~(*((_BYTE *)v15 + 2009) != 0);
v14 = v8 & 1;
if ( (v8 & 1) != 0 )
{
v11[4] = &v10;
v11[5] = 2LL;
v3 = (long long *)&v13;
v2 = 33LL;
v7 = 1;
if ( !translog_write_record((long long)&v13, 0x21u, v16[1], v16, 0, 3u, v11, &v10, 0LL) )
{
v3 = v13;
v7 = translog_flush((long long)v13) != 0;
}
if ( v7 )
goto LABEL_32;
v3 = (long long *)v15;
if ( (unsigned int)ma_mark_file_changed((long long)v15) )
goto LABEL_32;
}
else
{
v3 = (long long *)v15;
if ( (unsigned int)ma_mark_file_changed((long long)v15) )
{
LABEL_32:
v9 = *(_DWORD *)my_thread_var(v3, (const char *)v2);
v4 = v16;
ma_writeinfo(v16, 1);
*((_DWORD *)v16 + 393) |= 4u;
*(_DWORD *)my_thread_var(v4, (_BYTE *)&dword_0 + 1) = v9;
return v9;
}
ma_reset_status(v16);
}
ma_reset_state(v16);
v15[92] = 0;
if ( v12 )
ma_unmap_file(v16);
v3 = v16;
v2 = 3LL;
if ( (unsigned int)ma_flush_table_files(v16, 3, 2u, 2u) )
goto LABEL_32;
v3 = (long long *)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_delete_all.c";
v2 = 107LL;
if ( (unsigned int)inline_mysql_file_chsize_2(
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_delete_all.c",
107LL,
*((unsigned int *)v16 + 288),
0LL,
0LL,
16LL) )
goto LABEL_32;
v3 = (long long *)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_delete_all.c";
v2 = 108LL;
if ( (unsigned int)inline_mysql_file_chsize_2(
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_delete_all.c",
108LL,
(unsigned int)v15[472],
*((_QWORD *)v15 + 108),
0LL,
16LL) )
goto LABEL_32;
v3 = (long long *)v15;
v2 = *((unsigned int *)v16 + 288);
if ( (unsigned int)ma_initialize_data_file(v15, v2) )
goto LABEL_32;
if ( v14 )
{
v3 = (long long *)v15;
v2 = 5LL;
v6 = 1;
if ( !(unsigned int)ma_state_info_write(v15, 5LL) )
{
v3 = (long long *)v15;
v2 = (long long)v13;
v6 = 1;
if ( !(unsigned int)ma_update_state_lsns((long long)v15, (long long)v13, *(_QWORD *)(v16[1] + 120), 0, 0) )
{
v3 = v16;
v6 = ma_sync_table_files((unsigned int *)v16);
}
}
*(_QWORD *)(v16[1] + 144) = 0LL;
if ( v6 )
goto LABEL_32;
}
if ( (*((_DWORD *)v16 + 391) & 0x10) != 0 )
reinit_io_cache(v16 + 151, 2LL, 0LL, 1LL, 1LL);
ma_writeinfo(v16, 1);
if ( v12 )
ma_dynmap_file((unsigned int *)v16, 0LL);
return 0;
}
|
maria_delete_all_rows:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
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]
CMP qword ptr [RAX + 0x5f0],0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x29],AL
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x720]
AND RAX,0x10000
CMP RAX,0x0
JZ 0x001762b1
JMP 0x0017629a
LAB_0017629a:
CALL 0x001f6080
MOV dword ptr [RAX],0xd
MOV dword ptr [RBP + -0x4],0xd
JMP 0x001765c0
LAB_001762b1:
MOV RDI,qword ptr [RBP + -0x10]
MOV EDX,0x1
MOV ESI,EDX
CALL 0x00148c90
CMP EAX,0x0
JZ 0x001762d7
JMP 0x001762c8
LAB_001762c8:
CALL 0x001f6080
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x001765c0
LAB_001762d7:
MOV RAX,qword ptr [RBP + -0x18]
MOVSX ECX,byte ptr [RAX + 0x7e7]
XOR EAX,EAX
CMP ECX,0x0
MOV byte ptr [RBP + -0x69],AL
JZ 0x001762ff
MOV RAX,qword ptr [RBP + -0x18]
CMP byte ptr [RAX + 0x7d9],0x0
SETNZ AL
XOR AL,0xff
MOV byte ptr [RBP + -0x69],AL
LAB_001762ff:
MOV AL,byte ptr [RBP + -0x69]
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x19],AL
CMP byte ptr [RBP + -0x19],0x0
JZ 0x001763bb
LEA RAX,[RBP + -0x62]
MOV qword ptr [RBP + -0x40],RAX
MOV qword ptr [RBP + -0x38],0x2
MOV RAX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x10]
LEA R10,[RBP + -0x60]
LEA RAX,[RBP + -0x62]
LEA RDI,[RBP + -0x28]
MOV ESI,0x21
XOR R8D,R8D
MOV R9D,0x3
XOR R11D,R11D
MOV qword ptr [RSP],R10
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x10],0x0
CALL 0x00131e50
MOVSX ECX,AL
MOV AL,0x1
CMP ECX,0x0
MOV byte ptr [RBP + -0x6a],AL
JNZ 0x00176386
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x00134660
MOVSX EAX,AL
CMP EAX,0x0
SETNZ AL
MOV byte ptr [RBP + -0x6a],AL
LAB_00176386:
MOV AL,byte ptr [RBP + -0x6a]
AND AL,0x1
MOVZX EAX,AL
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x001763a6
JMP 0x0017657f
LAB_001763a6:
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00148d70
CMP EAX,0x0
JZ 0x001763b9
JMP 0x0017657f
LAB_001763b9:
JMP 0x001763d7
LAB_001763bb:
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00148d70
CMP EAX,0x0
JZ 0x001763ce
JMP 0x0017657f
LAB_001763ce:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001765d0
LAB_001763d7:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001497b0
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX + 0x170],0x0
CMP byte ptr [RBP + -0x29],0x0
JZ 0x001763fd
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0014bcb0
LAB_001763fd:
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,0x3
MOV ECX,0x2
MOV EDX,ECX
CALL 0x001430e0
CMP EAX,0x0
JNZ 0x00176478
MOV RAX,qword ptr [RBP + -0x10]
MOV EDX,dword ptr [RAX + 0x480]
LEA RDI,[0x25267e]
MOV ESI,0x6b
XOR EAX,EAX
MOV ECX,EAX
XOR R8D,R8D
MOV R9D,0x10
CALL 0x00176720
CMP EAX,0x0
JNZ 0x00176478
MOV RAX,qword ptr [RBP + -0x18]
MOV EDX,dword ptr [RAX + 0x760]
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RAX + 0x360]
LEA RDI,[0x25267e]
MOV ESI,0x6c
XOR R8D,R8D
MOV R9D,0x10
CALL 0x00176720
CMP EAX,0x0
JZ 0x0017647d
LAB_00176478:
JMP 0x0017657f
LAB_0017647d:
MOV RDI,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RAX + 0x480]
CALL 0x00175d50
CMP EAX,0x0
JZ 0x0017649a
JMP 0x0017657f
LAB_0017649a:
CMP byte ptr [RBP + -0x19],0x0
JZ 0x0017651f
MOV RDI,qword ptr [RBP + -0x18]
MOV ESI,0x5
CALL 0x0018fe70
MOV ECX,EAX
MOV AL,0x1
CMP ECX,0x0
MOV byte ptr [RBP + -0x6b],AL
JNZ 0x001764f7
MOV RDI,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV RDX,qword ptr [RAX + 0x78]
XOR R8D,R8D
MOV ECX,R8D
CALL 0x00176190
MOV ECX,EAX
MOV AL,0x1
CMP ECX,0x0
MOV byte ptr [RBP + -0x6b],AL
JNZ 0x001764f7
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00143350
CMP EAX,0x0
SETNZ AL
MOV byte ptr [RBP + -0x6b],AL
LAB_001764f7:
MOV AL,byte ptr [RBP + -0x6b]
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x63],AL
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RAX + 0x90],0x0
CMP byte ptr [RBP + -0x63],0x0
JZ 0x0017651d
JMP 0x0017657f
LAB_0017651d:
JMP 0x0017651f
LAB_0017651f:
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x61c]
AND EAX,0x10
CMP EAX,0x0
JZ 0x00176553
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x4b8
MOV ESI,0x2
XOR EAX,EAX
MOV EDX,EAX
MOV R8D,0x1
MOV ECX,R8D
CALL 0x001e0590
LAB_00176553:
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,0x1
CALL 0x00148cb0
CMP byte ptr [RBP + -0x29],0x0
JZ 0x00176574
MOV RDI,qword ptr [RBP + -0x10]
XOR EAX,EAX
MOV ESI,EAX
CALL 0x0014e3e0
LAB_00176574:
JMP 0x00176576
LAB_00176576:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x001765c0
LAB_0017657f:
CALL 0x001f6080
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x68],EAX
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,0x1
CALL 0x00148cb0
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x624]
OR ECX,0x4
MOV dword ptr [RAX + 0x624],ECX
MOV EAX,dword ptr [RBP + -0x68]
MOV dword ptr [RBP + -0x70],EAX
CALL 0x001f6080
MOV RCX,RAX
MOV EAX,dword ptr [RBP + -0x70]
MOV dword ptr [RCX],EAX
MOV dword ptr [RBP + -0x4],EAX
LAB_001765c0:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x90
POP RBP
RET
|
int4 maria_delete_all_rows(long *param_1)
{
int4 uVar1;
char cVar2;
int iVar3;
int4 *puVar4;
bool bVar5;
byte local_71;
int1 local_6a [2];
int1 local_68 [32];
int1 *local_48;
int8 local_40;
char local_31;
int8 local_30;
byte local_21;
long local_20;
long *local_18;
local_20 = *param_1;
local_31 = *(long *)(local_20 + 0x5f0) != 0;
local_18 = param_1;
if ((*(ulong *)(local_20 + 0x720) & 0x10000) != 0) {
puVar4 = (int4 *)_my_thread_var();
*puVar4 = 0xd;
return 0xd;
}
iVar3 = _ma_readinfo(param_1,1);
if (iVar3 != 0) {
puVar4 = (int4 *)_my_thread_var();
return *puVar4;
}
local_71 = 0;
if (*(char *)(local_20 + 0x7e7) != '\0') {
local_71 = *(char *)(local_20 + 0x7d9) != '\0' ^ 0xff;
}
local_21 = local_71 & 1;
if (local_21 == 0) {
iVar3 = _ma_mark_file_changed(local_20);
if (iVar3 != 0) goto LAB_0017657f;
_ma_reset_status(local_18);
}
else {
local_48 = local_6a;
local_40 = 2;
cVar2 = translog_write_record(&local_30,0x21,local_18[1],local_18,0,3,local_68,local_6a,0);
bVar5 = true;
if (cVar2 == '\0') {
cVar2 = translog_flush(local_30);
bVar5 = cVar2 != '\0';
}
if ((bVar5) || (iVar3 = _ma_mark_file_changed(local_20), iVar3 != 0)) goto LAB_0017657f;
}
_ma_reset_state(local_18);
*(int4 *)(local_20 + 0x170) = 0;
if (local_31 != '\0') {
_ma_unmap_file(local_18);
}
iVar3 = _ma_flush_table_files(local_18,3,2);
if ((((iVar3 == 0) &&
(iVar3 = inline_mysql_file_chsize
("/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_delete_all.c",
0x6b,(int)local_18[0x90],0,0,0x10), iVar3 == 0)) &&
(iVar3 = inline_mysql_file_chsize
("/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_delete_all.c",
0x6c,*(int4 *)(local_20 + 0x760),*(int8 *)(local_20 + 0x360),0
,0x10), iVar3 == 0)) &&
(iVar3 = _ma_initialize_data_file(local_20,(int)local_18[0x90]), iVar3 == 0)) {
if (local_21 != 0) {
iVar3 = _ma_state_info_write(local_20,5);
bVar5 = true;
if (iVar3 == 0) {
iVar3 = _ma_update_state_lsns(local_20,local_30,*(int8 *)(local_18[1] + 0x78),0);
bVar5 = true;
if (iVar3 == 0) {
iVar3 = _ma_sync_table_files(local_18);
bVar5 = iVar3 != 0;
}
}
*(int8 *)(local_18[1] + 0x90) = 0;
if (bVar5) goto LAB_0017657f;
}
if ((*(uint *)((long)local_18 + 0x61c) & 0x10) != 0) {
reinit_io_cache(local_18 + 0x97,2,0,1);
}
_ma_writeinfo(local_18,1);
if (local_31 != '\0') {
_ma_dynmap_file(local_18,0);
}
return 0;
}
LAB_0017657f:
puVar4 = (int4 *)_my_thread_var();
uVar1 = *puVar4;
_ma_writeinfo(local_18,1);
*(uint *)((long)local_18 + 0x624) = *(uint *)((long)local_18 + 0x624) | 4;
puVar4 = (int4 *)_my_thread_var();
*puVar4 = uVar1;
return uVar1;
}
|
|
19,920
|
chess::movegen::init_squares_between()
|
Razamindset[P]pawnstar-chess-engine/src/./engine/../chess-library/include/chess.hpp
|
inline auto movegen::init_squares_between() {
std::array<std::array<Bitboard, 64>, 64> squares_between_bb{};
Bitboard sqs = 0;
for (Square sq1 = 0; sq1 < 64; ++sq1) {
for (Square sq2 = 0; sq2 < 64; ++sq2) {
sqs = Bitboard::fromSquare(sq1) | Bitboard::fromSquare(sq2);
if (sq1 == sq2)
squares_between_bb[sq1.index()][sq2.index()].clear();
else if (sq1.file() == sq2.file() || sq1.rank() == sq2.rank())
squares_between_bb[sq1.index()][sq2.index()] = attacks::rook(sq1, sqs) & attacks::rook(sq2, sqs);
else if (sq1.diagonal_of() == sq2.diagonal_of() || sq1.antidiagonal_of() == sq2.antidiagonal_of())
squares_between_bb[sq1.index()][sq2.index()] = attacks::bishop(sq1, sqs) & attacks::bishop(sq2, sqs);
}
}
return squares_between_bb;
}
|
O1
|
cpp
|
chess::movegen::init_squares_between():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
xorl %r14d, %r14d
movl $0x8000, %edx # imm = 0x8000
xorl %esi, %esi
callq 0x30f0
leaq 0xed418(%rip), %rax # 0xf0e10
movq %rbx, (%rsp)
movq %rbx, %rsi
movl $0x1, %edi
movl %r14d, %ecx
shlq %cl, %rdi
movl %r14d, %r8d
shrl $0x3, %r8d
movl %r14d, %r9d
andl $0x7, %r9d
movl %r8d, %r10d
subl %r9d, %r10d
addl $0x7, %r10d
addl %r8d, %r9d
movl $0x3, %r11d
movq %r14, %r15
shlq $0x5, %r15
xorl %r12d, %r12d
cmpq %r12, %r14
jne 0x3a3e
xorl %ecx, %ecx
jmp 0x3a9c
movl %r12d, %ecx
xorl %r14d, %ecx
movq %rax, %r13
testb $0x7, %cl
je 0x3a5a
movl %r12d, %ecx
shrl $0x3, %ecx
movq %rax, %r13
cmpl %ecx, %r8d
jne 0x3aaf
movq %rdi, %rbx
btsq %r12, %rbx
movq (%r13,%r15), %rbp
andq %rbx, %rbp
imulq 0x8(%r13,%r15), %rbp
movb 0x18(%r13,%r15), %cl
shrq %cl, %rbp
andq -0x18(%r13,%r11,8), %rbx
movq 0x10(%r13,%r15), %rdx
imulq -0x10(%r13,%r11,8), %rbx
movb (%r13,%r11,8), %cl
shrq %cl, %rbx
movq -0x8(%r13,%r11,8), %rcx
movq (%rcx,%rbx,8), %rcx
andq (%rdx,%rbp,8), %rcx
movq %rcx, (%rsi,%r12,8)
incq %r12
addq $0x4, %r11
cmpq $0x40, %r12
jne 0x3a35
jmp 0x3ad8
movl %r12d, %ebp
andl $0x7, %ebp
movl %ecx, %ebx
subl %ebp, %ebx
addl $0x7, %ebx
leaq 0x24b4d(%rip), %r13 # 0x28610
cmpl %ebx, %r10d
je 0x3a5a
addl %ebp, %ecx
leaq 0x24b3f(%rip), %r13 # 0x28610
cmpl %ecx, %r9d
jne 0x3aa0
jmp 0x3a5a
incq %r14
addq $0x200, %rsi # imm = 0x200
cmpq $0x40, %r14
jne 0x39ff
movq (%rsp), %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
|
_ZN5chess7movegen20init_squares_betweenEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rdi
xor r14d, r14d
mov edx, 8000h
xor esi, esi
call _memset
lea rax, _ZN5chess7attacks9RookTableE; chess::attacks::RookTable
mov [rsp+38h+var_38], rbx
mov rsi, rbx
loc_39FF:
mov edi, 1
mov ecx, r14d
shl rdi, cl
mov r8d, r14d
shr r8d, 3
mov r9d, r14d
and r9d, 7
mov r10d, r8d
sub r10d, r9d
add r10d, 7
add r9d, r8d
mov r11d, 3
mov r15, r14
shl r15, 5
xor r12d, r12d
loc_3A35:
cmp r14, r12
jnz short loc_3A3E
xor ecx, ecx
jmp short loc_3A9C
loc_3A3E:
mov ecx, r12d
xor ecx, r14d
mov r13, rax
test cl, 7
jz short loc_3A5A
mov ecx, r12d
shr ecx, 3
mov r13, rax
cmp r8d, ecx
jnz short loc_3AAF
loc_3A5A:
mov rbx, rdi
bts rbx, r12
mov rbp, [r13+r15+0]
and rbp, rbx
imul rbp, [r13+r15+8]
mov cl, [r13+r15+18h]
shr rbp, cl
and rbx, [r13+r11*8-18h]
mov rdx, [r13+r15+10h]
imul rbx, [r13+r11*8-10h]
mov cl, [r13+r11*8+0]
shr rbx, cl
mov rcx, [r13+r11*8-8]
mov rcx, [rcx+rbx*8]
and rcx, [rdx+rbp*8]
loc_3A9C:
mov [rsi+r12*8], rcx
loc_3AA0:
inc r12
add r11, 4
cmp r12, 40h ; '@'
jnz short loc_3A35
jmp short loc_3AD8
loc_3AAF:
mov ebp, r12d
and ebp, 7
mov ebx, ecx
sub ebx, ebp
add ebx, 7
lea r13, _ZN5chess7attacks11BishopTableE; chess::attacks::BishopTable
cmp r10d, ebx
jz short loc_3A5A
add ecx, ebp
lea r13, _ZN5chess7attacks11BishopTableE; chess::attacks::BishopTable
cmp r9d, ecx
jnz short loc_3AA0
jmp short loc_3A5A
loc_3AD8:
inc r14
add rsi, 200h
cmp r14, 40h ; '@'
jnz loc_39FF
mov rax, [rsp+38h+var_38]
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
chess::movegen * chess::movegen::init_squares_between(chess::movegen *this)
{
long long v1; // r14
chess::movegen *v2; // rsi
int v3; // r9d
unsigned int v4; // r10d
int v5; // r9d
long long v6; // r11
long long v7; // r15
long long i; // r12
long long v9; // rcx
_BYTE *v10; // r13
unsigned int v11; // ecx
int v12; // ebp
v1 = 0LL;
memset(this, 0LL, 0x8000LL);
v2 = this;
do
{
v3 = v1 & 7;
v4 = ((unsigned int)v1 >> 3) - v3 + 7;
v5 = ((unsigned int)v1 >> 3) + v3;
v6 = 3LL;
for ( i = 0LL; i != 64; ++i )
{
if ( v1 == i )
{
v9 = 0LL;
LABEL_8:
*((_QWORD *)v2 + i) = v9;
goto LABEL_9;
}
v10 = &chess::attacks::RookTable;
if ( (((unsigned __int8)v1 ^ (unsigned __int8)i) & 7) == 0
|| (v11 = (unsigned int)i >> 3, v10 = &chess::attacks::RookTable, (unsigned int)v1 >> 3 == (unsigned int)i >> 3)
|| (v12 = i & 7, v10 = &chess::attacks::BishopTable, v4 == v11 - v12 + 7)
|| (v10 = &chess::attacks::BishopTable, v5 == v12 + v11) )
{
v7 = 32 * v1;
v9 = *(_QWORD *)(*(_QWORD *)&v10[v7 + 16]
+ 8
* ((*(_QWORD *)&v10[v7 + 8] * (((1LL << v1) | (unsigned long long)(1LL << i)) & *(_QWORD *)&v10[v7])) >> v10[v7 + 24])) & *(_QWORD *)(*(_QWORD *)&v10[8 * v6 - 8] + 8 * ((*(_QWORD *)&v10[8 * v6 - 16] * (*(_QWORD *)&v10[8 * v6 - 24] & ((1LL << v1) | (unsigned long long)(1LL << i)))) >> v10[8 * v6]));
goto LABEL_8;
}
LABEL_9:
v6 += 4LL;
}
++v1;
v2 = (chess::movegen *)((char *)v2 + 512);
}
while ( v1 != 64 );
return this;
}
|
init_squares_between:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDI
XOR R14D,R14D
MOV EDX,0x8000
XOR ESI,ESI
CALL 0x001030f0
LEA RAX,[0x1f0e10]
MOV qword ptr [RSP],RBX
MOV RSI,RBX
LAB_001039ff:
MOV EDI,0x1
MOV ECX,R14D
SHL RDI,CL
MOV R8D,R14D
SHR R8D,0x3
MOV R9D,R14D
AND R9D,0x7
MOV R10D,R8D
SUB R10D,R9D
ADD R10D,0x7
ADD R9D,R8D
MOV R11D,0x3
MOV R15,R14
SHL R15,0x5
XOR R12D,R12D
LAB_00103a35:
CMP R14,R12
JNZ 0x00103a3e
XOR ECX,ECX
JMP 0x00103a9c
LAB_00103a3e:
MOV ECX,R12D
XOR ECX,R14D
MOV R13,RAX
TEST CL,0x7
JZ 0x00103a5a
MOV ECX,R12D
SHR ECX,0x3
MOV R13,RAX
CMP R8D,ECX
JNZ 0x00103aaf
LAB_00103a5a:
MOV RBX,RDI
BTS RBX,R12
MOV RBP,qword ptr [R13 + R15*0x1]
AND RBP,RBX
IMUL RBP,qword ptr [R13 + R15*0x1 + 0x8]
MOV CL,byte ptr [R13 + R15*0x1 + 0x18]
SHR RBP,CL
AND RBX,qword ptr [R13 + R11*0x8 + -0x18]
MOV RDX,qword ptr [R13 + R15*0x1 + 0x10]
IMUL RBX,qword ptr [R13 + R11*0x8 + -0x10]
MOV CL,byte ptr [R13 + R11*0x8]
SHR RBX,CL
MOV RCX,qword ptr [R13 + R11*0x8 + -0x8]
MOV RCX,qword ptr [RCX + RBX*0x8]
AND RCX,qword ptr [RDX + RBP*0x8]
LAB_00103a9c:
MOV qword ptr [RSI + R12*0x8],RCX
LAB_00103aa0:
INC R12
ADD R11,0x4
CMP R12,0x40
JNZ 0x00103a35
JMP 0x00103ad8
LAB_00103aaf:
MOV EBP,R12D
AND EBP,0x7
MOV EBX,ECX
SUB EBX,EBP
ADD EBX,0x7
LEA R13,[0x128610]
CMP R10D,EBX
JZ 0x00103a5a
ADD ECX,EBP
LEA R13,[0x128610]
CMP R9D,ECX
JNZ 0x00103aa0
JMP 0x00103a5a
LAB_00103ad8:
INC R14
ADD RSI,0x200
CMP R14,0x40
JNZ 0x001039ff
MOV RAX,qword ptr [RSP]
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* chess::movegen::init_squares_between() */
movegen * __thiscall chess::movegen::init_squares_between(movegen *this)
{
uint uVar1;
ulong uVar2;
uint uVar3;
movegen *pmVar4;
uint uVar5;
uint uVar6;
long lVar7;
ulong uVar8;
int8 *puVar9;
ulong uVar10;
uVar10 = 0;
memset(this,0,0x8000);
pmVar4 = this;
do {
uVar5 = (uint)(uVar10 >> 3) & 0x1fffffff;
uVar6 = (uint)uVar10 & 7;
lVar7 = 3;
uVar8 = 0;
do {
if (uVar10 == uVar8) {
uVar2 = 0;
LAB_00103a9c:
*(ulong *)(pmVar4 + uVar8 * 8) = uVar2;
}
else {
puVar9 = &attacks::RookTable;
if ((((uint)uVar8 ^ (uint)uVar10) & 7) == 0) {
LAB_00103a5a:
uVar2 = 1L << ((byte)uVar10 & 0x3f) | 1L << (uVar8 & 0x3f);
uVar2 = *(ulong *)(puVar9[lVar7 + -1] +
((uVar2 & puVar9[lVar7 + -3]) * puVar9[lVar7 + -2] >>
(*(byte *)(puVar9 + lVar7) & 0x3f)) * 8) &
*(ulong *)(puVar9[uVar10 * 4 + 2] +
((puVar9[uVar10 * 4] & uVar2) * puVar9[uVar10 * 4 + 1] >>
(*(byte *)(puVar9 + uVar10 * 4 + 3) & 0x3f)) * 8);
goto LAB_00103a9c;
}
uVar1 = (uint)(uVar8 >> 3) & 0x1fffffff;
puVar9 = &attacks::RookTable;
if (uVar5 == uVar1) goto LAB_00103a5a;
uVar3 = (uint)uVar8 & 7;
puVar9 = &attacks::BishopTable;
if (((uVar5 - uVar6) + 7 == (uVar1 - uVar3) + 7) ||
(puVar9 = &attacks::BishopTable, uVar6 + uVar5 == uVar1 + uVar3)) goto LAB_00103a5a;
}
uVar8 = uVar8 + 1;
lVar7 = lVar7 + 4;
} while (uVar8 != 0x40);
uVar10 = uVar10 + 1;
pmVar4 = pmVar4 + 0x200;
if (uVar10 == 0x40) {
return this;
}
} while( true );
}
|
|
19,921
|
chess::movegen::init_squares_between()
|
Razamindset[P]pawnstar-chess-engine/src/./engine/../chess-library/include/chess.hpp
|
inline auto movegen::init_squares_between() {
std::array<std::array<Bitboard, 64>, 64> squares_between_bb{};
Bitboard sqs = 0;
for (Square sq1 = 0; sq1 < 64; ++sq1) {
for (Square sq2 = 0; sq2 < 64; ++sq2) {
sqs = Bitboard::fromSquare(sq1) | Bitboard::fromSquare(sq2);
if (sq1 == sq2)
squares_between_bb[sq1.index()][sq2.index()].clear();
else if (sq1.file() == sq2.file() || sq1.rank() == sq2.rank())
squares_between_bb[sq1.index()][sq2.index()] = attacks::rook(sq1, sqs) & attacks::rook(sq2, sqs);
else if (sq1.diagonal_of() == sq2.diagonal_of() || sq1.antidiagonal_of() == sq2.antidiagonal_of())
squares_between_bb[sq1.index()][sq2.index()] = attacks::bishop(sq1, sqs) & attacks::bishop(sq2, sqs);
}
}
return squares_between_bb;
}
|
O2
|
cpp
|
chess::movegen::init_squares_between():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
xorl %r14d, %r14d
movl $0x8000, %edx # imm = 0x8000
xorl %esi, %esi
callq 0x2120
movq %rbx, 0x10(%rsp)
movq %rbx, (%rsp)
cmpq $0x40, %r14
je 0x297c
movl %r14d, %ebx
shrl $0x3, %ebx
movl %r14d, %eax
andl $0x7, %eax
movl %ebx, %ecx
subl %eax, %ecx
addl $0x7, %ecx
movl %ecx, 0xc(%rsp)
addl %ebx, %eax
movl %eax, 0x8(%rsp)
movq %r14, %rbp
shlq $0x9, %rbp
addq 0x10(%rsp), %rbp
xorl %r15d, %r15d
cmpq $0x40, %r15
je 0x296c
movl %r14d, %edi
callq 0x2f8c
movq %rax, %r13
movl %r15d, %edi
callq 0x2f8c
cmpq %r15, %r14
jne 0x28f3
andq $0x0, (%rbp,%r14,8)
jmp 0x2931
movq %rax, %r12
orq %r13, %r12
movl %r15d, %eax
xorl %r14d, %eax
testb $0x7, %al
je 0x290d
movl %r15d, %eax
shrl $0x3, %eax
cmpl %eax, %ebx
jne 0x2936
movl %r14d, %edi
movq %r12, %rsi
callq 0x2fba
movq %rax, %r13
movl %r15d, %edi
movq %r12, %rsi
callq 0x2fba
andq %r13, %rax
movq (%rsp), %rcx
movq %rax, (%rcx,%r15,8)
incq %r15
jmp 0x28c9
movl %r15d, %ecx
andl $0x7, %ecx
movl %eax, %edx
subl %ecx, %edx
addl $0x7, %edx
cmpl %edx, 0xc(%rsp)
je 0x2951
addl %ecx, %eax
cmpl %eax, 0x8(%rsp)
jne 0x2931
movl %r14d, %edi
movq %r12, %rsi
callq 0x2fe4
movq %rax, %r13
movl %r15d, %edi
movq %r12, %rsi
callq 0x2fe4
jmp 0x2926
incq %r14
addq $0x200, (%rsp) # imm = 0x200
jmp 0x2893
movq 0x10(%rsp), %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
_ZN5chess7movegen20init_squares_betweenEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov rbx, rdi
xor r14d, r14d
mov edx, 8000h
xor esi, esi
call _memset
mov [rsp+48h+var_38], rbx
mov [rsp+48h+var_48], rbx
loc_2893:
cmp r14, 40h ; '@'
jz loc_297C
mov ebx, r14d
shr ebx, 3
mov eax, r14d
and eax, 7
mov ecx, ebx
sub ecx, eax
add ecx, 7
mov [rsp+48h+var_3C], ecx
add eax, ebx
mov [rsp+48h+var_40], eax
mov rbp, r14
shl rbp, 9
add rbp, [rsp+48h+var_38]
xor r15d, r15d
loc_28C9:
cmp r15, 40h ; '@'
jz loc_296C
mov edi, r14d
call _ZN5chess8Bitboard10fromSquareENS_6SquareE; chess::Bitboard::fromSquare(chess::Square)
mov r13, rax
mov edi, r15d
call _ZN5chess8Bitboard10fromSquareENS_6SquareE; chess::Bitboard::fromSquare(chess::Square)
cmp r14, r15
jnz short loc_28F3
and qword ptr [rbp+r14*8+0], 0
jmp short loc_2931
loc_28F3:
mov r12, rax
or r12, r13
mov eax, r15d
xor eax, r14d
test al, 7
jz short loc_290D
mov eax, r15d
shr eax, 3
cmp ebx, eax
jnz short loc_2936
loc_290D:
mov edi, r14d
mov rsi, r12
call _ZN5chess7attacks4rookENS_6SquareENS_8BitboardE; chess::attacks::rook(chess::Square,chess::Bitboard)
mov r13, rax
mov edi, r15d
mov rsi, r12
call _ZN5chess7attacks4rookENS_6SquareENS_8BitboardE; chess::attacks::rook(chess::Square,chess::Bitboard)
loc_2926:
and rax, r13
mov rcx, [rsp+48h+var_48]
mov [rcx+r15*8], rax
loc_2931:
inc r15
jmp short loc_28C9
loc_2936:
mov ecx, r15d
and ecx, 7
mov edx, eax
sub edx, ecx
add edx, 7
cmp [rsp+48h+var_3C], edx
jz short loc_2951
add eax, ecx
cmp [rsp+48h+var_40], eax
jnz short loc_2931
loc_2951:
mov edi, r14d
mov rsi, r12
call _ZN5chess7attacks6bishopENS_6SquareENS_8BitboardE; chess::attacks::bishop(chess::Square,chess::Bitboard)
mov r13, rax
mov edi, r15d
mov rsi, r12
call _ZN5chess7attacks6bishopENS_6SquareENS_8BitboardE; chess::attacks::bishop(chess::Square,chess::Bitboard)
jmp short loc_2926
loc_296C:
inc r14
add [rsp+48h+var_48], 200h
jmp loc_2893
loc_297C:
mov rax, [rsp+48h+var_38]
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
chess::movegen * chess::movegen::init_squares_between(chess::movegen *this)
{
long long v1; // r14
int v2; // eax
long long i; // r15
long long v4; // r13
long long v5; // rax
long long v6; // r12
unsigned int v7; // eax
long long v8; // r13
long long v9; // rax
int v10; // ecx
chess::movegen *v12; // [rsp+0h] [rbp-48h]
int v13; // [rsp+8h] [rbp-40h]
unsigned int v14; // [rsp+Ch] [rbp-3Ch]
v1 = 0LL;
memset(this, 0LL, 0x8000LL);
v12 = this;
LABEL_2:
if ( v1 != 64 )
{
v2 = v1 & 7;
v14 = ((unsigned int)v1 >> 3) - v2 + 7;
v13 = ((unsigned int)v1 >> 3) + v2;
for ( i = 0LL; ; ++i )
{
if ( i == 64 )
{
++v1;
v12 = (chess::movegen *)((char *)v12 + 512);
goto LABEL_2;
}
v4 = chess::Bitboard::fromSquare((unsigned int)v1);
v5 = chess::Bitboard::fromSquare((unsigned int)i);
if ( v1 == i )
{
*((_QWORD *)this + 64 * v1 + v1) = 0LL;
continue;
}
v6 = v4 | v5;
if ( (((unsigned __int8)v1 ^ (unsigned __int8)i) & 7) == 0 )
break;
v7 = (unsigned int)i >> 3;
if ( (unsigned int)v1 >> 3 == (unsigned int)i >> 3 )
break;
v10 = i & 7;
if ( v14 == v7 - v10 + 7 || v13 == v10 + v7 )
{
v8 = chess::attacks::bishop((unsigned int)v1, v6);
v9 = chess::attacks::bishop((unsigned int)i, v6);
goto LABEL_10;
}
LABEL_11:
;
}
v8 = chess::attacks::rook((unsigned int)v1, v6);
v9 = chess::attacks::rook((unsigned int)i, v6);
LABEL_10:
*((_QWORD *)v12 + i) = v8 & v9;
goto LABEL_11;
}
return this;
}
|
init_squares_between:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV RBX,RDI
XOR R14D,R14D
MOV EDX,0x8000
XOR ESI,ESI
CALL 0x00102120
MOV qword ptr [RSP + 0x10],RBX
MOV qword ptr [RSP],RBX
LAB_00102893:
CMP R14,0x40
JZ 0x0010297c
MOV EBX,R14D
SHR EBX,0x3
MOV EAX,R14D
AND EAX,0x7
MOV ECX,EBX
SUB ECX,EAX
ADD ECX,0x7
MOV dword ptr [RSP + 0xc],ECX
ADD EAX,EBX
MOV dword ptr [RSP + 0x8],EAX
MOV RBP,R14
SHL RBP,0x9
ADD RBP,qword ptr [RSP + 0x10]
XOR R15D,R15D
LAB_001028c9:
CMP R15,0x40
JZ 0x0010296c
MOV EDI,R14D
CALL 0x00102f8c
MOV R13,RAX
MOV EDI,R15D
CALL 0x00102f8c
CMP R14,R15
JNZ 0x001028f3
AND qword ptr [RBP + R14*0x8],0x0
JMP 0x00102931
LAB_001028f3:
MOV R12,RAX
OR R12,R13
MOV EAX,R15D
XOR EAX,R14D
TEST AL,0x7
JZ 0x0010290d
MOV EAX,R15D
SHR EAX,0x3
CMP EBX,EAX
JNZ 0x00102936
LAB_0010290d:
MOV EDI,R14D
MOV RSI,R12
CALL 0x00102fba
MOV R13,RAX
MOV EDI,R15D
MOV RSI,R12
CALL 0x00102fba
LAB_00102926:
AND RAX,R13
MOV RCX,qword ptr [RSP]
MOV qword ptr [RCX + R15*0x8],RAX
LAB_00102931:
INC R15
JMP 0x001028c9
LAB_00102936:
MOV ECX,R15D
AND ECX,0x7
MOV EDX,EAX
SUB EDX,ECX
ADD EDX,0x7
CMP dword ptr [RSP + 0xc],EDX
JZ 0x00102951
ADD EAX,ECX
CMP dword ptr [RSP + 0x8],EAX
JNZ 0x00102931
LAB_00102951:
MOV EDI,R14D
MOV RSI,R12
CALL 0x00102fe4
MOV R13,RAX
MOV EDI,R15D
MOV RSI,R12
CALL 0x00102fe4
JMP 0x00102926
LAB_0010296c:
INC R14
ADD qword ptr [RSP],0x200
JMP 0x00102893
LAB_0010297c:
MOV RAX,qword ptr [RSP + 0x10]
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* chess::movegen::init_squares_between() */
movegen * __thiscall chess::movegen::init_squares_between(movegen *this)
{
uint uVar1;
uint uVar2;
ulong uVar3;
ulong uVar4;
uint uVar5;
uint uVar6;
ulong uVar7;
ulong uVar8;
movegen *local_48;
uVar7 = 0;
memset(this,0,0x8000);
local_48 = this;
do {
if (uVar7 == 0x40) {
return this;
}
uVar6 = (uint)(uVar7 >> 3) & 0x1fffffff;
uVar1 = (uint)uVar7 & 7;
for (uVar8 = 0; uVar8 != 0x40; uVar8 = uVar8 + 1) {
uVar3 = Bitboard::fromSquare(uVar7 & 0xffffffff);
uVar4 = Bitboard::fromSquare(uVar8 & 0xffffffff);
if (uVar7 == uVar8) {
*(int8 *)(this + uVar7 * 0x208) = 0;
}
else {
uVar4 = uVar4 | uVar3;
if (((((uint)uVar8 ^ (uint)uVar7) & 7) == 0) ||
(uVar2 = (uint)(uVar8 >> 3) & 0x1fffffff, uVar6 == uVar2)) {
uVar3 = attacks::rook(uVar7 & 0xffffffff,uVar4);
uVar4 = attacks::rook(uVar8 & 0xffffffff,uVar4);
}
else {
uVar5 = (uint)uVar8 & 7;
if (((uVar6 - uVar1) + 7 != (uVar2 - uVar5) + 7) && (uVar1 + uVar6 != uVar2 + uVar5))
goto LAB_00102931;
uVar3 = attacks::bishop(uVar7 & 0xffffffff,uVar4);
uVar4 = attacks::bishop(uVar8 & 0xffffffff,uVar4);
}
*(ulong *)(local_48 + uVar8 * 8) = uVar4 & uVar3;
}
LAB_00102931:
}
uVar7 = uVar7 + 1;
local_48 = local_48 + 0x200;
} while( true );
}
|
|
19,922
|
getProcAddressGLX
|
untodesu[P]riteg/build_O1/_deps/glfw-src/src/glx_context.c
|
static GLFWglproc getProcAddressGLX(const char* procname)
{
if (_glfw.glx.GetProcAddress)
return _glfw.glx.GetProcAddress((const GLubyte*) procname);
else if (_glfw.glx.GetProcAddressARB)
return _glfw.glx.GetProcAddressARB((const GLubyte*) procname);
else
return _glfw_dlsym(_glfw.glx.handle, procname);
}
|
O1
|
c
|
getProcAddressGLX:
movq %rdi, %rsi
leaq 0x7e0c2(%rip), %rax # 0xa4638
movq 0x207f0(%rax), %rcx
testq %rcx, %rcx
jne 0x2658e
movq 0x207f8(%rax), %rcx
testq %rcx, %rcx
je 0x26593
movq %rsi, %rdi
jmpq *%rcx
movq 0x20780(%rax), %rdi
jmp 0xc820
|
getProcAddressGLX:
mov rsi, rdi
lea rax, _glfw
mov rcx, [rax+207F0h]
test rcx, rcx
jnz short loc_2658E
mov rcx, [rax+207F8h]
test rcx, rcx
jz short loc_26593
loc_2658E:
mov rdi, rsi
jmp rcx
loc_26593:
mov rdi, [rax+20780h]
jmp _dlsym
|
long long getProcAddressGLX(long long a1)
{
long long ( *v1)(long long); // rcx
v1 = *(long long ( **)(long long))&glfw[33276];
if ( v1 )
return v1(a1);
v1 = *(long long ( **)(long long))&glfw[33278];
if ( v1 )
return v1(a1);
else
return dlsym(*(_QWORD *)&glfw[33248], a1);
}
|
getProcAddressGLX:
MOV RSI,RDI
LEA RAX,[0x1a4638]
MOV RCX,qword ptr [RAX + 0x207f0]
TEST RCX,RCX
JNZ 0x0012658e
MOV RCX,qword ptr [RAX + 0x207f8]
TEST RCX,RCX
JZ 0x00126593
LAB_0012658e:
MOV RDI,RSI
JMP RCX
LAB_00126593:
MOV RDI,qword ptr [RAX + 0x20780]
JMP 0x0010c820
|
void getProcAddressGLX(int8 param_1)
{
code *UNRECOVERED_JUMPTABLE;
UNRECOVERED_JUMPTABLE = DAT_001c4e28;
if ((DAT_001c4e28 == (code *)0x0) &&
(UNRECOVERED_JUMPTABLE = DAT_001c4e30, DAT_001c4e30 == (code *)0x0)) {
dlsym(DAT_001c4db8);
return;
}
/* WARNING: Could not recover jumptable at 0x00126591. Too many branches */
/* WARNING: Treating indirect jump as call */
(*UNRECOVERED_JUMPTABLE)(param_1);
return;
}
|
|
19,923
|
setup_key_functions
|
eloqsql/storage/maria/ma_open.c
|
static void setup_key_functions(register MARIA_KEYDEF *keyinfo)
{
if (keyinfo->key_alg == HA_KEY_ALG_RTREE)
{
#ifdef HAVE_RTREE_KEYS
keyinfo->ck_insert = maria_rtree_insert;
keyinfo->ck_delete = maria_rtree_delete;
#else
DBUG_ASSERT(0); /* maria_open should check it never happens */
#endif
}
else
{
keyinfo->ck_insert = _ma_ck_write;
keyinfo->ck_delete = _ma_ck_delete;
}
if (keyinfo->flag & HA_SPATIAL)
keyinfo->make_key= _ma_sp_make_key;
else
keyinfo->make_key= _ma_make_key;
if (keyinfo->flag & HA_BINARY_PACK_KEY)
{ /* Simple prefix compression */
keyinfo->bin_search= _ma_seq_search;
keyinfo->get_key= _ma_get_binary_pack_key;
keyinfo->skip_key= _ma_skip_binary_pack_key;
keyinfo->pack_key= _ma_calc_bin_pack_key_length;
keyinfo->store_key= _ma_store_bin_pack_key;
}
else if (keyinfo->flag & HA_VAR_LENGTH_KEY)
{
keyinfo->get_key= _ma_get_pack_key;
keyinfo->skip_key= _ma_skip_pack_key;
if (keyinfo->seg[0].flag & HA_PACK_KEY)
{ /* Prefix compression */
/*
_ma_prefix_search() compares end-space against ASCII blank (' ').
It cannot be used for character sets, that do not encode the
blank character like ASCII does. UCS2 is an example. All
character sets with a fixed width > 1 or a mimimum width > 1
cannot represent blank like ASCII does. In these cases we have
to use _ma_seq_search() for the search.
*/
if (!keyinfo->seg->charset || use_strnxfrm(keyinfo->seg->charset) ||
(keyinfo->seg->flag & HA_NULL_PART) ||
keyinfo->seg->charset->mbminlen > 1)
keyinfo->bin_search= _ma_seq_search;
else
keyinfo->bin_search= _ma_prefix_search;
keyinfo->pack_key= _ma_calc_var_pack_key_length;
keyinfo->store_key= _ma_store_var_pack_key;
}
else
{
keyinfo->bin_search= _ma_seq_search;
keyinfo->pack_key= _ma_calc_var_key_length; /* Variable length key */
keyinfo->store_key= _ma_store_static_key;
}
}
else
{
keyinfo->bin_search= _ma_bin_search;
keyinfo->get_key= _ma_get_static_key;
keyinfo->skip_key= _ma_skip_static_key;
keyinfo->pack_key= _ma_calc_static_key_length;
keyinfo->store_key= _ma_store_static_key;
}
/* set keyinfo->write_comp_flag */
if (keyinfo->flag & HA_SORT_ALLOWS_SAME)
keyinfo->write_comp_flag=SEARCH_BIGGER; /* Put after same key */
else if (keyinfo->flag & ( HA_NOSAME | HA_FULLTEXT))
{
keyinfo->write_comp_flag= SEARCH_FIND | SEARCH_UPDATE; /* No duplicates */
if (keyinfo->flag & HA_NULL_ARE_EQUAL)
keyinfo->write_comp_flag|= SEARCH_NULL_ARE_EQUAL;
}
else
keyinfo->write_comp_flag= SEARCH_SAME; /* Keys in rec-pos order */
keyinfo->write_comp_flag|= SEARCH_INSERT;
return;
}
|
O0
|
c
|
setup_key_functions:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movzbl 0xa4(%rax), %eax
cmpl $0x2, %eax
jne 0x2fdfe
movq -0x8(%rbp), %rax
leaq 0x46f7d(%rip), %rcx # 0x76d60
movq %rcx, 0x100(%rax)
movq -0x8(%rbp), %rax
leaq 0x470cb(%rip), %rcx # 0x76ec0
movq %rcx, 0x108(%rax)
jmp 0x2fe22
movq -0x8(%rbp), %rax
leaq 0x32657(%rip), %rcx # 0x62460
movq %rcx, 0x100(%rax)
movq -0x8(%rbp), %rax
leaq 0x38145(%rip), %rcx # 0x67f60
movq %rcx, 0x108(%rax)
movq -0x8(%rbp), %rax
movzwl 0xa2(%rax), %eax
andl $0x400, %eax # imm = 0x400
cmpl $0x0, %eax
je 0x2fe4b
movq -0x8(%rbp), %rax
leaq 0x53f8e(%rip), %rcx # 0x83dd0
movq %rcx, 0x110(%rax)
jmp 0x2fe5d
movq -0x8(%rbp), %rax
leaq 0x10fea(%rip), %rcx # 0x40e40
movq %rcx, 0x110(%rax)
movq -0x8(%rbp), %rax
movzwl 0xa2(%rax), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0x2fecf
movq -0x8(%rbp), %rax
leaq 0x7e35(%rip), %rcx # 0x37cb0
movq %rcx, 0xd8(%rax)
movq -0x8(%rbp), %rax
leaq 0xa673(%rip), %rcx # 0x3a500
movq %rcx, 0xe0(%rax)
movq -0x8(%rbp), %rax
leaq 0xaab1(%rip), %rcx # 0x3a950
movq %rcx, 0xe8(%rax)
movq -0x8(%rbp), %rax
leaq 0xc4ef(%rip), %rcx # 0x3c3a0
movq %rcx, 0xf0(%rax)
movq -0x8(%rbp), %rax
leaq 0xcd1d(%rip), %rcx # 0x3cbe0
movq %rcx, 0xf8(%rax)
jmp 0x3005d
movq -0x8(%rbp), %rax
movzwl 0xa2(%rax), %eax
andl $0x8, %eax
cmpl $0x0, %eax
je 0x30001
movq -0x8(%rbp), %rax
leaq 0x9cdf(%rip), %rcx # 0x39bd0
movq %rcx, 0xe0(%rax)
movq -0x8(%rbp), %rax
leaq 0xa35d(%rip), %rcx # 0x3a260
movq %rcx, 0xe8(%rax)
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
movzwl 0x12(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x2ffc9
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
cmpq $0x0, (%rax)
je 0x2ff7d
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
movq (%rax), %rax
movl 0xc(%rax), %eax
andl $0x40, %eax
cmpl $0x0, %eax
jne 0x2ff7d
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
movzwl 0x12(%rax), %eax
andl $0x10, %eax
cmpl $0x0, %eax
jne 0x2ff7d
movq -0x8(%rbp), %rax
movq 0xc0(%rax), %rax
movq (%rax), %rax
cmpl $0x1, 0x98(%rax)
jbe 0x2ff91
movq -0x8(%rbp), %rax
leaq 0x7d28(%rip), %rcx # 0x37cb0
movq %rcx, 0xd8(%rax)
jmp 0x2ffa3
movq -0x8(%rbp), %rax
leaq 0x7fd4(%rip), %rcx # 0x37f70
movq %rcx, 0xd8(%rax)
movq -0x8(%rbp), %rax
leaq 0xb862(%rip), %rcx # 0x3b810
movq %rcx, 0xf0(%rax)
movq -0x8(%rbp), %rax
leaq 0xc770(%rip), %rcx # 0x3c730
movq %rcx, 0xf8(%rax)
jmp 0x2ffff
movq -0x8(%rbp), %rax
leaq 0x7cdc(%rip), %rcx # 0x37cb0
movq %rcx, 0xd8(%rax)
movq -0x8(%rbp), %rax
leaq 0xb7da(%rip), %rcx # 0x3b7c0
movq %rcx, 0xf0(%rax)
movq -0x8(%rbp), %rax
leaq 0xc6f8(%rip), %rcx # 0x3c6f0
movq %rcx, 0xf8(%rax)
jmp 0x3005b
movq -0x8(%rbp), %rax
leaq 0x7ab4(%rip), %rcx # 0x37ac0
movq %rcx, 0xd8(%rax)
movq -0x8(%rbp), %rax
leaq 0x99f2(%rip), %rcx # 0x39a10
movq %rcx, 0xe0(%rax)
movq -0x8(%rbp), %rax
leaq 0x9b10(%rip), %rcx # 0x39b40
movq %rcx, 0xe8(%rax)
movq -0x8(%rbp), %rax
leaq 0xb72e(%rip), %rcx # 0x3b770
movq %rcx, 0xf0(%rax)
movq -0x8(%rbp), %rax
leaq 0xc69c(%rip), %rcx # 0x3c6f0
movq %rcx, 0xf8(%rax)
jmp 0x3005d
movq -0x8(%rbp), %rax
movzwl 0xa2(%rax), %eax
andl $0x200, %eax # imm = 0x200
cmpl $0x0, %eax
je 0x30082
movq -0x8(%rbp), %rax
movl $0x8, 0xb4(%rax)
jmp 0x300e2
movq -0x8(%rbp), %rax
movzwl 0xa2(%rax), %eax
andl $0x81, %eax
cmpl $0x0, %eax
je 0x300d2
movq -0x8(%rbp), %rax
movl $0x41, 0xb4(%rax)
movq -0x8(%rbp), %rax
movzwl 0xa2(%rax), %eax
andl $0x800, %eax # imm = 0x800
cmpl $0x0, %eax
je 0x300d0
movq -0x8(%rbp), %rax
movl 0xb4(%rax), %ecx
orl $0x8000, %ecx # imm = 0x8000
movl %ecx, 0xb4(%rax)
jmp 0x300e0
movq -0x8(%rbp), %rax
movl $0x4, 0xb4(%rax)
jmp 0x300e2
movq -0x8(%rbp), %rax
movl 0xb4(%rax), %ecx
orl $0x20000, %ecx # imm = 0x20000
movl %ecx, 0xb4(%rax)
popq %rbp
retq
nopw (%rax,%rax)
|
setup_key_functions:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax+0A4h]
cmp eax, 2
jnz short loc_2FDFE
mov rax, [rbp+var_8]
lea rcx, maria_rtree_insert
mov [rax+100h], rcx
mov rax, [rbp+var_8]
lea rcx, maria_rtree_delete
mov [rax+108h], rcx
jmp short loc_2FE22
loc_2FDFE:
mov rax, [rbp+var_8]
lea rcx, _ma_ck_write
mov [rax+100h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_ck_delete
mov [rax+108h], rcx
loc_2FE22:
mov rax, [rbp+var_8]
movzx eax, word ptr [rax+0A2h]
and eax, 400h
cmp eax, 0
jz short loc_2FE4B
mov rax, [rbp+var_8]
lea rcx, _ma_sp_make_key
mov [rax+110h], rcx
jmp short loc_2FE5D
loc_2FE4B:
mov rax, [rbp+var_8]
lea rcx, _ma_make_key
mov [rax+110h], rcx
loc_2FE5D:
mov rax, [rbp+var_8]
movzx eax, word ptr [rax+0A2h]
and eax, 20h
cmp eax, 0
jz short loc_2FECF
mov rax, [rbp+var_8]
lea rcx, _ma_seq_search
mov [rax+0D8h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_get_binary_pack_key
mov [rax+0E0h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_skip_binary_pack_key
mov [rax+0E8h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_calc_bin_pack_key_length
mov [rax+0F0h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_store_bin_pack_key
mov [rax+0F8h], rcx
jmp loc_3005D
loc_2FECF:
mov rax, [rbp+var_8]
movzx eax, word ptr [rax+0A2h]
and eax, 8
cmp eax, 0
jz loc_30001
mov rax, [rbp+var_8]
lea rcx, _ma_get_pack_key
mov [rax+0E0h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_skip_pack_key
mov [rax+0E8h], rcx
mov rax, [rbp+var_8]
mov rax, [rax+0C0h]
movzx eax, word ptr [rax+12h]
and eax, 2
cmp eax, 0
jz loc_2FFC9
mov rax, [rbp+var_8]
mov rax, [rax+0C0h]
cmp qword ptr [rax], 0
jz short loc_2FF7D
mov rax, [rbp+var_8]
mov rax, [rax+0C0h]
mov rax, [rax]
mov eax, [rax+0Ch]
and eax, 40h
cmp eax, 0
jnz short loc_2FF7D
mov rax, [rbp+var_8]
mov rax, [rax+0C0h]
movzx eax, word ptr [rax+12h]
and eax, 10h
cmp eax, 0
jnz short loc_2FF7D
mov rax, [rbp+var_8]
mov rax, [rax+0C0h]
mov rax, [rax]
cmp dword ptr [rax+98h], 1
jbe short loc_2FF91
loc_2FF7D:
mov rax, [rbp+var_8]
lea rcx, _ma_seq_search
mov [rax+0D8h], rcx
jmp short loc_2FFA3
loc_2FF91:
mov rax, [rbp+var_8]
lea rcx, _ma_prefix_search
mov [rax+0D8h], rcx
loc_2FFA3:
mov rax, [rbp+var_8]
lea rcx, _ma_calc_var_pack_key_length
mov [rax+0F0h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_store_var_pack_key
mov [rax+0F8h], rcx
jmp short loc_2FFFF
loc_2FFC9:
mov rax, [rbp+var_8]
lea rcx, _ma_seq_search
mov [rax+0D8h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_calc_var_key_length
mov [rax+0F0h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_store_static_key
mov [rax+0F8h], rcx
loc_2FFFF:
jmp short loc_3005B
loc_30001:
mov rax, [rbp+var_8]
lea rcx, _ma_bin_search
mov [rax+0D8h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_get_static_key
mov [rax+0E0h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_skip_static_key
mov [rax+0E8h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_calc_static_key_length
mov [rax+0F0h], rcx
mov rax, [rbp+var_8]
lea rcx, _ma_store_static_key
mov [rax+0F8h], rcx
loc_3005B:
jmp short $+2
loc_3005D:
mov rax, [rbp+var_8]
movzx eax, word ptr [rax+0A2h]
and eax, 200h
cmp eax, 0
jz short loc_30082
mov rax, [rbp+var_8]
mov dword ptr [rax+0B4h], 8
jmp short loc_300E2
loc_30082:
mov rax, [rbp+var_8]
movzx eax, word ptr [rax+0A2h]
and eax, 81h
cmp eax, 0
jz short loc_300D2
mov rax, [rbp+var_8]
mov dword ptr [rax+0B4h], 41h ; 'A'
mov rax, [rbp+var_8]
movzx eax, word ptr [rax+0A2h]
and eax, 800h
cmp eax, 0
jz short loc_300D0
mov rax, [rbp+var_8]
mov ecx, [rax+0B4h]
or ecx, 8000h
mov [rax+0B4h], ecx
loc_300D0:
jmp short loc_300E0
loc_300D2:
mov rax, [rbp+var_8]
mov dword ptr [rax+0B4h], 4
loc_300E0:
jmp short $+2
loc_300E2:
mov rax, [rbp+var_8]
mov ecx, [rax+0B4h]
or ecx, 20000h
mov [rax+0B4h], ecx
pop rbp
retn
|
long long setup_key_functions(long long a1)
{
long long result; // rax
if ( *(_BYTE *)(a1 + 164) == 2 )
{
*(_QWORD *)(a1 + 256) = maria_rtree_insert;
*(_QWORD *)(a1 + 264) = maria_rtree_delete;
}
else
{
*(_QWORD *)(a1 + 256) = ma_ck_write;
*(_QWORD *)(a1 + 264) = ma_ck_delete;
}
if ( (*(_WORD *)(a1 + 162) & 0x400) != 0 )
*(_QWORD *)(a1 + 272) = ma_sp_make_key;
else
*(_QWORD *)(a1 + 272) = ma_make_key;
if ( (*(_WORD *)(a1 + 162) & 0x20) != 0 )
{
*(_QWORD *)(a1 + 216) = ma_seq_search;
*(_QWORD *)(a1 + 224) = ma_get_binary_pack_key;
*(_QWORD *)(a1 + 232) = ma_skip_binary_pack_key;
*(_QWORD *)(a1 + 240) = ma_calc_bin_pack_key_length;
*(_QWORD *)(a1 + 248) = ma_store_bin_pack_key;
}
else if ( (*(_WORD *)(a1 + 162) & 8) != 0 )
{
*(_QWORD *)(a1 + 224) = ma_get_pack_key;
*(_QWORD *)(a1 + 232) = ma_skip_pack_key;
if ( (*(_WORD *)(*(_QWORD *)(a1 + 192) + 18LL) & 2) != 0 )
{
if ( !**(_QWORD **)(a1 + 192)
|| (*(_DWORD *)(**(_QWORD **)(a1 + 192) + 12LL) & 0x40) != 0
|| (*(_WORD *)(*(_QWORD *)(a1 + 192) + 18LL) & 0x10) != 0
|| *(_DWORD *)(**(_QWORD **)(a1 + 192) + 152LL) > 1u )
{
*(_QWORD *)(a1 + 216) = ma_seq_search;
}
else
{
*(_QWORD *)(a1 + 216) = ma_prefix_search;
}
*(_QWORD *)(a1 + 240) = ma_calc_var_pack_key_length;
*(_QWORD *)(a1 + 248) = ma_store_var_pack_key;
}
else
{
*(_QWORD *)(a1 + 216) = ma_seq_search;
*(_QWORD *)(a1 + 240) = ma_calc_var_key_length;
*(_QWORD *)(a1 + 248) = ma_store_static_key;
}
}
else
{
*(_QWORD *)(a1 + 216) = ma_bin_search;
*(_QWORD *)(a1 + 224) = ma_get_static_key;
*(_QWORD *)(a1 + 232) = ma_skip_static_key;
*(_QWORD *)(a1 + 240) = ma_calc_static_key_length;
*(_QWORD *)(a1 + 248) = ma_store_static_key;
}
if ( (*(_WORD *)(a1 + 162) & 0x200) != 0 )
{
*(_DWORD *)(a1 + 180) = 8;
}
else if ( (*(_WORD *)(a1 + 162) & 0x81) != 0 )
{
*(_DWORD *)(a1 + 180) = 65;
if ( (*(_WORD *)(a1 + 162) & 0x800) != 0 )
*(_DWORD *)(a1 + 180) |= 0x8000u;
}
else
{
*(_DWORD *)(a1 + 180) = 4;
}
result = a1;
*(_DWORD *)(a1 + 180) |= 0x20000u;
return result;
}
|
setup_key_functions:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX + 0xa4]
CMP EAX,0x2
JNZ 0x0012fdfe
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x176d60]
MOV qword ptr [RAX + 0x100],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x176ec0]
MOV qword ptr [RAX + 0x108],RCX
JMP 0x0012fe22
LAB_0012fdfe:
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x162460]
MOV qword ptr [RAX + 0x100],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x167f60]
MOV qword ptr [RAX + 0x108],RCX
LAB_0012fe22:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,word ptr [RAX + 0xa2]
AND EAX,0x400
CMP EAX,0x0
JZ 0x0012fe4b
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x183dd0]
MOV qword ptr [RAX + 0x110],RCX
JMP 0x0012fe5d
LAB_0012fe4b:
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x140e40]
MOV qword ptr [RAX + 0x110],RCX
LAB_0012fe5d:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,word ptr [RAX + 0xa2]
AND EAX,0x20
CMP EAX,0x0
JZ 0x0012fecf
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x137cb0]
MOV qword ptr [RAX + 0xd8],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13a500]
MOV qword ptr [RAX + 0xe0],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13a950]
MOV qword ptr [RAX + 0xe8],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13c3a0]
MOV qword ptr [RAX + 0xf0],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13cbe0]
MOV qword ptr [RAX + 0xf8],RCX
JMP 0x0013005d
LAB_0012fecf:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,word ptr [RAX + 0xa2]
AND EAX,0x8
CMP EAX,0x0
JZ 0x00130001
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x139bd0]
MOV qword ptr [RAX + 0xe0],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13a260]
MOV qword ptr [RAX + 0xe8],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xc0]
MOVZX EAX,word ptr [RAX + 0x12]
AND EAX,0x2
CMP EAX,0x0
JZ 0x0012ffc9
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xc0]
CMP qword ptr [RAX],0x0
JZ 0x0012ff7d
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xc0]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX + 0xc]
AND EAX,0x40
CMP EAX,0x0
JNZ 0x0012ff7d
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xc0]
MOVZX EAX,word ptr [RAX + 0x12]
AND EAX,0x10
CMP EAX,0x0
JNZ 0x0012ff7d
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xc0]
MOV RAX,qword ptr [RAX]
CMP dword ptr [RAX + 0x98],0x1
JBE 0x0012ff91
LAB_0012ff7d:
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x137cb0]
MOV qword ptr [RAX + 0xd8],RCX
JMP 0x0012ffa3
LAB_0012ff91:
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x137f70]
MOV qword ptr [RAX + 0xd8],RCX
LAB_0012ffa3:
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13b810]
MOV qword ptr [RAX + 0xf0],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13c730]
MOV qword ptr [RAX + 0xf8],RCX
JMP 0x0012ffff
LAB_0012ffc9:
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x137cb0]
MOV qword ptr [RAX + 0xd8],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13b7c0]
MOV qword ptr [RAX + 0xf0],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13c6f0]
MOV qword ptr [RAX + 0xf8],RCX
LAB_0012ffff:
JMP 0x0013005b
LAB_00130001:
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x137ac0]
MOV qword ptr [RAX + 0xd8],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x139a10]
MOV qword ptr [RAX + 0xe0],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x139b40]
MOV qword ptr [RAX + 0xe8],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13b770]
MOV qword ptr [RAX + 0xf0],RCX
MOV RAX,qword ptr [RBP + -0x8]
LEA RCX,[0x13c6f0]
MOV qword ptr [RAX + 0xf8],RCX
LAB_0013005b:
JMP 0x0013005d
LAB_0013005d:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,word ptr [RAX + 0xa2]
AND EAX,0x200
CMP EAX,0x0
JZ 0x00130082
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0xb4],0x8
JMP 0x001300e2
LAB_00130082:
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,word ptr [RAX + 0xa2]
AND EAX,0x81
CMP EAX,0x0
JZ 0x001300d2
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0xb4],0x41
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,word ptr [RAX + 0xa2]
AND EAX,0x800
CMP EAX,0x0
JZ 0x001300d0
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0xb4]
OR ECX,0x8000
MOV dword ptr [RAX + 0xb4],ECX
LAB_001300d0:
JMP 0x001300e0
LAB_001300d2:
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0xb4],0x4
LAB_001300e0:
JMP 0x001300e2
LAB_001300e2:
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0xb4]
OR ECX,0x20000
MOV dword ptr [RAX + 0xb4],ECX
POP RBP
RET
|
void setup_key_functions(long param_1)
{
if (*(char *)(param_1 + 0xa4) == '\x02') {
*(code **)(param_1 + 0x100) = maria_rtree_insert;
*(code **)(param_1 + 0x108) = maria_rtree_delete;
}
else {
*(code **)(param_1 + 0x100) = _ma_ck_write;
*(code **)(param_1 + 0x108) = _ma_ck_delete;
}
if ((*(ushort *)(param_1 + 0xa2) & 0x400) == 0) {
*(code **)(param_1 + 0x110) = _ma_make_key;
}
else {
*(code **)(param_1 + 0x110) = _ma_sp_make_key;
}
if ((*(ushort *)(param_1 + 0xa2) & 0x20) == 0) {
if ((*(ushort *)(param_1 + 0xa2) & 8) == 0) {
*(code **)(param_1 + 0xd8) = _ma_bin_search;
*(code **)(param_1 + 0xe0) = _ma_get_static_key;
*(code **)(param_1 + 0xe8) = _ma_skip_static_key;
*(code **)(param_1 + 0xf0) = _ma_calc_static_key_length;
*(code **)(param_1 + 0xf8) = _ma_store_static_key;
}
else {
*(code **)(param_1 + 0xe0) = _ma_get_pack_key;
*(code **)(param_1 + 0xe8) = _ma_skip_pack_key;
if ((*(ushort *)(*(long *)(param_1 + 0xc0) + 0x12) & 2) == 0) {
*(code **)(param_1 + 0xd8) = _ma_seq_search;
*(code **)(param_1 + 0xf0) = _ma_calc_var_key_length;
*(code **)(param_1 + 0xf8) = _ma_store_static_key;
}
else {
if ((((**(long **)(param_1 + 0xc0) == 0) ||
((*(uint *)(**(long **)(param_1 + 0xc0) + 0xc) & 0x40) != 0)) ||
((*(ushort *)(*(long *)(param_1 + 0xc0) + 0x12) & 0x10) != 0)) ||
(1 < *(uint *)(**(long **)(param_1 + 0xc0) + 0x98))) {
*(code **)(param_1 + 0xd8) = _ma_seq_search;
}
else {
*(code **)(param_1 + 0xd8) = _ma_prefix_search;
}
*(code **)(param_1 + 0xf0) = _ma_calc_var_pack_key_length;
*(code **)(param_1 + 0xf8) = _ma_store_var_pack_key;
}
}
}
else {
*(code **)(param_1 + 0xd8) = _ma_seq_search;
*(code **)(param_1 + 0xe0) = _ma_get_binary_pack_key;
*(code **)(param_1 + 0xe8) = _ma_skip_binary_pack_key;
*(code **)(param_1 + 0xf0) = _ma_calc_bin_pack_key_length;
*(code **)(param_1 + 0xf8) = _ma_store_bin_pack_key;
}
if ((*(ushort *)(param_1 + 0xa2) & 0x200) == 0) {
if ((*(ushort *)(param_1 + 0xa2) & 0x81) == 0) {
*(int4 *)(param_1 + 0xb4) = 4;
}
else {
*(int4 *)(param_1 + 0xb4) = 0x41;
if ((*(ushort *)(param_1 + 0xa2) & 0x800) != 0) {
*(uint *)(param_1 + 0xb4) = *(uint *)(param_1 + 0xb4) | 0x8000;
}
}
}
else {
*(int4 *)(param_1 + 0xb4) = 8;
}
*(uint *)(param_1 + 0xb4) = *(uint *)(param_1 + 0xb4) | 0x20000;
return;
}
|
|
19,924
|
my_casedn_8bit
|
eloqsql/strings/ctype-simple.c
|
size_t my_casedn_8bit(CHARSET_INFO * cs, const char *src, size_t srclen,
char *dst, size_t dstlen __attribute__((unused)))
{
const char *end= src + srclen;
register const uchar *map=cs->to_lower;
DBUG_ASSERT(srclen <= dstlen);
for ( ; src != end ; src++)
*dst++= (char) map[(uchar) *src];
return srclen;
}
|
O0
|
c
|
my_casedn_8bit:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x10(%rbp), %rax
addq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq 0x48(%rax), %rax
movq %rax, -0x38(%rbp)
jmp 0x4bca2
jmp 0x4bca4
movq -0x10(%rbp), %rax
cmpq -0x30(%rbp), %rax
je 0x4bcdb
movq -0x38(%rbp), %rax
movq -0x10(%rbp), %rcx
movzbl (%rcx), %ecx
movb (%rax,%rcx), %cl
movq -0x20(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x20(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x4bca4
movq -0x18(%rbp), %rax
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
my_casedn_8bit:
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_28], r8
mov rax, [rbp+var_10]
add rax, [rbp+var_18]
mov [rbp+var_30], rax
mov rax, [rbp+var_8]
mov rax, [rax+48h]
mov [rbp+var_38], rax
jmp short $+2
loc_4BCA2:
jmp short $+2
loc_4BCA4:
mov rax, [rbp+var_10]
cmp rax, [rbp+var_30]
jz short loc_4BCDB
mov rax, [rbp+var_38]
mov rcx, [rbp+var_10]
movzx ecx, byte ptr [rcx]
mov cl, [rax+rcx]
mov rax, [rbp+var_20]
mov rdx, rax
add rdx, 1
mov [rbp+var_20], rdx
mov [rax], cl
mov rax, [rbp+var_10]
add rax, 1
mov [rbp+var_10], rax
jmp short loc_4BCA4
loc_4BCDB:
mov rax, [rbp+var_18]
pop rbp
retn
|
long long my_casedn_8bit(long long a1, unsigned __int8 *a2, long long a3, _BYTE *a4)
{
_BYTE *v4; // rax
long long v6; // [rsp+0h] [rbp-38h]
unsigned __int8 *v8; // [rsp+28h] [rbp-10h]
v8 = a2;
v6 = *(_QWORD *)(a1 + 72);
while ( v8 != &a2[a3] )
{
v4 = a4++;
*v4 = *(_BYTE *)(v6 + *v8++);
}
return a3;
}
|
my_casedn_8bit:
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],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x48]
MOV qword ptr [RBP + -0x38],RAX
JMP 0x0014bca2
LAB_0014bca2:
JMP 0x0014bca4
LAB_0014bca4:
MOV RAX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RBP + -0x30]
JZ 0x0014bcdb
MOV RAX,qword ptr [RBP + -0x38]
MOV RCX,qword ptr [RBP + -0x10]
MOVZX ECX,byte ptr [RCX]
MOV CL,byte ptr [RAX + RCX*0x1]
MOV RAX,qword ptr [RBP + -0x20]
MOV RDX,RAX
ADD RDX,0x1
MOV qword ptr [RBP + -0x20],RDX
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x1
MOV qword ptr [RBP + -0x10],RAX
JMP 0x0014bca4
LAB_0014bcdb:
MOV RAX,qword ptr [RBP + -0x18]
POP RBP
RET
|
long my_casedn_8bit(long param_1,byte *param_2,long param_3,int1 *param_4)
{
long lVar1;
int1 *local_28;
byte *local_18;
lVar1 = *(long *)(param_1 + 0x48);
local_28 = param_4;
for (local_18 = param_2; local_18 != param_2 + param_3; local_18 = local_18 + 1) {
*local_28 = *(int1 *)(lVar1 + (ulong)*local_18);
local_28 = local_28 + 1;
}
return param_3;
}
|
|
19,925
|
ma_control_file_write_and_force
|
eloqsql/storage/maria/ma_control_file.c
|
int ma_control_file_write_and_force(LSN last_checkpoint_lsn_arg,
uint32 last_logno_arg,
TrID max_trid_arg,
uint8 recovery_failures_arg)
{
uchar buffer[CF_MAX_SIZE];
uint32 sum;
my_bool no_need_sync;
DBUG_ENTER("ma_control_file_write_and_force");
/*
We don't need to sync if this is just an increase of
recovery_failures: it's even good if that counter is not increased on disk
in case of power or hardware failure (less false positives when removing
logs).
*/
no_need_sync= ((last_checkpoint_lsn == last_checkpoint_lsn_arg) &&
(last_logno == last_logno_arg) &&
(max_trid_in_control_file == max_trid_arg) &&
(recovery_failures_arg > 0));
if (control_file_fd < 0)
DBUG_RETURN(1);
#ifndef DBUG_OFF
if (maria_multi_threaded)
translog_lock_handler_assert_owner();
#endif
lsn_store(buffer + CF_LSN_OFFSET, last_checkpoint_lsn_arg);
int4store(buffer + CF_FILENO_OFFSET, last_logno_arg);
transid_store(buffer + CF_MAX_TRID_OFFSET, max_trid_arg);
(buffer + CF_RECOV_FAIL_OFFSET)[0]= recovery_failures_arg;
if (cf_changeable_size > CF_CHANGEABLE_TOTAL_SIZE)
{
/*
More room than needed for us. Must be a newer version. Clear part which
we cannot maintain, so that any future version notices we didn't
maintain its extra data.
*/
uint zeroed= cf_changeable_size - CF_CHANGEABLE_TOTAL_SIZE;
char msg[150];
bzero(buffer + CF_CHANGEABLE_TOTAL_SIZE, zeroed);
my_snprintf(msg, sizeof(msg),
"Control file must be from a newer version; zero-ing out %u"
" unknown bytes in control file at offset %u", zeroed,
cf_changeable_size + cf_create_time_size);
ma_message_no_user(ME_WARNING, msg);
}
else
{
/* not enough room for what we need to store: enlarge */
cf_changeable_size= CF_CHANGEABLE_TOTAL_SIZE;
}
/* Note that the create-time portion is not touched */
/* Checksum is stored first */
compile_time_assert(CF_CHECKSUM_OFFSET == 0);
sum= my_checksum(0, buffer + CF_CHECKSUM_SIZE,
cf_changeable_size - CF_CHECKSUM_SIZE);
int4store(buffer, sum);
if (my_pwrite(control_file_fd, buffer, cf_changeable_size,
cf_create_time_size, MYF(MY_FNABP | MY_WME)) ||
(!no_need_sync && mysql_file_sync(control_file_fd, MYF(MY_WME))))
DBUG_RETURN(1);
last_checkpoint_lsn= last_checkpoint_lsn_arg;
last_logno= last_logno_arg;
max_trid_in_control_file= max_trid_arg;
recovery_failures= recovery_failures_arg;
cf_changeable_size= CF_CHANGEABLE_TOTAL_SIZE; /* no more warning */
DBUG_RETURN(0);
}
|
O0
|
c
|
ma_control_file_write_and_force:
pushq %rbp
movq %rsp, %rbp
subq $0x310, %rsp # imm = 0x310
movb %cl, %al
movq %fs:0x28, %rcx
movq %rcx, -0x8(%rbp)
movq %rdi, -0x2c0(%rbp)
movl %esi, -0x2c4(%rbp)
movq %rdx, -0x2d0(%rbp)
movb %al, -0x2d1(%rbp)
movq 0x3feafd(%rip), %rcx # 0x48a788
xorl %eax, %eax
cmpq -0x2c0(%rbp), %rcx
movb %al, -0x309(%rbp)
jne 0x8bcdd
movl 0x3feaee(%rip), %ecx # 0x48a790
xorl %eax, %eax
cmpl -0x2c4(%rbp), %ecx
movb %al, -0x309(%rbp)
jne 0x8bcdd
movq 0x3feadf(%rip), %rcx # 0x48a798
xorl %eax, %eax
cmpq -0x2d0(%rbp), %rcx
movb %al, -0x309(%rbp)
jne 0x8bcdd
movzbl -0x2d1(%rbp), %eax
cmpl $0x0, %eax
setg %al
movb %al, -0x309(%rbp)
movb -0x309(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x2d9(%rbp)
cmpl $0x0, 0x243ecb(%rip) # 0x2cfbc0
jge 0x8bd08
jmp 0x8bcf9
movl $0x1, -0x2b4(%rbp)
jmp 0x8bf68
jmp 0x8bd0a
jmp 0x8bd0c
movq -0x2c0(%rbp), %rax
sarq $0x20, %rax
movb %al, -0x20c(%rbp)
movq -0x2c0(%rbp), %rax
sarq $0x20, %rax
shrl $0x8, %eax
movb %al, -0x20b(%rbp)
movq -0x2c0(%rbp), %rax
sarq $0x20, %rax
shrl $0x10, %eax
movb %al, -0x20a(%rbp)
jmp 0x8bd47
leaq -0x210(%rbp), %rax
addq $0x4, %rax
addq $0x3, %rax
movq %rax, -0x2e8(%rbp)
movabsq $0xffffffff, %rax # imm = 0xFFFFFFFF
andq -0x2c0(%rbp), %rax
movl %eax, %ecx
movq -0x2e8(%rbp), %rax
movl %ecx, (%rax)
jmp 0x8bd7b
jmp 0x8bd7d
leaq -0x210(%rbp), %rax
addq $0xb, %rax
movq %rax, -0x2f0(%rbp)
movl -0x2c4(%rbp), %ecx
movq -0x2f0(%rbp), %rax
movl %ecx, (%rax)
jmp 0x8bda0
leaq -0x210(%rbp), %rax
addq $0xf, %rax
movq %rax, -0x2f8(%rbp)
movq -0x2d0(%rbp), %rax
movl %eax, %ecx
movq -0x2f8(%rbp), %rax
movl %ecx, (%rax)
movq -0x2d0(%rbp), %rax
shrq $0x20, %rax
movw %ax, %cx
movq -0x2f8(%rbp), %rax
movw %cx, 0x4(%rax)
movb -0x2d1(%rbp), %al
movb %al, -0x1fb(%rbp)
cmpl $0x16, 0x3fe9b8(%rip) # 0x48a7a8
jbe 0x8be6a
movl 0x3fe9b0(%rip), %eax # 0x48a7a8
subl $0x16, %eax
movl %eax, -0x2fc(%rbp)
leaq -0x210(%rbp), %rdi
addq $0x16, %rdi
movl -0x2fc(%rbp), %eax
movl %eax, %edx
xorl %esi, %esi
callq 0x2a2b0
leaq -0x2b0(%rbp), %rdi
movl -0x2fc(%rbp), %ecx
movl 0x3fe979(%rip), %r8d # 0x48a7a8
addl 0x3fe96e(%rip), %r8d # 0x48a7a4
movl $0x96, %esi
leaq 0xd692d(%rip), %rdx # 0x16276f
movb $0x0, %al
callq 0x15cc50
leaq -0x2b0(%rbp), %rcx
movl $0xa8, %edi
leaq 0xd6979(%rip), %rsi # 0x1627d5
movl $0x800, %edx # imm = 0x800
movb $0x0, %al
callq 0xfa710
jmp 0x8be74
movl $0x16, 0x3fe934(%rip) # 0x48a7a8
jmp 0x8be76
jmp 0x8be78
leaq -0x210(%rbp), %rsi
addq $0x4, %rsi
movl 0x3fe91f(%rip), %eax # 0x48a7a8
subl $0x4, %eax
movl %eax, %eax
movl %eax, %edx
xorl %edi, %edi
callq 0x111b70
movl %eax, -0x2d8(%rbp)
leaq -0x210(%rbp), %rax
movq %rax, -0x308(%rbp)
movl -0x2d8(%rbp), %ecx
movq -0x308(%rbp), %rax
movl %ecx, (%rax)
movl 0x243d00(%rip), %edi # 0x2cfbc0
leaq -0x210(%rbp), %rsi
movl 0x3fe8db(%rip), %eax # 0x48a7a8
movl %eax, %edx
movl 0x3fe8cf(%rip), %eax # 0x48a7a4
movl %eax, %ecx
movl $0x12, %r8d
callq 0x1033a0
cmpq $0x0, %rax
jne 0x8bf12
cmpb $0x0, -0x2d9(%rbp)
jne 0x8bf20
movl 0x243cc9(%rip), %edx # 0x2cfbc0
leaq 0xd6618(%rip), %rdi # 0x162516
movl $0x22c, %esi # imm = 0x22C
movl $0x10, %ecx
callq 0x8bfa0
cmpl $0x0, %eax
je 0x8bf20
jmp 0x8bf14
movl $0x1, -0x2b4(%rbp)
jmp 0x8bf68
movq -0x2c0(%rbp), %rax
movq %rax, 0x3fe85a(%rip) # 0x48a788
movl -0x2c4(%rbp), %eax
movl %eax, 0x3fe856(%rip) # 0x48a790
movq -0x2d0(%rbp), %rax
movq %rax, 0x3fe850(%rip) # 0x48a798
movb -0x2d1(%rbp), %al
movb %al, 0x3fe84c(%rip) # 0x48a7a0
movl $0x16, 0x3fe84a(%rip) # 0x48a7a8
movl $0x0, -0x2b4(%rbp)
movl -0x2b4(%rbp), %eax
movl %eax, -0x310(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x8bf95
movl -0x310(%rbp), %eax
addq $0x310, %rsp # imm = 0x310
popq %rbp
retq
callq 0x2a260
nopw (%rax,%rax)
|
ma_control_file_write_and_force:
push rbp
mov rbp, rsp
sub rsp, 310h
mov al, cl
mov rcx, fs:28h
mov [rbp+var_8], rcx
mov [rbp+var_2C0], rdi
mov [rbp+var_2C4], esi
mov [rbp+var_2D0], rdx
mov [rbp+var_2D1], al
mov rcx, cs:last_checkpoint_lsn
xor eax, eax
cmp rcx, [rbp+var_2C0]
mov [rbp+var_309], al
jnz short loc_8BCDD
mov ecx, cs:last_logno
xor eax, eax
cmp ecx, [rbp+var_2C4]
mov [rbp+var_309], al
jnz short loc_8BCDD
mov rcx, cs:max_trid_in_control_file
xor eax, eax
cmp rcx, [rbp+var_2D0]
mov [rbp+var_309], al
jnz short loc_8BCDD
movzx eax, [rbp+var_2D1]
cmp eax, 0
setnle al
mov [rbp+var_309], al
loc_8BCDD:
mov al, [rbp+var_309]
and al, 1
movzx eax, al
mov [rbp+var_2D9], al
cmp cs:control_file_fd, 0
jge short loc_8BD08
jmp short $+2
loc_8BCF9:
mov [rbp+var_2B4], 1
jmp loc_8BF68
loc_8BD08:
jmp short $+2
loc_8BD0A:
jmp short $+2
loc_8BD0C:
mov rax, [rbp+var_2C0]
sar rax, 20h
mov [rbp+var_20C], al
mov rax, [rbp+var_2C0]
sar rax, 20h
shr eax, 8
mov [rbp+var_20B], al
mov rax, [rbp+var_2C0]
sar rax, 20h
shr eax, 10h
mov [rbp+var_20A], al
jmp short $+2
loc_8BD47:
lea rax, [rbp+var_210]
add rax, 4
add rax, 3
mov [rbp+var_2E8], rax
mov rax, 0FFFFFFFFh
and rax, [rbp+var_2C0]
mov ecx, eax
mov rax, [rbp+var_2E8]
mov [rax], ecx
jmp short $+2
loc_8BD7B:
jmp short $+2
loc_8BD7D:
lea rax, [rbp+var_210]
add rax, 0Bh
mov [rbp+var_2F0], rax
mov ecx, [rbp+var_2C4]
mov rax, [rbp+var_2F0]
mov [rax], ecx
jmp short $+2
loc_8BDA0:
lea rax, [rbp+var_210]
add rax, 0Fh
mov [rbp+var_2F8], rax
mov rax, [rbp+var_2D0]
mov ecx, eax
mov rax, [rbp+var_2F8]
mov [rax], ecx
mov rax, [rbp+var_2D0]
shr rax, 20h
mov cx, ax
mov rax, [rbp+var_2F8]
mov [rax+4], cx
mov al, [rbp+var_2D1]
mov [rbp+var_1FB], al
cmp cs:cf_changeable_size, 16h
jbe short loc_8BE6A
mov eax, cs:cf_changeable_size
sub eax, 16h
mov [rbp+var_2FC], eax
lea rdi, [rbp+var_210]
add rdi, 16h
mov eax, [rbp+var_2FC]
mov edx, eax
xor esi, esi
call _memset
lea rdi, [rbp+var_2B0]
mov ecx, [rbp+var_2FC]
mov r8d, cs:cf_changeable_size
add r8d, cs:cf_create_time_size
mov esi, 96h
lea rdx, aControlFileMus; "Control file must be from a newer versi"...
mov al, 0
call my_snprintf
lea rcx, [rbp+var_2B0]
mov edi, 0A8h
lea rsi, aAriaEngineS; "Aria engine: %s"
mov edx, 800h
mov al, 0
call my_printf_error
jmp short loc_8BE74
loc_8BE6A:
mov cs:cf_changeable_size, 16h
loc_8BE74:
jmp short $+2
loc_8BE76:
jmp short $+2
loc_8BE78:
lea rsi, [rbp+var_210]
add rsi, 4
mov eax, cs:cf_changeable_size
sub eax, 4
mov eax, eax
mov edx, eax
xor edi, edi
call my_checksum
mov [rbp+var_2D8], eax
lea rax, [rbp+var_210]
mov [rbp+var_308], rax
mov ecx, [rbp+var_2D8]
mov rax, [rbp+var_308]
mov [rax], ecx
mov edi, cs:control_file_fd
lea rsi, [rbp+var_210]
mov eax, cs:cf_changeable_size
mov edx, eax
mov eax, cs:cf_create_time_size
mov ecx, eax
mov r8d, 12h
call my_pwrite
cmp rax, 0
jnz short loc_8BF12
cmp [rbp+var_2D9], 0
jnz short loc_8BF20
mov edx, cs:control_file_fd
lea rdi, aWorkspaceLlm4b_16; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 22Ch
mov ecx, 10h
call inline_mysql_file_sync_3
cmp eax, 0
jz short loc_8BF20
loc_8BF12:
jmp short $+2
loc_8BF14:
mov [rbp+var_2B4], 1
jmp short loc_8BF68
loc_8BF20:
mov rax, [rbp+var_2C0]
mov cs:last_checkpoint_lsn, rax
mov eax, [rbp+var_2C4]
mov cs:last_logno, eax
mov rax, [rbp+var_2D0]
mov cs:max_trid_in_control_file, rax
mov al, [rbp+var_2D1]
mov cs:recovery_failures, al
mov cs:cf_changeable_size, 16h
mov [rbp+var_2B4], 0
loc_8BF68:
mov eax, [rbp+var_2B4]
mov [rbp+var_310], eax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_8BF95
mov eax, [rbp+var_310]
add rsp, 310h
pop rbp
retn
loc_8BF95:
call ___stack_chk_fail
|
long long ma_control_file_write_and_force(long long a1, int a2, long long a3, char a4)
{
int v4; // r9d
int v5; // r8d
int v6; // r9d
bool v8; // [rsp+7h] [rbp-309h]
int v9; // [rsp+14h] [rbp-2FCh]
_BYTE v13[160]; // [rsp+60h] [rbp-2B0h] BYREF
int v14; // [rsp+100h] [rbp-210h] BYREF
__int16 v15; // [rsp+104h] [rbp-20Ch] BYREF
char v16; // [rsp+106h] [rbp-20Ah]
int v17; // [rsp+107h] [rbp-209h]
int v18; // [rsp+10Bh] [rbp-205h]
int v19; // [rsp+10Fh] [rbp-201h]
__int16 v20; // [rsp+113h] [rbp-1FDh]
char v21; // [rsp+115h] [rbp-1FBh]
_BYTE v22[506]; // [rsp+116h] [rbp-1FAh] BYREF
*(_QWORD *)&v22[498] = __readfsqword(0x28u);
v8 = 0;
if ( last_checkpoint_lsn == a1 )
{
v8 = 0;
if ( last_logno == a2 )
{
v8 = 0;
if ( max_trid_in_control_file == a3 )
v8 = a4 != 0;
}
}
if ( control_file_fd >= 0 )
{
v15 = WORD2(a1);
v16 = BYTE6(a1);
v17 = a1;
v18 = a2;
v19 = a3;
v20 = WORD2(a3);
v21 = a4;
if ( (unsigned int)cf_changeable_size <= 0x16 )
{
cf_changeable_size = 22;
}
else
{
v9 = cf_changeable_size - 22;
memset(v22, 0LL, (unsigned int)(cf_changeable_size - 22));
my_snprintf(
(unsigned int)v13,
150,
(unsigned int)"Control file must be from a newer version; zero-ing out %u unknown bytes in control file at offset %u",
v9,
cf_create_time_size + cf_changeable_size,
v4);
my_printf_error(168, (unsigned int)"Aria engine: %s", 2048, (unsigned int)v13, v5, v6);
}
v14 = my_checksum(0LL, &v15, (unsigned int)(cf_changeable_size - 4));
if ( my_pwrite(
(unsigned int)control_file_fd,
&v14,
(unsigned int)cf_changeable_size,
(unsigned int)cf_create_time_size,
18LL)
|| !v8
&& (unsigned int)inline_mysql_file_sync_3(
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_control_file.c",
556LL,
(unsigned int)control_file_fd,
16LL) )
{
return 1;
}
else
{
last_checkpoint_lsn = a1;
last_logno = a2;
max_trid_in_control_file = a3;
recovery_failures = a4;
cf_changeable_size = 22;
return 0;
}
}
else
{
return 1;
}
}
|
ma_control_file_write_and_force:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x310
MOV AL,CL
MOV RCX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RCX
MOV qword ptr [RBP + -0x2c0],RDI
MOV dword ptr [RBP + -0x2c4],ESI
MOV qword ptr [RBP + -0x2d0],RDX
MOV byte ptr [RBP + -0x2d1],AL
MOV RCX,qword ptr [0x0058a788]
XOR EAX,EAX
CMP RCX,qword ptr [RBP + -0x2c0]
MOV byte ptr [RBP + -0x309],AL
JNZ 0x0018bcdd
MOV ECX,dword ptr [0x0058a790]
XOR EAX,EAX
CMP ECX,dword ptr [RBP + -0x2c4]
MOV byte ptr [RBP + -0x309],AL
JNZ 0x0018bcdd
MOV RCX,qword ptr [0x0058a798]
XOR EAX,EAX
CMP RCX,qword ptr [RBP + -0x2d0]
MOV byte ptr [RBP + -0x309],AL
JNZ 0x0018bcdd
MOVZX EAX,byte ptr [RBP + -0x2d1]
CMP EAX,0x0
SETG AL
MOV byte ptr [RBP + -0x309],AL
LAB_0018bcdd:
MOV AL,byte ptr [RBP + -0x309]
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x2d9],AL
CMP dword ptr [0x003cfbc0],0x0
JGE 0x0018bd08
JMP 0x0018bcf9
LAB_0018bcf9:
MOV dword ptr [RBP + -0x2b4],0x1
JMP 0x0018bf68
LAB_0018bd08:
JMP 0x0018bd0a
LAB_0018bd0a:
JMP 0x0018bd0c
LAB_0018bd0c:
MOV RAX,qword ptr [RBP + -0x2c0]
SAR RAX,0x20
MOV byte ptr [RBP + -0x20c],AL
MOV RAX,qword ptr [RBP + -0x2c0]
SAR RAX,0x20
SHR EAX,0x8
MOV byte ptr [RBP + -0x20b],AL
MOV RAX,qword ptr [RBP + -0x2c0]
SAR RAX,0x20
SHR EAX,0x10
MOV byte ptr [RBP + -0x20a],AL
JMP 0x0018bd47
LAB_0018bd47:
LEA RAX,[RBP + -0x210]
ADD RAX,0x4
ADD RAX,0x3
MOV qword ptr [RBP + -0x2e8],RAX
MOV RAX,0xffffffff
AND RAX,qword ptr [RBP + -0x2c0]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x2e8]
MOV dword ptr [RAX],ECX
JMP 0x0018bd7b
LAB_0018bd7b:
JMP 0x0018bd7d
LAB_0018bd7d:
LEA RAX,[RBP + -0x210]
ADD RAX,0xb
MOV qword ptr [RBP + -0x2f0],RAX
MOV ECX,dword ptr [RBP + -0x2c4]
MOV RAX,qword ptr [RBP + -0x2f0]
MOV dword ptr [RAX],ECX
JMP 0x0018bda0
LAB_0018bda0:
LEA RAX,[RBP + -0x210]
ADD RAX,0xf
MOV qword ptr [RBP + -0x2f8],RAX
MOV RAX,qword ptr [RBP + -0x2d0]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x2f8]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x2d0]
SHR RAX,0x20
MOV CX,AX
MOV RAX,qword ptr [RBP + -0x2f8]
MOV word ptr [RAX + 0x4],CX
MOV AL,byte ptr [RBP + -0x2d1]
MOV byte ptr [RBP + -0x1fb],AL
CMP dword ptr [0x0058a7a8],0x16
JBE 0x0018be6a
MOV EAX,dword ptr [0x0058a7a8]
SUB EAX,0x16
MOV dword ptr [RBP + -0x2fc],EAX
LEA RDI,[RBP + -0x210]
ADD RDI,0x16
MOV EAX,dword ptr [RBP + -0x2fc]
MOV EDX,EAX
XOR ESI,ESI
CALL 0x0012a2b0
LEA RDI,[RBP + -0x2b0]
MOV ECX,dword ptr [RBP + -0x2fc]
MOV R8D,dword ptr [0x0058a7a8]
ADD R8D,dword ptr [0x0058a7a4]
MOV ESI,0x96
LEA RDX,[0x26276f]
MOV AL,0x0
CALL 0x0025cc50
LEA RCX,[RBP + -0x2b0]
MOV EDI,0xa8
LEA RSI,[0x2627d5]
MOV EDX,0x800
MOV AL,0x0
CALL 0x001fa710
JMP 0x0018be74
LAB_0018be6a:
MOV dword ptr [0x0058a7a8],0x16
LAB_0018be74:
JMP 0x0018be76
LAB_0018be76:
JMP 0x0018be78
LAB_0018be78:
LEA RSI,[RBP + -0x210]
ADD RSI,0x4
MOV EAX,dword ptr [0x0058a7a8]
SUB EAX,0x4
MOV EAX,EAX
MOV EDX,EAX
XOR EDI,EDI
CALL 0x00211b70
MOV dword ptr [RBP + -0x2d8],EAX
LEA RAX,[RBP + -0x210]
MOV qword ptr [RBP + -0x308],RAX
MOV ECX,dword ptr [RBP + -0x2d8]
MOV RAX,qword ptr [RBP + -0x308]
MOV dword ptr [RAX],ECX
MOV EDI,dword ptr [0x003cfbc0]
LEA RSI,[RBP + -0x210]
MOV EAX,dword ptr [0x0058a7a8]
MOV EDX,EAX
MOV EAX,dword ptr [0x0058a7a4]
MOV ECX,EAX
MOV R8D,0x12
CALL 0x002033a0
CMP RAX,0x0
JNZ 0x0018bf12
CMP byte ptr [RBP + -0x2d9],0x0
JNZ 0x0018bf20
MOV EDX,dword ptr [0x003cfbc0]
LEA RDI,[0x262516]
MOV ESI,0x22c
MOV ECX,0x10
CALL 0x0018bfa0
CMP EAX,0x0
JZ 0x0018bf20
LAB_0018bf12:
JMP 0x0018bf14
LAB_0018bf14:
MOV dword ptr [RBP + -0x2b4],0x1
JMP 0x0018bf68
LAB_0018bf20:
MOV RAX,qword ptr [RBP + -0x2c0]
MOV qword ptr [0x0058a788],RAX
MOV EAX,dword ptr [RBP + -0x2c4]
MOV dword ptr [0x0058a790],EAX
MOV RAX,qword ptr [RBP + -0x2d0]
MOV qword ptr [0x0058a798],RAX
MOV AL,byte ptr [RBP + -0x2d1]
MOV byte ptr [0x0058a7a0],AL
MOV dword ptr [0x0058a7a8],0x16
MOV dword ptr [RBP + -0x2b4],0x0
LAB_0018bf68:
MOV EAX,dword ptr [RBP + -0x2b4]
MOV dword ptr [RBP + -0x310],EAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x0018bf95
MOV EAX,dword ptr [RBP + -0x310]
ADD RSP,0x310
POP RBP
RET
LAB_0018bf95:
CALL 0x0012a260
|
int4 ma_control_file_write_and_force(long param_1,int param_2,long param_3,char param_4)
{
bool bVar1;
uint uVar2;
int iVar3;
long lVar4;
long in_FS_OFFSET;
int4 local_2bc;
int1 local_2b8 [160];
int4 local_218;
int1 local_214;
int1 local_213;
int1 local_212;
int4 local_211;
int local_20d;
int4 local_209;
int2 local_205;
char local_203;
int1 auStack_202 [498];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
bVar1 = false;
if (((last_checkpoint_lsn == param_1) && (bVar1 = false, last_logno == param_2)) &&
(bVar1 = false, max_trid_in_control_file == param_3)) {
bVar1 = param_4 != '\0';
}
if (control_file_fd < 0) {
local_2bc = 1;
goto LAB_0018bf68;
}
local_214 = (int1)((ulong)param_1 >> 0x20);
local_213 = (int1)((ulong)param_1 >> 0x28);
local_212 = (int1)((ulong)param_1 >> 0x30);
local_211 = (int4)param_1;
local_209 = (int4)param_3;
local_205 = (int2)((ulong)param_3 >> 0x20);
local_203 = param_4;
local_20d = param_2;
if (cf_changeable_size < 0x17) {
cf_changeable_size = 0x16;
}
else {
uVar2 = cf_changeable_size - 0x16;
memset(auStack_202,0,(ulong)uVar2);
my_snprintf(local_2b8,0x96,
"Control file must be from a newer version; zero-ing out %u unknown bytes in control file at offset %u"
,uVar2,cf_changeable_size + cf_create_time_size);
my_printf_error(0xa8,"Aria engine: %s",0x800,local_2b8);
}
local_218 = my_checksum(0,&local_214,cf_changeable_size - 4);
lVar4 = my_pwrite(control_file_fd,&local_218,cf_changeable_size,cf_create_time_size,0x12);
if (lVar4 == 0) {
if (!bVar1) {
iVar3 = inline_mysql_file_sync
("/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_control_file.c",
0x22c,control_file_fd,0x10);
if (iVar3 != 0) goto LAB_0018bf12;
}
cf_changeable_size = 0x16;
local_2bc = 0;
last_checkpoint_lsn = param_1;
last_logno = param_2;
max_trid_in_control_file = param_3;
recovery_failures = param_4;
}
else {
LAB_0018bf12:
local_2bc = 1;
}
LAB_0018bf68:
if (*(long *)(in_FS_OFFSET + 0x28) == local_10) {
return local_2bc;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
|
|
19,926
|
uf_space_endspace_selected
|
eloqsql/storage/myisam/mi_packrec.c
|
static void uf_space_endspace_selected(MI_COLUMNDEF *rec, MI_BIT_BUFF *bit_buff,
uchar *to, uchar *end)
{
uint spaces;
if (get_bit(bit_buff))
bfill((uchar*) to,(end-to),' ');
else
{
if (get_bit(bit_buff))
{
if ((spaces=get_bits(bit_buff,rec->space_length_bits))+to > end)
{
bit_buff->error=1;
return;
}
if (to+spaces != end)
decode_bytes(rec,bit_buff,to,end-spaces);
bfill((uchar*) end-spaces,spaces,' ');
}
else
decode_bytes(rec,bit_buff,to,end);
}
}
|
O3
|
c
|
uf_space_endspace_selected:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r13
movl 0x4(%rsi), %eax
testl %eax, %eax
je 0x3c119
movl (%r15), %r12d
decl %eax
movl %eax, 0x4(%r15)
btl %eax, %r12d
jb 0x3c18e
testl %eax, %eax
jne 0x3c136
movq %r15, %rdi
callq 0x3b5a9
movl $0x1f, 0x4(%r15)
movl (%r15), %r12d
testl %r12d, %r12d
jns 0x3c1a1
movl $0x1f, %eax
jmp 0x3c142
movq %r15, %rdi
callq 0x3b5a9
movl $0x1f, 0x4(%r15)
movl (%r15), %r12d
movl $0x1f, %eax
testl %r12d, %r12d
js 0x3c18e
decl %eax
movl %eax, 0x4(%r15)
btl %eax, %r12d
jae 0x3c1a1
movq %r13, %rdx
movl 0x1c(%r13), %r13d
movl %eax, %ecx
subl %r13d, %ecx
movq %rdx, -0x30(%rbp)
jae 0x3c1c0
subl %eax, %r13d
movl %eax, %eax
leaq 0x602e0(%rip), %rcx # 0x9c440
andl (%rcx,%rax,4), %r12d
movl %r13d, %ecx
shll %cl, %r12d
movq %r15, %rdi
callq 0x3b5a9
movl $0x20, %eax
subl %r13d, %eax
movl %eax, 0x4(%r15)
movl (%r15), %eax
negl %r13d
movl %r13d, %ecx
shrl %cl, %eax
addl %eax, %r12d
jmp 0x3c1d5
subq %r14, %rbx
movq %r14, %rdi
movl $0x20, %esi
movq %rbx, %rdx
jmp 0x3c224
movq %r13, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3be9a
movl %ecx, 0x4(%r15)
shrl %cl, %r12d
movl 0x1c(%rdx), %eax
leaq 0x6026f(%rip), %rcx # 0x9c440
andl (%rcx,%rax,4), %r12d
movl %r12d, %r13d
leaq (%r14,%r13), %rax
cmpq %rbx, %rax
jbe 0x3c1f8
movl $0x1, 0x28(%r15)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r13, %r12
negq %r12
cmpq %rbx, %rax
je 0x3c216
leaq (%rbx,%r12), %rcx
movq -0x30(%rbp), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x3be9a
addq %r12, %rbx
movq %rbx, %rdi
movl $0x20, %esi
movq %r13, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x281d0
|
uf_space_endspace_selected:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rcx
mov r14, rdx
mov r15, rsi
mov r13, rdi
mov eax, [rsi+4]
test eax, eax
jz short loc_3C119
mov r12d, [r15]
dec eax
mov [r15+4], eax
bt r12d, eax
jb loc_3C18E
test eax, eax
jnz short loc_3C136
mov rdi, r15
call fill_buffer
mov dword ptr [r15+4], 1Fh
mov r12d, [r15]
test r12d, r12d
jns loc_3C1A1
mov eax, 1Fh
jmp short loc_3C142
loc_3C119:
mov rdi, r15
call fill_buffer
mov dword ptr [r15+4], 1Fh
mov r12d, [r15]
mov eax, 1Fh
test r12d, r12d
js short loc_3C18E
loc_3C136:
dec eax
mov [r15+4], eax
bt r12d, eax
jnb short loc_3C1A1
loc_3C142:
mov rdx, r13
mov r13d, [r13+1Ch]
mov ecx, eax
sub ecx, r13d
mov [rbp+var_30], rdx
jnb short loc_3C1C0
sub r13d, eax
mov eax, eax
lea rcx, mask
and r12d, [rcx+rax*4]
mov ecx, r13d
shl r12d, cl
mov rdi, r15
call fill_buffer
mov eax, 20h ; ' '
sub eax, r13d
mov [r15+4], eax
mov eax, [r15]
neg r13d
mov ecx, r13d
shr eax, cl
add r12d, eax
jmp short loc_3C1D5
loc_3C18E:
sub rbx, r14
mov rdi, r14
mov esi, 20h ; ' '
mov rdx, rbx
jmp loc_3C224
loc_3C1A1:
mov rdi, r13
mov rsi, r15
mov rdx, r14
mov rcx, rbx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp decode_bytes
loc_3C1C0:
mov [r15+4], ecx
shr r12d, cl
mov eax, [rdx+1Ch]
lea rcx, mask
and r12d, [rcx+rax*4]
loc_3C1D5:
mov r13d, r12d
lea rax, [r14+r13]
cmp rax, rbx
jbe short loc_3C1F8
mov dword ptr [r15+28h], 1
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3C1F8:
mov r12, r13
neg r12
cmp rax, rbx
jz short loc_3C216
lea rcx, [rbx+r12]
mov rdi, [rbp+var_30]
mov rsi, r15
mov rdx, r14
call decode_bytes
loc_3C216:
add rbx, r12
mov rdi, rbx
mov esi, 20h ; ' '
mov rdx, r13
loc_3C224:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp _memset
|
_BYTE * uf_space_endspace_selected(long long a1, unsigned int *a2, _BYTE *a3, _BYTE *a4)
{
unsigned int v6; // eax
unsigned int v7; // r12d
unsigned int v8; // eax
unsigned int v9; // eax
unsigned int v10; // r13d
unsigned int v11; // ecx
int v12; // r13d
int v13; // r12d
unsigned int v14; // r12d
_BYTE *result; // rax
v6 = a2[1];
if ( !v6 )
{
fill_buffer((long long)a2);
a2[1] = 31;
v7 = *a2;
v8 = 31;
if ( (*a2 & 0x80000000) == 0 )
{
LABEL_7:
v9 = v8 - 1;
a2[1] = v9;
if ( _bittest((const int *)&v7, v9) )
goto LABEL_8;
return decode_bytes(a1, (long long)a2, a3, a4);
}
return (_BYTE *)memset(a3, 32LL, a4 - a3);
}
v7 = *a2;
v8 = v6 - 1;
a2[1] = v8;
if ( _bittest((const int *)&v7, v8) )
return (_BYTE *)memset(a3, 32LL, a4 - a3);
if ( v8 )
goto LABEL_7;
fill_buffer((long long)a2);
a2[1] = 31;
v7 = *a2;
if ( (*a2 & 0x80000000) == 0 )
return decode_bytes(a1, (long long)a2, a3, a4);
v9 = 31;
LABEL_8:
v10 = *(_DWORD *)(a1 + 28);
v11 = v9 - v10;
if ( v9 >= v10 )
{
a2[1] = v11;
v14 = mask[*(unsigned int *)(a1 + 28)] & (v7 >> v11);
}
else
{
v12 = v10 - v9;
v13 = (mask[v9] & v7) << v12;
fill_buffer((long long)a2);
a2[1] = 32 - v12;
v14 = (*a2 >> -(char)v12) + v13;
}
result = &a3[v14];
if ( result <= a4 )
{
if ( result != a4 )
decode_bytes(a1, (long long)a2, a3, &a4[-v14]);
return (_BYTE *)memset(&a4[-v14], 32LL, v14);
}
else
{
a2[10] = 1;
}
return result;
}
|
uf_space_endspace_selected:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RCX
MOV R14,RDX
MOV R15,RSI
MOV R13,RDI
MOV EAX,dword ptr [RSI + 0x4]
TEST EAX,EAX
JZ 0x0013c119
MOV R12D,dword ptr [R15]
DEC EAX
MOV dword ptr [R15 + 0x4],EAX
BT R12D,EAX
JC 0x0013c18e
TEST EAX,EAX
JNZ 0x0013c136
MOV RDI,R15
CALL 0x0013b5a9
MOV dword ptr [R15 + 0x4],0x1f
MOV R12D,dword ptr [R15]
TEST R12D,R12D
JNS 0x0013c1a1
MOV EAX,0x1f
JMP 0x0013c142
LAB_0013c119:
MOV RDI,R15
CALL 0x0013b5a9
MOV dword ptr [R15 + 0x4],0x1f
MOV R12D,dword ptr [R15]
MOV EAX,0x1f
TEST R12D,R12D
JS 0x0013c18e
LAB_0013c136:
DEC EAX
MOV dword ptr [R15 + 0x4],EAX
BT R12D,EAX
JNC 0x0013c1a1
LAB_0013c142:
MOV RDX,R13
MOV R13D,dword ptr [R13 + 0x1c]
MOV ECX,EAX
SUB ECX,R13D
MOV qword ptr [RBP + -0x30],RDX
JNC 0x0013c1c0
SUB R13D,EAX
MOV EAX,EAX
LEA RCX,[0x19c440]
AND R12D,dword ptr [RCX + RAX*0x4]
MOV ECX,R13D
SHL R12D,CL
MOV RDI,R15
CALL 0x0013b5a9
MOV EAX,0x20
SUB EAX,R13D
MOV dword ptr [R15 + 0x4],EAX
MOV EAX,dword ptr [R15]
NEG R13D
MOV ECX,R13D
SHR EAX,CL
ADD R12D,EAX
JMP 0x0013c1d5
LAB_0013c18e:
SUB RBX,R14
MOV RDI,R14
MOV ESI,0x20
MOV RDX,RBX
JMP 0x0013c224
LAB_0013c1a1:
MOV RDI,R13
MOV RSI,R15
MOV RDX,R14
MOV RCX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x0013be9a
LAB_0013c1c0:
MOV dword ptr [R15 + 0x4],ECX
SHR R12D,CL
MOV EAX,dword ptr [RDX + 0x1c]
LEA RCX,[0x19c440]
AND R12D,dword ptr [RCX + RAX*0x4]
LAB_0013c1d5:
MOV R13D,R12D
LEA RAX,[R14 + R13*0x1]
CMP RAX,RBX
JBE 0x0013c1f8
MOV dword ptr [R15 + 0x28],0x1
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0013c1f8:
MOV R12,R13
NEG R12
CMP RAX,RBX
JZ 0x0013c216
LEA RCX,[RBX + R12*0x1]
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,R15
MOV RDX,R14
CALL 0x0013be9a
LAB_0013c216:
ADD RBX,R12
MOV RDI,RBX
MOV ESI,0x20
MOV RDX,R13
LAB_0013c224:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x001281d0
|
void uf_space_endspace_selected(long param_1,uint *param_2,void *param_3,ulong param_4)
{
uint uVar1;
uint uVar2;
uint uVar3;
byte bVar4;
size_t __n;
uint uVar5;
if (param_2[1] == 0) {
fill_buffer(param_2);
param_2[1] = 0x1f;
uVar5 = *param_2;
uVar3 = 0x1f;
if ((int)uVar5 < 0) goto LAB_0013c18e;
LAB_0013c136:
uVar3 = uVar3 - 1;
param_2[1] = uVar3;
if ((uVar5 >> (uVar3 & 0x1f) & 1) == 0) {
LAB_0013c1a1:
decode_bytes(param_1,param_2,param_3,param_4);
return;
}
}
else {
uVar5 = *param_2;
uVar3 = param_2[1] - 1;
param_2[1] = uVar3;
if ((uVar5 >> (uVar3 & 0x1f) & 1) != 0) {
LAB_0013c18e:
__n = param_4 - (long)param_3;
goto LAB_0013c224;
}
if (uVar3 != 0) goto LAB_0013c136;
fill_buffer(param_2);
param_2[1] = 0x1f;
uVar5 = *param_2;
if (-1 < (int)uVar5) goto LAB_0013c1a1;
uVar3 = 0x1f;
}
uVar1 = *(uint *)(param_1 + 0x1c);
if (uVar3 < uVar1) {
uVar2 = (&mask)[uVar3];
bVar4 = (byte)(uVar1 - uVar3);
fill_buffer(param_2);
param_2[1] = 0x20 - (uVar1 - uVar3);
uVar5 = ((uVar5 & uVar2) << (bVar4 & 0x1f)) + (*param_2 >> (-bVar4 & 0x1f));
}
else {
param_2[1] = uVar3 - uVar1;
uVar5 = uVar5 >> ((byte)(uVar3 - uVar1) & 0x1f) & (&mask)[*(uint *)(param_1 + 0x1c)];
}
__n = (size_t)uVar5;
if (param_4 < (long)param_3 + __n) {
param_2[10] = 1;
return;
}
if ((long)param_3 + __n != param_4) {
decode_bytes(param_1,param_2,param_3,param_4 + -__n);
}
param_3 = (void *)(param_4 + -__n);
LAB_0013c224:
memset(param_3,0x20,__n);
return;
}
|
|
19,927
|
my_stmt_result
|
eloqsql/libmariadb/unittest/libmariadb/my_test.h
|
int my_stmt_result(MYSQL *mysql, const char *buff)
{
MYSQL_STMT *stmt;
int row_count= 0;
int rc;
stmt= mysql_stmt_init(mysql);
rc= mysql_stmt_prepare(stmt, buff, (unsigned long)strlen(buff));
FAIL_IF(rc, mysql_stmt_error(stmt));
rc= mysql_stmt_execute(stmt);
FAIL_IF(rc, mysql_stmt_error(stmt));
while (mysql_stmt_fetch(stmt) != MYSQL_NO_DATA)
row_count++;
mysql_stmt_close(stmt);
return row_count;
}
|
O3
|
c
|
my_stmt_result:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
callq 0x322b8
movq %rax, %rbx
movq %r14, %rdi
callq 0x141c0
movq %rbx, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x3267c
testl %eax, %eax
je 0x14bb0
movq %rbx, %rdi
callq 0x31d58
leaq 0x31641(%rip), %rdi # 0x461e0
leaq 0x31662(%rip), %rdx # 0x46208
movq %rax, %rsi
movl $0x156, %ecx # imm = 0x156
jmp 0x14bda
movq %rbx, %rdi
callq 0x3324d
testl %eax, %eax
je 0x14bef
movq %rbx, %rdi
callq 0x31d58
leaq 0x31615(%rip), %rdi # 0x461e0
leaq 0x31636(%rip), %rdx # 0x46208
movq %rax, %rsi
movl $0x159, %ecx # imm = 0x159
xorl %eax, %eax
callq 0x264ef
movl $0x1, %r14d
movl %r14d, %eax
popq %rbx
popq %r14
popq %rbp
retq
movl $0xffffffff, %r14d # imm = 0xFFFFFFFF
movq %rbx, %rdi
callq 0x31d73
incl %r14d
cmpl $0x64, %eax
jne 0x14bf5
movq %rbx, %rdi
callq 0x31cc9
jmp 0x14be7
|
my_stmt_result:
push rbp
mov rbp, rsp
push r14
push rbx
mov r14, rsi
call mysql_stmt_init
mov rbx, rax
mov rdi, r14
call _strlen
mov rdi, rbx
mov rsi, r14
mov rdx, rax
call mysql_stmt_prepare
test eax, eax
jz short loc_14BB0
mov rdi, rbx
call mysql_stmt_error
lea rdi, aErrorSSD; "Error: %s (%s: %d)"
lea rdx, aWorkspaceLlm4b; "/workspace/llm4binary/github2025/eloqsq"...
mov rsi, rax
mov ecx, 156h
jmp short loc_14BDA
loc_14BB0:
mov rdi, rbx
call mysql_stmt_execute
test eax, eax
jz short loc_14BEF
mov rdi, rbx
call mysql_stmt_error
lea rdi, aErrorSSD; "Error: %s (%s: %d)"
lea rdx, aWorkspaceLlm4b; "/workspace/llm4binary/github2025/eloqsq"...
mov rsi, rax
mov ecx, 159h
loc_14BDA:
xor eax, eax
call diag
mov r14d, 1
loc_14BE7:
mov eax, r14d
pop rbx
pop r14
pop rbp
retn
loc_14BEF:
mov r14d, 0FFFFFFFFh
loc_14BF5:
mov rdi, rbx
call mysql_stmt_fetch
inc r14d
cmp eax, 64h ; 'd'
jnz short loc_14BF5
mov rdi, rbx
call mysql_stmt_close
jmp short loc_14BE7
|
long long my_stmt_result(long long a1, long long a2)
{
long long v2; // rbx
long long v3; // rax
int v4; // esi
int v5; // r8d
int v6; // r9d
int v7; // ecx
unsigned int v8; // r14d
v2 = mysql_stmt_init();
v3 = strlen(a2);
if ( (unsigned int)mysql_stmt_prepare(v2, a2, v3) )
{
v4 = mysql_stmt_error(v2);
v7 = 342;
LABEL_5:
diag(
(unsigned int)"Error: %s (%s: %d)",
v4,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/my_test.h",
v7,
v5,
v6);
return 1;
}
if ( (unsigned int)mysql_stmt_execute(v2) )
{
v4 = mysql_stmt_error(v2);
v7 = 345;
goto LABEL_5;
}
v8 = -1;
do
++v8;
while ( (unsigned int)mysql_stmt_fetch(v2) != 100 );
mysql_stmt_close(v2);
return v8;
}
|
my_stmt_result:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV R14,RSI
CALL 0x001322b8
MOV RBX,RAX
MOV RDI,R14
CALL 0x001141c0
MOV RDI,RBX
MOV RSI,R14
MOV RDX,RAX
CALL 0x0013267c
TEST EAX,EAX
JZ 0x00114bb0
MOV RDI,RBX
CALL 0x00131d58
LEA RDI,[0x1461e0]
LEA RDX,[0x146208]
MOV RSI,RAX
MOV ECX,0x156
JMP 0x00114bda
LAB_00114bb0:
MOV RDI,RBX
CALL 0x0013324d
TEST EAX,EAX
JZ 0x00114bef
MOV RDI,RBX
CALL 0x00131d58
LEA RDI,[0x1461e0]
LEA RDX,[0x146208]
MOV RSI,RAX
MOV ECX,0x159
LAB_00114bda:
XOR EAX,EAX
CALL 0x001264ef
MOV R14D,0x1
LAB_00114be7:
MOV EAX,R14D
POP RBX
POP R14
POP RBP
RET
LAB_00114bef:
MOV R14D,0xffffffff
LAB_00114bf5:
MOV RDI,RBX
CALL 0x00131d73
INC R14D
CMP EAX,0x64
JNZ 0x00114bf5
MOV RDI,RBX
CALL 0x00131cc9
JMP 0x00114be7
|
int my_stmt_result(int8 param_1,char *param_2)
{
int iVar1;
int iVar2;
int8 uVar3;
size_t sVar4;
int8 uVar5;
uVar3 = mysql_stmt_init();
sVar4 = strlen(param_2);
iVar1 = mysql_stmt_prepare(uVar3,param_2,sVar4);
if (iVar1 == 0) {
iVar1 = mysql_stmt_execute(uVar3);
if (iVar1 == 0) {
iVar1 = -1;
do {
iVar2 = mysql_stmt_fetch(uVar3);
iVar1 = iVar1 + 1;
} while (iVar2 != 100);
mysql_stmt_close(uVar3);
return iVar1;
}
uVar3 = mysql_stmt_error(uVar3);
uVar5 = 0x159;
}
else {
uVar3 = mysql_stmt_error(uVar3);
uVar5 = 0x156;
}
diag("Error: %s (%s: %d)",uVar3,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/my_test.h",uVar5);
return 1;
}
|
|
19,928
|
inline_mysql_file_chsize
|
eloqsql/include/mysql/psi/mysql_file.h
|
static inline int
inline_mysql_file_chsize(
#ifdef HAVE_PSI_FILE_INTERFACE
const char *src_file, uint src_line,
#endif
File file, my_off_t newlength, int filler, myf flags)
{
int result;
#ifdef HAVE_PSI_FILE_INTERFACE
struct PSI_file_locker *locker;
PSI_file_locker_state state;
locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_CHSIZE);
if (psi_likely(locker != NULL))
{
PSI_FILE_CALL(start_file_wait)(locker, (size_t) newlength, src_file,
src_line);
result= my_chsize(file, newlength, filler, flags);
PSI_FILE_CALL(end_file_wait)(locker, (size_t) newlength);
return result;
}
#endif
result= my_chsize(file, newlength, filler, flags);
return result;
}
|
O0
|
c
|
inline_mysql_file_chsize:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movq %r9, -0x30(%rbp)
leaq 0x27bd60(%rip), %rax # 0x2c00b8
movq (%rax), %rax
movq 0x158(%rax), %rax
movl -0x18(%rbp), %esi
leaq -0x88(%rbp), %rdi
movl $0xd, %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 0x443f2
leaq 0x27bd1a(%rip), %rax # 0x2c00b8
movq (%rax), %rax
movq 0x210(%rax), %rax
movq -0x40(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x10(%rbp), %rdx
movl -0x14(%rbp), %ecx
callq *%rax
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
movl -0x24(%rbp), %edx
movq -0x30(%rbp), %rcx
callq 0xef4a0
movl %eax, -0x34(%rbp)
leaq 0x27bce2(%rip), %rax # 0x2c00b8
movq (%rax), %rax
movq 0x218(%rax), %rax
movq -0x40(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq *%rax
movl -0x34(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x4440e
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
movl -0x24(%rbp), %edx
movq -0x30(%rbp), %rcx
callq 0xef4a0
movl %eax, -0x34(%rbp)
movl -0x34(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x90, %rsp
popq %rbp
retq
nopw (%rax,%rax)
|
inline_mysql_file_chsize:
push rbp
mov rbp, rsp
sub rsp, 90h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov [rbp+var_20], rcx
mov [rbp+var_24], r8d
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, 0Dh
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 short loc_443F2
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+210h]
mov rdi, [rbp+var_40]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_10]
mov ecx, [rbp+var_14]
call rax
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
mov edx, [rbp+var_24]
mov rcx, [rbp+var_30]
call my_chsize
mov [rbp+var_34], eax
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+218h]
mov rdi, [rbp+var_40]
mov rsi, [rbp+var_20]
call rax
mov eax, [rbp+var_34]
mov [rbp+var_4], eax
jmp short loc_4440E
loc_443F2:
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
mov edx, [rbp+var_24]
mov rcx, [rbp+var_30]
call my_chsize
mov [rbp+var_34], eax
mov eax, [rbp+var_34]
mov [rbp+var_4], eax
loc_4440E:
mov eax, [rbp+var_4]
add rsp, 90h
pop rbp
retn
|
long long inline_mysql_file_chsize(
long long a1,
unsigned int a2,
unsigned int a3,
long long a4,
unsigned int a5,
long long a6)
{
_BYTE v7[72]; // [rsp+8h] [rbp-88h] BYREF
long long v8; // [rsp+50h] [rbp-40h]
unsigned int v9; // [rsp+5Ch] [rbp-34h]
long long v10; // [rsp+60h] [rbp-30h]
unsigned int v11; // [rsp+6Ch] [rbp-24h]
long long v12; // [rsp+70h] [rbp-20h]
unsigned int v13; // [rsp+78h] [rbp-18h]
unsigned int v14; // [rsp+7Ch] [rbp-14h]
long long v15; // [rsp+80h] [rbp-10h]
v15 = a1;
v14 = a2;
v13 = a3;
v12 = a4;
v11 = a5;
v10 = a6;
v8 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v7, a3, 13LL);
if ( v8 )
{
((void ( *)(long long, long long, long long, _QWORD))PSI_server[66])(v8, v12, v15, v14);
v9 = my_chsize(v13, v12, v11, v10);
((void ( *)(long long, long long))PSI_server[67])(v8, v12);
}
else
{
return (unsigned int)my_chsize(v13, v12, v11, v10);
}
return v9;
}
|
inline_mysql_file_chsize:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
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 dword ptr [RBP + -0x24],R8D
MOV qword ptr [RBP + -0x30],R9
LEA RAX,[0x3c00b8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x158]
MOV ESI,dword ptr [RBP + -0x18]
LEA RDI,[RBP + -0x88]
MOV EDX,0xd
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 0x001443f2
LEA RAX,[0x3c00b8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x210]
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x20]
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 EDX,dword ptr [RBP + -0x24]
MOV RCX,qword ptr [RBP + -0x30]
CALL 0x001ef4a0
MOV dword ptr [RBP + -0x34],EAX
LEA RAX,[0x3c00b8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x218]
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x20]
CALL RAX
MOV EAX,dword ptr [RBP + -0x34]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014440e
LAB_001443f2:
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
MOV EDX,dword ptr [RBP + -0x24]
MOV RCX,qword ptr [RBP + -0x30]
CALL 0x001ef4a0
MOV dword ptr [RBP + -0x34],EAX
MOV EAX,dword ptr [RBP + -0x34]
MOV dword ptr [RBP + -0x4],EAX
LAB_0014440e:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x90
POP RBP
RET
|
int4
inline_mysql_file_chsize
(int8 param_1,int4 param_2,int4 param_3,int8 param_4,
int4 param_5,int8 param_6)
{
int1 local_90 [72];
long local_48;
int4 local_3c;
int8 local_38;
int4 local_2c;
int8 local_28;
int4 local_20;
int4 local_1c;
int8 local_18;
int4 local_c;
local_38 = param_6;
local_2c = 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,0xd);
if (local_48 == 0) {
local_c = my_chsize(local_20,local_28,local_2c,local_38);
}
else {
(**(code **)(PSI_server + 0x210))(local_48,local_28,local_18,local_1c);
local_3c = my_chsize(local_20,local_28,local_2c,local_38);
(**(code **)(PSI_server + 0x218))(local_48,local_28);
local_c = local_3c;
}
return local_c;
}
|
|
19,929
|
inline_mysql_file_chsize
|
eloqsql/include/mysql/psi/mysql_file.h
|
static inline int
inline_mysql_file_chsize(
#ifdef HAVE_PSI_FILE_INTERFACE
const char *src_file, uint src_line,
#endif
File file, my_off_t newlength, int filler, myf flags)
{
int result;
#ifdef HAVE_PSI_FILE_INTERFACE
struct PSI_file_locker *locker;
PSI_file_locker_state state;
locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_CHSIZE);
if (psi_likely(locker != NULL))
{
PSI_FILE_CALL(start_file_wait)(locker, (size_t) newlength, src_file,
src_line);
result= my_chsize(file, newlength, filler, flags);
PSI_FILE_CALL(end_file_wait)(locker, (size_t) newlength);
return result;
}
#endif
result= my_chsize(file, newlength, filler, flags);
return result;
}
|
O3
|
c
|
inline_mysql_file_chsize:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x58, %rsp
movq %rsi, %rbx
movl %edi, %r14d
leaq 0x2f50d3(%rip), %rax # 0x386010
movq (%rax), %rax
leaq -0x68(%rbp), %rdi
movl %r14d, %esi
movl $0xd, %edx
callq *0x158(%rax)
testq %rax, %rax
jne 0x90f71
movl %r14d, %edi
movq %rbx, %rsi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0x9dd80
addq $0x58, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq -0x1c(%rbp), %r15
movq %rax, %rdi
movq %rbx, %rsi
movl %r14d, %edx
movq %r15, %rcx
callq 0x2e7ec
movl (%r15), %eax
jmp 0x90f66
|
inline_mysql_file_chsize_1:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
sub rsp, 58h
mov rbx, rsi
mov r14d, edi
lea rax, PSI_server
mov rax, [rax]
lea rdi, [rbp+var_68]
mov esi, r14d
mov edx, 0Dh
call qword ptr [rax+158h]
test rax, rax
jnz short loc_90F71
mov edi, r14d
mov rsi, rbx
xor edx, edx
xor ecx, ecx
call my_chsize
loc_90F66:
add rsp, 58h
pop rbx
pop r14
pop r15
pop rbp
retn
loc_90F71:
lea r15, [rbp+var_1C]
mov rdi, rax
mov rsi, rbx
mov edx, r14d
mov rcx, r15
call inline_mysql_file_chsize_cold_1_0
mov eax, [r15]
jmp short loc_90F66
|
long long inline_mysql_file_chsize_1(unsigned int a1, long long a2)
{
long long v2; // rax
_BYTE v4[76]; // [rsp+8h] [rbp-68h] BYREF
_DWORD v5[7]; // [rsp+54h] [rbp-1Ch] BYREF
v2 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v4, a1, 13LL);
if ( !v2 )
return my_chsize(a1, a2, 0LL, 0LL);
inline_mysql_file_chsize_cold_1_0(v2, a2, a1, v5);
return v5[0];
}
|
inline_mysql_file_chsize:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x58
MOV RBX,RSI
MOV R14D,EDI
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
LEA RDI,[RBP + -0x68]
MOV ESI,R14D
MOV EDX,0xd
CALL qword ptr [RAX + 0x158]
TEST RAX,RAX
JNZ 0x00190f71
MOV EDI,R14D
MOV RSI,RBX
XOR EDX,EDX
XOR ECX,ECX
CALL 0x0019dd80
LAB_00190f66:
ADD RSP,0x58
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_00190f71:
LEA R15,[RBP + -0x1c]
MOV RDI,RAX
MOV RSI,RBX
MOV EDX,R14D
MOV RCX,R15
CALL 0x0012e7ec
MOV EAX,dword ptr [R15]
JMP 0x00190f66
|
ulong inline_mysql_file_chsize(int4 param_1,int8 param_2)
{
long lVar1;
ulong uVar2;
int1 local_70 [76];
uint local_24;
lVar1 = (**(code **)(PSI_server + 0x158))(local_70,param_1,0xd);
if (lVar1 == 0) {
uVar2 = my_chsize(param_1,param_2,0,0);
}
else {
inline_mysql_file_chsize_cold_1(lVar1,param_2,param_1,&local_24);
uVar2 = (ulong)local_24;
}
return uVar2;
}
|
|
19,930
|
mb_aes256_buffer
|
msxemulator/build_O3/_deps/picotool-src/bintool/mbedtls_wrapper.c
|
void mb_aes256_buffer(const uint8_t *data, size_t len, uint8_t *data_out, const private_t *key, iv_t *iv) {
mbedtls_aes_context aes;
assert(len % 16 == 0);
mbedtls_aes_setkey_enc(&aes, key->bytes, 256);
uint8_t stream_block[16] = {0};
size_t nc_off = 0;
mbedtls_aes_crypt_ctr(&aes, len, &nc_off, iv->bytes, stream_block, data, data_out);
}
|
O3
|
c
|
mb_aes256_buffer:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x140, %rsp # imm = 0x140
movq %r8, %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
leaq 0x20(%rsp), %r13
movq %r13, %rdi
movq %rcx, %rsi
movl $0x100, %edx # imm = 0x100
callq 0x7b649
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %r8
movaps %xmm0, (%r8)
leaq 0x8(%rsp), %rdx
movq $0x0, (%rdx)
movq %r14, (%rsp)
movq %r13, %rdi
movq %r15, %rsi
movq %rbx, %rcx
movq %r12, %r9
callq 0x7cef4
addq $0x140, %rsp # imm = 0x140
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
|
mb_aes256_buffer:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 140h
mov rbx, r8
mov r14, rdx
mov r15, rsi
mov r12, rdi
lea r13, [rsp+168h+var_148]
mov rdi, r13
mov rsi, rcx
mov edx, 100h
call mbedtls_aes_setkey_enc
xorps xmm0, xmm0
lea r8, [rsp+168h+var_158]
movaps xmmword ptr [r8], xmm0
lea rdx, [rsp+168h+var_160]
mov qword ptr [rdx], 0
mov [rsp+168h+var_168], r14
mov rdi, r13
mov rsi, r15
mov rcx, rbx
mov r9, r12
call mbedtls_aes_crypt_ctr
add rsp, 140h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
|
long long mb_aes256_buffer(int a1, int a2, long long a3, long long a4, int a5)
{
long long v8; // [rsp+8h] [rbp-160h] BYREF
__int128 v9; // [rsp+10h] [rbp-158h] BYREF
_BYTE v10[328]; // [rsp+20h] [rbp-148h] BYREF
mbedtls_aes_setkey_enc(v10, a4, 256LL);
v9 = 0LL;
v8 = 0LL;
return mbedtls_aes_crypt_ctr((unsigned int)v10, a2, (unsigned int)&v8, a5, (unsigned int)&v9, a1, a3);
}
|
mb_aes256_buffer:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x140
MOV RBX,R8
MOV R14,RDX
MOV R15,RSI
MOV R12,RDI
LEA R13,[RSP + 0x20]
MOV RDI,R13
MOV RSI,RCX
MOV EDX,0x100
CALL 0x0017b649
XORPS XMM0,XMM0
LEA R8,[RSP + 0x10]
MOVAPS xmmword ptr [R8],XMM0
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],0x0
MOV qword ptr [RSP],R14
MOV RDI,R13
MOV RSI,R15
MOV RCX,RBX
MOV R9,R12
CALL 0x0017cef4
ADD RSP,0x140
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
void mb_aes256_buffer(int8 param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5)
{
int8 local_160;
int8 local_158;
int8 uStack_150;
int1 local_148 [288];
mbedtls_aes_setkey_enc(local_148,param_4,0x100);
local_158 = 0;
uStack_150 = 0;
local_160 = 0;
mbedtls_aes_crypt_ctr(local_148,param_2,&local_160,param_5,&local_158,param_1,param_3);
return;
}
|
|
19,931
|
my_caseup_8bit
|
eloqsql/strings/ctype-simple.c
|
size_t my_caseup_8bit(CHARSET_INFO * cs, const char *src, size_t srclen,
char *dst, size_t dstlen __attribute__((unused)))
{
const char *end= src + srclen;
register const uchar *map= cs->to_upper;
DBUG_ASSERT(srclen <= dstlen);
for ( ; src != end ; src++)
*dst++= (char) map[(uchar) *src];
return srclen;
}
|
O0
|
c
|
my_caseup_8bit:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x10(%rbp), %rax
addq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq 0x50(%rax), %rax
movq %rax, -0x38(%rbp)
jmp 0x52322
jmp 0x52324
movq -0x10(%rbp), %rax
cmpq -0x30(%rbp), %rax
je 0x5235b
movq -0x38(%rbp), %rax
movq -0x10(%rbp), %rcx
movzbl (%rcx), %ecx
movb (%rax,%rcx), %cl
movq -0x20(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x20(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x52324
movq -0x18(%rbp), %rax
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
my_caseup_8bit:
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_28], r8
mov rax, [rbp+var_10]
add rax, [rbp+var_18]
mov [rbp+var_30], rax
mov rax, [rbp+var_8]
mov rax, [rax+50h]
mov [rbp+var_38], rax
jmp short $+2
loc_52322:
jmp short $+2
loc_52324:
mov rax, [rbp+var_10]
cmp rax, [rbp+var_30]
jz short loc_5235B
mov rax, [rbp+var_38]
mov rcx, [rbp+var_10]
movzx ecx, byte ptr [rcx]
mov cl, [rax+rcx]
mov rax, [rbp+var_20]
mov rdx, rax
add rdx, 1
mov [rbp+var_20], rdx
mov [rax], cl
mov rax, [rbp+var_10]
add rax, 1
mov [rbp+var_10], rax
jmp short loc_52324
loc_5235B:
mov rax, [rbp+var_18]
pop rbp
retn
|
long long my_caseup_8bit(long long a1, unsigned __int8 *a2, long long a3, _BYTE *a4)
{
_BYTE *v4; // rax
long long v6; // [rsp+0h] [rbp-38h]
unsigned __int8 *v8; // [rsp+28h] [rbp-10h]
v8 = a2;
v6 = *(_QWORD *)(a1 + 80);
while ( v8 != &a2[a3] )
{
v4 = a4++;
*v4 = *(_BYTE *)(v6 + *v8++);
}
return a3;
}
|
my_caseup_8bit:
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],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x50]
MOV qword ptr [RBP + -0x38],RAX
JMP 0x00152322
LAB_00152322:
JMP 0x00152324
LAB_00152324:
MOV RAX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RBP + -0x30]
JZ 0x0015235b
MOV RAX,qword ptr [RBP + -0x38]
MOV RCX,qword ptr [RBP + -0x10]
MOVZX ECX,byte ptr [RCX]
MOV CL,byte ptr [RAX + RCX*0x1]
MOV RAX,qword ptr [RBP + -0x20]
MOV RDX,RAX
ADD RDX,0x1
MOV qword ptr [RBP + -0x20],RDX
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x1
MOV qword ptr [RBP + -0x10],RAX
JMP 0x00152324
LAB_0015235b:
MOV RAX,qword ptr [RBP + -0x18]
POP RBP
RET
|
long my_caseup_8bit(long param_1,byte *param_2,long param_3,int1 *param_4)
{
long lVar1;
int1 *local_28;
byte *local_18;
lVar1 = *(long *)(param_1 + 0x50);
local_28 = param_4;
for (local_18 = param_2; local_18 != param_2 + param_3; local_18 = local_18 + 1) {
*local_28 = *(int1 *)(lVar1 + (ulong)*local_18);
local_28 = local_28 + 1;
}
return param_3;
}
|
|
19,932
|
decltype(from_json_array_impl(fp, fp0, nlohmann::json_abi_v3_11_3::detail::priority_tag<3u>{}), fp.get<std::vector<int, std::allocator<int>>::value_type>(), (void)()) nlohmann::json_abi_v3_11_3::detail::from_json<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::vector<int, std::allocator<int>>, 0>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, std::vector<int, std::allocator<int>>&)
|
llama.cpp/common/./json.hpp
|
auto from_json(const BasicJsonType& j, ConstructibleArrayType& arr)
-> decltype(from_json_array_impl(j, arr, priority_tag<3> {}),
j.template get<typename ConstructibleArrayType::value_type>(),
void())
{
if (JSON_HEDLEY_UNLIKELY(!j.is_array()))
{
JSON_THROW(type_error::create(302, concat("type must be array, but is ", j.type_name()), &j));
}
from_json_array_impl(j, arr, priority_tag<3> {});
}
|
O3
|
cpp
|
decltype(from_json_array_impl(fp, fp0, nlohmann::json_abi_v3_11_3::detail::priority_tag<3u>{}), fp.get<std::vector<int, std::allocator<int>>::value_type>(), (void)()) nlohmann::json_abi_v3_11_3::detail::from_json<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::vector<int, std::allocator<int>>, 0>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, std::vector<int, std::allocator<int>>&):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %r14
cmpb $0x2, (%rdi)
jne 0x375b8
movq %r14, %rdi
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
jmp 0x376d6
movl $0x20, %edi
callq 0x21660
movq %rax, %rbx
movq %r14, %rdi
callq 0x2e874
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
leaq 0xe6156(%rip), %rsi # 0x11d732
leaq 0x10(%rsp), %rdi
callq 0x3764e
movb $0x1, %bpl
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
movl $0x12e, %esi # imm = 0x12E
movq %r14, %rcx
callq 0x2f1b4
xorl %ebp, %ebp
leaq 0x134381(%rip), %rsi # 0x16b988
leaq -0x5e04(%rip), %rdx # 0x3180a
movq %rbx, %rdi
callq 0x21a80
movq %rax, %r14
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x37634
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x21180
testb %bpl, %bpl
jne 0x3763e
jmp 0x37646
movq %rax, %r14
movq %rbx, %rdi
callq 0x21f50
movq %r14, %rdi
callq 0x21b20
|
_ZN8nlohmann16json_abi_v3_11_36detail9from_jsonINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEES5_IiSaIiEETnNSt9enable_ifIXaaaaaaaasr27is_constructible_array_typeIT_T0_EE5valuentsr28is_constructible_object_typeISJ_SK_EE5valuentsr28is_constructible_string_typeISJ_SK_EE5valuentsr3std7is_sameISK_NSJ_8binary_tEEE5valuentsr13is_basic_jsonISK_EE5valueEiE4typeELi0EEEDTcmcmcl20from_json_array_implfp_fp0_tlNS1_12priority_tagILj3EEEEEcldtfp_3getINSK_10value_typeEEEcvv_EERKSJ_RSK_:
push rbp; void *
push r14; int
push rbx; __int64
sub rsp, 30h
mov r14, rdi
cmp byte ptr [rdi], 2
jnz short loc_375B8
mov rdi, r14
add rsp, 30h
pop rbx
pop r14
pop rbp
jmp _ZN8nlohmann16json_abi_v3_11_36detail20from_json_array_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEES5_IiSaIiEETnNSt9enable_ifIXsr3std13is_assignableIRT0_SJ_EE5valueEiE4typeELi0EEEDTcmcmcldtfp0_7reserveclsr3stdE7declvalINSJ_9size_typeEEEEcldtfp_3getINSJ_10value_typeEEEcvv_EERKT_SK_NS1_12priority_tagILj1EEE
loc_375B8:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void)
lea rdx, [rsp+48h+var_40]
mov [rdx], rax
lea rsi, aTypeMustBeArra; "type must be array, but is "
lea rdi, [rsp+48h+var_38]
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA28_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[28],char const*>(char const(&)[28],char const* &&)
mov bpl, 1
lea rdx, [rsp+48h+var_38]
mov rdi, rbx; this
mov esi, 12Eh; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+48h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_37634
mov rsi, [rsp+48h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_37634:
test bpl, bpl
jnz short loc_3763E
jmp short loc_37646
mov r14, rax
loc_3763E:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_37646:
mov rdi, r14
call __Unwind_Resume
|
long long ZN8nlohmann16json_abi_v3_11_36detail9from_jsonINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEES5_IiSaIiEETnNSt9enable_ifIXaaaaaaaasr27is_constructible_array_typeIT_T0_EE5valuentsr28is_constructible_object_typeISJ_SK_EE5valuentsr28is_constructible_string_typeISJ_SK_EE5valuentsr3std7is_sameISK_NSJ_8binary_tEEE5valuentsr13is_basic_jsonISK_EE5valueEiE4typeELi0EEEDTcmcmcl20from_json_array_implfp_fp0_tlNS1_12priority_tagILj3EEEEEcldtfp_3getINSK_10value_typeEEEcvv_EERKSJ_RSK_(
unsigned __int8 *a1,
int a2,
int a3,
int a4,
int a5,
int a6,
int a7,
long long a8)
{
nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx
_QWORD v10[2]; // [rsp+10h] [rbp-38h] BYREF
if ( *a1 != 2 )
{
exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name(a1);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[28],char const*>(
v10,
"type must be array, but is ");
ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_(
exception,
302,
v10);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
return ZN8nlohmann16json_abi_v3_11_36detail20from_json_array_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEES5_IiSaIiEETnNSt9enable_ifIXsr3std13is_assignableIRT0_SJ_EE5valueEiE4typeELi0EEEDTcmcmcldtfp0_7reserveclsr3stdE7declvalINSJ_9size_typeEEEEcldtfp_3getINSJ_10value_typeEEEcvv_EERKT_SK_NS1_12priority_tagILj1EEE(
(_DWORD)a1,
a2,
a3,
a4,
a5,
a6,
a7,
a8);
}
|
_ZN8nlohmann16json_abi_v3_11_36detail9from_jsonINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEES5_IiSaIiEETnNSt9enable_ifIXaaaaaaaasr27is_constructible_array_typeIT_T0_EE5valuentsr28is_constructible_object_typeISJ_SK_EE5valuentsr28is_constructible_string_typeISJ_SK_EE5valuentsr3std7is_sameISK_NSJ_8binary_tEEE5valuentsr13is_basic_jsonISK_EE5valueEiE4typeELi0EEEDTcmcmcl20from_json_array_implfp_fp0_tlNS1_12priority_tagILj3EEEEEcldtfp_3getINSK_10value_typeEEEcvv_EERKSJ_RSK_:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV R14,RDI
CMP byte ptr [RDI],0x2
JNZ 0x001375b8
MOV RDI,R14
ADD RSP,0x30
POP RBX
POP R14
POP RBP
JMP 0x001376d6
LAB_001375b8:
MOV EDI,0x20
CALL 0x00121660
MOV RBX,RAX
MOV RDI,R14
CALL 0x0012e874
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],RAX
LAB_001375d5:
LEA RSI,[0x21d732]
LEA RDI,[RSP + 0x10]
CALL 0x0013764e
MOV BPL,0x1
LAB_001375e9:
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
MOV ESI,0x12e
MOV RCX,R14
CALL 0x0012f1b4
XOR EBP,EBP
LEA RSI,[0x26b988]
LEA RDX,[0x13180a]
MOV RDI,RBX
CALL 0x00121a80
|
void _ZN8nlohmann16json_abi_v3_11_36detail9from_jsonINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEES5_IiSaIiEETnNSt9enable_ifIXaaaaaaaasr27is_constructible_array_typeIT_T0_EE5valuentsr28is_constructible_object_typeISJ_SK_EE5valuentsr28is_constructible_string_typeISJ_SK_EE5valuentsr3std7is_sameISK_NSJ_8binary_tEEE5valuentsr13is_basic_jsonISK_EE5valueEiE4typeELi0EEEDTcmcmcl20from_json_array_implfp_fp0_tlNS1_12priority_tagILj3EEEEEcldtfp_3getINSK_10value_typeEEEcvv_EERKSJ_RSK_
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*param_1)
{
int8 uVar1;
char *local_40;
detail local_38 [32];
if (*param_1 ==
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2) {
_ZN8nlohmann16json_abi_v3_11_36detail20from_json_array_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEES5_IiSaIiEETnNSt9enable_ifIXsr3std13is_assignableIRT0_SJ_EE5valueEiE4typeELi0EEEDTcmcmcldtfp0_7reserveclsr3stdE7declvalINSJ_9size_typeEEEEcldtfp_3getINSJ_10value_typeEEEcvv_EERKT_SK_NS1_12priority_tagILj1EEE
(param_1);
return;
}
uVar1 = __cxa_allocate_exception(0x20);
local_40 = (char *)nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::type_name(param_1);
/* try { // try from 001375d5 to 001375e5 has its CatchHandler @ 0013763b */
nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[28],char_const*>
(local_38,"type must be array, but is ",&local_40);
/* try { // try from 001375e9 to 00137615 has its CatchHandler @ 00137616 */
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
(uVar1,0x12e,local_38,param_1);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar1,&nlohmann::json_abi_v3_11_3::detail::type_error::typeinfo,
nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
|
|
19,933
|
my_append_fix_badly_formed_tail
|
eloqsql/strings/ctype-mb.c
|
static size_t
my_append_fix_badly_formed_tail(CHARSET_INFO *cs,
char *to, char *to_end,
const char *from, const char *from_end,
size_t nchars,
MY_STRCOPY_STATUS *status)
{
char *to0= to;
for ( ; nchars; nchars--)
{
int chlen;
if ((chlen= my_ci_charlen(cs, (const uchar*) from,
(const uchar *) from_end)) > 0)
{
/* Found a valid character */ /* chlen == 1..MBMAXLEN */
DBUG_ASSERT(chlen <= (int) cs->mbmaxlen);
if (to + chlen > to_end)
goto end; /* Does not fit to "to" */
memcpy(to, from, (size_t) chlen);
from+= chlen;
to+= chlen;
continue;
}
if (chlen == MY_CS_ILSEQ) /* chlen == 0 */
{
DBUG_ASSERT(from < from_end); /* Shouldn't get MY_CS_ILSEQ if empty */
goto bad;
}
/* Got an incomplete character */ /* chlen == MY_CS_TOOSMALLXXX */
DBUG_ASSERT(chlen >= MY_CS_TOOSMALL6);
DBUG_ASSERT(chlen <= MY_CS_TOOSMALL);
if (from >= from_end)
break; /* End of the source string */
bad:
/* Bad byte sequence, or incomplete character found */
if (!status->m_well_formed_error_pos)
status->m_well_formed_error_pos= from;
if ((chlen= my_ci_wc_mb(cs, '?', (uchar*) to, (uchar *) to_end)) <= 0)
break; /* Question mark does not fit into the destination */
to+= chlen;
from++;
}
end:
status->m_source_end_pos= from;
return to - to0;
}
|
O0
|
c
|
my_append_fix_badly_formed_tail:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq 0x10(%rbp), %rax
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x30(%rbp)
je 0x510d5
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
callq 0x506e0
movl %eax, -0x3c(%rbp)
cmpl $0x0, %eax
jle 0x51042
jmp 0x50ff2
jmp 0x50ff4
movq -0x10(%rbp), %rax
movslq -0x3c(%rbp), %rcx
addq %rcx, %rax
cmpq -0x18(%rbp), %rax
jbe 0x5100a
jmp 0x510d7
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rsi
movslq -0x3c(%rbp), %rdx
callq 0x25230
movl -0x3c(%rbp), %ecx
movq -0x20(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movl -0x3c(%rbp), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
jmp 0x510c4
cmpl $0x0, -0x3c(%rbp)
jne 0x5104e
jmp 0x5104a
jmp 0x5104c
jmp 0x51064
jmp 0x51050
jmp 0x51052
jmp 0x51054
jmp 0x51056
movq -0x20(%rbp), %rax
cmpq -0x28(%rbp), %rax
jb 0x51062
jmp 0x510d5
jmp 0x51064
movq 0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x5107b
movq -0x20(%rbp), %rcx
movq 0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x8(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x30(%rax), %rax
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x18(%rbp), %rcx
movl $0x3f, %esi
callq *%rax
movl %eax, -0x3c(%rbp)
cmpl $0x0, %eax
jg 0x510a7
jmp 0x510d5
movl -0x3c(%rbp), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x30(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x50fcc
jmp 0x510d7
movq -0x20(%rbp), %rcx
movq 0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq -0x38(%rbp), %rcx
subq %rcx, %rax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
my_append_fix_badly_formed_tail:
push rbp
mov rbp, rsp
sub rsp, 40h
mov rax, [rbp+arg_0]
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov [rbp+var_30], r9
mov rax, [rbp+var_10]
mov [rbp+var_38], rax
loc_50FCC:
cmp [rbp+var_30], 0
jz loc_510D5
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_28]
call my_ci_charlen_2
mov [rbp+var_3C], eax
cmp eax, 0
jle short loc_51042
jmp short $+2
loc_50FF2:
jmp short $+2
loc_50FF4:
mov rax, [rbp+var_10]
movsxd rcx, [rbp+var_3C]
add rax, rcx
cmp rax, [rbp+var_18]
jbe short loc_5100A
jmp loc_510D7
loc_5100A:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_20]
movsxd rdx, [rbp+var_3C]
call _memcpy
mov ecx, [rbp+var_3C]
mov rax, [rbp+var_20]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_20], rax
mov ecx, [rbp+var_3C]
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
jmp loc_510C4
loc_51042:
cmp [rbp+var_3C], 0
jnz short loc_5104E
jmp short $+2
loc_5104A:
jmp short $+2
loc_5104C:
jmp short loc_51064
loc_5104E:
jmp short $+2
loc_51050:
jmp short $+2
loc_51052:
jmp short $+2
loc_51054:
jmp short $+2
loc_51056:
mov rax, [rbp+var_20]
cmp rax, [rbp+var_28]
jb short loc_51062
jmp short loc_510D5
loc_51062:
jmp short $+2
loc_51064:
mov rax, [rbp+arg_0]
cmp qword ptr [rax+8], 0
jnz short loc_5107B
mov rcx, [rbp+var_20]
mov rax, [rbp+arg_0]
mov [rax+8], rcx
loc_5107B:
mov rax, [rbp+var_8]
mov rax, [rax+0B8h]
mov rax, [rax+30h]
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov rcx, [rbp+var_18]
mov esi, 3Fh ; '?'
call rax
mov [rbp+var_3C], eax
cmp eax, 0
jg short loc_510A7
jmp short loc_510D5
loc_510A7:
mov ecx, [rbp+var_3C]
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
loc_510C4:
mov rax, [rbp+var_30]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_30], rax
jmp loc_50FCC
loc_510D5:
jmp short $+2
loc_510D7:
mov rcx, [rbp+var_20]
mov rax, [rbp+arg_0]
mov [rax], rcx
mov rax, [rbp+var_10]
mov rcx, [rbp+var_38]
sub rax, rcx
add rsp, 40h
pop rbp
retn
|
long long my_append_fix_badly_formed_tail(
long long a1,
long long a2,
unsigned long long a3,
unsigned long long a4,
unsigned long long a5,
long long a6,
unsigned long long *a7)
{
int v8; // [rsp+4h] [rbp-3Ch]
int v9; // [rsp+4h] [rbp-3Ch]
long long v14; // [rsp+30h] [rbp-10h]
v14 = a2;
while ( a6 )
{
v8 = my_ci_charlen_2(a1, a4, a5);
if ( v8 <= 0 )
{
if ( v8 && a4 >= a5 )
break;
if ( !a7[1] )
a7[1] = a4;
v9 = (*(long long ( **)(long long, long long, long long, unsigned long long))(*(_QWORD *)(a1 + 184) + 48LL))(
a1,
63LL,
v14,
a3);
if ( v9 <= 0 )
break;
v14 += v9;
++a4;
}
else
{
if ( v8 + v14 > a3 )
break;
memcpy(v14, a4, v8);
a4 += v8;
v14 += v8;
}
--a6;
}
*a7 = a4;
return v14 - a2;
}
|
my_append_fix_badly_formed_tail:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV qword ptr [RBP + -0x30],R9
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x38],RAX
LAB_00150fcc:
CMP qword ptr [RBP + -0x30],0x0
JZ 0x001510d5
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x28]
CALL 0x001506e0
MOV dword ptr [RBP + -0x3c],EAX
CMP EAX,0x0
JLE 0x00151042
JMP 0x00150ff2
LAB_00150ff2:
JMP 0x00150ff4
LAB_00150ff4:
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,dword ptr [RBP + -0x3c]
ADD RAX,RCX
CMP RAX,qword ptr [RBP + -0x18]
JBE 0x0015100a
JMP 0x001510d7
LAB_0015100a:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x20]
MOVSXD RDX,dword ptr [RBP + -0x3c]
CALL 0x00125230
MOV ECX,dword ptr [RBP + -0x3c]
MOV RAX,qword ptr [RBP + -0x20]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
MOV ECX,dword ptr [RBP + -0x3c]
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
JMP 0x001510c4
LAB_00151042:
CMP dword ptr [RBP + -0x3c],0x0
JNZ 0x0015104e
JMP 0x0015104a
LAB_0015104a:
JMP 0x0015104c
LAB_0015104c:
JMP 0x00151064
LAB_0015104e:
JMP 0x00151050
LAB_00151050:
JMP 0x00151052
LAB_00151052:
JMP 0x00151054
LAB_00151054:
JMP 0x00151056
LAB_00151056:
MOV RAX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RBP + -0x28]
JC 0x00151062
JMP 0x001510d5
LAB_00151062:
JMP 0x00151064
LAB_00151064:
MOV RAX,qword ptr [RBP + 0x10]
CMP qword ptr [RAX + 0x8],0x0
JNZ 0x0015107b
MOV RCX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RAX + 0x8],RCX
LAB_0015107b:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0x30]
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x18]
MOV ESI,0x3f
CALL RAX
MOV dword ptr [RBP + -0x3c],EAX
CMP EAX,0x0
JG 0x001510a7
JMP 0x001510d5
LAB_001510a7:
MOV ECX,dword ptr [RBP + -0x3c]
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
LAB_001510c4:
MOV RAX,qword ptr [RBP + -0x30]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x30],RAX
JMP 0x00150fcc
LAB_001510d5:
JMP 0x001510d7
LAB_001510d7:
MOV RCX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + 0x10]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x38]
SUB RAX,RCX
ADD RSP,0x40
POP RBP
RET
|
long my_append_fix_badly_formed_tail
(long param_1,void *param_2,ulong param_3,void *param_4,void *param_5,long param_6,
int8 *param_7)
{
int iVar1;
long local_38;
void *local_28;
void *local_18;
local_28 = param_4;
local_18 = param_2;
for (local_38 = param_6; local_38 != 0; local_38 = local_38 + -1) {
iVar1 = my_ci_charlen(param_1,local_28,param_5);
if (iVar1 < 1) {
if ((iVar1 != 0) && (param_5 <= local_28)) break;
if (param_7[1] == 0) {
param_7[1] = local_28;
}
iVar1 = (**(code **)(*(long *)(param_1 + 0xb8) + 0x30))(param_1,0x3f,local_18,param_3);
if (iVar1 < 1) break;
local_28 = (void *)((long)local_28 + 1);
}
else {
if (param_3 < (ulong)((long)local_18 + (long)iVar1)) break;
memcpy(local_18,local_28,(long)iVar1);
local_28 = (void *)((long)local_28 + (long)iVar1);
}
local_18 = (void *)((long)local_18 + (long)iVar1);
}
*param_7 = local_28;
return (long)local_18 - (long)param_2;
}
|
|
19,934
|
minja::Value::Value(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
|
monkey531[P]llama/common/minja.hpp
|
Value(const std::string & v) : primitive_(v) {}
|
O3
|
cpp
|
minja::Value::Value(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
addq $0x40, %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x30(%rbx)
movups %xmm0, 0x20(%rbx)
movups %xmm0, 0x10(%rbx)
movups %xmm0, (%rbx)
callq 0x302ae
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
movq 0x38(%rbx), %rdi
testq %rdi, %rdi
je 0x47353
callq 0x348da
movq %rbx, %rdi
callq 0x1b488
movq %rbx, %rdi
callq 0x447ce
movq %r14, %rdi
callq 0x1ad30
nop
|
_ZN5minja5ValueC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push r14
push rbx
push rax
mov rbx, rdi
add rdi, 40h ; '@'
xorps xmm0, xmm0
movups xmmword ptr [rbx+30h], xmm0
movups xmmword ptr [rbx+20h], xmm0
movups xmmword ptr [rbx+10h], xmm0
movups xmmword ptr [rbx], xmm0
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRKS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SI_EE5valueEiE4typeELi0EEEOT_
add rsp, 8
pop rbx
pop r14
retn
mov r14, rax
mov rdi, [rbx+38h]
test rdi, rdi
jz short loc_47353
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_47353:
mov rdi, rbx
call _ZN5minja5ValueC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE_cold_1; minja::Value::Value(std::string const&) [clone]
mov rdi, rbx
call _ZNSt23enable_shared_from_thisIN5minja5ValueEED2Ev; std::enable_shared_from_this<minja::Value>::~enable_shared_from_this()
mov rdi, r14
call __Unwind_Resume
|
long long minja::Value::Value(_OWORD *a1)
{
a1[3] = 0LL;
a1[2] = 0LL;
a1[1] = 0LL;
*a1 = 0LL;
return ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRKS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SI_EE5valueEiE4typeELi0EEEOT_(a1 + 4);
}
|
Value:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
ADD RDI,0x40
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x30],XMM0
MOVUPS xmmword ptr [RBX + 0x20],XMM0
MOVUPS xmmword ptr [RBX + 0x10],XMM0
MOVUPS xmmword ptr [RBX],XMM0
LAB_00147335:
CALL 0x001302ae
LAB_0014733a:
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* minja::Value::Value(std::__cxx11::string const&) */
void __thiscall minja::Value::Value(Value *this,string *param_1)
{
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
/* try { // try from 00147335 to 00147339 has its CatchHandler @ 00147342 */
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRKS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SI_EE5valueEiE4typeELi0EEEOT_
(this + 0x40);
return;
}
|
|
19,935
|
dequantize_row_iq2_xs
|
ngxson[P]ggml-easy/ggml/src/ggml-quants.c
|
void dequantize_row_iq2_xs(const block_iq2_xs * GGML_RESTRICT x, float * GGML_RESTRICT y, int64_t k) {
assert(k % QK_K == 0);
const int64_t nb = k / QK_K;
float db[2];
for (int i = 0; i < nb; i++) {
const float d = GGML_FP16_TO_FP32(x[i].d);
for (int ib32 = 0; ib32 < QK_K/32; ++ib32) {
db[0] = d * (0.5f + (x[i].scales[ib32] & 0xf)) * 0.25f;
db[1] = d * (0.5f + (x[i].scales[ib32] >> 4)) * 0.25f;
for (int l = 0; l < 4; ++l) {
const uint8_t * grid = (const uint8_t *)(iq2xs_grid + (x[i].qs[4*ib32 + l] & 511));
const uint8_t signs = ksigns_iq2xs[x[i].qs[4*ib32 + l] >> 9];
for (int j = 0; j < 8; ++j) {
y[j] = db[l/2] * grid[j] * (signs & kmask_iq2xs[j] ? -1.f : 1.f);
}
y += 8;
}
}
}
}
|
O0
|
c
|
dequantize_row_iq2_xs:
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq %rsi, 0x48(%rsp)
movq %rdx, 0x40(%rsp)
movq 0x40(%rsp), %rax
movl $0x100, %ecx # imm = 0x100
cqto
idivq %rcx
movq %rax, 0x38(%rsp)
movl $0x0, 0x2c(%rsp)
movslq 0x2c(%rsp), %rax
cmpq 0x38(%rsp), %rax
jge 0x79e27
movq 0x50(%rsp), %rax
movslq 0x2c(%rsp), %rcx
imulq $0x4a, %rcx, %rcx
addq %rcx, %rax
movzwl (%rax), %edi
callq 0x6f9d0
movss %xmm0, 0x28(%rsp)
movl $0x0, 0x24(%rsp)
cmpl $0x8, 0x24(%rsp)
jge 0x79e15
movss 0x28(%rsp), %xmm0
movq 0x50(%rsp), %rax
movslq 0x2c(%rsp), %rcx
imulq $0x4a, %rcx, %rcx
addq %rcx, %rax
movslq 0x24(%rsp), %rcx
movzbl 0x42(%rax,%rcx), %eax
andl $0xf, %eax
cvtsi2ss %eax, %xmm2
movss 0x3a7df(%rip), %xmm1 # 0xb4420
addss %xmm2, %xmm1
mulss %xmm1, %xmm0
movss 0x3ebf3(%rip), %xmm1 # 0xb8844
mulss %xmm1, %xmm0
movss %xmm0, 0x30(%rsp)
movss 0x28(%rsp), %xmm0
movq 0x50(%rsp), %rax
movslq 0x2c(%rsp), %rcx
imulq $0x4a, %rcx, %rcx
addq %rcx, %rax
movslq 0x24(%rsp), %rcx
movzbl 0x42(%rax,%rcx), %eax
sarl $0x4, %eax
cvtsi2ss %eax, %xmm2
movss 0x3a795(%rip), %xmm1 # 0xb4420
addss %xmm2, %xmm1
mulss %xmm1, %xmm0
movss 0x3eba9(%rip), %xmm1 # 0xb8844
mulss %xmm1, %xmm0
movss %xmm0, 0x34(%rsp)
movl $0x0, 0x20(%rsp)
cmpl $0x4, 0x20(%rsp)
jge 0x79e03
movq 0x50(%rsp), %rax
movslq 0x2c(%rsp), %rcx
imulq $0x4a, %rcx, %rcx
addq %rcx, %rax
movl 0x24(%rsp), %ecx
shll $0x2, %ecx
addl 0x20(%rsp), %ecx
movslq %ecx, %rcx
movzwl 0x2(%rax,%rcx,2), %eax
andl $0x1ff, %eax # imm = 0x1FF
movslq %eax, %rcx
leaq 0x3f4f5(%rip), %rax # 0xb91e0
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, 0x18(%rsp)
movq 0x50(%rsp), %rax
movslq 0x2c(%rsp), %rcx
imulq $0x4a, %rcx, %rcx
addq %rcx, %rax
movl 0x24(%rsp), %ecx
shll $0x2, %ecx
addl 0x20(%rsp), %ecx
movslq %ecx, %rcx
movzwl 0x2(%rax,%rcx,2), %eax
sarl $0x9, %eax
movslq %eax, %rcx
leaq 0x3f428(%rip), %rax # 0xb9150
movb (%rax,%rcx), %al
movb %al, 0x17(%rsp)
movl $0x0, 0x10(%rsp)
cmpl $0x8, 0x10(%rsp)
jge 0x79de5
movl 0x20(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
cltq
movss 0x30(%rsp,%rax,4), %xmm0
movq 0x18(%rsp), %rax
movslq 0x10(%rsp), %rcx
movzbl (%rax,%rcx), %eax
cvtsi2ss %eax, %xmm1
mulss %xmm1, %xmm0
movss %xmm0, 0x4(%rsp)
movzbl 0x17(%rsp), %eax
movslq 0x10(%rsp), %rdx
leaq 0x3f44d(%rip), %rcx # 0xb91d0
movzbl (%rcx,%rdx), %ecx
andl %ecx, %eax
movss 0x3eaab(%rip), %xmm0 # 0xb883c
movss 0x3a68f(%rip), %xmm1 # 0xb4428
movss %xmm1, 0x8(%rsp)
cmpl $0x0, %eax
movss %xmm0, 0xc(%rsp)
jne 0x79db6
movss 0x8(%rsp), %xmm0
movss %xmm0, 0xc(%rsp)
movss 0x4(%rsp), %xmm0
movss 0xc(%rsp), %xmm1
mulss %xmm1, %xmm0
movq 0x48(%rsp), %rax
movslq 0x10(%rsp), %rcx
movss %xmm0, (%rax,%rcx,4)
movl 0x10(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x10(%rsp)
jmp 0x79d37
movq 0x48(%rsp), %rax
addq $0x20, %rax
movq %rax, 0x48(%rsp)
movl 0x20(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x20(%rsp)
jmp 0x79cad
jmp 0x79e05
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x79c06
jmp 0x79e17
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
jmp 0x79bcf
addq $0x58, %rsp
retq
nopl (%rax)
|
dequantize_row_iq2_xs:
sub rsp, 58h
mov [rsp+58h+var_8], rdi
mov [rsp+58h+var_10], rsi
mov [rsp+58h+var_18], rdx
mov rax, [rsp+58h+var_18]
mov ecx, 100h
cqo
idiv rcx
mov [rsp+58h+var_20], rax
mov [rsp+58h+var_2C], 0
loc_79BCF:
movsxd rax, [rsp+58h+var_2C]
cmp rax, [rsp+58h+var_20]
jge loc_79E27
mov rax, [rsp+58h+var_8]
movsxd rcx, [rsp+58h+var_2C]
imul rcx, 4Ah ; 'J'
add rax, rcx
movzx edi, word ptr [rax]
call ggml_lookup_fp16_to_fp32_0
movss [rsp+58h+var_30], xmm0
mov [rsp+58h+var_34], 0
loc_79C06:
cmp [rsp+58h+var_34], 8
jge loc_79E15
movss xmm0, [rsp+58h+var_30]
mov rax, [rsp+58h+var_8]
movsxd rcx, [rsp+58h+var_2C]
imul rcx, 4Ah ; 'J'
add rax, rcx
movsxd rcx, [rsp+58h+var_34]
movzx eax, byte ptr [rax+rcx+42h]
and eax, 0Fh
cvtsi2ss xmm2, eax
movss xmm1, cs:dword_B4420
addss xmm1, xmm2
mulss xmm0, xmm1
movss xmm1, cs:dword_B8844
mulss xmm0, xmm1
movss [rsp+58h+var_28], xmm0
movss xmm0, [rsp+58h+var_30]
mov rax, [rsp+58h+var_8]
movsxd rcx, [rsp+58h+var_2C]
imul rcx, 4Ah ; 'J'
add rax, rcx
movsxd rcx, [rsp+58h+var_34]
movzx eax, byte ptr [rax+rcx+42h]
sar eax, 4
cvtsi2ss xmm2, eax
movss xmm1, cs:dword_B4420
addss xmm1, xmm2
mulss xmm0, xmm1
movss xmm1, cs:dword_B8844
mulss xmm0, xmm1
movss [rsp+58h+var_24], xmm0
mov [rsp+58h+var_38], 0
loc_79CAD:
cmp [rsp+58h+var_38], 4
jge loc_79E03
mov rax, [rsp+58h+var_8]
movsxd rcx, [rsp+58h+var_2C]
imul rcx, 4Ah ; 'J'
add rax, rcx
mov ecx, [rsp+58h+var_34]
shl ecx, 2
add ecx, [rsp+58h+var_38]
movsxd rcx, ecx
movzx eax, word ptr [rax+rcx*2+2]
and eax, 1FFh
movsxd rcx, eax
lea rax, iq2xs_grid
shl rcx, 3
add rax, rcx
mov [rsp+58h+var_40], rax
mov rax, [rsp+58h+var_8]
movsxd rcx, [rsp+58h+var_2C]
imul rcx, 4Ah ; 'J'
add rax, rcx
mov ecx, [rsp+58h+var_34]
shl ecx, 2
add ecx, [rsp+58h+var_38]
movsxd rcx, ecx
movzx eax, word ptr [rax+rcx*2+2]
sar eax, 9
movsxd rcx, eax
lea rax, ksigns_iq2xs
mov al, [rax+rcx]
mov [rsp+58h+var_41], al
mov [rsp+58h+var_48], 0
loc_79D37:
cmp [rsp+58h+var_48], 8
jge loc_79DE5
mov eax, [rsp+58h+var_38]
mov ecx, 2
cdq
idiv ecx
cdqe
movss xmm0, [rsp+rax*4+58h+var_28]
mov rax, [rsp+58h+var_40]
movsxd rcx, [rsp+58h+var_48]
movzx eax, byte ptr [rax+rcx]
cvtsi2ss xmm1, eax
mulss xmm0, xmm1
movss [rsp+58h+var_54], xmm0
movzx eax, [rsp+58h+var_41]
movsxd rdx, [rsp+58h+var_48]
lea rcx, kmask_iq2xs
movzx ecx, byte ptr [rcx+rdx]
and eax, ecx
movss xmm0, cs:dword_B883C
movss xmm1, cs:dword_B4428
movss [rsp+58h+var_50], xmm1
cmp eax, 0
movss [rsp+58h+var_4C], xmm0
jnz short loc_79DB6
movss xmm0, [rsp+58h+var_50]
movss [rsp+58h+var_4C], xmm0
loc_79DB6:
movss xmm0, [rsp+58h+var_54]
movss xmm1, [rsp+58h+var_4C]
mulss xmm0, xmm1
mov rax, [rsp+58h+var_10]
movsxd rcx, [rsp+58h+var_48]
movss dword ptr [rax+rcx*4], xmm0
mov eax, [rsp+58h+var_48]
add eax, 1
mov [rsp+58h+var_48], eax
jmp loc_79D37
loc_79DE5:
mov rax, [rsp+58h+var_10]
add rax, 20h ; ' '
mov [rsp+58h+var_10], rax
mov eax, [rsp+58h+var_38]
add eax, 1
mov [rsp+58h+var_38], eax
jmp loc_79CAD
loc_79E03:
jmp short $+2
loc_79E05:
mov eax, [rsp+58h+var_34]
add eax, 1
mov [rsp+58h+var_34], eax
jmp loc_79C06
loc_79E15:
jmp short $+2
loc_79E17:
mov eax, [rsp+58h+var_2C]
add eax, 1
mov [rsp+58h+var_2C], eax
jmp loc_79BCF
loc_79E27:
add rsp, 58h
retn
|
long long dequantize_row_iq2_xs(long long a1, long long a2, long long a3)
{
long long result; // rax
float v4; // [rsp+Ch] [rbp-4Ch]
int m; // [rsp+10h] [rbp-48h]
unsigned __int8 v6; // [rsp+17h] [rbp-41h]
char *v7; // [rsp+18h] [rbp-40h]
int k; // [rsp+20h] [rbp-38h]
int j; // [rsp+24h] [rbp-34h]
float v10; // [rsp+28h] [rbp-30h]
int i; // [rsp+2Ch] [rbp-2Ch]
float v12[2]; // [rsp+30h] [rbp-28h]
long long v13; // [rsp+38h] [rbp-20h]
long long v14; // [rsp+40h] [rbp-18h]
long long v15; // [rsp+48h] [rbp-10h]
long long v16; // [rsp+50h] [rbp-8h]
v16 = a1;
v15 = a2;
v14 = a3;
v13 = a3 / 256;
for ( i = 0; ; ++i )
{
result = i;
if ( i >= v13 )
break;
v10 = ggml_lookup_fp16_to_fp32_0(*(_WORD *)(74LL * i + v16));
for ( j = 0; j < 8; ++j )
{
v12[0] = (float)(v10 * (float)((float)(*(_BYTE *)(74LL * i + v16 + j + 66) & 0xF) + 0.5)) * 0.25;
v12[1] = (float)(v10 * (float)((float)((int)*(unsigned __int8 *)(74LL * i + v16 + j + 66) >> 4) + 0.5)) * 0.25;
for ( k = 0; k < 4; ++k )
{
v7 = (char *)&iq2xs_grid + 8 * (*(_WORD *)(74LL * i + v16 + 2LL * (k + 4 * j) + 2) & 0x1FF);
v6 = ksigns_iq2xs[(int)*(unsigned __int16 *)(74LL * i + v16 + 2LL * (k + 4 * j) + 2) >> 9];
for ( m = 0; m < 8; ++m )
{
v4 = -1.0;
if ( (kmask_iq2xs[m] & v6) == 0 )
v4 = 1.0;
*(float *)(v15 + 4LL * m) = (float)(v12[k / 2] * (float)(unsigned __int8)v7[m]) * v4;
}
v15 += 32LL;
}
}
}
return result;
}
|
dequantize_row_iq2_xs:
SUB RSP,0x58
MOV qword ptr [RSP + 0x50],RDI
MOV qword ptr [RSP + 0x48],RSI
MOV qword ptr [RSP + 0x40],RDX
MOV RAX,qword ptr [RSP + 0x40]
MOV ECX,0x100
CQO
IDIV RCX
MOV qword ptr [RSP + 0x38],RAX
MOV dword ptr [RSP + 0x2c],0x0
LAB_00179bcf:
MOVSXD RAX,dword ptr [RSP + 0x2c]
CMP RAX,qword ptr [RSP + 0x38]
JGE 0x00179e27
MOV RAX,qword ptr [RSP + 0x50]
MOVSXD RCX,dword ptr [RSP + 0x2c]
IMUL RCX,RCX,0x4a
ADD RAX,RCX
MOVZX EDI,word ptr [RAX]
CALL 0x0016f9d0
MOVSS dword ptr [RSP + 0x28],XMM0
MOV dword ptr [RSP + 0x24],0x0
LAB_00179c06:
CMP dword ptr [RSP + 0x24],0x8
JGE 0x00179e15
MOVSS XMM0,dword ptr [RSP + 0x28]
MOV RAX,qword ptr [RSP + 0x50]
MOVSXD RCX,dword ptr [RSP + 0x2c]
IMUL RCX,RCX,0x4a
ADD RAX,RCX
MOVSXD RCX,dword ptr [RSP + 0x24]
MOVZX EAX,byte ptr [RAX + RCX*0x1 + 0x42]
AND EAX,0xf
CVTSI2SS XMM2,EAX
MOVSS XMM1,dword ptr [0x001b4420]
ADDSS XMM1,XMM2
MULSS XMM0,XMM1
MOVSS XMM1,dword ptr [0x001b8844]
MULSS XMM0,XMM1
MOVSS dword ptr [RSP + 0x30],XMM0
MOVSS XMM0,dword ptr [RSP + 0x28]
MOV RAX,qword ptr [RSP + 0x50]
MOVSXD RCX,dword ptr [RSP + 0x2c]
IMUL RCX,RCX,0x4a
ADD RAX,RCX
MOVSXD RCX,dword ptr [RSP + 0x24]
MOVZX EAX,byte ptr [RAX + RCX*0x1 + 0x42]
SAR EAX,0x4
CVTSI2SS XMM2,EAX
MOVSS XMM1,dword ptr [0x001b4420]
ADDSS XMM1,XMM2
MULSS XMM0,XMM1
MOVSS XMM1,dword ptr [0x001b8844]
MULSS XMM0,XMM1
MOVSS dword ptr [RSP + 0x34],XMM0
MOV dword ptr [RSP + 0x20],0x0
LAB_00179cad:
CMP dword ptr [RSP + 0x20],0x4
JGE 0x00179e03
MOV RAX,qword ptr [RSP + 0x50]
MOVSXD RCX,dword ptr [RSP + 0x2c]
IMUL RCX,RCX,0x4a
ADD RAX,RCX
MOV ECX,dword ptr [RSP + 0x24]
SHL ECX,0x2
ADD ECX,dword ptr [RSP + 0x20]
MOVSXD RCX,ECX
MOVZX EAX,word ptr [RAX + RCX*0x2 + 0x2]
AND EAX,0x1ff
MOVSXD RCX,EAX
LEA RAX,[0x1b91e0]
SHL RCX,0x3
ADD RAX,RCX
MOV qword ptr [RSP + 0x18],RAX
MOV RAX,qword ptr [RSP + 0x50]
MOVSXD RCX,dword ptr [RSP + 0x2c]
IMUL RCX,RCX,0x4a
ADD RAX,RCX
MOV ECX,dword ptr [RSP + 0x24]
SHL ECX,0x2
ADD ECX,dword ptr [RSP + 0x20]
MOVSXD RCX,ECX
MOVZX EAX,word ptr [RAX + RCX*0x2 + 0x2]
SAR EAX,0x9
MOVSXD RCX,EAX
LEA RAX,[0x1b9150]
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RSP + 0x17],AL
MOV dword ptr [RSP + 0x10],0x0
LAB_00179d37:
CMP dword ptr [RSP + 0x10],0x8
JGE 0x00179de5
MOV EAX,dword ptr [RSP + 0x20]
MOV ECX,0x2
CDQ
IDIV ECX
CDQE
MOVSS XMM0,dword ptr [RSP + RAX*0x4 + 0x30]
MOV RAX,qword ptr [RSP + 0x18]
MOVSXD RCX,dword ptr [RSP + 0x10]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
CVTSI2SS XMM1,EAX
MULSS XMM0,XMM1
MOVSS dword ptr [RSP + 0x4],XMM0
MOVZX EAX,byte ptr [RSP + 0x17]
MOVSXD RDX,dword ptr [RSP + 0x10]
LEA RCX,[0x1b91d0]
MOVZX ECX,byte ptr [RCX + RDX*0x1]
AND EAX,ECX
MOVSS XMM0,dword ptr [0x001b883c]
MOVSS XMM1,dword ptr [0x001b4428]
MOVSS dword ptr [RSP + 0x8],XMM1
CMP EAX,0x0
MOVSS dword ptr [RSP + 0xc],XMM0
JNZ 0x00179db6
MOVSS XMM0,dword ptr [RSP + 0x8]
MOVSS dword ptr [RSP + 0xc],XMM0
LAB_00179db6:
MOVSS XMM0,dword ptr [RSP + 0x4]
MOVSS XMM1,dword ptr [RSP + 0xc]
MULSS XMM0,XMM1
MOV RAX,qword ptr [RSP + 0x48]
MOVSXD RCX,dword ptr [RSP + 0x10]
MOVSS dword ptr [RAX + RCX*0x4],XMM0
MOV EAX,dword ptr [RSP + 0x10]
ADD EAX,0x1
MOV dword ptr [RSP + 0x10],EAX
JMP 0x00179d37
LAB_00179de5:
MOV RAX,qword ptr [RSP + 0x48]
ADD RAX,0x20
MOV qword ptr [RSP + 0x48],RAX
MOV EAX,dword ptr [RSP + 0x20]
ADD EAX,0x1
MOV dword ptr [RSP + 0x20],EAX
JMP 0x00179cad
LAB_00179e03:
JMP 0x00179e05
LAB_00179e05:
MOV EAX,dword ptr [RSP + 0x24]
ADD EAX,0x1
MOV dword ptr [RSP + 0x24],EAX
JMP 0x00179c06
LAB_00179e15:
JMP 0x00179e17
LAB_00179e17:
MOV EAX,dword ptr [RSP + 0x2c]
ADD EAX,0x1
MOV dword ptr [RSP + 0x2c],EAX
JMP 0x00179bcf
LAB_00179e27:
ADD RSP,0x58
RET
|
void dequantize_row_iq2_xs(long param_1,long param_2,long param_3)
{
byte bVar1;
ushort uVar2;
float fVar3;
float local_4c;
int local_48;
int local_38;
int local_34;
int local_2c;
float local_28 [2];
long local_20;
long local_18;
long local_10;
long local_8;
local_20 = param_3 / 0x100;
local_18 = param_3;
local_10 = param_2;
local_8 = param_1;
for (local_2c = 0; local_2c < local_20; local_2c = local_2c + 1) {
fVar3 = (float)ggml_lookup_fp16_to_fp32(*(int2 *)(local_8 + (long)local_2c * 0x4a));
for (local_34 = 0; local_34 < 8; local_34 = local_34 + 1) {
local_28[0] = fVar3 * (DAT_001b4420 +
(float)(*(byte *)(local_8 + (long)local_2c * 0x4a + 0x42 +
(long)local_34) & 0xf)) * DAT_001b8844;
local_28[1] = fVar3 * (DAT_001b4420 +
(float)((int)(uint)*(byte *)(local_8 + (long)local_2c * 0x4a + 0x42 +
(long)local_34) >> 4)) * DAT_001b8844;
for (local_38 = 0; local_38 < 4; local_38 = local_38 + 1) {
uVar2 = *(ushort *)
(local_8 + (long)local_2c * 0x4a + 2 + (long)(local_34 * 4 + local_38) * 2);
bVar1 = ksigns_iq2xs
[(int)(uint)*(ushort *)
(local_8 + (long)local_2c * 0x4a + 2 +
(long)(local_34 * 4 + local_38) * 2) >> 9];
for (local_48 = 0; local_48 < 8; local_48 = local_48 + 1) {
local_4c = DAT_001b883c;
if ((bVar1 & *(byte *)((long)&kmask_iq2xs + (long)local_48)) == 0) {
local_4c = DAT_001b4428;
}
*(float *)(local_10 + (long)local_48 * 4) =
local_28[local_38 / 2] *
(float)(byte)iq2xs_grid[(long)local_48 + (long)(int)(uVar2 & 0x1ff) * 8] * local_4c;
}
local_10 = local_10 + 0x20;
}
}
}
return;
}
|
|
19,936
|
pvio_socket_read
|
eloqsql/libmariadb/plugins/pvio/pvio_socket.c
|
ssize_t pvio_socket_read(MARIADB_PVIO *pvio, uchar *buffer, size_t length)
{
ssize_t r;
int read_flags= MSG_DONTWAIT;
struct st_pvio_socket *csock;
int timeout;
if (!pvio || !pvio->data)
return -1;
csock= (struct st_pvio_socket *)pvio->data;
timeout = pvio->timeout[PVIO_READ_TIMEOUT];
while ((r = ma_recv(csock->socket, (void *)buffer, length, read_flags)) == -1)
{
int err = socket_errno;
if ((err != SOCKET_EAGAIN
#ifdef HAVE_SOCKET_EWOULDBLOCK
&& err != SOCKET_EWOULDBLOCK
#endif
) || timeout == 0)
return r;
if (pvio_socket_wait_io_or_timeout(pvio, TRUE, timeout) < 1)
return -1;
}
return r;
}
|
O0
|
c
|
pvio_socket_read:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl $0x40, -0x2c(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x9bcec
movq -0x10(%rbp), %rax
cmpq $0x0, (%rax)
jne 0x9bcf6
movq $-0x1, -0x8(%rbp)
jmp 0x9bd75
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movl 0x28(%rax), %eax
movl %eax, -0x3c(%rbp)
movq -0x38(%rbp), %rax
movl (%rax), %edi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
movl -0x2c(%rbp), %ecx
callq 0x9d330
movq %rax, -0x28(%rbp)
cmpq $-0x1, %rax
jne 0x9bd6d
callq 0x3bb30
movl (%rax), %eax
movl %eax, -0x40(%rbp)
cmpl $0xb, -0x40(%rbp)
jne 0x9bd41
cmpl $0x0, -0x3c(%rbp)
jne 0x9bd4b
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x9bd75
movq -0x10(%rbp), %rdi
movl -0x3c(%rbp), %edx
movl $0x1, %esi
callq 0x9bf60
cmpl $0x1, %eax
jge 0x9bd6b
movq $-0x1, -0x8(%rbp)
jmp 0x9bd75
jmp 0x9bd0b
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nop
|
pvio_socket_read:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_2C], 40h ; '@'
cmp [rbp+var_10], 0
jz short loc_9BCEC
mov rax, [rbp+var_10]
cmp qword ptr [rax], 0
jnz short loc_9BCF6
loc_9BCEC:
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp short loc_9BD75
loc_9BCF6:
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_38], rax
mov rax, [rbp+var_10]
mov eax, [rax+28h]
mov [rbp+var_3C], eax
loc_9BD0B:
mov rax, [rbp+var_38]
mov edi, [rax]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_20]
mov ecx, [rbp+var_2C]
call ma_recv
mov [rbp+var_28], rax
cmp rax, 0FFFFFFFFFFFFFFFFh
jnz short loc_9BD6D
call ___errno_location
mov eax, [rax]
mov [rbp+var_40], eax
cmp [rbp+var_40], 0Bh
jnz short loc_9BD41
cmp [rbp+var_3C], 0
jnz short loc_9BD4B
loc_9BD41:
mov rax, [rbp+var_28]
mov [rbp+var_8], rax
jmp short loc_9BD75
loc_9BD4B:
mov rdi, [rbp+var_10]
mov edx, [rbp+var_3C]
mov esi, 1
call pvio_socket_wait_io_or_timeout
cmp eax, 1
jge short loc_9BD6B
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp short loc_9BD75
loc_9BD6B:
jmp short loc_9BD0B
loc_9BD6D:
mov rax, [rbp+var_28]
mov [rbp+var_8], rax
loc_9BD75:
mov rax, [rbp+var_8]
add rsp, 40h
pop rbp
retn
|
long long pvio_socket_read(unsigned int **a1, long long a2, long long a3)
{
long long v3; // rdi
unsigned int v5; // [rsp+4h] [rbp-3Ch]
unsigned int *v6; // [rsp+8h] [rbp-38h]
long long v7; // [rsp+18h] [rbp-28h]
if ( !a1 || !*a1 )
return -1LL;
v6 = *a1;
v5 = *((_DWORD *)a1 + 10);
while ( 1 )
{
v3 = *v6;
v7 = ma_recv(v3, a2, a3, 64LL);
if ( v7 != -1 )
break;
if ( *(_DWORD *)__errno_location(v3) != 11 || !v5 )
return -1LL;
if ( (int)pvio_socket_wait_io_or_timeout(a1, 1LL, v5) < 1 )
return -1LL;
}
return v7;
}
|
pvio_socket_read:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x2c],0x40
CMP qword ptr [RBP + -0x10],0x0
JZ 0x0019bcec
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX],0x0
JNZ 0x0019bcf6
LAB_0019bcec:
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x0019bd75
LAB_0019bcf6:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x28]
MOV dword ptr [RBP + -0x3c],EAX
LAB_0019bd0b:
MOV RAX,qword ptr [RBP + -0x38]
MOV EDI,dword ptr [RAX]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RBP + -0x2c]
CALL 0x0019d330
MOV qword ptr [RBP + -0x28],RAX
CMP RAX,-0x1
JNZ 0x0019bd6d
CALL 0x0013bb30
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x40],EAX
CMP dword ptr [RBP + -0x40],0xb
JNZ 0x0019bd41
CMP dword ptr [RBP + -0x3c],0x0
JNZ 0x0019bd4b
LAB_0019bd41:
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0019bd75
LAB_0019bd4b:
MOV RDI,qword ptr [RBP + -0x10]
MOV EDX,dword ptr [RBP + -0x3c]
MOV ESI,0x1
CALL 0x0019bf60
CMP EAX,0x1
JGE 0x0019bd6b
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x0019bd75
LAB_0019bd6b:
JMP 0x0019bd0b
LAB_0019bd6d:
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x8],RAX
LAB_0019bd75:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x40
POP RBP
RET
|
long pvio_socket_read(long *param_1,int8 param_2,int8 param_3)
{
int4 *puVar1;
long lVar2;
int iVar3;
long lVar4;
int *piVar5;
if ((param_1 != (long *)0x0) && (*param_1 != 0)) {
puVar1 = (int4 *)*param_1;
lVar2 = param_1[5];
do {
lVar4 = ma_recv(*puVar1,param_2,param_3,0x40);
if (lVar4 != -1) {
return lVar4;
}
piVar5 = __errno_location();
if (*piVar5 != 0xb) {
return -1;
}
if ((int)lVar2 == 0) {
return -1;
}
iVar3 = pvio_socket_wait_io_or_timeout(param_1,1,(int)lVar2);
} while (0 < iVar3);
}
return -1;
}
|
|
19,937
|
ma_pvio_tls_compare_fp
|
eloqsql/libmariadb/libmariadb/ma_tls.c
|
static my_bool ma_pvio_tls_compare_fp(const char *cert_fp,
unsigned int cert_fp_len,
const char *fp, unsigned int fp_len)
{
char *p= (char *)fp,
*c;
/* check length */
if (cert_fp_len != 20)
return 1;
/* We support two formats:
2 digits hex numbers, separated by colons (length=59)
20 * 2 digits hex numbers without separators (length = 40)
*/
if (fp_len != (strchr(fp, ':') ? 59 : 40))
return 1;
for(c= (char *)cert_fp; c < cert_fp + cert_fp_len; c++)
{
signed char d1, d2;
if (*p == ':')
p++;
if (p - fp > (int)fp_len -1)
return 1;
if ((d1 = ma_hex2int(*p)) == - 1 ||
(d2 = ma_hex2int(*(p+1))) == -1 ||
(char)(d1 * 16 + d2) != *c)
return 1;
p+= 2;
}
return 0;
}
|
O3
|
c
|
ma_pvio_tls_compare_fp:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movb $0x1, %bl
cmpl $0x14, %esi
jne 0x20a37
movl %ecx, %r14d
movq %rdx, %r15
movq %rdi, %r12
movq %rdx, %rdi
movl $0x3a, %esi
callq 0x13190
testq %rax, %rax
movl $0x28, %eax
movl $0x3b, %ecx
cmovel %eax, %ecx
cmpl %r14d, %ecx
jne 0x20a37
decl %r14d
xorl %eax, %eax
movq %r15, %rdx
xorl %ecx, %ecx
cmpb $0x3a, (%rdx)
sete %cl
addq %rdx, %rcx
movq %rcx, %rdx
subq %r15, %rdx
cmpq %r14, %rdx
jg 0x20a37
movb (%rcx), %sil
leal -0x30(%rsi), %edx
cmpb $0xa, %dl
jb 0x209ea
leal -0x41(%rsi), %edx
cmpb $0x5, %dl
ja 0x209dc
addb $-0x37, %sil
jmp 0x209e8
leal -0x67(%rsi), %edx
cmpb $-0x6, %dl
jb 0x20a37
addb $-0x57, %sil
movl %esi, %edx
movb 0x1(%rcx), %sil
leal -0x30(%rsi), %edi
cmpb $0xa, %dil
jb 0x20a15
leal -0x41(%rsi), %edi
cmpb $0x5, %dil
ja 0x20a06
addb $-0x37, %sil
jmp 0x20a13
leal -0x67(%rsi), %edi
cmpb $-0x6, %dil
jb 0x20a37
addb $-0x57, %sil
movl %esi, %edi
shlb $0x4, %dl
addb %dil, %dl
cmpb (%r12,%rax), %dl
jne 0x20a37
addq $0x2, %rcx
incq %rax
movq %rcx, %rdx
cmpq $0x14, %rax
jne 0x209ad
xorl %ebx, %ebx
movl %ebx, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
|
ma_pvio_tls_compare_fp:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
mov bl, 1
cmp esi, 14h
jnz loc_20A37
mov r14d, ecx
mov r15, rdx
mov r12, rdi
mov rdi, rdx
mov esi, 3Ah ; ':'
call _strchr
test rax, rax
mov eax, 28h ; '('
mov ecx, 3Bh ; ';'
cmovz ecx, eax
cmp ecx, r14d
jnz loc_20A37
dec r14d
xor eax, eax
mov rdx, r15
loc_209AD:
xor ecx, ecx
cmp byte ptr [rdx], 3Ah ; ':'
setz cl
add rcx, rdx
mov rdx, rcx
sub rdx, r15
cmp rdx, r14
jg short loc_20A37
mov sil, [rcx]
lea edx, [rsi-30h]
cmp dl, 0Ah
jb short loc_209EA
lea edx, [rsi-41h]
cmp dl, 5
ja short loc_209DC
add sil, 0C9h
jmp short loc_209E8
loc_209DC:
lea edx, [rsi-67h]
cmp dl, 0FAh
jb short loc_20A37
add sil, 0A9h
loc_209E8:
mov edx, esi
loc_209EA:
mov sil, [rcx+1]
lea edi, [rsi-30h]
cmp dil, 0Ah
jb short loc_20A15
lea edi, [rsi-41h]
cmp dil, 5
ja short loc_20A06
add sil, 0C9h
jmp short loc_20A13
loc_20A06:
lea edi, [rsi-67h]
cmp dil, 0FAh
jb short loc_20A37
add sil, 0A9h
loc_20A13:
mov edi, esi
loc_20A15:
shl dl, 4
add dl, dil
cmp dl, [r12+rax]
jnz short loc_20A37
add rcx, 2
inc rax
mov rdx, rcx
cmp rax, 14h
jnz loc_209AD
xor ebx, ebx
loc_20A37:
mov eax, ebx
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
|
long long ma_pvio_tls_compare_fp(long long a1, int a2, _BYTE *a3, int a4)
{
unsigned int v4; // ebx
long long v8; // rax
int v9; // ecx
long long v10; // r14
long long v11; // rax
_BYTE *v12; // rdx
char *v13; // rcx
char v14; // si
unsigned __int8 v15; // dl
unsigned __int8 v16; // si
char v17; // si
char v18; // di
char v19; // si
LOBYTE(v4) = 1;
if ( a2 == 20 )
{
v8 = strchr(a3, 58LL);
v9 = 59;
if ( !v8 )
v9 = 40;
if ( v9 == a4 )
{
v10 = (unsigned int)(a4 - 1);
v11 = 0LL;
v12 = a3;
while ( 1 )
{
v13 = &v12[*v12 == 58];
if ( v13 - a3 > v10 )
break;
v14 = *v13;
v15 = *v13 - 48;
if ( v15 >= 0xAu )
{
if ( (unsigned __int8)(v14 - 65) > 5u )
{
if ( (unsigned __int8)(v14 - 103) < 0xFAu )
return v4;
v16 = v14 - 87;
}
else
{
v16 = v14 - 55;
}
v15 = v16;
}
v17 = v13[1];
v18 = v17 - 48;
if ( (unsigned __int8)(v17 - 48) >= 0xAu )
{
if ( (unsigned __int8)(v17 - 65) > 5u )
{
if ( (unsigned __int8)(v17 - 103) < 0xFAu )
return v4;
v19 = v17 - 87;
}
else
{
v19 = v17 - 55;
}
v18 = v19;
}
if ( v18 + 16 * v15 != *(_BYTE *)(a1 + v11) )
break;
++v11;
v12 = v13 + 2;
if ( v11 == 20 )
return 0;
}
}
}
return v4;
}
|
ma_pvio_tls_compare_fp:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV BL,0x1
CMP ESI,0x14
JNZ 0x00120a37
MOV R14D,ECX
MOV R15,RDX
MOV R12,RDI
MOV RDI,RDX
MOV ESI,0x3a
CALL 0x00113190
TEST RAX,RAX
MOV EAX,0x28
MOV ECX,0x3b
CMOVZ ECX,EAX
CMP ECX,R14D
JNZ 0x00120a37
DEC R14D
XOR EAX,EAX
MOV RDX,R15
LAB_001209ad:
XOR ECX,ECX
CMP byte ptr [RDX],0x3a
SETZ CL
ADD RCX,RDX
MOV RDX,RCX
SUB RDX,R15
CMP RDX,R14
JG 0x00120a37
MOV SIL,byte ptr [RCX]
LEA EDX,[RSI + -0x30]
CMP DL,0xa
JC 0x001209ea
LEA EDX,[RSI + -0x41]
CMP DL,0x5
JA 0x001209dc
ADD SIL,0xc9
JMP 0x001209e8
LAB_001209dc:
LEA EDX,[RSI + -0x67]
CMP DL,0xfa
JC 0x00120a37
ADD SIL,0xa9
LAB_001209e8:
MOV EDX,ESI
LAB_001209ea:
MOV SIL,byte ptr [RCX + 0x1]
LEA EDI,[RSI + -0x30]
CMP DIL,0xa
JC 0x00120a15
LEA EDI,[RSI + -0x41]
CMP DIL,0x5
JA 0x00120a06
ADD SIL,0xc9
JMP 0x00120a13
LAB_00120a06:
LEA EDI,[RSI + -0x67]
CMP DIL,0xfa
JC 0x00120a37
ADD SIL,0xa9
LAB_00120a13:
MOV EDI,ESI
LAB_00120a15:
SHL DL,0x4
ADD DL,DIL
CMP DL,byte ptr [R12 + RAX*0x1]
JNZ 0x00120a37
ADD RCX,0x2
INC RAX
MOV RDX,RCX
CMP RAX,0x14
JNZ 0x001209ad
XOR EBX,EBX
LAB_00120a37:
MOV EAX,EBX
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
ulong ma_pvio_tls_compare_fp(long param_1,int param_2,char *param_3,int param_4)
{
char cVar1;
char *pcVar2;
long lVar3;
int iVar4;
int8 unaff_RBX;
ulong uVar5;
byte bVar6;
byte bVar7;
uVar5 = CONCAT71((int7)((ulong)unaff_RBX >> 8),1);
if (param_2 == 0x14) {
pcVar2 = strchr(param_3,0x3a);
iVar4 = 0x3b;
if (pcVar2 == (char *)0x0) {
iVar4 = 0x28;
}
if (iVar4 == param_4) {
lVar3 = 0;
pcVar2 = param_3;
do {
pcVar2 = pcVar2 + (*pcVar2 == ':');
if ((long)(ulong)(param_4 - 1) < (long)pcVar2 - (long)param_3) goto LAB_00120a37;
cVar1 = *pcVar2;
bVar6 = cVar1 - 0x30;
if (9 < bVar6) {
if ((byte)(cVar1 + 0xbfU) < 6) {
bVar6 = cVar1 - 0x37;
}
else {
if ((byte)(cVar1 + 0x99U) < 0xfa) goto LAB_00120a37;
bVar6 = cVar1 + 0xa9;
}
}
cVar1 = pcVar2[1];
bVar7 = cVar1 - 0x30;
if (9 < bVar7) {
if ((byte)(cVar1 + 0xbfU) < 6) {
bVar7 = cVar1 - 0x37;
}
else {
if ((byte)(cVar1 + 0x99U) < 0xfa) goto LAB_00120a37;
bVar7 = cVar1 + 0xa9;
}
}
if ((byte)(bVar6 * '\x10' + bVar7) != *(char *)(param_1 + lVar3)) goto LAB_00120a37;
pcVar2 = pcVar2 + 2;
lVar3 = lVar3 + 1;
} while (lVar3 != 0x14);
uVar5 = 0;
}
}
LAB_00120a37:
return uVar5 & 0xffffffff;
}
|
|
19,938
|
nlohmann::json_abi_v3_11_3::detail::type_error nlohmann::json_abi_v3_11_3::detail::type_error::create<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>*, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>*)
|
monkey531[P]llama/common/json.hpp
|
static type_error create(int id_, const std::string& what_arg, BasicJsonContext context)
{
const std::string w = concat(exception::name("type_error", id_), exception::diagnostics(context), what_arg);
return {id_, w.c_str()};
}
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::type_error nlohmann::json_abi_v3_11_3::detail::type_error::create<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>*, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdx, %r15
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x38(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x845b1(%rip), %rsi # 0x11340c
leaq 0x845b4(%rip), %rdx # 0x113416
leaq 0x28(%rsp), %rdi
callq 0x25e6a
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
movl %ebp, %edx
callq 0x88f1a
leaq 0x78(%rsp), %r14
movq %r14, -0x10(%r14)
xorl %eax, %eax
movq %rax, -0x8(%r14)
movb %al, (%r14)
leaq 0x18(%rsp), %r12
movq %r12, -0x10(%r12)
movq %rax, -0x8(%r12)
movb %al, (%r12)
movq 0x8(%r15), %rsi
addq 0x50(%rsp), %rsi
leaq 0x8(%rsp), %rdi
callq 0x1e370
movq 0x48(%rsp), %rsi
movq 0x50(%rsp), %rdx
leaq 0x8(%rsp), %rdi
callq 0x1d310
movq 0x68(%rsp), %rsi
movq 0x70(%rsp), %rdx
leaq 0x8(%rsp), %rdi
callq 0x1d310
movq (%r15), %rsi
movq 0x8(%r15), %rdx
leaq 0x8(%rsp), %rdi
callq 0x1d310
movq 0x68(%rsp), %rdi
cmpq %r14, %rdi
je 0x8ef05
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x1dc50
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x8ef20
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x1dc50
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x8ef37
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1dc50
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
movl %ebp, %esi
callq 0x89116
leaq 0xc5263(%rip), %rax # 0x1541b0
addq $0x10, %rax
movq %rax, (%rbx)
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0x8ef6b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1dc50
movq %rbx, %rax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0x8eff9
movq 0x18(%rsp), %rsi
jmp 0x8eff1
movq %rax, %rbx
jmp 0x8efe2
movq %rax, %rbx
jmp 0x8eff9
movq %rdx, %rbx
movq %rax, %r15
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0x8efbb
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1dc50
leaq 0x68(%rsp), %rdi
leaq 0x48(%rsp), %rdx
leaq 0x88(%rsp), %r12
movq %r14, %rsi
movq %r15, %rcx
movl %ebx, %r8d
movq %r12, %r9
callq 0x1f3eb
movq (%r12), %rbx
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x8eff9
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1dc50
movq %rbx, %rdi
callq 0x1e660
|
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 98h
mov r15, rdx
mov ebp, esi
mov rbx, rdi
lea r13, [rsp+0C8h+var_90]
mov [r13-10h], r13
lea rsi, aTypeError; "type_error"
lea rdx, aTypeError+0Ah; ""
lea rdi, [rsp+0C8h+var_A0]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
lea rdi, [rsp+0C8h+var_80]; int
lea rsi, [rsp+0C8h+var_A0]; int
mov edx, ebp; int
call _ZN8nlohmann16json_abi_v3_11_36detail9exception4nameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi; nlohmann::json_abi_v3_11_3::detail::exception::name(std::string const&,int)
lea r14, [rsp+0C8h+var_50]
mov [r14-10h], r14
xor eax, eax
mov [r14-8], rax
mov [r14], al
lea r12, [rsp+0C8h+var_B0]
mov [r12-10h], r12
mov [r12-8], rax
mov [r12], al
mov rsi, [r15+8]
add rsi, [rsp+0C8h+var_78]
lea rdi, [rsp+0C8h+var_C0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong)
mov rsi, qword ptr [rsp+0C8h+var_80]
mov rdx, [rsp+0C8h+var_78]
lea rdi, [rsp+0C8h+var_C0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
mov rsi, [rsp+0C8h+var_60]
mov rdx, [rsp+0C8h+var_58]
lea rdi, [rsp+0C8h+var_C0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
mov rsi, [r15]
mov rdx, [r15+8]
lea rdi, [rsp+0C8h+var_C0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
mov rdi, [rsp+0C8h+var_60]; void *
cmp rdi, r14
jz short loc_8EF05
mov rsi, [rsp+0C8h+var_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EF05:
lea rax, [rsp+0C8h+var_70]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_8EF20
mov rsi, [rsp+0C8h+var_70]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EF20:
mov rdi, [rsp+0C8h+var_A0]; void *
cmp rdi, r13
jz short loc_8EF37
mov rsi, [rsp+0C8h+var_90]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EF37:
mov rdx, [rsp+0C8h+var_C0]; char *
mov rdi, rbx; this
mov esi, ebp; int
call _ZN8nlohmann16json_abi_v3_11_36detail9exceptionC2EiPKc; nlohmann::json_abi_v3_11_3::detail::exception::exception(int,char const*)
lea rax, _ZTVN8nlohmann16json_abi_v3_11_36detail10type_errorE; `vtable for'nlohmann::json_abi_v3_11_3::detail::type_error
add rax, 10h
mov [rbx], rax
mov rdi, [rsp+0C8h+var_C0]; void *
cmp rdi, r12
jz short loc_8EF6B
mov rsi, [rsp+0C8h+var_B0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EF6B:
mov rax, rbx
add rsp, 98h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
mov rdi, [rsp+arg_0]
cmp rdi, r12
jz short loc_8EFF9
mov rsi, [rsp+arg_10]
jmp short loc_8EFF1
mov rbx, rax
jmp short loc_8EFE2
mov rbx, rax
jmp short loc_8EFF9
mov rbx, rdx
mov r15, rax
mov rdi, [rsp+arg_0]; void *
cmp rdi, r12
jz short loc_8EFBB
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EFBB:
lea rdi, [rsp+arg_60]
lea rdx, [rsp+arg_40]
lea r12, [rsp+arg_80]
mov rsi, r14
mov rcx, r15
mov r8d, ebx
mov r9, r12
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ__cold_1
mov rbx, [r12]
loc_8EFE2:
mov rdi, [rsp+arg_20]; void *
cmp rdi, r13
jz short loc_8EFF9
mov rsi, [rsp+arg_30]
loc_8EFF1:
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8EFF9:
mov rdi, rbx
call __Unwind_Resume
|
nlohmann::json_abi_v3_11_3::detail::exception * ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
nlohmann::json_abi_v3_11_3::detail::exception *this,
int a2,
_QWORD *a3)
{
char *v5[2]; // [rsp+8h] [rbp-C0h] BYREF
_QWORD v6[2]; // [rsp+18h] [rbp-B0h] BYREF
void *v7[2]; // [rsp+28h] [rbp-A0h] BYREF
_QWORD v8[2]; // [rsp+38h] [rbp-90h] BYREF
int v9[2]; // [rsp+48h] [rbp-80h] BYREF
long long v10; // [rsp+50h] [rbp-78h]
long long v11; // [rsp+58h] [rbp-70h] BYREF
void *v12; // [rsp+68h] [rbp-60h]
long long v13; // [rsp+70h] [rbp-58h]
_QWORD v14[10]; // [rsp+78h] [rbp-50h] BYREF
v7[0] = v8;
std::string::_M_construct<char const*>((long long)v7, "type_error", (long long)"");
nlohmann::json_abi_v3_11_3::detail::exception::name((long long)v9, (long long)v7, a2);
v12 = v14;
v13 = 0LL;
LOBYTE(v14[0]) = 0;
v5[0] = (char *)v6;
v5[1] = 0LL;
LOBYTE(v6[0]) = 0;
std::string::reserve(v5, v10 + a3[1]);
std::string::_M_append(v5, *(_QWORD *)v9, v10);
std::string::_M_append(v5, v12, v13);
std::string::_M_append(v5, *a3, a3[1]);
if ( v12 != v14 )
operator delete(v12, v14[0] + 1LL);
if ( *(long long **)v9 != &v11 )
operator delete(*(void **)v9, v11 + 1);
if ( v7[0] != v8 )
operator delete(v7[0], v8[0] + 1LL);
nlohmann::json_abi_v3_11_3::detail::exception::exception(this, a2, v5[0]);
*(_QWORD *)this = &`vtable for'nlohmann::json_abi_v3_11_3::detail::type_error + 2;
if ( (_QWORD *)v5[0] != v6 )
operator delete(v5[0], v6[0] + 1LL);
return this;
}
|
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x98
MOV R15,RDX
MOV EBP,ESI
MOV RBX,RDI
LEA R13,[RSP + 0x38]
MOV qword ptr [R13 + -0x10],R13
LAB_0018ee54:
LEA RSI,[0x21340c]
LEA RDX,[0x213416]
LEA RDI,[RSP + 0x28]
CALL 0x00125e6a
LAB_0018ee6c:
LEA RDI,[RSP + 0x48]
LEA RSI,[RSP + 0x28]
MOV EDX,EBP
CALL 0x00188f1a
LEA R14,[RSP + 0x78]
MOV qword ptr [R14 + -0x10],R14
XOR EAX,EAX
MOV qword ptr [R14 + -0x8],RAX
MOV byte ptr [R14],AL
LEA R12,[RSP + 0x18]
MOV qword ptr [R12 + -0x10],R12
MOV qword ptr [R12 + -0x8],RAX
MOV byte ptr [R12],AL
MOV RSI,qword ptr [R15 + 0x8]
ADD RSI,qword ptr [RSP + 0x50]
LAB_0018eeab:
LEA RDI,[RSP + 0x8]
CALL 0x0011e370
MOV RSI,qword ptr [RSP + 0x48]
MOV RDX,qword ptr [RSP + 0x50]
LEA RDI,[RSP + 0x8]
CALL 0x0011d310
MOV RSI,qword ptr [RSP + 0x68]
MOV RDX,qword ptr [RSP + 0x70]
LEA RDI,[RSP + 0x8]
CALL 0x0011d310
MOV RSI,qword ptr [R15]
MOV RDX,qword ptr [R15 + 0x8]
LEA RDI,[RSP + 0x8]
CALL 0x0011d310
MOV RDI,qword ptr [RSP + 0x68]
CMP RDI,R14
JZ 0x0018ef05
MOV RSI,qword ptr [RSP + 0x78]
INC RSI
CALL 0x0011dc50
LAB_0018ef05:
LEA RAX,[RSP + 0x58]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0018ef20
MOV RSI,qword ptr [RSP + 0x58]
INC RSI
CALL 0x0011dc50
LAB_0018ef20:
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R13
JZ 0x0018ef37
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x0011dc50
LAB_0018ef37:
MOV RDX,qword ptr [RSP + 0x8]
LAB_0018ef3c:
MOV RDI,RBX
MOV ESI,EBP
CALL 0x00189116
LAB_0018ef46:
LEA RAX,[0x2541b0]
ADD RAX,0x10
MOV qword ptr [RBX],RAX
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,R12
JZ 0x0018ef6b
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011dc50
LAB_0018ef6b:
MOV RAX,RBX
ADD RSP,0x98
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
exception *
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(exception *param_1,int param_2,ulong *param_3)
{
char *local_c0;
int8 local_b8;
char local_b0;
int7 uStack_af;
long *local_a0 [2];
long local_90 [2];
long *local_80 [2];
long local_70 [2];
int1 *local_60;
int8 local_58;
int1 local_50;
int7 uStack_4f;
/* try { // try from 0018ee54 to 0018ee6b has its CatchHandler @ 0018ef99 */
local_a0[0] = local_90;
std::__cxx11::string::_M_construct<char_const*>(local_a0,"type_error","");
/* try { // try from 0018ee6c to 0018ee7c has its CatchHandler @ 0018ef94 */
nlohmann::json_abi_v3_11_3::detail::exception::name
((exception *)local_80,(string *)local_a0,param_2);
local_58 = 0;
local_50 = 0;
local_b8 = 0;
local_b0 = '\0';
/* try { // try from 0018eeab to 0018eeed has its CatchHandler @ 0018ef9e */
local_c0 = &local_b0;
local_60 = &local_50;
std::__cxx11::string::reserve((ulong)&local_c0);
std::__cxx11::string::_M_append((char *)&local_c0,(ulong)local_80[0]);
std::__cxx11::string::_M_append((char *)&local_c0,(ulong)local_60);
std::__cxx11::string::_M_append((char *)&local_c0,*param_3);
if (local_60 != &local_50) {
operator_delete(local_60,CONCAT71(uStack_4f,local_50) + 1);
}
if (local_80[0] != local_70) {
operator_delete(local_80[0],local_70[0] + 1);
}
if (local_a0[0] != local_90) {
operator_delete(local_a0[0],local_90[0] + 1);
}
/* try { // try from 0018ef3c to 0018ef45 has its CatchHandler @ 0018ef80 */
nlohmann::json_abi_v3_11_3::detail::exception::exception(param_1,param_2,local_c0);
*(int ***)param_1 = &PTR__exception_002541c0;
if (local_c0 != &local_b0) {
operator_delete(local_c0,CONCAT71(uStack_af,local_b0) + 1);
}
return param_1;
}
|
|
19,939
|
inline_mysql_rwlock_init
|
eloqsql/include/mysql/psi/mysql_thread.h
|
static inline int inline_mysql_rwlock_init(
#ifdef HAVE_PSI_RWLOCK_INTERFACE
PSI_rwlock_key key,
#endif
mysql_rwlock_t *that)
{
#ifdef HAVE_PSI_RWLOCK_INTERFACE
that->m_psi= PSI_RWLOCK_CALL(init_rwlock)(key, &that->m_rwlock);
#else
that->m_psi= NULL;
#endif
/*
pthread_rwlockattr_t is not used in MySQL.
*/
return my_rwlock_init(&that->m_rwlock, NULL);
}
|
O0
|
c
|
inline_mysql_rwlock_init:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
leaq 0x1b7e52(%rip), %rax # 0x2617d8
movq (%rax), %rax
movq 0x50(%rax), %rax
movl -0x4(%rbp), %edi
movq -0x10(%rbp), %rsi
callq *%rax
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x90(%rax)
movq -0x10(%rbp), %rdi
callq 0xa6c50
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
inline_mysql_rwlock_init_0:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_4], edi
mov [rbp+var_10], rsi
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+50h]
mov edi, [rbp+var_4]
mov rsi, [rbp+var_10]
call rax
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+90h], rcx
mov rdi, [rbp+var_10]
call my_rw_init
add rsp, 10h
pop rbp
retn
|
long long inline_mysql_rwlock_init_0(unsigned int a1, long long a2)
{
*(_QWORD *)(a2 + 144) = (*((long long ( **)(_QWORD, long long))PSI_server + 10))(a1, a2);
return my_rw_init(a2);
}
|
inline_mysql_rwlock_init:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV dword ptr [RBP + -0x4],EDI
MOV qword ptr [RBP + -0x10],RSI
LEA RAX,[0x3617d8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x50]
MOV EDI,dword ptr [RBP + -0x4]
MOV RSI,qword ptr [RBP + -0x10]
CALL RAX
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x90],RCX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001a6c50
ADD RSP,0x10
POP RBP
RET
|
void inline_mysql_rwlock_init(int4 param_1,long param_2)
{
int8 uVar1;
uVar1 = (**(code **)(PSI_server + 0x50))(param_1,param_2);
*(int8 *)(param_2 + 0x90) = uVar1;
my_rw_init(param_2);
return;
}
|
|
19,940
|
nglog::InstallFailureSignalHandler()
|
ng-log[P]ng-log/src/signalhandler.cc
|
void InstallFailureSignalHandler() {
#ifdef HAVE_SIGACTION
// Build the sigaction struct.
struct sigaction sig_action;
memset(&sig_action, 0, sizeof(sig_action));
sigemptyset(&sig_action.sa_mask);
sig_action.sa_flags |= SA_SIGINFO;
sig_action.sa_sigaction = &FailureSignalHandler;
for (auto kFailureSignal : kFailureSignals) {
CHECK_ERR(sigaction(kFailureSignal.number, &sig_action, nullptr));
}
kFailureSignalHandlerInstalled = true;
#elif defined(NGLOG_OS_WINDOWS)
for (size_t i = 0; i < ARRAYSIZE(kFailureSignals); ++i) {
CHECK_NE(signal(kFailureSignals[i].number, &FailureSignalHandler), SIG_ERR);
}
kFailureSignalHandlerInstalled = true;
#endif // HAVE_SIGACTION
}
|
O0
|
cpp
|
nglog::InstallFailureSignalHandler():
pushq %rbp
movq %rsp, %rbp
subq $0x180, %rsp # imm = 0x180
leaq -0x98(%rbp), %rdi
xorl %esi, %esi
movl $0x98, %edx
callq 0x9380
leaq -0x98(%rbp), %rdi
addq $0x8, %rdi
callq 0x98f0
movl -0x10(%rbp), %eax
orl $0x4, %eax
movl %eax, -0x10(%rbp)
leaq -0x7e(%rip), %rax # 0x4ea30
movq %rax, -0x98(%rbp)
leaq 0x2b1e4(%rip), %rax # 0x79ca0
movq %rax, -0xa0(%rbp)
leaq 0x2b1d6(%rip), %rax # 0x79ca0
movq %rax, -0xa8(%rbp)
leaq 0x2b1c8(%rip), %rax # 0x79ca0
addq $0x60, %rax
movq %rax, -0xb0(%rbp)
movq -0xa8(%rbp), %rax
cmpq -0xb0(%rbp), %rax
je 0x4ec33
movq -0xa8(%rbp), %rax
movq (%rax), %rcx
movq %rcx, -0xc0(%rbp)
movq 0x8(%rax), %rax
movq %rax, -0xb8(%rbp)
movl -0xc0(%rbp), %edi
leaq -0x98(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0x9900
movb $0x0, -0x139(%rbp)
cmpl $-0x1, %eax
je 0x4eb3a
jmp 0x4ebd4
leaq -0x390c1(%rip), %rax # 0x15a80
movq %rax, -0x138(%rbp)
movq $0x0, -0x130(%rbp)
movups -0x138(%rbp), %xmm0
movq %rsp, %rax
movups %xmm0, (%rax)
leaq 0x62cb(%rip), %rsi # 0x54e32
xorl %eax, %eax
movl %eax, %r8d
leaq -0x128(%rbp), %rdi
movq %rdi, -0x160(%rbp)
movl $0x18b, %edx # imm = 0x18B
movl $0x3, %ecx
callq 0x172b0
movq -0x160(%rbp), %rdi
movb $0x1, -0x139(%rbp)
callq 0x15f00
movq %rax, -0x158(%rbp)
jmp 0x4eba5
movq -0x158(%rbp), %rdi
leaq 0x62cc(%rip), %rsi # 0x54e7f
callq 0x96d0
movq %rax, -0x168(%rbp)
jmp 0x4ebc1
movq -0x168(%rbp), %rsi
leaq -0xc1(%rbp), %rdi
callq 0x1f710
testb $0x1, -0x139(%rbp)
jne 0x4ebdf
jmp 0x4ebeb
leaq -0x128(%rbp), %rdi
callq 0x17340
jmp 0x4ebed
movq -0xa8(%rbp), %rax
addq $0x10, %rax
movq %rax, -0xa8(%rbp)
jmp 0x4eae3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x148(%rbp)
movl %eax, -0x14c(%rbp)
testb $0x1, -0x139(%rbp)
jne 0x4ec21
jmp 0x4ec31
leaq -0x128(%rbp), %rdi
callq 0x17340
jmp 0x4ec2f
jmp 0x4ec31
jmp 0x4ec43
movb $0x1, 0x3c092(%rip) # 0x8accc
addq $0x180, %rsp # imm = 0x180
popq %rbp
retq
movq -0x148(%rbp), %rdi
callq 0x9cc0
movq %rax, %rdi
callq 0xcb80
nopw (%rax,%rax)
|
_ZN5nglog27InstallFailureSignalHandlerEv:
push rbp
mov rbp, rsp
sub rsp, 180h
lea rdi, [rbp+var_98]
xor esi, esi
mov edx, 98h
call _memset
lea rdi, [rbp+var_98]
add rdi, 8
call _sigemptyset
mov eax, [rbp+var_10]
or eax, 4
mov [rbp+var_10], eax
lea rax, _ZN5nglog12_GLOBAL__N_120FailureSignalHandlerEiP9siginfo_tPv; nglog::`anonymous namespace'::FailureSignalHandler(int,siginfo_t *,void *)
mov [rbp+var_98], rax
lea rax, _ZN5nglog12_GLOBAL__N_115kFailureSignalsE; nglog::`anonymous namespace'::kFailureSignals
mov [rbp+var_A0], rax
lea rax, _ZN5nglog12_GLOBAL__N_115kFailureSignalsE; nglog::`anonymous namespace'::kFailureSignals
mov [rbp+var_A8], rax
lea rax, _ZN5nglog12_GLOBAL__N_115kFailureSignalsE; nglog::`anonymous namespace'::kFailureSignals
add rax, 60h ; '`'
mov [rbp+var_B0], rax
loc_4EAE3:
mov rax, [rbp+var_A8]
cmp rax, [rbp+var_B0]
jz loc_4EC33
mov rax, [rbp+var_A8]
mov rcx, [rax]
mov [rbp+var_C0], rcx
mov rax, [rax+8]
mov [rbp+var_B8], rax
mov edi, dword ptr [rbp+var_C0]
lea rsi, [rbp+var_98]
xor eax, eax
mov edx, eax
call _sigaction
mov [rbp+var_139], 0
cmp eax, 0FFFFFFFFh
jz short loc_4EB3A
jmp loc_4EBD4
loc_4EB3A:
lea rax, _ZN5nglog10LogMessage9SendToLogEv; nglog::LogMessage::SendToLog(void)
mov qword ptr [rbp+var_138], rax
mov qword ptr [rbp+var_138+8], 0
movups xmm0, [rbp+var_138]
mov rax, rsp
movups xmmword ptr [rax], xmm0
lea rsi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
xor eax, eax
mov r8d, eax
lea rdi, [rbp+var_128]
mov [rbp+var_160], rdi
mov edx, 18Bh
mov ecx, 3
call _ZN5nglog15ErrnoLogMessageC2EPKciNS_11LogSeverityElMNS_10LogMessageEFvvE; nglog::ErrnoLogMessage::ErrnoLogMessage(char const*,int,nglog::LogSeverity,long,void (nglog::LogMessage::*)(void))
mov rdi, [rbp+var_160]; this
mov [rbp+var_139], 1
call _ZN5nglog10LogMessage6streamEv; nglog::LogMessage::stream(void)
mov [rbp+var_158], rax
jmp short $+2
loc_4EBA5:
mov rdi, [rbp+var_158]
lea rsi, aSigactionKfail; "sigaction(kFailureSignal.number, &sig_a"...
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov [rbp+var_168], rax
jmp short $+2
loc_4EBC1:
mov rsi, [rbp+var_168]
lea rdi, [rbp+var_C1]
call _ZNK5nglog8internal17LogMessageVoidifyanERSo; nglog::internal::LogMessageVoidify::operator&(std::ostream &)
loc_4EBD4:
test [rbp+var_139], 1
jnz short loc_4EBDF
jmp short loc_4EBEB
loc_4EBDF:
lea rdi, [rbp+var_128]; this
call _ZN5nglog15ErrnoLogMessageD2Ev; nglog::ErrnoLogMessage::~ErrnoLogMessage()
loc_4EBEB:
jmp short $+2
loc_4EBED:
mov rax, [rbp+var_A8]
add rax, 10h
mov [rbp+var_A8], rax
jmp loc_4EAE3
mov rcx, rax
mov eax, edx
mov [rbp+var_148], rcx
mov [rbp+var_14C], eax
test [rbp+var_139], 1
jnz short loc_4EC21
jmp short loc_4EC31
loc_4EC21:
lea rdi, [rbp+var_128]; this
call _ZN5nglog15ErrnoLogMessageD2Ev; nglog::ErrnoLogMessage::~ErrnoLogMessage()
jmp short $+2
loc_4EC2F:
jmp short $+2
loc_4EC31:
jmp short loc_4EC43
loc_4EC33:
mov cs:_ZN5nglog12_GLOBAL__N_130kFailureSignalHandlerInstalledE, 1; nglog::`anonymous namespace'::kFailureSignalHandlerInstalled
add rsp, 180h
pop rbp
retn
loc_4EC43:
mov rdi, [rbp+var_148]
call __Unwind_Resume
mov rdi, rax
call __clang_call_terminate
|
char * nglog::InstallFailureSignalHandler(nglog *this)
{
char *result; // rax
long long v2; // r9
long long v3; // [rsp+28h] [rbp-158h]
char v4; // [rsp+47h] [rbp-139h]
_QWORD v5[12]; // [rsp+58h] [rbp-128h] BYREF
long long v6; // [rsp+C0h] [rbp-C0h]
long long v7; // [rsp+C8h] [rbp-B8h]
char *v8; // [rsp+D0h] [rbp-B0h]
char *v9; // [rsp+D8h] [rbp-A8h]
void *v10; // [rsp+E0h] [rbp-A0h]
long long ( *v11)(int, long long, long long); // [rsp+E8h] [rbp-98h] BYREF
long long v12; // [rsp+F0h] [rbp-90h] BYREF
int v13; // [rsp+170h] [rbp-10h]
memset(&v11, 0LL, 152LL);
sigemptyset(&v12);
v13 |= 4u;
v11 = nglog::`anonymous namespace'::FailureSignalHandler;
v10 = &nglog::`anonymous namespace'::kFailureSignals;
v9 = (char *)&nglog::`anonymous namespace'::kFailureSignals;
v8 = (char *)&nglog::`anonymous namespace'::kFailureSignals + 96;
while ( 1 )
{
result = v9;
if ( v9 == v8 )
break;
v6 = *(_QWORD *)v9;
v7 = *((_QWORD *)v9 + 1);
v4 = 0;
if ( (unsigned int)sigaction((unsigned int)v6, &v11, 0LL) == -1 )
{
nglog::ErrnoLogMessage::ErrnoLogMessage(
v5,
(long long)"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/signalhandler.cc",
0x18Bu,
3u,
0LL,
v2,
(long long)nglog::LogMessage::SendToLog,
0LL);
v4 = 1;
v3 = nglog::LogMessage::stream((nglog::LogMessage *)v5);
std::operator<<<std::char_traits<char>>(v3, "sigaction(kFailureSignal.number, &sig_action, nullptr)");
nglog::internal::LogMessageVoidify::operator&();
}
if ( (v4 & 1) != 0 )
nglog::ErrnoLogMessage::~ErrnoLogMessage((nglog::ErrnoLogMessage *)v5);
v9 += 16;
}
nglog::`anonymous namespace'::kFailureSignalHandlerInstalled = 1;
return result;
}
|
InstallFailureSignalHandler:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x180
LEA RDI,[RBP + -0x98]
XOR ESI,ESI
MOV EDX,0x98
CALL 0x00109380
LEA RDI,[RBP + -0x98]
ADD RDI,0x8
CALL 0x001098f0
MOV EAX,dword ptr [RBP + -0x10]
OR EAX,0x4
MOV dword ptr [RBP + -0x10],EAX
LEA RAX,[0x14ea30]
MOV qword ptr [RBP + -0x98],RAX
LEA RAX,[0x179ca0]
MOV qword ptr [RBP + -0xa0],RAX
LEA RAX,[0x179ca0]
MOV qword ptr [RBP + -0xa8],RAX
LEA RAX,[0x179ca0]
ADD RAX,0x60
MOV qword ptr [RBP + -0xb0],RAX
LAB_0014eae3:
MOV RAX,qword ptr [RBP + -0xa8]
CMP RAX,qword ptr [RBP + -0xb0]
JZ 0x0014ec33
MOV RAX,qword ptr [RBP + -0xa8]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RBP + -0xc0],RCX
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0xb8],RAX
MOV EDI,dword ptr [RBP + -0xc0]
LEA RSI,[RBP + -0x98]
XOR EAX,EAX
MOV EDX,EAX
CALL 0x00109900
MOV byte ptr [RBP + -0x139],0x0
CMP EAX,-0x1
JZ 0x0014eb3a
JMP 0x0014ebd4
LAB_0014eb3a:
LEA RAX,[0x115a80]
MOV qword ptr [RBP + -0x138],RAX
MOV qword ptr [RBP + -0x130],0x0
MOVUPS XMM0,xmmword ptr [RBP + -0x138]
MOV RAX,RSP
MOVUPS xmmword ptr [RAX],XMM0
LEA RSI,[0x154e32]
XOR EAX,EAX
MOV R8D,EAX
LEA RDI,[RBP + -0x128]
MOV qword ptr [RBP + -0x160],RDI
MOV EDX,0x18b
MOV ECX,0x3
CALL 0x001172b0
MOV RDI,qword ptr [RBP + -0x160]
MOV byte ptr [RBP + -0x139],0x1
LAB_0014eb97:
CALL 0x00115f00
MOV qword ptr [RBP + -0x158],RAX
JMP 0x0014eba5
LAB_0014eba5:
MOV RDI,qword ptr [RBP + -0x158]
LEA RSI,[0x154e7f]
CALL 0x001096d0
LAB_0014ebb8:
MOV qword ptr [RBP + -0x168],RAX
JMP 0x0014ebc1
LAB_0014ebc1:
MOV RSI,qword ptr [RBP + -0x168]
LEA RDI,[RBP + -0xc1]
CALL 0x0011f710
LAB_0014ebd4:
TEST byte ptr [RBP + -0x139],0x1
JNZ 0x0014ebdf
JMP 0x0014ebeb
LAB_0014ebdf:
LEA RDI,[RBP + -0x128]
CALL 0x00117340
LAB_0014ebeb:
JMP 0x0014ebed
LAB_0014ebed:
MOV RAX,qword ptr [RBP + -0xa8]
ADD RAX,0x10
MOV qword ptr [RBP + -0xa8],RAX
JMP 0x0014eae3
LAB_0014ec33:
MOV byte ptr [0x0018accc],0x1
ADD RSP,0x180
POP RBP
RET
|
/* nglog::InstallFailureSignalHandler() */
void nglog::InstallFailureSignalHandler(void)
{
int iVar1;
ostream *poVar2;
int8 in_R9;
ErrnoLogMessage local_130 [103];
LogMessageVoidify local_c9;
Elf64_DynTag local_c8;
qword local_c0;
Elf64_Dyn *local_b8;
Elf64_Dyn *local_b0;
int8 *local_a8;
sigaction local_a0;
memset(&local_a0,0,0x98);
sigemptyset(&local_a0.sa_mask);
local_a0.sa_flags = local_a0.sa_flags | 4;
local_a0.__sigaction_handler.sa_handler = (anonymous_namespace)::FailureSignalHandler;
local_a8 = &(anonymous_namespace)::kFailureSignals;
local_b8 = _DYNAMIC;
for (local_b0 = (Elf64_Dyn *)&(anonymous_namespace)::kFailureSignals; local_b0 != local_b8;
local_b0 = local_b0 + 1) {
local_c8 = local_b0->d_tag;
local_c0 = local_b0->d_val;
iVar1 = sigaction((int4)local_c8,&local_a0,(sigaction *)0x0);
if (iVar1 == -1) {
ErrnoLogMessage::ErrnoLogMessage
(local_130,
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/signalhandler.cc",
0x18b,3,0,in_R9,0x115a80,0);
/* try { // try from 0014eb97 to 0014ebb7 has its CatchHandler @ 0014ec04 */
poVar2 = (ostream *)LogMessage::stream((LogMessage *)local_130);
poVar2 = std::operator<<(poVar2,"sigaction(kFailureSignal.number, &sig_action, nullptr)");
internal::LogMessageVoidify::operator&(&local_c9,poVar2);
ErrnoLogMessage::~ErrnoLogMessage(local_130);
}
}
(anonymous_namespace)::kFailureSignalHandlerInstalled = 1;
return;
}
|
|
19,941
|
nglog::InstallFailureSignalHandler()
|
ng-log[P]ng-log/src/signalhandler.cc
|
void InstallFailureSignalHandler() {
#ifdef HAVE_SIGACTION
// Build the sigaction struct.
struct sigaction sig_action;
memset(&sig_action, 0, sizeof(sig_action));
sigemptyset(&sig_action.sa_mask);
sig_action.sa_flags |= SA_SIGINFO;
sig_action.sa_sigaction = &FailureSignalHandler;
for (auto kFailureSignal : kFailureSignals) {
CHECK_ERR(sigaction(kFailureSignal.number, &sig_action, nullptr));
}
kFailureSignalHandlerInstalled = true;
#elif defined(NGLOG_OS_WINDOWS)
for (size_t i = 0; i < ARRAYSIZE(kFailureSignals); ++i) {
CHECK_NE(signal(kFailureSignals[i].number, &FailureSignalHandler), SIG_ERR);
}
kFailureSignalHandlerInstalled = true;
#endif // HAVE_SIGACTION
}
|
O3
|
cpp
|
nglog::InstallFailureSignalHandler():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x118, %rsp # imm = 0x118
leaq 0x80(%rsp), %rbx
xorl %r13d, %r13d
movl $0x98, %edx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x7290
leaq 0x88(%rsp), %r14
movq %r14, %rdi
callq 0x7680
orb $0x4, 0x80(%r14)
leaq -0x88(%rip), %rax # 0x21369
movq %rax, -0x8(%r14)
leaq 0x10874(%rip), %rbp # 0x31c70
leaq 0x497f(%rip), %r14 # 0x25d82
leaq 0x20(%rsp), %r15
leaq 0x49c0(%rip), %r12 # 0x25dcf
movl (%r13,%rbp), %edi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x7690
cmpl $-0x1, %eax
je 0x2142f
addq $0x10, %r13
cmpq $0x60, %r13
jne 0x2140f
jmp 0x21487
leaq -0x15710(%rip), %rax # 0xbd26
movq %rax, 0x10(%rsp)
movq $0x0, 0x18(%rsp)
movups 0x10(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %r15, %rdi
movq %r14, %rsi
movl $0x18b, %edx # imm = 0x18B
movl $0x3, %ecx
xorl %r8d, %r8d
callq 0xce94
movq %r15, %rdi
callq 0xc1ee
movl $0x36, %edx
movq %rax, %rdi
movq %r12, %rsi
callq 0x75c0
movq %r15, %rdi
callq 0xcefe
jmp 0x21423
addq $0x118, %rsp # imm = 0x118
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0xcefe
movq %rbx, %rdi
callq 0x7930
movq %rax, %rdi
callq 0x9c33
|
_ZN5nglog27InstallFailureSignalHandlerEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 118h
lea rbx, [rsp+148h+var_C8]
xor r13d, r13d
mov edx, 98h
mov rdi, rbx
xor esi, esi
call _memset
lea r14, [rsp+148h+var_C0]
mov rdi, r14
call _sigemptyset
or byte ptr [r14+80h], 4
lea rax, _ZN5nglog12_GLOBAL__N_120FailureSignalHandlerEiP9siginfo_tPv; nglog::`anonymous namespace'::FailureSignalHandler(int,siginfo_t *,void *)
mov [r14-8], rax
lea rbp, _ZN5nglog12_GLOBAL__N_115kFailureSignalsE; nglog::`anonymous namespace'::kFailureSignals
lea r14, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea r15, [rsp+148h+var_128]
lea r12, aSigactionKfail; "sigaction(kFailureSignal.number, &sig_a"...
loc_2140F:
mov edi, [r13+rbp+0]
mov rsi, rbx
xor edx, edx
call _sigaction
cmp eax, 0FFFFFFFFh
jz short loc_2142F
loc_21423:
add r13, 10h
cmp r13, 60h ; '`'
jnz short loc_2140F
jmp short loc_21487
loc_2142F:
lea rax, _ZN5nglog10LogMessage9SendToLogEv; nglog::LogMessage::SendToLog(void)
mov qword ptr [rsp+148h+var_138], rax
mov qword ptr [rsp+148h+var_138+8], 0
movups xmm0, [rsp+148h+var_138]
movups [rsp+148h+var_148], xmm0
mov rdi, r15
mov rsi, r14
mov edx, 18Bh
mov ecx, 3
xor r8d, r8d
call _ZN5nglog15ErrnoLogMessageC2EPKciNS_11LogSeverityElMNS_10LogMessageEFvvE; nglog::ErrnoLogMessage::ErrnoLogMessage(char const*,int,nglog::LogSeverity,long,void (nglog::LogMessage::*)(void))
mov rdi, r15; this
call _ZN5nglog10LogMessage6streamEv; nglog::LogMessage::stream(void)
mov edx, 36h ; '6'
mov rdi, rax
mov rsi, 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, r15; this
call _ZN5nglog15ErrnoLogMessageD2Ev; nglog::ErrnoLogMessage::~ErrnoLogMessage()
jmp short loc_21423
loc_21487:
add rsp, 118h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
lea rdi, [rsp+arg_18]; this
call _ZN5nglog15ErrnoLogMessageD2Ev; nglog::ErrnoLogMessage::~ErrnoLogMessage()
mov rdi, rbx
call __Unwind_Resume
mov rdi, rax
call __clang_call_terminate
|
void nglog::InstallFailureSignalHandler(nglog *this)
{
long long v1; // r13
long long v2; // r9
long long v3; // rax
_QWORD v4[12]; // [rsp+20h] [rbp-128h] BYREF
long long ( *v5)(int, long long, long long); // [rsp+80h] [rbp-C8h] BYREF
_BYTE v6[128]; // [rsp+88h] [rbp-C0h] BYREF
char v7; // [rsp+108h] [rbp-40h]
v1 = 0LL;
memset(&v5, 0LL, 152LL);
sigemptyset(v6);
v7 |= 4u;
v5 = nglog::`anonymous namespace'::FailureSignalHandler;
do
{
if ( (unsigned int)sigaction(
*(unsigned int *)((char *)&nglog::`anonymous namespace'::kFailureSignals + v1),
&v5,
0LL) == -1 )
{
nglog::ErrnoLogMessage::ErrnoLogMessage(
v4,
(nglog::tools *)"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/signalhandler.cc",
395,
3,
0LL,
v2,
(long long)nglog::LogMessage::SendToLog,
0LL);
v3 = nglog::LogMessage::stream((nglog::LogMessage *)v4);
std::__ostream_insert<char,std::char_traits<char>>(
v3,
"sigaction(kFailureSignal.number, &sig_action, nullptr)",
54LL);
nglog::ErrnoLogMessage::~ErrnoLogMessage((nglog::ErrnoLogMessage *)v4);
}
v1 += 16LL;
}
while ( v1 != 96 );
}
|
InstallFailureSignalHandler:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x118
LEA RBX,[RSP + 0x80]
XOR R13D,R13D
MOV EDX,0x98
MOV RDI,RBX
XOR ESI,ESI
CALL 0x00107290
LEA R14,[RSP + 0x88]
MOV RDI,R14
CALL 0x00107680
OR byte ptr [R14 + 0x80],0x4
LEA RAX,[0x121369]
MOV qword ptr [R14 + -0x8],RAX
LEA RBP,[0x131c70]
LEA R14,[0x125d82]
LEA R15,[RSP + 0x20]
LEA R12,[0x125dcf]
LAB_0012140f:
MOV EDI,dword ptr [R13 + RBP*0x1]
MOV RSI,RBX
XOR EDX,EDX
CALL 0x00107690
CMP EAX,-0x1
JZ 0x0012142f
LAB_00121423:
ADD R13,0x10
CMP R13,0x60
JNZ 0x0012140f
JMP 0x00121487
LAB_0012142f:
LEA RAX,[0x10bd26]
MOV qword ptr [RSP + 0x10],RAX
MOV qword ptr [RSP + 0x18],0x0
MOVUPS XMM0,xmmword ptr [RSP + 0x10]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,R15
MOV RSI,R14
MOV EDX,0x18b
MOV ECX,0x3
XOR R8D,R8D
CALL 0x0010ce94
LAB_00121465:
MOV RDI,R15
CALL 0x0010c1ee
MOV EDX,0x36
MOV RDI,RAX
MOV RSI,R12
CALL 0x001075c0
LAB_0012147d:
MOV RDI,R15
CALL 0x0010cefe
JMP 0x00121423
LAB_00121487:
ADD RSP,0x118
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* nglog::InstallFailureSignalHandler() */
void nglog::InstallFailureSignalHandler(void)
{
int iVar1;
ostream *poVar2;
int8 in_R9;
long lVar3;
LogMessage local_128 [96];
sigaction local_c8;
lVar3 = 0;
memset(&local_c8,0,0x98);
sigemptyset(&local_c8.sa_mask);
local_c8.sa_flags._0_1_ = (byte)local_c8.sa_flags | 4;
local_c8.__sigaction_handler.sa_handler = (anonymous_namespace)::FailureSignalHandler;
do {
iVar1 = sigaction(*(int *)((long)&(anonymous_namespace)::kFailureSignals + lVar3),&local_c8,
(sigaction *)0x0);
if (iVar1 == -1) {
ErrnoLogMessage::ErrnoLogMessage
((ErrnoLogMessage *)local_128,
"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/signalhandler.cc",
0x18b,3,0,in_R9,0x10bd26,0);
/* try { // try from 00121465 to 0012147c has its CatchHandler @ 00121499 */
poVar2 = (ostream *)LogMessage::stream(local_128);
std::__ostream_insert<char,std::char_traits<char>>
(poVar2,"sigaction(kFailureSignal.number, &sig_action, nullptr)",0x36);
ErrnoLogMessage::~ErrnoLogMessage((ErrnoLogMessage *)local_128);
}
lVar3 = lVar3 + 0x10;
} while (lVar3 != 0x60);
return;
}
|
|
19,942
|
ma_compact_keypage
|
eloqsql/storage/maria/ma_page.c
|
my_bool _ma_compact_keypage(MARIA_PAGE *ma_page, TrID min_read_from)
{
MARIA_HA *info= ma_page->info;
MARIA_SHARE *share= info->s;
MARIA_KEY key;
uchar *page, *endpos, *start_of_empty_space;
uint page_flag, nod_flag, saved_space;
my_bool page_has_transid;
DBUG_ENTER("_ma_compact_keypage");
page_flag= ma_page->flag;
if (!(page_flag & KEYPAGE_FLAG_HAS_TRANSID))
DBUG_RETURN(0); /* No transaction id on page */
nod_flag= ma_page->node;
page= ma_page->buff;
endpos= page + ma_page->size;
key.data= info->lastkey_buff;
key.keyinfo= (MARIA_KEYDEF*) ma_page->keyinfo;
page_has_transid= 0;
page+= share->keypage_header + nod_flag;
key.data[0]= 0; /* safety */
start_of_empty_space= 0;
saved_space= 0;
do
{
if (!(page= (*ma_page->keyinfo->skip_key)(&key, 0, 0, page)))
{
DBUG_PRINT("error",("Couldn't find last key: page_pos: %p",
page));
_ma_set_fatal_error(info, HA_ERR_CRASHED);
DBUG_RETURN(1);
}
if (key_has_transid(page-1))
{
uint transid_length;
transid_length= transid_packed_length(page);
if (min_read_from == ~(TrID) 0 ||
min_read_from < transid_get_packed(share, page))
{
page[-1]&= 254; /* Remove transid marker */
transid_length= transid_packed_length(page);
if (start_of_empty_space)
{
/* Move block before the transid up in page */
uint copy_length= (uint) (page - start_of_empty_space) - saved_space;
memmove(start_of_empty_space, start_of_empty_space + saved_space,
copy_length);
start_of_empty_space+= copy_length;
}
else
start_of_empty_space= page;
saved_space+= transid_length;
}
else
page_has_transid= 1; /* At least one id left */
page+= transid_length;
}
page+= nod_flag;
} while (page < endpos);
DBUG_ASSERT(page == endpos);
if (start_of_empty_space)
{
/*
Move last block down
This is always true if any transid was removed
*/
uint copy_length= (uint) (endpos - start_of_empty_space) - saved_space;
if (copy_length)
memmove(start_of_empty_space, start_of_empty_space + saved_space,
copy_length);
ma_page->size= (uint) (start_of_empty_space + copy_length - ma_page->buff);
page_store_size(share, ma_page);
}
if (!page_has_transid)
{
ma_page->flag&= ~KEYPAGE_FLAG_HAS_TRANSID;
_ma_store_keypage_flag(share, ma_page->buff, ma_page->flag);
/* Clear packed transid (in case of zerofill) */
bzero(ma_page->buff + LSN_STORE_SIZE, TRANSID_SIZE);
}
if (share->now_transactional)
{
if (_ma_log_compact_keypage(ma_page, min_read_from))
DBUG_RETURN(1);
}
DBUG_RETURN(0);
}
|
O0
|
c
|
ma_compact_keypage:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
movl 0x2c(%rax), %eax
movl %eax, -0x64(%rbp)
movl -0x64(%rbp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
jne 0x6fa59
jmp 0x6fa50
movb $0x0, -0x1(%rbp)
jmp 0x6fd7a
movq -0x10(%rbp), %rax
movl 0x28(%rax), %eax
movl %eax, -0x68(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rax
movq -0x10(%rbp), %rcx
movl 0x20(%rcx), %ecx
addq %rcx, %rax
movq %rax, -0x58(%rbp)
movq -0x20(%rbp), %rax
movq 0x388(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x40(%rbp)
movb $0x0, -0x6d(%rbp)
movq -0x28(%rbp), %rax
movl 0x744(%rax), %ecx
addl -0x68(%rbp), %ecx
movq -0x50(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x50(%rbp)
movq -0x48(%rbp), %rax
movb $0x0, (%rax)
movq $0x0, -0x60(%rbp)
movl $0x0, -0x6c(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq 0xe8(%rax), %rax
movq -0x50(%rbp), %rcx
leaq -0x48(%rbp), %rdi
xorl %edx, %edx
movl %edx, %esi
callq *%rax
movq %rax, -0x50(%rbp)
cmpq $0x0, %rax
jne 0x6fb12
jmp 0x6faf9
jmp 0x6fafb
movq -0x20(%rbp), %rdi
movl $0x7e, %esi
callq 0x338b0
movb $0x1, -0x1(%rbp)
jmp 0x6fd7a
movq -0x50(%rbp), %rax
movzbl -0x1(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x6fc3e
movq -0x50(%rbp), %rax
movzbl (%rax), %eax
cmpl $0xf3, %eax
jge 0x6fb41
movl $0x1, %eax
movl %eax, -0x84(%rbp)
jmp 0x6fb53
movq -0x50(%rbp), %rax
movzbl (%rax), %eax
subl $0xf8, %eax
movl %eax, -0x84(%rbp)
movl -0x84(%rbp), %eax
movl %eax, -0x74(%rbp)
cmpq $-0x1, -0x18(%rbp)
je 0x6fb8e
movq -0x18(%rbp), %rax
movq %rax, -0x90(%rbp)
movq -0x28(%rbp), %rdi
movq -0x50(%rbp), %rsi
callq 0x33b20
movq %rax, %rcx
movq -0x90(%rbp), %rax
cmpq %rcx, %rax
jae 0x6fc2a
movq -0x50(%rbp), %rax
movzbl -0x1(%rax), %ecx
andl $0xfe, %ecx
movb %cl, -0x1(%rax)
movq -0x50(%rbp), %rax
movzbl (%rax), %eax
cmpl $0xf3, %eax
jge 0x6fbba
movl $0x1, %eax
movl %eax, -0x94(%rbp)
jmp 0x6fbcc
movq -0x50(%rbp), %rax
movzbl (%rax), %eax
subl $0xf8, %eax
movl %eax, -0x94(%rbp)
movl -0x94(%rbp), %eax
movl %eax, -0x74(%rbp)
cmpq $0x0, -0x60(%rbp)
je 0x6fc17
movq -0x50(%rbp), %rax
movq -0x60(%rbp), %rcx
subq %rcx, %rax
subl -0x6c(%rbp), %eax
movl %eax, -0x78(%rbp)
movq -0x60(%rbp), %rdi
movq -0x60(%rbp), %rsi
movl -0x6c(%rbp), %eax
addq %rax, %rsi
movl -0x78(%rbp), %eax
movl %eax, %edx
callq 0x2a130
movl -0x78(%rbp), %ecx
movq -0x60(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x60(%rbp)
jmp 0x6fc1f
movq -0x50(%rbp), %rax
movq %rax, -0x60(%rbp)
movl -0x74(%rbp), %eax
addl -0x6c(%rbp), %eax
movl %eax, -0x6c(%rbp)
jmp 0x6fc2e
movb $0x1, -0x6d(%rbp)
movl -0x74(%rbp), %ecx
movq -0x50(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x50(%rbp)
movl -0x68(%rbp), %ecx
movq -0x50(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rax
cmpq -0x58(%rbp), %rax
jb 0x6fad0
jmp 0x6fc5e
jmp 0x6fc60
cmpq $0x0, -0x60(%rbp)
je 0x6fcfb
movq -0x58(%rbp), %rax
movq -0x60(%rbp), %rcx
subq %rcx, %rax
subl -0x6c(%rbp), %eax
movl %eax, -0x7c(%rbp)
cmpl $0x0, -0x7c(%rbp)
je 0x6fc9a
movq -0x60(%rbp), %rdi
movq -0x60(%rbp), %rsi
movl -0x6c(%rbp), %eax
addq %rax, %rsi
movl -0x7c(%rbp), %eax
movl %eax, %edx
callq 0x2a130
movq -0x60(%rbp), %rax
movl -0x7c(%rbp), %ecx
addq %rcx, %rax
movq -0x10(%rbp), %rcx
movq 0x10(%rcx), %rcx
subq %rcx, %rax
movl %eax, %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x20(%rax)
movq -0x10(%rbp), %rax
movl 0x20(%rax), %eax
movl %eax, -0x80(%rbp)
movl -0x80(%rbp), %eax
movb %al, %dl
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x28(%rbp), %rcx
movl 0x744(%rcx), %ecx
movb %dl, -0x1(%rax,%rcx)
movl -0x80(%rbp), %eax
shrl $0x8, %eax
movb %al, %dl
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x28(%rbp), %rcx
movl 0x744(%rcx), %ecx
movb %dl, -0x2(%rax,%rcx)
cmpb $0x0, -0x6d(%rbp)
jne 0x6fd4c
movq -0x10(%rbp), %rax
movl 0x2c(%rax), %ecx
andl $-0x3, %ecx
movl %ecx, 0x2c(%rax)
movq -0x10(%rbp), %rax
movl 0x2c(%rax), %eax
movb %al, %dl
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x28(%rbp), %rcx
movl 0x744(%rcx), %ecx
subl $0x2, %ecx
subl $0x1, %ecx
movl %ecx, %ecx
movb %dl, (%rax,%rcx)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rdi
addq $0x7, %rdi
xorl %esi, %esi
movl $0x6, %edx
callq 0x2a2c0
movq -0x28(%rbp), %rax
cmpb $0x0, 0x7e7(%rax)
je 0x6fd74
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x6fd90
cmpb $0x0, %al
je 0x6fd72
jmp 0x6fd6c
movb $0x1, -0x1(%rbp)
jmp 0x6fd7a
jmp 0x6fd74
jmp 0x6fd76
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0xa0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
_ma_compact_keypage:
push rbp
mov rbp, rsp
sub rsp, 0A0h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
mov rax, [rax]
mov [rbp+var_28], rax
mov rax, [rbp+var_10]
mov eax, [rax+2Ch]
mov [rbp+var_64], eax
mov eax, [rbp+var_64]
and eax, 2
cmp eax, 0
jnz short loc_6FA59
jmp short $+2
loc_6FA50:
mov [rbp+var_1], 0
jmp loc_6FD7A
loc_6FA59:
mov rax, [rbp+var_10]
mov eax, [rax+28h]
mov [rbp+var_68], eax
mov rax, [rbp+var_10]
mov rax, [rax+10h]
mov [rbp+var_50], rax
mov rax, [rbp+var_50]
mov rcx, [rbp+var_10]
mov ecx, [rcx+20h]
add rax, rcx
mov [rbp+var_58], rax
mov rax, [rbp+var_20]
mov rax, [rax+388h]
mov [rbp+var_48], rax
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov [rbp+var_40], rax
mov [rbp+var_6D], 0
mov rax, [rbp+var_28]
mov ecx, [rax+744h]
add ecx, [rbp+var_68]
mov rax, [rbp+var_50]
mov ecx, ecx
add rax, rcx
mov [rbp+var_50], rax
mov rax, [rbp+var_48]
mov byte ptr [rax], 0
mov [rbp+var_60], 0
mov [rbp+var_6C], 0
loc_6FAD0:
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov rax, [rax+0E8h]
mov rcx, [rbp+var_50]
lea rdi, [rbp+var_48]
xor edx, edx
mov esi, edx
call rax
mov [rbp+var_50], rax
cmp rax, 0
jnz short loc_6FB12
jmp short $+2
loc_6FAF9:
jmp short $+2
loc_6FAFB:
mov rdi, [rbp+var_20]
mov esi, 7Eh ; '~'
call _ma_set_fatal_error
mov [rbp+var_1], 1
jmp loc_6FD7A
loc_6FB12:
mov rax, [rbp+var_50]
movzx eax, byte ptr [rax-1]
and eax, 1
cmp eax, 0
jz loc_6FC3E
mov rax, [rbp+var_50]
movzx eax, byte ptr [rax]
cmp eax, 0F3h
jge short loc_6FB41
mov eax, 1
mov [rbp+var_84], eax
jmp short loc_6FB53
loc_6FB41:
mov rax, [rbp+var_50]
movzx eax, byte ptr [rax]
sub eax, 0F8h
mov [rbp+var_84], eax
loc_6FB53:
mov eax, [rbp+var_84]
mov [rbp+var_74], eax
cmp [rbp+var_18], 0FFFFFFFFFFFFFFFFh
jz short loc_6FB8E
mov rax, [rbp+var_18]
mov [rbp+var_90], rax
mov rdi, [rbp+var_28]
mov rsi, [rbp+var_50]
call transid_get_packed
mov rcx, rax
mov rax, [rbp+var_90]
cmp rax, rcx
jnb loc_6FC2A
loc_6FB8E:
mov rax, [rbp+var_50]
movzx ecx, byte ptr [rax-1]
and ecx, 0FEh
mov [rax-1], cl
mov rax, [rbp+var_50]
movzx eax, byte ptr [rax]
cmp eax, 0F3h
jge short loc_6FBBA
mov eax, 1
mov [rbp+var_94], eax
jmp short loc_6FBCC
loc_6FBBA:
mov rax, [rbp+var_50]
movzx eax, byte ptr [rax]
sub eax, 0F8h
mov [rbp+var_94], eax
loc_6FBCC:
mov eax, [rbp+var_94]
mov [rbp+var_74], eax
cmp [rbp+var_60], 0
jz short loc_6FC17
mov rax, [rbp+var_50]
mov rcx, [rbp+var_60]
sub rax, rcx
sub eax, [rbp+var_6C]
mov [rbp+var_78], eax
mov rdi, [rbp+var_60]
mov rsi, [rbp+var_60]
mov eax, [rbp+var_6C]
add rsi, rax
mov eax, [rbp+var_78]
mov edx, eax
call _memmove
mov ecx, [rbp+var_78]
mov rax, [rbp+var_60]
mov ecx, ecx
add rax, rcx
mov [rbp+var_60], rax
jmp short loc_6FC1F
loc_6FC17:
mov rax, [rbp+var_50]
mov [rbp+var_60], rax
loc_6FC1F:
mov eax, [rbp+var_74]
add eax, [rbp+var_6C]
mov [rbp+var_6C], eax
jmp short loc_6FC2E
loc_6FC2A:
mov [rbp+var_6D], 1
loc_6FC2E:
mov ecx, [rbp+var_74]
mov rax, [rbp+var_50]
mov ecx, ecx
add rax, rcx
mov [rbp+var_50], rax
loc_6FC3E:
mov ecx, [rbp+var_68]
mov rax, [rbp+var_50]
mov ecx, ecx
add rax, rcx
mov [rbp+var_50], rax
mov rax, [rbp+var_50]
cmp rax, [rbp+var_58]
jb loc_6FAD0
jmp short $+2
loc_6FC5E:
jmp short $+2
loc_6FC60:
cmp [rbp+var_60], 0
jz loc_6FCFB
mov rax, [rbp+var_58]
mov rcx, [rbp+var_60]
sub rax, rcx
sub eax, [rbp+var_6C]
mov [rbp+var_7C], eax
cmp [rbp+var_7C], 0
jz short loc_6FC9A
mov rdi, [rbp+var_60]
mov rsi, [rbp+var_60]
mov eax, [rbp+var_6C]
add rsi, rax
mov eax, [rbp+var_7C]
mov edx, eax
call _memmove
loc_6FC9A:
mov rax, [rbp+var_60]
mov ecx, [rbp+var_7C]
add rax, rcx
mov rcx, [rbp+var_10]
mov rcx, [rcx+10h]
sub rax, rcx
mov ecx, eax
mov rax, [rbp+var_10]
mov [rax+20h], ecx
mov rax, [rbp+var_10]
mov eax, [rax+20h]
mov [rbp+var_80], eax
mov eax, [rbp+var_80]
mov dl, al
mov rax, [rbp+var_10]
mov rax, [rax+10h]
mov rcx, [rbp+var_28]
mov ecx, [rcx+744h]
mov [rax+rcx-1], dl
mov eax, [rbp+var_80]
shr eax, 8
mov dl, al
mov rax, [rbp+var_10]
mov rax, [rax+10h]
mov rcx, [rbp+var_28]
mov ecx, [rcx+744h]
mov [rax+rcx-2], dl
loc_6FCFB:
cmp [rbp+var_6D], 0
jnz short loc_6FD4C
mov rax, [rbp+var_10]
mov ecx, [rax+2Ch]
and ecx, 0FFFFFFFDh
mov [rax+2Ch], ecx
mov rax, [rbp+var_10]
mov eax, [rax+2Ch]
mov dl, al
mov rax, [rbp+var_10]
mov rax, [rax+10h]
mov rcx, [rbp+var_28]
mov ecx, [rcx+744h]
sub ecx, 2
sub ecx, 1
mov ecx, ecx
mov [rax+rcx], dl
mov rax, [rbp+var_10]
mov rdi, [rax+10h]
add rdi, 7
xor esi, esi
mov edx, 6
call _memset
loc_6FD4C:
mov rax, [rbp+var_28]
cmp byte ptr [rax+7E7h], 0
jz short loc_6FD74
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call _ma_log_compact_keypage
cmp al, 0
jz short loc_6FD72
jmp short $+2
loc_6FD6C:
mov [rbp+var_1], 1
jmp short loc_6FD7A
loc_6FD72:
jmp short $+2
loc_6FD74:
jmp short $+2
loc_6FD76:
mov [rbp+var_1], 0
loc_6FD7A:
mov al, [rbp+var_1]
add rsp, 0A0h
pop rbp
retn
|
bool ma_compact_keypage(long long a1, unsigned long long a2)
{
long long v2; // rdx
long long v3; // rcx
long long v4; // r8
int v5; // r9d
int v7; // [rsp+Ch] [rbp-94h]
unsigned long long v8; // [rsp+10h] [rbp-90h]
int v9; // [rsp+1Ch] [rbp-84h]
int v10; // [rsp+20h] [rbp-80h]
unsigned int v11; // [rsp+2Ch] [rbp-74h]
char v12; // [rsp+33h] [rbp-6Dh]
int v13; // [rsp+34h] [rbp-6Ch]
int v14; // [rsp+38h] [rbp-68h]
unsigned __int8 *v15; // [rsp+40h] [rbp-60h]
unsigned long long v16; // [rsp+48h] [rbp-58h]
long long v17; // [rsp+50h] [rbp-50h]
unsigned __int8 *v18; // [rsp+50h] [rbp-50h]
unsigned __int8 *v19; // [rsp+50h] [rbp-50h]
_QWORD v20[4]; // [rsp+58h] [rbp-48h] BYREF
long long v21; // [rsp+78h] [rbp-28h]
_DWORD *v22; // [rsp+80h] [rbp-20h]
unsigned long long v23; // [rsp+88h] [rbp-18h]
long long v24; // [rsp+90h] [rbp-10h]
v24 = a1;
v23 = a2;
v22 = *(_DWORD **)a1;
v21 = *(_QWORD *)v22;
if ( (*(_DWORD *)(a1 + 44) & 2) == 0 )
return 0;
v14 = *(_DWORD *)(v24 + 40);
v17 = *(_QWORD *)(v24 + 16);
v16 = *(unsigned int *)(v24 + 32) + v17;
v20[0] = *((_QWORD *)v22 + 113);
v20[1] = *(_QWORD *)(v24 + 8);
v12 = 0;
v18 = (unsigned __int8 *)((unsigned int)(v14 + *(_DWORD *)(v21 + 1860)) + v17);
*(_BYTE *)v20[0] = 0;
v15 = 0LL;
v13 = 0;
do
{
v19 = (unsigned __int8 *)(*(long long ( **)(_QWORD *, _QWORD, _QWORD, unsigned __int8 *))(*(_QWORD *)(v24 + 8) + 232LL))(
v20,
0LL,
0LL,
v18);
if ( !v19 )
{
ma_set_fatal_error(v22, 126, v2, v3, v4, v5);
return 1;
}
if ( (*(v19 - 1) & 1) != 0 )
{
if ( *v19 >= 0xF3u )
v9 = *v19 - 248;
else
v9 = 1;
v11 = v9;
if ( v23 == -1LL || (v8 = v23, v8 < transid_get_packed(v21, v19)) )
{
*(v19 - 1) &= ~1u;
if ( *v19 >= 0xF3u )
v7 = *v19 - 248;
else
v7 = 1;
v11 = v7;
if ( v15 )
{
memmove(v15, &v15[v13], (unsigned int)((_DWORD)v19 - (_DWORD)v15 - v13));
v15 += (unsigned int)((_DWORD)v19 - (_DWORD)v15 - v13);
}
else
{
v15 = v19;
}
v13 += v7;
}
else
{
v12 = 1;
}
v19 += v11;
}
v18 = &v19[v14];
}
while ( (unsigned long long)v18 < v16 );
if ( v15 )
{
if ( (_DWORD)v16 - (_DWORD)v15 != v13 )
memmove(v15, &v15[v13], (unsigned int)(v16 - (_DWORD)v15 - v13));
*(_DWORD *)(v24 + 32) = v16 - v13 - *(_QWORD *)(v24 + 16);
v10 = *(_DWORD *)(v24 + 32);
*(_BYTE *)(*(_QWORD *)(v24 + 16) + *(unsigned int *)(v21 + 1860) - 1LL) = v10;
*(_BYTE *)(*(_QWORD *)(v24 + 16) + *(unsigned int *)(v21 + 1860) - 2LL) = BYTE1(v10);
}
if ( !v12 )
{
*(_DWORD *)(v24 + 44) &= ~2u;
*(_BYTE *)(*(_QWORD *)(v24 + 16) + (unsigned int)(*(_DWORD *)(v21 + 1860) - 3)) = *(_DWORD *)(v24 + 44);
memset(*(_QWORD *)(v24 + 16) + 7LL, 0LL, 6LL);
}
return *(_BYTE *)(v21 + 2023) && (unsigned __int8)ma_log_compact_keypage(v24, v23);
}
|
_ma_compact_keypage:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xa0
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x2c]
MOV dword ptr [RBP + -0x64],EAX
MOV EAX,dword ptr [RBP + -0x64]
AND EAX,0x2
CMP EAX,0x0
JNZ 0x0016fa59
JMP 0x0016fa50
LAB_0016fa50:
MOV byte ptr [RBP + -0x1],0x0
JMP 0x0016fd7a
LAB_0016fa59:
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x28]
MOV dword ptr [RBP + -0x68],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x50]
MOV RCX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RCX + 0x20]
ADD RAX,RCX
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x388]
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x40],RAX
MOV byte ptr [RBP + -0x6d],0x0
MOV RAX,qword ptr [RBP + -0x28]
MOV ECX,dword ptr [RAX + 0x744]
ADD ECX,dword ptr [RBP + -0x68]
MOV RAX,qword ptr [RBP + -0x50]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV byte ptr [RAX],0x0
MOV qword ptr [RBP + -0x60],0x0
MOV dword ptr [RBP + -0x6c],0x0
LAB_0016fad0:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX + 0xe8]
MOV RCX,qword ptr [RBP + -0x50]
LEA RDI,[RBP + -0x48]
XOR EDX,EDX
MOV ESI,EDX
CALL RAX
MOV qword ptr [RBP + -0x50],RAX
CMP RAX,0x0
JNZ 0x0016fb12
JMP 0x0016faf9
LAB_0016faf9:
JMP 0x0016fafb
LAB_0016fafb:
MOV RDI,qword ptr [RBP + -0x20]
MOV ESI,0x7e
CALL 0x001338b0
MOV byte ptr [RBP + -0x1],0x1
JMP 0x0016fd7a
LAB_0016fb12:
MOV RAX,qword ptr [RBP + -0x50]
MOVZX EAX,byte ptr [RAX + -0x1]
AND EAX,0x1
CMP EAX,0x0
JZ 0x0016fc3e
MOV RAX,qword ptr [RBP + -0x50]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xf3
JGE 0x0016fb41
MOV EAX,0x1
MOV dword ptr [RBP + -0x84],EAX
JMP 0x0016fb53
LAB_0016fb41:
MOV RAX,qword ptr [RBP + -0x50]
MOVZX EAX,byte ptr [RAX]
SUB EAX,0xf8
MOV dword ptr [RBP + -0x84],EAX
LAB_0016fb53:
MOV EAX,dword ptr [RBP + -0x84]
MOV dword ptr [RBP + -0x74],EAX
CMP qword ptr [RBP + -0x18],-0x1
JZ 0x0016fb8e
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x90],RAX
MOV RDI,qword ptr [RBP + -0x28]
MOV RSI,qword ptr [RBP + -0x50]
CALL 0x00133b20
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x90]
CMP RAX,RCX
JNC 0x0016fc2a
LAB_0016fb8e:
MOV RAX,qword ptr [RBP + -0x50]
MOVZX ECX,byte ptr [RAX + -0x1]
AND ECX,0xfe
MOV byte ptr [RAX + -0x1],CL
MOV RAX,qword ptr [RBP + -0x50]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xf3
JGE 0x0016fbba
MOV EAX,0x1
MOV dword ptr [RBP + -0x94],EAX
JMP 0x0016fbcc
LAB_0016fbba:
MOV RAX,qword ptr [RBP + -0x50]
MOVZX EAX,byte ptr [RAX]
SUB EAX,0xf8
MOV dword ptr [RBP + -0x94],EAX
LAB_0016fbcc:
MOV EAX,dword ptr [RBP + -0x94]
MOV dword ptr [RBP + -0x74],EAX
CMP qword ptr [RBP + -0x60],0x0
JZ 0x0016fc17
MOV RAX,qword ptr [RBP + -0x50]
MOV RCX,qword ptr [RBP + -0x60]
SUB RAX,RCX
SUB EAX,dword ptr [RBP + -0x6c]
MOV dword ptr [RBP + -0x78],EAX
MOV RDI,qword ptr [RBP + -0x60]
MOV RSI,qword ptr [RBP + -0x60]
MOV EAX,dword ptr [RBP + -0x6c]
ADD RSI,RAX
MOV EAX,dword ptr [RBP + -0x78]
MOV EDX,EAX
CALL 0x0012a130
MOV ECX,dword ptr [RBP + -0x78]
MOV RAX,qword ptr [RBP + -0x60]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x60],RAX
JMP 0x0016fc1f
LAB_0016fc17:
MOV RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x60],RAX
LAB_0016fc1f:
MOV EAX,dword ptr [RBP + -0x74]
ADD EAX,dword ptr [RBP + -0x6c]
MOV dword ptr [RBP + -0x6c],EAX
JMP 0x0016fc2e
LAB_0016fc2a:
MOV byte ptr [RBP + -0x6d],0x1
LAB_0016fc2e:
MOV ECX,dword ptr [RBP + -0x74]
MOV RAX,qword ptr [RBP + -0x50]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x50],RAX
LAB_0016fc3e:
MOV ECX,dword ptr [RBP + -0x68]
MOV RAX,qword ptr [RBP + -0x50]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x50]
CMP RAX,qword ptr [RBP + -0x58]
JC 0x0016fad0
JMP 0x0016fc5e
LAB_0016fc5e:
JMP 0x0016fc60
LAB_0016fc60:
CMP qword ptr [RBP + -0x60],0x0
JZ 0x0016fcfb
MOV RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x60]
SUB RAX,RCX
SUB EAX,dword ptr [RBP + -0x6c]
MOV dword ptr [RBP + -0x7c],EAX
CMP dword ptr [RBP + -0x7c],0x0
JZ 0x0016fc9a
MOV RDI,qword ptr [RBP + -0x60]
MOV RSI,qword ptr [RBP + -0x60]
MOV EAX,dword ptr [RBP + -0x6c]
ADD RSI,RAX
MOV EAX,dword ptr [RBP + -0x7c]
MOV EDX,EAX
CALL 0x0012a130
LAB_0016fc9a:
MOV RAX,qword ptr [RBP + -0x60]
MOV ECX,dword ptr [RBP + -0x7c]
ADD RAX,RCX
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x10]
SUB RAX,RCX
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x20],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x20]
MOV dword ptr [RBP + -0x80],EAX
MOV EAX,dword ptr [RBP + -0x80]
MOV DL,AL
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x28]
MOV ECX,dword ptr [RCX + 0x744]
MOV byte ptr [RAX + RCX*0x1 + -0x1],DL
MOV EAX,dword ptr [RBP + -0x80]
SHR EAX,0x8
MOV DL,AL
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x28]
MOV ECX,dword ptr [RCX + 0x744]
MOV byte ptr [RAX + RCX*0x1 + -0x2],DL
LAB_0016fcfb:
CMP byte ptr [RBP + -0x6d],0x0
JNZ 0x0016fd4c
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x2c]
AND ECX,0xfffffffd
MOV dword ptr [RAX + 0x2c],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x2c]
MOV DL,AL
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RBP + -0x28]
MOV ECX,dword ptr [RCX + 0x744]
SUB ECX,0x2
SUB ECX,0x1
MOV ECX,ECX
MOV byte ptr [RAX + RCX*0x1],DL
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX + 0x10]
ADD RDI,0x7
XOR ESI,ESI
MOV EDX,0x6
CALL 0x0012a2c0
LAB_0016fd4c:
MOV RAX,qword ptr [RBP + -0x28]
CMP byte ptr [RAX + 0x7e7],0x0
JZ 0x0016fd74
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x0016fd90
CMP AL,0x0
JZ 0x0016fd72
JMP 0x0016fd6c
LAB_0016fd6c:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x0016fd7a
LAB_0016fd72:
JMP 0x0016fd74
LAB_0016fd74:
JMP 0x0016fd76
LAB_0016fd76:
MOV byte ptr [RBP + -0x1],0x0
LAB_0016fd7a:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0xa0
POP RBP
RET
|
int1 _ma_compact_keypage(long *param_1,ulong param_2)
{
bool bVar1;
long lVar2;
ulong uVar3;
byte *pbVar4;
char cVar5;
uint uVar6;
uint uVar7;
byte *pbVar8;
ulong uVar9;
uint local_9c;
uint local_8c;
uint local_7c;
uint local_74;
byte *local_68;
byte *local_58;
int1 *local_50;
long local_48;
long local_30;
long *local_28;
ulong local_20;
long *local_18;
int1 local_9;
local_28 = (long *)*param_1;
local_30 = *local_28;
if ((*(uint *)((long)param_1 + 0x2c) & 2) == 0) {
local_9 = 0;
}
else {
uVar7 = *(uint *)(param_1 + 5);
pbVar8 = (byte *)(param_1[2] + (ulong)*(uint *)(param_1 + 4));
local_50 = (int1 *)local_28[0x71];
local_48 = param_1[1];
bVar1 = false;
local_58 = (byte *)(param_1[2] + (ulong)(*(int *)(local_30 + 0x744) + uVar7));
*local_50 = 0;
local_68 = (byte *)0x0;
local_74 = 0;
local_20 = param_2;
local_18 = param_1;
do {
local_58 = (byte *)(**(code **)(local_18[1] + 0xe8))(&local_50,0,0,local_58);
uVar3 = local_20;
if (local_58 == (byte *)0x0) {
_ma_set_fatal_error(local_28,0x7e);
return 1;
}
if ((local_58[-1] & 1) != 0) {
if (*local_58 < 0xf3) {
local_8c = 1;
}
else {
local_8c = *local_58 - 0xf8;
}
local_7c = local_8c;
if ((local_20 == 0xffffffffffffffff) ||
(uVar9 = transid_get_packed(local_30), uVar3 < uVar9)) {
local_58[-1] = local_58[-1] & 0xfe;
if (*local_58 < 0xf3) {
local_9c = 1;
}
else {
local_9c = *local_58 - 0xf8;
}
local_7c = local_9c;
pbVar4 = local_58;
if (local_68 != (byte *)0x0) {
uVar6 = ((int)local_58 - (int)local_68) - local_74;
memmove(local_68,local_68 + local_74,(ulong)uVar6);
pbVar4 = local_68 + uVar6;
}
local_68 = pbVar4;
local_74 = local_9c + local_74;
}
else {
bVar1 = true;
}
local_58 = local_58 + local_7c;
}
local_58 = local_58 + uVar7;
} while (local_58 < pbVar8);
if (local_68 != (byte *)0x0) {
uVar7 = ((int)pbVar8 - (int)local_68) - local_74;
if (uVar7 != 0) {
memmove(local_68,local_68 + local_74,(ulong)uVar7);
}
*(uint *)(local_18 + 4) = ((int)local_68 + uVar7) - (int)local_18[2];
lVar2 = local_18[4];
*(char *)(local_18[2] + -1 + (ulong)*(uint *)(local_30 + 0x744)) = (char)(int)lVar2;
*(char *)(local_18[2] + -2 + (ulong)*(uint *)(local_30 + 0x744)) =
(char)((uint)(int)lVar2 >> 8);
}
if (!bVar1) {
*(uint *)((long)local_18 + 0x2c) = *(uint *)((long)local_18 + 0x2c) & 0xfffffffd;
*(char *)(local_18[2] + (ulong)(*(int *)(local_30 + 0x744) - 3)) =
(char)*(int4 *)((long)local_18 + 0x2c);
memset((void *)(local_18[2] + 7),0,6);
}
if ((*(char *)(local_30 + 0x7e7) == '\0') ||
(cVar5 = _ma_log_compact_keypage(local_18,local_20), cVar5 == '\0')) {
local_9 = 0;
}
else {
local_9 = 1;
}
}
return local_9;
}
|
|
19,943
|
nice_time
|
eloqsql/unittest/mytap/tap.c
|
static void nice_time(double sec,char *buff, my_bool part_second)
{
ulong tmp;
if (sec >= 3600.0*24)
{
tmp=(ulong) (sec/(3600.0*24));
sec-=3600.0*24*tmp;
buff+= sprintf(buff, "%ld %s", tmp, tmp > 1 ? " days " : " day ");
}
if (sec >= 3600.0)
{
tmp=(ulong) (sec/3600.0);
sec-=3600.0*tmp;
buff+= sprintf(buff, "%ld %s", tmp, tmp > 1 ? " hours " : " hour ");
}
if (sec >= 60.0)
{
tmp=(ulong) (sec/60.0);
sec-=60.0*tmp;
buff+= sprintf(buff, "%ld min ", tmp);
}
if (part_second)
sprintf(buff,"%.2f sec",sec);
else
sprintf(buff,"%d sec",(int) sec);
}
|
O0
|
c
|
nice_time:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movb %sil, %al
movsd %xmm0, -0x8(%rbp)
movq %rdi, -0x10(%rbp)
movb %al, -0x11(%rbp)
movsd -0x8(%rbp), %xmm0
movsd 0x86a1c(%rip), %xmm1 # 0x162260
ucomisd %xmm1, %xmm0
jb 0xdb90a
movsd -0x8(%rbp), %xmm0
movsd 0x86a05(%rip), %xmm1 # 0x162260
divsd %xmm1, %xmm0
movaps %xmm0, %xmm1
cvttsd2si %xmm1, %rax
movq %rax, %rdx
sarq $0x3f, %rdx
movsd 0x869b2(%rip), %xmm1 # 0x162228
subsd %xmm1, %xmm0
cvttsd2si %xmm0, %rcx
andq %rdx, %rcx
orq %rcx, %rax
movq %rax, -0x20(%rbp)
movaps 0x86e20(%rip), %xmm1 # 0x1626b0
movq -0x20(%rbp), %xmm0
punpckldq %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movapd 0x86e1f(%rip), %xmm1 # 0x1626c0
subpd %xmm1, %xmm0
movaps %xmm0, %xmm1
unpckhpd %xmm0, %xmm0 # xmm0 = xmm0[1,1]
addsd %xmm1, %xmm0
movsd -0x8(%rbp), %xmm1
movsd 0x869ab(%rip), %xmm2 # 0x162268
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x8(%rbp)
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rdx
movq -0x20(%rbp), %rsi
leaq 0x80e6b(%rip), %rcx # 0x15c748
leaq 0x80e5d(%rip), %rax # 0x15c741
cmpq $0x1, %rsi
cmovaq %rax, %rcx
leaq 0x80e47(%rip), %rsi # 0x15c73a
movb $0x0, %al
callq 0x2a7f0
movl %eax, %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
movsd -0x8(%rbp), %xmm0
movsd 0x86959(%rip), %xmm1 # 0x162270
ucomisd %xmm1, %xmm0
jb 0xdb9dd
movsd -0x8(%rbp), %xmm0
movsd 0x86942(%rip), %xmm1 # 0x162270
divsd %xmm1, %xmm0
movaps %xmm0, %xmm1
cvttsd2si %xmm1, %rax
movq %rax, %rdx
sarq $0x3f, %rdx
movsd 0x868df(%rip), %xmm1 # 0x162228
subsd %xmm1, %xmm0
cvttsd2si %xmm0, %rcx
andq %rdx, %rcx
orq %rcx, %rax
movq %rax, -0x20(%rbp)
movaps 0x86d4d(%rip), %xmm1 # 0x1626b0
movq -0x20(%rbp), %xmm0
punpckldq %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movapd 0x86d4c(%rip), %xmm1 # 0x1626c0
subpd %xmm1, %xmm0
movaps %xmm0, %xmm1
unpckhpd %xmm0, %xmm0 # xmm0 = xmm0[1,1]
addsd %xmm1, %xmm0
movsd -0x8(%rbp), %xmm1
movsd 0x868e8(%rip), %xmm2 # 0x162278
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x8(%rbp)
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rdx
movq -0x20(%rbp), %rsi
leaq 0x80da6(%rip), %rcx # 0x15c756
leaq 0x80d97(%rip), %rax # 0x15c74e
cmpq $0x1, %rsi
cmovaq %rax, %rcx
leaq 0x80d74(%rip), %rsi # 0x15c73a
movb $0x0, %al
callq 0x2a7f0
movl %eax, %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
movsd -0x8(%rbp), %xmm0
movsd 0x86896(%rip), %xmm1 # 0x162280
ucomisd %xmm1, %xmm0
jb 0xdba96
movsd -0x8(%rbp), %xmm0
movsd 0x8687f(%rip), %xmm1 # 0x162280
divsd %xmm1, %xmm0
movaps %xmm0, %xmm1
cvttsd2si %xmm1, %rax
movq %rax, %rdx
sarq $0x3f, %rdx
movsd 0x8680c(%rip), %xmm1 # 0x162228
subsd %xmm1, %xmm0
cvttsd2si %xmm0, %rcx
andq %rdx, %rcx
orq %rcx, %rax
movq %rax, -0x20(%rbp)
movaps 0x86c7a(%rip), %xmm1 # 0x1626b0
movq -0x20(%rbp), %xmm0
punpckldq %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movapd 0x86c79(%rip), %xmm1 # 0x1626c0
subpd %xmm1, %xmm0
movaps %xmm0, %xmm1
unpckhpd %xmm0, %xmm0 # xmm0 = xmm0[1,1]
addsd %xmm1, %xmm0
movsd -0x8(%rbp), %xmm1
movsd 0x86825(%rip), %xmm2 # 0x162288
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x8(%rbp)
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rdx
leaq 0x80cde(%rip), %rsi # 0x15c75d
movb $0x0, %al
callq 0x2a7f0
movl %eax, %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
cmpb $0x0, -0x11(%rbp)
je 0xdbab5
movq -0x10(%rbp), %rdi
movsd -0x8(%rbp), %xmm0
leaq 0x80cba(%rip), %rsi # 0x15c766
movb $0x1, %al
callq 0x2a7f0
jmp 0xdbacc
movq -0x10(%rbp), %rdi
cvttsd2si -0x8(%rbp), %edx
leaq 0x80caa(%rip), %rsi # 0x15c76f
movb $0x0, %al
callq 0x2a7f0
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
|
nice_time:
push rbp
mov rbp, rsp
sub rsp, 20h
mov al, sil
movsd [rbp+var_8], xmm0
mov [rbp+var_10], rdi
mov [rbp+var_11], al
movsd xmm0, [rbp+var_8]
movsd xmm1, cs:qword_162260
ucomisd xmm0, xmm1
jb loc_DB90A
movsd xmm0, [rbp+var_8]
movsd xmm1, cs:qword_162260
divsd xmm0, xmm1
movaps xmm1, xmm0
cvttsd2si rax, xmm1
mov rdx, rax
sar rdx, 3Fh
movsd xmm1, cs:qword_162228
subsd xmm0, xmm1
cvttsd2si rcx, xmm0
and rcx, rdx
or rax, rcx
mov [rbp+var_20], rax
movaps xmm1, cs:xmmword_1626B0
movq xmm0, [rbp+var_20]
punpckldq xmm0, xmm1
movapd xmm1, cs:xmmword_1626C0
subpd xmm0, xmm1
movaps xmm1, xmm0
unpckhpd xmm0, xmm0
addsd xmm0, xmm1
movsd xmm1, [rbp+var_8]
movsd xmm2, cs:qword_162268
mulsd xmm0, xmm2
addsd xmm0, xmm1
movsd [rbp+var_8], xmm0
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_20]
mov rsi, [rbp+var_20]
lea rcx, aDay; " day "
lea rax, aDays; " days "
cmp rsi, 1
cmova rcx, rax
lea rsi, aLdS; "%ld %s"
mov al, 0
call _sprintf
mov ecx, eax
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
loc_DB90A:
movsd xmm0, [rbp+var_8]
movsd xmm1, cs:qword_162270
ucomisd xmm0, xmm1
jb loc_DB9DD
movsd xmm0, [rbp+var_8]
movsd xmm1, cs:qword_162270
divsd xmm0, xmm1
movaps xmm1, xmm0
cvttsd2si rax, xmm1
mov rdx, rax
sar rdx, 3Fh
movsd xmm1, cs:qword_162228
subsd xmm0, xmm1
cvttsd2si rcx, xmm0
and rcx, rdx
or rax, rcx
mov [rbp+var_20], rax
movaps xmm1, cs:xmmword_1626B0
movq xmm0, [rbp+var_20]
punpckldq xmm0, xmm1
movapd xmm1, cs:xmmword_1626C0
subpd xmm0, xmm1
movaps xmm1, xmm0
unpckhpd xmm0, xmm0
addsd xmm0, xmm1
movsd xmm1, [rbp+var_8]
movsd xmm2, cs:qword_162278
mulsd xmm0, xmm2
addsd xmm0, xmm1
movsd [rbp+var_8], xmm0
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_20]
mov rsi, [rbp+var_20]
lea rcx, aHour; " hour "
lea rax, aHours; " hours "
cmp rsi, 1
cmova rcx, rax
lea rsi, aLdS; "%ld %s"
mov al, 0
call _sprintf
mov ecx, eax
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
loc_DB9DD:
movsd xmm0, [rbp+var_8]
movsd xmm1, cs:qword_162280
ucomisd xmm0, xmm1
jb loc_DBA96
movsd xmm0, [rbp+var_8]
movsd xmm1, cs:qword_162280
divsd xmm0, xmm1
movaps xmm1, xmm0
cvttsd2si rax, xmm1
mov rdx, rax
sar rdx, 3Fh
movsd xmm1, cs:qword_162228
subsd xmm0, xmm1
cvttsd2si rcx, xmm0
and rcx, rdx
or rax, rcx
mov [rbp+var_20], rax
movaps xmm1, cs:xmmword_1626B0
movq xmm0, [rbp+var_20]
punpckldq xmm0, xmm1
movapd xmm1, cs:xmmword_1626C0
subpd xmm0, xmm1
movaps xmm1, xmm0
unpckhpd xmm0, xmm0
addsd xmm0, xmm1
movsd xmm1, [rbp+var_8]
movsd xmm2, cs:qword_162288
mulsd xmm0, xmm2
addsd xmm0, xmm1
movsd [rbp+var_8], xmm0
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_20]
lea rsi, aLdMin; "%ld min "
mov al, 0
call _sprintf
mov ecx, eax
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
loc_DBA96:
cmp [rbp+var_11], 0
jz short loc_DBAB5
mov rdi, [rbp+var_10]
movsd xmm0, [rbp+var_8]
lea rsi, a2fSec; "%.2f sec"
mov al, 1
call _sprintf
jmp short loc_DBACC
loc_DBAB5:
mov rdi, [rbp+var_10]
cvttsd2si edx, [rbp+var_8]
lea rsi, aDSec; "%d sec"
mov al, 0
call _sprintf
loc_DBACC:
add rsp, 20h
pop rbp
retn
|
long long nice_time(long long a1, __int8 a2, double a3)
{
__m128d v3; // xmm0
const char *v4; // rcx
int v5; // eax
__m128d v6; // xmm0
const char *v7; // rcx
int v8; // eax
__m128d v9; // xmm0
int v10; // eax
__m128i v12; // [rsp+0h] [rbp-20h] BYREF
long long v13; // [rsp+10h] [rbp-10h]
double v14; // [rsp+18h] [rbp-8h]
v14 = a3;
v13 = a1;
v12.m128i_i8[15] = a2;
if ( a3 >= 86400.0 )
{
v12.m128i_i64[0] = (unsigned int)(int)(v14 / 86400.0);
v3 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32(_mm_loadl_epi64(&v12), (__m128i)xmmword_1626B0),
(__m128d)xmmword_1626C0);
v14 = (_mm_unpackhi_pd(v3, v3).m128d_f64[0] + v3.m128d_f64[0]) * -86400.0 + v14;
v4 = " day ";
if ( v12.m128i_i64[0] > 1uLL )
v4 = " days ";
v5 = sprintf(v13, "%ld %s", v12.m128i_i64[0], v4);
v13 += v5;
}
if ( v14 >= 3600.0 )
{
v12.m128i_i64[0] = (unsigned int)(int)(v14 / 3600.0);
v6 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32(_mm_loadl_epi64(&v12), (__m128i)xmmword_1626B0),
(__m128d)xmmword_1626C0);
v14 = (_mm_unpackhi_pd(v6, v6).m128d_f64[0] + v6.m128d_f64[0]) * -3600.0 + v14;
v7 = " hour ";
if ( v12.m128i_i64[0] > 1uLL )
v7 = " hours ";
v8 = sprintf(v13, "%ld %s", v12.m128i_i64[0], v7);
v13 += v8;
}
if ( v14 >= 60.0 )
{
v12.m128i_i64[0] = (unsigned int)(int)(v14 / 60.0);
v9 = _mm_sub_pd(
(__m128d)_mm_unpacklo_epi32(_mm_loadl_epi64(&v12), (__m128i)xmmword_1626B0),
(__m128d)xmmword_1626C0);
v14 = (_mm_unpackhi_pd(v9, v9).m128d_f64[0] + v9.m128d_f64[0]) * -60.0 + v14;
v10 = sprintf(v13, "%ld min ", v12.m128i_i64[0]);
v13 += v10;
}
if ( v12.m128i_i8[15] )
return sprintf(v13, "%.2f sec", v14);
else
return sprintf(v13, "%d sec", (int)v14);
}
|
nice_time:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV AL,SIL
MOVSD qword ptr [RBP + -0x8],XMM0
MOV qword ptr [RBP + -0x10],RDI
MOV byte ptr [RBP + -0x11],AL
MOVSD XMM0,qword ptr [RBP + -0x8]
MOVSD XMM1,qword ptr [0x00262260]
UCOMISD XMM0,XMM1
JC 0x001db90a
MOVSD XMM0,qword ptr [RBP + -0x8]
MOVSD XMM1,qword ptr [0x00262260]
DIVSD XMM0,XMM1
MOVAPS XMM1,XMM0
CVTTSD2SI RAX,XMM1
MOV RDX,RAX
SAR RDX,0x3f
MOVSD XMM1,qword ptr [0x00262228]
SUBSD XMM0,XMM1
CVTTSD2SI RCX,XMM0
AND RCX,RDX
OR RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
MOVAPS XMM1,xmmword ptr [0x002626b0]
MOVQ XMM0,qword ptr [RBP + -0x20]
PUNPCKLDQ XMM0,XMM1
MOVAPD XMM1,xmmword ptr [0x002626c0]
SUBPD XMM0,XMM1
MOVAPS XMM1,XMM0
UNPCKHPD XMM0,XMM0
ADDSD XMM0,XMM1
MOVSD XMM1,qword ptr [RBP + -0x8]
MOVSD XMM2,qword ptr [0x00262268]
MULSD XMM0,XMM2
ADDSD XMM0,XMM1
MOVSD qword ptr [RBP + -0x8],XMM0
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x20]
MOV RSI,qword ptr [RBP + -0x20]
LEA RCX,[0x25c748]
LEA RAX,[0x25c741]
CMP RSI,0x1
CMOVA RCX,RAX
LEA RSI,[0x25c73a]
MOV AL,0x0
CALL 0x0012a7f0
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
LAB_001db90a:
MOVSD XMM0,qword ptr [RBP + -0x8]
MOVSD XMM1,qword ptr [0x00262270]
UCOMISD XMM0,XMM1
JC 0x001db9dd
MOVSD XMM0,qword ptr [RBP + -0x8]
MOVSD XMM1,qword ptr [0x00262270]
DIVSD XMM0,XMM1
MOVAPS XMM1,XMM0
CVTTSD2SI RAX,XMM1
MOV RDX,RAX
SAR RDX,0x3f
MOVSD XMM1,qword ptr [0x00262228]
SUBSD XMM0,XMM1
CVTTSD2SI RCX,XMM0
AND RCX,RDX
OR RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
MOVAPS XMM1,xmmword ptr [0x002626b0]
MOVQ XMM0,qword ptr [RBP + -0x20]
PUNPCKLDQ XMM0,XMM1
MOVAPD XMM1,xmmword ptr [0x002626c0]
SUBPD XMM0,XMM1
MOVAPS XMM1,XMM0
UNPCKHPD XMM0,XMM0
ADDSD XMM0,XMM1
MOVSD XMM1,qword ptr [RBP + -0x8]
MOVSD XMM2,qword ptr [0x00262278]
MULSD XMM0,XMM2
ADDSD XMM0,XMM1
MOVSD qword ptr [RBP + -0x8],XMM0
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x20]
MOV RSI,qword ptr [RBP + -0x20]
LEA RCX,[0x25c756]
LEA RAX,[0x25c74e]
CMP RSI,0x1
CMOVA RCX,RAX
LEA RSI,[0x25c73a]
MOV AL,0x0
CALL 0x0012a7f0
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
LAB_001db9dd:
MOVSD XMM0,qword ptr [RBP + -0x8]
MOVSD XMM1,qword ptr [0x00262280]
UCOMISD XMM0,XMM1
JC 0x001dba96
MOVSD XMM0,qword ptr [RBP + -0x8]
MOVSD XMM1,qword ptr [0x00262280]
DIVSD XMM0,XMM1
MOVAPS XMM1,XMM0
CVTTSD2SI RAX,XMM1
MOV RDX,RAX
SAR RDX,0x3f
MOVSD XMM1,qword ptr [0x00262228]
SUBSD XMM0,XMM1
CVTTSD2SI RCX,XMM0
AND RCX,RDX
OR RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
MOVAPS XMM1,xmmword ptr [0x002626b0]
MOVQ XMM0,qword ptr [RBP + -0x20]
PUNPCKLDQ XMM0,XMM1
MOVAPD XMM1,xmmword ptr [0x002626c0]
SUBPD XMM0,XMM1
MOVAPS XMM1,XMM0
UNPCKHPD XMM0,XMM0
ADDSD XMM0,XMM1
MOVSD XMM1,qword ptr [RBP + -0x8]
MOVSD XMM2,qword ptr [0x00262288]
MULSD XMM0,XMM2
ADDSD XMM0,XMM1
MOVSD qword ptr [RBP + -0x8],XMM0
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x20]
LEA RSI,[0x25c75d]
MOV AL,0x0
CALL 0x0012a7f0
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
LAB_001dba96:
CMP byte ptr [RBP + -0x11],0x0
JZ 0x001dbab5
MOV RDI,qword ptr [RBP + -0x10]
MOVSD XMM0,qword ptr [RBP + -0x8]
LEA RSI,[0x25c766]
MOV AL,0x1
CALL 0x0012a7f0
JMP 0x001dbacc
LAB_001dbab5:
MOV RDI,qword ptr [RBP + -0x10]
CVTTSD2SI EDX,qword ptr [RBP + -0x8]
LEA RSI,[0x25c76f]
MOV AL,0x0
CALL 0x0012a7f0
LAB_001dbacc:
ADD RSP,0x20
POP RBP
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
void nice_time(double param_1,char *param_2,char param_3,int8 param_4)
{
int iVar1;
ulong uVar2;
char *pcVar3;
int4 extraout_var;
int4 extraout_var_00;
int4 extraout_var_01;
int4 uVar4;
int1 auVar5 [16];
int1 auVar6 [16];
int1 auVar7 [16];
char *local_18;
double local_10;
uVar4 = (int4)((ulong)param_4 >> 0x20);
local_18 = param_2;
local_10 = param_1;
if (DAT_00262260 <= param_1) {
uVar2 = (ulong)(param_1 / DAT_00262260);
uVar2 = uVar2 | (long)(param_1 / DAT_00262260 - DAT_00262228) & (long)uVar2 >> 0x3f;
auVar5._8_4_ = (int)(uVar2 >> 0x20);
auVar5._0_8_ = uVar2;
auVar5._12_4_ = _UNK_002626b4;
local_10 = ((auVar5._8_8_ - _UNK_002626c8) +
((double)CONCAT44(_DAT_002626b0,(int)uVar2) - _DAT_002626c0)) * DAT_00262268 +
param_1;
pcVar3 = " day ";
if (1 < uVar2) {
pcVar3 = " days ";
}
iVar1 = sprintf(param_2,"%ld %s",uVar2,pcVar3);
local_18 = param_2 + iVar1;
uVar4 = extraout_var;
}
if (DAT_00262270 <= local_10) {
uVar2 = (ulong)(local_10 / DAT_00262270);
uVar2 = uVar2 | (long)(local_10 / DAT_00262270 - DAT_00262228) & (long)uVar2 >> 0x3f;
auVar6._8_4_ = (int)(uVar2 >> 0x20);
auVar6._0_8_ = uVar2;
auVar6._12_4_ = _UNK_002626b4;
local_10 = ((auVar6._8_8_ - _UNK_002626c8) +
((double)CONCAT44(_DAT_002626b0,(int)uVar2) - _DAT_002626c0)) * DAT_00262278 +
local_10;
pcVar3 = " hour ";
if (1 < uVar2) {
pcVar3 = " hours ";
}
iVar1 = sprintf(local_18,"%ld %s",uVar2,pcVar3);
local_18 = local_18 + iVar1;
uVar4 = extraout_var_00;
}
if (DAT_00262280 <= local_10) {
uVar2 = (ulong)(local_10 / DAT_00262280);
uVar2 = uVar2 | (long)(local_10 / DAT_00262280 - DAT_00262228) & (long)uVar2 >> 0x3f;
auVar7._8_4_ = (int)(uVar2 >> 0x20);
auVar7._0_8_ = uVar2;
auVar7._12_4_ = _UNK_002626b4;
local_10 = ((auVar7._8_8_ - _UNK_002626c8) +
((double)CONCAT44(_DAT_002626b0,(int)uVar2) - _DAT_002626c0)) * DAT_00262288 +
local_10;
iVar1 = sprintf(local_18,"%ld min ",uVar2);
local_18 = local_18 + iVar1;
uVar4 = extraout_var_01;
}
if (param_3 == '\0') {
sprintf(local_18,"%d sec",CONCAT44(uVar4,(int)local_10));
}
else {
sprintf(local_18,"%.2f sec",local_10);
}
return;
}
|
|
19,944
|
spdlog::logger::sink_it_(spdlog::details::log_msg const&)
|
AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/logger-inl.h
|
SPDLOG_INLINE void logger::sink_it_(const details::log_msg &msg) {
for (auto &sink : sinks_) {
if (sink->should_log(msg.level)) {
SPDLOG_TRY { sink->log(msg); }
SPDLOG_LOGGER_CATCH(msg.source)
}
}
|
O0
|
c
|
spdlog::logger::sink_it_(spdlog::details::log_msg const&):
subq $0x1c8, %rsp # imm = 0x1C8
movq %rdi, 0xe8(%rsp)
movq %rsi, 0xe0(%rsp)
movq 0xe8(%rsp), %rax
movq %rax, 0x18(%rsp)
addq $0x28, %rax
movq %rax, 0xd8(%rsp)
movq 0xd8(%rsp), %rdi
callq 0x3a720
movq %rax, 0xd0(%rsp)
movq 0xd8(%rsp), %rdi
callq 0x3a790
movq %rax, 0xc8(%rsp)
leaq 0xd0(%rsp), %rdi
leaq 0xc8(%rsp), %rsi
callq 0x3a750
xorb $-0x1, %al
testb $0x1, %al
jne 0x35c9a
jmp 0x360dd
leaq 0xd0(%rsp), %rdi
callq 0x3a7f0
movq %rax, 0xc0(%rsp)
movq 0xc0(%rsp), %rdi
callq 0x3a800
movq %rax, %rdi
movq 0xe0(%rsp), %rax
movl 0x10(%rax), %esi
callq 0x36120
testb $0x1, %al
jne 0x35cd8
jmp 0x360c9
movq 0xc0(%rsp), %rdi
callq 0x3a800
movq %rax, %rdi
movq 0xe0(%rsp), %rsi
movq (%rdi), %rax
movq 0x10(%rax), %rax
callq *%rax
jmp 0x35cfb
jmp 0x360be
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xb8(%rsp)
movl %eax, 0xb4(%rsp)
movl 0xb4(%rsp), %eax
movl $0x2, %ecx
cmpl %ecx, %eax
jne 0x35f05
movq 0xb8(%rsp), %rdi
callq 0x14270
movq %rax, 0x80(%rsp)
movq 0xe0(%rsp), %rax
cmpq $0x0, 0x38(%rax)
je 0x36019
leaq 0xd6b80(%rip), %rax # 0x10c8d7
movq %rax, 0x50(%rsp)
movq $0xb, 0x58(%rsp)
movq 0x80(%rsp), %rdi
movq (%rdi), %rax
movq 0x10(%rax), %rax
callq *%rax
movq %rax, 0x48(%rsp)
movq 0xe0(%rsp), %rax
movq %rax, %rcx
addq $0x38, %rcx
addq $0x40, %rax
movq 0x50(%rsp), %rsi
movq 0x58(%rsp), %rdx
leaq 0x60(%rsp), %rdi
movq %rdi, 0x170(%rsp)
movq %rsi, 0x160(%rsp)
movq %rdx, 0x168(%rsp)
leaq 0x48(%rsp), %rdx
movq %rdx, 0x158(%rsp)
movq %rcx, 0x150(%rsp)
movq %rax, 0x148(%rsp)
leaq 0x160(%rsp), %rax
movq %rax, 0x178(%rsp)
movq 0x178(%rsp), %rax
movups (%rax), %xmm0
movaps %xmm0, 0x180(%rsp)
movq 0x180(%rsp), %rcx
movq 0x188(%rsp), %rax
movq %rcx, 0x138(%rsp)
movq %rax, 0x140(%rsp)
movq 0x158(%rsp), %rsi
movq 0x150(%rsp), %rdx
movq 0x148(%rsp), %rcx
leaq 0xf0(%rsp), %rdi
callq 0x4ba50
jmp 0x35e3c
leaq 0x128(%rsp), %rax
movq %rax, 0x1a0(%rsp)
leaq 0xf0(%rsp), %rax
movq %rax, 0x198(%rsp)
movq 0x1a0(%rsp), %rcx
movq 0x198(%rsp), %rax
movq %rax, 0x1a8(%rsp)
movq 0x1a8(%rsp), %rax
movq %rcx, 0x1c0(%rsp)
movq $0x1cc, 0x1b8(%rsp) # imm = 0x1CC
movq %rax, 0x1b0(%rsp)
movq 0x1c0(%rsp), %rax
movq 0x1b8(%rsp), %rcx
movq %rcx, (%rax)
movq 0x1b0(%rsp), %rcx
movq %rcx, 0x8(%rax)
movq 0x138(%rsp), %rsi
movq 0x140(%rsp), %rdx
movq 0x128(%rsp), %rcx
movq 0x130(%rsp), %r8
leaq 0x60(%rsp), %rdi
callq 0x87020
jmp 0x35ee3
jmp 0x35ee5
movq 0x18(%rsp), %rdi
leaq 0x60(%rsp), %rsi
callq 0x361c0
jmp 0x35ef6
leaq 0x60(%rsp), %rdi
callq 0x1aac0
jmp 0x360b9
movq 0xb8(%rsp), %rdi
callq 0x14270
leaq 0x8f(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x14c90
movq 0x10(%rsp), %rdx
leaq 0xd6980(%rip), %rsi # 0x10c8b0
leaq 0x90(%rsp), %rdi
callq 0x1a6a0
jmp 0x35f3f
movq 0x18(%rsp), %rdi
leaq 0x90(%rsp), %rsi
callq 0x361c0
jmp 0x35f53
leaq 0x90(%rsp), %rdi
callq 0x1aac0
leaq 0x8f(%rsp), %rdi
callq 0x14750
callq 0x14a80
jmp 0x3611d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xb8(%rsp)
movl %eax, 0xb4(%rsp)
jmp 0x35fae
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xb8(%rsp)
movl %eax, 0xb4(%rsp)
leaq 0x90(%rsp), %rdi
callq 0x1aac0
leaq 0x8f(%rsp), %rdi
callq 0x14750
jmp 0x35fd1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xb8(%rsp)
movl %eax, 0xb4(%rsp)
callq 0x14bb0
jmp 0x35fd8
jmp 0x36108
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xb8(%rsp)
movl %eax, 0xb4(%rsp)
jmp 0x360c0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xb8(%rsp)
movl %eax, 0xb4(%rsp)
leaq 0x60(%rsp), %rdi
callq 0x1aac0
jmp 0x360c0
movq 0x80(%rsp), %rdi
movq (%rdi), %rax
movq 0x10(%rax), %rax
callq *%rax
movq %rax, (%rsp)
leaq 0x27(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x14c90
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
leaq 0x28(%rsp), %rdi
callq 0x1a6a0
jmp 0x36052
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0x361c0
jmp 0x36063
leaq 0x28(%rsp), %rdi
callq 0x1aac0
leaq 0x27(%rsp), %rdi
callq 0x14750
jmp 0x360b9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xb8(%rsp)
movl %eax, 0xb4(%rsp)
jmp 0x360ad
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xb8(%rsp)
movl %eax, 0xb4(%rsp)
leaq 0x28(%rsp), %rdi
callq 0x1aac0
leaq 0x27(%rsp), %rdi
callq 0x14750
jmp 0x360c0
callq 0x14bb0
jmp 0x360c9
callq 0x14bb0
jmp 0x360c7
jmp 0x36108
jmp 0x360cb
leaq 0xd0(%rsp), %rdi
callq 0x3a840
jmp 0x35c7a
movq 0x18(%rsp), %rdi
movq 0xe0(%rsp), %rsi
callq 0x36410
testb $0x1, %al
jne 0x360f5
jmp 0x36100
movq 0x18(%rsp), %rdi
movq (%rdi), %rax
callq *0x20(%rax)
addq $0x1c8, %rsp # imm = 0x1C8
retq
movq 0xb8(%rsp), %rdi
callq 0x14c80
movq %rax, %rdi
callq 0x1b6b0
nopl (%rax)
|
_ZN6spdlog6logger8sink_it_ERKNS_7details7log_msgE:
sub rsp, 1C8h
mov [rsp+1C8h+var_E0], rdi
mov [rsp+1C8h+var_E8], rsi
mov rax, [rsp+1C8h+var_E0]
mov [rsp+1C8h+var_1B0], rax
add rax, 28h ; '('
mov [rsp+1C8h+var_F0], rax
mov rdi, [rsp+1C8h+var_F0]
call _ZNSt6vectorISt10shared_ptrIN6spdlog5sinks4sinkEESaIS4_EE5beginEv; std::vector<std::shared_ptr<spdlog::sinks::sink>>::begin(void)
mov [rsp+1C8h+var_F8], rax
mov rdi, [rsp+1C8h+var_F0]
call _ZNSt6vectorISt10shared_ptrIN6spdlog5sinks4sinkEESaIS4_EE3endEv; std::vector<std::shared_ptr<spdlog::sinks::sink>>::end(void)
mov [rsp+1C8h+var_100], rax
loc_35C7A:
lea rdi, [rsp+1C8h+var_F8]
lea rsi, [rsp+1C8h+var_100]
call _ZN9__gnu_cxxeqIPSt10shared_ptrIN6spdlog5sinks4sinkEESt6vectorIS5_SaIS5_EEEEbRKNS_17__normal_iteratorIT_T0_EESF_QrqXeqcldtfp_4baseEcldtfp0_4baseERSt14convertible_toIbEE
xor al, 0FFh
test al, 1
jnz short loc_35C9A
jmp loc_360DD
loc_35C9A:
lea rdi, [rsp+1C8h+var_F8]
call _ZNK9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN6spdlog5sinks4sinkEESt6vectorIS5_SaIS5_EEEdeEv; __gnu_cxx::__normal_iterator<std::shared_ptr<spdlog::sinks::sink> *,std::vector<std::shared_ptr<spdlog::sinks::sink>>>::operator*(void)
mov [rsp+1C8h+var_108], rax
mov rdi, [rsp+1C8h+var_108]
call _ZNKSt19__shared_ptr_accessIN6spdlog5sinks4sinkELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<spdlog::sinks::sink,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax
mov rax, [rsp+1C8h+var_E8]
mov esi, [rax+10h]
call _ZNK6spdlog5sinks4sink10should_logENS_5level10level_enumE; spdlog::sinks::sink::should_log(spdlog::level::level_enum)
test al, 1
jnz short loc_35CD8
jmp loc_360C9
loc_35CD8:
mov rdi, [rsp+1C8h+var_108]
call _ZNKSt19__shared_ptr_accessIN6spdlog5sinks4sinkELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<spdlog::sinks::sink,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void)
mov rdi, rax
mov rsi, [rsp+1C8h+var_E8]
mov rax, [rdi]
mov rax, [rax+10h]
call rax
jmp short $+2
loc_35CFB:
jmp loc_360BE
mov rcx, rax
mov eax, edx
mov [rsp+1C8h+var_110], rcx
mov [rsp+1C8h+var_114], eax
mov eax, [rsp+1C8h+var_114]
mov ecx, 2
cmp eax, ecx
jnz loc_35F05
mov rdi, [rsp+1C8h+var_110]; void *
call ___cxa_begin_catch
mov [rsp+1C8h+var_148], rax
mov rax, [rsp+1C8h+var_E8]
cmp qword ptr [rax+38h], 0
jz loc_36019
lea rax, asc_10C8D7; "{} [{}({})]"
mov [rsp+1C8h+var_178], rax
mov [rsp+1C8h+var_170], 0Bh
mov rdi, [rsp+1C8h+var_148]
mov rax, [rdi]
mov rax, [rax+10h]
call rax
mov [rsp+1C8h+var_180], rax
mov rax, [rsp+1C8h+var_E8]
mov rcx, rax
add rcx, 38h ; '8'
add rax, 40h ; '@'
mov rsi, [rsp+1C8h+var_178]
mov rdx, [rsp+1C8h+var_170]
lea rdi, [rsp+1C8h+var_168]
mov [rsp+1C8h+var_58], rdi
mov [rsp+1C8h+var_68], rsi
mov [rsp+1C8h+var_60], rdx
lea rdx, [rsp+1C8h+var_180]
mov [rsp+1C8h+var_70], rdx
mov [rsp+1C8h+var_78], rcx
mov [rsp+1C8h+var_80], rax
lea rax, [rsp+1C8h+var_68]
mov [rsp+1C8h+var_50], rax
mov rax, [rsp+1C8h+var_50]
movups xmm0, xmmword ptr [rax]
movaps [rsp+1C8h+var_48], xmm0
mov rcx, qword ptr [rsp+1C8h+var_48]
mov rax, qword ptr [rsp+1C8h+var_48+8]
mov [rsp+1C8h+var_90], rcx
mov [rsp+1C8h+var_88], rax
mov rsi, [rsp+1C8h+var_70]
mov rdx, [rsp+1C8h+var_78]
mov rcx, [rsp+1C8h+var_80]
lea rdi, [rsp+1C8h+var_D8]
call _ZN3fmt3v1016make_format_argsINS0_20basic_format_contextINS0_8appenderEcEEJPKcKS6_KiEEENS0_16format_arg_storeIT_JDpNSt9remove_cvINSt16remove_referenceIT0_E4typeEE4typeEEEEDpRSD_; fmt::v10::make_format_args<fmt::v10::basic_format_context<fmt::v10::appender,char>,char const*,char const* const,int const>(char const*,char const* const,int const&)
jmp short $+2
loc_35E3C:
lea rax, [rsp+1C8h+var_A0]
mov [rsp+1C8h+var_28], rax
lea rax, [rsp+1C8h+var_D8]
mov [rsp+1C8h+var_30], rax
mov rcx, [rsp+1C8h+var_28]
mov rax, [rsp+1C8h+var_30]
mov [rsp+1C8h+var_20], rax
mov rax, [rsp+1C8h+var_20]
mov [rsp+1C8h+var_8], rcx
mov [rsp+1C8h+var_10], 1CCh
mov [rsp+1C8h+var_18], rax
mov rax, [rsp+1C8h+var_8]
mov rcx, [rsp+1C8h+var_10]
mov [rax], rcx
mov rcx, [rsp+1C8h+var_18]
mov [rax+8], rcx
mov rsi, [rsp+1C8h+var_90]
mov rdx, [rsp+1C8h+var_88]
mov rcx, [rsp+1C8h+var_A0]
mov r8, [rsp+1C8h+var_98]
lea rdi, [rsp+1C8h+var_168]
call _ZN3fmt3v107vformatB5cxx11ENS0_17basic_string_viewIcEENS0_17basic_format_argsINS0_20basic_format_contextINS0_8appenderEcEEEE; fmt::v10::vformat(fmt::v10::basic_string_view<char>,fmt::v10::basic_format_args<fmt::v10::basic_format_context<fmt::v10::appender,char>>)
jmp short $+2
loc_35EE3:
jmp short $+2
loc_35EE5:
mov rdi, [rsp+1C8h+var_1B0]
lea rsi, [rsp+1C8h+var_168]
call _ZN6spdlog6logger12err_handler_ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; spdlog::logger::err_handler_(std::string const&)
jmp short $+2
loc_35EF6:
lea rdi, [rsp+1C8h+var_168]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp loc_360B9
loc_35F05:
mov rdi, [rsp+1C8h+var_110]; void *
call ___cxa_begin_catch
lea rdi, [rsp+1C8h+var_139]
mov [rsp+1C8h+var_1B8], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rsp+1C8h+var_1B8]
lea rsi, aRethrowingUnkn; "Rethrowing unknown exception in logger"
lea rdi, [rsp+1C8h+var_138]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_35F3F:
mov rdi, [rsp+1C8h+var_1B0]
lea rsi, [rsp+1C8h+var_138]
call _ZN6spdlog6logger12err_handler_ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; spdlog::logger::err_handler_(std::string const&)
jmp short $+2
loc_35F53:
lea rdi, [rsp+1C8h+var_138]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+1C8h+var_139]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
call ___cxa_rethrow
jmp loc_3611D
mov rcx, rax
mov eax, edx
mov [rsp+arg_B0], rcx
mov [rsp+arg_AC], eax
jmp short loc_35FAE
mov rcx, rax
mov eax, edx
mov [rsp+arg_B0], rcx
mov [rsp+arg_AC], eax
lea rdi, [rsp+arg_88]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_35FAE:
lea rdi, [rsp+arg_87]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_35FD1
mov rcx, rax
mov eax, edx
mov [rsp+arg_B0], rcx
mov [rsp+arg_AC], eax
loc_35FD1:
call ___cxa_end_catch
jmp short $+2
loc_35FD8:
jmp loc_36108
mov rcx, rax
mov eax, edx
mov [rsp+arg_B0], rcx
mov [rsp+arg_AC], eax
jmp loc_360C0
mov rcx, rax
mov eax, edx
mov [rsp+arg_B0], rcx
mov [rsp+arg_AC], eax
lea rdi, [rsp+arg_58]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp loc_360C0
loc_36019:
mov rdi, [rsp+1C8h+var_148]
mov rax, [rdi]
mov rax, [rax+10h]
call rax
mov [rsp+1C8h+var_1C8], rax
lea rdi, [rsp+1C8h+var_1A1]
mov [rsp+1C8h+var_1C0], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rsi, [rsp+1C8h+var_1C8]
mov rdx, [rsp+1C8h+var_1C0]
lea rdi, [rsp+1C8h+var_1A0]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_36052:
mov rdi, [rsp+1C8h+var_1B0]
lea rsi, [rsp+1C8h+var_1A0]
call _ZN6spdlog6logger12err_handler_ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; spdlog::logger::err_handler_(std::string const&)
jmp short $+2
loc_36063:
lea rdi, [rsp+1C8h+var_1A0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+1C8h+var_1A1]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_360B9
mov rcx, rax
mov eax, edx
mov [rsp+arg_B0], rcx
mov [rsp+arg_AC], eax
jmp short loc_360AD
mov rcx, rax
mov eax, edx
mov [rsp+arg_B0], rcx
mov [rsp+arg_AC], eax
lea rdi, [rsp+arg_20]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_360AD:
lea rdi, [rsp+arg_1F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_360C0
loc_360B9:
call ___cxa_end_catch
loc_360BE:
jmp short loc_360C9
loc_360C0:
call ___cxa_end_catch
jmp short $+2
loc_360C7:
jmp short loc_36108
loc_360C9:
jmp short $+2
loc_360CB:
lea rdi, [rsp+1C8h+var_F8]
call _ZN9__gnu_cxx17__normal_iteratorIPSt10shared_ptrIN6spdlog5sinks4sinkEESt6vectorIS5_SaIS5_EEEppEv; __gnu_cxx::__normal_iterator<std::shared_ptr<spdlog::sinks::sink> *,std::vector<std::shared_ptr<spdlog::sinks::sink>>>::operator++(void)
jmp loc_35C7A
loc_360DD:
mov rdi, [rsp+1C8h+var_1B0]
mov rsi, [rsp+1C8h+var_E8]
call _ZN6spdlog6logger13should_flush_ERKNS_7details7log_msgE; spdlog::logger::should_flush_(spdlog::details::log_msg const&)
test al, 1
jnz short loc_360F5
jmp short loc_36100
loc_360F5:
mov rdi, [rsp+1C8h+var_1B0]
mov rax, [rdi]
call qword ptr [rax+20h]
loc_36100:
add rsp, 1C8h
retn
loc_36108:
mov rdi, [rsp+arg_B0]
call __Unwind_Resume
mov rdi, rax
call __clang_call_terminate
loc_3611D:
nop dword ptr [rax]
|
long long spdlog::logger::sink_it_(spdlog::logger *this, const spdlog::details::log_msg *a2)
{
long long v2; // rax
long long v3; // rdi
long long result; // rax
long long v6; // [rsp+C0h] [rbp-108h]
long long v7; // [rsp+C8h] [rbp-100h] BYREF
_QWORD v8[2]; // [rsp+D0h] [rbp-F8h] BYREF
const spdlog::details::log_msg *v9; // [rsp+E0h] [rbp-E8h]
spdlog::logger *v10; // [rsp+E8h] [rbp-E0h]
v10 = this;
v9 = a2;
v8[1] = (char *)this + 40;
v8[0] = std::vector<std::shared_ptr<spdlog::sinks::sink>>::begin((char *)this + 40);
v7 = std::vector<std::shared_ptr<spdlog::sinks::sink>>::end((char *)this + 40);
while ( (__gnu_cxx::operator==<std::shared_ptr<spdlog::sinks::sink> *,std::vector<std::shared_ptr<spdlog::sinks::sink>>>(
v8,
&v7) & 1) == 0 )
{
v6 = __gnu_cxx::__normal_iterator<std::shared_ptr<spdlog::sinks::sink> *,std::vector<std::shared_ptr<spdlog::sinks::sink>>>::operator*(v8);
v2 = std::__shared_ptr_access<spdlog::sinks::sink,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v6);
if ( (spdlog::sinks::sink::should_log(v2, *((unsigned int *)v9 + 4)) & 1) != 0 )
{
v3 = std::__shared_ptr_access<spdlog::sinks::sink,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v6);
(*(void ( **)(long long, const spdlog::details::log_msg *))(*(_QWORD *)v3 + 16LL))(v3, v9);
}
__gnu_cxx::__normal_iterator<std::shared_ptr<spdlog::sinks::sink> *,std::vector<std::shared_ptr<spdlog::sinks::sink>>>::operator++(v8);
}
result = spdlog::logger::should_flush_(this, v9);
if ( (result & 1) != 0 )
return (*(long long ( **)(spdlog::logger *))(*(_QWORD *)this + 32LL))(this);
return result;
}
|
sink_it_:
SUB RSP,0x1c8
MOV qword ptr [RSP + 0xe8],RDI
MOV qword ptr [RSP + 0xe0],RSI
MOV RAX,qword ptr [RSP + 0xe8]
MOV qword ptr [RSP + 0x18],RAX
ADD RAX,0x28
MOV qword ptr [RSP + 0xd8],RAX
MOV RDI,qword ptr [RSP + 0xd8]
CALL 0x0013a720
MOV qword ptr [RSP + 0xd0],RAX
MOV RDI,qword ptr [RSP + 0xd8]
CALL 0x0013a790
MOV qword ptr [RSP + 0xc8],RAX
LAB_00135c7a:
LEA RDI,[RSP + 0xd0]
LEA RSI,[RSP + 0xc8]
CALL 0x0013a750
XOR AL,0xff
TEST AL,0x1
JNZ 0x00135c9a
JMP 0x001360dd
LAB_00135c9a:
LEA RDI,[RSP + 0xd0]
CALL 0x0013a7f0
MOV qword ptr [RSP + 0xc0],RAX
MOV RDI,qword ptr [RSP + 0xc0]
CALL 0x0013a800
MOV RDI,RAX
MOV RAX,qword ptr [RSP + 0xe0]
MOV ESI,dword ptr [RAX + 0x10]
CALL 0x00136120
TEST AL,0x1
JNZ 0x00135cd8
JMP 0x001360c9
LAB_00135cd8:
MOV RDI,qword ptr [RSP + 0xc0]
CALL 0x0013a800
MOV RDI,RAX
MOV RSI,qword ptr [RSP + 0xe0]
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX + 0x10]
LAB_00135cf7:
CALL RAX
LAB_00135cf9:
JMP 0x00135cfb
LAB_00135cfb:
JMP 0x001360be
LAB_001360be:
JMP 0x001360c9
LAB_001360c9:
JMP 0x001360cb
LAB_001360cb:
LEA RDI,[RSP + 0xd0]
CALL 0x0013a840
JMP 0x00135c7a
LAB_001360dd:
MOV RDI,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RSP + 0xe0]
CALL 0x00136410
TEST AL,0x1
JNZ 0x001360f5
JMP 0x00136100
LAB_001360f5:
MOV RDI,qword ptr [RSP + 0x18]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x20]
LAB_00136100:
ADD RSP,0x1c8
RET
|
/* spdlog::logger::sink_it_(spdlog::details::log_msg const&) */
void __thiscall spdlog::logger::sink_it_(logger *this,log_msg *param_1)
{
byte bVar1;
__shared_ptr_access<spdlog::sinks::sink,(__gnu_cxx::_Lock_policy)2,false,false> *this_00;
sink *psVar2;
long *plVar3;
ulong uVar4;
int8 local_100;
int8 local_f8;
vector<std::shared_ptr<spdlog::sinks::sink>,std::allocator<std::shared_ptr<spdlog::sinks::sink>>>
*local_f0;
log_msg *local_e8;
logger *local_e0;
local_f0 = (vector<std::shared_ptr<spdlog::sinks::sink>,std::allocator<std::shared_ptr<spdlog::sinks::sink>>>
*)(this + 0x28);
local_e8 = param_1;
local_e0 = this;
local_f8 = std::
vector<std::shared_ptr<spdlog::sinks::sink>,std::allocator<std::shared_ptr<spdlog::sinks::sink>>>
::begin(local_f0);
local_100 = std::
vector<std::shared_ptr<spdlog::sinks::sink>,std::allocator<std::shared_ptr<spdlog::sinks::sink>>>
::end(local_f0);
while (bVar1 = _ZN9__gnu_cxxeqIPSt10shared_ptrIN6spdlog5sinks4sinkEESt6vectorIS5_SaIS5_EEEEbRKNS_17__normal_iteratorIT_T0_EESF_QrqXeqcldtfp_4baseEcldtfp0_4baseERSt14convertible_toIbEE
(&local_f8,&local_100), ((bVar1 ^ 0xff) & 1) != 0) {
this_00 = (__shared_ptr_access<spdlog::sinks::sink,(__gnu_cxx::_Lock_policy)2,false,false> *)
__gnu_cxx::
__normal_iterator<std::shared_ptr<spdlog::sinks::sink>*,std::vector<std::shared_ptr<spdlog::sinks::sink>,std::allocator<std::shared_ptr<spdlog::sinks::sink>>>>
::operator*((__normal_iterator<std::shared_ptr<spdlog::sinks::sink>*,std::vector<std::shared_ptr<spdlog::sinks::sink>,std::allocator<std::shared_ptr<spdlog::sinks::sink>>>>
*)&local_f8);
psVar2 = (sink *)std::
__shared_ptr_access<spdlog::sinks::sink,(__gnu_cxx::_Lock_policy)2,false,false>
::operator->(this_00);
uVar4 = spdlog::sinks::sink::should_log(psVar2,*(int4 *)(local_e8 + 0x10));
if ((uVar4 & 1) != 0) {
plVar3 = (long *)std::
__shared_ptr_access<spdlog::sinks::sink,(__gnu_cxx::_Lock_policy)2,false,false>
::operator->(this_00);
/* try { // try from 00135cf7 to 00135cf8 has its CatchHandler @ 00135d00 */
(**(code **)(*plVar3 + 0x10))(plVar3,local_e8);
}
__gnu_cxx::
__normal_iterator<std::shared_ptr<spdlog::sinks::sink>*,std::vector<std::shared_ptr<spdlog::sinks::sink>,std::allocator<std::shared_ptr<spdlog::sinks::sink>>>>
::operator++((__normal_iterator<std::shared_ptr<spdlog::sinks::sink>*,std::vector<std::shared_ptr<spdlog::sinks::sink>,std::allocator<std::shared_ptr<spdlog::sinks::sink>>>>
*)&local_f8);
}
uVar4 = should_flush_(this,local_e8);
if ((uVar4 & 1) != 0) {
(**(code **)(*(long *)this + 0x20))();
}
return;
}
|
|
19,945
|
js_string_obj_get_length
|
bluesky950520[P]quickjs/quickjs.c
|
static uint32_t js_string_obj_get_length(JSContext *ctx,
JSValue obj)
{
JSObject *p;
JSString *p1;
uint32_t len = 0;
/* This is a class exotic method: obj class_id is JS_CLASS_STRING */
p = JS_VALUE_GET_OBJ(obj);
if (JS_VALUE_GET_TAG(p->u.object_data) == JS_TAG_STRING) {
p1 = JS_VALUE_GET_STRING(p->u.object_data);
len = p1->len;
}
return len;
}
|
O0
|
c
|
js_string_obj_get_length:
movq %rsi, -0x10(%rsp)
movq %rdx, -0x8(%rsp)
movq %rdi, -0x18(%rsp)
movl $0x0, -0x2c(%rsp)
movq -0x10(%rsp), %rax
movq %rax, -0x20(%rsp)
movq -0x20(%rsp), %rax
movq 0x38(%rax), %rax
cmpl $-0x7, %eax
jne 0x5f730
movq -0x20(%rsp), %rax
movq 0x30(%rax), %rax
movq %rax, -0x28(%rsp)
movq -0x28(%rsp), %rax
movq 0x4(%rax), %rax
andq $0x7fffffff, %rax # imm = 0x7FFFFFFF
movl %eax, -0x2c(%rsp)
movl -0x2c(%rsp), %eax
retq
nopw %cs:(%rax,%rax)
|
js_string_obj_get_length:
mov [rsp+var_10], rsi
mov [rsp+var_8], rdx
mov [rsp+var_18], rdi
mov [rsp+var_2C], 0
mov rax, [rsp+var_10]
mov [rsp+var_20], rax
mov rax, [rsp+var_20]
mov rax, [rax+38h]
cmp eax, 0FFFFFFF9h
jnz short loc_5F730
mov rax, [rsp+var_20]
mov rax, [rax+30h]
mov [rsp+var_28], rax
mov rax, [rsp+var_28]
mov rax, [rax+4]
and rax, 7FFFFFFFh
mov [rsp+var_2C], eax
loc_5F730:
mov eax, [rsp+var_2C]
retn
|
long long js_string_obj_get_length(long long a1, long long a2)
{
unsigned int v3; // [rsp+0h] [rbp-2Ch]
v3 = 0;
if ( (unsigned int)*(_QWORD *)(a2 + 56) == -7 )
return *(_DWORD *)(*(_QWORD *)(a2 + 48) + 4LL) & 0x7FFFFFFF;
return v3;
}
|
js_string_obj_get_length:
MOV qword ptr [RSP + -0x10],RSI
MOV qword ptr [RSP + -0x8],RDX
MOV qword ptr [RSP + -0x18],RDI
MOV dword ptr [RSP + -0x2c],0x0
MOV RAX,qword ptr [RSP + -0x10]
MOV qword ptr [RSP + -0x20],RAX
MOV RAX,qword ptr [RSP + -0x20]
MOV RAX,qword ptr [RAX + 0x38]
CMP EAX,-0x7
JNZ 0x0015f730
MOV RAX,qword ptr [RSP + -0x20]
MOV RAX,qword ptr [RAX + 0x30]
MOV qword ptr [RSP + -0x28],RAX
MOV RAX,qword ptr [RSP + -0x28]
MOV RAX,qword ptr [RAX + 0x4]
AND RAX,0x7fffffff
MOV dword ptr [RSP + -0x2c],EAX
LAB_0015f730:
MOV EAX,dword ptr [RSP + -0x2c]
RET
|
uint js_string_obj_get_length(int8 param_1,long param_2)
{
int4 local_2c;
local_2c = 0;
if ((int)*(int8 *)(param_2 + 0x38) == -7) {
local_2c = (uint)*(int8 *)(*(long *)(param_2 + 0x30) + 4) & 0x7fffffff;
}
return local_2c;
}
|
|
19,946
|
ggml_init
|
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
|
struct ggml_context * ggml_init(struct ggml_init_params params) {
static bool is_first_call = true;
ggml_critical_section_start();
if (is_first_call) {
// initialize time system (required on Windows)
ggml_time_init();
for (int i = 0; i < (1 << 16); ++i) {
union {
uint16_t u16;
ggml_fp16_t fp16;
} u = {i};
ggml_table_f32_f16[i] = GGML_COMPUTE_FP16_TO_FP32(u.fp16);
}
is_first_call = false;
}
ggml_critical_section_end();
struct ggml_context * ctx = GGML_MALLOC(sizeof(struct ggml_context));
// allow to call ggml_init with 0 size
if (params.mem_size == 0) {
params.mem_size = GGML_MEM_ALIGN;
}
const size_t mem_size = params.mem_buffer ? params.mem_size : GGML_PAD(params.mem_size, GGML_MEM_ALIGN);
*ctx = (struct ggml_context) {
/*.mem_size =*/ mem_size,
/*.mem_buffer =*/ params.mem_buffer ? params.mem_buffer : ggml_aligned_malloc(mem_size),
/*.mem_buffer_owned =*/ params.mem_buffer ? false : true,
/*.no_alloc =*/ params.no_alloc,
/*.n_objects =*/ 0,
/*.objects_begin =*/ NULL,
/*.objects_end =*/ NULL,
};
GGML_ASSERT(ctx->mem_buffer != NULL);
GGML_ASSERT_ALIGNED(ctx->mem_buffer);
GGML_PRINT_DEBUG("%s: context initialized\n", __func__);
return ctx;
}
|
O0
|
c
|
ggml_init:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
leaq 0x10(%rbp), %rax
movq %rax, -0x48(%rbp)
callq 0x48ea0
testb $0x1, 0x98be4(%rip) # 0xe4590
je 0x4b9f5
callq 0x429b0
movl $0x0, -0x4(%rbp)
cmpl $0x10000, -0x4(%rbp) # imm = 0x10000
jge 0x4b9ee
movl -0x4(%rbp), %eax
movw %ax, -0x6(%rbp)
movzwl -0x6(%rbp), %edi
callq 0x4bb60
movslq -0x4(%rbp), %rcx
movq 0x945d2(%rip), %rax # 0xdffb0
movss %xmm0, (%rax,%rcx,4)
movl -0x4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4(%rbp)
jmp 0x4b9ba
movb $0x0, 0x98b9b(%rip) # 0xe4590
callq 0x48750
movl $0x28, %edi
callq 0x4bc50
movq %rax, %rcx
movq -0x48(%rbp), %rax
movq %rcx, -0x10(%rbp)
cmpq $0x0, (%rax)
jne 0x4ba20
movq -0x48(%rbp), %rax
movq $0x10, (%rax)
movq -0x48(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x4ba38
movq -0x48(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x50(%rbp)
jmp 0x4ba4f
movq -0x48(%rbp), %rax
movq (%rax), %rax
addq $0x10, %rax
subq $0x1, %rax
andq $-0x10, %rax
movq %rax, -0x50(%rbp)
movq -0x48(%rbp), %rax
movq -0x50(%rbp), %rcx
movq %rcx, -0x18(%rbp)
movq -0x10(%rbp), %rcx
movq %rcx, -0x60(%rbp)
movq -0x18(%rbp), %rcx
movq %rcx, -0x40(%rbp)
leaq -0x40(%rbp), %rcx
addq $0x8, %rcx
movq %rcx, -0x58(%rbp)
cmpq $0x0, 0x8(%rax)
je 0x4ba8c
movq -0x48(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x68(%rbp)
jmp 0x4ba99
movq -0x18(%rbp), %rdi
callq 0x43ec0
movq %rax, -0x68(%rbp)
movq -0x60(%rbp), %rdi
movq -0x48(%rbp), %rax
movq -0x58(%rbp), %rcx
movq -0x68(%rbp), %rdx
movq %rdx, (%rcx)
movq 0x8(%rax), %rsi
movl $0x1, %ecx
xorl %edx, %edx
cmpq $0x0, %rsi
cmovnel %edx, %ecx
cmpl $0x0, %ecx
setne %cl
andb $0x1, %cl
movb %cl, -0x30(%rbp)
movb 0x10(%rax), %al
andb $0x1, %al
movb %al, -0x2f(%rbp)
movl $0x0, -0x2c(%rbp)
movq $0x0, -0x28(%rbp)
movq $0x0, -0x20(%rbp)
leaq -0x40(%rbp), %rsi
movl $0x28, %edx
callq 0x453f0
movq -0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x4bb23
leaq 0x65aae(%rip), %rdi # 0xb15b7
movl $0x5a2, %esi # imm = 0x5A2
leaq 0x65af4(%rip), %rdx # 0xb1609
leaq 0x65bef(%rip), %rcx # 0xb170b
movb $0x0, %al
callq 0x48a00
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
andq $0xf, %rax
cmpq $0x0, %rax
je 0x4bb56
leaq 0x65a7b(%rip), %rdi # 0xb15b7
movl $0x5a4, %esi # imm = 0x5A4
leaq 0x65ac1(%rip), %rdx # 0xb1609
leaq 0x65bd4(%rip), %rcx # 0xb1723
movb $0x0, %al
callq 0x48a00
movq -0x10(%rbp), %rax
addq $0x70, %rsp
popq %rbp
retq
|
ggml_init:
push rbp
mov rbp, rsp
sub rsp, 70h
lea rax, [rbp+arg_0]
mov [rbp+var_48], rax
call _ggml_critical_section_start
test cs:ggml_init_is_first_call, 1
jz short loc_4B9F5
call _ggml_time_init
mov [rbp+var_4], 0
loc_4B9BA:
cmp [rbp+var_4], 10000h
jge short loc_4B9EE
mov eax, [rbp+var_4]
mov [rbp+var_6], ax
movzx edi, [rbp+var_6]
call ggml_compute_fp16_to_fp32
movsxd rcx, [rbp+var_4]
mov rax, cs:ggml_table_f32_f16_ptr
movss dword ptr [rax+rcx*4], xmm0
mov eax, [rbp+var_4]
add eax, 1
mov [rbp+var_4], eax
jmp short loc_4B9BA
loc_4B9EE:
mov cs:ggml_init_is_first_call, 0
loc_4B9F5:
call _ggml_critical_section_end
mov edi, 28h ; '('
call ggml_malloc
mov rcx, rax
mov rax, [rbp+var_48]
mov [rbp+var_10], rcx
cmp qword ptr [rax], 0
jnz short loc_4BA20
mov rax, [rbp+var_48]
mov qword ptr [rax], 10h
loc_4BA20:
mov rax, [rbp+var_48]
cmp qword ptr [rax+8], 0
jz short loc_4BA38
mov rax, [rbp+var_48]
mov rax, [rax]
mov [rbp+var_50], rax
jmp short loc_4BA4F
loc_4BA38:
mov rax, [rbp+var_48]
mov rax, [rax]
add rax, 10h
sub rax, 1
and rax, 0FFFFFFFFFFFFFFF0h
mov [rbp+var_50], rax
loc_4BA4F:
mov rax, [rbp+var_48]
mov rcx, [rbp+var_50]
mov [rbp+var_18], rcx
mov rcx, [rbp+var_10]
mov [rbp+var_60], rcx
mov rcx, [rbp+var_18]
mov [rbp+var_40], rcx
lea rcx, [rbp+var_40]
add rcx, 8
mov [rbp+var_58], rcx
cmp qword ptr [rax+8], 0
jz short loc_4BA8C
mov rax, [rbp+var_48]
mov rax, [rax+8]
mov [rbp+var_68], rax
jmp short loc_4BA99
loc_4BA8C:
mov rdi, [rbp+var_18]
call _ggml_aligned_malloc
mov [rbp+var_68], rax
loc_4BA99:
mov rdi, [rbp+var_60]
mov rax, [rbp+var_48]
mov rcx, [rbp+var_58]
mov rdx, [rbp+var_68]
mov [rcx], rdx
mov rsi, [rax+8]
mov ecx, 1
xor edx, edx
cmp rsi, 0
cmovnz ecx, edx
cmp ecx, 0
setnz cl
and cl, 1
mov [rbp+var_30], cl
mov al, [rax+10h]
and al, 1
mov [rbp+var_2F], al
mov [rbp+var_2C], 0
mov [rbp+var_28], 0
mov [rbp+var_20], 0
lea rsi, [rbp+var_40]
mov edx, 28h ; '('
call _memcpy
mov rax, [rbp+var_10]
cmp qword ptr [rax+8], 0
jnz short loc_4BB23
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
mov esi, 5A2h
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aCtxMemBufferNu; "ctx->mem_buffer != NULL"
mov al, 0
call _ggml_abort
loc_4BB23:
mov rax, [rbp+var_10]
mov rax, [rax+8]
and rax, 0Fh
cmp rax, 0
jz short loc_4BB56
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
mov esi, 5A4h
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aUintptrTCtxMem; "((uintptr_t) (ctx->mem_buffer))%GGML_ME"...
mov al, 0
call _ggml_abort
loc_4BB56:
mov rax, [rbp+var_10]
add rsp, 70h
pop rbp
retn
|
long long ggml_init(
long long a1,
long long a2,
long long a3,
long long a4,
long long a5,
long long a6,
long long a7,
long long a8,
char a9)
{
long long v10; // [rsp+8h] [rbp-68h]
unsigned long long v11; // [rsp+20h] [rbp-50h]
_QWORD v12[2]; // [rsp+30h] [rbp-40h] BYREF
bool v13; // [rsp+40h] [rbp-30h]
char v14; // [rsp+41h] [rbp-2Fh]
int v15; // [rsp+44h] [rbp-2Ch]
long long v16; // [rsp+48h] [rbp-28h]
long long v17; // [rsp+50h] [rbp-20h]
unsigned long long v18; // [rsp+58h] [rbp-18h]
long long v19; // [rsp+60h] [rbp-10h]
__int16 v20; // [rsp+6Ah] [rbp-6h]
int i; // [rsp+6Ch] [rbp-4h]
ggml_critical_section_start();
if ( (ggml_init_is_first_call & 1) != 0 )
{
ggml_time_init();
for ( i = 0; i < 0x10000; ++i )
{
v20 = i;
ggml_table_f32_f16[i] = ggml_compute_fp16_to_fp32((unsigned __int16)i);
}
ggml_init_is_first_call = 0;
}
ggml_critical_section_end();
v19 = ggml_malloc(40LL);
if ( !a7 )
a7 = 16LL;
if ( a8 )
v11 = a7;
else
v11 = (a7 + 15) & 0xFFFFFFFFFFFFFFF0LL;
v18 = v11;
v12[0] = v11;
if ( a8 )
v10 = a8;
else
v10 = ggml_aligned_malloc(v18);
v12[1] = v10;
v13 = a8 == 0;
v14 = a9 & 1;
v15 = 0;
v16 = 0LL;
v17 = 0LL;
memcpy(v19, v12, 40LL);
if ( !*(_QWORD *)(v19 + 8) )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
1442,
(long long)"GGML_ASSERT(%s) failed",
"ctx->mem_buffer != NULL");
if ( (*(_QWORD *)(v19 + 8) & 0xFLL) != 0 )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
1444,
(long long)"GGML_ASSERT(%s) failed",
"((uintptr_t) (ctx->mem_buffer))%GGML_MEM_ALIGN == 0");
return v19;
}
|
ggml_init:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x70
LEA RAX,[RBP + 0x10]
MOV qword ptr [RBP + -0x48],RAX
CALL 0x00148ea0
TEST byte ptr [0x001e4590],0x1
JZ 0x0014b9f5
CALL 0x001429b0
MOV dword ptr [RBP + -0x4],0x0
LAB_0014b9ba:
CMP dword ptr [RBP + -0x4],0x10000
JGE 0x0014b9ee
MOV EAX,dword ptr [RBP + -0x4]
MOV word ptr [RBP + -0x6],AX
MOVZX EDI,word ptr [RBP + -0x6]
CALL 0x0014bb60
MOVSXD RCX,dword ptr [RBP + -0x4]
MOV RAX,qword ptr [0x001dffb0]
MOVSS dword ptr [RAX + RCX*0x4],XMM0
MOV EAX,dword ptr [RBP + -0x4]
ADD EAX,0x1
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014b9ba
LAB_0014b9ee:
MOV byte ptr [0x001e4590],0x0
LAB_0014b9f5:
CALL 0x00148750
MOV EDI,0x28
CALL 0x0014bc50
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RBP + -0x10],RCX
CMP qword ptr [RAX],0x0
JNZ 0x0014ba20
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RAX],0x10
LAB_0014ba20:
MOV RAX,qword ptr [RBP + -0x48]
CMP qword ptr [RAX + 0x8],0x0
JZ 0x0014ba38
MOV RAX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x50],RAX
JMP 0x0014ba4f
LAB_0014ba38:
MOV RAX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RAX]
ADD RAX,0x10
SUB RAX,0x1
AND RAX,-0x10
MOV qword ptr [RBP + -0x50],RAX
LAB_0014ba4f:
MOV RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x18],RCX
MOV RCX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x60],RCX
MOV RCX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x40],RCX
LEA RCX,[RBP + -0x40]
ADD RCX,0x8
MOV qword ptr [RBP + -0x58],RCX
CMP qword ptr [RAX + 0x8],0x0
JZ 0x0014ba8c
MOV RAX,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x68],RAX
JMP 0x0014ba99
LAB_0014ba8c:
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00143ec0
MOV qword ptr [RBP + -0x68],RAX
LAB_0014ba99:
MOV RDI,qword ptr [RBP + -0x60]
MOV RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x58]
MOV RDX,qword ptr [RBP + -0x68]
MOV qword ptr [RCX],RDX
MOV RSI,qword ptr [RAX + 0x8]
MOV ECX,0x1
XOR EDX,EDX
CMP RSI,0x0
CMOVNZ ECX,EDX
CMP ECX,0x0
SETNZ CL
AND CL,0x1
MOV byte ptr [RBP + -0x30],CL
MOV AL,byte ptr [RAX + 0x10]
AND AL,0x1
MOV byte ptr [RBP + -0x2f],AL
MOV dword ptr [RBP + -0x2c],0x0
MOV qword ptr [RBP + -0x28],0x0
MOV qword ptr [RBP + -0x20],0x0
LEA RSI,[RBP + -0x40]
MOV EDX,0x28
CALL 0x001453f0
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x8],0x0
JNZ 0x0014bb23
LEA RDI,[0x1b15b7]
MOV ESI,0x5a2
LEA RDX,[0x1b1609]
LEA RCX,[0x1b170b]
MOV AL,0x0
CALL 0x00148a00
LAB_0014bb23:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
AND RAX,0xf
CMP RAX,0x0
JZ 0x0014bb56
LEA RDI,[0x1b15b7]
MOV ESI,0x5a4
LEA RDX,[0x1b1609]
LEA RCX,[0x1b1723]
MOV AL,0x0
CALL 0x00148a00
LAB_0014bb56:
MOV RAX,qword ptr [RBP + -0x10]
ADD RSP,0x70
POP RBP
RET
|
void * ggml_init(void)
{
void *__dest;
int4 uVar1;
ulong in_stack_00000008;
long in_stack_00000010;
byte in_stack_00000018;
long local_70;
ulong local_58;
ulong local_48;
long local_40;
int1 local_38;
byte local_37;
int4 local_34;
int8 local_30;
int8 local_28;
ulong local_20;
void *local_18;
int2 local_e;
int local_c;
ggml_critical_section_start();
if ((ggml_init_is_first_call & 1) != 0) {
ggml_time_init();
for (local_c = 0; local_c < 0x10000; local_c = local_c + 1) {
local_e = (int2)local_c;
uVar1 = ggml_compute_fp16_to_fp32(local_e);
*(int4 *)(PTR_ggml_table_f32_f16_001dffb0 + (long)local_c * 4) = uVar1;
}
ggml_init_is_first_call = 0;
}
ggml_critical_section_end();
__dest = (void *)ggml_malloc(0x28);
if (in_stack_00000008 == 0) {
in_stack_00000008 = 0x10;
}
if (in_stack_00000010 == 0) {
local_58 = in_stack_00000008 + 0xf & 0xfffffffffffffff0;
}
else {
local_58 = in_stack_00000008;
}
local_20 = local_58;
local_48 = local_58;
local_18 = __dest;
if (in_stack_00000010 == 0) {
local_70 = ggml_aligned_malloc(local_58);
}
else {
local_70 = in_stack_00000010;
}
local_40 = local_70;
local_38 = in_stack_00000010 == 0;
local_37 = in_stack_00000018 & 1;
local_34 = 0;
local_30 = 0;
local_28 = 0;
memcpy(__dest,&local_48,0x28);
if (*(long *)((long)local_18 + 8) == 0) {
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
0x5a2,"GGML_ASSERT(%s) failed","ctx->mem_buffer != NULL");
}
if ((*(ulong *)((long)local_18 + 8) & 0xf) != 0) {
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
0x5a4,"GGML_ASSERT(%s) failed","((uintptr_t) (ctx->mem_buffer))%GGML_MEM_ALIGN == 0")
;
}
return local_18;
}
|
|
19,947
|
ggml_init
|
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
|
struct ggml_context * ggml_init(struct ggml_init_params params) {
static bool is_first_call = true;
ggml_critical_section_start();
if (is_first_call) {
// initialize time system (required on Windows)
ggml_time_init();
for (int i = 0; i < (1 << 16); ++i) {
union {
uint16_t u16;
ggml_fp16_t fp16;
} u = {i};
ggml_table_f32_f16[i] = GGML_COMPUTE_FP16_TO_FP32(u.fp16);
}
is_first_call = false;
}
ggml_critical_section_end();
struct ggml_context * ctx = GGML_MALLOC(sizeof(struct ggml_context));
// allow to call ggml_init with 0 size
if (params.mem_size == 0) {
params.mem_size = GGML_MEM_ALIGN;
}
const size_t mem_size = params.mem_buffer ? params.mem_size : GGML_PAD(params.mem_size, GGML_MEM_ALIGN);
*ctx = (struct ggml_context) {
/*.mem_size =*/ mem_size,
/*.mem_buffer =*/ params.mem_buffer ? params.mem_buffer : ggml_aligned_malloc(mem_size),
/*.mem_buffer_owned =*/ params.mem_buffer ? false : true,
/*.no_alloc =*/ params.no_alloc,
/*.n_objects =*/ 0,
/*.objects_begin =*/ NULL,
/*.objects_end =*/ NULL,
};
GGML_ASSERT(ctx->mem_buffer != NULL);
GGML_ASSERT_ALIGNED(ctx->mem_buffer);
GGML_PRINT_DEBUG("%s: context initialized\n", __func__);
return ctx;
}
|
O1
|
c
|
ggml_init:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
callq 0x18e20
cmpb $0x0, 0x53c28(%rip) # 0x6f200
jne 0x1b661
xorl %eax, %eax
movss 0x30a68(%rip), %xmm0 # 0x4c050
movss 0x30a64(%rip), %xmm1 # 0x4c054
movq 0x529b1(%rip), %rcx # 0x6dfa8
xorl %edx, %edx
xorl %esi, %esi
movl %eax, %edi
shrl $0x4, %edi
orl $0x70000000, %edi # imm = 0x70000000
movd %edi, %xmm2
movl %esi, %edi
andl $0x7fff, %edi # imm = 0x7FFF
orl $0x3f000000, %edi # imm = 0x3F000000
movd %edi, %xmm3
addss %xmm0, %xmm3
mulss %xmm1, %xmm2
cmpl $0x8000000, %eax # imm = 0x8000000
jb 0x1b62e
movaps %xmm2, %xmm3
movd %xmm3, %edi
movl %edx, %r8d
andl $0x80000000, %r8d # imm = 0x80000000
orl %edi, %r8d
movl %r8d, (%rcx,%rsi,4)
incq %rsi
addl $0x10000, %edx # imm = 0x10000
addl $0x20000, %eax # imm = 0x20000
cmpq $0x10000, %rsi # imm = 0x10000
jne 0x1b5fb
movb $0x1, 0x53b9f(%rip) # 0x6f200
callq 0x18c10
movl $0x28, %edi
callq 0x18650
testq %rax, %rax
je 0x1b6e8
movq %rax, %rbx
leaq 0x30(%rsp), %r15
cmpq $0x0, (%r15)
jne 0x1b68a
movq $0x10, (%r15)
movq (%r15), %rcx
movq 0x8(%r15), %r12
leaq 0xf(%rcx), %r14
andq $-0x10, %r14
movq %r12, %rax
testq %r12, %r12
cmovneq %rcx, %r14
jne 0x1b6ad
movq %r14, %rdi
callq 0x17880
testq %r12, %r12
movb 0x10(%r15), %cl
movq %r14, (%rbx)
movq %rax, 0x8(%rbx)
sete 0x10(%rbx)
movb %cl, 0x11(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x14(%rbx)
movl $0x0, 0x24(%rbx)
testq %rax, %rax
je 0x1b724
testb $0xf, %al
jne 0x1b740
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x32e29(%rip), %rsi # 0x4e518
leaq 0x32e43(%rip), %rdx # 0x4e539
movsd 0x3093a(%rip), %xmm0 # 0x4c038
movl $0x4, %edi
movb $0x1, %al
callq 0x17810
leaq 0x30e5e(%rip), %rdi # 0x4c56f
leaq 0x32e2d(%rip), %rdx # 0x4e545
movl $0x13c, %esi # imm = 0x13C
xorl %eax, %eax
callq 0x18ce0
leaq 0x30e44(%rip), %rdi # 0x4c56f
leaq 0x30e8f(%rip), %rdx # 0x4c5c1
leaq 0x30f8a(%rip), %rcx # 0x4c6c3
movl $0x5a2, %esi # imm = 0x5A2
jmp 0x1b75a
leaq 0x30e28(%rip), %rdi # 0x4c56f
leaq 0x30e73(%rip), %rdx # 0x4c5c1
leaq 0x30f86(%rip), %rcx # 0x4c6db
movl $0x5a4, %esi # imm = 0x5A4
xorl %eax, %eax
callq 0x18ce0
|
ggml_init:
push r15
push r14
push r12
push rbx
push rax
call _ggml_critical_section_start
cmp cs:ggml_init_is_first_call, 0
jnz loc_1B661
xor eax, eax
movss xmm0, cs:dword_4C050
movss xmm1, cs:dword_4C054
mov rcx, cs:ggml_table_f32_f16_ptr
xor edx, edx
xor esi, esi
loc_1B5FB:
mov edi, eax
shr edi, 4
or edi, 70000000h
movd xmm2, edi
mov edi, esi
and edi, 7FFFh
or edi, 3F000000h
movd xmm3, edi
addss xmm3, xmm0
mulss xmm2, xmm1
cmp eax, 8000000h
jb short loc_1B62E
movaps xmm3, xmm2
loc_1B62E:
movd edi, xmm3
mov r8d, edx
and r8d, 80000000h
or r8d, edi
mov [rcx+rsi*4], r8d
inc rsi
add edx, 10000h
add eax, 20000h
cmp rsi, 10000h
jnz short loc_1B5FB
mov cs:ggml_init_is_first_call, 1
loc_1B661:
call _ggml_critical_section_end
mov edi, 28h ; '('
call _malloc
test rax, rax
jz short loc_1B6E8
mov rbx, rax
lea r15, [rsp+28h+arg_0]
cmp qword ptr [r15], 0
jnz short loc_1B68A
mov qword ptr [r15], 10h
loc_1B68A:
mov rcx, [r15]
mov r12, [r15+8]
lea r14, [rcx+0Fh]
and r14, 0FFFFFFFFFFFFFFF0h
mov rax, r12
test r12, r12
cmovnz r14, rcx
jnz short loc_1B6AD
mov rdi, r14
call _ggml_aligned_malloc
loc_1B6AD:
test r12, r12
mov cl, [r15+10h]
mov [rbx], r14
mov [rbx+8], rax
setz byte ptr [rbx+10h]
mov [rbx+11h], cl
xorps xmm0, xmm0
movups xmmword ptr [rbx+14h], xmm0
mov dword ptr [rbx+24h], 0
test rax, rax
jz short loc_1B724
test al, 0Fh
jnz short loc_1B740
mov rax, rbx
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
loc_1B6E8:
lea rsi, aSFailedToAlloc; "%s: failed to allocate %6.2f MB\n"
lea rdx, aGgmlMalloc; "ggml_malloc"
movsd xmm0, cs:qword_4C038
mov edi, 4
mov al, 1
call _ggml_log_internal
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aFatalError; "fatal error"
mov esi, 13Ch
xor eax, eax
call _ggml_abort
loc_1B724:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aCtxMemBufferNu; "ctx->mem_buffer != NULL"
mov esi, 5A2h
jmp short loc_1B75A
loc_1B740:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aUintptrTCtxMem; "((uintptr_t) (ctx->mem_buffer))%GGML_ME"...
mov esi, 5A4h
loc_1B75A:
xor eax, eax
call _ggml_abort
|
long long ggml_init(
long long a1,
long long i,
__m128 a3,
__m128 a4,
__m128 a5,
__m128i a6,
double a7,
double a8,
__m128 a9,
__m128 a10,
long long a11,
long long a12,
long long a13,
long long a14,
long long a15,
long long a16,
char a17)
{
unsigned int v17; // eax
int v18; // edx
long long v19; // rax
long long v20; // rdx
long long v21; // rcx
long long v22; // r8
long long v23; // r9
__m128 v24; // xmm4
__m128 v25; // xmm5
long long v26; // rbx
unsigned long long v27; // r14
long long v28; // rax
int v30; // ecx
int v31; // r8d
int v32; // r9d
const char *v33; // rcx
int v34; // esi
ggml_critical_section_start(a1);
if ( !ggml_init_is_first_call )
{
v17 = 0;
a3 = (__m128)0xBF000000;
a4 = (__m128)0x7800000u;
v18 = 0;
for ( i = 0LL; i != 0x10000; ++i )
{
a5 = (__m128)_mm_cvtsi32_si128((v17 >> 4) | 0x70000000);
a6 = _mm_cvtsi32_si128(i & 0x7FFF | 0x3F000000);
*(float *)a6.m128i_i32 = *(float *)a6.m128i_i32 + -0.5;
a5.m128_f32[0] = a5.m128_f32[0] * 1.9259299e-34;
if ( v17 >= 0x8000000 )
a6 = (__m128i)a5;
LODWORD(ggml_table_f32_f16[i]) = _mm_cvtsi128_si32(a6) | v18 & 0x80000000;
v18 += 0x10000;
v17 += 0x20000;
}
ggml_init_is_first_call = 1;
}
ggml_critical_section_end();
v19 = malloc(40LL);
if ( !v19 )
{
ggml_log_internal(
4u,
(long long)"%s: failed to allocate %6.2f MB\n",
(long long)"ggml_malloc",
v21,
v22,
v23,
(__m128)0x3F04000000000000uLL,
a4,
a5,
(__m128)a6,
v24,
v25,
a9,
a10);
ggml_abort(
(unsigned int)"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
316,
(unsigned int)"fatal error",
v30,
v31,
v32);
}
v26 = v19;
if ( !a15 )
a15 = 16LL;
v27 = (a15 + 15) & 0xFFFFFFFFFFFFFFF0LL;
v28 = a16;
if ( a16 )
v27 = a15;
else
v28 = ggml_aligned_malloc(
(a15 + 15) & 0xFFFFFFFFFFFFFFF0LL,
a3,
a4,
a5,
(__m128)a6,
v24,
v25,
a9,
a10,
i,
v20,
a15,
v22,
v23);
*(_QWORD *)v26 = v27;
*(_QWORD *)(v26 + 8) = v28;
*(_BYTE *)(v26 + 16) = a16 == 0;
*(_BYTE *)(v26 + 17) = a17;
*(_OWORD *)(v26 + 20) = 0LL;
*(_DWORD *)(v26 + 36) = 0;
if ( !v28 )
{
v33 = "ctx->mem_buffer != NULL";
v34 = 1442;
goto LABEL_19;
}
if ( (v28 & 0xF) != 0 )
{
v33 = "((uintptr_t) (ctx->mem_buffer))%GGML_MEM_ALIGN == 0";
v34 = 1444;
LABEL_19:
ggml_abort(
(unsigned int)"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
v34,
(unsigned int)"GGML_ASSERT(%s) failed",
(_DWORD)v33,
v22,
v23);
}
return v26;
}
|
ggml_init:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
CALL 0x00118e20
CMP byte ptr [0x0016f200],0x0
JNZ 0x0011b661
XOR EAX,EAX
MOVSS XMM0,dword ptr [0x0014c050]
MOVSS XMM1,dword ptr [0x0014c054]
MOV RCX,qword ptr [0x0016dfa8]
XOR EDX,EDX
XOR ESI,ESI
LAB_0011b5fb:
MOV EDI,EAX
SHR EDI,0x4
OR EDI,0x70000000
MOVD XMM2,EDI
MOV EDI,ESI
AND EDI,0x7fff
OR EDI,0x3f000000
MOVD XMM3,EDI
ADDSS XMM3,XMM0
MULSS XMM2,XMM1
CMP EAX,0x8000000
JC 0x0011b62e
MOVAPS XMM3,XMM2
LAB_0011b62e:
MOVD EDI,XMM3
MOV R8D,EDX
AND R8D,0x80000000
OR R8D,EDI
MOV dword ptr [RCX + RSI*0x4],R8D
INC RSI
ADD EDX,0x10000
ADD EAX,0x20000
CMP RSI,0x10000
JNZ 0x0011b5fb
MOV byte ptr [0x0016f200],0x1
LAB_0011b661:
CALL 0x00118c10
MOV EDI,0x28
CALL 0x00118650
TEST RAX,RAX
JZ 0x0011b6e8
MOV RBX,RAX
LEA R15,[RSP + 0x30]
CMP qword ptr [R15],0x0
JNZ 0x0011b68a
MOV qword ptr [R15],0x10
LAB_0011b68a:
MOV RCX,qword ptr [R15]
MOV R12,qword ptr [R15 + 0x8]
LEA R14,[RCX + 0xf]
AND R14,-0x10
MOV RAX,R12
TEST R12,R12
CMOVNZ R14,RCX
JNZ 0x0011b6ad
MOV RDI,R14
CALL 0x00117880
LAB_0011b6ad:
TEST R12,R12
MOV CL,byte ptr [R15 + 0x10]
MOV qword ptr [RBX],R14
MOV qword ptr [RBX + 0x8],RAX
SETZ byte ptr [RBX + 0x10]
MOV byte ptr [RBX + 0x11],CL
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x14],XMM0
MOV dword ptr [RBX + 0x24],0x0
TEST RAX,RAX
JZ 0x0011b724
TEST AL,0xf
JNZ 0x0011b740
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
LAB_0011b6e8:
LEA RSI,[0x14e518]
LEA RDX,[0x14e539]
MOVSD XMM0,qword ptr [0x0014c038]
MOV EDI,0x4
MOV AL,0x1
CALL 0x00117810
LEA RDI,[0x14c56f]
LEA RDX,[0x14e545]
MOV ESI,0x13c
XOR EAX,EAX
CALL 0x00118ce0
LAB_0011b724:
LEA RDI,[0x14c56f]
LEA RDX,[0x14c5c1]
LEA RCX,[0x14c6c3]
MOV ESI,0x5a2
JMP 0x0011b75a
LAB_0011b740:
LEA RDI,[0x14c56f]
LEA RDX,[0x14c5c1]
LEA RCX,[0x14c6db]
MOV ESI,0x5a4
LAB_0011b75a:
XOR EAX,EAX
CALL 0x00118ce0
|
ulong * ggml_init(void)
{
float fVar1;
float fVar2;
int *puVar3;
uint uVar4;
ulong *puVar5;
ulong uVar6;
char *pcVar7;
uint uVar8;
long lVar9;
int8 uVar10;
ulong uVar11;
float fVar12;
ulong in_stack_00000008;
ulong in_stack_00000010;
int1 in_stack_00000018;
ggml_critical_section_start();
puVar3 = PTR_ggml_table_f32_f16_0016dfa8;
fVar2 = DAT_0014c054;
fVar1 = DAT_0014c050;
if (ggml_init_is_first_call == '\0') {
uVar4 = 0;
uVar8 = 0;
lVar9 = 0;
do {
fVar12 = (float)((uint)lVar9 & 0x7fff | 0x3f000000) + fVar1;
if (0x7ffffff < uVar4) {
fVar12 = (float)(uVar4 >> 4 | 0x70000000) * fVar2;
}
*(uint *)(puVar3 + lVar9 * 4) = uVar8 & 0x80000000 | (uint)fVar12;
lVar9 = lVar9 + 1;
uVar8 = uVar8 + 0x10000;
uVar4 = uVar4 + 0x20000;
} while (lVar9 != 0x10000);
ggml_init_is_first_call = '\x01';
}
ggml_critical_section_end();
puVar5 = (ulong *)malloc(0x28);
if (puVar5 != (ulong *)0x0) {
if (in_stack_00000008 == 0) {
in_stack_00000008 = 0x10;
}
uVar11 = in_stack_00000008 + 0xf & 0xfffffffffffffff0;
uVar6 = in_stack_00000010;
if (in_stack_00000010 == 0) {
uVar6 = ggml_aligned_malloc(uVar11);
in_stack_00000008 = uVar11;
}
*puVar5 = in_stack_00000008;
puVar5[1] = uVar6;
*(bool *)(puVar5 + 2) = in_stack_00000010 == 0;
*(int1 *)((long)puVar5 + 0x11) = in_stack_00000018;
*(int8 *)((long)puVar5 + 0x14) = 0;
*(int8 *)((long)puVar5 + 0x1c) = 0;
*(int4 *)((long)puVar5 + 0x24) = 0;
if (uVar6 == 0) {
pcVar7 = "ctx->mem_buffer != NULL";
uVar10 = 0x5a2;
}
else {
if ((uVar6 & 0xf) == 0) {
return puVar5;
}
pcVar7 = "((uintptr_t) (ctx->mem_buffer))%GGML_MEM_ALIGN == 0";
uVar10 = 0x5a4;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
uVar10,"GGML_ASSERT(%s) failed",pcVar7);
}
ggml_log_internal((int)DAT_0014c038,4,"%s: failed to allocate %6.2f MB\n","ggml_malloc");
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
0x13c,"fatal error");
}
|
|
19,948
|
ggml_init
|
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
|
struct ggml_context * ggml_init(struct ggml_init_params params) {
static bool is_first_call = true;
ggml_critical_section_start();
if (is_first_call) {
// initialize time system (required on Windows)
ggml_time_init();
for (int i = 0; i < (1 << 16); ++i) {
union {
uint16_t u16;
ggml_fp16_t fp16;
} u = {i};
ggml_table_f32_f16[i] = GGML_COMPUTE_FP16_TO_FP32(u.fp16);
}
is_first_call = false;
}
ggml_critical_section_end();
struct ggml_context * ctx = GGML_MALLOC(sizeof(struct ggml_context));
// allow to call ggml_init with 0 size
if (params.mem_size == 0) {
params.mem_size = GGML_MEM_ALIGN;
}
const size_t mem_size = params.mem_buffer ? params.mem_size : GGML_PAD(params.mem_size, GGML_MEM_ALIGN);
*ctx = (struct ggml_context) {
/*.mem_size =*/ mem_size,
/*.mem_buffer =*/ params.mem_buffer ? params.mem_buffer : ggml_aligned_malloc(mem_size),
/*.mem_buffer_owned =*/ params.mem_buffer ? false : true,
/*.no_alloc =*/ params.no_alloc,
/*.n_objects =*/ 0,
/*.objects_begin =*/ NULL,
/*.objects_end =*/ NULL,
};
GGML_ASSERT(ctx->mem_buffer != NULL);
GGML_ASSERT_ALIGNED(ctx->mem_buffer);
GGML_PRINT_DEBUG("%s: context initialized\n", __func__);
return ctx;
}
|
O2
|
c
|
ggml_init:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
leaq 0x30(%rsp), %r14
callq 0x1fb80
cmpb $0x0, 0x53a6a(%rip) # 0x749e0
jne 0x21001
xorl %eax, %eax
movss 0x2d0d2(%rip), %xmm0 # 0x4e058
movss 0x2d0ce(%rip), %xmm1 # 0x4e05c
movq 0x52013(%rip), %rcx # 0x72fa8
xorl %edx, %edx
xorl %esi, %esi
cmpq $0x10000, %rsi # imm = 0x10000
je 0x20ffa
movl %eax, %edi
shrl $0x4, %edi
orl $0x70000000, %edi # imm = 0x70000000
movd %edi, %xmm2
movl %esi, %edi
andl $0x7fff, %edi # imm = 0x7FFF
orl $0x3f000000, %edi # imm = 0x3F000000
movd %edi, %xmm3
addss %xmm0, %xmm3
mulss %xmm1, %xmm2
cmpl $0x8000000, %eax # imm = 0x8000000
jb 0x20fd5
movaps %xmm2, %xmm3
movd %xmm3, %edi
movl %edx, %r8d
andl $0x80000000, %r8d # imm = 0x80000000
orl %edi, %r8d
movl %r8d, (%rcx,%rsi,4)
incq %rsi
addl $0x10000, %edx # imm = 0x10000
addl $0x20000, %eax # imm = 0x20000
jmp 0x20f99
movb $0x1, 0x539df(%rip) # 0x749e0
callq 0x1f850
pushq $0x28
popq %rdi
callq 0x210b2
movq %rax, %rbx
movq (%r14), %rax
movq 0x8(%r14), %r15
testq %rax, %rax
pushq $0x10
popq %r12
cmovneq %rax, %r12
leaq 0xf(%r12), %rdi
andq $-0x10, %rdi
movq %r15, %rax
testq %r15, %r15
cmoveq %rdi, %r12
jne 0x2103d
callq 0x1dc40
testq %r15, %r15
movb 0x10(%r14), %cl
movq %r12, (%rbx)
movq %rax, 0x8(%rbx)
sete 0x10(%rbx)
movb %cl, 0x11(%rbx)
andl $0x0, 0x24(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x14(%rbx)
testq %rax, %rax
je 0x21075
testb $0xf, %al
jne 0x21091
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x2d507(%rip), %rdi # 0x4e583
leaq 0x2d552(%rip), %rdx # 0x4e5d5
leaq 0x2d64d(%rip), %rcx # 0x4e6d7
movl $0x5a2, %esi # imm = 0x5A2
jmp 0x210ab
leaq 0x2d4eb(%rip), %rdi # 0x4e583
leaq 0x2d536(%rip), %rdx # 0x4e5d5
leaq 0x2d649(%rip), %rcx # 0x4e6ef
movl $0x5a4, %esi # imm = 0x5A4
xorl %eax, %eax
callq 0x1f9b0
|
ggml_init:
push r15
push r14
push r12
push rbx
push rax
lea r14, [rsp+28h+arg_0]
call _ggml_critical_section_start
cmp cs:ggml_init_is_first_call, 0
jnz loc_21001
xor eax, eax
movss xmm0, cs:dword_4E058
movss xmm1, cs:dword_4E05C
mov rcx, cs:ggml_table_f32_f16_ptr
xor edx, edx
xor esi, esi
loc_20F99:
cmp rsi, 10000h
jz short loc_20FFA
mov edi, eax
shr edi, 4
or edi, 70000000h
movd xmm2, edi
mov edi, esi
and edi, 7FFFh
or edi, 3F000000h
movd xmm3, edi
addss xmm3, xmm0
mulss xmm2, xmm1
cmp eax, 8000000h
jb short loc_20FD5
movaps xmm3, xmm2
loc_20FD5:
movd edi, xmm3
mov r8d, edx
and r8d, 80000000h
or r8d, edi
mov [rcx+rsi*4], r8d
inc rsi
add edx, 10000h
add eax, 20000h
jmp short loc_20F99
loc_20FFA:
mov cs:ggml_init_is_first_call, 1
loc_21001:
call _ggml_critical_section_end
push 28h ; '('
pop rdi
call ggml_malloc
mov rbx, rax
mov rax, [r14]
mov r15, [r14+8]
test rax, rax
push 10h
pop r12
cmovnz r12, rax
lea rdi, [r12+0Fh]
and rdi, 0FFFFFFFFFFFFFFF0h
mov rax, r15
test r15, r15
cmovz r12, rdi
jnz short loc_2103D
call _ggml_aligned_malloc
loc_2103D:
test r15, r15
mov cl, [r14+10h]
mov [rbx], r12
mov [rbx+8], rax
setz byte ptr [rbx+10h]
mov [rbx+11h], cl
and dword ptr [rbx+24h], 0
xorps xmm0, xmm0
movups xmmword ptr [rbx+14h], xmm0
test rax, rax
jz short loc_21075
test al, 0Fh
jnz short loc_21091
mov rax, rbx
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
loc_21075:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aCtxMemBufferNu; "ctx->mem_buffer != NULL"
mov esi, 5A2h
jmp short loc_210AB
loc_21091:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aUintptrTCtxMem; "((uintptr_t) (ctx->mem_buffer))%GGML_ME"...
mov esi, 5A4h
loc_210AB:
xor eax, eax
call _ggml_abort
|
long long ggml_init(
__m128 a1,
__m128 a2,
__m128 a3,
__m128i a4,
double a5,
double a6,
__m128 a7,
__m128 a8,
long long a9,
long long i,
long long a11,
long long a12,
long long a13,
long long a14,
unsigned long long a15,
long long a16,
char a17)
{
char v17; // al
unsigned int v18; // eax
int v19; // edx
long long v20; // rdx
long long v21; // rcx
long long v22; // rbx
long long v23; // r8
long long v24; // r9
__m128 v25; // xmm4
__m128 v26; // xmm5
unsigned long long v27; // r12
unsigned long long v28; // rdi
long long v29; // rax
const char *v31; // rcx
int v32; // esi
char v33; // [rsp-8h] [rbp-28h]
v33 = v17;
ggml_critical_section_start();
if ( !ggml_init_is_first_call )
{
v18 = 0;
a1 = (__m128)0xBF000000;
a2 = (__m128)0x7800000u;
v19 = 0;
for ( i = 0LL; i != 0x10000; ++i )
{
a3 = (__m128)_mm_cvtsi32_si128((v18 >> 4) | 0x70000000);
a4 = _mm_cvtsi32_si128(i & 0x7FFF | 0x3F000000);
*(float *)a4.m128i_i32 = *(float *)a4.m128i_i32 + -0.5;
a3.m128_f32[0] = a3.m128_f32[0] * 1.9259299e-34;
if ( v18 >= 0x8000000 )
a4 = (__m128i)a3;
LODWORD(ggml_table_f32_f16[i]) = _mm_cvtsi128_si32(a4) | v19 & 0x80000000;
v19 += 0x10000;
v18 += 0x20000;
}
ggml_init_is_first_call = 1;
}
ggml_critical_section_end();
v22 = ggml_malloc(40LL);
v27 = 16LL;
if ( a15 )
v27 = a15;
v28 = (v27 + 15) & 0xFFFFFFFFFFFFFFF0LL;
v29 = a16;
if ( !a16 )
{
v27 = (v27 + 15) & 0xFFFFFFFFFFFFFFF0LL;
v29 = ggml_aligned_malloc(v28, a1, a2, a3, (__m128)a4, v25, v26, a7, a8, i, v20, v21, v23, v24);
}
*(_QWORD *)v22 = v27;
*(_QWORD *)(v22 + 8) = v29;
*(_BYTE *)(v22 + 16) = a16 == 0;
*(_BYTE *)(v22 + 17) = a17;
*(_DWORD *)(v22 + 36) = 0;
*(_OWORD *)(v22 + 20) = 0LL;
if ( !v29 )
{
v31 = "ctx->mem_buffer != NULL";
v32 = 1442;
goto LABEL_17;
}
if ( (v29 & 0xF) != 0 )
{
v31 = "((uintptr_t) (ctx->mem_buffer))%GGML_MEM_ALIGN == 0";
v32 = 1444;
LABEL_17:
ggml_abort(
"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
v32,
(long long)"GGML_ASSERT(%s) failed",
(long long)v31,
v23,
v24,
(__m128)0LL,
a2,
a3,
(__m128)a4,
v25,
v26,
a7,
a8,
v33);
}
return v22;
}
|
ggml_init:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
LEA R14,[RSP + 0x30]
CALL 0x0011fb80
CMP byte ptr [0x001749e0],0x0
JNZ 0x00121001
XOR EAX,EAX
MOVSS XMM0,dword ptr [0x0014e058]
MOVSS XMM1,dword ptr [0x0014e05c]
MOV RCX,qword ptr [0x00172fa8]
XOR EDX,EDX
XOR ESI,ESI
LAB_00120f99:
CMP RSI,0x10000
JZ 0x00120ffa
MOV EDI,EAX
SHR EDI,0x4
OR EDI,0x70000000
MOVD XMM2,EDI
MOV EDI,ESI
AND EDI,0x7fff
OR EDI,0x3f000000
MOVD XMM3,EDI
ADDSS XMM3,XMM0
MULSS XMM2,XMM1
CMP EAX,0x8000000
JC 0x00120fd5
MOVAPS XMM3,XMM2
LAB_00120fd5:
MOVD EDI,XMM3
MOV R8D,EDX
AND R8D,0x80000000
OR R8D,EDI
MOV dword ptr [RCX + RSI*0x4],R8D
INC RSI
ADD EDX,0x10000
ADD EAX,0x20000
JMP 0x00120f99
LAB_00120ffa:
MOV byte ptr [0x001749e0],0x1
LAB_00121001:
CALL 0x0011f850
PUSH 0x28
POP RDI
CALL 0x001210b2
MOV RBX,RAX
MOV RAX,qword ptr [R14]
MOV R15,qword ptr [R14 + 0x8]
TEST RAX,RAX
PUSH 0x10
POP R12
CMOVNZ R12,RAX
LEA RDI,[R12 + 0xf]
AND RDI,-0x10
MOV RAX,R15
TEST R15,R15
CMOVZ R12,RDI
JNZ 0x0012103d
CALL 0x0011dc40
LAB_0012103d:
TEST R15,R15
MOV CL,byte ptr [R14 + 0x10]
MOV qword ptr [RBX],R12
MOV qword ptr [RBX + 0x8],RAX
SETZ byte ptr [RBX + 0x10]
MOV byte ptr [RBX + 0x11],CL
AND dword ptr [RBX + 0x24],0x0
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x14],XMM0
TEST RAX,RAX
JZ 0x00121075
TEST AL,0xf
JNZ 0x00121091
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
LAB_00121075:
LEA RDI,[0x14e583]
LEA RDX,[0x14e5d5]
LEA RCX,[0x14e6d7]
MOV ESI,0x5a2
JMP 0x001210ab
LAB_00121091:
LEA RDI,[0x14e583]
LEA RDX,[0x14e5d5]
LEA RCX,[0x14e6ef]
MOV ESI,0x5a4
LAB_001210ab:
XOR EAX,EAX
CALL 0x0011f9b0
|
ulong * ggml_init(void)
{
float fVar1;
float fVar2;
int *puVar3;
uint uVar4;
ulong *puVar5;
ulong uVar6;
char *pcVar7;
uint uVar8;
long lVar9;
int8 uVar10;
ulong uVar11;
float fVar12;
ulong in_stack_00000008;
ulong in_stack_00000010;
int1 in_stack_00000018;
ggml_critical_section_start();
puVar3 = PTR_ggml_table_f32_f16_00172fa8;
fVar2 = DAT_0014e05c;
fVar1 = DAT_0014e058;
if (ggml_init_is_first_call == '\0') {
uVar4 = 0;
uVar8 = 0;
for (lVar9 = 0; lVar9 != 0x10000; lVar9 = lVar9 + 1) {
fVar12 = (float)((uint)lVar9 & 0x7fff | 0x3f000000) + fVar1;
if (0x7ffffff < uVar4) {
fVar12 = (float)(uVar4 >> 4 | 0x70000000) * fVar2;
}
*(uint *)(puVar3 + lVar9 * 4) = uVar8 & 0x80000000 | (uint)fVar12;
uVar8 = uVar8 + 0x10000;
uVar4 = uVar4 + 0x20000;
}
ggml_init_is_first_call = '\x01';
}
ggml_critical_section_end();
puVar5 = (ulong *)ggml_malloc(0x28);
uVar11 = 0x10;
if (in_stack_00000008 != 0) {
uVar11 = in_stack_00000008;
}
uVar6 = in_stack_00000010;
if (in_stack_00000010 == 0) {
uVar6 = ggml_aligned_malloc();
uVar11 = uVar11 + 0xf & 0xfffffffffffffff0;
}
*puVar5 = uVar11;
puVar5[1] = uVar6;
*(bool *)(puVar5 + 2) = in_stack_00000010 == 0;
*(int1 *)((long)puVar5 + 0x11) = in_stack_00000018;
*(int4 *)((long)puVar5 + 0x24) = 0;
*(int8 *)((long)puVar5 + 0x14) = 0;
*(int8 *)((long)puVar5 + 0x1c) = 0;
if (uVar6 == 0) {
pcVar7 = "ctx->mem_buffer != NULL";
uVar10 = 0x5a2;
}
else {
if ((uVar6 & 0xf) == 0) {
return puVar5;
}
pcVar7 = "((uintptr_t) (ctx->mem_buffer))%GGML_MEM_ALIGN == 0";
uVar10 = 0x5a4;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c",
uVar10,"GGML_ASSERT(%s) failed",pcVar7);
}
|
|
19,949
|
flux::parser::DataDecl::clone() const
|
kvthweatt[P]FluxLang/src/parser/ast.cpp
|
std::unique_ptr<Decl> DataDecl::clone() const {
return std::make_unique<DataDecl>(name, bits, isSigned, range);
}
|
O3
|
cpp
|
flux::parser::DataDecl::clone() const:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movl $0x48, %edi
callq 0x6270
movups 0x8(%rbx), %xmm0
movups 0x18(%rbx), %xmm1
movups 0x28(%rbx), %xmm2
movq 0x38(%rbx), %rcx
movb 0x40(%rbx), %dl
movups %xmm0, 0x8(%rax)
movups %xmm1, 0x18(%rax)
movups %xmm2, 0x28(%rax)
leaq 0x29548(%rip), %rsi # 0x389e8
movq %rsi, (%rax)
movq %rcx, 0x38(%rax)
movb %dl, 0x40(%rax)
movq %rax, (%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
|
_ZNK4flux6parser8DataDecl5cloneEv:
push r14
push rbx
push rax
mov rbx, rsi
mov r14, rdi
mov edi, 48h ; 'H'; unsigned __int64
call __Znwm; operator new(ulong)
movups xmm0, xmmword ptr [rbx+8]
movups xmm1, xmmword ptr [rbx+18h]
movups xmm2, xmmword ptr [rbx+28h]
mov rcx, [rbx+38h]
mov dl, [rbx+40h]
movups xmmword ptr [rax+8], xmm0
movups xmmword ptr [rax+18h], xmm1
movups xmmword ptr [rax+28h], xmm2
lea rsi, off_389E8
mov [rax], rsi
mov [rax+38h], rcx
mov [rax+40h], dl
mov [r14], rax
mov rax, r14
add rsp, 8
pop rbx
pop r14
retn
|
flux::parser::DataDecl * flux::parser::DataDecl::clone(flux::parser::DataDecl *this, long long a2)
{
long long v2; // rax
__int128 v3; // xmm1
__int128 v4; // xmm2
long long v5; // rcx
char v6; // dl
v2 = operator new(0x48uLL);
v3 = *(_OWORD *)(a2 + 24);
v4 = *(_OWORD *)(a2 + 40);
v5 = *(_QWORD *)(a2 + 56);
v6 = *(_BYTE *)(a2 + 64);
*(_OWORD *)(v2 + 8) = *(_OWORD *)(a2 + 8);
*(_OWORD *)(v2 + 24) = v3;
*(_OWORD *)(v2 + 40) = v4;
*(_QWORD *)v2 = off_389E8;
*(_QWORD *)(v2 + 56) = v5;
*(_BYTE *)(v2 + 64) = v6;
*(_QWORD *)this = v2;
return this;
}
|
clone:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV R14,RDI
MOV EDI,0x48
CALL 0x00106270
MOVUPS XMM0,xmmword ptr [RBX + 0x8]
MOVUPS XMM1,xmmword ptr [RBX + 0x18]
MOVUPS XMM2,xmmword ptr [RBX + 0x28]
MOV RCX,qword ptr [RBX + 0x38]
MOV DL,byte ptr [RBX + 0x40]
MOVUPS xmmword ptr [RAX + 0x8],XMM0
MOVUPS xmmword ptr [RAX + 0x18],XMM1
MOVUPS xmmword ptr [RAX + 0x28],XMM2
LEA RSI,[0x1389e8]
MOV qword ptr [RAX],RSI
MOV qword ptr [RAX + 0x38],RCX
MOV byte ptr [RAX + 0x40],DL
MOV qword ptr [R14],RAX
MOV RAX,R14
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* flux::parser::DataDecl::clone() const */
void flux::parser::DataDecl::clone(void)
{
int1 uVar1;
int8 uVar2;
int8 uVar3;
int8 uVar4;
int8 uVar5;
int8 uVar6;
int8 uVar7;
int8 *puVar8;
long in_RSI;
int8 *in_RDI;
puVar8 = (int8 *)operator_new(0x48);
uVar3 = *(int8 *)(in_RSI + 0x10);
uVar4 = *(int8 *)(in_RSI + 0x18);
uVar5 = *(int8 *)(in_RSI + 0x20);
uVar6 = *(int8 *)(in_RSI + 0x28);
uVar7 = *(int8 *)(in_RSI + 0x30);
uVar2 = *(int8 *)(in_RSI + 0x38);
uVar1 = *(int1 *)(in_RSI + 0x40);
puVar8[1] = *(int8 *)(in_RSI + 8);
puVar8[2] = uVar3;
puVar8[3] = uVar4;
puVar8[4] = uVar5;
puVar8[5] = uVar6;
puVar8[6] = uVar7;
*puVar8 = &PTR__Decl_001389e8;
puVar8[7] = uVar2;
*(int1 *)(puVar8 + 8) = uVar1;
*in_RDI = puVar8;
return;
}
|
|
19,950
|
mysql_ssl_set
|
eloqsql/libmariadb/libmariadb/mariadb_lib.c
|
int STDCALL
mysql_ssl_set(MYSQL *mysql __attribute__((unused)),
const char *key __attribute__((unused)),
const char *cert __attribute__((unused)),
const char *ca __attribute__((unused)),
const char *capath __attribute__((unused)),
const char *cipher __attribute__((unused)))
{
#ifdef HAVE_TLS
char enable= 1;
return (mysql_optionsv(mysql, MYSQL_OPT_SSL_ENFORCE, &enable) |
mysql_optionsv(mysql, MYSQL_OPT_SSL_KEY, key) |
mysql_optionsv(mysql, MYSQL_OPT_SSL_CERT, cert) |
mysql_optionsv(mysql, MYSQL_OPT_SSL_CA, ca) |
mysql_optionsv(mysql, MYSQL_OPT_SSL_CAPATH, capath) |
mysql_optionsv(mysql, MYSQL_OPT_SSL_CIPHER, cipher)) ? 1 : 0;
#else
return 0;
#endif
}
|
O3
|
c
|
mysql_ssl_set:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, -0x40(%rbp)
movq %r8, -0x38(%rbp)
movq %rcx, %r12
movq %rdx, %r13
movq %rsi, %rbx
movq %rdi, %r14
leaq -0x29(%rbp), %rdx
movb $0x1, (%rdx)
movl $0x26, %esi
xorl %eax, %eax
callq 0x164ee
movl %eax, %r15d
movq %r14, %rdi
movl $0x19, %esi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x164ee
movl %eax, %ebx
orl %r15d, %ebx
movq %r14, %rdi
movl $0x1a, %esi
movq %r13, %rdx
xorl %eax, %eax
callq 0x164ee
movl %eax, %r15d
movq %r14, %rdi
movl $0x1b, %esi
movq %r12, %rdx
xorl %eax, %eax
callq 0x164ee
movl %eax, %r12d
orl %r15d, %r12d
orl %ebx, %r12d
movq %r14, %rdi
movl $0x1c, %esi
movq -0x38(%rbp), %rdx
xorl %eax, %eax
callq 0x164ee
movl %eax, %ebx
orl %r12d, %ebx
movq %r14, %rdi
movl $0x1d, %esi
movq -0x40(%rbp), %rdx
xorl %eax, %eax
callq 0x164ee
xorl %ecx, %ecx
orl %ebx, %eax
setne %cl
movl %ecx, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
mysql_ssl_set:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov [rbp+var_40], r9
mov [rbp+var_38], r8
mov r12, rcx
mov r13, rdx
mov rbx, rsi
mov r14, rdi
lea rdx, [rbp+var_29]
mov byte ptr [rdx], 1
mov esi, 26h ; '&'
xor eax, eax
call mysql_optionsv
mov r15d, eax
mov rdi, r14
mov esi, 19h
mov rdx, rbx
xor eax, eax
call mysql_optionsv
mov ebx, eax
or ebx, r15d
mov rdi, r14
mov esi, 1Ah
mov rdx, r13
xor eax, eax
call mysql_optionsv
mov r15d, eax
mov rdi, r14
mov esi, 1Bh
mov rdx, r12
xor eax, eax
call mysql_optionsv
mov r12d, eax
or r12d, r15d
or r12d, ebx
mov rdi, r14
mov esi, 1Ch
mov rdx, [rbp+var_38]
xor eax, eax
call mysql_optionsv
mov ebx, eax
or ebx, r12d
mov rdi, r14
mov esi, 1Dh
mov rdx, [rbp+var_40]
xor eax, eax
call mysql_optionsv
xor ecx, ecx
or eax, ebx
setnz cl
mov eax, ecx
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
_BOOL8 mysql_ssl_set(
long long a1,
char *a2,
char *a3,
long long a4,
char *a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14)
{
char *v14; // r12
int v16; // r15d
long long v17; // rcx
long long v18; // r8
long long v19; // r9
__m128 v20; // xmm4
__m128 v21; // xmm5
int v22; // ebx
long long v23; // rcx
long long v24; // r8
long long v25; // r9
__m128 v26; // xmm4
__m128 v27; // xmm5
int v28; // r15d
long long v29; // rcx
long long v30; // r8
long long v31; // r9
__m128 v32; // xmm4
__m128 v33; // xmm5
long long v34; // rcx
long long v35; // r8
long long v36; // r9
__m128 v37; // xmm4
__m128 v38; // xmm5
int v39; // ebx
long long v40; // rcx
long long v41; // r8
long long v42; // r9
__m128 v43; // xmm4
__m128 v44; // xmm5
char v46; // [rsp+0h] [rbp-40h]
char v47; // [rsp+0h] [rbp-40h]
char v48; // [rsp+0h] [rbp-40h]
char v49; // [rsp+0h] [rbp-40h]
char *v50; // [rsp+0h] [rbp-40h]
char v52[41]; // [rsp+17h] [rbp-29h] BYREF
v14 = (char *)a4;
v52[0] = 1;
v16 = mysql_optionsv(a1, 38, v52, a4, (long long)a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a6);
v22 = v16 | mysql_optionsv(a1, 25, a2, v17, v18, v19, a7, a8, a9, a10, v20, v21, a13, a14, v46);
v28 = mysql_optionsv(a1, 26, a3, v23, v24, v25, a7, a8, a9, a10, v26, v27, a13, a14, v47);
LODWORD(v14) = v22 | v28 | mysql_optionsv(a1, 27, v14, v29, v30, v31, a7, a8, a9, a10, v32, v33, a13, a14, v48);
v39 = (unsigned int)v14 | mysql_optionsv(a1, 28, a5, v34, v35, v36, a7, a8, a9, a10, v37, v38, a13, a14, v49);
return (v39 | (unsigned int)mysql_optionsv(a1, 29, v50, v40, v41, v42, a7, a8, a9, a10, v43, v44, a13, a14, (char)v50)) != 0;
}
|
mysql_ssl_set:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV qword ptr [RBP + -0x40],R9
MOV qword ptr [RBP + -0x38],R8
MOV R12,RCX
MOV R13,RDX
MOV RBX,RSI
MOV R14,RDI
LEA RDX,[RBP + -0x29]
MOV byte ptr [RDX],0x1
MOV ESI,0x26
XOR EAX,EAX
CALL 0x001164ee
MOV R15D,EAX
MOV RDI,R14
MOV ESI,0x19
MOV RDX,RBX
XOR EAX,EAX
CALL 0x001164ee
MOV EBX,EAX
OR EBX,R15D
MOV RDI,R14
MOV ESI,0x1a
MOV RDX,R13
XOR EAX,EAX
CALL 0x001164ee
MOV R15D,EAX
MOV RDI,R14
MOV ESI,0x1b
MOV RDX,R12
XOR EAX,EAX
CALL 0x001164ee
MOV R12D,EAX
OR R12D,R15D
OR R12D,EBX
MOV RDI,R14
MOV ESI,0x1c
MOV RDX,qword ptr [RBP + -0x38]
XOR EAX,EAX
CALL 0x001164ee
MOV EBX,EAX
OR EBX,R12D
MOV RDI,R14
MOV ESI,0x1d
MOV RDX,qword ptr [RBP + -0x40]
XOR EAX,EAX
CALL 0x001164ee
XOR ECX,ECX
OR EAX,EBX
SETNZ CL
MOV EAX,ECX
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
bool mysql_ssl_set(int8 param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5,int8 param_6)
{
int iVar1;
int iVar2;
int iVar3;
int iVar4;
int iVar5;
int iVar6;
iVar1 = mysql_optionsv(param_1,0x26);
iVar2 = mysql_optionsv(param_1,0x19,param_2);
iVar3 = mysql_optionsv(param_1,0x1a,param_3);
iVar4 = mysql_optionsv(param_1,0x1b,param_4);
iVar5 = mysql_optionsv(param_1,0x1c,param_5);
iVar6 = mysql_optionsv(param_1,0x1d,param_6);
return iVar6 != 0 || (iVar5 != 0 || ((iVar4 != 0 || iVar3 != 0) || (iVar2 != 0 || iVar1 != 0)));
}
|
|
19,951
|
calc_hashnr_caseup
|
eloqsql/libmariadb/libmariadb/ma_hashtbl.c
|
static uint calc_hashnr_caseup(const uchar *key,uint length)
{
register uint nr=1, nr2=4;
while (length--)
{
nr^= (((nr & 63)+nr2)*((uint) (uchar) toupper(*key++)))+ (nr << 8);
nr2+=3;
}
return((uint) nr);
}
|
O0
|
c
|
calc_hashnr_caseup:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl $0x1, -0x10(%rbp)
movl $0x4, -0x14(%rbp)
movl -0xc(%rbp), %eax
movl %eax, %ecx
addl $-0x1, %ecx
movl %ecx, -0xc(%rbp)
cmpl $0x0, %eax
je 0x44b04
movl -0x10(%rbp), %eax
andl $0x3f, %eax
addl -0x14(%rbp), %eax
movl %eax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x8(%rbp)
movzbl (%rax), %edi
callq 0x137b0
movl %eax, %ecx
movl -0x18(%rbp), %eax
movzbl %cl, %ecx
imull %ecx, %eax
movl -0x10(%rbp), %ecx
shll $0x8, %ecx
addl %ecx, %eax
xorl -0x10(%rbp), %eax
movl %eax, -0x10(%rbp)
movl -0x14(%rbp), %eax
addl $0x3, %eax
movl %eax, -0x14(%rbp)
jmp 0x44aad
movl -0x10(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
|
calc_hashnr_caseup:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_10], 1
mov [rbp+var_14], 4
loc_44AAD:
mov eax, [rbp+var_C]
mov ecx, eax
add ecx, 0FFFFFFFFh
mov [rbp+var_C], ecx
cmp eax, 0
jz short loc_44B04
mov eax, [rbp+var_10]
and eax, 3Fh
add eax, [rbp+var_14]
mov [rbp+var_18], eax
mov rax, [rbp+var_8]
mov rcx, rax
add rcx, 1
mov [rbp+var_8], rcx
movzx edi, byte ptr [rax]
call _toupper
mov ecx, eax
mov eax, [rbp+var_18]
movzx ecx, cl
imul eax, ecx
mov ecx, [rbp+var_10]
shl ecx, 8
add eax, ecx
xor eax, [rbp+var_10]
mov [rbp+var_10], eax
mov eax, [rbp+var_14]
add eax, 3
mov [rbp+var_14], eax
jmp short loc_44AAD
loc_44B04:
mov eax, [rbp+var_10]
add rsp, 20h
pop rbp
retn
|
long long calc_hashnr_caseup(unsigned __int8 *a1, int a2)
{
unsigned __int8 *v3; // rax
int i; // [rsp+Ch] [rbp-14h]
unsigned int v6; // [rsp+10h] [rbp-10h]
v6 = 1;
for ( i = 4; a2--; i += 3 )
{
v3 = a1++;
v6 ^= (v6 << 8) + (unsigned __int8)toupper(*v3) * (i + (v6 & 0x3F));
}
return v6;
}
|
calc_hashnr_caseup:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV dword ptr [RBP + -0x10],0x1
MOV dword ptr [RBP + -0x14],0x4
LAB_00144aad:
MOV EAX,dword ptr [RBP + -0xc]
MOV ECX,EAX
ADD ECX,-0x1
MOV dword ptr [RBP + -0xc],ECX
CMP EAX,0x0
JZ 0x00144b04
MOV EAX,dword ptr [RBP + -0x10]
AND EAX,0x3f
ADD EAX,dword ptr [RBP + -0x14]
MOV dword ptr [RBP + -0x18],EAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,RAX
ADD RCX,0x1
MOV qword ptr [RBP + -0x8],RCX
MOVZX EDI,byte ptr [RAX]
CALL 0x001137b0
MOV ECX,EAX
MOV EAX,dword ptr [RBP + -0x18]
MOVZX ECX,CL
IMUL EAX,ECX
MOV ECX,dword ptr [RBP + -0x10]
SHL ECX,0x8
ADD EAX,ECX
XOR EAX,dword ptr [RBP + -0x10]
MOV dword ptr [RBP + -0x10],EAX
MOV EAX,dword ptr [RBP + -0x14]
ADD EAX,0x3
MOV dword ptr [RBP + -0x14],EAX
JMP 0x00144aad
LAB_00144b04:
MOV EAX,dword ptr [RBP + -0x10]
ADD RSP,0x20
POP RBP
RET
|
uint calc_hashnr_caseup(byte *param_1,int param_2)
{
uint uVar1;
int local_1c;
uint local_18;
int local_14;
byte *local_10;
local_18 = 1;
local_1c = 4;
local_14 = param_2;
local_10 = param_1;
while (local_14 != 0) {
uVar1 = toupper((uint)*local_10);
local_18 = ((local_18 & 0x3f) + local_1c) * (uVar1 & 0xff) + local_18 * 0x100 ^ local_18;
local_1c = local_1c + 3;
local_14 = local_14 + -1;
local_10 = local_10 + 1;
}
return local_18;
}
|
|
19,952
|
find_hashed_shape_prop
|
bluesky950520[P]quickjs/quickjs.c
|
static JSShape *find_hashed_shape_prop(JSRuntime *rt, JSShape *sh,
JSAtom atom, int prop_flags)
{
JSShape *sh1;
uint32_t h, h1, i, n;
h = sh->hash;
h = shape_hash(h, atom);
h = shape_hash(h, prop_flags);
h1 = get_shape_hash(h, rt->shape_hash_bits);
for(sh1 = rt->shape_hash[h1]; sh1 != NULL; sh1 = sh1->shape_hash_next) {
/* we test the hash first so that the rest is done only if the
shapes really match */
if (sh1->hash == h &&
sh1->proto == sh->proto &&
sh1->prop_count == ((n = sh->prop_count) + 1)) {
for(i = 0; i < n; i++) {
if (unlikely(sh1->prop[i].atom != sh->prop[i].atom) ||
unlikely(sh1->prop[i].flags != sh->prop[i].flags))
goto next;
}
if (unlikely(sh1->prop[n].atom != atom) ||
unlikely(sh1->prop[n].flags != prop_flags))
goto next;
return sh1;
}
next: ;
}
return NULL;
}
|
O0
|
c
|
find_hashed_shape_prop:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movl %edx, 0x1c(%rsp)
movl %ecx, 0x18(%rsp)
movq 0x20(%rsp), %rax
movl 0x1c(%rax), %eax
movl %eax, 0xc(%rsp)
movl 0xc(%rsp), %edi
movl 0x1c(%rsp), %esi
callq 0x63bf0
movl %eax, 0xc(%rsp)
movl 0xc(%rsp), %edi
movl 0x18(%rsp), %esi
callq 0x63bf0
movl %eax, 0xc(%rsp)
movl 0xc(%rsp), %edi
movq 0x28(%rsp), %rax
movl 0x184(%rax), %esi
callq 0x63b80
movl %eax, 0x8(%rsp)
movq 0x28(%rsp), %rax
movq 0x190(%rax), %rax
movl 0x8(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
je 0x643df
movq 0x10(%rsp), %rax
movl 0x1c(%rax), %eax
cmpl 0xc(%rsp), %eax
jne 0x643c8
movq 0x10(%rsp), %rax
movq 0x38(%rax), %rax
movq 0x20(%rsp), %rcx
cmpq 0x38(%rcx), %rax
jne 0x643c8
movq 0x10(%rsp), %rax
movl 0x28(%rax), %eax
movq 0x20(%rsp), %rcx
movl 0x28(%rcx), %ecx
movl %ecx, (%rsp)
addl $0x1, %ecx
cmpl %ecx, %eax
jne 0x643c8
movl $0x0, 0x4(%rsp)
movl 0x4(%rsp), %eax
cmpl (%rsp), %eax
jae 0x6436f
movq 0x10(%rsp), %rax
movl 0x4(%rsp), %ecx
movl 0x44(%rax,%rcx,8), %eax
movq 0x20(%rsp), %rcx
movl 0x4(%rsp), %edx
cmpl 0x44(%rcx,%rdx,8), %eax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
jne 0x6435e
movq 0x10(%rsp), %rax
movl 0x4(%rsp), %ecx
movl 0x40(%rax,%rcx,8), %eax
shrl $0x1a, %eax
movq 0x20(%rsp), %rcx
movl 0x4(%rsp), %edx
movl 0x40(%rcx,%rdx,8), %ecx
shrl $0x1a, %ecx
cmpl %ecx, %eax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x64360
jmp 0x643ca
jmp 0x64362
movl 0x4(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x4(%rsp)
jmp 0x642f1
movq 0x10(%rsp), %rax
movl (%rsp), %ecx
movl 0x44(%rax,%rcx,8), %eax
cmpl 0x1c(%rsp), %eax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
jne 0x643ba
movq 0x10(%rsp), %rax
movl (%rsp), %ecx
movl 0x40(%rax,%rcx,8), %eax
shrl $0x1a, %eax
cmpl 0x18(%rsp), %eax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x643bc
jmp 0x643ca
movq 0x10(%rsp), %rax
movq %rax, 0x30(%rsp)
jmp 0x643e8
jmp 0x643ca
jmp 0x643cc
movq 0x10(%rsp), %rax
movq 0x30(%rax), %rax
movq %rax, 0x10(%rsp)
jmp 0x64295
movq $0x0, 0x30(%rsp)
movq 0x30(%rsp), %rax
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
|
find_hashed_shape_prop:
sub rsp, 38h
mov [rsp+38h+var_10], rdi
mov [rsp+38h+var_18], rsi
mov [rsp+38h+var_1C], edx
mov [rsp+38h+var_20], ecx
mov rax, [rsp+38h+var_18]
mov eax, [rax+1Ch]
mov [rsp+38h+var_2C], eax
mov edi, [rsp+38h+var_2C]
mov esi, [rsp+38h+var_1C]
call shape_hash
mov [rsp+38h+var_2C], eax
mov edi, [rsp+38h+var_2C]
mov esi, [rsp+38h+var_20]
call shape_hash
mov [rsp+38h+var_2C], eax
mov edi, [rsp+38h+var_2C]
mov rax, [rsp+38h+var_10]
mov esi, [rax+184h]
call get_shape_hash
mov [rsp+38h+var_30], eax
mov rax, [rsp+38h+var_10]
mov rax, [rax+190h]
mov ecx, [rsp+38h+var_30]
mov rax, [rax+rcx*8]
mov [rsp+38h+var_28], rax
loc_64295:
cmp [rsp+38h+var_28], 0
jz loc_643DF
mov rax, [rsp+38h+var_28]
mov eax, [rax+1Ch]
cmp eax, [rsp+38h+var_2C]
jnz loc_643C8
mov rax, [rsp+38h+var_28]
mov rax, [rax+38h]
mov rcx, [rsp+38h+var_18]
cmp rax, [rcx+38h]
jnz loc_643C8
mov rax, [rsp+38h+var_28]
mov eax, [rax+28h]
mov rcx, [rsp+38h+var_18]
mov ecx, [rcx+28h]
mov [rsp+38h+var_38], ecx
add ecx, 1
cmp eax, ecx
jnz loc_643C8
mov [rsp+38h+var_34], 0
loc_642F1:
mov eax, [rsp+38h+var_34]
cmp eax, [rsp+38h+var_38]
jnb short loc_6436F
mov rax, [rsp+38h+var_28]
mov ecx, [rsp+38h+var_34]
mov eax, [rax+rcx*8+44h]
mov rcx, [rsp+38h+var_18]
mov edx, [rsp+38h+var_34]
cmp eax, [rcx+rdx*8+44h]
setnz al
xor al, 0FFh
xor al, 0FFh
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jnz short loc_6435E
mov rax, [rsp+38h+var_28]
mov ecx, [rsp+38h+var_34]
mov eax, [rax+rcx*8+40h]
shr eax, 1Ah
mov rcx, [rsp+38h+var_18]
mov edx, [rsp+38h+var_34]
mov ecx, [rcx+rdx*8+40h]
shr ecx, 1Ah
cmp eax, ecx
setnz al
xor al, 0FFh
xor al, 0FFh
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_64360
loc_6435E:
jmp short loc_643CA
loc_64360:
jmp short $+2
loc_64362:
mov eax, [rsp+38h+var_34]
add eax, 1
mov [rsp+38h+var_34], eax
jmp short loc_642F1
loc_6436F:
mov rax, [rsp+38h+var_28]
mov ecx, [rsp+38h+var_38]
mov eax, [rax+rcx*8+44h]
cmp eax, [rsp+38h+var_1C]
setnz al
xor al, 0FFh
xor al, 0FFh
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jnz short loc_643BA
mov rax, [rsp+38h+var_28]
mov ecx, [rsp+38h+var_38]
mov eax, [rax+rcx*8+40h]
shr eax, 1Ah
cmp eax, [rsp+38h+var_20]
setnz al
xor al, 0FFh
xor al, 0FFh
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_643BC
loc_643BA:
jmp short loc_643CA
loc_643BC:
mov rax, [rsp+38h+var_28]
mov [rsp+38h+var_8], rax
jmp short loc_643E8
loc_643C8:
jmp short $+2
loc_643CA:
jmp short $+2
loc_643CC:
mov rax, [rsp+38h+var_28]
mov rax, [rax+30h]
mov [rsp+38h+var_28], rax
jmp loc_64295
loc_643DF:
mov [rsp+38h+var_8], 0
loc_643E8:
mov rax, [rsp+38h+var_8]
add rsp, 38h
retn
|
long long find_hashed_shape_prop(long long a1, long long a2, int a3, int a4)
{
int v4; // eax
unsigned int v6; // [rsp+0h] [rbp-38h]
unsigned int j; // [rsp+4h] [rbp-34h]
unsigned int v8; // [rsp+Ch] [rbp-2Ch]
long long i; // [rsp+10h] [rbp-28h]
v4 = shape_hash(*(_DWORD *)(a2 + 28), a3);
v8 = shape_hash(v4, a4);
for ( i = *(_QWORD *)(*(_QWORD *)(a1 + 400) + 8LL * (unsigned int)get_shape_hash(v8, *(_DWORD *)(a1 + 388)));
i;
i = *(_QWORD *)(i + 48) )
{
if ( *(_DWORD *)(i + 28) == v8 && *(_QWORD *)(i + 56) == *(_QWORD *)(a2 + 56) )
{
v6 = *(_DWORD *)(a2 + 40);
if ( *(_DWORD *)(i + 40) == v6 + 1 )
{
for ( j = 0; j < v6; ++j )
{
if ( *(_DWORD *)(i + 8LL * j + 68) != *(_DWORD *)(a2 + 8LL * j + 68)
|| *(_DWORD *)(i + 8LL * j + 64) >> 26 != *(_DWORD *)(a2 + 8LL * j + 64) >> 26 )
{
goto LABEL_16;
}
}
if ( *(_DWORD *)(i + 8LL * v6 + 68) == a3 && *(_DWORD *)(i + 8LL * v6 + 64) >> 26 == a4 )
return i;
}
}
LABEL_16:
;
}
return 0LL;
}
|
find_hashed_shape_prop:
SUB RSP,0x38
MOV qword ptr [RSP + 0x28],RDI
MOV qword ptr [RSP + 0x20],RSI
MOV dword ptr [RSP + 0x1c],EDX
MOV dword ptr [RSP + 0x18],ECX
MOV RAX,qword ptr [RSP + 0x20]
MOV EAX,dword ptr [RAX + 0x1c]
MOV dword ptr [RSP + 0xc],EAX
MOV EDI,dword ptr [RSP + 0xc]
MOV ESI,dword ptr [RSP + 0x1c]
CALL 0x00163bf0
MOV dword ptr [RSP + 0xc],EAX
MOV EDI,dword ptr [RSP + 0xc]
MOV ESI,dword ptr [RSP + 0x18]
CALL 0x00163bf0
MOV dword ptr [RSP + 0xc],EAX
MOV EDI,dword ptr [RSP + 0xc]
MOV RAX,qword ptr [RSP + 0x28]
MOV ESI,dword ptr [RAX + 0x184]
CALL 0x00163b80
MOV dword ptr [RSP + 0x8],EAX
MOV RAX,qword ptr [RSP + 0x28]
MOV RAX,qword ptr [RAX + 0x190]
MOV ECX,dword ptr [RSP + 0x8]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RSP + 0x10],RAX
LAB_00164295:
CMP qword ptr [RSP + 0x10],0x0
JZ 0x001643df
MOV RAX,qword ptr [RSP + 0x10]
MOV EAX,dword ptr [RAX + 0x1c]
CMP EAX,dword ptr [RSP + 0xc]
JNZ 0x001643c8
MOV RAX,qword ptr [RSP + 0x10]
MOV RAX,qword ptr [RAX + 0x38]
MOV RCX,qword ptr [RSP + 0x20]
CMP RAX,qword ptr [RCX + 0x38]
JNZ 0x001643c8
MOV RAX,qword ptr [RSP + 0x10]
MOV EAX,dword ptr [RAX + 0x28]
MOV RCX,qword ptr [RSP + 0x20]
MOV ECX,dword ptr [RCX + 0x28]
MOV dword ptr [RSP],ECX
ADD ECX,0x1
CMP EAX,ECX
JNZ 0x001643c8
MOV dword ptr [RSP + 0x4],0x0
LAB_001642f1:
MOV EAX,dword ptr [RSP + 0x4]
CMP EAX,dword ptr [RSP]
JNC 0x0016436f
MOV RAX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RSP + 0x4]
MOV EAX,dword ptr [RAX + RCX*0x8 + 0x44]
MOV RCX,qword ptr [RSP + 0x20]
MOV EDX,dword ptr [RSP + 0x4]
CMP EAX,dword ptr [RCX + RDX*0x8 + 0x44]
SETNZ AL
XOR AL,0xff
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JNZ 0x0016435e
MOV RAX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RSP + 0x4]
MOV EAX,dword ptr [RAX + RCX*0x8 + 0x40]
SHR EAX,0x1a
MOV RCX,qword ptr [RSP + 0x20]
MOV EDX,dword ptr [RSP + 0x4]
MOV ECX,dword ptr [RCX + RDX*0x8 + 0x40]
SHR ECX,0x1a
CMP EAX,ECX
SETNZ AL
XOR AL,0xff
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x00164360
LAB_0016435e:
JMP 0x001643ca
LAB_00164360:
JMP 0x00164362
LAB_00164362:
MOV EAX,dword ptr [RSP + 0x4]
ADD EAX,0x1
MOV dword ptr [RSP + 0x4],EAX
JMP 0x001642f1
LAB_0016436f:
MOV RAX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RSP]
MOV EAX,dword ptr [RAX + RCX*0x8 + 0x44]
CMP EAX,dword ptr [RSP + 0x1c]
SETNZ AL
XOR AL,0xff
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JNZ 0x001643ba
MOV RAX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RSP]
MOV EAX,dword ptr [RAX + RCX*0x8 + 0x40]
SHR EAX,0x1a
CMP EAX,dword ptr [RSP + 0x18]
SETNZ AL
XOR AL,0xff
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x001643bc
LAB_001643ba:
JMP 0x001643ca
LAB_001643bc:
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x30],RAX
JMP 0x001643e8
LAB_001643c8:
JMP 0x001643ca
LAB_001643ca:
JMP 0x001643cc
LAB_001643cc:
MOV RAX,qword ptr [RSP + 0x10]
MOV RAX,qword ptr [RAX + 0x30]
MOV qword ptr [RSP + 0x10],RAX
JMP 0x00164295
LAB_001643df:
MOV qword ptr [RSP + 0x30],0x0
LAB_001643e8:
MOV RAX,qword ptr [RSP + 0x30]
ADD RSP,0x38
RET
|
long find_hashed_shape_prop(long param_1,long param_2,int param_3,uint param_4)
{
int4 uVar1;
int iVar2;
uint uVar3;
uint local_34;
long local_28;
uVar1 = shape_hash(*(int4 *)(param_2 + 0x1c),param_3);
iVar2 = shape_hash(uVar1,param_4);
uVar3 = get_shape_hash(iVar2,*(int4 *)(param_1 + 0x184));
local_28 = *(long *)(*(long *)(param_1 + 400) + (ulong)uVar3 * 8);
do {
if (local_28 == 0) {
return 0;
}
if (((*(int *)(local_28 + 0x1c) == iVar2) &&
(*(long *)(local_28 + 0x38) == *(long *)(param_2 + 0x38))) &&
(uVar3 = *(uint *)(param_2 + 0x28), *(int *)(local_28 + 0x28) == uVar3 + 1)) {
for (local_34 = 0; local_34 < uVar3; local_34 = local_34 + 1) {
if ((*(int *)(local_28 + 0x44 + (ulong)local_34 * 8) !=
*(int *)(param_2 + 0x44 + (ulong)local_34 * 8)) ||
(*(uint *)(local_28 + 0x40 + (ulong)local_34 * 8) >> 0x1a !=
*(uint *)(param_2 + 0x40 + (ulong)local_34 * 8) >> 0x1a)) goto LAB_001643cc;
}
if ((*(int *)(local_28 + 0x44 + (ulong)uVar3 * 8) == param_3) &&
(*(uint *)(local_28 + 0x40 + (ulong)uVar3 * 8) >> 0x1a == param_4)) {
return local_28;
}
}
LAB_001643cc:
local_28 = *(long *)(local_28 + 0x30);
} while( true );
}
|
|
19,953
|
ma_store_var_pack_key
|
eloqsql/storage/maria/ma_search.c
|
void _ma_store_var_pack_key(MARIA_KEYDEF *keyinfo __attribute__((unused)),
register uchar *key_pos,
register MARIA_KEY_PARAM *s_temp)
{
uint length;
uchar *org_key_pos= key_pos;
if (s_temp->ref_length)
{
/* Packed against previous key */
store_pack_length(s_temp->pack_marker == 128,key_pos,s_temp->ref_length);
/* If not same key after */
if (s_temp->ref_length != s_temp->pack_marker)
store_key_length_inc(key_pos,s_temp->key_length);
}
else
{
/* Not packed against previous key */
store_pack_length(s_temp->pack_marker == 128,key_pos,s_temp->key_length);
}
bmove(key_pos, s_temp->key,
(length= s_temp->totlength - (uint) (key_pos-org_key_pos)));
key_pos+= length;
if (!s_temp->next_key_pos) /* No following key */
goto end;
if (s_temp->prev_length)
{
/* Extend next key because new key didn't have same prefix as prev key */
if (s_temp->part_of_prev_key)
{
store_pack_length(s_temp->pack_marker == 128,key_pos,
s_temp->part_of_prev_key);
store_key_length_inc(key_pos,s_temp->n_length);
}
else
{
s_temp->n_length+= s_temp->store_not_null;
store_pack_length(s_temp->pack_marker == 128,key_pos,
s_temp->n_length);
}
memcpy(key_pos, s_temp->prev_key, s_temp->prev_length);
key_pos+= s_temp->prev_length;
}
else if (s_temp->n_ref_length)
{
store_pack_length(s_temp->pack_marker == 128,key_pos,s_temp->n_ref_length);
if (s_temp->n_ref_length != s_temp->pack_marker)
{
/* Not identical key */
store_key_length_inc(key_pos,s_temp->n_length);
}
}
else
{
s_temp->n_length+= s_temp->store_not_null;
store_pack_length(s_temp->pack_marker == 128,key_pos,s_temp->n_length);
}
end:
s_temp->changed_length= (uint) (key_pos - org_key_pos);
}
|
O3
|
c
|
ma_store_var_pack_key:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %rdx
movl 0x20(%r14), %eax
movl 0x3c(%r14), %ecx
testl %eax, %eax
je 0x5846f
movl $0x1, %ebx
cmpl $0x80, %ecx
jne 0x58483
movq %rdx, %rcx
jmp 0x58492
movl 0x24(%r14), %eax
cmpl $0x80, %ecx
jne 0x584b3
leaq 0x1(%rdx), %rbx
movb %al, (%rdx)
jmp 0x584d6
leaq 0x1(%rdx), %rcx
movb %ah, (%rdx)
movl 0x20(%r14), %eax
movl $0x2, %ebx
addq %rdx, %rbx
movb %al, (%rcx)
movl 0x20(%r14), %eax
cmpl 0x3c(%r14), %eax
je 0x584d6
movl 0x24(%r14), %eax
cmpl $0xfe, %eax
ja 0x584c2
movb %al, (%rbx)
incq %rbx
jmp 0x584d6
movb %ah, (%rdx)
movb 0x24(%r14), %al
leaq 0x2(%rdx), %rbx
movb %al, 0x1(%rdx)
jmp 0x584d6
movb $-0x1, (%rbx)
movzwl 0x24(%r14), %eax
rolw $0x8, %ax
movw %ax, 0x1(%rbx)
addq $0x3, %rbx
movq (%r14), %rsi
movq %rdx, %r12
movl %edx, %r15d
subl %ebx, %r15d
addl 0x30(%r14), %r15d
movq %rbx, %rdi
movq %r15, %rdx
callq 0x29120
addq %r15, %rbx
cmpq $0x0, 0x10(%r14)
je 0x585c3
cmpl $0x0, 0x38(%r14)
je 0x58522
movl 0x34(%r14), %eax
testl %eax, %eax
je 0x58549
movl $0x1, %ecx
cmpl $0x80, 0x3c(%r14)
jne 0x5856f
movq %rbx, %rdx
jmp 0x5857e
movl 0x28(%r14), %eax
testl %eax, %eax
je 0x585d3
movl $0x1, %ecx
cmpl $0x80, 0x3c(%r14)
jne 0x585f9
movq %rbx, %rdx
jmp 0x58608
movsbl 0x48(%r14), %eax
addl 0x2c(%r14), %eax
movl %eax, 0x2c(%r14)
cmpl $0x80, 0x3c(%r14)
je 0x5858e
movb %ah, (%rbx)
movb 0x2c(%r14), %al
movb %al, 0x1(%rbx)
addq $0x2, %rbx
jmp 0x585a9
leaq 0x1(%rbx), %rdx
movb %ah, (%rbx)
movl 0x34(%r14), %eax
movl $0x2, %ecx
addq %rcx, %rbx
movb %al, (%rdx)
movl 0x2c(%r14), %eax
cmpl $0xfe, %eax
ja 0x58595
movb %al, (%rbx)
incq %rbx
jmp 0x585a9
movb $-0x1, (%rbx)
movzwl 0x2c(%r14), %eax
rolw $0x8, %ax
movw %ax, 0x1(%rbx)
addq $0x3, %rbx
movq %rbx, %r15
movq 0x8(%r14), %rsi
movl 0x38(%r14), %edx
movq %rbx, %rdi
callq 0x29090
movl 0x38(%r14), %ebx
addq %r15, %rbx
subl %r12d, %ebx
movl %ebx, 0x40(%r14)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movsbl 0x48(%r14), %eax
addl 0x2c(%r14), %eax
movl %eax, 0x2c(%r14)
cmpl $0x80, 0x3c(%r14)
je 0x58622
movb %ah, (%rbx)
movb 0x2c(%r14), %al
movb %al, 0x1(%rbx)
addq $0x2, %rbx
jmp 0x585c3
leaq 0x1(%rbx), %rdx
movb %ah, (%rbx)
movl 0x28(%r14), %eax
movl $0x2, %ecx
addq %rcx, %rbx
movb %al, (%rdx)
movl 0x28(%r14), %eax
cmpl 0x3c(%r14), %eax
je 0x585c3
movl 0x2c(%r14), %eax
cmpl $0xfe, %eax
ja 0x58629
movb %al, (%rbx)
incq %rbx
jmp 0x585c3
movb $-0x1, (%rbx)
movzwl 0x2c(%r14), %eax
rolw $0x8, %ax
movw %ax, 0x1(%rbx)
addq $0x3, %rbx
jmp 0x585c3
|
_ma_store_var_pack_key:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
mov r14, rdx
mov rdx, rsi
mov eax, [r14+20h]
mov ecx, [r14+3Ch]
test eax, eax
jz short loc_5846F
mov ebx, 1
cmp ecx, 80h
jnz short loc_58483
mov rcx, rdx
jmp short loc_58492
loc_5846F:
mov eax, [r14+24h]
cmp ecx, 80h
jnz short loc_584B3
lea rbx, [rdx+1]
mov [rdx], al
jmp short loc_584D6
loc_58483:
lea rcx, [rdx+1]
mov [rdx], ah
mov eax, [r14+20h]
mov ebx, 2
loc_58492:
add rbx, rdx
mov [rcx], al
mov eax, [r14+20h]
cmp eax, [r14+3Ch]
jz short loc_584D6
mov eax, [r14+24h]
cmp eax, 0FEh
ja short loc_584C2
mov [rbx], al
inc rbx
jmp short loc_584D6
loc_584B3:
mov [rdx], ah
mov al, [r14+24h]
lea rbx, [rdx+2]
mov [rdx+1], al
jmp short loc_584D6
loc_584C2:
mov byte ptr [rbx], 0FFh
movzx eax, word ptr [r14+24h]
rol ax, 8
mov [rbx+1], ax
add rbx, 3
loc_584D6:
mov rsi, [r14]
mov r12, rdx
mov r15d, edx
sub r15d, ebx
add r15d, [r14+30h]
mov rdi, rbx
mov rdx, r15
call _memmove
add rbx, r15
cmp qword ptr [r14+10h], 0
jz loc_585C3
cmp dword ptr [r14+38h], 0
jz short loc_58522
mov eax, [r14+34h]
test eax, eax
jz short loc_58549
mov ecx, 1
cmp dword ptr [r14+3Ch], 80h
jnz short loc_5856F
mov rdx, rbx
jmp short loc_5857E
loc_58522:
mov eax, [r14+28h]
test eax, eax
jz loc_585D3
mov ecx, 1
cmp dword ptr [r14+3Ch], 80h
jnz loc_585F9
mov rdx, rbx
jmp loc_58608
loc_58549:
movsx eax, byte ptr [r14+48h]
add eax, [r14+2Ch]
mov [r14+2Ch], eax
cmp dword ptr [r14+3Ch], 80h
jz short loc_5858E
mov [rbx], ah
mov al, [r14+2Ch]
mov [rbx+1], al
add rbx, 2
jmp short loc_585A9
loc_5856F:
lea rdx, [rbx+1]
mov [rbx], ah
mov eax, [r14+34h]
mov ecx, 2
loc_5857E:
add rbx, rcx
mov [rdx], al
mov eax, [r14+2Ch]
cmp eax, 0FEh
ja short loc_58595
loc_5858E:
mov [rbx], al
inc rbx
jmp short loc_585A9
loc_58595:
mov byte ptr [rbx], 0FFh
movzx eax, word ptr [r14+2Ch]
rol ax, 8
mov [rbx+1], ax
add rbx, 3
loc_585A9:
mov r15, rbx
mov rsi, [r14+8]
mov edx, [r14+38h]
mov rdi, rbx
call _memcpy
mov ebx, [r14+38h]
add rbx, r15
loc_585C3:
sub ebx, r12d
mov [r14+40h], ebx
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_585D3:
movsx eax, byte ptr [r14+48h]
add eax, [r14+2Ch]
mov [r14+2Ch], eax
cmp dword ptr [r14+3Ch], 80h
jz short loc_58622
mov [rbx], ah
mov al, [r14+2Ch]
mov [rbx+1], al
add rbx, 2
jmp short loc_585C3
loc_585F9:
lea rdx, [rbx+1]
mov [rbx], ah
mov eax, [r14+28h]
mov ecx, 2
loc_58608:
add rbx, rcx
mov [rdx], al
mov eax, [r14+28h]
cmp eax, [r14+3Ch]
jz short loc_585C3
mov eax, [r14+2Ch]
cmp eax, 0FEh
ja short loc_58629
loc_58622:
mov [rbx], al
inc rbx
jmp short loc_585C3
loc_58629:
mov byte ptr [rbx], 0FFh
movzx eax, word ptr [r14+2Ch]
rol ax, 8
mov [rbx+1], ax
add rbx, 3
jmp short loc_585C3
|
char ma_store_var_pack_key(long long a1, _BYTE *a2, long long a3)
{
int v4; // eax
int v5; // ecx
long long v6; // rbx
_BYTE *v7; // rcx
int v8; // eax
_BYTE *v9; // rbx
unsigned int v10; // eax
long long v11; // r15
unsigned int v12; // eax
_BYTE *v13; // rbx
int v14; // eax
long long v15; // rcx
_BYTE *v16; // rdx
int v17; // eax
long long v18; // rcx
_BYTE *v19; // rdx
unsigned int v20; // eax
v4 = *(_DWORD *)(a3 + 32);
v5 = *(_DWORD *)(a3 + 60);
if ( v4 )
{
v6 = 1LL;
if ( v5 == 128 )
{
v7 = a2;
}
else
{
v7 = a2 + 1;
*a2 = BYTE1(v4);
v4 = *(_DWORD *)(a3 + 32);
v6 = 2LL;
}
v9 = &a2[v6];
*v7 = v4;
if ( *(_DWORD *)(a3 + 32) != *(_DWORD *)(a3 + 60) )
{
v10 = *(_DWORD *)(a3 + 36);
if ( v10 > 0xFE )
{
*v9 = -1;
*(_WORD *)(v9 + 1) = __ROL2__(*(_WORD *)(a3 + 36), 8);
v9 += 3;
}
else
{
*v9++ = v10;
}
}
}
else
{
v8 = *(_DWORD *)(a3 + 36);
if ( v5 == 128 )
{
v9 = a2 + 1;
*a2 = v8;
}
else
{
*a2 = BYTE1(v8);
v9 = a2 + 2;
a2[1] = *(_BYTE *)(a3 + 36);
}
}
v11 = (unsigned int)(*(_DWORD *)(a3 + 48) + (_DWORD)a2 - (_DWORD)v9);
LOBYTE(v12) = memmove(v9, *(_QWORD *)a3, v11);
v13 = &v9[v11];
if ( *(_QWORD *)(a3 + 16) )
{
if ( *(_DWORD *)(a3 + 56) )
{
v14 = *(_DWORD *)(a3 + 52);
if ( v14 )
{
v15 = 1LL;
if ( *(_DWORD *)(a3 + 60) == 128 )
{
v16 = v13;
}
else
{
v16 = v13 + 1;
*v13 = BYTE1(v14);
v14 = *(_DWORD *)(a3 + 52);
v15 = 2LL;
}
v13 += v15;
*v16 = v14;
v20 = *(_DWORD *)(a3 + 44);
if ( v20 > 0xFE )
{
*v13 = -1;
*(_WORD *)(v13 + 1) = __ROL2__(*(_WORD *)(a3 + 44), 8);
v13 += 3;
goto LABEL_26;
}
}
else
{
v20 = *(_DWORD *)(a3 + 44) + *(char *)(a3 + 72);
*(_DWORD *)(a3 + 44) = v20;
if ( *(_DWORD *)(a3 + 60) != 128 )
{
*v13 = BYTE1(v20);
v13[1] = *(_BYTE *)(a3 + 44);
v13 += 2;
LABEL_26:
LOBYTE(v12) = memcpy(v13, *(_QWORD *)(a3 + 8), *(unsigned int *)(a3 + 56));
LODWORD(v13) = (_DWORD)v13 + *(_DWORD *)(a3 + 56);
goto LABEL_27;
}
}
*v13++ = v20;
goto LABEL_26;
}
v17 = *(_DWORD *)(a3 + 40);
if ( !v17 )
{
v12 = *(_DWORD *)(a3 + 44) + *(char *)(a3 + 72);
*(_DWORD *)(a3 + 44) = v12;
if ( *(_DWORD *)(a3 + 60) != 128 )
{
*v13 = BYTE1(v12);
LOBYTE(v12) = *(_BYTE *)(a3 + 44);
v13[1] = v12;
LODWORD(v13) = (_DWORD)v13 + 2;
goto LABEL_27;
}
LABEL_33:
*v13 = v12;
LODWORD(v13) = (_DWORD)v13 + 1;
goto LABEL_27;
}
v18 = 1LL;
if ( *(_DWORD *)(a3 + 60) == 128 )
{
v19 = v13;
}
else
{
v19 = v13 + 1;
*v13 = BYTE1(v17);
v17 = *(_DWORD *)(a3 + 40);
v18 = 2LL;
}
v13 += v18;
*v19 = v17;
v12 = *(_DWORD *)(a3 + 40);
if ( v12 != *(_DWORD *)(a3 + 60) )
{
v12 = *(_DWORD *)(a3 + 44);
if ( v12 > 0xFE )
{
*v13 = -1;
LOWORD(v12) = __ROL2__(*(_WORD *)(a3 + 44), 8);
*(_WORD *)(v13 + 1) = v12;
LODWORD(v13) = (_DWORD)v13 + 3;
goto LABEL_27;
}
goto LABEL_33;
}
}
LABEL_27:
*(_DWORD *)(a3 + 64) = (_DWORD)v13 - (_DWORD)a2;
return v12;
}
|
_ma_store_var_pack_key:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV R14,RDX
MOV RDX,RSI
MOV EAX,dword ptr [R14 + 0x20]
MOV ECX,dword ptr [R14 + 0x3c]
TEST EAX,EAX
JZ 0x0015846f
MOV EBX,0x1
CMP ECX,0x80
JNZ 0x00158483
MOV RCX,RDX
JMP 0x00158492
LAB_0015846f:
MOV EAX,dword ptr [R14 + 0x24]
CMP ECX,0x80
JNZ 0x001584b3
LEA RBX,[RDX + 0x1]
MOV byte ptr [RDX],AL
JMP 0x001584d6
LAB_00158483:
LEA RCX,[RDX + 0x1]
MOV byte ptr [RDX],AH
MOV EAX,dword ptr [R14 + 0x20]
MOV EBX,0x2
LAB_00158492:
ADD RBX,RDX
MOV byte ptr [RCX],AL
MOV EAX,dword ptr [R14 + 0x20]
CMP EAX,dword ptr [R14 + 0x3c]
JZ 0x001584d6
MOV EAX,dword ptr [R14 + 0x24]
CMP EAX,0xfe
JA 0x001584c2
MOV byte ptr [RBX],AL
INC RBX
JMP 0x001584d6
LAB_001584b3:
MOV byte ptr [RDX],AH
MOV AL,byte ptr [R14 + 0x24]
LEA RBX,[RDX + 0x2]
MOV byte ptr [RDX + 0x1],AL
JMP 0x001584d6
LAB_001584c2:
MOV byte ptr [RBX],0xff
MOVZX EAX,word ptr [R14 + 0x24]
ROL AX,0x8
MOV word ptr [RBX + 0x1],AX
ADD RBX,0x3
LAB_001584d6:
MOV RSI,qword ptr [R14]
MOV R12,RDX
MOV R15D,EDX
SUB R15D,EBX
ADD R15D,dword ptr [R14 + 0x30]
MOV RDI,RBX
MOV RDX,R15
CALL 0x00129120
ADD RBX,R15
CMP qword ptr [R14 + 0x10],0x0
JZ 0x001585c3
CMP dword ptr [R14 + 0x38],0x0
JZ 0x00158522
MOV EAX,dword ptr [R14 + 0x34]
TEST EAX,EAX
JZ 0x00158549
MOV ECX,0x1
CMP dword ptr [R14 + 0x3c],0x80
JNZ 0x0015856f
MOV RDX,RBX
JMP 0x0015857e
LAB_00158522:
MOV EAX,dword ptr [R14 + 0x28]
TEST EAX,EAX
JZ 0x001585d3
MOV ECX,0x1
CMP dword ptr [R14 + 0x3c],0x80
JNZ 0x001585f9
MOV RDX,RBX
JMP 0x00158608
LAB_00158549:
MOVSX EAX,byte ptr [R14 + 0x48]
ADD EAX,dword ptr [R14 + 0x2c]
MOV dword ptr [R14 + 0x2c],EAX
CMP dword ptr [R14 + 0x3c],0x80
JZ 0x0015858e
MOV byte ptr [RBX],AH
MOV AL,byte ptr [R14 + 0x2c]
MOV byte ptr [RBX + 0x1],AL
ADD RBX,0x2
JMP 0x001585a9
LAB_0015856f:
LEA RDX,[RBX + 0x1]
MOV byte ptr [RBX],AH
MOV EAX,dword ptr [R14 + 0x34]
MOV ECX,0x2
LAB_0015857e:
ADD RBX,RCX
MOV byte ptr [RDX],AL
MOV EAX,dword ptr [R14 + 0x2c]
CMP EAX,0xfe
JA 0x00158595
LAB_0015858e:
MOV byte ptr [RBX],AL
INC RBX
JMP 0x001585a9
LAB_00158595:
MOV byte ptr [RBX],0xff
MOVZX EAX,word ptr [R14 + 0x2c]
ROL AX,0x8
MOV word ptr [RBX + 0x1],AX
ADD RBX,0x3
LAB_001585a9:
MOV R15,RBX
MOV RSI,qword ptr [R14 + 0x8]
MOV EDX,dword ptr [R14 + 0x38]
MOV RDI,RBX
CALL 0x00129090
MOV EBX,dword ptr [R14 + 0x38]
ADD RBX,R15
LAB_001585c3:
SUB EBX,R12D
MOV dword ptr [R14 + 0x40],EBX
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_001585d3:
MOVSX EAX,byte ptr [R14 + 0x48]
ADD EAX,dword ptr [R14 + 0x2c]
MOV dword ptr [R14 + 0x2c],EAX
CMP dword ptr [R14 + 0x3c],0x80
JZ 0x00158622
MOV byte ptr [RBX],AH
MOV AL,byte ptr [R14 + 0x2c]
MOV byte ptr [RBX + 0x1],AL
ADD RBX,0x2
JMP 0x001585c3
LAB_001585f9:
LEA RDX,[RBX + 0x1]
MOV byte ptr [RBX],AH
MOV EAX,dword ptr [R14 + 0x28]
MOV ECX,0x2
LAB_00158608:
ADD RBX,RCX
MOV byte ptr [RDX],AL
MOV EAX,dword ptr [R14 + 0x28]
CMP EAX,dword ptr [R14 + 0x3c]
JZ 0x001585c3
MOV EAX,dword ptr [R14 + 0x2c]
CMP EAX,0xfe
JA 0x00158629
LAB_00158622:
MOV byte ptr [RBX],AL
INC RBX
JMP 0x001585c3
LAB_00158629:
MOV byte ptr [RBX],0xff
MOVZX EAX,word ptr [R14 + 0x2c]
ROL AX,0x8
MOV word ptr [RBX + 0x1],AX
ADD RBX,0x3
JMP 0x001585c3
|
void _ma_store_var_pack_key(int8 param_1,int1 *param_2,int8 *param_3)
{
int iVar1;
uint uVar2;
int1 *puVar3;
long lVar4;
int1 *puVar5;
ulong __n;
iVar1 = *(int *)(param_3 + 4);
if (iVar1 == 0) {
if (*(int *)((long)param_3 + 0x3c) == 0x80) {
puVar5 = param_2 + 1;
*param_2 = (char)*(int4 *)((long)param_3 + 0x24);
}
else {
*param_2 = (char)((uint)*(int4 *)((long)param_3 + 0x24) >> 8);
puVar5 = param_2 + 2;
param_2[1] = *(int1 *)((long)param_3 + 0x24);
}
}
else {
lVar4 = 1;
puVar3 = param_2;
if (*(int *)((long)param_3 + 0x3c) != 0x80) {
*param_2 = (char)((uint)iVar1 >> 8);
iVar1 = *(int *)(param_3 + 4);
lVar4 = 2;
puVar3 = param_2 + 1;
}
puVar5 = param_2 + lVar4;
*puVar3 = (char)iVar1;
if (*(int *)(param_3 + 4) != *(int *)((long)param_3 + 0x3c)) {
if (*(uint *)((long)param_3 + 0x24) < 0xff) {
*puVar5 = (char)*(uint *)((long)param_3 + 0x24);
puVar5 = puVar5 + 1;
}
else {
*puVar5 = 0xff;
*(ushort *)(puVar5 + 1) =
*(ushort *)((long)param_3 + 0x24) << 8 | *(ushort *)((long)param_3 + 0x24) >> 8;
puVar5 = puVar5 + 3;
}
}
}
__n = (ulong)(uint)(((int)param_2 - (int)puVar5) + *(int *)(param_3 + 6));
memmove(puVar5,(void *)*param_3,__n);
puVar5 = puVar5 + __n;
if (param_3[2] == 0) goto LAB_001585c3;
if (*(int *)(param_3 + 7) == 0) {
iVar1 = *(int *)(param_3 + 5);
if (iVar1 == 0) {
uVar2 = (int)*(char *)(param_3 + 9) + *(int *)((long)param_3 + 0x2c);
*(uint *)((long)param_3 + 0x2c) = uVar2;
if (*(int *)((long)param_3 + 0x3c) != 0x80) {
*puVar5 = (char)(uVar2 >> 8);
puVar5[1] = *(int1 *)((long)param_3 + 0x2c);
puVar5 = puVar5 + 2;
goto LAB_001585c3;
}
}
else {
lVar4 = 1;
puVar3 = puVar5;
if (*(int *)((long)param_3 + 0x3c) != 0x80) {
*puVar5 = (char)((uint)iVar1 >> 8);
iVar1 = *(int *)(param_3 + 5);
lVar4 = 2;
puVar3 = puVar5 + 1;
}
puVar5 = puVar5 + lVar4;
*puVar3 = (char)iVar1;
if (*(int *)(param_3 + 5) == *(int *)((long)param_3 + 0x3c)) goto LAB_001585c3;
uVar2 = *(uint *)((long)param_3 + 0x2c);
if (0xfe < uVar2) {
*puVar5 = 0xff;
*(ushort *)(puVar5 + 1) =
*(ushort *)((long)param_3 + 0x2c) << 8 | *(ushort *)((long)param_3 + 0x2c) >> 8;
puVar5 = puVar5 + 3;
goto LAB_001585c3;
}
}
*puVar5 = (char)uVar2;
puVar5 = puVar5 + 1;
goto LAB_001585c3;
}
iVar1 = *(int *)((long)param_3 + 0x34);
if (iVar1 == 0) {
uVar2 = (int)*(char *)(param_3 + 9) + *(int *)((long)param_3 + 0x2c);
*(uint *)((long)param_3 + 0x2c) = uVar2;
if (*(int *)((long)param_3 + 0x3c) == 0x80) goto LAB_0015858e;
*puVar5 = (char)(uVar2 >> 8);
puVar5[1] = *(int1 *)((long)param_3 + 0x2c);
puVar5 = puVar5 + 2;
}
else {
lVar4 = 1;
puVar3 = puVar5;
if (*(int *)((long)param_3 + 0x3c) != 0x80) {
*puVar5 = (char)((uint)iVar1 >> 8);
iVar1 = *(int *)((long)param_3 + 0x34);
lVar4 = 2;
puVar3 = puVar5 + 1;
}
puVar5 = puVar5 + lVar4;
*puVar3 = (char)iVar1;
uVar2 = *(uint *)((long)param_3 + 0x2c);
if (uVar2 < 0xff) {
LAB_0015858e:
*puVar5 = (char)uVar2;
puVar5 = puVar5 + 1;
}
else {
*puVar5 = 0xff;
*(ushort *)(puVar5 + 1) =
*(ushort *)((long)param_3 + 0x2c) << 8 | *(ushort *)((long)param_3 + 0x2c) >> 8;
puVar5 = puVar5 + 3;
}
}
memcpy(puVar5,(void *)param_3[1],(ulong)*(uint *)(param_3 + 7));
puVar5 = puVar5 + *(uint *)(param_3 + 7);
LAB_001585c3:
*(int *)(param_3 + 8) = (int)puVar5 - (int)param_2;
return;
}
|
|
19,954
|
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>::json_value::json_value(nlohmann::json_abi_v3_11_3::detail::value_t)
|
monkey531[P]llama/common/json.hpp
|
json_value(value_t t)
{
switch (t)
{
case value_t::object:
{
object = create<object_t>();
break;
}
case value_t::array:
{
array = create<array_t>();
break;
}
case value_t::string:
{
string = create<string_t>("");
break;
}
case value_t::binary:
{
binary = create<binary_t>();
break;
}
case value_t::boolean:
{
boolean = static_cast<boolean_t>(false);
break;
}
case value_t::number_integer:
{
number_integer = static_cast<number_integer_t>(0);
break;
}
case value_t::number_unsigned:
{
number_unsigned = static_cast<number_unsigned_t>(0);
break;
}
case value_t::number_float:
{
number_float = static_cast<number_float_t>(0.0);
break;
}
case value_t::null:
{
object = nullptr; // silence warning, see #821
break;
}
case value_t::discarded:
default:
{
object = nullptr; // silence warning, see #821
if (JSON_HEDLEY_UNLIKELY(t == value_t::null))
{
JSON_THROW(other_error::create(500, "961c151d2e87f2686a955a9be24d316f1362bf21 3.11.3", nullptr)); // LCOV_EXCL_LINE
}
break;
}
}
}
|
O0
|
cpp
|
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::json_value::json_value(nlohmann::json_abi_v3_11_3::detail::value_t):
subq $0x68, %rsp
movb %sil, %al
movq %rdi, 0x60(%rsp)
movb %al, 0x5f(%rsp)
movq 0x60(%rsp), %rax
movq %rax, 0x10(%rsp)
movzbl 0x5f(%rsp), %eax
movq %rax, 0x18(%rsp)
subq $0x9, %rax
ja 0xa7461
movq 0x18(%rsp), %rax
leaq 0x166342(%rip), %rcx # 0x20d6ec
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
callq 0xa7550
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq %rcx, (%rax)
jmp 0xa753b
callq 0xa7650
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq %rcx, (%rax)
jmp 0xa753b
leaq 0x16c13b(%rip), %rdi # 0x21351f
callq 0xa7750
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq %rcx, (%rax)
jmp 0xa753b
callq 0xa7860
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq %rcx, (%rax)
jmp 0xa753b
movq 0x10(%rsp), %rax
movb $0x0, (%rax)
jmp 0xa753b
movq 0x10(%rsp), %rax
movq $0x0, (%rax)
jmp 0xa753b
movq 0x10(%rsp), %rax
movq $0x0, (%rax)
jmp 0xa753b
movq 0x10(%rsp), %rax
xorps %xmm0, %xmm0
movsd %xmm0, (%rax)
jmp 0xa753b
movq 0x10(%rsp), %rax
movq $0x0, (%rax)
jmp 0xa753b
jmp 0xa7461
movq 0x10(%rsp), %rax
movq $0x0, (%rax)
cmpb $0x0, 0x5f(%rsp)
sete %al
xorb $-0x1, %al
xorb $-0x1, %al
testb $0x1, %al
jne 0xa7482
jmp 0xa7539
movb $0x1, 0x23(%rsp)
movl $0x20, %edi
callq 0x5b740
movq %rax, (%rsp)
leaq 0x37(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x5c2c0
movq 0x8(%rsp), %rdx
leaq 0x16c174(%rip), %rsi # 0x213624
leaq 0x38(%rsp), %rdi
callq 0x63990
jmp 0xa74bc
movq (%rsp), %rdi
xorl %eax, %eax
movl %eax, %ecx
movl $0x1f4, %esi # imm = 0x1F4
leaq 0x38(%rsp), %rdx
callq 0xa7960
jmp 0xa74d5
movq (%rsp), %rdi
movb $0x0, 0x23(%rsp)
leaq 0x2017bb(%rip), %rsi # 0x2a8ca0
leaq 0x614(%rip), %rdx # 0xa7b00
callq 0x5bc30
jmp 0xa754a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x28(%rsp)
movl %eax, 0x24(%rsp)
jmp 0xa751b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x28(%rsp)
movl %eax, 0x24(%rsp)
leaq 0x38(%rsp), %rdi
callq 0x5c7f8
leaq 0x37(%rsp), %rdi
callq 0x5c7d0
testb $0x1, 0x23(%rsp)
jne 0xa752e
jmp 0xa7537
movq (%rsp), %rdi
callq 0x5c130
jmp 0xa7540
jmp 0xa753b
addq $0x68, %rsp
retq
movq 0x28(%rsp), %rdi
callq 0x5bd10
nopw (%rax,%rax)
|
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE10json_valueC2ENS0_6detail7value_tE:
sub rsp, 68h
mov al, sil
mov qword ptr [rsp+68h+var_8], rdi; int
mov [rsp+68h+var_9], al
mov rax, qword ptr [rsp+68h+var_8]
mov qword ptr [rsp+68h+var_58], rax; int
movzx eax, [rsp+68h+var_9]
mov qword ptr [rsp+68h+var_50], rax; char
sub rax, 9; switch 10 cases
ja def_A73B1; jumptable 00000000000A73B1 default case
mov rax, qword ptr [rsp+68h+var_50]
lea rcx, jpt_A73B1
movsxd rax, ds:(jpt_A73B1 - 20D6ECh)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_A73B3:
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createINS2_IS9_SD_St4lessIvESaISt4pairIKS9_SD_EEEEJEEEPT_DpOT0_; jumptable 00000000000A73B1 case 1
mov rcx, rax
mov rax, qword ptr [rsp+68h+var_58]
mov [rax], rcx
jmp loc_A753B
loc_A73C8:
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createIS3_ISD_SaISD_EEJEEEPT_DpOT0_; jumptable 00000000000A73B1 case 2
mov rcx, rax
mov rax, qword ptr [rsp+68h+var_58]
mov [rax], rcx
jmp loc_A753B
loc_A73DD:
lea rdi, aExampleSpecifi+27h; jumptable 00000000000A73B1 case 3
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createIS9_JRA1_KcEEEPT_DpOT0_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::create<std::string,char const(&)[1]>(char const(&)[1] &&)
mov rcx, rax
mov rax, qword ptr [rsp+68h+var_58]
mov [rax], rcx
jmp loc_A753B
loc_A73F9:
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createINS0_27byte_container_with_subtypeISC_EEJEEEPT_DpOT0_; jumptable 00000000000A73B1 case 8
mov rcx, rax
mov rax, qword ptr [rsp+68h+var_58]
mov [rax], rcx
jmp loc_A753B
loc_A740E:
mov rax, qword ptr [rsp+68h+var_58]; jumptable 00000000000A73B1 case 4
mov byte ptr [rax], 0
jmp loc_A753B
loc_A741B:
mov rax, qword ptr [rsp+68h+var_58]; jumptable 00000000000A73B1 case 5
mov qword ptr [rax], 0
jmp loc_A753B
loc_A742C:
mov rax, qword ptr [rsp+68h+var_58]; jumptable 00000000000A73B1 case 6
mov qword ptr [rax], 0
jmp loc_A753B
loc_A743D:
mov rax, qword ptr [rsp+68h+var_58]; jumptable 00000000000A73B1 case 7
xorps xmm0, xmm0
movsd qword ptr [rax], xmm0
jmp loc_A753B
loc_A744E:
mov rax, qword ptr [rsp+68h+var_58]; jumptable 00000000000A73B1 case 0
mov qword ptr [rax], 0
jmp loc_A753B
loc_A745F:
jmp short $+2; jumptable 00000000000A73B1 case 9
def_A73B1:
mov rax, qword ptr [rsp+68h+var_58]; jumptable 00000000000A73B1 default case
mov qword ptr [rax], 0
cmp [rsp+68h+var_9], 0
setz al
xor al, 0FFh
xor al, 0FFh
test al, 1
jnz short loc_A7482
jmp loc_A7539
loc_A7482:
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, a961c151d2e87f2; "961c151d2e87f2686a955a9be24d316f1362bf2"...
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_A74BC:
mov rdi, [rsp+68h+var_68]; int
xor eax, eax
mov ecx, eax
mov esi, 1F4h
lea rdx, [rsp+68h+var_31+1]
call _ZN8nlohmann16json_abi_v3_11_36detail11other_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_
jmp short $+2
loc_A74D5:
mov rdi, [rsp+68h+var_68]; void *
mov [rsp+68h+var_45], 0
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail11other_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail11other_errorD2Ev; void (*)(void *)
call ___cxa_throw
jmp short loc_A754A
mov rcx, rax
mov eax, edx
mov [rsp+arg_20], rcx
mov [rsp+arg_1C], eax
jmp short loc_A751B
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_A751B:
lea rdi, [rsp+arg_2F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
test [rsp+arg_1B], 1
jnz short loc_A752E
jmp short loc_A7537
loc_A752E:
mov rdi, [rsp+0]; void *
call ___cxa_free_exception
loc_A7537:
jmp short loc_A7540
loc_A7539:
jmp short $+2
loc_A753B:
add rsp, 68h
retn
loc_A7540:
mov rdi, [rsp+arg_20]
call __Unwind_Resume
loc_A754A:
nop word ptr [rax+rax+00h]
|
json_value:
SUB RSP,0x68
MOV AL,SIL
MOV qword ptr [RSP + 0x60],RDI
MOV byte ptr [RSP + 0x5f],AL
MOV RAX,qword ptr [RSP + 0x60]
MOV qword ptr [RSP + 0x10],RAX
MOVZX EAX,byte ptr [RSP + 0x5f]
MOV qword ptr [RSP + 0x18],RAX
SUB RAX,0x9
JA 0x001a7461
MOV RAX,qword ptr [RSP + 0x18]
LEA RCX,[0x30d6ec]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_1:
CALL 0x001a7550
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RAX],RCX
JMP 0x001a753b
caseD_2:
CALL 0x001a7650
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RAX],RCX
JMP 0x001a753b
caseD_3:
LEA RDI,[0x31351f]
CALL 0x001a7750
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RAX],RCX
JMP 0x001a753b
caseD_8:
CALL 0x001a7860
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RAX],RCX
JMP 0x001a753b
caseD_4:
MOV RAX,qword ptr [RSP + 0x10]
MOV byte ptr [RAX],0x0
JMP 0x001a753b
caseD_5:
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RAX],0x0
JMP 0x001a753b
caseD_6:
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RAX],0x0
JMP 0x001a753b
caseD_7:
MOV RAX,qword ptr [RSP + 0x10]
XORPS XMM0,XMM0
MOVSD qword ptr [RAX],XMM0
JMP 0x001a753b
caseD_0:
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RAX],0x0
JMP 0x001a753b
caseD_9:
JMP 0x001a7461
default:
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RAX],0x0
CMP byte ptr [RSP + 0x5f],0x0
SETZ AL
XOR AL,0xff
XOR AL,0xff
TEST AL,0x1
JNZ 0x001a7482
JMP 0x001a7539
LAB_001a7482:
MOV byte ptr [RSP + 0x23],0x1
MOV EDI,0x20
CALL 0x0015b740
MOV qword ptr [RSP],RAX
LEA RDI,[RSP + 0x37]
MOV qword ptr [RSP + 0x8],RDI
CALL 0x0015c2c0
MOV RDX,qword ptr [RSP + 0x8]
LAB_001a74a9:
LEA RSI,[0x313624]
LEA RDI,[RSP + 0x38]
CALL 0x00163990
JMP 0x001a74bc
LAB_001a74bc:
MOV RDI,qword ptr [RSP]
XOR EAX,EAX
MOV ECX,EAX
MOV ESI,0x1f4
LEA RDX,[RSP + 0x38]
CALL 0x001a7960
JMP 0x001a74d5
LAB_001a74d5:
MOV RDI,qword ptr [RSP]
MOV byte ptr [RSP + 0x23],0x0
LEA RSI,[0x3a8ca0]
LEA RDX,[0x1a7b00]
CALL 0x0015bc30
LAB_001a7539:
JMP 0x001a753b
LAB_001a753b:
ADD RSP,0x68
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>::json_value::json_value(nlohmann::json_abi_v3_11_3::detail::value_t) */
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>
::json_value::json_value(json_value *this,char param_2)
{
ordered_map *poVar1;
vector *pvVar2;
string *psVar3;
byte_container_with_subtype *pbVar4;
int8 uVar5;
allocator local_31;
string local_30 [39];
char local_9;
json_value *local_8;
local_9 = param_2;
local_8 = this;
switch(param_2) {
case '\0':
*(int8 *)this = 0;
break;
case '\x01':
poVar1 = create<nlohmann::json_abi_v3_11_3::ordered_map<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>,std::less<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>>>>>
();
*(ordered_map **)this = poVar1;
break;
case '\x02':
pvVar2 = create<std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
();
*(vector **)this = pvVar2;
break;
case '\x03':
psVar3 = create<std::__cxx11::string,char_const(&)[1]>("");
*(string **)this = psVar3;
break;
case '\x04':
*this = (json_value)0x0;
break;
case '\x05':
*(int8 *)this = 0;
break;
case '\x06':
*(int8 *)this = 0;
break;
case '\a':
*(int8 *)this = 0;
break;
case '\b':
pbVar4 = create<nlohmann::json_abi_v3_11_3::byte_container_with_subtype<std::vector<unsigned_char,std::allocator<unsigned_char>>>>
();
*(byte_container_with_subtype **)this = pbVar4;
break;
case '\t':
default:
*(int8 *)this = 0;
if (param_2 == '\0') {
uVar5 = __cxa_allocate_exception(0x20);
std::allocator<char>::allocator();
/* try { // try from 001a74a9 to 001a74b9 has its CatchHandler @ 001a74f3 */
std::__cxx11::string::string<std::allocator<char>>
(local_30,"961c151d2e87f2686a955a9be24d316f1362bf21 3.11.3",&local_31);
/* try { // try from 001a74bc to 001a74f0 has its CatchHandler @ 001a7503 */
_ZN8nlohmann16json_abi_v3_11_36detail11other_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_
(uVar5,500,local_30,0);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar5,&detail::other_error::typeinfo,detail::other_error::~other_error);
}
}
return;
}
|
||
19,955
|
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>::json_value::json_value(nlohmann::json_abi_v3_11_3::detail::value_t)
|
monkey531[P]llama/common/json.hpp
|
json_value(value_t t)
{
switch (t)
{
case value_t::object:
{
object = create<object_t>();
break;
}
case value_t::array:
{
array = create<array_t>();
break;
}
case value_t::string:
{
string = create<string_t>("");
break;
}
case value_t::binary:
{
binary = create<binary_t>();
break;
}
case value_t::boolean:
{
boolean = static_cast<boolean_t>(false);
break;
}
case value_t::number_integer:
{
number_integer = static_cast<number_integer_t>(0);
break;
}
case value_t::number_unsigned:
{
number_unsigned = static_cast<number_unsigned_t>(0);
break;
}
case value_t::number_float:
{
number_float = static_cast<number_float_t>(0.0);
break;
}
case value_t::null:
{
object = nullptr; // silence warning, see #821
break;
}
case value_t::discarded:
default:
{
object = nullptr; // silence warning, see #821
if (JSON_HEDLEY_UNLIKELY(t == value_t::null))
{
JSON_THROW(other_error::create(500, "961c151d2e87f2686a955a9be24d316f1362bf21 3.11.3", nullptr)); // LCOV_EXCL_LINE
}
break;
}
}
}
|
O2
|
cpp
|
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::json_value::json_value(nlohmann::json_abi_v3_11_3::detail::value_t):
pushq %rbx
movq %rdi, %rbx
cmpl $0x8, %esi
ja 0x40357
movl %esi, %eax
leaq 0x6c4f2(%rip), %rcx # 0xac840
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
andq $0x0, (%rbx)
jmp 0x40386
callq 0x40388
jmp 0x40383
movb $0x0, (%rbx)
jmp 0x40386
callq 0x403ca
jmp 0x40383
leaq 0x71a38(%rip), %rdi # 0xb1daf
callq 0x4040c
jmp 0x40383
callq 0x4049a
movq %rax, (%rbx)
popq %rbx
retq
|
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE10json_valueC2ENS0_6detail7value_tE:
push rbx
mov rbx, rdi
cmp esi, 8; switch 9 cases
ja short def_40355; jumptable 0000000000040355 default case, cases 0,5-7
mov eax, esi
lea rcx, jpt_40355
movsxd rax, ds:(jpt_40355 - 0AC840h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
def_40355:
and qword ptr [rbx], 0; jumptable 0000000000040355 default case, cases 0,5-7
jmp short loc_40386
loc_4035D:
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createINS2_IS9_SD_St4lessIvESaISt4pairIKS9_SD_EEEEJEEEPT_DpOT0_; jumptable 0000000000040355 case 1
jmp short loc_40383
loc_40364:
mov byte ptr [rbx], 0; jumptable 0000000000040355 case 4
jmp short loc_40386
loc_40369:
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createIS3_ISD_SaISD_EEJEEEPT_DpOT0_; jumptable 0000000000040355 case 2
jmp short loc_40383
loc_40370:
lea rdi, aErrorWhileHand_0+34h; jumptable 0000000000040355 case 3
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createIS9_JRA1_KcEEEPT_DpOT0_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::create<std::string,char const(&)[1]>(char const(&)[1] &&)
jmp short loc_40383
loc_4037E:
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6createINS0_27byte_container_with_subtypeISC_EEJEEEPT_DpOT0_; jumptable 0000000000040355 case 8
loc_40383:
mov [rbx], rax
loc_40386:
pop rbx
retn
|
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::json_value::json_value(
_BYTE *a1,
unsigned int a2)
{
long long result; // rax
result = a2;
switch ( a2 )
{
case 1u:
result = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::create<nlohmann::json_abi_v3_11_3::ordered_map<std::string,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::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>>();
goto LABEL_8;
case 2u:
result = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::create<std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>();
goto LABEL_8;
case 3u:
result = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::create<std::string,char const(&)[1]>("");
goto LABEL_8;
case 4u:
*a1 = 0;
return result;
case 8u:
result = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::create<nlohmann::json_abi_v3_11_3::byte_container_with_subtype<std::vector<unsigned char>>>();
LABEL_8:
*(_QWORD *)a1 = result;
break;
default:
*(_QWORD *)a1 = 0LL;
break;
}
return result;
}
|
json_value:
PUSH RBX
MOV RBX,RDI
CMP ESI,0x8
JA 0x00140357
MOV EAX,ESI
LEA RCX,[0x1ac840]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_0:
AND qword ptr [RBX],0x0
JMP 0x00140386
caseD_1:
CALL 0x00140388
JMP 0x00140383
caseD_4:
MOV byte ptr [RBX],0x0
JMP 0x00140386
caseD_2:
CALL 0x001403ca
JMP 0x00140383
caseD_3:
LEA RDI,[0x1b1daf]
CALL 0x0014040c
JMP 0x00140383
caseD_8:
CALL 0x0014049a
LAB_00140383:
MOV qword ptr [RBX],RAX
LAB_00140386:
POP RBX
RET
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>::json_value::json_value(nlohmann::json_abi_v3_11_3::detail::value_t) */
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>
::json_value::json_value(json_value *this,int4 param_2)
{
ordered_map *poVar1;
switch(param_2) {
default:
*(int8 *)this = 0;
return;
case 1:
poVar1 = create<nlohmann::json_abi_v3_11_3::ordered_map<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>,std::less<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>>>>>
();
break;
case 2:
poVar1 = (ordered_map *)
create<std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
();
break;
case 3:
poVar1 = (ordered_map *)create<std::__cxx11::string,char_const(&)[1]>("");
break;
case 4:
*this = (json_value)0x0;
return;
case 8:
poVar1 = (ordered_map *)
create<nlohmann::json_abi_v3_11_3::byte_container_with_subtype<std::vector<unsigned_char,std::allocator<unsigned_char>>>>
();
}
*(ordered_map **)this = poVar1;
return;
}
|
|
19,956
|
remove_end_comment
|
eloqsql/mysys/my_default.c
|
static char *remove_end_comment(char *ptr)
{
char quote= 0; /* we are inside quote marks */
char escape= 0; /* symbol is protected by escape chagacter */
for (; *ptr; ptr++)
{
if ((*ptr == '\'' || *ptr == '\"') && !escape)
{
if (!quote)
quote= *ptr;
else if (quote == *ptr)
quote= 0;
}
/* We are not inside a string */
if (!quote && *ptr == '#')
{
*ptr= 0;
return ptr;
}
escape= (quote && *ptr == '\\' && !escape);
}
return ptr;
}
|
O0
|
c
|
remove_end_comment:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movb $0x0, -0x11(%rbp)
movb $0x0, -0x12(%rbp)
movq -0x10(%rbp), %rax
cmpb $0x0, (%rax)
je 0x3b01d
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x27, %eax
je 0x3af85
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x22, %eax
jne 0x3afb3
cmpb $0x0, -0x12(%rbp)
jne 0x3afb3
cmpb $0x0, -0x11(%rbp)
jne 0x3af9c
movq -0x10(%rbp), %rax
movb (%rax), %al
movb %al, -0x11(%rbp)
jmp 0x3afb1
movsbl -0x11(%rbp), %eax
movq -0x10(%rbp), %rcx
movsbl (%rcx), %ecx
cmpl %ecx, %eax
jne 0x3afaf
movb $0x0, -0x11(%rbp)
jmp 0x3afb1
jmp 0x3afb3
cmpb $0x0, -0x11(%rbp)
jne 0x3afd6
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x23, %eax
jne 0x3afd6
movq -0x10(%rbp), %rax
movb $0x0, (%rax)
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x3b025
movsbl -0x11(%rbp), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x13(%rbp)
je 0x3b001
movq -0x10(%rbp), %rax
movsbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x5c, %ecx
movb %al, -0x13(%rbp)
jne 0x3b001
cmpb $0x0, -0x12(%rbp)
setne %al
xorb $-0x1, %al
movb %al, -0x13(%rbp)
movb -0x13(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x12(%rbp)
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x3af60
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
popq %rbp
retq
nopl (%rax,%rax)
|
remove_end_comment:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_11], 0
mov [rbp+var_12], 0
loc_3AF60:
mov rax, [rbp+var_10]
cmp byte ptr [rax], 0
jz loc_3B01D
mov rax, [rbp+var_10]
movsx eax, byte ptr [rax]
cmp eax, 27h ; '''
jz short loc_3AF85
mov rax, [rbp+var_10]
movsx eax, byte ptr [rax]
cmp eax, 22h ; '"'
jnz short loc_3AFB3
loc_3AF85:
cmp [rbp+var_12], 0
jnz short loc_3AFB3
cmp [rbp+var_11], 0
jnz short loc_3AF9C
mov rax, [rbp+var_10]
mov al, [rax]
mov [rbp+var_11], al
jmp short loc_3AFB1
loc_3AF9C:
movsx eax, [rbp+var_11]
mov rcx, [rbp+var_10]
movsx ecx, byte ptr [rcx]
cmp eax, ecx
jnz short loc_3AFAF
mov [rbp+var_11], 0
loc_3AFAF:
jmp short $+2
loc_3AFB1:
jmp short $+2
loc_3AFB3:
cmp [rbp+var_11], 0
jnz short loc_3AFD6
mov rax, [rbp+var_10]
movsx eax, byte ptr [rax]
cmp eax, 23h ; '#'
jnz short loc_3AFD6
mov rax, [rbp+var_10]
mov byte ptr [rax], 0
mov rax, [rbp+var_10]
mov [rbp+var_8], rax
jmp short loc_3B025
loc_3AFD6:
movsx ecx, [rbp+var_11]
xor eax, eax
cmp ecx, 0
mov [rbp+var_13], al
jz short loc_3B001
mov rax, [rbp+var_10]
movsx ecx, byte ptr [rax]
xor eax, eax
cmp ecx, 5Ch ; '\'
mov [rbp+var_13], al
jnz short loc_3B001
cmp [rbp+var_12], 0
setnz al
xor al, 0FFh
mov [rbp+var_13], al
loc_3B001:
mov al, [rbp+var_13]
and al, 1
movzx eax, al
mov [rbp+var_12], al
mov rax, [rbp+var_10]
add rax, 1
mov [rbp+var_10], rax
jmp loc_3AF60
loc_3B01D:
mov rax, [rbp+var_10]
mov [rbp+var_8], rax
loc_3B025:
mov rax, [rbp+var_8]
pop rbp
retn
|
char * remove_end_comment(char *a1)
{
char v2; // [rsp+1h] [rbp-13h]
char v3; // [rsp+2h] [rbp-12h]
char v4; // [rsp+3h] [rbp-11h]
v4 = 0;
v3 = 0;
while ( *a1 )
{
if ( (*a1 == 39 || *a1 == 34) && !v3 )
{
if ( v4 )
{
if ( v4 == *a1 )
v4 = 0;
}
else
{
v4 = *a1;
}
}
if ( !v4 && *a1 == 35 )
{
*a1 = 0;
return a1;
}
v2 = 0;
if ( v4 )
{
v2 = 0;
if ( *a1 == 92 )
v2 = ~(v3 != 0);
}
v3 = v2 & 1;
++a1;
}
return a1;
}
|
remove_end_comment:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV byte ptr [RBP + -0x11],0x0
MOV byte ptr [RBP + -0x12],0x0
LAB_0013af60:
MOV RAX,qword ptr [RBP + -0x10]
CMP byte ptr [RAX],0x0
JZ 0x0013b01d
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x27
JZ 0x0013af85
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x22
JNZ 0x0013afb3
LAB_0013af85:
CMP byte ptr [RBP + -0x12],0x0
JNZ 0x0013afb3
CMP byte ptr [RBP + -0x11],0x0
JNZ 0x0013af9c
MOV RAX,qword ptr [RBP + -0x10]
MOV AL,byte ptr [RAX]
MOV byte ptr [RBP + -0x11],AL
JMP 0x0013afb1
LAB_0013af9c:
MOVSX EAX,byte ptr [RBP + -0x11]
MOV RCX,qword ptr [RBP + -0x10]
MOVSX ECX,byte ptr [RCX]
CMP EAX,ECX
JNZ 0x0013afaf
MOV byte ptr [RBP + -0x11],0x0
LAB_0013afaf:
JMP 0x0013afb1
LAB_0013afb1:
JMP 0x0013afb3
LAB_0013afb3:
CMP byte ptr [RBP + -0x11],0x0
JNZ 0x0013afd6
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x23
JNZ 0x0013afd6
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0013b025
LAB_0013afd6:
MOVSX ECX,byte ptr [RBP + -0x11]
XOR EAX,EAX
CMP ECX,0x0
MOV byte ptr [RBP + -0x13],AL
JZ 0x0013b001
MOV RAX,qword ptr [RBP + -0x10]
MOVSX ECX,byte ptr [RAX]
XOR EAX,EAX
CMP ECX,0x5c
MOV byte ptr [RBP + -0x13],AL
JNZ 0x0013b001
CMP byte ptr [RBP + -0x12],0x0
SETNZ AL
XOR AL,0xff
MOV byte ptr [RBP + -0x13],AL
LAB_0013b001:
MOV AL,byte ptr [RBP + -0x13]
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x12],AL
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x1
MOV qword ptr [RBP + -0x10],RAX
JMP 0x0013af60
LAB_0013b01d:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x8],RAX
LAB_0013b025:
MOV RAX,qword ptr [RBP + -0x8]
POP RBP
RET
|
char * remove_end_comment(char *param_1)
{
bool bVar1;
bool bVar2;
char local_19;
char *local_18;
local_19 = '\0';
bVar1 = false;
local_18 = param_1;
while( true ) {
if (*local_18 == '\0') {
return local_18;
}
if (((*local_18 == '\'') || (*local_18 == '\"')) && (!bVar1)) {
if (local_19 == '\0') {
local_19 = *local_18;
}
else if (local_19 == *local_18) {
local_19 = '\0';
}
}
if ((local_19 == '\0') && (*local_18 == '#')) break;
bVar2 = false;
if ((local_19 != '\0') && (bVar2 = false, *local_18 == '\\')) {
bVar2 = (bool)(bVar1 ^ 1);
}
bVar1 = bVar2;
local_18 = local_18 + 1;
}
*local_18 = '\0';
return local_18;
}
|
|
19,957
|
OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::SurfaceFactory(OpenSubdiv::v3_6_0::Sdc::SchemeType, OpenSubdiv::v3_6_0::Sdc::Options const&, OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options const&)
|
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/surfaceFactory.cpp
|
SurfaceFactory::SurfaceFactory(Sdc::SchemeType subdivScheme,
Sdc::Options const & subdivOptions,
Options const & factoryOptions) :
_topologyCache(0) {
// Order of operations not important here:
setSubdivisionOptions(subdivScheme, subdivOptions);
setFactoryOptions(factoryOptions);
}
|
O0
|
cpp
|
OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::SurfaceFactory(OpenSubdiv::v3_6_0::Sdc::SchemeType, OpenSubdiv::v3_6_0::Sdc::Options const&, OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options const&):
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x38(%rbp)
callq 0xcd4e0
movq -0x38(%rbp), %rdi
movq 0x8ad39(%rip), %rax # 0x240ec8
addq $0x10, %rax
movq %rax, (%rdi)
addq $0xc, %rdi
callq 0xd6070
jmp 0x1b61a1
movq -0x38(%rbp), %rdi
addq $0x10, %rdi
callq 0xd3a50
jmp 0x1b61b0
movq -0x38(%rbp), %rdi
movq $0x0, 0x30(%rdi)
movl -0xc(%rbp), %esi
movq -0x18(%rbp), %rdx
callq 0xd4910
jmp 0x1b61ca
movq -0x38(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0xc7a20
jmp 0x1b61d9
addq $0x40, %rsp
popq %rbp
retq
movq -0x38(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
callq 0xd3cf0
movq -0x28(%rbp), %rdi
callq 0xd58b0
nopl (%rax)
|
_ZN10OpenSubdiv6v3_6_03Bfr14SurfaceFactoryC2ENS0_3Sdc10SchemeTypeERKNS3_7OptionsERKNS2_7OptionsE:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rdi, [rbp+var_8]; this
mov [rbp+var_38], rdi
call __ZN10OpenSubdiv6v3_6_03Bfr25SurfaceFactoryMeshAdapterC2Ev; OpenSubdiv::v3_6_0::Bfr::SurfaceFactoryMeshAdapter::SurfaceFactoryMeshAdapter(void)
mov rdi, [rbp+var_38]
mov rax, cs:_ZTVN10OpenSubdiv6v3_6_03Bfr14SurfaceFactoryE_ptr
add rax, 10h
mov [rdi], rax
add rdi, 0Ch; this
call __ZN10OpenSubdiv6v3_6_03Sdc7OptionsC2Ev; OpenSubdiv::v3_6_0::Sdc::Options::Options(void)
jmp short $+2
loc_1B61A1:
mov rdi, [rbp+var_38]
add rdi, 10h; this
call __ZN10OpenSubdiv6v3_6_03Bfr14SurfaceFactory7OptionsC2Ev; OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options::Options(void)
jmp short $+2
loc_1B61B0:
mov rdi, [rbp+var_38]
mov qword ptr [rdi+30h], 0
mov esi, [rbp+var_C]
mov rdx, [rbp+var_18]
call __ZN10OpenSubdiv6v3_6_03Bfr14SurfaceFactory21setSubdivisionOptionsENS0_3Sdc10SchemeTypeERKNS3_7OptionsE; OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::setSubdivisionOptions(OpenSubdiv::v3_6_0::Sdc::SchemeType,OpenSubdiv::v3_6_0::Sdc::Options const&)
jmp short $+2
loc_1B61CA:
mov rdi, [rbp+var_38]; this
mov rsi, [rbp+var_20]; OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options *
call __ZN10OpenSubdiv6v3_6_03Bfr14SurfaceFactory17setFactoryOptionsERKNS2_7OptionsE; OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::setFactoryOptions(OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options const&)
jmp short $+2
loc_1B61D9:
add rsp, 40h
pop rbp
retn
mov rdi, [rbp+var_38]; this
mov rcx, rax
mov eax, edx
mov [rbp+var_28], rcx
mov [rbp+var_2C], eax
call __ZN10OpenSubdiv6v3_6_03Bfr25SurfaceFactoryMeshAdapterD2Ev; OpenSubdiv::v3_6_0::Bfr::SurfaceFactoryMeshAdapter::~SurfaceFactoryMeshAdapter()
mov rdi, [rbp+var_28]
call __Unwind_Resume
|
long long OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::SurfaceFactory(
_QWORD *a1,
unsigned int a2,
long long a3,
const OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options *a4)
{
OpenSubdiv::v3_6_0::Bfr::SurfaceFactoryMeshAdapter::SurfaceFactoryMeshAdapter((OpenSubdiv::v3_6_0::Bfr::SurfaceFactoryMeshAdapter *)a1);
*a1 = &`vtable for'OpenSubdiv::v3_6_0::Bfr::SurfaceFactory + 2;
OpenSubdiv::v3_6_0::Sdc::Options::Options((OpenSubdiv::v3_6_0::Sdc::Options *)((char *)a1 + 12));
OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options::Options((OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options *)(a1 + 2));
a1[6] = 0LL;
OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::setSubdivisionOptions(a1, a2, a3);
return OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::setFactoryOptions((OpenSubdiv::v3_6_0::Bfr::SurfaceFactory *)a1, a4);
}
| |||
19,958
|
OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::SurfaceFactory(OpenSubdiv::v3_6_0::Sdc::SchemeType, OpenSubdiv::v3_6_0::Sdc::Options const&, OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options const&)
|
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/surfaceFactory.cpp
|
SurfaceFactory::SurfaceFactory(Sdc::SchemeType subdivScheme,
Sdc::Options const & subdivOptions,
Options const & factoryOptions) :
_topologyCache(0) {
// Order of operations not important here:
setSubdivisionOptions(subdivScheme, subdivOptions);
setFactoryOptions(factoryOptions);
}
|
O1
|
cpp
|
OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::SurfaceFactory(OpenSubdiv::v3_6_0::Sdc::SchemeType, OpenSubdiv::v3_6_0::Sdc::Options const&, OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options const&):
pushq %r14
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdi, %rbx
movq 0x415a3(%rip), %rax # 0xdded0
addq $0x10, %rax
movq %rax, (%rdi)
movl $0x500, 0xc(%rdi) # imm = 0x500
movq $-0x1, 0x10(%rdi)
xorl %eax, %eax
movq %rax, 0x18(%rdi)
orb $0x1, 0x20(%rdi)
movw $0x602, 0x21(%rdi) # imm = 0x602
movq %rax, 0x30(%rdi)
callq 0x3b9e0
movl 0xf(%r14), %eax
movl %eax, 0x1f(%rbx)
movups (%r14), %xmm0
movups %xmm0, 0x10(%rbx)
testb $0x1, 0x20(%rbx)
je 0x9c97e
movq 0x18(%rbx), %rax
testq %rax, %rax
je 0x9c97e
movq %rax, 0x30(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
|
_ZN10OpenSubdiv6v3_6_03Bfr14SurfaceFactoryC2ENS0_3Sdc10SchemeTypeERKNS3_7OptionsERKNS2_7OptionsE:
push r14
push rbx
push rax
mov r14, rcx
mov rbx, rdi
mov rax, cs:_ZTVN10OpenSubdiv6v3_6_03Bfr14SurfaceFactoryE_ptr
add rax, 10h
mov [rdi], rax
mov dword ptr [rdi+0Ch], 500h
mov qword ptr [rdi+10h], 0FFFFFFFFFFFFFFFFh
xor eax, eax
mov [rdi+18h], rax
or byte ptr [rdi+20h], 1
mov word ptr [rdi+21h], 602h
mov [rdi+30h], rax
call __ZN10OpenSubdiv6v3_6_03Bfr14SurfaceFactory21setSubdivisionOptionsENS0_3Sdc10SchemeTypeERKNS3_7OptionsE; OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::setSubdivisionOptions(OpenSubdiv::v3_6_0::Sdc::SchemeType,OpenSubdiv::v3_6_0::Sdc::Options const&)
mov eax, [r14+0Fh]
mov [rbx+1Fh], eax
movups xmm0, xmmword ptr [r14]
movups xmmword ptr [rbx+10h], xmm0
test byte ptr [rbx+20h], 1
jz short loc_9C97E
mov rax, [rbx+18h]
test rax, rax
jz short loc_9C97E
mov [rbx+30h], rax
loc_9C97E:
add rsp, 8
pop rbx
pop r14
retn
|
long long OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::SurfaceFactory(
long long a1,
long long a2,
long long a3,
long long a4)
{
long long result; // rax
*(_QWORD *)a1 = &`vtable for'OpenSubdiv::v3_6_0::Bfr::SurfaceFactory + 2;
*(_DWORD *)(a1 + 12) = 1280;
*(_QWORD *)(a1 + 16) = -1LL;
*(_QWORD *)(a1 + 24) = 0LL;
*(_BYTE *)(a1 + 32) |= 1u;
*(_WORD *)(a1 + 33) = 1538;
*(_QWORD *)(a1 + 48) = 0LL;
OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::setSubdivisionOptions(a1);
result = *(unsigned int *)(a4 + 15);
*(_DWORD *)(a1 + 31) = result;
*(_OWORD *)(a1 + 16) = *(_OWORD *)a4;
if ( (*(_BYTE *)(a1 + 32) & 1) != 0 )
{
result = *(_QWORD *)(a1 + 24);
if ( result )
*(_QWORD *)(a1 + 48) = result;
}
return result;
}
|
SurfaceFactory:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RCX
MOV RBX,RDI
MOV RAX,qword ptr [0x001dded0]
ADD RAX,0x10
MOV qword ptr [RDI],RAX
MOV dword ptr [RDI + 0xc],0x500
MOV qword ptr [RDI + 0x10],-0x1
XOR EAX,EAX
MOV qword ptr [RDI + 0x18],RAX
OR byte ptr [RDI + 0x20],0x1
MOV word ptr [RDI + 0x21],0x602
MOV qword ptr [RDI + 0x30],RAX
CALL 0x0013b9e0
MOV EAX,dword ptr [R14 + 0xf]
MOV dword ptr [RBX + 0x1f],EAX
MOVUPS XMM0,xmmword ptr [R14]
MOVUPS xmmword ptr [RBX + 0x10],XMM0
TEST byte ptr [RBX + 0x20],0x1
JZ 0x0019c97e
MOV RAX,qword ptr [RBX + 0x18]
TEST RAX,RAX
JZ 0x0019c97e
MOV qword ptr [RBX + 0x30],RAX
LAB_0019c97e:
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::SurfaceFactory(OpenSubdiv::v3_6_0::Sdc::SchemeType,
OpenSubdiv::v3_6_0::Sdc::Options const&, OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::Options const&)
*/
void __thiscall
OpenSubdiv::v3_6_0::Bfr::SurfaceFactory::SurfaceFactory
(SurfaceFactory *this,int8 param_2,int8 param_3,int8 *param_4)
{
int8 uVar1;
*(int **)this = PTR_vtable_001dded0 + 0x10;
*(int4 *)(this + 0xc) = 0x500;
*(int8 *)(this + 0x10) = 0xffffffffffffffff;
*(int8 *)(this + 0x18) = 0;
this[0x20] = (SurfaceFactory)((byte)this[0x20] | 1);
*(int2 *)(this + 0x21) = 0x602;
*(int8 *)(this + 0x30) = 0;
setSubdivisionOptions();
*(int4 *)(this + 0x1f) = *(int4 *)((long)param_4 + 0xf);
uVar1 = param_4[1];
*(int8 *)(this + 0x10) = *param_4;
*(int8 *)(this + 0x18) = uVar1;
if ((((byte)this[0x20] & 1) != 0) && (*(long *)(this + 0x18) != 0)) {
*(long *)(this + 0x30) = *(long *)(this + 0x18);
}
return;
}
|
|
19,959
|
dequantize_row_iq1_m
|
monkey531[P]llama/ggml/src/ggml-quants.c
|
void dequantize_row_iq1_m(const block_iq1_m * restrict x, float * restrict y, int64_t k) {
assert(k % QK_K == 0);
const int64_t nb = k / QK_K;
float delta[4];
uint16_t idx[4];
iq1m_scale_t scale;
for (int i = 0; i < nb; i++) {
const uint16_t * sc = (const uint16_t *)x[i].scales;
scale.u16 = (sc[0] >> 12) | ((sc[1] >> 8) & 0x00f0) | ((sc[2] >> 4) & 0x0f00) | (sc[3] & 0xf000);
const float d = GGML_FP16_TO_FP32(scale.f16);
const uint8_t * qs = x[i].qs;
const uint8_t * qh = x[i].qh;
for (int ib = 0; ib < QK_K/32; ++ib) {
const float dl1 = d * (2*((sc[ib/2] >> (6*(ib%2)+0)) & 0x7) + 1);
const float dl2 = d * (2*((sc[ib/2] >> (6*(ib%2)+3)) & 0x7) + 1);
idx[0] = qs[0] | ((qh[0] << 8) & 0x700);
idx[1] = qs[1] | ((qh[0] << 4) & 0x700);
idx[2] = qs[2] | ((qh[1] << 8) & 0x700);
idx[3] = qs[3] | ((qh[1] << 4) & 0x700);
delta[0] = qh[0] & 0x08 ? -IQ1S_DELTA : IQ1S_DELTA;
delta[1] = qh[0] & 0x80 ? -IQ1S_DELTA : IQ1S_DELTA;
delta[2] = qh[1] & 0x08 ? -IQ1S_DELTA : IQ1S_DELTA;
delta[3] = qh[1] & 0x80 ? -IQ1S_DELTA : IQ1S_DELTA;
for (int l = 0; l < 2; ++l) {
const int8_t * grid = (const int8_t *)(iq1s_grid + idx[l]);
for (int j = 0; j < 8; ++j) {
y[j] = dl1 * (grid[j] + delta[l]);
}
y += 8;
}
for (int l = 2; l < 4; ++l) {
const int8_t * grid = (const int8_t *)(iq1s_grid + idx[l]);
for (int j = 0; j < 8; ++j) {
y[j] = dl2 * (grid[j] + delta[l]);
}
y += 8;
}
qs += 4;
qh += 2;
}
}
}
|
O0
|
c
|
dequantize_row_iq1_m:
subq $0xd8, %rsp
movq %rdi, 0xd0(%rsp)
movq %rsi, 0xc8(%rsp)
movq %rdx, 0xc0(%rsp)
movq 0xc0(%rsp), %rax
movl $0x100, %ecx # imm = 0x100
cqto
idivq %rcx
movq %rax, 0xb8(%rsp)
movl $0x0, 0x90(%rsp)
movslq 0x90(%rsp), %rax
cmpq 0xb8(%rsp), %rax
jge 0x7acd9
movq 0xd0(%rsp), %rax
movslq 0x90(%rsp), %rcx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
addq $0x30, %rax
movq %rax, 0x88(%rsp)
movq 0x88(%rsp), %rax
movzwl (%rax), %eax
sarl $0xc, %eax
movq 0x88(%rsp), %rcx
movzwl 0x2(%rcx), %ecx
sarl $0x8, %ecx
andl $0xf0, %ecx
orl %ecx, %eax
movq 0x88(%rsp), %rcx
movzwl 0x4(%rcx), %ecx
sarl $0x4, %ecx
andl $0xf00, %ecx # imm = 0xF00
orl %ecx, %eax
movq 0x88(%rsp), %rcx
movzwl 0x6(%rcx), %ecx
andl $0xf000, %ecx # imm = 0xF000
orl %ecx, %eax
movw %ax, 0x96(%rsp)
movzwl 0x96(%rsp), %edi
callq 0x6f440
movss %xmm0, 0x84(%rsp)
movq 0xd0(%rsp), %rax
movslq 0x90(%rsp), %rcx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
movq %rax, 0x78(%rsp)
movq 0xd0(%rsp), %rax
movslq 0x90(%rsp), %rcx
imulq $0x38, %rcx, %rcx
addq %rcx, %rax
addq $0x20, %rax
movq %rax, 0x70(%rsp)
movl $0x0, 0x6c(%rsp)
cmpl $0x8, 0x6c(%rsp)
jge 0x7acc1
movss 0x84(%rsp), %xmm0
movq 0x88(%rsp), %rax
movq %rax, 0x20(%rsp)
movl 0x6c(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movq 0x20(%rsp), %rax
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
movl %eax, 0x2c(%rsp)
movl 0x6c(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl 0x2c(%rsp), %eax
imull $0x6, %edx, %ecx
addl $0x0, %ecx
sarl %cl, %eax
andl $0x7, %eax
shll %eax
addl $0x1, %eax
cvtsi2ss %eax, %xmm1
mulss %xmm1, %xmm0
movss %xmm0, 0x68(%rsp)
movss 0x84(%rsp), %xmm0
movq 0x88(%rsp), %rax
movq %rax, 0x30(%rsp)
movl 0x6c(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movq 0x30(%rsp), %rax
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
movl %eax, 0x38(%rsp)
movl 0x6c(%rsp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl 0x38(%rsp), %eax
imull $0x6, %edx, %ecx
addl $0x3, %ecx
sarl %cl, %eax
andl $0x7, %eax
shll %eax
addl $0x1, %eax
cvtsi2ss %eax, %xmm1
mulss %xmm1, %xmm0
movss %xmm0, 0x64(%rsp)
movq 0x78(%rsp), %rax
movzbl (%rax), %eax
movq 0x70(%rsp), %rcx
movzbl (%rcx), %ecx
shll $0x8, %ecx
andl $0x700, %ecx # imm = 0x700
orl %ecx, %eax
movw %ax, 0x98(%rsp)
movq 0x78(%rsp), %rax
movzbl 0x1(%rax), %eax
movq 0x70(%rsp), %rcx
movzbl (%rcx), %ecx
shll $0x4, %ecx
andl $0x700, %ecx # imm = 0x700
orl %ecx, %eax
movw %ax, 0x9a(%rsp)
movq 0x78(%rsp), %rax
movzbl 0x2(%rax), %eax
movq 0x70(%rsp), %rcx
movzbl 0x1(%rcx), %ecx
shll $0x8, %ecx
andl $0x700, %ecx # imm = 0x700
orl %ecx, %eax
movw %ax, 0x9c(%rsp)
movq 0x78(%rsp), %rax
movzbl 0x3(%rax), %eax
movq 0x70(%rsp), %rcx
movzbl 0x1(%rcx), %ecx
shll $0x4, %ecx
andl $0x700, %ecx # imm = 0x700
orl %ecx, %eax
movw %ax, 0x9e(%rsp)
movq 0x70(%rsp), %rax
movzbl (%rax), %eax
andl $0x8, %eax
movss 0x3dcd6(%rip), %xmm0 # 0xb86f8
movss 0x3dcd2(%rip), %xmm1 # 0xb86fc
movss %xmm1, 0x3c(%rsp)
cmpl $0x0, %eax
movss %xmm0, 0x40(%rsp)
jne 0x7aa47
movss 0x3c(%rsp), %xmm0
movss %xmm0, 0x40(%rsp)
movss 0x40(%rsp), %xmm0
movss %xmm0, 0xa0(%rsp)
movq 0x70(%rsp), %rax
movzbl (%rax), %eax
andl $0x80, %eax
movss 0x3dc8d(%rip), %xmm0 # 0xb86f8
movss 0x3dc89(%rip), %xmm1 # 0xb86fc
movss %xmm1, 0x18(%rsp)
cmpl $0x0, %eax
movss %xmm0, 0x1c(%rsp)
jne 0x7aa90
movss 0x18(%rsp), %xmm0
movss %xmm0, 0x1c(%rsp)
movss 0x1c(%rsp), %xmm0
movss %xmm0, 0xa4(%rsp)
movq 0x70(%rsp), %rax
movzbl 0x1(%rax), %eax
andl $0x8, %eax
movss 0x3dc45(%rip), %xmm0 # 0xb86f8
movss 0x3dc41(%rip), %xmm1 # 0xb86fc
movss %xmm1, 0x10(%rsp)
cmpl $0x0, %eax
movss %xmm0, 0x14(%rsp)
jne 0x7aad8
movss 0x10(%rsp), %xmm0
movss %xmm0, 0x14(%rsp)
movss 0x14(%rsp), %xmm0
movss %xmm0, 0xa8(%rsp)
movq 0x70(%rsp), %rax
movzbl 0x1(%rax), %eax
andl $0x80, %eax
movss 0x3dbfb(%rip), %xmm0 # 0xb86f8
movss 0x3dbf7(%rip), %xmm1 # 0xb86fc
movss %xmm1, 0x8(%rsp)
cmpl $0x0, %eax
movss %xmm0, 0xc(%rsp)
jne 0x7ab22
movss 0x8(%rsp), %xmm0
movss %xmm0, 0xc(%rsp)
movss 0xc(%rsp), %xmm0
movss %xmm0, 0xac(%rsp)
movl $0x0, 0x60(%rsp)
cmpl $0x2, 0x60(%rsp)
jge 0x7abe3
movslq 0x60(%rsp), %rax
movzwl 0x98(%rsp,%rax,2), %eax
movslq %eax, %rcx
leaq 0x42135(%rip), %rax # 0xbcc90
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, 0x58(%rsp)
movl $0x0, 0x54(%rsp)
cmpl $0x8, 0x54(%rsp)
jge 0x7abbf
movss 0x68(%rsp), %xmm0
movq 0x58(%rsp), %rax
movslq 0x54(%rsp), %rcx
movsbl (%rax,%rcx), %eax
cvtsi2ss %eax, %xmm1
movslq 0x60(%rsp), %rax
addss 0xa0(%rsp,%rax,4), %xmm1
mulss %xmm1, %xmm0
movq 0xc8(%rsp), %rax
movslq 0x54(%rsp), %rcx
movss %xmm0, (%rax,%rcx,4)
movl 0x54(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x54(%rsp)
jmp 0x7ab6f
movq 0xc8(%rsp), %rax
addq $0x20, %rax
movq %rax, 0xc8(%rsp)
movl 0x60(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x60(%rsp)
jmp 0x7ab39
movl $0x2, 0x50(%rsp)
cmpl $0x4, 0x50(%rsp)
jge 0x7ac95
movslq 0x50(%rsp), %rax
movzwl 0x98(%rsp,%rax,2), %eax
movslq %eax, %rcx
leaq 0x42083(%rip), %rax # 0xbcc90
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, 0x48(%rsp)
movl $0x0, 0x44(%rsp)
cmpl $0x8, 0x44(%rsp)
jge 0x7ac71
movss 0x64(%rsp), %xmm0
movq 0x48(%rsp), %rax
movslq 0x44(%rsp), %rcx
movsbl (%rax,%rcx), %eax
cvtsi2ss %eax, %xmm1
movslq 0x50(%rsp), %rax
addss 0xa0(%rsp,%rax,4), %xmm1
mulss %xmm1, %xmm0
movq 0xc8(%rsp), %rax
movslq 0x44(%rsp), %rcx
movss %xmm0, (%rax,%rcx,4)
movl 0x44(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x44(%rsp)
jmp 0x7ac21
movq 0xc8(%rsp), %rax
addq $0x20, %rax
movq %rax, 0xc8(%rsp)
movl 0x50(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x50(%rsp)
jmp 0x7abeb
movq 0x78(%rsp), %rax
addq $0x4, %rax
movq %rax, 0x78(%rsp)
movq 0x70(%rsp), %rax
addq $0x2, %rax
movq %rax, 0x70(%rsp)
movl 0x6c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x6c(%rsp)
jmp 0x7a8af
jmp 0x7acc3
movl 0x90(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x90(%rsp)
jmp 0x7a7c4
addq $0xd8, %rsp
retq
nopw %cs:(%rax,%rax)
|
dequantize_row_iq1_m:
sub rsp, 0D8h
mov [rsp+0D8h+var_8], rdi
mov [rsp+0D8h+var_10], rsi
mov [rsp+0D8h+var_18], rdx
mov rax, [rsp+0D8h+var_18]
mov ecx, 100h
cqo
idiv rcx
mov [rsp+0D8h+var_20], rax
mov [rsp+0D8h+var_48], 0
loc_7A7C4:
movsxd rax, [rsp+0D8h+var_48]
cmp rax, [rsp+0D8h+var_20]
jge loc_7ACD9
mov rax, [rsp+0D8h+var_8]
movsxd rcx, [rsp+0D8h+var_48]
imul rcx, 38h ; '8'
add rax, rcx
add rax, 30h ; '0'
mov [rsp+0D8h+var_50], rax
mov rax, [rsp+0D8h+var_50]
movzx eax, word ptr [rax]
sar eax, 0Ch
mov rcx, [rsp+0D8h+var_50]
movzx ecx, word ptr [rcx+2]
sar ecx, 8
and ecx, 0F0h
or eax, ecx
mov rcx, [rsp+0D8h+var_50]
movzx ecx, word ptr [rcx+4]
sar ecx, 4
and ecx, 0F00h
or eax, ecx
mov rcx, [rsp+0D8h+var_50]
movzx ecx, word ptr [rcx+6]
and ecx, 0F000h
or eax, ecx
mov [rsp+0D8h+var_42], ax
movzx edi, [rsp+0D8h+var_42]
call ggml_lookup_fp16_to_fp32_0
movss [rsp+0D8h+var_54], xmm0
mov rax, [rsp+0D8h+var_8]
movsxd rcx, [rsp+0D8h+var_48]
imul rcx, 38h ; '8'
add rax, rcx
mov [rsp+0D8h+var_60], rax
mov rax, [rsp+0D8h+var_8]
movsxd rcx, [rsp+0D8h+var_48]
imul rcx, 38h ; '8'
add rax, rcx
add rax, 20h ; ' '
mov [rsp+0D8h+var_68], rax
mov [rsp+0D8h+var_6C], 0
loc_7A8AF:
cmp [rsp+0D8h+var_6C], 8
jge loc_7ACC1
movss xmm0, [rsp+0D8h+var_54]
mov rax, [rsp+0D8h+var_50]
mov [rsp+0D8h+var_B8], rax
mov eax, [rsp+0D8h+var_6C]
mov ecx, 2
cdq
idiv ecx
mov ecx, eax
mov rax, [rsp+0D8h+var_B8]
movsxd rcx, ecx
movzx eax, word ptr [rax+rcx*2]
mov [rsp+0D8h+var_AC], eax
mov eax, [rsp+0D8h+var_6C]
mov ecx, 2
cdq
idiv ecx
mov eax, [rsp+0D8h+var_AC]
imul ecx, edx, 6
add ecx, 0
sar eax, cl
and eax, 7
shl eax, 1
add eax, 1
cvtsi2ss xmm1, eax
mulss xmm0, xmm1
movss [rsp+0D8h+var_70], xmm0
movss xmm0, [rsp+0D8h+var_54]
mov rax, [rsp+0D8h+var_50]
mov [rsp+0D8h+var_A8], rax
mov eax, [rsp+0D8h+var_6C]
mov ecx, 2
cdq
idiv ecx
mov ecx, eax
mov rax, [rsp+0D8h+var_A8]
movsxd rcx, ecx
movzx eax, word ptr [rax+rcx*2]
mov [rsp+0D8h+var_A0], eax
mov eax, [rsp+0D8h+var_6C]
mov ecx, 2
cdq
idiv ecx
mov eax, [rsp+0D8h+var_A0]
imul ecx, edx, 6
add ecx, 3
sar eax, cl
and eax, 7
shl eax, 1
add eax, 1
cvtsi2ss xmm1, eax
mulss xmm0, xmm1
movss [rsp+0D8h+var_74], xmm0
mov rax, [rsp+0D8h+var_60]
movzx eax, byte ptr [rax]
mov rcx, [rsp+0D8h+var_68]
movzx ecx, byte ptr [rcx]
shl ecx, 8
and ecx, 700h
or eax, ecx
mov [rsp+0D8h+var_40], ax
mov rax, [rsp+0D8h+var_60]
movzx eax, byte ptr [rax+1]
mov rcx, [rsp+0D8h+var_68]
movzx ecx, byte ptr [rcx]
shl ecx, 4
and ecx, 700h
or eax, ecx
mov [rsp+0D8h+var_3E], ax
mov rax, [rsp+0D8h+var_60]
movzx eax, byte ptr [rax+2]
mov rcx, [rsp+0D8h+var_68]
movzx ecx, byte ptr [rcx+1]
shl ecx, 8
and ecx, 700h
or eax, ecx
mov [rsp+0D8h+var_3C], ax
mov rax, [rsp+0D8h+var_60]
movzx eax, byte ptr [rax+3]
mov rcx, [rsp+0D8h+var_68]
movzx ecx, byte ptr [rcx+1]
shl ecx, 4
and ecx, 700h
or eax, ecx
mov [rsp+0D8h+var_3A], ax
mov rax, [rsp+0D8h+var_68]
movzx eax, byte ptr [rax]
and eax, 8
movss xmm0, cs:dword_B86F8
movss xmm1, cs:dword_B86FC
movss [rsp+0D8h+var_9C], xmm1
cmp eax, 0
movss [rsp+0D8h+var_98], xmm0
jnz short loc_7AA47
movss xmm0, [rsp+0D8h+var_9C]
movss [rsp+0D8h+var_98], xmm0
loc_7AA47:
movss xmm0, [rsp+0D8h+var_98]
movss [rsp+0D8h+var_38], xmm0
mov rax, [rsp+0D8h+var_68]
movzx eax, byte ptr [rax]
and eax, 80h
movss xmm0, cs:dword_B86F8
movss xmm1, cs:dword_B86FC
movss [rsp+0D8h+var_C0], xmm1
cmp eax, 0
movss [rsp+0D8h+var_BC], xmm0
jnz short loc_7AA90
movss xmm0, [rsp+0D8h+var_C0]
movss [rsp+0D8h+var_BC], xmm0
loc_7AA90:
movss xmm0, [rsp+0D8h+var_BC]
movss [rsp+0D8h+var_34], xmm0
mov rax, [rsp+0D8h+var_68]
movzx eax, byte ptr [rax+1]
and eax, 8
movss xmm0, cs:dword_B86F8
movss xmm1, cs:dword_B86FC
movss [rsp+0D8h+var_C8], xmm1
cmp eax, 0
movss [rsp+0D8h+var_C4], xmm0
jnz short loc_7AAD8
movss xmm0, [rsp+0D8h+var_C8]
movss [rsp+0D8h+var_C4], xmm0
loc_7AAD8:
movss xmm0, [rsp+0D8h+var_C4]
movss [rsp+0D8h+var_30], xmm0
mov rax, [rsp+0D8h+var_68]
movzx eax, byte ptr [rax+1]
and eax, 80h
movss xmm0, cs:dword_B86F8
movss xmm1, cs:dword_B86FC
movss [rsp+0D8h+var_D0], xmm1
cmp eax, 0
movss [rsp+0D8h+var_CC], xmm0
jnz short loc_7AB22
movss xmm0, [rsp+0D8h+var_D0]
movss [rsp+0D8h+var_CC], xmm0
loc_7AB22:
movss xmm0, [rsp+0D8h+var_CC]
movss [rsp+0D8h+var_2C], xmm0
mov [rsp+0D8h+var_78], 0
loc_7AB39:
cmp [rsp+0D8h+var_78], 2
jge loc_7ABE3
movsxd rax, [rsp+0D8h+var_78]
movzx eax, [rsp+rax*2+0D8h+var_40]
movsxd rcx, eax
lea rax, iq1s_grid
shl rcx, 3
add rax, rcx
mov [rsp+0D8h+var_80], rax
mov [rsp+0D8h+var_84], 0
loc_7AB6F:
cmp [rsp+0D8h+var_84], 8
jge short loc_7ABBF
movss xmm0, [rsp+0D8h+var_70]
mov rax, [rsp+0D8h+var_80]
movsxd rcx, [rsp+0D8h+var_84]
movsx eax, byte ptr [rax+rcx]
cvtsi2ss xmm1, eax
movsxd rax, [rsp+0D8h+var_78]
addss xmm1, [rsp+rax*4+0D8h+var_38]
mulss xmm0, xmm1
mov rax, [rsp+0D8h+var_10]
movsxd rcx, [rsp+0D8h+var_84]
movss dword ptr [rax+rcx*4], xmm0
mov eax, [rsp+0D8h+var_84]
add eax, 1
mov [rsp+0D8h+var_84], eax
jmp short loc_7AB6F
loc_7ABBF:
mov rax, [rsp+0D8h+var_10]
add rax, 20h ; ' '
mov [rsp+0D8h+var_10], rax
mov eax, [rsp+0D8h+var_78]
add eax, 1
mov [rsp+0D8h+var_78], eax
jmp loc_7AB39
loc_7ABE3:
mov [rsp+0D8h+var_88], 2
loc_7ABEB:
cmp [rsp+0D8h+var_88], 4
jge loc_7AC95
movsxd rax, [rsp+0D8h+var_88]
movzx eax, [rsp+rax*2+0D8h+var_40]
movsxd rcx, eax
lea rax, iq1s_grid
shl rcx, 3
add rax, rcx
mov [rsp+0D8h+var_90], rax
mov [rsp+0D8h+var_94], 0
loc_7AC21:
cmp [rsp+0D8h+var_94], 8
jge short loc_7AC71
movss xmm0, [rsp+0D8h+var_74]
mov rax, [rsp+0D8h+var_90]
movsxd rcx, [rsp+0D8h+var_94]
movsx eax, byte ptr [rax+rcx]
cvtsi2ss xmm1, eax
movsxd rax, [rsp+0D8h+var_88]
addss xmm1, [rsp+rax*4+0D8h+var_38]
mulss xmm0, xmm1
mov rax, [rsp+0D8h+var_10]
movsxd rcx, [rsp+0D8h+var_94]
movss dword ptr [rax+rcx*4], xmm0
mov eax, [rsp+0D8h+var_94]
add eax, 1
mov [rsp+0D8h+var_94], eax
jmp short loc_7AC21
loc_7AC71:
mov rax, [rsp+0D8h+var_10]
add rax, 20h ; ' '
mov [rsp+0D8h+var_10], rax
mov eax, [rsp+0D8h+var_88]
add eax, 1
mov [rsp+0D8h+var_88], eax
jmp loc_7ABEB
loc_7AC95:
mov rax, [rsp+0D8h+var_60]
add rax, 4
mov [rsp+0D8h+var_60], rax
mov rax, [rsp+0D8h+var_68]
add rax, 2
mov [rsp+0D8h+var_68], rax
mov eax, [rsp+0D8h+var_6C]
add eax, 1
mov [rsp+0D8h+var_6C], eax
jmp loc_7A8AF
loc_7ACC1:
jmp short $+2
loc_7ACC3:
mov eax, [rsp+0D8h+var_48]
add eax, 1
mov [rsp+0D8h+var_48], eax
jmp loc_7A7C4
loc_7ACD9:
add rsp, 0D8h
retn
|
long long dequantize_row_iq1_m(long long a1, long long a2, long long a3)
{
long long result; // rax
int v4; // [rsp+Ch] [rbp-CCh]
int v5; // [rsp+14h] [rbp-C4h]
int v6; // [rsp+1Ch] [rbp-BCh]
int v7; // [rsp+40h] [rbp-98h]
int ii; // [rsp+44h] [rbp-94h]
char *v9; // [rsp+48h] [rbp-90h]
int n; // [rsp+50h] [rbp-88h]
int m; // [rsp+54h] [rbp-84h]
char *v12; // [rsp+58h] [rbp-80h]
int k; // [rsp+60h] [rbp-78h]
float v14; // [rsp+64h] [rbp-74h]
float v15; // [rsp+68h] [rbp-70h]
int j; // [rsp+6Ch] [rbp-6Ch]
unsigned __int8 *v17; // [rsp+70h] [rbp-68h]
unsigned __int8 *v18; // [rsp+78h] [rbp-60h]
float v19; // [rsp+84h] [rbp-54h]
unsigned __int16 *v20; // [rsp+88h] [rbp-50h]
int i; // [rsp+90h] [rbp-48h]
_WORD v22[4]; // [rsp+98h] [rbp-40h]
_DWORD v23[6]; // [rsp+A0h] [rbp-38h]
long long v24; // [rsp+B8h] [rbp-20h]
long long v25; // [rsp+C0h] [rbp-18h]
long long v26; // [rsp+C8h] [rbp-10h]
long long v27; // [rsp+D0h] [rbp-8h]
v27 = a1;
v26 = a2;
v25 = a3;
v24 = a3 / 256;
for ( i = 0; ; ++i )
{
result = i;
if ( i >= v24 )
break;
v20 = (unsigned __int16 *)(56LL * i + v27 + 48);
v19 = ggml_lookup_fp16_to_fp32_0(*(_WORD *)(56LL * i + v27 + 54) & 0xF000 | ((int)*(unsigned __int16 *)(56LL * i + v27 + 52) >> 4) & 0xF00 | ((int)*(unsigned __int16 *)(56LL * i + v27 + 50) >> 8) & 0xF0 | ((int)*v20 >> 12));
v18 = (unsigned __int8 *)(56LL * i + v27);
v17 = v18 + 32;
for ( j = 0; j < 8; ++j )
{
v15 = v19 * (float)(2 * (((int)v20[j / 2] >> (6 * (j % 2))) & 7) + 1);
v14 = v19 * (float)(2 * (((int)v20[j / 2] >> (6 * (j % 2) + 3)) & 7) + 1);
v22[0] = (*v17 << 8) & 0x700 | *v18;
v22[1] = (16 * *v17) & 0x700 | v18[1];
v22[2] = (v17[1] << 8) & 0x700 | v18[2];
v22[3] = (16 * v17[1]) & 0x700 | v18[3];
v7 = -1107296256;
if ( (*v17 & 8) == 0 )
v7 = 1040187392;
v23[0] = v7;
v6 = -1107296256;
if ( (*v17 & 0x80) == 0 )
v6 = 1040187392;
v23[1] = v6;
v5 = -1107296256;
if ( (v17[1] & 8) == 0 )
v5 = 1040187392;
v23[2] = v5;
v4 = -1107296256;
if ( (v17[1] & 0x80) == 0 )
v4 = 1040187392;
v23[3] = v4;
for ( k = 0; k < 2; ++k )
{
v12 = (char *)&iq1s_grid + 8 * (unsigned __int16)v22[k];
for ( m = 0; m < 8; ++m )
*(float *)(v26 + 4LL * m) = v15 * (float)((float)v12[m] + *(float *)&v23[k]);
v26 += 32LL;
}
for ( n = 2; n < 4; ++n )
{
v9 = (char *)&iq1s_grid + 8 * (unsigned __int16)v22[n];
for ( ii = 0; ii < 8; ++ii )
*(float *)(v26 + 4LL * ii) = v14 * (float)((float)v9[ii] + *(float *)&v23[n]);
v26 += 32LL;
}
v18 += 4;
v17 += 2;
}
}
return result;
}
|
dequantize_row_iq1_m:
SUB RSP,0xd8
MOV qword ptr [RSP + 0xd0],RDI
MOV qword ptr [RSP + 0xc8],RSI
MOV qword ptr [RSP + 0xc0],RDX
MOV RAX,qword ptr [RSP + 0xc0]
MOV ECX,0x100
CQO
IDIV RCX
MOV qword ptr [RSP + 0xb8],RAX
MOV dword ptr [RSP + 0x90],0x0
LAB_0017a7c4:
MOVSXD RAX,dword ptr [RSP + 0x90]
CMP RAX,qword ptr [RSP + 0xb8]
JGE 0x0017acd9
MOV RAX,qword ptr [RSP + 0xd0]
MOVSXD RCX,dword ptr [RSP + 0x90]
IMUL RCX,RCX,0x38
ADD RAX,RCX
ADD RAX,0x30
MOV qword ptr [RSP + 0x88],RAX
MOV RAX,qword ptr [RSP + 0x88]
MOVZX EAX,word ptr [RAX]
SAR EAX,0xc
MOV RCX,qword ptr [RSP + 0x88]
MOVZX ECX,word ptr [RCX + 0x2]
SAR ECX,0x8
AND ECX,0xf0
OR EAX,ECX
MOV RCX,qword ptr [RSP + 0x88]
MOVZX ECX,word ptr [RCX + 0x4]
SAR ECX,0x4
AND ECX,0xf00
OR EAX,ECX
MOV RCX,qword ptr [RSP + 0x88]
MOVZX ECX,word ptr [RCX + 0x6]
AND ECX,0xf000
OR EAX,ECX
MOV word ptr [RSP + 0x96],AX
MOVZX EDI,word ptr [RSP + 0x96]
CALL 0x0016f440
MOVSS dword ptr [RSP + 0x84],XMM0
MOV RAX,qword ptr [RSP + 0xd0]
MOVSXD RCX,dword ptr [RSP + 0x90]
IMUL RCX,RCX,0x38
ADD RAX,RCX
MOV qword ptr [RSP + 0x78],RAX
MOV RAX,qword ptr [RSP + 0xd0]
MOVSXD RCX,dword ptr [RSP + 0x90]
IMUL RCX,RCX,0x38
ADD RAX,RCX
ADD RAX,0x20
MOV qword ptr [RSP + 0x70],RAX
MOV dword ptr [RSP + 0x6c],0x0
LAB_0017a8af:
CMP dword ptr [RSP + 0x6c],0x8
JGE 0x0017acc1
MOVSS XMM0,dword ptr [RSP + 0x84]
MOV RAX,qword ptr [RSP + 0x88]
MOV qword ptr [RSP + 0x20],RAX
MOV EAX,dword ptr [RSP + 0x6c]
MOV ECX,0x2
CDQ
IDIV ECX
MOV ECX,EAX
MOV RAX,qword ptr [RSP + 0x20]
MOVSXD RCX,ECX
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV dword ptr [RSP + 0x2c],EAX
MOV EAX,dword ptr [RSP + 0x6c]
MOV ECX,0x2
CDQ
IDIV ECX
MOV EAX,dword ptr [RSP + 0x2c]
IMUL ECX,EDX,0x6
ADD ECX,0x0
SAR EAX,CL
AND EAX,0x7
SHL EAX,0x1
ADD EAX,0x1
CVTSI2SS XMM1,EAX
MULSS XMM0,XMM1
MOVSS dword ptr [RSP + 0x68],XMM0
MOVSS XMM0,dword ptr [RSP + 0x84]
MOV RAX,qword ptr [RSP + 0x88]
MOV qword ptr [RSP + 0x30],RAX
MOV EAX,dword ptr [RSP + 0x6c]
MOV ECX,0x2
CDQ
IDIV ECX
MOV ECX,EAX
MOV RAX,qword ptr [RSP + 0x30]
MOVSXD RCX,ECX
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV dword ptr [RSP + 0x38],EAX
MOV EAX,dword ptr [RSP + 0x6c]
MOV ECX,0x2
CDQ
IDIV ECX
MOV EAX,dword ptr [RSP + 0x38]
IMUL ECX,EDX,0x6
ADD ECX,0x3
SAR EAX,CL
AND EAX,0x7
SHL EAX,0x1
ADD EAX,0x1
CVTSI2SS XMM1,EAX
MULSS XMM0,XMM1
MOVSS dword ptr [RSP + 0x64],XMM0
MOV RAX,qword ptr [RSP + 0x78]
MOVZX EAX,byte ptr [RAX]
MOV RCX,qword ptr [RSP + 0x70]
MOVZX ECX,byte ptr [RCX]
SHL ECX,0x8
AND ECX,0x700
OR EAX,ECX
MOV word ptr [RSP + 0x98],AX
MOV RAX,qword ptr [RSP + 0x78]
MOVZX EAX,byte ptr [RAX + 0x1]
MOV RCX,qword ptr [RSP + 0x70]
MOVZX ECX,byte ptr [RCX]
SHL ECX,0x4
AND ECX,0x700
OR EAX,ECX
MOV word ptr [RSP + 0x9a],AX
MOV RAX,qword ptr [RSP + 0x78]
MOVZX EAX,byte ptr [RAX + 0x2]
MOV RCX,qword ptr [RSP + 0x70]
MOVZX ECX,byte ptr [RCX + 0x1]
SHL ECX,0x8
AND ECX,0x700
OR EAX,ECX
MOV word ptr [RSP + 0x9c],AX
MOV RAX,qword ptr [RSP + 0x78]
MOVZX EAX,byte ptr [RAX + 0x3]
MOV RCX,qword ptr [RSP + 0x70]
MOVZX ECX,byte ptr [RCX + 0x1]
SHL ECX,0x4
AND ECX,0x700
OR EAX,ECX
MOV word ptr [RSP + 0x9e],AX
MOV RAX,qword ptr [RSP + 0x70]
MOVZX EAX,byte ptr [RAX]
AND EAX,0x8
MOVSS XMM0,dword ptr [0x001b86f8]
MOVSS XMM1,dword ptr [0x001b86fc]
MOVSS dword ptr [RSP + 0x3c],XMM1
CMP EAX,0x0
MOVSS dword ptr [RSP + 0x40],XMM0
JNZ 0x0017aa47
MOVSS XMM0,dword ptr [RSP + 0x3c]
MOVSS dword ptr [RSP + 0x40],XMM0
LAB_0017aa47:
MOVSS XMM0,dword ptr [RSP + 0x40]
MOVSS dword ptr [RSP + 0xa0],XMM0
MOV RAX,qword ptr [RSP + 0x70]
MOVZX EAX,byte ptr [RAX]
AND EAX,0x80
MOVSS XMM0,dword ptr [0x001b86f8]
MOVSS XMM1,dword ptr [0x001b86fc]
MOVSS dword ptr [RSP + 0x18],XMM1
CMP EAX,0x0
MOVSS dword ptr [RSP + 0x1c],XMM0
JNZ 0x0017aa90
MOVSS XMM0,dword ptr [RSP + 0x18]
MOVSS dword ptr [RSP + 0x1c],XMM0
LAB_0017aa90:
MOVSS XMM0,dword ptr [RSP + 0x1c]
MOVSS dword ptr [RSP + 0xa4],XMM0
MOV RAX,qword ptr [RSP + 0x70]
MOVZX EAX,byte ptr [RAX + 0x1]
AND EAX,0x8
MOVSS XMM0,dword ptr [0x001b86f8]
MOVSS XMM1,dword ptr [0x001b86fc]
MOVSS dword ptr [RSP + 0x10],XMM1
CMP EAX,0x0
MOVSS dword ptr [RSP + 0x14],XMM0
JNZ 0x0017aad8
MOVSS XMM0,dword ptr [RSP + 0x10]
MOVSS dword ptr [RSP + 0x14],XMM0
LAB_0017aad8:
MOVSS XMM0,dword ptr [RSP + 0x14]
MOVSS dword ptr [RSP + 0xa8],XMM0
MOV RAX,qword ptr [RSP + 0x70]
MOVZX EAX,byte ptr [RAX + 0x1]
AND EAX,0x80
MOVSS XMM0,dword ptr [0x001b86f8]
MOVSS XMM1,dword ptr [0x001b86fc]
MOVSS dword ptr [RSP + 0x8],XMM1
CMP EAX,0x0
MOVSS dword ptr [RSP + 0xc],XMM0
JNZ 0x0017ab22
MOVSS XMM0,dword ptr [RSP + 0x8]
MOVSS dword ptr [RSP + 0xc],XMM0
LAB_0017ab22:
MOVSS XMM0,dword ptr [RSP + 0xc]
MOVSS dword ptr [RSP + 0xac],XMM0
MOV dword ptr [RSP + 0x60],0x0
LAB_0017ab39:
CMP dword ptr [RSP + 0x60],0x2
JGE 0x0017abe3
MOVSXD RAX,dword ptr [RSP + 0x60]
MOVZX EAX,word ptr [RSP + RAX*0x2 + 0x98]
MOVSXD RCX,EAX
LEA RAX,[0x1bcc90]
SHL RCX,0x3
ADD RAX,RCX
MOV qword ptr [RSP + 0x58],RAX
MOV dword ptr [RSP + 0x54],0x0
LAB_0017ab6f:
CMP dword ptr [RSP + 0x54],0x8
JGE 0x0017abbf
MOVSS XMM0,dword ptr [RSP + 0x68]
MOV RAX,qword ptr [RSP + 0x58]
MOVSXD RCX,dword ptr [RSP + 0x54]
MOVSX EAX,byte ptr [RAX + RCX*0x1]
CVTSI2SS XMM1,EAX
MOVSXD RAX,dword ptr [RSP + 0x60]
ADDSS XMM1,dword ptr [RSP + RAX*0x4 + 0xa0]
MULSS XMM0,XMM1
MOV RAX,qword ptr [RSP + 0xc8]
MOVSXD RCX,dword ptr [RSP + 0x54]
MOVSS dword ptr [RAX + RCX*0x4],XMM0
MOV EAX,dword ptr [RSP + 0x54]
ADD EAX,0x1
MOV dword ptr [RSP + 0x54],EAX
JMP 0x0017ab6f
LAB_0017abbf:
MOV RAX,qword ptr [RSP + 0xc8]
ADD RAX,0x20
MOV qword ptr [RSP + 0xc8],RAX
MOV EAX,dword ptr [RSP + 0x60]
ADD EAX,0x1
MOV dword ptr [RSP + 0x60],EAX
JMP 0x0017ab39
LAB_0017abe3:
MOV dword ptr [RSP + 0x50],0x2
LAB_0017abeb:
CMP dword ptr [RSP + 0x50],0x4
JGE 0x0017ac95
MOVSXD RAX,dword ptr [RSP + 0x50]
MOVZX EAX,word ptr [RSP + RAX*0x2 + 0x98]
MOVSXD RCX,EAX
LEA RAX,[0x1bcc90]
SHL RCX,0x3
ADD RAX,RCX
MOV qword ptr [RSP + 0x48],RAX
MOV dword ptr [RSP + 0x44],0x0
LAB_0017ac21:
CMP dword ptr [RSP + 0x44],0x8
JGE 0x0017ac71
MOVSS XMM0,dword ptr [RSP + 0x64]
MOV RAX,qword ptr [RSP + 0x48]
MOVSXD RCX,dword ptr [RSP + 0x44]
MOVSX EAX,byte ptr [RAX + RCX*0x1]
CVTSI2SS XMM1,EAX
MOVSXD RAX,dword ptr [RSP + 0x50]
ADDSS XMM1,dword ptr [RSP + RAX*0x4 + 0xa0]
MULSS XMM0,XMM1
MOV RAX,qword ptr [RSP + 0xc8]
MOVSXD RCX,dword ptr [RSP + 0x44]
MOVSS dword ptr [RAX + RCX*0x4],XMM0
MOV EAX,dword ptr [RSP + 0x44]
ADD EAX,0x1
MOV dword ptr [RSP + 0x44],EAX
JMP 0x0017ac21
LAB_0017ac71:
MOV RAX,qword ptr [RSP + 0xc8]
ADD RAX,0x20
MOV qword ptr [RSP + 0xc8],RAX
MOV EAX,dword ptr [RSP + 0x50]
ADD EAX,0x1
MOV dword ptr [RSP + 0x50],EAX
JMP 0x0017abeb
LAB_0017ac95:
MOV RAX,qword ptr [RSP + 0x78]
ADD RAX,0x4
MOV qword ptr [RSP + 0x78],RAX
MOV RAX,qword ptr [RSP + 0x70]
ADD RAX,0x2
MOV qword ptr [RSP + 0x70],RAX
MOV EAX,dword ptr [RSP + 0x6c]
ADD EAX,0x1
MOV dword ptr [RSP + 0x6c],EAX
JMP 0x0017a8af
LAB_0017acc1:
JMP 0x0017acc3
LAB_0017acc3:
MOV EAX,dword ptr [RSP + 0x90]
ADD EAX,0x1
MOV dword ptr [RSP + 0x90],EAX
JMP 0x0017a7c4
LAB_0017acd9:
ADD RSP,0xd8
RET
|
void dequantize_row_iq1_m(long param_1,long param_2,long param_3)
{
ushort uVar1;
ushort uVar2;
ushort uVar3;
long lVar4;
ushort *puVar5;
float fVar6;
float local_cc;
float local_c4;
float local_bc;
float local_98;
int local_94;
int local_88;
int local_84;
int local_78;
int local_6c;
byte *local_68;
byte *local_60;
int local_48;
ushort local_40 [4];
float local_38 [6];
long local_20;
long local_18;
long local_10;
long local_8;
local_20 = param_3 / 0x100;
local_18 = param_3;
local_10 = param_2;
local_8 = param_1;
for (local_48 = 0; local_48 < local_20; local_48 = local_48 + 1) {
lVar4 = local_8 + (long)local_48 * 0x38;
puVar5 = (ushort *)(lVar4 + 0x30);
fVar6 = (float)ggml_lookup_fp16_to_fp32
((ushort)((int)(uint)*puVar5 >> 0xc) |
*(ushort *)(lVar4 + 0x32) >> 8 & 0xf0 |
(ushort)((int)(uint)*(ushort *)(lVar4 + 0x34) >> 4) & 0xf00 |
*(ushort *)(lVar4 + 0x36) & 0xf000);
local_60 = (byte *)(local_8 + (long)local_48 * 0x38);
local_68 = (byte *)(local_8 + (long)local_48 * 0x38 + 0x20);
for (local_6c = 0; local_6c < 8; local_6c = local_6c + 1) {
uVar1 = puVar5[local_6c / 2];
uVar2 = puVar5[local_6c / 2];
local_40[0] = (ushort)*local_60 | (ushort)((*local_68 & 7) << 8);
local_40[1] = (ushort)local_60[1] | (ushort)((*local_68 & 0x70) << 4);
local_40[2] = (ushort)local_60[2] | (ushort)((local_68[1] & 7) << 8);
local_40[3] = (ushort)local_60[3] | (ushort)((local_68[1] & 0x70) << 4);
local_98 = DAT_001b86f8;
if ((*local_68 & 8) == 0) {
local_98 = DAT_001b86fc;
}
local_38[0] = local_98;
local_bc = DAT_001b86f8;
if ((*local_68 & 0x80) == 0) {
local_bc = DAT_001b86fc;
}
local_38[1] = local_bc;
local_c4 = DAT_001b86f8;
if ((local_68[1] & 8) == 0) {
local_c4 = DAT_001b86fc;
}
local_38[2] = local_c4;
local_cc = DAT_001b86f8;
if ((local_68[1] & 0x80) == 0) {
local_cc = DAT_001b86fc;
}
local_38[3] = local_cc;
for (local_78 = 0; local_78 < 2; local_78 = local_78 + 1) {
uVar3 = local_40[local_78];
for (local_84 = 0; local_84 < 8; local_84 = local_84 + 1) {
*(float *)(local_10 + (long)local_84 * 4) =
fVar6 * (float)(((int)(uint)uVar1 >> ((char)(local_6c % 2) * '\x06' & 0x1fU) & 7U) *
2 + 1) *
((float)(int)(char)iq1s_grid[(long)local_84 + (long)(int)(uint)uVar3 * 8] +
local_38[local_78]);
}
local_10 = local_10 + 0x20;
}
for (local_88 = 2; local_88 < 4; local_88 = local_88 + 1) {
uVar1 = local_40[local_88];
for (local_94 = 0; local_94 < 8; local_94 = local_94 + 1) {
*(float *)(local_10 + (long)local_94 * 4) =
fVar6 * (float)(((int)(uint)uVar2 >>
((char)((long)local_6c % 2) * '\x06' + 3U & 0x1f) & 7U) * 2 + 1) *
((float)(int)(char)iq1s_grid[(long)local_94 + (long)(int)(uint)uVar1 * 8] +
local_38[local_88]);
}
local_10 = local_10 + 0x20;
}
local_60 = local_60 + 4;
local_68 = local_68 + 2;
}
}
return;
}
|
|
19,960
|
SchemaConverter::_not_strings(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&)
|
monkey531[P]llama/common/json-schema-to-grammar.cpp
|
std::string _not_strings(const std::vector<std::string> & strings) {
struct TrieNode {
std::map<char, TrieNode> children;
bool is_end_of_string;
TrieNode() : is_end_of_string(false) {}
void insert(const std::string & string) {
auto node = this;
for (char c : string) {
node = &node->children[c];
}
node->is_end_of_string = true;
}
};
TrieNode trie;
for (const auto & s : strings) {
trie.insert(s);
}
std::string char_rule = _add_primitive("char", PRIMITIVE_RULES.at("char"));
std::ostringstream out;
out << "[\"] ( ";
std::function<void(const TrieNode &)> visit = [&](const TrieNode & node) {
std::ostringstream rejects;
auto first = true;
for (const auto & kv : node.children) {
rejects << kv.first;
if (first) {
first = false;
} else {
out << " | ";
}
out << "[" << kv.first << "]";
if (!kv.second.children.empty()) {
out << " (";
visit(kv.second);
out << ")";
} else if (kv.second.is_end_of_string) {
out << " " << char_rule << "+";
}
}
if (!node.children.empty()) {
if (!first) {
out << " | ";
}
out << "[^\"" << rejects.str() << "] " << char_rule << "*";
}
};
visit(trie);
out << " )";
if (!trie.is_end_of_string) {
out << "?";
}
out << " [\"] space";
return out.str();
}
|
O3
|
cpp
|
SchemaConverter::_not_strings(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1f8, %rsp # imm = 0x1F8
movq %rsi, %r12
movq %rdi, %rbx
leaq 0x50(%rsp), %rax
movl $0x0, (%rax)
xorl %ecx, %ecx
movq %rcx, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %rcx, 0x20(%rax)
movb $0x0, 0x28(%rax)
movq (%rdx), %r14
movq 0x8(%rdx), %r13
cmpq %r13, %r14
je 0xa4c9b
leaq 0x48(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0xa5412
addq $0x20, %r14
cmpq %r13, %r14
jne 0xa4c87
leaq 0x90(%rsp), %r13
movq %r13, -0x10(%r13)
movl $0x72616863, %eax # imm = 0x72616863
movl %eax, (%r13)
movl $0x4, %ecx
movq %rcx, -0x8(%r13)
xorl %edx, %edx
movb %dl, 0x4(%r13)
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movl %eax, (%rbp)
movq %rcx, -0x8(%rbp)
movb %dl, 0x4(%rbp)
leaq 0x3d69f(%rip), %rdi # 0xe2378
leaq 0x8(%rsp), %r14
movq %r14, %rsi
callq 0xa8f8e
testq %rax, %rax
je 0xa4e89
addq $0x28, %rax
leaq 0x28(%rsp), %r15
leaq 0x80(%rsp), %rdx
movq %r15, %rdi
movq %r12, %rsi
movq %rax, %rcx
callq 0xa3a68
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0xa4d25
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186e0
movq 0x80(%rsp), %rdi
cmpq %r13, %rdi
je 0xa4d42
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x186e0
leaq 0x80(%rsp), %rdi
callq 0x18900
leaq 0x10cdd(%rip), %rsi # 0xb5a33
leaq 0x80(%rsp), %r12
movl $0x6, %edx
movq %r12, %rdi
callq 0x187c0
movq $0x0, 0x10(%rsp)
movl $0x18, %edi
callq 0x186d0
movq %r12, (%rax)
movq %r14, 0x8(%rax)
movq %r15, 0x10(%rax)
movq %rax, 0x8(%rsp)
leaq 0x967(%rip), %rcx # 0xa56fc
movq %rcx, 0x20(%rsp)
leaq 0x963(%rip), %rcx # 0xa5704
movq %rcx, 0x18(%rsp)
leaq 0x48(%rsp), %rsi
movq %rax, %rdi
callq 0xa572c
leaq 0x109b4(%rip), %rsi # 0xb576e
leaq 0x80(%rsp), %rdi
movl $0x2, %edx
callq 0x187c0
cmpb $0x0, 0x78(%rsp)
jne 0xa4dec
leaq 0x10ac2(%rip), %rsi # 0xb589c
leaq 0x80(%rsp), %rdi
movl $0x1, %edx
callq 0x187c0
leaq 0x10c47(%rip), %rsi # 0xb5a3a
leaq 0x80(%rsp), %rdi
movl $0xa, %edx
callq 0x187c0
leaq 0x88(%rsp), %rsi
movq %rbx, %rdi
callq 0x18ac0
movq 0x18(%rsp), %rax
testq %rax, %rax
je 0xa4e2e
leaq 0x8(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x3c153(%rip), %rsi # 0xe0f88
leaq 0x80(%rsp), %rdi
callq 0x183d0
leaq 0xf0(%rsp), %rdi
callq 0x18210
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa4e6a
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x186e0
leaq 0x48(%rsp), %rdi
callq 0xa5a2e
movq %rbx, %rax
addq $0x1f8, %rsp # imm = 0x1F8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x10b51(%rip), %rdi # 0xb59e1
callq 0x18a00
jmp 0xa4f31
jmp 0xa4e9c
movq %rax, %rbx
jmp 0xa4ef3
movq %rax, %rbx
jmp 0xa4f14
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0xa4ec0
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x186e0
movq 0x80(%rsp), %rdi
cmpq %r13, %rdi
je 0xa4f3c
movq 0x90(%rsp), %rsi
jmp 0xa4f27
movq %rax, %rbx
movq 0x18(%rsp), %rax
testq %rax, %rax
je 0xa4ef3
leaq 0x8(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x3c08e(%rip), %rsi # 0xe0f88
leaq 0x80(%rsp), %rdi
callq 0x183d0
leaq 0xf0(%rsp), %rdi
callq 0x18210
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa4f3c
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x186e0
jmp 0xa4f3c
movq %rax, %rdi
callq 0x1f25d
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0xa5a2e
movq %rbx, %rdi
callq 0x18c10
|
_ZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 1F8h
mov r12, rsi
mov rbx, rdi
lea rax, [rsp+228h+var_1D8]
mov dword ptr [rax], 0
xor ecx, ecx
mov [rax+8], rcx
mov [rax+10h], rax
mov [rax+18h], rax
mov [rax+20h], rcx
mov byte ptr [rax+28h], 0
mov r14, [rdx]
mov r13, [rdx+8]
cmp r14, r13
jz short loc_A4C9B
lea r15, [rsp+228h+var_1E0]
loc_A4C87:
mov rdi, r15
mov rsi, r14
call _ZZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EEEN8TrieNode6insertERKS6_; SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode::insert(std::string const&)
add r14, 20h ; ' '
cmp r14, r13
jnz short loc_A4C87
loc_A4C9B:
lea r13, [rsp+228h+var_198]
mov [r13-10h], r13
mov eax, 72616863h
mov [r13+0], eax
mov ecx, 4
mov [r13-8], rcx
xor edx, edx
mov [r13+4], dl
lea rbp, [rsp+228h+var_210]
mov [rbp-10h], rbp
mov [rbp+0], eax
mov [rbp-8], rcx
mov [rbp+4], dl
lea rdi, _Z15PRIMITIVE_RULESB5cxx11; PRIMITIVE_RULES
lea r14, [rsp+228h+var_220]
mov rsi, r14
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_11BuiltinRuleESaIS9_ENSt8__detail10_Select1stESt8equal_toIS5_ESt4hashIS5_ENSB_18_Mod_range_hashingENSB_20_Default_ranged_hashENSB_20_Prime_rehash_policyENSB_17_Hashtable_traitsILb1ELb0ELb1EEEE4findERS7_; std::_Hashtable<std::string,std::pair<std::string const,BuiltinRule>,std::allocator<std::pair<std::string const,BuiltinRule>>,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&)
test rax, rax
jz loc_A4E89
add rax, 28h ; '('
lea r15, [rsp+228h+var_200]
lea rdx, [rsp+228h+var_1A8]; int
mov rdi, r15; int
mov rsi, r12; int
mov rcx, rax; int
call _ZN15SchemaConverter14_add_primitiveERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERK11BuiltinRule; SchemaConverter::_add_primitive(std::string const&,BuiltinRule const&)
mov rdi, [rsp+228h+var_220]; void *
cmp rdi, rbp
jz short loc_A4D25
mov rsi, [rsp+228h+var_210]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A4D25:
mov rdi, [rsp+228h+var_1A8]; void *
cmp rdi, r13
jz short loc_A4D42
mov rsi, [rsp+228h+var_198]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A4D42:
lea rdi, [rsp+228h+var_1A8]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::ostringstream::basic_ostringstream(void)
lea rsi, asc_B5A33; "[\"] ( "
lea r12, [rsp+228h+var_1A8]
mov edx, 6
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 [rsp+228h+var_218], 0
mov edi, 18h; unsigned __int64
call __Znwm; operator new(ulong)
mov [rax], r12
mov [rax+8], r14
mov [rax+10h], r15
mov [rsp+228h+var_220], rax
lea rcx, _ZNSt17_Function_handlerIFvRKZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEE8TrieNodeEZNS0_12_not_stringsESB_EUlSE_E_E9_M_invokeERKSt9_Any_dataSE_; std::_Function_handler<void ()(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&),SchemaConverter::_not_strings(std::vector<std::string> const&)::{lambda(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&)#1}>::_M_invoke(std::_Any_data const&,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&)
mov [rsp+228h+var_208], rcx
lea rcx, _ZNSt17_Function_handlerIFvRKZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEE8TrieNodeEZNS0_12_not_stringsESB_EUlSE_E_E10_M_managerERSt9_Any_dataRKSI_St18_Manager_operation; std::_Function_handler<void ()(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&),SchemaConverter::_not_strings(std::vector<std::string> const&)::{lambda(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&)#1}>::_M_manager(std::_Any_data &,std::_Any_data const&,std::_Manager_operation)
mov [rsp+228h+var_210], rcx
lea rsi, [rsp+228h+var_1E0]
mov rdi, rax
call _ZZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EEENKUlRKZNS_12_not_stringsESA_E8TrieNodeE_clESD_; SchemaConverter::_not_strings(std::vector<std::string> const&)::{lambda(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&)#1}::operator()(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&)
lea rsi, a09401910201912+50h; " )"
lea rdi, [rsp+228h+var_1A8]
mov edx, 2
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
cmp [rsp+228h+var_1B0], 0
jnz short loc_A4DEC
lea rsi, asc_B5899+3; "?"
lea rdi, [rsp+228h+var_1A8]
mov edx, 1
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
loc_A4DEC:
lea rsi, aSpace_6; " [\"] space"
lea rdi, [rsp+228h+var_1A8]
mov edx, 0Ah
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, [rsp+228h+var_1A0]
mov rdi, rbx
call __ZNKSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void)
mov rax, [rsp+228h+var_210]
test rax, rax
jz short loc_A4E2E
lea rdi, [rsp+228h+var_220]
mov rsi, rdi
mov edx, 3
call rax
loc_A4E2E:
mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+228h+var_1A8]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream()
lea rdi, [rsp+228h+var_138]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
lea rax, [rsp+228h+var_1F0]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_A4E6A
mov rsi, [rsp+228h+var_1F0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A4E6A:
lea rdi, [rsp+228h+var_1E0]
call _ZNSt8_Rb_treeIcSt4pairIKcZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS9_EEE8TrieNodeESt10_Select1stISF_ESt4lessIcESaISF_EED2Ev; std::_Rb_tree<char,std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>,std::_Select1st<std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>>,std::less<char>,std::allocator<std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>>>::~_Rb_tree()
mov rax, rbx
add rsp, 1F8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_A4E89:
lea rdi, aMapBaseAt; "_Map_base::at"
call __ZSt20__throw_out_of_rangePKc; std::__throw_out_of_range(char const*)
jmp loc_A4F31
jmp short $+2
loc_A4E9C:
mov rbx, rax
jmp short loc_A4EF3
mov rbx, rax
jmp short loc_A4F14
mov rbx, rax
mov rdi, [rsp+228h+var_220]; void *
cmp rdi, rbp
jz short loc_A4EC0
mov rsi, [rsp+228h+var_210]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_A4EC0:
mov rdi, [rsp+228h+var_1A8]
cmp rdi, r13
jz short loc_A4F3C
mov rsi, [rsp+228h+var_198]
jmp short loc_A4F27
mov rbx, rax
mov rax, [rsp+228h+var_210]
test rax, rax
jz short loc_A4EF3
lea rdi, [rsp+228h+var_220]
mov rsi, rdi
mov edx, 3
call rax
loc_A4EF3:
mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+228h+var_1A8]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream()
lea rdi, [rsp+228h+var_138]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
loc_A4F14:
lea rax, [rsp+228h+var_1F0]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_A4F3C
mov rsi, [rsp+228h+var_1F0]
loc_A4F27:
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_A4F3C
loc_A4F31:
mov rdi, rax
call __clang_call_terminate
mov rbx, rax
loc_A4F3C:
lea rdi, [rsp+228h+var_1E0]
call _ZNSt8_Rb_treeIcSt4pairIKcZN15SchemaConverter12_not_stringsERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS9_EEE8TrieNodeESt10_Select1stISF_ESt4lessIcESaISF_EED2Ev; std::_Rb_tree<char,std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>,std::_Select1st<std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>>,std::less<char>,std::allocator<std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>>>::~_Rb_tree()
mov rdi, rbx
call __Unwind_Resume
|
long long SchemaConverter::_not_strings(long long a1, long long a2, long long *a3)
{
long long v3; // r14
long long v4; // r13
long long v5; // rax
void ***v6; // rax
void *v8; // [rsp+8h] [rbp-220h] BYREF
long long v9; // [rsp+10h] [rbp-218h]
_QWORD v10[2]; // [rsp+18h] [rbp-210h] BYREF
int v11[4]; // [rsp+28h] [rbp-200h] BYREF
long long v12; // [rsp+38h] [rbp-1F0h] BYREF
_BYTE v13[8]; // [rsp+48h] [rbp-1E0h] BYREF
int v14; // [rsp+50h] [rbp-1D8h] BYREF
long long v15; // [rsp+58h] [rbp-1D0h]
int *v16; // [rsp+60h] [rbp-1C8h]
int *v17; // [rsp+68h] [rbp-1C0h]
long long v18; // [rsp+70h] [rbp-1B8h]
char v19; // [rsp+78h] [rbp-1B0h]
void *v20; // [rsp+80h] [rbp-1A8h] BYREF
long long v21; // [rsp+88h] [rbp-1A0h] BYREF
char v22[96]; // [rsp+90h] [rbp-198h] BYREF
_BYTE v23[312]; // [rsp+F0h] [rbp-138h] BYREF
v14 = 0;
v15 = 0LL;
v16 = &v14;
v17 = &v14;
v18 = 0LL;
v19 = 0;
v3 = *a3;
v4 = a3[1];
if ( *a3 != v4 )
{
do
{
SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode::insert(v13, v3);
v3 += 32LL;
}
while ( v3 != v4 );
}
v20 = v22;
strcpy(v22, "char");
v21 = 4LL;
v8 = v10;
strcpy((char *)v10, "char");
v9 = 4LL;
v5 = std::_Hashtable<std::string,std::pair<std::string const,BuiltinRule>,std::allocator<std::pair<std::string const,BuiltinRule>>,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(
PRIMITIVE_RULES[abi:cxx11],
&v8);
if ( !v5 )
std::__throw_out_of_range("_Map_base::at");
SchemaConverter::_add_primitive((long long)v11, a2, (long long)&v20, (_QWORD *)(v5 + 40));
if ( v8 != v10 )
operator delete(v8, v10[0] + 1LL);
if ( v20 != v22 )
operator delete(v20, *(_QWORD *)v22 + 1LL);
std::ostringstream::basic_ostringstream(&v20);
std::__ostream_insert<char,std::char_traits<char>>(&v20, "[\"] ( ", 6LL);
v9 = 0LL;
v6 = (void ***)operator new(0x18uLL);
*v6 = &v20;
v6[1] = &v8;
v6[2] = (void **)v11;
v8 = v6;
v10[1] = std::_Function_handler<void ()(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&),SchemaConverter::_not_strings(std::vector<std::string> const&)::{lambda(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&)#1}>::_M_invoke;
v10[0] = std::_Function_handler<void ()(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&),SchemaConverter::_not_strings(std::vector<std::string> const&)::{lambda(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&)#1}>::_M_manager;
SchemaConverter::_not_strings(std::vector<std::string> const&)::{lambda(SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode const&)#1}::operator()(
v6,
v13);
std::__ostream_insert<char,std::char_traits<char>>(&v20, " )", 2LL);
if ( !v19 )
std::__ostream_insert<char,std::char_traits<char>>(&v20, "?", 1LL);
std::__ostream_insert<char,std::char_traits<char>>(&v20, " [\"] space", 10LL);
std::stringbuf::str(a1, &v21);
if ( v10[0] )
((void ( *)(void **, void **, long long))v10[0])(&v8, &v8, 3LL);
std::ostringstream::~ostringstream(&v20, &`VTT for'std::ostringstream);
std::ios_base::~ios_base((std::ios_base *)v23);
if ( *(long long **)v11 != &v12 )
operator delete(*(void **)v11, v12 + 1);
std::_Rb_tree<char,std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>,std::_Select1st<std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>>,std::less<char>,std::allocator<std::pair<char const,SchemaConverter::_not_strings(std::vector<std::string> const&)::TrieNode>>>::~_Rb_tree(v13);
return a1;
}
|
_not_strings:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x1f8
MOV R12,RSI
MOV RBX,RDI
LEA RAX,[RSP + 0x50]
MOV dword ptr [RAX],0x0
XOR ECX,ECX
MOV qword ptr [RAX + 0x8],RCX
MOV qword ptr [RAX + 0x10],RAX
MOV qword ptr [RAX + 0x18],RAX
MOV qword ptr [RAX + 0x20],RCX
MOV byte ptr [RAX + 0x28],0x0
MOV R14,qword ptr [RDX]
MOV R13,qword ptr [RDX + 0x8]
CMP R14,R13
JZ 0x001a4c9b
LEA R15,[RSP + 0x48]
LAB_001a4c87:
MOV RDI,R15
MOV RSI,R14
CALL 0x001a5412
ADD R14,0x20
CMP R14,R13
JNZ 0x001a4c87
LAB_001a4c9b:
LEA R13,[RSP + 0x90]
MOV qword ptr [R13 + -0x10],R13
MOV EAX,0x72616863
MOV dword ptr [R13],EAX
MOV ECX,0x4
MOV qword ptr [R13 + -0x8],RCX
XOR EDX,EDX
MOV byte ptr [R13 + 0x4],DL
LEA RBP,[RSP + 0x18]
MOV qword ptr [RBP + -0x10],RBP
MOV dword ptr [RBP],EAX
MOV qword ptr [RBP + -0x8],RCX
MOV byte ptr [RBP + 0x4],DL
LAB_001a4cd2:
LEA RDI,[0x1e2378]
LEA R14,[RSP + 0x8]
MOV RSI,R14
CALL 0x001a8f8e
TEST RAX,RAX
JZ 0x001a4e89
ADD RAX,0x28
LEA R15,[RSP + 0x28]
LEA RDX,[RSP + 0x80]
MOV RDI,R15
MOV RSI,R12
MOV RCX,RAX
CALL 0x001a3a68
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,RBP
JZ 0x001a4d25
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001186e0
LAB_001a4d25:
MOV RDI,qword ptr [RSP + 0x80]
CMP RDI,R13
JZ 0x001a4d42
MOV RSI,qword ptr [RSP + 0x90]
INC RSI
CALL 0x001186e0
LAB_001a4d42:
LEA RDI,[RSP + 0x80]
CALL 0x00118900
LAB_001a4d4f:
LEA RSI,[0x1b5a33]
LEA R12,[RSP + 0x80]
MOV EDX,0x6
MOV RDI,R12
CALL 0x001187c0
MOV qword ptr [RSP + 0x10],0x0
LAB_001a4d74:
MOV EDI,0x18
CALL 0x001186d0
MOV qword ptr [RAX],R12
MOV qword ptr [RAX + 0x8],R14
MOV qword ptr [RAX + 0x10],R15
MOV qword ptr [RSP + 0x8],RAX
LEA RCX,[0x1a56fc]
MOV qword ptr [RSP + 0x20],RCX
LEA RCX,[0x1a5704]
MOV qword ptr [RSP + 0x18],RCX
LAB_001a4da6:
LEA RSI,[RSP + 0x48]
MOV RDI,RAX
CALL 0x001a572c
LEA RSI,[0x1b576e]
LEA RDI,[RSP + 0x80]
MOV EDX,0x2
CALL 0x001187c0
CMP byte ptr [RSP + 0x78],0x0
JNZ 0x001a4dec
LEA RSI,[0x1b589c]
LEA RDI,[RSP + 0x80]
MOV EDX,0x1
CALL 0x001187c0
LAB_001a4dec:
LEA RSI,[0x1b5a3a]
LEA RDI,[RSP + 0x80]
MOV EDX,0xa
CALL 0x001187c0
LEA RSI,[RSP + 0x88]
MOV RDI,RBX
CALL 0x00118ac0
MOV RAX,qword ptr [RSP + 0x18]
TEST RAX,RAX
JZ 0x001a4e2e
LAB_001a4e1f:
LEA RDI,[RSP + 0x8]
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_001a4e2e:
MOV RSI,qword ptr [0x001e0f88]
LEA RDI,[RSP + 0x80]
CALL 0x001183d0
LEA RDI,[RSP + 0xf0]
CALL 0x00118210
LEA RAX,[RSP + 0x38]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x001a4e6a
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x001186e0
LAB_001a4e6a:
LEA RDI,[RSP + 0x48]
CALL 0x001a5a2e
MOV RAX,RBX
ADD RSP,0x1f8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001a4e89:
LEA RDI,[0x1b59e1]
CALL 0x00118a00
LAB_001a4e95:
JMP 0x001a4f31
LAB_001a4f31:
MOV RDI,RAX
CALL 0x0011f25d
|
/* SchemaConverter::_not_strings(std::vector<std::__cxx11::string,
std::allocator<std::__cxx11::string > > const&) */
vector * SchemaConverter::_not_strings(vector *param_1)
{
long lVar1;
int8 uVar2;
long *in_RDX;
BuiltinRule *in_RSI;
long lVar3;
_lambda_SchemaConverter___not_strings_std__vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const____TrieNode_const___1_
*local_220;
int8 local_218;
code *local_210;
code *local_208;
long *local_200 [2];
long local_1f0 [2];
TrieNode local_1e0 [8];
int4 local_1d8 [2];
int8 local_1d0;
int4 *local_1c8;
int4 *local_1c0;
int8 local_1b8;
char local_1b0;
int4 *local_1a8;
int8 local_1a0;
int4 local_198;
uint uStack_194;
ios_base local_138 [264];
local_1c8 = local_1d8;
local_1d8[0] = 0;
local_1d0 = 0;
local_1b8 = 0;
local_1b0 = '\0';
lVar3 = *in_RDX;
lVar1 = in_RDX[1];
local_1c0 = local_1c8;
if (lVar3 != lVar1) {
do {
/* try { // try from 001a4c87 to 001a4c91 has its CatchHandler @ 001a4f39 */
_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::
TrieNode::insert(std::__cxx11::string_const__(local_1e0,lVar3);
lVar3 = lVar3 + 0x20;
} while (lVar3 != lVar1);
}
local_198 = 0x72616863;
local_1a0 = 4;
uStack_194 = uStack_194 & 0xffffff00;
local_218 = 4;
local_210 = (code *)CONCAT35(local_210._5_3_,0x72616863);
/* try { // try from 001a4cd2 to 001a4d0d has its CatchHandler @ 001a4ea6 */
local_220 = (_lambda_SchemaConverter___not_strings_std__vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const____TrieNode_const___1_
*)&local_210;
local_1a8 = &local_198;
lVar3 = std::
_Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,BuiltinRule>,std::allocator<std::pair<std::__cxx11::string_const,BuiltinRule>>,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,BuiltinRule>,std::allocator<std::pair<std::__cxx11::string_const,BuiltinRule>>,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>>
*)PRIMITIVE_RULES_abi_cxx11_,(string *)&local_220);
if (lVar3 != 0) {
_add_primitive((string *)local_200,in_RSI);
if (local_220 !=
(_lambda_SchemaConverter___not_strings_std__vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const____TrieNode_const___1_
*)&local_210) {
operator_delete(local_220,(ulong)(local_210 + 1));
}
if (local_1a8 != &local_198) {
operator_delete(local_1a8,CONCAT44(uStack_194,local_198) + 1);
}
/* try { // try from 001a4d42 to 001a4d4e has its CatchHandler @ 001a4ea1 */
std::__cxx11::ostringstream::ostringstream((ostringstream *)&local_1a8);
/* try { // try from 001a4d4f to 001a4d6a has its CatchHandler @ 001a4e9c */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)&local_1a8,"[\"] ( ",6);
local_218 = 0;
/* try { // try from 001a4d74 to 001a4d7d has its CatchHandler @ 001a4e9a */
local_220 = (_lambda_SchemaConverter___not_strings_std__vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const____TrieNode_const___1_
*)operator_new(0x18);
*(ostream **)local_220 = (ostream *)&local_1a8;
*(string **)(local_220 + 8) = (string *)&local_220;
*(string **)(local_220 + 0x10) = (string *)local_200;
local_208 = std::
_Function_handler<void(SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode_const&),SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::{lambda(SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode_const&)#1}>
::_M_invoke;
local_210 = std::
_Function_handler<void(SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode_const&),SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::{lambda(SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode_const&)#1}>
::_M_manager;
/* try { // try from 001a4da6 to 001a4e14 has its CatchHandler @ 001a4ed7 */
_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::
{lambda(SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode_const&)#1}
::operator()(local_220,local_1e0);
std::__ostream_insert<char,std::char_traits<char>>((ostream *)&local_1a8," )",2);
if (local_1b0 == '\0') {
std::__ostream_insert<char,std::char_traits<char>>((ostream *)&local_1a8,"?",1);
}
std::__ostream_insert<char,std::char_traits<char>>((ostream *)&local_1a8," [\"] space",10);
std::__cxx11::stringbuf::str();
if (local_210 != (code *)0x0) {
/* try { // try from 001a4e1f to 001a4e2d has its CatchHandler @ 001a4e95 */
(*local_210)(&local_220,&local_220,3);
}
std::__cxx11::ostringstream::~ostringstream((ostringstream *)&local_1a8);
std::ios_base::~ios_base(local_138);
if (local_200[0] != local_1f0) {
operator_delete(local_200[0],local_1f0[0] + 1);
}
std::
_Rb_tree<char,std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>,std::_Select1st<std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>>,std::less<char>,std::allocator<std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>>>
::~_Rb_tree((_Rb_tree<char,std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>,std::_Select1st<std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>>,std::less<char>,std::allocator<std::pair<char_const,SchemaConverter::_not_strings(std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>const&)::TrieNode>>>
*)local_1e0);
return param_1;
}
/* try { // try from 001a4e89 to 001a4e94 has its CatchHandler @ 001a4ea6 */
uVar2 = std::__throw_out_of_range("_Map_base::at");
/* catch(type#1 @ 00000000) { ... } // from try @ 001a4e1f with catch @ 001a4e95
*/
/* catch(type#1 @ 00000000) { ... } // from try @ 001a4ee4 with catch @ 001a4f31
*/
/* WARNING: Subroutine does not return */
__clang_call_terminate(uVar2);
}
|
|
19,961
|
coro::net::tls::context::context(coro::net::tls::verify_peer_t)
|
AlayaLite/build_O3/_deps/libcoro-src/src/net/tls/context.cpp
|
context::context(verify_peer_t verify_peer)
{
{
std::scoped_lock g{g_tls_context_mutex};
if (g_tls_context_count == 0)
{
#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER >= 0x10100000L
OPENSSL_init_ssl(0, nullptr);
#else
SSL_library_init();
#endif
}
++g_tls_context_count;
}
#if !defined(LIBRESSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER >= 0x10100000L
m_ssl_ctx = SSL_CTX_new(TLS_method());
#else
m_ssl_ctx = SSL_CTX_new(SSLv23_method());
#endif
if (m_ssl_ctx == nullptr)
{
throw std::runtime_error{"Failed to initialize OpenSSL Context object."};
}
// Disable SSLv3
SSL_CTX_set_options(m_ssl_ctx, SSL_OP_ALL | SSL_OP_NO_SSLv3);
// Abort handshake if certificate verification fails.
if (verify_peer == verify_peer_t::yes)
{
SSL_CTX_set_verify(m_ssl_ctx, SSL_VERIFY_PEER, NULL);
}
// Set the minimum TLS version, as of this TLSv1.1 or earlier are deprecated.
SSL_CTX_set_min_proto_version(m_ssl_ctx, TLS1_2_VERSION);
}
|
O3
|
cpp
|
coro::net::tls::context::context(coro::net::tls::verify_peer_t):
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebp
movq %rdi, %rbx
movq $0x0, (%rdi)
leaq 0x671cd(%rip), %rdi # 0x1345d8
callq 0x17370
testl %eax, %eax
jne 0xcd493
movq 0x671b5(%rip), %rax # 0x1345d0
testq %rax, %rax
jne 0xcd430
xorl %edi, %edi
xorl %esi, %esi
callq 0x17120
movq 0x671a0(%rip), %rax # 0x1345d0
incq %rax
movq %rax, 0x67196(%rip) # 0x1345d0
leaq 0x67197(%rip), %rdi # 0x1345d8
callq 0x17300
callq 0x176c0
movq %rax, %rdi
callq 0x177d0
movq %rax, (%rbx)
testq %rax, %rax
je 0xcd49a
movl $0x82000850, %esi # imm = 0x82000850
movq %rax, %rdi
callq 0x17670
testl %ebp, %ebp
jne 0xcd47b
movq (%rbx), %rdi
movl $0x1, %esi
xorl %edx, %edx
callq 0x17df0
movq (%rbx), %rdi
movl $0x303, %edx # imm = 0x303
movl $0x7b, %esi
xorl %ecx, %ecx
popq %rbx
popq %r14
popq %rbp
jmp 0x17dc0
movl %eax, %edi
callq 0x174d0
movl $0x10, %edi
callq 0x17490
movq %rax, %rbx
leaq 0x164c3(%rip), %rsi # 0xe3971
movq %rax, %rdi
callq 0x17320
movq 0x64af3(%rip), %rsi # 0x131fb0
movq 0x64aac(%rip), %rdx # 0x131f70
movq %rbx, %rdi
callq 0x17700
movq %rax, %r14
leaq 0x67102(%rip), %rdi # 0x1345d8
callq 0x17300
jmp 0xcd4e8
movq %rax, %r14
movq %rbx, %rdi
callq 0x17aa0
movq %r14, %rdi
callq 0x17740
|
_ZN4coro3net3tls7contextC2ENS1_13verify_peer_tE:
push rbp; Alternative name is 'coro::net::tls::context::context(coro::net::tls::verify_peer_t)'
push r14
push rbx
mov ebp, esi
mov rbx, rdi
mov qword ptr [rdi], 0
lea rdi, _ZN4coro3net3tlsL19g_tls_context_mutexE; coro::net::tls::g_tls_context_mutex
call _pthread_mutex_lock
test eax, eax
jnz short loc_CD493
mov rax, cs:_ZN4coro3net3tlsL19g_tls_context_countE; coro::net::tls::g_tls_context_count
test rax, rax
jnz short loc_CD430
xor edi, edi
xor esi, esi
call _OPENSSL_init_ssl
mov rax, cs:_ZN4coro3net3tlsL19g_tls_context_countE; coro::net::tls::g_tls_context_count
loc_CD430:
inc rax
mov cs:_ZN4coro3net3tlsL19g_tls_context_countE, rax; coro::net::tls::g_tls_context_count
lea rdi, _ZN4coro3net3tlsL19g_tls_context_mutexE; coro::net::tls::g_tls_context_mutex
call _pthread_mutex_unlock
call _TLS_method
mov rdi, rax
call _SSL_CTX_new
mov [rbx], rax
test rax, rax
jz short loc_CD49A
mov esi, 82000850h
mov rdi, rax
call _SSL_CTX_set_options
test ebp, ebp
jnz short loc_CD47B
mov rdi, [rbx]
mov esi, 1
xor edx, edx
call _SSL_CTX_set_verify
loc_CD47B:
mov rdi, [rbx]
mov edx, 303h
mov esi, 7Bh ; '{'
xor ecx, ecx
pop rbx
pop r14
pop rbp
jmp _SSL_CTX_ctrl
loc_CD493:
mov edi, eax; int
call __ZSt20__throw_system_errori; std::__throw_system_error(int)
loc_CD49A:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rsi, aFailedToInitia; "Failed to initialize OpenSSL Context ob"...
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
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, _ZN4coro3net3tlsL19g_tls_context_mutexE; coro::net::tls::g_tls_context_mutex
call _pthread_mutex_unlock
jmp short loc_CD4E8
mov r14, rax
mov rdi, rbx; void *
call ___cxa_free_exception
loc_CD4E8:
mov rdi, r14
call __Unwind_Resume
|
long long coro::net::tls::context::context(long long *a1, int a2)
{
int v2; // eax
long long v3; // rax
long long v4; // rax
long long v5; // rax
std::runtime_error *exception; // rbx
*a1 = 0LL;
v2 = pthread_mutex_lock(&coro::net::tls::g_tls_context_mutex);
if ( v2 )
std::__throw_system_error(v2);
v3 = coro::net::tls::g_tls_context_count;
if ( !coro::net::tls::g_tls_context_count )
{
OPENSSL_init_ssl(0LL, 0LL);
v3 = coro::net::tls::g_tls_context_count;
}
coro::net::tls::g_tls_context_count = v3 + 1;
pthread_mutex_unlock(&coro::net::tls::g_tls_context_mutex);
v4 = TLS_method();
v5 = SSL_CTX_new(v4);
*a1 = v5;
if ( !v5 )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Failed to initialize OpenSSL Context object.");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
SSL_CTX_set_options(v5, 2181040208LL);
if ( !a2 )
SSL_CTX_set_verify(*a1, 1LL, 0LL);
return SSL_CTX_ctrl(*a1, 123LL, 771LL, 0LL);
}
|
context:
PUSH RBP
PUSH R14
PUSH RBX
MOV EBP,ESI
MOV RBX,RDI
MOV qword ptr [RDI],0x0
LEA RDI,[0x2345d8]
CALL 0x00117370
TEST EAX,EAX
JNZ 0x001cd493
MOV RAX,qword ptr [0x002345d0]
TEST RAX,RAX
JNZ 0x001cd430
LAB_001cd420:
XOR EDI,EDI
XOR ESI,ESI
CALL 0x00117120
LAB_001cd429:
MOV RAX,qword ptr [0x002345d0]
LAB_001cd430:
INC RAX
MOV qword ptr [0x002345d0],RAX
LEA RDI,[0x2345d8]
CALL 0x00117300
CALL 0x001176c0
MOV RDI,RAX
CALL 0x001177d0
MOV qword ptr [RBX],RAX
TEST RAX,RAX
JZ 0x001cd49a
MOV ESI,0x82000850
MOV RDI,RAX
CALL 0x00117670
TEST EBP,EBP
JNZ 0x001cd47b
MOV RDI,qword ptr [RBX]
MOV ESI,0x1
XOR EDX,EDX
CALL 0x00117df0
LAB_001cd47b:
MOV RDI,qword ptr [RBX]
MOV EDX,0x303
MOV ESI,0x7b
XOR ECX,ECX
POP RBX
POP R14
POP RBP
JMP 0x00117dc0
LAB_001cd493:
MOV EDI,EAX
CALL 0x001174d0
LAB_001cd49a:
MOV EDI,0x10
CALL 0x00117490
MOV RBX,RAX
LAB_001cd4a7:
LEA RSI,[0x1e3971]
MOV RDI,RAX
CALL 0x00117320
LAB_001cd4b6:
MOV RSI,qword ptr [0x00231fb0]
MOV RDX,qword ptr [0x00231f70]
MOV RDI,RBX
CALL 0x00117700
|
/* coro::net::tls::context::context(coro::net::tls::verify_peer_t) */
void __thiscall coro::net::tls::context::context(context *this,int param_2)
{
int iVar1;
SSL_METHOD *meth;
SSL_CTX *pSVar2;
runtime_error *this_00;
*(int8 *)this = 0;
iVar1 = pthread_mutex_lock((pthread_mutex_t *)g_tls_context_mutex);
if (iVar1 == 0) {
if (g_tls_context_count == 0) {
/* try { // try from 001cd420 to 001cd428 has its CatchHandler @ 001cd4cc */
OPENSSL_init_ssl(0,0);
}
g_tls_context_count = g_tls_context_count + 1;
pthread_mutex_unlock((pthread_mutex_t *)g_tls_context_mutex);
meth = (SSL_METHOD *)TLS_method();
pSVar2 = SSL_CTX_new(meth);
*(SSL_CTX **)this = pSVar2;
if (pSVar2 != (SSL_CTX *)0x0) {
SSL_CTX_set_options(pSVar2,0x82000850);
if (param_2 == 0) {
SSL_CTX_set_verify(*(SSL_CTX **)this,1,(callback *)0x0);
}
SSL_CTX_ctrl(*(SSL_CTX **)this,0x7b,0x303,(void *)0x0);
return;
}
}
else {
std::__throw_system_error(iVar1);
}
this_00 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 001cd4a7 to 001cd4b5 has its CatchHandler @ 001cd4dd */
std::runtime_error::runtime_error(this_00,"Failed to initialize OpenSSL Context object.");
/* WARNING: Subroutine does not return */
__cxa_throw(this_00,PTR_typeinfo_00231fb0,PTR__runtime_error_00231f70);
}
|
|
19,962
|
ma_pvio_wait_io_or_timeout
|
eloqsql/libmariadb/libmariadb/ma_pvio.c
|
int ma_pvio_wait_io_or_timeout(MARIADB_PVIO *pvio, my_bool is_read, int timeout)
{
if (pvio)
{
if (IS_PVIO_ASYNC_ACTIVE(pvio))
return ma_pvio_wait_async(pvio->mysql->options.extension->async_context,
(is_read) ? VIO_IO_EVENT_READ : VIO_IO_EVENT_WRITE,
timeout);
if (pvio && pvio->methods->wait_io_or_timeout)
return pvio->methods->wait_io_or_timeout(pvio, is_read, timeout);
}
return 1;
}
|
O0
|
c
|
ma_pvio_wait_io_or_timeout:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movb %sil, %al
movq %rdi, -0x10(%rbp)
movb %al, -0x11(%rbp)
movl %edx, -0x18(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x4904b
movq -0x10(%rbp), %rax
cmpq $0x0, 0x40(%rax)
je 0x49013
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rax
cmpq $0x0, 0x480(%rax)
je 0x49013
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rax
movq 0x480(%rax), %rax
cmpq $0x0, 0x28(%rax)
je 0x49013
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movsbl 0x14(%rax), %eax
cmpl $0x0, %eax
je 0x49013
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rdi
movsbl -0x11(%rbp), %ecx
movl $0x1, %esi
xorl %eax, %eax
cmpl $0x0, %ecx
cmovnel %eax, %esi
movl -0x18(%rbp), %edx
callq 0x49060
movsbl %al, %eax
movl %eax, -0x4(%rbp)
jmp 0x49052
cmpq $0x0, -0x10(%rbp)
je 0x49049
movq -0x10(%rbp), %rax
movq 0x48(%rax), %rax
cmpq $0x0, 0x30(%rax)
je 0x49049
movq -0x10(%rbp), %rax
movq 0x48(%rax), %rax
movq 0x30(%rax), %rax
movq -0x10(%rbp), %rdi
movb -0x11(%rbp), %cl
movl -0x18(%rbp), %edx
movsbl %cl, %esi
callq *%rax
movl %eax, -0x4(%rbp)
jmp 0x49052
jmp 0x4904b
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
ma_pvio_wait_io_or_timeout:
push rbp
mov rbp, rsp
sub rsp, 20h
mov al, sil
mov [rbp+var_10], rdi
mov [rbp+var_11], al
mov [rbp+var_18], edx
cmp [rbp+var_10], 0
jz loc_4904B
mov rax, [rbp+var_10]
cmp qword ptr [rax+40h], 0
jz short loc_49013
mov rax, [rbp+var_10]
mov rax, [rax+40h]
cmp qword ptr [rax+480h], 0
jz short loc_49013
mov rax, [rbp+var_10]
mov rax, [rax+40h]
mov rax, [rax+480h]
cmp qword ptr [rax+28h], 0
jz short loc_49013
mov rax, [rbp+var_10]
mov rax, [rax+40h]
mov rax, [rax+480h]
mov rax, [rax+28h]
movsx eax, byte ptr [rax+14h]
cmp eax, 0
jz short loc_49013
mov rax, [rbp+var_10]
mov rax, [rax+40h]
mov rax, [rax+480h]
mov rdi, [rax+28h]
movsx ecx, [rbp+var_11]
mov esi, 1
xor eax, eax
cmp ecx, 0
cmovnz esi, eax
mov edx, [rbp+var_18]
call ma_pvio_wait_async
movsx eax, al
mov [rbp+var_4], eax
jmp short loc_49052
loc_49013:
cmp [rbp+var_10], 0
jz short loc_49049
mov rax, [rbp+var_10]
mov rax, [rax+48h]
cmp qword ptr [rax+30h], 0
jz short loc_49049
mov rax, [rbp+var_10]
mov rax, [rax+48h]
mov rax, [rax+30h]
mov rdi, [rbp+var_10]
mov cl, [rbp+var_11]
mov edx, [rbp+var_18]
movsx esi, cl
call rax
mov [rbp+var_4], eax
jmp short loc_49052
loc_49049:
jmp short $+2
loc_4904B:
mov [rbp+var_4], 1
loc_49052:
mov eax, [rbp+var_4]
add rsp, 20h
pop rbp
retn
|
long long ma_pvio_wait_io_or_timeout(long long a1, char a2, unsigned int a3)
{
if ( !a1 )
return 1;
if ( !*(_QWORD *)(a1 + 64)
|| !*(_QWORD *)(*(_QWORD *)(a1 + 64) + 1152LL)
|| !*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 64) + 1152LL) + 40LL)
|| !*(_BYTE *)(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 64) + 1152LL) + 40LL) + 20LL) )
{
if ( *(_QWORD *)(*(_QWORD *)(a1 + 72) + 48LL) )
return (unsigned int)(*(long long ( **)(long long, _QWORD, _QWORD))(*(_QWORD *)(a1 + 72) + 48LL))(
a1,
(unsigned int)a2,
a3);
return 1;
}
return (unsigned int)(char)ma_pvio_wait_async(
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 64) + 1152LL) + 40LL),
a2 == 0,
a3);
}
|
ma_pvio_wait_io_or_timeout:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV AL,SIL
MOV qword ptr [RBP + -0x10],RDI
MOV byte ptr [RBP + -0x11],AL
MOV dword ptr [RBP + -0x18],EDX
CMP qword ptr [RBP + -0x10],0x0
JZ 0x0014904b
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x40],0x0
JZ 0x00149013
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x40]
CMP qword ptr [RAX + 0x480],0x0
JZ 0x00149013
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x40]
MOV RAX,qword ptr [RAX + 0x480]
CMP qword ptr [RAX + 0x28],0x0
JZ 0x00149013
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x40]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOVSX EAX,byte ptr [RAX + 0x14]
CMP EAX,0x0
JZ 0x00149013
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x40]
MOV RAX,qword ptr [RAX + 0x480]
MOV RDI,qword ptr [RAX + 0x28]
MOVSX ECX,byte ptr [RBP + -0x11]
MOV ESI,0x1
XOR EAX,EAX
CMP ECX,0x0
CMOVNZ ESI,EAX
MOV EDX,dword ptr [RBP + -0x18]
CALL 0x00149060
MOVSX EAX,AL
MOV dword ptr [RBP + -0x4],EAX
JMP 0x00149052
LAB_00149013:
CMP qword ptr [RBP + -0x10],0x0
JZ 0x00149049
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x48]
CMP qword ptr [RAX + 0x30],0x0
JZ 0x00149049
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x48]
MOV RAX,qword ptr [RAX + 0x30]
MOV RDI,qword ptr [RBP + -0x10]
MOV CL,byte ptr [RBP + -0x11]
MOV EDX,dword ptr [RBP + -0x18]
MOVSX ESI,CL
CALL RAX
MOV dword ptr [RBP + -0x4],EAX
JMP 0x00149052
LAB_00149049:
JMP 0x0014904b
LAB_0014904b:
MOV dword ptr [RBP + -0x4],0x1
LAB_00149052:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x20
POP RBP
RET
|
int ma_pvio_wait_io_or_timeout(long param_1,char param_2,int4 param_3)
{
char cVar1;
int iVar2;
if (param_1 != 0) {
if ((((*(long *)(param_1 + 0x40) != 0) && (*(long *)(*(long *)(param_1 + 0x40) + 0x480) != 0))
&& (*(long *)(*(long *)(*(long *)(param_1 + 0x40) + 0x480) + 0x28) != 0)) &&
(*(char *)(*(long *)(*(long *)(*(long *)(param_1 + 0x40) + 0x480) + 0x28) + 0x14) != '\0')) {
cVar1 = ma_pvio_wait_async(*(int8 *)
(*(long *)(*(long *)(param_1 + 0x40) + 0x480) + 0x28),
param_2 == '\0',param_3);
return (int)cVar1;
}
if ((param_1 != 0) && (*(long *)(*(long *)(param_1 + 0x48) + 0x30) != 0)) {
iVar2 = (**(code **)(*(long *)(param_1 + 0x48) + 0x30))(param_1,(int)param_2,param_3,param_2);
return iVar2;
}
}
return 1;
}
|
|
19,963
|
Catch::ConsoleReporter::lazyPrintRunInfo()
|
AlayaLite/build_O3/_deps/libcoro-src/test/catch_amalgamated.cpp
|
void ConsoleReporter::lazyPrintRunInfo() {
m_stream << '\n'
<< lineOfChars( '~' ) << '\n'
<< m_colour->guardColour( Colour::SecondaryText )
<< currentTestRunInfo.name << " is a Catch2 v" << libraryVersion()
<< " host application.\n"
<< "Run with -? for options\n\n";
m_testRunInfoPrinted = true;
}
|
O3
|
cpp
|
Catch::ConsoleReporter::lazyPrintRunInfo():
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq 0x20(%rdi), %rdi
movq %rsp, %rsi
movb $0xa, (%rsi)
movl $0x1, %edx
callq 0x17be0
movq %rax, %r14
movl $0x4f, %r15d
movq %r14, %rdi
movl $0x7e, %esi
callq 0x17630
decq %r15
jne 0x6a507
movq %rsp, %rsi
movb $0xa, (%rsi)
movl $0x1, %edx
movq %r14, %rdi
callq 0x17be0
movq %rax, %r14
movq 0x28(%rbx), %rdx
movq %rsp, %r15
movq %r15, %rdi
movl $0x17, %esi
callq 0x5bc9a
movb $0x1, 0xc(%r15)
movq (%r15), %rdi
movl 0x8(%r15), %esi
movq (%rdi), %rax
callq *0x10(%rax)
movq 0x60(%rbx), %rsi
movq 0x68(%rbx), %rdx
movq %r14, %rdi
callq 0x17580
movq %rax, %r14
leaq 0x73d7b(%rip), %rsi # 0xde2ea
movl $0xe, %edx
movq %rax, %rdi
callq 0x17be0
callq 0x55032
leaq 0xc9ab0(%rip), %rsi # 0x134038
movq %r14, %rdi
callq 0x54f3f
leaq 0x73d62(%rip), %rsi # 0xde2f9
movl $0x13, %edx
movq %r14, %rdi
callq 0x17be0
leaq 0x73d62(%rip), %rsi # 0xde30d
movl $0x19, %edx
movq %r14, %rdi
callq 0x17be0
movq %rsp, %rdi
callq 0x5bce6
movb $0x1, 0x99(%rbx)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
movq %rsp, %rdi
callq 0x5bce6
movq %rbx, %rdi
callq 0x17740
|
_ZN5Catch15ConsoleReporter16lazyPrintRunInfoEv:
push r15
push r14
push rbx
sub rsp, 10h
mov rbx, rdi
mov rdi, [rdi+20h]
mov rsi, rsp
mov byte ptr [rsi], 0Ah
mov edx, 1
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov r14, rax
mov r15d, 4Fh ; 'O'
loc_6A507:
mov rdi, r14; this
mov esi, 7Eh ; '~'; char
call __ZNSo3putEc; std::ostream::put(char)
dec r15
jnz short loc_6A507
mov rsi, rsp
mov byte ptr [rsi], 0Ah
mov edx, 1
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 r14, rax
mov rdx, [rbx+28h]
mov r15, rsp
mov rdi, r15
mov esi, 17h
call _ZN5Catch10ColourImpl11ColourGuardC2ENS_6Colour4CodeEPKS0_; Catch::ColourImpl::ColourGuard::ColourGuard(Catch::Colour::Code,Catch::ColourImpl const*)
mov byte ptr [r15+0Ch], 1
mov rdi, [r15]
mov esi, [r15+8]
mov rax, [rdi]
call qword ptr [rax+10h]
mov rsi, [rbx+60h]; char *
mov rdx, [rbx+68h]; __int64
mov rdi, r14; this
call __ZNSo5writeEPKcl; std::ostream::write(char const*,long)
mov r14, rax
lea rsi, aIsACatch2V; " is a Catch2 v"
mov edx, 0Eh
mov rdi, rax; this
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
call _ZN5Catch14libraryVersionEv; Catch::libraryVersion(void)
lea rsi, _ZZN5Catch14libraryVersionEvE7version; Catch::libraryVersion(void)::version
mov rdi, r14
call _ZN5CatchlsERSoRKNS_7VersionE; Catch::operator<<(std::ostream &,Catch::Version const&)
lea rsi, aHostApplicatio; " host application.\n"
mov edx, 13h
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)
lea rsi, aRunWithForOpti; "Run with -? for options\n\n"
mov edx, 19h
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 rdi, rsp; this
call _ZN5Catch10ColourImpl11ColourGuardD2Ev; Catch::ColourImpl::ColourGuard::~ColourGuard()
mov byte ptr [rbx+99h], 1
add rsp, 10h
pop rbx
pop r14
pop r15
retn
mov rbx, rax
mov rdi, rsp; this
call _ZN5Catch10ColourImpl11ColourGuardD2Ev; Catch::ColourImpl::ColourGuard::~ColourGuard()
mov rdi, rbx
call __Unwind_Resume
|
void Catch::ConsoleReporter::lazyPrintRunInfo(Catch::ConsoleReporter *this)
{
long long v2; // rdi
double v3; // xmm0_8
std::ostream *v4; // rax
std::ostream *v5; // r14
long long v6; // r15
double v7; // xmm0_8
std::ostream *v8; // rax
std::ostream *v9; // r14
Catch *v10; // rdi
double v11; // xmm0_8
double v12; // xmm0_8
long long v13; // [rsp+0h] [rbp-28h] BYREF
unsigned int v14; // [rsp+8h] [rbp-20h]
char v15; // [rsp+Ch] [rbp-1Ch]
v2 = *((_QWORD *)this + 4);
LOBYTE(v13) = 10;
v3 = std::__ostream_insert<char,std::char_traits<char>>(v2, (const char *)&v13, 1LL);
v5 = v4;
v6 = 79LL;
do
{
std::ostream::put(v5, 126);
--v6;
}
while ( v6 );
LOBYTE(v13) = 10;
v7 = std::__ostream_insert<char,std::char_traits<char>>(v5, (const char *)&v13, 1LL, v3);
v9 = v8;
Catch::ColourImpl::ColourGuard::ColourGuard((long long)&v13, 23, *((_QWORD *)this + 5));
v15 = 1;
(*(void ( **)(long long, _QWORD, double))(*(_QWORD *)v13 + 16LL))(v13, v14, v7);
v10 = (Catch *)std::ostream::write(v9, *((const char **)this + 12), *((_QWORD *)this + 13));
v11 = std::__ostream_insert<char,std::char_traits<char>>(v10, " is a Catch2 v", 14LL);
Catch::libraryVersion(v10);
Catch::operator<<((long long)v10, Catch::libraryVersion(void)::version);
v12 = std::__ostream_insert<char,std::char_traits<char>>(v10, " host application.\n", 19LL, v11);
std::__ostream_insert<char,std::char_traits<char>>(v10, "Run with -? for options\n\n", 25LL, v12);
Catch::ColourImpl::ColourGuard::~ColourGuard((Catch::ColourImpl::ColourGuard *)&v13);
*((_BYTE *)this + 153) = 1;
}
|
lazyPrintRunInfo:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x10
MOV RBX,RDI
MOV RDI,qword ptr [RDI + 0x20]
MOV RSI,RSP
MOV byte ptr [RSI],0xa
MOV EDX,0x1
CALL 0x00117be0
MOV R14,RAX
MOV R15D,0x4f
LAB_0016a507:
MOV RDI,R14
MOV ESI,0x7e
CALL 0x00117630
DEC R15
JNZ 0x0016a507
MOV RSI,RSP
MOV byte ptr [RSI],0xa
MOV EDX,0x1
MOV RDI,R14
CALL 0x00117be0
MOV R14,RAX
MOV RDX,qword ptr [RBX + 0x28]
MOV R15,RSP
MOV RDI,R15
MOV ESI,0x17
CALL 0x0015bc9a
MOV byte ptr [R15 + 0xc],0x1
MOV RDI,qword ptr [R15]
MOV ESI,dword ptr [R15 + 0x8]
MOV RAX,qword ptr [RDI]
LAB_0016a552:
CALL qword ptr [RAX + 0x10]
MOV RSI,qword ptr [RBX + 0x60]
MOV RDX,qword ptr [RBX + 0x68]
MOV RDI,R14
CALL 0x00117580
MOV R14,RAX
LEA RSI,[0x1de2ea]
MOV EDX,0xe
MOV RDI,RAX
CALL 0x00117be0
CALL 0x00155032
LEA RSI,[0x234038]
MOV RDI,R14
CALL 0x00154f3f
LEA RSI,[0x1de2f9]
MOV EDX,0x13
MOV RDI,R14
CALL 0x00117be0
LEA RSI,[0x1de30d]
MOV EDX,0x19
MOV RDI,R14
CALL 0x00117be0
LAB_0016a5b8:
MOV RDI,RSP
CALL 0x0015bce6
MOV byte ptr [RBX + 0x99],0x1
ADD RSP,0x10
POP RBX
POP R14
POP R15
RET
|
/* Catch::ConsoleReporter::lazyPrintRunInfo() */
void __thiscall Catch::ConsoleReporter::lazyPrintRunInfo(ConsoleReporter *this)
{
ostream *poVar1;
long lVar2;
ColourGuard local_28;
int7 uStack_27;
int4 local_20;
int1 local_1c;
local_28 = (ColourGuard)0xa;
poVar1 = std::__ostream_insert<char,std::char_traits<char>>
(*(ostream **)(this + 0x20),(char *)&local_28,1);
lVar2 = 0x4f;
do {
std::ostream::put((char)poVar1);
lVar2 = lVar2 + -1;
} while (lVar2 != 0);
local_28 = (ColourGuard)0xa;
poVar1 = std::__ostream_insert<char,std::char_traits<char>>(poVar1,(char *)&local_28,1);
ColourImpl::ColourGuard::ColourGuard(&local_28,0x17,*(int8 *)(this + 0x28));
local_1c = 1;
/* try { // try from 0016a552 to 0016a5b7 has its CatchHandler @ 0016a5d1 */
(**(code **)(*(long *)CONCAT71(uStack_27,local_28) + 0x10))
((long *)CONCAT71(uStack_27,local_28),local_20);
poVar1 = (ostream *)std::ostream::write((char *)poVar1,*(long *)(this + 0x60));
std::__ostream_insert<char,std::char_traits<char>>(poVar1," is a Catch2 v",0xe);
libraryVersion();
operator<<(poVar1,(Version *)libraryVersion()::version);
std::__ostream_insert<char,std::char_traits<char>>(poVar1," host application.\n",0x13);
std::__ostream_insert<char,std::char_traits<char>>(poVar1,"Run with -? for options\n\n",0x19);
ColourImpl::ColourGuard::~ColourGuard(&local_28);
this[0x99] = (ConsoleReporter)0x1;
return;
}
|
|
19,964
|
my_string_metadata_get_mb
|
eloqsql/strings/ctype.c
|
static void
my_string_metadata_get_mb(MY_STRING_METADATA *metadata,
CHARSET_INFO *cs, const char *str, ulong length)
{
const char *strend= str + length;
for (my_string_metadata_init(metadata) ;
str < strend;
metadata->char_length++)
{
my_wc_t wc;
int mblen= my_ci_mb_wc(cs, &wc, (const uchar *) str, (const uchar *) strend);
if (mblen > 0) /* Assigned character */
{
if (wc > 0x7F)
metadata->repertoire|= MY_REPERTOIRE_EXTENDED;
str+= mblen;
}
else if (mblen == MY_CS_ILSEQ) /* Bad byte sequence */
{
metadata->repertoire|= MY_REPERTOIRE_EXTENDED;
str++;
}
else if (mblen > MY_CS_TOOSMALL) /* Unassigned character */
{
metadata->repertoire|= MY_REPERTOIRE_EXTENDED;
str+= (-mblen);
}
else /* Incomplete character, premature end-of-line */
{
metadata->repertoire|= MY_REPERTOIRE_EXTENDED; /* Just in case */
break;
}
}
}
|
O0
|
c
|
my_string_metadata_get_mb:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x18(%rbp), %rax
addq -0x20(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rdi
callq 0x74ba0
movq -0x18(%rbp), %rax
cmpq -0x28(%rbp), %rax
jae 0x7372d
movq -0x10(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x28(%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rdx
movq -0x28(%rbp), %rcx
leaq -0x30(%rbp), %rsi
callq *%rax
movl %eax, -0x34(%rbp)
cmpl $0x0, -0x34(%rbp)
jle 0x736bc
cmpq $0x7f, -0x30(%rbp)
jbe 0x736a9
movq -0x8(%rbp), %rax
movl 0x8(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x8(%rax)
movl -0x34(%rbp), %ecx
movq -0x18(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
jmp 0x73718
cmpl $0x0, -0x34(%rbp)
jne 0x736dd
movq -0x8(%rbp), %rax
movl 0x8(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x8(%rax)
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x73716
cmpl $-0x65, -0x34(%rbp)
jle 0x73705
movq -0x8(%rbp), %rax
movl 0x8(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x8(%rax)
xorl %ecx, %ecx
subl -0x34(%rbp), %ecx
movq -0x18(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
jmp 0x73714
movq -0x8(%rbp), %rax
movl 0x8(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x8(%rax)
jmp 0x7372d
jmp 0x73716
jmp 0x73718
jmp 0x7371a
movq -0x8(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movq %rcx, (%rax)
jmp 0x7365d
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
my_string_metadata_get_mb:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rax, [rbp+var_18]
add rax, [rbp+var_20]
mov [rbp+var_28], rax
mov rdi, [rbp+var_8]
call my_string_metadata_init
loc_7365D:
mov rax, [rbp+var_18]
cmp rax, [rbp+var_28]
jnb loc_7372D
mov rax, [rbp+var_10]
mov rax, [rax+0B8h]
mov rax, [rax+28h]
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov rcx, [rbp+var_28]
lea rsi, [rbp+var_30]
call rax
mov [rbp+var_34], eax
cmp [rbp+var_34], 0
jle short loc_736BC
cmp [rbp+var_30], 7Fh
jbe short loc_736A9
mov rax, [rbp+var_8]
mov ecx, [rax+8]
or ecx, 2
mov [rax+8], ecx
loc_736A9:
mov ecx, [rbp+var_34]
mov rax, [rbp+var_18]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_18], rax
jmp short loc_73718
loc_736BC:
cmp [rbp+var_34], 0
jnz short loc_736DD
mov rax, [rbp+var_8]
mov ecx, [rax+8]
or ecx, 2
mov [rax+8], ecx
mov rax, [rbp+var_18]
add rax, 1
mov [rbp+var_18], rax
jmp short loc_73716
loc_736DD:
cmp [rbp+var_34], 0FFFFFF9Bh
jle short loc_73705
mov rax, [rbp+var_8]
mov ecx, [rax+8]
or ecx, 2
mov [rax+8], ecx
xor ecx, ecx
sub ecx, [rbp+var_34]
mov rax, [rbp+var_18]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_18], rax
jmp short loc_73714
loc_73705:
mov rax, [rbp+var_8]
mov ecx, [rax+8]
or ecx, 2
mov [rax+8], ecx
jmp short loc_7372D
loc_73714:
jmp short $+2
loc_73716:
jmp short $+2
loc_73718:
jmp short $+2
loc_7371A:
mov rax, [rbp+var_8]
mov rcx, [rax]
add rcx, 1
mov [rax], rcx
jmp loc_7365D
loc_7372D:
add rsp, 40h
pop rbp
retn
|
unsigned long long my_string_metadata_get_mb(unsigned long long a1, long long a2, unsigned long long a3, long long a4)
{
unsigned long long result; // rax
int v5; // [rsp+Ch] [rbp-34h]
unsigned long long v6; // [rsp+10h] [rbp-30h] BYREF
unsigned long long v7; // [rsp+18h] [rbp-28h]
long long v8; // [rsp+20h] [rbp-20h]
unsigned long long v9; // [rsp+28h] [rbp-18h]
long long v10; // [rsp+30h] [rbp-10h]
unsigned long long v11; // [rsp+38h] [rbp-8h]
v11 = a1;
v10 = a2;
v9 = a3;
v8 = a4;
v7 = a4 + a3;
my_string_metadata_init(a1);
while ( 1 )
{
result = v9;
if ( v9 >= v7 )
break;
v5 = (*(long long ( **)(long long, unsigned long long *, unsigned long long, unsigned long long))(*(_QWORD *)(v10 + 184) + 40LL))(
v10,
&v6,
v9,
v7);
if ( v5 <= 0 )
{
if ( v5 )
{
if ( v5 <= -101 )
{
result = v11;
*(_DWORD *)(v11 + 8) |= 2u;
return result;
}
*(_DWORD *)(v11 + 8) |= 2u;
v9 += -v5;
}
else
{
*(_DWORD *)(v11 + 8) |= 2u;
++v9;
}
}
else
{
if ( v6 > 0x7F )
*(_DWORD *)(v11 + 8) |= 2u;
v9 += v5;
}
++*(_QWORD *)v11;
}
return result;
}
|
my_string_metadata_get_mb:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00174ba0
LAB_0017365d:
MOV RAX,qword ptr [RBP + -0x18]
CMP RAX,qword ptr [RBP + -0x28]
JNC 0x0017372d
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0x28]
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x28]
LEA RSI,[RBP + -0x30]
CALL RAX
MOV dword ptr [RBP + -0x34],EAX
CMP dword ptr [RBP + -0x34],0x0
JLE 0x001736bc
CMP qword ptr [RBP + -0x30],0x7f
JBE 0x001736a9
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x8]
OR ECX,0x2
MOV dword ptr [RAX + 0x8],ECX
LAB_001736a9:
MOV ECX,dword ptr [RBP + -0x34]
MOV RAX,qword ptr [RBP + -0x18]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
JMP 0x00173718
LAB_001736bc:
CMP dword ptr [RBP + -0x34],0x0
JNZ 0x001736dd
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x8]
OR ECX,0x2
MOV dword ptr [RAX + 0x8],ECX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x1
MOV qword ptr [RBP + -0x18],RAX
JMP 0x00173716
LAB_001736dd:
CMP dword ptr [RBP + -0x34],-0x65
JLE 0x00173705
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x8]
OR ECX,0x2
MOV dword ptr [RAX + 0x8],ECX
XOR ECX,ECX
SUB ECX,dword ptr [RBP + -0x34]
MOV RAX,qword ptr [RBP + -0x18]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
JMP 0x00173714
LAB_00173705:
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x8]
OR ECX,0x2
MOV dword ptr [RAX + 0x8],ECX
JMP 0x0017372d
LAB_00173714:
JMP 0x00173716
LAB_00173716:
JMP 0x00173718
LAB_00173718:
JMP 0x0017371a
LAB_0017371a:
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX]
ADD RCX,0x1
MOV qword ptr [RAX],RCX
JMP 0x0017365d
LAB_0017372d:
ADD RSP,0x40
POP RBP
RET
|
void my_string_metadata_get_mb(long *param_1,long param_2,ulong param_3,long param_4)
{
int iVar1;
ulong local_38;
ulong local_30;
long local_28;
ulong local_20;
long local_18;
long *local_10;
local_30 = param_3 + param_4;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
my_string_metadata_init(param_1);
do {
if (local_30 <= local_20) {
return;
}
iVar1 = (**(code **)(*(long *)(local_18 + 0xb8) + 0x28))(local_18,&local_38,local_20,local_30);
if (iVar1 < 1) {
if (iVar1 == 0) {
*(uint *)(local_10 + 1) = *(uint *)(local_10 + 1) | 2;
local_20 = local_20 + 1;
}
else {
if (iVar1 < -100) {
*(uint *)(local_10 + 1) = *(uint *)(local_10 + 1) | 2;
return;
}
*(uint *)(local_10 + 1) = *(uint *)(local_10 + 1) | 2;
local_20 = local_20 + (long)-iVar1;
}
}
else {
if (0x7f < local_38) {
*(uint *)(local_10 + 1) = *(uint *)(local_10 + 1) | 2;
}
local_20 = local_20 + (long)iVar1;
}
*local_10 = *local_10 + 1;
} while( true );
}
|
|
19,965
|
build_arg_list
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue *build_arg_list(JSContext *ctx, uint32_t *plen,
JSValue array_arg)
{
uint32_t len, i;
JSValue *tab, ret;
JSObject *p;
if (JS_VALUE_GET_TAG(array_arg) != JS_TAG_OBJECT) {
JS_ThrowTypeError(ctx, "not a object");
return NULL;
}
if (js_get_length32(ctx, &len, array_arg))
return NULL;
if (len > JS_MAX_LOCAL_VARS) {
// XXX: check for stack overflow?
JS_ThrowRangeError(ctx, "too many arguments in function call (only %d allowed)",
JS_MAX_LOCAL_VARS);
return NULL;
}
/* avoid allocating 0 bytes */
tab = js_mallocz(ctx, sizeof(tab[0]) * max_uint32(1, len));
if (!tab)
return NULL;
p = JS_VALUE_GET_OBJ(array_arg);
if ((p->class_id == JS_CLASS_ARRAY || p->class_id == JS_CLASS_ARGUMENTS) &&
p->fast_array &&
len == p->u.array.count) {
for(i = 0; i < len; i++) {
tab[i] = js_dup(p->u.array.u.values[i]);
}
} else {
for(i = 0; i < len; i++) {
ret = JS_GetPropertyUint32(ctx, array_arg, i);
if (JS_IsException(ret)) {
free_arg_list(ctx, tab, i);
return NULL;
}
tab[i] = ret;
}
}
*plen = len;
return tab;
}
|
O1
|
c
|
build_arg_list:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %r12
movq %rdi, %r15
movq %rdx, 0x10(%rsp)
cmpl $-0x1, %r12d
jne 0x3f595
movq %rsi, %r14
leaq 0xc(%rsp), %rsi
movq %r15, %rdi
movq %r12, %rcx
callq 0x4160f
testl %eax, %eax
je 0x3f5aa
xorl %ebx, %ebx
jmp 0x3f5d0
leaq 0x5fe87(%rip), %rsi # 0x9f423
xorl %ebx, %ebx
movq %r15, %rdi
xorl %eax, %eax
callq 0x22567
jmp 0x3f5d0
movl 0xc(%rsp), %r13d
cmpq $0x10000, %r13 # imm = 0x10000
jb 0x3f5e2
leaq 0x5fe71(%rip), %rsi # 0x9f430
xorl %ebx, %ebx
movq %r15, %rdi
movl $0xffff, %edx # imm = 0xFFFF
xorl %eax, %eax
callq 0x20add
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpl $0x1, %r13d
movl %r13d, %esi
adcl $0x0, %esi
shll $0x4, %esi
movq %r15, %rdi
callq 0xee06
testq %rax, %rax
je 0x3f591
movq %rax, %rbx
movq 0x10(%rsp), %rax
movzwl 0x6(%rax), %ecx
cmpl $0x8, %ecx
movq %r13, (%rsp)
je 0x3f616
cmpl $0x2, %ecx
jne 0x3f668
testb $0x8, 0x5(%rax)
je 0x3f668
cmpl 0x40(%rax), %r13d
jne 0x3f668
testl %r13d, %r13d
je 0x3f6ae
movq (%rsp), %rcx
shlq $0x4, %rcx
xorl %edx, %edx
movq 0x38(%rax), %rdi
movq (%rdi,%rdx), %rsi
movq 0x8(%rdi,%rdx), %rdi
movq %rsi, 0x20(%rsp)
cmpl $-0x9, %edi
jb 0x3f654
movq 0x20(%rsp), %r8
incl (%r8)
movq %rsi, (%rbx,%rdx)
movq %rdi, 0x8(%rbx,%rdx)
addq $0x10, %rdx
cmpq %rdx, %rcx
jne 0x3f635
jmp 0x3f6ae
testl %r13d, %r13d
je 0x3f6ae
movq 0x10(%rsp), %rax
movq %rax, 0x18(%rsp)
movq %rbx, %rbp
addq $0x8, %rbp
xorl %r13d, %r13d
movq %r15, %rdi
movq 0x18(%rsp), %rsi
movq %r12, %rdx
movq %r13, %rcx
callq 0x241b4
cmpl $0x6, %edx
je 0x3f6ba
movq %rax, -0x8(%rbp)
movq %rdx, (%rbp)
incq %r13
addq $0x10, %rbp
cmpq %r13, (%rsp)
jne 0x3f681
movq (%rsp), %rax
movl %eax, (%r14)
jmp 0x3f5d0
movq %r15, %rdi
movq %rbx, %rsi
movl %r13d, %edx
callq 0x3f6cd
jmp 0x3f591
|
build_arg_list:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r12, rcx
mov r15, rdi
mov [rsp+58h+var_48], rdx
cmp r12d, 0FFFFFFFFh
jnz short loc_3F595
mov r14, rsi
lea rsi, [rsp+58h+var_4C]
mov rdi, r15
mov rcx, r12
call js_get_length32
test eax, eax
jz short loc_3F5AA
loc_3F591:
xor ebx, ebx
jmp short loc_3F5D0
loc_3F595:
lea rsi, aNotAObject; "not a object"
xor ebx, ebx
mov rdi, r15
xor eax, eax
call JS_ThrowTypeError
jmp short loc_3F5D0
loc_3F5AA:
mov r13d, [rsp+58h+var_4C]
cmp r13, 10000h
jb short loc_3F5E2
lea rsi, aTooManyArgumen; "too many arguments in function call (on"...
xor ebx, ebx
mov rdi, r15
mov edx, 0FFFFh
xor eax, eax
call JS_ThrowRangeError
loc_3F5D0:
mov rax, rbx
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3F5E2:
cmp r13d, 1
mov esi, r13d
adc esi, 0
shl esi, 4
mov rdi, r15
call js_mallocz
test rax, rax
jz short loc_3F591
mov rbx, rax
mov rax, [rsp+58h+var_48]
movzx ecx, word ptr [rax+6]
cmp ecx, 8
mov [rsp+58h+var_58], r13
jz short loc_3F616
cmp ecx, 2
jnz short loc_3F668
loc_3F616:
test byte ptr [rax+5], 8
jz short loc_3F668
cmp r13d, [rax+40h]
jnz short loc_3F668
test r13d, r13d
jz loc_3F6AE
mov rcx, [rsp+58h+var_58]
shl rcx, 4
xor edx, edx
loc_3F635:
mov rdi, [rax+38h]
mov rsi, [rdi+rdx]
mov rdi, [rdi+rdx+8]
mov [rsp+58h+var_38], rsi
cmp edi, 0FFFFFFF7h
jb short loc_3F654
mov r8, [rsp+58h+var_38]
inc dword ptr [r8]
loc_3F654:
mov [rbx+rdx], rsi
mov [rbx+rdx+8], rdi
add rdx, 10h
cmp rcx, rdx
jnz short loc_3F635
jmp short loc_3F6AE
loc_3F668:
test r13d, r13d
jz short loc_3F6AE
mov rax, [rsp+58h+var_48]
mov [rsp+58h+var_40], rax
mov rbp, rbx
add rbp, 8
xor r13d, r13d
loc_3F681:
mov rdi, r15
mov rsi, [rsp+58h+var_40]
mov rdx, r12
mov rcx, r13
call JS_GetPropertyInt64
cmp edx, 6
jz short loc_3F6BA
mov [rbp-8], rax
mov [rbp+0], rdx
inc r13
add rbp, 10h
cmp [rsp+58h+var_58], r13
jnz short loc_3F681
loc_3F6AE:
mov rax, [rsp+58h+var_58]
mov [r14], eax
jmp loc_3F5D0
loc_3F6BA:
mov rdi, r15
mov rsi, rbx
mov edx, r13d
call free_arg_list
jmp loc_3F591
|
long long build_arg_list(
long long a1,
_DWORD *a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14)
{
long long v16; // rcx
long long v17; // r8
long long v18; // r9
__m128 v19; // xmm4
__m128 v20; // xmm5
long long v21; // rbx
long long v22; // r13
long long v24; // rax
long long v25; // rax
int v26; // ecx
long long v27; // rdx
long long v28; // rdi
_DWORD *v29; // rsi
long long v30; // rdi
_QWORD *v31; // rbp
unsigned long long v32; // r13
unsigned long long PropertyInt64; // rax
long long v34; // rdx
char v35; // [rsp+0h] [rbp-58h]
long long v36; // [rsp+0h] [rbp-58h]
unsigned int v37; // [rsp+Ch] [rbp-4Ch] BYREF
long long v38; // [rsp+10h] [rbp-48h]
long long v39; // [rsp+18h] [rbp-40h]
_DWORD *v40; // [rsp+20h] [rbp-38h]
v38 = a3;
if ( (_DWORD)a4 == -1 )
{
if ( !(unsigned int)js_get_length32(a1, &v37) )
{
v22 = v37;
if ( v37 >= 0x10000uLL )
{
v21 = 0LL;
JS_ThrowRangeError(
a1,
(long long)"too many arguments in function call (only %d allowed)",
0xFFFFLL,
v16,
v17,
v18,
a7,
a8,
a9,
a10,
v19,
v20,
a13,
a14,
v35);
return v21;
}
v24 = js_mallocz(a1, 16 * ((v37 == 0) + v37));
if ( v24 )
{
v21 = v24;
v25 = v38;
v26 = *(unsigned __int16 *)(v38 + 6);
v36 = v22;
if ( (v26 == 8 || v26 == 2) && (*(_BYTE *)(v38 + 5) & 8) != 0 && (_DWORD)v22 == *(_DWORD *)(v38 + 64) )
{
if ( (_DWORD)v22 )
{
v27 = 0LL;
do
{
v28 = *(_QWORD *)(v25 + 56);
v29 = *(_DWORD **)(v28 + v27);
v30 = *(_QWORD *)(v28 + v27 + 8);
v40 = v29;
if ( (unsigned int)v30 >= 0xFFFFFFF7 )
++*v40;
*(_QWORD *)(v21 + v27) = v29;
*(_QWORD *)(v21 + v27 + 8) = v30;
v27 += 16LL;
}
while ( 16 * v22 != v27 );
}
goto LABEL_23;
}
if ( !(_DWORD)v22 )
{
LABEL_23:
*a2 = v36;
return v21;
}
v39 = v38;
v31 = (_QWORD *)(v21 + 8);
v32 = 0LL;
while ( 1 )
{
PropertyInt64 = JS_GetPropertyInt64(a1, v39, a4, v32);
if ( (_DWORD)v34 == 6 )
break;
*(v31 - 1) = PropertyInt64;
*v31 = v34;
++v32;
v31 += 2;
if ( v36 == v32 )
goto LABEL_23;
}
free_arg_list(a1, v21, (unsigned int)v32);
}
}
return 0LL;
}
else
{
v21 = 0LL;
JS_ThrowTypeError(a1, (long long)"not a object", a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v35);
}
return v21;
}
|
build_arg_list:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R12,RCX
MOV R15,RDI
MOV qword ptr [RSP + 0x10],RDX
CMP R12D,-0x1
JNZ 0x0013f595
MOV R14,RSI
LEA RSI,[RSP + 0xc]
MOV RDI,R15
MOV RCX,R12
CALL 0x0014160f
TEST EAX,EAX
JZ 0x0013f5aa
LAB_0013f591:
XOR EBX,EBX
JMP 0x0013f5d0
LAB_0013f595:
LEA RSI,[0x19f423]
XOR EBX,EBX
MOV RDI,R15
XOR EAX,EAX
CALL 0x00122567
JMP 0x0013f5d0
LAB_0013f5aa:
MOV R13D,dword ptr [RSP + 0xc]
CMP R13,0x10000
JC 0x0013f5e2
LEA RSI,[0x19f430]
XOR EBX,EBX
MOV RDI,R15
MOV EDX,0xffff
XOR EAX,EAX
CALL 0x00120add
LAB_0013f5d0:
MOV RAX,RBX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0013f5e2:
CMP R13D,0x1
MOV ESI,R13D
ADC ESI,0x0
SHL ESI,0x4
MOV RDI,R15
CALL 0x0010ee06
TEST RAX,RAX
JZ 0x0013f591
MOV RBX,RAX
MOV RAX,qword ptr [RSP + 0x10]
MOVZX ECX,word ptr [RAX + 0x6]
CMP ECX,0x8
MOV qword ptr [RSP],R13
JZ 0x0013f616
CMP ECX,0x2
JNZ 0x0013f668
LAB_0013f616:
TEST byte ptr [RAX + 0x5],0x8
JZ 0x0013f668
CMP R13D,dword ptr [RAX + 0x40]
JNZ 0x0013f668
TEST R13D,R13D
JZ 0x0013f6ae
MOV RCX,qword ptr [RSP]
SHL RCX,0x4
XOR EDX,EDX
LAB_0013f635:
MOV RDI,qword ptr [RAX + 0x38]
MOV RSI,qword ptr [RDI + RDX*0x1]
MOV RDI,qword ptr [RDI + RDX*0x1 + 0x8]
MOV qword ptr [RSP + 0x20],RSI
CMP EDI,-0x9
JC 0x0013f654
MOV R8,qword ptr [RSP + 0x20]
INC dword ptr [R8]
LAB_0013f654:
MOV qword ptr [RBX + RDX*0x1],RSI
MOV qword ptr [RBX + RDX*0x1 + 0x8],RDI
ADD RDX,0x10
CMP RCX,RDX
JNZ 0x0013f635
JMP 0x0013f6ae
LAB_0013f668:
TEST R13D,R13D
JZ 0x0013f6ae
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x18],RAX
MOV RBP,RBX
ADD RBP,0x8
XOR R13D,R13D
LAB_0013f681:
MOV RDI,R15
MOV RSI,qword ptr [RSP + 0x18]
MOV RDX,R12
MOV RCX,R13
CALL 0x001241b4
CMP EDX,0x6
JZ 0x0013f6ba
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP],RDX
INC R13
ADD RBP,0x10
CMP qword ptr [RSP],R13
JNZ 0x0013f681
LAB_0013f6ae:
MOV RAX,qword ptr [RSP]
MOV dword ptr [R14],EAX
JMP 0x0013f5d0
LAB_0013f6ba:
MOV RDI,R15
MOV RSI,RBX
MOV EDX,R13D
CALL 0x0013f6cd
JMP 0x0013f591
|
long build_arg_list(int8 param_1,uint *param_2,long param_3,int8 param_4)
{
int *piVar1;
int8 uVar2;
int iVar3;
long lVar4;
long lVar5;
int8 *puVar6;
ulong uVar7;
ulong uVar8;
int1 auVar9 [16];
uint local_4c;
long local_48;
long local_40;
local_48 = param_3;
if ((int)param_4 != -1) {
JS_ThrowTypeError(param_1,"not a object");
return 0;
}
iVar3 = js_get_length32(param_1,&local_4c,param_3,param_4);
if (iVar3 == 0) {
uVar7 = (ulong)local_4c;
if (0xffff < uVar7) {
JS_ThrowRangeError(param_1,"too many arguments in function call (only %d allowed)",0xffff);
return 0;
}
lVar4 = js_mallocz(param_1,(local_4c + (local_4c == 0)) * 0x10);
if (lVar4 != 0) {
if ((((*(short *)(local_48 + 6) == 8) || (*(short *)(local_48 + 6) == 2)) &&
((*(byte *)(local_48 + 5) & 8) != 0)) && (local_4c == *(uint *)(local_48 + 0x40))) {
if (local_4c != 0) {
lVar5 = 0;
do {
piVar1 = *(int **)(*(long *)(local_48 + 0x38) + lVar5);
uVar2 = *(int8 *)(*(long *)(local_48 + 0x38) + 8 + lVar5);
if (0xfffffff6 < (uint)uVar2) {
*piVar1 = *piVar1 + 1;
}
*(int **)(lVar4 + lVar5) = piVar1;
*(int8 *)(lVar4 + 8 + lVar5) = uVar2;
lVar5 = lVar5 + 0x10;
} while (uVar7 << 4 != lVar5);
}
}
else if (local_4c != 0) {
local_40 = local_48;
puVar6 = (int8 *)(lVar4 + 8);
uVar8 = 0;
do {
auVar9 = JS_GetPropertyInt64(param_1,local_40,param_4,uVar8);
if (auVar9._8_4_ == 6) {
free_arg_list(param_1,lVar4,uVar8 & 0xffffffff);
return 0;
}
puVar6[-1] = auVar9._0_8_;
*puVar6 = auVar9._8_8_;
uVar8 = uVar8 + 1;
puVar6 = puVar6 + 2;
} while (uVar7 != uVar8);
}
*param_2 = local_4c;
return lVar4;
}
}
return 0;
}
|
|
19,966
|
plutovg_blend_color
|
dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-blend.c
|
static void plutovg_blend_color(plutovg_canvas_t* canvas, const plutovg_color_t* color, const plutovg_span_buffer_t* span_buffer)
{
plutovg_state_t* state = canvas->state;
uint32_t solid = premultiply_color_with_opacity(color, state->opacity);
uint32_t alpha = plutovg_alpha(solid);
if(alpha == 255 && state->op == PLUTOVG_OPERATOR_SRC_OVER) {
blend_solid(canvas->surface, PLUTOVG_OPERATOR_SRC, solid, span_buffer);
} else {
blend_solid(canvas->surface, state->op, solid, span_buffer);
}
}
|
O1
|
c
|
plutovg_blend_color:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, 0x10(%rsp)
movq %rsi, %r12
movq %rdi, %r14
movq 0x18(%rdi), %rbx
movss 0x8c(%rbx), %xmm0
mulss 0xc(%rsi), %xmm0
mulss 0x2844(%rip), %xmm0 # 0x43148
callq 0xa420
movq %rax, %r13
movl %r13d, %eax
cvtsi2ss %rax, %xmm1
movss %xmm1, 0xc(%rsp)
movss (%r12), %xmm0
mulss %xmm1, %xmm0
callq 0xa420
movq %rax, %rbp
movss 0x4(%r12), %xmm0
mulss 0xc(%rsp), %xmm0
callq 0xa420
movq %rax, %r15
movss 0xc(%rsp), %xmm0
mulss 0x8(%r12), %xmm0
callq 0xa420
shll $0x18, %r13d
shll $0x10, %ebp
orl %r13d, %ebp
shll $0x8, %r15d
orl %eax, %r15d
orl %ebp, %r15d
cmpl $0xff000000, %r15d # imm = 0xFF000000
jb 0x40984
cmpl $0x3, 0x84(%rbx)
jne 0x40984
movq 0x8(%r14), %rdi
movl $0x1, %esi
jmp 0x4098e
movq 0x8(%r14), %rdi
movl 0x84(%rbx), %esi
movl %r15d, %edx
movq 0x10(%rsp), %rcx
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x409a6
|
plutovg_blend_color:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov [rsp+48h+var_38], rdx
mov r12, rsi
mov r14, rdi
mov rbx, [rdi+18h]
movss xmm0, dword ptr [rbx+8Ch]
mulss xmm0, dword ptr [rsi+0Ch]
mulss xmm0, cs:dword_43148
call _lroundf
mov r13, rax
mov eax, r13d
cvtsi2ss xmm1, rax
movss [rsp+48h+var_3C], xmm1
movss xmm0, dword ptr [r12]
mulss xmm0, xmm1
call _lroundf
mov rbp, rax
movss xmm0, dword ptr [r12+4]
mulss xmm0, [rsp+48h+var_3C]
call _lroundf
mov r15, rax
movss xmm0, [rsp+48h+var_3C]
mulss xmm0, dword ptr [r12+8]
call _lroundf
shl r13d, 18h
shl ebp, 10h
or ebp, r13d
shl r15d, 8
or r15d, eax
or r15d, ebp
cmp r15d, 0FF000000h
jb short loc_40984
cmp dword ptr [rbx+84h], 3
jnz short loc_40984
mov rdi, [r14+8]
mov esi, 1
jmp short loc_4098E
loc_40984:
mov rdi, [r14+8]
mov esi, [rbx+84h]
loc_4098E:
mov edx, r15d
mov rcx, [rsp+48h+var_38]
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp short $+2
|
long long plutovg_blend_color(long long a1, float *a2, long long a3)
{
long long v3; // rbx
int v4; // r13d
int v5; // ebp
int v6; // r15d
unsigned int v7; // r15d
long long v8; // rdi
long long v9; // rsi
v3 = *(_QWORD *)(a1 + 24);
v4 = lroundf((float)(*(float *)(v3 + 140) * a2[3]) * 255.0);
v5 = lroundf(*a2 * (float)v4);
v6 = lroundf(a2[1] * (float)v4);
v7 = (v4 << 24) | (v5 << 16) | lroundf((float)v4 * a2[2]) | (v6 << 8);
if ( v7 >= 0xFF000000 && *(_DWORD *)(v3 + 132) == 3 )
{
v8 = *(_QWORD *)(a1 + 8);
v9 = 1LL;
}
else
{
v8 = *(_QWORD *)(a1 + 8);
v9 = *(unsigned int *)(v3 + 132);
}
return blend_solid(v8, v9, v7, a3);
}
|
plutovg_blend_color:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV qword ptr [RSP + 0x10],RDX
MOV R12,RSI
MOV R14,RDI
MOV RBX,qword ptr [RDI + 0x18]
MOVSS XMM0,dword ptr [RBX + 0x8c]
MULSS XMM0,dword ptr [RSI + 0xc]
MULSS XMM0,dword ptr [0x00143148]
CALL 0x0010a420
MOV R13,RAX
MOV EAX,R13D
CVTSI2SS XMM1,RAX
MOVSS dword ptr [RSP + 0xc],XMM1
MOVSS XMM0,dword ptr [R12]
MULSS XMM0,XMM1
CALL 0x0010a420
MOV RBP,RAX
MOVSS XMM0,dword ptr [R12 + 0x4]
MULSS XMM0,dword ptr [RSP + 0xc]
CALL 0x0010a420
MOV R15,RAX
MOVSS XMM0,dword ptr [RSP + 0xc]
MULSS XMM0,dword ptr [R12 + 0x8]
CALL 0x0010a420
SHL R13D,0x18
SHL EBP,0x10
OR EBP,R13D
SHL R15D,0x8
OR R15D,EAX
OR R15D,EBP
CMP R15D,0xff000000
JC 0x00140984
CMP dword ptr [RBX + 0x84],0x3
JNZ 0x00140984
MOV RDI,qword ptr [R14 + 0x8]
MOV ESI,0x1
JMP 0x0014098e
LAB_00140984:
MOV RDI,qword ptr [R14 + 0x8]
MOV ESI,dword ptr [RBX + 0x84]
LAB_0014098e:
MOV EDX,R15D
MOV RCX,qword ptr [RSP + 0x10]
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x001409a6
|
void plutovg_blend_color(long param_1,float *param_2,int8 param_3)
{
long lVar1;
ulong uVar2;
long lVar3;
long lVar4;
long lVar5;
int4 uVar6;
int8 uVar7;
uint uVar8;
float fVar9;
lVar1 = *(long *)(param_1 + 0x18);
uVar2 = lroundf(*(float *)(lVar1 + 0x8c) * param_2[3] * DAT_00143148);
fVar9 = (float)(uVar2 & 0xffffffff);
lVar3 = lroundf(*param_2 * fVar9);
lVar4 = lroundf(param_2[1] * fVar9);
lVar5 = lroundf(fVar9 * param_2[2]);
uVar8 = (int)lVar4 << 8 | (uint)lVar5 | (int)lVar3 << 0x10 | (int)uVar2 << 0x18;
if ((uVar8 < 0xff000000) || (*(int *)(lVar1 + 0x84) != 3)) {
uVar7 = *(int8 *)(param_1 + 8);
uVar6 = *(int4 *)(lVar1 + 0x84);
}
else {
uVar7 = *(int8 *)(param_1 + 8);
uVar6 = 1;
}
blend_solid(uVar7,uVar6,uVar8,param_3);
return;
}
|
|
19,967
|
intx::operator>>(intx::uint<256u> const&, unsigned long)
|
corpus-core[P]colibri-stateless/build_O2/_deps/intx-src/include/intx/intx.hpp
|
inline constexpr uint256 operator>>(const uint256& x, uint64_t shift) noexcept
{
if (INTX_UNLIKELY(shift >= uint256::num_bits))
return 0;
constexpr auto num_bits = uint256::num_bits;
constexpr auto half_bits = num_bits / 2;
const auto xhi = uint128{x[2], x[3]};
if (shift < half_bits)
{
const auto hi = xhi >> shift;
const auto xlo = uint128{x[0], x[1]};
// Find the part moved from hi to lo.
// The shift left here can be invalid:
// for shift == 0 => lshift == half_bits.
// Split it into 2 valid shifts by (lshift - 1) and 1.
const auto lshift = half_bits - shift;
const auto hi_overflow = (xhi << (lshift - 1)) << 1;
const auto lo = (xlo >> shift) | hi_overflow;
return {lo[0], lo[1], hi[0], hi[1]};
}
const auto lo = xhi >> (shift - half_bits);
return {lo[0], lo[1], 0, 0};
}
|
O2
|
cpp
|
intx::operator>>(intx::uint<256u> const&, unsigned long):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
cmpq $0x100, %rdx # imm = 0x100
jae 0x3acc7
movq %rdx, %r14
movq %rsi, %r15
movq 0x10(%rsi), %rbp
movq 0x18(%rsi), %r13
cmpq $0x7f, %rdx
ja 0x3ac95
movq %rbp, %rdi
movq %r13, %rsi
movq %r14, %rdx
callq 0x39959
movq %rax, 0x10(%rsp)
movq %rdx, 0x8(%rsp)
movq (%r15), %r12
movq 0x8(%r15), %r15
pushq $0x7f
popq %rdx
subq %r14, %rdx
movq %rbp, %rdi
movq %r13, %rsi
callq 0x39d59
movq %rax, %r13
movq %rdx, %rbp
shldq $0x1, %rax, %rbp
addq %rax, %r13
movq %r12, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x39959
orq %r13, %rax
orq %rbp, %rdx
movq %rax, (%rbx)
movq %rdx, 0x8(%rbx)
movq 0x10(%rsp), %rax
movq %rax, 0x10(%rbx)
movq 0x8(%rsp), %rax
movq %rax, 0x18(%rbx)
jmp 0x3acb5
addq $-0x80, %r14
movq %rbp, %rdi
movq %r13, %rsi
movq %r14, %rdx
callq 0x39959
movq %rax, (%rbx)
movq %rdx, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movups %xmm0, (%rbx)
jmp 0x3acb5
|
_ZN4intxrsERKNS_4uintILj256EEEm:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov rbx, rdi
cmp rdx, 100h
jnb loc_3ACC7
mov r14, rdx
mov r15, rsi
mov rbp, [rsi+10h]
mov r13, [rsi+18h]
cmp rdx, 7Fh
ja short loc_3AC95
mov rdi, rbp
mov rsi, r13
mov rdx, r14
call _ZN4intxrsENS_4uintILj128EEEm; intx::operator>>(intx::uint<128u>,ulong)
mov [rsp+48h+var_38], rax
mov [rsp+48h+var_40], rdx
mov r12, [r15]
mov r15, [r15+8]
push 7Fh
pop rdx
sub rdx, r14
mov rdi, rbp
mov rsi, r13
call _ZN4intxlsENS_4uintILj128EEEm; intx::operator<<(intx::uint<128u>,ulong)
mov r13, rax
mov rbp, rdx
shld rbp, rax, 1
add r13, rax
mov rdi, r12
mov rsi, r15
mov rdx, r14
call _ZN4intxrsENS_4uintILj128EEEm; intx::operator>>(intx::uint<128u>,ulong)
or rax, r13
or rdx, rbp
mov [rbx], rax
mov [rbx+8], rdx
mov rax, [rsp+48h+var_38]
mov [rbx+10h], rax
mov rax, [rsp+48h+var_40]
mov [rbx+18h], rax
jmp short loc_3ACB5
loc_3AC95:
add r14, 0FFFFFFFFFFFFFF80h
mov rdi, rbp
mov rsi, r13
mov rdx, r14
call _ZN4intxrsENS_4uintILj128EEEm; intx::operator>>(intx::uint<128u>,ulong)
mov [rbx], rax
mov [rbx+8], rdx
xorps xmm0, xmm0
movups xmmword ptr [rbx+10h], xmm0
loc_3ACB5:
mov rax, rbx
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3ACC7:
xorps xmm0, xmm0
movups xmmword ptr [rbx+10h], xmm0
movups xmmword ptr [rbx], xmm0
jmp short loc_3ACB5
|
long long intx::operator>>(long long a1, unsigned long long *a2, unsigned long long a3)
{
long long v4; // rbp
long long v5; // r13
long long v6; // rdx
unsigned long long v7; // r12
unsigned long long v8; // r15
__int128 v9; // rax
__int128 v10; // rt0
long long v11; // rdx
long long v12; // rdx
long long v14; // [rsp+8h] [rbp-40h]
long long v15; // [rsp+10h] [rbp-38h]
if ( a3 >= 0x100 )
{
*(_OWORD *)(a1 + 16) = 0LL;
*(_OWORD *)a1 = 0LL;
}
else
{
v4 = a2[2];
v5 = a2[3];
if ( a3 > 0x7F )
{
*(_QWORD *)a1 = intx::operator>>(a2[2], a2[3], a3 - 128);
*(_QWORD *)(a1 + 8) = v12;
*(_OWORD *)(a1 + 16) = 0LL;
}
else
{
v15 = intx::operator>>(a2[2], a2[3], a3);
v14 = v6;
v7 = *a2;
v8 = a2[1];
*(_QWORD *)&v9 = intx::operator<<(v4, v5, 127 - a3);
v10 = v9;
*(_QWORD *)a1 = (2 * v9) | intx::operator>>(v7, v8, a3);
*(_QWORD *)(a1 + 8) = (v10 >> 63) | v11;
*(_QWORD *)(a1 + 16) = v15;
*(_QWORD *)(a1 + 24) = v14;
}
}
return a1;
}
|
operator>>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV RBX,RDI
CMP RDX,0x100
JNC 0x0013acc7
MOV R14,RDX
MOV R15,RSI
MOV RBP,qword ptr [RSI + 0x10]
MOV R13,qword ptr [RSI + 0x18]
CMP RDX,0x7f
JA 0x0013ac95
MOV RDI,RBP
MOV RSI,R13
MOV RDX,R14
CALL 0x00139959
MOV qword ptr [RSP + 0x10],RAX
MOV qword ptr [RSP + 0x8],RDX
MOV R12,qword ptr [R15]
MOV R15,qword ptr [R15 + 0x8]
PUSH 0x7f
POP RDX
SUB RDX,R14
MOV RDI,RBP
MOV RSI,R13
CALL 0x00139d59
MOV R13,RAX
MOV RBP,RDX
SHLD RBP,RAX,0x1
ADD R13,RAX
MOV RDI,R12
MOV RSI,R15
MOV RDX,R14
CALL 0x00139959
OR RAX,R13
OR RDX,RBP
MOV qword ptr [RBX],RAX
MOV qword ptr [RBX + 0x8],RDX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RBX + 0x10],RAX
MOV RAX,qword ptr [RSP + 0x8]
MOV qword ptr [RBX + 0x18],RAX
JMP 0x0013acb5
LAB_0013ac95:
ADD R14,-0x80
MOV RDI,RBP
MOV RSI,R13
MOV RDX,R14
CALL 0x00139959
MOV qword ptr [RBX],RAX
MOV qword ptr [RBX + 0x8],RDX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x10],XMM0
LAB_0013acb5:
MOV RAX,RBX
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0013acc7:
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x10],XMM0
MOVUPS xmmword ptr [RBX],XMM0
JMP 0x0013acb5
|
/* intx::TEMPNAMEPLACEHOLDERVALUE(intx::uint<256u> const&, unsigned long) */
intx * __thiscall intx::operator>>(intx *this,uint *param_1,ulong param_2)
{
intx *piVar1;
int8 uVar2;
intx *piVar3;
int8 uVar4;
int1 auVar5 [16];
int1 auVar6 [16];
int1 auVar7 [16];
if (param_2 < 0x100) {
piVar1 = *(intx **)(param_1 + 0x10);
uVar2 = *(int8 *)(param_1 + 0x18);
if (param_2 < 0x80) {
auVar5 = operator>>(piVar1,uVar2,param_2);
piVar3 = *(intx **)param_1;
uVar4 = *(int8 *)(param_1 + 8);
auVar6 = operator<<(piVar1,uVar2,0x7f - param_2);
auVar7 = operator>>(piVar3,uVar4,param_2);
*(ulong *)this = auVar7._0_8_ | auVar6._0_8_ * 2;
*(ulong *)(this + 8) = auVar7._8_8_ | auVar6._8_8_ << 1 | auVar6._0_8_ >> 0x3f;
*(int1 (*) [16])(this + 0x10) = auVar5;
}
else {
auVar5 = operator>>(piVar1,uVar2,param_2 - 0x80);
*(int1 (*) [16])this = auVar5;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
}
}
else {
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
}
return this;
}
|
|
19,968
|
set_default_charset
|
eloqsql/libmariadb/libmariadb/mariadb_charset.c
|
my_bool set_default_charset(uint cs, myf flags __attribute__((unused)))
{
MARIADB_CHARSET_INFO *new_charset;
new_charset = mysql_get_charset_by_nr(cs);
if (!new_charset)
{
return(TRUE); /* error */
}
ma_default_charset_info = new_charset;
return(FALSE);
}
|
O0
|
c
|
set_default_charset:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl -0x8(%rbp), %edi
callq 0x4a0f0
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x4a1b7
movb $0x1, -0x1(%rbp)
jmp 0x4a1c9
movq -0x18(%rbp), %rcx
leaq 0x1ac66(%rip), %rax # 0x64e28
movq %rcx, (%rax)
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
set_default_charset:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], edi
mov [rbp+var_C], esi
mov edi, [rbp+var_8]
call mysql_get_charset_by_nr
mov [rbp+var_18], rax
cmp [rbp+var_18], 0
jnz short loc_4A1B7
mov [rbp+var_1], 1
jmp short loc_4A1C9
loc_4A1B7:
mov rcx, [rbp+var_18]
lea rax, ma_default_charset_info
mov [rax], rcx
mov [rbp+var_1], 0
loc_4A1C9:
mov al, [rbp+var_1]
add rsp, 20h
pop rbp
retn
|
char set_default_charset(int a1)
{
char *charset_by_nr; // [rsp+8h] [rbp-18h]
charset_by_nr = mysql_get_charset_by_nr(a1);
if ( !charset_by_nr )
return 1;
ma_default_charset_info = charset_by_nr;
return 0;
}
|
set_default_charset:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV dword ptr [RBP + -0x8],EDI
MOV dword ptr [RBP + -0xc],ESI
MOV EDI,dword ptr [RBP + -0x8]
CALL 0x0014a0f0
MOV qword ptr [RBP + -0x18],RAX
CMP qword ptr [RBP + -0x18],0x0
JNZ 0x0014a1b7
MOV byte ptr [RBP + -0x1],0x1
JMP 0x0014a1c9
LAB_0014a1b7:
MOV RCX,qword ptr [RBP + -0x18]
LEA RAX,[0x164e28]
MOV qword ptr [RAX],RCX
MOV byte ptr [RBP + -0x1],0x0
LAB_0014a1c9:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x20
POP RBP
RET
|
int8 set_default_charset(int4 param_1)
{
long lVar1;
int8 *puVar2;
bool local_9;
lVar1 = mysql_get_charset_by_nr(param_1);
if (lVar1 != 0) {
puVar2 = &ma_default_charset_info;
ma_default_charset_info = lVar1;
}
else {
puVar2 = (int8 *)0x0;
}
local_9 = lVar1 == 0;
return CONCAT71((int7)((ulong)puVar2 >> 8),local_9);
}
|
|
19,969
|
set_default_charset
|
eloqsql/libmariadb/libmariadb/mariadb_charset.c
|
my_bool set_default_charset(uint cs, myf flags __attribute__((unused)))
{
MARIADB_CHARSET_INFO *new_charset;
new_charset = mysql_get_charset_by_nr(cs);
if (!new_charset)
{
return(TRUE); /* error */
}
ma_default_charset_info = new_charset;
return(FALSE);
}
|
O3
|
c
|
set_default_charset:
pushq %rbp
movq %rsp, %rbp
leaq 0xf635(%rip), %rax # 0x42c40
addq $-0x48, %rax
movl 0x48(%rax), %ecx
addq $0x48, %rax
testl %ecx, %ecx
je 0x3361e
cmpl %edi, %ecx
jne 0x3360f
testl %ecx, %ecx
je 0x33630
leaq 0x1a30f(%rip), %rcx # 0x4d938
movq %rax, (%rcx)
xorl %eax, %eax
jmp 0x33632
movb $0x1, %al
popq %rbp
retq
|
set_default_charset:
push rbp
mov rbp, rsp
lea rax, mariadb_compiled_charsets
add rax, 0FFFFFFFFFFFFFFB8h
loc_3360F:
mov ecx, [rax+48h]
add rax, 48h ; 'H'
test ecx, ecx
jz short loc_3361E
cmp ecx, edi
jnz short loc_3360F
loc_3361E:
test ecx, ecx
jz short loc_33630
lea rcx, ma_default_charset_info
mov [rcx], rax
xor eax, eax
jmp short loc_33632
loc_33630:
mov al, 1
loc_33632:
pop rbp
retn
|
char set_default_charset(int a1)
{
char *v1; // rax
int v2; // ecx
v1 = (char *)&mariadb_compiled_charsets - 72;
do
{
v2 = *((_DWORD *)v1 + 18);
v1 += 72;
}
while ( v2 && v2 != a1 );
if ( !v2 )
return 1;
ma_default_charset_info = v1;
return 0;
}
|
set_default_charset:
PUSH RBP
MOV RBP,RSP
LEA RAX,[0x142c40]
ADD RAX,-0x48
LAB_0013360f:
MOV ECX,dword ptr [RAX + 0x48]
ADD RAX,0x48
TEST ECX,ECX
JZ 0x0013361e
CMP ECX,EDI
JNZ 0x0013360f
LAB_0013361e:
TEST ECX,ECX
JZ 0x00133630
LEA RCX,[0x14d938]
MOV qword ptr [RCX],RAX
XOR EAX,EAX
JMP 0x00133632
LAB_00133630:
MOV AL,0x1
LAB_00133632:
POP RBP
RET
|
int8 set_default_charset(int param_1)
{
int iVar1;
int *puVar2;
int8 uVar3;
puVar2 = &UNK_00142bf8;
do {
iVar1 = *(int *)(puVar2 + 0x48);
puVar2 = puVar2 + 0x48;
if (iVar1 == 0) break;
} while (iVar1 != param_1);
if (iVar1 == 0) {
uVar3 = CONCAT71((int7)((ulong)puVar2 >> 8),1);
}
else {
uVar3 = 0;
ma_default_charset_info = puVar2;
}
return uVar3;
}
|
|
19,970
|
minja::Parser::parseLogicalAnd()
|
monkey531[P]llama/common/minja.hpp
|
std::shared_ptr<Expression> parseLogicalAnd() {
auto left = parseLogicalNot();
if (!left) throw std::runtime_error("Expected left side of 'logical and' expression");
static std::regex and_tok(R"(and\b)");
auto location = get_location();
while (!consumeToken(and_tok).empty()) {
auto right = parseLogicalNot();
if (!right) throw std::runtime_error("Expected right side of 'and' expression");
left = std::make_shared<BinaryOpExpr>(location, std::move(left), std::move(right), BinaryOpExpr::Op::And);
}
return left;
}
|
O1
|
cpp
|
minja::Parser::parseLogicalAnd():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x41d70
cmpq $0x0, (%rbx)
je 0x41c77
leaq 0xa42e4(%rip), %rax # 0xe5df0
movb (%rax), %al
testb %al, %al
je 0x41ca9
movq (%r14), %rax
movq %rax, 0x20(%rsp)
movq 0x8(%r14), %rax
movq %rax, 0x28(%rsp)
testq %rax, %rax
je 0x41b41
movq 0xa3465(%rip), %rcx # 0xe4f98
cmpb $0x0, (%rcx)
je 0x41b3d
incl 0x8(%rax)
jmp 0x41b41
lock
incl 0x8(%rax)
movq 0x20(%r14), %rax
subq 0x10(%r14), %rax
leaq 0x20(%rsp), %rcx
movq %rax, 0x10(%rcx)
movq %rsp, %r13
leaq 0xa1e3c(%rip), %r12 # 0xe3998
addq $0x10, %r12
movq %r13, %rdi
movq %r14, %rsi
leaq 0xa4263(%rip), %rdx # 0xe5dd0
movl $0x1, %ecx
callq 0x35568
movq (%rsp), %rdi
movq 0x8(%rsp), %r15
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x41b97
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x196e0
testq %r15, %r15
je 0x41c22
movq %r13, %rdi
movq %r14, %rsi
callq 0x41d70
cmpq $0x0, (%rsp)
je 0x41c43
movl $0x58, %edi
callq 0x196d0
movq %rax, %rbp
movabsq $0x100000001, %rax # imm = 0x100000001
movq %rax, 0x8(%rbp)
movq %r12, (%rbp)
movq %rbp, %r15
addq $0x10, %r15
movq %r15, %rdi
leaq 0x20(%rsp), %rsi
movq %rbx, %rdx
movq %r13, %rcx
movl $0xe, %r8d
callq 0x5c82e
movq %r15, (%rbx)
movq 0x8(%rbx), %rdi
movq %rbp, 0x8(%rbx)
testq %rdi, %rdi
je 0x41c0a
callq 0x3503e
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x41b60
callq 0x3503e
jmp 0x41b60
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x41c31
callq 0x3503e
movq %rbx, %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x19380
movq %rax, %r15
leaq 0x6f76a(%rip), %rsi # 0xb13c1
movq %rax, %rdi
callq 0x19280
movq 0xa338a(%rip), %rsi # 0xe4ff0
movq 0xa3303(%rip), %rdx # 0xe4f70
movq %r15, %rdi
callq 0x19bb0
jmp 0x41ca9
movl $0x10, %edi
callq 0x19380
movq %rax, %r15
leaq 0x6f701(%rip), %rsi # 0xb138c
movq %rax, %rdi
callq 0x19280
movq 0xa3356(%rip), %rsi # 0xe4ff0
movq 0xa32cf(%rip), %rdx # 0xe4f70
movq %r15, %rdi
callq 0x19bb0
leaq 0xa4140(%rip), %rdi # 0xe5df0
callq 0x19c60
testl %eax, %eax
je 0x41b16
leaq 0xa410c(%rip), %rdi # 0xe5dd0
leaq 0x6f6f0(%rip), %rsi # 0xb13bb
movl $0x10, %edx
callq 0x350ae
leaq -0xcbc6(%rip), %rdi # 0x35116
leaq 0xa40ed(%rip), %rsi # 0xe5dd0
leaq 0xa39fe(%rip), %rdx # 0xe56e8
callq 0x19600
leaq 0xa40fa(%rip), %rdi # 0xe5df0
callq 0x19470
jmp 0x41b16
movq %rax, %r14
leaq 0xa40e6(%rip), %rdi # 0xe5df0
callq 0x19460
jmp 0x41d5a
movq %rax, %r14
jmp 0x41d5a
movq %rax, %r14
movq %r15, %rdi
callq 0x19520
jmp 0x41d5a
jmp 0x41d34
movq %rax, %r14
movq %r15, %rdi
callq 0x19520
jmp 0x41d37
jmp 0x41d48
movq %rax, %r14
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x41d4b
callq 0x3503e
jmp 0x41d4b
movq %rax, %r14
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x41d5a
callq 0x3503e
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x41d68
callq 0x3503e
movq %r14, %rdi
callq 0x19c10
|
_ZN5minja6Parser15parseLogicalAndEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov r14, rsi
mov rbx, rdi
call _ZN5minja6Parser15parseLogicalNotEv; minja::Parser::parseLogicalNot(void)
cmp qword ptr [rbx], 0
jz loc_41C77
lea rax, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; `guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok
mov al, [rax]
test al, al
jz loc_41CA9
loc_41B16:
mov rax, [r14]
mov [rsp+68h+var_48], rax
mov rax, [r14+8]
mov [rsp+68h+var_40], rax
test rax, rax
jz short loc_41B41
mov rcx, cs:__libc_single_threaded_ptr
cmp byte ptr [rcx], 0
jz short loc_41B3D
inc dword ptr [rax+8]
jmp short loc_41B41
loc_41B3D:
lock inc dword ptr [rax+8]
loc_41B41:
mov rax, [r14+20h]
sub rax, [r14+10h]
lea rcx, [rsp+68h+var_48]
mov [rcx+10h], rax
mov r13, rsp
lea r12, _ZTVSt23_Sp_counted_ptr_inplaceIN5minja12BinaryOpExprESaIS1_ELN9__gnu_cxx12_Lock_policyE2EE; `vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2>
add r12, 10h
loc_41B60:
mov rdi, r13
mov rsi, r14
lea rdx, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; minja::Parser::parseLogicalAnd(void)::and_tok
mov ecx, 1
call _ZN5minja6Parser12consumeTokenERKNSt7__cxx1111basic_regexIcNS1_12regex_traitsIcEEEENS_13SpaceHandlingE; minja::Parser::consumeToken(std::basic_regex<char,std::regex_traits<char>> const&,minja::SpaceHandling)
mov rdi, [rsp+68h+var_68]; void *
mov r15, [rsp+68h+var_60]
lea rax, [rsp+68h+var_58]
cmp rdi, rax
jz short loc_41B97
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_41B97:
test r15, r15
jz loc_41C22
mov rdi, r13; this
mov rsi, r14
call _ZN5minja6Parser15parseLogicalNotEv; minja::Parser::parseLogicalNot(void)
cmp [rsp+68h+var_68], 0
jz loc_41C43
mov edi, 58h ; 'X'; unsigned __int64
call __Znwm; operator new(ulong)
mov rbp, rax
mov rax, 100000001h
mov [rbp+8], rax
mov [rbp+0], r12
mov r15, rbp
add r15, 10h
mov rdi, r15
lea rsi, [rsp+68h+var_48]
mov rdx, rbx
mov rcx, r13
mov r8d, 0Eh
call _ZN5minja12BinaryOpExprC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEES7_NS0_2OpE; minja::BinaryOpExpr::BinaryOpExpr(minja::Location const&,std::shared_ptr<minja::Expression> &&,std::shared_ptr<minja::Expression> &,minja::BinaryOpExpr::Op)
mov [rbx], r15
mov rdi, [rbx+8]
mov [rbx+8], rbp
test rdi, rdi
jz short loc_41C0A
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_41C0A:
mov rdi, [rsp+68h+var_60]
test rdi, rdi
jz loc_41B60
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
jmp loc_41B60
loc_41C22:
mov rdi, [rsp+68h+var_40]
test rdi, rdi
jz short loc_41C31
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_41C31:
mov rax, rbx
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_41C43:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedRightS_0; "Expected right side of 'and' expression"
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
jmp short loc_41CA9
loc_41C77:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedLeftSi_0; "Expected left side of 'logical and' exp"...
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
loc_41CA9:
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_acquire
test eax, eax
jz loc_41B16
lea rdi, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; minja::Parser::parseLogicalAnd(void)::and_tok
lea rsi, aAndB; "and\\b"
mov edx, 10h
call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEEC2EPKcNSt15regex_constants18syntax_option_typeE; std::basic_regex<char,std::regex_traits<char>>::basic_regex(char const*,std::regex_constants::syntax_option_type)
lea rdi, _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; lpfunc
lea rsi, _ZZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; obj
lea rdx, __dso_handle; lpdso_handle
call ___cxa_atexit
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_release
jmp loc_41B16
mov r14, rax
lea rdi, _ZGVZN5minja6Parser15parseLogicalAndEvE7and_tokB5cxx11; __guard *
call ___cxa_guard_abort
jmp short loc_41D5A
mov r14, rax
jmp short loc_41D5A
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_41D5A
jmp short loc_41D34
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_41D37
jmp short loc_41D48
loc_41D34:
mov r14, rax
loc_41D37:
mov rdi, [rsp+arg_0]
test rdi, rdi
jz short loc_41D4B
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
jmp short loc_41D4B
loc_41D48:
mov r14, rax
loc_41D4B:
mov rdi, [rsp+arg_20]
test rdi, rdi
jz short loc_41D5A
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_41D5A:
mov rdi, [rbx+8]
test rdi, rdi
jz short loc_41D68
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_41D68:
mov rdi, r14
call __Unwind_Resume
|
minja::Parser * minja::Parser::parseLogicalAnd(volatile signed __int32 **this, long long *a2)
{
volatile signed __int32 *v3; // rax
volatile signed __int32 *v4; // r15
volatile signed __int32 *v5; // rbp
volatile signed __int32 *v6; // rdi
std::runtime_error *v8; // r15
std::runtime_error *exception; // r15
void *v10; // [rsp+0h] [rbp-68h] BYREF
volatile signed __int32 *v11; // [rsp+8h] [rbp-60h]
long long v12; // [rsp+10h] [rbp-58h] BYREF
long long v13; // [rsp+20h] [rbp-48h] BYREF
volatile signed __int32 *v14; // [rsp+28h] [rbp-40h]
long long v15; // [rsp+30h] [rbp-38h]
minja::Parser::parseLogicalNot((minja::Parser *)this);
if ( !*this )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Expected left side of 'logical and' expression");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
if ( !(_BYTE)`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]
&& __cxa_guard_acquire(&`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]) )
{
std::basic_regex<char,std::regex_traits<char>>::basic_regex(
(long long)&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
"and\\b",
0x10u);
__cxa_atexit(
(void (*)(void *))std::basic_regex<char,std::regex_traits<char>>::~basic_regex,
&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
&_dso_handle);
__cxa_guard_release(&`guard variable for'minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11]);
}
v13 = *a2;
v3 = (volatile signed __int32 *)a2[1];
v14 = v3;
if ( v3 )
{
if ( _libc_single_threaded )
++*((_DWORD *)v3 + 2);
else
_InterlockedIncrement(v3 + 2);
}
v15 = a2[4] - a2[2];
while ( 1 )
{
minja::Parser::consumeToken(
(long long)&v10,
(long long)a2,
(long long)&minja::Parser::parseLogicalAnd(void)::and_tok[abi:cxx11],
1u);
v4 = v11;
if ( v10 != &v12 )
operator delete(v10, v12 + 1);
if ( !v4 )
break;
minja::Parser::parseLogicalNot((minja::Parser *)&v10);
if ( !v10 )
{
v8 = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(v8, "Expected right side of 'and' expression");
__cxa_throw(
v8,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
v5 = (volatile signed __int32 *)operator new(0x58uLL);
*((_QWORD *)v5 + 1) = 0x100000001LL;
*(_QWORD *)v5 = &`vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2>
+ 2;
minja::BinaryOpExpr::BinaryOpExpr(v5 + 4, &v13, this, &v10, 14LL);
*this = v5 + 4;
v6 = this[1];
this[1] = v5;
if ( v6 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v6);
if ( v11 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v11);
}
if ( v14 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v14);
return (minja::Parser *)this;
}
|
parseLogicalAnd:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV R14,RSI
MOV RBX,RDI
CALL 0x00141d70
CMP qword ptr [RBX],0x0
JZ 0x00141c77
LEA RAX,[0x1e5df0]
MOV AL,byte ptr [RAX]
TEST AL,AL
JZ 0x00141ca9
LAB_00141b16:
MOV RAX,qword ptr [R14]
MOV qword ptr [RSP + 0x20],RAX
MOV RAX,qword ptr [R14 + 0x8]
MOV qword ptr [RSP + 0x28],RAX
TEST RAX,RAX
JZ 0x00141b41
MOV RCX,qword ptr [0x001e4f98]
CMP byte ptr [RCX],0x0
JZ 0x00141b3d
INC dword ptr [RAX + 0x8]
JMP 0x00141b41
LAB_00141b3d:
INC.LOCK dword ptr [RAX + 0x8]
LAB_00141b41:
MOV RAX,qword ptr [R14 + 0x20]
SUB RAX,qword ptr [R14 + 0x10]
LEA RCX,[RSP + 0x20]
MOV qword ptr [RCX + 0x10],RAX
MOV R13,RSP
LEA R12,[0x1e3998]
ADD R12,0x10
LAB_00141b60:
MOV RDI,R13
MOV RSI,R14
LEA RDX,[0x1e5dd0]
MOV ECX,0x1
CALL 0x00135568
MOV RDI,qword ptr [RSP]
MOV R15,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x10]
CMP RDI,RAX
JZ 0x00141b97
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x001196e0
LAB_00141b97:
TEST R15,R15
JZ 0x00141c22
LAB_00141ba0:
MOV RDI,R13
MOV RSI,R14
CALL 0x00141d70
CMP qword ptr [RSP],0x0
JZ 0x00141c43
LAB_00141bb6:
MOV EDI,0x58
CALL 0x001196d0
LAB_00141bc0:
MOV RBP,RAX
MOV RAX,0x100000001
MOV qword ptr [RBP + 0x8],RAX
MOV qword ptr [RBP],R12
MOV R15,RBP
ADD R15,0x10
MOV RDI,R15
LEA RSI,[RSP + 0x20]
MOV RDX,RBX
MOV RCX,R13
MOV R8D,0xe
CALL 0x0015c82e
MOV qword ptr [RBX],R15
MOV RDI,qword ptr [RBX + 0x8]
MOV qword ptr [RBX + 0x8],RBP
TEST RDI,RDI
JZ 0x00141c0a
CALL 0x0013503e
LAB_00141c0a:
MOV RDI,qword ptr [RSP + 0x8]
TEST RDI,RDI
JZ 0x00141b60
CALL 0x0013503e
JMP 0x00141b60
LAB_00141c22:
MOV RDI,qword ptr [RSP + 0x28]
TEST RDI,RDI
JZ 0x00141c31
CALL 0x0013503e
LAB_00141c31:
MOV RAX,RBX
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00141c43:
MOV EDI,0x10
CALL 0x00119380
MOV R15,RAX
LAB_00141c50:
LEA RSI,[0x1b13c1]
MOV RDI,RAX
CALL 0x00119280
LAB_00141c5f:
MOV RSI,qword ptr [0x001e4ff0]
MOV RDX,qword ptr [0x001e4f70]
MOV RDI,R15
CALL 0x00119bb0
LAB_00141c77:
MOV EDI,0x10
CALL 0x00119380
MOV R15,RAX
LAB_00141c84:
LEA RSI,[0x1b138c]
MOV RDI,RAX
CALL 0x00119280
LAB_00141c93:
MOV RSI,qword ptr [0x001e4ff0]
MOV RDX,qword ptr [0x001e4f70]
MOV RDI,R15
CALL 0x00119bb0
LAB_00141ca9:
LEA RDI,[0x1e5df0]
CALL 0x00119c60
TEST EAX,EAX
JZ 0x00141b16
LAB_00141cbd:
LEA RDI,[0x1e5dd0]
LEA RSI,[0x1b13bb]
MOV EDX,0x10
CALL 0x001350ae
LAB_00141cd5:
LEA RDI,[0x135116]
LEA RSI,[0x1e5dd0]
LEA RDX,[0x1e56e8]
CALL 0x00119600
LEA RDI,[0x1e5df0]
CALL 0x00119470
JMP 0x00141b16
|
/* minja::Parser::parseLogicalAnd() */
void minja::Parser::parseLogicalAnd(void)
{
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Var1;
int iVar2;
int8 *puVar3;
runtime_error *prVar4;
int8 *in_RSI;
long *in_RDI;
long *local_68;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_60;
long local_58 [2];
int8 local_48;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_40;
long local_38;
parseLogicalNot();
if (*in_RDI == 0) {
prVar4 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00141c84 to 00141c92 has its CatchHandler @ 00141d16 */
std::runtime_error::runtime_error(prVar4,"Expected left side of \'logical and\' expression");
/* try { // try from 00141c93 to 00141ca8 has its CatchHandler @ 00141d11 */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar4,PTR_typeinfo_001e4ff0,PTR__runtime_error_001e4f70);
}
if (parseLogicalAnd()::and_tok_abi_cxx11_ == '\0') {
iVar2 = __cxa_guard_acquire(&parseLogicalAnd()::and_tok_abi_cxx11_);
if (iVar2 != 0) {
/* try { // try from 00141cbd to 00141cd4 has its CatchHandler @ 00141d00 */
std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::basic_regex
((basic_regex<char,std::__cxx11::regex_traits<char>> *)
parseLogicalAnd()::and_tok_abi_cxx11_,"and\\b",0x10);
__cxa_atexit(std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex,
parseLogicalAnd()::and_tok_abi_cxx11_,&__dso_handle);
__cxa_guard_release(&parseLogicalAnd()::and_tok_abi_cxx11_);
}
}
local_48 = *in_RSI;
local_40 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RSI[1];
if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
if (*PTR___libc_single_threaded_001e4f98 == '\0') {
LOCK();
*(int *)(local_40 + 8) = *(int *)(local_40 + 8) + 1;
UNLOCK();
}
else {
*(int *)(local_40 + 8) = *(int *)(local_40 + 8) + 1;
}
}
local_38 = in_RSI[4] - in_RSI[2];
while( true ) {
/* try { // try from 00141b60 to 00141b76 has its CatchHandler @ 00141d48 */
consumeToken(&local_68);
p_Var1 = local_60;
if (local_68 != local_58) {
operator_delete(local_68,local_58[0] + 1);
}
if (p_Var1 == (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) break;
/* try { // try from 00141ba0 to 00141baa has its CatchHandler @ 00141d32 */
parseLogicalNot();
if (local_68 == (long *)0x0) {
prVar4 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00141c50 to 00141c5e has its CatchHandler @ 00141d25 */
std::runtime_error::runtime_error(prVar4,"Expected right side of \'and\' expression");
/* try { // try from 00141c5f to 00141c74 has its CatchHandler @ 00141d23 */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar4,PTR_typeinfo_001e4ff0,PTR__runtime_error_001e4f70);
}
/* try { // try from 00141bb6 to 00141bbf has its CatchHandler @ 00141d34 */
puVar3 = (int8 *)operator_new(0x58);
puVar3[1] = 0x100000001;
*puVar3 = &PTR___Sp_counted_ptr_inplace_001e39a8;
BinaryOpExpr::BinaryOpExpr((BinaryOpExpr *)(puVar3 + 2),&local_48);
*in_RDI = (long)(puVar3 + 2);
p_Var1 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RDI[1];
in_RDI[1] = (long)puVar3;
if (p_Var1 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Var1);
}
if (local_60 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_60);
}
}
if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_40);
}
return;
}
|
|
19,971
|
my_strnxfrm_tis620_nopad
|
eloqsql/strings/ctype-tis620.c
|
static size_t
my_strnxfrm_tis620_nopad(CHARSET_INFO *cs,
uchar *dst, size_t dstlen, uint nweights,
const uchar *src, size_t srclen, uint flags)
{
size_t len, dstlen0= dstlen;
len= MY_MIN(dstlen, srclen);
memcpy(dst, src, len);
len= thai2sortable(dst, len);
set_if_smaller(dstlen, nweights);
set_if_smaller(len, dstlen);
len= my_strxfrm_pad_desc_and_reverse_nopad(cs, dst, dst + len, dst + dstlen,
(uint)(dstlen - len), flags, 0);
if ((flags & MY_STRXFRM_PAD_TO_MAXLEN) && len < dstlen0)
{
size_t fill_length= dstlen0 - len;
memset(dst + len, 0x00, fill_length);
len= dstlen0;
}
return len;
}
|
O3
|
c
|
my_strnxfrm_tis620_nopad:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r9, %r12
movl %ecx, %r15d
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r13
cmpq %r9, %rdx
cmovbq %rdx, %r12
movq %rsi, %rdi
movq %r8, %rsi
movq %r12, %rdx
callq 0x24290
movq %r14, %rdi
movq %r12, %rsi
callq 0x3b45b
movl %r15d, %r8d
cmpq %rbx, %r8
cmovaeq %rbx, %r8
cmpq %r8, %r12
cmovaeq %r8, %r12
leaq (%r14,%r12), %rdx
leaq (%r14,%r8), %rcx
subl %r12d, %r8d
movl $0x0, (%rsp)
movq %r13, %rdi
movq %r14, %rsi
movl 0x10(%rbp), %r15d
movl %r15d, %r9d
callq 0x382ee
testb %r15b, %r15b
jns 0x3b5f3
movq %rbx, %rdx
subq %rax, %rdx
jbe 0x3b5f3
addq %rax, %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x241c0
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
|
my_strnxfrm_tis620_nopad:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r12, r9
mov r15d, ecx
mov rbx, rdx
mov r14, rsi
mov r13, rdi
cmp rdx, r9
cmovb r12, rdx
mov rdi, rsi
mov rsi, r8
mov rdx, r12
call _memcpy
mov rdi, r14
mov rsi, r12
call thai2sortable
mov r8d, r15d
cmp r8, rbx
cmovnb r8, rbx
cmp r12, r8
cmovnb r12, r8
lea rdx, [r14+r12]
lea rcx, [r14+r8]
sub r8d, r12d
mov [rsp+30h+var_30], 0
mov rdi, r13
mov rsi, r14
mov r15d, [rbp+arg_0]
mov r9d, r15d
call my_strxfrm_pad_desc_and_reverse_nopad
test r15b, r15b
jns short loc_3B5F3
mov rdx, rbx
sub rdx, rax
jbe short loc_3B5F3
add r14, rax
mov rdi, r14
xor esi, esi
call _memset
mov rax, rbx
loc_3B5F3:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
unsigned long long my_strnxfrm_tis620_nopad(
long long a1,
unsigned __int8 *a2,
unsigned long long a3,
unsigned int a4,
long long a5,
unsigned long long a6,
unsigned int a7)
{
unsigned long long v7; // r12
unsigned long long v10; // r8
unsigned long long result; // rax
v7 = a6;
if ( a3 < a6 )
v7 = a3;
memcpy(a2, a5, v7);
thai2sortable(a2, v7);
v10 = a4;
if ( a4 >= a3 )
v10 = a3;
if ( v7 >= v10 )
v7 = v10;
result = my_strxfrm_pad_desc_and_reverse_nopad(
a1,
(long long)a2,
(unsigned long long)&a2[v7],
(unsigned long long)&a2[v10],
(int)v10 - (int)v7,
a7,
0);
if ( (a7 & 0x80u) != 0 && a3 > result )
{
memset(&a2[result], 0LL, a3 - result);
return a3;
}
return result;
}
|
my_strnxfrm_tis620_nopad:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R12,R9
MOV R15D,ECX
MOV RBX,RDX
MOV R14,RSI
MOV R13,RDI
CMP RDX,R9
CMOVC R12,RDX
MOV RDI,RSI
MOV RSI,R8
MOV RDX,R12
CALL 0x00124290
MOV RDI,R14
MOV RSI,R12
CALL 0x0013b45b
MOV R8D,R15D
CMP R8,RBX
CMOVNC R8,RBX
CMP R12,R8
CMOVNC R12,R8
LEA RDX,[R14 + R12*0x1]
LEA RCX,[R14 + R8*0x1]
SUB R8D,R12D
MOV dword ptr [RSP],0x0
MOV RDI,R13
MOV RSI,R14
MOV R15D,dword ptr [RBP + 0x10]
MOV R9D,R15D
CALL 0x001382ee
TEST R15B,R15B
JNS 0x0013b5f3
MOV RDX,RBX
SUB RDX,RAX
JBE 0x0013b5f3
ADD R14,RAX
MOV RDI,R14
XOR ESI,ESI
CALL 0x001241c0
MOV RAX,RBX
LAB_0013b5f3:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
ulong my_strnxfrm_tis620_nopad
(int8 param_1,void *param_2,ulong param_3,uint param_4,void *param_5,
ulong param_6,int4 param_7)
{
int8 in_RAX;
ulong uVar1;
uint uVar2;
uVar2 = (uint)((ulong)in_RAX >> 0x20);
if (param_3 < param_6) {
param_6 = param_3;
}
memcpy(param_2,param_5,param_6);
thai2sortable(param_2,param_6);
uVar1 = (ulong)param_4;
if (param_3 <= param_4) {
uVar1 = param_3;
}
if (uVar1 <= param_6) {
param_6 = uVar1;
}
uVar1 = my_strxfrm_pad_desc_and_reverse_nopad
(param_1,param_2,(long)param_2 + param_6,(long)param_2 + uVar1,
(int)uVar1 - (int)param_6,param_7,(ulong)uVar2 << 0x20);
if (((char)param_7 < '\0') && (uVar1 <= param_3 && param_3 - uVar1 != 0)) {
memset((void *)((long)param_2 + uVar1),0,param_3 - uVar1);
uVar1 = param_3;
}
return uVar1;
}
|
|
19,972
|
TextToInteger
|
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtext.c
|
int TextToInteger(const char *text)
{
int value = 0;
int sign = 1;
if ((text[0] == '+') || (text[0] == '-'))
{
if (text[0] == '-') sign = -1;
text++;
}
for (int i = 0; ((text[i] >= '0') && (text[i] <= '9')); i++) value = value*10 + (int)(text[i] - '0');
return value*sign;
}
|
O0
|
c
|
TextToInteger:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
movl $0x1, -0x10(%rbp)
movq -0x8(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2b, %eax
je 0xe6bee
movq -0x8(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2d, %eax
jne 0xe6c0d
movq -0x8(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2d, %eax
jne 0xe6c01
movl $0xffffffff, -0x10(%rbp) # imm = 0xFFFFFFFF
movq -0x8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x8(%rbp)
movl $0x0, -0x14(%rbp)
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movsbl (%rax,%rcx), %ecx
xorl %eax, %eax
cmpl $0x30, %ecx
movb %al, -0x15(%rbp)
jl 0xe6c3f
movq -0x8(%rbp), %rax
movslq -0x14(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x39, %eax
setle %al
movb %al, -0x15(%rbp)
movb -0x15(%rbp), %al
testb $0x1, %al
jne 0xe6c48
jmp 0xe6c6b
imull $0xa, -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
movslq -0x14(%rbp), %rdx
movsbl (%rcx,%rdx), %ecx
subl $0x30, %ecx
addl %ecx, %eax
movl %eax, -0xc(%rbp)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0xe6c14
movl -0xc(%rbp), %eax
imull -0x10(%rbp), %eax
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
TextToInteger:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_C], 0
mov [rbp+var_10], 1
mov rax, [rbp+var_8]
movsx eax, byte ptr [rax]
cmp eax, 2Bh ; '+'
jz short loc_E6BEE
mov rax, [rbp+var_8]
movsx eax, byte ptr [rax]
cmp eax, 2Dh ; '-'
jnz short loc_E6C0D
loc_E6BEE:
mov rax, [rbp+var_8]
movsx eax, byte ptr [rax]
cmp eax, 2Dh ; '-'
jnz short loc_E6C01
mov [rbp+var_10], 0FFFFFFFFh
loc_E6C01:
mov rax, [rbp+var_8]
add rax, 1
mov [rbp+var_8], rax
loc_E6C0D:
mov [rbp+var_14], 0
loc_E6C14:
mov rax, [rbp+var_8]
movsxd rcx, [rbp+var_14]
movsx ecx, byte ptr [rax+rcx]
xor eax, eax
cmp ecx, 30h ; '0'
mov [rbp+var_15], al
jl short loc_E6C3F
mov rax, [rbp+var_8]
movsxd rcx, [rbp+var_14]
movsx eax, byte ptr [rax+rcx]
cmp eax, 39h ; '9'
setle al
mov [rbp+var_15], al
loc_E6C3F:
mov al, [rbp+var_15]
test al, 1
jnz short loc_E6C48
jmp short loc_E6C6B
loc_E6C48:
imul eax, [rbp+var_C], 0Ah
mov rcx, [rbp+var_8]
movsxd rdx, [rbp+var_14]
movsx ecx, byte ptr [rcx+rdx]
sub ecx, 30h ; '0'
add eax, ecx
mov [rbp+var_C], eax
mov eax, [rbp+var_14]
add eax, 1
mov [rbp+var_14], eax
jmp short loc_E6C14
loc_E6C6B:
mov eax, [rbp+var_C]
imul eax, [rbp+var_10]
pop rbp
retn
|
long long TextToInteger(_BYTE *a1)
{
bool v2; // [rsp+1h] [rbp-15h]
int i; // [rsp+2h] [rbp-14h]
int v4; // [rsp+6h] [rbp-10h]
int v5; // [rsp+Ah] [rbp-Ch]
_BYTE *v6; // [rsp+Eh] [rbp-8h]
v6 = a1;
v5 = 0;
v4 = 1;
if ( *a1 == 43 || *a1 == 45 )
{
if ( *a1 == 45 )
v4 = -1;
v6 = a1 + 1;
}
for ( i = 0; ; ++i )
{
v2 = 0;
if ( (char)v6[i] >= 48 )
v2 = (char)v6[i] <= 57;
if ( !v2 )
break;
v5 = (char)v6[i] - 48 + 10 * v5;
}
return (unsigned int)(v4 * v5);
}
|
TextToInteger:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],0x0
MOV dword ptr [RBP + -0x10],0x1
MOV RAX,qword ptr [RBP + -0x8]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x2b
JZ 0x001e6bee
MOV RAX,qword ptr [RBP + -0x8]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x2d
JNZ 0x001e6c0d
LAB_001e6bee:
MOV RAX,qword ptr [RBP + -0x8]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x2d
JNZ 0x001e6c01
MOV dword ptr [RBP + -0x10],0xffffffff
LAB_001e6c01:
MOV RAX,qword ptr [RBP + -0x8]
ADD RAX,0x1
MOV qword ptr [RBP + -0x8],RAX
LAB_001e6c0d:
MOV dword ptr [RBP + -0x14],0x0
LAB_001e6c14:
MOV RAX,qword ptr [RBP + -0x8]
MOVSXD RCX,dword ptr [RBP + -0x14]
MOVSX ECX,byte ptr [RAX + RCX*0x1]
XOR EAX,EAX
CMP ECX,0x30
MOV byte ptr [RBP + -0x15],AL
JL 0x001e6c3f
MOV RAX,qword ptr [RBP + -0x8]
MOVSXD RCX,dword ptr [RBP + -0x14]
MOVSX EAX,byte ptr [RAX + RCX*0x1]
CMP EAX,0x39
SETLE AL
MOV byte ptr [RBP + -0x15],AL
LAB_001e6c3f:
MOV AL,byte ptr [RBP + -0x15]
TEST AL,0x1
JNZ 0x001e6c48
JMP 0x001e6c6b
LAB_001e6c48:
IMUL EAX,dword ptr [RBP + -0xc],0xa
MOV RCX,qword ptr [RBP + -0x8]
MOVSXD RDX,dword ptr [RBP + -0x14]
MOVSX ECX,byte ptr [RCX + RDX*0x1]
SUB ECX,0x30
ADD EAX,ECX
MOV dword ptr [RBP + -0xc],EAX
MOV EAX,dword ptr [RBP + -0x14]
ADD EAX,0x1
MOV dword ptr [RBP + -0x14],EAX
JMP 0x001e6c14
LAB_001e6c6b:
MOV EAX,dword ptr [RBP + -0xc]
IMUL EAX,dword ptr [RBP + -0x10]
POP RBP
RET
|
int TextToInteger(char *param_1)
{
bool bVar1;
int local_1c;
int local_18;
int local_14;
char *local_10;
local_14 = 0;
local_18 = 1;
if ((*param_1 == '+') || (local_10 = param_1, *param_1 == '-')) {
if (*param_1 == '-') {
local_18 = -1;
}
local_10 = param_1 + 1;
}
local_1c = 0;
while( true ) {
bVar1 = false;
if ('/' < local_10[local_1c]) {
bVar1 = local_10[local_1c] < ':';
}
if (!bVar1) break;
local_14 = local_14 * 10 + local_10[local_1c] + -0x30;
local_1c = local_1c + 1;
}
return local_14 * local_18;
}
|
|
19,973
|
TextToInteger
|
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtext.c
|
int TextToInteger(const char *text)
{
int value = 0;
int sign = 1;
if ((text[0] == '+') || (text[0] == '-'))
{
if (text[0] == '-') sign = -1;
text++;
}
for (int i = 0; ((text[i] >= '0') && (text[i] <= '9')); i++) value = value*10 + (int)(text[i] - '0');
return value*sign;
}
|
O2
|
c
|
TextToInteger:
movzbl (%rdi), %eax
cmpl $0x2d, %eax
je 0x72401
cmpl $0x2b, %eax
jne 0x72414
xorl %ecx, %ecx
cmpb $0x2d, %al
setne %cl
leal -0x1(,%rcx,2), %ecx
incq %rdi
jmp 0x72417
pushq $0x1
popq %rcx
xorl %eax, %eax
movb (%rdi), %dl
addb $-0x30, %dl
cmpb $0xa, %dl
jae 0x72430
imull $0xa, %eax, %esi
movzbl %dl, %eax
addl %esi, %eax
incq %rdi
jmp 0x72419
imull %ecx, %eax
retq
|
TextToInteger:
movzx eax, byte ptr [rdi]
cmp eax, 2Dh ; '-'
jz short loc_72401
cmp eax, 2Bh ; '+'
jnz short loc_72414
loc_72401:
xor ecx, ecx
cmp al, 2Dh ; '-'
setnz cl
lea ecx, ds:0FFFFFFFFFFFFFFFFh[rcx*2]
inc rdi
jmp short loc_72417
loc_72414:
push 1
pop rcx
loc_72417:
xor eax, eax
loc_72419:
mov dl, [rdi]
add dl, 0D0h
cmp dl, 0Ah
jnb short loc_72430
imul esi, eax, 0Ah
movzx eax, dl
add eax, esi
inc rdi
jmp short loc_72419
loc_72430:
imul eax, ecx
retn
|
long long TextToInteger(_BYTE *a1)
{
int v1; // eax
int v2; // ecx
int v3; // eax
unsigned __int8 v4; // dl
v1 = (unsigned __int8)*a1;
if ( v1 == 45 || v1 == 43 )
{
v2 = 2 * ((_BYTE)v1 != 45) - 1;
++a1;
}
else
{
v2 = 1;
}
v3 = 0;
while ( 1 )
{
v4 = *a1 - 48;
if ( v4 >= 0xAu )
break;
v3 = 10 * v3 + v4;
++a1;
}
return (unsigned int)(v2 * v3);
}
|
TextToInteger:
MOVZX EAX,byte ptr [RDI]
CMP EAX,0x2d
JZ 0x00172401
CMP EAX,0x2b
JNZ 0x00172414
LAB_00172401:
XOR ECX,ECX
CMP AL,0x2d
SETNZ CL
LEA ECX,[-0x1 + RCX*0x2]
INC RDI
JMP 0x00172417
LAB_00172414:
PUSH 0x1
POP RCX
LAB_00172417:
XOR EAX,EAX
LAB_00172419:
MOV DL,byte ptr [RDI]
ADD DL,0xd0
CMP DL,0xa
JNC 0x00172430
IMUL ESI,EAX,0xa
MOVZX EAX,DL
ADD EAX,ESI
INC RDI
JMP 0x00172419
LAB_00172430:
IMUL EAX,ECX
RET
|
int TextToInteger(char *param_1)
{
char cVar1;
int iVar2;
int iVar3;
cVar1 = *param_1;
if ((cVar1 == '-') || (cVar1 == '+')) {
iVar3 = (uint)(cVar1 != '-') * 2 + -1;
param_1 = param_1 + 1;
}
else {
iVar3 = 1;
}
iVar2 = 0;
for (; (byte)(*param_1 - 0x30U) < 10; param_1 = param_1 + 1) {
iVar2 = (uint)(byte)(*param_1 - 0x30U) + iVar2 * 10;
}
return iVar2 * iVar3;
}
|
|
19,974
|
my_fprintf
|
eloqsql/strings/my_vsnprintf.c
|
int my_fprintf(FILE *stream, const char* format, ...)
{
int result;
va_list args;
va_start(args, format);
result= my_vfprintf(stream, format, args);
va_end(args);
return result;
}
|
O0
|
c
|
my_fprintf:
pushq %rbp
movq %rsp, %rbp
subq $0xe0, %rsp
testb %al, %al
je 0xab5b8
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 %r9, -0xb8(%rbp)
movq %r8, -0xc0(%rbp)
movq %rcx, -0xc8(%rbp)
movq %rdx, -0xd0(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
leaq -0xe0(%rbp), %rax
movq %rax, -0x20(%rbp)
leaq 0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
movl $0x30, -0x2c(%rbp)
movl $0x10, -0x30(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
leaq -0x30(%rbp), %rdx
callq 0xab3d0
movl %eax, -0x14(%rbp)
movl -0x14(%rbp), %eax
addq $0xe0, %rsp
popq %rbp
retq
nopl (%rax)
|
my_fprintf:
push rbp
mov rbp, rsp
sub rsp, 0E0h
test al, al
jz short loc_AB5B8
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_AB5B8:
mov [rbp+var_B8], r9
mov [rbp+var_C0], r8
mov [rbp+var_C8], rcx
mov [rbp+var_D0], rdx
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
lea rax, [rbp+var_E0]
mov [rbp+var_20], rax
lea rax, [rbp+arg_0]
mov [rbp+var_28], rax
mov [rbp+var_2C], 30h ; '0'
mov [rbp+var_30], 10h
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
lea rdx, [rbp+var_30]
call my_vfprintf
mov [rbp+var_14], eax
mov eax, [rbp+var_14]
add rsp, 0E0h
pop rbp
retn
|
long long my_fprintf(
long long a1,
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)
{
char v16; // [rsp+0h] [rbp-E0h] BYREF
long long v17; // [rsp+10h] [rbp-D0h]
long long v18; // [rsp+18h] [rbp-C8h]
long long v19; // [rsp+20h] [rbp-C0h]
long long v20; // [rsp+28h] [rbp-B8h]
__m128 v21; // [rsp+30h] [rbp-B0h]
__m128 v22; // [rsp+40h] [rbp-A0h]
__m128 v23; // [rsp+50h] [rbp-90h]
__m128 v24; // [rsp+60h] [rbp-80h]
__m128 v25; // [rsp+70h] [rbp-70h]
__m128 v26; // [rsp+80h] [rbp-60h]
__m128 v27; // [rsp+90h] [rbp-50h]
__m128 v28; // [rsp+A0h] [rbp-40h]
int v29[2]; // [rsp+B0h] [rbp-30h] BYREF
char *v30; // [rsp+B8h] [rbp-28h]
char *v31; // [rsp+C0h] [rbp-20h]
char *v32; // [rsp+D0h] [rbp-10h]
long long v33; // [rsp+D8h] [rbp-8h]
v21 = a7;
v22 = a8;
v23 = a9;
v24 = a10;
v25 = a11;
v26 = a12;
v27 = a13;
v28 = a14;
v20 = a6;
v19 = a5;
v18 = a4;
v17 = a3;
v33 = a1;
v32 = a2;
v31 = &v16;
v30 = &a15;
v29[1] = 48;
v29[0] = 16;
return (unsigned int)my_vfprintf(a1, a2, v29);
}
|
my_fprintf:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xe0
TEST AL,AL
JZ 0x001ab5b8
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_001ab5b8:
MOV qword ptr [RBP + -0xb8],R9
MOV qword ptr [RBP + -0xc0],R8
MOV qword ptr [RBP + -0xc8],RCX
MOV qword ptr [RBP + -0xd0],RDX
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
LEA RAX,[RBP + -0xe0]
MOV qword ptr [RBP + -0x20],RAX
LEA RAX,[RBP + 0x10]
MOV qword ptr [RBP + -0x28],RAX
MOV dword ptr [RBP + -0x2c],0x30
MOV dword ptr [RBP + -0x30],0x10
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
LEA RDX,[RBP + -0x30]
CALL 0x001ab3d0
MOV dword ptr [RBP + -0x14],EAX
MOV EAX,dword ptr [RBP + -0x14]
ADD RSP,0xe0
POP RBP
RET
|
int4
my_fprintf(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;
int4 uVar1;
int1 local_e8 [16];
int8 local_d8;
int8 local_d0;
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;
int4 local_38;
int4 local_34;
int1 *local_30;
int1 *local_28;
int8 local_18;
int8 local_10;
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;
local_30 = &stack0x00000008;
local_34 = 0x30;
local_38 = 0x10;
local_d8 = param_11;
local_d0 = param_12;
local_c8 = param_13;
local_c0 = param_14;
local_18 = param_10;
local_10 = param_9;
uVar1 = my_vfprintf(param_9,param_10,&local_38);
return uVar1;
}
|
|
19,975
|
my_caseup_str_utf8mb3
|
eloqsql/strings/ctype-utf8.c
|
static size_t my_caseup_str_utf8mb3(CHARSET_INFO *cs, char *src)
{
my_wc_t wc;
int srcres, dstres;
char *dst= src, *dst0= src;
MY_UNICASE_INFO *uni_plane= cs->caseinfo;
DBUG_ASSERT(cs->caseup_multiply == 1);
while (*src &&
(srcres= my_utf8mb3_uni_no_range(cs, &wc, (uchar *) src)) > 0)
{
my_toupper_utf8mb3(uni_plane, &wc);
if ((dstres= my_uni_utf8mb3_no_range(cs, wc, (uchar*) dst)) <= 0)
break;
src+= srcres;
dst+= dstres;
}
*dst= '\0';
return (size_t) (dst - dst0);
}
|
O3
|
c
|
my_caseup_str_utf8mb3:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
cmpb $0x0, (%rsi)
movq %rsi, %r14
je 0x5655b
movq 0x78(%rdi), %r13
leaq -0x30(%rbp), %r15
movq %rbx, %r12
movq %rbx, %r14
movq %r15, %rdi
movq %r12, %rsi
callq 0x56e34
testl %eax, %eax
je 0x5655b
movq 0x8(%r13), %rdx
movq -0x30(%rbp), %rcx
movzbl %ch, %esi
movq (%rdx,%rsi,8), %rdx
testq %rdx, %rdx
je 0x564ea
movzbl %cl, %ecx
leaq (%rcx,%rcx,2), %rcx
movl (%rdx,%rcx,4), %ecx
movq %rcx, -0x30(%rbp)
movl $0x1, %edx
cmpq $0x80, %rcx
jb 0x56544
movl $0x2, %edx
cmpq $0x800, %rcx # imm = 0x800
jb 0x5652b
cmpq $0xffff, %rcx # imm = 0xFFFF
ja 0x5655b
movl %ecx, %edx
andb $0x3f, %dl
orb $-0x80, %dl
movb %dl, 0x2(%r14)
shrq $0x6, %rcx
orq $0x800, %rcx # imm = 0x800
movl $0x3, %edx
movl %ecx, %esi
andb $0x3f, %sil
orb $-0x80, %sil
movb %sil, 0x1(%r14)
shrq $0x6, %rcx
orq $0xc0, %rcx
movb %cl, (%r14)
movl %eax, %eax
addq %rdx, %r14
cmpb $0x0, (%r12,%rax)
leaq (%r12,%rax), %r12
jne 0x564b5
movb $0x0, (%r14)
subq %rbx, %r14
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
my_caseup_str_utf8mb3:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rsi
cmp byte ptr [rsi], 0
mov r14, rsi
jz loc_5655B
mov r13, [rdi+78h]
lea r15, [rbp+var_30]
mov r12, rbx
mov r14, rbx
loc_564B5:
mov rdi, r15
mov rsi, r12
call my_utf8mb3_uni_no_range
test eax, eax
jz loc_5655B
mov rdx, [r13+8]
mov rcx, [rbp+var_30]
movzx esi, ch
mov rdx, [rdx+rsi*8]
test rdx, rdx
jz short loc_564EA
movzx ecx, cl
lea rcx, [rcx+rcx*2]
mov ecx, [rdx+rcx*4]
mov [rbp+var_30], rcx
loc_564EA:
mov edx, 1
cmp rcx, 80h
jb short loc_56544
mov edx, 2
cmp rcx, 800h
jb short loc_5652B
cmp rcx, 0FFFFh
ja short loc_5655B
mov edx, ecx
and dl, 3Fh
or dl, 80h
mov [r14+2], dl
shr rcx, 6
or rcx, 800h
mov edx, 3
loc_5652B:
mov esi, ecx
and sil, 3Fh
or sil, 80h
mov [r14+1], sil
shr rcx, 6
or rcx, 0C0h
loc_56544:
mov [r14], cl
mov eax, eax
add r14, rdx
cmp byte ptr [r12+rax], 0
lea r12, [r12+rax]
jnz loc_564B5
loc_5655B:
mov byte ptr [r14], 0
sub r14, rbx
mov rax, r14
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long my_caseup_str_utf8mb3(long long a1, _BYTE *a2)
{
unsigned long long v2; // rax
_BYTE *v3; // r14
long long v4; // r13
_BYTE *v5; // r12
unsigned int v6; // eax
unsigned long long v7; // rcx
long long v8; // rdx
long long v9; // rdx
bool v10; // zf
unsigned long long v12; // [rsp+0h] [rbp-30h] BYREF
v12 = v2;
v3 = a2;
if ( *a2 )
{
v4 = *(_QWORD *)(a1 + 120);
v5 = a2;
v3 = a2;
do
{
v6 = my_utf8mb3_uni_no_range(&v12, v5);
if ( !v6 )
break;
v7 = v12;
v8 = *(_QWORD *)(*(_QWORD *)(v4 + 8) + 8LL * BYTE1(v12));
if ( v8 )
{
v7 = *(unsigned int *)(v8 + 12LL * (unsigned __int8)v12);
v12 = v7;
}
v9 = 1LL;
if ( v7 >= 0x80 )
{
v9 = 2LL;
if ( v7 >= 0x800 )
{
if ( v7 > 0xFFFF )
break;
v3[2] = v7 & 0x3F | 0x80;
v7 = (v7 >> 6) | 0x800;
v9 = 3LL;
}
v3[1] = v7 & 0x3F | 0x80;
v7 = (v7 >> 6) | 0xC0;
}
*v3 = v7;
v3 += v9;
v10 = v5[v6] == 0;
v5 += v6;
}
while ( !v10 );
}
*v3 = 0;
return v3 - a2;
}
|
my_caseup_str_utf8mb3:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RSI
CMP byte ptr [RSI],0x0
MOV R14,RSI
JZ 0x0015655b
MOV R13,qword ptr [RDI + 0x78]
LEA R15,[RBP + -0x30]
MOV R12,RBX
MOV R14,RBX
LAB_001564b5:
MOV RDI,R15
MOV RSI,R12
CALL 0x00156e34
TEST EAX,EAX
JZ 0x0015655b
MOV RDX,qword ptr [R13 + 0x8]
MOV RCX,qword ptr [RBP + -0x30]
MOVZX ESI,CH
MOV RDX,qword ptr [RDX + RSI*0x8]
TEST RDX,RDX
JZ 0x001564ea
MOVZX ECX,CL
LEA RCX,[RCX + RCX*0x2]
MOV ECX,dword ptr [RDX + RCX*0x4]
MOV qword ptr [RBP + -0x30],RCX
LAB_001564ea:
MOV EDX,0x1
CMP RCX,0x80
JC 0x00156544
MOV EDX,0x2
CMP RCX,0x800
JC 0x0015652b
CMP RCX,0xffff
JA 0x0015655b
MOV EDX,ECX
AND DL,0x3f
OR DL,0x80
MOV byte ptr [R14 + 0x2],DL
SHR RCX,0x6
OR RCX,0x800
MOV EDX,0x3
LAB_0015652b:
MOV ESI,ECX
AND SIL,0x3f
OR SIL,0x80
MOV byte ptr [R14 + 0x1],SIL
SHR RCX,0x6
OR RCX,0xc0
LAB_00156544:
MOV byte ptr [R14],CL
MOV EAX,EAX
ADD R14,RDX
CMP byte ptr [R12 + RAX*0x1],0x0
LEA R12,[R12 + RAX*0x1]
JNZ 0x001564b5
LAB_0015655b:
MOV byte ptr [R14],0x0
SUB R14,RBX
MOV RAX,R14
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
long my_caseup_str_utf8mb3(long param_1,char *param_2)
{
char *pcVar1;
long lVar2;
uint uVar3;
ulong in_RAX;
ulong uVar4;
long lVar5;
char *pcVar6;
char *pcVar7;
ulong local_38;
pcVar7 = param_2;
if (*param_2 != '\0') {
lVar2 = *(long *)(param_1 + 0x78);
pcVar6 = param_2;
local_38 = in_RAX;
do {
uVar3 = my_utf8mb3_uni_no_range(&local_38,pcVar6);
if (uVar3 == 0) break;
lVar5 = *(long *)(*(long *)(lVar2 + 8) + (local_38 >> 8 & 0xff) * 8);
if (lVar5 != 0) {
local_38 = (ulong)*(uint *)(lVar5 + (local_38 & 0xff) * 0xc);
}
lVar5 = 1;
uVar4 = local_38;
if (0x7f < local_38) {
lVar5 = 2;
if (0x7ff < local_38) {
if (0xffff < local_38) break;
pcVar7[2] = (byte)local_38 & 0x3f | 0x80;
uVar4 = local_38 >> 6 | 0x800;
lVar5 = 3;
}
pcVar7[1] = (byte)uVar4 & 0x3f | 0x80;
uVar4 = uVar4 >> 6 | 0xc0;
}
*pcVar7 = (char)uVar4;
pcVar7 = pcVar7 + lVar5;
pcVar1 = pcVar6 + uVar3;
pcVar6 = pcVar6 + uVar3;
} while (*pcVar1 != '\0');
}
*pcVar7 = '\0';
return (long)pcVar7 - (long)param_2;
}
|
|
19,976
|
add_compiled_extra_collation
|
eloqsql/mysys/charset.c
|
void add_compiled_extra_collation(struct charset_info_st *cs)
{
DBUG_ASSERT(cs->number < array_elements(all_charsets));
all_charsets[cs->number]= cs;
cs->state|= MY_CS_AVAILABLE;
if ((my_hash_insert(&charset_name_hash, (uchar*) cs)))
{
CHARSET_INFO *org= (CHARSET_INFO*) my_hash_search(&charset_name_hash,
(uchar*) cs->cs_name.str,
cs->cs_name.length);
cs->cs_name= org->cs_name;
}
}
|
O0
|
c
|
add_compiled_extra_collation:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
jmp 0xdcb7e
movq -0x8(%rbp), %rdx
movq -0x8(%rbp), %rax
movl (%rax), %eax
movl %eax, %ecx
leaq 0xb9edcf(%rip), %rax # 0xc7b960
movq %rdx, (%rax,%rcx,8)
movq -0x8(%rbp), %rax
movl 0xc(%rax), %ecx
orl $0x200, %ecx # imm = 0x200
movl %ecx, 0xc(%rax)
movq -0x8(%rbp), %rsi
leaq 0xba2db0(%rip), %rdi # 0xc7f960
callq 0xdf810
cmpb $0x0, %al
je 0xdcbf1
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rsi
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdx
leaq 0xba2d90(%rip), %rdi # 0xc7f960
callq 0xdf420
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq -0x10(%rbp), %rcx
movq 0x10(%rcx), %rdx
movq %rdx, 0x10(%rax)
movq 0x18(%rcx), %rcx
movq %rcx, 0x18(%rax)
addq $0x10, %rsp
popq %rbp
retq
nopw (%rax,%rax)
|
add_compiled_extra_collation:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
jmp short $+2
loc_DCB7E:
mov rdx, [rbp+var_8]
mov rax, [rbp+var_8]
mov eax, [rax]
mov ecx, eax
lea rax, all_charsets
mov [rax+rcx*8], rdx
mov rax, [rbp+var_8]
mov ecx, [rax+0Ch]
or ecx, 200h
mov [rax+0Ch], ecx
mov rsi, [rbp+var_8]
lea rdi, charset_name_hash
call my_hash_insert
cmp al, 0
jz short loc_DCBF1
mov rax, [rbp+var_8]
mov rsi, [rax+10h]
mov rax, [rbp+var_8]
mov rdx, [rax+18h]
lea rdi, charset_name_hash
call my_hash_search
mov [rbp+var_10], rax
mov rax, [rbp+var_8]
mov rcx, [rbp+var_10]
mov rdx, [rcx+10h]
mov [rax+10h], rdx
mov rcx, [rcx+18h]
mov [rax+18h], rcx
loc_DCBF1:
add rsp, 10h
pop rbp
retn
|
long long add_compiled_extra_collation(unsigned int *a1)
{
long long result; // rax
long long v2; // [rsp+0h] [rbp-10h]
all_charsets[*a1] = a1;
a1[3] |= 0x200u;
result = my_hash_insert(&charset_name_hash, a1);
if ( (_BYTE)result )
{
v2 = my_hash_search(&charset_name_hash, *((_QWORD *)a1 + 2), *((_QWORD *)a1 + 3));
result = (long long)a1;
*((_QWORD *)a1 + 2) = *(_QWORD *)(v2 + 16);
*((_QWORD *)a1 + 3) = *(_QWORD *)(v2 + 24);
}
return result;
}
|
add_compiled_extra_collation:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
JMP 0x001dcb7e
LAB_001dcb7e:
MOV RDX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX]
MOV ECX,EAX
LEA RAX,[0xd7b960]
MOV qword ptr [RAX + RCX*0x8],RDX
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0xc]
OR ECX,0x200
MOV dword ptr [RAX + 0xc],ECX
MOV RSI,qword ptr [RBP + -0x8]
LEA RDI,[0xd7f960]
CALL 0x001df810
CMP AL,0x0
JZ 0x001dcbf1
MOV RAX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RAX + 0x18]
LEA RDI,[0xd7f960]
CALL 0x001df420
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RCX + 0x10]
MOV qword ptr [RAX + 0x10],RDX
MOV RCX,qword ptr [RCX + 0x18]
MOV qword ptr [RAX + 0x18],RCX
LAB_001dcbf1:
ADD RSP,0x10
POP RBP
RET
|
void add_compiled_extra_collation(uint *param_1)
{
char cVar1;
long lVar2;
(&all_charsets)[*param_1] = param_1;
param_1[3] = param_1[3] | 0x200;
cVar1 = my_hash_insert(charset_name_hash,param_1);
if (cVar1 != '\0') {
lVar2 = my_hash_search(charset_name_hash,*(int8 *)(param_1 + 4),
*(int8 *)(param_1 + 6));
*(int8 *)(param_1 + 4) = *(int8 *)(lVar2 + 0x10);
*(int8 *)(param_1 + 6) = *(int8 *)(lVar2 + 0x18);
}
return;
}
|
|
19,977
|
blst_sk_mul_n_check
|
corpus-core[P]colibri-stateless/build_O2/_deps/blst-src/src/exports.c
|
int blst_sk_mul_n_check(pow256 ret, const pow256 a, const pow256 b)
{
vec256 t[2];
const union {
long one;
char little;
} is_endian = { 1 };
bool_t is_zero;
if (((size_t)a|(size_t)b)%sizeof(limb_t) != 0 || !is_endian.little) {
limbs_from_le_bytes(t[0], a, sizeof(pow256));
limbs_from_le_bytes(t[1], b, sizeof(pow256));
a = (const byte *)t[0];
b = (const byte *)t[1];
}
mul_mont_sparse_256(t[0], BLS12_381_rRR, (const limb_t *)a, BLS12_381_r, r0);
mul_mont_sparse_256(t[0], t[0], (const limb_t *)b, BLS12_381_r, r0);
le_bytes_from_limbs(ret, t[0], sizeof(pow256));
is_zero = vec_is_zero(t[0], sizeof(vec256));
vec_zero(t, sizeof(t));
return (int)(is_zero^1);
}
|
O2
|
c
|
blst_sk_mul_n_check:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdx, %r14
movq %rsi, %rdx
movq %rdi, %rbx
movl %r14d, %eax
orl %edx, %eax
testb $0x7, %al
je 0x2125d
leaq -0x70(%rbp), %r15
pushq $0x20
popq %r12
movq %r15, %rdi
movq %rdx, %rsi
movq %r12, %rdx
callq 0x2109c
leaq -0x50(%rbp), %r13
movq %r13, %rdi
movq %r14, %rsi
movq %r12, %rdx
callq 0x2109c
movq %r13, %r14
movq %r15, %rdx
leaq 0x19b5c(%rip), %rsi # 0x3adc0
leaq 0x19645(%rip), %r12 # 0x3a8b0
leaq -0x70(%rbp), %r15
movabsq $-0x100000001, %r13 # imm = 0xFFFFFFFEFFFFFFFF
movq %r15, %rdi
movq %r12, %rcx
movq %r13, %r8
callq 0x30c40
movq %r15, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %r12, %rcx
movq %r13, %r8
callq 0x30c40
pushq $0x20
popq %r14
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x21134
movq %r15, %rdi
movq %r14, %rsi
callq 0x17a59
movq %rax, %rbx
pushq $0x40
popq %rsi
movq %r15, %rdi
callq 0x1780a
xorl $0x1, %ebx
movl %ebx, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
blst_sk_mul_n_check:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov r14, rdx
mov rdx, rsi
mov rbx, rdi
mov eax, r14d
or eax, edx
test al, 7
jz short loc_2125D
lea r15, [rbp+var_70]
push 20h ; ' '
pop r12
mov rdi, r15
mov rsi, rdx
mov rdx, r12
call limbs_from_le_bytes
lea r13, [rbp+var_50]
mov rdi, r13
mov rsi, r14
mov rdx, r12
call limbs_from_le_bytes
mov r14, r13
mov rdx, r15
loc_2125D:
lea rsi, BLS12_381_rRR
lea r12, BLS12_381_r
lea r15, [rbp+var_70]
mov r13, 0FFFFFFFEFFFFFFFFh
mov rdi, r15
mov rcx, r12
mov r8, r13
call mul_mont_sparse_256
mov rdi, r15
mov rsi, r15
mov rdx, r14
mov rcx, r12
mov r8, r13
call mul_mont_sparse_256
push 20h ; ' '
pop r14
mov rdi, rbx
mov rsi, r15
mov rdx, r14
call le_bytes_from_limbs
mov rdi, r15
mov rsi, r14
call vec_is_zero
mov rbx, rax
push 40h ; '@'
pop rsi
mov rdi, r15
call vec_zero
xor ebx, 1
mov eax, ebx
add rsp, 48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long blst_sk_mul_n_check(long long a1, long long a2, _BYTE *a3)
{
_BYTE *v4; // rdx
int is_zero; // ebx
_BYTE v7[32]; // [rsp+0h] [rbp-70h] BYREF
_BYTE v8[80]; // [rsp+20h] [rbp-50h] BYREF
v4 = (_BYTE *)a2;
if ( (((unsigned __int8)a2 | (unsigned __int8)a3) & 7) != 0 )
{
limbs_from_le_bytes((long long)v7, a2, 32LL);
limbs_from_le_bytes((long long)v8, (long long)a3, 32LL);
a3 = v8;
v4 = v7;
}
mul_mont_sparse_256(v7, &BLS12_381_rRR, v4, &BLS12_381_r, 0xFFFFFFFEFFFFFFFFLL);
mul_mont_sparse_256(v7, v7, a3, &BLS12_381_r, 0xFFFFFFFEFFFFFFFFLL);
le_bytes_from_limbs(a1, (long long)v7, 0x20uLL);
is_zero = vec_is_zero((long long)v7, 0x20uLL);
vec_zero((long long)v7, 0x40uLL);
return is_zero ^ 1u;
}
|
blst_sk_mul_n_check:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV R14,RDX
MOV RDX,RSI
MOV RBX,RDI
MOV EAX,R14D
OR EAX,EDX
TEST AL,0x7
JZ 0x0012125d
LEA R15,[RBP + -0x70]
PUSH 0x20
POP R12
MOV RDI,R15
MOV RSI,RDX
MOV RDX,R12
CALL 0x0012109c
LEA R13,[RBP + -0x50]
MOV RDI,R13
MOV RSI,R14
MOV RDX,R12
CALL 0x0012109c
MOV R14,R13
MOV RDX,R15
LAB_0012125d:
LEA RSI,[0x13adc0]
LEA R12,[0x13a8b0]
LEA R15,[RBP + -0x70]
MOV R13,-0x100000001
MOV RDI,R15
MOV RCX,R12
MOV R8,R13
CALL 0x00130c40
MOV RDI,R15
MOV RSI,R15
MOV RDX,R14
MOV RCX,R12
MOV R8,R13
CALL 0x00130c40
PUSH 0x20
POP R14
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R14
CALL 0x00121134
MOV RDI,R15
MOV RSI,R14
CALL 0x00117a59
MOV RBX,RAX
PUSH 0x40
POP RSI
MOV RDI,R15
CALL 0x0011780a
XOR EBX,0x1
MOV EAX,EBX
ADD RSP,0x48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
uint blst_sk_mul_n_check(int8 param_1,int1 *param_2,int1 *param_3)
{
uint uVar1;
int1 *puVar2;
int1 *puVar3;
int1 local_78 [32];
int1 local_58 [40];
puVar2 = param_2;
puVar3 = param_3;
if ((((uint)param_3 | (uint)param_2) & 7) != 0) {
puVar2 = local_78;
limbs_from_le_bytes(puVar2,param_2,0x20);
puVar3 = local_58;
limbs_from_le_bytes(puVar3,param_3,0x20);
}
mul_mont_sparse_256(local_78,BLS12_381_rRR,puVar2,BLS12_381_r,0xfffffffeffffffff);
mul_mont_sparse_256(local_78,local_78,puVar3,BLS12_381_r,0xfffffffeffffffff);
le_bytes_from_limbs(param_1,local_78,0x20);
uVar1 = vec_is_zero(local_78,0x20);
vec_zero(local_78,0x40);
return uVar1 ^ 1;
}
|
|
19,978
|
miller_loop_n
|
corpus-core[P]colibri-stateless/build_O0/_deps/blst-src/src/pairing.c
|
static void miller_loop_n(vec384fp12 ret, const POINTonE2_affine Q[],
const POINTonE1_affine P[], size_t n)
{
#if !defined(__STDC_VERSION__) || __STDC_VERSION__<199901 \
|| defined(__STDC_NO_VLA__)
POINTonE2 *T = alloca(n*sizeof(POINTonE2));
POINTonE1_affine *Px2 = alloca(n*sizeof(POINTonE1_affine));
#else
POINTonE2 T[n];
POINTonE1_affine Px2[n];
#endif
size_t i;
if ((n == 1) && (vec_is_zero(&Q[0], sizeof(Q[0])) |
vec_is_zero(&P[0], sizeof(P[0]))) ) {
/*
* Special case of infinite aggregated signature, pair the additive
* group's identity with the multiplicative group's identity.
*/
vec_copy(ret, BLS12_381_Rx.p12, sizeof(vec384fp12));
return;
}
for (i = 0; i < n; i++) {
/* Move common expression from line evaluation to line_by_Px2. */
add_fp(Px2[i].X, P[i].X, P[i].X);
neg_fp(Px2[i].X, Px2[i].X);
add_fp(Px2[i].Y, P[i].Y, P[i].Y);
vec_copy(T[i].X, Q[i].X, 2*sizeof(T[i].X));
vec_copy(T[i].Z, BLS12_381_Rx.p2, sizeof(T[i].Z));
}
/* first step is ret = 1^2*line, which is replaced with ret = line */
start_dbl_n(ret, T, Px2, n); /* 0x2 */
add_n_dbl_n(ret, T, Q, Px2, n, 2); /* ..0xc */
add_n_dbl_n(ret, T, Q, Px2, n, 3); /* ..0x68 */
add_n_dbl_n(ret, T, Q, Px2, n, 9); /* ..0xd200 */
add_n_dbl_n(ret, T, Q, Px2, n, 32); /* ..0xd20100000000 */
add_n_dbl_n(ret, T, Q, Px2, n, 16); /* ..0xd201000000010000 */
conjugate_fp12(ret); /* account for z being negative */
}
|
O0
|
c
|
miller_loop_n:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rsp, %rcx
movq %rcx, -0x28(%rbp)
movq %rax, %rcx
shlq $0x5, %rcx
leaq (%rcx,%rcx,8), %rdx
movq %rsp, %rcx
subq %rdx, %rcx
movq %rcx, -0x58(%rbp)
movq %rcx, %rsp
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rax
movq %rax, %rcx
shlq $0x5, %rcx
leaq (%rcx,%rcx,2), %rdx
movq %rsp, %rcx
subq %rdx, %rcx
movq %rcx, -0x50(%rbp)
movq %rcx, %rsp
movq %rax, -0x38(%rbp)
cmpq $0x1, -0x20(%rbp)
jne 0xaf867
movq -0x10(%rbp), %rdi
movl $0xc0, %esi
callq 0xa8cd0
movq %rax, -0x60(%rbp)
movq -0x18(%rbp), %rdi
movl $0x60, %esi
callq 0xa8cd0
movq %rax, %rcx
movq -0x60(%rbp), %rax
orq %rcx, %rax
cmpq $0x0, %rax
je 0xaf867
movq -0x8(%rbp), %rdi
leaq 0x38c57(%rip), %rsi # 0xe84a8
movl $0x240, %edx # imm = 0x240
callq 0xa8ad0
movl $0x1, -0x44(%rbp)
jmp 0xafa1c
movq $0x0, -0x40(%rbp)
movq -0x40(%rbp), %rax
cmpq -0x20(%rbp), %rax
jae 0xaf95c
movq -0x50(%rbp), %rdi
imulq $0x60, -0x40(%rbp), %rax
addq %rax, %rdi
movq -0x18(%rbp), %rsi
imulq $0x60, -0x40(%rbp), %rax
addq %rax, %rsi
movq -0x18(%rbp), %rdx
imulq $0x60, -0x40(%rbp), %rax
addq %rax, %rdx
callq 0xafde0
movq -0x50(%rbp), %rsi
imulq $0x60, -0x40(%rbp), %rax
movq %rsi, %rdi
addq %rax, %rdi
imulq $0x60, -0x40(%rbp), %rax
addq %rax, %rsi
movl $0x1, %edx
callq 0xafe20
movq -0x50(%rbp), %rdi
imulq $0x60, -0x40(%rbp), %rax
addq %rax, %rdi
addq $0x30, %rdi
movq -0x18(%rbp), %rsi
imulq $0x60, -0x40(%rbp), %rax
addq %rax, %rsi
addq $0x30, %rsi
movq -0x18(%rbp), %rdx
imulq $0x60, -0x40(%rbp), %rax
addq %rax, %rdx
addq $0x30, %rdx
callq 0xafde0
movq -0x58(%rbp), %rdi
imulq $0x120, -0x40(%rbp), %rax # imm = 0x120
addq %rax, %rdi
movq -0x10(%rbp), %rsi
imulq $0xc0, -0x40(%rbp), %rax
addq %rax, %rsi
movl $0xc0, %edx
callq 0xa8ad0
movq -0x58(%rbp), %rdi
imulq $0x120, -0x40(%rbp), %rax # imm = 0x120
addq %rax, %rdi
addq $0xc0, %rdi
leaq 0x38b67(%rip), %rsi # 0xe84a8
movl $0x60, %edx
callq 0xa8ad0
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0xaf86f
movq -0x50(%rbp), %rdx
movq -0x58(%rbp), %rsi
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rcx
callq 0xafe60
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rcx
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x20(%rbp), %r8
movl $0x2, %r9d
callq 0xaff70
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rcx
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x20(%rbp), %r8
movl $0x3, %r9d
callq 0xaff70
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rcx
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x20(%rbp), %r8
movl $0x9, %r9d
callq 0xaff70
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rcx
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x20(%rbp), %r8
movl $0x20, %r9d
callq 0xaff70
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rcx
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x20(%rbp), %r8
movl $0x10, %r9d
callq 0xaff70
movq -0x8(%rbp), %rdi
callq 0xaf240
movl $0x0, -0x44(%rbp)
movq -0x28(%rbp), %rax
movq %rax, %rsp
movq %rbp, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
miller_loop_n:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rax, [rbp+var_20]
mov rcx, rsp
mov [rbp+var_28], rcx
mov rcx, rax
shl rcx, 5
lea rdx, [rcx+rcx*8]
mov rcx, rsp
sub rcx, rdx
mov [rbp+var_58], rcx
mov rsp, rcx
mov [rbp+var_30], rax
mov rax, [rbp+var_20]
mov rcx, rax
shl rcx, 5
lea rdx, [rcx+rcx*2]
mov rcx, rsp
sub rcx, rdx
mov [rbp+var_50], rcx
mov rsp, rcx
mov [rbp+var_38], rax
cmp [rbp+var_20], 1
jnz short loc_AF867
mov rdi, [rbp+var_10]
mov esi, 0C0h
call vec_is_zero
mov [rbp+var_60], rax
mov rdi, [rbp+var_18]
mov esi, 60h ; '`'
call vec_is_zero
mov rcx, rax
mov rax, [rbp+var_60]
or rax, rcx
cmp rax, 0
jz short loc_AF867
mov rdi, [rbp+var_8]
lea rsi, BLS12_381_Rx
mov edx, 240h
call vec_copy
mov [rbp+var_44], 1
jmp loc_AFA1C
loc_AF867:
mov [rbp+var_40], 0
loc_AF86F:
mov rax, [rbp+var_40]
cmp rax, [rbp+var_20]
jnb loc_AF95C
mov rdi, [rbp+var_50]
imul rax, [rbp+var_40], 60h ; '`'
add rdi, rax
mov rsi, [rbp+var_18]
imul rax, [rbp+var_40], 60h ; '`'
add rsi, rax
mov rdx, [rbp+var_18]
imul rax, [rbp+var_40], 60h ; '`'
add rdx, rax
call add_fp
mov rsi, [rbp+var_50]
imul rax, [rbp+var_40], 60h ; '`'
mov rdi, rsi
add rdi, rax
imul rax, [rbp+var_40], 60h ; '`'
add rsi, rax
mov edx, 1
call cneg_fp
mov rdi, [rbp+var_50]
imul rax, [rbp+var_40], 60h ; '`'
add rdi, rax
add rdi, 30h ; '0'
mov rsi, [rbp+var_18]
imul rax, [rbp+var_40], 60h ; '`'
add rsi, rax
add rsi, 30h ; '0'
mov rdx, [rbp+var_18]
imul rax, [rbp+var_40], 60h ; '`'
add rdx, rax
add rdx, 30h ; '0'
call add_fp
mov rdi, [rbp+var_58]
imul rax, [rbp+var_40], 120h
add rdi, rax
mov rsi, [rbp+var_10]
imul rax, [rbp+var_40], 0C0h
add rsi, rax
mov edx, 0C0h
call vec_copy
mov rdi, [rbp+var_58]
imul rax, [rbp+var_40], 120h
add rdi, rax
add rdi, 0C0h
lea rsi, BLS12_381_Rx
mov edx, 60h ; '`'
call vec_copy
mov rax, [rbp+var_40]
add rax, 1
mov [rbp+var_40], rax
jmp loc_AF86F
loc_AF95C:
mov rdx, [rbp+var_50]
mov rsi, [rbp+var_58]
mov rdi, [rbp+var_8]
mov rcx, [rbp+var_20]
call start_dbl_n
mov rsi, [rbp+var_58]
mov rcx, [rbp+var_50]
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov r8, [rbp+var_20]
mov r9d, 2
call add_n_dbl_n
mov rsi, [rbp+var_58]
mov rcx, [rbp+var_50]
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov r8, [rbp+var_20]
mov r9d, 3
call add_n_dbl_n
mov rsi, [rbp+var_58]
mov rcx, [rbp+var_50]
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov r8, [rbp+var_20]
mov r9d, 9
call add_n_dbl_n
mov rsi, [rbp+var_58]
mov rcx, [rbp+var_50]
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov r8, [rbp+var_20]
mov r9d, 20h ; ' '
call add_n_dbl_n
mov rsi, [rbp+var_58]
mov rcx, [rbp+var_50]
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov r8, [rbp+var_20]
mov r9d, 10h
call add_n_dbl_n
mov rdi, [rbp+var_8]
call conjugate_fp12
mov [rbp+var_44], 0
loc_AFA1C:
mov rax, [rbp+var_28]
mov rsp, rax
mov rsp, rbp
pop rbp
retn
|
unsigned long long * miller_loop_n(long long a1, long long a2, long long a3, unsigned long long a4)
{
unsigned long long v4; // rax
unsigned long long is_zero; // [rsp+0h] [rbp-60h] BYREF
unsigned long long *v7; // [rsp+8h] [rbp-58h]
unsigned long long *v8; // [rsp+10h] [rbp-50h]
int v9; // [rsp+1Ch] [rbp-44h]
unsigned long long i; // [rsp+20h] [rbp-40h]
unsigned long long v11; // [rsp+28h] [rbp-38h]
unsigned long long v12; // [rsp+30h] [rbp-30h]
unsigned long long *v13; // [rsp+38h] [rbp-28h]
unsigned long long v14; // [rsp+40h] [rbp-20h]
long long v15; // [rsp+48h] [rbp-18h]
long long v16; // [rsp+50h] [rbp-10h]
long long v17; // [rsp+58h] [rbp-8h]
v17 = a1;
v16 = a2;
v15 = a3;
v14 = a4;
v13 = &is_zero;
v7 = &is_zero - 36 * a4;
v12 = a4;
v8 = &is_zero - 12 * a4;
v11 = a4;
if ( a4 == 1 && (is_zero = vec_is_zero(v16, 0xC0uLL), v4 = vec_is_zero(v15, 0x60uLL), v4 | is_zero) )
{
vec_copy(v17, (long long)&BLS12_381_Rx, 0x240uLL);
v9 = 1;
}
else
{
for ( i = 0LL; i < v14; ++i )
{
add_fp(&v8[12 * i], 96 * i + v15, 96 * i + v15);
cneg_fp(&v8[12 * i], &v8[12 * i], 1LL);
add_fp(&v8[12 * i + 6], 96 * i + v15 + 48, 96 * i + v15 + 48);
vec_copy((long long)&v7[36 * i], 192 * i + v16, 0xC0uLL);
vec_copy((long long)&v7[36 * i + 24], (long long)&BLS12_381_Rx, 0x60uLL);
}
start_dbl_n(v17, v7, v8, v14);
add_n_dbl_n(v17, v7, v16, v8, v14, 2LL);
add_n_dbl_n(v17, v7, v16, v8, v14, 3LL);
add_n_dbl_n(v17, v7, v16, v8, v14, 9LL);
add_n_dbl_n(v17, v7, v16, v8, v14, 32LL);
add_n_dbl_n(v17, v7, v16, v8, v14, 16LL);
conjugate_fp12(v17);
v9 = 0;
}
return v13;
}
|
miller_loop_n:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,RSP
MOV qword ptr [RBP + -0x28],RCX
MOV RCX,RAX
SHL RCX,0x5
LEA RDX,[RCX + RCX*0x8]
MOV RCX,RSP
SUB RCX,RDX
MOV qword ptr [RBP + -0x58],RCX
MOV RSP,RCX
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,RAX
SHL RCX,0x5
LEA RDX,[RCX + RCX*0x2]
MOV RCX,RSP
SUB RCX,RDX
MOV qword ptr [RBP + -0x50],RCX
MOV RSP,RCX
MOV qword ptr [RBP + -0x38],RAX
CMP qword ptr [RBP + -0x20],0x1
JNZ 0x001af867
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,0xc0
CALL 0x001a8cd0
MOV qword ptr [RBP + -0x60],RAX
MOV RDI,qword ptr [RBP + -0x18]
MOV ESI,0x60
CALL 0x001a8cd0
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x60]
OR RAX,RCX
CMP RAX,0x0
JZ 0x001af867
MOV RDI,qword ptr [RBP + -0x8]
LEA RSI,[0x1e84a8]
MOV EDX,0x240
CALL 0x001a8ad0
MOV dword ptr [RBP + -0x44],0x1
JMP 0x001afa1c
LAB_001af867:
MOV qword ptr [RBP + -0x40],0x0
LAB_001af86f:
MOV RAX,qword ptr [RBP + -0x40]
CMP RAX,qword ptr [RBP + -0x20]
JNC 0x001af95c
MOV RDI,qword ptr [RBP + -0x50]
IMUL RAX,qword ptr [RBP + -0x40],0x60
ADD RDI,RAX
MOV RSI,qword ptr [RBP + -0x18]
IMUL RAX,qword ptr [RBP + -0x40],0x60
ADD RSI,RAX
MOV RDX,qword ptr [RBP + -0x18]
IMUL RAX,qword ptr [RBP + -0x40],0x60
ADD RDX,RAX
CALL 0x001afde0
MOV RSI,qword ptr [RBP + -0x50]
IMUL RAX,qword ptr [RBP + -0x40],0x60
MOV RDI,RSI
ADD RDI,RAX
IMUL RAX,qword ptr [RBP + -0x40],0x60
ADD RSI,RAX
MOV EDX,0x1
CALL 0x001afe20
MOV RDI,qword ptr [RBP + -0x50]
IMUL RAX,qword ptr [RBP + -0x40],0x60
ADD RDI,RAX
ADD RDI,0x30
MOV RSI,qword ptr [RBP + -0x18]
IMUL RAX,qword ptr [RBP + -0x40],0x60
ADD RSI,RAX
ADD RSI,0x30
MOV RDX,qword ptr [RBP + -0x18]
IMUL RAX,qword ptr [RBP + -0x40],0x60
ADD RDX,RAX
ADD RDX,0x30
CALL 0x001afde0
MOV RDI,qword ptr [RBP + -0x58]
IMUL RAX,qword ptr [RBP + -0x40],0x120
ADD RDI,RAX
MOV RSI,qword ptr [RBP + -0x10]
IMUL RAX,qword ptr [RBP + -0x40],0xc0
ADD RSI,RAX
MOV EDX,0xc0
CALL 0x001a8ad0
MOV RDI,qword ptr [RBP + -0x58]
IMUL RAX,qword ptr [RBP + -0x40],0x120
ADD RDI,RAX
ADD RDI,0xc0
LEA RSI,[0x1e84a8]
MOV EDX,0x60
CALL 0x001a8ad0
MOV RAX,qword ptr [RBP + -0x40]
ADD RAX,0x1
MOV qword ptr [RBP + -0x40],RAX
JMP 0x001af86f
LAB_001af95c:
MOV RDX,qword ptr [RBP + -0x50]
MOV RSI,qword ptr [RBP + -0x58]
MOV RDI,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RBP + -0x20]
CALL 0x001afe60
MOV RSI,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV R8,qword ptr [RBP + -0x20]
MOV R9D,0x2
CALL 0x001aff70
MOV RSI,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV R8,qword ptr [RBP + -0x20]
MOV R9D,0x3
CALL 0x001aff70
MOV RSI,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV R8,qword ptr [RBP + -0x20]
MOV R9D,0x9
CALL 0x001aff70
MOV RSI,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV R8,qword ptr [RBP + -0x20]
MOV R9D,0x20
CALL 0x001aff70
MOV RSI,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x50]
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV R8,qword ptr [RBP + -0x20]
MOV R9D,0x10
CALL 0x001aff70
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x001af240
MOV dword ptr [RBP + -0x44],0x0
LAB_001afa1c:
MOV RAX,qword ptr [RBP + -0x28]
MOV RSP,RAX
MOV RSP,RBP
POP RBP
RET
|
/* WARNING: Type propagation algorithm not settling */
int8 * miller_loop_n(int8 param_1,long param_2,long param_3,ulong param_4)
{
ulong uVar1;
int8 uVar2;
int8 *puVar3;
long lVar4;
long lVar5;
long lVar6;
long lVar7;
int8 uStack_70;
long local_68;
long local_60;
long local_58;
ulong local_48;
ulong local_40;
ulong local_38;
int8 *local_30;
ulong local_28;
long local_20;
long local_18;
int8 local_10;
local_30 = &local_68;
local_60 = (long)&local_68 + param_4 * -0x120;
lVar5 = local_60 + param_4 * -0x60;
local_58 = lVar5;
local_40 = param_4;
local_38 = param_4;
puVar3 = &local_68;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
if (param_4 == 1) {
*(int8 *)(lVar5 + -8) = 0x1af824;
local_68 = vec_is_zero(param_2,0xc0);
lVar4 = local_20;
*(int8 *)(lVar5 + -8) = 0x1af836;
lVar4 = vec_is_zero(lVar4,0x60);
uVar2 = local_10;
puVar3 = local_30;
if (local_68 != 0 || lVar4 != 0) {
*(int8 *)(lVar5 + -8) = 0x1af85b;
vec_copy(uVar2,BLS12_381_Rx,0x240);
return local_30;
}
}
local_30 = puVar3;
for (local_48 = 0; uVar2 = local_10, uVar1 = local_28, lVar6 = local_58, lVar4 = local_60,
local_48 < local_28; local_48 = local_48 + 1) {
lVar7 = local_58 + local_48 * 0x60;
lVar6 = local_20 + local_48 * 0x60;
lVar4 = local_20 + local_48 * 0x60;
*(int8 *)(lVar5 + -8) = 0x1af8a6;
add_fp(lVar7,lVar6,lVar4);
lVar6 = local_58 + local_48 * 0x60;
lVar4 = local_58 + local_48 * 0x60;
*(int8 *)(lVar5 + -8) = 0x1af8c7;
cneg_fp(lVar6,lVar4,1);
lVar7 = local_58 + (local_48 * 0xc + 6) * 8;
lVar6 = local_20 + local_48 * 0x60;
lVar4 = local_20 + local_48 * 0x60;
*(int8 *)(lVar5 + -8) = 0x1af8fc;
add_fp(lVar7,lVar6 + 0x30,lVar4 + 0x30);
lVar6 = local_60 + local_48 * 0x120;
lVar4 = local_18 + local_48 * 0xc0;
*(int8 *)(lVar5 + -8) = 0x1af924;
vec_copy(lVar6,lVar4,0xc0);
lVar4 = local_60 + (local_48 * 0x24 + 0x18) * 8;
*(int8 *)(lVar5 + -8) = 0x1af94b;
vec_copy(lVar4,BLS12_381_Rx,0x60);
}
*(int8 *)(lVar5 + -8) = 0x1af971;
start_dbl_n(uVar2,lVar4,lVar6,uVar1);
uVar2 = local_10;
lVar7 = local_18;
uVar1 = local_28;
lVar6 = local_58;
lVar4 = local_60;
*(int8 *)(lVar5 + -8) = 0x1af990;
add_n_dbl_n(uVar2,lVar4,lVar7,lVar6,uVar1,2);
uVar2 = local_10;
lVar7 = local_18;
uVar1 = local_28;
lVar6 = local_58;
lVar4 = local_60;
*(int8 *)(lVar5 + -8) = 0x1af9af;
add_n_dbl_n(uVar2,lVar4,lVar7,lVar6,uVar1,3);
uVar2 = local_10;
lVar7 = local_18;
uVar1 = local_28;
lVar6 = local_58;
lVar4 = local_60;
*(int8 *)(lVar5 + -8) = 0x1af9ce;
add_n_dbl_n(uVar2,lVar4,lVar7,lVar6,uVar1,9);
uVar2 = local_10;
lVar7 = local_18;
uVar1 = local_28;
lVar6 = local_58;
lVar4 = local_60;
*(int8 *)(lVar5 + -8) = 0x1af9ed;
add_n_dbl_n(uVar2,lVar4,lVar7,lVar6,uVar1,0x20);
uVar2 = local_10;
lVar7 = local_18;
uVar1 = local_28;
lVar6 = local_58;
lVar4 = local_60;
*(int8 *)(lVar5 + -8) = 0x1afa0c;
add_n_dbl_n(uVar2,lVar4,lVar7,lVar6,uVar1,0x10);
uVar2 = local_10;
*(int8 *)(lVar5 + -8) = 0x1afa15;
conjugate_fp12(uVar2);
return local_30;
}
|
|
19,979
|
minja::IfTemplateToken::~IfTemplateToken()
|
monkey531[P]llama/common/minja.hpp
|
IfTemplateToken(const Location & location, SpaceHandling pre, SpaceHandling post, std::shared_ptr<Expression> && c) : TemplateToken(Type::If, location, pre, post), condition(std::move(c)) {}
|
O1
|
cpp
|
minja::IfTemplateToken::~IfTemplateToken():
pushq %rbx
movq %rdi, %rbx
leaq 0x94cf5(%rip), %rax # 0x12fb30
addq $0x10, %rax
movq %rax, (%rdi)
movq 0x38(%rdi), %rdi
testq %rdi, %rdi
je 0x9ae50
callq 0x6fa60
leaq 0x94491(%rip), %rax # 0x12f2e8
addq $0x10, %rax
movq %rax, (%rbx)
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x9ae6c
callq 0x6fa60
movl $0x40, %esi
movq %rbx, %rdi
popq %rbx
jmp 0x1b8e0
|
_ZN5minja15IfTemplateTokenD0Ev:
push rbx
mov rbx, rdi
lea rax, _ZTVN5minja15IfTemplateTokenE; `vtable for'minja::IfTemplateToken
add rax, 10h
mov [rdi], rax
mov rdi, [rdi+38h]
test rdi, rdi
jz short loc_9AE50
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_9AE50:
lea rax, _ZTVN5minja13TemplateTokenE; `vtable for'minja::TemplateToken
add rax, 10h
mov [rbx], rax
mov rdi, [rbx+18h]
test rdi, rdi
jz short loc_9AE6C
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_9AE6C:
mov esi, 40h ; '@'; unsigned __int64
mov rdi, rbx; void *
pop rbx
jmp __ZdlPvm; operator delete(void *,ulong)
|
void minja::IfTemplateToken::~IfTemplateToken(minja::IfTemplateToken *this)
{
volatile signed __int32 *v2; // rdi
volatile signed __int32 *v3; // rdi
*(_QWORD *)this = &`vtable for'minja::IfTemplateToken + 2;
v2 = (volatile signed __int32 *)*((_QWORD *)this + 7);
if ( v2 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v2);
*(_QWORD *)this = &`vtable for'minja::TemplateToken + 2;
v3 = (volatile signed __int32 *)*((_QWORD *)this + 3);
if ( v3 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v3);
operator delete(this, 0x40uLL);
}
|
~IfTemplateToken:
PUSH RBX
MOV RBX,RDI
LEA RAX,[0x22fb30]
ADD RAX,0x10
MOV qword ptr [RDI],RAX
MOV RDI,qword ptr [RDI + 0x38]
TEST RDI,RDI
JZ 0x0019ae50
CALL 0x0016fa60
LAB_0019ae50:
LEA RAX,[0x22f2e8]
ADD RAX,0x10
MOV qword ptr [RBX],RAX
MOV RDI,qword ptr [RBX + 0x18]
TEST RDI,RDI
JZ 0x0019ae6c
CALL 0x0016fa60
LAB_0019ae6c:
MOV ESI,0x40
MOV RDI,RBX
POP RBX
JMP 0x0011b8e0
|
/* minja::IfTemplateToken::~IfTemplateToken() */
void __thiscall minja::IfTemplateToken::~IfTemplateToken(IfTemplateToken *this)
{
*(int ***)this = &PTR__IfTemplateToken_0022fb40;
if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x38) !=
(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release
(*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x38));
}
*(int ***)this = &PTR__TemplateToken_0022f2f8;
if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18) !=
(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release
(*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18));
}
operator_delete(this,0x40);
return;
}
|
|
19,980
|
orientStr(int)
|
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/def/defrw/defrw.cpp
|
char* orientStr(int orient) {
switch (orient) {
case 0: return ((char*)"N");
case 1: return ((char*)"W");
case 2: return ((char*)"S");
case 3: return ((char*)"E");
case 4: return ((char*)"FN");
case 5: return ((char*)"FW");
case 6: return ((char*)"FS");
case 7: return ((char*)"FE");
};
return ((char*)"BOGUS");
}
|
O3
|
cpp
|
orientStr(int):
cmpl $0x7, %edi
ja 0x7a5c
movl %edi, %eax
leaq 0x5c9e9(%rip), %rcx # 0x64440
movq (%rcx,%rax,8), %rax
retq
leaq 0x38b46(%rip), %rax # 0x405a9
retq
|
_Z9orientStri:
cmp edi, 7
ja short loc_7A5C
mov eax, edi
lea rcx, off_64440; "N"
mov rax, [rcx+rax*8]
retn
loc_7A5C:
lea rax, aBogus; "BOGUS"
retn
|
const char * orientStr(unsigned int a1)
{
if ( a1 > 7 )
return "BOGUS";
else
return (const char *)*(&off_64440 + a1);
}
|
orientStr:
CMP EDI,0x7
JA 0x00107a5c
MOV EAX,EDI
LEA RCX,[0x164440]
MOV RAX,qword ptr [RCX + RAX*0x8]
RET
LAB_00107a5c:
LEA RAX,[0x1405a9]
RET
|
/* orientStr(int) */
char * orientStr(int param_1)
{
if ((uint)param_1 < 8) {
return (&PTR_DAT_00164440)[(uint)param_1];
}
return "BOGUS";
}
|
|
19,981
|
inline_mysql_mutex_init
|
eloqsql/include/mysql/psi/mysql_thread.h
|
static inline int inline_mysql_mutex_init(
#ifdef HAVE_PSI_MUTEX_INTERFACE
PSI_mutex_key key,
#endif
mysql_mutex_t *that,
const pthread_mutexattr_t *attr
#ifdef SAFE_MUTEX
, const char *src_name, const char *src_file, uint src_line
#endif
)
{
#ifdef HAVE_PSI_MUTEX_INTERFACE
that->m_psi= PSI_MUTEX_CALL(init_mutex)(key, &that->m_mutex);
#else
that->m_psi= NULL;
#endif
#ifdef COROUTINE_ENABLED
that->l.data= that;
that->l.prev= that->l.next= NULL;
#endif
#ifdef SAFE_MUTEX
return safe_mutex_init(&that->m_mutex, attr, src_name, src_file, src_line);
#else
return pthread_mutex_init(&that->m_mutex, attr);
#endif
}
|
O0
|
c
|
inline_mysql_mutex_init:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
leaq 0x1c9c06(%rip), %rax # 0x2c75a0
movq (%rax), %rax
movq 0x40(%rax), %rax
movl -0x4(%rbp), %edi
movq -0x10(%rbp), %rsi
callq *%rax
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x40(%rax)
movq -0x10(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x38(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x30(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x28(%rax)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x2a320
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
|
inline_mysql_mutex_init_11:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_4], edi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+40h]
mov edi, [rbp+var_4]
mov rsi, [rbp+var_10]
call rax
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+40h], rcx
mov rcx, [rbp+var_10]
mov rax, [rbp+var_10]
mov [rax+38h], rcx
mov rax, [rbp+var_10]
mov qword ptr [rax+30h], 0
mov rax, [rbp+var_10]
mov qword ptr [rax+28h], 0
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call _pthread_mutex_init
add rsp, 20h
pop rbp
retn
|
long long inline_mysql_mutex_init_11(unsigned int a1, _QWORD *a2, long long a3)
{
a2[8] = ((long long ( *)(_QWORD, _QWORD *))PSI_server[8])(a1, a2);
a2[7] = a2;
a2[6] = 0LL;
a2[5] = 0LL;
return pthread_mutex_init(a2, a3);
}
|
inline_mysql_mutex_init:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV dword ptr [RBP + -0x4],EDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
LEA RAX,[0x3c75a0]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x40]
MOV EDI,dword ptr [RBP + -0x4]
MOV RSI,qword ptr [RBP + -0x10]
CALL RAX
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x40],RCX
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x38],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x30],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x28],0x0
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x0012a320
ADD RSP,0x20
POP RBP
RET
|
void inline_mysql_mutex_init
(int4 param_1,pthread_mutex_t *param_2,pthread_mutexattr_t *param_3)
{
int8 uVar1;
uVar1 = (**(code **)(PSI_server + 0x40))(param_1,param_2);
*(int8 *)((long)param_2 + 0x40) = uVar1;
*(pthread_mutex_t **)((long)param_2 + 0x38) = param_2;
*(int8 *)((long)param_2 + 0x30) = 0;
param_2[1].__align = 0;
pthread_mutex_init(param_2,param_3);
return;
}
|
|
19,982
|
nglog::GetStackTrace[abi:cxx11]()
|
ng-log[P]ng-log/src/utilities.cc
|
std::string GetStackTrace() {
std::string stacktrace;
DumpStackTrace(1, DebugWriteToString, &stacktrace);
return stacktrace;
}
|
O1
|
cpp
|
nglog::GetStackTrace[abi:cxx11]():
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x10(%rdi), %r15
movq %r15, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
leaq 0x13f(%rip), %rdi # 0x2186e
movq %rbx, %rsi
callq 0x2175e
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq (%rbx), %rdi
cmpq %r15, %rdi
je 0x21756
movq (%r15), %rsi
incq %rsi
callq 0x8fcc
movq %r14, %rdi
callq 0x7930
|
_ZN5nglog13GetStackTraceB5cxx11Ev:
push r15
push r14
push rbx
mov rbx, rdi
lea r15, [rdi+10h]
mov [rdi], r15
mov qword ptr [rdi+8], 0
mov byte ptr [rdi+10h], 0
lea rdi, _ZN5nglogL18DebugWriteToStringEPKcPv; this
mov rsi, rbx; int
call _ZN5nglogL14DumpStackTraceEiPFvPKcPvES2_; nglog::DumpStackTrace(int,void (*)(char const*,void *),void *)
mov rax, rbx
pop rbx
pop r14
pop r15
retn
mov r14, rax
mov rdi, [rbx]; void *
cmp rdi, r15
jz short loc_21756
mov rsi, [r15]
inc rsi; unsigned __int64
call _ZdlPvm; operator delete(void *,ulong)
loc_21756:
mov rdi, r14
call __Unwind_Resume
|
long long nglog::GetStackTrace[abi:cxx11](long long a1, long long a2, void (*a3)(const char *, void *), void *a4)
{
*(_QWORD *)a1 = a1 + 16;
*(_QWORD *)(a1 + 8) = 0LL;
*(_BYTE *)(a1 + 16) = 0;
nglog::DumpStackTrace((nglog *)nglog::DebugWriteToString, a1, a3, a4);
return a1;
}
|
GetStackTrace[abi:cxx11]:
PUSH R15
PUSH R14
PUSH RBX
MOV RBX,RDI
LEA R15,[RDI + 0x10]
MOV qword ptr [RDI],R15
MOV qword ptr [RDI + 0x8],0x0
MOV byte ptr [RDI + 0x10],0x0
LAB_00121728:
LEA RDI,[0x12186e]
MOV RSI,RBX
CALL 0x0012175e
LAB_00121737:
MOV RAX,RBX
POP RBX
POP R14
POP R15
RET
|
/* nglog::GetStackTrace[abi:cxx11]() */
void nglog::GetStackTrace_abi_cxx11_(void)
{
void *in_RDX;
_func_void_char_ptr_void_ptr *in_RDI;
*(_func_void_char_ptr_void_ptr **)in_RDI = in_RDI + 0x10;
*(int8 *)(in_RDI + 8) = 0;
in_RDI[0x10] = (code)0x0;
/* try { // try from 00121728 to 00121736 has its CatchHandler @ 00121740 */
DumpStackTrace(0x12186e,in_RDI,in_RDX);
return;
}
|
|
19,983
|
SchemaConverter::SchemaConverter(std::function<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> (std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)> const&, bool, bool)
|
monkey531[P]llama/common/json-schema-to-grammar.cpp
|
SchemaConverter(
const std::function<json(const std::string &)> & fetch_json,
bool dotall,
bool compact_spaces)
: _fetch_json(fetch_json), _dotall(dotall)
{
_rules["space"] = compact_spaces ? "\" \"?" : SPACE_RULE;
}
|
O2
|
cpp
|
SchemaConverter::SchemaConverter(std::function<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> (std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)> const&, bool, bool):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %ecx, %ebp
movl %edx, %r14d
movq %rdi, %rbx
callq 0x8da6c
movb %r14b, 0x20(%rbx)
leaq 0x30(%rbx), %rax
andl $0x0, 0x30(%rbx)
andq $0x0, 0x38(%rbx)
movq %rax, 0x40(%rbx)
movq %rax, 0x48(%rbx)
andq $0x0, 0x50(%rbx)
leaq 0x28(%rbx), %r14
leaq 0x88(%rbx), %rax
movq %rax, 0x58(%rbx)
pushq $0x1
popq %rax
movq %rax, 0x60(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x68(%rbx)
movl $0x3f800000, %ecx # imm = 0x3F800000
movl %ecx, 0x78(%rbx)
movups %xmm0, 0x80(%rbx)
leaq 0xc0(%rbx), %rdx
movq %rdx, 0x90(%rbx)
movq %rax, 0x98(%rbx)
movups %xmm0, 0xa0(%rbx)
movl %ecx, 0xb0(%rbx)
movups %xmm0, 0xb8(%rbx)
movups %xmm0, 0xc8(%rbx)
movups %xmm0, 0xd8(%rbx)
movups %xmm0, 0xe8(%rbx)
testl %ebp, %ebp
je 0x8d495
leaq 0x2bb1c(%rip), %rsi # 0xb8fa0
leaq 0x8(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0x26cb4
jmp 0x8d4a6
leaq 0x71e1c(%rip), %rsi # 0xff2b8
leaq 0x8(%rsp), %rdi
callq 0x23c40
leaq 0x2bd16(%rip), %rsi # 0xb91c3
leaq 0x28(%rsp), %rdi
leaq 0x6(%rsp), %rdx
callq 0x26cb4
leaq 0x28(%rsp), %rsi
movq %r14, %rdi
callq 0x8dab2
leaq 0x8(%rsp), %rsi
movq %rax, %rdi
callq 0x234e0
leaq 0x28(%rsp), %rdi
callq 0x24208
leaq 0x8(%rsp), %rdi
callq 0x24208
testb %bpl, %bpl
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r15
jmp 0x8d513
movq %rax, %r15
jmp 0x8d51d
movq %rax, %r15
leaq 0x28(%rsp), %rdi
callq 0x24208
leaq 0x8(%rsp), %rdi
callq 0x24208
leaq 0x58(%rbx), %r12
leaq 0x90(%rbx), %r13
testb %bpl, %bpl
leaq 0xe0(%rbx), %rdi
leaq 0xc8(%rbx), %rbp
callq 0x26d2a
movq %rbp, %rdi
callq 0x26d2a
movq %r13, %rdi
callq 0x5d014
movq %r12, %rdi
callq 0x8df00
movq %r14, %rdi
callq 0x8dfbe
movq %rbx, %rdi
callq 0x48672
movq %r15, %rdi
callq 0x23fc0
|
_ZN15SchemaConverterC2ERKSt8functionIFN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES5_IhSaIhEEvEERKSB_EEbb:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov ebp, ecx
mov r14d, edx
mov rbx, rdi
call _ZNSt8functionIFN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEERKSA_EEC2ERKSI_; std::function<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::string const&)>::function(std::function<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::string const&)> const&)
mov [rbx+20h], r14b
lea rax, [rbx+30h]
and dword ptr [rbx+30h], 0
and qword ptr [rbx+38h], 0
mov [rbx+40h], rax
mov [rbx+48h], rax
and qword ptr [rbx+50h], 0
lea r14, [rbx+28h]
lea rax, [rbx+88h]
mov [rbx+58h], rax
push 1
pop rax
mov [rbx+60h], rax
xorps xmm0, xmm0
movups xmmword ptr [rbx+68h], xmm0
mov ecx, 3F800000h
mov [rbx+78h], ecx
movups xmmword ptr [rbx+80h], xmm0
lea rdx, [rbx+0C0h]
mov [rbx+90h], rdx
mov [rbx+98h], rax
movups xmmword ptr [rbx+0A0h], xmm0
mov [rbx+0B0h], ecx
movups xmmword ptr [rbx+0B8h], xmm0
movups xmmword ptr [rbx+0C8h], xmm0
movups xmmword ptr [rbx+0D8h], xmm0
movups xmmword ptr [rbx+0E8h], xmm0
test ebp, ebp
jz short loc_8D495
lea rsi, asc_B8FA0; "\" \"?"
lea rdi, [rsp+78h+var_70]
lea rdx, [rsp+78h+var_71]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short loc_8D4A6
loc_8D495:
lea rsi, _ZL10SPACE_RULEB5cxx11; SPACE_RULE
lea rdi, [rsp+78h+var_70]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2ERKS4_; std::string::basic_string(std::string const&)
loc_8D4A6:
lea rsi, aSpace+7; "space"
lea rdi, [rsp+78h+var_50]
lea rdx, [rsp+78h+var_72]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rsi, [rsp+78h+var_50]
mov rdi, r14
call _ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_St4lessIS5_ESaISt4pairIKS5_S5_EEEixEOS5_; std::map<std::string,std::string>::operator[](std::string&&)
lea rsi, [rsp+78h+var_70]
mov rdi, rax
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&)
lea rdi, [rsp+78h+var_50]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+78h+var_70]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
add rsp, 48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r15, rax
jmp short loc_8D513
mov r15, rax
jmp short loc_8D51D
mov r15, rax
lea rdi, [rsp+arg_20]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_8D513:
lea rdi, [rsp+arg_0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_8D51D:
lea r12, [rbx+58h]
lea r13, [rbx+90h]
test bpl, bpl
lea rdi, [rbx+0E0h]; void *
lea rbp, [rbx+0C8h]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, rbp; void *
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, r13
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_SaIS5_ENSt8__detail9_IdentityESt8equal_toIS5_ESt4hashIS5_ENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb1ELb1ELb1EEEED2Ev; std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>>::~_Hashtable()
mov rdi, r12
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_N8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapESt6vectorS5_blmdSaNS9_14adl_serializerESC_IhSaIhEEvEEESaISH_ENSt8__detail10_Select1stESt8equal_toIS5_ESt4hashIS5_ENSJ_18_Mod_range_hashingENSJ_20_Default_ranged_hashENSJ_20_Prime_rehash_policyENSJ_17_Hashtable_traitsILb1ELb0ELb1EEEED2Ev; std::_Hashtable<std::string,std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::~_Hashtable()
mov rdi, r14
call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_S5_ESt10_Select1stIS8_ESt4lessIS5_ESaIS8_EED2Ev; std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::~_Rb_tree()
mov rdi, rbx; this
call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base()
mov rdi, r15
call __Unwind_Resume
|
void SchemaConverter::SchemaConverter(long long a1, long long a2, char a3, int a4)
{
long long v6; // rax
_QWORD v7[4]; // [rsp+8h] [rbp-70h] BYREF
_QWORD v8[10]; // [rsp+28h] [rbp-50h] BYREF
std::function<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::string const&)>::function();
*(_BYTE *)(a1 + 32) = a3;
*(_DWORD *)(a1 + 48) = 0;
*(_QWORD *)(a1 + 56) = 0LL;
*(_QWORD *)(a1 + 64) = a1 + 48;
*(_QWORD *)(a1 + 72) = a1 + 48;
*(_QWORD *)(a1 + 80) = 0LL;
*(_QWORD *)(a1 + 88) = a1 + 136;
*(_QWORD *)(a1 + 96) = 1LL;
*(_OWORD *)(a1 + 104) = 0LL;
*(_DWORD *)(a1 + 120) = 1065353216;
*(_OWORD *)(a1 + 128) = 0LL;
*(_QWORD *)(a1 + 144) = a1 + 192;
*(_QWORD *)(a1 + 152) = 1LL;
*(_OWORD *)(a1 + 160) = 0LL;
*(_DWORD *)(a1 + 176) = 1065353216;
*(_OWORD *)(a1 + 184) = 0LL;
*(_OWORD *)(a1 + 200) = 0LL;
*(_OWORD *)(a1 + 216) = 0LL;
*(_OWORD *)(a1 + 232) = 0LL;
if ( a4 )
std::string::basic_string<std::allocator<char>>(v7, (long long)"\" \"?");
else
std::string::basic_string(v7);
std::string::basic_string<std::allocator<char>>(v8, (long long)"space");
v6 = std::map<std::string,std::string>::operator[](a1 + 40, v8);
std::string::_M_assign(v6, v7);
std::string::~string(v8);
std::string::~string(v7);
}
|
SchemaConverter:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV EBP,ECX
MOV R14D,EDX
MOV RBX,RDI
CALL 0x0018da6c
MOV byte ptr [RBX + 0x20],R14B
LEA RAX,[RBX + 0x30]
AND dword ptr [RBX + 0x30],0x0
AND qword ptr [RBX + 0x38],0x0
MOV qword ptr [RBX + 0x40],RAX
MOV qword ptr [RBX + 0x48],RAX
AND qword ptr [RBX + 0x50],0x0
LEA R14,[RBX + 0x28]
LEA RAX,[RBX + 0x88]
MOV qword ptr [RBX + 0x58],RAX
PUSH 0x1
POP RAX
MOV qword ptr [RBX + 0x60],RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x68],XMM0
MOV ECX,0x3f800000
MOV dword ptr [RBX + 0x78],ECX
MOVUPS xmmword ptr [RBX + 0x80],XMM0
LEA RDX,[RBX + 0xc0]
MOV qword ptr [RBX + 0x90],RDX
MOV qword ptr [RBX + 0x98],RAX
MOVUPS xmmword ptr [RBX + 0xa0],XMM0
MOV dword ptr [RBX + 0xb0],ECX
MOVUPS xmmword ptr [RBX + 0xb8],XMM0
MOVUPS xmmword ptr [RBX + 0xc8],XMM0
MOVUPS xmmword ptr [RBX + 0xd8],XMM0
MOVUPS xmmword ptr [RBX + 0xe8],XMM0
TEST EBP,EBP
JZ 0x0018d495
LAB_0018d47d:
LEA RSI,[0x1b8fa0]
LEA RDI,[RSP + 0x8]
LEA RDX,[RSP + 0x7]
CALL 0x00126cb4
JMP 0x0018d4a6
LAB_0018d495:
LEA RSI,[0x1ff2b8]
LEA RDI,[RSP + 0x8]
CALL 0x00123c40
LAB_0018d4a6:
LEA RSI,[0x1b91c3]
LEA RDI,[RSP + 0x28]
LEA RDX,[RSP + 0x6]
CALL 0x00126cb4
LAB_0018d4bc:
LEA RSI,[RSP + 0x28]
MOV RDI,R14
CALL 0x0018dab2
LEA RSI,[RSP + 0x8]
MOV RDI,RAX
CALL 0x001234e0
LAB_0018d4d6:
LEA RDI,[RSP + 0x28]
CALL 0x00124208
LEA RDI,[RSP + 0x8]
CALL 0x00124208
TEST BPL,BPL
ADD RSP,0x48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* SchemaConverter::SchemaConverter(std::function<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::__cxx11::string const&)> const&, bool, bool) */
void __thiscall
SchemaConverter::SchemaConverter(SchemaConverter *this,function *param_1,bool param_2,bool param_3)
{
string *psVar1;
int7 in_register_00000009;
allocator local_72;
allocator local_71;
string local_70 [32];
string local_50 [32];
std::
function<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::__cxx11::string_const&)>
::function((function<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::__cxx11::string_const&)>
*)this,param_1);
this[0x20] = (SchemaConverter)param_2;
*(int4 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(SchemaConverter **)(this + 0x40) = this + 0x30;
*(SchemaConverter **)(this + 0x48) = this + 0x30;
*(int8 *)(this + 0x50) = 0;
*(SchemaConverter **)(this + 0x58) = this + 0x88;
*(int8 *)(this + 0x60) = 1;
*(int8 *)(this + 0x68) = 0;
*(int8 *)(this + 0x70) = 0;
*(int4 *)(this + 0x78) = 0x3f800000;
*(int8 *)(this + 0x80) = 0;
*(int8 *)(this + 0x88) = 0;
*(SchemaConverter **)(this + 0x90) = this + 0xc0;
*(int8 *)(this + 0x98) = 1;
*(int8 *)(this + 0xa0) = 0;
*(int8 *)(this + 0xa8) = 0;
*(int4 *)(this + 0xb0) = 0x3f800000;
*(int8 *)(this + 0xb8) = 0;
*(int8 *)(this + 0xc0) = 0;
*(int8 *)(this + 200) = 0;
*(int8 *)(this + 0xd0) = 0;
*(int8 *)(this + 0xd8) = 0;
*(int8 *)(this + 0xe0) = 0;
*(int8 *)(this + 0xe8) = 0;
*(int8 *)(this + 0xf0) = 0;
if ((int)CONCAT71(in_register_00000009,param_3) == 0) {
std::__cxx11::string::string(local_70,(string *)SPACE_RULE_abi_cxx11_);
}
else {
/* try { // try from 0018d47d to 0018d4a5 has its CatchHandler @ 0018d501 */
std::__cxx11::string::string<std::allocator<char>>(local_70,"\" \"?",&local_71);
}
/* try { // try from 0018d4a6 to 0018d4bb has its CatchHandler @ 0018d4fc */
std::__cxx11::string::string<std::allocator<char>>(local_50,"space",&local_72);
/* try { // try from 0018d4bc to 0018d4d5 has its CatchHandler @ 0018d506 */
psVar1 = (string *)
std::
map<std::__cxx11::string,std::__cxx11::string,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
::operator[]((map<std::__cxx11::string,std::__cxx11::string,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
*)(this + 0x28),local_50);
std::__cxx11::string::_M_assign(psVar1);
std::__cxx11::string::~string(local_50);
std::__cxx11::string::~string(local_70);
return;
}
|
|
19,984
|
OpenSubdiv::v3_6_0::Bfr::FaceTopology::print(int const*) const
|
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/faceTopology.cpp
|
void
FaceTopology::print(Index const faceVertIndices[]) const {
MultiVertexTag const & tag = _combinedTag;
printf("FaceTopology:\n");
printf(" face size = %d\n", _faceSize);
printf(" num-face-verts = %d\n", _numFaceVertsTotal);
printf(" Tags:\n");
printf(" inf-sharp verts = %d\n", tag.HasInfSharpVertices());
printf(" semi-sharp verts = %d\n", tag.HasSemiSharpVertices());
printf(" inf-sharp edges = %d\n", tag.HasInfSharpEdges());
printf(" semi-sharp edges = %d\n", tag.HasSemiSharpEdges());
printf(" inf-sharp darts = %d\n", tag.HasInfSharpDarts());
printf(" unsharp boundary = %d\n", tag.HasNonSharpBoundary());
printf(" irregular faces = %d\n", tag.HasIrregularFaceSizes());
printf(" unordered verts = %d\n", tag.HasUnOrderedVertices());
if (faceVertIndices) {
Index const * cornerFaceVertIndices = faceVertIndices;
for (int i = 0; i < _faceSize; ++i) {
printf(" corner %d:\n", i);
FaceVertex const & cTop = GetTopology(i);
printf(" topology: num faces = %d, boundary = %d\n",
cTop.GetNumFaces(), cTop.GetTag().IsBoundary());
printf(" face-vert indices:\n");
for (int j = 0, n = 0; j < cTop.GetNumFaces(); ++j) {
printf(" face %d: ", j);
int S = cTop.GetFaceSize(j);
for (int k = 0; k < S; ++k, ++n) {
printf("%3d", cornerFaceVertIndices[n]);
}
printf("\n");
}
cornerFaceVertIndices += cTop.GetNumFaceVertices();
}
}
}
|
O1
|
cpp
|
OpenSubdiv::v3_6_0::Bfr::FaceTopology::print(int const*) const:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x37618(%rip), %rdi # 0xbe1af
callq 0x3b430
movl 0x8(%r14), %esi
leaq 0x376fc(%rip), %rdi # 0xbe2a3
xorl %eax, %eax
callq 0x38100
movl 0x10(%r14), %esi
leaq 0x37703(%rip), %rdi # 0xbe2bc
xorl %eax, %eax
callq 0x38100
leaq 0x3770e(%rip), %rdi # 0xbe2d5
callq 0x3b430
movl 0x14(%r14), %esi
shrl %esi
andl $0x1, %esi
leaq 0x37311(%rip), %rdi # 0xbdeed
xorl %eax, %eax
callq 0x38100
movl 0x14(%r14), %esi
shrl $0x4, %esi
andl $0x1, %esi
leaq 0x37317(%rip), %rdi # 0xbdf0b
xorl %eax, %eax
callq 0x38100
movl 0x14(%r14), %esi
shrl $0x2, %esi
andl $0x1, %esi
leaq 0x3731d(%rip), %rdi # 0xbdf29
xorl %eax, %eax
callq 0x38100
movl 0x14(%r14), %esi
shrl $0x5, %esi
andl $0x1, %esi
leaq 0x37323(%rip), %rdi # 0xbdf47
xorl %eax, %eax
callq 0x38100
movl 0x14(%r14), %esi
shrl $0x3, %esi
andl $0x1, %esi
leaq 0x37329(%rip), %rdi # 0xbdf65
xorl %eax, %eax
callq 0x38100
movl 0x14(%r14), %esi
shrl $0xa, %esi
andl $0x1, %esi
leaq 0x3732f(%rip), %rdi # 0xbdf83
xorl %eax, %eax
callq 0x38100
movl 0x14(%r14), %esi
shrl $0x7, %esi
andl $0x1, %esi
leaq 0x37335(%rip), %rdi # 0xbdfa1
xorl %eax, %eax
callq 0x38100
movl 0x14(%r14), %esi
shrl $0x8, %esi
andl $0x1, %esi
leaq 0x3733b(%rip), %rdi # 0xbdfbf
xorl %eax, %eax
callq 0x38100
movq %rbx, 0x8(%rsp)
testq %rbx, %rbx
je 0x86dc4
cmpl $0x0, 0x8(%r14)
jle 0x86dc4
leaq 0x37400(%rip), %r15 # 0xbe0ab
xorl %r12d, %r12d
movq %r14, 0x10(%rsp)
leaq 0x37324(%rip), %rdi # 0xbdfde
movl %r12d, %esi
xorl %eax, %eax
callq 0x38100
movq 0x18(%r14), %rbx
movq %r12, 0x18(%rsp)
imulq $0xe0, %r12, %r12
leaq (%rbx,%r12), %r14
movswl 0x2(%rbx,%r12), %esi
movzwl 0x98(%rbx,%r12), %edx
andl $0x1, %edx
leaq 0x37301(%rip), %rdi # 0xbdff2
xorl %eax, %eax
callq 0x38100
leaq 0x374e5(%rip), %rdi # 0xbe1e4
callq 0x3b430
cmpw $0x0, 0x2(%rbx,%r12)
jle 0x86d95
xorl %r13d, %r13d
xorl %ebx, %ebx
movq %r14, 0x20(%rsp)
leaq 0x37376(%rip), %rdi # 0xbe098
movl %r13d, %esi
xorl %eax, %eax
callq 0x38100
movswl 0x9c(%r14), %eax
testl %eax, %eax
jne 0x86d45
movq 0x60(%r14), %rcx
movl 0x4(%rcx,%r13,4), %eax
subl (%rcx,%r13,4), %eax
testl %eax, %eax
jle 0x86d7e
movl %ebx, %r14d
movslq %ebx, %rcx
movq 0x8(%rsp), %rdx
leaq (%rdx,%rcx,4), %rbx
movl %eax, %ebp
xorl %r12d, %r12d
movl (%rbx,%r12,4), %esi
movq %r15, %rdi
xorl %eax, %eax
callq 0x38100
incq %r12
cmpl %r12d, %ebp
jne 0x86d5d
movl %r14d, %ebx
addl %r12d, %ebx
movq 0x20(%rsp), %r14
movl $0xa, %edi
callq 0x3af50
incq %r13
movswq 0x2(%r14), %rax
cmpq %rax, %r13
jl 0x86d1b
movslq 0xa0(%r14), %rax
movq 0x8(%rsp), %rcx
leaq (%rcx,%rax,4), %rcx
movq %rcx, 0x8(%rsp)
movq 0x18(%rsp), %r12
incq %r12
movq 0x10(%rsp), %r14
movslq 0x8(%r14), %rax
cmpq %rax, %r12
jl 0x86cb3
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
|
_ZNK10OpenSubdiv6v3_6_03Bfr12FaceTopology5printEPKi:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov rbx, rsi
mov r14, rdi
lea rdi, aFacetopology+4; "FaceTopology:"
call _puts
mov esi, [r14+8]
lea rdi, aFaceSizeD_0; " face size = %d\n"
xor eax, eax
call _printf
mov esi, [r14+10h]
lea rdi, aNumFaceVertsD_0; " num-face-verts = %d\n"
xor eax, eax
call _printf
lea rdi, aTags; " Tags:"
call _puts
mov esi, [r14+14h]
shr esi, 1
and esi, 1
lea rdi, aInfSharpVertsD+3; " inf-sharp verts = %d\n"
xor eax, eax
call _printf
mov esi, [r14+14h]
shr esi, 4
and esi, 1
lea rdi, aSemiSharpVerts+3; " semi-sharp verts = %d\n"
xor eax, eax
call _printf
mov esi, [r14+14h]
shr esi, 2
and esi, 1
lea rdi, aInfSharpEdgesD+3; " inf-sharp edges = %d\n"
xor eax, eax
call _printf
mov esi, [r14+14h]
shr esi, 5
and esi, 1
lea rdi, aSemiSharpEdges+3; " semi-sharp edges = %d\n"
xor eax, eax
call _printf
mov esi, [r14+14h]
shr esi, 3
and esi, 1
lea rdi, aInfSharpDartsD+3; " inf-sharp darts = %d\n"
xor eax, eax
call _printf
mov esi, [r14+14h]
shr esi, 0Ah
and esi, 1
lea rdi, aUnsharpBoundar+3; " unsharp boundary = %d\n"
xor eax, eax
call _printf
mov esi, [r14+14h]
shr esi, 7
and esi, 1
lea rdi, aIrregularFaces+3; " irregular faces = %d\n"
xor eax, eax
call _printf
mov esi, [r14+14h]
shr esi, 8
and esi, 1
lea rdi, aUnorderedVerts+3; " unordered verts = %d\n"
xor eax, eax
call _printf
mov [rsp+58h+var_50], rbx
test rbx, rbx
jz loc_86DC4
cmp dword ptr [r14+8], 0
jle loc_86DC4
lea r15, a3d; "%3d"
xor r12d, r12d
mov [rsp+58h+var_48], r14
loc_86CB3:
lea rdi, aCornerD_0+4; " corner %d:\n"
mov esi, r12d
xor eax, eax
call _printf
mov rbx, [r14+18h]
mov [rsp+58h+var_40], r12
imul r12, 0E0h
lea r14, [rbx+r12]
movsx esi, word ptr [rbx+r12+2]
movzx edx, word ptr [rbx+r12+98h]
and edx, 1
lea rdi, aTopologyNumFac+4; " topology: num faces = %d, bou"...
xor eax, eax
call _printf
lea rdi, aFaceVertIndice_0+4; " face-vert indices:"
call _puts
cmp word ptr [rbx+r12+2], 0
jle loc_86D95
xor r13d, r13d
xor ebx, ebx
mov [rsp+58h+var_38], r14
loc_86D1B:
lea rdi, aFaceD_0+4; " face %d: "
mov esi, r13d
xor eax, eax
call _printf
movsx eax, word ptr [r14+9Ch]
test eax, eax
jnz short loc_86D45
mov rcx, [r14+60h]
mov eax, [rcx+r13*4+4]
sub eax, [rcx+r13*4]
loc_86D45:
test eax, eax
jle short loc_86D7E
mov r14d, ebx
movsxd rcx, ebx
mov rdx, [rsp+58h+var_50]
lea rbx, [rdx+rcx*4]
mov ebp, eax
xor r12d, r12d
loc_86D5D:
mov esi, [rbx+r12*4]
mov rdi, r15
xor eax, eax
call _printf
inc r12
cmp ebp, r12d
jnz short loc_86D5D
mov ebx, r14d
add ebx, r12d
mov r14, [rsp+58h+var_38]
loc_86D7E:
mov edi, 0Ah
call _putchar
inc r13
movsx rax, word ptr [r14+2]
cmp r13, rax
jl short loc_86D1B
loc_86D95:
movsxd rax, dword ptr [r14+0A0h]
mov rcx, [rsp+58h+var_50]
lea rcx, [rcx+rax*4]
mov [rsp+58h+var_50], rcx
mov r12, [rsp+58h+var_40]
inc r12
mov r14, [rsp+58h+var_48]
movsxd rax, dword ptr [r14+8]
cmp r12, rax
jl loc_86CB3
loc_86DC4:
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long OpenSubdiv::v3_6_0::Bfr::FaceTopology::print(
OpenSubdiv::v3_6_0::Bfr::FaceTopology *this,
const int *a2)
{
OpenSubdiv::v3_6_0::Bfr::FaceTopology *v2; // r14
long long result; // rax
long long v4; // r12
long long v5; // r14
long long v6; // r13
int v7; // ebx
int v8; // eax
int v9; // r14d
const int *v10; // rbx
int v11; // ebp
long long v12; // r12
const int *v13; // [rsp+8h] [rbp-50h]
long long v14; // [rsp+18h] [rbp-40h]
long long v15; // [rsp+20h] [rbp-38h]
v2 = this;
puts("FaceTopology:");
printf(" face size = %d\n", *((_DWORD *)this + 2));
printf(" num-face-verts = %d\n", *((_DWORD *)this + 4));
puts(" Tags:");
printf(" inf-sharp verts = %d\n", (*((_DWORD *)this + 5) >> 1) & 1);
printf(" semi-sharp verts = %d\n", (*((_DWORD *)this + 5) >> 4) & 1);
printf(" inf-sharp edges = %d\n", (*((_DWORD *)this + 5) >> 2) & 1);
printf(" semi-sharp edges = %d\n", (*((_DWORD *)this + 5) >> 5) & 1);
printf(" inf-sharp darts = %d\n", (*((_DWORD *)this + 5) >> 3) & 1);
printf(" unsharp boundary = %d\n", (*((_DWORD *)this + 5) >> 10) & 1);
printf(" irregular faces = %d\n", (*((_DWORD *)this + 5) >> 7) & 1);
result = printf(" unordered verts = %d\n", (*((_DWORD *)this + 5) >> 8) & 1);
v13 = a2;
if ( a2 && *((int *)this + 2) > 0 )
{
v4 = 0LL;
do
{
printf(" corner %d:\n", v4);
v14 = v4;
v5 = *((_QWORD *)v2 + 3) + 224 * v4;
printf(" topology: num faces = %d, boundary = %d\n", *(__int16 *)(v5 + 2), *(_WORD *)(v5 + 152) & 1);
puts(" face-vert indices:");
if ( *(__int16 *)(v5 + 2) > 0 )
{
v6 = 0LL;
v7 = 0;
v15 = v5;
do
{
printf(" face %d: ", v6);
v8 = *(__int16 *)(v5 + 156);
if ( !*(_WORD *)(v5 + 156) )
v8 = *(_DWORD *)(*(_QWORD *)(v5 + 96) + 4 * v6 + 4) - *(_DWORD *)(*(_QWORD *)(v5 + 96) + 4 * v6);
if ( v8 > 0 )
{
v9 = v7;
v10 = &v13[v7];
v11 = v8;
v12 = 0LL;
do
printf("%3d", v10[v12++]);
while ( v11 != (_DWORD)v12 );
v7 = v12 + v9;
v5 = v15;
}
putchar(10LL);
++v6;
}
while ( v6 < *(__int16 *)(v5 + 2) );
}
v13 += *(int *)(v5 + 160);
v4 = v14 + 1;
v2 = this;
result = *((int *)this + 2);
}
while ( v14 + 1 < result );
}
return result;
}
|
print:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV RBX,RSI
MOV R14,RDI
LEA RDI,[0x1be1af]
CALL 0x0013b430
MOV ESI,dword ptr [R14 + 0x8]
LEA RDI,[0x1be2a3]
XOR EAX,EAX
CALL 0x00138100
MOV ESI,dword ptr [R14 + 0x10]
LEA RDI,[0x1be2bc]
XOR EAX,EAX
CALL 0x00138100
LEA RDI,[0x1be2d5]
CALL 0x0013b430
MOV ESI,dword ptr [R14 + 0x14]
SHR ESI,0x1
AND ESI,0x1
LEA RDI,[0x1bdeed]
XOR EAX,EAX
CALL 0x00138100
MOV ESI,dword ptr [R14 + 0x14]
SHR ESI,0x4
AND ESI,0x1
LEA RDI,[0x1bdf0b]
XOR EAX,EAX
CALL 0x00138100
MOV ESI,dword ptr [R14 + 0x14]
SHR ESI,0x2
AND ESI,0x1
LEA RDI,[0x1bdf29]
XOR EAX,EAX
CALL 0x00138100
MOV ESI,dword ptr [R14 + 0x14]
SHR ESI,0x5
AND ESI,0x1
LEA RDI,[0x1bdf47]
XOR EAX,EAX
CALL 0x00138100
MOV ESI,dword ptr [R14 + 0x14]
SHR ESI,0x3
AND ESI,0x1
LEA RDI,[0x1bdf65]
XOR EAX,EAX
CALL 0x00138100
MOV ESI,dword ptr [R14 + 0x14]
SHR ESI,0xa
AND ESI,0x1
LEA RDI,[0x1bdf83]
XOR EAX,EAX
CALL 0x00138100
MOV ESI,dword ptr [R14 + 0x14]
SHR ESI,0x7
AND ESI,0x1
LEA RDI,[0x1bdfa1]
XOR EAX,EAX
CALL 0x00138100
MOV ESI,dword ptr [R14 + 0x14]
SHR ESI,0x8
AND ESI,0x1
LEA RDI,[0x1bdfbf]
XOR EAX,EAX
CALL 0x00138100
MOV qword ptr [RSP + 0x8],RBX
TEST RBX,RBX
JZ 0x00186dc4
CMP dword ptr [R14 + 0x8],0x0
JLE 0x00186dc4
LEA R15,[0x1be0ab]
XOR R12D,R12D
MOV qword ptr [RSP + 0x10],R14
LAB_00186cb3:
LEA RDI,[0x1bdfde]
MOV ESI,R12D
XOR EAX,EAX
CALL 0x00138100
MOV RBX,qword ptr [R14 + 0x18]
MOV qword ptr [RSP + 0x18],R12
IMUL R12,R12,0xe0
LEA R14,[RBX + R12*0x1]
MOVSX ESI,word ptr [RBX + R12*0x1 + 0x2]
MOVZX EDX,word ptr [RBX + R12*0x1 + 0x98]
AND EDX,0x1
LEA RDI,[0x1bdff2]
XOR EAX,EAX
CALL 0x00138100
LEA RDI,[0x1be1e4]
CALL 0x0013b430
CMP word ptr [RBX + R12*0x1 + 0x2],0x0
JLE 0x00186d95
XOR R13D,R13D
XOR EBX,EBX
MOV qword ptr [RSP + 0x20],R14
LAB_00186d1b:
LEA RDI,[0x1be098]
MOV ESI,R13D
XOR EAX,EAX
CALL 0x00138100
MOVSX EAX,word ptr [R14 + 0x9c]
TEST EAX,EAX
JNZ 0x00186d45
MOV RCX,qword ptr [R14 + 0x60]
MOV EAX,dword ptr [RCX + R13*0x4 + 0x4]
SUB EAX,dword ptr [RCX + R13*0x4]
LAB_00186d45:
TEST EAX,EAX
JLE 0x00186d7e
MOV R14D,EBX
MOVSXD RCX,EBX
MOV RDX,qword ptr [RSP + 0x8]
LEA RBX,[RDX + RCX*0x4]
MOV EBP,EAX
XOR R12D,R12D
LAB_00186d5d:
MOV ESI,dword ptr [RBX + R12*0x4]
MOV RDI,R15
XOR EAX,EAX
CALL 0x00138100
INC R12
CMP EBP,R12D
JNZ 0x00186d5d
MOV EBX,R14D
ADD EBX,R12D
MOV R14,qword ptr [RSP + 0x20]
LAB_00186d7e:
MOV EDI,0xa
CALL 0x0013af50
INC R13
MOVSX RAX,word ptr [R14 + 0x2]
CMP R13,RAX
JL 0x00186d1b
LAB_00186d95:
MOVSXD RAX,dword ptr [R14 + 0xa0]
MOV RCX,qword ptr [RSP + 0x8]
LEA RCX,[RCX + RAX*0x4]
MOV qword ptr [RSP + 0x8],RCX
MOV R12,qword ptr [RSP + 0x18]
INC R12
MOV R14,qword ptr [RSP + 0x10]
MOVSXD RAX,dword ptr [R14 + 0x8]
CMP R12,RAX
JL 0x00186cb3
LAB_00186dc4:
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* OpenSubdiv::v3_6_0::Bfr::FaceTopology::print(int const*) const */
void __thiscall OpenSubdiv::v3_6_0::Bfr::FaceTopology::print(FaceTopology *this,int *param_1)
{
long lVar1;
int iVar2;
int iVar3;
long lVar4;
long lVar5;
ulong uVar6;
ulong uVar7;
int *local_50;
puts("FaceTopology:");
printf(" face size = %d\n",(ulong)*(uint *)(this + 8));
printf(" num-face-verts = %d\n",(ulong)*(uint *)(this + 0x10));
puts(" Tags:");
printf(" inf-sharp verts = %d\n",(ulong)(*(uint *)(this + 0x14) >> 1 & 1));
printf(" semi-sharp verts = %d\n",(ulong)(*(uint *)(this + 0x14) >> 4 & 1));
printf(" inf-sharp edges = %d\n",(ulong)(*(uint *)(this + 0x14) >> 2 & 1));
printf(" semi-sharp edges = %d\n",(ulong)(*(uint *)(this + 0x14) >> 5 & 1));
printf(" inf-sharp darts = %d\n",(ulong)(*(uint *)(this + 0x14) >> 3 & 1));
printf(" unsharp boundary = %d\n",(ulong)(*(uint *)(this + 0x14) >> 10 & 1));
printf(" irregular faces = %d\n",(ulong)(*(uint *)(this + 0x14) >> 7 & 1));
printf(" unordered verts = %d\n",(ulong)(*(uint *)(this + 0x14) >> 8 & 1));
if ((param_1 != (int *)0x0) && (0 < *(int *)(this + 8))) {
uVar6 = 0;
local_50 = param_1;
do {
printf(" corner %d:\n",uVar6 & 0xffffffff);
lVar5 = *(long *)(this + 0x18);
lVar4 = uVar6 * 0xe0;
lVar1 = lVar5 + lVar4;
printf(" topology: num faces = %d, boundary = %d\n",
(ulong)(uint)(int)*(short *)(lVar5 + 2 + lVar4),
(ulong)(*(ushort *)(lVar5 + 0x98 + lVar4) & 1));
puts(" face-vert indices:");
if (0 < *(short *)(lVar5 + 2 + lVar4)) {
uVar7 = 0;
iVar3 = 0;
do {
printf(" face %d: ",uVar7 & 0xffffffff);
iVar2 = (int)*(short *)(lVar1 + 0x9c);
if (*(short *)(lVar1 + 0x9c) == 0) {
iVar2 = *(int *)(*(long *)(lVar1 + 0x60) + 4 + uVar7 * 4) -
*(int *)(*(long *)(lVar1 + 0x60) + uVar7 * 4);
}
if (0 < iVar2) {
lVar5 = 0;
do {
printf("%3d",(ulong)(uint)local_50[iVar3 + lVar5]);
lVar5 = lVar5 + 1;
} while (iVar2 != (int)lVar5);
iVar3 = iVar3 + (int)lVar5;
}
putchar(10);
uVar7 = uVar7 + 1;
} while ((long)uVar7 < (long)*(short *)(lVar1 + 2));
}
local_50 = local_50 + *(int *)(lVar1 + 0xa0);
uVar6 = uVar6 + 1;
} while ((long)uVar6 < (long)*(int *)(this + 8));
}
return;
}
|
|
19,985
|
mysql_list_processes_start_internal
|
eloqsql/libmariadb/libmariadb/mariadb_async.c
|
static void
mysql_list_processes_start_internal(void *d)
{
MK_ASYNC_INTERNAL_BODY(
mysql_list_processes,
(parms->mysql),
parms->mysql,
MYSQL_RES *,
r_ptr)
}
|
O3
|
c
|
mysql_list_processes_start_internal:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq (%rdi), %rdi
movq 0x480(%rdi), %rax
movq 0x28(%rax), %rbx
callq 0x3c8fd
movq %rax, 0x8(%rbx)
movl $0x0, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
|
mysql_list_processes_start_internal:
push rbp
mov rbp, rsp
push rbx
push rax
mov rdi, [rdi]
mov rax, [rdi+480h]
mov rbx, [rax+28h]
call mysql_list_processes
mov [rbx+8], rax
mov dword ptr [rbx], 0
add rsp, 8
pop rbx
pop rbp
retn
|
long long mysql_list_processes_start_internal(long long *a1)
{
long long v1; // rdi
long long v2; // rbx
long long result; // rax
v1 = *a1;
v2 = *(_QWORD *)(*(_QWORD *)(v1 + 1152) + 40LL);
result = mysql_list_processes(v1);
*(_QWORD *)(v2 + 8) = result;
*(_DWORD *)v2 = 0;
return result;
}
|
mysql_list_processes_start_internal:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RDI,qword ptr [RDI]
MOV RAX,qword ptr [RDI + 0x480]
MOV RBX,qword ptr [RAX + 0x28]
CALL 0x0013c8fd
MOV qword ptr [RBX + 0x8],RAX
MOV dword ptr [RBX],0x0
ADD RSP,0x8
POP RBX
POP RBP
RET
|
void mysql_list_processes_start_internal(long *param_1)
{
int4 *puVar1;
int8 uVar2;
puVar1 = *(int4 **)(*(long *)(*param_1 + 0x480) + 0x28);
uVar2 = mysql_list_processes();
*(int8 *)(puVar1 + 2) = uVar2;
*puVar1 = 0;
return;
}
|
|
19,986
|
create_metadata_lock(void*, MDL_key const*, int, int, int, char const*, unsigned int)
|
eloqsql/storage/perfschema/pfs_instr.cc
|
PFS_metadata_lock* create_metadata_lock(void *identity,
const MDL_key *mdl_key,
opaque_mdl_type mdl_type,
opaque_mdl_duration mdl_duration,
opaque_mdl_status mdl_status,
const char *src_file,
uint src_line)
{
PFS_metadata_lock *pfs;
pfs_dirty_state dirty_state;
pfs= global_mdl_container.allocate(& dirty_state);
if (pfs != NULL)
{
pfs->m_identity= identity;
pfs->m_enabled= global_metadata_class.m_enabled && flag_global_instrumentation;
pfs->m_timed= global_metadata_class.m_timed;
pfs->m_mdl_key.mdl_key_init(mdl_key);
pfs->m_mdl_type= mdl_type;
pfs->m_mdl_duration= mdl_duration;
pfs->m_mdl_status= mdl_status;
pfs->m_src_file= src_file;
pfs->m_src_line= src_line;
pfs->m_owner_thread_id= 0;
pfs->m_owner_event_id= 0;
pfs->m_lock.dirty_to_allocated(& dirty_state);
}
return pfs;
}
|
O3
|
cpp
|
create_metadata_lock(void*, MDL_key const*, int, int, int, char const*, unsigned int):
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, -0x38(%rbp)
movl %r8d, -0x2c(%rbp)
movl %ecx, %r12d
movl %edx, %r13d
movq %rsi, %rbx
movq %rdi, %r15
leaq 0x3685f2(%rip), %rdi # 0x399758
leaq -0x30(%rbp), %rsi
callq 0x33bf0
movq %rax, %r14
testq %rax, %rax
je 0x31214
movq %r15, 0x10(%r14)
leaq 0x39c53a(%rip), %rax # 0x3cd6c0
leaq 0x39fa73(%rip), %rcx # 0x3d0c00
movzbl (%rcx), %ecx
xorl %edx, %edx
cmpb $0x0, 0x4(%rax)
cmovnel %ecx, %edx
movl 0x10(%rbp), %r15d
movb %dl, 0x4(%r14)
movb 0x5(%rax), %al
movb %al, 0x5(%r14)
movq %r14, %rdi
addq $0x20, %rdi
leaq 0x8(%rbx), %rsi
movzwl (%rbx), %edx
callq 0x26290
movzwl (%rbx), %eax
movw %ax, 0x18(%r14)
movzwl 0x2(%rbx), %eax
movw %ax, 0x1a(%r14)
movl 0x4(%rbx), %eax
movl %eax, 0x1c(%r14)
movl %r13d, 0x1a4(%r14)
movl %r12d, 0x1a8(%r14)
movl -0x2c(%rbp), %eax
movl %eax, 0x1ac(%r14)
movq -0x38(%rbp), %rax
movq %rax, 0x1b0(%r14)
movl %r15d, 0x1b8(%r14)
xorps %xmm0, %xmm0
movaps %xmm0, 0x1c0(%r14)
movl -0x30(%rbp), %eax
andl $-0x4, %eax
addl $0x6, %eax
xchgl %eax, (%r14)
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
_Z20create_metadata_lockPvPK7MDL_keyiiiPKcj:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov [rbp+var_38], r9
mov [rbp+var_2C], r8d
mov r12d, ecx
mov r13d, edx
mov rbx, rsi
mov r15, rdi
lea rdi, global_mdl_container
lea rsi, [rbp+var_30]
call _ZN29PFS_buffer_scalable_containerI17PFS_metadata_lockLi1024ELi1024E24PFS_buffer_default_arrayIS0_E28PFS_buffer_default_allocatorIS0_EE8allocateEP15pfs_dirty_state; PFS_buffer_scalable_container<PFS_metadata_lock,1024,1024,PFS_buffer_default_array<PFS_metadata_lock>,PFS_buffer_default_allocator<PFS_metadata_lock>>::allocate(pfs_dirty_state *)
mov r14, rax
test rax, rax
jz loc_31214
mov [r14+10h], r15
lea rax, global_metadata_class
lea rcx, flag_global_instrumentation
movzx ecx, byte ptr [rcx]
xor edx, edx
cmp byte ptr [rax+4], 0
cmovnz edx, ecx
mov r15d, [rbp+arg_0]
mov [r14+4], dl
mov al, [rax+5]
mov [r14+5], al
mov rdi, r14
add rdi, 20h ; ' '
lea rsi, [rbx+8]
movzx edx, word ptr [rbx]
call _memcpy
movzx eax, word ptr [rbx]
mov [r14+18h], ax
movzx eax, word ptr [rbx+2]
mov [r14+1Ah], ax
mov eax, [rbx+4]
mov [r14+1Ch], eax
mov [r14+1A4h], r13d
mov [r14+1A8h], r12d
mov eax, [rbp+var_2C]
mov [r14+1ACh], eax
mov rax, [rbp+var_38]
mov [r14+1B0h], rax
mov [r14+1B8h], r15d
xorps xmm0, xmm0
movaps xmmword ptr [r14+1C0h], xmm0
mov eax, [rbp+var_30]
and eax, 0FFFFFFFCh
add eax, 6
xchg eax, [r14]
loc_31214:
mov rax, r14
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long create_metadata_lock(long long a1, unsigned __int16 *a2, int a3, int a4, int a5, long long a6, int a7)
{
long long v9; // rax
long long v10; // r14
char v11; // dl
int v14; // [rsp+10h] [rbp-30h] BYREF
int v15; // [rsp+14h] [rbp-2Ch]
v15 = a5;
v9 = PFS_buffer_scalable_container<PFS_metadata_lock,1024,1024,PFS_buffer_default_array<PFS_metadata_lock>,PFS_buffer_default_allocator<PFS_metadata_lock>>::allocate(
global_mdl_container,
&v14);
v10 = v9;
if ( v9 )
{
*(_QWORD *)(v9 + 16) = a1;
v11 = 0;
if ( *((_BYTE *)&global_metadata_class + 4) )
v11 = flag_global_instrumentation[0];
*(_BYTE *)(v9 + 4) = v11;
*(_BYTE *)(v9 + 5) = *((_BYTE *)&global_metadata_class + 5);
memcpy(v9 + 32, a2 + 4, *a2);
*(_WORD *)(v10 + 24) = *a2;
*(_WORD *)(v10 + 26) = a2[1];
*(_DWORD *)(v10 + 28) = *((_DWORD *)a2 + 1);
*(_DWORD *)(v10 + 420) = a3;
*(_DWORD *)(v10 + 424) = a4;
*(_DWORD *)(v10 + 428) = v15;
*(_QWORD *)(v10 + 432) = a6;
*(_DWORD *)(v10 + 440) = a7;
*(_OWORD *)(v10 + 448) = 0LL;
_InterlockedExchange((volatile __int32 *)v10, (v14 & 0xFFFFFFFC) + 6);
}
return v10;
}
|
create_metadata_lock:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV qword ptr [RBP + -0x38],R9
MOV dword ptr [RBP + -0x2c],R8D
MOV R12D,ECX
MOV R13D,EDX
MOV RBX,RSI
MOV R15,RDI
LEA RDI,[0x499758]
LEA RSI,[RBP + -0x30]
CALL 0x00133bf0
MOV R14,RAX
TEST RAX,RAX
JZ 0x00131214
MOV qword ptr [R14 + 0x10],R15
LEA RAX,[0x4cd6c0]
LEA RCX,[0x4d0c00]
MOVZX ECX,byte ptr [RCX]
XOR EDX,EDX
CMP byte ptr [RAX + 0x4],0x0
CMOVNZ EDX,ECX
MOV R15D,dword ptr [RBP + 0x10]
MOV byte ptr [R14 + 0x4],DL
MOV AL,byte ptr [RAX + 0x5]
MOV byte ptr [R14 + 0x5],AL
MOV RDI,R14
ADD RDI,0x20
LEA RSI,[RBX + 0x8]
MOVZX EDX,word ptr [RBX]
CALL 0x00126290
MOVZX EAX,word ptr [RBX]
MOV word ptr [R14 + 0x18],AX
MOVZX EAX,word ptr [RBX + 0x2]
MOV word ptr [R14 + 0x1a],AX
MOV EAX,dword ptr [RBX + 0x4]
MOV dword ptr [R14 + 0x1c],EAX
MOV dword ptr [R14 + 0x1a4],R13D
MOV dword ptr [R14 + 0x1a8],R12D
MOV EAX,dword ptr [RBP + -0x2c]
MOV dword ptr [R14 + 0x1ac],EAX
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [R14 + 0x1b0],RAX
MOV dword ptr [R14 + 0x1b8],R15D
XORPS XMM0,XMM0
MOVAPS xmmword ptr [R14 + 0x1c0],XMM0
MOV EAX,dword ptr [RBP + -0x30]
AND EAX,0xfffffffc
ADD EAX,0x6
XCHG dword ptr [R14],EAX
LAB_00131214:
MOV RAX,R14
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* create_metadata_lock(void*, MDL_key const*, int, int, int, char const*, unsigned int) */
int * create_metadata_lock
(void *param_1,MDL_key *param_2,int param_3,int param_4,int param_5,char *param_6,
uint param_7)
{
int *piVar1;
int1 uVar2;
uint local_38;
int local_34;
local_34 = param_5;
piVar1 = (int *)PFS_buffer_scalable_container<PFS_metadata_lock,1024,1024,PFS_buffer_default_array<PFS_metadata_lock>,PFS_buffer_default_allocator<PFS_metadata_lock>>
::allocate((PFS_buffer_scalable_container<PFS_metadata_lock,1024,1024,PFS_buffer_default_array<PFS_metadata_lock>,PFS_buffer_default_allocator<PFS_metadata_lock>>
*)global_mdl_container,(pfs_dirty_state *)&local_38);
if (piVar1 != (int *)0x0) {
*(void **)(piVar1 + 4) = param_1;
uVar2 = 0;
if (global_metadata_class[4] != '\0') {
uVar2 = flag_global_instrumentation;
}
*(int1 *)(piVar1 + 1) = uVar2;
*(int1 *)((long)piVar1 + 5) = global_metadata_class[5];
memcpy(piVar1 + 8,param_2 + 8,(ulong)*(ushort *)param_2);
*(int2 *)(piVar1 + 6) = *(int2 *)param_2;
*(int2 *)((long)piVar1 + 0x1a) = *(int2 *)(param_2 + 2);
piVar1[7] = *(int *)(param_2 + 4);
piVar1[0x69] = param_3;
piVar1[0x6a] = param_4;
piVar1[0x6b] = local_34;
*(char **)(piVar1 + 0x6c) = param_6;
piVar1[0x6e] = param_7;
piVar1[0x70] = 0;
piVar1[0x71] = 0;
piVar1[0x72] = 0;
piVar1[0x73] = 0;
LOCK();
*piVar1 = (local_38 & 0xfffffffc) + 6;
UNLOCK();
}
return piVar1;
}
|
|
19,987
|
inline_mysql_file_chsize
|
eloqsql/include/mysql/psi/mysql_file.h
|
static inline int
inline_mysql_file_chsize(
#ifdef HAVE_PSI_FILE_INTERFACE
const char *src_file, uint src_line,
#endif
File file, my_off_t newlength, int filler, myf flags)
{
int result;
#ifdef HAVE_PSI_FILE_INTERFACE
struct PSI_file_locker *locker;
PSI_file_locker_state state;
locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_CHSIZE);
if (psi_likely(locker != NULL))
{
PSI_FILE_CALL(start_file_wait)(locker, (size_t) newlength, src_file,
src_line);
result= my_chsize(file, newlength, filler, flags);
PSI_FILE_CALL(end_file_wait)(locker, (size_t) newlength);
return result;
}
#endif
result= my_chsize(file, newlength, filler, flags);
return result;
}
|
O0
|
c
|
inline_mysql_file_chsize:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl %r8d, -0x24(%rbp)
movq %r9, -0x30(%rbp)
leaq 0x231be0(%rip), %rax # 0x2c8038
movq (%rax), %rax
movq 0x158(%rax), %rax
movl -0x18(%rbp), %esi
leaq -0x88(%rbp), %rdi
movl $0xd, %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 0x964f2
leaq 0x231b9a(%rip), %rax # 0x2c8038
movq (%rax), %rax
movq 0x210(%rax), %rax
movq -0x40(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x10(%rbp), %rdx
movl -0x14(%rbp), %ecx
callq *%rax
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
movl -0x24(%rbp), %edx
movq -0x30(%rbp), %rcx
callq 0xf7000
movl %eax, -0x34(%rbp)
leaq 0x231b62(%rip), %rax # 0x2c8038
movq (%rax), %rax
movq 0x218(%rax), %rax
movq -0x40(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq *%rax
movl -0x34(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x9650e
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
movl -0x24(%rbp), %edx
movq -0x30(%rbp), %rcx
callq 0xf7000
movl %eax, -0x34(%rbp)
movl -0x34(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x90, %rsp
popq %rbp
retq
nopw (%rax,%rax)
|
inline_mysql_file_chsize_2:
push rbp
mov rbp, rsp
sub rsp, 90h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov [rbp+var_20], rcx
mov [rbp+var_24], r8d
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, 0Dh
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 short loc_964F2
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+210h]
mov rdi, [rbp+var_40]
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_10]
mov ecx, [rbp+var_14]
call rax
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
mov edx, [rbp+var_24]
mov rcx, [rbp+var_30]
call my_chsize
mov [rbp+var_34], eax
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+218h]
mov rdi, [rbp+var_40]
mov rsi, [rbp+var_20]
call rax
mov eax, [rbp+var_34]
mov [rbp+var_4], eax
jmp short loc_9650E
loc_964F2:
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
mov edx, [rbp+var_24]
mov rcx, [rbp+var_30]
call my_chsize
mov [rbp+var_34], eax
mov eax, [rbp+var_34]
mov [rbp+var_4], eax
loc_9650E:
mov eax, [rbp+var_4]
add rsp, 90h
pop rbp
retn
|
long long inline_mysql_file_chsize_2(
long long a1,
unsigned int a2,
unsigned int a3,
long long a4,
unsigned int a5,
long long a6)
{
_BYTE v7[72]; // [rsp+8h] [rbp-88h] BYREF
long long v8; // [rsp+50h] [rbp-40h]
unsigned int v9; // [rsp+5Ch] [rbp-34h]
long long v10; // [rsp+60h] [rbp-30h]
unsigned int v11; // [rsp+6Ch] [rbp-24h]
long long v12; // [rsp+70h] [rbp-20h]
unsigned int v13; // [rsp+78h] [rbp-18h]
unsigned int v14; // [rsp+7Ch] [rbp-14h]
long long v15; // [rsp+80h] [rbp-10h]
v15 = a1;
v14 = a2;
v13 = a3;
v12 = a4;
v11 = a5;
v10 = a6;
v8 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v7, a3, 13LL);
if ( v8 )
{
((void ( *)(long long, long long, long long, _QWORD))PSI_server[66])(v8, v12, v15, v14);
v9 = my_chsize(v13, v12, v11, v10);
((void ( *)(long long, long long))PSI_server[67])(v8, v12);
}
else
{
return (unsigned int)my_chsize(v13, v12, v11, v10);
}
return v9;
}
|
inline_mysql_file_chsize:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
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 dword ptr [RBP + -0x24],R8D
MOV qword ptr [RBP + -0x30],R9
LEA RAX,[0x3c8038]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x158]
MOV ESI,dword ptr [RBP + -0x18]
LEA RDI,[RBP + -0x88]
MOV EDX,0xd
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 0x001964f2
LEA RAX,[0x3c8038]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x210]
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x20]
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 EDX,dword ptr [RBP + -0x24]
MOV RCX,qword ptr [RBP + -0x30]
CALL 0x001f7000
MOV dword ptr [RBP + -0x34],EAX
LEA RAX,[0x3c8038]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x218]
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x20]
CALL RAX
MOV EAX,dword ptr [RBP + -0x34]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0019650e
LAB_001964f2:
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
MOV EDX,dword ptr [RBP + -0x24]
MOV RCX,qword ptr [RBP + -0x30]
CALL 0x001f7000
MOV dword ptr [RBP + -0x34],EAX
MOV EAX,dword ptr [RBP + -0x34]
MOV dword ptr [RBP + -0x4],EAX
LAB_0019650e:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x90
POP RBP
RET
|
int4
inline_mysql_file_chsize
(int8 param_1,int4 param_2,int4 param_3,int8 param_4,
int4 param_5,int8 param_6)
{
int1 local_90 [72];
long local_48;
int4 local_3c;
int8 local_38;
int4 local_2c;
int8 local_28;
int4 local_20;
int4 local_1c;
int8 local_18;
int4 local_c;
local_38 = param_6;
local_2c = 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,0xd);
if (local_48 == 0) {
local_c = my_chsize(local_20,local_28,local_2c,local_38);
}
else {
(**(code **)(PSI_server + 0x210))(local_48,local_28,local_18,local_1c);
local_3c = my_chsize(local_20,local_28,local_2c,local_38);
(**(code **)(PSI_server + 0x218))(local_48,local_28);
local_c = local_3c;
}
return local_c;
}
|
|
19,988
|
SchemaConverter::_add_primitive(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, BuiltinRule const&)
|
llama.cpp/common/json-schema-to-grammar.cpp
|
std::string _add_primitive(const std::string & name, const BuiltinRule & rule) {
auto n = _add_rule(name, rule.content);
for (const auto & dep : rule.deps) {
BuiltinRule dep_rule;
auto it = PRIMITIVE_RULES.find(dep);
if (it == PRIMITIVE_RULES.end()) {
it = STRING_FORMAT_RULES.find(dep);
if (it == STRING_FORMAT_RULES.end()) {
_errors.push_back("Rule " + dep + " not known");
continue;
}
}
if (_rules.find(dep) == _rules.end()) {
_add_primitive(dep, it->second);
}
}
return n;
}
|
O3
|
cpp
|
SchemaConverter::_add_primitive(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, BuiltinRule const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %rcx, %rbx
movq %rsi, %r14
movq %rdi, 0x8(%rsp)
callq 0xbc332
movq 0x20(%rbx), %r15
movq 0x28(%rbx), %rbx
cmpq %rbx, %r15
je 0xc1899
leaq 0x80(%rsp), %rbp
leaq 0x90(%rsp), %r13
leaq 0x28(%r14), %rax
movq %rax, 0x48(%rsp)
leaq 0x30(%r14), %rax
movq %rax, 0x40(%rsp)
leaq 0xc8(%r14), %rax
movq %rax, 0x38(%rsp)
movq %r14, 0x30(%rsp)
movq %rbp, 0x70(%rsp)
xorl %eax, %eax
movq %rax, 0x78(%rsp)
movb $0x0, 0x80(%rsp)
movq %rax, 0x10(%r13)
xorps %xmm0, %xmm0
movups %xmm0, (%r13)
leaq 0x4ae92(%rip), %rdi # 0x10c5a8
movq %r15, %rsi
callq 0xc6da6
movq %rax, %r12
testq %rax, %rax
jne 0xc173d
leaq 0x4aeb3(%rip), %rdi # 0x10c5e0
movq %r15, %rsi
callq 0xc6da6
movq %rax, %r12
testq %rax, %rax
je 0xc1795
movq 0x48(%rsp), %rdi
movq %r15, %rsi
callq 0xbca46
cmpq 0x40(%rsp), %rax
jne 0xc186a
addq $0x28, %r12
leaq 0xa8(%rsp), %rdi
movq %r14, %rsi
movq %r15, %rdx
movq %r12, %rcx
callq 0xc168a
movq 0xa8(%rsp), %rdi
leaq 0xb8(%rsp), %rax
cmpq %rax, %rdi
je 0xc186a
movq 0xb8(%rsp), %rsi
jmp 0xc1862
leaq 0x50(%rsp), %r12
movq %r12, %rdi
leaq 0x18baf(%rip), %rsi # 0xda353
movq %r15, %rdx
callq 0x26a4e
movq %r12, %rdi
leaq 0x18ba3(%rip), %rsi # 0xda359
callq 0x1d920
movq %rax, %r12
leaq 0x20(%rsp), %rdi
movq %rdi, 0x10(%rsp)
movq (%rax), %rax
movq %r12, %r14
addq $0x10, %r14
cmpq %r14, %rax
je 0xc17ed
movq %rax, 0x10(%rsp)
movq 0x10(%r12), %rax
movq %rax, 0x20(%rsp)
movq 0x8(%r12), %rbp
jmp 0xc17fe
movq 0x8(%r12), %rbp
leaq 0x1(%rbp), %rdx
movq %r14, %rsi
callq 0x1d0c0
movq %rbp, 0x18(%rsp)
movq %r14, (%r12)
movq $0x0, 0x8(%r12)
movb $0x0, 0x10(%r12)
movq 0x38(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x56354
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
movq 0x30(%rsp), %r14
leaq 0x80(%rsp), %rbp
je 0xc184e
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x1d160
movq 0x50(%rsp), %rdi
leaq 0x60(%rsp), %rax
cmpq %rax, %rdi
je 0xc186a
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x1d160
movq %r13, %rdi
callq 0x23764
movq 0x70(%rsp), %rdi
cmpq %rbp, %rdi
je 0xc188c
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x1d160
addq $0x20, %r15
cmpq %rbx, %r15
jne 0xc16ef
movq 0x8(%rsp), %rax
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0xc18d4
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x1d160
jmp 0xc18d4
movq %rax, %rbx
movq 0x50(%rsp), %rdi
leaq 0x60(%rsp), %rax
cmpq %rax, %rdi
je 0xc18fb
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x1d160
jmp 0xc18fb
jmp 0xc18f8
jmp 0xc18f8
jmp 0xc18f8
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
callq 0xba86c
movq 0x8(%rsp), %rcx
movq (%rcx), %rdi
addq $0x10, %rcx
cmpq %rcx, %rdi
je 0xc1921
movq (%rcx), %rsi
incq %rsi
callq 0x1d160
movq %rbx, %rdi
callq 0x1d8e0
nop
|
_ZN15SchemaConverter14_add_primitiveERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERK11BuiltinRule:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0C8h
mov rbx, rcx
mov r14, rsi
mov [rsp+0F8h+var_F0], rdi; void *
call _ZN15SchemaConverter9_add_ruleERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_; SchemaConverter::_add_rule(std::string const&,std::string const&)
mov r15, [rbx+20h]
mov rbx, [rbx+28h]
cmp r15, rbx
jz loc_C1899
lea rbp, [rsp+0F8h+var_78]
lea r13, [rsp+0F8h+var_68]
lea rax, [r14+28h]
mov [rsp+0F8h+var_B0], rax; void *
lea rax, [r14+30h]
mov qword ptr [rsp+0F8h+var_B8], rax; int
lea rax, [r14+0C8h]
mov qword ptr [rsp+0F8h+var_C0], rax; int
mov qword ptr [rsp+0F8h+var_C8], r14; int
loc_C16EF:
mov [rsp+0F8h+var_88], rbp
xor eax, eax
mov [rsp+0F8h+var_80], rax
mov byte ptr [rsp+0F8h+var_78], 0
mov [r13+10h], rax
xorps xmm0, xmm0
movups xmmword ptr [r13+0], xmm0
lea rdi, _Z15PRIMITIVE_RULESB5cxx11; PRIMITIVE_RULES
mov rsi, r15
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_11BuiltinRuleESaIS9_ENSt8__detail10_Select1stESt8equal_toIS5_ESt4hashIS5_ENSB_18_Mod_range_hashingENSB_20_Default_ranged_hashENSB_20_Prime_rehash_policyENSB_17_Hashtable_traitsILb1ELb0ELb1EEEE4findERS7_; std::_Hashtable<std::string,std::pair<std::string const,BuiltinRule>,std::allocator<std::pair<std::string const,BuiltinRule>>,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 r12, rax
test rax, rax
jnz short loc_C173D
lea rdi, _Z19STRING_FORMAT_RULESB5cxx11; STRING_FORMAT_RULES
mov rsi, r15
call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_11BuiltinRuleESaIS9_ENSt8__detail10_Select1stESt8equal_toIS5_ESt4hashIS5_ENSB_18_Mod_range_hashingENSB_20_Default_ranged_hashENSB_20_Prime_rehash_policyENSB_17_Hashtable_traitsILb1ELb0ELb1EEEE4findERS7_; std::_Hashtable<std::string,std::pair<std::string const,BuiltinRule>,std::allocator<std::pair<std::string const,BuiltinRule>>,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 r12, rax
test rax, rax
jz short loc_C1795
loc_C173D:
mov rdi, [rsp+0F8h+var_B0]
mov rsi, r15
call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_S5_ESt10_Select1stIS8_ESt4lessIS5_ESaIS8_EE4findERS7_; std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::find(std::string const&)
cmp rax, qword ptr [rsp+0F8h+var_B8]
jnz loc_C186A
add r12, 28h ; '('
lea rdi, [rsp+0F8h+var_50]; int
mov rsi, r14; int
mov rdx, r15; int
mov rcx, r12; int
call _ZN15SchemaConverter14_add_primitiveERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERK11BuiltinRule; SchemaConverter::_add_primitive(std::string const&,BuiltinRule const&)
mov rdi, qword ptr [rsp+0F8h+var_50]
lea rax, [rsp+0F8h+var_40]
cmp rdi, rax
jz loc_C186A
mov rsi, [rsp+0F8h+var_40]
jmp loc_C1862
loc_C1795:
lea r12, [rsp+0F8h+var_A8]
mov rdi, r12
lea rsi, aRule; "Rule "
mov rdx, r15
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
mov rdi, r12
lea rsi, aNotKnown; " not known"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov r12, rax
lea rdi, [rsp+0F8h+var_D8]
mov [rsp+0F8h+var_E8], rdi
mov rax, [rax]
mov r14, r12
add r14, 10h
cmp rax, r14
jz short loc_C17ED
mov [rsp+0F8h+var_E8], rax
mov rax, [r12+10h]
mov [rsp+0F8h+var_D8], rax
mov rbp, [r12+8]
jmp short loc_C17FE
loc_C17ED:
mov rbp, [r12+8]
lea rdx, [rbp+1]
mov rsi, r14
call _memcpy
loc_C17FE:
mov [rsp+0F8h+var_E0], rbp
mov [r12], r14
mov qword ptr [r12+8], 0
mov byte ptr [r12+10h], 0
mov rdi, qword ptr [rsp+0F8h+var_C0]
lea rsi, [rsp+0F8h+var_E8]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&)
mov rdi, [rsp+0F8h+var_E8]; void *
lea rax, [rsp+0F8h+var_D8]
cmp rdi, rax
mov r14, qword ptr [rsp+0F8h+var_C8]
lea rbp, [rsp+0F8h+var_78]
jz short loc_C184E
mov rsi, [rsp+0F8h+var_D8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_C184E:
mov rdi, [rsp+0F8h+var_A8]; void *
lea rax, [rsp+0F8h+var_98]
cmp rdi, rax
jz short loc_C186A
mov rsi, [rsp+0F8h+var_98]
loc_C1862:
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_C186A:
mov rdi, r13
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, [rsp+0F8h+var_88]; void *
cmp rdi, rbp
jz short loc_C188C
mov rsi, [rsp+0F8h+var_78]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_C188C:
add r15, 20h ; ' '
cmp r15, rbx
jnz loc_C16EF
loc_C1899:
mov rax, [rsp+0F8h+var_F0]
add rsp, 0C8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
mov rdi, [rsp+arg_8]; void *
lea rax, [rsp+arg_18]
cmp rdi, rax
jz short loc_C18D4
mov rsi, [rsp+arg_18]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_C18D4
mov rbx, rax
loc_C18D4:
mov rdi, [rsp+arg_48]; void *
lea rax, [rsp+arg_58]
cmp rdi, rax
jz short loc_C18FB
mov rsi, [rsp+arg_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_C18FB
jmp short loc_C18F8
jmp short loc_C18F8
jmp short $+2
loc_C18F8:
mov rbx, rax
loc_C18FB:
lea rdi, [rsp+arg_68]; this
call _ZN11BuiltinRuleD2Ev; BuiltinRule::~BuiltinRule()
mov rcx, [rsp+arg_0]
mov rdi, [rcx]; void *
add rcx, 10h
cmp rdi, rcx
jz short loc_C1921
mov rsi, [rcx]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_C1921:
mov rdi, rbx
call __Unwind_Resume
|
void ** SchemaConverter::_add_primitive(void **a1, long long a2, long long a3, _QWORD *a4)
{
int v5; // r14d
_QWORD *v6; // r15
_QWORD *v7; // rbx
long long v8; // rax
int v9; // r12d
long long v10; // rax
long long v11; // rax
int v12; // r8d
int v13; // r9d
void *v14; // rdi
long long v15; // rsi
long long v16; // r12
long long v17; // rbp
long long v19; // [rsp+0h] [rbp-F8h]
void **v20; // [rsp+8h] [rbp-F0h]
void *v21; // [rsp+10h] [rbp-E8h] BYREF
long long v22; // [rsp+18h] [rbp-E0h]
long long v23; // [rsp+20h] [rbp-D8h] BYREF
int v24; // [rsp+28h] [rbp-D0h]
int v25[2]; // [rsp+30h] [rbp-C8h]
int v26[2]; // [rsp+38h] [rbp-C0h]
int v27[2]; // [rsp+40h] [rbp-B8h]
void *v28; // [rsp+48h] [rbp-B0h]
void *v29[2]; // [rsp+50h] [rbp-A8h] BYREF
long long v30; // [rsp+60h] [rbp-98h] BYREF
char v31; // [rsp+68h] [rbp-90h]
void *v32; // [rsp+70h] [rbp-88h]
long long v33; // [rsp+78h] [rbp-80h]
_QWORD v34[2]; // [rsp+80h] [rbp-78h] BYREF
__int128 v35; // [rsp+90h] [rbp-68h] BYREF
long long v36; // [rsp+A0h] [rbp-58h]
int v37[2]; // [rsp+A8h] [rbp-50h] BYREF
long long v38; // [rsp+B8h] [rbp-40h] BYREF
v5 = a2;
v20 = a1;
SchemaConverter::_add_rule(a1, a2, a3, a4);
v6 = (_QWORD *)a4[4];
v7 = (_QWORD *)a4[5];
if ( v6 != v7 )
{
v28 = (void *)(a2 + 40);
*(_QWORD *)v27 = a2 + 48;
*(_QWORD *)v26 = a2 + 200;
*(_QWORD *)v25 = a2;
do
{
v32 = v34;
v33 = 0LL;
LOBYTE(v34[0]) = 0;
v36 = 0LL;
v35 = 0LL;
v8 = std::_Hashtable<std::string,std::pair<std::string const,BuiltinRule>,std::allocator<std::pair<std::string const,BuiltinRule>>,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(
PRIMITIVE_RULES[abi:cxx11],
v6);
v9 = v8;
if ( v8
|| (v10 = std::_Hashtable<std::string,std::pair<std::string const,BuiltinRule>,std::allocator<std::pair<std::string const,BuiltinRule>>,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(
STRING_FORMAT_RULES[abi:cxx11],
v6),
v9 = v10,
v10) )
{
v11 = std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::find(
(long long)v28,
(long long)v6);
if ( v11 != *(_QWORD *)v27 )
goto LABEL_16;
SchemaConverter::_add_primitive(
(int)v37,
v5,
(int)v6,
v9 + 40,
v12,
v13,
v19,
v20,
(int)v21,
v22,
v23,
v24,
v25[0],
v26[0],
v27[0],
v28,
(int)v29[0],
(long long)v29[1],
v30,
v31);
v14 = *(void **)v37;
if ( *(long long **)v37 == &v38 )
goto LABEL_16;
v15 = v38;
}
else
{
std::operator+<char>((long long)v29, (long long)"Rule ", v6);
v16 = std::string::append(v29, " not known");
v21 = &v23;
if ( *(_QWORD *)v16 == v16 + 16 )
{
v17 = *(_QWORD *)(v16 + 8);
memcpy(&v23, v16 + 16, v17 + 1);
}
else
{
v21 = *(void **)v16;
v23 = *(_QWORD *)(v16 + 16);
v17 = *(_QWORD *)(v16 + 8);
}
v22 = v17;
*(_QWORD *)v16 = v16 + 16;
*(_QWORD *)(v16 + 8) = 0LL;
*(_BYTE *)(v16 + 16) = 0;
std::vector<std::string>::emplace_back<std::string>(*(long long *)v26, &v21);
v5 = v25[0];
if ( v21 != &v23 )
operator delete(v21, v23 + 1);
v14 = v29[0];
if ( v29[0] == &v30 )
goto LABEL_16;
v15 = v30;
}
operator delete(v14, v15 + 1);
LABEL_16:
std::vector<std::string>::~vector((long long)&v35);
if ( v32 != v34 )
operator delete(v32, v34[0] + 1LL);
v6 += 4;
}
while ( v6 != v7 );
}
return v20;
}
|
_add_primitive:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xc8
MOV RBX,RCX
MOV R14,RSI
MOV qword ptr [RSP + 0x8],RDI
CALL 0x001bc332
MOV R15,qword ptr [RBX + 0x20]
MOV RBX,qword ptr [RBX + 0x28]
CMP R15,RBX
JZ 0x001c1899
LEA RBP,[RSP + 0x80]
LEA R13,[RSP + 0x90]
LEA RAX,[R14 + 0x28]
MOV qword ptr [RSP + 0x48],RAX
LEA RAX,[R14 + 0x30]
MOV qword ptr [RSP + 0x40],RAX
LEA RAX,[R14 + 0xc8]
MOV qword ptr [RSP + 0x38],RAX
MOV qword ptr [RSP + 0x30],R14
LAB_001c16ef:
MOV qword ptr [RSP + 0x70],RBP
XOR EAX,EAX
MOV qword ptr [RSP + 0x78],RAX
MOV byte ptr [RSP + 0x80],0x0
MOV qword ptr [R13 + 0x10],RAX
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R13],XMM0
LAB_001c170f:
LEA RDI,[0x20c5a8]
MOV RSI,R15
CALL 0x001c6da6
MOV R12,RAX
TEST RAX,RAX
JNZ 0x001c173d
LAB_001c1726:
LEA RDI,[0x20c5e0]
MOV RSI,R15
CALL 0x001c6da6
MOV R12,RAX
TEST RAX,RAX
JZ 0x001c1795
LAB_001c173d:
MOV RDI,qword ptr [RSP + 0x48]
MOV RSI,R15
CALL 0x001bca46
CMP RAX,qword ptr [RSP + 0x40]
JNZ 0x001c186a
ADD R12,0x28
LAB_001c1759:
LEA RDI,[RSP + 0xa8]
MOV RSI,R14
MOV RDX,R15
MOV RCX,R12
CALL 0x001c168a
MOV RDI,qword ptr [RSP + 0xa8]
LEA RAX,[RSP + 0xb8]
CMP RDI,RAX
JZ 0x001c186a
MOV RSI,qword ptr [RSP + 0xb8]
JMP 0x001c1862
LAB_001c1795:
LEA R12,[RSP + 0x50]
MOV RDI,R12
LEA RSI,[0x1da353]
MOV RDX,R15
CALL 0x00126a4e
LAB_001c17ac:
MOV RDI,R12
LEA RSI,[0x1da359]
CALL 0x0011d920
LAB_001c17bb:
MOV R12,RAX
LEA RDI,[RSP + 0x20]
MOV qword ptr [RSP + 0x10],RDI
MOV RAX,qword ptr [RAX]
MOV R14,R12
ADD R14,0x10
CMP RAX,R14
JZ 0x001c17ed
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [R12 + 0x10]
MOV qword ptr [RSP + 0x20],RAX
MOV RBP,qword ptr [R12 + 0x8]
JMP 0x001c17fe
LAB_001c17ed:
MOV RBP,qword ptr [R12 + 0x8]
LEA RDX,[RBP + 0x1]
MOV RSI,R14
CALL 0x0011d0c0
LAB_001c17fe:
MOV qword ptr [RSP + 0x18],RBP
MOV qword ptr [R12],R14
MOV qword ptr [R12 + 0x8],0x0
MOV byte ptr [R12 + 0x10],0x0
LAB_001c1816:
MOV RDI,qword ptr [RSP + 0x38]
LEA RSI,[RSP + 0x10]
CALL 0x00156354
LAB_001c1825:
MOV RDI,qword ptr [RSP + 0x10]
LEA RAX,[RSP + 0x20]
CMP RDI,RAX
MOV R14,qword ptr [RSP + 0x30]
LEA RBP,[RSP + 0x80]
JZ 0x001c184e
MOV RSI,qword ptr [RSP + 0x20]
INC RSI
CALL 0x0011d160
LAB_001c184e:
MOV RDI,qword ptr [RSP + 0x50]
LEA RAX,[RSP + 0x60]
CMP RDI,RAX
JZ 0x001c186a
MOV RSI,qword ptr [RSP + 0x60]
LAB_001c1862:
INC RSI
CALL 0x0011d160
LAB_001c186a:
MOV RDI,R13
CALL 0x00123764
MOV RDI,qword ptr [RSP + 0x70]
CMP RDI,RBP
JZ 0x001c188c
MOV RSI,qword ptr [RSP + 0x80]
INC RSI
CALL 0x0011d160
LAB_001c188c:
ADD R15,0x20
CMP R15,RBX
JNZ 0x001c16ef
LAB_001c1899:
MOV RAX,qword ptr [RSP + 0x8]
ADD RSP,0xc8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* SchemaConverter::_add_primitive(std::__cxx11::string const&, BuiltinRule const&) */
string * SchemaConverter::_add_primitive(string *param_1,BuiltinRule *param_2)
{
string *psVar1;
long lVar2;
BuiltinRule *pBVar3;
int8 *puVar4;
long in_RCX;
long *plVar5;
string *psVar6;
long *local_e8;
long local_e0;
long local_d8 [2];
BuiltinRule *local_c8;
BuiltinRule *local_c0;
BuiltinRule *local_b8;
BuiltinRule *local_b0;
long *local_a8 [2];
long local_98 [2];
int1 *local_88;
int8 local_80;
int1 local_78;
int7 uStack_77;
int8 local_68;
int8 uStack_60;
int8 local_58;
long *local_50 [2];
long local_40 [2];
_add_rule(param_1,(string *)param_2);
psVar6 = *(string **)(in_RCX + 0x20);
psVar1 = *(string **)(in_RCX + 0x28);
if (psVar6 != psVar1) {
local_b0 = param_2 + 0x28;
local_b8 = param_2 + 0x30;
local_c0 = param_2 + 200;
local_c8 = param_2;
do {
local_88 = &local_78;
local_80 = 0;
local_78 = 0;
local_58 = 0;
local_68 = 0;
uStack_60 = 0;
/* try { // try from 001c170f to 001c171d has its CatchHandler @ 001c18f8 */
lVar2 = std::
_Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,BuiltinRule>,std::allocator<std::pair<std::__cxx11::string_const,BuiltinRule>>,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,BuiltinRule>,std::allocator<std::pair<std::__cxx11::string_const,BuiltinRule>>,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>>
*)PRIMITIVE_RULES_abi_cxx11_,psVar6);
/* try { // try from 001c1726 to 001c1734 has its CatchHandler @ 001c18f4 */
if ((lVar2 == 0) &&
(lVar2 = std::
_Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,BuiltinRule>,std::allocator<std::pair<std::__cxx11::string_const,BuiltinRule>>,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,BuiltinRule>,std::allocator<std::pair<std::__cxx11::string_const,BuiltinRule>>,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>>
*)STRING_FORMAT_RULES_abi_cxx11_,psVar6), lVar2 == 0)) {
/* try { // try from 001c1795 to 001c17ab has its CatchHandler @ 001c18f2 */
std::operator+((char *)local_a8,(string *)"Rule ");
/* try { // try from 001c17ac to 001c17ba has its CatchHandler @ 001c18d1 */
puVar4 = (int8 *)std::__cxx11::string::append((char *)local_a8);
local_e8 = local_d8;
plVar5 = puVar4 + 2;
if ((long *)*puVar4 == plVar5) {
lVar2 = puVar4[1];
memcpy(local_e8,plVar5,lVar2 + 1);
}
else {
local_d8[0] = puVar4[2];
lVar2 = puVar4[1];
local_e8 = (long *)*puVar4;
}
*puVar4 = plVar5;
puVar4[1] = 0;
*(int1 *)(puVar4 + 2) = 0;
/* try { // try from 001c1816 to 001c1824 has its CatchHandler @ 001c18b0 */
local_e0 = lVar2;
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<std::__cxx11::string>
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_c0,
(string *)&local_e8);
param_2 = local_c8;
if (local_e8 != local_d8) {
operator_delete(local_e8,local_d8[0] + 1);
}
lVar2 = local_98[0];
plVar5 = local_a8[0];
if (local_a8[0] != local_98) {
LAB_001c1862:
operator_delete(plVar5,lVar2 + 1);
}
}
else {
/* try { // try from 001c173d to 001c1749 has its CatchHandler @ 001c18f6 */
pBVar3 = (BuiltinRule *)
std::
_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
::find((_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
*)local_b0,psVar6);
/* try { // try from 001c1759 to 001c176e has its CatchHandler @ 001c18f8 */
if ((pBVar3 == local_b8) &&
(_add_primitive((string *)local_50,param_2), lVar2 = local_40[0], plVar5 = local_50[0],
local_50[0] != local_40)) goto LAB_001c1862;
}
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)&local_68);
if (local_88 != &local_78) {
operator_delete(local_88,CONCAT71(uStack_77,local_78) + 1);
}
psVar6 = psVar6 + 0x20;
} while (psVar6 != psVar1);
}
return param_1;
}
|
|
19,989
|
spdlog::details::backtracer::backtracer(spdlog::details::backtracer&&)
|
AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/details/backtracer-inl.h
|
SPDLOG_INLINE backtracer::backtracer(backtracer &&other) SPDLOG_NOEXCEPT {
std::lock_guard<std::mutex> lock(other.mutex_);
enabled_ = other.enabled();
messages_ = std::move(other.messages_);
}
|
O0
|
c
|
spdlog::details::backtracer::backtracer(spdlog::details::backtracer&&):
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x38970
movq 0x8(%rsp), %rdi
addq $0x28, %rdi
xorl %esi, %esi
callq 0x38980
movq 0x8(%rsp), %rdi
addq $0x30, %rdi
callq 0x389b0
movq 0x18(%rsp), %rsi
leaq 0x10(%rsp), %rdi
callq 0x389f0
jmp 0x31b9c
movq 0x18(%rsp), %rdi
callq 0x31b30
movb %al, 0x7(%rsp)
jmp 0x31bac
movq 0x8(%rsp), %rdi
movb 0x7(%rsp), %al
addq $0x28, %rdi
movzbl %al, %esi
andl $0x1, %esi
callq 0x38a20
movq 0x8(%rsp), %rdi
movq 0x18(%rsp), %rsi
addq $0x30, %rsi
addq $0x30, %rdi
callq 0x38af0
leaq 0x10(%rsp), %rdi
callq 0x38ab0
addq $0x28, %rsp
retq
movq %rax, %rdi
callq 0x1b6b0
nopw %cs:(%rax,%rax)
|
_ZN6spdlog7details10backtracerC2EOS1_:
sub rsp, 28h
mov [rsp+28h+var_8], rdi
mov [rsp+28h+var_10], rsi
mov rdi, [rsp+28h+var_8]; this
mov [rsp+28h+var_20], rdi
call _ZNSt5mutexC2Ev; std::mutex::mutex(void)
mov rdi, [rsp+28h+var_20]
add rdi, 28h ; '('
xor esi, esi
call _ZNSt6atomicIbEC2Eb; std::atomic<bool>::atomic(bool)
mov rdi, [rsp+28h+var_20]
add rdi, 30h ; '0'
call _ZN6spdlog7details10circular_qINS0_14log_msg_bufferEEC2Ev; spdlog::details::circular_q<spdlog::details::log_msg_buffer>::circular_q(void)
mov rsi, [rsp+28h+var_10]
lea rdi, [rsp+28h+var_18]
call _ZNSt10lock_guardISt5mutexEC2ERS0_; std::lock_guard<std::mutex>::lock_guard(std::mutex&)
jmp short $+2
loc_31B9C:
mov rdi, [rsp+28h+var_10]; this
call _ZNK6spdlog7details10backtracer7enabledEv; spdlog::details::backtracer::enabled(void)
mov [rsp+28h+var_21], al
jmp short $+2
loc_31BAC:
mov rdi, [rsp+28h+var_20]
mov al, [rsp+28h+var_21]
add rdi, 28h ; '('
movzx esi, al
and esi, 1
call _ZNSt6atomicIbEaSEb; std::atomic<bool>::operator=(bool)
mov rdi, [rsp+28h+var_20]
mov rsi, [rsp+28h+var_10]
add rsi, 30h ; '0'
add rdi, 30h ; '0'
call _ZN6spdlog7details10circular_qINS0_14log_msg_bufferEEaSEOS3_; spdlog::details::circular_q<spdlog::details::log_msg_buffer>::operator=(spdlog::details::circular_q<spdlog::details::log_msg_buffer>&&)
lea rdi, [rsp+28h+var_18]
call _ZNSt10lock_guardISt5mutexED2Ev; std::lock_guard<std::mutex>::~lock_guard()
add rsp, 28h
retn
mov rdi, rax
call __clang_call_terminate
|
long long spdlog::details::backtracer::backtracer(std::mutex *a1, spdlog::details::backtracer *a2)
{
char v3; // [rsp+7h] [rbp-21h]
_BYTE v4[8]; // [rsp+10h] [rbp-18h] BYREF
spdlog::details::backtracer *v5; // [rsp+18h] [rbp-10h]
std::mutex *v6; // [rsp+20h] [rbp-8h]
v6 = a1;
v5 = a2;
std::mutex::mutex(a1);
std::atomic<bool>::atomic((char *)a1 + 40, 0LL);
spdlog::details::circular_q<spdlog::details::log_msg_buffer>::circular_q((char *)a1 + 48);
std::lock_guard<std::mutex>::lock_guard(v4, a2);
v3 = spdlog::details::backtracer::enabled(v5);
std::atomic<bool>::operator=((char *)a1 + 40, v3 & 1);
spdlog::details::circular_q<spdlog::details::log_msg_buffer>::operator=((char *)a1 + 48, (char *)v5 + 48);
return std::lock_guard<std::mutex>::~lock_guard(v4);
}
|
backtracer:
SUB RSP,0x28
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x18],RSI
MOV RDI,qword ptr [RSP + 0x20]
MOV qword ptr [RSP + 0x8],RDI
CALL 0x00138970
MOV RDI,qword ptr [RSP + 0x8]
ADD RDI,0x28
XOR ESI,ESI
CALL 0x00138980
MOV RDI,qword ptr [RSP + 0x8]
ADD RDI,0x30
CALL 0x001389b0
MOV RSI,qword ptr [RSP + 0x18]
LAB_00131b90:
LEA RDI,[RSP + 0x10]
CALL 0x001389f0
JMP 0x00131b9c
LAB_00131b9c:
MOV RDI,qword ptr [RSP + 0x18]
CALL 0x00131b30
MOV byte ptr [RSP + 0x7],AL
JMP 0x00131bac
LAB_00131bac:
MOV RDI,qword ptr [RSP + 0x8]
MOV AL,byte ptr [RSP + 0x7]
ADD RDI,0x28
MOVZX ESI,AL
AND ESI,0x1
CALL 0x00138a20
MOV RDI,qword ptr [RSP + 0x8]
MOV RSI,qword ptr [RSP + 0x18]
ADD RSI,0x30
ADD RDI,0x30
CALL 0x00138af0
LEA RDI,[RSP + 0x10]
CALL 0x00138ab0
ADD RSP,0x28
RET
|
/* spdlog::details::backtracer::backtracer(spdlog::details::backtracer&&) */
void __thiscall spdlog::details::backtracer::backtracer(backtracer *this,backtracer *param_1)
{
byte bVar1;
lock_guard<std::mutex> local_18 [8];
backtracer *local_10;
backtracer *local_8;
local_10 = param_1;
local_8 = this;
std::mutex::mutex((mutex *)this);
std::atomic<bool>::atomic((atomic<bool> *)(this + 0x28),false);
circular_q<spdlog::details::log_msg_buffer>::circular_q
((circular_q<spdlog::details::log_msg_buffer> *)(this + 0x30));
/* try { // try from 00131b90 to 00131ba5 has its CatchHandler @ 00131bea */
std::lock_guard<std::mutex>::lock_guard(local_18,(mutex *)local_10);
bVar1 = enabled(local_10);
std::atomic<bool>::operator=((atomic<bool> *)(this + 0x28),(bool)(bVar1 & 1));
circular_q<spdlog::details::log_msg_buffer>::operator=
((circular_q<spdlog::details::log_msg_buffer> *)(this + 0x30),
(circular_q *)(local_10 + 0x30));
std::lock_guard<std::mutex>::~lock_guard(local_18);
return;
}
|
|
19,990
|
ftxui::operator|=(std::shared_ptr<ftxui::ComponentBase>&, std::function<std::shared_ptr<ftxui::Node> (std::shared_ptr<ftxui::Node>)>)
|
Andrewchistyakov[P]flashcards_lyc/build_O1/_deps/ftxui-src/src/ftxui/component/util.cpp
|
Component& operator|=(Component& component, ElementDecorator decorator) {
component = component | decorator; // NOLINT
return component;
}
|
O1
|
cpp
|
ftxui::operator|=(std::shared_ptr<ftxui::ComponentBase>&, std::function<std::shared_ptr<ftxui::Node> (std::shared_ptr<ftxui::Node>)>):
pushq %rbx
subq $0x40, %rsp
movq %rdi, %rbx
movq (%rdi), %rax
movq %rax, (%rsp)
movq 0x8(%rdi), %rax
movq %rax, 0x8(%rsp)
testq %rax, %rax
je 0x3440b
movq 0x25bb3(%rip), %rcx # 0x59fb0
cmpb $0x0, (%rcx)
je 0x34407
incl 0x8(%rax)
jmp 0x3440b
lock
incl 0x8(%rax)
leaq 0x20(%rsp), %rdi
callq 0x26520
leaq 0x10(%rsp), %rdi
movq %rsp, %rsi
leaq 0x20(%rsp), %rdx
callq 0x341df
movaps 0x10(%rsp), %xmm0
xorps %xmm1, %xmm1
movaps %xmm1, 0x10(%rsp)
movq 0x8(%rbx), %rdi
movups %xmm0, (%rbx)
testq %rdi, %rdi
je 0x34445
callq 0x14c7c
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x34454
callq 0x14c7c
movq 0x30(%rsp), %rax
testq %rax, %rax
je 0x3446d
leaq 0x20(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x3447c
callq 0x14c7c
movq %rbx, %rax
addq $0x40, %rsp
popq %rbx
retq
jmp 0x344a5
movq %rax, %rbx
movq 0x30(%rsp), %rax
testq %rax, %rax
je 0x344b0
leaq 0x20(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x344b0
movq %rax, %rdi
callq 0x106a9
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x344bf
callq 0x14c7c
movq %rbx, %rdi
callq 0xb780
nop
|
_ZN5ftxuioRERSt10shared_ptrINS_13ComponentBaseEESt8functionIFS0_INS_4NodeEES6_EE:
push rbx
sub rsp, 40h
mov rbx, rdi
mov rax, [rdi]
mov [rsp+48h+var_48], rax
mov rax, [rdi+8]
mov [rsp+48h+var_40], rax
test rax, rax
jz short loc_3440B
mov rcx, cs:__libc_single_threaded_ptr
cmp byte ptr [rcx], 0
jz short loc_34407
inc dword ptr [rax+8]
jmp short loc_3440B
loc_34407:
lock inc dword ptr [rax+8]
loc_3440B:
lea rdi, [rsp+48h+var_28]
call _ZNSt8functionIFSt10shared_ptrIN5ftxui4NodeEES3_EEC2ERKS5_; std::function<std::shared_ptr<ftxui::Node> ()(std::shared_ptr<ftxui::Node>)>::function(std::function<std::shared_ptr<ftxui::Node> ()(std::shared_ptr<ftxui::Node>)> const&)
lea rdi, [rsp+48h+var_38]
mov rsi, rsp
lea rdx, [rsp+48h+var_28]
call _ZN5ftxuiorESt10shared_ptrINS_13ComponentBaseEESt8functionIFS0_INS_4NodeEES5_EE; ftxui::operator|(std::shared_ptr<ftxui::ComponentBase>,std::function<std::shared_ptr<ftxui::Node> ()(std::shared_ptr<ftxui::Node>)>)
movaps xmm0, [rsp+48h+var_38]
xorps xmm1, xmm1
movaps [rsp+48h+var_38], xmm1
mov rdi, [rbx+8]
movups xmmword ptr [rbx], xmm0
test rdi, rdi
jz short loc_34445
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_34445:
mov rdi, qword ptr [rsp+48h+var_38+8]
test rdi, rdi
jz short loc_34454
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_34454:
mov rax, [rsp+48h+var_18]
test rax, rax
jz short loc_3446D
lea rdi, [rsp+48h+var_28]
mov rsi, rdi
mov edx, 3
call rax
loc_3446D:
mov rdi, [rsp+48h+var_40]
test rdi, rdi
jz short loc_3447C
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_3447C:
mov rax, rbx
add rsp, 40h
pop rbx
retn
jmp short loc_344A5
mov rbx, rax
mov rax, [rsp+48h+var_18]
test rax, rax
jz short loc_344B0
lea rdi, [rsp+48h+var_28]
mov rsi, rdi
mov edx, 3
call rax
jmp short loc_344B0
loc_344A5:
mov rdi, rax
call __clang_call_terminate
mov rbx, rax
loc_344B0:
mov rdi, [rsp+48h+var_40]
test rdi, rdi
jz short loc_344BF
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_344BF:
mov rdi, rbx
call __Unwind_Resume
|
long long * ftxui::operator|=(long long *a1, long long a2)
{
volatile signed __int32 *v3; // rax
__int128 v4; // xmm0
volatile signed __int32 *v5; // rdi
long long v7; // [rsp+0h] [rbp-48h] BYREF
volatile signed __int32 *v8; // [rsp+8h] [rbp-40h]
__int128 v9; // [rsp+10h] [rbp-38h] BYREF
_BYTE v10[16]; // [rsp+20h] [rbp-28h] BYREF
void ( *v11)(_BYTE *, _BYTE *, long long); // [rsp+30h] [rbp-18h]
v7 = *a1;
v3 = (volatile signed __int32 *)a1[1];
v8 = v3;
if ( v3 )
{
if ( _libc_single_threaded )
++*((_DWORD *)v3 + 2);
else
_InterlockedIncrement(v3 + 2);
}
std::function<std::shared_ptr<ftxui::Node> ()(std::shared_ptr<ftxui::Node>)>::function((long long)v10, a2);
ftxui::operator|((long long)&v9, &v7, (long long)v10);
v4 = v9;
v9 = 0LL;
v5 = (volatile signed __int32 *)a1[1];
*(_OWORD *)a1 = v4;
if ( v5 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v5);
if ( *((_QWORD *)&v9 + 1) )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(*((volatile signed __int32 **)&v9 + 1));
if ( v11 )
v11(v10, v10, 3LL);
if ( v8 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v8);
return a1;
}
|
operator|=:
PUSH RBX
SUB RSP,0x40
MOV RBX,RDI
MOV RAX,qword ptr [RDI]
MOV qword ptr [RSP],RAX
MOV RAX,qword ptr [RDI + 0x8]
MOV qword ptr [RSP + 0x8],RAX
TEST RAX,RAX
JZ 0x0013440b
MOV RCX,qword ptr [0x00159fb0]
CMP byte ptr [RCX],0x0
JZ 0x00134407
INC dword ptr [RAX + 0x8]
JMP 0x0013440b
LAB_00134407:
INC.LOCK dword ptr [RAX + 0x8]
LAB_0013440b:
LEA RDI,[RSP + 0x20]
CALL 0x00126520
LAB_00134415:
LEA RDI,[RSP + 0x10]
MOV RSI,RSP
LEA RDX,[RSP + 0x20]
CALL 0x001341df
MOVAPS XMM0,xmmword ptr [RSP + 0x10]
XORPS XMM1,XMM1
MOVAPS xmmword ptr [RSP + 0x10],XMM1
MOV RDI,qword ptr [RBX + 0x8]
MOVUPS xmmword ptr [RBX],XMM0
TEST RDI,RDI
JZ 0x00134445
CALL 0x00114c7c
LAB_00134445:
MOV RDI,qword ptr [RSP + 0x18]
TEST RDI,RDI
JZ 0x00134454
CALL 0x00114c7c
LAB_00134454:
MOV RAX,qword ptr [RSP + 0x30]
TEST RAX,RAX
JZ 0x0013446d
LAB_0013445e:
LEA RDI,[RSP + 0x20]
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_0013446d:
MOV RDI,qword ptr [RSP + 0x8]
TEST RDI,RDI
JZ 0x0013447c
CALL 0x00114c7c
LAB_0013447c:
MOV RAX,RBX
ADD RSP,0x40
POP RBX
RET
|
/* ftxui::TEMPNAMEPLACEHOLDERVALUE(std::shared_ptr<ftxui::ComponentBase>&,
std::function<std::shared_ptr<ftxui::Node> (std::shared_ptr<ftxui::Node>)>) */
int8 * ftxui::operator|=(int8 *param_1,function *param_2)
{
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *this;
int4 uVar1;
int4 uVar2;
int4 uVar3;
int4 uVar4;
int8 local_48;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_40;
int8 local_38;
int8 uStack_30;
function<std::shared_ptr<ftxui::Node>(std::shared_ptr<ftxui::Node>)> local_28 [16];
code *local_18;
local_48 = *param_1;
local_40 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)param_1[1];
if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
if (*PTR___libc_single_threaded_00159fb0 == '\0') {
LOCK();
*(int *)(local_40 + 8) = *(int *)(local_40 + 8) + 1;
UNLOCK();
}
else {
*(int *)(local_40 + 8) = *(int *)(local_40 + 8) + 1;
}
}
/* try { // try from 0013440b to 00134414 has its CatchHandler @ 001344ad */
std::function<std::shared_ptr<ftxui::Node>(std::shared_ptr<ftxui::Node>)>::function
(local_28,param_2);
/* try { // try from 00134415 to 00134426 has its CatchHandler @ 00134487 */
operator|((ftxui *)&local_38,&local_48,local_28);
uVar1 = (int4)local_38;
uVar2 = local_38._4_4_;
uVar3 = (int4)uStack_30;
uVar4 = uStack_30._4_4_;
local_38 = 0;
uStack_30 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0;
this = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)param_1[1];
*(int4 *)param_1 = uVar1;
*(int4 *)((long)param_1 + 4) = uVar2;
*(int4 *)(param_1 + 1) = uVar3;
*(int4 *)((long)param_1 + 0xc) = uVar4;
if (this != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(this);
}
if (uStack_30 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(uStack_30);
}
if (local_18 != (code *)0x0) {
/* try { // try from 0013445e to 0013446c has its CatchHandler @ 00134485 */
(*local_18)(local_28,local_28,3);
}
if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_40);
}
return param_1;
}
|
|
19,991
|
translog_scanner_init
|
eloqsql/storage/maria/ma_loghandler.c
|
my_bool translog_scanner_init(LSN lsn,
my_bool fixed_horizon,
TRANSLOG_SCANNER_DATA *scanner,
my_bool use_direct)
{
DBUG_ENTER("translog_scanner_init");
DBUG_PRINT("enter", ("Scanner: %p LSN: " LSN_FMT,
scanner, LSN_IN_PARTS(lsn)));
DBUG_ASSERT(translog_status == TRANSLOG_OK ||
translog_status == TRANSLOG_READONLY);
scanner->page_offset= LSN_OFFSET(lsn) % TRANSLOG_PAGE_SIZE;
scanner->fixed_horizon= fixed_horizon;
scanner->use_direct_link= use_direct;
scanner->direct_link= NULL;
scanner->horizon= translog_get_horizon();
DBUG_PRINT("info", ("horizon: " LSN_FMT, LSN_IN_PARTS(scanner->horizon)));
/* lsn < horizon */
DBUG_ASSERT(lsn <= scanner->horizon);
scanner->page_addr= lsn;
scanner->page_addr-= scanner->page_offset; /*decrease offset */
if (translog_scanner_set_last_page(scanner))
DBUG_RETURN(1);
if (translog_scanner_get_page(scanner))
DBUG_RETURN(1);
DBUG_RETURN(0);
}
|
O3
|
c
|
translog_scanner_init:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %rbx
movq %rdi, %r14
movl %r14d, %eax
andl $0x1fff, %eax # imm = 0x1FFF
movl %eax, 0x2028(%rdx)
movb %sil, 0x202c(%rdx)
movb %cl, 0x202d(%rdx)
movq $0x0, 0x2020(%rdx)
callq 0x465e4
movq %rax, 0x2008(%rbx)
movl 0x2028(%rbx), %eax
subq %rax, %r14
movq %r14, 0x2000(%rbx)
movq %rbx, %rdi
callq 0x46640
movl %eax, %ecx
movb $0x1, %al
testb %cl, %cl
jne 0x45389
leaq 0x2020(%rbx), %rax
leaq 0x2000(%rbx), %rcx
leaq -0x20(%rbp), %rdi
movq %rcx, (%rdi)
movb $0x0, 0x8(%rdi)
xorl %edx, %edx
cmpb $0x0, 0x202d(%rbx)
cmovneq %rax, %rdx
movq %rbx, %rsi
callq 0x44bdc
movq %rax, 0x2018(%rbx)
testq %rax, %rax
sete %al
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
|
translog_scanner_init:
push rbp
mov rbp, rsp
push r14
push rbx
sub rsp, 10h
mov rbx, rdx
mov r14, rdi
mov eax, r14d
and eax, 1FFFh
mov [rdx+2028h], eax
mov [rdx+202Ch], sil
mov [rdx+202Dh], cl
mov qword ptr [rdx+2020h], 0
call translog_get_horizon
mov [rbx+2008h], rax
mov eax, [rbx+2028h]
sub r14, rax
mov [rbx+2000h], r14
mov rdi, rbx
call translog_scanner_set_last_page
mov ecx, eax
mov al, 1
test cl, cl
jnz short loc_45389
lea rax, [rbx+2020h]
lea rcx, [rbx+2000h]
lea rdi, [rbp+var_20]
mov [rdi], rcx
mov byte ptr [rdi+8], 0
xor edx, edx
cmp byte ptr [rbx+202Dh], 0
cmovnz rdx, rax
mov rsi, rbx
call translog_get_page
mov [rbx+2018h], rax
test rax, rax
setz al
loc_45389:
add rsp, 10h
pop rbx
pop r14
pop rbp
retn
|
bool translog_scanner_init(long long a1, char a2, long long a3, char a4)
{
char page; // cl
bool result; // al
_QWORD *v7; // rdx
long long v8; // rax
long long *v9; // [rsp+0h] [rbp-20h] BYREF
char v10; // [rsp+8h] [rbp-18h]
*(_DWORD *)(a3 + 8232) = a1 & 0x1FFF;
*(_BYTE *)(a3 + 8236) = a2;
*(_BYTE *)(a3 + 8237) = a4;
*(_QWORD *)(a3 + 8224) = 0LL;
*(_QWORD *)(a3 + 8200) = translog_get_horizon();
*(_QWORD *)(a3 + 0x2000) = a1 - *(unsigned int *)(a3 + 8232);
page = translog_scanner_set_last_page(a3);
result = 1;
if ( !page )
{
v9 = (long long *)(a3 + 0x2000);
v10 = 0;
v7 = 0LL;
if ( *(_BYTE *)(a3 + 8237) )
v7 = (_QWORD *)(a3 + 8224);
v8 = translog_get_page(&v9, a3, v7);
*(_QWORD *)(a3 + 8216) = v8;
return v8 == 0;
}
return result;
}
|
translog_scanner_init:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
SUB RSP,0x10
MOV RBX,RDX
MOV R14,RDI
MOV EAX,R14D
AND EAX,0x1fff
MOV dword ptr [RDX + 0x2028],EAX
MOV byte ptr [RDX + 0x202c],SIL
MOV byte ptr [RDX + 0x202d],CL
MOV qword ptr [RDX + 0x2020],0x0
CALL 0x001465e4
MOV qword ptr [RBX + 0x2008],RAX
MOV EAX,dword ptr [RBX + 0x2028]
SUB R14,RAX
MOV qword ptr [RBX + 0x2000],R14
MOV RDI,RBX
CALL 0x00146640
MOV ECX,EAX
MOV AL,0x1
TEST CL,CL
JNZ 0x00145389
LEA RAX,[RBX + 0x2020]
LEA RCX,[RBX + 0x2000]
LEA RDI,[RBP + -0x20]
MOV qword ptr [RDI],RCX
MOV byte ptr [RDI + 0x8],0x0
XOR EDX,EDX
CMP byte ptr [RBX + 0x202d],0x0
CMOVNZ RDX,RAX
MOV RSI,RBX
CALL 0x00144bdc
MOV qword ptr [RBX + 0x2018],RAX
TEST RAX,RAX
SETZ AL
LAB_00145389:
ADD RSP,0x10
POP RBX
POP R14
POP RBP
RET
|
bool translog_scanner_init(long param_1,int1 param_2,long param_3,int1 param_4)
{
char cVar1;
int8 uVar2;
long lVar3;
bool bVar4;
long local_28;
int1 local_20;
*(uint *)(param_3 + 0x2028) = (uint)param_1 & 0x1fff;
*(int1 *)(param_3 + 0x202c) = param_2;
*(int1 *)(param_3 + 0x202d) = param_4;
*(int8 *)(param_3 + 0x2020) = 0;
uVar2 = translog_get_horizon();
*(int8 *)(param_3 + 0x2008) = uVar2;
*(ulong *)(param_3 + 0x2000) = param_1 - (ulong)*(uint *)(param_3 + 0x2028);
cVar1 = translog_scanner_set_last_page(param_3);
bVar4 = true;
if (cVar1 == '\0') {
local_28 = param_3 + 0x2000;
local_20 = 0;
lVar3 = 0;
if (*(char *)(param_3 + 0x202d) != '\0') {
lVar3 = param_3 + 0x2020;
}
lVar3 = translog_get_page(&local_28,param_3,lVar3);
*(long *)(param_3 + 0x2018) = lVar3;
bVar4 = lVar3 == 0;
}
return bVar4;
}
|
|
19,992
|
test_conc71
|
eloqsql/libmariadb/unittest/libmariadb/basic-t.c
|
static int test_conc71(MYSQL *my)
{
int rc;
MYSQL *mysql;
/* uncomment if you want to test manually */
return SKIP;
mysql= mysql_init(NULL);
mysql_options(mysql, MYSQL_SET_CHARSET_NAME, "utf8");
mysql_options(mysql, MYSQL_OPT_COMPRESS, 0);
mysql_options(mysql, MYSQL_INIT_COMMAND, "/*!40101 SET SQL_MODE='' */");
mysql_options(mysql, MYSQL_INIT_COMMAND, "/*!40101 set @@session.wait_timeout=28800 */");
FAIL_IF(!my_test_connect(mysql, hostname, username, password, schema,
port, socketname, 0), mysql_error(my));
diag("kill server");
rc= mysql_query(mysql, "SELECT 'foo' FROM DUAL");
check_mysql_rc(rc, mysql);
mysql_close(mysql);
return OK;
}
|
O3
|
c
|
test_conc71:
pushq %rbp
movq %rsp, %rbp
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
popq %rbp
retq
|
test_conc71:
push rbp
mov rbp, rsp
mov eax, 0FFFFFFFFh
pop rbp
retn
|
long long test_conc71()
{
return 0xFFFFFFFFLL;
}
|
test_conc71:
PUSH RBP
MOV RBP,RSP
MOV EAX,0xffffffff
POP RBP
RET
|
int8 test_conc71(void)
{
return 0xffffffff;
}
|
|
19,993
|
aria_read_data
|
eloqsql/storage/maria/ma_backup.c
|
int aria_read_data(File dfile, ARIA_TABLE_CAPABILITIES *cap, ulonglong block,
uchar *buffer, size_t *bytes_read)
{
MARIA_SHARE share;
int retry= 0;
DBUG_ENTER("aria_read_data");
share.keypage_header= cap->keypage_header;
share.block_size= cap->block_size;
if (!cap->online_backup_safe)
{
*bytes_read= my_pread(dfile, buffer, cap->block_size,
block * cap->block_size, MY_WME);
if (*bytes_read == 0)
DBUG_RETURN(HA_ERR_END_OF_FILE);
DBUG_RETURN(*bytes_read > 0 ? 0 : (my_errno ? my_errno : -1));
}
*bytes_read= cap->block_size;
do
{
int error;
size_t length;
if ((length= my_pread(dfile, buffer, cap->block_size,
block * cap->block_size, MYF(0))) != cap->block_size)
{
if (length == 0)
DBUG_RETURN(HA_ERR_END_OF_FILE);
if (length == (size_t) -1)
DBUG_RETURN(my_errno ? my_errno : -1);
}
/* If not transactional or key file header, there are no checksums */
if (!cap->online_backup_safe)
DBUG_RETURN(length == cap->block_size ? 0 : HA_ERR_CRASHED);
if (length == cap->block_size)
{
error= maria_page_crc_check(buffer, block, &share,
((block % cap->bitmap_pages_covered) == 0 ?
MARIA_NO_CRC_BITMAP_PAGE :
MARIA_NO_CRC_NORMAL_PAGE),
share.block_size - CRC_SIZE);
if (error != HA_ERR_WRONG_CRC)
DBUG_RETURN(error);
}
my_sleep(100000); /* Sleep 0.1 seconds */
} while (retry < MAX_RETRY);
DBUG_RETURN(HA_ERR_WRONG_CRC);
}
|
O3
|
c
|
aria_read_data:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc48, %rsp # imm = 0xC48
movq %r8, %r15
movq %rcx, %r14
movq %rdx, %rbx
movl %edi, %r12d
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
movl 0x14(%rsi), %eax
movl %eax, -0x524(%rbp)
movl 0x10(%rsi), %edx
movl %edx, -0x4ac(%rbp)
cmpb $0x0, 0x1f(%rsi)
je 0x7131b
movq %rsi, %r13
movq %rdx, -0xc70(%rbp)
movq %rdx, (%r15)
movl 0x10(%rsi), %edx
movq %rdx, %rcx
imulq %rbx, %rcx
xorl %r15d, %r15d
movl %r12d, %edi
movq %r14, %rsi
xorl %r8d, %r8d
callq 0xa0600
movl 0x10(%r13), %ecx
cmpq %rcx, %rax
je 0x712dc
testq %rax, %rax
je 0x7137d
cmpq $-0x1, %rax
je 0x71369
cmpb $0x0, 0x1f(%r13)
je 0x71385
movl $0x186a0, %edi # imm = 0x186A0
callq 0xa0c14
movl 0x10(%r13), %edx
movq %rdx, %rcx
imulq %rbx, %rcx
jmp 0x71290
cmpb $0x0, 0x1f(%r13)
je 0x71345
movq %rbx, %rax
xorl %edx, %edx
divq 0x8(%r13)
cmpq $0x1, %rdx
movl $0xffffffff, %ecx # imm = 0xFFFFFFFF
sbbl $0x0, %ecx
movq -0xc70(%rbp), %r8
addl $-0x4, %r8d
leaq -0xc68(%rbp), %rdx
movq %r14, %rdi
movq %rbx, %rsi
callq 0x3df20
movsbl %al, %r15d
jmp 0x71345
imulq %rdx, %rbx
movl $0x10, %r8d
movl %r12d, %edi
movq %r14, %rsi
movq %rbx, %rcx
callq 0xa0600
movq %rax, (%r15)
xorl %ecx, %ecx
testq %rax, %rax
movl $0x89, %r15d
cmovnel %ecx, %r15d
movq %fs:0x28, %rax
cmpq -0x30(%rbp), %rax
jne 0x71395
movl %r15d, %eax
addq $0xc48, %rsp # imm = 0xC48
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0xa1ac2
cmpl $0x0, (%rax)
je 0x7138d
callq 0xa1ac2
movl (%rax), %r15d
jmp 0x71345
movl $0x89, %r15d
jmp 0x71345
movl $0x7e, %r15d
jmp 0x71345
movl $0xffffffff, %r15d # imm = 0xFFFFFFFF
jmp 0x71345
callq 0x29250
nop
|
aria_read_data:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0C48h
mov r15, r8
mov r14, rcx
mov rbx, rdx
mov r12d, edi
mov rax, fs:28h
mov [rbp+var_30], rax
mov eax, [rsi+14h]
mov [rbp+var_524], eax
mov edx, [rsi+10h]
mov [rbp+var_4AC], edx
cmp byte ptr [rsi+1Fh], 0
jz loc_7131B
mov r13, rsi
mov [rbp+var_C70], rdx
mov [r15], rdx
mov edx, [rsi+10h]
mov rcx, rdx
imul rcx, rbx
xor r15d, r15d
loc_71290:
mov edi, r12d
mov rsi, r14
xor r8d, r8d
call my_pread
mov ecx, [r13+10h]
cmp rax, rcx
jz short loc_712DC
test rax, rax
jz loc_7137D
cmp rax, 0FFFFFFFFFFFFFFFFh
jz loc_71369
cmp byte ptr [r13+1Fh], 0
jz loc_71385
mov edi, offset stru_186A0
call my_sleep
mov edx, [r13+10h]
mov rcx, rdx
imul rcx, rbx
jmp short loc_71290
loc_712DC:
cmp byte ptr [r13+1Fh], 0
jz short loc_71345
mov rax, rbx
xor edx, edx
div qword ptr [r13+8]
cmp rdx, 1
mov ecx, 0FFFFFFFFh
sbb ecx, 0
mov r8, [rbp+var_C70]
add r8d, 0FFFFFFFCh
lea rdx, [rbp+var_C68]
mov rdi, r14
mov rsi, rbx
call maria_page_crc_check
movsx r15d, al
jmp short loc_71345
loc_7131B:
imul rbx, rdx
mov r8d, 10h
mov edi, r12d
mov rsi, r14
mov rcx, rbx
call my_pread
mov [r15], rax
xor ecx, ecx
test rax, rax
mov r15d, 89h
cmovnz r15d, ecx
loc_71345:
mov rax, fs:28h
cmp rax, [rbp+var_30]
jnz short loc_71395
mov eax, r15d
add rsp, 0C48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_71369:
call _my_thread_var
cmp dword ptr [rax], 0
jz short loc_7138D
call _my_thread_var
mov r15d, [rax]
jmp short loc_71345
loc_7137D:
mov r15d, 89h
jmp short loc_71345
loc_71385:
mov r15d, 7Eh ; '~'
jmp short loc_71345
loc_7138D:
mov r15d, 0FFFFFFFFh
jmp short loc_71345
loc_71395:
call ___stack_chk_fail
|
long long aria_read_data(unsigned int a1, long long a2, unsigned long long a3, long long a4, long long *a5)
{
long long v8; // rdx
long long v9; // rdx
long long v10; // rcx
unsigned int v11; // r15d
long long v12; // rax
long long v13; // rdx
long long v14; // rax
int v16; // [rsp+0h] [rbp-C70h]
char v17[1860]; // [rsp+8h] [rbp-C68h] BYREF
int v18; // [rsp+74Ch] [rbp-524h]
int v19; // [rsp+7C4h] [rbp-4ACh]
unsigned long long v20; // [rsp+C40h] [rbp-30h]
v20 = __readfsqword(0x28u);
v18 = *(_DWORD *)(a2 + 20);
v8 = *(unsigned int *)(a2 + 16);
v19 = *(_DWORD *)(a2 + 16);
if ( *(_BYTE *)(a2 + 31) )
{
v16 = v8;
*a5 = v8;
v9 = *(unsigned int *)(a2 + 16);
v10 = a3 * v9;
v11 = 0;
while ( 1 )
{
v12 = my_pread(a1, a4, v9, v10, 0LL);
if ( v12 == *(_DWORD *)(a2 + 16) )
break;
if ( !v12 )
return 137;
if ( v12 == -1 )
{
if ( *(_DWORD *)my_thread_var(a1) )
return *(unsigned int *)my_thread_var(a1);
else
return (unsigned int)-1;
}
if ( !*(_BYTE *)(a2 + 31) )
return 126;
my_sleep(&stru_186A0, a4, v13);
v9 = *(unsigned int *)(a2 + 16);
v10 = a3 * v9;
}
if ( *(_BYTE *)(a2 + 31) )
return (unsigned int)maria_page_crc_check(a4, a3, (long long)v17, -1 - (a3 % *(_QWORD *)(a2 + 8) == 0), v16 - 4);
}
else
{
v14 = my_pread(a1, a4, v8, v8 * a3, 16LL);
*a5 = v14;
v11 = 137;
if ( v14 )
return 0;
}
return v11;
}
|
aria_read_data:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xc48
MOV R15,R8
MOV R14,RCX
MOV RBX,RDX
MOV R12D,EDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
MOV EAX,dword ptr [RSI + 0x14]
MOV dword ptr [RBP + -0x524],EAX
MOV EDX,dword ptr [RSI + 0x10]
MOV dword ptr [RBP + -0x4ac],EDX
CMP byte ptr [RSI + 0x1f],0x0
JZ 0x0017131b
MOV R13,RSI
MOV qword ptr [RBP + -0xc70],RDX
MOV qword ptr [R15],RDX
MOV EDX,dword ptr [RSI + 0x10]
MOV RCX,RDX
IMUL RCX,RBX
XOR R15D,R15D
LAB_00171290:
MOV EDI,R12D
MOV RSI,R14
XOR R8D,R8D
CALL 0x001a0600
MOV ECX,dword ptr [R13 + 0x10]
CMP RAX,RCX
JZ 0x001712dc
TEST RAX,RAX
JZ 0x0017137d
CMP RAX,-0x1
JZ 0x00171369
CMP byte ptr [R13 + 0x1f],0x0
JZ 0x00171385
MOV EDI,0x186a0
CALL 0x001a0c14
MOV EDX,dword ptr [R13 + 0x10]
MOV RCX,RDX
IMUL RCX,RBX
JMP 0x00171290
LAB_001712dc:
CMP byte ptr [R13 + 0x1f],0x0
JZ 0x00171345
MOV RAX,RBX
XOR EDX,EDX
DIV qword ptr [R13 + 0x8]
CMP RDX,0x1
MOV ECX,0xffffffff
SBB ECX,0x0
MOV R8,qword ptr [RBP + -0xc70]
ADD R8D,-0x4
LEA RDX,[RBP + -0xc68]
MOV RDI,R14
MOV RSI,RBX
CALL 0x0013df20
MOVSX R15D,AL
JMP 0x00171345
LAB_0017131b:
IMUL RBX,RDX
MOV R8D,0x10
MOV EDI,R12D
MOV RSI,R14
MOV RCX,RBX
CALL 0x001a0600
MOV qword ptr [R15],RAX
XOR ECX,ECX
TEST RAX,RAX
MOV R15D,0x89
CMOVNZ R15D,ECX
LAB_00171345:
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNZ 0x00171395
MOV EAX,R15D
ADD RSP,0xc48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00171369:
CALL 0x001a1ac2
CMP dword ptr [RAX],0x0
JZ 0x0017138d
CALL 0x001a1ac2
MOV R15D,dword ptr [RAX]
JMP 0x00171345
LAB_0017137d:
MOV R15D,0x89
JMP 0x00171345
LAB_00171385:
MOV R15D,0x7e
JMP 0x00171345
LAB_0017138d:
MOV R15D,0xffffffff
JMP 0x00171345
LAB_00171395:
CALL 0x00129250
|
int aria_read_data(int4 param_1,long param_2,ulong param_3,int8 param_4,ulong *param_5)
{
uint uVar1;
uint uVar2;
char cVar3;
ulong uVar4;
int *piVar5;
int iVar6;
long in_FS_OFFSET;
int1 local_c70 [1860];
int4 local_52c;
uint local_4b4;
long local_38;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
local_52c = *(int4 *)(param_2 + 0x14);
uVar1 = *(uint *)(param_2 + 0x10);
uVar4 = (ulong)uVar1;
local_4b4 = uVar1;
if (*(char *)(param_2 + 0x1f) == '\0') {
uVar4 = my_pread(param_1,param_4,uVar4,param_3 * uVar4,0x10);
*param_5 = uVar4;
iVar6 = 0x89;
if (uVar4 != 0) {
iVar6 = 0;
}
}
else {
*param_5 = uVar4;
uVar2 = *(uint *)(param_2 + 0x10);
iVar6 = 0;
while( true ) {
uVar4 = my_pread(param_1,param_4,(ulong)uVar2,uVar2 * param_3,0);
if (uVar4 == *(uint *)(param_2 + 0x10)) break;
if (uVar4 == 0) {
iVar6 = 0x89;
goto LAB_00171345;
}
if (uVar4 == 0xffffffffffffffff) {
piVar5 = (int *)_my_thread_var();
if (*piVar5 == 0) {
iVar6 = -1;
}
else {
piVar5 = (int *)_my_thread_var();
iVar6 = *piVar5;
}
goto LAB_00171345;
}
if (*(char *)(param_2 + 0x1f) == '\0') {
iVar6 = 0x7e;
goto LAB_00171345;
}
my_sleep(100000);
uVar2 = *(uint *)(param_2 + 0x10);
}
if (*(char *)(param_2 + 0x1f) != '\0') {
cVar3 = maria_page_crc_check
(param_4,param_3,local_c70,
-1 - (uint)(param_3 % *(ulong *)(param_2 + 8) == 0),uVar1 - 4);
iVar6 = (int)cVar3;
}
}
LAB_00171345:
if (*(long *)(in_FS_OFFSET + 0x28) == local_38) {
return iVar6;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
|
|
19,994
|
std::hash<minja::Value>::operator()(minja::Value const&) const
|
monkey531[P]llama/common/minja.hpp
|
size_t operator()(const minja::Value & v) const {
if (!v.is_hashable())
throw std::runtime_error("Unsupported type for hashing: " + v.dump());
return std::hash<json>()(v.get<json>());
}
|
O3
|
cpp
|
std::hash<minja::Value>::operator()(minja::Value const&) const:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rsi, %r14
cmpq $0x0, 0x10(%rsi)
jne 0xb124e
cmpq $0x0, 0x20(%r14)
jne 0xb124e
cmpq $0x0, 0x30(%r14)
jne 0xb124e
movq %rsp, %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0xb1336
movq %rbx, %rdi
callq 0xb1853
movq %rax, %rbx
movq %rsp, %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x58644
movq %r14, %rdi
callq 0x5db32
movq %rbx, %rax
addq $0x40, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movl $0x10, %edi
callq 0x1b440
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
movl $0xffffffff, %edx # imm = 0xFFFFFFFF
xorl %ecx, %ecx
callq 0x86334
leaq 0x41d0f(%rip), %rsi # 0xf2f85
movq %rsp, %rdi
leaq 0x20(%rsp), %rdx
callq 0x78ac9
movb $0x1, %bpl
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x1be00
xorl %ebp, %ebp
movq 0x7cd4e(%rip), %rsi # 0x12dfe8
movq 0x7ccaf(%rip), %rdx # 0x12df50
movq %rbx, %rdi
callq 0x1bef0
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xb12c7
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1b8b0
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xb12e2
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1b8b0
testb %bpl, %bpl
jne 0xb130c
jmp 0xb132e
movq %rax, %r14
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xb130c
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1b8b0
jmp 0xb130c
movq %rax, %r14
movq %rbx, %rdi
callq 0x1b650
jmp 0xb132e
movq %rax, %r14
movq %rsp, %rbx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x58644
movq %rbx, %rdi
callq 0x5db32
movq %r14, %rdi
callq 0x1bf70
|
_ZNKSt4hashIN5minja5ValueEEclERKS1_:
push rbp
push r14
push rbx
sub rsp, 40h
mov r14, rsi
cmp qword ptr [rsi+10h], 0
jnz short loc_B124E
cmp qword ptr [r14+20h], 0
jnz short loc_B124E
cmp qword ptr [r14+30h], 0
jnz short loc_B124E
mov rbx, rsp
mov rdi, rbx
mov rsi, r14
call _ZNK5minja5Value3getIN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEEET_v; minja::Value::get<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>>(void)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail4hashINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEEmRKT_; nlohmann::json_abi_v3_11_3::detail::hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
mov rbx, rax
mov r14, rsp
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rax, rbx
add rsp, 40h
pop rbx
pop r14
pop rbp
retn
loc_B124E:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rdi, [rsp+58h+var_38]
mov rsi, r14
mov edx, 0FFFFFFFFh
xor ecx, ecx
call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool)
lea rsi, aUnsupportedTyp; "Unsupported type for hashing: "
mov rdi, rsp
lea rdx, [rsp+58h+var_38]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&)
mov bpl, 1
mov rsi, rsp
mov rdi, rbx
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
xor ebp, ebp
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+58h+var_48]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_B12C7
mov rsi, [rsp+58h+var_48]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_B12C7:
lea rax, [rsp+58h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_B12E2
mov rsi, [rsp+58h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_B12E2:
test bpl, bpl
jnz short loc_B130C
jmp short loc_B132E
mov r14, rax
lea rax, [rsp+58h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_B130C
mov rsi, [rsp+58h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_B130C
mov r14, rax
loc_B130C:
mov rdi, rbx; void *
call ___cxa_free_exception
jmp short loc_B132E
mov r14, rax
mov rbx, rsp
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()
loc_B132E:
mov rdi, r14
call __Unwind_Resume
|
long long std::hash<minja::Value>::operator()(long long a1, _QWORD *a2)
{
long long v2; // rbx
void *exception; // rbx
char v5[16]; // [rsp+0h] [rbp-58h] BYREF
_BYTE v6[16]; // [rsp+20h] [rbp-38h] BYREF
if ( a2[2] || a2[4] || a2[6] )
{
exception = __cxa_allocate_exception(0x10uLL);
minja::Value::dump[abi:cxx11]((long long)v6, (long long)a2, 0xFFFFFFFF, 0);
std::operator+<char>((long long)v5, (long long)"Unsupported type for hashing: ", (long long)v6);
std::runtime_error::runtime_error(exception, v5);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
minja::Value::get<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(
v5,
a2);
v2 = nlohmann::json_abi_v3_11_3::detail::hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(v5);
nlohmann::json_abi_v3_11_3::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(v5);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v5);
return v2;
}
|
operator():
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x40
MOV R14,RSI
CMP qword ptr [RSI + 0x10],0x0
JNZ 0x001b124e
CMP qword ptr [R14 + 0x20],0x0
JNZ 0x001b124e
CMP qword ptr [R14 + 0x30],0x0
JNZ 0x001b124e
MOV RBX,RSP
MOV RDI,RBX
MOV RSI,R14
CALL 0x001b1336
LAB_001b1222:
MOV RDI,RBX
CALL 0x001b1853
LAB_001b122a:
MOV RBX,RAX
MOV R14,RSP
MOV RDI,R14
XOR ESI,ESI
CALL 0x00158644
MOV RDI,R14
CALL 0x0015db32
MOV RAX,RBX
ADD RSP,0x40
POP RBX
POP R14
POP RBP
RET
LAB_001b124e:
MOV EDI,0x10
CALL 0x0011b440
MOV RBX,RAX
LAB_001b125b:
LEA RDI,[RSP + 0x20]
MOV RSI,R14
MOV EDX,0xffffffff
XOR ECX,ECX
CALL 0x00186334
LAB_001b126f:
LEA RSI,[0x1f2f85]
MOV RDI,RSP
LEA RDX,[RSP + 0x20]
CALL 0x00178ac9
MOV BPL,0x1
LAB_001b1286:
MOV RSI,RSP
MOV RDI,RBX
CALL 0x0011be00
XOR EBP,EBP
MOV RSI,qword ptr [0x0022dfe8]
MOV RDX,qword ptr [0x0022df50]
MOV RDI,RBX
CALL 0x0011bef0
|
/* std::hash<minja::Value>::TEMPNAMEPLACEHOLDERVALUE(minja::Value const&) const */
ulong __thiscall std::hash<minja::Value>::operator()(hash<minja::Value> *this,Value *param_1)
{
ulong uVar1;
runtime_error *this_00;
basic_json abStack_58 [32];
int1 local_38 [32];
if (((*(long *)(param_1 + 0x10) == 0) && (*(long *)(param_1 + 0x20) == 0)) &&
(*(long *)(param_1 + 0x30) == 0)) {
minja::Value::
get<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>>
();
/* try { // try from 001b1222 to 001b1229 has its CatchHandler @ 001b1316 */
uVar1 = nlohmann::json_abi_v3_11_3::detail::
hash<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>>
(abStack_58);
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(abStack_58,0));
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data((data *)abStack_58);
return uVar1;
}
this_00 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 001b125b to 001b126e has its CatchHandler @ 001b1309 */
minja::Value::dump_abi_cxx11_((int)local_38,SUB81(param_1,0));
/* try { // try from 001b126f to 001b1282 has its CatchHandler @ 001b12e9 */
operator+((char *)abStack_58,(string *)"Unsupported type for hashing: ");
/* try { // try from 001b1286 to 001b12a8 has its CatchHandler @ 001b12a9 */
std::runtime_error::runtime_error(this_00,(string *)abStack_58);
/* WARNING: Subroutine does not return */
__cxa_throw(this_00,PTR_typeinfo_0022dfe8,PTR__runtime_error_0022df50);
}
|
|
19,995
|
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>> nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::erase<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, 0>(nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>)
|
llama.cpp/common/json.hpp
|
IteratorType erase(IteratorType pos)
{
// make sure iterator fits the current value
if (JSON_HEDLEY_UNLIKELY(this != pos.m_object))
{
JSON_THROW(invalid_iterator::create(202, "iterator does not fit current value", this));
}
IteratorType result = end();
switch (m_data.m_type)
{
case value_t::boolean:
case value_t::number_float:
case value_t::number_integer:
case value_t::number_unsigned:
case value_t::string:
case value_t::binary:
{
if (JSON_HEDLEY_UNLIKELY(!pos.m_it.primitive_iterator.is_begin()))
{
JSON_THROW(invalid_iterator::create(205, "iterator out of range", this));
}
if (is_string())
{
AllocatorType<string_t> alloc;
std::allocator_traits<decltype(alloc)>::destroy(alloc, m_data.m_value.string);
std::allocator_traits<decltype(alloc)>::deallocate(alloc, m_data.m_value.string, 1);
m_data.m_value.string = nullptr;
}
else if (is_binary())
{
AllocatorType<binary_t> alloc;
std::allocator_traits<decltype(alloc)>::destroy(alloc, m_data.m_value.binary);
std::allocator_traits<decltype(alloc)>::deallocate(alloc, m_data.m_value.binary, 1);
m_data.m_value.binary = nullptr;
}
m_data.m_type = value_t::null;
assert_invariant();
break;
}
case value_t::object:
{
result.m_it.object_iterator = m_data.m_value.object->erase(pos.m_it.object_iterator);
break;
}
case value_t::array:
{
result.m_it.array_iterator = m_data.m_value.array->erase(pos.m_it.array_iterator);
break;
}
case value_t::null:
case value_t::discarded:
default:
JSON_THROW(type_error::create(307, detail::concat("cannot use erase() with ", type_name()), this));
}
return result;
}
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>> nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::erase<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, 0>(nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
cmpq %rsi, (%rdx)
jne 0x7cbdc
movq %rdx, %r15
movq %rdi, %rbx
movq %r14, (%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rdi)
movabsq $-0x8000000000000000, %rax # imm = 0x8000000000000000
movq %rax, 0x18(%rdi)
callq 0x7dbba
movzbl (%r14), %eax
leal -0x3(%rax), %ecx
cmpl $0x6, %ecx
jae 0x7cb3a
cmpq $0x0, 0x18(%r15)
jne 0x7cc3b
cmpl $0x8, %eax
je 0x7cb5b
cmpl $0x3, %eax
jne 0x7cb8e
leaq 0x8(%r14), %r15
movq 0x8(%r14), %rdi
movq (%rdi), %rax
leaq 0x10(%rdi), %rcx
cmpq %rcx, %rax
je 0x7cb33
movq (%rcx), %rsi
incq %rsi
movq %rax, %rdi
callq 0x20180
movq (%r15), %rdi
movl $0x20, %esi
jmp 0x7cb82
cmpl $0x1, %eax
je 0x7cbb1
cmpl $0x2, %eax
jne 0x7cc97
movq 0x8(%r14), %rdi
movq 0x10(%r15), %rsi
callq 0x7dedc
movq %rax, 0x10(%rbx)
jmp 0x7cb9f
leaq 0x8(%r14), %r15
movq 0x8(%r14), %rdi
movq (%rdi), %rax
testq %rax, %rax
je 0x7cb7d
movq 0x10(%rdi), %rsi
subq %rax, %rsi
movq %rax, %rdi
callq 0x20180
movq (%r15), %rdi
movl $0x28, %esi
callq 0x20180
movq $0x0, (%r15)
movb $0x0, (%r14)
movq %r14, %rdi
movl $0x1, %esi
callq 0x772be
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rbx, %r13
addq $0x8, %r13
movq 0x8(%r14), %r14
movq 0x8(%r15), %r15
movq %r15, %rdi
callq 0x210b0
movq %rax, %r12
movq %r14, %rdi
movq %r15, %rsi
callq 0x7de9e
movq %r12, (%r13)
jmp 0x7cb9f
movl $0x20, %edi
callq 0x20680
movq %rax, %rbx
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0xa1245(%rip), %rsi # 0x11de3e
leaq 0xa1261(%rip), %rdx # 0x11de61
movq %rsp, %rdi
callq 0x2a262
movb $0x1, %bpl
movq %rsp, %rdx
movq %rbx, %rdi
movl $0xca, %esi
movq %r14, %rcx
callq 0x7d9b0
xorl %ebp, %ebp
leaq 0xe73d9(%rip), %rsi # 0x164000
leaq -0x2c36(%rip), %rdx # 0x79ff8
movq %rbx, %rdi
callq 0x20ab0
jmp 0x7ccf1
movl $0x20, %edi
callq 0x20680
movq %rax, %rbx
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0xa120a(%rip), %rsi # 0x11de62
leaq 0xa1218(%rip), %rdx # 0x11de77
movq %rsp, %rdi
callq 0x2a262
movb $0x1, %bpl
movq %rsp, %rdx
movq %rbx, %rdi
movl $0xcd, %esi
movq %r14, %rcx
callq 0x7d9b0
xorl %ebp, %ebp
leaq 0xe737a(%rip), %rsi # 0x164000
leaq -0x2c95(%rip), %rdx # 0x79ff8
movq %rbx, %rdi
callq 0x20ab0
jmp 0x7ccf1
movl $0x20, %edi
callq 0x20680
movq %rax, %rbx
movq %r14, %rdi
callq 0x7de80
leaq 0x20(%rsp), %rdx
movq %rax, (%rdx)
leaq 0xa11bd(%rip), %rsi # 0x11de78
movq %rsp, %rdi
callq 0x7ddf8
movb $0x1, %bpl
movq %rsp, %rdx
movq %rbx, %rdi
movl $0x133, %esi # imm = 0x133
movq %r14, %rcx
callq 0x7dc20
xorl %ebp, %ebp
leaq 0xe735e(%rip), %rsi # 0x164040
leaq -0x2cf1(%rip), %rdx # 0x79ff8
movq %rbx, %rdi
callq 0x20ab0
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0x7cd16
jmp 0x7cd23
jmp 0x7cd2a
jmp 0x7cd0a
jmp 0x7cd2a
movq %rax, %r14
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x7cd23
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x20180
testb %bpl, %bpl
jne 0x7cd2d
jmp 0x7cd35
movq %rax, %r14
movq %rbx, %rdi
callq 0x20f60
movq %r14, %rdi
callq 0x20b50
nop
|
_ZN8nlohmann16json_abi_v3_11_310basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_:
push rbp; __int64
push r15; int
push r14; void *
push r13; int
push r12; __int64
push rbx; int
sub rsp, 28h
mov r14, rsi
cmp [rdx], rsi
jnz loc_7CBDC
mov r15, rdx
mov rbx, rdi
mov [rdi], r14
xorps xmm0, xmm0
movups xmmword ptr [rdi+8], xmm0
mov rax, 8000000000000000h
mov [rdi+18h], rax
call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::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)
movzx eax, byte ptr [r14]
lea ecx, [rax-3]
cmp ecx, 6
jnb short loc_7CB3A
cmp qword ptr [r15+18h], 0
jnz loc_7CC3B
cmp eax, 8
jz short loc_7CB5B
cmp eax, 3
jnz loc_7CB8E
lea r15, [r14+8]
mov rdi, [r14+8]
mov rax, [rdi]
lea rcx, [rdi+10h]
cmp rax, rcx
jz short loc_7CB33
mov rsi, [rcx]
inc rsi; unsigned __int64
mov rdi, rax; void *
call __ZdlPvm; operator delete(void *,ulong)
mov rdi, [r15]
loc_7CB33:
mov esi, 20h ; ' '
jmp short loc_7CB82
loc_7CB3A:
cmp eax, 1
jz short loc_7CBB1
cmp eax, 2
jnz loc_7CC97
mov rdi, [r14+8]
mov rsi, [r15+10h]
call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonISt3mapS_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EE8_M_eraseEN9__gnu_cxx17__normal_iteratorIPSD_SF_EE; std::vector<nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::_M_erase(__gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<std::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<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>)
mov [rbx+10h], rax
jmp short loc_7CB9F
loc_7CB5B:
lea r15, [r14+8]
mov rdi, [r14+8]
mov rax, [rdi]
test rax, rax
jz short loc_7CB7D
mov rsi, [rdi+10h]
sub rsi, rax; unsigned __int64
mov rdi, rax; void *
call __ZdlPvm; operator delete(void *,ulong)
mov rdi, [r15]; void *
loc_7CB7D:
mov esi, 28h ; '('; unsigned __int64
loc_7CB82:
call __ZdlPvm; operator delete(void *,ulong)
mov qword ptr [r15], 0
loc_7CB8E:
mov byte ptr [r14], 0
mov rdi, r14
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
loc_7CB9F:
mov rax, rbx
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_7CBB1:
mov r13, rbx
add r13, 8
mov r14, [r14+8]
mov r15, [r15+8]
mov rdi, r15
call __ZSt18_Rb_tree_incrementPSt18_Rb_tree_node_base; std::_Rb_tree_increment(std::_Rb_tree_node_base *)
mov r12, rax
mov rdi, r14
mov rsi, r15
call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_N8nlohmann16json_abi_v3_11_310basic_jsonISt3mapSt6vectorS5_blmdSaNS9_14adl_serializerESC_IhSaIhEEvEEESt10_Select1stISH_ESt4lessIvESaISH_EE12_M_erase_auxESt23_Rb_tree_const_iteratorISH_E; std::_Rb_tree<std::string,std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::_Select1st<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::_M_erase_aux(std::_Rb_tree_const_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>)
mov [r13+0], r12
jmp short loc_7CB9F
loc_7CBDC:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea r15, [rsp+58h+var_48]
mov [r15-10h], r15
lea rsi, aIteratorDoesNo; "iterator does not fit current value"
lea rdx, aIteratorDoesNo+23h; ""
mov rdi, rsp
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 bpl, 1
mov rdx, rsp
mov rdi, rbx; this
mov esi, 0CAh; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__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
jmp loc_7CCF1
loc_7CC3B:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea r15, [rsp+58h+var_48]
mov [r15-10h], r15
lea rsi, aIteratorOutOfR; "iterator out of range"
lea rdx, aIteratorOutOfR+15h; ""
mov rdi, rsp
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 bpl, 1
mov rdx, rsp
mov rdi, rbx; this
mov esi, 0CDh; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__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
jmp short loc_7CCF1
loc_7CC97:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void)
lea rdx, [rsp+58h+var_38]
mov [rdx], rax
lea rsi, aCannotUseErase; "cannot use erase() with "
mov rdi, rsp
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA25_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[25],char const*>(char const(&)[25],char const* &&)
mov bpl, 1
mov rdx, rsp
mov rdi, rbx; this
mov esi, 133h; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
loc_7CCF1:
mov r14, rax
lea rax, [rsp+58h+var_48]
mov rdi, [rax-10h]
cmp rdi, rax
jnz short loc_7CD16
jmp short loc_7CD23
jmp short loc_7CD2A
jmp short loc_7CD0A
jmp short loc_7CD2A
loc_7CD0A:
mov r14, rax
mov rdi, [rsp+58h+var_58]; void *
cmp rdi, r15
jz short loc_7CD23
loc_7CD16:
mov rsi, [rsp+58h+var_48]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_7CD23:
test bpl, bpl
jnz short loc_7CD2D
jmp short loc_7CD35
loc_7CD2A:
mov r14, rax
loc_7CD2D:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_7CD35:
mov rdi, r14
call __Unwind_Resume
|
_ZN8nlohmann16json_abi_v3_11_310basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R14,RSI
CMP qword ptr [RDX],RSI
JNZ 0x0017cbdc
MOV R15,RDX
MOV RBX,RDI
MOV qword ptr [RDI],R14
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI + 0x8],XMM0
MOV RAX,-0x8000000000000000
MOV qword ptr [RDI + 0x18],RAX
CALL 0x0017dbba
MOVZX EAX,byte ptr [R14]
LEA ECX,[RAX + -0x3]
CMP ECX,0x6
JNC 0x0017cb3a
CMP qword ptr [R15 + 0x18],0x0
JNZ 0x0017cc3b
CMP EAX,0x8
JZ 0x0017cb5b
CMP EAX,0x3
JNZ 0x0017cb8e
LEA R15,[R14 + 0x8]
MOV RDI,qword ptr [R14 + 0x8]
MOV RAX,qword ptr [RDI]
LEA RCX,[RDI + 0x10]
CMP RAX,RCX
JZ 0x0017cb33
MOV RSI,qword ptr [RCX]
INC RSI
MOV RDI,RAX
CALL 0x00120180
MOV RDI,qword ptr [R15]
LAB_0017cb33:
MOV ESI,0x20
JMP 0x0017cb82
LAB_0017cb3a:
CMP EAX,0x1
JZ 0x0017cbb1
CMP EAX,0x2
JNZ 0x0017cc97
MOV RDI,qword ptr [R14 + 0x8]
MOV RSI,qword ptr [R15 + 0x10]
CALL 0x0017dedc
MOV qword ptr [RBX + 0x10],RAX
JMP 0x0017cb9f
LAB_0017cb5b:
LEA R15,[R14 + 0x8]
MOV RDI,qword ptr [R14 + 0x8]
MOV RAX,qword ptr [RDI]
TEST RAX,RAX
JZ 0x0017cb7d
MOV RSI,qword ptr [RDI + 0x10]
SUB RSI,RAX
MOV RDI,RAX
CALL 0x00120180
MOV RDI,qword ptr [R15]
LAB_0017cb7d:
MOV ESI,0x28
LAB_0017cb82:
CALL 0x00120180
MOV qword ptr [R15],0x0
LAB_0017cb8e:
MOV byte ptr [R14],0x0
MOV RDI,R14
MOV ESI,0x1
CALL 0x001772be
LAB_0017cb9f:
MOV RAX,RBX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0017cbb1:
MOV R13,RBX
ADD R13,0x8
MOV R14,qword ptr [R14 + 0x8]
MOV R15,qword ptr [R15 + 0x8]
MOV RDI,R15
CALL 0x001210b0
MOV R12,RAX
MOV RDI,R14
MOV RSI,R15
CALL 0x0017de9e
MOV qword ptr [R13],R12
JMP 0x0017cb9f
LAB_0017cbdc:
MOV EDI,0x20
CALL 0x00120680
MOV RBX,RAX
LEA R15,[RSP + 0x10]
MOV qword ptr [R15 + -0x10],R15
LAB_0017cbf2:
LEA RSI,[0x21de3e]
LEA RDX,[0x21de61]
MOV RDI,RSP
CALL 0x0012a262
MOV BPL,0x1
LAB_0017cc0b:
MOV RDX,RSP
MOV RDI,RBX
MOV ESI,0xca
MOV RCX,R14
CALL 0x0017d9b0
XOR EBP,EBP
LEA RSI,[0x264000]
LEA RDX,[0x179ff8]
MOV RDI,RBX
CALL 0x00120ab0
LAB_0017cc3b:
MOV EDI,0x20
CALL 0x00120680
MOV RBX,RAX
LEA R15,[RSP + 0x10]
MOV qword ptr [R15 + -0x10],R15
LAB_0017cc51:
LEA RSI,[0x21de62]
LEA RDX,[0x21de77]
MOV RDI,RSP
CALL 0x0012a262
MOV BPL,0x1
LAB_0017cc6a:
MOV RDX,RSP
MOV RDI,RBX
MOV ESI,0xcd
MOV RCX,R14
CALL 0x0017d9b0
XOR EBP,EBP
LEA RSI,[0x264000]
LEA RDX,[0x179ff8]
MOV RDI,RBX
CALL 0x00120ab0
LAB_0017cc97:
MOV EDI,0x20
CALL 0x00120680
MOV RBX,RAX
MOV RDI,R14
CALL 0x0017de80
LEA RDX,[RSP + 0x20]
MOV qword ptr [RDX],RAX
LAB_0017ccb4:
LEA RSI,[0x21de78]
MOV RDI,RSP
CALL 0x0017ddf8
MOV BPL,0x1
LAB_0017ccc6:
MOV RDX,RSP
MOV RDI,RBX
MOV ESI,0x133
MOV RCX,R14
CALL 0x0017dc20
XOR EBP,EBP
LEA RSI,[0x264040]
LEA RDX,[0x179ff8]
MOV RDI,RBX
CALL 0x00120ab0
|
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::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>>
* _ZN8nlohmann16json_abi_v3_11_310basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_
(iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*param_1,
basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*param_2,long *param_3)
{
basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
bVar1;
void *pvVar2;
_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::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::_Select1st<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::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::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::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>>>>
*p_Var3;
_Rb_tree_node_base *p_Var4;
int8 uVar5;
ulong uVar6;
int8 *puVar7;
int1 *local_58 [2];
int1 local_48 [16];
char *local_38;
if ((basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*)*param_3 != param_2) {
uVar5 = __cxa_allocate_exception(0x20);
local_58[0] = local_48;
/* try { // try from 0017cbf2 to 0017cc07 has its CatchHandler @ 0017cd2a */
std::__cxx11::string::_M_construct<char_const*>
(local_58,"iterator does not fit current value","");
/* try { // try from 0017cc0b to 0017cc35 has its CatchHandler @ 0017cd0a */
_ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar5,0xca,local_58,param_2);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar5,&nlohmann::json_abi_v3_11_3::detail::invalid_iterator::typeinfo,
nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
*(basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
**)param_1 = param_2;
*(int8 *)(param_1 + 8) = 0;
*(int8 *)(param_1 + 0x10) = 0;
*(int8 *)(param_1 + 0x18) = 0x8000000000000000;
nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::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(param_1);
bVar1 = *param_2;
if (5 < (byte)bVar1 - 3) {
if (bVar1 == (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x1) {
p_Var3 = *(_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::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::_Select1st<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::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::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
**)(param_2 + 8);
p_Var4 = (_Rb_tree_node_base *)param_3[1];
uVar5 = std::_Rb_tree_increment(p_Var4);
std::
_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::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::_Select1st<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::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::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<std::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>>>>
::_M_erase_aux(p_Var3,p_Var4);
*(int8 *)(param_1 + 8) = uVar5;
return param_1;
}
if (bVar1 == (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x2) {
uVar5 = std::
vector<nlohmann::json_abi_v3_11_3::basic_json<std::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<std::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>>>
::_M_erase(*(vector<nlohmann::json_abi_v3_11_3::basic_json<std::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<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
**)(param_2 + 8),param_3[2]);
*(int8 *)(param_1 + 0x10) = uVar5;
return param_1;
}
uVar5 = __cxa_allocate_exception(0x20);
local_38 = (char *)nlohmann::json_abi_v3_11_3::
basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::type_name(param_2);
/* try { // try from 0017ccb4 to 0017ccc2 has its CatchHandler @ 0017cd04 */
nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[25],char_const*>
((detail *)local_58,"cannot use erase() with ",&local_38);
/* try { // try from 0017ccc6 to 0017ccf0 has its CatchHandler @ 0017ccf1 */
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar5,0x133,local_58,param_2);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar5,&nlohmann::json_abi_v3_11_3::detail::type_error::typeinfo,
nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
if (param_3[3] != 0) {
uVar5 = __cxa_allocate_exception(0x20);
local_58[0] = local_48;
/* try { // try from 0017cc51 to 0017cc66 has its CatchHandler @ 0017cd08 */
std::__cxx11::string::_M_construct<char_const*>(local_58,"iterator out of range","");
/* try { // try from 0017cc6a to 0017cc94 has its CatchHandler @ 0017cd06 */
_ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar5,0xcd,local_58,param_2);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar5,&nlohmann::json_abi_v3_11_3::detail::invalid_iterator::typeinfo,
nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
if (bVar1 == (basic_json<std::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>
)0x8) {
puVar7 = *(int8 **)(param_2 + 8);
pvVar2 = (void *)*puVar7;
if (pvVar2 != (void *)0x0) {
operator_delete(pvVar2,puVar7[2] - (long)pvVar2);
puVar7 = *(int8 **)(param_2 + 8);
}
uVar6 = 0x28;
}
else {
if (bVar1 != (basic_json<std::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>
)0x3) goto LAB_0017cb8e;
puVar7 = *(int8 **)(param_2 + 8);
if ((long *)*puVar7 != puVar7 + 2) {
operator_delete((long *)*puVar7,puVar7[2] + 1);
puVar7 = *(int8 **)(param_2 + 8);
}
uVar6 = 0x20;
}
operator_delete(puVar7,uVar6);
*(int8 *)(param_2 + 8) = 0;
LAB_0017cb8e:
*param_2 = (basic_json<std::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;
nlohmann::json_abi_v3_11_3::
basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(param_2,0));
return param_1;
}
|
||
19,996
|
ConfigNumber<unsigned short>::set(char const*)
|
untodesu[P]voxelius/core/config.hh
|
inline void ConfigNumber<T>::set(const char *value)
{
std::istringstream(value) >> m_value;
m_value = std::clamp(m_value, m_min_value, m_max_value);
m_string = std::to_string(m_value);
}
|
O2
|
cpp
|
ConfigNumber<unsigned short>::set(char const*):
pushq %r14
pushq %rbx
subq $0x1a8, %rsp # imm = 0x1A8
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
leaq 0x7(%rsp), %rdx
movq %r14, %rdi
callq 0x190fa
leaq 0x28(%rsp), %rdi
pushq $0x8
popq %rdx
movq %r14, %rsi
callq 0x17c10
leaq 0x8(%rbx), %rsi
leaq 0x28(%rsp), %rdi
callq 0x173b0
leaq 0x28(%rsp), %rdi
callq 0x172e0
leaq 0x8(%rsp), %rdi
callq 0x17ec8
movq 0x8(%rbx), %rax
xorl %ecx, %ecx
cmpq %rax, 0x18(%rbx)
setb %cl
shll $0x4, %ecx
orq $0x8, %rcx
cmpq 0x10(%rbx), %rax
pushq $0x10
popq %rax
cmovaeq %rcx, %rax
movq (%rbx,%rax), %rsi
movq %rsi, 0x8(%rbx)
leaq 0x28(%rsp), %r14
movq %r14, %rdi
callq 0x2d1ab
addq $0x20, %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x178b0
movq %r14, %rdi
callq 0x17ec8
addq $0x1a8, %rsp # imm = 0x1A8
popq %rbx
popq %r14
retq
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x172e0
jmp 0x2d193
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x17ec8
movq %rbx, %rdi
callq 0x17cd0
nop
|
_ZN12ConfigNumberImE3setEPKc:
push r14
push rbx
sub rsp, 1A8h
mov rbx, rdi
lea r14, [rsp+1B8h+var_1B0]
lea rdx, [rsp+1B8h+var_1B1]
mov rdi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rdi, [rsp+1B8h+var_190]
push 8
pop rdx
mov rsi, r14
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode; std::istringstream::basic_istringstream(std::string const&,std::_Ios_Openmode)
lea rsi, [rbx+8]
lea rdi, [rsp+1B8h+var_190]
call __ZNSi10_M_extractImEERSiRT_; std::istream::_M_extract<ulong>(ulong &)
lea rdi, [rsp+1B8h+var_190]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev; std::istringstream::~istringstream()
lea rdi, [rsp+1B8h+var_1B0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rax, [rbx+8]
xor ecx, ecx
cmp [rbx+18h], rax
setb cl
shl ecx, 4
or rcx, 8
cmp rax, [rbx+10h]
push 10h
pop rax
cmovnb rax, rcx
mov rsi, [rbx+rax]; unsigned __int64
mov [rbx+8], rsi
lea r14, [rsp+1B8h+var_190]
mov rdi, r14; this
call _ZNSt7__cxx119to_stringEm; std::to_string(ulong)
add rbx, 20h ; ' '
mov rdi, rbx
mov rsi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&)
mov rdi, r14; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
add rsp, 1A8h
pop rbx
pop r14
retn
mov rbx, rax
lea rdi, [rsp+arg_20]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev; std::istringstream::~istringstream()
jmp short loc_2D193
mov rbx, rax
loc_2D193:
lea rdi, [rsp+arg_0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, rbx
call __Unwind_Resume
|
void ConfigNumber<unsigned long>::set(_QWORD *a1, long long a2)
{
unsigned long long v2; // rax
long long v3; // rcx
bool v4; // cf
long long v5; // rax
unsigned long long v6; // rsi
_QWORD v7[4]; // [rsp+8h] [rbp-1B0h] BYREF
_BYTE v8[400]; // [rsp+28h] [rbp-190h] BYREF
std::string::basic_string<std::allocator<char>>(v7, a2);
std::istringstream::basic_istringstream(v8, v7, 8LL);
std::istream::_M_extract<unsigned long>(v8, a1 + 1);
std::istringstream::~istringstream(v8);
std::string::~string(v7);
v2 = a1[1];
v3 = (16 * (unsigned int)(a1[3] < v2)) | 8LL;
v4 = v2 < a1[2];
v5 = 16LL;
if ( !v4 )
v5 = v3;
v6 = *(_QWORD *)((char *)a1 + v5);
a1[1] = v6;
std::to_string((std::__cxx11 *)v8, v6);
std::string::operator=(a1 + 4, v8);
std::string::~string(v8);
}
|
set:
PUSH R14
PUSH RBX
SUB RSP,0x1a8
MOV RBX,RDI
LEA R14,[RSP + 0x8]
LEA RDX,[RSP + 0x7]
MOV RDI,R14
CALL 0x001190fa
LAB_0012d0f9:
LEA RDI,[RSP + 0x28]
PUSH 0x8
POP RDX
MOV RSI,R14
CALL 0x00117c10
LEA RSI,[RBX + 0x8]
LAB_0012d10d:
LEA RDI,[RSP + 0x28]
CALL 0x001173b0
LAB_0012d117:
LEA RDI,[RSP + 0x28]
CALL 0x001172e0
LEA RDI,[RSP + 0x8]
CALL 0x00117ec8
MOV RAX,qword ptr [RBX + 0x8]
XOR ECX,ECX
CMP qword ptr [RBX + 0x18],RAX
SETC CL
SHL ECX,0x4
OR RCX,0x8
CMP RAX,qword ptr [RBX + 0x10]
PUSH 0x10
POP RAX
CMOVNC RAX,RCX
MOV RSI,qword ptr [RBX + RAX*0x1]
MOV qword ptr [RBX + 0x8],RSI
LEA R14,[RSP + 0x28]
MOV RDI,R14
CALL 0x0012d1ab
ADD RBX,0x20
MOV RDI,RBX
MOV RSI,R14
CALL 0x001178b0
MOV RDI,R14
CALL 0x00117ec8
ADD RSP,0x1a8
POP RBX
POP R14
RET
|
/* ConfigNumber<unsigned long>::set(char const*) */
void __thiscall ConfigNumber<unsigned_long>::set(ConfigNumber<unsigned_long> *this,char *param_1)
{
ulong uVar1;
allocator local_1b1;
string local_1b0 [32];
istringstream local_190 [384];
std::__cxx11::string::string<std::allocator<char>>(local_1b0,param_1,&local_1b1);
/* try { // try from 0012d0f9 to 0012d108 has its CatchHandler @ 0012d190 */
std::__cxx11::istringstream::istringstream(local_190,local_1b0,8);
/* try { // try from 0012d10d to 0012d116 has its CatchHandler @ 0012d181 */
std::istream::_M_extract<unsigned_long>((ulong *)local_190);
std::__cxx11::istringstream::~istringstream(local_190);
std::__cxx11::string::~string(local_1b0);
uVar1 = 0x10;
if (*(ulong *)(this + 0x10) <= *(ulong *)(this + 8)) {
uVar1 = (ulong)(*(ulong *)(this + 0x18) < *(ulong *)(this + 8)) << 4 | 8;
}
uVar1 = *(ulong *)(this + uVar1);
*(ulong *)(this + 8) = uVar1;
std::__cxx11::to_string((__cxx11 *)local_190,uVar1);
std::__cxx11::string::operator=((string *)(this + 0x20),(string *)local_190);
std::__cxx11::string::~string((string *)local_190);
return;
}
|
|
19,997
|
ConfigNumber<unsigned short>::set(char const*)
|
untodesu[P]voxelius/core/config.hh
|
inline void ConfigNumber<T>::set(const char *value)
{
std::istringstream(value) >> m_value;
m_value = std::clamp(m_value, m_min_value, m_max_value);
m_string = std::to_string(m_value);
}
|
O3
|
cpp
|
ConfigNumber<unsigned short>::set(char const*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1b0, %rsp # imm = 0x1B0
movq %rdi, %rbx
leaq 0x10(%rsp), %r14
leaq 0xf(%rsp), %rdx
movq %r14, %rdi
callq 0x1b480
leaq 0x30(%rsp), %rdi
movq %r14, %rsi
movl $0x8, %edx
callq 0x16bb0
leaq 0x8(%rbx), %rsi
leaq 0x30(%rsp), %rdi
callq 0x16a00
movq 0xeb0ed(%rip), %rsi # 0x107f60
leaq 0x30(%rsp), %rdi
callq 0x169a0
leaq 0xa8(%rsp), %rdi
callq 0x16210
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1cea5
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x166c0
movzwl 0x8(%rbx), %eax
xorl %ecx, %ecx
cmpw %ax, 0xc(%rbx)
setb %cl
cmpw 0xa(%rbx), %ax
leaq 0x8(,%rcx,4), %rax
movl $0xa, %ecx
cmovaeq %rax, %rcx
movzwl (%rbx,%rcx), %ebp
movw %bp, 0x8(%rbx)
movl $0x1, %r14d
cmpl $0xa, %ebp
jb 0x1cf04
movl $0x2, %r14d
cmpw $0x64, %bp
jb 0x1cf04
movl $0x3, %r14d
cmpl $0x3e8, %ebp # imm = 0x3E8
jb 0x1cf04
cmpl $0x2710, %ebp # imm = 0x2710
movl $0x5, %r14d
sbbl $0x0, %r14d
movl %r14d, %esi
leaq 0x40(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x30(%rsp), %r15
movq %r15, %rdi
movl $0x2d, %edx
callq 0x167b0
movq (%r15), %rdi
movl %r14d, %esi
movl %ebp, %edx
callq 0x1cd86
addq $0x10, %rbx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x16840
movq (%r15), %rdi
cmpq %r12, %rdi
je 0x1cf54
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x166c0
addq $0x1b0, %rsp # imm = 0x1B0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0xeaff2(%rip), %rsi # 0x107f60
leaq 0x30(%rsp), %rdi
callq 0x169a0
leaq 0xa8(%rsp), %rdi
callq 0x16210
jmp 0x1cf8a
movq %rax, %rbx
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1cfa5
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x166c0
movq %rbx, %rdi
callq 0x16c90
nop
|
_ZN12ConfigNumberItE3setEPKc:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 1B0h
mov rbx, rdi
lea r14, [rsp+1D8h+var_1C8]
lea rdx, [rsp+1D8h+var_1C9]
mov rdi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rdi, [rsp+1D8h+var_1A8]
mov rsi, r14
mov edx, 8
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode; std::istringstream::basic_istringstream(std::string const&,std::_Ios_Openmode)
lea rsi, [rbx+8]
lea rdi, [rsp+1D8h+var_1A8]
call __ZNSi10_M_extractItEERSiRT_; std::istream::_M_extract<ushort>(ushort &)
mov rsi, cs:_ZTTNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+1D8h+var_1A8]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED2Ev; std::istringstream::~istringstream()
lea rdi, [rsp+1D8h+var_130]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
lea rax, [rsp+1D8h+var_1B8]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_1CEA5
mov rsi, [rsp+1D8h+var_1B8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_1CEA5:
movzx eax, word ptr [rbx+8]
xor ecx, ecx
cmp [rbx+0Ch], ax
setb cl
cmp ax, [rbx+0Ah]
lea rax, ds:8[rcx*4]
mov ecx, 0Ah
cmovnb rcx, rax
movzx ebp, word ptr [rbx+rcx]
mov [rbx+8], bp
mov r14d, 1
cmp ebp, 0Ah
jb short loc_1CF04
mov r14d, 2
cmp bp, 64h ; 'd'
jb short loc_1CF04
mov r14d, 3
cmp ebp, 3E8h
jb short loc_1CF04
cmp ebp, 2710h
mov r14d, 5
sbb r14d, 0
loc_1CF04:
mov esi, r14d
lea r12, [rsp+1D8h+var_198]
mov [r12-10h], r12
lea r15, [rsp+1D8h+var_1A8]
mov rdi, r15
mov edx, 2Dh ; '-'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructEmc; std::string::_M_construct(ulong,char)
mov rdi, [r15]
mov esi, r14d
mov edx, ebp
call _ZNSt8__detail18__to_chars_10_implIjEEvPcjT_; std::__detail::__to_chars_10_impl<uint>(char *,uint,uint)
add rbx, 10h
mov rdi, rbx
mov rsi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&)
mov rdi, [r15]; void *
cmp rdi, r12
jz short loc_1CF54
mov rsi, [rsp+1D8h+var_198]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_1CF54:
add rsp, 1B0h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
mov rbx, rax
mov rsi, cs:_ZTTNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+arg_28]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED2Ev; std::istringstream::~istringstream()
lea rdi, [rsp+arg_A0]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
jmp short loc_1CF8A
mov rbx, rax
loc_1CF8A:
lea rax, [rsp+arg_18]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_1CFA5
mov rsi, [rsp+arg_18]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_1CFA5:
mov rdi, rbx
call __Unwind_Resume
|
void ConfigNumber<unsigned short>::set(_WORD *a1, long long a2)
{
unsigned __int16 v2; // ax
bool v3; // cf
long long v4; // rax
long long v5; // rcx
unsigned int v6; // ebp
unsigned int v7; // r14d
void *v8[2]; // [rsp+10h] [rbp-1C8h] BYREF
long long v9; // [rsp+20h] [rbp-1B8h] BYREF
void *v10[2]; // [rsp+30h] [rbp-1A8h] BYREF
_QWORD v11[13]; // [rsp+40h] [rbp-198h] BYREF
_BYTE v12[304]; // [rsp+A8h] [rbp-130h] BYREF
std::string::basic_string<std::allocator<char>>(v8, a2);
std::istringstream::basic_istringstream(v10, v8, 8LL);
std::istream::_M_extract<unsigned short>(v10, a1 + 4);
std::istringstream::~istringstream(v10, &`VTT for'std::istringstream);
std::ios_base::~ios_base((std::ios_base *)v12);
if ( v8[0] != &v9 )
operator delete(v8[0], v9 + 1);
v2 = a1[4];
v3 = v2 < a1[5];
v4 = 4LL * (a1[6] < v2) + 8;
v5 = 10LL;
if ( !v3 )
v5 = v4;
v6 = *(unsigned __int16 *)((char *)a1 + v5);
a1[4] = v6;
v7 = 1;
if ( v6 >= 0xA )
{
v7 = 2;
if ( (unsigned __int16)v6 >= 0x64u )
{
v7 = 3;
if ( v6 >= 0x3E8 )
v7 = ((v6 | 0x500000000uLL) - 10000) >> 32;
}
}
v10[0] = v11;
std::string::_M_construct(v10, v7, 45LL);
std::__detail::__to_chars_10_impl<unsigned int>((char *)v10[0], v7, v6);
std::string::operator=(a1 + 8, v10);
if ( v10[0] != v11 )
operator delete(v10[0], v11[0] + 1LL);
}
|
set:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x1b0
MOV RBX,RDI
LEA R14,[RSP + 0x10]
LEA RDX,[RSP + 0xf]
MOV RDI,R14
CALL 0x0011b480
LAB_0011ce4c:
LEA RDI,[RSP + 0x30]
MOV RSI,R14
MOV EDX,0x8
CALL 0x00116bb0
LEA RSI,[RBX + 0x8]
LAB_0011ce62:
LEA RDI,[RSP + 0x30]
CALL 0x00116a00
LAB_0011ce6c:
MOV RSI,qword ptr [0x00207f60]
LEA RDI,[RSP + 0x30]
CALL 0x001169a0
LEA RDI,[RSP + 0xa8]
CALL 0x00116210
LEA RAX,[RSP + 0x20]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0011cea5
MOV RSI,qword ptr [RSP + 0x20]
INC RSI
CALL 0x001166c0
LAB_0011cea5:
MOVZX EAX,word ptr [RBX + 0x8]
XOR ECX,ECX
CMP word ptr [RBX + 0xc],AX
SETC CL
CMP AX,word ptr [RBX + 0xa]
LEA RAX,[0x8 + RCX*0x4]
MOV ECX,0xa
CMOVNC RCX,RAX
MOVZX EBP,word ptr [RBX + RCX*0x1]
MOV word ptr [RBX + 0x8],BP
MOV R14D,0x1
CMP EBP,0xa
JC 0x0011cf04
MOV R14D,0x2
CMP BP,0x64
JC 0x0011cf04
MOV R14D,0x3
CMP EBP,0x3e8
JC 0x0011cf04
CMP EBP,0x2710
MOV R14D,0x5
SBB R14D,0x0
LAB_0011cf04:
MOV ESI,R14D
LEA R12,[RSP + 0x40]
MOV qword ptr [R12 + -0x10],R12
LEA R15,[RSP + 0x30]
MOV RDI,R15
MOV EDX,0x2d
CALL 0x001167b0
MOV RDI,qword ptr [R15]
MOV ESI,R14D
MOV EDX,EBP
CALL 0x0011cd86
ADD RBX,0x10
MOV RDI,RBX
MOV RSI,R15
CALL 0x00116840
MOV RDI,qword ptr [R15]
CMP RDI,R12
JZ 0x0011cf54
MOV RSI,qword ptr [RSP + 0x40]
INC RSI
CALL 0x001166c0
LAB_0011cf54:
ADD RSP,0x1b0
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
/* ConfigNumber<unsigned short>::set(char const*) */
void __thiscall ConfigNumber<unsigned_short>::set(ConfigNumber<unsigned_short> *this,char *param_1)
{
ushort uVar1;
long lVar2;
uint uVar3;
uint uVar4;
allocator local_1c9;
long *local_1c8 [2];
long local_1b8 [2];
long *local_1a8 [2];
long local_198 [13];
ios_base local_130 [264];
std::__cxx11::string::string<std::allocator<char>>((string *)local_1c8,param_1,&local_1c9);
/* try { // try from 0011ce4c to 0011ce5d has its CatchHandler @ 0011cf87 */
std::__cxx11::istringstream::istringstream((istringstream *)local_1a8,(string *)local_1c8,8);
/* try { // try from 0011ce62 to 0011ce6b has its CatchHandler @ 0011cf64 */
std::istream::_M_extract<unsigned_short>((ushort *)local_1a8);
std::__cxx11::istringstream::~istringstream((istringstream *)local_1a8);
std::ios_base::~ios_base(local_130);
if (local_1c8[0] != local_1b8) {
operator_delete(local_1c8[0],local_1b8[0] + 1);
}
lVar2 = 10;
if (*(ushort *)(this + 10) <= *(ushort *)(this + 8)) {
lVar2 = (ulong)(*(ushort *)(this + 0xc) < *(ushort *)(this + 8)) * 4 + 8;
}
uVar1 = *(ushort *)(this + lVar2);
*(ushort *)(this + 8) = uVar1;
uVar4 = 1;
uVar3 = (uint)uVar1;
if (((9 < uVar3) && (uVar4 = 2, 99 < uVar1)) && (uVar4 = 3, 999 < uVar3)) {
uVar4 = 5 - (uVar3 < 10000);
}
local_1a8[0] = local_198;
std::__cxx11::string::_M_construct((ulong)local_1a8,(char)uVar4);
std::__detail::__to_chars_10_impl<unsigned_int>((char *)local_1a8[0],uVar4,uVar3);
std::__cxx11::string::operator=((string *)(this + 0x10),(string *)local_1a8);
if (local_1a8[0] != local_198) {
operator_delete(local_1a8[0],local_198[0] + 1);
}
return;
}
|
|
19,998
|
testing::internal::GetArgvs[abi:cxx11]()
|
seiftnesse[P]memoryallocator/build_O1/_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_)
}
|
O1
|
cpp
|
testing::internal::GetArgvs[abi:cxx11]():
pushq %rbx
movq %rdi, %rbx
leaq 0x41429ef(%rip), %rsi # 0x415df00
callq 0x35632
movq %rbx, %rax
popq %rbx
retq
|
_ZN7testing8internal8GetArgvsB5cxx11Ev:
push rbx
mov rbx, 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, rbx
pop rbx
retn
|
long long testing::internal::GetArgvs[abi:cxx11](long long a1)
{
std::vector<std::string>::vector(a1, &testing::internal::g_argvs[abi:cxx11]);
return a1;
}
|
GetArgvs[abi:cxx11]:
PUSH RBX
MOV RBX,RDI
LEA RSI,[0x425df00]
CALL 0x00135632
MOV RAX,RBX
POP RBX
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;
}
|
|
19,999
|
get_charsets_dir
|
eloqsql/mysys/charset.c
|
char *get_charsets_dir(char *buf)
{
const char *sharedir= SHAREDIR;
char *res;
DBUG_ENTER("get_charsets_dir");
if (charsets_dir != NULL)
strmake(buf, charsets_dir, FN_REFLEN-1);
else
{
if (test_if_hard_path(sharedir) ||
is_prefix(sharedir, DEFAULT_CHARSET_HOME))
strxmov(buf, sharedir, "/", CHARSET_DIR, NullS);
else
strxmov(buf, DEFAULT_CHARSET_HOME, "/", sharedir, "/", CHARSET_DIR,
NullS);
}
res= convert_dirname(buf,buf,NullS);
DBUG_PRINT("info",("charsets dir: '%s'", buf));
DBUG_RETURN(res);
}
|
O3
|
c
|
get_charsets_dir:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x342a85(%rip), %rax # 0x36e4b0
movq (%rax), %rsi
testq %rsi, %rsi
je 0x2ba42
movl $0x1ff, %edx # imm = 0x1FF
movq %rbx, %rdi
callq 0x5f400
jmp 0x2ba8b
leaq 0x367a5(%rip), %rdi # 0x621ee
callq 0x3086e
testl %eax, %eax
jne 0x2ba69
leaq 0x36795(%rip), %rdi # 0x621ee
leaq 0x367a7(%rip), %rsi # 0x62207
callq 0x5dac4
testl %eax, %eax
je 0x2ba9e
leaq 0x3677e(%rip), %rsi # 0x621ee
leaq 0x37966(%rip), %rdx # 0x633dd
leaq 0x3679c(%rip), %rcx # 0x6221a
movq %rbx, %rdi
xorl %r8d, %r8d
xorl %eax, %eax
callq 0x5f458
movq %rbx, %rdi
movq %rbx, %rsi
xorl %edx, %edx
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x2ea1b
movq $0x0, (%rsp)
leaq 0x3675a(%rip), %rsi # 0x62207
leaq 0x3673a(%rip), %rcx # 0x621ee
leaq 0x37922(%rip), %rdx # 0x633dd
leaq 0x36758(%rip), %r9 # 0x6221a
movq %rbx, %rdi
movq %rdx, %r8
xorl %eax, %eax
callq 0x5f458
jmp 0x2ba8b
|
get_charsets_dir:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdi
lea rax, charsets_dir
mov rsi, [rax]
test rsi, rsi
jz short loc_2BA42
mov edx, 1FFh
mov rdi, rbx
call strmake
jmp short loc_2BA8B
loc_2BA42:
lea rdi, aHomeMonoInstal; "/home/mono/install/share"
call test_if_hard_path
test eax, eax
jnz short loc_2BA69
lea rdi, aHomeMonoInstal; "/home/mono/install/share"
lea rsi, aHomeMonoInstal_0; "/home/mono/install"
call is_prefix
test eax, eax
jz short loc_2BA9E
loc_2BA69:
lea rsi, aHomeMonoInstal; "/home/mono/install/share"
lea rdx, unk_633DD
lea rcx, aCharsets; "charsets/"
mov rdi, rbx
xor r8d, r8d
xor eax, eax
call strxmov
loc_2BA8B:
mov rdi, rbx
mov rsi, rbx
xor edx, edx
add rsp, 8
pop rbx
pop rbp
jmp convert_dirname
loc_2BA9E:
mov [rsp+10h+var_10], 0
lea rsi, aHomeMonoInstal_0; "/home/mono/install"
lea rcx, aHomeMonoInstal; "/home/mono/install/share"
lea rdx, unk_633DD
lea r9, aCharsets; "charsets/"
mov rdi, rbx
mov r8, rdx
xor eax, eax
call strxmov
jmp short loc_2BA8B
|
long long get_charsets_dir(long long a1)
{
char v1; // al
int v2; // r9d
char v4; // [rsp+0h] [rbp-10h]
v4 = v1;
if ( charsets_dir )
{
strmake(a1, charsets_dir, 511LL);
}
else if ( (unsigned int)test_if_hard_path("/home/mono/install/share")
|| (unsigned int)is_prefix("/home/mono/install/share", "/home/mono/install") )
{
strxmov(
a1,
(unsigned int)"/home/mono/install/share",
(unsigned int)&unk_633DD,
(unsigned int)"charsets/",
0,
v2,
v4);
}
else
{
strxmov(
a1,
(unsigned int)"/home/mono/install",
(unsigned int)&unk_633DD,
(unsigned int)"/home/mono/install/share",
(unsigned int)&unk_633DD,
(unsigned int)"charsets/",
0);
}
return convert_dirname(a1, a1, 0LL);
}
|
get_charsets_dir:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RBX,RDI
LEA RAX,[0x46e4b0]
MOV RSI,qword ptr [RAX]
TEST RSI,RSI
JZ 0x0012ba42
MOV EDX,0x1ff
MOV RDI,RBX
CALL 0x0015f400
JMP 0x0012ba8b
LAB_0012ba42:
LEA RDI,[0x1621ee]
CALL 0x0013086e
TEST EAX,EAX
JNZ 0x0012ba69
LEA RDI,[0x1621ee]
LEA RSI,[0x162207]
CALL 0x0015dac4
TEST EAX,EAX
JZ 0x0012ba9e
LAB_0012ba69:
LEA RSI,[0x1621ee]
LEA RDX,[0x1633dd]
LEA RCX,[0x16221a]
MOV RDI,RBX
XOR R8D,R8D
XOR EAX,EAX
CALL 0x0015f458
LAB_0012ba8b:
MOV RDI,RBX
MOV RSI,RBX
XOR EDX,EDX
ADD RSP,0x8
POP RBX
POP RBP
JMP 0x0012ea1b
LAB_0012ba9e:
MOV qword ptr [RSP],0x0
LEA RSI,[0x162207]
LEA RCX,[0x1621ee]
LEA RDX,[0x1633dd]
LEA R9,[0x16221a]
MOV RDI,RBX
MOV R8,RDX
XOR EAX,EAX
CALL 0x0015f458
JMP 0x0012ba8b
|
void get_charsets_dir(int8 param_1)
{
int iVar1;
if (charsets_dir == 0) {
iVar1 = test_if_hard_path("/home/mono/install/share");
if (iVar1 == 0) {
iVar1 = is_prefix("/home/mono/install/share","/home/mono/install");
if (iVar1 == 0) {
strxmov(param_1,"/home/mono/install",&DAT_001633dd,"/home/mono/install/share",&DAT_001633dd,
"charsets/",0);
goto LAB_0012ba8b;
}
}
strxmov(param_1,"/home/mono/install/share",&DAT_001633dd,"charsets/",0);
}
else {
strmake(param_1,charsets_dir,0x1ff);
}
LAB_0012ba8b:
convert_dirname(param_1,param_1,0);
return;
}
|
Subsets and Splits
C++ Functions Using STL
Identifies C++ functions that depend on standard library components, revealing patterns in how developers utilize STL libraries and potentially highlighting common coding practices or dependencies in the dataset.
C++ STL Function Queries
Filters C++ code examples that use standard library containers and algorithms, helping identify common programming patterns and library usage in code generation tasks.
Random Training Function Samples
Performs basic filtering and random sampling of assembly code data without revealing meaningful patterns or relationships.
Random Training Function Samples
Retrieves a random sample of 1000 records from the training dataset, providing basic data exploration but offering limited analytical value beyond seeing raw entries.