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
|
---|---|---|---|---|---|---|---|---|---|---|---|
9,900 |
ma_bitmap_create_missing_into_pagecache
|
eloqsql/storage/maria/ma_bitmap.c
|
static my_bool
_ma_bitmap_create_missing_into_pagecache(MARIA_SHARE *share,
MARIA_FILE_BITMAP *bitmap,
pgcache_page_no_t from,
pgcache_page_no_t to,
uchar *zeroes)
{
pgcache_page_no_t i;
/*
We do not use my_chsize() because there can be a race between when it
reads the physical size and when it writes (assume data_file_length is 10,
physical length is 8 and two data pages are in cache, and here we do a
my_chsize: my_chsize sees physical length is 8, then the two data pages go
to disk then my_chsize writes from page 8 and so overwrites the two data
pages, wrongly).
We instead rely on the filesystem filling gaps with zeroes.
*/
for (i= from; i <= to; i+= bitmap->pages_covered)
{
/**
No need to keep them pinned, they are new so flushable.
@todo but we may want to keep them pinned, as an optimization: if they
are not pinned they may go to disk before the data pages go (so, the
physical pages would be in non-ascending "sparse" order on disk), or the
filesystem may fill gaps with zeroes physically which is a waste of
time.
*/
if (pagecache_write(share->pagecache,
&bitmap->file, i, 0,
zeroes, PAGECACHE_PLAIN_PAGE,
PAGECACHE_LOCK_LEFT_UNLOCKED,
PAGECACHE_PIN_LEFT_UNPINNED,
PAGECACHE_WRITE_DELAY, 0, LSN_IMPOSSIBLE))
goto err;
}
/*
Data pages after data_file_length are full of zeroes but that is allowed
as they are marked empty in the bitmap.
*/
return FALSE;
err:
_ma_set_fatal_error_with_share(share, my_errno);
return TRUE;
}
|
O0
|
c
|
ma_bitmap_create_missing_into_pagecache:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
cmpq -0x28(%rbp), %rax
ja 0x44686
movq -0x10(%rbp), %rax
movq 0x600(%rax), %rdi
movq -0x18(%rbp), %rsi
addq $0x40, %rsi
movq -0x38(%rbp), %rdx
movq -0x30(%rbp), %r8
movq -0x10(%rbp), %rax
movq 0x600(%rax), %rax
movl 0x80(%rax), %eax
xorl %ecx, %ecx
movl $0x1, %r9d
xorl %r10d, %r10d
movl $0x0, (%rsp)
movl $0x1, 0x8(%rsp)
movl $0x0, 0x10(%rsp)
movq $0x0, 0x18(%rsp)
movq $0x0, 0x20(%rsp)
movl $0x0, 0x28(%rsp)
movl %eax, 0x30(%rsp)
callq 0x2f040
cmpb $0x0, %al
je 0x4466c
jmp 0x4468c
jmp 0x4466e
movq -0x18(%rbp), %rax
movq 0x138(%rax), %rax
addq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x445e7
movb $0x0, -0x1(%rbp)
jmp 0x446a8
movq -0x10(%rbp), %rax
movq %rax, -0x40(%rbp)
callq 0xf6090
movq -0x40(%rbp), %rdi
movl (%rax), %esi
callq 0x33910
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x80, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
_ma_bitmap_create_missing_into_pagecache:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov [rbp+var_30], r8
mov rax, [rbp+var_20]
mov [rbp+var_38], rax
loc_445E7:
mov rax, [rbp+var_38]
cmp rax, [rbp+var_28]
ja loc_44686
mov rax, [rbp+var_10]
mov rdi, [rax+600h]
mov rsi, [rbp+var_18]
add rsi, 40h ; '@'
mov rdx, [rbp+var_38]
mov r8, [rbp+var_30]
mov rax, [rbp+var_10]
mov rax, [rax+600h]
mov eax, [rax+80h]
xor ecx, ecx
mov r9d, 1
xor r10d, r10d
mov [rsp+80h+var_80], 0
mov [rsp+80h+var_78], 1
mov [rsp+80h+var_70], 0
mov [rsp+80h+var_68], 0
mov [rsp+80h+var_60], 0
mov [rsp+80h+var_58], 0
mov [rsp+80h+var_50], eax
call pagecache_write_part
cmp al, 0
jz short loc_4466C
jmp short loc_4468C
loc_4466C:
jmp short $+2
loc_4466E:
mov rax, [rbp+var_18]
mov rax, [rax+138h]
add rax, [rbp+var_38]
mov [rbp+var_38], rax
jmp loc_445E7
loc_44686:
mov [rbp+var_1], 0
jmp short loc_446A8
loc_4468C:
mov rax, [rbp+var_10]
mov [rbp+var_40], rax
call _my_thread_var
mov rdi, [rbp+var_40]
mov esi, [rax]
call _ma_set_fatal_error_with_share
mov [rbp+var_1], 1
loc_446A8:
mov al, [rbp+var_1]
add rsp, 80h
pop rbp
retn
|
char ma_bitmap_create_missing_into_pagecache(
long long a1,
long long a2,
unsigned long long a3,
unsigned long long a4,
long long a5)
{
int *v5; // rax
long long v6; // rdx
long long v7; // rcx
long long v8; // r8
int v9; // r9d
while ( 1 )
{
if ( a3 > a4 )
return 0;
if ( pagecache_write_part(
*(_QWORD **)(a1 + 1536),
a2 + 64,
a3,
0,
a5,
1u,
0,
1u,
0,
0LL,
0LL,
0,
*(_DWORD *)(*(_QWORD *)(a1 + 1536) + 128LL)) )
{
break;
}
a3 += *(_QWORD *)(a2 + 312);
}
v5 = (int *)my_thread_var();
ma_set_fatal_error_with_share(a1, *v5, v6, v7, v8, v9);
return 1;
}
|
_ma_bitmap_create_missing_into_pagecache:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV qword ptr [RBP + -0x30],R8
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x38],RAX
LAB_001445e7:
MOV RAX,qword ptr [RBP + -0x38]
CMP RAX,qword ptr [RBP + -0x28]
JA 0x00144686
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX + 0x600]
MOV RSI,qword ptr [RBP + -0x18]
ADD RSI,0x40
MOV RDX,qword ptr [RBP + -0x38]
MOV R8,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x600]
MOV EAX,dword ptr [RAX + 0x80]
XOR ECX,ECX
MOV R9D,0x1
XOR R10D,R10D
MOV dword ptr [RSP],0x0
MOV dword ptr [RSP + 0x8],0x1
MOV dword ptr [RSP + 0x10],0x0
MOV qword ptr [RSP + 0x18],0x0
MOV qword ptr [RSP + 0x20],0x0
MOV dword ptr [RSP + 0x28],0x0
MOV dword ptr [RSP + 0x30],EAX
CALL 0x0012f040
CMP AL,0x0
JZ 0x0014466c
JMP 0x0014468c
LAB_0014466c:
JMP 0x0014466e
LAB_0014466e:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x138]
ADD RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x38],RAX
JMP 0x001445e7
LAB_00144686:
MOV byte ptr [RBP + -0x1],0x0
JMP 0x001446a8
LAB_0014468c:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x40],RAX
CALL 0x001f6090
MOV RDI,qword ptr [RBP + -0x40]
MOV ESI,dword ptr [RAX]
CALL 0x00133910
MOV byte ptr [RBP + -0x1],0x1
LAB_001446a8:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x80
POP RBP
RET
|
int1
_ma_bitmap_create_missing_into_pagecache
(long param_1,long param_2,ulong param_3,ulong param_4,int8 param_5)
{
char cVar1;
int4 *puVar2;
ulong local_40;
local_40 = param_3;
while( true ) {
if (param_4 < local_40) {
return 0;
}
cVar1 = pagecache_write_part
(*(int8 *)(param_1 + 0x600),param_2 + 0x40,local_40,0,param_5,1,0,1,0,0,
0,0,*(int4 *)(*(long *)(param_1 + 0x600) + 0x80));
if (cVar1 != '\0') break;
local_40 = *(long *)(param_2 + 0x138) + local_40;
}
puVar2 = (int4 *)_my_thread_var();
_ma_set_fatal_error_with_share(param_1,*puVar2);
return 1;
}
|
|
9,901 |
end_simple_key_cache
|
eloqsql/mysys/mf_keycache.c
|
static
void end_simple_key_cache(SIMPLE_KEY_CACHE_CB *keycache, my_bool cleanup)
{
DBUG_ENTER("end_simple_key_cache");
DBUG_PRINT("enter", ("key_cache: %p", keycache));
if (!keycache->key_cache_inited)
DBUG_VOID_RETURN;
if (keycache->disk_blocks > 0)
{
if (keycache->block_mem)
{
my_large_free((uchar*) keycache->block_mem, keycache->allocated_mem_size);
keycache->block_mem= NULL;
my_free(keycache->block_root);
keycache->block_root= NULL;
}
keycache->disk_blocks= -1;
/* Reset blocks_changed to be safe if flush_all_key_blocks is called */
keycache->blocks_changed= 0;
}
DBUG_PRINT("status", ("used: %lu changed: %lu w_requests: %lu "
"writes: %lu r_requests: %lu reads: %lu",
keycache->blocks_used, keycache->global_blocks_changed,
(ulong) keycache->global_cache_w_requests,
(ulong) keycache->global_cache_write,
(ulong) keycache->global_cache_r_requests,
(ulong) keycache->global_cache_read));
/*
Reset these values to be able to detect a disabled key cache.
See Bug#44068 (RESTORE can disable the MyISAM Key Cache).
*/
keycache->blocks_used= 0;
keycache->blocks_unused= 0;
if (cleanup)
{
mysql_mutex_destroy(&keycache->cache_lock);
keycache->key_cache_inited= keycache->can_be_used= 0;
KEYCACHE_DEBUG_CLOSE;
}
DBUG_VOID_RETURN;
}
|
O0
|
c
|
end_simple_key_cache:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movb %sil, %al
movq %rdi, -0x8(%rbp)
movb %al, -0x9(%rbp)
jmp 0xe6b04
movq -0x8(%rbp), %rax
cmpb $0x0, (%rax)
jne 0xe6b14
jmp 0xe6b0f
jmp 0xe6bce
movq -0x8(%rbp), %rax
cmpl $0x0, 0x48(%rax)
jle 0xe6b89
movq -0x8(%rbp), %rax
cmpq $0x0, 0xa8(%rax)
je 0xe6b72
movq -0x8(%rbp), %rax
movq 0xa8(%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rsi
callq 0x101f00
movq -0x8(%rbp), %rax
movq $0x0, 0xa8(%rax)
movq -0x8(%rbp), %rax
movq 0xa0(%rax), %rdi
callq 0xf3bb0
movq -0x8(%rbp), %rax
movq $0x0, 0xa0(%rax)
movq -0x8(%rbp), %rax
movl $0xffffffff, 0x48(%rax) # imm = 0xFFFFFFFF
movq -0x8(%rbp), %rax
movq $0x0, 0x60(%rax)
jmp 0xe6b8b
jmp 0xe6b8d
movq -0x8(%rbp), %rax
movq $0x0, 0x50(%rax)
movq -0x8(%rbp), %rax
movq $0x0, 0x58(%rax)
cmpb $0x0, -0x9(%rbp)
je 0xe6bca
movq -0x8(%rbp), %rdi
addq $0xc0, %rdi
callq 0xe7c00
movq -0x8(%rbp), %rax
movb $0x0, 0x3(%rax)
movq -0x8(%rbp), %rax
movb $0x0, (%rax)
jmp 0xe6bcc
jmp 0xe6bce
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
end_simple_key_cache:
push rbp
mov rbp, rsp
sub rsp, 10h
mov al, sil
mov [rbp+var_8], rdi
mov [rbp+var_9], al
jmp short $+2
loc_E6B04:
mov rax, [rbp+var_8]
cmp byte ptr [rax], 0
jnz short loc_E6B14
jmp short $+2
loc_E6B0F:
jmp loc_E6BCE
loc_E6B14:
mov rax, [rbp+var_8]
cmp dword ptr [rax+48h], 0
jle short loc_E6B89
mov rax, [rbp+var_8]
cmp qword ptr [rax+0A8h], 0
jz short loc_E6B72
mov rax, [rbp+var_8]
mov rdi, [rax+0A8h]
mov rax, [rbp+var_8]
mov rsi, [rax+10h]
call my_large_free
mov rax, [rbp+var_8]
mov qword ptr [rax+0A8h], 0
mov rax, [rbp+var_8]
mov rdi, [rax+0A0h]
call my_free
mov rax, [rbp+var_8]
mov qword ptr [rax+0A0h], 0
loc_E6B72:
mov rax, [rbp+var_8]
mov dword ptr [rax+48h], 0FFFFFFFFh
mov rax, [rbp+var_8]
mov qword ptr [rax+60h], 0
loc_E6B89:
jmp short $+2
loc_E6B8B:
jmp short $+2
loc_E6B8D:
mov rax, [rbp+var_8]
mov qword ptr [rax+50h], 0
mov rax, [rbp+var_8]
mov qword ptr [rax+58h], 0
cmp [rbp+var_9], 0
jz short loc_E6BCA
mov rdi, [rbp+var_8]
add rdi, 0C0h
call inline_mysql_mutex_destroy_7
mov rax, [rbp+var_8]
mov byte ptr [rax+3], 0
mov rax, [rbp+var_8]
mov byte ptr [rax], 0
loc_E6BCA:
jmp short $+2
loc_E6BCC:
jmp short $+2
loc_E6BCE:
add rsp, 10h
pop rbp
retn
|
long long end_simple_key_cache(long long a1, char a2)
{
long long result; // rax
result = a1;
if ( *(_BYTE *)a1 )
{
if ( *(int *)(a1 + 72) > 0 )
{
if ( *(_QWORD *)(a1 + 168) )
{
my_large_free(*(_QWORD *)(a1 + 168), *(_QWORD *)(a1 + 16));
*(_QWORD *)(a1 + 168) = 0LL;
my_free(*(_QWORD *)(a1 + 160));
*(_QWORD *)(a1 + 160) = 0LL;
}
*(_DWORD *)(a1 + 72) = -1;
*(_QWORD *)(a1 + 96) = 0LL;
}
*(_QWORD *)(a1 + 80) = 0LL;
result = a1;
*(_QWORD *)(a1 + 88) = 0LL;
if ( a2 )
{
inline_mysql_mutex_destroy_7(a1 + 192);
*(_BYTE *)(a1 + 3) = 0;
result = a1;
*(_BYTE *)a1 = 0;
}
}
return result;
}
|
end_simple_key_cache:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV AL,SIL
MOV qword ptr [RBP + -0x8],RDI
MOV byte ptr [RBP + -0x9],AL
JMP 0x001e6b04
LAB_001e6b04:
MOV RAX,qword ptr [RBP + -0x8]
CMP byte ptr [RAX],0x0
JNZ 0x001e6b14
JMP 0x001e6b0f
LAB_001e6b0f:
JMP 0x001e6bce
LAB_001e6b14:
MOV RAX,qword ptr [RBP + -0x8]
CMP dword ptr [RAX + 0x48],0x0
JLE 0x001e6b89
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0xa8],0x0
JZ 0x001e6b72
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX + 0xa8]
MOV RAX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RAX + 0x10]
CALL 0x00201f00
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0xa8],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX + 0xa0]
CALL 0x001f3bb0
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0xa0],0x0
LAB_001e6b72:
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x48],0xffffffff
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x60],0x0
LAB_001e6b89:
JMP 0x001e6b8b
LAB_001e6b8b:
JMP 0x001e6b8d
LAB_001e6b8d:
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x50],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x58],0x0
CMP byte ptr [RBP + -0x9],0x0
JZ 0x001e6bca
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0xc0
CALL 0x001e7c00
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x3],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX],0x0
LAB_001e6bca:
JMP 0x001e6bcc
LAB_001e6bcc:
JMP 0x001e6bce
LAB_001e6bce:
ADD RSP,0x10
POP RBP
RET
|
void end_simple_key_cache(char *param_1,char param_2)
{
if (*param_1 != '\0') {
if (0 < *(int *)(param_1 + 0x48)) {
if (*(long *)(param_1 + 0xa8) != 0) {
my_large_free(*(int8 *)(param_1 + 0xa8),*(int8 *)(param_1 + 0x10));
param_1[0xa8] = '\0';
param_1[0xa9] = '\0';
param_1[0xaa] = '\0';
param_1[0xab] = '\0';
param_1[0xac] = '\0';
param_1[0xad] = '\0';
param_1[0xae] = '\0';
param_1[0xaf] = '\0';
my_free(*(int8 *)(param_1 + 0xa0));
param_1[0xa0] = '\0';
param_1[0xa1] = '\0';
param_1[0xa2] = '\0';
param_1[0xa3] = '\0';
param_1[0xa4] = '\0';
param_1[0xa5] = '\0';
param_1[0xa6] = '\0';
param_1[0xa7] = '\0';
}
param_1[0x48] = -1;
param_1[0x49] = -1;
param_1[0x4a] = -1;
param_1[0x4b] = -1;
param_1[0x60] = '\0';
param_1[0x61] = '\0';
param_1[0x62] = '\0';
param_1[99] = '\0';
param_1[100] = '\0';
param_1[0x65] = '\0';
param_1[0x66] = '\0';
param_1[0x67] = '\0';
}
param_1[0x50] = '\0';
param_1[0x51] = '\0';
param_1[0x52] = '\0';
param_1[0x53] = '\0';
param_1[0x54] = '\0';
param_1[0x55] = '\0';
param_1[0x56] = '\0';
param_1[0x57] = '\0';
param_1[0x58] = '\0';
param_1[0x59] = '\0';
param_1[0x5a] = '\0';
param_1[0x5b] = '\0';
param_1[0x5c] = '\0';
param_1[0x5d] = '\0';
param_1[0x5e] = '\0';
param_1[0x5f] = '\0';
if (param_2 != '\0') {
inline_mysql_mutex_destroy(param_1 + 0xc0);
param_1[3] = '\0';
*param_1 = '\0';
}
}
return;
}
|
|
9,902 |
js_async_generator_resume_next
|
bluesky950520[P]quickjs/quickjs.c
|
static void js_async_generator_resume_next(JSContext *ctx,
JSAsyncGeneratorData *s)
{
JSAsyncGeneratorRequest *next;
JSValue func_ret, value;
for(;;) {
if (list_empty(&s->queue))
break;
next = list_entry(s->queue.next, JSAsyncGeneratorRequest, link);
switch(s->state) {
case JS_ASYNC_GENERATOR_STATE_EXECUTING:
/* only happens when restarting execution after await() */
goto resume_exec;
case JS_ASYNC_GENERATOR_STATE_AWAITING_RETURN:
goto done;
case JS_ASYNC_GENERATOR_STATE_SUSPENDED_START:
if (next->completion_type == GEN_MAGIC_NEXT) {
goto exec_no_arg;
} else {
js_async_generator_complete(ctx, s);
}
break;
case JS_ASYNC_GENERATOR_STATE_COMPLETED:
if (next->completion_type == GEN_MAGIC_NEXT) {
js_async_generator_resolve(ctx, s, JS_UNDEFINED, TRUE);
} else if (next->completion_type == GEN_MAGIC_RETURN) {
s->state = JS_ASYNC_GENERATOR_STATE_AWAITING_RETURN;
js_async_generator_completed_return(ctx, s, next->result);
} else {
js_async_generator_reject(ctx, s, next->result);
}
goto done;
case JS_ASYNC_GENERATOR_STATE_SUSPENDED_YIELD:
case JS_ASYNC_GENERATOR_STATE_SUSPENDED_YIELD_STAR:
value = js_dup(next->result);
if (next->completion_type == GEN_MAGIC_THROW &&
s->state == JS_ASYNC_GENERATOR_STATE_SUSPENDED_YIELD) {
JS_Throw(ctx, value);
s->func_state.throw_flag = TRUE;
} else {
/* 'yield' returns a value. 'yield *' also returns a value
in case the 'throw' method is called */
s->func_state.frame.cur_sp[-1] = value;
s->func_state.frame.cur_sp[0] =
js_int32(next->completion_type);
s->func_state.frame.cur_sp++;
exec_no_arg:
s->func_state.throw_flag = FALSE;
}
s->state = JS_ASYNC_GENERATOR_STATE_EXECUTING;
resume_exec:
func_ret = async_func_resume(ctx, &s->func_state);
if (JS_IsException(func_ret)) {
value = JS_GetException(ctx);
js_async_generator_complete(ctx, s);
js_async_generator_reject(ctx, s, value);
JS_FreeValue(ctx, value);
} else if (JS_VALUE_GET_TAG(func_ret) == JS_TAG_INT) {
int func_ret_code, ret;
value = s->func_state.frame.cur_sp[-1];
s->func_state.frame.cur_sp[-1] = JS_UNDEFINED;
func_ret_code = JS_VALUE_GET_INT(func_ret);
switch(func_ret_code) {
case FUNC_RET_YIELD:
case FUNC_RET_YIELD_STAR:
if (func_ret_code == FUNC_RET_YIELD_STAR)
s->state = JS_ASYNC_GENERATOR_STATE_SUSPENDED_YIELD_STAR;
else
s->state = JS_ASYNC_GENERATOR_STATE_SUSPENDED_YIELD;
js_async_generator_resolve(ctx, s, value, FALSE);
JS_FreeValue(ctx, value);
break;
case FUNC_RET_AWAIT:
ret = js_async_generator_await(ctx, s, value);
JS_FreeValue(ctx, value);
if (ret < 0) {
/* exception: throw it */
s->func_state.throw_flag = TRUE;
goto resume_exec;
}
goto done;
default:
abort();
}
} else {
assert(JS_IsUndefined(func_ret));
/* end of function */
value = s->func_state.frame.cur_sp[-1];
s->func_state.frame.cur_sp[-1] = JS_UNDEFINED;
js_async_generator_complete(ctx, s);
js_async_generator_resolve(ctx, s, value, TRUE);
JS_FreeValue(ctx, value);
}
break;
default:
abort();
}
}
done: ;
}
|
O2
|
c
|
js_async_generator_resume_next:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x78(%rsi), %rax
movq %rax, 0x20(%rsp)
leaq 0x10(%rsi), %rax
movq %rax, 0x28(%rsp)
movq %rsi, 0x8(%rsp)
movq 0x80(%r14), %rax
cmpq 0x20(%rsp), %rax
je 0x4d1d5
movl 0x8(%r14), %ecx
cmpq $0x5, %rcx
ja 0x4d335
leaq 0x3a099(%rip), %rsi # 0x87000
movslq (%rsi,%rcx,4), %rdx
addq %rsi, %rdx
jmpq *%rdx
movq 0x18(%rax), %rsi
movq 0x20(%rax), %rdx
cmpl $-0x9, %edx
jb 0x4cf7f
incl (%rsi)
cmpl $0x1, %ecx
jne 0x4cfaa
cmpl $0x2, 0x10(%rax)
jne 0x4cfaa
movq %rbx, %rdi
callq 0x1fff6
pushq $0x1
popq %rax
jmp 0x4cfcc
cmpl $0x0, 0x10(%rax)
je 0x4cfca
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4d33a
jmp 0x4cf40
movq 0x70(%r14), %rcx
movq %rsi, -0x10(%rcx)
movq %rdx, -0x8(%rcx)
movq 0x70(%r14), %rcx
movl 0x10(%rax), %eax
movq %rax, (%rcx)
andq $0x0, 0x8(%rcx)
addq $0x10, 0x70(%r14)
xorl %eax, %eax
movl %eax, 0x24(%r14)
movl $0x3, 0x8(%r14)
movq %rbx, %rdi
movq 0x28(%rsp), %rsi
callq 0x3e977
testl %edx, %edx
jne 0x4d0fe
movq 0x70(%r14), %rcx
movq -0x10(%rcx), %r13
movq -0x8(%rcx), %rbp
andl $0x0, -0x10(%rcx)
movq $0x3, -0x8(%rcx)
testl %eax, %eax
jne 0x4d145
movq %r13, 0x10(%rsp)
movq %rbp, 0x18(%rsp)
movq 0x88(%rbx), %rsi
movq 0x90(%rbx), %rdx
movq %rbx, %rdi
leaq 0x10(%rsp), %r8
xorl %r9d, %r9d
callq 0x4b251
movq %rdx, %r12
cmpl $0x6, %r12d
je 0x4d0e3
movq %rax, %r15
movq (%r14), %rsi
movq %rbx, %rdi
leaq 0x50(%rsp), %r14
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x4d468
testl %eax, %eax
je 0x4d073
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x1bbce
movq 0x8(%rsp), %r14
jmp 0x4d0e3
andl $0x0, 0x30(%rsp)
pushq $0x3
popq %rax
movq %rax, 0x38(%rsp)
andl $0x0, 0x40(%rsp)
movq %rax, 0x48(%rsp)
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
movq %r14, %rcx
leaq 0x30(%rsp), %r8
callq 0x3f781
movl %eax, 0x4(%rsp)
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x1bbce
xorl %r15d, %r15d
movq 0x8(%rsp), %r14
cmpq $0x20, %r15
je 0x4d0d8
movq 0x50(%rsp,%r15), %rsi
movq 0x58(%rsp,%r15), %rdx
movq %rbx, %rdi
callq 0x1bbce
addq $0x10, %r15
jmp 0x4d0ba
cmpl $0x0, 0x4(%rsp)
je 0x4d1c7
movq %rbx, %rdi
movq %r13, %rsi
movq %rbp, %rdx
callq 0x1bbce
movl $0x1, 0x24(%r14)
jmp 0x4cfd8
cmpl $0x6, %edx
jne 0x4d17c
movq 0x18(%rbx), %rax
movq 0xf0(%rax), %r15
movq 0xf8(%rax), %r12
andl $0x0, 0xf0(%rax)
movq $0x4, 0xf8(%rax)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4d33a
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
movq %r12, %rcx
callq 0x4d3ae
jmp 0x4d1b4
leal -0x1(%rax), %ecx
cmpl $0x1, %ecx
ja 0x4d335
movl %eax, 0x8(%r14)
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
movq %rbp, %rcx
xorl %r8d, %r8d
callq 0x4d355
movq %rbx, %rdi
movq %r13, %rsi
movq %rbp, %rdx
callq 0x1bbce
jmp 0x4cf40
movq 0x70(%r14), %rax
movq -0x10(%rax), %r15
movq -0x8(%rax), %r12
andl $0x0, -0x10(%rax)
movq $0x3, -0x8(%rax)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4d33a
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
movq %r12, %rcx
pushq $0x1
popq %r8
callq 0x4d355
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x1bbce
jmp 0x4cf40
movq %rbx, %rdi
movq %r13, %rsi
movq %rbp, %rdx
callq 0x1bbce
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl 0x10(%rax), %ecx
cmpl $0x1, %ecx
je 0x4d20a
testl %ecx, %ecx
jne 0x4d2a7
pushq $0x3
popq %rcx
pushq $0x1
popq %r8
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x4d355
jmp 0x4d1d5
movl $0x4, 0x8(%r14)
movups 0x18(%rax), %xmm0
leaq 0x10(%rsp), %r8
movaps %xmm0, (%r8)
movq 0x88(%rbx), %rsi
movq 0x90(%rbx), %rdx
movq %rbx, %rdi
xorl %r9d, %r9d
callq 0x4b251
movq %rdx, %r12
cmpl $0x6, %r12d
jne 0x4d2bf
movq 0x18(%rbx), %rax
movups 0xf0(%rax), %xmm0
andl $0x0, 0xf0(%rax)
movq $0x4, 0xf8(%rax)
leaq 0x50(%rsp), %r13
movaps %xmm0, (%r13)
movq 0x88(%rbx), %rsi
movq 0x90(%rbx), %rdx
pushq $0x1
popq %r9
movq %rbx, %rdi
movq %r13, %r8
callq 0x4b251
movq %rax, %r15
movq %rdx, %r12
movq (%r13), %rsi
movq 0x8(%r13), %rdx
movq %rbx, %rdi
callq 0x1bbce
cmpl $0x6, %r12d
je 0x4d1d5
jmp 0x4d2c2
movq 0x18(%rax), %rdx
movq 0x20(%rax), %rcx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4d3ae
jmp 0x4d1d5
movq %rax, %r15
movq (%r14), %rsi
leaq 0x30(%rsp), %rdx
pushq $0x1
popq %rcx
movq %rbx, %rdi
callq 0x4d468
testl %eax, %eax
jne 0x4d327
leaq 0x50(%rsp), %r8
andl $0x0, (%r8)
pushq $0x3
popq %rax
movq %rax, 0x8(%r8)
andl $0x0, 0x10(%r8)
movq %rax, 0x18(%r8)
leaq 0x30(%rsp), %r14
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
movq %r14, %rcx
callq 0x3f781
movq (%r14), %rsi
movq 0x8(%r14), %rdx
movq %rbx, %rdi
callq 0x1bbce
movq 0x10(%r14), %rsi
movq 0x18(%r14), %rdx
movq %rbx, %rdi
callq 0x1bbce
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
jmp 0x4d1d0
callq 0xe090
|
js_async_generator_resume_next:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 78h
mov r14, rsi
mov rbx, rdi
lea rax, [rsi+78h]
mov [rsp+0A8h+var_88], rax
lea rax, [rsi+10h]
mov [rsp+0A8h+var_80], rax
mov [rsp+0A8h+var_A0], rsi
loc_4CF40:
mov rax, [r14+80h]
cmp rax, [rsp+0A8h+var_88]
jz loc_4D1D5; jumptable 000000000004CF6E case 4
mov ecx, [r14+8]
cmp rcx, 5; switch 6 cases
ja def_4CF6E; jumptable 000000000004CF6E default case
lea rsi, jpt_4CF6E
movsxd rdx, ds:(jpt_4CF6E - 87000h)[rsi+rcx*4]
add rdx, rsi
jmp rdx; switch jump
loc_4CF70:
mov rsi, [rax+18h]; jumptable 000000000004CF6E cases 1,2
mov rdx, [rax+20h]
cmp edx, 0FFFFFFF7h
jb short loc_4CF7F
inc dword ptr [rsi]
loc_4CF7F:
cmp ecx, 1
jnz short loc_4CFAA
cmp dword ptr [rax+10h], 2
jnz short loc_4CFAA
mov rdi, rbx
call JS_Throw
push 1
pop rax
jmp short loc_4CFCC
loc_4CF97:
cmp dword ptr [rax+10h], 0; jumptable 000000000004CF6E case 0
jz short loc_4CFCA
mov rdi, rbx
mov rsi, r14
call js_async_generator_complete
jmp short loc_4CF40
loc_4CFAA:
mov rcx, [r14+70h]
mov [rcx-10h], rsi
mov [rcx-8], rdx
mov rcx, [r14+70h]
mov eax, [rax+10h]
mov [rcx], rax
and qword ptr [rcx+8], 0
add qword ptr [r14+70h], 10h
loc_4CFCA:
xor eax, eax
loc_4CFCC:
mov [r14+24h], eax
mov dword ptr [r14+8], 3
loc_4CFD8:
mov rdi, rbx; jumptable 000000000004CF6E case 3
mov rsi, [rsp+0A8h+var_80]
call async_func_resume
test edx, edx
jnz loc_4D0FE
mov rcx, [r14+70h]
mov r13, [rcx-10h]
mov rbp, [rcx-8]
and dword ptr [rcx-10h], 0
mov qword ptr [rcx-8], 3
test eax, eax
jnz loc_4D145
mov [rsp+0A8h+var_98], r13
mov [rsp+0A8h+var_90], rbp
mov rsi, [rbx+88h]
mov rdx, [rbx+90h]
mov rdi, rbx
lea r8, [rsp+0A8h+var_98]
xor r9d, r9d
call js_promise_resolve
mov r12, rdx
cmp r12d, 6
jz loc_4D0E3
mov r15, rax
mov rsi, [r14]
mov rdi, rbx
lea r14, [rsp+0A8h+var_58]
mov rdx, r14
xor ecx, ecx
call js_async_generator_resolve_function_create
test eax, eax
jz short loc_4D073
mov rdi, rbx
mov rsi, r15
mov rdx, r12
call JS_FreeValue
mov r14, [rsp+0A8h+var_A0]
jmp short loc_4D0E3
loc_4D073:
and [rsp+0A8h+var_78], 0
push 3
pop rax
mov [rsp+0A8h+var_70], rax
and [rsp+0A8h+var_68], 0
mov [rsp+0A8h+var_60], rax
mov rdi, rbx
mov rsi, r15
mov rdx, r12
mov rcx, r14
lea r8, [rsp+0A8h+var_78]
call perform_promise_then
mov [rsp+0A8h+var_A4], eax
mov rdi, rbx
mov rsi, r15
mov rdx, r12
call JS_FreeValue
xor r15d, r15d
mov r14, [rsp+0A8h+var_A0]
loc_4D0BA:
cmp r15, 20h ; ' '
jz short loc_4D0D8
mov rsi, [rsp+r15+0A8h+var_58]
mov rdx, [rsp+r15+0A8h+var_50]
mov rdi, rbx
call JS_FreeValue
add r15, 10h
jmp short loc_4D0BA
loc_4D0D8:
cmp [rsp+0A8h+var_A4], 0
jz loc_4D1C7
loc_4D0E3:
mov rdi, rbx
mov rsi, r13
mov rdx, rbp
call JS_FreeValue
mov dword ptr [r14+24h], 1
jmp loc_4CFD8; jumptable 000000000004CF6E case 3
loc_4D0FE:
cmp edx, 6
jnz short loc_4D17C
mov rax, [rbx+18h]
mov r15, [rax+0F0h]
mov r12, [rax+0F8h]
and dword ptr [rax+0F0h], 0
mov qword ptr [rax+0F8h], 4
mov rdi, rbx
mov rsi, r14
call js_async_generator_complete
mov rdi, rbx
mov rsi, r14
mov rdx, r15
mov rcx, r12
call js_async_generator_reject
jmp short loc_4D1B4
loc_4D145:
lea ecx, [rax-1]
cmp ecx, 1
ja def_4CF6E; jumptable 000000000004CF6E default case
mov [r14+8], eax
mov rdi, rbx
mov rsi, r14
mov rdx, r13
mov rcx, rbp
xor r8d, r8d
call js_async_generator_resolve
mov rdi, rbx
mov rsi, r13
mov rdx, rbp
call JS_FreeValue
jmp loc_4CF40
loc_4D17C:
mov rax, [r14+70h]
mov r15, [rax-10h]
mov r12, [rax-8]
and dword ptr [rax-10h], 0
mov qword ptr [rax-8], 3
mov rdi, rbx
mov rsi, r14
call js_async_generator_complete
mov rdi, rbx
mov rsi, r14
mov rdx, r15
mov rcx, r12
push 1
pop r8
call js_async_generator_resolve
loc_4D1B4:
mov rdi, rbx
mov rsi, r15
mov rdx, r12
call JS_FreeValue
jmp loc_4CF40
loc_4D1C7:
mov rdi, rbx
mov rsi, r13
mov rdx, rbp
loc_4D1D0:
call JS_FreeValue
loc_4D1D5:
add rsp, 78h; jumptable 000000000004CF6E case 4
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_4D1E4:
mov ecx, [rax+10h]; jumptable 000000000004CF6E case 5
cmp ecx, 1
jz short loc_4D20A
test ecx, ecx
jnz loc_4D2A7
push 3
pop rcx
push 1
pop r8
mov rdi, rbx
mov rsi, r14
xor edx, edx
call js_async_generator_resolve
jmp short loc_4D1D5; jumptable 000000000004CF6E case 4
loc_4D20A:
mov dword ptr [r14+8], 4
movups xmm0, xmmword ptr [rax+18h]
lea r8, [rsp+0A8h+var_98]
movaps xmmword ptr [r8], xmm0
mov rsi, [rbx+88h]
mov rdx, [rbx+90h]
mov rdi, rbx
xor r9d, r9d
call js_promise_resolve
mov r12, rdx
cmp r12d, 6
jnz short loc_4D2BF
mov rax, [rbx+18h]
movups xmm0, xmmword ptr [rax+0F0h]
and dword ptr [rax+0F0h], 0
mov qword ptr [rax+0F8h], 4
lea r13, [rsp+0A8h+var_58]
movaps xmmword ptr [r13+0], xmm0
mov rsi, [rbx+88h]
mov rdx, [rbx+90h]
push 1
pop r9
mov rdi, rbx
mov r8, r13
call js_promise_resolve
mov r15, rax
mov r12, rdx
mov rsi, [r13+0]
mov rdx, [r13+8]
mov rdi, rbx
call JS_FreeValue
cmp r12d, 6
jz loc_4D1D5; jumptable 000000000004CF6E case 4
jmp short loc_4D2C2
loc_4D2A7:
mov rdx, [rax+18h]
mov rcx, [rax+20h]
mov rdi, rbx
mov rsi, r14
call js_async_generator_reject
jmp loc_4D1D5; jumptable 000000000004CF6E case 4
loc_4D2BF:
mov r15, rax
loc_4D2C2:
mov rsi, [r14]
lea rdx, [rsp+0A8h+var_78]
push 1
pop rcx
mov rdi, rbx
call js_async_generator_resolve_function_create
test eax, eax
jnz short loc_4D327
lea r8, [rsp+0A8h+var_58]
and dword ptr [r8], 0
push 3
pop rax
mov [r8+8], rax
and dword ptr [r8+10h], 0
mov [r8+18h], rax
lea r14, [rsp+0A8h+var_78]
mov rdi, rbx
mov rsi, r15
mov rdx, r12
mov rcx, r14
call perform_promise_then
mov rsi, [r14]
mov rdx, [r14+8]
mov rdi, rbx
call JS_FreeValue
mov rsi, [r14+10h]
mov rdx, [r14+18h]
mov rdi, rbx
call JS_FreeValue
loc_4D327:
mov rdi, rbx
mov rsi, r15
mov rdx, r12
jmp loc_4D1D0
def_4CF6E:
call _abort; jumptable 000000000004CF6E default case
|
long long js_async_generator_resume_next(
const char *a1,
long long a2,
long long a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
long long a12,
long long a13,
long long a14)
{
_QWORD *v14; // r14
long long v15; // rbx
long long result; // rax
long long v17; // rcx
_DWORD *v18; // rsi
int v19; // eax
long long v20; // rcx
int v21; // eax
long long v22; // rcx
__m128 v23; // xmm4
__m128 v24; // xmm5
long long v25; // rcx
long long v26; // r13
long long v27; // rbp
_DWORD *v28; // rax
long long v29; // rdx
long long v30; // r12
long long v31; // r15
long long v32; // r15
long long v33; // rax
long long v34; // r15
long long v35; // r12
long long v36; // rax
long long v37; // rdi
long long v38; // rsi
long long v39; // rdx
long long v40; // rcx
_DWORD *v41; // rax
long long v42; // rcx
__m128 v43; // xmm4
__m128 v44; // xmm5
long long v45; // rdx
long long v46; // r12
__m128 *v47; // rax
__m128 v48; // xmm0
_DWORD *v49; // r15
long long v50; // rdx
int v51; // [rsp+4h] [rbp-A4h]
_QWORD *v52; // [rsp+8h] [rbp-A0h]
__m128 v53; // [rsp+10h] [rbp-98h] BYREF
long long v54; // [rsp+20h] [rbp-88h]
long long v55; // [rsp+28h] [rbp-80h]
long long v56; // [rsp+30h] [rbp-78h] BYREF
long long v57; // [rsp+38h] [rbp-70h]
long long v58; // [rsp+40h] [rbp-68h]
long long v59; // [rsp+48h] [rbp-60h]
__m128 v60; // [rsp+50h] [rbp-58h] BYREF
int v61; // [rsp+60h] [rbp-48h]
long long v62; // [rsp+68h] [rbp-40h]
v14 = (_QWORD *)a2;
v15 = (long long)a1;
v54 = a2 + 120;
v55 = a2 + 16;
v52 = (_QWORD *)a2;
while ( 2 )
{
result = v14[16];
if ( result == v54 )
return result;
v17 = *((unsigned int *)v14 + 2);
switch ( *((_DWORD *)v14 + 2) )
{
case 0:
if ( !*(_DWORD *)(result + 16) )
goto LABEL_12;
a1 = (const char *)v15;
a2 = (long long)v14;
js_async_generator_complete(v15, v14, a3, v17);
continue;
case 1:
case 2:
v18 = *(_DWORD **)(result + 24);
a3 = *(_QWORD *)(result + 32);
if ( (unsigned int)a3 >= 0xFFFFFFF7 )
++*v18;
if ( (_DWORD)v17 == 1 && *(_DWORD *)(result + 16) == 2 )
{
JS_Throw(v15, (long long)v18, a3);
v19 = 1;
}
else
{
v20 = v14[14];
*(_QWORD *)(v20 - 16) = v18;
*(_QWORD *)(v20 - 8) = a3;
v17 = v14[14];
*(_QWORD *)v17 = *(unsigned int *)(result + 16);
*(_QWORD *)(v17 + 8) = 0LL;
v14[14] += 16LL;
LABEL_12:
v19 = 0;
}
*((_DWORD *)v14 + 9) = v19;
*((_DWORD *)v14 + 2) = 3;
LABEL_14:
a1 = (const char *)v15;
a2 = v55;
v21 = async_func_resume(v15, v55, a3, v17, a13, a14, a4, a5, a6, a7, a8, a9, a10, a11);
if ( (_DWORD)a3 )
{
if ( (_DWORD)a3 == 6 )
{
v33 = *(_QWORD *)(v15 + 24);
v34 = *(_QWORD *)(v33 + 240);
v35 = *(_QWORD *)(v33 + 248);
*(_DWORD *)(v33 + 240) = 0;
*(_QWORD *)(v33 + 248) = 4LL;
js_async_generator_complete(v15, v14, a3, v22);
js_async_generator_reject(v15, v14, v34, v35);
}
else
{
v36 = v14[14];
v34 = *(_QWORD *)(v36 - 16);
v35 = *(_QWORD *)(v36 - 8);
*(_DWORD *)(v36 - 16) = 0;
*(_QWORD *)(v36 - 8) = 3LL;
js_async_generator_complete(v15, v14, a3, v22);
js_async_generator_resolve(v15, v14, v34, v35, 1LL);
}
a1 = (const char *)v15;
a2 = v34;
JS_FreeValue(v15, v34, v35);
continue;
}
v25 = v14[14];
v26 = *(_QWORD *)(v25 - 16);
v27 = *(_QWORD *)(v25 - 8);
*(_DWORD *)(v25 - 16) = 0;
*(_QWORD *)(v25 - 8) = 3LL;
if ( v21 )
{
v17 = (unsigned int)(v21 - 1);
if ( (unsigned int)v17 > 1 )
LABEL_44:
abort(a1, a2, a3, v17);
*((_DWORD *)v14 + 2) = v21;
js_async_generator_resolve(v15, v14, v26, v27, 0LL);
a1 = (const char *)v15;
a2 = v26;
JS_FreeValue(v15, v26, v27);
continue;
}
v53.m128_u64[0] = v26;
v53.m128_u64[1] = v27;
v28 = js_promise_resolve(
v15,
*(_DWORD **)(v15 + 136),
*(_QWORD *)(v15 + 144),
v25,
&v53,
0LL,
a4,
a5,
a6,
a7,
v23,
v24,
a10,
a11);
v30 = v29;
if ( (_DWORD)v29 == 6 )
{
LABEL_23:
JS_FreeValue(v15, v26, v27);
*((_DWORD *)v14 + 9) = 1;
goto LABEL_14;
}
v31 = (long long)v28;
if ( (unsigned int)js_async_generator_resolve_function_create(v15, *v14, &v60, 0LL) )
{
JS_FreeValue(v15, v31, v30);
v14 = v52;
goto LABEL_23;
}
LODWORD(v56) = 0;
v57 = 3LL;
LODWORD(v58) = 0;
v59 = 3LL;
v51 = perform_promise_then(v15, v31, v30, (long long)&v60, (long long)&v56);
JS_FreeValue(v15, v31, v30);
v32 = 0LL;
v14 = v52;
while ( v32 != 4 )
{
JS_FreeValue(v15, v60.m128_i64[v32], v60.m128_i64[v32 + 1]);
v32 += 2LL;
}
if ( v51 )
goto LABEL_23;
v37 = v15;
v38 = v26;
v39 = v27;
return JS_FreeValue(v37, v38, v39);
case 3:
goto LABEL_14;
case 4:
return result;
case 5:
v40 = *(unsigned int *)(result + 16);
if ( (_DWORD)v40 != 1 )
{
if ( (_DWORD)v40 )
return js_async_generator_reject(v15, v14, *(_QWORD *)(result + 24), *(_QWORD *)(result + 32));
else
return js_async_generator_resolve(v15, v14, 0LL, 3LL, 1LL);
}
*((_DWORD *)v14 + 2) = 4;
v53 = *(__m128 *)(result + 24);
v41 = js_promise_resolve(
v15,
*(_DWORD **)(v15 + 136),
*(_QWORD *)(v15 + 144),
v40,
&v53,
0LL,
v53,
a5,
a6,
a7,
a8,
a9,
a10,
a11);
v46 = v45;
if ( (_DWORD)v45 == 6 )
{
v47 = *(__m128 **)(v15 + 24);
v48 = v47[15];
v47[15].m128_i32[0] = 0;
v47[15].m128_u64[1] = 4LL;
v60 = v48;
v49 = js_promise_resolve(
v15,
*(_DWORD **)(v15 + 136),
*(_QWORD *)(v15 + 144),
v42,
&v60,
1LL,
v48,
a5,
a6,
a7,
v43,
v44,
a10,
a11);
v46 = v50;
result = JS_FreeValue(v15, v60.m128_i64[0], v60.m128_i64[1]);
if ( (_DWORD)v46 == 6 )
return result;
}
else
{
v49 = v41;
}
if ( !(unsigned int)js_async_generator_resolve_function_create(v15, *v14, &v56, 1LL) )
{
v60.m128_i32[0] = 0;
v60.m128_u64[1] = 3LL;
v61 = 0;
v62 = 3LL;
perform_promise_then(v15, (long long)v49, v46, (long long)&v56, (long long)&v60);
JS_FreeValue(v15, v56, v57);
JS_FreeValue(v15, v58, v59);
}
v37 = v15;
v38 = (long long)v49;
v39 = v46;
return JS_FreeValue(v37, v38, v39);
default:
goto LABEL_44;
}
}
}
|
js_async_generator_resume_next:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x78
MOV R14,RSI
MOV RBX,RDI
LEA RAX,[RSI + 0x78]
MOV qword ptr [RSP + 0x20],RAX
LEA RAX,[RSI + 0x10]
MOV qword ptr [RSP + 0x28],RAX
MOV qword ptr [RSP + 0x8],RSI
LAB_0014cf40:
MOV RAX,qword ptr [R14 + 0x80]
CMP RAX,qword ptr [RSP + 0x20]
JZ 0x0014d1d5
MOV ECX,dword ptr [R14 + 0x8]
CMP RCX,0x5
JA 0x0014d335
LEA RSI,[0x187000]
MOVSXD RDX,dword ptr [RSI + RCX*0x4]
ADD RDX,RSI
switchD:
JMP RDX
caseD_1:
MOV RSI,qword ptr [RAX + 0x18]
MOV RDX,qword ptr [RAX + 0x20]
CMP EDX,-0x9
JC 0x0014cf7f
INC dword ptr [RSI]
LAB_0014cf7f:
CMP ECX,0x1
JNZ 0x0014cfaa
CMP dword ptr [RAX + 0x10],0x2
JNZ 0x0014cfaa
MOV RDI,RBX
CALL 0x0011fff6
PUSH 0x1
POP RAX
JMP 0x0014cfcc
caseD_0:
CMP dword ptr [RAX + 0x10],0x0
JZ 0x0014cfca
MOV RDI,RBX
MOV RSI,R14
CALL 0x0014d33a
JMP 0x0014cf40
LAB_0014cfaa:
MOV RCX,qword ptr [R14 + 0x70]
MOV qword ptr [RCX + -0x10],RSI
MOV qword ptr [RCX + -0x8],RDX
MOV RCX,qword ptr [R14 + 0x70]
MOV EAX,dword ptr [RAX + 0x10]
MOV qword ptr [RCX],RAX
AND qword ptr [RCX + 0x8],0x0
ADD qword ptr [R14 + 0x70],0x10
LAB_0014cfca:
XOR EAX,EAX
LAB_0014cfcc:
MOV dword ptr [R14 + 0x24],EAX
MOV dword ptr [R14 + 0x8],0x3
caseD_3:
MOV RDI,RBX
MOV RSI,qword ptr [RSP + 0x28]
CALL 0x0013e977
TEST EDX,EDX
JNZ 0x0014d0fe
MOV RCX,qword ptr [R14 + 0x70]
MOV R13,qword ptr [RCX + -0x10]
MOV RBP,qword ptr [RCX + -0x8]
AND dword ptr [RCX + -0x10],0x0
MOV qword ptr [RCX + -0x8],0x3
TEST EAX,EAX
JNZ 0x0014d145
MOV qword ptr [RSP + 0x10],R13
MOV qword ptr [RSP + 0x18],RBP
MOV RSI,qword ptr [RBX + 0x88]
MOV RDX,qword ptr [RBX + 0x90]
MOV RDI,RBX
LEA R8,[RSP + 0x10]
XOR R9D,R9D
CALL 0x0014b251
MOV R12,RDX
CMP R12D,0x6
JZ 0x0014d0e3
MOV R15,RAX
MOV RSI,qword ptr [R14]
MOV RDI,RBX
LEA R14,[RSP + 0x50]
MOV RDX,R14
XOR ECX,ECX
CALL 0x0014d468
TEST EAX,EAX
JZ 0x0014d073
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R12
CALL 0x0011bbce
MOV R14,qword ptr [RSP + 0x8]
JMP 0x0014d0e3
LAB_0014d073:
AND dword ptr [RSP + 0x30],0x0
PUSH 0x3
POP RAX
MOV qword ptr [RSP + 0x38],RAX
AND dword ptr [RSP + 0x40],0x0
MOV qword ptr [RSP + 0x48],RAX
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R12
MOV RCX,R14
LEA R8,[RSP + 0x30]
CALL 0x0013f781
MOV dword ptr [RSP + 0x4],EAX
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R12
CALL 0x0011bbce
XOR R15D,R15D
MOV R14,qword ptr [RSP + 0x8]
LAB_0014d0ba:
CMP R15,0x20
JZ 0x0014d0d8
MOV RSI,qword ptr [RSP + R15*0x1 + 0x50]
MOV RDX,qword ptr [RSP + R15*0x1 + 0x58]
MOV RDI,RBX
CALL 0x0011bbce
ADD R15,0x10
JMP 0x0014d0ba
LAB_0014d0d8:
CMP dword ptr [RSP + 0x4],0x0
JZ 0x0014d1c7
LAB_0014d0e3:
MOV RDI,RBX
MOV RSI,R13
MOV RDX,RBP
CALL 0x0011bbce
MOV dword ptr [R14 + 0x24],0x1
JMP 0x0014cfd8
LAB_0014d0fe:
CMP EDX,0x6
JNZ 0x0014d17c
MOV RAX,qword ptr [RBX + 0x18]
MOV R15,qword ptr [RAX + 0xf0]
MOV R12,qword ptr [RAX + 0xf8]
AND dword ptr [RAX + 0xf0],0x0
MOV qword ptr [RAX + 0xf8],0x4
MOV RDI,RBX
MOV RSI,R14
CALL 0x0014d33a
MOV RDI,RBX
MOV RSI,R14
MOV RDX,R15
MOV RCX,R12
CALL 0x0014d3ae
JMP 0x0014d1b4
LAB_0014d145:
LEA ECX,[RAX + -0x1]
CMP ECX,0x1
JA 0x0014d335
MOV dword ptr [R14 + 0x8],EAX
MOV RDI,RBX
MOV RSI,R14
MOV RDX,R13
MOV RCX,RBP
XOR R8D,R8D
CALL 0x0014d355
MOV RDI,RBX
MOV RSI,R13
MOV RDX,RBP
CALL 0x0011bbce
JMP 0x0014cf40
LAB_0014d17c:
MOV RAX,qword ptr [R14 + 0x70]
MOV R15,qword ptr [RAX + -0x10]
MOV R12,qword ptr [RAX + -0x8]
AND dword ptr [RAX + -0x10],0x0
MOV qword ptr [RAX + -0x8],0x3
MOV RDI,RBX
MOV RSI,R14
CALL 0x0014d33a
MOV RDI,RBX
MOV RSI,R14
MOV RDX,R15
MOV RCX,R12
PUSH 0x1
POP R8
CALL 0x0014d355
LAB_0014d1b4:
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R12
CALL 0x0011bbce
JMP 0x0014cf40
LAB_0014d1c7:
MOV RDI,RBX
MOV RSI,R13
MOV RDX,RBP
LAB_0014d1d0:
CALL 0x0011bbce
caseD_4:
ADD RSP,0x78
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
caseD_5:
MOV ECX,dword ptr [RAX + 0x10]
CMP ECX,0x1
JZ 0x0014d20a
TEST ECX,ECX
JNZ 0x0014d2a7
PUSH 0x3
POP RCX
PUSH 0x1
POP R8
MOV RDI,RBX
MOV RSI,R14
XOR EDX,EDX
CALL 0x0014d355
JMP 0x0014d1d5
LAB_0014d20a:
MOV dword ptr [R14 + 0x8],0x4
MOVUPS XMM0,xmmword ptr [RAX + 0x18]
LEA R8,[RSP + 0x10]
MOVAPS xmmword ptr [R8],XMM0
MOV RSI,qword ptr [RBX + 0x88]
MOV RDX,qword ptr [RBX + 0x90]
MOV RDI,RBX
XOR R9D,R9D
CALL 0x0014b251
MOV R12,RDX
CMP R12D,0x6
JNZ 0x0014d2bf
MOV RAX,qword ptr [RBX + 0x18]
MOVUPS XMM0,xmmword ptr [RAX + 0xf0]
AND dword ptr [RAX + 0xf0],0x0
MOV qword ptr [RAX + 0xf8],0x4
LEA R13,[RSP + 0x50]
MOVAPS xmmword ptr [R13],XMM0
MOV RSI,qword ptr [RBX + 0x88]
MOV RDX,qword ptr [RBX + 0x90]
PUSH 0x1
POP R9
MOV RDI,RBX
MOV R8,R13
CALL 0x0014b251
MOV R15,RAX
MOV R12,RDX
MOV RSI,qword ptr [R13]
MOV RDX,qword ptr [R13 + 0x8]
MOV RDI,RBX
CALL 0x0011bbce
CMP R12D,0x6
JZ 0x0014d1d5
JMP 0x0014d2c2
LAB_0014d2a7:
MOV RDX,qword ptr [RAX + 0x18]
MOV RCX,qword ptr [RAX + 0x20]
MOV RDI,RBX
MOV RSI,R14
CALL 0x0014d3ae
JMP 0x0014d1d5
LAB_0014d2bf:
MOV R15,RAX
LAB_0014d2c2:
MOV RSI,qword ptr [R14]
LEA RDX,[RSP + 0x30]
PUSH 0x1
POP RCX
MOV RDI,RBX
CALL 0x0014d468
TEST EAX,EAX
JNZ 0x0014d327
LEA R8,[RSP + 0x50]
AND dword ptr [R8],0x0
PUSH 0x3
POP RAX
MOV qword ptr [R8 + 0x8],RAX
AND dword ptr [R8 + 0x10],0x0
MOV qword ptr [R8 + 0x18],RAX
LEA R14,[RSP + 0x30]
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R12
MOV RCX,R14
CALL 0x0013f781
MOV RSI,qword ptr [R14]
MOV RDX,qword ptr [R14 + 0x8]
MOV RDI,RBX
CALL 0x0011bbce
MOV RSI,qword ptr [R14 + 0x10]
MOV RDX,qword ptr [R14 + 0x18]
MOV RDI,RBX
CALL 0x0011bbce
LAB_0014d327:
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R12
JMP 0x0014d1d0
default:
CALL 0x0010e090
|
void js_async_generator_resume_next(long param_1,int8 *param_2)
{
int8 *puVar1;
int *piVar2;
ulong *puVar3;
int4 uVar4;
int iVar5;
int8 uVar6;
int extraout_EDX;
int8 uVar7;
int8 uVar8;
long lVar9;
int8 uVar10;
int1 auVar11 [16];
int1 auVar12 [16];
int8 local_98;
int8 uStack_90;
int8 *local_88;
int8 *local_80;
int4 local_78;
int4 uStack_74;
int8 local_70;
int4 local_68;
int4 uStack_64;
int8 local_60;
int8 local_58;
int8 uStack_50;
int4 local_48;
int8 local_40;
local_88 = param_2 + 0xf;
local_80 = param_2 + 2;
LAB_0014cf40:
do {
puVar1 = (int8 *)param_2[0x10];
if (puVar1 == local_88) {
switchD_0014cf6e_caseD_4:
return;
}
iVar5 = *(int *)(param_2 + 1);
switch(iVar5) {
case 0:
if (*(int *)(puVar1 + 2) != 0) {
js_async_generator_complete(param_1,param_2);
goto LAB_0014cf40;
}
LAB_0014cfca:
uVar4 = 0;
break;
case 1:
case 2:
piVar2 = (int *)puVar1[3];
uVar10 = puVar1[4];
if (0xfffffff6 < (uint)uVar10) {
*piVar2 = *piVar2 + 1;
}
if ((iVar5 != 1) || (*(int *)(puVar1 + 2) != 2)) {
lVar9 = param_2[0xe];
*(int **)(lVar9 + -0x10) = piVar2;
*(int8 *)(lVar9 + -8) = uVar10;
puVar3 = (ulong *)param_2[0xe];
*puVar3 = (ulong)*(uint *)(puVar1 + 2);
puVar3[1] = 0;
param_2[0xe] = param_2[0xe] + 0x10;
goto LAB_0014cfca;
}
JS_Throw(param_1);
uVar4 = 1;
break;
case 3:
goto switchD_0014cf6e_caseD_3;
case 4:
goto switchD_0014cf6e_caseD_4;
case 5:
if (*(int *)(puVar1 + 2) != 1) {
if (*(int *)(puVar1 + 2) == 0) {
js_async_generator_resolve(param_1,param_2,0,3,1);
return;
}
js_async_generator_reject(param_1,param_2,puVar1[3],puVar1[4]);
return;
}
*(int4 *)(param_2 + 1) = 4;
local_98 = puVar1[3];
uStack_90 = puVar1[4];
auVar12 = js_promise_resolve(param_1,*(int8 *)(param_1 + 0x88),
*(int8 *)(param_1 + 0x90),1,&local_98,0);
if (auVar12._8_4_ == 6) {
lVar9 = *(long *)(param_1 + 0x18);
local_58._0_4_ = *(int4 *)(lVar9 + 0xf0);
local_58._4_4_ = *(int4 *)(lVar9 + 0xf4);
uStack_50 = *(int8 *)(lVar9 + 0xf8);
*(int4 *)(lVar9 + 0xf0) = 0;
*(int8 *)(lVar9 + 0xf8) = 4;
auVar12 = js_promise_resolve(param_1,*(int8 *)(param_1 + 0x88),
*(int8 *)(param_1 + 0x90));
JS_FreeValue(param_1,CONCAT44(local_58._4_4_,(int4)local_58),uStack_50);
if (auVar12._8_4_ == 6) {
return;
}
}
iVar5 = js_async_generator_resolve_function_create(param_1,*param_2,&local_78,1);
if (iVar5 == 0) {
local_58._0_4_ = 0;
uStack_50 = 3;
local_48 = 0;
local_40 = 3;
perform_promise_then(param_1,auVar12._0_8_,auVar12._8_8_,&local_78);
JS_FreeValue(param_1,CONCAT44(uStack_74,local_78),local_70);
JS_FreeValue(param_1,CONCAT44(uStack_64,local_68),local_60);
}
LAB_0014d1d0:
JS_FreeValue(param_1,auVar12._0_8_,auVar12._8_8_);
return;
default:
switchD_0014cf6e_default:
/* WARNING: Subroutine does not return */
abort();
}
*(int4 *)((long)param_2 + 0x24) = uVar4;
*(int4 *)(param_2 + 1) = 3;
switchD_0014cf6e_caseD_3:
while (iVar5 = async_func_resume(param_1,local_80), extraout_EDX == 0) {
lVar9 = param_2[0xe];
uVar10 = *(int8 *)*(int1 (*) [16])(lVar9 + -0x10);
uVar8 = *(int8 *)(lVar9 + -8);
auVar12 = *(int1 (*) [16])(lVar9 + -0x10);
*(int4 *)(lVar9 + -0x10) = 0;
*(int8 *)(lVar9 + -8) = 3;
if (iVar5 != 0) {
if (1 < iVar5 - 1U) goto switchD_0014cf6e_default;
*(int *)(param_2 + 1) = iVar5;
js_async_generator_resolve(param_1,param_2,uVar10,uVar8,0);
JS_FreeValue(param_1,uVar10,uVar8);
goto LAB_0014cf40;
}
local_98 = uVar10;
uStack_90 = uVar8;
auVar11 = js_promise_resolve(param_1,*(int8 *)(param_1 + 0x88),
*(int8 *)(param_1 + 0x90),lVar9,&local_98,0);
uVar7 = auVar11._8_8_;
uVar6 = auVar11._0_8_;
if (auVar11._8_4_ != 6) {
iVar5 = js_async_generator_resolve_function_create(param_1,*param_2,&local_58,0);
if (iVar5 == 0) {
local_78 = 0;
local_70 = 3;
local_68 = 0;
local_60 = 3;
iVar5 = perform_promise_then(param_1,uVar6,uVar7,&local_58);
JS_FreeValue(param_1,uVar6,uVar7);
for (lVar9 = 0; lVar9 != 0x20; lVar9 = lVar9 + 0x10) {
JS_FreeValue(param_1,*(int8 *)((long)&local_58 + lVar9),
*(int8 *)((long)&uStack_50 + lVar9));
}
if (iVar5 == 0) goto LAB_0014d1d0;
}
else {
JS_FreeValue(param_1,uVar6,uVar7);
}
}
JS_FreeValue(param_1,uVar10,uVar8);
*(int4 *)((long)param_2 + 0x24) = 1;
}
if (extraout_EDX == 6) {
lVar9 = *(long *)(param_1 + 0x18);
uVar10 = *(int8 *)(lVar9 + 0xf0);
uVar8 = *(int8 *)(lVar9 + 0xf8);
*(int4 *)(lVar9 + 0xf0) = 0;
*(int8 *)(lVar9 + 0xf8) = 4;
js_async_generator_complete(param_1,param_2);
js_async_generator_reject(param_1,param_2,uVar10,uVar8);
}
else {
lVar9 = param_2[0xe];
uVar10 = *(int8 *)(lVar9 + -0x10);
uVar8 = *(int8 *)(lVar9 + -8);
*(int4 *)(lVar9 + -0x10) = 0;
*(int8 *)(lVar9 + -8) = 3;
js_async_generator_complete(param_1,param_2);
js_async_generator_resolve(param_1,param_2,uVar10,uVar8,1);
}
JS_FreeValue(param_1,uVar10,uVar8);
} while( true );
}
|
|
9,903 |
nlohmann::json_abi_v3_11_3::detail::lexer_base<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::token_type_name(nlohmann::json_abi_v3_11_3::detail::lexer_base<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::token_type)
|
monkey531[P]llama/common/json.hpp
|
static const char* token_type_name(const token_type t) noexcept
{
switch (t)
{
case token_type::uninitialized:
return "<uninitialized>";
case token_type::literal_true:
return "true literal";
case token_type::literal_false:
return "false literal";
case token_type::literal_null:
return "null literal";
case token_type::value_string:
return "string literal";
case token_type::value_unsigned:
case token_type::value_integer:
case token_type::value_float:
return "number literal";
case token_type::begin_array:
return "'['";
case token_type::begin_object:
return "'{'";
case token_type::end_array:
return "']'";
case token_type::end_object:
return "'}'";
case token_type::name_separator:
return "':'";
case token_type::value_separator:
return "','";
case token_type::parse_error:
return "<parse error>";
case token_type::end_of_input:
return "end of input";
case token_type::literal_or_value:
return "'[', '{', or a literal";
// LCOV_EXCL_START
default: // catch non-enum values
return "unknown token";
// LCOV_EXCL_STOP
}
}
|
O2
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::lexer_base<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::token_type_name(nlohmann::json_abi_v3_11_3::detail::lexer_base<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::token_type):
cmpl $0x10, %edi
ja 0x6c3f0
movl %edi, %eax
leaq 0x636f4(%rip), %rcx # 0xcfadc
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
retq
leaq 0x63125(%rip), %rax # 0xcf51c
retq
|
_ZN8nlohmann16json_abi_v3_11_36detail10lexer_baseINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE15token_type_nameENSG_10token_typeE:
cmp edi, 10h
ja short loc_6C3F0
mov eax, edi
lea rcx, unk_CFADC
movsxd rax, dword ptr [rcx+rax*4]
add rax, rcx
retn
loc_6C3F0:
lea rax, aUnknownToken; "unknown token"
retn
|
const char * nlohmann::json_abi_v3_11_3::detail::lexer_base<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::token_type_name(
unsigned int a1)
{
if ( a1 > 0x10 )
return "unknown token";
else
return (char *)dword_CFADC + dword_CFADC[a1];
}
|
token_type_name:
CMP EDI,0x10
JA 0x0016c3f0
MOV EAX,EDI
LEA RCX,[0x1cfadc]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
RET
LAB_0016c3f0:
LEA RAX,[0x1cf51c]
RET
|
/* nlohmann::json_abi_v3_11_3::detail::lexer_base<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>
>::token_type_name(nlohmann::json_abi_v3_11_3::detail::lexer_base<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >::token_type) */
char * nlohmann::json_abi_v3_11_3::detail::
lexer_base<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::token_type_name(uint param_1)
{
if (param_1 < 0x11) {
return &DAT_001cfadc + *(int *)(&DAT_001cfadc + (ulong)param_1 * 4);
}
return "unknown token";
}
|
|
9,904 |
evmone::instr::core::sstore(evmone::StackTop, long, evmone::ExecutionState&)
|
corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/lib/evmone/instructions_storage.cpp
|
Result sstore(StackTop stack, int64_t gas_left, ExecutionState& state) noexcept
{
if (state.in_static_mode())
return {EVMC_STATIC_MODE_VIOLATION, gas_left};
if (state.rev >= EVMC_ISTANBUL && gas_left <= 2300)
return {EVMC_OUT_OF_GAS, gas_left};
const auto key = intx::be::store<evmc::bytes32>(stack.pop());
const auto value = intx::be::store<evmc::bytes32>(stack.pop());
const auto gas_cost_cold =
(state.rev >= EVMC_BERLIN &&
state.host.access_storage(state.msg->recipient, key) == EVMC_ACCESS_COLD) ?
instr::cold_sload_cost :
0;
const auto status = state.host.set_storage(state.msg->recipient, key, value);
const auto [gas_cost_warm, gas_refund] = sstore_costs[state.rev][status];
const auto gas_cost = gas_cost_warm + gas_cost_cold;
if ((gas_left -= gas_cost) < 0)
return {EVMC_OUT_OF_GAS, gas_left};
state.gas_refund += gas_refund;
return {EVMC_SUCCESS, gas_left};
}
|
O0
|
cpp
|
evmone::instr::core::sstore(evmone::StackTop, long, evmone::ExecutionState&):
pushq %rbp
movq %rsp, %rbp
subq $0x100, %rsp # imm = 0x100
movq %rdi, -0x18(%rbp)
movq %rsi, -0x20(%rbp)
movq %rdx, -0x28(%rbp)
movq -0x28(%rbp), %rdi
callq 0x69a60
movb %al, -0xd1(%rbp)
jmp 0x890c8
movb -0xd1(%rbp), %al
testb $0x1, %al
jne 0x890d4
jmp 0x890e8
movl $0xb, -0x10(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x892e7
movq -0x28(%rbp), %rax
cmpl $0x7, 0x40(%rax)
jl 0x89110
cmpq $0x8fc, -0x20(%rbp) # imm = 0x8FC
jg 0x89110
movl $0x3, -0x10(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x892e7
leaq -0x18(%rbp), %rdi
callq 0x5fb60
movq %rax, %rsi
leaq -0x48(%rbp), %rdi
callq 0x69890
leaq -0x18(%rbp), %rdi
callq 0x5fb60
movq %rax, %rsi
leaq -0x68(%rbp), %rdi
callq 0x69890
movq -0x28(%rbp), %rcx
xorl %eax, %eax
cmpl $0x8, 0x40(%rcx)
movb %al, -0xd2(%rbp)
jl 0x891c9
movq -0x28(%rbp), %rax
addq $0x28, %rax
movq %rax, -0xe0(%rbp)
movq -0x28(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x18(%rax), %rcx
movq %rcx, -0x98(%rbp)
movq 0x20(%rax), %rcx
movq %rcx, -0x90(%rbp)
movl 0x28(%rax), %eax
movl %eax, -0x88(%rbp)
leaq -0x80(%rbp), %rdi
leaq -0x98(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movl 0x10(%rax), %eax
movl %eax, 0x10(%rsp)
callq 0x370a0
movq -0xe0(%rbp), %rdi
leaq -0x80(%rbp), %rsi
leaq -0x48(%rbp), %rdx
callq 0x3a2d0
cmpl $0x0, %eax
sete %al
movb %al, -0xd2(%rbp)
movb -0xd2(%rbp), %dl
xorl %eax, %eax
movl $0x834, %ecx # imm = 0x834
testb $0x1, %dl
cmovnel %ecx, %eax
movl %eax, -0x6c(%rbp)
movq -0x28(%rbp), %rax
addq $0x28, %rax
movq %rax, -0xe8(%rbp)
movq -0x28(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x18(%rax), %rcx
movq %rcx, -0xc8(%rbp)
movq 0x20(%rax), %rcx
movq %rcx, -0xc0(%rbp)
movl 0x28(%rax), %eax
movl %eax, -0xb8(%rbp)
leaq -0xb0(%rbp), %rdi
leaq -0xc8(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movl 0x10(%rax), %eax
movl %eax, 0x10(%rsp)
callq 0x370a0
movq -0xe8(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
leaq -0x48(%rbp), %rdx
leaq -0x68(%rbp), %rcx
callq 0x39ed0
movl %eax, -0x9c(%rbp)
movq -0x28(%rbp), %rax
movl 0x40(%rax), %eax
movl %eax, %esi
leaq 0x5aff4(%rip), %rdi # 0xe4264
callq 0x89300
movq %rax, %rdi
movl -0x9c(%rbp), %eax
movl %eax, %esi
callq 0x89330
movl (%rax), %eax
movl %eax, -0xcc(%rbp)
movswl -0xcc(%rbp), %eax
addl -0x6c(%rbp), %eax
movl %eax, -0xd0(%rbp)
movslq -0xd0(%rbp), %rcx
movq -0x20(%rbp), %rax
subq %rcx, %rax
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
jge 0x892c6
movl $0x3, -0x10(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x892e7
movswq -0xca(%rbp), %rcx
movq -0x28(%rbp), %rax
addq (%rax), %rcx
movq %rcx, (%rax)
movl $0x0, -0x10(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movl -0x10(%rbp), %eax
movq -0x8(%rbp), %rdx
addq $0x100, %rsp # imm = 0x100
popq %rbp
retq
movq %rax, %rdi
callq 0x36420
nop
|
_ZN6evmone5instr4core6sstoreENS_8StackTopElRNS_14ExecutionStateE:
push rbp
mov rbp, rsp
sub rsp, 100h
mov [rbp+var_18], rdi
mov [rbp+var_20], rsi
mov [rbp+var_28], rdx
mov rdi, [rbp+var_28]; this
call _ZNK6evmone14ExecutionState14in_static_modeEv; evmone::ExecutionState::in_static_mode(void)
mov [rbp+var_D1], al
jmp short $+2
loc_890C8:
mov al, [rbp+var_D1]
test al, 1
jnz short loc_890D4
jmp short loc_890E8
loc_890D4:
mov [rbp+var_10], 0Bh
mov rax, [rbp+var_20]
mov [rbp+var_8], rax
jmp loc_892E7
loc_890E8:
mov rax, [rbp+var_28]
cmp dword ptr [rax+40h], 7
jl short loc_89110
cmp [rbp+var_20], 8FCh
jg short loc_89110
mov [rbp+var_10], 3
mov rax, [rbp+var_20]
mov [rbp+var_8], rax
jmp loc_892E7
loc_89110:
lea rdi, [rbp+var_18]; this
call _ZN6evmone8StackTop3popEv; evmone::StackTop::pop(void)
mov rsi, rax
lea rdi, [rbp+var_48]
call _ZN4intx2be5storeIN4evmc7bytes32ENS_4uintILj256EEEEET_RKT0_; intx::be::store<evmc::bytes32,intx::uint<256u>>(intx::uint<256u> const&)
lea rdi, [rbp+var_18]; this
call _ZN6evmone8StackTop3popEv; evmone::StackTop::pop(void)
mov rsi, rax
lea rdi, [rbp+var_68]
call _ZN4intx2be5storeIN4evmc7bytes32ENS_4uintILj256EEEEET_RKT0_; intx::be::store<evmc::bytes32,intx::uint<256u>>(intx::uint<256u> const&)
mov rcx, [rbp+var_28]
xor eax, eax
cmp dword ptr [rcx+40h], 8
mov [rbp+var_D2], al
jl short loc_891C9
mov rax, [rbp+var_28]
add rax, 28h ; '('
mov [rbp+var_E0], rax
mov rax, [rbp+var_28]
mov rax, [rax+20h]
mov rcx, [rax+18h]
mov [rbp+var_98], rcx
mov rcx, [rax+20h]
mov [rbp+var_90], rcx
mov eax, [rax+28h]
mov [rbp+var_88], eax
lea rdi, [rbp+var_80]
lea rax, [rbp+var_98]
mov rcx, [rax]
mov [rsp+100h+var_100], rcx
mov rcx, [rax+8]
mov [rsp+100h+var_F8], rcx
mov eax, [rax+10h]
mov [rsp+100h+var_F0], eax
call _ZN4evmc7addressC2E12evmc_address; evmc::address::address(evmc_address)
mov rdi, [rbp+var_E0]
lea rsi, [rbp+var_80]
lea rdx, [rbp+var_48]
call _ZN4evmc11HostContext14access_storageERKNS_7addressERKNS_7bytes32E; evmc::HostContext::access_storage(evmc::address const&,evmc::bytes32 const&)
cmp eax, 0
setz al
mov [rbp+var_D2], al
loc_891C9:
mov dl, [rbp+var_D2]
xor eax, eax
mov ecx, 834h
test dl, 1
cmovnz eax, ecx
mov [rbp+var_6C], eax
mov rax, [rbp+var_28]
add rax, 28h ; '('
mov [rbp+var_E8], rax
mov rax, [rbp+var_28]
mov rax, [rax+20h]
mov rcx, [rax+18h]
mov [rbp+var_C8], rcx
mov rcx, [rax+20h]
mov [rbp+var_C0], rcx
mov eax, [rax+28h]
mov [rbp+var_B8], eax
lea rdi, [rbp+var_B0]
lea rax, [rbp+var_C8]
mov rcx, [rax]
mov [rsp+100h+var_100], rcx
mov rcx, [rax+8]
mov [rsp+100h+var_F8], rcx
mov eax, [rax+10h]
mov [rsp+100h+var_F0], eax
call _ZN4evmc7addressC2E12evmc_address; evmc::address::address(evmc_address)
mov rdi, [rbp+var_E8]
lea rsi, [rbp+var_B0]
lea rdx, [rbp+var_48]
lea rcx, [rbp+var_68]
call _ZN4evmc11HostContext11set_storageERKNS_7addressERKNS_7bytes32ES6_; evmc::HostContext::set_storage(evmc::address const&,evmc::bytes32 const&,evmc::bytes32 const&)
mov [rbp+var_9C], eax
mov rax, [rbp+var_28]
mov eax, [rax+40h]
mov esi, eax
lea rdi, _ZN6evmone5instr4core12_GLOBAL__N_112sstore_costsE; evmone::instr::core::`anonymous namespace'::sstore_costs
call _ZNKSt5arrayIS_IN6evmone5instr4core12_GLOBAL__N_116StorageStoreCostELm9EELm16EEixEm; std::array<std::array<evmone::instr::core::`anonymous namespace'::StorageStoreCost,9ul>,16ul>::operator[](ulong)
mov rdi, rax
mov eax, [rbp+var_9C]
mov esi, eax
call _ZNKSt5arrayIN6evmone5instr4core12_GLOBAL__N_116StorageStoreCostELm9EEixEm; std::array<evmone::instr::core::`anonymous namespace'::StorageStoreCost,9ul>::operator[](ulong)
mov eax, [rax]
mov [rbp+var_CC], eax
movsx eax, word ptr [rbp+var_CC]
add eax, [rbp+var_6C]
mov [rbp+var_D0], eax
movsxd rcx, [rbp+var_D0]
mov rax, [rbp+var_20]
sub rax, rcx
mov [rbp+var_20], rax
cmp rax, 0
jge short loc_892C6
mov [rbp+var_10], 3
mov rax, [rbp+var_20]
mov [rbp+var_8], rax
jmp short loc_892E7
loc_892C6:
movsx rcx, word ptr [rbp+var_CC+2]
mov rax, [rbp+var_28]
add rcx, [rax]
mov [rax], rcx
mov [rbp+var_10], 0
mov rax, [rbp+var_20]
mov [rbp+var_8], rax
loc_892E7:
mov eax, [rbp+var_10]
mov rdx, [rbp+var_8]
add rsp, 100h
pop rbp
retn
mov rdi, rax
call __clang_call_terminate
|
long long evmone::instr::core::sstore(long long a1, long long a2, evmone::ExecutionState *a3)
{
long long v3; // rax
long long v4; // rax
_BYTE *v5; // rsi
int v6; // edx
int v7; // r8d
int v8; // r9d
long long v9; // rax
int v10; // eax
long long v11; // rax
int *v12; // rax
char *v14; // [rsp+18h] [rbp-E8h]
char *v15; // [rsp+20h] [rbp-E0h]
bool v16; // [rsp+2Eh] [rbp-D2h]
int v17; // [rsp+34h] [rbp-CCh]
_BYTE v18[20]; // [rsp+50h] [rbp-B0h] BYREF
unsigned int v19; // [rsp+64h] [rbp-9Ch]
long long v20; // [rsp+68h] [rbp-98h]
long long v21; // [rsp+70h] [rbp-90h]
int v22; // [rsp+78h] [rbp-88h]
_BYTE v23[20]; // [rsp+80h] [rbp-80h] BYREF
int v24; // [rsp+94h] [rbp-6Ch]
_QWORD v25[4]; // [rsp+98h] [rbp-68h] BYREF
_QWORD v26[4]; // [rsp+B8h] [rbp-48h] BYREF
evmone::ExecutionState *v27; // [rsp+D8h] [rbp-28h]
long long v28; // [rsp+E0h] [rbp-20h]
long long v29; // [rsp+E8h] [rbp-18h] BYREF
unsigned int v30; // [rsp+F0h] [rbp-10h]
long long v31; // [rsp+F8h] [rbp-8h]
v29 = a1;
v28 = a2;
v27 = a3;
if ( evmone::ExecutionState::in_static_mode(a3) )
{
v30 = 11;
v31 = v28;
}
else if ( *((int *)v27 + 16) < 7 || v28 > 2300 )
{
v3 = evmone::StackTop::pop((evmone::StackTop *)&v29);
intx::be::store<evmc::bytes32,intx::uint<256u>>(v26, v3);
v4 = evmone::StackTop::pop((evmone::StackTop *)&v29);
LODWORD(v5) = v4;
intx::be::store<evmc::bytes32,intx::uint<256u>>(v25, v4);
v16 = 0;
if ( *((int *)v27 + 16) >= 8 )
{
v15 = (char *)v27 + 40;
v9 = *((_QWORD *)v27 + 4);
v20 = *(_QWORD *)(v9 + 24);
v21 = *(_QWORD *)(v9 + 32);
v22 = *(_DWORD *)(v9 + 40);
evmc::address::address((long long)v23, (_DWORD)v5, v6, v21, v7, v8, v20, v21, v22);
v5 = v23;
v16 = (unsigned int)evmc::HostContext::access_storage((long long)v15) == 0;
}
LOBYTE(v6) = v16;
v10 = 0;
if ( v16 )
v10 = 2100;
v24 = v10;
v14 = (char *)v27 + 40;
evmc::address::address(
(long long)v18,
(_DWORD)v5,
v6,
*(_QWORD *)(*((_QWORD *)v27 + 4) + 32LL),
v7,
v8,
*(_QWORD *)(*((_QWORD *)v27 + 4) + 24LL),
*(_QWORD *)(*((_QWORD *)v27 + 4) + 32LL),
*(_DWORD *)(*((_QWORD *)v27 + 4) + 40LL));
v19 = evmc::HostContext::set_storage((long long)v14);
v11 = std::array<std::array<evmone::instr::core::`anonymous namespace'::StorageStoreCost,9ul>,16ul>::operator[](
&evmone::instr::core::`anonymous namespace'::sstore_costs,
*((unsigned int *)v27 + 16));
v12 = (int *)std::array<evmone::instr::core::`anonymous namespace'::StorageStoreCost,9ul>::operator[](v11, v19);
v17 = *v12;
v28 -= v24 + (__int16)*v12;
if ( v28 >= 0 )
{
*(_QWORD *)v27 += SHIWORD(v17);
v30 = 0;
}
else
{
v30 = 3;
}
v31 = v28;
}
else
{
v30 = 3;
v31 = v28;
}
return v30;
}
|
sstore:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x100
MOV qword ptr [RBP + -0x18],RDI
MOV qword ptr [RBP + -0x20],RSI
MOV qword ptr [RBP + -0x28],RDX
MOV RDI,qword ptr [RBP + -0x28]
LAB_001890bb:
CALL 0x00169a60
MOV byte ptr [RBP + -0xd1],AL
JMP 0x001890c8
LAB_001890c8:
MOV AL,byte ptr [RBP + -0xd1]
TEST AL,0x1
JNZ 0x001890d4
JMP 0x001890e8
LAB_001890d4:
MOV dword ptr [RBP + -0x10],0xb
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001892e7
LAB_001890e8:
MOV RAX,qword ptr [RBP + -0x28]
CMP dword ptr [RAX + 0x40],0x7
JL 0x00189110
CMP qword ptr [RBP + -0x20],0x8fc
JG 0x00189110
MOV dword ptr [RBP + -0x10],0x3
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001892e7
LAB_00189110:
LEA RDI,[RBP + -0x18]
CALL 0x0015fb60
MOV RSI,RAX
LEA RDI,[RBP + -0x48]
CALL 0x00169890
LEA RDI,[RBP + -0x18]
CALL 0x0015fb60
MOV RSI,RAX
LEA RDI,[RBP + -0x68]
CALL 0x00169890
MOV RCX,qword ptr [RBP + -0x28]
XOR EAX,EAX
CMP dword ptr [RCX + 0x40],0x8
MOV byte ptr [RBP + -0xd2],AL
JL 0x001891c9
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x28
MOV qword ptr [RBP + -0xe0],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x20]
MOV RCX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0x98],RCX
MOV RCX,qword ptr [RAX + 0x20]
MOV qword ptr [RBP + -0x90],RCX
MOV EAX,dword ptr [RAX + 0x28]
MOV dword ptr [RBP + -0x88],EAX
LEA RDI,[RBP + -0x80]
LEA RAX,[RBP + -0x98]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV EAX,dword ptr [RAX + 0x10]
MOV dword ptr [RSP + 0x10],EAX
CALL 0x001370a0
MOV RDI,qword ptr [RBP + -0xe0]
LEA RSI,[RBP + -0x80]
LEA RDX,[RBP + -0x48]
CALL 0x0013a2d0
CMP EAX,0x0
SETZ AL
MOV byte ptr [RBP + -0xd2],AL
LAB_001891c9:
MOV DL,byte ptr [RBP + -0xd2]
XOR EAX,EAX
MOV ECX,0x834
TEST DL,0x1
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x6c],EAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x28
MOV qword ptr [RBP + -0xe8],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x20]
MOV RCX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0xc8],RCX
MOV RCX,qword ptr [RAX + 0x20]
MOV qword ptr [RBP + -0xc0],RCX
MOV EAX,dword ptr [RAX + 0x28]
MOV dword ptr [RBP + -0xb8],EAX
LEA RDI,[RBP + -0xb0]
LEA RAX,[RBP + -0xc8]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV EAX,dword ptr [RAX + 0x10]
MOV dword ptr [RSP + 0x10],EAX
CALL 0x001370a0
MOV RDI,qword ptr [RBP + -0xe8]
LEA RSI,[RBP + -0xb0]
LEA RDX,[RBP + -0x48]
LEA RCX,[RBP + -0x68]
CALL 0x00139ed0
MOV dword ptr [RBP + -0x9c],EAX
MOV RAX,qword ptr [RBP + -0x28]
MOV EAX,dword ptr [RAX + 0x40]
MOV ESI,EAX
LEA RDI,[0x1e4264]
CALL 0x00189300
MOV RDI,RAX
MOV EAX,dword ptr [RBP + -0x9c]
MOV ESI,EAX
CALL 0x00189330
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0xcc],EAX
MOVSX EAX,word ptr [RBP + -0xcc]
ADD EAX,dword ptr [RBP + -0x6c]
MOV dword ptr [RBP + -0xd0],EAX
MOVSXD RCX,dword ptr [RBP + -0xd0]
MOV RAX,qword ptr [RBP + -0x20]
SUB RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
CMP RAX,0x0
JGE 0x001892c6
MOV dword ptr [RBP + -0x10],0x3
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001892e7
LAB_001892c6:
MOVSX RCX,word ptr [RBP + -0xca]
MOV RAX,qword ptr [RBP + -0x28]
ADD RCX,qword ptr [RAX]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x10],0x0
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x8],RAX
LAB_001892e7:
MOV EAX,dword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x8]
ADD RSP,0x100
POP RBP
RET
|
/* evmone::instr::core::sstore(evmone::StackTop, long, evmone::ExecutionState&) */
int1 [16]
evmone::instr::core::sstore(int8 param_1,long param_2,ExecutionState *param_3)
{
long lVar1;
byte bVar2;
int iVar3;
uint *puVar4;
HostContext *pHVar5;
array<evmone::instr::core::(anonymous_namespace)::StorageStoreCost,9ul> *this;
int4 *puVar6;
bool bVar7;
int1 auVar8 [16];
short local_d4;
short sStack_d2;
address local_b8 [20];
uint local_a4;
int8 local_a0;
int8 local_98;
int4 local_90;
address local_88 [20];
int local_74;
be local_70 [32];
be local_50 [32];
ExecutionState *local_30;
long local_28;
int8 local_20;
uint local_18;
long local_10;
local_30 = param_3;
local_28 = param_2;
local_20 = param_1;
/* try { // try from 001890bb to 001890bf has its CatchHandler @ 001892f7 */
bVar2 = ExecutionState::in_static_mode(param_3);
if ((bVar2 & 1) == 0) {
if ((*(int *)(local_30 + 0x40) < 7) || (0x8fc < local_28)) {
puVar4 = (uint *)StackTop::pop((StackTop *)&local_20);
intx::be::store<evmc::bytes32,intx::uint<256u>>(local_50,puVar4);
puVar4 = (uint *)StackTop::pop((StackTop *)&local_20);
intx::be::store<evmc::bytes32,intx::uint<256u>>(local_70,puVar4);
bVar7 = false;
if (7 < *(int *)(local_30 + 0x40)) {
pHVar5 = (HostContext *)(local_30 + 0x28);
lVar1 = *(long *)(local_30 + 0x20);
local_a0 = *(int8 *)(lVar1 + 0x18);
local_98 = *(int8 *)(lVar1 + 0x20);
local_90 = *(int4 *)(lVar1 + 0x28);
evmc::address::address(local_88);
iVar3 = evmc::HostContext::access_storage(pHVar5,local_88,(bytes32 *)local_50);
bVar7 = iVar3 == 0;
}
local_74 = 0;
if (bVar7) {
local_74 = 0x834;
}
pHVar5 = (HostContext *)(local_30 + 0x28);
evmc::address::address(local_b8);
local_a4 = evmc::HostContext::set_storage
(pHVar5,local_b8,(bytes32 *)local_50,(bytes32 *)local_70);
this = (array<evmone::instr::core::(anonymous_namespace)::StorageStoreCost,9ul> *)
std::
array<std::array<evmone::instr::core::(anonymous_namespace)::StorageStoreCost,9ul>,16ul>
::operator[]((array<std::array<evmone::instr::core::(anonymous_namespace)::StorageStoreCost,9ul>,16ul>
*)(anonymous_namespace)::sstore_costs,(ulong)*(uint *)(local_30 + 0x40));
puVar6 = (int4 *)
std::array<evmone::instr::core::(anonymous_namespace)::StorageStoreCost,9ul>::
operator[](this,(ulong)local_a4);
local_d4 = (short)*puVar6;
local_10 = local_28 - (local_d4 + local_74);
if (local_10 < 0) {
local_18 = 3;
}
else {
sStack_d2 = (short)((uint)*puVar6 >> 0x10);
*(long *)local_30 = (long)sStack_d2 + *(long *)local_30;
local_18 = 0;
}
}
else {
local_18 = 3;
local_10 = local_28;
}
}
else {
local_18 = 0xb;
local_10 = local_28;
}
auVar8._4_4_ = 0;
auVar8._0_4_ = local_18;
auVar8._8_8_ = local_10;
return auVar8;
}
|
|
9,905 |
_gnu_cxx::__normal_iterator<std::pair<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>>*, std::vector<std::pair<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>>, std::allocator<std::pair<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>>>>> nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, 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::less<void>, std::allocator<std::pair<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>>>>::find<char const (&) [3], 0>(char const (&) [3])
|
monkey531[P]llama/common/json.hpp
|
iterator find(KeyType && key) // NOLINT(cppcoreguidelines-missing-std-forward)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return it;
}
}
return Container::end();
}
|
O0
|
cpp
|
_gnu_cxx::__normal_iterator<std::pair<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>>*, std::vector<std::pair<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>>, std::allocator<std::pair<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>>>>> nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, 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::less<void>, std::allocator<std::pair<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>>>>::find<char const (&) [3], 0>(char const (&) [3]):
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq 0x28(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0xb3e60
movq %rax, 0x30(%rsp)
movq 0x10(%rsp), %rdi
callq 0xb3e90
movq %rax, 0x18(%rsp)
leaq 0x30(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0xb3ec0
testb $0x1, %al
jne 0x16dac6
jmp 0x16db06
movq 0x10(%rsp), %rax
addq $0x18, %rax
movq %rax, 0x8(%rsp)
leaq 0x30(%rsp), %rdi
callq 0xb5030
movq 0x8(%rsp), %rdi
movq %rax, %rsi
movq 0x20(%rsp), %rdx
callq 0x16db20
testb $0x1, %al
jne 0x16daf6
jmp 0x16daf8
jmp 0x16db15
jmp 0x16dafa
leaq 0x30(%rsp), %rdi
callq 0xb3f40
jmp 0x16daa2
movq 0x10(%rsp), %rdi
callq 0xb3e90
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
addq $0x38, %rsp
retq
nop
|
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA13_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_:
sub rsp, 38h
mov [rsp+38h+var_10], rdi
mov [rsp+38h+var_18], rsi
mov rdi, [rsp+38h+var_10]
mov [rsp+38h+var_28], rdi
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE5beginEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::begin(void)
mov [rsp+38h+var_8], rax
loc_16DAA2:
mov rdi, [rsp+38h+var_28]
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::end(void)
mov [rsp+38h+var_20], rax
lea rdi, [rsp+38h+var_8]
lea rsi, [rsp+38h+var_20]
call _ZN9__gnu_cxxneIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbRKNS_17__normal_iteratorIT_T0_EESR_; __gnu_cxx::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::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>(__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>> const&,__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>> const&)
test al, 1
jnz short loc_16DAC6
jmp short loc_16DB06
loc_16DAC6:
mov rax, [rsp+38h+var_28]
add rax, 18h
mov [rsp+38h+var_30], rax
lea rdi, [rsp+38h+var_8]
call _ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEptEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator->(void)
mov rdi, [rsp+38h+var_30]
mov rsi, rax
mov rdx, [rsp+38h+var_18]
call _ZNKSt8equal_toIvEclIRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERA13_KcEEDTeqclsr3stdE7forwardIT_Efp_Eclsr3stdE7forwardIT0_Efp0_EEOSD_OSE_
test al, 1
jnz short loc_16DAF6
jmp short loc_16DAF8
loc_16DAF6:
jmp short loc_16DB15
loc_16DAF8:
jmp short $+2
loc_16DAFA:
lea rdi, [rsp+38h+var_8]
call _ZN9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEppEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator++(void)
jmp short loc_16DAA2
loc_16DB06:
mov rdi, [rsp+38h+var_28]
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::end(void)
mov [rsp+38h+var_8], rax
loc_16DB15:
mov rax, [rsp+38h+var_8]
add rsp, 38h
retn
|
long long ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA13_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_(
long long a1,
long long a2)
{
long long v2; // rax
long long v4; // [rsp+18h] [rbp-20h] BYREF
long long v5; // [rsp+20h] [rbp-18h]
long long v6; // [rsp+28h] [rbp-10h]
long long i; // [rsp+30h] [rbp-8h] BYREF
v6 = a1;
v5 = a2;
for ( i = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::begin(a1);
;
__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator++(&i) )
{
v4 = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::end(a1);
if ( !__gnu_cxx::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::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>(
(long long)&i,
(long long)&v4) )
break;
v2 = __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator->((long long)&i);
if ( (std::equal_to<void>::operator()<std::string const&,char const(&)[13]>(a1 + 24, v2, v5) & 1) != 0 )
return i;
}
return std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::end(a1);
}
| |||
9,906 |
_gnu_cxx::__normal_iterator<std::pair<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>>*, std::vector<std::pair<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>>, std::allocator<std::pair<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>>>>> nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, 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::less<void>, std::allocator<std::pair<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>>>>::find<char const (&) [3], 0>(char const (&) [3])
|
monkey531[P]llama/common/json.hpp
|
iterator find(KeyType && key) // NOLINT(cppcoreguidelines-missing-std-forward)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return it;
}
}
return Container::end();
}
|
O2
|
cpp
|
_gnu_cxx::__normal_iterator<std::pair<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>>*, std::vector<std::pair<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>>, std::allocator<std::pair<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>>>>> nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, 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::less<void>, std::allocator<std::pair<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>>>>::find<char const (&) [3], 0>(char const (&) [3]):
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r15
movq (%rdi), %r14
movq 0x8(%r15), %rax
cmpq %rax, %r14
je 0x92587
movq %r14, %rdi
movq %rbx, %rsi
callq 0x3963b
testb %al, %al
jne 0x92584
addq $0x30, %r14
jmp 0x92566
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
nop
|
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA21_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_:
push r15
push r14
push rbx
mov rbx, rsi
mov r15, rdi
mov r14, [rdi]
loc_92566:
mov rax, [r15+8]
cmp r14, rax
jz short loc_92587
mov rdi, r14
mov rsi, rbx
call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*)
test al, al
jnz short loc_92584
add r14, 30h ; '0'
jmp short loc_92566
loc_92584:
mov rax, r14
loc_92587:
pop rbx
pop r14
pop r15
retn
|
long long ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA21_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_(
long long *a1)
{
long long i; // r14
long long result; // rax
for ( i = *a1; ; i += 48LL )
{
result = a1[1];
if ( i == result )
break;
if ( std::operator==<char>(i) )
return i;
}
return result;
}
|
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA21_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_:
PUSH R15
PUSH R14
PUSH RBX
MOV RBX,RSI
MOV R15,RDI
MOV R14,qword ptr [RDI]
LAB_00192566:
MOV RAX,qword ptr [R15 + 0x8]
CMP R14,RAX
JZ 0x00192587
MOV RDI,R14
MOV RSI,RBX
CALL 0x0013963b
TEST AL,AL
JNZ 0x00192584
ADD R14,0x30
JMP 0x00192566
LAB_00192584:
MOV RAX,R14
LAB_00192587:
POP RBX
POP R14
POP R15
RET
|
string * _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA21_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_
(int8 *param_1,char *param_2)
{
bool bVar1;
string *psVar2;
string *psVar3;
psVar3 = (string *)*param_1;
while ((psVar2 = (string *)param_1[1], psVar3 != (string *)param_1[1] &&
(bVar1 = std::operator==(psVar3,param_2), psVar2 = psVar3, !bVar1))) {
psVar3 = psVar3 + 0x30;
}
return psVar2;
}
|
|
9,907 |
Catch::Clara::Opt::getHelpColumns() const
|
AlayaLite/build_O3/_deps/libcoro-src/test/catch_amalgamated.cpp
|
std::vector<Detail::HelpColumns> Opt::getHelpColumns() const {
std::ostringstream oss;
bool first = true;
for (auto const& opt : m_optNames) {
if (first)
first = false;
else
oss << ", ";
oss << opt;
}
if (!m_hint.empty())
oss << " <" << m_hint << '>';
return { { oss.str(), m_description } };
}
|
O3
|
cpp
|
Catch::Clara::Opt::getHelpColumns() const:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1c8, %rsp # imm = 0x1C8
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x50(%rsp), %rdi
callq 0x17b80
movq 0x60(%r14), %r13
movq 0x68(%r14), %rbp
cmpq %rbp, %r13
je 0x59d9f
movb $0x1, %al
leaq 0x50(%rsp), %r15
leaq 0x7f046(%rip), %r12 # 0xd8db6
testb $0x1, %al
jne 0x59d84
movl $0x2, %edx
movq %r15, %rdi
movq %r12, %rsi
callq 0x17be0
movq (%r13), %rsi
movq 0x8(%r13), %rdx
movq %r15, %rdi
callq 0x17be0
addq $0x20, %r13
xorl %eax, %eax
cmpq %rbp, %r13
jne 0x59d70
cmpq $0x0, 0x28(%r14)
je 0x59de3
leaq 0x834e3(%rip), %rsi # 0xdd290
leaq 0x50(%rsp), %rdi
movl $0x2, %edx
callq 0x17be0
movq 0x20(%r14), %rsi
movq 0x28(%r14), %rdx
leaq 0x50(%rsp), %rdi
callq 0x17be0
leaq 0x10(%rsp), %rsi
movb $0x3e, (%rsi)
movl $0x1, %edx
movq %rax, %rdi
callq 0x17be0
leaq 0x58(%rsp), %rsi
leaq 0x10(%rsp), %rdi
callq 0x17c70
leaq 0x30(%rsp), %rdi
leaq 0x40(%rsp), %r15
movq %r15, -0x10(%r15)
movq 0x40(%r14), %rsi
movq 0x48(%r14), %rdx
addq %rsi, %rdx
callq 0x251d8
leaq 0x10(%rsp), %rsi
leaq 0xf(%rsp), %rcx
movl $0x1, %edx
movq %rbx, %rdi
callq 0x77868
movq 0x30(%rsp), %rdi
cmpq %r15, %rdi
je 0x59e3e
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x17150
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x59e59
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x17150
movq 0xd80f0(%rip), %rsi # 0x131f50
leaq 0x50(%rsp), %rdi
callq 0x17810
leaq 0xc0(%rsp), %rdi
callq 0x177e0
movq %rbx, %rax
addq $0x1c8, %rsp # imm = 0x1C8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x77832
jmp 0x59ec2
movq %rax, %rbx
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x59ec2
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x17150
jmp 0x59ec2
jmp 0x59ebf
jmp 0x59ebf
movq %rax, %rbx
movq 0xd8087(%rip), %rsi # 0x131f50
leaq 0x50(%rsp), %rdi
callq 0x17810
leaq 0xc0(%rsp), %rdi
callq 0x177e0
movq %rbx, %rdi
callq 0x17740
|
_ZNK5Catch5Clara3Opt14getHelpColumnsEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 1C8h
mov r14, rsi
mov rbx, rdi
lea rdi, [rsp+1F8h+var_1A8]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::ostringstream::basic_ostringstream(void)
mov r13, [r14+60h]
mov rbp, [r14+68h]
cmp r13, rbp
jz short loc_59D9F
mov al, 1
lea r15, [rsp+1F8h+var_1A8]
lea r12, asc_D8DB6; ", "
loc_59D70:
test al, 1
jnz short loc_59D84
mov edx, 2
mov rdi, r15
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)
loc_59D84:
mov rsi, [r13+0]
mov rdx, [r13+8]
mov rdi, r15
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
add r13, 20h ; ' '
xor eax, eax
cmp r13, rbp
jnz short loc_59D70
loc_59D9F:
cmp qword ptr [r14+28h], 0
jz short loc_59DE3
lea rsi, asc_DD290; " <"
lea rdi, [rsp+1F8h+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)
mov rsi, [r14+20h]
mov rdx, [r14+28h]
lea rdi, [rsp+1F8h+var_1A8]
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
lea rsi, [rsp+1F8h+var_1E8]
mov byte ptr [rsi], 3Eh ; '>'
mov edx, 1
mov rdi, rax
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
loc_59DE3:
lea rsi, [rsp+1F8h+var_1A0]
lea rdi, [rsp+1F8h+var_1E8]
call __ZNKRSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void)
lea rdi, [rsp+1F8h+var_1C8]
lea r15, [rsp+1F8h+var_1B8]
mov [r15-10h], r15
mov rsi, [r14+40h]
mov rdx, [r14+48h]
add rdx, rsi
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
lea rsi, [rsp+1F8h+var_1E8]
lea rcx, [rsp+1F8h+var_1E9]
mov edx, 1
mov rdi, rbx
call _ZNSt6vectorIN5Catch5Clara6Detail11HelpColumnsESaIS3_EEC2ESt16initializer_listIS3_ERKS4_; std::vector<Catch::Clara::Detail::HelpColumns>::vector(std::initializer_list<Catch::Clara::Detail::HelpColumns>,std::allocator<Catch::Clara::Detail::HelpColumns> const&)
mov rdi, [rsp+1F8h+var_1C8]; void *
cmp rdi, r15
jz short loc_59E3E
mov rsi, [rsp+1F8h+var_1B8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_59E3E:
lea rax, [rsp+1F8h+var_1D8]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_59E59
mov rsi, [rsp+1F8h+var_1D8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_59E59:
mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+1F8h+var_1A8]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream()
lea rdi, [rsp+1F8h+var_138]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
mov rax, rbx
add rsp, 1C8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
lea rdi, [rsp+arg_8]; this
call _ZN5Catch5Clara6Detail11HelpColumnsD2Ev; Catch::Clara::Detail::HelpColumns::~HelpColumns()
jmp short loc_59EC2
mov rbx, rax
lea rax, [rsp+arg_18]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_59EC2
mov rsi, [rsp+arg_18]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_59EC2
jmp short loc_59EBF
jmp short $+2
loc_59EBF:
mov rbx, rax
loc_59EC2:
mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+arg_48]
call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream()
lea rdi, [rsp+arg_B8]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
mov rdi, rbx
call __Unwind_Resume
|
Catch::Clara::Opt * Catch::Clara::Opt::getHelpColumns(Catch::Clara::Opt *this, long long a2, double a3)
{
_QWORD *v3; // r13
_QWORD *v4; // rbp
char v5; // al
long long v6; // rax
char v8; // [rsp+Fh] [rbp-1E9h] BYREF
void *v9[2]; // [rsp+10h] [rbp-1E8h] BYREF
long long v10; // [rsp+20h] [rbp-1D8h] BYREF
void *v11; // [rsp+30h] [rbp-1C8h] BYREF
_QWORD v12[2]; // [rsp+40h] [rbp-1B8h] BYREF
_BYTE v13[8]; // [rsp+50h] [rbp-1A8h] BYREF
_BYTE v14[104]; // [rsp+58h] [rbp-1A0h] BYREF
_BYTE v15[312]; // [rsp+C0h] [rbp-138h] BYREF
std::ostringstream::basic_ostringstream(v13);
v3 = *(_QWORD **)(a2 + 96);
v4 = *(_QWORD **)(a2 + 104);
if ( v3 != v4 )
{
v5 = 1;
do
{
if ( (v5 & 1) == 0 )
std::__ostream_insert<char,std::char_traits<char>>(v13, ", ", 2LL);
std::__ostream_insert<char,std::char_traits<char>>(v13, *v3, v3[1]);
v3 += 4;
v5 = 0;
}
while ( v3 != v4 );
}
if ( *(_QWORD *)(a2 + 40) )
{
std::__ostream_insert<char,std::char_traits<char>>(v13, " <", 2LL);
v6 = std::__ostream_insert<char,std::char_traits<char>>(v13, *(_QWORD *)(a2 + 32), *(_QWORD *)(a2 + 40));
LOBYTE(v9[0]) = 62;
std::__ostream_insert<char,std::char_traits<char>>(v6, v9, 1LL);
}
std::stringbuf::str(v9, v14, a3);
v11 = v12;
std::string::_M_construct<char *>(&v11, *(_BYTE **)(a2 + 64), *(_QWORD *)(a2 + 64) + *(_QWORD *)(a2 + 72));
std::vector<Catch::Clara::Detail::HelpColumns>::vector(this, v9, 1LL, &v8);
if ( v11 != v12 )
operator delete(v11, v12[0] + 1LL);
if ( v9[0] != &v10 )
operator delete(v9[0], v10 + 1);
std::ostringstream::~ostringstream(v13, &`VTT for'std::ostringstream);
std::ios_base::~ios_base((std::ios_base *)v15);
return this;
}
|
getHelpColumns:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x1c8
MOV R14,RSI
MOV RBX,RDI
LEA RDI,[RSP + 0x50]
CALL 0x00117b80
MOV R13,qword ptr [R14 + 0x60]
MOV RBP,qword ptr [R14 + 0x68]
CMP R13,RBP
JZ 0x00159d9f
MOV AL,0x1
LEA R15,[RSP + 0x50]
LEA R12,[0x1d8db6]
LAB_00159d70:
TEST AL,0x1
JNZ 0x00159d84
LAB_00159d74:
MOV EDX,0x2
MOV RDI,R15
MOV RSI,R12
CALL 0x00117be0
LAB_00159d84:
MOV RSI,qword ptr [R13]
MOV RDX,qword ptr [R13 + 0x8]
MOV RDI,R15
CALL 0x00117be0
ADD R13,0x20
XOR EAX,EAX
CMP R13,RBP
JNZ 0x00159d70
LAB_00159d9f:
CMP qword ptr [R14 + 0x28],0x0
JZ 0x00159de3
LAB_00159da6:
LEA RSI,[0x1dd290]
LEA RDI,[RSP + 0x50]
MOV EDX,0x2
CALL 0x00117be0
MOV RSI,qword ptr [R14 + 0x20]
MOV RDX,qword ptr [R14 + 0x28]
LEA RDI,[RSP + 0x50]
CALL 0x00117be0
LEA RSI,[RSP + 0x10]
MOV byte ptr [RSI],0x3e
MOV EDX,0x1
MOV RDI,RAX
CALL 0x00117be0
LAB_00159de3:
LEA RSI,[RSP + 0x58]
LAB_00159de8:
LEA RDI,[RSP + 0x10]
CALL 0x00117c70
LEA RDI,[RSP + 0x30]
LEA R15,[RSP + 0x40]
MOV qword ptr [R15 + -0x10],R15
MOV RSI,qword ptr [R14 + 0x40]
MOV RDX,qword ptr [R14 + 0x48]
ADD RDX,RSI
LAB_00159e0b:
CALL 0x001251d8
LAB_00159e10:
LEA RSI,[RSP + 0x10]
LEA RCX,[RSP + 0xf]
MOV EDX,0x1
MOV RDI,RBX
CALL 0x00177868
LAB_00159e27:
MOV RDI,qword ptr [RSP + 0x30]
CMP RDI,R15
JZ 0x00159e3e
MOV RSI,qword ptr [RSP + 0x40]
INC RSI
CALL 0x00117150
LAB_00159e3e:
LEA RAX,[RSP + 0x20]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x00159e59
MOV RSI,qword ptr [RSP + 0x20]
INC RSI
CALL 0x00117150
LAB_00159e59:
MOV RSI,qword ptr [0x00231f50]
LEA RDI,[RSP + 0x50]
CALL 0x00117810
LEA RDI,[RSP + 0xc0]
CALL 0x001177e0
MOV RAX,RBX
ADD RSP,0x1c8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* Catch::Clara::Opt::getHelpColumns() const */
void Catch::Clara::Opt::getHelpColumns(void)
{
int8 *puVar1;
bool bVar2;
ostream *poVar3;
long in_RSI;
int8 *puVar4;
char local_1e8;
int7 uStack_1e7;
long local_1d8 [2];
long *local_1c8 [2];
long local_1b8 [2];
ostringstream local_1a8 [112];
ios_base local_138 [264];
std::__cxx11::ostringstream::ostringstream(local_1a8);
puVar4 = *(int8 **)(in_RSI + 0x60);
puVar1 = *(int8 **)(in_RSI + 0x68);
if (puVar4 != puVar1) {
bVar2 = true;
do {
if (!bVar2) {
/* try { // try from 00159d74 to 00159d93 has its CatchHandler @ 00159ebf */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)local_1a8,", ",2);
}
std::__ostream_insert<char,std::char_traits<char>>
((ostream *)local_1a8,(char *)*puVar4,puVar4[1]);
puVar4 = puVar4 + 4;
bVar2 = false;
} while (puVar4 != puVar1);
}
if (*(long *)(in_RSI + 0x28) != 0) {
/* try { // try from 00159da6 to 00159de2 has its CatchHandler @ 00159ebd */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)local_1a8," <",2);
poVar3 = std::__ostream_insert<char,std::char_traits<char>>
((ostream *)local_1a8,*(char **)(in_RSI + 0x20),*(long *)(in_RSI + 0x28));
local_1e8 = '>';
std::__ostream_insert<char,std::char_traits<char>>(poVar3,&local_1e8,1);
}
/* try { // try from 00159de8 to 00159df1 has its CatchHandler @ 00159ebb */
std::__cxx11::stringbuf::str();
local_1c8[0] = local_1b8;
/* try { // try from 00159e0b to 00159e0f has its CatchHandler @ 00159e9b */
std::__cxx11::string::_M_construct<char*>
(local_1c8,*(long *)(in_RSI + 0x40),*(long *)(in_RSI + 0x48) + *(long *)(in_RSI + 0x40))
;
/* try { // try from 00159e10 to 00159e26 has its CatchHandler @ 00159e8c */
std::vector<Catch::Clara::Detail::HelpColumns,std::allocator<Catch::Clara::Detail::HelpColumns>>::
vector();
if (local_1c8[0] != local_1b8) {
operator_delete(local_1c8[0],local_1b8[0] + 1);
}
if ((long *)CONCAT71(uStack_1e7,local_1e8) != local_1d8) {
operator_delete((long *)CONCAT71(uStack_1e7,local_1e8),local_1d8[0] + 1);
}
std::__cxx11::ostringstream::~ostringstream(local_1a8);
std::ios_base::~ios_base(local_138);
return;
}
|
|
9,908 |
loadElfToMemory(ELFIO::elfio*, MemoryManager*)
|
EnderturtleOrz[P]CSC3050-2025-Spring-Project-3/src/MainCPU.cpp
|
void loadElfToMemory(ELFIO::elfio *reader, MemoryManager *memory) {
ELFIO::Elf_Half seg_num = reader->segments.size();
for (int i = 0; i < seg_num; ++i) {
const ELFIO::segment *pseg = reader->segments[i];
uint64_t fullmemsz = pseg->get_memory_size();
uint64_t fulladdr = pseg->get_virtual_address();
// Our 32bit simulator cannot handle this
if (fulladdr + fullmemsz > 0xFFFFFFFF) {
dbgprintf(
"ELF address space larger than 32bit! Seg %d has max addr of 0x%lx\n",
i, fulladdr + fullmemsz);
exit(-1);
}
uint32_t filesz = pseg->get_file_size();
uint32_t memsz = pseg->get_memory_size();
uint32_t addr = (uint32_t)pseg->get_virtual_address();
for (uint32_t p = addr; p < addr + memsz; ++p) {
if (p < addr + filesz) {
memory->setByteNoCache(p, pseg->get_data()[p - addr]);
} else {
memory->setByteNoCache(p, 0);
}
}
}
}
|
O0
|
cpp
|
loadElfToMemory(ELFIO::elfio*, MemoryManager*):
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq %rsi, 0x48(%rsp)
movq 0x50(%rsp), %rdi
addq $0x8, %rdi
callq 0x16940
movw %ax, 0x46(%rsp)
movl $0x0, 0x40(%rsp)
movl 0x40(%rsp), %eax
movzwl 0x46(%rsp), %ecx
cmpl %ecx, %eax
jge 0x1641f
movq 0x50(%rsp), %rdi
addq $0x8, %rdi
movl 0x40(%rsp), %esi
callq 0x16960
movq %rax, 0x38(%rsp)
movq 0x38(%rsp), %rdi
movq (%rdi), %rax
callq *0x78(%rax)
movq %rax, 0x30(%rsp)
movq 0x38(%rsp), %rdi
movq (%rdi), %rax
callq *0x48(%rax)
movq %rax, 0x28(%rsp)
movq 0x28(%rsp), %rax
addq 0x30(%rsp), %rax
movl $0xffffffff, %ecx # imm = 0xFFFFFFFF
cmpq %rcx, %rax
jbe 0x1635b
movl 0x40(%rsp), %esi
movq 0x28(%rsp), %rdx
addq 0x30(%rsp), %rdx
leaq 0x12f9d(%rip), %rdi # 0x292e7
movb $0x0, %al
callq 0x167d0
movl $0xffffffff, %edi # imm = 0xFFFFFFFF
callq 0x15260
movq 0x38(%rsp), %rdi
movq (%rdi), %rax
callq *0x68(%rax)
movl %eax, 0x24(%rsp)
movq 0x38(%rsp), %rdi
movq (%rdi), %rax
callq *0x78(%rax)
movl %eax, 0x20(%rsp)
movq 0x38(%rsp), %rdi
movq (%rdi), %rax
callq *0x48(%rax)
movl %eax, 0x1c(%rsp)
movl 0x1c(%rsp), %eax
movl %eax, 0x18(%rsp)
movl 0x18(%rsp), %eax
movl 0x1c(%rsp), %ecx
addl 0x20(%rsp), %ecx
cmpl %ecx, %eax
jae 0x1640d
movl 0x18(%rsp), %eax
movl 0x1c(%rsp), %ecx
addl 0x24(%rsp), %ecx
cmpl %ecx, %eax
jae 0x163ee
movq 0x48(%rsp), %rax
movq %rax, 0x8(%rsp)
movl 0x18(%rsp), %eax
movl %eax, 0x14(%rsp)
movq 0x38(%rsp), %rdi
movq (%rdi), %rax
callq *0x90(%rax)
movq 0x8(%rsp), %rdi
movl 0x14(%rsp), %esi
movl 0x18(%rsp), %ecx
subl 0x1c(%rsp), %ecx
movl %ecx, %ecx
movzbl (%rax,%rcx), %edx
callq 0x1e8f0
jmp 0x163fe
movq 0x48(%rsp), %rdi
movl 0x18(%rsp), %esi
xorl %edx, %edx
callq 0x1e8f0
jmp 0x16400
movl 0x18(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x18(%rsp)
jmp 0x16390
jmp 0x1640f
movl 0x40(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x40(%rsp)
jmp 0x162d9
addq $0x58, %rsp
retq
nopw %cs:(%rax,%rax)
nop
|
_Z15loadElfToMemoryPN5ELFIO5elfioEP13MemoryManager:
sub rsp, 58h
mov [rsp+58h+var_8], rdi
mov [rsp+58h+var_10], rsi
mov rdi, [rsp+58h+var_8]
add rdi, 8; this
call _ZNK5ELFIO5elfio8Segments4sizeEv; ELFIO::elfio::Segments::size(void)
mov [rsp+58h+var_12], ax
mov [rsp+58h+var_18], 0
loc_162D9:
mov eax, [rsp+58h+var_18]
movzx ecx, [rsp+58h+var_12]
cmp eax, ecx
jge loc_1641F
mov rdi, [rsp+58h+var_8]
add rdi, 8
mov esi, [rsp+58h+var_18]
call _ZNK5ELFIO5elfio8SegmentsixEj; ELFIO::elfio::Segments::operator[](uint)
mov [rsp+58h+var_20], rax
mov rdi, [rsp+58h+var_20]
mov rax, [rdi]
call qword ptr [rax+78h]
mov [rsp+58h+var_28], rax
mov rdi, [rsp+58h+var_20]
mov rax, [rdi]
call qword ptr [rax+48h]
mov [rsp+58h+var_30], rax
mov rax, [rsp+58h+var_30]
add rax, [rsp+58h+var_28]
mov ecx, 0FFFFFFFFh
cmp rax, rcx
jbe short loc_1635B
mov esi, [rsp+58h+var_18]
mov rdx, [rsp+58h+var_30]
add rdx, [rsp+58h+var_28]
lea rdi, aElfAddressSpac; "ELF address space larger than 32bit! Se"...
mov al, 0
call _Z9dbgprintfPKcz; dbgprintf(char const*,...)
mov edi, 0FFFFFFFFh
call _exit
loc_1635B:
mov rdi, [rsp+58h+var_20]
mov rax, [rdi]
call qword ptr [rax+68h]
mov [rsp+58h+var_34], eax
mov rdi, [rsp+58h+var_20]
mov rax, [rdi]
call qword ptr [rax+78h]
mov [rsp+58h+var_38], eax
mov rdi, [rsp+58h+var_20]
mov rax, [rdi]
call qword ptr [rax+48h]
mov [rsp+58h+var_3C], eax
mov eax, [rsp+58h+var_3C]
mov [rsp+58h+var_40], eax
loc_16390:
mov eax, [rsp+58h+var_40]
mov ecx, [rsp+58h+var_3C]
add ecx, [rsp+58h+var_38]
cmp eax, ecx
jnb short loc_1640D
mov eax, [rsp+58h+var_40]
mov ecx, [rsp+58h+var_3C]
add ecx, [rsp+58h+var_34]
cmp eax, ecx
jnb short loc_163EE
mov rax, [rsp+58h+var_10]
mov [rsp+58h+var_50], rax
mov eax, [rsp+58h+var_40]
mov [rsp+58h+var_44], eax
mov rdi, [rsp+58h+var_20]
mov rax, [rdi]
call qword ptr [rax+90h]
mov rdi, [rsp+58h+var_50]; this
mov esi, [rsp+58h+var_44]; unsigned int
mov ecx, [rsp+58h+var_40]
sub ecx, [rsp+58h+var_3C]
mov ecx, ecx
movzx edx, byte ptr [rax+rcx]; unsigned __int8
call _ZN13MemoryManager14setByteNoCacheEjh; MemoryManager::setByteNoCache(uint,uchar)
jmp short loc_163FE
loc_163EE:
mov rdi, [rsp+58h+var_10]; this
mov esi, [rsp+58h+var_40]; unsigned int
xor edx, edx; unsigned __int8
call _ZN13MemoryManager14setByteNoCacheEjh; MemoryManager::setByteNoCache(uint,uchar)
loc_163FE:
jmp short $+2
loc_16400:
mov eax, [rsp+58h+var_40]
add eax, 1
mov [rsp+58h+var_40], eax
jmp short loc_16390
loc_1640D:
jmp short $+2
loc_1640F:
mov eax, [rsp+58h+var_18]
add eax, 1
mov [rsp+58h+var_18], eax
jmp loc_162D9
loc_1641F:
add rsp, 58h
retn
|
long long loadElfToMemory(ELFIO::elfio *a1, MemoryManager *a2)
{
long long result; // rax
long long v3; // rax
unsigned int j; // [rsp+18h] [rbp-40h]
unsigned int v5; // [rsp+1Ch] [rbp-3Ch]
int v6; // [rsp+20h] [rbp-38h]
int v7; // [rsp+24h] [rbp-34h]
long long v8; // [rsp+28h] [rbp-30h]
long long v9; // [rsp+30h] [rbp-28h]
long long v10; // [rsp+38h] [rbp-20h]
unsigned int i; // [rsp+40h] [rbp-18h]
unsigned __int16 v12; // [rsp+46h] [rbp-12h]
v12 = ELFIO::elfio::Segments::size((ELFIO::elfio *)((char *)a1 + 8));
for ( i = 0; ; ++i )
{
result = i;
if ( (int)i >= v12 )
break;
v10 = ELFIO::elfio::Segments::operator[]((char *)a1 + 8, i);
v9 = (*(long long ( **)(long long))(*(_QWORD *)v10 + 120LL))(v10);
v8 = (*(long long ( **)(long long))(*(_QWORD *)v10 + 72LL))(v10);
if ( (unsigned long long)(v9 + v8) > 0xFFFFFFFF )
{
dbgprintf("ELF address space larger than 32bit! Seg %d has max addr of 0x%lx\n", i, v9 + v8);
exit(0xFFFFFFFFLL);
}
v7 = (*(long long ( **)(long long))(*(_QWORD *)v10 + 104LL))(v10);
v6 = (*(long long ( **)(long long))(*(_QWORD *)v10 + 120LL))(v10);
v5 = (*(long long ( **)(long long))(*(_QWORD *)v10 + 72LL))(v10);
for ( j = v5; j < v6 + v5; ++j )
{
if ( j >= v7 + v5 )
{
MemoryManager::setByteNoCache(a2, j, 0);
}
else
{
v3 = (*(long long ( **)(long long))(*(_QWORD *)v10 + 144LL))(v10);
MemoryManager::setByteNoCache(a2, j, *(_BYTE *)(v3 + j - v5));
}
}
}
return result;
}
|
loadElfToMemory:
SUB RSP,0x58
MOV qword ptr [RSP + 0x50],RDI
MOV qword ptr [RSP + 0x48],RSI
MOV RDI,qword ptr [RSP + 0x50]
ADD RDI,0x8
CALL 0x00116940
MOV word ptr [RSP + 0x46],AX
MOV dword ptr [RSP + 0x40],0x0
LAB_001162d9:
MOV EAX,dword ptr [RSP + 0x40]
MOVZX ECX,word ptr [RSP + 0x46]
CMP EAX,ECX
JGE 0x0011641f
MOV RDI,qword ptr [RSP + 0x50]
ADD RDI,0x8
MOV ESI,dword ptr [RSP + 0x40]
CALL 0x00116960
MOV qword ptr [RSP + 0x38],RAX
MOV RDI,qword ptr [RSP + 0x38]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x78]
MOV qword ptr [RSP + 0x30],RAX
MOV RDI,qword ptr [RSP + 0x38]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x48]
MOV qword ptr [RSP + 0x28],RAX
MOV RAX,qword ptr [RSP + 0x28]
ADD RAX,qword ptr [RSP + 0x30]
MOV ECX,0xffffffff
CMP RAX,RCX
JBE 0x0011635b
MOV ESI,dword ptr [RSP + 0x40]
MOV RDX,qword ptr [RSP + 0x28]
ADD RDX,qword ptr [RSP + 0x30]
LEA RDI,[0x1292e7]
MOV AL,0x0
CALL 0x001167d0
MOV EDI,0xffffffff
CALL 0x00115260
LAB_0011635b:
MOV RDI,qword ptr [RSP + 0x38]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x68]
MOV dword ptr [RSP + 0x24],EAX
MOV RDI,qword ptr [RSP + 0x38]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x78]
MOV dword ptr [RSP + 0x20],EAX
MOV RDI,qword ptr [RSP + 0x38]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x48]
MOV dword ptr [RSP + 0x1c],EAX
MOV EAX,dword ptr [RSP + 0x1c]
MOV dword ptr [RSP + 0x18],EAX
LAB_00116390:
MOV EAX,dword ptr [RSP + 0x18]
MOV ECX,dword ptr [RSP + 0x1c]
ADD ECX,dword ptr [RSP + 0x20]
CMP EAX,ECX
JNC 0x0011640d
MOV EAX,dword ptr [RSP + 0x18]
MOV ECX,dword ptr [RSP + 0x1c]
ADD ECX,dword ptr [RSP + 0x24]
CMP EAX,ECX
JNC 0x001163ee
MOV RAX,qword ptr [RSP + 0x48]
MOV qword ptr [RSP + 0x8],RAX
MOV EAX,dword ptr [RSP + 0x18]
MOV dword ptr [RSP + 0x14],EAX
MOV RDI,qword ptr [RSP + 0x38]
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x90]
MOV RDI,qword ptr [RSP + 0x8]
MOV ESI,dword ptr [RSP + 0x14]
MOV ECX,dword ptr [RSP + 0x18]
SUB ECX,dword ptr [RSP + 0x1c]
MOV ECX,ECX
MOVZX EDX,byte ptr [RAX + RCX*0x1]
CALL 0x0011e8f0
JMP 0x001163fe
LAB_001163ee:
MOV RDI,qword ptr [RSP + 0x48]
MOV ESI,dword ptr [RSP + 0x18]
XOR EDX,EDX
CALL 0x0011e8f0
LAB_001163fe:
JMP 0x00116400
LAB_00116400:
MOV EAX,dword ptr [RSP + 0x18]
ADD EAX,0x1
MOV dword ptr [RSP + 0x18],EAX
JMP 0x00116390
LAB_0011640d:
JMP 0x0011640f
LAB_0011640f:
MOV EAX,dword ptr [RSP + 0x40]
ADD EAX,0x1
MOV dword ptr [RSP + 0x40],EAX
JMP 0x001162d9
LAB_0011641f:
ADD RSP,0x58
RET
|
/* loadElfToMemory(ELFIO::elfio*, MemoryManager*) */
void loadElfToMemory(elfio *param_1,MemoryManager *param_2)
{
ushort uVar1;
int iVar2;
int iVar3;
uint uVar4;
long *plVar5;
long lVar6;
long lVar7;
uint local_40;
uint local_18;
uVar1 = ELFIO::elfio::Segments::size((Segments *)(param_1 + 8));
local_18 = 0;
while( true ) {
if ((int)(uint)uVar1 <= (int)local_18) {
return;
}
plVar5 = (long *)ELFIO::elfio::Segments::operator[]((Segments *)(param_1 + 8),local_18);
lVar6 = (**(code **)(*plVar5 + 0x78))();
lVar7 = (**(code **)(*plVar5 + 0x48))();
if (0xffffffff < (ulong)(lVar7 + lVar6)) break;
iVar2 = (**(code **)(*plVar5 + 0x68))();
iVar3 = (**(code **)(*plVar5 + 0x78))();
uVar4 = (**(code **)(*plVar5 + 0x48))();
for (local_40 = uVar4; local_40 < uVar4 + iVar3; local_40 = local_40 + 1) {
if (local_40 < uVar4 + iVar2) {
lVar6 = (**(code **)(*plVar5 + 0x90))();
MemoryManager::setByteNoCache
(param_2,local_40,*(uchar *)(lVar6 + (ulong)(local_40 - uVar4)));
}
else {
MemoryManager::setByteNoCache(param_2,local_40,'\0');
}
}
local_18 = local_18 + 1;
}
dbgprintf("ELF address space larger than 32bit! Seg %d has max addr of 0x%lx\n",(ulong)local_18,
lVar7 + lVar6);
/* WARNING: Subroutine does not return */
exit(-1);
}
|
|
9,909 |
test_double_compare
|
eloqsql/tests/mysql_client_test.c
|
static void test_double_compare()
{
MYSQL_STMT *stmt;
int rc;
char real_data[10], tiny_data;
double double_data;
MYSQL_RES *result;
MYSQL_BIND my_bind[3];
ulong length[3];
char query[MAX_TEST_QUERY_LENGTH];
myheader("test_double_compare");
rc= mysql_autocommit(mysql, TRUE);
myquery(rc);
rc= mysql_query(mysql, "DROP TABLE IF EXISTS test_double_compare");
myquery(rc);
rc= mysql_query(mysql, "CREATE TABLE test_double_compare(col1 tinyint, "
" col2 float, col3 double )");
myquery(rc);
rc= mysql_query(mysql, "INSERT INTO test_double_compare "
"VALUES (1, 10.2, 34.5)");
myquery(rc);
strmov(query, "UPDATE test_double_compare SET col1=100 "
"WHERE col1 = ? AND col2 = ? AND COL3 = ?");
stmt= mysql_simple_prepare(mysql, query);
check_stmt(stmt);
verify_param_count(stmt, 3);
/* Always bzero bind array because there can be internal members */
bzero((char*) my_bind, sizeof(my_bind));
/* tinyint */
my_bind[0].buffer_type= MYSQL_TYPE_TINY;
my_bind[0].buffer= (void *)&tiny_data;
/* string->float */
my_bind[1].buffer_type= MYSQL_TYPE_STRING;
my_bind[1].buffer= (void *)&real_data;
my_bind[1].buffer_length= sizeof(real_data);
my_bind[1].length= &length[1];
length[1]= 10;
/* double */
my_bind[2].buffer_type= MYSQL_TYPE_DOUBLE;
my_bind[2].buffer= (void *)&double_data;
tiny_data= 1;
memset(real_data, 0, sizeof real_data);
strmov(real_data, "10.2");
double_data= 34.5;
rc= mysql_stmt_bind_param(stmt, my_bind);
check_execute(stmt, rc);
rc= mysql_stmt_execute(stmt);
check_execute(stmt, rc);
verify_affected_rows(0);
mysql_stmt_close(stmt);
/* now fetch the results ..*/
rc= mysql_commit(mysql);
myquery(rc);
/* test the results now, only one row should exist */
rc= mysql_query(mysql, "SELECT * FROM test_double_compare");
myquery(rc);
/* get the result */
result= mysql_store_result(mysql);
mytest(result);
rc= my_process_result_set(result);
DIE_UNLESS((int)tiny_data == rc);
mysql_free_result(result);
}
|
O3
|
c
|
test_double_compare:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x2d8, %rsp # imm = 0x2D8
movq %fs:0x28, %rax
movq %rax, -0x20(%rbp)
cmpb $0x1, 0x3d13f7(%rip) # 0x41a4c1
jg 0x49145
movq 0x356eed(%rip), %rbx # 0x39ffc0
movq (%rbx), %rdi
leaq 0x963e7(%rip), %rdx # 0xdf4c4
movl $0x1, %esi
xorl %eax, %eax
callq 0x39240
movq (%rbx), %rdi
movl 0x3d161a(%rip), %ecx # 0x41a70c
leal 0x1(%rcx), %eax
movl %eax, 0x3d1611(%rip) # 0x41a70c
movl 0x3d1606(%rip), %r8d # 0x41a708
movl 0x3d13e3(%rip), %r9d # 0x41a4ec
leaq 0x9b4b7(%rip), %rax # 0xe45c7
movq %rax, (%rsp)
leaq 0x976b1(%rip), %rdx # 0xe07cc
movl $0x1, %esi
xorl %eax, %eax
callq 0x39240
movq (%rbx), %rdi
leaq 0x963cb(%rip), %rdx # 0xdf4fc
movl $0x1, %esi
xorl %eax, %eax
callq 0x39240
movq (%rbx), %rdi
callq 0x394b0
movq 0x3d137c(%rip), %rdi # 0x41a4c8
movl $0x1, %esi
callq 0x3b899
testb %al, %al
jne 0x49345
movq 0x3d1363(%rip), %rdi # 0x41a4c8
leaq 0x9b34d(%rip), %rsi # 0xe44b9
callq 0x3b116
testl %eax, %eax
jne 0x49364
movq 0x3d1348(%rip), %rdi # 0x41a4c8
leaq 0x9b35b(%rip), %rsi # 0xe44e2
callq 0x3b116
testl %eax, %eax
jne 0x49383
movq 0x3d132d(%rip), %rdi # 0x41a4c8
leaq 0x9b38a(%rip), %rsi # 0xe452c
callq 0x3b116
testl %eax, %eax
jne 0x493a2
leaq 0x9b3ad(%rip), %rsi # 0xe4563
leaq -0x160(%rbp), %rbx
movl $0x51, %edx
movq %rbx, %rdi
callq 0x390a0
movq 0x3d12f7(%rip), %rdi # 0x41a4c8
movq %rbx, %rsi
callq 0x3ba15
testq %rax, %rax
je 0x493c1
movq %rax, %rbx
movl $0x3, %esi
movq %rax, %rdi
callq 0x3fe2c
leaq -0x2e0(%rbp), %r14
xorl %r15d, %r15d
movl $0x150, %edx # imm = 0x150
movq %r14, %rdi
xorl %esi, %esi
callq 0x392e0
movl $0x1, 0x60(%r14)
leaq -0x161(%rbp), %rax
movq %rax, 0x10(%r14)
movl $0xfe, 0xd0(%r14)
leaq -0x2c(%rbp), %rcx
movq %rcx, 0x80(%r14)
movl $0xa, %edx
movq %rdx, 0xb0(%r14)
leaq -0x188(%rbp), %rsi
movq %rsi, 0x70(%r14)
movq %rdx, (%rsi)
movl $0x5, 0x140(%r14)
leaq -0x170(%rbp), %rdx
movq %rdx, 0xf0(%r14)
movb $0x1, (%rax)
movb %r15b, 0x9(%rcx)
movl $0x0, 0x5(%rcx)
movb %r15b, 0x4(%rcx)
movl $0x322e3031, (%rcx) # imm = 0x322E3031
movabsq $0x4041400000000000, %rax # imm = 0x4041400000000000
movq %rax, (%rdx)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x90d4e
testb %al, %al
jne 0x493e0
movq %rbx, %rdi
callq 0x3b510
testl %eax, %eax
jne 0x49400
xorl %edi, %edi
callq 0x48820
movq %rbx, %rdi
callq 0x3b639
movq 0x3d1203(%rip), %rdi # 0x41a4c8
callq 0x3b7d5
testb %al, %al
jne 0x49420
movq 0x3d11ef(%rip), %rdi # 0x41a4c8
leaq 0x9b2d9(%rip), %rsi # 0xe45b9
callq 0x3b116
testl %eax, %eax
jne 0x4943f
movq 0x3d11d4(%rip), %rdi # 0x41a4c8
callq 0x3afac
testq %rax, %rax
je 0x4945e
movq %rax, %rbx
movq %rax, %rdi
callq 0x3c0fe
movsbl -0x161(%rbp), %ecx
cmpl %ecx, %eax
jne 0x4947d
movq %rbx, %rdi
callq 0x3b00f
movq %fs:0x28, %rax
cmpq -0x20(%rbp), %rax
jne 0x49495
addq $0x2d8, %rsp # imm = 0x2D8
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
xorl %edi, %edi
callq 0x3ba57
leaq 0x95a59(%rip), %rdi # 0xdedac
leaq 0xabd65(%rip), %rdx # 0xf50bf
movl $0x643, %esi # imm = 0x643
callq 0x3bb30
xorl %edi, %edi
callq 0x3ba57
leaq 0x95a3a(%rip), %rdi # 0xdedac
leaq 0xabd46(%rip), %rdx # 0xf50bf
movl $0x646, %esi # imm = 0x646
callq 0x3bb30
xorl %edi, %edi
callq 0x3ba57
leaq 0x95a1b(%rip), %rdi # 0xdedac
leaq 0xabd27(%rip), %rdx # 0xf50bf
movl $0x64a, %esi # imm = 0x64A
callq 0x3bb30
xorl %edi, %edi
callq 0x3ba57
leaq 0x959fc(%rip), %rdi # 0xdedac
leaq 0xabd08(%rip), %rdx # 0xf50bf
movl $0x64e, %esi # imm = 0x64E
callq 0x3bb30
xorl %edi, %edi
callq 0x3ba57
leaq 0x959dd(%rip), %rdi # 0xdedac
leaq 0x95734(%rip), %rdx # 0xdeb0a
movl $0x653, %esi # imm = 0x653
callq 0x3bb30
movq %rbx, %rdi
callq 0x3bbbe
leaq 0x959bd(%rip), %rdi # 0xdedac
leaq 0xa1571(%rip), %rdx # 0xea967
movl $0x66e, %esi # imm = 0x66E
callq 0x3bb30
movq %rbx, %rdi
callq 0x3bbbe
leaq 0x9599d(%rip), %rdi # 0xdedac
leaq 0xa1551(%rip), %rdx # 0xea967
movl $0x671, %esi # imm = 0x671
callq 0x3bb30
xorl %edi, %edi
callq 0x3ba57
leaq 0x9597e(%rip), %rdi # 0xdedac
leaq 0xabc8a(%rip), %rdx # 0xf50bf
movl $0x679, %esi # imm = 0x679
callq 0x3bb30
xorl %edi, %edi
callq 0x3ba57
leaq 0x9595f(%rip), %rdi # 0xdedac
leaq 0xabc6b(%rip), %rdx # 0xf50bf
movl $0x67d, %esi # imm = 0x67D
callq 0x3bb30
xorl %edi, %edi
callq 0x3ba57
leaq 0x95940(%rip), %rdi # 0xdedac
leaq 0x95709(%rip), %rdx # 0xdeb7c
movl $0x681, %esi # imm = 0x681
callq 0x3bb30
leaq 0x95928(%rip), %rdi # 0xdedac
leaq 0x9b150(%rip), %rdx # 0xe45db
movl $0x684, %esi # imm = 0x684
callq 0x3bb30
callq 0x39290
|
test_double_compare:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
sub rsp, 2D8h
mov rax, fs:28h
mov [rbp+var_20], rax
cmp cs:opt_silent, 1
jg short loc_49145
mov rbx, cs:stdout_ptr
mov rdi, [rbx]
lea rdx, asc_DF4C4; "\n\n###################################"...
mov esi, 1
xor eax, eax
call ___fprintf_chk
mov rdi, [rbx]
mov ecx, cs:test_count
lea eax, [rcx+1]
mov cs:test_count, eax
mov r8d, cs:iter_count
mov r9d, cs:opt_count
lea rax, aSelectFromTest_12+0Eh; "test_double_compare"
mov [rsp+2F0h+var_2F0], rax
lea rdx, aUOfUUS; "%u of (%u/%u): %s"
mov esi, 1
xor eax, eax
call ___fprintf_chk
mov rdi, [rbx]
lea rdx, asc_DF4FC; " \n###################################"...
mov esi, 1
xor eax, eax
call ___fprintf_chk
mov rdi, [rbx]
call _fflush
loc_49145:
mov rdi, cs:mysql
mov esi, 1
call wrap_mysql_autocommit
test al, al
jnz loc_49345
mov rdi, cs:mysql
lea rsi, aDropTableIfExi_19; "DROP TABLE IF EXISTS test_double_compar"...
call wrap_mysql_query
test eax, eax
jnz loc_49364
mov rdi, cs:mysql
lea rsi, aCreateTableTes_26; "CREATE TABLE test_double_compare(col1 t"...
call wrap_mysql_query
test eax, eax
jnz loc_49383
mov rdi, cs:mysql
lea rsi, aInsertIntoTest_19; "INSERT INTO test_double_compare VALUES "...
call wrap_mysql_query
test eax, eax
jnz loc_493A2
lea rsi, aUpdateTestDoub; "UPDATE test_double_compare SET col1=100"...
lea rbx, [rbp+var_160]
mov edx, 51h ; 'Q'
mov rdi, rbx
call _memcpy
mov rdi, cs:mysql
mov rsi, rbx
call mysql_simple_prepare
test rax, rax
jz loc_493C1
mov rbx, rax
mov esi, 3
mov rdi, rax
call verify_param_count
lea r14, [rbp+var_2E0]
xor r15d, r15d
mov edx, 150h
mov rdi, r14
xor esi, esi
call _memset
mov dword ptr [r14+60h], 1
lea rax, [rbp+var_161]
mov [r14+10h], rax
mov dword ptr [r14+0D0h], 0FEh
lea rcx, [rbp+var_2C]
mov [r14+80h], rcx
mov edx, 0Ah
mov [r14+0B0h], rdx
lea rsi, [rbp+var_188]
mov [r14+70h], rsi
mov [rsi], rdx
mov dword ptr [r14+140h], 5
lea rdx, [rbp+var_170]
mov [r14+0F0h], rdx
mov byte ptr [rax], 1
mov [rcx+9], r15b
mov dword ptr [rcx+5], 0
mov [rcx+4], r15b
mov dword ptr [rcx], 322E3031h
mov rax, 4041400000000000h
mov [rdx], rax
mov rdi, rbx
mov rsi, r14
call mysql_stmt_bind_param
test al, al
jnz loc_493E0
mov rdi, rbx
call wrap_mysql_stmt_execute
test eax, eax
jnz loc_49400
xor edi, edi
call verify_affected_rows
mov rdi, rbx
call wrap_mysql_stmt_close
mov rdi, cs:mysql
call wrap_mysql_commit
test al, al
jnz loc_49420
mov rdi, cs:mysql
lea rsi, aSelectFromTest_12; "SELECT * FROM test_double_compare"
call wrap_mysql_query
test eax, eax
jnz loc_4943F
mov rdi, cs:mysql
call wrap_mysql_store_result
test rax, rax
jz loc_4945E
mov rbx, rax
mov rdi, rax
call my_process_result_set
movsx ecx, [rbp+var_161]
cmp eax, ecx
jnz loc_4947D
mov rdi, rbx
call wrap_mysql_free_result
mov rax, fs:28h
cmp rax, [rbp+var_20]
jnz loc_49495
add rsp, 2D8h
pop rbx
pop r14
pop r15
pop rbp
retn
loc_49345:
xor edi, edi
call print_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aTmIYear0+9; "r == 0"
mov esi, 643h
call die
loc_49364:
xor edi, edi
call print_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aTmIYear0+9; "r == 0"
mov esi, 646h
call die
loc_49383:
xor edi, edi
call print_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aTmIYear0+9; "r == 0"
mov esi, 64Ah
call die
loc_493A2:
xor edi, edi
call print_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aTmIYear0+9; "r == 0"
mov esi, 64Eh
call die
loc_493C1:
xor edi, edi
call print_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aStmt0; "stmt != 0"
mov esi, 653h
call die
loc_493E0:
mov rdi, rbx
call print_st_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aRcMysqlDataTru+1Eh; "rc == 0"
mov esi, 66Eh
call die
loc_49400:
mov rdi, rbx
call print_st_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aRcMysqlDataTru+1Eh; "rc == 0"
mov esi, 671h
call die
loc_49420:
xor edi, edi
call print_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aTmIYear0+9; "r == 0"
mov esi, 679h
call die
loc_4943F:
xor edi, edi
call print_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aTmIYear0+9; "r == 0"
mov esi, 67Dh
call die
loc_4945E:
xor edi, edi
call print_error
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aFalse; "FALSE"
mov esi, 681h
call die
loc_4947D:
lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"...
lea rdx, aIntTinyDataRc_0; "(int)tiny_data == rc"
mov esi, 684h
call die
loc_49495:
call ___stack_chk_fail
|
unsigned long long test_double_compare()
{
int v0; // ecx
long long v1; // rax
long long v2; // rbx
long long v3; // rax
long long v4; // rbx
int v5; // eax
_BYTE v7[16]; // [rsp+10h] [rbp-2E0h] BYREF
char *v8; // [rsp+20h] [rbp-2D0h]
int v9; // [rsp+70h] [rbp-280h]
long long *v10; // [rsp+80h] [rbp-270h]
char *v11; // [rsp+90h] [rbp-260h]
long long v12; // [rsp+C0h] [rbp-230h]
int v13; // [rsp+E0h] [rbp-210h]
long long *v14; // [rsp+100h] [rbp-1F0h]
int v15; // [rsp+150h] [rbp-1A0h]
long long v16; // [rsp+168h] [rbp-188h] BYREF
long long v17; // [rsp+180h] [rbp-170h] BYREF
char v18; // [rsp+18Fh] [rbp-161h] BYREF
_BYTE v19[308]; // [rsp+190h] [rbp-160h] BYREF
char v20[12]; // [rsp+2C4h] [rbp-2Ch] BYREF
unsigned long long v21; // [rsp+2D0h] [rbp-20h]
v21 = __readfsqword(0x28u);
if ( opt_silent <= 1 )
{
__fprintf_chk(stdout, 1LL, "\n\n#####################################\n");
v0 = test_count++;
__fprintf_chk(stdout, 1LL, "%u of (%u/%u): %s", v0, iter_count, opt_count, "test_double_compare");
__fprintf_chk(stdout, 1LL, " \n#####################################\n");
fflush(stdout);
}
if ( wrap_mysql_autocommit(mysql, 1) )
{
print_error(0LL);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1603, "r == 0");
}
if ( (unsigned int)wrap_mysql_query(mysql, (long long)"DROP TABLE IF EXISTS test_double_compare") )
{
print_error(0LL);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1606, "r == 0");
}
if ( (unsigned int)wrap_mysql_query(
mysql,
(long long)"CREATE TABLE test_double_compare(col1 tinyint, col2 float, col3 double )") )
{
print_error(0LL);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1610, "r == 0");
}
if ( (unsigned int)wrap_mysql_query(mysql, (long long)"INSERT INTO test_double_compare VALUES (1, 10.2, 34.5)") )
{
print_error(0LL);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1614, "r == 0");
}
memcpy(v19, "UPDATE test_double_compare SET col1=100 WHERE col1 = ? AND col2 = ? AND COL3 = ?", 81LL);
v1 = mysql_simple_prepare(mysql, (long long)v19);
if ( !v1 )
{
print_error(0LL);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1619, "stmt != 0");
}
v2 = v1;
verify_param_count(v1, 3LL);
memset(v7, 0LL, 336LL);
v9 = 1;
v8 = &v18;
v13 = 254;
v11 = v20;
v12 = 10LL;
v10 = &v16;
v16 = 10LL;
v15 = 5;
v14 = &v17;
v18 = 1;
v20[9] = 0;
*(_DWORD *)&v20[5] = 0;
strcpy(v20, "10.2");
v17 = 0x4041400000000000LL;
if ( (unsigned __int8)mysql_stmt_bind_param(v2, v7) )
{
print_st_error(v2);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1646, "rc == 0");
}
if ( (unsigned int)wrap_mysql_stmt_execute(v2) )
{
print_st_error(v2);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1649, "rc == 0");
}
verify_affected_rows(0LL);
wrap_mysql_stmt_close(v2);
if ( wrap_mysql_commit(mysql) )
{
print_error(0LL);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1657, "r == 0");
}
if ( (unsigned int)wrap_mysql_query(mysql, (long long)"SELECT * FROM test_double_compare") )
{
print_error(0LL);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1661, "r == 0");
}
v3 = wrap_mysql_store_result(mysql);
if ( !v3 )
{
print_error(0LL);
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1665, "FALSE");
}
v4 = v3;
v5 = my_process_result_set(v3);
if ( v5 != v18 )
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 1668, "(int)tiny_data == rc");
wrap_mysql_free_result(v4);
return __readfsqword(0x28u);
}
|
test_double_compare:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x2d8
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x20],RAX
CMP byte ptr [0x0051a4c1],0x1
JG 0x00149145
MOV RBX,qword ptr [0x0049ffc0]
MOV RDI,qword ptr [RBX]
LEA RDX,[0x1df4c4]
MOV ESI,0x1
XOR EAX,EAX
CALL 0x00139240
MOV RDI,qword ptr [RBX]
MOV ECX,dword ptr [0x0051a70c]
LEA EAX,[RCX + 0x1]
MOV dword ptr [0x0051a70c],EAX
MOV R8D,dword ptr [0x0051a708]
MOV R9D,dword ptr [0x0051a4ec]
LEA RAX,[0x1e45c7]
MOV qword ptr [RSP],RAX
LEA RDX,[0x1e07cc]
MOV ESI,0x1
XOR EAX,EAX
CALL 0x00139240
MOV RDI,qword ptr [RBX]
LEA RDX,[0x1df4fc]
MOV ESI,0x1
XOR EAX,EAX
CALL 0x00139240
MOV RDI,qword ptr [RBX]
CALL 0x001394b0
LAB_00149145:
MOV RDI,qword ptr [0x0051a4c8]
MOV ESI,0x1
CALL 0x0013b899
TEST AL,AL
JNZ 0x00149345
MOV RDI,qword ptr [0x0051a4c8]
LEA RSI,[0x1e44b9]
CALL 0x0013b116
TEST EAX,EAX
JNZ 0x00149364
MOV RDI,qword ptr [0x0051a4c8]
LEA RSI,[0x1e44e2]
CALL 0x0013b116
TEST EAX,EAX
JNZ 0x00149383
MOV RDI,qword ptr [0x0051a4c8]
LEA RSI,[0x1e452c]
CALL 0x0013b116
TEST EAX,EAX
JNZ 0x001493a2
LEA RSI,[0x1e4563]
LEA RBX,[RBP + -0x160]
MOV EDX,0x51
MOV RDI,RBX
CALL 0x001390a0
MOV RDI,qword ptr [0x0051a4c8]
MOV RSI,RBX
CALL 0x0013ba15
TEST RAX,RAX
JZ 0x001493c1
MOV RBX,RAX
MOV ESI,0x3
MOV RDI,RAX
CALL 0x0013fe2c
LEA R14,[RBP + -0x2e0]
XOR R15D,R15D
MOV EDX,0x150
MOV RDI,R14
XOR ESI,ESI
CALL 0x001392e0
MOV dword ptr [R14 + 0x60],0x1
LEA RAX,[RBP + -0x161]
MOV qword ptr [R14 + 0x10],RAX
MOV dword ptr [R14 + 0xd0],0xfe
LEA RCX,[RBP + -0x2c]
MOV qword ptr [R14 + 0x80],RCX
MOV EDX,0xa
MOV qword ptr [R14 + 0xb0],RDX
LEA RSI,[RBP + -0x188]
MOV qword ptr [R14 + 0x70],RSI
MOV qword ptr [RSI],RDX
MOV dword ptr [R14 + 0x140],0x5
LEA RDX,[RBP + -0x170]
MOV qword ptr [R14 + 0xf0],RDX
MOV byte ptr [RAX],0x1
MOV byte ptr [RCX + 0x9],R15B
MOV dword ptr [RCX + 0x5],0x0
MOV byte ptr [RCX + 0x4],R15B
MOV dword ptr [RCX],0x322e3031
MOV RAX,0x4041400000000000
MOV qword ptr [RDX],RAX
MOV RDI,RBX
MOV RSI,R14
CALL 0x00190d4e
TEST AL,AL
JNZ 0x001493e0
MOV RDI,RBX
CALL 0x0013b510
TEST EAX,EAX
JNZ 0x00149400
XOR EDI,EDI
CALL 0x00148820
MOV RDI,RBX
CALL 0x0013b639
MOV RDI,qword ptr [0x0051a4c8]
CALL 0x0013b7d5
TEST AL,AL
JNZ 0x00149420
MOV RDI,qword ptr [0x0051a4c8]
LEA RSI,[0x1e45b9]
CALL 0x0013b116
TEST EAX,EAX
JNZ 0x0014943f
MOV RDI,qword ptr [0x0051a4c8]
CALL 0x0013afac
TEST RAX,RAX
JZ 0x0014945e
MOV RBX,RAX
MOV RDI,RAX
CALL 0x0013c0fe
MOVSX ECX,byte ptr [RBP + -0x161]
CMP EAX,ECX
JNZ 0x0014947d
MOV RDI,RBX
CALL 0x0013b00f
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x20]
JNZ 0x00149495
ADD RSP,0x2d8
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_00149345:
XOR EDI,EDI
CALL 0x0013ba57
LEA RDI,[0x1dedac]
LEA RDX,[0x1f50bf]
MOV ESI,0x643
CALL 0x0013bb30
LAB_00149364:
XOR EDI,EDI
CALL 0x0013ba57
LEA RDI,[0x1dedac]
LEA RDX,[0x1f50bf]
MOV ESI,0x646
CALL 0x0013bb30
LAB_00149383:
XOR EDI,EDI
CALL 0x0013ba57
LEA RDI,[0x1dedac]
LEA RDX,[0x1f50bf]
MOV ESI,0x64a
CALL 0x0013bb30
LAB_001493a2:
XOR EDI,EDI
CALL 0x0013ba57
LEA RDI,[0x1dedac]
LEA RDX,[0x1f50bf]
MOV ESI,0x64e
CALL 0x0013bb30
LAB_001493c1:
XOR EDI,EDI
CALL 0x0013ba57
LEA RDI,[0x1dedac]
LEA RDX,[0x1deb0a]
MOV ESI,0x653
CALL 0x0013bb30
LAB_001493e0:
MOV RDI,RBX
CALL 0x0013bbbe
LEA RDI,[0x1dedac]
LEA RDX,[0x1ea967]
MOV ESI,0x66e
CALL 0x0013bb30
LAB_00149400:
MOV RDI,RBX
CALL 0x0013bbbe
LEA RDI,[0x1dedac]
LEA RDX,[0x1ea967]
MOV ESI,0x671
CALL 0x0013bb30
LAB_00149420:
XOR EDI,EDI
CALL 0x0013ba57
LEA RDI,[0x1dedac]
LEA RDX,[0x1f50bf]
MOV ESI,0x679
CALL 0x0013bb30
LAB_0014943f:
XOR EDI,EDI
CALL 0x0013ba57
LEA RDI,[0x1dedac]
LEA RDX,[0x1f50bf]
MOV ESI,0x67d
CALL 0x0013bb30
LAB_0014945e:
XOR EDI,EDI
CALL 0x0013ba57
LEA RDI,[0x1dedac]
LEA RDX,[0x1deb7c]
MOV ESI,0x681
CALL 0x0013bb30
LAB_0014947d:
LEA RDI,[0x1dedac]
LEA RDX,[0x1e45db]
MOV ESI,0x684
CALL 0x0013bb30
LAB_00149495:
CALL 0x00139290
|
void test_double_compare(void)
{
int *puVar1;
char cVar2;
int iVar3;
long lVar4;
long in_FS_OFFSET;
int1 local_2e8 [16];
char *local_2d8;
int4 local_288;
int8 *local_278;
int4 *local_268;
int8 local_238;
int4 local_218;
int8 *local_1f8;
int4 local_1a8;
int8 local_190 [3];
int8 local_178;
char local_169;
int1 local_168 [308];
int4 local_34;
int1 local_30;
int4 local_2f;
int1 local_2b;
long local_28;
puVar1 = PTR_stdout_0049ffc0;
local_28 = *(long *)(in_FS_OFFSET + 0x28);
if (opt_silent < '\x02') {
__fprintf_chk(*(int8 *)PTR_stdout_0049ffc0,1,"\n\n#####################################\n"
);
iVar3 = test_count;
test_count = test_count + 1;
__fprintf_chk(*(int8 *)puVar1,1,"%u of (%u/%u): %s",iVar3,iter_count,opt_count,
"test_double_compare");
__fprintf_chk(*(int8 *)puVar1,1," \n#####################################\n");
fflush(*(FILE **)puVar1);
}
cVar2 = wrap_mysql_autocommit(mysql,1);
if (cVar2 != '\0') {
print_error(0);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x643,"r == 0");
}
iVar3 = wrap_mysql_query(mysql,"DROP TABLE IF EXISTS test_double_compare");
if (iVar3 != 0) {
print_error(0);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x646,"r == 0");
}
iVar3 = wrap_mysql_query(mysql,
"CREATE TABLE test_double_compare(col1 tinyint, col2 float, col3 double )"
);
if (iVar3 != 0) {
print_error(0);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x64a,"r == 0");
}
iVar3 = wrap_mysql_query(mysql,"INSERT INTO test_double_compare VALUES (1, 10.2, 34.5)");
if (iVar3 != 0) {
print_error(0);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x64e,"r == 0");
}
memcpy(local_168,
"UPDATE test_double_compare SET col1=100 WHERE col1 = ? AND col2 = ? AND COL3 = ?",0x51);
lVar4 = mysql_simple_prepare(mysql,local_168);
if (lVar4 == 0) {
print_error(0);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x653,"stmt != 0");
}
verify_param_count(lVar4);
memset(local_2e8,0,0x150);
local_288 = 1;
local_2d8 = &local_169;
local_218 = 0xfe;
local_268 = &local_34;
local_238 = 10;
local_278 = local_190;
local_190[0] = 10;
local_1a8 = 5;
local_1f8 = &local_178;
local_169 = '\x01';
local_2b = 0;
local_2f = 0;
local_30 = 0;
local_34 = 0x322e3031;
local_178 = 0x4041400000000000;
cVar2 = mysql_stmt_bind_param(lVar4,local_2e8);
if (cVar2 != '\0') {
print_st_error(lVar4);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x66e,"rc == 0");
}
iVar3 = wrap_mysql_stmt_execute(lVar4);
if (iVar3 == 0) {
verify_affected_rows(0);
wrap_mysql_stmt_close(lVar4);
cVar2 = wrap_mysql_commit(mysql);
if (cVar2 != '\0') {
print_error(0);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x679,"r == 0");
}
iVar3 = wrap_mysql_query(mysql,"SELECT * FROM test_double_compare");
if (iVar3 != 0) {
print_error(0);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x67d,"r == 0");
}
lVar4 = wrap_mysql_store_result(mysql);
if (lVar4 == 0) {
print_error(0);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x681,"FALSE");
}
iVar3 = my_process_result_set(lVar4);
if (iVar3 == local_169) {
wrap_mysql_free_result(lVar4);
if (*(long *)(in_FS_OFFSET + 0x28) == local_28) {
return;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x684,
"(int)tiny_data == rc");
}
print_st_error(lVar4);
/* WARNING: Subroutine does not return */
die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x671,"rc == 0");
}
|
|
9,910 |
JS_ReadModule
|
bluesky950520[P]quickjs/quickjs.c
|
static JSValue JS_ReadModule(BCReaderState *s)
{
JSContext *ctx = s->ctx;
JSValue obj;
JSModuleDef *m = NULL;
JSAtom module_name;
int i;
uint8_t v8;
if (bc_get_atom(s, &module_name))
goto fail;
#ifdef DUMP_READ_OBJECT
if (check_dump_flag(s->ctx->rt, DUMP_READ_OBJECT)) {
bc_read_trace(s, "name: ");
print_atom(s->ctx, module_name);
printf("\n");
}
#endif
m = js_new_module_def(ctx, module_name);
if (!m)
goto fail;
obj = js_dup(JS_MKPTR(JS_TAG_MODULE, m));
if (bc_get_leb128_int(s, &m->req_module_entries_count))
goto fail;
obj = JS_NewModuleValue(ctx, m);
if (m->req_module_entries_count != 0) {
m->req_module_entries_size = m->req_module_entries_count;
m->req_module_entries = js_mallocz(ctx, sizeof(m->req_module_entries[0]) * m->req_module_entries_size);
if (!m->req_module_entries)
goto fail;
for(i = 0; i < m->req_module_entries_count; i++) {
JSReqModuleEntry *rme = &m->req_module_entries[i];
if (bc_get_atom(s, &rme->module_name))
goto fail;
}
}
if (bc_get_leb128_int(s, &m->export_entries_count))
goto fail;
if (m->export_entries_count != 0) {
m->export_entries_size = m->export_entries_count;
m->export_entries = js_mallocz(ctx, sizeof(m->export_entries[0]) * m->export_entries_size);
if (!m->export_entries)
goto fail;
for(i = 0; i < m->export_entries_count; i++) {
JSExportEntry *me = &m->export_entries[i];
if (bc_get_u8(s, &v8))
goto fail;
me->export_type = v8;
if (me->export_type == JS_EXPORT_TYPE_LOCAL) {
if (bc_get_leb128_int(s, &me->u.local.var_idx))
goto fail;
} else {
if (bc_get_leb128_int(s, &me->u.req_module_idx))
goto fail;
if (bc_get_atom(s, &me->local_name))
goto fail;
}
if (bc_get_atom(s, &me->export_name))
goto fail;
}
}
if (bc_get_leb128_int(s, &m->star_export_entries_count))
goto fail;
if (m->star_export_entries_count != 0) {
m->star_export_entries_size = m->star_export_entries_count;
m->star_export_entries = js_mallocz(ctx, sizeof(m->star_export_entries[0]) * m->star_export_entries_size);
if (!m->star_export_entries)
goto fail;
for(i = 0; i < m->star_export_entries_count; i++) {
JSStarExportEntry *se = &m->star_export_entries[i];
if (bc_get_leb128_int(s, &se->req_module_idx))
goto fail;
}
}
if (bc_get_leb128_int(s, &m->import_entries_count))
goto fail;
if (m->import_entries_count != 0) {
m->import_entries_size = m->import_entries_count;
m->import_entries = js_mallocz(ctx, sizeof(m->import_entries[0]) * m->import_entries_size);
if (!m->import_entries)
goto fail;
for(i = 0; i < m->import_entries_count; i++) {
JSImportEntry *mi = &m->import_entries[i];
if (bc_get_leb128_int(s, &mi->var_idx))
goto fail;
if (bc_get_atom(s, &mi->import_name))
goto fail;
if (bc_get_leb128_int(s, &mi->req_module_idx))
goto fail;
}
}
if (bc_get_u8(s, &v8))
goto fail;
m->has_tla = (v8 != 0);
m->func_obj = JS_ReadObjectRec(s);
if (JS_IsException(m->func_obj))
goto fail;
return obj;
fail:
if (m) {
js_free_module_def(ctx, m);
}
return JS_EXCEPTION;
}
|
O1
|
c
|
JS_ReadModule:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %r15
movq (%rdi), %rbx
leaq 0x1c(%rsp), %rsi
callq 0x46eb6
testl %eax, %eax
je 0x462f1
xorl %r14d, %r14d
movl $0x6, %r15d
testq %r14, %r14
je 0x462d8
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3b6a0
xorl %eax, %eax
xorl %ecx, %ecx
orq %rcx, %rax
movq %r15, %rdx
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl 0x1c(%rsp), %esi
movq %rbx, %rdi
callq 0xff78
testq %rax, %rax
je 0x462bf
movq %rax, %r14
incl (%rax)
leaq 0x20(%rax), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x45a75
testl %eax, %eax
jne 0x462c2
incl (%r14)
movslq 0x20(%r14), %rsi
testq %rsi, %rsi
jne 0x463ec
leaq 0x30(%r14), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x45a75
testl %eax, %eax
jne 0x462c2
movslq (%r12), %rsi
testq %rsi, %rsi
jne 0x46445
leaq 0x40(%r14), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x45a75
testl %eax, %eax
jne 0x462c2
movslq (%r12), %rsi
testq %rsi, %rsi
jne 0x46524
leaq 0x50(%r14), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x45a75
testl %eax, %eax
jne 0x462c2
movslq (%r12), %rax
testq %rax, %rax
jne 0x4657d
leaq 0xf(%rsp), %rsi
movq %r15, %rdi
callq 0x45a3d
testl %eax, %eax
jne 0x462c2
cmpb $0x0, 0xf(%rsp)
setne 0x80(%r14)
movq %r15, %rdi
callq 0x32909
movq %rax, 0x68(%r14)
movq %rdx, 0x70(%r14)
cmpl $0x6, %edx
je 0x462c2
movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000
movq %r14, %rcx
andq %rax, %rcx
movl %r14d, %eax
movq $-0x3, %r15
jmp 0x462dc
movl %esi, 0x24(%r14)
shlq $0x4, %rsi
movq %rbx, %rdi
callq 0xee06
movq %rax, 0x18(%r14)
testq %rax, %rax
je 0x462c2
cmpl $0x0, (%r12)
jle 0x4632a
xorl %r13d, %r13d
xorl %ebp, %ebp
movq 0x18(%r14), %rsi
addq %r13, %rsi
movq %r15, %rdi
callq 0x46eb6
testl %eax, %eax
jne 0x462c2
incq %rbp
movslq (%r12), %rax
addq $0x10, %r13
cmpq %rax, %rbp
jl 0x46419
jmp 0x4632a
movl %esi, 0x34(%r14)
shlq $0x5, %rsi
movq %rbx, %rdi
callq 0xee06
movq %rax, 0x28(%r14)
testq %rax, %rax
je 0x462c2
cmpl $0x0, (%r12)
jle 0x4634a
movl $0x18, %r13d
xorl %ecx, %ecx
movq %rcx, 0x10(%rsp)
movq 0x28(%r14), %rbp
movq %r15, %rdi
leaq 0xf(%rsp), %rsi
callq 0x45a3d
testl %eax, %eax
jne 0x462c2
movq %r13, 0x20(%rsp)
leaq -0x18(,%r13), %rsi
addq %rbp, %rsi
movzbl 0xf(%rsp), %r13d
movl %r13d, 0x10(%rsi)
movq %r15, %rdi
callq 0x45a75
testl %r13d, %r13d
je 0x464e3
testl %eax, %eax
jne 0x462c2
movq 0x20(%rsp), %r13
leaq -0x4(,%r13), %rsi
addq %rbp, %rsi
movq %r15, %rdi
callq 0x46eb6
testl %eax, %eax
je 0x464f0
jmp 0x462c2
testl %eax, %eax
movq 0x20(%rsp), %r13
jne 0x462c2
addq %r13, %rbp
movq %r15, %rdi
movq %rbp, %rsi
callq 0x46eb6
testl %eax, %eax
movq 0x10(%rsp), %rcx
jne 0x462c2
incq %rcx
movslq (%r12), %rax
addq $0x20, %r13
cmpq %rax, %rcx
jl 0x46475
jmp 0x4634a
movl %esi, 0x44(%r14)
shlq $0x2, %rsi
movq %rbx, %rdi
callq 0xee06
movq %rax, 0x38(%r14)
testq %rax, %rax
je 0x462c2
cmpl $0x0, (%r12)
jle 0x4636e
xorl %r13d, %r13d
xorl %ebp, %ebp
movq 0x38(%r14), %rsi
addq %r13, %rsi
movq %r15, %rdi
callq 0x45a75
testl %eax, %eax
jne 0x462c2
incq %rbp
movslq (%r12), %rax
addq $0x4, %r13
cmpq %rax, %rbp
jl 0x46551
jmp 0x4636e
movl %eax, 0x54(%r14)
shlq $0x2, %rax
leaq (%rax,%rax,2), %rsi
movq %rbx, %rdi
callq 0xee06
movq %rax, 0x48(%r14)
testq %rax, %rax
je 0x462c2
cmpl $0x0, (%r12)
jle 0x46392
xorl %r13d, %r13d
movq $0x0, 0x10(%rsp)
movq 0x48(%r14), %rbp
movq %rbp, %rsi
addq %r13, %rsi
movq %r15, %rdi
callq 0x45a75
testl %eax, %eax
jne 0x462c2
leaq 0x4(,%r13), %rsi
addq %rbp, %rsi
movq %r15, %rdi
callq 0x46eb6
testl %eax, %eax
jne 0x462c2
leaq 0x8(,%r13), %rsi
addq %rbp, %rsi
movq %r15, %rdi
callq 0x45a75
testl %eax, %eax
jne 0x462c2
movq 0x10(%rsp), %rdx
incq %rdx
movslq (%r12), %rax
addq $0xc, %r13
movq %rdx, 0x10(%rsp)
cmpq %rax, %rdx
jl 0x465b5
jmp 0x46392
|
JS_ReadModule:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r15, rdi
mov rbx, [rdi]
lea rsi, [rsp+58h+var_3C]
call bc_get_atom
test eax, eax
jz short loc_462F1
loc_462BF:
xor r14d, r14d
loc_462C2:
mov r15d, 6
test r14, r14
jz short loc_462D8
mov rdi, rbx
mov rsi, r14
call js_free_module_def
loc_462D8:
xor eax, eax
xor ecx, ecx
loc_462DC:
or rax, rcx
mov rdx, r15
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_462F1:
mov esi, [rsp+58h+var_3C]
mov rdi, rbx
call js_new_module_def
test rax, rax
jz short loc_462BF
mov r14, rax
inc dword ptr [rax]
lea r12, [rax+20h]
mov rdi, r15
mov rsi, r12
call bc_get_leb128
test eax, eax
jnz short loc_462C2
inc dword ptr [r14]
movsxd rsi, dword ptr [r14+20h]
test rsi, rsi
jnz loc_463EC
loc_4632A:
lea r12, [r14+30h]
mov rdi, r15
mov rsi, r12
call bc_get_leb128
test eax, eax
jnz short loc_462C2
movsxd rsi, dword ptr [r12]
test rsi, rsi
jnz loc_46445
loc_4634A:
lea r12, [r14+40h]
mov rdi, r15
mov rsi, r12
call bc_get_leb128
test eax, eax
jnz loc_462C2
movsxd rsi, dword ptr [r12]
test rsi, rsi
jnz loc_46524
loc_4636E:
lea r12, [r14+50h]
mov rdi, r15
mov rsi, r12
call bc_get_leb128
test eax, eax
jnz loc_462C2
movsxd rax, dword ptr [r12]
test rax, rax
jnz loc_4657D
loc_46392:
lea rsi, [rsp+58h+var_49]
mov rdi, r15
call bc_get_u8
test eax, eax
jnz loc_462C2
cmp [rsp+58h+var_49], 0
setnz byte ptr [r14+80h]
mov rdi, r15
call JS_ReadObjectRec
mov [r14+68h], rax
mov [r14+70h], rdx
cmp edx, 6
jz loc_462C2
mov rax, 0FFFFFFFF00000000h
mov rcx, r14
and rcx, rax
mov eax, r14d
mov r15, 0FFFFFFFFFFFFFFFDh
jmp loc_462DC
loc_463EC:
mov [r14+24h], esi
shl rsi, 4
mov rdi, rbx
call js_mallocz
mov [r14+18h], rax
test rax, rax
jz loc_462C2
cmp dword ptr [r12], 0
jle loc_4632A
xor r13d, r13d
xor ebp, ebp
loc_46419:
mov rsi, [r14+18h]
add rsi, r13
mov rdi, r15
call bc_get_atom
test eax, eax
jnz loc_462C2
inc rbp
movsxd rax, dword ptr [r12]
add r13, 10h
cmp rbp, rax
jl short loc_46419
jmp loc_4632A
loc_46445:
mov [r14+34h], esi
shl rsi, 5
mov rdi, rbx
call js_mallocz
mov [r14+28h], rax
test rax, rax
jz loc_462C2
cmp dword ptr [r12], 0
jle loc_4634A
mov r13d, 18h
xor ecx, ecx
loc_46475:
mov [rsp+58h+var_48], rcx
mov rbp, [r14+28h]
mov rdi, r15
lea rsi, [rsp+58h+var_49]
call bc_get_u8
test eax, eax
jnz loc_462C2
mov [rsp+58h+var_38], r13
lea rsi, ds:0FFFFFFFFFFFFFFE8h[r13]
add rsi, rbp
movzx r13d, [rsp+58h+var_49]
mov [rsi+10h], r13d
mov rdi, r15
call bc_get_leb128
test r13d, r13d
jz short loc_464E3
test eax, eax
jnz loc_462C2
mov r13, [rsp+58h+var_38]
lea rsi, ds:0FFFFFFFFFFFFFFFCh[r13]
add rsi, rbp
mov rdi, r15
call bc_get_atom
test eax, eax
jz short loc_464F0
jmp loc_462C2
loc_464E3:
test eax, eax
mov r13, [rsp+58h+var_38]
jnz loc_462C2
loc_464F0:
add rbp, r13
mov rdi, r15
mov rsi, rbp
call bc_get_atom
test eax, eax
mov rcx, [rsp+58h+var_48]
jnz loc_462C2
inc rcx
movsxd rax, dword ptr [r12]
add r13, 20h ; ' '
cmp rcx, rax
jl loc_46475
jmp loc_4634A
loc_46524:
mov [r14+44h], esi
shl rsi, 2
mov rdi, rbx
call js_mallocz
mov [r14+38h], rax
test rax, rax
jz loc_462C2
cmp dword ptr [r12], 0
jle loc_4636E
xor r13d, r13d
xor ebp, ebp
loc_46551:
mov rsi, [r14+38h]
add rsi, r13
mov rdi, r15
call bc_get_leb128
test eax, eax
jnz loc_462C2
inc rbp
movsxd rax, dword ptr [r12]
add r13, 4
cmp rbp, rax
jl short loc_46551
jmp loc_4636E
loc_4657D:
mov [r14+54h], eax
shl rax, 2
lea rsi, [rax+rax*2]
mov rdi, rbx
call js_mallocz
mov [r14+48h], rax
test rax, rax
jz loc_462C2
cmp dword ptr [r12], 0
jle loc_46392
xor r13d, r13d
mov [rsp+58h+var_48], 0
loc_465B5:
mov rbp, [r14+48h]
mov rsi, rbp
add rsi, r13
mov rdi, r15
call bc_get_leb128
test eax, eax
jnz loc_462C2
lea rsi, ds:4[r13]
add rsi, rbp
mov rdi, r15
call bc_get_atom
test eax, eax
jnz loc_462C2
lea rsi, ds:8[r13]
add rsi, rbp
mov rdi, r15
call bc_get_leb128
test eax, eax
jnz loc_462C2
mov rdx, [rsp+58h+var_48]
inc rdx
movsxd rax, dword ptr [r12]
add r13, 0Ch
mov [rsp+58h+var_48], rdx
cmp rdx, rax
jl short loc_465B5
jmp loc_46392
|
unsigned long long JS_ReadModule(
long long *a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
double a6,
double a7,
__m128 a8,
__m128 a9)
{
long long v9; // rbx
long long v10; // r14
long long v11; // rax
unsigned long long v12; // rcx
_DWORD *v14; // rax
long long v15; // rdx
int v16; // ecx
unsigned long long v17; // r8
int *v18; // r12
long long v19; // rdx
int v20; // ecx
unsigned long long v21; // r8
long long v22; // rsi
int *v23; // r12
long long v24; // rdx
long long v25; // rcx
unsigned long long v26; // r8
long long v27; // rsi
int *v28; // r12
long long v29; // rdx
int v30; // ecx
unsigned long long v31; // r8
long long v32; // rsi
int *v33; // r12
long long v34; // rdx
long long v35; // rcx
unsigned long long v36; // r8
int v37; // r9d
long long v38; // rax
long long v39; // rdx
long long v40; // rcx
long long v41; // r8
long long v42; // r9
__m128 v43; // xmm4
__m128 v44; // xmm5
long long v45; // rdx
long long v46; // rax
long long v47; // r13
long long v48; // rbp
long long v49; // rax
int v50; // r9d
long long v51; // r13
long long v52; // rbp
long long v53; // rdx
int v54; // ecx
unsigned long long v55; // r8
_DWORD *v56; // rsi
int v57; // r13d
int leb128; // eax
long long v59; // r13
long long v60; // rax
long long v61; // r13
long long v62; // rbp
long long v63; // rax
long long v64; // r13
long long v65; // rbp
long long v66; // rdx
int v67; // ecx
unsigned long long v68; // r8
long long v69; // rax
unsigned __int8 v70; // [rsp+Fh] [rbp-49h] BYREF
long long v71; // [rsp+10h] [rbp-48h]
unsigned int v72; // [rsp+1Ch] [rbp-3Ch] BYREF
long long v73; // [rsp+20h] [rbp-38h]
v9 = *a1;
if ( (unsigned int)bc_get_atom(a1, &v72) || (v14 = (_DWORD *)js_new_module_def(v9, v72)) == 0LL )
{
v10 = 0LL;
}
else
{
v10 = (long long)v14;
++*v14;
v18 = v14 + 8;
if ( !(unsigned int)bc_get_leb128((long long)a1, v14 + 8, v15, v16, v17) )
{
++*(_DWORD *)v10;
v22 = *(int *)(v10 + 32);
if ( *(_DWORD *)(v10 + 32) )
{
*(_DWORD *)(v10 + 36) = v22;
v46 = js_mallocz(v9, 16 * v22);
*(_QWORD *)(v10 + 24) = v46;
if ( !v46 )
goto LABEL_3;
if ( *v18 > 0 )
{
v47 = 0LL;
v48 = 0LL;
while ( !(unsigned int)bc_get_atom(a1, v47 + *(_QWORD *)(v10 + 24)) )
{
++v48;
v47 += 16LL;
if ( v48 >= *v18 )
goto LABEL_10;
}
goto LABEL_3;
}
}
LABEL_10:
v23 = (int *)(v10 + 48);
if ( !(unsigned int)bc_get_leb128((long long)a1, (_DWORD *)(v10 + 48), v19, v20, v21) )
{
v27 = *v23;
if ( *v23 )
{
*(_DWORD *)(v10 + 52) = v27;
v49 = js_mallocz(v9, 32 * v27);
*(_QWORD *)(v10 + 40) = v49;
if ( !v49 )
goto LABEL_3;
if ( *v23 > 0 )
{
v51 = 24LL;
v25 = 0LL;
do
{
v71 = v25;
v52 = *(_QWORD *)(v10 + 40);
if ( (unsigned int)bc_get_u8((long long)a1, &v70, v24, v25, v26, v50) )
goto LABEL_3;
v73 = v51;
v56 = (_DWORD *)(v52 + v51 - 24);
v57 = v70;
v56[4] = v70;
leb128 = bc_get_leb128((long long)a1, v56, v53, v54, v55);
if ( v57 )
{
if ( leb128 )
goto LABEL_3;
v59 = v73;
if ( (unsigned int)bc_get_atom(a1, v52 + v73 - 4) )
goto LABEL_3;
}
else
{
v59 = v73;
if ( leb128 )
goto LABEL_3;
}
if ( (unsigned int)bc_get_atom(a1, v59 + v52) )
goto LABEL_3;
v25 = v71 + 1;
v51 = v59 + 32;
}
while ( v71 + 1 < *v23 );
}
}
v28 = (int *)(v10 + 64);
if ( !(unsigned int)bc_get_leb128((long long)a1, (_DWORD *)(v10 + 64), v24, v25, v26) )
{
v32 = *v28;
if ( *v28 )
{
*(_DWORD *)(v10 + 68) = v32;
v60 = js_mallocz(v9, 4 * v32);
*(_QWORD *)(v10 + 56) = v60;
if ( !v60 )
goto LABEL_3;
if ( *v28 > 0 )
{
v61 = 0LL;
v62 = 0LL;
while ( !(unsigned int)bc_get_leb128((long long)a1, (_DWORD *)(v61 + *(_QWORD *)(v10 + 56)), v29, v30, v31) )
{
++v62;
v61 += 4LL;
if ( v62 >= *v28 )
goto LABEL_14;
}
goto LABEL_3;
}
}
LABEL_14:
v33 = (int *)(v10 + 80);
if ( !(unsigned int)bc_get_leb128((long long)a1, (_DWORD *)(v10 + 80), v29, v30, v31) )
{
v38 = *v33;
if ( *v33 )
{
*(_DWORD *)(v10 + 84) = v38;
v63 = js_mallocz(v9, 12 * v38);
*(_QWORD *)(v10 + 72) = v63;
if ( !v63 )
goto LABEL_3;
if ( *v33 > 0 )
{
v64 = 0LL;
v71 = 0LL;
do
{
v65 = *(_QWORD *)(v10 + 72);
if ( (unsigned int)bc_get_leb128((long long)a1, (_DWORD *)(v64 + v65), v34, v35, v36)
|| (unsigned int)bc_get_atom(a1, v65 + v64 + 4)
|| (unsigned int)bc_get_leb128((long long)a1, (_DWORD *)(v65 + v64 + 8), v66, v67, v68) )
{
goto LABEL_3;
}
v34 = v71 + 1;
v69 = *v33;
v64 += 12LL;
v71 = v34;
}
while ( v34 < v69 );
}
}
if ( !(unsigned int)bc_get_u8((long long)a1, &v70, v34, v35, v36, v37) )
{
*(_BYTE *)(v10 + 128) = v70 != 0;
*(_QWORD *)(v10 + 104) = JS_ReadObjectRec(
(long long)a1,
a2,
a3,
a4,
a5,
v43,
v44,
a8,
a9,
(long long)&v70,
v39,
v40,
v41,
v42);
*(_QWORD *)(v10 + 112) = v45;
if ( (_DWORD)v45 != 6 )
{
v12 = v10 & 0xFFFFFFFF00000000LL;
v11 = (unsigned int)v10;
return v12 | v11;
}
}
}
}
}
}
}
LABEL_3:
if ( v10 )
js_free_module_def(v9, v10);
v11 = 0LL;
v12 = 0LL;
return v12 | v11;
}
|
JS_ReadModule:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R15,RDI
MOV RBX,qword ptr [RDI]
LEA RSI,[RSP + 0x1c]
CALL 0x00146eb6
TEST EAX,EAX
JZ 0x001462f1
LAB_001462bf:
XOR R14D,R14D
LAB_001462c2:
MOV R15D,0x6
TEST R14,R14
JZ 0x001462d8
MOV RDI,RBX
MOV RSI,R14
CALL 0x0013b6a0
LAB_001462d8:
XOR EAX,EAX
XOR ECX,ECX
LAB_001462dc:
OR RAX,RCX
MOV RDX,R15
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001462f1:
MOV ESI,dword ptr [RSP + 0x1c]
MOV RDI,RBX
CALL 0x0010ff78
TEST RAX,RAX
JZ 0x001462bf
MOV R14,RAX
INC dword ptr [RAX]
LEA R12,[RAX + 0x20]
MOV RDI,R15
MOV RSI,R12
CALL 0x00145a75
TEST EAX,EAX
JNZ 0x001462c2
INC dword ptr [R14]
MOVSXD RSI,dword ptr [R14 + 0x20]
TEST RSI,RSI
JNZ 0x001463ec
LAB_0014632a:
LEA R12,[R14 + 0x30]
MOV RDI,R15
MOV RSI,R12
CALL 0x00145a75
TEST EAX,EAX
JNZ 0x001462c2
MOVSXD RSI,dword ptr [R12]
TEST RSI,RSI
JNZ 0x00146445
LAB_0014634a:
LEA R12,[R14 + 0x40]
MOV RDI,R15
MOV RSI,R12
CALL 0x00145a75
TEST EAX,EAX
JNZ 0x001462c2
MOVSXD RSI,dword ptr [R12]
TEST RSI,RSI
JNZ 0x00146524
LAB_0014636e:
LEA R12,[R14 + 0x50]
MOV RDI,R15
MOV RSI,R12
CALL 0x00145a75
TEST EAX,EAX
JNZ 0x001462c2
MOVSXD RAX,dword ptr [R12]
TEST RAX,RAX
JNZ 0x0014657d
LAB_00146392:
LEA RSI,[RSP + 0xf]
MOV RDI,R15
CALL 0x00145a3d
TEST EAX,EAX
JNZ 0x001462c2
CMP byte ptr [RSP + 0xf],0x0
SETNZ byte ptr [R14 + 0x80]
MOV RDI,R15
CALL 0x00132909
MOV qword ptr [R14 + 0x68],RAX
MOV qword ptr [R14 + 0x70],RDX
CMP EDX,0x6
JZ 0x001462c2
MOV RAX,-0x100000000
MOV RCX,R14
AND RCX,RAX
MOV EAX,R14D
MOV R15,-0x3
JMP 0x001462dc
LAB_001463ec:
MOV dword ptr [R14 + 0x24],ESI
SHL RSI,0x4
MOV RDI,RBX
CALL 0x0010ee06
MOV qword ptr [R14 + 0x18],RAX
TEST RAX,RAX
JZ 0x001462c2
CMP dword ptr [R12],0x0
JLE 0x0014632a
XOR R13D,R13D
XOR EBP,EBP
LAB_00146419:
MOV RSI,qword ptr [R14 + 0x18]
ADD RSI,R13
MOV RDI,R15
CALL 0x00146eb6
TEST EAX,EAX
JNZ 0x001462c2
INC RBP
MOVSXD RAX,dword ptr [R12]
ADD R13,0x10
CMP RBP,RAX
JL 0x00146419
JMP 0x0014632a
LAB_00146445:
MOV dword ptr [R14 + 0x34],ESI
SHL RSI,0x5
MOV RDI,RBX
CALL 0x0010ee06
MOV qword ptr [R14 + 0x28],RAX
TEST RAX,RAX
JZ 0x001462c2
CMP dword ptr [R12],0x0
JLE 0x0014634a
MOV R13D,0x18
XOR ECX,ECX
LAB_00146475:
MOV qword ptr [RSP + 0x10],RCX
MOV RBP,qword ptr [R14 + 0x28]
MOV RDI,R15
LEA RSI,[RSP + 0xf]
CALL 0x00145a3d
TEST EAX,EAX
JNZ 0x001462c2
MOV qword ptr [RSP + 0x20],R13
LEA RSI,[-0x18 + R13*0x1]
ADD RSI,RBP
MOVZX R13D,byte ptr [RSP + 0xf]
MOV dword ptr [RSI + 0x10],R13D
MOV RDI,R15
CALL 0x00145a75
TEST R13D,R13D
JZ 0x001464e3
TEST EAX,EAX
JNZ 0x001462c2
MOV R13,qword ptr [RSP + 0x20]
LEA RSI,[-0x4 + R13*0x1]
ADD RSI,RBP
MOV RDI,R15
CALL 0x00146eb6
TEST EAX,EAX
JZ 0x001464f0
JMP 0x001462c2
LAB_001464e3:
TEST EAX,EAX
MOV R13,qword ptr [RSP + 0x20]
JNZ 0x001462c2
LAB_001464f0:
ADD RBP,R13
MOV RDI,R15
MOV RSI,RBP
CALL 0x00146eb6
TEST EAX,EAX
MOV RCX,qword ptr [RSP + 0x10]
JNZ 0x001462c2
INC RCX
MOVSXD RAX,dword ptr [R12]
ADD R13,0x20
CMP RCX,RAX
JL 0x00146475
JMP 0x0014634a
LAB_00146524:
MOV dword ptr [R14 + 0x44],ESI
SHL RSI,0x2
MOV RDI,RBX
CALL 0x0010ee06
MOV qword ptr [R14 + 0x38],RAX
TEST RAX,RAX
JZ 0x001462c2
CMP dword ptr [R12],0x0
JLE 0x0014636e
XOR R13D,R13D
XOR EBP,EBP
LAB_00146551:
MOV RSI,qword ptr [R14 + 0x38]
ADD RSI,R13
MOV RDI,R15
CALL 0x00145a75
TEST EAX,EAX
JNZ 0x001462c2
INC RBP
MOVSXD RAX,dword ptr [R12]
ADD R13,0x4
CMP RBP,RAX
JL 0x00146551
JMP 0x0014636e
LAB_0014657d:
MOV dword ptr [R14 + 0x54],EAX
SHL RAX,0x2
LEA RSI,[RAX + RAX*0x2]
MOV RDI,RBX
CALL 0x0010ee06
MOV qword ptr [R14 + 0x48],RAX
TEST RAX,RAX
JZ 0x001462c2
CMP dword ptr [R12],0x0
JLE 0x00146392
XOR R13D,R13D
MOV qword ptr [RSP + 0x10],0x0
LAB_001465b5:
MOV RBP,qword ptr [R14 + 0x48]
MOV RSI,RBP
ADD RSI,R13
MOV RDI,R15
CALL 0x00145a75
TEST EAX,EAX
JNZ 0x001462c2
LEA RSI,[0x4 + R13*0x1]
ADD RSI,RBP
MOV RDI,R15
CALL 0x00146eb6
TEST EAX,EAX
JNZ 0x001462c2
LEA RSI,[0x8 + R13*0x1]
ADD RSI,RBP
MOV RDI,R15
CALL 0x00145a75
TEST EAX,EAX
JNZ 0x001462c2
MOV RDX,qword ptr [RSP + 0x10]
INC RDX
MOVSXD RAX,dword ptr [R12]
ADD R13,0xc
MOV qword ptr [RSP + 0x10],RDX
CMP RDX,RAX
JL 0x001465b5
JMP 0x00146392
|
int1 [16] JS_ReadModule(int8 *param_1)
{
int *piVar1;
int8 uVar2;
long lVar3;
int iVar4;
ulong uVar5;
int *piVar6;
long lVar7;
ulong uVar8;
uint uVar9;
long lVar10;
int8 uVar11;
int1 auVar12 [16];
byte local_49;
long local_48;
int4 local_3c;
long local_38;
uVar2 = *param_1;
iVar4 = bc_get_atom(param_1,&local_3c);
if ((iVar4 == 0) && (piVar6 = (int *)js_new_module_def(uVar2,local_3c), piVar6 != (int *)0x0)) {
*piVar6 = *piVar6 + 1;
piVar1 = piVar6 + 8;
iVar4 = bc_get_leb128(param_1,piVar1);
if (iVar4 == 0) {
*piVar6 = *piVar6 + 1;
iVar4 = piVar6[8];
if ((long)iVar4 != 0) {
piVar6[9] = iVar4;
lVar7 = js_mallocz(uVar2,(long)iVar4 << 4);
*(long *)(piVar6 + 6) = lVar7;
if (lVar7 == 0) goto LAB_001462c2;
if (0 < *piVar1) {
lVar10 = 0;
lVar7 = 0;
do {
iVar4 = bc_get_atom(param_1,*(long *)(piVar6 + 6) + lVar10);
if (iVar4 != 0) goto LAB_001462c2;
lVar7 = lVar7 + 1;
lVar10 = lVar10 + 0x10;
} while (lVar7 < *piVar1);
}
}
piVar1 = piVar6 + 0xc;
iVar4 = bc_get_leb128(param_1,piVar1);
if (iVar4 == 0) {
iVar4 = *piVar1;
if ((long)iVar4 != 0) {
piVar6[0xd] = iVar4;
lVar7 = js_mallocz(uVar2,(long)iVar4 << 5);
*(long *)(piVar6 + 10) = lVar7;
if (lVar7 == 0) goto LAB_001462c2;
if (0 < *piVar1) {
lVar7 = 0x18;
lVar10 = 0;
do {
lVar3 = *(long *)(piVar6 + 10);
local_48 = lVar10;
iVar4 = bc_get_u8(param_1,&local_49);
if (iVar4 != 0) goto LAB_001462c2;
uVar9 = (uint)local_49;
*(uint *)(lVar7 + lVar3 + -8) = uVar9;
local_38 = lVar7;
iVar4 = bc_get_leb128(param_1);
lVar7 = local_38;
if (uVar9 != 0) {
if (iVar4 != 0) goto LAB_001462c2;
iVar4 = bc_get_atom(param_1,local_38 + -4 + lVar3);
}
if ((iVar4 != 0) || (iVar4 = bc_get_atom(param_1,lVar3 + lVar7), iVar4 != 0))
goto LAB_001462c2;
lVar10 = local_48 + 1;
lVar7 = lVar7 + 0x20;
} while (lVar10 < *piVar1);
}
}
piVar1 = piVar6 + 0x10;
iVar4 = bc_get_leb128(param_1,piVar1);
if (iVar4 == 0) {
iVar4 = *piVar1;
if ((long)iVar4 != 0) {
piVar6[0x11] = iVar4;
lVar7 = js_mallocz(uVar2,(long)iVar4 << 2);
*(long *)(piVar6 + 0xe) = lVar7;
if (lVar7 == 0) goto LAB_001462c2;
if (0 < *piVar1) {
lVar10 = 0;
lVar7 = 0;
do {
iVar4 = bc_get_leb128(param_1,*(long *)(piVar6 + 0xe) + lVar10);
if (iVar4 != 0) goto LAB_001462c2;
lVar7 = lVar7 + 1;
lVar10 = lVar10 + 4;
} while (lVar7 < *piVar1);
}
}
piVar1 = piVar6 + 0x14;
iVar4 = bc_get_leb128(param_1,piVar1);
if (iVar4 == 0) {
iVar4 = *piVar1;
if ((long)iVar4 != 0) {
piVar6[0x15] = iVar4;
lVar7 = js_mallocz(uVar2,(long)iVar4 * 0xc);
*(long *)(piVar6 + 0x12) = lVar7;
if (lVar7 == 0) goto LAB_001462c2;
if (0 < *piVar1) {
lVar7 = 0;
local_48 = 0;
do {
lVar10 = *(long *)(piVar6 + 0x12);
iVar4 = bc_get_leb128(param_1,lVar10 + lVar7);
if (((iVar4 != 0) || (iVar4 = bc_get_atom(param_1,lVar7 + 4 + lVar10), iVar4 != 0)
) || (iVar4 = bc_get_leb128(param_1,lVar7 + 8 + lVar10), iVar4 != 0))
goto LAB_001462c2;
local_48 = local_48 + 1;
lVar7 = lVar7 + 0xc;
} while (local_48 < *piVar1);
}
}
iVar4 = bc_get_u8(param_1,&local_49);
if (iVar4 == 0) {
*(bool *)(piVar6 + 0x20) = local_49 != 0;
auVar12 = JS_ReadObjectRec(param_1);
*(int1 (*) [16])(piVar6 + 0x1a) = auVar12;
if (auVar12._8_4_ != 6) {
uVar8 = (ulong)piVar6 & 0xffffffff00000000;
uVar5 = (ulong)piVar6 & 0xffffffff;
uVar11 = 0xfffffffffffffffd;
goto LAB_001462dc;
}
}
}
}
}
}
}
else {
piVar6 = (int *)0x0;
}
LAB_001462c2:
uVar11 = 6;
if (piVar6 != (int *)0x0) {
js_free_module_def(uVar2,piVar6);
}
uVar5 = 0;
uVar8 = 0;
LAB_001462dc:
auVar12._0_8_ = uVar5 | uVar8;
auVar12._8_8_ = uVar11;
return auVar12;
}
|
|
9,911 |
wqueue_release_queue
|
eloqsql/mysys/wqueue.c
|
void wqueue_release_queue(WQUEUE *wqueue)
{
struct st_my_thread_var *last= wqueue->last_thread;
struct st_my_thread_var *next= last->next;
struct st_my_thread_var *thread;
do
{
thread= next;
mysql_cond_signal(&thread->suspend);
next= thread->next;
thread->next= NULL;
}
while (thread != last);
wqueue->last_thread= NULL;
}
|
O0
|
c
|
wqueue_release_queue:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x88(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
addq $0x8, %rdi
callq 0xca570
movq -0x20(%rbp), %rax
movq 0x88(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x20(%rbp), %rax
movq $0x0, 0x88(%rax)
movq -0x20(%rbp), %rax
cmpq -0x10(%rbp), %rax
jne 0xca516
movq -0x8(%rbp), %rax
movq $0x0, (%rax)
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
wqueue_release_queue:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_10], rax
mov rax, [rbp+var_10]
mov rax, [rax+88h]
mov [rbp+var_18], rax
loc_CA516:
mov rax, [rbp+var_18]
mov [rbp+var_20], rax
mov rdi, [rbp+var_20]
add rdi, 8
call inline_mysql_cond_signal_4
mov rax, [rbp+var_20]
mov rax, [rax+88h]
mov [rbp+var_18], rax
mov rax, [rbp+var_20]
mov qword ptr [rax+88h], 0
mov rax, [rbp+var_20]
cmp rax, [rbp+var_10]
jnz short loc_CA516
mov rax, [rbp+var_8]
mov qword ptr [rax], 0
add rsp, 20h
pop rbp
retn
|
long long * wqueue_release_queue(long long *a1)
{
long long *result; // rax
long long v2; // [rsp+0h] [rbp-20h]
long long v3; // [rsp+8h] [rbp-18h]
long long v4; // [rsp+10h] [rbp-10h]
v4 = *a1;
v3 = *(_QWORD *)(*a1 + 136);
do
{
v2 = v3;
inline_mysql_cond_signal_4(v3 + 8);
v3 = *(_QWORD *)(v3 + 136);
*(_QWORD *)(v2 + 136) = 0LL;
}
while ( v2 != v4 );
result = a1;
*a1 = 0LL;
return result;
}
|
wqueue_release_queue:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x88]
MOV qword ptr [RBP + -0x18],RAX
LAB_001ca516:
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x20],RAX
MOV RDI,qword ptr [RBP + -0x20]
ADD RDI,0x8
CALL 0x001ca570
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x88]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX + 0x88],0x0
MOV RAX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RBP + -0x10]
JNZ 0x001ca516
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX],0x0
ADD RSP,0x20
POP RBP
RET
|
void wqueue_release_queue(long *param_1)
{
long lVar1;
long lVar2;
bool bVar3;
int8 local_20;
lVar1 = *param_1;
local_20 = *(long *)(lVar1 + 0x88);
do {
inline_mysql_cond_signal(local_20 + 8);
lVar2 = *(long *)(local_20 + 0x88);
*(int8 *)(local_20 + 0x88) = 0;
bVar3 = local_20 != lVar1;
local_20 = lVar2;
} while (bVar3);
*param_1 = 0;
return;
}
|
|
9,912 |
js_arguments_define_own_property
|
bluesky950520[P]quickjs/quickjs.c
|
static int js_arguments_define_own_property(JSContext *ctx,
JSValue this_obj,
JSAtom prop, JSValue val,
JSValue getter, JSValue setter, int flags)
{
JSObject *p;
uint32_t idx;
p = JS_VALUE_GET_OBJ(this_obj);
/* convert to normal array when redefining an existing numeric field */
if (p->fast_array && JS_AtomIsArrayIndex(ctx, &idx, prop) &&
idx < p->u.array.count) {
if (convert_fast_array_to_array(ctx, p))
return -1;
}
/* run the default define own property */
return JS_DefineProperty(ctx, this_obj, prop, val, getter, setter,
flags | JS_PROP_NO_EXOTIC);
}
|
O1
|
c
|
js_arguments_define_own_property:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %r9, %rbx
movq %r8, %r14
movl %ecx, %ebp
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r13
testb $0x8, 0x5(%rsi)
je 0x3eeb1
leaq 0x34(%rsp), %rsi
movq %r13, %rdi
movl %ebp, %edx
callq 0x3d7ed
testl %eax, %eax
je 0x3eeb1
movl 0x34(%rsp), %eax
cmpl 0x40(%r12), %eax
jae 0x3eeb1
movq %r13, %rdi
movq %r12, %rsi
callq 0x267b0
testl %eax, %eax
je 0x3eeb1
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
jmp 0x3eef3
movl 0x90(%rsp), %eax
leaq 0x80(%rsp), %rcx
leaq 0x70(%rsp), %rdx
orl $0x20000, %eax # imm = 0x20000
movups (%rcx), %xmm0
movups %xmm0, 0x10(%rsp)
movups (%rdx), %xmm0
movups %xmm0, (%rsp)
movl %eax, 0x20(%rsp)
movq %r13, %rdi
movq %r12, %rsi
movq %r15, %rdx
movl %ebp, %ecx
movq %r14, %r8
movq %rbx, %r9
callq 0x254b9
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
js_arguments_define_own_property:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov rbx, r9
mov r14, r8
mov ebp, ecx
mov r15, rdx
mov r12, rsi
mov r13, rdi
test byte ptr [rsi+5], 8
jz short loc_3EEB1
lea rsi, [rsp+68h+var_34]
mov rdi, r13
mov edx, ebp
call JS_AtomIsArrayIndex
test eax, eax
jz short loc_3EEB1
mov eax, [rsp+68h+var_34]
cmp eax, [r12+40h]
jnb short loc_3EEB1
mov rdi, r13
mov rsi, r12
call convert_fast_array_to_array
test eax, eax
jz short loc_3EEB1
mov eax, 0FFFFFFFFh
jmp short loc_3EEF3
loc_3EEB1:
mov eax, [rsp+68h+arg_20]
lea rcx, [rsp+68h+arg_10]
lea rdx, [rsp+68h+arg_0]
or eax, 20000h
movups xmm0, xmmword ptr [rcx]
movups [rsp+68h+var_58], xmm0
movups xmm0, xmmword ptr [rdx]
movups [rsp+68h+var_68], xmm0
mov [rsp+68h+var_48], eax
mov rdi, r13
mov rsi, r12
mov rdx, r15
mov ecx, ebp
mov r8, r14
mov r9, rbx
call JS_DefineProperty
loc_3EEF3:
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long js_arguments_define_own_property(
long long a1,
unsigned long long a2,
long long a3,
unsigned int a4,
long long a5,
long long a6,
double a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14,
__m128 a15,
_DWORD *a16,
long long a17,
int a18)
{
_DWORD v23[13]; // [rsp+34h] [rbp-34h] BYREF
if ( (*(_BYTE *)(a2 + 5) & 8) != 0
&& (unsigned int)JS_AtomIsArrayIndex(a1, v23, a4)
&& v23[0] < *(_DWORD *)(a2 + 64)
&& (unsigned int)convert_fast_array_to_array(a1, a2) )
{
return 0xFFFFFFFFLL;
}
else
{
return JS_DefineProperty(
a1,
a2,
a3,
a4,
a5,
a6,
a15,
a8,
a9,
a10,
a11,
a12,
a13,
a14,
a15.m128_u64[0],
a15.m128_i64[1],
a16,
a17,
a18 | 0x20000u);
}
}
|
js_arguments_define_own_property:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV RBX,R9
MOV R14,R8
MOV EBP,ECX
MOV R15,RDX
MOV R12,RSI
MOV R13,RDI
TEST byte ptr [RSI + 0x5],0x8
JZ 0x0013eeb1
LEA RSI,[RSP + 0x34]
MOV RDI,R13
MOV EDX,EBP
CALL 0x0013d7ed
TEST EAX,EAX
JZ 0x0013eeb1
MOV EAX,dword ptr [RSP + 0x34]
CMP EAX,dword ptr [R12 + 0x40]
JNC 0x0013eeb1
MOV RDI,R13
MOV RSI,R12
CALL 0x001267b0
TEST EAX,EAX
JZ 0x0013eeb1
MOV EAX,0xffffffff
JMP 0x0013eef3
LAB_0013eeb1:
MOV EAX,dword ptr [RSP + 0x90]
LEA RCX,[RSP + 0x80]
LEA RDX,[RSP + 0x70]
OR EAX,0x20000
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [RSP + 0x10],XMM0
MOVUPS XMM0,xmmword ptr [RDX]
MOVUPS xmmword ptr [RSP],XMM0
MOV dword ptr [RSP + 0x20],EAX
MOV RDI,R13
MOV RSI,R12
MOV RDX,R15
MOV ECX,EBP
MOV R8,R14
MOV R9,RBX
CALL 0x001254b9
LAB_0013eef3:
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8
js_arguments_define_own_property
(int8 param_1,long param_2,int8 param_3,int4 param_4,int8 param_5,
int8 param_6,int4 param_7,int4 param_8,int8 param_9,
int8 param_10,uint param_11)
{
int iVar1;
int8 uVar2;
uint local_34;
if (((((*(byte *)(param_2 + 5) & 8) != 0) &&
(iVar1 = JS_AtomIsArrayIndex(param_1,&local_34,param_4), iVar1 != 0)) &&
(local_34 < *(uint *)(param_2 + 0x40))) &&
(iVar1 = convert_fast_array_to_array(param_1,param_2), iVar1 != 0)) {
return 0xffffffff;
}
uVar2 = JS_DefineProperty(param_1,param_2,param_3,param_4,param_5,param_6,param_7,param_8,param_9,
param_10,param_11 | 0x20000);
return uVar2;
}
|
|
9,913 |
js_arguments_define_own_property
|
bluesky950520[P]quickjs/quickjs.c
|
static int js_arguments_define_own_property(JSContext *ctx,
JSValue this_obj,
JSAtom prop, JSValue val,
JSValue getter, JSValue setter, int flags)
{
JSObject *p;
uint32_t idx;
p = JS_VALUE_GET_OBJ(this_obj);
/* convert to normal array when redefining an existing numeric field */
if (p->fast_array && JS_AtomIsArrayIndex(ctx, &idx, prop) &&
idx < p->u.array.count) {
if (convert_fast_array_to_array(ctx, p))
return -1;
}
/* run the default define own property */
return JS_DefineProperty(ctx, this_obj, prop, val, getter, setter,
flags | JS_PROP_NO_EXOTIC);
}
|
O2
|
c
|
js_arguments_define_own_property:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %r9, %rbx
movq %r8, %r14
movl %ecx, %ebp
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r13
testb $0x8, 0x5(%rsi)
je 0x37321
leaq 0x34(%rsp), %rsi
movq %r13, %rdi
movl %ebp, %edx
callq 0x36088
testl %eax, %eax
je 0x37321
movl 0x34(%rsp), %eax
cmpl 0x40(%r12), %eax
jae 0x37321
movq %r13, %rdi
movq %r12, %rsi
callq 0x20237
testl %eax, %eax
je 0x37321
pushq $-0x1
popq %rax
jmp 0x37363
movl 0x90(%rsp), %eax
leaq 0x80(%rsp), %rcx
leaq 0x70(%rsp), %rdx
orl $0x20000, %eax # imm = 0x20000
movups (%rcx), %xmm0
movups %xmm0, 0x10(%rsp)
movups (%rdx), %xmm0
movups %xmm0, (%rsp)
movl %eax, 0x20(%rsp)
movq %r13, %rdi
movq %r12, %rsi
movq %r15, %rdx
movl %ebp, %ecx
movq %r14, %r8
movq %rbx, %r9
callq 0x1f1de
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
js_arguments_define_own_property:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
mov rbx, r9
mov r14, r8
mov ebp, ecx
mov r15, rdx
mov r12, rsi
mov r13, rdi
test byte ptr [rsi+5], 8
jz short loc_37321
lea rsi, [rsp+68h+var_34]
mov rdi, r13
mov edx, ebp
call JS_AtomIsArrayIndex
test eax, eax
jz short loc_37321
mov eax, [rsp+68h+var_34]
cmp eax, [r12+40h]
jnb short loc_37321
mov rdi, r13
mov rsi, r12
call convert_fast_array_to_array
test eax, eax
jz short loc_37321
push 0FFFFFFFFFFFFFFFFh
pop rax
jmp short loc_37363
loc_37321:
mov eax, [rsp+68h+arg_20]
lea rcx, [rsp+68h+arg_10]
lea rdx, [rsp+68h+arg_0]
or eax, 20000h
movups xmm0, xmmword ptr [rcx]
movups [rsp+68h+var_58], xmm0
movups xmm0, xmmword ptr [rdx]
movups [rsp+68h+var_68], xmm0
mov [rsp+68h+var_48], eax
mov rdi, r13
mov rsi, r12
mov rdx, r15
mov ecx, ebp
mov r8, r14
mov r9, rbx
call JS_DefineProperty
loc_37363:
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long js_arguments_define_own_property(
long long a1,
long long a2,
long long a3,
unsigned int a4,
_DWORD *a5,
long long a6,
double a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14,
__m128 a15,
_DWORD *a16,
unsigned int a17,
int a18)
{
unsigned int v23[13]; // [rsp+34h] [rbp-34h] BYREF
if ( (*(_BYTE *)(a2 + 5) & 8) != 0
&& (unsigned int)JS_AtomIsArrayIndex(a1, (int *)v23, a4)
&& v23[0] < *(_DWORD *)(a2 + 64)
&& (unsigned int)convert_fast_array_to_array(a1, a2) )
{
return -1LL;
}
else
{
return JS_DefineProperty(
a1,
a2,
a3,
a4,
a5,
a6,
a15,
a8,
a9,
a10,
a11,
a12,
a13,
a14,
a15.m128_u64[0],
a15.m128_u32[2],
a16,
a17,
a18 | 0x20000u);
}
}
|
js_arguments_define_own_property:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOV RBX,R9
MOV R14,R8
MOV EBP,ECX
MOV R15,RDX
MOV R12,RSI
MOV R13,RDI
TEST byte ptr [RSI + 0x5],0x8
JZ 0x00137321
LEA RSI,[RSP + 0x34]
MOV RDI,R13
MOV EDX,EBP
CALL 0x00136088
TEST EAX,EAX
JZ 0x00137321
MOV EAX,dword ptr [RSP + 0x34]
CMP EAX,dword ptr [R12 + 0x40]
JNC 0x00137321
MOV RDI,R13
MOV RSI,R12
CALL 0x00120237
TEST EAX,EAX
JZ 0x00137321
PUSH -0x1
POP RAX
JMP 0x00137363
LAB_00137321:
MOV EAX,dword ptr [RSP + 0x90]
LEA RCX,[RSP + 0x80]
LEA RDX,[RSP + 0x70]
OR EAX,0x20000
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [RSP + 0x10],XMM0
MOVUPS XMM0,xmmword ptr [RDX]
MOVUPS xmmword ptr [RSP],XMM0
MOV dword ptr [RSP + 0x20],EAX
MOV RDI,R13
MOV RSI,R12
MOV RDX,R15
MOV ECX,EBP
MOV R8,R14
MOV R9,RBX
CALL 0x0011f1de
LAB_00137363:
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8
js_arguments_define_own_property
(int8 param_1,long param_2,int8 param_3,int4 param_4,int8 param_5,
int8 param_6,int4 param_7,int4 param_8,int8 param_9,
int8 param_10,uint param_11)
{
int iVar1;
int8 uVar2;
uint local_34;
if (((((*(byte *)(param_2 + 5) & 8) != 0) &&
(iVar1 = JS_AtomIsArrayIndex(param_1,&local_34,param_4), iVar1 != 0)) &&
(local_34 < *(uint *)(param_2 + 0x40))) &&
(iVar1 = convert_fast_array_to_array(param_1,param_2), iVar1 != 0)) {
return 0xffffffffffffffff;
}
uVar2 = JS_DefineProperty(param_1,param_2,param_3,param_4,param_5,param_6,param_7,param_8,param_9,
param_10,param_11 | 0x20000);
return uVar2;
}
|
|
9,914 |
testing::internal::GetCurrentExecutableName()
|
AlayaLite/build_O0/_deps/googletest-src/googletest/src/gtest.cc
|
FilePath GetCurrentExecutableName() {
FilePath result;
auto args = GetArgvs();
if (!args.empty()) {
#if defined(GTEST_OS_WINDOWS) || defined(GTEST_OS_OS2)
result.Set(FilePath(args[0]).RemoveExtension("exe"));
#else
result.Set(FilePath(args[0]));
#endif // GTEST_OS_WINDOWS
}
return result.RemoveDirectoryName();
}
|
O0
|
cpp
|
testing::internal::GetCurrentExecutableName():
subq $0xa8, %rsp
movq %rdi, 0x8(%rsp)
movq %rdi, %rax
movq %rax, 0x10(%rsp)
movq %rdi, 0xa0(%rsp)
leaq 0x80(%rsp), %rdi
callq 0x124550
leaq 0x68(%rsp), %rdi
callq 0xfa550
jmp 0xfedb5
leaq 0x68(%rsp), %rdi
callq 0x1260b0
testb $0x1, %al
jne 0xfee76
xorl %eax, %eax
movl %eax, %esi
leaq 0x68(%rsp), %rdi
callq 0x124270
movq %rax, %rsi
leaq 0x18(%rsp), %rdi
callq 0x1fe60
jmp 0xfede4
leaq 0x38(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x1242e0
jmp 0xfedf5
leaq 0x80(%rsp), %rdi
leaq 0x38(%rsp), %rsi
callq 0x1245c0
jmp 0xfee09
leaq 0x38(%rsp), %rdi
callq 0x1243f0
leaq 0x18(%rsp), %rdi
callq 0x1c160
jmp 0xfee76
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0xfeeb8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0xfeeae
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0xfee6a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
leaq 0x38(%rsp), %rdi
callq 0x1243f0
leaq 0x18(%rsp), %rdi
callq 0x1c160
jmp 0xfeeae
movq 0x8(%rsp), %rdi
leaq 0x80(%rsp), %rsi
callq 0xf7880
jmp 0xfee8a
leaq 0x68(%rsp), %rdi
callq 0x123ed0
leaq 0x80(%rsp), %rdi
callq 0x1243f0
movq 0x10(%rsp), %rax
addq $0xa8, %rsp
retq
leaq 0x68(%rsp), %rdi
callq 0x123ed0
leaq 0x80(%rsp), %rdi
callq 0x1243f0
movq 0x60(%rsp), %rdi
callq 0x15dd0
nop
|
_ZN7testing8internal24GetCurrentExecutableNameEv:
sub rsp, 0A8h
mov [rsp+0A8h+var_A0], rdi
mov rax, rdi
mov [rsp+0A8h+var_98], rax
mov [rsp+0A8h+var_8], rdi
lea rdi, [rsp+0A8h+var_28]; this
call _ZN7testing8internal8FilePathC2Ev; testing::internal::FilePath::FilePath(void)
lea rdi, [rsp+0A8h+var_40]
call _ZN7testing8internal8GetArgvsB5cxx11Ev; testing::internal::GetArgvs(void)
jmp short $+2
loc_FEDB5:
lea rdi, [rsp+0A8h+var_40]
call _ZNKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5emptyEv; std::vector<std::string>::empty(void)
test al, 1
jnz loc_FEE76
xor eax, eax
mov esi, eax
lea rdi, [rsp+0A8h+var_40]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EEixEm; std::vector<std::string>::operator[](ulong)
mov rsi, rax
lea rdi, [rsp+0A8h+var_90]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2ERKS4_; std::string::basic_string(std::string const&)
jmp short $+2
loc_FEDE4:
lea rdi, [rsp+0A8h+var_70]
lea rsi, [rsp+0A8h+var_90]
call _ZN7testing8internal8FilePathC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; testing::internal::FilePath::FilePath(std::string)
jmp short $+2
loc_FEDF5:
lea rdi, [rsp+0A8h+var_28]; this
lea rsi, [rsp+0A8h+var_70]; testing::internal::FilePath *
call _ZN7testing8internal8FilePath3SetERKS1_; testing::internal::FilePath::Set(testing::internal::FilePath const&)
jmp short $+2
loc_FEE09:
lea rdi, [rsp+0A8h+var_70]; this
call _ZN7testing8internal8FilePathD2Ev; testing::internal::FilePath::~FilePath()
lea rdi, [rsp+0A8h+var_90]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_FEE76
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp loc_FEEB8
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_FEEAE
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_FEE6A
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
lea rdi, [rsp+arg_30]; this
call _ZN7testing8internal8FilePathD2Ev; testing::internal::FilePath::~FilePath()
loc_FEE6A:
lea rdi, [rsp+arg_10]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_FEEAE
loc_FEE76:
mov rdi, [rsp+0A8h+var_A0]; this
lea rsi, [rsp+0A8h+var_28]
call _ZNK7testing8internal8FilePath19RemoveDirectoryNameEv; testing::internal::FilePath::RemoveDirectoryName(void)
jmp short $+2
loc_FEE8A:
lea rdi, [rsp+0A8h+var_40]; void *
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
lea rdi, [rsp+0A8h+var_28]; this
call _ZN7testing8internal8FilePathD2Ev; testing::internal::FilePath::~FilePath()
mov rax, [rsp+0A8h+var_98]
add rsp, 0A8h
retn
loc_FEEAE:
lea rdi, [rsp+arg_60]; void *
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
loc_FEEB8:
lea rdi, [rsp+arg_78]; this
call _ZN7testing8internal8FilePathD2Ev; testing::internal::FilePath::~FilePath()
mov rdi, [rsp+arg_58]
call __Unwind_Resume
|
testing::internal * testing::internal::GetCurrentExecutableName(testing::internal *this)
{
long long v1; // rax
int v2; // edx
int v3; // ecx
int v4; // r8d
int v5; // r9d
_QWORD v7[4]; // [rsp+18h] [rbp-90h] BYREF
_BYTE v8[48]; // [rsp+38h] [rbp-70h] BYREF
_BYTE v9[24]; // [rsp+68h] [rbp-40h] BYREF
_BYTE v10[32]; // [rsp+80h] [rbp-28h] BYREF
testing::internal *v11; // [rsp+A0h] [rbp-8h]
v11 = this;
testing::internal::FilePath::FilePath((testing::internal::FilePath *)v10);
testing::internal::GetArgvs[abi:cxx11](v9);
if ( (std::vector<std::string>::empty(v9) & 1) == 0 )
{
v1 = std::vector<std::string>::operator[](v9, 0LL);
std::string::basic_string(v7, v1);
testing::internal::FilePath::FilePath((unsigned int)v8, (unsigned int)v7, v2, v3, v4, v5);
testing::internal::FilePath::Set((testing::internal::FilePath *)v10, (const testing::internal::FilePath *)v8);
testing::internal::FilePath::~FilePath((testing::internal::FilePath *)v8);
std::string::~string(v7);
}
testing::internal::FilePath::RemoveDirectoryName(this, (testing::internal::FilePath *)v10);
std::vector<std::string>::~vector(v9);
testing::internal::FilePath::~FilePath((testing::internal::FilePath *)v10);
return this;
}
|
GetCurrentExecutableName:
SUB RSP,0xa8
MOV qword ptr [RSP + 0x8],RDI
MOV RAX,RDI
MOV qword ptr [RSP + 0x10],RAX
MOV qword ptr [RSP + 0xa0],RDI
LEA RDI,[RSP + 0x80]
CALL 0x00224550
LAB_001feda9:
LEA RDI,[RSP + 0x68]
CALL 0x001fa550
JMP 0x001fedb5
LAB_001fedb5:
LEA RDI,[RSP + 0x68]
CALL 0x002260b0
TEST AL,0x1
JNZ 0x001fee76
XOR EAX,EAX
MOV ESI,EAX
LEA RDI,[RSP + 0x68]
CALL 0x00224270
MOV RSI,RAX
LAB_001fedd8:
LEA RDI,[RSP + 0x18]
CALL 0x0011fe60
JMP 0x001fede4
LAB_001fede4:
LEA RDI,[RSP + 0x38]
LEA RSI,[RSP + 0x18]
CALL 0x002242e0
JMP 0x001fedf5
LAB_001fedf5:
LEA RDI,[RSP + 0x80]
LEA RSI,[RSP + 0x38]
CALL 0x002245c0
JMP 0x001fee09
LAB_001fee09:
LEA RDI,[RSP + 0x38]
CALL 0x002243f0
LEA RDI,[RSP + 0x18]
CALL 0x0011c160
JMP 0x001fee76
LAB_001fee76:
MOV RDI,qword ptr [RSP + 0x8]
LEA RSI,[RSP + 0x80]
CALL 0x001f7880
LAB_001fee88:
JMP 0x001fee8a
LAB_001fee8a:
LEA RDI,[RSP + 0x68]
CALL 0x00223ed0
LEA RDI,[RSP + 0x80]
CALL 0x002243f0
MOV RAX,qword ptr [RSP + 0x10]
ADD RSP,0xa8
RET
|
/* testing::internal::GetCurrentExecutableName() */
internal * __thiscall testing::internal::GetCurrentExecutableName(internal *this)
{
ulong uVar1;
string *psVar2;
string local_90 [32];
FilePath local_70 [48];
internal local_40 [24];
FilePath local_28 [32];
internal *local_8;
local_8 = this;
FilePath::FilePath(local_28);
/* try { // try from 001feda9 to 001fedb2 has its CatchHandler @ 001fee1f */
GetArgvs_abi_cxx11_(local_40);
uVar1 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::empty
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_40);
if ((uVar1 & 1) == 0) {
psVar2 = (string *)
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::operator[]
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)
local_40,0);
/* try { // try from 001fedd8 to 001fede1 has its CatchHandler @ 001fee32 */
std::__cxx11::string::string(local_90,psVar2);
/* try { // try from 001fede4 to 001fedf2 has its CatchHandler @ 001fee42 */
FilePath::FilePath(local_70,local_90);
/* try { // try from 001fedf5 to 001fee06 has its CatchHandler @ 001fee52 */
FilePath::Set(local_28,local_70);
FilePath::~FilePath(local_70);
std::__cxx11::string::~string(local_90);
}
/* try { // try from 001fee76 to 001fee87 has its CatchHandler @ 001fee32 */
FilePath::RemoveDirectoryName();
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_40);
FilePath::~FilePath(local_28);
return this;
}
|
|
9,915 |
find_collation_data_inheritance_source
|
eloqsql/mysys/charset.c
|
static CHARSET_INFO *find_collation_data_inheritance_source(CHARSET_INFO *cs, myf flags)
{
const char *beg, *end;
if (cs->tailoring &&
!strncmp(cs->tailoring, "[import ", 8) &&
(end= strchr(cs->tailoring + 8, ']')) &&
(beg= cs->tailoring + 8) + MY_CS_NAME_SIZE > end)
{
char name[MY_CS_NAME_SIZE + 1];
memcpy(name, beg, end - beg);
name[end - beg]= '\0';
return inheritance_source_by_id(cs, get_collation_number(name,MYF(flags)));
}
return NULL;
}
|
O0
|
c
|
find_collation_data_inheritance_source:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x40(%rbp)
movq %rsi, -0x48(%rbp)
movq -0x40(%rbp), %rax
cmpq $0x0, 0x38(%rax)
je 0x37306
movq -0x40(%rbp), %rax
movq 0x38(%rax), %rdi
leaq 0x4c684(%rip), %rsi # 0x838ef
movl $0x8, %edx
callq 0x24140
cmpl $0x0, %eax
jne 0x37306
movq -0x40(%rbp), %rax
movq 0x38(%rax), %rdi
addq $0x8, %rdi
movl $0x5d, %esi
callq 0x24100
movq %rax, -0x58(%rbp)
cmpq $0x0, %rax
je 0x37306
movq -0x40(%rbp), %rax
movq 0x38(%rax), %rax
addq $0x8, %rax
movq %rax, -0x50(%rbp)
addq $0x20, %rax
cmpq -0x58(%rbp), %rax
jbe 0x37306
leaq -0x30(%rbp), %rdi
movq -0x50(%rbp), %rsi
movq -0x58(%rbp), %rdx
movq -0x50(%rbp), %rax
subq %rax, %rdx
callq 0x24200
movq -0x58(%rbp), %rax
movq -0x50(%rbp), %rcx
subq %rcx, %rax
movb $0x0, -0x30(%rbp,%rax)
movq -0x40(%rbp), %rax
movq %rax, -0x60(%rbp)
leaq -0x30(%rbp), %rdi
movq -0x48(%rbp), %rsi
callq 0x35040
movq -0x60(%rbp), %rdi
movl %eax, %esi
callq 0x37480
movq %rax, -0x38(%rbp)
jmp 0x3730e
movq $0x0, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x68(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x37332
movq -0x68(%rbp), %rax
addq $0x70, %rsp
popq %rbp
retq
callq 0x24300
nopw (%rax,%rax)
|
find_collation_data_inheritance_source:
push rbp
mov rbp, rsp
sub rsp, 70h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_40], rdi
mov [rbp+var_48], rsi
mov rax, [rbp+var_40]
cmp qword ptr [rax+38h], 0
jz loc_37306
mov rax, [rbp+var_40]
mov rdi, [rax+38h]
lea rsi, aImport; "[import "
mov edx, 8
call _strncmp
cmp eax, 0
jnz loc_37306
mov rax, [rbp+var_40]
mov rdi, [rax+38h]
add rdi, 8
mov esi, 5Dh ; ']'
call _strchr
mov [rbp+var_58], rax
cmp rax, 0
jz short loc_37306
mov rax, [rbp+var_40]
mov rax, [rax+38h]
add rax, 8
mov [rbp+var_50], rax
add rax, 20h ; ' '
cmp rax, [rbp+var_58]
jbe short loc_37306
lea rdi, [rbp+var_30]
mov rsi, [rbp+var_50]
mov rdx, [rbp+var_58]
mov rax, [rbp+var_50]
sub rdx, rax
call _memcpy
mov rax, [rbp+var_58]
mov rcx, [rbp+var_50]
sub rax, rcx
mov [rbp+rax+var_30], 0
mov rax, [rbp+var_40]
mov [rbp+var_60], rax
lea rdi, [rbp+var_30]
mov rsi, [rbp+var_48]
call get_collation_number
mov rdi, [rbp+var_60]
mov esi, eax
call inheritance_source_by_id
mov [rbp+var_38], rax
jmp short loc_3730E
loc_37306:
mov [rbp+var_38], 0
loc_3730E:
mov rax, [rbp+var_38]
mov [rbp+var_68], rax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_37332
mov rax, [rbp+var_68]
add rsp, 70h
pop rbp
retn
loc_37332:
call ___stack_chk_fail
|
long long find_collation_data_inheritance_source(long long a1, long long a2)
{
unsigned int collation_number; // eax
unsigned long long v4; // [rsp+18h] [rbp-58h]
long long v5; // [rsp+20h] [rbp-50h]
_BYTE v7[40]; // [rsp+40h] [rbp-30h] BYREF
unsigned long long v8; // [rsp+68h] [rbp-8h]
v8 = __readfsqword(0x28u);
if ( !*(_QWORD *)(a1 + 56) )
return 0LL;
if ( (unsigned int)strncmp(*(_QWORD *)(a1 + 56), "[import ", 8LL) )
return 0LL;
v4 = strchr(*(_QWORD *)(a1 + 56) + 8LL, 93LL);
if ( !v4 )
return 0LL;
v5 = *(_QWORD *)(a1 + 56) + 8LL;
if ( *(_QWORD *)(a1 + 56) + 40LL <= v4 )
return 0LL;
memcpy(v7, v5, v4 - v5);
v7[v4 - v5] = 0;
collation_number = get_collation_number((long long)v7, a2);
return inheritance_source_by_id(a1, collation_number);
}
|
find_collation_data_inheritance_source:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x70
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x40],RDI
MOV qword ptr [RBP + -0x48],RSI
MOV RAX,qword ptr [RBP + -0x40]
CMP qword ptr [RAX + 0x38],0x0
JZ 0x00137306
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [RAX + 0x38]
LEA RSI,[0x1838ef]
MOV EDX,0x8
CALL 0x00124140
CMP EAX,0x0
JNZ 0x00137306
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [RAX + 0x38]
ADD RDI,0x8
MOV ESI,0x5d
CALL 0x00124100
MOV qword ptr [RBP + -0x58],RAX
CMP RAX,0x0
JZ 0x00137306
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x38]
ADD RAX,0x8
MOV qword ptr [RBP + -0x50],RAX
ADD RAX,0x20
CMP RAX,qword ptr [RBP + -0x58]
JBE 0x00137306
LEA RDI,[RBP + -0x30]
MOV RSI,qword ptr [RBP + -0x50]
MOV RDX,qword ptr [RBP + -0x58]
MOV RAX,qword ptr [RBP + -0x50]
SUB RDX,RAX
CALL 0x00124200
MOV RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x50]
SUB RAX,RCX
MOV byte ptr [RBP + RAX*0x1 + -0x30],0x0
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RBP + -0x60],RAX
LEA RDI,[RBP + -0x30]
MOV RSI,qword ptr [RBP + -0x48]
CALL 0x00135040
MOV RDI,qword ptr [RBP + -0x60]
MOV ESI,EAX
CALL 0x00137480
MOV qword ptr [RBP + -0x38],RAX
JMP 0x0013730e
LAB_00137306:
MOV qword ptr [RBP + -0x38],0x0
LAB_0013730e:
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x00137332
MOV RAX,qword ptr [RBP + -0x68]
ADD RSP,0x70
POP RBP
RET
LAB_00137332:
CALL 0x00124300
|
int8 find_collation_data_inheritance_source(long param_1,int8 param_2)
{
int iVar1;
int4 uVar2;
char *pcVar3;
void *__src;
long in_FS_OFFSET;
int8 local_40;
char local_38 [40];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
if (*(long *)(param_1 + 0x38) != 0) {
iVar1 = strncmp(*(char **)(param_1 + 0x38),"[import ",8);
if (iVar1 == 0) {
pcVar3 = strchr((char *)(*(long *)(param_1 + 0x38) + 8),0x5d);
if ((pcVar3 != (char *)0x0) &&
(__src = (void *)(*(long *)(param_1 + 0x38) + 8),
pcVar3 < (char *)(*(long *)(param_1 + 0x38) + 0x28))) {
memcpy(local_38,__src,(long)pcVar3 - (long)__src);
pcVar3[(long)(local_38 + -(long)__src)] = '\0';
uVar2 = get_collation_number(local_38,param_2);
local_40 = inheritance_source_by_id(param_1,uVar2);
goto LAB_0013730e;
}
}
}
local_40 = 0;
LAB_0013730e:
if (*(long *)(in_FS_OFFSET + 0x28) == local_10) {
return local_40;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
|
|
9,916 |
arrowMaker[abi:cxx11](Line const&)
|
11AgReS1SoR11[P]Graph/Common/Retranslator/src/Retranslator.cpp
|
std::string arrowMaker(const Line& line)
{
if (static_cast<short>(line.type) == 0 && static_cast<short>(line.orientation) == 0)
return "--";
else if (static_cast<short>(line.type) == 0 && static_cast<short>(line.orientation) == 1)
return "-->";
else if (static_cast<short>(line.type) == 0 && static_cast<short>(line.orientation) == 2)
return "<-->";
else if (static_cast<short>(line.type) == 1 && static_cast<short>(line.orientation) == 0)
return "-";
else if (static_cast<short>(line.type) == 1 && static_cast<short>(line.orientation) == 1)
return "->";
else
return "<->";
}
|
O0
|
cpp
|
arrowMaker[abi:cxx11](Line const&):
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x40(%rbp)
movq %rdi, %rax
movq %rax, -0x38(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movswl 0xa0(%rax), %eax
cmpl $0x0, %eax
jne 0xa026
movq -0x10(%rbp), %rax
movswl 0xa2(%rax), %eax
cmpl $0x0, %eax
jne 0xa026
leaq -0x11(%rbp), %rdi
movq %rdi, -0x48(%rbp)
callq 0x5770
movq -0x40(%rbp), %rdi
movq -0x48(%rbp), %rdx
leaq 0x20e4(%rip), %rsi # 0xc0db
callq 0x5700
jmp 0x9ffe
leaq -0x11(%rbp), %rdi
callq 0x54b0
jmp 0xa211
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x11(%rbp), %rdi
callq 0x54b0
jmp 0xa21b
movq -0x10(%rbp), %rax
movswl 0xa0(%rax), %eax
cmpl $0x0, %eax
jne 0xa091
movq -0x10(%rbp), %rax
movswl 0xa2(%rax), %eax
cmpl $0x1, %eax
jne 0xa091
leaq -0x25(%rbp), %rdi
movq %rdi, -0x50(%rbp)
callq 0x5770
movq -0x40(%rbp), %rdi
movq -0x50(%rbp), %rdx
leaq 0x207d(%rip), %rsi # 0xc0df
callq 0x5700
jmp 0xa069
leaq -0x25(%rbp), %rdi
callq 0x54b0
jmp 0xa211
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x25(%rbp), %rdi
callq 0x54b0
jmp 0xa21b
movq -0x10(%rbp), %rax
movswl 0xa0(%rax), %eax
cmpl $0x0, %eax
jne 0xa0fc
movq -0x10(%rbp), %rax
movswl 0xa2(%rax), %eax
cmpl $0x2, %eax
jne 0xa0fc
leaq -0x26(%rbp), %rdi
movq %rdi, -0x58(%rbp)
callq 0x5770
movq -0x40(%rbp), %rdi
movq -0x58(%rbp), %rdx
leaq 0x2011(%rip), %rsi # 0xc0de
callq 0x5700
jmp 0xa0d4
leaq -0x26(%rbp), %rdi
callq 0x54b0
jmp 0xa211
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x26(%rbp), %rdi
callq 0x54b0
jmp 0xa21b
movq -0x10(%rbp), %rax
movswl 0xa0(%rax), %eax
cmpl $0x1, %eax
jne 0xa167
movq -0x10(%rbp), %rax
movswl 0xa2(%rax), %eax
cmpl $0x0, %eax
jne 0xa167
leaq -0x27(%rbp), %rdi
movq %rdi, -0x60(%rbp)
callq 0x5770
movq -0x40(%rbp), %rdi
movq -0x60(%rbp), %rdx
leaq 0x1fa4(%rip), %rsi # 0xc0dc
callq 0x5700
jmp 0xa13f
leaq -0x27(%rbp), %rdi
callq 0x54b0
jmp 0xa211
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x27(%rbp), %rdi
callq 0x54b0
jmp 0xa21b
movq -0x10(%rbp), %rax
movswl 0xa0(%rax), %eax
cmpl $0x1, %eax
jne 0xa1cc
movq -0x10(%rbp), %rax
movswl 0xa2(%rax), %eax
cmpl $0x1, %eax
jne 0xa1cc
leaq -0x28(%rbp), %rdi
movq %rdi, -0x68(%rbp)
callq 0x5770
movq -0x40(%rbp), %rdi
movq -0x68(%rbp), %rdx
leaq 0x1f3d(%rip), %rsi # 0xc0e0
callq 0x5700
jmp 0xa1aa
leaq -0x28(%rbp), %rdi
callq 0x54b0
jmp 0xa211
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x28(%rbp), %rdi
callq 0x54b0
jmp 0xa21b
leaq -0x29(%rbp), %rdi
movq %rdi, -0x70(%rbp)
callq 0x5770
movq -0x40(%rbp), %rdi
movq -0x70(%rbp), %rdx
leaq 0x1efb(%rip), %rsi # 0xc0e3
callq 0x5700
jmp 0xa1ef
leaq -0x29(%rbp), %rdi
callq 0x54b0
jmp 0xa211
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x29(%rbp), %rdi
callq 0x54b0
jmp 0xa21b
movq -0x38(%rbp), %rax
addq $0x70, %rsp
popq %rbp
retq
movq -0x20(%rbp), %rdi
callq 0x5740
nopw %cs:(%rax,%rax)
nop
|
_Z10arrowMakerB5cxx11RK4Line:
push rbp
mov rbp, rsp
sub rsp, 70h
mov [rbp+var_40], rdi
mov rax, rdi
mov [rbp+var_38], rax
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A0h]
cmp eax, 0
jnz short loc_A026
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A2h]
cmp eax, 0
jnz short loc_A026
lea rdi, [rbp+var_11]
mov [rbp+var_48], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rbp+var_40]
mov rdx, [rbp+var_48]
lea rsi, asc_C0DB; "--"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_9FFE:
lea rdi, [rbp+var_11]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_A211
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
lea rdi, [rbp+var_11]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_A21B
loc_A026:
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A0h]
cmp eax, 0
jnz short loc_A091
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A2h]
cmp eax, 1
jnz short loc_A091
lea rdi, [rbp+var_25]
mov [rbp+var_50], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rbp+var_40]
mov rdx, [rbp+var_50]
lea rsi, asc_C0DE+1; "-->"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_A069:
lea rdi, [rbp+var_25]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_A211
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
lea rdi, [rbp+var_25]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_A21B
loc_A091:
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A0h]
cmp eax, 0
jnz short loc_A0FC
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A2h]
cmp eax, 2
jnz short loc_A0FC
lea rdi, [rbp+var_26]
mov [rbp+var_58], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rbp+var_40]
mov rdx, [rbp+var_58]
lea rsi, asc_C0DE; "<-->"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_A0D4:
lea rdi, [rbp+var_26]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_A211
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
lea rdi, [rbp+var_26]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_A21B
loc_A0FC:
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A0h]
cmp eax, 1
jnz short loc_A167
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A2h]
cmp eax, 0
jnz short loc_A167
lea rdi, [rbp+var_27]
mov [rbp+var_60], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rbp+var_40]
mov rdx, [rbp+var_60]
lea rsi, asc_C0DB+1; "-"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_A13F:
lea rdi, [rbp+var_27]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_A211
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
lea rdi, [rbp+var_27]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_A21B
loc_A167:
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A0h]
cmp eax, 1
jnz short loc_A1CC
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+0A2h]
cmp eax, 1
jnz short loc_A1CC
lea rdi, [rbp+var_28]
mov [rbp+var_68], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rbp+var_40]
mov rdx, [rbp+var_68]
lea rsi, asc_C0DE+2; "->"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_A1AA:
lea rdi, [rbp+var_28]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_A211
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
lea rdi, [rbp+var_28]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_A21B
loc_A1CC:
lea rdi, [rbp+var_29]
mov [rbp+var_70], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rbp+var_40]
mov rdx, [rbp+var_70]
lea rsi, asc_C0E3; "<->"
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_A1EF:
lea rdi, [rbp+var_29]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_A211
mov rcx, rax
mov eax, edx
mov [rbp+var_20], rcx
mov [rbp+var_24], eax
lea rdi, [rbp+var_29]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_A21B
loc_A211:
mov rax, [rbp+var_38]
add rsp, 70h
pop rbp
retn
loc_A21B:
mov rdi, [rbp+var_20]
call __Unwind_Resume
|
long long arrowMaker[abi:cxx11](long long a1, long long a2)
{
char v3; // [rsp+47h] [rbp-29h] BYREF
char v4; // [rsp+48h] [rbp-28h] BYREF
char v5; // [rsp+49h] [rbp-27h] BYREF
char v6; // [rsp+4Ah] [rbp-26h] BYREF
char v7; // [rsp+4Bh] [rbp-25h] BYREF
char v8; // [rsp+5Fh] [rbp-11h] BYREF
long long v9; // [rsp+60h] [rbp-10h]
long long v10; // [rsp+68h] [rbp-8h]
v10 = a1;
v9 = a2;
if ( *(_WORD *)(a2 + 160) || *(_WORD *)(v9 + 162) )
{
if ( *(_WORD *)(v9 + 160) || *(_WORD *)(v9 + 162) != 1 )
{
if ( *(_WORD *)(v9 + 160) || *(_WORD *)(v9 + 162) != 2 )
{
if ( *(_WORD *)(v9 + 160) != 1 || *(_WORD *)(v9 + 162) )
{
if ( *(_WORD *)(v9 + 160) == 1 && *(_WORD *)(v9 + 162) == 1 )
{
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, "->", &v4);
std::allocator<char>::~allocator(&v4);
}
else
{
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, "<->", &v3);
std::allocator<char>::~allocator(&v3);
}
}
else
{
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, "-", &v5);
std::allocator<char>::~allocator(&v5);
}
}
else
{
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, "<-->", &v6);
std::allocator<char>::~allocator(&v6);
}
}
else
{
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, "-->", &v7);
std::allocator<char>::~allocator(&v7);
}
}
else
{
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, "--", &v8);
std::allocator<char>::~allocator(&v8);
}
return a1;
}
|
arrowMaker[abi:cxx11]:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x70
MOV qword ptr [RBP + -0x40],RDI
MOV RAX,RDI
MOV qword ptr [RBP + -0x38],RAX
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa0]
CMP EAX,0x0
JNZ 0x0010a026
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa2]
CMP EAX,0x0
JNZ 0x0010a026
LEA RDI,[RBP + -0x11]
MOV qword ptr [RBP + -0x48],RDI
CALL 0x00105770
MOV RDI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x48]
LAB_00109ff0:
LEA RSI,[0x10c0db]
CALL 0x00105700
JMP 0x00109ffe
LAB_00109ffe:
LEA RDI,[RBP + -0x11]
CALL 0x001054b0
JMP 0x0010a211
LAB_0010a026:
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa0]
CMP EAX,0x0
JNZ 0x0010a091
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa2]
CMP EAX,0x1
JNZ 0x0010a091
LEA RDI,[RBP + -0x25]
MOV qword ptr [RBP + -0x50],RDI
CALL 0x00105770
MOV RDI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x50]
LAB_0010a05b:
LEA RSI,[0x10c0df]
CALL 0x00105700
JMP 0x0010a069
LAB_0010a069:
LEA RDI,[RBP + -0x25]
CALL 0x001054b0
JMP 0x0010a211
LAB_0010a091:
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa0]
CMP EAX,0x0
JNZ 0x0010a0fc
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa2]
CMP EAX,0x2
JNZ 0x0010a0fc
LEA RDI,[RBP + -0x26]
MOV qword ptr [RBP + -0x58],RDI
CALL 0x00105770
MOV RDI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x58]
LAB_0010a0c6:
LEA RSI,[0x10c0de]
CALL 0x00105700
JMP 0x0010a0d4
LAB_0010a0d4:
LEA RDI,[RBP + -0x26]
CALL 0x001054b0
JMP 0x0010a211
LAB_0010a0fc:
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa0]
CMP EAX,0x1
JNZ 0x0010a167
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa2]
CMP EAX,0x0
JNZ 0x0010a167
LEA RDI,[RBP + -0x27]
MOV qword ptr [RBP + -0x60],RDI
CALL 0x00105770
MOV RDI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x60]
LAB_0010a131:
LEA RSI,[0x10c0dc]
CALL 0x00105700
JMP 0x0010a13f
LAB_0010a13f:
LEA RDI,[RBP + -0x27]
CALL 0x001054b0
JMP 0x0010a211
LAB_0010a167:
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa0]
CMP EAX,0x1
JNZ 0x0010a1cc
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,word ptr [RAX + 0xa2]
CMP EAX,0x1
JNZ 0x0010a1cc
LEA RDI,[RBP + -0x28]
MOV qword ptr [RBP + -0x68],RDI
CALL 0x00105770
MOV RDI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x68]
LAB_0010a19c:
LEA RSI,[0x10c0e0]
CALL 0x00105700
JMP 0x0010a1aa
LAB_0010a1aa:
LEA RDI,[RBP + -0x28]
CALL 0x001054b0
JMP 0x0010a211
LAB_0010a1cc:
LEA RDI,[RBP + -0x29]
MOV qword ptr [RBP + -0x70],RDI
CALL 0x00105770
MOV RDI,qword ptr [RBP + -0x40]
MOV RDX,qword ptr [RBP + -0x70]
LAB_0010a1e1:
LEA RSI,[0x10c0e3]
CALL 0x00105700
LAB_0010a1ed:
JMP 0x0010a1ef
LAB_0010a1ef:
LEA RDI,[RBP + -0x29]
CALL 0x001054b0
JMP 0x0010a211
LAB_0010a211:
MOV RAX,qword ptr [RBP + -0x38]
ADD RSP,0x70
POP RBP
RET
|
/* arrowMaker[abi:cxx11](Line const&) */
Line * arrowMaker_abi_cxx11_(Line *param_1)
{
long in_RSI;
allocator local_31;
allocator local_30;
allocator local_2f;
allocator local_2e;
allocator local_2d [20];
allocator local_19 [9];
Line *local_10;
local_10 = param_1;
if ((*(short *)(in_RSI + 0xa0) == 0) && (*(short *)(in_RSI + 0xa2) == 0)) {
std::allocator<char>::allocator();
/* try { // try from 00109ff0 to 00109ffb has its CatchHandler @ 0010a00c */
std::__cxx11::string::string<std::allocator<char>>((string *)param_1,"--",local_19);
std::allocator<char>::~allocator((allocator<char> *)local_19);
}
else if ((*(short *)(in_RSI + 0xa0) == 0) && (*(short *)(in_RSI + 0xa2) == 1)) {
std::allocator<char>::allocator();
/* try { // try from 0010a05b to 0010a066 has its CatchHandler @ 0010a077 */
std::__cxx11::string::string<std::allocator<char>>((string *)param_1,"-->",local_2d);
std::allocator<char>::~allocator((allocator<char> *)local_2d);
}
else if ((*(short *)(in_RSI + 0xa0) == 0) && (*(short *)(in_RSI + 0xa2) == 2)) {
std::allocator<char>::allocator();
/* try { // try from 0010a0c6 to 0010a0d1 has its CatchHandler @ 0010a0e2 */
std::__cxx11::string::string<std::allocator<char>>((string *)param_1,"<-->",&local_2e);
std::allocator<char>::~allocator((allocator<char> *)&local_2e);
}
else if ((*(short *)(in_RSI + 0xa0) == 1) && (*(short *)(in_RSI + 0xa2) == 0)) {
std::allocator<char>::allocator();
/* try { // try from 0010a131 to 0010a13c has its CatchHandler @ 0010a14d */
std::__cxx11::string::string<std::allocator<char>>((string *)param_1,"-",&local_2f);
std::allocator<char>::~allocator((allocator<char> *)&local_2f);
}
else if ((*(short *)(in_RSI + 0xa0) == 1) && (*(short *)(in_RSI + 0xa2) == 1)) {
std::allocator<char>::allocator();
/* try { // try from 0010a19c to 0010a1a7 has its CatchHandler @ 0010a1b5 */
std::__cxx11::string::string<std::allocator<char>>((string *)param_1,"->",&local_30);
std::allocator<char>::~allocator((allocator<char> *)&local_30);
}
else {
std::allocator<char>::allocator();
/* try { // try from 0010a1e1 to 0010a1ec has its CatchHandler @ 0010a1fa */
std::__cxx11::string::string<std::allocator<char>>((string *)param_1,"<->",&local_31);
std::allocator<char>::~allocator((allocator<char> *)&local_31);
}
return param_1;
}
|
|
9,917 |
arrowMaker[abi:cxx11](Line const&)
|
11AgReS1SoR11[P]Graph/Common/Retranslator/src/Retranslator.cpp
|
std::string arrowMaker(const Line& line)
{
if (static_cast<short>(line.type) == 0 && static_cast<short>(line.orientation) == 0)
return "--";
else if (static_cast<short>(line.type) == 0 && static_cast<short>(line.orientation) == 1)
return "-->";
else if (static_cast<short>(line.type) == 0 && static_cast<short>(line.orientation) == 2)
return "<-->";
else if (static_cast<short>(line.type) == 1 && static_cast<short>(line.orientation) == 0)
return "-";
else if (static_cast<short>(line.type) == 1 && static_cast<short>(line.orientation) == 1)
return "->";
else
return "<->";
}
|
O2
|
cpp
|
arrowMaker[abi:cxx11](Line const&):
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movzwl 0xa0(%rsi), %eax
movzwl 0xa2(%rsi), %ecx
movl %eax, %edx
orw %cx, %dx
jne 0x3f81
leaq 0x1161(%rip), %rsi # 0x50db
leaq 0xf(%rsp), %rdx
jmp 0x3fee
movl %ecx, %edx
xorl $0x1, %edx
orw %ax, %dx
jne 0x3f99
leaq 0x114d(%rip), %rsi # 0x50df
leaq 0xe(%rsp), %rdx
jmp 0x3fee
movl %ecx, %edx
xorl $0x2, %edx
orw %ax, %dx
jne 0x3fb1
leaq 0x1134(%rip), %rsi # 0x50de
leaq 0xd(%rsp), %rdx
jmp 0x3fee
movl %eax, %edx
xorl $0x1, %edx
orw %cx, %dx
jne 0x3fc9
leaq 0x111a(%rip), %rsi # 0x50dc
leaq 0xc(%rsp), %rdx
jmp 0x3fee
xorl $0x1, %eax
xorl $0x1, %ecx
orw %ax, %cx
jne 0x3fe2
leaq 0x1105(%rip), %rsi # 0x50e0
leaq 0xb(%rsp), %rdx
jmp 0x3fee
leaq 0x10fa(%rip), %rsi # 0x50e3
leaq 0xa(%rsp), %rdx
movq %rbx, %rdi
callq 0x22c0
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
retq
nop
|
_Z10arrowMakerB5cxx11RK4Line:
push rbx
sub rsp, 10h
mov rbx, rdi
movzx eax, word ptr [rsi+0A0h]
movzx ecx, word ptr [rsi+0A2h]
mov edx, eax
or dx, cx
jnz short loc_3F81
lea rsi, asc_50DB; "--"
lea rdx, [rsp+18h+var_9]
jmp short loc_3FEE
loc_3F81:
mov edx, ecx
xor edx, 1
or dx, ax
jnz short loc_3F99
lea rsi, asc_50DE+1; "-->"
lea rdx, [rsp+18h+var_A]
jmp short loc_3FEE
loc_3F99:
mov edx, ecx
xor edx, 2
or dx, ax
jnz short loc_3FB1
lea rsi, asc_50DE; "<-->"
lea rdx, [rsp+18h+var_B]
jmp short loc_3FEE
loc_3FB1:
mov edx, eax
xor edx, 1
or dx, cx
jnz short loc_3FC9
lea rsi, asc_50DB+1; "-"
lea rdx, [rsp+18h+var_C]
jmp short loc_3FEE
loc_3FC9:
xor eax, 1
xor ecx, 1
or cx, ax
jnz short loc_3FE2
lea rsi, asc_50DE+2; "->"
lea rdx, [rsp+18h+var_D]
jmp short loc_3FEE
loc_3FE2:
lea rsi, asc_50E3; "<->"
lea rdx, [rsp+18h+var_E]
loc_3FEE:
mov rdi, rbx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
mov rax, rbx
add rsp, 10h
pop rbx
retn
|
long long arrowMaker[abi:cxx11](long long a1, long long a2)
{
unsigned __int16 v2; // ax
unsigned __int16 v3; // cx
char *v4; // rsi
char *v5; // rdx
char v7; // [rsp+Ah] [rbp-Eh] BYREF
char v8; // [rsp+Bh] [rbp-Dh] BYREF
char v9; // [rsp+Ch] [rbp-Ch] BYREF
char v10; // [rsp+Dh] [rbp-Bh] BYREF
char v11; // [rsp+Eh] [rbp-Ah] BYREF
char v12; // [rsp+Fh] [rbp-9h] BYREF
v2 = *(_WORD *)(a2 + 160);
v3 = *(_WORD *)(a2 + 162);
if ( *(_DWORD *)(a2 + 160) )
{
if ( v2 | v3 ^ 1 )
{
if ( v2 | v3 ^ 2 )
{
if ( v3 | v2 ^ 1 )
{
if ( v2 ^ 1 | v3 ^ 1 )
{
v4 = "<->";
v5 = &v7;
}
else
{
v4 = "->";
v5 = &v8;
}
}
else
{
v4 = "-";
v5 = &v9;
}
}
else
{
v4 = "<-->";
v5 = &v10;
}
}
else
{
v4 = "-->";
v5 = &v11;
}
}
else
{
v4 = "--";
v5 = &v12;
}
std::string::basic_string<std::allocator<char>>(a1, v4, v5);
return a1;
}
|
arrowMaker[abi:cxx11]:
PUSH RBX
SUB RSP,0x10
MOV RBX,RDI
MOVZX EAX,word ptr [RSI + 0xa0]
MOVZX ECX,word ptr [RSI + 0xa2]
MOV EDX,EAX
OR DX,CX
JNZ 0x00103f81
LEA RSI,[0x1050db]
LEA RDX,[RSP + 0xf]
JMP 0x00103fee
LAB_00103f81:
MOV EDX,ECX
XOR EDX,0x1
OR DX,AX
JNZ 0x00103f99
LEA RSI,[0x1050df]
LEA RDX,[RSP + 0xe]
JMP 0x00103fee
LAB_00103f99:
MOV EDX,ECX
XOR EDX,0x2
OR DX,AX
JNZ 0x00103fb1
LEA RSI,[0x1050de]
LEA RDX,[RSP + 0xd]
JMP 0x00103fee
LAB_00103fb1:
MOV EDX,EAX
XOR EDX,0x1
OR DX,CX
JNZ 0x00103fc9
LEA RSI,[0x1050dc]
LEA RDX,[RSP + 0xc]
JMP 0x00103fee
LAB_00103fc9:
XOR EAX,0x1
XOR ECX,0x1
OR CX,AX
JNZ 0x00103fe2
LEA RSI,[0x1050e0]
LEA RDX,[RSP + 0xb]
JMP 0x00103fee
LAB_00103fe2:
LEA RSI,[0x1050e3]
LEA RDX,[RSP + 0xa]
LAB_00103fee:
MOV RDI,RBX
CALL 0x001022c0
MOV RAX,RBX
ADD RSP,0x10
POP RBX
RET
|
/* arrowMaker[abi:cxx11](Line const&) */
Line * arrowMaker_abi_cxx11_(Line *param_1)
{
short sVar1;
short sVar2;
allocator *paVar3;
long in_RSI;
char *pcVar4;
allocator local_e;
allocator local_d;
allocator local_c;
allocator local_b;
allocator local_a;
allocator local_9;
sVar1 = *(short *)(in_RSI + 0xa0);
sVar2 = *(short *)(in_RSI + 0xa2);
if (sVar1 == 0 && sVar2 == 0) {
pcVar4 = "--";
paVar3 = &local_9;
}
else if (sVar2 == 1 && sVar1 == 0) {
pcVar4 = "-->";
paVar3 = &local_a;
}
else if (sVar2 == 2 && sVar1 == 0) {
pcVar4 = "<-->";
paVar3 = &local_b;
}
else if (sVar1 == 1 && sVar2 == 0) {
pcVar4 = "-";
paVar3 = &local_c;
}
else if (sVar2 == 1 && sVar1 == 1) {
pcVar4 = "->";
paVar3 = &local_d;
}
else {
pcVar4 = "<->";
paVar3 = &local_e;
}
std::__cxx11::string::string<std::allocator<char>>((string *)param_1,pcVar4,paVar3);
return param_1;
}
|
|
9,918 |
js_parse_expr_paren
|
bluesky950520[P]quickjs/quickjs.c
|
static __exception int js_parse_expr_paren(JSParseState *s)
{
if (js_parse_expect(s, '('))
return -1;
if (js_parse_expr(s))
return -1;
if (js_parse_expect(s, ')'))
return -1;
return 0;
}
|
O1
|
c
|
js_parse_expr_paren:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movl $0x28, %esi
callq 0x637c4
movl $0xffffffff, %ebx # imm = 0xFFFFFFFF
testl %eax, %eax
jne 0x68b3b
movq %r14, %rdi
movl $0x1, %esi
callq 0x6a9b7
testl %eax, %eax
jne 0x68b3b
movq %r14, %rdi
movl $0x29, %esi
callq 0x637c4
xorl %ebx, %ebx
negl %eax
sbbl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
|
js_parse_expr_paren:
push r14
push rbx
push rax
mov r14, rdi
mov esi, 28h ; '('
call js_parse_expect
mov ebx, 0FFFFFFFFh
test eax, eax
jnz short loc_68B3B
mov rdi, r14
mov esi, 1
call js_parse_expr2
test eax, eax
jnz short loc_68B3B
mov rdi, r14
mov esi, 29h ; ')'
call js_parse_expect
xor ebx, ebx
neg eax
sbb ebx, ebx
loc_68B3B:
mov eax, ebx
add rsp, 8
pop rbx
pop r14
retn
|
long long js_parse_expr_paren(
long long *a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
long long a10,
long long a11,
long long a12,
long long a13,
long long a14)
{
unsigned int v14; // ebx
long long v15; // rdx
long long v16; // rcx
long long v17; // r8
long long v18; // r9
__m128 v19; // xmm4
__m128 v20; // xmm5
v14 = -1;
if ( !(unsigned int)js_parse_expect(a1, 40LL, a11, a12, a13, a14, a2, a3, a4, a5, a6, a7, a8, a9)
&& !(unsigned int)js_parse_expr2(a1, 1LL) )
{
return (unsigned int)-((unsigned int)js_parse_expect(a1, 41LL, v15, v16, v17, v18, a2, a3, a4, a5, v19, v20, a8, a9) != 0);
}
return v14;
}
|
js_parse_expr_paren:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RDI
MOV ESI,0x28
CALL 0x001637c4
MOV EBX,0xffffffff
TEST EAX,EAX
JNZ 0x00168b3b
MOV RDI,R14
MOV ESI,0x1
CALL 0x0016a9b7
TEST EAX,EAX
JNZ 0x00168b3b
MOV RDI,R14
MOV ESI,0x29
CALL 0x001637c4
XOR EBX,EBX
NEG EAX
SBB EBX,EBX
LAB_00168b3b:
MOV EAX,EBX
ADD RSP,0x8
POP RBX
POP R14
RET
|
int js_parse_expr_paren(int8 param_1)
{
int iVar1;
int iVar2;
iVar1 = js_parse_expect(param_1,0x28);
iVar2 = -1;
if (iVar1 == 0) {
iVar1 = js_parse_expr2(param_1,1);
if (iVar1 == 0) {
iVar2 = js_parse_expect(param_1,0x29);
iVar2 = -(uint)(iVar2 != 0);
}
}
return iVar2;
}
|
|
9,919 |
js_parse_expr_paren
|
bluesky950520[P]quickjs/quickjs.c
|
static __exception int js_parse_expr_paren(JSParseState *s)
{
if (js_parse_expect(s, '('))
return -1;
if (js_parse_expr(s))
return -1;
if (js_parse_expect(s, ')'))
return -1;
return 0;
}
|
O2
|
c
|
js_parse_expr_paren:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
pushq $0x28
popq %rsi
callq 0x5523b
pushq $-0x1
popq %rbp
testl %eax, %eax
jne 0x58cc3
movq %rbx, %rdi
callq 0x59f66
testl %eax, %eax
jne 0x58cc3
pushq $0x29
popq %rsi
movq %rbx, %rdi
callq 0x5523b
xorl %ebp, %ebp
negl %eax
sbbl %ebp, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
|
js_parse_expr_paren:
push rbp
push rbx
push rax
mov rbx, rdi
push 28h ; '('
pop rsi
call js_parse_expect
push 0FFFFFFFFFFFFFFFFh
pop rbp
test eax, eax
jnz short loc_58CC3
mov rdi, rbx
call js_parse_expr
test eax, eax
jnz short loc_58CC3
push 29h ; ')'
pop rsi
mov rdi, rbx
call js_parse_expect
xor ebp, ebp
neg eax
sbb ebp, ebp
loc_58CC3:
mov eax, ebp
add rsp, 8
pop rbx
pop rbp
retn
|
long long js_parse_expr_paren(
long long a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
long long a10,
long long a11,
long long a12,
long long a13,
long long a14)
{
unsigned int v14; // ebp
long long v15; // rdx
long long v16; // rcx
long long v17; // r8
long long v18; // r9
__m128 v19; // xmm4
__m128 v20; // xmm5
v14 = -1;
if ( !(unsigned int)js_parse_expect(a1, 40LL, a11, a12, a13, a14, a2, a3, a4, a5, a6, a7, a8, a9)
&& !(unsigned int)js_parse_expr(a1) )
{
return (unsigned int)-((unsigned int)js_parse_expect(a1, 41LL, v15, v16, v17, v18, a2, a3, a4, a5, v19, v20, a8, a9) != 0);
}
return v14;
}
|
js_parse_expr_paren:
PUSH RBP
PUSH RBX
PUSH RAX
MOV RBX,RDI
PUSH 0x28
POP RSI
CALL 0x0015523b
PUSH -0x1
POP RBP
TEST EAX,EAX
JNZ 0x00158cc3
MOV RDI,RBX
CALL 0x00159f66
TEST EAX,EAX
JNZ 0x00158cc3
PUSH 0x29
POP RSI
MOV RDI,RBX
CALL 0x0015523b
XOR EBP,EBP
NEG EAX
SBB EBP,EBP
LAB_00158cc3:
MOV EAX,EBP
ADD RSP,0x8
POP RBX
POP RBP
RET
|
int js_parse_expr_paren(int8 param_1)
{
int iVar1;
int iVar2;
iVar1 = js_parse_expect(param_1,0x28);
iVar2 = -1;
if (iVar1 == 0) {
iVar1 = js_parse_expr(param_1);
if (iVar1 == 0) {
iVar2 = js_parse_expect(param_1,0x29);
iVar2 = -(uint)(iVar2 != 0);
}
}
return iVar2;
}
|
|
9,920 |
strmake_root
|
eloqsql/mysys/my_alloc.c
|
char *strmake_root(MEM_ROOT *root, const char *str, size_t len)
{
char *pos;
if ((pos=alloc_root(root,len+1)))
{
if (len)
memcpy(pos,str,len);
pos[len]=0;
}
return pos;
}
|
O3
|
c
|
strmake_root:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
leaq 0x1(%rdx), %rsi
callq 0x5d103
movq %rax, %r15
testq %rax, %rax
je 0x5d4fe
testq %rbx, %rbx
je 0x5d4f9
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x360a0
movb $0x0, (%r15,%rbx)
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
|
strmake_root:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov rbx, rdx
mov r14, rsi
lea rsi, [rdx+1]
call alloc_root
mov r15, rax
test rax, rax
jz short loc_5D4FE
test rbx, rbx
jz short loc_5D4F9
mov rdi, r15
mov rsi, r14
mov rdx, rbx
call _memcpy
loc_5D4F9:
mov byte ptr [r15+rbx], 0
loc_5D4FE:
mov rax, r15
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
|
char * strmake_root(long long a1, long long a2, long long a3)
{
char *v4; // rax
char *v5; // r15
v4 = alloc_root(a1, a3 + 1);
v5 = v4;
if ( v4 )
{
if ( a3 )
memcpy(v4, a2, a3);
v5[a3] = 0;
}
return v5;
}
|
strmake_root:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDX
MOV R14,RSI
LEA RSI,[RDX + 0x1]
CALL 0x0015d103
MOV R15,RAX
TEST RAX,RAX
JZ 0x0015d4fe
TEST RBX,RBX
JZ 0x0015d4f9
MOV RDI,R15
MOV RSI,R14
MOV RDX,RBX
CALL 0x001360a0
LAB_0015d4f9:
MOV byte ptr [R15 + RBX*0x1],0x0
LAB_0015d4fe:
MOV RAX,R15
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
|
void * strmake_root(int8 param_1,void *param_2,size_t param_3)
{
void *__dest;
__dest = (void *)alloc_root(param_1,param_3 + 1);
if (__dest != (void *)0x0) {
if (param_3 != 0) {
memcpy(__dest,param_2,param_3);
}
*(int1 *)((long)__dest + param_3) = 0;
}
return __dest;
}
|
|
9,921 |
common_log::~common_log()
|
monkey531[P]llama/common/log.cpp
|
~common_log() {
pause();
if (file) {
fclose(file);
}
}
|
O1
|
cpp
|
common_log::~common_log():
pushq %rbx
movq %rdi, %rbx
callq 0xcd5e4
movq 0x60(%rbx), %rdi
testq %rdi, %rdi
je 0xcd5a1
callq 0x1b8b0
movq 0xb0(%rbx), %rdi
testq %rdi, %rdi
je 0xcd5bc
movq 0xc0(%rbx), %rsi
subq %rdi, %rsi
callq 0x1b8f0
leaq 0x78(%rbx), %rdi
callq 0xcdc8e
leaq 0x30(%rbx), %rdi
callq 0x1c040
cmpq $0x0, 0x28(%rbx)
jne 0xcd5d7
popq %rbx
retq
callq 0x1b220
movq %rax, %rdi
callq 0x229a1
|
_ZN10common_logD2Ev:
push rbx
mov rbx, rdi
call _ZN10common_log5pauseEv; common_log::pause(void)
mov rdi, [rbx+60h]
test rdi, rdi
jz short loc_CD5A1
call _fclose
loc_CD5A1:
mov rdi, [rbx+0B0h]; void *
test rdi, rdi
jz short loc_CD5BC
mov rsi, [rbx+0C0h]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_CD5BC:
lea rdi, [rbx+78h]
call _ZNSt6vectorI16common_log_entrySaIS0_EED2Ev; std::vector<common_log_entry>::~vector()
lea rdi, [rbx+30h]; this
call __ZNSt18condition_variableD1Ev; std::condition_variable::~condition_variable()
cmp qword ptr [rbx+28h], 0
jnz short loc_CD5D7
pop rbx
retn
loc_CD5D7:
call __ZSt9terminatev; std::terminate(void)
mov rdi, rax
call __clang_call_terminate
|
void common_log::~common_log(char *a1)
{
void *v2; // rdi
common_log::pause((common_log *)a1);
if ( *((_QWORD *)a1 + 12) )
fclose();
v2 = (void *)*((_QWORD *)a1 + 22);
if ( v2 )
operator delete(v2, *((_QWORD *)a1 + 24) - (_QWORD)v2);
std::vector<common_log_entry>::~vector(a1 + 120);
std::condition_variable::~condition_variable((std::condition_variable *)(a1 + 48));
if ( *((_QWORD *)a1 + 5) )
std::terminate();
}
|
~common_log:
PUSH RBX
MOV RBX,RDI
LAB_001cd58e:
CALL 0x001cd5e4
LAB_001cd593:
MOV RDI,qword ptr [RBX + 0x60]
TEST RDI,RDI
JZ 0x001cd5a1
CALL 0x0011b8b0
LAB_001cd5a1:
MOV RDI,qword ptr [RBX + 0xb0]
TEST RDI,RDI
JZ 0x001cd5bc
MOV RSI,qword ptr [RBX + 0xc0]
SUB RSI,RDI
CALL 0x0011b8f0
LAB_001cd5bc:
LEA RDI,[RBX + 0x78]
CALL 0x001cdc8e
LEA RDI,[RBX + 0x30]
CALL 0x0011c040
CMP qword ptr [RBX + 0x28],0x0
JNZ 0x001cd5d7
POP RBX
RET
LAB_001cd5d7:
CALL 0x0011b220
|
/* common_log::~common_log() */
void __thiscall common_log::~common_log(common_log *this)
{
void *pvVar1;
/* try { // try from 001cd58e to 001cd592 has its CatchHandler @ 001cd5dc */
pause(this);
if (*(FILE **)(this + 0x60) != (FILE *)0x0) {
fclose(*(FILE **)(this + 0x60));
}
pvVar1 = *(void **)(this + 0xb0);
if (pvVar1 != (void *)0x0) {
operator_delete(pvVar1,*(long *)(this + 0xc0) - (long)pvVar1);
}
std::vector<common_log_entry,std::allocator<common_log_entry>>::~vector
((vector<common_log_entry,std::allocator<common_log_entry>> *)(this + 0x78));
std::condition_variable::~condition_variable((condition_variable *)(this + 0x30));
if (*(long *)(this + 0x28) == 0) {
return;
}
/* WARNING: Subroutine does not return */
std::terminate();
}
|
|
9,922 |
common_log::~common_log()
|
monkey531[P]llama/common/log.cpp
|
~common_log() {
pause();
if (file) {
fclose(file);
}
}
|
O3
|
cpp
|
common_log::~common_log():
pushq %rbx
movq %rdi, %rbx
callq 0xcba4a
movq 0x60(%rbx), %rdi
testq %rdi, %rdi
je 0xcba07
callq 0x1a8b0
movq 0xb0(%rbx), %rdi
testq %rdi, %rdi
je 0xcba22
movq 0xc0(%rbx), %rsi
subq %rdi, %rsi
callq 0x1a8f0
leaq 0x78(%rbx), %rdi
callq 0xcc0f6
leaq 0x30(%rbx), %rdi
callq 0x1b040
cmpq $0x0, 0x28(%rbx)
jne 0xcba3d
popq %rbx
retq
callq 0x1a220
movq %rax, %rdi
callq 0x218f5
|
_ZN10common_logD2Ev:
push rbx
mov rbx, rdi
call _ZN10common_log5pauseEv; common_log::pause(void)
mov rdi, [rbx+60h]
test rdi, rdi
jz short loc_CBA07
call _fclose
loc_CBA07:
mov rdi, [rbx+0B0h]; void *
test rdi, rdi
jz short loc_CBA22
mov rsi, [rbx+0C0h]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_CBA22:
lea rdi, [rbx+78h]
call _ZNSt6vectorI16common_log_entrySaIS0_EED2Ev; std::vector<common_log_entry>::~vector()
lea rdi, [rbx+30h]; this
call __ZNSt18condition_variableD1Ev; std::condition_variable::~condition_variable()
cmp qword ptr [rbx+28h], 0
jnz short loc_CBA3D
pop rbx
retn
loc_CBA3D:
call __ZSt9terminatev; std::terminate(void)
mov rdi, rax
call __clang_call_terminate
|
void common_log::~common_log(char *a1)
{
void *v2; // rdi
common_log::pause((common_log *)a1);
if ( *((_QWORD *)a1 + 12) )
fclose();
v2 = (void *)*((_QWORD *)a1 + 22);
if ( v2 )
operator delete(v2, *((_QWORD *)a1 + 24) - (_QWORD)v2);
std::vector<common_log_entry>::~vector(a1 + 120);
std::condition_variable::~condition_variable((std::condition_variable *)(a1 + 48));
if ( *((_QWORD *)a1 + 5) )
std::terminate();
}
|
~common_log:
PUSH RBX
MOV RBX,RDI
LAB_001cb9f4:
CALL 0x001cba4a
LAB_001cb9f9:
MOV RDI,qword ptr [RBX + 0x60]
TEST RDI,RDI
JZ 0x001cba07
CALL 0x0011a8b0
LAB_001cba07:
MOV RDI,qword ptr [RBX + 0xb0]
TEST RDI,RDI
JZ 0x001cba22
MOV RSI,qword ptr [RBX + 0xc0]
SUB RSI,RDI
CALL 0x0011a8f0
LAB_001cba22:
LEA RDI,[RBX + 0x78]
CALL 0x001cc0f6
LEA RDI,[RBX + 0x30]
CALL 0x0011b040
CMP qword ptr [RBX + 0x28],0x0
JNZ 0x001cba3d
POP RBX
RET
LAB_001cba3d:
CALL 0x0011a220
|
/* common_log::~common_log() */
void __thiscall common_log::~common_log(common_log *this)
{
void *pvVar1;
/* try { // try from 001cb9f4 to 001cb9f8 has its CatchHandler @ 001cba42 */
pause(this);
if (*(FILE **)(this + 0x60) != (FILE *)0x0) {
fclose(*(FILE **)(this + 0x60));
}
pvVar1 = *(void **)(this + 0xb0);
if (pvVar1 != (void *)0x0) {
operator_delete(pvVar1,*(long *)(this + 0xc0) - (long)pvVar1);
}
std::vector<common_log_entry,std::allocator<common_log_entry>>::~vector
((vector<common_log_entry,std::allocator<common_log_entry>> *)(this + 0x78));
std::condition_variable::~condition_variable((condition_variable *)(this + 0x30));
if (*(long *)(this + 0x28) == 0) {
return;
}
/* WARNING: Subroutine does not return */
std::terminate();
}
|
|
9,923 |
LefDefParser::defrSettings::defrSettings()
|
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/def/def/defrSettings.cpp
|
defrSettings::defrSettings()
: defiDeltaNumberLines(10000),
AssertionWarnings(999),
BlockageWarnings(999),
CaseSensitiveWarnings(999),
ComponentWarnings(999),
ConstraintWarnings(999),
DefaultCapWarnings(999),
FillWarnings(999),
GcellGridWarnings(999),
IOTimingWarnings(999),
NetWarnings(999),
NonDefaultWarnings(999),
PinExtWarnings(999),
PinWarnings(999),
RegionWarnings(999),
RowWarnings(999),
TrackWarnings(999),
ScanchainWarnings(999),
SNetWarnings(999),
StylesWarnings(999),
UnitsWarnings(999),
VersionWarnings(999),
ViaWarnings(999),
nDDMsgs(0),
disableDMsgs(NULL),
reader_case_sensitive_set(0),
totalDefMsgLimit(0),
AddPathToNet(0),
AllowComponentNets(0),
CommentChar('#'),
DisPropStrProcess(0),
LogFileAppend(0),
ReadFunction(NULL),
ErrorLogFunction(NULL),
WarningLogFunction(NULL),
ContextErrorLogFunction(NULL),
ContextWarningLogFunction(NULL),
MagicCommentFoundFunction(NULL),
MallocFunction(NULL),
ReallocFunction(NULL),
FreeFunction(NULL),
LineNumberFunction(NULL),
LongLineNumberFunction(NULL),
ContextLineNumberFunction(NULL),
ContextLongLineNumberFunction(NULL)
{
memset(MsgLimit, 0, DEF_MSGS * sizeof(int));
memset(UnusedCallbacks, 0, CBMAX * sizeof(int));
init_symbol_table();
}
|
O0
|
cpp
|
LefDefParser::defrSettings::defrSettings():
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x35250
movq 0x8(%rsp), %rdi
movl $0x2710, 0x30(%rdi) # imm = 0x2710
movl $0x3e7, 0x34(%rdi) # imm = 0x3E7
movl $0x3e7, 0x38(%rdi) # imm = 0x3E7
movl $0x3e7, 0x3c(%rdi) # imm = 0x3E7
movl $0x3e7, 0x40(%rdi) # imm = 0x3E7
movl $0x3e7, 0x44(%rdi) # imm = 0x3E7
movl $0x3e7, 0x48(%rdi) # imm = 0x3E7
movl $0x3e7, 0x4c(%rdi) # imm = 0x3E7
movl $0x3e7, 0x50(%rdi) # imm = 0x3E7
movl $0x3e7, 0x54(%rdi) # imm = 0x3E7
movl $0x0, 0x58(%rdi)
movl $0x3e7, 0x5c(%rdi) # imm = 0x3E7
movl $0x3e7, 0x60(%rdi) # imm = 0x3E7
movl $0x3e7, 0x64(%rdi) # imm = 0x3E7
movl $0x3e7, 0x68(%rdi) # imm = 0x3E7
movl $0x3e7, 0x6c(%rdi) # imm = 0x3E7
movl $0x3e7, 0x70(%rdi) # imm = 0x3E7
movl $0x3e7, 0x74(%rdi) # imm = 0x3E7
movl $0x3e7, 0x78(%rdi) # imm = 0x3E7
movl $0x3e7, 0x7c(%rdi) # imm = 0x3E7
movl $0x3e7, 0x80(%rdi) # imm = 0x3E7
movl $0x3e7, 0x84(%rdi) # imm = 0x3E7
movl $0x3e7, 0x88(%rdi) # imm = 0x3E7
movl $0x3e7, 0x8c(%rdi) # imm = 0x3E7
movl $0x0, 0x90(%rdi)
movq $0x0, 0x98(%rdi)
movl $0x0, 0xa0(%rdi)
movl $0x0, 0xa4(%rdi)
movl $0x0, 0xa8(%rdi)
movb $0x23, 0xac(%rdi)
movl $0x0, 0xb0(%rdi)
movl $0x0, 0xb4(%rdi)
movq $0x0, 0xb8(%rdi)
movq $0x0, 0xc0(%rdi)
movq $0x0, 0xc8(%rdi)
movq $0x0, 0xd0(%rdi)
movq $0x0, 0xd8(%rdi)
movq $0x0, 0xe0(%rdi)
movq $0x0, 0xe8(%rdi)
movq $0x0, 0xf0(%rdi)
movq $0x0, 0xf8(%rdi)
movq $0x0, 0x100(%rdi)
movq $0x0, 0x108(%rdi)
movq $0x0, 0x110(%rdi)
movq $0x0, 0x118(%rdi)
addq $0x378, %rdi # imm = 0x378
xorl %esi, %esi
movl %esi, 0x4(%rsp)
movl $0x3eb4, %edx # imm = 0x3EB4
callq 0x7150
movl 0x4(%rsp), %esi
movq 0x8(%rsp), %rdi
addq $0x120, %rdi # imm = 0x120
movl $0x258, %edx # imm = 0x258
callq 0x7150
movq 0x8(%rsp), %rdi
callq 0x32d40
jmp 0x32d0b
addq $0x28, %rsp
retq
movq 0x8(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
callq 0x22cd0
movq 0x18(%rsp), %rdi
callq 0x73b0
nopw %cs:(%rax,%rax)
|
_ZN12LefDefParser12defrSettingsC2Ev:
sub rsp, 28h; Alternative name is 'LefDefParser::defrSettings::defrSettings(void)'
mov [rsp+28h+var_8], rdi
mov rdi, [rsp+28h+var_8]
mov [rsp+28h+var_20], rdi
call _ZNSt3mapIPKciN12LefDefParser18defCompareCStringsESaISt4pairIKS1_iEEEC2Ev; std::map<char const*,int,LefDefParser::defCompareCStrings,std::allocator<std::pair<char const* const,int>>>::map(void)
mov rdi, [rsp+28h+var_20]
mov dword ptr [rdi+30h], 2710h
mov dword ptr [rdi+34h], 3E7h
mov dword ptr [rdi+38h], 3E7h
mov dword ptr [rdi+3Ch], 3E7h
mov dword ptr [rdi+40h], 3E7h
mov dword ptr [rdi+44h], 3E7h
mov dword ptr [rdi+48h], 3E7h
mov dword ptr [rdi+4Ch], 3E7h
mov dword ptr [rdi+50h], 3E7h
mov dword ptr [rdi+54h], 3E7h
mov dword ptr [rdi+58h], 0
mov dword ptr [rdi+5Ch], 3E7h
mov dword ptr [rdi+60h], 3E7h
mov dword ptr [rdi+64h], 3E7h
mov dword ptr [rdi+68h], 3E7h
mov dword ptr [rdi+6Ch], 3E7h
mov dword ptr [rdi+70h], 3E7h
mov dword ptr [rdi+74h], 3E7h
mov dword ptr [rdi+78h], 3E7h
mov dword ptr [rdi+7Ch], 3E7h
mov dword ptr [rdi+80h], 3E7h
mov dword ptr [rdi+84h], 3E7h
mov dword ptr [rdi+88h], 3E7h
mov dword ptr [rdi+8Ch], 3E7h
mov dword ptr [rdi+90h], 0
mov qword ptr [rdi+98h], 0
mov dword ptr [rdi+0A0h], 0
mov dword ptr [rdi+0A4h], 0
mov dword ptr [rdi+0A8h], 0
mov byte ptr [rdi+0ACh], 23h ; '#'
mov dword ptr [rdi+0B0h], 0
mov dword ptr [rdi+0B4h], 0
mov qword ptr [rdi+0B8h], 0
mov qword ptr [rdi+0C0h], 0
mov qword ptr [rdi+0C8h], 0
mov qword ptr [rdi+0D0h], 0
mov qword ptr [rdi+0D8h], 0
mov qword ptr [rdi+0E0h], 0
mov qword ptr [rdi+0E8h], 0
mov qword ptr [rdi+0F0h], 0
mov qword ptr [rdi+0F8h], 0
mov qword ptr [rdi+100h], 0
mov qword ptr [rdi+108h], 0
mov qword ptr [rdi+110h], 0
mov qword ptr [rdi+118h], 0
add rdi, 378h
xor esi, esi
mov [rsp+28h+var_24], esi
mov edx, 3EB4h
call _memset
mov esi, [rsp+28h+var_24]
mov rdi, [rsp+28h+var_20]
add rdi, 120h
mov edx, 258h
call _memset
mov rdi, [rsp+28h+var_20]; this
call _ZN12LefDefParser12defrSettings17init_symbol_tableEv; LefDefParser::defrSettings::init_symbol_table(void)
jmp short $+2
loc_32D0B:
add rsp, 28h
retn
mov rdi, [rsp+arg_0]
mov rcx, rax
mov eax, edx
mov [rsp+arg_10], rcx
mov [rsp+arg_C], eax
call _ZNSt3mapIPKciN12LefDefParser18defCompareCStringsESaISt4pairIKS1_iEEED2Ev; std::map<char const*,int,LefDefParser::defCompareCStrings,std::allocator<std::pair<char const* const,int>>>::~map()
mov rdi, [rsp+arg_10]
call __Unwind_Resume
|
long long LefDefParser::defrSettings::defrSettings(LefDefParser::defrSettings *this)
{
std::map<char const*,int,LefDefParser::defCompareCStrings,std::allocator<std::pair<char const* const,int>>>::map();
*((_DWORD *)this + 12) = 10000;
*((_DWORD *)this + 13) = 999;
*((_DWORD *)this + 14) = 999;
*((_DWORD *)this + 15) = 999;
*((_DWORD *)this + 16) = 999;
*((_DWORD *)this + 17) = 999;
*((_DWORD *)this + 18) = 999;
*((_DWORD *)this + 19) = 999;
*((_DWORD *)this + 20) = 999;
*((_DWORD *)this + 21) = 999;
*((_DWORD *)this + 22) = 0;
*((_DWORD *)this + 23) = 999;
*((_DWORD *)this + 24) = 999;
*((_DWORD *)this + 25) = 999;
*((_DWORD *)this + 26) = 999;
*((_DWORD *)this + 27) = 999;
*((_DWORD *)this + 28) = 999;
*((_DWORD *)this + 29) = 999;
*((_DWORD *)this + 30) = 999;
*((_DWORD *)this + 31) = 999;
*((_DWORD *)this + 32) = 999;
*((_DWORD *)this + 33) = 999;
*((_DWORD *)this + 34) = 999;
*((_DWORD *)this + 35) = 999;
*((_DWORD *)this + 36) = 0;
*((_QWORD *)this + 19) = 0LL;
*((_DWORD *)this + 40) = 0;
*((_DWORD *)this + 41) = 0;
*((_DWORD *)this + 42) = 0;
*((_BYTE *)this + 172) = 35;
*((_DWORD *)this + 44) = 0;
*((_DWORD *)this + 45) = 0;
*((_QWORD *)this + 23) = 0LL;
*((_QWORD *)this + 24) = 0LL;
*((_QWORD *)this + 25) = 0LL;
*((_QWORD *)this + 26) = 0LL;
*((_QWORD *)this + 27) = 0LL;
*((_QWORD *)this + 28) = 0LL;
*((_QWORD *)this + 29) = 0LL;
*((_QWORD *)this + 30) = 0LL;
*((_QWORD *)this + 31) = 0LL;
*((_QWORD *)this + 32) = 0LL;
*((_QWORD *)this + 33) = 0LL;
*((_QWORD *)this + 34) = 0LL;
*((_QWORD *)this + 35) = 0LL;
memset((char *)this + 888, 0LL, 16052LL);
memset((char *)this + 288, 0LL, 600LL);
return LefDefParser::defrSettings::init_symbol_table(this);
}
|
defrSettings:
SUB RSP,0x28
MOV qword ptr [RSP + 0x20],RDI
MOV RDI,qword ptr [RSP + 0x20]
MOV qword ptr [RSP + 0x8],RDI
CALL 0x00135250
MOV RDI,qword ptr [RSP + 0x8]
MOV dword ptr [RDI + 0x30],0x2710
MOV dword ptr [RDI + 0x34],0x3e7
MOV dword ptr [RDI + 0x38],0x3e7
MOV dword ptr [RDI + 0x3c],0x3e7
MOV dword ptr [RDI + 0x40],0x3e7
MOV dword ptr [RDI + 0x44],0x3e7
MOV dword ptr [RDI + 0x48],0x3e7
MOV dword ptr [RDI + 0x4c],0x3e7
MOV dword ptr [RDI + 0x50],0x3e7
MOV dword ptr [RDI + 0x54],0x3e7
MOV dword ptr [RDI + 0x58],0x0
MOV dword ptr [RDI + 0x5c],0x3e7
MOV dword ptr [RDI + 0x60],0x3e7
MOV dword ptr [RDI + 0x64],0x3e7
MOV dword ptr [RDI + 0x68],0x3e7
MOV dword ptr [RDI + 0x6c],0x3e7
MOV dword ptr [RDI + 0x70],0x3e7
MOV dword ptr [RDI + 0x74],0x3e7
MOV dword ptr [RDI + 0x78],0x3e7
MOV dword ptr [RDI + 0x7c],0x3e7
MOV dword ptr [RDI + 0x80],0x3e7
MOV dword ptr [RDI + 0x84],0x3e7
MOV dword ptr [RDI + 0x88],0x3e7
MOV dword ptr [RDI + 0x8c],0x3e7
MOV dword ptr [RDI + 0x90],0x0
MOV qword ptr [RDI + 0x98],0x0
MOV dword ptr [RDI + 0xa0],0x0
MOV dword ptr [RDI + 0xa4],0x0
MOV dword ptr [RDI + 0xa8],0x0
MOV byte ptr [RDI + 0xac],0x23
MOV dword ptr [RDI + 0xb0],0x0
MOV dword ptr [RDI + 0xb4],0x0
MOV qword ptr [RDI + 0xb8],0x0
MOV qword ptr [RDI + 0xc0],0x0
MOV qword ptr [RDI + 0xc8],0x0
MOV qword ptr [RDI + 0xd0],0x0
MOV qword ptr [RDI + 0xd8],0x0
MOV qword ptr [RDI + 0xe0],0x0
MOV qword ptr [RDI + 0xe8],0x0
MOV qword ptr [RDI + 0xf0],0x0
MOV qword ptr [RDI + 0xf8],0x0
MOV qword ptr [RDI + 0x100],0x0
MOV qword ptr [RDI + 0x108],0x0
MOV qword ptr [RDI + 0x110],0x0
MOV qword ptr [RDI + 0x118],0x0
ADD RDI,0x378
XOR ESI,ESI
MOV dword ptr [RSP + 0x4],ESI
MOV EDX,0x3eb4
CALL 0x00107150
MOV ESI,dword ptr [RSP + 0x4]
MOV RDI,qword ptr [RSP + 0x8]
ADD RDI,0x120
MOV EDX,0x258
CALL 0x00107150
MOV RDI,qword ptr [RSP + 0x8]
LAB_00132d04:
CALL 0x00132d40
LAB_00132d09:
JMP 0x00132d0b
LAB_00132d0b:
ADD RSP,0x28
RET
|
/* LefDefParser::defrSettings::defrSettings() */
void __thiscall LefDefParser::defrSettings::defrSettings(defrSettings *this)
{
std::
map<char_const*,int,LefDefParser::defCompareCStrings,std::allocator<std::pair<char_const*const,int>>>
::map((map<char_const*,int,LefDefParser::defCompareCStrings,std::allocator<std::pair<char_const*const,int>>>
*)this);
*(int4 *)(this + 0x30) = 10000;
*(int4 *)(this + 0x34) = 999;
*(int4 *)(this + 0x38) = 999;
*(int4 *)(this + 0x3c) = 999;
*(int4 *)(this + 0x40) = 999;
*(int4 *)(this + 0x44) = 999;
*(int4 *)(this + 0x48) = 999;
*(int4 *)(this + 0x4c) = 999;
*(int4 *)(this + 0x50) = 999;
*(int4 *)(this + 0x54) = 999;
*(int4 *)(this + 0x58) = 0;
*(int4 *)(this + 0x5c) = 999;
*(int4 *)(this + 0x60) = 999;
*(int4 *)(this + 100) = 999;
*(int4 *)(this + 0x68) = 999;
*(int4 *)(this + 0x6c) = 999;
*(int4 *)(this + 0x70) = 999;
*(int4 *)(this + 0x74) = 999;
*(int4 *)(this + 0x78) = 999;
*(int4 *)(this + 0x7c) = 999;
*(int4 *)(this + 0x80) = 999;
*(int4 *)(this + 0x84) = 999;
*(int4 *)(this + 0x88) = 999;
*(int4 *)(this + 0x8c) = 999;
*(int4 *)(this + 0x90) = 0;
*(int8 *)(this + 0x98) = 0;
*(int4 *)(this + 0xa0) = 0;
*(int4 *)(this + 0xa4) = 0;
*(int4 *)(this + 0xa8) = 0;
this[0xac] = (defrSettings)0x23;
*(int4 *)(this + 0xb0) = 0;
*(int4 *)(this + 0xb4) = 0;
*(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;
*(int8 *)(this + 0xf8) = 0;
*(int8 *)(this + 0x100) = 0;
*(int8 *)(this + 0x108) = 0;
*(int8 *)(this + 0x110) = 0;
*(int8 *)(this + 0x118) = 0;
memset(this + 0x378,0,0x3eb4);
memset(this + 0x120,0,600);
/* try { // try from 00132d04 to 00132d08 has its CatchHandler @ 00132d10 */
init_symbol_table(this);
return;
}
|
|
9,924 |
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::key(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
|
monkey531[P]llama/common/./json.hpp
|
bool key(string_t& val)
{
BasicJsonType k = BasicJsonType(val);
// check callback for key
const bool keep = callback(static_cast<int>(ref_stack.size()), parse_event_t::key, k);
key_keep_stack.push_back(keep);
// add discarded value at given key and store the reference for later
if (keep && ref_stack.back())
{
object_element = &(ref_stack.back()->m_data.m_value.object->operator[](val) = discarded);
}
return true;
}
|
O1
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::key(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x10(%rsp), %rdi
callq 0x74a72
movq 0x10(%rbx), %rax
subq 0x8(%rbx), %rax
shrq $0x3, %rax
movl %eax, 0xc(%rsp)
movb $0x4, 0xb(%rsp)
cmpq $0x0, 0x90(%rbx)
je 0x808a4
leaq 0x80(%rbx), %rdi
leaq 0xc(%rsp), %rsi
leaq 0xb(%rsp), %rdx
leaq 0x10(%rsp), %rcx
callq *0x98(%rbx)
movl %eax, %ebp
leaq 0x48(%rbx), %rdi
movzbl %al, %esi
callq 0x8002c
testb %bpl, %bpl
je 0x80882
movq 0x10(%rbx), %rax
cmpq $0x0, -0x8(%rax)
je 0x80882
leaq 0xa8(%rbx), %rsi
leaq 0x20(%rsp), %rdi
callq 0x57948
movq 0x10(%rbx), %rax
movq -0x8(%rax), %rax
movq 0x8(%rax), %rdi
movq %r14, %rsi
callq 0x81e04
leaq 0x20(%rsp), %r14
movq %rax, %rdi
movq %r14, %rsi
callq 0x56e60
movq %rax, 0x70(%rbx)
movq %r14, %rdi
xorl %esi, %esi
callq 0x449aa
movq %r14, %rdi
callq 0x45236
leaq 0x10(%rsp), %rbx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x449aa
movq %rbx, %rdi
callq 0x45236
movb $0x1, %al
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
callq 0x1f3e0
movq %rax, %rbx
leaq 0x20(%rsp), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x449aa
movq %r14, %rdi
callq 0x45236
jmp 0x808c8
movq %rax, %rbx
leaq 0x10(%rsp), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x449aa
movq %r14, %rdi
callq 0x45236
movq %rbx, %rdi
callq 0x20380
nop
|
_ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE3keyERSB_:
push rbp
push r14
push rbx
sub rsp, 30h
mov r14, rsi
mov rbx, rdi
lea rdi, [rsp+48h+var_38]
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SH_EE5valueEiE4typeELi0EEEOT_
mov rax, [rbx+10h]
sub rax, [rbx+8]
shr rax, 3
mov [rsp+48h+var_3C], eax
mov [rsp+48h+var_3D], 4
cmp qword ptr [rbx+90h], 0
jz loc_808A4
lea rdi, [rbx+80h]
lea rsi, [rsp+48h+var_3C]
lea rdx, [rsp+48h+var_3D]
lea rcx, [rsp+48h+var_38]
call qword ptr [rbx+98h]
mov ebp, eax
lea rdi, [rbx+48h]
movzx esi, al
call _ZNSt6vectorIbSaIbEE9push_backEb; std::vector<bool>::push_back(bool)
test bpl, bpl
jz short loc_80882
mov rax, [rbx+10h]
cmp qword ptr [rax-8], 0
jz short loc_80882
lea rsi, [rbx+0A8h]
lea rdi, [rsp+48h+var_28]
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ERKSD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::basic_json(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
mov rax, [rbx+10h]
mov rax, [rax-8]
mov rdi, [rax+8]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEEixERSH_; 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,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<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator[](std::string const&)
lea r14, [rsp+48h+var_28]
mov rdi, rax
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::operator=(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>)
mov [rbx+70h], rax
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
loc_80882:
lea rbx, [rsp+48h+var_38]
mov rdi, rbx
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov al, 1
add rsp, 30h
pop rbx
pop r14
pop rbp
retn
loc_808A4:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
mov rbx, rax
lea r14, [rsp+48h+var_28]
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()
jmp short loc_808C8
mov rbx, rax
loc_808C8:
lea r14, [rsp+48h+var_38]
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rdi, rbx
call __Unwind_Resume
|
char nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::key(
long long a1,
long long a2)
{
unsigned __int8 v2; // bp
long long v3; // rax
char v5; // [rsp+Bh] [rbp-3Dh] BYREF
int v6; // [rsp+Ch] [rbp-3Ch] BYREF
unsigned __int8 v7[16]; // [rsp+10h] [rbp-38h] BYREF
unsigned __int8 v8[40]; // [rsp+20h] [rbp-28h] BYREF
ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SH_EE5valueEiE4typeELi0EEEOT_(
v7,
a2);
v6 = (*(_QWORD *)(a1 + 16) - *(_QWORD *)(a1 + 8)) >> 3;
v5 = 4;
if ( !*(_QWORD *)(a1 + 144) )
std::__throw_bad_function_call();
v2 = (*(long long ( **)(long long, int *, char *, unsigned __int8 *))(a1 + 152))(a1 + 128, &v6, &v5, v7);
std::vector<bool>::push_back(a1 + 72, v2);
if ( v2 && *(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL) )
{
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json(
v8,
(unsigned __int8 *)(a1 + 168));
v3 = 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>>>>::operator[](
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL) + 8LL),
a2);
*(_QWORD *)(a1 + 112) = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator=(
v3,
(long long)v8);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v8);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v8);
}
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v7);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v7);
return 1;
}
|
key:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV R14,RSI
MOV RBX,RDI
LEA RDI,[RSP + 0x10]
CALL 0x00174a72
MOV RAX,qword ptr [RBX + 0x10]
SUB RAX,qword ptr [RBX + 0x8]
SHR RAX,0x3
MOV dword ptr [RSP + 0xc],EAX
MOV byte ptr [RSP + 0xb],0x4
CMP qword ptr [RBX + 0x90],0x0
JZ 0x001808a4
LEA RDI,[RBX + 0x80]
LAB_00180804:
LEA RSI,[RSP + 0xc]
LEA RDX,[RSP + 0xb]
LEA RCX,[RSP + 0x10]
CALL qword ptr [RBX + 0x98]
MOV EBP,EAX
LEA RDI,[RBX + 0x48]
MOVZX ESI,AL
CALL 0x0018002c
TEST BPL,BPL
JZ 0x00180882
MOV RAX,qword ptr [RBX + 0x10]
CMP qword ptr [RAX + -0x8],0x0
JZ 0x00180882
LEA RSI,[RBX + 0xa8]
LEA RDI,[RSP + 0x20]
CALL 0x00157948
MOV RAX,qword ptr [RBX + 0x10]
MOV RAX,qword ptr [RAX + -0x8]
MOV RDI,qword ptr [RAX + 0x8]
LAB_00180854:
MOV RSI,R14
CALL 0x00181e04
LEA R14,[RSP + 0x20]
MOV RDI,RAX
MOV RSI,R14
CALL 0x00156e60
MOV qword ptr [RBX + 0x70],RAX
MOV RDI,R14
XOR ESI,ESI
CALL 0x001449aa
MOV RDI,R14
CALL 0x00145236
LAB_00180882:
LEA RBX,[RSP + 0x10]
MOV RDI,RBX
XOR ESI,ESI
CALL 0x001449aa
MOV RDI,RBX
CALL 0x00145236
MOV AL,0x1
ADD RSP,0x30
POP RBX
POP R14
POP RBP
RET
LAB_001808a4:
CALL 0x0011f3e0
|
/* nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >::key(std::__cxx11::string&) */
int8 __thiscall
nlohmann::json_abi_v3_11_3::detail::
json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::key(json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*this,string *param_1)
{
bool bVar1;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*pbVar2;
int8 uVar3;
int1 local_3d;
int4 local_3c;
data local_38 [16];
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
local_28 [16];
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SH_EE5valueEiE4typeELi0EEEOT_
(local_38);
local_3c = (int4)((ulong)(*(long *)(this + 0x10) - *(long *)(this + 8)) >> 3);
local_3d = 4;
if (*(long *)(this + 0x90) != 0) {
/* try { // try from 00180804 to 00180847 has its CatchHandler @ 001808c5 */
bVar1 = (bool)(**(code **)(this + 0x98))(this + 0x80,&local_3c,&local_3d,local_38);
std::vector<bool,std::allocator<bool>>::push_back
((vector<bool,std::allocator<bool>> *)(this + 0x48),bVar1);
if ((bVar1 != false) && (*(long *)(*(long *)(this + 0x10) + -8) != 0)) {
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::basic_json(local_28,(basic_json *)(this + 0xa8));
/* try { // try from 00180854 to 0018085b has its CatchHandler @ 001808a9 */
pbVar2 = (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<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>>>>
::operator[](*(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>>>>
**)(*(long *)(*(long *)(this + 0x10) + -8) + 8),param_1);
uVar3 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::operator=(pbVar2,(data *)local_28);
*(int8 *)(this + 0x70) = uVar3;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81((data *)local_28,0));
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data((data *)local_28);
}
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(local_38,0));
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data(local_38);
return 1;
}
/* WARNING: Subroutine does not return */
/* try { // try from 001808a4 to 001808a8 has its CatchHandler @ 001808c5 */
std::__throw_bad_function_call();
}
|
|
9,925 |
rlp_get_uint64
|
corpus-core[P]colibri-stateless/src/chains/eth/verifier/rlp.c
|
INTERNAL uint64_t rlp_get_uint64(bytes_t data, int index) {
uint64_t value = 0;
rlp_decode(&data, index, &data);
if (data.len > 8 || !data.len) return 0;
for (int i = 0; i < data.len; i++)
value |= ((uint64_t) data.data[i]) << ((data.len - i - 1) << 3);
return value;
}
|
O0
|
c
|
rlp_get_uint64:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl %edi, -0x18(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x1c(%rbp)
movq $0x0, -0x28(%rbp)
movl -0x1c(%rbp), %esi
leaq -0x18(%rbp), %rdx
movq %rdx, %rdi
callq 0x36280
cmpl $0x8, -0x18(%rbp)
ja 0x36a05
cmpl $0x0, -0x18(%rbp)
jne 0x36a0f
movq $0x0, -0x8(%rbp)
jmp 0x36a56
movl $0x0, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
cmpl -0x18(%rbp), %eax
jae 0x36a4e
movq -0x10(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movzbl (%rax,%rcx), %eax
movl -0x18(%rbp), %ecx
subl -0x2c(%rbp), %ecx
subl $0x1, %ecx
shll $0x3, %ecx
movl %ecx, %ecx
shlq %cl, %rax
orq -0x28(%rbp), %rax
movq %rax, -0x28(%rbp)
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x36a16
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
|
rlp_get_uint64:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_18], edi
mov [rbp+var_10], rsi
mov [rbp+var_1C], edx
mov [rbp+var_28], 0
mov esi, [rbp+var_1C]
lea rdx, [rbp+var_18]
mov rdi, rdx
call rlp_decode
cmp [rbp+var_18], 8
ja short loc_36A05
cmp [rbp+var_18], 0
jnz short loc_36A0F
loc_36A05:
mov [rbp+var_8], 0
jmp short loc_36A56
loc_36A0F:
mov [rbp+var_2C], 0
loc_36A16:
mov eax, [rbp+var_2C]
cmp eax, [rbp+var_18]
jnb short loc_36A4E
mov rax, [rbp+var_10]
movsxd rcx, [rbp+var_2C]
movzx eax, byte ptr [rax+rcx]
mov ecx, [rbp+var_18]
sub ecx, [rbp+var_2C]
sub ecx, 1
shl ecx, 3
mov ecx, ecx
shl rax, cl
or rax, [rbp+var_28]
mov [rbp+var_28], rax
mov eax, [rbp+var_2C]
add eax, 1
mov [rbp+var_2C], eax
jmp short loc_36A16
loc_36A4E:
mov rax, [rbp+var_28]
mov [rbp+var_8], rax
loc_36A56:
mov rax, [rbp+var_8]
add rsp, 30h
pop rbp
retn
|
long long rlp_get_uint64(unsigned int a1, long long a2, int a3)
{
unsigned int i; // [rsp+4h] [rbp-2Ch]
long long v5; // [rsp+8h] [rbp-28h]
unsigned int v6; // [rsp+18h] [rbp-18h] BYREF
long long v7; // [rsp+20h] [rbp-10h]
v6 = a1;
v7 = a2;
v5 = 0LL;
rlp_decode(&v6, a3, (long long)&v6);
if ( v6 > 8 || !v6 )
return 0LL;
for ( i = 0; i < v6; ++i )
v5 |= (unsigned long long)*(unsigned __int8 *)(v7 + (int)i) << (8 * ((unsigned __int8)v6 - (unsigned __int8)i - 1));
return v5;
}
|
rlp_get_uint64:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV dword ptr [RBP + -0x18],EDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x1c],EDX
MOV qword ptr [RBP + -0x28],0x0
MOV ESI,dword ptr [RBP + -0x1c]
LEA RDX,[RBP + -0x18]
MOV RDI,RDX
CALL 0x00136280
CMP dword ptr [RBP + -0x18],0x8
JA 0x00136a05
CMP dword ptr [RBP + -0x18],0x0
JNZ 0x00136a0f
LAB_00136a05:
MOV qword ptr [RBP + -0x8],0x0
JMP 0x00136a56
LAB_00136a0f:
MOV dword ptr [RBP + -0x2c],0x0
LAB_00136a16:
MOV EAX,dword ptr [RBP + -0x2c]
CMP EAX,dword ptr [RBP + -0x18]
JNC 0x00136a4e
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,dword ptr [RBP + -0x2c]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV ECX,dword ptr [RBP + -0x18]
SUB ECX,dword ptr [RBP + -0x2c]
SUB ECX,0x1
SHL ECX,0x3
MOV ECX,ECX
SHL RAX,CL
OR RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x28],RAX
MOV EAX,dword ptr [RBP + -0x2c]
ADD EAX,0x1
MOV dword ptr [RBP + -0x2c],EAX
JMP 0x00136a16
LAB_00136a4e:
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x8],RAX
LAB_00136a56:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x30
POP RBP
RET
|
ulong rlp_get_uint64(uint param_1,long param_2,int4 param_3)
{
uint local_34;
ulong local_30;
uint local_20 [2];
long local_18;
ulong local_10;
local_30 = 0;
local_20[0] = param_1;
local_18 = param_2;
rlp_decode(local_20,param_3);
if ((local_20[0] < 9) && (local_20[0] != 0)) {
for (local_34 = 0; local_34 < local_20[0]; local_34 = local_34 + 1) {
local_30 = (ulong)*(byte *)(local_18 + (int)local_34) <<
((((char)local_20[0] - (char)local_34) + -1) * '\b' & 0x3fU) | local_30;
}
local_10 = local_30;
}
else {
local_10 = 0;
}
return local_10;
}
|
|
9,926 |
rlp_get_uint64
|
corpus-core[P]colibri-stateless/src/chains/eth/verifier/rlp.c
|
INTERNAL uint64_t rlp_get_uint64(bytes_t data, int index) {
uint64_t value = 0;
rlp_decode(&data, index, &data);
if (data.len > 8 || !data.len) return 0;
for (int i = 0; i < data.len; i++)
value |= ((uint64_t) data.data[i]) << ((data.len - i - 1) << 3);
return value;
}
|
O2
|
c
|
rlp_get_uint64:
pushq %rbx
subq $0x10, %rsp
movq %rsp, %rbx
movl %edi, (%rbx)
movq %rsi, 0x8(%rbx)
movq %rbx, %rdi
movl %edx, %esi
movq %rbx, %rdx
callq 0x2de74
movl (%rbx), %edx
leal -0x1(%rdx), %eax
cmpl $0x7, %eax
ja 0x2e247
movq 0x8(%rsp), %rsi
leal -0x8(,%rdx,8), %ecx
xorl %edi, %edi
xorl %eax, %eax
cmpq %rdi, %rdx
je 0x2e249
movzbl (%rsi,%rdi), %r8d
shlq %cl, %r8
orq %r8, %rax
incq %rdi
addl $-0x8, %ecx
jmp 0x2e22f
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
retq
nop
|
rlp_get_uint64:
push rbx
sub rsp, 10h
mov rbx, rsp
mov [rbx], edi
mov [rbx+8], rsi
mov rdi, rbx
mov esi, edx
mov rdx, rbx
call rlp_decode
mov edx, [rbx]
lea eax, [rdx-1]
cmp eax, 7
ja short loc_2E247
mov rsi, [rsp+18h+var_10]
lea ecx, ds:0FFFFFFFFFFFFFFF8h[rdx*8]
xor edi, edi
xor eax, eax
loc_2E22F:
cmp rdx, rdi
jz short loc_2E249
movzx r8d, byte ptr [rsi+rdi]
shl r8, cl
or rax, r8
inc rdi
add ecx, 0FFFFFFF8h
jmp short loc_2E22F
loc_2E247:
xor eax, eax
loc_2E249:
add rsp, 10h
pop rbx
retn
|
long long rlp_get_uint64(unsigned int a1, long long a2, int a3)
{
unsigned int v3; // ecx
long long v4; // rdi
long long result; // rax
unsigned int v6; // [rsp+0h] [rbp-18h] BYREF
long long v7; // [rsp+8h] [rbp-10h]
v6 = a1;
v7 = a2;
rlp_decode(&v6, a3, (long long)&v6);
if ( v6 - 1 > 7 )
return 0LL;
v3 = 8 * v6 - 8;
v4 = 0LL;
result = 0LL;
while ( v6 != v4 )
{
result |= (unsigned long long)*(unsigned __int8 *)(v7 + v4++) << v3;
v3 -= 8;
}
return result;
}
|
rlp_get_uint64:
PUSH RBX
SUB RSP,0x10
MOV RBX,RSP
MOV dword ptr [RBX],EDI
MOV qword ptr [RBX + 0x8],RSI
MOV RDI,RBX
MOV ESI,EDX
MOV RDX,RBX
CALL 0x0012de74
MOV EDX,dword ptr [RBX]
LEA EAX,[RDX + -0x1]
CMP EAX,0x7
JA 0x0012e247
MOV RSI,qword ptr [RSP + 0x8]
LEA ECX,[-0x8 + RDX*0x8]
XOR EDI,EDI
XOR EAX,EAX
LAB_0012e22f:
CMP RDX,RDI
JZ 0x0012e249
MOVZX R8D,byte ptr [RSI + RDI*0x1]
SHL R8,CL
OR RAX,R8
INC RDI
ADD ECX,-0x8
JMP 0x0012e22f
LAB_0012e247:
XOR EAX,EAX
LAB_0012e249:
ADD RSP,0x10
POP RBX
RET
|
ulong rlp_get_uint64(uint param_1,long param_2,int4 param_3)
{
ulong uVar1;
int iVar2;
ulong uVar3;
uint local_18 [2];
long local_10;
local_18[0] = param_1;
local_10 = param_2;
rlp_decode(local_18,param_3,local_18);
if (local_18[0] - 1 < 8) {
iVar2 = local_18[0] * 8;
uVar1 = 0;
for (uVar3 = 0; iVar2 = iVar2 + -8, local_18[0] != uVar3; uVar3 = uVar3 + 1) {
uVar1 = uVar1 | (ulong)*(byte *)(local_10 + uVar3) << ((byte)iVar2 & 0x3f);
}
}
else {
uVar1 = 0;
}
return uVar1;
}
|
|
9,927 |
rlp_get_uint64
|
corpus-core[P]colibri-stateless/src/chains/eth/verifier/rlp.c
|
INTERNAL uint64_t rlp_get_uint64(bytes_t data, int index) {
uint64_t value = 0;
rlp_decode(&data, index, &data);
if (data.len > 8 || !data.len) return 0;
for (int i = 0; i < data.len; i++)
value |= ((uint64_t) data.data[i]) << ((data.len - i - 1) << 3);
return value;
}
|
O3
|
c
|
rlp_get_uint64:
pushq %rbx
subq $0x10, %rsp
movq %rsp, %rbx
movl %edi, (%rbx)
movq %rsi, 0x8(%rbx)
movq %rbx, %rdi
movl %edx, %esi
movq %rbx, %rdx
callq 0x2f56c
movl (%rbx), %edx
leal -0x1(%rdx), %eax
cmpl $0x7, %eax
ja 0x2fa4d
movq 0x8(%rsp), %rsi
leal -0x8(,%rdx,8), %ecx
xorl %edi, %edi
xorl %eax, %eax
movzbl (%rsi,%rdi), %r8d
shlq %cl, %r8
orq %r8, %rax
incq %rdi
addl $-0x8, %ecx
cmpq %rdi, %rdx
jne 0x2fa35
jmp 0x2fa4f
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
retq
nopl (%rax)
|
rlp_get_uint64:
push rbx
sub rsp, 10h
mov rbx, rsp
mov [rbx], edi
mov [rbx+8], rsi
mov rdi, rbx
mov esi, edx
mov rdx, rbx
call rlp_decode
mov edx, [rbx]
lea eax, [rdx-1]
cmp eax, 7
ja short loc_2FA4D
mov rsi, [rsp+18h+var_10]
lea ecx, ds:0FFFFFFFFFFFFFFF8h[rdx*8]
xor edi, edi
xor eax, eax
loc_2FA35:
movzx r8d, byte ptr [rsi+rdi]
shl r8, cl
or rax, r8
inc rdi
add ecx, 0FFFFFFF8h
cmp rdx, rdi
jnz short loc_2FA35
jmp short loc_2FA4F
loc_2FA4D:
xor eax, eax
loc_2FA4F:
add rsp, 10h
pop rbx
retn
|
long long rlp_get_uint64(unsigned int a1, long long a2, int a3)
{
unsigned int v3; // ecx
long long v4; // rdi
long long result; // rax
unsigned int v6; // [rsp+0h] [rbp-18h] BYREF
long long v7; // [rsp+8h] [rbp-10h]
v6 = a1;
v7 = a2;
rlp_decode(&v6, a3, (long long)&v6);
if ( v6 - 1 > 7 )
return 0LL;
v3 = 8 * v6 - 8;
v4 = 0LL;
result = 0LL;
do
{
result |= (unsigned long long)*(unsigned __int8 *)(v7 + v4++) << v3;
v3 -= 8;
}
while ( v6 != v4 );
return result;
}
|
rlp_get_uint64:
PUSH RBX
SUB RSP,0x10
MOV RBX,RSP
MOV dword ptr [RBX],EDI
MOV qword ptr [RBX + 0x8],RSI
MOV RDI,RBX
MOV ESI,EDX
MOV RDX,RBX
CALL 0x0012f56c
MOV EDX,dword ptr [RBX]
LEA EAX,[RDX + -0x1]
CMP EAX,0x7
JA 0x0012fa4d
MOV RSI,qword ptr [RSP + 0x8]
LEA ECX,[-0x8 + RDX*0x8]
XOR EDI,EDI
XOR EAX,EAX
LAB_0012fa35:
MOVZX R8D,byte ptr [RSI + RDI*0x1]
SHL R8,CL
OR RAX,R8
INC RDI
ADD ECX,-0x8
CMP RDX,RDI
JNZ 0x0012fa35
JMP 0x0012fa4f
LAB_0012fa4d:
XOR EAX,EAX
LAB_0012fa4f:
ADD RSP,0x10
POP RBX
RET
|
ulong rlp_get_uint64(uint param_1,long param_2,int4 param_3)
{
ulong uVar1;
int iVar2;
ulong uVar3;
uint local_18 [2];
long local_10;
local_18[0] = param_1;
local_10 = param_2;
rlp_decode(local_18,param_3,local_18);
if (local_18[0] - 1 < 8) {
iVar2 = local_18[0] * 8;
uVar3 = 0;
uVar1 = 0;
do {
iVar2 = iVar2 + -8;
uVar1 = uVar1 | (ulong)*(byte *)(local_10 + uVar3) << ((byte)iVar2 & 0x3f);
uVar3 = uVar3 + 1;
} while (local_18[0] != uVar3);
}
else {
uVar1 = 0;
}
return uVar1;
}
|
|
9,928 |
bitmap_set_above
|
eloqsql/mysys/my_bitmap.c
|
void bitmap_set_above(MY_BITMAP *map, uint from_byte, uint use_bit)
{
uchar use_byte= use_bit ? 0xff : 0;
uchar *to= (uchar *)map->bitmap + from_byte;
uchar *end= (uchar *)map->bitmap + (map->n_bits+7)/8;
while (to < end)
*to++= use_byte;
}
|
O3
|
c
|
bitmap_set_above:
pushq %rbp
movq %rsp, %rbp
movl 0x1c(%rdi), %eax
addl $0x7, %eax
shrl $0x3, %eax
cmpl %esi, %eax
jbe 0x9d771
movl %eax, %eax
movq (%rdi), %rcx
movl %esi, %esi
leaq (%rcx,%rsi), %rdi
addq %rcx, %rsi
incq %rsi
addq %rcx, %rax
cmpq %rax, %rsi
cmovaq %rsi, %rax
subq %rdi, %rax
xorl %esi, %esi
negl %edx
sbbl %esi, %esi
movq %rax, %rdx
popq %rbp
jmp 0x292a0
popq %rbp
retq
|
bitmap_set_above:
push rbp
mov rbp, rsp
mov eax, [rdi+1Ch]
add eax, 7
shr eax, 3
cmp eax, esi
jbe short loc_9D771
mov eax, eax
mov rcx, [rdi]
mov esi, esi
lea rdi, [rcx+rsi]
add rsi, rcx
inc rsi
add rax, rcx
cmp rsi, rax
cmova rax, rsi
sub rax, rdi
xor esi, esi
neg edx
sbb esi, esi
mov rdx, rax
pop rbp
jmp _memset
loc_9D771:
pop rbp
retn
|
long long bitmap_set_above(long long *a1, unsigned int a2, int a3)
{
long long result; // rax
long long v4; // rcx
long long v5; // rdi
unsigned long long v6; // rax
result = (unsigned int)(*((_DWORD *)a1 + 7) + 7) >> 3;
if ( (unsigned int)result > a2 )
{
v4 = *a1;
v5 = *a1 + a2;
v6 = v4 + (unsigned int)result;
if ( v5 + 1 > v6 )
v6 = v5 + 1;
return memset(v5, (unsigned int)-(a3 != 0), v6 - v5);
}
return result;
}
|
bitmap_set_above:
PUSH RBP
MOV RBP,RSP
MOV EAX,dword ptr [RDI + 0x1c]
ADD EAX,0x7
SHR EAX,0x3
CMP EAX,ESI
JBE 0x0019d771
MOV EAX,EAX
MOV RCX,qword ptr [RDI]
MOV ESI,ESI
LEA RDI,[RCX + RSI*0x1]
ADD RSI,RCX
INC RSI
ADD RAX,RCX
CMP RSI,RAX
CMOVA RAX,RSI
SUB RAX,RDI
XOR ESI,ESI
NEG EDX
SBB ESI,ESI
MOV RDX,RAX
POP RBP
JMP 0x001292a0
LAB_0019d771:
POP RBP
RET
|
void bitmap_set_above(long *param_1,uint param_2,int param_3)
{
void *__s;
long lVar1;
uint uVar2;
ulong uVar3;
ulong uVar4;
uVar2 = *(int *)((long)param_1 + 0x1c) + 7U >> 3;
if (param_2 < uVar2) {
lVar1 = *param_1;
__s = (void *)(lVar1 + (ulong)param_2);
uVar4 = (ulong)param_2 + lVar1 + 1;
uVar3 = (ulong)uVar2 + lVar1;
if (uVar3 < uVar4) {
uVar3 = uVar4;
}
memset(__s,-(uint)(param_3 != 0),uVar3 - (long)__s);
return;
}
return;
}
|
|
9,929 |
my_hash_sort_utf16_nopad
|
eloqsql/strings/ctype-ucs2.c
|
static void
my_hash_sort_utf16_nopad(CHARSET_INFO *cs,
const uchar *s, size_t slen,
ulong *nr1, ulong *nr2)
{
my_wc_t wc;
my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc;
int res;
const uchar *e= s + slen;
MY_UNICASE_INFO *uni_plane= cs->caseinfo;
register ulong m1= *nr1, m2= *nr2;
while ((s < e) && (res= mb_wc(cs, &wc, (uchar *) s, (uchar *) e)) > 0)
{
my_tosort_utf16(uni_plane, &wc);
MY_HASH_ADD_16(m1, m2, wc);
s+= res;
}
*nr1= m1;
*nr2= m2;
}
|
O0
|
c
|
my_hash_sort_utf16_nopad:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
addq -0x18(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x8(%rbp), %rax
movq 0x78(%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x60(%rbp)
movq -0x10(%rbp), %rcx
xorl %eax, %eax
cmpq -0x48(%rbp), %rcx
movb %al, -0x61(%rbp)
jae 0x1332de
movq -0x38(%rbp), %rax
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x48(%rbp), %rcx
leaq -0x30(%rbp), %rsi
callq *%rax
movl %eax, -0x3c(%rbp)
cmpl $0x0, %eax
setg %al
movb %al, -0x61(%rbp)
movb -0x61(%rbp), %al
testb $0x1, %al
jne 0x1332ea
jmp 0x133384
movq -0x50(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x1333a0
jmp 0x1332f9
movq -0x58(%rbp), %rax
andq $0x3f, %rax
addq -0x60(%rbp), %rax
movq -0x30(%rbp), %rcx
andq $0xff, %rcx
imulq %rcx, %rax
movq -0x58(%rbp), %rcx
shlq $0x8, %rcx
addq %rcx, %rax
xorq -0x58(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x60(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x60(%rbp)
jmp 0x133335
movq -0x58(%rbp), %rax
andq $0x3f, %rax
addq -0x60(%rbp), %rax
movq -0x30(%rbp), %rcx
shrq $0x8, %rcx
imulq %rcx, %rax
movq -0x58(%rbp), %rcx
shlq $0x8, %rcx
addq %rcx, %rax
xorq -0x58(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x60(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x60(%rbp)
jmp 0x13336e
movl -0x3c(%rbp), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
jmp 0x1332ad
movq -0x58(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movq -0x60(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
addq $0x70, %rsp
popq %rbp
retq
|
my_hash_sort_utf16_nopad:
push rbp
mov rbp, rsp
sub rsp, 70h
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 rax, [rax+0B8h]
mov rax, [rax+28h]
mov [rbp+var_38], rax
mov rax, [rbp+var_10]
add rax, [rbp+var_18]
mov [rbp+var_48], rax
mov rax, [rbp+var_8]
mov rax, [rax+78h]
mov [rbp+var_50], rax
mov rax, [rbp+var_20]
mov rax, [rax]
mov [rbp+var_58], rax
mov rax, [rbp+var_28]
mov rax, [rax]
mov [rbp+var_60], rax
loc_1332AD:
mov rcx, [rbp+var_10]
xor eax, eax
cmp rcx, [rbp+var_48]
mov [rbp+var_61], al
jnb short loc_1332DE
mov rax, [rbp+var_38]
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov rcx, [rbp+var_48]
lea rsi, [rbp+var_30]
call rax
mov [rbp+var_3C], eax
cmp eax, 0
setnle al
mov [rbp+var_61], al
loc_1332DE:
mov al, [rbp+var_61]
test al, 1
jnz short loc_1332EA
jmp loc_133384
loc_1332EA:
mov rdi, [rbp+var_50]
lea rsi, [rbp+var_30]
call my_tosort_utf16
jmp short $+2
loc_1332F9:
mov rax, [rbp+var_58]
and rax, 3Fh
add rax, [rbp+var_60]
mov rcx, [rbp+var_30]
and rcx, 0FFh
imul rax, rcx
mov rcx, [rbp+var_58]
shl rcx, 8
add rax, rcx
xor rax, [rbp+var_58]
mov [rbp+var_58], rax
mov rax, [rbp+var_60]
add rax, 3
mov [rbp+var_60], rax
jmp short $+2
loc_133335:
mov rax, [rbp+var_58]
and rax, 3Fh
add rax, [rbp+var_60]
mov rcx, [rbp+var_30]
shr rcx, 8
imul rax, rcx
mov rcx, [rbp+var_58]
shl rcx, 8
add rax, rcx
xor rax, [rbp+var_58]
mov [rbp+var_58], rax
mov rax, [rbp+var_60]
add rax, 3
mov [rbp+var_60], rax
jmp short $+2
loc_13336E:
mov ecx, [rbp+var_3C]
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
jmp loc_1332AD
loc_133384:
mov rcx, [rbp+var_58]
mov rax, [rbp+var_20]
mov [rax], rcx
mov rcx, [rbp+var_60]
mov rax, [rbp+var_28]
mov [rax], rcx
add rsp, 70h
pop rbp
retn
|
_QWORD * my_hash_sort_utf16_nopad(
long long a1,
unsigned long long a2,
long long a3,
unsigned long long *a4,
_QWORD *a5)
{
_QWORD *result; // rax
bool v6; // [rsp+Fh] [rbp-61h]
long long v7; // [rsp+10h] [rbp-60h]
long long v8; // [rsp+10h] [rbp-60h]
unsigned long long v9; // [rsp+18h] [rbp-58h]
long long v10; // [rsp+18h] [rbp-58h]
long long v11; // [rsp+20h] [rbp-50h]
unsigned long long v12; // [rsp+28h] [rbp-48h]
int v13; // [rsp+34h] [rbp-3Ch]
long long ( *v14)(long long, unsigned long long *, unsigned long long, unsigned long long); // [rsp+38h] [rbp-38h]
unsigned long long v15; // [rsp+40h] [rbp-30h] BYREF
_QWORD *v16; // [rsp+48h] [rbp-28h]
unsigned long long *v17; // [rsp+50h] [rbp-20h]
long long v18; // [rsp+58h] [rbp-18h]
unsigned long long v19; // [rsp+60h] [rbp-10h]
long long v20; // [rsp+68h] [rbp-8h]
v20 = a1;
v19 = a2;
v18 = a3;
v17 = a4;
v16 = a5;
v14 = *(long long ( **)(long long, unsigned long long *, unsigned long long, unsigned long long))(*(_QWORD *)(a1 + 184)
+ 40LL);
v12 = a3 + a2;
v11 = *(_QWORD *)(a1 + 120);
v9 = *a4;
v7 = *a5;
while ( 1 )
{
v6 = 0;
if ( v19 < v12 )
{
v13 = v14(v20, &v15, v19, v12);
v6 = v13 > 0;
}
if ( !v6 )
break;
my_tosort_utf16(v11, &v15);
v10 = v9 ^ ((v9 << 8) + (unsigned __int8)v15 * (v7 + (v9 & 0x3F)));
v8 = v7 + 3;
v9 = v10 ^ ((v10 << 8) + (v15 >> 8) * (v8 + (v10 & 0x3F)));
v7 = v8 + 3;
v19 += v13;
}
*v17 = v9;
result = v16;
*v16 = v7;
return result;
}
| |||
9,930 |
my_hash_sort_utf16_nopad
|
eloqsql/strings/ctype-ucs2.c
|
static void
my_hash_sort_utf16_nopad(CHARSET_INFO *cs,
const uchar *s, size_t slen,
ulong *nr1, ulong *nr2)
{
my_wc_t wc;
my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc;
int res;
const uchar *e= s + slen;
MY_UNICASE_INFO *uni_plane= cs->caseinfo;
register ulong m1= *nr1, m2= *nr2;
while ((s < e) && (res= mb_wc(cs, &wc, (uchar *) s, (uchar *) e)) > 0)
{
my_tosort_utf16(uni_plane, &wc);
MY_HASH_ADD_16(m1, m2, wc);
s+= res;
}
*nr1= m1;
*nr2= m2;
}
|
O3
|
c
|
my_hash_sort_utf16_nopad:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, -0x40(%rbp)
movq (%rcx), %rbx
movq %r8, -0x48(%rbp)
movq (%r8), %r14
testq %rdx, %rdx
jle 0xc542d
movq %rdx, %r15
movq %rsi, %r12
movq 0x78(%rdi), %rax
movq %rax, -0x30(%rbp)
movq 0xb8(%rdi), %rax
movq 0x28(%rax), %rax
movq %rax, -0x50(%rbp)
addq %rsi, %r15
movq %rdi, %r13
leaq -0x38(%rbp), %rsi
movq %r12, %rdx
movq %r15, %rcx
callq *-0x50(%rbp)
testl %eax, %eax
jle 0xc542d
movq -0x38(%rbp), %rdx
movl $0xfffd, %esi # imm = 0xFFFD
movq -0x30(%rbp), %rcx
cmpq (%rcx), %rdx
movq %r13, %rdi
ja 0xc53d6
movq -0x30(%rbp), %rcx
movq 0x8(%rcx), %rsi
movq %rdx, %rcx
shrq $0x8, %rcx
movq (%rsi,%rcx,8), %rsi
testq %rsi, %rsi
je 0xc53e2
movzbl %dl, %ecx
leaq (%rcx,%rcx,2), %rcx
movl 0x8(%rsi,%rcx,4), %esi
movq %rsi, -0x38(%rbp)
movl %esi, %ecx
shrl $0x8, %ecx
movq %rsi, %rdx
movl %ebx, %esi
andl $0x3f, %esi
addq %r14, %rsi
movzbl %dl, %edx
imulq %rsi, %rdx
movq %rbx, %rsi
shlq $0x8, %rsi
addq %rdx, %rsi
xorq %rbx, %rsi
movl %esi, %edx
andl $0x3f, %edx
addq %r14, %rdx
addq $0x3, %rdx
imulq %rcx, %rdx
movq %rsi, %rbx
shlq $0x8, %rbx
addq %rdx, %rbx
xorq %rsi, %rbx
addq $0x6, %r14
movl %eax, %eax
addq %rax, %r12
cmpq %r15, %r12
jb 0xc5386
movq -0x40(%rbp), %rax
movq %rbx, (%rax)
movq -0x48(%rbp), %rax
movq %r14, (%rax)
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
my_hash_sort_utf16_nopad:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov [rbp+var_40], rcx
mov rbx, [rcx]
mov [rbp+var_48], r8
mov r14, [r8]
test rdx, rdx
jle loc_C542D
mov r15, rdx
mov r12, rsi
mov rax, [rdi+78h]
mov [rbp+var_30], rax
mov rax, [rdi+0B8h]
mov rax, [rax+28h]
mov [rbp+var_50], rax
add r15, rsi
loc_C5386:
mov r13, rdi
lea rsi, [rbp+var_38]
mov rdx, r12
mov rcx, r15
call [rbp+var_50]
test eax, eax
jle loc_C542D
mov rdx, [rbp+var_38]
mov esi, 0FFFDh
mov rcx, [rbp+var_30]
cmp rdx, [rcx]
mov rdi, r13
ja short loc_C53D6
mov rcx, [rbp+var_30]
mov rsi, [rcx+8]
mov rcx, rdx
shr rcx, 8
mov rsi, [rsi+rcx*8]
test rsi, rsi
jz short loc_C53E2
movzx ecx, dl
lea rcx, [rcx+rcx*2]
mov esi, [rsi+rcx*4+8]
loc_C53D6:
mov [rbp+var_38], rsi
mov ecx, esi
shr ecx, 8
mov rdx, rsi
loc_C53E2:
mov esi, ebx
and esi, 3Fh
add rsi, r14
movzx edx, dl
imul rdx, rsi
mov rsi, rbx
shl rsi, 8
add rsi, rdx
xor rsi, rbx
mov edx, esi
and edx, 3Fh
add rdx, r14
add rdx, 3
imul rdx, rcx
mov rbx, rsi
shl rbx, 8
add rbx, rdx
xor rbx, rsi
add r14, 6
mov eax, eax
add r12, rax
cmp r12, r15
jb loc_C5386
loc_C542D:
mov rax, [rbp+var_40]
mov [rax], rbx
mov rax, [rbp+var_48]
mov [rax], r14
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
_QWORD * my_hash_sort_utf16_nopad(long long a1, unsigned long long a2, long long a3, long long *a4, _QWORD *a5)
{
long long v5; // rbx
long long v6; // r14
unsigned long long v7; // r12
unsigned long long v8; // r15
int v9; // eax
unsigned __int8 v10; // dl
long long v11; // rsi
unsigned long long v12; // rcx
long long v13; // rsi
long long v14; // rsi
_QWORD *result; // rax
long long ( *v16)(long long, unsigned long long *, unsigned long long, unsigned long long); // [rsp+0h] [rbp-50h]
unsigned long long v19; // [rsp+18h] [rbp-38h] BYREF
unsigned long long *v20; // [rsp+20h] [rbp-30h]
v5 = *a4;
v6 = *a5;
if ( a3 > 0 )
{
v7 = a2;
v20 = *(unsigned long long **)(a1 + 120);
v16 = *(long long ( **)(long long, unsigned long long *, unsigned long long, unsigned long long))(*(_QWORD *)(a1 + 184) + 40LL);
v8 = a2 + a3;
while ( 1 )
{
v9 = v16(a1, &v19, v7, v8);
if ( v9 <= 0 )
goto LABEL_9;
v10 = v19;
v11 = 65533LL;
if ( v19 > *v20 )
goto LABEL_7;
v12 = v19 >> 8;
v13 = *(_QWORD *)(v20[1] + 8 * (v19 >> 8));
if ( v13 )
break;
LABEL_8:
v14 = v5 ^ ((v6 + (v5 & 0x3F)) * v10 + (v5 << 8));
v5 = v14 ^ (v12 * (v6 + (((unsigned __int8)v5 ^ (unsigned __int8)((v6 + (v5 & 0x3F)) * v10)) & 0x3F) + 3)
+ (v14 << 8));
v6 += 6LL;
v7 += (unsigned int)v9;
if ( v7 >= v8 )
goto LABEL_9;
}
v11 = *(unsigned int *)(v13 + 12LL * (unsigned __int8)v19 + 8);
LABEL_7:
v19 = v11;
v12 = (unsigned int)v11 >> 8;
v10 = v11;
goto LABEL_8;
}
LABEL_9:
*a4 = v5;
result = a5;
*a5 = v6;
return result;
}
|
my_hash_sort_utf16_nopad:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV qword ptr [RBP + -0x40],RCX
MOV RBX,qword ptr [RCX]
MOV qword ptr [RBP + -0x48],R8
MOV R14,qword ptr [R8]
TEST RDX,RDX
JLE 0x001c542d
MOV R15,RDX
MOV R12,RSI
MOV RAX,qword ptr [RDI + 0x78]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RDI + 0xb8]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x50],RAX
ADD R15,RSI
LAB_001c5386:
MOV R13,RDI
LEA RSI,[RBP + -0x38]
MOV RDX,R12
MOV RCX,R15
CALL qword ptr [RBP + -0x50]
TEST EAX,EAX
JLE 0x001c542d
MOV RDX,qword ptr [RBP + -0x38]
MOV ESI,0xfffd
MOV RCX,qword ptr [RBP + -0x30]
CMP RDX,qword ptr [RCX]
MOV RDI,R13
JA 0x001c53d6
MOV RCX,qword ptr [RBP + -0x30]
MOV RSI,qword ptr [RCX + 0x8]
MOV RCX,RDX
SHR RCX,0x8
MOV RSI,qword ptr [RSI + RCX*0x8]
TEST RSI,RSI
JZ 0x001c53e2
MOVZX ECX,DL
LEA RCX,[RCX + RCX*0x2]
MOV ESI,dword ptr [RSI + RCX*0x4 + 0x8]
LAB_001c53d6:
MOV qword ptr [RBP + -0x38],RSI
MOV ECX,ESI
SHR ECX,0x8
MOV RDX,RSI
LAB_001c53e2:
MOV ESI,EBX
AND ESI,0x3f
ADD RSI,R14
MOVZX EDX,DL
IMUL RDX,RSI
MOV RSI,RBX
SHL RSI,0x8
ADD RSI,RDX
XOR RSI,RBX
MOV EDX,ESI
AND EDX,0x3f
ADD RDX,R14
ADD RDX,0x3
IMUL RDX,RCX
MOV RBX,RSI
SHL RBX,0x8
ADD RBX,RDX
XOR RBX,RSI
ADD R14,0x6
MOV EAX,EAX
ADD R12,RAX
CMP R12,R15
JC 0x001c5386
LAB_001c542d:
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RAX],RBX
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RAX],R14
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void my_hash_sort_utf16_nopad(long param_1,ulong param_2,long param_3,ulong *param_4,long *param_5)
{
code *pcVar1;
long lVar2;
uint uVar3;
ulong uVar4;
ulong uVar5;
ulong uVar6;
long lVar7;
ulong uVar8;
ulong local_40;
ulong *local_38;
uVar6 = *param_4;
lVar7 = *param_5;
if (0 < param_3) {
local_38 = *(ulong **)(param_1 + 0x78);
pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28);
uVar8 = param_3 + param_2;
do {
uVar3 = (*pcVar1)(param_1,&local_40,param_2,uVar8);
if ((int)uVar3 < 1) break;
uVar5 = 0xfffd;
if (*local_38 < local_40) {
LAB_001c53d6:
uVar4 = uVar5 >> 8;
local_40 = uVar5;
}
else {
uVar4 = local_40 >> 8;
lVar2 = *(long *)(local_38[1] + uVar4 * 8);
if (lVar2 != 0) {
uVar5 = (ulong)*(uint *)(lVar2 + 8 + (local_40 & 0xff) * 0xc);
goto LAB_001c53d6;
}
}
uVar6 = uVar6 * 0x100 + (local_40 & 0xff) * ((ulong)((uint)uVar6 & 0x3f) + lVar7) ^ uVar6;
uVar6 = uVar6 * 0x100 + ((ulong)((uint)uVar6 & 0x3f) + lVar7 + 3) * uVar4 ^ uVar6;
lVar7 = lVar7 + 6;
param_2 = param_2 + uVar3;
} while (param_2 < uVar8);
}
*param_4 = uVar6;
*param_5 = lVar7;
return;
}
|
|
9,931 |
translog_page_validator
|
eloqsql/storage/maria/ma_loghandler.c
|
static my_bool translog_page_validator(int res, PAGECACHE_IO_HOOK_ARGS *args)
{
uchar *page= args->page;
pgcache_page_no_t page_no= args->pageno;
uint this_page_page_overhead;
uint flags;
uchar *page_pos;
TRANSLOG_FILE *data= (TRANSLOG_FILE *) args->data;
#ifndef DBUG_OFF
pgcache_page_no_t offset= page_no * TRANSLOG_PAGE_SIZE;
#endif
DBUG_ENTER("translog_page_validator");
data->was_recovered= 0;
if (res)
{
DBUG_RETURN(1);
}
if ((pgcache_page_no_t) uint3korr(page) != page_no ||
(uint32) uint3korr(page + 3) != data->number)
{
DBUG_PRINT("error", ("Page " LSN_FMT ": "
"page address written in the page is incorrect: "
"File %lu instead of %lu or page %lu instead of %lu",
(uint)data->number, (uint)offset,
(ulong) uint3korr(page + 3), (ulong) data->number,
(ulong) uint3korr(page),
(ulong) page_no));
DBUG_RETURN(1);
}
flags= (uint)(page[TRANSLOG_PAGE_FLAGS]);
this_page_page_overhead= page_overhead[flags];
if (flags & ~(TRANSLOG_PAGE_CRC | TRANSLOG_SECTOR_PROTECTION |
TRANSLOG_RECORD_CRC))
{
DBUG_PRINT("error", ("Page " LSN_FMT ": "
"Garbage in the page flags field detected : %x",
(uint) data->number, (uint) offset,
(uint) flags));
DBUG_RETURN(1);
}
page_pos= page + (3 + 3 + 1);
if (flags & TRANSLOG_PAGE_CRC)
{
uint32 crc= translog_crc(page + this_page_page_overhead,
TRANSLOG_PAGE_SIZE -
this_page_page_overhead);
if (crc != uint4korr(page_pos))
{
DBUG_PRINT("error", ("Page " LSN_FMT ": "
"CRC mismatch: calculated: %lx on the page %lx",
(uint) data->number, (uint) offset,
(ulong) crc, (ulong) uint4korr(page_pos)));
DBUG_RETURN(1);
}
page_pos+= CRC_SIZE; /* Skip crc */
}
if (flags & TRANSLOG_SECTOR_PROTECTION &&
translog_check_sector_protection(page, data))
{
DBUG_RETURN(1);
}
DBUG_RETURN(0);
}
|
O0
|
c
|
translog_page_validator:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movb $0x0, 0x50(%rax)
cmpl $0x0, -0x8(%rbp)
je 0x36b1b
jmp 0x36b12
movb $0x1, -0x1(%rbp)
jmp 0x36c36
movq -0x18(%rbp), %rax
movzbl (%rax), %eax
movq -0x18(%rbp), %rcx
movzbl 0x1(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x18(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movl %eax, %eax
cmpq -0x20(%rbp), %rax
jne 0x36b6e
movq -0x18(%rbp), %rax
movzbl 0x3(%rax), %eax
movq -0x18(%rbp), %rcx
movzbl 0x4(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x18(%rbp), %rcx
movzbl 0x5(%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movq -0x38(%rbp), %rcx
cmpl (%rcx), %eax
je 0x36b7d
jmp 0x36b70
jmp 0x36b72
jmp 0x36b74
movb $0x1, -0x1(%rbp)
jmp 0x36c36
movq -0x18(%rbp), %rax
movzbl 0x6(%rax), %eax
movl %eax, -0x28(%rbp)
movl -0x28(%rbp), %eax
movl %eax, %ecx
leaq 0xc42fcc(%rip), %rax # 0xc79b60
movl (%rax,%rcx,4), %eax
movl %eax, -0x24(%rbp)
movl -0x28(%rbp), %eax
andl $-0x8, %eax
cmpl $0x0, %eax
je 0x36bb4
jmp 0x36ba7
jmp 0x36ba9
jmp 0x36bab
movb $0x1, -0x1(%rbp)
jmp 0x36c36
movq -0x18(%rbp), %rax
addq $0x7, %rax
movq %rax, -0x30(%rbp)
movl -0x28(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x36c08
movq -0x18(%rbp), %rdi
movl -0x24(%rbp), %eax
addq %rax, %rdi
movl $0x2000, %esi # imm = 0x2000
subl -0x24(%rbp), %esi
callq 0x36c40
movl %eax, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
movq -0x30(%rbp), %rcx
cmpl (%rcx), %eax
je 0x36bfc
jmp 0x36bf2
jmp 0x36bf4
jmp 0x36bf6
movb $0x1, -0x1(%rbp)
jmp 0x36c36
movq -0x30(%rbp), %rax
addq $0x4, %rax
movq %rax, -0x30(%rbp)
movl -0x28(%rbp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x36c30
movq -0x18(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x36c70
movsbl %al, %eax
cmpl $0x0, %eax
je 0x36c30
jmp 0x36c2a
movb $0x1, -0x1(%rbp)
jmp 0x36c36
jmp 0x36c32
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x40, %rsp
popq %rbp
retq
nop
|
translog_page_validator:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], edi
mov [rbp+var_10], rsi
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_18], rax
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov [rbp+var_20], rax
mov rax, [rbp+var_10]
mov rax, [rax+10h]
mov [rbp+var_38], rax
mov rax, [rbp+var_38]
mov byte ptr [rax+50h], 0
cmp [rbp+var_8], 0
jz short loc_36B1B
jmp short $+2
loc_36B12:
mov [rbp+var_1], 1
jmp loc_36C36
loc_36B1B:
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax]
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+1]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+2]
shl ecx, 10h
or eax, ecx
mov eax, eax
cmp rax, [rbp+var_20]
jnz short loc_36B6E
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax+3]
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+4]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+5]
shl ecx, 10h
or eax, ecx
mov rcx, [rbp+var_38]
cmp eax, [rcx]
jz short loc_36B7D
loc_36B6E:
jmp short $+2
loc_36B70:
jmp short $+2
loc_36B72:
jmp short $+2
loc_36B74:
mov [rbp+var_1], 1
jmp loc_36C36
loc_36B7D:
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax+6]
mov [rbp+var_28], eax
mov eax, [rbp+var_28]
mov ecx, eax
lea rax, page_overhead
mov eax, [rax+rcx*4]
mov [rbp+var_24], eax
mov eax, [rbp+var_28]
and eax, 0FFFFFFF8h
cmp eax, 0
jz short loc_36BB4
jmp short $+2
loc_36BA7:
jmp short $+2
loc_36BA9:
jmp short $+2
loc_36BAB:
mov [rbp+var_1], 1
jmp loc_36C36
loc_36BB4:
mov rax, [rbp+var_18]
add rax, 7
mov [rbp+var_30], rax
mov eax, [rbp+var_28]
and eax, 1
cmp eax, 0
jz short loc_36C08
mov rdi, [rbp+var_18]
mov eax, [rbp+var_24]
add rdi, rax
mov esi, 2000h
sub esi, [rbp+var_24]
call translog_crc
mov [rbp+var_3C], eax
mov eax, [rbp+var_3C]
mov rcx, [rbp+var_30]
cmp eax, [rcx]
jz short loc_36BFC
jmp short $+2
loc_36BF2:
jmp short $+2
loc_36BF4:
jmp short $+2
loc_36BF6:
mov [rbp+var_1], 1
jmp short loc_36C36
loc_36BFC:
mov rax, [rbp+var_30]
add rax, 4
mov [rbp+var_30], rax
loc_36C08:
mov eax, [rbp+var_28]
and eax, 2
cmp eax, 0
jz short loc_36C30
mov rdi, [rbp+var_18]
mov rsi, [rbp+var_38]
call translog_check_sector_protection
movsx eax, al
cmp eax, 0
jz short loc_36C30
jmp short $+2
loc_36C2A:
mov [rbp+var_1], 1
jmp short loc_36C36
loc_36C30:
jmp short $+2
loc_36C32:
mov [rbp+var_1], 0
loc_36C36:
mov al, [rbp+var_1]
add rsp, 40h
pop rbp
retn
|
bool translog_page_validator(int a1, unsigned __int16 **a2)
{
unsigned __int16 *v3; // [rsp+8h] [rbp-38h]
int v4; // [rsp+18h] [rbp-28h]
unsigned int v5; // [rsp+1Ch] [rbp-24h]
unsigned __int16 *v6; // [rsp+20h] [rbp-20h]
unsigned __int16 *v7; // [rsp+28h] [rbp-18h]
v7 = *a2;
v6 = a2[1];
v3 = a2[2];
*((_BYTE *)v3 + 80) = 0;
if ( a1 )
return 1;
if ( (unsigned __int16 *)((*((unsigned __int8 *)v7 + 2) << 16) | (unsigned int)*v7) != v6
|| ((*((unsigned __int8 *)v7 + 5) << 16) | *(unsigned __int16 *)((char *)v7 + 3)) != *(_DWORD *)v3 )
{
return 1;
}
v4 = *((unsigned __int8 *)v7 + 6);
if ( (v4 & 0xFFFFFFF8) != 0 )
return 1;
if ( (v4 & 1) == 0 )
return (v4 & 2) != 0 && (unsigned __int8)translog_check_sector_protection(v7, v3);
v5 = page_overhead[*((unsigned __int8 *)v7 + 6)];
if ( (unsigned int)translog_crc((char *)v7 + v5, 0x2000 - v5) == *(_DWORD *)((char *)v7 + 7) )
return (v4 & 2) != 0 && (unsigned __int8)translog_check_sector_protection(v7, v3);
return 1;
}
|
translog_page_validator:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV dword ptr [RBP + -0x8],EDI
MOV qword ptr [RBP + -0x10],RSI
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 + 0x8]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV byte ptr [RAX + 0x50],0x0
CMP dword ptr [RBP + -0x8],0x0
JZ 0x00136b1b
JMP 0x00136b12
LAB_00136b12:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00136c36
LAB_00136b1b:
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX]
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x1]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x2]
SHL ECX,0x10
OR EAX,ECX
MOV EAX,EAX
CMP RAX,qword ptr [RBP + -0x20]
JNZ 0x00136b6e
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x3]
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x4]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x5]
SHL ECX,0x10
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x38]
CMP EAX,dword ptr [RCX]
JZ 0x00136b7d
LAB_00136b6e:
JMP 0x00136b70
LAB_00136b70:
JMP 0x00136b72
LAB_00136b72:
JMP 0x00136b74
LAB_00136b74:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00136c36
LAB_00136b7d:
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x6]
MOV dword ptr [RBP + -0x28],EAX
MOV EAX,dword ptr [RBP + -0x28]
MOV ECX,EAX
LEA RAX,[0xd79b60]
MOV EAX,dword ptr [RAX + RCX*0x4]
MOV dword ptr [RBP + -0x24],EAX
MOV EAX,dword ptr [RBP + -0x28]
AND EAX,0xfffffff8
CMP EAX,0x0
JZ 0x00136bb4
JMP 0x00136ba7
LAB_00136ba7:
JMP 0x00136ba9
LAB_00136ba9:
JMP 0x00136bab
LAB_00136bab:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00136c36
LAB_00136bb4:
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x7
MOV qword ptr [RBP + -0x30],RAX
MOV EAX,dword ptr [RBP + -0x28]
AND EAX,0x1
CMP EAX,0x0
JZ 0x00136c08
MOV RDI,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RBP + -0x24]
ADD RDI,RAX
MOV ESI,0x2000
SUB ESI,dword ptr [RBP + -0x24]
CALL 0x00136c40
MOV dword ptr [RBP + -0x3c],EAX
MOV EAX,dword ptr [RBP + -0x3c]
MOV RCX,qword ptr [RBP + -0x30]
CMP EAX,dword ptr [RCX]
JZ 0x00136bfc
JMP 0x00136bf2
LAB_00136bf2:
JMP 0x00136bf4
LAB_00136bf4:
JMP 0x00136bf6
LAB_00136bf6:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00136c36
LAB_00136bfc:
MOV RAX,qword ptr [RBP + -0x30]
ADD RAX,0x4
MOV qword ptr [RBP + -0x30],RAX
LAB_00136c08:
MOV EAX,dword ptr [RBP + -0x28]
AND EAX,0x2
CMP EAX,0x0
JZ 0x00136c30
MOV RDI,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x38]
CALL 0x00136c70
MOVSX EAX,AL
CMP EAX,0x0
JZ 0x00136c30
JMP 0x00136c2a
LAB_00136c2a:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00136c36
LAB_00136c30:
JMP 0x00136c32
LAB_00136c32:
MOV byte ptr [RBP + -0x1],0x0
LAB_00136c36:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x40
POP RBP
RET
|
int8 translog_page_validator(int param_1,long *param_2)
{
byte bVar1;
uint3 *puVar2;
uint *puVar3;
uint *puVar4;
char cVar5;
uint uVar6;
uint *puVar7;
int1 local_9;
puVar2 = (uint3 *)*param_2;
puVar3 = (uint *)param_2[1];
puVar4 = (uint *)param_2[2];
*(int1 *)(puVar4 + 0x14) = 0;
if (param_1 == 0) {
puVar7 = (uint *)(ulong)*puVar2;
if ((puVar7 == puVar3) &&
(puVar7 = (uint *)(ulong)(uint)*(uint3 *)((long)puVar2 + 3),
(uint)*(uint3 *)((long)puVar2 + 3) == *puVar4)) {
bVar1 = *(byte *)((long)puVar2 + 6);
puVar7 = (uint *)0x0;
if ((bVar1 & 0xf8) == 0) {
if ((bVar1 & 1) != 0) {
uVar6 = translog_crc((long)puVar2 + (ulong)*(uint *)(page_overhead + (ulong)bVar1 * 4),
0x2000 - *(uint *)(page_overhead + (ulong)bVar1 * 4));
puVar7 = (uint *)(ulong)uVar6;
if (uVar6 != *(uint *)((long)puVar2 + 7)) {
local_9 = 1;
goto LAB_00136c36;
}
}
puVar7 = (uint *)0x0;
if ((bVar1 & 2) != 0) {
cVar5 = translog_check_sector_protection(puVar2,puVar4);
puVar7 = (uint *)(ulong)(uint)(int)cVar5;
if ((int)cVar5 != 0) {
local_9 = 1;
goto LAB_00136c36;
}
}
local_9 = 0;
}
else {
local_9 = 1;
}
}
else {
local_9 = 1;
}
}
else {
local_9 = 1;
puVar7 = puVar4;
}
LAB_00136c36:
return CONCAT71((int7)((ulong)puVar7 >> 8),local_9);
}
|
|
9,932 |
common_log::pause()
|
monkey531[P]llama/common/log.cpp
|
void pause() {
{
std::lock_guard<std::mutex> lock(mtx);
if (!running) {
return;
}
running = false;
// push an entry to signal the worker thread to stop
{
auto & entry = entries[tail];
entry.is_end = true;
tail = (tail + 1) % entries.size();
}
cv.notify_one();
}
thrd.join();
}
|
O1
|
cpp
|
common_log::pause():
pushq %rbx
movq %rdi, %rbx
callq 0x1ac70
testl %eax, %eax
jne 0xcbcc5
cmpb $0x1, 0x6a(%rbx)
jne 0xcbcbc
movb $0x0, 0x6a(%rbx)
movq 0x78(%rbx), %rcx
movq 0x98(%rbx), %rax
leaq (%rax,%rax,2), %rdx
shlq $0x4, %rdx
movb $0x1, 0x28(%rcx,%rdx)
incq %rax
movq 0x80(%rbx), %rdx
subq %rcx, %rdx
sarq $0x4, %rdx
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rdx, %rcx
xorl %edx, %edx
divq %rcx
movq %rdx, 0x98(%rbx)
leaq 0x30(%rbx), %rdi
callq 0x1a440
movq %rbx, %rdi
callq 0x1a680
addq $0x28, %rbx
movq %rbx, %rdi
popq %rbx
jmp 0x1ae90
movq %rbx, %rdi
popq %rbx
jmp 0x1a680
movl %eax, %edi
callq 0x1a5c0
|
_ZN10common_log5pauseEv:
push rbx
mov rbx, rdi
call _pthread_mutex_lock
test eax, eax
jnz short loc_CBCC5
cmp byte ptr [rbx+6Ah], 1
jnz short loc_CBCBC
mov byte ptr [rbx+6Ah], 0
mov rcx, [rbx+78h]
mov rax, [rbx+98h]
lea rdx, [rax+rax*2]
shl rdx, 4
mov byte ptr [rcx+rdx+28h], 1
inc rax
mov rdx, [rbx+80h]
sub rdx, rcx
sar rdx, 4
mov rcx, 0AAAAAAAAAAAAAAABh
imul rcx, rdx
xor edx, edx
div rcx
mov [rbx+98h], rdx
lea rdi, [rbx+30h]; this
call __ZNSt18condition_variable10notify_oneEv; std::condition_variable::notify_one(void)
mov rdi, rbx
call _pthread_mutex_unlock
add rbx, 28h ; '('
mov rdi, rbx; this
pop rbx
jmp __ZNSt6thread4joinEv; std::thread::join(void)
loc_CBCBC:
mov rdi, rbx
pop rbx
jmp _pthread_mutex_unlock
loc_CBCC5:
mov edi, eax; int
call __ZSt20__throw_system_errori; std::__throw_system_error(int)
|
long long common_log::pause(common_log *this)
{
int v1; // eax
long long v2; // rcx
long long v3; // rax
v1 = pthread_mutex_lock();
if ( v1 )
std::__throw_system_error(v1);
if ( *((_BYTE *)this + 106) != 1 )
return pthread_mutex_unlock(this);
*((_BYTE *)this + 106) = 0;
v2 = *((_QWORD *)this + 15);
v3 = *((_QWORD *)this + 19);
*(_BYTE *)(v2 + 48 * v3 + 40) = 1;
*((_QWORD *)this + 19) = (v3 + 1) % (0xAAAAAAAAAAAAAAABLL * ((*((_QWORD *)this + 16) - v2) >> 4));
std::condition_variable::notify_one((common_log *)((char *)this + 48));
pthread_mutex_unlock(this);
return std::thread::join((common_log *)((char *)this + 40));
}
|
pause:
PUSH RBX
MOV RBX,RDI
CALL 0x0011ac70
TEST EAX,EAX
JNZ 0x001cbcc5
CMP byte ptr [RBX + 0x6a],0x1
JNZ 0x001cbcbc
MOV byte ptr [RBX + 0x6a],0x0
MOV RCX,qword ptr [RBX + 0x78]
MOV RAX,qword ptr [RBX + 0x98]
LEA RDX,[RAX + RAX*0x2]
SHL RDX,0x4
MOV byte ptr [RCX + RDX*0x1 + 0x28],0x1
INC RAX
MOV RDX,qword ptr [RBX + 0x80]
SUB RDX,RCX
SAR RDX,0x4
MOV RCX,-0x5555555555555555
IMUL RCX,RDX
XOR EDX,EDX
DIV RCX
MOV qword ptr [RBX + 0x98],RDX
LEA RDI,[RBX + 0x30]
CALL 0x0011a440
MOV RDI,RBX
CALL 0x0011a680
ADD RBX,0x28
MOV RDI,RBX
POP RBX
JMP 0x0011ae90
LAB_001cbcbc:
MOV RDI,RBX
POP RBX
JMP 0x0011a680
LAB_001cbcc5:
MOV EDI,EAX
CALL 0x0011a5c0
|
/* common_log::pause() */
void __thiscall common_log::pause(common_log *this)
{
long lVar1;
long lVar2;
int iVar3;
iVar3 = pthread_mutex_lock((pthread_mutex_t *)this);
if (iVar3 != 0) {
/* WARNING: Subroutine does not return */
std::__throw_system_error(iVar3);
}
if (this[0x6a] == (common_log)0x1) {
this[0x6a] = (common_log)0x0;
lVar1 = *(long *)(this + 0x78);
lVar2 = *(long *)(this + 0x98);
*(int1 *)(lVar1 + 0x28 + lVar2 * 0x30) = 1;
*(ulong *)(this + 0x98) =
(lVar2 + 1U) % (ulong)((*(long *)(this + 0x80) - lVar1 >> 4) * -0x5555555555555555);
std::condition_variable::notify_one();
pthread_mutex_unlock((pthread_mutex_t *)this);
std::thread::join();
return;
}
pthread_mutex_unlock((pthread_mutex_t *)this);
return;
}
|
|
9,933 |
common_log::pause()
|
monkey531[P]llama/common/log.cpp
|
void pause() {
{
std::lock_guard<std::mutex> lock(mtx);
if (!running) {
return;
}
running = false;
// push an entry to signal the worker thread to stop
{
auto & entry = entries[tail];
entry.is_end = true;
tail = (tail + 1) % entries.size();
}
cv.notify_one();
}
thrd.join();
}
|
O3
|
cpp
|
common_log::pause():
pushq %rbx
movq %rdi, %rbx
callq 0x1ac70
testl %eax, %eax
jne 0xcb207
cmpb $0x0, 0x6a(%rbx)
je 0xcb1fe
movb $0x0, 0x6a(%rbx)
movq 0x78(%rbx), %rcx
movq 0x98(%rbx), %rax
leaq (%rax,%rax,2), %rdx
shlq $0x4, %rdx
movb $0x1, 0x28(%rcx,%rdx)
incq %rax
movq 0x80(%rbx), %rdx
subq %rcx, %rdx
sarq $0x4, %rdx
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rdx, %rcx
xorl %edx, %edx
divq %rcx
movq %rdx, 0x98(%rbx)
leaq 0x30(%rbx), %rdi
callq 0x1a440
movq %rbx, %rdi
callq 0x1a680
addq $0x28, %rbx
movq %rbx, %rdi
popq %rbx
jmp 0x1ae90
movq %rbx, %rdi
popq %rbx
jmp 0x1a680
movl %eax, %edi
callq 0x1a5c0
|
_ZN10common_log5pauseEv:
push rbx
mov rbx, rdi
call _pthread_mutex_lock
test eax, eax
jnz short loc_CB207
cmp byte ptr [rbx+6Ah], 0
jz short loc_CB1FE
mov byte ptr [rbx+6Ah], 0
mov rcx, [rbx+78h]
mov rax, [rbx+98h]
lea rdx, [rax+rax*2]
shl rdx, 4
mov byte ptr [rcx+rdx+28h], 1
inc rax
mov rdx, [rbx+80h]
sub rdx, rcx
sar rdx, 4
mov rcx, 0AAAAAAAAAAAAAAABh
imul rcx, rdx
xor edx, edx
div rcx
mov [rbx+98h], rdx
lea rdi, [rbx+30h]; this
call __ZNSt18condition_variable10notify_oneEv; std::condition_variable::notify_one(void)
mov rdi, rbx
call _pthread_mutex_unlock
add rbx, 28h ; '('
mov rdi, rbx; this
pop rbx
jmp __ZNSt6thread4joinEv; std::thread::join(void)
loc_CB1FE:
mov rdi, rbx
pop rbx
jmp _pthread_mutex_unlock
loc_CB207:
mov edi, eax; int
call __ZSt20__throw_system_errori; std::__throw_system_error(int)
|
long long common_log::pause(common_log *this)
{
int v1; // eax
long long v2; // rcx
long long v3; // rax
v1 = pthread_mutex_lock();
if ( v1 )
std::__throw_system_error(v1);
if ( !*((_BYTE *)this + 106) )
return pthread_mutex_unlock(this);
*((_BYTE *)this + 106) = 0;
v2 = *((_QWORD *)this + 15);
v3 = *((_QWORD *)this + 19);
*(_BYTE *)(v2 + 48 * v3 + 40) = 1;
*((_QWORD *)this + 19) = (v3 + 1) % (0xAAAAAAAAAAAAAAABLL * ((*((_QWORD *)this + 16) - v2) >> 4));
std::condition_variable::notify_one((common_log *)((char *)this + 48));
pthread_mutex_unlock(this);
return std::thread::join((common_log *)((char *)this + 40));
}
|
pause:
PUSH RBX
MOV RBX,RDI
CALL 0x0011ac70
TEST EAX,EAX
JNZ 0x001cb207
CMP byte ptr [RBX + 0x6a],0x0
JZ 0x001cb1fe
MOV byte ptr [RBX + 0x6a],0x0
MOV RCX,qword ptr [RBX + 0x78]
MOV RAX,qword ptr [RBX + 0x98]
LEA RDX,[RAX + RAX*0x2]
SHL RDX,0x4
MOV byte ptr [RCX + RDX*0x1 + 0x28],0x1
INC RAX
MOV RDX,qword ptr [RBX + 0x80]
SUB RDX,RCX
SAR RDX,0x4
MOV RCX,-0x5555555555555555
IMUL RCX,RDX
XOR EDX,EDX
DIV RCX
MOV qword ptr [RBX + 0x98],RDX
LEA RDI,[RBX + 0x30]
CALL 0x0011a440
MOV RDI,RBX
CALL 0x0011a680
ADD RBX,0x28
MOV RDI,RBX
POP RBX
JMP 0x0011ae90
LAB_001cb1fe:
MOV RDI,RBX
POP RBX
JMP 0x0011a680
LAB_001cb207:
MOV EDI,EAX
CALL 0x0011a5c0
|
/* common_log::pause() */
void __thiscall common_log::pause(common_log *this)
{
long lVar1;
long lVar2;
int iVar3;
iVar3 = pthread_mutex_lock((pthread_mutex_t *)this);
if (iVar3 != 0) {
/* WARNING: Subroutine does not return */
std::__throw_system_error(iVar3);
}
if (this[0x6a] != (common_log)0x0) {
this[0x6a] = (common_log)0x0;
lVar1 = *(long *)(this + 0x78);
lVar2 = *(long *)(this + 0x98);
*(int1 *)(lVar1 + 0x28 + lVar2 * 0x30) = 1;
*(ulong *)(this + 0x98) =
(lVar2 + 1U) % (ulong)((*(long *)(this + 0x80) - lVar1 >> 4) * -0x5555555555555555);
std::condition_variable::notify_one();
pthread_mutex_unlock((pthread_mutex_t *)this);
std::thread::join();
return;
}
pthread_mutex_unlock((pthread_mutex_t *)this);
return;
}
|
|
9,934 |
nglog::posix_strerror_r(int, char*, unsigned long)
|
ng-log[P]ng-log/src/logging.cc
|
NGLOG_NO_EXPORT
int posix_strerror_r(int err, char* buf, size_t len) {
// Sanity check input parameters
if (buf == nullptr || len <= 0) {
errno = EINVAL;
return -1;
}
// Reset buf and errno, and try calling whatever version of strerror_r()
// is implemented by glibc
buf[0] = '\000';
int old_errno = errno;
errno = 0;
char* rc = reinterpret_cast<char*>(strerror_r(err, buf, len));
// Both versions set errno on failure
if (errno) {
// Should already be there, but better safe than sorry
buf[0] = '\000';
return -1;
}
errno = old_errno;
// POSIX is vague about whether the string will be terminated, although
// is indirectly implies that typically ERANGE will be returned, instead
// of truncating the string. This is different from the GNU implementation.
// We play it safe by always terminating the string explicitly.
buf[len - 1] = '\000';
// If the function succeeded, we can use its exit code to determine the
// semantics implemented by glibc
if (!rc) {
return 0;
} else {
// GNU semantics detected
if (rc == buf) {
return 0;
} else {
buf[0] = '\000';
#if defined(NGLOG_OS_MACOSX) || defined(NGLOG_OS_FREEBSD) || \
defined(NGLOG_OS_OPENBSD)
if (reinterpret_cast<intptr_t>(rc) < sys_nerr) {
// This means an error on MacOSX or FreeBSD.
return -1;
}
#endif
strncat(buf, rc, len - 1);
return 0;
}
}
}
|
O0
|
cpp
|
nglog::posix_strerror_r(int, char*, unsigned long):
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x1a2f1
cmpq $0x0, -0x18(%rbp)
ja 0x1a308
callq 0x9070
movl $0x16, (%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1a3b8
movq -0x10(%rbp), %rax
movb $0x0, (%rax)
callq 0x9070
movl (%rax), %eax
movl %eax, -0x1c(%rbp)
callq 0x9070
movl $0x0, (%rax)
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x9150
movq %rax, -0x28(%rbp)
callq 0x9070
cmpl $0x0, (%rax)
je 0x1a352
movq -0x10(%rbp), %rax
movb $0x0, (%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1a3b8
movl -0x1c(%rbp), %eax
movl %eax, -0x2c(%rbp)
callq 0x9070
movl -0x2c(%rbp), %ecx
movl %ecx, (%rax)
movq -0x10(%rbp), %rax
movq -0x18(%rbp), %rcx
subq $0x1, %rcx
movb $0x0, (%rax,%rcx)
cmpq $0x0, -0x28(%rbp)
jne 0x1a382
movl $0x0, -0x4(%rbp)
jmp 0x1a3b8
movq -0x28(%rbp), %rax
cmpq -0x10(%rbp), %rax
jne 0x1a395
movl $0x0, -0x4(%rbp)
jmp 0x1a3b8
movq -0x10(%rbp), %rax
movb $0x0, (%rax)
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x18(%rbp), %rdx
subq $0x1, %rdx
callq 0x9490
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
_ZN5nglog16posix_strerror_rEiPcm:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], edi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
cmp [rbp+var_10], 0
jz short loc_1A2F1
cmp [rbp+var_18], 0
ja short loc_1A308
loc_1A2F1:
call ___errno_location
mov dword ptr [rax], 16h
mov [rbp+var_4], 0FFFFFFFFh
jmp loc_1A3B8
loc_1A308:
mov rax, [rbp+var_10]
mov byte ptr [rax], 0
call ___errno_location
mov eax, [rax]
mov [rbp+var_1C], eax
call ___errno_location
mov dword ptr [rax], 0
mov edi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
call _strerror_r
mov [rbp+var_28], rax
call ___errno_location
cmp dword ptr [rax], 0
jz short loc_1A352
mov rax, [rbp+var_10]
mov byte ptr [rax], 0
mov [rbp+var_4], 0FFFFFFFFh
jmp short loc_1A3B8
loc_1A352:
mov eax, [rbp+var_1C]
mov [rbp+var_2C], eax
call ___errno_location
mov ecx, [rbp+var_2C]
mov [rax], ecx
mov rax, [rbp+var_10]
mov rcx, [rbp+var_18]
sub rcx, 1
mov byte ptr [rax+rcx], 0
cmp [rbp+var_28], 0
jnz short loc_1A382
mov [rbp+var_4], 0
jmp short loc_1A3B8
loc_1A382:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_10]
jnz short loc_1A395
mov [rbp+var_4], 0
jmp short loc_1A3B8
loc_1A395:
mov rax, [rbp+var_10]
mov byte ptr [rax], 0
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
mov rdx, [rbp+var_18]
sub rdx, 1
call _strncat
mov [rbp+var_4], 0
loc_1A3B8:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
|
long long nglog::posix_strerror_r(nglog *this, _BYTE *a2, char *a3)
{
long long v4; // [rsp+8h] [rbp-28h]
int v5; // [rsp+14h] [rbp-1Ch]
if ( a2 && a3 )
{
*a2 = 0;
v5 = *(_DWORD *)__errno_location();
*(_DWORD *)__errno_location() = 0;
v4 = strerror_r((unsigned int)this, a2, a3);
if ( *(_DWORD *)__errno_location() )
{
*a2 = 0;
return (unsigned int)-1;
}
else
{
*(_DWORD *)__errno_location() = v5;
a3[(_QWORD)a2 - 1] = 0;
if ( v4 )
{
if ( (_BYTE *)v4 != a2 )
{
*a2 = 0;
strncat(a2, v4, a3 - 1);
}
return 0;
}
else
{
return 0;
}
}
}
else
{
*(_DWORD *)__errno_location() = 22;
return (unsigned int)-1;
}
}
|
posix_strerror_r:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV dword ptr [RBP + -0x8],EDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
CMP qword ptr [RBP + -0x10],0x0
JZ 0x0011a2f1
CMP qword ptr [RBP + -0x18],0x0
JA 0x0011a308
LAB_0011a2f1:
CALL 0x00109070
MOV dword ptr [RAX],0x16
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x0011a3b8
LAB_0011a308:
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],0x0
CALL 0x00109070
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x1c],EAX
CALL 0x00109070
MOV dword ptr [RAX],0x0
MOV EDI,dword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
CALL 0x00109150
MOV qword ptr [RBP + -0x28],RAX
CALL 0x00109070
CMP dword ptr [RAX],0x0
JZ 0x0011a352
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],0x0
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x0011a3b8
LAB_0011a352:
MOV EAX,dword ptr [RBP + -0x1c]
MOV dword ptr [RBP + -0x2c],EAX
CALL 0x00109070
MOV ECX,dword ptr [RBP + -0x2c]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x18]
SUB RCX,0x1
MOV byte ptr [RAX + RCX*0x1],0x0
CMP qword ptr [RBP + -0x28],0x0
JNZ 0x0011a382
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0011a3b8
LAB_0011a382:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x10]
JNZ 0x0011a395
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0011a3b8
LAB_0011a395:
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],0x0
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x18]
SUB RDX,0x1
CALL 0x00109490
MOV dword ptr [RBP + -0x4],0x0
LAB_0011a3b8:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
/* nglog::posix_strerror_r(int, char*, unsigned long) */
int4 nglog::posix_strerror_r(int param_1,char *param_2,ulong param_3)
{
int iVar1;
int *piVar2;
char *__src;
int4 local_c;
if ((param_2 == (char *)0x0) || (param_3 == 0)) {
piVar2 = __errno_location();
*piVar2 = 0x16;
local_c = 0xffffffff;
}
else {
*param_2 = '\0';
piVar2 = __errno_location();
iVar1 = *piVar2;
piVar2 = __errno_location();
*piVar2 = 0;
__src = strerror_r(param_1,param_2,param_3);
piVar2 = __errno_location();
if (*piVar2 == 0) {
piVar2 = __errno_location();
*piVar2 = iVar1;
param_2[param_3 - 1] = '\0';
if (__src == (char *)0x0) {
local_c = 0;
}
else if (__src == param_2) {
local_c = 0;
}
else {
*param_2 = '\0';
strncat(param_2,__src,param_3 - 1);
local_c = 0;
}
}
else {
*param_2 = '\0';
local_c = 0xffffffff;
}
}
return local_c;
}
|
|
9,935 |
nglog::posix_strerror_r(int, char*, unsigned long)
|
ng-log[P]ng-log/src/logging.cc
|
NGLOG_NO_EXPORT
int posix_strerror_r(int err, char* buf, size_t len) {
// Sanity check input parameters
if (buf == nullptr || len <= 0) {
errno = EINVAL;
return -1;
}
// Reset buf and errno, and try calling whatever version of strerror_r()
// is implemented by glibc
buf[0] = '\000';
int old_errno = errno;
errno = 0;
char* rc = reinterpret_cast<char*>(strerror_r(err, buf, len));
// Both versions set errno on failure
if (errno) {
// Should already be there, but better safe than sorry
buf[0] = '\000';
return -1;
}
errno = old_errno;
// POSIX is vague about whether the string will be terminated, although
// is indirectly implies that typically ERANGE will be returned, instead
// of truncating the string. This is different from the GNU implementation.
// We play it safe by always terminating the string explicitly.
buf[len - 1] = '\000';
// If the function succeeded, we can use its exit code to determine the
// semantics implemented by glibc
if (!rc) {
return 0;
} else {
// GNU semantics detected
if (rc == buf) {
return 0;
} else {
buf[0] = '\000';
#if defined(NGLOG_OS_MACOSX) || defined(NGLOG_OS_FREEBSD) || \
defined(NGLOG_OS_OPENBSD)
if (reinterpret_cast<intptr_t>(rc) < sys_nerr) {
// This means an error on MacOSX or FreeBSD.
return -1;
}
#endif
strncat(buf, rc, len - 1);
return 0;
}
}
}
|
O2
|
cpp
|
nglog::posix_strerror_r(int, char*, unsigned long):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rsi, %rsi
setne %al
testq %rdx, %rdx
setne %cl
testb %cl, %al
jne 0xdca2
callq 0x7040
movl $0x16, (%rax)
jmp 0xdcd2
movq %rdx, %rbx
movq %rsi, %r14
movl %edi, %ebp
movb $0x0, (%rsi)
callq 0x7040
movq %rax, %r15
movl (%rax), %r12d
andl $0x0, (%rax)
movl %ebp, %edi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x7100
cmpl $0x0, (%r15)
je 0xdce0
movb $0x0, (%r14)
pushq $-0x1
popq %rbp
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl %r12d, (%r15)
movb $0x0, -0x1(%r14,%rbx)
testq %rax, %rax
sete %cl
cmpq %r14, %rax
sete %dl
xorl %ebp, %ebp
orb %cl, %dl
jne 0xdcd5
decq %rbx
movb $0x0, (%r14)
movq %r14, %rdi
movq %rax, %rsi
movq %rbx, %rdx
callq 0x7390
jmp 0xdcd5
|
_ZN5nglog16posix_strerror_rEiPcm:
push rbp
push r15
push r14
push r12
push rbx
test rsi, rsi
setnz al
test rdx, rdx
setnz cl
test al, cl
jnz short loc_DCA2
call ___errno_location
mov dword ptr [rax], 16h
jmp short loc_DCD2
loc_DCA2:
mov rbx, rdx
mov r14, rsi
mov ebp, edi
mov byte ptr [rsi], 0
call ___errno_location
mov r15, rax
mov r12d, [rax]
and dword ptr [rax], 0
mov edi, ebp
mov rsi, r14
mov rdx, rbx
call _strerror_r
cmp dword ptr [r15], 0
jz short loc_DCE0
mov byte ptr [r14], 0
loc_DCD2:
push 0FFFFFFFFFFFFFFFFh
pop rbp
loc_DCD5:
mov eax, ebp
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_DCE0:
mov [r15], r12d
mov byte ptr [r14+rbx-1], 0
test rax, rax
setz cl
cmp rax, r14
setz dl
xor ebp, ebp
or dl, cl
jnz short loc_DCD5
dec rbx
mov byte ptr [r14], 0
mov rdi, r14
mov rsi, rax
mov rdx, rbx
call _strncat
jmp short loc_DCD5
|
long long nglog::posix_strerror_r(nglog *this, _BYTE *a2, char *a3)
{
int *v4; // r15
int v5; // r12d
long long v6; // rax
unsigned int v7; // ebp
if ( a3 == 0LL || a2 == 0LL )
{
*(_DWORD *)__errno_location(this) = 22;
return (unsigned int)-1;
}
*a2 = 0;
v4 = (int *)((long long (*)(void))__errno_location)();
v5 = *v4;
*v4 = 0;
v6 = strerror_r((unsigned int)this, a2, a3);
if ( *v4 )
{
*a2 = 0;
return (unsigned int)-1;
}
*v4 = v5;
a3[(_QWORD)a2 - 1] = 0;
v7 = 0;
if ( v6 != 0 && v6 != (_QWORD)a2 )
{
*a2 = 0;
strncat(a2, v6, a3 - 1);
}
return v7;
}
|
posix_strerror_r:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
TEST RSI,RSI
SETNZ AL
TEST RDX,RDX
SETNZ CL
TEST AL,CL
JNZ 0x0010dca2
CALL 0x00107040
MOV dword ptr [RAX],0x16
JMP 0x0010dcd2
LAB_0010dca2:
MOV RBX,RDX
MOV R14,RSI
MOV EBP,EDI
MOV byte ptr [RSI],0x0
CALL 0x00107040
MOV R15,RAX
MOV R12D,dword ptr [RAX]
AND dword ptr [RAX],0x0
MOV EDI,EBP
MOV RSI,R14
MOV RDX,RBX
CALL 0x00107100
CMP dword ptr [R15],0x0
JZ 0x0010dce0
MOV byte ptr [R14],0x0
LAB_0010dcd2:
PUSH -0x1
POP RBP
LAB_0010dcd5:
MOV EAX,EBP
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_0010dce0:
MOV dword ptr [R15],R12D
MOV byte ptr [R14 + RBX*0x1 + -0x1],0x0
TEST RAX,RAX
SETZ CL
CMP RAX,R14
SETZ DL
XOR EBP,EBP
OR DL,CL
JNZ 0x0010dcd5
DEC RBX
MOV byte ptr [R14],0x0
MOV RDI,R14
MOV RSI,RAX
MOV RDX,RBX
CALL 0x00107390
JMP 0x0010dcd5
|
/* nglog::posix_strerror_r(int, char*, unsigned long) */
int4 nglog::posix_strerror_r(int param_1,char *param_2,ulong param_3)
{
int iVar1;
int *piVar2;
char *__src;
if (param_2 == (char *)0x0 || param_3 == 0) {
piVar2 = __errno_location();
*piVar2 = 0x16;
}
else {
*param_2 = '\0';
piVar2 = __errno_location();
iVar1 = *piVar2;
*piVar2 = 0;
__src = strerror_r(param_1,param_2,param_3);
if (*piVar2 == 0) {
*piVar2 = iVar1;
param_2[param_3 - 1] = '\0';
if (__src == param_2 || __src == (char *)0x0) {
return 0;
}
*param_2 = '\0';
strncat(param_2,__src,param_3 - 1);
return 0;
}
*param_2 = '\0';
}
return 0xffffffff;
}
|
|
9,936 |
google::protobuf::PlanAllocationSize(google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto> const&, google::protobuf::internal::FlatAllocator&)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc
|
static void PlanAllocationSize(
const RepeatedPtrField<ServiceDescriptorProto>& services,
internal::FlatAllocator& alloc) {
alloc.PlanArray<ServiceDescriptor>(services.size());
alloc.PlanArray<std::string>(2 * services.size()); // name + full_name
for (const auto& service : services) {
if (service.has_options()) alloc.PlanArray<ServiceOptions>(1);
PlanAllocationSize(service.method(), alloc);
}
}
|
O0
|
cpp
|
google::protobuf::PlanAllocationSize(google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto> const&, google::protobuf::internal::FlatAllocator&):
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movq %rsi, 0x38(%rsp)
movq 0x38(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x40(%rsp), %rdi
callq 0x83f70
movq 0x8(%rsp), %rdi
movl %eax, %esi
callq 0x658e0
movq 0x38(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x40(%rsp), %rdi
callq 0x83f70
movq 0x10(%rsp), %rdi
movl %eax, %esi
shll %esi
callq 0x448d0
movq 0x40(%rsp), %rax
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rdi
callq 0x83f80
movq %rax, 0x28(%rsp)
movq 0x30(%rsp), %rdi
callq 0x83fc0
movq %rax, 0x20(%rsp)
leaq 0x28(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x84020
testb $0x1, %al
jne 0x651dd
jmp 0x6522e
leaq 0x28(%rsp), %rdi
callq 0x84040
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
callq 0x79630
testb $0x1, %al
jne 0x651fc
jmp 0x6520b
movq 0x38(%rsp), %rdi
movl $0x1, %esi
callq 0x659e0
movq 0x18(%rsp), %rdi
callq 0x84060
movq %rax, %rdi
movq 0x38(%rsp), %rsi
callq 0x65ad0
leaq 0x28(%rsp), %rdi
callq 0x84080
jmp 0x651c8
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
|
_ZN6google8protobufL18PlanAllocationSizeERKNS0_16RepeatedPtrFieldINS0_22ServiceDescriptorProtoEEERNS0_8internal13FlatAllocatorE:
sub rsp, 48h
mov [rsp+48h+var_8], rdi
mov [rsp+48h+var_10], rsi
mov rax, [rsp+48h+var_10]
mov [rsp+48h+var_40], rax
mov rdi, [rsp+48h+var_8]
call _ZNK6google8protobuf16RepeatedPtrFieldINS0_22ServiceDescriptorProtoEE4sizeEv; google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::size(void)
mov rdi, [rsp+48h+var_40]
mov esi, eax
call _ZN6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE9PlanArrayINS0_17ServiceDescriptorEEEvi; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::PlanArray<google::protobuf::ServiceDescriptor>(int)
mov rax, [rsp+48h+var_10]
mov [rsp+48h+var_38], rax
mov rdi, [rsp+48h+var_8]
call _ZNK6google8protobuf16RepeatedPtrFieldINS0_22ServiceDescriptorProtoEE4sizeEv; google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::size(void)
mov rdi, [rsp+48h+var_38]
mov esi, eax
shl esi, 1
call _ZN6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE9PlanArrayIS8_EEvi; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::PlanArray<std::string>(int)
mov rax, [rsp+48h+var_8]
mov [rsp+48h+var_18], rax
mov rdi, [rsp+48h+var_18]
call _ZNK6google8protobuf16RepeatedPtrFieldINS0_22ServiceDescriptorProtoEE5beginEv; google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::begin(void)
mov [rsp+48h+var_20], rax
mov rdi, [rsp+48h+var_18]
call _ZNK6google8protobuf16RepeatedPtrFieldINS0_22ServiceDescriptorProtoEE3endEv; google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::end(void)
mov [rsp+48h+var_28], rax
loc_651C8:
lea rdi, [rsp+48h+var_20]
lea rsi, [rsp+48h+var_28]
call _ZN6google8protobuf8internalneERKNS1_19RepeatedPtrIteratorIKNS0_22ServiceDescriptorProtoEEES7_; google::protobuf::internal::operator!=(google::protobuf::internal::RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto const> const&,google::protobuf::internal::RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto const> const&)
test al, 1
jnz short loc_651DD
jmp short loc_6522E
loc_651DD:
lea rdi, [rsp+48h+var_20]
call _ZNK6google8protobuf8internal19RepeatedPtrIteratorIKNS0_22ServiceDescriptorProtoEEdeEv; google::protobuf::internal::RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto const>::operator*(void)
mov [rsp+48h+var_30], rax
mov rdi, [rsp+48h+var_30]; this
call _ZNK6google8protobuf22ServiceDescriptorProto11has_optionsEv; google::protobuf::ServiceDescriptorProto::has_options(void)
test al, 1
jnz short loc_651FC
jmp short loc_6520B
loc_651FC:
mov rdi, [rsp+48h+var_10]
mov esi, 1
call _ZN6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE9PlanArrayISH_EEvi; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::PlanArray<google::protobuf::ServiceOptions>(int)
loc_6520B:
mov rdi, [rsp+48h+var_30]; this
call _ZNK6google8protobuf22ServiceDescriptorProto6methodEv; google::protobuf::ServiceDescriptorProto::method(void)
mov rdi, rax
mov rsi, [rsp+48h+var_10]
call _ZN6google8protobufL18PlanAllocationSizeERKNS0_16RepeatedPtrFieldINS0_21MethodDescriptorProtoEEERNS0_8internal13FlatAllocatorE; google::protobuf::PlanAllocationSize(google::protobuf::RepeatedPtrField<google::protobuf::MethodDescriptorProto> const&,google::protobuf::internal::FlatAllocator &)
lea rdi, [rsp+48h+var_20]
call _ZN6google8protobuf8internal19RepeatedPtrIteratorIKNS0_22ServiceDescriptorProtoEEppEv; google::protobuf::internal::RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto const>::operator++(void)
jmp short loc_651C8
loc_6522E:
add rsp, 48h
retn
|
long long google::protobuf::PlanAllocationSize(long long a1, long long a2)
{
int v2; // eax
int v3; // edx
int v4; // ecx
int v5; // r8d
int v6; // r9d
int v7; // eax
long long result; // rax
int v9; // edx
int v10; // ecx
int v11; // r8d
int v12; // r9d
long long v13; // rax
int v14; // [rsp+0h] [rbp-48h]
int v15; // [rsp+8h] [rbp-40h]
int v16; // [rsp+10h] [rbp-38h]
google::protobuf::ServiceDescriptorProto *v17; // [rsp+18h] [rbp-30h]
long long v18; // [rsp+20h] [rbp-28h] BYREF
long long v19; // [rsp+28h] [rbp-20h] BYREF
long long v20; // [rsp+30h] [rbp-18h]
long long v21; // [rsp+38h] [rbp-10h]
long long v22; // [rsp+40h] [rbp-8h]
v22 = a1;
v21 = a2;
v15 = a2;
v2 = google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::size(a1);
google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::PlanArray<google::protobuf::ServiceDescriptor>(
a2,
v2,
v3,
v4,
v5,
v6);
v16 = a2;
v7 = google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::size(a1);
google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::PlanArray<std::string>(
a2,
2 * v7);
v20 = a1;
v19 = google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::begin(a1);
v18 = google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::end(a1);
while ( 1 )
{
result = google::protobuf::internal::operator!=(&v19, &v18);
if ( (result & 1) == 0 )
break;
v17 = (google::protobuf::ServiceDescriptorProto *)google::protobuf::internal::RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto const>::operator*(&v19);
if ( (google::protobuf::ServiceDescriptorProto::has_options(v17) & 1) != 0 )
google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::PlanArray<google::protobuf::ServiceOptions>(
v21,
1,
v9,
v10,
v11,
v12,
v14,
v15,
v16,
(_DWORD)v17,
v18,
v19,
v20,
v21);
v13 = google::protobuf::ServiceDescriptorProto::method(v17);
google::protobuf::PlanAllocationSize(v13, v21);
google::protobuf::internal::RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto const>::operator++(&v19);
}
return result;
}
|
PlanAllocationSize:
SUB RSP,0x48
MOV qword ptr [RSP + 0x40],RDI
MOV qword ptr [RSP + 0x38],RSI
MOV RAX,qword ptr [RSP + 0x38]
MOV qword ptr [RSP + 0x8],RAX
MOV RDI,qword ptr [RSP + 0x40]
CALL 0x00183f70
MOV RDI,qword ptr [RSP + 0x8]
MOV ESI,EAX
CALL 0x001658e0
MOV RAX,qword ptr [RSP + 0x38]
MOV qword ptr [RSP + 0x10],RAX
MOV RDI,qword ptr [RSP + 0x40]
CALL 0x00183f70
MOV RDI,qword ptr [RSP + 0x10]
MOV ESI,EAX
SHL ESI,0x1
CALL 0x001448d0
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP + 0x30],RAX
MOV RDI,qword ptr [RSP + 0x30]
CALL 0x00183f80
MOV qword ptr [RSP + 0x28],RAX
MOV RDI,qword ptr [RSP + 0x30]
CALL 0x00183fc0
MOV qword ptr [RSP + 0x20],RAX
LAB_001651c8:
LEA RDI,[RSP + 0x28]
LEA RSI,[RSP + 0x20]
CALL 0x00184020
TEST AL,0x1
JNZ 0x001651dd
JMP 0x0016522e
LAB_001651dd:
LEA RDI,[RSP + 0x28]
CALL 0x00184040
MOV qword ptr [RSP + 0x18],RAX
MOV RDI,qword ptr [RSP + 0x18]
CALL 0x00179630
TEST AL,0x1
JNZ 0x001651fc
JMP 0x0016520b
LAB_001651fc:
MOV RDI,qword ptr [RSP + 0x38]
MOV ESI,0x1
CALL 0x001659e0
LAB_0016520b:
MOV RDI,qword ptr [RSP + 0x18]
CALL 0x00184060
MOV RDI,RAX
MOV RSI,qword ptr [RSP + 0x38]
CALL 0x00165ad0
LEA RDI,[RSP + 0x28]
CALL 0x00184080
JMP 0x001651c8
LAB_0016522e:
ADD RSP,0x48
RET
|
/* google::protobuf::PlanAllocationSize(google::protobuf::RepeatedPtrField<google::protobuf::ServiceDescriptorProto>
const&, google::protobuf::internal::FlatAllocator&) */
void google::protobuf::PlanAllocationSize(RepeatedPtrField *param_1,FlatAllocator *param_2)
{
FlatAllocator *this;
int iVar1;
ulong uVar2;
ServiceDescriptorProto *this_00;
RepeatedPtrField *pRVar3;
int8 local_28;
int8 local_20;
RepeatedPtrField<google::protobuf::ServiceDescriptorProto> *local_18;
FlatAllocator *local_10;
RepeatedPtrField *local_8;
local_10 = param_2;
local_8 = param_1;
iVar1 = RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::size
((RepeatedPtrField<google::protobuf::ServiceDescriptorProto> *)param_1);
(anonymous_namespace)::
FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
::PlanArray<google::protobuf::ServiceDescriptor>
((FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
*)param_2,iVar1);
this = local_10;
iVar1 = RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::size
((RepeatedPtrField<google::protobuf::ServiceDescriptorProto> *)local_8);
(anonymous_namespace)::
FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
::PlanArray<std::__cxx11::string>
((FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
*)this,iVar1 << 1);
local_18 = (RepeatedPtrField<google::protobuf::ServiceDescriptorProto> *)local_8;
local_20 = RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::begin
((RepeatedPtrField<google::protobuf::ServiceDescriptorProto> *)local_8);
local_28 = RepeatedPtrField<google::protobuf::ServiceDescriptorProto>::end(local_18);
while (uVar2 = internal::operator!=
((RepeatedPtrIterator *)&local_20,(RepeatedPtrIterator *)&local_28),
(uVar2 & 1) != 0) {
this_00 = (ServiceDescriptorProto *)
internal::RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto_const>::
operator*((RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto_const> *)
&local_20);
uVar2 = ServiceDescriptorProto::has_options(this_00);
if ((uVar2 & 1) != 0) {
(anonymous_namespace)::
FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
::PlanArray<google::protobuf::ServiceOptions>
((FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
*)local_10,1);
}
pRVar3 = (RepeatedPtrField *)ServiceDescriptorProto::method(this_00);
PlanAllocationSize(pRVar3,local_10);
internal::RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto_const>::operator++
((RepeatedPtrIterator<google::protobuf::ServiceDescriptorProto_const> *)&local_20);
}
return;
}
|
|
9,937 |
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::push_back(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>)
|
monkey531[P]llama/common/json.hpp
|
void push_back(initializer_list_t init)
{
if (is_object() && init.size() == 2 && (*init.begin())->is_string())
{
basic_json&& key = init.begin()->moved_or_copied();
push_back(typename object_t::value_type(
std::move(key.get_ref<string_t&>()), (init.begin() + 1)->moved_or_copied()));
}
else
{
push_back(basic_json(init));
}
}
|
O2
|
cpp
|
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::push_back(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<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 %r15
pushq %r14
pushq %rbx
subq $0x50, %rsp
movq %rsi, %r14
movq %rdi, %rbx
cmpb $0x1, (%rdi)
sete %al
cmpq $0x2, %rdx
sete %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x2c8c8
movq 0x10(%r14), %rax
testq %rax, %rax
cmoveq %r14, %rax
cmpb $0x3, (%rax)
jne 0x2c8c8
leaq 0x10(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x5cc58
movq %r15, %rdi
callq 0x6df14
movq %rax, %r15
addq $0x18, %r14
movq %rsp, %rdi
movq %r14, %rsi
callq 0x5cc58
leaq 0x20(%rsp), %r14
movq %rsp, %rdx
movq %r14, %rdi
movq %r15, %rsi
callq 0x6dc86
movq %rbx, %rdi
movq %r14, %rsi
callq 0x6dbba
leaq 0x20(%rsp), %rdi
callq 0x3e158
movq %rsp, %rdi
callq 0x2c78c
leaq 0x10(%rsp), %rdi
jmp 0x2c8ef
leaq 0x20(%rsp), %r15
pushq $0x1
popq %rcx
pushq $0x2
popq %r8
movq %r15, %rdi
movq %r14, %rsi
callq 0x2d008
movq %rbx, %rdi
movq %r15, %rsi
callq 0x6dcac
leaq 0x20(%rsp), %rdi
callq 0x2c78c
addq $0x50, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x3e158
movq %rsp, %rdi
callq 0x2c78c
jmp 0x2c91a
jmp 0x2c917
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
jmp 0x2c929
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x2c78c
movq %rbx, %rdi
callq 0x20b90
|
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backESt16initializer_listINS0_6detail8json_refISD_EEE:
push r15
push r14
push rbx
sub rsp, 50h
mov r14, rsi
mov rbx, rdi
cmp byte ptr [rdi], 1
setz al
cmp rdx, 2
setz cl
and cl, al
cmp cl, 1
jnz short loc_2C8C8
mov rax, [r14+10h]
test rax, rax
cmovz rax, r14
cmp byte ptr [rax], 3
jnz short loc_2C8C8
lea r15, [rsp+68h+var_58]
mov rdi, r15
mov rsi, r14
call _ZNK8nlohmann16json_abi_v3_11_36detail8json_refINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE15moved_or_copiedEv; nlohmann::json_abi_v3_11_3::detail::json_ref<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>>::moved_or_copied(void)
mov rdi, r15
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE12get_ref_implIRS9_SD_EET_RT0_; 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>::get_ref_impl<std::string&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &)
mov r15, rax
add r14, 18h
mov rdi, rsp
mov rsi, r14
call _ZNK8nlohmann16json_abi_v3_11_36detail8json_refINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE15moved_or_copiedEv; nlohmann::json_abi_v3_11_3::detail::json_ref<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>>::moved_or_copied(void)
lea r14, [rsp+68h+var_48]
mov rdx, rsp
mov rdi, r14
mov rsi, r15
call _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEEC2IS5_SF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_
mov rdi, rbx
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backERKSt4pairIKS9_SD_E; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::push_back(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>> const&)
lea rdi, [rsp+68h+var_48]; void *
call _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEED2Ev; 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>>::~pair()
mov rdi, rsp
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json()
lea rdi, [rsp+68h+var_58]
jmp short loc_2C8EF
loc_2C8C8:
lea r15, [rsp+68h+var_48]
push 1
pop rcx
push 2
pop r8
mov rdi, r15
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ESt16initializer_listINS0_6detail8json_refISD_EEEbNSF_7value_tE; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::basic_json(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>,bool,nlohmann::json_abi_v3_11_3::detail::value_t)
mov rdi, rbx
mov rsi, r15
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backEOSD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::push_back(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&&)
lea rdi, [rsp+68h+var_48]
loc_2C8EF:
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json()
add rsp, 50h
pop rbx
pop r14
pop r15
retn
mov rbx, rax
lea rdi, [rsp+arg_18]; void *
call _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEED2Ev; 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>>::~pair()
mov rdi, rsp
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json()
jmp short loc_2C91A
jmp short $+2
loc_2C917:
mov rbx, rax
loc_2C91A:
lea rdi, [rsp+arg_8]
jmp short loc_2C929
mov rbx, rax
lea rdi, [rsp+arg_18]
loc_2C929:
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json()
mov rdi, rbx
call __Unwind_Resume
|
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back(
_BYTE *a1,
long long a2,
long long a3)
{
_BYTE *v3; // rax
long long v4; // r15
_BYTE *v5; // rdi
_BYTE v7[16]; // [rsp+0h] [rbp-68h] BYREF
_BYTE v8[16]; // [rsp+10h] [rbp-58h] BYREF
_BYTE v9[72]; // [rsp+20h] [rbp-48h] BYREF
if ( *a1 != 1 || a3 != 2 )
goto LABEL_6;
v3 = *(_BYTE **)(a2 + 16);
if ( !v3 )
v3 = (_BYTE *)a2;
if ( *v3 == 3 )
{
nlohmann::json_abi_v3_11_3::detail::json_ref<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>>::moved_or_copied(
v8,
a2);
v4 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::get_ref_impl<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>>(v8);
nlohmann::json_abi_v3_11_3::detail::json_ref<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>>::moved_or_copied(
v7,
a2 + 24);
ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEEC2IS5_SF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_(
v9,
v4,
v7);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back(
a1,
v9);
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>>::~pair(v9);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::~basic_json((long long)v7);
v5 = v8;
}
else
{
LABEL_6:
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json(
v9,
a2,
a3,
1LL,
2LL);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back(
a1,
v9);
v5 = v9;
}
return nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::~basic_json((long long)v5);
}
|
push_back:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x50
MOV R14,RSI
MOV RBX,RDI
CMP byte ptr [RDI],0x1
SETZ AL
CMP RDX,0x2
SETZ CL
AND CL,AL
CMP CL,0x1
JNZ 0x0012c8c8
MOV RAX,qword ptr [R14 + 0x10]
TEST RAX,RAX
CMOVZ RAX,R14
CMP byte ptr [RAX],0x3
JNZ 0x0012c8c8
LEA R15,[RSP + 0x10]
MOV RDI,R15
MOV RSI,R14
CALL 0x0015cc58
LAB_0012c877:
MOV RDI,R15
CALL 0x0016df14
MOV R15,RAX
ADD R14,0x18
LAB_0012c886:
MOV RDI,RSP
MOV RSI,R14
CALL 0x0015cc58
LEA R14,[RSP + 0x20]
MOV RDX,RSP
MOV RDI,R14
MOV RSI,R15
CALL 0x0016dc86
LAB_0012c8a4:
MOV RDI,RBX
MOV RSI,R14
CALL 0x0016dbba
LAB_0012c8af:
LEA RDI,[RSP + 0x20]
CALL 0x0013e158
MOV RDI,RSP
CALL 0x0012c78c
LEA RDI,[RSP + 0x10]
JMP 0x0012c8ef
LAB_0012c8c8:
LEA R15,[RSP + 0x20]
PUSH 0x1
POP RCX
PUSH 0x2
POP R8
MOV RDI,R15
MOV RSI,R14
CALL 0x0012d008
LAB_0012c8df:
MOV RDI,RBX
MOV RSI,R15
CALL 0x0016dcac
LAB_0012c8ea:
LEA RDI,[RSP + 0x20]
LAB_0012c8ef:
CALL 0x0012c78c
ADD RSP,0x50
POP RBX
POP R14
POP R15
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>::push_back(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> > >) */
void nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::push_back(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*param_1,char *param_2,long param_3)
{
char *pcVar1;
string *psVar2;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this;
basic_json<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_68 [16];
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
local_58 [16];
pair local_48 [48];
if (param_3 == 2 &&
*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>
)0x1) {
pcVar1 = *(char **)(param_2 + 0x10);
if (*(char **)(param_2 + 0x10) == (char *)0x0) {
pcVar1 = param_2;
}
if (*pcVar1 == '\x03') {
detail::
json_ref<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>>
::moved_or_copied();
/* try { // try from 0012c877 to 0012c87e has its CatchHandler @ 0012c917 */
psVar2 = get_ref_impl<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>>
(local_58);
/* try { // try from 0012c886 to 0012c890 has its CatchHandler @ 0012c915 */
detail::
json_ref<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>>
::moved_or_copied();
_ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEEC2IS5_SF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_
(local_48,psVar2,abStack_68);
/* try { // try from 0012c8a4 to 0012c8ae has its CatchHandler @ 0012c8fe */
push_back(param_1,local_48);
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>>
::~pair((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>>
*)local_48);
~basic_json(abStack_68);
this = local_58;
goto LAB_0012c8ef;
}
}
basic_json(local_48,param_2,param_3,1,2);
/* try { // try from 0012c8df to 0012c8e9 has its CatchHandler @ 0012c921 */
push_back(param_1,local_48);
this = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*)local_48;
LAB_0012c8ef:
~basic_json(this);
return;
}
|
|
9,938 |
nglog::(anonymous namespace)::LogCleaner::IsLogLastModifiedOver(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::chrono::time_point<std::chrono::_V2::system_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l>>> const&) const
|
ng-log[P]ng-log/src/logging.cc
|
bool LogCleaner::IsLogLastModifiedOver(
const string& filepath,
const std::chrono::system_clock::time_point& current_time) const {
// Try to get the last modified time of this file.
struct stat file_stat;
if (stat(filepath.c_str(), &file_stat) == 0) {
const auto last_modified_time =
std::chrono::system_clock::from_time_t(file_stat.st_mtime);
const auto diff = current_time - last_modified_time;
return diff >= overdue_;
}
// If failed to get file stat, don't return true!
return false;
}
|
O0
|
cpp
|
nglog::(anonymous namespace)::LogCleaner::IsLogLastModifiedOver(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::chrono::time_point<std::chrono::_V2::system_clock, std::chrono::duration<long, std::ratio<1l, 1000000000l>>> const&) const:
pushq %rbp
movq %rsp, %rbp
subq $0xd0, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0xc8(%rbp)
movq -0x18(%rbp), %rdi
callq 0x92b0
movq %rax, %rdi
leaq -0xb0(%rbp), %rsi
callq 0x9630
cmpl $0x0, %eax
jne 0x1c014
movq -0x58(%rbp), %rdi
callq 0x1ee20
movq %rax, -0xb8(%rbp)
movq -0x20(%rbp), %rdi
leaq -0xb8(%rbp), %rsi
callq 0x1edd0
movq -0xc8(%rbp), %rsi
movq %rax, -0xc0(%rbp)
addq $0x8, %rsi
leaq -0xc0(%rbp), %rdi
callq 0x20ee0
andb $0x1, %al
movb %al, -0x1(%rbp)
jmp 0x1c018
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0xd0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
_ZNK5nglog12_GLOBAL__N_110LogCleaner21IsLogLastModifiedOverERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNSt6chrono10time_pointINSA_3_V212system_clockENSA_8durationIlSt5ratioILl1ELl1000000000EEEEEE:
push rbp
mov rbp, rsp
sub rsp, 0D0h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov rax, [rbp+var_10]
mov [rbp+var_C8], rax
mov rdi, [rbp+var_18]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov rdi, rax
lea rsi, [rbp+var_B0]; __int64
call _stat
cmp eax, 0
jnz short loc_1C014
mov rdi, [rbp+var_58]; this
call _ZNSt6chrono3_V212system_clock11from_time_tEl; std::chrono::_V2::system_clock::from_time_t(long)
mov [rbp+var_B8], rax
mov rdi, [rbp+var_20]
lea rsi, [rbp+var_B8]
call _ZNSt6chronomiINS_3_V212system_clockENS_8durationIlSt5ratioILl1ELl1000000000EEEES6_EENSt11common_typeIJT0_T1_EE4typeERKNS_10time_pointIT_S8_EERKNSC_ISD_S9_EE; std::chrono::operator-<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>,std::chrono::duration<long,std::ratio<1l,1000000000l>>>(std::chrono::time_point<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>> const&,std::chrono::time_point<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>> const&)
mov rsi, [rbp+var_C8]
mov [rbp+var_C0], rax
add rsi, 8
lea rdi, [rbp+var_C0]
call _ZNSt6chronogeIlSt5ratioILl1ELl1000000000EElS1_ILl60ELl1EEEEbRKNS_8durationIT_T0_EERKNS4_IT1_T2_EE; std::chrono::operator>=<long,std::ratio<1l,1000000000l>,long,std::ratio<60l,1l>>(std::chrono::duration<long,std::ratio<1l,1000000000l>> const&,std::chrono::duration<long,std::ratio<60l,1l>> const&)
and al, 1
mov [rbp+var_1], al
jmp short loc_1C018
loc_1C014:
mov [rbp+var_1], 0
loc_1C018:
mov al, [rbp+var_1]
and al, 1
add rsp, 0D0h
pop rbp
retn
|
char nglog::`anonymous namespace'::LogCleaner::IsLogLastModifiedOver(long long a1, long long a2, long long a3)
{
long long v3; // rax
long long v5; // [rsp+10h] [rbp-C0h] BYREF
long long v6; // [rsp+18h] [rbp-B8h] BYREF
long long v7[18]; // [rsp+20h] [rbp-B0h] BYREF
long long v8; // [rsp+B0h] [rbp-20h]
long long v9; // [rsp+B8h] [rbp-18h]
long long v10; // [rsp+C0h] [rbp-10h]
v10 = a1;
v9 = a2;
v8 = a3;
v3 = std::string::c_str(a2);
if ( (unsigned int)stat(v3, v7) )
return 0;
v6 = std::chrono::_V2::system_clock::from_time_t((std::chrono::_V2::system_clock *)v7[11], (long long)v7);
v5 = std::chrono::operator-<std::chrono::_V2::system_clock,std::chrono::duration<long,std::ratio<1l,1000000000l>>,std::chrono::duration<long,std::ratio<1l,1000000000l>>>(
v8,
&v6);
return std::chrono::operator>=<long,std::ratio<1l,1000000000l>,long,std::ratio<60l,1l>>(&v5, a1 + 8) & 1;
}
|
IsLogLastModifiedOver:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xd0
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0xc8],RAX
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x001092b0
MOV RDI,RAX
LEA RSI,[RBP + -0xb0]
CALL 0x00109630
CMP EAX,0x0
JNZ 0x0011c014
MOV RDI,qword ptr [RBP + -0x58]
CALL 0x0011ee20
MOV qword ptr [RBP + -0xb8],RAX
MOV RDI,qword ptr [RBP + -0x20]
LEA RSI,[RBP + -0xb8]
CALL 0x0011edd0
MOV RSI,qword ptr [RBP + -0xc8]
MOV qword ptr [RBP + -0xc0],RAX
ADD RSI,0x8
LEA RDI,[RBP + -0xc0]
CALL 0x00120ee0
AND AL,0x1
MOV byte ptr [RBP + -0x1],AL
JMP 0x0011c018
LAB_0011c014:
MOV byte ptr [RBP + -0x1],0x0
LAB_0011c018:
MOV AL,byte ptr [RBP + -0x1]
AND AL,0x1
ADD RSP,0xd0
POP RBP
RET
|
/* nglog::(anonymous namespace)::LogCleaner::IsLogLastModifiedOver(std::__cxx11::string const&,
std::chrono::time_point<std::chrono::_V2::system_clock, std::chrono::duration<long,
std::ratio<1l, 1000000000l> > > const&) const */
int8 __thiscall
nglog::(anonymous_namespace)::LogCleaner::IsLogLastModifiedOver
(LogCleaner *this,string *param_1,time_point *param_2)
{
int iVar1;
char *__file;
int4 extraout_var_00;
int7 extraout_var;
int8 uVar2;
int8 local_c8;
int8 local_c0;
stat local_b8;
time_point *local_28;
string *local_20;
LogCleaner *local_18;
bool local_9;
local_28 = param_2;
local_20 = param_1;
local_18 = this;
__file = (char *)std::__cxx11::string::c_str();
iVar1 = stat(__file,&local_b8);
uVar2 = CONCAT44(extraout_var_00,iVar1);
if (iVar1 == 0) {
local_c0 = std::chrono::_V2::system_clock::from_time_t(local_b8.st_mtim.tv_sec);
local_c8 = std::chrono::operator-(local_28,(time_point *)&local_c0);
local_9 = std::chrono::operator>=((duration *)&local_c8,(duration *)(this + 8));
uVar2 = CONCAT71(extraout_var,local_9);
}
else {
local_9 = false;
}
return CONCAT71((int7)((ulong)uVar2 >> 8),local_9);
}
|
|
9,939 |
my_coll_parser_scan_setting
|
eloqsql/strings/ctype-uca.c
|
static int
my_coll_parser_scan_setting(MY_COLL_RULE_PARSER *p)
{
MY_COLL_RULES *rules= p->rules;
MY_COLL_LEXEM *lexem= my_coll_parser_curr(p);
if (!lex_cmp(lexem, C_STRING_WITH_LEN("[version 4.0.0]")))
{
rules->version= 400;
rules->uca= &my_uca_v400;
}
else if (!lex_cmp(lexem, C_STRING_WITH_LEN("[version 5.2.0]")))
{
rules->version= 520;
rules->uca= &my_uca_v520;
}
else if (!lex_cmp(lexem, C_STRING_WITH_LEN("[shift-after-method expand]")))
{
rules->shift_after_method= my_shift_method_expand;
}
else if (!lex_cmp(lexem, C_STRING_WITH_LEN("[shift-after-method simple]")))
{
rules->shift_after_method= my_shift_method_simple;
}
else if (!lex_cmp(lexem, C_STRING_WITH_LEN("[strength 1]")))
rules->strength= 1;
else if (!lex_cmp(lexem, C_STRING_WITH_LEN("[strength 2]")))
rules->strength= 2;
else
{
return 0;
}
return my_coll_parser_scan(p);
}
|
O0
|
c
|
my_coll_parser_scan_setting:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0xf0(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
callq 0x4d110
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
leaq 0x2d004(%rip), %rsi # 0x7a767
movl $0xf, %edx
callq 0x4d890
cmpl $0x0, %eax
jne 0x4d790
movq -0x18(%rbp), %rax
movl $0x190, (%rax) # imm = 0x190
movq -0x18(%rbp), %rax
leaq 0x2695d9(%rip), %rcx # 0x2b6d60
movq %rcx, 0x8(%rax)
jmp 0x4d87a
movq -0x20(%rbp), %rdi
leaq 0x2cfdc(%rip), %rsi # 0x7a777
movl $0xf, %edx
callq 0x4d890
cmpl $0x0, %eax
jne 0x4d7c8
movq -0x18(%rbp), %rax
movl $0x208, (%rax) # imm = 0x208
movq -0x18(%rbp), %rax
leaq 0x26e709(%rip), %rcx # 0x2bbec8
movq %rcx, 0x8(%rax)
jmp 0x4d878
movq -0x20(%rbp), %rdi
leaq 0x2cfb4(%rip), %rsi # 0x7a787
movl $0x1b, %edx
callq 0x4d890
cmpl $0x0, %eax
jne 0x4d7f2
movq -0x18(%rbp), %rax
movl $0x1, 0x30(%rax)
jmp 0x4d876
movq -0x20(%rbp), %rdi
leaq 0x2cfa6(%rip), %rsi # 0x7a7a3
movl $0x1b, %edx
callq 0x4d890
cmpl $0x0, %eax
jne 0x4d819
movq -0x18(%rbp), %rax
movl $0x0, 0x30(%rax)
jmp 0x4d874
movq -0x20(%rbp), %rdi
leaq 0x2cf9b(%rip), %rsi # 0x7a7bf
movl $0xc, %edx
callq 0x4d890
cmpl $0x0, %eax
jne 0x4d840
movq -0x18(%rbp), %rax
movl $0x1, 0x4(%rax)
jmp 0x4d872
movq -0x20(%rbp), %rdi
leaq 0x2c5b8(%rip), %rsi # 0x79e03
movl $0xc, %edx
callq 0x4d890
cmpl $0x0, %eax
jne 0x4d867
movq -0x18(%rbp), %rax
movl $0x2, 0x4(%rax)
jmp 0x4d870
movl $0x0, -0x4(%rbp)
jmp 0x4d886
jmp 0x4d872
jmp 0x4d874
jmp 0x4d876
jmp 0x4d878
jmp 0x4d87a
movq -0x10(%rbp), %rdi
callq 0x4d8f0
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
|
my_coll_parser_scan_setting:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov rax, [rbp+var_10]
mov rax, [rax+0F0h]
mov [rbp+var_18], rax
mov rdi, [rbp+var_10]
call my_coll_parser_curr
mov [rbp+var_20], rax
mov rdi, [rbp+var_20]
lea rsi, aVersion400; "[version 4.0.0]"
mov edx, 0Fh
call lex_cmp
cmp eax, 0
jnz short loc_4D790
mov rax, [rbp+var_18]
mov dword ptr [rax], 190h
mov rax, [rbp+var_18]
lea rcx, my_uca_v400
mov [rax+8], rcx
jmp loc_4D87A
loc_4D790:
mov rdi, [rbp+var_20]
lea rsi, aVersion520; "[version 5.2.0]"
mov edx, 0Fh
call lex_cmp
cmp eax, 0
jnz short loc_4D7C8
mov rax, [rbp+var_18]
mov dword ptr [rax], 208h
mov rax, [rbp+var_18]
lea rcx, my_uca_v520
mov [rax+8], rcx
jmp loc_4D878
loc_4D7C8:
mov rdi, [rbp+var_20]
lea rsi, aShiftAfterMeth; "[shift-after-method expand]"
mov edx, 1Bh
call lex_cmp
cmp eax, 0
jnz short loc_4D7F2
mov rax, [rbp+var_18]
mov dword ptr [rax+30h], 1
jmp loc_4D876
loc_4D7F2:
mov rdi, [rbp+var_20]
lea rsi, aShiftAfterMeth_0; "[shift-after-method simple]"
mov edx, 1Bh
call lex_cmp
cmp eax, 0
jnz short loc_4D819
mov rax, [rbp+var_18]
mov dword ptr [rax+30h], 0
jmp short loc_4D874
loc_4D819:
mov rdi, [rbp+var_20]
lea rsi, aStrength1; "[strength 1]"
mov edx, 0Ch
call lex_cmp
cmp eax, 0
jnz short loc_4D840
mov rax, [rbp+var_18]
mov dword ptr [rax+4], 1
jmp short loc_4D872
loc_4D840:
mov rdi, [rbp+var_20]
lea rsi, aStrength2; "[strength 2]"
mov edx, 0Ch
call lex_cmp
cmp eax, 0
jnz short loc_4D867
mov rax, [rbp+var_18]
mov dword ptr [rax+4], 2
jmp short loc_4D870
loc_4D867:
mov [rbp+var_4], 0
jmp short loc_4D886
loc_4D870:
jmp short $+2
loc_4D872:
jmp short $+2
loc_4D874:
jmp short $+2
loc_4D876:
jmp short $+2
loc_4D878:
jmp short $+2
loc_4D87A:
mov rdi, [rbp+var_10]
call my_coll_parser_scan
mov [rbp+var_4], eax
loc_4D886:
mov eax, [rbp+var_4]
add rsp, 20h
pop rbp
retn
|
long long my_coll_parser_scan_setting(long long a1)
{
long long v2; // [rsp+0h] [rbp-20h]
long long v3; // [rsp+8h] [rbp-18h]
v3 = *(_QWORD *)(a1 + 240);
v2 = my_coll_parser_curr(a1);
if ( !(unsigned int)lex_cmp(v2, "[version 4.0.0]", 15LL) )
{
*(_DWORD *)v3 = 400;
*(_QWORD *)(v3 + 8) = &my_uca_v400;
return (unsigned int)my_coll_parser_scan(a1);
}
if ( !(unsigned int)lex_cmp(v2, "[version 5.2.0]", 15LL) )
{
*(_DWORD *)v3 = 520;
*(_QWORD *)(v3 + 8) = &my_uca_v520;
return (unsigned int)my_coll_parser_scan(a1);
}
if ( !(unsigned int)lex_cmp(v2, "[shift-after-method expand]", 27LL) )
{
*(_DWORD *)(v3 + 48) = 1;
return (unsigned int)my_coll_parser_scan(a1);
}
if ( !(unsigned int)lex_cmp(v2, "[shift-after-method simple]", 27LL) )
{
*(_DWORD *)(v3 + 48) = 0;
return (unsigned int)my_coll_parser_scan(a1);
}
if ( !(unsigned int)lex_cmp(v2, "[strength 1]", 12LL) )
{
*(_DWORD *)(v3 + 4) = 1;
return (unsigned int)my_coll_parser_scan(a1);
}
if ( !(unsigned int)lex_cmp(v2, "[strength 2]", 12LL) )
{
*(_DWORD *)(v3 + 4) = 2;
return (unsigned int)my_coll_parser_scan(a1);
}
return 0;
}
|
my_coll_parser_scan_setting:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0xf0]
MOV qword ptr [RBP + -0x18],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0014d110
MOV qword ptr [RBP + -0x20],RAX
MOV RDI,qword ptr [RBP + -0x20]
LEA RSI,[0x17a767]
MOV EDX,0xf
CALL 0x0014d890
CMP EAX,0x0
JNZ 0x0014d790
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX],0x190
MOV RAX,qword ptr [RBP + -0x18]
LEA RCX,[0x3b6d60]
MOV qword ptr [RAX + 0x8],RCX
JMP 0x0014d87a
LAB_0014d790:
MOV RDI,qword ptr [RBP + -0x20]
LEA RSI,[0x17a777]
MOV EDX,0xf
CALL 0x0014d890
CMP EAX,0x0
JNZ 0x0014d7c8
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX],0x208
MOV RAX,qword ptr [RBP + -0x18]
LEA RCX,[0x3bbec8]
MOV qword ptr [RAX + 0x8],RCX
JMP 0x0014d878
LAB_0014d7c8:
MOV RDI,qword ptr [RBP + -0x20]
LEA RSI,[0x17a787]
MOV EDX,0x1b
CALL 0x0014d890
CMP EAX,0x0
JNZ 0x0014d7f2
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX + 0x30],0x1
JMP 0x0014d876
LAB_0014d7f2:
MOV RDI,qword ptr [RBP + -0x20]
LEA RSI,[0x17a7a3]
MOV EDX,0x1b
CALL 0x0014d890
CMP EAX,0x0
JNZ 0x0014d819
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX + 0x30],0x0
JMP 0x0014d874
LAB_0014d819:
MOV RDI,qword ptr [RBP + -0x20]
LEA RSI,[0x17a7bf]
MOV EDX,0xc
CALL 0x0014d890
CMP EAX,0x0
JNZ 0x0014d840
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX + 0x4],0x1
JMP 0x0014d872
LAB_0014d840:
MOV RDI,qword ptr [RBP + -0x20]
LEA RSI,[0x179e03]
MOV EDX,0xc
CALL 0x0014d890
CMP EAX,0x0
JNZ 0x0014d867
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX + 0x4],0x2
JMP 0x0014d870
LAB_0014d867:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0014d886
LAB_0014d870:
JMP 0x0014d872
LAB_0014d872:
JMP 0x0014d874
LAB_0014d874:
JMP 0x0014d876
LAB_0014d876:
JMP 0x0014d878
LAB_0014d878:
JMP 0x0014d87a
LAB_0014d87a:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0014d8f0
MOV dword ptr [RBP + -0x4],EAX
LAB_0014d886:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x20
POP RBP
RET
|
int4 my_coll_parser_scan_setting(long param_1)
{
int4 *puVar1;
int iVar2;
int4 uVar3;
int8 uVar4;
puVar1 = *(int4 **)(param_1 + 0xf0);
uVar4 = my_coll_parser_curr(param_1);
iVar2 = lex_cmp(uVar4,"[version 4.0.0]",0xf);
if (iVar2 == 0) {
*puVar1 = 400;
*(int1 **)(puVar1 + 2) = my_uca_v400;
}
else {
iVar2 = lex_cmp(uVar4,"[version 5.2.0]",0xf);
if (iVar2 == 0) {
*puVar1 = 0x208;
*(int1 **)(puVar1 + 2) = my_uca_v520;
}
else {
iVar2 = lex_cmp(uVar4,"[shift-after-method expand]",0x1b);
if (iVar2 == 0) {
puVar1[0xc] = 1;
}
else {
iVar2 = lex_cmp(uVar4,"[shift-after-method simple]",0x1b);
if (iVar2 == 0) {
puVar1[0xc] = 0;
}
else {
iVar2 = lex_cmp(uVar4,"[strength 1]",0xc);
if (iVar2 == 0) {
puVar1[1] = 1;
}
else {
iVar2 = lex_cmp(uVar4,"[strength 2]",0xc);
if (iVar2 != 0) {
return 0;
}
puVar1[1] = 2;
}
}
}
}
}
uVar3 = my_coll_parser_scan(param_1);
return uVar3;
}
|
|
9,940 |
mysql_change_user_start_internal
|
eloqsql/libmariadb/libmariadb/mariadb_async.c
|
static void
mysql_change_user_start_internal(void *d)
{
MK_ASYNC_INTERNAL_BODY(
mysql_change_user,
(parms->mysql, parms->user, parms->passwd, parms->db),
parms->mysql,
my_bool,
r_my_bool)
}
|
O0
|
c
|
mysql_change_user_start_internal:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rdx
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rcx
callq 0x41c80
movb %al, -0x11(%rbp)
movb -0x11(%rbp), %cl
movq -0x20(%rbp), %rax
movb %cl, 0x8(%rax)
movq -0x20(%rbp), %rax
movl $0x0, (%rax)
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
mysql_change_user_start_internal:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov [rbp+var_10], rax
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov [rbp+var_20], rax
mov rax, [rbp+var_10]
mov rdi, [rax]
mov rax, [rbp+var_10]
mov rsi, [rax+8]
mov rax, [rbp+var_10]
mov rdx, [rax+10h]
mov rax, [rbp+var_10]
mov rcx, [rax+18h]
call mysql_change_user
mov [rbp+var_11], al
mov cl, [rbp+var_11]
mov rax, [rbp+var_20]
mov [rax+8], cl
mov rax, [rbp+var_20]
mov dword ptr [rax], 0
add rsp, 20h
pop rbp
retn
|
long long mysql_change_user_start_internal(long long *a1)
{
long long result; // rax
long long v2; // [rsp+0h] [rbp-20h]
v2 = *(_QWORD *)(*(_QWORD *)(*a1 + 1152) + 40LL);
*(_BYTE *)(v2 + 8) = mysql_change_user(*a1, a1[1], a1[2], a1[3]);
result = v2;
*(_DWORD *)v2 = 0;
return result;
}
|
mysql_change_user_start_internal:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x18]
CALL 0x00141c80
MOV byte ptr [RBP + -0x11],AL
MOV CL,byte ptr [RBP + -0x11]
MOV RAX,qword ptr [RBP + -0x20]
MOV byte ptr [RAX + 0x8],CL
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX],0x0
ADD RSP,0x20
POP RBP
RET
|
void mysql_change_user_start_internal(long *param_1)
{
int4 *puVar1;
int1 uVar2;
puVar1 = *(int4 **)(*(long *)(*param_1 + 0x480) + 0x28);
uVar2 = mysql_change_user(*param_1,param_1[1],param_1[2],param_1[3]);
*(int1 *)(puVar1 + 2) = uVar2;
*puVar1 = 0;
return;
}
|
|
9,941 |
char const* google::protobuf::internal::VarintParse<unsigned long>(char const*, unsigned long*)
|
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/parse_context.h
|
PROTOBUF_NODISCARD const char* VarintParse(const char* p, T* out) {
auto ptr = reinterpret_cast<const uint8_t*>(p);
uint32_t res = ptr[0];
if (!(res & 0x80)) {
*out = res;
return p + 1;
}
uint32_t byte = ptr[1];
res += (byte - 1) << 7;
if (!(byte & 0x80)) {
*out = res;
return p + 2;
}
return VarintParseSlow(p, res, out);
}
|
O3
|
c
|
char const* google::protobuf::internal::VarintParse<unsigned long>(char const*, unsigned long*):
movq %rdi, %rax
movsbq (%rdi), %rdx
testq %rdx, %rdx
js 0xff0c6
movq %rdx, (%rsi)
incq %rax
retq
movzbl 0x1(%rax), %ecx
movl %ecx, %edi
shll $0x7, %edi
andl $0x7f, %edx
orq %rdi, %rdx
testb %cl, %cl
js 0xff0e1
movq %rdx, (%rsi)
addq $0x2, %rax
retq
addq $0x3, %rax
movl $0xe, %ecx
movq %rdx, %rdi
movzbl -0x1(%rax), %r8d
movq %r8, %rdx
decq %rdx
shlq %cl, %rdx
addq %rdi, %rdx
testb %r8b, %r8b
jns 0xff114
incq %rax
addq $0x7, %rcx
cmpq $0x46, %rcx
jne 0xff0ea
xorl %eax, %eax
xorl %edx, %edx
movq %rdx, (%rsi)
retq
|
_ZN6google8protobuf8internal11VarintParseImEEPKcS4_PT_:
mov rax, rdi
movsx rdx, byte ptr [rdi]
test rdx, rdx
js short loc_FF0C6
mov [rsi], rdx
inc rax
retn
loc_FF0C6:
movzx ecx, byte ptr [rax+1]
mov edi, ecx
shl edi, 7
and edx, 7Fh
or rdx, rdi
test cl, cl
js short loc_FF0E1
mov [rsi], rdx
add rax, 2
retn
loc_FF0E1:
add rax, 3
mov ecx, 0Eh
loc_FF0EA:
mov rdi, rdx
movzx r8d, byte ptr [rax-1]
mov rdx, r8
dec rdx
shl rdx, cl
add rdx, rdi
test r8b, r8b
jns short loc_FF114
inc rax
add rcx, 7
cmp rcx, 46h ; 'F'
jnz short loc_FF0EA
xor eax, eax
xor edx, edx
loc_FF114:
mov [rsi], rdx
retn
|
char * google::protobuf::internal::VarintParse<unsigned long>(char *a1, long long *a2)
{
long long v2; // rdx
char *result; // rax
unsigned long long v4; // rdx
long long v5; // rcx
v2 = *a1;
if ( v2 < 0 )
{
v4 = ((unsigned __int8)a1[1] << 7) | (unsigned long long)(v2 & 0x7F);
if ( a1[1] < 0 )
{
result = a1 + 3;
v5 = 14LL;
while ( 1 )
{
v4 += ((unsigned __int8)*(result - 1) - 1LL) << v5;
if ( *(result - 1) >= 0 )
break;
++result;
v5 += 7LL;
if ( v5 == 70 )
{
result = 0LL;
v4 = 0LL;
break;
}
}
*a2 = v4;
}
else
{
*a2 = v4;
return a1 + 2;
}
}
else
{
*a2 = v2;
return a1 + 1;
}
return result;
}
|
VarintParse<unsigned_long>:
MOV RAX,RDI
MOVSX RDX,byte ptr [RDI]
TEST RDX,RDX
JS 0x001ff0c6
MOV qword ptr [RSI],RDX
INC RAX
RET
LAB_001ff0c6:
MOVZX ECX,byte ptr [RAX + 0x1]
MOV EDI,ECX
SHL EDI,0x7
AND EDX,0x7f
OR RDX,RDI
TEST CL,CL
JS 0x001ff0e1
MOV qword ptr [RSI],RDX
ADD RAX,0x2
RET
LAB_001ff0e1:
ADD RAX,0x3
MOV ECX,0xe
LAB_001ff0ea:
MOV RDI,RDX
MOVZX R8D,byte ptr [RAX + -0x1]
MOV RDX,R8
DEC RDX
SHL RDX,CL
ADD RDX,RDI
TEST R8B,R8B
JNS 0x001ff114
INC RAX
ADD RCX,0x7
CMP RCX,0x46
JNZ 0x001ff0ea
XOR EAX,EAX
XOR EDX,EDX
LAB_001ff114:
MOV qword ptr [RSI],RDX
RET
|
/* char const* google::protobuf::internal::VarintParse<unsigned long>(char const*, unsigned long*)
*/
char * google::protobuf::internal::VarintParse<unsigned_long>(char *param_1,ulong *param_2)
{
char cVar1;
char *pcVar2;
long lVar3;
ulong uVar4;
cVar1 = *param_1;
if (-1 < (long)cVar1) {
*param_2 = (long)cVar1;
return param_1 + 1;
}
uVar4 = (ulong)((int)cVar1 & 0x7fU | (uint)(byte)param_1[1] << 7);
if (-1 < param_1[1]) {
*param_2 = uVar4;
return param_1 + 2;
}
pcVar2 = param_1 + 3;
lVar3 = 0xe;
do {
uVar4 = ((ulong)(byte)pcVar2[-1] - 1 << ((byte)lVar3 & 0x3f)) + uVar4;
if (-1 < pcVar2[-1]) goto LAB_001ff114;
pcVar2 = pcVar2 + 1;
lVar3 = lVar3 + 7;
} while (lVar3 != 0x46);
pcVar2 = (char *)0x0;
uVar4 = 0;
LAB_001ff114:
*param_2 = uVar4;
return pcVar2;
}
|
|
9,942 |
wait_on_queue
|
eloqsql/mysys/mf_keycache.c
|
static void wait_on_queue(KEYCACHE_WQUEUE *wqueue,
mysql_mutex_t *mutex)
{
struct st_my_thread_var *last;
struct st_my_thread_var *thread= my_thread_var;
DBUG_ASSERT(!thread->next);
DBUG_ASSERT(!thread->prev); /* Not required, but must be true anyway. */
mysql_mutex_assert_owner(mutex);
/* Add to queue. */
if (! (last= wqueue->last_thread))
thread->next= thread;
else
{
thread->next= last->next;
last->next= thread;
}
wqueue->last_thread= thread;
/*
Wait until thread is removed from queue by the signaling thread.
The loop protects against stray signals.
*/
do
{
KEYCACHE_DBUG_PRINT("wait", ("suspend thread %ld", (ulong) thread->id));
keycache_pthread_cond_wait(&thread->suspend, mutex);
}
while (thread->next);
}
|
O3
|
c
|
wait_on_queue:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r15
callq 0x5be8e
movq %rax, %r14
movq %rax, %r12
movq (%r15), %rax
testq %rax, %rax
je 0x528bb
movq 0x88(%rax), %rcx
addq $0x88, %rax
movq %rcx, 0x88(%r12)
jmp 0x528c2
leaq 0x88(%r14), %rax
movq %r12, (%rax)
movq %r12, (%r15)
addq $0x8, %r14
leaq 0x401dc(%rip), %r15 # 0x92aaf
cmpq $0x0, 0x38(%r12)
jne 0x528f3
movq %r14, %rdi
movq %rbx, %rsi
callq 0x285e0
cmpq $0x0, 0x88(%r12)
jne 0x528d3
jmp 0x52908
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
movl $0x477, %ecx # imm = 0x477
callq 0x2a1ed
jmp 0x528e6
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
|
wait_on_queue:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
mov rbx, rsi
mov r15, rdi
call _my_thread_var
mov r14, rax
mov r12, rax
mov rax, [r15]
test rax, rax
jz short loc_528BB
mov rcx, [rax+88h]
add rax, 88h
mov [r12+88h], rcx
jmp short loc_528C2
loc_528BB:
lea rax, [r14+88h]
loc_528C2:
mov [rax], r12
mov [r15], r12
add r14, 8
lea r15, aWorkspaceLlm4b_21; "/workspace/llm4binary/github2025/eloqsq"...
loc_528D3:
cmp qword ptr [r12+38h], 0
jnz short loc_528F3
mov rdi, r14
mov rsi, rbx
call _pthread_cond_wait
loc_528E6:
cmp qword ptr [r12+88h], 0
jnz short loc_528D3
jmp short loc_52908
loc_528F3:
mov rdi, r14
mov rsi, rbx
mov rdx, r15
mov ecx, 477h
call psi_cond_wait
jmp short loc_528E6
loc_52908:
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
|
long long wait_on_queue(long long *a1, long long a2)
{
long long v2; // r14
long long v3; // r12
long long v4; // rax
long long v5; // rcx
long long *v6; // rax
long long v7; // r14
long long result; // rax
v2 = my_thread_var(a1);
v3 = v2;
v4 = *a1;
if ( *a1 )
{
v5 = *(_QWORD *)(v4 + 136);
v6 = (long long *)(v4 + 136);
*(_QWORD *)(v2 + 136) = v5;
}
else
{
v6 = (long long *)(v2 + 136);
}
*v6 = v2;
*a1 = v2;
v7 = v2 + 8;
do
{
if ( *(_QWORD *)(v3 + 56) )
result = psi_cond_wait(v7, a2, (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/mf_keycache.c", 0x477u);
else
result = pthread_cond_wait(v7, a2);
}
while ( *(_QWORD *)(v3 + 136) );
return result;
}
|
wait_on_queue:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV RBX,RSI
MOV R15,RDI
CALL 0x0015be8e
MOV R14,RAX
MOV R12,RAX
MOV RAX,qword ptr [R15]
TEST RAX,RAX
JZ 0x001528bb
MOV RCX,qword ptr [RAX + 0x88]
ADD RAX,0x88
MOV qword ptr [R12 + 0x88],RCX
JMP 0x001528c2
LAB_001528bb:
LEA RAX,[R14 + 0x88]
LAB_001528c2:
MOV qword ptr [RAX],R12
MOV qword ptr [R15],R12
ADD R14,0x8
LEA R15,[0x192aaf]
LAB_001528d3:
CMP qword ptr [R12 + 0x38],0x0
JNZ 0x001528f3
MOV RDI,R14
MOV RSI,RBX
CALL 0x001285e0
LAB_001528e6:
CMP qword ptr [R12 + 0x88],0x0
JNZ 0x001528d3
JMP 0x00152908
LAB_001528f3:
MOV RDI,R14
MOV RSI,RBX
MOV RDX,R15
MOV ECX,0x477
CALL 0x0012a1ed
JMP 0x001528e6
LAB_00152908:
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
void wait_on_queue(long *param_1,pthread_mutex_t *param_2)
{
long lVar1;
long lVar2;
long lVar3;
lVar3 = _my_thread_var();
lVar1 = *param_1;
lVar2 = lVar3;
if (lVar1 != 0) {
*(int8 *)(lVar3 + 0x88) = *(int8 *)(lVar1 + 0x88);
lVar2 = lVar1;
}
*(long *)(lVar2 + 0x88) = lVar3;
*param_1 = lVar3;
do {
if (*(long *)(lVar3 + 0x38) == 0) {
pthread_cond_wait((pthread_cond_t *)(lVar3 + 8),param_2);
}
else {
psi_cond_wait((pthread_cond_t *)(lVar3 + 8),param_2,
"/workspace/llm4binary/github2025/eloqsql/mysys/mf_keycache.c",0x477);
}
} while (*(long *)(lVar3 + 0x88) != 0);
return;
}
|
|
9,943 |
ImPlot::ShowAltLegend(char const*, bool, ImVec2, bool)
|
zkingston[P]unknot/build_O1/_deps/implot-src/implot.cpp
|
void ShowAltLegend(const char* title_id, bool vertical, const ImVec2 size, bool interactable) {
ImPlotContext& gp = *GImPlot;
ImGuiContext &G = *GImGui;
ImGuiWindow * Window = G.CurrentWindow;
if (Window->SkipItems)
return;
ImDrawList &DrawList = *Window->DrawList;
ImPlotPlot* plot = GetPlot(title_id);
ImVec2 legend_size;
ImVec2 default_size = gp.Style.LegendPadding * 2;
if (plot != nullptr) {
legend_size = CalcLegendSize(plot->Items, gp.Style.LegendInnerPadding, gp.Style.LegendSpacing, vertical);
default_size = legend_size + gp.Style.LegendPadding * 2;
}
ImVec2 frame_size = ImGui::CalcItemSize(size, default_size.x, default_size.y);
ImRect bb_frame = ImRect(Window->DC.CursorPos, Window->DC.CursorPos + frame_size);
ImGui::ItemSize(bb_frame);
if (!ImGui::ItemAdd(bb_frame, 0, &bb_frame))
return;
ImGui::RenderFrame(bb_frame.Min, bb_frame.Max, GetStyleColorU32(ImPlotCol_FrameBg), true, G.Style.FrameRounding);
DrawList.PushClipRect(bb_frame.Min, bb_frame.Max, true);
if (plot != nullptr) {
const ImVec2 legend_pos = GetLocationPos(bb_frame, legend_size, 0, gp.Style.LegendPadding);
const ImRect legend_bb(legend_pos, legend_pos + legend_size);
interactable = interactable && bb_frame.Contains(ImGui::GetIO().MousePos);
// render legend box
ImU32 col_bg = GetStyleColorU32(ImPlotCol_LegendBg);
ImU32 col_bd = GetStyleColorU32(ImPlotCol_LegendBorder);
DrawList.AddRectFilled(legend_bb.Min, legend_bb.Max, col_bg);
DrawList.AddRect(legend_bb.Min, legend_bb.Max, col_bd);
// render entries
ShowLegendEntries(plot->Items, legend_bb, interactable, gp.Style.LegendInnerPadding, gp.Style.LegendSpacing, vertical, DrawList);
}
DrawList.PopClipRect();
}
|
O1
|
cpp
|
ImPlot::ShowAltLegend(char const*, bool, ImVec2, bool):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
leaq 0x27459b(%rip), %rax # 0x337030
movq (%rax), %rbx
movq 0x1368(%rbx), %r13
cmpb $0x0, 0xcf(%r13)
jne 0xc2df4
movl %edx, %ebp
movaps %xmm0, 0x20(%rsp)
movl %esi, 0xc(%rsp)
movq 0x2741e1(%rip), %r15 # 0x336ca0
movq 0x2b0(%r13), %r14
callq 0xae1cb
movq %rax, %r12
testq %rax, %rax
je 0xc2b09
leaq 0x8f8(%r12), %rdi
leaq 0x178(%r15), %rsi
leaq 0x180(%r15), %rdx
movzbl 0xc(%rsp), %ecx
callq 0xae2e9
movsd 0x170(%r15), %xmm1
addps %xmm1, %xmm1
movaps %xmm0, 0x30(%rsp)
addps %xmm0, %xmm1
jmp 0xc2b1d
movsd 0x170(%r15), %xmm1
addps %xmm1, %xmm1
xorps %xmm0, %xmm0
movaps %xmm0, 0x30(%rsp)
movaps %xmm1, %xmm2
shufps $0x55, %xmm1, %xmm2 # xmm2 = xmm2[1,1],xmm1[1,1]
movaps 0x20(%rsp), %xmm0
callq 0x2263c1
movsd 0x118(%r13), %xmm1
addps %xmm1, %xmm0
movaps %xmm1, %xmm2
movlhps %xmm0, %xmm2 # xmm2 = xmm2[0],xmm0[0]
leaq 0x10(%rsp), %r13
movups %xmm2, (%r13)
subps %xmm1, %xmm0
leaq 0x40(%rsp), %rdi
movlps %xmm0, (%rdi)
movss 0x1cc4a7(%rip), %xmm0 # 0x28f004
callq 0x226733
movq %r13, %rdi
xorl %esi, %esi
movq %r13, %rdx
xorl %ecx, %ecx
callq 0x2268b6
testb %al, %al
je 0xc2df4
leaq 0x18(%rsp), %r13
movsd -0x8(%r13), %xmm0
movaps %xmm0, 0x20(%rsp)
movsd (%r13), %xmm0
movaps %xmm0, 0x60(%rsp)
movq 0x274105(%rip), %rcx # 0x336ca0
movss 0x20c(%rcx), %xmm0
ucomiss 0x1cc45a(%rip), %xmm0 # 0x28f004
jne 0xc2bc1
jp 0xc2bc1
movl $0x7, %edi
callq 0x215eee
movq %rax, %rcx
addq $0x8, %rcx
jmp 0xc2bcf
leaq 0x200(%rcx), %rax
addq $0x208, %rcx # imm = 0x208
movsd (%rax), %xmm0
movhps (%rcx), %xmm0 # xmm0 = xmm0[0,1],mem[0,1]
leaq 0x40(%rsp), %rdi
movups %xmm0, (%rdi)
callq 0x213cfe
movss 0xc34(%rbx), %xmm2
movaps 0x20(%rsp), %xmm0
movaps 0x60(%rsp), %xmm1
movl %eax, %edi
movl $0x1, %esi
callq 0x217467
leaq 0x10(%rsp), %rsi
movq %r14, %rdi
movq %r13, %rdx
movl $0x1, %ecx
callq 0x23abf8
testq %r12, %r12
je 0xc2dec
movsd 0x10(%rsp), %xmm0
movsd 0x18(%rsp), %xmm1
addps %xmm0, %xmm1
movaps 0x1d17bb(%rip), %xmm0 # 0x2943f0
mulps %xmm0, %xmm1
movaps 0x30(%rsp), %xmm3
movaps %xmm3, %xmm2
mulps %xmm0, %xmm2
subps %xmm2, %xmm1
addps %xmm0, %xmm1
cvttps2dq %xmm1, %xmm0
cvtdq2ps %xmm0, %xmm0
addps %xmm0, %xmm3
movlhps %xmm3, %xmm0 # xmm0 = xmm0[0],xmm3[0]
movups %xmm0, 0x50(%rsp)
testb %bpl, %bpl
je 0xc2c78
callq 0x21ac26
movss 0xe0(%rax), %xmm1
ucomiss 0x10(%rsp), %xmm1
jae 0xc2d26
xorl %eax, %eax
movl %eax, 0x20(%rsp)
movq 0x27401b(%rip), %rcx # 0x336ca0
movss 0x23c(%rcx), %xmm0
ucomiss 0x1cc370(%rip), %xmm0 # 0x28f004
jne 0xc2cab
jp 0xc2cab
movl $0x4, %edi
callq 0x215eee
movq %rax, %rcx
addq $0x8, %rcx
jmp 0xc2cb9
leaq 0x230(%rcx), %rax
addq $0x238, %rcx # imm = 0x238
leaq 0x58(%rsp), %rbx
movsd (%rax), %xmm0
movhps (%rcx), %xmm0 # xmm0 = xmm0[0,1],mem[0,1]
leaq 0x40(%rsp), %rdi
movups %xmm0, (%rdi)
callq 0x213cfe
movl %eax, 0x30(%rsp)
movq 0x273fc3(%rip), %rcx # 0x336ca0
movss 0x24c(%rcx), %xmm0
ucomiss 0x1cc318(%rip), %xmm0 # 0x28f004
jne 0xc2d16
jp 0xc2d16
movss 0x22c(%rcx), %xmm0
ucomiss 0x1cc305(%rip), %xmm0 # 0x28f004
jne 0xc2d5b
jp 0xc2d5b
movl $0x5, %edi
callq 0x215eee
movq %rax, %rcx
addq $0x8, %rcx
jmp 0xc2d69
leaq 0x240(%rcx), %rax
addq $0x248, %rcx # imm = 0x248
jmp 0xc2d69
movss 0xe4(%rax), %xmm0
xorl %eax, %eax
ucomiss 0x14(%rsp), %xmm0
jb 0xc2c7a
movss 0x18(%rsp), %xmm2
ucomiss %xmm1, %xmm2
jbe 0xc2c7a
movss 0x1c(%rsp), %xmm1
ucomiss %xmm0, %xmm1
seta %al
jmp 0xc2c7a
leaq 0x220(%rcx), %rax
addq $0x228, %rcx # imm = 0x228
movsd (%rax), %xmm0
movhps (%rcx), %xmm0 # xmm0 = xmm0[0,1],mem[0,1]
leaq 0x40(%rsp), %rdi
movups %xmm0, (%rdi)
callq 0x213cfe
movl %eax, %ebp
leaq 0x50(%rsp), %r13
xorps %xmm0, %xmm0
movq %r14, %rdi
movq %r13, %rsi
movq %rbx, %rdx
movl 0x30(%rsp), %ecx
xorl %r8d, %r8d
callq 0x23dbe4
movss 0x1cc264(%rip), %xmm1 # 0x28f008
xorps %xmm0, %xmm0
movq %r14, %rdi
movq %r13, %rsi
movq %rbx, %rdx
movl %ebp, %ecx
xorl %r8d, %r8d
callq 0x23db44
addq $0x8f8, %r12 # imm = 0x8F8
leaq 0x178(%r15), %rcx
addq $0x180, %r15 # imm = 0x180
movq %r14, (%rsp)
movzbl 0x20(%rsp), %edx
movzbl 0xc(%rsp), %r9d
movq %r12, %rdi
movq %r13, %rsi
movq %r15, %r8
callq 0xae45f
movq %r14, %rdi
callq 0x23ad78
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
_ZN6ImPlot13ShowAltLegendEPKcb6ImVec2b:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 78h
lea rax, GImGui
mov rbx, [rax]
mov r13, [rbx+1368h]
cmp byte ptr [r13+0CFh], 0
jnz loc_C2DF4
mov ebp, edx
movaps [rsp+0A8h+var_88], xmm0
mov [rsp+0A8h+var_9C], esi
mov r15, cs:GImPlot
mov r14, [r13+2B0h]
call _ZN6ImPlot7GetPlotEPKc; ImPlot::GetPlot(char const*)
mov r12, rax
test rax, rax
jz short loc_C2B09
lea rdi, [r12+8F8h]
lea rsi, [r15+178h]
lea rdx, [r15+180h]
movzx ecx, byte ptr [rsp+0A8h+var_9C]
call _ZN6ImPlot14CalcLegendSizeER15ImPlotItemGroupRK6ImVec2S4_b; ImPlot::CalcLegendSize(ImPlotItemGroup &,ImVec2 const&,ImVec2 const&,bool)
movsd xmm1, qword ptr [r15+170h]
addps xmm1, xmm1
movaps [rsp+0A8h+var_78], xmm0
addps xmm1, xmm0
jmp short loc_C2B1D
loc_C2B09:
movsd xmm1, qword ptr [r15+170h]
addps xmm1, xmm1
xorps xmm0, xmm0
movaps [rsp+0A8h+var_78], xmm0
loc_C2B1D:
movaps xmm2, xmm1
shufps xmm2, xmm1, 55h ; 'U'
movaps xmm0, [rsp+0A8h+var_88]
call _ZN5ImGui12CalcItemSizeE6ImVec2ff; ImGui::CalcItemSize(ImVec2,float,float)
movsd xmm1, qword ptr [r13+118h]
addps xmm0, xmm1
movaps xmm2, xmm1
movlhps xmm2, xmm0
lea r13, [rsp+0A8h+var_98]
movups xmmword ptr [r13+0], xmm2
subps xmm0, xmm1
lea rdi, [rsp+0A8h+var_68]
movlps qword ptr [rdi], xmm0
movss xmm0, cs:flt_28F004
call _ZN5ImGui8ItemSizeERK6ImVec2f; ImGui::ItemSize(ImVec2 const&,float)
mov rdi, r13
xor esi, esi; int
mov rdx, r13
xor ecx, ecx
call _ZN5ImGui7ItemAddERK6ImRectjPS1_i; ImGui::ItemAdd(ImRect const&,uint,ImRect const*,int)
test al, al
jz loc_C2DF4
lea r13, [rsp+0A8h+var_90]
movsd xmm0, qword ptr [r13-8]
movaps [rsp+0A8h+var_88], xmm0
movsd xmm0, qword ptr [r13+0]
movaps [rsp+0A8h+var_48], xmm0
mov rcx, cs:GImPlot
movss xmm0, dword ptr [rcx+20Ch]
ucomiss xmm0, cs:flt_28F004
jnz short loc_C2BC1
jp short loc_C2BC1
mov edi, offset byte_7; this
call _ZN5ImGui17GetStyleColorVec4Ei; ImGui::GetStyleColorVec4(int)
mov rcx, rax
add rcx, 8
jmp short loc_C2BCF
loc_C2BC1:
lea rax, [rcx+200h]
add rcx, 208h
loc_C2BCF:
movsd xmm0, qword ptr [rax]
movhps xmm0, qword ptr [rcx]
lea rdi, [rsp+0A8h+var_68]
movups xmmword ptr [rdi], xmm0
call _ZN5ImGui23ColorConvertFloat4ToU32ERK6ImVec4; ImGui::ColorConvertFloat4ToU32(ImVec4 const&)
movss xmm2, dword ptr [rbx+0C34h]
movaps xmm0, [rsp+0A8h+var_88]
movaps xmm1, [rsp+0A8h+var_48]
mov edi, eax
mov esi, 1
call _ZN5ImGui11RenderFrameE6ImVec2S0_jbf; ImGui::RenderFrame(ImVec2,ImVec2,uint,bool,float)
lea rsi, [rsp+0A8h+var_98]; int
mov rdi, r14; this
mov rdx, r13
mov ecx, 1
call _ZN10ImDrawList12PushClipRectERK6ImVec2S2_b; ImDrawList::PushClipRect(ImVec2 const&,ImVec2 const&,bool)
test r12, r12
jz loc_C2DEC
movsd xmm0, qword ptr [rsp+0A8h+var_98]
movsd xmm1, [rsp+0A8h+var_90]
addps xmm1, xmm0
movaps xmm0, cs:xmmword_2943F0
mulps xmm1, xmm0
movaps xmm3, [rsp+0A8h+var_78]
movaps xmm2, xmm3
mulps xmm2, xmm0
subps xmm1, xmm2
addps xmm1, xmm0
cvttps2dq xmm0, xmm1
cvtdq2ps xmm0, xmm0
addps xmm3, xmm0
movlhps xmm0, xmm3
movups xmmword ptr [rsp+0A8h+var_58], xmm0
test bpl, bpl
jz short loc_C2C78
call _ZN5ImGui5GetIOEv; ImGui::GetIO(void)
movss xmm1, dword ptr [rax+0E0h]
ucomiss xmm1, [rsp+0A8h+var_98]
jnb loc_C2D26
loc_C2C78:
xor eax, eax
loc_C2C7A:
mov dword ptr [rsp+0A8h+var_88], eax
mov rcx, cs:GImPlot
movss xmm0, dword ptr [rcx+23Ch]
ucomiss xmm0, cs:flt_28F004
jnz short loc_C2CAB
jp short loc_C2CAB
mov edi, offset byte_4; this
call _ZN5ImGui17GetStyleColorVec4Ei; ImGui::GetStyleColorVec4(int)
mov rcx, rax
add rcx, 8
jmp short loc_C2CB9
loc_C2CAB:
lea rax, [rcx+230h]
add rcx, 238h
loc_C2CB9:
lea rbx, [rsp+0A8h+var_58+8]
movsd xmm0, qword ptr [rax]
movhps xmm0, qword ptr [rcx]
lea rdi, [rsp+0A8h+var_68]
movups xmmword ptr [rdi], xmm0
call _ZN5ImGui23ColorConvertFloat4ToU32ERK6ImVec4; ImGui::ColorConvertFloat4ToU32(ImVec4 const&)
mov dword ptr [rsp+0A8h+var_78], eax
mov rcx, cs:GImPlot
movss xmm0, dword ptr [rcx+24Ch]
ucomiss xmm0, cs:flt_28F004
jnz short loc_C2D16
jp short loc_C2D16
movss xmm0, dword ptr [rcx+22Ch]
ucomiss xmm0, cs:flt_28F004
jnz short loc_C2D5B
jp short loc_C2D5B
mov edi, offset byte_5; this
call _ZN5ImGui17GetStyleColorVec4Ei; ImGui::GetStyleColorVec4(int)
mov rcx, rax
add rcx, 8
jmp short loc_C2D69
loc_C2D16:
lea rax, [rcx+240h]
add rcx, 248h
jmp short loc_C2D69
loc_C2D26:
movss xmm0, dword ptr [rax+0E4h]
xor eax, eax
ucomiss xmm0, [rsp+0A8h+var_98+4]
jb loc_C2C7A
movss xmm2, dword ptr [rsp+0A8h+var_90]
ucomiss xmm2, xmm1
jbe loc_C2C7A
movss xmm1, dword ptr [rsp+0A8h+var_90+4]
ucomiss xmm1, xmm0
setnbe al
jmp loc_C2C7A
loc_C2D5B:
lea rax, [rcx+220h]
add rcx, 228h
loc_C2D69:
movsd xmm0, qword ptr [rax]
movhps xmm0, qword ptr [rcx]
lea rdi, [rsp+0A8h+var_68]
movups xmmword ptr [rdi], xmm0
call _ZN5ImGui23ColorConvertFloat4ToU32ERK6ImVec4; ImGui::ColorConvertFloat4ToU32(ImVec4 const&)
mov ebp, eax
lea r13, [rsp+0A8h+var_58]
xorps xmm0, xmm0
mov rdi, r14; this
mov rsi, r13
mov rdx, rbx
mov ecx, dword ptr [rsp+0A8h+var_78]
xor r8d, r8d
call _ZN10ImDrawList13AddRectFilledERK6ImVec2S2_jfi; ImDrawList::AddRectFilled(ImVec2 const&,ImVec2 const&,uint,float,int)
movss xmm1, cs:flt_28F008
xorps xmm0, xmm0
mov rdi, r14; this
mov rsi, r13
mov rdx, rbx
mov ecx, ebp
xor r8d, r8d
call _ZN10ImDrawList7AddRectERK6ImVec2S2_jfif; ImDrawList::AddRect(ImVec2 const&,ImVec2 const&,uint,float,int,float)
add r12, 8F8h
lea rcx, [r15+178h]; int
add r15, 180h
mov [rsp+0A8h+var_A8], r14; ImDrawList *
movzx edx, byte ptr [rsp+0A8h+var_88]; int
movzx r9d, byte ptr [rsp+0A8h+var_9C]; int
mov rdi, r12; int
mov rsi, r13; int
mov r8, r15; int
call _ZN6ImPlot17ShowLegendEntriesER15ImPlotItemGroupRK6ImRectbRK6ImVec2S7_bR10ImDrawList; ImPlot::ShowLegendEntries(ImPlotItemGroup &,ImRect const&,bool,ImVec2 const&,ImVec2 const&,bool,ImDrawList &)
loc_C2DEC:
mov rdi, r14; this
call _ZN10ImDrawList11PopClipRectEv; ImDrawList::PopClipRect(void)
loc_C2DF4:
add rsp, 78h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
ImGui ** ImPlot::ShowAltLegend(ImPlot *a1, const char *a2, char a3, __m128 a4)
{
ImGui **result; // rax
ImGui *v5; // rbx
long long v6; // r13
ImGui *v8; // r15
ImDrawList *v9; // r14
long long Plot; // rax
long long v11; // r12
__m128 v12; // xmm0
__m128 v13; // xmm1
__m128 v14; // xmm1
__m128 v15; // xmm0
__m128 v16; // xmm1
__m128 v17; // xmm0
const double *v18; // rcx
unsigned int v19; // eax
__m128 v20; // xmm0
long long IO; // rax
float v22; // xmm1_4
__int32 v23; // eax
const double *v24; // rcx
const double *v25; // rcx
float v26; // xmm0_4
unsigned __int8 v27; // [rsp+Ch] [rbp-9Ch]
__m128 v28; // [rsp+10h] [rbp-98h] BYREF
__m128 v29; // [rsp+20h] [rbp-88h]
__m128 v30; // [rsp+30h] [rbp-78h]
__m128 v31; // [rsp+40h] [rbp-68h] BYREF
int v32[4]; // [rsp+50h] [rbp-58h] BYREF
double v33[9]; // [rsp+60h] [rbp-48h]
result = &GImGui;
v5 = GImGui;
v6 = *((_QWORD *)GImGui + 621);
if ( !*(_BYTE *)(v6 + 207) )
{
v29 = a4;
v27 = (unsigned __int8)a2;
v8 = GImPlot;
v9 = *(ImDrawList **)(v6 + 688);
Plot = ImPlot::GetPlot(a1, a2);
v11 = Plot;
if ( Plot )
{
a2 = (char *)v8 + 376;
v12 = ImPlot::CalcLegendSize(Plot + 2296, (float *)v8 + 94, (float *)v8 + 96, v27, a4);
v13 = _mm_add_ps((__m128)*((unsigned long long *)v8 + 46), (__m128)*((unsigned long long *)v8 + 46));
v30 = v12;
v14 = _mm_add_ps(v13, v12);
}
else
{
v14 = _mm_add_ps((__m128)*((unsigned long long *)v8 + 46), (__m128)*((unsigned long long *)v8 + 46));
v30 = 0LL;
}
v15.m128_u64[1] = v29.m128_u64[1];
*(double *)v15.m128_u64 = ImGui::CalcItemSize(
*(double *)v29.m128_u64,
v14.m128_f32[0],
_mm_shuffle_ps(v14, v14, 85).m128_f32[0]);
v16 = (__m128)*(unsigned long long *)(v6 + 280);
v17 = _mm_add_ps(v15, v16);
v28 = _mm_movelh_ps(v16, v17);
_mm_storel_ps((double *)v31.m128_u64, _mm_sub_ps(v17, v16));
ImGui::ItemSize(&v31, a2, -1.0);
result = (ImGui **)ImGui::ItemAdd(&v28, 0LL, &v28, 0LL);
if ( (_BYTE)result )
{
v29 = (__m128)v28.m128_u64[0];
*(_OWORD *)v33 = v28.m128_u64[1];
if ( *((float *)GImPlot + 131) == -1.0 )
v18 = (const double *)(ImGui::GetStyleColorVec4((ImGui *)&byte_7, 0) + 8);
else
v18 = (const double *)((char *)GImPlot + 520);
v31 = _mm_loadh_ps(v18);
v19 = ImGui::ColorConvertFloat4ToU32(&v31);
ImGui::RenderFrame(v19, 1LL, *(double *)v29.m128_u64, v33[0], *((float *)v5 + 781));
ImDrawList::PushClipRect(v9);
if ( v11 )
{
v20 = _mm_cvtepi32_ps(
_mm_cvttps_epi32(
_mm_add_ps(
_mm_sub_ps(
_mm_mul_ps(_mm_add_ps((__m128)v28.m128_u64[1], (__m128)v28.m128_u64[0]), (__m128)xmmword_2943F0),
_mm_mul_ps(v30, (__m128)xmmword_2943F0)),
(__m128)xmmword_2943F0)));
*(__m128 *)v32 = _mm_movelh_ps(v20, _mm_add_ps(v30, v20));
if ( a3 && (IO = ImGui::GetIO(v9), v22 = *(float *)(IO + 224), v22 >= v28.m128_f32[0]) )
{
v26 = *(float *)(IO + 228);
v23 = 0;
if ( v26 >= v28.m128_f32[1] && v28.m128_f32[2] > v22 )
LOBYTE(v23) = v28.m128_f32[3] > v26;
}
else
{
v23 = 0;
}
v29.m128_i32[0] = v23;
if ( *((float *)GImPlot + 143) == -1.0 )
v24 = (const double *)(ImGui::GetStyleColorVec4((ImGui *)&byte_4, (int)&v28) + 8);
else
v24 = (const double *)((char *)GImPlot + 568);
v31 = _mm_loadh_ps(v24);
v30.m128_i32[0] = ImGui::ColorConvertFloat4ToU32(&v31);
if ( *((float *)GImPlot + 147) == -1.0 )
{
if ( *((float *)GImPlot + 139) == -1.0 )
v25 = (const double *)(ImGui::GetStyleColorVec4((ImGui *)&byte_5, (int)&v28) + 8);
else
v25 = (const double *)((char *)GImPlot + 552);
}
else
{
v25 = (const double *)((char *)GImPlot + 584);
}
v31 = _mm_loadh_ps(v25);
ImGui::ColorConvertFloat4ToU32(&v31);
ImDrawList::AddRectFilled(v9);
ImDrawList::AddRect(v9);
ImPlot::ShowLegendEntries(
v11 + 2296,
(unsigned long long)v32,
v29.m128_u8[0],
(float *)v8 + 94,
(long long)v8 + 384,
v27,
(__m128)0LL,
v9);
}
return (ImGui **)ImDrawList::PopClipRect(v9);
}
}
return result;
}
|
ShowAltLegend:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x78
LEA RAX,[0x437030]
MOV RBX,qword ptr [RAX]
MOV R13,qword ptr [RBX + 0x1368]
CMP byte ptr [R13 + 0xcf],0x0
JNZ 0x001c2df4
MOV EBP,EDX
MOVAPS xmmword ptr [RSP + 0x20],XMM0
MOV dword ptr [RSP + 0xc],ESI
MOV R15,qword ptr [0x00436ca0]
MOV R14,qword ptr [R13 + 0x2b0]
CALL 0x001ae1cb
MOV R12,RAX
TEST RAX,RAX
JZ 0x001c2b09
LEA RDI,[R12 + 0x8f8]
LEA RSI,[R15 + 0x178]
LEA RDX,[R15 + 0x180]
MOVZX ECX,byte ptr [RSP + 0xc]
CALL 0x001ae2e9
MOVSD XMM1,qword ptr [R15 + 0x170]
ADDPS XMM1,XMM1
MOVAPS xmmword ptr [RSP + 0x30],XMM0
ADDPS XMM1,XMM0
JMP 0x001c2b1d
LAB_001c2b09:
MOVSD XMM1,qword ptr [R15 + 0x170]
ADDPS XMM1,XMM1
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP + 0x30],XMM0
LAB_001c2b1d:
MOVAPS XMM2,XMM1
SHUFPS XMM2,XMM1,0x55
MOVAPS XMM0,xmmword ptr [RSP + 0x20]
CALL 0x003263c1
MOVSD XMM1,qword ptr [R13 + 0x118]
ADDPS XMM0,XMM1
MOVAPS XMM2,XMM1
MOVLHPS XMM2,XMM0
LEA R13,[RSP + 0x10]
MOVUPS xmmword ptr [R13],XMM2
SUBPS XMM0,XMM1
LEA RDI,[RSP + 0x40]
MOVLPS qword ptr [RDI],XMM0
MOVSS XMM0,dword ptr [0x0038f004]
CALL 0x00326733
MOV RDI,R13
XOR ESI,ESI
MOV RDX,R13
XOR ECX,ECX
CALL 0x003268b6
TEST AL,AL
JZ 0x001c2df4
LEA R13,[RSP + 0x18]
MOVSD XMM0,qword ptr [R13 + -0x8]
MOVAPS xmmword ptr [RSP + 0x20],XMM0
MOVSD XMM0,qword ptr [R13]
MOVAPS xmmword ptr [RSP + 0x60],XMM0
MOV RCX,qword ptr [0x00436ca0]
MOVSS XMM0,dword ptr [RCX + 0x20c]
UCOMISS XMM0,dword ptr [0x0038f004]
JNZ 0x001c2bc1
JP 0x001c2bc1
MOV EDI,0x7
CALL 0x00315eee
MOV RCX,RAX
ADD RCX,0x8
JMP 0x001c2bcf
LAB_001c2bc1:
LEA RAX,[RCX + 0x200]
ADD RCX,0x208
LAB_001c2bcf:
MOVSD XMM0,qword ptr [RAX]
MOVHPS XMM0,qword ptr [RCX]
LEA RDI,[RSP + 0x40]
MOVUPS xmmword ptr [RDI],XMM0
CALL 0x00313cfe
MOVSS XMM2,dword ptr [RBX + 0xc34]
MOVAPS XMM0,xmmword ptr [RSP + 0x20]
MOVAPS XMM1,xmmword ptr [RSP + 0x60]
MOV EDI,EAX
MOV ESI,0x1
CALL 0x00317467
LEA RSI,[RSP + 0x10]
MOV RDI,R14
MOV RDX,R13
MOV ECX,0x1
CALL 0x0033abf8
TEST R12,R12
JZ 0x001c2dec
MOVSD XMM0,qword ptr [RSP + 0x10]
MOVSD XMM1,qword ptr [RSP + 0x18]
ADDPS XMM1,XMM0
MOVAPS XMM0,xmmword ptr [0x003943f0]
MULPS XMM1,XMM0
MOVAPS XMM3,xmmword ptr [RSP + 0x30]
MOVAPS XMM2,XMM3
MULPS XMM2,XMM0
SUBPS XMM1,XMM2
ADDPS XMM1,XMM0
CVTTPS2DQ XMM0,XMM1
CVTDQ2PS XMM0,XMM0
ADDPS XMM3,XMM0
MOVLHPS XMM0,XMM3
MOVUPS xmmword ptr [RSP + 0x50],XMM0
TEST BPL,BPL
JZ 0x001c2c78
CALL 0x0031ac26
MOVSS XMM1,dword ptr [RAX + 0xe0]
UCOMISS XMM1,dword ptr [RSP + 0x10]
JNC 0x001c2d26
LAB_001c2c78:
XOR EAX,EAX
LAB_001c2c7a:
MOV dword ptr [RSP + 0x20],EAX
MOV RCX,qword ptr [0x00436ca0]
MOVSS XMM0,dword ptr [RCX + 0x23c]
UCOMISS XMM0,dword ptr [0x0038f004]
JNZ 0x001c2cab
JP 0x001c2cab
MOV EDI,0x4
CALL 0x00315eee
MOV RCX,RAX
ADD RCX,0x8
JMP 0x001c2cb9
LAB_001c2cab:
LEA RAX,[RCX + 0x230]
ADD RCX,0x238
LAB_001c2cb9:
LEA RBX,[RSP + 0x58]
MOVSD XMM0,qword ptr [RAX]
MOVHPS XMM0,qword ptr [RCX]
LEA RDI,[RSP + 0x40]
MOVUPS xmmword ptr [RDI],XMM0
CALL 0x00313cfe
MOV dword ptr [RSP + 0x30],EAX
MOV RCX,qword ptr [0x00436ca0]
MOVSS XMM0,dword ptr [RCX + 0x24c]
UCOMISS XMM0,dword ptr [0x0038f004]
JNZ 0x001c2d16
JP 0x001c2d16
MOVSS XMM0,dword ptr [RCX + 0x22c]
UCOMISS XMM0,dword ptr [0x0038f004]
JNZ 0x001c2d5b
JP 0x001c2d5b
MOV EDI,0x5
CALL 0x00315eee
MOV RCX,RAX
ADD RCX,0x8
JMP 0x001c2d69
LAB_001c2d16:
LEA RAX,[RCX + 0x240]
ADD RCX,0x248
JMP 0x001c2d69
LAB_001c2d26:
MOVSS XMM0,dword ptr [RAX + 0xe4]
XOR EAX,EAX
UCOMISS XMM0,dword ptr [RSP + 0x14]
JC 0x001c2c7a
MOVSS XMM2,dword ptr [RSP + 0x18]
UCOMISS XMM2,XMM1
JBE 0x001c2c7a
MOVSS XMM1,dword ptr [RSP + 0x1c]
UCOMISS XMM1,XMM0
SETA AL
JMP 0x001c2c7a
LAB_001c2d5b:
LEA RAX,[RCX + 0x220]
ADD RCX,0x228
LAB_001c2d69:
MOVSD XMM0,qword ptr [RAX]
MOVHPS XMM0,qword ptr [RCX]
LEA RDI,[RSP + 0x40]
MOVUPS xmmword ptr [RDI],XMM0
CALL 0x00313cfe
MOV EBP,EAX
LEA R13,[RSP + 0x50]
XORPS XMM0,XMM0
MOV RDI,R14
MOV RSI,R13
MOV RDX,RBX
MOV ECX,dword ptr [RSP + 0x30]
XOR R8D,R8D
CALL 0x0033dbe4
MOVSS XMM1,dword ptr [0x0038f008]
XORPS XMM0,XMM0
MOV RDI,R14
MOV RSI,R13
MOV RDX,RBX
MOV ECX,EBP
XOR R8D,R8D
CALL 0x0033db44
ADD R12,0x8f8
LEA RCX,[R15 + 0x178]
ADD R15,0x180
MOV qword ptr [RSP],R14
MOVZX EDX,byte ptr [RSP + 0x20]
MOVZX R9D,byte ptr [RSP + 0xc]
MOV RDI,R12
MOV RSI,R13
MOV R8,R15
CALL 0x001ae45f
LAB_001c2dec:
MOV RDI,R14
CALL 0x0033ad78
LAB_001c2df4:
ADD RSP,0x78
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* ImPlot::ShowAltLegend(char const*, bool, ImVec2, bool) */
void ImPlot::ShowAltLegend(int8 param_1_00,char *param_1,bool param_2,char param_4)
{
ImDrawList *this;
long lVar1;
long lVar2;
char cVar3;
int4 uVar4;
uint uVar5;
long lVar6;
int8 *puVar7;
long lVar8;
int8 *puVar9;
int8 uVar10;
int4 extraout_XMM0_Dc;
int4 extraout_XMM0_Dd;
float fVar11;
float fVar12;
float local_98;
float fStack_94;
float fStack_90;
float fStack_8c;
int8 local_88;
int8 uStack_80;
int8 local_78;
int8 uStack_70;
int8 local_68;
int4 uStack_60;
int4 uStack_5c;
float local_58;
float fStack_54;
float fStack_50;
float fStack_4c;
int8 local_48;
int8 uStack_40;
lVar2 = GImGui;
lVar1 = GImPlot;
lVar8 = *(long *)(GImGui + 0x1368);
if (*(char *)(lVar8 + 0xcf) != '\0') {
return;
}
this = *(ImDrawList **)(lVar8 + 0x2b0);
local_88 = param_1_00;
lVar6 = GetPlot(param_1);
if (lVar6 == 0) {
fVar11 = (float)*(int8 *)(lVar1 + 0x170);
fVar12 = (float)((ulong)*(int8 *)(lVar1 + 0x170) >> 0x20);
uVar10 = CONCAT44(fVar12 + fVar12,fVar11 + fVar11);
local_78 = 0;
uStack_70 = 0;
}
else {
local_78 = CalcLegendSize((ImPlotItemGroup *)(lVar6 + 0x8f8),(ImVec2 *)(lVar1 + 0x178),
(ImVec2 *)(lVar1 + 0x180),param_2);
fVar11 = (float)*(int8 *)(lVar1 + 0x170);
fVar12 = (float)((ulong)*(int8 *)(lVar1 + 0x170) >> 0x20);
uStack_70 = CONCAT44(extraout_XMM0_Dd,extraout_XMM0_Dc);
uVar10 = CONCAT44(fVar12 + fVar12 + (float)((ulong)local_78 >> 0x20),
fVar11 + fVar11 + (float)local_78);
}
uVar10 = ImGui::CalcItemSize((int4)local_88,uVar10,(int)((ulong)uVar10 >> 0x20));
local_98 = *(float *)(lVar8 + 0x118);
fStack_94 = *(float *)(lVar8 + 0x11c);
fStack_90 = (float)uVar10 + local_98;
fStack_8c = (float)((ulong)uVar10 >> 0x20) + fStack_94;
local_68 = CONCAT44(fStack_8c - fStack_94,fStack_90 - local_98);
ImGui::ItemSize((ImVec2 *)&local_68,DAT_0038f004);
cVar3 = ImGui::ItemAdd((ImRect *)&local_98,0,(ImRect *)&local_98,0);
if (cVar3 == '\0') {
return;
}
local_88 = CONCAT44(fStack_94,local_98);
uStack_80 = 0;
local_48 = CONCAT44(fStack_8c,fStack_90);
uStack_40 = 0;
if ((*(float *)(GImPlot + 0x20c) != DAT_0038f004) ||
(NAN(*(float *)(GImPlot + 0x20c)) || NAN(DAT_0038f004))) {
puVar7 = (int8 *)(GImPlot + 0x200);
puVar9 = (int8 *)(GImPlot + 0x208);
}
else {
puVar7 = (int8 *)ImGui::GetStyleColorVec4(7);
puVar9 = puVar7 + 1;
}
local_68 = *puVar7;
uStack_60 = (int4)*puVar9;
uStack_5c = (int4)((ulong)*puVar9 >> 0x20);
uVar4 = ImGui::ColorConvertFloat4ToU32((ImVec4 *)&local_68);
ImGui::RenderFrame((int4)local_88,local_48,*(int4 *)(lVar2 + 0xc34),uVar4,1);
ImDrawList::PushClipRect(this,(ImVec2 *)&local_98,(ImVec2 *)&fStack_90,true);
if (lVar6 == 0) goto LAB_001c2dec;
local_58 = (float)(int)(((fStack_90 + local_98) * (float)DAT_003943f0 -
(float)local_78 * (float)DAT_003943f0) + (float)DAT_003943f0);
fStack_54 = (float)(int)(((fStack_8c + fStack_94) * DAT_003943f0._4_4_ -
local_78._4_4_ * DAT_003943f0._4_4_) + DAT_003943f0._4_4_);
fStack_50 = (float)local_78 + local_58;
fStack_4c = local_78._4_4_ + fStack_54;
if (param_4 == '\0') {
LAB_001c2c78:
uVar5 = 0;
}
else {
lVar8 = ImGui::GetIO();
if (*(float *)(lVar8 + 0xe0) < local_98) goto LAB_001c2c78;
uVar5 = 0;
if ((fStack_94 <= *(float *)(lVar8 + 0xe4)) && (*(float *)(lVar8 + 0xe0) < fStack_90)) {
uVar5 = (uint)(*(float *)(lVar8 + 0xe4) < fStack_8c);
}
}
local_88 = CONCAT44(local_88._4_4_,uVar5);
if ((*(float *)(GImPlot + 0x23c) != DAT_0038f004) ||
(NAN(*(float *)(GImPlot + 0x23c)) || NAN(DAT_0038f004))) {
puVar7 = (int8 *)(GImPlot + 0x230);
puVar9 = (int8 *)(GImPlot + 0x238);
}
else {
puVar7 = (int8 *)ImGui::GetStyleColorVec4(4);
puVar9 = puVar7 + 1;
}
local_68 = *puVar7;
uStack_60 = (int4)*puVar9;
uStack_5c = (int4)((ulong)*puVar9 >> 0x20);
uVar4 = ImGui::ColorConvertFloat4ToU32((ImVec4 *)&local_68);
local_78 = CONCAT44(local_78._4_4_,uVar4);
if ((*(float *)(GImPlot + 0x24c) != DAT_0038f004) ||
(NAN(*(float *)(GImPlot + 0x24c)) || NAN(DAT_0038f004))) {
puVar7 = (int8 *)(GImPlot + 0x240);
puVar9 = (int8 *)(GImPlot + 0x248);
}
else if ((*(float *)(GImPlot + 0x22c) != DAT_0038f004) ||
(NAN(*(float *)(GImPlot + 0x22c)) || NAN(DAT_0038f004))) {
puVar7 = (int8 *)(GImPlot + 0x220);
puVar9 = (int8 *)(GImPlot + 0x228);
}
else {
puVar7 = (int8 *)ImGui::GetStyleColorVec4(5);
puVar9 = puVar7 + 1;
}
local_68 = *puVar7;
uStack_60 = (int4)*puVar9;
uStack_5c = (int4)((ulong)*puVar9 >> 0x20);
uVar5 = ImGui::ColorConvertFloat4ToU32((ImVec4 *)&local_68);
ImDrawList::AddRectFilled
(this,(ImRect *)&local_58,(ImVec2 *)&fStack_50,(uint)(float)local_78,0.0,0);
ImDrawList::AddRect(this,(ImRect *)&local_58,(ImVec2 *)&fStack_50,uVar5,0.0,0,DAT_0038f008);
ShowLegendEntries((ImPlotItemGroup *)(lVar6 + 0x8f8),(ImRect *)&local_58,local_88._0_1_,
(ImVec2 *)(lVar1 + 0x178),(ImVec2 *)(lVar1 + 0x180),param_2,this);
LAB_001c2dec:
ImDrawList::PopClipRect(this);
return;
}
|
|
9,944 |
mysql_stmt_close_start
|
eloqsql/libmariadb/libmariadb/mariadb_async.c
|
int STDCALL
mysql_stmt_close_start(my_bool *ret, MYSQL_STMT *stmt)
{
MK_ASYNC_START_BODY(
mysql_stmt_close,
stmt->mysql,
{
WIN_SET_NONBLOCKING(stmt->mysql)
parms.stmt= stmt;
},
TRUE,
r_my_bool,
/* If stmt->mysql==NULL then we will not block so can call directly. */
if (!stmt->mysql)
{
*ret= mysql_stmt_close(stmt);
return 0;
})
}
|
O0
|
c
|
mysql_stmt_close_start:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x38(%rax)
jne 0x57e18
movq -0x18(%rbp), %rdi
callq 0x43eb0
movb %al, %cl
movq -0x10(%rbp), %rax
movb %cl, (%rax)
movl $0x0, -0x4(%rbp)
jmp 0x57f26
movq -0x18(%rbp), %rax
movq 0x38(%rax), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x28(%rbp), %rax
movb $0x1, 0x14(%rax)
movq -0x28(%rbp), %rdi
addq $0x38, %rdi
leaq 0xe2(%rip), %rsi # 0x57f30
leaq -0x30(%rbp), %rdx
callq 0x59b10
movl %eax, -0x1c(%rbp)
movq -0x28(%rbp), %rax
movb $0x0, 0x15(%rax)
movq -0x28(%rbp), %rax
movb $0x0, 0x14(%rax)
cmpl $0x0, -0x1c(%rbp)
jle 0x57e86
movq -0x28(%rbp), %rax
movb $0x1, 0x15(%rax)
movq -0x28(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x4(%rbp)
jmp 0x57f26
cmpl $0x0, -0x1c(%rbp)
jge 0x57f12
jmp 0x57e92
movq -0x18(%rbp), %rax
movq 0x38(%rax), %rax
movl $0x7d8, 0x90(%rax) # imm = 0x7D8
movq -0x18(%rbp), %rax
movq 0x38(%rax), %rdi
addq $0x297, %rdi # imm = 0x297
leaq 0x28fe6(%rip), %rax # 0x80ea0
movq (%rax), %rsi
movl $0x5, %edx
callq 0x14220
movq -0x18(%rbp), %rax
movq 0x38(%rax), %rax
movb $0x0, 0x29c(%rax)
movq -0x18(%rbp), %rax
movq 0x38(%rax), %rdi
addq $0x97, %rdi
leaq 0x28fc4(%rip), %rax # 0x80eb0
movq 0x40(%rax), %rsi
movl $0x1ff, %edx # imm = 0x1FF
callq 0x14220
movq -0x18(%rbp), %rax
movq 0x38(%rax), %rax
movb $0x0, 0x296(%rax)
movq -0x10(%rbp), %rax
movb $0x1, (%rax)
jmp 0x57f1f
movq -0x28(%rbp), %rax
movb 0x8(%rax), %cl
movq -0x10(%rbp), %rax
movb %cl, (%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nop
|
mysql_stmt_close_start:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rax, [rbp+var_18]
cmp qword ptr [rax+38h], 0
jnz short loc_57E18
mov rdi, [rbp+var_18]
call mysql_stmt_close
mov cl, al
mov rax, [rbp+var_10]
mov [rax], cl
mov [rbp+var_4], 0
jmp loc_57F26
loc_57E18:
mov rax, [rbp+var_18]
mov rax, [rax+38h]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov [rbp+var_28], rax
mov rax, [rbp+var_18]
mov [rbp+var_30], rax
mov rax, [rbp+var_28]
mov byte ptr [rax+14h], 1
mov rdi, [rbp+var_28]
add rdi, 38h ; '8'
lea rsi, mysql_stmt_close_start_internal
lea rdx, [rbp+var_30]
call my_context_spawn
mov [rbp+var_1C], eax
mov rax, [rbp+var_28]
mov byte ptr [rax+15h], 0
mov rax, [rbp+var_28]
mov byte ptr [rax+14h], 0
cmp [rbp+var_1C], 0
jle short loc_57E86
mov rax, [rbp+var_28]
mov byte ptr [rax+15h], 1
mov rax, [rbp+var_28]
mov eax, [rax]
mov [rbp+var_4], eax
jmp loc_57F26
loc_57E86:
cmp [rbp+var_1C], 0
jge loc_57F12
jmp short $+2
loc_57E92:
mov rax, [rbp+var_18]
mov rax, [rax+38h]
mov dword ptr [rax+90h], 7D8h
mov rax, [rbp+var_18]
mov rdi, [rax+38h]
add rdi, 297h
lea rax, SQLSTATE_UNKNOWN
mov rsi, [rax]
mov edx, 5
call _strncpy
mov rax, [rbp+var_18]
mov rax, [rax+38h]
mov byte ptr [rax+29Ch], 0
mov rax, [rbp+var_18]
mov rdi, [rax+38h]
add rdi, 97h
lea rax, client_errors
mov rsi, [rax+40h]
mov edx, 1FFh
call _strncpy
mov rax, [rbp+var_18]
mov rax, [rax+38h]
mov byte ptr [rax+296h], 0
mov rax, [rbp+var_10]
mov byte ptr [rax], 1
jmp short loc_57F1F
loc_57F12:
mov rax, [rbp+var_28]
mov cl, [rax+8]
mov rax, [rbp+var_10]
mov [rax], cl
loc_57F1F:
mov [rbp+var_4], 0
loc_57F26:
mov eax, [rbp+var_4]
add rsp, 30h
pop rbp
retn
|
long long mysql_stmt_close_start(char *a1, long long a2)
{
long long v3; // [rsp+0h] [rbp-30h] BYREF
_BYTE *v4; // [rsp+8h] [rbp-28h]
int v5; // [rsp+14h] [rbp-1Ch]
long long v6; // [rsp+18h] [rbp-18h]
char *v7; // [rsp+20h] [rbp-10h]
v7 = a1;
v6 = a2;
if ( *(_QWORD *)(a2 + 56) )
{
v4 = *(_BYTE **)(*(_QWORD *)(*(_QWORD *)(v6 + 56) + 1152LL) + 40LL);
v3 = v6;
v4[20] = 1;
v5 = my_context_spawn(v4 + 56, mysql_stmt_close_start_internal, &v3);
v4[21] = 0;
v4[20] = 0;
if ( v5 <= 0 )
{
if ( v5 >= 0 )
{
*v7 = v4[8];
}
else
{
*(_DWORD *)(*(_QWORD *)(v6 + 56) + 144LL) = 2008;
strncpy(*(_QWORD *)(v6 + 56) + 663LL, SQLSTATE_UNKNOWN, 5LL);
*(_BYTE *)(*(_QWORD *)(v6 + 56) + 668LL) = 0;
strncpy(*(_QWORD *)(v6 + 56) + 151LL, client_errors[8], 511LL);
*(_BYTE *)(*(_QWORD *)(v6 + 56) + 662LL) = 0;
*v7 = 1;
}
return 0;
}
else
{
v4[21] = 1;
return *(unsigned int *)v4;
}
}
else
{
*v7 = mysql_stmt_close(v6);
return 0;
}
}
|
mysql_stmt_close_start:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x18]
CMP qword ptr [RAX + 0x38],0x0
JNZ 0x00157e18
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00143eb0
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],CL
MOV dword ptr [RBP + -0x4],0x0
JMP 0x00157f26
LAB_00157e18:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x38]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x14],0x1
MOV RDI,qword ptr [RBP + -0x28]
ADD RDI,0x38
LEA RSI,[0x157f30]
LEA RDX,[RBP + -0x30]
CALL 0x00159b10
MOV dword ptr [RBP + -0x1c],EAX
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x15],0x0
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x14],0x0
CMP dword ptr [RBP + -0x1c],0x0
JLE 0x00157e86
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x15],0x1
MOV RAX,qword ptr [RBP + -0x28]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x00157f26
LAB_00157e86:
CMP dword ptr [RBP + -0x1c],0x0
JGE 0x00157f12
JMP 0x00157e92
LAB_00157e92:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x38]
MOV dword ptr [RAX + 0x90],0x7d8
MOV RAX,qword ptr [RBP + -0x18]
MOV RDI,qword ptr [RAX + 0x38]
ADD RDI,0x297
LEA RAX,[0x180ea0]
MOV RSI,qword ptr [RAX]
MOV EDX,0x5
CALL 0x00114220
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x38]
MOV byte ptr [RAX + 0x29c],0x0
MOV RAX,qword ptr [RBP + -0x18]
MOV RDI,qword ptr [RAX + 0x38]
ADD RDI,0x97
LEA RAX,[0x180eb0]
MOV RSI,qword ptr [RAX + 0x40]
MOV EDX,0x1ff
CALL 0x00114220
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0x38]
MOV byte ptr [RAX + 0x296],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],0x1
JMP 0x00157f1f
LAB_00157f12:
MOV RAX,qword ptr [RBP + -0x28]
MOV CL,byte ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],CL
LAB_00157f1f:
MOV dword ptr [RBP + -0x4],0x0
LAB_00157f26:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x30
POP RBP
RET
|
int4 mysql_stmt_close_start(int1 *param_1,long param_2)
{
int1 uVar1;
long local_38;
int4 *local_30;
int local_24;
long local_20;
int1 *local_18;
int4 local_c;
local_20 = param_2;
local_18 = param_1;
if (*(long *)(param_2 + 0x38) == 0) {
uVar1 = mysql_stmt_close(param_2);
*local_18 = uVar1;
local_c = 0;
}
else {
local_30 = *(int4 **)(*(long *)(*(long *)(param_2 + 0x38) + 0x480) + 0x28);
*(int1 *)(local_30 + 5) = 1;
local_38 = param_2;
local_24 = my_context_spawn(local_30 + 0xe,mysql_stmt_close_start_internal,&local_38);
*(int1 *)((long)local_30 + 0x15) = 0;
*(int1 *)(local_30 + 5) = 0;
if (local_24 < 1) {
if (local_24 < 0) {
*(int4 *)(*(long *)(local_20 + 0x38) + 0x90) = 0x7d8;
strncpy((char *)(*(long *)(local_20 + 0x38) + 0x297),SQLSTATE_UNKNOWN,5);
*(int1 *)(*(long *)(local_20 + 0x38) + 0x29c) = 0;
strncpy((char *)(*(long *)(local_20 + 0x38) + 0x97),PTR_s_Client_run_out_of_memory_00180ef0,
0x1ff);
*(int1 *)(*(long *)(local_20 + 0x38) + 0x296) = 0;
*local_18 = 1;
}
else {
*local_18 = *(int1 *)(local_30 + 2);
}
local_c = 0;
}
else {
*(int1 *)((long)local_30 + 0x15) = 1;
local_c = *local_30;
}
}
return local_c;
}
|
|
9,945 |
blst_p1_mult
|
corpus-core[P]colibri-stateless/build_O0/_deps/blst-src/src/e1.c
|
void blst_p1_mult(POINTonE1 *out, const POINTonE1 *a,
const byte *scalar, size_t nbits)
{
if (nbits < 176) {
if (nbits)
POINTonE1_mult_w4(out, a, scalar, nbits);
else
vec_zero(out, sizeof(*out));
} else if (nbits <= 256) {
union { vec256 l; pow256 s; } val;
size_t i, j, top, mask = (size_t)0 - 1;
/* this is not about constant-time-ness, but branch optimization */
for (top = (nbits + 7)/8, i=0, j=0; i<sizeof(val.s);) {
val.s[i++] = scalar[j] & mask;
mask = 0 - ((i - top) >> (8*sizeof(top)-1));
j += 1 & mask;
}
if (check_mod_256(val.s, BLS12_381_r)) /* z^4 is the formal limit */
POINTonE1_mult_glv(out, a, val.s);
else /* should never be the case, added for formal completeness */
POINTonE1_mult_w5(out, a, scalar, nbits);
vec_zero(val.l, sizeof(val));
} else { /* should never be the case, added for formal completeness */
POINTonE1_mult_w5(out, a, scalar, nbits);
}
}
|
O0
|
c
|
blst_p1_mult:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
cmpq $0xb0, -0x20(%rbp)
jae 0x25733
cmpq $0x0, -0x20(%rbp)
je 0x25720
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
callq 0x25830
jmp 0x2572e
movq -0x8(%rbp), %rdi
movl $0x90, %esi
callq 0x23310
jmp 0x25821
cmpq $0x100, -0x20(%rbp) # imm = 0x100
ja 0x2580a
movq $-0x1, -0x60(%rbp)
movq -0x20(%rbp), %rax
addq $0x7, %rax
shrq $0x3, %rax
movq %rax, -0x58(%rbp)
movq $0x0, -0x48(%rbp)
movq $0x0, -0x50(%rbp)
cmpq $0x20, -0x48(%rbp)
jae 0x257bc
movq -0x18(%rbp), %rax
movq -0x50(%rbp), %rcx
movzbl (%rax,%rcx), %eax
andq -0x60(%rbp), %rax
movb %al, %cl
movq -0x48(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x48(%rbp)
movb %cl, -0x40(%rbp,%rax)
movq -0x48(%rbp), %rcx
subq -0x58(%rbp), %rcx
shrq $0x3f, %rcx
xorl %eax, %eax
subq %rcx, %rax
movq %rax, -0x60(%rbp)
movq -0x60(%rbp), %rax
andq $0x1, %rax
addq -0x50(%rbp), %rax
movq %rax, -0x50(%rbp)
jmp 0x25769
leaq -0x40(%rbp), %rdi
leaq 0x2f2c9(%rip), %rsi # 0x54a90
callq 0x47c40
cmpq $0x0, %rax
je 0x257e5
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
leaq -0x40(%rbp), %rdx
callq 0x25af0
jmp 0x257fa
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
callq 0x25cd0
leaq -0x40(%rbp), %rdi
movl $0x20, %esi
callq 0x23310
jmp 0x2581f
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
callq 0x25cd0
jmp 0x25821
addq $0x60, %rsp
popq %rbp
retq
nopw (%rax,%rax)
|
blst_p1_mult:
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
cmp [rbp+var_20], 0B0h
jnb short loc_25733
cmp [rbp+var_20], 0
jz short loc_25720
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov rcx, [rbp+var_20]
call POINTonE1_mult_w4
jmp short loc_2572E
loc_25720:
mov rdi, [rbp+var_8]
mov esi, 90h
call vec_zero
loc_2572E:
jmp loc_25821
loc_25733:
cmp [rbp+var_20], 100h
ja loc_2580A
mov [rbp+var_60], 0FFFFFFFFFFFFFFFFh
mov rax, [rbp+var_20]
add rax, 7
shr rax, 3
mov [rbp+var_58], rax
mov [rbp+var_48], 0
mov [rbp+var_50], 0
loc_25769:
cmp [rbp+var_48], 20h ; ' '
jnb short loc_257BC
mov rax, [rbp+var_18]
mov rcx, [rbp+var_50]
movzx eax, byte ptr [rax+rcx]
and rax, [rbp+var_60]
mov cl, al
mov rax, [rbp+var_48]
mov rdx, rax
add rdx, 1
mov [rbp+var_48], rdx
mov [rbp+rax+var_40], cl
mov rcx, [rbp+var_48]
sub rcx, [rbp+var_58]
shr rcx, 3Fh
xor eax, eax
sub rax, rcx
mov [rbp+var_60], rax
mov rax, [rbp+var_60]
and rax, 1
add rax, [rbp+var_50]
mov [rbp+var_50], rax
jmp short loc_25769
loc_257BC:
lea rdi, [rbp+var_40]
lea rsi, BLS12_381_r
call check_mod_256
cmp rax, 0
jz short loc_257E5
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
lea rdx, [rbp+var_40]
call POINTonE1_mult_glv
jmp short loc_257FA
loc_257E5:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov rcx, [rbp+var_20]
call POINTonE1_mult_w5
loc_257FA:
lea rdi, [rbp+var_40]
mov esi, 20h ; ' '
call vec_zero
jmp short loc_2581F
loc_2580A:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov rcx, [rbp+var_20]
call POINTonE1_mult_w5
loc_2581F:
jmp short $+2
loc_25821:
add rsp, 60h
pop rbp
retn
|
long long blst_p1_mult(long long a1, long long a2, long long a3, unsigned long long a4)
{
unsigned long long v5; // rax
long long v6; // [rsp+0h] [rbp-60h]
unsigned long long v7; // [rsp+8h] [rbp-58h]
long long v8; // [rsp+10h] [rbp-50h]
unsigned long long v9; // [rsp+18h] [rbp-48h]
_BYTE v10[32]; // [rsp+20h] [rbp-40h] BYREF
unsigned long long v11; // [rsp+40h] [rbp-20h]
long long v12; // [rsp+48h] [rbp-18h]
long long v13; // [rsp+50h] [rbp-10h]
long long v14; // [rsp+58h] [rbp-8h]
v14 = a1;
v13 = a2;
v12 = a3;
v11 = a4;
if ( a4 >= 0xB0 )
{
if ( v11 > 0x100 )
{
return POINTonE1_mult_w5(v14, v13, v12, v11);
}
else
{
LOBYTE(v6) = -1;
v7 = (v11 + 7) >> 3;
v9 = 0LL;
v8 = 0LL;
while ( v9 < 0x20 )
{
v5 = v9++;
v10[v5] = v6 & *(_BYTE *)(v12 + v8);
v6 = -(long long)((v9 - v7) >> 63);
v8 += (long long)(v9 - v7) < 0;
}
if ( check_mod_256(v10, &BLS12_381_r) )
POINTonE1_mult_glv(v14, v13, v10);
else
POINTonE1_mult_w5(v14, v13, v12, v11);
return vec_zero((long long)v10, 0x20uLL);
}
}
else if ( v11 )
{
return POINTonE1_mult_w4(v14, v13, v12, v11);
}
else
{
return vec_zero(v14, 0x90uLL);
}
}
|
blst_p1_mult:
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
CMP qword ptr [RBP + -0x20],0xb0
JNC 0x00125733
CMP qword ptr [RBP + -0x20],0x0
JZ 0x00125720
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x20]
CALL 0x00125830
JMP 0x0012572e
LAB_00125720:
MOV RDI,qword ptr [RBP + -0x8]
MOV ESI,0x90
CALL 0x00123310
LAB_0012572e:
JMP 0x00125821
LAB_00125733:
CMP qword ptr [RBP + -0x20],0x100
JA 0x0012580a
MOV qword ptr [RBP + -0x60],-0x1
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x7
SHR RAX,0x3
MOV qword ptr [RBP + -0x58],RAX
MOV qword ptr [RBP + -0x48],0x0
MOV qword ptr [RBP + -0x50],0x0
LAB_00125769:
CMP qword ptr [RBP + -0x48],0x20
JNC 0x001257bc
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x50]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
AND RAX,qword ptr [RBP + -0x60]
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x48]
MOV RDX,RAX
ADD RDX,0x1
MOV qword ptr [RBP + -0x48],RDX
MOV byte ptr [RBP + RAX*0x1 + -0x40],CL
MOV RCX,qword ptr [RBP + -0x48]
SUB RCX,qword ptr [RBP + -0x58]
SHR RCX,0x3f
XOR EAX,EAX
SUB RAX,RCX
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x60]
AND RAX,0x1
ADD RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x50],RAX
JMP 0x00125769
LAB_001257bc:
LEA RDI,[RBP + -0x40]
LEA RSI,[0x154a90]
CALL 0x00147c40
CMP RAX,0x0
JZ 0x001257e5
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
LEA RDX,[RBP + -0x40]
CALL 0x00125af0
JMP 0x001257fa
LAB_001257e5:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x20]
CALL 0x00125cd0
LAB_001257fa:
LEA RDI,[RBP + -0x40]
MOV ESI,0x20
CALL 0x00123310
JMP 0x0012581f
LAB_0012580a:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x20]
CALL 0x00125cd0
LAB_0012581f:
JMP 0x00125821
LAB_00125821:
ADD RSP,0x60
POP RBP
RET
|
void blst_p1_mult(int8 param_1,int8 param_2,long param_3,ulong param_4)
{
long lVar1;
ulong local_68;
long local_58;
ulong local_50;
byte local_48 [32];
ulong local_28;
long local_20;
int8 local_18;
int8 local_10;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
if (param_4 < 0xb0) {
if (param_4 == 0) {
vec_zero(param_1,0x90);
}
else {
POINTonE1_mult_w4(param_1,param_2,param_3,param_4);
}
}
else if (param_4 < 0x101) {
local_68 = 0xffffffffffffffff;
local_50 = 0;
local_58 = 0;
while (local_50 < 0x20) {
local_48[local_50] = *(byte *)(param_3 + local_58) & (byte)local_68;
local_68 = (long)((local_50 + 1) - (param_4 + 7 >> 3)) >> 0x3f;
local_58 = (local_68 & 1) + local_58;
local_50 = local_50 + 1;
}
lVar1 = check_mod_256(local_48,BLS12_381_r);
if (lVar1 == 0) {
POINTonE1_mult_w5(local_10,local_18,local_20,local_28);
}
else {
POINTonE1_mult_glv(local_10,local_18,local_48);
}
vec_zero(local_48,0x20);
}
else {
POINTonE1_mult_w5(param_1,param_2,param_3,param_4);
}
return;
}
|
|
9,946 |
ftb_check_phrase
|
eloqsql/storage/myisam/ft_boolean_search.c
|
static int _ftb_check_phrase(FTB *ftb, const uchar *document, uint len,
FTB_EXPR *ftbe, struct st_mysql_ftparser *parser)
{
MY_FTB_PHRASE_PARAM ftb_param;
MYSQL_FTPARSER_PARAM *param;
DBUG_ENTER("_ftb_check_phrase");
DBUG_ASSERT(parser);
if (! (param= ftparser_call_initializer(ftb->info, ftb->keynr, 1)))
DBUG_RETURN(0);
ftb_param.phrase= ftbe->phrase;
ftb_param.document= ftbe->document;
ftb_param.cs= ftb->charset;
ftb_param.phrase_length= list_length(ftbe->phrase);
ftb_param.document_length= 1;
ftb_param.match= 0;
param->mysql_parse= ftb_check_phrase_internal;
param->mysql_add_word= ftb_phrase_add_word;
param->mysql_ftparam= (void *)&ftb_param;
param->cs= ftb->charset;
param->doc= (char *) document;
param->length= len;
param->flags= 0;
param->mode= MYSQL_FTPARSER_WITH_STOPWORDS;
if (unlikely(parser->parse(param)))
return -1;
DBUG_RETURN(ftb_param.match ? 1 : 0);
}
|
O0
|
c
|
ftb_check_phrase:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
jmp 0x9f80d
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x10(%rbp), %rax
movl 0x340(%rax), %esi
movl $0x1, %edx
callq 0xa21c0
movq %rax, -0x60(%rbp)
cmpq $0x0, %rax
jne 0x9f841
jmp 0x9f835
movl $0x0, -0x4(%rbp)
jmp 0x9f927
movq -0x28(%rbp), %rax
movq 0x30(%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x28(%rbp), %rax
movq 0x38(%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x28(%rbp), %rax
movq 0x30(%rax), %rdi
callq 0xe1400
movl %eax, -0x40(%rbp)
movl $0x1, -0x3c(%rbp)
movl $0x0, -0x38(%rbp)
movq -0x60(%rbp), %rax
leaq 0xa2(%rip), %rcx # 0x9f930
movq %rcx, (%rax)
movq -0x60(%rbp), %rax
leaq 0x114(%rip), %rcx # 0x9f9b0
movq %rcx, 0x8(%rax)
movq -0x60(%rbp), %rax
leaq -0x58(%rbp), %rcx
movq %rcx, 0x18(%rax)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x60(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x18(%rbp), %rcx
movq -0x60(%rbp), %rax
movq %rcx, 0x28(%rax)
movl -0x1c(%rbp), %ecx
movq -0x60(%rbp), %rax
movl %ecx, 0x30(%rax)
movq -0x60(%rbp), %rax
movl $0x0, 0x34(%rax)
movq -0x60(%rbp), %rax
movl $0x1, 0x38(%rax)
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x60(%rbp), %rdi
callq *%rax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x9f912
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x9f927
jmp 0x9f914
movl -0x38(%rbp), %edx
xorl %eax, %eax
movl $0x1, %ecx
cmpl $0x0, %edx
cmovnel %ecx, %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x60, %rsp
popq %rbp
retq
|
_ftb_check_phrase:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_1C], edx
mov [rbp+var_28], rcx
mov [rbp+var_30], r8
jmp short $+2
loc_9F80D:
mov rax, [rbp+var_10]
mov rdi, [rax+8]
mov rax, [rbp+var_10]
mov esi, [rax+340h]
mov edx, 1
call ftparser_call_initializer
mov [rbp+var_60], rax
cmp rax, 0
jnz short loc_9F841
jmp short $+2
loc_9F835:
mov [rbp+var_4], 0
jmp loc_9F927
loc_9F841:
mov rax, [rbp+var_28]
mov rax, [rax+30h]
mov [rbp+var_58], rax
mov rax, [rbp+var_28]
mov rax, [rax+38h]
mov [rbp+var_50], rax
mov rax, [rbp+var_10]
mov rax, [rax+10h]
mov [rbp+var_48], rax
mov rax, [rbp+var_28]
mov rdi, [rax+30h]
call list_length
mov [rbp+var_40], eax
mov [rbp+var_3C], 1
mov [rbp+var_38], 0
mov rax, [rbp+var_60]
lea rcx, ftb_check_phrase_internal
mov [rax], rcx
mov rax, [rbp+var_60]
lea rcx, ftb_phrase_add_word
mov [rax+8], rcx
mov rax, [rbp+var_60]
lea rcx, [rbp+var_58]
mov [rax+18h], rcx
mov rax, [rbp+var_10]
mov rcx, [rax+10h]
mov rax, [rbp+var_60]
mov [rax+20h], rcx
mov rcx, [rbp+var_18]
mov rax, [rbp+var_60]
mov [rax+28h], rcx
mov ecx, [rbp+var_1C]
mov rax, [rbp+var_60]
mov [rax+30h], ecx
mov rax, [rbp+var_60]
mov dword ptr [rax+34h], 0
mov rax, [rbp+var_60]
mov dword ptr [rax+38h], 1
mov rax, [rbp+var_30]
mov rax, [rax+8]
mov rdi, [rbp+var_60]
call rax
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_9F912
mov [rbp+var_4], 0FFFFFFFFh
jmp short loc_9F927
loc_9F912:
jmp short $+2
loc_9F914:
mov edx, [rbp+var_38]
xor eax, eax
mov ecx, 1
cmp edx, 0
cmovnz eax, ecx
mov [rbp+var_4], eax
loc_9F927:
mov eax, [rbp+var_4]
add rsp, 60h
pop rbp
retn
|
long long ftb_check_phrase(long long a1, long long a2, int a3, long long a4, long long a5)
{
long long v6; // [rsp+0h] [rbp-60h]
_QWORD v7[3]; // [rsp+8h] [rbp-58h] BYREF
int v8; // [rsp+20h] [rbp-40h]
int v9; // [rsp+24h] [rbp-3Ch]
int v10; // [rsp+28h] [rbp-38h]
long long v11; // [rsp+30h] [rbp-30h]
long long v12; // [rsp+38h] [rbp-28h]
int v13; // [rsp+44h] [rbp-1Ch]
long long v14; // [rsp+48h] [rbp-18h]
long long v15; // [rsp+50h] [rbp-10h]
v15 = a1;
v14 = a2;
v13 = a3;
v12 = a4;
v11 = a5;
v6 = ftparser_call_initializer(*(_QWORD *)(v15 + 8), *(unsigned int *)(v15 + 832), 1LL);
if ( v6 )
{
v7[0] = *(_QWORD *)(v12 + 48);
v7[1] = *(_QWORD *)(v12 + 56);
v7[2] = *(_QWORD *)(v15 + 16);
v8 = list_length(*(_QWORD *)(v12 + 48));
v9 = 1;
v10 = 0;
*(_QWORD *)v6 = ftb_check_phrase_internal;
*(_QWORD *)(v6 + 8) = ftb_phrase_add_word;
*(_QWORD *)(v6 + 24) = v7;
*(_QWORD *)(v6 + 32) = *(_QWORD *)(v15 + 16);
*(_QWORD *)(v6 + 40) = v14;
*(_DWORD *)(v6 + 48) = v13;
*(_DWORD *)(v6 + 52) = 0;
*(_DWORD *)(v6 + 56) = 1;
if ( (*(unsigned int ( **)(long long))(v11 + 8))(v6) )
return (unsigned int)-1;
else
return v10 != 0;
}
else
{
return 0;
}
}
|
_ftb_check_phrase:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV dword ptr [RBP + -0x1c],EDX
MOV qword ptr [RBP + -0x28],RCX
MOV qword ptr [RBP + -0x30],R8
JMP 0x0019f80d
LAB_0019f80d:
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RAX + 0x340]
MOV EDX,0x1
CALL 0x001a21c0
MOV qword ptr [RBP + -0x60],RAX
CMP RAX,0x0
JNZ 0x0019f841
JMP 0x0019f835
LAB_0019f835:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0019f927
LAB_0019f841:
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x30]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x38]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RDI,qword ptr [RAX + 0x30]
CALL 0x001e1400
MOV dword ptr [RBP + -0x40],EAX
MOV dword ptr [RBP + -0x3c],0x1
MOV dword ptr [RBP + -0x38],0x0
MOV RAX,qword ptr [RBP + -0x60]
LEA RCX,[0x19f930]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x60]
LEA RCX,[0x19f9b0]
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RBP + -0x60]
LEA RCX,[RBP + -0x58]
MOV qword ptr [RAX + 0x18],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x60]
MOV qword ptr [RAX + 0x20],RCX
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x60]
MOV qword ptr [RAX + 0x28],RCX
MOV ECX,dword ptr [RBP + -0x1c]
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX + 0x30],ECX
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX + 0x34],0x0
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX + 0x38],0x1
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX + 0x8]
MOV RDI,qword ptr [RBP + -0x60]
CALL RAX
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x0019f912
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x0019f927
LAB_0019f912:
JMP 0x0019f914
LAB_0019f914:
MOV EDX,dword ptr [RBP + -0x38]
XOR EAX,EAX
MOV ECX,0x1
CMP EDX,0x0
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x4],EAX
LAB_0019f927:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x60
POP RBP
RET
|
uint _ftb_check_phrase(long param_1,int8 param_2,int4 param_3,long param_4,long param_5)
{
int iVar1;
int8 *puVar2;
int8 local_60;
int8 local_58;
int8 local_50;
int4 local_48;
int4 local_44;
int local_40;
long local_38;
long local_30;
int4 local_24;
int8 local_20;
long local_18;
uint local_c;
local_38 = param_5;
local_30 = param_4;
local_24 = param_3;
local_20 = param_2;
local_18 = param_1;
puVar2 = (int8 *)
ftparser_call_initializer
(*(int8 *)(param_1 + 8),*(int4 *)(param_1 + 0x340),1);
if (puVar2 == (int8 *)0x0) {
local_c = 0;
}
else {
local_60 = *(int8 *)(local_30 + 0x30);
local_58 = *(int8 *)(local_30 + 0x38);
local_50 = *(int8 *)(local_18 + 0x10);
local_48 = list_length(*(int8 *)(local_30 + 0x30));
local_44 = 1;
local_40 = 0;
*puVar2 = ftb_check_phrase_internal;
puVar2[1] = ftb_phrase_add_word;
puVar2[3] = &local_60;
puVar2[4] = *(int8 *)(local_18 + 0x10);
puVar2[5] = local_20;
*(int4 *)(puVar2 + 6) = local_24;
*(int4 *)((long)puVar2 + 0x34) = 0;
*(int4 *)(puVar2 + 7) = 1;
iVar1 = (**(code **)(local_38 + 8))(puVar2);
if (iVar1 == 0) {
local_c = (uint)(local_40 != 0);
}
else {
local_c = 0xffffffff;
}
}
return local_c;
}
|
|
9,947 |
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 0x1c7566(%rip), %rax # 0x289300
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 0x27390
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
|
inline_mysql_mutex_init_9:
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_9(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,[0x389300]
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 0x00127390
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;
}
|
|
9,948 |
js_TA_cmp_float16
|
bluesky950520[P]quickjs/quickjs.c
|
static int js_TA_cmp_float16(const void *a, const void *b, void *opaque) {
return js_cmp_doubles(fromfp16(*(const uint16_t *)a),
fromfp16(*(const uint16_t *)b));
}
|
O1
|
c
|
js_TA_cmp_float16:
pushq %rbp
pushq %rbx
subq $0x28, %rsp
movq %rsi, %rbx
movzwl (%rdi), %ebp
movl $0x7c00, %edx # imm = 0x7C00
movl %ebp, %eax
andl %edx, %eax
movl %ebp, %ecx
andl $0x3ff, %ecx # imm = 0x3FF
cmpl %edx, %eax
jne 0x821c4
xorl %eax, %eax
testl %ecx, %ecx
sete %al
leaq 0x1ae83(%rip), %rcx # 0x9d040
movsd (%rcx,%rax,8), %xmm2
jmp 0x821f5
cvtsi2sd %ecx, %xmm0
mulsd 0x1afa0(%rip), %xmm0 # 0x9d170
movl %eax, %edi
shrl $0xa, %edi
addl $-0xf, %edi
testl %eax, %eax
je 0x821e4
addsd 0x1af74(%rip), %xmm0 # 0x9d158
movl $0xfffffff2, %eax # imm = 0xFFFFFFF2
cmovel %eax, %edi
callq 0xe660
movapd %xmm0, %xmm2
testw %bp, %bp
js 0x82200
movapd %xmm2, %xmm3
jmp 0x8220c
movapd 0x1ae48(%rip), %xmm3 # 0x9d050
xorpd %xmm2, %xmm3
movzwl (%rbx), %ebx
movl $0x7c00, %edx # imm = 0x7C00
movl %ebx, %eax
andl %edx, %eax
movl %ebx, %ecx
andl $0x3ff, %ecx # imm = 0x3FF
cmpl %edx, %eax
jne 0x82239
xorl %eax, %eax
testl %ecx, %ecx
sete %al
leaq 0x1ae0e(%rip), %rcx # 0x9d040
movsd (%rcx,%rax,8), %xmm0
jmp 0x8227f
xorps %xmm0, %xmm0
cvtsi2sd %ecx, %xmm0
mulsd 0x1af28(%rip), %xmm0 # 0x9d170
movl %eax, %edi
shrl $0xa, %edi
addl $-0xf, %edi
testl %eax, %eax
movapd %xmm2, 0x10(%rsp)
movapd %xmm3, (%rsp)
je 0x82267
addsd 0x1aef1(%rip), %xmm0 # 0x9d158
movl $0xfffffff2, %eax # imm = 0xFFFFFFF2
cmovel %eax, %edi
callq 0xe660
movapd 0x10(%rsp), %xmm2
movapd (%rsp), %xmm3
testw %bx, %bx
jns 0x8228c
xorpd 0x1adc4(%rip), %xmm0 # 0x9d050
ucomisd %xmm3, %xmm3
jp 0x822e4
ucomisd %xmm0, %xmm0
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
jp 0x822dd
ucomisd %xmm3, %xmm0
ja 0x822dd
movl $0x1, %eax
ucomisd %xmm0, %xmm3
ja 0x822dd
xorl %eax, %eax
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm2
jne 0x822dd
jp 0x822dd
movq %xmm3, %rax
movq %xmm0, %rcx
testq %rax, %rax
js 0x822d3
shrq $0x3f, %rcx
movl %ecx, %eax
jmp 0x822dd
xorl %eax, %eax
testq %rcx, %rcx
setns %al
negl %eax
addq $0x28, %rsp
popq %rbx
popq %rbp
retq
xorl %eax, %eax
ucomisd %xmm0, %xmm0
setnp %al
jmp 0x822dd
|
js_TA_cmp_float16:
push rbp
push rbx
sub rsp, 28h
mov rbx, rsi
movzx ebp, word ptr [rdi]
mov edx, 7C00h
mov eax, ebp
and eax, edx
mov ecx, ebp
and ecx, 3FFh
cmp eax, edx
jnz short loc_821C4
xor eax, eax
test ecx, ecx
setz al
lea rcx, dbl_9D040
movsd xmm2, qword ptr [rcx+rax*8]
jmp short loc_821F5
loc_821C4:
cvtsi2sd xmm0, ecx
mulsd xmm0, cs:qword_9D170
mov edi, eax
shr edi, 0Ah
add edi, 0FFFFFFF1h
test eax, eax
jz short loc_821E4
addsd xmm0, cs:qword_9D158
loc_821E4:
mov eax, 0FFFFFFF2h
cmovz edi, eax
call _scalbn
movapd xmm2, xmm0
loc_821F5:
test bp, bp
js short loc_82200
movapd xmm3, xmm2
jmp short loc_8220C
loc_82200:
movapd xmm3, cs:xmmword_9D050
xorpd xmm3, xmm2
loc_8220C:
movzx ebx, word ptr [rbx]
mov edx, 7C00h
mov eax, ebx
and eax, edx
mov ecx, ebx
and ecx, 3FFh
cmp eax, edx
jnz short loc_82239
xor eax, eax
test ecx, ecx
setz al
lea rcx, dbl_9D040
movsd xmm0, qword ptr [rcx+rax*8]
jmp short loc_8227F
loc_82239:
xorps xmm0, xmm0
cvtsi2sd xmm0, ecx
mulsd xmm0, cs:qword_9D170
mov edi, eax
shr edi, 0Ah
add edi, 0FFFFFFF1h
test eax, eax
movapd [rsp+38h+var_28], xmm2
movapd [rsp+38h+var_38], xmm3
jz short loc_82267
addsd xmm0, cs:qword_9D158
loc_82267:
mov eax, 0FFFFFFF2h
cmovz edi, eax
call _scalbn
movapd xmm2, [rsp+38h+var_28]
movapd xmm3, [rsp+38h+var_38]
loc_8227F:
test bx, bx
jns short loc_8228C
xorpd xmm0, cs:xmmword_9D050
loc_8228C:
ucomisd xmm3, xmm3
jp short loc_822E4
ucomisd xmm0, xmm0
mov eax, 0FFFFFFFFh
jp short loc_822DD
ucomisd xmm0, xmm3
ja short loc_822DD
mov eax, 1
ucomisd xmm3, xmm0
ja short loc_822DD
xor eax, eax
xorpd xmm1, xmm1
ucomisd xmm2, xmm1
jnz short loc_822DD
jp short loc_822DD
movq rax, xmm3
movq rcx, xmm0
test rax, rax
js short loc_822D3
shr rcx, 3Fh
mov eax, ecx
jmp short loc_822DD
loc_822D3:
xor eax, eax
test rcx, rcx
setns al
neg eax
loc_822DD:
add rsp, 28h
pop rbx
pop rbp
retn
loc_822E4:
xor eax, eax
ucomisd xmm0, xmm0
setnp al
jmp short loc_822DD
|
long long js_TA_cmp_float16(__int16 *a1, __int16 *a2)
{
__int16 v2; // bp
unsigned int v3; // eax
int v4; // ecx
double v5; // xmm2_8
double v6; // xmm0_8
long long v7; // rdi
double v8; // xmm3_8
__int16 v9; // bx
unsigned int v10; // eax
int v11; // ecx
double v12; // xmm0_8
double v13; // xmm0_8
long long v14; // rdi
long long result; // rax
v2 = *a1;
v3 = *a1 & 0x7C00;
v4 = *a1 & 0x3FF;
if ( v3 == 31744 )
{
v5 = dbl_9D040[v4 == 0];
}
else
{
v6 = (double)v4 * 0.0009765625;
v7 = (v3 >> 10) - 15;
if ( v3 )
v6 = v6 + 1.0;
else
v7 = 4294967282LL;
v5 = scalbn(v7, v6);
}
if ( v2 < 0 )
v8 = -v5;
else
v8 = v5;
v9 = *a2;
v10 = *a2 & 0x7C00;
v11 = *a2 & 0x3FF;
if ( v10 == 31744 )
{
v12 = dbl_9D040[v11 == 0];
}
else
{
v13 = (double)v11 * 0.0009765625;
v14 = (v10 >> 10) - 15;
if ( (*a2 & 0x7C00) != 0 )
v13 = v13 + 1.0;
else
v14 = 4294967282LL;
v12 = scalbn(v14, v13);
}
if ( v9 < 0 )
v12 = -v12;
result = 0xFFFFFFFFLL;
if ( v12 <= v8 )
{
result = 1LL;
if ( v8 <= v12 )
{
result = 0LL;
if ( v5 == 0.0 )
{
if ( v8 < 0.0 )
return (unsigned int)-(v12 >= 0.0);
else
return *(_QWORD *)&v12 >> 63;
}
}
}
return result;
}
|
js_TA_cmp_float16:
PUSH RBP
PUSH RBX
SUB RSP,0x28
MOV RBX,RSI
MOVZX EBP,word ptr [RDI]
MOV EDX,0x7c00
MOV EAX,EBP
AND EAX,EDX
MOV ECX,EBP
AND ECX,0x3ff
CMP EAX,EDX
JNZ 0x001821c4
XOR EAX,EAX
TEST ECX,ECX
SETZ AL
LEA RCX,[0x19d040]
MOVSD XMM2,qword ptr [RCX + RAX*0x8]
JMP 0x001821f5
LAB_001821c4:
CVTSI2SD XMM0,ECX
MULSD XMM0,qword ptr [0x0019d170]
MOV EDI,EAX
SHR EDI,0xa
ADD EDI,-0xf
TEST EAX,EAX
JZ 0x001821e4
ADDSD XMM0,qword ptr [0x0019d158]
LAB_001821e4:
MOV EAX,0xfffffff2
CMOVZ EDI,EAX
CALL 0x0010e660
MOVAPD XMM2,XMM0
LAB_001821f5:
TEST BP,BP
JS 0x00182200
MOVAPD XMM3,XMM2
JMP 0x0018220c
LAB_00182200:
MOVAPD XMM3,xmmword ptr [0x0019d050]
XORPD XMM3,XMM2
LAB_0018220c:
MOVZX EBX,word ptr [RBX]
MOV EDX,0x7c00
MOV EAX,EBX
AND EAX,EDX
MOV ECX,EBX
AND ECX,0x3ff
CMP EAX,EDX
JNZ 0x00182239
XOR EAX,EAX
TEST ECX,ECX
SETZ AL
LEA RCX,[0x19d040]
MOVSD XMM0,qword ptr [RCX + RAX*0x8]
JMP 0x0018227f
LAB_00182239:
XORPS XMM0,XMM0
CVTSI2SD XMM0,ECX
MULSD XMM0,qword ptr [0x0019d170]
MOV EDI,EAX
SHR EDI,0xa
ADD EDI,-0xf
TEST EAX,EAX
MOVAPD xmmword ptr [RSP + 0x10],XMM2
MOVAPD xmmword ptr [RSP],XMM3
JZ 0x00182267
ADDSD XMM0,qword ptr [0x0019d158]
LAB_00182267:
MOV EAX,0xfffffff2
CMOVZ EDI,EAX
CALL 0x0010e660
MOVAPD XMM2,xmmword ptr [RSP + 0x10]
MOVAPD XMM3,xmmword ptr [RSP]
LAB_0018227f:
TEST BX,BX
JNS 0x0018228c
XORPD XMM0,xmmword ptr [0x0019d050]
LAB_0018228c:
UCOMISD XMM3,XMM3
JP 0x001822e4
UCOMISD XMM0,XMM0
MOV EAX,0xffffffff
JP 0x001822dd
UCOMISD XMM0,XMM3
JA 0x001822dd
MOV EAX,0x1
UCOMISD XMM3,XMM0
JA 0x001822dd
XOR EAX,EAX
XORPD XMM1,XMM1
UCOMISD XMM2,XMM1
JNZ 0x001822dd
JP 0x001822dd
MOVQ RAX,XMM3
MOVQ RCX,XMM0
TEST RAX,RAX
JS 0x001822d3
SHR RCX,0x3f
MOV EAX,ECX
JMP 0x001822dd
LAB_001822d3:
XOR EAX,EAX
TEST RCX,RCX
SETNS AL
NEG EAX
LAB_001822dd:
ADD RSP,0x28
POP RBX
POP RBP
RET
LAB_001822e4:
XOR EAX,EAX
UCOMISD XMM0,XMM0
SETNP AL
JMP 0x001822dd
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
uint js_TA_cmp_float16(ushort *param_1,ushort *param_2)
{
ushort uVar1;
double dVar2;
ulong uVar3;
uint uVar4;
int iVar5;
int4 uVar6;
uint uVar7;
double dVar8;
double dVar9;
uVar1 = *param_1;
if ((uVar1 & 0x7c00) == 0x7c00) {
dVar8 = *(double *)(&DAT_0019d040 + (ulong)((uVar1 & 0x3ff) == 0) * 8);
}
else {
dVar8 = (double)(uVar1 & 0x3ff) * _DAT_0019d170;
iVar5 = ((uVar1 & 0x7c00) >> 10) - 0xf;
if ((uVar1 & 0x7c00) == 0) {
iVar5 = -0xe;
}
else {
dVar8 = dVar8 + DAT_0019d158;
}
dVar8 = scalbn(dVar8,iVar5);
}
dVar9 = dVar8;
if ((short)uVar1 < 0) {
dVar9 = (double)(_DAT_0019d050 ^ (ulong)dVar8);
}
uVar1 = *param_2;
if ((uVar1 & 0x7c00) == 0x7c00) {
uVar6 = (int4)*(int8 *)(&DAT_0019d040 + (ulong)((uVar1 & 0x3ff) == 0) * 8);
uVar7 = (uint)((ulong)*(int8 *)(&DAT_0019d040 + (ulong)((uVar1 & 0x3ff) == 0) * 8) >> 0x20
);
}
else {
dVar2 = (double)(uVar1 & 0x3ff) * _DAT_0019d170;
iVar5 = ((uVar1 & 0x7c00) >> 10) - 0xf;
if ((uVar1 & 0x7c00) == 0) {
iVar5 = -0xe;
}
else {
dVar2 = dVar2 + DAT_0019d158;
}
dVar2 = scalbn(dVar2,iVar5);
uVar6 = SUB84(dVar2,0);
uVar7 = (uint)((ulong)dVar2 >> 0x20);
}
if ((short)uVar1 < 0) {
uVar3 = CONCAT44(uVar7,uVar6) ^ _DAT_0019d050;
uVar6 = (int4)uVar3;
uVar7 = (uint)(uVar3 >> 0x20);
}
if (NAN(dVar9)) {
uVar4 = (uint)(!NAN((double)CONCAT44(uVar7,uVar6)) && !NAN((double)CONCAT44(uVar7,uVar6)));
}
else {
uVar4 = 0xffffffff;
if (((double)CONCAT44(uVar7,uVar6) < dVar9 || (double)CONCAT44(uVar7,uVar6) == dVar9) &&
(uVar4 = 1, dVar9 < (double)CONCAT44(uVar7,uVar6) || dVar9 == (double)CONCAT44(uVar7,uVar6)))
{
uVar4 = 0;
if ((dVar8 == 0.0) && (!NAN(dVar8))) {
if ((long)dVar9 < 0) {
uVar4 = -(uint)(-1 < (int)uVar7);
}
else {
uVar4 = uVar7 >> 0x1f;
}
}
}
}
return uVar4;
}
|
|
9,949 |
my_fill_mb2
|
eloqsql/strings/ctype-ucs2.c
|
static void
my_fill_mb2(CHARSET_INFO *cs, char *s, size_t slen, int fill)
{
char buf[10], *last;
size_t buflen, remainder;
DBUG_ASSERT((slen % 2) == 0);
buflen= my_ci_wc_mb(cs, (my_wc_t) fill, (uchar*) buf,
(uchar*) buf + sizeof(buf));
DBUG_ASSERT(buflen > 0);
/*
"last" in the last position where a sequence of "buflen" bytes can start.
*/
for (last= s + slen - buflen; s <= last; s+= buflen)
{
/* Enough space for the character */
memcpy(s, buf, buflen);
}
/*
If there are some more space which is not enough
for the whole multibyte character, then add trailing zeros.
*/
if ((remainder= last + buflen - s) > 0)
bzero(s, (size_t) remainder);
}
|
O0
|
c
|
my_fill_mb2:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x20(%rbp)
movq %rsi, -0x28(%rbp)
movq %rdx, -0x30(%rbp)
movl %ecx, -0x34(%rbp)
jmp 0xacbb6
movq -0x20(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x30(%rax), %rax
movq -0x20(%rbp), %rdi
movslq -0x34(%rbp), %rsi
leaq -0x12(%rbp), %rdx
leaq -0x12(%rbp), %rcx
addq $0xa, %rcx
callq *%rax
cltq
movq %rax, -0x48(%rbp)
jmp 0xacbe3
movq -0x28(%rbp), %rax
addq -0x30(%rbp), %rax
xorl %ecx, %ecx
subq -0x48(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x40(%rbp), %rax
ja 0xacc21
movq -0x28(%rbp), %rdi
leaq -0x12(%rbp), %rsi
movq -0x48(%rbp), %rdx
callq 0x370c0
movq -0x48(%rbp), %rax
addq -0x28(%rbp), %rax
movq %rax, -0x28(%rbp)
jmp 0xacbf8
movq -0x40(%rbp), %rax
addq -0x48(%rbp), %rax
movq -0x28(%rbp), %rcx
subq %rcx, %rax
movq %rax, -0x50(%rbp)
cmpq $0x0, %rax
jbe 0xacc49
movq -0x28(%rbp), %rdi
movq -0x50(%rbp), %rdx
xorl %esi, %esi
callq 0x37300
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0xacc61
addq $0x50, %rsp
popq %rbp
retq
callq 0x372c0
nopw %cs:(%rax,%rax)
|
my_fill_mb2:
push rbp
mov rbp, rsp
sub rsp, 50h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_20], rdi
mov [rbp+var_28], rsi
mov [rbp+var_30], rdx
mov [rbp+var_34], ecx
jmp short $+2
loc_ACBB6:
mov rax, [rbp+var_20]
mov rax, [rax+0B8h]
mov rax, [rax+30h]
mov rdi, [rbp+var_20]
movsxd rsi, [rbp+var_34]
lea rdx, [rbp+var_12]
lea rcx, [rbp+var_12]
add rcx, 0Ah
call rax
cdqe
mov [rbp+var_48], rax
jmp short $+2
loc_ACBE3:
mov rax, [rbp+var_28]
add rax, [rbp+var_30]
xor ecx, ecx
sub rcx, [rbp+var_48]
add rax, rcx
mov [rbp+var_40], rax
loc_ACBF8:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_40]
ja short loc_ACC21
mov rdi, [rbp+var_28]
lea rsi, [rbp+var_12]
mov rdx, [rbp+var_48]
call _memcpy
mov rax, [rbp+var_48]
add rax, [rbp+var_28]
mov [rbp+var_28], rax
jmp short loc_ACBF8
loc_ACC21:
mov rax, [rbp+var_40]
add rax, [rbp+var_48]
mov rcx, [rbp+var_28]
sub rax, rcx
mov [rbp+var_50], rax
cmp rax, 0
jbe short loc_ACC49
mov rdi, [rbp+var_28]
mov rdx, [rbp+var_50]
xor esi, esi
call _memset
loc_ACC49:
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_ACC61
add rsp, 50h
pop rbp
retn
loc_ACC61:
call ___stack_chk_fail
|
unsigned long long my_fill_mb2(long long a1, unsigned long long a2, long long a3, int a4)
{
long long i; // [rsp+8h] [rbp-48h]
unsigned long long v7; // [rsp+28h] [rbp-28h]
_BYTE v8[10]; // [rsp+3Eh] [rbp-12h] BYREF
unsigned long long v9; // [rsp+48h] [rbp-8h] BYREF
v9 = __readfsqword(0x28u);
v7 = a2;
for ( i = (*(int ( **)(long long, _QWORD, _BYTE *, unsigned long long *))(*(_QWORD *)(a1 + 184) + 48LL))(
a1,
a4,
v8,
&v9); v7 <= a3 + a2 - i; v7 += i )
memcpy(v7, v8, i);
if ( a3 + a2 != v7 )
memset(v7, 0LL, a3 + a2 - v7);
return __readfsqword(0x28u);
}
|
my_fill_mb2:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x20],RDI
MOV qword ptr [RBP + -0x28],RSI
MOV qword ptr [RBP + -0x30],RDX
MOV dword ptr [RBP + -0x34],ECX
JMP 0x001acbb6
LAB_001acbb6:
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0x30]
MOV RDI,qword ptr [RBP + -0x20]
MOVSXD RSI,dword ptr [RBP + -0x34]
LEA RDX,[RBP + -0x12]
LEA RCX,[RBP + -0x12]
ADD RCX,0xa
CALL RAX
CDQE
MOV qword ptr [RBP + -0x48],RAX
JMP 0x001acbe3
LAB_001acbe3:
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,qword ptr [RBP + -0x30]
XOR ECX,ECX
SUB RCX,qword ptr [RBP + -0x48]
ADD RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
LAB_001acbf8:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x40]
JA 0x001acc21
MOV RDI,qword ptr [RBP + -0x28]
LEA RSI,[RBP + -0x12]
MOV RDX,qword ptr [RBP + -0x48]
CALL 0x001370c0
MOV RAX,qword ptr [RBP + -0x48]
ADD RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x28],RAX
JMP 0x001acbf8
LAB_001acc21:
MOV RAX,qword ptr [RBP + -0x40]
ADD RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x28]
SUB RAX,RCX
MOV qword ptr [RBP + -0x50],RAX
CMP RAX,0x0
JBE 0x001acc49
MOV RDI,qword ptr [RBP + -0x28]
MOV RDX,qword ptr [RBP + -0x50]
XOR ESI,ESI
CALL 0x00137300
LAB_001acc49:
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x001acc61
ADD RSP,0x50
POP RBP
RET
LAB_001acc61:
CALL 0x001372c0
|
void my_fill_mb2(long param_1,void *param_2,long param_3,int param_4)
{
int iVar1;
size_t sVar2;
void *pvVar3;
long in_FS_OFFSET;
void *local_30;
int1 local_1a [10];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
iVar1 = (**(code **)(*(long *)(param_1 + 0xb8) + 0x30))(param_1,(long)param_4,local_1a);
sVar2 = (size_t)iVar1;
pvVar3 = (void *)((long)param_2 + (param_3 - sVar2));
for (local_30 = param_2; local_30 <= pvVar3; local_30 = (void *)(sVar2 + (long)local_30)) {
memcpy(local_30,local_1a,sVar2);
}
sVar2 = (long)pvVar3 + (sVar2 - (long)local_30);
if (sVar2 != 0) {
memset(local_30,0,sVar2);
}
if (*(long *)(in_FS_OFFSET + 0x28) == local_10) {
return;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
|
|
9,950 |
mi_delete_static_record
|
eloqsql/storage/myisam/mi_statrec.c
|
int _mi_delete_static_record(MI_INFO *info)
{
uchar temp[9]; /* 1+sizeof(uint32) */
info->state->del++;
info->state->empty+=info->s->base.pack_reclength;
temp[0]= '\0'; /* Mark that record is deleted */
_mi_dpointer(info,temp+1,info->s->state.dellink);
info->s->state.dellink = info->lastpos;
info->rec_cache.seek_not_done=1;
return (info->s->file_write(info,(uchar*) temp, 1+info->s->rec_reflength,
info->lastpos, MYF(MY_NABP)) != 0);
}
|
O3
|
c
|
mi_delete_static_record:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movq %fs:0x28, %rax
movq %rax, -0x10(%rbp)
movq 0x8(%rdi), %rax
incq 0x8(%rax)
movq (%rdi), %rax
movq 0x8(%rdi), %rcx
movq 0x148(%rax), %rax
addq %rax, 0x10(%rcx)
leaq -0x18(%rbp), %rsi
movb $0x0, -0x1(%rsi)
movq (%rdi), %rax
movq 0x58(%rax), %rdx
callq 0x8b6c7
movq (%rbx), %rax
movq 0x170(%rbx), %rcx
movq %rcx, 0x58(%rax)
movl $0x1, 0x300(%rbx)
movq (%rbx), %rax
movl 0x338(%rax), %edx
incl %edx
leaq -0x19(%rbp), %rsi
movl $0x4, %r8d
movq %rbx, %rdi
callq *0x2e8(%rax)
movq %rax, %rcx
xorl %eax, %eax
testq %rcx, %rcx
setne %cl
movq %fs:0x28, %rdx
cmpq -0x10(%rbp), %rdx
jne 0x8d3a8
movb %cl, %al
addq $0x18, %rsp
popq %rbx
popq %rbp
retq
callq 0x29220
|
_mi_delete_static_record:
push rbp
mov rbp, rsp
push rbx
sub rsp, 18h
mov rbx, rdi
mov rax, fs:28h
mov [rbp+var_10], rax
mov rax, [rdi+8]
inc qword ptr [rax+8]
mov rax, [rdi]
mov rcx, [rdi+8]
mov rax, [rax+148h]
add [rcx+10h], rax
lea rsi, [rbp+var_18]
mov byte ptr [rsi-1], 0
mov rax, [rdi]
mov rdx, [rax+58h]
call _mi_dpointer
mov rax, [rbx]
mov rcx, [rbx+170h]
mov [rax+58h], rcx
mov dword ptr [rbx+300h], 1
mov rax, [rbx]
mov edx, [rax+338h]
inc edx
lea rsi, [rbp+var_19]
mov r8d, 4
mov rdi, rbx
call qword ptr [rax+2E8h]
mov rcx, rax
xor eax, eax
test rcx, rcx
setnz cl
mov rdx, fs:28h
cmp rdx, [rbp+var_10]
jnz short loc_8D3A8
mov al, cl
add rsp, 18h
pop rbx
pop rbp
retn
loc_8D3A8:
call ___stack_chk_fail
|
bool mi_delete_static_record(long long *a1)
{
long long v1; // rcx
char v4; // [rsp+7h] [rbp-19h] BYREF
char v5[8]; // [rsp+8h] [rbp-18h] BYREF
unsigned long long v6; // [rsp+10h] [rbp-10h]
v6 = __readfsqword(0x28u);
++*(_QWORD *)(a1[1] + 8);
*(_QWORD *)(a1[1] + 16) += *(_QWORD *)(*a1 + 328);
v4 = 0;
mi_dpointer(a1, (long long)v5, *(_QWORD *)(*a1 + 88));
v1 = a1[46];
*(_QWORD *)(*a1 + 88) = v1;
*((_DWORD *)a1 + 192) = 1;
return (*(long long ( **)(long long *, char *, _QWORD, long long, long long))(*a1 + 744))(
a1,
&v4,
(unsigned int)(*(_DWORD *)(*a1 + 824) + 1),
v1,
4LL) != 0;
}
|
_mi_delete_static_record:
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x18
MOV RBX,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RDI + 0x8]
INC qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RDI]
MOV RCX,qword ptr [RDI + 0x8]
MOV RAX,qword ptr [RAX + 0x148]
ADD qword ptr [RCX + 0x10],RAX
LEA RSI,[RBP + -0x18]
MOV byte ptr [RSI + -0x1],0x0
MOV RAX,qword ptr [RDI]
MOV RDX,qword ptr [RAX + 0x58]
CALL 0x0018b6c7
MOV RAX,qword ptr [RBX]
MOV RCX,qword ptr [RBX + 0x170]
MOV qword ptr [RAX + 0x58],RCX
MOV dword ptr [RBX + 0x300],0x1
MOV RAX,qword ptr [RBX]
MOV EDX,dword ptr [RAX + 0x338]
INC EDX
LEA RSI,[RBP + -0x19]
MOV R8D,0x4
MOV RDI,RBX
CALL qword ptr [RAX + 0x2e8]
MOV RCX,RAX
XOR EAX,EAX
TEST RCX,RCX
SETNZ CL
MOV RDX,qword ptr FS:[0x28]
CMP RDX,qword ptr [RBP + -0x10]
JNZ 0x0018d3a8
MOV AL,CL
ADD RSP,0x18
POP RBX
POP RBP
RET
LAB_0018d3a8:
CALL 0x00129220
|
bool _mi_delete_static_record(long *param_1)
{
long lVar1;
long in_FS_OFFSET;
int1 local_21;
int1 local_20 [8];
long local_18;
local_18 = *(long *)(in_FS_OFFSET + 0x28);
*(long *)(param_1[1] + 8) = *(long *)(param_1[1] + 8) + 1;
*(long *)(param_1[1] + 0x10) = *(long *)(param_1[1] + 0x10) + *(long *)(*param_1 + 0x148);
local_21 = 0;
_mi_dpointer(param_1,local_20,*(int8 *)(*param_1 + 0x58));
lVar1 = param_1[0x2e];
*(long *)(*param_1 + 0x58) = lVar1;
*(int4 *)(param_1 + 0x60) = 1;
lVar1 = (**(code **)(*param_1 + 0x2e8))(param_1,&local_21,*(int *)(*param_1 + 0x338) + 1,lVar1,4);
if (*(long *)(in_FS_OFFSET + 0x28) == local_18) {
return lVar1 != 0;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
|
|
9,951 |
inherit_charset_data
|
eloqsql/mysys/charset.c
|
static void
inherit_charset_data(struct charset_info_st *cs, CHARSET_INFO *refcs)
{
if (!cs->to_upper)
cs->to_upper= refcs->to_upper;
if (!cs->to_lower)
cs->to_lower= refcs->to_lower;
if (!cs->m_ctype)
cs->m_ctype= refcs->m_ctype;
if (!cs->tab_to_uni)
cs->tab_to_uni= refcs->tab_to_uni;
}
|
O3
|
c
|
inherit_charset_data:
pushq %rbp
movq %rsp, %rbp
cmpq $0x0, 0x50(%rdi)
jne 0x49da4
movq 0x50(%rsi), %rax
movq %rax, 0x50(%rdi)
cmpq $0x0, 0x48(%rdi)
jne 0x49db3
movq 0x48(%rsi), %rax
movq %rax, 0x48(%rdi)
cmpq $0x0, 0x40(%rdi)
jne 0x49dc2
movq 0x40(%rsi), %rax
movq %rax, 0x40(%rdi)
cmpq $0x0, 0x68(%rdi)
jne 0x49dd1
movq 0x68(%rsi), %rax
movq %rax, 0x68(%rdi)
popq %rbp
retq
nop
|
inherit_charset_data:
push rbp
mov rbp, rsp
cmp qword ptr [rdi+50h], 0
jnz short loc_49DA4
mov rax, [rsi+50h]
mov [rdi+50h], rax
loc_49DA4:
cmp qword ptr [rdi+48h], 0
jnz short loc_49DB3
mov rax, [rsi+48h]
mov [rdi+48h], rax
loc_49DB3:
cmp qword ptr [rdi+40h], 0
jnz short loc_49DC2
mov rax, [rsi+40h]
mov [rdi+40h], rax
loc_49DC2:
cmp qword ptr [rdi+68h], 0
jnz short loc_49DD1
mov rax, [rsi+68h]
mov [rdi+68h], rax
loc_49DD1:
pop rbp
retn
|
long long inherit_charset_data(_QWORD *a1, _QWORD *a2)
{
long long result; // rax
if ( !a1[10] )
{
result = a2[10];
a1[10] = result;
}
if ( !a1[9] )
{
result = a2[9];
a1[9] = result;
}
if ( !a1[8] )
{
result = a2[8];
a1[8] = result;
}
if ( !a1[13] )
{
result = a2[13];
a1[13] = result;
}
return result;
}
|
inherit_charset_data:
PUSH RBP
MOV RBP,RSP
CMP qword ptr [RDI + 0x50],0x0
JNZ 0x00149da4
MOV RAX,qword ptr [RSI + 0x50]
MOV qword ptr [RDI + 0x50],RAX
LAB_00149da4:
CMP qword ptr [RDI + 0x48],0x0
JNZ 0x00149db3
MOV RAX,qword ptr [RSI + 0x48]
MOV qword ptr [RDI + 0x48],RAX
LAB_00149db3:
CMP qword ptr [RDI + 0x40],0x0
JNZ 0x00149dc2
MOV RAX,qword ptr [RSI + 0x40]
MOV qword ptr [RDI + 0x40],RAX
LAB_00149dc2:
CMP qword ptr [RDI + 0x68],0x0
JNZ 0x00149dd1
MOV RAX,qword ptr [RSI + 0x68]
MOV qword ptr [RDI + 0x68],RAX
LAB_00149dd1:
POP RBP
RET
|
void inherit_charset_data(long param_1,long param_2)
{
if (*(long *)(param_1 + 0x50) == 0) {
*(int8 *)(param_1 + 0x50) = *(int8 *)(param_2 + 0x50);
}
if (*(long *)(param_1 + 0x48) == 0) {
*(int8 *)(param_1 + 0x48) = *(int8 *)(param_2 + 0x48);
}
if (*(long *)(param_1 + 0x40) == 0) {
*(int8 *)(param_1 + 0x40) = *(int8 *)(param_2 + 0x40);
}
if (*(long *)(param_1 + 0x68) == 0) {
*(int8 *)(param_1 + 0x68) = *(int8 *)(param_2 + 0x68);
}
return;
}
|
|
9,952 |
chess::attacks::initSliders(chess::Square, chess::attacks::Magic*, unsigned long, std::function<chess::Bitboard (chess::Square, chess::Bitboard)> const&)
|
Razamindset[P]pawnstar-chess-engine/src/./engine/../chess-library/include/chess.hpp
|
constexpr bool operator!=(const underlying& rhs) const noexcept { return rank_ != rhs; }
|
O1
|
cpp
|
chess::attacks::initSliders(chess::Square, chess::attacks::Magic*, unsigned long, std::function<chess::Bitboard (chess::Square, chess::Bitboard)> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %edi, %eax
andl $-0x8, %eax
cmpl $0x40, %eax
je 0x3c77
movq %rcx, %rbx
movq %rsi, %r14
movl %edi, %ebp
movslq %edi, %rax
shlq $0x5, %rax
movq %rdx, 0x8(%rsi,%rax)
movl %edi, 0xc(%rsp)
movq $0x0, 0x10(%rsp)
cmpq $0x0, 0x10(%rcx)
je 0x3c72
movl %ebp, %ecx
andb $0x7, %cl
movabsq $0x101010101010101, %r15 # imm = 0x101010101010101
movq %r15, %r12
shlq %cl, %r12
addq %rax, %r14
movl %ebp, %ecx
andb $-0x8, %cl
movl $0xff, %r13d
shlq %cl, %r13
leaq 0xc(%rsp), %rsi
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
callq *0x18(%rbx)
movabsq $0x7e7e7e7e7e7e7e7e, %rcx # imm = 0x7E7E7E7E7E7E7E7E
orq %r12, %rcx
movabsq $0xffffffffffff00, %rdx # imm = 0xFFFFFFFFFFFF00
orq %r13, %rdx
andq %rcx, %rdx
andq %rax, %rdx
movq %rdx, (%r14)
movq %rdx, %rax
shrq %rax
movabsq $0x5555555555555555, %rcx # imm = 0x5555555555555555
andq %rax, %rcx
subq %rcx, %rdx
movabsq $0x3333333333333333, %rax # imm = 0x3333333333333333
movq %rdx, %rcx
andq %rax, %rcx
shrq $0x2, %rdx
andq %rax, %rdx
addq %rcx, %rdx
movq %rdx, %rax
shrq $0x4, %rax
addq %rdx, %rax
movabsq $0xf0f0f0f0f0f0f0f, %rcx # imm = 0xF0F0F0F0F0F0F0F
andq %rax, %rcx
imulq %r15, %rcx
shrq $0x38, %rcx
movl $0x40, %eax
subq %rcx, %rax
movq %rax, 0x18(%r14)
cmpl $0x3e, %ebp
jg 0x3c15
movl $0x1, %eax
shlq %cl, %rax
shlq $0x3, %rax
addq 0x10(%r14), %rax
movq %rax, 0x30(%r14)
xorl %r13d, %r13d
leaq 0xc(%rsp), %r15
leaq 0x10(%rsp), %r12
movl %ebp, 0xc(%rsp)
movq %r13, 0x10(%rsp)
cmpq $0x0, 0x10(%rbx)
je 0x3c72
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq *0x18(%rbx)
movq 0x10(%r14), %rdx
movq (%r14), %rsi
andq %r13, %rsi
imulq 0x8(%r14), %rsi
movb 0x18(%r14), %cl
shrq %cl, %rsi
movq %rax, (%rdx,%rsi,8)
movq (%r14), %rax
subq %rax, %r13
andq %rax, %r13
jne 0x3c22
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x30a0
leaq 0xa7e2(%rip), %rdi # 0xe460
leaq 0xa7f1(%rip), %rsi # 0xe476
leaq 0xa866(%rip), %rcx # 0xe4f2
movl $0x216, %edx # imm = 0x216
callq 0x3130
|
_ZN5chess7attacks11initSlidersENS_6SquareEPNS0_5MagicEmRKSt8functionIFNS_8BitboardES1_S5_EE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov eax, edi
and eax, 0FFFFFFF8h
cmp eax, 40h ; '@'
jz loc_3C77
mov rbx, rcx
mov r14, rsi
mov ebp, edi
movsxd rax, edi
shl rax, 5
mov [rsi+rax+8], rdx
mov [rsp+48h+var_3C], edi
mov [rsp+48h+var_38], 0
cmp qword ptr [rcx+10h], 0
jz loc_3C72
mov ecx, ebp
and cl, 7
mov r15, 101010101010101h
mov r12, r15
shl r12, cl
add r14, rax
mov ecx, ebp
and cl, 0F8h
mov r13d, 0FFh
shl r13, cl
lea rsi, [rsp+48h+var_3C]
lea rdx, [rsp+48h+var_38]
mov rdi, rbx
call qword ptr [rbx+18h]
mov rcx, 7E7E7E7E7E7E7E7Eh
or rcx, r12
mov rdx, 0FFFFFFFFFFFF00h
or rdx, r13
and rdx, rcx
and rdx, rax
mov [r14], rdx
mov rax, rdx
shr rax, 1
mov rcx, 5555555555555555h
and rcx, rax
sub rdx, rcx
mov rax, 3333333333333333h
mov rcx, rdx
and rcx, rax
shr rdx, 2
and rdx, rax
add rdx, rcx
mov rax, rdx
shr rax, 4
add rax, rdx
mov rcx, 0F0F0F0F0F0F0F0Fh
and rcx, rax
imul rcx, r15
shr rcx, 38h
mov eax, 40h ; '@'
sub rax, rcx
mov [r14+18h], rax
cmp ebp, 3Eh ; '>'
jg short loc_3C15
mov eax, 1
shl rax, cl
shl rax, 3
add rax, [r14+10h]
mov [r14+30h], rax
loc_3C15:
xor r13d, r13d
lea r15, [rsp+48h+var_3C]
lea r12, [rsp+48h+var_38]
loc_3C22:
mov [rsp+48h+var_3C], ebp
mov [rsp+48h+var_38], r13
cmp qword ptr [rbx+10h], 0
jz short loc_3C72
mov rdi, rbx
mov rsi, r15
mov rdx, r12
call qword ptr [rbx+18h]
mov rdx, [r14+10h]
mov rsi, [r14]
and rsi, r13
imul rsi, [r14+8]
mov cl, [r14+18h]
shr rsi, cl
mov [rdx+rsi*8], rax
mov rax, [r14]
sub r13, rax
and r13, rax
jnz short loc_3C22
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3C72:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
loc_3C77:
lea rdi, aRankRankNoRank; "rank != Rank::NO_RANK"
lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aChessBitboardB; "chess::Bitboard::Bitboard(Rank)"
mov edx, 216h
call ___assert_fail
|
unsigned long long chess::attacks::initSliders(int a1, long long a2, long long a3, long long a4)
{
long long v5; // rax
unsigned long long *v6; // r14
unsigned long long v7; // rdx
unsigned long long v8; // rcx
unsigned long long v9; // r13
unsigned long long result; // rax
int v11; // [rsp+Ch] [rbp-3Ch] BYREF
_QWORD v12[7]; // [rsp+10h] [rbp-38h] BYREF
if ( (a1 & 0xFFFFFFF8) == 0x40 )
__assert_fail(
"rank != Rank::NO_RANK",
"/workspace/llm4binary/github/2025_star3/Razamindset[P]pawnstar-chess-engine/src/./engine/../chess-library/include/chess.hpp",
534LL,
"chess::Bitboard::Bitboard(Rank)");
v5 = 32LL * a1;
*(_QWORD *)(a2 + v5 + 8) = a3;
v11 = a1;
v12[0] = 0LL;
if ( !*(_QWORD *)(a4 + 16) )
LABEL_9:
std::__throw_bad_function_call();
v6 = (unsigned long long *)(v5 + a2);
v7 = (*(long long ( **)(long long, int *, _QWORD *))(a4 + 24))(a4, &v11, v12) & ((0x101010101010101LL << (a1 & 7)) | 0x7E7E7E7E7E7E7E7ELL) & ((255LL << (a1 & 0xF8)) | 0xFFFFFFFFFFFF00LL);
*v6 = v7;
v8 = (0x101010101010101LL
* ((((v7 - ((v7 >> 1) & 0x5555555555555555LL)) & 0x3333333333333333LL)
+ (((v7 - ((v7 >> 1) & 0x5555555555555555LL)) >> 2) & 0x3333333333333333LL)
+ ((((v7 - ((v7 >> 1) & 0x5555555555555555LL)) & 0x3333333333333333LL)
+ (((v7 - ((v7 >> 1) & 0x5555555555555555LL)) >> 2) & 0x3333333333333333LL)) >> 4)) & 0xF0F0F0F0F0F0F0FLL)) >> 56;
v6[3] = 64 - v8;
if ( a1 <= 62 )
v6[6] = v6[2] + 8 * (1LL << v8);
v9 = 0LL;
do
{
v11 = a1;
v12[0] = v9;
if ( !*(_QWORD *)(a4 + 16) )
goto LABEL_9;
*(_QWORD *)(v6[2] + 8 * ((v6[1] * (v9 & *v6)) >> *((_BYTE *)v6 + 24))) = (*(long long ( **)(long long, int *, _QWORD *))(a4 + 24))(
a4,
&v11,
v12);
result = *v6;
v9 = *v6 & (v9 - *v6);
}
while ( v9 );
return result;
}
|
initSliders:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV EAX,EDI
AND EAX,0xfffffff8
CMP EAX,0x40
JZ 0x00103c77
MOV RBX,RCX
MOV R14,RSI
MOV EBP,EDI
MOVSXD RAX,EDI
SHL RAX,0x5
MOV qword ptr [RSI + RAX*0x1 + 0x8],RDX
MOV dword ptr [RSP + 0xc],EDI
MOV qword ptr [RSP + 0x10],0x0
CMP qword ptr [RCX + 0x10],0x0
JZ 0x00103c72
MOV ECX,EBP
AND CL,0x7
MOV R15,0x101010101010101
MOV R12,R15
SHL R12,CL
ADD R14,RAX
MOV ECX,EBP
AND CL,0xf8
MOV R13D,0xff
SHL R13,CL
LEA RSI,[RSP + 0xc]
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
CALL qword ptr [RBX + 0x18]
MOV RCX,0x7e7e7e7e7e7e7e7e
OR RCX,R12
MOV RDX,0xffffffffffff00
OR RDX,R13
AND RDX,RCX
AND RDX,RAX
MOV qword ptr [R14],RDX
MOV RAX,RDX
SHR RAX,0x1
MOV RCX,0x5555555555555555
AND RCX,RAX
SUB RDX,RCX
MOV RAX,0x3333333333333333
MOV RCX,RDX
AND RCX,RAX
SHR RDX,0x2
AND RDX,RAX
ADD RDX,RCX
MOV RAX,RDX
SHR RAX,0x4
ADD RAX,RDX
MOV RCX,0xf0f0f0f0f0f0f0f
AND RCX,RAX
IMUL RCX,R15
SHR RCX,0x38
MOV EAX,0x40
SUB RAX,RCX
MOV qword ptr [R14 + 0x18],RAX
CMP EBP,0x3e
JG 0x00103c15
MOV EAX,0x1
SHL RAX,CL
SHL RAX,0x3
ADD RAX,qword ptr [R14 + 0x10]
MOV qword ptr [R14 + 0x30],RAX
LAB_00103c15:
XOR R13D,R13D
LEA R15,[RSP + 0xc]
LEA R12,[RSP + 0x10]
LAB_00103c22:
MOV dword ptr [RSP + 0xc],EBP
MOV qword ptr [RSP + 0x10],R13
CMP qword ptr [RBX + 0x10],0x0
JZ 0x00103c72
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R12
CALL qword ptr [RBX + 0x18]
MOV RDX,qword ptr [R14 + 0x10]
MOV RSI,qword ptr [R14]
AND RSI,R13
IMUL RSI,qword ptr [R14 + 0x8]
MOV CL,byte ptr [R14 + 0x18]
SHR RSI,CL
MOV qword ptr [RDX + RSI*0x8],RAX
MOV RAX,qword ptr [R14]
SUB R13,RAX
AND R13,RAX
JNZ 0x00103c22
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00103c72:
CALL 0x001030a0
LAB_00103c77:
LEA RDI,[0x10e460]
LEA RSI,[0x10e476]
LEA RCX,[0x10e4f2]
MOV EDX,0x216
CALL 0x00103130
|
/* chess::attacks::initSliders(chess::Square, chess::attacks::Magic*, unsigned long,
std::function<chess::Bitboard (chess::Square, chess::Bitboard)> const&) */
void chess::attacks::initSliders(uint param_1,long param_2,int8 param_3,long param_4)
{
ulong uVar1;
int8 uVar2;
ulong *puVar3;
uint local_3c;
ulong local_38;
if ((param_1 & 0xfffffff8) != 0x40) {
*(int8 *)(param_2 + 8 + (long)(int)param_1 * 0x20) = param_3;
local_38 = 0;
if (*(long *)(param_4 + 0x10) != 0) {
puVar3 = (ulong *)(param_2 + (long)(int)param_1 * 0x20);
local_3c = param_1;
uVar1 = (**(code **)(param_4 + 0x18))(param_4,&local_3c,&local_38);
uVar1 = (0xffL << ((byte)param_1 & 0x38) | 0xffffffffffff00U) &
(0x101010101010101 << ((byte)param_1 & 7) | 0x7e7e7e7e7e7e7e7eU) & uVar1;
*puVar3 = uVar1;
uVar1 = uVar1 - (uVar1 >> 1 & 0x5555555555555555);
uVar1 = (uVar1 >> 2 & 0x3333333333333333) + (uVar1 & 0x3333333333333333);
uVar1 = ((uVar1 >> 4) + uVar1 & 0xf0f0f0f0f0f0f0f) * 0x101010101010101;
puVar3[3] = 0x40 - (uVar1 >> 0x38);
if ((int)param_1 < 0x3f) {
puVar3[6] = (1L << ((byte)(uVar1 >> 0x38) & 0x3f)) * 8 + puVar3[2];
}
uVar1 = 0;
while( true ) {
local_38 = uVar1;
if (*(long *)(param_4 + 0x10) == 0) break;
local_3c = param_1;
uVar2 = (**(code **)(param_4 + 0x18))(param_4,&local_3c,&local_38);
*(int8 *)(puVar3[2] + ((*puVar3 & uVar1) * puVar3[1] >> ((byte)puVar3[3] & 0x3f)) * 8)
= uVar2;
uVar1 = uVar1 - *puVar3 & *puVar3;
if (uVar1 == 0) {
return;
}
}
}
local_3c = param_1;
std::__throw_bad_function_call();
}
/* WARNING: Subroutine does not return */
__assert_fail("rank != Rank::NO_RANK",
"/workspace/llm4binary/github/2025_star3/Razamindset[P]pawnstar-chess-engine/src/./engine/../chess-library/include/chess.hpp"
,0x216,"chess::Bitboard::Bitboard(Rank)");
}
|
|
9,953 |
chess::attacks::initSliders(chess::Square, chess::attacks::Magic*, unsigned long, std::function<chess::Bitboard (chess::Square, chess::Bitboard)> const&)
|
Razamindset[P]pawnstar-chess-engine/src/./engine/../chess-library/include/chess.hpp
|
constexpr bool operator!=(const underlying& rhs) const noexcept { return rank_ != rhs; }
|
O3
|
cpp
|
chess::attacks::initSliders(chess::Square, chess::attacks::Magic*, unsigned long, std::function<chess::Bitboard (chess::Square, chess::Bitboard)> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %edi, %eax
andl $-0x8, %eax
cmpl $0x40, %eax
je 0x2cd8
movq %rcx, %rbx
movq %rsi, %r14
movl %edi, %ebp
movslq %edi, %rcx
shlq $0x5, %rcx
movq %rdx, 0x8(%rsi,%rcx)
movl %edi, 0xc(%rsp)
movq $0x0, 0x10(%rsp)
cmpq $0x0, 0x10(%rbx)
je 0x2cd3
addq %rcx, %r14
movl %ebp, %ecx
andb $0x7, %cl
movabsq $0x101010101010101, %r15 # imm = 0x101010101010101
movq %r15, %r12
shlq %cl, %r12
movl $0xff, %r13d
movl %eax, %ecx
shlq %cl, %r13
leaq 0xc(%rsp), %rsi
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
callq *0x18(%rbx)
movabsq $0x7e7e7e7e7e7e7e7e, %rcx # imm = 0x7E7E7E7E7E7E7E7E
orq %r12, %rcx
movabsq $0xffffffffffff00, %rdx # imm = 0xFFFFFFFFFFFF00
orq %r13, %rdx
andq %rcx, %rdx
andq %rax, %rdx
movq %rdx, (%r14)
movq %rdx, %rax
shrq %rax
movabsq $0x5555555555555555, %rcx # imm = 0x5555555555555555
andq %rax, %rcx
subq %rcx, %rdx
movabsq $0x3333333333333333, %rax # imm = 0x3333333333333333
movq %rdx, %rcx
andq %rax, %rcx
shrq $0x2, %rdx
andq %rax, %rdx
addq %rcx, %rdx
movq %rdx, %rax
shrq $0x4, %rax
addq %rdx, %rax
movabsq $0xf0f0f0f0f0f0f0f, %rcx # imm = 0xF0F0F0F0F0F0F0F
andq %rax, %rcx
imulq %r15, %rcx
shrq $0x38, %rcx
movl $0x40, %eax
subq %rcx, %rax
movq %rax, 0x18(%r14)
cmpl $0x3e, %ebp
jg 0x2c76
movl $0x1, %eax
shlq %cl, %rax
shlq $0x3, %rax
addq 0x10(%r14), %rax
movq %rax, 0x30(%r14)
xorl %r13d, %r13d
leaq 0xc(%rsp), %r15
leaq 0x10(%rsp), %r12
movl %ebp, 0xc(%rsp)
movq %r13, 0x10(%rsp)
cmpq $0x0, 0x10(%rbx)
je 0x2cd3
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq *0x18(%rbx)
movq 0x10(%r14), %rdx
movq (%r14), %rsi
andq %r13, %rsi
imulq 0x8(%r14), %rsi
movb 0x18(%r14), %cl
shrq %cl, %rsi
movq %rax, (%rdx,%rsi,8)
movq (%r14), %rax
subq %rax, %r13
andq %rax, %r13
jne 0x2c83
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x20a0
leaq 0x9781(%rip), %rdi # 0xc460
leaq 0x9790(%rip), %rsi # 0xc476
leaq 0x9805(%rip), %rcx # 0xc4f2
movl $0x216, %edx # imm = 0x216
callq 0x2130
nop
|
_ZN5chess7attacks11initSlidersENS_6SquareEPNS0_5MagicEmRKSt8functionIFNS_8BitboardES1_S5_EE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov eax, edi
and eax, 0FFFFFFF8h
cmp eax, 40h ; '@'
jz loc_2CD8
mov rbx, rcx
mov r14, rsi
mov ebp, edi
movsxd rcx, edi
shl rcx, 5
mov [rsi+rcx+8], rdx
mov [rsp+48h+var_3C], edi
mov [rsp+48h+var_38], 0
cmp qword ptr [rbx+10h], 0
jz loc_2CD3
add r14, rcx
mov ecx, ebp
and cl, 7
mov r15, 101010101010101h
mov r12, r15
shl r12, cl
mov r13d, 0FFh
mov ecx, eax
shl r13, cl
lea rsi, [rsp+48h+var_3C]
lea rdx, [rsp+48h+var_38]
mov rdi, rbx
call qword ptr [rbx+18h]
mov rcx, 7E7E7E7E7E7E7E7Eh
or rcx, r12
mov rdx, 0FFFFFFFFFFFF00h
or rdx, r13
and rdx, rcx
and rdx, rax
mov [r14], rdx
mov rax, rdx
shr rax, 1
mov rcx, 5555555555555555h
and rcx, rax
sub rdx, rcx
mov rax, 3333333333333333h
mov rcx, rdx
and rcx, rax
shr rdx, 2
and rdx, rax
add rdx, rcx
mov rax, rdx
shr rax, 4
add rax, rdx
mov rcx, 0F0F0F0F0F0F0F0Fh
and rcx, rax
imul rcx, r15
shr rcx, 38h
mov eax, 40h ; '@'
sub rax, rcx
mov [r14+18h], rax
cmp ebp, 3Eh ; '>'
jg short loc_2C76
mov eax, 1
shl rax, cl
shl rax, 3
add rax, [r14+10h]
mov [r14+30h], rax
loc_2C76:
xor r13d, r13d
lea r15, [rsp+48h+var_3C]
lea r12, [rsp+48h+var_38]
loc_2C83:
mov [rsp+48h+var_3C], ebp
mov [rsp+48h+var_38], r13
cmp qword ptr [rbx+10h], 0
jz short loc_2CD3
mov rdi, rbx
mov rsi, r15
mov rdx, r12
call qword ptr [rbx+18h]
mov rdx, [r14+10h]
mov rsi, [r14]
and rsi, r13
imul rsi, [r14+8]
mov cl, [r14+18h]
shr rsi, cl
mov [rdx+rsi*8], rax
mov rax, [r14]
sub r13, rax
and r13, rax
jnz short loc_2C83
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_2CD3:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
loc_2CD8:
lea rdi, aRankRankNoRank; "rank != Rank::NO_RANK"
lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aChessBitboardB; "chess::Bitboard::Bitboard(Rank)"
mov edx, 216h
call ___assert_fail
|
unsigned long long chess::attacks::initSliders(int a1, long long a2, long long a3, long long a4)
{
long long v5; // rcx
unsigned long long *v6; // r14
unsigned long long v7; // rdx
unsigned long long v8; // rcx
unsigned long long v9; // r13
unsigned long long result; // rax
int v11; // [rsp+Ch] [rbp-3Ch] BYREF
_QWORD v12[7]; // [rsp+10h] [rbp-38h] BYREF
if ( (a1 & 0xFFFFFFF8) == 0x40 )
__assert_fail(
"rank != Rank::NO_RANK",
"/workspace/llm4binary/github/2025_star3/Razamindset[P]pawnstar-chess-engine/src/./engine/../chess-library/include/chess.hpp",
534LL,
"chess::Bitboard::Bitboard(Rank)");
v5 = 32LL * a1;
*(_QWORD *)(a2 + v5 + 8) = a3;
v11 = a1;
v12[0] = 0LL;
if ( !*(_QWORD *)(a4 + 16) )
LABEL_9:
std::__throw_bad_function_call();
v6 = (unsigned long long *)(v5 + a2);
v7 = (*(long long ( **)(long long, int *, _QWORD *))(a4 + 24))(a4, &v11, v12) & ((0x101010101010101LL << (a1 & 7)) | 0x7E7E7E7E7E7E7E7ELL) & ((255LL << (a1 & 0xF8)) | 0xFFFFFFFFFFFF00LL);
*v6 = v7;
v8 = (0x101010101010101LL
* ((((v7 - ((v7 >> 1) & 0x5555555555555555LL)) & 0x3333333333333333LL)
+ (((v7 - ((v7 >> 1) & 0x5555555555555555LL)) >> 2) & 0x3333333333333333LL)
+ ((((v7 - ((v7 >> 1) & 0x5555555555555555LL)) & 0x3333333333333333LL)
+ (((v7 - ((v7 >> 1) & 0x5555555555555555LL)) >> 2) & 0x3333333333333333LL)) >> 4)) & 0xF0F0F0F0F0F0F0FLL)) >> 56;
v6[3] = 64 - v8;
if ( a1 <= 62 )
v6[6] = v6[2] + 8 * (1LL << v8);
v9 = 0LL;
do
{
v11 = a1;
v12[0] = v9;
if ( !*(_QWORD *)(a4 + 16) )
goto LABEL_9;
*(_QWORD *)(v6[2] + 8 * ((v6[1] * (v9 & *v6)) >> *((_BYTE *)v6 + 24))) = (*(long long ( **)(long long, int *, _QWORD *))(a4 + 24))(
a4,
&v11,
v12);
result = *v6;
v9 = *v6 & (v9 - *v6);
}
while ( v9 );
return result;
}
|
initSliders:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV EAX,EDI
AND EAX,0xfffffff8
CMP EAX,0x40
JZ 0x00102cd8
MOV RBX,RCX
MOV R14,RSI
MOV EBP,EDI
MOVSXD RCX,EDI
SHL RCX,0x5
MOV qword ptr [RSI + RCX*0x1 + 0x8],RDX
MOV dword ptr [RSP + 0xc],EDI
MOV qword ptr [RSP + 0x10],0x0
CMP qword ptr [RBX + 0x10],0x0
JZ 0x00102cd3
ADD R14,RCX
MOV ECX,EBP
AND CL,0x7
MOV R15,0x101010101010101
MOV R12,R15
SHL R12,CL
MOV R13D,0xff
MOV ECX,EAX
SHL R13,CL
LEA RSI,[RSP + 0xc]
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
CALL qword ptr [RBX + 0x18]
MOV RCX,0x7e7e7e7e7e7e7e7e
OR RCX,R12
MOV RDX,0xffffffffffff00
OR RDX,R13
AND RDX,RCX
AND RDX,RAX
MOV qword ptr [R14],RDX
MOV RAX,RDX
SHR RAX,0x1
MOV RCX,0x5555555555555555
AND RCX,RAX
SUB RDX,RCX
MOV RAX,0x3333333333333333
MOV RCX,RDX
AND RCX,RAX
SHR RDX,0x2
AND RDX,RAX
ADD RDX,RCX
MOV RAX,RDX
SHR RAX,0x4
ADD RAX,RDX
MOV RCX,0xf0f0f0f0f0f0f0f
AND RCX,RAX
IMUL RCX,R15
SHR RCX,0x38
MOV EAX,0x40
SUB RAX,RCX
MOV qword ptr [R14 + 0x18],RAX
CMP EBP,0x3e
JG 0x00102c76
MOV EAX,0x1
SHL RAX,CL
SHL RAX,0x3
ADD RAX,qword ptr [R14 + 0x10]
MOV qword ptr [R14 + 0x30],RAX
LAB_00102c76:
XOR R13D,R13D
LEA R15,[RSP + 0xc]
LEA R12,[RSP + 0x10]
LAB_00102c83:
MOV dword ptr [RSP + 0xc],EBP
MOV qword ptr [RSP + 0x10],R13
CMP qword ptr [RBX + 0x10],0x0
JZ 0x00102cd3
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R12
CALL qword ptr [RBX + 0x18]
MOV RDX,qword ptr [R14 + 0x10]
MOV RSI,qword ptr [R14]
AND RSI,R13
IMUL RSI,qword ptr [R14 + 0x8]
MOV CL,byte ptr [R14 + 0x18]
SHR RSI,CL
MOV qword ptr [RDX + RSI*0x8],RAX
MOV RAX,qword ptr [R14]
SUB R13,RAX
AND R13,RAX
JNZ 0x00102c83
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00102cd3:
CALL 0x001020a0
LAB_00102cd8:
LEA RDI,[0x10c460]
LEA RSI,[0x10c476]
LEA RCX,[0x10c4f2]
MOV EDX,0x216
CALL 0x00102130
|
/* chess::attacks::initSliders(chess::Square, chess::attacks::Magic*, unsigned long,
std::function<chess::Bitboard (chess::Square, chess::Bitboard)> const&) */
void chess::attacks::initSliders(uint param_1,long param_2,int8 param_3,long param_4)
{
ulong uVar1;
int8 uVar2;
ulong *puVar3;
uint local_3c;
ulong local_38;
if ((param_1 & 0xfffffff8) != 0x40) {
*(int8 *)(param_2 + 8 + (long)(int)param_1 * 0x20) = param_3;
local_38 = 0;
if (*(long *)(param_4 + 0x10) != 0) {
puVar3 = (ulong *)(param_2 + (long)(int)param_1 * 0x20);
local_3c = param_1;
uVar1 = (**(code **)(param_4 + 0x18))(param_4,&local_3c,&local_38);
uVar1 = (0xffL << ((byte)(param_1 & 0xfffffff8) & 0x3f) | 0xffffffffffff00U) &
(0x101010101010101 << ((byte)param_1 & 7) | 0x7e7e7e7e7e7e7e7eU) & uVar1;
*puVar3 = uVar1;
uVar1 = uVar1 - (uVar1 >> 1 & 0x5555555555555555);
uVar1 = (uVar1 >> 2 & 0x3333333333333333) + (uVar1 & 0x3333333333333333);
uVar1 = ((uVar1 >> 4) + uVar1 & 0xf0f0f0f0f0f0f0f) * 0x101010101010101;
puVar3[3] = 0x40 - (uVar1 >> 0x38);
if ((int)param_1 < 0x3f) {
puVar3[6] = (1L << ((byte)(uVar1 >> 0x38) & 0x3f)) * 8 + puVar3[2];
}
uVar1 = 0;
while( true ) {
local_38 = uVar1;
if (*(long *)(param_4 + 0x10) == 0) break;
local_3c = param_1;
uVar2 = (**(code **)(param_4 + 0x18))(param_4,&local_3c,&local_38);
*(int8 *)(puVar3[2] + ((*puVar3 & uVar1) * puVar3[1] >> ((byte)puVar3[3] & 0x3f)) * 8)
= uVar2;
uVar1 = uVar1 - *puVar3 & *puVar3;
if (uVar1 == 0) {
return;
}
}
}
local_3c = param_1;
std::__throw_bad_function_call();
}
/* WARNING: Subroutine does not return */
__assert_fail("rank != Rank::NO_RANK",
"/workspace/llm4binary/github/2025_star3/Razamindset[P]pawnstar-chess-engine/src/./engine/../chess-library/include/chess.hpp"
,0x216,"chess::Bitboard::Bitboard(Rank)");
}
|
|
9,954 |
flush_log_for_bitmap
|
eloqsql/storage/maria/ma_bitmap.c
|
static my_bool
flush_log_for_bitmap(PAGECACHE_IO_HOOK_ARGS *args __attribute__ ((unused)))
{
#ifdef DBUG_ASSERT_EXISTS
const MARIA_SHARE *share= (MARIA_SHARE*)args->data;
#endif
DBUG_ENTER("flush_log_for_bitmap");
DBUG_ASSERT(share->now_transactional);
/*
WAL imposes that UNDOs reach disk before bitmap is flushed. We don't know
the LSN of the last UNDO about this bitmap page, so we flush whole log.
*/
DBUG_RETURN(translog_flush(translog_get_horizon()));
}
|
O0
|
c
|
flush_log_for_bitmap:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
jmp 0x4445e
jmp 0x44460
movb $0x0, %al
callq 0x54bc0
movq %rax, %rdi
callq 0x56800
movb %al, -0x9(%rbp)
movb -0x9(%rbp), %al
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
flush_log_for_bitmap:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
jmp short $+2
loc_4445E:
jmp short $+2
loc_44460:
mov al, 0
call translog_get_horizon
mov rdi, rax
call translog_flush
mov [rbp+var_9], al
mov al, [rbp+var_9]
add rsp, 10h
pop rbp
retn
|
long long flush_log_for_bitmap()
{
long long horizon; // rax
horizon = translog_get_horizon();
return translog_flush(horizon);
}
|
flush_log_for_bitmap:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
JMP 0x0014445e
LAB_0014445e:
JMP 0x00144460
LAB_00144460:
MOV AL,0x0
CALL 0x00154bc0
MOV RDI,RAX
CALL 0x00156800
MOV byte ptr [RBP + -0x9],AL
MOV AL,byte ptr [RBP + -0x9]
ADD RSP,0x10
POP RBP
RET
|
int1 flush_log_for_bitmap(void)
{
int8 uVar1;
int1 uVar2;
uVar1 = translog_get_horizon();
uVar2 = translog_flush(uVar1);
return uVar2;
}
|
|
9,955 |
my_strnxfrm_tis620
|
eloqsql/strings/ctype-tis620.c
|
static size_t
my_strnxfrm_tis620(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(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;
my_ci_fill(cs, (char*) dst + len, fill_length, cs->pad_char);
len= dstlen0;
}
return len;
}
|
O3
|
c
|
my_strnxfrm_tis620:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r9, %r13
movl %ecx, %r12d
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
cmpq %r9, %rdx
cmovbq %rdx, %r13
movq %rsi, %rdi
movq %r8, %rsi
movq %r13, %rdx
callq 0x29080
movq %r14, %rdi
movq %r13, %rsi
callq 0xb7adb
movl %r12d, %r8d
cmpq %rbx, %r8
cmovaeq %rbx, %r8
cmpq %r8, %r13
cmovaeq %r8, %r13
leaq (%r14,%r13), %rdx
leaq (%r14,%r8), %rcx
subl %r13d, %r8d
movl $0x0, (%rsp)
movq %r15, %rdi
movq %r14, %rsi
movl 0x10(%rbp), %r12d
movl %r12d, %r9d
callq 0xb4844
testb %r12b, %r12b
jns 0xb7acc
movq %rbx, %rdx
subq %rax, %rdx
jbe 0xb7acc
addq %rax, %r14
movzbl 0xb0(%r15), %ecx
movq 0xb8(%r15), %rax
movq %r15, %rdi
movq %r14, %rsi
callq *0x78(%rax)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
my_strnxfrm_tis620:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r13, r9
mov r12d, ecx
mov rbx, rdx
mov r14, rsi
mov r15, rdi
cmp rdx, r9
cmovb r13, rdx
mov rdi, rsi
mov rsi, r8
mov rdx, r13
call _memcpy
mov rdi, r14
mov rsi, r13
call thai2sortable
mov r8d, r12d
cmp r8, rbx
cmovnb r8, rbx
cmp r13, r8
cmovnb r13, r8
lea rdx, [r14+r13]
lea rcx, [r14+r8]
sub r8d, r13d
mov [rsp+30h+var_30], 0
mov rdi, r15
mov rsi, r14
mov r12d, [rbp+arg_0]
mov r9d, r12d
call my_strxfrm_pad_desc_and_reverse
test r12b, r12b
jns short loc_B7ACC
mov rdx, rbx
sub rdx, rax
jbe short loc_B7ACC
add r14, rax
movzx ecx, byte ptr [r15+0B0h]
mov rax, [r15+0B8h]
mov rdi, r15
mov rsi, r14
call qword ptr [rax+78h]
mov rax, rbx
loc_B7ACC:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
unsigned long long my_strnxfrm_tis620(
long long a1,
long long a2,
unsigned long long a3,
unsigned int a4,
long long a5,
unsigned long long a6,
unsigned int a7)
{
unsigned long long v7; // r13
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(a1, a2, a2 + v7, a2 + v10, (int)v10 - (int)v7, a7, 0);
if ( (a7 & 0x80u) != 0 && a3 > result )
{
(*(void ( **)(long long, unsigned long long, unsigned long long, _QWORD))(*(_QWORD *)(a1 + 184) + 120LL))(
a1,
result + a2,
a3 - result,
*(unsigned __int8 *)(a1 + 176));
return a3;
}
return result;
}
|
my_strnxfrm_tis620:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R13,R9
MOV R12D,ECX
MOV RBX,RDX
MOV R14,RSI
MOV R15,RDI
CMP RDX,R9
CMOVC R13,RDX
MOV RDI,RSI
MOV RSI,R8
MOV RDX,R13
CALL 0x00129080
MOV RDI,R14
MOV RSI,R13
CALL 0x001b7adb
MOV R8D,R12D
CMP R8,RBX
CMOVNC R8,RBX
CMP R13,R8
CMOVNC R13,R8
LEA RDX,[R14 + R13*0x1]
LEA RCX,[R14 + R8*0x1]
SUB R8D,R13D
MOV dword ptr [RSP],0x0
MOV RDI,R15
MOV RSI,R14
MOV R12D,dword ptr [RBP + 0x10]
MOV R9D,R12D
CALL 0x001b4844
TEST R12B,R12B
JNS 0x001b7acc
MOV RDX,RBX
SUB RDX,RAX
JBE 0x001b7acc
ADD R14,RAX
MOVZX ECX,byte ptr [R15 + 0xb0]
MOV RAX,qword ptr [R15 + 0xb8]
MOV RDI,R15
MOV RSI,R14
CALL qword ptr [RAX + 0x78]
MOV RAX,RBX
LAB_001b7acc:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
ulong my_strnxfrm_tis620(long 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
(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)) {
(**(code **)(*(long *)(param_1 + 0xb8) + 0x78))
(param_1,(long)param_2 + uVar1,param_3 - uVar1,*(int1 *)(param_1 + 0xb0));
uVar1 = param_3;
}
return uVar1;
}
|
|
9,956 |
nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>> 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>::parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>(nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>, std::function<bool (int, nlohmann::json_abi_v3_11_3::detail::parse_event_t, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&)>, bool, bool)
|
monkey531[P]llama/common/json.hpp
|
static ::nlohmann::detail::parser<basic_json, InputAdapterType> parser(
InputAdapterType adapter,
detail::parser_callback_t<basic_json>cb = nullptr,
const bool allow_exceptions = true,
const bool ignore_comments = false
)
{
return ::nlohmann::detail::parser<basic_json, InputAdapterType>(std::move(adapter),
std::move(cb), allow_exceptions, ignore_comments);
}
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>> 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>::parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>(nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>, std::function<bool (int, nlohmann::json_abi_v3_11_3::detail::parse_event_t, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&)>, bool, bool):
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
movq %rsi, 0x20(%rsp)
movq %rdx, 0x28(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
movq 0x18(%rcx), %rax
movq %rax, 0x18(%rsp)
movq 0x10(%rcx), %rax
testq %rax, %rax
je 0x57821
movups (%rcx), %xmm1
addq $0x10, %rcx
movaps %xmm1, (%rsp)
movq %rax, 0x10(%rsp)
movups %xmm0, (%rcx)
movzbl %r8b, %ecx
movzbl %r9b, %r8d
leaq 0x20(%rsp), %rsi
movq %rsp, %rdx
movq %rbx, %rdi
callq 0x5833a
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0x57850
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rax
addq $0x30, %rsp
popq %rbx
retq
jmp 0x5787d
movq %rax, %rbx
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0x57875
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rdi
callq 0x1afa0
movq %rax, %rdi
callq 0x212e3
nop
|
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6parserINS0_6detail22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcS9_EEEEEENSF_6parserISD_T_EESO_St8functionIFbiNSF_13parse_event_tERSD_EEbb:
push rbx
sub rsp, 30h
mov rbx, rdi
mov [rsp+38h+var_18], rsi
mov [rsp+38h+var_10], rdx
xorps xmm0, xmm0
movaps [rsp+38h+var_38], xmm0
mov [rsp+38h+var_28], 0
mov rax, [rcx+18h]
mov [rsp+38h+var_20], rax
mov rax, [rcx+10h]
test rax, rax
jz short loc_57821
movups xmm1, xmmword ptr [rcx]
add rcx, 10h
movaps [rsp+38h+var_38], xmm1
mov [rsp+38h+var_28], rax
movups xmmword ptr [rcx], xmm0
loc_57821:
movzx ecx, r8b
movzx r8d, r9b
lea rsi, [rsp+38h+var_18]
mov rdx, rsp
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail6parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEEC2EOSM_St8functionIFbiNS1_13parse_event_tERSF_EEbb; nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::parser(nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>&&,std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&)>,bool,bool)
mov rax, [rsp+38h+var_28]
test rax, rax
jz short loc_57850
mov rdi, rsp
mov rsi, rdi
mov edx, 3
call rax
loc_57850:
mov rax, rbx
add rsp, 30h
pop rbx
retn
jmp short loc_5787D
mov rbx, rax
mov rax, [rsp+38h+var_28]
test rax, rax
jz short loc_57875
mov rdi, rsp
mov rsi, rdi
mov edx, 3
call rax
loc_57875:
mov rdi, rbx
call __Unwind_Resume
loc_5787D:
mov rdi, rax
call __clang_call_terminate
|
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>::parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>(
long long a1,
long long a2,
long long a3,
__int128 *a4,
unsigned __int8 a5,
unsigned __int8 a6)
{
void ( *v6)(__int128 *, __int128 *, long long); // rax
__int128 v8; // [rsp+0h] [rbp-38h] BYREF
void ( *v9)(__int128 *, __int128 *, long long); // [rsp+10h] [rbp-28h]
long long v10; // [rsp+18h] [rbp-20h]
_QWORD v11[3]; // [rsp+20h] [rbp-18h] BYREF
v11[0] = a2;
v11[1] = a3;
v8 = 0LL;
v9 = 0LL;
v10 = *((_QWORD *)a4 + 3);
v6 = (void ( *)(__int128 *, __int128 *, long long))*((_QWORD *)a4 + 2);
if ( v6 )
{
v8 = *a4;
v9 = v6;
a4[1] = 0LL;
}
((void ( *)(long long, _QWORD *, __int128 *, _QWORD, _QWORD))nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::parser)(
a1,
v11,
&v8,
a5,
a6);
if ( v9 )
v9(&v8, &v8, 3LL);
return a1;
}
|
parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>:
PUSH RBX
SUB RSP,0x30
MOV RBX,RDI
MOV qword ptr [RSP + 0x20],RSI
MOV qword ptr [RSP + 0x28],RDX
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP],XMM0
MOV qword ptr [RSP + 0x10],0x0
MOV RAX,qword ptr [RCX + 0x18]
MOV qword ptr [RSP + 0x18],RAX
MOV RAX,qword ptr [RCX + 0x10]
TEST RAX,RAX
JZ 0x00157821
MOVUPS XMM1,xmmword ptr [RCX]
ADD RCX,0x10
MOVAPS xmmword ptr [RSP],XMM1
MOV qword ptr [RSP + 0x10],RAX
MOVUPS xmmword ptr [RCX],XMM0
LAB_00157821:
MOVZX ECX,R8B
MOVZX R8D,R9B
LEA RSI,[RSP + 0x20]
MOV RDX,RSP
MOV RDI,RBX
CALL 0x0015833a
MOV RAX,qword ptr [RSP + 0x10]
TEST RAX,RAX
JZ 0x00157850
LAB_00157843:
MOV RDI,RSP
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_00157850:
MOV RAX,RBX
ADD RSP,0x30
POP RBX
RET
|
/* nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>,
nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char
const*, std::__cxx11::string > > >
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>::parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char
const*, std::__cxx11::string > >
>(nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char
const*, std::__cxx11::string > >, std::function<bool (int,
nlohmann::json_abi_v3_11_3::detail::parse_event_t,
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>&)>, bool, bool) */
parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
* 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>
::
parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
(parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
*param_1,int8 param_2,int8 param_3,int8 *param_4,int1 param_5,
int1 param_6)
{
code *pcVar1;
int8 local_38;
int8 uStack_30;
code *local_28;
int8 local_20;
int8 local_18;
int8 local_10;
local_38 = 0;
uStack_30 = 0;
local_28 = (code *)0x0;
local_20 = param_4[3];
pcVar1 = (code *)param_4[2];
if (pcVar1 != (code *)0x0) {
local_38 = *param_4;
uStack_30 = param_4[1];
param_4[2] = 0;
param_4[3] = 0;
local_28 = pcVar1;
}
/* try { // try from 00157821 to 00157838 has its CatchHandler @ 0015785b */
local_18 = param_2;
local_10 = param_3;
detail::
parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
::parser(param_1,&local_18,&local_38,param_5,param_6);
if (local_28 != (code *)0x0) {
/* try { // try from 00157843 to 0015784f has its CatchHandler @ 00157859 */
(*local_28)(&local_38,&local_38,3);
}
return param_1;
}
|
|
9,957 |
std::less<ftxui::(anonymous namespace)::TileEncoding>::operator()(ftxui::(anonymous namespace)::TileEncoding const&, ftxui::(anonymous namespace)::TileEncoding const&) const
|
Andrewchistyakov[P]flashcards_lyc/build_O2/_deps/ftxui-src/src/ftxui/screen/screen.cpp
|
bool operator<(const TileEncoding& other) const {
if (left < other.left) { return true; }
if (left > other.left) { return false; }
if (top < other.top) { return true; }
if (top > other.top) { return false; }
if (right < other.right) { return true; }
if (right > other.right) { return false; }
if (down < other.down) { return true; }
if (down > other.down) { return false; }
if (round < other.round) { return true; }
if (round > other.round) { return false; }
return false;
}
|
O2
|
cpp
|
std::less<ftxui::(anonymous namespace)::TileEncoding>::operator()(ftxui::(anonymous namespace)::TileEncoding const&, ftxui::(anonymous namespace)::TileEncoding const&) const:
movzwl (%rdi), %ecx
movl %ecx, %edi
andl $0x3, %edi
movzwl (%rsi), %edx
movl %edx, %esi
andl $0x3, %esi
movb $0x1, %al
cmpw %si, %di
jb 0x30c6f
jbe 0x30c70
xorl %eax, %eax
retq
movl %ecx, %esi
shrl $0x2, %esi
andl $0x3, %esi
movl %edx, %edi
shrl $0x2, %edi
andl $0x3, %edi
cmpw %di, %si
jb 0x30c6f
ja 0x30c6d
movl %ecx, %esi
shrl $0x4, %esi
andl $0x3, %esi
movl %edx, %edi
shrl $0x4, %edi
andl $0x3, %edi
cmpw %di, %si
jb 0x30c6f
ja 0x30c6d
movl %ecx, %esi
shrl $0x6, %esi
andl $0x3, %esi
movl %edx, %edi
shrl $0x6, %edi
andl $0x3, %edi
cmpw %di, %si
jb 0x30c6f
ja 0x30c6d
shrl $0x8, %ecx
andl $0x1, %ecx
btl $0x8, %edx
sbbw $0x0, %cx
setb %al
retq
nop
|
_ZNKSt4lessIN5ftxui12_GLOBAL__N_112TileEncodingEEclERKS2_S5_:
movzx ecx, word ptr [rdi]
mov edi, ecx
and edi, 3
movzx edx, word ptr [rsi]
mov esi, edx
and esi, 3
mov al, 1
cmp di, si
jb short locret_30C6F
jbe short loc_30C70
loc_30C6D:
xor eax, eax
locret_30C6F:
retn
loc_30C70:
mov esi, ecx
shr esi, 2
and esi, 3
mov edi, edx
shr edi, 2
and edi, 3
cmp si, di
jb short locret_30C6F
ja short loc_30C6D
mov esi, ecx
shr esi, 4
and esi, 3
mov edi, edx
shr edi, 4
and edi, 3
cmp si, di
jb short locret_30C6F
ja short loc_30C6D
mov esi, ecx
shr esi, 6
and esi, 3
mov edi, edx
shr edi, 6
and edi, 3
cmp si, di
jb short locret_30C6F
ja short loc_30C6D
shr ecx, 8
and ecx, 1
bt edx, 8
sbb cx, 0
setb al
retn
|
bool std::less<ftxui::`anonymous namespace'::TileEncoding>::operator()(_WORD *a1, _WORD *a2)
{
unsigned int v2; // ecx
unsigned __int16 v3; // di
unsigned int v4; // edx
unsigned __int16 v5; // si
bool result; // al
unsigned __int16 v7; // si
unsigned __int16 v8; // di
v2 = (unsigned __int16)*a1;
v3 = *a1 & 3;
v4 = (unsigned __int16)*a2;
v5 = *a2 & 3;
result = 1;
if ( v3 >= v5 )
{
if ( v3 > v5 )
return 0;
if ( (unsigned __int16)((v2 >> 2) & 3) >= (unsigned __int16)((v4 >> 2) & 3) )
{
if ( (unsigned __int16)((v2 >> 2) & 3) > (unsigned __int16)((v4 >> 2) & 3) )
return 0;
if ( (unsigned __int16)((v2 >> 4) & 3) >= (unsigned __int16)((v4 >> 4) & 3) )
{
if ( (unsigned __int16)((v2 >> 4) & 3) > (unsigned __int16)((v4 >> 4) & 3) )
return 0;
v7 = (unsigned __int8)v2 >> 6;
v8 = (unsigned __int8)v4 >> 6;
if ( v7 >= v8 )
{
if ( v7 <= v8 )
return (unsigned __int16)((v2 >> 8) & 1) < (unsigned __int8)((v4 & 0x100) != 0);
return 0;
}
}
}
}
return result;
}
|
operator():
MOVZX ECX,word ptr [RDI]
MOV EDI,ECX
AND EDI,0x3
MOVZX EDX,word ptr [RSI]
MOV ESI,EDX
AND ESI,0x3
MOV AL,0x1
CMP DI,SI
JC 0x00130c6f
JBE 0x00130c70
LAB_00130c6d:
XOR EAX,EAX
LAB_00130c6f:
RET
LAB_00130c70:
MOV ESI,ECX
SHR ESI,0x2
AND ESI,0x3
MOV EDI,EDX
SHR EDI,0x2
AND EDI,0x3
CMP SI,DI
JC 0x00130c6f
JA 0x00130c6d
MOV ESI,ECX
SHR ESI,0x4
AND ESI,0x3
MOV EDI,EDX
SHR EDI,0x4
AND EDI,0x3
CMP SI,DI
JC 0x00130c6f
JA 0x00130c6d
MOV ESI,ECX
SHR ESI,0x6
AND ESI,0x3
MOV EDI,EDX
SHR EDI,0x6
AND EDI,0x3
CMP SI,DI
JC 0x00130c6f
JA 0x00130c6d
SHR ECX,0x8
AND ECX,0x1
BT EDX,0x8
SBB CX,0x0
SETC AL
RET
|
/* std::less<ftxui::(anonymous namespace)::TileEncoding>::TEMPNAMEPLACEHOLDERVALUE(ftxui::(anonymous
namespace)::TileEncoding const&, ftxui::(anonymous namespace)::TileEncoding const&) const */
bool std::less<ftxui::(anonymous_namespace)::TileEncoding>::operator()
(TileEncoding *param_1,TileEncoding *param_2)
{
ushort uVar1;
ushort uVar2;
bool bVar3;
ushort uVar4;
ushort uVar5;
uVar1 = *(ushort *)param_1;
uVar2 = *(ushort *)param_2;
bVar3 = true;
if ((uVar2 & 3) <= (uVar1 & 3)) {
if ((uVar1 & 3) <= (uVar2 & 3)) {
uVar4 = uVar1 >> 2 & 3;
uVar5 = uVar2 >> 2 & 3;
if (uVar4 < uVar5) {
return true;
}
if (uVar4 <= uVar5) {
uVar4 = uVar1 >> 4 & 3;
uVar5 = uVar2 >> 4 & 3;
if (uVar4 < uVar5) {
return true;
}
if (uVar4 <= uVar5) {
uVar4 = uVar1 >> 6 & 3;
uVar5 = uVar2 >> 6 & 3;
if (uVar4 < uVar5) {
return true;
}
if (uVar4 <= uVar5) {
return (uVar1 >> 8 & 1) < (ushort)((uVar2 >> 8 & 1) != 0);
}
}
}
}
bVar3 = false;
}
return bVar3;
}
|
|
9,958 |
main
|
tinyCoroLab/examples/buffer_channel.cpp
|
int main(int argc, char const* argv[])
{
/* code */
scheduler::init();
number = 2;
submit_to_scheduler(producer(0));
submit_to_scheduler(producer(1));
submit_to_scheduler(consumer(2));
submit_to_scheduler(consumer(3));
scheduler::loop();
return 0;
}
|
O0
|
cpp
|
main:
subq $0x38, %rsp
movl $0x0, 0x34(%rsp)
movl %edi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
callq 0x9410
movl %eax, %eax
movl %eax, %edi
callq 0xe420
leaq 0x9bea6(%rip), %rdi # 0xa63c0
movl $0x2, %esi
callq 0xe450
leaq 0x20(%rsp), %rdi
xorl %esi, %esi
callq 0x9730
leaq 0x20(%rsp), %rdi
callq 0xe4f0
leaq 0x20(%rsp), %rdi
callq 0xe500
leaq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x9730
leaq 0x18(%rsp), %rdi
callq 0xe4f0
leaq 0x18(%rsp), %rdi
callq 0xe500
leaq 0x10(%rsp), %rdi
movl $0x2, %esi
callq 0x9ea0
leaq 0x10(%rsp), %rdi
callq 0xe4f0
leaq 0x10(%rsp), %rdi
callq 0xe500
leaq 0x8(%rsp), %rdi
movl $0x3, %esi
callq 0x9ea0
leaq 0x8(%rsp), %rdi
callq 0xe4f0
leaq 0x8(%rsp), %rdi
callq 0xe500
callq 0xe560
xorl %eax, %eax
addq $0x38, %rsp
retq
nopl (%rax)
|
main:
sub rsp, 38h
mov [rsp+38h+var_4], 0
mov [rsp+38h+var_8], edi
mov [rsp+38h+var_10], rsi
call __ZNSt6thread20hardware_concurrencyEv; std::thread::hardware_concurrency(void)
mov eax, eax
mov edi, eax; this
call _ZN4coro9scheduler4initEm; coro::scheduler::init(ulong)
lea rdi, number
mov esi, 2
call _ZNSt13__atomic_baseIiEaSEi; std::__atomic_base<int>::operator=(int)
lea rdi, [rsp+38h+var_18]; int
xor esi, esi
call _Z8produceri; producer(int)
lea rdi, [rsp+38h+var_18]
call _ZN4coro19submit_to_schedulerEONS_4taskIvEE; coro::submit_to_scheduler(coro::task<void> &&)
lea rdi, [rsp+38h+var_18]
call _ZN4coro4taskIvED2Ev; coro::task<void>::~task()
lea rdi, [rsp+38h+var_20]; int
mov esi, 1
call _Z8produceri; producer(int)
lea rdi, [rsp+38h+var_20]
call _ZN4coro19submit_to_schedulerEONS_4taskIvEE; coro::submit_to_scheduler(coro::task<void> &&)
lea rdi, [rsp+38h+var_20]
call _ZN4coro4taskIvED2Ev; coro::task<void>::~task()
lea rdi, [rsp+38h+var_28]; int
mov esi, 2
call _Z8consumeri; consumer(int)
lea rdi, [rsp+38h+var_28]
call _ZN4coro19submit_to_schedulerEONS_4taskIvEE; coro::submit_to_scheduler(coro::task<void> &&)
lea rdi, [rsp+38h+var_28]
call _ZN4coro4taskIvED2Ev; coro::task<void>::~task()
lea rdi, [rsp+38h+var_30]; int
mov esi, 3
call _Z8consumeri; consumer(int)
lea rdi, [rsp+38h+var_30]
call _ZN4coro19submit_to_schedulerEONS_4taskIvEE; coro::submit_to_scheduler(coro::task<void> &&)
lea rdi, [rsp+38h+var_30]; this
call _ZN4coro4taskIvED2Ev; coro::task<void>::~task()
call _ZN4coro9scheduler4loopEv; coro::scheduler::loop(void)
xor eax, eax
add rsp, 38h
retn
|
// local variable allocation has failed, the output may be wrong!
int main(int argc, const char **argv, const char **envp)
{
unsigned int v3; // eax
int v5; // [rsp+8h] [rbp-30h] BYREF
int v6; // [rsp+10h] [rbp-28h] BYREF
int v7; // [rsp+18h] [rbp-20h] BYREF
int v8; // [rsp+20h] [rbp-18h] BYREF
const char **v9; // [rsp+28h] [rbp-10h]
int v10; // [rsp+30h] [rbp-8h]
int v11; // [rsp+34h] [rbp-4h]
v11 = 0;
v10 = argc;
v9 = argv;
v3 = std::thread::hardware_concurrency(*(std::thread **)&argc);
coro::scheduler::init((coro::scheduler *)v3, (unsigned long long)argv);
std::__atomic_base<int>::operator=(&number, 2LL);
producer((long long)&v8, 0LL);
coro::submit_to_scheduler(&v8);
coro::task<void>::~task(&v8);
producer((long long)&v7, 1LL);
coro::submit_to_scheduler(&v7);
coro::task<void>::~task(&v7);
consumer((long long)&v6, 2LL);
coro::submit_to_scheduler(&v6);
coro::task<void>::~task(&v6);
consumer((long long)&v5, 3LL);
coro::submit_to_scheduler(&v5);
coro::task<void>::~task(&v5);
coro::scheduler::loop((coro::scheduler *)&v5);
return 0;
}
|
main:
SUB RSP,0x38
MOV dword ptr [RSP + 0x34],0x0
MOV dword ptr [RSP + 0x30],EDI
MOV qword ptr [RSP + 0x28],RSI
CALL 0x00109410
MOV EAX,EAX
MOV EDI,EAX
CALL 0x0010e420
LEA RDI,[0x1a63c0]
MOV ESI,0x2
CALL 0x0010e450
LEA RDI,[RSP + 0x20]
XOR ESI,ESI
CALL 0x00109730
LEA RDI,[RSP + 0x20]
CALL 0x0010e4f0
LEA RDI,[RSP + 0x20]
CALL 0x0010e500
LEA RDI,[RSP + 0x18]
MOV ESI,0x1
CALL 0x00109730
LEA RDI,[RSP + 0x18]
CALL 0x0010e4f0
LEA RDI,[RSP + 0x18]
CALL 0x0010e500
LEA RDI,[RSP + 0x10]
MOV ESI,0x2
CALL 0x00109ea0
LEA RDI,[RSP + 0x10]
CALL 0x0010e4f0
LEA RDI,[RSP + 0x10]
CALL 0x0010e500
LEA RDI,[RSP + 0x8]
MOV ESI,0x3
CALL 0x00109ea0
LEA RDI,[RSP + 0x8]
CALL 0x0010e4f0
LEA RDI,[RSP + 0x8]
CALL 0x0010e500
CALL 0x0010e560
XOR EAX,EAX
ADD RSP,0x38
RET
|
int8 main(int4 param_1,int8 param_2)
{
uint uVar1;
task local_30 [8];
task local_28 [8];
task local_20 [8];
task local_18 [8];
int8 local_10;
int4 local_8;
int4 local_4;
local_4 = 0;
local_10 = param_2;
local_8 = param_1;
uVar1 = std::thread::hardware_concurrency();
coro::scheduler::init((ulong)uVar1);
std::__atomic_base<int>::operator=((__atomic_base<int> *)&number,2);
producer((int)local_18);
coro::submit_to_scheduler(local_18);
coro::task<void>::~task((task<void> *)local_18);
producer((int)local_20);
coro::submit_to_scheduler(local_20);
coro::task<void>::~task((task<void> *)local_20);
consumer((int)local_28);
coro::submit_to_scheduler(local_28);
coro::task<void>::~task((task<void> *)local_28);
consumer((int)local_30);
coro::submit_to_scheduler(local_30);
coro::task<void>::~task((task<void> *)local_30);
coro::scheduler::loop();
return 0;
}
|
|
9,959 |
lre_byte_swap
|
bluesky950520[P]quickjs/libregexp.c
|
void lre_byte_swap(uint8_t *buf, size_t len, BOOL is_byte_swapped)
{
uint8_t *p, *pe;
uint32_t n, r, nw;
p = buf;
if (len < RE_HEADER_LEN)
abort();
// format is:
// <header>
// <bytecode>
// <capture group name 1>
// <capture group name 2>
// etc.
inplace_bswap16(&p[RE_HEADER_FLAGS]);
n = get_u32(&p[RE_HEADER_BYTECODE_LEN]);
inplace_bswap32(&p[RE_HEADER_BYTECODE_LEN]);
if (is_byte_swapped)
n = bswap32(n);
if (n > len - RE_HEADER_LEN)
abort();
p = &buf[RE_HEADER_LEN];
pe = &p[n];
while (p < pe) {
n = reopcode_info[*p].size;
switch (n) {
case 1:
case 2:
break;
case 3:
switch (*p) {
case REOP_save_reset: // has two 8 bit arguments
break;
case REOP_range32: // variable length
nw = get_u16(&p[1]); // number of pairs of uint32_t
if (is_byte_swapped)
n = bswap16(n);
for (r = 3 + 8 * nw; n < r; n += 4)
inplace_bswap32(&p[n]);
goto doswap16;
case REOP_range: // variable length
nw = get_u16(&p[1]); // number of pairs of uint16_t
if (is_byte_swapped)
n = bswap16(n);
for (r = 3 + 4 * nw; n < r; n += 2)
inplace_bswap16(&p[n]);
goto doswap16;
default:
doswap16:
inplace_bswap16(&p[1]);
break;
}
break;
case 5:
inplace_bswap32(&p[1]);
break;
case 17:
assert(*p == REOP_simple_greedy_quant);
inplace_bswap32(&p[1]);
inplace_bswap32(&p[5]);
inplace_bswap32(&p[9]);
inplace_bswap32(&p[13]);
break;
default:
abort();
}
p = &p[n];
}
}
|
O1
|
c
|
lre_byte_swap:
pushq %rax
cmpq $0x7, %rsi
jbe 0x95ea8
rolw $0x8, (%rdi)
movl 0x4(%rdi), %ecx
movl %ecx, %eax
bswapl %eax
movl %eax, 0x4(%rdi)
testl %edx, %edx
cmovel %ecx, %eax
addq $-0x8, %rsi
cmpq %rax, %rsi
jb 0x95ea8
testq %rax, %rax
je 0x95ea6
addq %rdi, %rax
addq $0x8, %rax
addq $0x8, %rdi
testl %edx, %edx
movl $0x3, %edx
movl $0x300, %ecx # imm = 0x300
cmovel %edx, %ecx
leaq 0xd60b(%rip), %rdx # 0xa33b0
pxor %xmm0, %xmm0
movzbl (%rdi), %r8d
movzbl (%r8,%rdx), %esi
cmpl $0x4, %esi
jg 0x95e21
leal -0x1(%rsi), %r9d
cmpl $0x2, %r9d
jb 0x95e98
cmpl $0x3, %esi
jne 0x95ea8
movl $0x3, %esi
cmpl $0xe, %r8d
je 0x95e98
cmpl $0x16, %r8d
je 0x95e6f
cmpl $0x17, %r8d
jne 0x95e93
movzwl 0x1(%rdi), %esi
leaq 0x3(,%rsi,8), %r8
movl %ecx, %esi
cmpl %r8d, %ecx
jae 0x95e93
movq %rcx, %rsi
movl (%rdi,%rsi), %r9d
bswapl %r9d
movl %r9d, (%rdi,%rsi)
addq $0x4, %rsi
cmpq %r8, %rsi
jb 0x95e0b
jmp 0x95e93
cmpl $0x5, %esi
je 0x95e60
cmpl $0x11, %esi
jne 0x95ea8
movdqu 0x1(%rdi), %xmm1
movdqa %xmm1, %xmm2
punpckhbw %xmm0, %xmm2 # xmm2 = xmm2[8],xmm0[8],xmm2[9],xmm0[9],xmm2[10],xmm0[10],xmm2[11],xmm0[11],xmm2[12],xmm0[12],xmm2[13],xmm0[13],xmm2[14],xmm0[14],xmm2[15],xmm0[15]
pshuflw $0x1b, %xmm2, %xmm2 # xmm2 = xmm2[3,2,1,0,4,5,6,7]
pshufhw $0x1b, %xmm2, %xmm2 # xmm2 = xmm2[0,1,2,3,7,6,5,4]
punpcklbw %xmm0, %xmm1 # xmm1 = xmm1[0],xmm0[0],xmm1[1],xmm0[1],xmm1[2],xmm0[2],xmm1[3],xmm0[3],xmm1[4],xmm0[4],xmm1[5],xmm0[5],xmm1[6],xmm0[6],xmm1[7],xmm0[7]
pshuflw $0x1b, %xmm1, %xmm1 # xmm1 = xmm1[3,2,1,0,4,5,6,7]
pshufhw $0x1b, %xmm1, %xmm1 # xmm1 = xmm1[0,1,2,3,7,6,5,4]
packuswb %xmm2, %xmm1
movdqu %xmm1, 0x1(%rdi)
movl $0x11, %esi
jmp 0x95e98
movl 0x1(%rdi), %esi
bswapl %esi
movl %esi, 0x1(%rdi)
movl $0x5, %esi
jmp 0x95e98
movzwl 0x1(%rdi), %esi
leaq 0x3(,%rsi,4), %r8
movl %ecx, %esi
cmpl %r8d, %ecx
jae 0x95e93
movq %rcx, %rsi
rolw $0x8, (%rdi,%rsi)
addq $0x2, %rsi
cmpq %r8, %rsi
jb 0x95e85
rolw $0x8, 0x1(%rdi)
movl %esi, %esi
addq %rsi, %rdi
cmpq %rax, %rdi
jb 0x95da9
popq %rax
retq
callq 0xe090
|
lre_byte_swap:
push rax
cmp rsi, 7
jbe loc_95EA8
rol word ptr [rdi], 8
mov ecx, [rdi+4]
mov eax, ecx
bswap eax
mov [rdi+4], eax
test edx, edx
cmovz eax, ecx
add rsi, 0FFFFFFFFFFFFFFF8h
cmp rsi, rax
jb loc_95EA8
test rax, rax
jz loc_95EA6
add rax, rdi
add rax, 8
add rdi, 8
test edx, edx
mov edx, 3
mov ecx, 300h
cmovz ecx, edx
lea rdx, reopcode_info
pxor xmm0, xmm0
loc_95DA9:
movzx r8d, byte ptr [rdi]
movzx esi, byte ptr [r8+rdx]
cmp esi, 4
jg short loc_95E21
lea r9d, [rsi-1]
cmp r9d, 2
jb loc_95E98
cmp esi, 3
jnz loc_95EA8
mov esi, 3
cmp r8d, 0Eh
jz loc_95E98
cmp r8d, 16h
jz loc_95E6F
cmp r8d, 17h
jnz loc_95E93
movzx esi, word ptr [rdi+1]
lea r8, ds:3[rsi*8]
mov esi, ecx
cmp ecx, r8d
jnb loc_95E93
mov rsi, rcx
loc_95E0B:
mov r9d, [rdi+rsi]
bswap r9d
mov [rdi+rsi], r9d
add rsi, 4
cmp rsi, r8
jb short loc_95E0B
jmp short loc_95E93
loc_95E21:
cmp esi, 5
jz short loc_95E60
cmp esi, 11h
jnz short loc_95EA8
movdqu xmm1, xmmword ptr [rdi+1]
movdqa xmm2, xmm1
punpckhbw xmm2, xmm0
pshuflw xmm2, xmm2, 1Bh
pshufhw xmm2, xmm2, 1Bh
punpcklbw xmm1, xmm0
pshuflw xmm1, xmm1, 1Bh
pshufhw xmm1, xmm1, 1Bh
packuswb xmm1, xmm2
movdqu xmmword ptr [rdi+1], xmm1
mov esi, 11h
jmp short loc_95E98
loc_95E60:
mov esi, [rdi+1]
bswap esi
mov [rdi+1], esi
mov esi, 5
jmp short loc_95E98
loc_95E6F:
movzx esi, word ptr [rdi+1]
lea r8, ds:3[rsi*4]
mov esi, ecx
cmp ecx, r8d
jnb short loc_95E93
mov rsi, rcx
loc_95E85:
rol word ptr [rdi+rsi], 8
add rsi, 2
cmp rsi, r8
jb short loc_95E85
loc_95E93:
rol word ptr [rdi+1], 8
loc_95E98:
mov esi, esi
add rdi, rsi
cmp rdi, rax
jb loc_95DA9
loc_95EA6:
pop rax
retn
loc_95EA8:
call _abort
|
void __spoils<rdx,rcx,r8,r9,r10,r11,xmm0,xmm4,xmm5> lre_byte_swap(
unsigned __int8 *a1,
unsigned long long a2,
int a3)
{
unsigned int v3; // ecx
unsigned long long v4; // rax
unsigned long long v5; // rax
long long v6; // rcx
long long v7; // r8
unsigned long long v8; // rsi
unsigned long long v9; // r8
__m128i v10; // xmm1
unsigned long long v11; // r8
if ( a2 <= 7 )
goto LABEL_28;
*(_WORD *)a1 = __ROL2__(*(_WORD *)a1, 8);
v3 = *((_DWORD *)a1 + 1);
v4 = _byteswap_ulong(v3);
*((_DWORD *)a1 + 1) = v4;
if ( !a3 )
v4 = v3;
if ( a2 - 8 < v4 )
LABEL_28:
abort((const char *)a1);
if ( v4 )
{
v5 = (unsigned long long)&a1[v4 + 8];
a1 += 8;
v6 = 768LL;
if ( !a3 )
v6 = 3LL;
do
{
v7 = *a1;
LODWORD(v8) = reopcode_info[v7];
if ( (unsigned int)v8 > 4 )
{
if ( (_DWORD)v8 == 5 )
{
*(_DWORD *)(a1 + 1) = _byteswap_ulong(*(_DWORD *)(a1 + 1));
LODWORD(v8) = 5;
}
else
{
if ( (_DWORD)v8 != 17 )
goto LABEL_28;
v10 = _mm_loadu_si128((const __m128i *)(a1 + 1));
*(__m128i *)(a1 + 1) = _mm_packus_epi16(
_mm_shufflehi_epi16(
_mm_shufflelo_epi16(_mm_unpacklo_epi8(v10, (__m128i)0LL), 27),
27),
_mm_shufflehi_epi16(
_mm_shufflelo_epi16(_mm_unpackhi_epi8(v10, (__m128i)0LL), 27),
27));
LODWORD(v8) = 17;
}
}
else if ( (unsigned int)(v8 - 1) >= 2 )
{
if ( (_DWORD)v8 != 3 )
goto LABEL_28;
LODWORD(v8) = 3;
if ( (_DWORD)v7 != 14 )
{
if ( (_DWORD)v7 == 22 )
{
v11 = 4LL * *(unsigned __int16 *)(a1 + 1) + 3;
LODWORD(v8) = v6;
if ( (unsigned int)v6 < (unsigned int)v11 )
{
v8 = v6;
do
{
*(_WORD *)&a1[v8] = __ROL2__(*(_WORD *)&a1[v8], 8);
v8 += 2LL;
}
while ( v8 < v11 );
}
}
else if ( (_DWORD)v7 == 23 )
{
v9 = 8LL * *(unsigned __int16 *)(a1 + 1) + 3;
LODWORD(v8) = v6;
if ( (unsigned int)v6 < (unsigned int)v9 )
{
v8 = v6;
do
{
*(_DWORD *)&a1[v8] = _byteswap_ulong(*(_DWORD *)&a1[v8]);
v8 += 4LL;
}
while ( v8 < v9 );
}
}
*(_WORD *)(a1 + 1) = __ROL2__(*(_WORD *)(a1 + 1), 8);
}
}
a1 += (unsigned int)v8;
}
while ( (unsigned long long)a1 < v5 );
}
}
| |||
9,960 |
lre_byte_swap
|
bluesky950520[P]quickjs/libregexp.c
|
void lre_byte_swap(uint8_t *buf, size_t len, BOOL is_byte_swapped)
{
uint8_t *p, *pe;
uint32_t n, r, nw;
p = buf;
if (len < RE_HEADER_LEN)
abort();
// format is:
// <header>
// <bytecode>
// <capture group name 1>
// <capture group name 2>
// etc.
inplace_bswap16(&p[RE_HEADER_FLAGS]);
n = get_u32(&p[RE_HEADER_BYTECODE_LEN]);
inplace_bswap32(&p[RE_HEADER_BYTECODE_LEN]);
if (is_byte_swapped)
n = bswap32(n);
if (n > len - RE_HEADER_LEN)
abort();
p = &buf[RE_HEADER_LEN];
pe = &p[n];
while (p < pe) {
n = reopcode_info[*p].size;
switch (n) {
case 1:
case 2:
break;
case 3:
switch (*p) {
case REOP_save_reset: // has two 8 bit arguments
break;
case REOP_range32: // variable length
nw = get_u16(&p[1]); // number of pairs of uint32_t
if (is_byte_swapped)
n = bswap16(n);
for (r = 3 + 8 * nw; n < r; n += 4)
inplace_bswap32(&p[n]);
goto doswap16;
case REOP_range: // variable length
nw = get_u16(&p[1]); // number of pairs of uint16_t
if (is_byte_swapped)
n = bswap16(n);
for (r = 3 + 4 * nw; n < r; n += 2)
inplace_bswap16(&p[n]);
goto doswap16;
default:
doswap16:
inplace_bswap16(&p[1]);
break;
}
break;
case 5:
inplace_bswap32(&p[1]);
break;
case 17:
assert(*p == REOP_simple_greedy_quant);
inplace_bswap32(&p[1]);
inplace_bswap32(&p[5]);
inplace_bswap32(&p[9]);
inplace_bswap32(&p[13]);
break;
default:
abort();
}
p = &p[n];
}
}
|
O2
|
c
|
lre_byte_swap:
pushq %rbx
cmpq $0x7, %rsi
jbe 0x7d188
rolw $0x8, (%rdi)
movl 0x4(%rdi), %eax
movl %eax, %ecx
bswapl %ecx
movl %ecx, 0x4(%rdi)
testl %edx, %edx
cmovel %eax, %ecx
addq $-0x8, %rsi
cmpq %rcx, %rsi
jb 0x7d188
leaq 0x8(%rdi), %rax
testl %edx, %edx
leaq 0x8(%rdi,%rcx), %rcx
pushq $0x3
popq %rsi
movl $0x300, %edx # imm = 0x300
cmoveq %rsi, %rdx
leaq 0xd26b(%rip), %rsi # 0x8a2f0
pxor %xmm0, %xmm0
pushq $0x11
popq %rdi
pushq $0x5
popq %r8
pushq $0x3
popq %r9
cmpq %rcx, %rax
jae 0x7d186
movzbl (%rax), %r11d
movzbl (%r11,%rsi), %r10d
leal -0x1(%r10), %ebx
cmpl $0x2, %ebx
jb 0x7d17b
cmpl $0x11, %r10d
je 0x7d112
cmpl $0x5, %r10d
je 0x7d145
cmpl $0x3, %r10d
jne 0x7d188
movl %r9d, %r10d
cmpl $0xe, %r11d
je 0x7d17b
cmpl $0x16, %r11d
je 0x7d155
movl %r9d, %r10d
cmpl $0x17, %r11d
jne 0x7d176
movzwl 0x1(%rax), %r10d
leaq 0x3(,%r10,8), %r11
movq %rdx, %r10
cmpq %r11, %r10
jae 0x7d176
movl (%rax,%r10), %ebx
bswapl %ebx
movl %ebx, (%rax,%r10)
addq $0x4, %r10
jmp 0x7d0fd
movdqu 0x1(%rax), %xmm1
movdqa %xmm1, %xmm2
punpckhbw %xmm0, %xmm2 # xmm2 = xmm2[8],xmm0[8],xmm2[9],xmm0[9],xmm2[10],xmm0[10],xmm2[11],xmm0[11],xmm2[12],xmm0[12],xmm2[13],xmm0[13],xmm2[14],xmm0[14],xmm2[15],xmm0[15]
pshuflw $0x1b, %xmm2, %xmm2 # xmm2 = xmm2[3,2,1,0,4,5,6,7]
pshufhw $0x1b, %xmm2, %xmm2 # xmm2 = xmm2[0,1,2,3,7,6,5,4]
punpcklbw %xmm0, %xmm1 # xmm1 = xmm1[0],xmm0[0],xmm1[1],xmm0[1],xmm1[2],xmm0[2],xmm1[3],xmm0[3],xmm1[4],xmm0[4],xmm1[5],xmm0[5],xmm1[6],xmm0[6],xmm1[7],xmm0[7]
pshuflw $0x1b, %xmm1, %xmm1 # xmm1 = xmm1[3,2,1,0,4,5,6,7]
pshufhw $0x1b, %xmm1, %xmm1 # xmm1 = xmm1[0,1,2,3,7,6,5,4]
packuswb %xmm2, %xmm1
movdqu %xmm1, 0x1(%rax)
movl %edi, %r10d
jmp 0x7d17b
movl 0x1(%rax), %r10d
bswapl %r10d
movl %r10d, 0x1(%rax)
movl %r8d, %r10d
jmp 0x7d17b
movzwl 0x1(%rax), %r10d
leaq 0x3(,%r10,4), %r11
movq %rdx, %r10
cmpq %r11, %r10
jae 0x7d176
rolw $0x8, (%rax,%r10)
addq $0x2, %r10
jmp 0x7d165
rolw $0x8, 0x1(%rax)
movl %r10d, %r10d
addq %r10, %rax
jmp 0x7d094
popq %rbx
retq
callq 0xe090
|
lre_byte_swap:
push rbx
cmp rsi, 7
jbe loc_7D188
rol word ptr [rdi], 8
mov eax, [rdi+4]
mov ecx, eax
bswap ecx
mov [rdi+4], ecx
test edx, edx
cmovz ecx, eax
add rsi, 0FFFFFFFFFFFFFFF8h
cmp rsi, rcx
jb loc_7D188
lea rax, [rdi+8]
test edx, edx
lea rcx, [rdi+rcx+8]
push 3
pop rsi
mov edx, 300h
cmovz rdx, rsi
lea rsi, reopcode_info
pxor xmm0, xmm0
push 11h
pop rdi
push 5
pop r8
push 3
pop r9
loc_7D094:
cmp rax, rcx
jnb loc_7D186
movzx r11d, byte ptr [rax]
movzx r10d, byte ptr [r11+rsi]
lea ebx, [r10-1]
cmp ebx, 2
jb loc_7D17B
cmp r10d, 11h
jz short loc_7D112
cmp r10d, 5
jz loc_7D145
cmp r10d, 3
jnz loc_7D188
mov r10d, r9d
cmp r11d, 0Eh
jz loc_7D17B
cmp r11d, 16h
jz short loc_7D155
mov r10d, r9d
cmp r11d, 17h
jnz loc_7D176
movzx r10d, word ptr [rax+1]
lea r11, ds:3[r10*8]
mov r10, rdx
loc_7D0FD:
cmp r10, r11
jnb short loc_7D176
mov ebx, [rax+r10]
bswap ebx
mov [rax+r10], ebx
add r10, 4
jmp short loc_7D0FD
loc_7D112:
movdqu xmm1, xmmword ptr [rax+1]
movdqa xmm2, xmm1
punpckhbw xmm2, xmm0
pshuflw xmm2, xmm2, 1Bh
pshufhw xmm2, xmm2, 1Bh
punpcklbw xmm1, xmm0
pshuflw xmm1, xmm1, 1Bh
pshufhw xmm1, xmm1, 1Bh
packuswb xmm1, xmm2
movdqu xmmword ptr [rax+1], xmm1
mov r10d, edi
jmp short loc_7D17B
loc_7D145:
mov r10d, [rax+1]
bswap r10d
mov [rax+1], r10d
mov r10d, r8d
jmp short loc_7D17B
loc_7D155:
movzx r10d, word ptr [rax+1]
lea r11, ds:3[r10*4]
mov r10, rdx
loc_7D165:
cmp r10, r11
jnb short loc_7D176
rol word ptr [rax+r10], 8
add r10, 2
jmp short loc_7D165
loc_7D176:
rol word ptr [rax+1], 8
loc_7D17B:
mov r10d, r10d
add rax, r10
jmp loc_7D094
loc_7D186:
pop rbx
retn
loc_7D188:
call _abort
|
unsigned __int8 * lre_byte_swap(char *a1, unsigned long long a2, int a3)
{
unsigned int v3; // eax
unsigned long long v4; // rcx
unsigned __int8 *result; // rax
bool v6; // zf
unsigned long long v7; // rcx
long long v8; // rdx
long long v9; // r11
unsigned long long i; // r10
unsigned long long v11; // r11
__m128i v12; // xmm1
unsigned long long v13; // r11
if ( a2 <= 7 )
goto LABEL_27;
*(_WORD *)a1 = __ROL2__(*(_WORD *)a1, 8);
v3 = *((_DWORD *)a1 + 1);
v4 = _byteswap_ulong(v3);
*((_DWORD *)a1 + 1) = v4;
if ( !a3 )
v4 = v3;
if ( a2 - 8 < v4 )
LABEL_27:
abort(a1);
result = (unsigned __int8 *)(a1 + 8);
v6 = a3 == 0;
v7 = (unsigned long long)&a1[v4 + 8];
v8 = 768LL;
if ( v6 )
v8 = 3LL;
a1 = (_BYTE *)(&word_10 + 1);
while ( (unsigned long long)result < v7 )
{
v9 = *result;
LODWORD(i) = reopcode_info[v9];
if ( (unsigned int)(i - 1) >= 2 )
{
switch ( (_DWORD)i )
{
case 0x11:
v12 = _mm_loadu_si128((const __m128i *)(result + 1));
*(__m128i *)(result + 1) = _mm_packus_epi16(
_mm_shufflehi_epi16(
_mm_shufflelo_epi16(_mm_unpacklo_epi8(v12, (__m128i)0LL), 27),
27),
_mm_shufflehi_epi16(
_mm_shufflelo_epi16(_mm_unpackhi_epi8(v12, (__m128i)0LL), 27),
27));
LODWORD(i) = 17;
break;
case 5:
*(_DWORD *)(result + 1) = _byteswap_ulong(*(_DWORD *)(result + 1));
LODWORD(i) = 5;
break;
case 3:
LODWORD(i) = 3;
if ( (_DWORD)v9 != 14 )
{
if ( (_DWORD)v9 == 22 )
{
v13 = 4LL * *(unsigned __int16 *)(result + 1) + 3;
for ( i = v8; i < v13; i += 2LL )
*(_WORD *)&result[i] = __ROL2__(*(_WORD *)&result[i], 8);
}
else
{
LODWORD(i) = 3;
if ( (_DWORD)v9 == 23 )
{
v11 = 8LL * *(unsigned __int16 *)(result + 1) + 3;
for ( i = v8; i < v11; i += 4LL )
*(_DWORD *)&result[i] = _byteswap_ulong(*(_DWORD *)&result[i]);
}
}
*(_WORD *)(result + 1) = __ROL2__(*(_WORD *)(result + 1), 8);
}
break;
default:
goto LABEL_27;
}
}
result += (unsigned int)i;
}
return result;
}
|
lre_byte_swap:
PUSH RBX
CMP RSI,0x7
JBE 0x0017d188
ROL word ptr [RDI],0x8
MOV EAX,dword ptr [RDI + 0x4]
MOV ECX,EAX
BSWAP ECX
MOV dword ptr [RDI + 0x4],ECX
TEST EDX,EDX
CMOVZ ECX,EAX
ADD RSI,-0x8
CMP RSI,RCX
JC 0x0017d188
LEA RAX,[RDI + 0x8]
TEST EDX,EDX
LEA RCX,[RDI + RCX*0x1 + 0x8]
PUSH 0x3
POP RSI
MOV EDX,0x300
CMOVZ RDX,RSI
LEA RSI,[0x18a2f0]
PXOR XMM0,XMM0
PUSH 0x11
POP RDI
PUSH 0x5
POP R8
PUSH 0x3
POP R9
LAB_0017d094:
CMP RAX,RCX
JNC 0x0017d186
MOVZX R11D,byte ptr [RAX]
MOVZX R10D,byte ptr [R11 + RSI*0x1]
LEA EBX,[R10 + -0x1]
CMP EBX,0x2
JC 0x0017d17b
CMP R10D,0x11
JZ 0x0017d112
CMP R10D,0x5
JZ 0x0017d145
CMP R10D,0x3
JNZ 0x0017d188
MOV R10D,R9D
CMP R11D,0xe
JZ 0x0017d17b
CMP R11D,0x16
JZ 0x0017d155
MOV R10D,R9D
CMP R11D,0x17
JNZ 0x0017d176
MOVZX R10D,word ptr [RAX + 0x1]
LEA R11,[0x3 + R10*0x8]
MOV R10,RDX
LAB_0017d0fd:
CMP R10,R11
JNC 0x0017d176
MOV EBX,dword ptr [RAX + R10*0x1]
BSWAP EBX
MOV dword ptr [RAX + R10*0x1],EBX
ADD R10,0x4
JMP 0x0017d0fd
LAB_0017d112:
MOVDQU XMM1,xmmword ptr [RAX + 0x1]
MOVDQA XMM2,XMM1
PUNPCKHBW XMM2,XMM0
PSHUFLW XMM2,XMM2,0x1b
PSHUFHW XMM2,XMM2,0x1b
PUNPCKLBW XMM1,XMM0
PSHUFLW XMM1,XMM1,0x1b
PSHUFHW XMM1,XMM1,0x1b
PACKUSWB XMM1,XMM2
MOVDQU xmmword ptr [RAX + 0x1],XMM1
MOV R10D,EDI
JMP 0x0017d17b
LAB_0017d145:
MOV R10D,dword ptr [RAX + 0x1]
BSWAP R10D
MOV dword ptr [RAX + 0x1],R10D
MOV R10D,R8D
JMP 0x0017d17b
LAB_0017d155:
MOVZX R10D,word ptr [RAX + 0x1]
LEA R11,[0x3 + R10*0x4]
MOV R10,RDX
LAB_0017d165:
CMP R10,R11
JNC 0x0017d176
ROL word ptr [RAX + R10*0x1],0x8
ADD R10,0x2
JMP 0x0017d165
LAB_0017d176:
ROL word ptr [RAX + 0x1],0x8
LAB_0017d17b:
MOV R10D,R10D
ADD RAX,R10
JMP 0x0017d094
LAB_0017d186:
POP RBX
RET
LAB_0017d188:
CALL 0x0010e090
|
void lre_byte_swap(ushort *param_1,ulong param_2,int param_3)
{
ushort *puVar1;
byte bVar2;
byte bVar3;
ushort uVar4;
short sVar5;
short sVar6;
short sVar7;
short sVar8;
short sVar9;
short sVar10;
short sVar11;
short sVar12;
short sVar13;
short sVar14;
short sVar15;
short sVar16;
short sVar17;
short sVar18;
short sVar19;
short sVar20;
int1 auVar21 [15];
int1 auVar22 [15];
int1 auVar23 [15];
int1 auVar24 [15];
int1 auVar25 [15];
int1 auVar26 [15];
int1 auVar27 [15];
int1 auVar28 [15];
int1 auVar29 [15];
int1 auVar30 [15];
ushort *puVar31;
uint uVar32;
ulong uVar33;
uint uVar34;
ulong uVar35;
int1 auVar36 [16];
int1 auVar37 [16];
if (7 < param_2) {
*param_1 = *param_1 << 8 | *param_1 >> 8;
uVar34 = *(uint *)(param_1 + 2);
uVar32 = uVar34 >> 0x18 | (uVar34 & 0xff0000) >> 8 | (uVar34 & 0xff00) << 8 | uVar34 << 0x18;
*(uint *)(param_1 + 2) = uVar32;
if (param_3 == 0) {
uVar32 = uVar34;
}
if ((ulong)uVar32 <= param_2 - 8) {
puVar31 = param_1 + 4;
uVar33 = 0x300;
if (param_3 == 0) {
uVar33 = 3;
}
do {
if ((ushort *)((long)param_1 + (ulong)uVar32 + 8) <= puVar31) {
return;
}
bVar2 = (byte)*puVar31;
bVar3 = reopcode_info[bVar2];
uVar34 = (uint)bVar3;
if (1 < bVar3 - 1) {
if (bVar3 == 0x11) {
auVar36 = *(int1 (*) [16])((long)puVar31 + 1);
auVar37[1] = 0;
auVar37[0] = auVar36[8];
auVar37[2] = auVar36[9];
auVar37[3] = 0;
auVar37[4] = auVar36[10];
auVar37[5] = 0;
auVar37[6] = auVar36[0xb];
auVar37[7] = 0;
auVar37[8] = auVar36[0xc];
auVar37[9] = 0;
auVar37[10] = auVar36[0xd];
auVar37[0xb] = 0;
auVar37[0xc] = auVar36[0xe];
auVar37[0xd] = 0;
auVar37[0xe] = auVar36[0xf];
auVar37[0xf] = 0;
auVar37 = pshuflw(auVar37,auVar37,0x1b);
auVar37 = pshufhw(auVar37,auVar37,0x1b);
auVar21[0xd] = 0;
auVar21._0_13_ = auVar36._0_13_;
auVar21[0xe] = auVar36[7];
auVar22[0xc] = auVar36[6];
auVar22._0_12_ = auVar36._0_12_;
auVar22._13_2_ = auVar21._13_2_;
auVar23[0xb] = 0;
auVar23._0_11_ = auVar36._0_11_;
auVar23._12_3_ = auVar22._12_3_;
auVar24[10] = auVar36[5];
auVar24._0_10_ = auVar36._0_10_;
auVar24._11_4_ = auVar23._11_4_;
auVar25[9] = 0;
auVar25._0_9_ = auVar36._0_9_;
auVar25._10_5_ = auVar24._10_5_;
auVar26[8] = auVar36[4];
auVar26._0_8_ = auVar36._0_8_;
auVar26._9_6_ = auVar25._9_6_;
auVar28._7_8_ = 0;
auVar28._0_7_ = auVar26._8_7_;
auVar29._1_8_ = SUB158(auVar28 << 0x40,7);
auVar29[0] = auVar36[3];
auVar29._9_6_ = 0;
auVar30._1_10_ = SUB1510(auVar29 << 0x30,5);
auVar30[0] = auVar36[2];
auVar30._11_4_ = 0;
auVar27[2] = auVar36[1];
auVar27._0_2_ = auVar36._0_2_;
auVar27._3_12_ = SUB1512(auVar30 << 0x20,3);
auVar36._0_2_ = auVar36._0_2_ & 0xff;
auVar36._2_13_ = auVar27._2_13_;
auVar36[0xf] = 0;
auVar36 = pshuflw(auVar36,auVar36,0x1b);
auVar36 = pshufhw(auVar36,auVar36,0x1b);
sVar5 = auVar36._0_2_;
sVar6 = auVar36._2_2_;
sVar7 = auVar36._4_2_;
sVar8 = auVar36._6_2_;
sVar9 = auVar36._8_2_;
sVar10 = auVar36._10_2_;
sVar11 = auVar36._12_2_;
sVar12 = auVar36._14_2_;
sVar13 = auVar37._0_2_;
sVar14 = auVar37._2_2_;
sVar15 = auVar37._4_2_;
sVar16 = auVar37._6_2_;
sVar17 = auVar37._8_2_;
sVar18 = auVar37._10_2_;
sVar19 = auVar37._12_2_;
sVar20 = auVar37._14_2_;
*(char *)((long)puVar31 + 1) =
(0 < sVar5) * (sVar5 < 0x100) * auVar36[0] - (0xff < sVar5);
*(char *)(puVar31 + 1) = (0 < sVar6) * (sVar6 < 0x100) * auVar36[2] - (0xff < sVar6);
*(char *)((long)puVar31 + 3) =
(0 < sVar7) * (sVar7 < 0x100) * auVar36[4] - (0xff < sVar7);
*(char *)(puVar31 + 2) = (0 < sVar8) * (sVar8 < 0x100) * auVar36[6] - (0xff < sVar8);
*(char *)((long)puVar31 + 5) =
(0 < sVar9) * (sVar9 < 0x100) * auVar36[8] - (0xff < sVar9);
*(char *)(puVar31 + 3) = (0 < sVar10) * (sVar10 < 0x100) * auVar36[10] - (0xff < sVar10)
;
*(char *)((long)puVar31 + 7) =
(0 < sVar11) * (sVar11 < 0x100) * auVar36[0xc] - (0xff < sVar11);
*(char *)(puVar31 + 4) =
(0 < sVar12) * (sVar12 < 0x100) * auVar36[0xe] - (0xff < sVar12);
*(char *)((long)puVar31 + 9) =
(0 < sVar13) * (sVar13 < 0x100) * auVar37[0] - (0xff < sVar13);
*(char *)(puVar31 + 5) = (0 < sVar14) * (sVar14 < 0x100) * auVar37[2] - (0xff < sVar14);
*(char *)((long)puVar31 + 0xb) =
(0 < sVar15) * (sVar15 < 0x100) * auVar37[4] - (0xff < sVar15);
*(char *)(puVar31 + 6) = (0 < sVar16) * (sVar16 < 0x100) * auVar37[6] - (0xff < sVar16);
*(char *)((long)puVar31 + 0xd) =
(0 < sVar17) * (sVar17 < 0x100) * auVar37[8] - (0xff < sVar17);
*(char *)(puVar31 + 7) = (0 < sVar18) * (sVar18 < 0x100) * auVar37[10] - (0xff < sVar18)
;
*(char *)((long)puVar31 + 0xf) =
(0 < sVar19) * (sVar19 < 0x100) * auVar37[0xc] - (0xff < sVar19);
*(char *)(puVar31 + 8) =
(0 < sVar20) * (sVar20 < 0x100) * auVar37[0xe] - (0xff < sVar20);
uVar34 = 0x11;
}
else if (bVar3 == 5) {
uVar34 = *(uint *)((long)puVar31 + 1);
*(uint *)((long)puVar31 + 1) =
uVar34 >> 0x18 | (uVar34 & 0xff0000) >> 8 | (uVar34 & 0xff00) << 8 | uVar34 << 0x18
;
uVar34 = 5;
}
else {
if (bVar3 != 3) break;
uVar34 = 3;
if (bVar2 != 0xe) {
if (bVar2 == 0x16) {
uVar4 = *(ushort *)((long)puVar31 + 1);
for (uVar35 = uVar33; uVar35 < (ulong)uVar4 * 4 + 3; uVar35 = uVar35 + 2) {
puVar1 = (ushort *)((long)puVar31 + uVar35);
*puVar1 = *puVar1 << 8 | *puVar1 >> 8;
}
}
else {
uVar35 = 3;
if (bVar2 == 0x17) {
uVar4 = *(ushort *)((long)puVar31 + 1);
for (uVar35 = uVar33; uVar35 < (ulong)uVar4 * 8 + 3; uVar35 = uVar35 + 4) {
uVar34 = *(uint *)((long)puVar31 + uVar35);
*(uint *)((long)puVar31 + uVar35) =
uVar34 >> 0x18 | (uVar34 & 0xff0000) >> 8 | (uVar34 & 0xff00) << 8 |
uVar34 << 0x18;
}
}
}
uVar34 = (uint)uVar35;
puVar1 = (ushort *)((long)puVar31 + 1);
*puVar1 = *puVar1 << 8 | *puVar1 >> 8;
}
}
}
puVar31 = (ushort *)((long)puVar31 + (ulong)uVar34);
} while( true );
}
}
/* WARNING: Subroutine does not return */
abort();
}
|
|
9,961 |
LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(int, double*, double*)
|
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp
|
int
lefwLayerAntennaDiffAreaRatioPwl(int numPwls,
double *diffusions,
double *ratios)
{
int i;
lefw54Num = LEFW_ANTENNADIFFAREARATIOPWL;
if (!lefwFile)
return LEFW_UNINITIALIZED;
if (lefwState != LEFW_LAYERROUTING_START && lefwState != LEFW_LAYERROUTING
&& lefwState != LEFW_LAYER_START && lefwState != LEFW_LAYER)
return LEFW_BAD_ORDER;
// only routing or cut calls this func
if (!lefwIsRouting && !lefwIsCut)
return LEFW_BAD_DATA;
if (versionNum < 5.4)
return LEFW_WRONG_VERSION;
if (lefwWriteEncrypt) {
encPrint(lefwFile, (char*) " ANTENNADIFFAREARATIO PWL ( ");
for (i = 0; i < numPwls; i++)
encPrint(lefwFile, (char*) "( %.11g %.11g ) ", *diffusions++, *ratios++);
encPrint(lefwFile, (char*) ") ;\n");
} else {
fprintf(lefwFile, " ANTENNADIFFAREARATIO PWL ( ");
for (i = 0; i < numPwls; i++)
fprintf(lefwFile, "( %.11g %.11g ) ", *diffusions++, *ratios++);
fprintf(lefwFile, ") ;\n");
}
lefwLines++;
return LEFW_OK;
}
|
O0
|
cpp
|
LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(int, double*, double*):
subq $0x28, %rsp
movl %edi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq %rdx, 0x10(%rsp)
movl $0x67, 0x1e140(%rip) # 0x32d4c
leaq 0x1e1ed(%rip), %rax # 0x32e00
cmpq $0x0, (%rax)
jne 0x14c26
movl $0x1, 0x24(%rsp)
jmp 0x14df8
leaq 0x1e423(%rip), %rax # 0x33050
cmpl $0x7, (%rax)
je 0x14c63
leaq 0x1e417(%rip), %rax # 0x33050
cmpl $0x1f, (%rax)
je 0x14c63
leaq 0x1e40b(%rip), %rax # 0x33050
cmpl $0x6, (%rax)
je 0x14c63
leaq 0x1e3ff(%rip), %rax # 0x33050
cmpl $0x1c, (%rax)
je 0x14c63
movl $0x2, 0x24(%rsp)
jmp 0x14df8
leaq 0x1e45a(%rip), %rax # 0x330c4
cmpl $0x0, (%rax)
jne 0x14c88
leaq 0x1e40e(%rip), %rax # 0x33084
cmpl $0x0, (%rax)
jne 0x14c88
movl $0x3, 0x24(%rsp)
jmp 0x14df8
movsd 0x14570(%rip), %xmm0 # 0x29200
ucomisd 0x1e0a8(%rip), %xmm0 # 0x32d40
jbe 0x14ca7
movl $0x5, 0x24(%rsp)
jmp 0x14df8
cmpl $0x0, 0x1e43e(%rip) # 0x330ec
je 0x14d4a
leaq 0x1e145(%rip), %rax # 0x32e00
movq (%rax), %rdi
leaq 0x15df4(%rip), %rsi # 0x2aab9
movb $0x0, %al
callq 0x289b0
movl $0x0, 0xc(%rsp)
movl 0xc(%rsp), %eax
cmpl 0x20(%rsp), %eax
jge 0x14d2d
leaq 0x1e11b(%rip), %rax # 0x32e00
movq (%rax), %rdi
movq 0x18(%rsp), %rax
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, 0x18(%rsp)
movsd (%rax), %xmm0
movq 0x10(%rsp), %rax
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, 0x10(%rsp)
movsd (%rax), %xmm1
leaq 0x15dbf(%rip), %rsi # 0x2aad8
movb $0x2, %al
callq 0x289b0
movl 0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xc(%rsp)
jmp 0x14cd4
leaq 0x1e0cc(%rip), %rax # 0x32e00
movq (%rax), %rdi
leaq 0x15dab(%rip), %rsi # 0x2aae9
movb $0x0, %al
callq 0x289b0
jmp 0x14ddb
leaq 0x1e0af(%rip), %rax # 0x32e00
movq (%rax), %rdi
leaq 0x15d5e(%rip), %rsi # 0x2aab9
movb $0x0, %al
callq 0x1100
movl $0x0, 0xc(%rsp)
movl 0xc(%rsp), %eax
cmpl 0x20(%rsp), %eax
jge 0x14dc3
leaq 0x1e085(%rip), %rax # 0x32e00
movq (%rax), %rdi
movq 0x18(%rsp), %rax
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, 0x18(%rsp)
movsd (%rax), %xmm0
movq 0x10(%rsp), %rax
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, 0x10(%rsp)
movsd (%rax), %xmm1
leaq 0x15d29(%rip), %rsi # 0x2aad8
movb $0x2, %al
callq 0x1100
movl 0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xc(%rsp)
jmp 0x14d6a
leaq 0x1e036(%rip), %rax # 0x32e00
movq (%rax), %rdi
leaq 0x15d15(%rip), %rsi # 0x2aae9
movb $0x0, %al
callq 0x1100
leaq 0x1e26a(%rip), %rax # 0x3304c
movl (%rax), %ecx
addl $0x1, %ecx
leaq 0x1e25e(%rip), %rax # 0x3304c
movl %ecx, (%rax)
movl $0x0, 0x24(%rsp)
movl 0x24(%rsp), %eax
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
|
_ZN12LefDefParser32lefwLayerAntennaDiffAreaRatioPwlEiPdS0_:
sub rsp, 28h
mov [rsp+28h+var_8], edi
mov [rsp+28h+var_10], rsi
mov [rsp+28h+var_18], rdx
mov cs:_ZN12LefDefParserL9lefw54NumE, 67h ; 'g'; LefDefParser::lefw54Num
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
cmp qword ptr [rax], 0
jnz short loc_14C26
mov [rsp+28h+var_4], 1
jmp loc_14DF8
loc_14C26:
lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState
cmp dword ptr [rax], 7
jz short loc_14C63
lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState
cmp dword ptr [rax], 1Fh
jz short loc_14C63
lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState
cmp dword ptr [rax], 6
jz short loc_14C63
lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState
cmp dword ptr [rax], 1Ch
jz short loc_14C63
mov [rsp+28h+var_4], 2
jmp loc_14DF8
loc_14C63:
lea rax, _ZN12LefDefParser13lefwIsRoutingE; LefDefParser::lefwIsRouting
cmp dword ptr [rax], 0
jnz short loc_14C88
lea rax, _ZN12LefDefParser9lefwIsCutE; LefDefParser::lefwIsCut
cmp dword ptr [rax], 0
jnz short loc_14C88
mov [rsp+28h+var_4], 3
jmp loc_14DF8
loc_14C88:
movsd xmm0, cs:dbl_29200
ucomisd xmm0, cs:_ZN12LefDefParserL10versionNumE; LefDefParser::versionNum
jbe short loc_14CA7
mov [rsp+28h+var_4], 5
jmp loc_14DF8
loc_14CA7:
cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 0; LefDefParser::lefwWriteEncrypt
jz loc_14D4A
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
lea rsi, aAntennadiffare_0; " ANTENNADIFFAREARATIO PWL ( "
mov al, 0
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
mov [rsp+28h+var_1C], 0
loc_14CD4:
mov eax, [rsp+28h+var_1C]
cmp eax, [rsp+28h+var_8]
jge short loc_14D2D
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
mov rax, [rsp+28h+var_10]
mov rcx, rax
add rcx, 8
mov [rsp+28h+var_10], rcx
movsd xmm0, qword ptr [rax]
mov rax, [rsp+28h+var_18]
mov rcx, rax
add rcx, 8
mov [rsp+28h+var_18], rcx
movsd xmm1, qword ptr [rax]
lea rsi, a11g11g_0; "( %.11g %.11g ) "
mov al, 2
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
mov eax, [rsp+28h+var_1C]
add eax, 1
mov [rsp+28h+var_1C], eax
jmp short loc_14CD4
loc_14D2D:
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
lea rsi, asc_2AAE9; ") ;\n"
mov al, 0
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
jmp loc_14DDB
loc_14D4A:
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
lea rsi, aAntennadiffare_0; " ANTENNADIFFAREARATIO PWL ( "
mov al, 0
call _fprintf
mov [rsp+28h+var_1C], 0
loc_14D6A:
mov eax, [rsp+28h+var_1C]
cmp eax, [rsp+28h+var_8]
jge short loc_14DC3
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
mov rax, [rsp+28h+var_10]
mov rcx, rax
add rcx, 8
mov [rsp+28h+var_10], rcx
movsd xmm0, qword ptr [rax]
mov rax, [rsp+28h+var_18]
mov rcx, rax
add rcx, 8
mov [rsp+28h+var_18], rcx
movsd xmm1, qword ptr [rax]
lea rsi, a11g11g_0; "( %.11g %.11g ) "
mov al, 2
call _fprintf
mov eax, [rsp+28h+var_1C]
add eax, 1
mov [rsp+28h+var_1C], eax
jmp short loc_14D6A
loc_14DC3:
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rdi, [rax]
lea rsi, asc_2AAE9; ") ;\n"
mov al, 0
call _fprintf
loc_14DDB:
lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines
mov ecx, [rax]
add ecx, 1
lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines
mov [rax], ecx
mov [rsp+28h+var_4], 0
loc_14DF8:
mov eax, [rsp+28h+var_4]
add rsp, 28h
retn
|
long long LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(
LefDefParser *this,
double *a2,
double *a3,
double *a4,
int a5,
int a6)
{
int v6; // edx
int v7; // ecx
int v8; // r8d
int v9; // r9d
double *v10; // rax
double v11; // xmm0_8
double *v12; // rax
int i; // [rsp+Ch] [rbp-1Ch]
int j; // [rsp+Ch] [rbp-1Ch]
double *v16; // [rsp+10h] [rbp-18h]
v16 = a3;
LefDefParser::lefw54Num = 103;
if ( *(_QWORD *)&LefDefParser::lefwFile )
{
if ( LefDefParser::lefwState == 7
|| LefDefParser::lefwState == 31
|| LefDefParser::lefwState == 6
|| LefDefParser::lefwState == 28 )
{
if ( LefDefParser::lefwIsRouting || LefDefParser::lefwIsCut )
{
if ( *(double *)&LefDefParser::versionNum >= 5.4 )
{
if ( LefDefParser::lefwWriteEncrypt )
{
LefDefParser::encPrint(
LefDefParser::lefwFile,
(unsigned int)" ANTENNADIFFAREARATIO PWL ( ",
(_DWORD)a3,
(_DWORD)a4,
a5,
a6);
for ( i = 0; i < (int)this; ++i )
{
++a2;
LefDefParser::encPrint(
LefDefParser::lefwFile,
(unsigned int)"( %.11g %.11g ) ",
v6,
(_DWORD)++v16,
v8,
v9);
}
LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)") ;\n", v6, v7, v8, v9);
}
else
{
fprintf(*(_QWORD *)&LefDefParser::lefwFile, " ANTENNADIFFAREARATIO PWL ( ");
for ( j = 0; j < (int)this; ++j )
{
v10 = a2++;
v11 = *v10;
v12 = v16++;
fprintf(*(_QWORD *)&LefDefParser::lefwFile, "( %.11g %.11g ) ", v11, *v12);
}
fprintf(*(_QWORD *)&LefDefParser::lefwFile, ") ;\n");
}
++LefDefParser::lefwLines;
return 0;
}
else
{
return 5;
}
}
else
{
return 3;
}
}
else
{
return 2;
}
}
else
{
return 1;
}
}
|
lefwLayerAntennaDiffAreaRatioPwl:
SUB RSP,0x28
MOV dword ptr [RSP + 0x20],EDI
MOV qword ptr [RSP + 0x18],RSI
MOV qword ptr [RSP + 0x10],RDX
MOV dword ptr [0x00132d4c],0x67
LEA RAX,[0x132e00]
CMP qword ptr [RAX],0x0
JNZ 0x00114c26
MOV dword ptr [RSP + 0x24],0x1
JMP 0x00114df8
LAB_00114c26:
LEA RAX,[0x133050]
CMP dword ptr [RAX],0x7
JZ 0x00114c63
LEA RAX,[0x133050]
CMP dword ptr [RAX],0x1f
JZ 0x00114c63
LEA RAX,[0x133050]
CMP dword ptr [RAX],0x6
JZ 0x00114c63
LEA RAX,[0x133050]
CMP dword ptr [RAX],0x1c
JZ 0x00114c63
MOV dword ptr [RSP + 0x24],0x2
JMP 0x00114df8
LAB_00114c63:
LEA RAX,[0x1330c4]
CMP dword ptr [RAX],0x0
JNZ 0x00114c88
LEA RAX,[0x133084]
CMP dword ptr [RAX],0x0
JNZ 0x00114c88
MOV dword ptr [RSP + 0x24],0x3
JMP 0x00114df8
LAB_00114c88:
MOVSD XMM0,qword ptr [0x00129200]
UCOMISD XMM0,qword ptr [0x00132d40]
JBE 0x00114ca7
MOV dword ptr [RSP + 0x24],0x5
JMP 0x00114df8
LAB_00114ca7:
CMP dword ptr [0x001330ec],0x0
JZ 0x00114d4a
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
LEA RSI,[0x12aab9]
MOV AL,0x0
CALL 0x001289b0
MOV dword ptr [RSP + 0xc],0x0
LAB_00114cd4:
MOV EAX,dword ptr [RSP + 0xc]
CMP EAX,dword ptr [RSP + 0x20]
JGE 0x00114d2d
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
MOV RAX,qword ptr [RSP + 0x18]
MOV RCX,RAX
ADD RCX,0x8
MOV qword ptr [RSP + 0x18],RCX
MOVSD XMM0,qword ptr [RAX]
MOV RAX,qword ptr [RSP + 0x10]
MOV RCX,RAX
ADD RCX,0x8
MOV qword ptr [RSP + 0x10],RCX
MOVSD XMM1,qword ptr [RAX]
LEA RSI,[0x12aad8]
MOV AL,0x2
CALL 0x001289b0
MOV EAX,dword ptr [RSP + 0xc]
ADD EAX,0x1
MOV dword ptr [RSP + 0xc],EAX
JMP 0x00114cd4
LAB_00114d2d:
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
LEA RSI,[0x12aae9]
MOV AL,0x0
CALL 0x001289b0
JMP 0x00114ddb
LAB_00114d4a:
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
LEA RSI,[0x12aab9]
MOV AL,0x0
CALL 0x00101100
MOV dword ptr [RSP + 0xc],0x0
LAB_00114d6a:
MOV EAX,dword ptr [RSP + 0xc]
CMP EAX,dword ptr [RSP + 0x20]
JGE 0x00114dc3
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
MOV RAX,qword ptr [RSP + 0x18]
MOV RCX,RAX
ADD RCX,0x8
MOV qword ptr [RSP + 0x18],RCX
MOVSD XMM0,qword ptr [RAX]
MOV RAX,qword ptr [RSP + 0x10]
MOV RCX,RAX
ADD RCX,0x8
MOV qword ptr [RSP + 0x10],RCX
MOVSD XMM1,qword ptr [RAX]
LEA RSI,[0x12aad8]
MOV AL,0x2
CALL 0x00101100
MOV EAX,dword ptr [RSP + 0xc]
ADD EAX,0x1
MOV dword ptr [RSP + 0xc],EAX
JMP 0x00114d6a
LAB_00114dc3:
LEA RAX,[0x132e00]
MOV RDI,qword ptr [RAX]
LEA RSI,[0x12aae9]
MOV AL,0x0
CALL 0x00101100
LAB_00114ddb:
LEA RAX,[0x13304c]
MOV ECX,dword ptr [RAX]
ADD ECX,0x1
LEA RAX,[0x13304c]
MOV dword ptr [RAX],ECX
MOV dword ptr [RSP + 0x24],0x0
LAB_00114df8:
MOV EAX,dword ptr [RSP + 0x24]
ADD RSP,0x28
RET
|
/* LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(int, double*, double*) */
int4
LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(int param_1,double *param_2,double *param_3)
{
int local_1c;
double *local_18;
double *local_10;
int4 local_4;
lefw54Num = 0x67;
if (lefwFile == (_IO_FILE *)0x0) {
local_4 = 1;
}
else if ((((lefwState == 7) || (lefwState == 0x1f)) || (lefwState == 6)) || (lefwState == 0x1c)) {
if ((lefwIsRouting == 0) && (lefwIsCut == 0)) {
local_4 = 3;
}
else if (DAT_00129200 <= versionNum) {
if (lefwWriteEncrypt == 0) {
fprintf(lefwFile," ANTENNADIFFAREARATIO PWL ( ");
local_18 = param_3;
local_10 = param_2;
for (local_1c = 0; local_1c < param_1; local_1c = local_1c + 1) {
fprintf(lefwFile,"( %.11g %.11g ) ",*local_10,*local_18);
local_18 = local_18 + 1;
local_10 = local_10 + 1;
}
fprintf(lefwFile,") ;\n");
}
else {
encPrint(lefwFile," ANTENNADIFFAREARATIO PWL ( ");
local_18 = param_3;
local_10 = param_2;
for (local_1c = 0; local_1c < param_1; local_1c = local_1c + 1) {
encPrint(lefwFile,"( %.11g %.11g ) ",*local_10,*local_18);
local_18 = local_18 + 1;
local_10 = local_10 + 1;
}
encPrint(lefwFile,") ;\n");
}
lefwLines = lefwLines + 1;
local_4 = 0;
}
else {
local_4 = 5;
}
}
else {
local_4 = 2;
}
return local_4;
}
|
|
9,962 |
LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(int, double*, double*)
|
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp
|
int
lefwLayerAntennaDiffAreaRatioPwl(int numPwls,
double *diffusions,
double *ratios)
{
int i;
lefw54Num = LEFW_ANTENNADIFFAREARATIOPWL;
if (!lefwFile)
return LEFW_UNINITIALIZED;
if (lefwState != LEFW_LAYERROUTING_START && lefwState != LEFW_LAYERROUTING
&& lefwState != LEFW_LAYER_START && lefwState != LEFW_LAYER)
return LEFW_BAD_ORDER;
// only routing or cut calls this func
if (!lefwIsRouting && !lefwIsCut)
return LEFW_BAD_DATA;
if (versionNum < 5.4)
return LEFW_WRONG_VERSION;
if (lefwWriteEncrypt) {
encPrint(lefwFile, (char*) " ANTENNADIFFAREARATIO PWL ( ");
for (i = 0; i < numPwls; i++)
encPrint(lefwFile, (char*) "( %.11g %.11g ) ", *diffusions++, *ratios++);
encPrint(lefwFile, (char*) ") ;\n");
} else {
fprintf(lefwFile, " ANTENNADIFFAREARATIO PWL ( ");
for (i = 0; i < numPwls; i++)
fprintf(lefwFile, "( %.11g %.11g ) ", *diffusions++, *ratios++);
fprintf(lefwFile, ") ;\n");
}
lefwLines++;
return LEFW_OK;
}
|
O3
|
cpp
|
LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(int, double*, double*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl $0x67, 0x186a1(%rip) # 0x24d4c
leaq 0x1874e(%rip), %r12 # 0x24e00
movq (%r12), %rcx
testq %rcx, %rcx
je 0xc783
movq %rdx, %rbx
leaq 0x18987(%rip), %rax # 0x25050
movl (%rax), %edx
movl $0x2, %eax
cmpl $0x1f, %edx
ja 0xc7f6
movq %rsi, %r14
movl $0x900000c0, %esi # imm = 0x900000C0
btl %edx, %esi
jae 0xc7f6
leaq 0x189d3(%rip), %rdx # 0x250c4
leaq 0x1898c(%rip), %rax # 0x25084
movl (%rax), %esi
movl $0x3, %eax
orl (%rdx), %esi
je 0xc7f6
movl $0x5, %eax
movsd 0xca04(%rip), %xmm0 # 0x19118
ucomisd 0x18624(%rip), %xmm0 # 0x24d40
ja 0xc7f6
movl %edi, %ebp
cmpb $0x1, 0x189c1(%rip) # 0x250ec
jne 0xc78a
leaq 0xe641(%rip), %rsi # 0x1ad75
movq %rcx, %rdi
xorl %eax, %eax
callq 0x18c35
testl %ebp, %ebp
jle 0xc76f
movl %ebp, %r13d
xorl %ebp, %ebp
leaq 0xe646(%rip), %r15 # 0x1ad94
movq (%r12), %rdi
movsd (%r14,%rbp,8), %xmm0
movsd (%rbx,%rbp,8), %xmm1
movq %r15, %rsi
movb $0x2, %al
callq 0x18c35
incq %rbp
cmpl %ebp, %r13d
jne 0xc74e
movq (%r12), %rdi
leaq 0xe62b(%rip), %rsi # 0x1ada5
xorl %eax, %eax
callq 0x18c35
jmp 0xc7eb
movl $0x1, %eax
jmp 0xc7f6
leaq 0xe5e4(%rip), %rdi # 0x1ad75
movl $0x1e, %esi
movl $0x1, %edx
callq 0x1110
testl %ebp, %ebp
jle 0xc7d1
movl %ebp, %r13d
xorl %ebp, %ebp
leaq 0xe5e4(%rip), %r15 # 0x1ad94
movq (%r12), %rdi
movsd (%r14,%rbp,8), %xmm0
movsd (%rbx,%rbp,8), %xmm1
movq %r15, %rsi
movb $0x2, %al
callq 0x10f0
incq %rbp
cmpl %ebp, %r13d
jne 0xc7b0
movq (%r12), %rcx
leaq 0xe5c9(%rip), %rdi # 0x1ada5
movl $0x4, %esi
movl $0x1, %edx
callq 0x1110
leaq 0x1885a(%rip), %rax # 0x2504c
incl (%rax)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
_ZN12LefDefParser32lefwLayerAntennaDiffAreaRatioPwlEiPdS0_:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov cs:_ZN12LefDefParserL9lefw54NumE, 67h ; 'g'; LefDefParser::lefw54Num
lea r12, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
mov rcx, [r12]
test rcx, rcx
jz loc_C783
mov rbx, rdx
lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState
mov edx, [rax]
mov eax, 2
cmp edx, 1Fh
ja loc_C7F6
mov r14, rsi
mov esi, 900000C0h
bt esi, edx
jnb loc_C7F6
lea rdx, _ZN12LefDefParser13lefwIsRoutingE; LefDefParser::lefwIsRouting
lea rax, _ZN12LefDefParser9lefwIsCutE; LefDefParser::lefwIsCut
mov esi, [rax]
mov eax, 3
or esi, [rdx]
jz loc_C7F6
mov eax, 5
movsd xmm0, cs:dbl_19118
ucomisd xmm0, cs:_ZN12LefDefParserL10versionNumE; LefDefParser::versionNum
ja loc_C7F6
mov ebp, edi
cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 1; LefDefParser::lefwWriteEncrypt
jnz short loc_C78A
lea rsi, aAntennadiffare_0; " ANTENNADIFFAREARATIO PWL ( "
mov rdi, rcx
xor eax, eax
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
test ebp, ebp
jle short loc_C76F
mov r13d, ebp
xor ebp, ebp
lea r15, a11g11g_0; "( %.11g %.11g ) "
loc_C74E:
mov rdi, [r12]
movsd xmm0, qword ptr [r14+rbp*8]
movsd xmm1, qword ptr [rbx+rbp*8]
mov rsi, r15
mov al, 2
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
inc rbp
cmp r13d, ebp
jnz short loc_C74E
loc_C76F:
mov rdi, [r12]
lea rsi, asc_1ADA5; ") ;\n"
xor eax, eax
call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...)
jmp short loc_C7EB
loc_C783:
mov eax, 1
jmp short loc_C7F6
loc_C78A:
lea rdi, aAntennadiffare_0; " ANTENNADIFFAREARATIO PWL ( "
mov esi, 1Eh
mov edx, 1
call _fwrite
test ebp, ebp
jle short loc_C7D1
mov r13d, ebp
xor ebp, ebp
lea r15, a11g11g_0; "( %.11g %.11g ) "
loc_C7B0:
mov rdi, [r12]
movsd xmm0, qword ptr [r14+rbp*8]
movsd xmm1, qword ptr [rbx+rbp*8]
mov rsi, r15
mov al, 2
call _fprintf
inc rbp
cmp r13d, ebp
jnz short loc_C7B0
loc_C7D1:
mov rcx, [r12]
lea rdi, asc_1ADA5; ") ;\n"
mov esi, 4
mov edx, 1
call _fwrite
loc_C7EB:
lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines
inc dword ptr [rax]
xor eax, eax
loc_C7F6:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(
LefDefParser *this,
long long a2,
double *a3,
double *a4,
int a5,
int a6)
{
long long result; // rax
int v9; // esi
int v10; // edx
int v11; // ecx
int v12; // r8d
int v13; // r9d
long long v14; // rbp
long long v15; // rbp
LefDefParser::lefw54Num = 103;
if ( !*(_QWORD *)&LefDefParser::lefwFile )
return 1LL;
result = 2LL;
if ( LefDefParser::lefwState <= 0x1F )
{
v9 = -1879048000;
if ( _bittest(&v9, LefDefParser::lefwState) )
{
result = 3LL;
if ( LefDefParser::lefwIsRouting | LefDefParser::lefwIsCut )
{
result = 5LL;
if ( *(double *)&LefDefParser::versionNum >= 5.4 )
{
if ( LefDefParser::lefwWriteEncrypt == 1 )
{
LefDefParser::encPrint(
LefDefParser::lefwFile,
(unsigned int)" ANTENNADIFFAREARATIO PWL ( ",
(unsigned int)&LefDefParser::lefwIsRouting,
LefDefParser::lefwFile,
a5,
a6);
if ( (int)this > 0 )
{
v14 = 0LL;
do
{
LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)"( %.11g %.11g ) ", v10, v11, v12, v13);
++v14;
}
while ( (_DWORD)this != (_DWORD)v14 );
}
LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)") ;\n", v10, v11, v12, v13);
}
else
{
fwrite(" ANTENNADIFFAREARATIO PWL ( ", 30LL, 1LL, *(_QWORD *)&LefDefParser::lefwFile);
if ( (int)this > 0 )
{
v15 = 0LL;
do
{
fprintf(*(_QWORD *)&LefDefParser::lefwFile, "( %.11g %.11g ) ", *(double *)(a2 + 8 * v15), a3[v15]);
++v15;
}
while ( (_DWORD)this != (_DWORD)v15 );
}
fwrite(") ;\n", 4LL, 1LL, *(_QWORD *)&LefDefParser::lefwFile);
}
++LefDefParser::lefwLines;
return 0LL;
}
}
}
}
return result;
}
|
lefwLayerAntennaDiffAreaRatioPwl:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV dword ptr [0x00124d4c],0x67
LEA R12,[0x124e00]
MOV RCX,qword ptr [R12]
TEST RCX,RCX
JZ 0x0010c783
MOV RBX,RDX
LEA RAX,[0x125050]
MOV EDX,dword ptr [RAX]
MOV EAX,0x2
CMP EDX,0x1f
JA 0x0010c7f6
MOV R14,RSI
MOV ESI,0x900000c0
BT ESI,EDX
JNC 0x0010c7f6
LEA RDX,[0x1250c4]
LEA RAX,[0x125084]
MOV ESI,dword ptr [RAX]
MOV EAX,0x3
OR ESI,dword ptr [RDX]
JZ 0x0010c7f6
MOV EAX,0x5
MOVSD XMM0,qword ptr [0x00119118]
UCOMISD XMM0,qword ptr [0x00124d40]
JA 0x0010c7f6
MOV EBP,EDI
CMP byte ptr [0x001250ec],0x1
JNZ 0x0010c78a
LEA RSI,[0x11ad75]
MOV RDI,RCX
XOR EAX,EAX
CALL 0x00118c35
TEST EBP,EBP
JLE 0x0010c76f
MOV R13D,EBP
XOR EBP,EBP
LEA R15,[0x11ad94]
LAB_0010c74e:
MOV RDI,qword ptr [R12]
MOVSD XMM0,qword ptr [R14 + RBP*0x8]
MOVSD XMM1,qword ptr [RBX + RBP*0x8]
MOV RSI,R15
MOV AL,0x2
CALL 0x00118c35
INC RBP
CMP R13D,EBP
JNZ 0x0010c74e
LAB_0010c76f:
MOV RDI,qword ptr [R12]
LEA RSI,[0x11ada5]
XOR EAX,EAX
CALL 0x00118c35
JMP 0x0010c7eb
LAB_0010c783:
MOV EAX,0x1
JMP 0x0010c7f6
LAB_0010c78a:
LEA RDI,[0x11ad75]
MOV ESI,0x1e
MOV EDX,0x1
CALL 0x00101110
TEST EBP,EBP
JLE 0x0010c7d1
MOV R13D,EBP
XOR EBP,EBP
LEA R15,[0x11ad94]
LAB_0010c7b0:
MOV RDI,qword ptr [R12]
MOVSD XMM0,qword ptr [R14 + RBP*0x8]
MOVSD XMM1,qword ptr [RBX + RBP*0x8]
MOV RSI,R15
MOV AL,0x2
CALL 0x001010f0
INC RBP
CMP R13D,EBP
JNZ 0x0010c7b0
LAB_0010c7d1:
MOV RCX,qword ptr [R12]
LEA RDI,[0x11ada5]
MOV ESI,0x4
MOV EDX,0x1
CALL 0x00101110
LAB_0010c7eb:
LEA RAX,[0x12504c]
INC dword ptr [RAX]
XOR EAX,EAX
LAB_0010c7f6:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(int, double*, double*) */
int8
LefDefParser::lefwLayerAntennaDiffAreaRatioPwl(int param_1,double *param_2,double *param_3)
{
int8 uVar1;
long lVar2;
lefw54Num = 0x67;
if (lefwFile == (_IO_FILE *)0x0) {
uVar1 = 1;
}
else {
uVar1 = 2;
if (((lefwState < 0x20) && ((0x900000c0U >> (lefwState & 0x1f) & 1) != 0)) &&
(uVar1 = 3, lefwIsCut != 0 || lefwIsRouting != 0)) {
uVar1 = 5;
if (DAT_00119118 <= versionNum) {
if (lefwWriteEncrypt == '\x01') {
encPrint(lefwFile," ANTENNADIFFAREARATIO PWL ( ");
if (0 < param_1) {
lVar2 = 0;
do {
encPrint(lefwFile,"( %.11g %.11g ) ",param_2[lVar2],param_3[lVar2]);
lVar2 = lVar2 + 1;
} while (param_1 != (int)lVar2);
}
encPrint(lefwFile,") ;\n");
}
else {
fwrite(" ANTENNADIFFAREARATIO PWL ( ",0x1e,1,lefwFile);
if (0 < param_1) {
lVar2 = 0;
do {
fprintf(lefwFile,"( %.11g %.11g ) ",param_2[lVar2],param_3[lVar2]);
lVar2 = lVar2 + 1;
} while (param_1 != (int)lVar2);
}
fwrite(&DAT_0011ada5,4,1,lefwFile);
}
lefwLines = lefwLines + 1;
uVar1 = 0;
}
}
}
return uVar1;
}
|
|
9,963 |
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<2>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<float> const&)
|
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/../bfr/pointOperations.h
|
static void apply(Parameters const & args) {
typedef struct PointBuilder<REAL,SIZE> Point;
int pSize = args.pointSize;
int pStride = args.pointStride;
REAL const * const * wArray = args.weightArray;
REAL ** pArray = args.resultArray;
//
// Apply each successive control point to all derivatives at once,
// rather than computing each derivate independently:
//
REAL const * pSrc = (args.srcIndices == 0) ? args.pointData :
(args.pointData + pStride * args.srcIndices[0]);
Point::Set(pArray[0], wArray[0][0], pSrc, pSize);
Point::Set(pArray[1], wArray[1][0], pSrc, pSize);
Point::Set(pArray[2], wArray[2][0], pSrc, pSize);
for (int i = 1; i < args.srcCount; ++i) {
pSrc = (args.srcIndices == 0) ? (pSrc + pStride) :
(args.pointData + pStride * args.srcIndices[i]);
Point::Add(pArray[0], wArray[0][i], pSrc, pSize);
Point::Add(pArray[1], wArray[1][i], pSrc, pSize);
Point::Add(pArray[2], wArray[2][i], pSrc, pSize);
}
}
|
O0
|
c
|
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<2>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<float> const&):
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
movl 0xc(%rax), %eax
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq 0x28(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x10(%rax)
jne 0x1b0b90
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x38(%rbp)
jmp 0x1b0bb3
movq -0x8(%rbp), %rax
movq (%rax), %rax
movl -0x10(%rbp), %ecx
movq -0x8(%rbp), %rdx
movq 0x10(%rdx), %rdx
imull (%rdx), %ecx
movslq %ecx, %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rax
movq (%rax), %rax
movss (%rax), %xmm0
movq -0x28(%rbp), %rsi
movl -0xc(%rbp), %edx
callq 0xd36d0
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movss (%rax), %xmm0
movq -0x28(%rbp), %rsi
movl -0xc(%rbp), %edx
callq 0xd36d0
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movss (%rax), %xmm0
movq -0x28(%rbp), %rsi
movl -0xc(%rbp), %edx
callq 0xd36d0
movl $0x1, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x18(%rcx), %eax
jge 0x1b0cfb
movq -0x8(%rbp), %rax
cmpq $0x0, 0x10(%rax)
jne 0x1b0c50
movq -0x28(%rbp), %rax
movslq -0x10(%rbp), %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
jmp 0x1b0c78
movq -0x8(%rbp), %rax
movq (%rax), %rax
movl -0x10(%rbp), %ecx
movq -0x8(%rbp), %rdx
movq 0x10(%rdx), %rdx
movslq -0x2c(%rbp), %rsi
imull (%rdx,%rsi,4), %ecx
movslq %ecx, %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rax
movq (%rax), %rax
movslq -0x2c(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movq -0x28(%rbp), %rsi
movl -0xc(%rbp), %edx
callq 0xce900
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x2c(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movq -0x28(%rbp), %rsi
movl -0xc(%rbp), %edx
callq 0xce900
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movslq -0x2c(%rbp), %rcx
movss (%rax,%rcx,4), %xmm0
movq -0x28(%rbp), %rsi
movl -0xc(%rbp), %edx
callq 0xce900
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x1b0c20
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax,%rax)
|
_ZN10OpenSubdiv6v3_6_03Bfr6points8Combine3IfE5applyILi0EEEvRKNS2_27CommonCombinationParametersIfEE:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov eax, [rax+8]
mov [rbp+var_C], eax
mov rax, [rbp+var_8]
mov eax, [rax+0Ch]
mov [rbp+var_10], eax
mov rax, [rbp+var_8]
mov rax, [rax+28h]
mov [rbp+var_18], rax
mov rax, [rbp+var_8]
mov rax, [rax+20h]
mov [rbp+var_20], rax
mov rax, [rbp+var_8]
cmp qword ptr [rax+10h], 0
jnz short loc_1B0B90
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_38], rax
jmp short loc_1B0BB3
loc_1B0B90:
mov rax, [rbp+var_8]
mov rax, [rax]
mov ecx, [rbp+var_10]
mov rdx, [rbp+var_8]
mov rdx, [rdx+10h]
imul ecx, [rdx]
movsxd rcx, ecx
shl rcx, 2
add rax, rcx
mov [rbp+var_38], rax
loc_1B0BB3:
mov rax, [rbp+var_38]
mov [rbp+var_28], rax
mov rax, [rbp+var_20]
mov rdi, [rax]
mov rax, [rbp+var_18]
mov rax, [rax]
movss xmm0, dword ptr [rax]
mov rsi, [rbp+var_28]
mov edx, [rbp+var_C]
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIfLi0EE3SetEPffPKfi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Set(float *,float,float const*,int)
mov rax, [rbp+var_20]
mov rdi, [rax+8]
mov rax, [rbp+var_18]
mov rax, [rax+8]
movss xmm0, dword ptr [rax]
mov rsi, [rbp+var_28]
mov edx, [rbp+var_C]
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIfLi0EE3SetEPffPKfi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Set(float *,float,float const*,int)
mov rax, [rbp+var_20]
mov rdi, [rax+10h]
mov rax, [rbp+var_18]
mov rax, [rax+10h]
movss xmm0, dword ptr [rax]
mov rsi, [rbp+var_28]
mov edx, [rbp+var_C]
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIfLi0EE3SetEPffPKfi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Set(float *,float,float const*,int)
mov [rbp+var_2C], 1
loc_1B0C20:
mov eax, [rbp+var_2C]
mov rcx, [rbp+var_8]
cmp eax, [rcx+18h]
jge loc_1B0CFB
mov rax, [rbp+var_8]
cmp qword ptr [rax+10h], 0
jnz short loc_1B0C50
mov rax, [rbp+var_28]
movsxd rcx, [rbp+var_10]
shl rcx, 2
add rax, rcx
mov [rbp+var_40], rax
jmp short loc_1B0C78
loc_1B0C50:
mov rax, [rbp+var_8]
mov rax, [rax]
mov ecx, [rbp+var_10]
mov rdx, [rbp+var_8]
mov rdx, [rdx+10h]
movsxd rsi, [rbp+var_2C]
imul ecx, [rdx+rsi*4]
movsxd rcx, ecx
shl rcx, 2
add rax, rcx
mov [rbp+var_40], rax
loc_1B0C78:
mov rax, [rbp+var_40]
mov [rbp+var_28], rax
mov rax, [rbp+var_20]
mov rdi, [rax]
mov rax, [rbp+var_18]
mov rax, [rax]
movsxd rcx, [rbp+var_2C]
movss xmm0, dword ptr [rax+rcx*4]
mov rsi, [rbp+var_28]
mov edx, [rbp+var_C]
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIfLi0EE3AddEPffPKfi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Add(float *,float,float const*,int)
mov rax, [rbp+var_20]
mov rdi, [rax+8]
mov rax, [rbp+var_18]
mov rax, [rax+8]
movsxd rcx, [rbp+var_2C]
movss xmm0, dword ptr [rax+rcx*4]
mov rsi, [rbp+var_28]
mov edx, [rbp+var_C]
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIfLi0EE3AddEPffPKfi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Add(float *,float,float const*,int)
mov rax, [rbp+var_20]
mov rdi, [rax+10h]
mov rax, [rbp+var_18]
mov rax, [rax+10h]
movsxd rcx, [rbp+var_2C]
movss xmm0, dword ptr [rax+rcx*4]
mov rsi, [rbp+var_28]
mov edx, [rbp+var_C]
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIfLi0EE3AddEPffPKfi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Add(float *,float,float const*,int)
mov eax, [rbp+var_2C]
add eax, 1
mov [rbp+var_2C], eax
jmp loc_1B0C20
loc_1B0CFB:
add rsp, 40h
pop rbp
retn
|
long long OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<0>(long long a1)
{
long long result; // rax
long long v2; // [rsp+0h] [rbp-40h]
long long v3; // [rsp+8h] [rbp-38h]
int i; // [rsp+14h] [rbp-2Ch]
long long v5; // [rsp+18h] [rbp-28h]
_QWORD *v6; // [rsp+20h] [rbp-20h]
float **v7; // [rsp+28h] [rbp-18h]
int v8; // [rsp+30h] [rbp-10h]
unsigned int v9; // [rsp+34h] [rbp-Ch]
v9 = *(_DWORD *)(a1 + 8);
v8 = *(_DWORD *)(a1 + 12);
v7 = *(float ***)(a1 + 40);
v6 = *(_QWORD **)(a1 + 32);
if ( *(_QWORD *)(a1 + 16) )
v3 = 4LL * **(_DWORD **)(a1 + 16) * v8 + *(_QWORD *)a1;
else
v3 = *(_QWORD *)a1;
v5 = v3;
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Set(*v6, v3, v9, **v7);
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Set(v6[1], v3, v9, *v7[1]);
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Set(v6[2], v3, v9, *v7[2]);
for ( i = 1; ; ++i )
{
result = (unsigned int)i;
if ( i >= *(_DWORD *)(a1 + 24) )
break;
if ( *(_QWORD *)(a1 + 16) )
v2 = 4LL * *(_DWORD *)(*(_QWORD *)(a1 + 16) + 4LL * i) * v8 + *(_QWORD *)a1;
else
v2 = 4LL * v8 + v5;
v5 = v2;
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Add(*v6, v2, v9, (*v7)[i]);
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Add(v6[1], v2, v9, v7[1][i]);
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<float,0>::Add(v6[2], v2, v9, v7[2][i]);
}
return result;
}
| |||
9,964 |
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<2>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<float> const&)
|
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/../bfr/pointOperations.h
|
static void apply(Parameters const & args) {
typedef struct PointBuilder<REAL,SIZE> Point;
int pSize = args.pointSize;
int pStride = args.pointStride;
REAL const * const * wArray = args.weightArray;
REAL ** pArray = args.resultArray;
//
// Apply each successive control point to all derivatives at once,
// rather than computing each derivate independently:
//
REAL const * pSrc = (args.srcIndices == 0) ? args.pointData :
(args.pointData + pStride * args.srcIndices[0]);
Point::Set(pArray[0], wArray[0][0], pSrc, pSize);
Point::Set(pArray[1], wArray[1][0], pSrc, pSize);
Point::Set(pArray[2], wArray[2][0], pSrc, pSize);
for (int i = 1; i < args.srcCount; ++i) {
pSrc = (args.srcIndices == 0) ? (pSrc + pStride) :
(args.pointData + pStride * args.srcIndices[i]);
Point::Add(pArray[0], wArray[0][i], pSrc, pSize);
Point::Add(pArray[1], wArray[1][i], pSrc, pSize);
Point::Add(pArray[2], wArray[2][i], pSrc, pSize);
}
}
|
O1
|
c
|
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<2>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<float> const&):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl 0x8(%rdi), %eax
movslq 0xc(%rdi), %rcx
movq 0x28(%rdi), %r14
movq 0x20(%rdi), %rbx
movq 0x10(%rdi), %rdx
movq (%rdi), %rsi
testq %rdx, %rdx
je 0x9b061
movslq (%rdx), %r8
imulq %rcx, %r8
leaq (%rsi,%r8,8), %rsi
movq (%rbx), %r8
movq (%r14), %r9
testl %eax, %eax
jle 0x9b08b
movsd (%r9), %xmm0
xorl %r10d, %r10d
movsd (%rsi,%r10,8), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, (%r8,%r10,8)
incq %r10
cmpq %r10, %rax
jne 0x9b073
movq 0x8(%rbx), %r10
movq 0x8(%r14), %r11
testl %eax, %eax
jle 0x9b0b7
movsd (%r11), %xmm0
xorl %r15d, %r15d
movsd (%rsi,%r15,8), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, (%r10,%r15,8)
incq %r15
cmpq %r15, %rax
jne 0x9b09f
movq 0x10(%rbx), %rbx
movq 0x10(%r14), %r14
testl %eax, %eax
jle 0x9b0e3
movsd (%r14), %xmm0
xorl %r15d, %r15d
movsd (%rsi,%r15,8), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, (%rbx,%r15,8)
incq %r15
cmpq %r15, %rax
jne 0x9b0cb
movslq 0x18(%rdi), %r15
cmpq $0x2, %r15
jl 0x9b19e
movq (%rdi), %rdi
movl $0x1, %r12d
testq %rdx, %rdx
je 0x9b10d
movslq (%rdx,%r12,4), %rsi
imulq %rcx, %rsi
leaq (%rdi,%rsi,8), %rsi
jmp 0x9b111
leaq (%rsi,%rcx,8), %rsi
testl %eax, %eax
jle 0x9b13c
movsd (%r9,%r12,8), %xmm0
xorl %r13d, %r13d
movsd (%rsi,%r13,8), %xmm1
mulsd %xmm0, %xmm1
addsd (%r8,%r13,8), %xmm1
movsd %xmm1, (%r8,%r13,8)
incq %r13
cmpq %r13, %rax
jne 0x9b11e
testl %eax, %eax
jle 0x9b167
movsd (%r11,%r12,8), %xmm0
xorl %r13d, %r13d
movsd (%rsi,%r13,8), %xmm1
mulsd %xmm0, %xmm1
addsd (%r10,%r13,8), %xmm1
movsd %xmm1, (%r10,%r13,8)
incq %r13
cmpq %r13, %rax
jne 0x9b149
testl %eax, %eax
jle 0x9b192
movsd (%r14,%r12,8), %xmm0
xorl %r13d, %r13d
movsd (%rsi,%r13,8), %xmm1
mulsd %xmm0, %xmm1
addsd (%rbx,%r13,8), %xmm1
movsd %xmm1, (%rbx,%r13,8)
incq %r13
cmpq %r13, %rax
jne 0x9b174
incq %r12
cmpq %r15, %r12
jne 0x9b0fa
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
|
_ZN10OpenSubdiv6v3_6_03Bfr6points8Combine3IdE5applyILi0EEEvRKNS2_27CommonCombinationParametersIdEE:
push r15
push r14
push r13
push r12
push rbx
mov eax, [rdi+8]
movsxd rcx, dword ptr [rdi+0Ch]
mov r14, [rdi+28h]
mov rbx, [rdi+20h]
mov rdx, [rdi+10h]
mov rsi, [rdi]
test rdx, rdx
jz short loc_9B061
movsxd r8, dword ptr [rdx]
imul r8, rcx
lea rsi, [rsi+r8*8]
loc_9B061:
mov r8, [rbx]
mov r9, [r14]
test eax, eax
jle short loc_9B08B
movsd xmm0, qword ptr [r9]
xor r10d, r10d
loc_9B073:
movsd xmm1, qword ptr [rsi+r10*8]
mulsd xmm1, xmm0
movsd qword ptr [r8+r10*8], xmm1
inc r10
cmp rax, r10
jnz short loc_9B073
loc_9B08B:
mov r10, [rbx+8]
mov r11, [r14+8]
test eax, eax
jle short loc_9B0B7
movsd xmm0, qword ptr [r11]
xor r15d, r15d
loc_9B09F:
movsd xmm1, qword ptr [rsi+r15*8]
mulsd xmm1, xmm0
movsd qword ptr [r10+r15*8], xmm1
inc r15
cmp rax, r15
jnz short loc_9B09F
loc_9B0B7:
mov rbx, [rbx+10h]
mov r14, [r14+10h]
test eax, eax
jle short loc_9B0E3
movsd xmm0, qword ptr [r14]
xor r15d, r15d
loc_9B0CB:
movsd xmm1, qword ptr [rsi+r15*8]
mulsd xmm1, xmm0
movsd qword ptr [rbx+r15*8], xmm1
inc r15
cmp rax, r15
jnz short loc_9B0CB
loc_9B0E3:
movsxd r15, dword ptr [rdi+18h]
cmp r15, 2
jl loc_9B19E
mov rdi, [rdi]
mov r12d, 1
loc_9B0FA:
test rdx, rdx
jz short loc_9B10D
movsxd rsi, dword ptr [rdx+r12*4]
imul rsi, rcx
lea rsi, [rdi+rsi*8]
jmp short loc_9B111
loc_9B10D:
lea rsi, [rsi+rcx*8]
loc_9B111:
test eax, eax
jle short loc_9B13C
movsd xmm0, qword ptr [r9+r12*8]
xor r13d, r13d
loc_9B11E:
movsd xmm1, qword ptr [rsi+r13*8]
mulsd xmm1, xmm0
addsd xmm1, qword ptr [r8+r13*8]
movsd qword ptr [r8+r13*8], xmm1
inc r13
cmp rax, r13
jnz short loc_9B11E
loc_9B13C:
test eax, eax
jle short loc_9B167
movsd xmm0, qword ptr [r11+r12*8]
xor r13d, r13d
loc_9B149:
movsd xmm1, qword ptr [rsi+r13*8]
mulsd xmm1, xmm0
addsd xmm1, qword ptr [r10+r13*8]
movsd qword ptr [r10+r13*8], xmm1
inc r13
cmp rax, r13
jnz short loc_9B149
loc_9B167:
test eax, eax
jle short loc_9B192
movsd xmm0, qword ptr [r14+r12*8]
xor r13d, r13d
loc_9B174:
movsd xmm1, qword ptr [rsi+r13*8]
mulsd xmm1, xmm0
addsd xmm1, qword ptr [rbx+r13*8]
movsd qword ptr [rbx+r13*8], xmm1
inc r13
cmp rax, r13
jnz short loc_9B174
loc_9B192:
inc r12
cmp r12, r15
jnz loc_9B0FA
loc_9B19E:
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
|
long long OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<0>(long long *a1)
{
long long result; // rax
long long v2; // rcx
double **v3; // r14
long long *v4; // rbx
int *v5; // rdx
long long v6; // rsi
long long v7; // r8
double *v8; // r9
double v9; // xmm0_8
long long i; // r10
long long v11; // r10
double *v12; // r11
double v13; // xmm0_8
long long j; // r15
long long v15; // rbx
double *v16; // r14
double v17; // xmm0_8
long long k; // r15
long long v19; // r15
long long v20; // rdi
long long m; // r12
double v22; // xmm0_8
long long n; // r13
double v24; // xmm0_8
long long ii; // r13
double v26; // xmm0_8
long long jj; // r13
result = *((unsigned int *)a1 + 2);
v2 = *((int *)a1 + 3);
v3 = (double **)a1[5];
v4 = (long long *)a1[4];
v5 = (int *)a1[2];
v6 = *a1;
if ( v5 )
v6 += 8 * v2 * *v5;
v7 = *v4;
v8 = *v3;
if ( (int)result > 0 )
{
v9 = *v8;
for ( i = 0LL; i != result; ++i )
*(double *)(v7 + 8 * i) = *(double *)(v6 + 8 * i) * v9;
}
v11 = v4[1];
v12 = v3[1];
if ( (int)result > 0 )
{
v13 = *v12;
for ( j = 0LL; j != result; ++j )
*(double *)(v11 + 8 * j) = *(double *)(v6 + 8 * j) * v13;
}
v15 = v4[2];
v16 = v3[2];
if ( (int)result > 0 )
{
v17 = *v16;
for ( k = 0LL; k != result; ++k )
*(double *)(v15 + 8 * k) = *(double *)(v6 + 8 * k) * v17;
}
v19 = *((int *)a1 + 6);
if ( v19 >= 2 )
{
v20 = *a1;
for ( m = 1LL; m != v19; ++m )
{
if ( v5 )
v6 = v20 + 8 * v2 * v5[m];
else
v6 += 8 * v2;
if ( (int)result > 0 )
{
v22 = v8[m];
for ( n = 0LL; n != result; ++n )
*(double *)(v7 + 8 * n) = *(double *)(v6 + 8 * n) * v22 + *(double *)(v7 + 8 * n);
}
if ( (int)result > 0 )
{
v24 = v12[m];
for ( ii = 0LL; ii != result; ++ii )
*(double *)(v11 + 8 * ii) = *(double *)(v6 + 8 * ii) * v24 + *(double *)(v11 + 8 * ii);
}
if ( (int)result > 0 )
{
v26 = v16[m];
for ( jj = 0LL; jj != result; ++jj )
*(double *)(v15 + 8 * jj) = *(double *)(v6 + 8 * jj) * v26 + *(double *)(v15 + 8 * jj);
}
}
}
return result;
}
|
apply<0>:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV EAX,dword ptr [RDI + 0x8]
MOVSXD RCX,dword ptr [RDI + 0xc]
MOV R14,qword ptr [RDI + 0x28]
MOV RBX,qword ptr [RDI + 0x20]
MOV RDX,qword ptr [RDI + 0x10]
MOV RSI,qword ptr [RDI]
TEST RDX,RDX
JZ 0x0019b061
MOVSXD R8,dword ptr [RDX]
IMUL R8,RCX
LEA RSI,[RSI + R8*0x8]
LAB_0019b061:
MOV R8,qword ptr [RBX]
MOV R9,qword ptr [R14]
TEST EAX,EAX
JLE 0x0019b08b
MOVSD XMM0,qword ptr [R9]
XOR R10D,R10D
LAB_0019b073:
MOVSD XMM1,qword ptr [RSI + R10*0x8]
MULSD XMM1,XMM0
MOVSD qword ptr [R8 + R10*0x8],XMM1
INC R10
CMP RAX,R10
JNZ 0x0019b073
LAB_0019b08b:
MOV R10,qword ptr [RBX + 0x8]
MOV R11,qword ptr [R14 + 0x8]
TEST EAX,EAX
JLE 0x0019b0b7
MOVSD XMM0,qword ptr [R11]
XOR R15D,R15D
LAB_0019b09f:
MOVSD XMM1,qword ptr [RSI + R15*0x8]
MULSD XMM1,XMM0
MOVSD qword ptr [R10 + R15*0x8],XMM1
INC R15
CMP RAX,R15
JNZ 0x0019b09f
LAB_0019b0b7:
MOV RBX,qword ptr [RBX + 0x10]
MOV R14,qword ptr [R14 + 0x10]
TEST EAX,EAX
JLE 0x0019b0e3
MOVSD XMM0,qword ptr [R14]
XOR R15D,R15D
LAB_0019b0cb:
MOVSD XMM1,qword ptr [RSI + R15*0x8]
MULSD XMM1,XMM0
MOVSD qword ptr [RBX + R15*0x8],XMM1
INC R15
CMP RAX,R15
JNZ 0x0019b0cb
LAB_0019b0e3:
MOVSXD R15,dword ptr [RDI + 0x18]
CMP R15,0x2
JL 0x0019b19e
MOV RDI,qword ptr [RDI]
MOV R12D,0x1
LAB_0019b0fa:
TEST RDX,RDX
JZ 0x0019b10d
MOVSXD RSI,dword ptr [RDX + R12*0x4]
IMUL RSI,RCX
LEA RSI,[RDI + RSI*0x8]
JMP 0x0019b111
LAB_0019b10d:
LEA RSI,[RSI + RCX*0x8]
LAB_0019b111:
TEST EAX,EAX
JLE 0x0019b13c
MOVSD XMM0,qword ptr [R9 + R12*0x8]
XOR R13D,R13D
LAB_0019b11e:
MOVSD XMM1,qword ptr [RSI + R13*0x8]
MULSD XMM1,XMM0
ADDSD XMM1,qword ptr [R8 + R13*0x8]
MOVSD qword ptr [R8 + R13*0x8],XMM1
INC R13
CMP RAX,R13
JNZ 0x0019b11e
LAB_0019b13c:
TEST EAX,EAX
JLE 0x0019b167
MOVSD XMM0,qword ptr [R11 + R12*0x8]
XOR R13D,R13D
LAB_0019b149:
MOVSD XMM1,qword ptr [RSI + R13*0x8]
MULSD XMM1,XMM0
ADDSD XMM1,qword ptr [R10 + R13*0x8]
MOVSD qword ptr [R10 + R13*0x8],XMM1
INC R13
CMP RAX,R13
JNZ 0x0019b149
LAB_0019b167:
TEST EAX,EAX
JLE 0x0019b192
MOVSD XMM0,qword ptr [R14 + R12*0x8]
XOR R13D,R13D
LAB_0019b174:
MOVSD XMM1,qword ptr [RSI + R13*0x8]
MULSD XMM1,XMM0
ADDSD XMM1,qword ptr [RBX + R13*0x8]
MOVSD qword ptr [RBX + R13*0x8],XMM1
INC R13
CMP RAX,R13
JNZ 0x0019b174
LAB_0019b192:
INC R12
CMP R12,R15
JNZ 0x0019b0fa
LAB_0019b19e:
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
/* void
OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<0>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<double>
const&) */
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<0>
(CommonCombinationParameters *param_1)
{
double dVar1;
uint uVar2;
int iVar3;
int8 *puVar4;
long *plVar5;
int *piVar6;
long lVar7;
double *pdVar8;
long lVar9;
double *pdVar10;
long lVar11;
double *pdVar12;
long lVar13;
ulong uVar14;
long lVar15;
long lVar16;
ulong uVar17;
long lVar18;
uVar2 = *(uint *)(param_1 + 8);
uVar14 = (ulong)uVar2;
lVar15 = (long)*(int *)(param_1 + 0xc);
puVar4 = *(int8 **)(param_1 + 0x28);
plVar5 = *(long **)(param_1 + 0x20);
piVar6 = *(int **)(param_1 + 0x10);
lVar16 = *(long *)param_1;
if (piVar6 != (int *)0x0) {
lVar16 = lVar16 + *piVar6 * lVar15 * 8;
}
lVar7 = *plVar5;
pdVar8 = (double *)*puVar4;
if (0 < (int)uVar2) {
dVar1 = *pdVar8;
uVar17 = 0;
do {
*(double *)(lVar7 + uVar17 * 8) = *(double *)(lVar16 + uVar17 * 8) * dVar1;
uVar17 = uVar17 + 1;
} while (uVar14 != uVar17);
}
lVar9 = plVar5[1];
pdVar10 = (double *)puVar4[1];
if (0 < (int)uVar2) {
dVar1 = *pdVar10;
uVar17 = 0;
do {
*(double *)(lVar9 + uVar17 * 8) = *(double *)(lVar16 + uVar17 * 8) * dVar1;
uVar17 = uVar17 + 1;
} while (uVar14 != uVar17);
}
lVar11 = plVar5[2];
pdVar12 = (double *)puVar4[2];
if (0 < (int)uVar2) {
dVar1 = *pdVar12;
uVar17 = 0;
do {
*(double *)(lVar11 + uVar17 * 8) = *(double *)(lVar16 + uVar17 * 8) * dVar1;
uVar17 = uVar17 + 1;
} while (uVar14 != uVar17);
}
iVar3 = *(int *)(param_1 + 0x18);
if (1 < (long)iVar3) {
lVar13 = *(long *)param_1;
lVar18 = 1;
do {
if (piVar6 == (int *)0x0) {
lVar16 = lVar16 + lVar15 * 8;
}
else {
lVar16 = lVar13 + piVar6[lVar18] * lVar15 * 8;
}
if (0 < (int)uVar2) {
dVar1 = pdVar8[lVar18];
uVar17 = 0;
do {
*(double *)(lVar7 + uVar17 * 8) =
*(double *)(lVar16 + uVar17 * 8) * dVar1 + *(double *)(lVar7 + uVar17 * 8);
uVar17 = uVar17 + 1;
} while (uVar14 != uVar17);
}
if (0 < (int)uVar2) {
dVar1 = pdVar10[lVar18];
uVar17 = 0;
do {
*(double *)(lVar9 + uVar17 * 8) =
*(double *)(lVar16 + uVar17 * 8) * dVar1 + *(double *)(lVar9 + uVar17 * 8);
uVar17 = uVar17 + 1;
} while (uVar14 != uVar17);
}
if (0 < (int)uVar2) {
dVar1 = pdVar12[lVar18];
uVar17 = 0;
do {
*(double *)(lVar11 + uVar17 * 8) =
*(double *)(lVar16 + uVar17 * 8) * dVar1 + *(double *)(lVar11 + uVar17 * 8);
uVar17 = uVar17 + 1;
} while (uVar14 != uVar17);
}
lVar18 = lVar18 + 1;
} while (lVar18 != iVar3);
}
return;
}
|
|
9,965 |
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<2>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<float> const&)
|
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/../bfr/pointOperations.h
|
static void apply(Parameters const & args) {
typedef struct PointBuilder<REAL,SIZE> Point;
int pSize = args.pointSize;
int pStride = args.pointStride;
REAL const * const * wArray = args.weightArray;
REAL ** pArray = args.resultArray;
//
// Apply each successive control point to all derivatives at once,
// rather than computing each derivate independently:
//
REAL const * pSrc = (args.srcIndices == 0) ? args.pointData :
(args.pointData + pStride * args.srcIndices[0]);
Point::Set(pArray[0], wArray[0][0], pSrc, pSize);
Point::Set(pArray[1], wArray[1][0], pSrc, pSize);
Point::Set(pArray[2], wArray[2][0], pSrc, pSize);
for (int i = 1; i < args.srcCount; ++i) {
pSrc = (args.srcIndices == 0) ? (pSrc + pStride) :
(args.pointData + pStride * args.srcIndices[i]);
Point::Add(pArray[0], wArray[0][i], pSrc, pSize);
Point::Add(pArray[1], wArray[1][i], pSrc, pSize);
Point::Add(pArray[2], wArray[2][i], pSrc, pSize);
}
}
|
O2
|
c
|
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<2>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<float> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl 0x8(%rdi), %ebp
movslq 0xc(%rdi), %rcx
movq 0x28(%rdi), %r12
movq 0x20(%rdi), %r13
movq 0x10(%rdi), %rax
movq (%rdi), %r14
testq %rax, %rax
movq %rcx, (%rsp)
je 0xa7280
movslq (%rax), %rax
imulq %rcx, %rax
leaq (%r14,%rax,8), %r14
movq (%r13), %rdi
movq (%r12), %rax
movsd (%rax), %xmm0
movq %r14, %rsi
movl %ebp, %edx
callq 0x50e10
movq 0x8(%r13), %rdi
movq 0x8(%r12), %rax
movsd (%rax), %xmm0
movq %r14, %rsi
movl %ebp, %edx
callq 0x50e10
movq 0x10(%r13), %rdi
movq 0x10(%r12), %rax
movsd (%rax), %xmm0
movq %r14, %rsi
movl %ebp, %edx
callq 0x50e10
pushq $0x1
popq %r15
movslq 0x18(%rbx), %rax
cmpq %rax, %r15
jge 0xa7343
movq 0x10(%rbx), %rax
testq %rax, %rax
je 0xa72ec
movslq (%rax,%r15,4), %r14
imulq (%rsp), %r14
shlq $0x3, %r14
addq (%rbx), %r14
jmp 0xa72f4
movq (%rsp), %rax
leaq (%r14,%rax,8), %r14
movq (%r13), %rdi
movq (%r12), %rax
movsd (%rax,%r15,8), %xmm0
movq %r14, %rsi
movl %ebp, %edx
callq 0x527e0
movq 0x8(%r13), %rdi
movq 0x8(%r12), %rax
movsd (%rax,%r15,8), %xmm0
movq %r14, %rsi
movl %ebp, %edx
callq 0x527e0
movq 0x10(%r13), %rdi
movq 0x10(%r12), %rax
movsd (%rax,%r15,8), %xmm0
movq %r14, %rsi
movl %ebp, %edx
callq 0x527e0
incq %r15
jmp 0xa72c8
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
|
_ZN10OpenSubdiv6v3_6_03Bfr6points8Combine3IdE5applyILi4EEEvRKNS2_27CommonCombinationParametersIdEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rdi
mov ebp, [rdi+8]
movsxd rcx, dword ptr [rdi+0Ch]
mov r12, [rdi+28h]
mov r13, [rdi+20h]
mov rax, [rdi+10h]
mov r14, [rdi]
test rax, rax
mov [rsp+38h+var_38], rcx
jz short loc_A7280
movsxd rax, dword ptr [rax]
imul rax, rcx
lea r14, [r14+rax*8]
loc_A7280:
mov rdi, [r13+0]
mov rax, [r12]
movsd xmm0, qword ptr [rax]
mov rsi, r14
mov edx, ebp
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIdLi4EE3SetEPddPKdi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Set(double *,double,double const*,int)
mov rdi, [r13+8]
mov rax, [r12+8]
movsd xmm0, qword ptr [rax]
mov rsi, r14
mov edx, ebp
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIdLi4EE3SetEPddPKdi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Set(double *,double,double const*,int)
mov rdi, [r13+10h]
mov rax, [r12+10h]
movsd xmm0, qword ptr [rax]
mov rsi, r14
mov edx, ebp
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIdLi4EE3SetEPddPKdi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Set(double *,double,double const*,int)
push 1
pop r15
loc_A72C8:
movsxd rax, dword ptr [rbx+18h]
cmp r15, rax
jge short loc_A7343
mov rax, [rbx+10h]
test rax, rax
jz short loc_A72EC
movsxd r14, dword ptr [rax+r15*4]
imul r14, [rsp+38h+var_38]
shl r14, 3
add r14, [rbx]
jmp short loc_A72F4
loc_A72EC:
mov rax, [rsp+38h+var_38]
lea r14, [r14+rax*8]
loc_A72F4:
mov rdi, [r13+0]
mov rax, [r12]
movsd xmm0, qword ptr [rax+r15*8]
mov rsi, r14
mov edx, ebp
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIdLi4EE3AddEPddPKdi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Add(double *,double,double const*,int)
mov rdi, [r13+8]
mov rax, [r12+8]
movsd xmm0, qword ptr [rax+r15*8]
mov rsi, r14
mov edx, ebp
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIdLi4EE3AddEPddPKdi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Add(double *,double,double const*,int)
mov rdi, [r13+10h]
mov rax, [r12+10h]
movsd xmm0, qword ptr [rax+r15*8]
mov rsi, r14
mov edx, ebp
call __ZN10OpenSubdiv6v3_6_03Bfr6points12PointBuilderIdLi4EE3AddEPddPKdi; OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Add(double *,double,double const*,int)
inc r15
jmp short loc_A72C8
loc_A7343:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
|
long long OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<4>(long long *a1)
{
unsigned int v1; // ebp
double **v2; // r12
_QWORD *v3; // r13
int *v4; // rax
long long v5; // r14
long long i; // r15
long long result; // rax
long long v8; // rax
long long v9; // [rsp+0h] [rbp-38h]
v1 = *((_DWORD *)a1 + 2);
v2 = (double **)a1[5];
v3 = (_QWORD *)a1[4];
v4 = (int *)a1[2];
v5 = *a1;
v9 = *((int *)a1 + 3);
if ( v4 )
v5 += 8 * *((int *)a1 + 3) * (long long)*v4;
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Set(*v3, v5, **v2);
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Set(v3[1], v5, *v2[1]);
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Set(v3[2], v5, *v2[2]);
for ( i = 1LL; ; ++i )
{
result = *((int *)a1 + 6);
if ( i >= result )
break;
v8 = a1[2];
if ( v8 )
v5 = *a1 + 8 * v9 * *(int *)(v8 + 4 * i);
else
v5 += 8 * v9;
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Add(*v3, v5, v1, (*v2)[i]);
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Add(v3[1], v5, v1, v2[1][i]);
OpenSubdiv::v3_6_0::Bfr::points::PointBuilder<double,4>::Add(v3[2], v5, v1, v2[2][i]);
}
return result;
}
|
apply<4>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV EBP,dword ptr [RDI + 0x8]
MOVSXD RCX,dword ptr [RDI + 0xc]
MOV R12,qword ptr [RDI + 0x28]
MOV R13,qword ptr [RDI + 0x20]
MOV RAX,qword ptr [RDI + 0x10]
MOV R14,qword ptr [RDI]
TEST RAX,RAX
MOV qword ptr [RSP],RCX
JZ 0x001a7280
MOVSXD RAX,dword ptr [RAX]
IMUL RAX,RCX
LEA R14,[R14 + RAX*0x8]
LAB_001a7280:
MOV RDI,qword ptr [R13]
MOV RAX,qword ptr [R12]
MOVSD XMM0,qword ptr [RAX]
MOV RSI,R14
MOV EDX,EBP
CALL 0x00150e10
MOV RDI,qword ptr [R13 + 0x8]
MOV RAX,qword ptr [R12 + 0x8]
MOVSD XMM0,qword ptr [RAX]
MOV RSI,R14
MOV EDX,EBP
CALL 0x00150e10
MOV RDI,qword ptr [R13 + 0x10]
MOV RAX,qword ptr [R12 + 0x10]
MOVSD XMM0,qword ptr [RAX]
MOV RSI,R14
MOV EDX,EBP
CALL 0x00150e10
PUSH 0x1
POP R15
LAB_001a72c8:
MOVSXD RAX,dword ptr [RBX + 0x18]
CMP R15,RAX
JGE 0x001a7343
MOV RAX,qword ptr [RBX + 0x10]
TEST RAX,RAX
JZ 0x001a72ec
MOVSXD R14,dword ptr [RAX + R15*0x4]
IMUL R14,qword ptr [RSP]
SHL R14,0x3
ADD R14,qword ptr [RBX]
JMP 0x001a72f4
LAB_001a72ec:
MOV RAX,qword ptr [RSP]
LEA R14,[R14 + RAX*0x8]
LAB_001a72f4:
MOV RDI,qword ptr [R13]
MOV RAX,qword ptr [R12]
MOVSD XMM0,qword ptr [RAX + R15*0x8]
MOV RSI,R14
MOV EDX,EBP
CALL 0x001527e0
MOV RDI,qword ptr [R13 + 0x8]
MOV RAX,qword ptr [R12 + 0x8]
MOVSD XMM0,qword ptr [RAX + R15*0x8]
MOV RSI,R14
MOV EDX,EBP
CALL 0x001527e0
MOV RDI,qword ptr [R13 + 0x10]
MOV RAX,qword ptr [R12 + 0x10]
MOVSD XMM0,qword ptr [RAX + R15*0x8]
MOV RSI,R14
MOV EDX,EBP
CALL 0x001527e0
INC R15
JMP 0x001a72c8
LAB_001a7343:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* void
OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<4>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<double>
const&) */
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<4>
(CommonCombinationParameters *param_1)
{
int iVar1;
long *plVar2;
int8 *puVar3;
long lVar4;
double *pdVar5;
long lVar6;
iVar1 = *(int *)(param_1 + 8);
lVar4 = (long)*(int *)(param_1 + 0xc);
plVar2 = *(long **)(param_1 + 0x28);
puVar3 = *(int8 **)(param_1 + 0x20);
pdVar5 = *(double **)param_1;
if (*(int **)(param_1 + 0x10) != (int *)0x0) {
pdVar5 = pdVar5 + **(int **)(param_1 + 0x10) * lVar4;
}
PointBuilder<double,4>::Set((double *)*puVar3,*(double *)*plVar2,pdVar5,iVar1);
PointBuilder<double,4>::Set((double *)puVar3[1],*(double *)plVar2[1],pdVar5,iVar1);
PointBuilder<double,4>::Set((double *)puVar3[2],*(double *)plVar2[2],pdVar5,iVar1);
for (lVar6 = 1; lVar6 < *(int *)(param_1 + 0x18); lVar6 = lVar6 + 1) {
if (*(long *)(param_1 + 0x10) == 0) {
pdVar5 = pdVar5 + lVar4;
}
else {
pdVar5 = (double *)
(*(int *)(*(long *)(param_1 + 0x10) + lVar6 * 4) * lVar4 * 8 + *(long *)param_1);
}
PointBuilder<double,4>::Add((double *)*puVar3,*(double *)(*plVar2 + lVar6 * 8),pdVar5,iVar1);
PointBuilder<double,4>::Add((double *)puVar3[1],*(double *)(plVar2[1] + lVar6 * 8),pdVar5,iVar1)
;
PointBuilder<double,4>::Add((double *)puVar3[2],*(double *)(plVar2[2] + lVar6 * 8),pdVar5,iVar1)
;
}
return;
}
|
|
9,966 |
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<2>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<float> const&)
|
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/../bfr/pointOperations.h
|
static void apply(Parameters const & args) {
typedef struct PointBuilder<REAL,SIZE> Point;
int pSize = args.pointSize;
int pStride = args.pointStride;
REAL const * const * wArray = args.weightArray;
REAL ** pArray = args.resultArray;
//
// Apply each successive control point to all derivatives at once,
// rather than computing each derivate independently:
//
REAL const * pSrc = (args.srcIndices == 0) ? args.pointData :
(args.pointData + pStride * args.srcIndices[0]);
Point::Set(pArray[0], wArray[0][0], pSrc, pSize);
Point::Set(pArray[1], wArray[1][0], pSrc, pSize);
Point::Set(pArray[2], wArray[2][0], pSrc, pSize);
for (int i = 1; i < args.srcCount; ++i) {
pSrc = (args.srcIndices == 0) ? (pSrc + pStride) :
(args.pointData + pStride * args.srcIndices[i]);
Point::Add(pArray[0], wArray[0][i], pSrc, pSize);
Point::Add(pArray[1], wArray[1][i], pSrc, pSize);
Point::Add(pArray[2], wArray[2][i], pSrc, pSize);
}
}
|
O3
|
c
|
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<float>::apply<2>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<float> const&):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl 0x8(%rdi), %eax
movslq 0xc(%rdi), %rcx
movq 0x28(%rdi), %r14
movq 0x20(%rdi), %rbx
movq 0x10(%rdi), %rdx
movq (%rdi), %rsi
testq %rdx, %rdx
je 0x9db8d
movslq (%rdx), %r8
imulq %rcx, %r8
leaq (%rsi,%r8,8), %rsi
movq (%rbx), %r8
movq (%r14), %r9
testl %eax, %eax
jle 0x9dc09
movsd (%r9), %xmm0
xorl %r10d, %r10d
movsd (%rsi,%r10,8), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, (%r8,%r10,8)
incq %r10
cmpq %r10, %rax
jne 0x9db9f
movq 0x8(%rbx), %r10
movq 0x8(%r14), %r11
movsd (%r11), %xmm0
xorl %r15d, %r15d
movsd (%rsi,%r15,8), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, (%r10,%r15,8)
incq %r15
cmpq %r15, %rax
jne 0x9dbc7
movq 0x10(%rbx), %rbx
movq 0x10(%r14), %r14
movsd (%r14), %xmm0
xorl %r15d, %r15d
movsd (%rsi,%r15,8), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, (%rbx,%r15,8)
incq %r15
cmpq %r15, %rax
jne 0x9dbef
jmp 0x9dc19
movq 0x8(%rbx), %r10
movq 0x10(%rbx), %rbx
movq 0x8(%r14), %r11
movq 0x10(%r14), %r14
movslq 0x18(%rdi), %r15
cmpq $0x2, %r15
jl 0x9dccc
movq (%rdi), %rdi
movl $0x1, %r12d
testq %rdx, %rdx
je 0x9dc43
movslq (%rdx,%r12,4), %rsi
imulq %rcx, %rsi
leaq (%rdi,%rsi,8), %rsi
jmp 0x9dc47
leaq (%rsi,%rcx,8), %rsi
testl %eax, %eax
jle 0x9dcc0
movsd (%r9,%r12,8), %xmm0
xorl %r13d, %r13d
movsd (%rsi,%r13,8), %xmm1
mulsd %xmm0, %xmm1
addsd (%r8,%r13,8), %xmm1
movsd %xmm1, (%r8,%r13,8)
incq %r13
cmpq %r13, %rax
jne 0x9dc54
movsd (%r11,%r12,8), %xmm0
xorl %r13d, %r13d
movsd (%rsi,%r13,8), %xmm1
mulsd %xmm0, %xmm1
addsd (%r10,%r13,8), %xmm1
movsd %xmm1, (%r10,%r13,8)
incq %r13
cmpq %r13, %rax
jne 0x9dc7b
movsd (%r14,%r12,8), %xmm0
xorl %r13d, %r13d
movsd (%rsi,%r13,8), %xmm1
mulsd %xmm0, %xmm1
addsd (%rbx,%r13,8), %xmm1
movsd %xmm1, (%rbx,%r13,8)
incq %r13
cmpq %r13, %rax
jne 0x9dca2
incq %r12
cmpq %r15, %r12
jne 0x9dc30
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
|
_ZN10OpenSubdiv6v3_6_03Bfr6points8Combine3IdE5applyILi0EEEvRKNS2_27CommonCombinationParametersIdEE:
push r15
push r14
push r13
push r12
push rbx
mov eax, [rdi+8]
movsxd rcx, dword ptr [rdi+0Ch]
mov r14, [rdi+28h]
mov rbx, [rdi+20h]
mov rdx, [rdi+10h]
mov rsi, [rdi]
test rdx, rdx
jz short loc_9DB8D
movsxd r8, dword ptr [rdx]
imul r8, rcx
lea rsi, [rsi+r8*8]
loc_9DB8D:
mov r8, [rbx]
mov r9, [r14]
test eax, eax
jle short loc_9DC09
movsd xmm0, qword ptr [r9]
xor r10d, r10d
loc_9DB9F:
movsd xmm1, qword ptr [rsi+r10*8]
mulsd xmm1, xmm0
movsd qword ptr [r8+r10*8], xmm1
inc r10
cmp rax, r10
jnz short loc_9DB9F
mov r10, [rbx+8]
mov r11, [r14+8]
movsd xmm0, qword ptr [r11]
xor r15d, r15d
loc_9DBC7:
movsd xmm1, qword ptr [rsi+r15*8]
mulsd xmm1, xmm0
movsd qword ptr [r10+r15*8], xmm1
inc r15
cmp rax, r15
jnz short loc_9DBC7
mov rbx, [rbx+10h]
mov r14, [r14+10h]
movsd xmm0, qword ptr [r14]
xor r15d, r15d
loc_9DBEF:
movsd xmm1, qword ptr [rsi+r15*8]
mulsd xmm1, xmm0
movsd qword ptr [rbx+r15*8], xmm1
inc r15
cmp rax, r15
jnz short loc_9DBEF
jmp short loc_9DC19
loc_9DC09:
mov r10, [rbx+8]
mov rbx, [rbx+10h]
mov r11, [r14+8]
mov r14, [r14+10h]
loc_9DC19:
movsxd r15, dword ptr [rdi+18h]
cmp r15, 2
jl loc_9DCCC
mov rdi, [rdi]
mov r12d, 1
loc_9DC30:
test rdx, rdx
jz short loc_9DC43
movsxd rsi, dword ptr [rdx+r12*4]
imul rsi, rcx
lea rsi, [rdi+rsi*8]
jmp short loc_9DC47
loc_9DC43:
lea rsi, [rsi+rcx*8]
loc_9DC47:
test eax, eax
jle short loc_9DCC0
movsd xmm0, qword ptr [r9+r12*8]
xor r13d, r13d
loc_9DC54:
movsd xmm1, qword ptr [rsi+r13*8]
mulsd xmm1, xmm0
addsd xmm1, qword ptr [r8+r13*8]
movsd qword ptr [r8+r13*8], xmm1
inc r13
cmp rax, r13
jnz short loc_9DC54
movsd xmm0, qword ptr [r11+r12*8]
xor r13d, r13d
loc_9DC7B:
movsd xmm1, qword ptr [rsi+r13*8]
mulsd xmm1, xmm0
addsd xmm1, qword ptr [r10+r13*8]
movsd qword ptr [r10+r13*8], xmm1
inc r13
cmp rax, r13
jnz short loc_9DC7B
movsd xmm0, qword ptr [r14+r12*8]
xor r13d, r13d
loc_9DCA2:
movsd xmm1, qword ptr [rsi+r13*8]
mulsd xmm1, xmm0
addsd xmm1, qword ptr [rbx+r13*8]
movsd qword ptr [rbx+r13*8], xmm1
inc r13
cmp rax, r13
jnz short loc_9DCA2
loc_9DCC0:
inc r12
cmp r12, r15
jnz loc_9DC30
loc_9DCCC:
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
|
long long OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<0>(long long *a1)
{
long long result; // rax
long long v2; // rcx
double **v3; // r14
long long *v4; // rbx
int *v5; // rdx
long long v6; // rsi
long long v7; // r8
double *v8; // r9
double v9; // xmm0_8
long long i; // r10
long long v11; // r10
double *v12; // r11
double v13; // xmm0_8
long long j; // r15
long long v15; // rbx
double *v16; // r14
double v17; // xmm0_8
long long k; // r15
long long v19; // r15
long long v20; // rdi
long long m; // r12
double v22; // xmm0_8
long long n; // r13
double v24; // xmm0_8
long long ii; // r13
double v26; // xmm0_8
long long jj; // r13
result = *((unsigned int *)a1 + 2);
v2 = *((int *)a1 + 3);
v3 = (double **)a1[5];
v4 = (long long *)a1[4];
v5 = (int *)a1[2];
v6 = *a1;
if ( v5 )
v6 += 8 * v2 * *v5;
v7 = *v4;
v8 = *v3;
if ( (int)result <= 0 )
{
v11 = v4[1];
v15 = v4[2];
v12 = v3[1];
v16 = v3[2];
}
else
{
v9 = *v8;
for ( i = 0LL; i != result; ++i )
*(double *)(v7 + 8 * i) = *(double *)(v6 + 8 * i) * v9;
v11 = v4[1];
v12 = v3[1];
v13 = *v12;
for ( j = 0LL; j != result; ++j )
*(double *)(v11 + 8 * j) = *(double *)(v6 + 8 * j) * v13;
v15 = v4[2];
v16 = v3[2];
v17 = *v16;
for ( k = 0LL; k != result; ++k )
*(double *)(v15 + 8 * k) = *(double *)(v6 + 8 * k) * v17;
}
v19 = *((int *)a1 + 6);
if ( v19 >= 2 )
{
v20 = *a1;
for ( m = 1LL; m != v19; ++m )
{
if ( v5 )
v6 = v20 + 8 * v2 * v5[m];
else
v6 += 8 * v2;
if ( (int)result > 0 )
{
v22 = v8[m];
for ( n = 0LL; n != result; ++n )
*(double *)(v7 + 8 * n) = *(double *)(v6 + 8 * n) * v22 + *(double *)(v7 + 8 * n);
v24 = v12[m];
for ( ii = 0LL; ii != result; ++ii )
*(double *)(v11 + 8 * ii) = *(double *)(v6 + 8 * ii) * v24 + *(double *)(v11 + 8 * ii);
v26 = v16[m];
for ( jj = 0LL; jj != result; ++jj )
*(double *)(v15 + 8 * jj) = *(double *)(v6 + 8 * jj) * v26 + *(double *)(v15 + 8 * jj);
}
}
}
return result;
}
|
apply<0>:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV EAX,dword ptr [RDI + 0x8]
MOVSXD RCX,dword ptr [RDI + 0xc]
MOV R14,qword ptr [RDI + 0x28]
MOV RBX,qword ptr [RDI + 0x20]
MOV RDX,qword ptr [RDI + 0x10]
MOV RSI,qword ptr [RDI]
TEST RDX,RDX
JZ 0x0019db8d
MOVSXD R8,dword ptr [RDX]
IMUL R8,RCX
LEA RSI,[RSI + R8*0x8]
LAB_0019db8d:
MOV R8,qword ptr [RBX]
MOV R9,qword ptr [R14]
TEST EAX,EAX
JLE 0x0019dc09
MOVSD XMM0,qword ptr [R9]
XOR R10D,R10D
LAB_0019db9f:
MOVSD XMM1,qword ptr [RSI + R10*0x8]
MULSD XMM1,XMM0
MOVSD qword ptr [R8 + R10*0x8],XMM1
INC R10
CMP RAX,R10
JNZ 0x0019db9f
MOV R10,qword ptr [RBX + 0x8]
MOV R11,qword ptr [R14 + 0x8]
MOVSD XMM0,qword ptr [R11]
XOR R15D,R15D
LAB_0019dbc7:
MOVSD XMM1,qword ptr [RSI + R15*0x8]
MULSD XMM1,XMM0
MOVSD qword ptr [R10 + R15*0x8],XMM1
INC R15
CMP RAX,R15
JNZ 0x0019dbc7
MOV RBX,qword ptr [RBX + 0x10]
MOV R14,qword ptr [R14 + 0x10]
MOVSD XMM0,qword ptr [R14]
XOR R15D,R15D
LAB_0019dbef:
MOVSD XMM1,qword ptr [RSI + R15*0x8]
MULSD XMM1,XMM0
MOVSD qword ptr [RBX + R15*0x8],XMM1
INC R15
CMP RAX,R15
JNZ 0x0019dbef
JMP 0x0019dc19
LAB_0019dc09:
MOV R10,qword ptr [RBX + 0x8]
MOV RBX,qword ptr [RBX + 0x10]
MOV R11,qword ptr [R14 + 0x8]
MOV R14,qword ptr [R14 + 0x10]
LAB_0019dc19:
MOVSXD R15,dword ptr [RDI + 0x18]
CMP R15,0x2
JL 0x0019dccc
MOV RDI,qword ptr [RDI]
MOV R12D,0x1
LAB_0019dc30:
TEST RDX,RDX
JZ 0x0019dc43
MOVSXD RSI,dword ptr [RDX + R12*0x4]
IMUL RSI,RCX
LEA RSI,[RDI + RSI*0x8]
JMP 0x0019dc47
LAB_0019dc43:
LEA RSI,[RSI + RCX*0x8]
LAB_0019dc47:
TEST EAX,EAX
JLE 0x0019dcc0
MOVSD XMM0,qword ptr [R9 + R12*0x8]
XOR R13D,R13D
LAB_0019dc54:
MOVSD XMM1,qword ptr [RSI + R13*0x8]
MULSD XMM1,XMM0
ADDSD XMM1,qword ptr [R8 + R13*0x8]
MOVSD qword ptr [R8 + R13*0x8],XMM1
INC R13
CMP RAX,R13
JNZ 0x0019dc54
MOVSD XMM0,qword ptr [R11 + R12*0x8]
XOR R13D,R13D
LAB_0019dc7b:
MOVSD XMM1,qword ptr [RSI + R13*0x8]
MULSD XMM1,XMM0
ADDSD XMM1,qword ptr [R10 + R13*0x8]
MOVSD qword ptr [R10 + R13*0x8],XMM1
INC R13
CMP RAX,R13
JNZ 0x0019dc7b
MOVSD XMM0,qword ptr [R14 + R12*0x8]
XOR R13D,R13D
LAB_0019dca2:
MOVSD XMM1,qword ptr [RSI + R13*0x8]
MULSD XMM1,XMM0
ADDSD XMM1,qword ptr [RBX + R13*0x8]
MOVSD qword ptr [RBX + R13*0x8],XMM1
INC R13
CMP RAX,R13
JNZ 0x0019dca2
LAB_0019dcc0:
INC R12
CMP R12,R15
JNZ 0x0019dc30
LAB_0019dccc:
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
/* void
OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<0>(OpenSubdiv::v3_6_0::Bfr::points::CommonCombinationParameters<double>
const&) */
void OpenSubdiv::v3_6_0::Bfr::points::Combine3<double>::apply<0>
(CommonCombinationParameters *param_1)
{
double dVar1;
uint uVar2;
int iVar3;
int8 *puVar4;
long *plVar5;
int *piVar6;
long lVar7;
double *pdVar8;
long lVar9;
ulong uVar10;
long lVar11;
long lVar12;
long lVar13;
ulong uVar14;
long lVar15;
double *pdVar16;
long lVar17;
double *pdVar18;
uVar2 = *(uint *)(param_1 + 8);
uVar10 = (ulong)uVar2;
lVar11 = (long)*(int *)(param_1 + 0xc);
puVar4 = *(int8 **)(param_1 + 0x28);
plVar5 = *(long **)(param_1 + 0x20);
piVar6 = *(int **)(param_1 + 0x10);
lVar13 = *(long *)param_1;
if (piVar6 != (int *)0x0) {
lVar13 = lVar13 + *piVar6 * lVar11 * 8;
}
lVar7 = *plVar5;
pdVar8 = (double *)*puVar4;
if ((int)uVar2 < 1) {
lVar15 = plVar5[1];
lVar12 = plVar5[2];
pdVar16 = (double *)puVar4[1];
pdVar18 = (double *)puVar4[2];
}
else {
dVar1 = *pdVar8;
uVar14 = 0;
do {
*(double *)(lVar7 + uVar14 * 8) = *(double *)(lVar13 + uVar14 * 8) * dVar1;
uVar14 = uVar14 + 1;
} while (uVar10 != uVar14);
lVar15 = plVar5[1];
pdVar16 = (double *)puVar4[1];
dVar1 = *pdVar16;
uVar14 = 0;
do {
*(double *)(lVar15 + uVar14 * 8) = *(double *)(lVar13 + uVar14 * 8) * dVar1;
uVar14 = uVar14 + 1;
} while (uVar10 != uVar14);
lVar12 = plVar5[2];
pdVar18 = (double *)puVar4[2];
dVar1 = *pdVar18;
uVar14 = 0;
do {
*(double *)(lVar12 + uVar14 * 8) = *(double *)(lVar13 + uVar14 * 8) * dVar1;
uVar14 = uVar14 + 1;
} while (uVar10 != uVar14);
}
iVar3 = *(int *)(param_1 + 0x18);
if (1 < (long)iVar3) {
lVar9 = *(long *)param_1;
lVar17 = 1;
do {
if (piVar6 == (int *)0x0) {
lVar13 = lVar13 + lVar11 * 8;
}
else {
lVar13 = lVar9 + piVar6[lVar17] * lVar11 * 8;
}
if (0 < (int)uVar2) {
dVar1 = pdVar8[lVar17];
uVar14 = 0;
do {
*(double *)(lVar7 + uVar14 * 8) =
*(double *)(lVar13 + uVar14 * 8) * dVar1 + *(double *)(lVar7 + uVar14 * 8);
uVar14 = uVar14 + 1;
} while (uVar10 != uVar14);
dVar1 = pdVar16[lVar17];
uVar14 = 0;
do {
*(double *)(lVar15 + uVar14 * 8) =
*(double *)(lVar13 + uVar14 * 8) * dVar1 + *(double *)(lVar15 + uVar14 * 8);
uVar14 = uVar14 + 1;
} while (uVar10 != uVar14);
dVar1 = pdVar18[lVar17];
uVar14 = 0;
do {
*(double *)(lVar12 + uVar14 * 8) =
*(double *)(lVar13 + uVar14 * 8) * dVar1 + *(double *)(lVar12 + uVar14 * 8);
uVar14 = uVar14 + 1;
} while (uVar10 != uVar14);
}
lVar17 = lVar17 + 1;
} while (lVar17 != iVar3);
}
return;
}
|
|
9,967 |
my_caseup_utf16
|
eloqsql/strings/ctype-ucs2.c
|
static size_t
my_caseup_utf16(CHARSET_INFO *cs, const char *src, size_t srclen,
char *dst, size_t dstlen)
{
my_wc_t wc;
my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc;
my_charset_conv_wc_mb wc_mb= cs->cset->wc_mb;
int res;
const char *srcend= src + srclen;
char *dstend= dst + dstlen;
MY_UNICASE_INFO *uni_plane= cs->caseinfo;
DBUG_ASSERT(srclen <= dstlen);
while ((src < srcend) &&
(res= mb_wc(cs, &wc, (uchar *) src, (uchar *) srcend)) > 0)
{
my_toupper_utf16(uni_plane, &wc);
if (res != wc_mb(cs, wc, (uchar *) dst, (uchar *) dstend))
break;
src+= res;
dst+= res;
}
return srclen;
}
|
O0
|
c
|
my_caseup_utf16:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x30(%rax), %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rax
addq -0x18(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x20(%rbp), %rax
addq -0x28(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x8(%rbp), %rax
movq 0x78(%rax), %rax
movq %rax, -0x60(%rbp)
jmp 0x6adf8
jmp 0x6adfa
movq -0x10(%rbp), %rcx
xorl %eax, %eax
cmpq -0x50(%rbp), %rcx
movb %al, -0x61(%rbp)
jae 0x6ae2b
movq -0x38(%rbp), %rax
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x50(%rbp), %rcx
leaq -0x30(%rbp), %rsi
callq *%rax
movl %eax, -0x44(%rbp)
cmpl $0x0, %eax
setg %al
movb %al, -0x61(%rbp)
movb -0x61(%rbp), %al
testb $0x1, %al
jne 0x6ae34
jmp 0x6ae8f
movq -0x60(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x6e380
movl -0x44(%rbp), %eax
movl %eax, -0x68(%rbp)
movq -0x40(%rbp), %rax
movq -0x8(%rbp), %rdi
movq -0x30(%rbp), %rsi
movq -0x20(%rbp), %rdx
movq -0x58(%rbp), %rcx
callq *%rax
movl %eax, %ecx
movl -0x68(%rbp), %eax
cmpl %ecx, %eax
je 0x6ae68
jmp 0x6ae8f
movl -0x44(%rbp), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
movl -0x44(%rbp), %ecx
movq -0x20(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
jmp 0x6adfa
movq -0x18(%rbp), %rax
addq $0x70, %rsp
popq %rbp
retq
nopl (%rax)
|
my_caseup_utf16:
push rbp
mov rbp, rsp
sub rsp, 70h
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 rax, [rax+0B8h]
mov rax, [rax+28h]
mov [rbp+var_38], rax
mov rax, [rbp+var_8]
mov rax, [rax+0B8h]
mov rax, [rax+30h]
mov [rbp+var_40], rax
mov rax, [rbp+var_10]
add rax, [rbp+var_18]
mov [rbp+var_50], rax
mov rax, [rbp+var_20]
add rax, [rbp+var_28]
mov [rbp+var_58], rax
mov rax, [rbp+var_8]
mov rax, [rax+78h]
mov [rbp+var_60], rax
jmp short $+2
loc_6ADF8:
jmp short $+2
loc_6ADFA:
mov rcx, [rbp+var_10]
xor eax, eax
cmp rcx, [rbp+var_50]
mov [rbp+var_61], al
jnb short loc_6AE2B
mov rax, [rbp+var_38]
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov rcx, [rbp+var_50]
lea rsi, [rbp+var_30]
call rax
mov [rbp+var_44], eax
cmp eax, 0
setnle al
mov [rbp+var_61], al
loc_6AE2B:
mov al, [rbp+var_61]
test al, 1
jnz short loc_6AE34
jmp short loc_6AE8F
loc_6AE34:
mov rdi, [rbp+var_60]
lea rsi, [rbp+var_30]
call my_toupper_utf16
mov eax, [rbp+var_44]
mov [rbp+var_68], eax
mov rax, [rbp+var_40]
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_30]
mov rdx, [rbp+var_20]
mov rcx, [rbp+var_58]
call rax
mov ecx, eax
mov eax, [rbp+var_68]
cmp eax, ecx
jz short loc_6AE68
jmp short loc_6AE8F
loc_6AE68:
mov ecx, [rbp+var_44]
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
mov ecx, [rbp+var_44]
mov rax, [rbp+var_20]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_20], rax
jmp loc_6ADFA
loc_6AE8F:
mov rax, [rbp+var_18]
add rsp, 70h
pop rbp
retn
|
long long my_caseup_utf16(long long a1, unsigned long long a2, long long a3, long long a4, long long a5)
{
bool v6; // [rsp+Fh] [rbp-61h]
long long v7; // [rsp+10h] [rbp-60h]
long long v8; // [rsp+18h] [rbp-58h]
unsigned long long v9; // [rsp+20h] [rbp-50h]
int v10; // [rsp+2Ch] [rbp-44h]
unsigned int ( *v11)(long long, _QWORD, long long, long long); // [rsp+30h] [rbp-40h]
long long ( *v12)(long long, _QWORD *, unsigned long long, unsigned long long); // [rsp+38h] [rbp-38h]
_QWORD v13[2]; // [rsp+40h] [rbp-30h] BYREF
long long v14; // [rsp+50h] [rbp-20h]
long long v15; // [rsp+58h] [rbp-18h]
unsigned long long v16; // [rsp+60h] [rbp-10h]
long long v17; // [rsp+68h] [rbp-8h]
v17 = a1;
v16 = a2;
v15 = a3;
v14 = a4;
v13[1] = a5;
v12 = *(long long ( **)(long long, _QWORD *, unsigned long long, unsigned long long))(*(_QWORD *)(a1 + 184) + 40LL);
v11 = *(unsigned int ( **)(long long, _QWORD, long long, long long))(*(_QWORD *)(a1 + 184) + 48LL);
v9 = a3 + a2;
v8 = a5 + a4;
v7 = *(_QWORD *)(a1 + 120);
while ( 1 )
{
v6 = 0;
if ( v16 < v9 )
{
v10 = v12(v17, v13, v16, v9);
v6 = v10 > 0;
}
if ( !v6 )
break;
my_toupper_utf16(v7, v13);
if ( v10 != v11(v17, v13[0], v14, v8) )
break;
v16 += v10;
v14 += v10;
}
return v15;
}
|
my_caseup_utf16:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x70
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 RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0x30]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x78]
MOV qword ptr [RBP + -0x60],RAX
JMP 0x0016adf8
LAB_0016adf8:
JMP 0x0016adfa
LAB_0016adfa:
MOV RCX,qword ptr [RBP + -0x10]
XOR EAX,EAX
CMP RCX,qword ptr [RBP + -0x50]
MOV byte ptr [RBP + -0x61],AL
JNC 0x0016ae2b
MOV RAX,qword ptr [RBP + -0x38]
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x50]
LEA RSI,[RBP + -0x30]
CALL RAX
MOV dword ptr [RBP + -0x44],EAX
CMP EAX,0x0
SETG AL
MOV byte ptr [RBP + -0x61],AL
LAB_0016ae2b:
MOV AL,byte ptr [RBP + -0x61]
TEST AL,0x1
JNZ 0x0016ae34
JMP 0x0016ae8f
LAB_0016ae34:
MOV RDI,qword ptr [RBP + -0x60]
LEA RSI,[RBP + -0x30]
CALL 0x0016e380
MOV EAX,dword ptr [RBP + -0x44]
MOV dword ptr [RBP + -0x68],EAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x30]
MOV RDX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x58]
CALL RAX
MOV ECX,EAX
MOV EAX,dword ptr [RBP + -0x68]
CMP EAX,ECX
JZ 0x0016ae68
JMP 0x0016ae8f
LAB_0016ae68:
MOV ECX,dword ptr [RBP + -0x44]
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
MOV ECX,dword ptr [RBP + -0x44]
MOV RAX,qword ptr [RBP + -0x20]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
JMP 0x0016adfa
LAB_0016ae8f:
MOV RAX,qword ptr [RBP + -0x18]
ADD RSP,0x70
POP RBP
RET
|
long my_caseup_utf16(long param_1,ulong param_2,long param_3,long param_4,long param_5)
{
code *pcVar1;
code *pcVar2;
int8 uVar3;
bool bVar4;
int iVar5;
int local_4c;
int8 local_38;
long local_30;
long local_28;
long local_20;
ulong local_18;
long local_10;
pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28);
pcVar2 = *(code **)(*(long *)(param_1 + 0xb8) + 0x30);
uVar3 = *(int8 *)(param_1 + 0x78);
local_30 = param_5;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
while( true ) {
bVar4 = false;
if (local_18 < param_2 + param_3) {
local_4c = (*pcVar1)(local_10,&local_38,local_18,param_2 + param_3);
bVar4 = 0 < local_4c;
}
if (!bVar4) break;
my_toupper_utf16(uVar3,&local_38);
iVar5 = (*pcVar2)(local_10,local_38,local_28,param_4 + param_5);
if (local_4c != iVar5) {
return local_20;
}
local_18 = local_18 + (long)local_4c;
local_28 = local_28 + local_4c;
}
return local_20;
}
|
|
9,968 |
Settings::setHeight(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
|
666mxvbee[P]BattleShip/lib/Settings/Settings.cpp
|
std::string Settings::setHeight(const std::string& N) {
std::lock_guard<std::mutex> lock(settings_mutex);
std::regex valid_number_regex("^\\d+$");
if (!std::regex_match(N, valid_number_regex)) {
return "failed";
}
uint64_t value = std::stoull(N);
height = value;
return "ok";
}
|
O0
|
cpp
|
Settings::setHeight(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x80(%rbp)
movq %rdi, %rax
movq %rax, -0x78(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x10(%rbp), %rsi
movq %rsi, -0x70(%rbp)
leaq -0x20(%rbp), %rdi
callq 0xb200
leaq 0x36875(%rip), %rsi # 0x4028f
leaq -0x40(%rbp), %rdi
movl $0x10, %edx
callq 0xb3a0
jmp 0x9a2a
movq -0x18(%rbp), %rdi
leaq -0x40(%rbp), %rsi
xorl %edx, %edx
callq 0xb440
movb %al, -0x81(%rbp)
jmp 0x9a41
movb -0x81(%rbp), %al
testb $0x1, %al
jne 0x9ac7
jmp 0x9a4d
leaq -0x4d(%rbp), %rdi
movq %rdi, -0x90(%rbp)
callq 0x7650
movq -0x80(%rbp), %rdi
movq -0x90(%rbp), %rdx
leaq 0x36819(%rip), %rsi # 0x40288
callq 0xb110
jmp 0x9a76
leaq -0x4d(%rbp), %rdi
callq 0x73d0
movl $0x1, -0x54(%rbp)
jmp 0x9b4b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x9b73
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x9b6a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x4d(%rbp), %rdi
callq 0x73d0
jmp 0x9b6a
movq -0x18(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
movl $0xa, %edx
callq 0xb490
movq %rax, -0x98(%rbp)
jmp 0x9ae2
movq -0x70(%rbp), %rax
movq -0x98(%rbp), %rcx
movq %rcx, -0x60(%rbp)
movq -0x60(%rbp), %rcx
movq %rcx, 0x50(%rax)
leaq -0x61(%rbp), %rdi
movq %rdi, -0xa0(%rbp)
callq 0x7650
movq -0x80(%rbp), %rdi
movq -0xa0(%rbp), %rdx
leaq 0x3676a(%rip), %rsi # 0x40285
callq 0xb110
jmp 0x9b22
leaq -0x61(%rbp), %rdi
callq 0x73d0
movl $0x1, -0x54(%rbp)
jmp 0x9b4b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x61(%rbp), %rdi
callq 0x73d0
jmp 0x9b6a
leaq -0x40(%rbp), %rdi
callq 0xb4d0
leaq -0x20(%rbp), %rdi
callq 0xb290
movq -0x78(%rbp), %rax
addq $0xa0, %rsp
popq %rbp
retq
leaq -0x40(%rbp), %rdi
callq 0xb4d0
leaq -0x20(%rbp), %rdi
callq 0xb290
movq -0x48(%rbp), %rdi
callq 0x7640
nopw %cs:(%rax,%rax)
|
_ZN8Settings9setHeightERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push rbp
mov rbp, rsp
sub rsp, 0A0h
mov [rbp+var_80], rdi
mov rax, rdi
mov [rbp+var_78], rax
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov rsi, [rbp+var_10]
mov [rbp+var_70], rsi
lea rdi, [rbp+var_20]
call _ZNSt10lock_guardISt5mutexEC2ERS0_; std::lock_guard<std::mutex>::lock_guard(std::mutex&)
lea rsi, aD; "^\\d+$"
lea rdi, [rbp+var_40]
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)
jmp short $+2
loc_9A2A:
mov rdi, [rbp+var_18]
lea rsi, [rbp+var_40]
xor edx, edx
call _ZSt11regex_matchISt11char_traitsIcESaIcEcNSt7__cxx1112regex_traitsIcEEEbRKNS3_12basic_stringIT1_T_T0_EERKNS3_11basic_regexIS7_T2_EENSt15regex_constants15match_flag_typeE; std::regex_match<std::char_traits<char>,std::allocator<char>,char,std::regex_traits<char>>(std::string const&,std::basic_regex<char,std::regex_traits<char>> const&,std::regex_constants::match_flag_type)
mov [rbp+var_81], al
jmp short $+2
loc_9A41:
mov al, [rbp+var_81]
test al, 1
jnz short loc_9AC7
jmp short $+2
loc_9A4D:
lea rdi, [rbp+var_4D]
mov [rbp+var_90], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rbp+var_80]
mov rdx, [rbp+var_90]
lea rsi, aFailed; "failed"
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_9A76:
lea rdi, [rbp+var_4D]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov [rbp+var_54], 1
jmp loc_9B4B
mov rcx, rax
mov eax, edx
mov [rbp+var_48], rcx
mov [rbp+var_4C], eax
jmp loc_9B73
mov rcx, rax
mov eax, edx
mov [rbp+var_48], rcx
mov [rbp+var_4C], eax
jmp loc_9B6A
mov rcx, rax
mov eax, edx
mov [rbp+var_48], rcx
mov [rbp+var_4C], eax
lea rdi, [rbp+var_4D]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp loc_9B6A
loc_9AC7:
mov rdi, [rbp+var_18]
xor eax, eax
mov esi, eax
mov edx, 0Ah
call _ZNSt7__cxx116stoullERKNS_12basic_stringIcSt11char_traitsIcESaIcEEEPmi; std::stoull(std::string const&,ulong *,int)
mov [rbp+var_98], rax
jmp short $+2
loc_9AE2:
mov rax, [rbp+var_70]
mov rcx, [rbp+var_98]
mov [rbp+var_60], rcx
mov rcx, [rbp+var_60]
mov [rax+50h], rcx
lea rdi, [rbp+var_61]
mov [rbp+var_A0], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdi, [rbp+var_80]
mov rdx, [rbp+var_A0]
lea rsi, aOk; "ok"
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_9B22:
lea rdi, [rbp+var_61]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov [rbp+var_54], 1
jmp short loc_9B4B
mov rcx, rax
mov eax, edx
mov [rbp+var_48], rcx
mov [rbp+var_4C], eax
lea rdi, [rbp+var_61]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_9B6A
loc_9B4B:
lea rdi, [rbp+var_40]
call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; std::basic_regex<char,std::regex_traits<char>>::~basic_regex()
lea rdi, [rbp+var_20]
call _ZNSt10lock_guardISt5mutexED2Ev; std::lock_guard<std::mutex>::~lock_guard()
mov rax, [rbp+var_78]
add rsp, 0A0h
pop rbp
retn
loc_9B6A:
lea rdi, [rbp+var_40]
call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; std::basic_regex<char,std::regex_traits<char>>::~basic_regex()
loc_9B73:
lea rdi, [rbp+var_20]
call _ZNSt10lock_guardISt5mutexED2Ev; std::lock_guard<std::mutex>::~lock_guard()
mov rdi, [rbp+var_48]
call __Unwind_Resume
|
long long Settings::setHeight(long long a1, long long a2, long long a3)
{
char v4; // [rsp+3Fh] [rbp-61h] BYREF
long long v5; // [rsp+40h] [rbp-60h]
int v6; // [rsp+4Ch] [rbp-54h]
char v7; // [rsp+53h] [rbp-4Dh] BYREF
_BYTE v8[32]; // [rsp+60h] [rbp-40h] BYREF
_BYTE v9[8]; // [rsp+80h] [rbp-20h] BYREF
long long v10; // [rsp+88h] [rbp-18h]
long long v11; // [rsp+90h] [rbp-10h]
long long v12; // [rsp+98h] [rbp-8h]
v12 = a1;
v11 = a2;
v10 = a3;
std::lock_guard<std::mutex>::lock_guard(v9);
std::basic_regex<char,std::regex_traits<char>>::basic_regex(v8, "^\\d+$", 16LL);
if ( (std::regex_match<std::char_traits<char>,std::allocator<char>,char,std::regex_traits<char>>(v10, v8, 0LL) & 1) != 0 )
{
v5 = std::stoull(v10, 0LL, 10LL);
*(_QWORD *)(a2 + 80) = v5;
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, "ok", &v4);
std::allocator<char>::~allocator(&v4);
}
else
{
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>(a1, "failed", &v7);
std::allocator<char>::~allocator(&v7);
}
v6 = 1;
std::basic_regex<char,std::regex_traits<char>>::~basic_regex(v8);
std::lock_guard<std::mutex>::~lock_guard(v9);
return a1;
}
|
setHeight:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xa0
MOV qword ptr [RBP + -0x80],RDI
MOV RAX,RDI
MOV qword ptr [RBP + -0x78],RAX
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV RSI,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x70],RSI
LEA RDI,[RBP + -0x20]
CALL 0x0010b200
LAB_00109a13:
LEA RSI,[0x14028f]
LEA RDI,[RBP + -0x40]
MOV EDX,0x10
CALL 0x0010b3a0
JMP 0x00109a2a
LAB_00109a2a:
MOV RDI,qword ptr [RBP + -0x18]
LAB_00109a2e:
LEA RSI,[RBP + -0x40]
XOR EDX,EDX
CALL 0x0010b440
MOV byte ptr [RBP + -0x81],AL
JMP 0x00109a41
LAB_00109a41:
MOV AL,byte ptr [RBP + -0x81]
TEST AL,0x1
JNZ 0x00109ac7
JMP 0x00109a4d
LAB_00109a4d:
LEA RDI,[RBP + -0x4d]
MOV qword ptr [RBP + -0x90],RDI
CALL 0x00107650
MOV RDI,qword ptr [RBP + -0x80]
MOV RDX,qword ptr [RBP + -0x90]
LAB_00109a68:
LEA RSI,[0x140288]
CALL 0x0010b110
JMP 0x00109a76
LAB_00109a76:
LEA RDI,[RBP + -0x4d]
CALL 0x001073d0
MOV dword ptr [RBP + -0x54],0x1
JMP 0x00109b4b
LAB_00109ac7:
MOV RDI,qword ptr [RBP + -0x18]
LAB_00109acb:
XOR EAX,EAX
MOV ESI,EAX
MOV EDX,0xa
CALL 0x0010b490
MOV qword ptr [RBP + -0x98],RAX
JMP 0x00109ae2
LAB_00109ae2:
MOV RAX,qword ptr [RBP + -0x70]
MOV RCX,qword ptr [RBP + -0x98]
MOV qword ptr [RBP + -0x60],RCX
MOV RCX,qword ptr [RBP + -0x60]
MOV qword ptr [RAX + 0x50],RCX
LEA RDI,[RBP + -0x61]
MOV qword ptr [RBP + -0xa0],RDI
CALL 0x00107650
MOV RDI,qword ptr [RBP + -0x80]
MOV RDX,qword ptr [RBP + -0xa0]
LAB_00109b14:
LEA RSI,[0x140285]
CALL 0x0010b110
LAB_00109b20:
JMP 0x00109b22
LAB_00109b22:
LEA RDI,[RBP + -0x61]
CALL 0x001073d0
MOV dword ptr [RBP + -0x54],0x1
JMP 0x00109b4b
LAB_00109b4b:
LEA RDI,[RBP + -0x40]
CALL 0x0010b4d0
LEA RDI,[RBP + -0x20]
CALL 0x0010b290
MOV RAX,qword ptr [RBP + -0x78]
ADD RSP,0xa0
POP RBP
RET
|
/* Settings::setHeight(std::__cxx11::string const&) */
string * Settings::setHeight(string *param_1)
{
bool bVar1;
string *in_RDX;
mutex *in_RSI;
allocator local_69;
int8 local_68;
int4 local_5c;
allocator local_55 [13];
basic_regex<char,std::__cxx11::regex_traits<char>> local_48 [32];
lock_guard<std::mutex> local_28 [8];
string *local_20;
string *local_10;
local_20 = in_RDX;
local_10 = param_1;
std::lock_guard<std::mutex>::lock_guard(local_28,in_RSI);
/* try { // try from 00109a13 to 00109a27 has its CatchHandler @ 00109a8b */
std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::basic_regex
(local_48,"^\\d+$",0x10);
/* try { // try from 00109a2e to 00109a38 has its CatchHandler @ 00109a9c */
bVar1 = std::
regex_match<std::char_traits<char>,std::allocator<char>,char,std::__cxx11::regex_traits<char>>
(local_20,local_48,0);
if (bVar1) {
/* try { // try from 00109acb to 00109ad8 has its CatchHandler @ 00109a9c */
local_68 = std::__cxx11::stoull(local_20,(ulong *)0x0,10);
*(int8 *)(in_RSI + 0x50) = local_68;
std::allocator<char>::allocator();
/* try { // try from 00109b14 to 00109b1f has its CatchHandler @ 00109b34 */
std::__cxx11::string::string<std::allocator<char>>(param_1,"ok",&local_69);
std::allocator<char>::~allocator((allocator<char> *)&local_69);
}
else {
std::allocator<char>::allocator();
/* try { // try from 00109a68 to 00109a73 has its CatchHandler @ 00109aad */
std::__cxx11::string::string<std::allocator<char>>(param_1,"failed",local_55);
std::allocator<char>::~allocator((allocator<char> *)local_55);
}
local_5c = 1;
std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex(local_48);
std::lock_guard<std::mutex>::~lock_guard(local_28);
return param_1;
}
|
|
9,969 |
my_interval_timer
|
eloqsql/mysys/my_getsystime.c
|
ulonglong my_interval_timer()
{
#ifdef HAVE_CLOCK_GETTIME
struct timespec tp;
clock_gettime(CLOCK_MONOTONIC, &tp);
return tp.tv_sec*1000000000ULL+tp.tv_nsec;
#elif defined(HAVE_GETHRTIME)
return gethrtime();
#elif defined(_WIN32)
DBUG_ASSERT(query_performance_frequency);
LARGE_INTEGER t_cnt;
QueryPerformanceCounter(&t_cnt);
return (t_cnt.QuadPart / query_performance_frequency * 1000000000ULL) +
((t_cnt.QuadPart % query_performance_frequency) * 1000000000ULL /
query_performance_frequency);
#else
/* TODO: check for other possibilities for hi-res timestamping */
struct timeval tv;
gettimeofday(&tv,NULL);
return tv.tv_sec*1000000000ULL+tv.tv_usec*1000ULL;
#endif
}
|
O3
|
c
|
my_interval_timer:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x18, %rsp
leaq -0x18(%rbp), %rbx
movl $0x1, %edi
movq %rbx, %rsi
callq 0x262e0
imulq $0x3b9aca00, (%rbx), %rax # imm = 0x3B9ACA00
addq 0x8(%rbx), %rax
addq $0x18, %rsp
popq %rbx
popq %rbp
retq
|
my_interval_timer:
push rbp
mov rbp, rsp
push rbx
sub rsp, 18h
lea rbx, [rbp+var_18]
mov edi, 1
mov rsi, rbx
call _clock_gettime
imul rax, [rbx], 3B9ACA00h
add rax, [rbx+8]
add rsp, 18h
pop rbx
pop rbp
retn
|
long long my_interval_timer()
{
_QWORD v1[3]; // [rsp+8h] [rbp-18h] BYREF
clock_gettime(1LL, v1);
return v1[1] + 1000000000LL * v1[0];
}
|
my_interval_timer:
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x18
LEA RBX,[RBP + -0x18]
MOV EDI,0x1
MOV RSI,RBX
CALL 0x001262e0
IMUL RAX,qword ptr [RBX],0x3b9aca00
ADD RAX,qword ptr [RBX + 0x8]
ADD RSP,0x18
POP RBX
POP RBP
RET
|
long my_interval_timer(void)
{
timespec local_20;
clock_gettime(1,&local_20);
return local_20.tv_sec * 1000000000 + local_20.tv_nsec;
}
|
|
9,970 |
my_fill_utf8mb3_mb
|
eloqsql/strings/ctype-utf8.c
|
static void
my_fill_utf8mb3_mb(CHARSET_INFO *cs, char *str, size_t length, int fill)
{
char *end= str + length;
char buf[10];
char buflen= my_ci_native_to_mb(cs, (my_wc_t) fill, (uchar*) buf,
(uchar*) buf + sizeof(buf));
DBUG_ASSERT(buflen > 0);
for ( ; str + buflen <= end ; )
{
memcpy(str, buf, buflen);
str+= buflen;
}
for ( ; str < end; )
*str++= ' ';
}
|
O0
|
c
|
my_fill_utf8mb3_mb:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x20(%rbp)
movq %rsi, -0x28(%rbp)
movq %rdx, -0x30(%rbp)
movl %ecx, -0x34(%rbp)
movq -0x28(%rbp), %rax
addq -0x30(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x20(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0xd8(%rax), %rax
movq -0x20(%rbp), %rdi
movslq -0x34(%rbp), %rsi
leaq -0x12(%rbp), %rdx
leaq -0x12(%rbp), %rcx
addq $0xa, %rcx
callq *%rax
movb %al, -0x41(%rbp)
jmp 0xd035d
jmp 0xd035f
movq -0x28(%rbp), %rax
movsbl -0x41(%rbp), %ecx
movslq %ecx, %rcx
addq %rcx, %rax
cmpq -0x40(%rbp), %rax
ja 0xd0399
movq -0x28(%rbp), %rdi
leaq -0x12(%rbp), %rsi
movsbq -0x41(%rbp), %rdx
callq 0x292d0
movsbl -0x41(%rbp), %ecx
movq -0x28(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
jmp 0xd035f
jmp 0xd039b
movq -0x28(%rbp), %rax
cmpq -0x40(%rbp), %rax
jae 0xd03b9
movq -0x28(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x28(%rbp)
movb $0x20, (%rax)
jmp 0xd039b
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0xd03d1
addq $0x50, %rsp
popq %rbp
retq
callq 0x29420
nopw %cs:(%rax,%rax)
|
my_fill_utf8mb3_mb:
push rbp
mov rbp, rsp
sub rsp, 50h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_20], rdi
mov [rbp+var_28], rsi
mov [rbp+var_30], rdx
mov [rbp+var_34], ecx
mov rax, [rbp+var_28]
add rax, [rbp+var_30]
mov [rbp+var_40], rax
mov rax, [rbp+var_20]
mov rax, [rax+0B8h]
mov rax, [rax+0D8h]
mov rdi, [rbp+var_20]
movsxd rsi, [rbp+var_34]
lea rdx, [rbp+var_12]
lea rcx, [rbp+var_12]
add rcx, 0Ah
call rax
mov [rbp+var_41], al
jmp short $+2
loc_D035D:
jmp short $+2
loc_D035F:
mov rax, [rbp+var_28]
movsx ecx, [rbp+var_41]
movsxd rcx, ecx
add rax, rcx
cmp rax, [rbp+var_40]
ja short loc_D0399
mov rdi, [rbp+var_28]
lea rsi, [rbp+var_12]
movsx rdx, [rbp+var_41]
call _memcpy
movsx ecx, [rbp+var_41]
mov rax, [rbp+var_28]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_28], rax
jmp short loc_D035F
loc_D0399:
jmp short $+2
loc_D039B:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_40]
jnb short loc_D03B9
mov rax, [rbp+var_28]
mov rcx, rax
add rcx, 1
mov [rbp+var_28], rcx
mov byte ptr [rax], 20h ; ' '
jmp short loc_D039B
loc_D03B9:
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_D03D1
add rsp, 50h
pop rbp
retn
loc_D03D1:
call ___stack_chk_fail
|
unsigned long long my_fill_utf8mb3_mb(long long a1, _BYTE *a2, long long a3, int a4)
{
_BYTE *v4; // rax
char i; // [rsp+Fh] [rbp-41h]
unsigned long long v7; // [rsp+10h] [rbp-40h]
_BYTE *v8; // [rsp+28h] [rbp-28h]
_BYTE v9[10]; // [rsp+3Eh] [rbp-12h] BYREF
unsigned long long v10; // [rsp+48h] [rbp-8h] BYREF
v10 = __readfsqword(0x28u);
v8 = a2;
v7 = (unsigned long long)&a2[a3];
for ( i = (*(long long ( **)(long long, _QWORD, _BYTE *, unsigned long long *))(*(_QWORD *)(a1 + 184) + 216LL))(
a1,
a4,
v9,
&v10); (unsigned long long)&v8[i] <= v7; v8 += i )
memcpy(v8, v9, i);
while ( (unsigned long long)v8 < v7 )
{
v4 = v8++;
*v4 = 32;
}
return __readfsqword(0x28u);
}
|
my_fill_utf8mb3_mb:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x20],RDI
MOV qword ptr [RBP + -0x28],RSI
MOV qword ptr [RBP + -0x30],RDX
MOV dword ptr [RBP + -0x34],ECX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0xd8]
MOV RDI,qword ptr [RBP + -0x20]
MOVSXD RSI,dword ptr [RBP + -0x34]
LEA RDX,[RBP + -0x12]
LEA RCX,[RBP + -0x12]
ADD RCX,0xa
CALL RAX
MOV byte ptr [RBP + -0x41],AL
JMP 0x001d035d
LAB_001d035d:
JMP 0x001d035f
LAB_001d035f:
MOV RAX,qword ptr [RBP + -0x28]
MOVSX ECX,byte ptr [RBP + -0x41]
MOVSXD RCX,ECX
ADD RAX,RCX
CMP RAX,qword ptr [RBP + -0x40]
JA 0x001d0399
MOV RDI,qword ptr [RBP + -0x28]
LEA RSI,[RBP + -0x12]
MOVSX RDX,byte ptr [RBP + -0x41]
CALL 0x001292d0
MOVSX ECX,byte ptr [RBP + -0x41]
MOV RAX,qword ptr [RBP + -0x28]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x28],RAX
JMP 0x001d035f
LAB_001d0399:
JMP 0x001d039b
LAB_001d039b:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x40]
JNC 0x001d03b9
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,RAX
ADD RCX,0x1
MOV qword ptr [RBP + -0x28],RCX
MOV byte ptr [RAX],0x20
JMP 0x001d039b
LAB_001d03b9:
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x001d03d1
ADD RSP,0x50
POP RBP
RET
LAB_001d03d1:
CALL 0x00129420
|
void my_fill_utf8mb3_mb(long param_1,int1 *param_2,long param_3,int param_4)
{
char cVar1;
long in_FS_OFFSET;
int1 *local_30;
int1 local_1a [10];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
cVar1 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xd8))(param_1,(long)param_4,local_1a,&local_10);
for (local_30 = param_2; local_30 + (int)cVar1 <= param_2 + param_3;
local_30 = local_30 + (int)cVar1) {
memcpy(local_30,local_1a,(long)cVar1);
}
while (local_30 < param_2 + param_3) {
*local_30 = 0x20;
local_30 = local_30 + 1;
}
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return;
}
|
|
9,971 |
s3_put_object
|
eloqsql/storage/maria/s3_func.c
|
int s3_put_object(ms3_st *s3_client, const char *aws_bucket,
const char *name, uchar *data, size_t length,
my_bool compression)
{
uint8_t error;
const char *errmsg;
DBUG_ENTER("s3_put_object");
DBUG_PRINT("enter", ("name: %s", name));
if (compression)
{
size_t comp_len;
data[-COMPRESS_HEADER]= 0; // No compression
if (!my_compress(data, &length, &comp_len))
data[-COMPRESS_HEADER]= 1; // Compressed package
data-= COMPRESS_HEADER;
length+= COMPRESS_HEADER;
int3store(data+1, comp_len); // Original length or 0
}
if (likely(!(error= ms3_put(s3_client, aws_bucket, name, data, length))))
DBUG_RETURN(0);
if (!(errmsg= ms3_server_error(s3_client)))
errmsg= ms3_error(error);
my_printf_error(EE_WRITE, "Got error from put_object(%s): %d %s", MYF(0),
name, error, errmsg);
DBUG_RETURN(EE_WRITE);
}
|
O0
|
c
|
s3_put_object:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movb %r9b, %al
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movb %al, -0x31(%rbp)
jmp 0x29a44
cmpb $0x0, -0x31(%rbp)
je 0x29ab7
movq -0x28(%rbp), %rax
movb $0x0, -0x4(%rax)
movq -0x28(%rbp), %rdi
leaq -0x30(%rbp), %rsi
leaq -0x48(%rbp), %rdx
callq 0xb5e30
cmpb $0x0, %al
jne 0x29a6f
movq -0x28(%rbp), %rax
movb $0x1, -0x4(%rax)
movq -0x28(%rbp), %rax
addq $-0x4, %rax
movq %rax, -0x28(%rbp)
movq -0x30(%rbp), %rax
addq $0x4, %rax
movq %rax, -0x30(%rbp)
movq -0x48(%rbp), %rax
movb %al, %cl
movq -0x28(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0x48(%rbp), %rax
shrl $0x8, %eax
movb %al, %cl
movq -0x28(%rbp), %rax
movb %cl, 0x2(%rax)
movq -0x48(%rbp), %rax
shrq $0x10, %rax
movb %al, %cl
movq -0x28(%rbp), %rax
movb %cl, 0x3(%rax)
jmp 0x29ab7
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
movq -0x28(%rbp), %rcx
movq -0x30(%rbp), %r8
callq 0x2cfa0
movb %al, -0x32(%rbp)
cmpb $0x0, %al
setne %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x29afd
jmp 0x29af4
movl $0x0, -0x4(%rbp)
jmp 0x29b48
movq -0x10(%rbp), %rdi
callq 0x2cd60
movq %rax, -0x40(%rbp)
cmpq $0x0, %rax
jne 0x29b1d
movzbl -0x32(%rbp), %edi
callq 0x2ce00
movq %rax, -0x40(%rbp)
movq -0x20(%rbp), %rcx
movzbl -0x32(%rbp), %r8d
movq -0x40(%rbp), %r9
movl $0x3, %edi
leaq 0xf3d05(%rip), %rsi # 0x11d83b
xorl %eax, %eax
movl %eax, %edx
movb $0x0, %al
callq 0xb6900
movl $0x3, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
|
s3_put_object:
push rbp
mov rbp, rsp
sub rsp, 50h
mov al, r9b
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov [rbp+var_30], r8
mov [rbp+var_31], al
jmp short $+2
loc_29A44:
cmp [rbp+var_31], 0
jz short loc_29AB7
mov rax, [rbp+var_28]
mov byte ptr [rax-4], 0
mov rdi, [rbp+var_28]
lea rsi, [rbp+var_30]
lea rdx, [rbp+var_48]
call my_compress
cmp al, 0
jnz short loc_29A6F
mov rax, [rbp+var_28]
mov byte ptr [rax-4], 1
loc_29A6F:
mov rax, [rbp+var_28]
add rax, 0FFFFFFFFFFFFFFFCh
mov [rbp+var_28], rax
mov rax, [rbp+var_30]
add rax, 4
mov [rbp+var_30], rax
mov rax, [rbp+var_48]
mov cl, al
mov rax, [rbp+var_28]
mov [rax+1], cl
mov rax, [rbp+var_48]
shr eax, 8
mov cl, al
mov rax, [rbp+var_28]
mov [rax+2], cl
mov rax, [rbp+var_48]
shr rax, 10h
mov cl, al
mov rax, [rbp+var_28]
mov [rax+3], cl
jmp short $+2
loc_29AB7:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_20]
mov rcx, [rbp+var_28]
mov r8, [rbp+var_30]
call ms3_put
mov [rbp+var_32], al
cmp al, 0
setnz al
xor al, 0FFh
and al, 1
movzx eax, al
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_29AFD
jmp short $+2
loc_29AF4:
mov [rbp+var_4], 0
jmp short loc_29B48
loc_29AFD:
mov rdi, [rbp+var_10]
call ms3_server_error
mov [rbp+var_40], rax
cmp rax, 0
jnz short loc_29B1D
movzx edi, [rbp+var_32]
call ms3_error
mov [rbp+var_40], rax
loc_29B1D:
mov rcx, [rbp+var_20]
movzx r8d, [rbp+var_32]
mov r9, [rbp+var_40]
mov edi, 3
lea rsi, aGotErrorFromPu; "Got error from put_object(%s): %d %s"
xor eax, eax
mov edx, eax
mov al, 0
call my_printf_error
mov [rbp+var_4], 3
loc_29B48:
mov eax, [rbp+var_4]
add rsp, 50h
pop rbp
retn
|
long long s3_put_object(long long a1, long long a2, long long a3, long long a4, long long a5, char a6)
{
__int16 v7; // [rsp+8h] [rbp-48h] BYREF
char v8; // [rsp+Ah] [rbp-46h]
long long v9; // [rsp+10h] [rbp-40h]
unsigned __int8 v10; // [rsp+1Eh] [rbp-32h]
char v11; // [rsp+1Fh] [rbp-31h]
long long v12; // [rsp+20h] [rbp-30h] BYREF
long long v13; // [rsp+28h] [rbp-28h]
long long v14; // [rsp+30h] [rbp-20h]
long long v15; // [rsp+38h] [rbp-18h]
long long v16; // [rsp+40h] [rbp-10h]
v16 = a1;
v15 = a2;
v14 = a3;
v13 = a4;
v12 = a5;
v11 = a6;
if ( a6 )
{
*(_BYTE *)(v13 - 4) = 0;
if ( !(unsigned __int8)my_compress(v13, &v12, &v7) )
*(_BYTE *)(v13 - 4) = 1;
v13 -= 4LL;
v12 += 4LL;
*(_WORD *)(v13 + 1) = v7;
*(_BYTE *)(v13 + 3) = v8;
}
v10 = ms3_put(v16, v15, v14, v13, v12);
if ( v10 )
{
v9 = ms3_server_error(v16);
if ( !v9 )
v9 = ms3_error(v10);
my_printf_error(3, (unsigned int)"Got error from put_object(%s): %d %s", 0, v14, v10, v9);
return 3;
}
else
{
return 0;
}
}
|
s3_put_object:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV AL,R9B
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV qword ptr [RBP + -0x30],R8
MOV byte ptr [RBP + -0x31],AL
JMP 0x00129a44
LAB_00129a44:
CMP byte ptr [RBP + -0x31],0x0
JZ 0x00129ab7
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + -0x4],0x0
MOV RDI,qword ptr [RBP + -0x28]
LEA RSI,[RBP + -0x30]
LEA RDX,[RBP + -0x48]
CALL 0x001b5e30
CMP AL,0x0
JNZ 0x00129a6f
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + -0x4],0x1
LAB_00129a6f:
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,-0x4
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x30]
ADD RAX,0x4
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x1],CL
MOV RAX,qword ptr [RBP + -0x48]
SHR EAX,0x8
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x2],CL
MOV RAX,qword ptr [RBP + -0x48]
SHR RAX,0x10
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x3],CL
JMP 0x00129ab7
LAB_00129ab7:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x28]
MOV R8,qword ptr [RBP + -0x30]
CALL 0x0012cfa0
MOV byte ptr [RBP + -0x32],AL
CMP AL,0x0
SETNZ AL
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x00129afd
JMP 0x00129af4
LAB_00129af4:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x00129b48
LAB_00129afd:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0012cd60
MOV qword ptr [RBP + -0x40],RAX
CMP RAX,0x0
JNZ 0x00129b1d
MOVZX EDI,byte ptr [RBP + -0x32]
CALL 0x0012ce00
MOV qword ptr [RBP + -0x40],RAX
LAB_00129b1d:
MOV RCX,qword ptr [RBP + -0x20]
MOVZX R8D,byte ptr [RBP + -0x32]
MOV R9,qword ptr [RBP + -0x40]
MOV EDI,0x3
LEA RSI,[0x21d83b]
XOR EAX,EAX
MOV EDX,EAX
MOV AL,0x0
CALL 0x001b6900
MOV dword ptr [RBP + -0x4],0x3
LAB_00129b48:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x50
POP RBP
RET
|
int4
s3_put_object(int8 param_1,int8 param_2,int8 param_3,long param_4,long param_5,
char param_6)
{
char cVar1;
int1 local_50 [8];
long local_48;
char local_3a;
char local_39;
long local_38;
long local_30;
int8 local_28;
int8 local_20;
int8 local_18;
int4 local_c;
local_39 = param_6;
local_38 = param_5;
local_30 = param_4;
local_28 = param_3;
local_20 = param_2;
local_18 = param_1;
if (param_6 != '\0') {
*(int1 *)(param_4 + -4) = 0;
local_30 = param_4;
cVar1 = my_compress(param_4,&local_38,local_50);
if (cVar1 == '\0') {
*(int1 *)(local_30 + -4) = 1;
}
local_38 = local_38 + 4;
*(char *)(local_30 + -3) = local_50[0];
*(char *)(local_30 + -2) = local_50[1];
*(char *)(local_30 + -1) = local_50[2];
local_30 = local_30 + -4;
}
local_3a = ms3_put(local_18,local_20,local_28,local_30,local_38);
if (local_3a == '\0') {
local_c = 0;
}
else {
local_48 = ms3_server_error(local_18);
if (local_48 == 0) {
local_48 = ms3_error(local_3a);
}
my_printf_error(3,"Got error from put_object(%s): %d %s",0,local_28,local_3a,local_48);
local_c = 3;
}
return local_c;
}
|
|
9,972 |
my_hash_sort_ucs2_nopad
|
eloqsql/strings/ctype-ucs2.c
|
static void
my_hash_sort_ucs2_nopad(CHARSET_INFO *cs, const uchar *s, size_t slen,
ulong *nr1, ulong *nr2)
{
my_wc_t wc;
int res;
const uchar *e=s+slen;
MY_UNICASE_INFO *uni_plane= cs->caseinfo;
register ulong m1= *nr1, m2= *nr2;
while ((s < e) && (res=my_ucs2_uni(cs,&wc, (uchar *)s, (uchar*)e)) >0)
{
my_tosort_ucs2(uni_plane, &wc);
MY_HASH_ADD_16(m1, m2, wc);
s+=res;
}
*nr1= m1;
*nr2= m2;
}
|
O0
|
c
|
my_hash_sort_ucs2_nopad:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x10(%rbp), %rax
addq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x8(%rbp), %rax
movq 0x78(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x50(%rbp)
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x10(%rbp), %rcx
xorl %eax, %eax
cmpq -0x40(%rbp), %rcx
movb %al, -0x59(%rbp)
jae 0x5a64a
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rdx
movq -0x40(%rbp), %rcx
leaq -0x30(%rbp), %rsi
callq 0x54f20
movl %eax, -0x34(%rbp)
cmpl $0x0, %eax
setg %al
movb %al, -0x59(%rbp)
movb -0x59(%rbp), %al
testb $0x1, %al
jne 0x5a656
jmp 0x5a6f0
movq -0x48(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x5a710
jmp 0x5a665
movq -0x50(%rbp), %rax
andq $0x3f, %rax
addq -0x58(%rbp), %rax
movq -0x30(%rbp), %rcx
andq $0xff, %rcx
imulq %rcx, %rax
movq -0x50(%rbp), %rcx
shlq $0x8, %rcx
addq %rcx, %rax
xorq -0x50(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x58(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x58(%rbp)
jmp 0x5a6a1
movq -0x50(%rbp), %rax
andq $0x3f, %rax
addq -0x58(%rbp), %rax
movq -0x30(%rbp), %rcx
shrq $0x8, %rcx
imulq %rcx, %rax
movq -0x50(%rbp), %rcx
shlq $0x8, %rcx
addq %rcx, %rax
xorq -0x50(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x58(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x58(%rbp)
jmp 0x5a6da
movl -0x34(%rbp), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
jmp 0x5a61a
movq -0x50(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movq -0x58(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
|
my_hash_sort_ucs2_nopad:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov rax, [rbp+var_10]
add rax, [rbp+var_18]
mov [rbp+var_40], rax
mov rax, [rbp+var_8]
mov rax, [rax+78h]
mov [rbp+var_48], rax
mov rax, [rbp+var_20]
mov rax, [rax]
mov [rbp+var_50], rax
mov rax, [rbp+var_28]
mov rax, [rax]
mov [rbp+var_58], rax
loc_5A61A:
mov rcx, [rbp+var_10]
xor eax, eax
cmp rcx, [rbp+var_40]
mov [rbp+var_59], al
jnb short loc_5A64A
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_10]
mov rcx, [rbp+var_40]
lea rsi, [rbp+var_30]
call my_ucs2_uni
mov [rbp+var_34], eax
cmp eax, 0
setnle al
mov [rbp+var_59], al
loc_5A64A:
mov al, [rbp+var_59]
test al, 1
jnz short loc_5A656
jmp loc_5A6F0
loc_5A656:
mov rdi, [rbp+var_48]
lea rsi, [rbp+var_30]
call my_tosort_ucs2
jmp short $+2
loc_5A665:
mov rax, [rbp+var_50]
and rax, 3Fh
add rax, [rbp+var_58]
mov rcx, [rbp+var_30]
and rcx, 0FFh
imul rax, rcx
mov rcx, [rbp+var_50]
shl rcx, 8
add rax, rcx
xor rax, [rbp+var_50]
mov [rbp+var_50], rax
mov rax, [rbp+var_58]
add rax, 3
mov [rbp+var_58], rax
jmp short $+2
loc_5A6A1:
mov rax, [rbp+var_50]
and rax, 3Fh
add rax, [rbp+var_58]
mov rcx, [rbp+var_30]
shr rcx, 8
imul rax, rcx
mov rcx, [rbp+var_50]
shl rcx, 8
add rax, rcx
xor rax, [rbp+var_50]
mov [rbp+var_50], rax
mov rax, [rbp+var_58]
add rax, 3
mov [rbp+var_58], rax
jmp short $+2
loc_5A6DA:
mov ecx, [rbp+var_34]
mov rax, [rbp+var_10]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_10], rax
jmp loc_5A61A
loc_5A6F0:
mov rcx, [rbp+var_50]
mov rax, [rbp+var_20]
mov [rax], rcx
mov rcx, [rbp+var_58]
mov rax, [rbp+var_28]
mov [rax], rcx
add rsp, 60h
pop rbp
retn
|
_QWORD * my_hash_sort_ucs2_nopad(
long long a1,
unsigned long long a2,
long long a3,
unsigned long long *a4,
_QWORD *a5,
long long a6)
{
_QWORD *result; // rax
bool v7; // [rsp+7h] [rbp-59h]
long long v8; // [rsp+8h] [rbp-58h]
long long v9; // [rsp+8h] [rbp-58h]
unsigned long long v10; // [rsp+10h] [rbp-50h]
long long v11; // [rsp+10h] [rbp-50h]
long long v12; // [rsp+18h] [rbp-48h]
unsigned long long v13; // [rsp+20h] [rbp-40h]
int v14; // [rsp+2Ch] [rbp-34h]
unsigned long long v15; // [rsp+30h] [rbp-30h] BYREF
_QWORD *v16; // [rsp+38h] [rbp-28h]
unsigned long long *v17; // [rsp+40h] [rbp-20h]
long long v18; // [rsp+48h] [rbp-18h]
unsigned long long v19; // [rsp+50h] [rbp-10h]
long long v20; // [rsp+58h] [rbp-8h]
v20 = a1;
v19 = a2;
v18 = a3;
v17 = a4;
v16 = a5;
v13 = a3 + a2;
v12 = *(_QWORD *)(a1 + 120);
v10 = *a4;
v8 = *a5;
while ( 1 )
{
v7 = 0;
if ( v19 < v13 )
{
v14 = my_ucs2_uni(v20, (long long)&v15, v19, v13, (long long)a5, a6);
v7 = v14 > 0;
}
if ( !v7 )
break;
my_tosort_ucs2(v12, &v15);
v11 = v10 ^ ((v10 << 8) + (unsigned __int8)v15 * (v8 + (v10 & 0x3F)));
v9 = v8 + 3;
v10 = v11 ^ ((v11 << 8) + (v15 >> 8) * (v9 + (v11 & 0x3F)));
v8 = v9 + 3;
v19 += v14;
}
*v17 = v10;
result = v16;
*v16 = v8;
return result;
}
|
my_hash_sort_ucs2_nopad:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x78]
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x58],RAX
LAB_0015a61a:
MOV RCX,qword ptr [RBP + -0x10]
XOR EAX,EAX
CMP RCX,qword ptr [RBP + -0x40]
MOV byte ptr [RBP + -0x59],AL
JNC 0x0015a64a
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x40]
LEA RSI,[RBP + -0x30]
CALL 0x00154f20
MOV dword ptr [RBP + -0x34],EAX
CMP EAX,0x0
SETG AL
MOV byte ptr [RBP + -0x59],AL
LAB_0015a64a:
MOV AL,byte ptr [RBP + -0x59]
TEST AL,0x1
JNZ 0x0015a656
JMP 0x0015a6f0
LAB_0015a656:
MOV RDI,qword ptr [RBP + -0x48]
LEA RSI,[RBP + -0x30]
CALL 0x0015a710
JMP 0x0015a665
LAB_0015a665:
MOV RAX,qword ptr [RBP + -0x50]
AND RAX,0x3f
ADD RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x30]
AND RCX,0xff
IMUL RAX,RCX
MOV RCX,qword ptr [RBP + -0x50]
SHL RCX,0x8
ADD RAX,RCX
XOR RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x3
MOV qword ptr [RBP + -0x58],RAX
JMP 0x0015a6a1
LAB_0015a6a1:
MOV RAX,qword ptr [RBP + -0x50]
AND RAX,0x3f
ADD RAX,qword ptr [RBP + -0x58]
MOV RCX,qword ptr [RBP + -0x30]
SHR RCX,0x8
IMUL RAX,RCX
MOV RCX,qword ptr [RBP + -0x50]
SHL RCX,0x8
ADD RAX,RCX
XOR RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x58]
ADD RAX,0x3
MOV qword ptr [RBP + -0x58],RAX
JMP 0x0015a6da
LAB_0015a6da:
MOV ECX,dword ptr [RBP + -0x34]
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
JMP 0x0015a61a
LAB_0015a6f0:
MOV RCX,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x58]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
ADD RSP,0x60
POP RBP
RET
|
void my_hash_sort_ucs2_nopad(long param_1,ulong param_2,long param_3,ulong *param_4,long *param_5)
{
int8 uVar1;
bool bVar2;
long local_60;
ulong local_58;
int local_3c;
ulong local_38;
long *local_30;
ulong *local_28;
long local_20;
ulong local_18;
long local_10;
uVar1 = *(int8 *)(param_1 + 0x78);
local_58 = *param_4;
local_60 = *param_5;
local_30 = param_5;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
while( true ) {
bVar2 = false;
if (local_18 < param_2 + param_3) {
local_3c = my_ucs2_uni(local_10,&local_38,local_18,param_2 + param_3);
bVar2 = 0 < local_3c;
}
if (!bVar2) break;
my_tosort_ucs2(uVar1,&local_38);
local_58 = ((local_58 & 0x3f) + local_60) * (local_38 & 0xff) + local_58 * 0x100 ^ local_58;
local_58 = ((local_58 & 0x3f) + local_60 + 3) * (local_38 >> 8) + local_58 * 0x100 ^ local_58;
local_60 = local_60 + 6;
local_18 = local_18 + (long)local_3c;
}
*local_28 = local_58;
*local_30 = local_60;
return;
}
|
|
9,973 |
int testing::internal::CountIf<std::vector<testing::TestSuite*, std::allocator<testing::TestSuite*>>, bool (*)(testing::TestSuite const*)>(std::vector<testing::TestSuite*, std::allocator<testing::TestSuite*>> const&, bool (*)(testing::TestSuite const*))
|
AlayaLite/build_O0/_deps/googletest-src/googletest/src/gtest-internal-inl.h
|
inline int CountIf(const Container& c, Predicate predicate) {
// Implemented as an explicit loop since std::count_if() in libCstd on
// Solaris has a non-standard signature.
int count = 0;
for (auto it = c.begin(); it != c.end(); ++it) {
if (predicate(*it)) ++count;
}
return count;
}
|
O0
|
c
|
int testing::internal::CountIf<std::vector<testing::TestSuite*, std::allocator<testing::TestSuite*>>, bool (*)(testing::TestSuite const*)>(std::vector<testing::TestSuite*, std::allocator<testing::TestSuite*>> const&, bool (*)(testing::TestSuite const*)):
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movl $0x0, 0x24(%rsp)
movq 0x30(%rsp), %rdi
callq 0xf1fa0
movq %rax, 0x18(%rsp)
movq 0x30(%rsp), %rdi
callq 0xf1fd0
movq %rax, 0x10(%rsp)
leaq 0x18(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0xf2000
xorb $-0x1, %al
testb $0x1, %al
jne 0xeda1b
jmp 0xeda5b
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
leaq 0x18(%rsp), %rdi
callq 0xf2040
movq %rax, %rcx
movq 0x8(%rsp), %rax
movq (%rcx), %rdi
callq *%rax
testb $0x1, %al
jne 0xeda42
jmp 0xeda4d
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0xeda4f
leaq 0x18(%rsp), %rdi
callq 0xf2050
jmp 0xed9f5
movl 0x24(%rsp), %eax
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
nop
|
_ZN7testing8internal7CountIfISt6vectorIPNS_9TestSuiteESaIS4_EEPFbPKS3_EEEiRKT_T0_:
sub rsp, 38h
mov [rsp+38h+var_8], rdi
mov [rsp+38h+var_10], rsi
mov [rsp+38h+var_14], 0
mov rdi, [rsp+38h+var_8]
call _ZNKSt6vectorIPN7testing9TestSuiteESaIS2_EE5beginEv; std::vector<testing::TestSuite *>::begin(void)
mov [rsp+38h+var_20], rax
loc_ED9F5:
mov rdi, [rsp+38h+var_8]
call _ZNKSt6vectorIPN7testing9TestSuiteESaIS2_EE3endEv; std::vector<testing::TestSuite *>::end(void)
mov [rsp+38h+var_28], rax
lea rdi, [rsp+38h+var_20]
lea rsi, [rsp+38h+var_28]
call _ZN9__gnu_cxxeqIPKPN7testing9TestSuiteESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_QrqXeqcldtfp_4baseEcldtfp0_4baseERSt14convertible_toIbEE
xor al, 0FFh
test al, 1
jnz short loc_EDA1B
jmp short loc_EDA5B
loc_EDA1B:
mov rax, [rsp+38h+var_10]
mov [rsp+38h+var_30], rax
lea rdi, [rsp+38h+var_20]
call _ZNK9__gnu_cxx17__normal_iteratorIPKPN7testing9TestSuiteESt6vectorIS3_SaIS3_EEEdeEv; __gnu_cxx::__normal_iterator<testing::TestSuite * const*,std::vector<testing::TestSuite *>>::operator*(void)
mov rcx, rax
mov rax, [rsp+38h+var_30]
mov rdi, [rcx]
call rax
test al, 1
jnz short loc_EDA42
jmp short loc_EDA4D
loc_EDA42:
mov eax, [rsp+38h+var_14]
add eax, 1
mov [rsp+38h+var_14], eax
loc_EDA4D:
jmp short $+2
loc_EDA4F:
lea rdi, [rsp+38h+var_20]
call _ZN9__gnu_cxx17__normal_iteratorIPKPN7testing9TestSuiteESt6vectorIS3_SaIS3_EEEppEv; __gnu_cxx::__normal_iterator<testing::TestSuite * const*,std::vector<testing::TestSuite *>>::operator++(void)
jmp short loc_ED9F5
loc_EDA5B:
mov eax, [rsp+38h+var_14]
add rsp, 38h
retn
|
long long testing::internal::CountIf<std::vector<testing::TestSuite *>,bool (*)(testing::TestSuite const*)>(
long long a1,
long long ( *a2)(_QWORD))
{
_QWORD *v2; // rax
long long ( *v4)(_QWORD); // [rsp+8h] [rbp-30h]
long long v5; // [rsp+10h] [rbp-28h] BYREF
long long i; // [rsp+18h] [rbp-20h] BYREF
unsigned int v7; // [rsp+24h] [rbp-14h]
long long ( *v8)(_QWORD); // [rsp+28h] [rbp-10h]
long long v9; // [rsp+30h] [rbp-8h]
v9 = a1;
v8 = a2;
v7 = 0;
for ( i = std::vector<testing::TestSuite *>::begin(a1);
;
__gnu_cxx::__normal_iterator<testing::TestSuite * const*,std::vector<testing::TestSuite *>>::operator++(&i) )
{
v5 = std::vector<testing::TestSuite *>::end(v9);
if ( (__gnu_cxx::operator==<testing::TestSuite * const*,std::vector<testing::TestSuite *>>(&i, &v5) & 1) != 0 )
break;
v4 = v8;
v2 = (_QWORD *)__gnu_cxx::__normal_iterator<testing::TestSuite * const*,std::vector<testing::TestSuite *>>::operator*(&i);
if ( (v4(*v2) & 1) != 0 )
++v7;
}
return v7;
}
|
CountIf<std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>,bool(*)(testing::TestSuite_const*)>:
SUB RSP,0x38
MOV qword ptr [RSP + 0x30],RDI
MOV qword ptr [RSP + 0x28],RSI
MOV dword ptr [RSP + 0x24],0x0
MOV RDI,qword ptr [RSP + 0x30]
CALL 0x001f1fa0
MOV qword ptr [RSP + 0x18],RAX
LAB_001ed9f5:
MOV RDI,qword ptr [RSP + 0x30]
CALL 0x001f1fd0
MOV qword ptr [RSP + 0x10],RAX
LEA RDI,[RSP + 0x18]
LEA RSI,[RSP + 0x10]
CALL 0x001f2000
XOR AL,0xff
TEST AL,0x1
JNZ 0x001eda1b
JMP 0x001eda5b
LAB_001eda1b:
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x8],RAX
LEA RDI,[RSP + 0x18]
CALL 0x001f2040
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x8]
MOV RDI,qword ptr [RCX]
CALL RAX
TEST AL,0x1
JNZ 0x001eda42
JMP 0x001eda4d
LAB_001eda42:
MOV EAX,dword ptr [RSP + 0x24]
ADD EAX,0x1
MOV dword ptr [RSP + 0x24],EAX
LAB_001eda4d:
JMP 0x001eda4f
LAB_001eda4f:
LEA RDI,[RSP + 0x18]
CALL 0x001f2050
JMP 0x001ed9f5
LAB_001eda5b:
MOV EAX,dword ptr [RSP + 0x24]
ADD RSP,0x38
RET
|
/* int testing::internal::CountIf<std::vector<testing::TestSuite*,
std::allocator<testing::TestSuite*> >, bool (*)(testing::TestSuite
const*)>(std::vector<testing::TestSuite*, std::allocator<testing::TestSuite*> > const&, bool
(*)(testing::TestSuite const*)) */
int testing::internal::
CountIf<std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>,bool(*)(testing::TestSuite_const*)>
(vector *param_1,_func_bool_TestSuite_ptr *param_2)
{
_func_bool_TestSuite_ptr *p_Var1;
byte bVar2;
bool bVar3;
int8 *puVar4;
int8 local_28;
int8 local_20;
int local_14;
_func_bool_TestSuite_ptr *local_10;
vector *local_8;
local_14 = 0;
local_10 = param_2;
local_8 = param_1;
local_20 = std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>::begin
((vector<testing::TestSuite*,std::allocator<testing::TestSuite*>> *)param_1);
while( true ) {
local_28 = std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>::end
((vector<testing::TestSuite*,std::allocator<testing::TestSuite*>> *)local_8
);
bVar2 = _ZN9__gnu_cxxeqIPKPN7testing9TestSuiteESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESE_QrqXeqcldtfp_4baseEcldtfp0_4baseERSt14convertible_toIbEE
(&local_20,&local_28);
p_Var1 = local_10;
if (((bVar2 ^ 0xff) & 1) == 0) break;
puVar4 = (int8 *)
__gnu_cxx::
__normal_iterator<testing::TestSuite*const*,std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>>
::operator*((__normal_iterator<testing::TestSuite*const*,std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>>
*)&local_20);
bVar3 = (*p_Var1)((TestSuite *)*puVar4);
if (bVar3) {
local_14 = local_14 + 1;
}
__gnu_cxx::
__normal_iterator<testing::TestSuite*const*,std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>>
::operator++((__normal_iterator<testing::TestSuite*const*,std::vector<testing::TestSuite*,std::allocator<testing::TestSuite*>>>
*)&local_20);
}
return local_14;
}
|
|
9,974 |
end_io_cache
|
eloqsql/mysys/mf_iocache.c
|
int end_io_cache(IO_CACHE *info)
{
int error=0;
DBUG_ENTER("end_io_cache");
DBUG_PRINT("enter",("cache: %p", info));
/*
Every thread must call remove_io_thread(). The last one destroys
the share elements.
*/
DBUG_ASSERT(!info->share || !info->share->total_threads);
if (info->alloced_buffer)
{
info->alloced_buffer=0;
if (info->file != -1) /* File doesn't exist */
error= my_b_flush_io_cache(info,1);
my_free(info->buffer);
info->buffer=info->read_pos=(uchar*) 0;
}
if (info->type == SEQ_READ_APPEND)
{
/* Destroy allocated mutex */
mysql_mutex_destroy(&info->append_buffer_lock);
}
info->share= 0;
info->type= TYPE_NOT_SET; /* Ensure that flush_io_cache() does nothing */
info->write_end= 0; /* Ensure that my_b_write() fails */
info->write_function= 0; /* my_b_write will crash if used */
DBUG_RETURN(error);
}
|
O3
|
c
|
end_io_cache:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpq $0x0, 0x100(%rdi)
je 0x96340
movq $0x0, 0x100(%rbx)
cmpl $-0x1, 0xd4(%rbx)
je 0x96345
movq %rbx, %rdi
movl $0x1, %esi
callq 0x9535d
movl %eax, %r14d
jmp 0x96348
xorl %r14d, %r14d
jmp 0x9635b
xorl %r14d, %r14d
movq 0x20(%rbx), %rdi
callq 0x9ff7e
xorl %eax, %eax
movq %rax, 0x10(%rbx)
movq %rax, 0x20(%rbx)
cmpl $0x3, 0xb0(%rbx)
jne 0x96394
leaq 0x50(%rbx), %r15
movq 0x90(%rbx), %rdi
testq %rdi, %rdi
je 0x9638c
leaq 0x2efc95(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x48(%rax)
movq $0x0, 0x90(%rbx)
movq %r15, %rdi
callq 0x290c0
xorl %eax, %eax
movq %rax, 0x98(%rbx)
movl $0x0, 0xb0(%rbx)
movq %rax, 0x48(%rbx)
movq %rax, 0xa8(%rbx)
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
|
end_io_cache:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov rbx, rdi
cmp qword ptr [rdi+100h], 0
jz short loc_96340
mov qword ptr [rbx+100h], 0
cmp dword ptr [rbx+0D4h], 0FFFFFFFFh
jz short loc_96345
mov rdi, rbx
mov esi, 1
call my_b_flush_io_cache
mov r14d, eax
jmp short loc_96348
loc_96340:
xor r14d, r14d
jmp short loc_9635B
loc_96345:
xor r14d, r14d
loc_96348:
mov rdi, [rbx+20h]
call my_free
xor eax, eax
mov [rbx+10h], rax
mov [rbx+20h], rax
loc_9635B:
cmp dword ptr [rbx+0B0h], 3
jnz short loc_96394
lea r15, [rbx+50h]
mov rdi, [rbx+90h]
test rdi, rdi
jz short loc_9638C
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+48h]
mov qword ptr [rbx+90h], 0
loc_9638C:
mov rdi, r15
call _pthread_mutex_destroy
loc_96394:
xor eax, eax
mov [rbx+98h], rax
mov dword ptr [rbx+0B0h], 0
mov [rbx+48h], rax
mov [rbx+0A8h], rax
mov eax, r14d
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
|
long long end_io_cache(long long a1)
{
unsigned int v2; // r14d
long long v3; // rdi
if ( *(_QWORD *)(a1 + 256) )
{
*(_QWORD *)(a1 + 256) = 0LL;
if ( *(_DWORD *)(a1 + 212) == -1 )
v2 = 0;
else
v2 = my_b_flush_io_cache((long long *)a1, 1);
my_free(*(_QWORD *)(a1 + 32));
*(_QWORD *)(a1 + 16) = 0LL;
*(_QWORD *)(a1 + 32) = 0LL;
}
else
{
v2 = 0;
}
if ( *(_DWORD *)(a1 + 176) == 3 )
{
v3 = *(_QWORD *)(a1 + 144);
if ( v3 )
{
((void ( *)(long long))PSI_server[9])(v3);
*(_QWORD *)(a1 + 144) = 0LL;
}
pthread_mutex_destroy(a1 + 80);
}
*(_QWORD *)(a1 + 152) = 0LL;
*(_DWORD *)(a1 + 176) = 0;
*(_QWORD *)(a1 + 72) = 0LL;
*(_QWORD *)(a1 + 168) = 0LL;
return v2;
}
|
end_io_cache:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
CMP qword ptr [RDI + 0x100],0x0
JZ 0x00196340
MOV qword ptr [RBX + 0x100],0x0
CMP dword ptr [RBX + 0xd4],-0x1
JZ 0x00196345
MOV RDI,RBX
MOV ESI,0x1
CALL 0x0019535d
MOV R14D,EAX
JMP 0x00196348
LAB_00196340:
XOR R14D,R14D
JMP 0x0019635b
LAB_00196345:
XOR R14D,R14D
LAB_00196348:
MOV RDI,qword ptr [RBX + 0x20]
CALL 0x0019ff7e
XOR EAX,EAX
MOV qword ptr [RBX + 0x10],RAX
MOV qword ptr [RBX + 0x20],RAX
LAB_0019635b:
CMP dword ptr [RBX + 0xb0],0x3
JNZ 0x00196394
LEA R15,[RBX + 0x50]
MOV RDI,qword ptr [RBX + 0x90]
TEST RDI,RDI
JZ 0x0019638c
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x48]
MOV qword ptr [RBX + 0x90],0x0
LAB_0019638c:
MOV RDI,R15
CALL 0x001290c0
LAB_00196394:
XOR EAX,EAX
MOV qword ptr [RBX + 0x98],RAX
MOV dword ptr [RBX + 0xb0],0x0
MOV qword ptr [RBX + 0x48],RAX
MOV qword ptr [RBX + 0xa8],RAX
MOV EAX,R14D
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
|
int4 end_io_cache(long param_1)
{
int4 uVar1;
if (*(long *)(param_1 + 0x100) == 0) {
uVar1 = 0;
}
else {
*(int8 *)(param_1 + 0x100) = 0;
if (*(int *)(param_1 + 0xd4) == -1) {
uVar1 = 0;
}
else {
uVar1 = my_b_flush_io_cache(param_1,1);
}
my_free(*(int8 *)(param_1 + 0x20));
*(int8 *)(param_1 + 0x10) = 0;
*(int8 *)(param_1 + 0x20) = 0;
}
if (*(int *)(param_1 + 0xb0) == 3) {
if (*(long *)(param_1 + 0x90) != 0) {
(**(code **)(PSI_server + 0x48))();
*(int8 *)(param_1 + 0x90) = 0;
}
pthread_mutex_destroy((pthread_mutex_t *)(param_1 + 0x50));
}
*(int8 *)(param_1 + 0x98) = 0;
*(int4 *)(param_1 + 0xb0) = 0;
*(int8 *)(param_1 + 0x48) = 0;
*(int8 *)(param_1 + 0xa8) = 0;
return uVar1;
}
|
|
9,975 |
SchemaConverter::check_errors()
|
monkey531[P]llama/common/json-schema-to-grammar.cpp
|
void check_errors() {
if (!_errors.empty()) {
throw std::runtime_error("JSON schema conversion failed:\n" + string_join(_errors, "\n"));
}
if (!_warnings.empty()) {
fprintf(stderr, "WARNING: JSON schema conversion was incomplete: %s\n", string_join(_warnings, "; ").c_str());
}
}
|
O2
|
cpp
|
SchemaConverter::check_errors():
pushq %rbp
pushq %r14
pushq %rbx
subq $0x70, %rsp
movq %rdi, %r14
movq 0xc8(%rdi), %rax
cmpq 0xd0(%rdi), %rax
jne 0x8cf3c
movq 0xe0(%r14), %rax
cmpq 0xe8(%r14), %rax
jne 0x8ced6
addq $0x70, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq 0x730ab(%rip), %rax # 0xfff88
movq (%rax), %rbx
leaq 0x2d79d(%rip), %rsi # 0xba684
leaq 0x10(%rsp), %rdi
leaq 0x50(%rsp), %rdx
callq 0x27852
addq $0xe0, %r14
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rdx
movq %r14, %rsi
callq 0x53f9a
leaq 0x30(%rsp), %r14
movq (%r14), %rdx
leaq 0x2d732(%rip), %rsi # 0xba650
movq %rbx, %rdi
xorl %eax, %eax
callq 0x24c70
movq %r14, %rdi
callq 0x251b8
leaq 0x10(%rsp), %rdi
callq 0x251b8
jmp 0x8cecd
pushq $0x10
popq %rdi
callq 0x24460
movq %rax, %rbx
leaq 0x2498a(%rip), %rsi # 0xb18d8
leaq 0x50(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x27852
addq $0xc8, %r14
leaq 0x10(%rsp), %rdi
leaq 0x50(%rsp), %rdx
movq %r14, %rsi
callq 0x53f9a
leaq 0x2d6b3(%rip), %rsi # 0xba630
leaq 0x30(%rsp), %rdi
leaq 0x10(%rsp), %rdx
callq 0x58a46
movb $0x1, %bpl
leaq 0x30(%rsp), %rsi
movq %rbx, %rdi
callq 0x24e10
xorl %ebp, %ebp
movq 0x7304b(%rip), %rsi # 0xffff0
movq 0x72fa4(%rip), %rdx # 0xfff50
movq %rbx, %rdi
callq 0x24ee0
movq %rax, %r14
leaq 0x30(%rsp), %rdi
callq 0x251b8
jmp 0x8cfc9
movq %rax, %r14
movb $0x1, %bpl
leaq 0x10(%rsp), %rdi
callq 0x251b8
jmp 0x8cfdb
movq %rax, %r14
movb $0x1, %bpl
leaq 0x50(%rsp), %rdi
callq 0x251b8
testb %bpl, %bpl
jne 0x8cfef
jmp 0x8d00b
movq %rax, %r14
movq %rbx, %rdi
callq 0x24670
jmp 0x8d00b
movq %rax, %r14
leaq 0x10(%rsp), %rdi
callq 0x251b8
jmp 0x8d00b
movq %rax, %r14
movq %r14, %rdi
callq 0x24f60
nop
|
_ZN15SchemaConverter12check_errorsEv:
push rbp
push r14
push rbx
sub rsp, 70h
mov r14, rdi
mov rax, [rdi+0C8h]
cmp rax, [rdi+0D0h]
jnz short loc_8CF3C
mov rax, [r14+0E0h]
cmp rax, [r14+0E8h]
jnz short loc_8CED6
loc_8CECD:
add rsp, 70h
pop rbx
pop r14
pop rbp
retn
loc_8CED6:
mov rax, cs:stderr_ptr
mov rbx, [rax]
lea rsi, asc_BA684; "; "
lea rdi, [rsp+88h+var_78]
lea rdx, [rsp+88h+var_38]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
add r14, 0E0h
lea rdi, [rsp+88h+var_58]
lea rdx, [rsp+88h+var_78]
mov rsi, r14
call _Z11string_joinRKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EERKS5_; string_join(std::vector<std::string> const&,std::string const&)
lea r14, [rsp+88h+var_58]
mov rdx, [r14]
lea rsi, aWarningJsonSch; "WARNING: JSON schema conversion was inc"...
mov rdi, rbx
xor eax, eax
call _fprintf
mov rdi, r14; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+88h+var_78]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_8CECD
loc_8CF3C:
push 10h
pop rdi; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rsi, aErrorWhileHand_0+33h; "\n"
lea rdi, [rsp+88h+var_38]
lea rdx, [rsp+88h+var_79]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
add r14, 0C8h
lea rdi, [rsp+88h+var_78]
lea rdx, [rsp+88h+var_38]
mov rsi, r14
call _Z11string_joinRKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EERKS5_; string_join(std::vector<std::string> const&,std::string const&)
lea rsi, aJsonSchemaConv; "JSON schema conversion failed:\n"
lea rdi, [rsp+88h+var_58]
lea rdx, [rsp+88h+var_78]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&)
mov bpl, 1
lea rsi, [rsp+88h+var_58]
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:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rdi, [rsp+88h+var_58]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_8CFC9
mov r14, rax
mov bpl, 1
loc_8CFC9:
lea rdi, [rsp+88h+var_78]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_8CFDB
mov r14, rax
mov bpl, 1
loc_8CFDB:
lea rdi, [rsp+88h+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
jnz short loc_8CFEF
jmp short loc_8D00B
mov r14, rax
loc_8CFEF:
mov rdi, rbx; void *
call ___cxa_free_exception
jmp short loc_8D00B
mov r14, rax
lea rdi, [rsp+88h+var_78]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_8D00B
mov r14, rax
loc_8D00B:
mov rdi, r14
call __Unwind_Resume
|
void SchemaConverter::check_errors(SchemaConverter *this)
{
long long v1; // rbx
void *exception; // rbx
_QWORD v3[4]; // [rsp+10h] [rbp-78h] BYREF
const char *v4[4]; // [rsp+30h] [rbp-58h] BYREF
_QWORD v5[7]; // [rsp+50h] [rbp-38h] BYREF
if ( *((_QWORD *)this + 25) != *((_QWORD *)this + 26) )
{
exception = __cxa_allocate_exception(0x10uLL);
std::string::basic_string<std::allocator<char>>(v5, (long long)"\n");
string_join((long long)v3, (long long *)this + 25, (long long)v5);
std::operator+<char>((long long)v4, (long long)"JSON schema conversion failed:\n", (long long)v3);
std::runtime_error::runtime_error(exception, v4);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
if ( *((_QWORD *)this + 28) != *((_QWORD *)this + 29) )
{
v1 = stderr;
std::string::basic_string<std::allocator<char>>(v3, (long long)"; ");
string_join((long long)v4, (long long *)this + 28, (long long)v3);
fprintf(v1, "WARNING: JSON schema conversion was incomplete: %s\n", v4[0]);
std::string::~string(v4);
std::string::~string(v3);
}
}
|
check_errors:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x70
MOV R14,RDI
MOV RAX,qword ptr [RDI + 0xc8]
CMP RAX,qword ptr [RDI + 0xd0]
JNZ 0x0018cf3c
MOV RAX,qword ptr [R14 + 0xe0]
CMP RAX,qword ptr [R14 + 0xe8]
JNZ 0x0018ced6
LAB_0018cecd:
ADD RSP,0x70
POP RBX
POP R14
POP RBP
RET
LAB_0018ced6:
MOV RAX,qword ptr [0x001fff88]
MOV RBX,qword ptr [RAX]
LAB_0018cee0:
LEA RSI,[0x1ba684]
LEA RDI,[RSP + 0x10]
LEA RDX,[RSP + 0x50]
CALL 0x00127852
LAB_0018cef6:
ADD R14,0xe0
LEA RDI,[RSP + 0x30]
LEA RDX,[RSP + 0x10]
MOV RSI,R14
CALL 0x00153f9a
LAB_0018cf0f:
LEA R14,[RSP + 0x30]
MOV RDX,qword ptr [R14]
LEA RSI,[0x1ba650]
MOV RDI,RBX
XOR EAX,EAX
CALL 0x00124c70
MOV RDI,R14
CALL 0x001251b8
LEA RDI,[RSP + 0x10]
CALL 0x001251b8
JMP 0x0018cecd
LAB_0018cf3c:
PUSH 0x10
POP RDI
CALL 0x00124460
MOV RBX,RAX
LAB_0018cf47:
LEA RSI,[0x1b18d8]
LEA RDI,[RSP + 0x50]
LEA RDX,[RSP + 0xf]
CALL 0x00127852
LAB_0018cf5d:
ADD R14,0xc8
LEA RDI,[RSP + 0x10]
LEA RDX,[RSP + 0x50]
MOV RSI,R14
CALL 0x00153f9a
LAB_0018cf76:
LEA RSI,[0x1ba630]
LEA RDI,[RSP + 0x30]
LEA RDX,[RSP + 0x10]
CALL 0x00158a46
MOV BPL,0x1
LAB_0018cf8f:
LEA RSI,[RSP + 0x30]
MOV RDI,RBX
CALL 0x00124e10
XOR EBP,EBP
MOV RSI,qword ptr [0x001ffff0]
MOV RDX,qword ptr [0x001fff50]
MOV RDI,RBX
CALL 0x00124ee0
|
/* SchemaConverter::check_errors() */
void __thiscall SchemaConverter::check_errors(SchemaConverter *this)
{
FILE *__stream;
runtime_error *this_00;
allocator local_79;
string local_78 [32];
int8 local_58 [4];
allocator local_38 [32];
if (*(long *)(this + 200) == *(long *)(this + 0xd0)) {
if (*(long *)(this + 0xe0) != *(long *)(this + 0xe8)) {
__stream = *(FILE **)PTR_stderr_001fff88;
/* try { // try from 0018cee0 to 0018cef5 has its CatchHandler @ 0018d008 */
std::__cxx11::string::string<std::allocator<char>>(local_78,"; ",local_38);
/* try { // try from 0018cef6 to 0018cf0e has its CatchHandler @ 0018cff9 */
string_join((vector *)local_58,(string *)(this + 0xe0));
fprintf(__stream,"WARNING: JSON schema conversion was incomplete: %s\n",local_58[0]);
std::__cxx11::string::~string((string *)local_58);
std::__cxx11::string::~string(local_78);
}
return;
}
this_00 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0018cf47 to 0018cf5c has its CatchHandler @ 0018cfec */
std::__cxx11::string::string<std::allocator<char>>((string *)local_38,"\n",&local_79);
/* try { // try from 0018cf5d to 0018cf75 has its CatchHandler @ 0018cfd5 */
string_join((vector *)local_78,(string *)(this + 200));
/* try { // try from 0018cf76 to 0018cf8b has its CatchHandler @ 0018cfc3 */
std::operator+((char *)local_58,(string *)"JSON schema conversion failed:\n");
/* try { // try from 0018cf8f to 0018cfb3 has its CatchHandler @ 0018cfb4 */
std::runtime_error::runtime_error(this_00,(string *)local_58);
/* WARNING: Subroutine does not return */
__cxa_throw(this_00,PTR_typeinfo_001ffff0,PTR__runtime_error_001fff50);
}
|
|
9,976 |
SchemaConverter::check_errors()
|
monkey531[P]llama/common/json-schema-to-grammar.cpp
|
void check_errors() {
if (!_errors.empty()) {
throw std::runtime_error("JSON schema conversion failed:\n" + string_join(_errors, "\n"));
}
if (!_warnings.empty()) {
fprintf(stderr, "WARNING: JSON schema conversion was incomplete: %s\n", string_join(_warnings, "; ").c_str());
}
}
|
O3
|
cpp
|
SchemaConverter::check_errors():
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x68, %rsp
movq %rdi, %r14
movq 0xc8(%rdi), %rax
cmpq 0xd0(%rdi), %rax
jne 0xbe8a9
movq 0xe0(%r14), %rax
cmpq 0xe8(%r14), %rax
jne 0xbe84e
addq $0x68, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq 0x6f733(%rip), %rax # 0x12df88
movq (%rax), %r15
leaq 0x18(%rsp), %rbx
movq %rbx, -0x10(%rbx)
leaq 0x37e29(%rip), %rsi # 0xf6691
leaq 0x37e24(%rip), %rdx # 0xf6693
leaq 0x8(%rsp), %rdi
callq 0x21ce4
addq $0xe0, %r14
leaq 0x48(%rsp), %rdi
leaq 0x8(%rsp), %rdx
movq %r14, %rsi
callq 0x72191
leaq 0x48(%rsp), %rdi
leaq 0x8(%rsp), %rdx
movq %r15, %rsi
movq %rbx, %rcx
callq 0x1d139
jmp 0xbe843
movl $0x10, %edi
callq 0x1b440
movq %rax, %rbx
leaq 0x38(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x2f00f(%rip), %rsi # 0xed8d5
leaq 0x2f009(%rip), %rdx # 0xed8d6
leaq 0x28(%rsp), %rdi
callq 0x21ce4
addq $0xc8, %r14
leaq 0x8(%rsp), %rdi
leaq 0x28(%rsp), %rdx
movq %r14, %rsi
callq 0x72191
leaq 0x37d46(%rip), %rsi # 0xf663d
leaq 0x48(%rsp), %rdi
leaq 0x8(%rsp), %rdx
callq 0x78ac9
movb $0x1, %bpl
leaq 0x48(%rsp), %rsi
movq %rbx, %rdi
callq 0x1be00
xorl %ebp, %ebp
movq 0x6f6c9(%rip), %rsi # 0x12dfe8
movq 0x6f62a(%rip), %rdx # 0x12df50
movq %rbx, %rdi
callq 0x1bef0
movq %rax, %r14
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xbe954
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x1b8b0
jmp 0xbe954
movq %rax, %r14
movb $0x1, %bpl
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xbe96f
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1b8b0
movq 0x28(%rsp), %rdi
cmpq %r15, %rdi
je 0xbe986
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1b8b0
testb %bpl, %bpl
jne 0xbe9ac
jmp 0xbe9d5
movq %rax, %r14
movq 0x28(%rsp), %rdi
cmpq %r15, %rdi
je 0xbe9ac
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1b8b0
jmp 0xbe9ac
movq %rax, %r14
movq %rbx, %rdi
callq 0x1b650
jmp 0xbe9d5
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %rbx, %rdi
je 0xbe9d5
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1b8b0
jmp 0xbe9d5
movq %rax, %r14
movq %r14, %rdi
callq 0x1bf70
nop
|
_ZN15SchemaConverter12check_errorsEv:
push rbp
push r15
push r14
push rbx
sub rsp, 68h
mov r14, rdi
mov rax, [rdi+0C8h]
cmp rax, [rdi+0D0h]
jnz short loc_BE8A9
mov rax, [r14+0E0h]
cmp rax, [r14+0E8h]
jnz short loc_BE84E
loc_BE843:
add rsp, 68h
pop rbx
pop r14
pop r15
pop rbp
retn
loc_BE84E:
mov rax, cs:stderr_ptr
mov r15, [rax]
lea rbx, [rsp+88h+var_70]
mov [rbx-10h], rbx
lea rsi, asc_F6691; "; "
lea rdx, asc_F6691+2; ""
lea rdi, [rsp+88h+var_80]
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)
add r14, 0E0h
lea rdi, [rsp+88h+var_40]
lea rdx, [rsp+88h+var_80]
mov rsi, r14
call _Z11string_joinRKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EERKS5_; string_join(std::vector<std::string> const&,std::string const&)
lea rdi, [rsp+88h+var_40]
lea rdx, [rsp+88h+var_80]
mov rsi, r15
mov rcx, rbx
call _ZN15SchemaConverter12check_errorsEv_cold_1; SchemaConverter::check_errors(void) [clone]
jmp short loc_BE843
loc_BE8A9:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea r15, [rsp+88h+var_50]
mov [r15-10h], r15
lea rsi, aErrorWhileHand_0+33h; "\n"
lea rdx, aErrorWhileHand_0+34h; ""
lea rdi, [rsp+88h+var_60]
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)
add r14, 0C8h
lea rdi, [rsp+88h+var_80]
lea rdx, [rsp+88h+var_60]
mov rsi, r14
call _Z11string_joinRKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EERKS5_; string_join(std::vector<std::string> const&,std::string const&)
lea rsi, aJsonSchemaConv; "JSON schema conversion failed:\n"
lea rdi, [rsp+88h+var_40]
lea rdx, [rsp+88h+var_80]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&)
mov bpl, 1
lea rsi, [rsp+88h+var_40]
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+88h+var_30]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_BE954
mov rsi, [rsp+88h+var_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BE954
mov r14, rax
mov bpl, 1
loc_BE954:
lea rax, [rsp+88h+var_70]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_BE96F
mov rsi, [rsp+88h+var_70]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BE96F:
mov rdi, [rsp+88h+var_60]; void *
cmp rdi, r15
jz short loc_BE986
mov rsi, [rsp+88h+var_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BE986:
test bpl, bpl
jnz short loc_BE9AC
jmp short loc_BE9D5
mov r14, rax
mov rdi, [rsp+88h+var_60]; void *
cmp rdi, r15
jz short loc_BE9AC
mov rsi, [rsp+88h+var_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BE9AC
mov r14, rax
loc_BE9AC:
mov rdi, rbx; void *
call ___cxa_free_exception
jmp short loc_BE9D5
mov r14, rax
mov rdi, [rsp+88h+var_80]; void *
cmp rdi, rbx
jz short loc_BE9D5
mov rsi, [rsp+88h+var_70]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BE9D5
mov r14, rax
loc_BE9D5:
mov rdi, r14
call __Unwind_Resume
|
void SchemaConverter::check_errors(SchemaConverter *this)
{
long long v1; // r15
void *exception; // rbx
void *v3[2]; // [rsp+8h] [rbp-80h] BYREF
void *v4[2]; // [rsp+18h] [rbp-70h] BYREF
void *v5[2]; // [rsp+28h] [rbp-60h] BYREF
long long v6; // [rsp+38h] [rbp-50h] BYREF
const char *v7[2]; // [rsp+48h] [rbp-40h] BYREF
if ( *((_QWORD *)this + 25) != *((_QWORD *)this + 26) )
{
exception = __cxa_allocate_exception(0x10uLL);
v5[0] = &v6;
std::string::_M_construct<char const*>((long long)v5, "\n", (long long)"");
string_join((long long)v3, (long long *)this + 25, v5);
std::operator+<char>((long long)v7, (long long)"JSON schema conversion failed:\n", (long long)v3);
std::runtime_error::runtime_error(exception, v7);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
if ( *((_QWORD *)this + 28) != *((_QWORD *)this + 29) )
{
v1 = stderr;
v3[0] = v4;
std::string::_M_construct<char const*>((long long)v3, "; ", (long long)"");
string_join((long long)v7, (long long *)this + 28, v3);
SchemaConverter::check_errors(v7, v1, v3, v4);
}
}
| |||
9,977 |
severity_channel_available
|
navaro[P]qoraal-tictactoe/build_O3/_deps/qoraal-src/src/svc/svc_logger.c
|
static void
severity_channel_available(void)
{
uint8_t severity = SVC_LOGGER_SEVERITY_NEVER ;
LOGGERT_MASK_T mask = 0 ;
LOGGER_CHANNEL_T * start ;
for ( start = (LOGGER_CHANNEL_T*)linked_head (&_logger_channels) ;
(start!=NULL_LLO)
; ) {
int i ;
for (i=0; i<SVC_LOGGER_FILTER_CNT; i++) {
if (!start->filter[i].mask) continue ;
if (severity < SVC_LOGGER_GET_SEVERITY(start->filter[i].type)) {
severity = SVC_LOGGER_GET_SEVERITY(start->filter[i].type) ;
}
mask |= start->filter[i].mask ;
}
start = (LOGGER_CHANNEL_T*)linked_next ((plists_t)start, OFFSETOF(LOGGER_CHANNEL_T, next));
}
_logger_filter.type = SVC_LOGGER_TYPE(severity, 0) ;
_logger_filter.mask = mask ;
}
|
O3
|
c
|
severity_channel_available:
movq 0x2a5cb(%rip), %rcx # 0x40d60
testq %rcx, %rcx
je 0x167f2
pushq %rbp
movq %rsp, %rbp
xorl %eax, %eax
xorl %edx, %edx
leaq 0x10(%rcx), %rsi
movb $0x1, %dil
xorl %r8d, %r8d
leaq (%r8,%r8,8), %r9
movq (%rsi,%r9), %r8
testq %r8, %r8
je 0x167d6
addq %rsi, %r9
movb 0x8(%r9), %r9b
andb $0xf, %r9b
movzbl %dl, %r10d
movzbl %r9b, %edx
cmpb %dl, %r10b
cmoval %r10d, %edx
orq %r8, %rax
movl $0x1, %r8d
testb $0x1, %dil
movl $0x0, %edi
jne 0x167ac
movq (%rcx), %rcx
testq %rcx, %rcx
jne 0x167a2
popq %rbp
jmp 0x167f6
xorl %edx, %edx
xorl %eax, %eax
movb %dl, 0x2a57a(%rip) # 0x40d76
movq %rax, 0x2831d(%rip) # 0x3eb20
retq
|
severity_channel_available:
mov rcx, qword ptr cs:_logger_channels
test rcx, rcx
jz short loc_167F2
push rbp
mov rbp, rsp
xor eax, eax
xor edx, edx
loc_167A2:
lea rsi, [rcx+10h]
mov dil, 1
xor r8d, r8d
loc_167AC:
lea r9, [r8+r8*8]
mov r8, [rsi+r9]
test r8, r8
jz short loc_167D6
add r9, rsi
mov r9b, [r9+8]
and r9b, 0Fh
movzx r10d, dl
movzx edx, r9b
cmp r10b, dl
cmova edx, r10d
or rax, r8
loc_167D6:
mov r8d, 1
test dil, 1
mov edi, 0
jnz short loc_167AC
mov rcx, [rcx]
test rcx, rcx
jnz short loc_167A2
pop rbp
jmp short loc_167F6
loc_167F2:
xor edx, edx
xor eax, eax
loc_167F6:
mov cs:_logger_filter_1, dl
mov cs:_logger_filter_0, rax
retn
|
long long severity_channel_available()
{
_QWORD *v0; // rcx
long long result; // rax
unsigned __int8 v2; // dl
_QWORD *v3; // rsi
char v4; // di
long long v5; // r8
long long v6; // r9
long long v7; // r8
unsigned __int8 v8; // r10
bool v9; // zf
v0 = (_QWORD *)logger_channels;
if ( (_QWORD)logger_channels )
{
result = 0LL;
v2 = 0;
do
{
v3 = v0 + 2;
v4 = 1;
v5 = 0LL;
do
{
v6 = 9 * v5;
v7 = *(_QWORD *)((char *)v3 + 9 * v5);
if ( v7 )
{
v8 = v2;
v2 = *((_BYTE *)v3 + v6 + 8) & 0xF;
if ( v8 > v2 )
v2 = v8;
result |= v7;
}
v5 = 1LL;
v9 = (v4 & 1) == 0;
v4 = 0;
}
while ( !v9 );
v0 = (_QWORD *)*v0;
}
while ( v0 );
}
else
{
v2 = 0;
result = 0LL;
}
logger_filter_1 = v2;
logger_filter_0 = result;
return result;
}
|
severity_channel_available:
MOV RCX,qword ptr [0x00140d60]
TEST RCX,RCX
JZ 0x001167f2
PUSH RBP
MOV RBP,RSP
XOR EAX,EAX
XOR EDX,EDX
LAB_001167a2:
LEA RSI,[RCX + 0x10]
MOV DIL,0x1
XOR R8D,R8D
LAB_001167ac:
LEA R9,[R8 + R8*0x8]
MOV R8,qword ptr [RSI + R9*0x1]
TEST R8,R8
JZ 0x001167d6
ADD R9,RSI
MOV R9B,byte ptr [R9 + 0x8]
AND R9B,0xf
MOVZX R10D,DL
MOVZX EDX,R9B
CMP R10B,DL
CMOVA EDX,R10D
OR RAX,R8
LAB_001167d6:
MOV R8D,0x1
TEST DIL,0x1
MOV EDI,0x0
JNZ 0x001167ac
MOV RCX,qword ptr [RCX]
TEST RCX,RCX
JNZ 0x001167a2
POP RBP
JMP 0x001167f6
LAB_001167f2:
XOR EDX,EDX
XOR EAX,EAX
LAB_001167f6:
MOV byte ptr [0x00140d76],DL
MOV qword ptr [0x0013eb20],RAX
RET
|
void severity_channel_available(void)
{
ulong uVar1;
bool bVar2;
long *plVar3;
byte bVar4;
bool bVar5;
long lVar6;
if (_logger_channels == (long *)0x0) {
_logger_filter_1 = 0;
_logger_filter_0 = 0;
}
else {
_logger_filter_0 = 0;
bVar4 = 0;
_logger_filter_1 = 0;
plVar3 = _logger_channels;
do {
lVar6 = 0;
bVar2 = true;
do {
bVar5 = bVar2;
uVar1 = *(ulong *)((long)plVar3 + lVar6 * 9 + 0x10);
if (uVar1 != 0) {
_logger_filter_1 = *(byte *)((long)plVar3 + lVar6 * 9 + 0x18) & 0xf;
if (_logger_filter_1 < bVar4) {
_logger_filter_1 = bVar4;
}
_logger_filter_0 = _logger_filter_0 | uVar1;
bVar4 = _logger_filter_1;
}
lVar6 = 1;
bVar2 = false;
} while (bVar5);
plVar3 = (long *)*plVar3;
} while (plVar3 != (long *)0x0);
}
return;
}
|
|
9,978 |
js_std_file_finalizer
|
bluesky950520[P]quickjs/quickjs-libc.c
|
static void js_std_file_finalizer(JSRuntime *rt, JSValue val)
{
JSThreadState *ts = js_get_thread_state(rt);
JSSTDFile *s = JS_GetOpaque(val, ts->std_file_class_id);
if (s) {
if (s->f && !is_stdio(s->f)) {
#if !defined(__wasi__)
if (s->is_popen)
pclose(s->f);
else
#endif
fclose(s->f);
}
js_free_rt(rt, s);
}
}
|
O0
|
c
|
js_std_file_finalizer:
subq $0x28, %rsp
movq %rsi, 0x18(%rsp)
movq %rdx, 0x20(%rsp)
movq %rdi, 0x10(%rsp)
movq 0x10(%rsp), %rdi
callq 0x178c0
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rax
movl 0x78(%rax), %edx
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rsi
callq 0x3e640
movq %rax, (%rsp)
cmpq $0x0, (%rsp)
je 0x18b63
movq (%rsp), %rax
cmpq $0x0, (%rax)
je 0x18b55
movq (%rsp), %rax
movq (%rax), %rdi
callq 0x18b70
cmpl $0x0, %eax
jne 0x18b55
movq (%rsp), %rax
cmpl $0x0, 0x8(%rax)
je 0x18b47
movq (%rsp), %rax
movq (%rax), %rdi
callq 0xe2e0
jmp 0x18b53
movq (%rsp), %rax
movq (%rax), %rdi
callq 0xe240
jmp 0x18b55
movq 0x10(%rsp), %rdi
movq (%rsp), %rsi
callq 0x27c50
addq $0x28, %rsp
retq
nopl (%rax,%rax)
|
js_std_file_finalizer:
sub rsp, 28h
mov [rsp+28h+var_10], rsi
mov [rsp+28h+var_8], rdx
mov [rsp+28h+var_18], rdi
mov rdi, [rsp+28h+var_18]
call js_get_thread_state
mov [rsp+28h+var_20], rax
mov rax, [rsp+28h+var_20]
mov edx, [rax+78h]
mov rdi, [rsp+28h+var_10]
mov rsi, [rsp+28h+var_8]
call JS_GetOpaque
mov [rsp+28h+var_28], rax
cmp [rsp+28h+var_28], 0
jz short loc_18B63
mov rax, [rsp+28h+var_28]
cmp qword ptr [rax], 0
jz short loc_18B55
mov rax, [rsp+28h+var_28]
mov rdi, [rax]
call is_stdio
cmp eax, 0
jnz short loc_18B55
mov rax, [rsp+28h+var_28]
cmp dword ptr [rax+8], 0
jz short loc_18B47
mov rax, [rsp+28h+var_28]
mov rdi, [rax]
call _pclose
jmp short loc_18B53
loc_18B47:
mov rax, [rsp+28h+var_28]
mov rdi, [rax]
call _fclose
loc_18B53:
jmp short $+2
loc_18B55:
mov rdi, [rsp+28h+var_18]
mov rsi, [rsp+28h+var_28]
call js_free_rt
loc_18B63:
add rsp, 28h
retn
|
_QWORD * js_std_file_finalizer(long long a1, long long a2, long long a3, int a4, int a5, int a6)
{
_QWORD *result; // rax
_QWORD *v7; // [rsp+0h] [rbp-28h]
long long thread_state; // [rsp+8h] [rbp-20h]
thread_state = js_get_thread_state(a1, a2, a3, a4, a5, a6);
result = (_QWORD *)JS_GetOpaque(a2, a3, *(unsigned int *)(thread_state + 120));
v7 = result;
if ( result )
{
if ( *result && !(unsigned int)is_stdio(*result) )
{
if ( *((_DWORD *)v7 + 2) )
pclose(*v7);
else
fclose(*v7);
}
return (_QWORD *)js_free_rt(a1, v7);
}
return result;
}
|
js_std_file_finalizer:
SUB RSP,0x28
MOV qword ptr [RSP + 0x18],RSI
MOV qword ptr [RSP + 0x20],RDX
MOV qword ptr [RSP + 0x10],RDI
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x001178c0
MOV qword ptr [RSP + 0x8],RAX
MOV RAX,qword ptr [RSP + 0x8]
MOV EDX,dword ptr [RAX + 0x78]
MOV RDI,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RSP + 0x20]
CALL 0x0013e640
MOV qword ptr [RSP],RAX
CMP qword ptr [RSP],0x0
JZ 0x00118b63
MOV RAX,qword ptr [RSP]
CMP qword ptr [RAX],0x0
JZ 0x00118b55
MOV RAX,qword ptr [RSP]
MOV RDI,qword ptr [RAX]
CALL 0x00118b70
CMP EAX,0x0
JNZ 0x00118b55
MOV RAX,qword ptr [RSP]
CMP dword ptr [RAX + 0x8],0x0
JZ 0x00118b47
MOV RAX,qword ptr [RSP]
MOV RDI,qword ptr [RAX]
CALL 0x0010e2e0
JMP 0x00118b53
LAB_00118b47:
MOV RAX,qword ptr [RSP]
MOV RDI,qword ptr [RAX]
CALL 0x0010e240
LAB_00118b53:
JMP 0x00118b55
LAB_00118b55:
MOV RDI,qword ptr [RSP + 0x10]
MOV RSI,qword ptr [RSP]
CALL 0x00127c50
LAB_00118b63:
ADD RSP,0x28
RET
|
void js_std_file_finalizer(int8 param_1,int8 param_2,int8 param_3)
{
int iVar1;
long lVar2;
long *plVar3;
lVar2 = js_get_thread_state(param_1);
plVar3 = (long *)JS_GetOpaque(param_2,param_3,*(int4 *)(lVar2 + 0x78));
if (plVar3 != (long *)0x0) {
if ((*plVar3 != 0) && (iVar1 = is_stdio(*plVar3), iVar1 == 0)) {
if ((int)plVar3[1] == 0) {
fclose((FILE *)*plVar3);
}
else {
pclose((FILE *)*plVar3);
}
}
js_free_rt(param_1,plVar3);
}
return;
}
|
|
9,979 |
js_std_file_finalizer
|
bluesky950520[P]quickjs/quickjs-libc.c
|
static void js_std_file_finalizer(JSRuntime *rt, JSValue val)
{
JSThreadState *ts = js_get_thread_state(rt);
JSSTDFile *s = JS_GetOpaque(val, ts->std_file_class_id);
if (s) {
if (s->f && !is_stdio(s->f)) {
#if !defined(__wasi__)
if (s->is_popen)
pclose(s->f);
else
#endif
fclose(s->f);
}
js_free_rt(rt, s);
}
}
|
O1
|
c
|
js_std_file_finalizer:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
xorl %edi, %edi
movq %rbx, %rsi
xorl %eax, %eax
callq 0x3e64f
movl 0x78(%rax), %edx
movq %r15, %rdi
movq %r14, %rsi
callq 0x2b5f2
testq %rax, %rax
je 0x19ed6
movq %rax, %r14
movq (%rax), %rdi
testq %rdi, %rdi
je 0x19ee1
movq 0xb811d(%rip), %rax # 0xd1fc8
cmpq %rdi, (%rax)
je 0x19ee1
movq 0xb8109(%rip), %rax # 0xd1fc0
cmpq %rdi, (%rax)
je 0x19ee1
movq 0xb8135(%rip), %rax # 0xd1ff8
cmpq %rdi, (%rax)
je 0x19ee1
cmpl $0x0, 0x8(%r14)
je 0x19edc
callq 0xe2f0
jmp 0x19ee1
popq %rbx
popq %r14
popq %r15
retq
callq 0xe250
movq %rbx, %rdi
movq %r14, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x20ae0
|
js_std_file_finalizer:
push r15
push r14
push rbx
mov r14, rdx
mov r15, rsi
mov rbx, rdi
xor edi, edi
mov rsi, rbx
xor eax, eax
call js_std_cmd
mov edx, [rax+78h]
mov rdi, r15
mov rsi, r14
call JS_GetOpaque
test rax, rax
jz short loc_19ED6
mov r14, rax
mov rdi, [rax]
test rdi, rdi
jz short loc_19EE1
mov rax, cs:stdin_ptr
cmp [rax], rdi
jz short loc_19EE1
mov rax, cs:stdout_ptr
cmp [rax], rdi
jz short loc_19EE1
mov rax, cs:stderr_ptr
cmp [rax], rdi
jz short loc_19EE1
cmp dword ptr [r14+8], 0
jz short loc_19EDC
call _pclose
jmp short loc_19EE1
loc_19ED6:
pop rbx
pop r14
pop r15
retn
loc_19EDC:
call _fclose
loc_19EE1:
mov rdi, rbx
mov rsi, r14
pop rbx
pop r14
pop r15
jmp js_free_rt
|
long long js_std_file_finalizer(long long a1, long long a2, long long a3, int a4, int a5, int a6)
{
long long v8; // rax
long long result; // rax
long long v10; // r14
long long v11; // rdi
v8 = js_std_cmd(0, a1, a3, a4, a5, a6);
result = JS_GetOpaque(a2, a3, *(unsigned int *)(v8 + 120));
if ( result )
{
v10 = result;
v11 = *(_QWORD *)result;
if ( *(_QWORD *)result && stdin != v11 && stdout != v11 && stderr != v11 )
{
if ( *(_DWORD *)(result + 8) )
pclose();
else
fclose(v11);
}
return js_free_rt(a1, v10);
}
return result;
}
|
js_std_file_finalizer:
PUSH R15
PUSH R14
PUSH RBX
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
XOR EDI,EDI
MOV RSI,RBX
XOR EAX,EAX
CALL 0x0013e64f
MOV EDX,dword ptr [RAX + 0x78]
MOV RDI,R15
MOV RSI,R14
CALL 0x0012b5f2
TEST RAX,RAX
JZ 0x00119ed6
MOV R14,RAX
MOV RDI,qword ptr [RAX]
TEST RDI,RDI
JZ 0x00119ee1
MOV RAX,qword ptr [0x001d1fc8]
CMP qword ptr [RAX],RDI
JZ 0x00119ee1
MOV RAX,qword ptr [0x001d1fc0]
CMP qword ptr [RAX],RDI
JZ 0x00119ee1
MOV RAX,qword ptr [0x001d1ff8]
CMP qword ptr [RAX],RDI
JZ 0x00119ee1
CMP dword ptr [R14 + 0x8],0x0
JZ 0x00119edc
CALL 0x0010e2f0
JMP 0x00119ee1
LAB_00119ed6:
POP RBX
POP R14
POP R15
RET
LAB_00119edc:
CALL 0x0010e250
LAB_00119ee1:
MOV RDI,RBX
MOV RSI,R14
POP RBX
POP R14
POP R15
JMP 0x00120ae0
|
void js_std_file_finalizer(int8 param_1,int8 param_2,int8 param_3)
{
FILE *__stream;
long lVar1;
int8 *puVar2;
lVar1 = js_std_cmd(0,param_1);
puVar2 = (int8 *)JS_GetOpaque(param_2,param_3,*(int4 *)(lVar1 + 0x78));
if (puVar2 != (int8 *)0x0) {
__stream = (FILE *)*puVar2;
if ((((__stream != (FILE *)0x0) && (*(FILE **)PTR_stdin_001d1fc8 != __stream)) &&
(*(FILE **)PTR_stdout_001d1fc0 != __stream)) && (*(FILE **)PTR_stderr_001d1ff8 != __stream))
{
if (*(int *)(puVar2 + 1) == 0) {
fclose(__stream);
}
else {
pclose(__stream);
}
}
js_free_rt(param_1,puVar2);
return;
}
return;
}
|
|
9,980 |
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
|
monkey531[P]llama/common/json.hpp
|
inline void grisu2(char* buf, int& len, int& decimal_exponent,
diyfp m_minus, diyfp v, diyfp m_plus)
{
JSON_ASSERT(m_plus.e == m_minus.e);
JSON_ASSERT(m_plus.e == v.e);
// --------(-----------------------+-----------------------)-------- (A)
// m- v m+
//
// --------------------(-----------+-----------------------)-------- (B)
// m- v m+
//
// First scale v (and m- and m+) such that the exponent is in the range
// [alpha, gamma].
const cached_power cached = get_cached_power_for_binary_exponent(m_plus.e);
const diyfp c_minus_k(cached.f, cached.e); // = c ~= 10^-k
// The exponent of the products is = v.e + c_minus_k.e + q and is in the range [alpha,gamma]
const diyfp w = diyfp::mul(v, c_minus_k);
const diyfp w_minus = diyfp::mul(m_minus, c_minus_k);
const diyfp w_plus = diyfp::mul(m_plus, c_minus_k);
// ----(---+---)---------------(---+---)---------------(---+---)----
// w- w w+
// = c*m- = c*v = c*m+
//
// diyfp::mul rounds its result and c_minus_k is approximated too. w, w- and
// w+ are now off by a small amount.
// In fact:
//
// w - v * 10^k < 1 ulp
//
// To account for this inaccuracy, add resp. subtract 1 ulp.
//
// --------+---[---------------(---+---)---------------]---+--------
// w- M- w M+ w+
//
// Now any number in [M-, M+] (bounds included) will round to w when input,
// regardless of how the input rounding algorithm breaks ties.
//
// And digit_gen generates the shortest possible such number in [M-, M+].
// Note that this does not mean that Grisu2 always generates the shortest
// possible number in the interval (m-, m+).
const diyfp M_minus(w_minus.f + 1, w_minus.e);
const diyfp M_plus (w_plus.f - 1, w_plus.e );
decimal_exponent = -cached.k; // = -(-k) = k
grisu2_digit_gen(buf, len, decimal_exponent, M_minus, w, M_plus);
}
|
O1
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rdi, %rax
movq %rcx, 0x58(%rsp)
movl %r8d, 0x60(%rsp)
movl 0xc8(%rsp), %edi
cmpl %r8d, %edi
jne 0x50140
movq %rax, 0x20(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
leaq 0xb0(%rsp), %r13
cmpl 0x8(%r13), %edi
jne 0x5015c
callq 0x50217
movq %rdx, %r12
leaq 0x68(%rsp), %r14
movq %rax, (%r14)
movl %r12d, 0x8(%r14)
movq %r13, %rdi
movq %r14, %rsi
callq 0x50358
movq %rax, %r15
movl %edx, %ebx
leaq 0x58(%rsp), %rdi
movq %r14, %rsi
callq 0x50358
movq %rax, %r13
movl %edx, %ebp
leaq 0xc0(%rsp), %rdi
movq %r14, %rsi
callq 0x50358
incq %r13
decq %rax
shrq $0x20, %r12
negl %r12d
movq 0x30(%rsp), %rcx
movl %r12d, (%rcx)
movq %r15, 0x48(%rsp)
movl %ebx, 0x50(%rsp)
movq %rax, 0x38(%rsp)
movl %edx, 0x40(%rsp)
movups 0x38(%rsp), %xmm0
movups %xmm0, 0x10(%rsp)
movups 0x48(%rsp), %xmm0
movups %xmm0, (%rsp)
movq 0x20(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq %rcx, %rdx
movq %r13, %rcx
movl %ebp, %r8d
callq 0x503b4
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x6a653(%rip), %rdi # 0xba79a
leaq 0x68034(%rip), %rdx # 0xb8182
leaq 0x6adfc(%rip), %rcx # 0xbaf51
movl $0x454b, %esi # imm = 0x454B
jmp 0x50176
leaq 0x6a637(%rip), %rdi # 0xba79a
leaq 0x68018(%rip), %rdx # 0xb8182
leaq 0x6adf6(%rip), %rcx # 0xbaf67
movl $0x454c, %esi # imm = 0x454C
xorl %eax, %eax
callq 0x19b30
nop
|
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl6grisu2EPcRiS4_NS2_5diyfpES5_S5_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 78h
mov rax, rdi
mov [rsp+0A8h+var_50], rcx
mov [rsp+0A8h+var_48], r8d
mov edi, dword ptr [rsp+0A8h+arg_18]; this
cmp edi, r8d
jnz loc_50140
mov [rsp+0A8h+var_88], rax
mov [rsp+0A8h+var_80], rsi
mov [rsp+0A8h+var_78], rdx
lea r13, [rsp+0A8h+arg_0]
cmp edi, [r13+8]
jnz loc_5015C
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl36get_cached_power_for_binary_exponentEi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)
mov r12, rdx
lea r14, [rsp+0A8h+var_40]
mov [r14], rax
mov [r14+8], r12d
mov rdi, r13
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r15, rax
mov ebx, edx
lea rdi, [rsp+0A8h+var_50]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r13, rax
mov ebp, edx
lea rdi, [rsp+0A8h+arg_10]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
inc r13
dec rax
shr r12, 20h
neg r12d
mov rcx, [rsp+0A8h+var_78]
mov [rcx], r12d
mov qword ptr [rsp+0A8h+var_60], r15
mov dword ptr [rsp+0A8h+var_60+8], ebx
mov qword ptr [rsp+0A8h+var_70], rax
mov dword ptr [rsp+0A8h+var_70+8], edx
movups xmm0, [rsp+0A8h+var_70]
movups [rsp+0A8h+var_98], xmm0
movups xmm0, [rsp+0A8h+var_60]
movups [rsp+0A8h+var_A8], xmm0
mov rdi, [rsp+0A8h+var_88]
mov rsi, [rsp+0A8h+var_80]
mov rdx, rcx
mov rcx, r13
mov r8d, ebp
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl16grisu2_digit_genEPcRiS4_NS2_5diyfpES5_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(char *,int &,int &,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
add rsp, 78h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_50140:
lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEMMinusE; "m_plus.e == m_minus.e"
mov esi, 454Bh
jmp short loc_50176
loc_5015C:
lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEVE; "m_plus.e == v.e"
mov esi, 454Ch
loc_50176:
xor eax, eax
call _ggml_abort
nop
|
long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(
int a1,
int a2,
_DWORD *a3,
long long a4,
int a5,
int a6,
char a7,
int a8,
char a9,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *a10)
{
long long cached_power_for_binary_exponent; // rax
int v11; // rdx^4
int v12; // r12^4
int v13; // edx
char v14; // r15
int v15; // edx
int v16; // ebx
int v17; // r13d
int v18; // edx
int v19; // ebp
char v20; // al
int v21; // edx
int v22; // r9d
long long v24; // rsi
long long v26; // [rsp+58h] [rbp-50h] BYREF
int v27; // [rsp+60h] [rbp-48h]
long long v28; // [rsp+68h] [rbp-40h] BYREF
int v29; // [rsp+70h] [rbp-38h]
v26 = a4;
v27 = a5;
if ( (_DWORD)a10 == a5 )
{
if ( (_DWORD)a10 == a8 )
{
cached_power_for_binary_exponent = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)(unsigned int)a10,
a2);
v12 = v11;
v28 = cached_power_for_binary_exponent;
v29 = v13;
v14 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a7, &v28);
v16 = v15;
v17 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&v26, &v28);
v19 = v18;
v20 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a9, &v28);
*a3 = -v12;
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(
a1,
a2,
(_DWORD)a3,
v17 + 1,
v19,
v22,
v14,
v16,
v20 - 1,
v21);
}
v24 = 17740LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17740LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == v.e");
}
else
{
v24 = 17739LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17739LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == m_minus.e");
}
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::normalize(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
v24);
}
|
grisu2:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x78
MOV RAX,RDI
MOV qword ptr [RSP + 0x58],RCX
MOV dword ptr [RSP + 0x60],R8D
MOV EDI,dword ptr [RSP + 0xc8]
CMP EDI,R8D
JNZ 0x00150140
MOV qword ptr [RSP + 0x20],RAX
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x30],RDX
LEA R13,[RSP + 0xb0]
CMP EDI,dword ptr [R13 + 0x8]
JNZ 0x0015015c
CALL 0x00150217
MOV R12,RDX
LEA R14,[RSP + 0x68]
MOV qword ptr [R14],RAX
MOV dword ptr [R14 + 0x8],R12D
MOV RDI,R13
MOV RSI,R14
CALL 0x00150358
MOV R15,RAX
MOV EBX,EDX
LEA RDI,[RSP + 0x58]
MOV RSI,R14
CALL 0x00150358
MOV R13,RAX
MOV EBP,EDX
LEA RDI,[RSP + 0xc0]
MOV RSI,R14
CALL 0x00150358
INC R13
DEC RAX
SHR R12,0x20
NEG R12D
MOV RCX,qword ptr [RSP + 0x30]
MOV dword ptr [RCX],R12D
MOV qword ptr [RSP + 0x48],R15
MOV dword ptr [RSP + 0x50],EBX
MOV qword ptr [RSP + 0x38],RAX
MOV dword ptr [RSP + 0x40],EDX
MOVUPS XMM0,xmmword ptr [RSP + 0x38]
MOVUPS xmmword ptr [RSP + 0x10],XMM0
MOVUPS XMM0,xmmword ptr [RSP + 0x48]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,RCX
MOV RCX,R13
MOV R8D,EBP
CALL 0x001503b4
ADD RSP,0x78
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00150140:
LEA RDI,[0x1ba79a]
LEA RDX,[0x1b8182]
LEA RCX,[0x1baf51]
MOV ESI,0x454b
JMP 0x00150176
LAB_0015015c:
LEA RDI,[0x1ba79a]
LEA RDX,[0x1b8182]
LEA RCX,[0x1baf67]
MOV ESI,0x454c
LAB_00150176:
XOR EAX,EAX
CALL 0x00119b30
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp) */
void nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2
(int8 param_1,int8 param_2,int *param_3,int8 param_4,int param_5,
int8 param_6,int8 param_7,int param_8,int8 param_9,int param_10)
{
int4 uVar1;
char *pcVar2;
int4 extraout_EDX;
int8 uVar3;
int1 auVar4 [12];
int1 auVar5 [12];
int1 auVar6 [16];
int4 uStack_64;
int8 local_50;
int local_48;
int8 local_40;
int4 local_38;
local_50 = param_4;
local_48 = param_5;
if (param_10 == param_5) {
if (param_10 == param_8) {
auVar6 = get_cached_power_for_binary_exponent(param_10);
local_40 = auVar6._0_8_;
local_38 = auVar6._8_4_;
uVar1 = diyfp::mul((diyfp *)¶m_7,(diyfp *)&local_40);
auVar4 = diyfp::mul((diyfp *)&local_50,(diyfp *)&local_40);
auVar5 = diyfp::mul((diyfp *)¶m_9,(diyfp *)&local_40);
*param_3 = -auVar6._12_4_;
grisu2_digit_gen(param_1,param_2,param_3,auVar4._0_8_ + 1,auVar4._8_4_,param_6,uVar1,
extraout_EDX,auVar5._0_8_ + -1,CONCAT44(uStack_64,auVar5._8_4_));
return;
}
pcVar2 = "m_plus.e == v.e";
uVar3 = 0x454c;
}
else {
pcVar2 = "m_plus.e == m_minus.e";
uVar3 = 0x454b;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
|
|
9,981 |
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
|
monkey531[P]llama/common/json.hpp
|
inline void grisu2(char* buf, int& len, int& decimal_exponent,
diyfp m_minus, diyfp v, diyfp m_plus)
{
JSON_ASSERT(m_plus.e == m_minus.e);
JSON_ASSERT(m_plus.e == v.e);
// --------(-----------------------+-----------------------)-------- (A)
// m- v m+
//
// --------------------(-----------+-----------------------)-------- (B)
// m- v m+
//
// First scale v (and m- and m+) such that the exponent is in the range
// [alpha, gamma].
const cached_power cached = get_cached_power_for_binary_exponent(m_plus.e);
const diyfp c_minus_k(cached.f, cached.e); // = c ~= 10^-k
// The exponent of the products is = v.e + c_minus_k.e + q and is in the range [alpha,gamma]
const diyfp w = diyfp::mul(v, c_minus_k);
const diyfp w_minus = diyfp::mul(m_minus, c_minus_k);
const diyfp w_plus = diyfp::mul(m_plus, c_minus_k);
// ----(---+---)---------------(---+---)---------------(---+---)----
// w- w w+
// = c*m- = c*v = c*m+
//
// diyfp::mul rounds its result and c_minus_k is approximated too. w, w- and
// w+ are now off by a small amount.
// In fact:
//
// w - v * 10^k < 1 ulp
//
// To account for this inaccuracy, add resp. subtract 1 ulp.
//
// --------+---[---------------(---+---)---------------]---+--------
// w- M- w M+ w+
//
// Now any number in [M-, M+] (bounds included) will round to w when input,
// regardless of how the input rounding algorithm breaks ties.
//
// And digit_gen generates the shortest possible such number in [M-, M+].
// Note that this does not mean that Grisu2 always generates the shortest
// possible number in the interval (m-, m+).
const diyfp M_minus(w_minus.f + 1, w_minus.e);
const diyfp M_plus (w_plus.f - 1, w_plus.e );
decimal_exponent = -cached.k; // = -(-k) = k
grisu2_digit_gen(buf, len, decimal_exponent, M_minus, w, M_plus);
}
|
O3
|
cpp
|
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp, nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rcx, 0x58(%rsp)
movl %r8d, 0x60(%rsp)
cmpl %r8d, 0xc8(%rsp)
jne 0x4f500
movq %rdi, 0x20(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
leaq 0xb0(%rsp), %r13
cmpl %r8d, 0x8(%r13)
jne 0x4f51c
movl %r8d, %edi
callq 0x4f5d7
movq %rdx, %r12
leaq 0x68(%rsp), %r14
movq %rax, (%r14)
movl %r12d, 0x8(%r14)
movq %r13, %rdi
movq %r14, %rsi
callq 0x4f718
movq %rax, %r15
movl %edx, %ebx
leaq 0x58(%rsp), %rdi
movq %r14, %rsi
callq 0x4f718
movq %rax, %r13
movl %edx, %ebp
leaq 0xc0(%rsp), %rdi
movq %r14, %rsi
callq 0x4f718
incq %r13
decq %rax
shrq $0x20, %r12
negl %r12d
movq 0x30(%rsp), %rcx
movl %r12d, (%rcx)
movq %r15, 0x48(%rsp)
movl %ebx, 0x50(%rsp)
movq %rax, 0x38(%rsp)
movl %edx, 0x40(%rsp)
movups 0x38(%rsp), %xmm0
movups %xmm0, 0x10(%rsp)
movups 0x48(%rsp), %xmm0
movups %xmm0, (%rsp)
movq 0x20(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq %rcx, %rdx
movq %r13, %rcx
movl %ebp, %r8d
callq 0x4f774
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x68293(%rip), %rdi # 0xb779a
leaq 0x65c74(%rip), %rdx # 0xb5182
leaq 0x68a3c(%rip), %rcx # 0xb7f51
movl $0x454b, %esi # imm = 0x454B
jmp 0x4f536
leaq 0x68277(%rip), %rdi # 0xb779a
leaq 0x65c58(%rip), %rdx # 0xb5182
leaq 0x68a36(%rip), %rcx # 0xb7f67
movl $0x454c, %esi # imm = 0x454C
xorl %eax, %eax
callq 0x19b30
nop
|
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl6grisu2EPcRiS4_NS2_5diyfpES5_S5_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 78h
mov [rsp+0A8h+var_50], rcx
mov [rsp+0A8h+var_48], r8d
cmp [rsp+0A8h+arg_18], r8d
jnz loc_4F500
mov [rsp+0A8h+var_88], rdi
mov [rsp+0A8h+var_80], rsi
mov [rsp+0A8h+var_78], rdx
lea r13, [rsp+0A8h+arg_0]
cmp [r13+8], r8d
jnz loc_4F51C
mov edi, r8d; this
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl36get_cached_power_for_binary_exponentEi; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)
mov r12, rdx
lea r14, [rsp+0A8h+var_40]
mov [r14], rax
mov [r14+8], r12d
mov rdi, r13
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r15, rax
mov ebx, edx
lea rdi, [rsp+0A8h+var_50]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
mov r13, rax
mov ebp, edx
lea rdi, [rsp+0A8h+arg_10]
mov rsi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl5diyfp3mulERKS3_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp const&)
inc r13
dec rax
shr r12, 20h
neg r12d
mov rcx, [rsp+0A8h+var_78]
mov [rcx], r12d
mov qword ptr [rsp+0A8h+var_60], r15
mov dword ptr [rsp+0A8h+var_60+8], ebx
mov qword ptr [rsp+0A8h+var_70], rax
mov dword ptr [rsp+0A8h+var_70+8], edx
movups xmm0, xmmword ptr [rsp+0A8h+var_70]
movups xmmword ptr [rsp+0A8h+var_98], xmm0; char
movups xmm0, xmmword ptr [rsp+0A8h+var_60]
movups xmmword ptr [rsp+0A8h+var_A8], xmm0; char
mov rdi, [rsp+0A8h+var_88]; this
mov rsi, [rsp+0A8h+var_80]
mov rdx, rcx
mov rcx, r13
mov r8d, ebp
call _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl16grisu2_digit_genEPcRiS4_NS2_5diyfpES5_S5_; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(char *,int &,int &,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp)
add rsp, 78h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_4F500:
lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEMMinusE; "m_plus.e == m_minus.e"
mov esi, 454Bh
jmp short loc_4F536
loc_4F51C:
lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMPlusEVE; "m_plus.e == v.e"
mov esi, 454Ch
loc_4F536:
xor eax, eax
call _ggml_abort
nop
|
long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *a1,
int a2,
_DWORD *a3,
long long a4,
unsigned int a5,
long long a6,
char a7,
int a8,
char a9,
int a10)
{
long long cached_power_for_binary_exponent; // rax
int v11; // rdx^4
int v12; // r12^4
int v13; // edx
char v14; // r15
int v15; // edx
int v16; // ebx
char v17; // al
int v18; // edx
long long v20; // rsi
long long v22; // [rsp+58h] [rbp-50h] BYREF
unsigned int v23; // [rsp+60h] [rbp-48h]
long long v24; // [rsp+68h] [rbp-40h] BYREF
int v25; // [rsp+70h] [rbp-38h]
v22 = a4;
v23 = a5;
if ( a10 == a5 )
{
if ( a8 == a5 )
{
cached_power_for_binary_exponent = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(
(nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)a5,
a2);
v12 = v11;
v24 = cached_power_for_binary_exponent;
v25 = v13;
v14 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a7, &v24);
v16 = v15;
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&v22, &v24);
v17 = nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul(&a9, &v24);
*a3 = -v12;
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_digit_gen(a1, v14, v16, v17 - 1, v18);
}
v20 = 17740LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17740LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == v.e");
}
else
{
v20 = 17739LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17739LL,
"GGML_ASSERT(%s) failed",
"m_plus.e == m_minus.e");
}
return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::normalize(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
v20);
}
|
grisu2:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x78
MOV qword ptr [RSP + 0x58],RCX
MOV dword ptr [RSP + 0x60],R8D
CMP dword ptr [RSP + 0xc8],R8D
JNZ 0x0014f500
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x30],RDX
LEA R13,[RSP + 0xb0]
CMP dword ptr [R13 + 0x8],R8D
JNZ 0x0014f51c
MOV EDI,R8D
CALL 0x0014f5d7
MOV R12,RDX
LEA R14,[RSP + 0x68]
MOV qword ptr [R14],RAX
MOV dword ptr [R14 + 0x8],R12D
MOV RDI,R13
MOV RSI,R14
CALL 0x0014f718
MOV R15,RAX
MOV EBX,EDX
LEA RDI,[RSP + 0x58]
MOV RSI,R14
CALL 0x0014f718
MOV R13,RAX
MOV EBP,EDX
LEA RDI,[RSP + 0xc0]
MOV RSI,R14
CALL 0x0014f718
INC R13
DEC RAX
SHR R12,0x20
NEG R12D
MOV RCX,qword ptr [RSP + 0x30]
MOV dword ptr [RCX],R12D
MOV qword ptr [RSP + 0x48],R15
MOV dword ptr [RSP + 0x50],EBX
MOV qword ptr [RSP + 0x38],RAX
MOV dword ptr [RSP + 0x40],EDX
MOVUPS XMM0,xmmword ptr [RSP + 0x38]
MOVUPS xmmword ptr [RSP + 0x10],XMM0
MOVUPS XMM0,xmmword ptr [RSP + 0x48]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,RCX
MOV RCX,R13
MOV R8D,EBP
CALL 0x0014f774
ADD RSP,0x78
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0014f500:
LEA RDI,[0x1b779a]
LEA RDX,[0x1b5182]
LEA RCX,[0x1b7f51]
MOV ESI,0x454b
JMP 0x0014f536
LAB_0014f51c:
LEA RDI,[0x1b779a]
LEA RDX,[0x1b5182]
LEA RCX,[0x1b7f67]
MOV ESI,0x454c
LAB_0014f536:
XOR EAX,EAX
CALL 0x00119b30
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2(char*, int&, int&,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp,
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp) */
void nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2
(int8 param_1,int8 param_2,int *param_3,int8 param_4,int param_5,
int8 param_6,int8 param_7,int param_8,int8 param_9,int param_10)
{
int4 uVar1;
char *pcVar2;
int4 extraout_EDX;
int8 uVar3;
int1 auVar4 [12];
int1 auVar5 [12];
int1 auVar6 [16];
int4 uStack_64;
int8 local_50;
int local_48;
int8 local_40;
int4 local_38;
local_50 = param_4;
local_48 = param_5;
if (param_10 == param_5) {
if (param_8 == param_5) {
auVar6 = get_cached_power_for_binary_exponent(param_5);
local_40 = auVar6._0_8_;
local_38 = auVar6._8_4_;
uVar1 = diyfp::mul((diyfp *)¶m_7,(diyfp *)&local_40);
auVar4 = diyfp::mul((diyfp *)&local_50,(diyfp *)&local_40);
auVar5 = diyfp::mul((diyfp *)¶m_9,(diyfp *)&local_40);
*param_3 = -auVar6._12_4_;
grisu2_digit_gen(param_1,param_2,param_3,auVar4._0_8_ + 1,auVar4._8_4_,param_6,uVar1,
extraout_EDX,auVar5._0_8_ + -1,CONCAT44(uStack_64,auVar5._8_4_));
return;
}
pcVar2 = "m_plus.e == v.e";
uVar3 = 0x454c;
}
else {
pcVar2 = "m_plus.e == m_minus.e";
uVar3 = 0x454b;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
|
|
9,982 |
nglog::tools::ProgramInvocationShortName()
|
ng-log[P]ng-log/src/utilities.cc
|
const char* ProgramInvocationShortName() {
if (g_program_invocation_short_name != nullptr) {
return g_program_invocation_short_name;
}
#if defined(HAVE_PROGRAM_INVOCATION_SHORT_NAME)
return program_invocation_short_name;
#elif defined(HAVE_GETPROGNAME)
return getprogname();
#elif defined(HAVE___PROGNAME)
return __progname;
#elif defined(HAVE___ARGV)
return const_basename(__argv[0]);
#else
return "UNKNOWN";
#endif
}
|
O0
|
cpp
|
nglog::tools::ProgramInvocationShortName():
pushq %rbp
movq %rsp, %rbp
cmpq $0x0, 0x4179c(%rip) # 0xac338
je 0x6abab
movq 0x41793(%rip), %rax # 0xac338
movq %rax, -0x8(%rbp)
jmp 0x6abb9
movq 0x303ee(%rip), %rax # 0x9afa0
movq (%rax), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
popq %rbp
retq
nop
|
_ZN5nglog5tools26ProgramInvocationShortNameEv:
push rbp
mov rbp, rsp
cmp cs:_ZN5nglogL31g_program_invocation_short_nameE, 0; nglog::g_program_invocation_short_name
jz short loc_6ABAB
mov rax, cs:_ZN5nglogL31g_program_invocation_short_nameE; nglog::g_program_invocation_short_name
mov [rbp+var_8], rax
jmp short loc_6ABB9
loc_6ABAB:
mov rax, cs:program_invocation_short_name_ptr
mov rax, [rax]
mov [rbp+var_8], rax
loc_6ABB9:
mov rax, [rbp+var_8]
pop rbp
retn
|
long long nglog::tools::ProgramInvocationShortName(nglog::tools *this)
{
if ( nglog::g_program_invocation_short_name )
return nglog::g_program_invocation_short_name;
else
return program_invocation_short_name;
}
|
ProgramInvocationShortName:
PUSH RBP
MOV RBP,RSP
CMP qword ptr [0x001ac338],0x0
JZ 0x0016abab
MOV RAX,qword ptr [0x001ac338]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0016abb9
LAB_0016abab:
MOV RAX,qword ptr [0x0019afa0]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x8],RAX
LAB_0016abb9:
MOV RAX,qword ptr [RBP + -0x8]
POP RBP
RET
|
/* nglog::tools::ProgramInvocationShortName() */
long nglog::tools::ProgramInvocationShortName(void)
{
int8 local_10;
if (g_program_invocation_short_name == 0) {
local_10 = *(long *)PTR_program_invocation_short_name_0019afa0;
}
else {
local_10 = g_program_invocation_short_name;
}
return local_10;
}
|
|
9,983 |
minja::ExpressionTemplateToken::~ExpressionTemplateToken()
|
monkey531[P]llama/common/minja.hpp
|
ExpressionTemplateToken(const Location & location, SpaceHandling pre, SpaceHandling post, std::shared_ptr<Expression> && e) : TemplateToken(Type::Expression, location, pre, post), expr(std::move(e)) {}
|
O1
|
cpp
|
minja::ExpressionTemplateToken::~ExpressionTemplateToken():
pushq %rbx
movq %rdi, %rbx
leaq 0x9aa6f(%rip), %rax # 0x157ae8
addq $0x10, %rax
movq %rax, (%rdi)
movq 0x38(%rdi), %rdi
testq %rdi, %rdi
je 0xbd08e
callq 0x520bc
leaq 0x9a243(%rip), %rax # 0x1572d8
addq $0x10, %rax
movq %rax, (%rbx)
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0xbd0aa
callq 0x520bc
movl $0x40, %esi
movq %rbx, %rdi
popq %rbx
jmp 0x1dc40
|
_ZN5minja23ExpressionTemplateTokenD0Ev:
push rbx
mov rbx, rdi
lea rax, _ZTVN5minja23ExpressionTemplateTokenE; `vtable for'minja::ExpressionTemplateToken
add rax, 10h
mov [rdi], rax
mov rdi, [rdi+38h]
test rdi, rdi
jz short loc_BD08E
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_BD08E:
lea rax, _ZTVN5minja13TemplateTokenE; `vtable for'minja::TemplateToken
add rax, 10h
mov [rbx], rax
mov rdi, [rbx+18h]
test rdi, rdi
jz short loc_BD0AA
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_BD0AA:
mov esi, 40h ; '@'; unsigned __int64
mov rdi, rbx; void *
pop rbx
jmp __ZdlPvm; operator delete(void *,ulong)
|
void minja::ExpressionTemplateToken::~ExpressionTemplateToken(minja::ExpressionTemplateToken *this)
{
volatile signed __int32 *v2; // rdi
volatile signed __int32 *v3; // rdi
*(_QWORD *)this = &`vtable for'minja::ExpressionTemplateToken + 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);
}
|
~ExpressionTemplateToken:
PUSH RBX
MOV RBX,RDI
LEA RAX,[0x257ae8]
ADD RAX,0x10
MOV qword ptr [RDI],RAX
MOV RDI,qword ptr [RDI + 0x38]
TEST RDI,RDI
JZ 0x001bd08e
CALL 0x001520bc
LAB_001bd08e:
LEA RAX,[0x2572d8]
ADD RAX,0x10
MOV qword ptr [RBX],RAX
MOV RDI,qword ptr [RBX + 0x18]
TEST RDI,RDI
JZ 0x001bd0aa
CALL 0x001520bc
LAB_001bd0aa:
MOV ESI,0x40
MOV RDI,RBX
POP RBX
JMP 0x0011dc40
|
/* minja::ExpressionTemplateToken::~ExpressionTemplateToken() */
void __thiscall
minja::ExpressionTemplateToken::~ExpressionTemplateToken(ExpressionTemplateToken *this)
{
*(int ***)this = &PTR__ExpressionTemplateToken_00257af8;
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_002572e8;
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;
}
|
|
9,984 |
my_mb_wc_filename
|
eloqsql/strings/ctype-utf8.c
|
static int
my_mb_wc_filename(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t *pwc, const uchar *s, const uchar *e)
{
int byte1, byte2;
if (s >= e)
return MY_CS_TOOSMALL;
if (*s < 128 && filename_safe_char[*s])
{
*pwc= *s;
return 1;
}
if (*s != MY_FILENAME_ESCAPE)
return MY_CS_ILSEQ;
if (s + 3 > e)
return MY_CS_TOOSMALL3;
byte1= s[1];
if (byte1 == 0)
return MY_CS_ILSEQ; /* avoid possible out-of-bounds read */
byte2= s[2];
if (byte1 >= 0x30 && byte1 <= 0x7F &&
byte2 >= 0x30 && byte2 <= 0x7F)
{
int code= (byte1 - 0x30) * 80 + byte2 - 0x30;
if (code < 5994 && touni[code])
{
*pwc= touni[code];
return 3;
}
if (byte1 == '@' && byte2 == '@')
{
*pwc= 0;
return 3;
}
}
if (s + 4 > e)
return MY_CS_TOOSMALL4;
if ((byte1= hexlo(byte1)) >= 0 &&
(byte2= hexlo(byte2)) >= 0)
{
int byte3= hexlo(s[3]);
int byte4= hexlo(s[3] ? s[4] : 0);
if (byte3 >=0 && byte4 >=0)
{
*pwc= (byte1 << 12) + (byte2 << 8) + (byte3 << 4) + byte4;
return 5;
}
}
return MY_CS_ILSEQ;
}
|
O3
|
c
|
my_mb_wc_filename:
pushq %rbp
movq %rsp, %rbp
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmpq %rcx, %rdx
jae 0x5ae26
movsbq (%rdx), %r8
testq %r8, %r8
js 0x5ae24
leaq 0x2823c2(%rip), %rdi # 0x2dd0f0
movl $0x1, %eax
cmpb $0x0, (%r8,%rdi)
je 0x5ad42
movq %r8, (%rsi)
jmp 0x5ae26
cmpb $0x40, %r8b
jne 0x5ae24
leaq 0x3(%rdx), %rdi
movl $0xffffff99, %eax # imm = 0xFFFFFF99
cmpq %rcx, %rdi
ja 0x5ae26
movzbl 0x1(%rdx), %r10d
testl %r10d, %r10d
je 0x5ae24
movb 0x2(%rdx), %al
movzbl %al, %r9d
cmpb $0x30, %r10b
setge %al
cmpb $0x30, %r9b
setge %r8b
andb %al, %r8b
cmpb $0x1, %r8b
jne 0x5addd
leal (%r10,%r10,4), %eax
shll $0x4, %eax
addl %r9d, %eax
addl $0xfffff100, %eax # imm = 0xFFFFF100
cmpl $0x1799, %eax # imm = 0x1799
jg 0x5adbf
addl $-0x30, %eax
leaq 0x2823c5(%rip), %r8 # 0x2dd170
movzwl (%r8,%rax,2), %r8d
testq %r8, %r8
je 0x5adbf
movl $0x3, %eax
jmp 0x5ad3a
movl %r10d, %eax
xorb $0x40, %al
movl %r9d, %r8d
xorb $0x40, %r8b
orb %al, %r8b
jne 0x5addd
movl $0x3, %eax
xorl %r8d, %r8d
jmp 0x5ad3a
addq $0x4, %rdx
movl $0xffffff98, %eax # imm = 0xFFFFFF98
cmpq %rcx, %rdx
ja 0x5ae26
movl %r10d, %eax
leaq 0x28525b(%rip), %r10 # 0x2e0050
movzbl (%rax,%r10), %ecx
testb %cl, %cl
js 0x5ae24
movl %r9d, %eax
movzbl (%rax,%r10), %r9d
movl $0x0, %eax
testb %r9b, %r9b
js 0x5ae26
movzbl (%rdi), %edi
xorl %eax, %eax
movzbl (%rdi,%r10), %r8d
testq %rdi, %rdi
je 0x5ae28
movzbl (%rdx), %edx
jmp 0x5ae2a
xorl %eax, %eax
popq %rbp
retq
xorl %edx, %edx
testb %r8b, %r8b
js 0x5ae26
movb (%rdx,%r10), %dl
testb %dl, %dl
js 0x5ae26
movzbl %dl, %eax
shll $0xc, %ecx
shll $0x8, %r9d
shll $0x4, %r8d
addq %rcx, %r8
addq %r9, %r8
addq %rax, %r8
movl $0x5, %eax
jmp 0x5ad3a
|
my_mb_wc_filename:
push rbp
mov rbp, rsp
mov eax, 0FFFFFF9Bh
cmp rdx, rcx
jnb loc_5AE26
movsx r8, byte ptr [rdx]
test r8, r8
js loc_5AE24
lea rdi, filename_safe_char
mov eax, 1
cmp byte ptr [r8+rdi], 0
jz short loc_5AD42
loc_5AD3A:
mov [rsi], r8
jmp loc_5AE26
loc_5AD42:
cmp r8b, 40h ; '@'
jnz loc_5AE24
lea rdi, [rdx+3]
mov eax, 0FFFFFF99h
cmp rdi, rcx
ja loc_5AE26
movzx r10d, byte ptr [rdx+1]
test r10d, r10d
jz loc_5AE24
mov al, [rdx+2]
movzx r9d, al
cmp r10b, 30h ; '0'
setnl al
cmp r9b, 30h ; '0'
setnl r8b
and r8b, al
cmp r8b, 1
jnz short loc_5ADDD
lea eax, [r10+r10*4]
shl eax, 4
add eax, r9d
add eax, 0FFFFF100h
cmp eax, 1799h
jg short loc_5ADBF
add eax, 0FFFFFFD0h
lea r8, touni
movzx r8d, word ptr [r8+rax*2]
test r8, r8
jz short loc_5ADBF
mov eax, 3
jmp loc_5AD3A
loc_5ADBF:
mov eax, r10d
xor al, 40h
mov r8d, r9d
xor r8b, 40h
or r8b, al
jnz short loc_5ADDD
mov eax, 3
xor r8d, r8d
jmp loc_5AD3A
loc_5ADDD:
add rdx, 4
mov eax, 0FFFFFF98h
cmp rdx, rcx
ja short loc_5AE26
mov eax, r10d
lea r10, hexlo_hex_lo_digit
movzx ecx, byte ptr [rax+r10]
test cl, cl
js short loc_5AE24
mov eax, r9d
movzx r9d, byte ptr [rax+r10]
mov eax, 0
test r9b, r9b
js short loc_5AE26
movzx edi, byte ptr [rdi]
xor eax, eax
movzx r8d, byte ptr [rdi+r10]
test rdi, rdi
jz short loc_5AE28
movzx edx, byte ptr [rdx]
jmp short loc_5AE2A
loc_5AE24:
xor eax, eax
loc_5AE26:
pop rbp
retn
loc_5AE28:
xor edx, edx
loc_5AE2A:
test r8b, r8b
js short loc_5AE26
mov dl, [rdx+r10]
test dl, dl
js short loc_5AE26
movzx eax, dl
shl ecx, 0Ch
shl r9d, 8
shl r8d, 4
add r8, rcx
add r8, r9
add r8, rax
mov eax, 5
jmp loc_5AD3A
|
long long my_mb_wc_filename(long long a1, signed long long *a2, char *a3, unsigned long long a4)
{
long long result; // rax
signed long long v5; // r8
unsigned __int8 *v6; // rdi
int v7; // r10d
int v8; // r9d
long long v9; // rax
unsigned __int8 *v10; // rdx
int v11; // ecx
int v12; // r9d
long long v13; // rdi
int v14; // r8d
long long v15; // rdx
char v16; // dl
result = 4294967195LL;
if ( (unsigned long long)a3 >= a4 )
return result;
v5 = *a3;
if ( v5 < 0 )
return 0LL;
result = 1LL;
if ( filename_safe_char[v5] )
{
LABEL_4:
*a2 = v5;
return result;
}
if ( (_BYTE)v5 != 64 )
return 0LL;
v6 = (unsigned __int8 *)(a3 + 3);
result = 4294967193LL;
if ( (unsigned long long)(a3 + 3) > a4 )
return result;
v7 = (unsigned __int8)a3[1];
if ( !a3[1] )
return 0LL;
v8 = (unsigned __int8)a3[2];
if ( (char)v7 >= 48 && (char)v8 >= 48 )
{
if ( v8 + 80 * v7 - 3840 <= 6041 )
{
v9 = (unsigned int)(v8 + 80 * v7 - 3888);
v5 = touni[v9];
if ( touni[v9] )
{
result = 3LL;
goto LABEL_4;
}
}
if ( !((unsigned __int8)v7 ^ 0x40 | (unsigned __int8)v8 ^ 0x40) )
{
result = 3LL;
v5 = 0LL;
goto LABEL_4;
}
}
v10 = (unsigned __int8 *)(a3 + 4);
result = 4294967192LL;
if ( (unsigned long long)v10 <= a4 )
{
v11 = hexlo_hex_lo_digit[v7];
if ( (v11 & 0x80u) == 0 )
{
v12 = hexlo_hex_lo_digit[v8];
result = 0LL;
if ( (v12 & 0x80u) == 0 )
{
v13 = *v6;
result = 0LL;
v14 = hexlo_hex_lo_digit[v13];
v15 = v13 ? *v10 : 0LL;
if ( (v14 & 0x80u) == 0 )
{
v16 = hexlo_hex_lo_digit[v15];
if ( v16 >= 0 )
{
v5 = (unsigned __int8)v16
+ (unsigned int)(v12 << 8)
+ (unsigned int)(v11 << 12)
+ (unsigned long long)(unsigned int)(16 * v14);
result = 5LL;
goto LABEL_4;
}
}
}
return result;
}
return 0LL;
}
return result;
}
|
my_mb_wc_filename:
PUSH RBP
MOV RBP,RSP
MOV EAX,0xffffff9b
CMP RDX,RCX
JNC 0x0015ae26
MOVSX R8,byte ptr [RDX]
TEST R8,R8
JS 0x0015ae24
LEA RDI,[0x3dd0f0]
MOV EAX,0x1
CMP byte ptr [R8 + RDI*0x1],0x0
JZ 0x0015ad42
LAB_0015ad3a:
MOV qword ptr [RSI],R8
JMP 0x0015ae26
LAB_0015ad42:
CMP R8B,0x40
JNZ 0x0015ae24
LEA RDI,[RDX + 0x3]
MOV EAX,0xffffff99
CMP RDI,RCX
JA 0x0015ae26
MOVZX R10D,byte ptr [RDX + 0x1]
TEST R10D,R10D
JZ 0x0015ae24
MOV AL,byte ptr [RDX + 0x2]
MOVZX R9D,AL
CMP R10B,0x30
SETGE AL
CMP R9B,0x30
SETGE R8B
AND R8B,AL
CMP R8B,0x1
JNZ 0x0015addd
LEA EAX,[R10 + R10*0x4]
SHL EAX,0x4
ADD EAX,R9D
ADD EAX,0xfffff100
CMP EAX,0x1799
JG 0x0015adbf
ADD EAX,-0x30
LEA R8,[0x3dd170]
MOVZX R8D,word ptr [R8 + RAX*0x2]
TEST R8,R8
JZ 0x0015adbf
MOV EAX,0x3
JMP 0x0015ad3a
LAB_0015adbf:
MOV EAX,R10D
XOR AL,0x40
MOV R8D,R9D
XOR R8B,0x40
OR R8B,AL
JNZ 0x0015addd
MOV EAX,0x3
XOR R8D,R8D
JMP 0x0015ad3a
LAB_0015addd:
ADD RDX,0x4
MOV EAX,0xffffff98
CMP RDX,RCX
JA 0x0015ae26
MOV EAX,R10D
LEA R10,[0x3e0050]
MOVZX ECX,byte ptr [RAX + R10*0x1]
TEST CL,CL
JS 0x0015ae24
MOV EAX,R9D
MOVZX R9D,byte ptr [RAX + R10*0x1]
MOV EAX,0x0
TEST R9B,R9B
JS 0x0015ae26
MOVZX EDI,byte ptr [RDI]
XOR EAX,EAX
MOVZX R8D,byte ptr [RDI + R10*0x1]
TEST RDI,RDI
JZ 0x0015ae28
MOVZX EDX,byte ptr [RDX]
JMP 0x0015ae2a
LAB_0015ae24:
XOR EAX,EAX
LAB_0015ae26:
POP RBP
RET
LAB_0015ae28:
XOR EDX,EDX
LAB_0015ae2a:
TEST R8B,R8B
JS 0x0015ae26
MOV DL,byte ptr [RDX + R10*0x1]
TEST DL,DL
JS 0x0015ae26
MOVZX EAX,DL
SHL ECX,0xc
SHL R9D,0x8
SHL R8D,0x4
ADD R8,RCX
ADD R8,R9
ADD R8,RAX
MOV EAX,0x5
JMP 0x0015ad3a
|
int8 my_mb_wc_filename(int8 param_1,ulong *param_2,byte *param_3,byte *param_4)
{
byte bVar1;
byte bVar2;
int iVar3;
int8 uVar4;
ulong uVar5;
ulong uVar6;
if (param_4 <= param_3) {
return 0xffffff9b;
}
uVar6 = (ulong)(char)*param_3;
if ((long)uVar6 < 0) {
return 0;
}
uVar4 = 1;
if (filename_safe_char[uVar6] != '\0') goto LAB_0015ad3a;
if (*param_3 == 0x40) {
if (param_4 < param_3 + 3) {
return 0xffffff99;
}
bVar2 = param_3[1];
if (bVar2 == 0) {
return 0;
}
bVar1 = param_3[2];
if ('/' < (char)bVar1 && '/' < (char)bVar2) {
iVar3 = ((uint)bVar2 + (uint)bVar2 * 4) * 0x10 + (uint)bVar1;
if ((iVar3 + -0xf00 < 0x179a) &&
(uVar6 = (ulong)*(ushort *)(touni + (ulong)(iVar3 - 0xf30) * 2), uVar6 != 0)) {
uVar4 = 3;
goto LAB_0015ad3a;
}
if (bVar1 == 0x40 && bVar2 == 0x40) {
uVar4 = 3;
uVar6 = 0;
goto LAB_0015ad3a;
}
}
if (param_4 < param_3 + 4) {
return 0xffffff98;
}
if (-1 < (char)hexlo_hex_lo_digit[bVar2]) {
if ((char)hexlo_hex_lo_digit[bVar1] < '\0') {
return 0;
}
uVar6 = (ulong)param_3[3];
if (uVar6 == 0) {
uVar5 = 0;
}
else {
uVar5 = (ulong)param_3[4];
}
if ((char)hexlo_hex_lo_digit[uVar6] < '\0') {
return 0;
}
if ((char)hexlo_hex_lo_digit[uVar5] < '\0') {
return 0;
}
uVar6 = (ulong)(byte)hexlo_hex_lo_digit[uVar6] * 0x10 +
(ulong)(byte)hexlo_hex_lo_digit[bVar2] * 0x1000 +
(ulong)(byte)hexlo_hex_lo_digit[bVar1] * 0x100 +
(ulong)(byte)hexlo_hex_lo_digit[uVar5];
uVar4 = 5;
LAB_0015ad3a:
*param_2 = uVar6;
return uVar4;
}
}
return 0;
}
|
|
9,985 |
minja::ArrayExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const
|
monkey531[P]llama/common/minja.hpp
|
Value do_evaluate(const std::shared_ptr<Context> & context) const override {
auto result = Value::array();
for (const auto& e : elements) {
if (!e) throw std::runtime_error("Array element is null");
result.push_back(e->evaluate(context));
}
return result;
}
|
O2
|
cpp
|
minja::ArrayExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x70, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
xorps %xmm0, %xmm0
movq %rsp, %rsi
movaps %xmm0, (%rsi)
andq $0x0, 0x10(%rsi)
callq 0x6c91c
movq %rsp, %rdi
callq 0x6c12e
movq 0x20(%r15), %r12
movq 0x28(%r15), %r13
leaq 0x20(%rsp), %r15
cmpq %r13, %r12
je 0x6c862
movq (%r12), %rsi
testq %rsi, %rsi
je 0x6c873
movq %r15, %rdi
movq %r14, %rdx
callq 0x6624a
movq %rbx, %rdi
movq %r15, %rsi
callq 0x6c988
movq %r15, %rdi
callq 0x664da
addq $0x10, %r12
jmp 0x6c830
movq %rbx, %rax
addq $0x70, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
pushq $0x10
popq %rdi
callq 0x244f0
movq %rax, %r15
leaq 0x4ad3c(%rip), %rsi # 0xb75c1
movq %rax, %rdi
callq 0x24370
movq 0x95754(%rip), %rsi # 0x101fe8
movq 0x956ad(%rip), %rdx # 0x101f48
movq %r15, %rdi
callq 0x251c0
movq %rax, %r14
movq %rsp, %rdi
callq 0x6c12e
jmp 0x6c8d9
jmp 0x6c8bf
movq %rax, %r14
movq %r15, %rdi
callq 0x24780
jmp 0x6c8d1
movq %rax, %r14
jmp 0x6c8d1
movq %rax, %r14
leaq 0x20(%rsp), %rdi
callq 0x664da
movq %rbx, %rdi
callq 0x664da
movq %r14, %rdi
callq 0x25250
nop
|
_ZNK5minja9ArrayExpr11do_evaluateERKSt10shared_ptrINS_7ContextEE:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 70h
mov r14, rdx
mov r15, rsi
mov rbx, rdi
xorps xmm0, xmm0
mov rsi, rsp
movaps xmmword ptr [rsi], xmm0
and qword ptr [rsi+10h], 0
call _ZN5minja5Value5arrayESt6vectorIS0_SaIS0_EE; minja::Value::array(std::vector<minja::Value>)
mov rdi, rsp
call _ZNSt6vectorIN5minja5ValueESaIS1_EED2Ev; std::vector<minja::Value>::~vector()
mov r12, [r15+20h]
mov r13, [r15+28h]
lea r15, [rsp+98h+var_78]
loc_6C830:
cmp r12, r13
jz short loc_6C862
mov rsi, [r12]
test rsi, rsi
jz short loc_6C873
mov rdi, r15
mov rdx, r14
call _ZNK5minja10Expression8evaluateERKSt10shared_ptrINS_7ContextEE; minja::Expression::evaluate(std::shared_ptr<minja::Context> const&)
mov rdi, rbx; this
mov rsi, r15; minja::Value *
call _ZN5minja5Value9push_backERKS0_; minja::Value::push_back(minja::Value const&)
mov rdi, r15; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
add r12, 10h
jmp short loc_6C830
loc_6C862:
mov rax, rbx
add rsp, 70h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
loc_6C873:
push 10h
pop rdi; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aArrayElementIs; "Array element is null"
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
mov r14, rax
mov rdi, rsp
call _ZNSt6vectorIN5minja5ValueESaIS1_EED2Ev; std::vector<minja::Value>::~vector()
jmp short loc_6C8D9
jmp short loc_6C8BF
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_6C8D1
loc_6C8BF:
mov r14, rax
jmp short loc_6C8D1
mov r14, rax
lea rdi, [rsp+98h+var_78]; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
loc_6C8D1:
mov rdi, rbx; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
loc_6C8D9:
mov rdi, r14
call __Unwind_Resume
|
minja::Value * minja::ArrayExpr::do_evaluate(minja::Value *this, long long a2, int a3, int a4, int a5, int a6)
{
void (****v6)(void); // r12
void (****v7)(void); // r13
std::runtime_error *exception; // r15
_BYTE v10[32]; // [rsp+0h] [rbp-98h] BYREF
_BYTE v11[120]; // [rsp+20h] [rbp-78h] BYREF
minja::Value::array((_DWORD)this, (unsigned int)v10, a3, a4, a5, a6, 0LL, 0LL, 0LL);
std::vector<minja::Value>::~vector((long long)v10);
v6 = *(void (*****)(void))(a2 + 32);
v7 = *(void (*****)(void))(a2 + 40);
while ( v6 != v7 )
{
if ( !*v6 )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Array element is null");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
minja::Expression::evaluate((long long)v11, *v6);
minja::Value::push_back(this, (const minja::Value *)v11);
minja::Value::~Value((minja::Value *)v11);
v6 += 2;
}
return this;
}
|
do_evaluate:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x70
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
XORPS XMM0,XMM0
MOV RSI,RSP
MOVAPS xmmword ptr [RSI],XMM0
AND qword ptr [RSI + 0x10],0x0
LAB_0016c816:
CALL 0x0016c91c
MOV RDI,RSP
CALL 0x0016c12e
MOV R12,qword ptr [R15 + 0x20]
MOV R13,qword ptr [R15 + 0x28]
LEA R15,[RSP + 0x20]
LAB_0016c830:
CMP R12,R13
JZ 0x0016c862
MOV RSI,qword ptr [R12]
TEST RSI,RSI
JZ 0x0016c873
LAB_0016c83e:
MOV RDI,R15
MOV RDX,R14
CALL 0x0016624a
LAB_0016c849:
MOV RDI,RBX
MOV RSI,R15
CALL 0x0016c988
LAB_0016c854:
MOV RDI,R15
CALL 0x001664da
ADD R12,0x10
JMP 0x0016c830
LAB_0016c862:
MOV RAX,RBX
ADD RSP,0x70
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
LAB_0016c873:
PUSH 0x10
POP RDI
CALL 0x001244f0
MOV R15,RAX
LAB_0016c87e:
LEA RSI,[0x1b75c1]
MOV RDI,RAX
CALL 0x00124370
LAB_0016c88d:
MOV RSI,qword ptr [0x00201fe8]
MOV RDX,qword ptr [0x00201f48]
MOV RDI,R15
CALL 0x001251c0
|
/* minja::ArrayExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const */
ArrayExpr * __thiscall minja::ArrayExpr::do_evaluate(ArrayExpr *this,shared_ptr *param_1)
{
int8 *puVar1;
runtime_error *this_00;
int8 *puVar2;
int8 local_98;
int8 uStack_90;
int8 local_88;
Expression local_78 [80];
local_98 = 0;
uStack_90 = 0;
local_88 = 0;
/* try { // try from 0016c816 to 0016c81a has its CatchHandler @ 0016c8a3 */
Value::array();
std::vector<minja::Value,std::allocator<minja::Value>>::~vector
((vector<minja::Value,std::allocator<minja::Value>> *)&local_98);
puVar2 = *(int8 **)(param_1 + 0x20);
puVar1 = *(int8 **)(param_1 + 0x28);
while( true ) {
if (puVar2 == puVar1) {
return this;
}
if ((shared_ptr *)*puVar2 == (shared_ptr *)0x0) break;
/* try { // try from 0016c83e to 0016c848 has its CatchHandler @ 0016c8bf */
Expression::evaluate(local_78,(shared_ptr *)*puVar2);
/* try { // try from 0016c849 to 0016c853 has its CatchHandler @ 0016c8c4 */
Value::push_back((Value *)this,(Value *)local_78);
Value::~Value((Value *)local_78);
puVar2 = puVar2 + 2;
}
this_00 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0016c87e to 0016c88c has its CatchHandler @ 0016c8b2 */
std::runtime_error::runtime_error(this_00,"Array element is null");
/* try { // try from 0016c88d to 0016c8a2 has its CatchHandler @ 0016c8b0 */
/* WARNING: Subroutine does not return */
__cxa_throw(this_00,PTR_typeinfo_00201fe8,PTR__runtime_error_00201f48);
}
|
|
9,986 |
Balloc
|
eloqsql/strings/dtoa.c
|
static Bigint *Balloc(int k, Stack_alloc *alloc)
{
Bigint *rv;
DBUG_ASSERT(k <= Kmax);
if (k <= Kmax && alloc->freelist[k])
{
rv= alloc->freelist[k];
alloc->freelist[k]= rv->p.next;
}
else
{
int x, len;
x= 1 << k;
len= MY_ALIGN(sizeof(Bigint) + x * sizeof(ULong), SIZEOF_CHARP);
if (alloc->free + len <= alloc->end)
{
rv= (Bigint*) alloc->free;
alloc->free+= len;
}
else
rv= (Bigint*) malloc(len);
rv->k= k;
rv->maxwds= x;
}
rv->sign= rv->wds= 0;
rv->p.x= (ULong*) (rv + 1);
return rv;
}
|
O3
|
c
|
Balloc:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %edi, %ebx
cmpl $0xf, %edi
jg 0xd501d
movslq %ebx, %rcx
movq 0x18(%rsi,%rcx,8), %rax
testq %rax, %rax
je 0xd501d
movq (%rax), %rdx
movq %rdx, 0x18(%rsi,%rcx,8)
jmp 0xd5058
movl $0x1, %r14d
movl %ebx, %ecx
shll %cl, %r14d
movl $0x4, %edx
shll %cl, %edx
addl $0x1f, %edx
andl $-0x8, %edx
movq 0x8(%rsi), %rax
movslq %edx, %rdi
leaq (%rax,%rdi), %rcx
cmpq 0x10(%rsi), %rcx
jbe 0xd504d
callq 0x29700
jmp 0xd5051
movq %rcx, 0x8(%rsi)
movl %ebx, 0x8(%rax)
movl %r14d, 0xc(%rax)
movq $0x0, 0x10(%rax)
leaq 0x18(%rax), %rcx
movq %rcx, (%rax)
popq %rbx
popq %r14
popq %rbp
retq
|
Balloc:
push rbp
mov rbp, rsp
push r14
push rbx
mov ebx, edi
cmp edi, 0Fh
jg short loc_D501D
movsxd rcx, ebx
mov rax, [rsi+rcx*8+18h]
test rax, rax
jz short loc_D501D
mov rdx, [rax]
mov [rsi+rcx*8+18h], rdx
jmp short loc_D5058
loc_D501D:
mov r14d, 1
mov ecx, ebx
shl r14d, cl
mov edx, 4
shl edx, cl
add edx, 1Fh
and edx, 0FFFFFFF8h
mov rax, [rsi+8]
movsxd rdi, edx
lea rcx, [rax+rdi]
cmp rcx, [rsi+10h]
jbe short loc_D504D
call _malloc
jmp short loc_D5051
loc_D504D:
mov [rsi+8], rcx
loc_D5051:
mov [rax+8], ebx
mov [rax+0Ch], r14d
loc_D5058:
mov qword ptr [rax+10h], 0
lea rcx, [rax+18h]
mov [rax], rcx
pop rbx
pop r14
pop rbp
retn
|
long long Balloc(int a1, long long a2)
{
long long result; // rax
long long v4; // rdi
if ( a1 <= 15 && (result = *(_QWORD *)(a2 + 8LL * a1 + 24)) != 0 )
{
*(_QWORD *)(a2 + 8LL * a1 + 24) = *(_QWORD *)result;
}
else
{
result = *(_QWORD *)(a2 + 8);
v4 = (int)(((4 << a1) + 31) & 0xFFFFFFF8);
if ( (unsigned long long)(result + v4) <= *(_QWORD *)(a2 + 16) )
*(_QWORD *)(a2 + 8) = result + v4;
else
result = malloc(v4);
*(_DWORD *)(result + 8) = a1;
*(_DWORD *)(result + 12) = 1 << a1;
}
*(_QWORD *)(result + 16) = 0LL;
*(_QWORD *)result = result + 24;
return result;
}
|
Balloc:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV EBX,EDI
CMP EDI,0xf
JG 0x001d501d
MOVSXD RCX,EBX
MOV RAX,qword ptr [RSI + RCX*0x8 + 0x18]
TEST RAX,RAX
JZ 0x001d501d
MOV RDX,qword ptr [RAX]
MOV qword ptr [RSI + RCX*0x8 + 0x18],RDX
JMP 0x001d5058
LAB_001d501d:
MOV R14D,0x1
MOV ECX,EBX
SHL R14D,CL
MOV EDX,0x4
SHL EDX,CL
ADD EDX,0x1f
AND EDX,0xfffffff8
MOV RAX,qword ptr [RSI + 0x8]
MOVSXD RDI,EDX
LEA RCX,[RAX + RDI*0x1]
CMP RCX,qword ptr [RSI + 0x10]
JBE 0x001d504d
CALL 0x00129700
JMP 0x001d5051
LAB_001d504d:
MOV qword ptr [RSI + 0x8],RCX
LAB_001d5051:
MOV dword ptr [RAX + 0x8],EBX
MOV dword ptr [RAX + 0xc],R14D
LAB_001d5058:
MOV qword ptr [RAX + 0x10],0x0
LEA RCX,[RAX + 0x18]
MOV qword ptr [RAX],RCX
POP RBX
POP R14
POP RBP
RET
|
void Balloc(int param_1,long param_2)
{
ulong uVar1;
long *plVar2;
size_t __size;
if (param_1 < 0x10) {
plVar2 = *(long **)(param_2 + 0x18 + (long)param_1 * 8);
if (plVar2 != (long *)0x0) {
*(long *)(param_2 + 0x18 + (long)param_1 * 8) = *plVar2;
goto LAB_001d5058;
}
}
plVar2 = *(long **)(param_2 + 8);
__size = (size_t)(int)((4 << ((byte)param_1 & 0x1f)) + 0x1fU & 0xfffffff8);
uVar1 = (long)plVar2 + __size;
if (*(ulong *)(param_2 + 0x10) < uVar1) {
plVar2 = (long *)malloc(__size);
}
else {
*(ulong *)(param_2 + 8) = uVar1;
}
*(int *)(plVar2 + 1) = param_1;
*(int *)((long)plVar2 + 0xc) = 1 << ((byte)param_1 & 0x1f);
LAB_001d5058:
plVar2[2] = 0;
*plVar2 = (long)(plVar2 + 3);
return;
}
|
|
9,987 |
inline_mysql_cond_init
|
eloqsql/include/mysql/psi/mysql_thread.h
|
static inline int inline_mysql_cond_init(
#ifdef HAVE_PSI_COND_INTERFACE
PSI_cond_key key,
#endif
mysql_cond_t *that,
const pthread_condattr_t *attr)
{
#ifdef HAVE_PSI_COND_INTERFACE
that->m_psi= PSI_COND_CALL(init_cond)(key, &that->m_cond);
#else
that->m_psi= NULL;
#endif
return pthread_cond_init(&that->m_cond, attr);
}
|
O0
|
c
|
inline_mysql_cond_init:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
leaq 0x1c7916(%rip), %rax # 0x289300
movq (%rax), %rax
movq 0x60(%rax), %rax
movl -0x4(%rbp), %edi
movq -0x10(%rbp), %rsi
callq *%rax
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x30(%rax)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x273d0
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
|
inline_mysql_cond_init_4:
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+60h]
mov edi, [rbp+var_4]
mov rsi, [rbp+var_10]
call rax
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+30h], rcx
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call _pthread_cond_init
add rsp, 20h
pop rbp
retn
|
long long inline_mysql_cond_init_4(unsigned int a1, long long a2, long long a3)
{
*(_QWORD *)(a2 + 48) = ((long long ( *)(_QWORD, long long))PSI_server[12])(a1, a2);
return pthread_cond_init(a2, a3);
}
|
inline_mysql_cond_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,[0x389300]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x60]
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 + 0x30],RCX
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x001273d0
ADD RSP,0x20
POP RBP
RET
|
void inline_mysql_cond_init(int4 param_1,pthread_cond_t *param_2,pthread_condattr_t *param_3)
{
longlong lVar1;
lVar1 = (**(code **)(PSI_server + 0x60))(param_1,param_2);
param_2[1].__align = lVar1;
pthread_cond_init(param_2,param_3);
return;
}
|
|
9,988 |
splash_init_filename(char const*)
|
untodesu[P]voxelius/game/shared/splash.cc
|
static void splash_init_filename(const char *filename)
{
if(auto file = PHYSFS_openRead(filename)) {
auto source = std::string(PHYSFS_fileLength(file), char(0x00));
PHYSFS_readBytes(file, source.data(), source.size());
PHYSFS_close(file);
std::string line;
std::istringstream stream(source);
while(std::getline(stream, line))
splash_lines.push_back(sanitize_line(line));
splash_random.seed(std::random_device()());
}
else {
splash_lines.push_back(fmt::format("{}: {}", filename, PHYSFS_getErrorByCode(PHYSFS_getLastErrorCode())));
splash_random.seed(std::random_device()());
}
}
|
O2
|
cpp
|
splash_init_filename(char const*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1558, %rsp # imm = 0x1558
movq %rdi, 0x8(%rsp)
callq 0x53553
testq %rax, %rax
je 0x44a23
movq %rax, %rbx
movq %rax, %rdi
callq 0x53acd
leaq 0x20(%rsp), %rcx
movq %rcx, -0x10(%rcx)
leaq 0x10(%rsp), %rdi
movq %rax, %rsi
xorl %edx, %edx
callq 0x17820
movq 0x10(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq %rbx, %rdi
callq 0x5381f
movq %rbx, %rdi
callq 0x536ef
leaq 0x40(%rsp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x50(%rsp), %rdi
leaq 0x10(%rsp), %rsi
pushq $0x8
popq %rdx
callq 0x17c10
leaq 0x50(%rsp), %rbx
leaq 0x30(%rsp), %r14
leaq 0x1d0(%rsp), %r12
movq %rbx, %rdi
movq %r14, %rsi
callq 0x170e0
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x449cb
leaq 0x1e0(%rsp), %rax
movq %rax, 0x1d0(%rsp)
andq $0x0, 0x1d8(%rsp)
movb $0x0, 0x1e0(%rsp)
movq 0x30(%rsp), %rbp
movq 0x38(%rsp), %r13
xorl %r15d, %r15d
cmpq %r15, %r13
je 0x449af
movzbl (%rbp,%r15), %eax
cmpl $0xa, %eax
je 0x449aa
cmpl $0xd, %eax
je 0x449aa
movsbl %al, %esi
movq %r12, %rdi
callq 0x17600
incq %r15
jmp 0x4498a
leaq 0xca152(%rip), %rdi # 0x10eb08
movq %r12, %rsi
callq 0x44cca
movq %r12, %rdi
callq 0x17ec8
jmp 0x44943
leaq 0x1d0(%rsp), %rdi
callq 0x44c36
leaq 0x1d0(%rsp), %rdi
callq 0x179d0
movl %eax, %esi
leaq 0xc9752(%rip), %rdi # 0x10e140
callq 0x1e3a4
leaq 0x1d0(%rsp), %rdi
callq 0x44c8c
leaq 0x50(%rsp), %rdi
callq 0x172e0
leaq 0x30(%rsp), %rdi
callq 0x17ec8
leaq 0x10(%rsp), %rdi
callq 0x17ec8
jmp 0x44aa5
callq 0x50c4a
movl %eax, %edi
callq 0x50cc1
leaq 0x50(%rsp), %r8
movq %rax, (%r8)
leaq 0x6af30(%rip), %rsi # 0xaf96e
leaq 0x1d0(%rsp), %rbx
pushq $0x6
popq %rdx
leaq 0x8(%rsp), %rcx
movq %rbx, %rdi
callq 0x44c9c
leaq 0xca0ab(%rip), %rdi # 0x10eb08
movq %rbx, %rsi
callq 0x44cca
leaq 0x1d0(%rsp), %rdi
callq 0x17ec8
leaq 0x1d0(%rsp), %rbx
movq %rbx, %rdi
callq 0x44c36
movq %rbx, %rdi
callq 0x179d0
movl %eax, %esi
leaq 0xc96ad(%rip), %rdi # 0x10e140
callq 0x1e3a4
leaq 0x1d0(%rsp), %rdi
callq 0x44c8c
addq $0x1558, %rsp # imm = 0x1558
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x1d0(%rsp), %rdi
jmp 0x44b29
jmp 0x44afb
movq %rax, %rbx
jmp 0x44b1a
movq %rax, %rbx
jmp 0x44b2e
movq %rax, %rbx
leaq 0x1d0(%rsp), %rdi
callq 0x44c8c
jmp 0x44b2e
movq %rax, %rbx
leaq 0x1d0(%rsp), %rdi
callq 0x44c8c
jmp 0x44b10
movq %rax, %rbx
jmp 0x44b24
jmp 0x44b00
movq %rax, %rbx
jmp 0x44b10
movq %rax, %rbx
leaq 0x1d0(%rsp), %rdi
callq 0x17ec8
leaq 0x50(%rsp), %rdi
callq 0x172e0
leaq 0x30(%rsp), %rdi
callq 0x17ec8
leaq 0x10(%rsp), %rdi
callq 0x17ec8
movq %rbx, %rdi
callq 0x17cd0
|
_ZL20splash_init_filenamePKc:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 1558h
mov [rsp+1588h+var_1580], rdi
call PHYSFS_openRead
test rax, rax
jz loc_44A23
mov rbx, rax
mov rdi, rax
call PHYSFS_fileLength
lea rcx, [rsp+1588h+var_1568]
mov [rcx-10h], rcx
lea rdi, [rsp+1588h+var_1578]
mov rsi, rax
xor edx, edx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructEmc; std::string::_M_construct(ulong,char)
mov rsi, [rsp+1588h+var_1578]
mov rdx, [rsp+1588h+var_1570]
mov rdi, rbx
call PHYSFS_readBytes
mov rdi, rbx
call PHYSFS_close
lea rax, [rsp+1588h+var_1548]
mov [rax-10h], rax
and qword ptr [rax-8], 0
mov byte ptr [rax], 0
lea rdi, [rsp+1588h+var_1538]
lea rsi, [rsp+1588h+var_1578]
push 8
pop rdx
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode; std::istringstream::basic_istringstream(std::string const&,std::_Ios_Openmode)
lea rbx, [rsp+1588h+var_1538]
lea r14, [rsp+1588h+var_1558]
lea r12, [rsp+1588h+var_13B8]
loc_44943:
mov rdi, rbx
mov rsi, r14
call __ZSt7getlineIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::getline<char,std::char_traits<char>,std::allocator<char>>(std::istream &,std::string &)
mov rcx, [rax]
mov rcx, [rcx-18h]
test byte ptr [rax+rcx+20h], 5
jnz short loc_449CB
lea rax, [rsp+1588h+var_13A8]
mov [rsp+1588h+var_13B8], rax
and [rsp+1588h+var_13B0], 0
mov [rsp+1588h+var_13A8], 0
mov rbp, [rsp+1588h+var_1558]
mov r13, [rsp+1588h+var_1550]
xor r15d, r15d
loc_4498A:
cmp r13, r15
jz short loc_449AF
movzx eax, byte ptr [rbp+r15+0]
cmp eax, 0Ah
jz short loc_449AA
cmp eax, 0Dh
jz short loc_449AA
movsx esi, al
mov rdi, r12
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
loc_449AA:
inc r15
jmp short loc_4498A
loc_449AF:
lea rdi, _ZL12splash_linesB5cxx11; splash_lines
mov rsi, r12
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&)
mov rdi, r12; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp loc_44943
loc_449CB:
lea rdi, [rsp+1588h+var_13B8]; this
call _ZNSt13random_deviceC2Ev; std::random_device::random_device(void)
lea rdi, [rsp+1588h+var_13B8]; this
call __ZNSt13random_device9_M_getvalEv; std::random_device::_M_getval(void)
mov esi, eax
lea rdi, _ZL13splash_random; splash_random
call _ZNSt23mersenne_twister_engineImLm64ELm312ELm156ELm31ELm13043109905998158313ELm29ELm6148914691236517205ELm17ELm8202884508482404352ELm37ELm18444473444759240704ELm43ELm6364136223846793005EE4seedEm; std::mersenne_twister_engine<ulong,64ul,312ul,156ul,31ul,13043109905998158313ul,29ul,6148914691236517205ul,17ul,8202884508482404352ul,37ul,18444473444759240704ul,43ul,6364136223846793005ul>::seed(ulong)
lea rdi, [rsp+1588h+var_13B8]; this
call _ZNSt13random_deviceD2Ev; std::random_device::~random_device()
lea rdi, [rsp+1588h+var_1538]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev; std::istringstream::~istringstream()
lea rdi, [rsp+1588h+var_1558]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+1588h+var_1578]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp loc_44AA5
loc_44A23:
call PHYSFS_getLastErrorCode
mov edi, eax
call PHYSFS_getErrorByCode
lea r8, [rsp+1588h+var_1538]
mov [r8], rax
lea rsi, aResource+0Ah; "{}: {}"
lea rbx, [rsp+1588h+var_13B8]
push 6
pop rdx
lea rcx, [rsp+1588h+var_1580]
mov rdi, rbx
call _ZN3fmt3v116formatIJRPKcS3_EEENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_19basic_format_stringIcJDpNS0_13type_identityIT_E4typeEEEEDpOSD_; fmt::v11::format<char const*&,char const*>(fmt::v11::basic_format_string<char,fmt::v11::type_identity<char const*&,char const*>::type>,char const*&,char const*&&)
lea rdi, _ZL12splash_linesB5cxx11; splash_lines
mov rsi, rbx
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&)
lea rdi, [rsp+1588h+var_13B8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rbx, [rsp+1588h+var_13B8]
mov rdi, rbx; this
call _ZNSt13random_deviceC2Ev; std::random_device::random_device(void)
mov rdi, rbx; this
call __ZNSt13random_device9_M_getvalEv; std::random_device::_M_getval(void)
mov esi, eax
lea rdi, _ZL13splash_random; splash_random
call _ZNSt23mersenne_twister_engineImLm64ELm312ELm156ELm31ELm13043109905998158313ELm29ELm6148914691236517205ELm17ELm8202884508482404352ELm37ELm18444473444759240704ELm43ELm6364136223846793005EE4seedEm; std::mersenne_twister_engine<ulong,64ul,312ul,156ul,31ul,13043109905998158313ul,29ul,6148914691236517205ul,17ul,8202884508482404352ul,37ul,18444473444759240704ul,43ul,6364136223846793005ul>::seed(ulong)
lea rdi, [rsp+1588h+var_13B8]; this
call _ZNSt13random_deviceD2Ev; std::random_device::~random_device()
loc_44AA5:
add rsp, 1558h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
lea rdi, [rsp+arg_1C8]
jmp short loc_44B29
jmp short loc_44AFB
mov rbx, rax
jmp short loc_44B1A
mov rbx, rax
jmp short loc_44B2E
mov rbx, rax
lea rdi, [rsp+arg_1C8]; this
call _ZNSt13random_deviceD2Ev; std::random_device::~random_device()
jmp short loc_44B2E
mov rbx, rax
lea rdi, [rsp+arg_1C8]; this
call _ZNSt13random_deviceD2Ev; std::random_device::~random_device()
jmp short loc_44B10
mov rbx, rax
jmp short loc_44B24
jmp short loc_44B00
loc_44AFB:
mov rbx, rax
jmp short loc_44B10
loc_44B00:
mov rbx, rax
lea rdi, [rsp+arg_1C8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_44B10:
lea rdi, [rsp+arg_48]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev; std::istringstream::~istringstream()
loc_44B1A:
lea rdi, [rsp+arg_28]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_44B24:
lea rdi, [rsp+arg_8]; void *
loc_44B29:
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_44B2E:
mov rdi, rbx
call __Unwind_Resume
|
void splash_init_filename(const char *a1, long long a2)
{
long long v2; // rax
long long v3; // rbx
long long v4; // rax
_QWORD *v5; // rax
char *v6; // rbp
long long v7; // r13
long long i; // r15
int v9; // eax
unsigned int v10; // eax
unsigned int LastErrorCode; // eax
unsigned int v12; // eax
const char *v13; // [rsp+8h] [rbp-1580h] BYREF
_QWORD v14[2]; // [rsp+10h] [rbp-1578h] BYREF
char v15; // [rsp+20h] [rbp-1568h] BYREF
char *v16; // [rsp+30h] [rbp-1558h] BYREF
long long v17; // [rsp+38h] [rbp-1550h]
char v18; // [rsp+40h] [rbp-1548h] BYREF
_QWORD v19[48]; // [rsp+50h] [rbp-1538h] BYREF
_QWORD v20[2]; // [rsp+1D0h] [rbp-13B8h] BYREF
char v21; // [rsp+1E0h] [rbp-13A8h] BYREF
v13 = a1;
v2 = PHYSFS_openRead(a1);
if ( v2 )
{
v3 = v2;
v4 = PHYSFS_fileLength(v2);
v14[0] = &v15;
std::string::_M_construct(v14, v4, 0LL);
PHYSFS_readBytes(v3, v14[0], v14[1]);
PHYSFS_close(v3);
v16 = &v18;
v17 = 0LL;
v18 = 0;
std::istringstream::basic_istringstream(v19, v14, 8LL);
while ( 1 )
{
v5 = (_QWORD *)std::getline<char,std::char_traits<char>,std::allocator<char>>(v19, &v16);
if ( (*((_BYTE *)v5 + *(_QWORD *)(*v5 - 24LL) + 32) & 5) != 0 )
break;
v20[0] = &v21;
v20[1] = 0LL;
v21 = 0;
v6 = v16;
v7 = v17;
for ( i = 0LL; v7 != i; ++i )
{
v9 = (unsigned __int8)v6[i];
if ( v9 != 10 && v9 != 13 )
std::string::push_back(v20, (unsigned int)(char)v9);
}
std::vector<std::string>::emplace_back<std::string>(&splash_lines[abi:cxx11], v20);
std::string::~string(v20);
}
std::random_device::random_device((std::random_device *)v20);
v10 = std::random_device::_M_getval((std::random_device *)v20);
std::mersenne_twister_engine<unsigned long,64ul,312ul,156ul,31ul,13043109905998158313ul,29ul,6148914691236517205ul,17ul,8202884508482404352ul,37ul,18444473444759240704ul,43ul,6364136223846793005ul>::seed(
splash_random,
v10);
std::random_device::~random_device((std::random_device *)v20);
std::istringstream::~istringstream(v19);
std::string::~string(&v16);
std::string::~string(v14);
}
else
{
LastErrorCode = PHYSFS_getLastErrorCode(a1, a2);
v19[0] = PHYSFS_getErrorByCode(LastErrorCode);
fmt::v11::format<char const*&,char const*>(v20, "{}: {}", 6LL, &v13);
std::vector<std::string>::emplace_back<std::string>(&splash_lines[abi:cxx11], v20);
std::string::~string(v20);
std::random_device::random_device((std::random_device *)v20);
v12 = std::random_device::_M_getval((std::random_device *)v20);
std::mersenne_twister_engine<unsigned long,64ul,312ul,156ul,31ul,13043109905998158313ul,29ul,6148914691236517205ul,17ul,8202884508482404352ul,37ul,18444473444759240704ul,43ul,6364136223846793005ul>::seed(
splash_random,
v12);
std::random_device::~random_device((std::random_device *)v20);
}
}
|
splash_init_filename:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x1558
MOV qword ptr [RSP + 0x8],RDI
CALL 0x00153553
TEST RAX,RAX
JZ 0x00144a23
MOV RBX,RAX
MOV RDI,RAX
CALL 0x00153acd
LEA RCX,[RSP + 0x20]
MOV qword ptr [RCX + -0x10],RCX
LAB_001448e5:
LEA RDI,[RSP + 0x10]
MOV RSI,RAX
XOR EDX,EDX
CALL 0x00117820
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RSP + 0x18]
LAB_001448fe:
MOV RDI,RBX
CALL 0x0015381f
MOV RDI,RBX
CALL 0x001536ef
LEA RAX,[RSP + 0x40]
MOV qword ptr [RAX + -0x10],RAX
AND qword ptr [RAX + -0x8],0x0
MOV byte ptr [RAX],0x0
LAB_0014491f:
LEA RDI,[RSP + 0x50]
LEA RSI,[RSP + 0x10]
PUSH 0x8
POP RDX
CALL 0x00117c10
LEA RBX,[RSP + 0x50]
LEA R14,[RSP + 0x30]
LEA R12,[RSP + 0x1d0]
LAB_00144943:
MOV RDI,RBX
MOV RSI,R14
CALL 0x001170e0
MOV RCX,qword ptr [RAX]
MOV RCX,qword ptr [RCX + -0x18]
TEST byte ptr [RAX + RCX*0x1 + 0x20],0x5
JNZ 0x001449cb
LEA RAX,[RSP + 0x1e0]
MOV qword ptr [RSP + 0x1d0],RAX
AND qword ptr [RSP + 0x1d8],0x0
MOV byte ptr [RSP + 0x1e0],0x0
MOV RBP,qword ptr [RSP + 0x30]
MOV R13,qword ptr [RSP + 0x38]
XOR R15D,R15D
LAB_0014498a:
CMP R13,R15
JZ 0x001449af
MOVZX EAX,byte ptr [RBP + R15*0x1]
CMP EAX,0xa
JZ 0x001449aa
CMP EAX,0xd
JZ 0x001449aa
LAB_0014499f:
MOVSX ESI,AL
MOV RDI,R12
CALL 0x00117600
LAB_001449aa:
INC R15
JMP 0x0014498a
LAB_001449af:
LEA RDI,[0x20eb08]
MOV RSI,R12
CALL 0x00144cca
MOV RDI,R12
CALL 0x00117ec8
JMP 0x00144943
LAB_001449cb:
LEA RDI,[RSP + 0x1d0]
CALL 0x00144c36
LAB_001449d8:
LEA RDI,[RSP + 0x1d0]
CALL 0x001179d0
MOV ESI,EAX
LEA RDI,[0x20e140]
CALL 0x0011e3a4
LAB_001449f3:
LEA RDI,[RSP + 0x1d0]
CALL 0x00144c8c
LEA RDI,[RSP + 0x50]
CALL 0x001172e0
LEA RDI,[RSP + 0x30]
CALL 0x00117ec8
LEA RDI,[RSP + 0x10]
CALL 0x00117ec8
JMP 0x00144aa5
LAB_00144a23:
CALL 0x00150c4a
MOV EDI,EAX
CALL 0x00150cc1
LEA R8,[RSP + 0x50]
MOV qword ptr [R8],RAX
LEA RSI,[0x1af96e]
LEA RBX,[RSP + 0x1d0]
PUSH 0x6
POP RDX
LEA RCX,[RSP + 0x8]
MOV RDI,RBX
CALL 0x00144c9c
LAB_00144a56:
LEA RDI,[0x20eb08]
MOV RSI,RBX
CALL 0x00144cca
LAB_00144a65:
LEA RDI,[RSP + 0x1d0]
CALL 0x00117ec8
LEA RBX,[RSP + 0x1d0]
MOV RDI,RBX
CALL 0x00144c36
LAB_00144a82:
MOV RDI,RBX
CALL 0x001179d0
MOV ESI,EAX
LEA RDI,[0x20e140]
CALL 0x0011e3a4
LAB_00144a98:
LEA RDI,[RSP + 0x1d0]
CALL 0x00144c8c
LAB_00144aa5:
ADD RSP,0x1558
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* splash_init_filename(char const*) */
void splash_init_filename(char *param_1)
{
int1 *puVar1;
char cVar2;
uint uVar3;
int4 uVar4;
long lVar5;
istream *piVar6;
long lVar7;
char *local_1580;
int1 *local_1578;
int8 local_1570;
int1 local_1568 [16];
int1 *local_1558;
long local_1550;
int1 local_1548 [16];
int8 local_1538 [48];
int1 *local_13b8;
int8 local_13b0;
int1 local_13a8 [4984];
local_1580 = param_1;
lVar5 = PHYSFS_openRead();
if (lVar5 == 0) {
uVar4 = PHYSFS_getLastErrorCode();
local_1538[0] = PHYSFS_getErrorByCode(uVar4);
fmt::v11::format<char_const*&,char_const*>((string *)&local_13b8,"{}: {}",6,&local_1580);
/* try { // try from 00144a56 to 00144a64 has its CatchHandler @ 00144ab7 */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<std::__cxx11::string>
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)
&splash_lines_abi_cxx11_,(string *)&local_13b8);
std::__cxx11::string::~string((string *)&local_13b8);
std::random_device::random_device((random_device *)&local_13b8);
/* try { // try from 00144a82 to 00144a97 has its CatchHandler @ 00144ad0 */
uVar3 = std::random_device::_M_getval();
std::
mersenne_twister_engine<unsigned_long,64ul,312ul,156ul,31ul,13043109905998158313ul,29ul,6148914691236517205ul,17ul,8202884508482404352ul,37ul,18444473444759240704ul,43ul,6364136223846793005ul>
::seed((mersenne_twister_engine<unsigned_long,64ul,312ul,156ul,31ul,13043109905998158313ul,29ul,6148914691236517205ul,17ul,8202884508482404352ul,37ul,18444473444759240704ul,43ul,6364136223846793005ul>
*)splash_random,(ulong)uVar3);
std::random_device::~random_device((random_device *)&local_13b8);
}
else {
cVar2 = PHYSFS_fileLength(lVar5);
local_1578 = local_1568;
/* try { // try from 001448e5 to 001448f3 has its CatchHandler @ 00144acb */
std::__cxx11::string::_M_construct((ulong)&local_1578,cVar2);
/* try { // try from 001448fe to 0014490d has its CatchHandler @ 00144af4 */
PHYSFS_readBytes(lVar5,local_1578,local_1570);
PHYSFS_close(lVar5);
local_1558 = local_1548;
local_1550 = 0;
local_1548[0] = 0;
/* try { // try from 0014491f to 00144930 has its CatchHandler @ 00144ac6 */
std::__cxx11::istringstream::istringstream((istringstream *)local_1538,&local_1578,8);
while( true ) {
/* try { // try from 00144943 to 0014494d has its CatchHandler @ 00144afb */
piVar6 = std::getline<char,std::char_traits<char>,std::allocator<char>>
((istream *)local_1538,(string *)&local_1558);
lVar5 = local_1550;
puVar1 = local_1558;
if (((byte)piVar6[*(long *)(*(long *)piVar6 + -0x18) + 0x20] & 5) != 0) break;
local_13b8 = local_13a8;
local_13b0 = 0;
local_13a8[0] = 0;
for (lVar7 = 0; lVar5 != lVar7; lVar7 = lVar7 + 1) {
if ((puVar1[lVar7] != '\n') && (puVar1[lVar7] != '\r')) {
/* try { // try from 0014499f to 001449a9 has its CatchHandler @ 00144b00 */
std::__cxx11::string::push_back((char)(string *)&local_13b8);
}
}
/* try { // try from 001449af to 001449bd has its CatchHandler @ 00144af9 */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<std::__cxx11::string>
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)
&splash_lines_abi_cxx11_,(string *)&local_13b8);
std::__cxx11::string::~string((string *)&local_13b8);
}
/* try { // try from 001449cb to 001449d7 has its CatchHandler @ 00144ac4 */
std::random_device::random_device((random_device *)&local_13b8);
/* try { // try from 001449d8 to 001449f2 has its CatchHandler @ 00144ae2 */
uVar3 = std::random_device::_M_getval();
std::
mersenne_twister_engine<unsigned_long,64ul,312ul,156ul,31ul,13043109905998158313ul,29ul,6148914691236517205ul,17ul,8202884508482404352ul,37ul,18444473444759240704ul,43ul,6364136223846793005ul>
::seed((mersenne_twister_engine<unsigned_long,64ul,312ul,156ul,31ul,13043109905998158313ul,29ul,6148914691236517205ul,17ul,8202884508482404352ul,37ul,18444473444759240704ul,43ul,6364136223846793005ul>
*)splash_random,(ulong)uVar3);
std::random_device::~random_device((random_device *)&local_13b8);
std::__cxx11::istringstream::~istringstream((istringstream *)local_1538);
std::__cxx11::string::~string((string *)&local_1558);
std::__cxx11::string::~string((string *)&local_1578);
}
return;
}
|
|
9,989 |
my_mb_wc_euc_jp
|
eloqsql/strings/ctype-ujis.c
|
static int
my_mb_wc_euc_jp(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t *pwc, const uchar *s, const uchar *e)
{
int hi;
if (s >= e)
return MY_CS_TOOSMALL;
if ((hi= s[0]) < 0x80) /* ASCII code set: [00..7F] -> [U+0000..U+007F] */
{
*pwc= hi;
return 1;
}
if (hi >= 0xA1 && hi <= 0xFE) /* JIS-X-0208 code set: [A1..FE][A1..FE] */
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
return (*pwc= jisx0208_eucjp_to_unicode[(hi << 8) + s[1]]) ? 2 :
(s[1] < 0xA1 || s[1] > 0xFE) ? MY_CS_ILSEQ : -2;
}
/* JIS-X-0201 HALF WIDTH KATAKANA: [8E][A1..DF] -> [U+FF61..U+FF9F] */
if (hi == 0x8E)
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
if (s[1] < 0xA1 || s[1] > 0xDF)
return MY_CS_ILSEQ;
*pwc= 0xFEC0 + s[1]; /* 0xFFC0 = 0xFF61 - 0xA1 */
return 2;
}
if (hi == 0x8F) /* JIS X 0212 code set: [8F][A1..FE][A1..FE] */
{
if (s + 3 > e)
return MY_CS_TOOSMALL3;
return (*pwc= jisx0212_eucjp_to_unicode[(((int) s[1]) << 8) + s[2]]) ?
3 :
(s[1] < 0xA1 || s[1] > 0xFE || s[2] < 0xA1 || s[2] > 0xFE) ?
MY_CS_ILSEQ : -3;
}
return MY_CS_ILSEQ;
}
|
O3
|
c
|
my_mb_wc_euc_jp:
pushq %rbp
movq %rsp, %rbp
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmpq %rcx, %rdx
jae 0x85177
movzbl (%rdx), %edi
testb %dil, %dil
js 0x85179
movq %rdi, (%rsi)
movl $0x1, %eax
popq %rbp
retq
leal 0x5f(%rdi), %eax
cmpb $0x5d, %al
ja 0x851c5
leaq 0x2(%rdx), %r8
movl $0xffffff9a, %eax # imm = 0xFFFFFF9A
cmpq %rcx, %r8
ja 0x85177
movzbl 0x1(%rdx), %eax
shll $0x9, %edi
leal (%rdi,%rax,2), %eax
leaq 0x20b6b1(%rip), %rcx # 0x290850
movzwl (%rax,%rcx), %ecx
movq %rcx, (%rsi)
movl $0x2, %eax
testq %rcx, %rcx
jne 0x85177
movb 0x1(%rdx), %al
incb %al
xorl %ecx, %ecx
cmpb $-0x5e, %al
setb %cl
leal -0x2(,%rcx,2), %eax
jmp 0x85177
cmpq $0x8f, %rdi
je 0x85209
cmpl $0x8e, %edi
jne 0x8524b
leaq 0x2(%rdx), %rdi
movl $0xffffff9a, %eax # imm = 0xFFFFFF9A
cmpq %rcx, %rdi
ja 0x85177
movzbl 0x1(%rdx), %ecx
leal 0x20(%rcx), %edx
movl $0x0, %eax
cmpb $-0x3f, %dl
jb 0x85177
addq $0xfec0, %rcx # imm = 0xFEC0
movq %rcx, (%rsi)
movl $0x2, %eax
jmp 0x85177
leaq 0x3(%rdx), %rdi
movl $0xffffff99, %eax # imm = 0xFFFFFF99
cmpq %rcx, %rdi
ja 0x85177
movzwl 0x1(%rdx), %eax
rolw $0x8, %ax
movzwl %ax, %eax
leaq 0x22b623(%rip), %rcx # 0x2b0850
movzwl (%rcx,%rax,2), %ecx
movq %rcx, (%rsi)
movl $0x3, %eax
testq %rcx, %rcx
jne 0x85177
movb 0x1(%rdx), %al
incb %al
cmpb $-0x5e, %al
jae 0x85252
xorl %eax, %eax
jmp 0x85177
movb 0x2(%rdx), %cl
movl $0x0, %eax
cmpb $-0x5f, %cl
jb 0x85177
xorl %eax, %eax
cmpb $-0x1, %cl
sete %al
leal (%rax,%rax,2), %eax
addl $-0x3, %eax
jmp 0x85177
|
my_mb_wc_euc_jp:
push rbp
mov rbp, rsp
mov eax, 0FFFFFF9Bh
cmp rdx, rcx
jnb short loc_85177
movzx edi, byte ptr [rdx]
test dil, dil
js short loc_85179
mov [rsi], rdi
mov eax, 1
loc_85177:
pop rbp
retn
loc_85179:
lea eax, [rdi+5Fh]
cmp al, 5Dh ; ']'
ja short loc_851C5
lea r8, [rdx+2]
mov eax, 0FFFFFF9Ah
cmp r8, rcx
ja short loc_85177
movzx eax, byte ptr [rdx+1]
shl edi, 9
lea eax, [rdi+rax*2]
lea rcx, jisx0208_eucjp_to_unicode
movzx ecx, word ptr [rax+rcx]
mov [rsi], rcx
mov eax, 2
test rcx, rcx
jnz short loc_85177
mov al, [rdx+1]
inc al
xor ecx, ecx
cmp al, 0A2h
setb cl
lea eax, ds:0FFFFFFFFFFFFFFFEh[rcx*2]
jmp short loc_85177
loc_851C5:
cmp rdi, 8Fh
jz short loc_85209
cmp edi, 8Eh
jnz short loc_8524B
lea rdi, [rdx+2]
mov eax, 0FFFFFF9Ah
cmp rdi, rcx
ja short loc_85177
movzx ecx, byte ptr [rdx+1]
lea edx, [rcx+20h]
mov eax, 0
cmp dl, 0C1h
jb short loc_85177
add rcx, 0FEC0h
mov [rsi], rcx
mov eax, 2
jmp loc_85177
loc_85209:
lea rdi, [rdx+3]
mov eax, 0FFFFFF99h
cmp rdi, rcx
ja loc_85177
movzx eax, word ptr [rdx+1]
rol ax, 8
movzx eax, ax
lea rcx, jisx0212_eucjp_to_unicode
movzx ecx, word ptr [rcx+rax*2]
mov [rsi], rcx
mov eax, 3
test rcx, rcx
jnz loc_85177
mov al, [rdx+1]
inc al
cmp al, 0A2h
jnb short loc_85252
loc_8524B:
xor eax, eax
jmp loc_85177
loc_85252:
mov cl, [rdx+2]
mov eax, 0
cmp cl, 0A1h
jb loc_85177
xor eax, eax
cmp cl, 0FFh
setz al
lea eax, [rax+rax*2]
add eax, 0FFFFFFFDh
jmp loc_85177
|
long long my_mb_wc_euc_jp(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4)
{
long long result; // rax
long long v5; // rdi
long long v6; // rcx
long long v7; // rcx
long long v8; // rcx
unsigned __int8 v9; // cl
result = 4294967195LL;
if ( (unsigned long long)a3 >= a4 )
return result;
v5 = *a3;
if ( (v5 & 0x80u) == 0LL )
{
*a2 = v5;
return 1LL;
}
if ( (unsigned __int8)(v5 + 95) <= 0x5Du )
{
result = 4294967194LL;
if ( (unsigned long long)(a3 + 2) <= a4 )
{
v6 = jisx0208_eucjp_to_unicode[256 * (_DWORD)v5 + a3[1]];
*a2 = v6;
result = 2LL;
if ( !v6 )
return 2 * (unsigned int)((unsigned __int8)(a3[1] + 1) < 0xA2u) - 2;
}
return result;
}
if ( v5 != 143 )
{
if ( (_DWORD)v5 == 142 )
{
result = 4294967194LL;
if ( (unsigned long long)(a3 + 2) <= a4 )
{
v7 = a3[1];
result = 0LL;
if ( (unsigned __int8)(v7 + 32) >= 0xC1u )
{
*a2 = v7 + 65216;
return 2LL;
}
}
return result;
}
return 0LL;
}
result = 4294967193LL;
if ( (unsigned long long)(a3 + 3) > a4 )
return result;
v8 = jisx0212_eucjp_to_unicode[(unsigned __int16)__ROL2__(*(_WORD *)(a3 + 1), 8)];
*a2 = v8;
result = 3LL;
if ( v8 )
return result;
if ( (unsigned __int8)(a3[1] + 1) < 0xA2u )
return 0LL;
v9 = a3[2];
result = 0LL;
if ( v9 >= 0xA1u )
return 3 * (unsigned int)(v9 == 0xFF) - 3;
return result;
}
|
my_mb_wc_euc_jp:
PUSH RBP
MOV RBP,RSP
MOV EAX,0xffffff9b
CMP RDX,RCX
JNC 0x00185177
MOVZX EDI,byte ptr [RDX]
TEST DIL,DIL
JS 0x00185179
MOV qword ptr [RSI],RDI
MOV EAX,0x1
LAB_00185177:
POP RBP
RET
LAB_00185179:
LEA EAX,[RDI + 0x5f]
CMP AL,0x5d
JA 0x001851c5
LEA R8,[RDX + 0x2]
MOV EAX,0xffffff9a
CMP R8,RCX
JA 0x00185177
MOVZX EAX,byte ptr [RDX + 0x1]
SHL EDI,0x9
LEA EAX,[RDI + RAX*0x2]
LEA RCX,[0x390850]
MOVZX ECX,word ptr [RAX + RCX*0x1]
MOV qword ptr [RSI],RCX
MOV EAX,0x2
TEST RCX,RCX
JNZ 0x00185177
MOV AL,byte ptr [RDX + 0x1]
INC AL
XOR ECX,ECX
CMP AL,0xa2
SETC CL
LEA EAX,[-0x2 + RCX*0x2]
JMP 0x00185177
LAB_001851c5:
CMP RDI,0x8f
JZ 0x00185209
CMP EDI,0x8e
JNZ 0x0018524b
LEA RDI,[RDX + 0x2]
MOV EAX,0xffffff9a
CMP RDI,RCX
JA 0x00185177
MOVZX ECX,byte ptr [RDX + 0x1]
LEA EDX,[RCX + 0x20]
MOV EAX,0x0
CMP DL,0xc1
JC 0x00185177
ADD RCX,0xfec0
MOV qword ptr [RSI],RCX
MOV EAX,0x2
JMP 0x00185177
LAB_00185209:
LEA RDI,[RDX + 0x3]
MOV EAX,0xffffff99
CMP RDI,RCX
JA 0x00185177
MOVZX EAX,word ptr [RDX + 0x1]
ROL AX,0x8
MOVZX EAX,AX
LEA RCX,[0x3b0850]
MOVZX ECX,word ptr [RCX + RAX*0x2]
MOV qword ptr [RSI],RCX
MOV EAX,0x3
TEST RCX,RCX
JNZ 0x00185177
MOV AL,byte ptr [RDX + 0x1]
INC AL
CMP AL,0xa2
JNC 0x00185252
LAB_0018524b:
XOR EAX,EAX
JMP 0x00185177
LAB_00185252:
MOV CL,byte ptr [RDX + 0x2]
MOV EAX,0x0
CMP CL,0xa1
JC 0x00185177
XOR EAX,EAX
CMP CL,0xff
SETZ AL
LEA EAX,[RAX + RAX*0x2]
ADD EAX,-0x3
JMP 0x00185177
|
int my_mb_wc_euc_jp(int8 param_1,ulong *param_2,byte *param_3,byte *param_4)
{
byte bVar1;
ushort uVar2;
int iVar3;
iVar3 = -0x65;
if (param_3 < param_4) {
bVar1 = *param_3;
if ((char)bVar1 < '\0') {
if ((byte)(bVar1 + 0x5f) < 0x5e) {
iVar3 = -0x66;
if (param_3 + 2 <= param_4) {
uVar2 = *(ushort *)
(jisx0208_eucjp_to_unicode + ((uint)bVar1 * 0x200 + (uint)param_3[1] * 2));
*param_2 = (ulong)uVar2;
iVar3 = 2;
if ((ulong)uVar2 == 0) {
iVar3 = (uint)((byte)(param_3[1] + 1) < 0xa2) * 2 + -2;
}
}
}
else {
if ((ulong)bVar1 == 0x8f) {
if (param_4 < param_3 + 3) {
return -0x67;
}
uVar2 = *(ushort *)
(&jisx0212_eucjp_to_unicode +
(ulong)(ushort)(*(ushort *)(param_3 + 1) << 8 | *(ushort *)(param_3 + 1) >> 8) *
2);
*param_2 = (ulong)uVar2;
if ((ulong)uVar2 != 0) {
return 3;
}
if (0xa1 < (byte)(param_3[1] + 1)) {
if (param_3[2] < 0xa1) {
return 0;
}
return (uint)(param_3[2] == 0xff) * 3 + -3;
}
}
else if (bVar1 == 0x8e) {
if (param_4 < param_3 + 2) {
return -0x66;
}
if ((byte)(param_3[1] + 0x20) < 0xc1) {
return 0;
}
*param_2 = (ulong)param_3[1] + 0xfec0;
return 2;
}
iVar3 = 0;
}
}
else {
*param_2 = (ulong)bVar1;
iVar3 = 1;
}
}
return iVar3;
}
|
|
9,990 |
test_temp(std::vector<float, std::allocator<float>> const&, std::vector<float, std::allocator<float>> const&, float)
|
monkey531[P]llama/tests/test-sampling.cpp
|
static void test_temp(const std::vector<float> & probs, const std::vector<float> & probs_expected, float temp) {
sampler_tester tester(probs, probs_expected);
DUMP(&tester.cur_p);
tester.apply(llama_sampler_init_temp(temp));
tester.apply(llama_sampler_init_dist(0));
DUMP(&tester.cur_p);
tester.check();
}
|
O2
|
cpp
|
test_temp(std::vector<float, std::allocator<float>> const&, std::vector<float, std::allocator<float>> const&, float):
pushq %rbx
subq $0x60, %rsp
movss %xmm0, 0xc(%rsp)
movq %rsi, %rdx
movq %rdi, %rsi
leaq 0x10(%rsp), %rbx
movq %rbx, %rdi
callq 0x50ac
leaq 0x2171(%rip), %rdi # 0x6298
leaq 0x2176(%rip), %rsi # 0x62a4
leaq 0x21c1(%rip), %rcx # 0x62f6
pushq $0x43
popq %rdx
xorl %eax, %eax
callq 0x2030
movq %rbx, %rdi
callq 0x4df9
leaq 0x2546(%rip), %rdi # 0x6694
callq 0x2210
movss 0xc(%rsp), %xmm0
callq 0x2130
leaq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x5198
xorl %edi, %edi
callq 0x2200
leaq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x5198
leaq 0x2112(%rip), %rdi # 0x6298
leaq 0x2117(%rip), %rsi # 0x62a4
leaq 0x2162(%rip), %rcx # 0x62f6
pushq $0x46
popq %rdx
xorl %eax, %eax
callq 0x2030
leaq 0x10(%rsp), %rbx
movq %rbx, %rdi
callq 0x4df9
leaq 0x24e2(%rip), %rdi # 0x6694
callq 0x2210
movq %rbx, %rdi
callq 0x51b0
leaq 0x10(%rsp), %rdi
callq 0x523e
addq $0x60, %rsp
popq %rbx
retq
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x523e
movq %rbx, %rdi
callq 0x2270
|
_ZL9test_tempRKSt6vectorIfSaIfEES3_f:
push rbx
sub rsp, 60h
movss [rsp+68h+var_5C], xmm0
mov rdx, rsi
mov rsi, rdi
lea rbx, [rsp+68h+var_58]
mov rdi, rbx
call _ZN14sampler_testerC2ERKSt6vectorIfSaIfEES4_; sampler_tester::sampler_tester(std::vector<float> const&,std::vector<float> const&)
lea rdi, aSDS; "%s:%d (%s)\n"
lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aTestTemp; "test_temp"
push 43h ; 'C'
pop rdx
xor eax, eax
call _printf
mov rdi, rbx
call _ZL4dumpPK22llama_token_data_array; dump(llama_token_data_array const*)
lea rdi, asc_6694; "-"
call _puts
movss xmm0, [rsp+68h+var_5C]
call _llama_sampler_init_temp
lea rdi, [rsp+68h+var_58]
mov rsi, rax
call _ZN14sampler_tester5applyEP13llama_sampler; sampler_tester::apply(llama_sampler *)
xor edi, edi
call _llama_sampler_init_dist
lea rdi, [rsp+68h+var_58]
mov rsi, rax
call _ZN14sampler_tester5applyEP13llama_sampler; sampler_tester::apply(llama_sampler *)
lea rdi, aSDS; "%s:%d (%s)\n"
lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aTestTemp; "test_temp"
push 46h ; 'F'
pop rdx
xor eax, eax
call _printf
lea rbx, [rsp+68h+var_58]
mov rdi, rbx
call _ZL4dumpPK22llama_token_data_array; dump(llama_token_data_array const*)
lea rdi, asc_6694; "-"
call _puts
mov rdi, rbx; this
call _ZN14sampler_tester5checkEv; sampler_tester::check(void)
lea rdi, [rsp+68h+var_58]; this
call _ZN14sampler_testerD2Ev; sampler_tester::~sampler_tester()
add rsp, 60h
pop rbx
retn
mov rbx, rax
lea rdi, [rsp+arg_8]; this
call _ZN14sampler_testerD2Ev; sampler_tester::~sampler_tester()
mov rdi, rbx
call __Unwind_Resume
|
void test_temp(long long a1, long long a2, float a3)
{
long long inited; // rax
long long v4; // rax
_BYTE v5[88]; // [rsp+10h] [rbp-58h] BYREF
sampler_tester::sampler_tester(v5, a1, a2);
printf(
"%s:%d (%s)\n",
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/tests/test-sampling.cpp",
67,
"test_temp");
dump(v5);
puts("-");
inited = llama_sampler_init_temp(a3);
sampler_tester::apply(v5, inited);
v4 = llama_sampler_init_dist(0LL);
sampler_tester::apply(v5, v4);
printf(
"%s:%d (%s)\n",
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/tests/test-sampling.cpp",
70,
"test_temp");
dump(v5);
puts("-");
sampler_tester::check((sampler_tester *)v5);
sampler_tester::~sampler_tester((sampler_tester *)v5);
}
|
test_temp:
PUSH RBX
SUB RSP,0x60
MOVSS dword ptr [RSP + 0xc],XMM0
MOV RDX,RSI
MOV RSI,RDI
LEA RBX,[RSP + 0x10]
MOV RDI,RBX
CALL 0x001050ac
LEA RDI,[0x106298]
LEA RSI,[0x1062a4]
LEA RCX,[0x1062f6]
PUSH 0x43
POP RDX
XOR EAX,EAX
CALL 0x00102030
MOV RDI,RBX
CALL 0x00104df9
LEA RDI,[0x106694]
CALL 0x00102210
LAB_00104153:
MOVSS XMM0,dword ptr [RSP + 0xc]
CALL 0x00102130
LEA RDI,[RSP + 0x10]
MOV RSI,RAX
CALL 0x00105198
XOR EDI,EDI
CALL 0x00102200
LEA RDI,[RSP + 0x10]
MOV RSI,RAX
CALL 0x00105198
LEA RDI,[0x106298]
LEA RSI,[0x1062a4]
LEA RCX,[0x1062f6]
PUSH 0x46
POP RDX
XOR EAX,EAX
CALL 0x00102030
LEA RBX,[RSP + 0x10]
MOV RDI,RBX
CALL 0x00104df9
LEA RDI,[0x106694]
CALL 0x00102210
MOV RDI,RBX
CALL 0x001051b0
LAB_001041bf:
LEA RDI,[RSP + 0x10]
CALL 0x0010523e
ADD RSP,0x60
POP RBX
RET
|
/* test_temp(std::vector<float, std::allocator<float> > const&, std::vector<float,
std::allocator<float> > const&, float) */
void test_temp(vector *param_1,vector *param_2,float param_3)
{
llama_sampler *plVar1;
sampler_tester local_58 [80];
sampler_tester::sampler_tester(local_58,param_1,param_2);
printf("%s:%d (%s)\n",
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/tests/test-sampling.cpp",0x43,
"test_temp");
dump((llama_token_data_array *)local_58);
puts("-");
/* try { // try from 00104153 to 001041be has its CatchHandler @ 001041cf */
plVar1 = (llama_sampler *)llama_sampler_init_temp(param_3);
sampler_tester::apply(local_58,plVar1);
plVar1 = (llama_sampler *)llama_sampler_init_dist(0);
sampler_tester::apply(local_58,plVar1);
printf("%s:%d (%s)\n",
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/tests/test-sampling.cpp",0x46,
"test_temp");
dump((llama_token_data_array *)local_58);
puts("-");
sampler_tester::check(local_58);
sampler_tester::~sampler_tester(local_58);
return;
}
|
|
9,991 |
cs_enter
|
eloqsql/strings/ctype.c
|
static int cs_enter(MY_XML_PARSER *st,const char *attr, size_t len)
{
struct my_cs_file_info *i= (struct my_cs_file_info *)st->user_data;
const struct my_cs_file_section_st *s= cs_file_sec(attr,len);
int state= s ? s->state : 0;
switch (state) {
case 0:
i->loader->reporter(WARNING_LEVEL, "Unknown LDML tag: '%.*s'", len, attr);
break;
case _CS_CHARSET:
my_charset_file_reset_charset(i);
break;
case _CS_COLLATION:
my_charset_file_reset_collation(i);
break;
case _CS_RESET:
return tailoring_append(st, " &", 0, NULL);
default:
break;
}
return MY_XML_OK;
}
|
O3
|
c
|
cs_enter:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %r14
movq 0x140(%rdi), %rbx
leaq 0x2b24b5(%rip), %r13 # 0x383220
leaq 0xb2ef(%rip), %r12 # 0xdc061
movq %r14, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x291d0
testl %eax, %eax
jne 0xd0d8b
cmpb $0x0, (%r12,%r15)
je 0xd0dcb
movq 0x18(%r13), %r12
addq $0x10, %r13
testq %r12, %r12
jne 0xd0d72
movq 0x7a8(%rbx), %r8
leaq 0xe369(%rip), %rsi # 0xdf10f
movl $0x1, %edi
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq *0xa0(%r8)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl (%r13), %eax
cmpl $0x8, %eax
jg 0xd0df5
testl %eax, %eax
je 0xd0d98
cmpl $0x8, %eax
jne 0xd0dba
addq $0x6e0, %rbx # imm = 0x6E0
movl $0xc8, %edx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x292c0
jmp 0xd0dba
cmpl $0x9, %eax
je 0xd0e22
cmpl $0x12d, %eax # imm = 0x12D
jne 0xd0dba
leaq 0xe320(%rip), %rsi # 0xdf128
movq %rbx, %rdi
xorl %edx, %edx
xorl %ecx, %ecx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xd1fc4
movq $0x0, 0x690(%rbx)
movb $0x0, 0x6a0(%rbx)
jmp 0xd0dba
|
cs_enter:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r15, rdx
mov r14, rsi
mov rbx, [rdi+140h]
lea r13, sec
lea r12, aIndexXml+6; "xml"
loc_D0D72:
mov rdi, r14
mov rsi, r12
mov rdx, r15
call _strncmp
test eax, eax
jnz short loc_D0D8B
cmp byte ptr [r12+r15], 0
jz short loc_D0DCB
loc_D0D8B:
mov r12, [r13+18h]
add r13, 10h
test r12, r12
jnz short loc_D0D72
loc_D0D98:
mov r8, [rbx+7A8h]
lea rsi, aUnknownLdmlTag; "Unknown LDML tag: '%.*s'"
mov edi, 1
mov rdx, r15
mov rcx, r14
xor eax, eax
call qword ptr [r8+0A0h]
loc_D0DBA:
xor eax, eax
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_D0DCB:
mov eax, [r13+0]
cmp eax, 8
jg short loc_D0DF5
test eax, eax
jz short loc_D0D98
cmp eax, 8
jnz short loc_D0DBA
add rbx, 6E0h
mov edx, 0C8h
mov rdi, rbx
xor esi, esi
call _memset
jmp short loc_D0DBA
loc_D0DF5:
cmp eax, 9
jz short loc_D0E22
cmp eax, 12Dh
jnz short loc_D0DBA
lea rsi, asc_DF128; " &"
mov rdi, rbx
xor edx, edx
xor ecx, ecx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp tailoring_append
loc_D0E22:
mov qword ptr [rbx+690h], 0
mov byte ptr [rbx+6A0h], 0
jmp short loc_D0DBA
|
long long cs_enter(long long a1, const char *a2, long long a3)
{
long long v4; // rbx
char *v5; // r13
char *v6; // r12
int v8; // eax
v4 = *(_QWORD *)(a1 + 320);
v5 = (char *)&sec;
v6 = "xml";
while ( (unsigned int)strncmp(a2, v6, a3) || v6[a3] )
{
v6 = (char *)*((_QWORD *)v5 + 3);
v5 += 16;
if ( !v6 )
goto LABEL_5;
}
v8 = *(_DWORD *)v5;
if ( *(int *)v5 <= 8 )
{
if ( v8 )
{
if ( v8 == 8 )
memset(v4 + 1760, 0LL, 200LL);
}
else
{
LABEL_5:
(*(void (**)(long long, const char *, ...))(*(_QWORD *)(v4 + 1960) + 160LL))(
1LL,
"Unknown LDML tag: '%.*s'",
a3,
a2);
}
return 0LL;
}
if ( v8 == 9 )
{
*(_QWORD *)(v4 + 1680) = 0LL;
*(_BYTE *)(v4 + 1696) = 0;
return 0LL;
}
if ( v8 != 301 )
return 0LL;
return tailoring_append(v4, " &", 0LL, 0LL);
}
|
cs_enter:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R15,RDX
MOV R14,RSI
MOV RBX,qword ptr [RDI + 0x140]
LEA R13,[0x483220]
LEA R12,[0x1dc061]
LAB_001d0d72:
MOV RDI,R14
MOV RSI,R12
MOV RDX,R15
CALL 0x001291d0
TEST EAX,EAX
JNZ 0x001d0d8b
CMP byte ptr [R12 + R15*0x1],0x0
JZ 0x001d0dcb
LAB_001d0d8b:
MOV R12,qword ptr [R13 + 0x18]
ADD R13,0x10
TEST R12,R12
JNZ 0x001d0d72
LAB_001d0d98:
MOV R8,qword ptr [RBX + 0x7a8]
LEA RSI,[0x1df10f]
MOV EDI,0x1
MOV RDX,R15
MOV RCX,R14
XOR EAX,EAX
CALL qword ptr [R8 + 0xa0]
LAB_001d0dba:
XOR EAX,EAX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001d0dcb:
MOV EAX,dword ptr [R13]
CMP EAX,0x8
JG 0x001d0df5
TEST EAX,EAX
JZ 0x001d0d98
CMP EAX,0x8
JNZ 0x001d0dba
ADD RBX,0x6e0
MOV EDX,0xc8
MOV RDI,RBX
XOR ESI,ESI
CALL 0x001292c0
JMP 0x001d0dba
LAB_001d0df5:
CMP EAX,0x9
JZ 0x001d0e22
CMP EAX,0x12d
JNZ 0x001d0dba
LEA RSI,[0x1df128]
MOV RDI,RBX
XOR EDX,EDX
XOR ECX,ECX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x001d1fc4
LAB_001d0e22:
MOV qword ptr [RBX + 0x690],0x0
MOV byte ptr [RBX + 0x6a0],0x0
JMP 0x001d0dba
|
int8 cs_enter(long param_1,char *param_2,size_t param_3)
{
long lVar1;
int iVar2;
int8 uVar3;
char *__s2;
int *piVar4;
lVar1 = *(long *)(param_1 + 0x140);
piVar4 = &sec;
__s2 = "xml";
while ((iVar2 = strncmp(param_2,__s2,param_3), iVar2 != 0 || (__s2[param_3] != '\0'))) {
__s2 = *(char **)(piVar4 + 6);
piVar4 = piVar4 + 4;
if (__s2 == (char *)0x0) {
LAB_001d0d98:
(**(code **)(*(long *)(lVar1 + 0x7a8) + 0xa0))(1,"Unknown LDML tag: \'%.*s\'",param_3,param_2)
;
return 0;
}
}
iVar2 = *piVar4;
if (8 < iVar2) {
if (iVar2 == 9) {
*(int8 *)(lVar1 + 0x690) = 0;
*(int1 *)(lVar1 + 0x6a0) = 0;
return 0;
}
if (iVar2 != 0x12d) {
return 0;
}
uVar3 = tailoring_append(lVar1,&DAT_001df128,0,0);
return uVar3;
}
if (iVar2 != 0) {
if (iVar2 != 8) {
return 0;
}
memset((void *)(lVar1 + 0x6e0),0,200);
return 0;
}
goto LAB_001d0d98;
}
|
|
9,992 |
format_literal(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
|
monkey531[P]llama/common/json-schema-to-grammar.cpp
|
static std::string format_literal(const std::string & literal) {
std::string escaped = replacePattern(literal, GRAMMAR_LITERAL_ESCAPE_RE, [&](const std::smatch & match) {
char c = match.str()[0];
return GRAMMAR_LITERAL_ESCAPES.at(c);
});
return "\"" + escaped + "\"";
}
|
O1
|
cpp
|
format_literal(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 $0x88, %rsp
movq %rdi, 0x80(%rsp)
xorps %xmm0, %xmm0
leaq 0x60(%rsp), %rcx
movaps %xmm0, (%rcx)
leaq 0x2f9(%rip), %rax # 0xbf630
movq %rax, 0x18(%rcx)
leaq 0x35e(%rip), %rax # 0xbf6a0
movq %rax, 0x10(%rcx)
movq %rsp, %r12
movaps %xmm0, 0x10(%r12)
movaps %xmm0, (%r12)
leaq 0x30(%rsp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movq (%rsi), %r14
movq 0x8(%rsi), %r15
addq %r14, %r15
leaq 0x70f77(%rip), %r13 # 0x1302f0
leaq 0x20(%rsp), %rbp
leaq 0x40(%rsp), %rbx
movq %r14, %rdi
movq %r15, %rsi
movq %r12, %rdx
movq %r13, %rcx
xorl %r8d, %r8d
callq 0x6e7bb
testb %al, %al
je 0xbf45d
movq (%rsp), %rax
movq 0x8(%rsp), %rcx
movq %rcx, %rdx
subq %rax, %rdx
leaq -0x48(%rcx), %rsi
cmpq $0x48, %rdx
movq %rax, %rdx
cmoveq %rsi, %rdx
cmpq %rax, %rcx
cmoveq %rsi, %rdx
movq (%rdx), %r8
subq 0x18(%rsp), %r8
movq 0x28(%rsp), %rsi
movq %rbp, %rdi
xorl %edx, %edx
movq %r14, %rcx
callq 0x1b9e0
cmpq $0x0, 0x70(%rsp)
je 0xbf55b
movq %rbx, %rdi
leaq 0x60(%rsp), %rsi
movq %r12, %rdx
callq *0x78(%rsp)
movq 0x40(%rsp), %rsi
movq 0x48(%rsp), %rdx
movq %rbp, %rdi
callq 0x1b270
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0xbf427
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq 0x8(%rsp), %rax
movq %rax, %rcx
subq (%rsp), %rcx
sarq $0x3, %rcx
movabsq $-0x5555555555555555, %rdx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rdx, %rcx
leaq -0x18(%rax), %rdx
addq $-0x48, %rax
cmpq $0x4, %rcx
cmovaeq %rdx, %rax
movq (%rax), %r14
jmp 0xbf383
leaq 0x20(%rsp), %rdi
movq 0x8(%rdi), %rsi
subq %r14, %r15
xorl %edx, %edx
movq %r14, %rcx
movq %r15, %r8
callq 0x1b9e0
movq (%rsp), %rdi
testq %rdi, %rdi
movq 0x80(%rsp), %rbx
je 0xbf494
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x1b8e0
movq 0x70(%rsp), %rax
testq %rax, %rax
je 0xbf4ad
leaq 0x60(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
leaq 0x3a79b(%rip), %rsi # 0xf9c4f
movq %rsp, %rdi
leaq 0x20(%rsp), %rdx
callq 0x55265
leaq 0x3a787(%rip), %rsi # 0xf9c4f
movq %rsp, %rdi
callq 0x1c0e0
leaq 0x10(%rbx), %rdx
movq %rdx, (%rbx)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0xbf4f2
movq %rsi, (%rbx)
movq (%rcx), %rdx
movq %rdx, 0x10(%rbx)
jmp 0xbf4f8
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)
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xbf52a
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0xbf546
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq %rbx, %rax
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x1b320
jmp 0xbf627
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xbf588
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1b8e0
jmp 0xbf588
movq %rax, %rbx
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0xbf61f
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1b8e0
jmp 0xbf61f
jmp 0xbf5d1
jmp 0xbf5d1
movq %rax, %rbx
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0xbf5d4
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x1b8e0
jmp 0xbf5d4
jmp 0xbf5d1
movq %rax, %rbx
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0xbf5f0
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq (%rsp), %rdi
testq %rdi, %rdi
je 0xbf606
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x1b8e0
movq 0x70(%rsp), %rax
testq %rax, %rax
je 0xbf61f
leaq 0x60(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rdi
callq 0x1bf90
movq %rax, %rdi
callq 0x231d1
nop
|
_ZL14format_literalRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 88h
mov [rsp+0B8h+var_38], rdi
xorps xmm0, xmm0
lea rcx, [rsp+0B8h+var_58]
movaps xmmword ptr [rcx], xmm0
lea rax, _ZNSt17_Function_handlerIFNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_13match_resultsIN9__gnu_cxx17__normal_iteratorIPKcS5_EESaINS0_9sub_matchISB_EEEEEEZL14format_literalRKS5_E3$_0E9_M_invokeERKSt9_Any_dataSH_; std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_invoke(std::_Any_data const&,std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&)
mov [rcx+18h], rax
lea rax, _ZNSt17_Function_handlerIFNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_13match_resultsIN9__gnu_cxx17__normal_iteratorIPKcS5_EESaINS0_9sub_matchISB_EEEEEEZL14format_literalRKS5_E3$_0E10_M_managerERSt9_Any_dataRKSN_St18_Manager_operation; std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_manager(std::_Any_data &,std::_Any_data const&,std::_Manager_operation)
mov [rcx+10h], rax
mov r12, rsp
movaps xmmword ptr [r12+10h], xmm0
movaps xmmword ptr [r12], xmm0
lea rax, [rsp+0B8h+var_88]
mov [rax-10h], rax
mov qword ptr [rax-8], 0
mov byte ptr [rax], 0
mov r14, [rsi]
mov r15, [rsi+8]
add r15, r14
lea r13, _Z25GRAMMAR_LITERAL_ESCAPE_REB5cxx11; GRAMMAR_LITERAL_ESCAPE_RE
lea rbp, [rsp+0B8h+var_98]
lea rbx, [rsp+0B8h+var_78]
loc_BF383:
mov rdi, r14
mov rsi, r15
mov rdx, r12
mov rcx, r13
xor r8d, r8d
call _ZNSt8__detail17__regex_algo_implIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEESaINS5_9sub_matchISB_EEEcNS5_12regex_traitsIcEELNS_20_RegexExecutorPolicyE0ELb0EEEbT_SI_RNS5_13match_resultsISI_T0_EERKNS5_11basic_regexIT1_T2_EENSt15regex_constants15match_flag_typeE; std::__detail::__regex_algo_impl<__gnu_cxx::__normal_iterator<char const*,std::string>,std::allocator<std::sub_match<__gnu_cxx::__normal_iterator<char const*,std::string>>>,char,std::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> &,std::basic_regex<char,std::regex_traits<char>> const&,std::regex_constants::match_flag_type)
test al, al
jz loc_BF45D
mov rax, [rsp+0B8h+var_B8]
mov rcx, [rsp+0B8h+var_B0]
mov rdx, rcx
sub rdx, rax
lea rsi, [rcx-48h]
cmp rdx, 48h ; 'H'
mov rdx, rax
cmovz rdx, rsi
cmp rcx, rax
cmovz rdx, rsi
mov r8, [rdx]
sub r8, [rsp+0B8h+var_A0]
mov rsi, [rsp+0B8h+var_90]
mov rdi, rbp
xor edx, edx
mov rcx, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong)
cmp [rsp+0B8h+var_48], 0
jz loc_BF55B
mov rdi, rbx
lea rsi, [rsp+0B8h+var_58]
mov rdx, r12
call [rsp+0B8h+var_40]
mov rsi, [rsp+0B8h+var_78]
mov rdx, [rsp+0B8h+var_70]
mov rdi, rbp
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
mov rdi, [rsp+0B8h+var_78]; void *
lea rax, [rsp+0B8h+var_68]
cmp rdi, rax
jz short loc_BF427
mov rsi, [rsp+0B8h+var_68]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BF427:
mov rax, [rsp+0B8h+var_B0]
mov rcx, rax
sub rcx, [rsp+0B8h+var_B8]
sar rcx, 3
mov rdx, 0AAAAAAAAAAAAAAABh
imul rcx, rdx
lea rdx, [rax-18h]
add rax, 0FFFFFFFFFFFFFFB8h
cmp rcx, 4
cmovnb rax, rdx
mov r14, [rax]
jmp loc_BF383
loc_BF45D:
lea rdi, [rsp+0B8h+var_98]
mov rsi, [rdi+8]
sub r15, r14
xor edx, edx
mov rcx, r14
mov r8, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong)
mov rdi, [rsp+0B8h+var_B8]; void *
test rdi, rdi
mov rbx, [rsp+0B8h+var_38]
jz short loc_BF494
mov rsi, [rsp+0B8h+var_A8]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BF494:
mov rax, [rsp+0B8h+var_48]
test rax, rax
jz short loc_BF4AD
lea rdi, [rsp+0B8h+var_58]
mov rsi, rdi
mov edx, 3
call rax
loc_BF4AD:
lea rsi, aName+9; "\""
mov rdi, rsp
lea rdx, [rsp+0B8h+var_98]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
lea rsi, aName+9; "\""
mov rdi, rsp
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_BF4F2
mov [rbx], rsi
mov rdx, [rcx]
mov [rbx+10h], rdx
jmp short loc_BF4F8
loc_BF4F2:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [rdx], xmm0
loc_BF4F8:
mov rdx, [rax+8]
mov [rbx+8], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
lea rax, [rsp+0B8h+var_A8]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_BF52A
mov rsi, [rsp+0B8h+var_A8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BF52A:
mov rdi, [rsp+0B8h+var_98]; void *
lea rax, [rsp+0B8h+var_88]
cmp rdi, rax
jz short loc_BF546
mov rsi, [rsp+0B8h+var_88]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BF546:
mov rax, rbx
add rsp, 88h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_BF55B:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
jmp loc_BF627
mov rbx, rax
lea rax, [rsp+0B8h+var_A8]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_BF588
mov rsi, [rsp+0B8h+var_A8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BF588
mov rbx, rax
loc_BF588:
mov rdi, [rsp+0B8h+var_98]; void *
lea rax, [rsp+0B8h+var_88]
cmp rdi, rax
jz loc_BF61F
mov rsi, [rsp+0B8h+var_88]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BF61F
jmp short loc_BF5D1
jmp short loc_BF5D1
mov rbx, rax
mov rdi, [rsp+0B8h+var_78]; void *
lea rax, [rsp+0B8h+var_68]
cmp rdi, rax
jz short loc_BF5D4
mov rsi, [rsp+0B8h+var_68]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BF5D4
jmp short $+2
loc_BF5D1:
mov rbx, rax
loc_BF5D4:
mov rdi, [rsp+0B8h+var_98]; void *
lea rax, [rsp+0B8h+var_88]
cmp rdi, rax
jz short loc_BF5F0
mov rsi, [rsp+0B8h+var_88]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BF5F0:
mov rdi, [rsp+0B8h+var_B8]; void *
test rdi, rdi
jz short loc_BF606
mov rsi, [rsp+0B8h+var_A8]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BF606:
mov rax, [rsp+0B8h+var_48]
test rax, rax
jz short loc_BF61F
lea rdi, [rsp+0B8h+var_58]
mov rsi, rdi
mov edx, 3
call rax
loc_BF61F:
mov rdi, rbx
call __Unwind_Resume
loc_BF627:
mov rdi, rax
call __clang_call_terminate
|
long long format_literal(long long a1, long long a2)
{
long long *v2; // r14
long long v3; // r15
_QWORD *v4; // rdx
long long **v5; // rax
long long v6; // rbx
long long v7; // rax
_OWORD *v8; // rcx
__int128 v10; // [rsp+0h] [rbp-B8h] BYREF
__int128 v11; // [rsp+10h] [rbp-A8h] BYREF
void *v12; // [rsp+20h] [rbp-98h] BYREF
long long v13; // [rsp+28h] [rbp-90h]
_QWORD v14[2]; // [rsp+30h] [rbp-88h] BYREF
void *v15[2]; // [rsp+40h] [rbp-78h] BYREF
long long v16; // [rsp+50h] [rbp-68h] BYREF
__int128 v17; // [rsp+60h] [rbp-58h] BYREF
long long ( *v18)(); // [rsp+70h] [rbp-48h]
long long ( *v19)(); // [rsp+78h] [rbp-40h]
long long v20; // [rsp+80h] [rbp-38h]
v20 = a1;
v17 = 0LL;
v19 = std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_invoke;
v18 = std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_manager;
v11 = 0LL;
v10 = 0LL;
v12 = v14;
v13 = 0LL;
LOBYTE(v14[0]) = 0;
v2 = *(long long **)a2;
v3 = *(_QWORD *)a2 + *(_QWORD *)(a2 + 8);
while ( (unsigned __int8)std::__detail::__regex_algo_impl<__gnu_cxx::__normal_iterator<char const*,std::string>,std::allocator<std::sub_match<__gnu_cxx::__normal_iterator<char const*,std::string>>>,char,std::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false>(
v2,
v3,
(long long **)&v10,
(long long)&GRAMMAR_LITERAL_ESCAPE_RE[abi:cxx11],
0) )
{
v4 = (_QWORD *)v10;
if ( *((_QWORD *)&v10 + 1) - (_QWORD)v10 == 72LL )
v4 = (_QWORD *)(*((_QWORD *)&v10 + 1) - 72LL);
if ( *((_QWORD *)&v10 + 1) == (_QWORD)v10 )
v4 = (_QWORD *)(*((_QWORD *)&v10 + 1) - 72LL);
std::string::replace(&v12, v13, 0LL, v2, *v4 - *((_QWORD *)&v11 + 1));
if ( !v18 )
std::__throw_bad_function_call();
((void ( *)(void **, __int128 *, __int128 *))v19)(v15, &v17, &v10);
std::string::_M_append(&v12, v15[0], v15[1]);
if ( v15[0] != &v16 )
operator delete(v15[0], v16 + 1);
v5 = (long long **)(*((_QWORD *)&v10 + 1) - 72LL);
if ( 0xAAAAAAAAAAAAAAABLL * ((long long)(*((_QWORD *)&v10 + 1) - v10) >> 3) >= 4 )
v5 = (long long **)(*((_QWORD *)&v10 + 1) - 24LL);
v2 = *v5;
}
std::string::replace(&v12, v13, 0LL, v2, v3 - (_QWORD)v2);
v6 = v20;
if ( (_QWORD)v10 )
operator delete((void *)v10, v11 - v10);
if ( v18 )
((void ( *)(__int128 *, __int128 *, long long))v18)(&v17, &v17, 3LL);
std::operator+<char>((long long)&v10, (long long)"\"", &v12);
v7 = std::string::append(&v10, "\"");
*(_QWORD *)v6 = v6 + 16;
v8 = (_OWORD *)(v7 + 16);
if ( *(_QWORD *)v7 == v7 + 16 )
{
*(_OWORD *)(v6 + 16) = *v8;
}
else
{
*(_QWORD *)v6 = *(_QWORD *)v7;
*(_QWORD *)(v6 + 16) = *(_QWORD *)v8;
}
*(_QWORD *)(v6 + 8) = *(_QWORD *)(v7 + 8);
*(_QWORD *)v7 = v8;
*(_QWORD *)(v7 + 8) = 0LL;
*(_BYTE *)(v7 + 16) = 0;
if ( (__int128 *)v10 != &v11 )
operator delete((void *)v10, v11 + 1);
if ( v12 != v14 )
operator delete(v12, v14[0] + 1LL);
return v6;
}
|
format_literal:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x88
MOV qword ptr [RSP + 0x80],RDI
XORPS XMM0,XMM0
LEA RCX,[RSP + 0x60]
MOVAPS xmmword ptr [RCX],XMM0
LEA RAX,[0x1bf630]
MOV qword ptr [RCX + 0x18],RAX
LEA RAX,[0x1bf6a0]
MOV qword ptr [RCX + 0x10],RAX
MOV R12,RSP
MOVAPS xmmword ptr [R12 + 0x10],XMM0
MOVAPS xmmword ptr [R12],XMM0
LEA RAX,[RSP + 0x30]
MOV qword ptr [RAX + -0x10],RAX
MOV qword ptr [RAX + -0x8],0x0
MOV byte ptr [RAX],0x0
MOV R14,qword ptr [RSI]
MOV R15,qword ptr [RSI + 0x8]
ADD R15,R14
LEA R13,[0x2302f0]
LEA RBP,[RSP + 0x20]
LEA RBX,[RSP + 0x40]
LAB_001bf383:
MOV RDI,R14
MOV RSI,R15
MOV RDX,R12
MOV RCX,R13
XOR R8D,R8D
CALL 0x0016e7bb
TEST AL,AL
JZ 0x001bf45d
MOV RAX,qword ptr [RSP]
MOV RCX,qword ptr [RSP + 0x8]
MOV RDX,RCX
SUB RDX,RAX
LEA RSI,[RCX + -0x48]
CMP RDX,0x48
MOV RDX,RAX
CMOVZ RDX,RSI
CMP RCX,RAX
CMOVZ RDX,RSI
MOV R8,qword ptr [RDX]
SUB R8,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDI,RBP
XOR EDX,EDX
MOV RCX,R14
CALL 0x0011b9e0
CMP qword ptr [RSP + 0x70],0x0
JZ 0x001bf55b
LAB_001bf3ea:
MOV RDI,RBX
LEA RSI,[RSP + 0x60]
MOV RDX,R12
CALL qword ptr [RSP + 0x78]
MOV RSI,qword ptr [RSP + 0x40]
MOV RDX,qword ptr [RSP + 0x48]
LAB_001bf403:
MOV RDI,RBP
CALL 0x0011b270
MOV RDI,qword ptr [RSP + 0x40]
LEA RAX,[RSP + 0x50]
CMP RDI,RAX
JZ 0x001bf427
MOV RSI,qword ptr [RSP + 0x50]
INC RSI
CALL 0x0011b8e0
LAB_001bf427:
MOV RAX,qword ptr [RSP + 0x8]
MOV RCX,RAX
SUB RCX,qword ptr [RSP]
SAR RCX,0x3
MOV RDX,-0x5555555555555555
IMUL RCX,RDX
LEA RDX,[RAX + -0x18]
ADD RAX,-0x48
CMP RCX,0x4
CMOVNC RAX,RDX
MOV R14,qword ptr [RAX]
JMP 0x001bf383
LAB_001bf45d:
LEA RDI,[RSP + 0x20]
MOV RSI,qword ptr [RDI + 0x8]
SUB R15,R14
LAB_001bf469:
XOR EDX,EDX
MOV RCX,R14
MOV R8,R15
CALL 0x0011b9e0
MOV RDI,qword ptr [RSP]
TEST RDI,RDI
MOV RBX,qword ptr [RSP + 0x80]
JZ 0x001bf494
MOV RSI,qword ptr [RSP + 0x10]
SUB RSI,RDI
CALL 0x0011b8e0
LAB_001bf494:
MOV RAX,qword ptr [RSP + 0x70]
TEST RAX,RAX
JZ 0x001bf4ad
LAB_001bf49e:
LEA RDI,[RSP + 0x60]
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_001bf4ad:
LEA RSI,[0x1f9c4f]
MOV RDI,RSP
LEA RDX,[RSP + 0x20]
CALL 0x00155265
LAB_001bf4c1:
LEA RSI,[0x1f9c4f]
MOV RDI,RSP
CALL 0x0011c0e0
LEA RDX,[RBX + 0x10]
MOV qword ptr [RBX],RDX
MOV RSI,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RSI,RCX
JZ 0x001bf4f2
MOV qword ptr [RBX],RSI
MOV RDX,qword ptr [RCX]
MOV qword ptr [RBX + 0x10],RDX
JMP 0x001bf4f8
LAB_001bf4f2:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [RDX],XMM0
LAB_001bf4f8:
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
LEA RAX,[RSP + 0x10]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x001bf52a
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0011b8e0
LAB_001bf52a:
MOV RDI,qword ptr [RSP + 0x20]
LEA RAX,[RSP + 0x30]
CMP RDI,RAX
JZ 0x001bf546
MOV RSI,qword ptr [RSP + 0x30]
INC RSI
CALL 0x0011b8e0
LAB_001bf546:
MOV RAX,RBX
ADD RSP,0x88
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001bf55b:
CALL 0x0011b320
|
/* format_literal(std::__cxx11::string const&) */
string * format_literal(string *param_1)
{
string *psVar1;
bool bVar2;
ulong *puVar3;
int8 *puVar4;
long *plVar5;
ulong *in_RSI;
ulong uVar6;
long lVar7;
long *local_b8;
long lStack_b0;
long local_a8 [2];
int1 *local_98;
ulong local_90;
int1 local_88;
int7 uStack_87;
long *local_78 [2];
long local_68 [2];
int8 local_58;
int8 uStack_50;
code *local_48;
code *local_40;
string *local_38;
local_58 = 0;
uStack_50 = 0;
local_40 = std::
_Function_handler<std::__cxx11::string(std::__cxx11::match_results<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>>const&),format_literal(std::__cxx11::string_const&)::$_0>
::_M_invoke;
local_48 = std::
_Function_handler<std::__cxx11::string(std::__cxx11::match_results<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>>const&),format_literal(std::__cxx11::string_const&)::$_0>
::_M_manager;
local_a8[0] = 0;
local_a8[1] = 0;
local_b8 = (long *)0x0;
lStack_b0 = 0;
local_98 = &local_88;
local_90 = 0;
local_88 = 0;
uVar6 = *in_RSI;
lVar7 = in_RSI[1] + uVar6;
local_38 = param_1;
while( true ) {
/* try { // try from 001bf383 to 001bf3dd has its CatchHandler @ 001bf5d1 */
bVar2 = std::__detail::
__regex_algo_impl<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>,char,std::__cxx11::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false>
(uVar6,lVar7,&local_b8,GRAMMAR_LITERAL_ESCAPE_RE_abi_cxx11_,0);
if (!bVar2) {
/* try { // try from 001bf469 to 001bf475 has its CatchHandler @ 001bf5aa */
std::__cxx11::string::replace((ulong)&local_98,local_90,(char *)0x0,uVar6);
psVar1 = local_38;
if (local_b8 != (long *)0x0) {
operator_delete(local_b8,local_a8[0] - (long)local_b8);
}
if (local_48 != (code *)0x0) {
/* try { // try from 001bf49e to 001bf4ac has its CatchHandler @ 001bf560 */
(*local_48)(&local_58,&local_58,3);
}
/* try { // try from 001bf4ad to 001bf4c0 has its CatchHandler @ 001bf585 */
std::operator+((char *)&local_b8,(string *)&DAT_001f9c4f);
/* try { // try from 001bf4c1 to 001bf4cf has its CatchHandler @ 001bf565 */
puVar4 = (int8 *)std::__cxx11::string::append((char *)&local_b8);
*(string **)psVar1 = psVar1 + 0x10;
plVar5 = puVar4 + 2;
if ((long *)*puVar4 == plVar5) {
lVar7 = puVar4[3];
*(long *)(psVar1 + 0x10) = *plVar5;
*(long *)(psVar1 + 0x18) = lVar7;
}
else {
*(long **)psVar1 = (long *)*puVar4;
*(long *)(psVar1 + 0x10) = *plVar5;
}
*(int8 *)(psVar1 + 8) = puVar4[1];
*puVar4 = plVar5;
puVar4[1] = 0;
*(int1 *)(puVar4 + 2) = 0;
if (local_b8 != local_a8) {
operator_delete(local_b8,local_a8[0] + 1);
}
if (local_98 != &local_88) {
operator_delete(local_98,CONCAT71(uStack_87,local_88) + 1);
}
return psVar1;
}
std::__cxx11::string::replace((ulong)&local_98,local_90,(char *)0x0,uVar6);
if (local_48 == (code *)0x0) break;
/* try { // try from 001bf3ea to 001bf3f8 has its CatchHandler @ 001bf5cf */
(*local_40)(local_78,&local_58,&local_b8);
/* try { // try from 001bf403 to 001bf40a has its CatchHandler @ 001bf5ae */
std::__cxx11::string::_M_append((char *)&local_98,(ulong)local_78[0]);
if (local_78[0] != local_68) {
operator_delete(local_78[0],local_68[0] + 1);
}
puVar3 = (ulong *)(lStack_b0 + -0x48);
if (3 < (ulong)((lStack_b0 - (long)local_b8 >> 3) * -0x5555555555555555)) {
puVar3 = (ulong *)(lStack_b0 + -0x18);
}
uVar6 = *puVar3;
}
/* WARNING: Subroutine does not return */
/* try { // try from 001bf55b to 001bf55f has its CatchHandler @ 001bf5ac */
std::__throw_bad_function_call();
}
|
|
9,993 |
format_literal(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
|
monkey531[P]llama/common/json-schema-to-grammar.cpp
|
static std::string format_literal(const std::string & literal) {
std::string escaped = replacePattern(literal, GRAMMAR_LITERAL_ESCAPE_RE, [&](const std::smatch & match) {
char c = match.str()[0];
return GRAMMAR_LITERAL_ESCAPES.at(c);
});
return "\"" + escaped + "\"";
}
|
O3
|
cpp
|
format_literal(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 $0x88, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, 0x80(%rsp)
xorps %xmm0, %xmm0
leaq 0x60(%rsp), %rcx
movaps %xmm0, (%rcx)
leaq 0x2ef(%rip), %rax # 0xbde00
movq %rax, 0x18(%rcx)
leaq 0x366(%rip), %rax # 0xbde82
movq %rax, 0x10(%rcx)
movq %rsp, %r12
movaps %xmm0, 0x10(%r12)
movaps %xmm0, (%r12)
leaq 0x30(%rsp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
addq %rsi, %r14
leaq 0x6f7a4(%rip), %r13 # 0x12d2f0
leaq 0x20(%rsp), %rbp
leaq 0x40(%rsp), %rbx
movq %r15, %rdi
movq %r14, %rsi
movq %r12, %rdx
movq %r13, %rcx
xorl %r8d, %r8d
callq 0x6e023
testb %al, %al
je 0xbdc30
movq (%rsp), %rax
movq 0x8(%rsp), %rcx
movq %rcx, %rdx
subq %rax, %rdx
leaq -0x48(%rcx), %rsi
cmpq $0x48, %rdx
movq %rax, %rdx
cmoveq %rsi, %rdx
cmpq %rax, %rcx
cmoveq %rsi, %rdx
movq (%rdx), %r8
subq 0x18(%rsp), %r8
movq 0x28(%rsp), %rsi
movq %rbp, %rdi
xorl %edx, %edx
movq %r15, %rcx
callq 0x1a9e0
cmpq $0x0, 0x70(%rsp)
je 0xbdd2b
movq %rbx, %rdi
leaq 0x60(%rsp), %rsi
movq %r12, %rdx
callq *0x78(%rsp)
movq 0x40(%rsp), %rsi
movq 0x48(%rsp), %rdx
movq %rbp, %rdi
callq 0x1a270
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0xbdbfa
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x1a8e0
movq 0x8(%rsp), %rax
movq %rax, %rcx
subq (%rsp), %rcx
sarq $0x3, %rcx
movabsq $-0x5555555555555555, %rdx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rdx, %rcx
leaq -0x18(%rax), %rdx
addq $-0x48, %rax
cmpq $0x4, %rcx
cmovaeq %rdx, %rax
movq (%rax), %r15
jmp 0xbdb56
leaq 0x20(%rsp), %rdi
movq 0x8(%rdi), %rsi
subq %r15, %r14
xorl %edx, %edx
movq %r15, %rcx
movq %r14, %r8
callq 0x1a9e0
movq (%rsp), %rdi
testq %rdi, %rdi
movq 0x80(%rsp), %rbx
je 0xbdc67
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x1a8e0
movq 0x70(%rsp), %rax
testq %rax, %rax
je 0xbdc80
leaq 0x60(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
leaq 0x38fa8(%rip), %rsi # 0xf6c2f
movq %rsp, %rdi
leaq 0x20(%rsp), %rdx
callq 0x54c9d
leaq 0x38f94(%rip), %rsi # 0xf6c2f
movq %rsp, %rdi
callq 0x1b0e0
leaq 0x10(%rbx), %rdx
movq %rdx, (%rbx)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0xbdcc5
movq %rsi, (%rbx)
movq (%rcx), %rdx
movq %rdx, 0x10(%rbx)
jmp 0xbdccb
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)
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xbdcfd
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1a8e0
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0xbdd19
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1a8e0
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x1a320
jmp 0xbddf7
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xbdd58
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1a8e0
jmp 0xbdd58
movq %rax, %rbx
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0xbddef
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1a8e0
jmp 0xbddef
jmp 0xbdda1
jmp 0xbdda1
movq %rax, %rbx
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0xbdda4
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x1a8e0
jmp 0xbdda4
jmp 0xbdda1
movq %rax, %rbx
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0xbddc0
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1a8e0
movq (%rsp), %rdi
testq %rdi, %rdi
je 0xbddd6
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x1a8e0
movq 0x70(%rsp), %rax
testq %rax, %rax
je 0xbddef
leaq 0x60(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rdi
callq 0x1af90
movq %rax, %rdi
callq 0x22203
nop
|
_ZL14format_literalRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 88h
mov r14, rdx
mov r15, rsi
mov [rsp+0B8h+var_38], rdi
xorps xmm0, xmm0
lea rcx, [rsp+0B8h+var_58]
movaps xmmword ptr [rcx], xmm0
lea rax, _ZNSt17_Function_handlerIFNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_13match_resultsIN9__gnu_cxx17__normal_iteratorIPKcS5_EESaINS0_9sub_matchISB_EEEEEEZL14format_literalRKS5_E3$_0E9_M_invokeERKSt9_Any_dataSH_; std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_invoke(std::_Any_data const&,std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&)
mov [rcx+18h], rax
lea rax, _ZNSt17_Function_handlerIFNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_13match_resultsIN9__gnu_cxx17__normal_iteratorIPKcS5_EESaINS0_9sub_matchISB_EEEEEEZL14format_literalRKS5_E3$_0E10_M_managerERSt9_Any_dataRKSN_St18_Manager_operation; std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_manager(std::_Any_data &,std::_Any_data const&,std::_Manager_operation)
mov [rcx+10h], rax
mov r12, rsp
movaps xmmword ptr [r12+10h], xmm0
movaps xmmword ptr [r12], xmm0
lea rax, [rsp+0B8h+var_88]
mov [rax-10h], rax
mov qword ptr [rax-8], 0
mov byte ptr [rax], 0
add r14, rsi
lea r13, _Z25GRAMMAR_LITERAL_ESCAPE_REB5cxx11; GRAMMAR_LITERAL_ESCAPE_RE
lea rbp, [rsp+0B8h+var_98]
lea rbx, [rsp+0B8h+var_78]
loc_BDB56:
mov rdi, r15
mov rsi, r14
mov rdx, r12
mov rcx, r13
xor r8d, r8d
call _ZNSt8__detail17__regex_algo_implIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEESaINS5_9sub_matchISB_EEEcNS5_12regex_traitsIcEELNS_20_RegexExecutorPolicyE0ELb0EEEbT_SI_RNS5_13match_resultsISI_T0_EERKNS5_11basic_regexIT1_T2_EENSt15regex_constants15match_flag_typeE; std::__detail::__regex_algo_impl<__gnu_cxx::__normal_iterator<char const*,std::string>,std::allocator<std::sub_match<__gnu_cxx::__normal_iterator<char const*,std::string>>>,char,std::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> &,std::basic_regex<char,std::regex_traits<char>> const&,std::regex_constants::match_flag_type)
test al, al
jz loc_BDC30
mov rax, [rsp+0B8h+var_B8]
mov rcx, [rsp+0B8h+var_B0]
mov rdx, rcx
sub rdx, rax
lea rsi, [rcx-48h]
cmp rdx, 48h ; 'H'
mov rdx, rax
cmovz rdx, rsi
cmp rcx, rax
cmovz rdx, rsi
mov r8, [rdx]
sub r8, [rsp+0B8h+var_A0]
mov rsi, [rsp+0B8h+var_90]
mov rdi, rbp
xor edx, edx
mov rcx, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong)
cmp [rsp+0B8h+var_48], 0
jz loc_BDD2B
mov rdi, rbx
lea rsi, [rsp+0B8h+var_58]
mov rdx, r12
call [rsp+0B8h+var_40]
mov rsi, [rsp+0B8h+var_78]
mov rdx, [rsp+0B8h+var_70]
mov rdi, rbp
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
mov rdi, [rsp+0B8h+var_78]; void *
lea rax, [rsp+0B8h+var_68]
cmp rdi, rax
jz short loc_BDBFA
mov rsi, [rsp+0B8h+var_68]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BDBFA:
mov rax, [rsp+0B8h+var_B0]
mov rcx, rax
sub rcx, [rsp+0B8h+var_B8]
sar rcx, 3
mov rdx, 0AAAAAAAAAAAAAAABh
imul rcx, rdx
lea rdx, [rax-18h]
add rax, 0FFFFFFFFFFFFFFB8h
cmp rcx, 4
cmovnb rax, rdx
mov r15, [rax]
jmp loc_BDB56
loc_BDC30:
lea rdi, [rsp+0B8h+var_98]
mov rsi, [rdi+8]
sub r14, r15
xor edx, edx
mov rcx, r15
mov r8, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong)
mov rdi, [rsp+0B8h+var_B8]; void *
test rdi, rdi
mov rbx, [rsp+0B8h+var_38]
jz short loc_BDC67
mov rsi, [rsp+0B8h+var_A8]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BDC67:
mov rax, [rsp+0B8h+var_48]
test rax, rax
jz short loc_BDC80
lea rdi, [rsp+0B8h+var_58]
mov rsi, rdi
mov edx, 3
call rax
loc_BDC80:
lea rsi, aName+9; "\""
mov rdi, rsp
lea rdx, [rsp+0B8h+var_98]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
lea rsi, aName+9; "\""
mov rdi, rsp
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_BDCC5
mov [rbx], rsi
mov rdx, [rcx]
mov [rbx+10h], rdx
jmp short loc_BDCCB
loc_BDCC5:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [rdx], xmm0
loc_BDCCB:
mov rdx, [rax+8]
mov [rbx+8], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
lea rax, [rsp+0B8h+var_A8]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_BDCFD
mov rsi, [rsp+0B8h+var_A8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BDCFD:
mov rdi, [rsp+0B8h+var_98]; void *
lea rax, [rsp+0B8h+var_88]
cmp rdi, rax
jz short loc_BDD19
mov rsi, [rsp+0B8h+var_88]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BDD19:
add rsp, 88h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_BDD2B:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
jmp loc_BDDF7
mov rbx, rax
lea rax, [rsp+0B8h+var_A8]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_BDD58
mov rsi, [rsp+0B8h+var_A8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BDD58
mov rbx, rax
loc_BDD58:
mov rdi, [rsp+0B8h+var_98]; void *
lea rax, [rsp+0B8h+var_88]
cmp rdi, rax
jz loc_BDDEF
mov rsi, [rsp+0B8h+var_88]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BDDEF
jmp short loc_BDDA1
jmp short loc_BDDA1
mov rbx, rax
mov rdi, [rsp+0B8h+var_78]; void *
lea rax, [rsp+0B8h+var_68]
cmp rdi, rax
jz short loc_BDDA4
mov rsi, [rsp+0B8h+var_68]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_BDDA4
jmp short $+2
loc_BDDA1:
mov rbx, rax
loc_BDDA4:
mov rdi, [rsp+0B8h+var_98]; void *
lea rax, [rsp+0B8h+var_88]
cmp rdi, rax
jz short loc_BDDC0
mov rsi, [rsp+0B8h+var_88]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BDDC0:
mov rdi, [rsp+0B8h+var_B8]; void *
test rdi, rdi
jz short loc_BDDD6
mov rsi, [rsp+0B8h+var_A8]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BDDD6:
mov rax, [rsp+0B8h+var_48]
test rax, rax
jz short loc_BDDEF
lea rdi, [rsp+0B8h+var_58]
mov rsi, rdi
mov edx, 3
call rax
loc_BDDEF:
mov rdi, rbx
call __Unwind_Resume
loc_BDDF7:
mov rdi, rax
call __clang_call_terminate
|
void format_literal(long long a1, long long *a2, long long a3)
{
long long *v3; // r15
long long v4; // r14
_QWORD *v5; // rdx
long long **v6; // rax
long long v7; // rbx
long long v8; // rax
_OWORD *v9; // rcx
__int128 v10; // [rsp+0h] [rbp-B8h] BYREF
__int128 v11; // [rsp+10h] [rbp-A8h] BYREF
void *v12; // [rsp+20h] [rbp-98h] BYREF
long long v13; // [rsp+28h] [rbp-90h]
_QWORD v14[2]; // [rsp+30h] [rbp-88h] BYREF
void *v15[2]; // [rsp+40h] [rbp-78h] BYREF
long long v16; // [rsp+50h] [rbp-68h] BYREF
__int128 v17; // [rsp+60h] [rbp-58h] BYREF
long long ( *v18)(); // [rsp+70h] [rbp-48h]
long long ( *v19)(); // [rsp+78h] [rbp-40h]
long long v20; // [rsp+80h] [rbp-38h]
v3 = a2;
v20 = a1;
v17 = 0LL;
v19 = std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_invoke;
v18 = std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_manager;
v11 = 0LL;
v10 = 0LL;
v12 = v14;
v13 = 0LL;
LOBYTE(v14[0]) = 0;
v4 = (long long)a2 + a3;
while ( std::__detail::__regex_algo_impl<__gnu_cxx::__normal_iterator<char const*,std::string>,std::allocator<std::sub_match<__gnu_cxx::__normal_iterator<char const*,std::string>>>,char,std::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false>(
v3,
v4,
(long long **)&v10,
(long long)&GRAMMAR_LITERAL_ESCAPE_RE[abi:cxx11],
0) )
{
v5 = (_QWORD *)v10;
if ( *((_QWORD *)&v10 + 1) - (_QWORD)v10 == 72LL )
v5 = (_QWORD *)(*((_QWORD *)&v10 + 1) - 72LL);
if ( *((_QWORD *)&v10 + 1) == (_QWORD)v10 )
v5 = (_QWORD *)(*((_QWORD *)&v10 + 1) - 72LL);
std::string::replace(&v12, v13, 0LL, v3, *v5 - *((_QWORD *)&v11 + 1));
if ( !v18 )
std::__throw_bad_function_call();
((void ( *)(void **, __int128 *, __int128 *))v19)(v15, &v17, &v10);
std::string::_M_append(&v12, v15[0], v15[1]);
if ( v15[0] != &v16 )
operator delete(v15[0], v16 + 1);
v6 = (long long **)(*((_QWORD *)&v10 + 1) - 72LL);
if ( 0xAAAAAAAAAAAAAAABLL * ((long long)(*((_QWORD *)&v10 + 1) - v10) >> 3) >= 4 )
v6 = (long long **)(*((_QWORD *)&v10 + 1) - 24LL);
v3 = *v6;
}
std::string::replace(&v12, v13, 0LL, v3, v4 - (_QWORD)v3);
v7 = v20;
if ( (_QWORD)v10 )
operator delete((void *)v10, v11 - v10);
if ( v18 )
((void ( *)(__int128 *, __int128 *, long long))v18)(&v17, &v17, 3LL);
std::operator+<char>((long long)&v10, (long long)"\"", &v12);
v8 = std::string::append(&v10, "\"");
*(_QWORD *)v7 = v7 + 16;
v9 = (_OWORD *)(v8 + 16);
if ( *(_QWORD *)v8 == v8 + 16 )
{
*(_OWORD *)(v7 + 16) = *v9;
}
else
{
*(_QWORD *)v7 = *(_QWORD *)v8;
*(_QWORD *)(v7 + 16) = *(_QWORD *)v9;
}
*(_QWORD *)(v7 + 8) = *(_QWORD *)(v8 + 8);
*(_QWORD *)v8 = v9;
*(_QWORD *)(v8 + 8) = 0LL;
*(_BYTE *)(v8 + 16) = 0;
if ( (__int128 *)v10 != &v11 )
operator delete((void *)v10, v11 + 1);
if ( v12 != v14 )
operator delete(v12, v14[0] + 1LL);
}
|
format_literal:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x88
MOV R14,RDX
MOV R15,RSI
MOV qword ptr [RSP + 0x80],RDI
XORPS XMM0,XMM0
LEA RCX,[RSP + 0x60]
MOVAPS xmmword ptr [RCX],XMM0
LEA RAX,[0x1bde00]
MOV qword ptr [RCX + 0x18],RAX
LEA RAX,[0x1bde82]
MOV qword ptr [RCX + 0x10],RAX
MOV R12,RSP
MOVAPS xmmword ptr [R12 + 0x10],XMM0
MOVAPS xmmword ptr [R12],XMM0
LEA RAX,[RSP + 0x30]
MOV qword ptr [RAX + -0x10],RAX
MOV qword ptr [RAX + -0x8],0x0
MOV byte ptr [RAX],0x0
ADD R14,RSI
LEA R13,[0x22d2f0]
LEA RBP,[RSP + 0x20]
LEA RBX,[RSP + 0x40]
LAB_001bdb56:
MOV RDI,R15
MOV RSI,R14
MOV RDX,R12
MOV RCX,R13
XOR R8D,R8D
CALL 0x0016e023
TEST AL,AL
JZ 0x001bdc30
MOV RAX,qword ptr [RSP]
MOV RCX,qword ptr [RSP + 0x8]
MOV RDX,RCX
SUB RDX,RAX
LEA RSI,[RCX + -0x48]
CMP RDX,0x48
MOV RDX,RAX
CMOVZ RDX,RSI
CMP RCX,RAX
CMOVZ RDX,RSI
MOV R8,qword ptr [RDX]
SUB R8,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDI,RBP
XOR EDX,EDX
MOV RCX,R15
CALL 0x0011a9e0
CMP qword ptr [RSP + 0x70],0x0
JZ 0x001bdd2b
LAB_001bdbbd:
MOV RDI,RBX
LEA RSI,[RSP + 0x60]
MOV RDX,R12
CALL qword ptr [RSP + 0x78]
MOV RSI,qword ptr [RSP + 0x40]
MOV RDX,qword ptr [RSP + 0x48]
LAB_001bdbd6:
MOV RDI,RBP
CALL 0x0011a270
MOV RDI,qword ptr [RSP + 0x40]
LEA RAX,[RSP + 0x50]
CMP RDI,RAX
JZ 0x001bdbfa
MOV RSI,qword ptr [RSP + 0x50]
INC RSI
CALL 0x0011a8e0
LAB_001bdbfa:
MOV RAX,qword ptr [RSP + 0x8]
MOV RCX,RAX
SUB RCX,qword ptr [RSP]
SAR RCX,0x3
MOV RDX,-0x5555555555555555
IMUL RCX,RDX
LEA RDX,[RAX + -0x18]
ADD RAX,-0x48
CMP RCX,0x4
CMOVNC RAX,RDX
MOV R15,qword ptr [RAX]
JMP 0x001bdb56
LAB_001bdc30:
LEA RDI,[RSP + 0x20]
MOV RSI,qword ptr [RDI + 0x8]
SUB R14,R15
LAB_001bdc3c:
XOR EDX,EDX
MOV RCX,R15
MOV R8,R14
CALL 0x0011a9e0
MOV RDI,qword ptr [RSP]
TEST RDI,RDI
MOV RBX,qword ptr [RSP + 0x80]
JZ 0x001bdc67
MOV RSI,qword ptr [RSP + 0x10]
SUB RSI,RDI
CALL 0x0011a8e0
LAB_001bdc67:
MOV RAX,qword ptr [RSP + 0x70]
TEST RAX,RAX
JZ 0x001bdc80
LAB_001bdc71:
LEA RDI,[RSP + 0x60]
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_001bdc80:
LEA RSI,[0x1f6c2f]
MOV RDI,RSP
LEA RDX,[RSP + 0x20]
CALL 0x00154c9d
LAB_001bdc94:
LEA RSI,[0x1f6c2f]
MOV RDI,RSP
CALL 0x0011b0e0
LEA RDX,[RBX + 0x10]
MOV qword ptr [RBX],RDX
MOV RSI,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RSI,RCX
JZ 0x001bdcc5
MOV qword ptr [RBX],RSI
MOV RDX,qword ptr [RCX]
MOV qword ptr [RBX + 0x10],RDX
JMP 0x001bdccb
LAB_001bdcc5:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [RDX],XMM0
LAB_001bdccb:
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
LEA RAX,[RSP + 0x10]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x001bdcfd
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0011a8e0
LAB_001bdcfd:
MOV RDI,qword ptr [RSP + 0x20]
LEA RAX,[RSP + 0x30]
CMP RDI,RAX
JZ 0x001bdd19
MOV RSI,qword ptr [RSP + 0x30]
INC RSI
CALL 0x0011a8e0
LAB_001bdd19:
ADD RSP,0x88
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001bdd2b:
CALL 0x0011a320
|
/* format_literal(std::__cxx11::string const&) */
void format_literal(string *param_1)
{
string *psVar1;
bool bVar2;
ulong *puVar3;
int8 *puVar4;
long *plVar5;
long in_RDX;
ulong in_RSI;
long lVar6;
long *local_b8;
long lStack_b0;
long local_a8 [2];
int1 *local_98;
ulong local_90;
int1 local_88;
int7 uStack_87;
long *local_78 [2];
long local_68 [2];
int8 local_58;
int8 uStack_50;
code *local_48;
code *local_40;
string *local_38;
local_58 = 0;
uStack_50 = 0;
local_40 = std::
_Function_handler<std::__cxx11::string(std::__cxx11::match_results<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>>const&),format_literal(std::__cxx11::string_const&)::$_0>
::_M_invoke;
local_48 = std::
_Function_handler<std::__cxx11::string(std::__cxx11::match_results<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>>const&),format_literal(std::__cxx11::string_const&)::$_0>
::_M_manager;
local_a8[0] = 0;
local_a8[1] = 0;
local_b8 = (long *)0x0;
lStack_b0 = 0;
local_98 = &local_88;
local_90 = 0;
local_88 = 0;
lVar6 = in_RDX + in_RSI;
local_38 = param_1;
while( true ) {
/* try { // try from 001bdb56 to 001bdbb0 has its CatchHandler @ 001bdda1 */
bVar2 = std::__detail::
__regex_algo_impl<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>,char,std::__cxx11::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false>
(in_RSI,lVar6,&local_b8,GRAMMAR_LITERAL_ESCAPE_RE_abi_cxx11_,0);
if (!bVar2) {
/* try { // try from 001bdc3c to 001bdc48 has its CatchHandler @ 001bdd7a */
std::__cxx11::string::replace((ulong)&local_98,local_90,(char *)0x0,in_RSI);
psVar1 = local_38;
if (local_b8 != (long *)0x0) {
operator_delete(local_b8,local_a8[0] - (long)local_b8);
}
if (local_48 != (code *)0x0) {
/* try { // try from 001bdc71 to 001bdc7f has its CatchHandler @ 001bdd30 */
(*local_48)(&local_58,&local_58,3);
}
/* try { // try from 001bdc80 to 001bdc93 has its CatchHandler @ 001bdd55 */
std::operator+((char *)&local_b8,(string *)&DAT_001f6c2f);
/* try { // try from 001bdc94 to 001bdca2 has its CatchHandler @ 001bdd35 */
puVar4 = (int8 *)std::__cxx11::string::append((char *)&local_b8);
*(string **)psVar1 = psVar1 + 0x10;
plVar5 = puVar4 + 2;
if ((long *)*puVar4 == plVar5) {
lVar6 = puVar4[3];
*(long *)(psVar1 + 0x10) = *plVar5;
*(long *)(psVar1 + 0x18) = lVar6;
}
else {
*(long **)psVar1 = (long *)*puVar4;
*(long *)(psVar1 + 0x10) = *plVar5;
}
*(int8 *)(psVar1 + 8) = puVar4[1];
*puVar4 = plVar5;
puVar4[1] = 0;
*(int1 *)(puVar4 + 2) = 0;
if (local_b8 != local_a8) {
operator_delete(local_b8,local_a8[0] + 1);
}
if (local_98 != &local_88) {
operator_delete(local_98,CONCAT71(uStack_87,local_88) + 1);
}
return;
}
std::__cxx11::string::replace((ulong)&local_98,local_90,(char *)0x0,in_RSI);
if (local_48 == (code *)0x0) break;
/* try { // try from 001bdbbd to 001bdbcb has its CatchHandler @ 001bdd9f */
(*local_40)(local_78,&local_58,&local_b8);
/* try { // try from 001bdbd6 to 001bdbdd has its CatchHandler @ 001bdd7e */
std::__cxx11::string::_M_append((char *)&local_98,(ulong)local_78[0]);
if (local_78[0] != local_68) {
operator_delete(local_78[0],local_68[0] + 1);
}
puVar3 = (ulong *)(lStack_b0 + -0x48);
if (3 < (ulong)((lStack_b0 - (long)local_b8 >> 3) * -0x5555555555555555)) {
puVar3 = (ulong *)(lStack_b0 + -0x18);
}
in_RSI = *puVar3;
}
/* WARNING: Subroutine does not return */
/* try { // try from 001bdd2b to 001bdd2f has its CatchHandler @ 001bdd7c */
std::__throw_bad_function_call();
}
|
|
9,994 |
void msgpack23::Packer<true>::emplace_integral<unsigned short>(unsigned short const&)
|
msgpack23/include/msgpack23/msgpack23.h
|
void emplace_integral(T const &value) {
if constexpr (IsDryRun) {
required_size_ += sizeof(T);
} else {
auto const serialize_value = to_big_endian(value);
auto const bytes = std::bit_cast<std::array<std::byte, sizeof(serialize_value)> >(serialize_value);
data_.insert(data_.end(), bytes.begin(), bytes.end());
}
}
|
O0
|
c
|
void msgpack23::Packer<true>::emplace_integral<unsigned short>(unsigned short const&):
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x18(%rax)
popq %rbp
retq
nop
|
_ZN9msgpack236PackerILb1EE16emplace_integralITkSt8integralhEEvRKT_:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_8]
mov rcx, [rax+18h]
add rcx, 1
mov [rax+18h], rcx
pop rbp
retn
|
long long ZN9msgpack236PackerILb1EE16emplace_integralITkSt8integralhEEvRKT_(long long a1)
{
long long result; // rax
result = a1;
++*(_QWORD *)(a1 + 24);
return result;
}
|
_ZN9msgpack236PackerILb1EE16emplace_integralITkSt8integralhEEvRKT_:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x18]
ADD RCX,0x1
MOV qword ptr [RAX + 0x18],RCX
POP RBP
RET
|
void _ZN9msgpack236PackerILb1EE16emplace_integralITkSt8integralhEEvRKT_(long param_1)
{
*(long *)(param_1 + 0x18) = *(long *)(param_1 + 0x18) + 1;
return;
}
|
|
9,995 |
ggml_is_contiguous_n
|
ngxson[P]ggml-easy/ggml/src/ggml.c
|
static bool ggml_is_contiguous_n(const struct ggml_tensor * tensor, int n) {
size_t next_nb = ggml_type_size(tensor->type);
if (tensor->ne[0] != ggml_blck_size(tensor->type) && tensor->nb[0] != next_nb) {
return false;
}
next_nb *= tensor->ne[0]/ggml_blck_size(tensor->type);
for (int i = 1; i < GGML_MAX_DIMS; i++) {
if (tensor->ne[i] != 1) {
if (i > n) {
if (tensor->nb[i] != next_nb) {
return false;
}
next_nb *= tensor->ne[i];
} else {
// this dimension does not need to be contiguous
next_nb = tensor->ne[i]*tensor->nb[i];
}
}
}
return true;
}
|
O1
|
c
|
ggml_is_contiguous_n:
movl (%rdi), %eax
imulq $0x38, %rax, %rax
leaq 0x4f5c4(%rip), %rcx # 0x68dc0
movq 0x8(%rax,%rcx), %r8
movq 0x18(%rax,%rcx), %rcx
movq 0x10(%rdi), %rax
cmpq %r8, %rax
je 0x19815
cmpq %rcx, 0x30(%rdi)
jne 0x1985c
cqto
idivq %r8
imulq %rcx, %rax
movslq %esi, %rdx
xorl %esi, %esi
xorl %ecx, %ecx
movq %rsi, %r9
incq %rsi
movq 0x18(%rdi,%r9,8), %r8
cmpq $0x1, %r8
je 0x19851
cmpq %rdx, %rsi
jle 0x19848
cmpq %rax, 0x38(%rdi,%r9,8)
jne 0x1985e
imulq %r8, %rax
jmp 0x19851
imulq 0x38(%rdi,%r9,8), %r8
movq %r8, %rax
cmpq $0x3, %rsi
setae %cl
jne 0x19825
jmp 0x1985e
xorl %ecx, %ecx
andb $0x1, %cl
movl %ecx, %eax
retq
|
ggml_is_contiguous_n:
mov eax, [rdi]
imul rax, 38h ; '8'
lea rcx, type_traits
mov r8, [rax+rcx+8]
mov rcx, [rax+rcx+18h]
mov rax, [rdi+10h]
cmp rax, r8
jz short loc_19815
cmp [rdi+30h], rcx
jnz short loc_1985C
loc_19815:
cqo
idiv r8
imul rax, rcx
movsxd rdx, esi
xor esi, esi
xor ecx, ecx
loc_19825:
mov r9, rsi
inc rsi
mov r8, [rdi+r9*8+18h]
cmp r8, 1
jz short loc_19851
cmp rsi, rdx
jle short loc_19848
cmp [rdi+r9*8+38h], rax
jnz short loc_1985E
imul rax, r8
jmp short loc_19851
loc_19848:
imul r8, [rdi+r9*8+38h]
mov rax, r8
loc_19851:
cmp rsi, 3
setnb cl
jnz short loc_19825
jmp short loc_1985E
loc_1985C:
xor ecx, ecx
loc_1985E:
and cl, 1
mov eax, ecx
retn
|
long long ggml_is_contiguous_n(unsigned int *a1, int a2)
{
long long v2; // rax
long long v3; // r8
char *v4; // rcx
long long v5; // rax
long long v6; // rax
signed long long v7; // rdx
unsigned long long v8; // rsi
unsigned int v9; // ecx
unsigned long long v10; // r9
long long v11; // r8
v2 = 7LL * *a1;
v3 = (long long)(&type_traits)[v2 + 1];
v4 = (&type_traits)[v2 + 3];
v5 = *((_QWORD *)a1 + 2);
if ( v5 == v3 || *((char **)a1 + 6) == v4 )
{
v6 = (_QWORD)v4 * (v5 / v3);
v7 = a2;
v8 = 0LL;
v9 = 0;
do
{
v10 = v8++;
v11 = *(_QWORD *)&a1[2 * v10 + 6];
if ( v11 != 1 )
{
if ( (long long)v8 <= v7 )
{
v6 = *(_QWORD *)&a1[2 * v10 + 14] * v11;
}
else
{
if ( *(_QWORD *)&a1[2 * v10 + 14] != v6 )
break;
v6 *= v11;
}
}
LOBYTE(v9) = v8 >= 3;
}
while ( v8 != 3 );
}
else
{
v9 = 0;
}
LOBYTE(v9) = v9 & 1;
return v9;
}
|
ggml_is_contiguous_n:
MOV EAX,dword ptr [RDI]
IMUL RAX,RAX,0x38
LEA RCX,[0x168dc0]
MOV R8,qword ptr [RAX + RCX*0x1 + 0x8]
MOV RCX,qword ptr [RAX + RCX*0x1 + 0x18]
MOV RAX,qword ptr [RDI + 0x10]
CMP RAX,R8
JZ 0x00119815
CMP qword ptr [RDI + 0x30],RCX
JNZ 0x0011985c
LAB_00119815:
CQO
IDIV R8
IMUL RAX,RCX
MOVSXD RDX,ESI
XOR ESI,ESI
XOR ECX,ECX
LAB_00119825:
MOV R9,RSI
INC RSI
MOV R8,qword ptr [RDI + R9*0x8 + 0x18]
CMP R8,0x1
JZ 0x00119851
CMP RSI,RDX
JLE 0x00119848
CMP qword ptr [RDI + R9*0x8 + 0x38],RAX
JNZ 0x0011985e
IMUL RAX,R8
JMP 0x00119851
LAB_00119848:
IMUL R8,qword ptr [RDI + R9*0x8 + 0x38]
MOV RAX,R8
LAB_00119851:
CMP RSI,0x3
SETNC CL
JNZ 0x00119825
JMP 0x0011985e
LAB_0011985c:
XOR ECX,ECX
LAB_0011985e:
AND CL,0x1
MOV EAX,ECX
RET
|
bool ggml_is_contiguous_n(uint *param_1,int param_2)
{
long lVar1;
long lVar2;
ulong uVar3;
ulong uVar4;
bool bVar5;
if ((*(long *)(param_1 + 4) == *(long *)(type_traits + (ulong)*param_1 * 0x38 + 8)) ||
(*(long *)(param_1 + 0xc) == *(long *)(type_traits + (ulong)*param_1 * 0x38 + 0x18))) {
lVar2 = (*(long *)(param_1 + 4) / *(long *)(type_traits + (ulong)*param_1 * 0x38 + 8)) *
*(long *)(type_traits + (ulong)*param_1 * 0x38 + 0x18);
bVar5 = false;
uVar3 = 0;
do {
uVar4 = uVar3 + 1;
lVar1 = *(long *)(param_1 + uVar3 * 2 + 6);
if (lVar1 != 1) {
if ((long)param_2 < (long)uVar4) {
if (*(long *)(param_1 + uVar3 * 2 + 0xe) != lVar2) {
return bVar5;
}
lVar2 = lVar2 * lVar1;
}
else {
lVar2 = lVar1 * *(long *)(param_1 + uVar3 * 2 + 0xe);
}
}
bVar5 = 2 < uVar4;
uVar3 = uVar4;
} while (uVar4 != 3);
}
else {
bVar5 = false;
}
return bVar5;
}
|
|
9,996 |
my_convert
|
eloqsql/strings/ctype.c
|
uint32
my_convert(char *to, uint32 to_length, CHARSET_INFO *to_cs,
const char *from, uint32 from_length,
CHARSET_INFO *from_cs, uint *errors)
{
uint32 length, length2;
/*
If any of the character sets is not ASCII compatible,
immediately switch to slow mb_wc->wc_mb method.
*/
if ((to_cs->state | from_cs->state) & MY_CS_NONASCII)
return my_convert_using_func(to, to_length,
to_cs, to_cs->cset->wc_mb,
from, from_length,
from_cs, from_cs->cset->mb_wc,
errors);
length= length2= MY_MIN(to_length, from_length);
#if defined(__i386__) || defined(__x86_64__)
/*
Special loop for i386, it allows to refer to a
non-aligned memory block as UINT32, which makes
it possible to copy four bytes at once. This
gives about 10% performance improvement comparing
to byte-by-byte loop.
*/
for ( ; length >= 4; length-= 4, from+= 4, to+= 4)
{
if ((*(uint32*)from) & 0x80808080)
break;
*((uint32*) to)= *((const uint32*) from);
}
#endif /* __i386__ */
for (; ; *to++= *from++, length--)
{
if (!length)
{
*errors= 0;
return length2;
}
if (*((unsigned char*) from) > 0x7F) /* A non-ASCII character */
{
uint32 copied_length= length2 - length;
to_length-= copied_length;
from_length-= copied_length;
return copied_length + my_convert_using_func(to, to_length, to_cs,
to_cs->cset->wc_mb,
from, from_length, from_cs,
from_cs->cset->mb_wc,
errors);
}
}
DBUG_ASSERT(FALSE); // Should never get to here
return 0; // Make compiler happy
}
|
O3
|
c
|
my_convert:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %r9, %rax
movl %r8d, %r9d
movq %rcx, %r8
movq 0x10(%rbp), %r10
movl 0xc(%rax), %ecx
orl 0xc(%rdx), %ecx
btl $0xd, %ecx
jb 0xd1ec4
cmpl %r9d, %esi
movl %r9d, %ebx
cmovbl %esi, %ebx
movl %ebx, %ecx
cmpl $0x4, %ebx
jb 0xd1e9d
movl (%r8), %r11d
testl $0x80808080, %r11d # imm = 0x80808080
jne 0xd1ea1
movl %r11d, (%rdi)
addl $-0x4, %ecx
addq $0x4, %r8
addq $0x4, %rdi
cmpl $0x3, %ecx
ja 0xd1e7e
testl %ecx, %ecx
je 0xd1ebb
movl %ecx, %r14d
xorl %r15d, %r15d
movb (%r8,%r15), %cl
testb %cl, %cl
js 0xd1ef1
movb %cl, (%rdi,%r15)
incq %r15
cmpl %r15d, %r14d
jne 0xd1ea7
movl $0x0, (%r10)
jmp 0xd1f36
movl %esi, %esi
movq 0xb8(%rdx), %rcx
movq 0x30(%rcx), %rcx
movl %r9d, %r9d
movq 0xb8(%rax), %r11
subq $0x8, %rsp
pushq %r10
pushq 0x28(%r11)
pushq %rax
callq 0xd1d53
addq $0x28, %rsp
jmp 0xd1f3c
addl %r14d, %esi
subl %ebx, %esi
subl %r15d, %esi
addl %r14d, %r9d
subl %ebx, %r9d
subl %r15d, %r9d
movq 0xb8(%rdx), %rcx
movq 0x30(%rcx), %rcx
movq 0xb8(%rax), %r11
addq %r15, %rdi
addq %r15, %r8
subq $0x8, %rsp
pushq %r10
pushq 0x28(%r11)
pushq %rax
callq 0xd1d53
addq $0x20, %rsp
subl %r14d, %ebx
addl %r15d, %ebx
addl %eax, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
|
my_convert:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov rax, r9
mov r9d, r8d
mov r8, rcx
mov r10, [rbp+arg_0]
mov ecx, [rax+0Ch]
or ecx, [rdx+0Ch]
bt ecx, 0Dh
jb short loc_D1EC4
cmp esi, r9d
mov ebx, r9d
cmovb ebx, esi
mov ecx, ebx
cmp ebx, 4
jb short loc_D1E9D
loc_D1E7E:
mov r11d, [r8]
test r11d, 80808080h
jnz short loc_D1EA1
mov [rdi], r11d
add ecx, 0FFFFFFFCh
add r8, 4
add rdi, 4
cmp ecx, 3
ja short loc_D1E7E
loc_D1E9D:
test ecx, ecx
jz short loc_D1EBB
loc_D1EA1:
mov r14d, ecx
xor r15d, r15d
loc_D1EA7:
mov cl, [r8+r15]
test cl, cl
js short loc_D1EF1
mov [rdi+r15], cl
inc r15
cmp r14d, r15d
jnz short loc_D1EA7
loc_D1EBB:
mov dword ptr [r10], 0
jmp short loc_D1F36
loc_D1EC4:
mov esi, esi
mov rcx, [rdx+0B8h]
mov rcx, [rcx+30h]
mov r9d, r9d
mov r11, [rax+0B8h]
sub rsp, 8
push r10
push qword ptr [r11+28h]
push rax
call my_convert_using_func
add rsp, 28h
jmp short loc_D1F3C
loc_D1EF1:
add esi, r14d
sub esi, ebx
sub esi, r15d
add r9d, r14d
sub r9d, ebx
sub r9d, r15d
mov rcx, [rdx+0B8h]
mov rcx, [rcx+30h]
mov r11, [rax+0B8h]
add rdi, r15
add r8, r15
sub rsp, 8
push r10
push qword ptr [r11+28h]
push rax
call my_convert_using_func
add rsp, 20h
sub ebx, r14d
add ebx, r15d
add ebx, eax
loc_D1F36:
mov eax, ebx
add rsp, 8
loc_D1F3C:
pop rbx
pop r14
pop r15
pop rbp
retn
|
long long my_convert(
_DWORD *a1,
unsigned int a2,
long long a3,
long long a4,
unsigned int a5,
long long a6,
_DWORD *a7)
{
_DWORD *v9; // r8
unsigned int v10; // ebx
unsigned int v11; // ecx
unsigned int v12; // r14d
long long v13; // r15
char v14; // cl
v9 = (_DWORD *)a4;
if ( ((*(_DWORD *)(a3 + 12) | *(_DWORD *)(a6 + 12)) & 0x2000) != 0 )
return my_convert_using_func(
(long long)a1,
a2,
a3,
*(long long ( **)(long long, long long, long long, long long))(*(_QWORD *)(a3 + 184) + 48LL),
a4,
a5,
a6,
*(long long ( **)(long long, long long *, long long, unsigned long long))(*(_QWORD *)(a6 + 184) + 40LL),
a7);
v10 = a5;
if ( a2 < a5 )
v10 = a2;
v11 = v10;
if ( v10 >= 4 )
{
while ( (*v9 & 0x80808080) == 0 )
{
*a1 = *v9;
v11 -= 4;
++v9;
++a1;
if ( v11 <= 3 )
goto LABEL_7;
}
goto LABEL_8;
}
LABEL_7:
if ( v11 )
{
LABEL_8:
v12 = v11;
v13 = 0LL;
do
{
v14 = *((_BYTE *)v9 + v13);
if ( v14 < 0 )
return (unsigned int)my_convert_using_func(
(long long)a1 + v13,
v12 + a2 - v10 - (unsigned int)v13,
a3,
*(long long ( **)(long long, long long, long long, long long))(*(_QWORD *)(a3 + 184)
+ 48LL),
(long long)v9 + v13,
v12 + a5 - v10 - (unsigned int)v13,
a6,
*(long long ( **)(long long, long long *, long long, unsigned long long))(*(_QWORD *)(a6 + 184) + 40LL),
a7)
+ (_DWORD)v13
+ v10
- v12;
*((_BYTE *)a1 + v13++) = v14;
}
while ( v12 != (_DWORD)v13 );
}
*a7 = 0;
return v10;
}
|
my_convert:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV RAX,R9
MOV R9D,R8D
MOV R8,RCX
MOV R10,qword ptr [RBP + 0x10]
MOV ECX,dword ptr [RAX + 0xc]
OR ECX,dword ptr [RDX + 0xc]
BT ECX,0xd
JC 0x001d1ec4
CMP ESI,R9D
MOV EBX,R9D
CMOVC EBX,ESI
MOV ECX,EBX
CMP EBX,0x4
JC 0x001d1e9d
LAB_001d1e7e:
MOV R11D,dword ptr [R8]
TEST R11D,0x80808080
JNZ 0x001d1ea1
MOV dword ptr [RDI],R11D
ADD ECX,-0x4
ADD R8,0x4
ADD RDI,0x4
CMP ECX,0x3
JA 0x001d1e7e
LAB_001d1e9d:
TEST ECX,ECX
JZ 0x001d1ebb
LAB_001d1ea1:
MOV R14D,ECX
XOR R15D,R15D
LAB_001d1ea7:
MOV CL,byte ptr [R8 + R15*0x1]
TEST CL,CL
JS 0x001d1ef1
MOV byte ptr [RDI + R15*0x1],CL
INC R15
CMP R14D,R15D
JNZ 0x001d1ea7
LAB_001d1ebb:
MOV dword ptr [R10],0x0
JMP 0x001d1f36
LAB_001d1ec4:
MOV ESI,ESI
MOV RCX,qword ptr [RDX + 0xb8]
MOV RCX,qword ptr [RCX + 0x30]
MOV R9D,R9D
MOV R11,qword ptr [RAX + 0xb8]
SUB RSP,0x8
PUSH R10
PUSH qword ptr [R11 + 0x28]
PUSH RAX
CALL 0x001d1d53
ADD RSP,0x28
JMP 0x001d1f3c
LAB_001d1ef1:
ADD ESI,R14D
SUB ESI,EBX
SUB ESI,R15D
ADD R9D,R14D
SUB R9D,EBX
SUB R9D,R15D
MOV RCX,qword ptr [RDX + 0xb8]
MOV RCX,qword ptr [RCX + 0x30]
MOV R11,qword ptr [RAX + 0xb8]
ADD RDI,R15
ADD R8,R15
SUB RSP,0x8
PUSH R10
PUSH qword ptr [R11 + 0x28]
PUSH RAX
CALL 0x001d1d53
ADD RSP,0x20
SUB EBX,R14D
ADD EBX,R15D
ADD EBX,EAX
LAB_001d1f36:
MOV EAX,EBX
ADD RSP,0x8
LAB_001d1f3c:
POP RBX
POP R14
POP R15
POP RBP
RET
|
ulong my_convert(uint *param_1,uint param_2,long param_3,uint *param_4,uint param_5,long param_6,
int4 *param_7)
{
int iVar1;
ulong uVar2;
uint uVar3;
uint uVar5;
int iVar6;
long lVar7;
ulong uVar4;
uVar2 = (ulong)param_5;
if (((*(uint *)(param_6 + 0xc) | *(uint *)(param_3 + 0xc)) >> 0xd & 1) == 0) {
if (param_2 < param_5) {
uVar2 = (ulong)param_2;
}
uVar5 = (uint)uVar2;
uVar3 = uVar5;
uVar4 = uVar2;
while (3 < uVar3) {
uVar3 = (uint)uVar4;
if ((*param_4 & 0x80808080) != 0) goto LAB_001d1ea1;
*param_1 = *param_4;
uVar3 = uVar3 - 4;
uVar4 = (ulong)uVar3;
param_4 = param_4 + 1;
param_1 = param_1 + 1;
}
if (uVar3 != 0) {
LAB_001d1ea1:
lVar7 = 0;
do {
if (*(char *)((long)param_4 + lVar7) < '\0') {
iVar6 = (int)lVar7;
iVar1 = my_convert_using_func
((long)param_1 + lVar7,((param_2 + uVar3) - uVar5) - iVar6,param_3,
*(int8 *)(*(long *)(param_3 + 0xb8) + 0x30),(long)param_4 + lVar7
,((param_5 + uVar3) - uVar5) - iVar6,param_6,
*(int8 *)(*(long *)(param_6 + 0xb8) + 0x28),param_7);
return (ulong)((uVar5 - uVar3) + iVar6 + iVar1);
}
*(char *)((long)param_1 + lVar7) = *(char *)((long)param_4 + lVar7);
lVar7 = lVar7 + 1;
} while (uVar3 != (uint)lVar7);
}
*param_7 = 0;
}
else {
uVar2 = my_convert_using_func
(param_1,param_2,param_3,*(int8 *)(*(long *)(param_3 + 0xb8) + 0x30),
param_4,uVar2,param_6,*(int8 *)(*(long *)(param_6 + 0xb8) + 0x28),
param_7);
}
return uVar2;
}
|
|
9,997 |
my_error_unregister
|
eloqsql/mysys/my_error.c
|
my_bool my_error_unregister(uint first, uint last)
{
struct my_err_head *meh_p;
struct my_err_head **search_meh_pp;
/* Search for the registration in the list. */
for (search_meh_pp= &my_errmsgs_list;
*search_meh_pp;
search_meh_pp= &(*search_meh_pp)->meh_next)
{
if (((*search_meh_pp)->meh_first == first) &&
((*search_meh_pp)->meh_last == last))
break;
}
if (! *search_meh_pp)
return TRUE;
/* Remove header from the chain. */
meh_p= *search_meh_pp;
*search_meh_pp= meh_p->meh_next;
my_free(meh_p);
return FALSE;
}
|
O3
|
c
|
my_error_unregister:
movq 0x2c5541(%rip), %r8 # 0x2f6d08
movb $0x1, %al
testq %r8, %r8
je 0x31805
pushq %rbp
movq %rsp, %rbp
leaq 0x2c552f(%rip), %rdx # 0x2f6d08
movq %r8, %rcx
cmpl %edi, 0x10(%r8)
jne 0x317e7
cmpl %esi, 0x14(%rcx)
je 0x317f4
movq (%rcx), %r8
movq %rcx, %rdx
testq %r8, %r8
jne 0x317d9
jmp 0x31804
movq (%rcx), %rax
movq %rax, (%rdx)
movq %rcx, %rdi
callq 0x2bd7e
xorl %eax, %eax
popq %rbp
retq
|
my_error_unregister:
mov r8, cs:my_errmsgs_list
mov al, 1
test r8, r8
jz short locret_31805
push rbp
mov rbp, rsp
lea rdx, my_errmsgs_list
loc_317D9:
mov rcx, r8
cmp [r8+10h], edi
jnz short loc_317E7
cmp [rcx+14h], esi
jz short loc_317F4
loc_317E7:
mov r8, [rcx]
mov rdx, rcx
test r8, r8
jnz short loc_317D9
jmp short loc_31804
loc_317F4:
mov rax, [rcx]
mov [rdx], rax
mov rdi, rcx
call my_free
xor eax, eax
loc_31804:
pop rbp
locret_31805:
retn
|
char my_error_unregister(int a1, int a2)
{
long long *v2; // r8
char result; // al
long long **v4; // rdx
long long *v5; // rcx
v2 = my_errmsgs_list;
result = 1;
if ( my_errmsgs_list )
{
v4 = &my_errmsgs_list;
while ( 1 )
{
v5 = v2;
if ( *((_DWORD *)v2 + 4) == a1 && *((_DWORD *)v2 + 5) == a2 )
break;
v2 = (long long *)*v2;
v4 = (long long **)v5;
if ( !*v5 )
return result;
}
*v4 = (long long *)*v2;
my_free((long long)v2);
return 0;
}
return result;
}
|
my_error_unregister:
MOV R8,qword ptr [0x003f6d08]
MOV AL,0x1
TEST R8,R8
JZ 0x00131805
PUSH RBP
MOV RBP,RSP
LEA RDX,[0x3f6d08]
LAB_001317d9:
MOV RCX,R8
CMP dword ptr [R8 + 0x10],EDI
JNZ 0x001317e7
CMP dword ptr [RCX + 0x14],ESI
JZ 0x001317f4
LAB_001317e7:
MOV R8,qword ptr [RCX]
MOV RDX,RCX
TEST R8,R8
JNZ 0x001317d9
JMP 0x00131804
LAB_001317f4:
MOV RAX,qword ptr [RCX]
MOV qword ptr [RDX],RAX
MOV RDI,RCX
CALL 0x0012bd7e
XOR EAX,EAX
LAB_00131804:
POP RBP
LAB_00131805:
RET
|
int8 my_error_unregister(int param_1,int param_2)
{
int **ppuVar1;
int **ppuVar2;
int **ppuVar3;
if (my_errmsgs_list != (int *)0x0) {
ppuVar2 = &my_errmsgs_list;
ppuVar3 = (int **)my_errmsgs_list;
do {
if ((*(int *)(ppuVar3 + 2) == param_1) && (*(int *)((long)ppuVar3 + 0x14) == param_2)) {
*ppuVar2 = *ppuVar3;
my_free(ppuVar3);
return 0;
}
ppuVar1 = (int **)*ppuVar3;
ppuVar2 = ppuVar3;
ppuVar3 = ppuVar1;
} while (ppuVar1 != (int **)0x0);
}
return 1;
}
|
|
9,998 |
get_timer_raw_value_and_function(enum_timer_name, unsigned long long (**)())
|
eloqsql/storage/perfschema/pfs_timer.cc
|
ulonglong get_timer_raw_value_and_function(enum_timer_name timer_name, timer_fct_t *fct)
{
switch (timer_name)
{
case TIMER_NAME_CYCLE:
*fct= my_timer_cycles;
return my_timer_cycles();
case TIMER_NAME_NANOSEC:
*fct= my_timer_nanoseconds;
return my_timer_nanoseconds();
case TIMER_NAME_MICROSEC:
*fct= my_timer_microseconds;
return my_timer_microseconds();
case TIMER_NAME_MILLISEC:
*fct= my_timer_milliseconds;
return my_timer_milliseconds();
case TIMER_NAME_TICK:
*fct= my_timer_ticks;
return my_timer_ticks();
default:
*fct= NULL;
assert(false);
}
return 0;
}
|
O3
|
cpp
|
get_timer_raw_value_and_function(enum_timer_name, unsigned long long (**)()):
pushq %rbp
movq %rsp, %rbp
decl %edi
cmpl $0x4, %edi
ja 0x3a7ff
leaq 0x46757(%rip), %rax # 0x80ef8
movslq (%rax,%rdi,4), %rcx
addq %rax, %rcx
jmpq *%rcx
leaq -0x73(%rip), %rax # 0x3a73e
movq %rax, (%rsi)
rdtsc
shlq $0x20, %rdx
orq %rdx, %rax
jmp 0x3a808
leaq 0xcd93(%rip), %rax # 0x47559
movq %rax, (%rsi)
popq %rbp
jmp 0x47559
leaq 0xcd07(%rip), %rax # 0x474dd
movq %rax, (%rsi)
popq %rbp
jmp 0x474dd
leaq 0xcd33(%rip), %rax # 0x47519
movq %rax, (%rsi)
popq %rbp
jmp 0x47519
leaq 0xccbe(%rip), %rax # 0x474b4
movq %rax, (%rsi)
popq %rbp
jmp 0x474b4
movq $0x0, (%rsi)
xorl %eax, %eax
popq %rbp
retq
|
_Z32get_timer_raw_value_and_function15enum_timer_namePPFyvE:
push rbp
mov rbp, rsp
dec edi; switch 5 cases
cmp edi, 4
ja short def_3A7A8; jumptable 000000000003A7A8 default case
lea rax, jpt_3A7A8
movsxd rcx, ds:(jpt_3A7A8 - 80EF8h)[rax+rdi*4]
add rcx, rax
jmp rcx; switch jump
loc_3A7AA:
lea rax, _ZL15my_timer_cyclesv; jumptable 000000000003A7A8 case 1
mov [rsi], rax
rdtsc
shl rdx, 20h
or rax, rdx
jmp short loc_3A808
loc_3A7BF:
lea rax, my_timer_ticks; jumptable 000000000003A7A8 case 5
mov [rsi], rax
pop rbp
jmp my_timer_ticks
loc_3A7CF:
lea rax, my_timer_microseconds; jumptable 000000000003A7A8 case 3
mov [rsi], rax
pop rbp
jmp my_timer_microseconds
loc_3A7DF:
lea rax, my_timer_milliseconds; jumptable 000000000003A7A8 case 4
mov [rsi], rax
pop rbp
jmp my_timer_milliseconds
loc_3A7EF:
lea rax, my_timer_nanoseconds; jumptable 000000000003A7A8 case 2
mov [rsi], rax
pop rbp
jmp my_timer_nanoseconds
def_3A7A8:
mov qword ptr [rsi], 0; jumptable 000000000003A7A8 default case
xor eax, eax
loc_3A808:
pop rbp
retn
|
long long get_timer_raw_value_and_function(int a1, unsigned long long (**a2)(void))
{
long long result; // rax
switch ( a1 )
{
case 1:
*a2 = my_timer_cycles;
result = __rdtsc();
break;
case 2:
*a2 = (unsigned long long (*)(void))my_timer_nanoseconds;
result = my_timer_nanoseconds();
break;
case 3:
*a2 = (unsigned long long (*)(void))my_timer_microseconds;
result = my_timer_microseconds();
break;
case 4:
*a2 = (unsigned long long (*)(void))my_timer_milliseconds;
result = my_timer_milliseconds();
break;
case 5:
*a2 = (unsigned long long (*)(void))my_timer_ticks;
result = my_timer_ticks();
break;
default:
*a2 = 0LL;
result = 0LL;
break;
}
return result;
}
|
get_timer_raw_value_and_function:
PUSH RBP
MOV RBP,RSP
DEC EDI
CMP EDI,0x4
JA 0x0013a7ff
LEA RAX,[0x180ef8]
MOVSXD RCX,dword ptr [RAX + RDI*0x4]
ADD RCX,RAX
switchD:
JMP RCX
caseD_1:
LEA RAX,[0x13a73e]
MOV qword ptr [RSI],RAX
RDTSC
SHL RDX,0x20
OR RAX,RDX
JMP 0x0013a808
caseD_5:
LEA RAX,[0x147559]
MOV qword ptr [RSI],RAX
POP RBP
JMP 0x00147559
caseD_3:
LEA RAX,[0x1474dd]
MOV qword ptr [RSI],RAX
POP RBP
JMP 0x001474dd
caseD_4:
LEA RAX,[0x147519]
MOV qword ptr [RSI],RAX
POP RBP
JMP 0x00147519
caseD_2:
LEA RAX,[0x1474b4]
MOV qword ptr [RSI],RAX
POP RBP
JMP 0x001474b4
default:
MOV qword ptr [RSI],0x0
XOR EAX,EAX
LAB_0013a808:
POP RBP
RET
|
/* get_timer_raw_value_and_function(enum_timer_name, unsigned long long (**)()) */
int8 get_timer_raw_value_and_function(int4 param_1,int8 *param_2)
{
int8 uVar1;
switch(param_1) {
case 1:
*param_2 = my_timer_cycles;
uVar1 = rdtsc();
break;
case 2:
*param_2 = my_timer_nanoseconds;
uVar1 = my_timer_nanoseconds();
return uVar1;
case 3:
*param_2 = my_timer_microseconds;
uVar1 = my_timer_microseconds();
return uVar1;
case 4:
*param_2 = my_timer_milliseconds;
uVar1 = my_timer_milliseconds();
return uVar1;
case 5:
*param_2 = my_timer_ticks;
uVar1 = my_timer_ticks();
return uVar1;
default:
*param_2 = 0;
uVar1 = 0;
}
return uVar1;
}
|
|
9,999 |
void nlohmann::json_abi_v3_11_3::detail::get_arithmetic_value<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, long, 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&, long&)
|
llama.cpp/common/json.hpp
|
void get_arithmetic_value(const BasicJsonType& j, ArithmeticType& val)
{
switch (static_cast<value_t>(j))
{
case value_t::number_unsigned:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_unsigned_t*>());
break;
}
case value_t::number_integer:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_integer_t*>());
break;
}
case value_t::number_float:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_float_t*>());
break;
}
case value_t::null:
case value_t::object:
case value_t::array:
case value_t::string:
case value_t::boolean:
case value_t::binary:
case value_t::discarded:
default:
JSON_THROW(type_error::create(302, concat("type must be number, but is ", j.type_name()), &j));
}
}
|
O3
|
cpp
|
void nlohmann::json_abi_v3_11_3::detail::get_arithmetic_value<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, long, 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&, long&):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %r14
movzbl (%rdi), %eax
cmpl $0x5, %eax
je 0xc250c
cmpl $0x7, %eax
je 0xc2512
cmpl $0x6, %eax
jne 0xc2524
movq 0x8(%r14), %rax
jmp 0xc2518
cvttsd2si 0x8(%r14), %rax
movq %rax, (%rsi)
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movl $0x20, %edi
callq 0x20620
movq %rax, %rbx
movq %r14, %rdi
callq 0x8af7c
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
leaq 0x5d679(%rip), %rsi # 0x11fbc1
leaq 0x10(%rsp), %rdi
callq 0x80a4c
movb $0x1, %bpl
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
movl $0x12e, %esi # imm = 0x12E
movq %r14, %rcx
callq 0xbc7d0
xorl %ebp, %ebp
leaq 0x9dacd(%rip), %rsi # 0x160040
leaq -0x4b5ea(%rip), %rdx # 0x76f90
movq %rbx, %rdi
callq 0x20a30
movq %rax, %r14
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc25a0
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x20170
testb %bpl, %bpl
jne 0xc25aa
jmp 0xc25b2
movq %rax, %r14
movq %rbx, %rdi
callq 0x20eb0
movq %r14, %rdi
callq 0x20ad0
|
_ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_:
push rbp; void *
push r14; int
push rbx; __int64
sub rsp, 30h
mov r14, rdi
movzx eax, byte ptr [rdi]
cmp eax, 5
jz short loc_C250C
cmp eax, 7
jz short loc_C2512
cmp eax, 6
jnz short loc_C2524
loc_C250C:
mov rax, [r14+8]
jmp short loc_C2518
loc_C2512:
cvttsd2si rax, qword ptr [r14+8]
loc_C2518:
mov [rsi], rax
add rsp, 30h
pop rbx
pop r14
pop rbp
retn
loc_C2524:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void)
lea rdx, [rsp+48h+var_40]
mov [rdx], rax
lea rsi, aTypeMustBeNumb; "type must be number, but is "
lea rdi, [rsp+48h+var_38]
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA29_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(char const(&)[29],char const* &&)
mov bpl, 1
lea rdx, [rsp+48h+var_38]
mov rdi, rbx; this
mov esi, 12Eh; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+48h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_C25A0
mov rsi, [rsp+48h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_C25A0:
test bpl, bpl
jnz short loc_C25AA
jmp short loc_C25B2
mov r14, rax
loc_C25AA:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_C25B2:
mov rdi, r14
call __Unwind_Resume
|
long long ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_(
double *a1,
_QWORD *a2)
{
int v2; // eax
long long result; // rax
nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx
const char *v5; // [rsp+8h] [rbp-40h] BYREF
_QWORD v6[2]; // [rsp+10h] [rbp-38h] BYREF
v2 = *(unsigned __int8 *)a1;
if ( v2 != 5 )
{
if ( v2 == 7 )
{
result = (unsigned int)(int)a1[1];
goto LABEL_6;
}
if ( v2 != 6 )
{
exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL);
v5 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name((unsigned __int8 *)a1);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(
(long long)v6,
(long long)"type must be number, but is ",
&v5);
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,
v6);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
}
result = *((_QWORD *)a1 + 1);
LABEL_6:
*a2 = result;
return result;
}
|
_ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV R14,RDI
MOVZX EAX,byte ptr [RDI]
CMP EAX,0x5
JZ 0x001c250c
CMP EAX,0x7
JZ 0x001c2512
CMP EAX,0x6
JNZ 0x001c2524
LAB_001c250c:
MOV RAX,qword ptr [R14 + 0x8]
JMP 0x001c2518
LAB_001c2512:
CVTTSD2SI RAX,qword ptr [R14 + 0x8]
LAB_001c2518:
MOV qword ptr [RSI],RAX
ADD RSP,0x30
POP RBX
POP R14
POP RBP
RET
LAB_001c2524:
MOV EDI,0x20
CALL 0x00120620
MOV RBX,RAX
MOV RDI,R14
CALL 0x0018af7c
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],RAX
LAB_001c2541:
LEA RSI,[0x21fbc1]
LEA RDI,[RSP + 0x10]
CALL 0x00180a4c
MOV BPL,0x1
LAB_001c2555:
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
MOV ESI,0x12e
MOV RCX,R14
CALL 0x001bc7d0
XOR EBP,EBP
LEA RSI,[0x260040]
LEA RDX,[0x176f90]
MOV RDI,RBX
CALL 0x00120a30
|
void _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*param_1,long *param_2)
{
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
bVar1;
long lVar2;
int8 uVar3;
char *local_40;
detail local_38 [32];
bVar1 = *param_1;
if (bVar1 != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x5) {
if (bVar1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x7) {
lVar2 = (long)*(double *)(param_1 + 8);
goto LAB_001c2518;
}
if (bVar1 != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x6) {
uVar3 = __cxa_allocate_exception(0x20);
local_40 = (char *)nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::type_name(param_1);
/* try { // try from 001c2541 to 001c2551 has its CatchHandler @ 001c25a7 */
nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[29],char_const*>
(local_38,"type must be number, but is ",&local_40);
/* try { // try from 001c2555 to 001c2581 has its CatchHandler @ 001c2582 */
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
(uVar3,0x12e,local_38,param_1);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar3,&nlohmann::json_abi_v3_11_3::detail::type_error::typeinfo,
nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
}
lVar2 = *(long *)(param_1 + 8);
LAB_001c2518:
*param_2 = lVar2;
return;
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.