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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
21,400 | JS_GetPropertyInt64 | bluesky950520[P]quickjs/quickjs.c | JSValue JS_GetPropertyInt64(JSContext *ctx, JSValue obj, int64_t idx)
{
JSAtom prop;
JSValue val;
if (likely(JS_VALUE_GET_TAG(obj) == JS_TAG_OBJECT &&
(uint64_t)idx <= INT32_MAX)) {
/* fast path for array and typed array access */
JSObject *p = JS_VALUE_GET_OBJ(obj);
if (js_get_fast_array_element(ctx, p, idx, &val))
return val;
}
prop = JS_NewAtomInt64(ctx, idx);
if (prop == JS_ATOM_NULL)
return JS_EXCEPTION;
val = JS_GetProperty(ctx, obj, prop);
JS_FreeAtom(ctx, prop);
return val;
} | O2 | c | JS_GetPropertyInt64:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r12
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movabsq $-0x100000000, %r13 # imm = 0xFFFFFFFF00000000
cmpl $-0x1, %r14d
jne 0x1e1ce
cmpq $0x7fffffff, %r12 # imm = 0x7FFFFFFF
ja 0x1e1ce
leaq 0x8(%rsp), %rcx
movq %rbx, %rdi
movq %r15, %rsi
movl %r12d, %edx
callq 0x1e226
testl %eax, %eax
je 0x1e1ce
movq 0x8(%rsp), %r15
movq 0x10(%rsp), %r14
jmp 0x1e1ff
movq %rbx, %rdi
movq %r12, %rsi
callq 0x1e3a6
testl %eax, %eax
je 0x1e21a
movl %eax, %ebp
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
movl %eax, %ecx
callq 0x1b043
movq %rax, %r15
movq %rdx, %r14
movq %rbx, %rdi
movl %ebp, %esi
callq 0x1a995
andq %r15, %r13
movl %r15d, %eax
orq %r13, %rax
movq %r14, %rdx
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
pushq $0x6
popq %r14
xorl %r15d, %r15d
xorl %r13d, %r13d
jmp 0x1e202
| JS_GetPropertyInt64:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov r12, rcx
mov r14, rdx
mov r15, rsi
mov rbx, rdi
mov r13, 0FFFFFFFF00000000h
cmp r14d, 0FFFFFFFFh
jnz short loc_1E1CE
cmp r12, 7FFFFFFFh
ja short loc_1E1CE
lea rcx, [rsp+48h+var_40]
mov rdi, rbx
mov rsi, r15
mov edx, r12d
call js_get_fast_array_element
test eax, eax
jz short loc_1E1CE
mov r15, [rsp+48h+var_40]
mov r14, [rsp+48h+var_38]
jmp short loc_1E1FF
loc_1E1CE:
mov rdi, rbx
mov rsi, r12
call JS_NewAtomInt64
test eax, eax
jz short loc_1E21A
mov ebp, eax
mov rdi, rbx
mov rsi, r15
mov rdx, r14
mov ecx, eax
call JS_GetProperty
mov r15, rax
mov r14, rdx
mov rdi, rbx
mov esi, ebp
call JS_FreeAtom
loc_1E1FF:
and r13, r15
loc_1E202:
mov eax, r15d
or rax, r13
mov rdx, r14
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_1E21A:
push 6
pop r14
xor r15d, r15d
xor r13d, r13d
jmp short loc_1E202
| unsigned long long JS_GetPropertyInt64(long long a1, long long a2, int a3, unsigned long long a4)
{
long long Property; // r15
int v7; // eax
int v8; // ebp
unsigned long long v9; // r13
long long v11; // [rsp+8h] [rbp-40h] BYREF
if ( a3 == -1 && a4 <= 0x7FFFFFFF && (unsigned int)js_get_fast_array_element(a1, a2, (unsigned int)a4, &v11) )
{
Property = v11;
}
else
{
v7 = JS_NewAtomInt64(a1, a4);
if ( !v7 )
{
LODWORD(Property) = 0;
v9 = 0LL;
return v9 | (unsigned int)Property;
}
v8 = v7;
Property = JS_GetProperty(a1, a2, a3, v7);
JS_FreeAtom(a1, v8);
}
v9 = Property & 0xFFFFFFFF00000000LL;
return v9 | (unsigned int)Property;
}
| JS_GetPropertyInt64:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV R12,RCX
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
MOV R13,-0x100000000
CMP R14D,-0x1
JNZ 0x0011e1ce
CMP R12,0x7fffffff
JA 0x0011e1ce
LEA RCX,[RSP + 0x8]
MOV RDI,RBX
MOV RSI,R15
MOV EDX,R12D
CALL 0x0011e226
TEST EAX,EAX
JZ 0x0011e1ce
MOV R15,qword ptr [RSP + 0x8]
MOV R14,qword ptr [RSP + 0x10]
JMP 0x0011e1ff
LAB_0011e1ce:
MOV RDI,RBX
MOV RSI,R12
CALL 0x0011e3a6
TEST EAX,EAX
JZ 0x0011e21a
MOV EBP,EAX
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R14
MOV ECX,EAX
CALL 0x0011b043
MOV R15,RAX
MOV R14,RDX
MOV RDI,RBX
MOV ESI,EBP
CALL 0x0011a995
LAB_0011e1ff:
AND R13,R15
LAB_0011e202:
MOV EAX,R15D
OR RAX,R13
MOV RDX,R14
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0011e21a:
PUSH 0x6
POP R14
XOR R15D,R15D
XOR R13D,R13D
JMP 0x0011e202
|
int1 [16]
JS_GetPropertyInt64(int8 param_1,int8 param_2,int8 param_3,ulong param_4)
{
int iVar1;
ulong uVar2;
int1 auVar3 [16];
int1 auVar4 [16];
ulong local_40;
int8 local_38;
if (((int)param_3 == -1) && (param_4 < 0x80000000)) {
iVar1 = js_get_fast_array_element(param_1,param_2,param_4 & 0xffffffff,&local_40);
auVar3._8_8_ = local_38;
auVar3._0_8_ = local_40;
if (iVar1 == 0) goto LAB_0011e1ce;
}
else {
LAB_0011e1ce:
iVar1 = JS_NewAtomInt64(param_1,param_4);
if (iVar1 == 0) {
auVar3 = ZEXT816(6) << 0x40;
uVar2 = 0;
goto LAB_0011e202;
}
auVar3 = JS_GetProperty(param_1,param_2,param_3,iVar1);
JS_FreeAtom(param_1,iVar1);
}
uVar2 = auVar3._0_8_ & 0xffffffff00000000;
LAB_0011e202:
auVar4._0_8_ = auVar3._0_8_ & 0xffffffff | uVar2;
auVar4._8_8_ = auVar3._8_8_;
return auVar4;
}
| |
21,401 | minja::Value::insert(unsigned long, minja::Value const&) | monkey531[P]llama/common/minja.hpp | void insert(size_t index, const Value& v) {
if (!array_)
throw std::runtime_error("Value is not an array: " + dump());
array_->insert(array_->begin() + index, v);
} | O2 | cpp | minja::Value::insert(unsigned long, minja::Value const&):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rdi, %r14
movq 0x10(%rdi), %rdi
testq %rdi, %rdi
je 0x6d30c
imulq $0x50, %rsi, %rsi
addq (%rdi), %rsi
addq $0x40, %rsp
popq %rbx
popq %r14
popq %rbp
jmp 0x6e3a0
pushq $0x10
popq %rdi
callq 0x24460
movq %rax, %rbx
movq %rsp, %rdi
pushq $-0x1
popq %rdx
movq %r14, %rsi
xorl %ecx, %ecx
callq 0x63320
leaq 0x48cb2(%rip), %rsi # 0xb5fe0
leaq 0x20(%rsp), %rdi
movq %rsp, %rdx
callq 0x58a46
movb $0x1, %bpl
leaq 0x20(%rsp), %rsi
movq %rbx, %rdi
callq 0x24e10
xorl %ebp, %ebp
movq 0x92c9c(%rip), %rsi # 0xffff0
movq 0x92bf5(%rip), %rdx # 0xfff50
movq %rbx, %rdi
callq 0x24ee0
movq %rax, %r14
leaq 0x20(%rsp), %rdi
callq 0x251b8
jmp 0x6d378
movq %rax, %r14
movb $0x1, %bpl
movq %rsp, %rdi
callq 0x251b8
testb %bpl, %bpl
jne 0x6d38a
jmp 0x6d392
movq %rax, %r14
movq %rbx, %rdi
callq 0x24670
movq %r14, %rdi
callq 0x24f60
| _ZN5minja5Value6insertEmRKS0_:
push rbp
push r14
push rbx
sub rsp, 40h
mov r14, rdi
mov rdi, [rdi+10h]
test rdi, rdi
jz short loc_6D30C
imul rsi, 50h ; 'P'
add rsi, [rdi]
add rsp, 40h
pop rbx
pop r14
pop rbp
jmp _ZNSt6vectorIN5minja5ValueESaIS1_EE6insertEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EERS6_; std::vector<minja::Value>::insert(__gnu_cxx::__normal_iterator<minja::Value const*,std::vector<minja::Value>>,minja::Value const&)
loc_6D30C:
push 10h
pop rdi; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, rsp
push 0FFFFFFFFFFFFFFFFh
pop rdx
mov rsi, r14
xor ecx, ecx
call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool)
lea rsi, aValueIsNotAnAr; "Value is not an array: "
lea rdi, [rsp+58h+var_38]
mov rdx, rsp
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&)
mov bpl, 1
lea rsi, [rsp+58h+var_38]
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+58h+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_6D378
mov r14, rax
mov bpl, 1
loc_6D378:
mov rdi, rsp; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
jnz short loc_6D38A
jmp short loc_6D392
mov r14, rax
loc_6D38A:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_6D392:
mov rdi, r14
call __Unwind_Resume
| long long minja::Value::insert(minja::Value *this, long long a2, const minja::Value *a3)
{
_QWORD *v4; // rdi
void *exception; // rbx
_BYTE v7[32]; // [rsp+0h] [rbp-58h] BYREF
_BYTE v8[56]; // [rsp+20h] [rbp-38h] BYREF
v4 = (_QWORD *)*((_QWORD *)this + 2);
if ( !v4 )
{
exception = __cxa_allocate_exception(0x10uLL);
minja::Value::dump[abi:cxx11]((long long)v7, (long long)this, 0xFFFFFFFF, 0);
std::operator+<char>((long long)v8, (long long)"Value is not an array: ", (long long)v7);
std::runtime_error::runtime_error(exception, v8);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
return std::vector<minja::Value>::insert(v4, *v4 + 80 * a2, a3);
}
| insert:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x40
MOV R14,RDI
MOV RDI,qword ptr [RDI + 0x10]
TEST RDI,RDI
JZ 0x0016d30c
IMUL RSI,RSI,0x50
ADD RSI,qword ptr [RDI]
ADD RSP,0x40
POP RBX
POP R14
POP RBP
JMP 0x0016e3a0
LAB_0016d30c:
PUSH 0x10
POP RDI
CALL 0x00124460
MOV RBX,RAX
LAB_0016d317:
MOV RDI,RSP
PUSH -0x1
POP RDX
MOV RSI,R14
XOR ECX,ECX
CALL 0x00163320
LAB_0016d327:
LEA RSI,[0x1b5fe0]
LEA RDI,[RSP + 0x20]
MOV RDX,RSP
CALL 0x00158a46
MOV BPL,0x1
LAB_0016d33e:
LEA RSI,[RSP + 0x20]
MOV RDI,RBX
CALL 0x00124e10
XOR EBP,EBP
MOV RSI,qword ptr [0x001ffff0]
MOV RDX,qword ptr [0x001fff50]
MOV RDI,RBX
CALL 0x00124ee0
|
/* minja::Value::insert(unsigned long, minja::Value const&) */
void minja::Value::insert(ulong param_1,Value *param_2)
{
vector<minja::Value,std::allocator<minja::Value>> *pvVar1;
runtime_error *this;
int1 auStack_58 [32];
string local_38 [32];
pvVar1 = *(vector<minja::Value,std::allocator<minja::Value>> **)(param_1 + 0x10);
if (pvVar1 != (vector<minja::Value,std::allocator<minja::Value>> *)0x0) {
std::vector<minja::Value,std::allocator<minja::Value>>::insert
(pvVar1,(long)param_2 * 0x50 + *(long *)pvVar1);
return;
}
this = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 0016d317 to 0016d326 has its CatchHandler @ 0016d387 */
dump_abi_cxx11_((int)auStack_58,SUB81(param_1,0));
/* try { // try from 0016d327 to 0016d33a has its CatchHandler @ 0016d372 */
std::operator+((char *)local_38,(string *)"Value is not an array: ");
/* try { // try from 0016d33e to 0016d362 has its CatchHandler @ 0016d363 */
std::runtime_error::runtime_error(this,local_38);
/* WARNING: Subroutine does not return */
__cxa_throw(this,PTR_typeinfo_001ffff0,PTR__runtime_error_001fff50);
}
| |
21,402 | init_dynamic_array2 | eloqsql/mysys/array.c | my_bool init_dynamic_array2(PSI_memory_key psi_key, DYNAMIC_ARRAY *array,
uint element_size, void *init_buffer,
uint init_alloc, uint alloc_increment, myf my_flags)
{
DBUG_ENTER("init_dynamic_array2");
if (!alloc_increment)
{
alloc_increment=MY_MAX((8192-MALLOC_OVERHEAD)/element_size,16);
if (init_alloc > 8 && alloc_increment > init_alloc * 2)
alloc_increment=init_alloc*2;
}
array->elements=0;
array->max_element=init_alloc;
array->alloc_increment=alloc_increment;
array->size_of_element=element_size;
array->m_psi_key= psi_key;
array->malloc_flags= my_flags;
DBUG_ASSERT((my_flags & MY_INIT_BUFFER_USED) == 0);
if ((array->buffer= init_buffer))
{
array->malloc_flags|= MY_INIT_BUFFER_USED;
DBUG_RETURN(FALSE);
}
/*
Since the dynamic array is usable even if allocation fails here malloc
should not throw an error
*/
if (init_alloc &&
!(array->buffer= (uchar*) my_malloc(psi_key, element_size*init_alloc,
MYF(my_flags))))
array->max_element=0;
DBUG_RETURN(FALSE);
} | O3 | c | init_dynamic_array2:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %edx, %r11d
movq %rsi, %rbx
movq 0x10(%rbp), %r10
testl %r9d, %r9d
jne 0x92dfb
movl $0x10, %r9d
cmpl $0x1e1, %r11d # imm = 0x1E1
ja 0x92dea
movw $0x1ff8, %ax # imm = 0x1FF8
xorl %edx, %edx
divw %r11w
movzwl %ax, %r9d
cmpl $0x9, %r8d
jb 0x92dfb
leal (%r8,%r8), %eax
cmpl %eax, %r9d
cmovael %eax, %r9d
movl $0x0, 0x8(%rbx)
movl %r8d, 0xc(%rbx)
movl %r9d, 0x10(%rbx)
movl %r11d, 0x14(%rbx)
movl %edi, 0x18(%rbx)
movq %r10, 0x20(%rbx)
movq %rcx, (%rbx)
testq %rcx, %rcx
je 0x92e31
orq $0x100, %r10 # imm = 0x100
movq %r10, 0x20(%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
testl %r8d, %r8d
je 0x92e28
imull %r11d, %r8d
movq %r8, %rsi
movq %r10, %rdx
callq 0xa11e5
movq %rax, (%rbx)
testq %rax, %rax
jne 0x92e28
movl $0x0, 0xc(%rbx)
jmp 0x92e28
| init_dynamic_array2:
push rbp
mov rbp, rsp
push rbx
push rax
mov r11d, edx
mov rbx, rsi
mov r10, [rbp+arg_0]
test r9d, r9d
jnz short loc_92DFB
mov r9d, 10h
cmp r11d, 1E1h
ja short loc_92DEA
mov ax, 1FF8h
xor edx, edx
div r11w
movzx r9d, ax
loc_92DEA:
cmp r8d, 9
jb short loc_92DFB
lea eax, [r8+r8]
cmp r9d, eax
cmovnb r9d, eax
loc_92DFB:
mov dword ptr [rbx+8], 0
mov [rbx+0Ch], r8d
mov [rbx+10h], r9d
mov [rbx+14h], r11d
mov [rbx+18h], edi
mov [rbx+20h], r10
mov [rbx], rcx
test rcx, rcx
jz short loc_92E31
or r10, 100h
mov [rbx+20h], r10
loc_92E28:
xor eax, eax
add rsp, 8
pop rbx
pop rbp
retn
loc_92E31:
test r8d, r8d
jz short loc_92E28
imul r8d, r11d
mov rsi, r8
mov rdx, r10
call my_malloc
mov [rbx], rax
test rax, rax
jnz short loc_92E28
mov dword ptr [rbx+0Ch], 0
jmp short loc_92E28
| long long init_dynamic_array2(
long long a1,
long long a2,
unsigned int a3,
long long a4,
unsigned int a5,
unsigned int a6,
long long a7)
{
long long v8; // rax
if ( !a6 )
{
a6 = 16;
if ( a3 <= 0x1E1 )
a6 = 0x1FF8u / (unsigned __int16)a3;
if ( a5 >= 9 && a6 >= 2 * a5 )
a6 = 2 * a5;
}
*(_DWORD *)(a2 + 8) = 0;
*(_DWORD *)(a2 + 12) = a5;
*(_DWORD *)(a2 + 16) = a6;
*(_DWORD *)(a2 + 20) = a3;
*(_DWORD *)(a2 + 24) = a1;
*(_QWORD *)(a2 + 32) = a7;
*(_QWORD *)a2 = a4;
if ( a4 )
{
*(_QWORD *)(a2 + 32) = a7 | 0x100;
}
else if ( a5 )
{
v8 = my_malloc(a1, a3 * a5, a7);
*(_QWORD *)a2 = v8;
if ( !v8 )
*(_DWORD *)(a2 + 12) = 0;
}
return 0LL;
}
| init_dynamic_array2:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV R11D,EDX
MOV RBX,RSI
MOV R10,qword ptr [RBP + 0x10]
TEST R9D,R9D
JNZ 0x00192dfb
MOV R9D,0x10
CMP R11D,0x1e1
JA 0x00192dea
MOV AX,0x1ff8
XOR EDX,EDX
DIV R11W
MOVZX R9D,AX
LAB_00192dea:
CMP R8D,0x9
JC 0x00192dfb
LEA EAX,[R8 + R8*0x1]
CMP R9D,EAX
CMOVNC R9D,EAX
LAB_00192dfb:
MOV dword ptr [RBX + 0x8],0x0
MOV dword ptr [RBX + 0xc],R8D
MOV dword ptr [RBX + 0x10],R9D
MOV dword ptr [RBX + 0x14],R11D
MOV dword ptr [RBX + 0x18],EDI
MOV qword ptr [RBX + 0x20],R10
MOV qword ptr [RBX],RCX
TEST RCX,RCX
JZ 0x00192e31
OR R10,0x100
MOV qword ptr [RBX + 0x20],R10
LAB_00192e28:
XOR EAX,EAX
ADD RSP,0x8
POP RBX
POP RBP
RET
LAB_00192e31:
TEST R8D,R8D
JZ 0x00192e28
IMUL R8D,R11D
MOV RSI,R8
MOV RDX,R10
CALL 0x001a11e5
MOV qword ptr [RBX],RAX
TEST RAX,RAX
JNZ 0x00192e28
MOV dword ptr [RBX + 0xc],0x0
JMP 0x00192e28
|
int8
init_dynamic_array2(int4 param_1,long *param_2,uint param_3,long param_4,uint param_5,
uint param_6,ulong param_7)
{
long lVar1;
if (param_6 == 0) {
param_6 = 0x10;
if (param_3 < 0x1e2) {
param_6 = 0x1ff8 / (param_3 & 0xffff);
}
if ((8 < param_5) && (param_5 * 2 <= param_6)) {
param_6 = param_5 * 2;
}
}
*(int4 *)(param_2 + 1) = 0;
*(uint *)((long)param_2 + 0xc) = param_5;
*(uint *)(param_2 + 2) = param_6;
*(uint *)((long)param_2 + 0x14) = param_3;
*(int4 *)(param_2 + 3) = param_1;
param_2[4] = param_7;
*param_2 = param_4;
if (param_4 == 0) {
if (param_5 != 0) {
lVar1 = my_malloc(param_1,param_5 * param_3,param_7);
*param_2 = lVar1;
if (lVar1 == 0) {
*(int4 *)((long)param_2 + 0xc) = 0;
}
}
}
else {
param_2[4] = param_7 | 0x100;
}
return 0;
}
| |
21,403 | nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__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>>>>>::lexer(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>>>>&&, bool) | monkey531[P]llama/common/./json.hpp | explicit lexer(InputAdapterType&& adapter, bool ignore_comments_ = false) noexcept
: ia(std::move(adapter))
, ignore_comments(ignore_comments_)
, decimal_point_char(static_cast<char_int_type>(get_decimal_point()))
{} | O0 | cpp | nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__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>>>>>::lexer(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>>>>&&, bool):
subq $0x28, %rsp
movb %dl, %al
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
andb $0x1, %al
movb %al, 0x17(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rcx
movq (%rcx), %rdx
movq %rdx, (%rax)
movq 0x8(%rcx), %rcx
movq %rcx, 0x8(%rax)
movb 0x17(%rsp), %cl
andb $0x1, %cl
movb %cl, 0x10(%rax)
callq 0xaf170
movq 0x8(%rsp), %rdi
movl %eax, 0x14(%rdi)
movb $0x0, 0x18(%rdi)
movq $0x0, 0x20(%rdi)
movq $0x0, 0x28(%rdi)
movq $0x0, 0x30(%rdi)
addq $0x38, %rdi
movq %rdi, (%rsp)
xorl %esi, %esi
movl $0x18, %edx
callq 0x50430
movq (%rsp), %rdi
callq 0x87050
movq 0x8(%rsp), %rdi
addq $0x50, %rdi
callq 0x504a0
movq 0x8(%rsp), %rax
leaq 0x11bf83(%rip), %rcx # 0x1cb050
movq %rcx, 0x70(%rax)
movq $0x0, 0x78(%rax)
movq $0x0, 0x80(%rax)
xorps %xmm0, %xmm0
movsd %xmm0, 0x88(%rax)
callq 0xaf180
movb %al, %cl
movq 0x8(%rsp), %rax
movsbl %cl, %ecx
movl %ecx, 0x90(%rax)
addq $0x28, %rsp
retq
nopl (%rax)
| _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEEC2EOSM_b:
sub rsp, 28h
mov al, dl
mov [rsp+28h+var_8], rdi
mov [rsp+28h+var_10], rsi
and al, 1
mov [rsp+28h+var_11], al
mov rax, [rsp+28h+var_8]
mov [rsp+28h+var_20], rax
mov rcx, [rsp+28h+var_10]
mov rdx, [rcx]
mov [rax], rdx
mov rcx, [rcx+8]
mov [rax+8], rcx
mov cl, [rsp+28h+var_11]
and cl, 1
mov [rax+10h], cl
call _ZNSt11char_traitsIcE3eofEv; std::char_traits<char>::eof(void)
mov rdi, [rsp+28h+var_20]
mov [rdi+14h], eax
mov byte ptr [rdi+18h], 0
mov qword ptr [rdi+20h], 0
mov qword ptr [rdi+28h], 0
mov qword ptr [rdi+30h], 0
add rdi, 38h ; '8'
mov [rsp+28h+var_28], rdi
xor esi, esi
mov edx, 18h
call _memset
mov rdi, [rsp+28h+var_28]
call _ZNSt6vectorIcSaIcEEC2Ev; std::vector<char>::vector(void)
mov rdi, [rsp+28h+var_20]
add rdi, 50h ; 'P'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev; std::string::basic_string(void)
mov rax, [rsp+28h+var_20]
lea rcx, aSJinja+16h; ""
mov [rax+70h], rcx
mov qword ptr [rax+78h], 0
mov qword ptr [rax+80h], 0
xorps xmm0, xmm0
movsd qword ptr [rax+88h], xmm0
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE17get_decimal_pointEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get_decimal_point(void)
mov cl, al
mov rax, [rsp+28h+var_20]
movsx ecx, cl
mov [rax+90h], ecx
add rsp, 28h
retn
| long long nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::lexer(
long long a1,
_QWORD *a2,
char a3)
{
char decimal_point; // cl
long long result; // rax
*(_QWORD *)a1 = *a2;
*(_QWORD *)(a1 + 8) = a2[1];
*(_BYTE *)(a1 + 16) = a3 & 1;
*(_DWORD *)(a1 + 20) = std::char_traits<char>::eof();
*(_BYTE *)(a1 + 24) = 0;
*(_QWORD *)(a1 + 32) = 0LL;
*(_QWORD *)(a1 + 40) = 0LL;
*(_QWORD *)(a1 + 48) = 0LL;
memset(a1 + 56, 0LL, 24LL);
std::vector<char>::vector(a1 + 56);
std::string::basic_string(a1 + 80);
*(_QWORD *)(a1 + 112) = "";
*(_QWORD *)(a1 + 120) = 0LL;
*(_QWORD *)(a1 + 128) = 0LL;
*(_QWORD *)(a1 + 136) = 0LL;
decimal_point = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get_decimal_point();
result = a1;
*(_DWORD *)(a1 + 144) = decimal_point;
return result;
}
| lexer:
SUB RSP,0x28
MOV AL,DL
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x18],RSI
AND AL,0x1
MOV byte ptr [RSP + 0x17],AL
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RSP + 0x8],RAX
MOV RCX,qword ptr [RSP + 0x18]
MOV RDX,qword ptr [RCX]
MOV qword ptr [RAX],RDX
MOV RCX,qword ptr [RCX + 0x8]
MOV qword ptr [RAX + 0x8],RCX
MOV CL,byte ptr [RSP + 0x17]
AND CL,0x1
MOV byte ptr [RAX + 0x10],CL
CALL 0x001af170
MOV RDI,qword ptr [RSP + 0x8]
MOV dword ptr [RDI + 0x14],EAX
MOV byte ptr [RDI + 0x18],0x0
MOV qword ptr [RDI + 0x20],0x0
MOV qword ptr [RDI + 0x28],0x0
MOV qword ptr [RDI + 0x30],0x0
ADD RDI,0x38
MOV qword ptr [RSP],RDI
XOR ESI,ESI
MOV EDX,0x18
CALL 0x00150430
MOV RDI,qword ptr [RSP]
CALL 0x00187050
MOV RDI,qword ptr [RSP + 0x8]
ADD RDI,0x50
CALL 0x001504a0
MOV RAX,qword ptr [RSP + 0x8]
LEA RCX,[0x2cb050]
MOV qword ptr [RAX + 0x70],RCX
MOV qword ptr [RAX + 0x78],0x0
MOV qword ptr [RAX + 0x80],0x0
XORPS XMM0,XMM0
MOVSD qword ptr [RAX + 0x88],XMM0
CALL 0x001af180
MOV CL,AL
MOV RAX,qword ptr [RSP + 0x8]
MOVSX ECX,CL
MOV dword ptr [RAX + 0x90],ECX
ADD RSP,0x28
RET
|
/* nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>,
nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char
const*, std::__cxx11::string > >
>::lexer(nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char
const*, std::__cxx11::string > >&&, bool) */
void __thiscall
nlohmann::json_abi_v3_11_3::detail::
lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
::lexer(lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
*this,iterator_input_adapter *param_1,bool param_2)
{
char cVar1;
int4 uVar2;
*(int8 *)this = *(int8 *)param_1;
*(int8 *)(this + 8) = *(int8 *)(param_1 + 8);
this[0x10] = (lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
)param_2;
uVar2 = std::char_traits<char>::eof();
*(int4 *)(this + 0x14) = uVar2;
this[0x18] = (lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
)0x0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
memset((vector<char,std::allocator<char>> *)(this + 0x38),0,0x18);
std::vector<char,std::allocator<char>>::vector((vector<char,std::allocator<char>> *)(this + 0x38))
;
std::__cxx11::string::string((string *)(this + 0x50));
*(char **)(this + 0x70) = "";
*(int8 *)(this + 0x78) = 0;
*(int8 *)(this + 0x80) = 0;
*(int8 *)(this + 0x88) = 0;
cVar1 = get_decimal_point();
*(int *)(this + 0x90) = (int)cVar1;
return;
}
| |
21,404 | void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__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>>::dump_integer<unsigned char, 0>(unsigned char) | monkey531[P]llama/common/json.hpp | void dump_integer(NumberType x)
{
static constexpr std::array<std::array<char, 2>, 100> digits_to_99
{
{
{{'0', '0'}}, {{'0', '1'}}, {{'0', '2'}}, {{'0', '3'}}, {{'0', '4'}}, {{'0', '5'}}, {{'0', '6'}}, {{'0', '7'}}, {{'0', '8'}}, {{'0', '9'}},
{{'1', '0'}}, {{'1', '1'}}, {{'1', '2'}}, {{'1', '3'}}, {{'1', '4'}}, {{'1', '5'}}, {{'1', '6'}}, {{'1', '7'}}, {{'1', '8'}}, {{'1', '9'}},
{{'2', '0'}}, {{'2', '1'}}, {{'2', '2'}}, {{'2', '3'}}, {{'2', '4'}}, {{'2', '5'}}, {{'2', '6'}}, {{'2', '7'}}, {{'2', '8'}}, {{'2', '9'}},
{{'3', '0'}}, {{'3', '1'}}, {{'3', '2'}}, {{'3', '3'}}, {{'3', '4'}}, {{'3', '5'}}, {{'3', '6'}}, {{'3', '7'}}, {{'3', '8'}}, {{'3', '9'}},
{{'4', '0'}}, {{'4', '1'}}, {{'4', '2'}}, {{'4', '3'}}, {{'4', '4'}}, {{'4', '5'}}, {{'4', '6'}}, {{'4', '7'}}, {{'4', '8'}}, {{'4', '9'}},
{{'5', '0'}}, {{'5', '1'}}, {{'5', '2'}}, {{'5', '3'}}, {{'5', '4'}}, {{'5', '5'}}, {{'5', '6'}}, {{'5', '7'}}, {{'5', '8'}}, {{'5', '9'}},
{{'6', '0'}}, {{'6', '1'}}, {{'6', '2'}}, {{'6', '3'}}, {{'6', '4'}}, {{'6', '5'}}, {{'6', '6'}}, {{'6', '7'}}, {{'6', '8'}}, {{'6', '9'}},
{{'7', '0'}}, {{'7', '1'}}, {{'7', '2'}}, {{'7', '3'}}, {{'7', '4'}}, {{'7', '5'}}, {{'7', '6'}}, {{'7', '7'}}, {{'7', '8'}}, {{'7', '9'}},
{{'8', '0'}}, {{'8', '1'}}, {{'8', '2'}}, {{'8', '3'}}, {{'8', '4'}}, {{'8', '5'}}, {{'8', '6'}}, {{'8', '7'}}, {{'8', '8'}}, {{'8', '9'}},
{{'9', '0'}}, {{'9', '1'}}, {{'9', '2'}}, {{'9', '3'}}, {{'9', '4'}}, {{'9', '5'}}, {{'9', '6'}}, {{'9', '7'}}, {{'9', '8'}}, {{'9', '9'}},
}
};
// special case for "0"
if (x == 0)
{
o->write_character('0');
return;
}
// use a pointer to fill the buffer
auto buffer_ptr = number_buffer.begin(); // NOLINT(llvm-qualified-auto,readability-qualified-auto,cppcoreguidelines-pro-type-vararg,hicpp-vararg)
number_unsigned_t abs_value;
unsigned int n_chars{};
if (is_negative_number(x))
{
*buffer_ptr = '-';
abs_value = remove_sign(static_cast<number_integer_t>(x));
// account one more byte for the minus sign
n_chars = 1 + count_digits(abs_value);
}
else
{
abs_value = static_cast<number_unsigned_t>(x);
n_chars = count_digits(abs_value);
}
// spare 1 byte for '\0'
JSON_ASSERT(n_chars < number_buffer.size() - 1);
// jump to the end to generate the string from backward,
// so we later avoid reversing the result
buffer_ptr += n_chars;
// Fast int2ascii implementation inspired by "Fastware" talk by Andrei Alexandrescu
// See: https://www.youtube.com/watch?v=o4-CwDo2zpg
while (abs_value >= 100)
{
const auto digits_index = static_cast<unsigned>((abs_value % 100));
abs_value /= 100;
*(--buffer_ptr) = digits_to_99[digits_index][1];
*(--buffer_ptr) = digits_to_99[digits_index][0];
}
if (abs_value >= 10)
{
const auto digits_index = static_cast<unsigned>(abs_value);
*(--buffer_ptr) = digits_to_99[digits_index][1];
*(--buffer_ptr) = digits_to_99[digits_index][0];
}
else
{
*(--buffer_ptr) = static_cast<char>('0' + abs_value);
}
o->write_characters(number_buffer.data(), n_chars);
} | O2 | cpp | void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__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>>::dump_integer<unsigned char, 0>(unsigned char):
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
testq %rsi, %rsi
je 0x87edc
movq %rsi, %r14
movq %rbx, %rdi
callq 0x88310
cmpl $0x3f, %eax
jae 0x87f14
leaq 0x10(%rbx), %rsi
movl %eax, %ecx
leaq (%rsi,%rcx), %rdi
pushq $0x64
popq %r9
leaq 0x319c2(%rip), %r8 # 0xb9865
cmpq $0x64, %r14
jb 0x87ec5
movq %r14, %rax
xorl %edx, %edx
divq %r9
movl %edx, %edx
movzwl (%r8,%rdx,2), %edx
movw %dx, -0x2(%rdi)
addq $-0x2, %rdi
movq %rax, %r14
jmp 0x87ea3
cmpq $0xa, %r14
jb 0x87ef1
movb (%r8,%r14,2), %al
movb 0x1(%r8,%r14,2), %dl
movb %dl, -0x1(%rdi)
pushq $-0x2
popq %rdx
jmp 0x87efb
movq (%rbx), %rdi
movq (%rdi), %rax
movq (%rax), %rax
pushq $0x30
popq %rsi
addq $0x8, %rsp
popq %rbx
popq %r14
jmpq *%rax
orb $0x30, %r14b
pushq $-0x1
popq %rdx
movl %r14d, %eax
movb %al, (%rdi,%rdx)
movq (%rbx), %rdi
movq (%rdi), %rax
movq 0x8(%rax), %rax
movq %rcx, %rdx
addq $0x8, %rsp
popq %rbx
popq %r14
jmpq *%rax
leaq 0x29d21(%rip), %rdi # 0xb1c3c
leaq 0x29d64(%rip), %rdx # 0xb1c86
leaq 0x2f395(%rip), %rcx # 0xb72be
movl $0x4952, %esi # imm = 0x4952
xorl %eax, %eax
callq 0x24ea0
nop
| _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_:
push r14
push rbx
push rax
mov rbx, rdi
test rsi, rsi
jz short loc_87EDC
mov r14, rsi
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12count_digitsEm; nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::count_digits(ulong)
cmp eax, 3Fh ; '?'
jnb loc_87F14
lea rsi, [rbx+10h]
mov ecx, eax
lea rdi, [rsi+rcx]
push 64h ; 'd'
pop r9
lea r8, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99
loc_87EA3:
cmp r14, 64h ; 'd'
jb short loc_87EC5
mov rax, r14
xor edx, edx
div r9
mov edx, edx
movzx edx, word ptr [r8+rdx*2]
mov [rdi-2], dx
add rdi, 0FFFFFFFFFFFFFFFEh
mov r14, rax
jmp short loc_87EA3
loc_87EC5:
cmp r14, 0Ah
jb short loc_87EF1
mov al, [r8+r14*2]
mov dl, [r8+r14*2+1]
mov [rdi-1], dl
push 0FFFFFFFFFFFFFFFEh
pop rdx
jmp short loc_87EFB
loc_87EDC:
mov rdi, [rbx]
mov rax, [rdi]
mov rax, [rax]
push 30h ; '0'
pop rsi
add rsp, 8
pop rbx
pop r14
jmp rax
loc_87EF1:
or r14b, 30h
push 0FFFFFFFFFFFFFFFFh
pop rdx
mov eax, r14d
loc_87EFB:
mov [rdi+rdx], al
mov rdi, [rbx]
mov rax, [rdi]
mov rax, [rax+8]
mov rdx, rcx
add rsp, 8
pop rbx
pop r14
jmp rax
loc_87F14:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aNCharsNumberBu; "n_chars < number_buffer.size() - 1"
mov esi, 4952h
xor eax, eax
call _ggml_abort
nop
| long long ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_(
_QWORD *a1,
unsigned long long a2)
{
unsigned long long v3; // r14
unsigned int v4; // eax
_QWORD *v5; // rsi
long long v6; // rcx
long long v7; // rdi
char v8; // al
long long v9; // rdx
if ( !a2 )
return (**(long long ( ***)(_QWORD, long long))*a1)(*a1, 48LL);
v3 = a2;
v4 = nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::count_digits(
a1,
a2);
if ( v4 >= 0x3F )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
18770LL,
"GGML_ASSERT(%s) failed",
"n_chars < number_buffer.size() - 1");
return ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
18770LL);
}
else
{
v5 = a1 + 2;
v6 = v4;
v7 = (long long)a1 + v4 + 16;
while ( v3 >= 0x64 )
{
*(_WORD *)(v7 - 2) = *((_WORD *)&ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99
+ v3 % 0x64);
v7 -= 2LL;
v3 /= 0x64uLL;
}
if ( v3 < 0xA )
{
v9 = -1LL;
v8 = v3 | 0x30;
}
else
{
v8 = *((_BYTE *)&ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99
+ 2 * v3);
*(_BYTE *)(v7 - 1) = *((_BYTE *)&ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99
+ 2 * v3
+ 1);
v9 = -2LL;
}
*(_BYTE *)(v7 + v9) = v8;
return (*(long long ( **)(_QWORD, _QWORD *, long long))(*(_QWORD *)*a1 + 8LL))(*a1, v5, v6);
}
}
| _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
TEST RSI,RSI
JZ 0x00187edc
MOV R14,RSI
MOV RDI,RBX
CALL 0x00188310
CMP EAX,0x3f
JNC 0x00187f14
LEA RSI,[RBX + 0x10]
MOV ECX,EAX
LEA RDI,[RSI + RCX*0x1]
PUSH 0x64
POP R9
LEA R8,[0x1b9865]
LAB_00187ea3:
CMP R14,0x64
JC 0x00187ec5
MOV RAX,R14
XOR EDX,EDX
DIV R9
MOV EDX,EDX
MOVZX EDX,word ptr [R8 + RDX*0x2]
MOV word ptr [RDI + -0x2],DX
ADD RDI,-0x2
MOV R14,RAX
JMP 0x00187ea3
LAB_00187ec5:
CMP R14,0xa
JC 0x00187ef1
MOV AL,byte ptr [R8 + R14*0x2]
MOV DL,byte ptr [R8 + R14*0x2 + 0x1]
MOV byte ptr [RDI + -0x1],DL
PUSH -0x2
POP RDX
JMP 0x00187efb
LAB_00187edc:
MOV RDI,qword ptr [RBX]
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX]
PUSH 0x30
POP RSI
ADD RSP,0x8
POP RBX
POP R14
JMP RAX
LAB_00187ef1:
OR R14B,0x30
PUSH -0x1
POP RDX
MOV EAX,R14D
LAB_00187efb:
MOV byte ptr [RDI + RDX*0x1],AL
MOV RDI,qword ptr [RBX]
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX + 0x8]
MOV RDX,RCX
ADD RSP,0x8
POP RBX
POP R14
JMP RAX
LAB_00187f14:
LEA RDI,[0x1b1c3c]
LEA RDX,[0x1b1c86]
LEA RCX,[0x1b72be]
MOV ESI,0x4952
XOR EAX,EAX
CALL 0x00124ea0
|
void _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_
(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*param_1,ulong param_2)
{
uint uVar1;
long lVar2;
serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*psVar3;
serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
sVar4;
if (param_2 == 0) {
/* WARNING: Could not recover jumptable at 0x00187eef. Too many branches */
/* WARNING: Treating indirect jump as call */
(**(code **)**(int8 **)param_1)(*(int8 **)param_1,0x30);
return;
}
uVar1 = nlohmann::json_abi_v3_11_3::detail::
serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::count_digits(param_1,param_2);
if (uVar1 < 0x3f) {
psVar3 = param_1 + 0x10 + uVar1;
for (; 99 < param_2; param_2 = param_2 / 100) {
*(int2 *)(psVar3 + -2) =
*(int2 *)
(
_ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99
+ (param_2 % 100) * 2);
psVar3 = psVar3 + -2;
}
if (param_2 < 10) {
sVar4 = (serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
)((byte)param_2 | 0x30);
lVar2 = -1;
}
else {
sVar4 = *(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*)(
_ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99
+ param_2 * 2);
psVar3[-1] = *(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*)(
_ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerImTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99
+ param_2 * 2 + 1);
lVar2 = -2;
}
psVar3[lVar2] = sVar4;
/* WARNING: Could not recover jumptable at 0x00187f12. Too many branches */
/* WARNING: Treating indirect jump as call */
(**(code **)(**(long **)param_1 + 8))(*(long **)param_1,param_1 + 0x10,(ulong)uVar1);
return;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x4952,
"GGML_ASSERT(%s) failed","n_chars < number_buffer.size() - 1");
}
| |
21,405 | google::protobuf::Descriptor::FindFieldByCamelcaseName(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) const | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc | const FieldDescriptor* Descriptor::FindFieldByCamelcaseName(
ConstStringParam key) const {
const FieldDescriptor* result =
file()->tables_->FindFieldByCamelcaseName(this, key);
if (result == nullptr || result->is_extension()) {
return nullptr;
} else {
return result;
}
} | O0 | cpp | google::protobuf::Descriptor::FindFieldByCamelcaseName(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) const:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq %rsi, 0x30(%rsp)
movq 0x38(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x1c1590
movq 0x80(%rax), %rax
movq %rax, 0x8(%rsp)
movq 0x30(%rsp), %rsi
leaq 0x18(%rsp), %rdi
callq 0x158e50
movq 0x8(%rsp), %rdi
movq 0x10(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq 0x20(%rsp), %rcx
callq 0x282a30
movq %rax, 0x28(%rsp)
cmpq $0x0, 0x28(%rsp)
je 0x24430e
movq 0x28(%rsp), %rdi
callq 0x1bab10
testb $0x1, %al
jne 0x24430e
jmp 0x244319
movq $0x0, 0x40(%rsp)
jmp 0x244323
movq 0x28(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x40(%rsp), %rax
addq $0x48, %rsp
retq
nopl (%rax)
| _ZNK6google8protobuf10Descriptor24FindFieldByCamelcaseNameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
sub rsp, 48h
mov [rsp+48h+var_10], rdi
mov [rsp+48h+var_18], rsi
mov rdi, [rsp+48h+var_10]; this
mov [rsp+48h+var_38], rdi
call _ZNK6google8protobuf10Descriptor4fileEv; google::protobuf::Descriptor::file(void)
mov rax, [rax+80h]
mov [rsp+48h+var_40], rax
mov rsi, [rsp+48h+var_18]
lea rdi, [rsp+48h+var_30]
call _ZN6google8protobuf20stringpiece_internal11StringPieceC2ISaIcEEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcET_EE; google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(std::string const&)
mov rdi, [rsp+48h+var_40]
mov rsi, [rsp+48h+var_38]
mov rdx, [rsp+48h+var_30]
mov rcx, [rsp+48h+var_28]
call _ZNK6google8protobuf20FileDescriptorTables24FindFieldByCamelcaseNameEPKvNS0_20stringpiece_internal11StringPieceE; google::protobuf::FileDescriptorTables::FindFieldByCamelcaseName(void const*,google::protobuf::stringpiece_internal::StringPiece)
mov [rsp+48h+var_20], rax
cmp [rsp+48h+var_20], 0
jz short loc_24430E
mov rdi, [rsp+48h+var_20]; this
call _ZNK6google8protobuf15FieldDescriptor12is_extensionEv; google::protobuf::FieldDescriptor::is_extension(void)
test al, 1
jnz short loc_24430E
jmp short loc_244319
loc_24430E:
mov [rsp+48h+var_8], 0
jmp short loc_244323
loc_244319:
mov rax, [rsp+48h+var_20]
mov [rsp+48h+var_8], rax
loc_244323:
mov rax, [rsp+48h+var_8]
add rsp, 48h
retn
| google::protobuf::FieldDescriptor * google::protobuf::Descriptor::FindFieldByCamelcaseName(
google::protobuf::Descriptor *a1,
long long a2)
{
long long v3; // [rsp+8h] [rbp-40h]
google::protobuf::FieldDescriptor *v4[2]; // [rsp+18h] [rbp-30h] BYREF
google::protobuf::FieldDescriptor *FieldByCamelcaseName; // [rsp+28h] [rbp-20h]
long long v6; // [rsp+30h] [rbp-18h]
google::protobuf::Descriptor *v7; // [rsp+38h] [rbp-10h]
v7 = a1;
v6 = a2;
v3 = *(_QWORD *)(google::protobuf::Descriptor::file(a1) + 128);
google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(v4, a2);
FieldByCamelcaseName = (google::protobuf::FieldDescriptor *)google::protobuf::FileDescriptorTables::FindFieldByCamelcaseName(
v3,
a1,
v4[0],
v4[1]);
if ( FieldByCamelcaseName && !google::protobuf::FieldDescriptor::is_extension(FieldByCamelcaseName) )
return FieldByCamelcaseName;
else
return 0LL;
}
| _M_reserve_map_at_back:
SUB RSP,0x18
MOV qword ptr [RSP + 0x10],RDI
MOV qword ptr [RSP + 0x8],RSI
MOV RSI,qword ptr [RSP + 0x10]
MOV qword ptr [RSP],RSI
MOV RAX,qword ptr [RSP + 0x8]
ADD RAX,0x1
MOV RCX,qword ptr [RSI + 0x8]
MOV RDX,qword ptr [RSI + 0x48]
MOV RSI,qword ptr [RSI]
SUB RDX,RSI
SAR RDX,0x3
SUB RCX,RDX
CMP RAX,RCX
JBE 0x002442ea
MOV RDI,qword ptr [RSP]
MOV RSI,qword ptr [RSP + 0x8]
XOR EDX,EDX
CALL 0x002443f0
LAB_002442ea:
ADD RSP,0x18
RET
|
/* std::deque<YAML::CollectionType::value, std::allocator<YAML::CollectionType::value>
>::_M_reserve_map_at_back(unsigned long) */
void __thiscall
std::deque<YAML::CollectionType::value,std::allocator<YAML::CollectionType::value>>::
_M_reserve_map_at_back
(deque<YAML::CollectionType::value,std::allocator<YAML::CollectionType::value>> *this,
ulong param_1)
{
if ((ulong)(*(long *)(this + 8) - (*(long *)(this + 0x48) - *(long *)this >> 3)) < param_1 + 1) {
_M_reallocate_map(this,param_1,false);
}
return;
}
| |
21,406 | glfwPlatformCreateWindowSurface | untodesu[P]riteg/build_O1/_deps/glfw-src/src/x11_window.c | VkResult _glfwPlatformCreateWindowSurface(VkInstance instance,
_GLFWwindow* window,
const VkAllocationCallbacks* allocator,
VkSurfaceKHR* surface)
{
if (_glfw.vk.KHR_xcb_surface && _glfw.x11.x11xcb.handle)
{
VkResult err;
VkXcbSurfaceCreateInfoKHR sci;
PFN_vkCreateXcbSurfaceKHR vkCreateXcbSurfaceKHR;
xcb_connection_t* connection = XGetXCBConnection(_glfw.x11.display);
if (!connection)
{
_glfwInputError(GLFW_PLATFORM_ERROR,
"X11: Failed to retrieve XCB connection");
return VK_ERROR_EXTENSION_NOT_PRESENT;
}
vkCreateXcbSurfaceKHR = (PFN_vkCreateXcbSurfaceKHR)
vkGetInstanceProcAddr(instance, "vkCreateXcbSurfaceKHR");
if (!vkCreateXcbSurfaceKHR)
{
_glfwInputError(GLFW_API_UNAVAILABLE,
"X11: Vulkan instance missing VK_KHR_xcb_surface extension");
return VK_ERROR_EXTENSION_NOT_PRESENT;
}
memset(&sci, 0, sizeof(sci));
sci.sType = VK_STRUCTURE_TYPE_XCB_SURFACE_CREATE_INFO_KHR;
sci.connection = connection;
sci.window = window->x11.handle;
err = vkCreateXcbSurfaceKHR(instance, &sci, allocator, surface);
if (err)
{
_glfwInputError(GLFW_PLATFORM_ERROR,
"X11: Failed to create Vulkan XCB surface: %s",
_glfwGetVulkanResultString(err));
}
return err;
}
else
{
VkResult err;
VkXlibSurfaceCreateInfoKHR sci;
PFN_vkCreateXlibSurfaceKHR vkCreateXlibSurfaceKHR;
vkCreateXlibSurfaceKHR = (PFN_vkCreateXlibSurfaceKHR)
vkGetInstanceProcAddr(instance, "vkCreateXlibSurfaceKHR");
if (!vkCreateXlibSurfaceKHR)
{
_glfwInputError(GLFW_API_UNAVAILABLE,
"X11: Vulkan instance missing VK_KHR_xlib_surface extension");
return VK_ERROR_EXTENSION_NOT_PRESENT;
}
memset(&sci, 0, sizeof(sci));
sci.sType = VK_STRUCTURE_TYPE_XLIB_SURFACE_CREATE_INFO_KHR;
sci.dpy = _glfw.x11.display;
sci.window = window->x11.handle;
err = vkCreateXlibSurfaceKHR(instance, &sci, allocator, surface);
if (err)
{
_glfwInputError(GLFW_PLATFORM_ERROR,
"X11: Failed to create Vulkan X11 surface: %s",
_glfwGetVulkanResultString(err));
}
return err;
}
} | O1 | c | glfwPlatformCreateWindowSurface:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
leaq 0x7ebde(%rip), %rbp # 0xa4638
cmpl $0x0, 0x1fea8(%rbp)
je 0x25af7
cmpq $0x0, 0x206b8(%rbp)
je 0x25af7
movq 0x1fec0(%rbp), %rdi
callq *0x206c0(%rbp)
testq %rax, %rax
je 0x25b77
movq %rax, %r13
leaq 0x5c23b(%rip), %rsi # 0x81cd0
movq %r15, %rdi
callq *0x1fe98(%rbp)
testq %rax, %rax
je 0x25b85
xorps %xmm0, %xmm0
movq %rsp, %rsi
movaps %xmm0, (%rsi)
movaps %xmm0, 0x10(%rsi)
movq $0x0, 0x20(%rsi)
movl $0x3b9add88, (%rsi) # imm = 0x3B9ADD88
movq %r13, 0x18(%rsi)
movq 0x348(%r12), %rcx
movq %rcx, 0x20(%rsi)
movq %r15, %rdi
movq %r14, %rdx
movq %rbx, %rcx
callq *%rax
movl %eax, %ebx
testl %eax, %eax
je 0x25b9d
movl %ebx, %edi
callq 0x1c788
leaq 0x5c1f1(%rip), %rsi # 0x81ce6
jmp 0x25b5d
leaq 0x5c215(%rip), %rsi # 0x81d13
movq %r15, %rdi
callq *0x1fe98(%rbp)
testq %rax, %rax
je 0x25b6e
xorps %xmm0, %xmm0
movq %rsp, %rsi
movaps %xmm0, (%rsi)
movaps %xmm0, 0x10(%rsi)
movq $0x0, 0x20(%rsi)
movl $0x3b9ad9a0, (%rsi) # imm = 0x3B9AD9A0
movq 0x1fec0(%rbp), %rcx
movq %rcx, 0x18(%rsi)
movq 0x348(%r12), %rcx
movq %rcx, 0x20(%rsi)
movq %r15, %rdi
movq %r14, %rdx
movq %rbx, %rcx
callq *%rax
movl %eax, %ebx
testl %eax, %eax
je 0x25b9d
movl %ebx, %edi
callq 0x1c788
leaq 0x5c1cd(%rip), %rsi # 0x81d2a
movl $0x10008, %edi # imm = 0x10008
movq %rax, %rdx
xorl %eax, %eax
callq 0x19081
jmp 0x25b9d
leaq 0x5c120(%rip), %rsi # 0x81c95
jmp 0x25b8c
leaq 0x5c0c2(%rip), %rsi # 0x81c40
movl $0x10008, %edi # imm = 0x10008
jmp 0x25b91
leaq 0x5c07a(%rip), %rsi # 0x81c06
movl $0x10006, %edi # imm = 0x10006
xorl %eax, %eax
callq 0x19081
movl $0xfffffff9, %ebx # imm = 0xFFFFFFF9
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| _glfwPlatformCreateWindowSurface:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov rbx, rcx
mov r14, rdx
mov r12, rsi
mov r15, rdi
lea rbp, _glfw
cmp dword ptr ss:loc_1FEA8[rbp], 0
jz loc_25AF7
cmp qword ptr [rbp+206B8h], 0
jz loc_25AF7
mov rdi, [rbp+1FEC0h]
call qword ptr [rbp+206C0h]
test rax, rax
jz loc_25B77
mov r13, rax
lea rsi, aVkcreatexcbsur; "vkCreateXcbSurfaceKHR"
mov rdi, r15
call qword ptr [rbp+1FE98h]
test rax, rax
jz loc_25B85
xorps xmm0, xmm0
mov rsi, rsp
movaps xmmword ptr [rsi], xmm0
movaps xmmword ptr [rsi+10h], xmm0
mov qword ptr [rsi+20h], 0
mov dword ptr [rsi], 3B9ADD88h
mov [rsi+18h], r13
mov rcx, [r12+348h]
mov [rsi+20h], rcx
mov rdi, r15
mov rdx, r14
mov rcx, rbx
call rax
mov ebx, eax
test eax, eax
jz loc_25B9D
mov edi, ebx
call _glfwGetVulkanResultString
lea rsi, aX11FailedToCre_1; "X11: Failed to create Vulkan XCB surfac"...
jmp short loc_25B5D
loc_25AF7:
lea rsi, aVkcreatexlibsu; "vkCreateXlibSurfaceKHR"
mov rdi, r15
call qword ptr [rbp+1FE98h]
test rax, rax
jz short loc_25B6E
xorps xmm0, xmm0
mov rsi, rsp
movaps xmmword ptr [rsi], xmm0
movaps xmmword ptr [rsi+10h], xmm0
mov qword ptr [rsi+20h], 0
mov dword ptr [rsi], 3B9AD9A0h
mov rcx, [rbp+1FEC0h]
mov [rsi+18h], rcx
mov rcx, [r12+348h]
mov [rsi+20h], rcx
mov rdi, r15
mov rdx, r14
mov rcx, rbx
call rax
mov ebx, eax
test eax, eax
jz short loc_25B9D
mov edi, ebx
call _glfwGetVulkanResultString
lea rsi, aX11FailedToCre_2; "X11: Failed to create Vulkan X11 surfac"...
loc_25B5D:
mov edi, offset loc_10008
mov rdx, rax
xor eax, eax
call _glfwInputError
jmp short loc_25B9D
loc_25B6E:
lea rsi, aX11VulkanInsta; "X11: Vulkan instance missing VK_KHR_xli"...
jmp short loc_25B8C
loc_25B77:
lea rsi, aX11FailedToRet; "X11: Failed to retrieve XCB connection"
mov edi, offset loc_10008
jmp short loc_25B91
loc_25B85:
lea rsi, aX11VulkanInsta_0; "X11: Vulkan instance missing VK_KHR_xcb"...
loc_25B8C:
mov edi, 10006h
loc_25B91:
xor eax, eax
call _glfwInputError
mov ebx, 0FFFFFFF9h
loc_25B9D:
mov eax, ebx
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long glfwPlatformCreateWindowSurface(long long a1, long long a2, long long a3, long long a4)
{
long long v6; // rax
long long v7; // r13
long long ( *v8)(long long, __int128 *, long long, long long); // rax
int v9; // eax
unsigned int v10; // ebx
const char *VulkanResultString; // rax
long long ( *v12)(long long, __int128 *, long long, long long); // rax
int v13; // eax
const char *v14; // rax
const char *v15; // rsi
__int128 v17; // [rsp+0h] [rbp-58h] BYREF
__int128 v18; // [rsp+10h] [rbp-48h]
long long v19; // [rsp+20h] [rbp-38h]
if ( *(_DWORD *)((char *)&loc_1FEA8 + (_QWORD)glfw) && *(_QWORD *)&glfw[33198] )
{
v6 = (*(long long ( **)(_QWORD))&glfw[33200])(*(_QWORD *)&glfw[32688]);
if ( !v6 )
{
glfwInputError((unsigned int)&loc_10008, (long long)"X11: Failed to retrieve XCB connection");
return (unsigned int)-7;
}
v7 = v6;
v8 = (long long ( *)(long long, __int128 *, long long, long long))(*(long long ( **)(long long, const char *))&glfw[32678])(
a1,
"vkCreateXcbSurfaceKHR");
if ( v8 )
{
v17 = 0LL;
*(_QWORD *)&v18 = 0LL;
v19 = 0LL;
LODWORD(v17) = 1000005000;
*((_QWORD *)&v18 + 1) = v7;
v19 = *(_QWORD *)(a2 + 840);
v9 = v8(a1, &v17, a3, a4);
v10 = v9;
if ( v9 )
{
VulkanResultString = glfwGetVulkanResultString(v9);
glfwInputError(
(unsigned int)&loc_10008,
(long long)"X11: Failed to create Vulkan XCB surface: %s",
VulkanResultString);
}
return v10;
}
v15 = "X11: Vulkan instance missing VK_KHR_xcb_surface extension";
LABEL_14:
glfwInputError(0x10006u, (long long)v15);
return (unsigned int)-7;
}
v12 = (long long ( *)(long long, __int128 *, long long, long long))(*(long long ( **)(long long, const char *))&glfw[32678])(
a1,
"vkCreateXlibSurfaceKHR");
if ( !v12 )
{
v15 = "X11: Vulkan instance missing VK_KHR_xlib_surface extension";
goto LABEL_14;
}
v17 = 0LL;
v18 = 0LL;
v19 = 0LL;
LODWORD(v17) = 1000004000;
*((_QWORD *)&v18 + 1) = *(_QWORD *)&glfw[32688];
v19 = *(_QWORD *)(a2 + 840);
v13 = v12(a1, &v17, a3, a4);
v10 = v13;
if ( v13 )
{
v14 = glfwGetVulkanResultString(v13);
glfwInputError((unsigned int)&loc_10008, (long long)"X11: Failed to create Vulkan X11 surface: %s", v14);
}
return v10;
}
| _glfwPlatformCreateWindowSurface:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV RBX,RCX
MOV R14,RDX
MOV R12,RSI
MOV R15,RDI
LEA RBP,[0x1a4638]
CMP dword ptr [RBP + 0x1fea8],0x0
JZ 0x00125af7
CMP qword ptr [RBP + 0x206b8],0x0
JZ 0x00125af7
MOV RDI,qword ptr [RBP + 0x1fec0]
CALL qword ptr [RBP + 0x206c0]
TEST RAX,RAX
JZ 0x00125b77
MOV R13,RAX
LEA RSI,[0x181cd0]
MOV RDI,R15
CALL qword ptr [RBP + 0x1fe98]
TEST RAX,RAX
JZ 0x00125b85
XORPS XMM0,XMM0
MOV RSI,RSP
MOVAPS xmmword ptr [RSI],XMM0
MOVAPS xmmword ptr [RSI + 0x10],XMM0
MOV qword ptr [RSI + 0x20],0x0
MOV dword ptr [RSI],0x3b9add88
MOV qword ptr [RSI + 0x18],R13
MOV RCX,qword ptr [R12 + 0x348]
MOV qword ptr [RSI + 0x20],RCX
MOV RDI,R15
MOV RDX,R14
MOV RCX,RBX
CALL RAX
MOV EBX,EAX
TEST EAX,EAX
JZ 0x00125b9d
MOV EDI,EBX
CALL 0x0011c788
LEA RSI,[0x181ce6]
JMP 0x00125b5d
LAB_00125af7:
LEA RSI,[0x181d13]
MOV RDI,R15
CALL qword ptr [RBP + 0x1fe98]
TEST RAX,RAX
JZ 0x00125b6e
XORPS XMM0,XMM0
MOV RSI,RSP
MOVAPS xmmword ptr [RSI],XMM0
MOVAPS xmmword ptr [RSI + 0x10],XMM0
MOV qword ptr [RSI + 0x20],0x0
MOV dword ptr [RSI],0x3b9ad9a0
MOV RCX,qword ptr [RBP + 0x1fec0]
MOV qword ptr [RSI + 0x18],RCX
MOV RCX,qword ptr [R12 + 0x348]
MOV qword ptr [RSI + 0x20],RCX
MOV RDI,R15
MOV RDX,R14
MOV RCX,RBX
CALL RAX
MOV EBX,EAX
TEST EAX,EAX
JZ 0x00125b9d
MOV EDI,EBX
CALL 0x0011c788
LEA RSI,[0x181d2a]
LAB_00125b5d:
MOV EDI,0x10008
MOV RDX,RAX
XOR EAX,EAX
CALL 0x00119081
JMP 0x00125b9d
LAB_00125b6e:
LEA RSI,[0x181c95]
JMP 0x00125b8c
LAB_00125b77:
LEA RSI,[0x181c40]
MOV EDI,0x10008
JMP 0x00125b91
LAB_00125b85:
LEA RSI,[0x181c06]
LAB_00125b8c:
MOV EDI,0x10006
LAB_00125b91:
XOR EAX,EAX
CALL 0x00119081
MOV EBX,0xfffffff9
LAB_00125b9d:
MOV EAX,EBX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int _glfwPlatformCreateWindowSurface
(int8 param_1,long param_2,int8 param_3,int8 param_4)
{
int iVar1;
code *pcVar2;
int8 uVar3;
char *pcVar4;
int8 local_58;
int8 uStack_50;
int8 local_48;
long lStack_40;
int8 local_38;
if ((DAT_001c44e0 == 0) || (DAT_001c4cf0 == 0)) {
pcVar2 = (code *)(*DAT_001c44d0)(param_1,"vkCreateXlibSurfaceKHR");
if (pcVar2 != (code *)0x0) {
uStack_50 = 0;
local_48 = 0;
local_58 = 0x3b9ad9a0;
lStack_40 = DAT_001c44f8;
local_38 = *(int8 *)(param_2 + 0x348);
iVar1 = (*pcVar2)(param_1,&local_58,param_3,param_4);
if (iVar1 == 0) {
return 0;
}
uVar3 = _glfwGetVulkanResultString(iVar1);
pcVar4 = "X11: Failed to create Vulkan X11 surface: %s";
LAB_00125b5d:
_glfwInputError(0x10008,pcVar4,uVar3);
return iVar1;
}
pcVar4 = "X11: Vulkan instance missing VK_KHR_xlib_surface extension";
}
else {
lStack_40 = (*DAT_001c4cf8)(DAT_001c44f8);
if (lStack_40 == 0) {
pcVar4 = "X11: Failed to retrieve XCB connection";
uVar3 = 0x10008;
goto LAB_00125b91;
}
pcVar2 = (code *)(*DAT_001c44d0)(param_1,"vkCreateXcbSurfaceKHR");
if (pcVar2 != (code *)0x0) {
uStack_50 = 0;
local_48 = 0;
local_58 = 0x3b9add88;
local_38 = *(int8 *)(param_2 + 0x348);
iVar1 = (*pcVar2)(param_1,&local_58,param_3,param_4);
if (iVar1 == 0) {
return 0;
}
uVar3 = _glfwGetVulkanResultString(iVar1);
pcVar4 = "X11: Failed to create Vulkan XCB surface: %s";
goto LAB_00125b5d;
}
pcVar4 = "X11: Vulkan instance missing VK_KHR_xcb_surface extension";
}
uVar3 = 0x10006;
LAB_00125b91:
_glfwInputError(uVar3,pcVar4);
return -7;
}
| |
21,407 | translog_variable_record_1group_decode_len | eloqsql/storage/maria/ma_loghandler.c | static translog_size_t translog_variable_record_1group_decode_len(uchar **src)
{
uint8 first= (uint8) (**src);
switch (first) {
case 251:
(*src)+= 3;
return (uint2korr((*src) - 2));
case 252:
(*src)+= 4;
return (uint3korr((*src) - 3));
case 253:
(*src)+= 5;
return (uint4korr((*src) - 4));
case 254:
case 255:
DBUG_ASSERT(0); /* reserved for future use */
return (0);
default:
(*src)++;
return (first);
}
} | O0 | c | translog_variable_record_1group_decode_len:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movb (%rax), %al
movb %al, -0x11(%rbp)
movzbl -0x11(%rbp), %eax
addl $0xffffff05, %eax # imm = 0xFFFFFF05
movl %eax, %ecx
movq %rcx, -0x20(%rbp)
subl $0x4, %eax
ja 0x4ebd6
movq -0x20(%rbp), %rax
leaq 0x13b499(%rip), %rcx # 0x189fe0
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq $0x3, %rcx
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movzwl -0x2(%rax), %eax
movl %eax, -0x4(%rbp)
jmp 0x4ebeb
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq $0x4, %rcx
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movzbl -0x3(%rax), %eax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
movzbl -0x2(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
movzbl -0x1(%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movl %eax, -0x4(%rbp)
jmp 0x4ebeb
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq $0x5, %rcx
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl -0x4(%rax), %eax
movl %eax, -0x4(%rbp)
jmp 0x4ebeb
jmp 0x4ebcb
jmp 0x4ebcd
movl $0x0, -0x4(%rbp)
jmp 0x4ebeb
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movq %rcx, (%rax)
movzbl -0x11(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
| translog_variable_record_1group_decode_len:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov rax, [rbp+var_10]
mov rax, [rax]
mov al, [rax]
mov [rbp+var_11], al
movzx eax, [rbp+var_11]
add eax, 0FFFFFF05h; switch 5 cases
mov ecx, eax
mov [rbp+var_20], rcx
sub eax, 4
ja def_4EB4E; jumptable 000000000004EB4E default case
mov rax, [rbp+var_20]
lea rcx, jpt_4EB4E
movsxd rax, ds:(jpt_4EB4E - 189FE0h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_4EB50:
mov rax, [rbp+var_10]; jumptable 000000000004EB4E case 251
mov rcx, [rax]
add rcx, 3
mov [rax], rcx
mov rax, [rbp+var_10]
mov rax, [rax]
movzx eax, word ptr [rax-2]
mov [rbp+var_4], eax
jmp short loc_4EBEB
loc_4EB6E:
mov rax, [rbp+var_10]; jumptable 000000000004EB4E case 252
mov rcx, [rax]
add rcx, 4
mov [rax], rcx
mov rax, [rbp+var_10]
mov rax, [rax]
movzx eax, byte ptr [rax-3]
mov rcx, [rbp+var_10]
mov rcx, [rcx]
movzx ecx, byte ptr [rcx-2]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_10]
mov rcx, [rcx]
movzx ecx, byte ptr [rcx-1]
shl ecx, 10h
or eax, ecx
mov [rbp+var_4], eax
jmp short loc_4EBEB
loc_4EBAC:
mov rax, [rbp+var_10]; jumptable 000000000004EB4E case 253
mov rcx, [rax]
add rcx, 5
mov [rax], rcx
mov rax, [rbp+var_10]
mov rax, [rax]
mov eax, [rax-4]
mov [rbp+var_4], eax
jmp short loc_4EBEB
loc_4EBC9:
jmp short $+2; jumptable 000000000004EB4E cases 254,255
loc_4EBCB:
jmp short $+2
loc_4EBCD:
mov [rbp+var_4], 0
jmp short loc_4EBEB
def_4EB4E:
mov rax, [rbp+var_10]; jumptable 000000000004EB4E default case
mov rcx, [rax]
add rcx, 1
mov [rax], rcx
movzx eax, [rbp+var_11]
mov [rbp+var_4], eax
loc_4EBEB:
mov eax, [rbp+var_4]
pop rbp
retn
| long long translog_variable_record_1group_decode_len(unsigned __int8 **a1)
{
unsigned __int8 v2; // [rsp+Fh] [rbp-11h]
unsigned int v3; // [rsp+1Ch] [rbp-4h]
v2 = **a1;
switch ( v2 )
{
case 0xFBu:
*a1 += 3;
v3 = *((unsigned __int16 *)*a1 - 1);
break;
case 0xFCu:
*a1 += 4;
v3 = (*(*a1 - 1) << 16) | *(unsigned __int16 *)(*a1 - 3);
break;
case 0xFDu:
*a1 += 5;
v3 = *((_DWORD *)*a1 - 1);
break;
case 0xFEu:
case 0xFFu:
v3 = 0;
break;
default:
++*a1;
v3 = v2;
break;
}
return v3;
}
| translog_variable_record_1group_decode_len:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV AL,byte ptr [RAX]
MOV byte ptr [RBP + -0x11],AL
MOVZX EAX,byte ptr [RBP + -0x11]
ADD EAX,0xffffff05
MOV ECX,EAX
MOV qword ptr [RBP + -0x20],RCX
SUB EAX,0x4
JA 0x0014ebd6
MOV RAX,qword ptr [RBP + -0x20]
LEA RCX,[0x289fe0]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_fb:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX]
ADD RCX,0x3
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOVZX EAX,word ptr [RAX + -0x2]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014ebeb
caseD_fc:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX]
ADD RCX,0x4
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOVZX EAX,byte ptr [RAX + -0x3]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX]
MOVZX ECX,byte ptr [RCX + -0x2]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX]
MOVZX ECX,byte ptr [RCX + -0x1]
SHL ECX,0x10
OR EAX,ECX
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014ebeb
caseD_fd:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX]
ADD RCX,0x5
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX + -0x4]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014ebeb
caseD_fe:
JMP 0x0014ebcb
LAB_0014ebcb:
JMP 0x0014ebcd
LAB_0014ebcd:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0014ebeb
default:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX]
ADD RCX,0x1
MOV qword ptr [RAX],RCX
MOVZX EAX,byte ptr [RBP + -0x11]
MOV dword ptr [RBP + -0x4],EAX
LAB_0014ebeb:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
uint translog_variable_record_1group_decode_len(long *param_1)
{
byte bVar1;
uint local_c;
bVar1 = *(byte *)*param_1;
switch(bVar1) {
case 0xfb:
*param_1 = *param_1 + 3;
local_c = (uint)*(ushort *)(*param_1 + -2);
break;
case 0xfc:
*param_1 = *param_1 + 4;
local_c = (uint)CONCAT12(*(int1 *)(*param_1 + -1),
CONCAT11(*(int1 *)(*param_1 + -2),*(int1 *)(*param_1 + -3))
);
break;
case 0xfd:
*param_1 = *param_1 + 5;
local_c = *(uint *)(*param_1 + -4);
break;
case 0xfe:
case 0xff:
local_c = 0;
break;
default:
*param_1 = *param_1 + 1;
local_c = (uint)bVar1;
}
return local_c;
}
| |
21,408 | js_string_fromCharCode | bluesky950520[P]quickjs/quickjs.c | static JSValue js_string_fromCharCode(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
int i;
StringBuffer b_s, *b = &b_s;
// shortcut for single argument common case
if (argc == 1 && JS_VALUE_GET_TAG(argv[0]) == JS_TAG_INT) {
uint16_t c16 = JS_VALUE_GET_INT(argv[0]);
return js_new_string_char(ctx, c16);
}
string_buffer_init(ctx, b, argc);
for(i = 0; i < argc; i++) {
int32_t c;
if (JS_ToInt32(ctx, &c, argv[i]) || string_buffer_putc16(b, c & 0xffff)) {
string_buffer_free(b);
return JS_EXCEPTION;
}
}
return string_buffer_end(b);
} | O0 | c | js_string_fromCharCode:
subq $0x78, %rsp
movq %rsi, 0x58(%rsp)
movq %rdx, 0x60(%rsp)
movq %rdi, 0x50(%rsp)
movl %ecx, 0x4c(%rsp)
movq %r8, 0x40(%rsp)
leaq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
cmpl $0x1, 0x4c(%rsp)
jne 0xd89d5
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rax
cmpl $0x0, %eax
jne 0xd89d5
movq 0x40(%rsp), %rax
movl (%rax), %eax
movw %ax, 0xe(%rsp)
movq 0x50(%rsp), %rdi
movzwl 0xe(%rsp), %esi
callq 0x66740
movq %rax, 0x68(%rsp)
movq %rdx, 0x70(%rsp)
jmp 0xd8a7f
movq 0x50(%rsp), %rdi
movq 0x10(%rsp), %rsi
movl 0x4c(%rsp), %edx
callq 0x56930
movl $0x0, 0x3c(%rsp)
movl 0x3c(%rsp), %eax
cmpl 0x4c(%rsp), %eax
jge 0xd8a6b
movq 0x50(%rsp), %rdi
movq 0x40(%rsp), %rax
movslq 0x3c(%rsp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rdx
movq 0x8(%rax), %rcx
leaq 0x8(%rsp), %rsi
callq 0x3f210
cmpl $0x0, %eax
jne 0xd8a3f
movq 0x10(%rsp), %rdi
movl 0x8(%rsp), %esi
andl $0xffff, %esi # imm = 0xFFFF
callq 0x84980
cmpl $0x0, %eax
je 0xd8a5c
movq 0x10(%rsp), %rdi
callq 0x587a0
movl $0x0, 0x68(%rsp)
movq $0x6, 0x70(%rsp)
jmp 0xd8a7f
jmp 0xd8a5e
movl 0x3c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x3c(%rsp)
jmp 0xd89f0
movq 0x10(%rsp), %rdi
callq 0x53df0
movq %rax, 0x68(%rsp)
movq %rdx, 0x70(%rsp)
movq 0x68(%rsp), %rax
movq 0x70(%rsp), %rdx
addq $0x78, %rsp
retq
nop
| js_string_fromCharCode:
sub rsp, 78h
mov [rsp+78h+var_20], rsi
mov [rsp+78h+var_18], rdx
mov [rsp+78h+var_28], rdi
mov [rsp+78h+var_2C], ecx
mov [rsp+78h+var_38], r8
lea rax, [rsp+78h+var_60]
mov [rsp+78h+var_68], rax
cmp [rsp+78h+var_2C], 1
jnz short loc_D89D5
mov rax, [rsp+78h+var_38]
mov rax, [rax+8]
cmp eax, 0
jnz short loc_D89D5
mov rax, [rsp+78h+var_38]
mov eax, [rax]
mov [rsp+78h+var_6A], ax
mov rdi, [rsp+78h+var_28]
movzx esi, [rsp+78h+var_6A]
call js_new_string_char
mov [rsp+78h+var_10], rax
mov [rsp+78h+var_8], rdx
jmp loc_D8A7F
loc_D89D5:
mov rdi, [rsp+78h+var_28]
mov rsi, [rsp+78h+var_68]
mov edx, [rsp+78h+var_2C]
call string_buffer_init
mov [rsp+78h+var_3C], 0
loc_D89F0:
mov eax, [rsp+78h+var_3C]
cmp eax, [rsp+78h+var_2C]
jge short loc_D8A6B
mov rdi, [rsp+78h+var_28]
mov rax, [rsp+78h+var_38]
movsxd rcx, [rsp+78h+var_3C]
shl rcx, 4
add rax, rcx
mov rdx, [rax]
mov rcx, [rax+8]
lea rsi, [rsp+78h+var_70]
call JS_ToInt32
cmp eax, 0
jnz short loc_D8A3F
mov rdi, [rsp+78h+var_68]
mov esi, [rsp+78h+var_70]
and esi, 0FFFFh
call string_buffer_putc16
cmp eax, 0
jz short loc_D8A5C
loc_D8A3F:
mov rdi, [rsp+78h+var_68]
call string_buffer_free
mov dword ptr [rsp+78h+var_10], 0
mov [rsp+78h+var_8], 6
jmp short loc_D8A7F
loc_D8A5C:
jmp short $+2
loc_D8A5E:
mov eax, [rsp+78h+var_3C]
add eax, 1
mov [rsp+78h+var_3C], eax
jmp short loc_D89F0
loc_D8A6B:
mov rdi, [rsp+78h+var_68]
call string_buffer_end
mov [rsp+78h+var_10], rax
mov [rsp+78h+var_8], rdx
loc_D8A7F:
mov rax, [rsp+78h+var_10]
mov rdx, [rsp+78h+var_8]
add rsp, 78h
retn
| long long js_string_fromCharCode(long long a1, long long a2, long long a3, signed int a4, long long a5)
{
long long v5; // rdx
long long v6; // rdx
int v8; // [rsp+8h] [rbp-70h] BYREF
long long *v9; // [rsp+10h] [rbp-68h]
char v10; // [rsp+18h] [rbp-60h] BYREF
signed int i; // [rsp+3Ch] [rbp-3Ch]
long long v12; // [rsp+40h] [rbp-38h]
signed int v13; // [rsp+4Ch] [rbp-2Ch]
long long v14; // [rsp+50h] [rbp-28h]
long long v15; // [rsp+58h] [rbp-20h]
long long v16; // [rsp+60h] [rbp-18h]
long long v17; // [rsp+68h] [rbp-10h]
long long v18; // [rsp+70h] [rbp-8h]
v15 = a2;
v16 = a3;
v14 = a1;
v13 = a4;
v12 = a5;
v9 = (long long *)&v10;
if ( a4 != 1 || (unsigned int)*(_QWORD *)(v12 + 8) )
{
string_buffer_init(v14, (long long)v9, v13);
for ( i = 0; i < v13; ++i )
{
if ( (unsigned int)JS_ToInt32(v14, (long long)&v8, *(_DWORD **)(16LL * i + v12), *(_QWORD *)(16LL * i + v12 + 8))
|| (unsigned int)string_buffer_putc16((long long)v9, (unsigned __int16)v8) )
{
string_buffer_free(v9);
LODWORD(v17) = 0;
v18 = 6LL;
return v17;
}
}
v17 = string_buffer_end((long long)v9);
v18 = v6;
}
else
{
v17 = js_new_string_char(v14, *(_DWORD *)v12);
v18 = v5;
}
return v17;
}
| js_string_fromCharCode:
SUB RSP,0x78
MOV qword ptr [RSP + 0x58],RSI
MOV qword ptr [RSP + 0x60],RDX
MOV qword ptr [RSP + 0x50],RDI
MOV dword ptr [RSP + 0x4c],ECX
MOV qword ptr [RSP + 0x40],R8
LEA RAX,[RSP + 0x18]
MOV qword ptr [RSP + 0x10],RAX
CMP dword ptr [RSP + 0x4c],0x1
JNZ 0x001d89d5
MOV RAX,qword ptr [RSP + 0x40]
MOV RAX,qword ptr [RAX + 0x8]
CMP EAX,0x0
JNZ 0x001d89d5
MOV RAX,qword ptr [RSP + 0x40]
MOV EAX,dword ptr [RAX]
MOV word ptr [RSP + 0xe],AX
MOV RDI,qword ptr [RSP + 0x50]
MOVZX ESI,word ptr [RSP + 0xe]
CALL 0x00166740
MOV qword ptr [RSP + 0x68],RAX
MOV qword ptr [RSP + 0x70],RDX
JMP 0x001d8a7f
LAB_001d89d5:
MOV RDI,qword ptr [RSP + 0x50]
MOV RSI,qword ptr [RSP + 0x10]
MOV EDX,dword ptr [RSP + 0x4c]
CALL 0x00156930
MOV dword ptr [RSP + 0x3c],0x0
LAB_001d89f0:
MOV EAX,dword ptr [RSP + 0x3c]
CMP EAX,dword ptr [RSP + 0x4c]
JGE 0x001d8a6b
MOV RDI,qword ptr [RSP + 0x50]
MOV RAX,qword ptr [RSP + 0x40]
MOVSXD RCX,dword ptr [RSP + 0x3c]
SHL RCX,0x4
ADD RAX,RCX
MOV RDX,qword ptr [RAX]
MOV RCX,qword ptr [RAX + 0x8]
LEA RSI,[RSP + 0x8]
CALL 0x0013f210
CMP EAX,0x0
JNZ 0x001d8a3f
MOV RDI,qword ptr [RSP + 0x10]
MOV ESI,dword ptr [RSP + 0x8]
AND ESI,0xffff
CALL 0x00184980
CMP EAX,0x0
JZ 0x001d8a5c
LAB_001d8a3f:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x001587a0
MOV dword ptr [RSP + 0x68],0x0
MOV qword ptr [RSP + 0x70],0x6
JMP 0x001d8a7f
LAB_001d8a5c:
JMP 0x001d8a5e
LAB_001d8a5e:
MOV EAX,dword ptr [RSP + 0x3c]
ADD EAX,0x1
MOV dword ptr [RSP + 0x3c],EAX
JMP 0x001d89f0
LAB_001d8a6b:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x00153df0
MOV qword ptr [RSP + 0x68],RAX
MOV qword ptr [RSP + 0x70],RDX
LAB_001d8a7f:
MOV RAX,qword ptr [RSP + 0x68]
MOV RDX,qword ptr [RSP + 0x70]
ADD RSP,0x78
RET
|
int1 [16]
js_string_fromCharCode
(int8 param_1,int8 param_2,int8 param_3,int param_4,int4 *param_5)
{
int iVar1;
int1 auVar2 [16];
uint local_70;
int2 local_6a;
int1 *local_68;
int1 local_60 [36];
int local_3c;
int4 *local_38;
int local_2c;
int8 local_28;
int8 local_20;
int8 local_18;
int4 local_10;
int4 uStack_c;
int8 local_8;
local_68 = local_60;
local_38 = param_5;
local_2c = param_4;
local_28 = param_1;
local_20 = param_2;
local_18 = param_3;
if ((param_4 == 1) && ((int)*(int8 *)(param_5 + 2) == 0)) {
local_6a = (int2)*param_5;
auVar2 = js_new_string_char(param_1,local_6a);
local_8 = auVar2._8_8_;
local_10 = auVar2._0_4_;
uStack_c = auVar2._4_4_;
}
else {
string_buffer_init(param_1,local_68,param_4);
for (local_3c = 0; local_3c < local_2c; local_3c = local_3c + 1) {
iVar1 = JS_ToInt32(local_28,&local_70,*(int8 *)(local_38 + (long)local_3c * 4),
*(int8 *)((long)(local_38 + (long)local_3c * 4) + 8));
if (iVar1 != 0) {
LAB_001d8a3f:
string_buffer_free(local_68);
local_10 = 0;
local_8 = 6;
goto LAB_001d8a7f;
}
iVar1 = string_buffer_putc16(local_68,local_70 & 0xffff);
if (iVar1 != 0) goto LAB_001d8a3f;
}
auVar2 = string_buffer_end(local_68);
local_8 = auVar2._8_8_;
local_10 = auVar2._0_4_;
uStack_c = auVar2._4_4_;
}
LAB_001d8a7f:
auVar2._4_4_ = uStack_c;
auVar2._0_4_ = local_10;
auVar2._8_8_ = local_8;
return auVar2;
}
| |
21,409 | DsMrr_impl::reset_buffer_sizes(void*) | eloqsql/sql/multi_range_read.cc | void DsMrr_impl::reset_buffer_sizes(void *dsmrr_arg)
{
DsMrr_impl *dsmrr= (DsMrr_impl*)dsmrr_arg;
dsmrr->rowid_buffer.set_buffer_space(dsmrr->full_buf,
dsmrr->rowid_buffer_end);
dsmrr->key_buffer->set_buffer_space(dsmrr->rowid_buffer_end,
dsmrr->full_buf_end);
} | O0 | cpp | DsMrr_impl::reset_buffer_sizes(void*):
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
addq $0x248, %rdi # imm = 0x248
movq -0x10(%rbp), %rax
movq 0x180(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x190(%rax), %rdx
callq 0xba4060
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x190(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x188(%rax), %rdx
callq 0xba4060
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _ZN10DsMrr_impl18reset_buffer_sizesEPv:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov [rbp+var_10], rax
mov rdi, [rbp+var_10]
add rdi, 248h; this
mov rax, [rbp+var_10]
mov rsi, [rax+180h]; unsigned __int8 *
mov rax, [rbp+var_10]
mov rdx, [rax+190h]; unsigned __int8 *
call _ZN11Lifo_buffer16set_buffer_spaceEPhS0_; Lifo_buffer::set_buffer_space(uchar *,uchar *)
mov rax, [rbp+var_10]
mov rdi, [rax]; this
mov rax, [rbp+var_10]
mov rsi, [rax+190h]; unsigned __int8 *
mov rax, [rbp+var_10]
mov rdx, [rax+188h]; unsigned __int8 *
call _ZN11Lifo_buffer16set_buffer_spaceEPhS0_; Lifo_buffer::set_buffer_space(uchar *,uchar *)
add rsp, 10h
pop rbp
retn
| long long DsMrr_impl::reset_buffer_sizes(unsigned __int8 **this, void *a2)
{
Lifo_buffer::set_buffer_space((Lifo_buffer *)(this + 73), this[48], this[50]);
return Lifo_buffer::set_buffer_space((Lifo_buffer *)*this, this[50], this[49]);
}
| ~I_List:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00956da0
ADD RSP,0x10
POP RBP
RET
|
/* I_List<thread_info>::~I_List() */
void __thiscall I_List<thread_info>::~I_List(I_List<thread_info> *this)
{
base_ilist::~base_ilist((base_ilist *)this);
return;
}
| |
21,410 | DsMrr_impl::reset_buffer_sizes(void*) | eloqsql/sql/multi_range_read.cc | void DsMrr_impl::reset_buffer_sizes(void *dsmrr_arg)
{
DsMrr_impl *dsmrr= (DsMrr_impl*)dsmrr_arg;
dsmrr->rowid_buffer.set_buffer_space(dsmrr->full_buf,
dsmrr->rowid_buffer_end);
dsmrr->key_buffer->set_buffer_space(dsmrr->rowid_buffer_end,
dsmrr->full_buf_end);
} | O3 | cpp | DsMrr_impl::reset_buffer_sizes(void*):
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
addq $0x248, %rdi # imm = 0x248
movq 0x180(%rbx), %rax
movq 0x190(%rbx), %rcx
movq %rax, 0x280(%rbx)
movq %rcx, 0x288(%rbx)
movq 0x248(%rbx), %rax
callq *0x18(%rax)
movq (%rbx), %rdi
movdqu 0x188(%rbx), %xmm0
pshufd $0x4e, %xmm0, %xmm0 # xmm0 = xmm0[2,3,0,1]
movdqu %xmm0, 0x38(%rdi)
movq (%rdi), %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
jmpq *0x18(%rax)
nop
| _ZN10DsMrr_impl18reset_buffer_sizesEPv:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdi
add rdi, 248h
mov rax, [rbx+180h]
mov rcx, [rbx+190h]
mov [rbx+280h], rax
mov [rbx+288h], rcx
mov rax, [rbx+248h]
call qword ptr [rax+18h]
mov rdi, [rbx]
movdqu xmm0, xmmword ptr [rbx+188h]
pshufd xmm0, xmm0, 4Eh ; 'N'
movdqu xmmword ptr [rdi+38h], xmm0
mov rax, [rdi]
add rsp, 8
pop rbx
pop rbp
jmp qword ptr [rax+18h]
| long long DsMrr_impl::reset_buffer_sizes(DsMrr_impl *this, void *a2)
{
long long v3; // rcx
long long v4; // rdi
v3 = *((_QWORD *)this + 50);
*((_QWORD *)this + 80) = *((_QWORD *)this + 48);
*((_QWORD *)this + 81) = v3;
(*(void ( **)(char *, void *))(*((_QWORD *)this + 73) + 24LL))((char *)this + 584, a2);
v4 = *(_QWORD *)this;
*(__m128i *)(v4 + 56) = _mm_shuffle_epi32(_mm_loadu_si128((const __m128i *)((char *)this + 392)), 78);
return (*(long long ( **)(long long))(*(_QWORD *)v4 + 24LL))(v4);
}
| |||
21,411 | minja::Value::contains(char const*) const | monkey531[P]llama/common/minja.hpp | bool contains(const char * key) const { return contains(std::string(key)); } | O3 | cpp | minja::Value::contains(char const*) const:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
leaq 0x7(%rsp), %rdx
movq %r14, %rdi
callq 0x526fe
movq %rbx, %rdi
movq %r14, %rsi
callq 0x934d0
movl %eax, %ebx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xad1aa
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1b8b0
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r14
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xad1d2
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1b8b0
movq %rbx, %rdi
callq 0x1bf70
| _ZNK5minja5Value8containsEPKc:
push r14
push rbx
sub rsp, 28h
mov rbx, rdi
lea r14, [rsp+38h+var_30]
lea rdx, [rsp+38h+var_31]
mov rdi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
mov rdi, rbx
mov rsi, r14
call _ZNK5minja5Value8containsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; minja::Value::contains(std::string const&)
mov ebx, eax
lea rax, [rsp+38h+var_20]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_AD1AA
mov rsi, [rsp+38h+var_20]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_AD1AA:
mov eax, ebx
add rsp, 28h
pop rbx
pop r14
retn
mov rbx, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_AD1D2
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_AD1D2:
mov rdi, rbx
call __Unwind_Resume
| long long minja::Value::contains(minja::Value *this, char *a2)
{
unsigned int v2; // eax
unsigned int v3; // ebx
void *v5[2]; // [rsp+8h] [rbp-30h] BYREF
long long v6; // [rsp+18h] [rbp-20h] BYREF
std::string::basic_string<std::allocator<char>>(v5, a2);
LOBYTE(v2) = minja::Value::contains((long long)this, (long long)v5);
v3 = v2;
if ( v5[0] != &v6 )
operator delete(v5[0], v6 + 1);
return v3;
}
| contains:
PUSH R14
PUSH RBX
SUB RSP,0x28
MOV RBX,RDI
LEA R14,[RSP + 0x8]
LEA RDX,[RSP + 0x7]
MOV RDI,R14
CALL 0x001526fe
LAB_001ad182:
MOV RDI,RBX
MOV RSI,R14
CALL 0x001934d0
LAB_001ad18d:
MOV EBX,EAX
LEA RAX,[RSP + 0x18]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x001ad1aa
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011b8b0
LAB_001ad1aa:
MOV EAX,EBX
ADD RSP,0x28
POP RBX
POP R14
RET
|
/* minja::Value::contains(char const*) const */
int4 __thiscall minja::Value::contains(Value *this,char *param_1)
{
int4 uVar1;
allocator local_31;
long *local_30 [2];
long local_20 [2];
std::__cxx11::string::string<std::allocator<char>>((string *)local_30,param_1,&local_31);
/* try { // try from 001ad182 to 001ad18c has its CatchHandler @ 001ad1b4 */
uVar1 = contains(this,(string *)local_30);
if (local_30[0] != local_20) {
operator_delete(local_30[0],local_20[0] + 1);
}
return uVar1;
}
| |
21,412 | refreshMultiLine(linenoiseState*, int) | llama.cpp/examples/run/linenoise.cpp/linenoise.cpp | static void refreshMultiLine(struct linenoiseState *l, int flags) {
char seq[64];
size_t pcollen = promptTextColumnLen(l->prompt, strlen(l->prompt));
int colpos = columnPosForMultiLine(l->buf, l->len, l->len, l->cols, pcollen);
int colpos2; /* cursor column position. */
int rows = (pcollen + colpos + l->cols - 1) / l->cols; /* rows used by current buf. */
int rpos = (pcollen + l->oldcolpos + l->cols) / l->cols; /* cursor relative row. */
int rpos2; /* rpos after refresh. */
int col; /* column position, zero-based. */
int old_rows = l->oldrows;
int fd = l->ofd, j;
std::string ab;
l->oldrows = rows;
/* First step: clear all the lines used before. To do so start by
* going to the last row. */
if (flags & REFRESH_CLEAN) {
if (old_rows - rpos > 0) {
snprintf(seq,64,"\x1b[%dB", old_rows-rpos);
ab.append(seq);
}
/* Now for every row clear it, go up. */
for (j = 0; j < old_rows - 1; j++) {
snprintf(seq,64,"\r\x1b[0K\x1b[1A");
ab.append(seq);
}
}
if (flags & REFRESH_ALL) {
/* Clean the top line. */
snprintf(seq,64,"\r\x1b[0K");
ab.append(seq);
}
/* Get column length to cursor position */
colpos2 = columnPosForMultiLine(l->buf, l->len, l->pos, l->cols, pcollen);
if (flags & REFRESH_WRITE) {
/* Write the prompt and the current buffer content */
ab.append(l->prompt);
if (maskmode == 1) {
for (unsigned int i = 0; i < l->len; ++i) {
ab.append("*");
}
} else {
ab.append(l->buf, l->len);
}
/* Show hits if any. */
refreshShowHints(ab, l, pcollen);
/* If we are at the very end of the screen with our prompt, we need to
* emit a newline and move the prompt to the first column. */
if (l->pos && l->pos == l->len && (colpos2 + pcollen) % l->cols == 0) {
ab.append("\n");
snprintf(seq,64,"\r");
ab.append(seq);
rows++;
if (rows > (int)l->oldrows) l->oldrows = rows;
}
/* Move cursor to right position. */
rpos2 = (pcollen + colpos2 + l->cols) / l->cols; /* Current cursor relative row */
/* Go up till we reach the expected position. */
if (rows - rpos2 > 0) {
snprintf(seq,64,"\x1b[%dA", rows-rpos2);
ab.append(seq);
}
/* Set column. */
col = (pcollen + colpos2) % l->cols;
if (col)
snprintf(seq,64,"\r\x1b[%dC", col);
else
snprintf(seq,64,"\r");
ab.append(seq);
}
l->oldcolpos = colpos2;
(void) !write(fd, ab.c_str(), ab.size()); /* Can't recover from write error. */
} | O3 | cpp | refreshMultiLine(linenoiseState*, int):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movl %esi, %r12d
movq %rdi, %rbx
movq 0x28(%rdi), %r14
movq %r14, %rdi
callq 0x1d550
movq %r14, %rdi
movq %rax, %rsi
callq 0x33d92
movq %rax, %r14
movq 0x18(%rbx), %rdi
movq 0x48(%rbx), %rdx
movq 0x50(%rbx), %rcx
movq %rdx, %rsi
movq %rax, %r8
callq 0x33e5b
cltq
movq 0x50(%rbx), %rsi
movq %r14, 0x38(%rsp)
leaq (%rsi,%r14), %rcx
addq %rcx, %rax
decq %rax
xorl %edx, %edx
divq %rsi
movq 0x40(%rbx), %rdi
movl 0x58(%rbx), %r15d
movl 0x14(%rbx), %edx
movl %edx, 0x34(%rsp)
leaq 0x20(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq $0x0, -0x8(%rdx)
movb $0x0, (%rdx)
movq %rax, 0x8(%rsp)
movslq %eax, %rdx
movq %rdx, 0x58(%rbx)
testb $0x1, %r12b
je 0x3230c
addq %rdi, %rcx
movq %rcx, %rax
xorl %edx, %edx
divq %rsi
movl %r15d, %ecx
subl %eax, %ecx
jle 0x322d3
leaq 0x9dc38(%rip), %rdx # 0xcfeea
leaq 0x40(%rsp), %r13
movl $0x40, %esi
movq %r13, %rdi
xorl %eax, %eax
callq 0x1d6f0
leaq 0x10(%rsp), %rdi
movq %r13, %rsi
callq 0x1d920
cmpl $0x2, %r15d
jl 0x3230c
decl %r15d
movabsq $0x315b1b4b305b1b0d, %r14 # imm = 0x315B1B4B305B1B0D
leaq 0x10(%rsp), %r13
leaq 0x40(%rsp), %rbp
movq %r14, 0x40(%rsp)
movw $0x41, 0x48(%rsp)
movq %r13, %rdi
movq %rbp, %rsi
callq 0x1d920
decl %r15d
jne 0x322f0
testb $0x3, %r12b
movq 0x38(%rsp), %r14
je 0x32332
leaq 0x40(%rsp), %rsi
movw $0x4b, 0x4(%rsi)
movl $0x305b1b0d, (%rsi) # imm = 0x305B1B0D
leaq 0x10(%rsp), %rdi
callq 0x1d920
movq 0x48(%rbx), %rsi
movq 0x18(%rbx), %rdi
movq 0x38(%rbx), %rdx
movq 0x50(%rbx), %rcx
movq %r14, %r8
callq 0x33e5b
movq %rax, %r13
testb $0x2, %r12b
jne 0x3235b
movslq %r13d, %r12
jmp 0x32473
movq 0x28(%rbx), %rsi
leaq 0x10(%rsp), %rdi
callq 0x1d920
cmpb $0x1, 0xd9a28(%rip) # 0x10bd98
jne 0x323a4
cmpq $0x0, 0x48(%rbx)
je 0x323b6
movl $0x1, %r15d
leaq 0xa1893(%rip), %r12 # 0xd3c19
leaq 0x10(%rsp), %rbp
movq %rbp, %rdi
movq %r12, %rsi
callq 0x1d920
movl %r15d, %eax
incl %r15d
cmpq %rax, 0x48(%rbx)
ja 0x3238b
jmp 0x323b6
movq 0x18(%rbx), %rsi
movq 0x48(%rbx), %rdx
leaq 0x10(%rsp), %rdi
callq 0x1d470
leaq 0x10(%rsp), %rdi
movq %rbx, %rsi
movl %r14d, %edx
callq 0x33eee
movq 0x38(%rbx), %rax
testq %rax, %rax
je 0x323ea
cmpq 0x48(%rbx), %rax
jne 0x323ea
movslq %r13d, %rax
addq %r14, %rax
xorl %edx, %edx
divq 0x50(%rbx)
testq %rdx, %rdx
je 0x324b8
movq 0x8(%rsp), %rax
movl %eax, %ecx
movslq %r13d, %r12
addq %r12, %r14
movq 0x50(%rbx), %rsi
leaq (%rsi,%r14), %rax
xorl %edx, %edx
divq %rsi
subl %eax, %ecx
jle 0x32434
leaq 0x9daf1(%rip), %rdx # 0xcff00
leaq 0x40(%rsp), %r15
movl $0x40, %esi
movq %r15, %rdi
xorl %eax, %eax
callq 0x1d6f0
leaq 0x10(%rsp), %rdi
movq %r15, %rsi
callq 0x1d920
movq 0x50(%rbx), %rsi
movq %r14, %rax
xorl %edx, %edx
divq %rsi
movq %rdx, %rcx
testl %ecx, %ecx
je 0x3245d
leaq 0x9dabc(%rip), %rdx # 0xcff06
leaq 0x40(%rsp), %rdi
movl $0x40, %esi
xorl %eax, %eax
callq 0x1d6f0
jmp 0x32464
movw $0xd, 0x40(%rsp)
leaq 0x10(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0x1d920
movq %r12, 0x40(%rbx)
movq 0x10(%rsp), %rsi
movq 0x18(%rsp), %rdx
movl 0x34(%rsp), %edi
callq 0x1de70
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x324a6
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x1d160
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xa00d0(%rip), %rsi # 0xd258f
leaq 0x10(%rsp), %rdi
callq 0x1d920
leaq 0x40(%rsp), %rsi
movw $0xd, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x1d920
movq 0x8(%rsp), %rax
leal 0x1(%rax), %ecx
cmpl 0x58(%rbx), %eax
jl 0x323f1
movslq %ecx, %rax
movq %rax, 0x58(%rbx)
jmp 0x323f1
jmp 0x324fe
jmp 0x324fe
movq %rax, %rbx
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x3251d
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x1d160
movq %rbx, %rdi
callq 0x1d8e0
| _ZL16refreshMultiLineP14linenoiseStatei:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 88h
mov r12d, esi
mov rbx, rdi
mov r14, [rdi+28h]
mov rdi, r14
call _strlen
mov rdi, r14; char *
mov rsi, rax; unsigned __int64
call _ZL19promptTextColumnLenPKcm; promptTextColumnLen(char const*,ulong)
mov r14, rax
mov rdi, [rbx+18h]; char *
mov rdx, [rbx+48h]; unsigned __int64
mov rcx, [rbx+50h]; unsigned __int64
mov rsi, rdx; unsigned __int64
mov r8, rax; unsigned __int64
call _ZL21columnPosForMultiLinePKcmmmm; columnPosForMultiLine(char const*,ulong,ulong,ulong,ulong)
cdqe
mov rsi, [rbx+50h]
mov [rsp+0B8h+var_80], r14
lea rcx, [rsi+r14]
add rax, rcx
dec rax
xor edx, edx
div rsi
mov rdi, [rbx+40h]
mov r15d, [rbx+58h]
mov edx, [rbx+14h]
mov [rsp+0B8h+var_84], edx
lea rdx, [rsp+0B8h+var_98]
mov [rdx-10h], rdx
mov qword ptr [rdx-8], 0
mov byte ptr [rdx], 0
mov [rsp+0B8h+var_B0], rax
movsxd rdx, eax
mov [rbx+58h], rdx
test r12b, 1
jz short loc_3230C
add rcx, rdi
mov rax, rcx
xor edx, edx
div rsi
mov ecx, r15d
sub ecx, eax
jle short loc_322D3
lea rdx, aDb; "\x1B[%dB"
lea r13, [rsp+0B8h+var_78]
mov esi, 40h ; '@'
mov rdi, r13
xor eax, eax
call _snprintf
lea rdi, [rsp+0B8h+var_A8]
mov rsi, r13
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
loc_322D3:
cmp r15d, 2
jl short loc_3230C
dec r15d
mov r14, 315B1B4B305B1B0Dh
lea r13, [rsp+0B8h+var_A8]
lea rbp, [rsp+0B8h+var_78]
loc_322F0:
mov [rsp+0B8h+var_78], r14
mov [rsp+0B8h+var_70], 41h ; 'A'
mov rdi, r13
mov rsi, rbp
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
dec r15d
jnz short loc_322F0
loc_3230C:
test r12b, 3
mov r14, [rsp+0B8h+var_80]
jz short loc_32332
lea rsi, [rsp+0B8h+var_78]
mov word ptr [rsi+4], 4Bh ; 'K'
mov dword ptr [rsi], 305B1B0Dh
lea rdi, [rsp+0B8h+var_A8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
loc_32332:
mov rsi, [rbx+48h]; unsigned __int64
mov rdi, [rbx+18h]; char *
mov rdx, [rbx+38h]; unsigned __int64
mov rcx, [rbx+50h]; unsigned __int64
mov r8, r14; unsigned __int64
call _ZL21columnPosForMultiLinePKcmmmm; columnPosForMultiLine(char const*,ulong,ulong,ulong,ulong)
mov r13, rax
test r12b, 2
jnz short loc_3235B
movsxd r12, r13d
jmp loc_32473
loc_3235B:
mov rsi, [rbx+28h]
lea rdi, [rsp+0B8h+var_A8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
cmp cs:_ZL8maskmode, 1; maskmode
jnz short loc_323A4
cmp qword ptr [rbx+48h], 0
jz short loc_323B6
mov r15d, 1
lea r12, asc_D3C18+1; "*"
lea rbp, [rsp+0B8h+var_A8]
loc_3238B:
mov rdi, rbp
mov rsi, r12
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov eax, r15d
inc r15d
cmp [rbx+48h], rax
ja short loc_3238B
jmp short loc_323B6
loc_323A4:
mov rsi, [rbx+18h]
mov rdx, [rbx+48h]
lea rdi, [rsp+0B8h+var_A8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKcm; std::string::append(char const*,ulong)
loc_323B6:
lea rdi, [rsp+0B8h+var_A8]
mov rsi, rbx
mov edx, r14d
call _ZL16refreshShowHintsRNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP14linenoiseStatei; refreshShowHints(std::string &,linenoiseState *,int)
mov rax, [rbx+38h]
test rax, rax
jz short loc_323EA
cmp rax, [rbx+48h]
jnz short loc_323EA
movsxd rax, r13d
add rax, r14
xor edx, edx
div qword ptr [rbx+50h]
test rdx, rdx
jz loc_324B8
loc_323EA:
mov rax, [rsp+0B8h+var_B0]
mov ecx, eax
loc_323F1:
movsxd r12, r13d
add r14, r12
mov rsi, [rbx+50h]
lea rax, [rsi+r14]
xor edx, edx
div rsi
sub ecx, eax
jle short loc_32434
lea rdx, aDa; "\x1B[%dA"
lea r15, [rsp+0B8h+var_78]
mov esi, 40h ; '@'
mov rdi, r15
xor eax, eax
call _snprintf
lea rdi, [rsp+0B8h+var_A8]
mov rsi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov rsi, [rbx+50h]
loc_32434:
mov rax, r14
xor edx, edx
div rsi
mov rcx, rdx
test ecx, ecx
jz short loc_3245D
lea rdx, aDc; "\r\x1B[%dC"
lea rdi, [rsp+0B8h+var_78]
mov esi, 40h ; '@'
xor eax, eax
call _snprintf
jmp short loc_32464
loc_3245D:
mov word ptr [rsp+0B8h+var_78], 0Dh
loc_32464:
lea rdi, [rsp+0B8h+var_A8]
lea rsi, [rsp+0B8h+var_78]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
loc_32473:
mov [rbx+40h], r12
mov rsi, [rsp+0B8h+var_A8]
mov rdx, [rsp+0B8h+var_A0]
mov edi, [rsp+0B8h+var_84]
call _write
mov rdi, [rsp+0B8h+var_A8]; void *
lea rax, [rsp+0B8h+var_98]
cmp rdi, rax
jz short loc_324A6
mov rsi, [rsp+0B8h+var_98]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_324A6:
add rsp, 88h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_324B8:
lea rsi, aExampleToolCal+1Ch; "\n"
lea rdi, [rsp+0B8h+var_A8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea rsi, [rsp+0B8h+var_78]
mov word ptr [rsi], 0Dh
lea rdi, [rsp+0B8h+var_A8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov rax, [rsp+0B8h+var_B0]
lea ecx, [rax+1]
cmp eax, [rbx+58h]
jl loc_323F1
movsxd rax, ecx
mov [rbx+58h], rax
jmp loc_323F1
jmp short loc_324FE
jmp short $+2
loc_324FE:
mov rbx, rax
mov rdi, [rsp+arg_8]; void *
lea rax, [rsp+arg_18]
cmp rdi, rax
jz short loc_3251D
mov rsi, [rsp+arg_18]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_3251D:
mov rdi, rbx
call __Unwind_Resume
| void refreshMultiLine(long long a1, char a2)
{
const char *v4; // r14
unsigned long long v5; // rax
unsigned long long v6; // r14
int v7; // eax
unsigned long long v8; // rsi
long long v9; // rdi
int v10; // r15d
unsigned long long v11; // rax
int v12; // r15d
unsigned long long v13; // r14
int v14; // eax
int v15; // r13d
long long v16; // r12
unsigned int v17; // r15d
unsigned long long v18; // rax
long long v19; // rax
int v20; // ecx
unsigned long long v21; // r14
unsigned long long v22; // rsi
unsigned long long v23; // rax
bool v24; // cc
int v25; // ecx
unsigned long long v26; // [rsp+8h] [rbp-B0h]
void *v27; // [rsp+10h] [rbp-A8h] BYREF
long long v28; // [rsp+18h] [rbp-A0h]
_QWORD v29[2]; // [rsp+20h] [rbp-98h] BYREF
unsigned int v30; // [rsp+34h] [rbp-84h]
unsigned long long v31; // [rsp+38h] [rbp-80h]
char v32[120]; // [rsp+40h] [rbp-78h] BYREF
v4 = *(const char **)(a1 + 40);
v5 = strlen(v4);
v6 = promptTextColumnLen(v4, v5);
v7 = columnPosForMultiLine(
*(const char **)(a1 + 24),
*(_QWORD *)(a1 + 72),
*(_QWORD *)(a1 + 72),
*(_QWORD *)(a1 + 80),
v6);
v8 = *(_QWORD *)(a1 + 80);
v31 = v6;
v9 = *(_QWORD *)(a1 + 64);
v10 = *(_DWORD *)(a1 + 88);
v30 = *(_DWORD *)(a1 + 20);
v27 = v29;
v28 = 0LL;
LOBYTE(v29[0]) = 0;
v26 = (v8 + v6 + v7 - 1) / v8;
*(_QWORD *)(a1 + 88) = (int)v26;
if ( (a2 & 1) != 0 )
{
v11 = (v9 + v8 + v6) / v8;
if ( v10 > (int)v11 )
{
snprintf(v32, 64LL, "\x1B[%dB", v10 - v11);
std::string::append(&v27, v32);
}
if ( v10 >= 2 )
{
v12 = v10 - 1;
do
{
strcpy(v32, "\r\x1B[0K\x1B[1A");
std::string::append(&v27, v32);
--v12;
}
while ( v12 );
}
}
v13 = v31;
if ( (a2 & 3) != 0 )
{
strcpy(v32, "\r\x1B[0K");
std::string::append(&v27, v32);
}
v14 = columnPosForMultiLine(
*(const char **)(a1 + 24),
*(_QWORD *)(a1 + 72),
*(_QWORD *)(a1 + 56),
*(_QWORD *)(a1 + 80),
v13);
v15 = v14;
if ( (a2 & 2) != 0 )
{
std::string::append(&v27, *(_QWORD *)(a1 + 40));
if ( maskmode == 1 )
{
if ( *(_QWORD *)(a1 + 72) )
{
v17 = 1;
do
{
std::string::append(&v27, "*");
v18 = v17++;
}
while ( *(_QWORD *)(a1 + 72) > v18 );
}
}
else
{
std::string::append(&v27, *(_QWORD *)(a1 + 24), *(_QWORD *)(a1 + 72));
}
refreshShowHints(&v27, a1, (unsigned int)v13);
v19 = *(_QWORD *)(a1 + 56);
if ( v19 && v19 == *(_QWORD *)(a1 + 72) && !((v13 + v15) % *(_QWORD *)(a1 + 80)) )
{
std::string::append(&v27, "\n");
strcpy(v32, "\r");
std::string::append(&v27, v32);
v20 = v26 + 1;
if ( (int)v26 >= *(_DWORD *)(a1 + 88) )
*(_QWORD *)(a1 + 88) = v20;
}
else
{
v20 = v26;
}
v16 = v15;
v21 = v15 + v13;
v22 = *(_QWORD *)(a1 + 80);
v23 = (v22 + v21) / v22;
v24 = v20 <= (int)v23;
v25 = v20 - v23;
if ( !v24 )
{
snprintf(v32, 64LL, "\x1B[%dA", v25);
std::string::append(&v27, v32);
v22 = *(_QWORD *)(a1 + 80);
}
if ( (unsigned int)(v21 % v22) )
snprintf(v32, 64LL, "\r\x1B[%dC", v21 % v22);
else
strcpy(v32, "\r");
std::string::append(&v27, v32);
}
else
{
v16 = v14;
}
*(_QWORD *)(a1 + 64) = v16;
write(v30, v27, v28);
if ( v27 != v29 )
operator delete(v27, v29[0] + 1LL);
}
| refreshMultiLine:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x88
MOV R12D,ESI
MOV RBX,RDI
MOV R14,qword ptr [RDI + 0x28]
MOV RDI,R14
CALL 0x0011d550
MOV RDI,R14
MOV RSI,RAX
CALL 0x00133d92
MOV R14,RAX
MOV RDI,qword ptr [RBX + 0x18]
MOV RDX,qword ptr [RBX + 0x48]
MOV RCX,qword ptr [RBX + 0x50]
MOV RSI,RDX
MOV R8,RAX
CALL 0x00133e5b
CDQE
MOV RSI,qword ptr [RBX + 0x50]
MOV qword ptr [RSP + 0x38],R14
LEA RCX,[RSI + R14*0x1]
ADD RAX,RCX
DEC RAX
XOR EDX,EDX
DIV RSI
MOV RDI,qword ptr [RBX + 0x40]
MOV R15D,dword ptr [RBX + 0x58]
MOV EDX,dword ptr [RBX + 0x14]
MOV dword ptr [RSP + 0x34],EDX
LEA RDX,[RSP + 0x20]
MOV qword ptr [RDX + -0x10],RDX
MOV qword ptr [RDX + -0x8],0x0
MOV byte ptr [RDX],0x0
MOV qword ptr [RSP + 0x8],RAX
MOVSXD RDX,EAX
MOV qword ptr [RBX + 0x58],RDX
TEST R12B,0x1
JZ 0x0013230c
ADD RCX,RDI
MOV RAX,RCX
XOR EDX,EDX
DIV RSI
MOV ECX,R15D
SUB ECX,EAX
JLE 0x001322d3
LEA RDX,[0x1cfeea]
LEA R13,[RSP + 0x40]
MOV ESI,0x40
MOV RDI,R13
XOR EAX,EAX
CALL 0x0011d6f0
LAB_001322c6:
LEA RDI,[RSP + 0x10]
MOV RSI,R13
CALL 0x0011d920
LAB_001322d3:
CMP R15D,0x2
JL 0x0013230c
DEC R15D
MOV R14,0x315b1b4b305b1b0d
LEA R13,[RSP + 0x10]
LEA RBP,[RSP + 0x40]
LAB_001322f0:
MOV qword ptr [RSP + 0x40],R14
MOV word ptr [RSP + 0x48],0x41
LAB_001322fc:
MOV RDI,R13
MOV RSI,RBP
CALL 0x0011d920
DEC R15D
JNZ 0x001322f0
LAB_0013230c:
TEST R12B,0x3
MOV R14,qword ptr [RSP + 0x38]
JZ 0x00132332
LEA RSI,[RSP + 0x40]
MOV word ptr [RSI + 0x4],0x4b
MOV dword ptr [RSI],0x305b1b0d
LAB_00132328:
LEA RDI,[RSP + 0x10]
CALL 0x0011d920
LAB_00132332:
MOV RSI,qword ptr [RBX + 0x48]
MOV RDI,qword ptr [RBX + 0x18]
MOV RDX,qword ptr [RBX + 0x38]
MOV RCX,qword ptr [RBX + 0x50]
MOV R8,R14
CALL 0x00133e5b
MOV R13,RAX
TEST R12B,0x2
JNZ 0x0013235b
MOVSXD R12,R13D
JMP 0x00132473
LAB_0013235b:
MOV RSI,qword ptr [RBX + 0x28]
LEA RDI,[RSP + 0x10]
CALL 0x0011d920
CMP byte ptr [0x0020bd98],0x1
JNZ 0x001323a4
CMP qword ptr [RBX + 0x48],0x0
JZ 0x001323b6
MOV R15D,0x1
LEA R12,[0x1d3c19]
LEA RBP,[RSP + 0x10]
LAB_0013238b:
MOV RDI,RBP
MOV RSI,R12
CALL 0x0011d920
MOV EAX,R15D
INC R15D
CMP qword ptr [RBX + 0x48],RAX
JA 0x0013238b
JMP 0x001323b6
LAB_001323a4:
MOV RSI,qword ptr [RBX + 0x18]
MOV RDX,qword ptr [RBX + 0x48]
LAB_001323ac:
LEA RDI,[RSP + 0x10]
CALL 0x0011d470
LAB_001323b6:
LEA RDI,[RSP + 0x10]
MOV RSI,RBX
MOV EDX,R14D
CALL 0x00133eee
MOV RAX,qword ptr [RBX + 0x38]
TEST RAX,RAX
JZ 0x001323ea
CMP RAX,qword ptr [RBX + 0x48]
JNZ 0x001323ea
MOVSXD RAX,R13D
ADD RAX,R14
XOR EDX,EDX
DIV qword ptr [RBX + 0x50]
TEST RDX,RDX
JZ 0x001324b8
LAB_001323ea:
MOV RAX,qword ptr [RSP + 0x8]
MOV ECX,EAX
LAB_001323f1:
MOVSXD R12,R13D
ADD R14,R12
MOV RSI,qword ptr [RBX + 0x50]
LEA RAX,[RSI + R14*0x1]
XOR EDX,EDX
DIV RSI
SUB ECX,EAX
JLE 0x00132434
LEA RDX,[0x1cff00]
LEA R15,[RSP + 0x40]
MOV ESI,0x40
MOV RDI,R15
XOR EAX,EAX
CALL 0x0011d6f0
LEA RDI,[RSP + 0x10]
MOV RSI,R15
CALL 0x0011d920
MOV RSI,qword ptr [RBX + 0x50]
LAB_00132434:
MOV RAX,R14
XOR EDX,EDX
DIV RSI
MOV RCX,RDX
TEST ECX,ECX
JZ 0x0013245d
LEA RDX,[0x1cff06]
LEA RDI,[RSP + 0x40]
MOV ESI,0x40
XOR EAX,EAX
CALL 0x0011d6f0
JMP 0x00132464
LAB_0013245d:
MOV word ptr [RSP + 0x40],0xd
LAB_00132464:
LEA RDI,[RSP + 0x10]
LEA RSI,[RSP + 0x40]
CALL 0x0011d920
LAB_00132473:
MOV qword ptr [RBX + 0x40],R12
MOV RSI,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RSP + 0x18]
MOV EDI,dword ptr [RSP + 0x34]
CALL 0x0011de70
MOV RDI,qword ptr [RSP + 0x10]
LEA RAX,[RSP + 0x20]
CMP RDI,RAX
JZ 0x001324a6
MOV RSI,qword ptr [RSP + 0x20]
INC RSI
CALL 0x0011d160
LAB_001324a6:
ADD RSP,0x88
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001324b8:
LEA RSI,[0x1d258f]
LEA RDI,[RSP + 0x10]
CALL 0x0011d920
LEA RSI,[RSP + 0x40]
MOV word ptr [RSI],0xd
LEA RDI,[RSP + 0x10]
CALL 0x0011d920
LAB_001324dd:
MOV RAX,qword ptr [RSP + 0x8]
LEA ECX,[RAX + 0x1]
CMP EAX,dword ptr [RBX + 0x58]
JL 0x001323f1
MOVSXD RAX,ECX
MOV qword ptr [RBX + 0x58],RAX
JMP 0x001323f1
|
/* refreshMultiLine(linenoiseState*, int) */
void refreshMultiLine(linenoiseState *param_1,int param_2)
{
char *__s;
ulong uVar1;
bool bVar2;
int iVar3;
size_t sVar4;
ulong uVar5;
int iVar6;
int iVar7;
int1 *local_a8;
size_t local_a0;
int1 local_98;
int7 uStack_97;
int local_84;
ulong local_80;
int8 local_78;
int2 local_70;
__s = *(char **)(param_1 + 0x28);
sVar4 = strlen(__s);
uVar5 = promptTextColumnLen(__s,sVar4);
iVar3 = columnPosForMultiLine
(*(char **)(param_1 + 0x18),*(ulong *)(param_1 + 0x48),
*(ulong *)(param_1 + 0x48),*(ulong *)(param_1 + 0x50),uVar5);
uVar1 = *(ulong *)(param_1 + 0x50);
iVar7 = *(int *)(param_1 + 0x58);
local_84 = *(int *)(param_1 + 0x14);
local_a8 = &local_98;
local_a0 = 0;
local_98 = 0;
iVar3 = (int)((((long)iVar3 + uVar1 + uVar5) - 1) / uVar1);
*(long *)(param_1 + 0x58) = (long)iVar3;
local_80 = uVar5;
if ((param_2 & 1U) != 0) {
if ((int)((uVar1 + uVar5 + *(long *)(param_1 + 0x40)) / uVar1) < iVar7) {
snprintf((char *)&local_78,0x40,"\x1b[%dB");
/* try { // try from 001322c6 to 001322d2 has its CatchHandler @ 001324fc */
std::__cxx11::string::append((char *)&local_a8);
}
if (1 < iVar7) {
iVar7 = iVar7 + -1;
do {
local_78 = 0x315b1b4b305b1b0d;
local_70 = 0x41;
/* try { // try from 001322fc to 00132306 has its CatchHandler @ 001324fe */
std::__cxx11::string::append((char *)&local_a8);
iVar7 = iVar7 + -1;
} while (iVar7 != 0);
}
}
uVar1 = local_80;
if ((param_2 & 3U) != 0) {
local_78 = CONCAT26(local_78._6_2_,0x4b00000000);
local_78 = CONCAT44(local_78._4_4_,0x305b1b0d);
/* try { // try from 00132328 to 00132368 has its CatchHandler @ 001324fc */
std::__cxx11::string::append((char *)&local_a8);
}
iVar7 = columnPosForMultiLine
(*(char **)(param_1 + 0x18),*(ulong *)(param_1 + 0x48),
*(ulong *)(param_1 + 0x38),*(ulong *)(param_1 + 0x50),uVar1);
if ((param_2 & 2U) != 0) {
std::__cxx11::string::append((char *)&local_a8);
if (maskmode == '\x01') {
if (*(long *)(param_1 + 0x48) != 0) {
uVar5 = 1;
do {
/* try { // try from 0013238b to 00132395 has its CatchHandler @ 001324fa */
std::__cxx11::string::append((char *)&local_a8);
bVar2 = uVar5 < *(ulong *)(param_1 + 0x48);
uVar5 = (ulong)((int)uVar5 + 1);
} while (bVar2);
}
}
else {
/* try { // try from 001323ac to 001324dc has its CatchHandler @ 001324fc */
std::__cxx11::string::append((char *)&local_a8,*(ulong *)(param_1 + 0x18));
}
refreshShowHints((string *)&local_a8,param_1,(int)uVar1);
if (((*(long *)(param_1 + 0x38) != 0) &&
(*(long *)(param_1 + 0x38) == *(long *)(param_1 + 0x48))) &&
(((long)iVar7 + uVar1) % *(ulong *)(param_1 + 0x50) == 0)) {
std::__cxx11::string::append((char *)&local_a8);
local_78 = CONCAT62(local_78._2_6_,0xd);
std::__cxx11::string::append((char *)&local_a8);
iVar6 = iVar3 + 1;
bVar2 = *(int *)(param_1 + 0x58) <= iVar3;
iVar3 = iVar6;
if (bVar2) {
*(long *)(param_1 + 0x58) = (long)iVar6;
}
}
uVar5 = *(ulong *)(param_1 + 0x50);
if ((int)((uVar5 + uVar1 + (long)iVar7) / uVar5) < iVar3) {
snprintf((char *)&local_78,0x40,"\x1b[%dA");
std::__cxx11::string::append((char *)&local_a8);
uVar5 = *(ulong *)(param_1 + 0x50);
}
if ((int)((uVar1 + (long)iVar7) % uVar5) == 0) {
local_78 = CONCAT62(local_78._2_6_,0xd);
}
else {
snprintf((char *)&local_78,0x40,"\r\x1b[%dC");
}
std::__cxx11::string::append((char *)&local_a8);
}
*(long *)(param_1 + 0x40) = (long)iVar7;
write(local_84,local_a8,local_a0);
if (local_a8 != &local_98) {
operator_delete(local_a8,CONCAT71(uStack_97,local_98) + 1);
}
return;
}
| |
21,413 | my_mb_wc_cp932 | eloqsql/strings/ctype-cp932.c | static int
my_mb_wc_cp932(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: [00-7F] -> [U+0000..U+007F] */
{
*pwc= hi;
return 1;
}
/* JIS-X-0201 Half width Katakana: [A1..DF] -> [U+FF61..U+FF9F] */
if (hi >= 0xA1 && hi <= 0xDF)
{
*pwc= cp932_to_unicode[hi];
return 1;
}
if (s + 2 > e)
return MY_CS_TOOSMALL2;
/* JIS-X-0208-MS [81..9F,E0..FC][40..7E,80..FC] */
if (!(pwc[0]= cp932_to_unicode[(hi << 8) + s[1]]))
return (iscp932head(hi) && iscp932tail(s[1])) ? -2 : MY_CS_ILSEQ;
return 2;
} | O3 | c | my_mb_wc_cp932:
pushq %rbp
movq %rsp, %rbp
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmpq %rcx, %rdx
jae 0x2f407
movzbl (%rdx), %edi
testb %dil, %dil
js 0x2f3ed
movq %rdi, (%rsi)
jmp 0x2f402
leal 0x5f(%rdi), %eax
cmpb $0x3e, %al
ja 0x2f409
leaq 0x47525(%rip), %rax # 0x76920
movzwl (%rax,%rdi,2), %eax
movq %rax, (%rsi)
movl $0x1, %eax
popq %rbp
retq
leaq 0x2(%rdx), %r8
movl $0xffffff9a, %eax # imm = 0xFFFFFF9A
cmpq %rcx, %r8
ja 0x2f407
movzbl 0x1(%rdx), %eax
movl %edi, %ecx
shll $0x9, %ecx
leal (%rcx,%rax,2), %eax
leaq 0x474f6(%rip), %rcx # 0x76920
movzwl (%rax,%rcx), %ecx
movq %rcx, (%rsi)
movl $0x2, %eax
testq %rcx, %rcx
jne 0x2f407
cmpb $-0x80, %dil
setne %al
cmpb $-0x60, %dil
setb %cl
andb %al, %cl
addb $0x20, %dil
cmpb $0x1d, %dil
setb %sil
orb %cl, %sil
xorl %eax, %eax
cmpb $0x1, %sil
jne 0x2f407
movb 0x1(%rdx), %cl
leal -0x40(%rcx), %edx
movl $0xfffffffe, %eax # imm = 0xFFFFFFFE
cmpb $0x3f, %dl
jb 0x2f407
movl $0x0, %eax
testb %cl, %cl
jns 0x2f407
xorl %eax, %eax
cmpb $-0x3, %cl
setae %al
leal -0x2(,%rax,2), %eax
jmp 0x2f407
| my_mb_wc_cp932:
push rbp
mov rbp, rsp
mov eax, 0FFFFFF9Bh
cmp rdx, rcx
jnb short loc_2F407
movzx edi, byte ptr [rdx]
test dil, dil
js short loc_2F3ED
mov [rsi], rdi
jmp short loc_2F402
loc_2F3ED:
lea eax, [rdi+5Fh]
cmp al, 3Eh ; '>'
ja short loc_2F409
lea rax, cp932_to_unicode
movzx eax, word ptr [rax+rdi*2]
mov [rsi], rax
loc_2F402:
mov eax, 1
loc_2F407:
pop rbp
retn
loc_2F409:
lea r8, [rdx+2]
mov eax, 0FFFFFF9Ah
cmp r8, rcx
ja short loc_2F407
movzx eax, byte ptr [rdx+1]
mov ecx, edi
shl ecx, 9
lea eax, [rcx+rax*2]
lea rcx, cp932_to_unicode
movzx ecx, word ptr [rax+rcx]
mov [rsi], rcx
mov eax, 2
test rcx, rcx
jnz short loc_2F407
cmp dil, 80h
setnz al
cmp dil, 0A0h
setb cl
and cl, al
add dil, 20h ; ' '
cmp dil, 1Dh
setb sil
or sil, cl
xor eax, eax
cmp sil, 1
jnz short loc_2F407
mov cl, [rdx+1]
lea edx, [rcx-40h]
mov eax, 0FFFFFFFEh
cmp dl, 3Fh ; '?'
jb short loc_2F407
mov eax, 0
test cl, cl
jns short loc_2F407
xor eax, eax
cmp cl, 0FDh
setnb al
lea eax, ds:0FFFFFFFFFFFFFFFEh[rax*2]
jmp loc_2F407
| long long my_mb_wc_cp932(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4)
{
long long result; // rax
long long v5; // rdi
long long v6; // rcx
char v7; // cl
result = 4294967195LL;
if ( (unsigned long long)a3 < a4 )
{
v5 = *a3;
if ( (v5 & 0x80u) == 0LL )
{
*a2 = v5;
return 1LL;
}
if ( (unsigned __int8)(v5 + 95) <= 0x3Eu )
{
*a2 = cp932_to_unicode[v5];
return 1LL;
}
result = 4294967194LL;
if ( (unsigned long long)(a3 + 2) <= a4 )
{
v6 = cp932_to_unicode[256 * (_DWORD)v5 + a3[1]];
*a2 = v6;
result = 2LL;
if ( !v6 )
{
result = 0LL;
if ( (_BYTE)v5 != 0x80 && (unsigned __int8)v5 < 0xA0u || (unsigned __int8)(v5 + 32) < 0x1Du )
{
v7 = a3[1];
result = 4294967294LL;
if ( (unsigned __int8)(v7 - 64) >= 0x3Fu )
{
result = 0LL;
if ( v7 < 0 )
return 2 * (unsigned int)((unsigned __int8)v7 >= 0xFDu) - 2;
}
}
}
}
}
return result;
}
| my_mb_wc_cp932:
PUSH RBP
MOV RBP,RSP
MOV EAX,0xffffff9b
CMP RDX,RCX
JNC 0x0012f407
MOVZX EDI,byte ptr [RDX]
TEST DIL,DIL
JS 0x0012f3ed
MOV qword ptr [RSI],RDI
JMP 0x0012f402
LAB_0012f3ed:
LEA EAX,[RDI + 0x5f]
CMP AL,0x3e
JA 0x0012f409
LEA RAX,[0x176920]
MOVZX EAX,word ptr [RAX + RDI*0x2]
MOV qword ptr [RSI],RAX
LAB_0012f402:
MOV EAX,0x1
LAB_0012f407:
POP RBP
RET
LAB_0012f409:
LEA R8,[RDX + 0x2]
MOV EAX,0xffffff9a
CMP R8,RCX
JA 0x0012f407
MOVZX EAX,byte ptr [RDX + 0x1]
MOV ECX,EDI
SHL ECX,0x9
LEA EAX,[RCX + RAX*0x2]
LEA RCX,[0x176920]
MOVZX ECX,word ptr [RAX + RCX*0x1]
MOV qword ptr [RSI],RCX
MOV EAX,0x2
TEST RCX,RCX
JNZ 0x0012f407
CMP DIL,0x80
SETNZ AL
CMP DIL,0xa0
SETC CL
AND CL,AL
ADD DIL,0x20
CMP DIL,0x1d
SETC SIL
OR SIL,CL
XOR EAX,EAX
CMP SIL,0x1
JNZ 0x0012f407
MOV CL,byte ptr [RDX + 0x1]
LEA EDX,[RCX + -0x40]
MOV EAX,0xfffffffe
CMP DL,0x3f
JC 0x0012f407
MOV EAX,0x0
TEST CL,CL
JNS 0x0012f407
XOR EAX,EAX
CMP CL,0xfd
SETNC AL
LEA EAX,[-0x2 + RAX*0x2]
JMP 0x0012f407
|
int my_mb_wc_cp932(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 (0x3e < (byte)(bVar1 + 0x5f)) {
if (param_4 < param_3 + 2) {
return -0x66;
}
uVar2 = *(ushort *)(cp932_to_unicode + ((uint)bVar1 * 0x200 + (uint)param_3[1] * 2));
*param_2 = (ulong)uVar2;
if ((ulong)uVar2 != 0) {
return 2;
}
if (0x1c < (byte)(bVar1 + 0x20) && (0x9f < bVar1 || bVar1 == 0x80)) {
return 0;
}
bVar1 = param_3[1];
if ((byte)(bVar1 - 0x40) < 0x3f) {
return -2;
}
if (-1 < (char)bVar1) {
return 0;
}
return (uint)(0xfc < bVar1) * 2 + -2;
}
*param_2 = (ulong)*(ushort *)(cp932_to_unicode + (ulong)bVar1 * 2);
}
else {
*param_2 = (ulong)bVar1;
}
iVar3 = 1;
}
return iVar3;
}
| |
21,414 | coro::context::start() | tinyCoroLab/src/context.cpp | auto context::start() noexcept -> void
{
// TODO[lab2b]: Add you codes
m_job = make_unique<jthread>(
[this](stop_token token)
{
this->init();
this->run(token);
this->deinit();
});
} | O0 | cpp | coro::context::start():
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movq %rax, 0x10(%rsp)
leaq 0x18(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x6ee30
jmp 0x6edf9
movq 0x8(%rsp), %rdi
addq $0x20240, %rdi # imm = 0x20240
leaq 0x18(%rsp), %rsi
callq 0x6f5f0
leaq 0x18(%rsp), %rdi
callq 0xf540
addq $0x28, %rsp
retq
movq %rax, %rdi
callq 0xe5b0
nopw %cs:(%rax,%rax)
| _ZN4coro7context5startEv:
sub rsp, 28h
mov [rsp+28h+var_8], rdi
mov rax, [rsp+28h+var_8]
mov [rsp+28h+var_20], rax; void *
mov qword ptr [rsp+28h+var_18], rax; int
lea rdi, [rsp+28h+var_10]; int
lea rsi, [rsp+28h+var_18]
call _ZSt11make_uniqueISt7jthreadJZN4coro7context5startEvE3$_0EENSt9_MakeUniqIT_E15__single_objectEDpOT0_; std::make_unique<std::jthread,coro::context::start(void)::$_0>(coro::context::start(void)::$_0 &&)
jmp short $+2
loc_6EDF9:
mov rdi, [rsp+28h+var_20]
add rdi, 20240h
lea rsi, [rsp+28h+var_10]
call _ZNSt10unique_ptrISt7jthreadSt14default_deleteIS0_EEaSEOS3_; std::unique_ptr<std::jthread>::operator=(std::unique_ptr<std::jthread>&&)
lea rdi, [rsp+28h+var_10]
call _ZNSt10unique_ptrISt7jthreadSt14default_deleteIS0_EED2Ev; std::unique_ptr<std::jthread>::~unique_ptr()
add rsp, 28h
retn
mov rdi, rax
call __clang_call_terminate
| _QWORD * coro::context::start(coro::context *this)
{
int v2; // [rsp+0h] [rbp-28h]
char *v3; // [rsp+8h] [rbp-20h]
long long v4[2]; // [rsp+18h] [rbp-10h] BYREF
v4[1] = (long long)this;
std::make_unique<std::jthread,coro::context::start(void)::$_0>((int)v4, v2, this, (int)this, v4[0]);
std::unique_ptr<std::jthread>::operator=(v3 + 131648, v4);
return std::unique_ptr<std::jthread>::~unique_ptr((long long)v4);
}
| start:
SUB RSP,0x28
MOV qword ptr [RSP + 0x20],RDI
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x10],RAX
LAB_0016ede8:
LEA RDI,[RSP + 0x18]
LEA RSI,[RSP + 0x10]
CALL 0x0016ee30
JMP 0x0016edf9
LAB_0016edf9:
MOV RDI,qword ptr [RSP + 0x8]
ADD RDI,0x20240
LEA RSI,[RSP + 0x18]
CALL 0x0016f5f0
LEA RDI,[RSP + 0x18]
CALL 0x0010f540
ADD RSP,0x28
RET
|
/* coro::context::start() */
void __thiscall coro::context::start(context *this)
{
__0 local_10 [8];
context *local_8;
/* try { // try from 0016ede8 to 0016edf6 has its CatchHandler @ 0016ee1e */
local_8 = this;
std::make_unique<std::jthread,coro::context::start()::__0>(local_10);
std::unique_ptr<std::jthread,std::default_delete<std::jthread>>::operator=
((unique_ptr<std::jthread,std::default_delete<std::jthread>> *)(this + 0x20240),
(unique_ptr *)local_10);
std::unique_ptr<std::jthread,std::default_delete<std::jthread>>::~unique_ptr
((unique_ptr<std::jthread,std::default_delete<std::jthread>> *)local_10);
return;
}
| |
21,415 | get_tty_password | eloqsql/mysys/get_password.c | char *get_tty_password(const char *opt_message)
{
#ifdef HAVE_GETPASS
char *passbuff;
#else /* ! HAVE_GETPASS */
TERMIO org,tmp;
#endif /* HAVE_GETPASS */
char buff[80];
DBUG_ENTER("get_tty_password");
#ifdef HAVE_GETPASS
passbuff = getpass(opt_message ? opt_message : "Enter password: ");
/* copy the password to buff and clear original (static) buffer */
strnmov(buff, passbuff, sizeof(buff) - 1);
#ifdef _PASSWORD_LEN
memset(passbuff, 0, _PASSWORD_LEN);
#endif
#else
if (isatty(fileno(stderr)))
{
fputs(opt_message ? opt_message : "Enter password: ",stderr);
fflush(stderr);
}
#if defined(HAVE_TERMIOS_H)
tcgetattr(fileno(stdin), &org);
tmp = org;
tmp.c_lflag &= ~(ECHO | ISIG | ICANON);
tmp.c_cc[VMIN] = 1;
tmp.c_cc[VTIME] = 0;
tcsetattr(fileno(stdin), TCSADRAIN, &tmp);
get_password(buff, sizeof(buff)-1, fileno(stdin), isatty(fileno(stderr)));
tcsetattr(fileno(stdin), TCSADRAIN, &org);
#elif defined(HAVE_TERMIO_H)
ioctl(fileno(stdin), (int) TCGETA, &org);
tmp=org;
tmp.c_lflag &= ~(ECHO | ISIG | ICANON);
tmp.c_cc[VMIN] = 1;
tmp.c_cc[VTIME]= 0;
ioctl(fileno(stdin),(int) TCSETA, &tmp);
get_password(buff,sizeof(buff)-1,fileno(stdin),isatty(fileno(stderr)));
ioctl(fileno(stdin),(int) TCSETA, &org);
#else
gtty(fileno(stdin), &org);
tmp=org;
tmp.sg_flags &= ~ECHO;
tmp.sg_flags |= RAW;
stty(fileno(stdin), &tmp);
get_password(buff,sizeof(buff)-1,fileno(stdin),isatty(fileno(stderr)));
stty(fileno(stdin), &org);
#endif
if (isatty(fileno(stderr)))
fputc('\n',stderr);
#endif /* HAVE_GETPASS */
DBUG_RETURN(my_strdup(PSI_INSTRUMENT_ME, buff, MYF(MY_FAE)));
} | O0 | c | get_tty_password:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x68(%rbp)
cmpq $0x0, -0x68(%rbp)
je 0xd7f2d
movq -0x68(%rbp), %rax
movq %rax, -0x78(%rbp)
jmp 0xd7f3a
leaq 0x72271(%rip), %rax # 0x14a1a5
movq %rax, -0x78(%rbp)
jmp 0xd7f3a
movq -0x78(%rbp), %rdi
callq 0x3a680
movq %rax, -0x70(%rbp)
leaq -0x60(%rbp), %rdi
movq -0x70(%rbp), %rsi
movl $0x4f, %edx
callq 0x12b6a0
leaq -0x60(%rbp), %rsi
xorl %edi, %edi
movl $0x8, %edx
callq 0xe15e0
movq %rax, -0x80(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0xd7f8c
movq -0x80(%rbp), %rax
addq $0x80, %rsp
popq %rbp
retq
callq 0x3a2a0
nopw %cs:(%rax,%rax)
nopl (%rax,%rax)
| get_tty_password:
push rbp
mov rbp, rsp
sub rsp, 80h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_68], rdi
cmp [rbp+var_68], 0
jz short loc_D7F2D
mov rax, [rbp+var_68]
mov [rbp+var_78], rax
jmp short loc_D7F3A
loc_D7F2D:
lea rax, aEnterPassword; "Enter password: "
mov [rbp+var_78], rax
jmp short $+2
loc_D7F3A:
mov rdi, [rbp+var_78]
call _getpass
mov [rbp+var_70], rax
lea rdi, [rbp+var_60]
mov rsi, [rbp+var_70]
mov edx, 4Fh ; 'O'
call strnmov
lea rsi, [rbp+var_60]
xor edi, edi
mov edx, 8
call my_strdup
mov [rbp+var_80], rax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_D7F8C
mov rax, [rbp+var_80]
add rsp, 80h
pop rbp
retn
loc_D7F8C:
call ___stack_chk_fail
| long long get_tty_password(long long a1)
{
long long v1; // rax
_BYTE v3[88]; // [rsp+20h] [rbp-60h] BYREF
unsigned long long v4; // [rsp+78h] [rbp-8h]
v4 = __readfsqword(0x28u);
if ( a1 )
v1 = getpass(a1);
else
v1 = getpass("Enter password: ");
strnmov(v3, v1, 79LL);
return my_strdup(0LL, v3, 8LL);
}
| get_tty_password:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x68],RDI
CMP qword ptr [RBP + -0x68],0x0
JZ 0x001d7f2d
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RBP + -0x78],RAX
JMP 0x001d7f3a
LAB_001d7f2d:
LEA RAX,[0x24a1a5]
MOV qword ptr [RBP + -0x78],RAX
JMP 0x001d7f3a
LAB_001d7f3a:
MOV RDI,qword ptr [RBP + -0x78]
CALL 0x0013a680
MOV qword ptr [RBP + -0x70],RAX
LEA RDI,[RBP + -0x60]
MOV RSI,qword ptr [RBP + -0x70]
MOV EDX,0x4f
CALL 0x0022b6a0
LEA RSI,[RBP + -0x60]
XOR EDI,EDI
MOV EDX,0x8
CALL 0x001e15e0
MOV qword ptr [RBP + -0x80],RAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x001d7f8c
MOV RAX,qword ptr [RBP + -0x80]
ADD RSP,0x80
POP RBP
RET
LAB_001d7f8c:
CALL 0x0013a2a0
|
int8 get_tty_password(char *param_1)
{
char *pcVar1;
int8 uVar2;
long in_FS_OFFSET;
char *local_80;
int1 local_68 [88];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_80 = param_1;
if (param_1 == (char *)0x0) {
local_80 = "Enter password: ";
}
pcVar1 = getpass(local_80);
strnmov(local_68,pcVar1,0x4f);
uVar2 = my_strdup(0,local_68,8);
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return uVar2;
}
| |
21,416 | get_tty_password | eloqsql/mysys/get_password.c | char *get_tty_password(const char *opt_message)
{
#ifdef HAVE_GETPASS
char *passbuff;
#else /* ! HAVE_GETPASS */
TERMIO org,tmp;
#endif /* HAVE_GETPASS */
char buff[80];
DBUG_ENTER("get_tty_password");
#ifdef HAVE_GETPASS
passbuff = getpass(opt_message ? opt_message : "Enter password: ");
/* copy the password to buff and clear original (static) buffer */
strnmov(buff, passbuff, sizeof(buff) - 1);
#ifdef _PASSWORD_LEN
memset(passbuff, 0, _PASSWORD_LEN);
#endif
#else
if (isatty(fileno(stderr)))
{
fputs(opt_message ? opt_message : "Enter password: ",stderr);
fflush(stderr);
}
#if defined(HAVE_TERMIOS_H)
tcgetattr(fileno(stdin), &org);
tmp = org;
tmp.c_lflag &= ~(ECHO | ISIG | ICANON);
tmp.c_cc[VMIN] = 1;
tmp.c_cc[VTIME] = 0;
tcsetattr(fileno(stdin), TCSADRAIN, &tmp);
get_password(buff, sizeof(buff)-1, fileno(stdin), isatty(fileno(stderr)));
tcsetattr(fileno(stdin), TCSADRAIN, &org);
#elif defined(HAVE_TERMIO_H)
ioctl(fileno(stdin), (int) TCGETA, &org);
tmp=org;
tmp.c_lflag &= ~(ECHO | ISIG | ICANON);
tmp.c_cc[VMIN] = 1;
tmp.c_cc[VTIME]= 0;
ioctl(fileno(stdin),(int) TCSETA, &tmp);
get_password(buff,sizeof(buff)-1,fileno(stdin),isatty(fileno(stderr)));
ioctl(fileno(stdin),(int) TCSETA, &org);
#else
gtty(fileno(stdin), &org);
tmp=org;
tmp.sg_flags &= ~ECHO;
tmp.sg_flags |= RAW;
stty(fileno(stdin), &tmp);
get_password(buff,sizeof(buff)-1,fileno(stdin),isatty(fileno(stderr)));
stty(fileno(stdin), &org);
#endif
if (isatty(fileno(stderr)))
fputc('\n',stderr);
#endif /* HAVE_GETPASS */
DBUG_RETURN(my_strdup(PSI_INSTRUMENT_ME, buff, MYF(MY_FAE)));
} | O3 | c | get_tty_password:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x58, %rsp
movq %fs:0x28, %rax
movq %rax, -0x10(%rbp)
testq %rdi, %rdi
leaq 0x53fd3(%rip), %rax # 0xfb2d3
cmoveq %rax, %rdi
callq 0x396a0
leaq -0x60(%rbp), %rbx
movl $0x4f, %edx
movq %rbx, %rdi
movq %rax, %rsi
callq 0xdd02c
movl $0x8, %edx
xorl %edi, %edi
movq %rbx, %rsi
callq 0xacccc
movq %fs:0x28, %rcx
cmpq -0x10(%rbp), %rcx
jne 0xa7342
addq $0x58, %rsp
popq %rbx
popq %rbp
retq
callq 0x39290
nop
| get_tty_password:
push rbp
mov rbp, rsp
push rbx
sub rsp, 58h
mov rax, fs:28h
mov [rbp+var_10], rax
test rdi, rdi
lea rax, aEnterPassword; "Enter password: "
cmovz rdi, rax
call _getpass
lea rbx, [rbp+var_60]
mov edx, 4Fh ; 'O'
mov rdi, rbx
mov rsi, rax
call strnmov
mov edx, 8
xor edi, edi
mov rsi, rbx
call my_strdup
mov rcx, fs:28h
cmp rcx, [rbp+var_10]
jnz short loc_A7342
add rsp, 58h
pop rbx
pop rbp
retn
loc_A7342:
call ___stack_chk_fail
| long long get_tty_password(const char *a1)
{
long long v1; // rax
_BYTE v3[80]; // [rsp+0h] [rbp-60h] BYREF
unsigned long long v4; // [rsp+50h] [rbp-10h]
v4 = __readfsqword(0x28u);
if ( !a1 )
a1 = "Enter password: ";
v1 = getpass(a1);
strnmov(v3, v1, 79LL);
return my_strdup(0LL, v3, 8LL);
}
| get_tty_password:
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x58
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x10],RAX
TEST RDI,RDI
LEA RAX,[0x1fb2d3]
CMOVZ RDI,RAX
CALL 0x001396a0
LEA RBX,[RBP + -0x60]
MOV EDX,0x4f
MOV RDI,RBX
MOV RSI,RAX
CALL 0x001dd02c
MOV EDX,0x8
XOR EDI,EDI
MOV RSI,RBX
CALL 0x001acccc
MOV RCX,qword ptr FS:[0x28]
CMP RCX,qword ptr [RBP + -0x10]
JNZ 0x001a7342
ADD RSP,0x58
POP RBX
POP RBP
RET
LAB_001a7342:
CALL 0x00139290
|
void get_tty_password(char *param_1)
{
char *pcVar1;
long in_FS_OFFSET;
int1 local_68 [80];
long local_18;
local_18 = *(long *)(in_FS_OFFSET + 0x28);
if (param_1 == (char *)0x0) {
param_1 = "Enter password: ";
}
pcVar1 = getpass(param_1);
strnmov(local_68,pcVar1,0x4f);
my_strdup(0,local_68,8);
if (*(long *)(in_FS_OFFSET + 0x28) == local_18) {
return;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
21,417 | thai2sortable | eloqsql/strings/ctype-tis620.c | static size_t thai2sortable(uchar *tstr, size_t len)
{
uchar *p;
size_t tlen;
uchar l2bias;
tlen= len;
l2bias= 256 - 8;
for (p= tstr; tlen > 0; p++, tlen--)
{
uchar c= *p;
if (isthai(c))
{
const int *t_ctype0= t_ctype[c];
if (isconsnt(c))
l2bias -= 8;
if (isldvowel(c) && tlen != 1 && isconsnt(p[1]))
{
/* simply swap between leading-vowel and consonant */
*p= p[1];
p[1]= c;
tlen--;
p++;
continue;
}
/* if found level 2 char (L2_GARAN,L2_TONE*,L2_TYKHU) move to last */
if (t_ctype0[1] >= L2_GARAN)
{
/*
l2bias use to control position weight of l2char
example (*=l2char) XX*X must come before X*XX
*/
memmove((char*) p, (char*) (p+1), tlen-1);
tstr[len-1]= l2bias + t_ctype0[1]- L2_GARAN +1;
p--;
continue;
}
}
else
{
l2bias-= 8;
*p= to_lower_tis620[c];
}
}
return len;
} | O0 | c | thai2sortable:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movb $-0x8, -0x21(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x20(%rbp)
jbe 0x5cff6
movq -0x18(%rbp), %rax
movb (%rax), %al
movb %al, -0x22(%rbp)
movzbl -0x22(%rbp), %eax
cmpl $0x80, %eax
jl 0x5cfb7
movzbl -0x22(%rbp), %eax
movl %eax, %ecx
leaq 0xfc62c(%rip), %rax # 0x1594e0
imulq $0x14, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movzbl -0x22(%rbp), %eax
movl %eax, %ecx
leaq 0xfc614(%rip), %rax # 0x1594e0
imulq $0x14, %rcx, %rcx
addq %rcx, %rax
movl 0x10(%rax), %eax
andl $0x10, %eax
cmpl $0x0, %eax
je 0x5cee8
movzbl -0x21(%rbp), %eax
subl $0x8, %eax
movb %al, -0x21(%rbp)
movzbl -0x22(%rbp), %eax
movl %eax, %ecx
leaq 0xfc5eb(%rip), %rax # 0x1594e0
imulq $0x14, %rcx, %rcx
addq %rcx, %rax
movl 0x10(%rax), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0x5cf62
cmpq $0x1, -0x20(%rbp)
je 0x5cf62
movq -0x18(%rbp), %rax
movzbl 0x1(%rax), %eax
movl %eax, %ecx
leaq 0xfc5c1(%rip), %rax # 0x1594e0
imulq $0x14, %rcx, %rcx
addq %rcx, %rax
movl 0x10(%rax), %eax
andl $0x10, %eax
cmpl $0x0, %eax
je 0x5cf62
movq -0x18(%rbp), %rax
movb 0x1(%rax), %cl
movq -0x18(%rbp), %rax
movb %cl, (%rax)
movb -0x22(%rbp), %cl
movq -0x18(%rbp), %rax
movb %cl, 0x1(%rax)
movq -0x20(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x5cfd9
movq -0x30(%rbp), %rax
cmpl $0x9, 0x4(%rax)
jl 0x5cfb5
movq -0x18(%rbp), %rdi
movq -0x18(%rbp), %rsi
addq $0x1, %rsi
movq -0x20(%rbp), %rdx
subq $0x1, %rdx
callq 0x256b0
movzbl -0x21(%rbp), %eax
movq -0x30(%rbp), %rcx
addl 0x4(%rcx), %eax
subl $0x9, %eax
addl $0x1, %eax
movb %al, %dl
movq -0x8(%rbp), %rax
movq -0x10(%rbp), %rcx
subq $0x1, %rcx
movb %dl, (%rax,%rcx)
movq -0x18(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x5cfd9
jmp 0x5cfd7
movzbl -0x21(%rbp), %eax
subl $0x8, %eax
movb %al, -0x21(%rbp)
movzbl -0x22(%rbp), %eax
movl %eax, %ecx
leaq 0x277032(%rip), %rax # 0x2d4000
movb (%rax,%rcx), %cl
movq -0x18(%rbp), %rax
movb %cl, (%rax)
jmp 0x5cfd9
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
movq -0x20(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x5ce84
movq -0x10(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
| thai2sortable:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_10]
mov [rbp+var_20], rax
mov [rbp+var_21], 0F8h
mov rax, [rbp+var_8]
mov [rbp+var_18], rax
loc_5CE84:
cmp [rbp+var_20], 0
jbe loc_5CFF6
mov rax, [rbp+var_18]
mov al, [rax]
mov [rbp+var_22], al
movzx eax, [rbp+var_22]
cmp eax, 80h
jl loc_5CFB7
movzx eax, [rbp+var_22]
mov ecx, eax
lea rax, t_ctype
imul rcx, 14h
add rax, rcx
mov [rbp+var_30], rax
movzx eax, [rbp+var_22]
mov ecx, eax
lea rax, t_ctype
imul rcx, 14h
add rax, rcx
mov eax, [rax+10h]
and eax, 10h
cmp eax, 0
jz short loc_5CEE8
movzx eax, [rbp+var_21]
sub eax, 8
mov [rbp+var_21], al
loc_5CEE8:
movzx eax, [rbp+var_22]
mov ecx, eax
lea rax, t_ctype
imul rcx, 14h
add rax, rcx
mov eax, [rax+10h]
and eax, 20h
cmp eax, 0
jz short loc_5CF62
cmp [rbp+var_20], 1
jz short loc_5CF62
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax+1]
mov ecx, eax
lea rax, t_ctype
imul rcx, 14h
add rax, rcx
mov eax, [rax+10h]
and eax, 10h
cmp eax, 0
jz short loc_5CF62
mov rax, [rbp+var_18]
mov cl, [rax+1]
mov rax, [rbp+var_18]
mov [rax], cl
mov cl, [rbp+var_22]
mov rax, [rbp+var_18]
mov [rax+1], cl
mov rax, [rbp+var_20]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_20], rax
mov rax, [rbp+var_18]
add rax, 1
mov [rbp+var_18], rax
jmp short loc_5CFD9
loc_5CF62:
mov rax, [rbp+var_30]
cmp dword ptr [rax+4], 9
jl short loc_5CFB5
mov rdi, [rbp+var_18]
mov rsi, [rbp+var_18]
add rsi, 1
mov rdx, [rbp+var_20]
sub rdx, 1
call _memmove
movzx eax, [rbp+var_21]
mov rcx, [rbp+var_30]
add eax, [rcx+4]
sub eax, 9
add eax, 1
mov dl, al
mov rax, [rbp+var_8]
mov rcx, [rbp+var_10]
sub rcx, 1
mov [rax+rcx], dl
mov rax, [rbp+var_18]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_18], rax
jmp short loc_5CFD9
loc_5CFB5:
jmp short loc_5CFD7
loc_5CFB7:
movzx eax, [rbp+var_21]
sub eax, 8
mov [rbp+var_21], al
movzx eax, [rbp+var_22]
mov ecx, eax
lea rax, to_lower_tis620
mov cl, [rax+rcx]
mov rax, [rbp+var_18]
mov [rax], cl
loc_5CFD7:
jmp short $+2
loc_5CFD9:
mov rax, [rbp+var_18]
add rax, 1
mov [rbp+var_18], rax
mov rax, [rbp+var_20]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_20], rax
jmp loc_5CE84
loc_5CFF6:
mov rax, [rbp+var_10]
add rsp, 30h
pop rbp
retn
| long long thai2sortable(unsigned __int8 *a1, long long a2)
{
char *v3; // [rsp+0h] [rbp-30h]
unsigned __int8 v4; // [rsp+Eh] [rbp-22h]
char v5; // [rsp+Fh] [rbp-21h]
long long v6; // [rsp+10h] [rbp-20h]
unsigned __int8 *v7; // [rsp+18h] [rbp-18h]
v6 = a2;
v5 = -8;
v7 = a1;
while ( v6 )
{
v4 = *v7;
if ( *v7 < 0x80u )
{
v5 -= 8;
*v7 = to_lower_tis620[v4];
}
else
{
v3 = (char *)&t_ctype[5 * v4];
if ( (*((_DWORD *)v3 + 4) & 0x10) != 0 )
v5 -= 8;
if ( (t_ctype[5 * v4 + 4] & 0x20) != 0 && v6 != 1 && (t_ctype[5 * v7[1] + 4] & 0x10) != 0 )
{
*v7 = v7[1];
v7[1] = v4;
--v6;
++v7;
}
else if ( *((int *)v3 + 1) >= 9 )
{
memmove(v7, v7 + 1, v6 - 1);
a1[a2 - 1] = v3[4] + v5 - 9 + 1;
--v7;
}
}
++v7;
--v6;
}
return a2;
}
| thai2sortable:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x20],RAX
MOV byte ptr [RBP + -0x21],0xf8
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x18],RAX
LAB_0015ce84:
CMP qword ptr [RBP + -0x20],0x0
JBE 0x0015cff6
MOV RAX,qword ptr [RBP + -0x18]
MOV AL,byte ptr [RAX]
MOV byte ptr [RBP + -0x22],AL
MOVZX EAX,byte ptr [RBP + -0x22]
CMP EAX,0x80
JL 0x0015cfb7
MOVZX EAX,byte ptr [RBP + -0x22]
MOV ECX,EAX
LEA RAX,[0x2594e0]
IMUL RCX,RCX,0x14
ADD RAX,RCX
MOV qword ptr [RBP + -0x30],RAX
MOVZX EAX,byte ptr [RBP + -0x22]
MOV ECX,EAX
LEA RAX,[0x2594e0]
IMUL RCX,RCX,0x14
ADD RAX,RCX
MOV EAX,dword ptr [RAX + 0x10]
AND EAX,0x10
CMP EAX,0x0
JZ 0x0015cee8
MOVZX EAX,byte ptr [RBP + -0x21]
SUB EAX,0x8
MOV byte ptr [RBP + -0x21],AL
LAB_0015cee8:
MOVZX EAX,byte ptr [RBP + -0x22]
MOV ECX,EAX
LEA RAX,[0x2594e0]
IMUL RCX,RCX,0x14
ADD RAX,RCX
MOV EAX,dword ptr [RAX + 0x10]
AND EAX,0x20
CMP EAX,0x0
JZ 0x0015cf62
CMP qword ptr [RBP + -0x20],0x1
JZ 0x0015cf62
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x1]
MOV ECX,EAX
LEA RAX,[0x2594e0]
IMUL RCX,RCX,0x14
ADD RAX,RCX
MOV EAX,dword ptr [RAX + 0x10]
AND EAX,0x10
CMP EAX,0x0
JZ 0x0015cf62
MOV RAX,qword ptr [RBP + -0x18]
MOV CL,byte ptr [RAX + 0x1]
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX],CL
MOV CL,byte ptr [RBP + -0x22]
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX + 0x1],CL
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x1
MOV qword ptr [RBP + -0x18],RAX
JMP 0x0015cfd9
LAB_0015cf62:
MOV RAX,qword ptr [RBP + -0x30]
CMP dword ptr [RAX + 0x4],0x9
JL 0x0015cfb5
MOV RDI,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x18]
ADD RSI,0x1
MOV RDX,qword ptr [RBP + -0x20]
SUB RDX,0x1
CALL 0x001256b0
MOVZX EAX,byte ptr [RBP + -0x21]
MOV RCX,qword ptr [RBP + -0x30]
ADD EAX,dword ptr [RCX + 0x4]
SUB EAX,0x9
ADD EAX,0x1
MOV DL,AL
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RBP + -0x10]
SUB RCX,0x1
MOV byte ptr [RAX + RCX*0x1],DL
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x18],RAX
JMP 0x0015cfd9
LAB_0015cfb5:
JMP 0x0015cfd7
LAB_0015cfb7:
MOVZX EAX,byte ptr [RBP + -0x21]
SUB EAX,0x8
MOV byte ptr [RBP + -0x21],AL
MOVZX EAX,byte ptr [RBP + -0x22]
MOV ECX,EAX
LEA RAX,[0x3d4000]
MOV CL,byte ptr [RAX + RCX*0x1]
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX],CL
LAB_0015cfd7:
JMP 0x0015cfd9
LAB_0015cfd9:
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x1
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x20],RAX
JMP 0x0015ce84
LAB_0015cff6:
MOV RAX,qword ptr [RBP + -0x10]
ADD RSP,0x30
POP RBP
RET
|
long thai2sortable(byte *param_1,long param_2)
{
byte bVar1;
char local_29;
long local_28;
byte *local_20;
local_29 = -8;
local_20 = param_1;
for (local_28 = param_2; local_28 != 0; local_28 = local_28 + -1) {
bVar1 = *local_20;
if (bVar1 < 0x80) {
local_29 = local_29 + -8;
*local_20 = to_lower_tis620[bVar1];
}
else {
if ((*(uint *)(t_ctype + (ulong)bVar1 * 0x14 + 0x10) & 0x10) != 0) {
local_29 = local_29 + -8;
}
if ((((*(uint *)(t_ctype + (ulong)bVar1 * 0x14 + 0x10) & 0x20) == 0) || (local_28 == 1)) ||
((*(uint *)(t_ctype + (ulong)local_20[1] * 0x14 + 0x10) & 0x10) == 0)) {
if (8 < *(int *)(t_ctype + (ulong)bVar1 * 0x14 + 4)) {
memmove(local_20,local_20 + 1,local_28 - 1);
param_1[param_2 + -1] =
(local_29 + (char)*(int4 *)(t_ctype + (ulong)bVar1 * 0x14 + 4)) - 8;
local_20 = local_20 + -1;
}
}
else {
*local_20 = local_20[1];
local_20[1] = bVar1;
local_28 = local_28 + -1;
local_20 = local_20 + 1;
}
}
local_20 = local_20 + 1;
}
return param_2;
}
| |
21,418 | minja::Value::operator>(minja::Value const&) const | monkey531[P]llama/common/./minja.hpp | bool operator>(const Value & other) const {
if (is_null())
throw std::runtime_error("Undefined value or reference");
if (is_number() && other.is_number()) return get<double>() > other.get<double>();
if (is_string() && other.is_string()) return get<std::string>() > other.get<std::string>();
throw std::runtime_error("Cannot compare values: " + dump() + " > " + other.dump());
} | O0 | cpp | minja::Value::operator>(minja::Value const&) const:
subq $0x138, %rsp # imm = 0x138
movq %rdi, 0x128(%rsp)
movq %rsi, 0x120(%rsp)
movq 0x128(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0xa18f0
testb $0x1, %al
jne 0xe5c3f
jmp 0xe5c9d
movl $0x10, %edi
callq 0x50540
movq %rax, %rdi
movq %rdi, %rax
movq %rax, 0x18(%rsp)
leaq 0xe708d(%rip), %rsi # 0x1ccce8
callq 0x50340
jmp 0xe5c62
movq 0x18(%rsp), %rdi
movq 0x16e342(%rip), %rsi # 0x253fb0
movq 0x16e303(%rip), %rdx # 0x253f78
callq 0x508f0
movq 0x18(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x118(%rsp)
movl %eax, 0x114(%rsp)
callq 0x50c40
jmp 0xe5f62
movq 0x20(%rsp), %rdi
callq 0xa4840
testb $0x1, %al
jne 0xe5cad
jmp 0xe5cfb
movq 0x120(%rsp), %rdi
callq 0xa4840
testb $0x1, %al
jne 0xe5cc0
jmp 0xe5cfb
movq 0x20(%rsp), %rdi
callq 0x9fc90
movsd %xmm0, 0x10(%rsp)
movq 0x120(%rsp), %rdi
callq 0x9fc90
movaps %xmm0, %xmm1
movsd 0x10(%rsp), %xmm0
ucomisd %xmm1, %xmm0
seta %al
andb $0x1, %al
movb %al, 0x137(%rsp)
jmp 0xe5f51
movq 0x20(%rsp), %rdi
callq 0xa1f30
testb $0x1, %al
jne 0xe5d0e
jmp 0xe5db0
movq 0x120(%rsp), %rdi
callq 0xa1f30
testb $0x1, %al
jne 0xe5d24
jmp 0xe5db0
movq 0x20(%rsp), %rsi
leaq 0xf0(%rsp), %rdi
callq 0xa4860
movq 0x120(%rsp), %rsi
leaq 0xd0(%rsp), %rdi
callq 0xa4860
jmp 0xe5d4d
leaq 0xf0(%rsp), %rdi
leaq 0xd0(%rsp), %rsi
callq 0xe6380
andb $0x1, %al
movb %al, 0x137(%rsp)
leaq 0xd0(%rsp), %rdi
callq 0x510c0
leaq 0xf0(%rsp), %rdi
callq 0x510c0
jmp 0xe5f51
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x118(%rsp)
movl %eax, 0x114(%rsp)
leaq 0xf0(%rsp), %rdi
callq 0x510c0
jmp 0xe5f62
movb $0x1, 0x2f(%rsp)
movl $0x10, %edi
callq 0x50540
movq 0x20(%rsp), %rsi
movq %rax, 0x8(%rsp)
leaq 0x50(%rsp), %rdi
movl $0xffffffff, %edx # imm = 0xFFFFFFFF
xorl %ecx, %ecx
callq 0x9feb0
jmp 0xe5ddc
leaq 0xebe59(%rip), %rsi # 0x1d1c3c
leaq 0x70(%rsp), %rdi
leaq 0x50(%rsp), %rdx
callq 0x7a6e0
jmp 0xe5df4
leaq 0xebe5d(%rip), %rdx # 0x1d1c58
leaq 0x90(%rsp), %rdi
leaq 0x70(%rsp), %rsi
callq 0xae4c0
jmp 0xe5e0f
movq 0x120(%rsp), %rsi
leaq 0x30(%rsp), %rdi
movl $0xffffffff, %edx # imm = 0xFFFFFFFF
xorl %ecx, %ecx
callq 0x9feb0
jmp 0xe5e2a
leaq 0xb0(%rsp), %rdi
leaq 0x90(%rsp), %rsi
leaq 0x30(%rsp), %rdx
callq 0xae510
jmp 0xe5e46
movq 0x8(%rsp), %rdi
leaq 0xb0(%rsp), %rsi
callq 0x50390
jmp 0xe5e5a
movq 0x8(%rsp), %rdi
movb $0x0, 0x2f(%rsp)
movq 0x16e145(%rip), %rsi # 0x253fb0
movq 0x16e106(%rip), %rdx # 0x253f78
callq 0x508f0
jmp 0xe5f6f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x118(%rsp)
movl %eax, 0x114(%rsp)
jmp 0xe5f3c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x118(%rsp)
movl %eax, 0x114(%rsp)
jmp 0xe5f32
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x118(%rsp)
movl %eax, 0x114(%rsp)
jmp 0xe5f28
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x118(%rsp)
movl %eax, 0x114(%rsp)
jmp 0xe5f1b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x118(%rsp)
movl %eax, 0x114(%rsp)
jmp 0xe5f11
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x118(%rsp)
movl %eax, 0x114(%rsp)
leaq 0xb0(%rsp), %rdi
callq 0x510c0
leaq 0x30(%rsp), %rdi
callq 0x510c0
leaq 0x90(%rsp), %rdi
callq 0x510c0
leaq 0x70(%rsp), %rdi
callq 0x510c0
leaq 0x50(%rsp), %rdi
callq 0x510c0
testb $0x1, 0x2f(%rsp)
jne 0xe5f45
jmp 0xe5f4f
movq 0x8(%rsp), %rdi
callq 0x50c40
jmp 0xe5f62
movb 0x137(%rsp), %al
andb $0x1, %al
addq $0x138, %rsp # imm = 0x138
retq
movq 0x118(%rsp), %rdi
callq 0x50940
nop
| _ZNK5minja5ValuegtERKS0_:
sub rsp, 138h
mov [rsp+138h+var_10], rdi
mov [rsp+138h+var_18], rsi
mov rdi, [rsp+138h+var_10]; this
mov [rsp+138h+var_118], rdi; __int16
call _ZNK5minja5Value7is_nullEv; minja::Value::is_null(void)
test al, 1
jnz short loc_E5C3F
jmp short loc_E5C9D
loc_E5C3F:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rdi, rax; this
mov rax, rdi
mov [rsp+138h+var_120], rax
lea rsi, aUndefinedValue; "Undefined value or reference"
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
jmp short $+2
loc_E5C62:
mov rdi, [rsp+138h+var_120]; void *
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
call ___cxa_throw
mov rdi, [rsp+138h+var_120]; void *
mov rcx, rax
mov eax, edx
mov [rsp+138h+var_20], rcx
mov [rsp+138h+var_24], eax
call ___cxa_free_exception
jmp loc_E5F62
loc_E5C9D:
mov rdi, [rsp+138h+var_118]; this
call _ZNK5minja5Value9is_numberEv; minja::Value::is_number(void)
test al, 1
jnz short loc_E5CAD
jmp short loc_E5CFB
loc_E5CAD:
mov rdi, [rsp+138h+var_18]; this
call _ZNK5minja5Value9is_numberEv; minja::Value::is_number(void)
test al, 1
jnz short loc_E5CC0
jmp short loc_E5CFB
loc_E5CC0:
mov rdi, [rsp+138h+var_118]
call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void)
movsd [rsp+138h+var_128], xmm0
mov rdi, [rsp+138h+var_18]
call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void)
movaps xmm1, xmm0
movsd xmm0, [rsp+138h+var_128]
ucomisd xmm0, xmm1
setnbe al
and al, 1
mov [rsp+138h+var_1], al
jmp loc_E5F51
loc_E5CFB:
mov rdi, [rsp+138h+var_118]; this
call _ZNK5minja5Value9is_stringEv; minja::Value::is_string(void)
test al, 1
jnz short loc_E5D0E
jmp loc_E5DB0
loc_E5D0E:
mov rdi, [rsp+138h+var_18]; this
call _ZNK5minja5Value9is_stringEv; minja::Value::is_string(void)
test al, 1
jnz short loc_E5D24
jmp loc_E5DB0
loc_E5D24:
mov rsi, [rsp+138h+var_118]; int
lea rdi, [rsp+138h+var_48]; int
call _ZNK5minja5Value3getINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEET_v; minja::Value::get<std::string>(void)
mov rsi, [rsp+138h+var_18]; int
lea rdi, [rsp+138h+var_68]; int
call _ZNK5minja5Value3getINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEET_v; minja::Value::get<std::string>(void)
jmp short $+2
loc_E5D4D:
lea rdi, [rsp+138h+var_48]
lea rsi, [rsp+138h+var_68]
call _ZStgtIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EESA_; std::operator><char>(std::string const&,std::string const&)
and al, 1
mov [rsp+138h+var_1], al
lea rdi, [rsp+138h+var_68]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+138h+var_48]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_E5F51
mov rcx, rax
mov eax, edx
mov [rsp+138h+var_20], rcx
mov [rsp+138h+var_24], eax
lea rdi, [rsp+138h+var_48]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_E5F62
loc_E5DB0:
mov [rsp+138h+var_109], 1
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rsi, [rsp+138h+var_118]
mov [rsp+138h+var_130], rax
lea rdi, [rsp+138h+var_E8]
mov edx, 0FFFFFFFFh
xor ecx, ecx
call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool)
jmp short $+2
loc_E5DDC:
lea rsi, aCannotCompareV; "Cannot compare values: "
lea rdi, [rsp+138h+var_C8]
lea rdx, [rsp+138h+var_E8]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&)
jmp short $+2
loc_E5DF4:
lea rdx, asc_1D1C58; " > "
lea rdi, [rsp+138h+var_A8]
lea rsi, [rsp+138h+var_C8]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_PKS5_; std::operator+<char>(std::string&&,char const*)
jmp short $+2
loc_E5E0F:
mov rsi, [rsp+138h+var_18]
lea rdi, [rsp+138h+var_108]
mov edx, 0FFFFFFFFh
xor ecx, ecx
call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool)
jmp short $+2
loc_E5E2A:
lea rdi, [rsp+138h+var_88]
lea rsi, [rsp+138h+var_A8]
lea rdx, [rsp+138h+var_108]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_S9_; std::operator+<char>(std::string&&,std::string&)
jmp short $+2
loc_E5E46:
mov rdi, [rsp+138h+var_130]
lea rsi, [rsp+138h+var_88]
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
jmp short $+2
loc_E5E5A:
mov rdi, [rsp+138h+var_130]; void *
mov [rsp+138h+var_109], 0
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
call ___cxa_throw
jmp loc_E5F6F
mov rcx, rax
mov eax, edx
mov [rsp+138h+var_20], rcx
mov [rsp+138h+var_24], eax
jmp loc_E5F3C
mov rcx, rax
mov eax, edx
mov [rsp+138h+var_20], rcx
mov [rsp+138h+var_24], eax
jmp loc_E5F32
mov rcx, rax
mov eax, edx
mov [rsp+138h+var_20], rcx
mov [rsp+138h+var_24], eax
jmp short loc_E5F28
mov rcx, rax
mov eax, edx
mov [rsp+138h+var_20], rcx
mov [rsp+138h+var_24], eax
jmp short loc_E5F1B
mov rcx, rax
mov eax, edx
mov [rsp+138h+var_20], rcx
mov [rsp+138h+var_24], eax
jmp short loc_E5F11
mov rcx, rax
mov eax, edx
mov [rsp+138h+var_20], rcx
mov [rsp+138h+var_24], eax
lea rdi, [rsp+138h+var_88]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_E5F11:
lea rdi, [rsp+138h+var_108]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_E5F1B:
lea rdi, [rsp+138h+var_A8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_E5F28:
lea rdi, [rsp+138h+var_C8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_E5F32:
lea rdi, [rsp+138h+var_E8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_E5F3C:
test [rsp+138h+var_109], 1
jnz short loc_E5F45
jmp short loc_E5F4F
loc_E5F45:
mov rdi, [rsp+138h+var_130]; void *
call ___cxa_free_exception
loc_E5F4F:
jmp short loc_E5F62
loc_E5F51:
mov al, [rsp+138h+var_1]
and al, 1
add rsp, 138h
retn
loc_E5F62:
mov rdi, [rsp+138h+var_20]
call __Unwind_Resume
loc_E5F6F:
nop
| char minja::Value::operator>(minja::Value *a1, minja::Value *a2)
{
void *v3; // [rsp+8h] [rbp-130h]
std::runtime_error *exception; // [rsp+18h] [rbp-120h]
_BYTE v5[32]; // [rsp+30h] [rbp-108h] BYREF
_BYTE v6[32]; // [rsp+50h] [rbp-E8h] BYREF
_BYTE v7[32]; // [rsp+70h] [rbp-C8h] BYREF
_BYTE v8[32]; // [rsp+90h] [rbp-A8h] BYREF
_BYTE v9[32]; // [rsp+B0h] [rbp-88h] BYREF
int v10[8]; // [rsp+D0h] [rbp-68h] BYREF
int v11[9]; // [rsp+F0h] [rbp-48h] BYREF
minja::Value *v12; // [rsp+120h] [rbp-18h]
minja::Value *v13; // [rsp+128h] [rbp-10h]
char v14; // [rsp+137h] [rbp-1h]
v13 = a1;
v12 = a2;
if ( (minja::Value::is_null(a1) & 1) != 0 )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Undefined value or reference");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
if ( (minja::Value::is_number(a1) & 1) != 0 && (minja::Value::is_number(v12) & 1) != 0 )
{
minja::Value::get<double>(a1);
minja::Value::get<double>(v12);
v14 = 0;
}
else
{
if ( !minja::Value::is_string(a1) || !minja::Value::is_string(v12) )
{
v3 = __cxa_allocate_exception(0x10uLL);
minja::Value::dump[abi:cxx11]((long long)v6, (long long)a1, 0xFFFFFFFF, 0);
std::operator+<char>((long long)v7, (long long)"Cannot compare values: ", (long long)v6);
std::operator+<char>((long long)v8, (long long)v7, (long long)" > ");
minja::Value::dump[abi:cxx11]((long long)v5, (long long)v12, 0xFFFFFFFF, 0);
std::operator+<char>((long long)v9, (long long)v8, (long long)v5);
std::runtime_error::runtime_error(v3, v9);
__cxa_throw(
v3,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
minja::Value::get<std::string>(v11, a1);
minja::Value::get<std::string>(v10, v12);
v14 = std::operator><char>(v11, v10) & 1;
std::string::~string(v10);
std::string::~string(v11);
}
return v14 & 1;
}
| operator>:
SUB RSP,0x138
MOV qword ptr [RSP + 0x128],RDI
MOV qword ptr [RSP + 0x120],RSI
MOV RDI,qword ptr [RSP + 0x128]
MOV qword ptr [RSP + 0x20],RDI
CALL 0x001a18f0
TEST AL,0x1
JNZ 0x001e5c3f
JMP 0x001e5c9d
LAB_001e5c3f:
MOV EDI,0x10
CALL 0x00150540
MOV RDI,RAX
MOV RAX,RDI
MOV qword ptr [RSP + 0x18],RAX
LAB_001e5c54:
LEA RSI,[0x2ccce8]
CALL 0x00150340
LAB_001e5c60:
JMP 0x001e5c62
LAB_001e5c62:
MOV RDI,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [0x00353fb0]
MOV RDX,qword ptr [0x00353f78]
CALL 0x001508f0
LAB_001e5c9d:
MOV RDI,qword ptr [RSP + 0x20]
CALL 0x001a4840
TEST AL,0x1
JNZ 0x001e5cad
JMP 0x001e5cfb
LAB_001e5cad:
MOV RDI,qword ptr [RSP + 0x120]
CALL 0x001a4840
TEST AL,0x1
JNZ 0x001e5cc0
JMP 0x001e5cfb
LAB_001e5cc0:
MOV RDI,qword ptr [RSP + 0x20]
CALL 0x0019fc90
MOVSD qword ptr [RSP + 0x10],XMM0
MOV RDI,qword ptr [RSP + 0x120]
CALL 0x0019fc90
MOVAPS XMM1,XMM0
MOVSD XMM0,qword ptr [RSP + 0x10]
UCOMISD XMM0,XMM1
SETA AL
AND AL,0x1
MOV byte ptr [RSP + 0x137],AL
JMP 0x001e5f51
LAB_001e5cfb:
MOV RDI,qword ptr [RSP + 0x20]
CALL 0x001a1f30
TEST AL,0x1
JNZ 0x001e5d0e
JMP 0x001e5db0
LAB_001e5d0e:
MOV RDI,qword ptr [RSP + 0x120]
CALL 0x001a1f30
TEST AL,0x1
JNZ 0x001e5d24
JMP 0x001e5db0
LAB_001e5d24:
MOV RSI,qword ptr [RSP + 0x20]
LEA RDI,[RSP + 0xf0]
CALL 0x001a4860
MOV RSI,qword ptr [RSP + 0x120]
LAB_001e5d3e:
LEA RDI,[RSP + 0xd0]
CALL 0x001a4860
LAB_001e5d4b:
JMP 0x001e5d4d
LAB_001e5d4d:
LEA RDI,[RSP + 0xf0]
LEA RSI,[RSP + 0xd0]
CALL 0x001e6380
AND AL,0x1
MOV byte ptr [RSP + 0x137],AL
LEA RDI,[RSP + 0xd0]
CALL 0x001510c0
LEA RDI,[RSP + 0xf0]
CALL 0x001510c0
JMP 0x001e5f51
LAB_001e5db0:
MOV byte ptr [RSP + 0x2f],0x1
MOV EDI,0x10
CALL 0x00150540
MOV RSI,qword ptr [RSP + 0x20]
MOV qword ptr [RSP + 0x8],RAX
LAB_001e5dc9:
LEA RDI,[RSP + 0x50]
MOV EDX,0xffffffff
XOR ECX,ECX
CALL 0x0019feb0
JMP 0x001e5ddc
LAB_001e5ddc:
LEA RSI,[0x2d1c3c]
LEA RDI,[RSP + 0x70]
LEA RDX,[RSP + 0x50]
CALL 0x0017a6e0
JMP 0x001e5df4
LAB_001e5df4:
LEA RDX,[0x2d1c58]
LEA RDI,[RSP + 0x90]
LEA RSI,[RSP + 0x70]
CALL 0x001ae4c0
JMP 0x001e5e0f
LAB_001e5e0f:
MOV RSI,qword ptr [RSP + 0x120]
LAB_001e5e17:
LEA RDI,[RSP + 0x30]
MOV EDX,0xffffffff
XOR ECX,ECX
CALL 0x0019feb0
JMP 0x001e5e2a
LAB_001e5e2a:
LEA RDI,[RSP + 0xb0]
LEA RSI,[RSP + 0x90]
LEA RDX,[RSP + 0x30]
CALL 0x001ae510
JMP 0x001e5e46
LAB_001e5e46:
MOV RDI,qword ptr [RSP + 0x8]
LEA RSI,[RSP + 0xb0]
CALL 0x00150390
JMP 0x001e5e5a
LAB_001e5e5a:
MOV RDI,qword ptr [RSP + 0x8]
MOV byte ptr [RSP + 0x2f],0x0
MOV RSI,qword ptr [0x00353fb0]
MOV RDX,qword ptr [0x00353f78]
CALL 0x001508f0
LAB_001e5f51:
MOV AL,byte ptr [RSP + 0x137]
AND AL,0x1
ADD RSP,0x138
RET
|
/* minja::Value::TEMPNAMEPLACEHOLDERVALUE(minja::Value const&) const */
ulong __thiscall minja::Value::operator>(Value *this,Value *param_1)
{
ulong uVar1;
int8 extraout_RAX;
int7 uVar3;
int7 extraout_var;
runtime_error *prVar2;
double dVar4;
double dVar5;
int1 local_108 [32];
int1 local_e8 [32];
char local_c8 [32];
string local_a8 [32];
string local_88 [32];
string local_68 [32];
string local_48 [48];
Value *local_18;
Value *local_10;
int1 local_1;
local_18 = param_1;
local_10 = this;
uVar1 = is_null(this);
if ((uVar1 & 1) != 0) {
prVar2 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 001e5c54 to 001e5c5f has its CatchHandler @ 001e5c7a */
std::runtime_error::runtime_error(prVar2,"Undefined value or reference");
/* WARNING: Subroutine does not return */
__cxa_throw(prVar2,PTR_typeinfo_00353fb0,PTR__runtime_error_00353f78);
}
uVar1 = is_number(this);
if (((uVar1 & 1) == 0) || (uVar1 = is_number(local_18), (uVar1 & 1) == 0)) {
uVar1 = is_string(this);
if (((uVar1 & 1) == 0) || (uVar1 = is_string(local_18), (uVar1 & 1) == 0)) {
prVar2 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 001e5dc9 to 001e5dd9 has its CatchHandler @ 001e5e7c */
dump_abi_cxx11_((int)local_e8,SUB81(this,0));
/* try { // try from 001e5ddc to 001e5df1 has its CatchHandler @ 001e5e95 */
std::operator+(local_c8,(string *)"Cannot compare values: ");
/* try { // try from 001e5df4 to 001e5e0c has its CatchHandler @ 001e5eae */
std::operator+(local_a8,local_c8);
/* try { // try from 001e5e17 to 001e5e27 has its CatchHandler @ 001e5ec4 */
dump_abi_cxx11_((int)local_108,SUB81(local_18,0));
/* try { // try from 001e5e2a to 001e5e43 has its CatchHandler @ 001e5eda */
std::operator+(local_88,local_a8);
/* try { // try from 001e5e46 to 001e5e76 has its CatchHandler @ 001e5ef0 */
std::runtime_error::runtime_error(prVar2,local_88);
/* WARNING: Subroutine does not return */
__cxa_throw(prVar2,PTR_typeinfo_00353fb0,PTR__runtime_error_00353f78);
}
get<std::__cxx11::string>();
/* try { // try from 001e5d3e to 001e5d4a has its CatchHandler @ 001e5d8a */
get<std::__cxx11::string>();
local_1 = std::operator>(local_48,local_68);
std::__cxx11::string::~string(local_68);
std::__cxx11::string::~string(local_48);
uVar3 = extraout_var;
}
else {
dVar4 = get<double>(this);
dVar5 = get<double>(local_18);
local_1 = dVar5 < dVar4;
uVar3 = (int7)((ulong)extraout_RAX >> 8);
}
return CONCAT71(uVar3,local_1) & 0xffffffffffffff01;
}
| |
21,419 | ggml_cont_4d | monkey531[P]llama/ggml/src/ggml.c | struct ggml_tensor * ggml_cont_4d(
struct ggml_context * ctx,
struct ggml_tensor * a,
int64_t ne0,
int64_t ne1,
int64_t ne2,
int64_t ne3) {
GGML_ASSERT(ggml_nelements(a) == (ne0*ne1*ne2*ne3));
struct ggml_tensor * result = ggml_new_tensor_4d(ctx, a->type, ne0, ne1, ne2, ne3);
ggml_format_name(result, "%s (cont)", a->name);
result->op = GGML_OP_CONT;
result->src[0] = a;
return result;
} | O3 | c | ggml_cont_4d:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rsi, %rbx
movq 0x18(%rsi), %rax
imulq 0x10(%rsi), %rax
imulq 0x20(%rsi), %rax
imulq 0x28(%rsi), %rax
movq %rcx, %rsi
imulq %rdx, %rsi
movq %r8, %r10
imulq %r9, %r10
imulq %rsi, %r10
cmpq %r10, %rax
jne 0x1b91e
movl (%rbx), %esi
movq %rsp, %rax
movq %rdx, (%rax)
movq %rcx, 0x8(%rax)
movq %r8, 0x10(%rax)
movq %r9, 0x18(%rax)
movl $0x4, %edx
movq %rax, %rcx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x19bd0
movq %rax, %r14
leaq 0x100(%rbx), %rdx
leaq 0x2f078(%rip), %rsi # 0x4a972
movq %rax, %rdi
xorl %eax, %eax
callq 0x179f0
movl $0x20, 0x50(%r14)
movq %rbx, 0x98(%r14)
movq %r14, %rax
addq $0x28, %rsp
popq %rbx
popq %r14
retq
leaq 0x2ecee(%rip), %rdi # 0x4a613
leaq 0x2ed31(%rip), %rdx # 0x4a65d
leaq 0x2f018(%rip), %rcx # 0x4a94b
movl $0xbb9, %esi # imm = 0xBB9
xorl %eax, %eax
callq 0x17c60
| ggml_cont_4d:
push r14
push rbx
sub rsp, 28h
mov rbx, rsi
mov rax, [rsi+18h]
imul rax, [rsi+10h]
imul rax, [rsi+20h]
imul rax, [rsi+28h]
mov rsi, rcx
imul rsi, rdx
mov r10, r8
imul r10, r9
imul r10, rsi
cmp rax, r10
jnz short loc_1B91E
mov esi, [rbx]
mov rax, rsp
mov [rax], rdx
mov [rax+8], rcx
mov [rax+10h], r8
mov [rax+18h], r9
mov edx, 4
mov rcx, rax
xor r8d, r8d
xor r9d, r9d
call ggml_new_tensor_impl
mov r14, rax
lea rdx, [rbx+100h]
lea rsi, aSCont; "%s (cont)"
mov rdi, rax
xor eax, eax
call _ggml_format_name
mov dword ptr [r14+50h], 20h ; ' '
mov [r14+98h], rbx
mov rax, r14
add rsp, 28h
pop rbx
pop r14
retn
loc_1B91E:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlNelementsA_1; "ggml_nelements(a) == (ne0*ne1*ne2*ne3)"
mov esi, 0BB9h
xor eax, eax
call _ggml_abort
| long long ggml_cont_4d(long long a1, long long a2, long long a3, long long a4, long long a5, long long a6)
{
unsigned int v7; // esi
long long v8; // r14
_QWORD v10[7]; // [rsp+0h] [rbp-38h] BYREF
if ( *(_QWORD *)(a2 + 40) * *(_QWORD *)(a2 + 32) * *(_QWORD *)(a2 + 16) * *(_QWORD *)(a2 + 24) != a3 * a4 * a6 * a5 )
ggml_abort(
(unsigned int)"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/ggml/src/ggml.c",
3001,
(unsigned int)"GGML_ASSERT(%s) failed",
(unsigned int)"ggml_nelements(a) == (ne0*ne1*ne2*ne3)",
a5,
a6);
v7 = *(_DWORD *)a2;
v10[0] = a3;
v10[1] = a4;
v10[2] = a5;
v10[3] = a6;
v8 = ggml_new_tensor_impl(a1, v7, 4u, v10, 0LL, 0LL);
ggml_format_name(v8, (long long)"%s (cont)");
*(_DWORD *)(v8 + 80) = 32;
*(_QWORD *)(v8 + 152) = a2;
return v8;
}
| ggml_cont_4d:
PUSH R14
PUSH RBX
SUB RSP,0x28
MOV RBX,RSI
MOV RAX,qword ptr [RSI + 0x18]
IMUL RAX,qword ptr [RSI + 0x10]
IMUL RAX,qword ptr [RSI + 0x20]
IMUL RAX,qword ptr [RSI + 0x28]
MOV RSI,RCX
IMUL RSI,RDX
MOV R10,R8
IMUL R10,R9
IMUL R10,RSI
CMP RAX,R10
JNZ 0x0011b91e
MOV ESI,dword ptr [RBX]
MOV RAX,RSP
MOV qword ptr [RAX],RDX
MOV qword ptr [RAX + 0x8],RCX
MOV qword ptr [RAX + 0x10],R8
MOV qword ptr [RAX + 0x18],R9
MOV EDX,0x4
MOV RCX,RAX
XOR R8D,R8D
XOR R9D,R9D
CALL 0x00119bd0
MOV R14,RAX
LEA RDX,[RBX + 0x100]
LEA RSI,[0x14a972]
MOV RDI,RAX
XOR EAX,EAX
CALL 0x001179f0
MOV dword ptr [R14 + 0x50],0x20
MOV qword ptr [R14 + 0x98],RBX
MOV RAX,R14
ADD RSP,0x28
POP RBX
POP R14
RET
LAB_0011b91e:
LEA RDI,[0x14a613]
LEA RDX,[0x14a65d]
LEA RCX,[0x14a94b]
MOV ESI,0xbb9
XOR EAX,EAX
CALL 0x00117c60
|
long ggml_cont_4d(int8 param_1,int4 *param_2,long param_3,long param_4,long param_5,
long param_6)
{
long lVar1;
long local_38;
long local_30;
long local_28;
long local_20;
if (*(long *)(param_2 + 6) * *(long *)(param_2 + 4) * *(long *)(param_2 + 8) *
*(long *)(param_2 + 10) - param_5 * param_6 * param_4 * param_3 == 0) {
local_38 = param_3;
local_30 = param_4;
local_28 = param_5;
local_20 = param_6;
lVar1 = ggml_new_tensor_impl(param_1,*param_2,4,&local_38,0,0);
ggml_format_name(lVar1,"%s (cont)",param_2 + 0x40);
*(int4 *)(lVar1 + 0x50) = 0x20;
*(int4 **)(lVar1 + 0x98) = param_2;
return lVar1;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/ggml/src/ggml.c",0xbb9,
"GGML_ASSERT(%s) failed","ggml_nelements(a) == (ne0*ne1*ne2*ne3)");
}
| |
21,420 | fmt::v10::appender fmt::v10::detail::write_padded<(fmt::v10::align::type)2, fmt::v10::appender, char, char fmt::v10::detail::write_int<fmt::v10::appender, char, fmt::v10::appender fmt::v10::detail::write_int<char, fmt::v10::appender, unsigned int>(fmt::v10::appender, fmt::v10::detail::write_int_arg<unsigned int>, fmt::v10::format_specs<char> const&, fmt::v10::detail::locale_ref)::'lambda1'(fmt::v10::appender)>(char, int, unsigned int, fmt::v10::format_specs<fmt::v10::appender> const&, unsigned int)::'lambda'(fmt::v10::appender)&>(fmt::v10::appender, fmt::v10::format_specs<unsigned int> const&, unsigned long, unsigned long, char fmt::v10::detail::write_int<fmt::v10::appender, char, fmt::v10::appender fmt::v10::detail::write_int<char, fmt::v10::appender, unsigned int>(fmt::v10::appender, fmt::v10::detail::write_int_arg<unsigned int>, fmt::v10::format_specs<char> const&, fmt::v10::detail::locale_ref)::'lambda1'(fmt::v10::appender)>(char, int, unsigned int, fmt::v10::format_specs<fmt::v10::appender> const&, unsigned int)::'lambda'(fmt::v10::appender)&) | AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/fmt/bundled/format.h | FMT_CONSTEXPR auto write_padded(OutputIt out, const format_specs<Char>& specs,
size_t size, size_t width, F&& f) -> OutputIt {
static_assert(align == align::left || align == align::right, "");
unsigned spec_width = to_unsigned(specs.width);
size_t padding = spec_width > width ? spec_width - width : 0;
// Shifts are encoded as string literals because static constexpr is not
// supported in constexpr functions.
auto* shifts = align == align::left ? "\x1f\x1f\x00\x01" : "\x00\x1f\x00\x01";
size_t left_padding = padding >> shifts[specs.align];
size_t right_padding = padding - left_padding;
auto it = reserve(out, size + padding * specs.fill.size());
if (left_padding != 0) it = fill(it, left_padding, specs.fill);
it = f(it);
if (right_padding != 0) it = fill(it, right_padding, specs.fill);
return base_iterator(out, it);
} | O0 | c | fmt::v10::appender fmt::v10::detail::write_padded<(fmt::v10::align::type)2, fmt::v10::appender, char, char fmt::v10::detail::write_int<fmt::v10::appender, char, fmt::v10::appender fmt::v10::detail::write_int<char, fmt::v10::appender, unsigned int>(fmt::v10::appender, fmt::v10::detail::write_int_arg<unsigned int>, fmt::v10::format_specs<char> const&, fmt::v10::detail::locale_ref)::'lambda1'(fmt::v10::appender)>(char, int, unsigned int, fmt::v10::format_specs<fmt::v10::appender> const&, unsigned int)::'lambda'(fmt::v10::appender)&>(fmt::v10::appender, fmt::v10::format_specs<unsigned int> const&, unsigned long, unsigned long, char fmt::v10::detail::write_int<fmt::v10::appender, char, fmt::v10::appender fmt::v10::detail::write_int<char, fmt::v10::appender, unsigned int>(fmt::v10::appender, fmt::v10::detail::write_int_arg<unsigned int>, fmt::v10::format_specs<char> const&, fmt::v10::detail::locale_ref)::'lambda1'(fmt::v10::appender)>(char, int, unsigned int, fmt::v10::format_specs<fmt::v10::appender> const&, unsigned int)::'lambda'(fmt::v10::appender)&):
subq $0xb8, %rsp
movq %rdi, 0xa8(%rsp)
movq %rsi, 0xa0(%rsp)
movq %rdx, 0x98(%rsp)
movq %rcx, 0x90(%rsp)
movq %r8, 0x88(%rsp)
movq 0xa0(%rsp), %rax
movl (%rax), %edi
callq 0xc7930
movl %eax, 0x84(%rsp)
movl 0x84(%rsp), %eax
cmpq 0x90(%rsp), %rax
jbe 0xef00c
movl 0x84(%rsp), %eax
subq 0x90(%rsp), %rax
movq %rax, 0x10(%rsp)
jmp 0xef015
xorl %eax, %eax
movq %rax, 0x10(%rsp)
jmp 0xef015
movq 0x10(%rsp), %rax
movq %rax, 0x78(%rsp)
leaq 0x63d8e(%rip), %rax # 0x152db4
movq %rax, 0x70(%rsp)
movq 0x78(%rsp), %rax
movq 0x70(%rsp), %rcx
movq 0xa0(%rsp), %rdx
movw 0x9(%rdx), %dx
andw $0xf, %dx
movzbl %dl, %edx
movsbl (%rcx,%rdx), %ecx
movl %ecx, %ecx
shrq %cl, %rax
movq %rax, 0x68(%rsp)
movq 0x78(%rsp), %rax
subq 0x68(%rsp), %rax
movq %rax, 0x60(%rsp)
movq 0x98(%rsp), %rax
movq %rax, (%rsp)
movq 0x78(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0xa0(%rsp), %rdi
addq $0xb, %rdi
callq 0xcfec0
movq (%rsp), %rsi
movq %rax, %rcx
movq 0x8(%rsp), %rax
imulq %rcx, %rax
addq %rax, %rsi
leaq 0xa8(%rsp), %rdi
callq 0xcd6b0
movq (%rax), %rax
movq %rax, 0x58(%rsp)
cmpq $0x0, 0x68(%rsp)
je 0xef0f0
movq 0x58(%rsp), %rax
movq %rax, 0x48(%rsp)
movq 0x68(%rsp), %rsi
movq 0xa0(%rsp), %rdx
addq $0xb, %rdx
movq 0x48(%rsp), %rdi
callq 0xcfed0
movq %rax, 0x50(%rsp)
movq 0x50(%rsp), %rax
movq %rax, 0x58(%rsp)
movq 0x88(%rsp), %rdi
movq 0x58(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x38(%rsp), %rsi
callq 0xef1a0
movq %rax, 0x40(%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0x58(%rsp)
cmpq $0x0, 0x60(%rsp)
je 0xef157
movq 0x58(%rsp), %rax
movq %rax, 0x28(%rsp)
movq 0x60(%rsp), %rsi
movq 0xa0(%rsp), %rdx
addq $0xb, %rdx
movq 0x28(%rsp), %rdi
callq 0xcfed0
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x58(%rsp)
movq 0xa8(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0x58(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0xcd7e0
movq %rax, 0xb0(%rsp)
movq 0xb0(%rsp), %rax
addq $0xb8, %rsp
retq
nopw %cs:(%rax,%rax)
nop
| _ZN3fmt3v106detail12write_paddedILNS0_5align4typeE2ENS0_8appenderEcZNS1_9write_intIS5_mcEET_S7_T0_jRKNS0_12format_specsIT1_EERKNS1_14digit_groupingISA_EEEUlS5_E_EES8_S8_SD_mmOT2_:
sub rsp, 0B8h
mov [rsp+0B8h+var_10], rdi
mov [rsp+0B8h+var_18], rsi
mov [rsp+0B8h+var_20], rdx
mov [rsp+0B8h+var_28], rcx
mov [rsp+0B8h+var_30], r8
mov rax, [rsp+0B8h+var_18]
mov edi, [rax]
call _ZN3fmt3v106detail11to_unsignedIiEENSt13make_unsignedIT_E4typeES4_; fmt::v10::detail::to_unsigned<int>(int)
mov [rsp+0B8h+var_34], eax
mov eax, [rsp+0B8h+var_34]
cmp rax, [rsp+0B8h+var_28]
jbe short loc_EF00C
mov eax, [rsp+0B8h+var_34]
sub rax, [rsp+0B8h+var_28]
mov [rsp+0B8h+var_A8], rax
jmp short loc_EF015
loc_EF00C:
xor eax, eax
mov [rsp+0B8h+var_A8], rax
jmp short $+2
loc_EF015:
mov rax, [rsp+0B8h+var_A8]
mov [rsp+0B8h+var_40], rax
lea rax, byte_152DB4
mov [rsp+0B8h+var_48], rax
mov rax, [rsp+0B8h+var_40]
mov rcx, [rsp+0B8h+var_48]
mov rdx, [rsp+0B8h+var_18]
mov dx, [rdx+9]
and dx, 0Fh
movzx edx, dl
movsx ecx, byte ptr [rcx+rdx]
mov ecx, ecx
shr rax, cl
mov [rsp+0B8h+var_50], rax
mov rax, [rsp+0B8h+var_40]
sub rax, [rsp+0B8h+var_50]
mov [rsp+0B8h+var_58], rax
mov rax, [rsp+0B8h+var_20]
mov [rsp+0B8h+var_B8], rax
mov rax, [rsp+0B8h+var_40]
mov [rsp+0B8h+var_B0], rax
mov rdi, [rsp+0B8h+var_18]
add rdi, 0Bh
call _ZNK3fmt3v106detail6fill_tIcE4sizeEv; fmt::v10::detail::fill_t<char>::size(void)
mov rsi, [rsp+0B8h+var_B8]
mov rcx, rax
mov rax, [rsp+0B8h+var_B0]
imul rax, rcx
add rsi, rax
lea rdi, [rsp+0B8h+var_10]
call _ZN3fmt3v106detail7reserveINS0_8appenderEEERT_S5_m; fmt::v10::detail::reserve<fmt::v10::appender>(fmt::v10::appender &,ulong)
mov rax, [rax]
mov [rsp+0B8h+var_60], rax
cmp [rsp+0B8h+var_50], 0
jz short loc_EF0F0
mov rax, [rsp+0B8h+var_60]
mov [rsp+0B8h+var_70], rax
mov rsi, [rsp+0B8h+var_50]
mov rdx, [rsp+0B8h+var_18]
add rdx, 0Bh
mov rdi, [rsp+0B8h+var_70]
call _ZN3fmt3v106detail4fillINS0_8appenderEcEET_S4_mRKNS1_6fill_tIT0_EE; fmt::v10::detail::fill<fmt::v10::appender,char>(fmt::v10::appender,ulong,fmt::v10::detail::fill_t<char> const&)
mov [rsp+0B8h+var_68], rax
mov rax, [rsp+0B8h+var_68]
mov [rsp+0B8h+var_60], rax
loc_EF0F0:
mov rdi, [rsp+0B8h+var_30]
mov rax, [rsp+0B8h+var_60]
mov [rsp+0B8h+var_80], rax
mov rsi, [rsp+0B8h+var_80]
call _ZZN3fmt3v106detail9write_intINS0_8appenderEmcEET_S4_T0_jRKNS0_12format_specsIT1_EERKNS1_14digit_groupingIS7_EEENKUlS3_E_clES3_; fmt::v10::detail::write_int<fmt::v10::appender,ulong,char>(fmt::v10::appender,ulong,uint,fmt::v10::format_specs<char> const&,fmt::v10::detail::digit_grouping<char> const&)::{lambda(fmt::v10::appender)#1}::operator()(fmt::v10::appender)
mov [rsp+0B8h+var_78], rax
mov rax, [rsp+0B8h+var_78]
mov [rsp+0B8h+var_60], rax
cmp [rsp+0B8h+var_58], 0
jz short loc_EF157
mov rax, [rsp+0B8h+var_60]
mov [rsp+0B8h+var_90], rax
mov rsi, [rsp+0B8h+var_58]
mov rdx, [rsp+0B8h+var_18]
add rdx, 0Bh
mov rdi, [rsp+0B8h+var_90]
call _ZN3fmt3v106detail4fillINS0_8appenderEcEET_S4_mRKNS1_6fill_tIT0_EE; fmt::v10::detail::fill<fmt::v10::appender,char>(fmt::v10::appender,ulong,fmt::v10::detail::fill_t<char> const&)
mov [rsp+0B8h+var_88], rax
mov rax, [rsp+0B8h+var_88]
mov [rsp+0B8h+var_60], rax
loc_EF157:
mov rax, [rsp+0B8h+var_10]
mov [rsp+0B8h+var_98], rax
mov rax, [rsp+0B8h+var_60]
mov [rsp+0B8h+var_A0], rax
mov rdi, [rsp+0B8h+var_98]
mov rsi, [rsp+0B8h+var_A0]
call _ZN3fmt3v106detail13base_iteratorINS0_8appenderEEET_S4_S4_; fmt::v10::detail::base_iterator<fmt::v10::appender>(fmt::v10::appender,fmt::v10::appender)
mov [rsp+0B8h+var_8], rax
mov rax, [rsp+0B8h+var_8]
add rsp, 0B8h
retn
| long long fmt::v10::detail::write_padded<(fmt::v10::align::type)2,fmt::v10::appender,char,fmt::v10::appender fmt::v10::detail::write_int<fmt::v10::appender,unsigned long,char>(fmt::v10::appender,unsigned long,unsigned int,fmt::v10::format_specs<char> const&,fmt::v10::detail::digit_grouping<char> const&)::{lambda(fmt::v10::appender)#1}>(
long long a1,
long long a2,
long long a3,
unsigned long long a4,
long long a5)
{
unsigned long long v6; // [rsp+10h] [rbp-A8h]
long long v7; // [rsp+58h] [rbp-60h]
long long v8; // [rsp+58h] [rbp-60h]
unsigned long long v9; // [rsp+60h] [rbp-58h]
unsigned long long v10; // [rsp+68h] [rbp-50h]
unsigned int v11; // [rsp+84h] [rbp-34h]
long long v14; // [rsp+A8h] [rbp-10h] BYREF
v14 = a1;
v11 = fmt::v10::detail::to_unsigned<int>(*(_DWORD *)a2);
if ( v11 <= a4 )
v6 = 0LL;
else
v6 = v11 - a4;
v10 = v6 >> byte_152DB4[*(_WORD *)(a2 + 9) & 0xF];
v9 = v6 - v10;
fmt::v10::detail::fill_t<char>::size(a2 + 11);
v7 = *(_QWORD *)fmt::v10::detail::reserve<fmt::v10::appender>((long long)&v14);
if ( v10 )
v7 = fmt::v10::detail::fill<fmt::v10::appender,char>(v7, v10, a2 + 11);
v8 = fmt::v10::detail::write_int<fmt::v10::appender,unsigned long,char>(fmt::v10::appender,unsigned long,unsigned int,fmt::v10::format_specs<char> const&,fmt::v10::detail::digit_grouping<char> const&)::{lambda(fmt::v10::appender)#1}::operator()(
a5,
v7);
if ( v9 )
v8 = fmt::v10::detail::fill<fmt::v10::appender,char>(v8, v9, a2 + 11);
return fmt::v10::detail::base_iterator<fmt::v10::appender>(v14, v8);
}
| write_padded<(fmt::v10::align::type)2,fmt::v10::appender,char,fmt::v10::detail::write_int<fmt::v10::appender,unsigned_long,char>(fmt::v10::appender,unsigned_long,unsigned_int,fmt::v10::format_specs<char>const&,fmt::v10::detail::digit_grouping<char>const&)::{lambda(fmt::v10::appender)#1}>:
SUB RSP,0xb8
MOV qword ptr [RSP + 0xa8],RDI
MOV qword ptr [RSP + 0xa0],RSI
MOV qword ptr [RSP + 0x98],RDX
MOV qword ptr [RSP + 0x90],RCX
MOV qword ptr [RSP + 0x88],R8
MOV RAX,qword ptr [RSP + 0xa0]
MOV EDI,dword ptr [RAX]
CALL 0x001c7930
MOV dword ptr [RSP + 0x84],EAX
MOV EAX,dword ptr [RSP + 0x84]
CMP RAX,qword ptr [RSP + 0x90]
JBE 0x001ef00c
MOV EAX,dword ptr [RSP + 0x84]
SUB RAX,qword ptr [RSP + 0x90]
MOV qword ptr [RSP + 0x10],RAX
JMP 0x001ef015
LAB_001ef00c:
XOR EAX,EAX
MOV qword ptr [RSP + 0x10],RAX
JMP 0x001ef015
LAB_001ef015:
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x78],RAX
LEA RAX,[0x252db4]
MOV qword ptr [RSP + 0x70],RAX
MOV RAX,qword ptr [RSP + 0x78]
MOV RCX,qword ptr [RSP + 0x70]
MOV RDX,qword ptr [RSP + 0xa0]
MOV DX,word ptr [RDX + 0x9]
AND DX,0xf
MOVZX EDX,DL
MOVSX ECX,byte ptr [RCX + RDX*0x1]
MOV ECX,ECX
SHR RAX,CL
MOV qword ptr [RSP + 0x68],RAX
MOV RAX,qword ptr [RSP + 0x78]
SUB RAX,qword ptr [RSP + 0x68]
MOV qword ptr [RSP + 0x60],RAX
MOV RAX,qword ptr [RSP + 0x98]
MOV qword ptr [RSP],RAX
MOV RAX,qword ptr [RSP + 0x78]
MOV qword ptr [RSP + 0x8],RAX
MOV RDI,qword ptr [RSP + 0xa0]
ADD RDI,0xb
CALL 0x001cfec0
MOV RSI,qword ptr [RSP]
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x8]
IMUL RAX,RCX
ADD RSI,RAX
LEA RDI,[RSP + 0xa8]
CALL 0x001cd6b0
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + 0x58],RAX
CMP qword ptr [RSP + 0x68],0x0
JZ 0x001ef0f0
MOV RAX,qword ptr [RSP + 0x58]
MOV qword ptr [RSP + 0x48],RAX
MOV RSI,qword ptr [RSP + 0x68]
MOV RDX,qword ptr [RSP + 0xa0]
ADD RDX,0xb
MOV RDI,qword ptr [RSP + 0x48]
CALL 0x001cfed0
MOV qword ptr [RSP + 0x50],RAX
MOV RAX,qword ptr [RSP + 0x50]
MOV qword ptr [RSP + 0x58],RAX
LAB_001ef0f0:
MOV RDI,qword ptr [RSP + 0x88]
MOV RAX,qword ptr [RSP + 0x58]
MOV qword ptr [RSP + 0x38],RAX
MOV RSI,qword ptr [RSP + 0x38]
CALL 0x001ef1a0
MOV qword ptr [RSP + 0x40],RAX
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP + 0x58],RAX
CMP qword ptr [RSP + 0x60],0x0
JZ 0x001ef157
MOV RAX,qword ptr [RSP + 0x58]
MOV qword ptr [RSP + 0x28],RAX
MOV RSI,qword ptr [RSP + 0x60]
MOV RDX,qword ptr [RSP + 0xa0]
ADD RDX,0xb
MOV RDI,qword ptr [RSP + 0x28]
CALL 0x001cfed0
MOV qword ptr [RSP + 0x30],RAX
MOV RAX,qword ptr [RSP + 0x30]
MOV qword ptr [RSP + 0x58],RAX
LAB_001ef157:
MOV RAX,qword ptr [RSP + 0xa8]
MOV qword ptr [RSP + 0x20],RAX
MOV RAX,qword ptr [RSP + 0x58]
MOV qword ptr [RSP + 0x18],RAX
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x18]
CALL 0x001cd7e0
MOV qword ptr [RSP + 0xb0],RAX
MOV RAX,qword ptr [RSP + 0xb0]
ADD RSP,0xb8
RET
|
/* fmt::v10::appender fmt::v10::detail::write_padded<(fmt::v10::align::type)2, fmt::v10::appender,
char, fmt::v10::detail::write_int<fmt::v10::appender, unsigned long, char>(fmt::v10::appender,
unsigned long, unsigned int, fmt::v10::format_specs<char> const&,
fmt::v10::detail::digit_grouping<char>
const&)::{lambda(fmt::v10::appender)#1}>(fmt::v10::appender, fmt::v10::format_specs<char> const&,
unsigned long, unsigned long, fmt::v10::detail::write_int<fmt::v10::appender, unsigned long,
char>(fmt::v10::appender, unsigned long, unsigned int, fmt::v10::format_specs<char> const&,
fmt::v10::detail::digit_grouping<char> const&)::{lambda(fmt::v10::appender)#1}&&) */
int8
fmt::v10::detail::
write_padded<(fmt::v10::align::type)2,fmt::v10::appender,char,fmt::v10::detail::write_int<fmt::v10::appender,unsigned_long,char>(fmt::v10::appender,unsigned_long,unsigned_int,fmt::v10::format_specs<char>const&,fmt::v10::detail::digit_grouping<char>const&)::_lambda(fmt::v10::appender)_1_>
(int8 param_1,int *param_2,long param_3,ulong param_4,
_lambda_fmt__v10__appender__1_ *param_5)
{
uint uVar1;
ulong uVar2;
long lVar3;
int8 *puVar4;
int8 uVar5;
ulong local_a8;
int8 local_60;
int8 local_10 [2];
local_10[0] = param_1;
uVar1 = to_unsigned<int>(*param_2);
if (param_4 < uVar1) {
local_a8 = uVar1 - param_4;
}
else {
local_a8 = 0;
}
uVar2 = local_a8 >> ((&DAT_00252db4)[(byte)*(int2 *)((long)param_2 + 9) & 0xf] & 0x3f);
lVar3 = fill_t<char>::size((fill_t<char> *)((long)param_2 + 0xb));
puVar4 = (int8 *)
reserve<fmt::v10::appender>((appender *)local_10,param_3 + local_a8 * lVar3);
local_60 = *puVar4;
if (uVar2 != 0) {
local_60 = fill<fmt::v10::appender,char>(local_60,uVar2,(long)param_2 + 0xb);
}
local_60 = write_int<fmt::v10::appender,unsigned_long,char>(fmt::v10::appender,unsigned_long,unsigned_int,fmt::v10::format_specs<char>const&,fmt::v10::detail::digit_grouping<char>const&)
::{lambda(fmt::v10::appender)#1}::operator()(param_5,local_60);
if (local_a8 - uVar2 != 0) {
local_60 = fill<fmt::v10::appender,char>(local_60,local_a8 - uVar2,(long)param_2 + 0xb);
}
uVar5 = base_iterator<fmt::v10::appender>(local_10[0],local_60);
return uVar5;
}
| |
21,421 | ps_fetch_float | eloqsql/libmariadb/libmariadb/ma_stmt_codec.c | static
void ps_fetch_float(MYSQL_BIND *r_param, const MYSQL_FIELD * field, unsigned char **row)
{
switch(r_param->buffer_type)
{
case MYSQL_TYPE_FLOAT:
{
float *value= (float *)r_param->buffer;
float4get(*value, *row);
r_param->buffer_length= 4;
*r_param->error= 0;
}
break;
default:
{
float value;
memcpy(&value, *row, sizeof(float));
float4get(value, (char *)*row);
convert_from_float(r_param, field, value, sizeof(float));
}
break;
}
(*row)+= 4;
} | O0 | c | ps_fetch_float:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl 0x60(%rax), %eax
subl $0x4, %eax
jne 0x2ef16
jmp 0x2eee2
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq (%rcx), %rcx
movl (%rcx), %ecx
movl %ecx, (%rax)
movq -0x8(%rbp), %rax
movq $0x4, 0x40(%rax)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movb $0x0, (%rax)
jmp 0x2ef45
movq -0x18(%rbp), %rax
movq (%rax), %rax
movl (%rax), %eax
movl %eax, -0x24(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movl (%rax), %eax
movl %eax, -0x24(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movss -0x24(%rbp), %xmm0
movl $0x4, %edx
callq 0x30790
movq -0x18(%rbp), %rax
movq (%rax), %rcx
addq $0x4, %rcx
movq %rcx, (%rax)
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
| ps_fetch_float:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov rax, [rbp+var_8]
mov eax, [rax+60h]
sub eax, 4
jnz short loc_2EF16
jmp short $+2
loc_2EEE2:
mov rax, [rbp+var_8]
mov rax, [rax+10h]
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
mov rcx, [rbp+var_18]
mov rcx, [rcx]
mov ecx, [rcx]
mov [rax], ecx
mov rax, [rbp+var_8]
mov qword ptr [rax+40h], 4
mov rax, [rbp+var_8]
mov rax, [rax+18h]
mov byte ptr [rax], 0
jmp short loc_2EF45
loc_2EF16:
mov rax, [rbp+var_18]
mov rax, [rax]
mov eax, [rax]
mov [rbp+var_24], eax
mov rax, [rbp+var_18]
mov rax, [rax]
mov eax, [rax]
mov [rbp+var_24], eax
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
movss xmm0, [rbp+var_24]
mov edx, 4
call convert_from_float
loc_2EF45:
mov rax, [rbp+var_18]
mov rcx, [rax]
add rcx, 4
mov [rax], rcx
add rsp, 30h
pop rbp
retn
| float ** ps_fetch_float(long long a1, long long a2, float **a3)
{
float **result; // rax
if ( *(_DWORD *)(a1 + 96) == 4 )
{
**(float **)(a1 + 16) = **a3;
*(_QWORD *)(a1 + 64) = 4LL;
**(_BYTE **)(a1 + 24) = 0;
}
else
{
convert_from_float(a1, a2, 4LL, **a3);
}
result = a3;
++*a3;
return result;
}
| ps_fetch_float:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x60]
SUB EAX,0x4
JNZ 0x0012ef16
JMP 0x0012eee2
LAB_0012eee2:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RCX]
MOV ECX,dword ptr [RCX]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x40],0x4
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x18]
MOV byte ptr [RAX],0x0
JMP 0x0012ef45
LAB_0012ef16:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x24],EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x24],EAX
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOVSS XMM0,dword ptr [RBP + -0x24]
MOV EDX,0x4
CALL 0x00130790
LAB_0012ef45:
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RAX]
ADD RCX,0x4
MOV qword ptr [RAX],RCX
ADD RSP,0x30
POP RBP
RET
|
void ps_fetch_float(long param_1,int8 param_2,long *param_3)
{
if (*(int *)(param_1 + 0x60) == 4) {
**(int4 **)(param_1 + 0x10) = *(int4 *)*param_3;
*(int8 *)(param_1 + 0x40) = 4;
**(int1 **)(param_1 + 0x18) = 0;
}
else {
convert_from_float(*(int4 *)*param_3,param_1,param_2,4);
}
*param_3 = *param_3 + 4;
return;
}
| |
21,422 | PVG_FT_MulDiv | dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-ft-math.c | PVG_FT_Long PVG_FT_MulDiv(PVG_FT_Long a, PVG_FT_Long b, PVG_FT_Long c)
{
PVG_FT_Int s = 1;
PVG_FT_Long d;
PVG_FT_MOVE_SIGN(a, s);
PVG_FT_MOVE_SIGN(b, s);
PVG_FT_MOVE_SIGN(c, s);
d = (PVG_FT_Long)(c > 0 ? ((PVG_FT_Int64)a * b + (c >> 1)) / c : 0x7FFFFFFFL);
return (s > 0) ? d : -d;
} | O0 | c | PVG_FT_MulDiv:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl $0x1, -0x1c(%rbp)
cmpq $0x0, -0x8(%rbp)
jge 0x8aaf0
xorl %eax, %eax
subq -0x8(%rbp), %rax
movq %rax, -0x8(%rbp)
xorl %eax, %eax
subl -0x1c(%rbp), %eax
movl %eax, -0x1c(%rbp)
jmp 0x8aaf2
jmp 0x8aaf4
cmpq $0x0, -0x10(%rbp)
jge 0x8ab0d
xorl %eax, %eax
subq -0x10(%rbp), %rax
movq %rax, -0x10(%rbp)
xorl %eax, %eax
subl -0x1c(%rbp), %eax
movl %eax, -0x1c(%rbp)
jmp 0x8ab0f
jmp 0x8ab11
cmpq $0x0, -0x18(%rbp)
jge 0x8ab2a
xorl %eax, %eax
subq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
xorl %eax, %eax
subl -0x1c(%rbp), %eax
movl %eax, -0x1c(%rbp)
jmp 0x8ab2c
cmpq $0x0, -0x18(%rbp)
jle 0x8ab52
movq -0x8(%rbp), %rax
imulq -0x10(%rbp), %rax
movq -0x18(%rbp), %rcx
sarq %rcx
addq %rcx, %rax
cqto
idivq -0x18(%rbp)
movq %rax, -0x30(%rbp)
jmp 0x8ab5d
movl $0x7fffffff, %eax # imm = 0x7FFFFFFF
movq %rax, -0x30(%rbp)
jmp 0x8ab5d
movq -0x30(%rbp), %rax
movq %rax, -0x28(%rbp)
cmpl $0x0, -0x1c(%rbp)
jle 0x8ab75
movq -0x28(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x8ab7f
xorl %eax, %eax
subq -0x28(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
popq %rbp
retq
nopw %cs:(%rax,%rax)
| PVG_FT_MulDiv:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_1C], 1
cmp [rbp+var_8], 0
jge short loc_8AAF0
xor eax, eax
sub rax, [rbp+var_8]
mov [rbp+var_8], rax
xor eax, eax
sub eax, [rbp+var_1C]
mov [rbp+var_1C], eax
loc_8AAF0:
jmp short $+2
loc_8AAF2:
jmp short $+2
loc_8AAF4:
cmp [rbp+var_10], 0
jge short loc_8AB0D
xor eax, eax
sub rax, [rbp+var_10]
mov [rbp+var_10], rax
xor eax, eax
sub eax, [rbp+var_1C]
mov [rbp+var_1C], eax
loc_8AB0D:
jmp short $+2
loc_8AB0F:
jmp short $+2
loc_8AB11:
cmp [rbp+var_18], 0
jge short loc_8AB2A
xor eax, eax
sub rax, [rbp+var_18]
mov [rbp+var_18], rax
xor eax, eax
sub eax, [rbp+var_1C]
mov [rbp+var_1C], eax
loc_8AB2A:
jmp short $+2
loc_8AB2C:
cmp [rbp+var_18], 0
jle short loc_8AB52
mov rax, [rbp+var_8]
imul rax, [rbp+var_10]
mov rcx, [rbp+var_18]
sar rcx, 1
add rax, rcx
cqo
idiv [rbp+var_18]
mov [rbp+var_30], rax
jmp short loc_8AB5D
loc_8AB52:
mov eax, 7FFFFFFFh
mov [rbp+var_30], rax
jmp short $+2
loc_8AB5D:
mov rax, [rbp+var_30]
mov [rbp+var_28], rax
cmp [rbp+var_1C], 0
jle short loc_8AB75
mov rax, [rbp+var_28]
mov [rbp+var_38], rax
jmp short loc_8AB7F
loc_8AB75:
xor eax, eax
sub rax, [rbp+var_28]
mov [rbp+var_38], rax
loc_8AB7F:
mov rax, [rbp+var_38]
pop rbp
retn
| long long PVG_FT_MulDiv(long long a1, long long a2, long long a3)
{
long long v5; // [rsp+8h] [rbp-30h]
int v6; // [rsp+1Ch] [rbp-1Ch]
long long v7; // [rsp+20h] [rbp-18h]
long long v8; // [rsp+28h] [rbp-10h]
long long v9; // [rsp+30h] [rbp-8h]
v9 = a1;
v8 = a2;
v7 = a3;
v6 = 1;
if ( a1 < 0 )
{
v9 = -a1;
v6 = -1;
}
if ( a2 < 0 )
{
v8 = -a2;
v6 = -v6;
}
if ( a3 < 0 )
{
v7 = -a3;
v6 = -v6;
}
if ( v7 <= 0 )
v5 = 0x7FFFFFFFLL;
else
v5 = ((v7 >> 1) + v8 * v9) / v7;
if ( v6 <= 0 )
return -v5;
else
return v5;
}
| PVG_FT_MulDiv:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV dword ptr [RBP + -0x1c],0x1
CMP qword ptr [RBP + -0x8],0x0
JGE 0x0018aaf0
XOR EAX,EAX
SUB RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x8],RAX
XOR EAX,EAX
SUB EAX,dword ptr [RBP + -0x1c]
MOV dword ptr [RBP + -0x1c],EAX
LAB_0018aaf0:
JMP 0x0018aaf2
LAB_0018aaf2:
JMP 0x0018aaf4
LAB_0018aaf4:
CMP qword ptr [RBP + -0x10],0x0
JGE 0x0018ab0d
XOR EAX,EAX
SUB RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x10],RAX
XOR EAX,EAX
SUB EAX,dword ptr [RBP + -0x1c]
MOV dword ptr [RBP + -0x1c],EAX
LAB_0018ab0d:
JMP 0x0018ab0f
LAB_0018ab0f:
JMP 0x0018ab11
LAB_0018ab11:
CMP qword ptr [RBP + -0x18],0x0
JGE 0x0018ab2a
XOR EAX,EAX
SUB RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
SUB EAX,dword ptr [RBP + -0x1c]
MOV dword ptr [RBP + -0x1c],EAX
LAB_0018ab2a:
JMP 0x0018ab2c
LAB_0018ab2c:
CMP qword ptr [RBP + -0x18],0x0
JLE 0x0018ab52
MOV RAX,qword ptr [RBP + -0x8]
IMUL RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x18]
SAR RCX,0x1
ADD RAX,RCX
CQO
IDIV qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
JMP 0x0018ab5d
LAB_0018ab52:
MOV EAX,0x7fffffff
MOV qword ptr [RBP + -0x30],RAX
JMP 0x0018ab5d
LAB_0018ab5d:
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x28],RAX
CMP dword ptr [RBP + -0x1c],0x0
JLE 0x0018ab75
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x38],RAX
JMP 0x0018ab7f
LAB_0018ab75:
XOR EAX,EAX
SUB RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x38],RAX
LAB_0018ab7f:
MOV RAX,qword ptr [RBP + -0x38]
POP RBP
RET
|
long PVG_FT_MulDiv(long param_1,long param_2,long param_3)
{
int8 local_40;
int8 local_38;
int4 local_24;
int8 local_20;
int8 local_18;
int8 local_10;
local_24 = 1;
local_10 = param_1;
if (param_1 < 0) {
local_10 = -param_1;
local_24 = -1;
}
local_18 = param_2;
if (param_2 < 0) {
local_18 = -param_2;
local_24 = -local_24;
}
local_20 = param_3;
if (param_3 < 0) {
local_20 = -param_3;
local_24 = -local_24;
}
if (local_20 < 1) {
local_38 = 0x7fffffff;
}
else {
local_38 = (local_10 * local_18 + (local_20 >> 1)) / local_20;
}
if (local_24 < 1) {
local_40 = -local_38;
}
else {
local_40 = local_38;
}
return local_40;
}
| |
21,423 | PVG_FT_MulDiv | dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-ft-math.c | PVG_FT_Long PVG_FT_MulDiv(PVG_FT_Long a, PVG_FT_Long b, PVG_FT_Long c)
{
PVG_FT_Int s = 1;
PVG_FT_Long d;
PVG_FT_MOVE_SIGN(a, s);
PVG_FT_MOVE_SIGN(b, s);
PVG_FT_MOVE_SIGN(c, s);
d = (PVG_FT_Long)(c > 0 ? ((PVG_FT_Int64)a * b + (c >> 1)) / c : 0x7FFFFFFFL);
return (s > 0) ? d : -d;
} | O1 | c | PVG_FT_MulDiv:
movq %rdx, %rcx
testq %rdx, %rdx
je 0x42175
movq %rcx, %r8
negq %r8
cmovsq %rcx, %r8
movq %rsi, %rax
imulq %rdi, %rax
movq %rax, %rdx
negq %rdx
cmovsq %rax, %rdx
movq %r8, %rax
shrq %rax
addq %rdx, %rax
xorl %edx, %edx
divq %r8
jmp 0x4217a
movl $0x7fffffff, %eax # imm = 0x7FFFFFFF
sarq $0x3f, %rdi
orl $0x1, %edi
movl %edi, %edx
negl %edx
testq %rsi, %rsi
cmovnsl %edi, %edx
movl %edx, %esi
negl %esi
testq %rcx, %rcx
cmovnsl %edx, %esi
movq %rax, %rcx
negq %rcx
testl %esi, %esi
cmovgq %rax, %rcx
movq %rcx, %rax
retq
| PVG_FT_MulDiv:
mov rcx, rdx
test rdx, rdx
jz short loc_42175
mov r8, rcx
neg r8
cmovs r8, rcx
mov rax, rsi
imul rax, rdi
mov rdx, rax
neg rdx
cmovs rdx, rax
mov rax, r8
shr rax, 1
add rax, rdx
xor edx, edx
div r8
jmp short loc_4217A
loc_42175:
mov eax, 7FFFFFFFh
loc_4217A:
sar rdi, 3Fh
or edi, 1
mov edx, edi
neg edx
test rsi, rsi
cmovns edx, edi
mov esi, edx
neg esi
test rcx, rcx
cmovns esi, edx
mov rcx, rax
neg rcx
test esi, esi
cmovg rcx, rax
mov rax, rcx
retn
| long long PVG_FT_MulDiv(long long a1, long long a2, long long a3)
{
unsigned long long v4; // r8
long long v5; // rdx
long long v6; // rax
int v7; // edi
int v8; // edx
int v9; // esi
long long v10; // rcx
if ( a3 )
{
v4 = -a3;
if ( a3 > 0 )
v4 = a3;
v5 = -(a1 * a2);
if ( a1 * a2 > 0 )
v5 = a1 * a2;
v6 = (v5 + (v4 >> 1)) / v4;
}
else
{
v6 = 0x7FFFFFFFLL;
}
v7 = (a1 >> 63) | 1;
v8 = -v7;
if ( a2 >= 0 )
v8 = v7;
v9 = -v8;
if ( a3 >= 0 )
v9 = v8;
v10 = -v6;
if ( v9 > 0 )
return v6;
return v10;
}
| PVG_FT_MulDiv:
MOV RCX,RDX
TEST RDX,RDX
JZ 0x00142175
MOV R8,RCX
NEG R8
CMOVS R8,RCX
MOV RAX,RSI
IMUL RAX,RDI
MOV RDX,RAX
NEG RDX
CMOVS RDX,RAX
MOV RAX,R8
SHR RAX,0x1
ADD RAX,RDX
XOR EDX,EDX
DIV R8
JMP 0x0014217a
LAB_00142175:
MOV EAX,0x7fffffff
LAB_0014217a:
SAR RDI,0x3f
OR EDI,0x1
MOV EDX,EDI
NEG EDX
TEST RSI,RSI
CMOVNS EDX,EDI
MOV ESI,EDX
NEG ESI
TEST RCX,RCX
CMOVNS ESI,EDX
MOV RCX,RAX
NEG RCX
TEST ESI,ESI
CMOVG RCX,RAX
MOV RAX,RCX
RET
|
ulong PVG_FT_MulDiv(long param_1,long param_2,ulong param_3)
{
long lVar1;
ulong uVar2;
ulong uVar3;
uint uVar4;
long lVar5;
uint uVar6;
if (param_3 == 0) {
uVar2 = 0x7fffffff;
}
else {
uVar2 = -param_3;
if (0 < (long)param_3) {
uVar2 = param_3;
}
lVar1 = param_2 * param_1;
lVar5 = -lVar1;
if (0 < lVar1) {
lVar5 = lVar1;
}
uVar2 = ((uVar2 >> 1) + lVar5) / uVar2;
}
uVar6 = (uint)(param_1 >> 0x3f) | 1;
uVar4 = -uVar6;
if (-1 < param_2) {
uVar4 = uVar6;
}
uVar6 = -uVar4;
if (-1 < (long)param_3) {
uVar6 = uVar4;
}
uVar3 = -uVar2;
if (0 < (int)uVar6) {
uVar3 = uVar2;
}
return uVar3;
}
| |
21,424 | my_thread_destory_thr_mutex | eloqsql/mysys/my_thr_init.c | static void my_thread_destory_thr_mutex(struct st_my_thread_var *var)
{
mysql_mutex_destroy(&var->mutex);
mysql_cond_destroy(&var->suspend);
} | O3 | c | my_thread_destory_thr_mutex:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x40(%rdi), %r14
movq 0x80(%rdi), %rdi
testq %rdi, %rdi
je 0x26e63
leaq 0x2c79ce(%rip), %rax # 0x2ee820
movq (%rax), %rax
callq *0x48(%rax)
movq $0x0, 0x80(%rbx)
movq %r14, %rdi
callq 0x24310
movq 0x38(%rbx), %rdi
testq %rdi, %rdi
jne 0x26e84
addq $0x8, %rbx
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x24540
leaq 0x2c7995(%rip), %rax # 0x2ee820
movq (%rax), %rax
callq *0x68(%rax)
movq $0x0, 0x38(%rbx)
jmp 0x26e74
| my_thread_destory_thr_mutex:
push rbp
mov rbp, rsp
push r14
push rbx
mov rbx, rdi
lea r14, [rdi+40h]
mov rdi, [rdi+80h]
test rdi, rdi
jz short loc_26E63
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+48h]
mov qword ptr [rbx+80h], 0
loc_26E63:
mov rdi, r14
call _pthread_mutex_destroy
mov rdi, [rbx+38h]
test rdi, rdi
jnz short loc_26E84
loc_26E74:
add rbx, 8
mov rdi, rbx
pop rbx
pop r14
pop rbp
jmp _pthread_cond_destroy
loc_26E84:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+68h]
mov qword ptr [rbx+38h], 0
jmp short loc_26E74
| long long my_thread_destory_thr_mutex(long long a1)
{
if ( *(_QWORD *)(a1 + 128) )
{
(*((void (**)(void))PSI_server[0] + 9))();
*(_QWORD *)(a1 + 128) = 0LL;
}
pthread_mutex_destroy(a1 + 64);
if ( *(_QWORD *)(a1 + 56) )
{
(*((void (**)(void))PSI_server[0] + 13))();
*(_QWORD *)(a1 + 56) = 0LL;
}
return pthread_cond_destroy(a1 + 8);
}
| my_thread_destory_thr_mutex:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV RBX,RDI
LEA R14,[RDI + 0x40]
MOV RDI,qword ptr [RDI + 0x80]
TEST RDI,RDI
JZ 0x00126e63
LEA RAX,[0x3ee820]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x48]
MOV qword ptr [RBX + 0x80],0x0
LAB_00126e63:
MOV RDI,R14
CALL 0x00124310
MOV RDI,qword ptr [RBX + 0x38]
TEST RDI,RDI
JNZ 0x00126e84
LAB_00126e74:
ADD RBX,0x8
MOV RDI,RBX
POP RBX
POP R14
POP RBP
JMP 0x00124540
LAB_00126e84:
LEA RAX,[0x3ee820]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x68]
MOV qword ptr [RBX + 0x38],0x0
JMP 0x00126e74
|
void my_thread_destory_thr_mutex(long param_1)
{
if (*(long *)(param_1 + 0x80) != 0) {
(**(code **)(PSI_server + 0x48))();
*(int8 *)(param_1 + 0x80) = 0;
}
pthread_mutex_destroy((pthread_mutex_t *)(param_1 + 0x40));
if (*(long *)(param_1 + 0x38) != 0) {
(**(code **)(PSI_server + 0x68))();
*(int8 *)(param_1 + 0x38) = 0;
}
pthread_cond_destroy((pthread_cond_t *)(param_1 + 8));
return;
}
| |
21,425 | my_numcells_cp932 | eloqsql/strings/ctype-cp932.c | static
size_t my_numcells_cp932(CHARSET_INFO *cs __attribute__((unused)),
const char *str, const char *str_end)
{
size_t clen= 0;
const uchar *b= (const uchar *) str;
const uchar *e= (const uchar *) str_end;
for (clen= 0; b < e; )
{
if (*b >= 0xA1 && *b <= 0xDF)
{
clen++;
b++;
}
else if (*b > 0x7F)
{
clen+= 2;
b+= 2;
}
else
{
clen++;
b++;
}
}
return clen;
} | O0 | c | my_numcells_cp932:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x30(%rbp), %rax
jae 0x359e5
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0xa1, %eax
jl 0x359a0
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0xdf, %eax
jg 0x359a0
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x359e0
movq -0x28(%rbp), %rax
movzbl (%rax), %eax
cmpl $0x7f, %eax
jle 0x359c6
movq -0x20(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
jmp 0x359de
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x359e0
jmp 0x35960
movq -0x20(%rbp), %rax
popq %rbp
retq
nopl (%rax,%rax)
| my_numcells_cp932:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], 0
mov rax, [rbp+var_10]
mov [rbp+var_28], rax
mov rax, [rbp+var_18]
mov [rbp+var_30], rax
mov [rbp+var_20], 0
loc_35960:
mov rax, [rbp+var_28]
cmp rax, [rbp+var_30]
jnb short loc_359E5
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 0A1h
jl short loc_359A0
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 0DFh
jg short loc_359A0
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 1
mov [rbp+var_28], rax
jmp short loc_359E0
loc_359A0:
mov rax, [rbp+var_28]
movzx eax, byte ptr [rax]
cmp eax, 7Fh
jle short loc_359C6
mov rax, [rbp+var_20]
add rax, 2
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
jmp short loc_359DE
loc_359C6:
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
mov rax, [rbp+var_28]
add rax, 1
mov [rbp+var_28], rax
loc_359DE:
jmp short $+2
loc_359E0:
jmp loc_35960
loc_359E5:
mov rax, [rbp+var_20]
pop rbp
retn
| long long my_numcells_cp932(long long a1, unsigned __int8 *a2, unsigned long long a3)
{
long long v5; // [rsp+10h] [rbp-20h]
v5 = 0LL;
while ( (unsigned long long)a2 < a3 )
{
if ( *a2 < 0xA1u || *a2 > 0xDFu )
{
if ( *a2 <= 0x7Fu )
{
++v5;
++a2;
}
else
{
v5 += 2LL;
a2 += 2;
}
}
else
{
++v5;
++a2;
}
}
return v5;
}
| my_numcells_cp932:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
MOV qword ptr [RBP + -0x20],0x0
LAB_00135960:
MOV RAX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNC 0x001359e5
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xa1
JL 0x001359a0
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xdf
JG 0x001359a0
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x1
MOV qword ptr [RBP + -0x28],RAX
JMP 0x001359e0
LAB_001359a0:
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x7f
JLE 0x001359c6
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
JMP 0x001359de
LAB_001359c6:
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x1
MOV qword ptr [RBP + -0x28],RAX
LAB_001359de:
JMP 0x001359e0
LAB_001359e0:
JMP 0x00135960
LAB_001359e5:
MOV RAX,qword ptr [RBP + -0x20]
POP RBP
RET
|
long my_numcells_cp932(int8 param_1,byte *param_2,byte *param_3)
{
byte *local_30;
long local_28;
local_28 = 0;
local_30 = param_2;
while (local_30 < param_3) {
if ((*local_30 < 0xa1) || (0xdf < *local_30)) {
if (*local_30 < 0x80) {
local_28 = local_28 + 1;
local_30 = local_30 + 1;
}
else {
local_28 = local_28 + 2;
local_30 = local_30 + 2;
}
}
else {
local_28 = local_28 + 1;
local_30 = local_30 + 1;
}
}
return local_28;
}
| |
21,426 | js_os_ttyGetWinSize | bluesky950520[P]quickjs/quickjs-libc.c | static JSValue js_os_ttyGetWinSize(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
int fd;
struct winsize ws;
JSValue obj;
if (JS_ToInt32(ctx, &fd, argv[0]))
return JS_EXCEPTION;
if (ioctl(fd, TIOCGWINSZ, &ws) == 0 &&
ws.ws_col >= 4 && ws.ws_row >= 4) {
obj = JS_NewArray(ctx);
if (JS_IsException(obj))
return obj;
JS_DefinePropertyValueUint32(ctx, obj, 0, JS_NewInt32(ctx, ws.ws_col), JS_PROP_C_W_E);
JS_DefinePropertyValueUint32(ctx, obj, 1, JS_NewInt32(ctx, ws.ws_row), JS_PROP_C_W_E);
return obj;
} else {
return JS_NULL;
}
} | O2 | c | js_os_ttyGetWinSize:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rdi, %r15
movq (%r8), %rdx
movq 0x8(%r8), %rcx
leaq 0x1c(%rsp), %rsi
callq 0x215d7
testl %eax, %eax
je 0x137e0
pushq $0x6
popq %r14
xorl %ebx, %ebx
xorl %ecx, %ecx
jmp 0x13874
movl 0x1c(%rsp), %edi
xorl %ebx, %ebx
leaq 0x14(%rsp), %rdx
movl $0x5413, %esi # imm = 0x5413
xorl %eax, %eax
callq 0xe380
pushq $0x2
popq %r14
testl %eax, %eax
jne 0x137d9
cmpw $0x4, 0x16(%rsp)
jb 0x137d9
cmpw $0x4, 0x14(%rsp)
movl $0x0, %ecx
jb 0x13874
movabsq $-0x100000000, %r12 # imm = 0xFFFFFFFF00000000
movq %r15, %rdi
callq 0x1b2bb
movq %rax, %rbx
movq %rdx, %r14
cmpl $0x6, %r14d
je 0x1386e
movzwl 0x16(%rsp), %r8d
pushq $0x7
popq %rbp
movl %ebp, (%rsp)
movq %r15, %rdi
movq %rbx, %rsi
movq %r14, %rdx
xorl %ecx, %ecx
xorl %r9d, %r9d
callq 0x20972
movzwl 0x14(%rsp), %r8d
movl %ebp, (%rsp)
pushq $0x1
popq %rcx
movq %r15, %rdi
movq %rbx, %rsi
movq %r14, %rdx
xorl %r9d, %r9d
callq 0x20972
movq %rbx, %rcx
andq %r12, %rcx
movl %ebx, %eax
orq %rcx, %rax
movq %r14, %rdx
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| js_os_ttyGetWinSize:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 20h
mov r15, rdi
mov rdx, [r8]
mov rcx, [r8+8]
lea rsi, [rsp+48h+var_2C]
call JS_ToInt32
test eax, eax
jz short loc_137E0
push 6
pop r14
xor ebx, ebx
loc_137D9:
xor ecx, ecx
jmp loc_13874
loc_137E0:
mov edi, [rsp+48h+var_2C]
xor ebx, ebx
lea rdx, [rsp+48h+var_34]
mov esi, 5413h
xor eax, eax
call _ioctl
push 2
pop r14
test eax, eax
jnz short loc_137D9
cmp [rsp+48h+var_32], 4
jb short loc_137D9
cmp [rsp+48h+var_34], 4
mov ecx, 0
jb short loc_13874
mov r12, 0FFFFFFFF00000000h
mov rdi, r15
call JS_NewArray
mov rbx, rax
mov r14, rdx
cmp r14d, 6
jz short loc_1386E
movzx r8d, [rsp+48h+var_32]
push 7
pop rbp
mov [rsp+48h+var_48], ebp
mov rdi, r15
mov rsi, rbx
mov rdx, r14
xor ecx, ecx
xor r9d, r9d
call JS_DefinePropertyValueUint32
movzx r8d, [rsp+48h+var_34]
mov [rsp+48h+var_48], ebp
push 1
pop rcx
mov rdi, r15
mov rsi, rbx
mov rdx, r14
xor r9d, r9d
call JS_DefinePropertyValueUint32
loc_1386E:
mov rcx, rbx
and rcx, r12
loc_13874:
mov eax, ebx
or rax, rcx
mov rdx, r14
add rsp, 20h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| unsigned long long js_os_ttyGetWinSize(long long a1, long long a2, long long a3, long long a4, _QWORD *a5)
{
long long v5; // rbx
unsigned long long v6; // rcx
long long v7; // rax
int v8; // edx
int v9; // r14d
unsigned __int16 v11; // [rsp+14h] [rbp-34h] BYREF
unsigned __int16 v12; // [rsp+16h] [rbp-32h]
_DWORD v13[11]; // [rsp+1Ch] [rbp-2Ch] BYREF
if ( (unsigned int)JS_ToInt32(a1, v13, *a5, a5[1]) )
{
LODWORD(v5) = 0;
LABEL_3:
v6 = 0LL;
return v6 | (unsigned int)v5;
}
LODWORD(v5) = 0;
if ( (unsigned int)ioctl(v13[0], 21523LL, &v11) || v12 < 4u )
goto LABEL_3;
v6 = 0LL;
if ( v11 >= 4u )
{
v7 = JS_NewArray(a1);
v5 = v7;
v9 = v8;
if ( v8 != 6 )
{
JS_DefinePropertyValueUint32(a1, v7, v8, 0, v12, 0, 7);
JS_DefinePropertyValueUint32(a1, v5, v9, 1, v11, 0, 7);
}
v6 = v5 & 0xFFFFFFFF00000000LL;
}
return v6 | (unsigned int)v5;
}
| js_os_ttyGetWinSize:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x20
MOV R15,RDI
MOV RDX,qword ptr [R8]
MOV RCX,qword ptr [R8 + 0x8]
LEA RSI,[RSP + 0x1c]
CALL 0x001215d7
TEST EAX,EAX
JZ 0x001137e0
PUSH 0x6
POP R14
XOR EBX,EBX
LAB_001137d9:
XOR ECX,ECX
JMP 0x00113874
LAB_001137e0:
MOV EDI,dword ptr [RSP + 0x1c]
XOR EBX,EBX
LEA RDX,[RSP + 0x14]
MOV ESI,0x5413
XOR EAX,EAX
CALL 0x0010e380
PUSH 0x2
POP R14
TEST EAX,EAX
JNZ 0x001137d9
CMP word ptr [RSP + 0x16],0x4
JC 0x001137d9
CMP word ptr [RSP + 0x14],0x4
MOV ECX,0x0
JC 0x00113874
MOV R12,-0x100000000
MOV RDI,R15
CALL 0x0011b2bb
MOV RBX,RAX
MOV R14,RDX
CMP R14D,0x6
JZ 0x0011386e
MOVZX R8D,word ptr [RSP + 0x16]
PUSH 0x7
POP RBP
MOV dword ptr [RSP],EBP
MOV RDI,R15
MOV RSI,RBX
MOV RDX,R14
XOR ECX,ECX
XOR R9D,R9D
CALL 0x00120972
MOVZX R8D,word ptr [RSP + 0x14]
MOV dword ptr [RSP],EBP
PUSH 0x1
POP RCX
MOV RDI,R15
MOV RSI,RBX
MOV RDX,R14
XOR R9D,R9D
CALL 0x00120972
LAB_0011386e:
MOV RCX,RBX
AND RCX,R12
LAB_00113874:
MOV EAX,EBX
OR RAX,RCX
MOV RDX,R14
ADD RSP,0x20
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
int1 [16] js_os_ttyGetWinSize(int8 param_1)
{
int iVar1;
ulong uVar2;
int8 *in_R8;
int1 auVar3 [16];
int1 auVar4 [16];
ulong uStackY_50;
ushort local_34;
ushort local_32;
int local_2c;
iVar1 = JS_ToInt32(param_1,&local_2c,*in_R8,in_R8[1]);
if (iVar1 == 0) {
iVar1 = ioctl(local_2c,0x5413,&local_34);
uStackY_50 = 2;
auVar3 = ZEXT816(2) << 0x40;
if ((iVar1 == 0) && (uStackY_50 = 2, 3 < local_32)) {
uVar2 = 0;
if (3 < local_34) {
auVar3 = JS_NewArray(param_1);
uVar2 = auVar3._0_8_;
if (auVar3._8_4_ != 6) {
JS_DefinePropertyValueUint32(param_1,uVar2,auVar3._8_8_,0,local_32,0,7);
JS_DefinePropertyValueUint32(param_1,uVar2,auVar3._8_8_,1,local_34,0,7);
}
uVar2 = uVar2 & 0xffffffff00000000;
}
goto LAB_00113874;
}
}
else {
uStackY_50 = 6;
}
auVar3._8_8_ = 0;
auVar3._0_8_ = uStackY_50;
auVar3 = auVar3 << 0x40;
uVar2 = 0;
LAB_00113874:
auVar4._0_8_ = auVar3._0_8_ & 0xffffffff | uVar2;
auVar4._8_8_ = auVar3._8_8_;
return auVar4;
}
| |
21,427 | llama_kv_cache_seq_cp(llama_kv_cache&, int, int, int, int) | monkey531[P]llama/src/llama-kv-cache.cpp | void llama_kv_cache_seq_cp(
struct llama_kv_cache & cache,
llama_seq_id seq_id_src,
llama_seq_id seq_id_dst,
llama_pos p0,
llama_pos p1) {
if (p0 < 0) p0 = 0;
if (p1 < 0) p1 = std::numeric_limits<llama_pos>::max();
if (cache.recurrent) {
if ((uint32_t) seq_id_dst < cache.size && (uint32_t) seq_id_src < cache.size) {
llama_kv_cell & tail_src = cache.cells[seq_id_src];
llama_kv_cell & tail_dst = cache.cells[seq_id_dst];
if (tail_dst.tail >= 0) {
// clear destination seq_id if it wasn't empty
llama_kv_cell & cell_dst = cache.cells[tail_dst.tail];
cell_dst.seq_id.erase(seq_id_dst);
tail_dst.tail = -1;
if (cell_dst.seq_id.empty()) {
cell_dst.pos = -1;
cell_dst.delta = -1;
cell_dst.src = -1;
cache.used -= 1;
}
}
if (tail_src.tail >= 0) {
llama_kv_cell & cell_src = cache.cells[tail_src.tail];
cell_src.seq_id.insert(seq_id_dst);
tail_dst.tail = tail_src.tail;
}
}
return;
}
// otherwise, this is the KV cache of a Transformer-like model
cache.head = 0;
for (uint32_t i = 0; i < cache.size; ++i) {
if (cache.cells[i].has_seq_id(seq_id_src) && cache.cells[i].pos >= p0 && cache.cells[i].pos < p1) {
cache.cells[i].seq_id.insert(seq_id_dst);
}
}
} | O1 | cpp | llama_kv_cache_seq_cp(llama_kv_cache&, int, int, int, int):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
movl %edx, 0x4(%rsp)
xorl %r15d, %r15d
testl %ecx, %ecx
cmovgl %ecx, %r15d
movl $0x7fffffff, %r12d # imm = 0x7FFFFFFF
cmpl %r12d, %r8d
cmovbl %r8d, %r12d
cmpb $0x1, 0x2(%rdi)
jne 0xadbc1
movl 0xc(%rbx), %eax
cmpl %edx, %eax
setbe %cl
cmpl %ebp, %eax
setbe %al
orb %cl, %al
jne 0xadc4d
movslq %ebp, %r12
movq 0x20(%rbx), %r13
movslq %edx, %rax
shlq $0x6, %rax
leaq (%rax,%r13), %r15
addq $0xc, %r15
movslq (%r15), %rbp
testq %rbp, %rbp
js 0xadb82
shlq $0x6, %rbp
leaq 0x10(,%rbp), %r14
addq %r13, %r14
leaq 0x4(%rsp), %rsi
movq %r14, %rdi
callq 0x669d0
movq %r14, %rdi
movq %rax, %rsi
callq 0x68270
cmpq $0x0, 0x28(%r14)
movl $0xffffffff, (%r15) # imm = 0xFFFFFFFF
jne 0xadb82
addq %r13, %rbp
movq $-0x1, (%rbp)
movl $0xffffffff, 0x8(%rbp) # imm = 0xFFFFFFFF
decl 0x10(%rbx)
shlq $0x6, %r12
movslq 0xc(%r13,%r12), %rax
testq %rax, %rax
js 0xadc4d
leaq (%r12,%r13), %r14
addq $0xc, %r14
movq 0x20(%rbx), %rcx
shlq $0x6, %rax
leaq (%rcx,%rax), %rdi
addq $0x10, %rdi
leaq 0x4(%rsp), %rsi
callq 0x693f0
movl (%r14), %eax
movl %eax, (%r15)
jmp 0xadc4d
movl $0x0, 0x8(%rbx)
cmpl $0x0, 0xc(%rbx)
je 0xadc4d
xorl %r13d, %r13d
leaq 0x4(%rsp), %r14
movq 0x20(%rbx), %rdi
movq %r13, %rax
shlq $0x6, %rax
leaq (%rdi,%rax), %rcx
addq $0x18, %rcx
movq 0x8(%rcx), %rsi
movq %rcx, %rdx
testq %rsi, %rsi
je 0xadc10
movq %rcx, %rdx
xorl %r8d, %r8d
cmpl %ebp, 0x20(%rsi)
setl %r8b
cmovgeq %rsi, %rdx
movq 0x10(%rsi,%r8,8), %rsi
testq %rsi, %rsi
jne 0xadbf8
movq %rcx, %rsi
cmpq %rcx, %rdx
je 0xadc22
cmpl %ebp, 0x20(%rdx)
cmovgq %rcx, %rdx
movq %rdx, %rsi
cmpq %rcx, %rsi
je 0xadc42
addq %rax, %rdi
movl (%rdi), %eax
cmpl %r15d, %eax
jl 0xadc42
cmpl %r12d, %eax
jge 0xadc42
addq $0x10, %rdi
movq %r14, %rsi
callq 0x693f0
incq %r13
movl 0xc(%rbx), %eax
cmpq %rax, %r13
jb 0xadbd6
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| _Z21llama_kv_cache_seq_cpR14llama_kv_cacheiiii:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov ebp, esi
mov rbx, rdi
mov [rsp+38h+var_34], edx
xor r15d, r15d
test ecx, ecx
cmovg r15d, ecx
mov r12d, 7FFFFFFFh
cmp r8d, r12d
cmovb r12d, r8d
cmp byte ptr [rdi+2], 1
jnz loc_ADBC1
mov eax, [rbx+0Ch]
cmp eax, edx
setbe cl
cmp eax, ebp
setbe al
or al, cl
jnz loc_ADC4D
movsxd r12, ebp
mov r13, [rbx+20h]
movsxd rax, edx
shl rax, 6
lea r15, [rax+r13]
add r15, 0Ch
movsxd rbp, dword ptr [r15]
test rbp, rbp
js short loc_ADB82
shl rbp, 6
lea r14, ds:10h[rbp]
add r14, r13
lea rsi, [rsp+38h+var_34]
mov rdi, r14
call __ZNSt8_Rb_treeIiiSt9_IdentityIiESt4lessIiESaIiEE11equal_rangeERKi; std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::equal_range(int const&)
mov rdi, r14
mov rsi, rax
call __ZNSt8_Rb_treeIiiSt9_IdentityIiESt4lessIiESaIiEE12_M_erase_auxESt23_Rb_tree_const_iteratorIiES7_; std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::_M_erase_aux(std::_Rb_tree_const_iterator<int>,std::_Rb_tree_const_iterator<int>)
cmp qword ptr [r14+28h], 0
mov dword ptr [r15], 0FFFFFFFFh
jnz short loc_ADB82
add rbp, r13
mov qword ptr [rbp+0], 0FFFFFFFFFFFFFFFFh
mov dword ptr [rbp+8], 0FFFFFFFFh
dec dword ptr [rbx+10h]
loc_ADB82:
shl r12, 6
movsxd rax, dword ptr [r13+r12+0Ch]
test rax, rax
js loc_ADC4D
lea r14, [r12+r13]
add r14, 0Ch
mov rcx, [rbx+20h]
shl rax, 6
lea rdi, [rcx+rax]
add rdi, 10h
lea rsi, [rsp+38h+var_34]
call __ZNSt8_Rb_treeIiiSt9_IdentityIiESt4lessIiESaIiEE16_M_insert_uniqueIRKiEESt4pairISt17_Rb_tree_iteratorIiEbEOT_; std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::_M_insert_unique<int const&>(int const&)
mov eax, [r14]
mov [r15], eax
jmp loc_ADC4D
loc_ADBC1:
mov dword ptr [rbx+8], 0
cmp dword ptr [rbx+0Ch], 0
jz short loc_ADC4D
xor r13d, r13d
lea r14, [rsp+38h+var_34]
loc_ADBD6:
mov rdi, [rbx+20h]
mov rax, r13
shl rax, 6
lea rcx, [rdi+rax]
add rcx, 18h
mov rsi, [rcx+8]
mov rdx, rcx
test rsi, rsi
jz short loc_ADC10
mov rdx, rcx
loc_ADBF8:
xor r8d, r8d
cmp [rsi+20h], ebp
setl r8b
cmovge rdx, rsi
mov rsi, [rsi+r8*8+10h]
test rsi, rsi
jnz short loc_ADBF8
loc_ADC10:
mov rsi, rcx
cmp rdx, rcx
jz short loc_ADC22
cmp [rdx+20h], ebp
cmovg rdx, rcx
mov rsi, rdx
loc_ADC22:
cmp rsi, rcx
jz short loc_ADC42
add rdi, rax
mov eax, [rdi]
cmp eax, r15d
jl short loc_ADC42
cmp eax, r12d
jge short loc_ADC42
add rdi, 10h
mov rsi, r14
call __ZNSt8_Rb_treeIiiSt9_IdentityIiESt4lessIiESaIiEE16_M_insert_uniqueIRKiEESt4pairISt17_Rb_tree_iteratorIiEbEOT_; std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::_M_insert_unique<int const&>(int const&)
loc_ADC42:
inc r13
mov eax, [rbx+0Ch]
cmp r13, rax
jb short loc_ADBD6
loc_ADC4D:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long llama_kv_cache_seq_cp(long long a1, signed int a2, unsigned int a3, int a4, unsigned int a5)
{
long long result; // rax
int v8; // r15d
int v9; // r12d
long long v10; // r13
int *v11; // r15
long long v12; // rbp
long long v13; // rbp
long long v14; // rax
bool v15; // zf
long long v16; // rbp
long long v17; // r12
unsigned long long v18; // r13
long long v19; // rdi
long long v20; // rcx
long long v21; // rsi
long long v22; // rdx
long long v23; // rsi
int *v24; // rdi
_DWORD v25[13]; // [rsp+0h] [rbp-34h] BYREF
v25[0] = a3;
v8 = 0;
if ( a4 > 0 )
v8 = a4;
v9 = 0x7FFFFFFF;
if ( a5 < 0x7FFFFFFF )
v9 = a5;
if ( *(_BYTE *)(a1 + 2) == 1 )
{
result = *(unsigned int *)(a1 + 12);
LOBYTE(result) = (unsigned int)result <= a3 || (unsigned int)result <= a2;
if ( !(_BYTE)result )
{
v10 = *(_QWORD *)(a1 + 32);
v11 = (int *)(((long long)(int)a3 << 6) + v10 + 12);
v12 = *v11;
if ( v12 >= 0 )
{
v13 = v12 << 6;
v14 = std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::equal_range(
v10 + v13 + 16,
v25);
std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::_M_erase_aux(v10 + v13 + 16, v14);
v15 = *(_QWORD *)(v10 + v13 + 16 + 40) == 0LL;
*v11 = -1;
if ( v15 )
{
v16 = v10 + v13;
*(_QWORD *)v16 = -1LL;
*(_DWORD *)(v16 + 8) = -1;
--*(_DWORD *)(a1 + 16);
}
}
v17 = (long long)a2 << 6;
result = *(int *)(v10 + v17 + 12);
if ( result >= 0 )
{
std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::_M_insert_unique<int const&>(
*(_QWORD *)(a1 + 32) + (result << 6) + 16,
v25);
result = *(unsigned int *)(v17 + v10 + 12);
*v11 = result;
}
}
}
else
{
*(_DWORD *)(a1 + 8) = 0;
if ( *(_DWORD *)(a1 + 12) )
{
v18 = 0LL;
do
{
v19 = *(_QWORD *)(a1 + 32);
v20 = v19 + (v18 << 6) + 24;
v21 = *(_QWORD *)(v19 + (v18 << 6) + 32);
v22 = v20;
if ( v21 )
{
v22 = v19 + (v18 << 6) + 24;
do
{
if ( *(_DWORD *)(v21 + 32) >= a2 )
v22 = v21;
v21 = *(_QWORD *)(v21 + 8LL * (*(_DWORD *)(v21 + 32) < a2) + 16);
}
while ( v21 );
}
v23 = v19 + (v18 << 6) + 24;
if ( v22 != v20 )
{
if ( *(_DWORD *)(v22 + 32) > a2 )
v22 = v19 + (v18 << 6) + 24;
v23 = v22;
}
if ( v23 != v20 )
{
v24 = (int *)((v18 << 6) + v19);
if ( *v24 >= v8 && *v24 < v9 )
std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::_M_insert_unique<int const&>(
v24 + 4,
v25);
}
++v18;
result = *(unsigned int *)(a1 + 12);
}
while ( v18 < result );
}
}
return result;
}
| llama_kv_cache_seq_cp:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV EBP,ESI
MOV RBX,RDI
MOV dword ptr [RSP + 0x4],EDX
XOR R15D,R15D
TEST ECX,ECX
CMOVG R15D,ECX
MOV R12D,0x7fffffff
CMP R8D,R12D
CMOVC R12D,R8D
CMP byte ptr [RDI + 0x2],0x1
JNZ 0x001adbc1
MOV EAX,dword ptr [RBX + 0xc]
CMP EAX,EDX
SETBE CL
CMP EAX,EBP
SETBE AL
OR AL,CL
JNZ 0x001adc4d
MOVSXD R12,EBP
MOV R13,qword ptr [RBX + 0x20]
MOVSXD RAX,EDX
SHL RAX,0x6
LEA R15,[RAX + R13*0x1]
ADD R15,0xc
MOVSXD RBP,dword ptr [R15]
TEST RBP,RBP
JS 0x001adb82
SHL RBP,0x6
LEA R14,[0x10 + RBP*0x1]
ADD R14,R13
LEA RSI,[RSP + 0x4]
MOV RDI,R14
CALL 0x001669d0
MOV RDI,R14
MOV RSI,RAX
CALL 0x00168270
CMP qword ptr [R14 + 0x28],0x0
MOV dword ptr [R15],0xffffffff
JNZ 0x001adb82
ADD RBP,R13
MOV qword ptr [RBP],-0x1
MOV dword ptr [RBP + 0x8],0xffffffff
DEC dword ptr [RBX + 0x10]
LAB_001adb82:
SHL R12,0x6
MOVSXD RAX,dword ptr [R13 + R12*0x1 + 0xc]
TEST RAX,RAX
JS 0x001adc4d
LEA R14,[R12 + R13*0x1]
ADD R14,0xc
MOV RCX,qword ptr [RBX + 0x20]
SHL RAX,0x6
LEA RDI,[RCX + RAX*0x1]
ADD RDI,0x10
LEA RSI,[RSP + 0x4]
CALL 0x001693f0
MOV EAX,dword ptr [R14]
MOV dword ptr [R15],EAX
JMP 0x001adc4d
LAB_001adbc1:
MOV dword ptr [RBX + 0x8],0x0
CMP dword ptr [RBX + 0xc],0x0
JZ 0x001adc4d
XOR R13D,R13D
LEA R14,[RSP + 0x4]
LAB_001adbd6:
MOV RDI,qword ptr [RBX + 0x20]
MOV RAX,R13
SHL RAX,0x6
LEA RCX,[RDI + RAX*0x1]
ADD RCX,0x18
MOV RSI,qword ptr [RCX + 0x8]
MOV RDX,RCX
TEST RSI,RSI
JZ 0x001adc10
MOV RDX,RCX
LAB_001adbf8:
XOR R8D,R8D
CMP dword ptr [RSI + 0x20],EBP
SETL R8B
CMOVGE RDX,RSI
MOV RSI,qword ptr [RSI + R8*0x8 + 0x10]
TEST RSI,RSI
JNZ 0x001adbf8
LAB_001adc10:
MOV RSI,RCX
CMP RDX,RCX
JZ 0x001adc22
CMP dword ptr [RDX + 0x20],EBP
CMOVG RDX,RCX
MOV RSI,RDX
LAB_001adc22:
CMP RSI,RCX
JZ 0x001adc42
ADD RDI,RAX
MOV EAX,dword ptr [RDI]
CMP EAX,R15D
JL 0x001adc42
CMP EAX,R12D
JGE 0x001adc42
ADD RDI,0x10
MOV RSI,R14
CALL 0x001693f0
LAB_001adc42:
INC R13
MOV EAX,dword ptr [RBX + 0xc]
CMP R13,RAX
JC 0x001adbd6
LAB_001adc4d:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* llama_kv_cache_seq_cp(llama_kv_cache&, int, int, int, int) */
void llama_kv_cache_seq_cp(llama_kv_cache *param_1,int param_2,int param_3,int param_4,int param_5)
{
int iVar1;
int8 uVar2;
long lVar3;
long lVar4;
int8 *puVar5;
long lVar6;
int iVar7;
ulong uVar8;
_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>> *this;
int iVar9;
int *piVar10;
int local_34;
iVar9 = 0;
if (0 < param_4) {
iVar9 = param_4;
}
iVar7 = 0x7fffffff;
if ((uint)param_5 < 0x7fffffff) {
iVar7 = param_5;
}
if (param_1[2] == (llama_kv_cache)0x1) {
if ((uint)param_2 < *(uint *)(param_1 + 0xc) && (uint)param_3 < *(uint *)(param_1 + 0xc)) {
lVar6 = *(long *)(param_1 + 0x20);
piVar10 = (int *)((long)param_3 * 0x40 + lVar6 + 0xc);
if (-1 < (long)*piVar10) {
lVar4 = (long)*piVar10 * 0x40;
this = (_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>> *)
(lVar4 + 0x10 + lVar6);
uVar2 = std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::
equal_range(this,&local_34);
std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::_M_erase_aux
(this,uVar2);
lVar3 = *(long *)(this + 0x28);
*piVar10 = -1;
if (lVar3 == 0) {
puVar5 = (int8 *)(lVar4 + lVar6);
*puVar5 = 0xffffffffffffffff;
*(int4 *)(puVar5 + 1) = 0xffffffff;
*(int *)(param_1 + 0x10) = *(int *)(param_1 + 0x10) + -1;
}
}
lVar3 = (long)*(int *)(lVar6 + 0xc + (long)param_2 * 0x40);
if (-1 < lVar3) {
std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::
_M_insert_unique<int_const&>
((_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>> *)
(*(long *)(param_1 + 0x20) + lVar3 * 0x40 + 0x10),&local_34);
*piVar10 = *(int *)((long)param_2 * 0x40 + lVar6 + 0xc);
}
}
}
else {
*(int4 *)(param_1 + 8) = 0;
if (*(int *)(param_1 + 0xc) != 0) {
uVar8 = 0;
do {
lVar6 = *(long *)(param_1 + 0x20) + uVar8 * 0x40;
lVar4 = lVar6 + 0x18;
lVar3 = lVar4;
for (lVar6 = *(long *)(lVar6 + 0x20); lVar6 != 0;
lVar6 = *(long *)(lVar6 + 0x10 + (ulong)(*(int *)(lVar6 + 0x20) < param_2) * 8)) {
if (param_2 <= *(int *)(lVar6 + 0x20)) {
lVar3 = lVar6;
}
}
lVar6 = lVar4;
if ((lVar3 != lVar4) && (lVar6 = lVar3, param_2 < *(int *)(lVar3 + 0x20))) {
lVar6 = lVar4;
}
if (lVar6 != lVar4) {
piVar10 = (int *)(*(long *)(param_1 + 0x20) + uVar8 * 0x40);
iVar1 = *piVar10;
if ((iVar9 <= iVar1) && (iVar1 < iVar7)) {
std::_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>>::
_M_insert_unique<int_const&>
((_Rb_tree<int,int,std::_Identity<int>,std::less<int>,std::allocator<int>> *)
(piVar10 + 4),&local_34);
}
}
uVar8 = uVar8 + 1;
} while (uVar8 < *(uint *)(param_1 + 0xc));
}
}
return;
}
| |
21,428 | void ggml_quantize_mat_t<8l, (ggml_type)8>(float const*, void*, long, long) | ngxson[P]ggml-easy/ggml/src/ggml-cpu/ggml-cpu-aarch64.cpp | void ggml_quantize_mat_t<8, GGML_TYPE_Q8_0>(const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t nrow, int64_t n_per_row) {
assert(nrow == 4);
UNUSED(nrow);
ggml_quantize_mat_q8_0_4x8(x, vy, n_per_row);
} | O2 | cpp | void ggml_quantize_mat_t<8l, (ggml_type)8>(float const*, void*, long, long):
pushq %rbp
movq %rsp, %rbp
andq $-0x20, %rsp
subq $0x2a0, %rsp # imm = 0x2A0
pushq $0x20
popq %r8
movq %rcx, %rax
cqto
idivq %r8
movl %eax, %edx
sarl $0x1f, %edx
andnl %eax, %edx, %eax
addq $0x60, %rdi
shlq $0x2, %rcx
xorl %edx, %edx
vmovaps 0x32e92(%rip), %ymm0 # 0x44d40
pushq $-0x80
popq %r8
vbroadcastss 0x32e51(%rip), %ymm1 # 0x44d0c
vmovss 0x32e4d(%rip), %xmm2 # 0x44d10
vxorps %xmm3, %xmm3, %xmm3
cmpq %rax, %rdx
je 0x1204b
movq %rdi, %r9
movq %rsi, %r10
xorl %r11d, %r11d
cmpq $0x80, %r11
je 0x11fa1
vmovups -0x60(%r9), %ymm4
vmovups -0x40(%r9), %ymm5
vmovups -0x20(%r9), %ymm6
vmovups (%r9), %ymm7
vandps %ymm1, %ymm4, %ymm8
vandps %ymm1, %ymm5, %ymm9
vmaxps %ymm9, %ymm8, %ymm8
vandps %ymm1, %ymm6, %ymm9
vmaxps %ymm9, %ymm8, %ymm8
vandps %ymm1, %ymm7, %ymm9
vmaxps %ymm9, %ymm8, %ymm8
vextractf128 $0x1, %ymm8, %xmm9
vmaxps %xmm8, %xmm9, %xmm8
vshufpd $0x3, %xmm8, %xmm8, %xmm9 # xmm9 = xmm8[1,1]
vmaxps %xmm9, %xmm8, %xmm8
vmovshdup %xmm8, %xmm9 # xmm9 = xmm8[1,1,3,3]
vmaxss %xmm9, %xmm8, %xmm8
vdivss %xmm2, %xmm8, %xmm9
vdivss %xmm8, %xmm2, %xmm10
vcmpneqss %xmm3, %xmm8, %k1
vcvtps2ph $0x0, %xmm9, %xmm8
vmovss %xmm10, %xmm10, %xmm9 {%k1} {z}
vpextrw $0x0, %xmm8, (%r10)
vmovaps %ymm4, 0x80(%rsp,%r11,4)
vmovaps %ymm5, 0xa0(%rsp,%r11,4)
vmovaps %ymm6, 0xc0(%rsp,%r11,4)
vmovaps %ymm7, 0xe0(%rsp,%r11,4)
vbroadcastss %xmm9, %ymm4
vmovaps %ymm4, (%rsp,%r11)
addq $0x20, %r11
addq $0x2, %r10
addq %rcx, %r9
jmp 0x11ed9
vmovaps (%rsp), %ymm4
vmovaps 0x20(%rsp), %ymm5
vmovaps 0x40(%rsp), %ymm6
vmovaps 0x60(%rsp), %ymm7
movq %r8, %r9
testq %r9, %r9
je 0x12038
vmulps 0x100(%rsp,%r9), %ymm4, %ymm8
vmulps 0x180(%rsp,%r9), %ymm5, %ymm9
vmulps 0x200(%rsp,%r9), %ymm6, %ymm10
vmulps 0x280(%rsp,%r9), %ymm7, %ymm11
vroundps $0x0, %ymm8, %ymm8
vroundps $0x0, %ymm9, %ymm9
vroundps $0x0, %ymm10, %ymm10
vroundps $0x0, %ymm11, %ymm11
vcvtps2dq %ymm8, %ymm8
vcvtps2dq %ymm9, %ymm9
vpackssdw %ymm9, %ymm8, %ymm8
vcvtps2dq %ymm10, %ymm9
vcvtps2dq %ymm11, %ymm10
vpackssdw %ymm10, %ymm9, %ymm9
vpacksswb %ymm9, %ymm8, %ymm8
vpermps %ymm8, %ymm0, %ymm8
vmovups %ymm8, 0x88(%rsi,%r9)
addq $0x20, %r9
jmp 0x11fbb
incq %rdx
addq $0x88, %rsi
subq $-0x80, %rdi
jmp 0x11ec7
movq %rbp, %rsp
popq %rbp
vzeroupper
retq
| _Z19ggml_quantize_mat_tILl8EL9ggml_type8EEvPKfPvll:
push rbp
mov rbp, rsp
and rsp, 0FFFFFFFFFFFFFFE0h
sub rsp, 2A0h
push 20h ; ' '
pop r8
mov rax, rcx
cqo
idiv r8
mov edx, eax
sar edx, 1Fh
andn eax, edx, eax
add rdi, 60h ; '`'
shl rcx, 2
xor edx, edx
vmovaps ymm0, cs:ymmword_44D40
push 0FFFFFFFFFFFFFF80h
pop r8
vbroadcastss ymm1, cs:dword_44D0C
vmovss xmm2, cs:dword_44D10
vxorps xmm3, xmm3, xmm3
loc_11EC7:
cmp rdx, rax
jz loc_1204B
mov r9, rdi
mov r10, rsi
xor r11d, r11d
loc_11ED9:
cmp r11, 80h
jz loc_11FA1
vmovups ymm4, ymmword ptr [r9-60h]
vmovups ymm5, ymmword ptr [r9-40h]
vmovups ymm6, ymmword ptr [r9-20h]
vmovups ymm7, ymmword ptr [r9]
vandps ymm8, ymm4, ymm1
vandps ymm9, ymm5, ymm1
vmaxps ymm8, ymm8, ymm9
vandps ymm9, ymm6, ymm1
vmaxps ymm8, ymm8, ymm9
vandps ymm9, ymm7, ymm1
vmaxps ymm8, ymm8, ymm9
vextractf128 xmm9, ymm8, 1
vmaxps xmm8, xmm9, xmm8
vshufpd xmm9, xmm8, xmm8, 3
vmaxps xmm8, xmm8, xmm9
vmovshdup xmm9, xmm8
vmaxss xmm8, xmm8, xmm9
vdivss xmm9, xmm8, xmm2
vdivss xmm10, xmm2, xmm8
vcmpneqss k1, xmm8, xmm3
vcvtps2ph xmm8, xmm9, 0
vmovss xmm9{k1}{z}, xmm10, xmm10
vpextrw word ptr [r10], xmm8, 0
vmovaps [rsp+r11*4+2A0h+var_220], ymm4
vmovaps [rsp+r11*4+2A0h+var_200], ymm5
vmovaps [rsp+r11*4+2A0h+var_1E0], ymm6
vmovaps [rsp+r11*4+2A0h+var_1C0], ymm7
vbroadcastss ymm4, xmm9
vmovaps [rsp+r11+2A0h+var_2A0], ymm4
add r11, 20h ; ' '
add r10, 2
add r9, rcx
jmp loc_11ED9
loc_11FA1:
vmovaps ymm4, [rsp+2A0h+var_2A0]
vmovaps ymm5, [rsp+2A0h+var_280]
vmovaps ymm6, [rsp+2A0h+var_260]
vmovaps ymm7, [rsp+2A0h+var_240]
mov r9, r8
loc_11FBB:
test r9, r9
jz short loc_12038
vmulps ymm8, ymm4, [rsp+r9+2A0h+var_1A0]
vmulps ymm9, ymm5, [rsp+r9+2A0h+var_120]
vmulps ymm10, ymm6, [rsp+r9+2A0h+var_A0]
vmulps ymm11, ymm7, [rsp+r9+2A0h+var_20]
vroundps ymm8, ymm8, 0
vroundps ymm9, ymm9, 0
vroundps ymm10, ymm10, 0
vroundps ymm11, ymm11, 0
vcvtps2dq ymm8, ymm8
vcvtps2dq ymm9, ymm9
vpackssdw ymm8, ymm8, ymm9
vcvtps2dq ymm9, ymm10
vcvtps2dq ymm10, ymm11
vpackssdw ymm9, ymm9, ymm10
vpacksswb ymm8, ymm8, ymm9
vpermps ymm8, ymm0, ymm8
vmovups ymmword ptr [rsi+r9+88h], ymm8
add r9, 20h ; ' '
jmp short loc_11FBB
loc_12038:
inc rdx
add rsi, 88h
sub rdi, 0FFFFFFFFFFFFFF80h
jmp loc_11EC7
loc_1204B:
mov rsp, rbp
pop rbp
vzeroupper
retn
| long long ggml_quantize_mat_t<8l,(ggml_type)8>(
long long a1,
long long _RSI,
double a3,
double a4,
double a5,
__m128 _XMM3,
long long a7,
long long a8)
{
long long result; // rax
long long v9; // rdi
long long v10; // rcx
long long v11; // rdx
result = (unsigned int)(a8 / 32) & ~((int)(a8 / 32) >> 31);
v9 = a1 + 96;
v10 = 4 * a8;
v11 = 0LL;
__asm
{
vmovaps ymm0, cs:ymmword_44D40
vbroadcastss ymm1, cs:dword_44D0C
vmovss xmm2, cs:dword_44D10
vxorps xmm3, xmm3, xmm3
}
while ( v11 != result )
{
_R9 = v9;
_R10 = _RSI;
for ( _R11 = 0LL; _R11 != 128; _R11 += 32LL )
{
__asm
{
vmovups ymm4, ymmword ptr [r9-60h]
vmovups ymm5, ymmword ptr [r9-40h]
vmovups ymm6, ymmword ptr [r9-20h]
vmovups ymm7, ymmword ptr [r9]
vandps ymm8, ymm4, ymm1
vandps ymm9, ymm5, ymm1
vmaxps ymm8, ymm8, ymm9
vandps ymm9, ymm6, ymm1
vmaxps ymm8, ymm8, ymm9
vandps ymm9, ymm7, ymm1
vmaxps ymm8, ymm8, ymm9
vextractf128 xmm9, ymm8, 1
vmaxps xmm8, xmm9, xmm8
vshufpd xmm9, xmm8, xmm8, 3
vmaxps xmm8, xmm8, xmm9
vmovshdup xmm9, xmm8
vmaxss xmm8, xmm8, xmm9
vdivss xmm9, xmm8, xmm2
vdivss xmm10, xmm2, xmm8
vcmpneqss k1, xmm8, xmm3
vcvtps2ph xmm8, xmm9, 0
vmovss xmm9{k1}{z}, xmm10, xmm10
vpextrw word ptr [r10], xmm8, 0
vmovaps [rsp+r11*4+2A0h+var_220], ymm4
vmovaps [rsp+r11*4+2A0h+var_200], ymm5
vmovaps [rsp+r11*4+2A0h+var_1E0], ymm6
vmovaps [rsp+r11*4+2A0h+var_1C0], ymm7
vbroadcastss ymm4, xmm9
vmovaps [rsp+r11+2A0h+var_2A0], ymm4
}
_R10 += 2LL;
_R9 += v10;
}
__asm
{
vmovaps ymm4, [rsp+2A0h+var_2A0]
vmovaps ymm5, [rsp+2A0h+var_280]
vmovaps ymm6, [rsp+2A0h+var_260]
vmovaps ymm7, [rsp+2A0h+var_240]
}
for ( _R9 = -128LL; _R9; _R9 += 32LL )
{
__asm
{
vmulps ymm8, ymm4, [rsp+r9+2A0h+var_1A0]
vmulps ymm9, ymm5, [rsp+r9+2A0h+var_120]
vmulps ymm10, ymm6, [rsp+r9+2A0h+var_A0]
vmulps ymm11, ymm7, [rsp+r9+2A0h+var_20]
vroundps ymm8, ymm8, 0
vroundps ymm9, ymm9, 0
vroundps ymm10, ymm10, 0
vroundps ymm11, ymm11, 0
vcvtps2dq ymm8, ymm8
vcvtps2dq ymm9, ymm9
vpackssdw ymm8, ymm8, ymm9
vcvtps2dq ymm9, ymm10
vcvtps2dq ymm10, ymm11
vpackssdw ymm9, ymm9, ymm10
vpacksswb ymm8, ymm8, ymm9
vpermps ymm8, ymm0, ymm8
vmovups ymmword ptr [rsi+r9+88h], ymm8
}
}
++v11;
_RSI += 136LL;
v9 += 128LL;
}
__asm { vzeroupper }
return result;
}
| ggml_quantize_mat_t<8l,(ggml_type)8>:
PUSH RBP
MOV RBP,RSP
AND RSP,-0x20
SUB RSP,0x2a0
PUSH 0x20
POP R8
MOV RAX,RCX
CQO
IDIV R8
MOV EDX,EAX
SAR EDX,0x1f
ANDN EAX,EDX,EAX
ADD RDI,0x60
SHL RCX,0x2
XOR EDX,EDX
VMOVAPS YMM0,ymmword ptr [0x00144d40]
PUSH -0x80
POP R8
VBROADCASTSS YMM1,dword ptr [0x00144d0c]
VMOVSS XMM2,dword ptr [0x00144d10]
VXORPS XMM3,XMM3,XMM3
LAB_00111ec7:
CMP RDX,RAX
JZ 0x0011204b
MOV R9,RDI
MOV R10,RSI
XOR R11D,R11D
LAB_00111ed9:
CMP R11,0x80
JZ 0x00111fa1
VMOVUPS YMM4,ymmword ptr [R9 + -0x60]
VMOVUPS YMM5,ymmword ptr [R9 + -0x40]
VMOVUPS YMM6,ymmword ptr [R9 + -0x20]
VMOVUPS YMM7,ymmword ptr [R9]
VANDPS YMM8,YMM4,YMM1
VANDPS YMM9,YMM5,YMM1
VMAXPS YMM8,YMM8,YMM9
VANDPS YMM9,YMM6,YMM1
VMAXPS YMM8,YMM8,YMM9
VANDPS YMM9,YMM7,YMM1
VMAXPS YMM8,YMM8,YMM9
VEXTRACTF128 XMM9,YMM8,0x1
VMAXPS XMM8,XMM9,XMM8
VSHUFPD XMM9,XMM8,XMM8,0x3
VMAXPS XMM8,XMM8,XMM9
VMOVSHDUP XMM9,XMM8
VMAXSS XMM8,XMM8,XMM9
VDIVSS XMM9,XMM8,XMM2
VDIVSS XMM10,XMM2,XMM8
VCMPNEQSS K1 {K0},XMM8,XMM3
VCVTPS2PH XMM8,XMM9,0x0
VMOVSS XMM9{K1}{z},XMM10,XMM10
VPEXTRW word ptr [R10],XMM8,0x0
VMOVAPS ymmword ptr [RSP + R11*0x4 + 0x80],YMM4
VMOVAPS ymmword ptr [RSP + R11*0x4 + 0xa0],YMM5
VMOVAPS ymmword ptr [RSP + R11*0x4 + 0xc0],YMM6
VMOVAPS ymmword ptr [RSP + R11*0x4 + 0xe0],YMM7
VBROADCASTSS YMM4,XMM9
VMOVAPS ymmword ptr [RSP + R11*0x1],YMM4
ADD R11,0x20
ADD R10,0x2
ADD R9,RCX
JMP 0x00111ed9
LAB_00111fa1:
VMOVAPS YMM4,ymmword ptr [RSP]
VMOVAPS YMM5,ymmword ptr [RSP + 0x20]
VMOVAPS YMM6,ymmword ptr [RSP + 0x40]
VMOVAPS YMM7,ymmword ptr [RSP + 0x60]
MOV R9,R8
LAB_00111fbb:
TEST R9,R9
JZ 0x00112038
VMULPS YMM8,YMM4,ymmword ptr [RSP + R9*0x1 + 0x100]
VMULPS YMM9,YMM5,ymmword ptr [RSP + R9*0x1 + 0x180]
VMULPS YMM10,YMM6,ymmword ptr [RSP + R9*0x1 + 0x200]
VMULPS YMM11,YMM7,ymmword ptr [RSP + R9*0x1 + 0x280]
VROUNDPS YMM8,YMM8,0x0
VROUNDPS YMM9,YMM9,0x0
VROUNDPS YMM10,YMM10,0x0
VROUNDPS YMM11,YMM11,0x0
VCVTPS2DQ YMM8,YMM8
VCVTPS2DQ YMM9,YMM9
VPACKSSDW YMM8,YMM8,YMM9
VCVTPS2DQ YMM9,YMM10
VCVTPS2DQ YMM10,YMM11
VPACKSSDW YMM9,YMM9,YMM10
VPACKSSWB YMM8,YMM8,YMM9
VPERMPS YMM8,YMM0,YMM8
VMOVUPS ymmword ptr [RSI + R9*0x1 + 0x88],YMM8
ADD R9,0x20
JMP 0x00111fbb
LAB_00112038:
INC RDX
ADD RSI,0x88
SUB RDI,-0x80
JMP 0x00111ec7
LAB_0011204b:
MOV RSP,RBP
POP RBP
VZEROUPPER
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* void ggml_quantize_mat_t<8l, (ggml_type)8>(float const*, void*, long, long) */
void ggml_quantize_mat_t<8l,(ggml_type)8>(float *param_1,void *param_2,long param_3,long param_4)
{
int1 auVar1 [32];
int1 auVar2 [32];
int1 auVar3 [32];
int1 auVar4 [32];
int1 auVar5 [32];
int8 uVar6;
uint uVar7;
float fVar8;
int1 auVar9 [32];
uint uVar10;
ulong uVar11;
int1 (*pauVar12) [32];
int1 (*pauVar13) [32];
long lVar14;
long lVar15;
byte in_K0;
int1 auVar16 [32];
int1 auVar17 [16];
int1 in_ZMM8 [64];
int1 auVar18 [64];
int1 auVar19 [16];
int1 in_ZMM9 [64];
int1 auVar20 [64];
float fVar21;
int1 in_ZMM10 [64];
int1 auVar22 [64];
int1 in_ZMM11 [64];
int1 auVar23 [64];
float local_2c0 [7];
uint uStack_2a4;
float local_2a0;
float fStack_29c;
float fStack_298;
float fStack_294;
float fStack_290;
float fStack_28c;
float fStack_288;
float local_280;
float fStack_27c;
float fStack_278;
float fStack_274;
float fStack_270;
float fStack_26c;
float fStack_268;
float local_260;
float fStack_25c;
float fStack_258;
float fStack_254;
float fStack_250;
float fStack_24c;
float fStack_248;
float afStack_240 [8];
int1 auStack_220 [32];
int1 auStack_200 [32];
int1 auStack_1e0 [32];
float afStack_1c0 [32];
float afStack_140 [32];
float afStack_c0 [32];
float afStack_40 [14];
auVar9 = _DAT_00144d40;
fVar8 = DAT_00144d10;
uVar10 = (uint)(param_4 / 0x20);
pauVar12 = (int1 (*) [32])(param_1 + 0x18);
auVar16._4_4_ = DAT_00144d0c;
auVar16._0_4_ = DAT_00144d0c;
auVar16._8_4_ = DAT_00144d0c;
auVar16._12_4_ = DAT_00144d0c;
auVar16._16_4_ = DAT_00144d0c;
auVar16._20_4_ = DAT_00144d0c;
auVar16._24_4_ = DAT_00144d0c;
auVar16._28_4_ = DAT_00144d0c;
for (uVar11 = 0; uVar11 != (~((int)uVar10 >> 0x1f) & uVar10); uVar11 = uVar11 + 1) {
pauVar13 = pauVar12;
for (lVar15 = 0; lVar14 = -0x80, lVar15 != 0x80; lVar15 = lVar15 + 0x20) {
auVar1 = pauVar13[-2];
auVar2 = pauVar13[-1];
auVar3 = *pauVar13;
auVar4 = vandps_avx(pauVar13[-3],auVar16);
auVar5 = vandps_avx(auVar1,auVar16);
auVar5 = vmaxps_avx(auVar4,auVar5);
auVar4 = vandps_avx(auVar2,auVar16);
auVar5 = vmaxps_avx(auVar5,auVar4);
auVar4 = vandps_avx(auVar3,auVar16);
auVar4 = vmaxps_avx(auVar5,auVar4);
auVar17 = vmaxps_avx(auVar4._16_16_,auVar4._0_16_);
auVar19 = vshufpd_avx(auVar17,auVar17,3);
auVar17 = vmaxps_avx(auVar17,auVar19);
auVar19 = vmovshdup_avx(auVar17);
auVar17 = vmaxss_avx(auVar17,auVar19);
auVar19._0_4_ = auVar17._0_4_ / fVar8;
auVar19._4_12_ = auVar17._4_12_;
fVar21 = fVar8 / auVar17._0_4_;
in_ZMM10 = ZEXT464((uint)fVar21);
uVar6 = vcmpss_avx512f(auVar17,ZEXT816(0) << 0x40,4);
auVar17 = vcvtps2ph_f16c(auVar19,0);
in_ZMM8 = ZEXT1664(auVar17);
uVar7 = (uint)(in_K0 & 1 & (byte)uVar6) * (int)fVar21;
in_ZMM9 = ZEXT464(uVar7);
vpextrw_avx(auVar17,0);
*(int1 (*) [32])(afStack_240 + lVar15) = pauVar13[-3];
*(int1 (*) [32])(auStack_220 + lVar15 * 4) = auVar1;
*(int1 (*) [32])(auStack_200 + lVar15 * 4) = auVar2;
*(int1 (*) [32])(auStack_1e0 + lVar15 * 4) = auVar3;
*(uint *)((long)local_2c0 + lVar15) = uVar7;
*(uint *)((long)local_2c0 + lVar15 + 4) = uVar7;
*(uint *)((long)local_2c0 + lVar15 + 8) = uVar7;
*(uint *)((long)local_2c0 + lVar15 + 0xc) = uVar7;
*(uint *)((long)local_2c0 + lVar15 + 0x10) = uVar7;
*(uint *)((long)local_2c0 + lVar15 + 0x14) = uVar7;
*(uint *)((long)local_2c0 + lVar15 + 0x18) = uVar7;
*(uint *)((long)&uStack_2a4 + lVar15) = uVar7;
pauVar13 = (int1 (*) [32])(*pauVar13 + param_4 * 4);
}
for (; lVar14 != 0; lVar14 = lVar14 + 0x20) {
auVar18._0_4_ = local_2c0[0] * *(float *)((long)afStack_1c0 + lVar14);
auVar18._4_4_ = local_2c0[1] * *(float *)((long)afStack_1c0 + lVar14 + 4);
auVar18._8_4_ = local_2c0[2] * *(float *)((long)afStack_1c0 + lVar14 + 8);
auVar18._12_4_ = local_2c0[3] * *(float *)((long)afStack_1c0 + lVar14 + 0xc);
auVar18._16_4_ = local_2c0[4] * *(float *)((long)afStack_1c0 + lVar14 + 0x10);
auVar18._20_4_ = local_2c0[5] * *(float *)((long)afStack_1c0 + lVar14 + 0x14);
auVar18._28_36_ = in_ZMM8._28_36_;
auVar18._24_4_ = local_2c0[6] * *(float *)((long)afStack_1c0 + lVar14 + 0x18);
auVar20._0_4_ = local_2a0 * *(float *)((long)afStack_140 + lVar14);
auVar20._4_4_ = fStack_29c * *(float *)((long)afStack_140 + lVar14 + 4);
auVar20._8_4_ = fStack_298 * *(float *)((long)afStack_140 + lVar14 + 8);
auVar20._12_4_ = fStack_294 * *(float *)((long)afStack_140 + lVar14 + 0xc);
auVar20._16_4_ = fStack_290 * *(float *)((long)afStack_140 + lVar14 + 0x10);
auVar20._20_4_ = fStack_28c * *(float *)((long)afStack_140 + lVar14 + 0x14);
auVar20._28_36_ = in_ZMM9._28_36_;
auVar20._24_4_ = fStack_288 * *(float *)((long)afStack_140 + lVar14 + 0x18);
auVar22._0_4_ = local_280 * *(float *)((long)afStack_c0 + lVar14);
auVar22._4_4_ = fStack_27c * *(float *)((long)afStack_c0 + lVar14 + 4);
auVar22._8_4_ = fStack_278 * *(float *)((long)afStack_c0 + lVar14 + 8);
auVar22._12_4_ = fStack_274 * *(float *)((long)afStack_c0 + lVar14 + 0xc);
auVar22._16_4_ = fStack_270 * *(float *)((long)afStack_c0 + lVar14 + 0x10);
auVar22._20_4_ = fStack_26c * *(float *)((long)afStack_c0 + lVar14 + 0x14);
auVar22._28_36_ = in_ZMM10._28_36_;
auVar22._24_4_ = fStack_268 * *(float *)((long)afStack_c0 + lVar14 + 0x18);
auVar23._0_4_ = local_260 * *(float *)((long)afStack_40 + lVar14);
auVar23._4_4_ = fStack_25c * *(float *)((long)afStack_40 + lVar14 + 4);
auVar23._8_4_ = fStack_258 * *(float *)((long)afStack_40 + lVar14 + 8);
auVar23._12_4_ = fStack_254 * *(float *)((long)afStack_40 + lVar14 + 0xc);
auVar23._16_4_ = fStack_250 * *(float *)((long)afStack_40 + lVar14 + 0x10);
auVar23._20_4_ = fStack_24c * *(float *)((long)afStack_40 + lVar14 + 0x14);
auVar23._28_36_ = in_ZMM11._28_36_;
auVar23._24_4_ = fStack_248 * *(float *)((long)afStack_40 + lVar14 + 0x18);
auVar1 = vroundps_avx(auVar18._0_32_,0);
auVar2 = vroundps_avx(auVar20._0_32_,0);
auVar3 = vroundps_avx(auVar22._0_32_,0);
auVar4 = vroundps_avx(auVar23._0_32_,0);
in_ZMM11 = ZEXT3264(auVar4);
auVar1 = vcvtps2dq_avx(auVar1);
auVar2 = vcvtps2dq_avx(auVar2);
auVar5 = vpackssdw_avx2(auVar1,auVar2);
auVar1 = vcvtps2dq_avx(auVar3);
auVar2 = vcvtps2dq_avx(auVar4);
in_ZMM10 = ZEXT3264(auVar2);
auVar1 = vpackssdw_avx2(auVar1,auVar2);
in_ZMM9 = ZEXT3264(auVar1);
auVar1 = vpacksswb_avx2(auVar5,auVar1);
auVar1 = vpermps_avx2(auVar9,auVar1);
in_ZMM8 = ZEXT3264(auVar1);
*(int1 (*) [32])((long)param_2 + lVar14 + 0x88) = auVar1;
}
param_2 = (void *)((long)param_2 + 0x88);
pauVar12 = pauVar12 + 4;
}
return;
}
| |
21,429 | ft_parse | eloqsql/storage/myisam/ft_parser.c | int ft_parse(TREE *wtree, uchar *doc, int doclen,
struct st_mysql_ftparser *parser,
MYSQL_FTPARSER_PARAM *param, MEM_ROOT *mem_root)
{
MY_FT_PARSER_PARAM my_param;
DBUG_ENTER("ft_parse");
DBUG_ASSERT(parser);
my_param.wtree= wtree;
my_param.mem_root= mem_root;
param->mysql_parse= ft_parse_internal;
param->mysql_add_word= ft_add_word;
param->mysql_ftparam= &my_param;
param->cs= wtree->custom_arg;
param->doc= (char*) doc;
param->length= doclen;
param->mode= MYSQL_FTPARSER_SIMPLE_MODE;
DBUG_RETURN(parser->parse(param));
} | O0 | c | ft_parse:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
jmp 0xa1f21
movq -0x8(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x28(%rbp), %rax
leaq 0x74(%rip), %rcx # 0xa1fb0
movq %rcx, (%rax)
movq -0x28(%rbp), %rax
leaq 0x116(%rip), %rcx # 0xa2060
movq %rcx, 0x8(%rax)
movq -0x28(%rbp), %rax
leaq -0x40(%rbp), %rcx
movq %rcx, 0x18(%rax)
movq -0x8(%rbp), %rax
movq 0x230(%rax), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x10(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x28(%rax)
movl -0x14(%rbp), %ecx
movq -0x28(%rbp), %rax
movl %ecx, 0x30(%rax)
movq -0x28(%rbp), %rax
movl $0x0, 0x38(%rax)
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x28(%rbp), %rdi
callq *%rax
movl %eax, -0x44(%rbp)
movl -0x44(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| ft_parse:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov [rbp+var_30], r9
jmp short $+2
loc_A1F21:
mov rax, [rbp+var_8]
mov [rbp+var_40], rax
mov rax, [rbp+var_30]
mov [rbp+var_38], rax
mov rax, [rbp+var_28]
lea rcx, ft_parse_internal
mov [rax], rcx
mov rax, [rbp+var_28]
lea rcx, ft_add_word
mov [rax+8], rcx
mov rax, [rbp+var_28]
lea rcx, [rbp+var_40]
mov [rax+18h], rcx
mov rax, [rbp+var_8]
mov rcx, [rax+230h]
mov rax, [rbp+var_28]
mov [rax+20h], rcx
mov rcx, [rbp+var_10]
mov rax, [rbp+var_28]
mov [rax+28h], rcx
mov ecx, [rbp+var_14]
mov rax, [rbp+var_28]
mov [rax+30h], ecx
mov rax, [rbp+var_28]
mov dword ptr [rax+38h], 0
mov rax, [rbp+var_20]
mov rax, [rax+8]
mov rdi, [rbp+var_28]
call rax
mov [rbp+var_44], eax
mov eax, [rbp+var_44]
add rsp, 50h
pop rbp
retn
| long long ft_parse(long long a1, long long a2, int a3, long long a4, _QWORD *a5, long long a6)
{
_QWORD v7[3]; // [rsp+10h] [rbp-40h] BYREF
_QWORD *v8; // [rsp+28h] [rbp-28h]
long long v9; // [rsp+30h] [rbp-20h]
int v10; // [rsp+3Ch] [rbp-14h]
long long v11; // [rsp+40h] [rbp-10h]
long long v12; // [rsp+48h] [rbp-8h]
v12 = a1;
v11 = a2;
v10 = a3;
v9 = a4;
v8 = a5;
v7[2] = a6;
v7[0] = a1;
v7[1] = a6;
*a5 = ft_parse_internal;
v8[1] = ft_add_word;
v8[3] = v7;
v8[4] = *(_QWORD *)(v12 + 560);
v8[5] = v11;
*((_DWORD *)v8 + 12) = v10;
*((_DWORD *)v8 + 14) = 0;
return (*(unsigned int ( **)(_QWORD *))(v9 + 8))(v8);
}
| ft_parse:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV qword ptr [RBP + -0x30],R9
JMP 0x001a1f21
LAB_001a1f21:
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x28]
LEA RCX,[0x1a1fb0]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x28]
LEA RCX,[0x1a2060]
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RBP + -0x28]
LEA RCX,[RBP + -0x40]
MOV qword ptr [RAX + 0x18],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x230]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX + 0x20],RCX
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX + 0x28],RCX
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RBP + -0x28]
MOV dword ptr [RAX + 0x30],ECX
MOV RAX,qword ptr [RBP + -0x28]
MOV dword ptr [RAX + 0x38],0x0
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x8]
MOV RDI,qword ptr [RBP + -0x28]
CALL RAX
MOV dword ptr [RBP + -0x44],EAX
MOV EAX,dword ptr [RBP + -0x44]
ADD RSP,0x50
POP RBP
RET
|
int4
ft_parse(long param_1,int8 param_2,int4 param_3,long param_4,int8 *param_5,
int8 param_6)
{
int4 uVar1;
long local_48;
int8 local_40;
int8 local_38;
int8 *local_30;
long local_28;
int4 local_1c;
int8 local_18;
long local_10;
*param_5 = ft_parse_internal;
param_5[1] = ft_add_word;
param_5[3] = &local_48;
param_5[4] = *(int8 *)(param_1 + 0x230);
param_5[5] = param_2;
*(int4 *)(param_5 + 6) = param_3;
*(int4 *)(param_5 + 7) = 0;
local_48 = param_1;
local_40 = param_6;
local_38 = param_6;
local_30 = param_5;
local_28 = param_4;
local_1c = param_3;
local_18 = param_2;
local_10 = param_1;
uVar1 = (**(code **)(param_4 + 8))(param_5);
return uVar1;
}
| |
21,430 | inline_mysql_file_close | eloqsql/include/mysql/psi/mysql_file.h | static inline int
inline_mysql_file_close(
#ifdef HAVE_PSI_FILE_INTERFACE
const char *src_file, uint src_line,
#endif
File file, myf flags)
{
int result;
#ifdef HAVE_PSI_FILE_INTERFACE
struct PSI_file_locker *locker;
PSI_file_locker_state state;
locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_CLOSE);
if (psi_likely(locker != NULL))
{
PSI_FILE_CALL(start_file_close_wait)(locker, src_file, src_line);
result= my_close(file, flags);
PSI_FILE_CALL(end_file_close_wait)(locker, result);
return result;
}
#endif
result= my_close(file, flags);
return result;
} | O0 | c | inline_mysql_file_close:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
leaq 0x1a42b8(%rip), %rax # 0x1db8a8
movq (%rax), %rax
movq 0x158(%rax), %rax
movl -0x18(%rbp), %esi
leaq -0x78(%rbp), %rdi
movl $0x4, %edx
callq *%rax
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
setne %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x3767b
leaq 0x1a4275(%rip), %rax # 0x1db8a8
movq (%rax), %rax
movq 0x220(%rax), %rax
movq -0x30(%rbp), %rdi
movq -0x10(%rbp), %rsi
movl -0x14(%rbp), %edx
callq *%rax
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
callq 0x3c030
movl %eax, -0x24(%rbp)
leaq 0x1a4248(%rip), %rax # 0x1db8a8
movq (%rax), %rax
movq 0x228(%rax), %rax
movq -0x30(%rbp), %rdi
movl -0x24(%rbp), %esi
callq *%rax
movl -0x24(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x37690
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
callq 0x3c030
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x80, %rsp
popq %rbp
retq
nopl (%rax)
| inline_mysql_file_close:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov [rbp+var_20], rcx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+158h]
mov esi, [rbp+var_18]
lea rdi, [rbp+var_78]
mov edx, 4
call rax
mov [rbp+var_30], rax
cmp [rbp+var_30], 0
setnz al
and al, 1
movzx eax, al
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_3767B
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+220h]
mov rdi, [rbp+var_30]
mov rsi, [rbp+var_10]
mov edx, [rbp+var_14]
call rax
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
call my_close
mov [rbp+var_24], eax
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+228h]
mov rdi, [rbp+var_30]
mov esi, [rbp+var_24]
call rax
mov eax, [rbp+var_24]
mov [rbp+var_4], eax
jmp short loc_37690
loc_3767B:
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
call my_close
mov [rbp+var_24], eax
mov eax, [rbp+var_24]
mov [rbp+var_4], eax
loc_37690:
mov eax, [rbp+var_4]
add rsp, 80h
pop rbp
retn
| long long inline_mysql_file_close(long long a1, unsigned int a2, unsigned int a3, long long a4)
{
_BYTE v5[72]; // [rsp+8h] [rbp-78h] BYREF
long long v6; // [rsp+50h] [rbp-30h]
unsigned int v7; // [rsp+5Ch] [rbp-24h]
long long v8; // [rsp+60h] [rbp-20h]
unsigned int v9; // [rsp+68h] [rbp-18h]
unsigned int v10; // [rsp+6Ch] [rbp-14h]
long long v11; // [rsp+70h] [rbp-10h]
v11 = a1;
v10 = a2;
v9 = a3;
v8 = a4;
v6 = (*((long long ( **)(_BYTE *, _QWORD, long long))PSI_server[0] + 43))(v5, a3, 4LL);
if ( v6 )
{
(*((void ( **)(long long, long long, _QWORD))PSI_server[0] + 68))(v6, v11, v10);
v7 = my_close(v9, v8);
(*((void ( **)(long long, _QWORD))PSI_server[0] + 69))(v6, v7);
}
else
{
return (unsigned int)my_close(v9, v8);
}
return v7;
}
| inline_mysql_file_close:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV dword ptr [RBP + -0x18],EDX
MOV qword ptr [RBP + -0x20],RCX
LEA RAX,[0x2db8a8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x158]
MOV ESI,dword ptr [RBP + -0x18]
LEA RDI,[RBP + -0x78]
MOV EDX,0x4
CALL RAX
MOV qword ptr [RBP + -0x30],RAX
CMP qword ptr [RBP + -0x30],0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x0013767b
LEA RAX,[0x2db8a8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x220]
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,qword ptr [RBP + -0x10]
MOV EDX,dword ptr [RBP + -0x14]
CALL RAX
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x0013c030
MOV dword ptr [RBP + -0x24],EAX
LEA RAX,[0x2db8a8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x228]
MOV RDI,qword ptr [RBP + -0x30]
MOV ESI,dword ptr [RBP + -0x24]
CALL RAX
MOV EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x00137690
LAB_0013767b:
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x0013c030
MOV dword ptr [RBP + -0x24],EAX
MOV EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x4],EAX
LAB_00137690:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x80
POP RBP
RET
|
int4
inline_mysql_file_close(int8 param_1,int4 param_2,int4 param_3,int8 param_4)
{
int1 local_80 [72];
long local_38;
int4 local_2c;
int8 local_28;
int4 local_20;
int4 local_1c;
int8 local_18;
int4 local_c;
local_28 = param_4;
local_20 = param_3;
local_1c = param_2;
local_18 = param_1;
local_38 = (**(code **)(PSI_server + 0x158))(local_80,param_3,4);
if (local_38 == 0) {
local_c = my_close(local_20,local_28);
}
else {
(**(code **)(PSI_server + 0x220))(local_38,local_18,local_1c);
local_2c = my_close(local_20,local_28);
(**(code **)(PSI_server + 0x228))(local_38,local_2c);
local_c = local_2c;
}
return local_c;
}
| |
21,431 | ftb_find_relevance_parse | eloqsql/storage/myisam/ft_boolean_search.c | static int ftb_find_relevance_parse(MYSQL_FTPARSER_PARAM *param,
const char *doc, int len)
{
MY_FTB_FIND_PARAM *ftb_param= param->mysql_ftparam;
FT_INFO *ftb= ftb_param->ftb;
uchar *end= (uchar*) doc + len;
FT_WORD w;
while (ft_simple_get_word(ftb->charset, (uchar**) &doc, end, &w, TRUE))
param->mysql_add_word(param, (char*) w.pos, (int)w.len, 0);
return(0);
} | O3 | c | ftb_find_relevance_parse:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
leaq -0x30(%rbp), %rax
movq %rsi, (%rax)
movq 0x18(%rdi), %rcx
movq (%rcx), %r13
movslq %edx, %r14
addq %rsi, %r14
movq 0x10(%r13), %rdi
leaq -0x48(%rbp), %rcx
movq %rax, %rsi
movq %r14, %rdx
movl $0x1, %r8d
callq 0x74ab9
testb %al, %al
je 0x7349d
leaq -0x30(%rbp), %r15
leaq -0x48(%rbp), %r12
movq -0x48(%rbp), %rsi
movl -0x38(%rbp), %edx
movq %rbx, %rdi
xorl %ecx, %ecx
callq *0x8(%rbx)
movq 0x10(%r13), %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %r12, %rcx
movl $0x1, %r8d
callq 0x74ab9
testb %al, %al
jne 0x73472
xorl %eax, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| ftb_find_relevance_parse:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov rbx, rdi
lea rax, [rbp+var_30]
mov [rax], rsi
mov rcx, [rdi+18h]
mov r13, [rcx]
movsxd r14, edx
add r14, rsi
mov rdi, [r13+10h]
lea rcx, [rbp+var_48]
mov rsi, rax
mov rdx, r14
mov r8d, 1
call ft_simple_get_word
test al, al
jz short loc_7349D
lea r15, [rbp+var_30]
lea r12, [rbp+var_48]
loc_73472:
mov rsi, [rbp+var_48]
mov edx, [rbp+var_38]
mov rdi, rbx
xor ecx, ecx
call qword ptr [rbx+8]
mov rdi, [r13+10h]
mov rsi, r15
mov rdx, r14
mov rcx, r12
mov r8d, 1
call ft_simple_get_word
test al, al
jnz short loc_73472
loc_7349D:
xor eax, eax
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long ftb_find_relevance_parse(long long a1, long long a2, int a3)
{
long long v3; // r13
long long v4; // r14
_QWORD v6[2]; // [rsp+8h] [rbp-48h] BYREF
unsigned int v7; // [rsp+18h] [rbp-38h]
_QWORD v8[6]; // [rsp+20h] [rbp-30h] BYREF
v8[0] = a2;
v3 = **(_QWORD **)(a1 + 24);
v4 = a2 + a3;
while ( (unsigned __int8)ft_simple_get_word(*(_QWORD *)(v3 + 16), v8, v4, v6, 1LL) )
(*(void ( **)(long long, _QWORD, _QWORD, _QWORD))(a1 + 8))(a1, v6[0], v7, 0LL);
return 0LL;
}
| ftb_find_relevance_parse:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV RBX,RDI
LEA RAX,[RBP + -0x30]
MOV qword ptr [RAX],RSI
MOV RCX,qword ptr [RDI + 0x18]
MOV R13,qword ptr [RCX]
MOVSXD R14,EDX
ADD R14,RSI
MOV RDI,qword ptr [R13 + 0x10]
LEA RCX,[RBP + -0x48]
MOV RSI,RAX
MOV RDX,R14
MOV R8D,0x1
CALL 0x00174ab9
TEST AL,AL
JZ 0x0017349d
LEA R15,[RBP + -0x30]
LEA R12,[RBP + -0x48]
LAB_00173472:
MOV RSI,qword ptr [RBP + -0x48]
MOV EDX,dword ptr [RBP + -0x38]
MOV RDI,RBX
XOR ECX,ECX
CALL qword ptr [RBX + 0x8]
MOV RDI,qword ptr [R13 + 0x10]
MOV RSI,R15
MOV RDX,R14
MOV RCX,R12
MOV R8D,0x1
CALL 0x00174ab9
TEST AL,AL
JNZ 0x00173472
LAB_0017349d:
XOR EAX,EAX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8 ftb_find_relevance_parse(long param_1,long param_2,int param_3)
{
long lVar1;
char cVar2;
int8 local_50 [2];
int4 local_40;
long local_38;
lVar1 = **(long **)(param_1 + 0x18);
local_38 = param_2;
cVar2 = ft_simple_get_word(*(int8 *)(lVar1 + 0x10),&local_38,param_3 + param_2,local_50,1);
if (cVar2 != '\0') {
do {
(**(code **)(param_1 + 8))(param_1,local_50[0],local_40,0);
cVar2 = ft_simple_get_word(*(int8 *)(lVar1 + 0x10),&local_38,param_3 + param_2,local_50,
1);
} while (cVar2 != '\0');
}
return 0;
}
| |
21,432 | nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(char*, int, unsigned long, unsigned long, unsigned long, unsigned long) | monkey531[P]llama/common/json.hpp | inline void grisu2_round(char* buf, int len, std::uint64_t dist, std::uint64_t delta,
std::uint64_t rest, std::uint64_t ten_k)
{
JSON_ASSERT(len >= 1);
JSON_ASSERT(dist <= delta);
JSON_ASSERT(rest <= delta);
JSON_ASSERT(ten_k > 0);
// <--------------------------- delta ---->
// <---- dist --------->
// --------------[------------------+-------------------]--------------
// M- w M+
//
// ten_k
// <------>
// <---- rest ---->
// --------------[------------------+----+--------------]--------------
// w V
// = buf * 10^k
//
// ten_k represents a unit-in-the-last-place in the decimal representation
// stored in buf.
// Decrement buf by ten_k while this takes buf closer to w.
// The tests are written in this order to avoid overflow in unsigned
// integer arithmetic.
while (rest < dist
&& delta - rest >= ten_k
&& (rest + ten_k < dist || dist - rest > rest + ten_k - dist))
{
JSON_ASSERT(buf[len - 1] != '0');
buf[len - 1]--;
rest += ten_k;
}
} | O2 | cpp | nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(char*, int, unsigned long, unsigned long, unsigned long, unsigned long):
pushq %rax
testl %esi, %esi
jle 0x8af27
cmpq %rcx, %rdx
ja 0x8af43
subq %r8, %rcx
jb 0x8af5f
testq %r9, %r9
je 0x8af7b
movl %esi, %eax
movq %r9, %rsi
subq %rdx, %rsi
movq %rdx, %r10
subq %r8, %r10
cmpq %rdx, %r8
jae 0x8af04
subq %r9, %rcx
jb 0x8af04
leaq (%r8,%r9), %r11
cmpq %rdx, %r11
jb 0x8aee9
addq %rsi, %r8
cmpq %r8, %r10
jbe 0x8af04
movb -0x1(%rdi,%rax), %r8b
cmpb $0x30, %r8b
je 0x8af06
decb %r8b
movb %r8b, -0x1(%rdi,%rax)
subq %r9, %r10
movq %r11, %r8
jmp 0x8aece
popq %rax
retq
leaq 0x271af(%rip), %rdi # 0xb20bc
leaq 0x271f2(%rip), %rdx # 0xb2106
leaq 0x2ca56(%rip), %rcx # 0xb7971
movl $0x444d, %esi # imm = 0x444D
xorl %eax, %eax
callq 0x250e0
leaq 0x2718e(%rip), %rdi # 0xb20bc
leaq 0x271d1(%rip), %rdx # 0xb2106
leaq 0x2ca06(%rip), %rcx # 0xb7942
movl $0x4431, %esi # imm = 0x4431
jmp 0x8af20
leaq 0x27172(%rip), %rdi # 0xb20bc
leaq 0x271b5(%rip), %rdx # 0xb2106
leaq 0x2c9f3(%rip), %rcx # 0xb794b
movl $0x4432, %esi # imm = 0x4432
jmp 0x8af20
leaq 0x27156(%rip), %rdi # 0xb20bc
leaq 0x27199(%rip), %rdx # 0xb2106
leaq 0x2c9e5(%rip), %rcx # 0xb7959
movl $0x4433, %esi # imm = 0x4433
jmp 0x8af20
leaq 0x2713a(%rip), %rdi # 0xb20bc
leaq 0x2717d(%rip), %rdx # 0xb2106
leaq 0x2c9d7(%rip), %rcx # 0xb7967
movl $0x4434, %esi # imm = 0x4434
jmp 0x8af20
| _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl12grisu2_roundEPcimmmm:
push rax
test esi, esi
jle loc_8AF27
cmp rdx, rcx
ja loc_8AF43
sub rcx, r8
jb loc_8AF5F
test r9, r9
jz loc_8AF7B
mov eax, esi
mov rsi, r9
sub rsi, rdx
mov r10, rdx
sub r10, r8
loc_8AECE:
cmp r8, rdx
jnb short loc_8AF04
sub rcx, r9
jb short loc_8AF04
lea r11, [r8+r9]
cmp r11, rdx
jb short loc_8AEE9
add r8, rsi
cmp r10, r8
jbe short loc_8AF04
loc_8AEE9:
mov r8b, [rdi+rax-1]
cmp r8b, 30h ; '0'
jz short loc_8AF06
dec r8b
mov [rdi+rax-1], r8b
sub r10, r9
mov r8, r11
jmp short loc_8AECE
loc_8AF04:
pop rax
retn
loc_8AF06:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aBufLen10; "buf[len - 1] != '0'"
mov esi, 444Dh
loc_8AF20:
xor eax, eax
call _ggml_abort
loc_8AF27:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aLen1; "len >= 1"
mov esi, 4431h
jmp short loc_8AF20
loc_8AF43:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aDistDelta; "dist <= delta"
mov esi, 4432h
jmp short loc_8AF20
loc_8AF5F:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aRestDelta; "rest <= delta"
mov esi, 4433h
jmp short loc_8AF20
loc_8AF7B:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aTenK0; "ten_k > 0"
mov esi, 4434h
jmp short loc_8AF20
| void __spoils<rdx,rcx,r8,r9,r10,r11,xmm4,xmm5> nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *this,
char *a2,
unsigned long long a3,
unsigned long long a4,
unsigned long long a5,
unsigned long long a6)
{
bool v6; // cf
unsigned long long v7; // rcx
unsigned long long v8; // r10
unsigned long long v9; // r11
char v10; // r8
if ( (int)a2 <= 0 )
{
while ( 1 )
LABEL_14:
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17457LL,
"GGML_ASSERT(%s) failed",
"len >= 1");
}
if ( a3 > a4 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17458LL,
"GGML_ASSERT(%s) failed",
"dist <= delta");
goto LABEL_14;
}
v6 = a4 < a5;
v7 = a4 - a5;
if ( v6 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17459LL,
"GGML_ASSERT(%s) failed",
"rest <= delta");
goto LABEL_14;
}
if ( !a6 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17460LL,
"GGML_ASSERT(%s) failed",
"ten_k > 0");
goto LABEL_14;
}
v8 = a3 - a5;
while ( a5 < a3 )
{
v6 = v7 < a6;
v7 -= a6;
if ( v6 )
break;
v9 = a5 + a6;
if ( a5 + a6 >= a3 && v8 <= a6 - a3 + a5 )
break;
v10 = *((_BYTE *)this + (unsigned int)a2 - 1);
if ( v10 == 48 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
17485LL,
"GGML_ASSERT(%s) failed",
"buf[len - 1] != '0'");
goto LABEL_14;
}
*((_BYTE *)this + (unsigned int)a2 - 1) = v10 - 1;
v8 -= a6;
a5 = v9;
}
}
| grisu2_round:
PUSH RAX
TEST ESI,ESI
JLE 0x0018af27
CMP RDX,RCX
JA 0x0018af43
SUB RCX,R8
JC 0x0018af5f
TEST R9,R9
JZ 0x0018af7b
MOV EAX,ESI
MOV RSI,R9
SUB RSI,RDX
MOV R10,RDX
SUB R10,R8
LAB_0018aece:
CMP R8,RDX
JNC 0x0018af04
SUB RCX,R9
JC 0x0018af04
LEA R11,[R8 + R9*0x1]
CMP R11,RDX
JC 0x0018aee9
ADD R8,RSI
CMP R10,R8
JBE 0x0018af04
LAB_0018aee9:
MOV R8B,byte ptr [RDI + RAX*0x1 + -0x1]
CMP R8B,0x30
JZ 0x0018af06
DEC R8B
MOV byte ptr [RDI + RAX*0x1 + -0x1],R8B
SUB R10,R9
MOV R8,R11
JMP 0x0018aece
LAB_0018af04:
POP RAX
RET
LAB_0018af06:
LEA RDI,[0x1b20bc]
LEA RDX,[0x1b2106]
LEA RCX,[0x1b7971]
MOV ESI,0x444d
LAB_0018af20:
XOR EAX,EAX
CALL 0x001250e0
LAB_0018af27:
LEA RDI,[0x1b20bc]
LEA RDX,[0x1b2106]
LEA RCX,[0x1b7942]
MOV ESI,0x4431
JMP 0x0018af20
LAB_0018af43:
LEA RDI,[0x1b20bc]
LEA RDX,[0x1b2106]
LEA RCX,[0x1b794b]
MOV ESI,0x4432
JMP 0x0018af20
LAB_0018af5f:
LEA RDI,[0x1b20bc]
LEA RDX,[0x1b2106]
LEA RCX,[0x1b7959]
MOV ESI,0x4433
JMP 0x0018af20
LAB_0018af7b:
LEA RDI,[0x1b20bc]
LEA RDX,[0x1b2106]
LEA RCX,[0x1b7967]
MOV ESI,0x4434
JMP 0x0018af20
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round(char*, int, unsigned long, unsigned
long, unsigned long, unsigned long) */
int8
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::grisu2_round
(char *param_1,int param_2,ulong param_3,ulong param_4,ulong param_5,ulong param_6)
{
int8 in_RAX;
ulong uVar1;
char *pcVar2;
int8 uVar3;
ulong uVar4;
bool bVar5;
if (param_2 < 1) {
pcVar2 = "len >= 1";
uVar3 = 0x4431;
}
else if (param_4 < param_3) {
pcVar2 = "dist <= delta";
uVar3 = 0x4432;
}
else {
uVar1 = param_4 - param_5;
if (param_4 < param_5) {
pcVar2 = "rest <= delta";
uVar3 = 0x4433;
}
else if (param_6 == 0) {
pcVar2 = "ten_k > 0";
uVar3 = 0x4434;
}
else {
uVar4 = param_3 - param_5;
while( true ) {
if (((param_3 <= param_5) || (bVar5 = uVar1 < param_6, uVar1 = uVar1 - param_6, bVar5)) ||
((param_3 <= param_5 + param_6 && (uVar4 <= param_5 + (param_6 - param_3))))) {
return in_RAX;
}
if (param_1[(ulong)(uint)param_2 - 1] == '0') break;
param_1[(ulong)(uint)param_2 - 1] = param_1[(ulong)(uint)param_2 - 1] + -1;
uVar4 = uVar4 - param_6;
param_5 = param_5 + param_6;
}
pcVar2 = "buf[len - 1] != \'0\'";
uVar3 = 0x444d;
}
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
| |
21,433 | fmt::v8::detail::bigint::subtract_aligned(fmt::v8::detail::bigint const&) | aimrt_mujoco_sim/_deps/spdlog_lib-src/include/spdlog/fmt/bundled/format-inl.h | void subtract_aligned(const bigint& other) {
FMT_ASSERT(other.exp_ >= exp_, "unaligned bigints");
FMT_ASSERT(compare(*this, other) >= 0, "");
bigit borrow = 0;
int i = other.exp_ - exp_;
for (size_t j = 0, n = other.bigits_.size(); j != n; ++i, ++j)
subtract_bigits(i, other.bigits_[j], borrow);
while (borrow > 0) subtract_bigits(i, 0, borrow);
remove_leading_zeros();
} | O3 | c | fmt::v8::detail::bigint::subtract_aligned(fmt::v8::detail::bigint const&):
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
callq 0x4763f
movq 0x10(%r14), %rcx
testq %rcx, %rcx
je 0x47cfb
movl 0xa8(%r14), %eax
subl 0xa8(%rbx), %eax
movq 0x8(%r14), %rsi
movq 0x8(%rbx), %rdi
xorl %edx, %edx
xorl %r8d, %r8d
leal (%rax,%rdx), %r10d
movl (%rsi,%rdx,4), %r9d
subq %r9, %r8
movl (%rdi,%r10,4), %r9d
addq %r8, %r9
movl %r9d, (%rdi,%r10,4)
movq %r9, %r8
sarq $0x3f, %r8
incq %rdx
cmpq %rdx, %rcx
jne 0x47caa
testq %r9, %r9
jns 0x47cfb
addq %rdx, %rax
movq 0x8(%rbx), %rcx
movl %eax, %eax
movl (%rcx,%rax,4), %edx
movq $-0x1, %rsi
movl %edx, %edx
addq %rsi, %rdx
movq %rdx, %rsi
sarq $0x3f, %rsi
testq %rdx, %rdx
js 0x47ce7
movl %edx, (%rcx,%rax,4)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x47a64
| _ZN3fmt2v86detail6bigint16subtract_alignedERKS2_:
push r14
push rbx
push rax
mov r14, rsi
mov rbx, rdi
call _ZN3fmt2v86detail7compareERKNS1_6bigintES4_; fmt::v8::detail::compare(fmt::v8::detail::bigint const&,fmt::v8::detail::bigint const&)
mov rcx, [r14+10h]
test rcx, rcx
jz short loc_47CFB
mov eax, [r14+0A8h]
sub eax, [rbx+0A8h]
mov rsi, [r14+8]
mov rdi, [rbx+8]
xor edx, edx
xor r8d, r8d
loc_47CAA:
lea r10d, [rax+rdx]
mov r9d, [rsi+rdx*4]
sub r8, r9
mov r9d, [rdi+r10*4]
add r9, r8
mov [rdi+r10*4], r9d
mov r8, r9
sar r8, 3Fh
inc rdx
cmp rcx, rdx
jnz short loc_47CAA
test r9, r9
jns short loc_47CFB
add rax, rdx
mov rcx, [rbx+8]
mov eax, eax
mov edx, [rcx+rax*4]
mov rsi, 0FFFFFFFFFFFFFFFFh
loc_47CE7:
mov edx, edx
add rdx, rsi
mov rsi, rdx
sar rsi, 3Fh
test rdx, rdx
js short loc_47CE7
mov [rcx+rax*4], edx
loc_47CFB:
mov rdi, rbx; this
add rsp, 8
pop rbx
pop r14
jmp _ZN3fmt2v86detail6bigint20remove_leading_zerosEv; fmt::v8::detail::bigint::remove_leading_zeros(void)
| unsigned long long fmt::v8::detail::bigint::subtract_aligned(
fmt::v8::detail::bigint *this,
const fmt::v8::detail::bigint *a2,
const fmt::v8::detail::bigint *a3)
{
long long v4; // rcx
int v5; // eax
long long v6; // rsi
long long v7; // rdi
long long v8; // rdx
long long v9; // r8
long long v10; // r10
long long v11; // r9
long long v12; // rcx
long long v13; // rax
long long v14; // rsi
fmt::v8::detail::compare(this, a2, a3);
v4 = *((_QWORD *)a2 + 2);
if ( v4 )
{
v5 = *((_DWORD *)a2 + 42) - *((_DWORD *)this + 42);
v6 = *((_QWORD *)a2 + 1);
v7 = *((_QWORD *)this + 1);
v8 = 0LL;
v9 = 0LL;
do
{
v10 = (unsigned int)(v5 + v8);
v11 = v9 - *(unsigned int *)(v6 + 4 * v8) + *(unsigned int *)(v7 + 4 * v10);
*(_DWORD *)(v7 + 4 * v10) = v11;
v9 = v11 >> 63;
++v8;
}
while ( v4 != v8 );
if ( v11 < 0 )
{
v12 = *((_QWORD *)this + 1);
v13 = (unsigned int)(v8 + v5);
LODWORD(v8) = *(_DWORD *)(v12 + 4 * v13);
v14 = -1LL;
do
{
v8 = v14 + (unsigned int)v8;
v14 = v8 >> 63;
}
while ( v8 < 0 );
*(_DWORD *)(v12 + 4 * v13) = v8;
}
}
return fmt::v8::detail::bigint::remove_leading_zeros(this);
}
| subtract_aligned:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RSI
MOV RBX,RDI
CALL 0x0014763f
MOV RCX,qword ptr [R14 + 0x10]
TEST RCX,RCX
JZ 0x00147cfb
MOV EAX,dword ptr [R14 + 0xa8]
SUB EAX,dword ptr [RBX + 0xa8]
MOV RSI,qword ptr [R14 + 0x8]
MOV RDI,qword ptr [RBX + 0x8]
XOR EDX,EDX
XOR R8D,R8D
LAB_00147caa:
LEA R10D,[RAX + RDX*0x1]
MOV R9D,dword ptr [RSI + RDX*0x4]
SUB R8,R9
MOV R9D,dword ptr [RDI + R10*0x4]
ADD R9,R8
MOV dword ptr [RDI + R10*0x4],R9D
MOV R8,R9
SAR R8,0x3f
INC RDX
CMP RCX,RDX
JNZ 0x00147caa
TEST R9,R9
JNS 0x00147cfb
ADD RAX,RDX
MOV RCX,qword ptr [RBX + 0x8]
MOV EAX,EAX
MOV EDX,dword ptr [RCX + RAX*0x4]
MOV RSI,-0x1
LAB_00147ce7:
MOV EDX,EDX
ADD RDX,RSI
MOV RSI,RDX
SAR RSI,0x3f
TEST RDX,RDX
JS 0x00147ce7
MOV dword ptr [RCX + RAX*0x4],EDX
LAB_00147cfb:
MOV RDI,RBX
ADD RSP,0x8
POP RBX
POP R14
JMP 0x00147a64
|
/* fmt::v8::detail::bigint::subtract_aligned(fmt::v8::detail::bigint const&) */
void __thiscall fmt::v8::detail::bigint::subtract_aligned(bigint *this,bigint *param_1)
{
int iVar1;
int iVar2;
long lVar3;
long lVar4;
ulong uVar5;
long lVar6;
ulong uVar7;
long lVar8;
long lVar9;
long lVar10;
compare(this,param_1);
lVar8 = *(long *)(param_1 + 0x10);
if (lVar8 != 0) {
iVar1 = *(int *)(param_1 + 0xa8);
iVar2 = *(int *)(this + 0xa8);
lVar3 = *(long *)(param_1 + 8);
lVar4 = *(long *)(this + 8);
lVar6 = 0;
lVar9 = 0;
do {
uVar5 = (ulong)(uint)((iVar1 - iVar2) + (int)lVar6);
lVar10 = (ulong)*(uint *)(lVar4 + uVar5 * 4) + (lVar9 - (ulong)*(uint *)(lVar3 + lVar6 * 4));
*(int *)(lVar4 + uVar5 * 4) = (int)lVar10;
lVar9 = lVar10 >> 0x3f;
lVar6 = lVar6 + 1;
} while (lVar8 != lVar6);
if (lVar10 < 0) {
uVar5 = (ulong)(uint)((iVar1 - iVar2) + (int)lVar6);
uVar7 = (ulong)*(uint *)(*(long *)(this + 8) + uVar5 * 4);
lVar8 = -1;
do {
uVar7 = (uVar7 & 0xffffffff) + lVar8;
lVar8 = (long)uVar7 >> 0x3f;
} while ((long)uVar7 < 0);
*(int *)(*(long *)(this + 8) + uVar5 * 4) = (int)uVar7;
}
}
remove_leading_zeros(this);
return;
}
| |
21,434 | translog_scanner_eol | eloqsql/storage/maria/ma_loghandler.c | static my_bool translog_scanner_eol(TRANSLOG_SCANNER_DATA *scanner)
{
DBUG_ENTER("translog_scanner_eol");
DBUG_PRINT("enter",
("Horizon: " LSN_FMT " Current: (%u, 0x%x+0x%x=0x%x)",
LSN_IN_PARTS(scanner->horizon),
LSN_IN_PARTS(scanner->page_addr),
(uint) scanner->page_offset,
(uint) (LSN_OFFSET(scanner->page_addr) + scanner->page_offset)));
if (scanner->horizon > (scanner->page_addr +
scanner->page_offset))
{
DBUG_PRINT("info", ("Horizon is not reached"));
DBUG_RETURN(0);
}
if (scanner->fixed_horizon)
{
DBUG_PRINT("info", ("Horizon is fixed and reached"));
DBUG_RETURN(1);
}
scanner->horizon= translog_get_horizon();
DBUG_PRINT("info",
("Horizon is re-read, EOL: %d",
scanner->horizon <= (scanner->page_addr +
scanner->page_offset)));
DBUG_RETURN(scanner->horizon <= (scanner->page_addr +
scanner->page_offset));
} | O3 | c | translog_scanner_eol:
movl 0x2028(%rdi), %eax
addq 0x2000(%rdi), %rax
cmpq %rax, 0x2008(%rdi)
jle 0x50114
xorl %eax, %eax
retq
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movb $0x1, %al
cmpb $0x0, 0x202c(%rdi)
jne 0x50147
callq 0x4bf7c
movq %rax, 0x2008(%rbx)
movl 0x2028(%rbx), %ecx
addq 0x2000(%rbx), %rcx
cmpq %rcx, %rax
setle %al
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| translog_scanner_eol:
mov eax, [rdi+2028h]
add rax, [rdi+2000h]
cmp [rdi+2008h], rax
jle short loc_50114
xor eax, eax
retn
loc_50114:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdi
mov al, 1
cmp byte ptr [rdi+202Ch], 0
jnz short loc_50147
call translog_get_horizon
mov [rbx+2008h], rax
mov ecx, [rbx+2028h]
add rcx, [rbx+2000h]
cmp rax, rcx
setle al
loc_50147:
add rsp, 8
pop rbx
pop rbp
retn
| bool translog_scanner_eol(long long a1)
{
bool result; // al
long long horizon; // rax
if ( *(_QWORD *)(a1 + 8200) > (signed long long)(*(_QWORD *)(a1 + 0x2000) + *(unsigned int *)(a1 + 8232)) )
return 0;
result = 1;
if ( !*(_BYTE *)(a1 + 8236) )
{
horizon = translog_get_horizon();
*(_QWORD *)(a1 + 8200) = horizon;
return horizon <= *(_QWORD *)(a1 + 0x2000) + *(unsigned int *)(a1 + 8232);
}
return result;
}
| translog_scanner_eol:
MOV EAX,dword ptr [RDI + 0x2028]
ADD RAX,qword ptr [RDI + 0x2000]
CMP qword ptr [RDI + 0x2008],RAX
JLE 0x00150114
XOR EAX,EAX
RET
LAB_00150114:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV AL,0x1
CMP byte ptr [RDI + 0x202c],0x0
JNZ 0x00150147
CALL 0x0014bf7c
MOV qword ptr [RBX + 0x2008],RAX
MOV ECX,dword ptr [RBX + 0x2028]
ADD RCX,qword ptr [RBX + 0x2000]
CMP RAX,RCX
SETLE AL
LAB_00150147:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
bool translog_scanner_eol(long param_1)
{
bool bVar1;
long lVar2;
if ((long)((ulong)*(uint *)(param_1 + 0x2028) + *(long *)(param_1 + 0x2000)) <
*(long *)(param_1 + 0x2008)) {
return false;
}
bVar1 = true;
if (*(char *)(param_1 + 0x202c) == '\0') {
lVar2 = translog_get_horizon();
*(long *)(param_1 + 0x2008) = lVar2;
bVar1 = lVar2 <= (long)((ulong)*(uint *)(param_1 + 0x2028) + *(long *)(param_1 + 0x2000));
}
return bVar1;
}
| |
21,435 | plugin_dl_del(st_plugin_dl*) | eloqsql/sql/sql_plugin.cc | static void plugin_dl_del(struct st_plugin_dl *plugin_dl)
{
DBUG_ENTER("plugin_dl_del");
if (!plugin_dl)
DBUG_VOID_RETURN;
mysql_mutex_assert_owner(&LOCK_plugin);
/* Do not remove this element, unless no other plugin uses this dll. */
if (! --plugin_dl->ref_count)
{
free_plugin_mem(plugin_dl);
bzero(plugin_dl, sizeof(struct st_plugin_dl));
}
DBUG_VOID_RETURN;
} | O0 | cpp | plugin_dl_del(st_plugin_dl*):
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
jne 0xa0f5c7
jmp 0xa0f5c5
jmp 0xa0f5fa
jmp 0xa0f5c9
jmp 0xa0f5cb
movq -0x8(%rbp), %rcx
movl 0x2c(%rcx), %eax
addl $-0x1, %eax
movl %eax, 0x2c(%rcx)
cmpl $0x0, %eax
jne 0xa0f5f6
movq -0x8(%rbp), %rdi
callq 0xa0d530
movq -0x8(%rbp), %rdi
xorl %esi, %esi
movl $0x40, %edx
callq 0x7754f0
jmp 0xa0f5f8
jmp 0xa0f5fa
addq $0x10, %rsp
popq %rbp
retq
| _ZL13plugin_dl_delP12st_plugin_dl:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
cmp [rbp+var_8], 0
jnz short loc_A0F5C7
jmp short $+2
loc_A0F5C5:
jmp short loc_A0F5FA
loc_A0F5C7:
jmp short $+2
loc_A0F5C9:
jmp short $+2
loc_A0F5CB:
mov rcx, [rbp+var_8]
mov eax, [rcx+2Ch]
add eax, 0FFFFFFFFh
mov [rcx+2Ch], eax
cmp eax, 0
jnz short loc_A0F5F6
mov rdi, [rbp+var_8]
call _ZL15free_plugin_memP12st_plugin_dl; free_plugin_mem(st_plugin_dl *)
mov rdi, [rbp+var_8]
xor esi, esi
mov edx, 40h ; '@'
call _memset
loc_A0F5F6:
jmp short $+2
loc_A0F5F8:
jmp short $+2
loc_A0F5FA:
add rsp, 10h
pop rbp
retn
| long long plugin_dl_del(long long a1)
{
long long result; // rax
if ( a1 )
{
result = (unsigned int)(*(_DWORD *)(a1 + 44) - 1);
*(_DWORD *)(a1 + 44) = result;
if ( !(_DWORD)result )
{
free_plugin_mem(a1);
return memset(a1, 0LL, 64LL);
}
}
return result;
}
| instructions:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x9f8]
POP RBP
RET
|
/* sp_head::instructions() */
int4 __thiscall sp_head::instructions(sp_head *this)
{
return *(int4 *)(this + 0x9f8);
}
| |
21,436 | translog_put_sector_protection | eloqsql/storage/maria/ma_loghandler.c | static void translog_put_sector_protection(uchar *page,
struct st_buffer_cursor *cursor)
{
uchar *table= page + log_descriptor.page_overhead -
TRANSLOG_PAGE_SIZE / DISK_DRIVE_SECTOR_SIZE;
uint i, offset;
uint16 last_protected_sector= ((cursor->previous_offset - 1) /
DISK_DRIVE_SECTOR_SIZE);
uint16 start_sector= cursor->previous_offset / DISK_DRIVE_SECTOR_SIZE;
uint8 value= table[0] + cursor->write_counter;
DBUG_ENTER("translog_put_sector_protection");
if (start_sector == 0)
{
/* First sector is protected by file & page numbers in the page header. */
start_sector= 1;
}
DBUG_PRINT("enter", ("Write counter:%u value:%u offset:%u, "
"last protected:%u start sector:%u",
(uint) cursor->write_counter,
(uint) value,
(uint) cursor->previous_offset,
(uint) last_protected_sector, (uint) start_sector));
if (last_protected_sector == start_sector)
{
i= last_protected_sector;
offset= last_protected_sector * DISK_DRIVE_SECTOR_SIZE;
/* restore data, because we modified sector which was protected */
if (offset < cursor->previous_offset)
page[offset]= table[i];
}
for (i= start_sector, offset= start_sector * DISK_DRIVE_SECTOR_SIZE;
i < TRANSLOG_PAGE_SIZE / DISK_DRIVE_SECTOR_SIZE;
i++, (offset+= DISK_DRIVE_SECTOR_SIZE))
{
DBUG_PRINT("info", ("sector:%u offset:%u data 0x%x",
i, offset, (uint) page[offset]));
table[i]= page[offset];
page[offset]= value;
DBUG_PRINT("info", ("sector:%u offset:%u data 0x%x",
i, offset, (uint) page[offset]));
}
DBUG_VOID_RETURN;
} | O3 | c | translog_put_sector_protection:
movzwl 0x3b0668(%rip), %eax # 0x400a94
movl $0xffff, %r9d # imm = 0xFFFF
andl %r9d, %edx
leal 0x1ffffff(%rdx), %ecx
shrl $0x9, %ecx
movl %edx, %r10d
shrl $0x9, %r10d
addb -0x10(%rdi,%rax), %sil
cmpl $0x200, %edx # imm = 0x200
movl $0x1, %r8d
cmovael %r10d, %r8d
cmpw %cx, %r8w
jne 0x5047e
andl %r9d, %ecx
movl %ecx, %r9d
shll $0x9, %r9d
cmpl %edx, %r9d
jae 0x5047e
leaq (%rdi,%rax), %rdx
addq $-0x10, %rdx
movb (%rdx,%rcx), %cl
movb %cl, (%rdi,%r9)
cmpw $0xf, %r8w
ja 0x504b1
pushq %rbp
movq %rsp, %rbp
addq %rdi, %rax
movzwl %r8w, %edx
leaq -0x10(%rdx), %rcx
shll $0x9, %edx
addq %rdi, %rdx
movb (%rdx), %dil
movb %dil, (%rax,%rcx)
movb %sil, (%rdx)
addq $0x200, %rdx # imm = 0x200
incq %rcx
jne 0x5049a
popq %rbp
retq
| translog_put_sector_protection:
movzx eax, cs:word_400A94
mov r9d, 0FFFFh
and edx, r9d
lea ecx, [rdx+1FFFFFFh]
shr ecx, 9
mov r10d, edx
shr r10d, 9
add sil, [rdi+rax-10h]
cmp edx, 200h
mov r8d, 1
cmovnb r8d, r10d
cmp r8w, cx
jnz short loc_5047E
and ecx, r9d
mov r9d, ecx
shl r9d, 9
cmp r9d, edx
jnb short loc_5047E
lea rdx, [rdi+rax]
add rdx, 0FFFFFFFFFFFFFFF0h
mov cl, [rdx+rcx]
mov [rdi+r9], cl
loc_5047E:
cmp r8w, 0Fh
ja short locret_504B1
push rbp
mov rbp, rsp
add rax, rdi
movzx edx, r8w
lea rcx, [rdx-10h]
shl edx, 9
add rdx, rdi
loc_5049A:
mov dil, [rdx]
mov [rax+rcx], dil
mov [rdx], sil
add rdx, 200h
inc rcx
jnz short loc_5049A
pop rbp
locret_504B1:
retn
| long long translog_put_sector_protection(long long a1, char a2, unsigned __int16 a3)
{
long long result; // rax
char v4; // si
unsigned __int16 v5; // r8
long long v6; // rcx
long long v7; // r9
long long v8; // rcx
_BYTE *v9; // rdx
result = (unsigned __int16)word_400A94;
v4 = *(_BYTE *)(a1 + (unsigned __int16)word_400A94 - 16) + a2;
v5 = 1;
if ( a3 >= 0x200u )
v5 = a3 >> 9;
if ( v5 == (unsigned __int16)(((unsigned int)a3 + 0x1FFFFFF) >> 9) )
{
v6 = (unsigned __int16)(((unsigned int)a3 + 0x1FFFFFF) >> 9);
v7 = (unsigned int)((_DWORD)v6 << 9);
if ( (unsigned int)v7 < a3 )
*(_BYTE *)(a1 + v7) = *(_BYTE *)(a1 + (unsigned __int16)word_400A94 - 16 + v6);
}
if ( v5 <= 0xFu )
{
result += a1;
v8 = v5 - 16LL;
v9 = (_BYTE *)(a1 + (v5 << 9));
do
{
*(_BYTE *)(result + v8) = *v9;
*v9 = v4;
v9 += 512;
++v8;
}
while ( v8 );
}
return result;
}
| translog_put_sector_protection:
MOVZX EAX,word ptr [0x00500a94]
MOV R9D,0xffff
AND EDX,R9D
LEA ECX,[RDX + 0x1ffffff]
SHR ECX,0x9
MOV R10D,EDX
SHR R10D,0x9
ADD SIL,byte ptr [RDI + RAX*0x1 + -0x10]
CMP EDX,0x200
MOV R8D,0x1
CMOVNC R8D,R10D
CMP R8W,CX
JNZ 0x0015047e
AND ECX,R9D
MOV R9D,ECX
SHL R9D,0x9
CMP R9D,EDX
JNC 0x0015047e
LEA RDX,[RDI + RAX*0x1]
ADD RDX,-0x10
MOV CL,byte ptr [RDX + RCX*0x1]
MOV byte ptr [RDI + R9*0x1],CL
LAB_0015047e:
CMP R8W,0xf
JA 0x001504b1
PUSH RBP
MOV RBP,RSP
ADD RAX,RDI
MOVZX EDX,R8W
LEA RCX,[RDX + -0x10]
SHL EDX,0x9
ADD RDX,RDI
LAB_0015049a:
MOV DIL,byte ptr [RDX]
MOV byte ptr [RAX + RCX*0x1],DIL
MOV byte ptr [RDX],SIL
ADD RDX,0x200
INC RCX
JNZ 0x0015049a
POP RBP
LAB_001504b1:
RET
|
void translog_put_sector_protection(long param_1,char param_2,uint param_3)
{
char cVar1;
ulong uVar2;
uint uVar3;
long lVar4;
char *pcVar5;
uint uVar6;
uint uVar7;
uVar2 = (ulong)DAT_00500a94;
param_3 = param_3 & 0xffff;
uVar3 = param_3 + 0x1ffffff >> 9;
cVar1 = *(char *)(param_1 + -0x10 + uVar2);
uVar6 = 1;
if (0x1ff < param_3) {
uVar6 = param_3 >> 9;
}
if ((ushort)uVar6 == (ushort)uVar3) {
uVar3 = uVar3 & 0xffff;
uVar7 = uVar3 << 9;
if (uVar7 < param_3) {
*(int1 *)(param_1 + (ulong)uVar7) =
*(int1 *)(param_1 + uVar2 + -0x10 + (ulong)uVar3);
}
}
if ((ushort)uVar6 < 0x10) {
lVar4 = (ulong)uVar6 - 0x10;
pcVar5 = (char *)((ulong)(uVar6 << 9) + param_1);
do {
*(char *)(uVar2 + param_1 + lVar4) = *pcVar5;
*pcVar5 = param_2 + cVar1;
pcVar5 = pcVar5 + 0x200;
lVar4 = lVar4 + 1;
} while (lVar4 != 0);
}
return;
}
| |
21,437 | SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int) | 11AgReS1SoR11[P]Graph/Common/SemanticAnalyzer/src/SemanticAnalyzer.hpp | SemanticError(const std::string& message, int statementNumber)
: std::runtime_error("Ошибка: " + message + " Statement " + std::to_string(statementNumber)){} | O0 | cpp | SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int):
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0xb8(%rbp)
movq -0x10(%rbp), %rdx
leaq 0x139fd(%rip), %rsi # 0x4d519
leaq -0x78(%rbp), %rdi
movq %rdi, -0xb0(%rbp)
callq 0x2ee40
movq -0xb0(%rbp), %rsi
leaq 0x139ee(%rip), %rdx # 0x4d528
leaq -0x58(%rbp), %rdi
callq 0x2d6e0
jmp 0x39b45
movl -0x14(%rbp), %esi
leaq -0xa8(%rbp), %rdi
callq 0x2fc40
jmp 0x39b56
leaq -0x38(%rbp), %rdi
leaq -0x58(%rbp), %rsi
leaq -0xa8(%rbp), %rdx
callq 0x2ec20
jmp 0x39b6c
movq -0xb8(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x2fae0
jmp 0x39b7e
leaq -0x38(%rbp), %rdi
callq 0x2e520
leaq -0xa8(%rbp), %rdi
callq 0x2e520
leaq -0x58(%rbp), %rdi
callq 0x2e520
leaq -0x78(%rbp), %rdi
callq 0x2e520
movq -0xb8(%rbp), %rax
movq 0x213ad(%rip), %rcx # 0x5af60
addq $0x10, %rcx
movq %rcx, (%rax)
addq $0xc0, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x80(%rbp)
movl %eax, -0x84(%rbp)
jmp 0x39c23
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x80(%rbp)
movl %eax, -0x84(%rbp)
jmp 0x39c1a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x80(%rbp)
movl %eax, -0x84(%rbp)
jmp 0x39c0e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x80(%rbp)
movl %eax, -0x84(%rbp)
leaq -0x38(%rbp), %rdi
callq 0x2e520
leaq -0xa8(%rbp), %rdi
callq 0x2e520
leaq -0x58(%rbp), %rdi
callq 0x2e520
leaq -0x78(%rbp), %rdi
callq 0x2e520
movq -0x80(%rbp), %rdi
callq 0x30ed0
nopw %cs:(%rax,%rax)
nop
| _ZN16SEMANTICANALYZER13SemanticErrorC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi:
push rbp
mov rbp, rsp
sub rsp, 0C0h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
mov rax, [rbp+var_8]
mov [rbp+var_B8], rax
mov rdx, [rbp+var_10]
lea rsi, unk_4D519
lea rdi, [rbp+var_78]
mov [rbp+var_B0], rdi
call __ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
mov rsi, [rbp+var_B0]
lea rdx, aStatement; " Statement "
lea rdi, [rbp+var_58]
call __ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_PKS5_; std::operator+<char>(std::string&&,char const*)
jmp short $+2
loc_39B45:
mov esi, [rbp+var_14]; int
lea rdi, [rbp+var_A8]; this
call __ZNSt7__cxx119to_stringEi; std::to_string(int)
jmp short $+2
loc_39B56:
lea rdi, [rbp+var_38]
lea rsi, [rbp+var_58]
lea rdx, [rbp+var_A8]
call __ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_S9_; std::operator+<char>(std::string&&,std::string&)
jmp short $+2
loc_39B6C:
mov rdi, [rbp+var_B8]
lea rsi, [rbp+var_38]
call __ZNSt13runtime_errorC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
jmp short $+2
loc_39B7E:
lea rdi, [rbp+var_38]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rbp+var_A8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rbp+var_58]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rbp+var_78]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rax, [rbp+var_B8]
mov rcx, cs:_ZTVN16SEMANTICANALYZER13SemanticErrorE_ptr
add rcx, 10h
mov [rax], rcx
add rsp, 0C0h
pop rbp
retn
mov rcx, rax
mov eax, edx
mov [rbp+var_80], rcx
mov [rbp+var_84], eax
jmp short loc_39C23
mov rcx, rax
mov eax, edx
mov [rbp+var_80], rcx
mov [rbp+var_84], eax
jmp short loc_39C1A
mov rcx, rax
mov eax, edx
mov [rbp+var_80], rcx
mov [rbp+var_84], eax
jmp short loc_39C0E
mov rcx, rax
mov eax, edx
mov [rbp+var_80], rcx
mov [rbp+var_84], eax
lea rdi, [rbp+var_38]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_39C0E:
lea rdi, [rbp+var_A8]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_39C1A:
lea rdi, [rbp+var_58]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_39C23:
lea rdi, [rbp+var_78]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rdi, [rbp+var_80]
call __Unwind_Resume
| _QWORD * SEMANTICANALYZER::SemanticError::SemanticError(_QWORD *a1, long long a2, int a3)
{
_QWORD *result; // rax
_BYTE v4[36]; // [rsp+18h] [rbp-A8h] BYREF
_BYTE v5[32]; // [rsp+48h] [rbp-78h] BYREF
_BYTE v6[32]; // [rsp+68h] [rbp-58h] BYREF
_BYTE v7[36]; // [rsp+88h] [rbp-38h] BYREF
int v8; // [rsp+ACh] [rbp-14h]
long long v9; // [rsp+B0h] [rbp-10h]
_QWORD *v10; // [rsp+B8h] [rbp-8h]
v10 = a1;
v9 = a2;
v8 = a3;
std::operator+<char>(v5, &unk_4D519, a2);
std::operator+<char>(v6, v5, " Statement ");
std::to_string((std::__cxx11 *)v4, v8);
std::operator+<char>(v7, v6, v4);
std::runtime_error::runtime_error(a1, v7);
std::string::~string(v7);
std::string::~string(v4);
std::string::~string(v6);
std::string::~string(v5);
result = a1;
*a1 = &`vtable for'SEMANTICANALYZER::SemanticError + 2;
return result;
}
| SemanticError:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xc0
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0xb8],RAX
MOV RDX,qword ptr [RBP + -0x10]
LEA RSI,[0x14d519]
LEA RDI,[RBP + -0x78]
MOV qword ptr [RBP + -0xb0],RDI
CALL 0x0012ee40
MOV RSI,qword ptr [RBP + -0xb0]
LAB_00139b33:
LEA RDX,[0x14d528]
LEA RDI,[RBP + -0x58]
CALL 0x0012d6e0
JMP 0x00139b45
LAB_00139b45:
MOV ESI,dword ptr [RBP + -0x14]
LAB_00139b48:
LEA RDI,[RBP + -0xa8]
CALL 0x0012fc40
JMP 0x00139b56
LAB_00139b56:
LEA RDI,[RBP + -0x38]
LEA RSI,[RBP + -0x58]
LEA RDX,[RBP + -0xa8]
CALL 0x0012ec20
JMP 0x00139b6c
LAB_00139b6c:
MOV RDI,qword ptr [RBP + -0xb8]
LEA RSI,[RBP + -0x38]
CALL 0x0012fae0
LAB_00139b7c:
JMP 0x00139b7e
LAB_00139b7e:
LEA RDI,[RBP + -0x38]
CALL 0x0012e520
LEA RDI,[RBP + -0xa8]
CALL 0x0012e520
LEA RDI,[RBP + -0x58]
CALL 0x0012e520
LEA RDI,[RBP + -0x78]
CALL 0x0012e520
MOV RAX,qword ptr [RBP + -0xb8]
MOV RCX,qword ptr [0x0015af60]
ADD RCX,0x10
MOV qword ptr [RAX],RCX
ADD RSP,0xc0
POP RBP
RET
|
/* SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::string const&, int) */
void __thiscall
SEMANTICANALYZER::SemanticError::SemanticError(SemanticError *this,string *param_1,int param_2)
{
__cxx11 local_b0 [48];
string local_80 [32];
string local_60 [32];
string local_40 [36];
int local_1c;
string *local_18;
SemanticError *local_10;
local_1c = param_2;
local_18 = param_1;
local_10 = this;
std::operator+((char *)local_80,(string *)&DAT_0014d519);
/* try { // try from 00139b33 to 00139b42 has its CatchHandler @ 00139bc3 */
std::operator+(local_60,(char *)local_80);
/* try { // try from 00139b48 to 00139b53 has its CatchHandler @ 00139bd4 */
std::__cxx11::to_string(local_b0,local_1c);
/* try { // try from 00139b56 to 00139b69 has its CatchHandler @ 00139be5 */
std::operator+(local_40,local_60);
/* try { // try from 00139b6c to 00139b7b has its CatchHandler @ 00139bf6 */
std::runtime_error::runtime_error((runtime_error *)this,local_40);
std::__cxx11::string::~string(local_40);
std::__cxx11::string::~string((string *)local_b0);
std::__cxx11::string::~string(local_60);
std::__cxx11::string::~string(local_80);
*(int **)this = PTR_vtable_0015af60 + 0x10;
return;
}
| |
21,438 | SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int) | 11AgReS1SoR11[P]Graph/Common/SemanticAnalyzer/src/SemanticAnalyzer.hpp | SemanticError(const std::string& message, int statementNumber)
: std::runtime_error("Ошибка: " + message + " Statement " + std::to_string(statementNumber)){} | O2 | cpp | SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x80, %rsp
movl %edx, %ebp
movq %rsi, %rdx
movq %rdi, %rbx
leaq 0x675f(%rip), %rsi # 0x1b523
leaq 0x60(%rsp), %r14
movq %r14, %rdi
callq 0x10970
leaq 0x675a(%rip), %rdx # 0x1b532
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
callq 0x10270
movq %rsp, %rdi
movl %ebp, %esi
callq 0x10de0
leaq 0x40(%rsp), %rdi
leaq 0x20(%rsp), %rsi
movq %rsp, %rdx
callq 0x108b0
leaq 0x40(%rsp), %rsi
movq %rbx, %rdi
callq 0x10d30
leaq 0x40(%rsp), %rdi
callq 0x104a0
movq %rsp, %rdi
callq 0x104a0
leaq 0x20(%rsp), %rdi
callq 0x104a0
leaq 0x60(%rsp), %rdi
callq 0x104a0
movq 0xd11d(%rip), %rax # 0x21f58
addq $0x10, %rax
movq %rax, (%rbx)
addq $0x80, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
leaq 0x40(%rsp), %rdi
callq 0x104a0
jmp 0x14e60
movq %rax, %rbx
movq %rsp, %rdi
callq 0x104a0
jmp 0x14e6d
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x104a0
jmp 0x14e7c
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0x104a0
movq %rbx, %rdi
callq 0x11420
| _ZN16SEMANTICANALYZER13SemanticErrorC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi:
push rbp
push r14
push rbx
sub rsp, 80h
mov ebp, edx
mov rdx, rsi
mov rbx, rdi
lea rsi, unk_1B523
lea r14, [rsp+98h+var_38]
mov rdi, r14
call __ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
lea rdx, aStatement; " Statement "
lea rdi, [rsp+98h+var_78]
mov rsi, r14
call __ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_PKS5_; std::operator+<char>(std::string&&,char const*)
mov rdi, rsp; this
mov esi, ebp; int
call __ZNSt7__cxx119to_stringEi; std::to_string(int)
lea rdi, [rsp+98h+var_58]
lea rsi, [rsp+98h+var_78]
mov rdx, rsp
call __ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_S9_; std::operator+<char>(std::string&&,std::string&)
lea rsi, [rsp+98h+var_58]
mov rdi, rbx
call __ZNSt13runtime_errorC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
lea rdi, [rsp+98h+var_58]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, rsp
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+98h+var_78]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+98h+var_38]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rax, cs:_ZTVN16SEMANTICANALYZER13SemanticErrorE_ptr
add rax, 10h
mov [rbx], rax
add rsp, 80h
pop rbx
pop r14
pop rbp
retn
mov rbx, rax
lea rdi, [rsp+arg_38]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_14E60
mov rbx, rax
loc_14E60:
mov rdi, rsp
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_14E6D
mov rbx, rax
loc_14E6D:
lea rdi, [rsp+arg_18]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_14E7C
mov rbx, rax
loc_14E7C:
lea rdi, [rsp+arg_58]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, rbx
call __Unwind_Resume
| long long * SEMANTICANALYZER::SemanticError::SemanticError(_QWORD *a1, long long a2, int a3)
{
long long *result; // rax
_BYTE v5[32]; // [rsp+0h] [rbp-98h] BYREF
_BYTE v6[32]; // [rsp+20h] [rbp-78h] BYREF
_BYTE v7[32]; // [rsp+40h] [rbp-58h] BYREF
_BYTE v8[56]; // [rsp+60h] [rbp-38h] BYREF
std::operator+<char>(v8, &unk_1B523, a2);
std::operator+<char>(v6, v8, " Statement ");
std::to_string((std::__cxx11 *)v5, a3);
std::operator+<char>(v7, v6, v5);
std::runtime_error::runtime_error(a1, v7);
std::string::~string(v7);
std::string::~string(v5);
std::string::~string(v6);
std::string::~string(v8);
result = &`vtable for'SEMANTICANALYZER::SemanticError + 2;
*a1 = &`vtable for'SEMANTICANALYZER::SemanticError + 2;
return result;
}
| SemanticError:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x80
MOV EBP,EDX
MOV RDX,RSI
MOV RBX,RDI
LEA RSI,[0x11b523]
LEA R14,[RSP + 0x60]
MOV RDI,R14
CALL 0x00110970
LAB_00114dd1:
LEA RDX,[0x11b532]
LEA RDI,[RSP + 0x20]
MOV RSI,R14
CALL 0x00110270
LAB_00114de5:
MOV RDI,RSP
MOV ESI,EBP
CALL 0x00110de0
LAB_00114def:
LEA RDI,[RSP + 0x40]
LEA RSI,[RSP + 0x20]
MOV RDX,RSP
CALL 0x001108b0
LAB_00114e01:
LEA RSI,[RSP + 0x40]
MOV RDI,RBX
CALL 0x00110d30
LAB_00114e0e:
LEA RDI,[RSP + 0x40]
CALL 0x001104a0
MOV RDI,RSP
CALL 0x001104a0
LEA RDI,[RSP + 0x20]
CALL 0x001104a0
LEA RDI,[RSP + 0x60]
CALL 0x001104a0
MOV RAX,qword ptr [0x00121f58]
ADD RAX,0x10
MOV qword ptr [RBX],RAX
ADD RSP,0x80
POP RBX
POP R14
POP RBP
RET
|
/* SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::string const&, int) */
void __thiscall
SEMANTICANALYZER::SemanticError::SemanticError(SemanticError *this,string *param_1,int param_2)
{
__cxx11 a_Stack_98 [32];
string local_78 [32];
string local_58 [32];
string local_38 [32];
std::operator+((char *)local_38,(string *)&DAT_0011b523);
/* try { // try from 00114dd1 to 00114de4 has its CatchHandler @ 00114e79 */
std::operator+(local_78,(char *)local_38);
/* try { // try from 00114de5 to 00114dee has its CatchHandler @ 00114e6a */
std::__cxx11::to_string(a_Stack_98,param_2);
/* try { // try from 00114def to 00114e00 has its CatchHandler @ 00114e5d */
std::operator+(local_58,local_78);
/* try { // try from 00114e01 to 00114e0d has its CatchHandler @ 00114e4e */
std::runtime_error::runtime_error((runtime_error *)this,local_58);
std::__cxx11::string::~string(local_58);
std::__cxx11::string::~string((string *)a_Stack_98);
std::__cxx11::string::~string(local_78);
std::__cxx11::string::~string(local_38);
*(int **)this = PTR_vtable_00121f58 + 0x10;
return;
}
| |
21,439 | SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int) | 11AgReS1SoR11[P]Graph/Common/SemanticAnalyzer/src/SemanticAnalyzer.hpp | SemanticError(const std::string& message, int statementNumber)
: std::runtime_error("Ошибка: " + message + " Statement " + std::to_string(statementNumber)){} | O3 | cpp | SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movl %edx, %r14d
movq %rsi, %rdx
movq %rdi, %rbx
leaq 0x69d0(%rip), %rsi # 0x17529
leaq 0x68(%rsp), %r15
movq %r15, %rdi
callq 0xb5e0
leaq 0x69cb(%rip), %rsi # 0x17538
movq %r15, %rdi
callq 0xbd40
leaq 0x38(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x10b9d
movq %rdx, 0x28(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x38(%rsp)
jmp 0x10ba5
movups (%rcx), %xmm0
movups %xmm0, (%r12)
movq 0x8(%rax), %rdx
movq %rdx, 0x30(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movl %r14d, %ebp
negl %ebp
cmovsl %r14d, %ebp
movl $0x1, %r15d
cmpl $0xa, %ebp
jb 0x10c1a
movl $0x4, %r15d
movl $0xd1b71759, %eax # imm = 0xD1B71759
movl %ebp, %ecx
cmpl $0x63, %ecx
jbe 0x10c11
cmpl $0x3e7, %ecx # imm = 0x3E7
jbe 0x10c17
cmpl $0x2710, %ecx # imm = 0x2710
jb 0x10c1a
movl %ecx, %edx
imulq %rax, %rdx
shrq $0x2d, %rdx
addl $0x4, %r15d
cmpl $0x1869f, %ecx # imm = 0x1869F
movl %edx, %ecx
ja 0x10bde
addl $-0x3, %r15d
jmp 0x10c1a
addl $-0x2, %r15d
jmp 0x10c1a
decl %r15d
shrl $0x1f, %r14d
leal (%r15,%r14), %esi
leaq 0x58(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x48(%rsp), %rdi
movl $0x2d, %edx
callq 0xb810
movl %r14d, %edi
addq 0x48(%rsp), %rdi
movl %r15d, %esi
movl %ebp, %edx
callq 0xb920
movq 0x28(%rsp), %rcx
movq 0x30(%rsp), %r8
movq 0x50(%rsp), %rdx
leaq (%rdx,%r8), %rax
movl $0xf, %edi
cmpq %r12, %rcx
je 0x10c6e
movq 0x38(%rsp), %rdi
movq 0x48(%rsp), %rsi
cmpq %rdi, %rax
jbe 0x10c8c
movl $0xf, %edi
cmpq %r13, %rsi
je 0x10c87
movq 0x58(%rsp), %rdi
cmpq %rdi, %rax
jbe 0x10c98
leaq 0x28(%rsp), %rdi
callq 0xb240
jmp 0x10ca6
leaq 0x48(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0xb780
leaq 0x18(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x10cca
movq %rsi, 0x8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x18(%rsp)
jmp 0x10cd0
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x10(%rsp)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0xb870
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x10d15
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xb6a0
movq 0x48(%rsp), %rdi
cmpq %r13, %rdi
je 0x10d2c
movq 0x58(%rsp), %rsi
incq %rsi
callq 0xb6a0
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0x10d43
movq 0x38(%rsp), %rsi
incq %rsi
callq 0xb6a0
leaq 0x78(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x10d5e
movq 0x78(%rsp), %rsi
incq %rsi
callq 0xb6a0
movq 0xc1f3(%rip), %rax # 0x1cf58
addq $0x10, %rax
movq %rax, (%rbx)
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x10da1
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xb6a0
jmp 0x10da1
movq %rax, %rbx
movq 0x48(%rsp), %rdi
cmpq %r13, %rdi
je 0x10dbd
movq 0x58(%rsp), %rsi
incq %rsi
callq 0xb6a0
jmp 0x10dbd
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0x10dd9
movq 0x38(%rsp), %rsi
incq %rsi
callq 0xb6a0
jmp 0x10dd9
movq %rax, %rbx
leaq 0x78(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x10df4
movq 0x78(%rsp), %rsi
incq %rsi
callq 0xb6a0
movq %rbx, %rdi
callq 0xbc50
| _ZN16SEMANTICANALYZER13SemanticErrorC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 88h
mov r14d, edx
mov rdx, rsi
mov rbx, rdi
lea rsi, unk_17529
lea r15, [rsp+0B8h+var_50]
mov rdi, r15
call __ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
lea rsi, aStatement; " Statement "
mov rdi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea r12, [rsp+0B8h+var_80]
mov [r12-10h], r12
mov rdx, [rax]
mov rcx, rax
add rcx, 10h
cmp rdx, rcx
jz short loc_10B9D
mov [rsp+0B8h+var_90], rdx
mov rdx, [rcx]
mov [rsp+0B8h+var_80], rdx
jmp short loc_10BA5
loc_10B9D:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [r12], xmm0
loc_10BA5:
mov rdx, [rax+8]
mov [rsp+0B8h+var_88], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
mov ebp, r14d
neg ebp
cmovs ebp, r14d
mov r15d, 1
cmp ebp, 0Ah
jb short loc_10C1A
mov r15d, 4
mov eax, 0D1B71759h
mov ecx, ebp
loc_10BDE:
cmp ecx, 63h ; 'c'
jbe short loc_10C11
cmp ecx, 3E7h
jbe short loc_10C17
cmp ecx, 2710h
jb short loc_10C1A
mov edx, ecx
imul rdx, rax
shr rdx, 2Dh
add r15d, 4
cmp ecx, offset unk_1869F
mov ecx, edx
ja short loc_10BDE
add r15d, 0FFFFFFFDh
jmp short loc_10C1A
loc_10C11:
add r15d, 0FFFFFFFEh
jmp short loc_10C1A
loc_10C17:
dec r15d
loc_10C1A:
shr r14d, 1Fh
lea esi, [r15+r14]
lea r13, [rsp+0B8h+var_60]
mov [r13-10h], r13
lea rdi, [rsp+0B8h+var_70]
mov edx, 2Dh ; '-'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructEmc; std::string::_M_construct(ulong,char)
mov edi, r14d
add rdi, [rsp+0B8h+var_70]
mov esi, r15d
mov edx, ebp
call __ZNSt8__detail18__to_chars_10_implIjEEvPcjT_; std::__detail::__to_chars_10_impl<uint>(char *,uint,uint)
mov rcx, [rsp+0B8h+var_90]
mov r8, [rsp+0B8h+var_88]
mov rdx, [rsp+0B8h+var_68]
lea rax, [rdx+r8]
mov edi, 0Fh
cmp rcx, r12
jz short loc_10C6E
mov rdi, [rsp+0B8h+var_80]
loc_10C6E:
mov rsi, [rsp+0B8h+var_70]
cmp rax, rdi
jbe short loc_10C8C
mov edi, 0Fh
cmp rsi, r13
jz short loc_10C87
mov rdi, [rsp+0B8h+var_60]
loc_10C87:
cmp rax, rdi
jbe short loc_10C98
loc_10C8C:
lea rdi, [rsp+0B8h+var_90]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
jmp short loc_10CA6
loc_10C98:
lea rdi, [rsp+0B8h+var_70]
xor esi, esi
xor edx, edx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong)
loc_10CA6:
lea rdx, [rsp+0B8h+var_A0]
mov [rdx-10h], rdx
mov rsi, [rax]
lea rcx, [rax+10h]
cmp rsi, rcx
jz short loc_10CCA
mov [rsp+0B8h+var_B0], rsi
mov rdx, [rcx]
mov [rsp+0B8h+var_A0], rdx
jmp short loc_10CD0
loc_10CCA:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [rdx], xmm0
loc_10CD0:
mov rdx, rax
add rdx, 8
mov rsi, [rax+8]
mov [rsp+0B8h+var_A8], rsi
mov [rax], rcx
mov qword ptr [rdx], 0
mov byte ptr [rcx], 0
lea rsi, [rsp+0B8h+var_B0]
mov rdi, rbx
call __ZNSt13runtime_errorC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
lea rax, [rsp+0B8h+var_A0]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_10D15
mov rsi, [rsp+0B8h+var_A0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_10D15:
mov rdi, [rsp+0B8h+var_70]; void *
cmp rdi, r13
jz short loc_10D2C
mov rsi, [rsp+0B8h+var_60]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_10D2C:
mov rdi, [rsp+0B8h+var_90]; void *
cmp rdi, r12
jz short loc_10D43
mov rsi, [rsp+0B8h+var_80]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_10D43:
lea rax, [rsp+0B8h+var_40]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_10D5E
mov rsi, [rsp+0B8h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_10D5E:
mov rax, cs:_ZTVN16SEMANTICANALYZER13SemanticErrorE_ptr
add rax, 10h
mov [rbx], rax
add rsp, 88h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_10DA1
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_10DA1
mov rbx, rax
loc_10DA1:
mov rdi, [rsp+arg_40]; void *
cmp rdi, r13
jz short loc_10DBD
mov rsi, [rsp+arg_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_10DBD
mov rbx, rax
loc_10DBD:
mov rdi, [rsp+arg_20]; void *
cmp rdi, r12
jz short loc_10DD9
mov rsi, [rsp+arg_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_10DD9
mov rbx, rax
loc_10DD9:
lea rax, [rsp+arg_70]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_10DF4
mov rsi, [rsp+arg_70]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_10DF4:
mov rdi, rbx
call __Unwind_Resume
| long long * SEMANTICANALYZER::SemanticError::SemanticError(_QWORD *a1, long long a2, int a3)
{
long long v5; // rax
__int128 *v6; // rcx
unsigned int v7; // ebp
unsigned int v8; // r15d
unsigned int v9; // ecx
bool v10; // cc
unsigned int v11; // r14d
unsigned long long v12; // rax
unsigned long long v13; // rdi
unsigned long long v14; // rdi
void **v15; // rax
__int128 *v16; // rcx
long long *result; // rax
void *v18[2]; // [rsp+8h] [rbp-B0h] BYREF
__int128 v19; // [rsp+18h] [rbp-A0h] BYREF
void *v20; // [rsp+28h] [rbp-90h] BYREF
long long v21; // [rsp+30h] [rbp-88h]
__int128 v22; // [rsp+38h] [rbp-80h] BYREF
void *v23; // [rsp+48h] [rbp-70h] BYREF
long long v24; // [rsp+50h] [rbp-68h]
_QWORD v25[2]; // [rsp+58h] [rbp-60h] BYREF
void *v26[2]; // [rsp+68h] [rbp-50h] BYREF
long long v27; // [rsp+78h] [rbp-40h] BYREF
std::operator+<char>(v26, &unk_17529, a2);
v5 = std::string::append(v26, " Statement ");
v20 = &v22;
v6 = (__int128 *)(v5 + 16);
if ( *(_QWORD *)v5 == v5 + 16 )
{
v22 = *v6;
}
else
{
v20 = *(void **)v5;
*(_QWORD *)&v22 = *(_QWORD *)v6;
}
v21 = *(_QWORD *)(v5 + 8);
*(_QWORD *)v5 = v6;
*(_QWORD *)(v5 + 8) = 0LL;
*(_BYTE *)(v5 + 16) = 0;
v7 = -a3;
if ( a3 > 0 )
v7 = a3;
v8 = 1;
if ( v7 >= 0xA )
{
v8 = 4;
v9 = v7;
while ( 1 )
{
if ( v9 <= 0x63 )
{
v8 -= 2;
goto LABEL_15;
}
if ( v9 <= 0x3E7 )
break;
if ( v9 < 0x2710 )
goto LABEL_15;
v8 += 4;
v10 = v9 <= (unsigned int)&unk_1869F;
v9 /= 0x2710u;
if ( v10 )
{
v8 -= 3;
goto LABEL_15;
}
}
--v8;
}
LABEL_15:
v11 = (unsigned int)a3 >> 31;
v23 = v25;
std::string::_M_construct(&v23, v8 + v11, 45LL);
std::__detail::__to_chars_10_impl<unsigned int>((char *)v23 + v11, v8, v7);
v12 = v24 + v21;
v13 = 15LL;
if ( v20 != &v22 )
v13 = v22;
if ( v12 <= v13 )
goto LABEL_21;
v14 = 15LL;
if ( v23 != v25 )
v14 = v25[0];
if ( v12 <= v14 )
v15 = (void **)std::string::replace(&v23, 0LL, 0LL);
else
LABEL_21:
v15 = (void **)std::string::_M_append(&v20, v23, v24);
v18[0] = &v19;
v16 = (__int128 *)(v15 + 2);
if ( *v15 == v15 + 2 )
{
v19 = *v16;
}
else
{
v18[0] = *v15;
*(_QWORD *)&v19 = *(_QWORD *)v16;
}
v18[1] = v15[1];
*v15 = v16;
v15[1] = 0LL;
*(_BYTE *)v16 = 0;
std::runtime_error::runtime_error(a1, v18);
if ( v18[0] != &v19 )
operator delete(v18[0], v19 + 1);
if ( v23 != v25 )
operator delete(v23, v25[0] + 1LL);
if ( v20 != &v22 )
operator delete(v20, v22 + 1);
if ( v26[0] != &v27 )
operator delete(v26[0], v27 + 1);
result = &`vtable for'SEMANTICANALYZER::SemanticError + 2;
*a1 = &`vtable for'SEMANTICANALYZER::SemanticError + 2;
return result;
}
| SemanticError:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x88
MOV R14D,EDX
MOV RDX,RSI
MOV RBX,RDI
LEA RSI,[0x117529]
LEA R15,[RSP + 0x68]
MOV RDI,R15
CALL 0x0010b5e0
LAB_00110b66:
LEA RSI,[0x117538]
MOV RDI,R15
CALL 0x0010bd40
LEA R12,[RSP + 0x38]
MOV qword ptr [R12 + -0x10],R12
MOV RDX,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RDX,RCX
JZ 0x00110b9d
MOV qword ptr [RSP + 0x28],RDX
MOV RDX,qword ptr [RCX]
MOV qword ptr [RSP + 0x38],RDX
JMP 0x00110ba5
LAB_00110b9d:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [R12],XMM0
LAB_00110ba5:
MOV RDX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x30],RDX
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV byte ptr [RAX + 0x10],0x0
MOV EBP,R14D
NEG EBP
CMOVS EBP,R14D
MOV R15D,0x1
CMP EBP,0xa
JC 0x00110c1a
MOV R15D,0x4
MOV EAX,0xd1b71759
MOV ECX,EBP
LAB_00110bde:
CMP ECX,0x63
JBE 0x00110c11
CMP ECX,0x3e7
JBE 0x00110c17
CMP ECX,0x2710
JC 0x00110c1a
MOV EDX,ECX
IMUL RDX,RAX
SHR RDX,0x2d
ADD R15D,0x4
CMP ECX,0x1869f
MOV ECX,EDX
JA 0x00110bde
ADD R15D,-0x3
JMP 0x00110c1a
LAB_00110c11:
ADD R15D,-0x2
JMP 0x00110c1a
LAB_00110c17:
DEC R15D
LAB_00110c1a:
SHR R14D,0x1f
LEA ESI,[R15 + R14*0x1]
LEA R13,[RSP + 0x58]
MOV qword ptr [R13 + -0x10],R13
LAB_00110c2b:
LEA RDI,[RSP + 0x48]
MOV EDX,0x2d
CALL 0x0010b810
MOV EDI,R14D
ADD RDI,qword ptr [RSP + 0x48]
MOV ESI,R15D
MOV EDX,EBP
CALL 0x0010b920
MOV RCX,qword ptr [RSP + 0x28]
MOV R8,qword ptr [RSP + 0x30]
MOV RDX,qword ptr [RSP + 0x50]
LEA RAX,[RDX + R8*0x1]
MOV EDI,0xf
CMP RCX,R12
JZ 0x00110c6e
MOV RDI,qword ptr [RSP + 0x38]
LAB_00110c6e:
MOV RSI,qword ptr [RSP + 0x48]
CMP RAX,RDI
JBE 0x00110c8c
MOV EDI,0xf
CMP RSI,R13
JZ 0x00110c87
MOV RDI,qword ptr [RSP + 0x58]
LAB_00110c87:
CMP RAX,RDI
JBE 0x00110c98
LAB_00110c8c:
LEA RDI,[RSP + 0x28]
CALL 0x0010b240
JMP 0x00110ca6
LAB_00110c98:
LEA RDI,[RSP + 0x48]
XOR ESI,ESI
XOR EDX,EDX
CALL 0x0010b780
LAB_00110ca6:
LEA RDX,[RSP + 0x18]
MOV qword ptr [RDX + -0x10],RDX
MOV RSI,qword ptr [RAX]
LEA RCX,[RAX + 0x10]
CMP RSI,RCX
JZ 0x00110cca
MOV qword ptr [RSP + 0x8],RSI
MOV RDX,qword ptr [RCX]
MOV qword ptr [RSP + 0x18],RDX
JMP 0x00110cd0
LAB_00110cca:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [RDX],XMM0
LAB_00110cd0:
MOV RDX,RAX
ADD RDX,0x8
MOV RSI,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x10],RSI
MOV qword ptr [RAX],RCX
MOV qword ptr [RDX],0x0
MOV byte ptr [RCX],0x0
LAB_00110ced:
LEA RSI,[RSP + 0x8]
MOV RDI,RBX
CALL 0x0010b870
LAB_00110cfa:
LEA RAX,[RSP + 0x18]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x00110d15
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0010b6a0
LAB_00110d15:
MOV RDI,qword ptr [RSP + 0x48]
CMP RDI,R13
JZ 0x00110d2c
MOV RSI,qword ptr [RSP + 0x58]
INC RSI
CALL 0x0010b6a0
LAB_00110d2c:
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R12
JZ 0x00110d43
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x0010b6a0
LAB_00110d43:
LEA RAX,[RSP + 0x78]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x00110d5e
MOV RSI,qword ptr [RSP + 0x78]
INC RSI
CALL 0x0010b6a0
LAB_00110d5e:
MOV RAX,qword ptr [0x0011cf58]
ADD RAX,0x10
MOV qword ptr [RBX],RAX
ADD RSP,0x88
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* SEMANTICANALYZER::SemanticError::SemanticError(std::__cxx11::string const&, int) */
void __thiscall
SEMANTICANALYZER::SemanticError::SemanticError(SemanticError *this,string *param_1,int param_2)
{
uint uVar1;
long *plVar2;
int8 *puVar3;
uint uVar4;
ulong *puVar5;
ulong uVar6;
uint uVar7;
uint uVar8;
long *local_b0;
int8 local_a8;
long local_a0;
int8 uStack_98;
ulong *local_90;
long local_88;
ulong local_80;
long lStack_78;
ulong *local_70;
long local_68;
ulong local_60 [2];
long *local_50 [2];
long local_40 [2];
std::operator+((char *)local_50,(string *)&DAT_00117529);
/* try { // try from 00110b66 to 00110b74 has its CatchHandler @ 00110dd6 */
plVar2 = (long *)std::__cxx11::string::append((char *)local_50);
puVar5 = (ulong *)(plVar2 + 2);
if ((ulong *)*plVar2 == puVar5) {
local_80 = *puVar5;
lStack_78 = plVar2[3];
local_90 = &local_80;
}
else {
local_80 = *puVar5;
local_90 = (ulong *)*plVar2;
}
local_88 = plVar2[1];
*plVar2 = (long)puVar5;
plVar2[1] = 0;
*(int1 *)(plVar2 + 2) = 0;
uVar7 = -param_2;
if (0 < param_2) {
uVar7 = param_2;
}
uVar8 = 1;
if (9 < uVar7) {
uVar6 = (ulong)uVar7;
uVar1 = 4;
do {
uVar8 = uVar1;
uVar4 = (uint)uVar6;
if (uVar4 < 100) {
uVar8 = uVar8 - 2;
goto LAB_00110c1a;
}
if (uVar4 < 1000) {
uVar8 = uVar8 - 1;
goto LAB_00110c1a;
}
if (uVar4 < 10000) goto LAB_00110c1a;
uVar6 = uVar6 / 10000;
uVar1 = uVar8 + 4;
} while (99999 < uVar4);
uVar8 = uVar8 + 1;
}
LAB_00110c1a:
/* try { // try from 00110c2b to 00110c39 has its CatchHandler @ 00110dba */
local_70 = local_60;
std::__cxx11::string::_M_construct((ulong)&local_70,(char)uVar8 - (char)(param_2 >> 0x1f));
std::__detail::__to_chars_10_impl<unsigned_int>
((char *)((ulong)((uint)param_2 >> 0x1f) + (long)local_70),uVar8,uVar7);
uVar6 = 0xf;
if (local_90 != &local_80) {
uVar6 = local_80;
}
if (uVar6 < (ulong)(local_68 + local_88)) {
uVar6 = 0xf;
if (local_70 != local_60) {
uVar6 = local_60[0];
}
if ((ulong)(local_68 + local_88) <= uVar6) {
puVar3 = (int8 *)
std::__cxx11::string::replace((ulong)&local_70,0,(char *)0x0,(ulong)local_90);
goto LAB_00110ca6;
}
}
/* try { // try from 00110c8c to 00110ca5 has its CatchHandler @ 00110d9e */
puVar3 = (int8 *)std::__cxx11::string::_M_append((char *)&local_90,(ulong)local_70);
LAB_00110ca6:
local_b0 = &local_a0;
plVar2 = puVar3 + 2;
if ((long *)*puVar3 == plVar2) {
local_a0 = *plVar2;
uStack_98 = puVar3[3];
}
else {
local_a0 = *plVar2;
local_b0 = (long *)*puVar3;
}
local_a8 = puVar3[1];
*puVar3 = plVar2;
puVar3[1] = 0;
*(int1 *)plVar2 = 0;
/* try { // try from 00110ced to 00110cf9 has its CatchHandler @ 00110d7e */
std::runtime_error::runtime_error((runtime_error *)this,(string *)&local_b0);
if (local_b0 != &local_a0) {
operator_delete(local_b0,local_a0 + 1);
}
if (local_70 != local_60) {
operator_delete(local_70,local_60[0] + 1);
}
if (local_90 != &local_80) {
operator_delete(local_90,local_80 + 1);
}
if (local_50[0] != local_40) {
operator_delete(local_50[0],local_40[0] + 1);
}
*(int **)this = PTR_vtable_0011cf58 + 0x10;
return;
}
| |
21,440 | ps_fetch_int16 | eloqsql/libmariadb/libmariadb/ma_stmt_codec.c | static
void ps_fetch_int16(MYSQL_BIND *r_param, const MYSQL_FIELD * const field,
unsigned char **row)
{
switch (r_param->buffer_type) {
case MYSQL_TYPE_YEAR:
case MYSQL_TYPE_SHORT:
ps_fetch_from_1_to_8_bytes(r_param, field, row, 2);
break;
default:
{
short sval= sint2korr(*row);
longlong lval= field->flags & UNSIGNED_FLAG ? (longlong)(ushort) sval : (longlong)sval;
convert_from_long(r_param, field, lval, field->flags & UNSIGNED_FLAG);
(*row) += 2;
}
break;
}
} | O0 | c | ps_fetch_int16:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl 0x60(%rax), %eax
movl %eax, -0x2c(%rbp)
subl $0x2, %eax
je 0x36c9f
jmp 0x36c95
movl -0x2c(%rbp), %eax
subl $0xd, %eax
jne 0x36cb7
jmp 0x36c9f
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movl $0x2, %ecx
callq 0x35a00
jmp 0x36d2f
movq -0x18(%rbp), %rax
movq (%rax), %rax
movzbl (%rax), %eax
cwtl
movq -0x18(%rbp), %rcx
movq (%rcx), %rcx
movzbl 0x1(%rcx), %ecx
movswl %cx, %ecx
shll $0x8, %ecx
addl %ecx, %eax
movw %ax, -0x1a(%rbp)
movq -0x10(%rbp), %rax
movl 0x64(%rax), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0x36cf2
movzwl -0x1a(%rbp), %eax
movq %rax, -0x38(%rbp)
jmp 0x36cfb
movswq -0x1a(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x28(%rbp), %rdx
movq -0x10(%rbp), %rax
movl 0x64(%rax), %eax
andl $0x20, %eax
movsbl %al, %ecx
callq 0x37710
movq -0x18(%rbp), %rax
movq (%rax), %rcx
addq $0x2, %rcx
movq %rcx, (%rax)
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| ps_fetch_int16:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov rax, [rbp+var_8]
mov eax, [rax+60h]
mov [rbp+var_2C], eax
sub eax, 2
jz short loc_36C9F
jmp short $+2
loc_36C95:
mov eax, [rbp+var_2C]
sub eax, 0Dh
jnz short loc_36CB7
jmp short $+2
loc_36C9F:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov ecx, 2
call ps_fetch_from_1_to_8_bytes
jmp short loc_36D2F
loc_36CB7:
mov rax, [rbp+var_18]
mov rax, [rax]
movzx eax, byte ptr [rax]
cwde
mov rcx, [rbp+var_18]
mov rcx, [rcx]
movzx ecx, byte ptr [rcx+1]
movsx ecx, cx
shl ecx, 8
add eax, ecx
mov [rbp+var_1A], ax
mov rax, [rbp+var_10]
mov eax, [rax+64h]
and eax, 20h
cmp eax, 0
jz short loc_36CF2
movzx eax, [rbp+var_1A]
mov [rbp+var_38], rax
jmp short loc_36CFB
loc_36CF2:
movsx rax, [rbp+var_1A]
mov [rbp+var_38], rax
loc_36CFB:
mov rax, [rbp+var_38]
mov [rbp+var_28], rax
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_28]
mov rax, [rbp+var_10]
mov eax, [rax+64h]
and eax, 20h
movsx ecx, al
call convert_from_long
mov rax, [rbp+var_18]
mov rcx, [rax]
add rcx, 2
mov [rax], rcx
loc_36D2F:
add rsp, 40h
pop rbp
retn
| _BYTE ** ps_fetch_int16(long long a1, long long a2, _BYTE **a3)
{
_BYTE **result; // rax
long long v4; // [rsp+8h] [rbp-38h]
int v5; // [rsp+14h] [rbp-2Ch]
unsigned __int16 v6; // [rsp+26h] [rbp-1Ah]
v5 = *(_DWORD *)(a1 + 96);
if ( v5 == 2 || v5 == 13 )
return ps_fetch_from_1_to_8_bytes(a1, a2, a3, 2u);
v6 = ((unsigned __int8)(*a3)[1] << 8) + (unsigned __int8)**a3;
if ( (*(_DWORD *)(a2 + 100) & 0x20) != 0 )
v4 = v6;
else
v4 = (__int16)v6;
convert_from_long(a1, a2, v4, *(_BYTE *)(a2 + 100) & 0x20);
result = a3;
*a3 += 2;
return result;
}
| ps_fetch_int16:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x60]
MOV dword ptr [RBP + -0x2c],EAX
SUB EAX,0x2
JZ 0x00136c9f
JMP 0x00136c95
LAB_00136c95:
MOV EAX,dword ptr [RBP + -0x2c]
SUB EAX,0xd
JNZ 0x00136cb7
JMP 0x00136c9f
LAB_00136c9f:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
MOV ECX,0x2
CALL 0x00135a00
JMP 0x00136d2f
LAB_00136cb7:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOVZX EAX,byte ptr [RAX]
CWDE
MOV RCX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RCX]
MOVZX ECX,byte ptr [RCX + 0x1]
MOVSX ECX,CX
SHL ECX,0x8
ADD EAX,ECX
MOV word ptr [RBP + -0x1a],AX
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x64]
AND EAX,0x20
CMP EAX,0x0
JZ 0x00136cf2
MOVZX EAX,word ptr [RBP + -0x1a]
MOV qword ptr [RBP + -0x38],RAX
JMP 0x00136cfb
LAB_00136cf2:
MOVSX RAX,word ptr [RBP + -0x1a]
MOV qword ptr [RBP + -0x38],RAX
LAB_00136cfb:
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x64]
AND EAX,0x20
MOVSX ECX,AL
CALL 0x00137710
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RAX]
ADD RCX,0x2
MOV qword ptr [RAX],RCX
LAB_00136d2f:
ADD RSP,0x40
POP RBP
RET
|
void ps_fetch_int16(long param_1,long param_2,long *param_3)
{
ushort uVar1;
ulong local_40;
if ((*(int *)(param_1 + 0x60) == 2) || (*(int *)(param_1 + 0x60) == 0xd)) {
ps_fetch_from_1_to_8_bytes(param_1,param_2,param_3,2);
}
else {
uVar1 = (ushort)*(byte *)*param_3 + (short)((int)(short)(ushort)*(byte *)(*param_3 + 1) << 8);
if ((*(uint *)(param_2 + 100) & 0x20) == 0) {
local_40 = (ulong)(short)uVar1;
}
else {
local_40 = (ulong)uVar1;
}
convert_from_long(param_1,param_2,local_40,(byte)*(int4 *)(param_2 + 100) & 0x20);
*param_3 = *param_3 + 2;
}
return;
}
| |
21,441 | ps_fetch_int16 | eloqsql/libmariadb/libmariadb/ma_stmt_codec.c | static
void ps_fetch_int16(MYSQL_BIND *r_param, const MYSQL_FIELD * const field,
unsigned char **row)
{
switch (r_param->buffer_type) {
case MYSQL_TYPE_YEAR:
case MYSQL_TYPE_SHORT:
ps_fetch_from_1_to_8_bytes(r_param, field, row, 2);
break;
default:
{
short sval= sint2korr(*row);
longlong lval= field->flags & UNSIGNED_FLAG ? (longlong)(ushort) sval : (longlong)sval;
convert_from_long(r_param, field, lval, field->flags & UNSIGNED_FLAG);
(*row) += 2;
}
break;
}
} | O3 | c | ps_fetch_int16:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl 0x60(%rdi), %eax
cmpl $0xd, %eax
je 0x28ab4
cmpl $0x2, %eax
jne 0x28ac7
movq %rbx, %rdx
movl $0x2, %ecx
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x27ee4
movq (%rbx), %rax
movzwl (%rax), %eax
movl 0x64(%rsi), %ecx
andl $0x20, %ecx
movswq %ax, %rdx
cmovneq %rax, %rdx
callq 0x295bf
addq $0x2, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| ps_fetch_int16:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdx
mov eax, [rdi+60h]
cmp eax, 0Dh
jz short loc_28AB4
cmp eax, 2
jnz short loc_28AC7
loc_28AB4:
mov rdx, rbx
mov ecx, 2
add rsp, 8
pop rbx
pop rbp
jmp ps_fetch_from_1_to_8_bytes
loc_28AC7:
mov rax, [rbx]
movzx eax, word ptr [rax]
mov ecx, [rsi+64h]
and ecx, 20h
movsx rdx, ax
cmovnz rdx, rax
call convert_from_long
add qword ptr [rbx], 2
add rsp, 8
pop rbx
pop rbp
retn
| long long ps_fetch_int16(long long a1, long long a2, _BYTE **a3)
{
int v4; // eax
long long result; // rax
long long v6; // rdx
v4 = *(_DWORD *)(a1 + 96);
if ( v4 == 13 || v4 == 2 )
return ps_fetch_from_1_to_8_bytes(a1, a2, a3, 2u);
v6 = *(__int16 *)*a3;
if ( (*(_DWORD *)(a2 + 100) & 0x20) != 0 )
v6 = *(unsigned __int16 *)*a3;
result = convert_from_long(a1, a2, v6, *(_DWORD *)(a2 + 100) & 0x20);
*a3 += 2;
return result;
}
| ps_fetch_int16:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RBX,RDX
MOV EAX,dword ptr [RDI + 0x60]
CMP EAX,0xd
JZ 0x00128ab4
CMP EAX,0x2
JNZ 0x00128ac7
LAB_00128ab4:
MOV RDX,RBX
MOV ECX,0x2
ADD RSP,0x8
POP RBX
POP RBP
JMP 0x00127ee4
LAB_00128ac7:
MOV RAX,qword ptr [RBX]
MOVZX EAX,word ptr [RAX]
MOV ECX,dword ptr [RSI + 0x64]
AND ECX,0x20
MOVSX RDX,AX
CMOVNZ RDX,RAX
CALL 0x001295bf
ADD qword ptr [RBX],0x2
ADD RSP,0x8
POP RBX
POP RBP
RET
|
void ps_fetch_int16(long param_1,long param_2,long *param_3)
{
ulong uVar1;
if ((*(int *)(param_1 + 0x60) != 0xd) && (*(int *)(param_1 + 0x60) != 2)) {
uVar1 = (long)(short)*(ushort *)*param_3;
if ((*(uint *)(param_2 + 100) & 0x20) != 0) {
uVar1 = (ulong)*(ushort *)*param_3;
}
convert_from_long(param_1,param_2,uVar1);
*param_3 = *param_3 + 2;
return;
}
ps_fetch_from_1_to_8_bytes(param_1,param_2,param_3,2);
return;
}
| |
21,442 | ftxui::TerminalInputParser::Send(ftxui::TerminalInputParser::Output) | Andrewchistyakov[P]flashcards_lyc/build_O0/_deps/ftxui-src/src/ftxui/component/terminal_input_parser.cpp | void TerminalInputParser::Send(TerminalInputParser::Output output) {
switch (output.type) {
case UNCOMPLETED:
return;
case DROP:
pending_.clear();
return;
case CHARACTER:
out_->Send(Event::Character(std::move(pending_)));
pending_.clear();
return;
case SPECIAL: {
auto it = g_uniformize.find(pending_);
if (it != g_uniformize.end()) {
pending_ = it->second;
}
out_->Send(Event::Special(std::move(pending_)));
pending_.clear();
}
return;
case MOUSE:
out_->Send(Event::Mouse(std::move(pending_), output.mouse)); // NOLINT
pending_.clear();
return;
case CURSOR_REPORTING:
out_->Send(Event::CursorReporting(std::move(pending_), // NOLINT
output.cursor.x, // NOLINT
output.cursor.y)); // NOLINT
pending_.clear();
return;
}
// NOT_REACHED().
} | O0 | cpp | ftxui::TerminalInputParser::Send(ftxui::TerminalInputParser::Output):
pushq %rbp
movq %rsp, %rbp
subq $0x380, %rsp # imm = 0x380
leaq 0x10(%rbp), %rax
movq %rax, -0x300(%rbp)
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rcx
movq %rcx, -0x2f8(%rbp)
movl (%rax), %eax
movq %rax, -0x2f0(%rbp)
subq $0x5, %rax
ja 0x72919
movq -0x2f0(%rbp), %rax
leaq 0x20e66(%rip), %rcx # 0x932cc
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
jmp 0x72919
movq -0x2f8(%rbp), %rdi
addq $0x10, %rdi
callq 0xd7d0
jmp 0x72919
movq -0x2f8(%rbp), %rdi
callq 0x695c0
movq -0x2f8(%rbp), %rsi
movq %rax, -0x310(%rbp)
addq $0x10, %rsi
leaq -0xb0(%rbp), %rdi
movq %rdi, -0x308(%rbp)
callq 0xd300
movq -0x308(%rbp), %rsi
leaq -0x90(%rbp), %rdi
callq 0x57ca0
jmp 0x724cf
leaq -0x50(%rbp), %rdi
movq %rdi, -0x318(%rbp)
leaq -0x90(%rbp), %rsi
callq 0x69f70
movq -0x310(%rbp), %rdi
movq -0x318(%rbp), %rsi
callq 0x695e0
jmp 0x724fb
leaq -0x50(%rbp), %rdi
callq 0x21650
leaq -0x90(%rbp), %rdi
callq 0x219e0
leaq -0xb0(%rbp), %rdi
callq 0xdbc8
movq -0x2f8(%rbp), %rdi
addq $0x10, %rdi
callq 0xd7d0
jmp 0x72919
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xb8(%rbp)
movl %eax, -0xbc(%rbp)
jmp 0x7256c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xb8(%rbp)
movl %eax, -0xbc(%rbp)
leaq -0x50(%rbp), %rdi
callq 0x21650
leaq -0x90(%rbp), %rdi
callq 0x219e0
leaq -0xb0(%rbp), %rdi
callq 0xdbc8
jmp 0x72922
movq -0x2f8(%rbp), %rsi
addq $0x10, %rsi
leaq 0x6df29(%rip), %rdi # 0xe04b8
callq 0x73bb0
movq %rax, -0xc8(%rbp)
leaq 0x6df16(%rip), %rdi # 0xe04b8
callq 0x73be0
movq %rax, -0xd0(%rbp)
leaq -0xc8(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
callq 0x1a470
testb $0x1, %al
jne 0x725c7
jmp 0x725ea
leaq -0xc8(%rbp), %rdi
callq 0x1a4d0
movq -0x2f8(%rbp), %rdi
movq %rax, %rsi
addq $0x20, %rsi
addq $0x10, %rdi
callq 0xd060
movq -0x2f8(%rbp), %rdi
callq 0x695c0
movq -0x2f8(%rbp), %rsi
movq %rax, -0x328(%rbp)
addq $0x10, %rsi
leaq -0x178(%rbp), %rdi
movq %rdi, -0x320(%rbp)
callq 0xd300
movq -0x320(%rbp), %rsi
leaq -0x158(%rbp), %rdi
callq 0x57f20
jmp 0x72630
leaq -0x118(%rbp), %rdi
movq %rdi, -0x330(%rbp)
leaq -0x158(%rbp), %rsi
callq 0x69f70
movq -0x328(%rbp), %rdi
movq -0x330(%rbp), %rsi
callq 0x695e0
jmp 0x7265f
leaq -0x118(%rbp), %rdi
callq 0x21650
leaq -0x158(%rbp), %rdi
callq 0x219e0
leaq -0x178(%rbp), %rdi
callq 0xdbc8
movq -0x2f8(%rbp), %rdi
addq $0x10, %rdi
callq 0xd7d0
jmp 0x72919
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xb8(%rbp)
movl %eax, -0xbc(%rbp)
jmp 0x726d6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xb8(%rbp)
movl %eax, -0xbc(%rbp)
leaq -0x118(%rbp), %rdi
callq 0x21650
leaq -0x158(%rbp), %rdi
callq 0x219e0
leaq -0x178(%rbp), %rdi
callq 0xdbc8
jmp 0x72922
movq -0x2f8(%rbp), %rdi
callq 0x695c0
movq -0x2f8(%rbp), %rsi
movq %rax, -0x340(%rbp)
addq $0x10, %rsi
leaq -0x220(%rbp), %rdi
movq %rdi, -0x338(%rbp)
callq 0xd300
movq -0x300(%rbp), %rax
movq -0x338(%rbp), %rsi
movl 0x14(%rax), %ecx
movl %ecx, -0x230(%rbp)
movups 0x4(%rax), %xmm0
movaps %xmm0, -0x240(%rbp)
movl -0x230(%rbp), %ecx
movq %rsp, %rax
movl %ecx, 0x10(%rax)
movaps -0x240(%rbp), %xmm0
movups %xmm0, (%rax)
leaq -0x200(%rbp), %rdi
callq 0x57e90
jmp 0x7275e
leaq -0x1c0(%rbp), %rdi
movq %rdi, -0x348(%rbp)
leaq -0x200(%rbp), %rsi
callq 0x69f70
movq -0x340(%rbp), %rdi
movq -0x348(%rbp), %rsi
callq 0x695e0
jmp 0x7278d
leaq -0x1c0(%rbp), %rdi
callq 0x21650
leaq -0x200(%rbp), %rdi
callq 0x219e0
leaq -0x220(%rbp), %rdi
callq 0xdbc8
movq -0x2f8(%rbp), %rdi
addq $0x10, %rdi
callq 0xd7d0
jmp 0x72919
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xb8(%rbp)
movl %eax, -0xbc(%rbp)
jmp 0x72804
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xb8(%rbp)
movl %eax, -0xbc(%rbp)
leaq -0x1c0(%rbp), %rdi
callq 0x21650
leaq -0x200(%rbp), %rdi
callq 0x219e0
leaq -0x220(%rbp), %rdi
callq 0xdbc8
jmp 0x72922
movq -0x2f8(%rbp), %rdi
callq 0x695c0
movq -0x2f8(%rbp), %rsi
movq %rax, -0x358(%rbp)
addq $0x10, %rsi
leaq -0x2e8(%rbp), %rdi
movq %rdi, -0x350(%rbp)
callq 0xd300
movq -0x300(%rbp), %rax
movq -0x350(%rbp), %rsi
movl 0x4(%rax), %edx
movl 0x8(%rax), %ecx
leaq -0x2c8(%rbp), %rdi
callq 0x57f80
jmp 0x72868
leaq -0x288(%rbp), %rdi
movq %rdi, -0x360(%rbp)
leaq -0x2c8(%rbp), %rsi
callq 0x69f70
movq -0x358(%rbp), %rdi
movq -0x360(%rbp), %rsi
callq 0x695e0
jmp 0x72897
leaq -0x288(%rbp), %rdi
callq 0x21650
leaq -0x2c8(%rbp), %rdi
callq 0x219e0
leaq -0x2e8(%rbp), %rdi
callq 0xdbc8
movq -0x2f8(%rbp), %rdi
addq $0x10, %rdi
callq 0xd7d0
jmp 0x72919
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xb8(%rbp)
movl %eax, -0xbc(%rbp)
jmp 0x7290b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xb8(%rbp)
movl %eax, -0xbc(%rbp)
leaq -0x288(%rbp), %rdi
callq 0x21650
leaq -0x2c8(%rbp), %rdi
callq 0x219e0
leaq -0x2e8(%rbp), %rdi
callq 0xdbc8
jmp 0x72922
addq $0x380, %rsp # imm = 0x380
popq %rbp
retq
movq -0xb8(%rbp), %rdi
callq 0xda90
nop
| _ZN5ftxui19TerminalInputParser4SendENS0_6OutputE:
push rbp
mov rbp, rsp
sub rsp, 380h
lea rax, [rbp+arg_0]
mov [rbp+var_300], rax
mov [rbp+var_8], rdi
mov rcx, [rbp+var_8]
mov [rbp+var_2F8], rcx
mov eax, [rax]
mov [rbp+var_2F0], rax
sub rax, 5; switch 6 cases
ja def_7246D; jumptable 000000000007246D default case
mov rax, [rbp+var_2F0]
lea rcx, jpt_7246D
movsxd rax, ds:(jpt_7246D - 932CCh)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_7246F:
jmp def_7246D; jumptable 000000000007246D case 0
loc_72474:
mov rdi, [rbp+var_2F8]; jumptable 000000000007246D case 1
add rdi, 10h
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5clearEv; std::string::clear(void)
jmp def_7246D; jumptable 000000000007246D default case
loc_72489:
mov rdi, [rbp+var_2F8]; jumptable 000000000007246D case 2
call _ZNKSt10unique_ptrIN5ftxui10SenderImplISt7variantIJNS0_5EventESt8functionIFvvEENS0_13AnimationTaskEEEEESt14default_deleteIS9_EEptEv; std::unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>>::operator->(void)
mov rsi, [rbp+var_2F8]
mov [rbp+var_310], rax
add rsi, 10h
lea rdi, [rbp+var_B0]
mov [rbp+var_308], rdi
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EOS4_; std::string::basic_string(std::string&&)
mov rsi, [rbp+var_308]
lea rdi, [rbp+var_90]
call _ZN5ftxui5Event9CharacterENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; ftxui::Event::Character(std::string)
jmp short $+2
loc_724CF:
lea rdi, [rbp+var_50]
mov [rbp+var_318], rdi
lea rsi, [rbp+var_90]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEEC2IS1_vvS1_vEEOT_; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::variant<ftxui::Event,void,void,ftxui::Event,void>(ftxui::Event &&)
mov rdi, [rbp+var_310]
mov rsi, [rbp+var_318]
call _ZN5ftxui10SenderImplISt7variantIJNS_5EventESt8functionIFvvEENS_13AnimationTaskEEEE4SendES7_; ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>::Send(std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>)
jmp short $+2
loc_724FB:
lea rdi, [rbp+var_50]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEED2Ev; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant()
lea rdi, [rbp+var_90]; void *
call _ZN5ftxui5EventD2Ev; ftxui::Event::~Event()
lea rdi, [rbp+var_B0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rdi, [rbp+var_2F8]
add rdi, 10h
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5clearEv; std::string::clear(void)
jmp def_7246D; jumptable 000000000007246D default case
mov rcx, rax
mov eax, edx
mov [rbp+var_B8], rcx
mov [rbp+var_BC], eax
jmp short loc_7256C
mov rcx, rax
mov eax, edx
mov [rbp+var_B8], rcx
mov [rbp+var_BC], eax
lea rdi, [rbp+var_50]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEED2Ev; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant()
lea rdi, [rbp+var_90]; void *
call _ZN5ftxui5EventD2Ev; ftxui::Event::~Event()
loc_7256C:
lea rdi, [rbp+var_B0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_72922
loc_7257D:
mov rsi, [rbp+var_2F8]; jumptable 000000000007246D case 3
add rsi, 10h
lea rdi, _ZN5ftxuiL12g_uniformizeB5cxx11E; ftxui::g_uniformize
call _ZNKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_St4lessIS5_ESaISt4pairIKS5_S5_EEE4findERS9_; std::map<std::string,std::string>::find(std::string const&)
mov [rbp+var_C8], rax
lea rdi, _ZN5ftxuiL12g_uniformizeB5cxx11E; ftxui::g_uniformize
call _ZNKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_St4lessIS5_ESaISt4pairIKS5_S5_EEE3endEv; std::map<std::string,std::string>::end(void)
mov [rbp+var_D0], rax
lea rdi, [rbp+var_C8]
lea rsi, [rbp+var_D0]
call _ZStneRKSt23_Rb_tree_const_iteratorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES6_EESB_; std::operator!=(std::_Rb_tree_const_iterator<std::pair<std::string const,std::string>> const&,std::_Rb_tree_const_iterator<std::pair<std::string const,std::string>> const&)
test al, 1
jnz short loc_725C7
jmp short loc_725EA
loc_725C7:
lea rdi, [rbp+var_C8]
call _ZNKSt23_Rb_tree_const_iteratorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES6_EEptEv; std::_Rb_tree_const_iterator<std::pair<std::string const,std::string>>::operator->(void)
mov rdi, [rbp+var_2F8]
mov rsi, rax
add rsi, 20h ; ' '
add rdi, 10h
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSERKS4_; std::string::operator=(std::string const&)
loc_725EA:
mov rdi, [rbp+var_2F8]
call _ZNKSt10unique_ptrIN5ftxui10SenderImplISt7variantIJNS0_5EventESt8functionIFvvEENS0_13AnimationTaskEEEEESt14default_deleteIS9_EEptEv; std::unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>>::operator->(void)
mov rsi, [rbp+var_2F8]
mov [rbp+var_328], rax
add rsi, 10h
lea rdi, [rbp+var_178]
mov [rbp+var_320], rdi
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EOS4_; std::string::basic_string(std::string&&)
mov rsi, [rbp+var_320]
lea rdi, [rbp+var_158]
call _ZN5ftxui5Event7SpecialENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; ftxui::Event::Special(std::string)
jmp short $+2
loc_72630:
lea rdi, [rbp+var_118]
mov [rbp+var_330], rdi
lea rsi, [rbp+var_158]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEEC2IS1_vvS1_vEEOT_; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::variant<ftxui::Event,void,void,ftxui::Event,void>(ftxui::Event &&)
mov rdi, [rbp+var_328]
mov rsi, [rbp+var_330]
call _ZN5ftxui10SenderImplISt7variantIJNS_5EventESt8functionIFvvEENS_13AnimationTaskEEEE4SendES7_; ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>::Send(std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>)
jmp short $+2
loc_7265F:
lea rdi, [rbp+var_118]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEED2Ev; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant()
lea rdi, [rbp+var_158]; void *
call _ZN5ftxui5EventD2Ev; ftxui::Event::~Event()
lea rdi, [rbp+var_178]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rdi, [rbp+var_2F8]
add rdi, 10h
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5clearEv; std::string::clear(void)
jmp def_7246D; jumptable 000000000007246D default case
mov rcx, rax
mov eax, edx
mov [rbp+var_B8], rcx
mov [rbp+var_BC], eax
jmp short loc_726D6
mov rcx, rax
mov eax, edx
mov [rbp+var_B8], rcx
mov [rbp+var_BC], eax
lea rdi, [rbp+var_118]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEED2Ev; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant()
lea rdi, [rbp+var_158]; void *
call _ZN5ftxui5EventD2Ev; ftxui::Event::~Event()
loc_726D6:
lea rdi, [rbp+var_178]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_72922
loc_726E7:
mov rdi, [rbp+var_2F8]; jumptable 000000000007246D case 4
call _ZNKSt10unique_ptrIN5ftxui10SenderImplISt7variantIJNS0_5EventESt8functionIFvvEENS0_13AnimationTaskEEEEESt14default_deleteIS9_EEptEv; std::unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>>::operator->(void)
mov rsi, [rbp+var_2F8]
mov [rbp+var_340], rax
add rsi, 10h
lea rdi, [rbp+var_220]
mov [rbp+var_338], rdi
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EOS4_; std::string::basic_string(std::string&&)
mov rax, [rbp+var_300]
mov rsi, [rbp+var_338]
mov ecx, [rax+14h]
mov [rbp+var_230], ecx
movups xmm0, xmmword ptr [rax+4]
movaps [rbp+var_240], xmm0
mov ecx, [rbp+var_230]
mov rax, rsp
mov [rax+10h], ecx
movaps xmm0, [rbp+var_240]
movups xmmword ptr [rax], xmm0
lea rdi, [rbp+var_200]
call _ZN5ftxui5Event5MouseENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS_5MouseE; ftxui::Event::Mouse(std::string,ftxui::Mouse)
jmp short $+2
loc_7275E:
lea rdi, [rbp+var_1C0]
mov [rbp+var_348], rdi
lea rsi, [rbp+var_200]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEEC2IS1_vvS1_vEEOT_; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::variant<ftxui::Event,void,void,ftxui::Event,void>(ftxui::Event &&)
mov rdi, [rbp+var_340]
mov rsi, [rbp+var_348]
call _ZN5ftxui10SenderImplISt7variantIJNS_5EventESt8functionIFvvEENS_13AnimationTaskEEEE4SendES7_; ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>::Send(std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>)
jmp short $+2
loc_7278D:
lea rdi, [rbp+var_1C0]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEED2Ev; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant()
lea rdi, [rbp+var_200]; void *
call _ZN5ftxui5EventD2Ev; ftxui::Event::~Event()
lea rdi, [rbp+var_220]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rdi, [rbp+var_2F8]
add rdi, 10h
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5clearEv; std::string::clear(void)
jmp def_7246D; jumptable 000000000007246D default case
mov rcx, rax
mov eax, edx
mov [rbp+var_B8], rcx
mov [rbp+var_BC], eax
jmp short loc_72804
mov rcx, rax
mov eax, edx
mov [rbp+var_B8], rcx
mov [rbp+var_BC], eax
lea rdi, [rbp+var_1C0]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEED2Ev; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant()
lea rdi, [rbp+var_200]; void *
call _ZN5ftxui5EventD2Ev; ftxui::Event::~Event()
loc_72804:
lea rdi, [rbp+var_220]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp loc_72922
loc_72815:
mov rdi, [rbp+var_2F8]; jumptable 000000000007246D case 5
call _ZNKSt10unique_ptrIN5ftxui10SenderImplISt7variantIJNS0_5EventESt8functionIFvvEENS0_13AnimationTaskEEEEESt14default_deleteIS9_EEptEv; std::unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>>::operator->(void)
mov rsi, [rbp+var_2F8]
mov [rbp+var_358], rax
add rsi, 10h
lea rdi, [rbp+var_2E8]
mov [rbp+var_350], rdi
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EOS4_; std::string::basic_string(std::string&&)
mov rax, [rbp+var_300]
mov rsi, [rbp+var_350]
mov edx, [rax+4]
mov ecx, [rax+8]
lea rdi, [rbp+var_2C8]
call _ZN5ftxui5Event15CursorReportingENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii; ftxui::Event::CursorReporting(std::string,int,int)
jmp short $+2
loc_72868:
lea rdi, [rbp+var_288]
mov [rbp+var_360], rdi
lea rsi, [rbp+var_2C8]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEEC2IS1_vvS1_vEEOT_; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::variant<ftxui::Event,void,void,ftxui::Event,void>(ftxui::Event &&)
mov rdi, [rbp+var_358]
mov rsi, [rbp+var_360]
call _ZN5ftxui10SenderImplISt7variantIJNS_5EventESt8functionIFvvEENS_13AnimationTaskEEEE4SendES7_; ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>::Send(std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>)
jmp short $+2
loc_72897:
lea rdi, [rbp+var_288]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEED2Ev; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant()
lea rdi, [rbp+var_2C8]; void *
call _ZN5ftxui5EventD2Ev; ftxui::Event::~Event()
lea rdi, [rbp+var_2E8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rdi, [rbp+var_2F8]
add rdi, 10h
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5clearEv; std::string::clear(void)
jmp short def_7246D; jumptable 000000000007246D default case
mov rcx, rax
mov eax, edx
mov [rbp+var_B8], rcx
mov [rbp+var_BC], eax
jmp short loc_7290B
mov rcx, rax
mov eax, edx
mov [rbp+var_B8], rcx
mov [rbp+var_BC], eax
lea rdi, [rbp+var_288]
call _ZNSt7variantIJN5ftxui5EventESt8functionIFvvEENS0_13AnimationTaskEEED2Ev; std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant()
lea rdi, [rbp+var_2C8]; void *
call _ZN5ftxui5EventD2Ev; ftxui::Event::~Event()
loc_7290B:
lea rdi, [rbp+var_2E8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_72922
def_7246D:
add rsp, 380h; jumptable 000000000007246D default case
pop rbp
retn
loc_72922:
mov rdi, [rbp+var_B8]
call __Unwind_Resume
| long long ftxui::TerminalInputParser::Send(long long a1, arg7_72420 a2)
{
long long result; // rax
long long v8; // rax
long long v9; // rdx
long long v10; // r8
long long v11; // r9
_QWORD *v12; // [rsp+28h] [rbp-358h]
_QWORD *v13; // [rsp+40h] [rbp-340h]
_QWORD *v14; // [rsp+58h] [rbp-328h]
_QWORD *v15; // [rsp+70h] [rbp-310h]
_BYTE v16[32]; // [rsp+98h] [rbp-2E8h] BYREF
char v17[64]; // [rsp+B8h] [rbp-2C8h] BYREF
_BYTE v18[72]; // [rsp+F8h] [rbp-288h] BYREF
_BYTE v19[32]; // [rsp+160h] [rbp-220h] BYREF
char v20[64]; // [rsp+180h] [rbp-200h] BYREF
_BYTE v21[72]; // [rsp+1C0h] [rbp-1C0h] BYREF
_BYTE v22[32]; // [rsp+208h] [rbp-178h] BYREF
char v23[64]; // [rsp+228h] [rbp-158h] BYREF
_BYTE v24[72]; // [rsp+268h] [rbp-118h] BYREF
long long v25; // [rsp+2B0h] [rbp-D0h] BYREF
long long v26; // [rsp+2B8h] [rbp-C8h] BYREF
_BYTE v27[32]; // [rsp+2D0h] [rbp-B0h] BYREF
char v28[64]; // [rsp+2F0h] [rbp-90h] BYREF
_BYTE v29[72]; // [rsp+330h] [rbp-50h] BYREF
long long v30; // [rsp+378h] [rbp-8h]
v30 = a1;
result = *(unsigned int *)a2.arr;
switch ( *(_DWORD *)a2.arr )
{
case 1:
result = std::string::clear(a1 + 16);
break;
case 2:
v15 = (_QWORD *)std::unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>>::operator->(a1);
std::string::basic_string(v27, a1 + 16);
ftxui::Event::Character((ftxui::Event *)v28);
std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::variant<ftxui::Event,void,void,ftxui::Event,void>();
ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>::Send(
v15,
(long long)v29);
std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant((long long)v29);
ftxui::Event::~Event(v28);
std::string::~string(v27);
result = std::string::clear(a1 + 16);
break;
case 3:
v26 = std::map<std::string,std::string>::find(&ftxui::g_uniformize[abi:cxx11], a1 + 16);
v25 = std::map<std::string,std::string>::end(&ftxui::g_uniformize[abi:cxx11]);
if ( std::operator!=(&v26, &v25) )
{
v8 = std::_Rb_tree_const_iterator<std::pair<std::string const,std::string>>::operator->(&v26);
std::string::operator=(a1 + 16, v8 + 32);
}
v14 = (_QWORD *)std::unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>>::operator->(a1);
std::string::basic_string(v22, a1 + 16);
ftxui::Event::Special((ftxui::Event *)v23);
std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::variant<ftxui::Event,void,void,ftxui::Event,void>();
ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>::Send(
v14,
(long long)v24);
std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant((long long)v24);
ftxui::Event::~Event(v23);
std::string::~string(v22);
result = std::string::clear(a1 + 16);
break;
case 4:
v13 = (_QWORD *)std::unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>>::operator->(a1);
std::string::basic_string(v19, a1 + 16);
ftxui::Event::Mouse(
(long long)v20,
(long long)v19,
v9,
*(unsigned int *)&a2.arr[20],
v10,
v11,
*(long long *)&a2.arr[4],
*(long long *)&a2.arr[12],
*(int *)&a2.arr[20]);
std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::variant<ftxui::Event,void,void,ftxui::Event,void>();
ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>::Send(
v13,
(long long)v21);
std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant((long long)v21);
ftxui::Event::~Event(v20);
std::string::~string(v19);
result = std::string::clear(a1 + 16);
break;
case 5:
v12 = (_QWORD *)std::unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>>::operator->(a1);
std::string::basic_string(v16, a1 + 16);
ftxui::Event::CursorReporting(
(long long)v17,
(long long)v16,
*(unsigned int *)&a2.arr[4],
*(unsigned int *)&a2.arr[8]);
std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::variant<ftxui::Event,void,void,ftxui::Event,void>();
ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>>::Send(
v12,
(long long)v18);
std::variant<ftxui::Event,std::function<void ()(void)>,ftxui::AnimationTask>::~variant((long long)v18);
ftxui::Event::~Event(v17);
std::string::~string(v16);
result = std::string::clear(a1 + 16);
break;
default:
return result;
}
return result;
}
| Send:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x380
LEA RAX,[RBP + 0x10]
MOV qword ptr [RBP + -0x300],RAX
MOV qword ptr [RBP + -0x8],RDI
MOV RCX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x2f8],RCX
MOV EAX,dword ptr [RAX]
MOV qword ptr [RBP + -0x2f0],RAX
SUB RAX,0x5
JA 0x00172919
MOV RAX,qword ptr [RBP + -0x2f0]
LEA RCX,[0x1932cc]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_0:
JMP 0x00172919
caseD_1:
MOV RDI,qword ptr [RBP + -0x2f8]
ADD RDI,0x10
CALL 0x0010d7d0
JMP 0x00172919
caseD_2:
MOV RDI,qword ptr [RBP + -0x2f8]
CALL 0x001695c0
MOV RSI,qword ptr [RBP + -0x2f8]
MOV qword ptr [RBP + -0x310],RAX
ADD RSI,0x10
LEA RDI,[RBP + -0xb0]
MOV qword ptr [RBP + -0x308],RDI
CALL 0x0010d300
MOV RSI,qword ptr [RBP + -0x308]
LAB_001724c1:
LEA RDI,[RBP + -0x90]
CALL 0x00157ca0
JMP 0x001724cf
LAB_001724cf:
LEA RDI,[RBP + -0x50]
MOV qword ptr [RBP + -0x318],RDI
LEA RSI,[RBP + -0x90]
CALL 0x00169f70
MOV RDI,qword ptr [RBP + -0x310]
MOV RSI,qword ptr [RBP + -0x318]
LAB_001724f4:
CALL 0x001695e0
LAB_001724f9:
JMP 0x001724fb
LAB_001724fb:
LEA RDI,[RBP + -0x50]
CALL 0x00121650
LEA RDI,[RBP + -0x90]
CALL 0x001219e0
LEA RDI,[RBP + -0xb0]
CALL 0x0010dbc8
MOV RDI,qword ptr [RBP + -0x2f8]
ADD RDI,0x10
CALL 0x0010d7d0
JMP 0x00172919
caseD_3:
MOV RSI,qword ptr [RBP + -0x2f8]
ADD RSI,0x10
LEA RDI,[0x1e04b8]
CALL 0x00173bb0
MOV qword ptr [RBP + -0xc8],RAX
LEA RDI,[0x1e04b8]
CALL 0x00173be0
MOV qword ptr [RBP + -0xd0],RAX
LEA RDI,[RBP + -0xc8]
LEA RSI,[RBP + -0xd0]
CALL 0x0011a470
TEST AL,0x1
JNZ 0x001725c7
JMP 0x001725ea
LAB_001725c7:
LEA RDI,[RBP + -0xc8]
CALL 0x0011a4d0
MOV RDI,qword ptr [RBP + -0x2f8]
MOV RSI,RAX
ADD RSI,0x20
ADD RDI,0x10
CALL 0x0010d060
LAB_001725ea:
MOV RDI,qword ptr [RBP + -0x2f8]
CALL 0x001695c0
MOV RSI,qword ptr [RBP + -0x2f8]
MOV qword ptr [RBP + -0x328],RAX
ADD RSI,0x10
LEA RDI,[RBP + -0x178]
MOV qword ptr [RBP + -0x320],RDI
CALL 0x0010d300
MOV RSI,qword ptr [RBP + -0x320]
LAB_00172622:
LEA RDI,[RBP + -0x158]
CALL 0x00157f20
JMP 0x00172630
LAB_00172630:
LEA RDI,[RBP + -0x118]
MOV qword ptr [RBP + -0x330],RDI
LEA RSI,[RBP + -0x158]
CALL 0x00169f70
MOV RDI,qword ptr [RBP + -0x328]
MOV RSI,qword ptr [RBP + -0x330]
LAB_00172658:
CALL 0x001695e0
JMP 0x0017265f
LAB_0017265f:
LEA RDI,[RBP + -0x118]
CALL 0x00121650
LEA RDI,[RBP + -0x158]
CALL 0x001219e0
LEA RDI,[RBP + -0x178]
CALL 0x0010dbc8
MOV RDI,qword ptr [RBP + -0x2f8]
ADD RDI,0x10
CALL 0x0010d7d0
JMP 0x00172919
caseD_4:
MOV RDI,qword ptr [RBP + -0x2f8]
CALL 0x001695c0
MOV RSI,qword ptr [RBP + -0x2f8]
MOV qword ptr [RBP + -0x340],RAX
ADD RSI,0x10
LEA RDI,[RBP + -0x220]
MOV qword ptr [RBP + -0x338],RDI
CALL 0x0010d300
MOV RAX,qword ptr [RBP + -0x300]
MOV RSI,qword ptr [RBP + -0x338]
MOV ECX,dword ptr [RAX + 0x14]
MOV dword ptr [RBP + -0x230],ECX
MOVUPS XMM0,xmmword ptr [RAX + 0x4]
MOVAPS xmmword ptr [RBP + -0x240],XMM0
LAB_0017273a:
MOV ECX,dword ptr [RBP + -0x230]
MOV RAX,RSP
MOV dword ptr [RAX + 0x10],ECX
MOVAPS XMM0,xmmword ptr [RBP + -0x240]
MOVUPS xmmword ptr [RAX],XMM0
LEA RDI,[RBP + -0x200]
CALL 0x00157e90
JMP 0x0017275e
LAB_0017275e:
LEA RDI,[RBP + -0x1c0]
MOV qword ptr [RBP + -0x348],RDI
LEA RSI,[RBP + -0x200]
CALL 0x00169f70
MOV RDI,qword ptr [RBP + -0x340]
MOV RSI,qword ptr [RBP + -0x348]
LAB_00172786:
CALL 0x001695e0
JMP 0x0017278d
LAB_0017278d:
LEA RDI,[RBP + -0x1c0]
CALL 0x00121650
LEA RDI,[RBP + -0x200]
CALL 0x001219e0
LEA RDI,[RBP + -0x220]
CALL 0x0010dbc8
MOV RDI,qword ptr [RBP + -0x2f8]
ADD RDI,0x10
CALL 0x0010d7d0
JMP 0x00172919
caseD_5:
MOV RDI,qword ptr [RBP + -0x2f8]
CALL 0x001695c0
MOV RSI,qword ptr [RBP + -0x2f8]
MOV qword ptr [RBP + -0x358],RAX
ADD RSI,0x10
LEA RDI,[RBP + -0x2e8]
MOV qword ptr [RBP + -0x350],RDI
CALL 0x0010d300
MOV RAX,qword ptr [RBP + -0x300]
MOV RSI,qword ptr [RBP + -0x350]
MOV EDX,dword ptr [RAX + 0x4]
MOV ECX,dword ptr [RAX + 0x8]
LAB_0017285a:
LEA RDI,[RBP + -0x2c8]
CALL 0x00157f80
JMP 0x00172868
LAB_00172868:
LEA RDI,[RBP + -0x288]
MOV qword ptr [RBP + -0x360],RDI
LEA RSI,[RBP + -0x2c8]
CALL 0x00169f70
MOV RDI,qword ptr [RBP + -0x358]
MOV RSI,qword ptr [RBP + -0x360]
LAB_00172890:
CALL 0x001695e0
LAB_00172895:
JMP 0x00172897
LAB_00172897:
LEA RDI,[RBP + -0x288]
CALL 0x00121650
LEA RDI,[RBP + -0x2c8]
CALL 0x001219e0
LEA RDI,[RBP + -0x2e8]
CALL 0x0010dbc8
MOV RDI,qword ptr [RBP + -0x2f8]
ADD RDI,0x10
CALL 0x0010d7d0
JMP 0x00172919
default:
ADD RSP,0x380
POP RBP
RET
|
/* ftxui::TerminalInputParser::Send(ftxui::TerminalInputParser::Output) */
void ftxui::TerminalInputParser::Send
(unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>,std::default_delete<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>>>
*param_1)
{
ulong uVar1;
long lVar2;
SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>> *pSVar3;
int4 uStack0000000000000008;
int4 uStack000000000000000c;
int4 in_stack_00000010;
string local_2f0 [32];
Event local_2d0 [64];
variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask> local_290 [72];
int8 local_248;
string local_228 [32];
Event local_208 [64];
variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask> local_1c8 [72];
string local_180 [32];
Event local_160 [64];
variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask> local_120 [72];
int8 local_d8;
int8 local_d0 [3];
string local_b8 [32];
Event local_98 [64];
variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask> local_58 [72];
unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>,std::default_delete<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>>>
*local_10;
local_10 = param_1;
switch(uStack0000000000000008) {
case 0:
break;
case 1:
std::__cxx11::string::clear();
break;
case 2:
pSVar3 = (SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>> *)
std::
unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>,std::default_delete<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>>>
::operator->(param_1);
std::__cxx11::string::string(local_b8,(string *)(param_1 + 0x10));
/* try { // try from 001724c1 to 001724cc has its CatchHandler @ 00172531 */
Event::Character(local_98,local_b8);
std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>::
variant<ftxui::Event,void,void,ftxui::Event,void>(local_58,local_98);
/* try { // try from 001724f4 to 001724f8 has its CatchHandler @ 00172545 */
SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>::Send
(pSVar3,local_58);
std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>::~variant(local_58);
Event::~Event(local_98);
std::__cxx11::string::~string(local_b8);
std::__cxx11::string::clear();
break;
case 3:
local_d0[0] = std::
map<std::__cxx11::string,std::__cxx11::string,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
::find((map<std::__cxx11::string,std::__cxx11::string,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
*)g_uniformize_abi_cxx11_,(string *)(param_1 + 0x10));
local_d8 = std::
map<std::__cxx11::string,std::__cxx11::string,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
::end((map<std::__cxx11::string,std::__cxx11::string,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>
*)g_uniformize_abi_cxx11_);
uVar1 = std::operator!=((_Rb_tree_const_iterator *)local_d0,(_Rb_tree_const_iterator *)&local_d8
);
if ((uVar1 & 1) != 0) {
lVar2 = std::
_Rb_tree_const_iterator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>::
operator->((_Rb_tree_const_iterator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>
*)local_d0);
std::__cxx11::string::operator=((string *)(param_1 + 0x10),(string *)(lVar2 + 0x20));
}
pSVar3 = (SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>> *)
std::
unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>,std::default_delete<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>>>
::operator->(param_1);
std::__cxx11::string::string(local_180,(string *)(param_1 + 0x10));
/* try { // try from 00172622 to 0017262d has its CatchHandler @ 00172698 */
Event::Special(local_160,local_180);
std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>::
variant<ftxui::Event,void,void,ftxui::Event,void>(local_120,local_160);
/* try { // try from 00172658 to 0017265c has its CatchHandler @ 001726ac */
SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>::Send
(pSVar3,local_120);
std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>::~variant(local_120);
Event::~Event(local_160);
std::__cxx11::string::~string(local_180);
std::__cxx11::string::clear();
break;
case 4:
pSVar3 = (SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>> *)
std::
unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>,std::default_delete<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>>>
::operator->(param_1);
std::__cxx11::string::string(local_228,(string *)(param_1 + 0x10));
local_248 = CONCAT44(in_stack_00000010,uStack000000000000000c);
/* try { // try from 0017273a to 0017275b has its CatchHandler @ 001727c6 */
Event::Mouse(local_208,local_228);
std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>::
variant<ftxui::Event,void,void,ftxui::Event,void>(local_1c8,local_208);
/* try { // try from 00172786 to 0017278a has its CatchHandler @ 001727da */
SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>::Send
(pSVar3,local_1c8);
std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>::~variant(local_1c8);
Event::~Event(local_208);
std::__cxx11::string::~string(local_228);
std::__cxx11::string::clear();
break;
case 5:
pSVar3 = (SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>> *)
std::
unique_ptr<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>,std::default_delete<ftxui::SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>>>
::operator->(param_1);
std::__cxx11::string::string(local_2f0,(string *)(param_1 + 0x10));
/* try { // try from 0017285a to 00172865 has its CatchHandler @ 001728cd */
Event::CursorReporting(local_2d0,local_2f0,uStack000000000000000c,in_stack_00000010);
std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>::
variant<ftxui::Event,void,void,ftxui::Event,void>(local_290,local_2d0);
/* try { // try from 00172890 to 00172894 has its CatchHandler @ 001728e1 */
SenderImpl<std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>>::Send
(pSVar3,local_290);
std::variant<ftxui::Event,std::function<void()>,ftxui::AnimationTask>::~variant(local_290);
Event::~Event(local_2d0);
std::__cxx11::string::~string(local_2f0);
std::__cxx11::string::clear();
}
return;
}
| |
21,443 | unicode_prop1 | bluesky950520[P]quickjs/libunicode.c | static int unicode_prop1(CharRange *cr, int prop_idx)
{
const uint8_t *p, *p_end;
uint32_t c, c0, b, bit;
p = unicode_prop_table[prop_idx];
p_end = p + unicode_prop_len_table[prop_idx];
c = 0;
bit = 0;
while (p < p_end) {
c0 = c;
b = *p++;
if (b < 64) {
c += (b >> 3) + 1;
if (bit) {
if (cr_add_interval(cr, c0, c))
return -1;
}
bit ^= 1;
c0 = c;
c += (b & 7) + 1;
} else if (b >= 0x80) {
c += b - 0x80 + 1;
} else if (b < 0x60) {
c += (((b - 0x40) << 8) | p[0]) + 1;
p++;
} else {
c += (((b - 0x60) << 16) | (p[0] << 8) | p[1]) + 1;
p += 2;
}
if (bit) {
if (cr_add_interval(cr, c0, c))
return -1;
}
bit ^= 1;
}
return 0;
} | O3 | c | unicode_prop1:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movslq %esi, %rax
leaq 0x31aed(%rip), %rcx # 0xcdc20
movq (%rcx,%rax,8), %r15
leaq 0x115e2(%rip), %rcx # 0xad720
movzwl (%rcx,%rax,2), %edi
addq %r15, %rdi
xorl %ebp, %ebp
xorl %r12d, %r12d
movq %rdi, (%rsp)
leaq 0x1(%r15), %r13
movzbl (%r15), %r14d
cmpl $0x3f, %r14d
ja 0x9c1c0
movl %r14d, %eax
shrl $0x3, %eax
leal (%r12,%rax), %r8d
incl %r8d
testl %ebp, %ebp
je 0x9c1ae
movl (%rbx), %eax
leal 0x2(%rax), %esi
cmpl 0x4(%rbx), %esi
jle 0x9c193
movq %r8, %r15
movq %rbx, %rdi
callq 0x9a333
testl %eax, %eax
jne 0x9c26a
movl (%rbx), %eax
movq (%rsp), %rdi
movq %r15, %r8
movq 0x8(%rbx), %rcx
leal 0x1(%rax), %edx
movl %edx, (%rbx)
cltq
movl %r12d, (%rcx,%rax,4)
movslq (%rbx), %rax
leal 0x1(%rax), %edx
movl %edx, (%rbx)
movl %r8d, (%rcx,%rax,4)
xorl $0x1, %ebp
andl $0x7, %r14d
addl %r8d, %r14d
incl %r14d
movq %r13, %r15
jmp 0x9c216
testb %r14b, %r14b
js 0x9c1e7
movzbl (%r13), %eax
cmpb $0x5f, %r14b
ja 0x9c1f3
shll $0x8, %r14d
addl %r12d, %r14d
addl %eax, %r14d
addl $0xffffc001, %r14d # imm = 0xFFFFC001
addq $0x2, %r15
jmp 0x9c213
addl %r12d, %r14d
addl $-0x7f, %r14d
movq %r13, %r15
jmp 0x9c213
shll $0x10, %r14d
shll $0x8, %eax
movzbl 0x2(%r15), %ecx
addl %r12d, %r14d
addl %eax, %r14d
addl %ecx, %r14d
addl $0xffa00001, %r14d # imm = 0xFFA00001
addq $0x3, %r15
movl %r12d, %r8d
testl %ebp, %ebp
je 0x9c257
movl (%rbx), %eax
leal 0x2(%rax), %esi
cmpl 0x4(%rbx), %esi
jle 0x9c23c
movq %r8, %r12
movq %rbx, %rdi
callq 0x9a333
testl %eax, %eax
jne 0x9c26a
movl (%rbx), %eax
movq (%rsp), %rdi
movq %r12, %r8
movq 0x8(%rbx), %rcx
leal 0x1(%rax), %edx
movl %edx, (%rbx)
cltq
movl %r8d, (%rcx,%rax,4)
movslq (%rbx), %rax
leal 0x1(%rax), %edx
movl %edx, (%rbx)
movl %r14d, (%rcx,%rax,4)
xorl $0x1, %ebp
movl %r14d, %r12d
cmpq %rdi, %r15
jb 0x9c14e
xorl %eax, %eax
jmp 0x9c26f
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| unicode_prop1:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rdi
movsxd rax, esi
lea rcx, unicode_prop_table
mov r15, [rcx+rax*8]
lea rcx, unicode_prop_len_table
movzx edi, word ptr [rcx+rax*2]
add rdi, r15
xor ebp, ebp
xor r12d, r12d
mov [rsp+38h+var_38], rdi
loc_9C14E:
lea r13, [r15+1]
movzx r14d, byte ptr [r15]
cmp r14d, 3Fh ; '?'
ja short loc_9C1C0
mov eax, r14d
shr eax, 3
lea r8d, [r12+rax]
inc r8d
test ebp, ebp
jz short loc_9C1AE
mov eax, [rbx]
lea esi, [rax+2]
cmp esi, [rbx+4]
jle short loc_9C193
mov r15, r8
mov rdi, rbx
call cr_realloc
test eax, eax
jnz loc_9C26A
mov eax, [rbx]
mov rdi, [rsp+38h+var_38]
mov r8, r15
loc_9C193:
mov rcx, [rbx+8]
lea edx, [rax+1]
mov [rbx], edx
cdqe
mov [rcx+rax*4], r12d
movsxd rax, dword ptr [rbx]
lea edx, [rax+1]
mov [rbx], edx
mov [rcx+rax*4], r8d
loc_9C1AE:
xor ebp, 1
and r14d, 7
add r14d, r8d
inc r14d
mov r15, r13
jmp short loc_9C216
loc_9C1C0:
test r14b, r14b
js short loc_9C1E7
movzx eax, byte ptr [r13+0]
cmp r14b, 5Fh ; '_'
ja short loc_9C1F3
shl r14d, 8
add r14d, r12d
add r14d, eax
add r14d, 0FFFFC001h
add r15, 2
jmp short loc_9C213
loc_9C1E7:
add r14d, r12d
add r14d, 0FFFFFF81h
mov r15, r13
jmp short loc_9C213
loc_9C1F3:
shl r14d, 10h
shl eax, 8
movzx ecx, byte ptr [r15+2]
add r14d, r12d
add r14d, eax
add r14d, ecx
add r14d, 0FFA00001h
add r15, 3
loc_9C213:
mov r8d, r12d
loc_9C216:
test ebp, ebp
jz short loc_9C257
mov eax, [rbx]
lea esi, [rax+2]
cmp esi, [rbx+4]
jle short loc_9C23C
mov r12, r8
mov rdi, rbx
call cr_realloc
test eax, eax
jnz short loc_9C26A
mov eax, [rbx]
mov rdi, [rsp+38h+var_38]
mov r8, r12
loc_9C23C:
mov rcx, [rbx+8]
lea edx, [rax+1]
mov [rbx], edx
cdqe
mov [rcx+rax*4], r8d
movsxd rax, dword ptr [rbx]
lea edx, [rax+1]
mov [rbx], edx
mov [rcx+rax*4], r14d
loc_9C257:
xor ebp, 1
mov r12d, r14d
cmp r15, rdi
jb loc_9C14E
xor eax, eax
jmp short loc_9C26F
loc_9C26A:
mov eax, 0FFFFFFFFh
loc_9C26F:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long unicode_prop1(int *a1, int a2)
{
unsigned __int8 *v3; // r15
unsigned __int8 *v4; // rdi
int v5; // ebp
int v6; // r12d
unsigned int v7; // r14d
int v8; // r8d
int v9; // eax
int v10; // esi
long long v11; // rcx
long long v12; // rax
int v13; // r14d
int v14; // eax
int v15; // eax
int v16; // esi
int v17; // r12d
long long v18; // rcx
long long v19; // rax
unsigned __int8 *v21; // [rsp+0h] [rbp-38h]
v3 = (unsigned __int8 *)*(&unicode_prop_table + a2);
v4 = &v3[unicode_prop_len_table[a2]];
v5 = 0;
v6 = 0;
v21 = v4;
while ( 1 )
{
v7 = *v3;
if ( v7 > 0x3F )
{
if ( (v7 & 0x80u) != 0 )
{
v13 = v6 + v7 - 127;
++v3;
}
else
{
v14 = v3[1];
if ( (unsigned __int8)v7 > 0x5Fu )
{
v13 = v3[2] + (v14 << 8) + v6 + (v7 << 16) - 6291455;
v3 += 3;
}
else
{
v13 = v14 + v6 + (v7 << 8) - 0x3FFF;
v3 += 2;
}
}
v8 = v6;
}
else
{
v8 = v6 + (v7 >> 3) + 1;
if ( v5 )
{
v9 = *a1;
v10 = *a1 + 2;
if ( v10 > a1[1] )
{
if ( (unsigned int)cr_realloc((long long)a1, v10) )
return 0xFFFFFFFFLL;
v9 = *a1;
v4 = v21;
v8 = v6 + (v7 >> 3) + 1;
}
v11 = *((_QWORD *)a1 + 1);
*a1 = v9 + 1;
*(_DWORD *)(v11 + 4LL * v9) = v6;
v12 = *a1;
*a1 = v12 + 1;
*(_DWORD *)(v11 + 4 * v12) = v8;
}
v5 ^= 1u;
v13 = v8 + (v7 & 7) + 1;
++v3;
}
if ( v5 )
break;
LABEL_20:
v5 ^= 1u;
v6 = v13;
if ( v3 >= v4 )
return 0LL;
}
v15 = *a1;
v16 = *a1 + 2;
if ( v16 <= a1[1] )
{
LABEL_19:
v18 = *((_QWORD *)a1 + 1);
*a1 = v15 + 1;
*(_DWORD *)(v18 + 4LL * v15) = v8;
v19 = *a1;
*a1 = v19 + 1;
*(_DWORD *)(v18 + 4 * v19) = v13;
goto LABEL_20;
}
v17 = v8;
if ( !(unsigned int)cr_realloc((long long)a1, v16) )
{
v15 = *a1;
v4 = v21;
v8 = v17;
goto LABEL_19;
}
return 0xFFFFFFFFLL;
}
| unicode_prop1:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOVSXD RAX,ESI
LEA RCX,[0x1cdc20]
MOV R15,qword ptr [RCX + RAX*0x8]
LEA RCX,[0x1ad720]
MOVZX EDI,word ptr [RCX + RAX*0x2]
ADD RDI,R15
XOR EBP,EBP
XOR R12D,R12D
MOV qword ptr [RSP],RDI
LAB_0019c14e:
LEA R13,[R15 + 0x1]
MOVZX R14D,byte ptr [R15]
CMP R14D,0x3f
JA 0x0019c1c0
MOV EAX,R14D
SHR EAX,0x3
LEA R8D,[R12 + RAX*0x1]
INC R8D
TEST EBP,EBP
JZ 0x0019c1ae
MOV EAX,dword ptr [RBX]
LEA ESI,[RAX + 0x2]
CMP ESI,dword ptr [RBX + 0x4]
JLE 0x0019c193
MOV R15,R8
MOV RDI,RBX
CALL 0x0019a333
TEST EAX,EAX
JNZ 0x0019c26a
MOV EAX,dword ptr [RBX]
MOV RDI,qword ptr [RSP]
MOV R8,R15
LAB_0019c193:
MOV RCX,qword ptr [RBX + 0x8]
LEA EDX,[RAX + 0x1]
MOV dword ptr [RBX],EDX
CDQE
MOV dword ptr [RCX + RAX*0x4],R12D
MOVSXD RAX,dword ptr [RBX]
LEA EDX,[RAX + 0x1]
MOV dword ptr [RBX],EDX
MOV dword ptr [RCX + RAX*0x4],R8D
LAB_0019c1ae:
XOR EBP,0x1
AND R14D,0x7
ADD R14D,R8D
INC R14D
MOV R15,R13
JMP 0x0019c216
LAB_0019c1c0:
TEST R14B,R14B
JS 0x0019c1e7
MOVZX EAX,byte ptr [R13]
CMP R14B,0x5f
JA 0x0019c1f3
SHL R14D,0x8
ADD R14D,R12D
ADD R14D,EAX
ADD R14D,0xffffc001
ADD R15,0x2
JMP 0x0019c213
LAB_0019c1e7:
ADD R14D,R12D
ADD R14D,-0x7f
MOV R15,R13
JMP 0x0019c213
LAB_0019c1f3:
SHL R14D,0x10
SHL EAX,0x8
MOVZX ECX,byte ptr [R15 + 0x2]
ADD R14D,R12D
ADD R14D,EAX
ADD R14D,ECX
ADD R14D,0xffa00001
ADD R15,0x3
LAB_0019c213:
MOV R8D,R12D
LAB_0019c216:
TEST EBP,EBP
JZ 0x0019c257
MOV EAX,dword ptr [RBX]
LEA ESI,[RAX + 0x2]
CMP ESI,dword ptr [RBX + 0x4]
JLE 0x0019c23c
MOV R12,R8
MOV RDI,RBX
CALL 0x0019a333
TEST EAX,EAX
JNZ 0x0019c26a
MOV EAX,dword ptr [RBX]
MOV RDI,qword ptr [RSP]
MOV R8,R12
LAB_0019c23c:
MOV RCX,qword ptr [RBX + 0x8]
LEA EDX,[RAX + 0x1]
MOV dword ptr [RBX],EDX
CDQE
MOV dword ptr [RCX + RAX*0x4],R8D
MOVSXD RAX,dword ptr [RBX]
LEA EDX,[RAX + 0x1]
MOV dword ptr [RBX],EDX
MOV dword ptr [RCX + RAX*0x4],R14D
LAB_0019c257:
XOR EBP,0x1
MOV R12D,R14D
CMP R15,RDI
JC 0x0019c14e
XOR EAX,EAX
JMP 0x0019c26f
LAB_0019c26a:
MOV EAX,0xffffffff
LAB_0019c26f:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8 unicode_prop1(int *param_1,int param_2)
{
byte bVar1;
byte bVar2;
ushort uVar3;
byte *pbVar4;
long lVar5;
bool bVar6;
int iVar7;
int iVar8;
int iVar9;
uint uVar10;
byte *pbVar11;
byte *pbVar12;
pbVar4 = *(byte **)(unicode_prop_table + (long)param_2 * 8);
uVar3 = *(ushort *)(unicode_prop_len_table + (long)param_2 * 2);
bVar6 = false;
iVar9 = 0;
pbVar11 = pbVar4;
do {
pbVar12 = pbVar11 + 1;
bVar1 = *pbVar11;
uVar10 = (uint)bVar1;
if (bVar1 < 0x40) {
iVar8 = iVar9 + (uint)(bVar1 >> 3) + 1;
if (bVar6) {
iVar7 = *param_1;
if (param_1[1] < iVar7 + 2) {
iVar7 = cr_realloc(param_1);
if (iVar7 != 0) {
return 0xffffffff;
}
iVar7 = *param_1;
}
lVar5 = *(long *)(param_1 + 2);
*param_1 = iVar7 + 1;
*(int *)(lVar5 + (long)iVar7 * 4) = iVar9;
iVar9 = *param_1;
*param_1 = iVar9 + 1;
*(int *)(lVar5 + (long)iVar9 * 4) = iVar8;
}
bVar6 = (bool)(bVar6 ^ 1);
iVar9 = (uVar10 & 7) + iVar8 + 1;
}
else {
iVar8 = iVar9;
if ((char)bVar1 < '\0') {
iVar9 = (uint)bVar1 + iVar9 + -0x7f;
}
else {
bVar2 = *pbVar12;
if (bVar1 < 0x60) {
pbVar12 = pbVar11 + 2;
iVar9 = uVar10 * 0x100 + iVar9 + (uint)bVar2 + -0x3fff;
}
else {
pbVar12 = pbVar11 + 3;
iVar9 = uVar10 * 0x10000 + iVar9 + (uint)bVar2 * 0x100 + (uint)pbVar11[2] + -0x5fffff;
}
}
}
if (bVar6) {
iVar7 = *param_1;
if (param_1[1] < iVar7 + 2) {
iVar7 = cr_realloc(param_1);
if (iVar7 != 0) {
return 0xffffffff;
}
iVar7 = *param_1;
}
lVar5 = *(long *)(param_1 + 2);
*param_1 = iVar7 + 1;
*(int *)(lVar5 + (long)iVar7 * 4) = iVar8;
iVar8 = *param_1;
*param_1 = iVar8 + 1;
*(int *)(lVar5 + (long)iVar8 * 4) = iVar9;
}
bVar6 = (bool)(bVar6 ^ 1);
pbVar11 = pbVar12;
} while (pbVar12 < pbVar4 + uVar3);
return 0;
}
| |
21,444 | find_test_files | bluesky950520[P]quickjs/run-test262.c | static void find_test_files(const char *path)
{
#ifdef _WIN32
WIN32_FIND_DATAA d;
HANDLE h;
char s[1024];
snprintf(s, sizeof(s), "%s/*", path);
h = FindFirstFileA(s, &d);
if (h != INVALID_HANDLE_VALUE) {
do {
consider_test_file(path,
d.cFileName,
d.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY);
} while (FindNextFileA(h, &d));
FindClose(h);
}
#else
struct dirent *d, **ds = NULL;
int i, n;
n = scandir(path, &ds, NULL, alphasort);
for (i = 0; i < n; i++) {
d = ds[i];
consider_test_file(path, d->d_name, d->d_type == DT_DIR);
free(d);
}
free(ds);
#endif
} | O0 | c | find_test_files:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq $0x0, 0x10(%rsp)
movq 0x20(%rsp), %rdi
leaq 0x10(%rsp), %rsi
xorl %eax, %eax
movl %eax, %edx
movq 0x1289f9(%rip), %rcx # 0x13cfd0
callq 0xe3a0
movl %eax, 0x8(%rsp)
movl $0x0, 0xc(%rsp)
movl 0xc(%rsp), %eax
cmpl 0x8(%rsp), %eax
jge 0x14643
movq 0x10(%rsp), %rax
movslq 0xc(%rsp), %rcx
movq (%rax,%rcx,8), %rax
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rsi
addq $0x13, %rsi
movq 0x18(%rsp), %rax
movzbl 0x12(%rax), %eax
cmpl $0x4, %eax
sete %al
andb $0x1, %al
movzbl %al, %edx
callq 0x14660
movq 0x18(%rsp), %rdi
callq 0xe060
movl 0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xc(%rsp)
jmp 0x145e8
movq 0x10(%rsp), %rdi
callq 0xe060
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
| find_test_files:
sub rsp, 28h
mov [rsp+28h+var_8], rdi
mov [rsp+28h+var_18], 0
mov rdi, [rsp+28h+var_8]
lea rsi, [rsp+28h+var_18]
xor eax, eax
mov edx, eax
mov rcx, cs:alphasort_ptr
call _scandir
mov [rsp+28h+var_20], eax
mov [rsp+28h+var_1C], 0
loc_145E8:
mov eax, [rsp+28h+var_1C]
cmp eax, [rsp+28h+var_20]
jge short loc_14643
mov rax, [rsp+28h+var_18]
movsxd rcx, [rsp+28h+var_1C]
mov rax, [rax+rcx*8]
mov [rsp+28h+var_10], rax
mov rdi, [rsp+28h+var_8]
mov rsi, [rsp+28h+var_10]
add rsi, 13h
mov rax, [rsp+28h+var_10]
movzx eax, byte ptr [rax+12h]
cmp eax, 4
setz al
and al, 1
movzx edx, al
call consider_test_file
mov rdi, [rsp+28h+var_10]
call _free
mov eax, [rsp+28h+var_1C]
add eax, 1
mov [rsp+28h+var_1C], eax
jmp short loc_145E8
loc_14643:
mov rdi, [rsp+28h+var_18]
call _free
add rsp, 28h
retn
| long long find_test_files(long long a1)
{
int v2; // [rsp+8h] [rbp-20h]
int i; // [rsp+Ch] [rbp-1Ch]
long long v4; // [rsp+10h] [rbp-18h] BYREF
long long v5; // [rsp+18h] [rbp-10h]
long long v6; // [rsp+20h] [rbp-8h]
v6 = a1;
v4 = 0LL;
v2 = scandir(a1, &v4, 0LL, &alphasort);
for ( i = 0; i < v2; ++i )
{
v5 = *(_QWORD *)(v4 + 8LL * i);
consider_test_file(v6, v5 + 19, *(unsigned __int8 *)(v5 + 18) == 4);
free(v5);
}
return free(v4);
}
| find_test_files:
SUB RSP,0x28
MOV qword ptr [RSP + 0x20],RDI
MOV qword ptr [RSP + 0x10],0x0
MOV RDI,qword ptr [RSP + 0x20]
LEA RSI,[RSP + 0x10]
XOR EAX,EAX
MOV EDX,EAX
MOV RCX,qword ptr [0x0023cfd0]
CALL 0x0010e3a0
MOV dword ptr [RSP + 0x8],EAX
MOV dword ptr [RSP + 0xc],0x0
LAB_001145e8:
MOV EAX,dword ptr [RSP + 0xc]
CMP EAX,dword ptr [RSP + 0x8]
JGE 0x00114643
MOV RAX,qword ptr [RSP + 0x10]
MOVSXD RCX,dword ptr [RSP + 0xc]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RSP + 0x18],RAX
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x18]
ADD RSI,0x13
MOV RAX,qword ptr [RSP + 0x18]
MOVZX EAX,byte ptr [RAX + 0x12]
CMP EAX,0x4
SETZ AL
AND AL,0x1
MOVZX EDX,AL
CALL 0x00114660
MOV RDI,qword ptr [RSP + 0x18]
CALL 0x0010e060
MOV EAX,dword ptr [RSP + 0xc]
ADD EAX,0x1
MOV dword ptr [RSP + 0xc],EAX
JMP 0x001145e8
LAB_00114643:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x0010e060
ADD RSP,0x28
RET
|
void find_test_files(char *param_1)
{
int iVar1;
int local_1c;
dirent **local_18;
dirent *local_10;
char *local_8;
local_18 = (dirent **)0x0;
local_8 = param_1;
iVar1 = scandir(param_1,&local_18,(__selector *)0x0,(__cmp *)PTR_alphasort_0023cfd0);
for (local_1c = 0; local_1c < iVar1; local_1c = local_1c + 1) {
local_10 = local_18[local_1c];
consider_test_file(local_8,local_10->d_name,local_10->d_type == '\x04');
free(local_10);
}
free(local_18);
return;
}
| |
21,445 | find_test_files | bluesky950520[P]quickjs/run-test262.c | static void find_test_files(const char *path)
{
#ifdef _WIN32
WIN32_FIND_DATAA d;
HANDLE h;
char s[1024];
snprintf(s, sizeof(s), "%s/*", path);
h = FindFirstFileA(s, &d);
if (h != INVALID_HANDLE_VALUE) {
do {
consider_test_file(path,
d.cFileName,
d.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY);
} while (FindNextFileA(h, &d));
FindClose(h);
}
#else
struct dirent *d, **ds = NULL;
int i, n;
n = scandir(path, &ds, NULL, alphasort);
for (i = 0; i < n; i++) {
d = ds[i];
consider_test_file(path, d->d_name, d->d_type == DT_DIR);
free(d);
}
free(ds);
#endif
} | O1 | c | find_test_files:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x428, %rsp # imm = 0x428
leaq 0x10(%rsp), %rsi
movq $0x0, (%rsi)
movq 0xba580(%rip), %rcx # 0xd1fd0
movq %rdi, 0x18(%rsp)
xorl %edx, %edx
callq 0xe3b0
testl %eax, %eax
jle 0x17b3e
movl %eax, %r15d
leaq 0x8d3e6(%rip), %r14 # 0xa4e54
xorl %ebx, %ebx
movq %r15, 0x8(%rsp)
movq 0x10(%rsp), %rax
movq (%rax,%rbx,8), %rbp
leaq 0x13(%rbp), %r12
movb 0x12(%rbp), %r13b
movq %r12, %rdi
movq %r14, %rsi
callq 0xe570
testl %eax, %eax
je 0x17b2a
movq %r12, %rdi
leaq 0x8d3b0(%rip), %rsi # 0xa4e53
callq 0xe570
testl %eax, %eax
je 0x17b2a
movq %r14, %r15
movl $0x400, %esi # imm = 0x400
leaq 0x20(%rsp), %r14
movq %r14, %rdi
leaq 0x87d77(%rip), %rdx # 0x9f83a
movq 0x18(%rsp), %rcx
movq %r12, %r8
xorl %eax, %eax
callq 0xe300
movq %r14, %rdi
cmpb $0x4, %r13b
jne 0x17aea
callq 0x17a2c
movq %r15, %r14
movq 0x8(%rsp), %r15
jmp 0x17b2a
leaq 0x87d57(%rip), %rsi # 0x9f848
callq 0x1f342
testl %eax, %eax
movq %r15, %r14
movq 0x8(%rsp), %r15
je 0x17b2a
leaq 0x20(%rsp), %rdi
leaq 0x87d32(%rip), %rsi # 0x9f840
callq 0x1f342
testl %eax, %eax
jne 0x17b2a
leaq 0xbaaaa(%rip), %rdi # 0xd25c8
xorl %esi, %esi
leaq 0x20(%rsp), %rdx
callq 0x14308
movq %rbp, %rdi
callq 0xe060
incq %rbx
cmpq %rbx, %r15
jne 0x17a75
movq 0x10(%rsp), %rdi
callq 0xe060
addq $0x428, %rsp # imm = 0x428
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| find_test_files:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 428h
lea rsi, [rsp+458h+var_448]
mov qword ptr [rsi], 0
mov rcx, cs:alphasort_ptr
mov [rsp+458h+var_440], rdi
xor edx, edx
call _scandir
test eax, eax
jle loc_17B3E
mov r15d, eax
lea r14, aMissingBinding+19h; "."
xor ebx, ebx
mov [rsp+458h+var_450], r15
loc_17A75:
mov rax, [rsp+458h+var_448]
mov rbp, [rax+rbx*8]
lea r12, [rbp+13h]
mov r13b, [rbp+12h]
mov rdi, r12
mov rsi, r14
call _strcmp
test eax, eax
jz loc_17B2A
mov rdi, r12
lea rsi, aMissingBinding+18h; ".."
call _strcmp
test eax, eax
jz short loc_17B2A
mov r15, r14
mov esi, 400h
lea r14, [rsp+458h+var_438]
mov rdi, r14
lea rdx, aSS_1; "%s/%s"
mov rcx, [rsp+458h+var_440]
mov r8, r12
xor eax, eax
call _snprintf
mov rdi, r14
cmp r13b, 4
jnz short loc_17AEA
call find_test_files
mov r14, r15
mov r15, [rsp+458h+var_450]
jmp short loc_17B2A
loc_17AEA:
lea rsi, aFixtureJs+8; ".js"
call js__has_suffix
test eax, eax
mov r14, r15
mov r15, [rsp+458h+var_450]
jz short loc_17B2A
lea rdi, [rsp+458h+var_438]
lea rsi, aFixtureJs; "_FIXTURE.js"
call js__has_suffix
test eax, eax
jnz short loc_17B2A
lea rdi, test_list
xor esi, esi
lea rdx, [rsp+458h+var_438]
call namelist_add
loc_17B2A:
mov rdi, rbp
call _free
inc rbx
cmp r15, rbx
jnz loc_17A75
loc_17B3E:
mov rdi, [rsp+458h+var_448]
call _free
add rsp, 428h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long find_test_files(
const char *a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
double a6,
double a7,
__m128 a8,
__m128 a9)
{
int v9; // eax
long long v10; // r15
long long v11; // rbx
long long v12; // rbp
char v13; // r13
double v14; // xmm4_8
double v15; // xmm5_8
long long v17; // [rsp+8h] [rbp-450h]
long long v18; // [rsp+10h] [rbp-448h] BYREF
const char *v19; // [rsp+18h] [rbp-440h]
_BYTE v20[1080]; // [rsp+20h] [rbp-438h] BYREF
v18 = 0LL;
v19 = a1;
v9 = scandir(a1, &v18, 0LL, &alphasort);
if ( v9 > 0 )
{
v10 = (unsigned int)v9;
v11 = 0LL;
v17 = (unsigned int)v9;
do
{
v12 = *(_QWORD *)(v18 + 8 * v11);
v13 = *(_BYTE *)(v12 + 18);
if ( (unsigned int)strcmp(v12 + 19, ".") && (unsigned int)strcmp(v12 + 19, "..") )
{
snprintf(v20, 1024LL, "%s/%s", v19, (const char *)(v12 + 19));
if ( v13 == 4 )
{
find_test_files(v20);
v10 = v17;
}
else
{
v10 = v17;
if ( (unsigned int)js__has_suffix(v20, ".js") && !(unsigned int)js__has_suffix(v20, "_FIXTURE.js") )
namelist_add((long long)&test_list, 0LL, v20, a2, a3, a4, a5, v14, v15, a8, a9);
}
}
free(v12);
++v11;
}
while ( v10 != v11 );
}
return free(v18);
}
| find_test_files:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x428
LEA RSI,[RSP + 0x10]
MOV qword ptr [RSI],0x0
MOV RCX,qword ptr [0x001d1fd0]
MOV qword ptr [RSP + 0x18],RDI
XOR EDX,EDX
CALL 0x0010e3b0
TEST EAX,EAX
JLE 0x00117b3e
MOV R15D,EAX
LEA R14,[0x1a4e54]
XOR EBX,EBX
MOV qword ptr [RSP + 0x8],R15
LAB_00117a75:
MOV RAX,qword ptr [RSP + 0x10]
MOV RBP,qword ptr [RAX + RBX*0x8]
LEA R12,[RBP + 0x13]
MOV R13B,byte ptr [RBP + 0x12]
MOV RDI,R12
MOV RSI,R14
CALL 0x0010e570
TEST EAX,EAX
JZ 0x00117b2a
MOV RDI,R12
LEA RSI,[0x1a4e53]
CALL 0x0010e570
TEST EAX,EAX
JZ 0x00117b2a
MOV R15,R14
MOV ESI,0x400
LEA R14,[RSP + 0x20]
MOV RDI,R14
LEA RDX,[0x19f83a]
MOV RCX,qword ptr [RSP + 0x18]
MOV R8,R12
XOR EAX,EAX
CALL 0x0010e300
MOV RDI,R14
CMP R13B,0x4
JNZ 0x00117aea
CALL 0x00117a2c
MOV R14,R15
MOV R15,qword ptr [RSP + 0x8]
JMP 0x00117b2a
LAB_00117aea:
LEA RSI,[0x19f848]
CALL 0x0011f342
TEST EAX,EAX
MOV R14,R15
MOV R15,qword ptr [RSP + 0x8]
JZ 0x00117b2a
LEA RDI,[RSP + 0x20]
LEA RSI,[0x19f840]
CALL 0x0011f342
TEST EAX,EAX
JNZ 0x00117b2a
LEA RDI,[0x1d25c8]
XOR ESI,ESI
LEA RDX,[RSP + 0x20]
CALL 0x00114308
LAB_00117b2a:
MOV RDI,RBP
CALL 0x0010e060
INC RBX
CMP R15,RBX
JNZ 0x00117a75
LAB_00117b3e:
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x0010e060
ADD RSP,0x428
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void find_test_files(char *param_1)
{
char *__s1;
uchar uVar1;
dirent *__ptr;
uint uVar2;
int iVar3;
ulong uVar4;
dirent **local_448;
char *local_440;
char local_438 [1032];
local_448 = (dirent **)0x0;
local_440 = param_1;
uVar2 = scandir(param_1,&local_448,(__selector *)0x0,(__cmp *)PTR_alphasort_001d1fd0);
if (0 < (int)uVar2) {
uVar4 = 0;
do {
__ptr = local_448[uVar4];
__s1 = __ptr->d_name;
uVar1 = __ptr->d_type;
iVar3 = strcmp(__s1,".");
if (iVar3 != 0) {
iVar3 = strcmp(__s1,"..");
if (iVar3 != 0) {
snprintf(local_438,0x400,"%s/%s",local_440,__s1);
if (uVar1 == '\x04') {
find_test_files();
}
else {
iVar3 = js__has_suffix(local_438,".js");
if (iVar3 != 0) {
iVar3 = js__has_suffix(local_438,"_FIXTURE.js");
if (iVar3 == 0) {
namelist_add(&test_list,0,local_438);
}
}
}
}
}
free(__ptr);
uVar4 = uVar4 + 1;
} while (uVar2 != uVar4);
}
free(local_448);
return;
}
| |
21,446 | find_test_files | bluesky950520[P]quickjs/run-test262.c | static void find_test_files(const char *path)
{
#ifdef _WIN32
WIN32_FIND_DATAA d;
HANDLE h;
char s[1024];
snprintf(s, sizeof(s), "%s/*", path);
h = FindFirstFileA(s, &d);
if (h != INVALID_HANDLE_VALUE) {
do {
consider_test_file(path,
d.cFileName,
d.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY);
} while (FindNextFileA(h, &d));
FindClose(h);
}
#else
struct dirent *d, **ds = NULL;
int i, n;
n = scandir(path, &ds, NULL, alphasort);
for (i = 0; i < n; i++) {
d = ds[i];
consider_test_file(path, d->d_name, d->d_type == DT_DIR);
free(d);
}
free(ds);
#endif
} | O2 | c | find_test_files:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x428, %rsp # imm = 0x428
leaq 0x18(%rsp), %rsi
andq $0x0, (%rsi)
movq 0xac97f(%rip), %rcx # 0xbefd0
xorl %ebx, %ebx
movq %rdi, 0x10(%rsp)
xorl %edx, %edx
callq 0xe3c0
movl %eax, %r14d
testl %eax, %eax
cmovlel %ebx, %r14d
leaq 0x20(%rsp), %r15
xorl %ebp, %ebp
movq %r14, 0x8(%rsp)
movq 0x18(%rsp), %rdi
cmpq %rbp, %r14
je 0x12730
movq (%rdi,%rbp,8), %r13
leaq 0x13(%r13), %rbx
movb 0x12(%r13), %r12b
movq %rbx, %rdi
leaq 0x786f6(%rip), %rsi # 0x8ad8e
callq 0xfbbc
testl %eax, %eax
jne 0x12720
movq %rbx, %rdi
leaq 0x786e2(%rip), %rsi # 0x8ad8d
callq 0xfbbc
testl %eax, %eax
jne 0x12720
movl $0x400, %esi # imm = 0x400
movq %r15, %rdi
leaq 0x73160(%rip), %rdx # 0x85823
movq 0x10(%rsp), %rcx
movq %rbx, %r8
xorl %eax, %eax
callq 0xe310
movq %r15, %rdi
cmpb $0x4, %r12b
jne 0x126e7
callq 0x12630
movq 0x8(%rsp), %r14
jmp 0x12720
leaq 0x73143(%rip), %rsi # 0x85831
callq 0x19703
testl %eax, %eax
movq 0x8(%rsp), %r14
je 0x12720
movq %r15, %rdi
leaq 0x73123(%rip), %rsi # 0x85829
callq 0x19703
testl %eax, %eax
jne 0x12720
leaq 0xacec2(%rip), %rdi # 0xbf5d8
xorl %esi, %esi
movq %r15, %rdx
callq 0xf188
movq %r13, %rdi
callq 0xe060
incq %rbp
jmp 0x12674
callq 0xe060
addq $0x428, %rsp # imm = 0x428
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| find_test_files:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 428h
lea rsi, [rsp+458h+var_440]
and qword ptr [rsi], 0
mov rcx, cs:alphasort_ptr
xor ebx, ebx
mov [rsp+458h+var_448], rdi
xor edx, edx
call _scandir
mov r14d, eax
test eax, eax
cmovle r14d, ebx
lea r15, [rsp+458h+var_438]
xor ebp, ebp
mov [rsp+458h+var_450], r14
loc_12674:
mov rdi, [rsp+458h+var_440]
cmp r14, rbp
jz loc_12730
mov r13, [rdi+rbp*8]
lea rbx, [r13+13h]
mov r12b, [r13+12h]
mov rdi, rbx
lea rsi, aMissingBinding+19h; "."
call str_equal
test eax, eax
jnz short loc_12720
mov rdi, rbx
lea rsi, aMissingBinding+18h; ".."
call str_equal
test eax, eax
jnz short loc_12720
mov esi, 400h
mov rdi, r15
lea rdx, aSS_1; "%s/%s"
mov rcx, [rsp+458h+var_448]
mov r8, rbx
xor eax, eax
call _snprintf
mov rdi, r15
cmp r12b, 4
jnz short loc_126E7
call find_test_files
mov r14, [rsp+458h+var_450]
jmp short loc_12720
loc_126E7:
lea rsi, aFixtureJs+8; ".js"
call js__has_suffix
test eax, eax
mov r14, [rsp+458h+var_450]
jz short loc_12720
mov rdi, r15
lea rsi, aFixtureJs; "_FIXTURE.js"
call js__has_suffix
test eax, eax
jnz short loc_12720
lea rdi, test_list
xor esi, esi
mov rdx, r15
call namelist_add
loc_12720:
mov rdi, r13
call _free
inc rbp
jmp loc_12674
loc_12730:
call _free
add rsp, 428h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long find_test_files(
const char *a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
double a6,
double a7,
__m128 a8,
__m128 a9)
{
int v9; // eax
long long v10; // r14
long long v11; // rbp
long long v12; // r13
char v13; // r12
double v14; // xmm4_8
double v15; // xmm5_8
long long v17; // [rsp+8h] [rbp-450h]
long long v18; // [rsp+18h] [rbp-440h] BYREF
_BYTE v19[1080]; // [rsp+20h] [rbp-438h] BYREF
v18 = 0LL;
v9 = scandir(a1, &v18, 0LL, &alphasort);
v10 = (unsigned int)v9;
if ( v9 <= 0 )
v10 = 0LL;
v11 = 0LL;
v17 = v10;
while ( v10 != v11 )
{
v12 = *(_QWORD *)(v18 + 8 * v11);
v13 = *(_BYTE *)(v12 + 18);
if ( !str_equal(v12 + 19) && !str_equal(v12 + 19) )
{
snprintf(v19, 1024LL, "%s/%s", a1, (const char *)(v12 + 19));
if ( v13 == 4 )
{
find_test_files(v19);
v10 = v17;
}
else
{
v10 = v17;
if ( (unsigned int)js__has_suffix(v19, ".js") )
{
if ( !(unsigned int)js__has_suffix(v19, "_FIXTURE.js") )
namelist_add(&test_list, 0LL, v19, a2, a3, a4, a5, v14, v15, a8, a9);
}
}
}
free(v12);
++v11;
}
return free(v18);
}
| find_test_files:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x428
LEA RSI,[RSP + 0x18]
AND qword ptr [RSI],0x0
MOV RCX,qword ptr [0x001befd0]
XOR EBX,EBX
MOV qword ptr [RSP + 0x10],RDI
XOR EDX,EDX
CALL 0x0010e3c0
MOV R14D,EAX
TEST EAX,EAX
CMOVLE R14D,EBX
LEA R15,[RSP + 0x20]
XOR EBP,EBP
MOV qword ptr [RSP + 0x8],R14
LAB_00112674:
MOV RDI,qword ptr [RSP + 0x18]
CMP R14,RBP
JZ 0x00112730
MOV R13,qword ptr [RDI + RBP*0x8]
LEA RBX,[R13 + 0x13]
MOV R12B,byte ptr [R13 + 0x12]
MOV RDI,RBX
LEA RSI,[0x18ad8e]
CALL 0x0010fbbc
TEST EAX,EAX
JNZ 0x00112720
MOV RDI,RBX
LEA RSI,[0x18ad8d]
CALL 0x0010fbbc
TEST EAX,EAX
JNZ 0x00112720
MOV ESI,0x400
MOV RDI,R15
LEA RDX,[0x185823]
MOV RCX,qword ptr [RSP + 0x10]
MOV R8,RBX
XOR EAX,EAX
CALL 0x0010e310
MOV RDI,R15
CMP R12B,0x4
JNZ 0x001126e7
CALL 0x00112630
MOV R14,qword ptr [RSP + 0x8]
JMP 0x00112720
LAB_001126e7:
LEA RSI,[0x185831]
CALL 0x00119703
TEST EAX,EAX
MOV R14,qword ptr [RSP + 0x8]
JZ 0x00112720
MOV RDI,R15
LEA RSI,[0x185829]
CALL 0x00119703
TEST EAX,EAX
JNZ 0x00112720
LEA RDI,[0x1bf5d8]
XOR ESI,ESI
MOV RDX,R15
CALL 0x0010f188
LAB_00112720:
MOV RDI,R13
CALL 0x0010e060
INC RBP
JMP 0x00112674
LAB_00112730:
CALL 0x0010e060
ADD RSP,0x428
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void find_test_files(char *param_1)
{
char *pcVar1;
uchar uVar2;
dirent *__ptr;
uint uVar3;
int iVar4;
ulong uVar5;
dirent **local_440;
char local_438 [1032];
local_440 = (dirent **)0x0;
uVar3 = scandir(param_1,&local_440,(__selector *)0x0,(__cmp *)PTR_alphasort_001befd0);
if ((int)uVar3 < 1) {
uVar3 = 0;
}
for (uVar5 = 0; uVar3 != uVar5; uVar5 = uVar5 + 1) {
__ptr = local_440[uVar5];
pcVar1 = __ptr->d_name;
uVar2 = __ptr->d_type;
iVar4 = str_equal(pcVar1,".");
if (iVar4 == 0) {
iVar4 = str_equal(pcVar1,"..");
if (iVar4 == 0) {
snprintf(local_438,0x400,"%s/%s",param_1,pcVar1);
if (uVar2 == '\x04') {
find_test_files();
}
else {
iVar4 = js__has_suffix(local_438,".js");
if (iVar4 != 0) {
iVar4 = js__has_suffix(local_438,"_FIXTURE.js");
if (iVar4 == 0) {
namelist_add(&test_list,0,local_438);
}
}
}
}
}
free(__ptr);
}
free(local_440);
return;
}
| |
21,447 | find_test_files | bluesky950520[P]quickjs/run-test262.c | static void find_test_files(const char *path)
{
#ifdef _WIN32
WIN32_FIND_DATAA d;
HANDLE h;
char s[1024];
snprintf(s, sizeof(s), "%s/*", path);
h = FindFirstFileA(s, &d);
if (h != INVALID_HANDLE_VALUE) {
do {
consider_test_file(path,
d.cFileName,
d.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY);
} while (FindNextFileA(h, &d));
FindClose(h);
}
#else
struct dirent *d, **ds = NULL;
int i, n;
n = scandir(path, &ds, NULL, alphasort);
for (i = 0; i < n; i++) {
d = ds[i];
consider_test_file(path, d->d_name, d->d_type == DT_DIR);
free(d);
}
free(ds);
#endif
} | O3 | c | find_test_files:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x418, %rsp # imm = 0x418
movq %rdi, %rbx
leaq 0x8(%rsp), %rsi
movq $0x0, (%rsi)
movq 0xbcb06(%rip), %rcx # 0xd4fd0
xorl %edx, %edx
callq 0xe3b0
testl %eax, %eax
jle 0x1857e
movl %eax, %r13d
leaq 0x10(%rsp), %r15
xorl %r12d, %r12d
movq 0x8(%rsp), %rax
movq (%rax,%r12,8), %rbp
movb 0x12(%rbp), %r14b
cmpb $0x2e, 0x13(%rbp)
jne 0x18509
cmpb $0x0, 0x14(%rbp)
je 0x1856a
cmpb $0x2e, 0x14(%rbp)
jne 0x18509
cmpb $0x0, 0x15(%rbp)
je 0x1856a
leaq 0x13(%rbp), %r8
movl $0x400, %esi # imm = 0x400
movq %r15, %rdi
leaq 0x8a2e3(%rip), %rdx # 0xa27ff
movq %rbx, %rcx
xorl %eax, %eax
callq 0xe300
movq %r15, %rdi
cmpb $0x4, %r14b
jne 0x18536
callq 0x184a3
jmp 0x1856a
leaq 0x8a2d0(%rip), %rsi # 0xa280d
callq 0x1fc22
testl %eax, %eax
je 0x1856a
movq %r15, %rdi
leaq 0x8a2b5(%rip), %rsi # 0xa2805
callq 0x1fc22
testl %eax, %eax
jne 0x1856a
leaq 0xbd068(%rip), %rdi # 0xd55c8
xorl %esi, %esi
movq %r15, %rdx
callq 0x14d35
movq %rbp, %rdi
callq 0xe060
incq %r12
cmpq %r12, %r13
jne 0x184e4
movq 0x8(%rsp), %rdi
callq 0xe060
addq $0x418, %rsp # imm = 0x418
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| find_test_files:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 418h
mov rbx, rdi
lea rsi, [rsp+448h+var_440]
mov qword ptr [rsi], 0
mov rcx, cs:alphasort_ptr
xor edx, edx
call _scandir
test eax, eax
jle loc_1857E
mov r13d, eax
lea r15, [rsp+448h+var_438]
xor r12d, r12d
loc_184E4:
mov rax, [rsp+448h+var_440]
mov rbp, [rax+r12*8]
mov r14b, [rbp+12h]
cmp byte ptr [rbp+13h], 2Eh ; '.'
jnz short loc_18509
cmp byte ptr [rbp+14h], 0
jz short loc_1856A
cmp byte ptr [rbp+14h], 2Eh ; '.'
jnz short loc_18509
cmp byte ptr [rbp+15h], 0
jz short loc_1856A
loc_18509:
lea r8, [rbp+13h]
mov esi, 400h
mov rdi, r15
lea rdx, aSS_1; "%s/%s"
mov rcx, rbx
xor eax, eax
call _snprintf
mov rdi, r15
cmp r14b, 4
jnz short loc_18536
call find_test_files
jmp short loc_1856A
loc_18536:
lea rsi, aFixtureJs+8; ".js"
call js__has_suffix
test eax, eax
jz short loc_1856A
mov rdi, r15
lea rsi, aFixtureJs; "_FIXTURE.js"
call js__has_suffix
test eax, eax
jnz short loc_1856A
lea rdi, test_list
xor esi, esi
mov rdx, r15
call namelist_add
loc_1856A:
mov rdi, rbp
call _free
inc r12
cmp r13, r12
jnz loc_184E4
loc_1857E:
mov rdi, [rsp+448h+var_440]
call _free
add rsp, 418h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long find_test_files(
const char *a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
double a6,
double a7,
__m128 a8,
__m128 a9)
{
int v9; // eax
long long v10; // r13
long long i; // r12
long long v12; // rbp
char v13; // r14
double v14; // xmm4_8
double v15; // xmm5_8
long long v17; // [rsp+8h] [rbp-440h] BYREF
_BYTE v18[1080]; // [rsp+10h] [rbp-438h] BYREF
v17 = 0LL;
v9 = scandir(a1, &v17, 0LL, &alphasort);
if ( v9 > 0 )
{
v10 = (unsigned int)v9;
for ( i = 0LL; i != v10; ++i )
{
v12 = *(_QWORD *)(v17 + 8 * i);
v13 = *(_BYTE *)(v12 + 18);
if ( *(_BYTE *)(v12 + 19) != 46 || *(_BYTE *)(v12 + 20) && (*(_BYTE *)(v12 + 20) != 46 || *(_BYTE *)(v12 + 21)) )
{
snprintf(v18, 1024LL, "%s/%s", a1, (const char *)(v12 + 19));
if ( v13 == 4 )
{
find_test_files(v18);
}
else if ( (unsigned int)js__has_suffix(v18, ".js") && !(unsigned int)js__has_suffix(v18, "_FIXTURE.js") )
{
namelist_add(&test_list, 0LL, v18, a2, a3, a4, a5, v14, v15, a8, a9);
}
}
free(v12);
}
}
return free(v17);
}
| find_test_files:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x418
MOV RBX,RDI
LEA RSI,[RSP + 0x8]
MOV qword ptr [RSI],0x0
MOV RCX,qword ptr [0x001d4fd0]
XOR EDX,EDX
CALL 0x0010e3b0
TEST EAX,EAX
JLE 0x0011857e
MOV R13D,EAX
LEA R15,[RSP + 0x10]
XOR R12D,R12D
LAB_001184e4:
MOV RAX,qword ptr [RSP + 0x8]
MOV RBP,qword ptr [RAX + R12*0x8]
MOV R14B,byte ptr [RBP + 0x12]
CMP byte ptr [RBP + 0x13],0x2e
JNZ 0x00118509
CMP byte ptr [RBP + 0x14],0x0
JZ 0x0011856a
CMP byte ptr [RBP + 0x14],0x2e
JNZ 0x00118509
CMP byte ptr [RBP + 0x15],0x0
JZ 0x0011856a
LAB_00118509:
LEA R8,[RBP + 0x13]
MOV ESI,0x400
MOV RDI,R15
LEA RDX,[0x1a27ff]
MOV RCX,RBX
XOR EAX,EAX
CALL 0x0010e300
MOV RDI,R15
CMP R14B,0x4
JNZ 0x00118536
CALL 0x001184a3
JMP 0x0011856a
LAB_00118536:
LEA RSI,[0x1a280d]
CALL 0x0011fc22
TEST EAX,EAX
JZ 0x0011856a
MOV RDI,R15
LEA RSI,[0x1a2805]
CALL 0x0011fc22
TEST EAX,EAX
JNZ 0x0011856a
LEA RDI,[0x1d55c8]
XOR ESI,ESI
MOV RDX,R15
CALL 0x00114d35
LAB_0011856a:
MOV RDI,RBP
CALL 0x0010e060
INC R12
CMP R13,R12
JNZ 0x001184e4
LAB_0011857e:
MOV RDI,qword ptr [RSP + 0x8]
CALL 0x0010e060
ADD RSP,0x418
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void find_test_files(char *param_1)
{
uchar uVar1;
dirent *__ptr;
uint uVar2;
int iVar3;
ulong uVar4;
dirent **local_440;
char local_438 [1032];
local_440 = (dirent **)0x0;
uVar2 = scandir(param_1,&local_440,(__selector *)0x0,(__cmp *)PTR_alphasort_001d4fd0);
if (0 < (int)uVar2) {
uVar4 = 0;
do {
__ptr = local_440[uVar4];
uVar1 = __ptr->d_type;
if ((__ptr->d_name[0] != '.') ||
((__ptr->d_name[1] != '\0' && ((__ptr->d_name[1] != '.' || (__ptr->d_name[2] != '\0'))))))
{
snprintf(local_438,0x400,"%s/%s",param_1,__ptr->d_name);
if (uVar1 == '\x04') {
find_test_files();
}
else {
iVar3 = js__has_suffix(local_438,".js");
if (iVar3 != 0) {
iVar3 = js__has_suffix(local_438,"_FIXTURE.js");
if (iVar3 == 0) {
namelist_add(&test_list,0,local_438);
}
}
}
}
free(__ptr);
uVar4 = uVar4 + 1;
} while (uVar2 != uVar4);
}
free(local_440);
return;
}
| |
21,448 | combine_filename | corpus-core[P]colibri-stateless/src/util/plugin.c | static char* combine_filename(char* name) {
const char* base_path = getenv("C4_STATES_DIR");
if (base_path != NULL) {
size_t length = strlen(base_path) + strlen(name) + 2;
char* full_path = safe_malloc(length);
if (full_path == NULL) return NULL;
snprintf(full_path, length, "%s/%s", base_path, name);
return full_path;
}
else
return strdup(name);
} | O0 | c | combine_filename:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
leaq 0x41db9(%rip), %rdi # 0xe58ac
callq 0x232b0
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0xa3b71
movq -0x18(%rbp), %rdi
callq 0x230f0
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rdi
callq 0x230f0
movq %rax, %rcx
movq -0x30(%rbp), %rax
addq %rcx, %rax
addq $0x2, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
callq 0x9c400
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0xa3b49
movq $0x0, -0x8(%rbp)
jmp 0xa3b7e
movq -0x28(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x18(%rbp), %rcx
movq -0x10(%rbp), %r8
leaq 0x41d5a(%rip), %rdx # 0xe58ba
movb $0x0, %al
callq 0x233b0
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0xa3b7e
movq -0x10(%rbp), %rdi
callq 0x23450
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| combine_filename:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
lea rdi, aC4StatesDir; "C4_STATES_DIR"
call _getenv
mov [rbp+var_18], rax
cmp [rbp+var_18], 0
jz short loc_A3B71
mov rdi, [rbp+var_18]
call _strlen
mov [rbp+var_30], rax
mov rdi, [rbp+var_10]
call _strlen
mov rcx, rax
mov rax, [rbp+var_30]
add rax, rcx
add rax, 2
mov [rbp+var_20], rax
mov rdi, [rbp+var_20]
call safe_malloc
mov [rbp+var_28], rax
cmp [rbp+var_28], 0
jnz short loc_A3B49
mov [rbp+var_8], 0
jmp short loc_A3B7E
loc_A3B49:
mov rdi, [rbp+var_28]
mov rsi, [rbp+var_20]
mov rcx, [rbp+var_18]
mov r8, [rbp+var_10]
lea rdx, aSS; "%s/%s"
mov al, 0
call _snprintf
mov rax, [rbp+var_28]
mov [rbp+var_8], rax
jmp short loc_A3B7E
loc_A3B71:
mov rdi, [rbp+var_10]
call _strdup
mov [rbp+var_8], rax
loc_A3B7E:
mov rax, [rbp+var_8]
add rsp, 30h
pop rbp
retn
| long long combine_filename(const char *a1)
{
long long v2; // [rsp+0h] [rbp-30h]
long long v3; // [rsp+8h] [rbp-28h]
long long v4; // [rsp+10h] [rbp-20h]
const char *v5; // [rsp+18h] [rbp-18h]
v5 = (const char *)getenv("C4_STATES_DIR");
if ( !v5 )
return strdup(a1);
v2 = strlen(v5);
v4 = strlen(a1) + v2 + 2;
v3 = safe_malloc(v4);
if ( !v3 )
return 0LL;
snprintf(v3, v4, "%s/%s", v5, a1);
return v3;
}
| combine_filename:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
LEA RDI,[0x1e58ac]
CALL 0x001232b0
MOV qword ptr [RBP + -0x18],RAX
CMP qword ptr [RBP + -0x18],0x0
JZ 0x001a3b71
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x001230f0
MOV qword ptr [RBP + -0x30],RAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001230f0
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x30]
ADD RAX,RCX
ADD RAX,0x2
MOV qword ptr [RBP + -0x20],RAX
MOV RDI,qword ptr [RBP + -0x20]
CALL 0x0019c400
MOV qword ptr [RBP + -0x28],RAX
CMP qword ptr [RBP + -0x28],0x0
JNZ 0x001a3b49
MOV qword ptr [RBP + -0x8],0x0
JMP 0x001a3b7e
LAB_001a3b49:
MOV RDI,qword ptr [RBP + -0x28]
MOV RSI,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x18]
MOV R8,qword ptr [RBP + -0x10]
LEA RDX,[0x1e58ba]
MOV AL,0x0
CALL 0x001233b0
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001a3b7e
LAB_001a3b71:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x00123450
MOV qword ptr [RBP + -0x8],RAX
LAB_001a3b7e:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x30
POP RBP
RET
|
char * combine_filename(char *param_1)
{
char *__s;
size_t sVar1;
size_t sVar2;
char *local_10;
__s = getenv("C4_STATES_DIR");
if (__s == (char *)0x0) {
local_10 = strdup(param_1);
}
else {
sVar1 = strlen(__s);
sVar2 = strlen(param_1);
sVar1 = sVar1 + sVar2 + 2;
local_10 = (char *)safe_malloc(sVar1);
if (local_10 == (char *)0x0) {
local_10 = (char *)0x0;
}
else {
snprintf(local_10,sVar1,"%s/%s",__s,param_1);
}
}
return local_10;
}
| |
21,449 | nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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>>::start_object(unsigned long) | monkey531[P]llama/common/json.hpp | bool start_object(std::size_t len)
{
ref_stack.push_back(handle_value(BasicJsonType::value_t::object));
if (JSON_HEDLEY_UNLIKELY(len != static_cast<std::size_t>(-1) && len > ref_stack.back()->max_size()))
{
JSON_THROW(out_of_range::create(408, concat("excessive object size: ", std::to_string(len)), ref_stack.back()));
}
return true;
} | O2 | cpp | nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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>>::start_object(unsigned long):
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r15
movq %rdi, %r14
leaq 0x8(%rdi), %rbx
leaq 0x8(%rsp), %rsi
movb $0x1, (%rsi)
callq 0x6c4fa
leaq 0x28(%rsp), %rsi
movq %rax, (%rsi)
movq %rbx, %rdi
callq 0x6c5da
cmpq $-0x1, %r15
je 0x6c19b
movq 0x10(%r14), %rax
movq -0x8(%rax), %rdi
callq 0x68d1e
cmpq %r15, %rax
jb 0x6c1a8
movb $0x1, %al
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
pushq $0x20
popq %rdi
callq 0x265e0
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
movq %r15, %rsi
callq 0x42685
leaq 0x62f44(%rip), %rsi # 0xcf10b
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rdx
callq 0x68e33
movq 0x10(%r14), %rax
movq -0x8(%rax), %rcx
movb $0x1, %bpl
leaq 0x28(%rsp), %rdx
movq %rbx, %rdi
movl $0x198, %esi # imm = 0x198
callq 0x68d46
xorl %ebp, %ebp
leaq 0xb2f1c(%rip), %rsi # 0x11f118
leaq -0x505d(%rip), %rdx # 0x671a6
movq %rbx, %rdi
callq 0x275b0
movq %rax, %r14
leaq 0x28(%rsp), %rdi
callq 0x27998
jmp 0x6c220
movq %rax, %r14
movb $0x1, %bpl
leaq 0x8(%rsp), %rdi
callq 0x27998
testb %bpl, %bpl
jne 0x6c234
jmp 0x6c23c
movq %rax, %r14
movq %rbx, %rdi
callq 0x268f0
movq %r14, %rdi
callq 0x27660
| _ZN8nlohmann16json_abi_v3_11_36detail19json_sax_dom_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12start_objectEm:
push rbp; char
push r15; int
push r14; int
push rbx; int
sub rsp, 48h
mov r15, rsi
mov r14, rdi
lea rbx, [rdi+8]
lea rsi, [rsp+68h+var_60]
mov byte ptr [rsi], 1
call _ZN8nlohmann16json_abi_v3_11_36detail19json_sax_dom_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12handle_valueINS1_7value_tEEEPSF_OT_; nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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>>::handle_value<nlohmann::json_abi_v3_11_3::detail::value_t>(nlohmann::json_abi_v3_11_3::detail::value_t &&)
lea rsi, [rsp+68h+var_40]
mov [rsi], rax
mov rdi, rbx
call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE12emplace_backIJSE_EEERSE_DpOT_; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> * &&)
cmp r15, 0FFFFFFFFFFFFFFFFh
jz short loc_6C19B
mov rax, [r14+10h]
mov rdi, [rax-8]
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8max_sizeEv; 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>::max_size(void)
cmp rax, r15
jb short loc_6C1A8
loc_6C19B:
mov al, 1
add rsp, 48h
pop rbx
pop r14
pop r15
pop rbp
retn
loc_6C1A8:
push 20h ; ' '
pop rdi; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rdi, [rsp+68h+var_60]; this
mov rsi, r15; unsigned __int64
call _ZNSt7__cxx119to_stringEm; std::to_string(ulong)
lea rsi, aExcessiveObjec; "excessive object size: "
lea rdi, [rsp+68h+var_40]
lea rdx, [rsp+68h+var_60]
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA24_KcS8_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[24],std::string>(char const(&)[24],std::string &&)
mov rax, [r14+10h]
mov rcx, [rax-8]
mov bpl, 1
lea rdx, [rsp+68h+var_40]
mov rdi, rbx; this
mov esi, 198h; int
call _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail12out_of_rangeE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rdi, [rsp+68h+var_40]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_6C220
mov r14, rax
mov bpl, 1
loc_6C220:
lea rdi, [rsp+68h+var_60]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
jnz short loc_6C234
jmp short loc_6C23C
mov r14, rax
loc_6C234:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_6C23C:
mov rdi, r14
call __Unwind_Resume
| char nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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>>::start_object(
long long a1,
unsigned long long a2)
{
nlohmann::json_abi_v3_11_3::detail::out_of_range *exception; // rbx
_BYTE v4[32]; // [rsp+8h] [rbp-60h] BYREF
_QWORD v5[8]; // [rsp+28h] [rbp-40h] BYREF
v4[0] = 1;
v5[0] = nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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>>::handle_value<nlohmann::json_abi_v3_11_3::detail::value_t>(
a1,
v4);
std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *>>::emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> *>(a1 + 8);
if ( a2 != -1LL
&& 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>::max_size(*(unsigned __int8 **)(*(_QWORD *)(a1 + 16) - 8LL)) < a2 )
{
exception = (nlohmann::json_abi_v3_11_3::detail::out_of_range *)__cxa_allocate_exception(0x20uLL);
std::to_string((std::__cxx11 *)v4, a2);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[24],std::string>(
(long long)v5,
(long long)"excessive object size: ",
(long long)v4);
ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_(
exception,
408,
(long long)v5,
*(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL));
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::out_of_range,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
return 1;
}
| start_object:
PUSH RBP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x48
MOV R15,RSI
MOV R14,RDI
LEA RBX,[RDI + 0x8]
LEA RSI,[RSP + 0x8]
MOV byte ptr [RSI],0x1
CALL 0x0016c4fa
LEA RSI,[RSP + 0x28]
MOV qword ptr [RSI],RAX
MOV RDI,RBX
CALL 0x0016c5da
CMP R15,-0x1
JZ 0x0016c19b
MOV RAX,qword ptr [R14 + 0x10]
MOV RDI,qword ptr [RAX + -0x8]
CALL 0x00168d1e
CMP RAX,R15
JC 0x0016c1a8
LAB_0016c19b:
MOV AL,0x1
ADD RSP,0x48
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_0016c1a8:
PUSH 0x20
POP RDI
CALL 0x001265e0
MOV RBX,RAX
LAB_0016c1b3:
LEA RDI,[RSP + 0x8]
MOV RSI,R15
CALL 0x00142685
LAB_0016c1c0:
LEA RSI,[0x1cf10b]
LEA RDI,[RSP + 0x28]
LEA RDX,[RSP + 0x8]
CALL 0x00168e33
MOV RAX,qword ptr [R14 + 0x10]
MOV RCX,qword ptr [RAX + -0x8]
MOV BPL,0x1
LAB_0016c1e1:
LEA RDX,[RSP + 0x28]
MOV RDI,RBX
MOV ESI,0x198
CALL 0x00168d46
XOR EBP,EBP
LEA RSI,[0x21f118]
LEA RDX,[0x1671a6]
MOV RDI,RBX
CALL 0x001275b0
|
/* nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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> >::start_object(unsigned long) */
int8 __thiscall
nlohmann::json_abi_v3_11_3::detail::
json_sax_dom_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>>
::start_object(json_sax_dom_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,ulong param_1)
{
ulong uVar1;
int8 uVar2;
__cxx11 local_60 [32];
basic_json *local_40 [4];
local_60[0] = (__cxx11)0x1;
local_40[0] = handle_value<nlohmann::json_abi_v3_11_3::detail::value_t>(this,local_60);
std::
vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>>
::
emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>
((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>>
*)(this + 8),local_40);
if (param_1 != 0xffffffffffffffff) {
uVar1 = 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>
::max_size(*(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
**)(*(long *)(this + 0x10) + -8));
if (uVar1 < param_1) {
uVar2 = __cxa_allocate_exception(0x20);
/* try { // try from 0016c1b3 to 0016c1bf has its CatchHandler @ 0016c231 */
std::__cxx11::to_string(local_60,param_1);
/* try { // try from 0016c1c0 to 0016c1d5 has its CatchHandler @ 0016c21a */
concat<std::__cxx11::string,char_const(&)[24],std::__cxx11::string>
((detail *)local_40,"excessive object size: ",(string *)local_60);
/* try { // try from 0016c1e1 to 0016c20a has its CatchHandler @ 0016c20b */
_ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_
(uVar2,0x198,local_40,*(int8 *)(*(long *)(this + 0x10) + -8));
/* WARNING: Subroutine does not return */
__cxa_throw(uVar2,&out_of_range::typeinfo,exception::~exception);
}
}
return 1;
}
| |
21,450 | minja::FilterNode::FilterNode(minja::Location const&, std::shared_ptr<minja::Expression>&&, std::shared_ptr<minja::TemplateNode>&&) | monkey531[P]llama/common/minja.hpp | FilterNode(const Location & location, std::shared_ptr<Expression> && f, std::shared_ptr<TemplateNode> && b)
: TemplateNode(location), filter(std::move(f)), body(std::move(b)) {} | O2 | cpp | minja::FilterNode::FilterNode(minja::Location const&, std::shared_ptr<minja::Expression>&&, std::shared_ptr<minja::TemplateNode>&&):
pushq %r15
pushq %r14
pushq %rbx
movq %rcx, %rbx
movq %rdx, %r14
movq %rdi, %r15
callq 0x65a86
leaq 0x783ca(%rip), %rax # 0xe2518
addq $0x10, %rax
movq %rax, (%r15)
andq $0x0, 0x28(%r15)
movups (%r14), %xmm0
andq $0x0, 0x8(%r14)
movups %xmm0, 0x20(%r15)
andq $0x0, (%r14)
andq $0x0, 0x38(%r15)
movups (%rbx), %xmm0
andq $0x0, 0x8(%rbx)
movups %xmm0, 0x30(%r15)
andq $0x0, (%rbx)
popq %rbx
popq %r14
popq %r15
retq
| _ZN5minja10FilterNodeC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEEOS4_INS_12TemplateNodeEE:
push r15
push r14
push rbx
mov rbx, rcx
mov r14, rdx
mov r15, rdi
call _ZN5minja12TemplateNodeC2ERKNS_8LocationE; minja::TemplateNode::TemplateNode(minja::Location const&)
lea rax, _ZTVN5minja10FilterNodeE; `vtable for'minja::FilterNode
add rax, 10h
mov [r15], rax
and qword ptr [r15+28h], 0
movups xmm0, xmmword ptr [r14]
and qword ptr [r14+8], 0
movups xmmword ptr [r15+20h], xmm0
and qword ptr [r14], 0
and qword ptr [r15+38h], 0
movups xmm0, xmmword ptr [rbx]
and qword ptr [rbx+8], 0
movups xmmword ptr [r15+30h], xmm0
and qword ptr [rbx], 0
pop rbx
pop r14
pop r15
retn
| long long * minja::FilterNode::FilterNode(long long a1, _QWORD *a2, __int128 *a3, __int128 *a4)
{
long long *result; // rax
__int128 v7; // xmm0
__int128 v8; // xmm0
minja::TemplateNode::TemplateNode((_QWORD *)a1, a2);
result = &`vtable for'minja::FilterNode + 2;
*(_QWORD *)a1 = &`vtable for'minja::FilterNode + 2;
*(_QWORD *)(a1 + 40) = 0LL;
v7 = *a3;
*((_QWORD *)a3 + 1) = 0LL;
*(_OWORD *)(a1 + 32) = v7;
*(_QWORD *)a3 = 0LL;
*(_QWORD *)(a1 + 56) = 0LL;
v8 = *a4;
*((_QWORD *)a4 + 1) = 0LL;
*(_OWORD *)(a1 + 48) = v8;
*(_QWORD *)a4 = 0LL;
return result;
}
| FilterNode:
PUSH R15
PUSH R14
PUSH RBX
MOV RBX,RCX
MOV R14,RDX
MOV R15,RDI
CALL 0x00165a86
LEA RAX,[0x1e2518]
ADD RAX,0x10
MOV qword ptr [R15],RAX
AND qword ptr [R15 + 0x28],0x0
MOVUPS XMM0,xmmword ptr [R14]
AND qword ptr [R14 + 0x8],0x0
MOVUPS xmmword ptr [R15 + 0x20],XMM0
AND qword ptr [R14],0x0
AND qword ptr [R15 + 0x38],0x0
MOVUPS XMM0,xmmword ptr [RBX]
AND qword ptr [RBX + 0x8],0x0
MOVUPS xmmword ptr [R15 + 0x30],XMM0
AND qword ptr [RBX],0x0
POP RBX
POP R14
POP R15
RET
|
/* minja::FilterNode::FilterNode(minja::Location const&, std::shared_ptr<minja::Expression>&&,
std::shared_ptr<minja::TemplateNode>&&) */
void __thiscall
minja::FilterNode::FilterNode
(FilterNode *this,Location *param_1,shared_ptr *param_2,shared_ptr *param_3)
{
int8 uVar1;
TemplateNode::TemplateNode((TemplateNode *)this,param_1);
*(int ***)this = &PTR_do_render_001e2528;
*(int8 *)(this + 0x28) = 0;
uVar1 = *(int8 *)(param_2 + 8);
*(int8 *)(param_2 + 8) = 0;
*(int8 *)(this + 0x20) = *(int8 *)param_2;
*(int8 *)(this + 0x28) = uVar1;
*(int8 *)param_2 = 0;
*(int8 *)(this + 0x38) = 0;
uVar1 = *(int8 *)(param_3 + 8);
*(int8 *)(param_3 + 8) = 0;
*(int8 *)(this + 0x30) = *(int8 *)param_3;
*(int8 *)(this + 0x38) = uVar1;
*(int8 *)param_3 = 0;
return;
}
| |
21,451 | get_timer_raw_value(enum_timer_name) | eloqsql/storage/perfschema/pfs_timer.cc | ulonglong get_timer_raw_value(enum_timer_name timer_name)
{
switch (timer_name)
{
case TIMER_NAME_CYCLE:
return my_timer_cycles();
case TIMER_NAME_NANOSEC:
return my_timer_nanoseconds();
case TIMER_NAME_MICROSEC:
return my_timer_microseconds();
case TIMER_NAME_MILLISEC:
return my_timer_milliseconds();
case TIMER_NAME_TICK:
return my_timer_ticks();
default:
assert(false);
}
return 0;
} | O3 | cpp | get_timer_raw_value(enum_timer_name):
pushq %rbp
movq %rsp, %rbp
decl %edi
cmpl $0x4, %edi
ja 0x3a78b
leaq 0x46785(%rip), %rax # 0x80ee4
movslq (%rax,%rdi,4), %rcx
addq %rax, %rcx
jmpq *%rcx
rdtsc
shlq $0x20, %rdx
orq %rdx, %rax
jmp 0x3a78d
popq %rbp
jmp 0x47559
popq %rbp
jmp 0x474dd
popq %rbp
jmp 0x47519
popq %rbp
jmp 0x474b4
xorl %eax, %eax
popq %rbp
retq
| _Z19get_timer_raw_value15enum_timer_name:
push rbp
mov rbp, rsp
dec edi; switch 5 cases
cmp edi, 4
ja short def_3A766; jumptable 000000000003A766 default case
lea rax, jpt_3A766
movsxd rcx, ds:(jpt_3A766 - 80EE4h)[rax+rdi*4]
add rcx, rax
jmp rcx; switch jump
loc_3A768:
rdtsc; jumptable 000000000003A766 case 1
shl rdx, 20h
or rax, rdx
jmp short loc_3A78D
loc_3A773:
pop rbp; jumptable 000000000003A766 case 5
jmp my_timer_ticks
loc_3A779:
pop rbp; jumptable 000000000003A766 case 3
jmp my_timer_microseconds
loc_3A77F:
pop rbp; jumptable 000000000003A766 case 4
jmp my_timer_milliseconds
loc_3A785:
pop rbp; jumptable 000000000003A766 case 2
jmp my_timer_nanoseconds
def_3A766:
xor eax, eax; jumptable 000000000003A766 default case
loc_3A78D:
pop rbp
retn
| long long get_timer_raw_value(int a1)
{
long long result; // rax
switch ( a1 )
{
case 1:
result = __rdtsc();
break;
case 2:
result = my_timer_nanoseconds();
break;
case 3:
result = my_timer_microseconds();
break;
case 4:
result = my_timer_milliseconds();
break;
case 5:
result = my_timer_ticks();
break;
default:
result = 0LL;
break;
}
return result;
}
| get_timer_raw_value:
PUSH RBP
MOV RBP,RSP
DEC EDI
CMP EDI,0x4
JA 0x0013a78b
LEA RAX,[0x180ee4]
MOVSXD RCX,dword ptr [RAX + RDI*0x4]
ADD RCX,RAX
switchD:
JMP RCX
caseD_1:
RDTSC
SHL RDX,0x20
OR RAX,RDX
JMP 0x0013a78d
caseD_5:
POP RBP
JMP 0x00147559
caseD_3:
POP RBP
JMP 0x001474dd
caseD_4:
POP RBP
JMP 0x00147519
caseD_2:
POP RBP
JMP 0x001474b4
default:
XOR EAX,EAX
LAB_0013a78d:
POP RBP
RET
|
/* get_timer_raw_value(enum_timer_name) */
int8 get_timer_raw_value(int4 param_1)
{
int8 uVar1;
switch(param_1) {
case 1:
uVar1 = rdtsc();
break;
case 2:
uVar1 = my_timer_nanoseconds();
return uVar1;
case 3:
uVar1 = my_timer_microseconds();
return uVar1;
case 4:
uVar1 = my_timer_milliseconds();
return uVar1;
case 5:
uVar1 = my_timer_ticks();
return uVar1;
default:
uVar1 = 0;
}
return uVar1;
}
| |
21,452 | tree_search_edge | eloqsql/mysys/tree.c | void *tree_search_edge(TREE *tree, TREE_ELEMENT **parents,
TREE_ELEMENT ***last_pos, int child_offs)
{
TREE_ELEMENT *element= tree->root;
*parents= &null_element;
while (element != &null_element)
{
*++parents= element;
element= ELEMENT_CHILD(element, child_offs);
}
*last_pos= parents;
return **last_pos != &null_element ?
ELEMENT_KEY(tree, **last_pos) : NULL;
} | O0 | c | tree_search_edge:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
leaq 0x1b04f7(%rip), %rcx # 0x238b40
movq %rcx, (%rax)
leaq 0x1b04ed(%rip), %rax # 0x238b40
cmpq %rax, -0x28(%rbp)
je 0x88682
movq -0x28(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, -0x10(%rbp)
movq %rcx, 0x8(%rax)
movq -0x28(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movq (%rax,%rcx), %rax
movq %rax, -0x28(%rbp)
jmp 0x8864c
movq -0x10(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movq -0x18(%rbp), %rax
movq (%rax), %rax
leaq 0x1b04a5(%rip), %rcx # 0x238b40
cmpq %rcx, (%rax)
je 0x886e6
movq -0x8(%rbp), %rax
cmpl $0x0, 0x208(%rax)
je 0x886ca
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rax
movq -0x8(%rbp), %rcx
movl 0x208(%rcx), %ecx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
jmp 0x886dc
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x886ee
xorl %eax, %eax
movq %rax, -0x38(%rbp)
jmp 0x886ee
movq -0x38(%rbp), %rax
popq %rbp
retq
nopw %cs:(%rax,%rax)
| tree_search_edge:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_1C], ecx
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_28], rax
mov rax, [rbp+var_10]
lea rcx, null_element
mov [rax], rcx
loc_8864C:
lea rax, null_element
cmp [rbp+var_28], rax
jz short loc_88682
mov rcx, [rbp+var_28]
mov rax, [rbp+var_10]
mov rdx, rax
add rdx, 8
mov [rbp+var_10], rdx
mov [rax+8], rcx
mov rax, [rbp+var_28]
movsxd rcx, [rbp+var_1C]
mov rax, [rax+rcx]
mov [rbp+var_28], rax
jmp short loc_8864C
loc_88682:
mov rcx, [rbp+var_10]
mov rax, [rbp+var_18]
mov [rax], rcx
mov rax, [rbp+var_18]
mov rax, [rax]
lea rcx, null_element
cmp [rax], rcx
jz short loc_886E6
mov rax, [rbp+var_8]
cmp dword ptr [rax+208h], 0
jz short loc_886CA
mov rax, [rbp+var_18]
mov rax, [rax]
mov rax, [rax]
mov rcx, [rbp+var_8]
mov ecx, [rcx+208h]
add rax, rcx
mov [rbp+var_30], rax
jmp short loc_886DC
loc_886CA:
mov rax, [rbp+var_18]
mov rax, [rax]
mov rax, [rax]
mov rax, [rax+18h]
mov [rbp+var_30], rax
loc_886DC:
mov rax, [rbp+var_30]
mov [rbp+var_38], rax
jmp short loc_886EE
loc_886E6:
xor eax, eax
mov [rbp+var_38], rax
jmp short $+2
loc_886EE:
mov rax, [rbp+var_38]
pop rbp
retn
| long long tree_search_edge(char **a1, _QWORD *a2, long long a3, int a4)
{
_QWORD *v4; // rax
char *v8; // [rsp+10h] [rbp-28h]
_QWORD *v9; // [rsp+28h] [rbp-10h]
v9 = a2;
v8 = *a1;
*a2 = &null_element;
while ( v8 != (char *)&null_element )
{
v4 = v9++;
v4[1] = v8;
v8 = *(char **)&v8[a4];
}
*(_QWORD *)a3 = v9;
if ( **(_UNKNOWN ***)a3 == &null_element )
return 0LL;
if ( *((_DWORD *)a1 + 130) )
return *((unsigned int *)a1 + 130) + **(_QWORD **)a3;
else
return *(_QWORD *)(**(_QWORD **)a3 + 24LL);
}
| tree_search_edge:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV dword ptr [RBP + -0x1c],ECX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x10]
LEA RCX,[0x338b40]
MOV qword ptr [RAX],RCX
LAB_0018864c:
LEA RAX,[0x338b40]
CMP qword ptr [RBP + -0x28],RAX
JZ 0x00188682
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x10]
MOV RDX,RAX
ADD RDX,0x8
MOV qword ptr [RBP + -0x10],RDX
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RBP + -0x28]
MOVSXD RCX,dword ptr [RBP + -0x1c]
MOV RAX,qword ptr [RAX + RCX*0x1]
MOV qword ptr [RBP + -0x28],RAX
JMP 0x0018864c
LAB_00188682:
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
LEA RCX,[0x338b40]
CMP qword ptr [RAX],RCX
JZ 0x001886e6
MOV RAX,qword ptr [RBP + -0x8]
CMP dword ptr [RAX + 0x208],0x0
JZ 0x001886ca
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX]
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x208]
ADD RAX,RCX
MOV qword ptr [RBP + -0x30],RAX
JMP 0x001886dc
LAB_001886ca:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0x30],RAX
LAB_001886dc:
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x38],RAX
JMP 0x001886ee
LAB_001886e6:
XOR EAX,EAX
MOV qword ptr [RBP + -0x38],RAX
JMP 0x001886ee
LAB_001886ee:
MOV RAX,qword ptr [RBP + -0x38]
POP RBP
RET
|
long tree_search_edge(int8 *param_1,int8 *param_2,int8 *param_3,int param_4)
{
long local_40;
long local_38;
int1 *local_30;
int8 *local_18;
local_30 = (int1 *)*param_1;
*param_2 = null_element;
local_18 = param_2;
for (; local_30 != null_element; local_30 = *(int1 **)(local_30 + param_4)) {
local_18[1] = local_30;
local_18 = local_18 + 1;
}
*param_3 = local_18;
if (*(int1 **)*param_3 == null_element) {
local_40 = 0;
}
else {
if (*(int *)(param_1 + 0x41) == 0) {
local_38 = *(long *)(*(long *)*param_3 + 0x18);
}
else {
local_38 = *(long *)*param_3 + (ulong)*(uint *)(param_1 + 0x41);
}
local_40 = local_38;
}
return local_40;
}
| |
21,453 | ma_tls_version_options | eloqsql/libmariadb/libmariadb/secure/openssl.c | static long ma_tls_version_options(const char *version)
{
long protocol_options,
disable_all_protocols;
protocol_options= disable_all_protocols=
SSL_OP_NO_SSLv2 |
SSL_OP_NO_SSLv3 |
SSL_OP_NO_TLSv1 |
SSL_OP_NO_TLSv1_1 |
SSL_OP_NO_TLSv1_2
#ifdef TLS1_3_VERSION
| SSL_OP_NO_TLSv1_3
#endif
;
if (!version)
return 0;
if (strstr(version, "TLSv1.0"))
protocol_options&= ~SSL_OP_NO_TLSv1;
if (strstr(version, "TLSv1.1"))
protocol_options&= ~SSL_OP_NO_TLSv1_1;
if (strstr(version, "TLSv1.2"))
protocol_options&= ~SSL_OP_NO_TLSv1_2;
#ifdef TLS1_3_VERSION
if (strstr(version, "TLSv1.3"))
protocol_options&= ~SSL_OP_NO_TLSv1_3;
#endif
if (protocol_options != disable_all_protocols)
return protocol_options;
return 0;
} | O0 | c | ma_tls_version_options:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq $0x3e000000, -0x20(%rbp) # imm = 0x3E000000
movq $0x3e000000, -0x18(%rbp) # imm = 0x3E000000
cmpq $0x0, -0x10(%rbp)
jne 0x5d9f0
movq $0x0, -0x8(%rbp)
jmp 0x5da9c
movq -0x10(%rbp), %rdi
leaq 0x715e3(%rip), %rsi # 0xcefde
callq 0x37470
cmpq $0x0, %rax
je 0x5da14
movq -0x18(%rbp), %rax
andq $-0x4000001, %rax # imm = 0xFBFFFFFF
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x715c7(%rip), %rsi # 0xcefe6
callq 0x37470
cmpq $0x0, %rax
je 0x5da38
movq -0x18(%rbp), %rax
andq $-0x10000001, %rax # imm = 0xEFFFFFFF
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x715ab(%rip), %rsi # 0xcefee
callq 0x37470
cmpq $0x0, %rax
je 0x5da5c
movq -0x18(%rbp), %rax
andq $-0x8000001, %rax # imm = 0xF7FFFFFF
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x7158f(%rip), %rsi # 0xceff6
callq 0x37470
cmpq $0x0, %rax
je 0x5da80
movq -0x18(%rbp), %rax
andq $-0x20000001, %rax # imm = 0xDFFFFFFF
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
cmpq -0x20(%rbp), %rax
je 0x5da94
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x5da9c
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| ma_tls_version_options:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov [rbp+var_20], 3E000000h
mov [rbp+var_18], 3E000000h
cmp [rbp+var_10], 0
jnz short loc_5D9F0
mov [rbp+var_8], 0
jmp loc_5DA9C
loc_5D9F0:
mov rdi, [rbp+var_10]
lea rsi, aTlsv10; "TLSv1.0"
call _strstr
cmp rax, 0
jz short loc_5DA14
mov rax, [rbp+var_18]
and rax, 0FFFFFFFFFBFFFFFFh
mov [rbp+var_18], rax
loc_5DA14:
mov rdi, [rbp+var_10]
lea rsi, aTlsv11; "TLSv1.1"
call _strstr
cmp rax, 0
jz short loc_5DA38
mov rax, [rbp+var_18]
and rax, 0FFFFFFFFEFFFFFFFh
mov [rbp+var_18], rax
loc_5DA38:
mov rdi, [rbp+var_10]
lea rsi, aTlsv12; "TLSv1.2"
call _strstr
cmp rax, 0
jz short loc_5DA5C
mov rax, [rbp+var_18]
and rax, 0FFFFFFFFF7FFFFFFh
mov [rbp+var_18], rax
loc_5DA5C:
mov rdi, [rbp+var_10]
lea rsi, aTlsv13; "TLSv1.3"
call _strstr
cmp rax, 0
jz short loc_5DA80
mov rax, [rbp+var_18]
and rax, 0FFFFFFFFDFFFFFFFh
mov [rbp+var_18], rax
loc_5DA80:
mov rax, [rbp+var_18]
cmp rax, [rbp+var_20]
jz short loc_5DA94
mov rax, [rbp+var_18]
mov [rbp+var_8], rax
jmp short loc_5DA9C
loc_5DA94:
mov [rbp+var_8], 0
loc_5DA9C:
mov rax, [rbp+var_8]
add rsp, 20h
pop rbp
retn
| long long ma_tls_version_options(long long a1)
{
long long v2; // [rsp+8h] [rbp-18h]
v2 = 1040187392LL;
if ( !a1 )
return 0LL;
if ( strstr(a1, "TLSv1.0") )
v2 = 973078528LL;
if ( strstr(a1, "TLSv1.1") )
v2 &= ~0x10000000uLL;
if ( strstr(a1, "TLSv1.2") )
v2 &= ~0x8000000uLL;
if ( strstr(a1, "TLSv1.3") )
v2 &= ~0x20000000uLL;
if ( v2 == 1040187392 )
return 0LL;
else
return v2;
}
| ma_tls_version_options:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x20],0x3e000000
MOV qword ptr [RBP + -0x18],0x3e000000
CMP qword ptr [RBP + -0x10],0x0
JNZ 0x0015d9f0
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0015da9c
LAB_0015d9f0:
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[0x1cefde]
CALL 0x00137470
CMP RAX,0x0
JZ 0x0015da14
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,-0x4000001
MOV qword ptr [RBP + -0x18],RAX
LAB_0015da14:
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[0x1cefe6]
CALL 0x00137470
CMP RAX,0x0
JZ 0x0015da38
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,-0x10000001
MOV qword ptr [RBP + -0x18],RAX
LAB_0015da38:
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[0x1cefee]
CALL 0x00137470
CMP RAX,0x0
JZ 0x0015da5c
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,-0x8000001
MOV qword ptr [RBP + -0x18],RAX
LAB_0015da5c:
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[0x1ceff6]
CALL 0x00137470
CMP RAX,0x0
JZ 0x0015da80
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,-0x20000001
MOV qword ptr [RBP + -0x18],RAX
LAB_0015da80:
MOV RAX,qword ptr [RBP + -0x18]
CMP RAX,qword ptr [RBP + -0x20]
JZ 0x0015da94
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0015da9c
LAB_0015da94:
MOV qword ptr [RBP + -0x8],0x0
LAB_0015da9c:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x20
POP RBP
RET
|
ulong ma_tls_version_options(char *param_1)
{
char *pcVar1;
ulong local_20;
ulong local_10;
local_20 = 0x3e000000;
if (param_1 == (char *)0x0) {
local_10 = 0;
}
else {
pcVar1 = strstr(param_1,"TLSv1.0");
if (pcVar1 != (char *)0x0) {
local_20 = 0x3a000000;
}
pcVar1 = strstr(param_1,"TLSv1.1");
if (pcVar1 != (char *)0x0) {
local_20 = local_20 & 0xffffffffefffffff;
}
pcVar1 = strstr(param_1,"TLSv1.2");
if (pcVar1 != (char *)0x0) {
local_20 = local_20 & 0xfffffffff7ffffff;
}
pcVar1 = strstr(param_1,"TLSv1.3");
if (pcVar1 != (char *)0x0) {
local_20 = local_20 & 0xffffffffdfffffff;
}
if (local_20 == 0x3e000000) {
local_10 = 0;
}
else {
local_10 = local_20;
}
}
return local_10;
}
| |
21,454 | store_page_range | eloqsql/storage/maria/ma_blockrec.c | static uchar *store_page_range(MARIA_SHARE *share,
uchar *to, MARIA_BITMAP_BLOCK *block,
ulong length,
uint *tot_ranges)
{
uint data_size= FULL_PAGE_SIZE(share);
ulong pages_left= (length + data_size -1) / data_size;
uint page_count, ranges, empty_space;
uchar *to_start;
DBUG_ENTER("store_page_range");
to_start= to;
to+= SUB_RANGE_SIZE;
/* Store number of unused bytes at last page */
empty_space= (uint) (pages_left * data_size - length);
int2store(to, empty_space);
to+= BLOCK_FILLER_SIZE;
ranges= 0;
do
{
pgcache_page_no_t page;
page= block->page;
page_count= block->page_count;
block++;
if (page_count > pages_left)
page_count= pages_left;
page_store(to, page);
to+= PAGE_STORE_SIZE;
pagerange_store(to, page_count);
to+= PAGERANGE_STORE_SIZE;
ranges++;
} while ((pages_left-= page_count));
/* Store number of ranges for this block */
int2store(to_start, ranges);
(*tot_ranges)+= ranges;
DBUG_RETURN(to);
} | O0 | c | store_page_range:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x8(%rbp), %rax
movl 0x7bc(%rax), %eax
movq -0x8(%rbp), %rcx
movl 0xc18(%rcx), %ecx
addl $0x8, %ecx
subl %ecx, %eax
subl $0x4, %eax
movl %eax, -0x2c(%rbp)
movq -0x20(%rbp), %rax
movl -0x2c(%rbp), %ecx
addq %rcx, %rax
subq $0x1, %rax
movl -0x2c(%rbp), %ecx
xorl %edx, %edx
divq %rcx
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x10(%rbp)
movq -0x38(%rbp), %rax
movl -0x2c(%rbp), %ecx
imulq %rcx, %rax
subq -0x20(%rbp), %rax
movl %eax, -0x44(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x58(%rbp)
movl -0x44(%rbp), %eax
movw %ax, %cx
movq -0x58(%rbp), %rax
movw %cx, (%rax)
movq -0x10(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x10(%rbp)
movl $0x0, -0x40(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x60(%rbp)
movq -0x18(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0x3c(%rbp)
movq -0x18(%rbp), %rax
addq $0x18, %rax
movq %rax, -0x18(%rbp)
movl -0x3c(%rbp), %eax
cmpq -0x38(%rbp), %rax
jbe 0x5f730
movq -0x38(%rbp), %rax
movl %eax, -0x3c(%rbp)
jmp 0x5f732
movq -0x10(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x60(%rbp), %rax
movl %eax, %ecx
movq -0x68(%rbp), %rax
movl %ecx, (%rax)
movq -0x60(%rbp), %rax
shrq $0x20, %rax
movb %al, %cl
movq -0x68(%rbp), %rax
movb %cl, 0x4(%rax)
movq -0x10(%rbp), %rax
addq $0x5, %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x70(%rbp)
movl -0x3c(%rbp), %eax
movw %ax, %cx
movq -0x70(%rbp), %rax
movw %cx, (%rax)
movq -0x10(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x10(%rbp)
movl -0x40(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x40(%rbp)
movl -0x3c(%rbp), %eax
movl %eax, %ecx
movq -0x38(%rbp), %rax
subq %rcx, %rax
movq %rax, -0x38(%rbp)
cmpq $0x0, %rax
jne 0x5f6ff
jmp 0x5f7a9
movq -0x50(%rbp), %rax
movq %rax, -0x78(%rbp)
movl -0x40(%rbp), %eax
movw %ax, %cx
movq -0x78(%rbp), %rax
movw %cx, (%rax)
movl -0x40(%rbp), %ecx
movq -0x28(%rbp), %rax
addl (%rax), %ecx
movl %ecx, (%rax)
movq -0x10(%rbp), %rax
movq %rax, -0x80(%rbp)
movq -0x80(%rbp), %rax
popq %rbp
retq
nopw (%rax,%rax)
| store_page_range:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov rax, [rbp+var_8]
mov eax, [rax+7BCh]
mov rcx, [rbp+var_8]
mov ecx, [rcx+0C18h]
add ecx, 8
sub eax, ecx
sub eax, 4
mov [rbp+var_2C], eax
mov rax, [rbp+var_20]
mov ecx, [rbp+var_2C]
add rax, rcx
sub rax, 1
mov ecx, [rbp+var_2C]
xor edx, edx
div rcx
mov [rbp+var_38], rax
mov rax, [rbp+var_10]
mov [rbp+var_50], rax
mov rax, [rbp+var_10]
add rax, 2
mov [rbp+var_10], rax
mov rax, [rbp+var_38]
mov ecx, [rbp+var_2C]
imul rax, rcx
sub rax, [rbp+var_20]
mov [rbp+var_44], eax
mov rax, [rbp+var_10]
mov [rbp+var_58], rax
mov eax, [rbp+var_44]
mov cx, ax
mov rax, [rbp+var_58]
mov [rax], cx
mov rax, [rbp+var_10]
add rax, 2
mov [rbp+var_10], rax
mov [rbp+var_40], 0
loc_5F6FF:
mov rax, [rbp+var_18]
mov rax, [rax]
mov [rbp+var_60], rax
mov rax, [rbp+var_18]
mov eax, [rax+8]
mov [rbp+var_3C], eax
mov rax, [rbp+var_18]
add rax, 18h
mov [rbp+var_18], rax
mov eax, [rbp+var_3C]
cmp rax, [rbp+var_38]
jbe short loc_5F730
mov rax, [rbp+var_38]
mov [rbp+var_3C], eax
loc_5F730:
jmp short $+2
loc_5F732:
mov rax, [rbp+var_10]
mov [rbp+var_68], rax
mov rax, [rbp+var_60]
mov ecx, eax
mov rax, [rbp+var_68]
mov [rax], ecx
mov rax, [rbp+var_60]
shr rax, 20h
mov cl, al
mov rax, [rbp+var_68]
mov [rax+4], cl
mov rax, [rbp+var_10]
add rax, 5
mov [rbp+var_10], rax
mov rax, [rbp+var_10]
mov [rbp+var_70], rax
mov eax, [rbp+var_3C]
mov cx, ax
mov rax, [rbp+var_70]
mov [rax], cx
mov rax, [rbp+var_10]
add rax, 2
mov [rbp+var_10], rax
mov eax, [rbp+var_40]
add eax, 1
mov [rbp+var_40], eax
mov eax, [rbp+var_3C]
mov ecx, eax
mov rax, [rbp+var_38]
sub rax, rcx
mov [rbp+var_38], rax
cmp rax, 0
jnz loc_5F6FF
jmp short $+2
loc_5F7A9:
mov rax, [rbp+var_50]
mov [rbp+var_78], rax
mov eax, [rbp+var_40]
mov cx, ax
mov rax, [rbp+var_78]
mov [rax], cx
mov ecx, [rbp+var_40]
mov rax, [rbp+var_28]
add ecx, [rax]
mov [rax], ecx
mov rax, [rbp+var_10]
mov [rbp+var_80], rax
mov rax, [rbp+var_80]
pop rbp
retn
| _WORD * store_page_range(long long a1, _WORD *a2, long long *a3, long long a4, _DWORD *a5)
{
long long v6; // [rsp+20h] [rbp-60h]
int v7; // [rsp+40h] [rbp-40h]
unsigned int v8; // [rsp+44h] [rbp-3Ch]
unsigned long long v9; // [rsp+48h] [rbp-38h]
unsigned int v10; // [rsp+54h] [rbp-2Ch]
_WORD *v12; // [rsp+70h] [rbp-10h]
v10 = *(_DWORD *)(a1 + 1980) - (*(_DWORD *)(a1 + 3096) + 8) - 4;
v9 = ((unsigned long long)v10 + a4 - 1) / v10;
a2[1] = v10 * v9 - a4;
v12 = a2 + 2;
v7 = 0;
do
{
v6 = *a3;
v8 = *((_DWORD *)a3 + 2);
a3 += 3;
if ( v8 > v9 )
v8 = v9;
*(_DWORD *)v12 = v6;
*((_BYTE *)v12 + 4) = BYTE4(v6);
*(_WORD *)((char *)v12 + 5) = v8;
v12 = (_WORD *)((char *)v12 + 7);
++v7;
v9 -= v8;
}
while ( v9 );
*a2 = v7;
*a5 += v7;
return v12;
}
| store_page_range:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x7bc]
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0xc18]
ADD ECX,0x8
SUB EAX,ECX
SUB EAX,0x4
MOV dword ptr [RBP + -0x2c],EAX
MOV RAX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RBP + -0x2c]
ADD RAX,RCX
SUB RAX,0x1
MOV ECX,dword ptr [RBP + -0x2c]
XOR EDX,EDX
DIV RCX
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x2
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV ECX,dword ptr [RBP + -0x2c]
IMUL RAX,RCX
SUB RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RBP + -0x44],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x58],RAX
MOV EAX,dword ptr [RBP + -0x44]
MOV CX,AX
MOV RAX,qword ptr [RBP + -0x58]
MOV word ptr [RAX],CX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x2
MOV qword ptr [RBP + -0x10],RAX
MOV dword ptr [RBP + -0x40],0x0
LAB_0015f6ff:
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV EAX,dword ptr [RAX + 0x8]
MOV dword ptr [RBP + -0x3c],EAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x18
MOV qword ptr [RBP + -0x18],RAX
MOV EAX,dword ptr [RBP + -0x3c]
CMP RAX,qword ptr [RBP + -0x38]
JBE 0x0015f730
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RBP + -0x3c],EAX
LAB_0015f730:
JMP 0x0015f732
LAB_0015f732:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RBP + -0x60]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x68]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x60]
SHR RAX,0x20
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x68]
MOV byte ptr [RAX + 0x4],CL
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x5
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x70],RAX
MOV EAX,dword ptr [RBP + -0x3c]
MOV CX,AX
MOV RAX,qword ptr [RBP + -0x70]
MOV word ptr [RAX],CX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x2
MOV qword ptr [RBP + -0x10],RAX
MOV EAX,dword ptr [RBP + -0x40]
ADD EAX,0x1
MOV dword ptr [RBP + -0x40],EAX
MOV EAX,dword ptr [RBP + -0x3c]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x38]
SUB RAX,RCX
MOV qword ptr [RBP + -0x38],RAX
CMP RAX,0x0
JNZ 0x0015f6ff
JMP 0x0015f7a9
LAB_0015f7a9:
MOV RAX,qword ptr [RBP + -0x50]
MOV qword ptr [RBP + -0x78],RAX
MOV EAX,dword ptr [RBP + -0x40]
MOV CX,AX
MOV RAX,qword ptr [RBP + -0x78]
MOV word ptr [RAX],CX
MOV ECX,dword ptr [RBP + -0x40]
MOV RAX,qword ptr [RBP + -0x28]
ADD ECX,dword ptr [RAX]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x80],RAX
MOV RAX,qword ptr [RBP + -0x80]
POP RBP
RET
|
int4 *
store_page_range(long param_1,int2 *param_2,int8 *param_3,long param_4,int *param_5)
{
int8 uVar1;
uint uVar2;
int local_48;
uint local_44;
ulong local_40;
int8 *local_20;
int4 *local_18;
uVar2 = (*(int *)(param_1 + 0x7bc) - (*(int *)(param_1 + 0xc18) + 8)) - 4;
local_40 = ((param_4 + (ulong)uVar2) - 1) / (ulong)uVar2;
param_2[1] = (short)local_40 * (short)uVar2 - (short)param_4;
local_18 = (int4 *)(param_2 + 2);
local_48 = 0;
local_20 = param_3;
do {
uVar1 = *local_20;
local_44 = *(uint *)(local_20 + 1);
local_20 = local_20 + 3;
if (local_40 < local_44) {
local_44 = (uint)local_40;
}
*local_18 = (int)uVar1;
*(char *)(local_18 + 1) = (char)((ulong)uVar1 >> 0x20);
*(short *)((long)local_18 + 5) = (short)local_44;
local_18 = (int4 *)((long)local_18 + 7);
local_48 = local_48 + 1;
local_40 = local_40 - local_44;
} while (local_40 != 0);
*param_2 = (short)local_48;
*param_5 = local_48 + *param_5;
return local_18;
}
| |
21,455 | madb_get_os_character_set | eloqsql/libmariadb/libmariadb/ma_charset.c | const char *madb_get_os_character_set()
{
unsigned int i= 0;
char *p= NULL;
#ifdef _WIN32
char codepage[FN_REFLEN];
snprintf(codepage, FN_REFLEN, "%u", GetConsoleCP() ? GetConsoleCP() : GetACP());
p= codepage;
#elif defined(HAVE_NL_LANGINFO) && defined(HAVE_SETLOCALE)
if (setlocale(LC_CTYPE, ""))
p= nl_langinfo(CODESET);
#endif
if (!p)
return MADB_DEFAULT_CHARSET_NAME;
while (MADB_OS_CHARSET[i].identifier)
{
if (MADB_OS_CHARSET[i].supported > MADB_CS_UNSUPPORTED &&
strcasecmp(MADB_OS_CHARSET[i].identifier, p) == 0)
return MADB_OS_CHARSET[i].charset;
i++;
}
return MADB_DEFAULT_CHARSET_NAME;
} | O0 | c | madb_get_os_character_set:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl $0x0, -0xc(%rbp)
movq $0x0, -0x18(%rbp)
xorl %edi, %edi
leaq 0x62bf7(%rip), %rsi # 0xcbf27
callq 0x367d0
cmpq $0x0, %rax
je 0x69349
movl $0xe, %edi
callq 0x36750
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x69360
leaq 0x6456d(%rip), %rax # 0xcd8c4
movq %rax, -0x8(%rbp)
jmp 0x693f1
jmp 0x69362
movl -0xc(%rbp), %eax
movl %eax, %ecx
leaq 0x1caf02(%rip), %rax # 0x234270
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
cmpq $0x0, (%rax)
je 0x693e6
movl -0xc(%rbp), %eax
movl %eax, %ecx
leaq 0x1caee9(%rip), %rax # 0x234270
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movzbl 0x20(%rax), %eax
cmpl $0x0, %eax
jle 0x693d8
movl -0xc(%rbp), %eax
movl %eax, %ecx
leaq 0x1caecd(%rip), %rax # 0x234270
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
callq 0x36810
cmpl $0x0, %eax
jne 0x693d8
movl -0xc(%rbp), %eax
movl %eax, %ecx
leaq 0x1caea9(%rip), %rax # 0x234270
imulq $0x28, %rcx, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rax
movq %rax, -0x8(%rbp)
jmp 0x693f1
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x69362
leaq 0x644d7(%rip), %rax # 0xcd8c4
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| madb_get_os_character_set:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_C], 0
mov [rbp+var_18], 0
xor edi, edi
lea rsi, aS+5; ""
call _setlocale
cmp rax, 0
jz short loc_69349
mov edi, 0Eh
call _nl_langinfo
mov [rbp+var_18], rax
loc_69349:
cmp [rbp+var_18], 0
jnz short loc_69360
lea rax, aLatin1; "latin1"
mov [rbp+var_8], rax
jmp loc_693F1
loc_69360:
jmp short $+2
loc_69362:
mov eax, [rbp+var_C]
mov ecx, eax
lea rax, MADB_OS_CHARSET
imul rcx, 28h ; '('
add rax, rcx
cmp qword ptr [rax], 0
jz short loc_693E6
mov eax, [rbp+var_C]
mov ecx, eax
lea rax, MADB_OS_CHARSET
imul rcx, 28h ; '('
add rax, rcx
movzx eax, byte ptr [rax+20h]
cmp eax, 0
jle short loc_693D8
mov eax, [rbp+var_C]
mov ecx, eax
lea rax, MADB_OS_CHARSET
imul rcx, 28h ; '('
add rax, rcx
mov rdi, [rax]
mov rsi, [rbp+var_18]
call _strcasecmp
cmp eax, 0
jnz short loc_693D8
mov eax, [rbp+var_C]
mov ecx, eax
lea rax, MADB_OS_CHARSET
imul rcx, 28h ; '('
add rax, rcx
mov rax, [rax+10h]
mov [rbp+var_8], rax
jmp short loc_693F1
loc_693D8:
mov eax, [rbp+var_C]
add eax, 1
mov [rbp+var_C], eax
jmp loc_69362
loc_693E6:
lea rax, aLatin1; "latin1"
mov [rbp+var_8], rax
loc_693F1:
mov rax, [rbp+var_8]
add rsp, 20h
pop rbp
retn
| const char *madb_get_os_character_set()
{
long long v1; // [rsp+8h] [rbp-18h]
unsigned int v2; // [rsp+14h] [rbp-Ch]
v2 = 0;
v1 = 0LL;
if ( setlocale(0LL, "") )
v1 = nl_langinfo(14LL);
if ( !v1 )
return "latin1";
while ( *(&MADB_OS_CHARSET + 5 * v2) )
{
if ( *((_BYTE *)&MADB_OS_CHARSET + 40 * v2 + 32) && !(unsigned int)strcasecmp(*(&MADB_OS_CHARSET + 5 * v2), v1) )
return (const char *)*(&MADB_OS_CHARSET + 5 * v2 + 2);
++v2;
}
return "latin1";
}
| madb_get_os_character_set:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV dword ptr [RBP + -0xc],0x0
MOV qword ptr [RBP + -0x18],0x0
XOR EDI,EDI
LEA RSI,[0x1cbf27]
CALL 0x001367d0
CMP RAX,0x0
JZ 0x00169349
MOV EDI,0xe
CALL 0x00136750
MOV qword ptr [RBP + -0x18],RAX
LAB_00169349:
CMP qword ptr [RBP + -0x18],0x0
JNZ 0x00169360
LEA RAX,[0x1cd8c4]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001693f1
LAB_00169360:
JMP 0x00169362
LAB_00169362:
MOV EAX,dword ptr [RBP + -0xc]
MOV ECX,EAX
LEA RAX,[0x334270]
IMUL RCX,RCX,0x28
ADD RAX,RCX
CMP qword ptr [RAX],0x0
JZ 0x001693e6
MOV EAX,dword ptr [RBP + -0xc]
MOV ECX,EAX
LEA RAX,[0x334270]
IMUL RCX,RCX,0x28
ADD RAX,RCX
MOVZX EAX,byte ptr [RAX + 0x20]
CMP EAX,0x0
JLE 0x001693d8
MOV EAX,dword ptr [RBP + -0xc]
MOV ECX,EAX
LEA RAX,[0x334270]
IMUL RCX,RCX,0x28
ADD RAX,RCX
MOV RDI,qword ptr [RAX]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x00136810
CMP EAX,0x0
JNZ 0x001693d8
MOV EAX,dword ptr [RBP + -0xc]
MOV ECX,EAX
LEA RAX,[0x334270]
IMUL RCX,RCX,0x28
ADD RAX,RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x001693f1
LAB_001693d8:
MOV EAX,dword ptr [RBP + -0xc]
ADD EAX,0x1
MOV dword ptr [RBP + -0xc],EAX
JMP 0x00169362
LAB_001693e6:
LEA RAX,[0x1cd8c4]
MOV qword ptr [RBP + -0x8],RAX
LAB_001693f1:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x20
POP RBP
RET
|
char * madb_get_os_character_set(void)
{
int iVar1;
char *pcVar2;
char *local_20;
uint local_14;
char *local_10;
local_14 = 0;
local_20 = (char *)0x0;
pcVar2 = setlocale(0,&DAT_001cbf27);
if (pcVar2 != (char *)0x0) {
local_20 = nl_langinfo(0xe);
}
if (local_20 != (char *)0x0) {
while (*(long *)(MADB_OS_CHARSET + (ulong)local_14 * 0x28) != 0) {
if ((MADB_OS_CHARSET[(ulong)local_14 * 0x28 + 0x20] != '\0') &&
(iVar1 = strcasecmp(*(char **)(MADB_OS_CHARSET + (ulong)local_14 * 0x28),local_20),
iVar1 == 0)) {
return *(char **)(MADB_OS_CHARSET + (ulong)local_14 * 0x28 + 0x10);
}
local_14 = local_14 + 1;
}
}
local_10 = "latin1";
return local_10;
}
| |
21,456 | ftxui::(anonymous namespace)::FocusCursor::Render(ftxui::Screen&) | Andrewchistyakov[P]flashcards_lyc/build_O0/_deps/ftxui-src/src/ftxui/dom/frame.cpp | void Render(Screen& screen) override {
Select::Render(screen); // NOLINT
screen.SetCursor(Screen::Cursor{
box_.x_min,
box_.y_min,
shape_,
});
} | O0 | cpp | ftxui::(anonymous namespace)::FocusCursor::Render(ftxui::Screen&):
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x38(%rbp)
movq -0x10(%rbp), %rsi
callq 0x446a0
movq -0x38(%rbp), %rax
movq -0x10(%rbp), %rdi
movl 0x4c(%rax), %ecx
movl %ecx, -0x1c(%rbp)
movl 0x54(%rax), %ecx
movl %ecx, -0x18(%rbp)
movl 0x5c(%rax), %eax
movl %eax, -0x14(%rbp)
movq -0x1c(%rbp), %rax
movq %rax, -0x2c(%rbp)
movl -0x14(%rbp), %eax
movl %eax, -0x24(%rbp)
movq -0x2c(%rbp), %rsi
movl -0x24(%rbp), %edx
callq 0x85130
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| _ZN5ftxui12_GLOBAL__N_111FocusCursor6RenderERNS_6ScreenE:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rdi, [rbp+var_8]; this
mov [rbp+var_38], rdi
mov rsi, [rbp+var_10]; ftxui::Screen *
call _ZN5ftxui4Node6RenderERNS_6ScreenE; ftxui::Node::Render(ftxui::Screen &)
mov rax, [rbp+var_38]
mov rdi, [rbp+var_10]
mov ecx, [rax+4Ch]
mov dword ptr [rbp+var_1C], ecx
mov ecx, [rax+54h]
mov dword ptr [rbp+var_1C+4], ecx
mov eax, [rax+5Ch]
mov [rbp+var_14], eax
mov rax, [rbp+var_1C]
mov [rbp+var_2C], rax
mov eax, [rbp+var_14]
mov [rbp+var_24], eax
mov rsi, [rbp+var_2C]
mov edx, [rbp+var_24]
call _ZN5ftxui6Screen9SetCursorENS0_6CursorE; ftxui::Screen::SetCursor(ftxui::Screen::Cursor)
add rsp, 40h
pop rbp
retn
| long long ftxui::`anonymous namespace'::FocusCursor::Render(
ftxui::_anonymous_namespace_::FocusCursor *this,
ftxui::Screen *a2)
{
long long v3; // [rsp+24h] [rbp-1Ch]
ftxui::Node::Render(this, a2);
LODWORD(v3) = *((_DWORD *)this + 19);
HIDWORD(v3) = *((_DWORD *)this + 21);
return ftxui::Screen::SetCursor(a2, v3, *((unsigned int *)this + 23));
}
| Render:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RDI,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x38],RDI
MOV RSI,qword ptr [RBP + -0x10]
CALL 0x001446a0
MOV RAX,qword ptr [RBP + -0x38]
MOV RDI,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x4c]
MOV dword ptr [RBP + -0x1c],ECX
MOV ECX,dword ptr [RAX + 0x54]
MOV dword ptr [RBP + -0x18],ECX
MOV EAX,dword ptr [RAX + 0x5c]
MOV dword ptr [RBP + -0x14],EAX
MOV RAX,qword ptr [RBP + -0x1c]
MOV qword ptr [RBP + -0x2c],RAX
MOV EAX,dword ptr [RBP + -0x14]
MOV dword ptr [RBP + -0x24],EAX
MOV RSI,qword ptr [RBP + -0x2c]
MOV EDX,dword ptr [RBP + -0x24]
CALL 0x00185130
ADD RSP,0x40
POP RBP
RET
|
/* ftxui::(anonymous namespace)::FocusCursor::Render(ftxui::Screen&) */
void __thiscall ftxui::(anonymous_namespace)::FocusCursor::Render(FocusCursor *this,Screen *param_1)
{
Node::Render((Node *)this,param_1);
Screen::SetCursor(param_1,CONCAT44(*(int4 *)(this + 0x54),*(int4 *)(this + 0x4c)),
*(int4 *)(this + 0x5c));
return;
}
| |
21,457 | foreach_function(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, std::function<void (nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&)> const&) | llama.cpp/common/chat.cpp | static void foreach_function(const json & tools, const std::function<void(const json &)> & fn) {
for (const auto & tool : tools) {
if (!tool.contains("type") || tool.at("type") != "function" || !tool.contains("function")) {
LOG_INF("Skipping tool without function: %s", tool.dump(2).c_str());
continue;
}
fn(tool);
}
} | O3 | cpp | foreach_function(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, std::function<void (nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&)> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rsi, (%rsp)
movq %rdi, %r14
leaq 0x48(%rsp), %r15
movq %rdi, (%r15)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%r15)
movabsq $-0x8000000000000000, %rbx # imm = 0x8000000000000000
movq %rbx, 0x18(%r15)
movq %r15, %rdi
callq 0xcfe78
leaq 0x28(%rsp), %r12
movq %r14, (%r12)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%r12)
movq %rbx, 0x18(%r12)
movq %r12, %rdi
callq 0xcfeea
movq %r15, %rdi
movq %r12, %rsi
callq 0xce0f6
testb %al, %al
jne 0x9c911
leaq 0x48(%rsp), %r14
leaq 0x7ed70(%rip), %r15 # 0x11b595
leaq 0xc70d4(%rip), %r12 # 0x163900
leaq 0x28(%rsp), %r13
movq %r14, %rdi
callq 0xaefd6
movq %rax, %rbp
movq %rax, %rdi
movq %r15, %rsi
callq 0xaf212
testb %al, %al
je 0x9c893
movq %rbp, %rdi
movq %r15, %rsi
callq 0xaf274
movq %rax, %rdi
leaq 0x7ec7c(%rip), %rsi # 0x11b4dc
callq 0xaf6bf
testb %al, %al
jne 0x9c893
movq %rbp, %rdi
leaq 0x7ec69(%rip), %rsi # 0x11b4dc
callq 0xaf9f6
testb %al, %al
je 0x9c893
movq (%rsp), %rdi
cmpq $0x0, 0x10(%rdi)
je 0x9c920
movq %rbp, %rsi
callq *0x18(%rdi)
jmp 0x9c8f6
cmpl $0x0, (%r12)
js 0x9c8f6
callq 0x10c85b
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
movq %rbp, %rsi
movl $0x2, %edx
movl $0x20, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0xaee5a
movq 0x8(%rsp), %rcx
movq %rbx, %rdi
movl $0x2, %esi
leaq 0x82caa(%rip), %rdx # 0x11f57d
xorl %eax, %eax
callq 0x10c8f8
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x9c8f6
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x20170
movq %r14, %rdi
callq 0xaf770
movq %r14, %rdi
movq %r13, %rsi
callq 0xce0f6
testb %al, %al
je 0x9c831
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x212c0
movq %rax, %rbx
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x9c944
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x20170
movq %rbx, %rdi
callq 0x20ae0
| _ZL16foreach_functionRKN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEERKSt8functionIFvSF_EE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 68h
mov [rsp+98h+var_98], rsi
mov r14, rdi
lea r15, [rsp+98h+var_50]
mov [r15], rdi
xorps xmm0, xmm0
movups xmmword ptr [r15+8], xmm0
mov rbx, 8000000000000000h
mov [r15+18h], rbx
mov rdi, r15
call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE9set_beginEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::set_begin(void)
lea r12, [rsp+98h+var_70]
mov [r12], r14
xorps xmm0, xmm0
movups xmmword ptr [r12+8], xmm0
mov [r12+18h], rbx
mov rdi, r12
call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::set_end(void)
mov rdi, r15
mov rsi, r12
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_
test al, al
jnz loc_9C911
lea r14, [rsp+98h+var_50]
lea r15, aUnknownBufferT+0Fh; "type"
lea r12, common_log_verbosity_thold
lea r13, [rsp+98h+var_70]
loc_9C831:
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEdeEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::operator*(void)
mov rbp, rax
mov rdi, rax
mov rsi, r15
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_
test al, al
jz short loc_9C893
mov rdi, rbp
mov rsi, r15
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_
mov rdi, rax
lea rsi, aFailedToFindRp_0+1Eh; "function"
call _ZN8nlohmann16json_abi_v3_11_3neIPKcTnNSt9enable_ifIXsr3std9is_scalarIT_EE5valueEiE4typeELi0EEEbRKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerESA_IhSaIhEEvEES5_
test al, al
jnz short loc_9C893
mov rdi, rbp
lea rsi, aFailedToFindRp_0+1Eh; "function"
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA9_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_
test al, al
jz short loc_9C893
mov rdi, [rsp+98h+var_98]
cmp qword ptr [rdi+10h], 0
jz loc_9C920
mov rsi, rbp
call qword ptr [rdi+18h]
jmp short loc_9C8F6
loc_9C893:
cmp dword ptr [r12], 0
js short loc_9C8F6
call _Z15common_log_mainv; common_log_main(void)
mov rbx, rax
lea rdi, [rsp+98h+var_90]
mov rsi, rbp
mov edx, 2
mov ecx, 20h ; ' '
xor r8d, r8d
xor r9d, r9d
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dumpEicbNS0_6detail15error_handler_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>::dump(int,char,bool,nlohmann::json_abi_v3_11_3::detail::error_handler_t)
mov rcx, [rsp+98h+var_90]
mov rdi, rbx
mov esi, 2
lea rdx, aSkippingToolWi; "Skipping tool without function: %s"
xor eax, eax
call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...)
mov rdi, [rsp+98h+var_90]; void *
lea rax, [rsp+98h+var_80]
cmp rdi, rax
jz short loc_9C8F6
mov rsi, [rsp+98h+var_80]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_9C8F6:
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEppEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::operator++(void)
mov rdi, r14
mov rsi, r13
call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_
test al, al
jz loc_9C831
loc_9C911:
add rsp, 68h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_9C920:
call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
mov rbx, rax
mov rdi, [rsp+98h+var_90]; void *
lea rax, [rsp+98h+var_80]
cmp rdi, rax
jz short loc_9C944
mov rsi, [rsp+98h+var_80]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_9C944:
mov rdi, rbx
call __Unwind_Resume
| long long foreach_function(long long a1, long long a2)
{
long long result; // rax
long long v3; // rbp
long long v4; // rax
int v5; // ebx
int v6; // r8d
int v7; // r9d
void *v8; // [rsp+8h] [rbp-90h] BYREF
long long v9; // [rsp+18h] [rbp-80h] BYREF
long long v10; // [rsp+28h] [rbp-70h] BYREF
__int128 v11; // [rsp+30h] [rbp-68h]
unsigned long long v12; // [rsp+40h] [rbp-58h]
long long v13; // [rsp+48h] [rbp-50h] BYREF
__int128 v14; // [rsp+50h] [rbp-48h]
unsigned long long v15; // [rsp+60h] [rbp-38h]
v13 = a1;
v14 = 0LL;
v15 = 0x8000000000000000LL;
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::set_begin(&v13);
v10 = a1;
v11 = 0LL;
v12 = 0x8000000000000000LL;
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::set_end(&v10);
for ( result = ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_(
&v13,
&v10);
!(_BYTE)result;
result = ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_(
&v13,
&v10) )
{
v3 = nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator*(&v13);
if ( (unsigned __int8)ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_(
v3,
"type")
&& (v4 = ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_(
v3,
"type"),
!(unsigned __int8)ZN8nlohmann16json_abi_v3_11_3neIPKcTnNSt9enable_ifIXsr3std9is_scalarIT_EE5valueEiE4typeELi0EEEbRKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerESA_IhSaIhEEvEES5_(
v4,
"function"))
&& (unsigned __int8)ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA9_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_(
v3,
"function") )
{
if ( !*(_QWORD *)(a2 + 16) )
std::__throw_bad_function_call();
(*(void ( **)(long long, long long))(a2 + 24))(a2, v3);
}
else if ( common_log_verbosity_thold >= 0 )
{
v5 = common_log_main();
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>::dump(
(unsigned int)&v8,
v3,
2,
32,
0,
0);
common_log_add(v5, 2, (unsigned int)"Skipping tool without function: %s", (_DWORD)v8, v6, v7);
if ( v8 != &v9 )
operator delete(v8, v9 + 1);
}
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator++(&v13);
}
return result;
}
| foreach_function:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x68
MOV qword ptr [RSP],RSI
MOV R14,RDI
LEA R15,[RSP + 0x48]
MOV qword ptr [R15],RDI
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R15 + 0x8],XMM0
MOV RBX,-0x8000000000000000
MOV qword ptr [R15 + 0x18],RBX
MOV RDI,R15
CALL 0x001cfe78
LEA R12,[RSP + 0x28]
MOV qword ptr [R12],R14
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R12 + 0x8],XMM0
MOV qword ptr [R12 + 0x18],RBX
MOV RDI,R12
CALL 0x001cfeea
MOV RDI,R15
MOV RSI,R12
CALL 0x001ce0f6
TEST AL,AL
JNZ 0x0019c911
LEA R14,[RSP + 0x48]
LEA R15,[0x21b595]
LEA R12,[0x263900]
LEA R13,[RSP + 0x28]
LAB_0019c831:
MOV RDI,R14
CALL 0x001aefd6
MOV RBP,RAX
MOV RDI,RAX
MOV RSI,R15
CALL 0x001af212
TEST AL,AL
JZ 0x0019c893
MOV RDI,RBP
MOV RSI,R15
CALL 0x001af274
MOV RDI,RAX
LEA RSI,[0x21b4dc]
CALL 0x001af6bf
TEST AL,AL
JNZ 0x0019c893
MOV RDI,RBP
LEA RSI,[0x21b4dc]
CALL 0x001af9f6
TEST AL,AL
JZ 0x0019c893
MOV RDI,qword ptr [RSP]
CMP qword ptr [RDI + 0x10],0x0
JZ 0x0019c920
MOV RSI,RBP
CALL qword ptr [RDI + 0x18]
JMP 0x0019c8f6
LAB_0019c893:
CMP dword ptr [R12],0x0
JS 0x0019c8f6
CALL 0x0020c85b
MOV RBX,RAX
LEA RDI,[RSP + 0x8]
MOV RSI,RBP
MOV EDX,0x2
MOV ECX,0x20
XOR R8D,R8D
XOR R9D,R9D
CALL 0x001aee5a
MOV RCX,qword ptr [RSP + 0x8]
LAB_0019c8c4:
MOV RDI,RBX
MOV ESI,0x2
LEA RDX,[0x21f57d]
XOR EAX,EAX
CALL 0x0020c8f8
LAB_0019c8da:
MOV RDI,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x18]
CMP RDI,RAX
JZ 0x0019c8f6
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x00120170
LAB_0019c8f6:
MOV RDI,R14
CALL 0x001af770
MOV RDI,R14
MOV RSI,R13
CALL 0x001ce0f6
TEST AL,AL
JZ 0x0019c831
LAB_0019c911:
ADD RSP,0x68
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0019c920:
CALL 0x001212c0
|
/* foreach_function(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const&, std::function<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> const&)> const&) */
void foreach_function(basic_json *param_1,function *param_2)
{
char cVar1;
int8 uVar2;
int8 uVar3;
long *local_90 [2];
long local_80 [2];
basic_json *local_70;
int8 local_68;
int8 uStack_60;
int8 local_58;
basic_json *local_50;
int8 local_48;
int8 uStack_40;
int8 local_38;
local_48 = 0;
uStack_40 = 0;
local_38 = 0x8000000000000000;
local_50 = param_1;
nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
::set_begin((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_50);
local_68 = 0;
uStack_60 = 0;
local_58 = 0x8000000000000000;
local_70 = param_1;
nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
::set_end((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_70);
cVar1 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_
((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_50,
(iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_70);
if (cVar1 == '\0') {
do {
uVar2 = nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
::operator*((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_50);
cVar1 = _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_
(uVar2,"type");
if (cVar1 == '\0') {
LAB_0019c893:
if (-1 < common_log_verbosity_thold) {
uVar3 = common_log_main();
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>
::dump(local_90,uVar2,2,0x20,0,0);
/* try { // try from 0019c8c4 to 0019c8d9 has its CatchHandler @ 0019c925 */
common_log_add(uVar3,2,"Skipping tool without function: %s",local_90[0]);
if (local_90[0] != local_80) {
operator_delete(local_90[0],local_80[0] + 1);
}
}
}
else {
uVar3 = _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_
(uVar2,"type");
cVar1 = _ZN8nlohmann16json_abi_v3_11_3neIPKcTnNSt9enable_ifIXsr3std9is_scalarIT_EE5valueEiE4typeELi0EEEbRKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerESA_IhSaIhEEvEES5_
(uVar3,"function");
if (cVar1 != '\0') goto LAB_0019c893;
cVar1 = _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA9_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_
(uVar2,"function");
if (cVar1 == '\0') goto LAB_0019c893;
if (*(long *)(param_2 + 0x10) == 0) {
/* WARNING: Subroutine does not return */
std::__throw_bad_function_call();
}
(**(code **)(param_2 + 0x18))(param_2,uVar2);
}
nlohmann::json_abi_v3_11_3::detail::
iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
::operator++((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_50);
cVar1 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_
((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)&local_50,&local_70);
} while (cVar1 == '\0');
}
return;
}
| |
21,458 | psi_rwlock_wrlock | eloqsql/mysys/my_thr_init.c | ATTRIBUTE_COLD
int psi_rwlock_wrlock(mysql_rwlock_t *that, const char *file, uint line)
{
PSI_rwlock_locker_state state;
PSI_rwlock_locker *locker= PSI_RWLOCK_CALL(start_rwlock_wrwait)
(&state, that->m_psi, PSI_RWLOCK_WRITELOCK, file, line);
int result= rw_wrlock(&that->m_rwlock);
if (locker)
PSI_RWLOCK_CALL(end_rwlock_wrwait)(locker, result);
return result;
} | O0 | c | psi_rwlock_wrlock:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
leaq 0x1af71e(%rip), %rax # 0x1e3e98
movq (%rax), %rax
movq 0x1b0(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x90(%rcx), %rsi
movq -0x10(%rbp), %rcx
movl -0x14(%rbp), %r8d
leaq -0x48(%rbp), %rdi
movl $0x1, %edx
callq *%rax
movq %rax, -0x50(%rbp)
movq -0x8(%rbp), %rdi
callq 0x34ce0
movl %eax, -0x54(%rbp)
cmpq $0x0, -0x50(%rbp)
je 0x347d3
leaq 0x1af6d8(%rip), %rax # 0x1e3e98
movq (%rax), %rax
movq 0x1b8(%rax), %rax
movq -0x50(%rbp), %rdi
movl -0x54(%rbp), %esi
callq *%rax
movl -0x54(%rbp), %eax
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
| psi_rwlock_wrlock:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+1B0h]
mov rcx, [rbp+var_8]
mov rsi, [rcx+90h]
mov rcx, [rbp+var_10]
mov r8d, [rbp+var_14]
lea rdi, [rbp+var_48]
mov edx, 1
call rax
mov [rbp+var_50], rax
mov rdi, [rbp+var_8]
call my_rw_wrlock
mov [rbp+var_54], eax
cmp [rbp+var_50], 0
jz short loc_347D3
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+1B8h]
mov rdi, [rbp+var_50]
mov esi, [rbp+var_54]
call rax
loc_347D3:
mov eax, [rbp+var_54]
add rsp, 60h
pop rbp
retn
| long long psi_rwlock_wrlock(long long a1, long long a2, unsigned int a3)
{
unsigned int v4; // [rsp+Ch] [rbp-54h]
long long v5; // [rsp+10h] [rbp-50h]
_BYTE v6[52]; // [rsp+18h] [rbp-48h] BYREF
unsigned int v7; // [rsp+4Ch] [rbp-14h]
long long v8; // [rsp+50h] [rbp-10h]
long long v9; // [rsp+58h] [rbp-8h]
v9 = a1;
v8 = a2;
v7 = a3;
v5 = (*((long long ( **)(_BYTE *, _QWORD, long long, long long, _QWORD))PSI_server + 54))(
v6,
*(_QWORD *)(a1 + 144),
1LL,
a2,
a3);
v4 = my_rw_wrlock(v9);
if ( v5 )
(*((void ( **)(long long, _QWORD))PSI_server + 55))(v5, v4);
return v4;
}
| psi_rwlock_wrlock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
LEA RAX,[0x2e3e98]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x1b0]
MOV RCX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RCX + 0x90]
MOV RCX,qword ptr [RBP + -0x10]
MOV R8D,dword ptr [RBP + -0x14]
LEA RDI,[RBP + -0x48]
MOV EDX,0x1
CALL RAX
MOV qword ptr [RBP + -0x50],RAX
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00134ce0
MOV dword ptr [RBP + -0x54],EAX
CMP qword ptr [RBP + -0x50],0x0
JZ 0x001347d3
LEA RAX,[0x2e3e98]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x1b8]
MOV RDI,qword ptr [RBP + -0x50]
MOV ESI,dword ptr [RBP + -0x54]
CALL RAX
LAB_001347d3:
MOV EAX,dword ptr [RBP + -0x54]
ADD RSP,0x60
POP RBP
RET
|
int4 psi_rwlock_wrlock(long param_1,int8 param_2,int4 param_3)
{
int4 uVar1;
long lVar2;
int1 local_50 [52];
int4 local_1c;
int8 local_18;
long local_10;
local_1c = param_3;
local_18 = param_2;
local_10 = param_1;
lVar2 = (**(code **)(PSI_server + 0x1b0))
(local_50,*(int8 *)(param_1 + 0x90),1,param_2,param_3);
uVar1 = my_rw_wrlock(local_10);
if (lVar2 != 0) {
(**(code **)(PSI_server + 0x1b8))(lVar2,uVar1);
}
return uVar1;
}
| |
21,459 | psi_rwlock_wrlock | eloqsql/mysys/my_thr_init.c | ATTRIBUTE_COLD
int psi_rwlock_wrlock(mysql_rwlock_t *that, const char *file, uint line)
{
PSI_rwlock_locker_state state;
PSI_rwlock_locker *locker= PSI_RWLOCK_CALL(start_rwlock_wrwait)
(&state, that->m_psi, PSI_RWLOCK_WRITELOCK, file, line);
int result= rw_wrlock(&that->m_rwlock);
if (locker)
PSI_RWLOCK_CALL(end_rwlock_wrwait)(locker, result);
return result;
} | O3 | c | psi_rwlock_wrlock:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x38, %rsp
movl %edx, %r8d
movq %rsi, %rcx
movq %rdi, %r14
leaq 0x2d54f4(%rip), %r15 # 0x2f9e58
movq (%r15), %rax
movq 0x90(%rdi), %rsi
leaq -0x48(%rbp), %rdi
pushq $0x1
popq %rdx
callq *0x1b0(%rax)
movq %rax, %rbx
movq %r14, %rdi
callq 0x2f2d9
movl %eax, %r14d
testq %rbx, %rbx
je 0x2499d
movq (%r15), %rax
movq %rbx, %rdi
movl %r14d, %esi
callq *0x1b8(%rax)
movl %r14d, %eax
addq $0x38, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| psi_rwlock_wrlock:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
sub rsp, 38h
mov r8d, edx
mov rcx, rsi
mov r14, rdi
lea r15, PSI_server
mov rax, [r15]
mov rsi, [rdi+90h]
lea rdi, [rbp+var_48]
push 1
pop rdx
call qword ptr [rax+1B0h]
mov rbx, rax
mov rdi, r14
call my_rw_wrlock
mov r14d, eax
test rbx, rbx
jz short loc_2499D
mov rax, [r15]
mov rdi, rbx
mov esi, r14d
call qword ptr [rax+1B8h]
loc_2499D:
mov eax, r14d
add rsp, 38h
pop rbx
pop r14
pop r15
pop rbp
retn
| long long psi_rwlock_wrlock(long long a1, long long a2, unsigned int a3)
{
long long v3; // rbx
unsigned int v4; // r14d
_BYTE v6[72]; // [rsp+8h] [rbp-48h] BYREF
v3 = (*((long long ( **)(_BYTE *, _QWORD, long long, long long, _QWORD))PSI_server + 54))(
v6,
*(_QWORD *)(a1 + 144),
1LL,
a2,
a3);
v4 = my_rw_wrlock(a1);
if ( v3 )
(*((void ( **)(long long, _QWORD))PSI_server + 55))(v3, v4);
return v4;
}
| psi_rwlock_wrlock:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x38
MOV R8D,EDX
MOV RCX,RSI
MOV R14,RDI
LEA R15,[0x3f9e58]
MOV RAX,qword ptr [R15]
MOV RSI,qword ptr [RDI + 0x90]
LEA RDI,[RBP + -0x48]
PUSH 0x1
POP RDX
CALL qword ptr [RAX + 0x1b0]
MOV RBX,RAX
MOV RDI,R14
CALL 0x0012f2d9
MOV R14D,EAX
TEST RBX,RBX
JZ 0x0012499d
MOV RAX,qword ptr [R15]
MOV RDI,RBX
MOV ESI,R14D
CALL qword ptr [RAX + 0x1b8]
LAB_0012499d:
MOV EAX,R14D
ADD RSP,0x38
POP RBX
POP R14
POP R15
POP RBP
RET
|
int4 psi_rwlock_wrlock(long param_1,int8 param_2,int4 param_3)
{
int4 uVar1;
long lVar2;
int1 local_50 [48];
lVar2 = (**(code **)(PSI_server + 0x1b0))
(local_50,*(int8 *)(param_1 + 0x90),1,param_2,param_3);
uVar1 = my_rw_wrlock(param_1);
if (lVar2 != 0) {
(**(code **)(PSI_server + 0x1b8))(lVar2,uVar1);
}
return uVar1;
}
| |
21,460 | MyCTX::update(unsigned char const*, unsigned int, unsigned char*, unsigned int*) | eloqsql/mysys_ssl/my_crypt.cc | virtual int update(const uchar *src, uint slen, uchar *dst, uint *dlen)
{
#ifdef HAVE_WOLFSSL
// WolfSSL checks parameters and does not like NULL pointers to be passed to function below.
if (!src)
{
static uchar dummy[MY_AES_BLOCK_SIZE];
DBUG_ASSERT(!slen);
src=dummy;
}
#endif
if (EVP_CipherUpdate(ctx, dst, (int*)dlen, src, slen) != 1)
return MY_AES_OPENSSL_ERROR;
return MY_AES_OK;
} | O3 | cpp | MyCTX::update(unsigned char const*, unsigned int, unsigned char*, unsigned int*):
pushq %rbp
movq %rsp, %rbp
movl %edx, %eax
movq %rsi, %r9
movq 0xc8(%rdi), %rdi
movq %rcx, %rsi
movq %r8, %rdx
movq %r9, %rcx
movl %eax, %r8d
callq 0x29890
xorl %ecx, %ecx
cmpl $0x1, %eax
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmovel %ecx, %eax
popq %rbp
retq
| _ZN5MyCTX6updateEPKhjPhPj:
push rbp
mov rbp, rsp
mov eax, edx
mov r9, rsi
mov rdi, [rdi+0C8h]
mov rsi, rcx
mov rdx, r8
mov rcx, r9
mov r8d, eax
call _EVP_CipherUpdate
xor ecx, ecx
cmp eax, 1
mov eax, 0FFFFFF9Bh
cmovz eax, ecx
pop rbp
retn
| long long MyCTX::update(
MyCTX *this,
const unsigned __int8 *a2,
unsigned int a3,
unsigned __int8 *a4,
unsigned int *a5)
{
bool v5; // zf
long long result; // rax
v5 = (unsigned int)EVP_CipherUpdate(*((_QWORD *)this + 25), a4, a5, a2) == 1;
result = 4294967195LL;
if ( v5 )
return 0LL;
return result;
}
| update:
PUSH RBP
MOV RBP,RSP
MOV EAX,EDX
MOV R9,RSI
MOV RDI,qword ptr [RDI + 0xc8]
MOV RSI,RCX
MOV RDX,R8
MOV RCX,R9
MOV R8D,EAX
CALL 0x00129890
XOR ECX,ECX
CMP EAX,0x1
MOV EAX,0xffffff9b
CMOVZ EAX,ECX
POP RBP
RET
|
/* MyCTX::update(unsigned char const*, unsigned int, unsigned char*, unsigned int*) */
int8 __thiscall
MyCTX::update(MyCTX *this,uchar *param_1,uint param_2,uchar *param_3,uint *param_4)
{
int iVar1;
int8 uVar2;
iVar1 = EVP_CipherUpdate(*(EVP_CIPHER_CTX **)(this + 200),param_3,(int *)param_4,param_1,param_2);
uVar2 = 0xffffff9b;
if (iVar1 == 1) {
uVar2 = 0;
}
return uVar2;
}
| |
21,461 | add_scope_var | bluesky950520[P]quickjs/quickjs.c | static int add_scope_var(JSContext *ctx, JSFunctionDef *fd, JSAtom name,
JSVarKindEnum var_kind)
{
int idx = add_var(ctx, fd, name);
if (idx >= 0) {
JSVarDef *vd = &fd->vars[idx];
vd->var_kind = var_kind;
vd->scope_level = fd->scope_level;
vd->scope_next = fd->scope_first;
fd->scopes[fd->scope_level].first = idx;
fd->scope_first = idx;
}
return idx;
} | O1 | c | add_scope_var:
pushq %rbp
pushq %rbx
pushq %rax
movl %ecx, %ebp
movq %rsi, %rbx
callq 0x5d24a
testl %eax, %eax
js 0x64697
movq 0x90(%rbx), %rcx
movl %eax, %edx
shlq $0x4, %rdx
shll $0x4, %ebp
movzbl %bpl, %esi
movl $0xffffff0f, %edi # imm = 0xFFFFFF0F
andl 0xc(%rcx,%rdx), %edi
orl %esi, %edi
movl %edi, 0xc(%rcx,%rdx)
movq 0xe8(%rbx), %rsi
movq %rsi, 0x4(%rcx,%rdx)
movq 0xf8(%rbx), %rcx
movslq %esi, %rdx
movl %eax, 0x4(%rcx,%rdx,8)
movl %eax, 0xec(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| add_scope_var:
push rbp
push rbx
push rax
mov ebp, ecx
mov rbx, rsi
call add_var
test eax, eax
js short loc_64697
mov rcx, [rbx+90h]
mov edx, eax
shl rdx, 4
shl ebp, 4
movzx esi, bpl
mov edi, 0FFFFFF0Fh
and edi, [rcx+rdx+0Ch]
or edi, esi
mov [rcx+rdx+0Ch], edi
mov rsi, [rbx+0E8h]
mov [rcx+rdx+4], rsi
mov rcx, [rbx+0F8h]
movsxd rdx, esi
mov [rcx+rdx*8+4], eax
mov [rbx+0ECh], eax
loc_64697:
add rsp, 8
pop rbx
pop rbp
retn
| long long add_scope_var(
long long a1,
long long a2,
int a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14)
{
char v14; // bp
long long result; // rax
long long v17; // rcx
long long v18; // rdx
long long v19; // rsi
v14 = a4;
result = add_var(a1, a2, a3, a4, a7, a8, a9, a10, a11, a12, a13, a14, a5, a6);
if ( (int)result >= 0 )
{
v17 = *(_QWORD *)(a2 + 144);
v18 = 16LL * (unsigned int)result;
*(_DWORD *)(v17 + v18 + 12) = (unsigned __int8)(16 * v14) | *(_DWORD *)(v17 + v18 + 12) & 0xFFFFFF0F;
v19 = *(_QWORD *)(a2 + 232);
*(_QWORD *)(v17 + v18 + 4) = v19;
*(_DWORD *)(*(_QWORD *)(a2 + 248) + 8LL * (int)v19 + 4) = result;
*(_DWORD *)(a2 + 236) = result;
}
return result;
}
| add_scope_var:
PUSH RBP
PUSH RBX
PUSH RAX
MOV EBP,ECX
MOV RBX,RSI
CALL 0x0015d24a
TEST EAX,EAX
JS 0x00164697
MOV RCX,qword ptr [RBX + 0x90]
MOV EDX,EAX
SHL RDX,0x4
SHL EBP,0x4
MOVZX ESI,BPL
MOV EDI,0xffffff0f
AND EDI,dword ptr [RCX + RDX*0x1 + 0xc]
OR EDI,ESI
MOV dword ptr [RCX + RDX*0x1 + 0xc],EDI
MOV RSI,qword ptr [RBX + 0xe8]
MOV qword ptr [RCX + RDX*0x1 + 0x4],RSI
MOV RCX,qword ptr [RBX + 0xf8]
MOVSXD RDX,ESI
MOV dword ptr [RCX + RDX*0x8 + 0x4],EAX
MOV dword ptr [RBX + 0xec],EAX
LAB_00164697:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
void add_scope_var(int8 param_1,long param_2,int8 param_3,uint param_4)
{
long lVar1;
int8 uVar2;
uint uVar3;
long lVar4;
uVar3 = add_var();
if (-1 < (int)uVar3) {
lVar1 = *(long *)(param_2 + 0x90);
lVar4 = (ulong)uVar3 * 0x10;
*(uint *)(lVar1 + 0xc + lVar4) =
*(uint *)(lVar1 + 0xc + lVar4) & 0xffffff0f | (param_4 & 0xf) << 4;
uVar2 = *(int8 *)(param_2 + 0xe8);
*(int8 *)(lVar1 + 4 + lVar4) = uVar2;
*(uint *)(*(long *)(param_2 + 0xf8) + 4 + (long)(int)uVar2 * 8) = uVar3;
*(uint *)(param_2 + 0xec) = uVar3;
}
return;
}
| |
21,462 | add_scope_var | bluesky950520[P]quickjs/quickjs.c | static int add_scope_var(JSContext *ctx, JSFunctionDef *fd, JSAtom name,
JSVarKindEnum var_kind)
{
int idx = add_var(ctx, fd, name);
if (idx >= 0) {
JSVarDef *vd = &fd->vars[idx];
vd->var_kind = var_kind;
vd->scope_level = fd->scope_level;
vd->scope_next = fd->scope_first;
fd->scopes[fd->scope_level].first = idx;
fd->scope_first = idx;
}
return idx;
} | O3 | c | add_scope_var:
pushq %rbp
pushq %rbx
pushq %rax
movl %ecx, %ebp
movq %rsi, %rbx
callq 0x600f8
testl %eax, %eax
js 0x66ef0
movq 0x90(%rbx), %rcx
movl %eax, %edx
shlq $0x4, %rdx
shll $0x4, %ebp
movzbl %bpl, %esi
movl $0xffffff0f, %edi # imm = 0xFFFFFF0F
andl 0xc(%rcx,%rdx), %edi
orl %esi, %edi
movl %edi, 0xc(%rcx,%rdx)
movq 0xe8(%rbx), %rsi
movq %rsi, 0x4(%rcx,%rdx)
movq 0xf8(%rbx), %rcx
movslq %esi, %rdx
movl %eax, 0x4(%rcx,%rdx,8)
movl %eax, 0xec(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| add_scope_var:
push rbp
push rbx
push rax
mov ebp, ecx
mov rbx, rsi
call add_var
test eax, eax
js short loc_66EF0
mov rcx, [rbx+90h]
mov edx, eax
shl rdx, 4
shl ebp, 4
movzx esi, bpl
mov edi, 0FFFFFF0Fh
and edi, [rcx+rdx+0Ch]
or edi, esi
mov [rcx+rdx+0Ch], edi
mov rsi, [rbx+0E8h]
mov [rcx+rdx+4], rsi
mov rcx, [rbx+0F8h]
movsxd rdx, esi
mov [rcx+rdx*8+4], eax
mov [rbx+0ECh], eax
loc_66EF0:
add rsp, 8
pop rbx
pop rbp
retn
| long long add_scope_var(
long long a1,
long long a2,
int a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14)
{
char v14; // bp
long long result; // rax
long long v17; // rcx
long long v18; // rdx
long long v19; // rsi
v14 = a4;
result = add_var(a1, a2, a3, a4, a7, a8, a9, a10, a11, a12, a13, a14, a5, a6);
if ( (int)result >= 0 )
{
v17 = *(_QWORD *)(a2 + 144);
v18 = 16LL * (unsigned int)result;
*(_DWORD *)(v17 + v18 + 12) = (unsigned __int8)(16 * v14) | *(_DWORD *)(v17 + v18 + 12) & 0xFFFFFF0F;
v19 = *(_QWORD *)(a2 + 232);
*(_QWORD *)(v17 + v18 + 4) = v19;
*(_DWORD *)(*(_QWORD *)(a2 + 248) + 8LL * (int)v19 + 4) = result;
*(_DWORD *)(a2 + 236) = result;
}
return result;
}
| add_scope_var:
PUSH RBP
PUSH RBX
PUSH RAX
MOV EBP,ECX
MOV RBX,RSI
CALL 0x001600f8
TEST EAX,EAX
JS 0x00166ef0
MOV RCX,qword ptr [RBX + 0x90]
MOV EDX,EAX
SHL RDX,0x4
SHL EBP,0x4
MOVZX ESI,BPL
MOV EDI,0xffffff0f
AND EDI,dword ptr [RCX + RDX*0x1 + 0xc]
OR EDI,ESI
MOV dword ptr [RCX + RDX*0x1 + 0xc],EDI
MOV RSI,qword ptr [RBX + 0xe8]
MOV qword ptr [RCX + RDX*0x1 + 0x4],RSI
MOV RCX,qword ptr [RBX + 0xf8]
MOVSXD RDX,ESI
MOV dword ptr [RCX + RDX*0x8 + 0x4],EAX
MOV dword ptr [RBX + 0xec],EAX
LAB_00166ef0:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
void add_scope_var(int8 param_1,long param_2,int8 param_3,uint param_4)
{
long lVar1;
int8 uVar2;
uint uVar3;
long lVar4;
uVar3 = add_var();
if (-1 < (int)uVar3) {
lVar1 = *(long *)(param_2 + 0x90);
lVar4 = (ulong)uVar3 * 0x10;
*(uint *)(lVar1 + 0xc + lVar4) =
*(uint *)(lVar1 + 0xc + lVar4) & 0xffffff0f | (param_4 & 0xf) << 4;
uVar2 = *(int8 *)(param_2 + 0xe8);
*(int8 *)(lVar1 + 4 + lVar4) = uVar2;
*(uint *)(*(long *)(param_2 + 0xf8) + 4 + (long)(int)uVar2 * 8) = uVar3;
*(uint *)(param_2 + 0xec) = uVar3;
}
return;
}
| |
21,463 | thr_unlock | eloqsql/mysys/thr_lock.c | void thr_unlock(THR_LOCK_DATA *data, uint unlock_flags)
{
THR_LOCK *lock=data->lock;
enum thr_lock_type lock_type=data->type;
DBUG_ENTER("thr_unlock");
DBUG_PRINT("lock",("data: %p thread: %lu lock: %p",
data, (ulong) data->owner->thread_id,
lock));
mysql_mutex_lock(&lock->mutex);
check_locks(lock,"start of release lock", lock_type, 0);
if (((*data->prev)=data->next)) /* remove from lock-list */
data->next->prev= data->prev;
else if (lock_type <= TL_READ_NO_INSERT)
lock->read.last=data->prev;
else if (lock_type == TL_WRITE_DELAYED && data->cond)
{
/*
This only happens in extreme circumstances when a
write delayed lock that is waiting for a lock
*/
lock->write_wait.last=data->prev; /* Put it on wait queue */
}
else
lock->write.last=data->prev;
if (unlock_flags & THR_UNLOCK_UPDATE_STATUS)
{
/* External lock was not called; Update or restore status */
if (lock_type >= TL_WRITE_CONCURRENT_INSERT)
{
if (lock->update_status)
(*lock->update_status)(data->status_param);
}
else
{
if (lock->restore_status)
(*lock->restore_status)(data->status_param);
}
}
if (lock_type == TL_READ_NO_INSERT)
lock->read_no_write_count--;
data->type=TL_UNLOCK; /* Mark unlocked */
wake_up_waiters(lock);
mysql_mutex_unlock(&lock->mutex);
DBUG_VOID_RETURN;
} | O0 | c | thr_unlock:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl 0x40(%rax), %eax
movl %eax, -0x1c(%rbp)
jmp 0x87bc7
movq -0x18(%rbp), %rdi
addq $0x18, %rdi
leaq 0x55f1f(%rip), %rsi # 0xddaf5
movl $0x3c0, %edx # imm = 0x3C0
callq 0x87950
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x10(%rcx), %rcx
movq %rax, (%rcx)
cmpq $0x0, %rax
je 0x87c0f
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movq %rcx, 0x10(%rax)
jmp 0x87c64
cmpl $0x5, -0x1c(%rbp)
jg 0x87c27
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x78(%rax)
jmp 0x87c62
cmpl $0x9, -0x1c(%rbp)
jne 0x87c4d
movq -0x8(%rbp), %rax
cmpq $0x0, 0x20(%rax)
je 0x87c4d
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x88(%rax)
jmp 0x87c60
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x98(%rax)
jmp 0x87c62
jmp 0x87c64
movl -0xc(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x87cc1
cmpl $0x8, -0x1c(%rbp)
jl 0x87c9a
movq -0x18(%rbp), %rax
cmpq $0x0, 0xc0(%rax)
je 0x87c98
movq -0x18(%rbp), %rax
movq 0xc0(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x28(%rcx), %rdi
callq *%rax
jmp 0x87cbf
movq -0x18(%rbp), %rax
cmpq $0x0, 0xc8(%rax)
je 0x87cbd
movq -0x18(%rbp), %rax
movq 0xc8(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x28(%rcx), %rdi
callq *%rax
jmp 0x87cbf
jmp 0x87cc1
cmpl $0x5, -0x1c(%rbp)
jne 0x87cda
movq -0x18(%rbp), %rax
movl 0xa8(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0xa8(%rax)
movq -0x8(%rbp), %rax
movl $0x0, 0x40(%rax)
movq -0x18(%rbp), %rdi
callq 0x87d10
movq -0x18(%rbp), %rdi
addq $0x18, %rdi
callq 0x879c0
jmp 0x87cfd
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| thr_unlock:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov rax, [rbp+var_8]
mov rax, [rax+18h]
mov [rbp+var_18], rax
mov rax, [rbp+var_8]
mov eax, [rax+40h]
mov [rbp+var_1C], eax
jmp short $+2
loc_87BC7:
mov rdi, [rbp+var_18]
add rdi, 18h
lea rsi, aWorkspaceLlm4b_25; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 3C0h
call inline_mysql_mutex_lock_12
mov rax, [rbp+var_8]
mov rax, [rax+8]
mov rcx, [rbp+var_8]
mov rcx, [rcx+10h]
mov [rcx], rax
cmp rax, 0
jz short loc_87C0F
mov rax, [rbp+var_8]
mov rcx, [rax+10h]
mov rax, [rbp+var_8]
mov rax, [rax+8]
mov [rax+10h], rcx
jmp short loc_87C64
loc_87C0F:
cmp [rbp+var_1C], 5
jg short loc_87C27
mov rax, [rbp+var_8]
mov rcx, [rax+10h]
mov rax, [rbp+var_18]
mov [rax+78h], rcx
jmp short loc_87C62
loc_87C27:
cmp [rbp+var_1C], 9
jnz short loc_87C4D
mov rax, [rbp+var_8]
cmp qword ptr [rax+20h], 0
jz short loc_87C4D
mov rax, [rbp+var_8]
mov rcx, [rax+10h]
mov rax, [rbp+var_18]
mov [rax+88h], rcx
jmp short loc_87C60
loc_87C4D:
mov rax, [rbp+var_8]
mov rcx, [rax+10h]
mov rax, [rbp+var_18]
mov [rax+98h], rcx
loc_87C60:
jmp short $+2
loc_87C62:
jmp short $+2
loc_87C64:
mov eax, [rbp+var_C]
and eax, 1
cmp eax, 0
jz short loc_87CC1
cmp [rbp+var_1C], 8
jl short loc_87C9A
mov rax, [rbp+var_18]
cmp qword ptr [rax+0C0h], 0
jz short loc_87C98
mov rax, [rbp+var_18]
mov rax, [rax+0C0h]
mov rcx, [rbp+var_8]
mov rdi, [rcx+28h]
call rax
loc_87C98:
jmp short loc_87CBF
loc_87C9A:
mov rax, [rbp+var_18]
cmp qword ptr [rax+0C8h], 0
jz short loc_87CBD
mov rax, [rbp+var_18]
mov rax, [rax+0C8h]
mov rcx, [rbp+var_8]
mov rdi, [rcx+28h]
call rax
loc_87CBD:
jmp short $+2
loc_87CBF:
jmp short $+2
loc_87CC1:
cmp [rbp+var_1C], 5
jnz short loc_87CDA
mov rax, [rbp+var_18]
mov ecx, [rax+0A8h]
add ecx, 0FFFFFFFFh
mov [rax+0A8h], ecx
loc_87CDA:
mov rax, [rbp+var_8]
mov dword ptr [rax+40h], 0
mov rdi, [rbp+var_18]
call wake_up_waiters
mov rdi, [rbp+var_18]
add rdi, 18h
call inline_mysql_mutex_unlock_12
jmp short $+2
loc_87CFD:
add rsp, 20h
pop rbp
retn
| long long thr_unlock(long long a1, char a2)
{
long long v2; // rax
int v4; // [rsp+4h] [rbp-1Ch]
long long v5; // [rsp+8h] [rbp-18h]
v5 = *(_QWORD *)(a1 + 24);
v4 = *(_DWORD *)(a1 + 64);
inline_mysql_mutex_lock_12(v5 + 24, (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/thr_lock.c", 0x3C0u);
v2 = *(_QWORD *)(a1 + 8);
**(_QWORD **)(a1 + 16) = v2;
if ( v2 )
{
*(_QWORD *)(*(_QWORD *)(a1 + 8) + 16LL) = *(_QWORD *)(a1 + 16);
}
else if ( v4 > 5 )
{
if ( v4 == 9 && *(_QWORD *)(a1 + 32) )
*(_QWORD *)(v5 + 136) = *(_QWORD *)(a1 + 16);
else
*(_QWORD *)(v5 + 152) = *(_QWORD *)(a1 + 16);
}
else
{
*(_QWORD *)(v5 + 120) = *(_QWORD *)(a1 + 16);
}
if ( (a2 & 1) != 0 )
{
if ( v4 < 8 )
{
if ( *(_QWORD *)(v5 + 200) )
(*(void ( **)(_QWORD))(v5 + 200))(*(_QWORD *)(a1 + 40));
}
else if ( *(_QWORD *)(v5 + 192) )
{
(*(void ( **)(_QWORD))(v5 + 192))(*(_QWORD *)(a1 + 40));
}
}
if ( v4 == 5 )
--*(_DWORD *)(v5 + 168);
*(_DWORD *)(a1 + 64) = 0;
wake_up_waiters(v5);
return inline_mysql_mutex_unlock_12(v5 + 24);
}
| thr_unlock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x40]
MOV dword ptr [RBP + -0x1c],EAX
JMP 0x00187bc7
LAB_00187bc7:
MOV RDI,qword ptr [RBP + -0x18]
ADD RDI,0x18
LEA RSI,[0x1ddaf5]
MOV EDX,0x3c0
CALL 0x00187950
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV RCX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RCX + 0x10]
MOV qword ptr [RCX],RAX
CMP RAX,0x0
JZ 0x00187c0f
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RAX + 0x10],RCX
JMP 0x00187c64
LAB_00187c0f:
CMP dword ptr [RBP + -0x1c],0x5
JG 0x00187c27
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x78],RCX
JMP 0x00187c62
LAB_00187c27:
CMP dword ptr [RBP + -0x1c],0x9
JNZ 0x00187c4d
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x20],0x0
JZ 0x00187c4d
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x88],RCX
JMP 0x00187c60
LAB_00187c4d:
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x98],RCX
LAB_00187c60:
JMP 0x00187c62
LAB_00187c62:
JMP 0x00187c64
LAB_00187c64:
MOV EAX,dword ptr [RBP + -0xc]
AND EAX,0x1
CMP EAX,0x0
JZ 0x00187cc1
CMP dword ptr [RBP + -0x1c],0x8
JL 0x00187c9a
MOV RAX,qword ptr [RBP + -0x18]
CMP qword ptr [RAX + 0xc0],0x0
JZ 0x00187c98
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0xc0]
MOV RCX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RCX + 0x28]
CALL RAX
LAB_00187c98:
JMP 0x00187cbf
LAB_00187c9a:
MOV RAX,qword ptr [RBP + -0x18]
CMP qword ptr [RAX + 0xc8],0x0
JZ 0x00187cbd
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX + 0xc8]
MOV RCX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RCX + 0x28]
CALL RAX
LAB_00187cbd:
JMP 0x00187cbf
LAB_00187cbf:
JMP 0x00187cc1
LAB_00187cc1:
CMP dword ptr [RBP + -0x1c],0x5
JNZ 0x00187cda
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RAX + 0xa8]
ADD ECX,-0x1
MOV dword ptr [RAX + 0xa8],ECX
LAB_00187cda:
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x40],0x0
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00187d10
MOV RDI,qword ptr [RBP + -0x18]
ADD RDI,0x18
CALL 0x001879c0
JMP 0x00187cfd
LAB_00187cfd:
ADD RSP,0x20
POP RBP
RET
|
void thr_unlock(long param_1,uint param_2)
{
int iVar1;
long lVar2;
long lVar3;
lVar2 = *(long *)(param_1 + 0x18);
iVar1 = *(int *)(param_1 + 0x40);
inline_mysql_mutex_lock
(lVar2 + 0x18,"/workspace/llm4binary/github2025/eloqsql/mysys/thr_lock.c",0x3c0);
lVar3 = *(long *)(param_1 + 8);
**(long **)(param_1 + 0x10) = lVar3;
if (lVar3 == 0) {
if (iVar1 < 6) {
*(int8 *)(lVar2 + 0x78) = *(int8 *)(param_1 + 0x10);
}
else if ((iVar1 == 9) && (*(long *)(param_1 + 0x20) != 0)) {
*(int8 *)(lVar2 + 0x88) = *(int8 *)(param_1 + 0x10);
}
else {
*(int8 *)(lVar2 + 0x98) = *(int8 *)(param_1 + 0x10);
}
}
else {
*(int8 *)(*(long *)(param_1 + 8) + 0x10) = *(int8 *)(param_1 + 0x10);
}
if ((param_2 & 1) != 0) {
if (iVar1 < 8) {
if (*(long *)(lVar2 + 200) != 0) {
(**(code **)(lVar2 + 200))(*(int8 *)(param_1 + 0x28));
}
}
else if (*(long *)(lVar2 + 0xc0) != 0) {
(**(code **)(lVar2 + 0xc0))(*(int8 *)(param_1 + 0x28));
}
}
if (iVar1 == 5) {
*(int *)(lVar2 + 0xa8) = *(int *)(lVar2 + 0xa8) + -1;
}
*(int4 *)(param_1 + 0x40) = 0;
wake_up_waiters(lVar2);
inline_mysql_mutex_unlock(lVar2 + 0x18);
return;
}
| |
21,464 | trnman_free_trn | eloqsql/storage/maria/trnman.c | static void trnman_free_trn(TRN *trn)
{
/*
union is to solve strict aliasing issue.
without it gcc 3.4.3 doesn't notice that updating *(void **)&tmp
modifies the value of tmp.
*/
union { TRN *trn; void *v; } tmp;
DBUG_ASSERT(trn != &dummy_transaction_object);
mysql_mutex_lock(&trn->state_lock);
trn->short_id= 0;
mysql_mutex_unlock(&trn->state_lock);
tmp.trn= pool;
do
{
/*
without this volatile cast gcc-3.4.4 moves the assignment
down after the loop at -O2
*/
*(TRN * volatile *)&(trn->next)= tmp.trn;
} while (!my_atomic_casptr((void **)(char*)&pool, &tmp.v, trn));
} | O3 | c | trnman_free_trn:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x10(%rdi), %r14
cmpq $0x0, 0x50(%rdi)
jne 0x46d8a
movq %r14, %rdi
callq 0x29220
movw $0x0, 0xac(%rbx)
movq 0x50(%rbx), %rdi
testq %rdi, %rdi
jne 0x46da0
movq %r14, %rdi
callq 0x291e0
movq 0x3b66d2(%rip), %rax # 0x3fd448
movq %rax, 0x68(%rbx)
lock
cmpxchgq %rbx, 0x3b66c5(%rip) # 0x3fd448
jne 0x46d76
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x92c13(%rip), %rsi # 0xd99a4
movq %r14, %rdi
movl $0x22d, %edx # imm = 0x22D
callq 0x2eb8f
jmp 0x46d55
leaq 0x33f269(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x46d67
| trnman_free_trn:
push rbp
mov rbp, rsp
push r14
push rbx
mov rbx, rdi
lea r14, [rdi+10h]
cmp qword ptr [rdi+50h], 0
jnz short loc_46D8A
mov rdi, r14
call _pthread_mutex_lock
loc_46D55:
mov word ptr [rbx+0ACh], 0
mov rdi, [rbx+50h]
test rdi, rdi
jnz short loc_46DA0
loc_46D67:
mov rdi, r14
call _pthread_mutex_unlock
mov rax, cs:pool
loc_46D76:
mov [rbx+68h], rax
lock cmpxchg cs:pool, rbx
jnz short loc_46D76
pop rbx
pop r14
pop rbp
retn
loc_46D8A:
lea rsi, aWorkspaceLlm4b_5; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, r14
mov edx, 22Dh
call psi_mutex_lock
jmp short loc_46D55
loc_46DA0:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp short loc_46D67
| signed long long trnman_free_trn(signed long long a1)
{
signed long long result; // rax
signed long long v2; // rtt
if ( *(_QWORD *)(a1 + 80) )
psi_mutex_lock(a1 + 16, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/trnman.c", 0x22Du);
else
pthread_mutex_lock(a1 + 16);
*(_WORD *)(a1 + 172) = 0;
if ( *(_QWORD *)(a1 + 80) )
PSI_server[44]();
pthread_mutex_unlock(a1 + 16);
result = pool;
do
{
*(_QWORD *)(a1 + 104) = result;
v2 = result;
result = _InterlockedCompareExchange64(&pool, a1, result);
}
while ( v2 != result );
return result;
}
| trnman_free_trn:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV RBX,RDI
LEA R14,[RDI + 0x10]
CMP qword ptr [RDI + 0x50],0x0
JNZ 0x00146d8a
MOV RDI,R14
CALL 0x00129220
LAB_00146d55:
MOV word ptr [RBX + 0xac],0x0
MOV RDI,qword ptr [RBX + 0x50]
TEST RDI,RDI
JNZ 0x00146da0
LAB_00146d67:
MOV RDI,R14
CALL 0x001291e0
MOV RAX,qword ptr [0x004fd448]
LAB_00146d76:
MOV qword ptr [RBX + 0x68],RAX
CMPXCHG.LOCK qword ptr [0x004fd448],RBX
JNZ 0x00146d76
POP RBX
POP R14
POP RBP
RET
LAB_00146d8a:
LEA RSI,[0x1d99a4]
MOV RDI,R14
MOV EDX,0x22d
CALL 0x0012eb8f
JMP 0x00146d55
LAB_00146da0:
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x00146d67
|
void trnman_free_trn(long param_1)
{
pthread_mutex_t *__mutex;
long lVar1;
long lVar2;
bool bVar3;
__mutex = (pthread_mutex_t *)(param_1 + 0x10);
if (*(long *)(param_1 + 0x50) == 0) {
pthread_mutex_lock(__mutex);
}
else {
psi_mutex_lock(__mutex,"/workspace/llm4binary/github2025/eloqsql/storage/maria/trnman.c",0x22d);
}
*(int2 *)(param_1 + 0xac) = 0;
if (*(long *)(param_1 + 0x50) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
lVar2 = pool;
do {
*(long *)(param_1 + 0x68) = lVar2;
LOCK();
bVar3 = lVar2 != pool;
lVar1 = param_1;
if (bVar3) {
lVar2 = pool;
lVar1 = pool;
}
pool = lVar1;
UNLOCK();
} while (bVar3);
return;
}
| |
21,465 | getopt_double | eloqsql/mysys/my_getopt.c | static double getopt_double(char *arg, const struct my_option *optp, int *err)
{
double num;
int error;
char *end= arg + 1000; /* Big enough as *arg is \0 terminated */
num= my_strtod(arg, &end, &error);
if (end[0] != 0 || error)
{
my_getopt_error_reporter(ERROR_LEVEL,
"Invalid decimal value for option '%s'\n", optp->name);
*err= EXIT_ARGUMENT_INVALID;
return 0.0;
}
return getopt_double_limit_value(num, optp, NULL);
} | O0 | c | getopt_double:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
addq $0x3e8, %rax # imm = 0x3E8
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rdi
leaq -0x38(%rbp), %rsi
leaq -0x2c(%rbp), %rdx
callq 0x153d60
movsd %xmm0, -0x28(%rbp)
movq -0x38(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
jne 0xf8e1a
cmpl $0x0, -0x2c(%rbp)
je 0xf8e4c
leaq 0x1d53ff(%rip), %rax # 0x2ce220
movq (%rax), %rcx
movq -0x18(%rbp), %rax
movq (%rax), %rdx
xorl %edi, %edi
leaq 0x67e0a(%rip), %rsi # 0x160c3e
movb $0x0, %al
callq *%rcx
movq -0x20(%rbp), %rax
movl $0xd, (%rax)
xorps %xmm0, %xmm0
movsd %xmm0, -0x8(%rbp)
jmp 0xf8e63
movsd -0x28(%rbp), %xmm0
movq -0x18(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xf7cf0
movsd %xmm0, -0x8(%rbp)
movsd -0x8(%rbp), %xmm0
addq $0x40, %rsp
popq %rbp
retq
nop
| getopt_double:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov rax, [rbp+var_10]
add rax, 3E8h
mov [rbp+var_38], rax
mov rdi, [rbp+var_10]
lea rsi, [rbp+var_38]
lea rdx, [rbp+var_2C]
call my_strtod
movsd [rbp+var_28], xmm0
mov rax, [rbp+var_38]
movsx eax, byte ptr [rax]
cmp eax, 0
jnz short loc_F8E1A
cmp [rbp+var_2C], 0
jz short loc_F8E4C
loc_F8E1A:
lea rax, my_getopt_error_reporter
mov rcx, [rax]
mov rax, [rbp+var_18]
mov rdx, [rax]
xor edi, edi
lea rsi, aInvalidDecimal; "Invalid decimal value for option '%s'\n"
mov al, 0
call rcx
mov rax, [rbp+var_20]
mov dword ptr [rax], 0Dh
xorps xmm0, xmm0
movsd [rbp+var_8], xmm0
jmp short loc_F8E63
loc_F8E4C:
movsd xmm0, [rbp+var_28]
mov rdi, [rbp+var_18]
xor eax, eax
mov esi, eax
call getopt_double_limit_value
movsd [rbp+var_8], xmm0
loc_F8E63:
movsd xmm0, [rbp+var_8]
add rsp, 40h
pop rbp
retn
| double getopt_double(long long a1, const char **a2, _DWORD *a3)
{
_BYTE *v4; // [rsp+8h] [rbp-38h] BYREF
int v5; // [rsp+14h] [rbp-2Ch] BYREF
double v6; // [rsp+18h] [rbp-28h]
_DWORD *v7; // [rsp+20h] [rbp-20h]
const char **v8; // [rsp+28h] [rbp-18h]
long long v9; // [rsp+30h] [rbp-10h]
v9 = a1;
v8 = a2;
v7 = a3;
v4 = (_BYTE *)(a1 + 1000);
v6 = my_strtod(a1, &v4, &v5);
if ( !*v4 && !v5 )
return getopt_double_limit_value(v8, 0LL, v6);
my_getopt_error_reporter(0, (long long)"Invalid decimal value for option '%s'\n", *v8);
*v7 = 13;
return 0.0;
}
| getopt_double:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x3e8
MOV qword ptr [RBP + -0x38],RAX
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[RBP + -0x38]
LEA RDX,[RBP + -0x2c]
CALL 0x00253d60
MOVSD qword ptr [RBP + -0x28],XMM0
MOV RAX,qword ptr [RBP + -0x38]
MOVSX EAX,byte ptr [RAX]
CMP EAX,0x0
JNZ 0x001f8e1a
CMP dword ptr [RBP + -0x2c],0x0
JZ 0x001f8e4c
LAB_001f8e1a:
LEA RAX,[0x3ce220]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RAX]
XOR EDI,EDI
LEA RSI,[0x260c3e]
MOV AL,0x0
CALL RCX
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX],0xd
XORPS XMM0,XMM0
MOVSD qword ptr [RBP + -0x8],XMM0
JMP 0x001f8e63
LAB_001f8e4c:
MOVSD XMM0,qword ptr [RBP + -0x28]
MOV RDI,qword ptr [RBP + -0x18]
XOR EAX,EAX
MOV ESI,EAX
CALL 0x001f7cf0
MOVSD qword ptr [RBP + -0x8],XMM0
LAB_001f8e63:
MOVSD XMM0,qword ptr [RBP + -0x8]
ADD RSP,0x40
POP RBP
RET
|
int8 getopt_double(long param_1,int8 *param_2,int4 *param_3)
{
char *local_40;
int local_34;
int8 local_30;
int4 *local_28;
int8 *local_20;
long local_18;
int8 local_10;
local_40 = (char *)(param_1 + 1000);
local_28 = param_3;
local_20 = param_2;
local_18 = param_1;
local_30 = my_strtod(param_1,&local_40,&local_34);
if ((*local_40 == '\0') && (local_34 == 0)) {
local_10 = getopt_double_limit_value(local_30,local_20,0);
}
else {
(*(code *)my_getopt_error_reporter)(0,"Invalid decimal value for option \'%s\'\n",*local_20);
*local_28 = 0xd;
local_10 = 0;
}
return local_10;
}
| |
21,466 | my_like_range_win1250ch | eloqsql/strings/ctype-win1250ch.c | static my_bool
my_like_range_win1250ch(CHARSET_INFO *cs __attribute__((unused)),
const char *ptr, size_t ptr_length,
pbool escape, pbool w_one, pbool w_many,
size_t res_length,
char *min_str, char *max_str,
size_t *min_length, size_t *max_length)
{
int only_min_found= 1;
const char *end = ptr + ptr_length;
char *min_org = min_str;
char *min_end = min_str + res_length;
/* return 1; */
for (; ptr != end && min_str != min_end ; ptr++)
{
if (*ptr == escape && ptr+1 != end)
ptr++; /* Skip escape */
else if (*ptr == w_one || *ptr == w_many) /* '_' or '%' in SQL */
break;
*min_str= like_range_prefix_min_win1250ch[(uint) (uchar) (*ptr)];
if (*min_str != min_sort_char)
only_min_found= 0;
min_str++;
*max_str++= like_range_prefix_max_win1250ch[(uint) (uchar) (*ptr)];
}
if (cs->state & MY_CS_BINSORT)
*min_length= (size_t) (min_str - min_org);
else
{
/* 'a\0\0... is the smallest possible string */
*min_length= res_length;
}
/* a\ff\ff... is the biggest possible string */
*max_length= res_length;
while (min_str != min_end)
{
*min_str++ = min_sort_char;
*max_str++ = max_sort_char;
}
return (only_min_found);
} | O3 | c | my_like_range_win1250ch:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl %r9d, -0x2c(%rbp)
movl %r8d, -0x30(%rbp)
movq %rdi, -0x38(%rbp)
movq 0x20(%rbp), %r10
movq 0x18(%rbp), %r13
movq 0x10(%rbp), %r8
leaq (%r8,%r13), %r11
testq %rdx, %rdx
sete %al
testq %r8, %r8
sete %dil
orb %al, %dil
movb $0x1, %al
jne 0x5b5be
addq %rsi, %rdx
leaq -0x1(%r8), %rbx
movb $0x1, %al
leaq 0x287529(%rip), %r12 # 0x2e2a70
leaq 0x287622(%rip), %rdi # 0x2e2b70
movb (%rsi), %r14b
cmpb %cl, %r14b
setne %r9b
leaq 0x1(%rsi), %r15
cmpq %rdx, %r15
sete %r8b
orb %r9b, %r8b
cmpb $0x1, %r8b
jne 0x5b57b
cmpb -0x30(%rbp), %r14b
je 0x5b5be
movq %rsi, %r15
cmpb -0x2c(%rbp), %r14b
je 0x5b5be
movzbl (%r15), %esi
cmpq $0x20, %rsi
movb (%rsi,%r12), %sil
movb %sil, (%r13)
movzbl %al, %eax
movl $0x0, %esi
cmovnel %esi, %eax
incq %r13
movzbl (%r15), %esi
movb (%rsi,%rdi), %sil
movb %sil, (%r10)
incq %r10
movq %r15, %rsi
incq %rsi
cmpq %rdx, %rsi
je 0x5b5be
leaq -0x1(%rbx), %r8
testq %rbx, %rbx
movq %r8, %rbx
jne 0x5b54e
movq %r13, %rcx
subq 0x18(%rbp), %rcx
movq -0x38(%rbp), %rdx
testb $0x10, 0xc(%rdx)
movq 0x10(%rbp), %rsi
cmoveq %rsi, %rcx
movq 0x28(%rbp), %rdx
movq %rcx, (%rdx)
movq 0x30(%rbp), %rcx
movq %rsi, (%rcx)
cmpq %r11, %r13
je 0x5b5f9
movb $0x20, (%r13)
incq %r13
movb $-0x1, (%r10)
incq %r10
jmp 0x5b5e3
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| my_like_range_win1250ch:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
mov [rbp+var_2C], r9d
mov [rbp+var_30], r8d
mov [rbp+var_38], rdi
mov r10, [rbp+arg_10]
mov r13, [rbp+arg_8]
mov r8, [rbp+arg_0]
lea r11, [r8+r13]
test rdx, rdx
setz al
test r8, r8
setz dil
or dil, al
mov al, 1
jnz loc_5B5BE
add rdx, rsi
lea rbx, [r8-1]
mov al, 1
lea r12, like_range_prefix_min_win1250ch
lea rdi, like_range_prefix_max_win1250ch
loc_5B54E:
mov r14b, [rsi]
cmp r14b, cl
setnz r9b
lea r15, [rsi+1]
cmp r15, rdx
setz r8b
or r8b, r9b
cmp r8b, 1
jnz short loc_5B57B
cmp r14b, byte ptr [rbp+var_30]
jz short loc_5B5BE
mov r15, rsi
cmp r14b, byte ptr [rbp+var_2C]
jz short loc_5B5BE
loc_5B57B:
movzx esi, byte ptr [r15]
cmp rsi, 20h ; ' '
mov sil, [rsi+r12]
mov [r13+0], sil
movzx eax, al
mov esi, 0
cmovnz eax, esi
inc r13
movzx esi, byte ptr [r15]
mov sil, [rsi+rdi]
mov [r10], sil
inc r10
mov rsi, r15
inc rsi
cmp rsi, rdx
jz short loc_5B5BE
lea r8, [rbx-1]
test rbx, rbx
mov rbx, r8
jnz short loc_5B54E
loc_5B5BE:
mov rcx, r13
sub rcx, [rbp+arg_8]
mov rdx, [rbp+var_38]
test byte ptr [rdx+0Ch], 10h
mov rsi, [rbp+arg_0]
cmovz rcx, rsi
mov rdx, [rbp+arg_18]
mov [rdx], rcx
mov rcx, [rbp+arg_20]
mov [rcx], rsi
loc_5B5E3:
cmp r13, r11
jz short loc_5B5F9
mov byte ptr [r13+0], 20h ; ' '
inc r13
mov byte ptr [r10], 0FFh
inc r10
jmp short loc_5B5E3
loc_5B5F9:
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| char my_like_range_win1250ch(
long long a1,
unsigned __int8 *a2,
long long a3,
unsigned __int8 a4,
char a5,
char a6,
long long a7,
long long a8,
_BYTE *a9,
long long *a10,
_QWORD *a11)
{
_BYTE *v12; // r13
char result; // al
unsigned __int8 *v14; // rdx
long long v15; // rbx
unsigned __int8 v16; // r14
unsigned __int8 *v17; // r15
long long v18; // rsi
long long v20; // rcx
v12 = (_BYTE *)a8;
result = 1;
if ( a3 != 0 && a7 != 0 )
{
v14 = &a2[a3];
v15 = a7 - 1;
result = 1;
do
{
v16 = *a2;
v17 = a2 + 1;
if ( *a2 != a4 || a2 + 1 == v14 )
{
if ( v16 == a5 )
break;
v17 = a2;
if ( v16 == a6 )
break;
}
v18 = *v17;
*v12 = like_range_prefix_min_win1250ch[v18];
if ( v18 != 32 )
result = 0;
++v12;
*a9++ = like_range_prefix_max_win1250ch[*v17];
a2 = v17 + 1;
if ( v17 + 1 == v14 )
break;
}
while ( v15-- != 0 );
}
v20 = (long long)&v12[-a8];
if ( (*(_BYTE *)(a1 + 12) & 0x10) == 0 )
v20 = a7;
*a10 = v20;
*a11 = a7;
while ( v12 != (_BYTE *)(a7 + a8) )
{
*v12++ = 32;
*a9++ = -1;
}
return result;
}
| my_like_range_win1250ch:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV dword ptr [RBP + -0x2c],R9D
MOV dword ptr [RBP + -0x30],R8D
MOV qword ptr [RBP + -0x38],RDI
MOV R10,qword ptr [RBP + 0x20]
MOV R13,qword ptr [RBP + 0x18]
MOV R8,qword ptr [RBP + 0x10]
LEA R11,[R8 + R13*0x1]
TEST RDX,RDX
SETZ AL
TEST R8,R8
SETZ DIL
OR DIL,AL
MOV AL,0x1
JNZ 0x0015b5be
ADD RDX,RSI
LEA RBX,[R8 + -0x1]
MOV AL,0x1
LEA R12,[0x3e2a70]
LEA RDI,[0x3e2b70]
LAB_0015b54e:
MOV R14B,byte ptr [RSI]
CMP R14B,CL
SETNZ R9B
LEA R15,[RSI + 0x1]
CMP R15,RDX
SETZ R8B
OR R8B,R9B
CMP R8B,0x1
JNZ 0x0015b57b
CMP R14B,byte ptr [RBP + -0x30]
JZ 0x0015b5be
MOV R15,RSI
CMP R14B,byte ptr [RBP + -0x2c]
JZ 0x0015b5be
LAB_0015b57b:
MOVZX ESI,byte ptr [R15]
CMP RSI,0x20
MOV SIL,byte ptr [RSI + R12*0x1]
MOV byte ptr [R13],SIL
MOVZX EAX,AL
MOV ESI,0x0
CMOVNZ EAX,ESI
INC R13
MOVZX ESI,byte ptr [R15]
MOV SIL,byte ptr [RSI + RDI*0x1]
MOV byte ptr [R10],SIL
INC R10
MOV RSI,R15
INC RSI
CMP RSI,RDX
JZ 0x0015b5be
LEA R8,[RBX + -0x1]
TEST RBX,RBX
MOV RBX,R8
JNZ 0x0015b54e
LAB_0015b5be:
MOV RCX,R13
SUB RCX,qword ptr [RBP + 0x18]
MOV RDX,qword ptr [RBP + -0x38]
TEST byte ptr [RDX + 0xc],0x10
MOV RSI,qword ptr [RBP + 0x10]
CMOVZ RCX,RSI
MOV RDX,qword ptr [RBP + 0x28]
MOV qword ptr [RDX],RCX
MOV RCX,qword ptr [RBP + 0x30]
MOV qword ptr [RCX],RSI
LAB_0015b5e3:
CMP R13,R11
JZ 0x0015b5f9
MOV byte ptr [R13],0x20
INC R13
MOV byte ptr [R10],0xff
INC R10
JMP 0x0015b5e3
LAB_0015b5f9:
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8
my_like_range_win1250ch
(long param_1,byte *param_2,long param_3,byte param_4,byte param_5,byte param_6,
long param_7,int1 *param_8,int1 *param_9,long *param_10,long *param_11)
{
byte bVar1;
int8 uVar2;
byte *pbVar3;
long lVar4;
int1 *puVar5;
byte *pbVar6;
uVar2 = 1;
puVar5 = param_8;
if (param_7 != 0 && param_3 != 0) {
pbVar3 = param_2 + param_3;
uVar2 = 1;
lVar4 = param_7;
while( true ) {
lVar4 = lVar4 + -1;
bVar1 = *param_2;
pbVar6 = param_2 + 1;
if ((param_2 + 1 == pbVar3 || bVar1 != param_4) &&
((bVar1 == param_5 || (pbVar6 = param_2, bVar1 == param_6)))) break;
bVar1 = *pbVar6;
*puVar5 = like_range_prefix_min_win1250ch[bVar1];
if ((ulong)bVar1 != 0x20) {
uVar2 = 0;
}
puVar5 = puVar5 + 1;
*param_9 = like_range_prefix_max_win1250ch[*pbVar6];
param_9 = param_9 + 1;
param_2 = pbVar6 + 1;
if ((param_2 == pbVar3) || (lVar4 == 0)) break;
}
}
lVar4 = (long)puVar5 - (long)param_8;
if ((*(byte *)(param_1 + 0xc) & 0x10) == 0) {
lVar4 = param_7;
}
*param_10 = lVar4;
*param_11 = param_7;
for (; puVar5 != param_8 + param_7; puVar5 = puVar5 + 1) {
*puVar5 = 0x20;
*param_9 = 0xff;
param_9 = param_9 + 1;
}
return uVar2;
}
| |
21,467 | 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
} | O0 | c | my_interval_timer:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl $0x1, %edi
leaq -0x10(%rbp), %rsi
callq 0x2a2d0
imulq $0x3b9aca00, -0x10(%rbp), %rax # imm = 0x3B9ACA00
addq -0x8(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| my_interval_timer:
push rbp
mov rbp, rsp
sub rsp, 10h
mov edi, 1
lea rsi, [rbp+var_10]
call _clock_gettime
imul rax, [rbp+var_10], 3B9ACA00h
add rax, [rbp+var_8]
add rsp, 10h
pop rbp
retn
| long long my_interval_timer()
{
_QWORD v1[2]; // [rsp+0h] [rbp-10h] BYREF
clock_gettime(1LL, v1);
return v1[1] + 1000000000LL * v1[0];
}
| my_interval_timer:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV EDI,0x1
LEA RSI,[RBP + -0x10]
CALL 0x0012a2d0
IMUL RAX,qword ptr [RBP + -0x10],0x3b9aca00
ADD RAX,qword ptr [RBP + -0x8]
ADD RSP,0x10
POP RBP
RET
|
long my_interval_timer(void)
{
timespec local_18;
clock_gettime(1,&local_18);
return local_18.tv_sec * 1000000000 + local_18.tv_nsec;
}
| |
21,468 | my_mb_wc_eucjpms | eloqsql/strings/ctype-eucjpms.c | static int
my_mb_wc_eucjpms(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_eucjpms_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_eucjpms_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;
} | O0 | c | my_mb_wc_eucjpms:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x20(%rbp), %rax
cmpq -0x28(%rbp), %rax
jb 0x3d77a
movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B
jmp 0x3d996
movq -0x20(%rbp), %rax
movzbl (%rax), %eax
movl %eax, -0x2c(%rbp)
cmpl $0x80, %eax
jge 0x3d7a2
movslq -0x2c(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movl $0x1, -0x4(%rbp)
jmp 0x3d996
cmpl $0xa1, -0x2c(%rbp)
jl 0x3d851
cmpl $0xfe, -0x2c(%rbp)
jg 0x3d851
movq -0x20(%rbp), %rax
addq $0x2, %rax
cmpq -0x28(%rbp), %rax
jbe 0x3d7d6
movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A
jmp 0x3d996
movl -0x2c(%rbp), %eax
shll $0x8, %eax
movq -0x20(%rbp), %rcx
movzbl 0x1(%rcx), %ecx
addl %ecx, %eax
movslq %eax, %rcx
leaq 0x1ac7e0(%rip), %rax # 0x1e9fd0
movzwl (%rax,%rcx,2), %eax
movq -0x18(%rbp), %rcx
movq %rax, (%rcx)
cmpq $0x0, %rax
je 0x3d80b
movl $0x2, %eax
movl %eax, -0x30(%rbp)
jmp 0x3d846
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %ecx
movb $0x1, %al
cmpl $0xa1, %ecx
movb %al, -0x31(%rbp)
jl 0x3d833
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
cmpl $0xfe, %eax
setg %al
movb %al, -0x31(%rbp)
movb -0x31(%rbp), %dl
movl $0xfffffffe, %eax # imm = 0xFFFFFFFE
xorl %ecx, %ecx
testb $0x1, %dl
cmovnel %ecx, %eax
movl %eax, -0x30(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x3d996
cmpl $0x8e, -0x2c(%rbp)
jne 0x3d8c1
movq -0x20(%rbp), %rax
addq $0x2, %rax
cmpq -0x28(%rbp), %rax
jbe 0x3d874
movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A
jmp 0x3d996
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
cmpl $0xa1, %eax
jl 0x3d892
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
cmpl $0xdf, %eax
jle 0x3d89e
movl $0x0, -0x4(%rbp)
jmp 0x3d996
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
addl $0xfec0, %eax # imm = 0xFEC0
movslq %eax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movl $0x2, -0x4(%rbp)
jmp 0x3d996
cmpl $0x8f, -0x2c(%rbp)
jne 0x3d98f
movq -0x20(%rbp), %rax
addq $0x3, %rax
cmpq -0x28(%rbp), %rax
jbe 0x3d8e8
movl $0xffffff99, -0x4(%rbp) # imm = 0xFFFFFF99
jmp 0x3d996
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %eax
shll $0x8, %eax
movq -0x20(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
addl %ecx, %eax
movslq %eax, %rcx
leaq 0x1cc6c9(%rip), %rax # 0x209fd0
movzwl (%rax,%rcx,2), %eax
movq -0x18(%rbp), %rcx
movq %rax, (%rcx)
cmpq $0x0, %rax
je 0x3d922
movl $0x3, %eax
movl %eax, -0x38(%rbp)
jmp 0x3d987
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %ecx
movb $0x1, %al
cmpl $0xa1, %ecx
movb %al, -0x39(%rbp)
jl 0x3d974
movq -0x20(%rbp), %rax
movzbl 0x1(%rax), %ecx
movb $0x1, %al
cmpl $0xfe, %ecx
movb %al, -0x39(%rbp)
jg 0x3d974
movq -0x20(%rbp), %rax
movzbl 0x2(%rax), %ecx
movb $0x1, %al
cmpl $0xa1, %ecx
movb %al, -0x39(%rbp)
jl 0x3d974
movq -0x20(%rbp), %rax
movzbl 0x2(%rax), %eax
cmpl $0xfe, %eax
setg %al
movb %al, -0x39(%rbp)
movb -0x39(%rbp), %dl
movl $0xfffffffd, %eax # imm = 0xFFFFFFFD
xorl %ecx, %ecx
testb $0x1, %dl
cmovnel %ecx, %eax
movl %eax, -0x38(%rbp)
movl -0x38(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x3d996
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax,%rax)
| my_mb_wc_eucjpms:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_20]
cmp rax, [rbp+var_28]
jb short loc_3D77A
mov [rbp+var_4], 0FFFFFF9Bh
jmp loc_3D996
loc_3D77A:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax]
mov [rbp+var_2C], eax
cmp eax, 80h
jge short loc_3D7A2
movsxd rcx, [rbp+var_2C]
mov rax, [rbp+var_18]
mov [rax], rcx
mov [rbp+var_4], 1
jmp loc_3D996
loc_3D7A2:
cmp [rbp+var_2C], 0A1h
jl loc_3D851
cmp [rbp+var_2C], 0FEh
jg loc_3D851
mov rax, [rbp+var_20]
add rax, 2
cmp rax, [rbp+var_28]
jbe short loc_3D7D6
mov [rbp+var_4], 0FFFFFF9Ah
jmp loc_3D996
loc_3D7D6:
mov eax, [rbp+var_2C]
shl eax, 8
mov rcx, [rbp+var_20]
movzx ecx, byte ptr [rcx+1]
add eax, ecx
movsxd rcx, eax
lea rax, jisx0208_eucjpms_to_unicode
movzx eax, word ptr [rax+rcx*2]
mov rcx, [rbp+var_18]
mov [rcx], rax
cmp rax, 0
jz short loc_3D80B
mov eax, 2
mov [rbp+var_30], eax
jmp short loc_3D846
loc_3D80B:
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+1]
mov al, 1
cmp ecx, 0A1h
mov [rbp+var_31], al
jl short loc_3D833
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
cmp eax, 0FEh
setnle al
mov [rbp+var_31], al
loc_3D833:
mov dl, [rbp+var_31]
mov eax, 0FFFFFFFEh
xor ecx, ecx
test dl, 1
cmovnz eax, ecx
mov [rbp+var_30], eax
loc_3D846:
mov eax, [rbp+var_30]
mov [rbp+var_4], eax
jmp loc_3D996
loc_3D851:
cmp [rbp+var_2C], 8Eh
jnz short loc_3D8C1
mov rax, [rbp+var_20]
add rax, 2
cmp rax, [rbp+var_28]
jbe short loc_3D874
mov [rbp+var_4], 0FFFFFF9Ah
jmp loc_3D996
loc_3D874:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
cmp eax, 0A1h
jl short loc_3D892
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
cmp eax, 0DFh
jle short loc_3D89E
loc_3D892:
mov [rbp+var_4], 0
jmp loc_3D996
loc_3D89E:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
add eax, 0FEC0h
movsxd rcx, eax
mov rax, [rbp+var_18]
mov [rax], rcx
mov [rbp+var_4], 2
jmp loc_3D996
loc_3D8C1:
cmp [rbp+var_2C], 8Fh
jnz loc_3D98F
mov rax, [rbp+var_20]
add rax, 3
cmp rax, [rbp+var_28]
jbe short loc_3D8E8
mov [rbp+var_4], 0FFFFFF99h
jmp loc_3D996
loc_3D8E8:
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+1]
shl eax, 8
mov rcx, [rbp+var_20]
movzx ecx, byte ptr [rcx+2]
add eax, ecx
movsxd rcx, eax
lea rax, jisx0212_eucjpms_to_unicode
movzx eax, word ptr [rax+rcx*2]
mov rcx, [rbp+var_18]
mov [rcx], rax
cmp rax, 0
jz short loc_3D922
mov eax, 3
mov [rbp+var_38], eax
jmp short loc_3D987
loc_3D922:
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+1]
mov al, 1
cmp ecx, 0A1h
mov [rbp+var_39], al
jl short loc_3D974
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+1]
mov al, 1
cmp ecx, 0FEh
mov [rbp+var_39], al
jg short loc_3D974
mov rax, [rbp+var_20]
movzx ecx, byte ptr [rax+2]
mov al, 1
cmp ecx, 0A1h
mov [rbp+var_39], al
jl short loc_3D974
mov rax, [rbp+var_20]
movzx eax, byte ptr [rax+2]
cmp eax, 0FEh
setnle al
mov [rbp+var_39], al
loc_3D974:
mov dl, [rbp+var_39]
mov eax, 0FFFFFFFDh
xor ecx, ecx
test dl, 1
cmovnz eax, ecx
mov [rbp+var_38], eax
loc_3D987:
mov eax, [rbp+var_38]
mov [rbp+var_4], eax
jmp short loc_3D996
loc_3D98F:
mov [rbp+var_4], 0
loc_3D996:
mov eax, [rbp+var_4]
pop rbp
retn
| long long my_mb_wc_eucjpms(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4)
{
long long v4; // rax
unsigned int v5; // eax
long long v6; // rax
unsigned int v7; // eax
bool v9; // [rsp+1h] [rbp-39h]
bool v11; // [rsp+9h] [rbp-31h]
unsigned int v13; // [rsp+Eh] [rbp-2Ch]
if ( (unsigned long long)a3 < a4 )
{
v13 = *a3;
if ( v13 >= 0x80 )
{
if ( *a3 < 0xA1u || *a3 == 255 )
{
if ( v13 == 142 )
{
if ( (unsigned long long)(a3 + 2) <= a4 )
{
if ( a3[1] >= 0xA1u && a3[1] <= 0xDFu )
{
*a2 = a3[1] + 65216;
return 2;
}
else
{
return 0;
}
}
else
{
return (unsigned int)-102;
}
}
else if ( v13 == 143 )
{
if ( (unsigned long long)(a3 + 3) <= a4 )
{
v6 = jisx0212_eucjpms_to_unicode[256 * a3[1] + a3[2]];
*a2 = v6;
if ( v6 )
{
return 3;
}
else
{
v9 = 1;
if ( a3[1] >= 0xA1u )
{
v9 = 1;
if ( a3[1] != 255 )
{
v9 = 1;
if ( a3[2] >= 0xA1u )
v9 = a3[2] == 255;
}
}
v7 = -3;
if ( v9 )
v7 = 0;
return v7;
}
}
else
{
return (unsigned int)-103;
}
}
else
{
return 0;
}
}
else if ( (unsigned long long)(a3 + 2) <= a4 )
{
v4 = jisx0208_eucjpms_to_unicode[a3[1] + (v13 << 8)];
*a2 = v4;
if ( v4 )
{
return 2;
}
else
{
v11 = 1;
if ( a3[1] >= 0xA1u )
v11 = a3[1] == 255;
v5 = -2;
if ( v11 )
v5 = 0;
return v5;
}
}
else
{
return (unsigned int)-102;
}
}
else
{
*a2 = *a3;
return 1;
}
}
else
{
return (unsigned int)-101;
}
}
| my_mb_wc_eucjpms:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RBP + -0x28]
JC 0x0013d77a
MOV dword ptr [RBP + -0x4],0xffffff9b
JMP 0x0013d996
LAB_0013d77a:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX]
MOV dword ptr [RBP + -0x2c],EAX
CMP EAX,0x80
JGE 0x0013d7a2
MOVSXD RCX,dword ptr [RBP + -0x2c]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x1
JMP 0x0013d996
LAB_0013d7a2:
CMP dword ptr [RBP + -0x2c],0xa1
JL 0x0013d851
CMP dword ptr [RBP + -0x2c],0xfe
JG 0x0013d851
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x0013d7d6
MOV dword ptr [RBP + -0x4],0xffffff9a
JMP 0x0013d996
LAB_0013d7d6:
MOV EAX,dword ptr [RBP + -0x2c]
SHL EAX,0x8
MOV RCX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RCX + 0x1]
ADD EAX,ECX
MOVSXD RCX,EAX
LEA RAX,[0x2e9fd0]
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV RCX,qword ptr [RBP + -0x18]
MOV qword ptr [RCX],RAX
CMP RAX,0x0
JZ 0x0013d80b
MOV EAX,0x2
MOV dword ptr [RBP + -0x30],EAX
JMP 0x0013d846
LAB_0013d80b:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0x1]
MOV AL,0x1
CMP ECX,0xa1
MOV byte ptr [RBP + -0x31],AL
JL 0x0013d833
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
CMP EAX,0xfe
SETG AL
MOV byte ptr [RBP + -0x31],AL
LAB_0013d833:
MOV DL,byte ptr [RBP + -0x31]
MOV EAX,0xfffffffe
XOR ECX,ECX
TEST DL,0x1
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x30],EAX
LAB_0013d846:
MOV EAX,dword ptr [RBP + -0x30]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0013d996
LAB_0013d851:
CMP dword ptr [RBP + -0x2c],0x8e
JNZ 0x0013d8c1
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x0013d874
MOV dword ptr [RBP + -0x4],0xffffff9a
JMP 0x0013d996
LAB_0013d874:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
CMP EAX,0xa1
JL 0x0013d892
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
CMP EAX,0xdf
JLE 0x0013d89e
LAB_0013d892:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0013d996
LAB_0013d89e:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
ADD EAX,0xfec0
MOVSXD RCX,EAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV dword ptr [RBP + -0x4],0x2
JMP 0x0013d996
LAB_0013d8c1:
CMP dword ptr [RBP + -0x2c],0x8f
JNZ 0x0013d98f
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x3
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x0013d8e8
MOV dword ptr [RBP + -0x4],0xffffff99
JMP 0x0013d996
LAB_0013d8e8:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x1]
SHL EAX,0x8
MOV RCX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RCX + 0x2]
ADD EAX,ECX
MOVSXD RCX,EAX
LEA RAX,[0x309fd0]
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV RCX,qword ptr [RBP + -0x18]
MOV qword ptr [RCX],RAX
CMP RAX,0x0
JZ 0x0013d922
MOV EAX,0x3
MOV dword ptr [RBP + -0x38],EAX
JMP 0x0013d987
LAB_0013d922:
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0x1]
MOV AL,0x1
CMP ECX,0xa1
MOV byte ptr [RBP + -0x39],AL
JL 0x0013d974
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0x1]
MOV AL,0x1
CMP ECX,0xfe
MOV byte ptr [RBP + -0x39],AL
JG 0x0013d974
MOV RAX,qword ptr [RBP + -0x20]
MOVZX ECX,byte ptr [RAX + 0x2]
MOV AL,0x1
CMP ECX,0xa1
MOV byte ptr [RBP + -0x39],AL
JL 0x0013d974
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,byte ptr [RAX + 0x2]
CMP EAX,0xfe
SETG AL
MOV byte ptr [RBP + -0x39],AL
LAB_0013d974:
MOV DL,byte ptr [RBP + -0x39]
MOV EAX,0xfffffffd
XOR ECX,ECX
TEST DL,0x1
CMOVNZ EAX,ECX
MOV dword ptr [RBP + -0x38],EAX
LAB_0013d987:
MOV EAX,dword ptr [RBP + -0x38]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0013d996
LAB_0013d98f:
MOV dword ptr [RBP + -0x4],0x0
LAB_0013d996:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int4 my_mb_wc_eucjpms(int8 param_1,ulong *param_2,byte *param_3,byte *param_4)
{
ushort uVar1;
bool bVar2;
uint uVar3;
int4 local_40;
int4 local_38;
int4 local_c;
if (param_3 < param_4) {
uVar3 = (uint)*param_3;
if (uVar3 < 0x80) {
*param_2 = (long)(int)uVar3;
local_c = 1;
}
else if ((uVar3 < 0xa1) || (0xfe < uVar3)) {
if (uVar3 == 0x8e) {
if (param_4 < param_3 + 2) {
local_c = 0xffffff9a;
}
else if ((param_3[1] < 0xa1) || (0xdf < param_3[1])) {
local_c = 0;
}
else {
*param_2 = (long)(int)(param_3[1] + 0xfec0);
local_c = 2;
}
}
else if (uVar3 == 0x8f) {
if (param_4 < param_3 + 3) {
local_c = 0xffffff99;
}
else {
uVar1 = *(ushort *)
(&jisx0212_eucjpms_to_unicode +
(long)(int)((uint)param_3[1] * 0x100 + (uint)param_3[2]) * 2);
*param_2 = (ulong)uVar1;
if ((ulong)uVar1 == 0) {
bVar2 = true;
if (((0xa0 < param_3[1]) && (bVar2 = true, param_3[1] != 0xff)) &&
(bVar2 = true, 0xa0 < param_3[2])) {
bVar2 = 0xfe < param_3[2];
}
local_40 = 0xfffffffd;
if (bVar2) {
local_40 = 0;
}
}
else {
local_40 = 3;
}
local_c = local_40;
}
}
else {
local_c = 0;
}
}
else if (param_4 < param_3 + 2) {
local_c = 0xffffff9a;
}
else {
uVar1 = *(ushort *)
(jisx0208_eucjpms_to_unicode + (long)(int)(uVar3 * 0x100 + (uint)param_3[1]) * 2);
*param_2 = (ulong)uVar1;
if ((ulong)uVar1 == 0) {
bVar2 = true;
if (0xa0 < param_3[1]) {
bVar2 = 0xfe < param_3[1];
}
local_38 = 0xfffffffe;
if (bVar2) {
local_38 = 0;
}
}
else {
local_38 = 2;
}
local_c = local_38;
}
}
else {
local_c = 0xffffff9b;
}
return local_c;
}
| |
21,469 | evmone::Memory::grow(unsigned long) | corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/lib/evmone/execution_state.hpp | void grow(size_t new_size) noexcept
{
// Restriction for future changes. EVM always has memory size as multiple of 32 bytes.
INTX_REQUIRE(new_size % 32 == 0);
// Allow only growing memory. Include hint for optimizing compiler.
INTX_REQUIRE(new_size > m_size);
if (new_size > m_capacity)
{
m_capacity *= 2; // Double the capacity.
if (m_capacity < new_size) // If not enough.
{
// Set capacity to required size rounded to multiple of page_size.
m_capacity = ((new_size + (page_size - 1)) / page_size) * page_size;
}
allocate_capacity();
}
std::memset(&m_data[m_size], 0, new_size - m_size);
m_size = new_size;
} | O0 | cpp | evmone::Memory::grow(unsigned long):
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
andq $0x1f, %rax
cmpq $0x0, %rax
jne 0x687f8
jmp 0x68817
leaq 0x7713d(%rip), %rdi # 0xdf93c
leaq 0x77149(%rip), %rsi # 0xdf94f
movl $0x7c, %edx
leaq 0x771c7(%rip), %rcx # 0xdf9d9
callq 0x23120
movq -0x18(%rbp), %rcx
movq -0x10(%rbp), %rax
cmpq 0x8(%rcx), %rax
jbe 0x68827
jmp 0x68846
leaq 0x771cd(%rip), %rdi # 0xdf9fb
leaq 0x7711a(%rip), %rsi # 0xdf94f
movl $0x7f, %edx
leaq 0x77198(%rip), %rcx # 0xdf9d9
callq 0x23120
movq -0x18(%rbp), %rcx
movq -0x10(%rbp), %rax
cmpq 0x10(%rcx), %rax
jbe 0x68891
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rcx
shlq %rcx
movq %rcx, 0x10(%rax)
movq 0x10(%rax), %rax
cmpq -0x10(%rbp), %rax
jae 0x68888
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
addq $0xfff, %rcx # imm = 0xFFF
shrq $0xc, %rcx
shlq $0xc, %rcx
movq %rcx, 0x10(%rax)
movq -0x18(%rbp), %rdi
callq 0x3d300
movq -0x18(%rbp), %rdi
movq 0x8(%rdi), %rsi
callq 0x688e0
movq %rax, -0x20(%rbp)
jmp 0x688a4
movq -0x18(%rbp), %rax
movq -0x20(%rbp), %rdi
movq -0x10(%rbp), %rdx
subq 0x8(%rax), %rdx
xorl %esi, %esi
callq 0x231c0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
movq %rcx, 0x8(%rax)
addq $0x20, %rsp
popq %rbp
retq
movq %rax, %rdi
callq 0x37a70
nopw %cs:(%rax,%rax)
nop
| _ZN6evmone6Memory4growEm:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_8]
mov [rbp+var_18], rax
mov rax, [rbp+var_10]
and rax, 1Fh
cmp rax, 0
jnz short loc_687F8
jmp short loc_68817
loc_687F8:
lea rdi, aNewSize320; "new_size % 32 == 0"
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
mov edx, 7Ch ; '|'
lea rcx, aVoidEvmoneMemo; "void evmone::Memory::grow(size_t)"
call ___assert_fail
loc_68817:
mov rcx, [rbp+var_18]
mov rax, [rbp+var_10]
cmp rax, [rcx+8]
jbe short loc_68827
jmp short loc_68846
loc_68827:
lea rdi, aNewSizeMSize; "new_size > m_size"
lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"...
mov edx, 7Fh
lea rcx, aVoidEvmoneMemo; "void evmone::Memory::grow(size_t)"
call ___assert_fail
loc_68846:
mov rcx, [rbp+var_18]
mov rax, [rbp+var_10]
cmp rax, [rcx+10h]
jbe short loc_68891
mov rax, [rbp+var_18]
mov rcx, [rax+10h]
shl rcx, 1
mov [rax+10h], rcx
mov rax, [rax+10h]
cmp rax, [rbp+var_10]
jnb short loc_68888
mov rax, [rbp+var_18]
mov rcx, [rbp+var_10]
add rcx, 0FFFh
shr rcx, 0Ch
shl rcx, 0Ch
mov [rax+10h], rcx
loc_68888:
mov rdi, [rbp+var_18]; this
call _ZN6evmone6Memory17allocate_capacityEv; evmone::Memory::allocate_capacity(void)
loc_68891:
mov rdi, [rbp+var_18]
mov rsi, [rdi+8]
call _ZNKSt10unique_ptrIA_hN6evmone6Memory11FreeDeleterEEixEm; std::unique_ptr<uchar [],evmone::Memory::FreeDeleter>::operator[](ulong)
mov [rbp+var_20], rax
jmp short $+2
loc_688A4:
mov rax, [rbp+var_18]
mov rdi, [rbp+var_20]
mov rdx, [rbp+var_10]
sub rdx, [rax+8]
xor esi, esi
call _memset
mov rax, [rbp+var_18]
mov rcx, [rbp+var_10]
mov [rax+8], rcx
add rsp, 20h
pop rbp
retn
mov rdi, rax
call __clang_call_terminate
| evmone::Memory * evmone::Memory::grow(evmone::Memory *this, unsigned long long a2)
{
evmone::Memory *result; // rax
long long v3; // [rsp+0h] [rbp-20h]
if ( (a2 & 0x1F) != 0 )
__assert_fail(
"new_size % 32 == 0",
"/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/lib/evm"
"one/execution_state.hpp",
124LL,
"void evmone::Memory::grow(size_t)");
if ( a2 <= *((_QWORD *)this + 1) )
__assert_fail(
"new_size > m_size",
"/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/lib/evm"
"one/execution_state.hpp",
127LL,
"void evmone::Memory::grow(size_t)");
if ( a2 > *((_QWORD *)this + 2) )
{
*((_QWORD *)this + 2) *= 2LL;
if ( *((_QWORD *)this + 2) < a2 )
*((_QWORD *)this + 2) = (a2 + 4095) >> 12 << 12;
evmone::Memory::allocate_capacity(this);
}
v3 = std::unique_ptr<unsigned char [],evmone::Memory::FreeDeleter>::operator[](this, *((_QWORD *)this + 1));
memset(v3, 0LL, a2 - *((_QWORD *)this + 1));
result = this;
*((_QWORD *)this + 1) = a2;
return result;
}
| grow:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x10]
AND RAX,0x1f
CMP RAX,0x0
JNZ 0x001687f8
JMP 0x00168817
LAB_001687f8:
LEA RDI,[0x1df93c]
LEA RSI,[0x1df94f]
MOV EDX,0x7c
LEA RCX,[0x1df9d9]
CALL 0x00123120
LAB_00168817:
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RCX + 0x8]
JBE 0x00168827
JMP 0x00168846
LAB_00168827:
LEA RDI,[0x1df9fb]
LEA RSI,[0x1df94f]
MOV EDX,0x7f
LEA RCX,[0x1df9d9]
CALL 0x00123120
LAB_00168846:
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RCX + 0x10]
JBE 0x00168891
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RAX + 0x10]
SHL RCX,0x1
MOV qword ptr [RAX + 0x10],RCX
MOV RAX,qword ptr [RAX + 0x10]
CMP RAX,qword ptr [RBP + -0x10]
JNC 0x00168888
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x10]
ADD RCX,0xfff
SHR RCX,0xc
SHL RCX,0xc
MOV qword ptr [RAX + 0x10],RCX
LAB_00168888:
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x0013d300
LAB_00168891:
MOV RDI,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RDI + 0x8]
LAB_00168899:
CALL 0x001688e0
LAB_0016889e:
MOV qword ptr [RBP + -0x20],RAX
JMP 0x001688a4
LAB_001688a4:
MOV RAX,qword ptr [RBP + -0x18]
MOV RDI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x10]
SUB RDX,qword ptr [RAX + 0x8]
XOR ESI,ESI
CALL 0x001231c0
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x8],RCX
ADD RSP,0x20
POP RBP
RET
|
/* evmone::Memory::grow(unsigned long) */
void __thiscall evmone::Memory::grow(Memory *this,ulong param_1)
{
void *__s;
if ((param_1 & 0x1f) != 0) {
/* WARNING: Subroutine does not return */
__assert_fail("new_size % 32 == 0",
"/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/lib/evmone/execution_state.hpp"
,0x7c,"void evmone::Memory::grow(size_t)");
}
if (*(ulong *)(this + 8) < param_1) {
if (*(ulong *)(this + 0x10) < param_1) {
*(long *)(this + 0x10) = *(long *)(this + 0x10) << 1;
if (*(ulong *)(this + 0x10) < param_1) {
*(ulong *)(this + 0x10) = param_1 + 0xfff & 0xfffffffffffff000;
}
allocate_capacity(this);
}
/* try { // try from 00168899 to 0016889d has its CatchHandler @ 001688cd */
__s = (void *)std::unique_ptr<unsigned_char[],evmone::Memory::FreeDeleter>::operator[]
((unique_ptr<unsigned_char[],evmone::Memory::FreeDeleter> *)this,
*(ulong *)(this + 8));
memset(__s,0,param_1 - *(long *)(this + 8));
*(ulong *)(this + 8) = param_1;
return;
}
/* WARNING: Subroutine does not return */
__assert_fail("new_size > m_size",
"/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/lib/evmone/execution_state.hpp"
,0x7f,"void evmone::Memory::grow(size_t)");
}
| |
21,470 | std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [17], std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [3]>(char const (&) [17], std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char&&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&&, char const (&) [3]) | llama.cpp/common/json.hpp | inline OutStringType concat(Args && ... args)
{
OutStringType str;
str.reserve(concat_length(args...));
concat_into(str, std::forward<Args>(args)...);
return str;
} | O3 | cpp | std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [17], std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [3]>(char const (&) [17], std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char&&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&&, char const (&) [3]):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
leaq 0x10(%rdi), %rbp
movq %rbp, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
movq %rsi, %rdi
callq 0x20650
movq %rax, %r13
addq 0x8(%r15), %r13
movq %r14, %rdi
callq 0x20650
addq %rax, %r13
movq %rbx, %rdi
movq %r13, %rsi
callq 0x20de0
movq %rbx, %rdi
movq %r12, %rsi
callq 0x20b20
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %rbx, %rdi
callq 0x20530
movq %rbx, %rdi
movq %r14, %rsi
callq 0x20b20
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq (%rbx), %rdi
cmpq %rbp, %rdi
je 0xbd427
movq (%rbp), %rsi
incq %rsi
callq 0x20170
movq %r14, %rdi
callq 0x20ad0
nop
| _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA13_KcS8_RA17_S9_EEET_DpOT0_:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r14, rcx
mov r15, rdx
mov r12, rsi
mov rbx, rdi
lea rbp, [rdi+10h]
mov [rdi], rbp
mov qword ptr [rdi+8], 0
mov byte ptr [rdi+10h], 0
mov rdi, rsi
call _strlen
mov r13, rax
add r13, [r15+8]
mov rdi, r14
call _strlen
add r13, rax
mov rdi, rbx
mov rsi, r13
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong)
mov rdi, rbx
mov rsi, r12
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov rsi, [r15]
mov rdx, [r15+8]
mov rdi, rbx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKcm; std::string::append(char const*,ulong)
mov rdi, rbx
mov rsi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
mov rax, rbx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r14, rax
mov rdi, [rbx]; void *
cmp rdi, rbp
jz short loc_BD427
mov rsi, [rbp+0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_BD427:
mov rdi, r14
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[13],std::string,char const(&)[17]>(
long long a1,
long long a2,
_QWORD *a3,
long long a4)
{
long long v6; // r13
long long v7; // rax
*(_QWORD *)a1 = a1 + 16;
*(_QWORD *)(a1 + 8) = 0LL;
*(_BYTE *)(a1 + 16) = 0;
v6 = a3[1] + strlen(a2);
v7 = strlen(a4);
std::string::reserve(a1, v7 + v6);
std::string::append(a1, a2);
std::string::append(a1, *a3, a3[1]);
std::string::append(a1, a4);
return a1;
}
| concat<std::__cxx11::string,char_const(&)[13],std::__cxx11::string,char_const(&)[17]>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R14,RCX
MOV R15,RDX
MOV R12,RSI
MOV RBX,RDI
LEA RBP,[RDI + 0x10]
MOV qword ptr [RDI],RBP
MOV qword ptr [RDI + 0x8],0x0
MOV byte ptr [RDI + 0x10],0x0
MOV RDI,RSI
CALL 0x00120650
MOV R13,RAX
ADD R13,qword ptr [R15 + 0x8]
MOV RDI,R14
CALL 0x00120650
ADD R13,RAX
LAB_001bd3ce:
MOV RDI,RBX
MOV RSI,R13
CALL 0x00120de0
MOV RDI,RBX
MOV RSI,R12
CALL 0x00120b20
MOV RSI,qword ptr [R15]
MOV RDX,qword ptr [R15 + 0x8]
MOV RDI,RBX
CALL 0x00120530
MOV RDI,RBX
MOV RSI,R14
CALL 0x00120b20
LAB_001bd3fe:
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* std::__cxx11::string nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string, char const
(&) [13], std::__cxx11::string, char const (&) [17]>(char const (&) [13], std::__cxx11::string&&,
char const (&) [17]) */
detail * __thiscall
nlohmann::json_abi_v3_11_3::detail::
concat<std::__cxx11::string,char_const(&)[13],std::__cxx11::string,char_const(&)[17]>
(detail *this,char *param_1,string *param_2,char *param_3)
{
*(detail **)this = this + 0x10;
*(int8 *)(this + 8) = 0;
this[0x10] = (detail)0x0;
strlen(param_1);
strlen(param_3);
/* try { // try from 001bd3ce to 001bd3fd has its CatchHandler @ 001bd410 */
std::__cxx11::string::reserve((ulong)this);
std::__cxx11::string::append((char *)this);
std::__cxx11::string::append((char *)this,*(ulong *)param_2);
std::__cxx11::string::append((char *)this);
return this;
}
| |
21,471 | nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__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>>>>>::scan_number() | llama.cpp/common/json.hpp | token_type scan_number() // lgtm [cpp/use-of-goto]
{
// reset token_buffer to store the number's bytes
reset();
// the type of the parsed number; initially set to unsigned; will be
// changed if minus sign, decimal point or exponent is read
token_type number_type = token_type::value_unsigned;
// state (init): we just found out we need to scan a number
switch (current)
{
case '-':
{
add(current);
goto scan_number_minus;
}
case '0':
{
add(current);
goto scan_number_zero;
}
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
{
add(current);
goto scan_number_any1;
}
// all other characters are rejected outside scan_number()
default: // LCOV_EXCL_LINE
JSON_ASSERT(false); // NOLINT(cert-dcl03-c,hicpp-static-assert,misc-static-assert) LCOV_EXCL_LINE
}
scan_number_minus:
// state: we just parsed a leading minus sign
number_type = token_type::value_integer;
switch (get())
{
case '0':
{
add(current);
goto scan_number_zero;
}
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
{
add(current);
goto scan_number_any1;
}
default:
{
error_message = "invalid number; expected digit after '-'";
return token_type::parse_error;
}
}
scan_number_zero:
// state: we just parse a zero (maybe with a leading minus sign)
switch (get())
{
case '.':
{
add(decimal_point_char);
goto scan_number_decimal1;
}
case 'e':
case 'E':
{
add(current);
goto scan_number_exponent;
}
default:
goto scan_number_done;
}
scan_number_any1:
// state: we just parsed a number 0-9 (maybe with a leading minus sign)
switch (get())
{
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
{
add(current);
goto scan_number_any1;
}
case '.':
{
add(decimal_point_char);
goto scan_number_decimal1;
}
case 'e':
case 'E':
{
add(current);
goto scan_number_exponent;
}
default:
goto scan_number_done;
}
scan_number_decimal1:
// state: we just parsed a decimal point
number_type = token_type::value_float;
switch (get())
{
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
{
add(current);
goto scan_number_decimal2;
}
default:
{
error_message = "invalid number; expected digit after '.'";
return token_type::parse_error;
}
}
scan_number_decimal2:
// we just parsed at least one number after a decimal point
switch (get())
{
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
{
add(current);
goto scan_number_decimal2;
}
case 'e':
case 'E':
{
add(current);
goto scan_number_exponent;
}
default:
goto scan_number_done;
}
scan_number_exponent:
// we just parsed an exponent
number_type = token_type::value_float;
switch (get())
{
case '+':
case '-':
{
add(current);
goto scan_number_sign;
}
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
{
add(current);
goto scan_number_any2;
}
default:
{
error_message =
"invalid number; expected '+', '-', or digit after exponent";
return token_type::parse_error;
}
}
scan_number_sign:
// we just parsed an exponent sign
switch (get())
{
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
{
add(current);
goto scan_number_any2;
}
default:
{
error_message = "invalid number; expected digit after exponent sign";
return token_type::parse_error;
}
}
scan_number_any2:
// we just parsed a number after the exponent or exponent sign
switch (get())
{
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
{
add(current);
goto scan_number_any2;
}
default:
goto scan_number_done;
}
scan_number_done:
// unget the character after the number (we only read it to know that
// we are done scanning a number)
unget();
char* endptr = nullptr; // NOLINT(cppcoreguidelines-pro-type-vararg,hicpp-vararg)
errno = 0;
// try to parse integers first and fall back to floats
if (number_type == token_type::value_unsigned)
{
const auto x = std::strtoull(token_buffer.data(), &endptr, 10);
// we checked the number format before
JSON_ASSERT(endptr == token_buffer.data() + token_buffer.size());
if (errno == 0)
{
value_unsigned = static_cast<number_unsigned_t>(x);
if (value_unsigned == x)
{
return token_type::value_unsigned;
}
}
}
else if (number_type == token_type::value_integer)
{
const auto x = std::strtoll(token_buffer.data(), &endptr, 10);
// we checked the number format before
JSON_ASSERT(endptr == token_buffer.data() + token_buffer.size());
if (errno == 0)
{
value_integer = static_cast<number_integer_t>(x);
if (value_integer == x)
{
return token_type::value_integer;
}
}
}
// this code is reached if we parse a floating-point number or if an
// integer conversion above failed
strtof(value_float, token_buffer.data(), &endptr);
// we checked the number format before
JSON_ASSERT(endptr == token_buffer.data() + token_buffer.size());
return token_type::value_float;
} | O3 | cpp | nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__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>>>>>::scan_number():
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x95f6c
movl 0x14(%rbx), %eax
leal -0x31(%rax), %ecx
cmpl $0x9, %ecx
jae 0x95ce6
leaq 0x50(%rbx), %r14
movl $0x5, %ebp
movsbl %al, %esi
movq %r14, %rdi
callq 0x22400
leaq 0x50(%rbx), %r14
movq %rbx, %rdi
callq 0x22d18
leal -0x30(%rax), %ecx
cmpl $0xa, %ecx
jae 0x95bf6
movsbl 0x14(%rbx), %esi
movq %r14, %rdi
callq 0x22400
jmp 0x95bd8
cmpl $0x2e, %eax
je 0x95d58
cmpl $0x45, %eax
je 0x95db4
cmpl $0x65, %eax
je 0x95db4
movq %rbx, %rdi
callq 0x95f08
movq $0x0, (%rsp)
callq 0x22150
movq %rax, %r14
movl $0x0, (%rax)
movq 0x50(%rbx), %rdi
movq %rsp, %r15
movq %r15, %rsi
movl $0xa, %edx
cmpl $0x5, %ebp
jne 0x95c6b
callq 0x21e30
movq 0x50(%rbx), %rcx
addq 0x58(%rbx), %rcx
cmpq %rcx, (%r15)
jne 0x95eae
cmpl $0x0, (%r14)
jne 0x95c87
movl $0x5, %ecx
movl $0x80, %edx
jmp 0x95cdd
callq 0x21d90
movq 0x50(%rbx), %rcx
addq 0x58(%rbx), %rcx
cmpq %rcx, (%r15)
jne 0x95eca
cmpl $0x0, (%r14)
je 0x95cd3
movq 0x50(%rbx), %rdi
movq %rsp, %r14
movq %r14, %rsi
callq 0x224c0
movsd %xmm0, 0x88(%rbx)
movq 0x50(%rbx), %rax
addq 0x58(%rbx), %rax
movl $0x7, %ecx
cmpq %rax, (%r14)
je 0x95dee
leaq 0x8f5eb(%rip), %rdi # 0x1252a6
leaq 0x8673e(%rip), %rdx # 0x11c400
leaq 0x8f844(%rip), %rcx # 0x12550d
movl $0x21d6, %esi # imm = 0x21D6
jmp 0x95f00
movl $0x6, %ecx
movl $0x78, %edx
movq %rax, (%rbx,%rdx)
jmp 0x95dee
cmpl $0x30, %eax
je 0x95d26
cmpl $0x2d, %eax
jne 0x95ee6
leaq 0x50(%rbx), %r14
movq %r14, %rdi
movl $0x2d, %esi
callq 0x22400
movq %rbx, %rdi
callq 0x22d18
leal -0x31(%rax), %ecx
cmpl $0x9, %ecx
jae 0x95e87
movl 0x14(%rbx), %eax
movl $0x6, %ebp
jmp 0x95bc9
leaq 0x50(%rbx), %rdi
movl $0x30, %esi
callq 0x22400
movl $0x5, %ebp
movq %rbx, %rdi
callq 0x22d18
cmpl $0x65, %eax
je 0x95db0
cmpl $0x45, %eax
je 0x95db0
cmpl $0x2e, %eax
jne 0x95c11
leaq 0x50(%rbx), %r14
movsbl 0x90(%rbx), %esi
movq %r14, %rdi
callq 0x22400
movq %rbx, %rdi
callq 0x22d18
addl $-0x30, %eax
cmpl $0x9, %eax
ja 0x95da7
leaq 0x50(%rbx), %r14
movsbl 0x14(%rbx), %esi
movq %r14, %rdi
callq 0x22400
movq %rbx, %rdi
callq 0x22d18
leal -0x30(%rax), %ecx
cmpl $0xa, %ecx
jb 0x95d7b
cmpl $0x65, %eax
je 0x95db4
cmpl $0x45, %eax
jne 0x95e3b
jmp 0x95db4
leaq 0x8759c(%rip), %rax # 0x11d34a
jmp 0x95de5
leaq 0x50(%rbx), %r14
movsbl 0x14(%rbx), %esi
movq %r14, %rdi
callq 0x22400
movq %rbx, %rdi
callq 0x22d18
leal -0x30(%rax), %ecx
cmpl $0xa, %ecx
jb 0x95dfb
cmpl $0x2d, %eax
je 0x95e5b
cmpl $0x2b, %eax
je 0x95e5b
leaq 0x8758e(%rip), %rax # 0x11d373
movq %rax, 0x70(%rbx)
movl $0xe, %ecx
movl %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x50(%rbx), %r14
movsbl 0x14(%rbx), %esi
movq %r14, %rdi
callq 0x22400
movq %rbx, %rdi
callq 0x22d18
addl $-0x30, %eax
cmpl $0x9, %eax
ja 0x95e3b
leaq 0x50(%rbx), %r14
movsbl 0x14(%rbx), %esi
movq %r14, %rdi
callq 0x22400
movq %rbx, %rdi
callq 0x22d18
addl $-0x30, %eax
cmpl $0xa, %eax
jb 0x95e1f
movq %rbx, %rdi
callq 0x95f08
movq $0x0, (%rsp)
callq 0x22150
movl $0x0, (%rax)
jmp 0x95c87
movsbl 0x14(%rbx), %esi
leaq 0x50(%rbx), %r14
movq %r14, %rdi
callq 0x22400
movq %rbx, %rdi
callq 0x22d18
addl $-0x30, %eax
cmpl $0xa, %eax
jb 0x95dff
leaq 0x8752c(%rip), %rax # 0x11d3ae
jmp 0x95de5
cmpl $0x30, %eax
je 0x95e98
leaq 0x8748e(%rip), %rax # 0x11d321
jmp 0x95de5
movsbl 0x14(%rbx), %esi
movq %r14, %rdi
callq 0x22400
movl $0x6, %ebp
jmp 0x95d39
leaq 0x8f3f1(%rip), %rdi # 0x1252a6
leaq 0x86544(%rip), %rdx # 0x11c400
leaq 0x8f64a(%rip), %rcx # 0x12550d
movl $0x21b5, %esi # imm = 0x21B5
jmp 0x95f00
leaq 0x8f3d5(%rip), %rdi # 0x1252a6
leaq 0x86528(%rip), %rdx # 0x11c400
leaq 0x8f62e(%rip), %rcx # 0x12550d
movl $0x21c5, %esi # imm = 0x21C5
jmp 0x95f00
leaq 0x8f3b9(%rip), %rdi # 0x1252a6
leaq 0x8650c(%rip), %rdx # 0x11c400
leaq 0x8c449(%rip), %rcx # 0x122344
movl $0x20be, %esi # imm = 0x20BE
xorl %eax, %eax
callq 0x21ec0
nop
| _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE11scan_numberEv:
push rbp
push r15
push r14
push rbx
push rax
mov rbx, rdi
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE5resetEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::reset(void)
mov eax, [rbx+14h]
lea ecx, [rax-31h]
cmp ecx, 9
jnb loc_95CE6
lea r14, [rbx+50h]
mov ebp, 5
loc_95BC9:
movsx esi, al
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
lea r14, [rbx+50h]
loc_95BD8:
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
lea ecx, [rax-30h]
cmp ecx, 0Ah
jnb short loc_95BF6
movsx esi, byte ptr [rbx+14h]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
jmp short loc_95BD8
loc_95BF6:
cmp eax, 2Eh ; '.'
jz loc_95D58
cmp eax, 45h ; 'E'
jz loc_95DB4
cmp eax, 65h ; 'e'
jz loc_95DB4
loc_95C11:
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE5ungetEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget(void)
mov [rsp+28h+var_28], 0
call ___errno_location
mov r14, rax
mov dword ptr [rax], 0
mov rdi, [rbx+50h]
mov r15, rsp
mov rsi, r15
mov edx, 0Ah
cmp ebp, 5
jnz short loc_95C6B
call _strtoull
mov rcx, [rbx+50h]
add rcx, [rbx+58h]
cmp [r15], rcx
jnz loc_95EAE
cmp dword ptr [r14], 0
jnz short loc_95C87
mov ecx, 5
mov edx, 80h
jmp short loc_95CDD
loc_95C6B:
call _strtoll
mov rcx, [rbx+50h]
add rcx, [rbx+58h]
cmp [r15], rcx
jnz loc_95ECA
cmp dword ptr [r14], 0
jz short loc_95CD3
loc_95C87:
mov rdi, [rbx+50h]
mov r14, rsp
mov rsi, r14
call _strtod
movsd qword ptr [rbx+88h], xmm0
mov rax, [rbx+50h]
add rax, [rbx+58h]
mov ecx, 7
cmp [r14], rax
jz loc_95DEE
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/llama."...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aEndptrTokenBuf; "endptr == token_buffer.data() + token_b"...
mov esi, 21D6h
jmp loc_95F00
loc_95CD3:
mov ecx, 6
mov edx, 78h ; 'x'
loc_95CDD:
mov [rbx+rdx], rax
jmp loc_95DEE
loc_95CE6:
cmp eax, 30h ; '0'
jz short loc_95D26
cmp eax, 2Dh ; '-'
jnz loc_95EE6
lea r14, [rbx+50h]
mov rdi, r14
mov esi, 2Dh ; '-'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
lea ecx, [rax-31h]
cmp ecx, 9
jnb loc_95E87
mov eax, [rbx+14h]
mov ebp, 6
jmp loc_95BC9
loc_95D26:
lea rdi, [rbx+50h]
mov esi, 30h ; '0'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov ebp, 5
loc_95D39:
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
cmp eax, 65h ; 'e'
jz short loc_95DB0
cmp eax, 45h ; 'E'
jz short loc_95DB0
cmp eax, 2Eh ; '.'
jnz loc_95C11
lea r14, [rbx+50h]
loc_95D58:
movsx esi, byte ptr [rbx+90h]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
add eax, 0FFFFFFD0h
cmp eax, 9
ja short loc_95DA7
lea r14, [rbx+50h]
loc_95D7B:
movsx esi, byte ptr [rbx+14h]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
lea ecx, [rax-30h]
cmp ecx, 0Ah
jb short loc_95D7B
cmp eax, 65h ; 'e'
jz short loc_95DB4
cmp eax, 45h ; 'E'
jnz loc_95E3B
jmp short loc_95DB4
loc_95DA7:
lea rax, aInvalidNumberE_1; "invalid number; expected digit after '."...
jmp short loc_95DE5
loc_95DB0:
lea r14, [rbx+50h]
loc_95DB4:
movsx esi, byte ptr [rbx+14h]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
lea ecx, [rax-30h]
cmp ecx, 0Ah
jb short loc_95DFB
cmp eax, 2Dh ; '-'
jz loc_95E5B
cmp eax, 2Bh ; '+'
jz short loc_95E5B
lea rax, aInvalidNumberE; "invalid number; expected '+', '-', or d"...
loc_95DE5:
mov [rbx+70h], rax
mov ecx, 0Eh
loc_95DEE:
mov eax, ecx
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
loc_95DFB:
lea r14, [rbx+50h]
loc_95DFF:
movsx esi, byte ptr [rbx+14h]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
add eax, 0FFFFFFD0h
cmp eax, 9
ja short loc_95E3B
lea r14, [rbx+50h]
loc_95E1F:
movsx esi, byte ptr [rbx+14h]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
add eax, 0FFFFFFD0h
cmp eax, 0Ah
jb short loc_95E1F
loc_95E3B:
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE5ungetEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget(void)
mov [rsp+28h+var_28], 0
call ___errno_location
mov dword ptr [rax], 0
jmp loc_95C87
loc_95E5B:
movsx esi, byte ptr [rbx+14h]
lea r14, [rbx+50h]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void)
add eax, 0FFFFFFD0h
cmp eax, 0Ah
jb short loc_95DFF
lea rax, aInvalidNumberE_2; "invalid number; expected digit after ex"...
jmp loc_95DE5
loc_95E87:
cmp eax, 30h ; '0'
jz short loc_95E98
lea rax, aInvalidNumberE_0; "invalid number; expected digit after '-"...
jmp loc_95DE5
loc_95E98:
movsx esi, byte ptr [rbx+14h]
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char)
mov ebp, 6
jmp loc_95D39
loc_95EAE:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/llama."...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aEndptrTokenBuf; "endptr == token_buffer.data() + token_b"...
mov esi, 21B5h
jmp short loc_95F00
loc_95ECA:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/llama."...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aEndptrTokenBuf; "endptr == token_buffer.data() + token_b"...
mov esi, 21C5h
jmp short loc_95F00
loc_95EE6:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/llama."...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aAdvancedOption+0ABh; "false"
mov esi, 20BEh
loc_95F00:
xor eax, eax
call _ggml_abort
nop
| long long nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::scan_number(
long long a1)
{
long long v1; // rax
long long v3; // rdx
long long v4; // r8
long long v5; // r9
int v6; // eax
long long v7; // rcx
long long v8; // r14
int v9; // ebp
long long v10; // r14
int v11; // eax
long long v12; // rdx
long long v13; // r8
long long v14; // r9
long long v15; // rcx
_DWORD *v16; // r14
long long v17; // rdi
long long v18; // rax
unsigned int v19; // ecx
long long v20; // rdx
int v21; // eax
int v22; // eax
int v23; // eax
const char *v24; // rax
int v25; // eax
long long v26; // rdx
long long v27; // r8
long long v28; // r9
long long v29; // rcx
long long v31; // r14
long long v32; // rdx
long long v33; // rcx
long long v34; // r8
long long v35; // r9
_QWORD v36[5]; // [rsp+0h] [rbp-28h] BYREF
v36[0] = v1;
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::reset(a1);
v6 = *(_DWORD *)(a1 + 20);
v7 = (unsigned int)(v6 - 49);
if ( (unsigned int)v7 >= 9 )
{
if ( v6 == 48 )
{
std::string::push_back(a1 + 80, 48LL, v3, v7, v4, v5);
v9 = 5;
}
else
{
if ( v6 != 45 )
{
ggml_abort(
"/workspace/llm4binary/github2025/llama.cpp/common/json.hpp",
8382LL,
"GGML_ASSERT(%s) failed",
"false");
return nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget("/workspace/llm4binary/github2025/llama.cpp/common/json.hpp");
}
v8 = a1 + 80;
std::string::push_back(a1 + 80, 45LL, v3, v7, v4, v5);
v21 = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1);
v7 = (unsigned int)(v21 - 49);
if ( (unsigned int)v7 < 9 )
{
v6 = *(_DWORD *)(a1 + 20);
v9 = 6;
goto LABEL_3;
}
if ( v21 != 48 )
{
v24 = "invalid number; expected digit after '-'";
goto LABEL_40;
}
std::string::push_back(a1 + 80, (unsigned int)*(char *)(a1 + 20), v3, v7, v4, v5);
v9 = 6;
}
v22 = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1);
if ( v22 == 101 || v22 == 69 )
{
v10 = a1 + 80;
goto LABEL_36;
}
if ( v22 != 46 )
goto LABEL_9;
v10 = a1 + 80;
LABEL_28:
std::string::push_back(v10, (unsigned int)*(char *)(a1 + 144), v12, v15, v13, v14);
if ( (unsigned int)nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1)
- 48 > 9 )
{
v24 = "invalid number; expected digit after '.'";
LABEL_40:
*(_QWORD *)(a1 + 112) = v24;
return 14;
}
v10 = a1 + 80;
do
{
std::string::push_back(a1 + 80, (unsigned int)*(char *)(a1 + 20), v12, v15, v13, v14);
v23 = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1);
v15 = (unsigned int)(v23 - 48);
}
while ( (unsigned int)v15 < 0xA );
if ( v23 != 101 && v23 != 69 )
{
LABEL_45:
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget(a1);
v36[0] = 0LL;
*(_DWORD *)__errno_location(a1) = 0;
goto LABEL_15;
}
LABEL_36:
std::string::push_back(v10, (unsigned int)*(char *)(a1 + 20), v12, v15, v13, v14);
v25 = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1);
v29 = (unsigned int)(v25 - 48);
if ( (unsigned int)v29 < 0xA )
{
v31 = a1 + 80;
}
else
{
if ( v25 != 45 && v25 != 43 )
{
v24 = "invalid number; expected '+', '-', or digit after exponent";
goto LABEL_40;
}
v31 = a1 + 80;
std::string::push_back(a1 + 80, (unsigned int)*(char *)(a1 + 20), v26, v29, v27, v28);
if ( (unsigned int)nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1)
- 48 >= 0xA )
{
v24 = "invalid number; expected digit after exponent sign";
goto LABEL_40;
}
}
std::string::push_back(v31, (unsigned int)*(char *)(a1 + 20), v26, v29, v27, v28);
if ( (unsigned int)nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1)
- 48 <= 9 )
{
do
std::string::push_back(a1 + 80, (unsigned int)*(char *)(a1 + 20), v32, v33, v34, v35);
while ( (unsigned int)nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1)
- 48 < 0xA );
}
goto LABEL_45;
}
v8 = a1 + 80;
v9 = 5;
LABEL_3:
std::string::push_back(v8, (unsigned int)(char)v6, v3, v7, v4, v5);
v10 = a1 + 80;
while ( 1 )
{
v11 = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get((__m128i *)a1);
v15 = (unsigned int)(v11 - 48);
if ( (unsigned int)v15 >= 0xA )
break;
std::string::push_back(a1 + 80, (unsigned int)*(char *)(a1 + 20), v12, v15, v13, v14);
}
if ( v11 == 46 )
goto LABEL_28;
if ( v11 == 69 || v11 == 101 )
goto LABEL_36;
LABEL_9:
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget(a1);
v36[0] = 0LL;
v16 = (_DWORD *)__errno_location(a1);
*v16 = 0;
v17 = *(_QWORD *)(a1 + 80);
if ( v9 == 5 )
{
v18 = strtoull(v17, v36, 10LL);
if ( v36[0] != *(_QWORD *)(a1 + 88) + *(_QWORD *)(a1 + 80) )
{
ggml_abort(
"/workspace/llm4binary/github2025/llama.cpp/common/json.hpp",
8629LL,
"GGML_ASSERT(%s) failed",
"endptr == token_buffer.data() + token_buffer.size()");
return nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget("/workspace/llm4binary/github2025/llama.cpp/common/json.hpp");
}
if ( !*v16 )
{
v19 = 5;
v20 = 128LL;
LABEL_18:
*(_QWORD *)(a1 + v20) = v18;
return v19;
}
}
else
{
v18 = strtoll(v17, v36, 10LL);
if ( v36[0] != *(_QWORD *)(a1 + 88) + *(_QWORD *)(a1 + 80) )
{
ggml_abort(
"/workspace/llm4binary/github2025/llama.cpp/common/json.hpp",
8645LL,
"GGML_ASSERT(%s) failed",
"endptr == token_buffer.data() + token_buffer.size()");
return nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget("/workspace/llm4binary/github2025/llama.cpp/common/json.hpp");
}
if ( !*v16 )
{
v19 = 6;
v20 = 120LL;
goto LABEL_18;
}
}
LABEL_15:
*(double *)(a1 + 136) = strtod(*(_QWORD *)(a1 + 80), v36);
v19 = 7;
if ( v36[0] == *(_QWORD *)(a1 + 88) + *(_QWORD *)(a1 + 80) )
return v19;
ggml_abort(
"/workspace/llm4binary/github2025/llama.cpp/common/json.hpp",
8662LL,
"GGML_ASSERT(%s) failed",
"endptr == token_buffer.data() + token_buffer.size()");
return nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget("/workspace/llm4binary/github2025/llama.cpp/common/json.hpp");
}
| scan_number:
PUSH RBP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
CALL 0x00195f6c
MOV EAX,dword ptr [RBX + 0x14]
LEA ECX,[RAX + -0x31]
CMP ECX,0x9
JNC 0x00195ce6
LEA R14,[RBX + 0x50]
MOV EBP,0x5
LAB_00195bc9:
MOVSX ESI,AL
MOV RDI,R14
CALL 0x00122400
LEA R14,[RBX + 0x50]
LAB_00195bd8:
MOV RDI,RBX
CALL 0x00122d18
LEA ECX,[RAX + -0x30]
CMP ECX,0xa
JNC 0x00195bf6
MOVSX ESI,byte ptr [RBX + 0x14]
MOV RDI,R14
CALL 0x00122400
JMP 0x00195bd8
LAB_00195bf6:
CMP EAX,0x2e
JZ 0x00195d58
CMP EAX,0x45
JZ 0x00195db4
CMP EAX,0x65
JZ 0x00195db4
LAB_00195c11:
MOV RDI,RBX
CALL 0x00195f08
MOV qword ptr [RSP],0x0
CALL 0x00122150
MOV R14,RAX
MOV dword ptr [RAX],0x0
MOV RDI,qword ptr [RBX + 0x50]
MOV R15,RSP
MOV RSI,R15
MOV EDX,0xa
CMP EBP,0x5
JNZ 0x00195c6b
CALL 0x00121e30
MOV RCX,qword ptr [RBX + 0x50]
ADD RCX,qword ptr [RBX + 0x58]
CMP qword ptr [R15],RCX
JNZ 0x00195eae
CMP dword ptr [R14],0x0
JNZ 0x00195c87
MOV ECX,0x5
MOV EDX,0x80
JMP 0x00195cdd
LAB_00195c6b:
CALL 0x00121d90
MOV RCX,qword ptr [RBX + 0x50]
ADD RCX,qword ptr [RBX + 0x58]
CMP qword ptr [R15],RCX
JNZ 0x00195eca
CMP dword ptr [R14],0x0
JZ 0x00195cd3
LAB_00195c87:
MOV RDI,qword ptr [RBX + 0x50]
MOV R14,RSP
MOV RSI,R14
CALL 0x001224c0
MOVSD qword ptr [RBX + 0x88],XMM0
MOV RAX,qword ptr [RBX + 0x50]
ADD RAX,qword ptr [RBX + 0x58]
MOV ECX,0x7
CMP qword ptr [R14],RAX
JZ 0x00195dee
LEA RDI,[0x2252a6]
LEA RDX,[0x21c400]
LEA RCX,[0x22550d]
MOV ESI,0x21d6
JMP 0x00195f00
LAB_00195cd3:
MOV ECX,0x6
MOV EDX,0x78
LAB_00195cdd:
MOV qword ptr [RBX + RDX*0x1],RAX
JMP 0x00195dee
LAB_00195ce6:
CMP EAX,0x30
JZ 0x00195d26
CMP EAX,0x2d
JNZ 0x00195ee6
LEA R14,[RBX + 0x50]
MOV RDI,R14
MOV ESI,0x2d
CALL 0x00122400
MOV RDI,RBX
CALL 0x00122d18
LEA ECX,[RAX + -0x31]
CMP ECX,0x9
JNC 0x00195e87
MOV EAX,dword ptr [RBX + 0x14]
MOV EBP,0x6
JMP 0x00195bc9
LAB_00195d26:
LEA RDI,[RBX + 0x50]
MOV ESI,0x30
CALL 0x00122400
MOV EBP,0x5
LAB_00195d39:
MOV RDI,RBX
CALL 0x00122d18
CMP EAX,0x65
JZ 0x00195db0
CMP EAX,0x45
JZ 0x00195db0
CMP EAX,0x2e
JNZ 0x00195c11
LEA R14,[RBX + 0x50]
LAB_00195d58:
MOVSX ESI,byte ptr [RBX + 0x90]
MOV RDI,R14
CALL 0x00122400
MOV RDI,RBX
CALL 0x00122d18
ADD EAX,-0x30
CMP EAX,0x9
JA 0x00195da7
LEA R14,[RBX + 0x50]
LAB_00195d7b:
MOVSX ESI,byte ptr [RBX + 0x14]
MOV RDI,R14
CALL 0x00122400
MOV RDI,RBX
CALL 0x00122d18
LEA ECX,[RAX + -0x30]
CMP ECX,0xa
JC 0x00195d7b
CMP EAX,0x65
JZ 0x00195db4
CMP EAX,0x45
JNZ 0x00195e3b
JMP 0x00195db4
LAB_00195da7:
LEA RAX,[0x21d34a]
JMP 0x00195de5
LAB_00195db0:
LEA R14,[RBX + 0x50]
LAB_00195db4:
MOVSX ESI,byte ptr [RBX + 0x14]
MOV RDI,R14
CALL 0x00122400
MOV RDI,RBX
CALL 0x00122d18
LEA ECX,[RAX + -0x30]
CMP ECX,0xa
JC 0x00195dfb
CMP EAX,0x2d
JZ 0x00195e5b
CMP EAX,0x2b
JZ 0x00195e5b
LEA RAX,[0x21d373]
LAB_00195de5:
MOV qword ptr [RBX + 0x70],RAX
MOV ECX,0xe
LAB_00195dee:
MOV EAX,ECX
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_00195dfb:
LEA R14,[RBX + 0x50]
LAB_00195dff:
MOVSX ESI,byte ptr [RBX + 0x14]
MOV RDI,R14
CALL 0x00122400
MOV RDI,RBX
CALL 0x00122d18
ADD EAX,-0x30
CMP EAX,0x9
JA 0x00195e3b
LEA R14,[RBX + 0x50]
LAB_00195e1f:
MOVSX ESI,byte ptr [RBX + 0x14]
MOV RDI,R14
CALL 0x00122400
MOV RDI,RBX
CALL 0x00122d18
ADD EAX,-0x30
CMP EAX,0xa
JC 0x00195e1f
LAB_00195e3b:
MOV RDI,RBX
CALL 0x00195f08
MOV qword ptr [RSP],0x0
CALL 0x00122150
MOV dword ptr [RAX],0x0
JMP 0x00195c87
LAB_00195e5b:
MOVSX ESI,byte ptr [RBX + 0x14]
LEA R14,[RBX + 0x50]
MOV RDI,R14
CALL 0x00122400
MOV RDI,RBX
CALL 0x00122d18
ADD EAX,-0x30
CMP EAX,0xa
JC 0x00195dff
LEA RAX,[0x21d3ae]
JMP 0x00195de5
LAB_00195e87:
CMP EAX,0x30
JZ 0x00195e98
LEA RAX,[0x21d321]
JMP 0x00195de5
LAB_00195e98:
MOVSX ESI,byte ptr [RBX + 0x14]
MOV RDI,R14
CALL 0x00122400
MOV EBP,0x6
JMP 0x00195d39
LAB_00195eae:
LEA RDI,[0x2252a6]
LEA RDX,[0x21c400]
LEA RCX,[0x22550d]
MOV ESI,0x21b5
JMP 0x00195f00
LAB_00195eca:
LEA RDI,[0x2252a6]
LEA RDX,[0x21c400]
LEA RCX,[0x22550d]
MOV ESI,0x21c5
JMP 0x00195f00
LAB_00195ee6:
LEA RDI,[0x2252a6]
LEA RDX,[0x21c400]
LEA RCX,[0x222344]
MOV ESI,0x20be
LAB_00195f00:
XOR EAX,EAX
CALL 0x00121ec0
|
/* nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, 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 > > >::scan_number() */
int8 __thiscall
nlohmann::json_abi_v3_11_3::detail::
lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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>>>
::scan_number(lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
*this)
{
char cVar1;
int iVar2;
int iVar3;
char *in_RAX;
int *piVar4;
ulonglong uVar5;
int8 uVar6;
char *pcVar7;
long lVar8;
double dVar9;
char *local_28;
local_28 = in_RAX;
reset(this);
iVar3 = *(int *)(this + 0x14);
cVar1 = (char)this;
if (iVar3 - 0x31U < 9) {
iVar3 = 5;
LAB_00195bc9:
std::__cxx11::string::push_back(cVar1 + 'P');
while (iVar2 = get(this), iVar2 - 0x30U < 10) {
std::__cxx11::string::push_back(cVar1 + 'P');
}
if (iVar2 == 0x2e) {
LAB_00195d58:
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = get(this);
if (9 < iVar3 - 0x30U) {
pcVar7 = "invalid number; expected digit after \'.\'";
goto LAB_00195de5;
}
do {
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = get(this);
} while (iVar3 - 0x30U < 10);
if ((iVar3 == 0x65) || (iVar3 == 0x45)) goto LAB_00195db4;
goto LAB_00195e3b;
}
if ((iVar2 == 0x45) || (iVar2 == 0x65)) goto LAB_00195db4;
LAB_00195c11:
unget(this);
local_28 = (char *)0x0;
piVar4 = __errno_location();
*piVar4 = 0;
if (iVar3 == 5) {
uVar5 = strtoull(*(char **)(this + 0x50),&local_28,10);
if (local_28 != (char *)(*(long *)(this + 0x50) + *(long *)(this + 0x58))) {
pcVar7 = "endptr == token_buffer.data() + token_buffer.size()";
uVar6 = 0x21b5;
goto LAB_00195f00;
}
if (*piVar4 == 0) {
uVar6 = 5;
lVar8 = 0x80;
LAB_00195cdd:
*(ulonglong *)(this + lVar8) = uVar5;
return uVar6;
}
}
else {
uVar5 = strtoll(*(char **)(this + 0x50),&local_28,10);
if (local_28 != (char *)(*(long *)(this + 0x50) + *(long *)(this + 0x58))) {
pcVar7 = "endptr == token_buffer.data() + token_buffer.size()";
uVar6 = 0x21c5;
goto LAB_00195f00;
}
if (*piVar4 == 0) {
uVar6 = 6;
lVar8 = 0x78;
goto LAB_00195cdd;
}
}
}
else {
if (iVar3 == 0x30) {
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = 5;
}
else {
if (iVar3 != 0x2d) {
pcVar7 = "false";
uVar6 = 0x20be;
goto LAB_00195f00;
}
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = get(this);
if (iVar3 - 0x31U < 9) {
iVar3 = 6;
goto LAB_00195bc9;
}
if (iVar3 != 0x30) {
pcVar7 = "invalid number; expected digit after \'-\'";
goto LAB_00195de5;
}
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = 6;
}
iVar2 = get(this);
if ((iVar2 != 0x65) && (iVar2 != 0x45)) {
if (iVar2 != 0x2e) goto LAB_00195c11;
goto LAB_00195d58;
}
LAB_00195db4:
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = get(this);
if (9 < iVar3 - 0x30U) {
if ((iVar3 != 0x2d) && (iVar3 != 0x2b)) {
pcVar7 = "invalid number; expected \'+\', \'-\', or digit after exponent";
LAB_00195de5:
*(char **)(this + 0x70) = pcVar7;
return 0xe;
}
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = get(this);
if (9 < iVar3 - 0x30U) {
pcVar7 = "invalid number; expected digit after exponent sign";
goto LAB_00195de5;
}
}
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = get(this);
if (iVar3 - 0x30U < 10) {
do {
std::__cxx11::string::push_back(cVar1 + 'P');
iVar3 = get(this);
} while (iVar3 - 0x30U < 10);
}
LAB_00195e3b:
unget(this);
local_28 = (char *)0x0;
piVar4 = __errno_location();
*piVar4 = 0;
}
dVar9 = strtod(*(char **)(this + 0x50),&local_28);
*(double *)(this + 0x88) = dVar9;
if (local_28 == (char *)(*(long *)(this + 0x50) + *(long *)(this + 0x58))) {
return 7;
}
pcVar7 = "endptr == token_buffer.data() + token_buffer.size()";
uVar6 = 0x21d6;
LAB_00195f00:
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github2025/llama.cpp/common/json.hpp",uVar6,
"GGML_ASSERT(%s) failed",pcVar7);
}
| |
21,472 | common_arg::common_arg(std::initializer_list<char const*> const&, char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, void (*)(common_params&, int)) | monkey531[P]llama/common/arg.h | common_arg(
const std::initializer_list<const char *> & args,
const char * value_hint,
const std::string & help,
void (*handler)(common_params & params, int)
) : args(args), value_hint(value_hint), help(help), handler_int(handler) {} | O1 | c | common_arg::common_arg(std::initializer_list<char const*> const&, char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, void (*)(common_params&, int)):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r8, %r14
movq %rcx, %r15
movq %rdx, %r12
movq %rsi, %rbp
movq %rdi, %rbx
leaq 0x4(%rsp), %rsi
movl $0x0, (%rsi)
leaq 0x3(%rsp), %rcx
leaq 0x2(%rsp), %r8
movl $0x1, %edx
callq 0xd8a46
leaq 0x38(%rbx), %rax
xorps %xmm0, %xmm0
movups %xmm0, 0x40(%rbx)
movups %xmm0, 0x50(%rbx)
movups %xmm0, 0x30(%rbx)
movq %rax, 0x48(%rbx)
movq %rax, 0x50(%rbx)
movq $0x0, 0x58(%rbx)
leaq 0x60(%rbx), %r13
movq (%rbp), %rsi
movq 0x8(%rbp), %rdx
leaq 0x1(%rsp), %rcx
movq %r13, %rdi
callq 0xd8ac8
movq %r12, 0x78(%rbx)
leaq 0x90(%rbx), %rdi
leaq 0xa0(%rbx), %rax
xorps %xmm0, %xmm0
movups %xmm0, 0x80(%rbx)
movq %rax, 0x90(%rbx)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
callq 0x4d38c
movb $0x0, 0xb0(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0xb8(%rbx)
movq $0x0, 0xc8(%rbx)
movq %r14, 0xd0(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq (%r13), %rdi
testq %rdi, %rdi
je 0xd7b82
movq 0x70(%rbx), %rsi
subq %rdi, %rsi
callq 0x1fae0
jmp 0xd7b82
movq %rax, %r14
leaq 0x30(%rbx), %rdi
callq 0xd8b0e
movq %rbx, %rdi
callq 0xd8b0e
movq %r14, %rdi
callq 0x20380
nop
| _ZN10common_argC2ERKSt16initializer_listIPKcES2_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPFvR13common_paramsiE:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r14, r8
mov r15, rcx
mov r12, rdx
mov rbp, rsi
mov rbx, rdi
lea rsi, [rsp+38h+var_34]
mov dword ptr [rsi], 0
lea rcx, [rsp+38h+var_35]
lea r8, [rsp+38h+var_36]
mov edx, 1
call _ZNSt3setI13llama_exampleSt4lessIS0_ESaIS0_EEC2ESt16initializer_listIS0_ERKS2_RKS3_; std::set<llama_example>::set(std::initializer_list<llama_example>,std::less<llama_example> const&,std::allocator<llama_example> const&)
lea rax, [rbx+38h]
xorps xmm0, xmm0
movups xmmword ptr [rbx+40h], xmm0
movups xmmword ptr [rbx+50h], xmm0
movups xmmword ptr [rbx+30h], xmm0
mov [rbx+48h], rax
mov [rbx+50h], rax
mov qword ptr [rbx+58h], 0
lea r13, [rbx+60h]
mov rsi, [rbp+0]
mov rdx, [rbp+8]
lea rcx, [rsp+38h+var_37]
mov rdi, r13
call _ZNSt6vectorIPKcSaIS1_EEC2ESt16initializer_listIS1_ERKS2_; std::vector<char const*>::vector(std::initializer_list<char const*>,std::allocator<char const*> const&)
mov [rbx+78h], r12
lea rdi, [rbx+90h]
lea rax, [rbx+0A0h]
xorps xmm0, xmm0
movups xmmword ptr [rbx+80h], xmm0
mov [rbx+90h], rax
mov rsi, [r15]
mov rdx, [r15+8]
add rdx, rsi
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
mov byte ptr [rbx+0B0h], 0
xorps xmm0, xmm0
movups xmmword ptr [rbx+0B8h], xmm0
mov qword ptr [rbx+0C8h], 0
mov [rbx+0D0h], r14
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r14, rax
mov rdi, [r13+0]; void *
test rdi, rdi
jz short loc_D7B82
mov rsi, [rbx+70h]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_D7B82
mov r14, rax
loc_D7B82:
lea rdi, [rbx+30h]
call _ZNSt8_Rb_treeI13llama_exampleS0_St9_IdentityIS0_ESt4lessIS0_ESaIS0_EED2Ev; std::_Rb_tree<llama_example,llama_example,std::_Identity<llama_example>,std::less<llama_example>,std::allocator<llama_example>>::~_Rb_tree()
mov rdi, rbx
call _ZNSt8_Rb_treeI13llama_exampleS0_St9_IdentityIS0_ESt4lessIS0_ESaIS0_EED2Ev; std::_Rb_tree<llama_example,llama_example,std::_Identity<llama_example>,std::less<llama_example>,std::allocator<llama_example>>::~_Rb_tree()
mov rdi, r14
call __Unwind_Resume
| long long common_arg::common_arg(long long a1, _QWORD *a2, long long a3, long long a4, long long a5)
{
int v5; // eax
long long result; // rax
int v10; // [rsp+0h] [rbp-38h] BYREF
_DWORD v11[13]; // [rsp+4h] [rbp-34h] BYREF
v10 = v5;
v11[0] = 0;
std::set<llama_example>::set(a1, v11, 1LL, (char *)&v10 + 3, (char *)&v10 + 2);
*(_OWORD *)(a1 + 64) = 0LL;
*(_OWORD *)(a1 + 80) = 0LL;
*(_OWORD *)(a1 + 48) = 0LL;
*(_QWORD *)(a1 + 72) = a1 + 56;
*(_QWORD *)(a1 + 80) = a1 + 56;
*(_QWORD *)(a1 + 88) = 0LL;
std::vector<char const*>::vector(a1 + 96, *a2, a2[1], (char *)&v10 + 1);
*(_QWORD *)(a1 + 120) = a3;
*(_OWORD *)(a1 + 128) = 0LL;
*(_QWORD *)(a1 + 144) = a1 + 160;
result = std::string::_M_construct<char *>((_QWORD *)(a1 + 144), *(_BYTE **)a4, *(_QWORD *)a4 + *(_QWORD *)(a4 + 8));
*(_BYTE *)(a1 + 176) = 0;
*(_OWORD *)(a1 + 184) = 0LL;
*(_QWORD *)(a1 + 200) = 0LL;
*(_QWORD *)(a1 + 208) = a5;
return result;
}
| common_arg:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R14,R8
MOV R15,RCX
MOV R12,RDX
MOV RBP,RSI
MOV RBX,RDI
LEA RSI,[RSP + 0x4]
MOV dword ptr [RSI],0x0
LEA RCX,[RSP + 0x3]
LEA R8,[RSP + 0x2]
MOV EDX,0x1
CALL 0x001d8a46
LEA RAX,[RBX + 0x38]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x40],XMM0
MOVUPS xmmword ptr [RBX + 0x50],XMM0
MOVUPS xmmword ptr [RBX + 0x30],XMM0
MOV qword ptr [RBX + 0x48],RAX
MOV qword ptr [RBX + 0x50],RAX
MOV qword ptr [RBX + 0x58],0x0
LEA R13,[RBX + 0x60]
MOV RSI,qword ptr [RBP]
MOV RDX,qword ptr [RBP + 0x8]
LAB_001d7af4:
LEA RCX,[RSP + 0x1]
MOV RDI,R13
CALL 0x001d8ac8
MOV qword ptr [RBX + 0x78],R12
LEA RDI,[RBX + 0x90]
LEA RAX,[RBX + 0xa0]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x80],XMM0
MOV qword ptr [RBX + 0x90],RAX
MOV RSI,qword ptr [R15]
MOV RDX,qword ptr [R15 + 0x8]
ADD RDX,RSI
LAB_001d7b2e:
CALL 0x0014d38c
LAB_001d7b33:
MOV byte ptr [RBX + 0xb0],0x0
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0xb8],XMM0
MOV qword ptr [RBX + 0xc8],0x0
MOV qword ptr [RBX + 0xd0],R14
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* common_arg::common_arg(std::initializer_list<char const*> const&, char const*,
std::__cxx11::string const&, void (*)(common_params&, int)) */
void __thiscall
common_arg::common_arg
(common_arg *this,initializer_list *param_1,char *param_2,string *param_3,
_func_void_common_params_ptr_int *param_4)
{
int4 in_EAX;
int8 in_R9;
std::set<llama_example,std::less<llama_example>,std::allocator<llama_example>>::set
(this,&stack0xffffffffffffffcc,1,&stack0xffffffffffffffcb,&stack0xffffffffffffffca,in_R9
,in_EAX);
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
*(int8 *)(this + 0x50) = 0;
*(int8 *)(this + 0x58) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(common_arg **)(this + 0x48) = this + 0x38;
*(common_arg **)(this + 0x50) = this + 0x38;
*(int8 *)(this + 0x58) = 0;
/* try { // try from 001d7af4 to 001d7b00 has its CatchHandler @ 001d7b7f */
std::vector<char_const*,std::allocator<char_const*>>::vector
((vector<char_const*,std::allocator<char_const*>> *)(this + 0x60),*(int8 *)param_1
,*(int8 *)(param_1 + 8),&stack0xffffffffffffffc9);
*(char **)(this + 0x78) = param_2;
*(int8 *)(this + 0x80) = 0;
*(int8 *)(this + 0x88) = 0;
*(common_arg **)(this + 0x90) = this + 0xa0;
/* try { // try from 001d7b2e to 001d7b32 has its CatchHandler @ 001d7b65 */
std::__cxx11::string::_M_construct<char*>
(this + 0x90,*(long *)param_3,*(long *)(param_3 + 8) + *(long *)param_3);
this[0xb0] = (common_arg)0x0;
*(int8 *)(this + 0xb8) = 0;
*(int8 *)(this + 0xc0) = 0;
*(int8 *)(this + 200) = 0;
*(_func_void_common_params_ptr_int **)(this + 0xd0) = param_4;
return;
}
| |
21,473 | common_arg::common_arg(std::initializer_list<char const*> const&, char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, void (*)(common_params&, int)) | monkey531[P]llama/common/arg.h | common_arg(
const std::initializer_list<const char *> & args,
const char * value_hint,
const std::string & help,
void (*handler)(common_params & params, int)
) : args(args), value_hint(value_hint), help(help), handler_int(handler) {} | O2 | c | common_arg::common_arg(std::initializer_list<char const*> const&, char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, void (*)(common_params&, int)):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r8, %r14
movq %rcx, %r15
movq %rdx, %r12
movq %rsi, %rbp
movq %rdi, %rbx
leaq 0x4(%rsp), %rsi
andl $0x0, (%rsi)
pushq $0x1
popq %rdx
leaq 0x3(%rsp), %rcx
leaq 0x2(%rsp), %r8
callq 0x9f488
leaq 0x38(%rbx), %rax
xorps %xmm0, %xmm0
movups %xmm0, 0x30(%rbx)
andq $0x0, 0x40(%rbx)
movq %rax, 0x48(%rbx)
movq %rax, 0x50(%rbx)
andq $0x0, 0x58(%rbx)
leaq 0x60(%rbx), %r13
movq (%rbp), %rsi
movq 0x8(%rbp), %rdx
leaq 0x1(%rsp), %rcx
movq %r13, %rdi
callq 0x9f4ce
movq %r12, 0x78(%rbx)
leaq 0x90(%rbx), %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x80(%rbx)
movq %r15, %rsi
callq 0x28f50
movb $0x0, 0xb0(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0xb8(%rbx)
andq $0x0, 0xc8(%rbx)
movq %r14, 0xd0(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %r13, %rdi
callq 0x9f80a
jmp 0x9e620
movq %rax, %r14
leaq 0x30(%rbx), %rdi
callq 0x9f552
movq %rbx, %rdi
callq 0x9f552
movq %r14, %rdi
callq 0x293c0
nop
| _ZN10common_argC2ERKSt16initializer_listIPKcES2_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPFvR13common_paramsiE:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r14, r8
mov r15, rcx
mov r12, rdx
mov rbp, rsi
mov rbx, rdi
lea rsi, [rsp+38h+var_34]
and dword ptr [rsi], 0
push 1
pop rdx
lea rcx, [rsp+38h+var_35]
lea r8, [rsp+38h+var_36]
call _ZNSt3setI13llama_exampleSt4lessIS0_ESaIS0_EEC2ESt16initializer_listIS0_ERKS2_RKS3_; std::set<llama_example>::set(std::initializer_list<llama_example>,std::less<llama_example> const&,std::allocator<llama_example> const&)
lea rax, [rbx+38h]
xorps xmm0, xmm0
movups xmmword ptr [rbx+30h], xmm0
and qword ptr [rbx+40h], 0
mov [rbx+48h], rax
mov [rbx+50h], rax
and qword ptr [rbx+58h], 0
lea r13, [rbx+60h]
mov rsi, [rbp+0]
mov rdx, [rbp+8]
lea rcx, [rsp+38h+var_37]
mov rdi, r13
call _ZNSt6vectorIPKcSaIS1_EEC2ESt16initializer_listIS1_ERKS2_; std::vector<char const*>::vector(std::initializer_list<char const*>,std::allocator<char const*> const&)
mov [rbx+78h], r12
lea rdi, [rbx+90h]
xorps xmm0, xmm0
movups xmmword ptr [rbx+80h], xmm0
mov rsi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2ERKS4_; std::string::basic_string(std::string const&)
mov byte ptr [rbx+0B0h], 0
xorps xmm0, xmm0
movups xmmword ptr [rbx+0B8h], xmm0
and qword ptr [rbx+0C8h], 0
mov [rbx+0D0h], r14
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r14, rax
mov rdi, r13
call _ZNSt12_Vector_baseIPKcSaIS1_EED2Ev; std::_Vector_base<char const*>::~_Vector_base()
jmp short loc_9E620
mov r14, rax
loc_9E620:
lea rdi, [rbx+30h]
call _ZNSt8_Rb_treeI13llama_exampleS0_St9_IdentityIS0_ESt4lessIS0_ESaIS0_EED2Ev; std::_Rb_tree<llama_example,llama_example,std::_Identity<llama_example>,std::less<llama_example>,std::allocator<llama_example>>::~_Rb_tree()
mov rdi, rbx
call _ZNSt8_Rb_treeI13llama_exampleS0_St9_IdentityIS0_ESt4lessIS0_ESaIS0_EED2Ev; std::_Rb_tree<llama_example,llama_example,std::_Identity<llama_example>,std::less<llama_example>,std::allocator<llama_example>>::~_Rb_tree()
mov rdi, r14
call __Unwind_Resume
| long long common_arg::common_arg(long long a1, _QWORD *a2, long long a3, long long a4, long long a5)
{
int v5; // eax
long long result; // rax
int v10; // [rsp+0h] [rbp-38h] BYREF
_DWORD v11[13]; // [rsp+4h] [rbp-34h] BYREF
v10 = v5;
v11[0] = 0;
std::set<llama_example>::set(a1, v11, 1LL, (char *)&v10 + 3, (char *)&v10 + 2);
*(_OWORD *)(a1 + 48) = 0LL;
*(_QWORD *)(a1 + 64) = 0LL;
*(_QWORD *)(a1 + 72) = a1 + 56;
*(_QWORD *)(a1 + 80) = a1 + 56;
*(_QWORD *)(a1 + 88) = 0LL;
std::vector<char const*>::vector(a1 + 96, *a2, a2[1], (char *)&v10 + 1);
*(_QWORD *)(a1 + 120) = a3;
*(_OWORD *)(a1 + 128) = 0LL;
result = std::string::basic_string(a1 + 144, a4);
*(_BYTE *)(a1 + 176) = 0;
*(_OWORD *)(a1 + 184) = 0LL;
*(_QWORD *)(a1 + 200) = 0LL;
*(_QWORD *)(a1 + 208) = a5;
return result;
}
| common_arg:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R14,R8
MOV R15,RCX
MOV R12,RDX
MOV RBP,RSI
MOV RBX,RDI
LEA RSI,[RSP + 0x4]
AND dword ptr [RSI],0x0
PUSH 0x1
POP RDX
LEA RCX,[RSP + 0x3]
LEA R8,[RSP + 0x2]
CALL 0x0019f488
LEA RAX,[RBX + 0x38]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x30],XMM0
AND qword ptr [RBX + 0x40],0x0
MOV qword ptr [RBX + 0x48],RAX
MOV qword ptr [RBX + 0x50],RAX
AND qword ptr [RBX + 0x58],0x0
LEA R13,[RBX + 0x60]
MOV RSI,qword ptr [RBP]
MOV RDX,qword ptr [RBP + 0x8]
LAB_0019e5b7:
LEA RCX,[RSP + 0x1]
MOV RDI,R13
CALL 0x0019f4ce
MOV qword ptr [RBX + 0x78],R12
LEA RDI,[RBX + 0x90]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x80],XMM0
LAB_0019e5d9:
MOV RSI,R15
CALL 0x00128f50
LAB_0019e5e1:
MOV byte ptr [RBX + 0xb0],0x0
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0xb8],XMM0
AND qword ptr [RBX + 0xc8],0x0
MOV qword ptr [RBX + 0xd0],R14
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* common_arg::common_arg(std::initializer_list<char const*> const&, char const*,
std::__cxx11::string const&, void (*)(common_params&, int)) */
void __thiscall
common_arg::common_arg
(common_arg *this,initializer_list *param_1,char *param_2,string *param_3,
_func_void_common_params_ptr_int *param_4)
{
int4 in_EAX;
int8 in_R9;
std::set<llama_example,std::less<llama_example>,std::allocator<llama_example>>::set
(this,&stack0xffffffffffffffcc,1,&stack0xffffffffffffffcb,&stack0xffffffffffffffca,in_R9
,in_EAX);
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(common_arg **)(this + 0x48) = this + 0x38;
*(common_arg **)(this + 0x50) = this + 0x38;
*(int8 *)(this + 0x58) = 0;
/* try { // try from 0019e5b7 to 0019e5c3 has its CatchHandler @ 0019e61d */
std::vector<char_const*,std::allocator<char_const*>>::vector
((vector<char_const*,std::allocator<char_const*>> *)(this + 0x60),*(int8 *)param_1
,*(int8 *)(param_1 + 8),&stack0xffffffffffffffc9);
*(char **)(this + 0x78) = param_2;
*(int8 *)(this + 0x80) = 0;
*(int8 *)(this + 0x88) = 0;
/* try { // try from 0019e5d9 to 0019e5e0 has its CatchHandler @ 0019e610 */
std::__cxx11::string::string((string *)(this + 0x90),param_3);
this[0xb0] = (common_arg)0x0;
*(int8 *)(this + 0xb8) = 0;
*(int8 *)(this + 0xc0) = 0;
*(int8 *)(this + 200) = 0;
*(_func_void_common_params_ptr_int **)(this + 0xd0) = param_4;
return;
}
| |
21,474 | gguf_kv::gguf_kv<unsigned char>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::vector<unsigned char, std::allocator<unsigned char>> const&) | llama.cpp/ggml/src/gguf.cpp | gguf_kv(const std::string & key, const std::vector<T> & value)
: key(key), is_array(true), type(type_to_gguf_type<T>::value) {
GGML_ASSERT(!key.empty());
data.resize(value.size()*sizeof(T));
for (size_t i = 0; i < value.size(); ++i) {
const T tmp = value[i];
memcpy(data.data() + i*sizeof(T), &tmp, sizeof(T));
}
} | O3 | cpp | gguf_kv::gguf_kv<unsigned char>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::vector<unsigned char, std::allocator<unsigned char>> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r12
movq %rsi, %rbp
movq %rdi, %r14
leaq 0x10(%rdi), %rbx
movq %rbx, (%rdi)
movq (%rsi), %rsi
movq 0x8(%rbp), %rdx
addq %rsi, %rdx
callq 0x165f0
movb $0x1, 0x20(%r14)
movl $0x1, 0x24(%r14)
leaq 0x28(%r14), %r15
leaq 0x40(%r14), %r13
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%r14)
movups %xmm0, 0x38(%r14)
movups %xmm0, 0x48(%r14)
cmpq $0x0, 0x8(%rbp)
je 0x42df6
movq 0x8(%r12), %rsi
subq (%r12), %rsi
movq %r15, %rdi
callq 0x16110
movq (%r12), %rax
cmpq %rax, 0x8(%r12)
je 0x42de7
xorl %ecx, %ecx
movb (%rax,%rcx), %al
movq (%r15), %rdx
movb %al, (%rdx,%rcx)
incq %rcx
movq (%r12), %rax
movq 0x8(%r12), %rdx
subq %rax, %rdx
cmpq %rdx, %rcx
jb 0x42dca
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x16f48(%rip), %rdi # 0x59d45
leaq 0x784a(%rip), %rdx # 0x4a64e
leaq 0x176da(%rip), %rcx # 0x5a4e5
movl $0x8c, %esi
xorl %eax, %eax
callq 0x17c80
movq %rax, %r12
movq %r13, %rdi
callq 0x16c30
movq (%r15), %rdi
testq %rdi, %rdi
je 0x42e36
movq 0x38(%r14), %rsi
subq %rdi, %rsi
callq 0x17080
movq %r14, %rdi
movq %rbx, %rsi
callq 0x1884f
movq %r12, %rdi
callq 0x17e50
nop
| _ZN7gguf_kvC2IaEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIT_SaISA_EE:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r12, rdx
mov rbp, rsi
mov r14, rdi
lea rbx, [rdi+10h]
mov [rdi], rbx
mov rsi, [rsi]
mov rdx, [rbp+8]
add rdx, rsi
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
mov byte ptr [r14+20h], 1
mov dword ptr [r14+24h], 1
lea r15, [r14+28h]
lea r13, [r14+40h]
xorps xmm0, xmm0
movups xmmword ptr [r14+28h], xmm0
movups xmmword ptr [r14+38h], xmm0
movups xmmword ptr [r14+48h], xmm0
cmp qword ptr [rbp+8], 0
jz short loc_42DF6
mov rsi, [r12+8]
sub rsi, [r12]
mov rdi, r15
call __ZNSt6vectorIaSaIaEE6resizeEm; std::vector<signed char>::resize(ulong)
mov rax, [r12]
cmp [r12+8], rax
jz short loc_42DE7
xor ecx, ecx
loc_42DCA:
mov al, [rax+rcx]
mov rdx, [r15]
mov [rdx+rcx], al
inc rcx
mov rax, [r12]
mov rdx, [r12+8]
sub rdx, rax
cmp rcx, rdx
jb short loc_42DCA
loc_42DE7:
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_42DF6:
lea rdi, aWorkspaceLlm4b_5; "/workspace/llm4binary/github2025/llama."...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aKeyEmpty; "!key.empty()"
mov esi, 8Ch
xor eax, eax
call _ggml_abort
mov r12, rax
mov rdi, r13
call __ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, [r15]; void *
test rdi, rdi
jz short loc_42E36
mov rsi, [r14+38h]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_42E36:
mov rdi, r14
mov rsi, rbx
call _ZN7gguf_kvC2IaEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIT_SaISA_EE_cold_1; gguf_kv::gguf_kv<signed char>(std::string const&,std::vector<signed char> const&) [clone]
mov rdi, r12
call __Unwind_Resume
| long long gguf_kv::gguf_kv<signed char>(long long a1, _QWORD *a2, long long *a3)
{
int v4; // r8d
int v5; // r9d
long long result; // rax
unsigned long long v7; // rcx
*(_QWORD *)a1 = a1 + 16;
std::string::_M_construct<char *>(a1, *a2, *a2 + a2[1]);
*(_BYTE *)(a1 + 32) = 1;
*(_DWORD *)(a1 + 36) = 1;
*(_OWORD *)(a1 + 40) = 0LL;
*(_OWORD *)(a1 + 56) = 0LL;
*(_OWORD *)(a1 + 72) = 0LL;
if ( !a2[1] )
ggml_abort(
(unsigned int)"/workspace/llm4binary/github2025/llama.cpp/ggml/src/gguf.cpp",
140,
(unsigned int)"GGML_ASSERT(%s) failed",
(unsigned int)"!key.empty()",
v4,
v5);
std::vector<signed char>::resize(a1 + 40, a3[1] - *a3);
result = *a3;
if ( a3[1] != *a3 )
{
v7 = 0LL;
do
{
*(_BYTE *)(*(_QWORD *)(a1 + 40) + v7) = *(_BYTE *)(result + v7);
++v7;
result = *a3;
}
while ( v7 < a3[1] - *a3 );
}
return result;
}
| gguf_kv<signed_char>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R12,RDX
MOV RBP,RSI
MOV R14,RDI
LEA RBX,[RDI + 0x10]
MOV qword ptr [RDI],RBX
MOV RSI,qword ptr [RSI]
MOV RDX,qword ptr [RBP + 0x8]
ADD RDX,RSI
CALL 0x001165f0
MOV byte ptr [R14 + 0x20],0x1
MOV dword ptr [R14 + 0x24],0x1
LEA R15,[R14 + 0x28]
LEA R13,[R14 + 0x40]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R14 + 0x28],XMM0
MOVUPS xmmword ptr [R14 + 0x38],XMM0
MOVUPS xmmword ptr [R14 + 0x48],XMM0
CMP qword ptr [RBP + 0x8],0x0
JZ 0x00142df6
MOV RSI,qword ptr [R12 + 0x8]
SUB RSI,qword ptr [R12]
LAB_00142db5:
MOV RDI,R15
CALL 0x00116110
MOV RAX,qword ptr [R12]
CMP qword ptr [R12 + 0x8],RAX
JZ 0x00142de7
XOR ECX,ECX
LAB_00142dca:
MOV AL,byte ptr [RAX + RCX*0x1]
MOV RDX,qword ptr [R15]
MOV byte ptr [RDX + RCX*0x1],AL
INC RCX
MOV RAX,qword ptr [R12]
MOV RDX,qword ptr [R12 + 0x8]
SUB RDX,RAX
CMP RCX,RDX
JC 0x00142dca
LAB_00142de7:
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00142df6:
LEA RDI,[0x159d45]
LEA RDX,[0x14a64e]
LEA RCX,[0x15a4e5]
MOV ESI,0x8c
XOR EAX,EAX
CALL 0x00117c80
|
/* gguf_kv::gguf_kv<signed char>(std::__cxx11::string const&, std::vector<signed char,
std::allocator<signed char> > const&) */
void __thiscall gguf_kv::gguf_kv<signed_char>(gguf_kv *this,string *param_1,vector *param_2)
{
long lVar1;
ulong uVar2;
*(gguf_kv **)this = this + 0x10;
std::__cxx11::string::_M_construct<char*>
(this,*(long *)param_1,*(long *)(param_1 + 8) + *(long *)param_1);
this[0x20] = (gguf_kv)0x1;
*(int4 *)(this + 0x24) = 1;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
*(int8 *)(this + 0x50) = 0;
if (*(long *)(param_1 + 8) != 0) {
/* try { // try from 00142db5 to 00142e16 has its CatchHandler @ 00142e17 */
std::vector<signed_char,std::allocator<signed_char>>::resize
((vector<signed_char,std::allocator<signed_char>> *)(this + 0x28),
*(long *)(param_2 + 8) - *(long *)param_2);
lVar1 = *(long *)param_2;
if (*(long *)(param_2 + 8) != lVar1) {
uVar2 = 0;
do {
*(int1 *)(*(long *)(this + 0x28) + uVar2) = *(int1 *)(lVar1 + uVar2);
uVar2 = uVar2 + 1;
lVar1 = *(long *)param_2;
} while (uVar2 < (ulong)(*(long *)(param_2 + 8) - lVar1));
}
return;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github2025/llama.cpp/ggml/src/gguf.cpp",0x8c,
"GGML_ASSERT(%s) failed","!key.empty()");
}
| |
21,475 | ggml_gallocr_init_tensor | ngxson[P]ggml-easy/ggml/src/ggml-alloc.c | static void ggml_gallocr_init_tensor(ggml_gallocr_t galloc, struct ggml_tensor * tensor, struct tensor_alloc * tensor_alloc) {
int buffer_id = tensor_alloc->buffer_id;
assert(tensor->data || tensor->view_src || ggml_backend_buffer_get_alloc_size(galloc->buffers[buffer_id], tensor) <= tensor_alloc->size_max);
if (tensor->view_src != NULL) {
if (tensor->buffer == NULL) {
assert(tensor_alloc->offset == SIZE_MAX);
if (tensor->view_src->buffer == NULL) {
// this tensor was allocated without ggml-backend
return;
}
ggml_backend_view_init(tensor);
}
} else {
if (tensor->data == NULL) {
assert(tensor_alloc->offset != SIZE_MAX);
assert(ggml_backend_buffer_get_alloc_size(galloc->buffers[buffer_id], tensor) <= tensor_alloc->size_max);
void * base = ggml_backend_buffer_get_base(galloc->buffers[buffer_id]);
void * addr = (char *)base + tensor_alloc->offset;
ggml_backend_tensor_alloc(galloc->buffers[buffer_id], tensor, addr);
} else {
if (tensor->buffer == NULL) {
// this tensor was allocated without ggml-backend
return;
}
}
}
} | O0 | c | ggml_gallocr_init_tensor:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x20(%rsp)
movq 0x20(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x1c(%rsp)
movq 0x28(%rsp), %rax
cmpq $0x0, 0xe8(%rax)
je 0x5c56a
movq 0x28(%rsp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x5c568
movq 0x28(%rsp), %rax
movq 0xe8(%rax), %rax
cmpq $0x0, 0x8(%rax)
jne 0x5c55e
jmp 0x5c5dd
movq 0x28(%rsp), %rdi
callq 0x45910
jmp 0x5c5dd
movq 0x28(%rsp), %rax
cmpq $0x0, 0xf8(%rax)
jne 0x5c5cb
movq 0x30(%rsp), %rax
movq 0x8(%rax), %rax
movslq 0x1c(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x44ca0
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
movq 0x20(%rsp), %rcx
addq 0x8(%rcx), %rax
movq %rax, 0x8(%rsp)
movq 0x30(%rsp), %rax
movq 0x8(%rax), %rax
movslq 0x1c(%rsp), %rcx
movq (%rax,%rcx,8), %rdi
movq 0x28(%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0x453e0
jmp 0x5c5db
movq 0x28(%rsp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x5c5d9
jmp 0x5c5dd
jmp 0x5c5db
jmp 0x5c5dd
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
| ggml_gallocr_init_tensor:
sub rsp, 38h
mov [rsp+38h+var_8], rdi
mov [rsp+38h+var_10], rsi
mov [rsp+38h+var_18], rdx
mov rax, [rsp+38h+var_18]
mov eax, [rax]
mov [rsp+38h+var_1C], eax
mov rax, [rsp+38h+var_10]
cmp qword ptr [rax+0E8h], 0
jz short loc_5C56A
mov rax, [rsp+38h+var_10]
cmp qword ptr [rax+8], 0
jnz short loc_5C568
mov rax, [rsp+38h+var_10]
mov rax, [rax+0E8h]
cmp qword ptr [rax+8], 0
jnz short loc_5C55E
jmp short loc_5C5DD
loc_5C55E:
mov rdi, [rsp+38h+var_10]
call _ggml_backend_view_init
loc_5C568:
jmp short loc_5C5DD
loc_5C56A:
mov rax, [rsp+38h+var_10]
cmp qword ptr [rax+0F8h], 0
jnz short loc_5C5CB
mov rax, [rsp+38h+var_8]
mov rax, [rax+8]
movsxd rcx, [rsp+38h+var_1C]
mov rdi, [rax+rcx*8]
call _ggml_backend_buffer_get_base
mov [rsp+38h+var_28], rax
mov rax, [rsp+38h+var_28]
mov rcx, [rsp+38h+var_18]
add rax, [rcx+8]
mov [rsp+38h+var_30], rax
mov rax, [rsp+38h+var_8]
mov rax, [rax+8]
movsxd rcx, [rsp+38h+var_1C]
mov rdi, [rax+rcx*8]
mov rsi, [rsp+38h+var_10]
mov rdx, [rsp+38h+var_30]
call _ggml_backend_tensor_alloc
jmp short loc_5C5DB
loc_5C5CB:
mov rax, [rsp+38h+var_10]
cmp qword ptr [rax+8], 0
jnz short loc_5C5D9
jmp short loc_5C5DD
loc_5C5D9:
jmp short $+2
loc_5C5DB:
jmp short $+2
loc_5C5DD:
add rsp, 38h
retn
| long long ggml_gallocr_init_tensor(long long a1, _QWORD *a2, int *a3)
{
long long result; // rax
long long base; // [rsp+10h] [rbp-28h]
int v5; // [rsp+1Ch] [rbp-1Ch]
v5 = *a3;
if ( a2[29] )
{
result = (long long)a2;
if ( !a2[1] )
{
result = a2[29];
if ( *(_QWORD *)(result + 8) )
return ggml_backend_view_init(a2);
}
}
else if ( a2[31] )
{
return (long long)a2;
}
else
{
base = ggml_backend_buffer_get_base(*(_QWORD *)(*(_QWORD *)(a1 + 8) + 8LL * v5));
return ggml_backend_tensor_alloc(*(_QWORD *)(*(_QWORD *)(a1 + 8) + 8LL * v5), a2, *((_QWORD *)a3 + 1) + base);
}
return result;
}
| ggml_gallocr_init_tensor:
SUB RSP,0x38
MOV qword ptr [RSP + 0x30],RDI
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x20],RDX
MOV RAX,qword ptr [RSP + 0x20]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RSP + 0x1c],EAX
MOV RAX,qword ptr [RSP + 0x28]
CMP qword ptr [RAX + 0xe8],0x0
JZ 0x0015c56a
MOV RAX,qword ptr [RSP + 0x28]
CMP qword ptr [RAX + 0x8],0x0
JNZ 0x0015c568
MOV RAX,qword ptr [RSP + 0x28]
MOV RAX,qword ptr [RAX + 0xe8]
CMP qword ptr [RAX + 0x8],0x0
JNZ 0x0015c55e
JMP 0x0015c5dd
LAB_0015c55e:
MOV RDI,qword ptr [RSP + 0x28]
CALL 0x00145910
LAB_0015c568:
JMP 0x0015c5dd
LAB_0015c56a:
MOV RAX,qword ptr [RSP + 0x28]
CMP qword ptr [RAX + 0xf8],0x0
JNZ 0x0015c5cb
MOV RAX,qword ptr [RSP + 0x30]
MOV RAX,qword ptr [RAX + 0x8]
MOVSXD RCX,dword ptr [RSP + 0x1c]
MOV RDI,qword ptr [RAX + RCX*0x8]
CALL 0x00144ca0
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV RCX,qword ptr [RSP + 0x20]
ADD RAX,qword ptr [RCX + 0x8]
MOV qword ptr [RSP + 0x8],RAX
MOV RAX,qword ptr [RSP + 0x30]
MOV RAX,qword ptr [RAX + 0x8]
MOVSXD RCX,dword ptr [RSP + 0x1c]
MOV RDI,qword ptr [RAX + RCX*0x8]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,qword ptr [RSP + 0x8]
CALL 0x001453e0
JMP 0x0015c5db
LAB_0015c5cb:
MOV RAX,qword ptr [RSP + 0x28]
CMP qword ptr [RAX + 0x8],0x0
JNZ 0x0015c5d9
JMP 0x0015c5dd
LAB_0015c5d9:
JMP 0x0015c5db
LAB_0015c5db:
JMP 0x0015c5dd
LAB_0015c5dd:
ADD RSP,0x38
RET
|
void ggml_gallocr_init_tensor(long param_1,long param_2,int *param_3)
{
int iVar1;
long lVar2;
iVar1 = *param_3;
if (*(long *)(param_2 + 0xe8) == 0) {
if (*(long *)(param_2 + 0xf8) == 0) {
lVar2 = ggml_backend_buffer_get_base
(*(int8 *)(*(long *)(param_1 + 8) + (long)iVar1 * 8));
ggml_backend_tensor_alloc
(*(int8 *)(*(long *)(param_1 + 8) + (long)iVar1 * 8),param_2,
lVar2 + *(long *)(param_3 + 2));
}
}
else if ((*(long *)(param_2 + 8) == 0) && (*(long *)(*(long *)(param_2 + 0xe8) + 8) != 0)) {
ggml_backend_view_init(param_2);
}
return;
}
| |
21,476 | ggml_gallocr_init_tensor | ngxson[P]ggml-easy/ggml/src/ggml-alloc.c | static void ggml_gallocr_init_tensor(ggml_gallocr_t galloc, struct ggml_tensor * tensor, struct tensor_alloc * tensor_alloc) {
int buffer_id = tensor_alloc->buffer_id;
assert(tensor->data || tensor->view_src || ggml_backend_buffer_get_alloc_size(galloc->buffers[buffer_id], tensor) <= tensor_alloc->size_max);
if (tensor->view_src != NULL) {
if (tensor->buffer == NULL) {
assert(tensor_alloc->offset == SIZE_MAX);
if (tensor->view_src->buffer == NULL) {
// this tensor was allocated without ggml-backend
return;
}
ggml_backend_view_init(tensor);
}
} else {
if (tensor->data == NULL) {
assert(tensor_alloc->offset != SIZE_MAX);
assert(ggml_backend_buffer_get_alloc_size(galloc->buffers[buffer_id], tensor) <= tensor_alloc->size_max);
void * base = ggml_backend_buffer_get_base(galloc->buffers[buffer_id]);
void * addr = (char *)base + tensor_alloc->offset;
ggml_backend_tensor_alloc(galloc->buffers[buffer_id], tensor, addr);
} else {
if (tensor->buffer == NULL) {
// this tensor was allocated without ggml-backend
return;
}
}
}
} | O2 | c | ggml_gallocr_init_tensor:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq 0xe8(%rsi), %rax
testq %rax, %rax
je 0x29b37
cmpq $0x0, 0x8(%rbx)
jne 0x29b41
cmpq $0x0, 0x8(%rax)
je 0x29b41
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x1e230
cmpq $0x0, 0xf8(%rbx)
je 0x29b4d
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rdx, %r14
movq %rdi, %r15
movslq (%rdx), %r12
movq 0x8(%rdi), %rax
movq (%rax,%r12,8), %rdi
callq 0x1dce0
addq 0x8(%r14), %rax
movq 0x8(%r15), %rcx
movq (%rcx,%r12,8), %rdi
movq %rbx, %rsi
movq %rax, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x1dff0
| ggml_gallocr_init_tensor:
push r15
push r14
push r12
push rbx
push rax
mov rbx, rsi
mov rax, [rsi+0E8h]
test rax, rax
jz short loc_29B37
cmp qword ptr [rbx+8], 0
jnz short loc_29B41
cmp qword ptr [rax+8], 0
jz short loc_29B41
mov rdi, rbx
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
jmp _ggml_backend_view_init
loc_29B37:
cmp qword ptr [rbx+0F8h], 0
jz short loc_29B4D
loc_29B41:
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
loc_29B4D:
mov r14, rdx
mov r15, rdi
movsxd r12, dword ptr [rdx]
mov rax, [rdi+8]
mov rdi, [rax+r12*8]
call _ggml_backend_buffer_get_base
add rax, [r14+8]
mov rcx, [r15+8]
mov rdi, [rcx+r12*8]
mov rsi, rbx
mov rdx, rax
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
jmp _ggml_backend_tensor_alloc
| long long ggml_gallocr_init_tensor(long long a1, _QWORD *a2, int *a3)
{
long long result; // rax
long long v5; // r12
long long base; // rax
result = a2[29];
if ( result )
{
if ( !a2[1] )
{
if ( *(_QWORD *)(result + 8) )
return ggml_backend_view_init(a2);
}
}
else if ( !a2[31] )
{
v5 = *a3;
base = ggml_backend_buffer_get_base(*(_QWORD *)(*(_QWORD *)(a1 + 8) + 8 * v5));
return ggml_backend_tensor_alloc(*(_QWORD *)(*(_QWORD *)(a1 + 8) + 8 * v5), a2, *((_QWORD *)a3 + 1) + base);
}
return result;
}
| ggml_gallocr_init_tensor:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV RAX,qword ptr [RSI + 0xe8]
TEST RAX,RAX
JZ 0x00129b37
CMP qword ptr [RBX + 0x8],0x0
JNZ 0x00129b41
CMP qword ptr [RAX + 0x8],0x0
JZ 0x00129b41
MOV RDI,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
JMP 0x0011e230
LAB_00129b37:
CMP qword ptr [RBX + 0xf8],0x0
JZ 0x00129b4d
LAB_00129b41:
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
LAB_00129b4d:
MOV R14,RDX
MOV R15,RDI
MOVSXD R12,dword ptr [RDX]
MOV RAX,qword ptr [RDI + 0x8]
MOV RDI,qword ptr [RAX + R12*0x8]
CALL 0x0011dce0
ADD RAX,qword ptr [R14 + 0x8]
MOV RCX,qword ptr [R15 + 0x8]
MOV RDI,qword ptr [RCX + R12*0x8]
MOV RSI,RBX
MOV RDX,RAX
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
JMP 0x0011dff0
|
void ggml_gallocr_init_tensor(long param_1,long param_2,int *param_3)
{
int iVar1;
long lVar2;
if (*(long *)(param_2 + 0xe8) == 0) {
if (*(long *)(param_2 + 0xf8) == 0) {
iVar1 = *param_3;
lVar2 = ggml_backend_buffer_get_base
(*(int8 *)(*(long *)(param_1 + 8) + (long)iVar1 * 8));
ggml_backend_tensor_alloc
(*(int8 *)(*(long *)(param_1 + 8) + (long)iVar1 * 8),param_2,
lVar2 + *(long *)(param_3 + 2));
return;
}
}
else if ((*(long *)(param_2 + 8) == 0) && (*(long *)(*(long *)(param_2 + 0xe8) + 8) != 0)) {
ggml_backend_view_init(param_2);
return;
}
return;
}
| |
21,477 | HKDF_Extract | corpus-core[P]colibri-stateless/build_O1/_deps/blst-src/src/keygen.c | static void HKDF_Extract(unsigned char PRK[32],
const void *salt, size_t salt_len,
const void *IKM, size_t IKM_len,
#ifndef __BLST_HKDF_TESTMODE__
int IKM_fixup,
#endif
HMAC_SHA256_CTX *ctx)
{
unsigned char zero[1] = { 0 };
HMAC_init(ctx, salt != NULL ? salt : zero, salt_len);
HMAC_update(ctx, IKM, IKM_len);
#ifndef __BLST_HKDF_TESTMODE__
if (IKM_fixup) {
/* Section 2.3 KeyGen in BLS-signature draft */
HMAC_update(ctx, zero, 1);
}
#endif
HMAC_final(PRK, ctx);
} | O1 | c | HKDF_Extract:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, %r15d
movq %r8, %r12
movq %rcx, %r13
movq %rdi, %rbx
movq 0x10(%rbp), %r14
leaq -0x29(%rbp), %rax
movb $0x0, (%rax)
testq %rsi, %rsi
cmoveq %rax, %rsi
movq %r14, %rdi
callq 0x263da
movq %r14, %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x25cca
testl %r15d, %r15d
je 0x2625b
leaq -0x29(%rbp), %rsi
movl $0x1, %edx
movq %r14, %rdi
callq 0x25cca
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2658c
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| HKDF_Extract:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r15d, r9d
mov r12, r8
mov r13, rcx
mov rbx, rdi
mov r14, [rbp+arg_0]
lea rax, [rbp+var_29]
mov byte ptr [rax], 0
test rsi, rsi
cmovz rsi, rax
mov rdi, r14
call HMAC_init
mov rdi, r14
mov rsi, r13
mov rdx, r12
call sha256_update
test r15d, r15d
jz short loc_2625B
lea rsi, [rbp+var_29]
mov edx, 1
mov rdi, r14
call sha256_update
loc_2625B:
mov rdi, rbx
mov rsi, r14
call HMAC_final
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long HKDF_Extract(long long a1, _BYTE *a2, long long a3, long long a4, long long a5, int a6, long long a7)
{
_BYTE v11[41]; // [rsp+1h] [rbp-29h] BYREF
v11[0] = 0;
if ( !a2 )
a2 = v11;
HMAC_init(a7, a2);
sha256_update(a7, a4, a5);
if ( a6 )
sha256_update(a7, v11, 1LL);
return HMAC_final(a1, a7);
}
| HKDF_Extract:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R15D,R9D
MOV R12,R8
MOV R13,RCX
MOV RBX,RDI
MOV R14,qword ptr [RBP + 0x10]
LEA RAX,[RBP + -0x29]
MOV byte ptr [RAX],0x0
TEST RSI,RSI
CMOVZ RSI,RAX
MOV RDI,R14
CALL 0x001263da
MOV RDI,R14
MOV RSI,R13
MOV RDX,R12
CALL 0x00125cca
TEST R15D,R15D
JZ 0x0012625b
LEA RSI,[RBP + -0x29]
MOV EDX,0x1
MOV RDI,R14
CALL 0x00125cca
LAB_0012625b:
MOV RDI,RBX
MOV RSI,R14
CALL 0x0012658c
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void HKDF_Extract(int8 param_1,long param_2,int8 param_3,int8 param_4,
int8 param_5,int param_6,int8 param_7)
{
ulong in_RAX;
int8 uStack_38;
uStack_38 = in_RAX & 0xffffffffffffff;
if (param_2 == 0) {
param_2 = (long)&uStack_38 + 7;
}
HMAC_init(param_7,param_2);
sha256_update(param_7,param_4,param_5);
if (param_6 != 0) {
sha256_update(param_7,(long)&uStack_38 + 7,1);
}
HMAC_final(param_1,param_7);
return;
}
| |
21,478 | string_get_sortable_timestamp[abi:cxx11]() | monkey531[P]llama/common/common.cpp | std::string string_get_sortable_timestamp() {
using clock = std::chrono::system_clock;
const clock::time_point current_time = clock::now();
const time_t as_time_t = clock::to_time_t(current_time);
char timestamp_no_ns[100];
std::strftime(timestamp_no_ns, 100, "%Y_%m_%d-%H_%M_%S", std::localtime(&as_time_t));
const int64_t ns = std::chrono::duration_cast<std::chrono::nanoseconds>(
current_time.time_since_epoch() % 1000000000).count();
char timestamp_ns[11];
snprintf(timestamp_ns, 11, "%09" PRId64, ns);
return std::string(timestamp_no_ns) + "." + std::string(timestamp_ns);
} | O3 | cpp | string_get_sortable_timestamp[abi:cxx11]():
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xf0, %rsp
movq %rdi, %rbx
callq 0x1a090
movq %rax, %r14
movabsq $0x112e0be826d694b3, %rcx # imm = 0x112E0BE826D694B3
imulq %rcx
movq %rdx, %r12
movq %rdx, %rax
shrq $0x3f, %rax
sarq $0x1a, %r12
addq %rax, %r12
leaq 0x78(%rsp), %rdi
movq %r12, (%rdi)
callq 0x1a6b0
leaq 0x7d136(%rip), %rdx # 0xeec87
leaq 0x80(%rsp), %r15
movl $0x64, %esi
movq %r15, %rdi
movq %rax, %rcx
callq 0x1a730
imulq $0x3b9aca00, %r12, %rax # imm = 0x3B9ACA00
subq %rax, %r14
leaq 0x7d11f(%rip), %rdx # 0xeec99
leaq 0x4d(%rsp), %rdi
movl $0xb, %esi
movq %r14, %rcx
xorl %eax, %eax
callq 0x1ae00
leaq 0x68(%rsp), %r12
movq %r12, -0x10(%r12)
movq %r15, %rdi
callq 0x1a400
leaq (%rsp,%rax), %rdx
addq $0x80, %rdx
leaq 0x58(%rsp), %r14
movq %r14, %rdi
movq %r15, %rsi
callq 0x21af4
leaq 0x786df(%rip), %rsi # 0xea2a1
movq %r14, %rdi
callq 0x1b120
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x71bf1
movq %rdx, 0x8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x18(%rsp)
jmp 0x71bf8
movups (%rcx), %xmm0
movups %xmm0, (%r15)
movq 0x8(%rax), %rdx
movq %rdx, 0x10(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x38(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x4d(%rsp), %r14
movq %r14, %rdi
callq 0x1a400
leaq (%rsp,%rax), %rdx
addq $0x4d, %rdx
leaq 0x28(%rsp), %rdi
movq %r14, %rsi
callq 0x21af4
movq 0x8(%rsp), %rcx
movq 0x10(%rsp), %r8
movq 0x30(%rsp), %rdx
leaq (%rdx,%r8), %rax
movl $0xf, %edi
cmpq %r15, %rcx
je 0x71c5d
movq 0x18(%rsp), %rdi
movq 0x28(%rsp), %rsi
cmpq %rdi, %rax
jbe 0x71c7b
movl $0xf, %edi
cmpq %r13, %rsi
je 0x71c76
movq 0x38(%rsp), %rdi
cmpq %rdi, %rax
jbe 0x71c87
leaq 0x8(%rsp), %rdi
callq 0x1a270
jmp 0x71c95
leaq 0x28(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x1a9f0
leaq 0x10(%rbx), %rdx
movq %rdx, (%rbx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x71cb4
movq %rsi, (%rbx)
movq (%rcx), %rdx
movq %rdx, 0x10(%rbx)
jmp 0x71cba
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x8(%rbx)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x71ced
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1a8f0
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x71d04
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a8f0
movq 0x58(%rsp), %rdi
cmpq %r12, %rdi
je 0x71d1b
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x1a8f0
movq %rbx, %rax
addq $0xf0, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x71d4e
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1a8f0
jmp 0x71d4e
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x71d6a
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1a8f0
jmp 0x71d6a
movq %rax, %rbx
movq 0x58(%rsp), %rdi
cmpq %r12, %rdi
je 0x71d81
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x1a8f0
movq %rbx, %rdi
callq 0x1afd0
| _Z29string_get_sortable_timestampB5cxx11v:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0F0h
mov rbx, rdi
call __ZNSt6chrono3_V212system_clock3nowEv; std::chrono::_V2::system_clock::now(void)
mov r14, rax
mov rcx, 112E0BE826D694B3h
imul rcx
mov r12, rdx
mov rax, rdx
shr rax, 3Fh
sar r12, 1Ah
add r12, rax
lea rdi, [rsp+118h+var_A0]
mov [rdi], r12
call _localtime
lea rdx, aYMDHMS; "%Y_%m_%d-%H_%M_%S"
lea r15, [rsp+118h+var_98]
mov esi, 64h ; 'd'
mov rdi, r15
mov rcx, rax
call _strftime
imul rax, r12, 3B9ACA00h
sub r14, rax
lea rdx, a09ld; "%09ld"
lea rdi, [rsp+118h+var_CB]
mov esi, 0Bh
mov rcx, r14
xor eax, eax
call _snprintf
lea r12, [rsp+118h+var_B0]
mov [r12-10h], r12
mov rdi, r15
call _strlen
lea rdx, [rsp+rax+118h+var_118]
add rdx, 80h
lea r14, [rsp+118h+var_C0]
mov rdi, r14
mov rsi, r15
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
lea rsi, aN0N1+8; "."
mov rdi, r14
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea r15, [rsp+118h+var_100]
mov [r15-10h], r15
mov rdx, [rax]
mov rcx, rax
add rcx, 10h
cmp rdx, rcx
jz short loc_71BF1
mov [rsp+118h+var_110], rdx
mov rdx, [rcx]
mov [rsp+118h+var_100], rdx
jmp short loc_71BF8
loc_71BF1:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [r15], xmm0
loc_71BF8:
mov rdx, [rax+8]
mov [rsp+118h+var_108], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
lea r13, [rsp+118h+var_E0]
mov [r13-10h], r13
lea r14, [rsp+118h+var_CB]
mov rdi, r14
call _strlen
lea rdx, [rsp+rax+118h+var_118]
add rdx, 4Dh ; 'M'
lea rdi, [rsp+118h+var_F0]
mov rsi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rcx, [rsp+118h+var_110]
mov r8, [rsp+118h+var_108]
mov rdx, [rsp+118h+var_E8]
lea rax, [rdx+r8]
mov edi, 0Fh
cmp rcx, r15
jz short loc_71C5D
mov rdi, [rsp+118h+var_100]
loc_71C5D:
mov rsi, [rsp+118h+var_F0]
cmp rax, rdi
jbe short loc_71C7B
mov edi, 0Fh
cmp rsi, r13
jz short loc_71C76
mov rdi, [rsp+118h+var_E0]
loc_71C76:
cmp rax, rdi
jbe short loc_71C87
loc_71C7B:
lea rdi, [rsp+118h+var_110]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong)
jmp short loc_71C95
loc_71C87:
lea rdi, [rsp+118h+var_F0]
xor esi, esi
xor edx, edx
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong)
loc_71C95:
lea rdx, [rbx+10h]
mov [rbx], rdx
mov rsi, [rax]
lea rcx, [rax+10h]
cmp rsi, rcx
jz short loc_71CB4
mov [rbx], rsi
mov rdx, [rcx]
mov [rbx+10h], rdx
jmp short loc_71CBA
loc_71CB4:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [rdx], xmm0
loc_71CBA:
mov rdx, rax
add rdx, 8
mov rsi, [rax+8]
mov [rbx+8], rsi
mov [rax], rcx
mov qword ptr [rdx], 0
mov byte ptr [rcx], 0
mov rdi, [rsp+118h+var_F0]; void *
cmp rdi, r13
jz short loc_71CED
mov rsi, [rsp+118h+var_E0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_71CED:
mov rdi, [rsp+118h+var_110]; void *
cmp rdi, r15
jz short loc_71D04
mov rsi, [rsp+118h+var_100]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_71D04:
mov rdi, [rsp+118h+var_C0]; void *
cmp rdi, r12
jz short loc_71D1B
mov rsi, [rsp+118h+var_B0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_71D1B:
mov rax, rbx
add rsp, 0F0h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
mov rbx, rax
mov rdi, [rsp+arg_20]; void *
cmp rdi, r13
jz short loc_71D4E
mov rsi, [rsp+arg_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_71D4E
mov rbx, rax
loc_71D4E:
mov rdi, [rsp+arg_0]; void *
cmp rdi, r15
jz short loc_71D6A
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_71D6A
mov rbx, rax
loc_71D6A:
mov rdi, [rsp+arg_50]; void *
cmp rdi, r12
jz short loc_71D81
mov rsi, [rsp+arg_60]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_71D81:
mov rdi, rbx
call __Unwind_Resume
| long long string_get_sortable_timestamp[abi:cxx11](long long a1)
{
long long v2; // r14
long long v3; // rax
long long v4; // rax
long long v5; // rax
__int128 *v6; // rcx
long long v7; // rax
unsigned long long v8; // rax
unsigned long long v9; // rdi
unsigned long long v10; // rdi
_QWORD *v11; // rax
_OWORD *v12; // rcx
void *v14; // [rsp+8h] [rbp-110h] BYREF
long long v15; // [rsp+10h] [rbp-108h]
__int128 v16; // [rsp+18h] [rbp-100h] BYREF
void *v17; // [rsp+28h] [rbp-F0h] BYREF
long long v18; // [rsp+30h] [rbp-E8h]
_QWORD v19[2]; // [rsp+38h] [rbp-E0h] BYREF
_BYTE v20[11]; // [rsp+4Dh] [rbp-CBh] BYREF
void *v21[2]; // [rsp+58h] [rbp-C0h] BYREF
_QWORD v22[3]; // [rsp+68h] [rbp-B0h] BYREF
_BYTE v23[152]; // [rsp+80h] [rbp-98h] BYREF
v2 = std::chrono::_V2::system_clock::now((std::chrono::_V2::system_clock *)a1);
v22[2] = v2 / 1000000000;
v3 = localtime();
strftime(v23, 100LL, "%Y_%m_%d-%H_%M_%S", v3);
snprintf(v20, 11LL, "%09ld", v2 % 1000000000);
v21[0] = v22;
v4 = strlen(v23);
std::string::_M_construct<char const*>((long long)v21, v23, (long long)&v23[v4]);
v5 = std::string::append(v21, ".");
v14 = &v16;
v6 = (__int128 *)(v5 + 16);
if ( *(_QWORD *)v5 == v5 + 16 )
{
v16 = *v6;
}
else
{
v14 = *(void **)v5;
*(_QWORD *)&v16 = *(_QWORD *)v6;
}
v15 = *(_QWORD *)(v5 + 8);
*(_QWORD *)v5 = v6;
*(_QWORD *)(v5 + 8) = 0LL;
*(_BYTE *)(v5 + 16) = 0;
v17 = v19;
v7 = strlen(v20);
std::string::_M_construct<char const*>((long long)&v17, v20, (long long)&v20[v7]);
v8 = v18 + v15;
v9 = 15LL;
if ( v14 != &v16 )
v9 = v16;
if ( v8 <= v9 )
goto LABEL_10;
v10 = 15LL;
if ( v17 != v19 )
v10 = v19[0];
if ( v8 <= v10 )
v11 = (_QWORD *)std::string::replace(&v17, 0LL, 0LL, v14, v15);
else
LABEL_10:
v11 = (_QWORD *)std::string::_M_append(&v14, v17, v18);
*(_QWORD *)a1 = a1 + 16;
v12 = v11 + 2;
if ( (_QWORD *)*v11 == v11 + 2 )
{
*(_OWORD *)(a1 + 16) = *v12;
}
else
{
*(_QWORD *)a1 = *v11;
*(_QWORD *)(a1 + 16) = *(_QWORD *)v12;
}
*(_QWORD *)(a1 + 8) = v11[1];
*v11 = v12;
v11[1] = 0LL;
*(_BYTE *)v12 = 0;
if ( v17 != v19 )
operator delete(v17, v19[0] + 1LL);
if ( v14 != &v16 )
operator delete(v14, v16 + 1);
if ( v21[0] != v22 )
operator delete(v21[0], v22[0] + 1LL);
return a1;
}
| string_get_sortable_timestamp[abi:cxx11]:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xf0
MOV RBX,RDI
CALL 0x0011a090
MOV R14,RAX
MOV RCX,0x112e0be826d694b3
IMUL RCX
MOV R12,RDX
MOV RAX,RDX
SHR RAX,0x3f
SAR R12,0x1a
ADD R12,RAX
LEA RDI,[RSP + 0x78]
MOV qword ptr [RDI],R12
CALL 0x0011a6b0
LEA RDX,[0x1eec87]
LEA R15,[RSP + 0x80]
MOV ESI,0x64
MOV RDI,R15
MOV RCX,RAX
CALL 0x0011a730
IMUL RAX,R12,0x3b9aca00
SUB R14,RAX
LEA RDX,[0x1eec99]
LEA RDI,[RSP + 0x4d]
MOV ESI,0xb
MOV RCX,R14
XOR EAX,EAX
CALL 0x0011ae00
LEA R12,[RSP + 0x68]
MOV qword ptr [R12 + -0x10],R12
MOV RDI,R15
CALL 0x0011a400
LEA RDX,[RSP + RAX*0x1]
ADD RDX,0x80
LEA R14,[RSP + 0x58]
MOV RDI,R14
MOV RSI,R15
CALL 0x00121af4
LAB_00171bbb:
LEA RSI,[0x1ea2a1]
MOV RDI,R14
CALL 0x0011b120
LEA R15,[RSP + 0x18]
MOV qword ptr [R15 + -0x10],R15
MOV RDX,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RDX,RCX
JZ 0x00171bf1
MOV qword ptr [RSP + 0x8],RDX
MOV RDX,qword ptr [RCX]
MOV qword ptr [RSP + 0x18],RDX
JMP 0x00171bf8
LAB_00171bf1:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [R15],XMM0
LAB_00171bf8:
MOV RDX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x10],RDX
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV byte ptr [RAX + 0x10],0x0
LEA R13,[RSP + 0x38]
MOV qword ptr [R13 + -0x10],R13
LEA R14,[RSP + 0x4d]
MOV RDI,R14
CALL 0x0011a400
LEA RDX,[RSP + RAX*0x1]
ADD RDX,0x4d
LAB_00171c2e:
LEA RDI,[RSP + 0x28]
MOV RSI,R14
CALL 0x00121af4
MOV RCX,qword ptr [RSP + 0x8]
MOV R8,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RSP + 0x30]
LEA RAX,[RDX + R8*0x1]
MOV EDI,0xf
CMP RCX,R15
JZ 0x00171c5d
MOV RDI,qword ptr [RSP + 0x18]
LAB_00171c5d:
MOV RSI,qword ptr [RSP + 0x28]
CMP RAX,RDI
JBE 0x00171c7b
MOV EDI,0xf
CMP RSI,R13
JZ 0x00171c76
MOV RDI,qword ptr [RSP + 0x38]
LAB_00171c76:
CMP RAX,RDI
JBE 0x00171c87
LAB_00171c7b:
LEA RDI,[RSP + 0x8]
CALL 0x0011a270
JMP 0x00171c95
LAB_00171c87:
LEA RDI,[RSP + 0x28]
XOR ESI,ESI
XOR EDX,EDX
CALL 0x0011a9f0
LAB_00171c95:
LEA RDX,[RBX + 0x10]
MOV qword ptr [RBX],RDX
MOV RSI,qword ptr [RAX]
LEA RCX,[RAX + 0x10]
CMP RSI,RCX
JZ 0x00171cb4
MOV qword ptr [RBX],RSI
MOV RDX,qword ptr [RCX]
MOV qword ptr [RBX + 0x10],RDX
JMP 0x00171cba
LAB_00171cb4:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [RDX],XMM0
LAB_00171cba:
MOV RDX,RAX
ADD RDX,0x8
MOV RSI,qword ptr [RAX + 0x8]
MOV qword ptr [RBX + 0x8],RSI
MOV qword ptr [RAX],RCX
MOV qword ptr [RDX],0x0
MOV byte ptr [RCX],0x0
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R13
JZ 0x00171ced
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x0011a8f0
LAB_00171ced:
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,R15
JZ 0x00171d04
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011a8f0
LAB_00171d04:
MOV RDI,qword ptr [RSP + 0x58]
CMP RDI,R12
JZ 0x00171d1b
MOV RSI,qword ptr [RSP + 0x68]
INC RSI
CALL 0x0011a8f0
LAB_00171d1b:
MOV RAX,RBX
ADD RSP,0xf0
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
/* WARNING: Unknown calling convention -- yet parameter storage is locked */
/* string_get_sortable_timestamp[abi:cxx11]() */
void string_get_sortable_timestamp_abi_cxx11_(void)
{
int8 *puVar1;
int8 uVar2;
long lVar3;
tm *__tp;
size_t sVar4;
long *plVar5;
int8 *puVar6;
ulong *puVar7;
int8 *in_RDI;
ulong uVar8;
ulong *local_110;
long local_108;
ulong local_100;
long lStack_f8;
ulong *local_f0;
long local_e8;
ulong local_e0 [2];
char local_cb [11];
long *local_c0 [2];
long local_b0 [2];
long local_a0;
char local_98 [112];
lVar3 = std::chrono::_V2::system_clock::now();
local_a0 = lVar3 / 1000000000;
__tp = localtime(&local_a0);
strftime(local_98,100,"%Y_%m_%d-%H_%M_%S",__tp);
snprintf(local_cb,0xb,"%09ld",lVar3 % 1000000000);
local_c0[0] = local_b0;
sVar4 = strlen(local_98);
std::__cxx11::string::_M_construct<char_const*>(local_c0,local_98,local_98 + sVar4);
/* try { // try from 00171bbb to 00171bc9 has its CatchHandler @ 00171d67 */
plVar5 = (long *)std::__cxx11::string::append((char *)local_c0);
puVar7 = (ulong *)(plVar5 + 2);
if ((ulong *)*plVar5 == puVar7) {
local_100 = *puVar7;
lStack_f8 = plVar5[3];
local_110 = &local_100;
}
else {
local_100 = *puVar7;
local_110 = (ulong *)*plVar5;
}
local_108 = plVar5[1];
*plVar5 = (long)puVar7;
plVar5[1] = 0;
*(int1 *)(plVar5 + 2) = 0;
local_f0 = local_e0;
sVar4 = strlen(local_cb);
/* try { // try from 00171c2e to 00171c3a has its CatchHandler @ 00171d4b */
std::__cxx11::string::_M_construct<char_const*>(&local_f0,local_cb,local_cb + sVar4);
uVar8 = 0xf;
if (local_110 != &local_100) {
uVar8 = local_100;
}
if (uVar8 < (ulong)(local_e8 + local_108)) {
uVar8 = 0xf;
if (local_f0 != local_e0) {
uVar8 = local_e0[0];
}
if ((ulong)(local_e8 + local_108) <= uVar8) {
puVar6 = (int8 *)
std::__cxx11::string::replace((ulong)&local_f0,0,(char *)0x0,(ulong)local_110);
goto LAB_00171c95;
}
}
/* try { // try from 00171c7b to 00171c94 has its CatchHandler @ 00171d2f */
puVar6 = (int8 *)std::__cxx11::string::_M_append((char *)&local_110,(ulong)local_f0);
LAB_00171c95:
*in_RDI = in_RDI + 2;
puVar1 = puVar6 + 2;
if ((int8 *)*puVar6 == puVar1) {
uVar2 = puVar6[3];
in_RDI[2] = *puVar1;
in_RDI[3] = uVar2;
}
else {
*in_RDI = (int8 *)*puVar6;
in_RDI[2] = *puVar1;
}
in_RDI[1] = puVar6[1];
*puVar6 = puVar1;
puVar6[1] = 0;
*(int1 *)puVar1 = 0;
if (local_f0 != local_e0) {
operator_delete(local_f0,local_e0[0] + 1);
}
if (local_110 != &local_100) {
operator_delete(local_110,local_100 + 1);
}
if (local_c0[0] != local_b0) {
operator_delete(local_c0[0],local_b0[0] + 1);
}
return;
}
| |
21,479 | FileWriterText::writeTreeNode(std::filesystem::__cxx11::path const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | shubhamoy[P]dir2txt/src/FileWriterText.cpp | void FileWriterText::writeTreeNode(const std::filesystem::path& relPath, const std::string& type) {
std::string prefix = "├── ";
std::string line = prefix + relPath.string();
if (type == "dir") line += "/";
writeLine(line);
} | O2 | cpp | FileWriterText::writeTreeNode(std::filesystem::__cxx11::path const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
pushq %r15
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
leaq 0xe649(%rip), %rsi # 0x30f6c
leaq 0x40(%rsp), %rdi
movq %rsp, %rdx
callq 0xab86
leaq 0x20(%rsp), %rdi
movq %r15, %rsi
callq 0x21c16
movq %rsp, %rdi
leaq 0x40(%rsp), %rsi
leaq 0x20(%rsp), %rdx
callq 0x22d28
leaq 0x20(%rsp), %rdi
callq 0x8e46
leaq 0xe549(%rip), %rsi # 0x30ea9
movq %r14, %rdi
callq 0x10277
testb %al, %al
je 0x2297b
leaq 0x129bf(%rip), %rsi # 0x35332
movq %rsp, %rdi
callq 0x96fe
movq (%rbx), %rax
movq %rsp, %rsi
movq %rbx, %rdi
callq *0x20(%rax)
movq %rsp, %rdi
callq 0x8e46
leaq 0x40(%rsp), %rdi
callq 0x8e46
addq $0x60, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
jmp 0x229b8
movq %rax, %rbx
jmp 0x229bd
movq %rax, %rbx
movq %rsp, %rdi
callq 0x8e46
leaq 0x40(%rsp), %rdi
callq 0x8e46
movq %rbx, %rdi
callq 0x85e0
nop
| _ZN14FileWriterText13writeTreeNodeERKNSt10filesystem7__cxx114pathERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push r15
push r14
push rbx
sub rsp, 60h
mov r14, rdx
mov r15, rsi
mov rbx, rdi
lea rsi, unk_30F6C
lea rdi, [rsp+78h+var_38]
mov rdx, rsp
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
lea rdi, [rsp+78h+var_58]; this
mov rsi, r15
call _ZNKSt10filesystem7__cxx114path6stringEv; std::filesystem::__cxx11::path::string(void)
mov rdi, rsp
lea rsi, [rsp+78h+var_38]
lea rdx, [rsp+78h+var_58]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EERKS8_OS8_; std::operator+<char>(std::string const&,std::string&&)
lea rdi, [rsp+78h+var_58]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rsi, byte_30EA9
mov rdi, r14
call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*)
test al, al
jz short loc_2297B
lea rsi, asc_35330+2; "/"
mov rdi, rsp
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
loc_2297B:
mov rax, [rbx]
mov rsi, rsp
mov rdi, rbx
call qword ptr [rax+20h]
mov rdi, rsp; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+78h+var_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
add rsp, 60h
pop rbx
pop r14
pop r15
retn
mov rbx, rax
lea rdi, [rsp+arg_18]
jmp short loc_229B8
mov rbx, rax
jmp short loc_229BD
mov rbx, rax
mov rdi, rsp; void *
loc_229B8:
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_229BD:
lea rdi, [rsp+arg_38]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, rbx
call __Unwind_Resume
| void FileWriterText::writeTreeNode(long long a1, long long a2, long long a3)
{
_BYTE v4[32]; // [rsp+0h] [rbp-78h] BYREF
_BYTE v5[32]; // [rsp+20h] [rbp-58h] BYREF
_QWORD v6[7]; // [rsp+40h] [rbp-38h] BYREF
std::string::basic_string<std::allocator<char>>(v6, byte_30F6C);
std::filesystem::__cxx11::path::string((std::filesystem::__cxx11::path *)v5, a2);
std::operator+<char>(v4, v6, v5);
std::string::~string(v5);
if ( std::operator==<char>(a3) )
std::string::append((long long)v4, (long long)"/");
(*(void ( **)(long long, _BYTE *))(*(_QWORD *)a1 + 32LL))(a1, v4);
std::string::~string(v4);
std::string::~string(v6);
}
| writeTreeNode:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x60
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
LEA RSI,[0x130f6c]
LEA RDI,[RSP + 0x40]
MOV RDX,RSP
CALL 0x0010ab86
LAB_00122930:
LEA RDI,[RSP + 0x20]
MOV RSI,R15
CALL 0x00121c16
LAB_0012293d:
MOV RDI,RSP
LEA RSI,[RSP + 0x40]
LEA RDX,[RSP + 0x20]
CALL 0x00122d28
LEA RDI,[RSP + 0x20]
CALL 0x00108e46
LEA RSI,[0x130ea9]
MOV RDI,R14
CALL 0x00110277
TEST AL,AL
JZ 0x0012297b
LAB_0012296c:
LEA RSI,[0x135332]
MOV RDI,RSP
CALL 0x001096fe
LAB_0012297b:
MOV RAX,qword ptr [RBX]
MOV RSI,RSP
MOV RDI,RBX
CALL qword ptr [RAX + 0x20]
LAB_00122987:
MOV RDI,RSP
CALL 0x00108e46
LEA RDI,[RSP + 0x40]
CALL 0x00108e46
ADD RSP,0x60
POP RBX
POP R14
POP R15
RET
|
/* FileWriterText::writeTreeNode(std::filesystem::__cxx11::path const&, std::__cxx11::string const&)
*/
void __thiscall FileWriterText::writeTreeNode(FileWriterText *this,path *param_1,string *param_2)
{
bool bVar1;
allocator aaStack_78 [32];
string local_58 [32];
string local_38 [32];
std::__cxx11::string::string<std::allocator<char>>(local_38,&DAT_00130f6c,aaStack_78);
/* try { // try from 00122930 to 0012293c has its CatchHandler @ 001229ad */
std::filesystem::__cxx11::path::string();
/* try { // try from 0012293d to 0012294e has its CatchHandler @ 001229a3 */
std::operator+((string *)aaStack_78,local_38);
std::__cxx11::string::~string(local_58);
bVar1 = std::operator==(param_2,"dir");
if (bVar1) {
/* try { // try from 0012296c to 00122986 has its CatchHandler @ 001229b2 */
std::__cxx11::string::append((string *)aaStack_78,"/");
}
(**(code **)(*(long *)this + 0x20))(this,aaStack_78);
std::__cxx11::string::~string((string *)aaStack_78);
std::__cxx11::string::~string(local_38);
return;
}
| |
21,480 | inline_mysql_rwlock_unlock | eloqsql/include/mysql/psi/mysql_thread.h | static inline int inline_mysql_rwlock_unlock(
mysql_rwlock_t *that)
{
int result;
#ifdef HAVE_PSI_RWLOCK_INTERFACE
if (psi_likely(that->m_psi != NULL))
PSI_RWLOCK_CALL(unlock_rwlock)(that->m_psi);
#endif
result= rw_unlock(&that->m_rwlock);
return result;
} | O0 | c | inline_mysql_rwlock_unlock:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x90(%rax)
setne %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x57301
leaq 0x267dce(%rip), %rax # 0x2bf0b8
movq (%rax), %rax
movq 0x168(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x90(%rcx), %rdi
callq *%rax
movq -0x8(%rbp), %rdi
callq 0xf9b00
movl %eax, -0xc(%rbp)
movl -0xc(%rbp), %eax
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| inline_mysql_rwlock_unlock_1:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
cmp qword ptr [rax+90h], 0
setnz al
and al, 1
movzx eax, al
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_57301
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+168h]
mov rcx, [rbp+var_8]
mov rdi, [rcx+90h]
call rax
loc_57301:
mov rdi, [rbp+var_8]
call my_rw_unlock
mov [rbp+var_C], eax
mov eax, [rbp+var_C]
add rsp, 10h
pop rbp
retn
| long long inline_mysql_rwlock_unlock_1(long long a1)
{
if ( *(_QWORD *)(a1 + 144) )
((void ( *)(_QWORD))PSI_server[45])(*(_QWORD *)(a1 + 144));
return (unsigned int)my_rw_unlock(a1);
}
| inline_mysql_rwlock_unlock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x90],0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x00157301
LEA RAX,[0x3bf0b8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x168]
MOV RCX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RCX + 0x90]
CALL RAX
LAB_00157301:
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x001f9b00
MOV dword ptr [RBP + -0xc],EAX
MOV EAX,dword ptr [RBP + -0xc]
ADD RSP,0x10
POP RBP
RET
|
int4 inline_mysql_rwlock_unlock(long param_1)
{
int4 uVar1;
if (*(long *)(param_1 + 0x90) != 0) {
(**(code **)(PSI_server + 0x168))(*(int8 *)(param_1 + 0x90));
}
uVar1 = my_rw_unlock(param_1);
return uVar1;
}
| |
21,481 | unreg_request | eloqsql/mysys/mf_keycache.c | static void unreg_request(SIMPLE_KEY_CACHE_CB *keycache,
BLOCK_LINK *block, int at_end)
{
DBUG_ASSERT(block->status & (BLOCK_READ | BLOCK_IN_USE));
DBUG_ASSERT(block->hash_link); /*backptr to block NULL from free_block()*/
DBUG_ASSERT(block->requests);
DBUG_ASSERT(block->prev_changed && *block->prev_changed == block);
DBUG_ASSERT(!block->next_used);
DBUG_ASSERT(!block->prev_used);
/*
Unregister the request, but do not link erroneous blocks into the
LRU ring.
*/
if (!--block->requests && !(block->status & BLOCK_ERROR))
{
my_bool hot;
if (block->hits_left)
block->hits_left--;
hot= !block->hits_left && at_end &&
keycache->warm_blocks > keycache->min_warm_blocks;
if (hot)
{
if (block->temperature == BLOCK_WARM)
keycache->warm_blocks--;
block->temperature= BLOCK_HOT;
KEYCACHE_DBUG_PRINT("unreg_request", ("#warm_blocks: %lu",
keycache->warm_blocks));
}
link_block(keycache, block, hot, (my_bool)at_end);
block->last_hit_time= keycache->keycache_time;
keycache->keycache_time++;
/*
At this place, the block might be in the LRU ring or not. If an
evicter was waiting for a block, it was selected for eviction and
not linked in the LRU ring.
*/
/*
Check if we should link a hot block to the warm block sub-chain.
It is possible that we select the same block as above. But it can
also be another block. In any case a block from the LRU ring is
selected. In other words it works even if the above block was
selected for eviction and not linked in the LRU ring. Since this
happens only if the LRU ring is empty, the block selected below
would be NULL and the rest of the function skipped.
*/
block= keycache->used_ins;
if (block && keycache->keycache_time - block->last_hit_time >
keycache->age_threshold)
{
unlink_block(keycache, block);
link_block(keycache, block, 0, 0);
if (block->temperature != BLOCK_WARM)
{
keycache->warm_blocks++;
block->temperature= BLOCK_WARM;
}
KEYCACHE_DBUG_PRINT("unreg_request", ("#warm_blocks: %lu",
keycache->warm_blocks));
}
}
} | O0 | c | unreg_request:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
jmp 0xe4225
jmp 0xe4227
jmp 0xe4229
jmp 0xe422b
jmp 0xe422d
jmp 0xe422f
jmp 0xe4231
jmp 0xe4233
jmp 0xe4235
jmp 0xe4237
jmp 0xe4239
movq -0x10(%rbp), %rcx
movl 0x38(%rcx), %eax
addl $-0x1, %eax
movl %eax, 0x38(%rcx)
cmpl $0x0, %eax
jne 0xe4397
movq -0x10(%rbp), %rax
movl 0x50(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
jne 0xe4397
movq -0x10(%rbp), %rax
cmpl $0x0, 0x58(%rax)
je 0xe4279
movq -0x10(%rbp), %rax
movl 0x58(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0x58(%rax)
movq -0x10(%rbp), %rcx
xorl %eax, %eax
cmpl $0x0, 0x58(%rcx)
movb %al, -0x16(%rbp)
jne 0xe42a9
xorl %eax, %eax
cmpl $0x0, -0x14(%rbp)
movb %al, -0x16(%rbp)
je 0xe42a9
movq -0x8(%rbp), %rax
movq 0x68(%rax), %rax
movq -0x8(%rbp), %rcx
cmpq 0x20(%rcx), %rax
seta %al
movb %al, -0x16(%rbp)
movb -0x16(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x15(%rbp)
cmpb $0x0, -0x15(%rbp)
je 0xe42e3
movq -0x10(%rbp), %rax
cmpl $0x1, 0x54(%rax)
jne 0xe42d4
movq -0x8(%rbp), %rax
movq 0x68(%rax), %rcx
addq $-0x1, %rcx
movq %rcx, 0x68(%rax)
movq -0x10(%rbp), %rax
movl $0x2, 0x54(%rax)
jmp 0xe42e1
jmp 0xe42e3
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movb -0x15(%rbp), %cl
movl -0x14(%rbp), %eax
movsbl %cl, %edx
movsbl %al, %ecx
callq 0xe5800
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x60(%rax)
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x30(%rax)
movq -0x8(%rbp), %rax
movq 0xb8(%rax), %rax
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0xe4395
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq -0x10(%rbp), %rcx
subq 0x60(%rcx), %rax
movq -0x8(%rbp), %rcx
cmpq 0x28(%rcx), %rax
jbe 0xe4395
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0xe56d0
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
xorl %ecx, %ecx
movl %ecx, %edx
callq 0xe5800
movq -0x10(%rbp), %rax
cmpl $0x1, 0x54(%rax)
je 0xe438f
movq -0x8(%rbp), %rax
movq 0x68(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x68(%rax)
movq -0x10(%rbp), %rax
movl $0x1, 0x54(%rax)
jmp 0xe4391
jmp 0xe4393
jmp 0xe4395
jmp 0xe4397
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
| unreg_request_0:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
jmp short $+2
loc_E4225:
jmp short $+2
loc_E4227:
jmp short $+2
loc_E4229:
jmp short $+2
loc_E422B:
jmp short $+2
loc_E422D:
jmp short $+2
loc_E422F:
jmp short $+2
loc_E4231:
jmp short $+2
loc_E4233:
jmp short $+2
loc_E4235:
jmp short $+2
loc_E4237:
jmp short $+2
loc_E4239:
mov rcx, [rbp+var_10]
mov eax, [rcx+38h]
add eax, 0FFFFFFFFh
mov [rcx+38h], eax
cmp eax, 0
jnz loc_E4397
mov rax, [rbp+var_10]
mov eax, [rax+50h]
and eax, 1
cmp eax, 0
jnz loc_E4397
mov rax, [rbp+var_10]
cmp dword ptr [rax+58h], 0
jz short loc_E4279
mov rax, [rbp+var_10]
mov ecx, [rax+58h]
add ecx, 0FFFFFFFFh
mov [rax+58h], ecx
loc_E4279:
mov rcx, [rbp+var_10]
xor eax, eax
cmp dword ptr [rcx+58h], 0
mov [rbp+var_16], al
jnz short loc_E42A9
xor eax, eax
cmp [rbp+var_14], 0
mov [rbp+var_16], al
jz short loc_E42A9
mov rax, [rbp+var_8]
mov rax, [rax+68h]
mov rcx, [rbp+var_8]
cmp rax, [rcx+20h]
setnbe al
mov [rbp+var_16], al
loc_E42A9:
mov al, [rbp+var_16]
and al, 1
movzx eax, al
mov [rbp+var_15], al
cmp [rbp+var_15], 0
jz short loc_E42E3
mov rax, [rbp+var_10]
cmp dword ptr [rax+54h], 1
jnz short loc_E42D4
mov rax, [rbp+var_8]
mov rcx, [rax+68h]
add rcx, 0FFFFFFFFFFFFFFFFh
mov [rax+68h], rcx
loc_E42D4:
mov rax, [rbp+var_10]
mov dword ptr [rax+54h], 2
jmp short $+2
loc_E42E1:
jmp short $+2
loc_E42E3:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov cl, [rbp+var_15]
mov eax, [rbp+var_14]
movsx edx, cl
movsx ecx, al
call link_block_0
mov rax, [rbp+var_8]
mov rcx, [rax+30h]
mov rax, [rbp+var_10]
mov [rax+60h], rcx
mov rax, [rbp+var_8]
mov rcx, [rax+30h]
add rcx, 1
mov [rax+30h], rcx
mov rax, [rbp+var_8]
mov rax, [rax+0B8h]
mov [rbp+var_10], rax
cmp [rbp+var_10], 0
jz short loc_E4395
mov rax, [rbp+var_8]
mov rax, [rax+30h]
mov rcx, [rbp+var_10]
sub rax, [rcx+60h]
mov rcx, [rbp+var_8]
cmp rax, [rcx+28h]
jbe short loc_E4395
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
call unlink_block_0
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
xor ecx, ecx
mov edx, ecx
call link_block_0
mov rax, [rbp+var_10]
cmp dword ptr [rax+54h], 1
jz short loc_E438F
mov rax, [rbp+var_8]
mov rcx, [rax+68h]
add rcx, 1
mov [rax+68h], rcx
mov rax, [rbp+var_10]
mov dword ptr [rax+54h], 1
loc_E438F:
jmp short $+2
loc_E4391:
jmp short $+2
loc_E4393:
jmp short $+2
loc_E4395:
jmp short $+2
loc_E4397:
add rsp, 20h
pop rbp
retn
| unsigned long long unreg_request_0(_QWORD *a1, long long a2, int a3)
{
unsigned long long result; // rax
bool v4; // [rsp+Ah] [rbp-16h]
unsigned long long v5; // [rsp+10h] [rbp-10h]
result = (unsigned int)(*(_DWORD *)(a2 + 56) - 1);
*(_DWORD *)(a2 + 56) = result;
if ( !(_DWORD)result )
{
result = *(_DWORD *)(a2 + 80) & 1;
if ( !(_DWORD)result )
{
if ( *(_DWORD *)(a2 + 88) )
--*(_DWORD *)(a2 + 88);
v4 = 0;
if ( !*(_DWORD *)(a2 + 88) )
{
v4 = 0;
if ( a3 )
v4 = a1[13] > a1[4];
}
if ( v4 )
{
if ( *(_DWORD *)(a2 + 84) == 1 )
--a1[13];
*(_DWORD *)(a2 + 84) = 2;
}
link_block_0(a1, a2, v4, (unsigned int)(char)a3);
*(_QWORD *)(a2 + 96) = a1[6]++;
result = a1[23];
v5 = result;
if ( result )
{
result = a1[6] - *(_QWORD *)(result + 96);
if ( result > a1[5] )
{
unlink_block_0(a1, v5);
link_block_0(a1, v5, 0LL, 0LL);
result = v5;
if ( *(_DWORD *)(v5 + 84) != 1 )
{
++a1[13];
result = v5;
*(_DWORD *)(v5 + 84) = 1;
}
}
}
}
}
return result;
}
| unreg_request:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
JMP 0x001e4225
LAB_001e4225:
JMP 0x001e4227
LAB_001e4227:
JMP 0x001e4229
LAB_001e4229:
JMP 0x001e422b
LAB_001e422b:
JMP 0x001e422d
LAB_001e422d:
JMP 0x001e422f
LAB_001e422f:
JMP 0x001e4231
LAB_001e4231:
JMP 0x001e4233
LAB_001e4233:
JMP 0x001e4235
LAB_001e4235:
JMP 0x001e4237
LAB_001e4237:
JMP 0x001e4239
LAB_001e4239:
MOV RCX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RCX + 0x38]
ADD EAX,-0x1
MOV dword ptr [RCX + 0x38],EAX
CMP EAX,0x0
JNZ 0x001e4397
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x50]
AND EAX,0x1
CMP EAX,0x0
JNZ 0x001e4397
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x58],0x0
JZ 0x001e4279
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x58]
ADD ECX,-0x1
MOV dword ptr [RAX + 0x58],ECX
LAB_001e4279:
MOV RCX,qword ptr [RBP + -0x10]
XOR EAX,EAX
CMP dword ptr [RCX + 0x58],0x0
MOV byte ptr [RBP + -0x16],AL
JNZ 0x001e42a9
XOR EAX,EAX
CMP dword ptr [RBP + -0x14],0x0
MOV byte ptr [RBP + -0x16],AL
JZ 0x001e42a9
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x68]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,qword ptr [RCX + 0x20]
SETA AL
MOV byte ptr [RBP + -0x16],AL
LAB_001e42a9:
MOV AL,byte ptr [RBP + -0x16]
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x15],AL
CMP byte ptr [RBP + -0x15],0x0
JZ 0x001e42e3
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x54],0x1
JNZ 0x001e42d4
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x68]
ADD RCX,-0x1
MOV qword ptr [RAX + 0x68],RCX
LAB_001e42d4:
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x54],0x2
JMP 0x001e42e1
LAB_001e42e1:
JMP 0x001e42e3
LAB_001e42e3:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV CL,byte ptr [RBP + -0x15]
MOV EAX,dword ptr [RBP + -0x14]
MOVSX EDX,CL
MOVSX ECX,AL
CALL 0x001e5800
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x30]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x60],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x30]
ADD RCX,0x1
MOV qword ptr [RAX + 0x30],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0xb8]
MOV qword ptr [RBP + -0x10],RAX
CMP qword ptr [RBP + -0x10],0x0
JZ 0x001e4395
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x30]
MOV RCX,qword ptr [RBP + -0x10]
SUB RAX,qword ptr [RCX + 0x60]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,qword ptr [RCX + 0x28]
JBE 0x001e4395
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
CALL 0x001e56d0
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
XOR ECX,ECX
MOV EDX,ECX
CALL 0x001e5800
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x54],0x1
JZ 0x001e438f
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x68]
ADD RCX,0x1
MOV qword ptr [RAX + 0x68],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x54],0x1
LAB_001e438f:
JMP 0x001e4391
LAB_001e4391:
JMP 0x001e4393
LAB_001e4393:
JMP 0x001e4395
LAB_001e4395:
JMP 0x001e4397
LAB_001e4397:
ADD RSP,0x20
POP RBP
RET
|
void unreg_request(long param_1,long param_2,int param_3)
{
long lVar1;
int iVar2;
bool local_1e;
iVar2 = *(int *)(param_2 + 0x38) + -1;
*(int *)(param_2 + 0x38) = iVar2;
if ((iVar2 == 0) && ((*(uint *)(param_2 + 0x50) & 1) == 0)) {
if (*(int *)(param_2 + 0x58) != 0) {
*(int *)(param_2 + 0x58) = *(int *)(param_2 + 0x58) + -1;
}
local_1e = false;
if ((*(int *)(param_2 + 0x58) == 0) && (local_1e = false, param_3 != 0)) {
local_1e = *(ulong *)(param_1 + 0x20) < *(ulong *)(param_1 + 0x68);
}
if (local_1e != false) {
if (*(int *)(param_2 + 0x54) == 1) {
*(long *)(param_1 + 0x68) = *(long *)(param_1 + 0x68) + -1;
}
*(int4 *)(param_2 + 0x54) = 2;
}
link_block(param_1,param_2,local_1e,(int)(char)param_3);
*(int8 *)(param_2 + 0x60) = *(int8 *)(param_1 + 0x30);
*(long *)(param_1 + 0x30) = *(long *)(param_1 + 0x30) + 1;
lVar1 = *(long *)(param_1 + 0xb8);
if ((lVar1 != 0) &&
(*(ulong *)(param_1 + 0x28) < (ulong)(*(long *)(param_1 + 0x30) - *(long *)(lVar1 + 0x60))))
{
unlink_block(param_1,lVar1);
link_block(param_1,lVar1,0);
if (*(int *)(lVar1 + 0x54) != 1) {
*(long *)(param_1 + 0x68) = *(long *)(param_1 + 0x68) + 1;
*(int4 *)(lVar1 + 0x54) = 1;
}
}
}
return;
}
| |
21,482 | create_metadata_lock(void*, MDL_key const*, int, int, int, char const*, unsigned int) | eloqsql/storage/perfschema/pfs_instr.cc | PFS_metadata_lock* create_metadata_lock(void *identity,
const MDL_key *mdl_key,
opaque_mdl_type mdl_type,
opaque_mdl_duration mdl_duration,
opaque_mdl_status mdl_status,
const char *src_file,
uint src_line)
{
PFS_metadata_lock *pfs;
pfs_dirty_state dirty_state;
pfs= global_mdl_container.allocate(& dirty_state);
if (pfs != NULL)
{
pfs->m_identity= identity;
pfs->m_enabled= global_metadata_class.m_enabled && flag_global_instrumentation;
pfs->m_timed= global_metadata_class.m_timed;
pfs->m_mdl_key.mdl_key_init(mdl_key);
pfs->m_mdl_type= mdl_type;
pfs->m_mdl_duration= mdl_duration;
pfs->m_mdl_status= mdl_status;
pfs->m_src_file= src_file;
pfs->m_src_line= src_line;
pfs->m_owner_thread_id= 0;
pfs->m_owner_event_id= 0;
pfs->m_lock.dirty_to_allocated(& dirty_state);
}
return pfs;
} | O0 | cpp | create_metadata_lock(void*, MDL_key const*, int, int, int, char const*, unsigned int):
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movl 0x10(%rbp), %eax
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl %ecx, -0x18(%rbp)
movl %r8d, -0x1c(%rbp)
movq %r9, -0x28(%rbp)
leaq 0x3a5ab0(%rip), %rdi # 0x3d66c8
leaq -0x34(%rbp), %rsi
callq 0x35ae0
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
je 0x30cfa
movq -0x8(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, 0x10(%rax)
xorl %eax, %eax
leaq 0x3d9a3b(%rip), %rcx # 0x40a680
testb $0x1, 0x4(%rcx)
movb %al, -0x35(%rbp)
je 0x30c5a
leaq 0x3dd32b(%rip), %rax # 0x40df80
movb (%rax), %al
movb %al, -0x35(%rbp)
movb -0x35(%rbp), %cl
movq -0x30(%rbp), %rax
andb $0x1, %cl
movb %cl, 0x4(%rax)
leaq 0x3d9a12(%rip), %rax # 0x40a680
movb 0x5(%rax), %cl
movq -0x30(%rbp), %rax
andb $0x1, %cl
movb %cl, 0x5(%rax)
movq -0x30(%rbp), %rdi
addq $0x18, %rdi
movq -0x10(%rbp), %rsi
callq 0x35e90
movl -0x14(%rbp), %ecx
movq -0x30(%rbp), %rax
movl %ecx, 0x1a4(%rax)
movl -0x18(%rbp), %ecx
movq -0x30(%rbp), %rax
movl %ecx, 0x1a8(%rax)
movl -0x1c(%rbp), %ecx
movq -0x30(%rbp), %rax
movl %ecx, 0x1ac(%rax)
movq -0x28(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, 0x1b0(%rax)
movl 0x10(%rbp), %ecx
movq -0x30(%rbp), %rax
movl %ecx, 0x1b8(%rax)
movq -0x30(%rbp), %rax
movq $0x0, 0x1c0(%rax)
movq -0x30(%rbp), %rax
movq $0x0, 0x1c8(%rax)
movq -0x30(%rbp), %rdi
leaq -0x34(%rbp), %rsi
callq 0x334b0
movq -0x30(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _Z20create_metadata_lockPvPK7MDL_keyiiiPKcj:
push rbp
mov rbp, rsp
sub rsp, 40h
mov eax, [rbp+arg_0]
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
mov [rbp+var_18], ecx
mov [rbp+var_1C], r8d
mov [rbp+var_28], r9
lea rdi, global_mdl_container
lea rsi, [rbp+var_34]
call _ZN29PFS_buffer_scalable_containerI17PFS_metadata_lockLi1024ELi1024E24PFS_buffer_default_arrayIS0_E28PFS_buffer_default_allocatorIS0_EE8allocateEP15pfs_dirty_state; PFS_buffer_scalable_container<PFS_metadata_lock,1024,1024,PFS_buffer_default_array<PFS_metadata_lock>,PFS_buffer_default_allocator<PFS_metadata_lock>>::allocate(pfs_dirty_state *)
mov [rbp+var_30], rax
cmp [rbp+var_30], 0
jz loc_30CFA
mov rcx, [rbp+var_8]
mov rax, [rbp+var_30]
mov [rax+10h], rcx
xor eax, eax
lea rcx, global_metadata_class
test byte ptr [rcx+4], 1
mov [rbp+var_35], al
jz short loc_30C5A
lea rax, flag_global_instrumentation
mov al, [rax]
mov [rbp+var_35], al
loc_30C5A:
mov cl, [rbp+var_35]
mov rax, [rbp+var_30]
and cl, 1
mov [rax+4], cl
lea rax, global_metadata_class
mov cl, [rax+5]
mov rax, [rbp+var_30]
and cl, 1
mov [rax+5], cl
mov rdi, [rbp+var_30]
add rdi, 18h
mov rsi, [rbp+var_10]
call _ZN7MDL_key12mdl_key_initEPKS_; MDL_key::mdl_key_init(MDL_key const*)
mov ecx, [rbp+var_14]
mov rax, [rbp+var_30]
mov [rax+1A4h], ecx
mov ecx, [rbp+var_18]
mov rax, [rbp+var_30]
mov [rax+1A8h], ecx
mov ecx, [rbp+var_1C]
mov rax, [rbp+var_30]
mov [rax+1ACh], ecx
mov rcx, [rbp+var_28]
mov rax, [rbp+var_30]
mov [rax+1B0h], rcx
mov ecx, [rbp+arg_0]
mov rax, [rbp+var_30]
mov [rax+1B8h], ecx
mov rax, [rbp+var_30]
mov qword ptr [rax+1C0h], 0
mov rax, [rbp+var_30]
mov qword ptr [rax+1C8h], 0
mov rdi, [rbp+var_30]
lea rsi, [rbp+var_34]
call _ZN8pfs_lock18dirty_to_allocatedEPK15pfs_dirty_state; pfs_lock::dirty_to_allocated(pfs_dirty_state const*)
loc_30CFA:
mov rax, [rbp+var_30]
add rsp, 40h
pop rbp
retn
| long long create_metadata_lock(long long a1, long long a2, int a3, int a4, int a5, long long a6, int a7)
{
char v8; // [rsp+Bh] [rbp-35h]
_BYTE v9[4]; // [rsp+Ch] [rbp-34h] BYREF
long long v10; // [rsp+10h] [rbp-30h]
long long v11; // [rsp+18h] [rbp-28h]
int v12; // [rsp+24h] [rbp-1Ch]
int v13; // [rsp+28h] [rbp-18h]
int v14; // [rsp+2Ch] [rbp-14h]
long long v15; // [rsp+30h] [rbp-10h]
long long v16; // [rsp+38h] [rbp-8h]
v16 = a1;
v15 = a2;
v14 = a3;
v13 = a4;
v12 = a5;
v11 = a6;
v10 = PFS_buffer_scalable_container<PFS_metadata_lock,1024,1024,PFS_buffer_default_array<PFS_metadata_lock>,PFS_buffer_default_allocator<PFS_metadata_lock>>::allocate(
&global_mdl_container,
v9);
if ( v10 )
{
*(_QWORD *)(v10 + 16) = v16;
v8 = 0;
if ( (*((_BYTE *)&global_metadata_class + 4) & 1) != 0 )
v8 = flag_global_instrumentation;
*(_BYTE *)(v10 + 4) = v8 & 1;
*(_BYTE *)(v10 + 5) = *((_BYTE *)&global_metadata_class + 5) & 1;
MDL_key::mdl_key_init(v10 + 24, v15);
*(_DWORD *)(v10 + 420) = v14;
*(_DWORD *)(v10 + 424) = v13;
*(_DWORD *)(v10 + 428) = v12;
*(_QWORD *)(v10 + 432) = v11;
*(_DWORD *)(v10 + 440) = a7;
*(_QWORD *)(v10 + 448) = 0LL;
*(_QWORD *)(v10 + 456) = 0LL;
pfs_lock::dirty_to_allocated(v10, v9);
}
return v10;
}
| create_metadata_lock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV EAX,dword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
MOV dword ptr [RBP + -0x18],ECX
MOV dword ptr [RBP + -0x1c],R8D
MOV qword ptr [RBP + -0x28],R9
LEA RDI,[0x4d66c8]
LEA RSI,[RBP + -0x34]
CALL 0x00135ae0
MOV qword ptr [RBP + -0x30],RAX
CMP qword ptr [RBP + -0x30],0x0
JZ 0x00130cfa
MOV RCX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX + 0x10],RCX
XOR EAX,EAX
LEA RCX,[0x50a680]
TEST byte ptr [RCX + 0x4],0x1
MOV byte ptr [RBP + -0x35],AL
JZ 0x00130c5a
LEA RAX,[0x50df80]
MOV AL,byte ptr [RAX]
MOV byte ptr [RBP + -0x35],AL
LAB_00130c5a:
MOV CL,byte ptr [RBP + -0x35]
MOV RAX,qword ptr [RBP + -0x30]
AND CL,0x1
MOV byte ptr [RAX + 0x4],CL
LEA RAX,[0x50a680]
MOV CL,byte ptr [RAX + 0x5]
MOV RAX,qword ptr [RBP + -0x30]
AND CL,0x1
MOV byte ptr [RAX + 0x5],CL
MOV RDI,qword ptr [RBP + -0x30]
ADD RDI,0x18
MOV RSI,qword ptr [RBP + -0x10]
CALL 0x00135e90
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RBP + -0x30]
MOV dword ptr [RAX + 0x1a4],ECX
MOV ECX,dword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x30]
MOV dword ptr [RAX + 0x1a8],ECX
MOV ECX,dword ptr [RBP + -0x1c]
MOV RAX,qword ptr [RBP + -0x30]
MOV dword ptr [RAX + 0x1ac],ECX
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX + 0x1b0],RCX
MOV ECX,dword ptr [RBP + 0x10]
MOV RAX,qword ptr [RBP + -0x30]
MOV dword ptr [RAX + 0x1b8],ECX
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX + 0x1c0],0x0
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX + 0x1c8],0x0
MOV RDI,qword ptr [RBP + -0x30]
LEA RSI,[RBP + -0x34]
CALL 0x001334b0
LAB_00130cfa:
MOV RAX,qword ptr [RBP + -0x30]
ADD RSP,0x40
POP RBP
RET
|
/* create_metadata_lock(void*, MDL_key const*, int, int, int, char const*, unsigned int) */
pfs_lock *
create_metadata_lock
(void *param_1,MDL_key *param_2,int param_3,int param_4,int param_5,char *param_6,
uint param_7)
{
byte local_3d;
pfs_dirty_state local_3c [4];
pfs_lock *local_38;
char *local_30;
int local_24;
int local_20;
int local_1c;
MDL_key *local_18;
void *local_10;
local_30 = param_6;
local_24 = param_5;
local_20 = param_4;
local_1c = param_3;
local_18 = param_2;
local_10 = param_1;
local_38 = (pfs_lock *)
PFS_buffer_scalable_container<PFS_metadata_lock,1024,1024,PFS_buffer_default_array<PFS_metadata_lock>,PFS_buffer_default_allocator<PFS_metadata_lock>>
::allocate((PFS_buffer_scalable_container<PFS_metadata_lock,1024,1024,PFS_buffer_default_array<PFS_metadata_lock>,PFS_buffer_default_allocator<PFS_metadata_lock>>
*)global_mdl_container,local_3c);
if (local_38 != (pfs_lock *)0x0) {
*(void **)(local_38 + 0x10) = local_10;
local_3d = 0;
if ((global_metadata_class[4] & 1) != 0) {
local_3d = flag_global_instrumentation;
}
local_38[4] = (pfs_lock)(local_3d & 1);
local_38[5] = (pfs_lock)(global_metadata_class[5] & 1);
MDL_key::mdl_key_init((MDL_key *)(local_38 + 0x18),local_18);
*(int *)(local_38 + 0x1a4) = local_1c;
*(int *)(local_38 + 0x1a8) = local_20;
*(int *)(local_38 + 0x1ac) = local_24;
*(char **)(local_38 + 0x1b0) = local_30;
*(uint *)(local_38 + 0x1b8) = param_7;
*(int8 *)(local_38 + 0x1c0) = 0;
*(int8 *)(local_38 + 0x1c8) = 0;
pfs_lock::dirty_to_allocated(local_38,local_3c);
}
return local_38;
}
| |
21,483 | lunasvg::SVGCircleElement::updateShape(lunasvg::Path&) | dmazzella[P]pylunasvg/lunasvg/source/svggeometryelement.cpp | Rect SVGCircleElement::updateShape(Path& path)
{
LengthContext lengthContext(this);
auto r = lengthContext.valueForLength(m_r);
if(r <= 0.f) {
return Rect::Empty;
}
auto cx = lengthContext.valueForLength(m_cx);
auto cy = lengthContext.valueForLength(m_cy);
path.addEllipse(cx, cy, r, r);
return Rect(cx - r, cy - r, r + r, r + r);
} | O0 | cpp | lunasvg::SVGCircleElement::updateShape(lunasvg::Path&):
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x18(%rbp)
movq %rsi, -0x20(%rbp)
movq -0x18(%rbp), %rsi
movq %rsi, -0x48(%rbp)
leaq -0x30(%rbp), %rdi
xorl %edx, %edx
callq 0x20050
movq -0x48(%rbp), %rsi
addq $0x148, %rsi # imm = 0x148
leaq -0x30(%rbp), %rdi
callq 0x20080
movss %xmm0, -0x34(%rbp)
xorps %xmm0, %xmm0
ucomiss -0x34(%rbp), %xmm0
jb 0x2e920
leaq 0x5d84c(%rip), %rax # 0x8c158
movq (%rax), %rcx
movq %rcx, -0x10(%rbp)
movq 0x8(%rax), %rax
movq %rax, -0x8(%rbp)
jmp 0x2e9a0
movq -0x48(%rbp), %rsi
addq $0x118, %rsi # imm = 0x118
leaq -0x30(%rbp), %rdi
callq 0x20080
movq -0x48(%rbp), %rsi
movss %xmm0, -0x38(%rbp)
addq $0x130, %rsi # imm = 0x130
leaq -0x30(%rbp), %rdi
callq 0x20080
movss %xmm0, -0x3c(%rbp)
movq -0x20(%rbp), %rdi
movss -0x38(%rbp), %xmm0
movss -0x3c(%rbp), %xmm1
movss -0x34(%rbp), %xmm2
movss -0x34(%rbp), %xmm3
callq 0x12410
movss -0x38(%rbp), %xmm0
subss -0x34(%rbp), %xmm0
movss -0x3c(%rbp), %xmm1
subss -0x34(%rbp), %xmm1
movss -0x34(%rbp), %xmm2
addss -0x34(%rbp), %xmm2
movss -0x34(%rbp), %xmm3
addss -0x34(%rbp), %xmm3
leaq -0x10(%rbp), %rdi
callq 0x14ee0
movsd -0x10(%rbp), %xmm0
movsd -0x8(%rbp), %xmm1
addq $0x50, %rsp
popq %rbp
retq
| _ZN7lunasvg16SVGCircleElement11updateShapeERNS_4PathE:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_18], rdi
mov [rbp+var_20], rsi
mov rsi, [rbp+var_18]
mov [rbp+var_48], rsi
lea rdi, [rbp+var_30]
xor edx, edx
call _ZN7lunasvg13LengthContextC2EPKNS_10SVGElementENS_5UnitsE; lunasvg::LengthContext::LengthContext(lunasvg::SVGElement const*,lunasvg::Units)
mov rsi, [rbp+var_48]
add rsi, 148h; lunasvg::SVGLength *
lea rdi, [rbp+var_30]; this
call _ZNK7lunasvg13LengthContext14valueForLengthERKNS_9SVGLengthE; lunasvg::LengthContext::valueForLength(lunasvg::SVGLength const&)
movss [rbp+var_34], xmm0
xorps xmm0, xmm0
ucomiss xmm0, [rbp+var_34]
jb short loc_2E920
lea rax, _ZN7lunasvg4Rect5EmptyE; lunasvg::Rect::Empty
mov rcx, [rax]
mov [rbp+var_10], rcx
mov rax, [rax+8]
mov [rbp+var_8], rax
jmp loc_2E9A0
loc_2E920:
mov rsi, [rbp+var_48]
add rsi, 118h; lunasvg::SVGLength *
lea rdi, [rbp+var_30]; this
call _ZNK7lunasvg13LengthContext14valueForLengthERKNS_9SVGLengthE; lunasvg::LengthContext::valueForLength(lunasvg::SVGLength const&)
mov rsi, [rbp+var_48]
movss [rbp+var_38], xmm0
add rsi, 130h; lunasvg::SVGLength *
lea rdi, [rbp+var_30]; this
call _ZNK7lunasvg13LengthContext14valueForLengthERKNS_9SVGLengthE; lunasvg::LengthContext::valueForLength(lunasvg::SVGLength const&)
movss [rbp+var_3C], xmm0
mov rdi, [rbp+var_20]; this
movss xmm0, [rbp+var_38]; float
movss xmm1, [rbp+var_3C]; float
movss xmm2, [rbp+var_34]; float
movss xmm3, [rbp+var_34]; float
call _ZN7lunasvg4Path10addEllipseEffff; lunasvg::Path::addEllipse(float,float,float,float)
movss xmm0, [rbp+var_38]
subss xmm0, [rbp+var_34]; float
movss xmm1, [rbp+var_3C]
subss xmm1, [rbp+var_34]; float
movss xmm2, [rbp+var_34]
addss xmm2, [rbp+var_34]; float
movss xmm3, [rbp+var_34]
addss xmm3, [rbp+var_34]; float
lea rdi, [rbp+var_10]; this
call _ZN7lunasvg4RectC2Effff; lunasvg::Rect::Rect(float,float,float,float)
loc_2E9A0:
movsd xmm0, [rbp+var_10]
movsd xmm1, [rbp+var_8]
add rsp, 50h
pop rbp
retn
| double lunasvg::SVGCircleElement::updateShape(lunasvg::SVGCircleElement *this, lunasvg::Path *a2)
{
float v3; // [rsp+14h] [rbp-3Ch]
float v4; // [rsp+18h] [rbp-38h]
float v5; // [rsp+1Ch] [rbp-34h]
_BYTE v6[16]; // [rsp+20h] [rbp-30h] BYREF
lunasvg::Path *v7; // [rsp+30h] [rbp-20h]
lunasvg::SVGCircleElement *v8; // [rsp+38h] [rbp-18h]
_QWORD v9[2]; // [rsp+40h] [rbp-10h] BYREF
v8 = this;
v7 = a2;
lunasvg::LengthContext::LengthContext((long long)v6, (long long)this, 0);
v5 = lunasvg::LengthContext::valueForLength(
(lunasvg::LengthContext *)v6,
(lunasvg::SVGCircleElement *)((char *)this + 328));
if ( v5 > 0.0 )
{
v4 = lunasvg::LengthContext::valueForLength(
(lunasvg::LengthContext *)v6,
(lunasvg::SVGCircleElement *)((char *)this + 280));
v3 = lunasvg::LengthContext::valueForLength(
(lunasvg::LengthContext *)v6,
(lunasvg::SVGCircleElement *)((char *)this + 304));
lunasvg::Path::addEllipse(v7, v4, v3, v5, v5);
lunasvg::Rect::Rect((lunasvg::Rect *)v9, v4 - v5, v3 - v5, v5 + v5, v5 + v5);
}
else
{
v9[0] = lunasvg::Rect::Empty;
v9[1] = *(&lunasvg::Rect::Empty + 1);
}
return *(double *)v9;
}
| updateShape:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x18],RDI
MOV qword ptr [RBP + -0x20],RSI
MOV RSI,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x48],RSI
LEA RDI,[RBP + -0x30]
XOR EDX,EDX
CALL 0x00120050
MOV RSI,qword ptr [RBP + -0x48]
ADD RSI,0x148
LEA RDI,[RBP + -0x30]
CALL 0x00120080
MOVSS dword ptr [RBP + -0x34],XMM0
XORPS XMM0,XMM0
UCOMISS XMM0,dword ptr [RBP + -0x34]
JC 0x0012e920
LEA RAX,[0x18c158]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RBP + -0x10],RCX
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0012e9a0
LAB_0012e920:
MOV RSI,qword ptr [RBP + -0x48]
ADD RSI,0x118
LEA RDI,[RBP + -0x30]
CALL 0x00120080
MOV RSI,qword ptr [RBP + -0x48]
MOVSS dword ptr [RBP + -0x38],XMM0
ADD RSI,0x130
LEA RDI,[RBP + -0x30]
CALL 0x00120080
MOVSS dword ptr [RBP + -0x3c],XMM0
MOV RDI,qword ptr [RBP + -0x20]
MOVSS XMM0,dword ptr [RBP + -0x38]
MOVSS XMM1,dword ptr [RBP + -0x3c]
MOVSS XMM2,dword ptr [RBP + -0x34]
MOVSS XMM3,dword ptr [RBP + -0x34]
CALL 0x00112410
MOVSS XMM0,dword ptr [RBP + -0x38]
SUBSS XMM0,dword ptr [RBP + -0x34]
MOVSS XMM1,dword ptr [RBP + -0x3c]
SUBSS XMM1,dword ptr [RBP + -0x34]
MOVSS XMM2,dword ptr [RBP + -0x34]
ADDSS XMM2,dword ptr [RBP + -0x34]
MOVSS XMM3,dword ptr [RBP + -0x34]
ADDSS XMM3,dword ptr [RBP + -0x34]
LEA RDI,[RBP + -0x10]
CALL 0x00114ee0
LAB_0012e9a0:
MOVSD XMM0,qword ptr [RBP + -0x10]
MOVSD XMM1,qword ptr [RBP + -0x8]
ADD RSP,0x50
POP RBP
RET
|
/* lunasvg::SVGCircleElement::updateShape(lunasvg::Path&) */
int1 [16] __thiscall
lunasvg::SVGCircleElement::updateShape(SVGCircleElement *this,Path *param_1)
{
int1 auVar1 [16];
float fVar2;
float fVar3;
float fVar4;
LengthContext local_38 [16];
Path *local_28;
SVGCircleElement *local_20;
int8 local_18;
int8 local_10;
local_28 = param_1;
local_20 = this;
LengthContext::LengthContext(local_38,this,0);
fVar2 = (float)LengthContext::valueForLength(local_38,(SVGLength *)(this + 0x148));
if (0.0 < fVar2) {
fVar3 = (float)LengthContext::valueForLength(local_38,(SVGLength *)(this + 0x118));
fVar4 = (float)LengthContext::valueForLength(local_38,(SVGLength *)(this + 0x130));
Path::addEllipse(local_28,fVar3,fVar4,fVar2,fVar2);
Rect::Rect((Rect *)&local_18,fVar3 - fVar2,fVar4 - fVar2,fVar2 + fVar2,fVar2 + fVar2);
}
else {
local_18 = Rect::Empty;
local_10 = DAT_0018c160;
}
auVar1._8_8_ = local_10;
auVar1._0_8_ = local_18;
return auVar1;
}
| |
21,484 | lunasvg::SVGCircleElement::updateShape(lunasvg::Path&) | dmazzella[P]pylunasvg/lunasvg/source/svggeometryelement.cpp | Rect SVGCircleElement::updateShape(Path& path)
{
LengthContext lengthContext(this);
auto r = lengthContext.valueForLength(m_r);
if(r <= 0.f) {
return Rect::Empty;
}
auto cx = lengthContext.valueForLength(m_cx);
auto cy = lengthContext.valueForLength(m_cy);
path.addEllipse(cx, cy, r, r);
return Rect(cx - r, cy - r, r + r, r + r);
} | O1 | cpp | lunasvg::SVGCircleElement::updateShape(lunasvg::Path&):
pushq %r15
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x30(%rsp), %rdi
movq %r14, (%rdi)
movb $0x0, 0x8(%rdi)
leaq 0x154(%r14), %rsi
movzbl 0x151(%r14), %edx
callq 0x1f7ea
xorps %xmm1, %xmm1
ucomiss %xmm0, %xmm1
jae 0x14cf8
leaq 0x124(%r14), %rsi
movzbl 0x121(%r14), %edx
leaq 0x30(%rsp), %r15
movq %r15, %rdi
movaps %xmm0, (%rsp)
callq 0x1f7ea
movaps %xmm0, 0x10(%rsp)
movzbl 0x139(%r14), %edx
addq $0x13c, %r14 # imm = 0x13C
movq %r15, %rdi
movq %r14, %rsi
callq 0x1f7ea
movaps %xmm0, %xmm1
movaps %xmm0, 0x20(%rsp)
movq %rbx, %rdi
movaps 0x10(%rsp), %xmm0
movaps (%rsp), %xmm2
movaps (%rsp), %xmm3
callq 0xd072
movaps 0x10(%rsp), %xmm0
movaps (%rsp), %xmm1
subss %xmm1, %xmm0
movaps 0x20(%rsp), %xmm2
subss %xmm1, %xmm2
unpcklps %xmm2, %xmm0 # xmm0 = xmm0[0],xmm2[0],xmm0[1],xmm2[1]
addss %xmm1, %xmm1
shufps $0x0, %xmm1, %xmm1 # xmm1 = xmm1[0,0,0,0]
jmp 0x14d08
leaq 0x2e47d(%rip), %rax # 0x4317c
movsd (%rax), %xmm0
movsd 0x8(%rax), %xmm1
addq $0x40, %rsp
popq %rbx
popq %r14
popq %r15
retq
| _ZN7lunasvg16SVGCircleElement11updateShapeERNS_4PathE:
push r15
push r14
push rbx
sub rsp, 40h
mov rbx, rsi
mov r14, rdi
lea rdi, [rsp+58h+var_28]
mov [rdi], r14
mov byte ptr [rdi+8], 0
lea rsi, [r14+154h]
movzx edx, byte ptr [r14+151h]
call _ZNK7lunasvg13LengthContext14valueForLengthERKNS_6LengthENS_15LengthDirectionE; lunasvg::LengthContext::valueForLength(lunasvg::Length const&,lunasvg::LengthDirection)
xorps xmm1, xmm1
ucomiss xmm1, xmm0
jnb short loc_14CF8
lea rsi, [r14+124h]
movzx edx, byte ptr [r14+121h]
lea r15, [rsp+58h+var_28]
mov rdi, r15
movaps xmmword ptr [rsp+58h+var_58], xmm0
call _ZNK7lunasvg13LengthContext14valueForLengthERKNS_6LengthENS_15LengthDirectionE; lunasvg::LengthContext::valueForLength(lunasvg::Length const&,lunasvg::LengthDirection)
movaps xmmword ptr [rsp+58h+var_48], xmm0
movzx edx, byte ptr [r14+139h]
add r14, 13Ch
mov rdi, r15
mov rsi, r14
call _ZNK7lunasvg13LengthContext14valueForLengthERKNS_6LengthENS_15LengthDirectionE; lunasvg::LengthContext::valueForLength(lunasvg::Length const&,lunasvg::LengthDirection)
movaps xmm1, xmm0; float
movaps [rsp+58h+var_38], xmm0
mov rdi, rbx; this
movaps xmm0, xmmword ptr [rsp+58h+var_48]; float
movaps xmm2, xmmword ptr [rsp+58h+var_58]; float
movaps xmm3, xmmword ptr [rsp+58h+var_58]; float
call _ZN7lunasvg4Path10addEllipseEffff; lunasvg::Path::addEllipse(float,float,float,float)
movaps xmm0, xmmword ptr [rsp+58h+var_48]
movaps xmm1, xmmword ptr [rsp+58h+var_58]
subss xmm0, xmm1
movaps xmm2, [rsp+58h+var_38]
subss xmm2, xmm1
unpcklps xmm0, xmm2
addss xmm1, xmm1
shufps xmm1, xmm1, 0
jmp short loc_14D08
loc_14CF8:
lea rax, _ZN7lunasvg4Rect5EmptyE; lunasvg::Rect::Empty
movsd xmm0, qword ptr [rax]
movsd xmm1, qword ptr [rax+8]
loc_14D08:
add rsp, 40h
pop rbx
pop r14
pop r15
retn
| double lunasvg::SVGCircleElement::updateShape(lunasvg::SVGCircleElement *this, lunasvg::Path *a2, __m128 a3)
{
__m128 v3; // xmm0
__m128 v4; // xmm2
double result; // xmm0_8
float v6; // [rsp+0h] [rbp-58h]
__m128 v7; // [rsp+10h] [rbp-48h]
__m128 v8; // [rsp+20h] [rbp-38h]
lunasvg::SVGCircleElement *v9; // [rsp+30h] [rbp-28h] BYREF
char v10; // [rsp+38h] [rbp-20h]
v9 = this;
v10 = 0;
*(double *)a3.m128_u64 = lunasvg::LengthContext::valueForLength(&v9, (char *)v9 + 340, *((unsigned __int8 *)v9 + 337));
if ( a3.m128_f32[0] <= 0.0 )
return *(double *)lunasvg::Rect::Empty;
v6 = a3.m128_f32[0];
*(double *)a3.m128_u64 = lunasvg::LengthContext::valueForLength(
&v9,
(char *)this + 292,
*((unsigned __int8 *)this + 289));
v7 = a3;
*(double *)a3.m128_u64 = lunasvg::LengthContext::valueForLength(
&v9,
(char *)this + 316,
*((unsigned __int8 *)this + 313));
v8 = a3;
lunasvg::Path::addEllipse(a2, v7.m128_f32[0], a3.m128_f32[0], v6, v6);
v3 = v7;
v3.m128_f32[0] = v7.m128_f32[0] - v6;
v4 = v8;
v4.m128_f32[0] = v8.m128_f32[0] - v6;
*(_QWORD *)&result = _mm_unpacklo_ps(v3, v4).m128_u64[0];
return result;
}
| updateShape:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x40
MOV RBX,RSI
MOV R14,RDI
LEA RDI,[RSP + 0x30]
MOV qword ptr [RDI],R14
MOV byte ptr [RDI + 0x8],0x0
LEA RSI,[R14 + 0x154]
MOVZX EDX,byte ptr [R14 + 0x151]
CALL 0x0011f7ea
XORPS XMM1,XMM1
UCOMISS XMM1,XMM0
JNC 0x00114cf8
LEA RSI,[R14 + 0x124]
MOVZX EDX,byte ptr [R14 + 0x121]
LEA R15,[RSP + 0x30]
MOV RDI,R15
MOVAPS xmmword ptr [RSP],XMM0
CALL 0x0011f7ea
MOVAPS xmmword ptr [RSP + 0x10],XMM0
MOVZX EDX,byte ptr [R14 + 0x139]
ADD R14,0x13c
MOV RDI,R15
MOV RSI,R14
CALL 0x0011f7ea
MOVAPS XMM1,XMM0
MOVAPS xmmword ptr [RSP + 0x20],XMM0
MOV RDI,RBX
MOVAPS XMM0,xmmword ptr [RSP + 0x10]
MOVAPS XMM2,xmmword ptr [RSP]
MOVAPS XMM3,xmmword ptr [RSP]
CALL 0x0010d072
MOVAPS XMM0,xmmword ptr [RSP + 0x10]
MOVAPS XMM1,xmmword ptr [RSP]
SUBSS XMM0,XMM1
MOVAPS XMM2,xmmword ptr [RSP + 0x20]
SUBSS XMM2,XMM1
UNPCKLPS XMM0,XMM2
ADDSS XMM1,XMM1
SHUFPS XMM1,XMM1,0x0
JMP 0x00114d08
LAB_00114cf8:
LEA RAX,[0x14317c]
MOVSD XMM0,qword ptr [RAX]
MOVSD XMM1,qword ptr [RAX + 0x8]
LAB_00114d08:
ADD RSP,0x40
POP RBX
POP R14
POP R15
RET
|
/* lunasvg::SVGCircleElement::updateShape(lunasvg::Path&) */
int8 __thiscall lunasvg::SVGCircleElement::updateShape(SVGCircleElement *this,Path *param_1)
{
float fVar1;
float fVar2;
float fVar3;
SVGCircleElement *local_28;
int1 local_20;
local_20 = 0;
local_28 = this;
fVar1 = (float)LengthContext::valueForLength((LengthContext *)&local_28,this + 0x154,this[0x151]);
if (fVar1 <= 0.0) {
fVar2 = (float)Rect::Empty;
fVar3 = (float)((ulong)Rect::Empty >> 0x20);
}
else {
fVar2 = (float)LengthContext::valueForLength
((LengthContext *)&local_28,this + 0x124,this[0x121]);
fVar3 = (float)LengthContext::valueForLength
((LengthContext *)&local_28,this + 0x13c,this[0x139]);
Path::addEllipse(param_1,fVar2,fVar3,fVar1,fVar1);
fVar2 = fVar2 - fVar1;
fVar3 = fVar3 - fVar1;
}
return CONCAT44(fVar3,fVar2);
}
| |
21,485 | flush_partitioned_key_cache_blocks | eloqsql/mysys/mf_keycache.c | static
int flush_partitioned_key_cache_blocks(PARTITIONED_KEY_CACHE_CB *keycache,
File file, void *file_extra,
enum flush_type type)
{
uint i;
uint partitions= keycache->partitions;
int err= 0;
ulonglong *dirty_part_map= (ulonglong *) file_extra;
DBUG_ENTER("partitioned_flush_key_blocks");
DBUG_PRINT("enter", ("keycache: %p", keycache));
for (i= 0; i < partitions; i++)
{
SIMPLE_KEY_CACHE_CB *partition= keycache->partition_array[i];
if ((type == FLUSH_KEEP || type == FLUSH_FORCE_WRITE) &&
!((*dirty_part_map) & ((ulonglong) 1 << i)))
continue;
err|= MY_TEST(flush_simple_key_cache_blocks(partition, file, 0, type));
}
*dirty_part_map= 0;
DBUG_RETURN(err);
} | O3 | c | flush_partitioned_key_cache_blocks:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, -0x38(%rbp)
movl %esi, -0x2c(%rbp)
movl 0x1c(%rdi), %ebx
testq %rbx, %rbx
je 0x568d8
movl %ecx, %r14d
movq %rdi, %r12
xorl %r15d, %r15d
xorl %r13d, %r13d
movq 0x8(%r12), %rax
movq (%rax,%r15,8), %rdi
cmpl $0x3, %r14d
je 0x568ac
testl %r14d, %r14d
jne 0x568b9
movq -0x38(%rbp), %rax
movq (%rax), %rax
btq %r15, %rax
jae 0x568ce
movl -0x2c(%rbp), %esi
movl %r14d, %ecx
callq 0x556e7
xorl %ecx, %ecx
testl %eax, %eax
setne %cl
orl %ecx, %r13d
incq %r15
cmpq %r15, %rbx
jne 0x56898
jmp 0x568db
xorl %r13d, %r13d
movq -0x38(%rbp), %rax
movq $0x0, (%rax)
movl %r13d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| flush_partitioned_key_cache_blocks:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov [rbp+var_38], rdx
mov [rbp+var_2C], esi
mov ebx, [rdi+1Ch]
test rbx, rbx
jz short loc_568D8
mov r14d, ecx
mov r12, rdi
xor r15d, r15d
xor r13d, r13d
loc_56898:
mov rax, [r12+8]
mov rdi, [rax+r15*8]
cmp r14d, 3
jz short loc_568AC
test r14d, r14d
jnz short loc_568B9
loc_568AC:
mov rax, [rbp+var_38]
mov rax, [rax]
bt rax, r15
jnb short loc_568CE
loc_568B9:
mov esi, [rbp+var_2C]
mov ecx, r14d
call flush_simple_key_cache_blocks
xor ecx, ecx
test eax, eax
setnz cl
or r13d, ecx
loc_568CE:
inc r15
cmp rbx, r15
jnz short loc_56898
jmp short loc_568DB
loc_568D8:
xor r13d, r13d
loc_568DB:
mov rax, [rbp+var_38]
mov qword ptr [rax], 0
mov eax, r13d
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long flush_partitioned_key_cache_blocks(long long a1, unsigned int a2, long long *a3, unsigned int a4)
{
long long v4; // rbx
unsigned long long v6; // r15
unsigned int v7; // r13d
long long v8; // rax
v4 = *(unsigned int *)(a1 + 28);
if ( *(_DWORD *)(a1 + 28) )
{
v6 = 0LL;
v7 = 0;
do
{
if ( a4 != 3 && a4 || (v8 = *a3, _bittest64(&v8, v6)) )
v7 |= (unsigned int)flush_simple_key_cache_blocks(
*(_QWORD *)(*(_QWORD *)(a1 + 8) + 8 * v6),
a2,
(long long)a3,
a4) != 0;
++v6;
}
while ( v4 != v6 );
}
else
{
v7 = 0;
}
*a3 = 0LL;
return v7;
}
| flush_partitioned_key_cache_blocks:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV qword ptr [RBP + -0x38],RDX
MOV dword ptr [RBP + -0x2c],ESI
MOV EBX,dword ptr [RDI + 0x1c]
TEST RBX,RBX
JZ 0x001568d8
MOV R14D,ECX
MOV R12,RDI
XOR R15D,R15D
XOR R13D,R13D
LAB_00156898:
MOV RAX,qword ptr [R12 + 0x8]
MOV RDI,qword ptr [RAX + R15*0x8]
CMP R14D,0x3
JZ 0x001568ac
TEST R14D,R14D
JNZ 0x001568b9
LAB_001568ac:
MOV RAX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RAX]
BT RAX,R15
JNC 0x001568ce
LAB_001568b9:
MOV ESI,dword ptr [RBP + -0x2c]
MOV ECX,R14D
CALL 0x001556e7
XOR ECX,ECX
TEST EAX,EAX
SETNZ CL
OR R13D,ECX
LAB_001568ce:
INC R15
CMP RBX,R15
JNZ 0x00156898
JMP 0x001568db
LAB_001568d8:
XOR R13D,R13D
LAB_001568db:
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RAX],0x0
MOV EAX,R13D
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
byte flush_partitioned_key_cache_blocks(long param_1,int4 param_2,ulong *param_3,int param_4)
{
uint uVar1;
int iVar2;
ulong *extraout_RDX;
ulong *puVar3;
byte bVar4;
ulong uVar5;
uVar1 = *(uint *)(param_1 + 0x1c);
if ((ulong)uVar1 == 0) {
bVar4 = 0;
}
else {
uVar5 = 0;
bVar4 = 0;
puVar3 = param_3;
do {
if (((param_4 != 3) && (param_4 != 0)) || ((*param_3 >> (uVar5 & 0x3f) & 1) != 0)) {
iVar2 = flush_simple_key_cache_blocks
(*(int8 *)(*(long *)(param_1 + 8) + uVar5 * 8),param_2,puVar3,
param_4);
bVar4 = bVar4 | iVar2 != 0;
puVar3 = extraout_RDX;
}
uVar5 = uVar5 + 1;
} while (uVar1 != uVar5);
}
*param_3 = 0;
return bVar4;
}
| |
21,486 | pagecache_delete_by_link | eloqsql/storage/maria/ma_pagecache.c | my_bool pagecache_delete_by_link(PAGECACHE *pagecache,
PAGECACHE_BLOCK_LINK *block,
enum pagecache_page_lock lock,
my_bool flush)
{
my_bool error= 0;
enum pagecache_page_pin pin= PAGECACHE_PIN_LEFT_PINNED;
DBUG_ENTER("pagecache_delete_by_link");
DBUG_PRINT("enter", ("fd: %d block %p %s %s",
block->hash_link->file.file,
block,
page_cache_page_lock_str[lock],
page_cache_page_pin_str[pin]));
DBUG_ASSERT(lock == PAGECACHE_LOCK_WRITE ||
lock == PAGECACHE_LOCK_LEFT_WRITELOCKED);
DBUG_ASSERT(block->pins != 0); /* should be pinned */
if (pagecache->can_be_used)
{
pagecache_pthread_mutex_lock(&pagecache->cache_lock);
if (!pagecache->can_be_used)
goto end;
/*
This block should be pinned (i.e. has not zero request counter) =>
Such block can't be chosen for eviction.
*/
DBUG_ASSERT((block->status &
(PCBLOCK_IN_SWITCH | PCBLOCK_REASSIGNED)) == 0);
/* This lock is deleted in pagecache_delete_internal() called below */
inc_counter_for_resize_op(pagecache);
/*
make_lock_and_pin() can't fail here, because we are keeping pin on the
block and it can't be evicted (which is cause of lock fail and retry)
*/
if (make_lock_and_pin(pagecache, block, lock, pin, FALSE))
DBUG_ASSERT(0);
/*
get_present_hash_link() side effect emulation before call
pagecache_delete_internal()
*/
block->hash_link->requests++;
error= pagecache_delete_internal(pagecache, block, block->hash_link,
flush);
end:
pagecache_pthread_mutex_unlock(&pagecache->cache_lock);
}
DBUG_RETURN(error);
} | O3 | c | pagecache_delete_by_link:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
cmpb $0x0, 0x1aa(%rdi)
je 0x4d0ec
movl %ecx, %r12d
movl %edx, %r13d
movq %rsi, %r15
movq %rdi, %r14
leaq 0xc8(%rdi), %rbx
cmpq $0x0, 0x108(%rdi)
jne 0x4d11a
movq %rbx, %rdi
callq 0x2a230
cmpb $0x0, 0x1aa(%r14)
je 0x4d0f1
incq 0x68(%r14)
movq %r14, %rdi
movq %r15, %rsi
movl %r13d, %edx
xorl %ecx, %ecx
callq 0x4bba3
movq 0x20(%r15), %rax
incl 0x68(%rax)
movq 0x20(%r15), %rdx
movsbl %r12b, %ecx
movq %r14, %rdi
movq %r15, %rsi
callq 0x4d145
movl %eax, %r15d
jmp 0x4d0f4
xorl %r15d, %r15d
jmp 0x4d108
xorl %r15d, %r15d
movq 0x108(%r14), %rdi
testq %rdi, %rdi
jne 0x4d133
movq %rbx, %rdi
callq 0x2a1f0
movl %r15d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xacc81(%rip), %rsi # 0xf9da2
movq %rbx, %rdi
movl $0x1002, %edx # imm = 0x1002
callq 0x312ea
jmp 0x4d0af
leaq 0x3618de(%rip), %rax # 0x3aea18
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x4d100
| pagecache_delete_by_link:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
cmp byte ptr [rdi+1AAh], 0
jz short loc_4D0EC
mov r12d, ecx
mov r13d, edx
mov r15, rsi
mov r14, rdi
lea rbx, [rdi+0C8h]
cmp qword ptr [rdi+108h], 0
jnz short loc_4D11A
mov rdi, rbx
call _pthread_mutex_lock
loc_4D0AF:
cmp byte ptr [r14+1AAh], 0
jz short loc_4D0F1
inc qword ptr [r14+68h]
mov rdi, r14
mov rsi, r15
mov edx, r13d
xor ecx, ecx
call make_lock_and_pin
mov rax, [r15+20h]
inc dword ptr [rax+68h]
mov rdx, [r15+20h]
movsx ecx, r12b
mov rdi, r14
mov rsi, r15
call pagecache_delete_internal
mov r15d, eax
jmp short loc_4D0F4
loc_4D0EC:
xor r15d, r15d
jmp short loc_4D108
loc_4D0F1:
xor r15d, r15d
loc_4D0F4:
mov rdi, [r14+108h]
test rdi, rdi
jnz short loc_4D133
loc_4D100:
mov rdi, rbx
call _pthread_mutex_unlock
loc_4D108:
mov eax, r15d
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_4D11A:
lea rsi, aWorkspaceLlm4b_33; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, rbx
mov edx, 1002h
call psi_mutex_lock
jmp loc_4D0AF
loc_4D133:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp short loc_4D100
| long long pagecache_delete_by_link(long long a1, long long a2, int a3, char a4)
{
long long v6; // rbx
unsigned int v7; // r15d
long long v8; // rdi
if ( *(_BYTE *)(a1 + 426) )
{
v6 = a1 + 200;
if ( *(_QWORD *)(a1 + 264) )
psi_mutex_lock(
a1 + 200,
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c",
0x1002u);
else
pthread_mutex_lock(a1 + 200);
if ( *(_BYTE *)(a1 + 426) )
{
++*(_QWORD *)(a1 + 104);
make_lock_and_pin(a1, a2, a3, 0);
++*(_DWORD *)(*(_QWORD *)(a2 + 32) + 104LL);
v7 = pagecache_delete_internal(a1, a2, *(_QWORD *)(a2 + 32), (unsigned int)a4);
}
else
{
v7 = 0;
}
v8 = *(_QWORD *)(a1 + 264);
if ( v8 )
((void ( *)(long long))PSI_server[44])(v8);
pthread_mutex_unlock(v6);
}
else
{
return 0;
}
return v7;
}
| pagecache_delete_by_link:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
CMP byte ptr [RDI + 0x1aa],0x0
JZ 0x0014d0ec
MOV R12D,ECX
MOV R13D,EDX
MOV R15,RSI
MOV R14,RDI
LEA RBX,[RDI + 0xc8]
CMP qword ptr [RDI + 0x108],0x0
JNZ 0x0014d11a
MOV RDI,RBX
CALL 0x0012a230
LAB_0014d0af:
CMP byte ptr [R14 + 0x1aa],0x0
JZ 0x0014d0f1
INC qword ptr [R14 + 0x68]
MOV RDI,R14
MOV RSI,R15
MOV EDX,R13D
XOR ECX,ECX
CALL 0x0014bba3
MOV RAX,qword ptr [R15 + 0x20]
INC dword ptr [RAX + 0x68]
MOV RDX,qword ptr [R15 + 0x20]
MOVSX ECX,R12B
MOV RDI,R14
MOV RSI,R15
CALL 0x0014d145
MOV R15D,EAX
JMP 0x0014d0f4
LAB_0014d0ec:
XOR R15D,R15D
JMP 0x0014d108
LAB_0014d0f1:
XOR R15D,R15D
LAB_0014d0f4:
MOV RDI,qword ptr [R14 + 0x108]
TEST RDI,RDI
JNZ 0x0014d133
LAB_0014d100:
MOV RDI,RBX
CALL 0x0012a1f0
LAB_0014d108:
MOV EAX,R15D
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0014d11a:
LEA RSI,[0x1f9da2]
MOV RDI,RBX
MOV EDX,0x1002
CALL 0x001312ea
JMP 0x0014d0af
LAB_0014d133:
LEA RAX,[0x4aea18]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x0014d100
|
int4 pagecache_delete_by_link(long param_1,long param_2,int4 param_3,char param_4)
{
int *piVar1;
pthread_mutex_t *__mutex;
int4 uVar2;
if (*(char *)(param_1 + 0x1aa) == '\0') {
uVar2 = 0;
}
else {
__mutex = (pthread_mutex_t *)(param_1 + 200);
if (*(long *)(param_1 + 0x108) == 0) {
pthread_mutex_lock(__mutex);
}
else {
psi_mutex_lock(__mutex,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c"
,0x1002);
}
if (*(char *)(param_1 + 0x1aa) == '\0') {
uVar2 = 0;
}
else {
*(long *)(param_1 + 0x68) = *(long *)(param_1 + 0x68) + 1;
make_lock_and_pin(param_1,param_2,param_3,0);
piVar1 = (int *)(*(long *)(param_2 + 0x20) + 0x68);
*piVar1 = *piVar1 + 1;
uVar2 = pagecache_delete_internal
(param_1,param_2,*(int8 *)(param_2 + 0x20),(int)param_4);
}
if (*(long *)(param_1 + 0x108) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
}
return uVar2;
}
| |
21,487 | decode_pos | eloqsql/storage/maria/ma_packrec.c | static uint decode_pos(MARIA_BIT_BUFF *bit_buff,
MARIA_DECODE_TREE *decode_tree)
{
uint16 *pos=decode_tree->table;
for (;;)
{
if (get_bit(bit_buff))
pos++;
if (*pos & IS_CHAR)
return (uint) (*pos & ~IS_CHAR);
pos+= *pos;
}
} | O0 | c | decode_pos:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x0, 0x4(%rax)
je 0x4c2ea
movq -0x8(%rbp), %rax
movl (%rax), %eax
movq -0x8(%rbp), %rdx
movl 0x4(%rdx), %ecx
addl $-0x1, %ecx
movl %ecx, 0x4(%rdx)
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
jne 0x4c30e
jmp 0x4c31a
movq -0x8(%rbp), %rdi
callq 0x4ab70
movq -0x8(%rbp), %rax
movl $0x1f, 0x4(%rax)
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x80000000, %eax # imm = 0x80000000
cmpl $0x0, %eax
je 0x4c31a
movq -0x18(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movzwl (%rax), %eax
andl $0x8000, %eax # imm = 0x8000
cmpl $0x0, %eax
je 0x4c33d
movq -0x18(%rbp), %rax
movzwl (%rax), %eax
andl $0xffff7fff, %eax # imm = 0xFFFF7FFF
addq $0x20, %rsp
popq %rbp
retq
movq -0x18(%rbp), %rax
movzwl (%rax), %ecx
movq -0x18(%rbp), %rax
movslq %ecx, %rcx
shlq %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
jmp 0x4c2bb
nopw (%rax,%rax)
| decode_pos:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_10]
mov rax, [rax]
mov [rbp+var_18], rax
loc_4C2BB:
mov rax, [rbp+var_8]
cmp dword ptr [rax+4], 0
jz short loc_4C2EA
mov rax, [rbp+var_8]
mov eax, [rax]
mov rdx, [rbp+var_8]
mov ecx, [rdx+4]
add ecx, 0FFFFFFFFh
mov [rdx+4], ecx
mov edx, 1
shl edx, cl
mov ecx, edx
and eax, ecx
cmp eax, 0
jnz short loc_4C30E
jmp short loc_4C31A
loc_4C2EA:
mov rdi, [rbp+var_8]
call fill_buffer
mov rax, [rbp+var_8]
mov dword ptr [rax+4], 1Fh
mov rax, [rbp+var_8]
mov eax, [rax]
and eax, 80000000h
cmp eax, 0
jz short loc_4C31A
loc_4C30E:
mov rax, [rbp+var_18]
add rax, 2
mov [rbp+var_18], rax
loc_4C31A:
mov rax, [rbp+var_18]
movzx eax, word ptr [rax]
and eax, 8000h
cmp eax, 0
jz short loc_4C33D
mov rax, [rbp+var_18]
movzx eax, word ptr [rax]
and eax, 0FFFF7FFFh
add rsp, 20h
pop rbp
retn
loc_4C33D:
mov rax, [rbp+var_18]
movzx ecx, word ptr [rax]
mov rax, [rbp+var_18]
movsxd rcx, ecx
shl rcx, 1
add rax, rcx
mov [rbp+var_18], rax
jmp loc_4C2BB
| long long decode_pos(int *a1, _WORD **a2)
{
int v2; // eax
int v3; // ecx
_WORD *i; // [rsp+8h] [rbp-18h]
for ( i = *a2; ; i += (unsigned __int16)*i )
{
if ( !a1[1] )
{
fill_buffer((long long)a1);
a1[1] = 31;
if ( *a1 >= 0 )
goto LABEL_7;
LABEL_6:
++i;
goto LABEL_7;
}
v2 = *a1;
v3 = a1[1] - 1;
a1[1] = v3;
if ( ((1 << v3) & v2) != 0 )
goto LABEL_6;
LABEL_7:
if ( (*i & 0x8000) != 0 )
break;
}
return *i & 0x7FFF;
}
| decode_pos:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x18],RAX
LAB_0014c2bb:
MOV RAX,qword ptr [RBP + -0x8]
CMP dword ptr [RAX + 0x4],0x0
JZ 0x0014c2ea
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX]
MOV RDX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RDX + 0x4]
ADD ECX,-0x1
MOV dword ptr [RDX + 0x4],ECX
MOV EDX,0x1
SHL EDX,CL
MOV ECX,EDX
AND EAX,ECX
CMP EAX,0x0
JNZ 0x0014c30e
JMP 0x0014c31a
LAB_0014c2ea:
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x0014ab70
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x4],0x1f
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX]
AND EAX,0x80000000
CMP EAX,0x0
JZ 0x0014c31a
LAB_0014c30e:
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x2
MOV qword ptr [RBP + -0x18],RAX
LAB_0014c31a:
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,word ptr [RAX]
AND EAX,0x8000
CMP EAX,0x0
JZ 0x0014c33d
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,word ptr [RAX]
AND EAX,0xffff7fff
ADD RSP,0x20
POP RBP
RET
LAB_0014c33d:
MOV RAX,qword ptr [RBP + -0x18]
MOVZX ECX,word ptr [RAX]
MOV RAX,qword ptr [RBP + -0x18]
MOVSXD RCX,ECX
SHL RCX,0x1
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
JMP 0x0014c2bb
|
ushort decode_pos(uint *param_1,int8 *param_2)
{
uint uVar1;
ushort *local_20;
local_20 = (ushort *)*param_2;
while( true ) {
if (param_1[1] == 0) {
fill_buffer(param_1);
param_1[1] = 0x1f;
uVar1 = *param_1 & 0x80000000;
}
else {
uVar1 = param_1[1];
param_1[1] = uVar1 - 1;
uVar1 = *param_1 & 1 << ((byte)(uVar1 - 1) & 0x1f);
}
if (uVar1 != 0) {
local_20 = local_20 + 1;
}
if ((*local_20 & 0x8000) != 0) break;
local_20 = local_20 + (int)(uint)*local_20;
}
return *local_20 & 0x7fff;
}
| |
21,488 | mysql_real_connect_start_internal | eloqsql/libmariadb/libmariadb/mariadb_async.c | static void
mysql_real_connect_start_internal(void *d)
{
MK_ASYNC_INTERNAL_BODY(
mysql_real_connect,
(parms->mysql, parms->host, parms->user, parms->passwd, parms->db,
parms->port, parms->unix_socket, parms->client_flags),
parms->mysql,
MYSQL *,
r_ptr)
} | O0 | c | mysql_real_connect_start_internal:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %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
movq -0x10(%rbp), %rax
movq 0x20(%rax), %r8
movq -0x10(%rbp), %rax
movl 0x28(%rax), %r9d
movq -0x10(%rbp), %rax
movq 0x30(%rax), %r10
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rax
movq %r10, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x22ce0
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x20(%rbp), %rax
movl $0x0, (%rax)
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)
| mysql_real_connect_start_internal:
push rbp
mov rbp, rsp
sub rsp, 30h
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]
mov rax, [rbp+var_10]
mov r8, [rax+20h]
mov rax, [rbp+var_10]
mov r9d, [rax+28h]
mov rax, [rbp+var_10]
mov r10, [rax+30h]
mov rax, [rbp+var_10]
mov rax, [rax+38h]
mov [rsp+30h+var_30], r10
mov [rsp+30h+var_28], rax
call mysql_real_connect
mov [rbp+var_18], rax
mov rcx, [rbp+var_18]
mov rax, [rbp+var_20]
mov [rax+8], rcx
mov rax, [rbp+var_20]
mov dword ptr [rax], 0
add rsp, 30h
pop rbp
retn
| long long mysql_real_connect_start_internal(long long a1)
{
long long result; // rax
long long v2; // [rsp+10h] [rbp-20h]
v2 = *(_QWORD *)(*(_QWORD *)(*(_QWORD *)a1 + 1152LL) + 40LL);
*(_QWORD *)(v2 + 8) = mysql_real_connect(
*(_QWORD *)a1,
*(_QWORD *)(a1 + 8),
*(_QWORD *)(a1 + 16),
*(_QWORD *)(a1 + 24),
*(_QWORD *)(a1 + 32),
*(_DWORD *)(a1 + 40),
*(_QWORD *)(a1 + 48),
*(_QWORD *)(a1 + 56));
result = v2;
*(_DWORD *)v2 = 0;
return result;
}
| mysql_real_connect_start_internal:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
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]
MOV RAX,qword ptr [RBP + -0x10]
MOV R8,qword ptr [RAX + 0x20]
MOV RAX,qword ptr [RBP + -0x10]
MOV R9D,dword ptr [RAX + 0x28]
MOV RAX,qword ptr [RBP + -0x10]
MOV R10,qword ptr [RAX + 0x30]
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x38]
MOV qword ptr [RSP],R10
MOV qword ptr [RSP + 0x8],RAX
CALL 0x00122ce0
MOV qword ptr [RBP + -0x18],RAX
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX],0x0
ADD RSP,0x30
POP RBP
RET
|
void mysql_real_connect_start_internal(long *param_1)
{
int4 *puVar1;
int8 uVar2;
puVar1 = *(int4 **)(*(long *)(*param_1 + 0x480) + 0x28);
uVar2 = mysql_real_connect(*param_1,param_1[1],param_1[2],param_1[3],param_1[4],(int)param_1[5],
param_1[6],param_1[7]);
*(int8 *)(puVar1 + 2) = uVar2;
*puVar1 = 0;
return;
}
| |
21,489 | nglog::GetExistingTempDirectories(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&) | ng-log[P]ng-log/src/logging.cc | NGLOG_NO_EXPORT
void GetExistingTempDirectories(vector<string>& list) {
GetTempDirectories(list);
auto i_dir = list.begin();
while (i_dir != list.end()) {
// zero arg to access means test for existence; no constant
// defined on windows
if (access(i_dir->c_str(), 0)) {
i_dir = list.erase(i_dir);
} else {
++i_dir;
}
}
} | O0 | cpp | nglog::GetExistingTempDirectories(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&):
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
callq 0x17730
movq -0x8(%rbp), %rdi
callq 0xd110
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1eb40
movq %rax, -0x18(%rbp)
leaq -0x10(%rbp), %rdi
leaq -0x18(%rbp), %rsi
callq 0x1eb00
testb $0x1, %al
jne 0x17952
jmp 0x179ad
leaq -0x10(%rbp), %rdi
callq 0x1eb70
movq %rax, %rdi
callq 0x92b0
movq %rax, %rdi
xorl %esi, %esi
callq 0x9c80
cmpl $0x0, %eax
je 0x179a2
movq -0x8(%rbp), %rax
movq %rax, -0x30(%rbp)
leaq -0x28(%rbp), %rdi
leaq -0x10(%rbp), %rsi
callq 0x1ec00
movq -0x30(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x1eb90
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x10(%rbp)
jmp 0x179ab
leaq -0x10(%rbp), %rdi
callq 0x1ec40
jmp 0x17932
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _ZN5nglog26GetExistingTempDirectoriesERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov rdi, [rbp+var_8]
call _ZN5nglogL18GetTempDirectoriesERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE; nglog::GetTempDirectories(std::vector<std::string> &)
mov rdi, [rbp+var_8]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5beginEv; std::vector<std::string>::begin(void)
mov [rbp+var_10], rax
loc_17932:
mov rdi, [rbp+var_8]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE3endEv; std::vector<std::string>::end(void)
mov [rbp+var_18], rax
lea rdi, [rbp+var_10]
lea rsi, [rbp+var_18]
call _ZN9__gnu_cxxneIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEEbRKNS_17__normal_iteratorIT_T0_EESG_; __gnu_cxx::operator!=<std::string *,std::vector<std::string>>(__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&,__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&)
test al, 1
jnz short loc_17952
jmp short loc_179AD
loc_17952:
lea rdi, [rbp+var_10]
call _ZNK9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEptEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator->(void)
mov rdi, rax
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov rdi, rax
xor esi, esi
call _access
cmp eax, 0
jz short loc_179A2
mov rax, [rbp+var_8]
mov [rbp+var_30], rax
lea rdi, [rbp+var_28]
lea rsi, [rbp+var_10]
call _ZN9__gnu_cxx17__normal_iteratorIPKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEC2IPS6_EERKNS0_IT_NS_11__enable_ifIXsr3std10__are_sameISF_SE_EE7__valueESB_E6__typeEEE
mov rdi, [rbp+var_30]
mov rsi, [rbp+var_28]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS5_S7_EE; std::vector<std::string>::erase(__gnu_cxx::__normal_iterator<std::string const*,std::vector<std::string>>)
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
mov [rbp+var_10], rax
jmp short loc_179AB
loc_179A2:
lea rdi, [rbp+var_10]
call _ZN9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEppEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(void)
loc_179AB:
jmp short loc_17932
loc_179AD:
add rsp, 30h
pop rbp
retn
| long long nglog::GetExistingTempDirectories(long long a1)
{
long long result; // rax
long long v2; // rax
long long v3; // rax
long long v4; // [rsp+0h] [rbp-30h]
long long v5; // [rsp+8h] [rbp-28h] BYREF
long long v6; // [rsp+10h] [rbp-20h]
long long v7; // [rsp+18h] [rbp-18h] BYREF
long long v8; // [rsp+20h] [rbp-10h] BYREF
long long v9; // [rsp+28h] [rbp-8h]
v9 = a1;
nglog::GetTempDirectories(a1);
v8 = std::vector<std::string>::begin(a1);
while ( 1 )
{
v7 = std::vector<std::string>::end(v9);
result = __gnu_cxx::operator!=<std::string *,std::vector<std::string>>(&v8, &v7);
if ( (result & 1) == 0 )
break;
v2 = __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator->(&v8);
v3 = std::string::c_str(v2);
if ( (unsigned int)access(v3, 0LL) )
{
v4 = v9;
__gnu_cxx::__normal_iterator<std::string const*,std::vector<std::string>>::__normal_iterator<std::string*>(
&v5,
&v8);
v6 = std::vector<std::string>::erase(v4, v5);
v8 = v6;
}
else
{
__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(&v8);
}
}
return result;
}
| GetExistingTempDirectories:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00117730
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x0010d110
MOV qword ptr [RBP + -0x10],RAX
LAB_00117932:
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x0011eb40
MOV qword ptr [RBP + -0x18],RAX
LEA RDI,[RBP + -0x10]
LEA RSI,[RBP + -0x18]
CALL 0x0011eb00
TEST AL,0x1
JNZ 0x00117952
JMP 0x001179ad
LAB_00117952:
LEA RDI,[RBP + -0x10]
CALL 0x0011eb70
MOV RDI,RAX
CALL 0x001092b0
MOV RDI,RAX
XOR ESI,ESI
CALL 0x00109c80
CMP EAX,0x0
JZ 0x001179a2
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x30],RAX
LEA RDI,[RBP + -0x28]
LEA RSI,[RBP + -0x10]
CALL 0x0011ec00
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,qword ptr [RBP + -0x28]
CALL 0x0011eb90
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x10],RAX
JMP 0x001179ab
LAB_001179a2:
LEA RDI,[RBP + -0x10]
CALL 0x0011ec40
LAB_001179ab:
JMP 0x00117932
LAB_001179ad:
ADD RSP,0x30
POP RBP
RET
|
/* nglog::GetExistingTempDirectories(std::vector<std::__cxx11::string,
std::allocator<std::__cxx11::string > >&) */
void nglog::GetExistingTempDirectories(vector *param_1)
{
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *pvVar1;
bool bVar2;
int iVar3;
char *__name;
int8 local_30;
int8 local_28;
int8 local_20;
int8 local_18;
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *local_10;
local_10 = (vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1;
GetTempDirectories(param_1);
local_18 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::begin(local_10)
;
while( true ) {
local_20 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::end(local_10)
;
bVar2 = __gnu_cxx::operator!=((__normal_iterator *)&local_18,(__normal_iterator *)&local_20);
if (!bVar2) break;
__gnu_cxx::
__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::operator->((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_18);
__name = (char *)std::__cxx11::string::c_str();
iVar3 = access(__name,0);
pvVar1 = local_10;
if (iVar3 == 0) {
__gnu_cxx::
__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::operator++((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_18);
}
else {
__gnu_cxx::
__normal_iterator<std::__cxx11::string_const*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
::__normal_iterator<std::__cxx11::string*>
((__normal_iterator<std::__cxx11::string_const*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>>
*)&local_30,(__normal_iterator *)&local_18);
local_28 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::erase
(pvVar1,local_30);
local_18 = local_28;
}
}
return;
}
| |
21,490 | nglog::GetExistingTempDirectories(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&) | ng-log[P]ng-log/src/logging.cc | NGLOG_NO_EXPORT
void GetExistingTempDirectories(vector<string>& list) {
GetTempDirectories(list);
auto i_dir = list.begin();
while (i_dir != list.end()) {
// zero arg to access means test for existence; no constant
// defined on windows
if (access(i_dir->c_str(), 0)) {
i_dir = list.erase(i_dir);
} else {
++i_dir;
}
}
} | O1 | cpp | nglog::GetExistingTempDirectories(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&):
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0xddc2
movq (%rbx), %r14
cmpq 0x8(%rbx), %r14
je 0xdf4d
movq (%r14), %rdi
xorl %esi, %esi
callq 0x7920
testl %eax, %eax
je 0xdf47
movq %rbx, %rdi
movq %r14, %rsi
callq 0x20388
movq %rax, %r14
jmp 0xdf23
addq $0x20, %r14
jmp 0xdf23
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| _ZN5nglog26GetExistingTempDirectoriesERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE:
push r14
push rbx
push rax
mov rbx, rdi
call _ZN5nglogL18GetTempDirectoriesERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE; nglog::GetTempDirectories(std::vector<std::string> &)
mov r14, [rbx]
loc_DF23:
cmp r14, [rbx+8]
jz short loc_DF4D
mov rdi, [r14]
xor esi, esi
call _access
test eax, eax
jz short loc_DF47
mov rdi, rbx
mov rsi, r14
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE8_M_eraseEN9__gnu_cxx17__normal_iteratorIPS5_S7_EE; std::vector<std::string>::_M_erase(__gnu_cxx::__normal_iterator<std::string*,std::vector<std::string>>)
mov r14, rax
jmp short loc_DF23
loc_DF47:
add r14, 20h ; ' '
jmp short loc_DF23
loc_DF4D:
add rsp, 8
pop rbx
pop r14
retn
| void nglog::GetExistingTempDirectories(_QWORD *a1)
{
_QWORD *v1; // r14
nglog::GetTempDirectories(a1);
v1 = (_QWORD *)*a1;
while ( v1 != (_QWORD *)a1[1] )
{
if ( (unsigned int)access(*v1, 0LL) )
v1 = (_QWORD *)std::vector<std::string>::_M_erase(a1, v1);
else
v1 += 4;
}
}
| GetExistingTempDirectories:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
CALL 0x0010ddc2
MOV R14,qword ptr [RBX]
LAB_0010df23:
CMP R14,qword ptr [RBX + 0x8]
JZ 0x0010df4d
MOV RDI,qword ptr [R14]
XOR ESI,ESI
CALL 0x00107920
TEST EAX,EAX
JZ 0x0010df47
MOV RDI,RBX
MOV RSI,R14
CALL 0x00120388
MOV R14,RAX
JMP 0x0010df23
LAB_0010df47:
ADD R14,0x20
JMP 0x0010df23
LAB_0010df4d:
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* nglog::GetExistingTempDirectories(std::vector<std::__cxx11::string,
std::allocator<std::__cxx11::string > >&) */
void nglog::GetExistingTempDirectories(vector *param_1)
{
int iVar1;
int8 *puVar2;
GetTempDirectories(param_1);
puVar2 = *(int8 **)param_1;
while (puVar2 != *(int8 **)(param_1 + 8)) {
iVar1 = access((char *)*puVar2,0);
if (iVar1 == 0) {
puVar2 = puVar2 + 4;
}
else {
puVar2 = (int8 *)
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::_M_erase
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)
param_1);
}
}
return;
}
| |
21,491 | nglog::GetExistingTempDirectories(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&) | ng-log[P]ng-log/src/logging.cc | NGLOG_NO_EXPORT
void GetExistingTempDirectories(vector<string>& list) {
GetTempDirectories(list);
auto i_dir = list.begin();
while (i_dir != list.end()) {
// zero arg to access means test for existence; no constant
// defined on windows
if (access(i_dir->c_str(), 0)) {
i_dir = list.erase(i_dir);
} else {
++i_dir;
}
}
} | O2 | cpp | nglog::GetExistingTempDirectories(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&):
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0xd7a4
movq (%rbx), %r14
cmpq 0x8(%rbx), %r14
je 0xd8eb
movq (%r14), %rdi
xorl %esi, %esi
callq 0x89c0
testl %eax, %eax
je 0xd8e5
movq %rbx, %rdi
movq %r14, %rsi
callq 0x109d6
movq %rax, %r14
jmp 0xd8c1
addq $0x20, %r14
jmp 0xd8c1
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| _ZN5nglog26GetExistingTempDirectoriesERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE:
push r14
push rbx
push rax
mov rbx, rdi
call _ZN5nglogL18GetTempDirectoriesERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE; nglog::GetTempDirectories(std::vector<std::string> &)
mov r14, [rbx]
loc_D8C1:
cmp r14, [rbx+8]
jz short loc_D8EB
mov rdi, [r14]
xor esi, esi
call _access
test eax, eax
jz short loc_D8E5
mov rdi, rbx
mov rsi, r14
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS5_S7_EE; std::vector<std::string>::erase(__gnu_cxx::__normal_iterator<std::string const*,std::vector<std::string>>)
mov r14, rax
jmp short loc_D8C1
loc_D8E5:
add r14, 20h ; ' '
jmp short loc_D8C1
loc_D8EB:
add rsp, 8
pop rbx
pop r14
retn
| void nglog::GetExistingTempDirectories(_QWORD *a1)
{
_QWORD *v1; // r14
nglog::GetTempDirectories((long long)a1);
v1 = (_QWORD *)*a1;
while ( v1 != (_QWORD *)a1[1] )
{
if ( (unsigned int)access(*v1, 0LL) )
v1 = (_QWORD *)std::vector<std::string>::erase(a1, v1);
else
v1 += 4;
}
}
| GetExistingTempDirectories:
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
CALL 0x0010d7a4
MOV R14,qword ptr [RBX]
LAB_0010d8c1:
CMP R14,qword ptr [RBX + 0x8]
JZ 0x0010d8eb
MOV RDI,qword ptr [R14]
XOR ESI,ESI
CALL 0x001089c0
TEST EAX,EAX
JZ 0x0010d8e5
MOV RDI,RBX
MOV RSI,R14
CALL 0x001109d6
MOV R14,RAX
JMP 0x0010d8c1
LAB_0010d8e5:
ADD R14,0x20
JMP 0x0010d8c1
LAB_0010d8eb:
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* nglog::GetExistingTempDirectories(std::vector<std::__cxx11::string,
std::allocator<std::__cxx11::string > >&) */
void nglog::GetExistingTempDirectories(vector *param_1)
{
int iVar1;
int8 *puVar2;
GetTempDirectories(param_1);
puVar2 = *(int8 **)param_1;
while (puVar2 != *(int8 **)(param_1 + 8)) {
iVar1 = access((char *)*puVar2,0);
if (iVar1 == 0) {
puVar2 = puVar2 + 4;
}
else {
puVar2 = (int8 *)
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::erase
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)
param_1);
}
}
return;
}
| |
21,492 | reset_root_defaults | eloqsql/mysys/my_alloc.c | void reset_root_defaults(MEM_ROOT *mem_root, size_t block_size,
size_t pre_alloc_size __attribute__((unused)))
{
DBUG_ENTER("reset_root_defaults");
DBUG_ASSERT(alloc_root_inited(mem_root));
mem_root->block_size= (((block_size - ALLOC_ROOT_MIN_BLOCK_SIZE) & ~1) |
(mem_root->block_size & 1));
#if !(defined(HAVE_valgrind) && defined(EXTRA_DEBUG))
if (pre_alloc_size)
{
size_t size= pre_alloc_size + ALIGN_SIZE(sizeof(USED_MEM));
if (!mem_root->pre_alloc || mem_root->pre_alloc->size != size)
{
USED_MEM *mem, **prev= &mem_root->free;
/*
Free unused blocks, so that consequent calls
to reset_root_defaults won't eat away memory.
*/
while (*prev)
{
mem= *prev;
if (mem->size == size)
{
/* We found a suitable block, no need to do anything else */
mem_root->pre_alloc= mem;
DBUG_VOID_RETURN;
}
if (mem->left + ALIGN_SIZE(sizeof(USED_MEM)) == mem->size)
{
/* remove block from the list and free it */
*prev= mem->next;
my_free(mem);
}
else
prev= &mem->next;
}
/* Allocate new prealloc block and add it to the end of free list */
if ((mem= (USED_MEM *) my_malloc(mem_root->m_psi_key, size,
MYF(MALLOC_FLAG(mem_root->
block_size)))))
{
mem->size= size;
mem->left= pre_alloc_size;
mem->next= *prev;
*prev= mem_root->pre_alloc= mem;
TRASH_MEM(mem);
}
else
{
mem_root->pre_alloc= 0;
}
}
}
else
#endif
mem_root->pre_alloc= 0;
DBUG_VOID_RETURN;
} | O0 | c | reset_root_defaults:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
jmp 0x7b776
movq -0x10(%rbp), %rcx
subq $0x28, %rcx
andq $-0x2, %rcx
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
andq $0x1, %rax
orq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x20(%rax)
cmpq $0x0, -0x18(%rbp)
je 0x7b8cf
movq -0x18(%rbp), %rax
addq $0x18, %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x7b7d1
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
cmpq -0x20(%rbp), %rax
je 0x7b8cd
movq -0x8(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
cmpq $0x0, (%rax)
je 0x7b846
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq 0x10(%rax), %rax
cmpq -0x20(%rbp), %rax
jne 0x7b80d
movq -0x28(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x10(%rax)
jmp 0x7b8df
movq -0x28(%rbp), %rax
movq 0x8(%rax), %rax
addq $0x18, %rax
movq -0x28(%rbp), %rcx
cmpq 0x10(%rcx), %rax
jne 0x7b83c
movq -0x28(%rbp), %rax
movq (%rax), %rcx
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
movq -0x28(%rbp), %rdi
callq 0x808d0
jmp 0x7b844
movq -0x28(%rbp), %rax
movq %rax, -0x30(%rbp)
jmp 0x7b7d9
movq -0x8(%rbp), %rax
movl 0x38(%rax), %edi
movq -0x20(%rbp), %rsi
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rdx
andq $0x1, %rdx
xorl %eax, %eax
movl $0x10000, %ecx # imm = 0x10000
cmpq $0x0, %rdx
cmovnel %ecx, %eax
movl %eax, %eax
movl %eax, %edx
callq 0x80550
movq %rax, -0x28(%rbp)
cmpq $0x0, %rax
je 0x7b8bf
movq -0x20(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x18(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x30(%rbp), %rax
movq (%rax), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movq -0x28(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x30(%rbp), %rax
movq %rcx, (%rax)
jmp 0x7b8b9
jmp 0x7b8bb
jmp 0x7b8bd
jmp 0x7b8cb
movq -0x8(%rbp), %rax
movq $0x0, 0x10(%rax)
jmp 0x7b8cd
jmp 0x7b8db
movq -0x8(%rbp), %rax
movq $0x0, 0x10(%rax)
jmp 0x7b8dd
jmp 0x7b8df
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| reset_root_defaults:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
jmp short $+2
loc_7B776:
mov rcx, [rbp+var_10]
sub rcx, 28h ; '('
and rcx, 0FFFFFFFFFFFFFFFEh
mov rax, [rbp+var_8]
mov rax, [rax+20h]
and rax, 1
or rcx, rax
mov rax, [rbp+var_8]
mov [rax+20h], rcx
cmp [rbp+var_18], 0
jz loc_7B8CF
mov rax, [rbp+var_18]
add rax, 18h
mov [rbp+var_20], rax
mov rax, [rbp+var_8]
cmp qword ptr [rax+10h], 0
jz short loc_7B7D1
mov rax, [rbp+var_8]
mov rax, [rax+10h]
mov rax, [rax+10h]
cmp rax, [rbp+var_20]
jz loc_7B8CD
loc_7B7D1:
mov rax, [rbp+var_8]
mov [rbp+var_30], rax
loc_7B7D9:
mov rax, [rbp+var_30]
cmp qword ptr [rax], 0
jz short loc_7B846
mov rax, [rbp+var_30]
mov rax, [rax]
mov [rbp+var_28], rax
mov rax, [rbp+var_28]
mov rax, [rax+10h]
cmp rax, [rbp+var_20]
jnz short loc_7B80D
mov rcx, [rbp+var_28]
mov rax, [rbp+var_8]
mov [rax+10h], rcx
jmp loc_7B8DF
loc_7B80D:
mov rax, [rbp+var_28]
mov rax, [rax+8]
add rax, 18h
mov rcx, [rbp+var_28]
cmp rax, [rcx+10h]
jnz short loc_7B83C
mov rax, [rbp+var_28]
mov rcx, [rax]
mov rax, [rbp+var_30]
mov [rax], rcx
mov rdi, [rbp+var_28]
call my_free
jmp short loc_7B844
loc_7B83C:
mov rax, [rbp+var_28]
mov [rbp+var_30], rax
loc_7B844:
jmp short loc_7B7D9
loc_7B846:
mov rax, [rbp+var_8]
mov edi, [rax+38h]
mov rsi, [rbp+var_20]
mov rax, [rbp+var_8]
mov rdx, [rax+20h]
and rdx, 1
xor eax, eax
mov ecx, offset stru_10000
cmp rdx, 0
cmovnz eax, ecx
mov eax, eax
mov edx, eax
call my_malloc
mov [rbp+var_28], rax
cmp rax, 0
jz short loc_7B8BF
mov rcx, [rbp+var_20]
mov rax, [rbp+var_28]
mov [rax+10h], rcx
mov rcx, [rbp+var_18]
mov rax, [rbp+var_28]
mov [rax+8], rcx
mov rax, [rbp+var_30]
mov rcx, [rax]
mov rax, [rbp+var_28]
mov [rax], rcx
mov rcx, [rbp+var_28]
mov rax, [rbp+var_8]
mov [rax+10h], rcx
mov rax, [rbp+var_30]
mov [rax], rcx
jmp short $+2
loc_7B8B9:
jmp short $+2
loc_7B8BB:
jmp short $+2
loc_7B8BD:
jmp short loc_7B8CB
loc_7B8BF:
mov rax, [rbp+var_8]
mov qword ptr [rax+10h], 0
loc_7B8CB:
jmp short $+2
loc_7B8CD:
jmp short loc_7B8DB
loc_7B8CF:
mov rax, [rbp+var_8]
mov qword ptr [rax+10h], 0
loc_7B8DB:
jmp short $+2
loc_7B8DD:
jmp short $+2
loc_7B8DF:
add rsp, 30h
pop rbp
retn
| long long * reset_root_defaults(long long *a1, long long a2, long long a3)
{
long long *result; // rax
long long v4; // rdi
unsigned int v5; // eax
long long *v6; // [rsp+0h] [rbp-30h]
long long *v7; // [rsp+8h] [rbp-28h]
_QWORD *v8; // [rsp+8h] [rbp-28h]
long long *v9; // [rsp+10h] [rbp-20h]
a1[4] = a1[4] & 1 | (a2 - 40) & 0xFFFFFFFFFFFFFFFELL;
if ( a3 )
{
v9 = (long long *)(a3 + 24);
if ( !a1[2] || (result = *(long long **)(a1[2] + 16), result != v9) )
{
v6 = a1;
while ( *v6 )
{
v7 = (long long *)*v6;
if ( *(long long **)(*v6 + 16) == v9 )
{
result = a1;
a1[2] = (long long)v7;
return result;
}
if ( v7[1] + 24 == v7[2] )
{
*v6 = *v7;
my_free(v7);
}
else
{
v6 = (long long *)*v6;
}
}
v4 = *((unsigned int *)a1 + 14);
v5 = 0;
if ( (a1[4] & 1) != 0 )
v5 = (unsigned int)&stru_10000;
v8 = (_QWORD *)my_malloc(v4, v9, v5);
if ( v8 )
{
v8[2] = v9;
v8[1] = a3;
*v8 = *v6;
a1[2] = (long long)v8;
result = v6;
*v6 = (long long)v8;
}
else
{
result = a1;
a1[2] = 0LL;
}
}
}
else
{
result = a1;
a1[2] = 0LL;
}
return result;
}
| reset_root_defaults:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
JMP 0x0017b776
LAB_0017b776:
MOV RCX,qword ptr [RBP + -0x10]
SUB RCX,0x28
AND RCX,-0x2
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x20]
AND RAX,0x1
OR RCX,RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x20],RCX
CMP qword ptr [RBP + -0x18],0x0
JZ 0x0017b8cf
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x18
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x10],0x0
JZ 0x0017b7d1
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x10]
MOV RAX,qword ptr [RAX + 0x10]
CMP RAX,qword ptr [RBP + -0x20]
JZ 0x0017b8cd
LAB_0017b7d1:
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x30],RAX
LAB_0017b7d9:
MOV RAX,qword ptr [RBP + -0x30]
CMP qword ptr [RAX],0x0
JZ 0x0017b846
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x10]
CMP RAX,qword ptr [RBP + -0x20]
JNZ 0x0017b80d
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x10],RCX
JMP 0x0017b8df
LAB_0017b80d:
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x8]
ADD RAX,0x18
MOV RCX,qword ptr [RBP + -0x28]
CMP RAX,qword ptr [RCX + 0x10]
JNZ 0x0017b83c
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x001808d0
JMP 0x0017b844
LAB_0017b83c:
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x30],RAX
LAB_0017b844:
JMP 0x0017b7d9
LAB_0017b846:
MOV RAX,qword ptr [RBP + -0x8]
MOV EDI,dword ptr [RAX + 0x38]
MOV RSI,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RAX + 0x20]
AND RDX,0x1
XOR EAX,EAX
MOV ECX,0x10000
CMP RDX,0x0
CMOVNZ EAX,ECX
MOV EAX,EAX
MOV EDX,EAX
CALL 0x00180550
MOV qword ptr [RBP + -0x28],RAX
CMP RAX,0x0
JZ 0x0017b8bf
MOV RCX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX + 0x10],RCX
MOV RCX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x10],RCX
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX],RCX
JMP 0x0017b8b9
LAB_0017b8b9:
JMP 0x0017b8bb
LAB_0017b8bb:
JMP 0x0017b8bd
LAB_0017b8bd:
JMP 0x0017b8cb
LAB_0017b8bf:
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x10],0x0
LAB_0017b8cb:
JMP 0x0017b8cd
LAB_0017b8cd:
JMP 0x0017b8db
LAB_0017b8cf:
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x10],0x0
LAB_0017b8db:
JMP 0x0017b8dd
LAB_0017b8dd:
JMP 0x0017b8df
LAB_0017b8df:
ADD RSP,0x30
POP RBP
RET
|
void reset_root_defaults(long *param_1,long param_2,long param_3)
{
int4 uVar1;
long lVar2;
long *plVar3;
long *local_38;
param_1[4] = param_2 - 0x28U & 0xfffffffffffffffe | param_1[4] & 1U;
if (param_3 == 0) {
param_1[2] = 0;
}
else {
lVar2 = param_3 + 0x18;
plVar3 = param_1;
if ((param_1[2] == 0) || (plVar3 = param_1, *(long *)(param_1[2] + 0x10) != lVar2)) {
while (local_38 = plVar3, *local_38 != 0) {
plVar3 = (long *)*local_38;
if (plVar3[2] == lVar2) {
param_1[2] = (long)plVar3;
return;
}
if (plVar3[1] + 0x18 == plVar3[2]) {
*local_38 = *plVar3;
my_free(plVar3);
plVar3 = local_38;
}
}
uVar1 = 0;
if ((param_1[4] & 1U) != 0) {
uVar1 = 0x10000;
}
plVar3 = (long *)my_malloc((int)param_1[7],lVar2,uVar1);
if (plVar3 == (long *)0x0) {
param_1[2] = 0;
}
else {
plVar3[2] = lVar2;
plVar3[1] = param_3;
*plVar3 = *local_38;
param_1[2] = (long)plVar3;
*local_38 = (long)plVar3;
}
}
}
return;
}
| |
21,493 | OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<float> const&, float, float, float, float, float, float) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/stencilBuilder.cpp | void
StencilBuilder<REAL>::Index::AddWithWeight(StencilReal<REAL> const& src,
REAL weight, REAL du, REAL dv, REAL duu, REAL duv, REAL dvv)
{
if (isWeightZero(weight) && isWeightZero(du) && isWeightZero(dv) &&
isWeightZero(duu) && isWeightZero(duv) && isWeightZero(dvv)) {
return;
}
int srcSize = *src.GetSizePtr();
Vtr::Index const * srcIndices = src.GetVertexIndices();
REAL const * srcWeights = src.GetWeights();
for (int i = 0; i < srcSize; ++i) {
REAL w = srcWeights[i];
if (isWeightZero(w)) {
continue;
}
Vtr::Index srcIndex = srcIndices[i];
Point2ndDerivWeight<REAL> wgt = Point2ndDerivWeight<REAL>(weight, du, dv, duu, duv, dvv) * w;
_owner->_weightTable->AddWithWeight(srcIndex, _index, wgt,
_owner->_weightTable->GetPoint2ndDerivAccumulator());
}
} | O0 | cpp | OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<float> const&, float, float, float, float, float, float):
pushq %rbp
movq %rsp, %rbp
subq $0x180, %rsp # imm = 0x180
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movsd %xmm0, -0x18(%rbp)
movsd %xmm1, -0x20(%rbp)
movsd %xmm2, -0x28(%rbp)
movsd %xmm3, -0x30(%rbp)
movsd %xmm4, -0x38(%rbp)
movsd %xmm5, -0x40(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x140(%rbp)
movsd -0x18(%rbp), %xmm0
callq 0x178f80
testb $0x1, %al
jne 0x17b85c
jmp 0x17b8b1
movsd -0x20(%rbp), %xmm0
callq 0x178f80
testb $0x1, %al
jne 0x17b86c
jmp 0x17b8b1
movsd -0x28(%rbp), %xmm0
callq 0x178f80
testb $0x1, %al
jne 0x17b87c
jmp 0x17b8b1
movsd -0x30(%rbp), %xmm0
callq 0x178f80
testb $0x1, %al
jne 0x17b88c
jmp 0x17b8b1
movsd -0x38(%rbp), %xmm0
callq 0x178f80
testb $0x1, %al
jne 0x17b89c
jmp 0x17b8b1
movsd -0x40(%rbp), %xmm0
callq 0x178f80
testb $0x1, %al
jne 0x17b8ac
jmp 0x17b8b1
jmp 0x17ba39
movq -0x10(%rbp), %rdi
callq 0xd5f70
movl (%rax), %eax
movl %eax, -0x44(%rbp)
movq -0x10(%rbp), %rdi
callq 0xcc280
movq %rax, -0x50(%rbp)
movq -0x10(%rbp), %rdi
callq 0xcc5a0
movq %rax, -0x58(%rbp)
movl $0x0, -0x5c(%rbp)
movl -0x5c(%rbp), %eax
cmpl -0x44(%rbp), %eax
jge 0x17ba39
movq -0x58(%rbp), %rax
movslq -0x5c(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
movsd %xmm0, -0x68(%rbp)
movsd -0x68(%rbp), %xmm0
callq 0x178f80
testb $0x1, %al
jne 0x17b90e
jmp 0x17b913
jmp 0x17ba2b
movq -0x50(%rbp), %rax
movslq -0x5c(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x6c(%rbp)
movsd -0x18(%rbp), %xmm0
movsd -0x20(%rbp), %xmm1
movsd -0x28(%rbp), %xmm2
movsd -0x30(%rbp), %xmm3
movsd -0x38(%rbp), %xmm4
movsd -0x40(%rbp), %xmm5
leaq -0xd0(%rbp), %rdi
callq 0xd29f0
movsd -0x68(%rbp), %xmm0
leaq -0x100(%rbp), %rdi
callq 0xd0cf0
movups -0xd0(%rbp), %xmm0
movups -0xc0(%rbp), %xmm1
movups -0xb0(%rbp), %xmm2
movq %rsp, %rax
movups %xmm2, 0x20(%rax)
movups %xmm1, 0x10(%rax)
movups %xmm0, (%rax)
leaq -0xa0(%rbp), %rdi
leaq -0x100(%rbp), %rsi
callq 0xd1830
movq -0x140(%rbp), %rax
movq (%rax), %rcx
movq (%rcx), %rcx
movq %rcx, -0x150(%rbp)
movl -0x6c(%rbp), %ecx
movl %ecx, -0x148(%rbp)
movl 0x8(%rax), %eax
movl %eax, -0x144(%rbp)
leaq -0x130(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
movl $0x30, %edx
callq 0xcb1d0
movq -0x140(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rdi
callq 0xc7830
movq -0x150(%rbp), %rdi
movl -0x148(%rbp), %esi
movl -0x144(%rbp), %edx
movq %rax, -0x138(%rbp)
movq -0x138(%rbp), %rcx
movups -0x130(%rbp), %xmm0
movups -0x120(%rbp), %xmm1
movups -0x110(%rbp), %xmm2
movq %rsp, %rax
movups %xmm2, 0x20(%rax)
movups %xmm1, 0x10(%rax)
movups %xmm0, (%rax)
callq 0xc6e90
movl -0x5c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x5c(%rbp)
jmp 0x17b8e0
addq $0x180, %rsp # imm = 0x180
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
| _ZN10OpenSubdiv6v3_6_03Far8internal14StencilBuilderIdE5Index13AddWithWeightERKNS1_11StencilRealIdEEdddddd:
push rbp
mov rbp, rsp
sub rsp, 180h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
movsd [rbp+var_18], xmm0
movsd [rbp+var_20], xmm1
movsd [rbp+var_28], xmm2
movsd [rbp+var_30], xmm3
movsd [rbp+var_38], xmm4
movsd [rbp+var_40], xmm5
mov rax, [rbp+var_8]
mov [rbp+var_140], rax
movsd xmm0, [rbp+var_18]
call _ZN10OpenSubdiv6v3_6_03Far8internal12_GLOBAL__N_112isWeightZeroIdEEbT_; OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(double)
test al, 1
jnz short loc_17B85C
jmp short loc_17B8B1
loc_17B85C:
movsd xmm0, [rbp+var_20]
call _ZN10OpenSubdiv6v3_6_03Far8internal12_GLOBAL__N_112isWeightZeroIdEEbT_; OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(double)
test al, 1
jnz short loc_17B86C
jmp short loc_17B8B1
loc_17B86C:
movsd xmm0, [rbp+var_28]
call _ZN10OpenSubdiv6v3_6_03Far8internal12_GLOBAL__N_112isWeightZeroIdEEbT_; OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(double)
test al, 1
jnz short loc_17B87C
jmp short loc_17B8B1
loc_17B87C:
movsd xmm0, [rbp+var_30]
call _ZN10OpenSubdiv6v3_6_03Far8internal12_GLOBAL__N_112isWeightZeroIdEEbT_; OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(double)
test al, 1
jnz short loc_17B88C
jmp short loc_17B8B1
loc_17B88C:
movsd xmm0, [rbp+var_38]
call _ZN10OpenSubdiv6v3_6_03Far8internal12_GLOBAL__N_112isWeightZeroIdEEbT_; OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(double)
test al, 1
jnz short loc_17B89C
jmp short loc_17B8B1
loc_17B89C:
movsd xmm0, [rbp+var_40]
call _ZN10OpenSubdiv6v3_6_03Far8internal12_GLOBAL__N_112isWeightZeroIdEEbT_; OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(double)
test al, 1
jnz short loc_17B8AC
jmp short loc_17B8B1
loc_17B8AC:
jmp loc_17BA39
loc_17B8B1:
mov rdi, [rbp+var_10]
call __ZNK10OpenSubdiv6v3_6_03Far11StencilRealIdE10GetSizePtrEv; OpenSubdiv::v3_6_0::Far::StencilReal<double>::GetSizePtr(void)
mov eax, [rax]
mov [rbp+var_44], eax
mov rdi, [rbp+var_10]
call __ZNK10OpenSubdiv6v3_6_03Far11StencilRealIdE16GetVertexIndicesEv; OpenSubdiv::v3_6_0::Far::StencilReal<double>::GetVertexIndices(void)
mov [rbp+var_50], rax
mov rdi, [rbp+var_10]
call __ZNK10OpenSubdiv6v3_6_03Far11StencilRealIdE10GetWeightsEv; OpenSubdiv::v3_6_0::Far::StencilReal<double>::GetWeights(void)
mov [rbp+var_58], rax
mov [rbp+var_5C], 0
loc_17B8E0:
mov eax, [rbp+var_5C]
cmp eax, [rbp+var_44]
jge loc_17BA39
mov rax, [rbp+var_58]
movsxd rcx, [rbp+var_5C]
movsd xmm0, qword ptr [rax+rcx*8]
movsd [rbp+var_68], xmm0
movsd xmm0, [rbp+var_68]
call _ZN10OpenSubdiv6v3_6_03Far8internal12_GLOBAL__N_112isWeightZeroIdEEbT_; OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(double)
test al, 1
jnz short loc_17B90E
jmp short loc_17B913
loc_17B90E:
jmp loc_17BA2B
loc_17B913:
mov rax, [rbp+var_50]
movsxd rcx, [rbp+var_5C]
mov eax, [rax+rcx*4]
mov [rbp+var_6C], eax
movsd xmm0, [rbp+var_18]
movsd xmm1, [rbp+var_20]
movsd xmm2, [rbp+var_28]
movsd xmm3, [rbp+var_30]
movsd xmm4, [rbp+var_38]
movsd xmm5, [rbp+var_40]
lea rdi, [rbp+var_D0]
call __ZN10OpenSubdiv6v3_6_03Far8internal19Point2ndDerivWeightIdEC2Edddddd; OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>::Point2ndDerivWeight(double,double,double,double,double,double)
movsd xmm0, [rbp+var_68]
lea rdi, [rbp+var_100]
call __ZN10OpenSubdiv6v3_6_03Far8internal19Point2ndDerivWeightIdEC2Ed; OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>::Point2ndDerivWeight(double)
movups xmm0, [rbp+var_D0]
movups xmm1, [rbp+var_C0]
movups xmm2, [rbp+var_B0]
mov rax, rsp
movups xmmword ptr [rax+20h], xmm2
movups xmmword ptr [rax+10h], xmm1
movups xmmword ptr [rax], xmm0
lea rdi, [rbp+var_A0]
lea rsi, [rbp+var_100]
call __ZN10OpenSubdiv6v3_6_03Far8internalmlENS2_19Point2ndDerivWeightIdEERKS4_; OpenSubdiv::v3_6_0::Far::internal::operator*(OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double> const&)
mov rax, [rbp+var_140]
mov rcx, [rax]
mov rcx, [rcx]
mov [rbp+var_150], rcx
mov ecx, [rbp+var_6C]
mov [rbp+var_148], ecx
mov eax, [rax+8]
mov [rbp+var_144], eax
lea rdi, [rbp+var_130]
lea rsi, [rbp+var_A0]
mov edx, 30h ; '0'
call _memcpy
mov rax, [rbp+var_140]
mov rax, [rax]
mov rdi, [rax]
call __ZN10OpenSubdiv6v3_6_03Far8internal11WeightTableIdE27GetPoint2ndDerivAccumulatorEv; OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::GetPoint2ndDerivAccumulator(void)
mov rdi, [rbp+var_150]
mov esi, [rbp+var_148]
mov edx, [rbp+var_144]
mov [rbp+var_138], rax
mov rcx, [rbp+var_138]
movups xmm0, [rbp+var_130]
movups xmm1, [rbp+var_120]
movups xmm2, [rbp+var_110]
mov rax, rsp
movups xmmword ptr [rax+20h], xmm2
movups xmmword ptr [rax+10h], xmm1
movups xmmword ptr [rax], xmm0
call __ZN10OpenSubdiv6v3_6_03Far8internal11WeightTableIdE13AddWithWeightINS2_19Point2ndDerivWeightIdEENS4_24Point2ndDerivAccumulatorEEEviiT_T0_; OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>(int,int,OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator)
loc_17BA2B:
mov eax, [rbp+var_5C]
add eax, 1
mov [rbp+var_5C], eax
jmp loc_17B8E0
loc_17BA39:
add rsp, 180h
pop rbp
retn
| bool OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight(
long long **a1,
long long a2,
double a3,
double a4,
double a5,
double a6,
double a7,
double a8)
{
bool result; // al
int v9; // edx
int v10; // ecx
int v11; // r8d
int v12; // r9d
int v13; // r8d
int v14; // r9d
long long v15; // [rsp+30h] [rbp-150h]
int v16; // [rsp+38h] [rbp-148h]
int v17; // [rsp+3Ch] [rbp-144h]
int Point2ndDerivAccumulator; // [rsp+48h] [rbp-138h]
_OWORD v19[3]; // [rsp+50h] [rbp-130h] BYREF
_BYTE v20[48]; // [rsp+80h] [rbp-100h] BYREF
_OWORD v21[3]; // [rsp+B0h] [rbp-D0h] BYREF
_BYTE v22[52]; // [rsp+E0h] [rbp-A0h] BYREF
int v23; // [rsp+114h] [rbp-6Ch]
double v24; // [rsp+118h] [rbp-68h]
int i; // [rsp+124h] [rbp-5Ch]
long long Weights; // [rsp+128h] [rbp-58h]
long long VertexIndices; // [rsp+130h] [rbp-50h]
int v28; // [rsp+13Ch] [rbp-44h]
double v29; // [rsp+140h] [rbp-40h]
double v30; // [rsp+148h] [rbp-38h]
double v31; // [rsp+150h] [rbp-30h]
double v32; // [rsp+158h] [rbp-28h]
double v33; // [rsp+160h] [rbp-20h]
double v34; // [rsp+168h] [rbp-18h]
long long v35; // [rsp+170h] [rbp-10h]
long long **v36; // [rsp+178h] [rbp-8h]
v36 = a1;
v35 = a2;
v34 = a3;
v33 = a4;
v32 = a5;
v31 = a6;
v30 = a7;
v29 = a8;
if ( !OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(a3)
|| !OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(v33)
|| !OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(v32)
|| !OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(v31)
|| !OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(v30)
|| !(result = OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(v29)) )
{
v28 = *(_DWORD *)OpenSubdiv::v3_6_0::Far::StencilReal<double>::GetSizePtr(v35);
VertexIndices = OpenSubdiv::v3_6_0::Far::StencilReal<double>::GetVertexIndices(v35);
Weights = OpenSubdiv::v3_6_0::Far::StencilReal<double>::GetWeights(v35);
for ( i = 0; ; ++i )
{
result = i;
if ( i >= v28 )
break;
v24 = *(double *)(Weights + 8LL * i);
if ( !OpenSubdiv::v3_6_0::Far::internal::`anonymous namespace'::isWeightZero<double>(v24) )
{
v23 = *(_DWORD *)(VertexIndices + 4LL * i);
OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>::Point2ndDerivWeight(
v21,
v34,
v33,
v32,
v31,
v30,
v29);
OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>::Point2ndDerivWeight(v20, v24);
OpenSubdiv::v3_6_0::Far::internal::operator*(
(unsigned int)v22,
(unsigned int)v20,
v9,
v10,
v11,
v12,
v21[0],
v21[1],
v21[2]);
v15 = **a1;
v16 = v23;
v17 = *((_DWORD *)a1 + 2);
memcpy(v19, v22, sizeof(v19));
Point2ndDerivAccumulator = OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::GetPoint2ndDerivAccumulator(**a1);
OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>(
v15,
v16,
v17,
Point2ndDerivAccumulator,
v13,
v14,
v19[0],
v19[1],
v19[2]);
}
}
}
return result;
}
| |||
21,494 | OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<float> const&, float, float, float, float, float, float) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/stencilBuilder.cpp | void
StencilBuilder<REAL>::Index::AddWithWeight(StencilReal<REAL> const& src,
REAL weight, REAL du, REAL dv, REAL duu, REAL duv, REAL dvv)
{
if (isWeightZero(weight) && isWeightZero(du) && isWeightZero(dv) &&
isWeightZero(duu) && isWeightZero(duv) && isWeightZero(dvv)) {
return;
}
int srcSize = *src.GetSizePtr();
Vtr::Index const * srcIndices = src.GetVertexIndices();
REAL const * srcWeights = src.GetWeights();
for (int i = 0; i < srcSize; ++i) {
REAL w = srcWeights[i];
if (isWeightZero(w)) {
continue;
}
Vtr::Index srcIndex = srcIndices[i];
Point2ndDerivWeight<REAL> wgt = Point2ndDerivWeight<REAL>(weight, du, dv, duu, duv, dvv) * w;
_owner->_weightTable->AddWithWeight(srcIndex, _index, wgt,
_owner->_weightTable->GetPoint2ndDerivAccumulator());
}
} | O1 | cpp | OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<float> const&, float, float, float, float, float, float):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x90, %rsp
movsd %xmm5, 0x30(%rsp)
movsd %xmm4, 0x38(%rsp)
movsd %xmm3, 0x40(%rsp)
movsd %xmm2, 0x48(%rsp)
movsd %xmm1, 0x50(%rsp)
movq %rdi, %rbx
xorpd %xmm2, %xmm2
movsd %xmm0, 0x58(%rsp)
ucomisd %xmm2, %xmm0
jne 0x81ee1
jp 0x81ee1
movsd 0x50(%rsp), %xmm1
ucomisd %xmm2, %xmm1
jne 0x81ee1
jp 0x81ee1
xorpd %xmm0, %xmm0
movsd 0x48(%rsp), %xmm1
ucomisd %xmm0, %xmm1
jne 0x81ee1
jp 0x81ee1
movsd 0x40(%rsp), %xmm1
ucomisd %xmm0, %xmm1
jne 0x81ee1
jp 0x81ee1
movsd 0x38(%rsp), %xmm1
ucomisd %xmm0, %xmm1
jne 0x81ee1
jp 0x81ee1
movsd 0x30(%rsp), %xmm1
ucomisd %xmm0, %xmm1
jne 0x81ee1
jnp 0x81fbe
movq (%rsi), %rax
movslq (%rax), %r14
testq %r14, %r14
jle 0x81fbe
movq 0x8(%rsi), %r15
movq 0x10(%rsi), %r12
xorl %r13d, %r13d
xorpd %xmm1, %xmm1
movsd (%r12,%r13,8), %xmm0
ucomisd %xmm1, %xmm0
jne 0x81f11
jnp 0x81fb2
movl (%r15,%r13,4), %esi
movapd %xmm0, %xmm1
mulsd 0x58(%rsp), %xmm1
movapd %xmm0, %xmm2
mulsd 0x50(%rsp), %xmm2
movapd %xmm0, %xmm3
mulsd 0x48(%rsp), %xmm3
movapd %xmm0, %xmm4
mulsd 0x40(%rsp), %xmm4
movapd %xmm0, %xmm5
mulsd 0x38(%rsp), %xmm5
mulsd 0x30(%rsp), %xmm0
movq (%rbx), %rax
movq (%rax), %rcx
movl 0x8(%rbx), %edx
movsd %xmm1, 0x60(%rsp)
movsd %xmm2, 0x68(%rsp)
movsd %xmm3, 0x70(%rsp)
movsd %xmm4, 0x78(%rsp)
movsd %xmm5, 0x80(%rsp)
movsd %xmm0, 0x88(%rsp)
movupd 0x60(%rsp), %xmm0
movupd 0x70(%rsp), %xmm1
movupd 0x80(%rsp), %xmm2
movupd %xmm2, 0x20(%rsp)
movupd %xmm1, 0x10(%rsp)
movupd %xmm0, (%rsp)
movq %rcx, %rdi
callq 0x38db0
xorpd %xmm1, %xmm1
incq %r13
cmpq %r13, %r14
jne 0x81eff
addq $0x90, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
| _ZN10OpenSubdiv6v3_6_03Far8internal14StencilBuilderIdE5Index13AddWithWeightERKNS1_11StencilRealIdEEdddddd:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 90h
movsd [rsp+0B8h+var_88], xmm5
movsd [rsp+0B8h+var_80], xmm4
movsd [rsp+0B8h+var_78], xmm3
movsd [rsp+0B8h+var_70], xmm2
movsd [rsp+0B8h+var_68], xmm1
mov rbx, rdi
xorpd xmm2, xmm2
movsd [rsp+0B8h+var_60], xmm0
ucomisd xmm0, xmm2
jnz short loc_81EE1
jp short loc_81EE1
movsd xmm1, [rsp+0B8h+var_68]
ucomisd xmm1, xmm2
jnz short loc_81EE1
jp short loc_81EE1
xorpd xmm0, xmm0
movsd xmm1, [rsp+0B8h+var_70]
ucomisd xmm1, xmm0
jnz short loc_81EE1
jp short loc_81EE1
movsd xmm1, [rsp+0B8h+var_78]
ucomisd xmm1, xmm0
jnz short loc_81EE1
jp short loc_81EE1
movsd xmm1, [rsp+0B8h+var_80]
ucomisd xmm1, xmm0
jnz short loc_81EE1
jp short loc_81EE1
movsd xmm1, [rsp+0B8h+var_88]
ucomisd xmm1, xmm0
jnz short loc_81EE1
jnp loc_81FBE
loc_81EE1:
mov rax, [rsi]
movsxd r14, dword ptr [rax]
test r14, r14
jle loc_81FBE
mov r15, [rsi+8]
mov r12, [rsi+10h]
xor r13d, r13d
xorpd xmm1, xmm1
loc_81EFF:
movsd xmm0, qword ptr [r12+r13*8]
ucomisd xmm0, xmm1
jnz short loc_81F11
jnp loc_81FB2
loc_81F11:
mov esi, [r15+r13*4]
movapd xmm1, xmm0
mulsd xmm1, [rsp+0B8h+var_60]
movapd xmm2, xmm0
mulsd xmm2, [rsp+0B8h+var_68]
movapd xmm3, xmm0
mulsd xmm3, [rsp+0B8h+var_70]
movapd xmm4, xmm0
mulsd xmm4, [rsp+0B8h+var_78]
movapd xmm5, xmm0
mulsd xmm5, [rsp+0B8h+var_80]
mulsd xmm0, [rsp+0B8h+var_88]
mov rax, [rbx]
mov rcx, [rax]
mov edx, [rbx+8]
movsd qword ptr [rsp+0B8h+var_58], xmm1
movsd qword ptr [rsp+0B8h+var_58+8], xmm2
movsd qword ptr [rsp+0B8h+var_48], xmm3
movsd qword ptr [rsp+0B8h+var_48+8], xmm4
movsd qword ptr [rsp+0B8h+var_38], xmm5
movsd qword ptr [rsp+0B8h+var_38+8], xmm0
movupd xmm0, [rsp+0B8h+var_58]
movupd xmm1, [rsp+0B8h+var_48]
movupd xmm2, [rsp+0B8h+var_38]
movupd [rsp+0B8h+var_98], xmm2
movupd [rsp+0B8h+var_A8], xmm1
movupd [rsp+0B8h+var_B8], xmm0
mov rdi, rcx
call __ZN10OpenSubdiv6v3_6_03Far8internal11WeightTableIdE13AddWithWeightINS2_19Point2ndDerivWeightIdEENS4_24Point2ndDerivAccumulatorEEEviiT_T0_; OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>(int,int,OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator)
xorpd xmm1, xmm1
loc_81FB2:
inc r13
cmp r14, r13
jnz loc_81EFF
loc_81FBE:
add rsp, 90h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| long long OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight(
long long a1,
long long *a2,
double a3,
double a4,
double a5,
double a6,
double a7,
double a8,
long long a9,
long long a10,
int a11,
int a12)
{
long long result; // rax
long long v13; // r14
int *v14; // r15
int *v15; // r12
long long i; // r13
double v17; // xmm0_8
if ( a3 != 0.0 || a4 != 0.0 || a5 != 0.0 || a6 != 0.0 || a7 != 0.0 || a8 != 0.0 )
{
result = *a2;
v13 = *(int *)*a2;
if ( v13 > 0 )
{
v14 = (int *)a2[1];
v15 = (int *)a2[2];
for ( i = 0LL; i != v13; ++i )
{
v17 = *(double *)&v15[2 * i];
if ( v17 != 0.0 )
result = OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>(
**(_QWORD **)a1,
v14[i],
*(_DWORD *)(a1 + 8),
**(_QWORD **)a1,
a11,
a12,
v17 * a3,
v17 * a4,
v17 * a5,
v17 * a6,
v17 * a7,
v17 * a8);
}
}
}
return result;
}
| AddWithWeight:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x90
MOVSD qword ptr [RSP + 0x30],XMM5
MOVSD qword ptr [RSP + 0x38],XMM4
MOVSD qword ptr [RSP + 0x40],XMM3
MOVSD qword ptr [RSP + 0x48],XMM2
MOVSD qword ptr [RSP + 0x50],XMM1
MOV RBX,RDI
XORPD XMM2,XMM2
MOVSD qword ptr [RSP + 0x58],XMM0
UCOMISD XMM0,XMM2
JNZ 0x00181ee1
JP 0x00181ee1
MOVSD XMM1,qword ptr [RSP + 0x50]
UCOMISD XMM1,XMM2
JNZ 0x00181ee1
JP 0x00181ee1
XORPD XMM0,XMM0
MOVSD XMM1,qword ptr [RSP + 0x48]
UCOMISD XMM1,XMM0
JNZ 0x00181ee1
JP 0x00181ee1
MOVSD XMM1,qword ptr [RSP + 0x40]
UCOMISD XMM1,XMM0
JNZ 0x00181ee1
JP 0x00181ee1
MOVSD XMM1,qword ptr [RSP + 0x38]
UCOMISD XMM1,XMM0
JNZ 0x00181ee1
JP 0x00181ee1
MOVSD XMM1,qword ptr [RSP + 0x30]
UCOMISD XMM1,XMM0
JNZ 0x00181ee1
JNP 0x00181fbe
LAB_00181ee1:
MOV RAX,qword ptr [RSI]
MOVSXD R14,dword ptr [RAX]
TEST R14,R14
JLE 0x00181fbe
MOV R15,qword ptr [RSI + 0x8]
MOV R12,qword ptr [RSI + 0x10]
XOR R13D,R13D
XORPD XMM1,XMM1
LAB_00181eff:
MOVSD XMM0,qword ptr [R12 + R13*0x8]
UCOMISD XMM0,XMM1
JNZ 0x00181f11
JNP 0x00181fb2
LAB_00181f11:
MOV ESI,dword ptr [R15 + R13*0x4]
MOVAPD XMM1,XMM0
MULSD XMM1,qword ptr [RSP + 0x58]
MOVAPD XMM2,XMM0
MULSD XMM2,qword ptr [RSP + 0x50]
MOVAPD XMM3,XMM0
MULSD XMM3,qword ptr [RSP + 0x48]
MOVAPD XMM4,XMM0
MULSD XMM4,qword ptr [RSP + 0x40]
MOVAPD XMM5,XMM0
MULSD XMM5,qword ptr [RSP + 0x38]
MULSD XMM0,qword ptr [RSP + 0x30]
MOV RAX,qword ptr [RBX]
MOV RCX,qword ptr [RAX]
MOV EDX,dword ptr [RBX + 0x8]
MOVSD qword ptr [RSP + 0x60],XMM1
MOVSD qword ptr [RSP + 0x68],XMM2
MOVSD qword ptr [RSP + 0x70],XMM3
MOVSD qword ptr [RSP + 0x78],XMM4
MOVSD qword ptr [RSP + 0x80],XMM5
MOVSD qword ptr [RSP + 0x88],XMM0
MOVUPD XMM0,xmmword ptr [RSP + 0x60]
MOVUPD XMM1,xmmword ptr [RSP + 0x70]
MOVUPD XMM2,xmmword ptr [RSP + 0x80]
MOVUPD xmmword ptr [RSP + 0x20],XMM2
MOVUPD xmmword ptr [RSP + 0x10],XMM1
MOVUPD xmmword ptr [RSP],XMM0
MOV RDI,RCX
CALL 0x00138db0
XORPD XMM1,XMM1
LAB_00181fb2:
INC R13
CMP R14,R13
JNZ 0x00181eff
LAB_00181fbe:
ADD RSP,0x90
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
/* OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<double>
const&, double, double, double, double, double, double) */
void __thiscall
OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight
(Index *this,StencilReal *param_1,double param_2,double param_3,double param_4,
double param_5,double param_6,double param_7)
{
double dVar1;
int iVar2;
long lVar3;
long lVar4;
long lVar5;
if (((((((param_2 != 0.0) || (NAN(param_2))) || (param_3 != 0.0)) ||
(((NAN(param_3) || (param_4 != 0.0)) ||
((NAN(param_4) || ((param_5 != 0.0 || (NAN(param_5))))))))) || (param_6 != 0.0)) ||
(((NAN(param_6) || (param_7 != 0.0)) || (NAN(param_7))))) &&
(iVar2 = **(int **)param_1, 0 < (long)iVar2)) {
lVar3 = *(long *)(param_1 + 8);
lVar4 = *(long *)(param_1 + 0x10);
lVar5 = 0;
do {
dVar1 = *(double *)(lVar4 + lVar5 * 8);
if ((dVar1 != 0.0) || (NAN(dVar1))) {
WeightTable<double>::
AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>
(**(int8 **)this,*(int4 *)(lVar3 + lVar5 * 4),
*(int4 *)(this + 8));
}
lVar5 = lVar5 + 1;
} while (iVar2 != lVar5);
}
return;
}
| |
21,495 | OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<float> const&, float, float, float, float, float, float) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/stencilBuilder.cpp | void
StencilBuilder<REAL>::Index::AddWithWeight(StencilReal<REAL> const& src,
REAL weight, REAL du, REAL dv, REAL duu, REAL duv, REAL dvv)
{
if (isWeightZero(weight) && isWeightZero(du) && isWeightZero(dv) &&
isWeightZero(duu) && isWeightZero(duv) && isWeightZero(dvv)) {
return;
}
int srcSize = *src.GetSizePtr();
Vtr::Index const * srcIndices = src.GetVertexIndices();
REAL const * srcWeights = src.GetWeights();
for (int i = 0; i < srcSize; ++i) {
REAL w = srcWeights[i];
if (isWeightZero(w)) {
continue;
}
Vtr::Index srcIndex = srcIndices[i];
Point2ndDerivWeight<REAL> wgt = Point2ndDerivWeight<REAL>(weight, du, dv, duu, duv, dvv) * w;
_owner->_weightTable->AddWithWeight(srcIndex, _index, wgt,
_owner->_weightTable->GetPoint2ndDerivAccumulator());
}
} | O2 | cpp | OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<float> const&, float, float, float, float, float, float):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x90, %rsp
movapd %xmm4, 0x30(%rsp)
movapd %xmm2, 0x40(%rsp)
movq %rdi, %rbx
xorpd %xmm4, %xmm4
movapd %xmm0, 0x50(%rsp)
ucomisd %xmm4, %xmm0
jne 0x91c94
jp 0x91c94
ucomisd %xmm4, %xmm1
jne 0x91c94
jp 0x91c94
xorpd %xmm0, %xmm0
movapd 0x40(%rsp), %xmm2
ucomisd %xmm0, %xmm2
jne 0x91c94
jp 0x91c94
ucomisd %xmm0, %xmm3
jne 0x91c94
jp 0x91c94
movapd 0x30(%rsp), %xmm2
ucomisd %xmm0, %xmm2
jne 0x91c94
jp 0x91c94
ucomisd %xmm0, %xmm5
jne 0x91c94
jp 0x91c94
addq $0x90, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq (%rsi), %rax
movq 0x8(%rsi), %r14
movl (%rax), %r15d
xorl %r12d, %r12d
testl %r15d, %r15d
cmovlel %r12d, %r15d
movq 0x10(%rsi), %r13
movapd 0x50(%rsp), %xmm0
unpcklpd %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0]
movapd %xmm0, 0x50(%rsp)
movapd 0x40(%rsp), %xmm0
unpcklpd %xmm3, %xmm0 # xmm0 = xmm0[0],xmm3[0]
movapd %xmm0, 0x40(%rsp)
movapd 0x30(%rsp), %xmm0
unpcklpd %xmm5, %xmm0 # xmm0 = xmm0[0],xmm5[0]
movapd %xmm0, 0x30(%rsp)
cmpq %r12, %r15
je 0x91c83
movsd (%r13,%r12,8), %xmm0
ucomisd %xmm4, %xmm0
jne 0x91cf0
jnp 0x91d62
movl (%r14,%r12,4), %esi
unpcklpd %xmm0, %xmm0 # xmm0 = xmm0[0,0]
movapd %xmm0, %xmm1
mulpd 0x50(%rsp), %xmm1
movapd %xmm0, %xmm2
mulpd 0x40(%rsp), %xmm2
mulpd 0x30(%rsp), %xmm0
movq (%rbx), %rax
movq (%rax), %rcx
movl 0x8(%rbx), %edx
movapd %xmm1, 0x60(%rsp)
movapd %xmm2, 0x70(%rsp)
movapd %xmm0, 0x80(%rsp)
movapd 0x60(%rsp), %xmm0
movapd 0x70(%rsp), %xmm1
movapd 0x80(%rsp), %xmm2
movupd %xmm2, 0x20(%rsp)
movupd %xmm1, 0x10(%rsp)
movupd %xmm0, (%rsp)
movq %rcx, %rdi
callq 0x50540
xorpd %xmm4, %xmm4
incq %r12
jmp 0x91cdc
| _ZN10OpenSubdiv6v3_6_03Far8internal14StencilBuilderIdE5Index13AddWithWeightERKNS1_11StencilRealIdEEdddddd:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 90h
movapd [rsp+0B8h+var_88], xmm4
movapd [rsp+0B8h+var_78], xmm2
mov rbx, rdi
xorpd xmm4, xmm4
movapd [rsp+0B8h+var_68], xmm0
ucomisd xmm0, xmm4
jnz short loc_91C94
jp short loc_91C94
ucomisd xmm1, xmm4
jnz short loc_91C94
jp short loc_91C94
xorpd xmm0, xmm0
movapd xmm2, [rsp+0B8h+var_78]
ucomisd xmm2, xmm0
jnz short loc_91C94
jp short loc_91C94
ucomisd xmm3, xmm0
jnz short loc_91C94
jp short loc_91C94
movapd xmm2, [rsp+0B8h+var_88]
ucomisd xmm2, xmm0
jnz short loc_91C94
jp short loc_91C94
ucomisd xmm5, xmm0
jnz short loc_91C94
jp short loc_91C94
loc_91C83:
add rsp, 90h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
loc_91C94:
mov rax, [rsi]
mov r14, [rsi+8]
mov r15d, [rax]
xor r12d, r12d
test r15d, r15d
cmovle r15d, r12d
mov r13, [rsi+10h]
movapd xmm0, [rsp+0B8h+var_68]
unpcklpd xmm0, xmm1
movapd [rsp+0B8h+var_68], xmm0
movapd xmm0, [rsp+0B8h+var_78]
unpcklpd xmm0, xmm3
movapd [rsp+0B8h+var_78], xmm0
movapd xmm0, [rsp+0B8h+var_88]
unpcklpd xmm0, xmm5
movapd [rsp+0B8h+var_88], xmm0
loc_91CDC:
cmp r15, r12
jz short loc_91C83
movsd xmm0, qword ptr [r13+r12*8+0]
ucomisd xmm0, xmm4
jnz short loc_91CF0
jnp short loc_91D62
loc_91CF0:
mov esi, [r14+r12*4]
unpcklpd xmm0, xmm0
movapd xmm1, xmm0
mulpd xmm1, [rsp+0B8h+var_68]
movapd xmm2, xmm0
mulpd xmm2, [rsp+0B8h+var_78]
mulpd xmm0, [rsp+0B8h+var_88]
mov rax, [rbx]
mov rcx, [rax]
mov edx, [rbx+8]
movapd [rsp+0B8h+var_58], xmm1
movapd [rsp+0B8h+var_48], xmm2
movapd [rsp+0B8h+var_38], xmm0
movapd xmm0, [rsp+0B8h+var_58]
movapd xmm1, [rsp+0B8h+var_48]
movapd xmm2, [rsp+0B8h+var_38]
movupd [rsp+0B8h+var_98], xmm2
movupd [rsp+0B8h+var_A8], xmm1
movupd [rsp+0B8h+var_B8], xmm0
mov rdi, rcx
call __ZN10OpenSubdiv6v3_6_03Far8internal11WeightTableIdE13AddWithWeightINS2_19Point2ndDerivWeightIdEENS4_24Point2ndDerivAccumulatorEEEviiT_T0_; OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>(int,int,OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator)
xorpd xmm4, xmm4
loc_91D62:
inc r12
jmp loc_91CDC
| long long OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight(
long long a1,
long long *a2,
__m128d a3,
__m128d a4,
__m128d a5,
__m128d a6,
__m128d a7,
__m128d a8,
long long a9,
long long a10,
int a11,
int a12)
{
long long result; // rax
unsigned int *v13; // r14
long long v14; // r15
long long v15; // r12
unsigned int *v16; // r13
__m128d v17; // xmm0
__m128d v18; // xmm0
__m128d v19; // [rsp+30h] [rbp-88h]
__m128d v20; // [rsp+40h] [rbp-78h]
__m128d v21; // [rsp+50h] [rbp-68h]
if ( a3.m128d_f64[0] != 0.0
|| a4.m128d_f64[0] != 0.0
|| a5.m128d_f64[0] != 0.0
|| a6.m128d_f64[0] != 0.0
|| a7.m128d_f64[0] != 0.0
|| a8.m128d_f64[0] != 0.0 )
{
result = *a2;
v13 = (unsigned int *)a2[1];
v14 = *(unsigned int *)*a2;
v15 = 0LL;
if ( (int)v14 <= 0 )
v14 = 0LL;
v16 = (unsigned int *)a2[2];
v21 = _mm_unpacklo_pd(a3, a4);
v20 = _mm_unpacklo_pd(a5, a6);
v19 = _mm_unpacklo_pd(a7, a8);
while ( v14 != v15 )
{
v17 = (__m128d)*(unsigned long long *)&v16[2 * v15];
if ( v17.m128d_f64[0] != 0.0 )
{
v18 = _mm_unpacklo_pd(v17, v17);
result = OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>(
**(_QWORD **)a1,
v13[v15],
*(_DWORD *)(a1 + 8),
**(_QWORD **)a1,
a11,
a12,
_mm_mul_pd(v18, v21),
_mm_mul_pd(v18, v20),
_mm_mul_pd(v18, v19));
}
++v15;
}
}
return result;
}
| AddWithWeight:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x90
MOVAPD xmmword ptr [RSP + 0x30],XMM4
MOVAPD xmmword ptr [RSP + 0x40],XMM2
MOV RBX,RDI
XORPD XMM4,XMM4
MOVAPD xmmword ptr [RSP + 0x50],XMM0
UCOMISD XMM0,XMM4
JNZ 0x00191c94
JP 0x00191c94
UCOMISD XMM1,XMM4
JNZ 0x00191c94
JP 0x00191c94
XORPD XMM0,XMM0
MOVAPD XMM2,xmmword ptr [RSP + 0x40]
UCOMISD XMM2,XMM0
JNZ 0x00191c94
JP 0x00191c94
UCOMISD XMM3,XMM0
JNZ 0x00191c94
JP 0x00191c94
MOVAPD XMM2,xmmword ptr [RSP + 0x30]
UCOMISD XMM2,XMM0
JNZ 0x00191c94
JP 0x00191c94
UCOMISD XMM5,XMM0
JNZ 0x00191c94
JP 0x00191c94
LAB_00191c83:
ADD RSP,0x90
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
LAB_00191c94:
MOV RAX,qword ptr [RSI]
MOV R14,qword ptr [RSI + 0x8]
MOV R15D,dword ptr [RAX]
XOR R12D,R12D
TEST R15D,R15D
CMOVLE R15D,R12D
MOV R13,qword ptr [RSI + 0x10]
MOVAPD XMM0,xmmword ptr [RSP + 0x50]
UNPCKLPD XMM0,XMM1
MOVAPD xmmword ptr [RSP + 0x50],XMM0
MOVAPD XMM0,xmmword ptr [RSP + 0x40]
UNPCKLPD XMM0,XMM3
MOVAPD xmmword ptr [RSP + 0x40],XMM0
MOVAPD XMM0,xmmword ptr [RSP + 0x30]
UNPCKLPD XMM0,XMM5
MOVAPD xmmword ptr [RSP + 0x30],XMM0
LAB_00191cdc:
CMP R15,R12
JZ 0x00191c83
MOVSD XMM0,qword ptr [R13 + R12*0x8]
UCOMISD XMM0,XMM4
JNZ 0x00191cf0
JNP 0x00191d62
LAB_00191cf0:
MOV ESI,dword ptr [R14 + R12*0x4]
UNPCKLPD XMM0,XMM0
MOVAPD XMM1,XMM0
MULPD XMM1,xmmword ptr [RSP + 0x50]
MOVAPD XMM2,XMM0
MULPD XMM2,xmmword ptr [RSP + 0x40]
MULPD XMM0,xmmword ptr [RSP + 0x30]
MOV RAX,qword ptr [RBX]
MOV RCX,qword ptr [RAX]
MOV EDX,dword ptr [RBX + 0x8]
MOVAPD xmmword ptr [RSP + 0x60],XMM1
MOVAPD xmmword ptr [RSP + 0x70],XMM2
MOVAPD xmmword ptr [RSP + 0x80],XMM0
MOVAPD XMM0,xmmword ptr [RSP + 0x60]
MOVAPD XMM1,xmmword ptr [RSP + 0x70]
MOVAPD XMM2,xmmword ptr [RSP + 0x80]
MOVUPD xmmword ptr [RSP + 0x20],XMM2
MOVUPD xmmword ptr [RSP + 0x10],XMM1
MOVUPD xmmword ptr [RSP],XMM0
MOV RDI,RCX
CALL 0x00150540
XORPD XMM4,XMM4
LAB_00191d62:
INC R12
JMP 0x00191cdc
|
/* OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<double>
const&, double, double, double, double, double, double) */
void __thiscall
OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight
(Index *this,StencilReal *param_1,double param_2,double param_3,double param_4,
double param_5,double param_6,double param_7)
{
double dVar1;
long lVar2;
long lVar3;
ulong uVar4;
ulong uVar5;
if ((((((param_2 != 0.0) || (NAN(param_2))) || (param_3 != 0.0)) ||
(((NAN(param_3) || (param_4 != 0.0)) ||
((NAN(param_4) || ((param_5 != 0.0 || (NAN(param_5))))))))) || (param_6 != 0.0)) ||
(((NAN(param_6) || (param_7 != 0.0)) || (NAN(param_7))))) {
lVar2 = *(long *)(param_1 + 8);
uVar4 = 0;
uVar5 = (ulong)**(uint **)param_1;
if ((int)**(uint **)param_1 < 1) {
uVar5 = uVar4;
}
lVar3 = *(long *)(param_1 + 0x10);
for (; uVar5 != uVar4; uVar4 = uVar4 + 1) {
dVar1 = *(double *)(lVar3 + uVar4 * 8);
if ((dVar1 != 0.0) || (NAN(dVar1))) {
WeightTable<double>::
AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>
(**(int8 **)this,*(int4 *)(lVar2 + uVar4 * 4),
*(int4 *)(this + 8));
}
}
}
return;
}
| |
21,496 | OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<float> const&, float, float, float, float, float, float) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/stencilBuilder.cpp | void
StencilBuilder<REAL>::Index::AddWithWeight(StencilReal<REAL> const& src,
REAL weight, REAL du, REAL dv, REAL duu, REAL duv, REAL dvv)
{
if (isWeightZero(weight) && isWeightZero(du) && isWeightZero(dv) &&
isWeightZero(duu) && isWeightZero(duv) && isWeightZero(dvv)) {
return;
}
int srcSize = *src.GetSizePtr();
Vtr::Index const * srcIndices = src.GetVertexIndices();
REAL const * srcWeights = src.GetWeights();
for (int i = 0; i < srcSize; ++i) {
REAL w = srcWeights[i];
if (isWeightZero(w)) {
continue;
}
Vtr::Index srcIndex = srcIndices[i];
Point2ndDerivWeight<REAL> wgt = Point2ndDerivWeight<REAL>(weight, du, dv, duu, duv, dvv) * w;
_owner->_weightTable->AddWithWeight(srcIndex, _index, wgt,
_owner->_weightTable->GetPoint2ndDerivAccumulator());
}
} | O3 | cpp | OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<float> const&, float, float, float, float, float, float):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x90, %rsp
movaps %xmm4, 0x30(%rsp)
movapd %xmm2, 0x40(%rsp)
movq %rdi, %rbx
xorpd %xmm2, %xmm2
movapd %xmm0, 0x50(%rsp)
ucomisd %xmm2, %xmm0
jne 0x848c4
jp 0x848c4
ucomisd %xmm2, %xmm1
jne 0x848c4
jp 0x848c4
xorpd %xmm0, %xmm0
movapd 0x40(%rsp), %xmm2
ucomisd %xmm0, %xmm2
jne 0x848c4
jp 0x848c4
ucomisd %xmm0, %xmm3
jne 0x848c4
jp 0x848c4
movapd 0x30(%rsp), %xmm2
ucomisd %xmm0, %xmm2
jne 0x848c4
jp 0x848c4
ucomisd %xmm0, %xmm5
jne 0x848c4
jnp 0x8499e
movq (%rsi), %rax
movslq (%rax), %r14
testq %r14, %r14
jle 0x8499e
movq 0x8(%rsi), %r15
movq 0x10(%rsi), %r12
movapd 0x50(%rsp), %xmm0
unpcklpd %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0]
movapd %xmm0, 0x50(%rsp)
movapd 0x40(%rsp), %xmm0
unpcklpd %xmm3, %xmm0 # xmm0 = xmm0[0],xmm3[0]
movapd %xmm0, 0x40(%rsp)
movapd 0x30(%rsp), %xmm0
unpcklpd %xmm5, %xmm0 # xmm0 = xmm0[0],xmm5[0]
movapd %xmm0, 0x30(%rsp)
xorl %r13d, %r13d
xorpd %xmm1, %xmm1
movsd (%r12,%r13,8), %xmm0
ucomisd %xmm1, %xmm0
jne 0x84920
jnp 0x84992
movl (%r15,%r13,4), %esi
unpcklpd %xmm0, %xmm0 # xmm0 = xmm0[0,0]
movapd %xmm0, %xmm1
mulpd 0x50(%rsp), %xmm1
movapd %xmm0, %xmm2
mulpd 0x40(%rsp), %xmm2
mulpd 0x30(%rsp), %xmm0
movq (%rbx), %rax
movq (%rax), %rcx
movl 0x8(%rbx), %edx
movapd %xmm1, 0x60(%rsp)
movapd %xmm2, 0x70(%rsp)
movapd %xmm0, 0x80(%rsp)
movapd 0x60(%rsp), %xmm0
movapd 0x70(%rsp), %xmm1
movapd 0x80(%rsp), %xmm2
movupd %xmm2, 0x20(%rsp)
movupd %xmm1, 0x10(%rsp)
movupd %xmm0, (%rsp)
movq %rcx, %rdi
callq 0x38db0
xorpd %xmm1, %xmm1
incq %r13
cmpq %r13, %r14
jne 0x84912
addq $0x90, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
| _ZN10OpenSubdiv6v3_6_03Far8internal14StencilBuilderIdE5Index13AddWithWeightERKNS1_11StencilRealIdEEdddddd:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 90h
movaps [rsp+0B8h+var_88], xmm4
movapd [rsp+0B8h+var_78], xmm2
mov rbx, rdi
xorpd xmm2, xmm2
movapd [rsp+0B8h+var_68], xmm0
ucomisd xmm0, xmm2
jnz short loc_848C4
jp short loc_848C4
ucomisd xmm1, xmm2
jnz short loc_848C4
jp short loc_848C4
xorpd xmm0, xmm0
movapd xmm2, [rsp+0B8h+var_78]
ucomisd xmm2, xmm0
jnz short loc_848C4
jp short loc_848C4
ucomisd xmm3, xmm0
jnz short loc_848C4
jp short loc_848C4
movapd xmm2, [rsp+0B8h+var_88]
ucomisd xmm2, xmm0
jnz short loc_848C4
jp short loc_848C4
ucomisd xmm5, xmm0
jnz short loc_848C4
jnp loc_8499E
loc_848C4:
mov rax, [rsi]
movsxd r14, dword ptr [rax]
test r14, r14
jle loc_8499E
mov r15, [rsi+8]
mov r12, [rsi+10h]
movapd xmm0, [rsp+0B8h+var_68]
unpcklpd xmm0, xmm1
movapd [rsp+0B8h+var_68], xmm0
movapd xmm0, [rsp+0B8h+var_78]
unpcklpd xmm0, xmm3
movapd [rsp+0B8h+var_78], xmm0
movapd xmm0, [rsp+0B8h+var_88]
unpcklpd xmm0, xmm5
movapd [rsp+0B8h+var_88], xmm0
xor r13d, r13d
xorpd xmm1, xmm1
loc_84912:
movsd xmm0, qword ptr [r12+r13*8]
ucomisd xmm0, xmm1
jnz short loc_84920
jnp short loc_84992
loc_84920:
mov esi, [r15+r13*4]
unpcklpd xmm0, xmm0
movapd xmm1, xmm0
mulpd xmm1, [rsp+0B8h+var_68]
movapd xmm2, xmm0
mulpd xmm2, [rsp+0B8h+var_78]
mulpd xmm0, [rsp+0B8h+var_88]
mov rax, [rbx]
mov rcx, [rax]
mov edx, [rbx+8]
movapd [rsp+0B8h+var_58], xmm1
movapd [rsp+0B8h+var_48], xmm2
movapd [rsp+0B8h+var_38], xmm0
movapd xmm0, [rsp+0B8h+var_58]
movapd xmm1, [rsp+0B8h+var_48]
movapd xmm2, [rsp+0B8h+var_38]
movupd [rsp+0B8h+var_98], xmm2
movupd [rsp+0B8h+var_A8], xmm1
movupd [rsp+0B8h+var_B8], xmm0
mov rdi, rcx
call __ZN10OpenSubdiv6v3_6_03Far8internal11WeightTableIdE13AddWithWeightINS2_19Point2ndDerivWeightIdEENS4_24Point2ndDerivAccumulatorEEEviiT_T0_; OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>(int,int,OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator)
xorpd xmm1, xmm1
loc_84992:
inc r13
cmp r14, r13
jnz loc_84912
loc_8499E:
add rsp, 90h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| long long OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight(
long long a1,
long long *a2,
__m128d a3,
__m128d a4,
__m128d a5,
__m128d a6,
__m128d a7,
__m128d a8,
long long a9,
long long a10,
int a11,
int a12)
{
long long result; // rax
long long v13; // r14
int *v14; // r15
int *v15; // r12
long long i; // r13
__m128d v17; // xmm0
__m128d v18; // xmm0
__m128d v19; // [rsp+30h] [rbp-88h]
__m128d v20; // [rsp+40h] [rbp-78h]
__m128d v21; // [rsp+50h] [rbp-68h]
if ( a3.m128d_f64[0] != 0.0
|| a4.m128d_f64[0] != 0.0
|| a5.m128d_f64[0] != 0.0
|| a6.m128d_f64[0] != 0.0
|| a7.m128d_f64[0] != 0.0
|| a8.m128d_f64[0] != 0.0 )
{
result = *a2;
v13 = *(int *)*a2;
if ( v13 > 0 )
{
v14 = (int *)a2[1];
v15 = (int *)a2[2];
v21 = _mm_unpacklo_pd(a3, a4);
v20 = _mm_unpacklo_pd(a5, a6);
v19 = _mm_unpacklo_pd(a7, a8);
for ( i = 0LL; i != v13; ++i )
{
v17 = (__m128d)*(unsigned long long *)&v15[2 * i];
if ( v17.m128d_f64[0] != 0.0 )
{
v18 = _mm_unpacklo_pd(v17, v17);
result = OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>(
**(_QWORD **)a1,
v14[i],
*(_DWORD *)(a1 + 8),
**(_QWORD **)a1,
a11,
a12,
_mm_mul_pd(v18, v21),
_mm_mul_pd(v18, v20),
_mm_mul_pd(v18, v19));
}
}
}
}
return result;
}
| AddWithWeight:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x90
MOVAPS xmmword ptr [RSP + 0x30],XMM4
MOVAPD xmmword ptr [RSP + 0x40],XMM2
MOV RBX,RDI
XORPD XMM2,XMM2
MOVAPD xmmword ptr [RSP + 0x50],XMM0
UCOMISD XMM0,XMM2
JNZ 0x001848c4
JP 0x001848c4
UCOMISD XMM1,XMM2
JNZ 0x001848c4
JP 0x001848c4
XORPD XMM0,XMM0
MOVAPD XMM2,xmmword ptr [RSP + 0x40]
UCOMISD XMM2,XMM0
JNZ 0x001848c4
JP 0x001848c4
UCOMISD XMM3,XMM0
JNZ 0x001848c4
JP 0x001848c4
MOVAPD XMM2,xmmword ptr [RSP + 0x30]
UCOMISD XMM2,XMM0
JNZ 0x001848c4
JP 0x001848c4
UCOMISD XMM5,XMM0
JNZ 0x001848c4
JNP 0x0018499e
LAB_001848c4:
MOV RAX,qword ptr [RSI]
MOVSXD R14,dword ptr [RAX]
TEST R14,R14
JLE 0x0018499e
MOV R15,qword ptr [RSI + 0x8]
MOV R12,qword ptr [RSI + 0x10]
MOVAPD XMM0,xmmword ptr [RSP + 0x50]
UNPCKLPD XMM0,XMM1
MOVAPD xmmword ptr [RSP + 0x50],XMM0
MOVAPD XMM0,xmmword ptr [RSP + 0x40]
UNPCKLPD XMM0,XMM3
MOVAPD xmmword ptr [RSP + 0x40],XMM0
MOVAPD XMM0,xmmword ptr [RSP + 0x30]
UNPCKLPD XMM0,XMM5
MOVAPD xmmword ptr [RSP + 0x30],XMM0
XOR R13D,R13D
XORPD XMM1,XMM1
LAB_00184912:
MOVSD XMM0,qword ptr [R12 + R13*0x8]
UCOMISD XMM0,XMM1
JNZ 0x00184920
JNP 0x00184992
LAB_00184920:
MOV ESI,dword ptr [R15 + R13*0x4]
UNPCKLPD XMM0,XMM0
MOVAPD XMM1,XMM0
MULPD XMM1,xmmword ptr [RSP + 0x50]
MOVAPD XMM2,XMM0
MULPD XMM2,xmmword ptr [RSP + 0x40]
MULPD XMM0,xmmword ptr [RSP + 0x30]
MOV RAX,qword ptr [RBX]
MOV RCX,qword ptr [RAX]
MOV EDX,dword ptr [RBX + 0x8]
MOVAPD xmmword ptr [RSP + 0x60],XMM1
MOVAPD xmmword ptr [RSP + 0x70],XMM2
MOVAPD xmmword ptr [RSP + 0x80],XMM0
MOVAPD XMM0,xmmword ptr [RSP + 0x60]
MOVAPD XMM1,xmmword ptr [RSP + 0x70]
MOVAPD XMM2,xmmword ptr [RSP + 0x80]
MOVUPD xmmword ptr [RSP + 0x20],XMM2
MOVUPD xmmword ptr [RSP + 0x10],XMM1
MOVUPD xmmword ptr [RSP],XMM0
MOV RDI,RCX
CALL 0x00138db0
XORPD XMM1,XMM1
LAB_00184992:
INC R13
CMP R14,R13
JNZ 0x00184912
LAB_0018499e:
ADD RSP,0x90
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
/* OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight(OpenSubdiv::v3_6_0::Far::StencilReal<double>
const&, double, double, double, double, double, double) */
void __thiscall
OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<double>::Index::AddWithWeight
(Index *this,StencilReal *param_1,double param_2,double param_3,double param_4,
double param_5,double param_6,double param_7)
{
double dVar1;
int iVar2;
long lVar3;
long lVar4;
long lVar5;
if (((((((param_2 != 0.0) || (NAN(param_2))) || (param_3 != 0.0)) ||
(((NAN(param_3) || (param_4 != 0.0)) ||
((NAN(param_4) || ((param_5 != 0.0 || (NAN(param_5))))))))) || (param_6 != 0.0)) ||
(((NAN(param_6) || (param_7 != 0.0)) || (NAN(param_7))))) &&
(iVar2 = **(int **)param_1, 0 < (long)iVar2)) {
lVar3 = *(long *)(param_1 + 8);
lVar4 = *(long *)(param_1 + 0x10);
lVar5 = 0;
do {
dVar1 = *(double *)(lVar4 + lVar5 * 8);
if ((dVar1 != 0.0) || (NAN(dVar1))) {
WeightTable<double>::
AddWithWeight<OpenSubdiv::v3_6_0::Far::internal::Point2ndDerivWeight<double>,OpenSubdiv::v3_6_0::Far::internal::WeightTable<double>::Point2ndDerivAccumulator>
(**(int8 **)this,*(int4 *)(lVar3 + lVar5 * 4),
*(int4 *)(this + 8));
}
lVar5 = lVar5 + 1;
} while (iVar2 != lVar5);
}
return;
}
| |
21,497 | 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>::empty() const | monkey531[P]llama/common/json.hpp | bool empty() const noexcept
{
switch (m_data.m_type)
{
case value_t::null:
{
// null values are empty
return true;
}
case value_t::array:
{
// delegate call to array_t::empty()
return m_data.m_value.array->empty();
}
case value_t::object:
{
// delegate call to object_t::empty()
return m_data.m_value.object->empty();
}
case value_t::string:
case value_t::boolean:
case value_t::number_integer:
case value_t::number_unsigned:
case value_t::number_float:
case value_t::binary:
case value_t::discarded:
default:
{
// all other types are nonempty
return false;
}
}
} | O1 | cpp | nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::empty() const:
movzbl (%rdi), %eax
testl %eax, %eax
je 0xeacd4
cmpl $0x1, %eax
je 0xeacc5
cmpl $0x2, %eax
jne 0xeacd7
movq 0x8(%rdi), %rax
movq (%rax), %rcx
cmpq 0x8(%rax), %rcx
sete %al
retq
movb $0x1, %al
retq
xorl %eax, %eax
retq
| _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5emptyEv:
movzx eax, byte ptr [rdi]
test eax, eax
jz short loc_EACD4
cmp eax, 1
jz short loc_EACC5
cmp eax, 2
jnz short loc_EACD7
loc_EACC5:
mov rax, [rdi+8]
mov rcx, [rax]
cmp rcx, [rax+8]
setz al
retn
loc_EACD4:
mov al, 1
retn
loc_EACD7:
xor eax, eax
retn
| bool 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>::empty(
unsigned __int8 *a1)
{
int v1; // eax
v1 = *a1;
if ( !*a1 )
return 1;
if ( v1 == 1 || v1 == 2 )
return **((_QWORD **)a1 + 1) == *(_QWORD *)(*((_QWORD *)a1 + 1) + 8LL);
return 0;
}
| empty:
MOVZX EAX,byte ptr [RDI]
TEST EAX,EAX
JZ 0x001eacd4
CMP EAX,0x1
JZ 0x001eacc5
CMP EAX,0x2
JNZ 0x001eacd7
LAB_001eacc5:
MOV RAX,qword ptr [RDI + 0x8]
MOV RCX,qword ptr [RAX]
CMP RCX,qword ptr [RAX + 0x8]
SETZ AL
RET
LAB_001eacd4:
MOV AL,0x1
RET
LAB_001eacd7:
XOR EAX,EAX
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>::empty() const */
int8 __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::empty(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>
bVar1;
long *plVar2;
bVar1 = *this;
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>
)0x0) {
return 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>
)0x1) &&
(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>
)0x2)) {
return 0;
}
plVar2 = *(long **)(this + 8);
return CONCAT71((int7)((ulong)plVar2 >> 8),*plVar2 == plVar2[1]);
}
| |
21,498 | 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>::empty() const | monkey531[P]llama/common/json.hpp | bool empty() const noexcept
{
switch (m_data.m_type)
{
case value_t::null:
{
// null values are empty
return true;
}
case value_t::array:
{
// delegate call to array_t::empty()
return m_data.m_value.array->empty();
}
case value_t::object:
{
// delegate call to object_t::empty()
return m_data.m_value.object->empty();
}
case value_t::string:
case value_t::boolean:
case value_t::number_integer:
case value_t::number_unsigned:
case value_t::number_float:
case value_t::binary:
case value_t::discarded:
default:
{
// all other types are nonempty
return false;
}
}
} | O3 | cpp | nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::empty() const:
movzbl (%rdi), %eax
testl %eax, %eax
je 0xe98ec
cmpl $0x1, %eax
je 0xe98dd
cmpl $0x2, %eax
jne 0xe98ef
movq 0x8(%rdi), %rax
movq (%rax), %rcx
cmpq 0x8(%rax), %rcx
sete %al
retq
movb $0x1, %al
retq
xorl %eax, %eax
retq
| _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5emptyEv:
movzx eax, byte ptr [rdi]
test eax, eax
jz short loc_E98EC
cmp eax, 1
jz short loc_E98DD
cmp eax, 2
jnz short loc_E98EF
loc_E98DD:
mov rax, [rdi+8]
mov rcx, [rax]
cmp rcx, [rax+8]
setz al
retn
loc_E98EC:
mov al, 1
retn
loc_E98EF:
xor eax, eax
retn
| bool 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>::empty(
unsigned __int8 *a1)
{
int v1; // eax
v1 = *a1;
if ( !*a1 )
return 1;
if ( v1 == 1 || v1 == 2 )
return **((_QWORD **)a1 + 1) == *(_QWORD *)(*((_QWORD *)a1 + 1) + 8LL);
return 0;
}
| empty:
MOVZX EAX,byte ptr [RDI]
TEST EAX,EAX
JZ 0x001e98ec
CMP EAX,0x1
JZ 0x001e98dd
CMP EAX,0x2
JNZ 0x001e98ef
LAB_001e98dd:
MOV RAX,qword ptr [RDI + 0x8]
MOV RCX,qword ptr [RAX]
CMP RCX,qword ptr [RAX + 0x8]
SETZ AL
RET
LAB_001e98ec:
MOV AL,0x1
RET
LAB_001e98ef:
XOR EAX,EAX
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>::empty() const */
int8 __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::empty(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>
bVar1;
long *plVar2;
bVar1 = *this;
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>
)0x0) {
return 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>
)0x1) &&
(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>
)0x2)) {
return 0;
}
plVar2 = *(long **)(this + 8);
return CONCAT71((int7)((ulong)plVar2 >> 8),*plVar2 == plVar2[1]);
}
| |
21,499 | google::protobuf::compiler::csharp::WrapperFieldGenerator::GenerateMergingCode(google::protobuf::io::Printer*) | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/csharp/csharp_wrapper_field.cc | void WrapperFieldGenerator::GenerateMergingCode(io::Printer* printer) {
printer->Print(
variables_,
"if (other.$has_property_check$) {\n"
" if ($has_not_property_check$ || other.$property_name$ != $default_value$) {\n"
" $property_name$ = other.$property_name$;\n"
" }\n"
"}\n");
} | O3 | cpp | google::protobuf::compiler::csharp::WrapperFieldGenerator::GenerateMergingCode(google::protobuf::io::Printer*):
movq %rsi, %rax
leaq 0x20(%rdi), %rsi
leaq 0x15ed5e(%rip), %rdx # 0x1a0cfc
movq %rax, %rdi
jmp 0x16cd32
| _ZN6google8protobuf8compiler6csharp21WrapperFieldGenerator19GenerateMergingCodeEPNS0_2io7PrinterE:
mov rax, rsi
lea rsi, [rdi+20h]
lea rdx, aIfOtherHasProp_1; "if (other.$has_property_check$) {\n if"...
mov rdi, rax; this
jmp _ZN6google8protobuf2io7Printer5PrintERKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_St4lessIS9_ESaISt4pairIKS9_S9_EEEPKc; google::protobuf::io::Printer::Print(std::map<std::string,std::string> const&,char const*)
| long long google::protobuf::compiler::csharp::WrapperFieldGenerator::GenerateMergingCode(
google::protobuf::compiler::csharp::WrapperFieldGenerator *this,
google::protobuf::io::Printer *a2,
long long a3,
long long a4,
long long a5,
long long a6,
void *a7,
int a8,
char a9,
int a10,
int a11,
int a12,
int a13,
int a14,
int a15,
void *a16,
int a17,
char a18)
{
return google::protobuf::io::Printer::Print(a2, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18);
}
| GenerateMergingCode:
MOV RAX,RSI
LEA RSI,[RDI + 0x20]
LEA RDX,[0x2a0cfc]
MOV RDI,RAX
JMP 0x0026cd32
|
/* google::protobuf::compiler::csharp::WrapperFieldGenerator::GenerateMergingCode(google::protobuf::io::Printer*)
*/
void __thiscall
google::protobuf::compiler::csharp::WrapperFieldGenerator::GenerateMergingCode
(WrapperFieldGenerator *this,Printer *param_1)
{
io::Printer::Print(param_1,(map *)(this + 0x20),
"if (other.$has_property_check$) {\n if ($has_not_property_check$ || other.$property_name$ != $default_value$) {\n $property_name$ = other.$property_name$;\n }\n}\n"
);
return;
}
|
Subsets and Splits
C++ Functions Using STL
Identifies C++ functions that depend on standard library components, revealing patterns in how developers utilize STL libraries and potentially highlighting common coding practices or dependencies in the dataset.
C++ STL Function Queries
Filters C++ code examples that use standard library containers and algorithms, helping identify common programming patterns and library usage in code generation tasks.
Random Training Function Samples
Performs basic filtering and random sampling of assembly code data without revealing meaningful patterns or relationships.
Random Training Function Samples
Retrieves a random sample of 1000 records from the training dataset, providing basic data exploration but offering limited analytical value beyond seeing raw entries.