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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
22,100 | unpack_dirname | eloqsql/mysys/mf_pack.c | size_t unpack_dirname(char * to, const char *from)
{
size_t length, h_length;
char buff[FN_REFLEN+1+4],*suffix,*tilde_expansion;
DBUG_ENTER("unpack_dirname");
length= normalize_dirname(buff, from);
if (buff[0] == FN_HOMELIB)
{
suffix=buff+1; tilde_expansion=expand_tilde(&suffix);
if (tilde_expansion)
{
length-= (size_t) (suffix-buff)-1;
if (length+(h_length= strlen(tilde_expansion)) <= FN_REFLEN)
{
if ((h_length > 0) && (tilde_expansion[h_length-1] == FN_LIBCHAR))
h_length--;
if (buff+h_length < suffix)
bmove(buff+h_length,suffix,length);
else
bmove_upp((uchar*) buff+h_length+length, (uchar*) suffix+length, length);
bmove(buff,tilde_expansion,h_length);
}
}
}
#ifdef USE_SYMDIR
if (my_use_symdir)
symdirget(buff);
#endif
DBUG_RETURN(system_filename(to,buff)); /* Fix for open */
} | O3 | c | unpack_dirname:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x228, %rsp # imm = 0x228
movq %rdi, -0x250(%rbp)
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
leaq -0x240(%rbp), %r13
movq %r13, %rdi
callq 0xa894b
cmpb $0x7e, (%r13)
jne 0xa8b0d
movq %rax, %r14
leaq -0x23f(%rbp), %r15
cmpb $0x2f, (%r15)
jne 0xa8a2d
leaq 0x37ecad(%rip), %rbx # 0x4276d8
jmp 0xa8a86
movq %r15, %rdi
movl $0x2f, %esi
callq 0x394f0
movq %rax, %r12
testq %rax, %rax
jne 0xa8a4d
movq %r15, %rdi
callq 0xdcfb4
movq %rax, %r12
movb (%r12), %al
movb %al, -0x241(%rbp)
movb $0x0, (%r12)
movq %r15, %rdi
callq 0x39710
movq %rax, %rbx
movb -0x241(%rbp), %al
movb %al, (%r12)
callq 0x39b60
testq %rbx, %rbx
je 0xa8b0d
addq $0x20, %rbx
movq %r12, %r15
movq (%rbx), %r12
testq %r12, %r12
je 0xa8b0d
addq %r13, %r14
subq %r15, %r14
movq %r12, %rdi
callq 0x39400
movq %rax, %r13
addq %r14, %rax
incq %rax
cmpq $0x200, %rax # imm = 0x200
ja 0xa8b0d
testq %r13, %r13
je 0xa8ac2
xorl %eax, %eax
cmpb $0x2f, -0x1(%r12,%r13)
sete %al
subq %rax, %r13
jmp 0xa8ac5
xorl %r13d, %r13d
incq %r14
leaq -0x240(,%r13), %rdi
addq %rbp, %rdi
cmpq %r15, %rdi
jae 0xa8ae5
movq %r15, %rsi
movq %r14, %rdx
callq 0x39140
jmp 0xa8af6
addq %r14, %rdi
addq %r14, %r15
movq %r15, %rsi
movq %r14, %rdx
callq 0xb0ae0
leaq -0x240(%rbp), %rdi
movl $0x205, %ecx # imm = 0x205
movq %r12, %rsi
movq %r13, %rdx
callq 0x395a0
leaq -0x240(%rbp), %rsi
movl $0x1ff, %edx # imm = 0x1FF
movq -0x250(%rbp), %rbx
movq %rbx, %rdi
callq 0xdcffc
movq %fs:0x28, %rcx
cmpq -0x30(%rbp), %rcx
jne 0xa8b4c
subq %rbx, %rax
addq $0x228, %rsp # imm = 0x228
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x39290
| unpack_dirname:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 228h
mov [rbp+var_250], rdi
mov rax, fs:28h
mov [rbp+var_30], rax
lea r13, [rbp+var_240]
mov rdi, r13
call normalize_dirname
cmp byte ptr [r13+0], 7Eh ; '~'
jnz loc_A8B0D
mov r14, rax
lea r15, [rbp+var_23F]
cmp byte ptr [r15], 2Fh ; '/'
jnz short loc_A8A2D
lea rbx, home_dir
jmp short loc_A8A86
loc_A8A2D:
mov rdi, r15
mov esi, 2Fh ; '/'
call _strchr
mov r12, rax
test rax, rax
jnz short loc_A8A4D
mov rdi, r15
call strend
mov r12, rax
loc_A8A4D:
mov al, [r12]
mov [rbp+var_241], al
mov byte ptr [r12], 0
mov rdi, r15
call _getpwnam
mov rbx, rax
mov al, [rbp+var_241]
mov [r12], al
call _endpwent
test rbx, rbx
jz loc_A8B0D
add rbx, 20h ; ' '
mov r15, r12
loc_A8A86:
mov r12, [rbx]
test r12, r12
jz short loc_A8B0D
add r14, r13
sub r14, r15
mov rdi, r12
call _strlen
mov r13, rax
add rax, r14
inc rax
cmp rax, 200h
ja short loc_A8B0D
test r13, r13
jz short loc_A8AC2
xor eax, eax
cmp byte ptr [r12+r13-1], 2Fh ; '/'
setz al
sub r13, rax
jmp short loc_A8AC5
loc_A8AC2:
xor r13d, r13d
loc_A8AC5:
inc r14
lea rdi, ds:0FFFFFFFFFFFFFDC0h[r13]
add rdi, rbp
cmp rdi, r15
jnb short loc_A8AE5
mov rsi, r15
mov rdx, r14
call _memmove
jmp short loc_A8AF6
loc_A8AE5:
add rdi, r14
add r15, r14
mov rsi, r15
mov rdx, r14
call bmove_upp
loc_A8AF6:
lea rdi, [rbp+var_240]
mov ecx, 205h
mov rsi, r12
mov rdx, r13
call ___memmove_chk
loc_A8B0D:
lea rsi, [rbp+var_240]
mov edx, 1FFh
mov rbx, [rbp+var_250]
mov rdi, rbx
call strmake
mov rcx, fs:28h
cmp rcx, [rbp+var_30]
jnz short loc_A8B4C
sub rax, rbx
add rsp, 228h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_A8B4C:
call ___stack_chk_fail
| long long unpack_dirname(long long a1, _BYTE *a2)
{
long long v2; // rax
long long v3; // rdx
long long v4; // rcx
long long v5; // r14
char *v6; // r15
_QWORD *v7; // rbx
char *v8; // r12
long long v9; // rbx
long long v10; // r12
_BYTE *v11; // r14
long long v12; // r13
long long v13; // r13
_BYTE *v14; // r14
char *v15; // rdi
char v18; // [rsp+Fh] [rbp-241h]
char v19; // [rsp+10h] [rbp-240h] BYREF
_BYTE v20[527]; // [rsp+11h] [rbp-23Fh] BYREF
unsigned long long v21; // [rsp+220h] [rbp-30h]
long long savedregs; // [rsp+250h] [rbp+0h] BYREF
v21 = __readfsqword(0x28u);
v2 = normalize_dirname((long long)&v19, a2);
if ( v19 != 126 )
return strmake(a1, &v19, 511LL) - a1;
v5 = v2;
v6 = v20;
if ( v20[0] == 47 )
{
v7 = &home_dir;
LABEL_8:
v10 = *v7;
if ( *v7 )
{
v11 = (_BYTE *)(&v20[v5 - 1] - v6);
v12 = strlen(*v7);
if ( (unsigned long long)&v11[v12 + 1] <= 0x200 )
{
if ( v12 )
v13 = v12 - (*(_BYTE *)(v10 + v12 - 1) == 47);
else
v13 = 0LL;
v14 = v11 + 1;
v15 = (char *)&savedregs + v13 - 576;
if ( v15 >= v6 )
bmove_upp(&v15[(_QWORD)v14], &v6[(_QWORD)v14], v14);
else
memmove(v15, v6, v14);
__memmove_chk(&v19, v10, v13, 517LL);
}
}
return strmake(a1, &v19, 511LL) - a1;
}
v8 = (char *)strchr(v20, 47LL, v3, v4);
if ( !v8 )
v8 = (char *)strend(v20);
v18 = *v8;
*v8 = 0;
v9 = getpwnam(v20);
*v8 = v18;
endpwent();
if ( v9 )
{
v7 = (_QWORD *)(v9 + 32);
v6 = v8;
goto LABEL_8;
}
return strmake(a1, &v19, 511LL) - a1;
}
| unpack_dirname:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x228
MOV qword ptr [RBP + -0x250],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
LEA R13,[RBP + -0x240]
MOV RDI,R13
CALL 0x001a894b
CMP byte ptr [R13],0x7e
JNZ 0x001a8b0d
MOV R14,RAX
LEA R15,[RBP + -0x23f]
CMP byte ptr [R15],0x2f
JNZ 0x001a8a2d
LEA RBX,[0x5276d8]
JMP 0x001a8a86
LAB_001a8a2d:
MOV RDI,R15
MOV ESI,0x2f
CALL 0x001394f0
MOV R12,RAX
TEST RAX,RAX
JNZ 0x001a8a4d
MOV RDI,R15
CALL 0x001dcfb4
MOV R12,RAX
LAB_001a8a4d:
MOV AL,byte ptr [R12]
MOV byte ptr [RBP + -0x241],AL
MOV byte ptr [R12],0x0
MOV RDI,R15
CALL 0x00139710
MOV RBX,RAX
MOV AL,byte ptr [RBP + -0x241]
MOV byte ptr [R12],AL
CALL 0x00139b60
TEST RBX,RBX
JZ 0x001a8b0d
ADD RBX,0x20
MOV R15,R12
LAB_001a8a86:
MOV R12,qword ptr [RBX]
TEST R12,R12
JZ 0x001a8b0d
ADD R14,R13
SUB R14,R15
MOV RDI,R12
CALL 0x00139400
MOV R13,RAX
ADD RAX,R14
INC RAX
CMP RAX,0x200
JA 0x001a8b0d
TEST R13,R13
JZ 0x001a8ac2
XOR EAX,EAX
CMP byte ptr [R12 + R13*0x1 + -0x1],0x2f
SETZ AL
SUB R13,RAX
JMP 0x001a8ac5
LAB_001a8ac2:
XOR R13D,R13D
LAB_001a8ac5:
INC R14
LEA RDI,[-0x240 + R13*0x1]
ADD RDI,RBP
CMP RDI,R15
JNC 0x001a8ae5
MOV RSI,R15
MOV RDX,R14
CALL 0x00139140
JMP 0x001a8af6
LAB_001a8ae5:
ADD RDI,R14
ADD R15,R14
MOV RSI,R15
MOV RDX,R14
CALL 0x001b0ae0
LAB_001a8af6:
LEA RDI,[RBP + -0x240]
MOV ECX,0x205
MOV RSI,R12
MOV RDX,R13
CALL 0x001395a0
LAB_001a8b0d:
LEA RSI,[RBP + -0x240]
MOV EDX,0x1ff
MOV RBX,qword ptr [RBP + -0x250]
MOV RDI,RBX
CALL 0x001dcffc
MOV RCX,qword ptr FS:[0x28]
CMP RCX,qword ptr [RBP + -0x30]
JNZ 0x001a8b4c
SUB RAX,RBX
ADD RSP,0x228
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_001a8b4c:
CALL 0x00139290
|
long unpack_dirname(long param_1)
{
char *pcVar1;
long lVar2;
char *__src;
passwd *ppVar3;
size_t sVar4;
char **ppcVar5;
char *__dest;
long lVar6;
char *__n;
long in_FS_OFFSET;
char acStack_48f [559];
code *pcStack_260;
long local_258;
char local_249;
char local_248 [528];
long local_38;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
pcStack_260 = (code *)0x1a8a09;
local_258 = param_1;
lVar2 = normalize_dirname(local_248);
if (local_248[0] == '~') {
pcVar1 = local_248 + 1;
if (local_248[1] == '/') {
ppcVar5 = (char **)&home_dir;
__src = pcVar1;
}
else {
pcStack_260 = (code *)0x1a8a3a;
__src = strchr(pcVar1,0x2f);
if (__src == (char *)0x0) {
pcStack_260 = (code *)0x1a8a4a;
__src = (char *)strend(pcVar1);
}
local_249 = *__src;
*__src = '\0';
pcStack_260 = (code *)0x1a8a64;
ppVar3 = getpwnam(pcVar1);
*__src = local_249;
pcStack_260 = (code *)0x1a8a76;
endpwent();
if (ppVar3 == (passwd *)0x0) goto LAB_001a8b0d;
ppcVar5 = &ppVar3->pw_dir;
}
pcVar1 = *ppcVar5;
if (pcVar1 != (char *)0x0) {
pcStack_260 = (code *)0x1a8a9c;
sVar4 = strlen(pcVar1);
if (local_248 + sVar4 + (lVar2 - (long)__src) + 1 < (char *)0x201) {
if (sVar4 == 0) {
lVar6 = 0;
}
else {
lVar6 = sVar4 - (pcVar1[sVar4 - 1] == '/');
}
__n = local_248 + (lVar2 - (long)__src) + 1;
__dest = local_248 + lVar6;
if (__dest < __src) {
pcStack_260 = (code *)0x1a8ae3;
memmove(__dest,__src,(size_t)__n);
}
else {
pcStack_260 = (code *)0x1a8af6;
bmove_upp(__dest + (long)__n,__src + (long)__n,__n);
}
pcStack_260 = (code *)0x1a8b0d;
__memmove_chk(local_248,pcVar1,lVar6,0x205);
}
}
}
LAB_001a8b0d:
lVar2 = local_258;
pcStack_260 = (code *)0x1a8b28;
lVar6 = strmake(local_258,local_248,0x1ff);
if (*(long *)(in_FS_OFFSET + 0x28) == local_38) {
return lVar6 - lVar2;
}
/* WARNING: Subroutine does not return */
pcStack_260 = system_filename;
__stack_chk_fail();
}
| |
22,101 | intx::internal::add(unsigned long*, unsigned long const*, unsigned long const*, int) | corpus-core[P]colibri-stateless/build_O0/_deps/intx-src/include/intx/intx.hpp | inline bool add(uint64_t s[], const uint64_t x[], const uint64_t y[], int len) noexcept
{
// OPT: Add MinLen template parameter and unroll first loop iterations.
INTX_REQUIRE(len >= 2);
bool carry = false;
for (int i = 0; i < len; ++i)
std::tie(s[i], carry) = addc(x[i], y[i], carry);
return carry;
} | O0 | cpp | intx::internal::add(unsigned long*, unsigned long const*, unsigned long const*, int):
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
cmpl $0x2, -0x1c(%rbp)
jl 0x62eff
jmp 0x62f1e
leaq 0x7a40b(%rip), %rdi # 0xdd311
leaq 0x7a35b(%rip), %rsi # 0xdd268
movl $0x670, %edx # imm = 0x670
leaq 0x7a595(%rip), %rcx # 0xdd4ae
callq 0x23160
movb $0x0, -0x1d(%rbp)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x1c(%rbp), %eax
jge 0x62f9e
movq -0x10(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
movq -0x18(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rsi
movb -0x1d(%rbp), %al
andb $0x1, %al
movzbl %al, %edx
callq 0x5fd80
movq %rax, -0x48(%rbp)
movb %dl, -0x40(%rbp)
leaq -0x38(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x62e20
movq -0x8(%rbp), %rsi
movslq -0x24(%rbp), %rax
shlq $0x3, %rax
addq %rax, %rsi
leaq -0x58(%rbp), %rdi
leaq -0x1d(%rbp), %rdx
callq 0x62e60
leaq -0x58(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x62ea0
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x62f29
movb -0x1d(%rbp), %al
andb $0x1, %al
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
| _ZN4intx8internal3addEPmPKmS3_i:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_1C], ecx
cmp [rbp+var_1C], 2
jl short loc_62EFF
jmp short loc_62F1E
loc_62EFF:
lea rdi, aLen2; "len >= 2"
lea rsi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github/2025_star3"...
mov edx, 670h
lea rcx, aBoolIntxIntern; "bool intx::internal::add(uint64_t *, co"...
call ___assert_fail
loc_62F1E:
mov [rbp+var_1D], 0
mov [rbp+var_24], 0
loc_62F29:
mov eax, [rbp+var_24]
cmp eax, [rbp+var_1C]
jge short loc_62F9E
mov rax, [rbp+var_10]
movsxd rcx, [rbp+var_24]
mov rdi, [rax+rcx*8]; this
mov rax, [rbp+var_18]
movsxd rcx, [rbp+var_24]; bool
mov rsi, [rax+rcx*8]; unsigned __int64
mov al, [rbp+var_1D]
and al, 1
movzx edx, al; unsigned __int64
call _ZN4intx4addcEmmb; intx::addc(ulong,ulong,bool)
mov [rbp+var_48], rax
mov [rbp+var_40], dl
lea rdi, [rbp+var_38]
lea rsi, [rbp+var_48]
call _ZN4intx17result_with_carryImEcvSt5tupleIJRmRbEEEv; intx::result_with_carry<ulong>::operator std::tuple<ulong &,bool &>(void)
mov rsi, [rbp+var_8]
movsxd rax, [rbp+var_24]
shl rax, 3
add rsi, rax
lea rdi, [rbp+var_58]
lea rdx, [rbp+var_1D]
call _ZSt3tieIJmbEESt5tupleIJDpRT_EES3_; std::tie<ulong,bool>(ulong,bool &)
lea rdi, [rbp+var_58]
lea rsi, [rbp+var_38]
call _ZNSt5tupleIJRmRbEEaSEOS2_; std::tuple<ulong &,bool &>::operator=(std::tuple<ulong &,bool &>&&)
mov eax, [rbp+var_24]
add eax, 1
mov [rbp+var_24], eax
jmp short loc_62F29
loc_62F9E:
mov al, [rbp+var_1D]
and al, 1
add rsp, 60h
pop rbp
retn
| char intx::internal::add(
intx::internal *this,
unsigned long long *a2,
const unsigned long long *a3,
const unsigned long long *a4)
{
char v4; // dl
_BYTE v6[16]; // [rsp+8h] [rbp-58h] BYREF
long long v7; // [rsp+18h] [rbp-48h] BYREF
char v8; // [rsp+20h] [rbp-40h]
_BYTE v9[20]; // [rsp+28h] [rbp-38h] BYREF
int i; // [rsp+3Ch] [rbp-24h]
char v11; // [rsp+43h] [rbp-1Dh] BYREF
int v12; // [rsp+44h] [rbp-1Ch]
const unsigned long long *v13; // [rsp+48h] [rbp-18h]
unsigned long long *v14; // [rsp+50h] [rbp-10h]
intx::internal *v15; // [rsp+58h] [rbp-8h]
v15 = this;
v14 = a2;
v13 = a3;
v12 = (int)a4;
if ( (int)a4 < 2 )
__assert_fail(
"len >= 2",
"/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O0/_deps/intx-src/include/intx/intx.hpp",
1648LL,
"bool intx::internal::add(uint64_t *, const uint64_t *, const uint64_t *, int)");
v11 = 0;
for ( i = 0; i < v12; ++i )
{
v7 = intx::addc((intx *)v14[i], v13[i], v11 & 1);
v8 = v4;
intx::result_with_carry<unsigned long>::operator std::tuple<unsigned long &,bool &>((long long)v9, (long long)&v7);
std::tie<unsigned long,bool>((long long)v6, (long long)v15 + 8 * i, (long long)&v11);
std::tuple<unsigned long &,bool &>::operator=((long long)v6);
}
return v11 & 1;
}
| add:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV dword ptr [RBP + -0x1c],ECX
CMP dword ptr [RBP + -0x1c],0x2
JL 0x00162eff
JMP 0x00162f1e
LAB_00162eff:
LEA RDI,[0x1dd311]
LEA RSI,[0x1dd268]
MOV EDX,0x670
LEA RCX,[0x1dd4ae]
CALL 0x00123160
LAB_00162f1e:
MOV byte ptr [RBP + -0x1d],0x0
MOV dword ptr [RBP + -0x24],0x0
LAB_00162f29:
MOV EAX,dword ptr [RBP + -0x24]
CMP EAX,dword ptr [RBP + -0x1c]
JGE 0x00162f9e
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,dword ptr [RBP + -0x24]
MOV RDI,qword ptr [RAX + RCX*0x8]
MOV RAX,qword ptr [RBP + -0x18]
MOVSXD RCX,dword ptr [RBP + -0x24]
MOV RSI,qword ptr [RAX + RCX*0x8]
MOV AL,byte ptr [RBP + -0x1d]
AND AL,0x1
MOVZX EDX,AL
CALL 0x0015fd80
MOV qword ptr [RBP + -0x48],RAX
MOV byte ptr [RBP + -0x40],DL
LEA RDI,[RBP + -0x38]
LEA RSI,[RBP + -0x48]
CALL 0x00162e20
MOV RSI,qword ptr [RBP + -0x8]
MOVSXD RAX,dword ptr [RBP + -0x24]
SHL RAX,0x3
ADD RSI,RAX
LEA RDI,[RBP + -0x58]
LEA RDX,[RBP + -0x1d]
CALL 0x00162e60
LEA RDI,[RBP + -0x58]
LEA RSI,[RBP + -0x38]
CALL 0x00162ea0
MOV EAX,dword ptr [RBP + -0x24]
ADD EAX,0x1
MOV dword ptr [RBP + -0x24],EAX
JMP 0x00162f29
LAB_00162f9e:
MOV AL,byte ptr [RBP + -0x1d]
AND AL,0x1
ADD RSP,0x60
POP RBP
RET
|
/* intx::internal::add(unsigned long*, unsigned long const*, unsigned long const*, int) */
uint intx::internal::add(ulong *param_1,ulong *param_2,ulong *param_3,int param_4)
{
int1 extraout_DL;
tuple<unsigned_long&,bool&> local_60 [16];
int8 local_50;
int1 local_48;
result_with_carry local_40 [20];
int local_2c;
byte local_25;
int local_24;
ulong *local_20;
ulong *local_18;
ulong *local_10;
local_24 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
if (1 < param_4) {
local_25 = 0;
for (local_2c = 0; local_2c < local_24; local_2c = local_2c + 1) {
local_50 = addc(local_18[local_2c],local_20[local_2c],(bool)(local_25 & 1));
local_48 = extraout_DL;
result_with_carry::operator_cast_to_tuple(local_40);
std::tie<unsigned_long,bool>((ulong *)local_60,(bool *)(local_10 + local_2c));
std::tuple<unsigned_long&,bool&>::operator=(local_60,(tuple *)local_40);
}
return CONCAT31((int3)((uint)local_2c >> 8),local_25) & 0xffffff01;
}
/* WARNING: Subroutine does not return */
__assert_fail("len >= 2",
"/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O0/_deps/intx-src/include/intx/intx.hpp"
,0x670,
"bool intx::internal::add(uint64_t *, const uint64_t *, const uint64_t *, int)");
}
| |
22,102 | uf_varchar1 | eloqsql/storage/myisam/mi_packrec.c | static void uf_varchar1(MI_COLUMNDEF *rec, MI_BIT_BUFF *bit_buff,
uchar *to, uchar *end __attribute__((unused)))
{
if (get_bit(bit_buff))
to[0]= 0; /* Zero lengths */
else
{
ulong length=get_bits(bit_buff,rec->space_length_bits);
*to= (uchar) length;
decode_bytes(rec,bit_buff,to+1,to+1+length);
}
} | O3 | c | uf_varchar1:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movl 0x4(%rsi), %eax
testl %eax, %eax
je 0x3cc22
movl (%r14), %r13d
decl %eax
movl %eax, 0x4(%r14)
btl %eax, %r13d
jae 0x3cc3f
movb $0x0, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r14, %rdi
callq 0x3b5a9
movl $0x1f, 0x4(%r14)
movl (%r14), %r13d
movl $0x1f, %eax
testl %r13d, %r13d
js 0x3cc10
movl 0x1c(%r15), %r12d
movl %eax, %ecx
subl %r12d, %ecx
jae 0x3cc84
subl %eax, %r12d
movl %eax, %eax
leaq 0x5f7ea(%rip), %rcx # 0x9c440
andl (%rcx,%rax,4), %r13d
movl %r12d, %ecx
shll %cl, %r13d
movq %r14, %rdi
callq 0x3b5a9
movl $0x20, %eax
subl %r12d, %eax
movl %eax, 0x4(%r14)
movl (%r14), %eax
negl %r12d
movl %r12d, %ecx
shrl %cl, %eax
addl %eax, %r13d
jmp 0x3cc9a
movl %ecx, 0x4(%r14)
shrl %cl, %r13d
movl 0x1c(%r15), %eax
leaq 0x5f7aa(%rip), %rcx # 0x9c440
andl (%rcx,%rax,4), %r13d
movl %r13d, %eax
movb %r13b, (%rbx)
leaq (%rbx,%rax), %rcx
incq %rcx
incq %rbx
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3be9a
| uf_varchar1:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov rbx, rdx
mov r14, rsi
mov r15, rdi
mov eax, [rsi+4]
test eax, eax
jz short loc_3CC22
mov r13d, [r14]
dec eax
mov [r14+4], eax
bt r13d, eax
jnb short loc_3CC3F
loc_3CC10:
mov byte ptr [rbx], 0
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3CC22:
mov rdi, r14
call fill_buffer
mov dword ptr [r14+4], 1Fh
mov r13d, [r14]
mov eax, 1Fh
test r13d, r13d
js short loc_3CC10
loc_3CC3F:
mov r12d, [r15+1Ch]
mov ecx, eax
sub ecx, r12d
jnb short loc_3CC84
sub r12d, eax
mov eax, eax
lea rcx, mask
and r13d, [rcx+rax*4]
mov ecx, r12d
shl r13d, cl
mov rdi, r14
call fill_buffer
mov eax, 20h ; ' '
sub eax, r12d
mov [r14+4], eax
mov eax, [r14]
neg r12d
mov ecx, r12d
shr eax, cl
add r13d, eax
jmp short loc_3CC9A
loc_3CC84:
mov [r14+4], ecx
shr r13d, cl
mov eax, [r15+1Ch]
lea rcx, mask
and r13d, [rcx+rax*4]
loc_3CC9A:
mov eax, r13d
mov [rbx], r13b
lea rcx, [rbx+rax]
inc rcx
inc rbx
mov rdi, r15
mov rsi, r14
mov rdx, rbx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp decode_bytes
| long long uf_varchar1(long long a1, unsigned int *a2, _BYTE *a3)
{
unsigned int v4; // eax
unsigned int v5; // r13d
long long result; // rax
unsigned int v7; // r12d
unsigned int v8; // ecx
int v9; // r12d
int v10; // r13d
unsigned int v11; // r13d
v4 = a2[1];
if ( v4 )
{
v5 = *a2;
result = v4 - 1;
a2[1] = result;
if ( _bittest((const int *)&v5, result) )
{
LABEL_3:
*a3 = 0;
return result;
}
}
else
{
fill_buffer((long long)a2);
a2[1] = 31;
v5 = *a2;
result = 31LL;
if ( (*a2 & 0x80000000) != 0 )
goto LABEL_3;
}
v7 = *(_DWORD *)(a1 + 28);
v8 = result - v7;
if ( (unsigned int)result >= v7 )
{
a2[1] = v8;
v11 = mask[*(unsigned int *)(a1 + 28)] & (v5 >> v8);
}
else
{
v9 = v7 - result;
v10 = (mask[(unsigned int)result] & v5) << v9;
fill_buffer((long long)a2);
a2[1] = 32 - v9;
v11 = (*a2 >> -(char)v9) + v10;
}
*a3 = v11;
return (long long)decode_bytes(a1, (long long)a2, a3 + 1, &a3[v11 + 1]);
}
| uf_varchar1:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDX
MOV R14,RSI
MOV R15,RDI
MOV EAX,dword ptr [RSI + 0x4]
TEST EAX,EAX
JZ 0x0013cc22
MOV R13D,dword ptr [R14]
DEC EAX
MOV dword ptr [R14 + 0x4],EAX
BT R13D,EAX
JNC 0x0013cc3f
LAB_0013cc10:
MOV byte ptr [RBX],0x0
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0013cc22:
MOV RDI,R14
CALL 0x0013b5a9
MOV dword ptr [R14 + 0x4],0x1f
MOV R13D,dword ptr [R14]
MOV EAX,0x1f
TEST R13D,R13D
JS 0x0013cc10
LAB_0013cc3f:
MOV R12D,dword ptr [R15 + 0x1c]
MOV ECX,EAX
SUB ECX,R12D
JNC 0x0013cc84
SUB R12D,EAX
MOV EAX,EAX
LEA RCX,[0x19c440]
AND R13D,dword ptr [RCX + RAX*0x4]
MOV ECX,R12D
SHL R13D,CL
MOV RDI,R14
CALL 0x0013b5a9
MOV EAX,0x20
SUB EAX,R12D
MOV dword ptr [R14 + 0x4],EAX
MOV EAX,dword ptr [R14]
NEG R12D
MOV ECX,R12D
SHR EAX,CL
ADD R13D,EAX
JMP 0x0013cc9a
LAB_0013cc84:
MOV dword ptr [R14 + 0x4],ECX
SHR R13D,CL
MOV EAX,dword ptr [R15 + 0x1c]
LEA RCX,[0x19c440]
AND R13D,dword ptr [RCX + RAX*0x4]
LAB_0013cc9a:
MOV EAX,R13D
MOV byte ptr [RBX],R13B
LEA RCX,[RBX + RAX*0x1]
INC RCX
INC RBX
MOV RDI,R15
MOV RSI,R14
MOV RDX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x0013be9a
|
void uf_varchar1(long param_1,uint *param_2,int1 *param_3)
{
uint uVar1;
uint uVar2;
uint uVar3;
byte bVar4;
uint uVar5;
if (param_2[1] == 0) {
fill_buffer(param_2);
param_2[1] = 0x1f;
uVar5 = *param_2;
uVar3 = 0x1f;
if (-1 < (int)uVar5) goto LAB_0013cc3f;
}
else {
uVar5 = *param_2;
uVar3 = param_2[1] - 1;
param_2[1] = uVar3;
if ((uVar5 >> (uVar3 & 0x1f) & 1) == 0) {
LAB_0013cc3f:
uVar1 = *(uint *)(param_1 + 0x1c);
if (uVar3 < uVar1) {
uVar2 = (&mask)[uVar3];
bVar4 = (byte)(uVar1 - uVar3);
fill_buffer(param_2);
param_2[1] = 0x20 - (uVar1 - uVar3);
uVar5 = ((uVar5 & uVar2) << (bVar4 & 0x1f)) + (*param_2 >> (-bVar4 & 0x1f));
}
else {
param_2[1] = uVar3 - uVar1;
uVar5 = uVar5 >> ((byte)(uVar3 - uVar1) & 0x1f) & (&mask)[*(uint *)(param_1 + 0x1c)];
}
*param_3 = (char)uVar5;
decode_bytes(param_1,param_2,param_3 + 1,param_3 + (ulong)uVar5 + 1);
return;
}
}
*param_3 = 0;
return;
}
| |
22,103 | convert_dirname | eloqsql/mysys/mf_dirname.c | char *convert_dirname(char *to, const char *from, const char *from_end)
{
char *to_org=to;
#ifdef BACKSLASH_MBTAIL
CHARSET_INFO *fs= fs_character_set();
#endif
DBUG_ENTER("convert_dirname");
/* We use -2 here, becasue we need place for the last FN_LIBCHAR */
if (!from_end || (from_end - from) > FN_REFLEN-2)
from_end=from+FN_REFLEN -2;
#if FN_LIBCHAR != '/'
{
for (; from != from_end && *from ; from++)
{
if (*from == '/')
*to++= FN_LIBCHAR;
else
{
#ifdef BACKSLASH_MBTAIL
uint l;
if (my_ci_use_mb(fs) && (l= my_ismbchar(fs, from, from + 3)))
{
memmove(to, from, l);
to+= l;
from+= l - 1;
to_org= to; /* Don't look inside mbchar */
}
else
#endif
{
*to++= *from;
}
}
}
*to=0;
}
#else
/* This is ok even if to == from, becasue we need to cut the string */
to= strmake(to, from, (size_t) (from_end-from));
#endif
/* Add FN_LIBCHAR to the end of directory path */
if (to != to_org && (to[-1] != FN_LIBCHAR && to[-1] != FN_DEVCHAR))
{
*to++=FN_LIBCHAR;
*to=0;
}
DBUG_RETURN(to); /* Pointer to end of dir */
} | O3 | c | convert_dirname:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq %rdx, %rax
subq %rsi, %rax
leaq 0x1fe(%rsi), %rcx
cmpq $0x1ff, %rax # imm = 0x1FF
movq %rdx, %rax
cmovgeq %rcx, %rax
testq %rdx, %rdx
cmoveq %rcx, %rax
subq %rsi, %rax
movq %rax, %rdx
callq 0x5f56c
cmpq %rbx, %rax
je 0x30cb2
movzbl -0x1(%rax), %ecx
testl %ecx, %ecx
je 0x30cb2
cmpl $0x2f, %ecx
je 0x30cb2
movw $0x2f, (%rax)
incq %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
nopl (%rax)
| convert_dirname:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdi
mov rax, rdx
sub rax, rsi
lea rcx, [rsi+1FEh]
cmp rax, 1FFh
mov rax, rdx
cmovge rax, rcx
test rdx, rdx
cmovz rax, rcx
sub rax, rsi
mov rdx, rax
call strmake
cmp rax, rbx
jz short loc_30CB2
movzx ecx, byte ptr [rax-1]
test ecx, ecx
jz short loc_30CB2
cmp ecx, 2Fh ; '/'
jz short loc_30CB2
mov word ptr [rax], 2Fh ; '/'
inc rax
loc_30CB2:
add rsp, 8
pop rbx
pop rbp
retn
| _WORD * convert_dirname(_WORD *a1, long long a2, long long a3)
{
long long v3; // rax
_WORD *result; // rax
v3 = a3;
if ( a3 - a2 >= 511 )
v3 = a2 + 510;
if ( !a3 )
v3 = a2 + 510;
result = (_WORD *)strmake(a1, a2, v3 - a2);
if ( result != a1 && *((_BYTE *)result - 1) && *((_BYTE *)result - 1) != 47 )
{
*result = 47;
return (_WORD *)((char *)result + 1);
}
return result;
}
| convert_dirname:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV RAX,RDX
SUB RAX,RSI
LEA RCX,[RSI + 0x1fe]
CMP RAX,0x1ff
MOV RAX,RDX
CMOVGE RAX,RCX
TEST RDX,RDX
CMOVZ RAX,RCX
SUB RAX,RSI
MOV RDX,RAX
CALL 0x0015f56c
CMP RAX,RBX
JZ 0x00130cb2
MOVZX ECX,byte ptr [RAX + -0x1]
TEST ECX,ECX
JZ 0x00130cb2
CMP ECX,0x2f
JZ 0x00130cb2
MOV word ptr [RAX],0x2f
INC RAX
LAB_00130cb2:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
int2 * convert_dirname(int2 *param_1,long param_2,long param_3)
{
long lVar1;
int2 *puVar2;
lVar1 = param_3;
if (0x1fe < param_3 - param_2) {
lVar1 = param_2 + 0x1fe;
}
if (param_3 == 0) {
lVar1 = param_2 + 0x1fe;
}
puVar2 = (int2 *)strmake(param_1,param_2,lVar1 - param_2);
if (((puVar2 != param_1) && (*(char *)((long)puVar2 + -1) != '\0')) &&
(*(char *)((long)puVar2 + -1) != '/')) {
*puVar2 = 0x2f;
puVar2 = (int2 *)((long)puVar2 + 1);
}
return puVar2;
}
| |
22,104 | ma_set_fatal_error | eloqsql/storage/maria/ma_info.c | void _ma_set_fatal_error(MARIA_HA *info, int error)
{
MARIA_SHARE *share= info->s;
_ma_print_error(info, error,
(share->state.changed & STATE_CRASHED_PRINTED) == 0);
maria_mark_crashed_share(share);
share->state.changed|= STATE_CRASHED_PRINTED;
my_errno= error;
DBUG_ASSERT(!maria_assert_if_crashed_table);
} | O3 | c | ma_set_fatal_error:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %esi, %ebx
movq (%rdi), %r14
xorl %edx, %edx
btl $0xb, 0x170(%r14)
setae %dl
callq 0x5ca52
orl $0x802, 0x170(%r14) # imm = 0x802
callq 0xc14ee
movl %ebx, (%rax)
popq %rbx
popq %r14
popq %rbp
retq
| _ma_set_fatal_error:
push rbp
mov rbp, rsp
push r14
push rbx
mov ebx, esi
mov r14, [rdi]
xor edx, edx
bt dword ptr [r14+170h], 0Bh
setnb dl
call _ma_print_error
or dword ptr [r14+170h], 802h
call _my_thread_var
mov [rax], ebx
pop rbx
pop r14
pop rbp
retn
| int * ma_set_fatal_error(_DWORD *a1, int a2, long long a3, long long a4, long long a5, int a6)
{
long long v6; // r14
int *result; // rax
v6 = *(_QWORD *)a1;
ma_print_error(a1, a2, !_bittest((const signed __int32 *)(*(_QWORD *)a1 + 368LL), 0xBu), a4, a5, a6);
*(_DWORD *)(v6 + 368) |= 0x802u;
result = (int *)my_thread_var(a1);
*result = a2;
return result;
}
| _ma_set_fatal_error:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV EBX,ESI
MOV R14,qword ptr [RDI]
XOR EDX,EDX
BT dword ptr [R14 + 0x170],0xb
SETNC DL
CALL 0x0015ca52
OR dword ptr [R14 + 0x170],0x802
CALL 0x001c14ee
MOV dword ptr [RAX],EBX
POP RBX
POP R14
POP RBP
RET
|
void _ma_set_fatal_error(long *param_1,int4 param_2)
{
uint *puVar1;
long lVar2;
int4 *puVar3;
lVar2 = *param_1;
_ma_print_error(param_1,param_2,(*(uint *)(lVar2 + 0x170) >> 0xb & 1) == 0);
puVar1 = (uint *)(lVar2 + 0x170);
*puVar1 = *puVar1 | 0x802;
puVar3 = (int4 *)_my_thread_var();
*puVar3 = param_2;
return;
}
| |
22,105 | copy_decode_table | eloqsql/storage/maria/ma_packrec.c | static uint copy_decode_table(uint16 *to_pos, uint offset,
uint16 *decode_table)
{
uint prev_offset= offset;
DBUG_ENTER("copy_decode_table");
/* Descent on the left side. */
if (!(*decode_table & IS_CHAR))
{
/* Set a pointer to the next target node. */
to_pos[offset]=2;
/* Copy the left hand subtree there. */
offset=copy_decode_table(to_pos,offset+2,decode_table+ *decode_table);
}
else
{
/* Copy the uchar value. */
to_pos[offset]= *decode_table;
/* Step behind this node. */
offset+=2;
}
/* Descent on the right side. */
decode_table++;
if (!(*decode_table & IS_CHAR))
{
/* Set a pointer to the next free target node. */
to_pos[prev_offset+1]=(uint16) (offset-prev_offset-1);
/* Copy the right hand subtree to the entry of that node. */
offset=copy_decode_table(to_pos,offset,decode_table+ *decode_table);
}
else
{
/* Copy the uchar value. */
to_pos[prev_offset+1]= *decode_table;
}
DBUG_RETURN(offset);
} | O3 | c | copy_decode_table:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movl %esi, %eax
movq %rdi, %rbx
movzwl (%r14), %ecx
movl %eax, %r15d
addl $0x2, %eax
testw %cx, %cx
js 0x47216
movw $0x2, (%rbx,%r15,2)
movzwl (%r14), %ecx
leaq (%r14,%rcx,2), %rdx
movq %rbx, %rdi
movl %eax, %esi
callq 0x471da
jmp 0x4721b
movw %cx, (%rbx,%r15,2)
movzwl 0x2(%r14), %ecx
testw %cx, %cx
js 0x47242
addq $0x2, %r14
movl %r15d, %ecx
notl %ecx
addl %eax, %ecx
incl %r15d
movw %cx, (%rbx,%r15,2)
movzwl (%r14), %ecx
leaq (%r14,%rcx,2), %r14
jmp 0x471ec
incl %r15d
movw %cx, (%rbx,%r15,2)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| copy_decode_table:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov r14, rdx
mov eax, esi
mov rbx, rdi
loc_471EC:
movzx ecx, word ptr [r14]
mov r15d, eax
add eax, 2
test cx, cx
js short loc_47216
mov word ptr [rbx+r15*2], 2
movzx ecx, word ptr [r14]
lea rdx, [r14+rcx*2]
mov rdi, rbx
mov esi, eax
call copy_decode_table
jmp short loc_4721B
loc_47216:
mov [rbx+r15*2], cx
loc_4721B:
movzx ecx, word ptr [r14+2]
test cx, cx
js short loc_47242
add r14, 2
mov ecx, r15d
not ecx
add ecx, eax
inc r15d
mov [rbx+r15*2], cx
movzx ecx, word ptr [r14]
lea r14, [r14+rcx*2]
jmp short loc_471EC
loc_47242:
inc r15d
mov [rbx+r15*2], cx
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
| long long copy_decode_table(long long a1, int a2, unsigned __int16 *a3)
{
long long result; // rax
long long v5; // r15
__int16 v6; // cx
LODWORD(result) = a2;
while ( 1 )
{
v5 = (unsigned int)result;
result = (unsigned int)(result + 2);
if ( (*a3 & 0x8000u) != 0 )
{
*(_WORD *)(a1 + 2 * v5) = *a3;
}
else
{
*(_WORD *)(a1 + 2 * v5) = 2;
result = copy_decode_table(a1, (unsigned int)result, &a3[*a3]);
}
v6 = a3[1];
if ( v6 < 0 )
break;
*(_WORD *)(a1 + 2LL * (unsigned int)(v5 + 1)) = result + ~(_WORD)v5;
a3 += a3[1] + 1;
}
*(_WORD *)(a1 + 2LL * (unsigned int)(v5 + 1)) = v6;
return result;
}
| copy_decode_table:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RDX
MOV EAX,ESI
MOV RBX,RDI
LAB_001471ec:
MOVZX ECX,word ptr [R14]
MOV R15D,EAX
ADD EAX,0x2
TEST CX,CX
JS 0x00147216
MOV word ptr [RBX + R15*0x2],0x2
MOVZX ECX,word ptr [R14]
LEA RDX,[R14 + RCX*0x2]
MOV RDI,RBX
MOV ESI,EAX
CALL 0x001471da
JMP 0x0014721b
LAB_00147216:
MOV word ptr [RBX + R15*0x2],CX
LAB_0014721b:
MOVZX ECX,word ptr [R14 + 0x2]
TEST CX,CX
JS 0x00147242
ADD R14,0x2
MOV ECX,R15D
NOT ECX
ADD ECX,EAX
INC R15D
MOV word ptr [RBX + R15*0x2],CX
MOVZX ECX,word ptr [R14]
LEA R14,[R14 + RCX*0x2]
JMP 0x001471ec
LAB_00147242:
INC R15D
MOV word ptr [RBX + R15*0x2],CX
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
|
void copy_decode_table(long param_1,uint param_2,ushort *param_3)
{
uint uVar1;
while( true ) {
uVar1 = param_2 + 2;
if ((short)*param_3 < 0) {
*(ushort *)(param_1 + (ulong)param_2 * 2) = *param_3;
}
else {
*(int2 *)(param_1 + (ulong)param_2 * 2) = 2;
uVar1 = copy_decode_table(param_1,uVar1,param_3 + *param_3);
}
if ((short)param_3[1] < 0) break;
*(ushort *)(param_1 + (ulong)(param_2 + 1) * 2) = ~(ushort)param_2 + (short)uVar1;
param_3 = param_3 + 1 + param_3[1];
param_2 = uVar1;
}
*(ushort *)(param_1 + (ulong)(param_2 + 1) * 2) = param_3[1];
return;
}
| |
22,106 | js_shape_prepare_update | bluesky950520[P]quickjs/quickjs.c | static int js_shape_prepare_update(JSContext *ctx, JSObject *p,
JSShapeProperty **pprs)
{
JSShape *sh;
uint32_t idx = 0; /* prevent warning */
sh = p->shape;
if (sh->is_hashed) {
if (sh->header.ref_count != 1) {
if (pprs)
idx = *pprs - get_shape_prop(sh);
/* clone the shape (the resulting one is no longer hashed) */
sh = js_clone_shape(ctx, sh);
if (!sh)
return -1;
js_free_shape(ctx->rt, p->shape);
p->shape = sh;
if (pprs)
*pprs = get_shape_prop(sh) + idx;
} else {
js_shape_hash_unlink(ctx->rt, sh);
sh->is_hashed = FALSE;
}
}
return 0;
} | O1 | c | js_shape_prepare_update:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %r14
movq 0x18(%rsi), %rsi
cmpb $0x0, 0x18(%rsi)
je 0x2a3d4
movq %rdi, %r15
cmpl $0x1, (%rsi)
jne 0x2a3e0
movq 0x18(%r15), %rax
movl 0x1c(%rsi), %edx
xorl %ecx, %ecx
subb 0x184(%rax), %cl
shrl %cl, %edx
shlq $0x3, %rdx
addq 0x190(%rax), %rdx
movq %rdx, %rcx
movq (%rdx), %rdi
leaq 0x30(%rdi), %rdx
cmpq %rsi, %rdi
jne 0x2a3b4
movq 0x30(%rsi), %rdx
movq %rdx, (%rcx)
decl 0x18c(%rax)
movb $0x0, 0x18(%rsi)
xorl %eax, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rdx, %rbx
testq %rdx, %rdx
jne 0x2a3ed
xorl %r13d, %r13d
jmp 0x2a3fe
movq (%rbx), %rax
subq %rsi, %rax
addq $-0x40, %rax
shrq $0x3, %rax
movl %eax, %r13d
movq %r15, %rdi
callq 0x10cbd
testq %rax, %rax
je 0x2a43a
movq %rax, %r12
movq 0x18(%r15), %rdi
movq 0x18(%r14), %rsi
movl (%rsi), %eax
leal -0x1(%rax), %ecx
movl %ecx, (%rsi)
cmpl $0x1, %eax
jle 0x2a441
xorl %eax, %eax
movq %r12, 0x18(%r14)
testq %rbx, %rbx
je 0x2a3d6
leaq (%r12,%r13,8), %rcx
addq $0x40, %rcx
movq %rcx, (%rbx)
jmp 0x2a3d6
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
jmp 0x2a3d6
callq 0x3fcca
jmp 0x2a422
| js_shape_prepare_update:
push r15
push r14
push r13
push r12
push rbx
mov r14, rsi
mov rsi, [rsi+18h]
cmp byte ptr [rsi+18h], 0
jz short loc_2A3D4
mov r15, rdi
cmp dword ptr [rsi], 1
jnz short loc_2A3E0
mov rax, [r15+18h]
mov edx, [rsi+1Ch]
xor ecx, ecx
sub cl, [rax+184h]
shr edx, cl
shl rdx, 3
add rdx, [rax+190h]
loc_2A3B4:
mov rcx, rdx
mov rdi, [rdx]
lea rdx, [rdi+30h]
cmp rdi, rsi
jnz short loc_2A3B4
mov rdx, [rsi+30h]
mov [rcx], rdx
dec dword ptr [rax+18Ch]
mov byte ptr [rsi+18h], 0
loc_2A3D4:
xor eax, eax
loc_2A3D6:
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
loc_2A3E0:
mov rbx, rdx
test rdx, rdx
jnz short loc_2A3ED
xor r13d, r13d
jmp short loc_2A3FE
loc_2A3ED:
mov rax, [rbx]
sub rax, rsi
add rax, 0FFFFFFFFFFFFFFC0h
shr rax, 3
mov r13d, eax
loc_2A3FE:
mov rdi, r15
call js_clone_shape
test rax, rax
jz short loc_2A43A
mov r12, rax
mov rdi, [r15+18h]
mov rsi, [r14+18h]
mov eax, [rsi]
lea ecx, [rax-1]
mov [rsi], ecx
cmp eax, 1
jle short loc_2A441
loc_2A422:
xor eax, eax
mov [r14+18h], r12
test rbx, rbx
jz short loc_2A3D6
lea rcx, [r12+r13*8]
add rcx, 40h ; '@'
mov [rbx], rcx
jmp short loc_2A3D6
loc_2A43A:
mov eax, 0FFFFFFFFh
jmp short loc_2A3D6
loc_2A441:
call js_free_shape0
jmp short loc_2A422
| long long js_shape_prepare_update(long long a1, long long a2, _QWORD *a3)
{
long long v4; // rsi
long long v5; // rax
_QWORD *v6; // rdx
_QWORD *v7; // rcx
long long v8; // rdi
long long result; // rax
long long v11; // r13
long long v12; // rax
long long v13; // r12
long long v14; // rdi
_DWORD *v15; // rsi
int v16; // eax
v4 = *(_QWORD *)(a2 + 24);
if ( !*(_BYTE *)(v4 + 24) )
return 0LL;
if ( *(_DWORD *)v4 == 1 )
{
v5 = *(_QWORD *)(a1 + 24);
v6 = (_QWORD *)(*(_QWORD *)(v5 + 400) + 8LL * (unsigned int)(*(_DWORD *)(v4 + 28) >> -*(_BYTE *)(v5 + 388)));
do
{
v7 = v6;
v8 = *v6;
v6 = (_QWORD *)(*v6 + 48LL);
}
while ( v8 != v4 );
*v7 = *(_QWORD *)(v4 + 48);
--*(_DWORD *)(v5 + 396);
*(_BYTE *)(v4 + 24) = 0;
return 0LL;
}
if ( a3 )
v11 = (unsigned int)((unsigned long long)(*a3 - v4 - 64) >> 3);
else
v11 = 0LL;
v12 = js_clone_shape(a1, v4);
if ( !v12 )
return 0xFFFFFFFFLL;
v13 = v12;
v14 = *(_QWORD *)(a1 + 24);
v15 = *(_DWORD **)(a2 + 24);
v16 = (*v15)--;
if ( v16 <= 1 )
js_free_shape0(v14, v15);
result = 0LL;
*(_QWORD *)(a2 + 24) = v13;
if ( a3 )
*a3 = v13 + 8 * v11 + 64;
return result;
}
| js_shape_prepare_update:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV R14,RSI
MOV RSI,qword ptr [RSI + 0x18]
CMP byte ptr [RSI + 0x18],0x0
JZ 0x0012a3d4
MOV R15,RDI
CMP dword ptr [RSI],0x1
JNZ 0x0012a3e0
MOV RAX,qword ptr [R15 + 0x18]
MOV EDX,dword ptr [RSI + 0x1c]
XOR ECX,ECX
SUB CL,byte ptr [RAX + 0x184]
SHR EDX,CL
SHL RDX,0x3
ADD RDX,qword ptr [RAX + 0x190]
LAB_0012a3b4:
MOV RCX,RDX
MOV RDI,qword ptr [RDX]
LEA RDX,[RDI + 0x30]
CMP RDI,RSI
JNZ 0x0012a3b4
MOV RDX,qword ptr [RSI + 0x30]
MOV qword ptr [RCX],RDX
DEC dword ptr [RAX + 0x18c]
MOV byte ptr [RSI + 0x18],0x0
LAB_0012a3d4:
XOR EAX,EAX
LAB_0012a3d6:
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
LAB_0012a3e0:
MOV RBX,RDX
TEST RDX,RDX
JNZ 0x0012a3ed
XOR R13D,R13D
JMP 0x0012a3fe
LAB_0012a3ed:
MOV RAX,qword ptr [RBX]
SUB RAX,RSI
ADD RAX,-0x40
SHR RAX,0x3
MOV R13D,EAX
LAB_0012a3fe:
MOV RDI,R15
CALL 0x00110cbd
TEST RAX,RAX
JZ 0x0012a43a
MOV R12,RAX
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,qword ptr [R14 + 0x18]
MOV EAX,dword ptr [RSI]
LEA ECX,[RAX + -0x1]
MOV dword ptr [RSI],ECX
CMP EAX,0x1
JLE 0x0012a441
LAB_0012a422:
XOR EAX,EAX
MOV qword ptr [R14 + 0x18],R12
TEST RBX,RBX
JZ 0x0012a3d6
LEA RCX,[R12 + R13*0x8]
ADD RCX,0x40
MOV qword ptr [RBX],RCX
JMP 0x0012a3d6
LAB_0012a43a:
MOV EAX,0xffffffff
JMP 0x0012a3d6
LAB_0012a441:
CALL 0x0013fcca
JMP 0x0012a422
|
int8 js_shape_prepare_update(long param_1,long param_2,long *param_3)
{
int iVar1;
int *piVar2;
int *piVar3;
int8 uVar4;
int *piVar5;
long lVar6;
int *piVar7;
ulong uVar8;
piVar2 = *(int **)(param_2 + 0x18);
if ((char)piVar2[6] != '\0') {
if (*piVar2 != 1) {
if (param_3 == (long *)0x0) {
uVar8 = 0;
}
else {
uVar8 = (*param_3 - (long)piVar2) - 0x40U >> 3 & 0xffffffff;
}
lVar6 = js_clone_shape(param_1);
if (lVar6 == 0) {
return 0xffffffff;
}
uVar4 = *(int8 *)(param_1 + 0x18);
iVar1 = **(int **)(param_2 + 0x18);
**(int **)(param_2 + 0x18) = iVar1 + -1;
if (iVar1 < 2) {
js_free_shape0(uVar4);
}
*(long *)(param_2 + 0x18) = lVar6;
if (param_3 == (long *)0x0) {
return 0;
}
*param_3 = lVar6 + uVar8 * 8 + 0x40;
return 0;
}
lVar6 = *(long *)(param_1 + 0x18);
piVar5 = (int *)((ulong)((uint)piVar2[7] >> (-*(char *)(lVar6 + 0x184) & 0x1fU)) * 8 +
*(long *)(lVar6 + 400));
do {
piVar7 = piVar5;
piVar3 = *(int **)piVar7;
piVar5 = piVar3 + 0xc;
} while (piVar3 != piVar2);
*(int8 *)piVar7 = *(int8 *)(piVar2 + 0xc);
*(int *)(lVar6 + 0x18c) = *(int *)(lVar6 + 0x18c) + -1;
*(int1 *)(piVar2 + 6) = 0;
}
return 0;
}
| |
22,107 | js_shape_prepare_update | bluesky950520[P]quickjs/quickjs.c | static int js_shape_prepare_update(JSContext *ctx, JSObject *p,
JSShapeProperty **pprs)
{
JSShape *sh;
uint32_t idx = 0; /* prevent warning */
sh = p->shape;
if (sh->is_hashed) {
if (sh->header.ref_count != 1) {
if (pprs)
idx = *pprs - get_shape_prop(sh);
/* clone the shape (the resulting one is no longer hashed) */
sh = js_clone_shape(ctx, sh);
if (!sh)
return -1;
js_free_shape(ctx->rt, p->shape);
p->shape = sh;
if (pprs)
*pprs = get_shape_prop(sh) + idx;
} else {
js_shape_hash_unlink(ctx->rt, sh);
sh->is_hashed = FALSE;
}
}
return 0;
} | O2 | c | js_shape_prepare_update:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq 0x18(%rsi), %r12
xorl %ebp, %ebp
cmpb $0x0, 0x18(%r12)
je 0x23a78
movq %rdi, %r15
cmpl $0x1, (%r12)
jne 0x23a1c
movq 0x18(%r15), %rdi
movq %r12, %rsi
callq 0x386df
movb $0x0, 0x18(%r12)
jmp 0x23a78
movq %rdx, %rbx
movq %rsi, %r14
testq %rdx, %rdx
je 0x23a3a
movq (%rbx), %rax
subq %r12, %rax
addq $-0x40, %rax
shrq $0x3, %rax
movl %eax, %r13d
jmp 0x23a3d
xorl %r13d, %r13d
movq %r15, %rdi
movq %r12, %rsi
callq 0x38a4e
testq %rax, %rax
je 0x23a75
movq %rax, %r12
movq 0x18(%r15), %rdi
movq 0x18(%r14), %rsi
callq 0x38658
xorl %ebp, %ebp
movq %r12, 0x18(%r14)
testq %rbx, %rbx
je 0x23a78
leaq (%r12,%r13,8), %rax
addq $0x40, %rax
movq %rax, (%rbx)
jmp 0x23a78
pushq $-0x1
popq %rbp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| js_shape_prepare_update:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r12, [rsi+18h]
xor ebp, ebp
cmp byte ptr [r12+18h], 0
jz short loc_23A78
mov r15, rdi
cmp dword ptr [r12], 1
jnz short loc_23A1C
mov rdi, [r15+18h]
mov rsi, r12
call js_shape_hash_unlink
mov byte ptr [r12+18h], 0
jmp short loc_23A78
loc_23A1C:
mov rbx, rdx
mov r14, rsi
test rdx, rdx
jz short loc_23A3A
mov rax, [rbx]
sub rax, r12
add rax, 0FFFFFFFFFFFFFFC0h
shr rax, 3
mov r13d, eax
jmp short loc_23A3D
loc_23A3A:
xor r13d, r13d
loc_23A3D:
mov rdi, r15
mov rsi, r12
call js_clone_shape
test rax, rax
jz short loc_23A75
mov r12, rax
mov rdi, [r15+18h]
mov rsi, [r14+18h]
call js_free_shape
xor ebp, ebp
mov [r14+18h], r12
test rbx, rbx
jz short loc_23A78
lea rax, [r12+r13*8]
add rax, 40h ; '@'
mov [rbx], rax
jmp short loc_23A78
loc_23A75:
push 0FFFFFFFFFFFFFFFFh
pop rbp
loc_23A78:
mov eax, ebp
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long js_shape_prepare_update(long long a1, long long a2, _QWORD *a3)
{
long long v3; // r12
unsigned int v4; // ebp
long long v6; // r13
long long v7; // rax
long long v8; // r12
v3 = *(_QWORD *)(a2 + 24);
v4 = 0;
if ( *(_BYTE *)(v3 + 24) )
{
if ( *(_DWORD *)v3 == 1 )
{
js_shape_hash_unlink(*(_QWORD *)(a1 + 24), *(_QWORD *)(a2 + 24));
*(_BYTE *)(v3 + 24) = 0;
}
else
{
if ( a3 )
v6 = (unsigned int)((unsigned long long)(*a3 - v3 - 64) >> 3);
else
v6 = 0LL;
v7 = js_clone_shape(a1, *(_QWORD *)(a2 + 24));
if ( v7 )
{
v8 = v7;
js_free_shape(*(_QWORD *)(a1 + 24), *(_QWORD *)(a2 + 24));
v4 = 0;
*(_QWORD *)(a2 + 24) = v8;
if ( a3 )
*a3 = v8 + 8 * v6 + 64;
}
else
{
return (unsigned int)-1;
}
}
}
return v4;
}
| js_shape_prepare_update:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R12,qword ptr [RSI + 0x18]
XOR EBP,EBP
CMP byte ptr [R12 + 0x18],0x0
JZ 0x00123a78
MOV R15,RDI
CMP dword ptr [R12],0x1
JNZ 0x00123a1c
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,R12
CALL 0x001386df
MOV byte ptr [R12 + 0x18],0x0
JMP 0x00123a78
LAB_00123a1c:
MOV RBX,RDX
MOV R14,RSI
TEST RDX,RDX
JZ 0x00123a3a
MOV RAX,qword ptr [RBX]
SUB RAX,R12
ADD RAX,-0x40
SHR RAX,0x3
MOV R13D,EAX
JMP 0x00123a3d
LAB_00123a3a:
XOR R13D,R13D
LAB_00123a3d:
MOV RDI,R15
MOV RSI,R12
CALL 0x00138a4e
TEST RAX,RAX
JZ 0x00123a75
MOV R12,RAX
MOV RDI,qword ptr [R15 + 0x18]
MOV RSI,qword ptr [R14 + 0x18]
CALL 0x00138658
XOR EBP,EBP
MOV qword ptr [R14 + 0x18],R12
TEST RBX,RBX
JZ 0x00123a78
LEA RAX,[R12 + R13*0x8]
ADD RAX,0x40
MOV qword ptr [RBX],RAX
JMP 0x00123a78
LAB_00123a75:
PUSH -0x1
POP RBP
LAB_00123a78:
MOV EAX,EBP
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int4 js_shape_prepare_update(long param_1,long param_2,long *param_3)
{
int *piVar1;
long lVar2;
int4 uVar3;
ulong uVar4;
piVar1 = *(int **)(param_2 + 0x18);
uVar3 = 0;
if ((char)piVar1[6] != '\0') {
if (*piVar1 == 1) {
js_shape_hash_unlink(*(int8 *)(param_1 + 0x18),piVar1);
*(int1 *)(piVar1 + 6) = 0;
}
else {
if (param_3 == (long *)0x0) {
uVar4 = 0;
}
else {
uVar4 = (*param_3 - (long)piVar1) - 0x40U >> 3 & 0xffffffff;
}
lVar2 = js_clone_shape(param_1,piVar1);
if (lVar2 == 0) {
uVar3 = 0xffffffff;
}
else {
js_free_shape(*(int8 *)(param_1 + 0x18),*(int8 *)(param_2 + 0x18));
*(long *)(param_2 + 0x18) = lVar2;
uVar3 = 0;
if (param_3 != (long *)0x0) {
*param_3 = lVar2 + uVar4 * 8 + 0x40;
uVar3 = 0;
}
}
}
}
return uVar3;
}
| |
22,108 | nglog::base::SetLogger(nglog::LogSeverity, nglog::base::Logger*) | ng-log[P]ng-log/src/logging.cc | void base::SetLogger(LogSeverity severity, base::Logger* logger) {
std::lock_guard<std::mutex> l{log_mutex};
LogDestination::log_destination(severity)->SetLoggerImpl(logger);
} | O3 | cpp | nglog::base::SetLogger(nglog::LogSeverity, nglog::base::Logger*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x33e5a(%rip), %rdi # 0x3ec58
callq 0x7810
testl %eax, %eax
jne 0xaea0
movl %ebp, %r15d
leaq 0x24d8b(%rip), %r12 # 0x2fba0
movq (%r12,%r15,8), %r14
testq %r14, %r14
jne 0xae5e
movl $0xd0, %edi
callq 0x7520
movq %rax, %r14
movq %rax, %rdi
movl %ebp, %esi
xorl %edx, %edx
callq 0x941c
leaq (%r12,%r15,8), %r15
leaq 0x8(%rsp), %r12
movq $0x0, (%r12)
movq %r15, %rdi
movq %r14, %rsi
callq 0x117d4
movq %r12, %rdi
callq 0x10336
movq (%r15), %r14
movq 0xc8(%r14), %rdi
cmpq %rbx, %rdi
je 0xae87
testq %rdi, %rdi
sete %al
cmpq %r14, %rdi
sete %cl
orb %al, %cl
jne 0xae80
movq (%rdi), %rax
callq *0x8(%rax)
movq %rbx, 0xc8(%r14)
leaq 0x33dca(%rip), %rdi # 0x3ec58
callq 0x73e0
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %edi
callq 0x7350
movq %rax, %rbx
movl $0xd0, %esi
movq %r14, %rdi
callq 0x7530
jmp 0xaebc
movq %rax, %rbx
leaq 0x33d95(%rip), %rdi # 0x3ec58
callq 0x73e0
movq %rbx, %rdi
callq 0x7970
| _ZN5nglog4base9SetLoggerENS_11LogSeverityEPNS0_6LoggerE:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 10h
mov rbx, rsi
mov ebp, edi
lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex
call _pthread_mutex_lock
test eax, eax
jnz loc_AEA0
mov r15d, ebp
lea r12, _ZN5nglog14LogDestination17log_destinations_E; nglog::LogDestination::log_destinations_
mov r14, [r12+r15*8]
test r14, r14
jnz short loc_AE5E
mov edi, 0D0h; unsigned __int64
call __Znwm; operator new(ulong)
mov r14, rax
mov rdi, rax
mov esi, ebp
xor edx, edx
call _ZN5nglog14LogDestinationC2ENS_11LogSeverityEPKc; nglog::LogDestination::LogDestination(nglog::LogSeverity,char const*)
lea r15, [r12+r15*8]
lea r12, [rsp+38h+var_30]
mov qword ptr [r12], 0
mov rdi, r15
mov rsi, r14
call _ZNSt15__uniq_ptr_implIN5nglog14LogDestinationESt14default_deleteIS1_EE5resetEPS1_; std::__uniq_ptr_impl<nglog::LogDestination,std::default_delete<nglog::LogDestination>>::reset(nglog::LogDestination*)
mov rdi, r12
call _ZNSt10unique_ptrIN5nglog14LogDestinationESt14default_deleteIS1_EED2Ev; std::unique_ptr<nglog::LogDestination>::~unique_ptr()
mov r14, [r15]
loc_AE5E:
mov rdi, [r14+0C8h]
cmp rdi, rbx
jz short loc_AE87
test rdi, rdi
setz al
cmp rdi, r14
setz cl
or cl, al
jnz short loc_AE80
mov rax, [rdi]
call qword ptr [rax+8]
loc_AE80:
mov [r14+0C8h], rbx
loc_AE87:
lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex
call _pthread_mutex_unlock
add rsp, 10h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_AEA0:
mov edi, eax; int
call __ZSt20__throw_system_errori; std::__throw_system_error(int)
mov rbx, rax
mov esi, 0D0h; unsigned __int64
mov rdi, r14; void *
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_AEBC
mov rbx, rax
loc_AEBC:
lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex
call _pthread_mutex_unlock
mov rdi, rbx
call __Unwind_Resume
| long long nglog::base::SetLogger(int a1, long long a2)
{
int v2; // eax
long long v3; // r14
long long v4; // r14
long long v5; // rdi
_QWORD v7[6]; // [rsp+8h] [rbp-30h] BYREF
v2 = pthread_mutex_lock(&nglog::log_mutex);
if ( v2 )
std::__throw_system_error(v2);
v3 = nglog::LogDestination::log_destinations_[a1];
if ( !v3 )
{
v4 = operator new(0xD0uLL);
nglog::LogDestination::LogDestination(v4, a1, 0LL);
v7[0] = 0LL;
std::__uniq_ptr_impl<nglog::LogDestination,std::default_delete<nglog::LogDestination>>::reset(
&nglog::LogDestination::log_destinations_[a1],
v4);
std::unique_ptr<nglog::LogDestination>::~unique_ptr(v7);
v3 = nglog::LogDestination::log_destinations_[a1];
}
v5 = *(_QWORD *)(v3 + 200);
if ( v5 != a2 )
{
if ( v5 != 0 && v5 != v3 )
(*(void ( **)(long long))(*(_QWORD *)v5 + 8LL))(v5);
*(_QWORD *)(v3 + 200) = a2;
}
return pthread_mutex_unlock(&nglog::log_mutex);
}
| SetLogger:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV RBX,RSI
MOV EBP,EDI
LEA RDI,[0x13ec58]
CALL 0x00107810
TEST EAX,EAX
JNZ 0x0010aea0
MOV R15D,EBP
LEA R12,[0x12fba0]
MOV R14,qword ptr [R12 + R15*0x8]
TEST R14,R14
JNZ 0x0010ae5e
LAB_0010ae1e:
MOV EDI,0xd0
CALL 0x00107520
LAB_0010ae28:
MOV R14,RAX
MOV RDI,RAX
MOV ESI,EBP
XOR EDX,EDX
CALL 0x0010941c
LAB_0010ae37:
LEA R15,[R12 + R15*0x8]
LEA R12,[RSP + 0x8]
MOV qword ptr [R12],0x0
MOV RDI,R15
MOV RSI,R14
CALL 0x001117d4
MOV RDI,R12
CALL 0x00110336
MOV R14,qword ptr [R15]
LAB_0010ae5e:
MOV RDI,qword ptr [R14 + 0xc8]
CMP RDI,RBX
JZ 0x0010ae87
TEST RDI,RDI
SETZ AL
CMP RDI,R14
SETZ CL
OR CL,AL
JNZ 0x0010ae80
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x8]
LAB_0010ae80:
MOV qword ptr [R14 + 0xc8],RBX
LAB_0010ae87:
LEA RDI,[0x13ec58]
CALL 0x001073e0
ADD RSP,0x10
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_0010aea0:
MOV EDI,EAX
CALL 0x00107350
|
/* nglog::base::SetLogger(nglog::LogSeverity, nglog::base::Logger*) */
void nglog::base::SetLogger(uint param_1,long *param_2)
{
long *plVar1;
int iVar2;
LogDestination *pLVar3;
long *plVar4;
int8 local_30;
iVar2 = pthread_mutex_lock((pthread_mutex_t *)log_mutex);
if (iVar2 == 0) {
plVar4 = (long *)(&LogDestination::log_destinations_)[param_1];
if (plVar4 == (long *)0x0) {
/* try { // try from 0010ae1e to 0010ae27 has its CatchHandler @ 0010aeb9 */
pLVar3 = (LogDestination *)operator_new(0xd0);
/* try { // try from 0010ae28 to 0010ae36 has its CatchHandler @ 0010aea7 */
LogDestination::LogDestination(pLVar3,param_1,0);
local_30 = 0;
std::__uniq_ptr_impl<nglog::LogDestination,std::default_delete<nglog::LogDestination>>::reset
((__uniq_ptr_impl<nglog::LogDestination,std::default_delete<nglog::LogDestination>>
*)(&LogDestination::log_destinations_ + param_1),pLVar3);
std::unique_ptr<nglog::LogDestination,std::default_delete<nglog::LogDestination>>::~unique_ptr
((unique_ptr<nglog::LogDestination,std::default_delete<nglog::LogDestination>> *)
&local_30);
plVar4 = *(long **)(&LogDestination::log_destinations_ + param_1);
}
plVar1 = (long *)plVar4[0x19];
if (plVar1 != param_2) {
if (plVar1 != plVar4 && plVar1 != (long *)0x0) {
(**(code **)(*plVar1 + 8))();
}
plVar4[0x19] = (long)param_2;
}
pthread_mutex_unlock((pthread_mutex_t *)log_mutex);
return;
}
/* WARNING: Subroutine does not return */
std::__throw_system_error(iVar2);
}
| |
22,109 | format[abi:cxx11](char const*, ...) | ami-iit[P]serial_cpp/src/impl/list_ports/list_ports_linux.cc | string
format(const char* format, ...)
{
va_list ap;
size_t buffer_size_bytes = 256;
string result;
char* buffer = (char*)malloc(buffer_size_bytes);
if( buffer == NULL )
return result;
bool done = false;
unsigned int loop_count = 0;
while(!done)
{
va_start(ap, format);
int return_value = vsnprintf(buffer, buffer_size_bytes, format, ap);
if( return_value < 0 )
{
done = true;
}
else if( return_value >= buffer_size_bytes )
{
// Realloc and try again.
buffer_size_bytes = return_value + 1;
char* new_buffer_ptr = (char*)realloc(buffer, buffer_size_bytes);
if( new_buffer_ptr == NULL )
{
done = true;
}
else
{
buffer = new_buffer_ptr;
}
}
else
{
result = buffer;
done = true;
}
va_end(ap);
if( ++loop_count > 5 )
done = true;
}
free(buffer);
return result;
} | O0 | cpp | format[abi:cxx11](char const*, ...):
pushq %rbp
movq %rsp, %rbp
subq $0x130, %rsp # imm = 0x130
movq %rdi, -0x130(%rbp)
movq %rdi, %r10
movq %r10, -0x128(%rbp)
testb %al, %al
je 0xdd95
movaps %xmm0, -0xf0(%rbp)
movaps %xmm1, -0xe0(%rbp)
movaps %xmm2, -0xd0(%rbp)
movaps %xmm3, -0xc0(%rbp)
movaps %xmm4, -0xb0(%rbp)
movaps %xmm5, -0xa0(%rbp)
movaps %xmm6, -0x90(%rbp)
movaps %xmm7, -0x80(%rbp)
movq %r9, -0xf8(%rbp)
movq %r8, -0x100(%rbp)
movq %rcx, -0x108(%rbp)
movq %rdx, -0x110(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq $0x100, -0x38(%rbp) # imm = 0x100
movb $0x0, -0x39(%rbp)
callq 0x34b0
movq -0x38(%rbp), %rdi
callq 0x3470
movq %rax, -0x48(%rbp)
cmpq $0x0, -0x48(%rbp)
jne 0xddee
movb $0x1, -0x39(%rbp)
movl $0x1, -0x4c(%rbp)
jmp 0xdef0
movb $0x0, -0x4d(%rbp)
movl $0x0, -0x54(%rbp)
movb -0x4d(%rbp), %al
xorb $-0x1, %al
testb $0x1, %al
jne 0xde07
jmp 0xdedc
leaq -0x30(%rbp), %rax
leaq -0x120(%rbp), %rcx
movq %rcx, 0x10(%rax)
leaq 0x10(%rbp), %rcx
movq %rcx, 0x8(%rax)
movl $0x30, 0x4(%rax)
movl $0x10, (%rax)
movq -0x48(%rbp), %rdi
movq -0x38(%rbp), %rsi
movq -0x10(%rbp), %rdx
leaq -0x30(%rbp), %rcx
callq 0x31f0
movl %eax, -0x58(%rbp)
cmpl $0x0, -0x58(%rbp)
jge 0xde4f
movb $0x1, -0x4d(%rbp)
jmp 0xdec1
movslq -0x58(%rbp), %rax
cmpq -0x38(%rbp), %rax
jb 0xde8d
movl -0x58(%rbp), %eax
addl $0x1, %eax
cltq
movq %rax, -0x38(%rbp)
movq -0x48(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x3570
movq %rax, -0x60(%rbp)
cmpq $0x0, -0x60(%rbp)
jne 0xde83
movb $0x1, -0x4d(%rbp)
jmp 0xde8b
movq -0x60(%rbp), %rax
movq %rax, -0x48(%rbp)
jmp 0xdebf
movq -0x130(%rbp), %rdi
movq -0x48(%rbp), %rsi
callq 0x3490
jmp 0xde9f
movb $0x1, -0x4d(%rbp)
jmp 0xdebf
movq -0x130(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
callq 0x31e0
jmp 0xdf12
jmp 0xdec1
leaq -0x30(%rbp), %rax
movl -0x54(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x54(%rbp)
cmpl $0x5, %eax
jbe 0xded7
movb $0x1, -0x4d(%rbp)
jmp 0xddf9
movq -0x48(%rbp), %rdi
callq 0x3400
movb $0x1, -0x39(%rbp)
movl $0x1, -0x4c(%rbp)
testb $0x1, -0x39(%rbp)
jne 0xdf02
movq -0x130(%rbp), %rdi
callq 0x31e0
movq -0x128(%rbp), %rax
addq $0x130, %rsp # imm = 0x130
popq %rbp
retq
movq -0x68(%rbp), %rdi
callq 0x35d0
nopl (%rax,%rax)
| _ZL6formatB5cxx11PKcz:
push rbp
mov rbp, rsp
sub rsp, 130h
mov [rbp+var_130], rdi
mov r10, rdi
mov [rbp+var_128], r10
test al, al
jz short loc_DD95
movaps [rbp+var_F0], xmm0
movaps [rbp+var_E0], xmm1
movaps [rbp+var_D0], xmm2
movaps [rbp+var_C0], xmm3
movaps [rbp+var_B0], xmm4
movaps [rbp+var_A0], xmm5
movaps [rbp+var_90], xmm6
movaps [rbp+var_80], xmm7
loc_DD95:
mov [rbp+var_F8], r9
mov [rbp+var_100], r8
mov [rbp+var_108], rcx
mov [rbp+var_110], rdx
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_38], 100h
mov [rbp+var_39], 0
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev; std::string::basic_string(void)
mov rdi, [rbp+var_38]
call _malloc
mov [rbp+var_48], rax
cmp [rbp+var_48], 0
jnz short loc_DDEE
mov [rbp+var_39], 1
mov [rbp+var_4C], 1
jmp loc_DEF0
loc_DDEE:
mov [rbp+var_4D], 0
mov [rbp+var_54], 0
loc_DDF9:
mov al, [rbp+var_4D]
xor al, 0FFh
test al, 1
jnz short loc_DE07
jmp loc_DEDC
loc_DE07:
lea rax, [rbp+var_30]
lea rcx, [rbp+var_120]
mov [rax+10h], rcx
lea rcx, [rbp+arg_0]
mov [rax+8], rcx
mov dword ptr [rax+4], 30h ; '0'
mov dword ptr [rax], 10h
mov rdi, [rbp+var_48]
mov rsi, [rbp+var_38]
mov rdx, [rbp+var_10]
lea rcx, [rbp+var_30]
call _vsnprintf
mov [rbp+var_58], eax
cmp [rbp+var_58], 0
jge short loc_DE4F
mov [rbp+var_4D], 1
jmp short loc_DEC1
loc_DE4F:
movsxd rax, [rbp+var_58]
cmp rax, [rbp+var_38]
jb short loc_DE8D
mov eax, [rbp+var_58]
add eax, 1
cdqe
mov [rbp+var_38], rax
mov rdi, [rbp+var_48]
mov rsi, [rbp+var_38]
call _realloc
mov [rbp+var_60], rax
cmp [rbp+var_60], 0
jnz short loc_DE83
mov [rbp+var_4D], 1
jmp short loc_DE8B
loc_DE83:
mov rax, [rbp+var_60]
mov [rbp+var_48], rax
loc_DE8B:
jmp short loc_DEBF
loc_DE8D:
mov rdi, [rbp+var_130]
mov rsi, [rbp+var_48]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEPKc; std::string::operator=(char const*)
jmp short $+2
loc_DE9F:
mov [rbp+var_4D], 1
jmp short loc_DEBF
mov rdi, [rbp+var_130]
mov rcx, rax
mov eax, edx
mov [rbp+var_68], rcx
mov [rbp+var_6C], eax
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_DF12
loc_DEBF:
jmp short $+2
loc_DEC1:
lea rax, [rbp+var_30]
mov eax, [rbp+var_54]
add eax, 1
mov [rbp+var_54], eax
cmp eax, 5
jbe short loc_DED7
mov [rbp+var_4D], 1
loc_DED7:
jmp loc_DDF9
loc_DEDC:
mov rdi, [rbp+var_48]
call _free
mov [rbp+var_39], 1
mov [rbp+var_4C], 1
loc_DEF0:
test [rbp+var_39], 1
jnz short loc_DF02
mov rdi, [rbp+var_130]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_DF02:
mov rax, [rbp+var_128]
add rsp, 130h
pop rbp
retn
loc_DF12:
mov rdi, [rbp+var_68]
call __Unwind_Resume
| long long format[abi:cxx11](
long long a1,
long long a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14,
char a15)
{
char v16; // [rsp+10h] [rbp-120h] BYREF
long long v17; // [rsp+20h] [rbp-110h]
long long v18; // [rsp+28h] [rbp-108h]
long long v19; // [rsp+30h] [rbp-100h]
long long v20; // [rsp+38h] [rbp-F8h]
__m128 v21; // [rsp+40h] [rbp-F0h]
__m128 v22; // [rsp+50h] [rbp-E0h]
__m128 v23; // [rsp+60h] [rbp-D0h]
__m128 v24; // [rsp+70h] [rbp-C0h]
__m128 v25; // [rsp+80h] [rbp-B0h]
__m128 v26; // [rsp+90h] [rbp-A0h]
__m128 v27; // [rsp+A0h] [rbp-90h]
__m128 v28; // [rsp+B0h] [rbp-80h]
long long v29; // [rsp+D0h] [rbp-60h]
int v30; // [rsp+D8h] [rbp-58h]
int v31; // [rsp+DCh] [rbp-54h]
char v32; // [rsp+E3h] [rbp-4Dh]
int v33; // [rsp+E4h] [rbp-4Ch]
long long v34; // [rsp+E8h] [rbp-48h]
char v35; // [rsp+F7h] [rbp-39h]
unsigned long long v36; // [rsp+F8h] [rbp-38h]
_DWORD v37[2]; // [rsp+100h] [rbp-30h] BYREF
char *v38; // [rsp+108h] [rbp-28h]
char *v39; // [rsp+110h] [rbp-20h]
long long v40; // [rsp+120h] [rbp-10h]
long long v41; // [rsp+128h] [rbp-8h]
v21 = a7;
v22 = a8;
v23 = a9;
v24 = a10;
v25 = a11;
v26 = a12;
v27 = a13;
v28 = a14;
v20 = a6;
v19 = a5;
v18 = a4;
v17 = a3;
v41 = a1;
v40 = a2;
v36 = 256LL;
v35 = 0;
std::string::basic_string(a1);
v34 = malloc(256LL);
if ( v34 )
{
v32 = 0;
v31 = 0;
while ( (v32 & 1) == 0 )
{
v39 = &v16;
v38 = &a15;
v37[1] = 48;
v37[0] = 16;
v30 = vsnprintf(v34, v36, v40, v37);
if ( v30 >= 0 )
{
if ( v30 < v36 )
{
std::string::operator=(a1, v34);
v32 = 1;
}
else
{
v36 = v30 + 1;
v29 = realloc(v34, v36);
if ( v29 )
v34 = v29;
else
v32 = 1;
}
}
else
{
v32 = 1;
}
if ( (unsigned int)++v31 > 5 )
v32 = 1;
}
free(v34);
v35 = 1;
v33 = 1;
}
else
{
v35 = 1;
v33 = 1;
}
return a1;
}
| format[abi:cxx11]:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x130
MOV qword ptr [RBP + -0x130],RDI
MOV R10,RDI
MOV qword ptr [RBP + -0x128],R10
TEST AL,AL
JZ 0x0010dd95
MOVAPS xmmword ptr [RBP + -0xf0],XMM0
MOVAPS xmmword ptr [RBP + -0xe0],XMM1
MOVAPS xmmword ptr [RBP + -0xd0],XMM2
MOVAPS xmmword ptr [RBP + -0xc0],XMM3
MOVAPS xmmword ptr [RBP + -0xb0],XMM4
MOVAPS xmmword ptr [RBP + -0xa0],XMM5
MOVAPS xmmword ptr [RBP + -0x90],XMM6
MOVAPS xmmword ptr [RBP + -0x80],XMM7
LAB_0010dd95:
MOV qword ptr [RBP + -0xf8],R9
MOV qword ptr [RBP + -0x100],R8
MOV qword ptr [RBP + -0x108],RCX
MOV qword ptr [RBP + -0x110],RDX
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x38],0x100
MOV byte ptr [RBP + -0x39],0x0
CALL 0x001034b0
MOV RDI,qword ptr [RBP + -0x38]
CALL 0x00103470
MOV qword ptr [RBP + -0x48],RAX
CMP qword ptr [RBP + -0x48],0x0
JNZ 0x0010ddee
MOV byte ptr [RBP + -0x39],0x1
MOV dword ptr [RBP + -0x4c],0x1
JMP 0x0010def0
LAB_0010ddee:
MOV byte ptr [RBP + -0x4d],0x0
MOV dword ptr [RBP + -0x54],0x0
LAB_0010ddf9:
MOV AL,byte ptr [RBP + -0x4d]
XOR AL,0xff
TEST AL,0x1
JNZ 0x0010de07
JMP 0x0010dedc
LAB_0010de07:
LEA RAX,[RBP + -0x30]
LEA RCX,[RBP + -0x120]
MOV qword ptr [RAX + 0x10],RCX
LEA RCX,[RBP + 0x10]
MOV qword ptr [RAX + 0x8],RCX
MOV dword ptr [RAX + 0x4],0x30
MOV dword ptr [RAX],0x10
MOV RDI,qword ptr [RBP + -0x48]
MOV RSI,qword ptr [RBP + -0x38]
MOV RDX,qword ptr [RBP + -0x10]
LEA RCX,[RBP + -0x30]
CALL 0x001031f0
MOV dword ptr [RBP + -0x58],EAX
CMP dword ptr [RBP + -0x58],0x0
JGE 0x0010de4f
MOV byte ptr [RBP + -0x4d],0x1
JMP 0x0010dec1
LAB_0010de4f:
MOVSXD RAX,dword ptr [RBP + -0x58]
CMP RAX,qword ptr [RBP + -0x38]
JC 0x0010de8d
MOV EAX,dword ptr [RBP + -0x58]
ADD EAX,0x1
CDQE
MOV qword ptr [RBP + -0x38],RAX
MOV RDI,qword ptr [RBP + -0x48]
MOV RSI,qword ptr [RBP + -0x38]
CALL 0x00103570
MOV qword ptr [RBP + -0x60],RAX
CMP qword ptr [RBP + -0x60],0x0
JNZ 0x0010de83
MOV byte ptr [RBP + -0x4d],0x1
JMP 0x0010de8b
LAB_0010de83:
MOV RAX,qword ptr [RBP + -0x60]
MOV qword ptr [RBP + -0x48],RAX
LAB_0010de8b:
JMP 0x0010debf
LAB_0010de8d:
MOV RDI,qword ptr [RBP + -0x130]
MOV RSI,qword ptr [RBP + -0x48]
LAB_0010de98:
CALL 0x00103490
LAB_0010de9d:
JMP 0x0010de9f
LAB_0010de9f:
MOV byte ptr [RBP + -0x4d],0x1
JMP 0x0010debf
LAB_0010debf:
JMP 0x0010dec1
LAB_0010dec1:
LEA RAX,[RBP + -0x30]
MOV EAX,dword ptr [RBP + -0x54]
ADD EAX,0x1
MOV dword ptr [RBP + -0x54],EAX
CMP EAX,0x5
JBE 0x0010ded7
MOV byte ptr [RBP + -0x4d],0x1
LAB_0010ded7:
JMP 0x0010ddf9
LAB_0010dedc:
MOV RDI,qword ptr [RBP + -0x48]
CALL 0x00103400
MOV byte ptr [RBP + -0x39],0x1
MOV dword ptr [RBP + -0x4c],0x1
LAB_0010def0:
TEST byte ptr [RBP + -0x39],0x1
JNZ 0x0010df02
MOV RDI,qword ptr [RBP + -0x130]
CALL 0x001031e0
LAB_0010df02:
MOV RAX,qword ptr [RBP + -0x128]
ADD RSP,0x130
POP RBP
RET
|
/* WARNING: Removing unreachable block (ram,0x0010def6) */
/* format[abi:cxx11](char const*, ...) */
char * format_abi_cxx11_(char *param_1,...)
{
char *pcVar1;
char in_AL;
int8 in_RCX;
int8 in_RDX;
char *in_RSI;
int8 in_R8;
int8 in_R9;
int8 in_XMM0_Qa;
int8 in_XMM1_Qa;
int8 in_XMM2_Qa;
int8 in_XMM3_Qa;
int8 in_XMM4_Qa;
int8 in_XMM5_Qa;
int8 in_XMM6_Qa;
int8 in_XMM7_Qa;
int1 local_128 [16];
int8 local_118;
int8 local_110;
int8 local_108;
int8 local_100;
int8 local_f8;
int8 local_e8;
int8 local_d8;
int8 local_c8;
int8 local_b8;
int8 local_a8;
int8 local_98;
int8 local_88;
char *local_68;
int local_60;
uint local_5c;
byte local_55;
char *local_50;
int1 local_41;
size_t local_40;
int4 local_38;
int4 local_34;
int1 *local_30;
int1 *local_28;
char *local_18;
char *local_10;
if (in_AL != '\0') {
local_f8 = in_XMM0_Qa;
local_e8 = in_XMM1_Qa;
local_d8 = in_XMM2_Qa;
local_c8 = in_XMM3_Qa;
local_b8 = in_XMM4_Qa;
local_a8 = in_XMM5_Qa;
local_98 = in_XMM6_Qa;
local_88 = in_XMM7_Qa;
}
local_40 = 0x100;
local_41 = 0;
local_118 = in_RDX;
local_110 = in_RCX;
local_108 = in_R8;
local_100 = in_R9;
local_18 = in_RSI;
local_10 = param_1;
std::__cxx11::string::string((string *)param_1);
local_50 = (char *)malloc(local_40);
if (local_50 != (char *)0x0) {
local_55 = 0;
local_5c = 0;
while (((local_55 ^ 0xff) & 1) != 0) {
local_28 = local_128;
local_30 = &stack0x00000008;
local_34 = 0x30;
local_38 = 0x10;
local_60 = vsnprintf(local_50,local_40,local_18,&local_38);
if (local_60 < 0) {
local_55 = 1;
pcVar1 = local_50;
}
else if ((ulong)(long)local_60 < local_40) {
/* try { // try from 0010de98 to 0010de9c has its CatchHandler @ 0010dea5 */
std::__cxx11::string::operator=((string *)param_1,local_50);
local_55 = 1;
pcVar1 = local_50;
}
else {
local_40 = (size_t)(local_60 + 1);
local_68 = (char *)realloc(local_50,local_40);
pcVar1 = local_68;
if (local_68 == (char *)0x0) {
local_55 = 1;
pcVar1 = local_50;
}
}
local_50 = pcVar1;
local_5c = local_5c + 1;
if (5 < local_5c) {
local_55 = 1;
}
}
free(local_50);
}
return param_1;
}
| |
22,110 | format[abi:cxx11](char const*, ...) | ami-iit[P]serial_cpp/src/impl/list_ports/list_ports_linux.cc | string
format(const char* format, ...)
{
va_list ap;
size_t buffer_size_bytes = 256;
string result;
char* buffer = (char*)malloc(buffer_size_bytes);
if( buffer == NULL )
return result;
bool done = false;
unsigned int loop_count = 0;
while(!done)
{
va_start(ap, format);
int return_value = vsnprintf(buffer, buffer_size_bytes, format, ap);
if( return_value < 0 )
{
done = true;
}
else if( return_value >= buffer_size_bytes )
{
// Realloc and try again.
buffer_size_bytes = return_value + 1;
char* new_buffer_ptr = (char*)realloc(buffer, buffer_size_bytes);
if( new_buffer_ptr == NULL )
{
done = true;
}
else
{
buffer = new_buffer_ptr;
}
}
else
{
result = buffer;
done = true;
}
va_end(ap);
if( ++loop_count > 5 )
done = true;
}
free(buffer);
return result;
} | O2 | cpp | format[abi:cxx11](char const*, ...):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rsi, %r14
movq %rdx, 0x40(%rsp)
movq %rcx, 0x48(%rsp)
movq %r8, 0x50(%rsp)
movq %r9, 0x58(%rsp)
testb %al, %al
je 0x7e88
movaps %xmm0, 0x60(%rsp)
movaps %xmm1, 0x70(%rsp)
movaps %xmm2, 0x80(%rsp)
movaps %xmm3, 0x90(%rsp)
movaps %xmm4, 0xa0(%rsp)
movaps %xmm5, 0xb0(%rsp)
movaps %xmm6, 0xc0(%rsp)
movaps %xmm7, 0xd0(%rsp)
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
movq %rdi, 0x8(%rsp)
movb $0x0, 0x10(%rdi)
movl $0x100, %r13d # imm = 0x100
movl $0x100, %edi # imm = 0x100
callq 0x3390
testq %rax, %rax
je 0x7f51
movq %rax, %r15
pushq $0x1
popq %rbx
xorl %eax, %eax
testb $0x1, %al
jne 0x7f49
leaq 0x30(%rsp), %rax
movq %rax, 0x20(%rsp)
leaq 0x120(%rsp), %rax
movq %rax, 0x18(%rsp)
movabsq $0x3000000010, %rax # imm = 0x3000000010
movq %rax, 0x10(%rsp)
movq %r15, %rdi
movq %r13, %rsi
movq %r14, %rdx
leaq 0x10(%rsp), %rcx
callq 0x31b0
movb $0x1, %r12b
testl %eax, %eax
js 0x7f39
movl %eax, %ebp
movl %eax, %eax
cmpq %rax, %r13
jbe 0x7f1e
movq 0x8(%rsp), %rdi
movq %r15, %rsi
callq 0x3540
jmp 0x7f39
incl %ebp
movq %r15, %rdi
movq %rbp, %rsi
callq 0x3470
testq %rax, %rax
sete %r12b
cmovneq %rax, %r15
movq %rbp, %r13
cmpl $0x6, %ebx
setae %al
orb %r12b, %al
incl %ebx
jmp 0x7ebe
movq %r15, %rdi
callq 0x3340
movq 0x8(%rsp), %rax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq 0x8(%rsp), %rdi
callq 0x3140
movq %r14, %rdi
callq 0x34d0
| _ZL6formatB5cxx11PKcz:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0E8h
mov r14, rsi
mov [rsp+118h+var_D8], rdx
mov [rsp+118h+var_D0], rcx
mov [rsp+118h+var_C8], r8
mov [rsp+118h+var_C0], r9
test al, al
jz short loc_7E88
movaps [rsp+118h+var_B8], xmm0
movaps [rsp+118h+var_A8], xmm1
movaps [rsp+118h+var_98], xmm2
movaps [rsp+118h+var_88], xmm3
movaps [rsp+118h+var_78], xmm4
movaps [rsp+118h+var_68], xmm5
movaps [rsp+118h+var_58], xmm6
movaps [rsp+118h+var_48], xmm7
loc_7E88:
lea rax, [rdi+10h]
mov [rdi], rax
and qword ptr [rdi+8], 0
mov [rsp+118h+var_110], rdi
mov byte ptr [rdi+10h], 0
mov r13d, 100h
mov edi, 100h
call _malloc
test rax, rax
jz loc_7F51
mov r15, rax
push 1
pop rbx
xor eax, eax
loc_7EBE:
test al, 1
jnz loc_7F49
lea rax, [rsp+118h+var_E8]
mov [rsp+118h+var_F8], rax
lea rax, [rsp+118h+arg_0]
mov [rsp+118h+var_100], rax
mov rax, 3000000010h
mov [rsp+118h+var_108], rax
mov rdi, r15
mov rsi, r13
mov rdx, r14
lea rcx, [rsp+118h+var_108]
call _vsnprintf
mov r12b, 1
test eax, eax
js short loc_7F39
mov ebp, eax
mov eax, eax
cmp r13, rax
jbe short loc_7F1E
mov rdi, [rsp+118h+var_110]
mov rsi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6assignEPKc; std::string::assign(char const*)
jmp short loc_7F39
loc_7F1E:
inc ebp
mov rdi, r15
mov rsi, rbp
call _realloc
test rax, rax
setz r12b
cmovnz r15, rax
mov r13, rbp
loc_7F39:
cmp ebx, 6
setnb al
or al, r12b
inc ebx
jmp loc_7EBE
loc_7F49:
mov rdi, r15
call _free
loc_7F51:
mov rax, [rsp+118h+var_110]
add rsp, 0E8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r14, rax
mov rdi, [rsp+arg_0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, r14
call __Unwind_Resume
| long long format[abi:cxx11](long long a1, long long a2, ...)
{
unsigned long long v2; // r13
long long v3; // rax
long long v4; // r15
unsigned int v5; // ebx
char i; // al
int v7; // eax
bool v8; // r12
unsigned int v9; // ebp
long long v10; // rax
va_list va; // [rsp+10h] [rbp-108h] BYREF
*(_QWORD *)a1 = a1 + 16;
*(_QWORD *)(a1 + 8) = 0LL;
*(_BYTE *)(a1 + 16) = 0;
v2 = 256LL;
v3 = malloc(256LL);
if ( v3 )
{
v4 = v3;
v5 = 1;
for ( i = 0; (i & 1) == 0; i = v8 | (v5++ >= 6) )
{
va_start(va, a2);
v7 = vsnprintf(v4, v2, a2, va);
v8 = 1;
if ( v7 >= 0 )
{
if ( v2 <= (unsigned int)v7 )
{
v9 = v7 + 1;
v10 = realloc(v4, (unsigned int)(v7 + 1));
v8 = v10 == 0;
if ( v10 )
v4 = v10;
v2 = v9;
}
else
{
std::string::assign(a1, v4);
}
}
}
free(v4);
}
return a1;
}
| format[abi:cxx11]:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xe8
MOV R14,RSI
MOV qword ptr [RSP + 0x40],RDX
MOV qword ptr [RSP + 0x48],RCX
MOV qword ptr [RSP + 0x50],R8
MOV qword ptr [RSP + 0x58],R9
TEST AL,AL
JZ 0x00107e88
MOVAPS xmmword ptr [RSP + 0x60],XMM0
MOVAPS xmmword ptr [RSP + 0x70],XMM1
MOVAPS xmmword ptr [RSP + 0x80],XMM2
MOVAPS xmmword ptr [RSP + 0x90],XMM3
MOVAPS xmmword ptr [RSP + 0xa0],XMM4
MOVAPS xmmword ptr [RSP + 0xb0],XMM5
MOVAPS xmmword ptr [RSP + 0xc0],XMM6
MOVAPS xmmword ptr [RSP + 0xd0],XMM7
LAB_00107e88:
LEA RAX,[RDI + 0x10]
MOV qword ptr [RDI],RAX
AND qword ptr [RDI + 0x8],0x0
MOV qword ptr [RSP + 0x8],RDI
MOV byte ptr [RDI + 0x10],0x0
MOV R13D,0x100
MOV EDI,0x100
CALL 0x00103390
TEST RAX,RAX
JZ 0x00107f51
MOV R15,RAX
PUSH 0x1
POP RBX
XOR EAX,EAX
LAB_00107ebe:
TEST AL,0x1
JNZ 0x00107f49
LEA RAX,[RSP + 0x30]
MOV qword ptr [RSP + 0x20],RAX
LEA RAX,[RSP + 0x120]
MOV qword ptr [RSP + 0x18],RAX
MOV RAX,0x3000000010
MOV qword ptr [RSP + 0x10],RAX
MOV RDI,R15
MOV RSI,R13
MOV RDX,R14
LEA RCX,[RSP + 0x10]
CALL 0x001031b0
MOV R12B,0x1
TEST EAX,EAX
JS 0x00107f39
MOV EBP,EAX
MOV EAX,EAX
CMP R13,RAX
JBE 0x00107f1e
LAB_00107f0f:
MOV RDI,qword ptr [RSP + 0x8]
MOV RSI,R15
CALL 0x00103540
LAB_00107f1c:
JMP 0x00107f39
LAB_00107f1e:
INC EBP
MOV RDI,R15
MOV RSI,RBP
CALL 0x00103470
TEST RAX,RAX
SETZ R12B
CMOVNZ R15,RAX
MOV R13,RBP
LAB_00107f39:
CMP EBX,0x6
SETNC AL
OR AL,R12B
INC EBX
JMP 0x00107ebe
LAB_00107f49:
MOV RDI,R15
CALL 0x00103340
LAB_00107f51:
MOV RAX,qword ptr [RSP + 0x8]
ADD RSP,0xe8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* format[abi:cxx11](char const*, ...) */
char * format_abi_cxx11_(char *param_1,...)
{
char in_AL;
uint uVar1;
char *__s;
char *pcVar2;
int8 in_RCX;
int8 in_RDX;
uint uVar3;
char *in_RSI;
int8 in_R8;
int8 in_R9;
ulong __maxlen;
bool bVar4;
bool bVar5;
int8 in_XMM0_Qa;
int8 in_XMM1_Qa;
int8 in_XMM2_Qa;
int8 in_XMM3_Qa;
int8 in_XMM4_Qa;
int8 in_XMM5_Qa;
int8 in_XMM6_Qa;
int8 in_XMM7_Qa;
int8 local_108;
int1 *local_100;
int1 *local_f8;
int1 local_e8 [16];
int8 local_d8;
int8 local_d0;
int8 local_c8;
int8 local_c0;
int8 local_b8;
int8 local_a8;
int8 local_98;
int8 local_88;
int8 local_78;
int8 local_68;
int8 local_58;
int8 local_48;
if (in_AL != '\0') {
local_b8 = in_XMM0_Qa;
local_a8 = in_XMM1_Qa;
local_98 = in_XMM2_Qa;
local_88 = in_XMM3_Qa;
local_78 = in_XMM4_Qa;
local_68 = in_XMM5_Qa;
local_58 = in_XMM6_Qa;
local_48 = in_XMM7_Qa;
}
*(char **)param_1 = param_1 + 0x10;
param_1[8] = '\0';
param_1[9] = '\0';
param_1[10] = '\0';
param_1[0xb] = '\0';
param_1[0xc] = '\0';
param_1[0xd] = '\0';
param_1[0xe] = '\0';
param_1[0xf] = '\0';
param_1[0x10] = '\0';
__maxlen = 0x100;
local_d8 = in_RDX;
local_d0 = in_RCX;
local_c8 = in_R8;
local_c0 = in_R9;
__s = (char *)malloc(0x100);
if (__s != (char *)0x0) {
uVar3 = 1;
for (bVar4 = false; !bVar4; bVar4 = (bool)(bVar4 | bVar5)) {
local_f8 = local_e8;
local_100 = &stack0x00000008;
local_108 = 0x3000000010;
uVar1 = vsnprintf(__s,__maxlen,in_RSI,&local_108);
bVar5 = true;
if (-1 < (int)uVar1) {
if (uVar1 < __maxlen) {
/* try { // try from 00107f0f to 00107f1b has its CatchHandler @ 00107f68 */
std::__cxx11::string::assign(param_1);
}
else {
__maxlen = (ulong)(uVar1 + 1);
pcVar2 = (char *)realloc(__s,__maxlen);
bVar5 = pcVar2 == (char *)0x0;
if (!bVar5) {
__s = pcVar2;
}
}
}
bVar4 = 5 < uVar3;
uVar3 = uVar3 + 1;
}
free(__s);
}
return param_1;
}
| |
22,111 | format[abi:cxx11](char const*, ...) | ami-iit[P]serial_cpp/src/impl/list_ports/list_ports_linux.cc | string
format(const char* format, ...)
{
va_list ap;
size_t buffer_size_bytes = 256;
string result;
char* buffer = (char*)malloc(buffer_size_bytes);
if( buffer == NULL )
return result;
bool done = false;
unsigned int loop_count = 0;
while(!done)
{
va_start(ap, format);
int return_value = vsnprintf(buffer, buffer_size_bytes, format, ap);
if( return_value < 0 )
{
done = true;
}
else if( return_value >= buffer_size_bytes )
{
// Realloc and try again.
buffer_size_bytes = return_value + 1;
char* new_buffer_ptr = (char*)realloc(buffer, buffer_size_bytes);
if( new_buffer_ptr == NULL )
{
done = true;
}
else
{
buffer = new_buffer_ptr;
}
}
else
{
result = buffer;
done = true;
}
va_end(ap);
if( ++loop_count > 5 )
done = true;
}
free(buffer);
return result;
} | O3 | cpp | format[abi:cxx11](char const*, ...):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rsi, %r15
movq %rdi, %rbx
movq %rdx, 0x40(%rsp)
movq %rcx, 0x48(%rsp)
movq %r8, 0x50(%rsp)
movq %r9, 0x58(%rsp)
testb %al, %al
je 0x92a2
movaps %xmm0, 0x60(%rsp)
movaps %xmm1, 0x70(%rsp)
movaps %xmm2, 0x80(%rsp)
movaps %xmm3, 0x90(%rsp)
movaps %xmm4, 0xa0(%rsp)
movaps %xmm5, 0xb0(%rsp)
movaps %xmm6, 0xc0(%rsp)
movaps %xmm7, 0xd0(%rsp)
leaq 0x10(%rdi), %r13
movq %r13, (%rdi)
movq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
movl $0x100, %r12d # imm = 0x100
movl $0x100, %edi # imm = 0x100
callq 0x3390
testq %rax, %rax
je 0x9378
movq %rax, %r14
movq %r13, 0x8(%rsp)
movq %rbx, (%rsp)
xorl %ebp, %ebp
movabsq $0x3000000010, %rbx # imm = 0x3000000010
leaq 0x10(%rsp), %r13
leaq 0x30(%rsp), %rax
movq %rax, 0x20(%rsp)
leaq 0x120(%rsp), %rax
movq %rax, 0x18(%rsp)
movq %rbx, 0x10(%rsp)
movq %r14, %rdi
movq %r12, %rsi
movq %r15, %rdx
movq %r13, %rcx
callq 0x3190
testl %eax, %eax
js 0x936c
movl %eax, %ecx
cmpq %rcx, %r12
ja 0x9349
movl %eax, %r12d
incl %r12d
movq %r14, %rdi
movq %r12, %rsi
callq 0x3490
testq %rax, %rax
cmovneq %rax, %r14
cmpl $0x4, %ebp
ja 0x936c
incl %ebp
testq %rax, %rax
jne 0x92eb
jmp 0x936c
movq (%rsp), %rbx
movq 0x8(%rbx), %r15
movq %r14, %rdi
callq 0x3130
movq %rbx, %rdi
xorl %esi, %esi
movq %r15, %rdx
movq %r14, %rcx
movq %rax, %r8
callq 0x3450
movq %r14, %rdi
callq 0x3350
movq (%rsp), %rbx
movq %rbx, %rax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq (%rsp), %rax
movq (%rax), %rdi
cmpq 0x8(%rsp), %rdi
je 0x93ae
movq 0x8(%rsp), %rax
movq (%rax), %rsi
incq %rsi
callq 0x32c0
movq %r14, %rdi
callq 0x34f0
| _ZL6formatB5cxx11PKcz:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0E8h
mov r15, rsi
mov rbx, rdi
mov [rsp+118h+var_D8], rdx
mov [rsp+118h+var_D0], rcx
mov [rsp+118h+var_C8], r8
mov [rsp+118h+var_C0], r9
test al, al
jz short loc_92A2
movaps [rsp+118h+var_B8], xmm0
movaps [rsp+118h+var_A8], xmm1
movaps [rsp+118h+var_98], xmm2
movaps [rsp+118h+var_88], xmm3
movaps [rsp+118h+var_78], xmm4
movaps [rsp+118h+var_68], xmm5
movaps [rsp+118h+var_58], xmm6
movaps [rsp+118h+var_48], xmm7
loc_92A2:
lea r13, [rdi+10h]
mov [rdi], r13
mov qword ptr [rdi+8], 0
mov byte ptr [rdi+10h], 0
mov r12d, 100h
mov edi, 100h
call _malloc
test rax, rax
jz loc_9378
mov r14, rax
mov [rsp+118h+var_110], r13
mov [rsp+118h+var_118], rbx
xor ebp, ebp
mov rbx, 3000000010h
lea r13, [rsp+118h+var_108]
loc_92EB:
lea rax, [rsp+118h+var_E8]
mov [rsp+118h+var_F8], rax
lea rax, [rsp+118h+arg_0]
mov [rsp+118h+var_100], rax
mov [rsp+118h+var_108], rbx
mov rdi, r14
mov rsi, r12
mov rdx, r15
mov rcx, r13
call _vsnprintf
test eax, eax
js short loc_936C
mov ecx, eax
cmp r12, rcx
ja short loc_9349
mov r12d, eax
inc r12d
mov rdi, r14
mov rsi, r12
call _realloc
test rax, rax
cmovnz r14, rax
cmp ebp, 4
ja short loc_936C
inc ebp
test rax, rax
jnz short loc_92EB
jmp short loc_936C
loc_9349:
mov rbx, [rsp+118h+var_118]
mov r15, [rbx+8]
mov rdi, r14
call _strlen
mov rdi, rbx
xor esi, esi
mov rdx, r15
mov rcx, r14
mov r8, rax
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_replaceEmmPKcm; std::string::_M_replace(ulong,ulong,char const*,ulong)
loc_936C:
mov rdi, r14
call _free
mov rbx, [rsp+118h+var_118]
loc_9378:
mov rax, rbx
add rsp, 0E8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r14, rax
mov rax, [rsp+0]
mov rdi, [rax]; void *
cmp rdi, [rsp+arg_0]
jz short loc_93AE
mov rax, [rsp+arg_0]
mov rsi, [rax]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_93AE:
mov rdi, r14
call __Unwind_Resume
| long long format[abi:cxx11](long long a1, long long a2, ...)
{
long long v2; // rbx
unsigned long long v3; // r12
long long v4; // rax
long long v5; // r14
unsigned int v6; // ebp
int v7; // eax
long long v8; // rax
long long v9; // r15
long long v10; // rax
va_list va; // [rsp+10h] [rbp-108h] BYREF
v2 = a1;
*(_QWORD *)a1 = a1 + 16;
*(_QWORD *)(a1 + 8) = 0LL;
*(_BYTE *)(a1 + 16) = 0;
v3 = 256LL;
v4 = malloc(256LL);
if ( v4 )
{
v5 = v4;
v6 = 0;
while ( 1 )
{
va_start(va, a2);
v7 = vsnprintf(v5, v3, a2, va);
if ( v7 < 0 )
break;
if ( v3 > (unsigned int)v7 )
{
v9 = *(_QWORD *)(a1 + 8);
v10 = strlen(v5);
std::string::_M_replace(a1, 0LL, v9, v5, v10);
break;
}
v3 = (unsigned int)(v7 + 1);
v8 = realloc(v5, v3);
if ( v8 )
v5 = v8;
if ( v6 <= 4 )
{
++v6;
if ( v8 )
continue;
}
break;
}
free(v5);
return a1;
}
return v2;
}
| format[abi:cxx11]:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xe8
MOV R15,RSI
MOV RBX,RDI
MOV qword ptr [RSP + 0x40],RDX
MOV qword ptr [RSP + 0x48],RCX
MOV qword ptr [RSP + 0x50],R8
MOV qword ptr [RSP + 0x58],R9
TEST AL,AL
JZ 0x001092a2
MOVAPS xmmword ptr [RSP + 0x60],XMM0
MOVAPS xmmword ptr [RSP + 0x70],XMM1
MOVAPS xmmword ptr [RSP + 0x80],XMM2
MOVAPS xmmword ptr [RSP + 0x90],XMM3
MOVAPS xmmword ptr [RSP + 0xa0],XMM4
MOVAPS xmmword ptr [RSP + 0xb0],XMM5
MOVAPS xmmword ptr [RSP + 0xc0],XMM6
MOVAPS xmmword ptr [RSP + 0xd0],XMM7
LAB_001092a2:
LEA R13,[RDI + 0x10]
MOV qword ptr [RDI],R13
MOV qword ptr [RDI + 0x8],0x0
MOV byte ptr [RDI + 0x10],0x0
MOV R12D,0x100
MOV EDI,0x100
CALL 0x00103390
TEST RAX,RAX
JZ 0x00109378
MOV R14,RAX
MOV qword ptr [RSP + 0x8],R13
MOV qword ptr [RSP],RBX
XOR EBP,EBP
MOV RBX,0x3000000010
LEA R13,[RSP + 0x10]
LAB_001092eb:
LEA RAX,[RSP + 0x30]
MOV qword ptr [RSP + 0x20],RAX
LEA RAX,[RSP + 0x120]
MOV qword ptr [RSP + 0x18],RAX
MOV qword ptr [RSP + 0x10],RBX
MOV RDI,R14
MOV RSI,R12
MOV RDX,R15
MOV RCX,R13
CALL 0x00103190
TEST EAX,EAX
JS 0x0010936c
MOV ECX,EAX
CMP R12,RCX
JA 0x00109349
MOV R12D,EAX
INC R12D
MOV RDI,R14
MOV RSI,R12
CALL 0x00103490
TEST RAX,RAX
CMOVNZ R14,RAX
CMP EBP,0x4
JA 0x0010936c
INC EBP
TEST RAX,RAX
JNZ 0x001092eb
JMP 0x0010936c
LAB_00109349:
MOV RBX,qword ptr [RSP]
MOV R15,qword ptr [RBX + 0x8]
MOV RDI,R14
CALL 0x00103130
LAB_00109359:
MOV RDI,RBX
XOR ESI,ESI
MOV RDX,R15
MOV RCX,R14
MOV R8,RAX
CALL 0x00103450
LAB_0010936c:
MOV RDI,R14
CALL 0x00103350
MOV RBX,qword ptr [RSP]
LAB_00109378:
MOV RAX,RBX
ADD RSP,0xe8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* format[abi:cxx11](char const*, ...) */
char * format_abi_cxx11_(char *param_1,...)
{
char in_AL;
uint uVar1;
char *__s;
char *pcVar2;
int8 in_RCX;
int8 in_RDX;
uint uVar3;
char *in_RSI;
int8 in_R8;
int8 in_R9;
size_t __maxlen;
int8 in_XMM0_Qa;
int8 in_XMM1_Qa;
int8 in_XMM2_Qa;
int8 in_XMM3_Qa;
int8 in_XMM4_Qa;
int8 in_XMM5_Qa;
int8 in_XMM6_Qa;
int8 in_XMM7_Qa;
int8 local_108;
int1 *local_100;
int1 *local_f8;
int1 local_e8 [16];
int8 local_d8;
int8 local_d0;
int8 local_c8;
int8 local_c0;
int8 local_b8;
int8 local_a8;
int8 local_98;
int8 local_88;
int8 local_78;
int8 local_68;
int8 local_58;
int8 local_48;
if (in_AL != '\0') {
local_b8 = in_XMM0_Qa;
local_a8 = in_XMM1_Qa;
local_98 = in_XMM2_Qa;
local_88 = in_XMM3_Qa;
local_78 = in_XMM4_Qa;
local_68 = in_XMM5_Qa;
local_58 = in_XMM6_Qa;
local_48 = in_XMM7_Qa;
}
*(char **)param_1 = param_1 + 0x10;
param_1[8] = '\0';
param_1[9] = '\0';
param_1[10] = '\0';
param_1[0xb] = '\0';
param_1[0xc] = '\0';
param_1[0xd] = '\0';
param_1[0xe] = '\0';
param_1[0xf] = '\0';
param_1[0x10] = '\0';
__maxlen = 0x100;
local_d8 = in_RDX;
local_d0 = in_RCX;
local_c8 = in_R8;
local_c0 = in_R9;
__s = (char *)malloc(0x100);
if (__s != (char *)0x0) {
uVar3 = 0;
while( true ) {
local_f8 = local_e8;
local_100 = &stack0x00000008;
local_108 = 0x3000000010;
uVar1 = vsnprintf(__s,__maxlen,in_RSI,&local_108);
if ((int)uVar1 < 0) break;
if (uVar1 < __maxlen) {
pcVar2 = *(char **)(param_1 + 8);
strlen(__s);
/* try { // try from 00109359 to 0010936b has its CatchHandler @ 0010938d */
std::__cxx11::string::_M_replace((ulong)param_1,0,pcVar2,(ulong)__s);
break;
}
__maxlen = (size_t)(uVar1 + 1);
pcVar2 = (char *)realloc(__s,__maxlen);
if (pcVar2 != (char *)0x0) {
__s = pcVar2;
}
if ((4 < uVar3) || (uVar3 = uVar3 + 1, pcVar2 == (char *)0x0)) break;
}
free(__s);
}
return param_1;
}
| |
22,112 | search_default_file | eloqsql/mysys/my_default.c | static int search_default_file(struct handle_option_ctx *ctx, const char *dir,
const char *config_file)
{
char **ext;
const char *empty_list[]= { "", 0 };
my_bool have_ext= fn_ext(config_file)[0] != 0;
const char **exts_to_use= have_ext ? empty_list : f_extensions;
for (ext= (char**) exts_to_use; *ext; ext++)
{
int error;
if ((error= search_default_file_with_ext(ctx, dir, *ext, config_file, 0)) < 0)
return error;
}
return 0;
} | O3 | c | search_default_file:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq %rdx, %rdi
callq 0x641d8
cmpb $0x0, (%rax)
leaq 0x2c5e04(%rip), %rax # 0x329ca0
leaq 0x2c5e0d(%rip), %r12 # 0x329cb0
cmoveq %rax, %r12
movq (%r12), %rdx
testq %rdx, %rdx
je 0x63ed6
addq $0x8, %r12
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rcx
xorl %r8d, %r8d
callq 0x2a612
testl %eax, %eax
js 0x63ed8
movq (%r12), %rdx
addq $0x8, %r12
testq %rdx, %rdx
jne 0x63eb4
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| search_default_file:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
mov rbx, rdx
mov r14, rsi
mov r15, rdi
mov rdi, rdx
call fn_ext
cmp byte ptr [rax], 0
lea rax, f_extensions
lea r12, off_329CB0; ""
cmovz r12, rax
mov rdx, [r12]
test rdx, rdx
jz short loc_63ED6
add r12, 8
loc_63EB4:
mov rdi, r15
mov rsi, r14
mov rcx, rbx
xor r8d, r8d
call search_default_file_with_ext
test eax, eax
js short loc_63ED8
mov rdx, [r12]
add r12, 8
test rdx, rdx
jnz short loc_63EB4
loc_63ED6:
xor eax, eax
loc_63ED8:
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| long long search_default_file(long long a1, _BYTE *a2, long long a3)
{
char **v4; // r12
char *v5; // rdx
char **i; // r12
long long result; // rax
v4 = (char **)&off_329CB0;
if ( !*(_BYTE *)fn_ext(a3) )
v4 = &f_extensions;
v5 = *v4;
if ( !*v4 )
return 0LL;
for ( i = v4 + 1; ; ++i )
{
result = search_default_file_with_ext(a1, a2, (int)v5, a3, 0);
if ( (int)result < 0 )
break;
v5 = *i;
if ( !v5 )
return 0LL;
}
return result;
}
| search_default_file:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV RBX,RDX
MOV R14,RSI
MOV R15,RDI
MOV RDI,RDX
CALL 0x001641d8
CMP byte ptr [RAX],0x0
LEA RAX,[0x429ca0]
LEA R12,[0x429cb0]
CMOVZ R12,RAX
MOV RDX,qword ptr [R12]
TEST RDX,RDX
JZ 0x00163ed6
ADD R12,0x8
LAB_00163eb4:
MOV RDI,R15
MOV RSI,R14
MOV RCX,RBX
XOR R8D,R8D
CALL 0x0012a612
TEST EAX,EAX
JS 0x00163ed8
MOV RDX,qword ptr [R12]
ADD R12,0x8
TEST RDX,RDX
JNZ 0x00163eb4
LAB_00163ed6:
XOR EAX,EAX
LAB_00163ed8:
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
int8 search_default_file(int8 param_1,int8 param_2,int8 param_3)
{
int *puVar1;
char *pcVar2;
int8 uVar3;
int **ppuVar4;
pcVar2 = (char *)fn_ext(param_3);
ppuVar4 = &PTR_DAT_00429cb0;
if (*pcVar2 == '\0') {
ppuVar4 = (int **)f_extensions;
}
puVar1 = *ppuVar4;
while( true ) {
if (puVar1 == (int *)0x0) {
return 0;
}
ppuVar4 = ppuVar4 + 1;
uVar3 = search_default_file_with_ext(param_1,param_2,puVar1,param_3,0);
if ((int)uVar3 < 0) break;
puVar1 = *ppuVar4;
}
return uVar3;
}
| |
22,113 | sort_locks | eloqsql/mysys/thr_lock.c | static void sort_locks(THR_LOCK_DATA **data,uint count)
{
THR_LOCK_DATA **pos,**end,**prev,*tmp;
/* Sort locks with insertion sort (fast because almost always few locks) */
for (pos=data+1,end=data+count; pos < end ; pos++)
{
tmp= *pos;
if (LOCK_CMP(tmp,pos[-1]))
{
prev=pos;
do {
prev[0]=prev[-1];
} while (--prev != data && LOCK_CMP(tmp,prev[-1]));
prev[0]=tmp;
}
}
} | O0 | c | sort_locks:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl -0xc(%rbp), %ecx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpq -0x20(%rbp), %rax
jae 0x84659
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
movq -0x18(%rbp), %rax
movq -0x8(%rax), %rsi
callq 0x85ea0
cmpl $0x0, %eax
je 0x84646
movq -0x18(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq -0x8(%rax), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movq -0x28(%rbp), %rcx
addq $-0x8, %rcx
movq %rcx, -0x28(%rbp)
xorl %eax, %eax
cmpq -0x8(%rbp), %rcx
movb %al, -0x31(%rbp)
je 0x84634
movq -0x30(%rbp), %rdi
movq -0x28(%rbp), %rax
movq -0x8(%rax), %rsi
callq 0x85ea0
cmpl $0x0, %eax
setne %al
movb %al, -0x31(%rbp)
movb -0x31(%rbp), %al
testb $0x1, %al
jne 0x845f4
movq -0x30(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
jmp 0x84648
movq -0x18(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x18(%rbp)
jmp 0x845bd
addq $0x40, %rsp
popq %rbp
retq
nop
| sort_locks:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov rax, [rbp+var_8]
add rax, 8
mov [rbp+var_18], rax
mov rax, [rbp+var_8]
mov ecx, [rbp+var_C]
shl rcx, 3
add rax, rcx
mov [rbp+var_20], rax
loc_845BD:
mov rax, [rbp+var_18]
cmp rax, [rbp+var_20]
jnb loc_84659
mov rax, [rbp+var_18]
mov rax, [rax]
mov [rbp+var_30], rax
mov rdi, [rbp+var_30]
mov rax, [rbp+var_18]
mov rsi, [rax-8]
call LOCK_CMP
cmp eax, 0
jz short loc_84646
mov rax, [rbp+var_18]
mov [rbp+var_28], rax
loc_845F4:
mov rax, [rbp+var_28]
mov rcx, [rax-8]
mov rax, [rbp+var_28]
mov [rax], rcx
mov rcx, [rbp+var_28]
add rcx, 0FFFFFFFFFFFFFFF8h
mov [rbp+var_28], rcx
xor eax, eax
cmp rcx, [rbp+var_8]
mov [rbp+var_31], al
jz short loc_84634
mov rdi, [rbp+var_30]
mov rax, [rbp+var_28]
mov rsi, [rax-8]
call LOCK_CMP
cmp eax, 0
setnz al
mov [rbp+var_31], al
loc_84634:
mov al, [rbp+var_31]
test al, 1
jnz short loc_845F4
mov rcx, [rbp+var_30]
mov rax, [rbp+var_28]
mov [rax], rcx
loc_84646:
jmp short $+2
loc_84648:
mov rax, [rbp+var_18]
add rax, 8
mov [rbp+var_18], rax
jmp loc_845BD
loc_84659:
add rsp, 40h
pop rbp
retn
| _QWORD * sort_locks(_QWORD *a1, int a2)
{
_QWORD *result; // rax
bool v3; // [rsp+Fh] [rbp-31h]
long long v4; // [rsp+10h] [rbp-30h]
_QWORD *v5; // [rsp+18h] [rbp-28h]
_QWORD *i; // [rsp+28h] [rbp-18h]
for ( i = a1 + 1; ; ++i )
{
result = i;
if ( i >= &a1[a2] )
break;
v4 = *i;
if ( (unsigned int)LOCK_CMP(*i, *(i - 1)) )
{
v5 = i;
do
{
*v5 = *(v5 - 1);
--v5;
v3 = 0;
if ( v5 != a1 )
v3 = (unsigned int)LOCK_CMP(v4, *(v5 - 1)) != 0;
}
while ( v3 );
*v5 = v4;
}
}
return result;
}
| sort_locks:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV RAX,qword ptr [RBP + -0x8]
ADD RAX,0x8
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RBP + -0xc]
SHL RCX,0x3
ADD RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
LAB_001845bd:
MOV RAX,qword ptr [RBP + -0x18]
CMP RAX,qword ptr [RBP + -0x20]
JNC 0x00184659
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x30],RAX
MOV RDI,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RAX + -0x8]
CALL 0x00185ea0
CMP EAX,0x0
JZ 0x00184646
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x28],RAX
LAB_001845f4:
MOV RAX,qword ptr [RBP + -0x28]
MOV RCX,qword ptr [RAX + -0x8]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x28]
ADD RCX,-0x8
MOV qword ptr [RBP + -0x28],RCX
XOR EAX,EAX
CMP RCX,qword ptr [RBP + -0x8]
MOV byte ptr [RBP + -0x31],AL
JZ 0x00184634
MOV RDI,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x28]
MOV RSI,qword ptr [RAX + -0x8]
CALL 0x00185ea0
CMP EAX,0x0
SETNZ AL
MOV byte ptr [RBP + -0x31],AL
LAB_00184634:
MOV AL,byte ptr [RBP + -0x31]
TEST AL,0x1
JNZ 0x001845f4
MOV RCX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RAX],RCX
LAB_00184646:
JMP 0x00184648
LAB_00184648:
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x8
MOV qword ptr [RBP + -0x18],RAX
JMP 0x001845bd
LAB_00184659:
ADD RSP,0x40
POP RBP
RET
|
void sort_locks(int8 *param_1,uint param_2)
{
int8 uVar1;
int iVar2;
int8 *puVar3;
bool bVar4;
int8 *local_30;
int8 *local_20;
for (local_20 = param_1 + 1; local_20 < param_1 + param_2; local_20 = local_20 + 1) {
uVar1 = *local_20;
iVar2 = LOCK_CMP(uVar1,local_20[-1]);
if (iVar2 != 0) {
local_30 = local_20;
do {
*local_30 = local_30[-1];
puVar3 = local_30 + -1;
bVar4 = false;
if (puVar3 != param_1) {
iVar2 = LOCK_CMP(uVar1,local_30[-2]);
bVar4 = iVar2 != 0;
}
local_30 = puVar3;
} while (bVar4);
*puVar3 = uVar1;
}
}
return;
}
| |
22,114 | c4_tx_verify_tx_hash | corpus-core[P]colibri-stateless/src/chains/eth/verifier/eth_tx.c | INTERNAL bool c4_tx_verify_tx_hash(verify_ctx_t* ctx, bytes_t raw) {
if (ctx->method == NULL) return true;
if (strcmp(ctx->method, "eth_getTransactionByHash") == 0 || strcmp(ctx->method, "eth_getTransactionReceipt") == 0) {
json_t expected_hash = json_at(ctx->args, 0);
if (expected_hash.type != JSON_TYPE_STRING || expected_hash.len > 68) RETURN_VERIFY_ERROR(ctx, "invalid transaction hash!");
bytes32_t tmp = {0};
bytes32_t calculated_hash = {0};
buffer_t buf = stack_buffer(tmp);
bytes_t expected = json_as_bytes(expected_hash, &buf);
keccak(raw, calculated_hash);
if (expected.len != 32 || memcmp(expected.data, calculated_hash, 32) != 0) RETURN_VERIFY_ERROR(ctx, "invalid transaction hash!");
return true;
}
RETURN_VERIFY_ERROR(ctx, "invalid method for tx proof!");
} | O2 | c | c4_tx_verify_tx_hash:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq (%rdi), %r15
testq %r15, %r15
je 0x29b48
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x4993c(%rip), %rsi # 0x73397
movq %r15, %rdi
callq 0x22310
testl %eax, %eax
je 0x29a8a
leaq 0x4990f(%rip), %rsi # 0x7337d
movq %r15, %rdi
callq 0x22310
testl %eax, %eax
je 0x29a8a
leaq 0x70(%rbx), %rdi
leaq 0x4a4fe(%rip), %rsi # 0x73f83
jmp 0x29b3b
movq 0x18(%rbx), %rax
movq %rax, 0x10(%rsp)
movups 0x8(%rbx), %xmm0
movups %xmm0, (%rsp)
leaq 0x18(%rsp), %r15
movq %r15, %rdi
xorl %esi, %esi
callq 0x4e72e
cmpl $0x1, 0x10(%r15)
jne 0x29b30
cmpq $0x45, 0x20(%rsp)
jae 0x29b30
xorps %xmm0, %xmm0
leaq 0x70(%rsp), %rax
movaps %xmm0, 0x10(%rax)
movaps %xmm0, (%rax)
leaq 0x30(%rsp), %r12
leaq 0x58(%rsp), %rdi
andl $0x0, (%rdi)
movaps %xmm0, 0x10(%r12)
movaps %xmm0, (%r12)
movq %rax, 0x8(%rdi)
movl $0xffffffe0, 0x10(%rdi) # imm = 0xFFFFFFE0
movq 0x28(%rsp), %rax
movq %rax, 0x10(%rsp)
movups 0x18(%rsp), %xmm0
movups %xmm0, (%rsp)
callq 0x4e98c
movl %eax, %r13d
movq %rdx, %r15
movl %ebp, %edi
movq %r14, %rsi
movq %r12, %rdx
callq 0x4dcd0
cmpl $0x20, %r13d
jne 0x29b30
leaq 0x30(%rsp), %rsi
pushq $0x20
popq %rdx
movq %r15, %rdi
callq 0x22230
testl %eax, %eax
je 0x29b48
leaq 0x70(%rbx), %rdi
leaq 0x4ab83(%rip), %rsi # 0x746be
callq 0x4f75d
movb $0x0, 0x68(%rbx)
xorl %eax, %eax
jmp 0x29b4a
movb $0x1, %al
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| c4_tx_verify_tx_hash:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 98h
mov r15, [rdi]
test r15, r15
jz loc_29B48
mov r14, rdx
mov ebp, esi
mov rbx, rdi
lea rsi, aEthGettransact_0; "eth_getTransactionByHash"
mov rdi, r15
call _strcmp
test eax, eax
jz short loc_29A8A
lea rsi, aEthGettransact_3; "eth_getTransactionReceipt"
mov rdi, r15
call _strcmp
test eax, eax
jz short loc_29A8A
lea rdi, [rbx+70h]
lea rsi, aInvalidMethodF; "invalid method for tx proof!"
jmp loc_29B3B
loc_29A8A:
mov rax, [rbx+18h]
mov [rsp+0C8h+var_B8], rax
movups xmm0, xmmword ptr [rbx+8]
movups [rsp+0C8h+var_C8], xmm0
lea r15, [rsp+0C8h+var_B0]
mov rdi, r15
xor esi, esi
call json_at
cmp dword ptr [r15+10h], 1
jnz short loc_29B30
cmp qword ptr [rsp+0C8h+var_B0+8], 45h ; 'E'
jnb short loc_29B30
xorps xmm0, xmm0
lea rax, [rsp+0C8h+var_58]
movaps xmmword ptr [rax+10h], xmm0
movaps xmmword ptr [rax], xmm0
lea r12, [rsp+0C8h+var_98]
lea rdi, [rsp+0C8h+var_70]
and dword ptr [rdi], 0
movaps xmmword ptr [r12+10h], xmm0
movaps xmmword ptr [r12], xmm0
mov [rdi+8], rax
mov dword ptr [rdi+10h], 0FFFFFFE0h
mov rax, [rsp+0C8h+var_A0]
mov [rsp+0C8h+var_B8], rax
movups xmm0, [rsp+0C8h+var_B0]
movups [rsp+0C8h+var_C8], xmm0
call json_as_bytes
mov r13d, eax
mov r15, rdx
mov edi, ebp
mov rsi, r14
mov rdx, r12
call keccak
cmp r13d, 20h ; ' '
jnz short loc_29B30
lea rsi, [rsp+0C8h+var_98]
push 20h ; ' '
pop rdx
mov rdi, r15
call _bcmp
test eax, eax
jz short loc_29B48
loc_29B30:
lea rdi, [rbx+70h]
lea rsi, aInvalidTransac_1; "invalid transaction hash!"
loc_29B3B:
call c4_state_add_error
mov byte ptr [rbx+68h], 0
xor eax, eax
jmp short loc_29B4A
loc_29B48:
mov al, 1
loc_29B4A:
add rsp, 98h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| char c4_tx_verify_tx_hash(long long *a1, unsigned int a2, long long a3)
{
long long v3; // r15
int v6; // edx
int v7; // ecx
int v8; // r8d
int v9; // r9d
long long *v10; // rdi
const char *v11; // rsi
int v12; // edx
int v13; // ecx
int v14; // r8d
int v15; // r9d
int v16; // r13d
long long v17; // rdx
long long v18; // r15
__int128 v20; // [rsp+18h] [rbp-B0h] BYREF
long long v21; // [rsp+28h] [rbp-A0h]
_BYTE v22[40]; // [rsp+30h] [rbp-98h] BYREF
int v23; // [rsp+58h] [rbp-70h] BYREF
_BYTE *v24; // [rsp+60h] [rbp-68h]
int v25; // [rsp+68h] [rbp-60h]
_BYTE v26[88]; // [rsp+70h] [rbp-58h] BYREF
v3 = *a1;
if ( *a1 )
{
if ( (unsigned int)strcmp(*a1, "eth_getTransactionByHash") && (unsigned int)strcmp(v3, "eth_getTransactionReceipt") )
{
v10 = a1 + 14;
v11 = "invalid method for tx proof!";
LABEL_10:
c4_state_add_error(v10, v11);
*((_BYTE *)a1 + 104) = 0;
return 0;
}
json_at((unsigned int)&v20, 0, v6, v7, v8, v9, a1[1], a1[2], a1[3]);
if ( (_DWORD)v21 != 1 )
goto LABEL_9;
if ( *((_QWORD *)&v20 + 1) >= 0x45uLL )
goto LABEL_9;
memset(v26, 0, 32);
v23 = 0;
memset(v22, 0, 32);
v24 = v26;
v25 = -32;
v16 = json_as_bytes((unsigned int)&v23, 0, v12, v13, v14, v15, v20, v21);
v18 = v17;
keccak(a2, a3, v22);
if ( v16 != 32 || (unsigned int)bcmp(v18, v22, 32LL) )
{
LABEL_9:
v10 = a1 + 14;
v11 = "invalid transaction hash!";
goto LABEL_10;
}
}
return 1;
}
| c4_tx_verify_tx_hash:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x98
MOV R15,qword ptr [RDI]
TEST R15,R15
JZ 0x00129b48
MOV R14,RDX
MOV EBP,ESI
MOV RBX,RDI
LEA RSI,[0x173397]
MOV RDI,R15
CALL 0x00122310
TEST EAX,EAX
JZ 0x00129a8a
LEA RSI,[0x17337d]
MOV RDI,R15
CALL 0x00122310
TEST EAX,EAX
JZ 0x00129a8a
LEA RDI,[RBX + 0x70]
LEA RSI,[0x173f83]
JMP 0x00129b3b
LAB_00129a8a:
MOV RAX,qword ptr [RBX + 0x18]
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [RBX + 0x8]
MOVUPS xmmword ptr [RSP],XMM0
LEA R15,[RSP + 0x18]
MOV RDI,R15
XOR ESI,ESI
CALL 0x0014e72e
CMP dword ptr [R15 + 0x10],0x1
JNZ 0x00129b30
CMP qword ptr [RSP + 0x20],0x45
JNC 0x00129b30
XORPS XMM0,XMM0
LEA RAX,[RSP + 0x70]
MOVAPS xmmword ptr [RAX + 0x10],XMM0
MOVAPS xmmword ptr [RAX],XMM0
LEA R12,[RSP + 0x30]
LEA RDI,[RSP + 0x58]
AND dword ptr [RDI],0x0
MOVAPS xmmword ptr [R12 + 0x10],XMM0
MOVAPS xmmword ptr [R12],XMM0
MOV qword ptr [RDI + 0x8],RAX
MOV dword ptr [RDI + 0x10],0xffffffe0
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [RSP + 0x18]
MOVUPS xmmword ptr [RSP],XMM0
CALL 0x0014e98c
MOV R13D,EAX
MOV R15,RDX
MOV EDI,EBP
MOV RSI,R14
MOV RDX,R12
CALL 0x0014dcd0
CMP R13D,0x20
JNZ 0x00129b30
LEA RSI,[RSP + 0x30]
PUSH 0x20
POP RDX
MOV RDI,R15
CALL 0x00122230
TEST EAX,EAX
JZ 0x00129b48
LAB_00129b30:
LEA RDI,[RBX + 0x70]
LEA RSI,[0x1746be]
LAB_00129b3b:
CALL 0x0014f75d
MOV byte ptr [RBX + 0x68],0x0
XOR EAX,EAX
JMP 0x00129b4a
LAB_00129b48:
MOV AL,0x1
LAB_00129b4a:
ADD RSP,0x98
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8 c4_tx_verify_tx_hash(int8 *param_1,int4 param_2,int8 param_3)
{
int iVar1;
int8 uVar2;
void *__s1;
char *pcVar3;
int1 local_b0 [8];
int4 uStack_a8;
int4 uStack_a4;
int local_a0;
int8 local_98;
int8 uStack_90;
int8 local_88;
int8 uStack_80;
int4 local_70;
int8 *local_68;
int4 local_60;
int8 local_58;
int8 uStack_50;
int8 local_48;
int8 uStack_40;
pcVar3 = (char *)*param_1;
if (pcVar3 == (char *)0x0) {
LAB_00129b48:
uVar2 = 1;
}
else {
iVar1 = strcmp(pcVar3,"eth_getTransactionByHash");
if (iVar1 == 0) {
LAB_00129a8a:
json_at(local_b0,0);
if ((local_a0 == 1) && (CONCAT44(uStack_a4,uStack_a8) < 0x45)) {
local_68 = &local_58;
local_48 = 0;
uStack_40 = 0;
local_58 = 0;
uStack_50 = 0;
local_70 = 0;
local_88 = 0;
uStack_80 = 0;
local_98 = 0;
uStack_90 = 0;
local_60 = 0xffffffe0;
iVar1 = json_as_bytes();
keccak(param_2,param_3,&local_98);
if (iVar1 == 0x20) {
iVar1 = bcmp(__s1,&local_98,0x20);
if (iVar1 == 0) goto LAB_00129b48;
}
}
pcVar3 = "invalid transaction hash!";
}
else {
iVar1 = strcmp(pcVar3,"eth_getTransactionReceipt");
if (iVar1 == 0) goto LAB_00129a8a;
pcVar3 = "invalid method for tx proof!";
}
c4_state_add_error(param_1 + 0xe,pcVar3);
*(int1 *)(param_1 + 0xd) = 0;
uVar2 = 0;
}
return uVar2;
}
| |
22,115 | 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>>::decode(unsigned char&, unsigned int&, unsigned char) | monkey531[P]llama/common/json.hpp | static std::uint8_t decode(std::uint8_t& state, std::uint32_t& codep, const std::uint8_t byte) noexcept
{
static const std::array<std::uint8_t, 400> utf8d =
{
{
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 00..1F
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 20..3F
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 40..5F
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 60..7F
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, // 80..9F
7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, // A0..BF
8, 8, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, // C0..DF
0xA, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x3, 0x4, 0x3, 0x3, // E0..EF
0xB, 0x6, 0x6, 0x6, 0x5, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, 0x8, // F0..FF
0x0, 0x1, 0x2, 0x3, 0x5, 0x8, 0x7, 0x1, 0x1, 0x1, 0x4, 0x6, 0x1, 0x1, 0x1, 0x1, // s0..s0
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, // s1..s2
1, 2, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, // s3..s4
1, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 3, 1, 1, 1, 1, 1, 1, // s5..s6
1, 3, 1, 1, 1, 1, 1, 3, 1, 3, 1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 // s7..s8
}
};
JSON_ASSERT(byte < utf8d.size());
const std::uint8_t type = utf8d[byte];
codep = (state != UTF8_ACCEPT)
? (byte & 0x3fu) | (codep << 6u)
: (0xFFu >> type) & (byte);
const std::size_t index = 256u + static_cast<size_t>(state) * 16u + static_cast<size_t>(type);
JSON_ASSERT(index < utf8d.size());
state = utf8d[index];
return state;
} | O1 | cpp | nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::decode(unsigned char&, unsigned int&, unsigned char):
pushq %rax
movl %edx, %ecx
leaq 0x35666(%rip), %rax # 0xb0cbe
movzbl (%rax,%rcx), %ecx
cmpb $0x0, (%rdi)
je 0x7b672
andb $0x3f, %dl
movzbl %dl, %r8d
movl (%rsi), %edx
shll $0x6, %edx
orl %r8d, %edx
jmp 0x7b681
movl $0xff, %r8d
shrl %cl, %r8d
movzbl %dl, %edx
andl %r8d, %edx
movl %edx, (%rsi)
movzbl (%rdi), %edx
shll $0x4, %edx
movl %ecx, %ecx
addq %rdx, %rcx
addq $0x100, %rcx # imm = 0x100
cmpq $0x190, %rcx # imm = 0x190
jae 0x7b6a5
movb (%rax,%rcx), %al
movb %al, (%rdi)
popq %rcx
retq
leaq 0x2ffab(%rip), %rdi # 0xab657
leaq 0x2e75e(%rip), %rdx # 0xa9e11
leaq 0x32a96(%rip), %rcx # 0xae150
movl $0x49fb, %esi # imm = 0x49FB
xorl %eax, %eax
callq 0x18ad0
movq %rax, %rdi
callq 0x2a807
| _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE6decodeERhRjh:
push rax
mov ecx, edx
lea rax, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE6decodeERhRjhE5utf8d; 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>>::decode(uchar &,uint &,uchar)::utf8d
movzx ecx, byte ptr [rax+rcx]
cmp byte ptr [rdi], 0
jz short loc_7B672
and dl, 3Fh
movzx r8d, dl
mov edx, [rsi]
shl edx, 6
or edx, r8d
jmp short loc_7B681
loc_7B672:
mov r8d, 0FFh
shr r8d, cl
movzx edx, dl
and edx, r8d
loc_7B681:
mov [rsi], edx
movzx edx, byte ptr [rdi]
shl edx, 4
mov ecx, ecx
add rcx, rdx
add rcx, 100h
cmp rcx, 190h
jnb short loc_7B6A5
mov al, [rax+rcx]
mov [rdi], al
pop rcx
retn
loc_7B6A5:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aIndexUtf8dSize; "index < utf8d.size()"
mov esi, 49FBh
xor eax, eax
call _ggml_abort
mov rdi, rax
call __clang_call_terminate
| unsigned __int8 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>>::decode(
unsigned __int8 *a1,
unsigned int *a2,
int a3)
{
unsigned int v3; // ecx
unsigned int v4; // edx
unsigned long long v5; // rcx
unsigned __int8 result; // al
void *v7; // rax
v3 = 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>>::decode(unsigned char &,unsigned int &,unsigned char)::utf8d[a3];
if ( *a1 )
v4 = a3 & 0x3F | (*a2 << 6);
else
v4 = (0xFFu >> v3) & (unsigned __int8)a3;
*a2 = v4;
v5 = 16 * (unsigned int)*a1 + (unsigned long long)v3 + 256;
if ( v5 >= 0x190 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
18939LL,
"GGML_ASSERT(%s) failed",
"index < utf8d.size()");
_clang_call_terminate(v7);
}
result = 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>>::decode(unsigned char &,unsigned int &,unsigned char)::utf8d[v5];
*a1 = result;
return result;
}
| decode:
PUSH RAX
MOV ECX,EDX
LEA RAX,[0x1b0cbe]
MOVZX ECX,byte ptr [RAX + RCX*0x1]
CMP byte ptr [RDI],0x0
JZ 0x0017b672
AND DL,0x3f
MOVZX R8D,DL
MOV EDX,dword ptr [RSI]
SHL EDX,0x6
OR EDX,R8D
JMP 0x0017b681
LAB_0017b672:
MOV R8D,0xff
SHR R8D,CL
MOVZX EDX,DL
AND EDX,R8D
LAB_0017b681:
MOV dword ptr [RSI],EDX
MOVZX EDX,byte ptr [RDI]
SHL EDX,0x4
MOV ECX,ECX
ADD RCX,RDX
ADD RCX,0x100
CMP RCX,0x190
JNC 0x0017b6a5
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDI],AL
POP RCX
RET
LAB_0017b6a5:
LEA RDI,[0x1ab657]
LEA RDX,[0x1a9e11]
LEA RCX,[0x1ae150]
MOV ESI,0x49fb
XOR EAX,EAX
CALL 0x00118ad0
|
/* 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> >::decode(unsigned char&, unsigned int&, unsigned char) */
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::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>>
::decode(uchar *param_1,uint *param_2,uchar param_3)
{
byte bVar1;
long lVar2;
uint uVar3;
int7 in_register_00000011;
bVar1 = decode(unsigned_char&,unsigned_int&,unsigned_char)::utf8d
[CONCAT71(in_register_00000011,param_3) & 0xffffffff];
if (*param_1 == '\0') {
uVar3 = (uint)param_3 & 0xffU >> (bVar1 & 0x1f);
}
else {
uVar3 = *param_2 << 6 | (uint)(param_3 & 0x3f);
}
*param_2 = uVar3;
lVar2 = (ulong)bVar1 + (ulong)*param_1 * 0x10;
if (lVar2 + 0x100U < 400) {
*param_1 = decode(unsigned_char&,unsigned_int&,unsigned_char)::utf8d[lVar2 + 0x100];
return;
}
/* try { // try from 0017b6a5 to 0017b6c5 has its CatchHandler @ 0017b6c6 */
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x49fb,
"GGML_ASSERT(%s) failed","index < utf8d.size()");
}
| |
22,116 | nglog::LogDestination::FlushLogFiles(int) | ng-log[P]ng-log/src/logging.cc | inline void LogDestination::FlushLogFiles(int min_severity) {
// Prevent any subtle race conditions by wrapping a mutex lock around
// all this stuff.
std::lock_guard<std::mutex> l{log_mutex};
for (int i = min_severity; i < NUM_SEVERITIES; i++) {
LogDestination* log = log_destination(static_cast<LogSeverity>(i));
if (log != nullptr) {
log->logger_->Flush();
}
}
} | O0 | cpp | nglog::LogDestination::FlushLogFiles(int):
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movl %edi, -0x4(%rbp)
leaq -0x10(%rbp), %rdi
leaq 0x67f72(%rip), %rsi # 0x7fe58
callq 0x17410
movl -0x4(%rbp), %eax
movl %eax, -0x14(%rbp)
cmpl $0x4, -0x14(%rbp)
jge 0x17f50
movl -0x14(%rbp), %edi
callq 0x17dd0
movq %rax, -0x38(%rbp)
jmp 0x17f05
movq -0x38(%rbp), %rax
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x17f43
movq -0x20(%rbp), %rax
movq 0xc8(%rax), %rdi
movq (%rdi), %rax
movq 0x18(%rax), %rax
callq *%rax
jmp 0x17f2a
jmp 0x17f43
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x10(%rbp), %rdi
callq 0x17440
jmp 0x17f5f
jmp 0x17f45
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x17ef1
leaq -0x10(%rbp), %rdi
callq 0x17440
addq $0x40, %rsp
popq %rbp
retq
movq -0x28(%rbp), %rdi
callq 0x9d00
nopl (%rax,%rax)
| _ZN5nglog14LogDestination13FlushLogFilesEi:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_4], edi
lea rdi, [rbp+var_10]
lea rsi, _ZN5nglogL9log_mutexE; nglog::log_mutex
call _ZNSt10lock_guardISt5mutexEC2ERS0_; std::lock_guard<std::mutex>::lock_guard(std::mutex&)
mov eax, [rbp+var_4]
mov [rbp+var_14], eax
loc_17EF1:
cmp [rbp+var_14], 4
jge short loc_17F50
mov edi, [rbp+var_14]
call _ZN5nglog14LogDestination15log_destinationENS_11LogSeverityE; nglog::LogDestination::log_destination(nglog::LogSeverity)
mov [rbp+var_38], rax
jmp short $+2
loc_17F05:
mov rax, [rbp+var_38]
mov [rbp+var_20], rax
cmp [rbp+var_20], 0
jz short loc_17F43
mov rax, [rbp+var_20]
mov rdi, [rax+0C8h]
mov rax, [rdi]
mov rax, [rax+18h]
call rax
jmp short $+2
loc_17F2A:
jmp short loc_17F43
mov rcx, rax
mov eax, edx
mov [rbp+var_28], rcx
mov [rbp+var_2C], eax
lea rdi, [rbp+var_10]
call _ZNSt10lock_guardISt5mutexED2Ev; std::lock_guard<std::mutex>::~lock_guard()
jmp short loc_17F5F
loc_17F43:
jmp short $+2
loc_17F45:
mov eax, [rbp+var_14]
add eax, 1
mov [rbp+var_14], eax
jmp short loc_17EF1
loc_17F50:
lea rdi, [rbp+var_10]
call _ZNSt10lock_guardISt5mutexED2Ev; std::lock_guard<std::mutex>::~lock_guard()
add rsp, 40h
pop rbp
retn
loc_17F5F:
mov rdi, [rbp+var_28]
call __Unwind_Resume
| long long nglog::LogDestination::FlushLogFiles(nglog::LogDestination *this)
{
long long v2; // [rsp+20h] [rbp-20h]
signed int i; // [rsp+2Ch] [rbp-14h]
std::mutex *v4; // [rsp+30h] [rbp-10h] BYREF
signed int v5; // [rsp+3Ch] [rbp-4h]
v5 = (int)this;
std::lock_guard<std::mutex>::lock_guard(&v4, (std::mutex *)&nglog::log_mutex);
for ( i = v5; i < 4; ++i )
{
v2 = nglog::LogDestination::log_destination(i);
if ( v2 )
(*(void ( **)(_QWORD))(**(_QWORD **)(v2 + 200) + 24LL))(*(_QWORD *)(v2 + 200));
}
return std::lock_guard<std::mutex>::~lock_guard(&v4);
}
| FlushLogFiles:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV dword ptr [RBP + -0x4],EDI
LEA RDI,[RBP + -0x10]
LEA RSI,[0x17fe58]
CALL 0x00117410
MOV EAX,dword ptr [RBP + -0x4]
MOV dword ptr [RBP + -0x14],EAX
LAB_00117ef1:
CMP dword ptr [RBP + -0x14],0x4
JGE 0x00117f50
MOV EDI,dword ptr [RBP + -0x14]
LAB_00117efa:
CALL 0x00117dd0
MOV qword ptr [RBP + -0x38],RAX
JMP 0x00117f05
LAB_00117f05:
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x20],RAX
CMP qword ptr [RBP + -0x20],0x0
JZ 0x00117f43
MOV RAX,qword ptr [RBP + -0x20]
MOV RDI,qword ptr [RAX + 0xc8]
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX + 0x18]
CALL RAX
LAB_00117f28:
JMP 0x00117f2a
LAB_00117f2a:
JMP 0x00117f43
LAB_00117f43:
JMP 0x00117f45
LAB_00117f45:
MOV EAX,dword ptr [RBP + -0x14]
ADD EAX,0x1
MOV dword ptr [RBP + -0x14],EAX
JMP 0x00117ef1
LAB_00117f50:
LEA RDI,[RBP + -0x10]
CALL 0x00117440
ADD RSP,0x40
POP RBP
RET
|
/* nglog::LogDestination::FlushLogFiles(int) */
void nglog::LogDestination::FlushLogFiles(int param_1)
{
long lVar1;
int local_1c;
lock_guard<std::mutex> local_18 [12];
int local_c;
local_c = param_1;
std::lock_guard<std::mutex>::lock_guard(local_18,(mutex *)log_mutex);
for (local_1c = local_c; local_1c < 4; local_1c = local_1c + 1) {
/* try { // try from 00117efa to 00117f27 has its CatchHandler @ 00117f2c */
lVar1 = log_destination(local_1c);
if (lVar1 != 0) {
(**(code **)(**(long **)(lVar1 + 200) + 0x18))();
}
}
std::lock_guard<std::mutex>::~lock_guard(local_18);
return;
}
| |
22,117 | get_thread_range(ggml_compute_params const*, ggml_tensor const*) | ngxson[P]ggml-easy/ggml/src/ggml-cpu/common.h | static std::pair<int64_t, int64_t> get_thread_range(const struct ggml_compute_params * params, const struct ggml_tensor * src0) {
const int64_t ith = params->ith;
const int64_t nth = params->nth;
const int64_t nr = ggml_nrows(src0);
// rows per thread
const int64_t dr = (nr + nth - 1)/nth;
// row range for this thread
const int64_t ir0 = dr*ith;
const int64_t ir1 = MIN(ir0 + dr, nr);
return {ir0, ir1};
} | O2 | c | get_thread_range(ggml_compute_params const*, ggml_tensor const*):
pushq %r14
pushq %rbx
pushq %rax
movslq (%rdi), %rbx
movslq 0x4(%rdi), %r14
movq %rsi, %rdi
callq 0xbb10
movq %rax, %rcx
addq %r14, %rax
decq %rax
cqto
idivq %r14
imulq %rax, %rbx
addq %rbx, %rax
cmpq %rcx, %rax
cmovlq %rax, %rcx
movq %rbx, %rax
movq %rcx, %rdx
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| _ZL16get_thread_rangePK19ggml_compute_paramsPK11ggml_tensor:
push r14
push rbx
push rax
movsxd rbx, dword ptr [rdi]
movsxd r14, dword ptr [rdi+4]
mov rdi, rsi
call _ggml_nrows
mov rcx, rax
add rax, r14
dec rax
cqo
idiv r14
imul rbx, rax
add rax, rbx
cmp rax, rcx
cmovl rcx, rax
mov rax, rbx
mov rdx, rcx
add rsp, 8
pop rbx
pop r14
retn
| long long get_thread_range(int *a1, long long a2)
{
long long v2; // rbx
long long v3; // r14
v2 = *a1;
v3 = a1[1];
return (v3 + ggml_nrows(a2) - 1) / v3 * v2;
}
| get_thread_range:
PUSH R14
PUSH RBX
PUSH RAX
MOVSXD RBX,dword ptr [RDI]
MOVSXD R14,dword ptr [RDI + 0x4]
MOV RDI,RSI
CALL 0x0010bb10
MOV RCX,RAX
ADD RAX,R14
DEC RAX
CQO
IDIV R14
IMUL RBX,RAX
ADD RAX,RBX
CMP RAX,RCX
CMOVL RCX,RAX
MOV RAX,RBX
MOV RDX,RCX
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* get_thread_range(ggml_compute_params const*, ggml_tensor const*) */
int1 [16] get_thread_range(ggml_compute_params *param_1,ggml_tensor *param_2)
{
int iVar1;
int iVar2;
long lVar3;
long lVar4;
long lVar5;
int1 auVar6 [16];
iVar1 = *(int *)param_1;
iVar2 = *(int *)(param_1 + 4);
lVar3 = ggml_nrows(param_2);
lVar4 = (lVar3 + iVar2 + -1) / (long)iVar2;
lVar5 = iVar1 * lVar4;
lVar4 = lVar4 + lVar5;
if (lVar4 < lVar3) {
lVar3 = lVar4;
}
auVar6._8_8_ = lVar3;
auVar6._0_8_ = lVar5;
return auVar6;
}
| |
22,118 | MemoryManager::getByteNoCache(unsigned int) | DanielDanyang[P]CSC3050-2025-Spring-Project-4/src/MemoryManager.cpp | uint8_t MemoryManager::getByteNoCache(uint32_t addr) {
if (!this->isAddrExist(addr)) {
dbgprintf("Byte read to invalid addr 0x%x!\n", addr);
return false;
}
uint32_t i = this->getFirstEntryId(addr);
uint32_t j = this->getSecondEntryId(addr);
uint32_t k = this->getPageOffset(addr);
return this->memory[i][j][k];
} | O0 | cpp | MemoryManager::getByteNoCache(unsigned int):
subq $0x28, %rsp
movq %rdi, 0x18(%rsp)
movl %esi, 0x14(%rsp)
movq 0x18(%rsp), %rdi
movq %rdi, (%rsp)
movl 0x14(%rsp), %esi
callq 0x3440
testb $0x1, %al
jne 0x383c
movl 0x14(%rsp), %esi
leaq 0x494f(%rip), %rdi # 0x817d
movb $0x0, %al
callq 0x4180
movb $0x0, 0x27(%rsp)
jmp 0x3890
movq (%rsp), %rdi
movl 0x14(%rsp), %esi
callq 0x33d0
movq (%rsp), %rdi
movl %eax, 0x10(%rsp)
movl 0x14(%rsp), %esi
callq 0x33f0
movq (%rsp), %rdi
movl %eax, 0xc(%rsp)
movl 0x14(%rsp), %esi
callq 0x3660
movl %eax, %ecx
movq (%rsp), %rax
movl %ecx, 0x8(%rsp)
movl 0x10(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movl 0xc(%rsp), %ecx
movq (%rax,%rcx,8), %rax
movl 0x8(%rsp), %ecx
movb (%rax,%rcx), %al
movb %al, 0x27(%rsp)
movb 0x27(%rsp), %al
addq $0x28, %rsp
retq
nopl (%rax)
| _ZN13MemoryManager14getByteNoCacheEj:
sub rsp, 28h
mov [rsp+28h+var_10], rdi
mov [rsp+28h+var_14], esi
mov rdi, [rsp+28h+var_10]; this
mov [rsp+28h+var_28], rdi
mov esi, [rsp+28h+var_14]; unsigned int
call _ZN13MemoryManager11isAddrExistEj; MemoryManager::isAddrExist(uint)
test al, 1
jnz short loc_383C
mov esi, [rsp+28h+var_14]
lea rdi, aByteReadToInva; "Byte read to invalid addr 0x%x!\n"
mov al, 0
call _Z9dbgprintfPKcz; dbgprintf(char const*,...)
mov [rsp+28h+var_1], 0
jmp short loc_3890
loc_383C:
mov rdi, [rsp+28h+var_28]; this
mov esi, [rsp+28h+var_14]; unsigned int
call _ZN13MemoryManager15getFirstEntryIdEj; MemoryManager::getFirstEntryId(uint)
mov rdi, [rsp+28h+var_28]; this
mov [rsp+28h+var_18], eax
mov esi, [rsp+28h+var_14]; unsigned int
call _ZN13MemoryManager16getSecondEntryIdEj; MemoryManager::getSecondEntryId(uint)
mov rdi, [rsp+28h+var_28]; this
mov [rsp+28h+var_1C], eax
mov esi, [rsp+28h+var_14]; unsigned int
call _ZN13MemoryManager13getPageOffsetEj; MemoryManager::getPageOffset(uint)
mov ecx, eax
mov rax, [rsp+28h+var_28]
mov [rsp+28h+var_20], ecx
mov ecx, [rsp+28h+var_18]
mov rax, [rax+rcx*8]
mov ecx, [rsp+28h+var_1C]
mov rax, [rax+rcx*8]
mov ecx, [rsp+28h+var_20]
mov al, [rax+rcx]
mov [rsp+28h+var_1], al
loc_3890:
mov al, [rsp+28h+var_1]
add rsp, 28h
retn
| char MemoryManager::getByteNoCache(MemoryManager *this, unsigned int a2)
{
unsigned int SecondEntryId; // [rsp+Ch] [rbp-1Ch]
unsigned int FirstEntryId; // [rsp+10h] [rbp-18h]
if ( MemoryManager::isAddrExist(this, a2) )
{
FirstEntryId = MemoryManager::getFirstEntryId(this, a2);
SecondEntryId = MemoryManager::getSecondEntryId(this, a2);
return *(_BYTE *)(*(_QWORD *)(*((_QWORD *)this + FirstEntryId) + 8LL * SecondEntryId)
+ (unsigned int)MemoryManager::getPageOffset(this, a2));
}
else
{
dbgprintf("Byte read to invalid addr 0x%x!\n", a2);
return 0;
}
}
| getByteNoCache:
SUB RSP,0x28
MOV qword ptr [RSP + 0x18],RDI
MOV dword ptr [RSP + 0x14],ESI
MOV RDI,qword ptr [RSP + 0x18]
MOV qword ptr [RSP],RDI
MOV ESI,dword ptr [RSP + 0x14]
CALL 0x00103440
TEST AL,0x1
JNZ 0x0010383c
MOV ESI,dword ptr [RSP + 0x14]
LEA RDI,[0x10817d]
MOV AL,0x0
CALL 0x00104180
MOV byte ptr [RSP + 0x27],0x0
JMP 0x00103890
LAB_0010383c:
MOV RDI,qword ptr [RSP]
MOV ESI,dword ptr [RSP + 0x14]
CALL 0x001033d0
MOV RDI,qword ptr [RSP]
MOV dword ptr [RSP + 0x10],EAX
MOV ESI,dword ptr [RSP + 0x14]
CALL 0x001033f0
MOV RDI,qword ptr [RSP]
MOV dword ptr [RSP + 0xc],EAX
MOV ESI,dword ptr [RSP + 0x14]
CALL 0x00103660
MOV ECX,EAX
MOV RAX,qword ptr [RSP]
MOV dword ptr [RSP + 0x8],ECX
MOV ECX,dword ptr [RSP + 0x10]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV ECX,dword ptr [RSP + 0xc]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV ECX,dword ptr [RSP + 0x8]
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RSP + 0x27],AL
LAB_00103890:
MOV AL,byte ptr [RSP + 0x27]
ADD RSP,0x28
RET
|
/* MemoryManager::getByteNoCache(unsigned int) */
int8 __thiscall MemoryManager::getByteNoCache(MemoryManager *this,uint param_1)
{
long lVar1;
uint uVar2;
uint uVar3;
uint uVar4;
ulong uVar5;
int7 extraout_var;
int7 uVar6;
int1 local_1;
uVar5 = isAddrExist(this,param_1);
if ((uVar5 & 1) == 0) {
dbgprintf("Byte read to invalid addr 0x%x!\n",(ulong)param_1);
local_1 = 0;
uVar6 = extraout_var;
}
else {
uVar2 = getFirstEntryId(this,param_1);
uVar3 = getSecondEntryId(this,param_1);
uVar4 = getPageOffset(this,param_1);
lVar1 = *(long *)(*(long *)(this + (ulong)uVar2 * 8) + (ulong)uVar3 * 8);
local_1 = *(int1 *)(lVar1 + (ulong)uVar4);
uVar6 = (int7)((ulong)lVar1 >> 8);
}
return CONCAT71(uVar6,local_1);
}
| |
22,119 | MemoryManager::getByteNoCache(unsigned int) | DanielDanyang[P]CSC3050-2025-Spring-Project-4/src/MemoryManager.cpp | uint8_t MemoryManager::getByteNoCache(uint32_t addr) {
if (!this->isAddrExist(addr)) {
dbgprintf("Byte read to invalid addr 0x%x!\n", addr);
return false;
}
uint32_t i = this->getFirstEntryId(addr);
uint32_t j = this->getSecondEntryId(addr);
uint32_t k = this->getPageOffset(addr);
return this->memory[i][j][k];
} | O3 | cpp | MemoryManager::getByteNoCache(unsigned int):
pushq %rbx
movl %esi, %eax
shrl $0x16, %eax
movq (%rdi,%rax,8), %rax
testq %rax, %rax
je 0x3064
movl %esi, %ecx
shrl $0x9, %ecx
andl $0x1ff8, %ecx # imm = 0x1FF8
movq (%rax,%rcx), %rax
testq %rax, %rax
je 0x3064
andl $0xfff, %esi # imm = 0xFFF
movb (%rax,%rsi), %bl
movl %ebx, %eax
popq %rbx
retq
leaq 0x214c(%rip), %rdi # 0x51b7
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x2330
jmp 0x3060
| _ZN13MemoryManager14getByteNoCacheEj:
push rbx
mov eax, esi
shr eax, 16h
mov rax, [rdi+rax*8]
test rax, rax
jz short loc_3064
mov ecx, esi
shr ecx, 9
and ecx, 1FF8h
mov rax, [rax+rcx]
test rax, rax
jz short loc_3064
and esi, 0FFFh
mov bl, [rax+rsi]
loc_3060:
mov eax, ebx
pop rbx
retn
loc_3064:
lea rdi, aByteReadToInva; "Byte read to invalid addr 0x%x!\n"
xor ebx, ebx
xor eax, eax
call _Z9dbgprintfPKcz; dbgprintf(char const*,...)
jmp short loc_3060
| long long MemoryManager::getByteNoCache(
MemoryManager *this,
long long a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14)
{
unsigned int v14; // ebx
long long v15; // rax
long long v16; // rax
char v18; // [rsp+0h] [rbp-8h]
v15 = *((_QWORD *)this + ((unsigned int)a2 >> 22));
if ( v15 && (a4 = ((unsigned int)a2 >> 9) & 0x1FF8, (v16 = *(_QWORD *)(v15 + a4)) != 0) )
{
LOBYTE(v14) = *(_BYTE *)(v16 + (a2 & 0xFFF));
}
else
{
v14 = 0;
dbgprintf("Byte read to invalid addr 0x%x!\n", a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v18);
}
return v14;
}
| getByteNoCache:
PUSH RBX
MOV EAX,ESI
SHR EAX,0x16
MOV RAX,qword ptr [RDI + RAX*0x8]
TEST RAX,RAX
JZ 0x00103064
MOV ECX,ESI
SHR ECX,0x9
AND ECX,0x1ff8
MOV RAX,qword ptr [RAX + RCX*0x1]
TEST RAX,RAX
JZ 0x00103064
AND ESI,0xfff
MOV BL,byte ptr [RAX + RSI*0x1]
LAB_00103060:
MOV EAX,EBX
POP RBX
RET
LAB_00103064:
LEA RDI,[0x1051b7]
XOR EBX,EBX
XOR EAX,EAX
CALL 0x00102330
JMP 0x00103060
|
/* MemoryManager::getByteNoCache(unsigned int) */
ulong __thiscall MemoryManager::getByteNoCache(MemoryManager *this,uint param_1)
{
long lVar1;
int8 unaff_RBX;
ulong uVar2;
if ((*(long *)(this + (ulong)(param_1 >> 0x16) * 8) == 0) ||
(lVar1 = *(long *)(*(long *)(this + (ulong)(param_1 >> 0x16) * 8) +
(ulong)(param_1 >> 9 & 0x1ff8)), lVar1 == 0)) {
uVar2 = 0;
dbgprintf("Byte read to invalid addr 0x%x!\n");
}
else {
uVar2 = CONCAT71((int7)((ulong)unaff_RBX >> 8),*(int1 *)(lVar1 + (ulong)(param_1 & 0xfff))
);
}
return uVar2 & 0xffffffff;
}
| |
22,120 | ma_hashtbl_update | eloqsql/libmariadb/libmariadb/ma_hashtbl.c | my_bool ma_hashtbl_update(MA_HASHTBL *hash,uchar *record,uchar *old_key,uint old_key_length)
{
uint idx,new_index,new_pos_index,blength,records,empty;
MA_HASHTBL_LINK org_link,*data,*previous,*pos;
data=dynamic_element(&hash->array,0,MA_HASHTBL_LINK*);
blength=hash->blength; records=hash->records;
/* Search after record with key */
idx=hash_mask((*hash->calc_hashnr)(old_key,(old_key_length ?
old_key_length :
hash->key_length)),
blength,records);
new_index=hash_mask(rec_hashnr(hash,record),blength,records);
if (idx == new_index)
return(0); /* Nothing to do (No record check) */
previous=0;
for (;;)
{
if ((pos= data+idx)->data == record)
break;
previous=pos;
if ((idx=pos->next) == NO_RECORD)
return(1); /* Not found in links */
}
hash->current_record= NO_RECORD;
org_link= *pos;
empty=idx;
/* Relink record from current chain */
if (!previous)
{
if (pos->next != NO_RECORD)
{
empty=pos->next;
*pos= data[pos->next];
}
}
else
previous->next=pos->next; /* unlink pos */
/* Move data to correct position */
pos=data+new_index;
new_pos_index=hash_rec_mask(hash,pos,blength,records);
if (new_index != new_pos_index)
{ /* Other record in wrong position */
data[empty] = *pos;
movelink(data,new_index,new_pos_index,empty);
org_link.next=NO_RECORD;
data[new_index]= org_link;
}
else
{ /* Link in chain at right position */
org_link.next=data[new_index].next;
data[empty]=org_link;
data[new_index].next=empty;
}
return(0);
} | O0 | c | ma_hashtbl_update:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl %ecx, -0x24(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x10(%rbp), %rax
movl 0xc(%rax), %eax
movl %eax, -0x34(%rbp)
movq -0x10(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x40(%rax), %rax
movq %rax, -0x78(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x70(%rbp)
cmpl $0x0, -0x24(%rbp)
je 0x1dd5c
movl -0x24(%rbp), %eax
movl %eax, -0x7c(%rbp)
jmp 0x1dd66
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0x7c(%rbp)
movq -0x78(%rbp), %rax
movq -0x70(%rbp), %rdi
movl -0x7c(%rbp), %esi
callq *%rax
movl %eax, %edi
movl -0x34(%rbp), %esi
movl -0x38(%rbp), %edx
callq 0x1d2f0
movl %eax, -0x28(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x1d8d0
movl %eax, %edi
movl -0x34(%rbp), %esi
movl -0x38(%rbp), %edx
callq 0x1d2f0
movl %eax, -0x2c(%rbp)
movl -0x28(%rbp), %eax
cmpl -0x2c(%rbp), %eax
jne 0x1ddb1
movb $0x0, -0x1(%rbp)
jmp 0x1df35
movq $0x0, -0x60(%rbp)
movq -0x58(%rbp), %rax
movl -0x28(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x68(%rbp)
movq 0x8(%rax), %rax
cmpq -0x18(%rbp), %rax
jne 0x1ddd7
jmp 0x1ddf8
movq -0x68(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x68(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x28(%rbp)
cmpl $-0x1, %eax
jne 0x1ddf6
movb $0x1, -0x1(%rbp)
jmp 0x1df35
jmp 0x1ddb9
movq -0x10(%rbp), %rax
movl $0xffffffff, 0x10(%rax) # imm = 0xFFFFFFFF
movq -0x68(%rbp), %rax
movq (%rax), %rcx
movq %rcx, -0x50(%rbp)
movq 0x8(%rax), %rax
movq %rax, -0x48(%rbp)
movl -0x28(%rbp), %eax
movl %eax, -0x3c(%rbp)
cmpq $0x0, -0x60(%rbp)
jne 0x1de5a
movq -0x68(%rbp), %rax
cmpl $-0x1, (%rax)
je 0x1de58
movq -0x68(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x3c(%rbp)
movq -0x68(%rbp), %rax
movq -0x58(%rbp), %rcx
movq -0x68(%rbp), %rdx
movl (%rdx), %edx
shlq $0x4, %rdx
addq %rdx, %rcx
movq (%rcx), %rdx
movq %rdx, (%rax)
movq 0x8(%rcx), %rcx
movq %rcx, 0x8(%rax)
jmp 0x1de66
movq -0x68(%rbp), %rax
movl (%rax), %ecx
movq -0x60(%rbp), %rax
movl %ecx, (%rax)
movq -0x58(%rbp), %rax
movl -0x2c(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x68(%rbp)
movq -0x10(%rbp), %rdi
movq -0x68(%rbp), %rsi
movl -0x34(%rbp), %edx
movl -0x38(%rbp), %ecx
callq 0x1d3c0
movl %eax, -0x30(%rbp)
movl -0x2c(%rbp), %eax
cmpl -0x30(%rbp), %eax
je 0x1deee
movq -0x58(%rbp), %rax
movl -0x3c(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq -0x68(%rbp), %rcx
movq (%rcx), %rdx
movq %rdx, (%rax)
movq 0x8(%rcx), %rcx
movq %rcx, 0x8(%rax)
movq -0x58(%rbp), %rdi
movl -0x2c(%rbp), %esi
movl -0x30(%rbp), %edx
movl -0x3c(%rbp), %ecx
callq 0x1d910
movl $0xffffffff, -0x50(%rbp) # imm = 0xFFFFFFFF
movq -0x58(%rbp), %rax
movl -0x2c(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq -0x50(%rbp), %rcx
movq %rcx, (%rax)
movq -0x48(%rbp), %rcx
movq %rcx, 0x8(%rax)
jmp 0x1df31
movq -0x58(%rbp), %rax
movl -0x2c(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movl (%rax), %eax
movl %eax, -0x50(%rbp)
movq -0x58(%rbp), %rax
movl -0x3c(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq -0x50(%rbp), %rcx
movq %rcx, (%rax)
movq -0x48(%rbp), %rcx
movq %rcx, 0x8(%rax)
movl -0x3c(%rbp), %ecx
movq -0x58(%rbp), %rax
movl -0x2c(%rbp), %edx
shlq $0x4, %rdx
addq %rdx, %rax
movl %ecx, (%rax)
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x80, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| ma_hashtbl_update:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_24], ecx
mov rax, [rbp+var_10]
mov rax, [rax+18h]
mov [rbp+var_58], rax
mov rax, [rbp+var_10]
mov eax, [rax+0Ch]
mov [rbp+var_34], eax
mov rax, [rbp+var_10]
mov eax, [rax+8]
mov [rbp+var_38], eax
mov rax, [rbp+var_10]
mov rax, [rax+40h]
mov [rbp+var_78], rax
mov rax, [rbp+var_20]
mov [rbp+var_70], rax
cmp [rbp+var_24], 0
jz short loc_1DD5C
mov eax, [rbp+var_24]
mov [rbp+var_7C], eax
jmp short loc_1DD66
loc_1DD5C:
mov rax, [rbp+var_10]
mov eax, [rax+4]
mov [rbp+var_7C], eax
loc_1DD66:
mov rax, [rbp+var_78]
mov rdi, [rbp+var_70]
mov esi, [rbp+var_7C]
call rax
mov edi, eax
mov esi, [rbp+var_34]
mov edx, [rbp+var_38]
call hash_mask
mov [rbp+var_28], eax
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call rec_hashnr
mov edi, eax
mov esi, [rbp+var_34]
mov edx, [rbp+var_38]
call hash_mask
mov [rbp+var_2C], eax
mov eax, [rbp+var_28]
cmp eax, [rbp+var_2C]
jnz short loc_1DDB1
mov [rbp+var_1], 0
jmp loc_1DF35
loc_1DDB1:
mov [rbp+var_60], 0
loc_1DDB9:
mov rax, [rbp+var_58]
mov ecx, [rbp+var_28]
shl rcx, 4
add rax, rcx
mov [rbp+var_68], rax
mov rax, [rax+8]
cmp rax, [rbp+var_18]
jnz short loc_1DDD7
jmp short loc_1DDF8
loc_1DDD7:
mov rax, [rbp+var_68]
mov [rbp+var_60], rax
mov rax, [rbp+var_68]
mov eax, [rax]
mov [rbp+var_28], eax
cmp eax, 0FFFFFFFFh
jnz short loc_1DDF6
mov [rbp+var_1], 1
jmp loc_1DF35
loc_1DDF6:
jmp short loc_1DDB9
loc_1DDF8:
mov rax, [rbp+var_10]
mov dword ptr [rax+10h], 0FFFFFFFFh
mov rax, [rbp+var_68]
mov rcx, [rax]
mov [rbp+var_50], rcx
mov rax, [rax+8]
mov [rbp+var_48], rax
mov eax, [rbp+var_28]
mov [rbp+var_3C], eax
cmp [rbp+var_60], 0
jnz short loc_1DE5A
mov rax, [rbp+var_68]
cmp dword ptr [rax], 0FFFFFFFFh
jz short loc_1DE58
mov rax, [rbp+var_68]
mov eax, [rax]
mov [rbp+var_3C], eax
mov rax, [rbp+var_68]
mov rcx, [rbp+var_58]
mov rdx, [rbp+var_68]
mov edx, [rdx]
shl rdx, 4
add rcx, rdx
mov rdx, [rcx]
mov [rax], rdx
mov rcx, [rcx+8]
mov [rax+8], rcx
loc_1DE58:
jmp short loc_1DE66
loc_1DE5A:
mov rax, [rbp+var_68]
mov ecx, [rax]
mov rax, [rbp+var_60]
mov [rax], ecx
loc_1DE66:
mov rax, [rbp+var_58]
mov ecx, [rbp+var_2C]
shl rcx, 4
add rax, rcx
mov [rbp+var_68], rax
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_68]
mov edx, [rbp+var_34]
mov ecx, [rbp+var_38]
call hash_rec_mask
mov [rbp+var_30], eax
mov eax, [rbp+var_2C]
cmp eax, [rbp+var_30]
jz short loc_1DEEE
mov rax, [rbp+var_58]
mov ecx, [rbp+var_3C]
shl rcx, 4
add rax, rcx
mov rcx, [rbp+var_68]
mov rdx, [rcx]
mov [rax], rdx
mov rcx, [rcx+8]
mov [rax+8], rcx
mov rdi, [rbp+var_58]
mov esi, [rbp+var_2C]
mov edx, [rbp+var_30]
mov ecx, [rbp+var_3C]
call movelink
mov dword ptr [rbp+var_50], 0FFFFFFFFh
mov rax, [rbp+var_58]
mov ecx, [rbp+var_2C]
shl rcx, 4
add rax, rcx
mov rcx, [rbp+var_50]
mov [rax], rcx
mov rcx, [rbp+var_48]
mov [rax+8], rcx
jmp short loc_1DF31
loc_1DEEE:
mov rax, [rbp+var_58]
mov ecx, [rbp+var_2C]
shl rcx, 4
add rax, rcx
mov eax, [rax]
mov dword ptr [rbp+var_50], eax
mov rax, [rbp+var_58]
mov ecx, [rbp+var_3C]
shl rcx, 4
add rax, rcx
mov rcx, [rbp+var_50]
mov [rax], rcx
mov rcx, [rbp+var_48]
mov [rax+8], rcx
mov ecx, [rbp+var_3C]
mov rax, [rbp+var_58]
mov edx, [rbp+var_2C]
shl rdx, 4
add rax, rdx
mov [rax], ecx
loc_1DF31:
mov [rbp+var_1], 0
loc_1DF35:
mov al, [rbp+var_1]
add rsp, 80h
pop rbp
retn
| char ma_hashtbl_update(long long a1, long long a2, long long a3, unsigned int a4)
{
unsigned int v4; // eax
unsigned int v5; // eax
long long v6; // rdx
_QWORD *v7; // rax
_QWORD *v8; // rax
_QWORD *v9; // rax
unsigned int v11; // [rsp+4h] [rbp-7Ch]
unsigned int *v12; // [rsp+18h] [rbp-68h]
_QWORD *v13; // [rsp+18h] [rbp-68h]
_DWORD *v14; // [rsp+20h] [rbp-60h]
long long v15; // [rsp+28h] [rbp-58h]
long long v16; // [rsp+30h] [rbp-50h]
long long v17; // [rsp+38h] [rbp-48h]
unsigned int v18; // [rsp+44h] [rbp-3Ch]
unsigned int v19; // [rsp+48h] [rbp-38h]
unsigned int v20; // [rsp+4Ch] [rbp-34h]
unsigned int v21; // [rsp+50h] [rbp-30h]
unsigned int v22; // [rsp+54h] [rbp-2Ch]
unsigned int v23; // [rsp+58h] [rbp-28h]
v15 = *(_QWORD *)(a1 + 24);
v20 = *(_DWORD *)(a1 + 12);
v19 = *(_DWORD *)(a1 + 8);
if ( a4 )
v11 = a4;
else
v11 = *(_DWORD *)(a1 + 4);
v4 = (*(long long ( **)(long long, _QWORD))(a1 + 64))(a3, v11);
v23 = hash_mask(v4, v20, v19);
v5 = rec_hashnr(a1, a2);
v22 = hash_mask(v5, v20, v19);
if ( v23 == v22 )
return 0;
v14 = 0LL;
while ( 1 )
{
v12 = (unsigned int *)(16LL * v23 + v15);
if ( *((_QWORD *)v12 + 1) == a2 )
break;
v14 = (_DWORD *)(16LL * v23 + v15);
v23 = *v12;
if ( *v12 == -1 )
return 1;
}
*(_DWORD *)(a1 + 16) = -1;
v16 = *(_QWORD *)v12;
v17 = *((_QWORD *)v12 + 1);
v18 = v23;
if ( v14 )
{
*v14 = *v12;
}
else if ( *v12 != -1 )
{
v18 = *v12;
v6 = 16LL * *v12;
*(_QWORD *)v12 = *(_QWORD *)(v6 + v15);
*((_QWORD *)v12 + 1) = *(_QWORD *)(v6 + v15 + 8);
}
v13 = (_QWORD *)(16LL * v22 + v15);
v21 = hash_rec_mask(a1, (long long)v13, v20, v19);
if ( v22 == v21 )
{
LODWORD(v16) = *(_DWORD *)(16LL * v22 + v15);
v9 = (_QWORD *)(16LL * v18 + v15);
*v9 = v16;
v9[1] = v17;
*(_DWORD *)(16LL * v22 + v15) = v18;
}
else
{
v7 = (_QWORD *)(16LL * v18 + v15);
*v7 = *v13;
v7[1] = v13[1];
movelink(v15, v22, v21, v18);
LODWORD(v16) = -1;
v8 = (_QWORD *)(16LL * v22 + v15);
*v8 = v16;
v8[1] = v17;
}
return 0;
}
| ma_hashtbl_update:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x24],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0x58],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0xc]
MOV dword ptr [RBP + -0x34],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x8]
MOV dword ptr [RBP + -0x38],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x40]
MOV qword ptr [RBP + -0x78],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x70],RAX
CMP dword ptr [RBP + -0x24],0x0
JZ 0x0011dd5c
MOV EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x7c],EAX
JMP 0x0011dd66
LAB_0011dd5c:
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x4]
MOV dword ptr [RBP + -0x7c],EAX
LAB_0011dd66:
MOV RAX,qword ptr [RBP + -0x78]
MOV RDI,qword ptr [RBP + -0x70]
MOV ESI,dword ptr [RBP + -0x7c]
CALL RAX
MOV EDI,EAX
MOV ESI,dword ptr [RBP + -0x34]
MOV EDX,dword ptr [RBP + -0x38]
CALL 0x0011d2f0
MOV dword ptr [RBP + -0x28],EAX
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x0011d8d0
MOV EDI,EAX
MOV ESI,dword ptr [RBP + -0x34]
MOV EDX,dword ptr [RBP + -0x38]
CALL 0x0011d2f0
MOV dword ptr [RBP + -0x2c],EAX
MOV EAX,dword ptr [RBP + -0x28]
CMP EAX,dword ptr [RBP + -0x2c]
JNZ 0x0011ddb1
MOV byte ptr [RBP + -0x1],0x0
JMP 0x0011df35
LAB_0011ddb1:
MOV qword ptr [RBP + -0x60],0x0
LAB_0011ddb9:
MOV RAX,qword ptr [RBP + -0x58]
MOV ECX,dword ptr [RBP + -0x28]
SHL RCX,0x4
ADD RAX,RCX
MOV qword ptr [RBP + -0x68],RAX
MOV RAX,qword ptr [RAX + 0x8]
CMP RAX,qword ptr [RBP + -0x18]
JNZ 0x0011ddd7
JMP 0x0011ddf8
LAB_0011ddd7:
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x68]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x28],EAX
CMP EAX,-0x1
JNZ 0x0011ddf6
MOV byte ptr [RBP + -0x1],0x1
JMP 0x0011df35
LAB_0011ddf6:
JMP 0x0011ddb9
LAB_0011ddf8:
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x10],0xffffffff
MOV RAX,qword ptr [RBP + -0x68]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RBP + -0x50],RCX
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x48],RAX
MOV EAX,dword ptr [RBP + -0x28]
MOV dword ptr [RBP + -0x3c],EAX
CMP qword ptr [RBP + -0x60],0x0
JNZ 0x0011de5a
MOV RAX,qword ptr [RBP + -0x68]
CMP dword ptr [RAX],-0x1
JZ 0x0011de58
MOV RAX,qword ptr [RBP + -0x68]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x3c],EAX
MOV RAX,qword ptr [RBP + -0x68]
MOV RCX,qword ptr [RBP + -0x58]
MOV RDX,qword ptr [RBP + -0x68]
MOV EDX,dword ptr [RDX]
SHL RDX,0x4
ADD RCX,RDX
MOV RDX,qword ptr [RCX]
MOV qword ptr [RAX],RDX
MOV RCX,qword ptr [RCX + 0x8]
MOV qword ptr [RAX + 0x8],RCX
LAB_0011de58:
JMP 0x0011de66
LAB_0011de5a:
MOV RAX,qword ptr [RBP + -0x68]
MOV ECX,dword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x60]
MOV dword ptr [RAX],ECX
LAB_0011de66:
MOV RAX,qword ptr [RBP + -0x58]
MOV ECX,dword ptr [RBP + -0x2c]
SHL RCX,0x4
ADD RAX,RCX
MOV qword ptr [RBP + -0x68],RAX
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x68]
MOV EDX,dword ptr [RBP + -0x34]
MOV ECX,dword ptr [RBP + -0x38]
CALL 0x0011d3c0
MOV dword ptr [RBP + -0x30],EAX
MOV EAX,dword ptr [RBP + -0x2c]
CMP EAX,dword ptr [RBP + -0x30]
JZ 0x0011deee
MOV RAX,qword ptr [RBP + -0x58]
MOV ECX,dword ptr [RBP + -0x3c]
SHL RCX,0x4
ADD RAX,RCX
MOV RCX,qword ptr [RBP + -0x68]
MOV RDX,qword ptr [RCX]
MOV qword ptr [RAX],RDX
MOV RCX,qword ptr [RCX + 0x8]
MOV qword ptr [RAX + 0x8],RCX
MOV RDI,qword ptr [RBP + -0x58]
MOV ESI,dword ptr [RBP + -0x2c]
MOV EDX,dword ptr [RBP + -0x30]
MOV ECX,dword ptr [RBP + -0x3c]
CALL 0x0011d910
MOV dword ptr [RBP + -0x50],0xffffffff
MOV RAX,qword ptr [RBP + -0x58]
MOV ECX,dword ptr [RBP + -0x2c]
SHL RCX,0x4
ADD RAX,RCX
MOV RCX,qword ptr [RBP + -0x50]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x48]
MOV qword ptr [RAX + 0x8],RCX
JMP 0x0011df31
LAB_0011deee:
MOV RAX,qword ptr [RBP + -0x58]
MOV ECX,dword ptr [RBP + -0x2c]
SHL RCX,0x4
ADD RAX,RCX
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x50],EAX
MOV RAX,qword ptr [RBP + -0x58]
MOV ECX,dword ptr [RBP + -0x3c]
SHL RCX,0x4
ADD RAX,RCX
MOV RCX,qword ptr [RBP + -0x50]
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RBP + -0x48]
MOV qword ptr [RAX + 0x8],RCX
MOV ECX,dword ptr [RBP + -0x3c]
MOV RAX,qword ptr [RBP + -0x58]
MOV EDX,dword ptr [RBP + -0x2c]
SHL RDX,0x4
ADD RAX,RDX
MOV dword ptr [RAX],ECX
LAB_0011df31:
MOV byte ptr [RBP + -0x1],0x0
LAB_0011df35:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x80
POP RBP
RET
|
int8 ma_hashtbl_update(long param_1,long param_2,int8 param_3,int param_4)
{
int4 uVar1;
int4 uVar2;
long lVar3;
int8 uVar4;
int8 uVar5;
int4 uVar6;
uint uVar7;
uint uVar8;
uint *puVar9;
int8 *puVar10;
uint *puVar11;
int8 *puVar12;
int local_84;
uint *local_68;
int8 local_58;
uint local_44;
uint local_30;
int1 local_9;
lVar3 = *(long *)(param_1 + 0x18);
uVar1 = *(int4 *)(param_1 + 0xc);
uVar2 = *(int4 *)(param_1 + 8);
local_84 = param_4;
if (param_4 == 0) {
local_84 = *(int *)(param_1 + 4);
}
uVar6 = (**(code **)(param_1 + 0x40))(param_3,local_84);
local_30 = hash_mask(uVar6,uVar1,uVar2);
uVar6 = rec_hashnr(param_1,param_2);
uVar7 = hash_mask(uVar6,uVar1,uVar2);
puVar11 = (uint *)(ulong)local_30;
if (local_30 == uVar7) {
local_9 = 0;
}
else {
local_68 = (uint *)0x0;
do {
puVar9 = (uint *)(lVar3 + (ulong)local_30 * 0x10);
if (*(long *)(puVar9 + 2) == param_2) {
*(int4 *)(param_1 + 0x10) = 0xffffffff;
uVar4 = *(int8 *)puVar9;
uVar5 = *(int8 *)(puVar9 + 2);
local_44 = local_30;
if (local_68 == (uint *)0x0) {
if (*puVar9 != 0xffffffff) {
local_44 = *puVar9;
puVar12 = (int8 *)(lVar3 + (ulong)*puVar9 * 0x10);
*(int8 *)puVar9 = *puVar12;
*(int8 *)(puVar9 + 2) = puVar12[1];
}
}
else {
*local_68 = *puVar9;
}
puVar12 = (int8 *)(lVar3 + (ulong)uVar7 * 0x10);
uVar8 = hash_rec_mask(param_1,puVar12,uVar1,uVar2);
local_58._4_4_ = (int4)((ulong)uVar4 >> 0x20);
if (uVar7 == uVar8) {
local_58 = CONCAT44(local_58._4_4_,*(int4 *)(lVar3 + (ulong)uVar7 * 0x10));
puVar12 = (int8 *)(lVar3 + (ulong)local_44 * 0x10);
*puVar12 = local_58;
puVar12[1] = uVar5;
puVar11 = (uint *)(lVar3 + (ulong)uVar7 * 0x10);
*puVar11 = local_44;
}
else {
puVar10 = (int8 *)(lVar3 + (ulong)local_44 * 0x10);
*puVar10 = *puVar12;
puVar10[1] = puVar12[1];
movelink(lVar3,uVar7,uVar8,local_44);
local_58 = CONCAT44(local_58._4_4_,0xffffffff);
puVar11 = (uint *)(lVar3 + (ulong)uVar7 * 0x10);
*(int8 *)puVar11 = local_58;
*(int8 *)(puVar11 + 2) = uVar5;
}
local_9 = 0;
goto LAB_0011df35;
}
local_30 = *puVar9;
puVar11 = (uint *)(ulong)local_30;
local_68 = puVar9;
} while (local_30 != 0xffffffff);
local_9 = 1;
}
LAB_0011df35:
return CONCAT71((int7)((ulong)puVar11 >> 8),local_9);
}
| |
22,121 | minja::Parser::parseMathPow() | monkey531[P]llama/common/minja.hpp | std::shared_ptr<Expression> parseMathPow() {
auto left = parseMathPlusMinus();
if (!left) throw std::runtime_error("Expected left side of 'math pow' expression");
while (!consumeToken("**").empty()) {
auto right = parseMathPlusMinus();
if (!right) throw std::runtime_error("Expected right side of 'math pow' expression");
left = std::make_shared<BinaryOpExpr>(get_location(), std::move(left), std::move(right), BinaryOpExpr::Op::MulMul);
}
return left;
} | O1 | cpp | minja::Parser::parseMathPow():
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x88c3a
cmpq $0x0, (%rbx)
je 0x88b8c
leaq 0x30(%rsp), %rbp
leaq 0x20(%rsp), %r13
leaq 0xa4f84(%rip), %rax # 0x12d988
addq $0x10, %rax
movq %rax, 0x40(%rsp)
movq %rbp, 0x20(%rsp)
movq %r13, %rdi
leaq 0x6a469(%rip), %rsi # 0xf2e85
leaq 0x6a464(%rip), %rdx # 0xf2e87
callq 0x22ba6
movq %rsp, %rdi
movq %r14, %rsi
movq %r13, %rdx
movl $0x1, %ecx
callq 0x84e52
movq (%rsp), %rdi
movq 0x8(%rsp), %r15
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x88a5b
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1b8f0
movq 0x20(%rsp), %rdi
cmpq %rbp, %rdi
je 0x88a72
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1b8f0
testq %r15, %r15
je 0x88b46
movq %r13, %rdi
movq %r14, %rsi
callq 0x88c3a
cmpq $0x0, 0x20(%rsp)
je 0x88b58
movq (%r14), %rax
movq %rax, (%rsp)
movq 0x8(%r14), %rax
movq %rax, 0x8(%rsp)
testq %rax, %rax
je 0x88abc
movq 0xa64da(%rip), %rcx # 0x12ef88
cmpb $0x0, (%rcx)
je 0x88ab8
incl 0x8(%rax)
jmp 0x88abc
lock
incl 0x8(%rax)
movq 0x20(%r14), %rax
subq 0x10(%r14), %rax
movq %rax, 0x10(%rsp)
movl $0x58, %edi
callq 0x1b8c0
movq %rax, %r15
movabsq $0x100000001, %rax # imm = 0x100000001
movq %rax, 0x8(%r15)
movq 0x40(%rsp), %rax
movq %rax, (%r15)
movq %r15, %r12
addq $0x10, %r12
movq %r12, %rdi
movq %rsp, %rsi
movq %rbx, %rdx
movq %r13, %rcx
movl $0x4, %r8d
callq 0x96ba2
movq %r12, (%rbx)
movq 0x8(%rbx), %rdi
movq %r15, 0x8(%rbx)
testq %rdi, %rdi
je 0x88b1f
callq 0x6dc18
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x88b2e
callq 0x6dc18
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x88a0d
callq 0x6dc18
jmp 0x88a0d
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x1b460
movq %rax, %r15
leaq 0x6a31c(%rip), %rsi # 0xf2e88
movq %rax, %rdi
callq 0x1b340
movq 0xa6475(%rip), %rsi # 0x12eff0
movq 0xa63de(%rip), %rdx # 0x12ef60
movq %r15, %rdi
callq 0x1bf30
jmp 0x88bbe
movl $0x10, %edi
callq 0x1b460
movq %rax, %r15
leaq 0x6a2b9(%rip), %rsi # 0xf2e59
movq %rax, %rdi
callq 0x1b340
movq 0xa6441(%rip), %rsi # 0x12eff0
movq 0xa63aa(%rip), %rdx # 0x12ef60
movq %r15, %rdi
callq 0x1bf30
jmp 0x88c04
movq %rax, %r14
movq %r15, %rdi
callq 0x1b690
jmp 0x88c23
movq %rax, %r14
jmp 0x88bf3
movq %rax, %r14
movq %r15, %rdi
callq 0x1b690
jmp 0x88bf3
jmp 0x88c04
movq %rax, %r14
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x88bf3
callq 0x6dc18
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x88c23
callq 0x6dc18
jmp 0x88c23
movq %rax, %r14
jmp 0x88c23
movq %rax, %r14
movq 0x20(%rsp), %rdi
cmpq %rbp, %rdi
je 0x88c23
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1b8f0
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x88c31
callq 0x6dc18
movq %r14, %rdi
callq 0x1bfd0
nop
| _ZN5minja6Parser12parseMathPowEv:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 48h
mov r14, rsi
mov rbx, rdi
call _ZN5minja6Parser18parseMathPlusMinusEv; minja::Parser::parseMathPlusMinus(void)
cmp qword ptr [rbx], 0
jz loc_88B8C
lea rbp, [rsp+78h+var_48]
lea r13, [rsp+78h+var_58]
lea rax, _ZTVSt23_Sp_counted_ptr_inplaceIN5minja12BinaryOpExprESaIS1_ELN9__gnu_cxx12_Lock_policyE2EE; `vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2>
add rax, 10h
mov [rsp+78h+var_38], rax
loc_88A0D:
mov [rsp+78h+var_58], rbp
mov rdi, r13
lea rsi, asc_F2E85; "**"
lea rdx, asc_F2E85+2; ""
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rdi, rsp
mov rsi, r14
mov rdx, r13
mov ecx, 1
call _ZN5minja6Parser12consumeTokenERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS_13SpaceHandlingE; minja::Parser::consumeToken(std::string const&,minja::SpaceHandling)
mov rdi, [rsp+78h+var_78]; void *
mov r15, [rsp+78h+var_70]
lea rax, [rsp+78h+var_68]
cmp rdi, rax
jz short loc_88A5B
mov rsi, [rsp+78h+var_68]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_88A5B:
mov rdi, [rsp+78h+var_58]; void *
cmp rdi, rbp
jz short loc_88A72
mov rsi, [rsp+78h+var_48]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_88A72:
test r15, r15
jz loc_88B46
mov rdi, r13; this
mov rsi, r14
call _ZN5minja6Parser18parseMathPlusMinusEv; minja::Parser::parseMathPlusMinus(void)
cmp [rsp+78h+var_58], 0
jz loc_88B58
mov rax, [r14]
mov [rsp+78h+var_78], rax
mov rax, [r14+8]
mov [rsp+78h+var_70], rax
test rax, rax
jz short loc_88ABC
mov rcx, cs:__libc_single_threaded_ptr
cmp byte ptr [rcx], 0
jz short loc_88AB8
inc dword ptr [rax+8]
jmp short loc_88ABC
loc_88AB8:
lock inc dword ptr [rax+8]
loc_88ABC:
mov rax, [r14+20h]
sub rax, [r14+10h]
mov [rsp+78h+var_68], rax
mov edi, 58h ; 'X'; unsigned __int64
call __Znwm; operator new(ulong)
mov r15, rax
mov rax, 100000001h
mov [r15+8], rax
mov rax, [rsp+78h+var_38]
mov [r15], rax
mov r12, r15
add r12, 10h
mov rdi, r12
mov rsi, rsp
mov rdx, rbx
mov rcx, r13
mov r8d, 4
call _ZN5minja12BinaryOpExprC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEES7_NS0_2OpE; minja::BinaryOpExpr::BinaryOpExpr(minja::Location const&,std::shared_ptr<minja::Expression> &&,std::shared_ptr<minja::Expression> &,minja::BinaryOpExpr::Op)
mov [rbx], r12
mov rdi, [rbx+8]
mov [rbx+8], r15
test rdi, rdi
jz short loc_88B1F
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_88B1F:
mov rdi, [rsp+78h+var_70]
test rdi, rdi
jz short loc_88B2E
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_88B2E:
mov rdi, [rsp+78h+var_50]
test rdi, rdi
jz loc_88A0D
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
jmp loc_88A0D
loc_88B46:
mov rax, rbx
add rsp, 48h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_88B58:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedRightS_3; "Expected right side of 'math pow' expre"...
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
jmp short loc_88BBE
loc_88B8C:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r15, rax
lea rsi, aExpectedLeftSi_3; "Expected left side of 'math pow' expres"...
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r15; void *
call ___cxa_throw
loc_88BBE:
jmp short loc_88C04
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_88C23
mov r14, rax
jmp short loc_88BF3
mov r14, rax
mov rdi, r15; void *
call ___cxa_free_exception
jmp short loc_88BF3
jmp short loc_88C04
mov r14, rax
mov rdi, [rsp+78h+var_70]
test rdi, rdi
jz short loc_88BF3
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_88BF3:
mov rdi, [rsp+78h+var_50]
test rdi, rdi
jz short loc_88C23
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
jmp short loc_88C23
loc_88C04:
mov r14, rax
jmp short loc_88C23
mov r14, rax
mov rdi, [rsp+78h+var_58]; void *
cmp rdi, rbp
jz short loc_88C23
mov rsi, [rsp+78h+var_48]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_88C23:
mov rdi, [rbx+8]
test rdi, rdi
jz short loc_88C31
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_88C31:
mov rdi, r14
call __Unwind_Resume
| minja::Parser * minja::Parser::parseMathPow(volatile signed __int32 **this, long long a2)
{
volatile signed __int32 *v3; // r15
volatile signed __int32 *v4; // rax
long long **v5; // r15
volatile signed __int32 *v6; // rdi
std::runtime_error *v8; // r15
std::runtime_error *exception; // r15
void *v10; // [rsp+0h] [rbp-78h] BYREF
volatile signed __int32 *v11; // [rsp+8h] [rbp-70h]
long long v12; // [rsp+10h] [rbp-68h] BYREF
void *v13; // [rsp+20h] [rbp-58h] BYREF
volatile signed __int32 *v14; // [rsp+28h] [rbp-50h]
_QWORD v15[2]; // [rsp+30h] [rbp-48h] BYREF
long long *v16; // [rsp+40h] [rbp-38h]
minja::Parser::parseMathPlusMinus((minja::Parser *)this);
if ( !*this )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "Expected left side of 'math pow' expression");
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
v16 = &`vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2>
+ 2;
while ( 1 )
{
v13 = v15;
std::string::_M_construct<char const*>(&v13, "**", (long long)"");
minja::Parser::consumeToken(&v10, a2, (_BYTE **)&v13, 1u);
v3 = v11;
if ( v10 != &v12 )
operator delete(v10, v12 + 1);
if ( v13 != v15 )
operator delete(v13, v15[0] + 1LL);
if ( !v3 )
break;
minja::Parser::parseMathPlusMinus((minja::Parser *)&v13);
if ( !v13 )
{
v8 = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(v8, "Expected right side of 'math pow' expression");
__cxa_throw(
v8,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
v10 = *(void **)a2;
v4 = *(volatile signed __int32 **)(a2 + 8);
v11 = v4;
if ( v4 )
{
if ( _libc_single_threaded )
++*((_DWORD *)v4 + 2);
else
_InterlockedIncrement(v4 + 2);
}
v12 = *(_QWORD *)(a2 + 32) - *(_QWORD *)(a2 + 16);
v5 = (long long **)operator new(0x58uLL);
v5[1] = (long long *)0x100000001LL;
*v5 = v16;
minja::BinaryOpExpr::BinaryOpExpr(v5 + 2, &v10, this, &v13, 4LL);
*this = (volatile signed __int32 *)(v5 + 2);
v6 = this[1];
this[1] = (volatile signed __int32 *)v5;
if ( v6 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v6);
if ( v11 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v11);
if ( v14 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v14);
}
return (minja::Parser *)this;
}
| parseMathPow:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV R14,RSI
MOV RBX,RDI
CALL 0x00188c3a
CMP qword ptr [RBX],0x0
JZ 0x00188b8c
LEA RBP,[RSP + 0x30]
LEA R13,[RSP + 0x20]
LEA RAX,[0x22d988]
ADD RAX,0x10
MOV qword ptr [RSP + 0x40],RAX
LAB_00188a0d:
MOV qword ptr [RSP + 0x20],RBP
LAB_00188a12:
MOV RDI,R13
LEA RSI,[0x1f2e85]
LEA RDX,[0x1f2e87]
CALL 0x00122ba6
LAB_00188a28:
MOV RDI,RSP
MOV RSI,R14
MOV RDX,R13
MOV ECX,0x1
CALL 0x00184e52
MOV RDI,qword ptr [RSP]
MOV R15,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x10]
CMP RDI,RAX
JZ 0x00188a5b
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0011b8f0
LAB_00188a5b:
MOV RDI,qword ptr [RSP + 0x20]
CMP RDI,RBP
JZ 0x00188a72
MOV RSI,qword ptr [RSP + 0x30]
INC RSI
CALL 0x0011b8f0
LAB_00188a72:
TEST R15,R15
JZ 0x00188b46
LAB_00188a7b:
MOV RDI,R13
MOV RSI,R14
CALL 0x00188c3a
CMP qword ptr [RSP + 0x20],0x0
JZ 0x00188b58
MOV RAX,qword ptr [R14]
MOV qword ptr [RSP],RAX
MOV RAX,qword ptr [R14 + 0x8]
MOV qword ptr [RSP + 0x8],RAX
TEST RAX,RAX
JZ 0x00188abc
MOV RCX,qword ptr [0x0022ef88]
CMP byte ptr [RCX],0x0
JZ 0x00188ab8
INC dword ptr [RAX + 0x8]
JMP 0x00188abc
LAB_00188ab8:
INC.LOCK dword ptr [RAX + 0x8]
LAB_00188abc:
MOV RAX,qword ptr [R14 + 0x20]
SUB RAX,qword ptr [R14 + 0x10]
MOV qword ptr [RSP + 0x10],RAX
LAB_00188ac9:
MOV EDI,0x58
CALL 0x0011b8c0
LAB_00188ad3:
MOV R15,RAX
MOV RAX,0x100000001
MOV qword ptr [R15 + 0x8],RAX
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [R15],RAX
MOV R12,R15
ADD R12,0x10
MOV RDI,R12
MOV RSI,RSP
MOV RDX,RBX
MOV RCX,R13
MOV R8D,0x4
CALL 0x00196ba2
MOV qword ptr [RBX],R12
MOV RDI,qword ptr [RBX + 0x8]
MOV qword ptr [RBX + 0x8],R15
TEST RDI,RDI
JZ 0x00188b1f
CALL 0x0016dc18
LAB_00188b1f:
MOV RDI,qword ptr [RSP + 0x8]
TEST RDI,RDI
JZ 0x00188b2e
CALL 0x0016dc18
LAB_00188b2e:
MOV RDI,qword ptr [RSP + 0x28]
TEST RDI,RDI
JZ 0x00188a0d
CALL 0x0016dc18
JMP 0x00188a0d
LAB_00188b46:
MOV RAX,RBX
ADD RSP,0x48
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00188b58:
MOV EDI,0x10
CALL 0x0011b460
MOV R15,RAX
LAB_00188b65:
LEA RSI,[0x1f2e88]
MOV RDI,RAX
CALL 0x0011b340
LAB_00188b74:
MOV RSI,qword ptr [0x0022eff0]
MOV RDX,qword ptr [0x0022ef60]
MOV RDI,R15
CALL 0x0011bf30
LAB_00188b8c:
MOV EDI,0x10
CALL 0x0011b460
MOV R15,RAX
LAB_00188b99:
LEA RSI,[0x1f2e59]
MOV RDI,RAX
CALL 0x0011b340
LAB_00188ba8:
MOV RSI,qword ptr [0x0022eff0]
MOV RDX,qword ptr [0x0022ef60]
MOV RDI,R15
CALL 0x0011bf30
|
/* minja::Parser::parseMathPow() */
void minja::Parser::parseMathPow(void)
{
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Var1;
int8 *puVar2;
runtime_error *prVar3;
int8 *in_RSI;
long *in_RDI;
long *local_78;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_70;
long local_68 [2];
long *local_58;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_50;
long local_48 [2];
int **local_38;
parseMathPlusMinus();
if (*in_RDI == 0) {
prVar3 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00188b99 to 00188ba7 has its CatchHandler @ 00188bc0 */
std::runtime_error::runtime_error(prVar3,"Expected left side of \'math pow\' expression");
/* try { // try from 00188ba8 to 00188bbd has its CatchHandler @ 00188bbe */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar3,PTR_typeinfo_0022eff0,PTR__runtime_error_0022ef60);
}
local_38 = &PTR___Sp_counted_ptr_inplace_0022d998;
while( true ) {
local_58 = local_48;
/* try { // try from 00188a12 to 00188a27 has its CatchHandler @ 00188c04 */
std::__cxx11::string::_M_construct<char_const*>(&local_58,&DAT_001f2e85,&DAT_001f2e87);
/* try { // try from 00188a28 to 00188a3a has its CatchHandler @ 00188c09 */
consumeToken(&local_78);
p_Var1 = local_70;
if (local_78 != local_68) {
operator_delete(local_78,local_68[0] + 1);
}
if (local_58 != local_48) {
operator_delete(local_58,local_48[0] + 1);
}
if (p_Var1 == (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) break;
/* try { // try from 00188a7b to 00188a85 has its CatchHandler @ 00188bdf */
parseMathPlusMinus();
if (local_58 == (long *)0x0) {
prVar3 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00188b65 to 00188b73 has its CatchHandler @ 00188bd2 */
std::runtime_error::runtime_error(prVar3,"Expected right side of \'math pow\' expression");
/* try { // try from 00188b74 to 00188b89 has its CatchHandler @ 00188bcd */
/* WARNING: Subroutine does not return */
__cxa_throw(prVar3,PTR_typeinfo_0022eff0,PTR__runtime_error_0022ef60);
}
local_78 = (long *)*in_RSI;
local_70 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RSI[1];
if (local_70 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
if (*PTR___libc_single_threaded_0022ef88 == '\0') {
LOCK();
*(int *)(local_70 + 8) = *(int *)(local_70 + 8) + 1;
UNLOCK();
}
else {
*(int *)(local_70 + 8) = *(int *)(local_70 + 8) + 1;
}
}
local_68[0] = in_RSI[4] - in_RSI[2];
/* try { // try from 00188ac9 to 00188ad2 has its CatchHandler @ 00188be1 */
puVar2 = (int8 *)operator_new(0x58);
puVar2[1] = 0x100000001;
*puVar2 = local_38;
BinaryOpExpr::BinaryOpExpr((BinaryOpExpr *)(puVar2 + 2),&local_78);
*in_RDI = (long)(puVar2 + 2);
p_Var1 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RDI[1];
in_RDI[1] = (long)puVar2;
if (p_Var1 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Var1);
}
if (local_70 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_70);
}
if (local_50 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_50);
}
}
return;
}
| |
22,122 | stbi_info_from_memory | llama.cpp/examples/llava/../../common/stb_image.h | STBIDEF int stbi_info_from_memory(stbi_uc const *buffer, int len, int *x, int *y, int *comp)
{
stbi__context s;
stbi__start_mem(&s,buffer,len);
return stbi__info_main(&s,x,y,comp);
} | O3 | c | stbi_info_from_memory:
subq $0xe8, %rsp
leaq 0x8(%rsp), %rax
movq $0x0, 0x10(%rax)
xorl %r9d, %r9d
movl %r9d, 0x30(%rax)
movl %r9d, 0xb8(%rax)
movq %rdi, 0xd0(%rax)
movq %rdi, 0xc0(%rax)
movslq %esi, %rsi
addq %rdi, %rsi
movq %rsi, 0xd8(%rax)
movq %rsi, 0xc8(%rax)
movq %rax, %rdi
movq %rdx, %rsi
movq %rcx, %rdx
movq %r8, %rcx
callq 0x1a5bd
addq $0xe8, %rsp
retq
| stbi_info_from_memory:
sub rsp, 0E8h
lea rax, [rsp+0E8h+var_E0]
mov qword ptr [rax+10h], 0
xor r9d, r9d
mov [rax+30h], r9d
mov [rax+0B8h], r9d
mov [rax+0D0h], rdi
mov [rax+0C0h], rdi
movsxd rsi, esi
add rsi, rdi
mov [rax+0D8h], rsi
mov [rax+0C8h], rsi
mov rdi, rax
mov rsi, rdx
mov rdx, rcx
mov rcx, r8
call _ZL15stbi__info_mainP13stbi__contextPiS1_S1_; stbi__info_main(stbi__context *,int *,int *,int *)
add rsp, 0E8h
retn
| long long stbi_info_from_memory(long long a1, int a2, _DWORD *a3, _DWORD *a4, _DWORD *a5)
{
_BYTE v6[16]; // [rsp+8h] [rbp-E0h] BYREF
long long v7; // [rsp+18h] [rbp-D0h]
int v8; // [rsp+38h] [rbp-B0h]
int v9; // [rsp+C0h] [rbp-28h]
long long v10; // [rsp+C8h] [rbp-20h]
long long v11; // [rsp+D0h] [rbp-18h]
long long v12; // [rsp+D8h] [rbp-10h]
long long v13; // [rsp+E0h] [rbp-8h]
v7 = 0LL;
v8 = 0;
v9 = 0;
v12 = a1;
v10 = a1;
v13 = a1 + a2;
v11 = v13;
return stbi__info_main((long long)v6, a3, a4, a5);
}
| stbi_info_from_memory:
SUB RSP,0xe8
LEA RAX,[RSP + 0x8]
MOV qword ptr [RAX + 0x10],0x0
XOR R9D,R9D
MOV dword ptr [RAX + 0x30],R9D
MOV dword ptr [RAX + 0xb8],R9D
MOV qword ptr [RAX + 0xd0],RDI
MOV qword ptr [RAX + 0xc0],RDI
MOVSXD RSI,ESI
ADD RSI,RDI
MOV qword ptr [RAX + 0xd8],RSI
MOV qword ptr [RAX + 0xc8],RSI
MOV RDI,RAX
MOV RSI,RDX
MOV RDX,RCX
MOV RCX,R8
CALL 0x0011a5bd
ADD RSP,0xe8
RET
|
void stbi_info_from_memory(long param_1,int param_2,int *param_3,int *param_4,int *param_5)
{
stbi__context local_e0 [16];
int8 local_d0;
int4 local_b0;
int4 local_28;
long local_20;
long local_18;
long local_10;
long local_8;
local_d0 = 0;
local_b0 = 0;
local_28 = 0;
local_18 = param_2 + param_1;
local_20 = param_1;
local_10 = param_1;
local_8 = local_18;
stbi__info_main(local_e0,param_3,param_4,param_5);
return;
}
| |
22,123 | _gnu_cxx::__normal_iterator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>*, std::vector<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>> nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::find<char const (&) [3], 0>(char const (&) [3]) | monkey531[P]llama/common/json.hpp | iterator find(KeyType && key) // NOLINT(cppcoreguidelines-missing-std-forward)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return it;
}
}
return Container::end();
} | O0 | cpp | _gnu_cxx::__normal_iterator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>*, std::vector<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>> nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::find<char const (&) [3], 0>(char const (&) [3]):
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq 0x28(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0xb4be0
movq %rax, 0x30(%rsp)
movq 0x10(%rsp), %rdi
callq 0xb4c10
movq %rax, 0x18(%rsp)
leaq 0x30(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0xb4c40
testb $0x1, %al
jne 0x16c716
jmp 0x16c756
movq 0x10(%rsp), %rax
addq $0x18, %rax
movq %rax, 0x8(%rsp)
leaq 0x30(%rsp), %rdi
callq 0xb5db0
movq 0x8(%rsp), %rdi
movq %rax, %rsi
movq 0x20(%rsp), %rdx
callq 0x16c770
testb $0x1, %al
jne 0x16c746
jmp 0x16c748
jmp 0x16c765
jmp 0x16c74a
leaq 0x30(%rsp), %rdi
callq 0xb4cc0
jmp 0x16c6f2
movq 0x10(%rsp), %rdi
callq 0xb4c10
movq %rax, 0x30(%rsp)
movq 0x30(%rsp), %rax
addq $0x38, %rsp
retq
nop
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA3_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_:
sub rsp, 38h
mov [rsp+38h+var_10], rdi
mov [rsp+38h+var_18], rsi
mov rdi, [rsp+38h+var_10]
mov [rsp+38h+var_28], rdi
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE5beginEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::begin(void)
mov [rsp+38h+var_8], rax
loc_16C6F2:
mov rdi, [rsp+38h+var_28]
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::end(void)
mov [rsp+38h+var_20], rax
lea rdi, [rsp+38h+var_8]
lea rsi, [rsp+38h+var_20]
call _ZN9__gnu_cxxneIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbRKNS_17__normal_iteratorIT_T0_EESR_; __gnu_cxx::operator!=<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>(__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>> const&,__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>> const&)
test al, 1
jnz short loc_16C716
jmp short loc_16C756
loc_16C716:
mov rax, [rsp+38h+var_28]
add rax, 18h
mov [rsp+38h+var_30], rax
lea rdi, [rsp+38h+var_8]
call _ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEptEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator->(void)
mov rdi, [rsp+38h+var_30]
mov rsi, rax
mov rdx, [rsp+38h+var_18]
call _ZNKSt8equal_toIvEclIRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERA3_KcEEDTeqclsr3stdE7forwardIT_Efp_Eclsr3stdE7forwardIT0_Efp0_EEOSD_OSE_
test al, 1
jnz short loc_16C746
jmp short loc_16C748
loc_16C746:
jmp short loc_16C765
loc_16C748:
jmp short $+2
loc_16C74A:
lea rdi, [rsp+38h+var_8]
call _ZN9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEppEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator++(void)
jmp short loc_16C6F2
loc_16C756:
mov rdi, [rsp+38h+var_28]
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::end(void)
mov [rsp+38h+var_8], rax
loc_16C765:
mov rax, [rsp+38h+var_8]
add rsp, 38h
retn
| long long ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA3_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_(
long long a1,
long long a2)
{
long long v2; // rax
long long v4; // [rsp+18h] [rbp-20h] BYREF
long long v5; // [rsp+20h] [rbp-18h]
long long v6; // [rsp+28h] [rbp-10h]
long long i; // [rsp+30h] [rbp-8h] BYREF
v6 = a1;
v5 = a2;
for ( i = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::begin(a1);
;
__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator++(&i) )
{
v4 = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::end(a1);
if ( !__gnu_cxx::operator!=<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>(
(long long)&i,
(long long)&v4) )
break;
v2 = __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator->((long long)&i);
if ( (std::equal_to<void>::operator()<std::string const&,char const(&)[3]>(a1 + 24, v2, v5) & 1) != 0 )
return i;
}
return std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::end(a1);
}
| |||
22,124 | _gnu_cxx::__normal_iterator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>*, std::vector<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>> nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::find<char const (&) [3], 0>(char const (&) [3]) | monkey531[P]llama/common/json.hpp | iterator find(KeyType && key) // NOLINT(cppcoreguidelines-missing-std-forward)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return it;
}
}
return Container::end();
} | O2 | cpp | _gnu_cxx::__normal_iterator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>*, std::vector<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>> nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::find<char const (&) [3], 0>(char const (&) [3]):
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r15
movq (%rdi), %r14
movq 0x8(%r15), %rax
cmpq %rax, %r14
je 0x92227
movq %r14, %rdi
movq %rbx, %rsi
callq 0x3951e
testb %al, %al
jne 0x92224
addq $0x30, %r14
jmp 0x92206
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
nop
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA21_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_:
push r15
push r14
push rbx
mov rbx, rsi
mov r15, rdi
mov r14, [rdi]
loc_92206:
mov rax, [r15+8]
cmp r14, rax
jz short loc_92227
mov rdi, r14
mov rsi, rbx
call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*)
test al, al
jnz short loc_92224
add r14, 30h ; '0'
jmp short loc_92206
loc_92224:
mov rax, r14
loc_92227:
pop rbx
pop r14
pop r15
retn
| long long ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA21_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_(
long long *a1)
{
long long i; // r14
long long result; // rax
for ( i = *a1; ; i += 48LL )
{
result = a1[1];
if ( i == result )
break;
if ( std::operator==<char>(i) )
return i;
}
return result;
}
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA21_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_:
PUSH R15
PUSH R14
PUSH RBX
MOV RBX,RSI
MOV R15,RDI
MOV R14,qword ptr [RDI]
LAB_00192206:
MOV RAX,qword ptr [R15 + 0x8]
CMP R14,RAX
JZ 0x00192227
MOV RDI,R14
MOV RSI,RBX
CALL 0x0013951e
TEST AL,AL
JNZ 0x00192224
ADD R14,0x30
JMP 0x00192206
LAB_00192224:
MOV RAX,R14
LAB_00192227:
POP RBX
POP R14
POP R15
RET
|
string * _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE4findIRA21_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEEOSS_
(int8 *param_1,char *param_2)
{
bool bVar1;
string *psVar2;
string *psVar3;
psVar3 = (string *)*param_1;
while ((psVar2 = (string *)param_1[1], psVar3 != (string *)param_1[1] &&
(bVar1 = std::operator==(psVar3,param_2), psVar2 = psVar3, !bVar1))) {
psVar3 = psVar3 + 0x30;
}
return psVar2;
}
| |
22,125 | bool fmt::v10::detail::loc_writer<char>::operator()<unsigned int, 0>(unsigned int) | aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h | auto operator()(T value) -> bool {
auto arg = make_write_int_arg(value, specs.sign);
write_int(out, static_cast<uint64_or_128_t<T>>(arg.abs_value), arg.prefix,
specs, digit_grouping<Char>(grouping, sep));
return true;
} | O0 | c | bool fmt::v10::detail::loc_writer<char>::operator()<unsigned int, 0>(unsigned int):
subq $0x158, %rsp # imm = 0x158
movq %rsi, 0x140(%rsp)
movq %rdx, 0x148(%rsp)
movq 0x140(%rsp), %rax
movq 0x148(%rsp), %rcx
movq %rdi, 0x138(%rsp)
movq %rcx, 0x128(%rsp)
movq %rax, 0x120(%rsp)
movq 0x138(%rsp), %rcx
movq %rcx, 0x30(%rsp)
movq 0x120(%rsp), %rax
movq 0x128(%rsp), %rdx
movq 0x8(%rcx), %rcx
movzwl 0x9(%rcx), %ecx
shrl $0x4, %ecx
andl $0x7, %ecx
movq %rdx, 0xf8(%rsp)
movq %rax, 0xf0(%rsp)
movq 0xf0(%rsp), %rsi
movq 0xf8(%rsp), %rdx
leaq 0x100(%rsp), %rdi
callq 0xa9320
movq 0x30(%rsp), %rsi
movq (%rsi), %rax
movq %rax, 0xe8(%rsp)
movq 0x100(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x108(%rsp), %rax
movq %rax, 0x18(%rsp)
movl 0x110(%rsp), %eax
movl %eax, 0x24(%rsp)
movq 0x8(%rsi), %rax
movq %rax, 0x28(%rsp)
addq $0x30, %rsi
leaq 0x88(%rsp), %rdi
callq 0x94640
movq 0x30(%rsp), %rsi
addq $0x10, %rsi
leaq 0x68(%rsp), %rdi
callq 0x94640
jmp 0xa4b0b
leaq 0xa8(%rsp), %rdi
leaq 0x88(%rsp), %rsi
leaq 0x68(%rsp), %rdx
callq 0xa5240
jmp 0xa4b27
movq 0x28(%rsp), %r8
movl 0x24(%rsp), %ecx
movq 0x18(%rsp), %rax
movq 0x10(%rsp), %rdx
movq 0xe8(%rsp), %rdi
movq %rdx, 0x40(%rsp)
movq %rax, 0x48(%rsp)
movq 0x40(%rsp), %rsi
movq 0x48(%rsp), %rdx
leaq 0xa8(%rsp), %r9
callq 0xa8030
movq %rax, 0x8(%rsp)
jmp 0xa4b6a
movq 0x8(%rsp), %rax
movq %rax, 0x38(%rsp)
leaq 0xa8(%rsp), %rdi
callq 0xa5280
leaq 0x68(%rsp), %rdi
callq 0x96fb8
leaq 0x88(%rsp), %rdi
callq 0x96fb8
movb $0x1, %al
andb $0x1, %al
addq $0x158, %rsp # imm = 0x158
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0xa4be9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0xa4bdf
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
leaq 0xa8(%rsp), %rdi
callq 0xa5280
leaq 0x68(%rsp), %rdi
callq 0x96fb8
leaq 0x88(%rsp), %rdi
callq 0x96fb8
movq 0x60(%rsp), %rdi
callq 0x90db0
| _ZN3fmt3v106detail10loc_writerIcEclIoTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEbS6_:
sub rsp, 158h
mov [rsp+158h+var_18], rsi
mov [rsp+158h+var_10], rdx
mov rax, [rsp+158h+var_18]
mov rcx, [rsp+158h+var_10]
mov [rsp+158h+var_20], rdi
mov [rsp+158h+var_30], rcx
mov [rsp+158h+var_38], rax
mov rcx, [rsp+158h+var_20]
mov [rsp+158h+var_128], rcx
mov rax, [rsp+158h+var_38]
mov rdx, [rsp+158h+var_30]
mov rcx, [rcx+8]
movzx ecx, word ptr [rcx+9]
shr ecx, 4
and ecx, 7
mov [rsp+158h+var_60], rdx
mov [rsp+158h+var_68], rax
mov rsi, [rsp+158h+var_68]
mov rdx, [rsp+158h+var_60]
lea rdi, [rsp+158h+var_58]
call _ZN3fmt3v106detail18make_write_int_argIoEENS1_13write_int_argINSt11conditionalIXaalecl8num_bitsIT_EELi32EntLi0EEjNS4_IXlecl8num_bitsIS5_EELi64EEmoE4typeEE4typeEEES5_NS0_4sign4typeE; fmt::v10::detail::make_write_int_arg<unsigned __int128>(unsigned __int128,fmt::v10::sign::type)
mov rsi, [rsp+158h+var_128]
mov rax, [rsi]
mov [rsp+158h+var_70], rax
mov rax, [rsp+158h+var_58]
mov [rsp+158h+var_148], rax
mov rax, [rsp+158h+var_50]
mov [rsp+158h+var_140], rax
mov eax, [rsp+158h+var_48]
mov [rsp+158h+var_134], eax
mov rax, [rsi+8]
mov [rsp+158h+var_130], rax
add rsi, 30h ; '0'
lea rdi, [rsp+158h+var_D0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2ERKS4_; std::string::basic_string(std::string const&)
mov rsi, [rsp+158h+var_128]
add rsi, 10h
lea rdi, [rsp+158h+var_F0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2ERKS4_; std::string::basic_string(std::string const&)
jmp short $+2
loc_A4B0B:
lea rdi, [rsp+158h+var_B0]
lea rsi, [rsp+158h+var_D0]
lea rdx, [rsp+158h+var_F0]
call _ZN3fmt3v106detail14digit_groupingIcEC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_; fmt::v10::detail::digit_grouping<char>::digit_grouping(std::string,std::string)
jmp short $+2
loc_A4B27:
mov r8, [rsp+158h+var_130]
mov ecx, [rsp+158h+var_134]
mov rax, [rsp+158h+var_140]
mov rdx, [rsp+158h+var_148]
mov rdi, [rsp+158h+var_70]
mov [rsp+158h+var_118], rdx
mov [rsp+158h+var_110], rax
mov rsi, [rsp+158h+var_118]
mov rdx, [rsp+158h+var_110]
lea r9, [rsp+158h+var_B0]
call _ZN3fmt3v106detail9write_intINS0_8appenderEocEET_S4_T0_jRKNS0_12format_specsIT1_EERKNS1_14digit_groupingIS7_EE; fmt::v10::detail::write_int<fmt::v10::appender,unsigned __int128,char>(fmt::v10::appender,unsigned __int128,uint,fmt::v10::format_specs<char> const&,fmt::v10::detail::digit_grouping<char> const&)
mov [rsp+158h+var_150], rax
jmp short $+2
loc_A4B6A:
mov rax, [rsp+158h+var_150]
mov [rsp+158h+var_120], rax
lea rdi, [rsp+158h+var_B0]
call _ZN3fmt3v106detail14digit_groupingIcED2Ev; fmt::v10::detail::digit_grouping<char>::~digit_grouping()
lea rdi, [rsp+158h+var_F0]; void *
call j__ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
lea rdi, [rsp+158h+var_D0]; void *
call j__ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov al, 1
and al, 1
add rsp, 158h
retn
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_A4BE9
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_A4BDF
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
lea rdi, [rsp+arg_A0]
call _ZN3fmt3v106detail14digit_groupingIcED2Ev; fmt::v10::detail::digit_grouping<char>::~digit_grouping()
loc_A4BDF:
lea rdi, [rsp+arg_60]; void *
call j__ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_A4BE9:
lea rdi, [rsp+arg_80]; void *
call j__ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, [rsp+arg_58]
call __Unwind_Resume
| _ZN3fmt3v106detail10loc_writerIcEclIoTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEbS6_:
SUB RSP,0x158
MOV qword ptr [RSP + 0x140],RSI
MOV qword ptr [RSP + 0x148],RDX
MOV RAX,qword ptr [RSP + 0x140]
MOV RCX,qword ptr [RSP + 0x148]
MOV qword ptr [RSP + 0x138],RDI
MOV qword ptr [RSP + 0x128],RCX
MOV qword ptr [RSP + 0x120],RAX
MOV RCX,qword ptr [RSP + 0x138]
MOV qword ptr [RSP + 0x30],RCX
MOV RAX,qword ptr [RSP + 0x120]
MOV RDX,qword ptr [RSP + 0x128]
MOV RCX,qword ptr [RCX + 0x8]
MOVZX ECX,word ptr [RCX + 0x9]
SHR ECX,0x4
AND ECX,0x7
MOV qword ptr [RSP + 0xf8],RDX
MOV qword ptr [RSP + 0xf0],RAX
MOV RSI,qword ptr [RSP + 0xf0]
MOV RDX,qword ptr [RSP + 0xf8]
LEA RDI,[RSP + 0x100]
CALL 0x001a9320
MOV RSI,qword ptr [RSP + 0x30]
MOV RAX,qword ptr [RSI]
MOV qword ptr [RSP + 0xe8],RAX
MOV RAX,qword ptr [RSP + 0x100]
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [RSP + 0x108]
MOV qword ptr [RSP + 0x18],RAX
MOV EAX,dword ptr [RSP + 0x110]
MOV dword ptr [RSP + 0x24],EAX
MOV RAX,qword ptr [RSI + 0x8]
MOV qword ptr [RSP + 0x28],RAX
ADD RSI,0x30
LEA RDI,[RSP + 0x88]
CALL 0x00194640
MOV RSI,qword ptr [RSP + 0x30]
ADD RSI,0x10
LAB_001a4aff:
LEA RDI,[RSP + 0x68]
CALL 0x00194640
JMP 0x001a4b0b
LAB_001a4b0b:
LEA RDI,[RSP + 0xa8]
LEA RSI,[RSP + 0x88]
LEA RDX,[RSP + 0x68]
CALL 0x001a5240
JMP 0x001a4b27
LAB_001a4b27:
MOV R8,qword ptr [RSP + 0x28]
MOV ECX,dword ptr [RSP + 0x24]
MOV RAX,qword ptr [RSP + 0x18]
MOV RDX,qword ptr [RSP + 0x10]
MOV RDI,qword ptr [RSP + 0xe8]
MOV qword ptr [RSP + 0x40],RDX
MOV qword ptr [RSP + 0x48],RAX
MOV RSI,qword ptr [RSP + 0x40]
MOV RDX,qword ptr [RSP + 0x48]
LAB_001a4b56:
LEA R9,[RSP + 0xa8]
CALL 0x001a8030
LAB_001a4b63:
MOV qword ptr [RSP + 0x8],RAX
JMP 0x001a4b6a
LAB_001a4b6a:
MOV RAX,qword ptr [RSP + 0x8]
MOV qword ptr [RSP + 0x38],RAX
LEA RDI,[RSP + 0xa8]
CALL 0x001a5280
LEA RDI,[RSP + 0x68]
CALL 0x00196fb8
LEA RDI,[RSP + 0x88]
CALL 0x00196fb8
MOV AL,0x1
AND AL,0x1
ADD RSP,0x158
RET
|
int8
_ZN3fmt3v106detail10loc_writerIcEclIoTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEbS6_
(int8 *param_1,int8 param_2,int8 param_3)
{
int8 uVar1;
string local_f0 [32];
string local_d0 [32];
digit_grouping<char> local_b0 [64];
detail *local_70;
int8 local_68;
int8 local_60;
int8 local_58;
int8 local_50;
int4 local_48;
int8 local_38;
int8 local_30;
int8 *local_20;
int8 local_18;
int8 local_10;
local_68 = param_2;
local_60 = param_3;
local_38 = param_2;
local_30 = param_3;
local_20 = param_1;
local_18 = param_2;
local_10 = param_3;
fmt::v10::detail::write_int_arg<std::
conditional<(((num_bits<unsigned__int128>)())<=(32))&&(!(0)),unsigned_int,std::
conditional<((num_bits<unsigned__int128>)())<=(64),unsigned_long,unsigned__int128>::type>::
type>fmt::v10::detail::make_write_int_arg<unsigned__int128>
(&local_58,param_2,param_3,*(ushort *)(param_1[1] + 9) >> 4 & 7);
local_70 = (detail *)*param_1;
uVar1 = param_1[1];
std::__cxx11::string::string(local_d0,(string *)(param_1 + 6));
/* try { // try from 001a4aff to 001a4b08 has its CatchHandler @ 001a4ba4 */
std::__cxx11::string::string(local_f0,(string *)(param_1 + 2));
/* try { // try from 001a4b0b to 001a4b24 has its CatchHandler @ 001a4bb4 */
fmt::v10::detail::digit_grouping<char>::digit_grouping(local_b0,local_d0,local_f0);
/* try { // try from 001a4b56 to 001a4b62 has its CatchHandler @ 001a4bc4 */
fmt::v10::detail::write_int<fmt::v10::appender,unsigned__int128,char>
(local_70,local_58,local_50,local_48,uVar1,local_b0);
fmt::v10::detail::digit_grouping<char>::~digit_grouping(local_b0);
std::__cxx11::string::~string(local_f0);
std::__cxx11::string::~string(local_d0);
return 1;
}
| ||
22,126 | bool fmt::v10::detail::loc_writer<char>::operator()<unsigned int, 0>(unsigned int) | aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h | auto operator()(T value) -> bool {
auto arg = make_write_int_arg(value, specs.sign);
write_int(out, static_cast<uint64_or_128_t<T>>(arg.abs_value), arg.prefix,
specs, digit_grouping<Char>(grouping, sep));
return true;
} | O3 | c | bool fmt::v10::detail::loc_writer<char>::operator()<unsigned int, 0>(unsigned int):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rsi, 0x40(%rsp)
movq %rdi, %r12
movq (%rdi), %r15
movq 0x8(%rdi), %r14
movzwl 0x9(%r14), %eax
shrl $0x2, %eax
andl $0x1c, %eax
leaq 0x12ae9a(%rip), %rcx # 0x161180
movl (%rax,%rcx), %ebp
leaq 0x10(%rsp), %rbx
movq %rbx, -0x10(%rbx)
movq 0x30(%rdi), %rsi
movq 0x38(%rdi), %rdx
addq %rsi, %rdx
movq %rsp, %rdi
callq 0x2c640
leaq 0x30(%rsp), %r13
movq %r13, -0x10(%r13)
movq 0x10(%r12), %rsi
movq 0x18(%r12), %rdx
addq %rsi, %rdx
leaq 0x20(%rsp), %rdi
callq 0x2c640
leaq 0x58(%rsp), %rcx
movq %rcx, -0x10(%rcx)
movq (%rsp), %rax
cmpq %rbx, %rax
je 0x36348
movq %rax, 0x48(%rsp)
movq 0x10(%rsp), %rax
movq %rax, 0x58(%rsp)
jmp 0x3634e
movups (%rbx), %xmm0
movups %xmm0, (%rcx)
movq 0x8(%rsp), %rax
leaq 0x78(%rsp), %r12
movq %rax, -0x28(%r12)
movq %rbx, (%rsp)
movq $0x0, 0x8(%rsp)
movb $0x0, 0x10(%rsp)
movq %r12, -0x10(%r12)
movq 0x20(%rsp), %rax
movq %rcx, %rbx
cmpq %r13, %rax
je 0x36392
movq %rax, 0x68(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x78(%rsp)
jmp 0x3639c
movups (%r13), %xmm0
movups %xmm0, (%r12)
movq 0x28(%rsp), %rax
leaq 0x48(%rsp), %r8
movq %rax, 0x28(%r8)
movq %r13, 0x20(%rsp)
movq $0x0, 0x28(%rsp)
movb $0x0, 0x30(%rsp)
movq %r15, %rdi
movq 0x40(%rsp), %rsi
movl %ebp, %edx
movq %r14, %rcx
callq 0x36889
movq 0x68(%rsp), %rdi
cmpq %r12, %rdi
je 0x363e6
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x2d2d0
movq 0x48(%rsp), %rdi
cmpq %rbx, %rdi
je 0x363fd
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x2d2d0
movq 0x20(%rsp), %rdi
cmpq %r13, %rdi
je 0x36414
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x2d2d0
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x3642f
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2d2d0
movb $0x1, %al
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0x36d16
movq 0x20(%rsp), %rdi
cmpq %r13, %rdi
je 0x3646c
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x2d2d0
jmp 0x3646c
movq %rax, %rbx
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x36487
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2d2d0
movq %rbx, %rdi
callq 0x2e220
nop
| _ZN3fmt3v106detail10loc_writerIcEclIyTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEbS6_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 88h
mov [rsp+0B8h+var_78], rsi
mov r12, rdi
mov r15, [rdi]
mov r14, [rdi+8]
movzx eax, word ptr [r14+9]
shr eax, 2
and eax, 1Ch
lea rcx, dword_161180
mov ebp, [rax+rcx]
lea rbx, [rsp+0B8h+var_A8]
mov [rbx-10h], rbx
mov rsi, [rdi+30h]
mov rdx, [rdi+38h]
add rdx, rsi
mov rdi, rsp
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
lea r13, [rsp+0B8h+var_88]
mov [r13-10h], r13
mov rsi, [r12+10h]
mov rdx, [r12+18h]
add rdx, rsi
lea rdi, [rsp+0B8h+var_98]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
lea rcx, [rsp+0B8h+var_60]
mov [rcx-10h], rcx
mov rax, [rsp+0B8h+var_B8]
cmp rax, rbx
jz short loc_36348
mov [rsp+0B8h+var_70], rax
mov rax, [rsp+0B8h+var_A8]
mov [rsp+0B8h+var_60], rax
jmp short loc_3634E
loc_36348:
movups xmm0, xmmword ptr [rbx]
movups xmmword ptr [rcx], xmm0
loc_3634E:
mov rax, [rsp+0B8h+var_B0]
lea r12, [rsp+0B8h+var_40]
mov [r12-28h], rax
mov [rsp+0B8h+var_B8], rbx
mov [rsp+0B8h+var_B0], 0
mov byte ptr [rsp+0B8h+var_A8], 0
mov [r12-10h], r12
mov rax, [rsp+0B8h+var_98]
mov rbx, rcx
cmp rax, r13
jz short loc_36392
mov [rsp+0B8h+var_50], rax
mov rax, [rsp+0B8h+var_88]
mov [rsp+0B8h+var_40], rax
jmp short loc_3639C
loc_36392:
movups xmm0, xmmword ptr [r13+0]
movups xmmword ptr [r12], xmm0
loc_3639C:
mov rax, [rsp+0B8h+var_90]
lea r8, [rsp+0B8h+var_70]
mov [r8+28h], rax
mov [rsp+0B8h+var_98], r13
mov [rsp+0B8h+var_90], 0
mov byte ptr [rsp+0B8h+var_88], 0
mov rdi, r15; int
mov rsi, [rsp+0B8h+var_78]
mov edx, ebp
mov rcx, r14
call _ZN3fmt3v106detail9write_intINS0_8appenderEmcEET_S4_T0_jRKNS0_12format_specsIT1_EERKNS1_14digit_groupingIS7_EE; 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&)
mov rdi, [rsp+0B8h+var_50]; void *
cmp rdi, r12
jz short loc_363E6
mov rsi, [rsp+0B8h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_363E6:
mov rdi, [rsp+0B8h+var_70]; void *
cmp rdi, rbx
jz short loc_363FD
mov rsi, [rsp+0B8h+var_60]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_363FD:
mov rdi, [rsp+0B8h+var_98]; void *
cmp rdi, r13
jz short loc_36414
mov rsi, [rsp+0B8h+var_88]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_36414:
mov rdi, [rsp+0B8h+var_B8]; void *
lea rax, [rsp+0B8h+var_A8]
cmp rdi, rax
jz short loc_3642F
mov rsi, [rsp+0B8h+var_A8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_3642F:
mov al, 1
add rsp, 88h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
lea rdi, [rsp+arg_40]
call _ZN3fmt3v106detail14digit_groupingIcED2Ev; fmt::v10::detail::digit_grouping<char>::~digit_grouping()
mov rdi, [rsp+arg_18]; void *
cmp rdi, r13
jz short loc_3646C
mov rsi, [rsp+arg_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_3646C
mov rbx, rax
loc_3646C:
mov rdi, [rsp+0]; void *
lea rax, [rsp+arg_8]
cmp rdi, rax
jz short loc_36487
mov rsi, [rsp+arg_8]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_36487:
mov rdi, rbx
call __Unwind_Resume
| char ZN3fmt3v106detail10loc_writerIcEclIyTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEbS6_(
long long *a1,
long long a2)
{
long long v2; // r15
void *v4; // [rsp+0h] [rbp-B8h] BYREF
long long v5; // [rsp+8h] [rbp-B0h]
__int128 v6; // [rsp+10h] [rbp-A8h] BYREF
void *v7; // [rsp+20h] [rbp-98h] BYREF
long long v8; // [rsp+28h] [rbp-90h]
__int128 v9; // [rsp+30h] [rbp-88h] BYREF
long long v10; // [rsp+40h] [rbp-78h]
void *v11; // [rsp+48h] [rbp-70h]
long long v12; // [rsp+50h] [rbp-68h]
__int128 v13; // [rsp+58h] [rbp-60h] BYREF
void *v14; // [rsp+68h] [rbp-50h]
long long v15; // [rsp+70h] [rbp-48h]
_OWORD v16[4]; // [rsp+78h] [rbp-40h] BYREF
v10 = a2;
v2 = *a1;
v4 = &v6;
std::string::_M_construct<char *>(&v4, a1[6], a1[6] + a1[7]);
v7 = &v9;
std::string::_M_construct<char *>(&v7, a1[2], a1[2] + a1[3]);
v11 = &v13;
if ( v4 == &v6 )
{
v13 = v6;
}
else
{
v11 = v4;
*(_QWORD *)&v13 = v6;
}
v12 = v5;
v4 = &v6;
v5 = 0LL;
LOBYTE(v6) = 0;
v14 = v16;
if ( v7 == &v9 )
{
v16[0] = v9;
}
else
{
v14 = v7;
*(_QWORD *)&v16[0] = v9;
}
v15 = v8;
v7 = &v9;
v8 = 0LL;
LOBYTE(v9) = 0;
fmt::v10::detail::write_int<fmt::v10::appender,unsigned long,char>(v2);
if ( v14 != v16 )
operator delete(v14, *(_QWORD *)&v16[0] + 1LL);
if ( v11 != &v13 )
operator delete(v11, v13 + 1);
if ( v7 != &v9 )
operator delete(v7, v9 + 1);
if ( v4 != &v6 )
operator delete(v4, v6 + 1);
return 1;
}
| _ZN3fmt3v106detail10loc_writerIcEclIyTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEbS6_:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x88
MOV qword ptr [RSP + 0x40],RSI
MOV R12,RDI
MOV R15,qword ptr [RDI]
MOV R14,qword ptr [RDI + 0x8]
MOVZX EAX,word ptr [R14 + 0x9]
SHR EAX,0x2
AND EAX,0x1c
LEA RCX,[0x261180]
MOV EBP,dword ptr [RAX + RCX*0x1]
LEA RBX,[RSP + 0x10]
MOV qword ptr [RBX + -0x10],RBX
MOV RSI,qword ptr [RDI + 0x30]
MOV RDX,qword ptr [RDI + 0x38]
ADD RDX,RSI
MOV RDI,RSP
CALL 0x0012c640
LEA R13,[RSP + 0x30]
MOV qword ptr [R13 + -0x10],R13
MOV RSI,qword ptr [R12 + 0x10]
MOV RDX,qword ptr [R12 + 0x18]
ADD RDX,RSI
LAB_0013631b:
LEA RDI,[RSP + 0x20]
CALL 0x0012c640
LEA RCX,[RSP + 0x58]
MOV qword ptr [RCX + -0x10],RCX
MOV RAX,qword ptr [RSP]
CMP RAX,RBX
JZ 0x00136348
MOV qword ptr [RSP + 0x48],RAX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x58],RAX
JMP 0x0013634e
LAB_00136348:
MOVUPS XMM0,xmmword ptr [RBX]
MOVUPS xmmword ptr [RCX],XMM0
LAB_0013634e:
MOV RAX,qword ptr [RSP + 0x8]
LEA R12,[RSP + 0x78]
MOV qword ptr [R12 + -0x28],RAX
MOV qword ptr [RSP],RBX
MOV qword ptr [RSP + 0x8],0x0
MOV byte ptr [RSP + 0x10],0x0
MOV qword ptr [R12 + -0x10],R12
MOV RAX,qword ptr [RSP + 0x20]
MOV RBX,RCX
CMP RAX,R13
JZ 0x00136392
MOV qword ptr [RSP + 0x68],RAX
MOV RAX,qword ptr [RSP + 0x30]
MOV qword ptr [RSP + 0x78],RAX
JMP 0x0013639c
LAB_00136392:
MOVUPS XMM0,xmmword ptr [R13]
MOVUPS xmmword ptr [R12],XMM0
LAB_0013639c:
MOV RAX,qword ptr [RSP + 0x28]
LEA R8,[RSP + 0x48]
MOV qword ptr [R8 + 0x28],RAX
MOV qword ptr [RSP + 0x20],R13
MOV qword ptr [RSP + 0x28],0x0
MOV byte ptr [RSP + 0x30],0x0
LAB_001363bd:
MOV RDI,R15
MOV RSI,qword ptr [RSP + 0x40]
MOV EDX,EBP
MOV RCX,R14
CALL 0x00136889
LAB_001363cf:
MOV RDI,qword ptr [RSP + 0x68]
CMP RDI,R12
JZ 0x001363e6
MOV RSI,qword ptr [RSP + 0x78]
INC RSI
CALL 0x0012d2d0
LAB_001363e6:
MOV RDI,qword ptr [RSP + 0x48]
CMP RDI,RBX
JZ 0x001363fd
MOV RSI,qword ptr [RSP + 0x58]
INC RSI
CALL 0x0012d2d0
LAB_001363fd:
MOV RDI,qword ptr [RSP + 0x20]
CMP RDI,R13
JZ 0x00136414
MOV RSI,qword ptr [RSP + 0x30]
INC RSI
CALL 0x0012d2d0
LAB_00136414:
MOV RDI,qword ptr [RSP]
LEA RAX,[RSP + 0x10]
CMP RDI,RAX
JZ 0x0013642f
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0012d2d0
LAB_0013642f:
MOV AL,0x1
ADD RSP,0x88
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8
_ZN3fmt3v106detail10loc_writerIcEclIyTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEbS6_
(int8 *param_1,int8 param_2)
{
int4 uVar1;
int8 uVar2;
long lVar3;
uint *local_b8;
int8 local_b0;
uint local_a8;
int4 uStack_a4;
int4 uStack_a0;
int4 uStack_9c;
uint *local_98;
int8 local_90;
uint local_88;
int4 uStack_84;
int4 uStack_80;
int4 uStack_7c;
int8 local_78;
uint *local_70;
int8 local_68;
int8 local_60;
int4 uStack_58;
int4 uStack_54;
uint *local_50;
int8 local_48;
int8 local_40;
int4 uStack_38;
int4 uStack_34;
uVar2 = *param_1;
lVar3 = param_1[1];
uVar1 = *(int4 *)(&DAT_00261180 + (*(ushort *)(lVar3 + 9) >> 2 & 0x1c));
local_b8 = &local_a8;
local_78 = param_2;
std::__cxx11::string::_M_construct<char*>(&local_b8,param_1[6],param_1[7] + param_1[6]);
/* try { // try from 0013631b to 00136324 has its CatchHandler @ 00136469 */
local_98 = &local_88;
std::__cxx11::string::_M_construct<char*>(&local_98,param_1[2],param_1[3] + param_1[2]);
if (local_b8 == &local_a8) {
uStack_58 = uStack_a0;
uStack_54 = uStack_9c;
local_70 = (uint *)&local_60;
}
else {
local_70 = local_b8;
}
local_60 = CONCAT44(uStack_a4,local_a8);
local_68 = local_b0;
local_b0 = 0;
local_a8 = local_a8 & 0xffffff00;
if (local_98 == &local_88) {
uStack_38 = uStack_80;
uStack_34 = uStack_7c;
local_50 = (uint *)&local_40;
}
else {
local_50 = local_98;
}
local_40 = CONCAT44(uStack_84,local_88);
local_48 = local_90;
local_90 = 0;
local_88 = local_88 & 0xffffff00;
local_b8 = &local_a8;
local_98 = &local_88;
/* try { // try from 001363bd to 001363ce has its CatchHandler @ 00136443 */
fmt::v10::detail::write_int<fmt::v10::appender,unsigned_long,char>(uVar2,local_78,uVar1,lVar3);
if (local_50 != (uint *)&local_40) {
operator_delete(local_50,local_40 + 1);
}
if (local_70 != (uint *)&local_60) {
operator_delete(local_70,local_60 + 1);
}
if (local_98 != &local_88) {
operator_delete(local_98,CONCAT44(uStack_84,local_88) + 1);
}
if (local_b8 != &local_a8) {
operator_delete(local_b8,CONCAT44(uStack_a4,local_a8) + 1);
}
return 1;
}
| |
22,127 | js_callsite_mark | bluesky950520[P]quickjs/quickjs.c | static void js_callsite_mark(JSRuntime *rt, JSValue val, JS_MarkFunc *mark_func)
{
JSCallSiteData *csd = JS_GetOpaque(val, JS_CLASS_CALL_SITE);
if (csd) {
JS_MarkValue(rt, csd->filename, mark_func);
JS_MarkValue(rt, csd->func, mark_func);
JS_MarkValue(rt, csd->func_name, mark_func);
}
} | O2 | c | js_callsite_mark:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
cmpl $-0x1, %edx
jne 0x6e815
cmpw $0x3c, 0x6(%rsi)
jne 0x6e815
movq 0x30(%rsi), %r14
testq %r14, %r14
je 0x6e815
movq %rdi, %rbx
movl $0xfffffffe, %r15d # imm = 0xFFFFFFFE
movl 0x8(%r14), %eax
andl $-0x2, %eax
cmpl %r15d, %eax
jne 0x6e7da
movq (%r14), %rsi
movq %rbx, %rdi
movq %rcx, %r12
callq *%rcx
movq %r12, %rcx
movl 0x18(%r14), %eax
andl $-0x2, %eax
cmpl %r15d, %eax
jne 0x6e7f5
movq 0x10(%r14), %rsi
movq %rbx, %rdi
movq %rcx, %r12
callq *%rcx
movq %r12, %rcx
movl 0x28(%r14), %eax
andl $-0x2, %eax
cmpl %r15d, %eax
jne 0x6e815
movq 0x20(%r14), %rsi
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmpq *%rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
| js_callsite_mark:
push r15
push r14
push r12
push rbx
push rax
cmp edx, 0FFFFFFFFh
jnz short loc_6E815
cmp word ptr [rsi+6], 3Ch ; '<'
jnz short loc_6E815
mov r14, [rsi+30h]
test r14, r14
jz short loc_6E815
mov rbx, rdi
mov r15d, 0FFFFFFFEh
mov eax, [r14+8]
and eax, 0FFFFFFFEh
cmp eax, r15d
jnz short loc_6E7DA
mov rsi, [r14]
mov rdi, rbx
mov r12, rcx
call rcx
mov rcx, r12
loc_6E7DA:
mov eax, [r14+18h]
and eax, 0FFFFFFFEh
cmp eax, r15d
jnz short loc_6E7F5
mov rsi, [r14+10h]
mov rdi, rbx
mov r12, rcx
call rcx
mov rcx, r12
loc_6E7F5:
mov eax, [r14+28h]
and eax, 0FFFFFFFEh
cmp eax, r15d
jnz short loc_6E815
mov rsi, [r14+20h]
mov rdi, rbx
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
jmp rcx
loc_6E815:
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
| long long js_callsite_mark(long long a1, long long a2, int a3, void ( *a4)(_QWORD, _QWORD))
{
long long v4; // r14
void ( *v5)(_QWORD, _QWORD); // r12
void ( *v6)(_QWORD, _QWORD); // r12
long long result; // rax
if ( a3 == -1 && *(_WORD *)(a2 + 6) == 60 )
{
v4 = *(_QWORD *)(a2 + 48);
if ( v4 )
{
if ( (*(_DWORD *)(v4 + 8) & 0xFFFFFFFE) == 0xFFFFFFFE )
{
v5 = a4;
a4(a1, *(_QWORD *)v4);
a4 = v5;
}
if ( (*(_DWORD *)(v4 + 24) & 0xFFFFFFFE) == 0xFFFFFFFE )
{
v6 = a4;
a4(a1, *(_QWORD *)(v4 + 16));
a4 = v6;
}
result = *(_DWORD *)(v4 + 40) & 0xFFFFFFFE;
if ( (_DWORD)result == -2 )
return ((long long ( *)(long long, _QWORD))a4)(a1, *(_QWORD *)(v4 + 32));
}
}
return result;
}
| js_callsite_mark:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
CMP EDX,-0x1
JNZ 0x0016e815
CMP word ptr [RSI + 0x6],0x3c
JNZ 0x0016e815
MOV R14,qword ptr [RSI + 0x30]
TEST R14,R14
JZ 0x0016e815
MOV RBX,RDI
MOV R15D,0xfffffffe
MOV EAX,dword ptr [R14 + 0x8]
AND EAX,0xfffffffe
CMP EAX,R15D
JNZ 0x0016e7da
MOV RSI,qword ptr [R14]
MOV RDI,RBX
MOV R12,RCX
CALL RCX
MOV RCX,R12
LAB_0016e7da:
MOV EAX,dword ptr [R14 + 0x18]
AND EAX,0xfffffffe
CMP EAX,R15D
JNZ 0x0016e7f5
MOV RSI,qword ptr [R14 + 0x10]
MOV RDI,RBX
MOV R12,RCX
CALL RCX
MOV RCX,R12
LAB_0016e7f5:
MOV EAX,dword ptr [R14 + 0x28]
AND EAX,0xfffffffe
CMP EAX,R15D
JNZ 0x0016e815
MOV RSI,qword ptr [R14 + 0x20]
MOV RDI,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
JMP RCX
LAB_0016e815:
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
|
void js_callsite_mark(int8 param_1,long param_2,int param_3,code *UNRECOVERED_JUMPTABLE)
{
int8 *puVar1;
int4 extraout_EDX;
int4 extraout_EDX_00;
int4 uVar2;
if (((param_3 == -1) && (*(short *)(param_2 + 6) == 0x3c)) &&
(puVar1 = *(int8 **)(param_2 + 0x30), puVar1 != (int8 *)0x0)) {
uVar2 = 0xffffffff;
if ((*(uint *)(puVar1 + 1) & 0xfffffffe) == 0xfffffffe) {
(*UNRECOVERED_JUMPTABLE)(param_1,*puVar1);
uVar2 = extraout_EDX;
}
if ((*(uint *)(puVar1 + 3) & 0xfffffffe) == 0xfffffffe) {
(*UNRECOVERED_JUMPTABLE)(param_1,puVar1[2]);
uVar2 = extraout_EDX_00;
}
if ((*(uint *)(puVar1 + 5) & 0xfffffffe) == 0xfffffffe) {
/* WARNING: Could not recover jumptable at 0x0016e813. Too many branches */
/* WARNING: Treating indirect jump as call */
(*UNRECOVERED_JUMPTABLE)(param_1,puVar1[4],uVar2,UNRECOVERED_JUMPTABLE);
return;
}
}
return;
}
| |
22,128 | inline_mysql_file_sync | eloqsql/include/mysql/psi/mysql_file.h | static inline int
inline_mysql_file_sync(
#ifdef HAVE_PSI_FILE_INTERFACE
const char *src_file, uint src_line,
#endif
File fd, myf flags)
{
int result= 0;
#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, fd, PSI_FILE_SYNC);
if (psi_likely(locker != NULL))
{
PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line);
result= my_sync(fd, flags);
PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0);
return result;
}
#endif
result= my_sync(fd, flags);
return result;
} | O0 | c | inline_mysql_file_sync:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movl $0x0, -0x24(%rbp)
leaq 0x2791e1(%rip), %rax # 0x2c1158
movq (%rax), %rax
movq 0x158(%rax), %rax
movl -0x18(%rbp), %esi
leaq -0x78(%rbp), %rdi
movl $0x10, %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 0x48005
leaq 0x27919e(%rip), %rax # 0x2c1158
movq (%rax), %rax
movq 0x210(%rax), %rax
movq -0x30(%rbp), %rdi
movq -0x10(%rbp), %rdx
movl -0x14(%rbp), %ecx
xorl %esi, %esi
callq *%rax
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
callq 0xf6ea0
movl %eax, -0x24(%rbp)
leaq 0x27916f(%rip), %rax # 0x2c1158
movq (%rax), %rax
movq 0x218(%rax), %rax
movq -0x30(%rbp), %rdi
xorl %ecx, %ecx
movl %ecx, %esi
callq *%rax
movl -0x24(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x4801a
movl -0x18(%rbp), %edi
movq -0x20(%rbp), %rsi
callq 0xf6ea0
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x80, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| inline_mysql_file_sync_0:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov [rbp+var_20], rcx
mov [rbp+var_24], 0
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+158h]
mov esi, [rbp+var_18]
lea rdi, [rbp+var_78]
mov edx, 10h
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_48005
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+210h]
mov rdi, [rbp+var_30]
mov rdx, [rbp+var_10]
mov ecx, [rbp+var_14]
xor esi, esi
call rax
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
call my_sync
mov [rbp+var_24], eax
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+218h]
mov rdi, [rbp+var_30]
xor ecx, ecx
mov esi, ecx
call rax
mov eax, [rbp+var_24]
mov [rbp+var_4], eax
jmp short loc_4801A
loc_48005:
mov edi, [rbp+var_18]
mov rsi, [rbp+var_20]
call my_sync
mov [rbp+var_24], eax
mov eax, [rbp+var_24]
mov [rbp+var_4], eax
loc_4801A:
mov eax, [rbp+var_4]
add rsp, 80h
pop rbp
retn
| long long inline_mysql_file_sync_0(long long a1, unsigned int a2, unsigned int a3, long long a4)
{
_BYTE v5[72]; // [rsp+8h] [rbp-78h] BYREF
long long v6; // [rsp+50h] [rbp-30h]
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;
v7 = 0;
v6 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v5, a3, 16LL);
if ( v6 )
{
((void ( *)(long long, _QWORD, long long, _QWORD))PSI_server[66])(v6, 0LL, v11, v10);
v7 = my_sync(v9, v8);
((void ( *)(long long, _QWORD))PSI_server[67])(v6, 0LL);
}
else
{
return (unsigned int)my_sync(v9, v8);
}
return v7;
}
| inline_mysql_file_sync:
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
MOV dword ptr [RBP + -0x24],0x0
LEA RAX,[0x3c1158]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x158]
MOV ESI,dword ptr [RBP + -0x18]
LEA RDI,[RBP + -0x78]
MOV EDX,0x10
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 0x00148005
LEA RAX,[0x3c1158]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x210]
MOV RDI,qword ptr [RBP + -0x30]
MOV RDX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RBP + -0x14]
XOR ESI,ESI
CALL RAX
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x001f6ea0
MOV dword ptr [RBP + -0x24],EAX
LEA RAX,[0x3c1158]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x218]
MOV RDI,qword ptr [RBP + -0x30]
XOR ECX,ECX
MOV ESI,ECX
CALL RAX
MOV EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014801a
LAB_00148005:
MOV EDI,dword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x001f6ea0
MOV dword ptr [RBP + -0x24],EAX
MOV EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x4],EAX
LAB_0014801a:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x80
POP RBP
RET
|
int4
inline_mysql_file_sync(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_2c = 0;
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,0x10);
if (local_38 == 0) {
local_c = my_sync(local_20,local_28);
}
else {
(**(code **)(PSI_server + 0x210))(local_38,0,local_18,local_1c);
local_2c = my_sync(local_20,local_28);
(**(code **)(PSI_server + 0x218))(local_38,0);
local_c = local_2c;
}
return local_c;
}
| |
22,129 | my_wc_mb_euc_jp | eloqsql/strings/ctype-ujis.c | static int
my_wc_mb_euc_jp(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t wc, uchar *s, uchar *e)
{
int jp;
if ((int) wc < 0x80) /* ASCII [00-7F] */
{
if (s >= e)
return MY_CS_TOOSMALL;
*s= (uchar) wc;
return 1;
}
if (wc > 0xFFFF)
return MY_CS_ILUNI;
if ((jp= unicode_to_jisx0208_eucjp[wc])) /* JIS-X-0208 */
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
MY_PUT_MB2(s, jp);
return 2;
}
if ((jp= unicode_to_jisx0212_eucjp[wc])) /* JIS-X-0212 */
{
if (s + 3 > e)
return MY_CS_TOOSMALL3;
s[0]= 0x8F;
MY_PUT_MB2(s + 1, jp);
return 3;
}
if (wc >= 0xFF61 && wc <= 0xFF9F) /* Half width Katakana */
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
s[0]= 0x8E;
s[1]= (uchar) (wc - 0xFEC0);
return 2;
}
return MY_CS_ILUNI;
} | O3 | c | my_wc_mb_euc_jp:
cmpl $0x7f, %esi
jg 0x4cade
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmpq %rcx, %rdx
jae 0x4cb13
movb %sil, (%rdx)
movl $0x1, %eax
retq
xorl %eax, %eax
cmpq $0xffff, %rsi # imm = 0xFFFF
ja 0x4cb13
leaq 0x246430(%rip), %rdi # 0x292f20
movzwl (%rdi,%rsi,2), %edi
testw %di, %di
je 0x4cb14
leaq 0x2(%rdx), %rsi
movl $0xffffff9a, %eax # imm = 0xFFFFFF9A
cmpq %rcx, %rsi
ja 0x4cb13
rolw $0x8, %di
movw %di, (%rdx)
movl $0x2, %eax
retq
pushq %rbp
movq %rsp, %rbp
pushq %rbx
leaq 0x266400(%rip), %rdi # 0x2b2f20
movzwl (%rdi,%rsi,2), %ebx
testw %bx, %bx
je 0x4cb47
leaq 0x3(%rdx), %rsi
movl $0xffffff99, %eax # imm = 0xFFFFFF99
cmpq %rcx, %rsi
ja 0x4cb72
movb $-0x71, (%rdx)
movb %bh, 0x1(%rdx)
movb %bl, 0x2(%rdx)
movl $0x3, %eax
jmp 0x4cb72
leaq -0xff61(%rsi), %rdi
cmpq $0x3e, %rdi
ja 0x4cb72
leaq 0x2(%rdx), %rdi
movl $0xffffff9a, %eax # imm = 0xFFFFFF9A
cmpq %rcx, %rdi
ja 0x4cb72
movb $-0x72, (%rdx)
addb $0x40, %sil
movb %sil, 0x1(%rdx)
movl $0x2, %eax
popq %rbx
popq %rbp
retq
| my_wc_mb_euc_jp:
cmp esi, 7Fh
jg short loc_4CADE
mov eax, 0FFFFFF9Bh
cmp rdx, rcx
jnb short locret_4CB13
mov [rdx], sil
mov eax, 1
retn
loc_4CADE:
xor eax, eax
cmp rsi, 0FFFFh
ja short locret_4CB13
lea rdi, unicode_to_jisx0208_eucjp
movzx edi, word ptr [rdi+rsi*2]
test di, di
jz short loc_4CB14
lea rsi, [rdx+2]
mov eax, 0FFFFFF9Ah
cmp rsi, rcx
ja short locret_4CB13
rol di, 8
mov [rdx], di
mov eax, 2
locret_4CB13:
retn
loc_4CB14:
push rbp
mov rbp, rsp
push rbx
lea rdi, unicode_to_jisx0212_eucjp
movzx ebx, word ptr [rdi+rsi*2]
test bx, bx
jz short loc_4CB47
lea rsi, [rdx+3]
mov eax, 0FFFFFF99h
cmp rsi, rcx
ja short loc_4CB72
mov byte ptr [rdx], 8Fh
mov [rdx+1], bh
mov [rdx+2], bl
mov eax, 3
jmp short loc_4CB72
loc_4CB47:
lea rdi, [rsi-0FF61h]
cmp rdi, 3Eh ; '>'
ja short loc_4CB72
lea rdi, [rdx+2]
mov eax, 0FFFFFF9Ah
cmp rdi, rcx
ja short loc_4CB72
mov byte ptr [rdx], 8Eh
add sil, 40h ; '@'
mov [rdx+1], sil
mov eax, 2
loc_4CB72:
pop rbx
pop rbp
retn
| long long my_wc_mb_euc_jp(long long a1, unsigned long long a2, unsigned long long a3, unsigned long long a4)
{
long long result; // rax
__int16 v5; // di
__int16 v6; // bx
if ( (int)a2 > 127 )
{
result = 0LL;
if ( a2 <= 0xFFFF )
{
v5 = unicode_to_jisx0208_eucjp[a2];
if ( v5 )
{
result = 4294967194LL;
if ( a3 + 2 <= a4 )
{
*(_WORD *)a3 = __ROL2__(v5, 8);
return 2LL;
}
}
else
{
v6 = unicode_to_jisx0212_eucjp[a2];
if ( v6 )
{
result = 4294967193LL;
if ( a3 + 3 <= a4 )
{
*(_BYTE *)a3 = -113;
*(_BYTE *)(a3 + 1) = HIBYTE(v6);
*(_BYTE *)(a3 + 2) = v6;
return 3LL;
}
}
else if ( a2 - 65377 <= 0x3E )
{
result = 4294967194LL;
if ( a3 + 2 <= a4 )
{
*(_BYTE *)a3 = -114;
*(_BYTE *)(a3 + 1) = a2 + 64;
return 2LL;
}
}
}
}
}
else
{
result = 4294967195LL;
if ( a3 < a4 )
{
*(_BYTE *)a3 = a2;
return 1LL;
}
}
return result;
}
| my_wc_mb_euc_jp:
CMP ESI,0x7f
JG 0x0014cade
MOV EAX,0xffffff9b
CMP RDX,RCX
JNC 0x0014cb13
MOV byte ptr [RDX],SIL
MOV EAX,0x1
RET
LAB_0014cade:
XOR EAX,EAX
CMP RSI,0xffff
JA 0x0014cb13
LEA RDI,[0x392f20]
MOVZX EDI,word ptr [RDI + RSI*0x2]
TEST DI,DI
JZ 0x0014cb14
LEA RSI,[RDX + 0x2]
MOV EAX,0xffffff9a
CMP RSI,RCX
JA 0x0014cb13
ROL DI,0x8
MOV word ptr [RDX],DI
MOV EAX,0x2
LAB_0014cb13:
RET
LAB_0014cb14:
PUSH RBP
MOV RBP,RSP
PUSH RBX
LEA RDI,[0x3b2f20]
MOVZX EBX,word ptr [RDI + RSI*0x2]
TEST BX,BX
JZ 0x0014cb47
LEA RSI,[RDX + 0x3]
MOV EAX,0xffffff99
CMP RSI,RCX
JA 0x0014cb72
MOV byte ptr [RDX],0x8f
MOV byte ptr [RDX + 0x1],BH
MOV byte ptr [RDX + 0x2],BL
MOV EAX,0x3
JMP 0x0014cb72
LAB_0014cb47:
LEA RDI,[RSI + -0xff61]
CMP RDI,0x3e
JA 0x0014cb72
LEA RDI,[RDX + 0x2]
MOV EAX,0xffffff9a
CMP RDI,RCX
JA 0x0014cb72
MOV byte ptr [RDX],0x8e
ADD SIL,0x40
MOV byte ptr [RDX + 0x1],SIL
MOV EAX,0x2
LAB_0014cb72:
POP RBX
POP RBP
RET
|
int8 my_wc_mb_euc_jp(int8 param_1,ulong param_2,ushort *param_3,ushort *param_4)
{
ushort uVar1;
short sVar2;
int8 uVar3;
if ((int)param_2 < 0x80) {
uVar3 = 0xffffff9b;
if (param_3 < param_4) {
*(char *)param_3 = (char)param_2;
return 1;
}
}
else {
uVar3 = 0;
if (param_2 < 0x10000) {
uVar1 = *(ushort *)(unicode_to_jisx0208_eucjp + param_2 * 2);
if (uVar1 == 0) {
sVar2 = *(short *)(unicode_to_jisx0212_eucjp + param_2 * 2);
if (sVar2 == 0) {
if ((param_2 - 0xff61 < 0x3f) && (uVar3 = 0xffffff9a, param_3 + 1 <= param_4)) {
*(char *)param_3 = -0x72;
*(char *)((long)param_3 + 1) = (char)param_2 + '@';
uVar3 = 2;
}
}
else {
uVar3 = 0xffffff99;
if ((ushort *)((long)param_3 + 3) <= param_4) {
*(char *)param_3 = -0x71;
*(char *)((long)param_3 + 1) = (char)((ushort)sVar2 >> 8);
*(char *)(param_3 + 1) = (char)sVar2;
uVar3 = 3;
}
}
return uVar3;
}
uVar3 = 0xffffff9a;
if (param_3 + 1 <= param_4) {
*param_3 = uVar1 << 8 | uVar1 >> 8;
uVar3 = 2;
}
}
}
return uVar3;
}
| |
22,130 | c4_verify_blockroot_signature | corpus-core[P]colibri-stateless/src/chains/eth/verifier/verify_blockhash_proof.c | c4_status_t c4_verify_blockroot_signature(verify_ctx_t* ctx, ssz_ob_t* header, ssz_ob_t* sync_committee_bits, ssz_ob_t* sync_committee_signature, uint64_t slot) {
bytes32_t root = {0};
c4_sync_state_t sync_state = {0};
if (slot == 0) slot = ssz_get_uint64(header, "slot") + 1;
if (slot == 0) THROW_ERROR("slot is missing in beacon header!");
// get the validators and make sure we have the right ones for the requested period
TRY_ASYNC(c4_get_validators(ctx, slot >> 13, &sync_state));
// compute blockhash
ssz_hash_tree_root(*header, root);
// compute signing message and store it in root again
calculate_signing_message(ctx, slot, root, root);
// verify the signature
bool valid = blst_verify(root, sync_committee_signature->bytes.data, sync_state.validators.data, 512, sync_committee_bits->bytes, sync_state.deserialized);
#ifndef C4_STATIC_MEMORY
safe_free(sync_state.validators.data);
#endif
if (!valid)
THROW_ERROR("invalid blockhash signature!");
return C4_SUCCESS;
} | O0 | c | c4_verify_blockroot_signature:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
leaq -0x50(%rbp), %rdi
xorl %esi, %esi
movl $0x20, %edx
callq 0x231c0
leaq -0x70(%rbp), %rdi
xorl %esi, %esi
movl $0x20, %edx
callq 0x231c0
cmpq $0x0, -0x30(%rbp)
jne 0x2ff1e
movq -0x18(%rbp), %rdi
leaq 0xac787(%rip), %rsi # 0xdc698
callq 0x30020
addq $0x1, %rax
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
jne 0x2ff41
movq -0x10(%rbp), %rdi
addq $0x70, %rdi
leaq 0xadc24(%rip), %rsi # 0xddb58
callq 0xa79c0
movl %eax, -0x4(%rbp)
jmp 0x3000f
jmp 0x2ff43
movq -0x10(%rbp), %rdi
movq -0x30(%rbp), %rax
shrq $0xd, %rax
movl %eax, %esi
leaq -0x70(%rbp), %rdx
callq 0x26e90
movl %eax, -0x74(%rbp)
cmpl $0x0, -0x74(%rbp)
je 0x2ff6e
movl -0x74(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x3000f
jmp 0x2ff70
movq -0x18(%rbp), %rax
leaq -0x50(%rbp), %rdi
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0xa20a0
movq -0x10(%rbp), %rdi
movq -0x30(%rbp), %rsi
leaq -0x50(%rbp), %rdx
leaq -0x50(%rbp), %rcx
callq 0x30070
leaq -0x50(%rbp), %rdi
movq -0x28(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x60(%rbp), %rdx
movq -0x20(%rbp), %rcx
movb -0x58(%rbp), %al
movl (%rcx), %r8d
movq 0x8(%rcx), %r9
movl $0x200, %ecx # imm = 0x200
andb $0x1, %al
movzbl %al, %eax
movl %eax, (%rsp)
callq 0xa4b10
andb $0x1, %al
movb %al, -0x75(%rbp)
movq -0x60(%rbp), %rdi
callq 0x9dbf0
testb $0x1, -0x75(%rbp)
jne 0x30008
movq -0x10(%rbp), %rdi
addq $0x70, %rdi
leaq 0xadb7c(%rip), %rsi # 0xddb7a
callq 0xa79c0
movl %eax, -0x4(%rbp)
jmp 0x3000f
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x90, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| c4_verify_blockroot_signature:
push rbp
mov rbp, rsp
sub rsp, 90h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov [rbp+var_30], r8
lea rdi, [rbp+var_50]
xor esi, esi
mov edx, 20h ; ' '
call _memset
lea rdi, [rbp+var_70]
xor esi, esi
mov edx, 20h ; ' '
call _memset
cmp [rbp+var_30], 0
jnz short loc_2FF1E
mov rdi, [rbp+var_18]
lea rsi, aSlot; "slot"
call ssz_get_uint64_3
add rax, 1
mov [rbp+var_30], rax
loc_2FF1E:
cmp [rbp+var_30], 0
jnz short loc_2FF41
mov rdi, [rbp+var_10]
add rdi, 70h ; 'p'
lea rsi, aSlotIsMissingI; "slot is missing in beacon header!"
call c4_state_add_error
mov [rbp+var_4], eax
jmp loc_3000F
loc_2FF41:
jmp short $+2
loc_2FF43:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_30]
shr rax, 0Dh
mov esi, eax
lea rdx, [rbp+var_70]
call c4_get_validators
mov [rbp+var_74], eax
cmp [rbp+var_74], 0
jz short loc_2FF6E
mov eax, [rbp+var_74]
mov [rbp+var_4], eax
jmp loc_3000F
loc_2FF6E:
jmp short $+2
loc_2FF70:
mov rax, [rbp+var_18]
lea rdi, [rbp+var_50]
mov rcx, [rax]
mov [rsp+90h+var_90], rcx
mov rcx, [rax+8]
mov [rsp+90h+var_88], rcx
mov rax, [rax+10h]
mov [rsp+90h+var_80], rax
call ssz_hash_tree_root
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_30]
lea rdx, [rbp+var_50]
lea rcx, [rbp+var_50]
call calculate_signing_message
lea rdi, [rbp+var_50]
mov rax, [rbp+var_28]
mov rsi, [rax+8]
mov rdx, [rbp+var_60]
mov rcx, [rbp+var_20]
mov al, [rbp+var_58]
mov r8d, [rcx]
mov r9, [rcx+8]
mov ecx, 200h
and al, 1
movzx eax, al
mov dword ptr [rsp+90h+var_90], eax
call blst_verify
and al, 1
mov [rbp+var_75], al
mov rdi, [rbp+var_60]
call safe_free
test [rbp+var_75], 1
jnz short loc_30008
mov rdi, [rbp+var_10]
add rdi, 70h ; 'p'
lea rsi, aInvalidBlockha_1; "invalid blockhash signature!"
call c4_state_add_error
loc_30003:
mov [rbp+var_4], eax
jmp short loc_3000F
loc_30008:
mov [rbp+var_4], 0
loc_3000F:
mov eax, [rbp+var_4]
add rsp, 90h
pop rbp
retn
| long long c4_verify_blockroot_signature(long long a1, _QWORD *a2, long long a3, long long a4, unsigned long long a5)
{
unsigned int v5; // esi
int v6; // edx
int v7; // r8d
int v8; // r9d
int v10; // [rsp+1Bh] [rbp-75h]
unsigned int validators; // [rsp+1Ch] [rbp-74h]
_QWORD v12[2]; // [rsp+20h] [rbp-70h] BYREF
long long v13; // [rsp+30h] [rbp-60h]
char v14; // [rsp+38h] [rbp-58h]
_BYTE v15[32]; // [rsp+40h] [rbp-50h] BYREF
unsigned long long v16; // [rsp+60h] [rbp-30h]
long long v17; // [rsp+68h] [rbp-28h]
long long v18; // [rsp+70h] [rbp-20h]
_QWORD *v19; // [rsp+78h] [rbp-18h]
long long v20; // [rsp+80h] [rbp-10h]
v20 = a1;
v19 = a2;
v18 = a3;
v17 = a4;
v16 = a5;
memset(v15, 0LL, sizeof(v15));
memset(v12, 0LL, 32LL);
if ( !v16 )
v16 = ssz_get_uint64_3(v19, "slot") + 1;
if ( v16 )
{
v5 = v16 >> 13;
validators = c4_get_validators(v20, v5, v12);
if ( validators )
{
return validators;
}
else
{
ssz_hash_tree_root((unsigned int)v15, v5, v6, v19[1], v7, v8, *v19, v19[1], v19[2]);
calculate_signing_message(v20, v16, v15, v15);
v10 = blst_verify(
(unsigned int)v15,
*(_QWORD *)(v17 + 8),
v13,
512,
*(_DWORD *)v18,
*(_QWORD *)(v18 + 8),
v14 & 1) & 1;
safe_free(v13);
if ( (v10 & 1) != 0 )
return 0;
else
return (unsigned int)c4_state_add_error(v20 + 112, "invalid blockhash signature!");
}
}
else
{
return (unsigned int)c4_state_add_error(v20 + 112, "slot is missing in beacon header!");
}
}
| c4_verify_blockroot_signature:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV qword ptr [RBP + -0x30],R8
LEA RDI,[RBP + -0x50]
XOR ESI,ESI
MOV EDX,0x20
CALL 0x001231c0
LEA RDI,[RBP + -0x70]
XOR ESI,ESI
MOV EDX,0x20
CALL 0x001231c0
CMP qword ptr [RBP + -0x30],0x0
JNZ 0x0012ff1e
MOV RDI,qword ptr [RBP + -0x18]
LEA RSI,[0x1dc698]
CALL 0x00130020
ADD RAX,0x1
MOV qword ptr [RBP + -0x30],RAX
LAB_0012ff1e:
CMP qword ptr [RBP + -0x30],0x0
JNZ 0x0012ff41
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x70
LEA RSI,[0x1ddb58]
CALL 0x001a79c0
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0013000f
LAB_0012ff41:
JMP 0x0012ff43
LAB_0012ff43:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x30]
SHR RAX,0xd
MOV ESI,EAX
LEA RDX,[RBP + -0x70]
CALL 0x00126e90
MOV dword ptr [RBP + -0x74],EAX
CMP dword ptr [RBP + -0x74],0x0
JZ 0x0012ff6e
MOV EAX,dword ptr [RBP + -0x74]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0013000f
LAB_0012ff6e:
JMP 0x0012ff70
LAB_0012ff70:
MOV RAX,qword ptr [RBP + -0x18]
LEA RDI,[RBP + -0x50]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP],RCX
MOV RCX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x001a20a0
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x30]
LEA RDX,[RBP + -0x50]
LEA RCX,[RBP + -0x50]
CALL 0x00130070
LEA RDI,[RBP + -0x50]
MOV RAX,qword ptr [RBP + -0x28]
MOV RSI,qword ptr [RAX + 0x8]
MOV RDX,qword ptr [RBP + -0x60]
MOV RCX,qword ptr [RBP + -0x20]
MOV AL,byte ptr [RBP + -0x58]
MOV R8D,dword ptr [RCX]
MOV R9,qword ptr [RCX + 0x8]
MOV ECX,0x200
AND AL,0x1
MOVZX EAX,AL
MOV dword ptr [RSP],EAX
CALL 0x001a4b10
AND AL,0x1
MOV byte ptr [RBP + -0x75],AL
MOV RDI,qword ptr [RBP + -0x60]
CALL 0x0019dbf0
TEST byte ptr [RBP + -0x75],0x1
JNZ 0x00130008
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x70
LEA RSI,[0x1ddb7a]
CALL 0x001a79c0
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0013000f
LAB_00130008:
MOV dword ptr [RBP + -0x4],0x0
LAB_0013000f:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x90
POP RBP
RET
|
int c4_verify_blockroot_signature
(long param_1,int8 *param_2,int4 *param_3,long param_4,ulong param_5)
{
byte bVar1;
long lVar2;
int4 uVar3;
int8 uVar4;
int8 uVar5;
int1 local_78 [16];
int8 local_68;
byte local_60;
int1 local_58 [32];
ulong local_38;
long local_30;
int4 *local_28;
int8 *local_20;
long local_18;
int local_c;
local_38 = param_5;
local_30 = param_4;
local_28 = param_3;
local_20 = param_2;
local_18 = param_1;
memset(local_58,0,0x20);
memset(local_78,0,0x20);
if (local_38 == 0) {
lVar2 = ssz_get_uint64(local_20,&DAT_001dc698);
local_38 = lVar2 + 1;
}
if (local_38 == 0) {
local_c = c4_state_add_error(local_18 + 0x70,"slot is missing in beacon header!");
}
else {
local_c = c4_get_validators(local_18,local_38 >> 0xd & 0xffffffff,local_78);
if (local_c == 0) {
uVar3 = (int4)((ulong)*local_20 >> 0x20);
uVar4 = local_20[1];
uVar5 = local_20[2];
ssz_hash_tree_root(local_58);
calculate_signing_message(local_18,local_38,local_58,local_58);
bVar1 = blst_verify(local_58,*(int8 *)(local_30 + 8),local_68,0x200,*local_28,
*(int8 *)(local_28 + 2),CONCAT44(uVar3,(uint)(local_60 & 1)),uVar4,
uVar5);
safe_free(local_68);
if ((bVar1 & 1) == 0) {
local_c = c4_state_add_error(local_18 + 0x70,"invalid blockhash signature!");
}
else {
local_c = 0;
}
}
}
return local_c;
}
| |
22,131 | c4_verify_blockroot_signature | corpus-core[P]colibri-stateless/src/chains/eth/verifier/verify_blockhash_proof.c | c4_status_t c4_verify_blockroot_signature(verify_ctx_t* ctx, ssz_ob_t* header, ssz_ob_t* sync_committee_bits, ssz_ob_t* sync_committee_signature, uint64_t slot) {
bytes32_t root = {0};
c4_sync_state_t sync_state = {0};
if (slot == 0) slot = ssz_get_uint64(header, "slot") + 1;
if (slot == 0) THROW_ERROR("slot is missing in beacon header!");
// get the validators and make sure we have the right ones for the requested period
TRY_ASYNC(c4_get_validators(ctx, slot >> 13, &sync_state));
// compute blockhash
ssz_hash_tree_root(*header, root);
// compute signing message and store it in root again
calculate_signing_message(ctx, slot, root, root);
// verify the signature
bool valid = blst_verify(root, sync_committee_signature->bytes.data, sync_state.validators.data, 512, sync_committee_bits->bytes, sync_state.deserialized);
#ifndef C4_STATIC_MEMORY
safe_free(sync_state.validators.data);
#endif
if (!valid)
THROW_ERROR("invalid blockhash signature!");
return C4_SUCCESS;
} | O2 | c | c4_verify_blockroot_signature:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %r8, %r12
movq %rcx, %r15
movq %rdx, %r14
movq %rsi, %r13
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, 0x70(%rsp)
movaps %xmm0, 0x60(%rsp)
movaps %xmm0, 0x30(%rsp)
movaps %xmm0, 0x20(%rsp)
testq %r8, %r8
jne 0x2a35c
leaq 0x4a2e9(%rip), %rdx # 0x74610
leaq 0x80(%rsp), %r12
movq %r12, %rdi
movq %r13, %rsi
callq 0x4d119
movl (%r12), %edi
movq 0x8(%r12), %rsi
callq 0x4bbb5
movq %rax, %r12
incq %r12
jne 0x2a35c
leaq 0x4b623(%rip), %rsi # 0x7597a
jmp 0x2a43f
movq %r12, %rsi
shrq $0xd, %rsi
leaq 0x20(%rsp), %rdx
movq %rbx, %rdi
callq 0x24e75
testl %eax, %eax
jne 0x2a44b
movq 0x10(%r13), %rax
movq %rax, 0x10(%rsp)
movups (%r13), %xmm0
movups %xmm0, (%rsp)
leaq 0x60(%rsp), %r13
movq %r13, %rdi
callq 0x4d3f1
leaq 0xa0(%rsp), %rdx
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rdx)
movaps %xmm0, (%rdx)
movaps (%r13), %xmm0
movaps 0x10(%r13), %xmm1
movaps %xmm0, -0x20(%rdx)
movaps %xmm1, -0x10(%rdx)
movl 0x80(%rbx), %edi
movq %r12, %rsi
callq 0x2a238
movl $0x40, 0x48(%rsp)
leaq 0x80(%rsp), %rax
movq %rax, 0x50(%rsp)
leaq 0x7e8cb(%rip), %rax # 0xa8cb0
movq %rax, 0x58(%rsp)
movq %rax, 0x10(%rsp)
movups 0x48(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %r13, %rdi
callq 0x4d3f1
movq 0x8(%r15), %rsi
movq 0x30(%rsp), %rdx
movzbl 0x38(%rsp), %eax
movl (%r14), %r8d
movq 0x8(%r14), %r9
movl %eax, (%rsp)
movq %r13, %rdi
movl $0x200, %ecx # imm = 0x200
callq 0x4ed14
movl %eax, %ebp
movq 0x30(%rsp), %rdi
callq 0x4aff8
xorl %eax, %eax
testb %bpl, %bpl
jne 0x2a44b
leaq 0x4b55d(%rip), %rsi # 0x7599c
addq $0x70, %rbx
movq %rbx, %rdi
callq 0x50675
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| c4_verify_blockroot_signature:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0C8h
mov r12, r8
mov r15, rcx
mov r14, rdx
mov r13, rsi
mov rbx, rdi
xorps xmm0, xmm0
movaps [rsp+0F8h+var_88], xmm0
movaps [rsp+0F8h+var_98], xmm0
movaps [rsp+0F8h+var_C8], xmm0
movaps [rsp+0F8h+var_D8], xmm0
test r8, r8
jnz short loc_2A35C
lea rdx, aSlot; "slot"
lea r12, [rsp+0F8h+var_78]
mov rdi, r12
mov rsi, r13
call ssz_get
mov edi, [r12]
mov rsi, [r12+8]
call bytes_as_le
mov r12, rax
inc r12
jnz short loc_2A35C
lea rsi, aSlotIsMissingI; "slot is missing in beacon header!"
jmp loc_2A43F
loc_2A35C:
mov rsi, r12
shr rsi, 0Dh
lea rdx, [rsp+0F8h+var_D8]
mov rdi, rbx
call c4_get_validators
test eax, eax
jnz loc_2A44B
mov rax, [r13+10h]
mov [rsp+0F8h+var_E8], rax
movups xmm0, xmmword ptr [r13+0]
movups [rsp+0F8h+var_F8], xmm0
lea r13, [rsp+0F8h+var_98]
mov rdi, r13
call ssz_hash_tree_root
lea rdx, [rsp+0F8h+var_58]
xorps xmm0, xmm0
movaps xmmword ptr [rdx+10h], xmm0
movaps xmmword ptr [rdx], xmm0
movaps xmm0, xmmword ptr [r13+0]
movaps xmm1, xmmword ptr [r13+10h]
movaps xmmword ptr [rdx-20h], xmm0
movaps xmmword ptr [rdx-10h], xmm1
mov edi, [rbx+80h]
mov rsi, r12
call eth_calculate_domain
mov dword ptr [rsp+0F8h+var_B0], 40h ; '@'
lea rax, [rsp+0F8h+var_78]
mov qword ptr [rsp+0F8h+var_B0+8], rax
lea rax, SIGNING_DATA_CONTAINER
mov [rsp+0F8h+var_A0], rax
mov [rsp+0F8h+var_E8], rax
movups xmm0, [rsp+0F8h+var_B0]
movups [rsp+0F8h+var_F8], xmm0
mov rdi, r13
call ssz_hash_tree_root
mov rsi, [r15+8]
mov rdx, qword ptr [rsp+0F8h+var_C8]
movzx eax, byte ptr [rsp+0F8h+var_C8+8]
mov r8d, [r14]
mov r9, [r14+8]
mov dword ptr [rsp+0F8h+var_F8], eax
mov rdi, r13
mov ecx, 200h
call blst_verify
mov ebp, eax
mov rdi, qword ptr [rsp+0F8h+var_C8]
call safe_free
xor eax, eax
test bpl, bpl
jnz short loc_2A44B
lea rsi, aInvalidBlockha_1; "invalid blockhash signature!"
loc_2A43F:
add rbx, 70h ; 'p'
mov rdi, rbx
call c4_state_add_error
loc_2A44B:
add rsp, 0C8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long c4_verify_blockroot_signature(long long a1, _QWORD *a2, long long a3, long long a4, unsigned long long a5)
{
unsigned long long v5; // r12
long long v8; // rax
const char *v9; // rsi
long long result; // rax
long long v11; // rdx
long long v12; // rcx
long long v13; // r8
long long v14; // r9
long long v15; // rdx
long long v16; // rcx
long long v17; // r8
long long v18; // r9
char v19; // bp
__int128 v20; // [rsp+20h] [rbp-D8h] BYREF
__int128 v21; // [rsp+30h] [rbp-C8h]
long long v22; // [rsp+48h] [rbp-B0h]
_OWORD *v23; // [rsp+50h] [rbp-A8h]
char **v24; // [rsp+58h] [rbp-A0h]
__int128 v25; // [rsp+60h] [rbp-98h] BYREF
__int128 v26; // [rsp+70h] [rbp-88h]
_OWORD v27[2]; // [rsp+80h] [rbp-78h] BYREF
_BYTE v28[88]; // [rsp+A0h] [rbp-58h] BYREF
v5 = a5;
v26 = 0LL;
v25 = 0LL;
v21 = 0LL;
v20 = 0LL;
if ( !a5 )
{
ssz_get(v27, a2, "slot");
v8 = bytes_as_le(LODWORD(v27[0]));
v5 = v8 + 1;
if ( v8 == -1 )
{
v9 = "slot is missing in beacon header!";
return c4_state_add_error(a1 + 112, v9);
}
}
result = c4_get_validators(a1, v5 >> 13, &v20);
if ( !(_DWORD)result )
{
ssz_hash_tree_root(&v25, v5 >> 13, v11, v12, v13, v14, *a2, a2[1], a2[2]);
memset(v28, 0, 32);
v27[0] = v25;
v27[1] = v26;
eth_calculate_domain(*(unsigned int *)(a1 + 128), v5, (long long)v28);
LODWORD(v22) = 64;
v23 = v27;
v24 = &SIGNING_DATA_CONTAINER;
ssz_hash_tree_root(&v25, v5, v15, v16, v17, v18, v22, v27, &SIGNING_DATA_CONTAINER);
v19 = blst_verify(
(unsigned int)&v25,
*(_QWORD *)(a4 + 8),
v21,
512,
*(_DWORD *)a3,
*(_QWORD *)(a3 + 8),
SBYTE8(v21));
safe_free(v21);
result = 0LL;
if ( !v19 )
{
v9 = "invalid blockhash signature!";
return c4_state_add_error(a1 + 112, v9);
}
}
return result;
}
| c4_verify_blockroot_signature:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xc8
MOV R12,R8
MOV R15,RCX
MOV R14,RDX
MOV R13,RSI
MOV RBX,RDI
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP + 0x70],XMM0
MOVAPS xmmword ptr [RSP + 0x60],XMM0
MOVAPS xmmword ptr [RSP + 0x30],XMM0
MOVAPS xmmword ptr [RSP + 0x20],XMM0
TEST R8,R8
JNZ 0x0012a35c
LEA RDX,[0x174610]
LEA R12,[RSP + 0x80]
MOV RDI,R12
MOV RSI,R13
CALL 0x0014d119
MOV EDI,dword ptr [R12]
MOV RSI,qword ptr [R12 + 0x8]
CALL 0x0014bbb5
MOV R12,RAX
INC R12
JNZ 0x0012a35c
LEA RSI,[0x17597a]
JMP 0x0012a43f
LAB_0012a35c:
MOV RSI,R12
SHR RSI,0xd
LEA RDX,[RSP + 0x20]
MOV RDI,RBX
CALL 0x00124e75
TEST EAX,EAX
JNZ 0x0012a44b
MOV RAX,qword ptr [R13 + 0x10]
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [R13]
MOVUPS xmmword ptr [RSP],XMM0
LEA R13,[RSP + 0x60]
MOV RDI,R13
CALL 0x0014d3f1
LEA RDX,[RSP + 0xa0]
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RDX + 0x10],XMM0
MOVAPS xmmword ptr [RDX],XMM0
MOVAPS XMM0,xmmword ptr [R13]
MOVAPS XMM1,xmmword ptr [R13 + 0x10]
MOVAPS xmmword ptr [RDX + -0x20],XMM0
MOVAPS xmmword ptr [RDX + -0x10],XMM1
MOV EDI,dword ptr [RBX + 0x80]
MOV RSI,R12
CALL 0x0012a238
MOV dword ptr [RSP + 0x48],0x40
LEA RAX,[RSP + 0x80]
MOV qword ptr [RSP + 0x50],RAX
LEA RAX,[0x1a8cb0]
MOV qword ptr [RSP + 0x58],RAX
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [RSP + 0x48]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,R13
CALL 0x0014d3f1
MOV RSI,qword ptr [R15 + 0x8]
MOV RDX,qword ptr [RSP + 0x30]
MOVZX EAX,byte ptr [RSP + 0x38]
MOV R8D,dword ptr [R14]
MOV R9,qword ptr [R14 + 0x8]
MOV dword ptr [RSP],EAX
MOV RDI,R13
MOV ECX,0x200
CALL 0x0014ed14
MOV EBP,EAX
MOV RDI,qword ptr [RSP + 0x30]
CALL 0x0014aff8
XOR EAX,EAX
TEST BPL,BPL
JNZ 0x0012a44b
LEA RSI,[0x17599c]
LAB_0012a43f:
ADD RBX,0x70
MOV RDI,RBX
CALL 0x00150675
LAB_0012a44b:
ADD RSP,0xc8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8
c4_verify_blockroot_signature
(long param_1,int8 param_2,int4 *param_3,long param_4,ulong param_5)
{
char cVar1;
long lVar2;
int8 uVar3;
char *pcVar4;
int4 uVar5;
int1 *puVar6;
int8 local_d8;
int8 uStack_d0;
int8 local_c8;
int8 uStack_c0;
int4 local_b0;
int4 *puStack_a8;
int1 *local_a0;
int8 local_98;
int8 uStack_90;
int8 local_88;
int8 uStack_80;
int4 local_78;
int4 uStack_74;
int4 uStack_70;
int4 uStack_6c;
int4 local_68;
int4 uStack_64;
int4 uStack_60;
int4 uStack_5c;
int8 local_58;
int8 uStack_50;
int8 local_48;
int8 uStack_40;
local_88 = 0;
uStack_80 = 0;
local_98 = 0;
uStack_90 = 0;
local_c8 = 0;
uStack_c0 = 0;
local_d8 = 0;
uStack_d0 = 0;
if (param_5 == 0) {
ssz_get(&local_78,param_2,&DAT_00174610);
lVar2 = bytes_as_le(local_78,CONCAT44(uStack_6c,uStack_70));
param_5 = lVar2 + 1;
if (param_5 == 0) {
pcVar4 = "slot is missing in beacon header!";
goto LAB_0012a43f;
}
}
uVar3 = c4_get_validators(param_1,param_5 >> 0xd,&local_d8);
if ((int)uVar3 != 0) {
return uVar3;
}
ssz_hash_tree_root(&local_98);
local_48 = 0;
uStack_40 = 0;
local_58 = 0;
uStack_50 = 0;
local_78 = (int4)local_98;
uStack_74 = local_98._4_4_;
uStack_70 = (int4)uStack_90;
uStack_6c = uStack_90._4_4_;
local_68 = (int4)local_88;
uStack_64 = local_88._4_4_;
uStack_60 = (int4)uStack_80;
uStack_5c = uStack_80._4_4_;
eth_calculate_domain(*(int4 *)(param_1 + 0x80),param_5);
local_b0 = 0x40;
puStack_a8 = &local_78;
local_a0 = SIGNING_DATA_CONTAINER;
puVar6 = SIGNING_DATA_CONTAINER;
uVar5 = puStack_a8._0_4_;
ssz_hash_tree_root(&local_98);
cVar1 = blst_verify(&local_98,*(int8 *)(param_4 + 8),local_c8,0x200,*param_3,
*(int8 *)(param_3 + 2),(int1)uStack_c0,uVar5,puVar6);
safe_free(local_c8);
if (cVar1 != '\0') {
return 0;
}
pcVar4 = "invalid blockhash signature!";
LAB_0012a43f:
uVar3 = c4_state_add_error(param_1 + 0x70,pcVar4);
return uVar3;
}
| |
22,132 | c4_verify_blockroot_signature | corpus-core[P]colibri-stateless/src/chains/eth/verifier/verify_blockhash_proof.c | c4_status_t c4_verify_blockroot_signature(verify_ctx_t* ctx, ssz_ob_t* header, ssz_ob_t* sync_committee_bits, ssz_ob_t* sync_committee_signature, uint64_t slot) {
bytes32_t root = {0};
c4_sync_state_t sync_state = {0};
if (slot == 0) slot = ssz_get_uint64(header, "slot") + 1;
if (slot == 0) THROW_ERROR("slot is missing in beacon header!");
// get the validators and make sure we have the right ones for the requested period
TRY_ASYNC(c4_get_validators(ctx, slot >> 13, &sync_state));
// compute blockhash
ssz_hash_tree_root(*header, root);
// compute signing message and store it in root again
calculate_signing_message(ctx, slot, root, root);
// verify the signature
bool valid = blst_verify(root, sync_committee_signature->bytes.data, sync_state.validators.data, 512, sync_committee_bits->bytes, sync_state.deserialized);
#ifndef C4_STATIC_MEMORY
safe_free(sync_state.validators.data);
#endif
if (!valid)
THROW_ERROR("invalid blockhash signature!");
return C4_SUCCESS;
} | O3 | c | c4_verify_blockroot_signature:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %r8, %r12
movq %rcx, %r15
movq %rdx, %r14
movq %rsi, %r13
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, 0x70(%rsp)
movaps %xmm0, 0x60(%rsp)
movaps %xmm0, 0x30(%rsp)
movaps %xmm0, 0x20(%rsp)
testq %r8, %r8
jne 0x2b6d3
leaq 0x55f72(%rip), %rdx # 0x81610
leaq 0x80(%rsp), %r12
movq %r12, %rdi
movq %r13, %rsi
callq 0x5525d
movl (%r12), %edi
movq 0x8(%r12), %rsi
callq 0x53c76
movq %rax, %r12
incq %r12
jne 0x2b6d3
leaq 0x572ac(%rip), %rsi # 0x8297a
jmp 0x2b7b6
movq %r12, %rsi
shrq $0xd, %rsi
leaq 0x20(%rsp), %rdx
movq %rbx, %rdi
callq 0x25bec
testl %eax, %eax
jne 0x2b7c2
movq 0x10(%r13), %rax
movq %rax, 0x10(%rsp)
movups (%r13), %xmm0
movups %xmm0, (%rsp)
leaq 0x60(%rsp), %r13
movq %r13, %rdi
callq 0x554e2
movl 0x80(%rbx), %edi
leaq 0xa0(%rsp), %rdx
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rdx)
movaps %xmm0, (%rdx)
movaps (%r13), %xmm0
movaps 0x10(%r13), %xmm1
movaps %xmm0, -0x20(%rdx)
movaps %xmm1, -0x10(%rdx)
movq %r12, %rsi
callq 0x2b5ac
movl $0x40, 0x48(%rsp)
leaq 0x80(%rsp), %rax
movq %rax, 0x50(%rsp)
leaq 0x82554(%rip), %rax # 0xadcb0
movq %rax, 0x58(%rsp)
movq %rax, 0x10(%rsp)
movups 0x48(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %r13, %rdi
callq 0x554e2
movq 0x8(%r15), %rsi
movq 0x30(%rsp), %rdx
movzbl 0x38(%rsp), %eax
movl (%r14), %r8d
movq 0x8(%r14), %r9
movl %eax, (%rsp)
movq %r13, %rdi
movl $0x200, %ecx # imm = 0x200
callq 0x56eb3
movl %eax, %ebp
movq 0x30(%rsp), %rdi
callq 0x52f98
xorl %eax, %eax
testb %bpl, %bpl
jne 0x2b7c2
leaq 0x571e6(%rip), %rsi # 0x8299c
addq $0x70, %rbx
movq %rbx, %rdi
callq 0x589cd
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| c4_verify_blockroot_signature:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0C8h
mov r12, r8
mov r15, rcx
mov r14, rdx
mov r13, rsi
mov rbx, rdi
xorps xmm0, xmm0
movaps [rsp+0F8h+var_88], xmm0
movaps [rsp+0F8h+var_98], xmm0
movaps [rsp+0F8h+var_C8], xmm0
movaps [rsp+0F8h+var_D8], xmm0
test r8, r8
jnz short loc_2B6D3
lea rdx, aSlot; "slot"
lea r12, [rsp+0F8h+var_78]
mov rdi, r12
mov rsi, r13
call ssz_get
mov edi, [r12]
mov rsi, [r12+8]
call bytes_as_le
mov r12, rax
inc r12
jnz short loc_2B6D3
lea rsi, aSlotIsMissingI; "slot is missing in beacon header!"
jmp loc_2B7B6
loc_2B6D3:
mov rsi, r12
shr rsi, 0Dh
lea rdx, [rsp+0F8h+var_D8]
mov rdi, rbx
call c4_get_validators
test eax, eax
jnz loc_2B7C2
mov rax, [r13+10h]
mov [rsp+0F8h+var_E8], rax
movups xmm0, xmmword ptr [r13+0]
movups [rsp+0F8h+var_F8], xmm0
lea r13, [rsp+0F8h+var_98]
mov rdi, r13
call ssz_hash_tree_root
mov edi, [rbx+80h]
lea rdx, [rsp+0F8h+var_58]
xorps xmm0, xmm0
movaps xmmword ptr [rdx+10h], xmm0
movaps xmmword ptr [rdx], xmm0
movaps xmm0, xmmword ptr [r13+0]
movaps xmm1, xmmword ptr [r13+10h]
movaps xmmword ptr [rdx-20h], xmm0
movaps xmmword ptr [rdx-10h], xmm1
mov rsi, r12
call eth_calculate_domain
mov dword ptr [rsp+0F8h+var_B0], 40h ; '@'
lea rax, [rsp+0F8h+var_78]
mov qword ptr [rsp+0F8h+var_B0+8], rax
lea rax, SIGNING_DATA_CONTAINER
mov [rsp+0F8h+var_A0], rax
mov [rsp+0F8h+var_E8], rax
movups xmm0, [rsp+0F8h+var_B0]
movups [rsp+0F8h+var_F8], xmm0
mov rdi, r13
call ssz_hash_tree_root
mov rsi, [r15+8]
mov rdx, qword ptr [rsp+0F8h+var_C8]
movzx eax, byte ptr [rsp+0F8h+var_C8+8]
mov r8d, [r14]
mov r9, [r14+8]
mov dword ptr [rsp+0F8h+var_F8], eax
mov rdi, r13
mov ecx, 200h
call blst_verify
mov ebp, eax
mov rdi, qword ptr [rsp+0F8h+var_C8]
call safe_free
xor eax, eax
test bpl, bpl
jnz short loc_2B7C2
lea rsi, aInvalidBlockha_1; "invalid blockhash signature!"
loc_2B7B6:
add rbx, 70h ; 'p'
mov rdi, rbx
call c4_state_add_error
loc_2B7C2:
add rsp, 0C8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long c4_verify_blockroot_signature(long long a1, _QWORD *a2, long long a3, long long a4, unsigned long long a5)
{
unsigned long long v5; // r12
long long v9; // rax
const char *v10; // rsi
long long result; // rax
long long v12; // rdx
long long v13; // rcx
long long v14; // r8
long long v15; // r9
long long v16; // rdi
long long v17; // rdx
long long v18; // rcx
long long v19; // r8
long long v20; // r9
char v21; // bp
__int128 v22; // [rsp+20h] [rbp-D8h] BYREF
__int128 v23; // [rsp+30h] [rbp-C8h]
long long v24; // [rsp+48h] [rbp-B0h]
_OWORD *v25; // [rsp+50h] [rbp-A8h]
char **v26; // [rsp+58h] [rbp-A0h]
__int128 v27; // [rsp+60h] [rbp-98h] BYREF
__int128 v28; // [rsp+70h] [rbp-88h]
_OWORD v29[2]; // [rsp+80h] [rbp-78h] BYREF
_BYTE v30[88]; // [rsp+A0h] [rbp-58h] BYREF
v5 = a5;
v28 = 0LL;
v27 = 0LL;
v23 = 0LL;
v22 = 0LL;
if ( !a5 )
{
ssz_get(v29, a2, "slot");
v9 = bytes_as_le(LODWORD(v29[0]), *((_QWORD *)&v29[0] + 1));
v5 = v9 + 1;
if ( v9 == -1 )
{
v10 = "slot is missing in beacon header!";
return c4_state_add_error(a1 + 112, v10);
}
}
result = c4_get_validators(a1, v5 >> 13, &v22);
if ( !(_DWORD)result )
{
ssz_hash_tree_root(&v27, v5 >> 13, v12, v13, v14, v15, *a2, a2[1], a2[2]);
v16 = *(unsigned int *)(a1 + 128);
memset(v30, 0, 32);
v29[0] = v27;
v29[1] = v28;
eth_calculate_domain(v16, v5, (long long)v30);
LODWORD(v24) = 64;
v25 = v29;
v26 = &SIGNING_DATA_CONTAINER;
ssz_hash_tree_root(&v27, v5, v17, v18, v19, v20, v24, v29, &SIGNING_DATA_CONTAINER);
v21 = blst_verify(
(unsigned int)&v27,
*(_QWORD *)(a4 + 8),
v23,
512,
*(_DWORD *)a3,
*(_QWORD *)(a3 + 8),
SBYTE8(v23));
safe_free(v23);
result = 0LL;
if ( !v21 )
{
v10 = "invalid blockhash signature!";
return c4_state_add_error(a1 + 112, v10);
}
}
return result;
}
| c4_verify_blockroot_signature:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xc8
MOV R12,R8
MOV R15,RCX
MOV R14,RDX
MOV R13,RSI
MOV RBX,RDI
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RSP + 0x70],XMM0
MOVAPS xmmword ptr [RSP + 0x60],XMM0
MOVAPS xmmword ptr [RSP + 0x30],XMM0
MOVAPS xmmword ptr [RSP + 0x20],XMM0
TEST R8,R8
JNZ 0x0012b6d3
LEA RDX,[0x181610]
LEA R12,[RSP + 0x80]
MOV RDI,R12
MOV RSI,R13
CALL 0x0015525d
MOV EDI,dword ptr [R12]
MOV RSI,qword ptr [R12 + 0x8]
CALL 0x00153c76
MOV R12,RAX
INC R12
JNZ 0x0012b6d3
LEA RSI,[0x18297a]
JMP 0x0012b7b6
LAB_0012b6d3:
MOV RSI,R12
SHR RSI,0xd
LEA RDX,[RSP + 0x20]
MOV RDI,RBX
CALL 0x00125bec
TEST EAX,EAX
JNZ 0x0012b7c2
MOV RAX,qword ptr [R13 + 0x10]
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [R13]
MOVUPS xmmword ptr [RSP],XMM0
LEA R13,[RSP + 0x60]
MOV RDI,R13
CALL 0x001554e2
MOV EDI,dword ptr [RBX + 0x80]
LEA RDX,[RSP + 0xa0]
XORPS XMM0,XMM0
MOVAPS xmmword ptr [RDX + 0x10],XMM0
MOVAPS xmmword ptr [RDX],XMM0
MOVAPS XMM0,xmmword ptr [R13]
MOVAPS XMM1,xmmword ptr [R13 + 0x10]
MOVAPS xmmword ptr [RDX + -0x20],XMM0
MOVAPS xmmword ptr [RDX + -0x10],XMM1
MOV RSI,R12
CALL 0x0012b5ac
MOV dword ptr [RSP + 0x48],0x40
LEA RAX,[RSP + 0x80]
MOV qword ptr [RSP + 0x50],RAX
LEA RAX,[0x1adcb0]
MOV qword ptr [RSP + 0x58],RAX
MOV qword ptr [RSP + 0x10],RAX
MOVUPS XMM0,xmmword ptr [RSP + 0x48]
MOVUPS xmmword ptr [RSP],XMM0
MOV RDI,R13
CALL 0x001554e2
MOV RSI,qword ptr [R15 + 0x8]
MOV RDX,qword ptr [RSP + 0x30]
MOVZX EAX,byte ptr [RSP + 0x38]
MOV R8D,dword ptr [R14]
MOV R9,qword ptr [R14 + 0x8]
MOV dword ptr [RSP],EAX
MOV RDI,R13
MOV ECX,0x200
CALL 0x00156eb3
MOV EBP,EAX
MOV RDI,qword ptr [RSP + 0x30]
CALL 0x00152f98
XOR EAX,EAX
TEST BPL,BPL
JNZ 0x0012b7c2
LEA RSI,[0x18299c]
LAB_0012b7b6:
ADD RBX,0x70
MOV RDI,RBX
CALL 0x001589cd
LAB_0012b7c2:
ADD RSP,0xc8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8
c4_verify_blockroot_signature
(long param_1,int8 param_2,int4 *param_3,long param_4,ulong param_5)
{
char cVar1;
long lVar2;
int8 uVar3;
char *pcVar4;
int4 uVar5;
int1 *puVar6;
int8 local_d8;
int8 uStack_d0;
int8 local_c8;
int8 uStack_c0;
int4 local_b0;
int4 *puStack_a8;
int1 *local_a0;
int8 local_98;
int8 uStack_90;
int8 local_88;
int8 uStack_80;
int4 local_78;
int4 uStack_74;
int4 uStack_70;
int4 uStack_6c;
int4 local_68;
int4 uStack_64;
int4 uStack_60;
int4 uStack_5c;
int8 local_58;
int8 uStack_50;
int8 local_48;
int8 uStack_40;
local_88 = 0;
uStack_80 = 0;
local_98 = 0;
uStack_90 = 0;
local_c8 = 0;
uStack_c0 = 0;
local_d8 = 0;
uStack_d0 = 0;
if (param_5 == 0) {
ssz_get(&local_78,param_2,&DAT_00181610);
lVar2 = bytes_as_le(local_78,CONCAT44(uStack_6c,uStack_70));
param_5 = lVar2 + 1;
if (param_5 == 0) {
pcVar4 = "slot is missing in beacon header!";
goto LAB_0012b7b6;
}
}
uVar3 = c4_get_validators(param_1,param_5 >> 0xd,&local_d8);
if ((int)uVar3 != 0) {
return uVar3;
}
ssz_hash_tree_root(&local_98);
local_48 = 0;
uStack_40 = 0;
local_58 = 0;
uStack_50 = 0;
local_78 = (int4)local_98;
uStack_74 = local_98._4_4_;
uStack_70 = (int4)uStack_90;
uStack_6c = uStack_90._4_4_;
local_68 = (int4)local_88;
uStack_64 = local_88._4_4_;
uStack_60 = (int4)uStack_80;
uStack_5c = uStack_80._4_4_;
eth_calculate_domain(*(int4 *)(param_1 + 0x80),param_5);
local_b0 = 0x40;
puStack_a8 = &local_78;
local_a0 = SIGNING_DATA_CONTAINER;
puVar6 = SIGNING_DATA_CONTAINER;
uVar5 = puStack_a8._0_4_;
ssz_hash_tree_root(&local_98);
cVar1 = blst_verify(&local_98,*(int8 *)(param_4 + 8),local_c8,0x200,*param_3,
*(int8 *)(param_3 + 2),(int1)uStack_c0,uVar5,puVar6);
safe_free(local_c8);
if (cVar1 != '\0') {
return 0;
}
pcVar4 = "invalid blockhash signature!";
LAB_0012b7b6:
uVar3 = c4_state_add_error(param_1 + 0x70,pcVar4);
return uVar3;
}
| |
22,133 | google::protobuf::FileDescriptorTables::BuildLocationsByPath(std::pair<google::protobuf::FileDescriptorTables const*, google::protobuf::SourceCodeInfo const*>*) | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc | void FileDescriptorTables::BuildLocationsByPath(
std::pair<const FileDescriptorTables*, const SourceCodeInfo*>* p) {
for (int i = 0, len = p->second->location_size(); i < len; ++i) {
const SourceCodeInfo_Location* loc = &p->second->location().Get(i);
p->first->locations_by_path_[Join(loc->path(), ",")] = loc;
}
} | O0 | cpp | google::protobuf::FileDescriptorTables::BuildLocationsByPath(std::pair<google::protobuf::FileDescriptorTables const*, google::protobuf::SourceCodeInfo const*>*):
subq $0x68, %rsp
movq %rdi, 0x60(%rsp)
movl $0x0, 0x5c(%rsp)
movq 0x60(%rsp), %rax
movq 0x8(%rax), %rdi
callq 0x281dd0
movl %eax, 0x58(%rsp)
movl 0x5c(%rsp), %eax
cmpl 0x58(%rsp), %eax
jge 0x2424f0
movq 0x60(%rsp), %rax
movq 0x8(%rax), %rdi
callq 0x281de0
movq %rax, %rdi
movl 0x5c(%rsp), %esi
callq 0x281df0
movq %rax, 0x50(%rsp)
movq 0x50(%rsp), %rdi
movq %rdi, (%rsp)
movq 0x60(%rsp), %rax
movq (%rax), %rax
addq $0x100, %rax # imm = 0x100
movq %rax, 0x8(%rsp)
callq 0x281f10
movq %rax, %rsi
leaq 0x1ca34f(%rip), %rdx # 0x40c7da
leaq 0x30(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x281e40
movq 0x8(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0x281e10
movq %rax, 0x18(%rsp)
jmp 0x2424b0
movq 0x18(%rsp), %rax
movq (%rsp), %rcx
movq %rcx, (%rax)
leaq 0x30(%rsp), %rdi
callq 0x921e0
movl 0x5c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x5c(%rsp)
jmp 0x242433
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x28(%rsp)
movl %eax, 0x24(%rsp)
leaq 0x30(%rsp), %rdi
callq 0x921e0
jmp 0x2424f5
addq $0x68, %rsp
retq
movq 0x28(%rsp), %rdi
callq 0x90db0
nop
| _ZN6google8protobuf20FileDescriptorTables20BuildLocationsByPathEPSt4pairIPKS1_PKNS0_14SourceCodeInfoEE:
sub rsp, 68h
mov [rsp+68h+var_8], rdi
mov [rsp+68h+var_C], 0
mov rax, [rsp+68h+var_8]
mov rdi, [rax+8]; this
call _ZNK6google8protobuf14SourceCodeInfo13location_sizeEv; google::protobuf::SourceCodeInfo::location_size(void)
mov [rsp+68h+var_10], eax
loc_242433:
mov eax, [rsp+68h+var_C]
cmp eax, [rsp+68h+var_10]
jge loc_2424F0
mov rax, [rsp+68h+var_8]
mov rdi, [rax+8]; this
call _ZNK6google8protobuf14SourceCodeInfo8locationEv; google::protobuf::SourceCodeInfo::location(void)
mov rdi, rax
mov esi, [rsp+68h+var_C]
call _ZNK6google8protobuf16RepeatedPtrFieldINS0_23SourceCodeInfo_LocationEE3GetEi; google::protobuf::RepeatedPtrField<google::protobuf::SourceCodeInfo_Location>::Get(int)
mov [rsp+68h+var_18], rax
mov rdi, [rsp+68h+var_18]; this
mov [rsp+68h+var_68], rdi
mov rax, [rsp+68h+var_8]
mov rax, [rax]
add rax, 100h
mov [rsp+68h+var_60], rax
call _ZNK6google8protobuf23SourceCodeInfo_Location4pathEv; google::protobuf::SourceCodeInfo_Location::path(void)
mov rsi, rax
lea rdx, a050000007e0500_1+0B3h; ","
lea rdi, [rsp+68h+var_38]
mov [rsp+68h+var_58], rdi
call _ZN6google8protobuf4JoinINS0_13RepeatedFieldIiEEEENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_PKc; google::protobuf::Join<google::protobuf::RepeatedField<int>>(google::protobuf::RepeatedField<int> const&,char const*)
mov rdi, [rsp+68h+var_60]
mov rsi, [rsp+68h+var_58]
call _ZNSt13unordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPKN6google8protobuf23SourceCodeInfo_LocationESt4hashIS5_ESt8equal_toIS5_ESaISt4pairIKS5_SA_EEEixEOS5_; std::unordered_map<std::string,google::protobuf::SourceCodeInfo_Location const*>::operator[](std::string&&)
mov [rsp+68h+var_50], rax
jmp short $+2
loc_2424B0:
mov rax, [rsp+68h+var_50]
mov rcx, [rsp+68h+var_68]
mov [rax], rcx
lea rdi, [rsp+68h+var_38]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov eax, [rsp+68h+var_C]
add eax, 1
mov [rsp+68h+var_C], eax
jmp loc_242433
mov rcx, rax
mov eax, edx
mov [rsp+arg_20], rcx
mov [rsp+arg_1C], eax
lea rdi, [rsp+arg_28]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_2424F5
loc_2424F0:
add rsp, 68h
retn
loc_2424F5:
mov rdi, [rsp+arg_20]
call __Unwind_Resume
| long long google::protobuf::FileDescriptorTables::BuildLocationsByPath(long long a1)
{
long long result; // rax
long long v2; // rax
int v3; // eax
int v4; // ecx
int v5; // r8d
int v6; // r9d
int v7; // [rsp+0h] [rbp-68h]
long long v8; // [rsp+0h] [rbp-68h]
long long v9; // [rsp+8h] [rbp-60h]
long long v10; // [rsp+8h] [rbp-60h]
long long v11; // [rsp+10h] [rbp-58h]
_QWORD *v12; // [rsp+18h] [rbp-50h]
int v13; // [rsp+20h] [rbp-48h]
int v14; // [rsp+28h] [rbp-40h]
long long v15[4]; // [rsp+30h] [rbp-38h] BYREF
google::protobuf::SourceCodeInfo_Location *v16; // [rsp+50h] [rbp-18h]
int v17; // [rsp+58h] [rbp-10h]
unsigned int v18; // [rsp+5Ch] [rbp-Ch]
long long v19; // [rsp+60h] [rbp-8h]
v19 = a1;
v18 = 0;
v17 = google::protobuf::SourceCodeInfo::location_size(*(google::protobuf::SourceCodeInfo **)(a1 + 8));
while ( 1 )
{
result = v18;
if ( (int)v18 >= v17 )
break;
v2 = google::protobuf::SourceCodeInfo::location(*(google::protobuf::SourceCodeInfo **)(v19 + 8));
v16 = (google::protobuf::SourceCodeInfo_Location *)google::protobuf::RepeatedPtrField<google::protobuf::SourceCodeInfo_Location>::Get(
v2,
v18);
v7 = (int)v16;
v9 = *(_QWORD *)v19 + 256LL;
v3 = google::protobuf::SourceCodeInfo_Location::path(v16);
google::protobuf::Join<google::protobuf::RepeatedField<int>>(
(unsigned int)v15,
v3,
(unsigned int)",",
v4,
v5,
v6,
v7,
v9,
(unsigned int)v15,
(_DWORD)v12,
v13,
v14,
v15[0]);
v12 = (_QWORD *)std::unordered_map<std::string,google::protobuf::SourceCodeInfo_Location const*>::operator[](
v10,
v11);
*v12 = v8;
std::string::~string(v15);
++v18;
}
return result;
}
| |||
22,134 | google::protobuf::FileDescriptorTables::BuildLocationsByPath(std::pair<google::protobuf::FileDescriptorTables const*, google::protobuf::SourceCodeInfo const*>*) | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc | void FileDescriptorTables::BuildLocationsByPath(
std::pair<const FileDescriptorTables*, const SourceCodeInfo*>* p) {
for (int i = 0, len = p->second->location_size(); i < len; ++i) {
const SourceCodeInfo_Location* loc = &p->second->location().Get(i);
p->first->locations_by_path_[Join(loc->path(), ",")] = loc;
}
} | O3 | cpp | google::protobuf::FileDescriptorTables::BuildLocationsByPath(std::pair<google::protobuf::FileDescriptorTables const*, google::protobuf::SourceCodeInfo const*>*):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq 0x8(%rdi), %rax
movslq 0x18(%rax), %rbp
testq %rbp, %rbp
jle 0xbff13
movq %rdi, %rbx
xorl %r13d, %r13d
leaq 0x8(%rsp), %r15
movq 0x8(%rbx), %rax
movq 0x20(%rax), %rax
movq 0x8(%rax,%r13,8), %r14
movq (%rbx), %r12
movl $0x100, %eax # imm = 0x100
addq %rax, %r12
leaq 0x18(%r14), %rsi
movq %r15, %rdi
leaq 0xcb946(%rip), %rdx # 0x18b82a
callq 0xe0457
movq %r12, %rdi
movq %r15, %rsi
callq 0xe460a
movq %r14, (%rax)
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0xbff0b
callq 0x2d160
incq %r13
cmpq %r13, %rbp
jne 0xbfebe
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0xbff39
callq 0x2d160
movq %rbx, %rdi
callq 0x2e220
nop
| _ZN6google8protobuf20FileDescriptorTables20BuildLocationsByPathEPSt4pairIPKS1_PKNS0_14SourceCodeInfoEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov rax, [rdi+8]
movsxd rbp, dword ptr [rax+18h]
test rbp, rbp
jle short loc_BFF13
mov rbx, rdi
xor r13d, r13d
lea r15, [rsp+58h+var_50]
loc_BFEBE:
mov rax, [rbx+8]
mov rax, [rax+20h]
mov r14, [rax+r13*8+8]
mov r12, [rbx]
mov eax, 100h
add r12, rax
lea rsi, [r14+18h]
mov rdi, r15
lea rdx, a050000007e0500_1+0B3h; ","
call _ZN6google8protobuf4JoinINS0_13RepeatedFieldIiEEEENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_PKc; google::protobuf::Join<google::protobuf::RepeatedField<int>>(google::protobuf::RepeatedField<int> const&,char const*)
mov rdi, r12
mov rsi, r15
call _ZNSt8__detail9_Map_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS6_PKN6google8protobuf23SourceCodeInfo_LocationEESaISE_ENS_10_Select1stESt8equal_toIS6_ESt4hashIS6_ENS_18_Mod_range_hashingENS_20_Default_ranged_hashENS_20_Prime_rehash_policyENS_17_Hashtable_traitsILb1ELb0ELb1EEELb1EEixEOS6_; std::__detail::_Map_base<std::string,std::pair<std::string const,google::protobuf::SourceCodeInfo_Location const*>,std::allocator<std::pair<std::string const,google::protobuf::SourceCodeInfo_Location const*>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>,true>::operator[](std::string&&)
mov [rax], r14
mov rdi, [rsp+58h+var_50]; void *
lea rax, [rsp+58h+var_40]
cmp rdi, rax
jz short loc_BFF0B
call __ZdlPv; operator delete(void *)
loc_BFF0B:
inc r13
cmp rbp, r13
jnz short loc_BFEBE
loc_BFF13:
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov rbx, rax
mov rdi, [rsp+arg_0]; void *
lea rax, [rsp+arg_10]
cmp rdi, rax
jz short loc_BFF39
call __ZdlPv; operator delete(void *)
loc_BFF39:
mov rdi, rbx
call __Unwind_Resume
| void google::protobuf::FileDescriptorTables::BuildLocationsByPath(_QWORD *a1)
{
long long v1; // rbp
long long i; // r13
long long v3; // r14
long long v4; // r12
int v5; // edx
int v6; // ecx
int v7; // r8d
int v8; // r9d
char v9; // [rsp+0h] [rbp-58h]
void *v10[2]; // [rsp+8h] [rbp-50h] BYREF
char v11; // [rsp+18h] [rbp-40h] BYREF
v1 = *(int *)(a1[1] + 24LL);
if ( v1 > 0 )
{
for ( i = 0LL; i != v1; ++i )
{
v3 = *(_QWORD *)(*(_QWORD *)(a1[1] + 32LL) + 8 * i + 8);
v4 = *a1 + 256LL;
google::protobuf::Join<google::protobuf::RepeatedField<int>>(v10, v3 + 24, ",");
*(_QWORD *)std::__detail::_Map_base<std::string,std::pair<std::string const,google::protobuf::SourceCodeInfo_Location const*>,std::allocator<std::pair<std::string const,google::protobuf::SourceCodeInfo_Location const*>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>,true>::operator[](
v4,
(unsigned int)v10,
v5,
v6,
v7,
v8,
v9) = v3;
if ( v10[0] != &v11 )
operator delete(v10[0]);
}
}
}
| BuildLocationsByPath:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV RAX,qword ptr [RDI + 0x8]
MOVSXD RBP,dword ptr [RAX + 0x18]
TEST RBP,RBP
JLE 0x001bff13
MOV RBX,RDI
XOR R13D,R13D
LEA R15,[RSP + 0x8]
LAB_001bfebe:
MOV RAX,qword ptr [RBX + 0x8]
MOV RAX,qword ptr [RAX + 0x20]
MOV R14,qword ptr [RAX + R13*0x8 + 0x8]
MOV R12,qword ptr [RBX]
MOV EAX,0x100
ADD R12,RAX
LEA RSI,[R14 + 0x18]
MOV RDI,R15
LEA RDX,[0x28b82a]
CALL 0x001e0457
LAB_001bfee9:
MOV RDI,R12
MOV RSI,R15
CALL 0x001e460a
LAB_001bfef4:
MOV qword ptr [RAX],R14
MOV RDI,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x18]
CMP RDI,RAX
JZ 0x001bff0b
CALL 0x0012d160
LAB_001bff0b:
INC R13
CMP RBP,R13
JNZ 0x001bfebe
LAB_001bff13:
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* google::protobuf::FileDescriptorTables::BuildLocationsByPath(std::pair<google::protobuf::FileDescriptorTables
const*, google::protobuf::SourceCodeInfo const*>*) */
void google::protobuf::FileDescriptorTables::BuildLocationsByPath(pair *param_1)
{
int iVar1;
long lVar2;
long lVar3;
long *plVar4;
long lVar5;
int1 *local_50 [2];
int1 local_40 [16];
iVar1 = *(int *)(*(long *)(param_1 + 8) + 0x18);
if (0 < (long)iVar1) {
lVar5 = 0;
do {
lVar2 = *(long *)(*(long *)(*(long *)(param_1 + 8) + 0x20) + 8 + lVar5 * 8);
lVar3 = *(long *)param_1;
Join<google::protobuf::RepeatedField<int>>
((protobuf *)local_50,(RepeatedField *)(lVar2 + 0x18),",");
/* try { // try from 001bfee9 to 001bfef3 has its CatchHandler @ 001bff22 */
plVar4 = (long *)std::__detail::
_Map_base<std::__cxx11::string,std::pair<std::__cxx11::string_const,google::protobuf::SourceCodeInfo_Location_const*>,std::allocator<std::pair<std::__cxx11::string_const,google::protobuf::SourceCodeInfo_Location_const*>>,std::__detail::_Select1st,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>,true>
::operator[]((_Map_base<std::__cxx11::string,std::pair<std::__cxx11::string_const,google::protobuf::SourceCodeInfo_Location_const*>,std::allocator<std::pair<std::__cxx11::string_const,google::protobuf::SourceCodeInfo_Location_const*>>,std::__detail::_Select1st,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>,true>
*)(lVar3 + 0x100),(string *)local_50);
*plVar4 = lVar2;
if (local_50[0] != local_40) {
operator_delete(local_50[0]);
}
lVar5 = lVar5 + 1;
} while (iVar1 != lVar5);
}
return;
}
| |
22,135 | void OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::InterpolateFaceVarying<OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index, OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int, OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&, OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index&, int) const | NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/../far/primvarRefiner.h | inline void
PrimvarRefinerReal<REAL>::InterpolateFaceVarying(int level, T const & src, U & dst, int channel) const {
assert(level>0 && level<=(int)_refiner._refinements.size());
switch (_refiner._subdivType) {
case Sdc::SCHEME_CATMARK:
interpFVarFromFaces<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
interpFVarFromEdges<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
interpFVarFromVerts<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
break;
case Sdc::SCHEME_LOOP:
interpFVarFromFaces<Sdc::SCHEME_LOOP>(level, src, dst, channel);
interpFVarFromEdges<Sdc::SCHEME_LOOP>(level, src, dst, channel);
interpFVarFromVerts<Sdc::SCHEME_LOOP>(level, src, dst, channel);
break;
case Sdc::SCHEME_BILINEAR:
interpFVarFromFaces<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
interpFVarFromEdges<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
interpFVarFromVerts<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
break;
}
} | O3 | c | void OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::InterpolateFaceVarying<OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index, OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int, OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&, OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index&, int) const:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testl %esi, %esi
jle 0x74803
movq %rcx, %r14
movl %esi, %ebp
movq %rdi, %r12
movq (%rdi), %rax
movq 0x50(%rax), %rcx
subq 0x48(%rax), %rcx
shrq $0x3, %rcx
cmpl %esi, %ecx
jl 0x74803
movl %r8d, %ebx
movq %rdx, %r15
movl (%rax), %eax
testl %eax, %eax
je 0x747b9
cmpl $0x2, %eax
je 0x74778
cmpl $0x1, %eax
jne 0x747fa
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
callq 0x3b630
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
callq 0x39740
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x39e00
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
callq 0x3a560
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
callq 0x3b0e0
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x39650
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
callq 0x38140
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
callq 0x388f0
movq %r12, %rdi
movl %ebp, %esi
movq %r15, %rdx
movq %r14, %rcx
movl %ebx, %r8d
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x3b120
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x48f9f(%rip), %rdi # 0xbd7a9
leaq 0x48fcc(%rip), %rsi # 0xbd7dd
leaq 0x49c60(%rip), %rcx # 0xbe478
movl $0x127, %edx # imm = 0x127
callq 0x39540
| _ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE22InterpolateFaceVaryingINS1_8internal14StencilBuilderIfE5IndexES8_EEviRKT_RT0_i:
push rbp; int
push r15; int
push r14; int
push r12; int
push rbx; int
test esi, esi
jle loc_74803
mov r14, rcx
mov ebp, esi
mov r12, rdi
mov rax, [rdi]
mov rcx, [rax+50h]
sub rcx, [rax+48h]
shr rcx, 3
cmp ecx, esi
jl loc_74803
mov ebx, r8d
mov r15, rdx
mov eax, [rax]
test eax, eax
jz loc_747B9
cmp eax, 2
jz short loc_74778
cmp eax, 1
jnz loc_747FA
mov rdi, r12; int
mov esi, ebp; int
mov rdx, r15; int
mov rcx, r14; int
mov r8d, ebx; int
call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromFacesILNS0_3Sdc10SchemeTypeE1ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromFaces<(OpenSubdiv::v3_6_0::Sdc::SchemeType)1,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
mov rdi, r12
mov esi, ebp
mov rdx, r15
mov rcx, r14
mov r8d, ebx
call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromEdgesILNS0_3Sdc10SchemeTypeE1ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromEdges<(OpenSubdiv::v3_6_0::Sdc::SchemeType)1,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
mov rdi, r12
mov esi, ebp
mov rdx, r15
mov rcx, r14
mov r8d, ebx
pop rbx
pop r12
pop r14
pop r15
pop rbp
jmp __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromVertsILNS0_3Sdc10SchemeTypeE1ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromVerts<(OpenSubdiv::v3_6_0::Sdc::SchemeType)1,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
loc_74778:
mov rdi, r12; int
mov esi, ebp; int
mov rdx, r15; int
mov rcx, r14; int
mov r8d, ebx; int
call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromFacesILNS0_3Sdc10SchemeTypeE2ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromFaces<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
mov rdi, r12
mov esi, ebp
mov rdx, r15
mov rcx, r14
mov r8d, ebx
call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromEdgesILNS0_3Sdc10SchemeTypeE2ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromEdges<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
mov rdi, r12
mov esi, ebp
mov rdx, r15
mov rcx, r14
mov r8d, ebx
pop rbx
pop r12
pop r14
pop r15
pop rbp
jmp __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromVertsILNS0_3Sdc10SchemeTypeE2ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromVerts<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
loc_747B9:
mov rdi, r12; int
mov esi, ebp; int
mov rdx, r15; int
mov rcx, r14; int
mov r8d, ebx; int
call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromFacesILNS0_3Sdc10SchemeTypeE0ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromFaces<(OpenSubdiv::v3_6_0::Sdc::SchemeType)0,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
mov rdi, r12
mov esi, ebp
mov rdx, r15
mov rcx, r14
mov r8d, ebx
call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromEdgesILNS0_3Sdc10SchemeTypeE0ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromEdges<(OpenSubdiv::v3_6_0::Sdc::SchemeType)0,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
mov rdi, r12
mov esi, ebp
mov rdx, r15
mov rcx, r14
mov r8d, ebx
pop rbx
pop r12
pop r14
pop r15
pop rbp
jmp __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE19interpFVarFromVertsILNS0_3Sdc10SchemeTypeE0ENS1_8internal14StencilBuilderIfE5IndexESA_EEviRKT0_RT1_i; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::interpFVarFromVerts<(OpenSubdiv::v3_6_0::Sdc::SchemeType)0,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index &,int)
loc_747FA:
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_74803:
lea rdi, aLevel0LevelInt; "level>0 && level<=(int)_refiner._refine"...
lea rsi, aWorkspaceLlm4b_20; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aVoidOpensubdiv_71; "void OpenSubdiv::v3_6_0::Far::PrimvarRe"...
mov edx, 127h
call ___assert_fail
| InterpolateFaceVarying<OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
TEST ESI,ESI
JLE 0x00174803
MOV R14,RCX
MOV EBP,ESI
MOV R12,RDI
MOV RAX,qword ptr [RDI]
MOV RCX,qword ptr [RAX + 0x50]
SUB RCX,qword ptr [RAX + 0x48]
SHR RCX,0x3
CMP ECX,ESI
JL 0x00174803
MOV EBX,R8D
MOV R15,RDX
MOV EAX,dword ptr [RAX]
TEST EAX,EAX
JZ 0x001747b9
CMP EAX,0x2
JZ 0x00174778
CMP EAX,0x1
JNZ 0x001747fa
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
CALL 0x0013b630
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
CALL 0x00139740
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
POP RBX
POP R12
POP R14
POP R15
POP RBP
JMP 0x00139e00
LAB_00174778:
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
CALL 0x0013a560
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
CALL 0x0013b0e0
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
POP RBX
POP R12
POP R14
POP R15
POP RBP
JMP 0x00139650
LAB_001747b9:
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
CALL 0x00138140
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
CALL 0x001388f0
MOV RDI,R12
MOV ESI,EBP
MOV RDX,R15
MOV RCX,R14
MOV R8D,EBX
POP RBX
POP R12
POP R14
POP R15
POP RBP
JMP 0x0013b120
LAB_001747fa:
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_00174803:
LEA RDI,[0x1bd7a9]
LEA RSI,[0x1bd7dd]
LEA RCX,[0x1be478]
MOV EDX,0x127
CALL 0x00139540
|
/* void
OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::InterpolateFaceVarying<OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,
OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>(int,
OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index const&,
OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index&, int) const */
void __thiscall
OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::
InterpolateFaceVarying<OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(PrimvarRefinerReal<float> *this,int param_1,Index *param_2,Index *param_3,int param_4)
{
int iVar1;
int *piVar2;
if ((param_1 < 1) ||
(piVar2 = *(int **)this,
(int)((ulong)(*(long *)(piVar2 + 0x14) - *(long *)(piVar2 + 0x12)) >> 3) < param_1)) {
/* WARNING: Subroutine does not return */
__assert_fail("level>0 && level<=(int)_refiner._refinements.size()",
"/workspace/llm4binary/github/2025_star3/NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/../far/primvarRefiner.h"
,0x127,
"void OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::InterpolateFaceVarying(int, const T &, U &, int) const [REAL = float, T = OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index, U = OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index]"
);
}
iVar1 = *piVar2;
if (iVar1 == 0) {
interpFVarFromFaces<(OpenSubdiv::v3_6_0::Sdc::SchemeType)0,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
interpFVarFromEdges<(OpenSubdiv::v3_6_0::Sdc::SchemeType)0,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
interpFVarFromVerts<(OpenSubdiv::v3_6_0::Sdc::SchemeType)0,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
return;
}
if (iVar1 != 2) {
if (iVar1 == 1) {
interpFVarFromFaces<(OpenSubdiv::v3_6_0::Sdc::SchemeType)1,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
interpFVarFromEdges<(OpenSubdiv::v3_6_0::Sdc::SchemeType)1,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
interpFVarFromVerts<(OpenSubdiv::v3_6_0::Sdc::SchemeType)1,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
return;
}
return;
}
interpFVarFromFaces<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
interpFVarFromEdges<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
interpFVarFromVerts<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index,OpenSubdiv::v3_6_0::Far::internal::StencilBuilder<float>::Index>
(this,param_1,param_2,param_3,param_4);
return;
}
| ||
22,136 | my_weight_utf32_general_ci | eloqsql/strings/ctype-ucs2.c | static inline int my_weight_utf32_general_ci(uchar b0, uchar b1,
uchar b2, uchar b3)
{
my_wc_t wc= MY_UTF32_WC4(b0, b1, b2, b3);
if (wc <= 0xFFFF)
{
MY_UNICASE_CHARACTER *page= my_unicase_default_pages[wc >> 8];
return (int) (page ? page[wc & 0xFF].sort : wc);
}
return MY_CS_REPLACEMENT_CHARACTER;
} | O0 | c | my_weight_utf32_general_ci:
pushq %rbp
movq %rsp, %rbp
movb %cl, %al
movb %dl, %cl
movb %sil, %dl
movb %dil, %sil
movb %sil, -0x5(%rbp)
movb %dl, -0x6(%rbp)
movb %cl, -0x7(%rbp)
movb %al, -0x8(%rbp)
movzbl -0x5(%rbp), %eax
shlq $0x18, %rax
movzbl -0x6(%rbp), %ecx
shll $0x10, %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movzbl -0x7(%rbp), %ecx
shll $0x8, %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movzbl -0x8(%rbp), %ecx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
cmpq $0xffff, -0x10(%rbp) # imm = 0xFFFF
ja 0xafb60
movq -0x10(%rbp), %rcx
shrq $0x8, %rcx
leaq 0x31f48f(%rip), %rax # 0x3cefb0
movq (%rax,%rcx,8), %rax
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0xafb4f
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
andq $0xff, %rcx
imulq $0xc, %rcx, %rcx
addq %rcx, %rax
movl 0x8(%rax), %eax
movq %rax, -0x20(%rbp)
jmp 0xafb57
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movl %eax, -0x4(%rbp)
jmp 0xafb67
movl $0xfffd, -0x4(%rbp) # imm = 0xFFFD
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax)
| my_weight_utf32_general_ci:
push rbp
mov rbp, rsp
mov al, cl
mov cl, dl
mov dl, sil
mov sil, dil
mov [rbp+var_5], sil
mov [rbp+var_6], dl
mov [rbp+var_7], cl
mov [rbp+var_8], al
movzx eax, [rbp+var_5]
shl rax, 18h
movzx ecx, [rbp+var_6]
shl ecx, 10h
movsxd rcx, ecx
add rax, rcx
movzx ecx, [rbp+var_7]
shl ecx, 8
movsxd rcx, ecx
add rax, rcx
movzx ecx, [rbp+var_8]
add rax, rcx
mov [rbp+var_10], rax
cmp [rbp+var_10], 0FFFFh
ja short loc_AFB60
mov rcx, [rbp+var_10]
shr rcx, 8
lea rax, my_unicase_default_pages
mov rax, [rax+rcx*8]
mov [rbp+var_18], rax
cmp [rbp+var_18], 0
jz short loc_AFB4F
mov rax, [rbp+var_18]
mov rcx, [rbp+var_10]
and rcx, 0FFh
imul rcx, 0Ch
add rax, rcx
mov eax, [rax+8]
mov [rbp+var_20], rax
jmp short loc_AFB57
loc_AFB4F:
mov rax, [rbp+var_10]
mov [rbp+var_20], rax
loc_AFB57:
mov rax, [rbp+var_20]
mov [rbp+var_4], eax
jmp short loc_AFB67
loc_AFB60:
mov [rbp+var_4], 0FFFDh
loc_AFB67:
mov eax, [rbp+var_4]
pop rbp
retn
| long long my_weight_utf32_general_ci(
unsigned __int8 a1,
unsigned __int8 a2,
unsigned __int8 a3,
unsigned __int8 a4)
{
long long v6; // [rsp+8h] [rbp-18h]
unsigned long long v7; // [rsp+10h] [rbp-10h]
v7 = a4 + (a3 << 8) + (a2 << 16) + ((unsigned long long)a1 << 24);
if ( v7 > 0xFFFF )
{
return 65533;
}
else
{
v6 = (long long)*(&my_unicase_default_pages + (v7 >> 8));
if ( v6 )
return *(unsigned int *)(12LL * a4 + v6 + 8);
else
return (unsigned int)(a4 + (a3 << 8) + (a2 << 16) + (a1 << 24));
}
}
| my_weight_utf32_general_ci:
PUSH RBP
MOV RBP,RSP
MOV AL,CL
MOV CL,DL
MOV DL,SIL
MOV SIL,DIL
MOV byte ptr [RBP + -0x5],SIL
MOV byte ptr [RBP + -0x6],DL
MOV byte ptr [RBP + -0x7],CL
MOV byte ptr [RBP + -0x8],AL
MOVZX EAX,byte ptr [RBP + -0x5]
SHL RAX,0x18
MOVZX ECX,byte ptr [RBP + -0x6]
SHL ECX,0x10
MOVSXD RCX,ECX
ADD RAX,RCX
MOVZX ECX,byte ptr [RBP + -0x7]
SHL ECX,0x8
MOVSXD RCX,ECX
ADD RAX,RCX
MOVZX ECX,byte ptr [RBP + -0x8]
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
CMP qword ptr [RBP + -0x10],0xffff
JA 0x001afb60
MOV RCX,qword ptr [RBP + -0x10]
SHR RCX,0x8
LEA RAX,[0x4cefb0]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x18],RAX
CMP qword ptr [RBP + -0x18],0x0
JZ 0x001afb4f
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x10]
AND RCX,0xff
IMUL RCX,RCX,0xc
ADD RAX,RCX
MOV EAX,dword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x20],RAX
JMP 0x001afb57
LAB_001afb4f:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x20],RAX
LAB_001afb57:
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x001afb67
LAB_001afb60:
MOV dword ptr [RBP + -0x4],0xfffd
LAB_001afb67:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int4 my_weight_utf32_general_ci(byte param_1,byte param_2,byte param_3,byte param_4)
{
ulong local_28;
int4 local_c;
local_28 = (ulong)param_1 * 0x1000000 + (long)(int)((uint)param_2 << 0x10) +
(long)(int)((uint)param_3 << 8) + (ulong)param_4;
if (local_28 < 0x10000) {
if (*(long *)(my_unicase_default_pages + (local_28 >> 8) * 8) != 0) {
local_28 = (ulong)*(uint *)(*(long *)(my_unicase_default_pages + (local_28 >> 8) * 8) +
(local_28 & 0xff) * 0xc + 8);
}
local_c = (int4)local_28;
}
else {
local_c = 0xfffd;
}
return local_c;
}
| |
22,137 | JS_GetPropertyValue | bluesky950520[P]quickjs/quickjs.c | static JSValue JS_GetPropertyValue(JSContext *ctx, JSValue this_obj,
JSValue prop)
{
JSAtom atom;
JSValue ret;
uint32_t tag;
tag = JS_VALUE_GET_TAG(this_obj);
if (likely(tag == JS_TAG_OBJECT)) {
if (JS_VALUE_GET_TAG(prop) == JS_TAG_INT) {
JSObject *p = JS_VALUE_GET_OBJ(this_obj);
uint32_t idx = JS_VALUE_GET_INT(prop);
JSValue val;
/* fast path for array and typed array access */
if (js_get_fast_array_element(ctx, p, idx, &val))
return val;
}
} else {
switch(tag) {
case JS_TAG_NULL:
JS_FreeValue(ctx, prop);
return JS_ThrowTypeError(ctx, "cannot read property of null");
case JS_TAG_UNDEFINED:
JS_FreeValue(ctx, prop);
return JS_ThrowTypeError(ctx, "cannot read property of undefined");
}
}
atom = JS_ValueToAtom(ctx, prop);
JS_FreeValue(ctx, prop);
if (unlikely(atom == JS_ATOM_NULL))
return JS_EXCEPTION;
ret = JS_GetProperty(ctx, this_obj, atom);
JS_FreeAtom(ctx, atom);
return ret;
} | O0 | c | JS_GetPropertyValue:
subq $0x88, %rsp
movq %rsi, 0x68(%rsp)
movq %rdx, 0x70(%rsp)
movq %rcx, 0x58(%rsp)
movq %r8, 0x60(%rsp)
movq %rdi, 0x50(%rsp)
movq 0x70(%rsp), %rax
movl %eax, 0x34(%rsp)
cmpl $-0x1, 0x34(%rsp)
sete %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x69a17
movq 0x60(%rsp), %rax
cmpl $0x0, %eax
jne 0x69a12
movq 0x68(%rsp), %rax
movq %rax, 0x28(%rsp)
movl 0x58(%rsp), %eax
movl %eax, 0x24(%rsp)
movq 0x50(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x24(%rsp), %edx
leaq 0x78(%rsp), %rcx
callq 0x315e0
cmpl $0x0, %eax
je 0x69a10
jmp 0x69b5b
jmp 0x69a12
jmp 0x69aa5
movl 0x34(%rsp), %eax
movl %eax, 0xc(%rsp)
subl $0x2, %eax
je 0x69a31
jmp 0x69a26
movl 0xc(%rsp), %eax
subl $0x3, %eax
je 0x69a6a
jmp 0x69aa3
movq 0x50(%rsp), %rdi
movq 0x58(%rsp), %rsi
movq 0x60(%rsp), %rdx
callq 0x23c90
movq 0x50(%rsp), %rdi
leaq 0xa4b92(%rip), %rsi # 0x10e5e3
movb $0x0, %al
callq 0x2d300
movq %rax, 0x78(%rsp)
movq %rdx, 0x80(%rsp)
jmp 0x69b5b
movq 0x50(%rsp), %rdi
movq 0x58(%rsp), %rsi
movq 0x60(%rsp), %rdx
callq 0x23c90
movq 0x50(%rsp), %rdi
leaq 0xa4b76(%rip), %rsi # 0x10e600
movb $0x0, %al
callq 0x2d300
movq %rax, 0x78(%rsp)
movq %rdx, 0x80(%rsp)
jmp 0x69b5b
jmp 0x69aa5
movq 0x50(%rsp), %rdi
movq 0x58(%rsp), %rsi
movq 0x60(%rsp), %rdx
callq 0x31200
movl %eax, 0x4c(%rsp)
movq 0x50(%rsp), %rdi
movq 0x58(%rsp), %rsi
movq 0x60(%rsp), %rdx
callq 0x23c90
cmpl $0x0, 0x4c(%rsp)
sete %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x69b00
movl $0x0, 0x78(%rsp)
movq $0x6, 0x80(%rsp)
jmp 0x69b5b
movq 0x50(%rsp), %rdi
movl 0x4c(%rsp), %ecx
movq 0x68(%rsp), %rsi
movq 0x70(%rsp), %rdx
callq 0x29d80
movq %rax, 0x10(%rsp)
movq %rdx, 0x18(%rsp)
movq 0x10(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x18(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x50(%rsp), %rdi
movl 0x4c(%rsp), %esi
callq 0x29040
movq 0x38(%rsp), %rax
movq %rax, 0x78(%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0x80(%rsp)
movq 0x78(%rsp), %rax
movq 0x80(%rsp), %rdx
addq $0x88, %rsp
retq
| JS_GetPropertyValue:
sub rsp, 88h
mov [rsp+88h+var_20], rsi
mov [rsp+88h+var_18], rdx
mov [rsp+88h+var_30], rcx
mov [rsp+88h+var_28], r8
mov [rsp+88h+var_38], rdi
mov rax, [rsp+88h+var_18]
mov [rsp+88h+var_54], eax
cmp [rsp+88h+var_54], 0FFFFFFFFh
setz al
xor al, 0FFh
xor al, 0FFh
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_69A17
mov rax, [rsp+88h+var_28]
cmp eax, 0
jnz short loc_69A12
mov rax, [rsp+88h+var_20]
mov [rsp+88h+var_60], rax
mov eax, dword ptr [rsp+88h+var_30]
mov [rsp+88h+var_64], eax
mov rdi, [rsp+88h+var_38]
mov rsi, [rsp+88h+var_60]
mov edx, [rsp+88h+var_64]
lea rcx, [rsp+88h+var_10]
call js_get_fast_array_element
cmp eax, 0
jz short loc_69A10
jmp loc_69B5B
loc_69A10:
jmp short $+2
loc_69A12:
jmp loc_69AA5
loc_69A17:
mov eax, [rsp+88h+var_54]
mov [rsp+88h+var_7C], eax
sub eax, 2
jz short loc_69A31
jmp short $+2
loc_69A26:
mov eax, [rsp+88h+var_7C]
sub eax, 3
jz short loc_69A6A
jmp short loc_69AA3
loc_69A31:
mov rdi, [rsp+88h+var_38]
mov rsi, [rsp+88h+var_30]
mov rdx, [rsp+88h+var_28]
call JS_FreeValue
mov rdi, [rsp+88h+var_38]
lea rsi, aCannotReadProp_1; "cannot read property of null"
mov al, 0
call JS_ThrowTypeError
mov [rsp+88h+var_10], rax
mov [rsp+88h+var_8], rdx
jmp loc_69B5B
loc_69A6A:
mov rdi, [rsp+88h+var_38]
mov rsi, [rsp+88h+var_30]
mov rdx, [rsp+88h+var_28]
call JS_FreeValue
mov rdi, [rsp+88h+var_38]
lea rsi, aCannotReadProp_2; "cannot read property of undefined"
mov al, 0
call JS_ThrowTypeError
mov [rsp+88h+var_10], rax
mov [rsp+88h+var_8], rdx
jmp loc_69B5B
loc_69AA3:
jmp short $+2
loc_69AA5:
mov rdi, [rsp+88h+var_38]
mov rsi, [rsp+88h+var_30]
mov rdx, [rsp+88h+var_28]
call JS_ValueToAtom
mov [rsp+88h+var_3C], eax
mov rdi, [rsp+88h+var_38]
mov rsi, [rsp+88h+var_30]
mov rdx, [rsp+88h+var_28]
call JS_FreeValue
cmp [rsp+88h+var_3C], 0
setz al
xor al, 0FFh
xor al, 0FFh
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_69B00
mov dword ptr [rsp+88h+var_10], 0
mov [rsp+88h+var_8], 6
jmp short loc_69B5B
loc_69B00:
mov rdi, [rsp+88h+var_38]
mov ecx, [rsp+88h+var_3C]
mov rsi, [rsp+88h+var_20]
mov rdx, [rsp+88h+var_18]
call JS_GetProperty
mov [rsp+88h+var_78], rax
mov [rsp+88h+var_70], rdx
mov rax, [rsp+88h+var_78]
mov [rsp+88h+var_50], rax
mov rax, [rsp+88h+var_70]
mov [rsp+88h+var_48], rax
mov rdi, [rsp+88h+var_38]
mov esi, [rsp+88h+var_3C]
call JS_FreeAtom
mov rax, [rsp+88h+var_50]
mov [rsp+88h+var_10], rax
mov rax, [rsp+88h+var_48]
mov [rsp+88h+var_8], rax
loc_69B5B:
mov rax, [rsp+88h+var_10]
mov rdx, [rsp+88h+var_8]
add rsp, 88h
retn
| long long JS_GetPropertyValue(
long long a1,
long long a2,
int a3,
long long a4,
long long a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
double a10,
double a11,
__m128 a12,
__m128 a13)
{
long long v13; // rdx
long long v14; // rcx
long long v15; // r8
long long v16; // r9
__m128 v17; // xmm4
__m128 v18; // xmm5
long long v19; // rdx
long long v20; // rdx
long long v21; // rcx
long long v22; // r8
long long v23; // r9
__m128 v24; // xmm4
__m128 v25; // xmm5
long long v26; // rdx
long long v27; // rdx
char v29; // [rsp+0h] [rbp-88h]
long long Property; // [rsp+10h] [rbp-78h]
long long v31; // [rsp+40h] [rbp-48h]
unsigned int v32; // [rsp+4Ch] [rbp-3Ch]
long long v36; // [rsp+78h] [rbp-10h] BYREF
long long v37; // [rsp+80h] [rbp-8h]
if ( a3 != -1 )
{
if ( a3 == 2 )
{
JS_FreeValue(a1, a4, a5);
v36 = JS_ThrowTypeError(
a1,
(long long)"cannot read property of null",
v13,
v14,
v15,
v16,
a6,
a7,
a8,
a9,
v17,
v18,
a12,
a13,
v29);
v37 = v19;
return v36;
}
if ( a3 == 3 )
{
JS_FreeValue(a1, a4, a5);
v36 = JS_ThrowTypeError(
a1,
(long long)"cannot read property of undefined",
v20,
v21,
v22,
v23,
a6,
a7,
a8,
a9,
v24,
v25,
a12,
a13,
v29);
v37 = v26;
return v36;
}
goto LABEL_10;
}
if ( (_DWORD)a5 || !(unsigned int)js_get_fast_array_element(a1, a2, a4, &v36) )
{
LABEL_10:
v32 = JS_ValueToAtom(a1, a4, a5);
JS_FreeValue(a1, a4, a5);
if ( v32 )
{
Property = JS_GetProperty(a1, a2, a3, v32);
v31 = v27;
JS_FreeAtom(a1, v32);
v36 = Property;
v37 = v31;
}
else
{
LODWORD(v36) = 0;
v37 = 6LL;
}
}
return v36;
}
| JS_GetPropertyValue:
SUB RSP,0x88
MOV qword ptr [RSP + 0x68],RSI
MOV qword ptr [RSP + 0x70],RDX
MOV qword ptr [RSP + 0x58],RCX
MOV qword ptr [RSP + 0x60],R8
MOV qword ptr [RSP + 0x50],RDI
MOV RAX,qword ptr [RSP + 0x70]
MOV dword ptr [RSP + 0x34],EAX
CMP dword ptr [RSP + 0x34],-0x1
SETZ AL
XOR AL,0xff
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x00169a17
MOV RAX,qword ptr [RSP + 0x60]
CMP EAX,0x0
JNZ 0x00169a12
MOV RAX,qword ptr [RSP + 0x68]
MOV qword ptr [RSP + 0x28],RAX
MOV EAX,dword ptr [RSP + 0x58]
MOV dword ptr [RSP + 0x24],EAX
MOV RDI,qword ptr [RSP + 0x50]
MOV RSI,qword ptr [RSP + 0x28]
MOV EDX,dword ptr [RSP + 0x24]
LEA RCX,[RSP + 0x78]
CALL 0x001315e0
CMP EAX,0x0
JZ 0x00169a10
JMP 0x00169b5b
LAB_00169a10:
JMP 0x00169a12
LAB_00169a12:
JMP 0x00169aa5
LAB_00169a17:
MOV EAX,dword ptr [RSP + 0x34]
MOV dword ptr [RSP + 0xc],EAX
SUB EAX,0x2
JZ 0x00169a31
JMP 0x00169a26
LAB_00169a26:
MOV EAX,dword ptr [RSP + 0xc]
SUB EAX,0x3
JZ 0x00169a6a
JMP 0x00169aa3
LAB_00169a31:
MOV RDI,qword ptr [RSP + 0x50]
MOV RSI,qword ptr [RSP + 0x58]
MOV RDX,qword ptr [RSP + 0x60]
CALL 0x00123c90
MOV RDI,qword ptr [RSP + 0x50]
LEA RSI,[0x20e5e3]
MOV AL,0x0
CALL 0x0012d300
MOV qword ptr [RSP + 0x78],RAX
MOV qword ptr [RSP + 0x80],RDX
JMP 0x00169b5b
LAB_00169a6a:
MOV RDI,qword ptr [RSP + 0x50]
MOV RSI,qword ptr [RSP + 0x58]
MOV RDX,qword ptr [RSP + 0x60]
CALL 0x00123c90
MOV RDI,qword ptr [RSP + 0x50]
LEA RSI,[0x20e600]
MOV AL,0x0
CALL 0x0012d300
MOV qword ptr [RSP + 0x78],RAX
MOV qword ptr [RSP + 0x80],RDX
JMP 0x00169b5b
LAB_00169aa3:
JMP 0x00169aa5
LAB_00169aa5:
MOV RDI,qword ptr [RSP + 0x50]
MOV RSI,qword ptr [RSP + 0x58]
MOV RDX,qword ptr [RSP + 0x60]
CALL 0x00131200
MOV dword ptr [RSP + 0x4c],EAX
MOV RDI,qword ptr [RSP + 0x50]
MOV RSI,qword ptr [RSP + 0x58]
MOV RDX,qword ptr [RSP + 0x60]
CALL 0x00123c90
CMP dword ptr [RSP + 0x4c],0x0
SETZ AL
XOR AL,0xff
XOR AL,0xff
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x00169b00
MOV dword ptr [RSP + 0x78],0x0
MOV qword ptr [RSP + 0x80],0x6
JMP 0x00169b5b
LAB_00169b00:
MOV RDI,qword ptr [RSP + 0x50]
MOV ECX,dword ptr [RSP + 0x4c]
MOV RSI,qword ptr [RSP + 0x68]
MOV RDX,qword ptr [RSP + 0x70]
CALL 0x00129d80
MOV qword ptr [RSP + 0x10],RAX
MOV qword ptr [RSP + 0x18],RDX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x38],RAX
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP + 0x40],RAX
MOV RDI,qword ptr [RSP + 0x50]
MOV ESI,dword ptr [RSP + 0x4c]
CALL 0x00129040
MOV RAX,qword ptr [RSP + 0x38]
MOV qword ptr [RSP + 0x78],RAX
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP + 0x80],RAX
LAB_00169b5b:
MOV RAX,qword ptr [RSP + 0x78]
MOV RDX,qword ptr [RSP + 0x80]
ADD RSP,0x88
RET
|
int1 [16]
JS_GetPropertyValue(int8 param_1,int8 param_2,int8 param_3,ulong param_4,
int8 param_5)
{
int iVar1;
int1 auVar2 [16];
int4 local_10;
int4 uStack_c;
int8 local_8;
iVar1 = (int)param_3;
if (iVar1 == -1) {
if (((int)param_5 == 0) &&
(iVar1 = js_get_fast_array_element(param_1,param_2,param_4 & 0xffffffff,&local_10),
iVar1 != 0)) goto LAB_00169b5b;
}
else {
if (iVar1 == 2) {
JS_FreeValue(param_1,param_4,param_5);
auVar2 = JS_ThrowTypeError(param_1,"cannot read property of null");
local_8 = auVar2._8_8_;
local_10 = auVar2._0_4_;
uStack_c = auVar2._4_4_;
goto LAB_00169b5b;
}
if (iVar1 == 3) {
JS_FreeValue(param_1,param_4,param_5);
auVar2 = JS_ThrowTypeError(param_1,"cannot read property of int");
local_8 = auVar2._8_8_;
local_10 = auVar2._0_4_;
uStack_c = auVar2._4_4_;
goto LAB_00169b5b;
}
}
iVar1 = JS_ValueToAtom(param_1,param_4,param_5);
JS_FreeValue(param_1,param_4,param_5);
if (iVar1 == 0) {
local_10 = 0;
local_8 = 6;
}
else {
auVar2 = JS_GetProperty(param_1,param_2,param_3,iVar1);
JS_FreeAtom(param_1,iVar1);
local_10 = auVar2._0_4_;
uStack_c = auVar2._4_4_;
local_8 = auVar2._8_8_;
}
LAB_00169b5b:
auVar2._4_4_ = uStack_c;
auVar2._0_4_ = local_10;
auVar2._8_8_ = local_8;
return auVar2;
}
| |
22,138 | JS_GetPropertyValue | bluesky950520[P]quickjs/quickjs.c | static JSValue JS_GetPropertyValue(JSContext *ctx, JSValue this_obj,
JSValue prop)
{
JSAtom atom;
JSValue ret;
uint32_t tag;
tag = JS_VALUE_GET_TAG(this_obj);
if (likely(tag == JS_TAG_OBJECT)) {
if (JS_VALUE_GET_TAG(prop) == JS_TAG_INT) {
JSObject *p = JS_VALUE_GET_OBJ(this_obj);
uint32_t idx = JS_VALUE_GET_INT(prop);
JSValue val;
/* fast path for array and typed array access */
if (js_get_fast_array_element(ctx, p, idx, &val))
return val;
}
} else {
switch(tag) {
case JS_TAG_NULL:
JS_FreeValue(ctx, prop);
return JS_ThrowTypeError(ctx, "cannot read property of null");
case JS_TAG_UNDEFINED:
JS_FreeValue(ctx, prop);
return JS_ThrowTypeError(ctx, "cannot read property of undefined");
}
}
atom = JS_ValueToAtom(ctx, prop);
JS_FreeValue(ctx, prop);
if (unlikely(atom == JS_ATOM_NULL))
return JS_EXCEPTION;
ret = JS_GetProperty(ctx, this_obj, atom);
JS_FreeAtom(ctx, atom);
return ret;
} | O2 | c | JS_GetPropertyValue:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r8, %r15
movq %rcx, %r13
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %rbx
cmpl $-0x1, %r14d
jne 0x38110
testl %r15d, %r15d
je 0x380dd
movq %rbx, %rdi
movq %r13, %rsi
movq %r15, %rdx
callq 0x1e0bc
movl %eax, %ebp
movq %rbx, %rdi
movq %r13, %rsi
movq %r15, %rdx
callq 0x1801e
testl %ebp, %ebp
je 0x38137
movq %rbx, %rdi
movq %r12, %rsi
movq %r14, %rdx
movl %ebp, %ecx
callq 0x1b043
movq %rax, %r15
movq %rdx, %r14
movq %rbx, %rdi
movl %ebp, %esi
callq 0x1a995
movq %r15, 0x8(%rsp)
jmp 0x380f9
leaq 0x8(%rsp), %rcx
movq %rbx, %rdi
movq %r12, %rsi
movl %r13d, %edx
callq 0x1e226
testl %eax, %eax
je 0x38090
movq 0x10(%rsp), %r14
movq 0x8(%rsp), %rax
movq %r14, %rdx
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpl $0x2, %r14d
je 0x3813e
cmpl $0x3, %r14d
jne 0x38090
movq %rbx, %rdi
movq %r13, %rsi
movq %r15, %rdx
callq 0x1801e
leaq 0x4e3b7(%rip), %rsi # 0x864ec
jmp 0x38153
andl $0x0, 0x8(%rsp)
jmp 0x38163
movq %rbx, %rdi
movq %r13, %rsi
movq %r15, %rdx
callq 0x1801e
leaq 0x4e37c(%rip), %rsi # 0x864cf
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1c64d
andq $0x0, 0x8(%rsp)
pushq $0x6
popq %r14
jmp 0x380f9
| JS_GetPropertyValue:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov r15, r8
mov r13, rcx
mov r14, rdx
mov r12, rsi
mov rbx, rdi
cmp r14d, 0FFFFFFFFh
jnz loc_38110
test r15d, r15d
jz short loc_380DD
loc_38090:
mov rdi, rbx
mov rsi, r13
mov rdx, r15
call JS_ValueToAtom
mov ebp, eax
mov rdi, rbx
mov rsi, r13
mov rdx, r15
call JS_FreeValue
test ebp, ebp
jz loc_38137
mov rdi, rbx
mov rsi, r12
mov rdx, r14
mov ecx, ebp
call JS_GetProperty
mov r15, rax
mov r14, rdx
mov rdi, rbx
mov esi, ebp
call JS_FreeAtom
mov [rsp+48h+var_40], r15
jmp short loc_380F9
loc_380DD:
lea rcx, [rsp+48h+var_40]
mov rdi, rbx
mov rsi, r12
mov edx, r13d
call js_get_fast_array_element
test eax, eax
jz short loc_38090
mov r14, [rsp+48h+var_38]
loc_380F9:
mov rax, [rsp+48h+var_40]
mov rdx, r14
add rsp, 18h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_38110:
cmp r14d, 2
jz short loc_3813E
cmp r14d, 3
jnz loc_38090
mov rdi, rbx
mov rsi, r13
mov rdx, r15
call JS_FreeValue
lea rsi, aCannotReadProp_1; "cannot read property of undefined"
jmp short loc_38153
loc_38137:
and dword ptr [rsp+48h+var_40], 0
jmp short loc_38163
loc_3813E:
mov rdi, rbx
mov rsi, r13
mov rdx, r15
call JS_FreeValue
lea rsi, aCannotReadProp_2; "cannot read property of null"
loc_38153:
mov rdi, rbx
xor eax, eax
call JS_ThrowTypeError
and [rsp+48h+var_40], 0
loc_38163:
push 6
pop r14
jmp short loc_380F9
| long long JS_GetPropertyValue(
long long a1,
long long a2,
int a3,
long long a4,
long long a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
double a10,
double a11,
__m128 a12,
__m128 a13)
{
int v16; // ebp
long long Property; // r15
long long v19; // rdx
long long v20; // rcx
long long v21; // r8
long long v22; // r9
__m128 v23; // xmm4
__m128 v24; // xmm5
const char *v25; // rsi
char v26; // [rsp+0h] [rbp-48h]
long long v27; // [rsp+8h] [rbp-40h] BYREF
if ( a3 != -1 )
{
if ( a3 == 2 )
{
JS_FreeValue(a1, a4, a5);
v25 = "cannot read property of null";
}
else
{
if ( a3 != 3 )
{
LABEL_3:
v16 = JS_ValueToAtom(a1, a4, a5);
JS_FreeValue(a1, a4, a5);
if ( v16 )
{
Property = JS_GetProperty(a1, a2, a3, v16);
JS_FreeAtom(a1, v16);
return Property;
}
else
{
LODWORD(v27) = 0;
}
return v27;
}
JS_FreeValue(a1, a4, a5);
v25 = "cannot read property of undefined";
}
JS_ThrowTypeError(a1, (long long)v25, v19, v20, v21, v22, a6, a7, a8, a9, v23, v24, a12, a13, v26);
return 0LL;
}
if ( (_DWORD)a5 || !(unsigned int)js_get_fast_array_element(a1, a2, a4, (double *)&v27) )
goto LABEL_3;
return v27;
}
| JS_GetPropertyValue:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV R15,R8
MOV R13,RCX
MOV R14,RDX
MOV R12,RSI
MOV RBX,RDI
CMP R14D,-0x1
JNZ 0x00138110
TEST R15D,R15D
JZ 0x001380dd
LAB_00138090:
MOV RDI,RBX
MOV RSI,R13
MOV RDX,R15
CALL 0x0011e0bc
MOV EBP,EAX
MOV RDI,RBX
MOV RSI,R13
MOV RDX,R15
CALL 0x0011801e
TEST EBP,EBP
JZ 0x00138137
MOV RDI,RBX
MOV RSI,R12
MOV RDX,R14
MOV ECX,EBP
CALL 0x0011b043
MOV R15,RAX
MOV R14,RDX
MOV RDI,RBX
MOV ESI,EBP
CALL 0x0011a995
MOV qword ptr [RSP + 0x8],R15
JMP 0x001380f9
LAB_001380dd:
LEA RCX,[RSP + 0x8]
MOV RDI,RBX
MOV RSI,R12
MOV EDX,R13D
CALL 0x0011e226
TEST EAX,EAX
JZ 0x00138090
MOV R14,qword ptr [RSP + 0x10]
LAB_001380f9:
MOV RAX,qword ptr [RSP + 0x8]
MOV RDX,R14
ADD RSP,0x18
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00138110:
CMP R14D,0x2
JZ 0x0013813e
CMP R14D,0x3
JNZ 0x00138090
MOV RDI,RBX
MOV RSI,R13
MOV RDX,R15
CALL 0x0011801e
LEA RSI,[0x1864ec]
JMP 0x00138153
LAB_00138137:
AND dword ptr [RSP + 0x8],0x0
JMP 0x00138163
LAB_0013813e:
MOV RDI,RBX
MOV RSI,R13
MOV RDX,R15
CALL 0x0011801e
LEA RSI,[0x1864cf]
LAB_00138153:
MOV RDI,RBX
XOR EAX,EAX
CALL 0x0011c64d
AND qword ptr [RSP + 0x8],0x0
LAB_00138163:
PUSH 0x6
POP R14
JMP 0x001380f9
|
int1 [16]
JS_GetPropertyValue(int8 param_1,int8 param_2,int8 param_3,ulong param_4,
int8 param_5)
{
int1 auVar1 [16];
int iVar2;
char *pcVar3;
int1 auVar4 [16];
int8 local_40;
int8 local_38;
iVar2 = (int)param_3;
if (iVar2 == -1) {
if ((int)param_5 == 0) {
iVar2 = js_get_fast_array_element(param_1,param_2,param_4 & 0xffffffff,&local_40);
auVar4._8_8_ = local_38;
auVar4._0_8_ = local_40;
if (iVar2 != 0) {
return auVar4;
}
}
LAB_00138090:
iVar2 = JS_ValueToAtom(param_1,param_4,param_5);
JS_FreeValue(param_1,param_4,param_5);
if (iVar2 != 0) {
auVar4 = JS_GetProperty(param_1,param_2,param_3,iVar2);
JS_FreeAtom(param_1,iVar2);
return auVar4;
}
local_40 = (ulong)local_40._4_4_ << 0x20;
}
else {
if (iVar2 == 2) {
JS_FreeValue(param_1,param_4,param_5);
pcVar3 = "cannot read property of null";
}
else {
if (iVar2 != 3) goto LAB_00138090;
JS_FreeValue(param_1,param_4,param_5);
pcVar3 = "cannot read property of int";
}
JS_ThrowTypeError(param_1,pcVar3);
local_40 = 0;
}
auVar1._8_8_ = 6;
auVar1._0_8_ = local_40;
return auVar1;
}
| |
22,139 | add_cfg_dir | eloqsql/libmariadb/libmariadb/ma_default.c | static int add_cfg_dir(char **cfg_dirs, const char *directory)
{
int i;
for (i = 0; i < MAX_CONFIG_DIRS && cfg_dirs[i]; i++)
if (!strcmp(cfg_dirs[i], directory)) /* already present */
return 0;
if (i < MAX_CONFIG_DIRS) {
cfg_dirs[i]= strdup(directory);
return 0;
}
return 1;
} | O3 | c | add_cfg_dir:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
xorl %r15d, %r15d
movq (%rbx,%r15,8), %rdi
testq %rdi, %rdi
je 0x3663c
movq %r14, %rsi
callq 0x13660
testl %eax, %eax
je 0x36648
incq %r15
cmpq $0x6, %r15
jne 0x36617
movl $0x1, %eax
jmp 0x3664a
movq %r14, %rdi
callq 0x13810
movq %rax, (%rbx,%r15,8)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| add_cfg_dir:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov r14, rsi
mov rbx, rdi
xor r15d, r15d
loc_36617:
mov rdi, [rbx+r15*8]
test rdi, rdi
jz short loc_3663C
mov rsi, r14
call _strcmp
test eax, eax
jz short loc_36648
inc r15
cmp r15, 6
jnz short loc_36617
mov eax, 1
jmp short loc_3664A
loc_3663C:
mov rdi, r14
call _strdup
mov [rbx+r15*8], rax
loc_36648:
xor eax, eax
loc_3664A:
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
| long long add_cfg_dir(long long a1, long long a2)
{
long long v3; // r15
long long v4; // rdi
v3 = 0LL;
while ( 1 )
{
v4 = *(_QWORD *)(a1 + 8 * v3);
if ( !v4 )
break;
if ( !(unsigned int)strcmp(v4, a2) )
return 0LL;
if ( ++v3 == 6 )
return 1LL;
}
*(_QWORD *)(a1 + 8 * v3) = strdup(a2);
return 0LL;
}
| add_cfg_dir:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RSI
MOV RBX,RDI
XOR R15D,R15D
LAB_00136617:
MOV RDI,qword ptr [RBX + R15*0x8]
TEST RDI,RDI
JZ 0x0013663c
MOV RSI,R14
CALL 0x00113660
TEST EAX,EAX
JZ 0x00136648
INC R15
CMP R15,0x6
JNZ 0x00136617
MOV EAX,0x1
JMP 0x0013664a
LAB_0013663c:
MOV RDI,R14
CALL 0x00113810
MOV qword ptr [RBX + R15*0x8],RAX
LAB_00136648:
XOR EAX,EAX
LAB_0013664a:
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
|
int8 add_cfg_dir(long param_1,char *param_2)
{
int iVar1;
char *pcVar2;
long lVar3;
lVar3 = 0;
while( true ) {
pcVar2 = *(char **)(param_1 + lVar3 * 8);
if (pcVar2 == (char *)0x0) {
pcVar2 = strdup(param_2);
*(char **)(param_1 + lVar3 * 8) = pcVar2;
return 0;
}
iVar1 = strcmp(pcVar2,param_2);
if (iVar1 == 0) break;
lVar3 = lVar3 + 1;
if (lVar3 == 6) {
return 1;
}
}
return 0;
}
| |
22,140 | link_to_file_list | eloqsql/mysys/mf_keycache.c | static void link_to_file_list(SIMPLE_KEY_CACHE_CB *keycache,
BLOCK_LINK *block, int file,
my_bool unlink_block)
{
DBUG_ASSERT(block->status & BLOCK_IN_USE);
DBUG_ASSERT(block->hash_link && block->hash_link->block == block);
DBUG_ASSERT(block->hash_link->file == file);
if (unlink_block)
unlink_changed(block);
link_changed(block, &keycache->file_blocks[FILE_HASH(file, keycache)]);
if (block->status & BLOCK_CHANGED)
{
block->status&= ~BLOCK_CHANGED;
keycache->blocks_changed--;
keycache->global_blocks_changed--;
}
} | O0 | c | link_to_file_list:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movb %cl, %al
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movb %al, -0x15(%rbp)
jmp 0xe53aa
jmp 0xe53ac
jmp 0xe53ae
jmp 0xe53b0
jmp 0xe53b2
cmpb $0x0, -0x15(%rbp)
je 0xe53c1
movq -0x10(%rbp), %rdi
callq 0xe5570
movq -0x10(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x130(%rax), %rsi
movl -0x14(%rbp), %eax
movq -0x8(%rbp), %rcx
movl 0x3c(%rcx), %ecx
subl $0x1, %ecx
andl %ecx, %eax
movl %eax, %eax
shlq $0x3, %rax
addq %rax, %rsi
callq 0xe57d0
movq -0x10(%rbp), %rax
movl 0x50(%rax), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0xe542f
movq -0x10(%rbp), %rax
movl 0x50(%rax), %ecx
andl $-0x21, %ecx
movl %ecx, 0x50(%rax)
movq -0x8(%rbp), %rax
movq 0x60(%rax), %rcx
addq $-0x1, %rcx
movq %rcx, 0x60(%rax)
movq -0x8(%rbp), %rax
movq 0x138(%rax), %rcx
addq $-0x1, %rcx
movq %rcx, 0x138(%rax)
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| link_to_file_list_0:
push rbp
mov rbp, rsp
sub rsp, 20h
mov al, cl
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
mov [rbp+var_15], al
jmp short $+2
loc_E53AA:
jmp short $+2
loc_E53AC:
jmp short $+2
loc_E53AE:
jmp short $+2
loc_E53B0:
jmp short $+2
loc_E53B2:
cmp [rbp+var_15], 0
jz short loc_E53C1
mov rdi, [rbp+var_10]
call unlink_changed_0
loc_E53C1:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_8]
mov rsi, [rax+130h]
mov eax, [rbp+var_14]
mov rcx, [rbp+var_8]
mov ecx, [rcx+3Ch]
sub ecx, 1
and eax, ecx
mov eax, eax
shl rax, 3
add rsi, rax
call link_changed_0
mov rax, [rbp+var_10]
mov eax, [rax+50h]
and eax, 20h
cmp eax, 0
jz short loc_E542F
mov rax, [rbp+var_10]
mov ecx, [rax+50h]
and ecx, 0FFFFFFDFh
mov [rax+50h], ecx
mov rax, [rbp+var_8]
mov rcx, [rax+60h]
add rcx, 0FFFFFFFFFFFFFFFFh
mov [rax+60h], rcx
mov rax, [rbp+var_8]
mov rcx, [rax+138h]
add rcx, 0FFFFFFFFFFFFFFFFh
mov [rax+138h], rcx
loc_E542F:
add rsp, 20h
pop rbp
retn
| long long link_to_file_list_0(long long a1, long long a2, unsigned int a3, char a4)
{
long long result; // rax
if ( a4 )
unlink_changed_0(a2);
link_changed_0(a2, 8LL * ((*(_DWORD *)(a1 + 60) - 1) & a3) + *(_QWORD *)(a1 + 304));
result = *(_DWORD *)(a2 + 80) & 0x20;
if ( (_DWORD)result )
{
*(_DWORD *)(a2 + 80) &= ~0x20u;
--*(_QWORD *)(a1 + 96);
result = a1;
--*(_QWORD *)(a1 + 312);
}
return result;
}
| link_to_file_list:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV AL,CL
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
MOV byte ptr [RBP + -0x15],AL
JMP 0x001e53aa
LAB_001e53aa:
JMP 0x001e53ac
LAB_001e53ac:
JMP 0x001e53ae
LAB_001e53ae:
JMP 0x001e53b0
LAB_001e53b0:
JMP 0x001e53b2
LAB_001e53b2:
CMP byte ptr [RBP + -0x15],0x0
JZ 0x001e53c1
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001e5570
LAB_001e53c1:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RAX + 0x130]
MOV EAX,dword ptr [RBP + -0x14]
MOV RCX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RCX + 0x3c]
SUB ECX,0x1
AND EAX,ECX
MOV EAX,EAX
SHL RAX,0x3
ADD RSI,RAX
CALL 0x001e57d0
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x50]
AND EAX,0x20
CMP EAX,0x0
JZ 0x001e542f
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x50]
AND ECX,0xffffffdf
MOV dword ptr [RAX + 0x50],ECX
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x60]
ADD RCX,-0x1
MOV qword ptr [RAX + 0x60],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX + 0x138]
ADD RCX,-0x1
MOV qword ptr [RAX + 0x138],RCX
LAB_001e542f:
ADD RSP,0x20
POP RBP
RET
|
void link_to_file_list(long param_1,long param_2,uint param_3,char param_4)
{
if (param_4 != '\0') {
unlink_changed(param_2);
}
link_changed(param_2,*(long *)(param_1 + 0x130) +
(ulong)(param_3 & *(int *)(param_1 + 0x3c) - 1U) * 8);
if ((*(uint *)(param_2 + 0x50) & 0x20) != 0) {
*(uint *)(param_2 + 0x50) = *(uint *)(param_2 + 0x50) & 0xffffffdf;
*(long *)(param_1 + 0x60) = *(long *)(param_1 + 0x60) + -1;
*(long *)(param_1 + 0x138) = *(long *)(param_1 + 0x138) + -1;
}
return;
}
| |
22,141 | ma_keydef_write | eloqsql/storage/maria/ma_open.c | my_bool _ma_keydef_write(File file, MARIA_KEYDEF *keydef)
{
uchar buff[MARIA_KEYDEF_SIZE];
uchar *ptr=buff;
*ptr++= (uchar) keydef->keysegs;
*ptr++= keydef->key_alg; /* Rtree or Btree */
mi_int2store(ptr,keydef->flag); ptr+= 2;
mi_int2store(ptr,keydef->block_length); ptr+= 2;
mi_int2store(ptr,keydef->keylength); ptr+= 2;
mi_int2store(ptr,keydef->minlength); ptr+= 2;
mi_int2store(ptr,keydef->maxlength); ptr+= 2;
return mysql_file_write(file, buff, (size_t) (ptr-buff), MYF(MY_NABP)) != 0;
} | O0 | c | ma_keydef_write:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movl %edi, -0x18(%rbp)
movq %rsi, -0x20(%rbp)
leaq -0x14(%rbp), %rcx
movq %rcx, -0x28(%rbp)
movq -0x20(%rbp), %rax
movb 0xa0(%rax), %dl
movq -0x28(%rbp), %rax
movq %rax, %rsi
incq %rsi
movq %rsi, -0x28(%rbp)
movb %dl, (%rax)
movq -0x20(%rbp), %rax
movb 0xa4(%rax), %dl
movq -0x28(%rbp), %rax
movq %rax, %rsi
incq %rsi
movq %rsi, -0x28(%rbp)
movb %dl, (%rax)
movq -0x20(%rbp), %rax
movzwl 0xa2(%rax), %eax
movl %eax, -0x2c(%rbp)
movb -0x2c(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, 0x1(%rax)
movb -0x2b(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, (%rax)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movzwl 0xa6(%rax), %eax
movl %eax, -0x30(%rbp)
movb -0x30(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, 0x1(%rax)
movb -0x2f(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, (%rax)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movzwl 0xaa(%rax), %eax
movl %eax, -0x34(%rbp)
movb -0x34(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, 0x1(%rax)
movb -0x33(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, (%rax)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movzwl 0xac(%rax), %eax
movl %eax, -0x38(%rbp)
movb -0x38(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, 0x1(%rax)
movb -0x37(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, (%rax)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movzwl 0xae(%rax), %eax
movl %eax, -0x3c(%rbp)
movb -0x3c(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, 0x1(%rax)
movb -0x3b(%rbp), %dl
movq -0x28(%rbp), %rax
movb %dl, (%rax)
movq -0x28(%rbp), %rax
addq $0x2, %rax
movq %rax, -0x28(%rbp)
movl -0x18(%rbp), %edx
movq -0x28(%rbp), %r8
subq %rcx, %r8
leaq 0x112f5a(%rip), %rdi # 0x180894
movl $0x707, %esi # imm = 0x707
movl $0x4, %r9d
callq 0x6c780
testq %rax, %rax
setne %al
movb %al, -0x3d(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0x6d96e
movb -0x3d(%rbp), %al
addq $0x40, %rsp
popq %rbp
retq
callq 0x2a290
nopw %cs:(%rax,%rax)
| _ma_keydef_write:
push rbp
mov rbp, rsp
sub rsp, 40h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_18], edi
mov [rbp+var_20], rsi
lea rcx, [rbp+var_14]
mov [rbp+var_28], rcx
mov rax, [rbp+var_20]
mov dl, [rax+0A0h]
mov rax, [rbp+var_28]
mov rsi, rax
inc rsi
mov [rbp+var_28], rsi
mov [rax], dl
mov rax, [rbp+var_20]
mov dl, [rax+0A4h]
mov rax, [rbp+var_28]
mov rsi, rax
inc rsi
mov [rbp+var_28], rsi
mov [rax], dl
mov rax, [rbp+var_20]
movzx eax, word ptr [rax+0A2h]
mov [rbp+var_2C], eax
mov dl, byte ptr [rbp+var_2C]
mov rax, [rbp+var_28]
mov [rax+1], dl
mov dl, byte ptr [rbp+var_2C+1]
mov rax, [rbp+var_28]
mov [rax], dl
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
mov rax, [rbp+var_20]
movzx eax, word ptr [rax+0A6h]
mov [rbp+var_30], eax
mov dl, byte ptr [rbp+var_30]
mov rax, [rbp+var_28]
mov [rax+1], dl
mov dl, byte ptr [rbp+var_30+1]
mov rax, [rbp+var_28]
mov [rax], dl
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
mov rax, [rbp+var_20]
movzx eax, word ptr [rax+0AAh]
mov [rbp+var_34], eax
mov dl, byte ptr [rbp+var_34]
mov rax, [rbp+var_28]
mov [rax+1], dl
mov dl, byte ptr [rbp+var_34+1]
mov rax, [rbp+var_28]
mov [rax], dl
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
mov rax, [rbp+var_20]
movzx eax, word ptr [rax+0ACh]
mov [rbp+var_38], eax
mov dl, byte ptr [rbp+var_38]
mov rax, [rbp+var_28]
mov [rax+1], dl
mov dl, byte ptr [rbp+var_38+1]
mov rax, [rbp+var_28]
mov [rax], dl
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
mov rax, [rbp+var_20]
movzx eax, word ptr [rax+0AEh]
mov [rbp+var_3C], eax
mov dl, byte ptr [rbp+var_3C]
mov rax, [rbp+var_28]
mov [rax+1], dl
mov dl, byte ptr [rbp+var_3C+1]
mov rax, [rbp+var_28]
mov [rax], dl
mov rax, [rbp+var_28]
add rax, 2
mov [rbp+var_28], rax
mov edx, [rbp+var_18]
mov r8, [rbp+var_28]
sub r8, rcx
lea rdi, aWorkspaceLlm4b_13; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 707h
mov r9d, 4
call inline_mysql_file_write_0
test rax, rax
setnz al
mov [rbp+var_3D], al
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_6D96E
mov al, [rbp+var_3D]
add rsp, 40h
pop rbp
retn
loc_6D96E:
call ___stack_chk_fail
| bool ma_keydef_write(unsigned int a1, long long a2)
{
__int16 v2; // kr00_2
__int16 v3; // kr02_2
__int16 v4; // kr04_2
__int16 v5; // kr06_2
__int16 v6; // kr08_2
_BYTE v8[12]; // [rsp+2Ch] [rbp-14h] BYREF
unsigned long long v9; // [rsp+38h] [rbp-8h]
v9 = __readfsqword(0x28u);
v8[0] = *(_BYTE *)(a2 + 160);
v8[1] = *(_BYTE *)(a2 + 164);
v2 = *(_WORD *)(a2 + 162);
v8[2] = HIBYTE(v2);
v8[3] = v2;
v3 = *(_WORD *)(a2 + 166);
v8[4] = HIBYTE(v3);
v8[5] = v3;
v4 = *(_WORD *)(a2 + 170);
v8[6] = HIBYTE(v4);
v8[7] = v4;
v5 = *(_WORD *)(a2 + 172);
v8[8] = HIBYTE(v5);
v8[9] = v5;
v6 = *(_WORD *)(a2 + 174);
v8[10] = HIBYTE(v6);
v8[11] = v6;
return inline_mysql_file_write_0(
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_open.c",
0x707u,
a1,
(long long)v8,
12LL,
4LL) != 0;
}
| _ma_keydef_write:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV dword ptr [RBP + -0x18],EDI
MOV qword ptr [RBP + -0x20],RSI
LEA RCX,[RBP + -0x14]
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x20]
MOV DL,byte ptr [RAX + 0xa0]
MOV RAX,qword ptr [RBP + -0x28]
MOV RSI,RAX
INC RSI
MOV qword ptr [RBP + -0x28],RSI
MOV byte ptr [RAX],DL
MOV RAX,qword ptr [RBP + -0x20]
MOV DL,byte ptr [RAX + 0xa4]
MOV RAX,qword ptr [RBP + -0x28]
MOV RSI,RAX
INC RSI
MOV qword ptr [RBP + -0x28],RSI
MOV byte ptr [RAX],DL
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,word ptr [RAX + 0xa2]
MOV dword ptr [RBP + -0x2c],EAX
MOV DL,byte ptr [RBP + -0x2c]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x1],DL
MOV DL,byte ptr [RBP + -0x2b]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX],DL
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,word ptr [RAX + 0xa6]
MOV dword ptr [RBP + -0x30],EAX
MOV DL,byte ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x1],DL
MOV DL,byte ptr [RBP + -0x2f]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX],DL
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,word ptr [RAX + 0xaa]
MOV dword ptr [RBP + -0x34],EAX
MOV DL,byte ptr [RBP + -0x34]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x1],DL
MOV DL,byte ptr [RBP + -0x33]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX],DL
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,word ptr [RAX + 0xac]
MOV dword ptr [RBP + -0x38],EAX
MOV DL,byte ptr [RBP + -0x38]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x1],DL
MOV DL,byte ptr [RBP + -0x37]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX],DL
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOVZX EAX,word ptr [RAX + 0xae]
MOV dword ptr [RBP + -0x3c],EAX
MOV DL,byte ptr [RBP + -0x3c]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX + 0x1],DL
MOV DL,byte ptr [RBP + -0x3b]
MOV RAX,qword ptr [RBP + -0x28]
MOV byte ptr [RAX],DL
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,0x2
MOV qword ptr [RBP + -0x28],RAX
MOV EDX,dword ptr [RBP + -0x18]
MOV R8,qword ptr [RBP + -0x28]
SUB R8,RCX
LEA RDI,[0x280894]
MOV ESI,0x707
MOV R9D,0x4
CALL 0x0016c780
TEST RAX,RAX
SETNZ AL
MOV byte ptr [RBP + -0x3d],AL
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x0016d96e
MOV AL,byte ptr [RBP + -0x3d]
ADD RSP,0x40
POP RBP
RET
LAB_0016d96e:
CALL 0x0012a290
|
int8 _ma_keydef_write(int4 param_1,long param_2)
{
long lVar1;
long in_FS_OFFSET;
int1 local_44;
int1 uStack_43;
int1 local_40;
int1 uStack_3f;
int1 local_3c;
int1 uStack_3b;
int1 local_38;
int1 uStack_37;
int1 local_34;
int1 uStack_33;
int1 local_1c;
int1 local_1b;
int1 local_1a;
int1 local_19;
int1 local_18;
int1 local_17;
int1 local_16;
int1 local_15;
int1 local_14;
int1 local_13;
int1 local_12;
int1 local_11;
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_1c = *(int1 *)(param_2 + 0xa0);
local_1b = *(int1 *)(param_2 + 0xa4);
local_34 = (int1)*(int2 *)(param_2 + 0xa2);
local_19 = local_34;
uStack_33 = (int1)((ushort)*(int2 *)(param_2 + 0xa2) >> 8);
local_1a = uStack_33;
local_38 = (int1)*(int2 *)(param_2 + 0xa6);
local_17 = local_38;
uStack_37 = (int1)((ushort)*(int2 *)(param_2 + 0xa6) >> 8);
local_18 = uStack_37;
local_3c = (int1)*(int2 *)(param_2 + 0xaa);
local_15 = local_3c;
uStack_3b = (int1)((ushort)*(int2 *)(param_2 + 0xaa) >> 8);
local_16 = uStack_3b;
local_40 = (int1)*(int2 *)(param_2 + 0xac);
local_13 = local_40;
uStack_3f = (int1)((ushort)*(int2 *)(param_2 + 0xac) >> 8);
local_14 = uStack_3f;
local_44 = (int1)*(int2 *)(param_2 + 0xae);
local_11 = local_44;
uStack_43 = (int1)((ushort)*(int2 *)(param_2 + 0xae) >> 8);
local_12 = uStack_43;
lVar1 = inline_mysql_file_write
("/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_open.c",0x707,
param_1,&local_1c,(long)&local_10 - (long)&local_1c,4);
if (*(long *)(in_FS_OFFSET + 0x28) == local_10) {
return CONCAT71((int7)((ulong)*(long *)(in_FS_OFFSET + 0x28) >> 8),lVar1 != 0);
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
22,142 | common_embd_normalize(float const*, float*, int, int) | monkey531[P]llama/common/common.cpp | void common_embd_normalize(const float * inp, float * out, int n, int embd_norm) {
double sum = 0.0;
switch (embd_norm) {
case -1: // no normalisation
sum = 1.0;
break;
case 0: // max absolute
for (int i = 0; i < n; i++) {
if (sum < std::abs(inp[i])) {
sum = std::abs(inp[i]);
}
}
sum /= 32760.0; // make an int16 range
break;
case 2: // euclidean
for (int i = 0; i < n; i++) {
sum += inp[i] * inp[i];
}
sum = std::sqrt(sum);
break;
default: // p-norm (euclidean is p-norm p=2)
for (int i = 0; i < n; i++) {
sum += std::pow(std::abs(inp[i]), embd_norm);
}
sum = std::pow(sum, 1.0 / embd_norm);
break;
}
const float norm = sum > 0.0 ? 1.0 / sum : 0.0f;
for (int i = 0; i < n; i++) {
out[i] = inp[i] * norm;
}
} | O3 | cpp | common_embd_normalize(float const*, float*, int, int):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl %edx, %ebp
movq %rsi, %rbx
movq %rdi, %r14
movsd 0x76700(%rip), %xmm3 # 0xf0ae0
movapd %xmm3, %xmm0
cmpl $-0x1, %ecx
je 0x7a4f5
testl %ecx, %ecx
je 0x7a433
cmpl $0x2, %ecx
jne 0x7a469
xorpd %xmm1, %xmm1
xorpd %xmm0, %xmm0
testl %ebp, %ebp
jle 0x7a420
movl %ebp, %eax
xorl %ecx, %ecx
movss (%r14,%rcx,4), %xmm2
mulss %xmm2, %xmm2
cvtss2sd %xmm2, %xmm2
addsd %xmm2, %xmm0
incq %rcx
cmpq %rcx, %rax
jne 0x7a406
ucomisd %xmm1, %xmm0
jb 0x7a4c3
sqrtsd %xmm0, %xmm0
jmp 0x7a4f5
testl %ebp, %ebp
jle 0x7a4ca
movl %ebp, %eax
xorpd %xmm2, %xmm2
xorl %ecx, %ecx
movaps 0x76646(%rip), %xmm1 # 0xf0a90
movss (%r14,%rcx,4), %xmm0
andps %xmm1, %xmm0
cvtss2sd %xmm0, %xmm0
maxsd %xmm2, %xmm0
incq %rcx
movapd %xmm0, %xmm2
cmpq %rcx, %rax
jne 0x7a44a
jmp 0x7a4ce
cvtsi2sd %ecx, %xmm2
testl %ebp, %ebp
jle 0x7a4d8
movl %ebp, %r15d
xorpd %xmm0, %xmm0
xorl %r12d, %r12d
movsd %xmm2, 0x8(%rsp)
movsd %xmm0, (%rsp)
movss (%r14,%r12,4), %xmm0
andps 0x765fd(%rip), %xmm0 # 0xf0a90
cvtss2sd %xmm0, %xmm0
movapd %xmm2, %xmm1
callq 0x1c1b0
movsd 0x8(%rsp), %xmm2
movsd (%rsp), %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, (%rsp)
movsd (%rsp), %xmm0
incq %r12
cmpq %r12, %r15
jne 0x7a481
jmp 0x7a4dc
callq 0x1b810
jmp 0x7a4ed
xorpd %xmm0, %xmm0
divsd 0x76612(%rip), %xmm0 # 0xf0ae8
jmp 0x7a4f5
xorpd %xmm0, %xmm0
movsd 0x765fc(%rip), %xmm1 # 0xf0ae0
divsd %xmm2, %xmm1
callq 0x1c1b0
movsd 0x765eb(%rip), %xmm3 # 0xf0ae0
testl %ebp, %ebp
jle 0x7a52b
divsd %xmm0, %xmm3
xorps %xmm1, %xmm1
cmpltsd %xmm0, %xmm1
andpd %xmm3, %xmm1
xorps %xmm0, %xmm0
cvtsd2ss %xmm1, %xmm0
movl %ebp, %eax
xorl %ecx, %ecx
movss (%r14,%rcx,4), %xmm1
mulss %xmm0, %xmm1
movss %xmm1, (%rbx,%rcx,4)
incq %rcx
cmpq %rcx, %rax
jne 0x7a514
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| _Z21common_embd_normalizePKfPfii:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 10h
mov ebp, edx
mov rbx, rsi
mov r14, rdi
movsd xmm3, cs:qword_F0AE0
movapd xmm0, xmm3
cmp ecx, 0FFFFFFFFh
jz loc_7A4F5
test ecx, ecx
jz short loc_7A433
cmp ecx, 2
jnz short loc_7A469
xorpd xmm1, xmm1
xorpd xmm0, xmm0
test ebp, ebp
jle short loc_7A420
mov eax, ebp
xor ecx, ecx
loc_7A406:
movss xmm2, dword ptr [r14+rcx*4]
mulss xmm2, xmm2
cvtss2sd xmm2, xmm2
addsd xmm0, xmm2
inc rcx
cmp rax, rcx
jnz short loc_7A406
loc_7A420:
ucomisd xmm0, xmm1
jb loc_7A4C3
sqrtsd xmm0, xmm0
jmp loc_7A4F5
loc_7A433:
test ebp, ebp
jle loc_7A4CA
mov eax, ebp
xorpd xmm2, xmm2
xor ecx, ecx
movaps xmm1, cs:xmmword_F0A90
loc_7A44A:
movss xmm0, dword ptr [r14+rcx*4]
andps xmm0, xmm1
cvtss2sd xmm0, xmm0
maxsd xmm0, xmm2
inc rcx
movapd xmm2, xmm0
cmp rax, rcx
jnz short loc_7A44A
jmp short loc_7A4CE
loc_7A469:
cvtsi2sd xmm2, ecx
test ebp, ebp
jle short loc_7A4D8
mov r15d, ebp
xorpd xmm0, xmm0
xor r12d, r12d
movsd [rsp+38h+var_30], xmm2
loc_7A481:
movsd [rsp+38h+var_38], xmm0
movss xmm0, dword ptr [r14+r12*4]
andps xmm0, cs:xmmword_F0A90
cvtss2sd xmm0, xmm0
movapd xmm1, xmm2
call _pow
movsd xmm2, [rsp+38h+var_30]
movsd xmm1, [rsp+38h+var_38]
addsd xmm1, xmm0
movsd [rsp+38h+var_38], xmm1
movsd xmm0, [rsp+38h+var_38]
inc r12
cmp r15, r12
jnz short loc_7A481
jmp short loc_7A4DC
loc_7A4C3:
call _sqrt
jmp short loc_7A4ED
loc_7A4CA:
xorpd xmm0, xmm0
loc_7A4CE:
divsd xmm0, cs:qword_F0AE8
jmp short loc_7A4F5
loc_7A4D8:
xorpd xmm0, xmm0
loc_7A4DC:
movsd xmm1, cs:qword_F0AE0
divsd xmm1, xmm2
call _pow
loc_7A4ED:
movsd xmm3, cs:qword_F0AE0
loc_7A4F5:
test ebp, ebp
jle short loc_7A52B
divsd xmm3, xmm0
xorps xmm1, xmm1
cmpltsd xmm1, xmm0
andpd xmm1, xmm3
xorps xmm0, xmm0
cvtsd2ss xmm0, xmm1
mov eax, ebp
xor ecx, ecx
loc_7A514:
movss xmm1, dword ptr [r14+rcx*4]
mulss xmm1, xmm0
movss dword ptr [rbx+rcx*4], xmm1
inc rcx
cmp rax, rcx
jnz short loc_7A514
loc_7A52B:
add rsp, 10h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| void common_embd_normalize(const float *a1, float *a2, int a3, int a4)
{
__m128d v5; // xmm0
double v6; // xmm0_8
long long i; // rcx
double v8; // xmm2_8
long long v9; // rcx
double v10; // xmm0_8
double v11; // xmm2_8
double v12; // xmm0_8
long long v13; // r12
double v14; // xmm0_8
float v15; // xmm0_4
long long v16; // rcx
double v17; // [rsp+0h] [rbp-38h]
double v18; // [rsp+8h] [rbp-30h]
v5.m128d_f64[0] = 1.0;
if ( a4 != -1 )
{
if ( a4 )
{
if ( a4 == 2 )
{
v6 = 0.0;
if ( a3 > 0 )
{
for ( i = 0LL; i != a3; ++i )
v6 = v6 + (float)(a1[i] * a1[i]);
}
if ( v6 < 0.0 )
v5.m128d_f64[0] = sqrt(v6);
else
v5.m128d_f64[0] = sqrt(v6);
}
else
{
v11 = (double)a4;
if ( a3 <= 0 )
{
v12 = 0.0;
}
else
{
v12 = 0.0;
v13 = 0LL;
v18 = (double)a4;
do
{
v17 = v12;
v14 = pow(fabs(a1[v13]), v11);
v11 = v18;
v12 = v17 + v14;
++v13;
}
while ( a3 != v13 );
}
v5.m128d_f64[0] = pow(v12, 1.0 / v11);
}
}
else
{
if ( a3 <= 0 )
{
v10 = 0.0;
}
else
{
v8 = 0.0;
v9 = 0LL;
do
{
v10 = fmax(fabs(a1[v9++]), v8);
v8 = v10;
}
while ( a3 != v9 );
}
v5.m128d_f64[0] = v10 / 32760.0;
}
}
if ( a3 > 0 )
{
v15 = COERCE_DOUBLE(*(_OWORD *)&_mm_cmplt_sd((__m128d)0LL, v5) & COERCE_UNSIGNED_INT64(1.0 / v5.m128d_f64[0]));
v16 = 0LL;
do
{
a2[v16] = a1[v16] * v15;
++v16;
}
while ( a3 != v16 );
}
}
| common_embd_normalize:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV EBP,EDX
MOV RBX,RSI
MOV R14,RDI
MOVSD XMM3,qword ptr [0x001f0ae0]
MOVAPD XMM0,XMM3
CMP ECX,-0x1
JZ 0x0017a4f5
TEST ECX,ECX
JZ 0x0017a433
CMP ECX,0x2
JNZ 0x0017a469
XORPD XMM1,XMM1
XORPD XMM0,XMM0
TEST EBP,EBP
JLE 0x0017a420
MOV EAX,EBP
XOR ECX,ECX
LAB_0017a406:
MOVSS XMM2,dword ptr [R14 + RCX*0x4]
MULSS XMM2,XMM2
CVTSS2SD XMM2,XMM2
ADDSD XMM0,XMM2
INC RCX
CMP RAX,RCX
JNZ 0x0017a406
LAB_0017a420:
UCOMISD XMM0,XMM1
JC 0x0017a4c3
SQRTSD XMM0,XMM0
JMP 0x0017a4f5
LAB_0017a433:
TEST EBP,EBP
JLE 0x0017a4ca
MOV EAX,EBP
XORPD XMM2,XMM2
XOR ECX,ECX
MOVAPS XMM1,xmmword ptr [0x001f0a90]
LAB_0017a44a:
MOVSS XMM0,dword ptr [R14 + RCX*0x4]
ANDPS XMM0,XMM1
CVTSS2SD XMM0,XMM0
MAXSD XMM0,XMM2
INC RCX
MOVAPD XMM2,XMM0
CMP RAX,RCX
JNZ 0x0017a44a
JMP 0x0017a4ce
LAB_0017a469:
CVTSI2SD XMM2,ECX
TEST EBP,EBP
JLE 0x0017a4d8
MOV R15D,EBP
XORPD XMM0,XMM0
XOR R12D,R12D
MOVSD qword ptr [RSP + 0x8],XMM2
LAB_0017a481:
MOVSD qword ptr [RSP],XMM0
MOVSS XMM0,dword ptr [R14 + R12*0x4]
ANDPS XMM0,xmmword ptr [0x001f0a90]
CVTSS2SD XMM0,XMM0
MOVAPD XMM1,XMM2
CALL 0x0011c1b0
MOVSD XMM2,qword ptr [RSP + 0x8]
MOVSD XMM1,qword ptr [RSP]
ADDSD XMM1,XMM0
MOVSD qword ptr [RSP],XMM1
MOVSD XMM0,qword ptr [RSP]
INC R12
CMP R15,R12
JNZ 0x0017a481
JMP 0x0017a4dc
LAB_0017a4c3:
CALL 0x0011b810
JMP 0x0017a4ed
LAB_0017a4ca:
XORPD XMM0,XMM0
LAB_0017a4ce:
DIVSD XMM0,qword ptr [0x001f0ae8]
JMP 0x0017a4f5
LAB_0017a4d8:
XORPD XMM0,XMM0
LAB_0017a4dc:
MOVSD XMM1,qword ptr [0x001f0ae0]
DIVSD XMM1,XMM2
CALL 0x0011c1b0
LAB_0017a4ed:
MOVSD XMM3,qword ptr [0x001f0ae0]
LAB_0017a4f5:
TEST EBP,EBP
JLE 0x0017a52b
DIVSD XMM3,XMM0
XORPS XMM1,XMM1
CMPLTSD XMM1,XMM0
ANDPD XMM1,XMM3
XORPS XMM0,XMM0
CVTSD2SS XMM0,XMM1
MOV EAX,EBP
XOR ECX,ECX
LAB_0017a514:
MOVSS XMM1,dword ptr [R14 + RCX*0x4]
MULSS XMM1,XMM0
MOVSS dword ptr [RBX + RCX*0x4],XMM1
INC RCX
CMP RAX,RCX
JNZ 0x0017a514
LAB_0017a52b:
ADD RSP,0x10
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* common_embd_normalize(float const*, float*, int, int) */
void common_embd_normalize(float *param_1,float *param_2,int param_3,int param_4)
{
ulong uVar1;
double dVar2;
double dVar3;
dVar2 = DAT_001f0ae0;
if (param_4 != -1) {
if (param_4 == 0) {
if (param_3 < 1) {
dVar2 = 0.0;
}
else {
uVar1 = 0;
dVar3 = 0.0;
do {
dVar2 = (double)(float)((uint)param_1[uVar1] & _DAT_001f0a90);
if ((double)(float)((uint)param_1[uVar1] & _DAT_001f0a90) <= dVar3) {
dVar2 = dVar3;
}
uVar1 = uVar1 + 1;
dVar3 = dVar2;
} while ((uint)param_3 != uVar1);
}
dVar2 = dVar2 / _DAT_001f0ae8;
}
else if (param_4 == 2) {
dVar2 = 0.0;
if (0 < param_3) {
uVar1 = 0;
do {
dVar2 = dVar2 + (double)(param_1[uVar1] * param_1[uVar1]);
uVar1 = uVar1 + 1;
} while ((uint)param_3 != uVar1);
}
if (0.0 <= dVar2) {
dVar2 = SQRT(dVar2);
}
else {
dVar2 = sqrt(dVar2);
}
}
else {
if (param_3 < 1) {
dVar2 = 0.0;
}
else {
dVar2 = 0.0;
uVar1 = 0;
do {
dVar3 = pow((double)(float)((uint)param_1[uVar1] & _DAT_001f0a90),(double)param_4);
dVar2 = dVar2 + dVar3;
uVar1 = uVar1 + 1;
} while ((uint)param_3 != uVar1);
}
dVar2 = pow(dVar2,DAT_001f0ae0 / (double)param_4);
}
}
if (0 < param_3) {
dVar3 = DAT_001f0ae0 / dVar2;
uVar1 = 0;
do {
param_2[uVar1] = param_1[uVar1] * (float)(double)(-(ulong)(0.0 < dVar2) & (ulong)dVar3);
uVar1 = uVar1 + 1;
} while ((uint)param_3 != uVar1);
}
return;
}
| |
22,143 | atoi_octal | eloqsql/mysys/my_init.c | static ulong atoi_octal(const char *str)
{
long int tmp;
while (*str && my_isspace(&my_charset_latin1, *str))
str++;
str2int(str,
(*str == '0' ? 8 : 10), /* Octalt or decimalt */
0, INT_MAX, &tmp);
return (ulong) tmp;
} | O3 | c | atoi_octal:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movb (%rdi), %al
movl $0xa, %esi
testb %al, %al
je 0x6a972
leaq 0x3096d6(%rip), %rcx # 0x374020
movq 0x40(%rcx), %rcx
movzbl %al, %edx
testb $0x8, 0x1(%rcx,%rdx)
je 0x6a964
movb 0x1(%rdi), %al
incq %rdi
testb %al, %al
jne 0x6a94e
jmp 0x6a972
xorl %ecx, %ecx
cmpb $0x30, %al
setne %cl
leal 0x8(,%rcx,2), %esi
leaq -0x10(%rbp), %rbx
movl $0x7fffffff, %ecx # imm = 0x7FFFFFFF
xorl %edx, %edx
movq %rbx, %r8
callq 0x9b700
movq (%rbx), %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| atoi_octal:
push rbp
mov rbp, rsp
push rbx
push rax
mov al, [rdi]
mov esi, 0Ah
test al, al
jz short loc_6A972
lea rcx, my_charset_latin1
mov rcx, [rcx+40h]
loc_6A94E:
movzx edx, al
test byte ptr [rcx+rdx+1], 8
jz short loc_6A964
mov al, [rdi+1]
inc rdi
test al, al
jnz short loc_6A94E
jmp short loc_6A972
loc_6A964:
xor ecx, ecx
cmp al, 30h ; '0'
setnz cl
lea esi, ds:8[rcx*2]
loc_6A972:
lea rbx, [rbp+var_10]
mov ecx, 7FFFFFFFh
xor edx, edx
mov r8, rbx
call str2int
mov rax, [rbx]
add rsp, 8
pop rbx
pop rbp
retn
| void __spoils<rdx,rcx,r8,r9,r10,r11,xmm4,xmm5> atoi_octal(unsigned __int8 *a1)
{
unsigned __int8 v1; // al
long long v2; // rsi
_BYTE v3[16]; // [rsp+0h] [rbp-10h] BYREF
v1 = *a1;
v2 = 10LL;
if ( *a1 )
{
while ( (*(_BYTE *)(*((_QWORD *)&my_charset_latin1 + 8) + v1 + 1LL) & 8) != 0 )
{
v1 = *++a1;
if ( !v1 )
goto LABEL_6;
}
v2 = 2 * (unsigned int)(v1 != 48) + 8;
}
LABEL_6:
str2int(a1, v2, 0LL, 0x7FFFFFFFLL, v3);
}
| atoi_octal:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV AL,byte ptr [RDI]
MOV ESI,0xa
TEST AL,AL
JZ 0x0016a972
LEA RCX,[0x474020]
MOV RCX,qword ptr [RCX + 0x40]
LAB_0016a94e:
MOVZX EDX,AL
TEST byte ptr [RCX + RDX*0x1 + 0x1],0x8
JZ 0x0016a964
MOV AL,byte ptr [RDI + 0x1]
INC RDI
TEST AL,AL
JNZ 0x0016a94e
JMP 0x0016a972
LAB_0016a964:
XOR ECX,ECX
CMP AL,0x30
SETNZ CL
LEA ESI,[0x8 + RCX*0x2]
LAB_0016a972:
LEA RBX,[RBP + -0x10]
MOV ECX,0x7fffffff
XOR EDX,EDX
MOV R8,RBX
CALL 0x0019b700
MOV RAX,qword ptr [RBX]
ADD RSP,0x8
POP RBX
POP RBP
RET
|
int8 atoi_octal(byte *param_1)
{
byte bVar1;
int8 in_RAX;
char cVar2;
int8 local_18;
bVar1 = *param_1;
cVar2 = '\n';
do {
if (bVar1 == 0) {
LAB_0016a972:
local_18 = in_RAX;
str2int(param_1,cVar2,0,0x7fffffff,&local_18);
return local_18;
}
if ((PTR_ctype_latin1_00474060[(ulong)bVar1 + 1] & 8) == 0) {
cVar2 = (bVar1 != 0x30) * '\x02' + '\b';
goto LAB_0016a972;
}
bVar1 = param_1[1];
param_1 = param_1 + 1;
} while( true );
}
| |
22,144 | my_caseup_8bit | eloqsql/strings/ctype-simple.c | size_t my_caseup_8bit(CHARSET_INFO * cs, const char *src, size_t srclen,
char *dst, size_t dstlen __attribute__((unused)))
{
const char *end= src + srclen;
register const uchar *map= cs->to_upper;
DBUG_ASSERT(srclen <= dstlen);
for ( ; src != end ; src++)
*dst++= (char) map[(uchar) *src];
return srclen;
} | O3 | c | my_caseup_8bit:
movq %rdx, %rax
testq %rdx, %rdx
je 0x38413
pushq %rbp
movq %rsp, %rbp
movq 0x50(%rdi), %rdx
xorl %edi, %edi
movzbl (%rsi,%rdi), %r8d
movb (%rdx,%r8), %r8b
movb %r8b, (%rcx,%rdi)
incq %rdi
cmpq %rdi, %rax
jne 0x383fd
popq %rbp
retq
| my_caseup_8bit:
mov rax, rdx
test rdx, rdx
jz short locret_38413
push rbp
mov rbp, rsp
mov rdx, [rdi+50h]
xor edi, edi
loc_383FD:
movzx r8d, byte ptr [rsi+rdi]
mov r8b, [rdx+r8]
mov [rcx+rdi], r8b
inc rdi
cmp rax, rdi
jnz short loc_383FD
pop rbp
locret_38413:
retn
| long long my_caseup_8bit(long long a1, long long a2, long long a3, long long a4)
{
long long result; // rax
long long v5; // rdx
long long v6; // rdi
result = a3;
if ( a3 )
{
v5 = *(_QWORD *)(a1 + 80);
v6 = 0LL;
do
{
*(_BYTE *)(a4 + v6) = *(_BYTE *)(v5 + *(unsigned __int8 *)(a2 + v6));
++v6;
}
while ( result != v6 );
}
return result;
}
| my_caseup_8bit:
MOV RAX,RDX
TEST RDX,RDX
JZ 0x00138413
PUSH RBP
MOV RBP,RSP
MOV RDX,qword ptr [RDI + 0x50]
XOR EDI,EDI
LAB_001383fd:
MOVZX R8D,byte ptr [RSI + RDI*0x1]
MOV R8B,byte ptr [RDX + R8*0x1]
MOV byte ptr [RCX + RDI*0x1],R8B
INC RDI
CMP RAX,RDI
JNZ 0x001383fd
POP RBP
LAB_00138413:
RET
|
void my_caseup_8bit(long param_1,long param_2,long param_3,long param_4)
{
long lVar1;
long lVar2;
if (param_3 != 0) {
lVar1 = *(long *)(param_1 + 0x50);
lVar2 = 0;
do {
*(int1 *)(param_4 + lVar2) = *(int1 *)(lVar1 + (ulong)*(byte *)(param_2 + lVar2));
lVar2 = lVar2 + 1;
} while (param_3 != lVar2);
}
return;
}
| |
22,145 | Bfree | eloqsql/libmariadb/libmariadb/ma_dtoa.c | static void Bfree(Bigint *v, Stack_alloc *alloc)
{
char *gptr= (char*) v; /* generic pointer */
if (gptr < alloc->begin || gptr >= alloc->end)
free(gptr);
else if (v->k <= Kmax)
{
/*
Maintain free lists only for stack objects: this way we don't
have to bother with freeing lists in the end of dtoa;
heap should not be used normally anyway.
*/
v->p.next= alloc->freelist[v->k];
alloc->freelist[v->k]= v;
}
} | O3 | c | Bfree:
pushq %rbp
movq %rsp, %rbp
cmpq %rdi, (%rsi)
ja 0x2b87a
cmpq %rdi, 0x10(%rsi)
jbe 0x2b87a
movslq 0x8(%rdi), %rax
cmpq $0xf, %rax
jg 0x2b878
movq 0x18(%rsi,%rax,8), %rcx
movq %rcx, (%rdi)
movq %rdi, 0x18(%rsi,%rax,8)
popq %rbp
retq
popq %rbp
jmp 0x13580
| Bfree:
push rbp
mov rbp, rsp
cmp [rsi], rdi
ja short loc_2B87A
cmp [rsi+10h], rdi
jbe short loc_2B87A
movsxd rax, dword ptr [rdi+8]
cmp rax, 0Fh
jg short loc_2B878
mov rcx, [rsi+rax*8+18h]
mov [rdi], rcx
mov [rsi+rax*8+18h], rdi
loc_2B878:
pop rbp
retn
loc_2B87A:
pop rbp
jmp _free
| long long Bfree(unsigned long long a1, unsigned long long *a2)
{
long long result; // rax
if ( *a2 > a1 || a2[2] <= a1 )
return free(a1);
result = *(int *)(a1 + 8);
if ( result <= 15 )
{
*(_QWORD *)a1 = a2[result + 3];
a2[result + 3] = a1;
}
return result;
}
| Bfree:
PUSH RBP
MOV RBP,RSP
CMP qword ptr [RSI],RDI
JA 0x0012b87a
CMP qword ptr [RSI + 0x10],RDI
JBE 0x0012b87a
MOVSXD RAX,dword ptr [RDI + 0x8]
CMP RAX,0xf
JG 0x0012b878
MOV RCX,qword ptr [RSI + RAX*0x8 + 0x18]
MOV qword ptr [RDI],RCX
MOV qword ptr [RSI + RAX*0x8 + 0x18],RDI
LAB_0012b878:
POP RBP
RET
LAB_0012b87a:
POP RBP
JMP 0x00113580
|
void Bfree(ulong *param_1,ulong *param_2)
{
long lVar1;
if (((ulong *)*param_2 <= param_1) && (param_1 < (ulong *)param_2[2])) {
lVar1 = (long)(int)param_1[1];
if (lVar1 < 0x10) {
*param_1 = param_2[lVar1 + 3];
param_2[lVar1 + 3] = (ulong)param_1;
}
return;
}
free(param_1);
return;
}
| |
22,146 | httpdwnld_download | navaro[P]qoraal-tictactoe/build_O3/_deps/qoraal_http-src/src/httpdwnld.c | int32_t
httpdwnld_download (HTTPDWNLD_T * dwnld,
uint32_t timeout, HTTP_CLIENT_DOWNLOAD_CB cb, uintptr_t parm)
{
HTTP_CLIENT_T client ;
struct sockaddr_in addr ;
// int i = 0 ;
int32_t res ;
int32_t status ;
int32_t read = 0 ;
uint8_t* response ;
uint32_t ip ;
memset(&addr, 0, sizeof(addr));
addr.sin_family = AF_INET;
addr.sin_port = htons((uint16_t)dwnld->port);
#if QORAAL_CFG_USE_LWIP
addr.sin_len = sizeof(addr);
#endif
if (gethostbyname_timeout (dwnld->host, &ip, 6) != EOK) {
DBG_MESSAGE_HTTP_CLIENT (DBG_MESSAGE_SEVERITY_ERROR,
"HTTP : : resolving %s failed!", dwnld->host) ;
return HTTP_CLIENT_E_HOST ;
}
addr.sin_addr.s_addr = /*ntohl*/(ip) ;
httpclient_init (&client, dwnld->mss) ;
if (dwnld->host) {
httpclient_set_hostname (&client, dwnld->host) ;
}
res = httpclient_connect (&client, &addr, dwnld->https) ;
if (res != HTTP_CLIENT_E_OK) {
DBG_MESSAGE_HTTP_CLIENT (DBG_MESSAGE_SEVERITY_REPORT,
"HTTP : : httpclient_connect failed!");
httpclient_close (&client) ;
return res ;
}
res = cb (1, 0, 0, parm) ;
if (res != EOK) {
httpclient_close (&client) ;
return res ;
}
do {
if (dwnld->postlen) {
DBG_MESSAGE_HTTP_CLIENT (DBG_MESSAGE_SEVERITY_LOG,
"HTTP : : POST %s %s", dwnld->host, dwnld->https ? "usinng SSL" : "");
res = httpclient_post_stream(&client, dwnld->name, dwnld->stream, dwnld->parm, dwnld->postlen, dwnld->credentials) ;
} else {
DBG_MESSAGE_HTTP_CLIENT (DBG_MESSAGE_SEVERITY_LOG,
"HTTP : : GET %s %s", dwnld->host, dwnld->https ? "usinng SSL" : "");
res = httpclient_get(&client, dwnld->name, dwnld->credentials) ;
}
if ((res > HTTP_CLIENT_E_OK)) {
res = httpclient_read_response_ex (&client, timeout, &status) ;
if (status/100 != 2) {
res = status ? HTTP_CLIENT_E_CONTENT : HTTP_CLIENT_E_CONNECTION ;
}
if (res >= 0) {
res = cb (status, 0, 0, parm) ;
}
if (res == EOK) {
while (1) {
res = httpclient_read_next_ex (&client, timeout, &response) ;
if (res <= 0) {
break ;
}
read += res ;
res = cb (0, response, res, parm) ;
if (res != EOK) {
break;
}
}
} else {
DBG_MESSAGE_HTTP_CLIENT (DBG_MESSAGE_SEVERITY_REPORT,
"HTTP : : httpclient_read_response_ex failed %d status %d!",
res, status) ;
}
httpclient_read_complete_ex (&client) ;
} else {
DBG_MESSAGE_HTTP_CLIENT (DBG_MESSAGE_SEVERITY_ERROR,
"HTTP : : httpclient_get failed %d!", res) ;
}
} while (0) ;
httpclient_close (&client) ;
return res < 0 ? res : read ;
} | O3 | c | httpdwnld_download:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xb8, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movl %esi, %r15d
movq %rdi, %r13
movq $0x0, -0x38(%rbp)
movw $0x2, -0x40(%rbp)
movzwl 0x4(%rdi), %eax
rolw $0x8, %ax
movw %ax, -0x3e(%rbp)
movq 0x8(%rdi), %rdi
leaq -0x2c(%rbp), %rsi
movl $0x6, %edx
callq 0x214b0
testl %eax, %eax
je 0x20f0b
movq 0x8(%r13), %rcx
leaq 0x12c32(%rip), %rdx # 0x33b27
movl $0x2, %edi
xorl %esi, %esi
xorl %eax, %eax
callq 0x160ad
movl $0xfffffff7, %r12d # imm = 0xFFFFFFF7
jmp 0x20f8a
movl -0x2c(%rbp), %eax
movl %eax, -0x3c(%rbp)
movl 0x30(%r13), %esi
leaq -0xe0(%rbp), %rdi
callq 0x1fc04
movq 0x8(%r13), %rsi
testq %rsi, %rsi
je 0x20f36
leaq -0xe0(%rbp), %rdi
callq 0x1fd0f
movl (%r13), %edx
leaq -0xe0(%rbp), %rdi
leaq -0x40(%rbp), %rsi
callq 0x1fc31
testl %eax, %eax
je 0x20f68
movl %eax, %r12d
leaq 0x12bee(%rip), %rdx # 0x33b46
movl $0x4, %edi
xorl %esi, %esi
xorl %eax, %eax
callq 0x160ad
jmp 0x20f7e
movl $0x1, %edi
xorl %esi, %esi
xorl %edx, %edx
movq %rbx, %rcx
callq *%r14
testl %eax, %eax
je 0x20f9f
movl %eax, %r12d
leaq -0xe0(%rbp), %rdi
callq 0x1fdaa
movl %r12d, %eax
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
cmpl $0x0, (%r13)
leaq 0x5e20(%rip), %rax # 0x26dcb
leaq 0x12bce(%rip), %r8 # 0x33b80
cmoveq %rax, %r8
cmpl $0x0, 0x2c(%r13)
movq 0x8(%r13), %rcx
je 0x20ff8
leaq 0x12ba3(%rip), %rdx # 0x33b6b
movl $0x5, %edi
xorl %esi, %esi
xorl %eax, %eax
callq 0x160ad
movq 0x20(%r13), %rdx
movl 0x28(%r13), %ecx
movl 0x2c(%r13), %r8d
movq 0x10(%r13), %rsi
movq 0x18(%r13), %r9
leaq -0xe0(%rbp), %rdi
callq 0x203a4
jmp 0x21021
leaq 0x12b8c(%rip), %rdx # 0x33b8b
movl $0x5, %edi
xorl %esi, %esi
xorl %eax, %eax
callq 0x160ad
movq 0x10(%r13), %rsi
movq 0x18(%r13), %rdx
leaq -0xe0(%rbp), %rdi
callq 0x1fdd7
movl %eax, %r13d
testl %eax, %eax
jle 0x210e0
leaq -0xe0(%rbp), %rdi
leaq -0x30(%rbp), %r12
movl %r15d, %esi
movq %r12, %rdx
callq 0x20907
movl (%r12), %r8d
leal -0xc8(%r8), %ecx
xorl %r13d, %r13d
testl %r8d, %r8d
sete %r13b
addl %r13d, %r13d
orl $-0x4, %r13d
cmpl $0x64, %ecx
cmovbl %eax, %r13d
testl %r13d, %r13d
js 0x21085
xorl %r12d, %r12d
movl %r8d, %edi
xorl %esi, %esi
xorl %edx, %edx
movq %rbx, %rcx
callq *%r14
testl %eax, %eax
je 0x210c4
movl %eax, %r13d
movl -0x30(%rbp), %r8d
leaq 0x12b13(%rip), %rdx # 0x33b9f
xorl %r12d, %r12d
movl $0x4, %edi
xorl %esi, %esi
movl %r13d, %ecx
xorl %eax, %eax
callq 0x160ad
leaq -0xe0(%rbp), %rdi
callq 0x20e0a
jmp 0x210fb
addl %r13d, %r12d
movq -0x48(%rbp), %rsi
xorl %edi, %edi
movl %r13d, %edx
movq %rbx, %rcx
callq *%r14
testl %eax, %eax
jne 0x21113
leaq -0xe0(%rbp), %rdi
movl %r15d, %esi
leaq -0x48(%rbp), %rdx
callq 0x20b77
movl %eax, %r13d
testl %eax, %eax
jg 0x210ae
jmp 0x210a0
leaq 0x12af3(%rip), %rdx # 0x33bda
xorl %r12d, %r12d
movl $0x2, %edi
xorl %esi, %esi
movl %r13d, %ecx
xorl %eax, %eax
callq 0x160ad
leaq -0xe0(%rbp), %rdi
callq 0x1fdaa
testl %r13d, %r13d
cmovsl %r13d, %r12d
jmp 0x20f8a
movl %eax, %r13d
jmp 0x210a0
| httpdwnld_download:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0B8h
mov rbx, rcx
mov r14, rdx
mov r15d, esi
mov r13, rdi
mov [rbp+var_38], 0
mov [rbp+var_40], 2
movzx eax, word ptr [rdi+4]
rol ax, 8
mov [rbp+var_3E], ax
mov rdi, [rdi+8]
lea rsi, [rbp+var_2C]
mov edx, 6
call gethostbyname_timeout
test eax, eax
jz short loc_20F0B
mov rcx, [r13+8]
lea rdx, aHttpResolvingS_0; "HTTP : : resolving %s failed!"
mov edi, 2
xor esi, esi
xor eax, eax
call svc_logger_type_log
mov r12d, 0FFFFFFF7h
jmp short loc_20F8A
loc_20F0B:
mov eax, [rbp+var_2C]
mov [rbp+var_3C], eax
mov esi, [r13+30h]
lea rdi, [rbp+var_E0]
call httpclient_init
mov rsi, [r13+8]
test rsi, rsi
jz short loc_20F36
lea rdi, [rbp+var_E0]
call httpclient_set_hostname
loc_20F36:
mov edx, [r13+0]
lea rdi, [rbp+var_E0]
lea rsi, [rbp+var_40]
call httpclient_connect
test eax, eax
jz short loc_20F68
mov r12d, eax
lea rdx, aHttpHttpclient_7; "HTTP : : httpclient_connect failed!"
mov edi, 4
xor esi, esi
xor eax, eax
call svc_logger_type_log
jmp short loc_20F7E
loc_20F68:
mov edi, 1
xor esi, esi
xor edx, edx
mov rcx, rbx
call r14
test eax, eax
jz short loc_20F9F
mov r12d, eax
loc_20F7E:
lea rdi, [rbp+var_E0]
call httpclient_close
loc_20F8A:
mov eax, r12d
add rsp, 0B8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_20F9F:
cmp dword ptr [r13+0], 0
lea rax, asc_26DC6+5; ""
lea r8, aUsinngSsl; "usinng SSL"
cmovz r8, rax
cmp dword ptr [r13+2Ch], 0
mov rcx, [r13+8]
jz short loc_20FF8
lea rdx, aHttpPostSS; "HTTP : : POST %s %s"
mov edi, 5
xor esi, esi
xor eax, eax
call svc_logger_type_log
mov rdx, [r13+20h]
mov ecx, [r13+28h]
mov r8d, [r13+2Ch]
mov rsi, [r13+10h]
mov r9, [r13+18h]
lea rdi, [rbp+var_E0]
call httpclient_post_stream
jmp short loc_21021
loc_20FF8:
lea rdx, aHttpGetSS; "HTTP : : GET %s %s"
mov edi, 5
xor esi, esi
xor eax, eax
call svc_logger_type_log
mov rsi, [r13+10h]
mov rdx, [r13+18h]
lea rdi, [rbp+var_E0]
call httpclient_get
loc_21021:
mov r13d, eax
test eax, eax
jle loc_210E0
lea rdi, [rbp+var_E0]
lea r12, [rbp+var_30]
mov esi, r15d
mov rdx, r12
call httpclient_read_response_ex
mov r8d, [r12]
lea ecx, [r8-0C8h]
xor r13d, r13d
test r8d, r8d
setz r13b
add r13d, r13d
or r13d, 0FFFFFFFCh
cmp ecx, 64h ; 'd'
cmovb r13d, eax
test r13d, r13d
js short loc_21085
xor r12d, r12d
mov edi, r8d
xor esi, esi
xor edx, edx
mov rcx, rbx
call r14
test eax, eax
jz short loc_210C4
mov r13d, eax
mov r8d, [rbp+var_30]
loc_21085:
lea rdx, aHttpHttpclient_8; "HTTP : : httpclient_read_response_ex f"...
xor r12d, r12d
mov edi, 4
xor esi, esi
mov ecx, r13d
xor eax, eax
call svc_logger_type_log
loc_210A0:
lea rdi, [rbp+var_E0]
call httpclient_read_complete_ex
jmp short loc_210FB
loc_210AE:
add r12d, r13d
mov rsi, [rbp+var_48]
xor edi, edi
mov edx, r13d
mov rcx, rbx
call r14
test eax, eax
jnz short loc_21113
loc_210C4:
lea rdi, [rbp+var_E0]
mov esi, r15d
lea rdx, [rbp+var_48]
call httpclient_read_next_ex
mov r13d, eax
test eax, eax
jg short loc_210AE
jmp short loc_210A0
loc_210E0:
lea rdx, aHttpHttpclient_9; "HTTP : : httpclient_get failed %d!"
xor r12d, r12d
mov edi, 2
xor esi, esi
mov ecx, r13d
xor eax, eax
call svc_logger_type_log
loc_210FB:
lea rdi, [rbp+var_E0]
call httpclient_close
test r13d, r13d
cmovs r12d, r13d
jmp loc_20F8A
loc_21113:
mov r13d, eax
jmp short loc_210A0
| long long httpdwnld_download(
unsigned int *a1,
unsigned int a2,
long long ( *a3)(long long, long long, _QWORD, long long),
long long a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
double a9,
double a10,
__m128 a11,
__m128 a12)
{
long long v15; // r8
long long v16; // r9
__m128 v17; // xmm4
__m128 v18; // xmm5
unsigned int v19; // r12d
long long v20; // rcx
long long v21; // r8
long long v22; // r9
__m128 v23; // xmm4
__m128 v24; // xmm5
long long v25; // rsi
unsigned int v26; // eax
long long v27; // rcx
long long v28; // r8
long long v29; // r9
__m128 v30; // xmm4
__m128 v31; // xmm5
unsigned int v32; // eax
long long v33; // r9
__m128 v34; // xmm4
__m128 v35; // xmm5
char *v37; // r8
long long v38; // rcx
__m128 v39; // xmm4
__m128 v40; // xmm5
int v41; // eax
long long v42; // rcx
long long v43; // r8
long long v44; // r9
__m128 v45; // xmm4
__m128 v46; // xmm5
long long v47; // rcx
long long v48; // r8
long long v49; // r9
__m128 v50; // xmm4
__m128 v51; // xmm5
signed int v52; // r13d
signed int v53; // eax
long long v54; // r9
__m128 v55; // xmm4
__m128 v56; // xmm5
long long v57; // r8
signed int v58; // eax
long long v59; // rcx
long long v60; // r8
signed int v61; // eax
int v62; // eax
unsigned int v63[38]; // [rsp+0h] [rbp-E0h] BYREF
long long v64; // [rsp+98h] [rbp-48h] BYREF
_WORD v65[2]; // [rsp+A0h] [rbp-40h] BYREF
int v66; // [rsp+A4h] [rbp-3Ch]
long long v67; // [rsp+A8h] [rbp-38h]
unsigned int v68; // [rsp+B0h] [rbp-30h] BYREF
_DWORD v69[11]; // [rsp+B4h] [rbp-2Ch] BYREF
v67 = 0LL;
v65[0] = 2;
v65[1] = __ROL2__(*((_WORD *)a1 + 2), 8);
if ( (unsigned int)gethostbyname_timeout(*((_QWORD *)a1 + 1), v69, 6LL) )
{
svc_logger_type_log(
2LL,
0,
(long long)aHttpResolvingS_0,
*((_QWORD *)a1 + 1),
v15,
v16,
a5,
a6,
a7,
a8,
v17,
v18,
a11,
a12,
v63[0]);
return (unsigned int)-9;
}
v66 = v69[0];
httpclient_init(v63, a1[12]);
v25 = *((_QWORD *)a1 + 1);
if ( v25 )
httpclient_set_hostname((long long)v63, v25);
v26 = httpclient_connect((int *)v63, (long long)v65, a5, a6, a7, a8, v23, v24, a11, a12, *a1, v20, v21, v22);
if ( v26 )
{
v19 = v26;
svc_logger_type_log(4LL, 0, (long long)aHttpHttpclient_7, v27, v28, v29, a5, a6, a7, a8, v30, v31, a11, a12, v63[0]);
LABEL_9:
httpclient_close(v63);
return v19;
}
v32 = a3(1LL, 0LL, 0LL, a4);
if ( v32 )
{
v19 = v32;
goto LABEL_9;
}
v37 = aUsinngSsl;
if ( !*a1 )
v37 = &asc_26DC6[5];
v38 = *((_QWORD *)a1 + 1);
if ( a1[11] )
{
svc_logger_type_log(
5LL,
0,
(long long)aHttpPostSS,
v38,
(long long)v37,
v33,
a5,
a6,
a7,
a8,
v34,
v35,
a11,
a12,
v63[0]);
v41 = httpclient_post_stream(
v63,
*((char **)a1 + 2),
*((long long ( **)(long long ( *)(), _QWORD, _QWORD, _QWORD))a1 + 4),
a1[10],
a1[11],
*((_QWORD *)a1 + 3),
a5,
a6,
a7,
a8,
v39,
v40,
a11,
a12);
}
else
{
svc_logger_type_log(5LL, 0, (long long)aHttpGetSS, v38, (long long)v37, v33, a5, a6, a7, a8, v34, v35, a11, a12, v63[0]);
v41 = httpclient_get(
(long long)v63,
*((const char **)a1 + 2),
*((_QWORD *)a1 + 3),
v47,
v48,
v49,
a5,
a6,
a7,
a8,
v50,
v51,
a11,
a12);
}
v52 = v41;
if ( v41 > 0 )
{
v53 = httpclient_read_response_ex(
(long long)v63,
a2,
&v68,
v42,
v43,
v44,
*(double *)a5.m128_u64,
a6,
a7,
a8,
v45,
v46,
a11,
a12);
v57 = v68;
v52 = (2 * (v68 == 0)) | 0xFFFFFFFC;
if ( v68 - 200 < 0x64 )
v52 = v53;
if ( v52 >= 0 )
{
v19 = 0;
v58 = a3(v68, 0LL, 0LL, a4);
if ( !v58 )
{
while ( 1 )
{
v62 = httpclient_read_next_ex((long long)v63, a2, &v64, v59, v60, v54, a5, a6, a7, a8, v55, v56, a11, a12);
v52 = v62;
if ( v62 <= 0 )
goto LABEL_23;
v19 += v62;
v61 = a3(0LL, v64, (unsigned int)v62, a4);
if ( v61 )
{
v52 = v61;
goto LABEL_23;
}
}
}
v52 = v58;
v57 = v68;
}
v19 = 0;
svc_logger_type_log(
4LL,
0,
(long long)aHttpHttpclient_8,
(unsigned int)v52,
v57,
v54,
a5,
a6,
a7,
a8,
v55,
v56,
a11,
a12,
v63[0]);
LABEL_23:
httpclient_read_complete_ex((long long)v63);
goto LABEL_28;
}
v19 = 0;
svc_logger_type_log(
2LL,
0,
(long long)aHttpHttpclient_9,
(unsigned int)v41,
v43,
v44,
a5,
a6,
a7,
a8,
v45,
v46,
a11,
a12,
v63[0]);
LABEL_28:
httpclient_close(v63);
if ( v52 < 0 )
return (unsigned int)v52;
return v19;
}
| httpdwnld_download:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xb8
MOV RBX,RCX
MOV R14,RDX
MOV R15D,ESI
MOV R13,RDI
MOV qword ptr [RBP + -0x38],0x0
MOV word ptr [RBP + -0x40],0x2
MOVZX EAX,word ptr [RDI + 0x4]
ROL AX,0x8
MOV word ptr [RBP + -0x3e],AX
MOV RDI,qword ptr [RDI + 0x8]
LEA RSI,[RBP + -0x2c]
MOV EDX,0x6
CALL 0x001214b0
TEST EAX,EAX
JZ 0x00120f0b
MOV RCX,qword ptr [R13 + 0x8]
LEA RDX,[0x133b27]
MOV EDI,0x2
XOR ESI,ESI
XOR EAX,EAX
CALL 0x001160ad
MOV R12D,0xfffffff7
JMP 0x00120f8a
LAB_00120f0b:
MOV EAX,dword ptr [RBP + -0x2c]
MOV dword ptr [RBP + -0x3c],EAX
MOV ESI,dword ptr [R13 + 0x30]
LEA RDI,[RBP + -0xe0]
CALL 0x0011fc04
MOV RSI,qword ptr [R13 + 0x8]
TEST RSI,RSI
JZ 0x00120f36
LEA RDI,[RBP + -0xe0]
CALL 0x0011fd0f
LAB_00120f36:
MOV EDX,dword ptr [R13]
LEA RDI,[RBP + -0xe0]
LEA RSI,[RBP + -0x40]
CALL 0x0011fc31
TEST EAX,EAX
JZ 0x00120f68
MOV R12D,EAX
LEA RDX,[0x133b46]
MOV EDI,0x4
XOR ESI,ESI
XOR EAX,EAX
CALL 0x001160ad
JMP 0x00120f7e
LAB_00120f68:
MOV EDI,0x1
XOR ESI,ESI
XOR EDX,EDX
MOV RCX,RBX
CALL R14
TEST EAX,EAX
JZ 0x00120f9f
MOV R12D,EAX
LAB_00120f7e:
LEA RDI,[RBP + -0xe0]
CALL 0x0011fdaa
LAB_00120f8a:
MOV EAX,R12D
ADD RSP,0xb8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00120f9f:
CMP dword ptr [R13],0x0
LEA RAX,[0x126dcb]
LEA R8,[0x133b80]
CMOVZ R8,RAX
CMP dword ptr [R13 + 0x2c],0x0
MOV RCX,qword ptr [R13 + 0x8]
JZ 0x00120ff8
LEA RDX,[0x133b6b]
MOV EDI,0x5
XOR ESI,ESI
XOR EAX,EAX
CALL 0x001160ad
MOV RDX,qword ptr [R13 + 0x20]
MOV ECX,dword ptr [R13 + 0x28]
MOV R8D,dword ptr [R13 + 0x2c]
MOV RSI,qword ptr [R13 + 0x10]
MOV R9,qword ptr [R13 + 0x18]
LEA RDI,[RBP + -0xe0]
CALL 0x001203a4
JMP 0x00121021
LAB_00120ff8:
LEA RDX,[0x133b8b]
MOV EDI,0x5
XOR ESI,ESI
XOR EAX,EAX
CALL 0x001160ad
MOV RSI,qword ptr [R13 + 0x10]
MOV RDX,qword ptr [R13 + 0x18]
LEA RDI,[RBP + -0xe0]
CALL 0x0011fdd7
LAB_00121021:
MOV R13D,EAX
TEST EAX,EAX
JLE 0x001210e0
LEA RDI,[RBP + -0xe0]
LEA R12,[RBP + -0x30]
MOV ESI,R15D
MOV RDX,R12
CALL 0x00120907
MOV R8D,dword ptr [R12]
LEA ECX,[R8 + -0xc8]
XOR R13D,R13D
TEST R8D,R8D
SETZ R13B
ADD R13D,R13D
OR R13D,0xfffffffc
CMP ECX,0x64
CMOVC R13D,EAX
TEST R13D,R13D
JS 0x00121085
XOR R12D,R12D
MOV EDI,R8D
XOR ESI,ESI
XOR EDX,EDX
MOV RCX,RBX
CALL R14
TEST EAX,EAX
JZ 0x001210c4
MOV R13D,EAX
MOV R8D,dword ptr [RBP + -0x30]
LAB_00121085:
LEA RDX,[0x133b9f]
XOR R12D,R12D
MOV EDI,0x4
XOR ESI,ESI
MOV ECX,R13D
XOR EAX,EAX
CALL 0x001160ad
LAB_001210a0:
LEA RDI,[RBP + -0xe0]
CALL 0x00120e0a
JMP 0x001210fb
LAB_001210ae:
ADD R12D,R13D
MOV RSI,qword ptr [RBP + -0x48]
XOR EDI,EDI
MOV EDX,R13D
MOV RCX,RBX
CALL R14
TEST EAX,EAX
JNZ 0x00121113
LAB_001210c4:
LEA RDI,[RBP + -0xe0]
MOV ESI,R15D
LEA RDX,[RBP + -0x48]
CALL 0x00120b77
MOV R13D,EAX
TEST EAX,EAX
JG 0x001210ae
JMP 0x001210a0
LAB_001210e0:
LEA RDX,[0x133bda]
XOR R12D,R12D
MOV EDI,0x2
XOR ESI,ESI
MOV ECX,R13D
XOR EAX,EAX
CALL 0x001160ad
LAB_001210fb:
LEA RDI,[RBP + -0xe0]
CALL 0x0011fdaa
TEST R13D,R13D
CMOVS R12D,R13D
JMP 0x00120f8a
LAB_00121113:
MOV R13D,EAX
JMP 0x001210a0
|
uint httpdwnld_download(int *param_1,int4 param_2,code *param_3,int8 param_4)
{
int iVar1;
uint uVar2;
uint uVar3;
char *pcVar4;
int1 local_e8 [152];
int8 local_50;
int2 local_48;
ushort local_46;
int4 local_44;
int8 local_40;
int local_38;
int4 local_34;
local_40 = 0;
local_48 = 2;
local_46 = *(ushort *)(param_1 + 1) << 8 | *(ushort *)(param_1 + 1) >> 8;
iVar1 = gethostbyname_timeout(*(int8 *)(param_1 + 2),&local_34,6);
if (iVar1 != 0) {
svc_logger_type_log(2,0,s_HTTP_____resolving__s_failed__00133b27,*(int8 *)(param_1 + 2));
return 0xfffffff7;
}
local_44 = local_34;
httpclient_init(local_e8,param_1[0xc]);
if (*(long *)(param_1 + 2) != 0) {
httpclient_set_hostname(local_e8);
}
uVar2 = httpclient_connect(local_e8,&local_48,*param_1);
if (uVar2 != 0) {
svc_logger_type_log(4,0,s_HTTP_____httpclient_connect_fail_00133b46);
LAB_00120f7e:
httpclient_close(local_e8);
return uVar2;
}
uVar2 = (*param_3)(1,0,0,param_4);
if (uVar2 != 0) goto LAB_00120f7e;
pcVar4 = s_usinng_SSL_00133b80;
if (*param_1 == 0) {
pcVar4 = &DAT_00126dcb;
}
if (param_1[0xb] == 0) {
svc_logger_type_log(5,0,s_HTTP_____GET__s__s_00133b8b,*(int8 *)(param_1 + 2),pcVar4);
uVar2 = httpclient_get(local_e8,*(int8 *)(param_1 + 4),*(int8 *)(param_1 + 6));
}
else {
svc_logger_type_log(5,0,s_HTTP_____POST__s__s_00133b6b,*(int8 *)(param_1 + 2),pcVar4);
uVar2 = httpclient_post_stream
(local_e8,*(int8 *)(param_1 + 4),*(int8 *)(param_1 + 8),
param_1[10],param_1[0xb],*(int8 *)(param_1 + 6));
}
if ((int)uVar2 < 1) {
uVar3 = 0;
svc_logger_type_log(2,0,s_HTTP_____httpclient_get_failed___00133bda,uVar2);
goto LAB_001210fb;
}
uVar3 = httpclient_read_response_ex(local_e8,param_2,&local_38);
uVar2 = (uint)(local_38 == 0) * 2 | 0xfffffffc;
if (local_38 - 200U < 100) {
uVar2 = uVar3;
}
if ((int)uVar2 < 0) {
LAB_00121085:
uVar3 = 0;
svc_logger_type_log(4,0,s_HTTP_____httpclient_read_respons_00133b9f,uVar2,local_38);
}
else {
uVar3 = 0;
uVar2 = (*param_3)(local_38,0,0,param_4);
if (uVar2 != 0) goto LAB_00121085;
do {
uVar2 = httpclient_read_next_ex(local_e8,param_2,&local_50);
if ((int)uVar2 < 1) break;
uVar3 = uVar3 + uVar2;
uVar2 = (*param_3)(0,local_50,uVar2,param_4);
} while (uVar2 == 0);
}
httpclient_read_complete_ex(local_e8);
LAB_001210fb:
httpclient_close(local_e8);
if (-1 < (int)uVar2) {
return uVar3;
}
return uVar2;
}
| |
22,147 | POINTonE2_precompute_w5 | corpus-core[P]colibri-stateless/build_O0/_deps/blst-src/src/e2.c | POINT_AFFINE_MULT_SCALAR_IMPL(POINTonE2)
DECLARE_PRIVATE_POINTXZ(POINTonE2, 384x)
POINT_LADDER_PRE_IMPL(POINTonE2, 384x, fp2)
POINT_LADDER_STEP_IMPL_A0(POINTonE2, 384x, fp2, onE2)
POINT_LADDER_POST_IMPL_A0(POINTonE2, 384x, fp2, onE2)
POINT_MULT_SCALAR_LADDER_IMPL(POINTonE2)
#endif
static void psi(POINTonE2 *out, const POINTonE2 *in)
{
static const vec384x frobenius_x = { /* 1/(1 + i)^((P-1)/3) */
{ 0 },
{ /* (0x1a0111ea397fe699ec02408663d4de85aa0d857d89759ad4
897d29650fb85f9b409427eb4f49fffd8bfd00000000aaad << 384) % P */
TO_LIMB_T(0x890dc9e4867545c3), TO_LIMB_T(0x2af322533285a5d5),
TO_LIMB_T(0x50880866309b7e2c), TO_LIMB_T(0xa20d1b8c7e881024),
TO_LIMB_T(0x14e4f04fe2db9068), TO_LIMB_T(0x14e56d3f1564853a) }
};
static const vec384x frobenius_y = { /* 1/(1 + i)^((P-1)/2) */
{ /* (0x135203e60180a68ee2e9c448d77a2cd91c3dedd930b1cf60
ef396489f61eb45e304466cf3e67fa0af1ee7b04121bdea2 << 384) % P */
TO_LIMB_T(0x3e2f585da55c9ad1), TO_LIMB_T(0x4294213d86c18183),
TO_LIMB_T(0x382844c88b623732), TO_LIMB_T(0x92ad2afd19103e18),
TO_LIMB_T(0x1d794e4fac7cf0b9), TO_LIMB_T(0x0bd592fc7d825ec8) },
{ /* (0x06af0e0437ff400b6831e36d6bd17ffe48395dabc2d3435e
77f76e17009241c5ee67992f72ec05f4c81084fbede3cc09 << 384) % P */
TO_LIMB_T(0x7bcfa7a25aa30fda), TO_LIMB_T(0xdc17dec12a927e7c),
TO_LIMB_T(0x2f088dd86b4ebef1), TO_LIMB_T(0xd1ca2087da74d4a7),
TO_LIMB_T(0x2da2596696cebc1d), TO_LIMB_T(0x0e2b7eedbbfd87d2) },
};
vec_copy(out, in, sizeof(*out));
cneg_fp(out->X[1], out->X[1], 1); mul_fp2(out->X, out->X, frobenius_x);
cneg_fp(out->Y[1], out->Y[1], 1); mul_fp2(out->Y, out->Y, frobenius_y);
cneg_fp(out->Z[1], out->Z[1], 1);
}
/* Galbraith-Lin-Scott, ~67% faster than POINTonE2_mul_w5 */
static void POINTonE2_mult_gls(POINTonE2 *out, const POINTonE2 *in,
const pow256 SK)
{
union { vec256 l; pow256 s; } val;
/* break down SK to "digits" with |z| as radix [in constant time] */
limbs_from_le_bytes(val.l, SK, 32);
div_by_zz(val.l);
div_by_z(val.l);
div_by_z(val.l + NLIMBS(256)/2);
le_bytes_from_limbs(val.s, val.l, 32);
{
const byte *scalars[2] = { val.s, NULL };
POINTonE2 table[4][1<<(5-1)]; /* 18KB */
size_t i;
POINTonE2_precompute_w5(table[0], in);
for (i = 0; i < 1<<(5-1); i++) {
psi(&table[1][i], &table[0][i]);
psi(&table[2][i], &table[1][i]);
psi(&table[3][i], &table[2][i]);
POINTonE2_cneg(&table[1][i], 1); /* account for z being negative */
POINTonE2_cneg(&table[3][i], 1);
}
POINTonE2s_mult_w5(out, NULL, 4, scalars, 64, table);
}
vec_zero(val.l, sizeof(val)); /* scrub the copy of SK */
} | O0 | c | POINTonE2_precompute_w5:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x18(%rbp), %rax
shrq $0x5, %rax
andq $0x1, %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
andq $0x1f, %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movl $0x120, %edx # imm = 0x120
callq 0x23620
movq $0x2, -0x20(%rbp)
cmpq $0x10, -0x20(%rbp)
ja 0x37260
movq -0x8(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
imulq $0x120, -0x20(%rbp), %rcx # imm = 0x120
addq %rcx, %rax
addq $-0x120, %rax # imm = 0xFEE0
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rax
xorq -0x18(%rbp), %rax
movzbl %al, %edi
callq 0x32ec0
movq -0x38(%rbp), %rdi
movq -0x30(%rbp), %rsi
movq %rax, %rdx
callq 0x36a20
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x3720a
movq -0x8(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x26530
movq -0x18(%rbp), %rax
movzbl %al, %edi
callq 0x32ec0
addq $0x40, %rsp
popq %rbp
retq
nop
| POINTonE2_gather_booth_w5:
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_18]
shr rax, 5
and rax, 1
mov [rbp+var_28], rax
mov rax, [rbp+var_18]
and rax, 1Fh
mov [rbp+var_18], rax
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov edx, 120h
call vec_copy
mov [rbp+var_20], 2
loc_3720A:
cmp [rbp+var_20], 10h
ja short loc_37260
mov rax, [rbp+var_8]
mov [rbp+var_38], rax
mov rax, [rbp+var_10]
imul rcx, [rbp+var_20], 120h
add rax, rcx
add rax, 0FFFFFFFFFFFFFEE0h
mov [rbp+var_30], rax
mov rax, [rbp+var_20]
xor rax, [rbp+var_18]
movzx edi, al
call _byte_is_zero
mov rdi, [rbp+var_38]
mov rsi, [rbp+var_30]
mov rdx, rax
call POINTonE2_ccopy
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
jmp short loc_3720A
loc_37260:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_28]
call POINTonE2_cneg
mov rax, [rbp+var_18]
movzx edi, al
call _byte_is_zero
add rsp, 40h
pop rbp
retn
| unsigned long long POINTonE2_gather_booth_w5(long long a1, long long a2, unsigned long long a3)
{
unsigned long long is_zero; // rax
long long v5; // [rsp+18h] [rbp-28h]
unsigned long long i; // [rsp+20h] [rbp-20h]
unsigned __int8 v7; // [rsp+28h] [rbp-18h]
v5 = (a3 >> 5) & 1;
v7 = a3 & 0x1F;
vec_copy(a1, a2, 0x120uLL);
for ( i = 2LL; i <= 0x10; ++i )
{
is_zero = byte_is_zero(v7 ^ (unsigned __int8)i);
POINTonE2_ccopy(a1, 288 * i + a2 - 288, is_zero);
}
POINTonE2_cneg(a1, v5);
return byte_is_zero(v7);
}
| POINTonE2_gather_booth_w5:
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 + -0x18]
SHR RAX,0x5
AND RAX,0x1
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,0x1f
MOV qword ptr [RBP + -0x18],RAX
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV EDX,0x120
CALL 0x00123620
MOV qword ptr [RBP + -0x20],0x2
LAB_0013720a:
CMP qword ptr [RBP + -0x20],0x10
JA 0x00137260
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x10]
IMUL RCX,qword ptr [RBP + -0x20],0x120
ADD RAX,RCX
ADD RAX,-0x120
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x20]
XOR RAX,qword ptr [RBP + -0x18]
MOVZX EDI,AL
CALL 0x00132ec0
MOV RDI,qword ptr [RBP + -0x38]
MOV RSI,qword ptr [RBP + -0x30]
MOV RDX,RAX
CALL 0x00136a20
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
JMP 0x0013720a
LAB_00137260:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x28]
CALL 0x00126530
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EDI,AL
CALL 0x00132ec0
ADD RSP,0x40
POP RBP
RET
|
void POINTonE2_gather_booth_w5(int8 param_1,long param_2,ulong param_3)
{
int8 uVar1;
int8 local_28;
vec_copy(param_1,param_2,0x120);
for (local_28 = 2; local_28 < 0x11; local_28 = local_28 + 1) {
uVar1 = byte_is_zero((byte)local_28 ^ (byte)(param_3 & 0x1f));
POINTonE2_ccopy(param_1,param_2 + local_28 * 0x120 + -0x120,uVar1);
}
POINTonE2_cneg(param_1,param_3 >> 5 & 1);
byte_is_zero(param_3 & 0x1f);
return;
}
| |
22,148 | my_long10_to_str_8bit | eloqsql/strings/ctype-simple.c | size_t my_long10_to_str_8bit(CHARSET_INFO *cs __attribute__((unused)),
char *dst, size_t len, int radix, long int val)
{
char buffer[66];
register char *p, *e;
long int new_val;
uint sign=0;
unsigned long int uval = (unsigned long int) val;
e = p = &buffer[sizeof(buffer)-1];
*p= 0;
if (radix < 0)
{
if (val < 0)
{
/* Avoid integer overflow in (-val) for LONGLONG_MIN (BUG#31799). */
uval= (unsigned long int)0 - uval;
*dst++= '-';
len--;
sign= 1;
}
}
new_val = (long) (uval / 10);
*--p = '0'+ (char) (uval - (unsigned long) new_val * 10);
val = new_val;
while (val != 0)
{
new_val=val/10;
*--p = '0' + (char) (val-new_val*10);
val= new_val;
}
len= MY_MIN(len, (size_t) (e-p));
memcpy(dst, p, len);
return len+sign;
} | O3 | c | my_long10_to_str_8bit:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x50, %rsp
movq %rdx, %r10
movq %rsi, %rdi
movq %fs:0x28, %rax
movq %rax, -0x18(%rbp)
movb $0x0, -0x1f(%rbp)
testl %ecx, %ecx
setns %al
testq %r8, %r8
setns %cl
orb %al, %cl
jne 0x3808f
negq %r8
movb $0x2d, (%rdi)
incq %rdi
decq %r10
movl $0x1, %r14d
jmp 0x38092
xorl %r14d, %r14d
leaq -0x1f(%rbp), %rbx
movabsq $-0x3333333333333333, %rcx # imm = 0xCCCCCCCCCCCCCCCD
movq %r8, %rax
mulq %rcx
movq %rdx, %r9
shrq $0x3, %r9
imull $0xf6, %r9d, %eax
addl %r8d, %eax
addb $0x30, %al
leaq -0x20(%rbp), %rsi
movb %al, (%rsi)
cmpq $0xa, %r8
jb 0x380e9
movq %r9, %rax
mulq %rcx
shrq $0x3, %rdx
imull $0xf6, %edx, %eax
addl %r9d, %eax
addb $0x30, %al
movb %al, -0x1(%rsi)
decq %rsi
cmpq $0x9, %r9
movq %rdx, %r9
ja 0x380c5
subq %rsi, %rbx
cmpq %rbx, %r10
cmovbq %r10, %rbx
movq %rbx, %rdx
callq 0x24220
movq %fs:0x28, %rax
cmpq -0x18(%rbp), %rax
jne 0x38119
addq %r14, %rbx
movq %rbx, %rax
addq $0x50, %rsp
popq %rbx
popq %r14
popq %rbp
retq
callq 0x24340
| my_long10_to_str_8bit:
push rbp
mov rbp, rsp
push r14
push rbx
sub rsp, 50h
mov r10, rdx
mov rdi, rsi
mov rax, fs:28h
mov [rbp+var_18], rax
mov [rbp+var_1F], 0
test ecx, ecx
setns al
test r8, r8
setns cl
or cl, al
jnz short loc_3808F
neg r8
mov byte ptr [rdi], 2Dh ; '-'
inc rdi
dec r10
mov r14d, 1
jmp short loc_38092
loc_3808F:
xor r14d, r14d
loc_38092:
lea rbx, [rbp+var_1F]
mov rcx, 0CCCCCCCCCCCCCCCDh
mov rax, r8
mul rcx
mov r9, rdx
shr r9, 3
imul eax, r9d, 0F6h
add eax, r8d
add al, 30h ; '0'
lea rsi, [rbp+var_20]
mov [rsi], al
cmp r8, 0Ah
jb short loc_380E9
loc_380C5:
mov rax, r9
mul rcx
shr rdx, 3
imul eax, edx, 0F6h
add eax, r9d
add al, 30h ; '0'
mov [rsi-1], al
dec rsi
cmp r9, 9
mov r9, rdx
ja short loc_380C5
loc_380E9:
sub rbx, rsi
cmp r10, rbx
cmovb rbx, r10
mov rdx, rbx
call _memcpy
mov rax, fs:28h
cmp rax, [rbp+var_18]
jnz short loc_38119
add rbx, r14
mov rax, rbx
add rsp, 50h
pop rbx
pop r14
pop rbp
retn
loc_38119:
call ___stack_chk_fail
| _BYTE * my_long10_to_str_8bit(long long a1, _BYTE *a2, _BYTE *a3, int a4, unsigned long long a5)
{
_BYTE *v5; // r10
_BYTE *v6; // rdi
long long v7; // r14
unsigned long long v8; // r9
char *v9; // rsi
bool v10; // cf
bool v11; // zf
_BYTE *v12; // rbx
char v14; // [rsp+40h] [rbp-20h] BYREF
_BYTE v15[7]; // [rsp+41h] [rbp-1Fh] BYREF
unsigned long long v16; // [rsp+48h] [rbp-18h]
v5 = a3;
v6 = a2;
v16 = __readfsqword(0x28u);
v15[0] = 0;
if ( a4 >= 0 || (a5 & 0x8000000000000000LL) == 0LL )
{
v7 = 0LL;
}
else
{
a5 = -(long long)a5;
*a2 = 45;
v6 = a2 + 1;
v5 = a3 - 1;
v7 = 1LL;
}
v8 = a5 / 0xA;
v9 = &v14;
v14 = a5 % 0xA + 48;
if ( a5 >= 0xA )
{
do
{
*--v9 = v8 % 0xA + 48;
v10 = v8 < 9;
v11 = v8 == 9;
v8 /= 0xAuLL;
}
while ( !v10 && !v11 );
}
v12 = (_BYTE *)(v15 - v9);
if ( (unsigned long long)v5 < v15 - v9 )
v12 = v5;
memcpy(v6, v9, v12);
return &v12[v7];
}
| my_long10_to_str_8bit:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
SUB RSP,0x50
MOV R10,RDX
MOV RDI,RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
MOV byte ptr [RBP + -0x1f],0x0
TEST ECX,ECX
SETNS AL
TEST R8,R8
SETNS CL
OR CL,AL
JNZ 0x0013808f
NEG R8
MOV byte ptr [RDI],0x2d
INC RDI
DEC R10
MOV R14D,0x1
JMP 0x00138092
LAB_0013808f:
XOR R14D,R14D
LAB_00138092:
LEA RBX,[RBP + -0x1f]
MOV RCX,-0x3333333333333333
MOV RAX,R8
MUL RCX
MOV R9,RDX
SHR R9,0x3
IMUL EAX,R9D,0xf6
ADD EAX,R8D
ADD AL,0x30
LEA RSI,[RBP + -0x20]
MOV byte ptr [RSI],AL
CMP R8,0xa
JC 0x001380e9
LAB_001380c5:
MOV RAX,R9
MUL RCX
SHR RDX,0x3
IMUL EAX,EDX,0xf6
ADD EAX,R9D
ADD AL,0x30
MOV byte ptr [RSI + -0x1],AL
DEC RSI
CMP R9,0x9
MOV R9,RDX
JA 0x001380c5
LAB_001380e9:
SUB RBX,RSI
CMP R10,RBX
CMOVC RBX,R10
MOV RDX,RBX
CALL 0x00124220
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x18]
JNZ 0x00138119
ADD RBX,R14
MOV RAX,RBX
ADD RSP,0x50
POP RBX
POP R14
POP RBP
RET
LAB_00138119:
CALL 0x00124340
|
char * my_long10_to_str_8bit
(int8 param_1,int1 *param_2,char *param_3,int param_4,ulong param_5)
{
ulong uVar1;
ulong uVar2;
char *__n;
char *__src;
long in_FS_OFFSET;
bool bVar3;
char local_29 [9];
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
local_29[2] = 0;
bVar3 = (long)param_5 < 0;
if (bVar3 && param_4 < 0) {
param_5 = -param_5;
*param_2 = 0x2d;
param_2 = param_2 + 1;
param_3 = param_3 + -1;
}
local_29[1] = (char)(param_5 / 10) * -10 + (char)param_5 + '0';
__src = local_29 + 1;
uVar2 = param_5 / 10;
while (uVar1 = uVar2, 9 < param_5) {
__src[-1] = (char)(uVar1 / 10) * -10 + (char)uVar1 + '0';
__src = __src + -1;
uVar2 = uVar1 / 10;
param_5 = uVar1;
}
__n = local_29 + (2 - (long)__src);
if (param_3 < local_29 + (2 - (long)__src)) {
__n = param_3;
}
memcpy(param_2,__src,(size_t)__n);
if (*(long *)(in_FS_OFFSET + 0x28) == local_20) {
return __n + (bVar3 && param_4 < 0);
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
22,149 | std::hash<evmc::bytes32>::operator()(evmc::bytes32 const&) const | corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/evmc/include/evmc/evmc.hpp | constexpr size_t operator()(const evmc::bytes32& s) const noexcept
{
using namespace evmc;
using namespace fnv;
return static_cast<size_t>(
fnv1a_by64(fnv1a_by64(fnv1a_by64(fnv1a_by64(fnv::offset_basis, load64le(&s.bytes[0])),
load64le(&s.bytes[8])),
load64le(&s.bytes[16])),
load64le(&s.bytes[24])));
} | O0 | cpp | std::hash<evmc::bytes32>::operator()(evmc::bytes32 const&) const:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x3c730
movq %rax, %rsi
movabsq $-0x340d631b7bdddcdb, %rdi # imm = 0xCBF29CE484222325
callq 0x3c700
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rdi
addq $0x8, %rdi
callq 0x3c730
movq -0x28(%rbp), %rdi
movq %rax, %rsi
callq 0x3c700
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rdi
addq $0x10, %rdi
callq 0x3c730
movq -0x20(%rbp), %rdi
movq %rax, %rsi
callq 0x3c700
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
addq $0x18, %rdi
callq 0x3c730
movq -0x18(%rbp), %rdi
movq %rax, %rsi
callq 0x3c700
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| _ZNKSt4hashIN4evmc7bytes32EEclERKS1_:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rdi, [rbp+var_10]; this
call _ZN4evmc8load64leEPKh; evmc::load64le(uchar const*)
mov rsi, rax; unsigned __int8 *
mov rdi, 0CBF29CE484222325h; this
call _ZN4evmc3fnv10fnv1a_by64Emm; evmc::fnv::fnv1a_by64(ulong,ulong)
mov [rbp+var_28], rax
mov rdi, [rbp+var_10]
add rdi, 8; this
call _ZN4evmc8load64leEPKh; evmc::load64le(uchar const*)
mov rdi, [rbp+var_28]; this
mov rsi, rax; unsigned __int8 *
call _ZN4evmc3fnv10fnv1a_by64Emm; evmc::fnv::fnv1a_by64(ulong,ulong)
mov [rbp+var_20], rax
mov rdi, [rbp+var_10]
add rdi, 10h; this
call _ZN4evmc8load64leEPKh; evmc::load64le(uchar const*)
mov rdi, [rbp+var_20]; this
mov rsi, rax; unsigned __int8 *
call _ZN4evmc3fnv10fnv1a_by64Emm; evmc::fnv::fnv1a_by64(ulong,ulong)
mov [rbp+var_18], rax
mov rdi, [rbp+var_10]
add rdi, 18h; this
call _ZN4evmc8load64leEPKh; evmc::load64le(uchar const*)
mov rdi, [rbp+var_18]; this
mov rsi, rax; unsigned __int64
call _ZN4evmc3fnv10fnv1a_by64Emm; evmc::fnv::fnv1a_by64(ulong,ulong)
add rsp, 30h
pop rbp
retn
| long long std::hash<evmc::bytes32>::operator()(long long a1, long long a2)
{
const unsigned __int8 *v2; // rsi
unsigned long long v3; // rdx
const unsigned __int8 *v4; // rsi
unsigned long long v5; // rdx
const unsigned __int8 *v6; // rsi
unsigned long long v7; // rdx
unsigned long long v8; // rax
unsigned long long v9; // rdx
evmc::fnv *v11; // [rsp+8h] [rbp-28h]
evmc::fnv *v12; // [rsp+10h] [rbp-20h]
evmc::fnv *v13; // [rsp+18h] [rbp-18h]
v2 = (const unsigned __int8 *)evmc::load64le((evmc *)a2, (const unsigned __int8 *)a2);
v11 = (evmc::fnv *)evmc::fnv::fnv1a_by64((evmc::fnv *)0xCBF29CE484222325LL, (unsigned long long)v2, v3);
v4 = (const unsigned __int8 *)evmc::load64le((evmc *)(a2 + 8), v2);
v12 = (evmc::fnv *)evmc::fnv::fnv1a_by64(v11, (unsigned long long)v4, v5);
v6 = (const unsigned __int8 *)evmc::load64le((evmc *)(a2 + 16), v4);
v13 = (evmc::fnv *)evmc::fnv::fnv1a_by64(v12, (unsigned long long)v6, v7);
v8 = evmc::load64le((evmc *)(a2 + 24), v6);
return evmc::fnv::fnv1a_by64(v13, v8, v9);
}
| operator():
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0013c730
MOV RSI,RAX
MOV RDI,-0x340d631b7bdddcdb
CALL 0x0013c700
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x8
CALL 0x0013c730
MOV RDI,qword ptr [RBP + -0x28]
MOV RSI,RAX
CALL 0x0013c700
MOV qword ptr [RBP + -0x20],RAX
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x10
CALL 0x0013c730
MOV RDI,qword ptr [RBP + -0x20]
MOV RSI,RAX
CALL 0x0013c700
MOV qword ptr [RBP + -0x18],RAX
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x18
CALL 0x0013c730
MOV RDI,qword ptr [RBP + -0x18]
MOV RSI,RAX
CALL 0x0013c700
ADD RSP,0x30
POP RBP
RET
|
/* std::hash<evmc::bytes32>::TEMPNAMEPLACEHOLDERVALUE(evmc::bytes32 const&) const */
void __thiscall std::hash<evmc::bytes32>::operator()(hash<evmc::bytes32> *this,bytes32 *param_1)
{
fnv *pfVar1;
int1 auVar2 [16];
auVar2 = evmc::load64le((uchar *)param_1);
pfVar1 = (fnv *)evmc::fnv::fnv1a_by64((fnv *)0xcbf29ce484222325,auVar2._0_8_,auVar2._8_8_);
auVar2 = evmc::load64le((uchar *)(param_1 + 8));
pfVar1 = (fnv *)evmc::fnv::fnv1a_by64(pfVar1,auVar2._0_8_,auVar2._8_8_);
auVar2 = evmc::load64le((uchar *)(param_1 + 0x10));
pfVar1 = (fnv *)evmc::fnv::fnv1a_by64(pfVar1,auVar2._0_8_,auVar2._8_8_);
auVar2 = evmc::load64le((uchar *)(param_1 + 0x18));
evmc::fnv::fnv1a_by64(pfVar1,auVar2._0_8_,auVar2._8_8_);
return;
}
| |
22,150 | simple_cs_is_full | eloqsql/mysys/charset.c | static my_bool simple_cs_is_full(CHARSET_INFO *cs)
{
return cs->number && cs->cs_name.str && cs->coll_name.str &&
simple_8bit_charset_data_is_full(cs) &&
(simple_8bit_collation_data_is_full(cs) || cs->tailoring);
} | O3 | c | simple_cs_is_full:
pushq %rbp
movq %rsp, %rbp
cmpl $0x0, (%rdi)
je 0x28fcf
cmpq $0x0, 0x10(%rdi)
je 0x28fcf
cmpq $0x0, 0x20(%rdi)
je 0x28fcf
cmpq $0x0, 0x40(%rdi)
je 0x28fcf
cmpq $0x0, 0x50(%rdi)
je 0x28fcf
cmpq $0x0, 0x48(%rdi)
je 0x28fcf
cmpq $0x0, 0x68(%rdi)
je 0x28fcf
movb $0x1, %al
cmpq $0x0, 0x58(%rdi)
jne 0x28fd1
testb $0x10, 0xc(%rdi)
jne 0x28fd1
cmpq $0x0, 0x38(%rdi)
setne %al
jmp 0x28fd1
xorl %eax, %eax
popq %rbp
retq
| simple_cs_is_full:
push rbp
mov rbp, rsp
cmp dword ptr [rdi], 0
jz short loc_28FCF
cmp qword ptr [rdi+10h], 0
jz short loc_28FCF
cmp qword ptr [rdi+20h], 0
jz short loc_28FCF
cmp qword ptr [rdi+40h], 0
jz short loc_28FCF
cmp qword ptr [rdi+50h], 0
jz short loc_28FCF
cmp qword ptr [rdi+48h], 0
jz short loc_28FCF
cmp qword ptr [rdi+68h], 0
jz short loc_28FCF
mov al, 1
cmp qword ptr [rdi+58h], 0
jnz short loc_28FD1
test byte ptr [rdi+0Ch], 10h
jnz short loc_28FD1
cmp qword ptr [rdi+38h], 0
setnz al
jmp short loc_28FD1
loc_28FCF:
xor eax, eax
loc_28FD1:
pop rbp
retn
| bool simple_cs_is_full(long long a1)
{
bool result; // al
if ( !*(_DWORD *)a1
|| !*(_QWORD *)(a1 + 16)
|| !*(_QWORD *)(a1 + 32)
|| !*(_QWORD *)(a1 + 64)
|| !*(_QWORD *)(a1 + 80)
|| !*(_QWORD *)(a1 + 72)
|| !*(_QWORD *)(a1 + 104) )
{
return 0;
}
result = 1;
if ( !*(_QWORD *)(a1 + 88) && (*(_BYTE *)(a1 + 12) & 0x10) == 0 )
return *(_QWORD *)(a1 + 56) != 0LL;
return result;
}
| simple_cs_is_full:
PUSH RBP
MOV RBP,RSP
CMP dword ptr [RDI],0x0
JZ 0x00128fcf
CMP qword ptr [RDI + 0x10],0x0
JZ 0x00128fcf
CMP qword ptr [RDI + 0x20],0x0
JZ 0x00128fcf
CMP qword ptr [RDI + 0x40],0x0
JZ 0x00128fcf
CMP qword ptr [RDI + 0x50],0x0
JZ 0x00128fcf
CMP qword ptr [RDI + 0x48],0x0
JZ 0x00128fcf
CMP qword ptr [RDI + 0x68],0x0
JZ 0x00128fcf
MOV AL,0x1
CMP qword ptr [RDI + 0x58],0x0
JNZ 0x00128fd1
TEST byte ptr [RDI + 0xc],0x10
JNZ 0x00128fd1
CMP qword ptr [RDI + 0x38],0x0
SETNZ AL
JMP 0x00128fd1
LAB_00128fcf:
XOR EAX,EAX
LAB_00128fd1:
POP RBP
RET
|
bool simple_cs_is_full(int *param_1)
{
bool bVar1;
if (((((*param_1 == 0) || (*(long *)(param_1 + 4) == 0)) || (*(long *)(param_1 + 8) == 0)) ||
((*(long *)(param_1 + 0x10) == 0 || (*(long *)(param_1 + 0x14) == 0)))) ||
((*(long *)(param_1 + 0x12) == 0 || (*(long *)(param_1 + 0x1a) == 0)))) {
bVar1 = false;
}
else {
bVar1 = true;
if ((*(long *)(param_1 + 0x16) == 0) && ((*(byte *)(param_1 + 3) & 0x10) == 0)) {
bVar1 = *(long *)(param_1 + 0xe) != 0;
}
}
return bVar1;
}
| |
22,151 | void OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>(OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::PatchFace const&, OpenSubdiv::v3_6_0::Far::SparseMatrix<double>&, std::vector<int, std::allocator<int>>&) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/patchTreeBuilder.cpp | void
PatchTreeBuilder::getIrregularPatchConversion(PatchFace const & pf,
SparseMatrix<REAL> & conversionMatrix,
std::vector<Index> & sourcePoints) {
//
// The topology of an irregular patch is determined by its four corners:
//
Level::VSpan cornerSpans[4];
_patchBuilder->GetIrregularPatchCornerSpans(pf.level, pf.face, cornerSpans);
//
// Compute the conversion matrix from refined/source points to the
// set of points local to this patch:
//
_patchBuilder->GetIrregularPatchConversionMatrix(pf.level, pf.face,
cornerSpans, conversionMatrix);
//
// Identify the refined/source points for the patch and append stencils
// for the local patch points in terms of the source points:
//
int numSourcePoints = conversionMatrix.GetNumColumns();
sourcePoints.resize(numSourcePoints);
_patchBuilder->GetIrregularPatchSourcePoints(pf.level, pf.face,
cornerSpans, &sourcePoints[0]);
int sourceIndexOffset = _levelOffsets[pf.level];
for (int i = 0; i < numSourcePoints; ++i) {
sourcePoints[i] += sourceIndexOffset;
}
} | O0 | cpp | void OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>(OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::PatchFace const&, OpenSubdiv::v3_6_0::Far::SparseMatrix<double>&, std::vector<int, std::allocator<int>>&):
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x68(%rbp)
leaq -0x40(%rbp), %rax
movq %rax, %rcx
addq $0x20, %rcx
movq %rcx, -0x60(%rbp)
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rdi
movq %rdi, -0x70(%rbp)
callq 0xce760
movq -0x70(%rbp), %rax
movq -0x60(%rbp), %rcx
addq $0x8, %rax
cmpq %rcx, %rax
movq %rax, -0x58(%rbp)
jne 0x1a72e6
movq -0x68(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x10(%rbp), %rax
movswl 0x4(%rax), %esi
movq -0x10(%rbp), %rax
movl (%rax), %edx
leaq -0x40(%rbp), %rcx
movl $0xffffffff, %r8d # imm = 0xFFFFFFFF
callq 0xcf5d0
movq -0x68(%rbp), %rax
movq 0x48(%rax), %rdi
movq -0x10(%rbp), %rax
movswl 0x4(%rax), %esi
movq -0x10(%rbp), %rax
movl (%rax), %edx
leaq -0x40(%rbp), %rcx
movq -0x18(%rbp), %r8
callq 0xc85d0
movq -0x18(%rbp), %rdi
callq 0xcc9a0
movl %eax, -0x44(%rbp)
movq -0x20(%rbp), %rdi
movslq -0x44(%rbp), %rsi
callq 0xc9aa0
movq -0x68(%rbp), %rax
movq 0x48(%rax), %rax
movq %rax, -0x88(%rbp)
movq -0x10(%rbp), %rax
movswl 0x4(%rax), %eax
movl %eax, -0x80(%rbp)
movq -0x10(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x7c(%rbp)
leaq -0x40(%rbp), %rax
movq %rax, -0x78(%rbp)
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xc7140
movq -0x88(%rbp), %rdi
movl -0x80(%rbp), %esi
movl -0x7c(%rbp), %edx
movq -0x78(%rbp), %rcx
movq %rax, %r8
movl $0xffffffff, %r9d # imm = 0xFFFFFFFF
callq 0xd4ce0
movq -0x68(%rbp), %rdi
addq $0x18, %rdi
movq -0x10(%rbp), %rax
movswq 0x4(%rax), %rsi
callq 0xc7140
movl (%rax), %eax
movl %eax, -0x48(%rbp)
movl $0x0, -0x4c(%rbp)
movl -0x4c(%rbp), %eax
cmpl -0x44(%rbp), %eax
jge 0x1a7415
movl -0x48(%rbp), %eax
movl %eax, -0x8c(%rbp)
movq -0x20(%rbp), %rdi
movslq -0x4c(%rbp), %rsi
callq 0xc7140
movl -0x8c(%rbp), %ecx
addl (%rax), %ecx
movl %ecx, (%rax)
movl -0x4c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4c(%rbp)
jmp 0x1a73e2
addq $0x90, %rsp
popq %rbp
retq
nop
| _ZN10OpenSubdiv6v3_6_03Bfr16PatchTreeBuilder27getIrregularPatchConversionIfEEvRKNS2_9PatchFaceERNS0_3Far12SparseMatrixIT_EERSt6vectorIiSaIiEE:
push rbp
mov rbp, rsp
sub rsp, 90h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rax, [rbp+var_8]
mov [rbp+var_68], rax
lea rax, [rbp+var_40]
mov rcx, rax
add rcx, 20h ; ' '
mov [rbp+var_60], rcx
mov [rbp+var_58], rax
loc_1A72E6:
mov rdi, [rbp+var_58]; this
mov [rbp+var_70], rdi
call __ZN10OpenSubdiv6v3_6_03Vtr8internal5Level5VSpanC2Ev; OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan::VSpan(void)
mov rax, [rbp+var_70]
mov rcx, [rbp+var_60]
add rax, 8
cmp rax, rcx
mov [rbp+var_58], rax
jnz short loc_1A72E6
mov rax, [rbp+var_68]
mov rdi, [rax+48h]; this
mov rax, [rbp+var_10]
movsx esi, word ptr [rax+4]; int
mov rax, [rbp+var_10]
mov edx, [rax]; int
lea rcx, [rbp+var_40]; OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *
mov r8d, 0FFFFFFFFh; int
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder28GetIrregularPatchCornerSpansEiiPNS0_3Vtr8internal5Level5VSpanEi; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchCornerSpans(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *,int)
mov rax, [rbp+var_68]
mov rdi, [rax+48h]
mov rax, [rbp+var_10]
movsx esi, word ptr [rax+4]
mov rax, [rbp+var_10]
mov edx, [rax]
lea rcx, [rbp+var_40]
mov r8, [rbp+var_18]
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder33GetIrregularPatchConversionMatrixIfEEiiiPKNS0_3Vtr8internal5Level5VSpanERNS1_12SparseMatrixIT_EE; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchConversionMatrix<float>(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan const*,OpenSubdiv::v3_6_0::Far::SparseMatrix<float> &)
mov rdi, [rbp+var_18]
call __ZNK10OpenSubdiv6v3_6_03Far12SparseMatrixIfE13GetNumColumnsEv; OpenSubdiv::v3_6_0::Far::SparseMatrix<float>::GetNumColumns(void)
mov [rbp+var_44], eax
mov rdi, [rbp+var_20]
movsxd rsi, [rbp+var_44]
call __ZNSt6vectorIiSaIiEE6resizeEm; std::vector<int>::resize(ulong)
mov rax, [rbp+var_68]
mov rax, [rax+48h]
mov [rbp+var_88], rax
mov rax, [rbp+var_10]
movsx eax, word ptr [rax+4]
mov [rbp+var_80], eax
mov rax, [rbp+var_10]
mov eax, [rax]
mov [rbp+var_7C], eax
lea rax, [rbp+var_40]
mov [rbp+var_78], rax
mov rdi, [rbp+var_20]
xor eax, eax
mov esi, eax
call __ZNSt6vectorIiSaIiEEixEm; std::vector<int>::operator[](ulong)
mov rdi, [rbp+var_88]; this
mov esi, [rbp+var_80]; int
mov edx, [rbp+var_7C]; int
mov rcx, [rbp+var_78]; OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *
mov r8, rax; int *
mov r9d, 0FFFFFFFFh; int
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder29GetIrregularPatchSourcePointsEiiPKNS0_3Vtr8internal5Level5VSpanEPii; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchSourcePoints(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan const*,int *,int)
mov rdi, [rbp+var_68]
add rdi, 18h
mov rax, [rbp+var_10]
movsx rsi, word ptr [rax+4]
call __ZNSt6vectorIiSaIiEEixEm; std::vector<int>::operator[](ulong)
mov eax, [rax]
mov [rbp+var_48], eax
mov [rbp+var_4C], 0
loc_1A73E2:
mov eax, [rbp+var_4C]
cmp eax, [rbp+var_44]
jge short loc_1A7415
mov eax, [rbp+var_48]
mov [rbp+var_8C], eax
mov rdi, [rbp+var_20]
movsxd rsi, [rbp+var_4C]
call __ZNSt6vectorIiSaIiEEixEm; std::vector<int>::operator[](ulong)
mov ecx, [rbp+var_8C]
add ecx, [rax]
mov [rax], ecx
mov eax, [rbp+var_4C]
add eax, 1
mov [rbp+var_4C], eax
jmp short loc_1A73E2
loc_1A7415:
add rsp, 90h
pop rbp
retn
| long long OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<float>(
long long a1,
long long a2,
long long a3,
long long a4)
{
int *v4; // rax
long long result; // rax
_DWORD *v6; // rax
OpenSubdiv::v3_6_0::Far::PatchBuilder *v7; // [rsp+8h] [rbp-88h]
int v8; // [rsp+10h] [rbp-80h]
int v9; // [rsp+14h] [rbp-7Ch]
OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *v10; // [rsp+38h] [rbp-58h]
unsigned int i; // [rsp+44h] [rbp-4Ch]
int v12; // [rsp+48h] [rbp-48h]
int NumColumns; // [rsp+4Ch] [rbp-44h]
_BYTE v14[32]; // [rsp+50h] [rbp-40h] BYREF
long long v15; // [rsp+70h] [rbp-20h] BYREF
long long v16; // [rsp+78h] [rbp-18h]
long long v17; // [rsp+80h] [rbp-10h]
long long v18; // [rsp+88h] [rbp-8h]
v18 = a1;
v17 = a2;
v16 = a3;
v15 = a4;
v10 = (OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *)v14;
do
{
OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan::VSpan(v10);
v10 = (OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *)((char *)v10 + 8);
}
while ( v10 != (OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *)&v15 );
OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchCornerSpans(
*(OpenSubdiv::v3_6_0::Far::PatchBuilder **)(a1 + 72),
*(__int16 *)(v17 + 4),
*(_DWORD *)v17,
(OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *)v14,
-1);
OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchConversionMatrix<float>(
*(OpenSubdiv::v3_6_0::Far::PatchBuilder **)(a1 + 72),
*(__int16 *)(v17 + 4),
*(_DWORD *)v17,
(OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *)v14,
v16);
NumColumns = OpenSubdiv::v3_6_0::Far::SparseMatrix<float>::GetNumColumns(v16);
std::vector<int>::resize(v15, NumColumns);
v7 = *(OpenSubdiv::v3_6_0::Far::PatchBuilder **)(a1 + 72);
v8 = *(__int16 *)(v17 + 4);
v9 = *(_DWORD *)v17;
v4 = (int *)std::vector<int>::operator[](v15, 0LL);
OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchSourcePoints(
v7,
v8,
v9,
(const OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *)v14,
v4,
-1);
v12 = *(_DWORD *)std::vector<int>::operator[](a1 + 24, *(__int16 *)(v17 + 4));
for ( i = 0; ; ++i )
{
result = i;
if ( (int)i >= NumColumns )
break;
v6 = (_DWORD *)std::vector<int>::operator[](v15, (int)i);
*v6 += v12;
}
return result;
}
| |||
22,152 | void OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>(OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::PatchFace const&, OpenSubdiv::v3_6_0::Far::SparseMatrix<double>&, std::vector<int, std::allocator<int>>&) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/patchTreeBuilder.cpp | void
PatchTreeBuilder::getIrregularPatchConversion(PatchFace const & pf,
SparseMatrix<REAL> & conversionMatrix,
std::vector<Index> & sourcePoints) {
//
// The topology of an irregular patch is determined by its four corners:
//
Level::VSpan cornerSpans[4];
_patchBuilder->GetIrregularPatchCornerSpans(pf.level, pf.face, cornerSpans);
//
// Compute the conversion matrix from refined/source points to the
// set of points local to this patch:
//
_patchBuilder->GetIrregularPatchConversionMatrix(pf.level, pf.face,
cornerSpans, conversionMatrix);
//
// Identify the refined/source points for the patch and append stencils
// for the local patch points in terms of the source points:
//
int numSourcePoints = conversionMatrix.GetNumColumns();
sourcePoints.resize(numSourcePoints);
_patchBuilder->GetIrregularPatchSourcePoints(pf.level, pf.face,
cornerSpans, &sourcePoints[0]);
int sourceIndexOffset = _levelOffsets[pf.level];
for (int i = 0; i < numSourcePoints; ++i) {
sourcePoints[i] += sourceIndexOffset;
}
} | O2 | cpp | void OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>(OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::PatchFace const&, OpenSubdiv::v3_6_0::Far::SparseMatrix<double>&, std::vector<int, std::allocator<int>>&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %rbx
movq %rdx, %r13
movq %rsi, %r15
movq %rdi, %r14
xorps %xmm0, %xmm0
movq %rsp, %r12
movaps %xmm0, 0x10(%r12)
movaps %xmm0, (%r12)
movq 0x48(%rdi), %rdi
movswl 0x4(%rsi), %esi
movl (%r15), %edx
pushq $-0x1
popq %rbp
movq %r12, %rcx
movl %ebp, %r8d
callq 0x53250
movq 0x48(%r14), %rdi
movswl 0x4(%r15), %esi
movl (%r15), %edx
movq %r12, %rcx
movq %r13, %r8
callq 0x4f270
movslq 0x4(%r13), %r13
movq %rbx, %rdi
movq %r13, %rsi
callq 0x514b0
movq 0x48(%r14), %rdi
movswl 0x4(%r15), %esi
movl (%r15), %edx
movq (%rbx), %r8
movq %r12, %rcx
movl %ebp, %r9d
callq 0x54f00
movswq 0x4(%r15), %rax
movq 0x18(%r14), %rcx
movl (%rcx,%rax,4), %eax
movq (%rbx), %rcx
xorl %edx, %edx
testl %r13d, %r13d
movl $0x0, %esi
cmovgl %r13d, %esi
cmpq %rdx, %rsi
je 0xa193a
addl %eax, (%rcx,%rdx,4)
incq %rdx
jmp 0xa192d
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
| _ZN10OpenSubdiv6v3_6_03Bfr16PatchTreeBuilder27getIrregularPatchConversionIdEEvRKNS2_9PatchFaceERNS0_3Far12SparseMatrixIT_EERSt6vectorIiSaIiEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov rbx, rcx
mov r13, rdx
mov r15, rsi
mov r14, rdi
xorps xmm0, xmm0
mov r12, rsp
movaps xmmword ptr [r12+10h], xmm0
movaps xmmword ptr [r12], xmm0
mov rdi, [rdi+48h]
movsx esi, word ptr [rsi+4]
mov edx, [r15]
push 0FFFFFFFFFFFFFFFFh
pop rbp
mov rcx, r12
mov r8d, ebp
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder28GetIrregularPatchCornerSpansEiiPNS0_3Vtr8internal5Level5VSpanEi; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchCornerSpans(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *,int)
mov rdi, [r14+48h]
movsx esi, word ptr [r15+4]
mov edx, [r15]
mov rcx, r12
mov r8, r13
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder33GetIrregularPatchConversionMatrixIdEEiiiPKNS0_3Vtr8internal5Level5VSpanERNS1_12SparseMatrixIT_EE; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchConversionMatrix<double>(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan const*,OpenSubdiv::v3_6_0::Far::SparseMatrix<double> &)
movsxd r13, dword ptr [r13+4]
mov rdi, rbx
mov rsi, r13
call __ZNSt6vectorIiSaIiEE6resizeEm; std::vector<int>::resize(ulong)
mov rdi, [r14+48h]
movsx esi, word ptr [r15+4]
mov edx, [r15]
mov r8, [rbx]
mov rcx, r12
mov r9d, ebp
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder29GetIrregularPatchSourcePointsEiiPKNS0_3Vtr8internal5Level5VSpanEPii; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchSourcePoints(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan const*,int *,int)
movsx rax, word ptr [r15+4]
mov rcx, [r14+18h]
mov eax, [rcx+rax*4]
mov rcx, [rbx]
xor edx, edx
test r13d, r13d
mov esi, 0
cmovg esi, r13d
loc_A192D:
cmp rsi, rdx
jz short loc_A193A
add [rcx+rdx*4], eax
inc rdx
jmp short loc_A192D
loc_A193A:
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>(
long long a1,
long long a2,
long long a3,
long long *a4)
{
long long v7; // r13
long long result; // rax
long long v9; // rcx
long long v10; // rdx
long long v11; // rsi
unsigned __int16 v12[44]; // [rsp+0h] [rbp-58h] BYREF
memset(v12, 0, 32);
OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchCornerSpans(
*(_QWORD *)(a1 + 72),
*(__int16 *)(a2 + 4),
*(_DWORD *)a2,
v12,
-1);
OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchConversionMatrix<double>(
*(unsigned int **)(a1 + 72),
*(__int16 *)(a2 + 4),
*(_DWORD *)a2,
(long long)v12,
a3);
v7 = *(int *)(a3 + 4);
std::vector<int>::resize(a4, v7);
OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchSourcePoints(
*(_QWORD *)(a1 + 72),
*(__int16 *)(a2 + 4),
*(_DWORD *)a2,
(long long)v12,
*a4,
-1);
result = *(unsigned int *)(*(_QWORD *)(a1 + 24) + 4LL * *(__int16 *)(a2 + 4));
v9 = *a4;
v10 = 0LL;
v11 = 0LL;
if ( (int)v7 > 0 )
v11 = (unsigned int)v7;
while ( v11 != v10 )
*(_DWORD *)(v9 + 4 * v10++) += result;
return result;
}
| getIrregularPatchConversion<double>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV RBX,RCX
MOV R13,RDX
MOV R15,RSI
MOV R14,RDI
XORPS XMM0,XMM0
MOV R12,RSP
MOVAPS xmmword ptr [R12 + 0x10],XMM0
MOVAPS xmmword ptr [R12],XMM0
MOV RDI,qword ptr [RDI + 0x48]
MOVSX ESI,word ptr [RSI + 0x4]
MOV EDX,dword ptr [R15]
PUSH -0x1
POP RBP
MOV RCX,R12
MOV R8D,EBP
CALL 0x00153250
MOV RDI,qword ptr [R14 + 0x48]
MOVSX ESI,word ptr [R15 + 0x4]
MOV EDX,dword ptr [R15]
MOV RCX,R12
MOV R8,R13
CALL 0x0014f270
MOVSXD R13,dword ptr [R13 + 0x4]
MOV RDI,RBX
MOV RSI,R13
CALL 0x001514b0
MOV RDI,qword ptr [R14 + 0x48]
MOVSX ESI,word ptr [R15 + 0x4]
MOV EDX,dword ptr [R15]
MOV R8,qword ptr [RBX]
MOV RCX,R12
MOV R9D,EBP
CALL 0x00154f00
MOVSX RAX,word ptr [R15 + 0x4]
MOV RCX,qword ptr [R14 + 0x18]
MOV EAX,dword ptr [RCX + RAX*0x4]
MOV RCX,qword ptr [RBX]
XOR EDX,EDX
TEST R13D,R13D
MOV ESI,0x0
CMOVG ESI,R13D
LAB_001a192d:
CMP RSI,RDX
JZ 0x001a193a
ADD dword ptr [RCX + RDX*0x4],EAX
INC RDX
JMP 0x001a192d
LAB_001a193a:
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* void
OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>(OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::PatchFace
const&, OpenSubdiv::v3_6_0::Far::SparseMatrix<double>&, std::vector<int, std::allocator<int> >&)
*/
void __thiscall
OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>
(PatchTreeBuilder *this,PatchFace *param_1,SparseMatrix *param_2,vector *param_3)
{
int *piVar1;
uint uVar2;
int iVar3;
long lVar4;
ulong uVar5;
ulong uVar6;
int8 local_58;
int8 uStack_50;
int8 local_48;
int8 uStack_40;
local_48 = 0;
uStack_40 = 0;
local_58 = 0;
uStack_50 = 0;
Far::PatchBuilder::GetIrregularPatchCornerSpans
(*(PatchBuilder **)(this + 0x48),(int)*(short *)(param_1 + 4),*(int *)param_1,
(VSpan *)&local_58,-1);
Far::PatchBuilder::GetIrregularPatchConversionMatrix<double>
(*(PatchBuilder **)(this + 0x48),(int)*(short *)(param_1 + 4),*(int *)param_1,
(VSpan *)&local_58,param_2);
uVar2 = *(uint *)(param_2 + 4);
std::vector<int,std::allocator<int>>::resize
((vector<int,std::allocator<int>> *)param_3,(long)(int)uVar2);
Far::PatchBuilder::GetIrregularPatchSourcePoints
(*(PatchBuilder **)(this + 0x48),(int)*(short *)(param_1 + 4),*(int *)param_1,
(VSpan *)&local_58,*(int **)param_3,-1);
iVar3 = *(int *)(*(long *)(this + 0x18) + (long)*(short *)(param_1 + 4) * 4);
lVar4 = *(long *)param_3;
uVar5 = 0;
uVar6 = 0;
if (0 < (int)uVar2) {
uVar6 = (ulong)uVar2;
}
for (; uVar6 != uVar5; uVar5 = uVar5 + 1) {
piVar1 = (int *)(lVar4 + uVar5 * 4);
*piVar1 = *piVar1 + iVar3;
}
return;
}
| |
22,153 | void OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>(OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::PatchFace const&, OpenSubdiv::v3_6_0::Far::SparseMatrix<double>&, std::vector<int, std::allocator<int>>&) | NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/patchTreeBuilder.cpp | void
PatchTreeBuilder::getIrregularPatchConversion(PatchFace const & pf,
SparseMatrix<REAL> & conversionMatrix,
std::vector<Index> & sourcePoints) {
//
// The topology of an irregular patch is determined by its four corners:
//
Level::VSpan cornerSpans[4];
_patchBuilder->GetIrregularPatchCornerSpans(pf.level, pf.face, cornerSpans);
//
// Compute the conversion matrix from refined/source points to the
// set of points local to this patch:
//
_patchBuilder->GetIrregularPatchConversionMatrix(pf.level, pf.face,
cornerSpans, conversionMatrix);
//
// Identify the refined/source points for the patch and append stencils
// for the local patch points in terms of the source points:
//
int numSourcePoints = conversionMatrix.GetNumColumns();
sourcePoints.resize(numSourcePoints);
_patchBuilder->GetIrregularPatchSourcePoints(pf.level, pf.face,
cornerSpans, &sourcePoints[0]);
int sourceIndexOffset = _levelOffsets[pf.level];
for (int i = 0; i < numSourcePoints; ++i) {
sourcePoints[i] += sourceIndexOffset;
}
} | O3 | cpp | void OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<double>(OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::PatchFace const&, OpenSubdiv::v3_6_0::Far::SparseMatrix<double>&, std::vector<int, std::allocator<int>>&):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rcx, %rbx
movq %rdx, %r13
movq %rsi, %r15
movq %rdi, %r14
xorps %xmm0, %xmm0
movq %rsp, %r12
movaps %xmm0, 0x10(%r12)
movaps %xmm0, (%r12)
movq 0x48(%rdi), %rdi
movswl 0x4(%rsi), %esi
movl (%r15), %edx
movq %r12, %rcx
movl $0xffffffff, %r8d # imm = 0xFFFFFFFF
callq 0x3a870
movq 0x48(%r14), %rdi
movswl 0x4(%r15), %esi
movl (%r15), %edx
movq %r12, %rcx
movq %r13, %r8
callq 0x39290
movslq 0x4(%r13), %r13
movq %rbx, %rdi
movq %r13, %rsi
callq 0x39670
movq 0x48(%r14), %rdi
movswl 0x4(%r15), %esi
movl (%r15), %edx
movq (%rbx), %r8
movq %r12, %rcx
movl $0xffffffff, %r9d # imm = 0xFFFFFFFF
callq 0x3ba80
testq %r13, %r13
jle 0x972ed
movswq 0x4(%r15), %rax
movq 0x18(%r14), %rcx
movl (%rcx,%rax,4), %eax
movq (%rbx), %rcx
xorl %edx, %edx
addl %eax, (%rcx,%rdx,4)
incq %rdx
cmpq %rdx, %r13
jne 0x972e2
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
| _ZN10OpenSubdiv6v3_6_03Bfr16PatchTreeBuilder27getIrregularPatchConversionIfEEvRKNS2_9PatchFaceERNS0_3Far12SparseMatrixIT_EERSt6vectorIiSaIiEE:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 20h
mov rbx, rcx
mov r13, rdx
mov r15, rsi
mov r14, rdi
xorps xmm0, xmm0
mov r12, rsp
movaps xmmword ptr [r12+10h], xmm0
movaps xmmword ptr [r12], xmm0
mov rdi, [rdi+48h]
movsx esi, word ptr [rsi+4]
mov edx, [r15]
mov rcx, r12
mov r8d, 0FFFFFFFFh
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder28GetIrregularPatchCornerSpansEiiPNS0_3Vtr8internal5Level5VSpanEi; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchCornerSpans(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan *,int)
mov rdi, [r14+48h]
movsx esi, word ptr [r15+4]
mov edx, [r15]
mov rcx, r12
mov r8, r13
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder33GetIrregularPatchConversionMatrixIfEEiiiPKNS0_3Vtr8internal5Level5VSpanERNS1_12SparseMatrixIT_EE; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchConversionMatrix<float>(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan const*,OpenSubdiv::v3_6_0::Far::SparseMatrix<float> &)
movsxd r13, dword ptr [r13+4]
mov rdi, rbx
mov rsi, r13
call __ZNSt6vectorIiSaIiEE6resizeEm; std::vector<int>::resize(ulong)
mov rdi, [r14+48h]
movsx esi, word ptr [r15+4]
mov edx, [r15]
mov r8, [rbx]
mov rcx, r12
mov r9d, 0FFFFFFFFh
call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder29GetIrregularPatchSourcePointsEiiPKNS0_3Vtr8internal5Level5VSpanEPii; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchSourcePoints(int,int,OpenSubdiv::v3_6_0::Vtr::internal::Level::VSpan const*,int *,int)
test r13, r13
jle short loc_972ED
movsx rax, word ptr [r15+4]
mov rcx, [r14+18h]
mov eax, [rcx+rax*4]
mov rcx, [rbx]
xor edx, edx
loc_972E2:
add [rcx+rdx*4], eax
inc rdx
cmp r13, rdx
jnz short loc_972E2
loc_972ED:
add rsp, 20h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| long long OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<float>(
long long a1,
long long a2,
long long a3,
long long *a4)
{
long long v7; // r13
long long result; // rax
long long v9; // rcx
long long i; // rdx
unsigned __int16 v11[36]; // [rsp+0h] [rbp-48h] BYREF
memset(v11, 0, 32);
OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchCornerSpans(
*(_QWORD *)(a1 + 72),
*(__int16 *)(a2 + 4),
*(_DWORD *)a2,
v11,
-1);
OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchConversionMatrix<float>(
*(unsigned int **)(a1 + 72),
*(__int16 *)(a2 + 4),
*(_DWORD *)a2,
(long long)v11,
a3);
v7 = *(int *)(a3 + 4);
std::vector<int>::resize(a4, v7);
result = OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchSourcePoints(
*(_QWORD *)(a1 + 72),
*(__int16 *)(a2 + 4),
*(_DWORD *)a2,
(long long)v11,
*a4,
-1);
if ( v7 > 0 )
{
result = *(unsigned int *)(*(_QWORD *)(a1 + 24) + 4LL * *(__int16 *)(a2 + 4));
v9 = *a4;
for ( i = 0LL; i != v7; ++i )
*(_DWORD *)(v9 + 4 * i) += result;
}
return result;
}
| getIrregularPatchConversion<float>:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x20
MOV RBX,RCX
MOV R13,RDX
MOV R15,RSI
MOV R14,RDI
XORPS XMM0,XMM0
MOV R12,RSP
MOVAPS xmmword ptr [R12 + 0x10],XMM0
MOVAPS xmmword ptr [R12],XMM0
MOV RDI,qword ptr [RDI + 0x48]
MOVSX ESI,word ptr [RSI + 0x4]
MOV EDX,dword ptr [R15]
MOV RCX,R12
MOV R8D,0xffffffff
CALL 0x0013a870
MOV RDI,qword ptr [R14 + 0x48]
MOVSX ESI,word ptr [R15 + 0x4]
MOV EDX,dword ptr [R15]
MOV RCX,R12
MOV R8,R13
CALL 0x00139290
MOVSXD R13,dword ptr [R13 + 0x4]
MOV RDI,RBX
MOV RSI,R13
CALL 0x00139670
MOV RDI,qword ptr [R14 + 0x48]
MOVSX ESI,word ptr [R15 + 0x4]
MOV EDX,dword ptr [R15]
MOV R8,qword ptr [RBX]
MOV RCX,R12
MOV R9D,0xffffffff
CALL 0x0013ba80
TEST R13,R13
JLE 0x001972ed
MOVSX RAX,word ptr [R15 + 0x4]
MOV RCX,qword ptr [R14 + 0x18]
MOV EAX,dword ptr [RCX + RAX*0x4]
MOV RCX,qword ptr [RBX]
XOR EDX,EDX
LAB_001972e2:
ADD dword ptr [RCX + RDX*0x4],EAX
INC RDX
CMP R13,RDX
JNZ 0x001972e2
LAB_001972ed:
ADD RSP,0x20
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
/* void
OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<float>(OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::PatchFace
const&, OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, std::vector<int, std::allocator<int> >&)
*/
void __thiscall
OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::getIrregularPatchConversion<float>
(PatchTreeBuilder *this,PatchFace *param_1,SparseMatrix *param_2,vector *param_3)
{
int *piVar1;
int iVar2;
long lVar3;
ulong uVar4;
ulong uVar5;
int8 local_48;
int8 uStack_40;
int8 local_38;
int8 uStack_30;
local_38 = 0;
uStack_30 = 0;
local_48 = 0;
uStack_40 = 0;
Far::PatchBuilder::GetIrregularPatchCornerSpans
(*(PatchBuilder **)(this + 0x48),(int)*(short *)(param_1 + 4),*(int *)param_1,
(VSpan *)&local_48,-1);
Far::PatchBuilder::GetIrregularPatchConversionMatrix<float>
(*(PatchBuilder **)(this + 0x48),(int)*(short *)(param_1 + 4),*(int *)param_1,
(VSpan *)&local_48,param_2);
uVar5 = (ulong)*(int *)(param_2 + 4);
std::vector<int,std::allocator<int>>::resize((vector<int,std::allocator<int>> *)param_3,uVar5);
Far::PatchBuilder::GetIrregularPatchSourcePoints
(*(PatchBuilder **)(this + 0x48),(int)*(short *)(param_1 + 4),*(int *)param_1,
(VSpan *)&local_48,*(int **)param_3,-1);
if (0 < (long)uVar5) {
iVar2 = *(int *)(*(long *)(this + 0x18) + (long)*(short *)(param_1 + 4) * 4);
lVar3 = *(long *)param_3;
uVar4 = 0;
do {
piVar1 = (int *)(lVar3 + uVar4 * 4);
*piVar1 = *piVar1 + iVar2;
uVar4 = uVar4 + 1;
} while (uVar5 != uVar4);
}
return;
}
| |
22,154 | write_dynamic_record | eloqsql/storage/maria/ma_dynrec.c | static my_bool write_dynamic_record(MARIA_HA *info, const uchar *record,
ulong reclength)
{
int flag;
ulong length;
my_off_t filepos;
DBUG_ENTER("write_dynamic_record");
flag=0;
/*
Check if we have enough room for the new record.
First we do simplified check to make usual case faster.
Then we do more precise check for the space left.
Though it still is not absolutely precise, as
we always use MARIA_MAX_DYN_BLOCK_HEADER while it can be
less in the most of the cases.
*/
if (unlikely(info->s->base.max_data_file_length -
info->state->data_file_length <
reclength + MARIA_MAX_DYN_BLOCK_HEADER))
{
if (info->s->base.max_data_file_length - info->state->data_file_length +
info->state->empty - info->state->del * MARIA_MAX_DYN_BLOCK_HEADER <
reclength + MARIA_MAX_DYN_BLOCK_HEADER)
{
my_errno=HA_ERR_RECORD_FILE_FULL;
DBUG_RETURN(1);
}
}
do
{
if (_ma_find_writepos(info,reclength,&filepos,&length))
goto err;
if (_ma_write_part_record(info,filepos,length,
(info->append_insert_at_end ?
HA_OFFSET_ERROR : info->s->state.dellink),
(uchar**) &record,&reclength,&flag))
goto err;
} while (reclength);
DBUG_RETURN(0);
err:
DBUG_RETURN(1);
} | O0 | c | write_dynamic_record:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl $0x0, -0x24(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x368(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x20(%rcx), %rcx
subq 0x28(%rcx), %rax
movq -0x20(%rbp), %rcx
addq $0x14, %rcx
cmpq %rcx, %rax
setb %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x38d94
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x368(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x20(%rcx), %rcx
subq 0x28(%rcx), %rax
movq -0x10(%rbp), %rcx
movq 0x20(%rcx), %rcx
addq 0x10(%rcx), %rax
movq -0x10(%rbp), %rcx
movq 0x20(%rcx), %rcx
imulq $0x14, 0x8(%rcx), %rcx
subq %rcx, %rax
movq -0x20(%rbp), %rcx
addq $0x14, %rcx
cmpq %rcx, %rax
jae 0x38d92
callq 0xfabb0
movl $0x87, (%rax)
movb $0x1, -0x1(%rbp)
jmp 0x38e43
jmp 0x38d94
jmp 0x38d96
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rsi
leaq -0x38(%rbp), %rdx
leaq -0x30(%rbp), %rcx
callq 0x3de20
cmpl $0x0, %eax
je 0x38db5
jmp 0x38e3d
movq -0x10(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rax
movsbl 0x681(%rax), %eax
cmpl $0x0, %eax
je 0x38dea
movq $-0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0x38dfc
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0xc8(%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x40(%rbp), %rdx
movq -0x48(%rbp), %rsi
movq -0x50(%rbp), %rdi
movq -0x58(%rbp), %rcx
leaq -0x18(%rbp), %r8
leaq -0x20(%rbp), %r9
leaq -0x24(%rbp), %rax
movq %rax, (%rsp)
callq 0x39e80
cmpl $0x0, %eax
je 0x38e28
jmp 0x38e3d
jmp 0x38e2a
cmpq $0x0, -0x20(%rbp)
jne 0x38d96
jmp 0x38e37
movb $0x0, -0x1(%rbp)
jmp 0x38e43
jmp 0x38e3f
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
| write_dynamic_record:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_24], 0
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+368h]
mov rcx, [rbp+var_10]
mov rcx, [rcx+20h]
sub rax, [rcx+28h]
mov rcx, [rbp+var_20]
add rcx, 14h
cmp rax, rcx
setb 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_38D94
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+368h]
mov rcx, [rbp+var_10]
mov rcx, [rcx+20h]
sub rax, [rcx+28h]
mov rcx, [rbp+var_10]
mov rcx, [rcx+20h]
add rax, [rcx+10h]
mov rcx, [rbp+var_10]
mov rcx, [rcx+20h]
imul rcx, [rcx+8], 14h
sub rax, rcx
mov rcx, [rbp+var_20]
add rcx, 14h
cmp rax, rcx
jnb short loc_38D92
call _my_thread_var
mov dword ptr [rax], 87h
mov [rbp+var_1], 1
jmp loc_38E43
loc_38D92:
jmp short $+2
loc_38D94:
jmp short $+2
loc_38D96:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_20]
lea rdx, [rbp+var_38]
lea rcx, [rbp+var_30]
call _ma_find_writepos
cmp eax, 0
jz short loc_38DB5
jmp loc_38E3D
loc_38DB5:
mov rax, [rbp+var_10]
mov [rbp+var_50], rax
mov rax, [rbp+var_38]
mov [rbp+var_48], rax
mov rax, [rbp+var_30]
mov [rbp+var_40], rax
mov rax, [rbp+var_10]
movsx eax, byte ptr [rax+681h]
cmp eax, 0
jz short loc_38DEA
mov rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_58], rax
jmp short loc_38DFC
loc_38DEA:
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+0C8h]
mov [rbp+var_58], rax
loc_38DFC:
mov rdx, [rbp+var_40]
mov rsi, [rbp+var_48]
mov rdi, [rbp+var_50]
mov rcx, [rbp+var_58]
lea r8, [rbp+var_18]
lea r9, [rbp+var_20]
lea rax, [rbp+var_24]
mov [rsp+60h+var_60], rax
call _ma_write_part_record
cmp eax, 0
jz short loc_38E28
jmp short loc_38E3D
loc_38E28:
jmp short $+2
loc_38E2A:
cmp [rbp+var_20], 0
jnz loc_38D96
jmp short $+2
loc_38E37:
mov [rbp+var_1], 0
jmp short loc_38E43
loc_38E3D:
jmp short $+2
loc_38E3F:
mov [rbp+var_1], 1
loc_38E43:
mov al, [rbp+var_1]
add rsp, 60h
pop rbp
retn
| char write_dynamic_record(_QWORD *a1, long long a2, long long a3)
{
long long v5; // [rsp+28h] [rbp-38h] BYREF
long long v6; // [rsp+30h] [rbp-30h] BYREF
int v7; // [rsp+3Ch] [rbp-24h] BYREF
long long v8; // [rsp+40h] [rbp-20h] BYREF
long long v9; // [rsp+48h] [rbp-18h] BYREF
_QWORD *v10; // [rsp+50h] [rbp-10h]
v10 = a1;
v9 = a2;
v8 = a3;
v7 = 0;
if ( *(_QWORD *)(*a1 + 872LL) - *(_QWORD *)(a1[4] + 40LL) >= (unsigned long long)(a3 + 20)
|| *(_QWORD *)(v10[4] + 16LL)
+ *(_QWORD *)(*v10 + 872LL)
- *(_QWORD *)(v10[4] + 40LL)
- 20LL * *(_QWORD *)(v10[4] + 8LL) >= (unsigned long long)(v8 + 20) )
{
while ( !(unsigned int)ma_find_writepos(v10, v8, &v5, &v6) )
{
if ( *((_BYTE *)v10 + 1665)
? ma_write_part_record((_DWORD)v10, v5, v6, -1, (unsigned int)&v9, (unsigned int)&v8, (long long)&v7)
: (unsigned int)ma_write_part_record(
(_DWORD)v10,
v5,
v6,
*(_QWORD *)(*v10 + 200LL),
(unsigned int)&v9,
(unsigned int)&v8,
(long long)&v7) )
{
break;
}
if ( !v8 )
return 0;
}
return 1;
}
else
{
*(_DWORD *)my_thread_var() = 135;
return 1;
}
}
| write_dynamic_record:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x24],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x368]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x20]
SUB RAX,qword ptr [RCX + 0x28]
MOV RCX,qword ptr [RBP + -0x20]
ADD RCX,0x14
CMP RAX,RCX
SETC AL
AND AL,0x1
MOVZX EAX,AL
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x00138d94
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x368]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x20]
SUB RAX,qword ptr [RCX + 0x28]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x20]
ADD RAX,qword ptr [RCX + 0x10]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x20]
IMUL RCX,qword ptr [RCX + 0x8],0x14
SUB RAX,RCX
MOV RCX,qword ptr [RBP + -0x20]
ADD RCX,0x14
CMP RAX,RCX
JNC 0x00138d92
CALL 0x001fabb0
MOV dword ptr [RAX],0x87
MOV byte ptr [RBP + -0x1],0x1
JMP 0x00138e43
LAB_00138d92:
JMP 0x00138d94
LAB_00138d94:
JMP 0x00138d96
LAB_00138d96:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x20]
LEA RDX,[RBP + -0x38]
LEA RCX,[RBP + -0x30]
CALL 0x0013de20
CMP EAX,0x0
JZ 0x00138db5
JMP 0x00138e3d
LAB_00138db5:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOVSX EAX,byte ptr [RAX + 0x681]
CMP EAX,0x0
JZ 0x00138dea
MOV RAX,-0x1
MOV qword ptr [RBP + -0x58],RAX
JMP 0x00138dfc
LAB_00138dea:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0xc8]
MOV qword ptr [RBP + -0x58],RAX
LAB_00138dfc:
MOV RDX,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RBP + -0x48]
MOV RDI,qword ptr [RBP + -0x50]
MOV RCX,qword ptr [RBP + -0x58]
LEA R8,[RBP + -0x18]
LEA R9,[RBP + -0x20]
LEA RAX,[RBP + -0x24]
MOV qword ptr [RSP],RAX
CALL 0x00139e80
CMP EAX,0x0
JZ 0x00138e28
JMP 0x00138e3d
LAB_00138e28:
JMP 0x00138e2a
LAB_00138e2a:
CMP qword ptr [RBP + -0x20],0x0
JNZ 0x00138d96
JMP 0x00138e37
LAB_00138e37:
MOV byte ptr [RBP + -0x1],0x0
JMP 0x00138e43
LAB_00138e3d:
JMP 0x00138e3f
LAB_00138e3f:
MOV byte ptr [RBP + -0x1],0x1
LAB_00138e43:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x60
POP RBP
RET
|
int1 write_dynamic_record(long *param_1,int8 param_2,long param_3)
{
int iVar1;
int4 *puVar2;
int8 local_60;
int8 local_40;
int8 local_38;
int4 local_2c;
long local_28;
int8 local_20;
long *local_18;
int1 local_9;
local_2c = 0;
local_28 = param_3;
local_20 = param_2;
local_18 = param_1;
if (((ulong)(*(long *)(*param_1 + 0x368) - *(long *)(param_1[4] + 0x28)) < param_3 + 0x14U) &&
((ulong)((*(long *)(*param_1 + 0x368) - *(long *)(param_1[4] + 0x28)) +
*(long *)(param_1[4] + 0x10) + *(long *)(param_1[4] + 8) * -0x14) < param_3 + 0x14U))
{
puVar2 = (int4 *)_my_thread_var();
*puVar2 = 0x87;
local_9 = 1;
}
else {
do {
iVar1 = _ma_find_writepos(local_18,local_28,&local_40,&local_38);
if (iVar1 != 0) {
return 1;
}
if (*(char *)((long)local_18 + 0x681) == '\0') {
local_60 = *(int8 *)(*local_18 + 200);
}
else {
local_60 = 0xffffffffffffffff;
}
iVar1 = _ma_write_part_record
(local_18,local_40,local_38,local_60,&local_20,&local_28,&local_2c);
if (iVar1 != 0) {
return 1;
}
} while (local_28 != 0);
local_9 = 0;
}
return local_9;
}
| |
22,155 | mysql_close_slow_part | eloqsql/libmariadb/libmariadb/mariadb_lib.c | void mysql_close_slow_part(MYSQL *mysql)
{
if (mysql->net.pvio)
{
free_old_query(mysql);
mysql->status=MYSQL_STATUS_READY; /* Force command */
mysql->options.reconnect=0;
if (mysql->net.pvio && mysql->net.buff)
ma_simple_command(mysql, COM_QUIT,NullS,0,1,0);
end_server(mysql);
}
/* there is an ongoing async operation */
else if (mysql->options.extension && mysql->options.extension->async_context)
{
if (mysql->options.extension->async_context->pending_gai_res)
{
freeaddrinfo(mysql->options.extension->async_context->pending_gai_res);
mysql->options.extension->async_context->pending_gai_res = 0;
}
if (mysql->options.extension->async_context->pvio)
{
ma_pvio_close(mysql->options.extension->async_context->pvio);
mysql->options.extension->async_context->pvio = 0;
}
}
} | O0 | c | mysql_close_slow_part:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, (%rax)
je 0x1e0a8
movq -0x8(%rbp), %rdi
callq 0x1e170
movq -0x8(%rbp), %rax
movl $0x0, 0x488(%rax)
movq -0x8(%rbp), %rax
movb $0x0, 0x43b(%rax)
movq -0x8(%rbp), %rax
cmpq $0x0, (%rax)
je 0x1e09a
movq -0x8(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x1e09a
movq -0x8(%rbp), %rdi
movl $0x1, %r8d
xorl %eax, %eax
movl %eax, %r9d
movl %r8d, %esi
movq %r9, %rdx
movq %r9, %rcx
callq 0x16e20
movq -0x8(%rbp), %rdi
callq 0x15f80
jmp 0x1e15e
movq -0x8(%rbp), %rax
cmpq $0x0, 0x480(%rax)
je 0x1e15c
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
cmpq $0x0, 0x28(%rax)
je 0x1e15c
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
cmpq $0x0, 0x30(%rax)
je 0x1e115
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x13590
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq $0x0, 0x30(%rax)
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
cmpq $0x0, 0x18(%rax)
je 0x1e15a
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq 0x18(%rax), %rdi
callq 0x23b70
movq -0x8(%rbp), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq $0x0, 0x18(%rax)
jmp 0x1e15c
jmp 0x1e15e
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| mysql_close_slow_part:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
cmp qword ptr [rax], 0
jz short loc_1E0A8
mov rdi, [rbp+var_8]
call free_old_query
mov rax, [rbp+var_8]
mov dword ptr [rax+488h], 0
mov rax, [rbp+var_8]
mov byte ptr [rax+43Bh], 0
mov rax, [rbp+var_8]
cmp qword ptr [rax], 0
jz short loc_1E09A
mov rax, [rbp+var_8]
cmp qword ptr [rax+8], 0
jz short loc_1E09A
mov rdi, [rbp+var_8]
mov r8d, 1
xor eax, eax
mov r9d, eax
mov esi, r8d
mov rdx, r9
mov rcx, r9
call ma_simple_command
loc_1E09A:
mov rdi, [rbp+var_8]
call end_server
jmp loc_1E15E
loc_1E0A8:
mov rax, [rbp+var_8]
cmp qword ptr [rax+480h], 0
jz loc_1E15C
mov rax, [rbp+var_8]
mov rax, [rax+480h]
cmp qword ptr [rax+28h], 0
jz loc_1E15C
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
cmp qword ptr [rax+30h], 0
jz short loc_1E115
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov rdi, [rax+30h]
call _freeaddrinfo
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov qword ptr [rax+30h], 0
loc_1E115:
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
cmp qword ptr [rax+18h], 0
jz short loc_1E15A
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov rdi, [rax+18h]
call ma_pvio_close
mov rax, [rbp+var_8]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov qword ptr [rax+18h], 0
loc_1E15A:
jmp short $+2
loc_1E15C:
jmp short $+2
loc_1E15E:
add rsp, 10h
pop rbp
retn
| long long mysql_close_slow_part(long long a1)
{
long long result; // rax
if ( *(_QWORD *)a1 )
{
free_old_query(a1);
*(_DWORD *)(a1 + 1160) = 0;
*(_BYTE *)(a1 + 1083) = 0;
if ( *(_QWORD *)a1 )
{
if ( *(_QWORD *)(a1 + 8) )
ma_simple_command(a1, 1u, 0LL, 0LL, 1, 0LL);
}
return end_server((_QWORD *)a1);
}
else
{
result = a1;
if ( *(_QWORD *)(a1 + 1152) )
{
result = *(_QWORD *)(a1 + 1152);
if ( *(_QWORD *)(result + 40) )
{
if ( *(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL) )
{
freeaddrinfo(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL));
*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 48LL) = 0LL;
}
result = *(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL);
if ( *(_QWORD *)(result + 24) )
{
ma_pvio_close(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL) + 24LL));
result = *(_QWORD *)(*(_QWORD *)(a1 + 1152) + 40LL);
*(_QWORD *)(result + 24) = 0LL;
}
}
}
}
return result;
}
| mysql_close_slow_part:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX],0x0
JZ 0x0011e0a8
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x0011e170
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x488],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x43b],0x0
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX],0x0
JZ 0x0011e09a
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x8],0x0
JZ 0x0011e09a
MOV RDI,qword ptr [RBP + -0x8]
MOV R8D,0x1
XOR EAX,EAX
MOV R9D,EAX
MOV ESI,R8D
MOV RDX,R9
MOV RCX,R9
CALL 0x00116e20
LAB_0011e09a:
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00115f80
JMP 0x0011e15e
LAB_0011e0a8:
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x480],0x0
JZ 0x0011e15c
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
CMP qword ptr [RAX + 0x28],0x0
JZ 0x0011e15c
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
CMP qword ptr [RAX + 0x30],0x0
JZ 0x0011e115
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV RDI,qword ptr [RAX + 0x30]
CALL 0x00113590
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RAX + 0x30],0x0
LAB_0011e115:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
CMP qword ptr [RAX + 0x18],0x0
JZ 0x0011e15a
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV RDI,qword ptr [RAX + 0x18]
CALL 0x00123b70
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RAX + 0x18],0x0
LAB_0011e15a:
JMP 0x0011e15c
LAB_0011e15c:
JMP 0x0011e15e
LAB_0011e15e:
ADD RSP,0x10
POP RBP
RET
|
void mysql_close_slow_part(long *param_1)
{
if (*param_1 == 0) {
if ((param_1[0x90] != 0) && (*(long *)(param_1[0x90] + 0x28) != 0)) {
if (*(long *)(*(long *)(param_1[0x90] + 0x28) + 0x30) != 0) {
freeaddrinfo(*(addrinfo **)(*(long *)(param_1[0x90] + 0x28) + 0x30));
*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x30) = 0;
}
if (*(long *)(*(long *)(param_1[0x90] + 0x28) + 0x18) != 0) {
ma_pvio_close(*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x18));
*(int8 *)(*(long *)(param_1[0x90] + 0x28) + 0x18) = 0;
}
}
}
else {
free_old_query(param_1);
*(int4 *)(param_1 + 0x91) = 0;
*(int1 *)((long)param_1 + 0x43b) = 0;
if ((*param_1 != 0) && (param_1[1] != 0)) {
ma_simple_command(param_1,1,0,0);
}
end_server(param_1);
}
return;
}
| |
22,156 | maria_rtree_insert_req | eloqsql/storage/maria/ma_rt_index.c | static int maria_rtree_insert_req(MARIA_HA *info, MARIA_KEY *key,
my_off_t page_pos, my_off_t *new_page,
int ins_level, int level)
{
uint nod_flag;
uint key_length= key->data_length;
int res;
my_bool buff_alloced;
uchar *page_buf, *k;
MARIA_SHARE *share= info->s;
MARIA_KEYDEF *keyinfo= key->keyinfo;
MARIA_PAGE page;
DBUG_ENTER("maria_rtree_insert_req");
alloc_on_stack(*info->stack_end_ptr, page_buf, buff_alloced,
keyinfo->block_length + keyinfo->max_store_length);
if (!page_buf)
{
my_errno= HA_ERR_OUT_OF_MEM;
DBUG_RETURN(-1); /* purecov: inspected */
}
if (_ma_fetch_keypage(&page, info, keyinfo, page_pos, PAGECACHE_LOCK_WRITE,
DFLT_INIT_HITS, page_buf, 0))
goto err;
nod_flag= page.node;
DBUG_PRINT("rtree", ("page: %lu level: %d ins_level: %d nod_flag: %u",
(ulong) page.pos, level, ins_level, nod_flag));
if ((ins_level == -1 && nod_flag) || /* key: go down to leaf */
(ins_level > -1 && ins_level > level)) /* branch: go down to ins_level */
{
if (!(k= (uchar *)maria_rtree_pick_key(key, &page)))
goto err;
/* k is now a pointer inside the page_buf buffer */
switch ((res= maria_rtree_insert_req(info, key,
_ma_kpos(nod_flag, k), new_page,
ins_level, level + 1)))
{
case 0: /* child was not split, most common case */
{
maria_rtree_combine_rect(keyinfo->seg, k, key->data, k, key_length);
if (share->now_transactional &&
_ma_log_change(&page, k, key_length,
KEY_OP_DEBUG_RTREE_COMBINE))
goto err;
page_mark_changed(info, &page);
if (_ma_write_keypage(&page, PAGECACHE_LOCK_LEFT_WRITELOCKED,
DFLT_INIT_HITS))
goto err;
goto ok;
}
case 1: /* child was split */
{
/* Set new_key to point to a free buffer area */
uchar *new_key_buff= page_buf + keyinfo->block_length + nod_flag;
MARIA_KEY new_key;
MARIA_KEY k_key;
DBUG_ASSERT(nod_flag);
k_key.keyinfo= new_key.keyinfo= keyinfo;
new_key.data= new_key_buff;
k_key.data= k;
k_key.data_length= new_key.data_length= key->data_length;
k_key.ref_length= new_key.ref_length= key->ref_length;
k_key.flag= new_key.flag= 0; /* Safety */
/* set proper MBR for key */
if (maria_rtree_set_key_mbr(info, &k_key, _ma_kpos(nod_flag, k)))
goto err;
if (share->now_transactional &&
_ma_log_change(&page, k, key_length,
KEY_OP_DEBUG_RTREE_SPLIT))
goto err;
/* add new key for new page */
_ma_kpointer(info, new_key_buff - nod_flag, *new_page);
if (maria_rtree_set_key_mbr(info, &new_key, *new_page))
goto err;
res= maria_rtree_add_key(&new_key, &page, new_page);
page_mark_changed(info, &page);
if (_ma_write_keypage(&page, PAGECACHE_LOCK_LEFT_WRITELOCKED,
DFLT_INIT_HITS))
goto err;
goto ok;
}
default:
case -1: /* error */
{
goto err;
}
}
}
else
{
res= maria_rtree_add_key(key, &page, new_page);
page_mark_changed(info, &page);
if (_ma_write_keypage(&page, PAGECACHE_LOCK_LEFT_WRITELOCKED,
DFLT_INIT_HITS))
goto err;
}
ok:
stack_alloc_free(page_buf, buff_alloced);
DBUG_RETURN(res);
err:
res= -1; /* purecov: inspected */
goto ok; /* purecov: inspected */
} | O3 | c | maria_rtree_insert_req:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movl %r9d, -0x44(%rbp)
movl %r8d, -0x48(%rbp)
movq %rcx, -0x50(%rbp)
movq %rdx, %rbx
movq %rsi, %r13
movq %rdi, %r12
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
movl 0x10(%rsi), %eax
movl %eax, -0x38(%rbp)
movq (%rdi), %rax
movq %rax, -0x70(%rbp)
movq 0x8(%rsi), %rcx
movzwl 0xa6(%rcx), %eax
movq %rcx, -0x58(%rbp)
movzwl 0xb0(%rcx), %esi
addq %rax, %rsi
leaq -0xd8(%rbp), %rcx
movq %rsi, (%rcx)
movq 0x78(%rdi), %rax
movq (%rax), %rax
subq %rcx, %rax
subq %rsi, %rax
jbe 0x6bc3e
cmpq $0x10000, %rax # imm = 0x10000
ja 0x6bc2a
cmpl $0x1000, %esi # imm = 0x1000
jb 0x6bc3e
cmpq $0x8001, %rax # imm = 0x8001
jb 0x6bc3e
movq %rsp, %r14
addl $0xf, %esi
andl $-0x10, %esi
subq %rsi, %r14
movq %r14, %rsp
movb $0x1, %r15b
jmp 0x6bc59
xorl %r15d, %r15d
movl $0x10010, %edx # imm = 0x10010
xorl %edi, %edi
callq 0x9fd89
testq %rax, %rax
je 0x6be77
movq %rax, %r14
leaq -0xd8(%rbp), %rdi
movq %r12, %rsi
movq -0x58(%rbp), %rdx
movq %rbx, %rcx
movl $0x4, %r8d
movl $0x3, %r9d
pushq $0x0
pushq %r14
callq 0x58ed6
addq $0x10, %rsp
testb %al, %al
jne 0x6bedd
movq %r12, -0x40(%rbp)
movl %r15d, -0x34(%rbp)
movl -0xb0(%rbp), %eax
movl -0x48(%rbp), %esi
cmpl $-0x1, %esi
sete %cl
testl %eax, %eax
setne %dl
testb %dl, %cl
jne 0x6bcbe
testl %esi, %esi
sets %cl
cmpl -0x44(%rbp), %esi
setle %dl
orb %cl, %dl
jne 0x6be93
movq %r14, -0x68(%rbp)
movl %eax, %edx
movq -0xd8(%rbp), %rax
movq -0xc8(%rbp), %rcx
movq (%rax), %rax
movq %rax, %r12
movl 0x744(%rax), %r15d
movq %rdx, -0x60(%rbp)
addq %rcx, %r15
addq %rdx, %r15
movl -0xb8(%rbp), %r14d
addq %rcx, %r14
cmpq %r14, %r15
jae 0x6be89
movl 0x10(%r13), %ecx
movsd 0x752c0(%rip), %xmm2 # 0xe0fc8
xorl %ebx, %ebx
movsd %xmm2, -0xa0(%rbp)
movq (%r13), %rdx
movq 0x8(%r13), %rax
movq 0xc0(%rax), %rdi
addl 0x14(%r13), %ecx
movq %r15, %rsi
leaq -0x90(%rbp), %r8
callq 0x6e951
ucomisd 0x75294(%rip), %xmm0 # 0xe0fd0
jne 0x6bd44
jnp 0x6be89
movsd -0x90(%rbp), %xmm1
testq %rbx, %rbx
movsd -0xa0(%rbp), %xmm2
je 0x6bd75
ucomisd %xmm0, %xmm2
ja 0x6bd75
ucomisd %xmm2, %xmm0
jne 0x6bd84
jp 0x6bd84
movsd -0x98(%rbp), %xmm3
ucomisd %xmm1, %xmm3
jbe 0x6bd84
movapd %xmm0, %xmm2
movsd %xmm1, -0x98(%rbp)
movq %r15, %rbx
movl -0xb0(%rbp), %eax
testl %eax, %eax
jne 0x6bd96
movl 0x3e0(%r12), %eax
movl 0x10(%r13), %ecx
addq %rcx, %r15
movl %eax, %eax
addq %rax, %r15
cmpq %r14, %r15
jb 0x6bd0a
testq %rbx, %rbx
movq -0x68(%rbp), %r14
movl -0x34(%rbp), %r15d
movq -0x40(%rbp), %r12
je 0x6bedd
movq -0x60(%rbp), %rdi
movq %rbx, %rsi
callq 0x56ee7
movl -0x44(%rbp), %r9d
incl %r9d
movq %r12, %rdi
movq %r13, %rsi
movq %rax, %rdx
movq -0x50(%rbp), %rcx
movl -0x48(%rbp), %r8d
callq 0x6bb9d
cmpl $0x1, %eax
je 0x6bf13
testl %eax, %eax
movq -0x40(%rbp), %r12
jne 0x6bedd
movq -0x58(%rbp), %rax
movq 0xc0(%rax), %rdi
movq (%r13), %rdx
movq %rbx, %rsi
movq %rbx, %rcx
movl -0x38(%rbp), %r8d
callq 0x6df51
movq -0x70(%rbp), %rax
cmpb $0x0, 0x7e7(%rax)
je 0x6be45
leaq -0xd8(%rbp), %rdi
movq %rbx, %rsi
movl -0x38(%rbp), %edx
xorl %ecx, %ecx
callq 0x670a6
testb %al, %al
jne 0x6bedd
movq 0x2e8(%r12), %rax
leaq -0xd8(%rbp), %rdi
movl 0x30(%rdi), %ecx
leaq (%rcx,%rcx,2), %rcx
movb $0x1, 0x10(%rax,%rcx,8)
movl $0x2, %esi
movl $0x3, %edx
callq 0x59015
testb %al, %al
jne 0x6bedd
xorl %ebx, %ebx
jmp 0x6bee2
callq 0xa1afa
movl $0x80, (%rax)
movl $0xffffffff, %ebx # imm = 0xFFFFFFFF
jmp 0x6beef
movq -0x68(%rbp), %r14
movl -0x34(%rbp), %r15d
jmp 0x6bedd
leaq -0xd8(%rbp), %r15
movq %r13, %rdi
movq %r15, %rsi
movq -0x50(%rbp), %rdx
callq 0x6ce04
movl %eax, %ebx
movq -0x40(%rbp), %rax
movq 0x2e8(%rax), %rax
movl 0x30(%r15), %ecx
leaq (%rcx,%rcx,2), %rcx
movb $0x1, 0x10(%rax,%rcx,8)
movq %r15, %rdi
movl $0x2, %esi
movl $0x3, %edx
callq 0x59015
testb %al, %al
movl -0x34(%rbp), %r15d
je 0x6bee2
movl $0xffffffff, %ebx # imm = 0xFFFFFFFF
testb %r15b, %r15b
jne 0x6beef
movq %r14, %rdi
callq 0x9ffb6
movq %fs:0x28, %rax
cmpq -0x30(%rbp), %rax
jne 0x6c039
movl %ebx, %eax
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq -0x58(%rbp), %rcx
movzwl 0xa6(%rcx), %r12d
addq %r14, %r12
movq -0x60(%rbp), %rdi
movq %rdi, %rax
addq %r12, %rax
movq %rcx, -0x88(%rbp)
leaq -0xf8(%rbp), %r15
movq %rcx, 0x8(%r15)
movq %rax, -0x90(%rbp)
movq %rbx, (%r15)
movl 0x10(%r13), %eax
movl %eax, -0x80(%rbp)
movl %eax, 0x10(%r15)
movl 0x14(%r13), %eax
movl %eax, -0x7c(%rbp)
movl %eax, 0x14(%r15)
xorl %eax, %eax
movl %eax, -0x78(%rbp)
movl %eax, 0x18(%r15)
movq %rbx, %rsi
callq 0x56ee7
movq -0x40(%rbp), %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x6cfa3
testl %eax, %eax
jne 0x6be8d
movq -0x70(%rbp), %rax
cmpb $0x0, 0x7e7(%rax)
je 0x6bfb2
leaq -0xd8(%rbp), %rdi
movq %rbx, %rsi
movl -0x38(%rbp), %edx
movl $0x1, %ecx
callq 0x670a6
testb %al, %al
jne 0x6be8d
movq -0x50(%rbp), %r15
movq (%r15), %rdx
movq -0x40(%rbp), %rbx
movq %rbx, %rdi
movq %r12, %rsi
callq 0x56f95
movq (%r15), %rdx
leaq -0x90(%rbp), %rsi
movq %rbx, %rdi
callq 0x6cfa3
testl %eax, %eax
jne 0x6be8d
leaq -0x90(%rbp), %rdi
leaq -0xd8(%rbp), %r15
movq %r15, %rsi
movq -0x50(%rbp), %rdx
callq 0x6ce04
movl %eax, %ebx
movq -0x40(%rbp), %rax
movq 0x2e8(%rax), %rax
movl 0x30(%r15), %ecx
leaq (%rcx,%rcx,2), %rcx
movb $0x1, 0x10(%rax,%rcx,8)
movq %r15, %rdi
movl $0x2, %esi
movl $0x3, %edx
callq 0x59015
testb %al, %al
jne 0x6be8d
movl -0x34(%rbp), %r15d
jmp 0x6bee2
callq 0x29270
| maria_rtree_insert_req:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0D8h
mov [rbp+var_44], r9d
mov [rbp+var_48], r8d
mov [rbp+var_50], rcx
mov rbx, rdx
mov r13, rsi
mov r12, rdi
mov rax, fs:28h
mov [rbp+var_30], rax
mov eax, [rsi+10h]
mov [rbp+var_38], eax
mov rax, [rdi]
mov [rbp+var_70], rax
mov rcx, [rsi+8]
movzx eax, word ptr [rcx+0A6h]
mov [rbp+var_58], rcx
movzx esi, word ptr [rcx+0B0h]
add rsi, rax
lea rcx, [rbp+var_D8]
mov [rcx], rsi
mov rax, [rdi+78h]
mov rax, [rax]
sub rax, rcx
sub rax, rsi
jbe short loc_6BC3E
cmp rax, offset stru_10000
ja short loc_6BC2A
cmp esi, 1000h
jb short loc_6BC3E
cmp rax, 8001h
jb short loc_6BC3E
loc_6BC2A:
mov r14, rsp
add esi, 0Fh
and esi, 0FFFFFFF0h
sub r14, rsi
mov rsp, r14
mov r15b, 1
jmp short loc_6BC59
loc_6BC3E:
xor r15d, r15d
mov edx, 10010h
xor edi, edi
call my_malloc
test rax, rax
jz loc_6BE77
mov r14, rax
loc_6BC59:
lea rdi, [rbp+var_D8]
mov rsi, r12
mov rdx, [rbp+var_58]
mov rcx, rbx
mov r8d, 4
mov r9d, 3
push 0
push r14
call _ma_fetch_keypage
add rsp, 10h
test al, al
jnz loc_6BEDD
mov [rbp+var_40], r12
mov [rbp+var_34], r15d
mov eax, [rbp+var_B0]
mov esi, [rbp+var_48]
cmp esi, 0FFFFFFFFh
setz cl
test eax, eax
setnz dl
test cl, dl
jnz short loc_6BCBE
test esi, esi
sets cl
cmp esi, [rbp+var_44]
setle dl
or dl, cl
jnz loc_6BE93
loc_6BCBE:
mov [rbp+var_68], r14
mov edx, eax
mov rax, [rbp+var_D8]
mov rcx, [rbp+var_C8]
mov rax, [rax]
mov r12, rax
mov r15d, [rax+744h]
mov [rbp+var_60], rdx
add r15, rcx
add r15, rdx
mov r14d, [rbp+var_B8]
add r14, rcx
cmp r15, r14
jnb loc_6BE89
mov ecx, [r13+10h]
movsd xmm2, cs:qword_E0FC8
xor ebx, ebx
loc_6BD0A:
movsd [rbp+var_A0], xmm2
mov rdx, [r13+0]
mov rax, [r13+8]
mov rdi, [rax+0C0h]
add ecx, [r13+14h]
mov rsi, r15
lea r8, [rbp+var_90]
call maria_rtree_area_increase
ucomisd xmm0, cs:qword_E0FD0
jnz short loc_6BD44
jnp loc_6BE89
loc_6BD44:
movsd xmm1, [rbp+var_90]
test rbx, rbx
movsd xmm2, [rbp+var_A0]
jz short loc_6BD75
ucomisd xmm2, xmm0
ja short loc_6BD75
ucomisd xmm0, xmm2
jnz short loc_6BD84
jp short loc_6BD84
movsd xmm3, [rbp+var_98]
ucomisd xmm3, xmm1
jbe short loc_6BD84
loc_6BD75:
movapd xmm2, xmm0
movsd [rbp+var_98], xmm1
mov rbx, r15
loc_6BD84:
mov eax, [rbp+var_B0]
test eax, eax
jnz short loc_6BD96
mov eax, [r12+3E0h]
loc_6BD96:
mov ecx, [r13+10h]
add r15, rcx
mov eax, eax
add r15, rax
cmp r15, r14
jb loc_6BD0A
test rbx, rbx
mov r14, [rbp+var_68]
mov r15d, [rbp+var_34]
mov r12, [rbp+var_40]
jz loc_6BEDD
mov rdi, [rbp+var_60]
mov rsi, rbx
call _ma_kpos
mov r9d, [rbp+var_44]
inc r9d
mov rdi, r12
mov rsi, r13
mov rdx, rax
mov rcx, [rbp+var_50]
mov r8d, [rbp+var_48]
call maria_rtree_insert_req
cmp eax, 1
jz loc_6BF13
test eax, eax
mov r12, [rbp+var_40]
jnz loc_6BEDD
mov rax, [rbp+var_58]
mov rdi, [rax+0C0h]
mov rdx, [r13+0]
mov rsi, rbx
mov rcx, rbx
mov r8d, [rbp+var_38]
call maria_rtree_combine_rect
mov rax, [rbp+var_70]
cmp byte ptr [rax+7E7h], 0
jz short loc_6BE45
lea rdi, [rbp+var_D8]
mov rsi, rbx
mov edx, [rbp+var_38]
xor ecx, ecx
call _ma_log_change
test al, al
jnz loc_6BEDD
loc_6BE45:
mov rax, [r12+2E8h]
lea rdi, [rbp+var_D8]
mov ecx, [rdi+30h]
lea rcx, [rcx+rcx*2]
mov byte ptr [rax+rcx*8+10h], 1
mov esi, 2
mov edx, 3
call _ma_write_keypage
test al, al
jnz short loc_6BEDD
xor ebx, ebx
jmp short loc_6BEE2
loc_6BE77:
call _my_thread_var
mov dword ptr [rax], 80h
mov ebx, 0FFFFFFFFh
jmp short loc_6BEEF
loc_6BE89:
mov r14, [rbp+var_68]
loc_6BE8D:
mov r15d, [rbp+var_34]
jmp short loc_6BEDD
loc_6BE93:
lea r15, [rbp+var_D8]
mov rdi, r13
mov rsi, r15
mov rdx, [rbp+var_50]
call maria_rtree_add_key
mov ebx, eax
mov rax, [rbp+var_40]
mov rax, [rax+2E8h]
mov ecx, [r15+30h]
lea rcx, [rcx+rcx*2]
mov byte ptr [rax+rcx*8+10h], 1
mov rdi, r15
mov esi, 2
mov edx, 3
call _ma_write_keypage
test al, al
mov r15d, [rbp+var_34]
jz short loc_6BEE2
loc_6BEDD:
mov ebx, 0FFFFFFFFh
loc_6BEE2:
test r15b, r15b
jnz short loc_6BEEF
mov rdi, r14
call my_free
loc_6BEEF:
mov rax, fs:28h
cmp rax, [rbp+var_30]
jnz loc_6C039
mov eax, ebx
lea rsp, [rbp-28h]
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_6BF13:
mov rcx, [rbp+var_58]
movzx r12d, word ptr [rcx+0A6h]
add r12, r14
mov rdi, [rbp+var_60]
mov rax, rdi
add rax, r12
mov [rbp+var_88], rcx
lea r15, [rbp+var_F8]
mov [r15+8], rcx
mov [rbp+var_90], rax
mov [r15], rbx
mov eax, [r13+10h]
mov [rbp+var_80], eax
mov [r15+10h], eax
mov eax, [r13+14h]
mov [rbp+var_7C], eax
mov [r15+14h], eax
xor eax, eax
mov [rbp+var_78], eax
mov [r15+18h], eax
mov rsi, rbx
call _ma_kpos
mov rdi, [rbp+var_40]
mov rsi, r15
mov rdx, rax
call maria_rtree_set_key_mbr
test eax, eax
jnz loc_6BE8D
mov rax, [rbp+var_70]
cmp byte ptr [rax+7E7h], 0
jz short loc_6BFB2
lea rdi, [rbp+var_D8]
mov rsi, rbx
mov edx, [rbp+var_38]
mov ecx, 1
call _ma_log_change
test al, al
jnz loc_6BE8D
loc_6BFB2:
mov r15, [rbp+var_50]
mov rdx, [r15]
mov rbx, [rbp+var_40]
mov rdi, rbx
mov rsi, r12
call _ma_kpointer
mov rdx, [r15]
lea rsi, [rbp+var_90]
mov rdi, rbx
call maria_rtree_set_key_mbr
test eax, eax
jnz loc_6BE8D
lea rdi, [rbp+var_90]
lea r15, [rbp+var_D8]
mov rsi, r15
mov rdx, [rbp+var_50]
call maria_rtree_add_key
mov ebx, eax
mov rax, [rbp+var_40]
mov rax, [rax+2E8h]
mov ecx, [r15+30h]
lea rcx, [rcx+rcx*2]
mov byte ptr [rax+rcx*8+10h], 1
mov rdi, r15
mov esi, 2
mov edx, 3
call _ma_write_keypage
test al, al
jnz loc_6BE8D
mov r15d, [rbp+var_34]
jmp loc_6BEE2
loc_6C039:
call ___stack_chk_fail
| long long maria_rtree_insert_req(
long long a1,
_QWORD *a2,
unsigned long long a3,
unsigned long long *a4,
int a5,
int a6)
{
int v6; // r15d
long long v9; // rcx
long long v10; // rax
long long *v11; // rsi
unsigned long long v12; // rax
bool v13; // cc
unsigned long long v14; // rax
char *v15; // r14
long long v16; // rax
long long v17; // r12
long long v18; // r15
unsigned long long v19; // r15
unsigned long long v20; // r14
long long v21; // rcx
double v22; // xmm2_8
long long v23; // rbx
double v24; // xmm0_8
double v25; // xmm1_8
unsigned int v26; // eax
long long v27; // r12
long long v28; // rax
int inserted; // eax
long long v30; // r12
unsigned int v31; // ebx
char v32; // al
long long v34; // r12
long long v35; // rax
unsigned long long *v36; // r15
long long v37; // rbx
_QWORD v39[2]; // [rsp+8h] [rbp-F8h] BYREF
int v40; // [rsp+18h] [rbp-E8h]
int v41; // [rsp+1Ch] [rbp-E4h]
int v42; // [rsp+20h] [rbp-E0h]
long long *v43[2]; // [rsp+28h] [rbp-D8h] BYREF
long long v44; // [rsp+38h] [rbp-C8h]
unsigned int v45; // [rsp+48h] [rbp-B8h]
unsigned int v46; // [rsp+50h] [rbp-B0h]
unsigned int v47; // [rsp+58h] [rbp-A8h]
double v48; // [rsp+60h] [rbp-A0h]
double v49; // [rsp+68h] [rbp-98h]
double v50[2]; // [rsp+70h] [rbp-90h] BYREF
int v51; // [rsp+80h] [rbp-80h]
int v52; // [rsp+84h] [rbp-7Ch]
int v53; // [rsp+88h] [rbp-78h]
long long v54; // [rsp+90h] [rbp-70h]
char *v55; // [rsp+98h] [rbp-68h]
long long v56; // [rsp+A0h] [rbp-60h]
long long v57; // [rsp+A8h] [rbp-58h]
unsigned long long *v58; // [rsp+B0h] [rbp-50h]
int v59; // [rsp+B8h] [rbp-48h]
int v60; // [rsp+BCh] [rbp-44h]
long long v61; // [rsp+C0h] [rbp-40h]
unsigned int v62; // [rsp+C8h] [rbp-38h]
int v63; // [rsp+CCh] [rbp-34h]
unsigned long long v64; // [rsp+D0h] [rbp-30h]
v60 = a6;
v59 = a5;
v58 = a4;
v64 = __readfsqword(0x28u);
v62 = *((_DWORD *)a2 + 4);
v54 = *(_QWORD *)a1;
v9 = a2[1];
v10 = *(unsigned __int16 *)(v9 + 166);
v57 = v9;
v11 = (long long *)(v10 + *(unsigned __int16 *)(v9 + 176));
v43[0] = v11;
v12 = **(_QWORD **)(a1 + 120) - (_QWORD)v43;
v13 = v12 <= (unsigned long long)v11;
v14 = v12 - (_QWORD)v11;
if ( v13 || v14 <= (unsigned long long)&stru_10000 && ((unsigned int)v11 < 0x1000 || v14 < 0x8001) )
{
v6 = 0;
v16 = my_malloc(0LL, v11, 65552LL);
if ( !v16 )
{
*(_DWORD *)my_thread_var(0LL, (const char *)v11) = 128;
return (unsigned int)-1;
}
v15 = (char *)v16;
}
else
{
v15 = (char *)&v39[-1] - (((_DWORD)v11 + 15) & 0xFFFFFFF0);
LOBYTE(v6) = 1;
}
if ( !ma_fetch_keypage((long long)v43, a1, v57, a3, 4u, 3, (long long)v15) )
{
v61 = a1;
v63 = v6;
if ( (v46 == 0 || v59 != -1) && (v59 < 0 || v59 <= v60) )
{
v31 = maria_rtree_add_key(a2, v43, v58);
*(_BYTE *)(*(_QWORD *)(v61 + 744) + 24LL * v47 + 16) = 1;
v32 = ma_write_keypage(v43, 2u, 3);
LOBYTE(v6) = v63;
if ( !v32 )
goto LABEL_34;
}
else
{
v55 = v15;
v17 = *v43[0];
v18 = *(unsigned int *)(*v43[0] + 1860);
v56 = v46;
v19 = v46 + v44 + v18;
v20 = v44 + v45;
if ( v19 < v20 )
{
LODWORD(v21) = *((_DWORD *)a2 + 4);
v22 = 1.797693134862316e308;
v23 = 0LL;
while ( 1 )
{
v48 = v22;
v24 = maria_rtree_area_increase(
*(_QWORD *)(a2[1] + 192LL),
v19,
*a2,
(unsigned int)(*((_DWORD *)a2 + 5) + v21),
v50);
if ( v24 == -1.0 )
break;
v25 = v50[0];
v22 = v48;
if ( !v23 || v48 > v24 || v24 == v48 && v49 > v50[0] )
{
v22 = v24;
v49 = v50[0];
v23 = v19;
}
v26 = v46;
if ( !v46 )
v26 = *(_DWORD *)(v17 + 992);
v21 = *((unsigned int *)a2 + 4);
v19 += v26 + v21;
if ( v19 >= v20 )
{
v15 = v55;
LOBYTE(v6) = v63;
v27 = v61;
if ( !v23 )
goto LABEL_33;
v28 = ma_kpos(v56, v23);
inserted = maria_rtree_insert_req(v27, a2, v28, v58, (unsigned int)v59, (unsigned int)(v60 + 1));
if ( inserted != 1 )
{
v30 = v61;
if ( !inserted )
{
maria_rtree_combine_rect(*(_QWORD *)(v57 + 192), v23, *a2, v23, v62, v24, v25, v22);
if ( !*(_BYTE *)(v54 + 2023) || !ma_log_change((long long)v43, v23, v62) )
{
*(_BYTE *)(*(_QWORD *)(v30 + 744) + 24LL * v47 + 16) = 1;
if ( !(unsigned __int8)ma_write_keypage(v43, 2u, 3) )
{
v31 = 0;
goto LABEL_34;
}
}
}
goto LABEL_33;
}
v34 = (long long)&v15[*(unsigned __int16 *)(v57 + 166)];
*(_QWORD *)&v50[1] = v57;
v39[1] = v57;
*(_QWORD *)&v50[0] = v34 + v56;
v39[0] = v23;
v51 = *((_DWORD *)a2 + 4);
v40 = v51;
v52 = *((_DWORD *)a2 + 5);
v41 = v52;
v53 = 0;
v42 = 0;
v35 = ma_kpos(v56, v23);
if ( !(unsigned int)maria_rtree_set_key_mbr(v61, v39, v35)
&& (!*(_BYTE *)(v54 + 2023) || !ma_log_change((long long)v43, v23, v62)) )
{
v36 = v58;
v37 = v61;
ma_kpointer(v61, v34, *v58);
if ( !(unsigned int)maria_rtree_set_key_mbr(v37, v50, *v36) )
{
v31 = maria_rtree_add_key(v50, v43, v58);
*(_BYTE *)(*(_QWORD *)(v61 + 744) + 24LL * v47 + 16) = 1;
if ( !(unsigned __int8)ma_write_keypage(v43, 2u, 3) )
{
LOBYTE(v6) = v63;
goto LABEL_34;
}
}
}
goto LABEL_31;
}
}
}
v15 = v55;
LABEL_31:
LOBYTE(v6) = v63;
}
}
LABEL_33:
v31 = -1;
LABEL_34:
if ( !(_BYTE)v6 )
my_free(v15);
return v31;
}
| maria_rtree_insert_req:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xd8
MOV dword ptr [RBP + -0x44],R9D
MOV dword ptr [RBP + -0x48],R8D
MOV qword ptr [RBP + -0x50],RCX
MOV RBX,RDX
MOV R13,RSI
MOV R12,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
MOV EAX,dword ptr [RSI + 0x10]
MOV dword ptr [RBP + -0x38],EAX
MOV RAX,qword ptr [RDI]
MOV qword ptr [RBP + -0x70],RAX
MOV RCX,qword ptr [RSI + 0x8]
MOVZX EAX,word ptr [RCX + 0xa6]
MOV qword ptr [RBP + -0x58],RCX
MOVZX ESI,word ptr [RCX + 0xb0]
ADD RSI,RAX
LEA RCX,[RBP + -0xd8]
MOV qword ptr [RCX],RSI
MOV RAX,qword ptr [RDI + 0x78]
MOV RAX,qword ptr [RAX]
SUB RAX,RCX
SUB RAX,RSI
JBE 0x0016bc3e
CMP RAX,0x10000
JA 0x0016bc2a
CMP ESI,0x1000
JC 0x0016bc3e
CMP RAX,0x8001
JC 0x0016bc3e
LAB_0016bc2a:
MOV R14,RSP
ADD ESI,0xf
AND ESI,0xfffffff0
SUB R14,RSI
MOV RSP,R14
MOV R15B,0x1
JMP 0x0016bc59
LAB_0016bc3e:
XOR R15D,R15D
MOV EDX,0x10010
XOR EDI,EDI
CALL 0x0019fd89
TEST RAX,RAX
JZ 0x0016be77
MOV R14,RAX
LAB_0016bc59:
LEA RDI,[RBP + -0xd8]
MOV RSI,R12
MOV RDX,qword ptr [RBP + -0x58]
MOV RCX,RBX
MOV R8D,0x4
MOV R9D,0x3
PUSH 0x0
PUSH R14
CALL 0x00158ed6
ADD RSP,0x10
TEST AL,AL
JNZ 0x0016bedd
MOV qword ptr [RBP + -0x40],R12
MOV dword ptr [RBP + -0x34],R15D
MOV EAX,dword ptr [RBP + -0xb0]
MOV ESI,dword ptr [RBP + -0x48]
CMP ESI,-0x1
SETZ CL
TEST EAX,EAX
SETNZ DL
TEST CL,DL
JNZ 0x0016bcbe
TEST ESI,ESI
SETS CL
CMP ESI,dword ptr [RBP + -0x44]
SETLE DL
OR DL,CL
JNZ 0x0016be93
LAB_0016bcbe:
MOV qword ptr [RBP + -0x68],R14
MOV EDX,EAX
MOV RAX,qword ptr [RBP + -0xd8]
MOV RCX,qword ptr [RBP + -0xc8]
MOV RAX,qword ptr [RAX]
MOV R12,RAX
MOV R15D,dword ptr [RAX + 0x744]
MOV qword ptr [RBP + -0x60],RDX
ADD R15,RCX
ADD R15,RDX
MOV R14D,dword ptr [RBP + -0xb8]
ADD R14,RCX
CMP R15,R14
JNC 0x0016be89
MOV ECX,dword ptr [R13 + 0x10]
MOVSD XMM2,qword ptr [0x001e0fc8]
XOR EBX,EBX
LAB_0016bd0a:
MOVSD qword ptr [RBP + -0xa0],XMM2
MOV RDX,qword ptr [R13]
MOV RAX,qword ptr [R13 + 0x8]
MOV RDI,qword ptr [RAX + 0xc0]
ADD ECX,dword ptr [R13 + 0x14]
MOV RSI,R15
LEA R8,[RBP + -0x90]
CALL 0x0016e951
UCOMISD XMM0,qword ptr [0x001e0fd0]
JNZ 0x0016bd44
JNP 0x0016be89
LAB_0016bd44:
MOVSD XMM1,qword ptr [RBP + -0x90]
TEST RBX,RBX
MOVSD XMM2,qword ptr [RBP + -0xa0]
JZ 0x0016bd75
UCOMISD XMM2,XMM0
JA 0x0016bd75
UCOMISD XMM0,XMM2
JNZ 0x0016bd84
JP 0x0016bd84
MOVSD XMM3,qword ptr [RBP + -0x98]
UCOMISD XMM3,XMM1
JBE 0x0016bd84
LAB_0016bd75:
MOVAPD XMM2,XMM0
MOVSD qword ptr [RBP + -0x98],XMM1
MOV RBX,R15
LAB_0016bd84:
MOV EAX,dword ptr [RBP + -0xb0]
TEST EAX,EAX
JNZ 0x0016bd96
MOV EAX,dword ptr [R12 + 0x3e0]
LAB_0016bd96:
MOV ECX,dword ptr [R13 + 0x10]
ADD R15,RCX
MOV EAX,EAX
ADD R15,RAX
CMP R15,R14
JC 0x0016bd0a
TEST RBX,RBX
MOV R14,qword ptr [RBP + -0x68]
MOV R15D,dword ptr [RBP + -0x34]
MOV R12,qword ptr [RBP + -0x40]
JZ 0x0016bedd
MOV RDI,qword ptr [RBP + -0x60]
MOV RSI,RBX
CALL 0x00156ee7
MOV R9D,dword ptr [RBP + -0x44]
INC R9D
MOV RDI,R12
MOV RSI,R13
MOV RDX,RAX
MOV RCX,qword ptr [RBP + -0x50]
MOV R8D,dword ptr [RBP + -0x48]
CALL 0x0016bb9d
CMP EAX,0x1
JZ 0x0016bf13
TEST EAX,EAX
MOV R12,qword ptr [RBP + -0x40]
JNZ 0x0016bedd
MOV RAX,qword ptr [RBP + -0x58]
MOV RDI,qword ptr [RAX + 0xc0]
MOV RDX,qword ptr [R13]
MOV RSI,RBX
MOV RCX,RBX
MOV R8D,dword ptr [RBP + -0x38]
CALL 0x0016df51
MOV RAX,qword ptr [RBP + -0x70]
CMP byte ptr [RAX + 0x7e7],0x0
JZ 0x0016be45
LEA RDI,[RBP + -0xd8]
MOV RSI,RBX
MOV EDX,dword ptr [RBP + -0x38]
XOR ECX,ECX
CALL 0x001670a6
TEST AL,AL
JNZ 0x0016bedd
LAB_0016be45:
MOV RAX,qword ptr [R12 + 0x2e8]
LEA RDI,[RBP + -0xd8]
MOV ECX,dword ptr [RDI + 0x30]
LEA RCX,[RCX + RCX*0x2]
MOV byte ptr [RAX + RCX*0x8 + 0x10],0x1
MOV ESI,0x2
MOV EDX,0x3
CALL 0x00159015
TEST AL,AL
JNZ 0x0016bedd
XOR EBX,EBX
JMP 0x0016bee2
LAB_0016be77:
CALL 0x001a1afa
MOV dword ptr [RAX],0x80
MOV EBX,0xffffffff
JMP 0x0016beef
LAB_0016be89:
MOV R14,qword ptr [RBP + -0x68]
LAB_0016be8d:
MOV R15D,dword ptr [RBP + -0x34]
JMP 0x0016bedd
LAB_0016be93:
LEA R15,[RBP + -0xd8]
MOV RDI,R13
MOV RSI,R15
MOV RDX,qword ptr [RBP + -0x50]
CALL 0x0016ce04
MOV EBX,EAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x2e8]
MOV ECX,dword ptr [R15 + 0x30]
LEA RCX,[RCX + RCX*0x2]
MOV byte ptr [RAX + RCX*0x8 + 0x10],0x1
MOV RDI,R15
MOV ESI,0x2
MOV EDX,0x3
CALL 0x00159015
TEST AL,AL
MOV R15D,dword ptr [RBP + -0x34]
JZ 0x0016bee2
LAB_0016bedd:
MOV EBX,0xffffffff
LAB_0016bee2:
TEST R15B,R15B
JNZ 0x0016beef
MOV RDI,R14
CALL 0x0019ffb6
LAB_0016beef:
MOV RAX,qword ptr FS:[0x28]
CMP RAX,qword ptr [RBP + -0x30]
JNZ 0x0016c039
MOV EAX,EBX
LEA RSP,[RBP + -0x28]
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0016bf13:
MOV RCX,qword ptr [RBP + -0x58]
MOVZX R12D,word ptr [RCX + 0xa6]
ADD R12,R14
MOV RDI,qword ptr [RBP + -0x60]
MOV RAX,RDI
ADD RAX,R12
MOV qword ptr [RBP + -0x88],RCX
LEA R15,[RBP + -0xf8]
MOV qword ptr [R15 + 0x8],RCX
MOV qword ptr [RBP + -0x90],RAX
MOV qword ptr [R15],RBX
MOV EAX,dword ptr [R13 + 0x10]
MOV dword ptr [RBP + -0x80],EAX
MOV dword ptr [R15 + 0x10],EAX
MOV EAX,dword ptr [R13 + 0x14]
MOV dword ptr [RBP + -0x7c],EAX
MOV dword ptr [R15 + 0x14],EAX
XOR EAX,EAX
MOV dword ptr [RBP + -0x78],EAX
MOV dword ptr [R15 + 0x18],EAX
MOV RSI,RBX
CALL 0x00156ee7
MOV RDI,qword ptr [RBP + -0x40]
MOV RSI,R15
MOV RDX,RAX
CALL 0x0016cfa3
TEST EAX,EAX
JNZ 0x0016be8d
MOV RAX,qword ptr [RBP + -0x70]
CMP byte ptr [RAX + 0x7e7],0x0
JZ 0x0016bfb2
LEA RDI,[RBP + -0xd8]
MOV RSI,RBX
MOV EDX,dword ptr [RBP + -0x38]
MOV ECX,0x1
CALL 0x001670a6
TEST AL,AL
JNZ 0x0016be8d
LAB_0016bfb2:
MOV R15,qword ptr [RBP + -0x50]
MOV RDX,qword ptr [R15]
MOV RBX,qword ptr [RBP + -0x40]
MOV RDI,RBX
MOV RSI,R12
CALL 0x00156f95
MOV RDX,qword ptr [R15]
LEA RSI,[RBP + -0x90]
MOV RDI,RBX
CALL 0x0016cfa3
TEST EAX,EAX
JNZ 0x0016be8d
LEA RDI,[RBP + -0x90]
LEA R15,[RBP + -0xd8]
MOV RSI,R15
MOV RDX,qword ptr [RBP + -0x50]
CALL 0x0016ce04
MOV EBX,EAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RAX,qword ptr [RAX + 0x2e8]
MOV ECX,dword ptr [R15 + 0x30]
LEA RCX,[RCX + RCX*0x2]
MOV byte ptr [RAX + RCX*0x8 + 0x10],0x1
MOV RDI,R15
MOV ESI,0x2
MOV EDX,0x3
CALL 0x00159015
TEST AL,AL
JNZ 0x0016be8d
MOV R15D,dword ptr [RBP + -0x34]
JMP 0x0016bee2
LAB_0016c039:
CALL 0x00129270
|
int4
maria_rtree_insert_req
(long *param_1,int8 *param_2,int8 param_3,int8 *param_4,int param_5,
int param_6)
{
ushort uVar1;
long lVar2;
int8 uVar3;
ulong uVar4;
int8 *puVar5;
long *plVar6;
int1 *puVar7;
char cVar8;
char cVar9;
uint uVar10;
int iVar11;
int4 uVar12;
ulong uVar13;
int1 *puVar14;
int8 uVar15;
int4 *puVar16;
ulong uVar17;
ulong uVar18;
int1 *puVar19;
int iVar20;
int8 unaff_R15;
long in_FS_OFFSET;
double dVar21;
double dVar22;
int1 auStack_108 [8];
ulong local_100;
long local_f8;
int4 local_f0;
int4 local_ec;
int4 local_e8;
long *local_e0 [2];
long local_d0;
uint local_c0;
uint local_b8;
uint local_b0;
double local_a8;
int1 *local_a0;
int1 *local_98;
long local_90;
int4 local_88;
int4 local_84;
int4 local_80;
long local_78;
int1 *local_70;
ulong local_68;
long local_60;
int8 *local_58;
int local_50;
int local_4c;
long *local_48;
int4 local_40;
uint local_3c;
long local_38;
puVar19 = auStack_108;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
local_40 = *(int4 *)(param_2 + 2);
local_78 = *param_1;
local_60 = param_2[1];
local_e0[0] = (long *)((ulong)*(ushort *)(local_60 + 0xb0) + (ulong)*(ushort *)(local_60 + 0xa6));
uVar13 = (*(long *)param_1[0xf] - (long)local_e0) - (long)local_e0[0];
local_58 = param_4;
local_50 = param_5;
local_4c = param_6;
if ((local_e0[0] < (long *)(*(long *)param_1[0xf] - (long)local_e0)) &&
((0x10000 < uVar13 || ((0xfff < (uint)local_e0[0] && (0x8000 < uVar13)))))) {
puVar14 = auStack_108 + -(ulong)((uint)local_e0[0] + 0xf & 0xfffffff0);
uVar13 = CONCAT71((int7)((ulong)unaff_R15 >> 8),1);
puVar7 = puVar14;
}
else {
uVar13 = 0;
puVar14 = (int1 *)my_malloc(0,local_e0[0],0x10010);
puVar7 = auStack_108;
if (puVar14 == (int1 *)0x0) {
puVar16 = (int4 *)_my_thread_var();
*puVar16 = 0x80;
uVar12 = 0xffffffff;
goto LAB_0016beef;
}
}
puVar19 = puVar7;
lVar2 = local_60;
*(int8 *)(puVar19 + -8) = 0;
*(int1 **)(puVar19 + -0x10) = puVar14;
*(int8 *)(puVar19 + -0x18) = 0x16bc7f;
cVar8 = _ma_fetch_keypage(local_e0,param_1,lVar2,param_3,4,3);
puVar5 = local_58;
if (cVar8 == '\0') {
local_3c = (uint)uVar13;
local_48 = param_1;
if ((local_50 == -1 && local_b8 != 0) || (local_4c < local_50 && -1 < local_50)) {
local_68 = (ulong)local_b8;
lVar2 = *local_e0[0];
uVar13 = (ulong)*(uint *)(lVar2 + 0x744) + local_d0 + local_68;
local_70 = puVar14;
if ((ulong)local_c0 + local_d0 <= uVar13) goto LAB_0016be8d;
uVar17 = (ulong)*(uint *)(param_2 + 2);
uVar18 = 0;
dVar22 = DAT_001e0fc8;
do {
uVar15 = *param_2;
uVar3 = *(int8 *)(param_2[1] + 0xc0);
iVar11 = *(int *)((long)param_2 + 0x14);
local_a8 = dVar22;
*(int8 *)(puVar19 + -8) = 0x16bd34;
dVar21 = (double)maria_rtree_area_increase
(uVar3,uVar13,uVar15,(int)uVar17 + iVar11,&local_98);
plVar6 = local_48;
uVar4 = local_68;
puVar14 = local_70;
if ((dVar21 == DAT_001e0fd0) && (!NAN(dVar21) && !NAN(DAT_001e0fd0))) goto LAB_0016be8d;
if ((uVar18 == 0) || (dVar21 < local_a8)) {
LAB_0016bd75:
local_a0 = local_98;
uVar18 = uVar13;
dVar22 = dVar21;
}
else {
dVar22 = local_a8;
if (((dVar21 == local_a8) && (!NAN(dVar21) && !NAN(local_a8))) &&
((double)local_98 < (double)local_a0)) goto LAB_0016bd75;
}
uVar10 = local_b8;
if (local_b8 == 0) {
uVar10 = *(uint *)(lVar2 + 0x3e0);
}
uVar17 = (ulong)*(uint *)(param_2 + 2);
uVar13 = uVar13 + uVar17 + (ulong)uVar10;
} while (uVar13 < (ulong)local_c0 + local_d0);
uVar13 = (ulong)local_3c;
cVar8 = (char)local_3c;
if (uVar18 != 0) {
*(int8 *)(puVar19 + -8) = 0x16bdcc;
uVar15 = _ma_kpos(uVar4,uVar18);
iVar11 = local_50;
puVar5 = local_58;
iVar20 = local_4c + 1;
*(int8 *)(puVar19 + -8) = 0x16bde9;
iVar11 = maria_rtree_insert_req(plVar6,param_2,uVar15,puVar5,iVar11,iVar20);
uVar12 = local_40;
plVar6 = local_48;
uVar17 = local_68;
if (iVar11 == 1) {
uVar1 = *(ushort *)(local_60 + 0xa6);
local_98 = puVar14 + uVar1 + local_68;
local_90 = local_60;
local_f8 = local_60;
local_f0 = *(int4 *)(param_2 + 2);
local_ec = *(int4 *)((long)param_2 + 0x14);
local_80 = 0;
local_e8 = 0;
local_100 = uVar18;
local_88 = local_f0;
local_84 = local_ec;
*(int8 *)(puVar19 + -8) = 0x16bf6f;
uVar15 = _ma_kpos(uVar17,uVar18);
plVar6 = local_48;
*(int8 *)(puVar19 + -8) = 0x16bf7e;
iVar11 = maria_rtree_set_key_mbr(plVar6,&local_100,uVar15);
uVar12 = local_40;
if (iVar11 == 0) {
if (*(char *)(local_78 + 0x7e7) != '\0') {
*(int8 *)(puVar19 + -8) = 0x16bfaa;
cVar8 = _ma_log_change(local_e0,uVar18,uVar12,1);
if (cVar8 != '\0') goto LAB_0016be8d;
}
plVar6 = local_48;
puVar5 = local_58;
uVar15 = *local_58;
*(int8 *)(puVar19 + -8) = 0x16bfc8;
_ma_kpointer(plVar6,puVar14 + uVar1,uVar15);
uVar15 = *puVar5;
*(int8 *)(puVar19 + -8) = 0x16bfda;
iVar11 = maria_rtree_set_key_mbr(plVar6,&local_98,uVar15);
puVar5 = local_58;
if (iVar11 == 0) {
*(int8 *)(puVar19 + -8) = 0x16bffc;
uVar12 = maria_rtree_add_key(&local_98,local_e0,puVar5);
*(int1 *)(local_48[0x5d] + 0x10 + (ulong)local_b0 * 0x18) = 1;
*(int8 *)(puVar19 + -8) = 0x16c028;
cVar8 = _ma_write_keypage(local_e0,2,3);
if (cVar8 == '\0') {
cVar8 = (char)local_3c;
goto LAB_0016bee2;
}
}
}
LAB_0016be8d:
uVar13 = (ulong)local_3c;
}
else if (iVar11 == 0) {
uVar15 = *(int8 *)(local_60 + 0xc0);
uVar3 = *param_2;
*(int8 *)(puVar19 + -8) = 0x16be1c;
maria_rtree_combine_rect(uVar15,uVar18,uVar3,uVar18,uVar12);
uVar12 = local_40;
if (*(char *)(local_78 + 0x7e7) != '\0') {
*(int8 *)(puVar19 + -8) = 0x16be3d;
cVar9 = _ma_log_change(local_e0,uVar18,uVar12,0);
if (cVar9 != '\0') goto LAB_0016bedd;
}
*(int1 *)(plVar6[0x5d] + 0x10 + (ulong)local_b0 * 0x18) = 1;
*(int8 *)(puVar19 + -8) = 0x16be6f;
cVar9 = _ma_write_keypage(local_e0,2,3);
if (cVar9 == '\0') {
uVar12 = 0;
goto LAB_0016bee2;
}
}
}
goto LAB_0016bedd;
}
*(int8 *)(puVar19 + -8) = 0x16bea9;
uVar12 = maria_rtree_add_key(param_2,local_e0,puVar5);
*(int1 *)(local_48[0x5d] + 0x10 + (ulong)local_b0 * 0x18) = 1;
*(int8 *)(puVar19 + -8) = 0x16bed5;
cVar9 = _ma_write_keypage(local_e0,2,3);
uVar13 = (ulong)local_3c;
cVar8 = (char)local_3c;
if (cVar9 != '\0') goto LAB_0016bedd;
}
else {
LAB_0016bedd:
cVar8 = (char)uVar13;
uVar12 = 0xffffffff;
}
LAB_0016bee2:
if (cVar8 == '\0') {
*(int8 *)(puVar19 + -8) = 0x16beef;
my_free(puVar14);
}
LAB_0016beef:
if (*(long *)(in_FS_OFFSET + 0x28) != local_38) {
/* WARNING: Subroutine does not return */
*(code **)(puVar19 + -8) = maria_rtree_insert;
__stack_chk_fail();
}
return uVar12;
}
| |
22,157 | lf_alloc_new | eloqsql/mysys/lf_alloc-pin.c | void *lf_alloc_new(LF_PINS *pins)
{
LF_ALLOCATOR *allocator= (LF_ALLOCATOR *)(pins->pinbox->free_func_arg);
uchar *node;
for (;;)
{
do
{
node= allocator->top;
lf_pin(pins, 0, node);
} while (node != allocator->top && LF_BACKOFF());
if (!node)
{
node= (void *)my_malloc(key_memory_lf_node, allocator->element_size,
MYF(MY_WME));
if (allocator->constructor)
allocator->constructor(node);
#ifdef MY_LF_EXTRA_DEBUG
if (likely(node != 0))
my_atomic_add32(&allocator->mallocs, 1);
#endif
break;
}
if (my_atomic_casptr((void **)(char *)&allocator->top,
(void *)&node, anext_node(node)))
break;
}
lf_unpin(pins, 0);
return node;
} | O3 | c | lf_alloc_new:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x20(%rdi), %rax
movq 0x30(%rax), %r15
leaq 0x2e1bb9(%rip), %rcx # 0x38c3d0
movq 0x48(%r15), %r14
movq %r14, %rax
xchgq %rax, (%rbx)
cmpq 0x48(%r15), %r14
je 0xaa835
movl (%rcx), %eax
testl %eax, %eax
je 0xaa817
pause
decl %eax
jne 0xaa82d
jmp 0xaa817
testq %r14, %r14
je 0xaa84f
movl 0x38(%r15), %eax
movq (%r14,%rax), %rdx
movq %r14, %rax
lock
cmpxchgq %rdx, 0x48(%r15)
jne 0xaa817
jmp 0xaa877
leaq 0xb63f1a(%rip), %rax # 0xc0e770
movl (%rax), %edi
movl 0x50(%r15), %esi
movl $0x10, %edx
callq 0xa46f9
movq %rax, %r14
movq 0x58(%r15), %rax
testq %rax, %rax
je 0xaa877
movq %r14, %rdi
callq *%rax
xorl %eax, %eax
xchgq %rax, (%rbx)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| lf_alloc_new:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov rbx, rdi
mov rax, [rdi+20h]
mov r15, [rax+30h]
lea rcx, my_cpu_relax_multiplier
loc_AA817:
mov r14, [r15+48h]
mov rax, r14
xchg rax, [rbx]
cmp r14, [r15+48h]
jz short loc_AA835
mov eax, [rcx]
test eax, eax
jz short loc_AA817
loc_AA82D:
pause
dec eax
jnz short loc_AA82D
jmp short loc_AA817
loc_AA835:
test r14, r14
jz short loc_AA84F
mov eax, [r15+38h]
mov rdx, [r14+rax]
mov rax, r14
lock cmpxchg [r15+48h], rdx
jnz short loc_AA817
jmp short loc_AA877
loc_AA84F:
lea rax, key_memory_lf_node
mov edi, [rax]
mov esi, [r15+50h]
mov edx, 10h
call my_malloc
mov r14, rax
mov rax, [r15+58h]
test rax, rax
jz short loc_AA877
mov rdi, r14
call rax
loc_AA877:
xor eax, eax
xchg rax, [rbx]
mov rax, r14
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
| long long lf_alloc_new(long long a1)
{
long long v1; // r15
long long v2; // r14
int i; // eax
void ( *v4)(long long); // rax
v1 = *(_QWORD *)(*(_QWORD *)(a1 + 32) + 48LL);
while ( 1 )
{
while ( 1 )
{
v2 = *(_QWORD *)(v1 + 72);
_InterlockedExchange64((volatile long long *)a1, v2);
if ( v2 == *(_QWORD *)(v1 + 72) )
break;
for ( i = my_cpu_relax_multiplier; i; --i )
_mm_pause();
}
if ( !v2 )
break;
if ( v2 == _InterlockedCompareExchange64(
(volatile signed long long *)(v1 + 72),
*(_QWORD *)(v2 + *(unsigned int *)(v1 + 56)),
v2) )
goto LABEL_11;
}
v2 = my_malloc(key_memory_lf_node, (const char *)*(unsigned int *)(v1 + 80), 16);
v4 = *(void ( **)(long long))(v1 + 88);
if ( v4 )
v4(v2);
LABEL_11:
_InterlockedExchange64((volatile long long *)a1, 0LL);
return v2;
}
| lf_alloc_new:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV RAX,qword ptr [RDI + 0x20]
MOV R15,qword ptr [RAX + 0x30]
LEA RCX,[0x48c3d0]
LAB_001aa817:
MOV R14,qword ptr [R15 + 0x48]
MOV RAX,R14
XCHG qword ptr [RBX],RAX
CMP R14,qword ptr [R15 + 0x48]
JZ 0x001aa835
MOV EAX,dword ptr [RCX]
TEST EAX,EAX
JZ 0x001aa817
LAB_001aa82d:
PAUSE
DEC EAX
JNZ 0x001aa82d
JMP 0x001aa817
LAB_001aa835:
TEST R14,R14
JZ 0x001aa84f
MOV EAX,dword ptr [R15 + 0x38]
MOV RDX,qword ptr [R14 + RAX*0x1]
MOV RAX,R14
CMPXCHG.LOCK qword ptr [R15 + 0x48],RDX
JNZ 0x001aa817
JMP 0x001aa877
LAB_001aa84f:
LEA RAX,[0xd0e770]
MOV EDI,dword ptr [RAX]
MOV ESI,dword ptr [R15 + 0x50]
MOV EDX,0x10
CALL 0x001a46f9
MOV R14,RAX
MOV RAX,qword ptr [R15 + 0x58]
TEST RAX,RAX
JZ 0x001aa877
MOV RDI,R14
CALL RAX
LAB_001aa877:
XOR EAX,EAX
XCHG qword ptr [RBX],RAX
MOV RAX,R14
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
|
long lf_alloc_new(long *param_1)
{
long lVar1;
int iVar2;
long lVar3;
bool bVar4;
lVar1 = *(long *)(param_1[4] + 0x30);
do {
while( true ) {
lVar3 = *(long *)(lVar1 + 0x48);
LOCK();
*param_1 = lVar3;
UNLOCK();
iVar2 = my_cpu_relax_multiplier;
if (lVar3 == *(long *)(lVar1 + 0x48)) break;
for (; iVar2 != 0; iVar2 = iVar2 + -1) {
}
}
if (lVar3 == 0) {
lVar3 = my_malloc(key_memory_lf_node,*(int4 *)(lVar1 + 0x50),0x10);
if (*(code **)(lVar1 + 0x58) != (code *)0x0) {
(**(code **)(lVar1 + 0x58))(lVar3);
}
break;
}
LOCK();
bVar4 = lVar3 == *(long *)(lVar1 + 0x48);
if (bVar4) {
*(long *)(lVar1 + 0x48) = *(long *)(lVar3 + (ulong)*(uint *)(lVar1 + 0x38));
}
UNLOCK();
} while (!bVar4);
LOCK();
*param_1 = 0;
UNLOCK();
return lVar3;
}
| |
22,158 | ma_init_dynamic_array | eloqsql/libmariadb/libmariadb/ma_array.c | my_bool ma_init_dynamic_array(DYNAMIC_ARRAY *array, uint element_size,
uint init_alloc, uint alloc_increment CALLER_INFO_PROTO)
{
if (!alloc_increment)
{
alloc_increment=max((8192-MALLOC_OVERHEAD)/element_size,16);
if (init_alloc > 8 && alloc_increment > init_alloc * 2)
alloc_increment=init_alloc*2;
}
if (!init_alloc)
init_alloc=alloc_increment;
array->elements=0;
array->max_element=init_alloc;
array->alloc_increment=alloc_increment;
array->size_of_element=element_size;
if (!(array->buffer=(char*) malloc(element_size*init_alloc)))
{
array->max_element=0;
return(TRUE);
}
return(FALSE);
} | O3 | c | ma_init_dynamic_array:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %edx, %r8d
movq %rdi, %rbx
testl %ecx, %ecx
jne 0x33238
movl $0x10, %ecx
cmpl $0x1e1, %esi # imm = 0x1E1
ja 0x33229
movw $0x1ff8, %ax # imm = 0x1FF8
xorl %edx, %edx
divw %si
movzwl %ax, %ecx
cmpl $0x9, %r8d
jb 0x33238
leal (%r8,%r8), %eax
cmpl %eax, %ecx
cmovael %eax, %ecx
testl %r8d, %r8d
cmovel %ecx, %r8d
movl $0x0, 0x8(%rbx)
movl %r8d, 0xc(%rbx)
movl %ecx, 0x10(%rbx)
movl %esi, 0x14(%rbx)
imull %esi, %r8d
movq %r8, %rdi
callq 0x13600
movq %rax, (%rbx)
testq %rax, %rax
je 0x33268
xorl %eax, %eax
jmp 0x33271
movl $0x0, 0xc(%rbx)
movb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| ma_init_dynamic_array:
push rbp
mov rbp, rsp
push rbx
push rax
mov r8d, edx
mov rbx, rdi
test ecx, ecx
jnz short loc_33238
mov ecx, 10h
cmp esi, 1E1h
ja short loc_33229
mov ax, 1FF8h
xor edx, edx
div si
movzx ecx, ax
loc_33229:
cmp r8d, 9
jb short loc_33238
lea eax, [r8+r8]
cmp ecx, eax
cmovnb ecx, eax
loc_33238:
test r8d, r8d
cmovz r8d, ecx
mov dword ptr [rbx+8], 0
mov [rbx+0Ch], r8d
mov [rbx+10h], ecx
mov [rbx+14h], esi
imul r8d, esi
mov rdi, r8
call _malloc
mov [rbx], rax
test rax, rax
jz short loc_33268
xor eax, eax
jmp short loc_33271
loc_33268:
mov dword ptr [rbx+0Ch], 0
mov al, 1
loc_33271:
add rsp, 8
pop rbx
pop rbp
retn
| long long ma_init_dynamic_array(long long a1, unsigned int a2, unsigned int a3, unsigned int a4)
{
unsigned int v4; // r8d
long long v5; // rax
v4 = a3;
if ( !a4 )
{
a4 = 16;
if ( a2 <= 0x1E1 )
a4 = 0x1FF8u / (unsigned __int16)a2;
if ( a3 >= 9 && a4 >= 2 * a3 )
a4 = 2 * a3;
}
if ( !a3 )
v4 = a4;
*(_DWORD *)(a1 + 8) = 0;
*(_DWORD *)(a1 + 12) = v4;
*(_DWORD *)(a1 + 16) = a4;
*(_DWORD *)(a1 + 20) = a2;
v5 = malloc(a2 * v4);
*(_QWORD *)a1 = v5;
if ( v5 )
return 0LL;
*(_DWORD *)(a1 + 12) = 0;
return 1LL;
}
| ma_init_dynamic_array:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV R8D,EDX
MOV RBX,RDI
TEST ECX,ECX
JNZ 0x00133238
MOV ECX,0x10
CMP ESI,0x1e1
JA 0x00133229
MOV AX,0x1ff8
XOR EDX,EDX
DIV SI
MOVZX ECX,AX
LAB_00133229:
CMP R8D,0x9
JC 0x00133238
LEA EAX,[R8 + R8*0x1]
CMP ECX,EAX
CMOVNC ECX,EAX
LAB_00133238:
TEST R8D,R8D
CMOVZ R8D,ECX
MOV dword ptr [RBX + 0x8],0x0
MOV dword ptr [RBX + 0xc],R8D
MOV dword ptr [RBX + 0x10],ECX
MOV dword ptr [RBX + 0x14],ESI
IMUL R8D,ESI
MOV RDI,R8
CALL 0x00113600
MOV qword ptr [RBX],RAX
TEST RAX,RAX
JZ 0x00133268
XOR EAX,EAX
JMP 0x00133271
LAB_00133268:
MOV dword ptr [RBX + 0xc],0x0
MOV AL,0x1
LAB_00133271:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
bool ma_init_dynamic_array(int8 *param_1,uint param_2,uint param_3,uint param_4)
{
void *pvVar1;
if (param_4 == 0) {
param_4 = 0x10;
if (param_2 < 0x1e2) {
param_4 = 0x1ff8 / (param_2 & 0xffff);
}
if ((8 < param_3) && (param_3 * 2 <= param_4)) {
param_4 = param_3 * 2;
}
}
if (param_3 == 0) {
param_3 = param_4;
}
*(int4 *)(param_1 + 1) = 0;
*(uint *)((long)param_1 + 0xc) = param_3;
*(uint *)(param_1 + 2) = param_4;
*(uint *)((long)param_1 + 0x14) = param_2;
pvVar1 = malloc((ulong)(param_3 * param_2));
*param_1 = pvVar1;
if (pvVar1 == (void *)0x0) {
*(int4 *)((long)param_1 + 0xc) = 0;
}
return pvVar1 == (void *)0x0;
}
| |
22,159 | 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>>::end_object() | monkey531[P]llama/common/json.hpp | bool end_object()
{
JSON_ASSERT(!ref_stack.empty());
JSON_ASSERT(ref_stack.back()->is_object());
ref_stack.back()->set_parents();
ref_stack.pop_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>>::end_object():
pushq %rax
movq 0x10(%rdi), %rax
cmpq %rax, 0x8(%rdi)
je 0x452c6
movq -0x8(%rax), %rcx
cmpb $0x1, (%rcx)
jne 0x452e2
addq $-0x8, %rax
movq %rax, 0x10(%rdi)
movb $0x1, %al
popq %rcx
retq
leaq 0x6c919(%rip), %rdi # 0xb1be6
leaq 0x66e6c(%rip), %rdx # 0xac140
leaq 0x6d905(%rip), %rcx # 0xb2be0
movl $0x1aeb, %esi # imm = 0x1AEB
jmp 0x452fc
leaq 0x6c8fd(%rip), %rdi # 0xb1be6
leaq 0x66e50(%rip), %rdx # 0xac140
leaq 0x6d897(%rip), %rcx # 0xb2b8e
movl $0x1aec, %esi # imm = 0x1AEC
xorl %eax, %eax
callq 0x24e90
nop
| _ZN8nlohmann16json_abi_v3_11_36detail19json_sax_dom_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE10end_objectEv:
push rax
mov rax, [rdi+10h]
cmp [rdi+8], rax
jz short loc_452C6
mov rcx, [rax-8]
cmp byte ptr [rcx], 1
jnz short loc_452E2
add rax, 0FFFFFFFFFFFFFFF8h
mov [rdi+10h], rax
mov al, 1
pop rcx
retn
loc_452C6:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aRefStackEmpty; "!ref_stack.empty()"
mov esi, 1AEBh
jmp short loc_452FC
loc_452E2:
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aRefStackBackIs+20h; "ref_stack.back()->is_object()"
mov esi, 1AECh
loc_452FC:
xor eax, eax
call _ggml_abort
nop
| 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>>::end_object(
long long a1)
{
long long v1; // rax
long long v3; // rsi
v1 = *(_QWORD *)(a1 + 16);
if ( *(_QWORD *)(a1 + 8) == v1 )
{
v3 = 6891LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
6891LL,
"GGML_ASSERT(%s) failed",
"!ref_stack.empty()");
}
else
{
if ( **(_BYTE **)(v1 - 8) == 1 )
{
*(_QWORD *)(a1 + 16) = v1 - 8;
return 1;
}
v3 = 6892LL;
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
6892LL,
"GGML_ASSERT(%s) failed",
"ref_stack.back()->is_object()");
}
return 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>>::key(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",
v3);
}
| end_object:
PUSH RAX
MOV RAX,qword ptr [RDI + 0x10]
CMP qword ptr [RDI + 0x8],RAX
JZ 0x001452c6
MOV RCX,qword ptr [RAX + -0x8]
CMP byte ptr [RCX],0x1
JNZ 0x001452e2
ADD RAX,-0x8
MOV qword ptr [RDI + 0x10],RAX
MOV AL,0x1
POP RCX
RET
LAB_001452c6:
LEA RDI,[0x1b1be6]
LEA RDX,[0x1ac140]
LEA RCX,[0x1b2be0]
MOV ESI,0x1aeb
JMP 0x001452fc
LAB_001452e2:
LEA RDI,[0x1b1be6]
LEA RDX,[0x1ac140]
LEA RCX,[0x1b2b8e]
MOV ESI,0x1aec
LAB_001452fc:
XOR EAX,EAX
CALL 0x00124e90
|
/* 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> >::end_object() */
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>>
::end_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)
{
long lVar1;
char *pcVar2;
int8 uVar3;
lVar1 = *(long *)(this + 0x10);
if (*(long *)(this + 8) == lVar1) {
pcVar2 = "!ref_stack.empty()";
uVar3 = 0x1aeb;
}
else {
if (**(char **)(lVar1 + -8) == '\x01') {
*(long *)(this + 0x10) = lVar1 + -8;
return CONCAT71((int7)((ulong)(lVar1 + -8) >> 8),1);
}
pcVar2 = "ref_stack.back()->is_object()";
uVar3 = 0x1aec;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
| |
22,160 | mi_search_last | eloqsql/storage/myisam/mi_search.c | int _mi_search_last(register MI_INFO *info, register MI_KEYDEF *keyinfo,
register my_off_t pos)
{
uint nod_flag;
uchar *buff,*page;
DBUG_ENTER("_mi_search_last");
if (pos == HA_OFFSET_ERROR)
{
my_errno=HA_ERR_KEY_NOT_FOUND; /* Didn't find key */
info->lastpos= HA_OFFSET_ERROR;
DBUG_RETURN(-1);
}
buff=info->buff;
do
{
if (!_mi_fetch_keypage(info,keyinfo,pos,DFLT_INIT_HITS,buff,0))
{
info->lastpos= HA_OFFSET_ERROR;
DBUG_RETURN(-1);
}
page= buff+mi_getint(buff);
nod_flag=mi_test_if_nod(buff);
} while ((pos=_mi_kpos(nod_flag,page)) != HA_OFFSET_ERROR);
if (!_mi_get_last_key(info,keyinfo,buff,info->lastkey,page,
&info->lastkey_length))
DBUG_RETURN(-1);
info->lastpos=_mi_dpos(info,0,info->lastkey+info->lastkey_length);
info->int_keypos=info->int_maxpos=page;
info->int_nod_flag=nod_flag;
info->int_keytree_version=keyinfo->version;
info->last_search_keypage=info->last_keypage;
info->page_changed=info->buff_used=0;
DBUG_PRINT("exit",("found key at %lu",(ulong) info->lastpos));
DBUG_RETURN(0);
} | O0 | c | mi_search_last:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
cmpq $-0x1, -0x20(%rbp)
jne 0xc2581
callq 0xf60c0
movl $0x78, (%rax)
movq -0x10(%rbp), %rax
movq $-0x1, 0x170(%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xc2727
movq -0x10(%rbp), %rax
movq 0x100(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
movq -0x30(%rbp), %r8
movl $0x3, %ecx
xorl %r9d, %r9d
callq 0xbe050
cmpq $0x0, %rax
jne 0xc25ce
movq -0x10(%rbp), %rax
movq $-0x1, 0x170(%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xc2727
movq -0x30(%rbp), %rax
movq -0x30(%rbp), %rcx
movzbl 0x1(%rcx), %ecx
movzwl %cx, %ecx
movq -0x30(%rbp), %rdx
movzbl (%rdx), %edx
movzwl %dx, %edx
shll $0x8, %edx
orl %edx, %ecx
movzwl %cx, %ecx
andl $0x7fff, %ecx # imm = 0x7FFF
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rax
movzbl (%rax), %eax
andl $0x80, %eax
cmpl $0x0, %eax
je 0xc2621
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl 0x17c(%rax), %eax
movl %eax, -0x3c(%rbp)
jmp 0xc2628
xorl %eax, %eax
movl %eax, -0x3c(%rbp)
jmp 0xc2628
movl -0x3c(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %edi
movq -0x38(%rbp), %rsi
callq 0xbefc0
movq %rax, -0x20(%rbp)
cmpq $-0x1, %rax
jne 0xc2590
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x30(%rbp), %rdx
movq -0x10(%rbp), %rax
movq 0x108(%rax), %rcx
movq -0x38(%rbp), %r8
movq -0x10(%rbp), %r9
addq $0x1d8, %r9 # imm = 0x1D8
callq 0xc19e0
cmpq $0x0, %rax
jne 0xc2687
jmp 0xc267b
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xc2727
movq -0x10(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x108(%rax), %rdx
movq -0x10(%rbp), %rax
movl 0x1d8(%rax), %eax
addq %rax, %rdx
xorl %esi, %esi
callq 0xbf240
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x170(%rax)
movq -0x38(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x130(%rax)
movq -0x10(%rbp), %rax
movq %rcx, 0x128(%rax)
movl -0x24(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x138(%rax)
movq -0x18(%rbp), %rax
movl 0x1c(%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x13c(%rax)
movq -0x10(%rbp), %rax
movq 0x190(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x198(%rax)
movq -0x10(%rbp), %rax
movb $0x0, 0x33d(%rax)
movq -0x10(%rbp), %rax
movb $0x0, 0x33c(%rax)
jmp 0xc271e
jmp 0xc2720
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
| _mi_search_last:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
cmp [rbp+var_20], 0FFFFFFFFFFFFFFFFh
jnz short loc_C2581
call _my_thread_var
mov dword ptr [rax], 78h ; 'x'
mov rax, [rbp+var_10]
mov qword ptr [rax+170h], 0FFFFFFFFFFFFFFFFh
mov [rbp+var_4], 0FFFFFFFFh
jmp loc_C2727
loc_C2581:
mov rax, [rbp+var_10]
mov rax, [rax+100h]
mov [rbp+var_30], rax
loc_C2590:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_20]
mov r8, [rbp+var_30]
mov ecx, 3
xor r9d, r9d
call _mi_fetch_keypage
cmp rax, 0
jnz short loc_C25CE
mov rax, [rbp+var_10]
mov qword ptr [rax+170h], 0FFFFFFFFFFFFFFFFh
mov [rbp+var_4], 0FFFFFFFFh
jmp loc_C2727
loc_C25CE:
mov rax, [rbp+var_30]
mov rcx, [rbp+var_30]
movzx ecx, byte ptr [rcx+1]
movzx ecx, cx
mov rdx, [rbp+var_30]
movzx edx, byte ptr [rdx]
movzx edx, dx
shl edx, 8
or ecx, edx
movzx ecx, cx
and ecx, 7FFFh
mov ecx, ecx
add rax, rcx
mov [rbp+var_38], rax
mov rax, [rbp+var_30]
movzx eax, byte ptr [rax]
and eax, 80h
cmp eax, 0
jz short loc_C2621
mov rax, [rbp+var_10]
mov rax, [rax]
mov eax, [rax+17Ch]
mov [rbp+var_3C], eax
jmp short loc_C2628
loc_C2621:
xor eax, eax
mov [rbp+var_3C], eax
jmp short $+2
loc_C2628:
mov eax, [rbp+var_3C]
mov [rbp+var_24], eax
mov edi, [rbp+var_24]
mov rsi, [rbp+var_38]
call _mi_kpos
mov [rbp+var_20], rax
cmp rax, 0FFFFFFFFFFFFFFFFh
jnz loc_C2590
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_30]
mov rax, [rbp+var_10]
mov rcx, [rax+108h]
mov r8, [rbp+var_38]
mov r9, [rbp+var_10]
add r9, 1D8h
call _mi_get_last_key
cmp rax, 0
jnz short loc_C2687
jmp short $+2
loc_C267B:
mov [rbp+var_4], 0FFFFFFFFh
jmp loc_C2727
loc_C2687:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_10]
mov rdx, [rax+108h]
mov rax, [rbp+var_10]
mov eax, [rax+1D8h]
add rdx, rax
xor esi, esi
call _mi_dpos
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+170h], rcx
mov rcx, [rbp+var_38]
mov rax, [rbp+var_10]
mov [rax+130h], rcx
mov rax, [rbp+var_10]
mov [rax+128h], rcx
mov ecx, [rbp+var_24]
mov rax, [rbp+var_10]
mov [rax+138h], ecx
mov rax, [rbp+var_18]
mov ecx, [rax+1Ch]
mov rax, [rbp+var_10]
mov [rax+13Ch], ecx
mov rax, [rbp+var_10]
mov rcx, [rax+190h]
mov rax, [rbp+var_10]
mov [rax+198h], rcx
mov rax, [rbp+var_10]
mov byte ptr [rax+33Dh], 0
mov rax, [rbp+var_10]
mov byte ptr [rax+33Ch], 0
jmp short $+2
loc_C271E:
jmp short $+2
loc_C2720:
mov [rbp+var_4], 0
loc_C2727:
mov eax, [rbp+var_4]
add rsp, 40h
pop rbp
retn
| long long mi_search_last(long long a1, long long a2, long long a3)
{
unsigned int v4; // [rsp+4h] [rbp-3Ch]
unsigned long long v5; // [rsp+8h] [rbp-38h]
unsigned __int16 *v6; // [rsp+10h] [rbp-30h]
long long v7; // [rsp+20h] [rbp-20h]
v7 = a3;
if ( a3 == -1 )
{
*(_DWORD *)my_thread_var(a1, (const char *)a2) = 120;
*(_QWORD *)(a1 + 368) = -1LL;
return (unsigned int)-1;
}
else
{
v6 = *(unsigned __int16 **)(a1 + 256);
do
{
if ( !mi_fetch_keypage((_QWORD *)a1, a2, v7, 3, (int)v6, 0) )
{
*(_QWORD *)(a1 + 368) = -1LL;
return (unsigned int)-1;
}
v5 = (unsigned long long)v6 + (_byteswap_ushort(*v6) & 0x7FFF);
if ( (*(_BYTE *)v6 & 0x80) != 0 )
v4 = *(_DWORD *)(*(_QWORD *)a1 + 380LL);
else
v4 = 0;
v7 = mi_kpos(v4, v5);
}
while ( v7 != -1 );
if ( mi_get_last_key(a1, a2, v6, *(_BYTE **)(a1 + 264), v5, (_DWORD *)(a1 + 472)) )
{
*(_QWORD *)(a1 + 368) = mi_dpos(a1, 0, *(unsigned int *)(a1 + 472) + *(_QWORD *)(a1 + 264));
*(_QWORD *)(a1 + 304) = v5;
*(_QWORD *)(a1 + 296) = v5;
*(_DWORD *)(a1 + 312) = v4;
*(_DWORD *)(a1 + 316) = *(_DWORD *)(a2 + 28);
*(_QWORD *)(a1 + 408) = *(_QWORD *)(a1 + 400);
*(_BYTE *)(a1 + 829) = 0;
*(_BYTE *)(a1 + 828) = 0;
return 0;
}
else
{
return (unsigned int)-1;
}
}
}
| _mi_search_last:
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
CMP qword ptr [RBP + -0x20],-0x1
JNZ 0x001c2581
CALL 0x001f60c0
MOV dword ptr [RAX],0x78
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x170],-0x1
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x001c2727
LAB_001c2581:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x100]
MOV qword ptr [RBP + -0x30],RAX
LAB_001c2590:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
MOV R8,qword ptr [RBP + -0x30]
MOV ECX,0x3
XOR R9D,R9D
CALL 0x001be050
CMP RAX,0x0
JNZ 0x001c25ce
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x170],-0x1
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x001c2727
LAB_001c25ce:
MOV RAX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RBP + -0x30]
MOVZX ECX,byte ptr [RCX + 0x1]
MOVZX ECX,CX
MOV RDX,qword ptr [RBP + -0x30]
MOVZX EDX,byte ptr [RDX]
MOVZX EDX,DX
SHL EDX,0x8
OR ECX,EDX
MOVZX ECX,CX
AND ECX,0x7fff
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOVZX EAX,byte ptr [RAX]
AND EAX,0x80
CMP EAX,0x0
JZ 0x001c2621
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX + 0x17c]
MOV dword ptr [RBP + -0x3c],EAX
JMP 0x001c2628
LAB_001c2621:
XOR EAX,EAX
MOV dword ptr [RBP + -0x3c],EAX
JMP 0x001c2628
LAB_001c2628:
MOV EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0x24],EAX
MOV EDI,dword ptr [RBP + -0x24]
MOV RSI,qword ptr [RBP + -0x38]
CALL 0x001befc0
MOV qword ptr [RBP + -0x20],RAX
CMP RAX,-0x1
JNZ 0x001c2590
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x108]
MOV R8,qword ptr [RBP + -0x38]
MOV R9,qword ptr [RBP + -0x10]
ADD R9,0x1d8
CALL 0x001c19e0
CMP RAX,0x0
JNZ 0x001c2687
JMP 0x001c267b
LAB_001c267b:
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x001c2727
LAB_001c2687:
MOV RDI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RAX + 0x108]
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x1d8]
ADD RDX,RAX
XOR ESI,ESI
CALL 0x001bf240
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x170],RCX
MOV RCX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x130],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x128],RCX
MOV ECX,dword ptr [RBP + -0x24]
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x138],ECX
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,dword ptr [RAX + 0x1c]
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x13c],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x190]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x198],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x33d],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x33c],0x0
JMP 0x001c271e
LAB_001c271e:
JMP 0x001c2720
LAB_001c2720:
MOV dword ptr [RBP + -0x4],0x0
LAB_001c2727:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x40
POP RBP
RET
|
int4 _mi_search_last(long *param_1,long param_2,long param_3)
{
byte *pbVar1;
int4 *puVar2;
long lVar3;
byte *pbVar4;
int4 local_44;
long local_28;
int4 local_c;
if (param_3 == -1) {
puVar2 = (int4 *)_my_thread_var();
*puVar2 = 0x78;
param_1[0x2e] = -1;
local_c = 0xffffffff;
}
else {
pbVar1 = (byte *)param_1[0x20];
local_28 = param_3;
do {
lVar3 = _mi_fetch_keypage(param_1,param_2,local_28,3,pbVar1,0);
if (lVar3 == 0) {
param_1[0x2e] = -1;
return 0xffffffff;
}
pbVar4 = pbVar1 + ((uint)pbVar1[1] | (*pbVar1 & 0x7f) << 8);
if ((*pbVar1 & 0x80) == 0) {
local_44 = 0;
}
else {
local_44 = *(int4 *)(*param_1 + 0x17c);
}
local_28 = _mi_kpos(local_44,pbVar4);
} while (local_28 != -1);
lVar3 = _mi_get_last_key(param_1,param_2,pbVar1,param_1[0x21],pbVar4,param_1 + 0x3b);
if (lVar3 == 0) {
local_c = 0xffffffff;
}
else {
lVar3 = _mi_dpos(param_1,0,param_1[0x21] + (ulong)*(uint *)(param_1 + 0x3b));
param_1[0x2e] = lVar3;
param_1[0x26] = (long)pbVar4;
param_1[0x25] = (long)pbVar4;
*(int4 *)(param_1 + 0x27) = local_44;
*(int4 *)((long)param_1 + 0x13c) = *(int4 *)(param_2 + 0x1c);
param_1[0x33] = param_1[0x32];
*(int1 *)((long)param_1 + 0x33d) = 0;
*(int1 *)((long)param_1 + 0x33c) = 0;
local_c = 0;
}
}
return local_c;
}
| |
22,161 | nlohmann::json_abi_v3_11_3::ordered_map<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>, minja::Value, std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, std::allocator<std::pair<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, minja::Value>>>::count(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 | monkey531[P]llama/common/json.hpp | size_type count(const key_type& key) const
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return 1;
}
}
return 0;
} | O2 | cpp | nlohmann::json_abi_v3_11_3::ordered_map<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>, minja::Value, std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, std::allocator<std::pair<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, minja::Value>>>::count(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 %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq (%rdi), %rcx
movq %rcx, %r15
movq 0x8(%r14), %r12
cmpq %r12, %rcx
je 0x6fc3a
movq %r15, %rdi
movq %rbx, %rsi
callq 0x69902
leaq 0x60(%r15), %rcx
testb %al, %al
je 0x6fc1b
xorl %eax, %eax
cmpq %r12, %r15
setne %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
| _ZNK8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE5countERSJ_:
push r15
push r14
push r12
push rbx
push rax
mov rbx, rsi
mov r14, rdi
mov rcx, [rdi]
loc_6FC1B:
mov r15, rcx
mov r12, [r14+8]
cmp rcx, r12
jz short loc_6FC3A
mov rdi, r15
mov rsi, rbx
call _ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_; nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
lea rcx, [r15+60h]
test al, al
jz short loc_6FC1B
loc_6FC3A:
xor eax, eax
cmp r15, r12
setnz al
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
| _BOOL8 nlohmann::json_abi_v3_11_3::ordered_map<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>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<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,minja::Value>>>::count(
unsigned __int8 **a1,
unsigned __int8 *a2,
__m128d a3)
{
unsigned __int8 *v3; // rcx
unsigned __int8 *v4; // r15
unsigned __int8 *v5; // r12
char v6; // al
v3 = *a1;
do
{
v4 = v3;
v5 = a1[1];
if ( v3 == v5 )
break;
v6 = nlohmann::json_abi_v3_11_3::operator==(v3, a2, a3);
v3 = v4 + 96;
}
while ( !v6 );
return v4 != v5;
}
| count:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV R14,RDI
MOV RCX,qword ptr [RDI]
LAB_0016fc1b:
MOV R15,RCX
MOV R12,qword ptr [R14 + 0x8]
CMP RCX,R12
JZ 0x0016fc3a
MOV RDI,R15
MOV RSI,RBX
CALL 0x00169902
LEA RCX,[R15 + 0x60]
TEST AL,AL
JZ 0x0016fc1b
LAB_0016fc3a:
XOR EAX,EAX
CMP R15,R12
SETNZ AL
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
|
/* nlohmann::json_abi_v3_11_3::ordered_map<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>, minja::Value,
std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >,
std::allocator<std::pair<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, minja::Value> >
>::count(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 */
bool __thiscall
nlohmann::json_abi_v3_11_3::
ordered_map<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>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<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,minja::Value>>>
::count(ordered_map<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>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<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,minja::Value>>>
*this,basic_json *param_1)
{
basic_json *pbVar1;
basic_json *pbVar2;
char cVar3;
basic_json *pbVar4;
pbVar2 = *(basic_json **)this;
do {
pbVar4 = pbVar2;
pbVar1 = *(basic_json **)(this + 8);
if (pbVar4 == pbVar1) break;
cVar3 = json_abi_v3_11_3::operator==(pbVar4,param_1);
pbVar2 = pbVar4 + 0x60;
} while (cVar3 == '\0');
return pbVar4 != pbVar1;
}
| |
22,162 | int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker, fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>>(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>) | aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h | FMT_CONSTEXPR auto get_dynamic_spec(FormatArg arg) -> int {
unsigned long long value = visit_format_arg(Handler(), arg);
if (value > to_unsigned(max_value<int>()))
throw_format_error("number is too big");
return static_cast<int>(value);
} | O0 | c | int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker, fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>>(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>):
subq $0x108, %rsp # imm = 0x108
leaq 0x110(%rsp), %rax
leaq 0x4f(%rsp), %rcx
movq %rcx, 0xf8(%rsp)
movq %rax, 0xf0(%rsp)
movq 0xf0(%rsp), %rax
movl 0x10(%rax), %eax
movq %rax, 0x40(%rsp)
subq $0xf, %rax
ja 0xbe3b7
movq 0x40(%rsp), %rax
leaq 0x31f3be(%rip), %rcx # 0x3dd3e8
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
jmp 0xbe3b7
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movl (%rax), %esi
callq 0xbe4a0
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movl (%rax), %esi
callq 0xbe4e0
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movq (%rax), %rsi
callq 0xbe520
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movq (%rax), %rsi
callq 0xbe560
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0xf0(%rsp), %rcx
movq (%rcx), %rax
movq 0x8(%rcx), %rcx
movq %rcx, 0xe8(%rsp)
movq %rax, 0xe0(%rsp)
movq 0xe0(%rsp), %rdi
movq 0xe8(%rsp), %rsi
callq 0x9f970
movq 0x38(%rsp), %rdi
movq %rax, 0xd0(%rsp)
movq %rdx, 0xd8(%rsp)
movq 0xd0(%rsp), %rax
movq 0xd8(%rsp), %rcx
movq %rcx, 0xc8(%rsp)
movq %rax, 0xc0(%rsp)
movq 0xc0(%rsp), %rsi
movq 0xc8(%rsp), %rdx
callq 0xbe5a0
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rax
movq %rax, 0x30(%rsp)
movq 0xf0(%rsp), %rcx
movq (%rcx), %rax
movq 0x8(%rcx), %rcx
movq %rcx, 0xb8(%rsp)
movq %rax, 0xb0(%rsp)
movq 0xb0(%rsp), %rdi
movq 0xb8(%rsp), %rsi
callq 0x9fa20
movq 0x30(%rsp), %rdi
movq %rax, 0xa0(%rsp)
movq %rdx, 0xa8(%rsp)
movq 0xa0(%rsp), %rax
movq 0xa8(%rsp), %rcx
movq %rcx, 0x98(%rsp)
movq %rax, 0x90(%rsp)
movq 0x90(%rsp), %rsi
movq 0x98(%rsp), %rdx
callq 0xbe610
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movb (%rax), %al
andb $0x1, %al
movzbl %al, %esi
callq 0xbe680
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movsbl (%rax), %esi
callq 0xbe6a0
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movss (%rax), %xmm0
callq 0xbe6c0
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movsd (%rax), %xmm0
callq 0xbe6e0
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
fldt (%rax)
movq %rsp, %rax
fstpt (%rax)
callq 0xbe700
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movq (%rax), %rsi
callq 0xbe720
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rax
movq %rax, 0x28(%rsp)
movq 0xf0(%rsp), %rax
movq (%rax), %rsi
movq 0xf0(%rsp), %rax
movq 0x8(%rax), %rdx
leaq 0x80(%rsp), %rdi
callq 0x9fc80
movq 0x28(%rsp), %rdi
movq 0x80(%rsp), %rsi
movq 0x88(%rsp), %rdx
callq 0xbe740
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rdi
movq 0xf0(%rsp), %rax
movq (%rax), %rsi
callq 0xbe760
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rax
movq %rax, 0x20(%rsp)
movq 0xf0(%rsp), %rax
movq (%rax), %rcx
movq %rcx, 0x60(%rsp)
movq 0x8(%rax), %rax
movq %rax, 0x68(%rsp)
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
leaq 0x70(%rsp), %rdi
callq 0x9fdf0
movq 0x20(%rsp), %rdi
movq 0x70(%rsp), %rsi
movq 0x78(%rsp), %rdx
callq 0xbe780
movq %rax, 0x100(%rsp)
jmp 0xbe3e0
movq 0xf8(%rsp), %rax
movq %rax, 0x18(%rsp)
leaq 0x5f(%rsp), %rdi
callq 0x9f770
movq 0x18(%rsp), %rdi
callq 0xbe7a0
movq %rax, 0x100(%rsp)
movq 0x100(%rsp), %rax
movq %rax, 0x50(%rsp)
movq 0x50(%rsp), %rax
movq %rax, 0x10(%rsp)
callq 0xa6ee0
movl %eax, %edi
callq 0xa5690
movl %eax, %ecx
movq 0x10(%rsp), %rax
movl %ecx, %ecx
cmpq %rcx, %rax
jbe 0xbe41d
leaq 0x31f4e7(%rip), %rdi # 0x3dd8ff
callq 0x9f520
movq 0x50(%rsp), %rax
addq $0x108, %rsp # imm = 0x108
retq
nopw (%rax,%rax)
| _ZN3fmt3v106detail16get_dynamic_specINS1_13width_checkerENS0_16basic_format_argINS0_20basic_format_contextINS0_8appenderEcEEEEEEiT0_:
sub rsp, 108h
lea rax, [rsp+108h+arg_0]
lea rcx, [rsp+108h+var_B9]
mov [rsp+108h+var_10], rcx
mov [rsp+108h+var_18], rax
mov rax, [rsp+108h+var_18]
mov eax, [rax+10h]
mov [rsp+108h+var_C8], rax
sub rax, 0Fh; switch 16 cases
ja def_BE031; jumptable 00000000000BE031 default case
mov rax, [rsp+108h+var_C8]
lea rcx, jpt_BE031
movsxd rax, ds:(jpt_BE031 - 3DD3E8h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_BE033:
jmp def_BE031; jumptable 00000000000BE031 case 0
loc_BE038:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 1
mov rax, [rsp+108h+var_18]
mov esi, [rax]
call _ZN3fmt3v106detail13width_checkerclIiTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE05C:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 2
mov rax, [rsp+108h+var_18]
mov esi, [rax]
call _ZN3fmt3v106detail13width_checkerclIjTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE080:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 3
mov rax, [rsp+108h+var_18]
mov rsi, [rax]
call _ZN3fmt3v106detail13width_checkerclIxTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE0A5:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 4
mov rax, [rsp+108h+var_18]
mov rsi, [rax]
call _ZN3fmt3v106detail13width_checkerclIyTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE0CA:
mov rax, [rsp+108h+var_10]; jumptable 00000000000BE031 case 5
mov [rsp+108h+var_D0], rax
mov rcx, [rsp+108h+var_18]
mov rax, [rcx]
mov rcx, [rcx+8]
mov [rsp+108h+var_20], rcx
mov [rsp+108h+var_28], rax
mov rdi, [rsp+108h+var_28]
mov rsi, [rsp+108h+var_20]
call _ZN3fmt3v106detail17convert_for_visitInEET_S3_; fmt::v10::detail::convert_for_visit<__int128>(__int128)
mov rdi, [rsp+108h+var_D0]
mov [rsp+108h+var_38], rax
mov [rsp+108h+var_30], rdx
mov rax, [rsp+108h+var_38]
mov rcx, [rsp+108h+var_30]
mov [rsp+108h+var_40], rcx
mov [rsp+108h+var_48], rax
mov rsi, [rsp+108h+var_48]
mov rdx, [rsp+108h+var_40]
call _ZN3fmt3v106detail13width_checkerclInTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE162:
mov rax, [rsp+108h+var_10]; jumptable 00000000000BE031 case 6
mov [rsp+108h+var_D8], rax
mov rcx, [rsp+108h+var_18]
mov rax, [rcx]
mov rcx, [rcx+8]
mov [rsp+108h+var_50], rcx
mov [rsp+108h+var_58], rax
mov rdi, [rsp+108h+var_58]
mov rsi, [rsp+108h+var_50]
call _ZN3fmt3v106detail17convert_for_visitIoEET_S3_; fmt::v10::detail::convert_for_visit<unsigned __int128>(unsigned __int128)
mov rdi, [rsp+108h+var_D8]
mov [rsp+108h+var_68], rax
mov [rsp+108h+var_60], rdx
mov rax, [rsp+108h+var_68]
mov rcx, [rsp+108h+var_60]
mov [rsp+108h+var_70], rcx
mov [rsp+108h+var_78], rax
mov rsi, [rsp+108h+var_78]
mov rdx, [rsp+108h+var_70]
call _ZN3fmt3v106detail13width_checkerclIoTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE1FA:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 7
mov rax, [rsp+108h+var_18]
mov al, [rax]
and al, 1
movzx esi, al
call _ZN3fmt3v106detail13width_checkerclIbTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE223:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 8
mov rax, [rsp+108h+var_18]
movsx esi, byte ptr [rax]
call _ZN3fmt3v106detail13width_checkerclIcTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE248:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 9
mov rax, [rsp+108h+var_18]
movss xmm0, dword ptr [rax]
call _ZN3fmt3v106detail13width_checkerclIfTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE26E:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 10
mov rax, [rsp+108h+var_18]
movsd xmm0, qword ptr [rax]
call _ZN3fmt3v106detail13width_checkerclIdTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE294:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 11
mov rax, [rsp+108h+var_18]
fld tbyte ptr [rax]
mov rax, rsp
fstp tbyte ptr [rax]
call _ZN3fmt3v106detail13width_checkerclIeTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE2BD:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 12
mov rax, [rsp+108h+var_18]
mov rsi, [rax]
call _ZN3fmt3v106detail13width_checkerclIPKcTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE2E2:
mov rax, [rsp+108h+var_10]; jumptable 00000000000BE031 case 13
mov [rsp+108h+var_E0], rax
mov rax, [rsp+108h+var_18]
mov rsi, [rax]
mov rax, [rsp+108h+var_18]
mov rdx, [rax+8]
lea rdi, [rsp+108h+var_88]
call _ZN3fmt3v1017basic_string_viewIcEC2EPKcm; fmt::v10::basic_string_view<char>::basic_string_view(char const*,ulong)
mov rdi, [rsp+108h+var_E0]
mov rsi, [rsp+108h+var_88]
mov rdx, [rsp+108h+var_80]
call _ZN3fmt3v106detail13width_checkerclINS0_17basic_string_viewIcEETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE33A:
mov rdi, [rsp+108h+var_10]; jumptable 00000000000BE031 case 14
mov rax, [rsp+108h+var_18]
mov rsi, [rax]
call _ZN3fmt3v106detail13width_checkerclIPKvTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_
mov [rsp+108h+var_8], rax
jmp loc_BE3E0
loc_BE35F:
mov rax, [rsp+108h+var_10]; jumptable 00000000000BE031 case 15
mov [rsp+108h+var_E8], rax
mov rax, [rsp+108h+var_18]
mov rcx, [rax]
mov [rsp+108h+var_A8], rcx
mov rax, [rax+8]
mov [rsp+108h+var_A0], rax
mov rsi, [rsp+108h+var_A8]
mov rdx, [rsp+108h+var_A0]
lea rdi, [rsp+108h+var_98]
call _ZN3fmt3v1016basic_format_argINS0_20basic_format_contextINS0_8appenderEcEEE6handleC2ENS0_6detail12custom_valueIS4_EE; fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>::handle::handle(fmt::v10::detail::custom_value<fmt::v10::basic_format_context<fmt::v10::appender,char>>)
mov rdi, [rsp+108h+var_E8]
mov rsi, [rsp+108h+var_98]; char *
mov rdx, [rsp+108h+var_90]
call _ZN3fmt3v106detail13width_checkerclINS0_16basic_format_argINS0_20basic_format_contextINS0_8appenderEcEEE6handleETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEySB_
mov [rsp+108h+var_8], rax
jmp short loc_BE3E0
def_BE031:
mov rax, [rsp+108h+var_10]; jumptable 00000000000BE031 default case
mov [rsp+108h+var_F0], rax
lea rdi, [rsp+108h+var_A9]; this
call _ZN3fmt3v109monostateC2Ev; fmt::v10::monostate::monostate(void)
mov rdi, [rsp+108h+var_F0]
call _ZN3fmt3v106detail13width_checkerclINS0_9monostateETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS6_
mov [rsp+108h+var_8], rax
loc_BE3E0:
mov rax, [rsp+108h+var_8]
mov [rsp+108h+var_B8], rax
mov rax, [rsp+108h+var_B8]
mov [rsp+108h+var_F8], rax
call _ZN3fmt3v106detail9max_valueIiEET_v; fmt::v10::detail::max_value<int>(void)
mov edi, eax
call _ZN3fmt3v106detail11to_unsignedIiEENSt13make_unsignedIT_E4typeES4_; fmt::v10::detail::to_unsigned<int>(int)
mov ecx, eax
mov rax, [rsp+108h+var_F8]
mov ecx, ecx
cmp rax, rcx
jbe short loc_BE41D
lea rdi, aNumberIsTooBig; "number is too big"
call _ZN3fmt3v106detail18throw_format_errorEPKc; fmt::v10::detail::throw_format_error(char const*)
loc_BE41D:
mov rax, [rsp+108h+var_B8]
add rsp, 108h
retn
| long long fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>>(
_DWORD a1,
_DWORD a2,
_DWORD a3,
_DWORD a4,
_DWORD a5,
_DWORD a6,
char a7,
long long a8,
int a9)
{
long long v9; // rdi
const char *v10; // rsi
long long v11; // rax
long long v12; // rdx
long long v13; // rax
long long v14; // rdx
unsigned int v15; // eax
long double v17; // [rsp+0h] [rbp-108h]
unsigned long long v18; // [rsp+10h] [rbp-F8h]
char *v19; // [rsp+18h] [rbp-F0h]
char *v20; // [rsp+20h] [rbp-E8h]
char *v21; // [rsp+28h] [rbp-E0h]
char v22; // [rsp+4Fh] [rbp-B9h] BYREF
long long v23; // [rsp+50h] [rbp-B8h]
char v24; // [rsp+5Fh] [rbp-A9h] BYREF
long long v25; // [rsp+60h] [rbp-A8h]
long long v26; // [rsp+68h] [rbp-A0h]
char *v27[2]; // [rsp+70h] [rbp-98h] BYREF
_QWORD v28[4]; // [rsp+80h] [rbp-88h] BYREF
long long v29; // [rsp+A0h] [rbp-68h]
long long v30; // [rsp+A8h] [rbp-60h]
long long v31; // [rsp+B0h] [rbp-58h]
long long v32; // [rsp+B8h] [rbp-50h]
long long v33; // [rsp+C0h] [rbp-48h]
long long v34; // [rsp+C8h] [rbp-40h]
long long v35; // [rsp+D0h] [rbp-38h]
long long v36; // [rsp+D8h] [rbp-30h]
long long v37; // [rsp+E0h] [rbp-28h]
long long v38; // [rsp+E8h] [rbp-20h]
long long *v39; // [rsp+F0h] [rbp-18h]
char *v40; // [rsp+F8h] [rbp-10h]
long long v41; // [rsp+100h] [rbp-8h]
v40 = &v22;
v39 = (long long *)&a7;
switch ( a9 )
{
case 1:
v9 = (long long)v40;
v10 = (const char *)*(unsigned int *)v39;
v41 = ZN3fmt3v106detail13width_checkerclIiTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(v40, v10);
break;
case 2:
v9 = (long long)v40;
v10 = (const char *)*(unsigned int *)v39;
v41 = ZN3fmt3v106detail13width_checkerclIjTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(v40, v10);
break;
case 3:
v9 = (long long)v40;
v10 = (const char *)*v39;
v41 = ZN3fmt3v106detail13width_checkerclIxTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(v40, *v39);
break;
case 4:
v9 = (long long)v40;
v10 = (const char *)*v39;
v41 = ZN3fmt3v106detail13width_checkerclIyTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(v40, *v39);
break;
case 5:
v11 = *v39;
v38 = v39[1];
v37 = v11;
v9 = (long long)v40;
v35 = fmt::v10::detail::convert_for_visit<__int128>(v11);
v36 = v12;
v34 = v12;
v33 = v35;
v10 = (const char *)v35;
v41 = ZN3fmt3v106detail13width_checkerclInTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(
v9,
v35,
v12);
break;
case 6:
v13 = *v39;
v32 = v39[1];
v31 = v13;
v9 = (long long)v40;
v29 = fmt::v10::detail::convert_for_visit<unsigned __int128>(v13);
v30 = v14;
v28[3] = v14;
v28[2] = v29;
v10 = (const char *)v29;
v41 = ZN3fmt3v106detail13width_checkerclIoTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(
v9,
v29,
v14);
break;
case 7:
ZN3fmt3v106detail13width_checkerclIbTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(
v40,
*(_BYTE *)v39 & 1);
case 8:
ZN3fmt3v106detail13width_checkerclIcTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(
v40,
(unsigned int)*(char *)v39);
case 9:
ZN3fmt3v106detail13width_checkerclIfTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(
v40,
*(float *)v39);
case 10:
ZN3fmt3v106detail13width_checkerclIdTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(
v40,
*(double *)v39);
case 11:
v17 = *(long double *)v39;
ZN3fmt3v106detail13width_checkerclIeTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_(*(_TBYTE *)&v17);
case 12:
ZN3fmt3v106detail13width_checkerclIPKcTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_(v40, *v39);
case 13:
v21 = v40;
fmt::v10::basic_string_view<char>::basic_string_view(v28, *v39, v39[1]);
ZN3fmt3v106detail13width_checkerclINS0_17basic_string_viewIcEETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_(
v21,
v28[0],
v28[1]);
case 14:
ZN3fmt3v106detail13width_checkerclIPKvTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_(v40, *v39);
case 15:
v20 = v40;
v25 = *v39;
v26 = v39[1];
fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>::handle::handle(v27, v25, v26);
ZN3fmt3v106detail13width_checkerclINS0_16basic_format_argINS0_20basic_format_contextINS0_8appenderEcEEE6handleETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEySB_(
v20,
v27[0],
v27[1]);
default:
v19 = v40;
fmt::v10::monostate::monostate((fmt::v10::monostate *)&v24);
ZN3fmt3v106detail13width_checkerclINS0_9monostateETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS6_(v19);
}
v23 = v41;
v18 = v41;
v15 = fmt::v10::detail::max_value<int>(v9);
if ( v18 > (unsigned int)fmt::v10::detail::to_unsigned<int>(v15) )
fmt::v10::detail::throw_format_error((fmt::v10::detail *)"number is too big", v10);
return v23;
}
| get_dynamic_spec<fmt::v10::detail::width_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>>:
SUB RSP,0x108
LEA RAX,[RSP + 0x110]
LEA RCX,[RSP + 0x4f]
MOV qword ptr [RSP + 0xf8],RCX
MOV qword ptr [RSP + 0xf0],RAX
MOV RAX,qword ptr [RSP + 0xf0]
MOV EAX,dword ptr [RAX + 0x10]
MOV qword ptr [RSP + 0x40],RAX
SUB RAX,0xf
JA 0x001be3b7
MOV RAX,qword ptr [RSP + 0x40]
LEA RCX,[0x4dd3e8]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_0:
JMP 0x001be3b7
caseD_1:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOV ESI,dword ptr [RAX]
CALL 0x001be4a0
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_2:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOV ESI,dword ptr [RAX]
CALL 0x001be4e0
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_3:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOV RSI,qword ptr [RAX]
CALL 0x001be520
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_4:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOV RSI,qword ptr [RAX]
CALL 0x001be560
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_5:
MOV RAX,qword ptr [RSP + 0xf8]
MOV qword ptr [RSP + 0x38],RAX
MOV RCX,qword ptr [RSP + 0xf0]
MOV RAX,qword ptr [RCX]
MOV RCX,qword ptr [RCX + 0x8]
MOV qword ptr [RSP + 0xe8],RCX
MOV qword ptr [RSP + 0xe0],RAX
MOV RDI,qword ptr [RSP + 0xe0]
MOV RSI,qword ptr [RSP + 0xe8]
CALL 0x0019f970
MOV RDI,qword ptr [RSP + 0x38]
MOV qword ptr [RSP + 0xd0],RAX
MOV qword ptr [RSP + 0xd8],RDX
MOV RAX,qword ptr [RSP + 0xd0]
MOV RCX,qword ptr [RSP + 0xd8]
MOV qword ptr [RSP + 0xc8],RCX
MOV qword ptr [RSP + 0xc0],RAX
MOV RSI,qword ptr [RSP + 0xc0]
MOV RDX,qword ptr [RSP + 0xc8]
CALL 0x001be5a0
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_6:
MOV RAX,qword ptr [RSP + 0xf8]
MOV qword ptr [RSP + 0x30],RAX
MOV RCX,qword ptr [RSP + 0xf0]
MOV RAX,qword ptr [RCX]
MOV RCX,qword ptr [RCX + 0x8]
MOV qword ptr [RSP + 0xb8],RCX
MOV qword ptr [RSP + 0xb0],RAX
MOV RDI,qword ptr [RSP + 0xb0]
MOV RSI,qword ptr [RSP + 0xb8]
CALL 0x0019fa20
MOV RDI,qword ptr [RSP + 0x30]
MOV qword ptr [RSP + 0xa0],RAX
MOV qword ptr [RSP + 0xa8],RDX
MOV RAX,qword ptr [RSP + 0xa0]
MOV RCX,qword ptr [RSP + 0xa8]
MOV qword ptr [RSP + 0x98],RCX
MOV qword ptr [RSP + 0x90],RAX
MOV RSI,qword ptr [RSP + 0x90]
MOV RDX,qword ptr [RSP + 0x98]
CALL 0x001be610
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_7:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOV AL,byte ptr [RAX]
AND AL,0x1
MOVZX ESI,AL
CALL 0x001be680
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_8:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOVSX ESI,byte ptr [RAX]
CALL 0x001be6a0
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_9:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOVSS XMM0,dword ptr [RAX]
CALL 0x001be6c0
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_a:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOVSD XMM0,qword ptr [RAX]
CALL 0x001be6e0
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_b:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
FLD tword ptr [RAX]
MOV RAX,RSP
FSTP tword ptr [RAX]
CALL 0x001be700
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_c:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOV RSI,qword ptr [RAX]
CALL 0x001be720
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_d:
MOV RAX,qword ptr [RSP + 0xf8]
MOV qword ptr [RSP + 0x28],RAX
MOV RAX,qword ptr [RSP + 0xf0]
MOV RSI,qword ptr [RAX]
MOV RAX,qword ptr [RSP + 0xf0]
MOV RDX,qword ptr [RAX + 0x8]
LEA RDI,[RSP + 0x80]
CALL 0x0019fc80
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,qword ptr [RSP + 0x80]
MOV RDX,qword ptr [RSP + 0x88]
CALL 0x001be740
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_e:
MOV RDI,qword ptr [RSP + 0xf8]
MOV RAX,qword ptr [RSP + 0xf0]
MOV RSI,qword ptr [RAX]
CALL 0x001be760
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
caseD_f:
MOV RAX,qword ptr [RSP + 0xf8]
MOV qword ptr [RSP + 0x20],RAX
MOV RAX,qword ptr [RSP + 0xf0]
MOV RCX,qword ptr [RAX]
MOV qword ptr [RSP + 0x60],RCX
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x68],RAX
MOV RSI,qword ptr [RSP + 0x60]
MOV RDX,qword ptr [RSP + 0x68]
LEA RDI,[RSP + 0x70]
CALL 0x0019fdf0
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x70]
MOV RDX,qword ptr [RSP + 0x78]
CALL 0x001be780
MOV qword ptr [RSP + 0x100],RAX
JMP 0x001be3e0
default:
MOV RAX,qword ptr [RSP + 0xf8]
MOV qword ptr [RSP + 0x18],RAX
LEA RDI,[RSP + 0x5f]
CALL 0x0019f770
MOV RDI,qword ptr [RSP + 0x18]
CALL 0x001be7a0
MOV qword ptr [RSP + 0x100],RAX
LAB_001be3e0:
MOV RAX,qword ptr [RSP + 0x100]
MOV qword ptr [RSP + 0x50],RAX
MOV RAX,qword ptr [RSP + 0x50]
MOV qword ptr [RSP + 0x10],RAX
CALL 0x001a6ee0
MOV EDI,EAX
CALL 0x001a5690
MOV ECX,EAX
MOV RAX,qword ptr [RSP + 0x10]
MOV ECX,ECX
CMP RAX,RCX
JBE 0x001be41d
LEA RDI,[0x4dd8ff]
CALL 0x0019f520
LAB_001be41d:
MOV RAX,qword ptr [RSP + 0x50]
ADD RSP,0x108
RET
|
/* int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker,
fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char> >
>(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char> >) */
int fmt::v10::detail::
get_dynamic_spec<fmt::v10::detail::width_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>>
(void)
{
int1 auVar1 [16];
int4 uVar2;
ulong uVar3;
byte bVar4;
int iVar5;
uint uVar6;
int4 extraout_var;
int8 extraout_RDX;
int8 extraout_RDX_00;
byte bStack0000000000000008;
ulong in_stack_00000010;
int4 in_stack_00000018;
unkbyte10 in_stack_fffffffffffffef8;
int6 in_stack_ffffffffffffff02;
int1 local_b9;
ulong local_b8;
monostate local_a9;
detail *local_a8;
ulong local_a0;
int8 local_98;
int8 local_90;
int8 local_88;
int8 local_80;
int8 local_78;
int8 local_68;
detail *local_58;
ulong local_50;
__int128 *local_48;
__int128 *local_38;
detail *local_28;
ulong local_20;
int8 *local_18;
int1 *local_10;
ulong local_8;
uVar2 = _bStack0000000000000008;
local_18 = (int8 *)&stack0x00000008;
local_10 = &local_b9;
_bStack0000000000000008 = uVar2;
switch(in_stack_00000018) {
case 0:
default:
monostate::monostate(&local_a9);
local_8 = _ZN3fmt3v106detail13width_checkerclINS0_9monostateETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS6_
(&local_b9);
break;
case 1:
local_8 = _ZN3fmt3v106detail13width_checkerclIiTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9,uVar2);
break;
case 2:
local_8 = _ZN3fmt3v106detail13width_checkerclIjTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9,uVar2);
break;
case 3:
local_8 = _ZN3fmt3v106detail13width_checkerclIxTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9,_bStack0000000000000008);
break;
case 4:
local_8 = _ZN3fmt3v106detail13width_checkerclIyTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9,_bStack0000000000000008);
break;
case 5:
local_28 = _bStack0000000000000008;
local_20 = in_stack_00000010;
auVar1._10_6_ = in_stack_ffffffffffffff02;
auVar1._0_10_ = in_stack_fffffffffffffef8;
local_48 = convert_for_visit<__int128>((__int128 *)_bStack0000000000000008,(__int128)auVar1);
local_38 = local_48;
local_8 = _ZN3fmt3v106detail13width_checkerclInTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9,local_48,extraout_RDX);
break;
case 6:
local_58 = _bStack0000000000000008;
local_50 = in_stack_00000010;
uVar6 = convert_for_visit<unsigned__int128>(_bStack0000000000000008,(uint)in_stack_00000010);
local_78 = CONCAT44(extraout_var,uVar6);
local_68 = local_78;
local_8 = _ZN3fmt3v106detail13width_checkerclIoTnNSt9enable_ifIXsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9,local_78,extraout_RDX_00);
break;
case 7:
bVar4 = bStack0000000000000008 & 1;
local_8 = _ZN3fmt3v106detail13width_checkerclIbTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9,bVar4);
break;
case 8:
iVar5 = (int)(char)bStack0000000000000008;
local_8 = _ZN3fmt3v106detail13width_checkerclIcTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9,iVar5);
break;
case 9:
local_8 = _ZN3fmt3v106detail13width_checkerclIfTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(uVar2,&local_b9);
break;
case 10:
local_8 = _ZN3fmt3v106detail13width_checkerclIdTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(_bStack0000000000000008,&local_b9);
break;
case 0xb:
local_8 = _ZN3fmt3v106detail13width_checkerclIeTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS5_
(&local_b9);
break;
case 0xc:
local_8 = _ZN3fmt3v106detail13width_checkerclIPKcTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_
(&local_b9,_bStack0000000000000008);
break;
case 0xd:
basic_string_view<char>::basic_string_view
((basic_string_view<char> *)&local_88,(char *)_bStack0000000000000008,
in_stack_00000010);
local_8 = _ZN3fmt3v106detail13width_checkerclINS0_17basic_string_viewIcEETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_
(&local_b9,local_88,local_80);
break;
case 0xe:
local_8 = _ZN3fmt3v106detail13width_checkerclIPKvTnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEyS7_
(&local_b9,_bStack0000000000000008);
break;
case 0xf:
local_a8 = _bStack0000000000000008;
local_a0 = in_stack_00000010;
basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>::handle::handle
((handle *)&local_98,_bStack0000000000000008,in_stack_00000010);
local_8 = _ZN3fmt3v106detail13width_checkerclINS0_16basic_format_argINS0_20basic_format_contextINS0_8appenderEcEEE6handleETnNSt9enable_ifIXntsr10is_integerIT_EE5valueEiE4typeELi0EEEySB_
(&local_b9,local_98,local_90);
}
uVar3 = local_8;
local_b8 = local_8;
iVar5 = max_value<int>();
uVar6 = to_unsigned<int>(iVar5);
if (uVar3 <= uVar6) {
return (int)local_b8;
}
/* WARNING: Subroutine does not return */
throw_format_error("number is too big");
}
| |
22,163 | int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker, fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>>(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>) | aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h | FMT_CONSTEXPR auto get_dynamic_spec(FormatArg arg) -> int {
unsigned long long value = visit_format_arg(Handler(), arg);
if (value > to_unsigned(max_value<int>()))
throw_format_error("number is too big");
return static_cast<int>(value);
} | O3 | c | int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker, fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>>(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>):
pushq %rax
movl 0x20(%rsp), %ecx
decl %ecx
cmpl $0xe, %ecx
ja 0x3f577
leaq 0x10(%rsp), %rax
leaq 0x121f55(%rip), %rdx # 0x16148c
movslq (%rdx,%rcx,4), %rcx
addq %rdx, %rcx
jmpq *%rcx
movslq (%rax), %rax
testq %rax, %rax
jns 0x3f575
jmp 0x3f55e
cmpq $0x0, 0x8(%rax)
js 0x3f55e
movq (%rax), %rax
jmp 0x3f56c
movq (%rax), %rax
testq %rax, %rax
jns 0x3f56c
leaq 0x1223d6(%rip), %rdi # 0x16193b
callq 0x346a6
movl (%rax), %eax
movq %rax, %rcx
shrq $0x1f, %rcx
jne 0x3f583
popq %rcx
retq
leaq 0x1223d0(%rip), %rdi # 0x16194e
callq 0x346a6
leaq 0x12222f(%rip), %rdi # 0x1617b9
callq 0x346a6
| _ZN3fmt3v106detail16get_dynamic_specINS1_17precision_checkerENS0_16basic_format_argINS0_20basic_format_contextINS0_8appenderEcEEEEEEiT0_:
push rax
mov ecx, [rsp+8+arg_10]
dec ecx; switch 15 cases
cmp ecx, 0Eh
ja short def_3F53E; jumptable 000000000003F53E default case, cases 7-15
lea rax, [rsp+8+arg_0]
lea rdx, jpt_3F53E
movsxd rcx, ds:(jpt_3F53E - 16148Ch)[rdx+rcx*4]
add rcx, rdx
jmp rcx; switch jump
loc_3F540:
movsxd rax, dword ptr [rax]; jumptable 000000000003F53E case 1
test rax, rax
jns short loc_3F575
jmp short loc_3F55E
loc_3F54A:
cmp qword ptr [rax+8], 0; jumptable 000000000003F53E case 5
js short loc_3F55E
loc_3F551:
mov rax, [rax]; jumptable 000000000003F53E cases 4,6
jmp short loc_3F56C
loc_3F556:
mov rax, [rax]; jumptable 000000000003F53E case 3
test rax, rax
jns short loc_3F56C
loc_3F55E:
lea rdi, aNegativePrecis; "negative precision"
call _ZN3fmt3v106detail18throw_format_errorEPKc; fmt::v10::detail::throw_format_error(char const*)
loc_3F56A:
mov eax, [rax]; jumptable 000000000003F53E case 2
loc_3F56C:
mov rcx, rax
shr rcx, 1Fh
jnz short loc_3F583
loc_3F575:
pop rcx
retn
def_3F53E:
lea rdi, aPrecisionIsNot; jumptable 000000000003F53E default case, cases 7-15
call _ZN3fmt3v106detail18throw_format_errorEPKc; fmt::v10::detail::throw_format_error(char const*)
loc_3F583:
lea rdi, aNumberIsTooBig; "number is too big"
call _ZN3fmt3v106detail18throw_format_errorEPKc; fmt::v10::detail::throw_format_error(char const*)
| unsigned long long fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::precision_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>>(
long long a1,
const char *a2,
long long a3,
long long a4,
long long a5,
long long a6,
long long a7,
long long a8,
int a9)
{
unsigned long long result; // rax
switch ( a9 )
{
case 1:
result = (int)a7;
if ( (int)a7 < 0LL )
goto LABEL_7;
return result;
case 2:
result = (unsigned int)a7;
goto LABEL_9;
case 3:
result = a7;
if ( a7 < 0 )
goto LABEL_7;
goto LABEL_9;
case 4:
case 6:
goto LABEL_5;
case 5:
if ( a8 < 0 )
LABEL_7:
fmt::v10::detail::throw_format_error((fmt::v10::detail *)"negative precision", a2);
LABEL_5:
result = a7;
LABEL_9:
if ( result >> 31 )
fmt::v10::detail::throw_format_error((fmt::v10::detail *)"number is too big", a2);
return result;
default:
fmt::v10::detail::throw_format_error((fmt::v10::detail *)"precision is not integer", a2);
}
}
| get_dynamic_spec<fmt::v10::detail::precision_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>>:
PUSH RAX
MOV ECX,dword ptr [RSP + 0x20]
DEC ECX
CMP ECX,0xe
JA 0x0013f577
LEA RAX,[RSP + 0x10]
LEA RDX,[0x26148c]
MOVSXD RCX,dword ptr [RDX + RCX*0x4]
ADD RCX,RDX
switchD:
JMP RCX
caseD_1:
MOVSXD RAX,dword ptr [RAX]
TEST RAX,RAX
JNS 0x0013f575
JMP 0x0013f55e
caseD_5:
CMP qword ptr [RAX + 0x8],0x0
JS 0x0013f55e
caseD_4:
MOV RAX,qword ptr [RAX]
JMP 0x0013f56c
caseD_3:
MOV RAX,qword ptr [RAX]
TEST RAX,RAX
JNS 0x0013f56c
LAB_0013f55e:
LEA RDI,[0x26193b]
CALL 0x001346a6
caseD_2:
MOV EAX,dword ptr [RAX]
LAB_0013f56c:
MOV RCX,RAX
SHR RCX,0x1f
JNZ 0x0013f583
LAB_0013f575:
POP RCX
RET
caseD_7:
LEA RDI,[0x26194e]
CALL 0x001346a6
LAB_0013f583:
LEA RDI,[0x2617b9]
CALL 0x001346a6
|
/* int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::precision_checker,
fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char> >
>(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char> >) */
int fmt::v10::detail::
get_dynamic_spec<fmt::v10::detail::precision_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>>
(void)
{
int iStack0000000000000008;
long in_stack_00000010;
int4 in_stack_00000018;
switch(in_stack_00000018) {
case 1:
_iStack0000000000000008 = (ulong)iStack0000000000000008;
if ((long)_iStack0000000000000008 < 0) {
LAB_0013f55e:
/* WARNING: Subroutine does not return */
throw_format_error("negative precision");
}
goto LAB_0013f575;
case 2:
_iStack0000000000000008 = _iStack0000000000000008 & 0xffffffff;
break;
case 3:
if ((long)_iStack0000000000000008 < 0) goto LAB_0013f55e;
break;
case 5:
if (in_stack_00000010 < 0) goto LAB_0013f55e;
case 4:
case 6:
break;
default:
/* WARNING: Subroutine does not return */
throw_format_error("precision is not integer");
}
if (_iStack0000000000000008 >> 0x1f != 0) {
/* WARNING: Subroutine does not return */
throw_format_error("number is too big");
}
LAB_0013f575:
return (int)_iStack0000000000000008;
}
| |
22,164 | nlohmann::json_abi_v3_11_3::detail::other_error nlohmann::json_abi_v3_11_3::detail::other_error::create<std::nullptr_t, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::nullptr_t) | monkey531[P]llama/common/json.hpp | static other_error create(int id_, const std::string& what_arg, BasicJsonContext context)
{
const std::string w = concat(exception::name("other_error", id_), exception::diagnostics(context), what_arg);
return {id_, w.c_str()};
} | O0 | cpp | nlohmann::json_abi_v3_11_3::detail::other_error nlohmann::json_abi_v3_11_3::detail::other_error::create<std::nullptr_t, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::nullptr_t):
subq $0xd8, %rsp
movq %rdi, 0x8(%rsp)
movq %rdi, %rax
movq %rax, 0x10(%rsp)
movq %rdi, 0xd0(%rsp)
movl %esi, 0xcc(%rsp)
movq %rdx, 0xc0(%rsp)
movq %rcx, 0xb8(%rsp)
leaq 0x57(%rsp), %rdi
movq %rdi, 0x18(%rsp)
callq 0x5b0d0
movq 0x18(%rsp), %rdx
leaq 0x16baeb(%rip), %rsi # 0x2134e9
leaq 0x58(%rsp), %rdi
callq 0x64e60
jmp 0xa7a0a
movl 0xcc(%rsp), %edx
leaq 0x78(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0xa9540
jmp 0xa7a22
xorl %eax, %eax
movl %eax, %esi
leaq 0x20(%rsp), %rdi
callq 0xa95e0
jmp 0xa7a32
movq 0xc0(%rsp), %rcx
leaq 0x98(%rsp), %rdi
leaq 0x78(%rsp), %rsi
leaq 0x20(%rsp), %rdx
callq 0xa9480
jmp 0xa7a53
leaq 0x20(%rsp), %rdi
callq 0x5b558
leaq 0x78(%rsp), %rdi
callq 0x5b558
leaq 0x58(%rsp), %rdi
callq 0x5b558
leaq 0x57(%rsp), %rdi
callq 0x5b530
movl 0xcc(%rsp), %eax
movl %eax, 0x4(%rsp)
leaq 0x98(%rsp), %rdi
callq 0x5a1d0
movq 0x8(%rsp), %rdi
movl 0x4(%rsp), %esi
movq %rax, %rdx
callq 0xa9660
jmp 0xa7aa6
leaq 0x98(%rsp), %rdi
callq 0x5b558
movq 0x10(%rsp), %rax
addq $0xd8, %rsp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
jmp 0xa7b1c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
jmp 0xa7b12
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
jmp 0xa7b08
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x20(%rsp), %rdi
callq 0x5b558
leaq 0x78(%rsp), %rdi
callq 0x5b558
leaq 0x58(%rsp), %rdi
callq 0x5b558
leaq 0x57(%rsp), %rdi
callq 0x5b530
jmp 0xa7b43
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x48(%rsp)
movl %eax, 0x44(%rsp)
leaq 0x98(%rsp), %rdi
callq 0x5b558
movq 0x48(%rsp), %rdi
callq 0x5abc0
nopl (%rax)
| _ZN8nlohmann16json_abi_v3_11_36detail11other_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_:
sub rsp, 0D8h
mov [rsp+0D8h+var_D0], rdi; int
mov rax, rdi
mov qword ptr [rsp+0D8h+var_C8], rax; int
mov [rsp+0D8h+var_8], rdi
mov [rsp+0D8h+var_C], esi
mov qword ptr [rsp+0D8h+var_18], rdx
mov [rsp+0D8h+var_20], rcx
lea rdi, [rsp+0D8h+var_81]
mov qword ptr [rsp+0D8h+var_C0], rdi; int
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, qword ptr [rsp+0D8h+var_C0]
lea rsi, aOtherError; "other_error"
lea rdi, [rsp+0D8h+var_81+1]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_A7A0A:
mov edx, [rsp+0D8h+var_C]
lea rdi, [rsp+0D8h+var_60]; int
lea rsi, [rsp+0D8h+var_81+1]
call _ZN8nlohmann16json_abi_v3_11_36detail9exception4nameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi; nlohmann::json_abi_v3_11_3::detail::exception::name(std::string const&,int)
jmp short $+2
loc_A7A22:
xor eax, eax
mov esi, eax
lea rdi, [rsp+0D8h+var_B8]
call _ZN8nlohmann16json_abi_v3_11_36detail9exception11diagnosticsB5cxx11EDn; nlohmann::json_abi_v3_11_3::detail::exception::diagnostics(decltype(nullptr))
jmp short $+2
loc_A7A32:
mov rcx, qword ptr [rsp+0D8h+var_18]; int
lea rdi, [rsp+0D8h+var_40]; int
lea rsi, [rsp+0D8h+var_60]; int
lea rdx, [rsp+0D8h+var_B8]; int
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJS8_S8_RKS8_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,std::string,std::string const&>(std::string,std::string,std::string const&)
jmp short $+2
loc_A7A53:
lea rdi, [rsp+0D8h+var_B8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+0D8h+var_60]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+0D8h+var_81+1]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+0D8h+var_81]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov eax, [rsp+0D8h+var_C]
mov [rsp+0D8h+var_D4], eax
lea rdi, [rsp+0D8h+var_40]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov rdi, [rsp+0D8h+var_D0]; this
mov esi, [rsp+0D8h+var_D4]; int
mov rdx, rax; char *
call _ZN8nlohmann16json_abi_v3_11_36detail11other_errorC2EiPKc; nlohmann::json_abi_v3_11_3::detail::other_error::other_error(int,char const*)
jmp short $+2
loc_A7AA6:
lea rdi, [rsp+0D8h+var_40]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rax, qword ptr [rsp+0D8h+var_C8]
add rsp, 0D8h
retn
mov rcx, rax
mov eax, edx
mov [rsp+arg_40], rcx
mov [rsp+arg_3C], eax
jmp short loc_A7B1C
mov rcx, rax
mov eax, edx
mov [rsp+arg_40], rcx
mov [rsp+arg_3C], eax
jmp short loc_A7B12
mov rcx, rax
mov eax, edx
mov [rsp+arg_40], rcx
mov [rsp+arg_3C], eax
jmp short loc_A7B08
mov rcx, rax
mov eax, edx
mov [rsp+arg_40], rcx
mov [rsp+arg_3C], eax
lea rdi, [rsp+arg_18]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_A7B08:
lea rdi, [rsp+arg_70]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_A7B12:
lea rdi, [rsp+arg_50]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_A7B1C:
lea rdi, [rsp+arg_4F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_A7B43
mov rcx, rax
mov eax, edx
mov [rsp+arg_40], rcx
mov [rsp+arg_3C], eax
lea rdi, [rsp+arg_90]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_A7B43:
mov rdi, [rsp+arg_40]
call __Unwind_Resume
| long long ZN8nlohmann16json_abi_v3_11_36detail11other_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_(
long long a1,
int a2,
long long a3,
long long a4)
{
int v4; // edx
int v5; // ecx
int v6; // r8d
int v7; // r9d
int v8; // r8d
int v9; // r9d
const char *v10; // rax
int v12; // [rsp+0h] [rbp-D8h]
int v13; // [rsp+0h] [rbp-D8h]
void *v14; // [rsp+0h] [rbp-D8h]
int v15; // [rsp+4h] [rbp-D4h]
int v16; // [rsp+8h] [rbp-D0h]
int v17; // [rsp+8h] [rbp-D0h]
nlohmann::json_abi_v3_11_3::detail::other_error *v18; // [rsp+8h] [rbp-D0h]
int v19; // [rsp+10h] [rbp-C8h]
int v20; // [rsp+10h] [rbp-C8h]
int v21[2]; // [rsp+10h] [rbp-C8h]
int v22; // [rsp+18h] [rbp-C0h]
int v23; // [rsp+18h] [rbp-C0h]
long long v24; // [rsp+20h] [rbp-B8h] BYREF
int v25; // [rsp+28h] [rbp-B0h]
int v26[8]; // [rsp+57h] [rbp-81h] BYREF
int v27[8]; // [rsp+78h] [rbp-60h] BYREF
int v28[8]; // [rsp+98h] [rbp-40h] BYREF
long long v29; // [rsp+B8h] [rbp-20h]
int v30[3]; // [rsp+C0h] [rbp-18h]
int v31; // [rsp+CCh] [rbp-Ch]
long long v32; // [rsp+D0h] [rbp-8h]
v32 = a1;
v31 = a2;
*(_QWORD *)v30 = a3;
v29 = a4;
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>((long long)v26 + 1, (long long)"other_error", (long long)v26);
nlohmann::json_abi_v3_11_3::detail::exception::name((int)v27, v12, a1, a1, (int)v26, v24, v25);
nlohmann::json_abi_v3_11_3::detail::exception::diagnostics[abi:cxx11](
(unsigned int)&v24,
0,
v4,
v5,
v6,
v7,
v13,
v16,
v19,
v22,
v24,
v25);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,std::string,std::string const&>(
(int)v28,
(int)v27,
(int)&v24,
v30[0],
v8,
v9,
v14,
v17,
v20,
v23,
v24);
std::string::~string(&v24);
std::string::~string(v27);
std::string::~string((char *)v26 + 1);
std::allocator<char>::~allocator(v26);
v15 = v31;
v10 = (const char *)std::string::c_str(v28);
nlohmann::json_abi_v3_11_3::detail::other_error::other_error(v18, v15, v10);
std::string::~string(v28);
return *(_QWORD *)v21;
}
| _ZN8nlohmann16json_abi_v3_11_36detail11other_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_:
SUB RSP,0xd8
MOV qword ptr [RSP + 0x8],RDI
MOV RAX,RDI
MOV qword ptr [RSP + 0x10],RAX
MOV qword ptr [RSP + 0xd0],RDI
MOV dword ptr [RSP + 0xcc],ESI
MOV qword ptr [RSP + 0xc0],RDX
MOV qword ptr [RSP + 0xb8],RCX
LEA RDI,[RSP + 0x57]
MOV qword ptr [RSP + 0x18],RDI
CALL 0x0015b0d0
MOV RDX,qword ptr [RSP + 0x18]
LAB_001a79f7:
LEA RSI,[0x3134e9]
LEA RDI,[RSP + 0x58]
CALL 0x00164e60
JMP 0x001a7a0a
LAB_001a7a0a:
MOV EDX,dword ptr [RSP + 0xcc]
LAB_001a7a11:
LEA RDI,[RSP + 0x78]
LEA RSI,[RSP + 0x58]
CALL 0x001a9540
JMP 0x001a7a22
LAB_001a7a22:
XOR EAX,EAX
MOV ESI,EAX
LEA RDI,[RSP + 0x20]
CALL 0x001a95e0
JMP 0x001a7a32
LAB_001a7a32:
MOV RCX,qword ptr [RSP + 0xc0]
LAB_001a7a3a:
LEA RDI,[RSP + 0x98]
LEA RSI,[RSP + 0x78]
LEA RDX,[RSP + 0x20]
CALL 0x001a9480
JMP 0x001a7a53
LAB_001a7a53:
LEA RDI,[RSP + 0x20]
CALL 0x0015b558
LEA RDI,[RSP + 0x78]
CALL 0x0015b558
LEA RDI,[RSP + 0x58]
CALL 0x0015b558
LEA RDI,[RSP + 0x57]
CALL 0x0015b530
MOV EAX,dword ptr [RSP + 0xcc]
MOV dword ptr [RSP + 0x4],EAX
LEA RDI,[RSP + 0x98]
CALL 0x0015a1d0
MOV RDI,qword ptr [RSP + 0x8]
MOV ESI,dword ptr [RSP + 0x4]
MOV RDX,RAX
LAB_001a7a9f:
CALL 0x001a9660
LAB_001a7aa4:
JMP 0x001a7aa6
LAB_001a7aa6:
LEA RDI,[RSP + 0x98]
CALL 0x0015b558
MOV RAX,qword ptr [RSP + 0x10]
ADD RSP,0xd8
RET
|
other_error *
_ZN8nlohmann16json_abi_v3_11_36detail11other_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_
(other_error *param_1,int param_2,string *param_3,int8 param_4)
{
int iVar1;
char *pcVar2;
exception local_b8 [55];
allocator local_81;
string local_80 [32];
exception local_60 [32];
detail local_40 [32];
int8 local_20;
string *local_18;
int local_c;
other_error *local_8;
local_20 = param_4;
local_18 = param_3;
local_c = param_2;
local_8 = param_1;
std::allocator<char>::allocator();
/* try { // try from 001a79f7 to 001a7a07 has its CatchHandler @ 001a7ac0 */
std::__cxx11::string::string<std::allocator<char>>(local_80,"other_error",&local_81);
/* try { // try from 001a7a11 to 001a7a1f has its CatchHandler @ 001a7ad0 */
nlohmann::json_abi_v3_11_3::detail::exception::name(local_60,local_80,local_c);
/* try { // try from 001a7a22 to 001a7a2f has its CatchHandler @ 001a7ae0 */
nlohmann::json_abi_v3_11_3::detail::exception::diagnostics_abi_cxx11_
(local_b8,(_func_decltype_nullptr *)0x0);
/* try { // try from 001a7a3a to 001a7a50 has its CatchHandler @ 001a7af0 */
nlohmann::json_abi_v3_11_3::detail::
concat<std::__cxx11::string,std::__cxx11::string,std::__cxx11::string,std::__cxx11::string_const&>
(local_40,(string *)local_60,(string *)local_b8,local_18);
std::__cxx11::string::~string((string *)local_b8);
std::__cxx11::string::~string((string *)local_60);
std::__cxx11::string::~string(local_80);
std::allocator<char>::~allocator((allocator<char> *)&local_81);
iVar1 = local_c;
pcVar2 = (char *)std::__cxx11::string::c_str();
/* try { // try from 001a7a9f to 001a7aa3 has its CatchHandler @ 001a7b28 */
nlohmann::json_abi_v3_11_3::detail::other_error::other_error(param_1,iVar1,pcVar2);
std::__cxx11::string::~string((string *)local_40);
return param_1;
}
| |
22,165 | ma_scan_end_block_record | eloqsql/storage/maria/ma_blockrec.c | void _ma_scan_end_block_record(MARIA_HA *info)
{
DBUG_ENTER("_ma_scan_end_block_record");
my_free(info->scan.bitmap_buff);
info->scan.bitmap_buff= 0;
if (info->scan_save)
{
my_free(info->scan_save);
info->scan_save= 0;
}
DBUG_VOID_RETURN;
} | O0 | c | ma_scan_end_block_record:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x220(%rax), %rdi
callq 0xf3ba0
movq -0x8(%rbp), %rax
movq $0x0, 0x220(%rax)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x280(%rax)
je 0x591b8
movq -0x8(%rbp), %rax
movq 0x280(%rax), %rdi
callq 0xf3ba0
movq -0x8(%rbp), %rax
movq $0x0, 0x280(%rax)
jmp 0x591ba
jmp 0x591bc
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _ma_scan_end_block_record:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov rdi, [rax+220h]
call my_free
mov rax, [rbp+var_8]
mov qword ptr [rax+220h], 0
mov rax, [rbp+var_8]
cmp qword ptr [rax+280h], 0
jz short loc_591B8
mov rax, [rbp+var_8]
mov rdi, [rax+280h]
call my_free
mov rax, [rbp+var_8]
mov qword ptr [rax+280h], 0
loc_591B8:
jmp short $+2
loc_591BA:
jmp short $+2
loc_591BC:
add rsp, 10h
pop rbp
retn
| long long ma_scan_end_block_record(long long a1)
{
long long result; // rax
my_free(*(_QWORD *)(a1 + 544));
*(_QWORD *)(a1 + 544) = 0LL;
result = a1;
if ( *(_QWORD *)(a1 + 640) )
{
my_free(*(_QWORD *)(a1 + 640));
result = a1;
*(_QWORD *)(a1 + 640) = 0LL;
}
return result;
}
| _ma_scan_end_block_record:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX + 0x220]
CALL 0x001f3ba0
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x220],0x0
MOV RAX,qword ptr [RBP + -0x8]
CMP qword ptr [RAX + 0x280],0x0
JZ 0x001591b8
MOV RAX,qword ptr [RBP + -0x8]
MOV RDI,qword ptr [RAX + 0x280]
CALL 0x001f3ba0
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x280],0x0
LAB_001591b8:
JMP 0x001591ba
LAB_001591ba:
JMP 0x001591bc
LAB_001591bc:
ADD RSP,0x10
POP RBP
RET
|
void _ma_scan_end_block_record(long param_1)
{
my_free(*(int8 *)(param_1 + 0x220));
*(int8 *)(param_1 + 0x220) = 0;
if (*(long *)(param_1 + 0x280) != 0) {
my_free(*(int8 *)(param_1 + 0x280));
*(int8 *)(param_1 + 0x280) = 0;
}
return;
}
| |
22,166 | diag | eloqsql/unittest/mytap/tap.c | void
diag(char const *fmt, ...)
{
va_list ap;
va_start(ap, fmt);
fprintf(tapout, "# ");
vfprintf(tapout, fmt, ap);
emit_endl();
va_end(ap);
} | O3 | c | diag:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0xc8, %rsp
movq %rdi, %rbx
leaq -0xe0(%rbp), %rdi
movq %rsi, 0x8(%rdi)
movq %rdx, 0x10(%rdi)
movq %rcx, 0x18(%rdi)
movq %r8, 0x20(%rdi)
movq %r9, 0x28(%rdi)
testb %al, %al
je 0x923d2
movaps %xmm0, -0xb0(%rbp)
movaps %xmm1, -0xa0(%rbp)
movaps %xmm2, -0x90(%rbp)
movaps %xmm3, -0x80(%rbp)
movaps %xmm4, -0x70(%rbp)
movaps %xmm5, -0x60(%rbp)
movaps %xmm6, -0x50(%rbp)
movaps %xmm7, -0x40(%rbp)
leaq -0x30(%rbp), %r14
movq %rdi, 0x10(%r14)
leaq 0x10(%rbp), %rax
movq %rax, 0x8(%r14)
movabsq $0x3000000008, %rax # imm = 0x3000000008
movq %rax, (%r14)
movq 0x2f3baa(%rip), %r15 # 0x385fa0
movq (%r15), %rdi
leaq 0x4b0f2(%rip), %rdx # 0xdd4f2
movl $0x1, %esi
xorl %eax, %eax
callq 0x291e0
movq (%r15), %rdi
movl $0x1, %esi
movq %rbx, %rdx
movq %r14, %rcx
callq 0x29730
movq (%r15), %rdi
leaq 0x4efa6(%rip), %rdx # 0xe13cf
movl $0x1, %esi
xorl %eax, %eax
callq 0x291e0
movq (%r15), %rdi
callq 0x293f0
addq $0xc8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| diag:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
sub rsp, 0C8h
mov rbx, rdi
lea rdi, [rbp+var_E0]
mov [rdi+8], rsi
mov [rdi+10h], rdx
mov [rdi+18h], rcx
mov [rdi+20h], r8
mov [rdi+28h], r9
test al, al
jz short loc_923D2
movaps [rbp+var_B0], xmm0
movaps [rbp+var_A0], xmm1
movaps [rbp+var_90], xmm2
movaps [rbp+var_80], xmm3
movaps [rbp+var_70], xmm4
movaps [rbp+var_60], xmm5
movaps [rbp+var_50], xmm6
movaps [rbp+var_40], xmm7
loc_923D2:
lea r14, [rbp+var_30]
mov [r14+10h], rdi
lea rax, [rbp+arg_0]
mov [r14+8], rax
mov rax, 3000000008h
mov [r14], rax
mov r15, cs:stdout_ptr
mov rdi, [r15]
lea rdx, asc_DD4F2; "# "
mov esi, 1
xor eax, eax
call ___fprintf_chk
mov rdi, [r15]
mov esi, 1
mov rdx, rbx
mov rcx, r14
call ___vfprintf_chk
mov rdi, [r15]
lea rdx, asc_E13CC+3; "\n"
mov esi, 1
xor eax, eax
call ___fprintf_chk
mov rdi, [r15]
call _fflush
add rsp, 0C8h
pop rbx
pop r14
pop r15
pop rbp
retn
| long long diag(
long long a1,
long long a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14,
char a15)
{
char v16; // [rsp+0h] [rbp-E0h] BYREF
long long v17; // [rsp+8h] [rbp-D8h]
long long v18; // [rsp+10h] [rbp-D0h]
long long v19; // [rsp+18h] [rbp-C8h]
long long v20; // [rsp+20h] [rbp-C0h]
long long v21; // [rsp+28h] [rbp-B8h]
__m128 v22; // [rsp+30h] [rbp-B0h]
__m128 v23; // [rsp+40h] [rbp-A0h]
__m128 v24; // [rsp+50h] [rbp-90h]
__m128 v25; // [rsp+60h] [rbp-80h]
__m128 v26; // [rsp+70h] [rbp-70h]
__m128 v27; // [rsp+80h] [rbp-60h]
__m128 v28; // [rsp+90h] [rbp-50h]
__m128 v29; // [rsp+A0h] [rbp-40h]
_QWORD v30[6]; // [rsp+B0h] [rbp-30h] BYREF
v22 = a7;
v23 = a8;
v24 = a9;
v25 = a10;
v26 = a11;
v27 = a12;
v28 = a13;
v29 = a14;
v17 = a2;
v18 = a3;
v19 = a4;
v20 = a5;
v21 = a6;
v30[2] = &v16;
v30[1] = &a15;
v30[0] = 0x3000000008LL;
__fprintf_chk(stdout, 1LL, "# ");
__vfprintf_chk(stdout, 1LL, a1, v30);
__fprintf_chk(stdout, 1LL, "\n");
return fflush(stdout);
}
| diag:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0xc8
MOV RBX,RDI
LEA RDI,[RBP + -0xe0]
MOV qword ptr [RDI + 0x8],RSI
MOV qword ptr [RDI + 0x10],RDX
MOV qword ptr [RDI + 0x18],RCX
MOV qword ptr [RDI + 0x20],R8
MOV qword ptr [RDI + 0x28],R9
TEST AL,AL
JZ 0x001923d2
MOVAPS xmmword ptr [RBP + -0xb0],XMM0
MOVAPS xmmword ptr [RBP + -0xa0],XMM1
MOVAPS xmmword ptr [RBP + -0x90],XMM2
MOVAPS xmmword ptr [RBP + -0x80],XMM3
MOVAPS xmmword ptr [RBP + -0x70],XMM4
MOVAPS xmmword ptr [RBP + -0x60],XMM5
MOVAPS xmmword ptr [RBP + -0x50],XMM6
MOVAPS xmmword ptr [RBP + -0x40],XMM7
LAB_001923d2:
LEA R14,[RBP + -0x30]
MOV qword ptr [R14 + 0x10],RDI
LEA RAX,[RBP + 0x10]
MOV qword ptr [R14 + 0x8],RAX
MOV RAX,0x3000000008
MOV qword ptr [R14],RAX
MOV R15,qword ptr [0x00485fa0]
MOV RDI,qword ptr [R15]
LEA RDX,[0x1dd4f2]
MOV ESI,0x1
XOR EAX,EAX
CALL 0x001291e0
MOV RDI,qword ptr [R15]
MOV ESI,0x1
MOV RDX,RBX
MOV RCX,R14
CALL 0x00129730
MOV RDI,qword ptr [R15]
LEA RDX,[0x1e13cf]
MOV ESI,0x1
XOR EAX,EAX
CALL 0x001291e0
MOV RDI,qword ptr [R15]
CALL 0x001293f0
ADD RSP,0xc8
POP RBX
POP R14
POP R15
POP RBP
RET
|
void diag(int8 param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5,int8 param_6,int8 param_7,int8 param_8,
int8 param_9,int8 param_10,int8 param_11,int8 param_12,
int8 param_13,int8 param_14)
{
int *puVar1;
char in_AL;
int1 local_e8 [8];
int8 local_e0;
int8 local_d8;
int8 local_d0;
int8 local_c8;
int8 local_c0;
int8 local_b8;
int8 local_a8;
int8 local_98;
int8 local_88;
int8 local_78;
int8 local_68;
int8 local_58;
int8 local_48;
int8 local_38;
int1 *local_30;
int1 *local_28;
puVar1 = PTR_stdout_00485fa0;
local_28 = local_e8;
if (in_AL != '\0') {
local_b8 = param_1;
local_a8 = param_2;
local_98 = param_3;
local_88 = param_4;
local_78 = param_5;
local_68 = param_6;
local_58 = param_7;
local_48 = param_8;
}
local_30 = &stack0x00000008;
local_38 = 0x3000000008;
local_e0 = param_10;
local_d8 = param_11;
local_d0 = param_12;
local_c8 = param_13;
local_c0 = param_14;
__fprintf_chk(*(int8 *)PTR_stdout_00485fa0,1,&DAT_001dd4f2);
__vfprintf_chk(*(int8 *)puVar1,1,param_9,&local_38);
__fprintf_chk(*(int8 *)puVar1,1,&DAT_001e13cf);
fflush(*(FILE **)puVar1);
return;
}
| |
22,167 | StartTree::ClusterTree<float>::addCluster(unsigned long, float, unsigned long, float) | iqtree3/utils/bionj2.cpp | Cluster<T>& addCluster(size_t a, T aLength, size_t b, T bLength) {
push_back(Cluster<T>());
Cluster<T>& cluster = back();
cluster.links.emplace_back(a, aLength);
cluster.links.emplace_back(b, bLength);
cluster.countOfExteriorNodes = at(a).countOfExteriorNodes + at(b).countOfExteriorNodes;
return cluster;
} | O0 | cpp | StartTree::ClusterTree<float>::addCluster(unsigned long, float, unsigned long, float):
subq $0x98, %rsp
movq %rdi, 0x90(%rsp)
movq %rsi, 0x88(%rsp)
movss %xmm0, 0x84(%rsp)
movq %rdx, 0x78(%rsp)
movss %xmm1, 0x74(%rsp)
movq 0x90(%rsp), %rax
movq %rax, 0x8(%rsp)
leaq 0x30(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x42b40
movq 0x8(%rsp), %rdi
movq 0x10(%rsp), %rsi
callq 0x42b10
jmp 0x427c8
leaq 0x30(%rsp), %rdi
callq 0x416f0
movq 0x8(%rsp), %rdi
callq 0x42b80
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
addq $0x28, %rdi
leaq 0x88(%rsp), %rsi
leaq 0x84(%rsp), %rdx
callq 0x42bc0
movq 0x18(%rsp), %rdi
addq $0x28, %rdi
leaq 0x78(%rsp), %rsi
leaq 0x74(%rsp), %rdx
callq 0x42bc0
movq 0x8(%rsp), %rdi
movq 0x88(%rsp), %rsi
callq 0x42c50
movq 0x8(%rsp), %rdi
movq (%rax), %rax
movq %rax, (%rsp)
movq 0x78(%rsp), %rsi
callq 0x42c50
movq (%rsp), %rcx
addq (%rax), %rcx
movq 0x18(%rsp), %rax
movq %rcx, (%rax)
movq 0x18(%rsp), %rax
addq $0x98, %rsp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x28(%rsp)
movl %eax, 0x24(%rsp)
leaq 0x30(%rsp), %rdi
callq 0x416f0
movq 0x28(%rsp), %rdi
callq 0x37770
nopl (%rax)
| _ZN9StartTree11ClusterTreeIfE10addClusterEmfmf:
sub rsp, 98h
mov [rsp+98h+var_8], rdi
mov [rsp+98h+var_10], rsi
movss [rsp+98h+var_14], xmm0
mov [rsp+98h+var_20], rdx
movss [rsp+98h+var_24], xmm1
mov rax, [rsp+98h+var_8]
mov [rsp+98h+var_90], rax
lea rdi, [rsp+98h+var_68]
mov [rsp+98h+var_88], rdi
call _ZN9StartTree7ClusterIfEC2Ev; StartTree::Cluster<float>::Cluster(void)
mov rdi, [rsp+98h+var_90]
mov rsi, [rsp+98h+var_88]
call _ZNSt6vectorIN9StartTree7ClusterIfEESaIS2_EE9push_backEOS2_; std::vector<StartTree::Cluster<float>>::push_back(StartTree::Cluster<float>&&)
jmp short $+2
loc_427C8:
lea rdi, [rsp+98h+var_68]
call _ZN9StartTree7ClusterIfED2Ev; StartTree::Cluster<float>::~Cluster()
mov rdi, [rsp+98h+var_90]
call _ZNSt6vectorIN9StartTree7ClusterIfEESaIS2_EE4backEv; std::vector<StartTree::Cluster<float>>::back(void)
mov [rsp+98h+var_80], rax
mov rdi, [rsp+98h+var_80]
add rdi, 28h ; '('
lea rsi, [rsp+98h+var_10]
lea rdx, [rsp+98h+var_14]
call _ZNSt6vectorIN9StartTree4LinkIfEESaIS2_EE12emplace_backIJRmRfEEERS2_DpOT_; std::vector<StartTree::Link<float>>::emplace_back<ulong &,float &>(ulong &,float &)
mov rdi, [rsp+98h+var_80]
add rdi, 28h ; '('
lea rsi, [rsp+98h+var_20]
lea rdx, [rsp+98h+var_24]
call _ZNSt6vectorIN9StartTree4LinkIfEESaIS2_EE12emplace_backIJRmRfEEERS2_DpOT_; std::vector<StartTree::Link<float>>::emplace_back<ulong &,float &>(ulong &,float &)
mov rdi, [rsp+98h+var_90]
mov rsi, [rsp+98h+var_10]
call _ZNSt6vectorIN9StartTree7ClusterIfEESaIS2_EE2atEm; std::vector<StartTree::Cluster<float>>::at(ulong)
mov rdi, [rsp+98h+var_90]
mov rax, [rax]
mov [rsp+98h+var_98], rax
mov rsi, [rsp+98h+var_20]
call _ZNSt6vectorIN9StartTree7ClusterIfEESaIS2_EE2atEm; std::vector<StartTree::Cluster<float>>::at(ulong)
mov rcx, [rsp+98h+var_98]
add rcx, [rax]
mov rax, [rsp+98h+var_80]
mov [rax], rcx
mov rax, [rsp+98h+var_80]
add rsp, 98h
retn
mov rcx, rax
mov eax, edx
mov [rsp+arg_20], rcx
mov [rsp+arg_1C], eax
lea rdi, [rsp+arg_28]
call _ZN9StartTree7ClusterIfED2Ev; StartTree::Cluster<float>::~Cluster()
mov rdi, [rsp+arg_20]
call __Unwind_Resume
| _QWORD * StartTree::ClusterTree<float>::addCluster(long long a1, long long a2, long long a3, float a4, float a5)
{
long long v6; // [rsp+0h] [rbp-98h]
_QWORD *v7; // [rsp+18h] [rbp-80h]
_BYTE v8[68]; // [rsp+30h] [rbp-68h] BYREF
float v9; // [rsp+74h] [rbp-24h] BYREF
long long v10; // [rsp+78h] [rbp-20h] BYREF
float v11; // [rsp+84h] [rbp-14h] BYREF
_QWORD v12[2]; // [rsp+88h] [rbp-10h] BYREF
v12[1] = a1;
v12[0] = a2;
v11 = a4;
v10 = a3;
v9 = a5;
StartTree::Cluster<float>::Cluster();
std::vector<StartTree::Cluster<float>>::push_back(a1, v8);
StartTree::Cluster<float>::~Cluster((long long)v8);
v7 = (_QWORD *)std::vector<StartTree::Cluster<float>>::back(a1);
std::vector<StartTree::Link<float>>::emplace_back<unsigned long &,float &>(v7 + 5, v12, &v11);
std::vector<StartTree::Link<float>>::emplace_back<unsigned long &,float &>(v7 + 5, &v10, &v9);
v6 = *(_QWORD *)std::vector<StartTree::Cluster<float>>::at(a1, v12[0]);
*v7 = *(_QWORD *)std::vector<StartTree::Cluster<float>>::at(a1, v10) + v6;
return v7;
}
| addCluster:
SUB RSP,0x98
MOV qword ptr [RSP + 0x90],RDI
MOV qword ptr [RSP + 0x88],RSI
MOVSS dword ptr [RSP + 0x84],XMM0
MOV qword ptr [RSP + 0x78],RDX
MOVSS dword ptr [RSP + 0x74],XMM1
MOV RAX,qword ptr [RSP + 0x90]
MOV qword ptr [RSP + 0x8],RAX
LEA RDI,[RSP + 0x30]
MOV qword ptr [RSP + 0x10],RDI
CALL 0x00142b40
MOV RDI,qword ptr [RSP + 0x8]
MOV RSI,qword ptr [RSP + 0x10]
LAB_001427c1:
CALL 0x00142b10
LAB_001427c6:
JMP 0x001427c8
LAB_001427c8:
LEA RDI,[RSP + 0x30]
CALL 0x001416f0
MOV RDI,qword ptr [RSP + 0x8]
CALL 0x00142b80
MOV qword ptr [RSP + 0x18],RAX
MOV RDI,qword ptr [RSP + 0x18]
ADD RDI,0x28
LEA RSI,[RSP + 0x88]
LEA RDX,[RSP + 0x84]
CALL 0x00142bc0
MOV RDI,qword ptr [RSP + 0x18]
ADD RDI,0x28
LEA RSI,[RSP + 0x78]
LEA RDX,[RSP + 0x74]
CALL 0x00142bc0
MOV RDI,qword ptr [RSP + 0x8]
MOV RSI,qword ptr [RSP + 0x88]
CALL 0x00142c50
MOV RDI,qword ptr [RSP + 0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP],RAX
MOV RSI,qword ptr [RSP + 0x78]
CALL 0x00142c50
MOV RCX,qword ptr [RSP]
ADD RCX,qword ptr [RAX]
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RSP + 0x18]
ADD RSP,0x98
RET
|
/* StartTree::ClusterTree<float>::addCluster(unsigned long, float, unsigned long, float) */
long * __thiscall
StartTree::ClusterTree<float>::addCluster
(ClusterTree<float> *this,ulong param_1,float param_2,ulong param_3,float param_4)
{
long lVar1;
long *plVar2;
long *plVar3;
Cluster<float> local_68 [68];
float local_24;
ulong local_20;
float local_14;
ulong local_10;
ClusterTree<float> *local_8;
local_24 = param_4;
local_20 = param_3;
local_14 = param_2;
local_10 = param_1;
local_8 = this;
Cluster<float>::Cluster(local_68);
/* try { // try from 001427c1 to 001427c5 has its CatchHandler @ 0014285b */
std::vector<StartTree::Cluster<float>,std::allocator<StartTree::Cluster<float>>>::push_back
((vector<StartTree::Cluster<float>,std::allocator<StartTree::Cluster<float>>> *)this,
(Cluster *)local_68);
Cluster<float>::~Cluster(local_68);
plVar2 = (long *)std::vector<StartTree::Cluster<float>,std::allocator<StartTree::Cluster<float>>>
::back((vector<StartTree::Cluster<float>,std::allocator<StartTree::Cluster<float>>>
*)this);
std::vector<StartTree::Link<float>,std::allocator<StartTree::Link<float>>>::
emplace_back<unsigned_long&,float&>
((vector<StartTree::Link<float>,std::allocator<StartTree::Link<float>>> *)(plVar2 + 5),
&local_10,&local_14);
std::vector<StartTree::Link<float>,std::allocator<StartTree::Link<float>>>::
emplace_back<unsigned_long&,float&>
((vector<StartTree::Link<float>,std::allocator<StartTree::Link<float>>> *)(plVar2 + 5),
&local_20,&local_24);
plVar3 = (long *)std::vector<StartTree::Cluster<float>,std::allocator<StartTree::Cluster<float>>>
::at((vector<StartTree::Cluster<float>,std::allocator<StartTree::Cluster<float>>>
*)this,local_10);
lVar1 = *plVar3;
plVar3 = (long *)std::vector<StartTree::Cluster<float>,std::allocator<StartTree::Cluster<float>>>
::at((vector<StartTree::Cluster<float>,std::allocator<StartTree::Cluster<float>>>
*)this,local_20);
*plVar2 = lVar1 + *plVar3;
return plVar2;
}
| |
22,168 | string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int>> const&) | monkey531[P]llama/common/common.cpp | std::string string_from(const struct llama_context * ctx, const std::vector<llama_token> & tokens) {
std::stringstream buf;
buf << "[ ";
bool first = true;
for (const auto & token : tokens) {
if (!first) {
buf << ", ";
} else {
first = false;
}
auto detokenized = common_token_to_piece(ctx, token);
detokenized.erase(
std::remove_if(
detokenized.begin(),
detokenized.end(),
[](const unsigned char c) { return !std::isprint(c); }),
detokenized.end());
buf << "'" << detokenized << "'"
<< ":" << std::to_string(token);
}
buf << " ]";
return buf.str();
} | O2 | cpp | string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int>> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1f8, %rsp # imm = 0x1F8
movq %rdx, %rbx
movq %rsi, 0x38(%rsp)
movq %rdi, %r14
leaq 0x70(%rsp), %rdi
callq 0x24670
leaq 0x80(%rsp), %rdi
leaq 0x5f06a(%rip), %rsi # 0xbedb3
callq 0x248c0
movq (%rbx), %r15
movq 0x8(%rbx), %rax
movq %rax, 0x40(%rsp)
movb $0x1, %al
leaq 0x10(%rsp), %r13
movq %r14, 0x30(%rsp)
cmpq 0x40(%rsp), %r15
je 0x5ff2b
testb $0x1, %al
jne 0x5fd89
leaq 0x80(%rsp), %rdi
leaq 0x5f9d3(%rip), %rsi # 0xbf757
callq 0x248c0
movq %r15, 0x48(%rsp)
movl (%r15), %edx
movq %r13, %rdi
movq 0x38(%rsp), %rsi
pushq $0x1
popq %rcx
callq 0x5ffab
movq 0x10(%rsp), %r14
movq 0x18(%rsp), %r12
leaq (%r14,%r12), %rbp
movq %r12, %r13
sarq $0x2, %r13
movq %r12, %rbx
movq %r14, 0x8(%rsp)
testq %r13, %r13
jle 0x5fe10
movq %r14, %rdi
callq 0x64476
testb %al, %al
jne 0x5fe58
leaq 0x1(%r14), %r15
movq %r15, %rdi
callq 0x64476
testb %al, %al
jne 0x5fe5b
leaq 0x2(%r14), %r15
movq %r15, %rdi
callq 0x64476
testb %al, %al
jne 0x5fe5b
leaq 0x3(%r14), %r15
movq %r15, %rdi
callq 0x64476
testb %al, %al
jne 0x5fe5b
addq $0x4, %r14
decq %r13
addq $-0x4, %rbx
jmp 0x5fdbe
cmpq $0x1, %rbx
leaq 0x10(%rsp), %r13
je 0x5fe45
cmpq $0x2, %rbx
je 0x5fe36
cmpq $0x3, %rbx
jne 0x5fe93
movq %r14, %rdi
callq 0x64476
testb %al, %al
jne 0x5fe53
incq %r14
movq %r14, %rdi
callq 0x64476
testb %al, %al
jne 0x5fe53
incq %r14
movq %r14, %rdi
callq 0x64476
testb %al, %al
cmoveq %rbp, %r14
movq %r14, %r15
jmp 0x5fe60
movq %r14, %r15
leaq 0x10(%rsp), %r13
cmpq %rbp, %r15
je 0x5fe93
movq %r15, %r14
incq %r15
cmpq %rbp, %r15
je 0x5fe87
movq %r15, %rdi
callq 0x64476
testb %al, %al
jne 0x5fe68
movb (%r15), %al
movb %al, (%r14)
incq %r14
jmp 0x5fe68
movq 0x10(%rsp), %rax
movq 0x18(%rsp), %r12
jmp 0x5fe9b
movq %rbp, %r14
movq 0x8(%rsp), %rax
addq %rax, %r12
movq %r13, %rdi
movq %r14, %rsi
movq %r12, %rdx
callq 0x241c0
leaq 0x80(%rsp), %rdi
leaq 0x5dfea(%rip), %rbx # 0xbdea5
movq %rbx, %rsi
callq 0x248c0
movq 0x30(%rsp), %r14
movq 0x48(%rsp), %r15
leaq 0x50(%rsp), %r12
movq %rax, %rdi
movq %r13, %rsi
callq 0x247f0
movq %rax, %rdi
movq %rbx, %rsi
callq 0x248c0
movq %rax, %rdi
leaq 0x5f9b0(%rip), %rsi # 0xbf8a2
callq 0x248c0
movq %rax, %rbx
movl (%r15), %esi
movq %r12, %rdi
callq 0x49a2f
movq %rbx, %rdi
movq %r12, %rsi
callq 0x247f0
movq %r12, %rdi
callq 0x25298
movq %r13, %rdi
callq 0x25298
addq $0x4, %r15
xorl %eax, %eax
jmp 0x5fd66
leaq 0x5ee84(%rip), %rsi # 0xbedb6
leaq 0x80(%rsp), %rdi
callq 0x248c0
leaq 0x88(%rsp), %rsi
movq %r14, %rdi
callq 0x24e10
leaq 0x70(%rsp), %rdi
callq 0x246c0
movq %r14, %rax
addq $0x1f8, %rsp # imm = 0x1F8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5ff85
jmp 0x5ff85
jmp 0x5ff85
jmp 0x5ff8c
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x25298
jmp 0x5ff8f
movq %rax, %rbx
jmp 0x5ff99
jmp 0x5ff8c
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x25298
leaq 0x70(%rsp), %rdi
callq 0x246c0
movq %rbx, %rdi
callq 0x25010
| _Z11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 1F8h
mov rbx, rdx
mov [rsp+228h+var_1F0], rsi
mov r14, rdi
lea rdi, [rsp+228h+var_1B8]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::basic_stringstream(void)
lea rdi, [rsp+228h+var_1A8]
lea rsi, asc_BEDB3; "[ "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov r15, [rbx]
mov rax, [rbx+8]
mov [rsp+228h+var_1E8], rax
mov al, 1
lea r13, [rsp+228h+var_218]
mov [rsp+228h+var_1F8], r14
loc_5FD66:
cmp r15, [rsp+228h+var_1E8]
jz loc_5FF2B
test al, 1
jnz short loc_5FD89
lea rdi, [rsp+228h+var_1A8]
lea rsi, aZuD+6; ", "
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
loc_5FD89:
mov [rsp+228h+var_1E0], r15
mov edx, [r15]
mov rdi, r13; void *
mov rsi, [rsp+228h+var_1F0]
push 1
pop rcx
call _Z21common_token_to_pieceB5cxx11PK13llama_contextib; common_token_to_piece(llama_context const*,int,bool)
mov r14, [rsp+228h+var_218]
mov r12, [rsp+228h+var_210]
lea rbp, [r14+r12]
mov r13, r12
sar r13, 2
mov rbx, r12
mov [rsp+228h+var_220], r14
loc_5FDBE:
test r13, r13
jle short loc_5FE10
mov rdi, r14
call _ZN9__gnu_cxx5__ops10_Iter_predIZ11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEEE3$_0EclINS_17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEEbT_; __gnu_cxx::__ops::_Iter_pred<string_from(llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>)
test al, al
jnz loc_5FE58
lea r15, [r14+1]
mov rdi, r15
call _ZN9__gnu_cxx5__ops10_Iter_predIZ11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEEE3$_0EclINS_17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEEbT_; __gnu_cxx::__ops::_Iter_pred<string_from(llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>)
test al, al
jnz short loc_5FE5B
lea r15, [r14+2]
mov rdi, r15
call _ZN9__gnu_cxx5__ops10_Iter_predIZ11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEEE3$_0EclINS_17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEEbT_; __gnu_cxx::__ops::_Iter_pred<string_from(llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>)
test al, al
jnz short loc_5FE5B
lea r15, [r14+3]
mov rdi, r15
call _ZN9__gnu_cxx5__ops10_Iter_predIZ11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEEE3$_0EclINS_17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEEbT_; __gnu_cxx::__ops::_Iter_pred<string_from(llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>)
test al, al
jnz short loc_5FE5B
add r14, 4
dec r13
add rbx, 0FFFFFFFFFFFFFFFCh
jmp short loc_5FDBE
loc_5FE10:
cmp rbx, 1
lea r13, [rsp+228h+var_218]
jz short loc_5FE45
cmp rbx, 2
jz short loc_5FE36
cmp rbx, 3
jnz short loc_5FE93
mov rdi, r14
call _ZN9__gnu_cxx5__ops10_Iter_predIZ11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEEE3$_0EclINS_17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEEbT_; __gnu_cxx::__ops::_Iter_pred<string_from(llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>)
test al, al
jnz short loc_5FE53
inc r14
loc_5FE36:
mov rdi, r14
call _ZN9__gnu_cxx5__ops10_Iter_predIZ11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEEE3$_0EclINS_17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEEbT_; __gnu_cxx::__ops::_Iter_pred<string_from(llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>)
test al, al
jnz short loc_5FE53
inc r14
loc_5FE45:
mov rdi, r14
call _ZN9__gnu_cxx5__ops10_Iter_predIZ11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEEE3$_0EclINS_17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEEbT_; __gnu_cxx::__ops::_Iter_pred<string_from(llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>)
test al, al
cmovz r14, rbp
loc_5FE53:
mov r15, r14
jmp short loc_5FE60
loc_5FE58:
mov r15, r14
loc_5FE5B:
lea r13, [rsp+228h+var_218]
loc_5FE60:
cmp r15, rbp
jz short loc_5FE93
mov r14, r15
loc_5FE68:
inc r15
cmp r15, rbp
jz short loc_5FE87
mov rdi, r15
call _ZN9__gnu_cxx5__ops10_Iter_predIZ11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEEE3$_0EclINS_17__normal_iteratorIPcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEEbT_; __gnu_cxx::__ops::_Iter_pred<string_from(llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(__gnu_cxx::__normal_iterator<char *,std::string>)
test al, al
jnz short loc_5FE68
mov al, [r15]
mov [r14], al
inc r14
jmp short loc_5FE68
loc_5FE87:
mov rax, [rsp+228h+var_218]
mov r12, [rsp+228h+var_210]
jmp short loc_5FE9B
loc_5FE93:
mov r14, rbp
mov rax, [rsp+228h+var_220]
loc_5FE9B:
add r12, rax
mov rdi, r13
mov rsi, r14
mov rdx, r12
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5eraseEN9__gnu_cxx17__normal_iteratorIPKcS4_EES9_; std::string::erase(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>)
lea rdi, [rsp+228h+var_1A8]
lea rbx, asc_BDEA3+2; "'"
mov rsi, rbx
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov r14, [rsp+228h+var_1F8]
mov r15, [rsp+228h+var_1E0]
lea r12, [rsp+228h+var_1D8]
mov rdi, rax
mov rsi, r13
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov rdi, rax
mov rsi, rbx
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov rdi, rax
lea rsi, aArgumentNeedle_0+11h; ":"
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
mov rbx, rax
mov esi, [r15]; int
mov rdi, r12; this
call _ZNSt7__cxx119to_stringEi; std::to_string(int)
mov rdi, rbx
mov rsi, r12
call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&)
mov rdi, r12; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
mov rdi, r13; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
add r15, 4
xor eax, eax
jmp loc_5FD66
loc_5FF2B:
lea rsi, asc_BEDB6; " ]"
lea rdi, [rsp+228h+var_1A8]
call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*)
lea rsi, [rsp+228h+var_1A0]
mov rdi, r14
call __ZNKSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void)
lea rdi, [rsp+228h+var_1B8]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED1Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream()
mov rax, r14
add rsp, 1F8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_5FF85
jmp short loc_5FF85
jmp short loc_5FF85
jmp short loc_5FF8C
mov rbx, rax
lea rdi, [rsp+arg_48]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
jmp short loc_5FF8F
loc_5FF85:
mov rbx, rax
jmp short loc_5FF99
jmp short $+2
loc_5FF8C:
mov rbx, rax
loc_5FF8F:
lea rdi, [rsp+arg_8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
loc_5FF99:
lea rdi, [rsp+arg_68]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED1Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream()
mov rdi, rbx
call __Unwind_Resume
| long long string_from[abi:cxx11](long long a1, long long a2, int **a3)
{
long long v4; // r14
int *v5; // r15
char v6; // al
long long v7; // rsi
_BYTE *v8; // r14
long long v9; // r12
_BYTE *v10; // rbp
long long v11; // r13
long long v12; // rbx
_BYTE *v13; // r15
_BYTE *v14; // r14
_BYTE *v15; // rax
long long v16; // rax
int *v17; // r15
long long v18; // rax
long long v19; // rax
long long v20; // rbx
_BYTE *v22; // [rsp+8h] [rbp-220h]
_BYTE *v23; // [rsp+10h] [rbp-218h] BYREF
long long v24; // [rsp+18h] [rbp-210h]
long long v25; // [rsp+30h] [rbp-1F8h]
long long v26; // [rsp+38h] [rbp-1F0h]
int *v27; // [rsp+40h] [rbp-1E8h]
int *v28; // [rsp+48h] [rbp-1E0h]
_BYTE v29[32]; // [rsp+50h] [rbp-1D8h] BYREF
_BYTE v30[16]; // [rsp+70h] [rbp-1B8h] BYREF
char v31[8]; // [rsp+80h] [rbp-1A8h] BYREF
char v32[416]; // [rsp+88h] [rbp-1A0h] BYREF
v26 = a2;
v4 = a1;
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::basic_stringstream(v30);
std::operator<<<std::char_traits<char>>(v31, "[ ");
v5 = *a3;
v27 = a3[1];
v6 = 1;
v25 = a1;
while ( v5 != v27 )
{
if ( (v6 & 1) == 0 )
std::operator<<<std::char_traits<char>>(v31, ", ");
v28 = v5;
v7 = v26;
common_token_to_piece[abi:cxx11](&v23);
v8 = v23;
v9 = v24;
v10 = &v23[v24];
v11 = v24 >> 2;
v12 = v24;
v22 = v23;
while ( 1 )
{
if ( v11 <= 0 )
{
switch ( v12 )
{
case 1LL:
LABEL_19:
if ( !(unsigned __int8)__gnu_cxx::__ops::_Iter_pred<string_from[abi:cxx11](llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(
v8,
v7) )
v8 = v10;
break;
case 2LL:
goto LABEL_17;
case 3LL:
if ( !(unsigned __int8)__gnu_cxx::__ops::_Iter_pred<string_from[abi:cxx11](llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(
v8,
v7) )
{
++v8;
LABEL_17:
if ( !(unsigned __int8)__gnu_cxx::__ops::_Iter_pred<string_from[abi:cxx11](llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(
v8,
v7) )
{
++v8;
goto LABEL_19;
}
}
break;
default:
LABEL_29:
v14 = v10;
v15 = v22;
goto LABEL_30;
}
v13 = v8;
goto LABEL_23;
}
if ( (unsigned __int8)__gnu_cxx::__ops::_Iter_pred<string_from[abi:cxx11](llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(
v8,
v7) )
break;
v13 = v8 + 1;
if ( (unsigned __int8)__gnu_cxx::__ops::_Iter_pred<string_from[abi:cxx11](llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(
v8 + 1,
v7) )
goto LABEL_23;
v13 = v8 + 2;
if ( (unsigned __int8)__gnu_cxx::__ops::_Iter_pred<string_from[abi:cxx11](llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(
v8 + 2,
v7) )
goto LABEL_23;
v13 = v8 + 3;
if ( (unsigned __int8)__gnu_cxx::__ops::_Iter_pred<string_from[abi:cxx11](llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(
v8 + 3,
v7) )
goto LABEL_23;
v8 += 4;
--v11;
v12 -= 4LL;
}
v13 = v8;
LABEL_23:
if ( v13 == v10 )
goto LABEL_29;
v14 = v13;
while ( ++v13 != v10 )
{
if ( !(unsigned __int8)__gnu_cxx::__ops::_Iter_pred<string_from[abi:cxx11](llama_context const*,std::vector<int> const&)::$_0>::operator()<__gnu_cxx::__normal_iterator<char *,std::string>>(
v13,
v7) )
*v14++ = *v13;
}
v15 = v23;
v9 = v24;
LABEL_30:
std::string::erase(&v23, v14, &v15[v9]);
v16 = std::operator<<<std::char_traits<char>>(v31, "'");
v4 = v25;
v17 = v28;
v18 = std::operator<<<char>(v16, &v23);
v19 = std::operator<<<std::char_traits<char>>(v18, "'");
v20 = std::operator<<<std::char_traits<char>>(v19, ":");
std::to_string((std::__cxx11 *)v29, *v17);
std::operator<<<char>(v20, v29);
std::string::~string(v29);
std::string::~string(&v23);
v5 = v17 + 1;
v6 = 0;
}
std::operator<<<std::char_traits<char>>(v31, " ]");
std::stringbuf::str(v4, v32);
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream(v30);
return v4;
}
| string_from[abi:cxx11]:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x1f8
MOV RBX,RDX
MOV qword ptr [RSP + 0x38],RSI
MOV R14,RDI
LEA RDI,[RSP + 0x70]
CALL 0x00124670
LEA RDI,[RSP + 0x80]
LAB_0015fd42:
LEA RSI,[0x1bedb3]
CALL 0x001248c0
MOV R15,qword ptr [RBX]
MOV RAX,qword ptr [RBX + 0x8]
MOV qword ptr [RSP + 0x40],RAX
MOV AL,0x1
LEA R13,[RSP + 0x10]
MOV qword ptr [RSP + 0x30],R14
LAB_0015fd66:
CMP R15,qword ptr [RSP + 0x40]
JZ 0x0015ff2b
TEST AL,0x1
JNZ 0x0015fd89
LAB_0015fd75:
LEA RDI,[RSP + 0x80]
LEA RSI,[0x1bf757]
CALL 0x001248c0
LAB_0015fd89:
MOV qword ptr [RSP + 0x48],R15
MOV EDX,dword ptr [R15]
LAB_0015fd91:
MOV RDI,R13
MOV RSI,qword ptr [RSP + 0x38]
PUSH 0x1
POP RCX
CALL 0x0015ffab
MOV R14,qword ptr [RSP + 0x10]
MOV R12,qword ptr [RSP + 0x18]
LEA RBP,[R14 + R12*0x1]
MOV R13,R12
SAR R13,0x2
MOV RBX,R12
MOV qword ptr [RSP + 0x8],R14
LAB_0015fdbe:
TEST R13,R13
JLE 0x0015fe10
MOV RDI,R14
CALL 0x00164476
TEST AL,AL
JNZ 0x0015fe58
LEA R15,[R14 + 0x1]
MOV RDI,R15
CALL 0x00164476
TEST AL,AL
JNZ 0x0015fe5b
LEA R15,[R14 + 0x2]
MOV RDI,R15
CALL 0x00164476
TEST AL,AL
JNZ 0x0015fe5b
LEA R15,[R14 + 0x3]
MOV RDI,R15
CALL 0x00164476
TEST AL,AL
JNZ 0x0015fe5b
ADD R14,0x4
DEC R13
ADD RBX,-0x4
JMP 0x0015fdbe
LAB_0015fe10:
CMP RBX,0x1
LEA R13,[RSP + 0x10]
JZ 0x0015fe45
CMP RBX,0x2
JZ 0x0015fe36
CMP RBX,0x3
JNZ 0x0015fe93
MOV RDI,R14
CALL 0x00164476
TEST AL,AL
JNZ 0x0015fe53
INC R14
LAB_0015fe36:
MOV RDI,R14
CALL 0x00164476
TEST AL,AL
JNZ 0x0015fe53
INC R14
LAB_0015fe45:
MOV RDI,R14
CALL 0x00164476
TEST AL,AL
CMOVZ R14,RBP
LAB_0015fe53:
MOV R15,R14
JMP 0x0015fe60
LAB_0015fe58:
MOV R15,R14
LAB_0015fe5b:
LEA R13,[RSP + 0x10]
LAB_0015fe60:
CMP R15,RBP
JZ 0x0015fe93
MOV R14,R15
LAB_0015fe68:
INC R15
CMP R15,RBP
JZ 0x0015fe87
MOV RDI,R15
CALL 0x00164476
TEST AL,AL
JNZ 0x0015fe68
MOV AL,byte ptr [R15]
MOV byte ptr [R14],AL
INC R14
JMP 0x0015fe68
LAB_0015fe87:
MOV RAX,qword ptr [RSP + 0x10]
MOV R12,qword ptr [RSP + 0x18]
JMP 0x0015fe9b
LAB_0015fe93:
MOV R14,RBP
MOV RAX,qword ptr [RSP + 0x8]
LAB_0015fe9b:
ADD R12,RAX
LAB_0015fe9e:
MOV RDI,R13
MOV RSI,R14
MOV RDX,R12
CALL 0x001241c0
LAB_0015feac:
LEA RDI,[RSP + 0x80]
LEA RBX,[0x1bdea5]
MOV RSI,RBX
CALL 0x001248c0
MOV R14,qword ptr [RSP + 0x30]
MOV R15,qword ptr [RSP + 0x48]
LEA R12,[RSP + 0x50]
MOV RDI,RAX
MOV RSI,R13
CALL 0x001247f0
MOV RDI,RAX
MOV RSI,RBX
CALL 0x001248c0
MOV RDI,RAX
LEA RSI,[0x1bf8a2]
CALL 0x001248c0
MOV RBX,RAX
MOV ESI,dword ptr [R15]
LAB_0015fefd:
MOV RDI,R12
CALL 0x00149a2f
LAB_0015ff05:
MOV RDI,RBX
MOV RSI,R12
CALL 0x001247f0
MOV RDI,R12
CALL 0x00125298
MOV RDI,R13
CALL 0x00125298
ADD R15,0x4
XOR EAX,EAX
JMP 0x0015fd66
LAB_0015ff2b:
LEA RSI,[0x1bedb6]
LEA RDI,[RSP + 0x80]
CALL 0x001248c0
LEA RSI,[RSP + 0x88]
MOV RDI,R14
CALL 0x00124e10
LAB_0015ff4f:
LEA RDI,[RSP + 0x70]
CALL 0x001246c0
MOV RAX,R14
ADD RSP,0x1f8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int> > const&) */
llama_context * string_from_abi_cxx11_(llama_context *param_1,vector *param_2)
{
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::__0>
*p_Var1;
bool bVar2;
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::__0>
*p_Var3;
ostream *poVar4;
int8 *in_RDX;
long lVar5;
long lVar6;
long lVar7;
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::__0>
*p_Var8;
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::__0>
*p_Var9;
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::__0>
*p_Var10;
int *piVar11;
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::__0>
*local_218;
long local_210;
llama_context *local_1f8;
vector *local_1f0;
int *local_1e8;
int *local_1e0;
__cxx11 local_1d8 [32];
stringstream local_1b8 [16];
ostream local_1a8 [376];
local_1f0 = param_2;
std::__cxx11::stringstream::stringstream(local_1b8);
/* try { // try from 0015fd42 to 0015fd4d has its CatchHandler @ 0015ff6e */
std::operator<<(local_1a8,"[ ");
piVar11 = (int *)*in_RDX;
local_1e8 = (int *)in_RDX[1];
bVar2 = true;
local_1f8 = param_1;
do {
if (piVar11 == local_1e8) {
/* try { // try from 0015ff2b to 0015ff4e has its CatchHandler @ 0015ff70 */
std::operator<<(local_1a8," ]");
std::__cxx11::stringbuf::str();
std::__cxx11::stringstream::~stringstream(local_1b8);
return param_1;
}
if (!bVar2) {
/* try { // try from 0015fd75 to 0015fd88 has its CatchHandler @ 0015ff72 */
std::operator<<(local_1a8,", ");
}
local_1e0 = piVar11;
/* try { // try from 0015fd91 to 0015fda0 has its CatchHandler @ 0015ff85 */
common_token_to_piece_abi_cxx11_((llama_context *)&local_218,(int)local_1f0,SUB41(*piVar11,0));
lVar6 = local_210;
p_Var3 = local_218;
p_Var1 = local_218 + local_210;
lVar5 = local_210;
p_Var8 = local_218;
for (lVar7 = local_210 >> 2; p_Var10 = p_Var1, p_Var9 = p_Var8, 0 < lVar7; lVar7 = lVar7 + -1) {
bVar2 = __gnu_cxx::__ops::
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::$_0>
::operator()(p_Var8);
if (bVar2) goto LAB_0015fe60;
bVar2 = __gnu_cxx::__ops::
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::$_0>
::operator()(p_Var8 + 1);
p_Var9 = p_Var8 + 1;
if (bVar2) goto LAB_0015fe60;
bVar2 = __gnu_cxx::__ops::
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::$_0>
::operator()(p_Var8 + 2);
p_Var9 = p_Var8 + 2;
if (bVar2) goto LAB_0015fe60;
bVar2 = __gnu_cxx::__ops::
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::$_0>
::operator()(p_Var8 + 3);
p_Var9 = p_Var8 + 3;
if (bVar2) goto LAB_0015fe60;
p_Var8 = p_Var8 + 4;
lVar5 = lVar5 + -4;
}
if (lVar5 == 1) {
LAB_0015fe45:
bVar2 = __gnu_cxx::__ops::
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::$_0>
::operator()(p_Var8);
p_Var9 = p_Var8;
if (!bVar2) {
p_Var9 = p_Var1;
}
LAB_0015fe60:
p_Var8 = p_Var9;
if (p_Var9 != p_Var1) {
while (p_Var8 = p_Var8 + 1, p_Var3 = local_218, lVar6 = local_210, p_Var10 = p_Var9,
p_Var8 != p_Var1) {
bVar2 = __gnu_cxx::__ops::
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::$_0>
::operator()(p_Var8);
if (!bVar2) {
*p_Var9 = *p_Var8;
p_Var9 = p_Var9 + 1;
}
}
}
}
else {
if (lVar5 == 2) {
LAB_0015fe36:
bVar2 = __gnu_cxx::__ops::
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::$_0>
::operator()(p_Var8);
p_Var9 = p_Var8;
if (!bVar2) {
p_Var8 = p_Var8 + 1;
goto LAB_0015fe45;
}
goto LAB_0015fe60;
}
if (lVar5 == 3) {
bVar2 = __gnu_cxx::__ops::
_Iter_pred<string_from[abi:cxx11](llama_context_const*,std::vector<int,std::allocator<int>>const&)::$_0>
::operator()(p_Var8);
if (!bVar2) {
p_Var8 = p_Var8 + 1;
goto LAB_0015fe36;
}
goto LAB_0015fe60;
}
}
/* try { // try from 0015fe9e to 0015feab has its CatchHandler @ 0015ff8a */
std::__cxx11::string::erase((string *)&local_218,p_Var10,p_Var3 + lVar6);
/* try { // try from 0015feac to 0015fef6 has its CatchHandler @ 0015ff8c */
poVar4 = std::operator<<(local_1a8,"\'");
piVar11 = local_1e0;
param_1 = local_1f8;
poVar4 = std::operator<<(poVar4,(string *)&local_218);
poVar4 = std::operator<<(poVar4,"\'");
poVar4 = std::operator<<(poVar4,":");
/* try { // try from 0015fefd to 0015ff04 has its CatchHandler @ 0015ff74 */
std::__cxx11::to_string(local_1d8,*piVar11);
/* try { // try from 0015ff05 to 0015ff0f has its CatchHandler @ 0015ff76 */
std::operator<<(poVar4,(string *)local_1d8);
std::__cxx11::string::~string((string *)local_1d8);
std::__cxx11::string::~string((string *)&local_218);
piVar11 = piVar11 + 1;
bVar2 = false;
} while( true );
}
| |
22,169 | string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int>> const&) | monkey531[P]llama/common/common.cpp | std::string string_from(const struct llama_context * ctx, const std::vector<llama_token> & tokens) {
std::stringstream buf;
buf << "[ ";
bool first = true;
for (const auto & token : tokens) {
if (!first) {
buf << ", ";
} else {
first = false;
}
auto detokenized = common_token_to_piece(ctx, token);
detokenized.erase(
std::remove_if(
detokenized.begin(),
detokenized.end(),
[](const unsigned char c) { return !std::isprint(c); }),
detokenized.end());
buf << "'" << detokenized << "'"
<< ":" << std::to_string(token);
}
buf << " ]";
return buf.str();
} | O3 | cpp | string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int>> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1e8, %rsp # imm = 0x1E8
movq %rdx, %rbx
movq %rsi, 0x58(%rsp)
movq %rdi, 0x48(%rsp)
leaq 0x60(%rsp), %rdi
callq 0x1b650
leaq 0x70(%rsp), %r14
leaq 0x7c7b0(%rip), %rsi # 0xfce03
movl $0x2, %edx
movq %r14, %rdi
callq 0x1ba10
movq (%rbx), %r13
movq 0x8(%rbx), %rax
movq %rax, 0x50(%rsp)
cmpq %rax, %r13
je 0x8092d
movb $0x1, %al
testb $0x1, %al
jne 0x8068f
movl $0x2, %edx
movq %r14, %rdi
leaq 0x7d11d(%rip), %rsi # 0xfd7a7
callq 0x1ba10
movl (%r13), %ebx
movq 0x58(%rsp), %rdi
callq 0x1b7c0
movq %rax, %rdi
callq 0x1c220
leaq 0x8(%rsp), %rdi
movq %rax, %rsi
movl %ebx, %edx
movl $0x1, %ecx
callq 0x837c9
movq 0x8(%rsp), %r15
movq 0x10(%rsp), %rax
leaq (%r15,%rax), %rbx
movq %rax, %r14
sarq $0x2, %r14
movq %r15, %rbp
testq %r14, %r14
jle 0x80737
andq $-0x4, %rax
movq %rax, %rbp
addq %r15, %rbp
incq %r14
leaq 0x3(%r15), %r12
movzbl -0x3(%r12), %edi
callq 0x1c030
testl %eax, %eax
je 0x8078c
movzbl -0x2(%r12), %edi
callq 0x1c030
testl %eax, %eax
je 0x80792
movzbl -0x1(%r12), %edi
callq 0x1c030
testl %eax, %eax
je 0x80798
movzbl (%r12), %edi
callq 0x1c030
testl %eax, %eax
je 0x8079b
decq %r14
addq $0x4, %r12
cmpq $0x1, %r14
jg 0x806e7
movq %rbx, %rax
subq %rbp, %rax
cmpq $0x1, %rax
je 0x80778
cmpq $0x2, %rax
leaq 0x70(%rsp), %r14
je 0x80768
cmpq $0x3, %rax
jne 0x80925
movzbl (%rbp), %edi
callq 0x1c030
testl %eax, %eax
je 0x80787
incq %rbp
movzbl (%rbp), %edi
callq 0x1c030
testl %eax, %eax
je 0x80787
incq %rbp
movzbl (%rbp), %edi
callq 0x1c030
testl %eax, %eax
cmovneq %rbx, %rbp
movq %rbp, %r12
jmp 0x8079b
addq $-0x3, %r12
jmp 0x8079b
addq $-0x2, %r12
jmp 0x8079b
decq %r12
cmpq %rbx, %r12
sete %al
leaq 0x1(%r12), %r14
cmpq %rbx, %r14
sete %cl
orb %al, %cl
jne 0x807d4
movb (%r14), %bpl
movzbl %bpl, %edi
callq 0x1c030
testl %eax, %eax
je 0x807c7
movb %bpl, (%r12)
incq %r12
incq %r14
cmpq %rbx, %r14
jne 0x807b0
movq 0x8(%rsp), %r15
leaq 0x70(%rsp), %r14
movq %r12, %rax
subq %r15, %rax
movq %rax, 0x10(%rsp)
movb $0x0, (%r12)
movl $0x1, %edx
movq %r14, %rdi
leaq 0x7b6eb(%rip), %rsi # 0xfbee3
callq 0x1ba10
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
movq %r14, %rdi
callq 0x1ba10
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
leaq 0x7b6c2(%rip), %rsi # 0xfbee3
callq 0x1ba10
movl $0x1, %edx
movq %r12, %rdi
leaq 0x7d0bd(%rip), %rsi # 0xfd8f2
callq 0x1ba10
movl (%r13), %ebp
movl %ebp, %ebx
negl %ebx
cmovsl %ebp, %ebx
movl $0x1, %r15d
cmpl $0xa, %ebx
jb 0x80896
movl $0x4, %r15d
movl %ebx, %eax
cmpl $0x63, %eax
jbe 0x8088d
cmpl $0x3e7, %eax # imm = 0x3E7
jbe 0x80893
cmpl $0x2710, %eax # imm = 0x2710
jb 0x80896
movl %eax, %ecx
movl $0xd1b71759, %edx # imm = 0xD1B71759
imulq %rdx, %rcx
shrq $0x2d, %rcx
addl $0x4, %r15d
cmpl $0x1869f, %eax # imm = 0x1869F
movl %ecx, %eax
ja 0x80858
addl $-0x3, %r15d
jmp 0x80896
addl $-0x2, %r15d
jmp 0x80896
decl %r15d
shrl $0x1f, %ebp
leal (%r15,%rbp), %esi
leaq 0x38(%rsp), %rax
movq %rax, 0x28(%rsp)
leaq 0x28(%rsp), %rdi
movl $0x2d, %edx
callq 0x1ba40
addq 0x28(%rsp), %rbp
movq %rbp, %rdi
movl %r15d, %esi
movl %ebx, %edx
callq 0x669cd
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rdx
movq %r12, %rdi
callq 0x1ba10
movq 0x28(%rsp), %rdi
leaq 0x38(%rsp), %rax
cmpq %rax, %rdi
je 0x808f6
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1b8f0
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x80912
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1b8f0
addq $0x4, %r13
xorl %eax, %eax
cmpq 0x50(%rsp), %r13
jne 0x80677
jmp 0x8092d
movq %rbx, %r12
jmp 0x807d9
leaq 0x7c4d2(%rip), %rsi # 0xfce06
movl $0x2, %edx
movq %r14, %rdi
callq 0x1ba10
movq 0x48(%rsp), %rbx
leaq 0x78(%rsp), %rsi
movq %rbx, %rdi
callq 0x1be10
movq 0xba5be(%rip), %rsi # 0x13af18
leaq 0x60(%rsp), %rdi
callq 0x1b690
leaq 0xe0(%rsp), %rdi
callq 0x1b2c0
movq %rbx, %rax
addq $0x1e8, %rsp # imm = 0x1E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x809af
jmp 0x809af
jmp 0x809af
jmp 0x809b4
movq %rax, %rbx
movq 0x28(%rsp), %rdi
leaq 0x38(%rsp), %rax
cmpq %rax, %rdi
je 0x809b7
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x1b8f0
jmp 0x809b7
movq %rax, %rbx
jmp 0x809d3
movq %rax, %rbx
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x809d3
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x1b8f0
movq 0xba53e(%rip), %rsi # 0x13af18
leaq 0x60(%rsp), %rdi
callq 0x1b690
leaq 0xe0(%rsp), %rdi
callq 0x1b2c0
movq %rbx, %rdi
callq 0x1c020
| _Z11string_fromB5cxx11PK13llama_contextRKSt6vectorIiSaIiEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 1E8h
mov rbx, rdx
mov [rsp+218h+var_1C0], rsi
mov [rsp+218h+var_1D0], rdi
lea rdi, [rsp+218h+var_1B8]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::basic_stringstream(void)
lea r14, [rsp+218h+var_1A8]
lea rsi, asc_FCE03; "[ "
mov edx, 2
mov rdi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov r13, [rbx]
mov rax, [rbx+8]
mov [rsp+218h+var_1C8], rax
cmp r13, rax
jz loc_8092D
mov al, 1
loc_80677:
test al, 1
jnz short loc_8068F
mov edx, 2
mov rdi, r14
lea rsi, aZuD+6; ", "
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
loc_8068F:
mov ebx, [r13+0]
mov rdi, [rsp+218h+var_1C0]
call _llama_get_model
mov rdi, rax
call _llama_model_get_vocab
lea rdi, [rsp+218h+var_210]
mov rsi, rax
mov edx, ebx
mov ecx, 1
call _Z21common_token_to_pieceB5cxx11PK11llama_vocabib; common_token_to_piece(llama_vocab const*,int,bool)
mov r15, [rsp+218h+var_210]
mov rax, [rsp+218h+var_208]
lea rbx, [r15+rax]
mov r14, rax
sar r14, 2
mov rbp, r15
test r14, r14
jle short loc_80737
and rax, 0FFFFFFFFFFFFFFFCh
mov rbp, rax
add rbp, r15
inc r14
lea r12, [r15+3]
loc_806E7:
movzx edi, byte ptr [r12-3]
call _isprint
test eax, eax
jz loc_8078C
movzx edi, byte ptr [r12-2]
call _isprint
test eax, eax
jz loc_80792
movzx edi, byte ptr [r12-1]
call _isprint
test eax, eax
jz short loc_80798
movzx edi, byte ptr [r12]
call _isprint
test eax, eax
jz short loc_8079B
dec r14
add r12, 4
cmp r14, 1
jg short loc_806E7
loc_80737:
mov rax, rbx
sub rax, rbp
cmp rax, 1
jz short loc_80778
cmp rax, 2
lea r14, [rsp+218h+var_1A8]
jz short loc_80768
cmp rax, 3
jnz loc_80925
movzx edi, byte ptr [rbp+0]
call _isprint
test eax, eax
jz short loc_80787
inc rbp
loc_80768:
movzx edi, byte ptr [rbp+0]
call _isprint
test eax, eax
jz short loc_80787
inc rbp
loc_80778:
movzx edi, byte ptr [rbp+0]
call _isprint
test eax, eax
cmovnz rbp, rbx
loc_80787:
mov r12, rbp
jmp short loc_8079B
loc_8078C:
add r12, 0FFFFFFFFFFFFFFFDh
jmp short loc_8079B
loc_80792:
add r12, 0FFFFFFFFFFFFFFFEh
jmp short loc_8079B
loc_80798:
dec r12
loc_8079B:
cmp r12, rbx
setz al
lea r14, [r12+1]
cmp r14, rbx
setz cl
or cl, al
jnz short loc_807D4
loc_807B0:
mov bpl, [r14]
movzx edi, bpl
call _isprint
test eax, eax
jz short loc_807C7
mov [r12], bpl
inc r12
loc_807C7:
inc r14
cmp r14, rbx
jnz short loc_807B0
mov r15, [rsp+218h+var_210]
loc_807D4:
lea r14, [rsp+218h+var_1A8]
loc_807D9:
mov rax, r12
sub rax, r15
mov [rsp+218h+var_208], rax
mov byte ptr [r12], 0
mov edx, 1
mov rdi, r14
lea rsi, asc_FBEE1+2; "'"
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rsi, [rsp+218h+var_210]
mov rdx, [rsp+218h+var_208]
mov rdi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov r12, rax
mov edx, 1
mov rdi, rax
lea rsi, asc_FBEE1+2; "'"
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov edx, 1
mov rdi, r12
lea rsi, aArgumentNeedle_0+11h; ":"
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov ebp, [r13+0]
mov ebx, ebp
neg ebx
cmovs ebx, ebp
mov r15d, 1
cmp ebx, 0Ah
jb short loc_80896
mov r15d, 4
mov eax, ebx
loc_80858:
cmp eax, 63h ; 'c'
jbe short loc_8088D
cmp eax, 3E7h
jbe short loc_80893
cmp eax, 2710h
jb short loc_80896
mov ecx, eax
mov edx, 0D1B71759h
imul rcx, rdx
shr rcx, 2Dh
add r15d, 4
cmp eax, 1869Fh
mov eax, ecx
ja short loc_80858
add r15d, 0FFFFFFFDh
jmp short loc_80896
loc_8088D:
add r15d, 0FFFFFFFEh
jmp short loc_80896
loc_80893:
dec r15d
loc_80896:
shr ebp, 1Fh
lea esi, [r15+rbp]
lea rax, [rsp+218h+var_1E0]
mov [rsp+218h+var_1F0], rax
lea rdi, [rsp+218h+var_1F0]
mov edx, 2Dh ; '-'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructEmc; std::string::_M_construct(ulong,char)
add rbp, [rsp+218h+var_1F0]
mov rdi, rbp
mov esi, r15d
mov edx, ebx
call _ZNSt8__detail18__to_chars_10_implIjEEvPcjT_; std::__detail::__to_chars_10_impl<uint>(char *,uint,uint)
mov rsi, [rsp+218h+var_1F0]
mov rdx, [rsp+218h+var_1E8]
mov rdi, r12
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rdi, [rsp+218h+var_1F0]; void *
lea rax, [rsp+218h+var_1E0]
cmp rdi, rax
jz short loc_808F6
mov rsi, [rsp+218h+var_1E0]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_808F6:
mov rdi, [rsp+218h+var_210]; void *
lea rax, [rsp+218h+var_200]
cmp rdi, rax
jz short loc_80912
mov rsi, [rsp+218h+var_200]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_80912:
add r13, 4
xor eax, eax
cmp r13, [rsp+218h+var_1C8]
jnz loc_80677
jmp short loc_8092D
loc_80925:
mov r12, rbx
jmp loc_807D9
loc_8092D:
lea rsi, asc_FCE06; " ]"
mov edx, 2
mov rdi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov rbx, [rsp+218h+var_1D0]
lea rsi, [rsp+218h+var_1A0]
mov rdi, rbx
call __ZNKSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void)
mov rsi, cs:_ZTTNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+218h+var_1B8]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED2Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream()
lea rdi, [rsp+218h+var_138]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
mov rax, rbx
add rsp, 1E8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_809AF
jmp short loc_809AF
jmp short loc_809AF
jmp short loc_809B4
mov rbx, rax
mov rdi, [rsp+arg_20]; void *
lea rax, [rsp+arg_30]
cmp rdi, rax
jz short loc_809B7
mov rsi, [rsp+arg_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_809B7
loc_809AF:
mov rbx, rax
jmp short loc_809D3
loc_809B4:
mov rbx, rax
loc_809B7:
mov rdi, [rsp+arg_0]; void *
lea rax, [rsp+arg_10]
cmp rdi, rax
jz short loc_809D3
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_809D3:
mov rsi, cs:_ZTTNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEE_ptr
lea rdi, [rsp+arg_58]
call __ZNSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEED2Ev; std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream()
lea rdi, [rsp+arg_D8]; this
call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
mov rdi, rbx
call __Unwind_Resume
| long long string_from[abi:cxx11](long long a1, long long a2, unsigned int **a3)
{
unsigned int *v4; // r13
char v5; // al
unsigned int v6; // ebx
long long model; // rax
long long vocab; // rax
_BYTE *v9; // r15
char *v10; // rbx
char *v11; // rbp
long long v12; // r14
char *v13; // r12
signed long long v14; // rax
char *v15; // r14
char v16; // bp
long long v17; // r12
unsigned int v18; // ebx
int v19; // r15d
unsigned int v20; // eax
bool v21; // cc
unsigned int v22; // ebp
long long v23; // rbx
void *v25; // [rsp+8h] [rbp-210h] BYREF
long long v26; // [rsp+10h] [rbp-208h]
long long v27; // [rsp+18h] [rbp-200h] BYREF
void *v28[2]; // [rsp+28h] [rbp-1F0h] BYREF
_QWORD v29[2]; // [rsp+38h] [rbp-1E0h] BYREF
long long v30; // [rsp+48h] [rbp-1D0h]
unsigned int *v31; // [rsp+50h] [rbp-1C8h]
long long v32; // [rsp+58h] [rbp-1C0h]
_BYTE v33[16]; // [rsp+60h] [rbp-1B8h] BYREF
char v34[8]; // [rsp+70h] [rbp-1A8h] BYREF
char v35[104]; // [rsp+78h] [rbp-1A0h] BYREF
char v36[312]; // [rsp+E0h] [rbp-138h] BYREF
v32 = a2;
v30 = a1;
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::basic_stringstream(v33);
std::__ostream_insert<char,std::char_traits<char>>(v34, "[ ", 2LL);
v4 = *a3;
v31 = a3[1];
if ( v4 != v31 )
{
v5 = 1;
while ( 1 )
{
if ( (v5 & 1) == 0 )
std::__ostream_insert<char,std::char_traits<char>>(v34, ", ", 2LL);
v6 = *v4;
model = llama_get_model(v32);
vocab = llama_model_get_vocab(model);
common_token_to_piece[abi:cxx11](&v25, vocab, v6, 1LL);
v9 = v25;
v10 = (char *)v25 + v26;
v11 = (char *)v25;
if ( v26 >> 2 > 0 )
break;
LABEL_12:
v14 = v10 - v11;
if ( v10 - v11 == 1 )
goto LABEL_19;
if ( v14 == 2 )
goto LABEL_17;
if ( v14 == 3 )
{
if ( (unsigned int)isprint((unsigned __int8)*v11) )
{
++v11;
LABEL_17:
if ( (unsigned int)isprint((unsigned __int8)*v11) )
{
++v11;
LABEL_19:
if ( (unsigned int)isprint((unsigned __int8)*v11) )
v11 = v10;
}
}
v13 = v11;
LABEL_25:
v15 = v13 + 1;
if ( v13 != v10 && v13 + 1 != v10 )
{
do
{
v16 = *v15;
if ( (unsigned int)isprint((unsigned __int8)*v15) )
*v13++ = v16;
++v15;
}
while ( v15 != v10 );
v9 = v25;
}
goto LABEL_30;
}
v13 = v10;
LABEL_30:
v26 = v13 - v9;
*v13 = 0;
std::__ostream_insert<char,std::char_traits<char>>(v34, "'", 1LL);
v17 = std::__ostream_insert<char,std::char_traits<char>>(v34, v25, v26);
std::__ostream_insert<char,std::char_traits<char>>(v17, "'", 1LL);
std::__ostream_insert<char,std::char_traits<char>>(v17, ":", 1LL);
v18 = -*v4;
if ( (int)*v4 > 0 )
v18 = *v4;
v19 = 1;
if ( v18 >= 0xA )
{
v19 = 4;
v20 = v18;
while ( 1 )
{
if ( v20 <= 0x63 )
{
v19 -= 2;
goto LABEL_41;
}
if ( v20 <= 0x3E7 )
break;
if ( v20 < 0x2710 )
goto LABEL_41;
v19 += 4;
v21 = v20 <= 0x1869F;
v20 /= 0x2710u;
if ( v21 )
{
v19 -= 3;
goto LABEL_41;
}
}
--v19;
}
LABEL_41:
v22 = *v4 >> 31;
v28[0] = v29;
std::string::_M_construct(v28, v19 + v22, 45LL);
std::__detail::__to_chars_10_impl<unsigned int>((char *)v28[0] + v22, v19, v18);
std::__ostream_insert<char,std::char_traits<char>>(v17, v28[0], v28[1]);
if ( v28[0] != v29 )
operator delete(v28[0], v29[0] + 1LL);
if ( v25 != &v27 )
operator delete(v25, v27 + 1);
++v4;
v5 = 0;
if ( v4 == v31 )
goto LABEL_48;
}
v11 = (char *)v25 + (v26 & 0xFFFFFFFFFFFFFFFCLL);
v12 = (v26 >> 2) + 1;
v13 = (char *)v25 + 3;
while ( 1 )
{
if ( !(unsigned int)isprint((unsigned __int8)*(v13 - 3)) )
{
v13 -= 3;
goto LABEL_25;
}
if ( !(unsigned int)isprint((unsigned __int8)*(v13 - 2)) )
{
v13 -= 2;
goto LABEL_25;
}
if ( !(unsigned int)isprint((unsigned __int8)*(v13 - 1)) )
break;
if ( !(unsigned int)isprint((unsigned __int8)*v13) )
goto LABEL_25;
--v12;
v13 += 4;
if ( v12 <= 1 )
goto LABEL_12;
}
--v13;
goto LABEL_25;
}
LABEL_48:
std::__ostream_insert<char,std::char_traits<char>>(v34, " ]", 2LL);
v23 = v30;
std::stringbuf::str(v30, v35);
std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>::~basic_stringstream(
v33,
&`VTT for'std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>);
std::ios_base::~ios_base((std::ios_base *)v36);
return v23;
}
| string_from[abi:cxx11]:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x1e8
MOV RBX,RDX
MOV qword ptr [RSP + 0x58],RSI
MOV qword ptr [RSP + 0x48],RDI
LEA RDI,[RSP + 0x60]
CALL 0x0011b650
LEA R14,[RSP + 0x70]
LAB_0018064c:
LEA RSI,[0x1fce03]
MOV EDX,0x2
MOV RDI,R14
CALL 0x0011ba10
MOV R13,qword ptr [RBX]
MOV RAX,qword ptr [RBX + 0x8]
MOV qword ptr [RSP + 0x50],RAX
CMP R13,RAX
JZ 0x0018092d
MOV AL,0x1
LAB_00180677:
TEST AL,0x1
JNZ 0x0018068f
LAB_0018067b:
MOV EDX,0x2
MOV RDI,R14
LEA RSI,[0x1fd7a7]
CALL 0x0011ba10
LAB_0018068f:
MOV EBX,dword ptr [R13]
LAB_00180693:
MOV RDI,qword ptr [RSP + 0x58]
CALL 0x0011b7c0
MOV RDI,RAX
CALL 0x0011c220
LEA RDI,[RSP + 0x8]
MOV RSI,RAX
MOV EDX,EBX
MOV ECX,0x1
CALL 0x001837c9
MOV R15,qword ptr [RSP + 0x8]
MOV RAX,qword ptr [RSP + 0x10]
LEA RBX,[R15 + RAX*0x1]
MOV R14,RAX
SAR R14,0x2
MOV RBP,R15
TEST R14,R14
JLE 0x00180737
AND RAX,-0x4
MOV RBP,RAX
ADD RBP,R15
INC R14
LEA R12,[R15 + 0x3]
LAB_001806e7:
MOVZX EDI,byte ptr [R12 + -0x3]
CALL 0x0011c030
TEST EAX,EAX
JZ 0x0018078c
MOVZX EDI,byte ptr [R12 + -0x2]
CALL 0x0011c030
TEST EAX,EAX
JZ 0x00180792
MOVZX EDI,byte ptr [R12 + -0x1]
CALL 0x0011c030
TEST EAX,EAX
JZ 0x00180798
MOVZX EDI,byte ptr [R12]
CALL 0x0011c030
TEST EAX,EAX
JZ 0x0018079b
DEC R14
ADD R12,0x4
CMP R14,0x1
JG 0x001806e7
LAB_00180737:
MOV RAX,RBX
SUB RAX,RBP
CMP RAX,0x1
JZ 0x00180778
CMP RAX,0x2
LEA R14,[RSP + 0x70]
JZ 0x00180768
CMP RAX,0x3
JNZ 0x00180925
MOVZX EDI,byte ptr [RBP]
CALL 0x0011c030
TEST EAX,EAX
JZ 0x00180787
INC RBP
LAB_00180768:
MOVZX EDI,byte ptr [RBP]
CALL 0x0011c030
TEST EAX,EAX
JZ 0x00180787
INC RBP
LAB_00180778:
MOVZX EDI,byte ptr [RBP]
CALL 0x0011c030
TEST EAX,EAX
CMOVNZ RBP,RBX
LAB_00180787:
MOV R12,RBP
JMP 0x0018079b
LAB_0018078c:
ADD R12,-0x3
JMP 0x0018079b
LAB_00180792:
ADD R12,-0x2
JMP 0x0018079b
LAB_00180798:
DEC R12
LAB_0018079b:
CMP R12,RBX
SETZ AL
LEA R14,[R12 + 0x1]
CMP R14,RBX
SETZ CL
OR CL,AL
JNZ 0x001807d4
LAB_001807b0:
MOV BPL,byte ptr [R14]
MOVZX EDI,BPL
CALL 0x0011c030
TEST EAX,EAX
JZ 0x001807c7
MOV byte ptr [R12],BPL
INC R12
LAB_001807c7:
INC R14
CMP R14,RBX
JNZ 0x001807b0
MOV R15,qword ptr [RSP + 0x8]
LAB_001807d4:
LEA R14,[RSP + 0x70]
LAB_001807d9:
MOV RAX,R12
SUB RAX,R15
MOV qword ptr [RSP + 0x10],RAX
MOV byte ptr [R12],0x0
LAB_001807e9:
MOV EDX,0x1
MOV RDI,R14
LEA RSI,[0x1fbee3]
CALL 0x0011ba10
MOV RSI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [RSP + 0x10]
MOV RDI,R14
CALL 0x0011ba10
MOV R12,RAX
MOV EDX,0x1
MOV RDI,RAX
LEA RSI,[0x1fbee3]
CALL 0x0011ba10
MOV EDX,0x1
MOV RDI,R12
LEA RSI,[0x1fd8f2]
CALL 0x0011ba10
MOV EBP,dword ptr [R13]
MOV EBX,EBP
NEG EBX
CMOVS EBX,EBP
MOV R15D,0x1
CMP EBX,0xa
JC 0x00180896
MOV R15D,0x4
MOV EAX,EBX
LAB_00180858:
CMP EAX,0x63
JBE 0x0018088d
CMP EAX,0x3e7
JBE 0x00180893
CMP EAX,0x2710
JC 0x00180896
MOV ECX,EAX
MOV EDX,0xd1b71759
IMUL RCX,RDX
SHR RCX,0x2d
ADD R15D,0x4
CMP EAX,0x1869f
MOV EAX,ECX
JA 0x00180858
ADD R15D,-0x3
JMP 0x00180896
LAB_0018088d:
ADD R15D,-0x2
JMP 0x00180896
LAB_00180893:
DEC R15D
LAB_00180896:
SHR EBP,0x1f
LEA ESI,[R15 + RBP*0x1]
LEA RAX,[RSP + 0x38]
MOV qword ptr [RSP + 0x28],RAX
LAB_001808a7:
LEA RDI,[RSP + 0x28]
MOV EDX,0x2d
CALL 0x0011ba40
ADD RBP,qword ptr [RSP + 0x28]
MOV RDI,RBP
MOV ESI,R15D
MOV EDX,EBX
CALL 0x001669cd
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,qword ptr [RSP + 0x30]
LAB_001808d2:
MOV RDI,R12
CALL 0x0011ba10
MOV RDI,qword ptr [RSP + 0x28]
LEA RAX,[RSP + 0x38]
CMP RDI,RAX
JZ 0x001808f6
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x0011b8f0
LAB_001808f6:
MOV RDI,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x18]
CMP RDI,RAX
JZ 0x00180912
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0011b8f0
LAB_00180912:
ADD R13,0x4
XOR EAX,EAX
CMP R13,qword ptr [RSP + 0x50]
JNZ 0x00180677
JMP 0x0018092d
LAB_00180925:
MOV R12,RBX
JMP 0x001807d9
LAB_0018092d:
LEA RSI,[0x1fce06]
MOV EDX,0x2
MOV RDI,R14
CALL 0x0011ba10
MOV RBX,qword ptr [RSP + 0x48]
LEA RSI,[RSP + 0x78]
MOV RDI,RBX
CALL 0x0011be10
LAB_00180953:
MOV RSI,qword ptr [0x0023af18]
LEA RDI,[RSP + 0x60]
CALL 0x0011b690
LEA RDI,[RSP + 0xe0]
CALL 0x0011b2c0
MOV RAX,RBX
ADD RSP,0x1e8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* string_from[abi:cxx11](llama_context const*, std::vector<int, std::allocator<int> > const&) */
llama_context * string_from_abi_cxx11_(llama_context *param_1,vector *param_2)
{
byte *pbVar1;
byte bVar2;
uint uVar3;
uint uVar4;
llama_context *plVar5;
uint uVar6;
bool bVar7;
int iVar8;
uint uVar9;
int8 uVar10;
ostream *poVar11;
ulong uVar12;
int8 *in_RDX;
byte *pbVar13;
byte *pbVar14;
uint *puVar15;
long lVar16;
uint uVar17;
byte *pbVar18;
byte *local_210;
ulong local_208;
long local_200 [2];
long *local_1f0;
long local_1e8;
long local_1e0 [2];
llama_context *local_1d0;
uint *local_1c8;
vector *local_1c0;
stringstream local_1b8 [16];
ostream local_1a8 [112];
ios_base local_138 [264];
local_1d0 = param_1;
local_1c0 = param_2;
std::__cxx11::stringstream::stringstream(local_1b8);
/* try { // try from 0018064c to 0018065f has its CatchHandler @ 00180986 */
std::__ostream_insert<char,std::char_traits<char>>(local_1a8,"[ ",2);
puVar15 = (uint *)*in_RDX;
local_1c8 = (uint *)in_RDX[1];
if (puVar15 != local_1c8) {
bVar7 = true;
do {
if (!bVar7) {
/* try { // try from 0018067b to 0018068e has its CatchHandler @ 0018098a */
std::__ostream_insert<char,std::char_traits<char>>(local_1a8,", ",2);
}
uVar3 = *puVar15;
/* try { // try from 00180693 to 001806b8 has its CatchHandler @ 001809af */
uVar10 = llama_get_model(local_1c0);
iVar8 = llama_model_get_vocab(uVar10);
common_token_to_piece_abi_cxx11_((llama_vocab *)&local_210,iVar8,SUB41(uVar3,0));
pbVar18 = local_210;
pbVar1 = local_210 + local_208;
pbVar13 = local_210;
if (0 < (long)local_208 >> 2) {
pbVar13 = local_210 + (local_208 & 0xfffffffffffffffc);
lVar16 = ((long)local_208 >> 2) + 1;
pbVar14 = local_210 + 3;
do {
iVar8 = isprint((uint)pbVar14[-3]);
if (iVar8 == 0) {
pbVar14 = pbVar14 + -3;
goto LAB_0018079b;
}
iVar8 = isprint((uint)pbVar14[-2]);
if (iVar8 == 0) {
pbVar14 = pbVar14 + -2;
goto LAB_0018079b;
}
iVar8 = isprint((uint)pbVar14[-1]);
if (iVar8 == 0) {
pbVar14 = pbVar14 + -1;
goto LAB_0018079b;
}
iVar8 = isprint((uint)*pbVar14);
if (iVar8 == 0) goto LAB_0018079b;
lVar16 = lVar16 + -1;
pbVar14 = pbVar14 + 4;
} while (1 < lVar16);
}
lVar16 = (long)pbVar1 - (long)pbVar13;
if (lVar16 == 1) {
LAB_00180778:
iVar8 = isprint((uint)*pbVar13);
pbVar14 = pbVar13;
if (iVar8 != 0) {
pbVar14 = pbVar1;
}
LAB_0018079b:
pbVar13 = pbVar14 + 1;
if (pbVar13 != pbVar1 && pbVar14 != pbVar1) {
do {
bVar2 = *pbVar13;
iVar8 = isprint((uint)bVar2);
if (iVar8 != 0) {
*pbVar14 = bVar2;
pbVar14 = pbVar14 + 1;
}
pbVar13 = pbVar13 + 1;
pbVar18 = local_210;
} while (pbVar13 != pbVar1);
}
}
else {
if (lVar16 == 2) {
LAB_00180768:
iVar8 = isprint((uint)*pbVar13);
pbVar14 = pbVar13;
if (iVar8 != 0) {
pbVar13 = pbVar13 + 1;
goto LAB_00180778;
}
goto LAB_0018079b;
}
pbVar14 = pbVar1;
if (lVar16 == 3) {
iVar8 = isprint((uint)*pbVar13);
pbVar14 = pbVar13;
if (iVar8 != 0) {
pbVar13 = pbVar13 + 1;
goto LAB_00180768;
}
goto LAB_0018079b;
}
}
local_208 = (long)pbVar14 - (long)pbVar18;
*pbVar14 = 0;
/* try { // try from 001807e9 to 00180839 has its CatchHandler @ 001809b4 */
std::__ostream_insert<char,std::char_traits<char>>(local_1a8,"\'",1);
poVar11 = std::__ostream_insert<char,std::char_traits<char>>
(local_1a8,(char *)local_210,local_208);
std::__ostream_insert<char,std::char_traits<char>>(poVar11,"\'",1);
std::__ostream_insert<char,std::char_traits<char>>(poVar11,":",1);
uVar3 = *puVar15;
uVar4 = -uVar3;
if (0 < (int)uVar3) {
uVar4 = uVar3;
}
uVar17 = 1;
if (9 < uVar4) {
uVar12 = (ulong)uVar4;
uVar6 = 4;
do {
uVar17 = uVar6;
uVar9 = (uint)uVar12;
if (uVar9 < 100) {
uVar17 = uVar17 - 2;
goto LAB_00180896;
}
if (uVar9 < 1000) {
uVar17 = uVar17 - 1;
goto LAB_00180896;
}
if (uVar9 < 10000) goto LAB_00180896;
uVar12 = uVar12 / 10000;
uVar6 = uVar17 + 4;
} while (99999 < uVar9);
uVar17 = uVar17 + 1;
}
LAB_00180896:
local_1f0 = local_1e0;
/* try { // try from 001808a7 to 001808b5 has its CatchHandler @ 0018098c */
std::__cxx11::string::_M_construct
((ulong)&local_1f0,(char)uVar17 - (char)((int)uVar3 >> 0x1f));
std::__detail::__to_chars_10_impl<unsigned_int>
((char *)((long)local_1f0 + (ulong)(uVar3 >> 0x1f)),uVar17,uVar4);
/* try { // try from 001808d2 to 001808d9 has its CatchHandler @ 0018098e */
std::__ostream_insert<char,std::char_traits<char>>(poVar11,(char *)local_1f0,local_1e8);
if (local_1f0 != local_1e0) {
operator_delete(local_1f0,local_1e0[0] + 1);
}
if (local_210 != (byte *)local_200) {
operator_delete(local_210,local_200[0] + 1);
}
puVar15 = puVar15 + 1;
bVar7 = false;
} while (puVar15 != local_1c8);
}
/* try { // try from 0018092d to 00180952 has its CatchHandler @ 00180988 */
std::__ostream_insert<char,std::char_traits<char>>(local_1a8," ]",2);
plVar5 = local_1d0;
std::__cxx11::stringbuf::str();
std::__cxx11::stringstream::~stringstream(local_1b8);
std::ios_base::~ios_base(local_138);
return plVar5;
}
| |
22,170 | nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::parse<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, std::function<bool (int, nlohmann::json_abi_v3_11_3::detail::parse_event_t, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&)>, bool, bool) | monkey531[P]llama/common/json.hpp | JSON_HEDLEY_WARN_UNUSED_RESULT
static basic_json parse(InputType&& i,
const parser_callback_t cb = nullptr,
const bool allow_exceptions = true,
const bool ignore_comments = false)
{
basic_json result;
parser(detail::input_adapter(std::forward<InputType>(i)), cb, allow_exceptions, ignore_comments).parse(true, result);
return result;
} | O3 | cpp | nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::parse<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, std::function<bool (int, nlohmann::json_abi_v3_11_3::detail::parse_event_t, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&)>, bool, bool):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movl %r8d, %ebp
movl %ecx, %r14d
movq %rdx, %r13
movq %rsi, %r12
movq %rdi, %rbx
movb $0x0, (%rdi)
movq $0x0, 0x8(%rdi)
movl $0x1, %esi
callq 0x89206
movq %rbx, %rdi
movl $0x1, %esi
callq 0x89206
movq (%r12), %r15
movq 0x8(%r12), %r12
movq %rsp, %rdi
movq %r13, %rsi
callq 0x88ba8
addq %r15, %r12
movzbl %r14b, %r8d
movzbl %bpl, %r9d
leaq 0x20(%rsp), %rdi
movq %rsp, %rcx
movq %r15, %rsi
movq %r12, %rdx
callq 0x88afc
leaq 0x20(%rsp), %rdi
movl $0x1, %esi
movq %rbx, %rdx
callq 0x88c06
leaq 0x48(%rsp), %r14
movq %r14, %rdi
callq 0x896c6
movq -0x18(%r14), %rax
testq %rax, %rax
je 0xafcab
leaq 0x20(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0xafcc2
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %rbx, %rax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0xafd06
jmp 0xafd06
movq %rax, %r14
leaq 0x20(%rsp), %rdi
callq 0x891d8
jmp 0xafced
movq %rax, %r14
movq 0x10(%rsp), %rax
testq %rax, %rax
je 0xafd11
movq %rsp, %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0xafd11
movq %rax, %rdi
callq 0x25ec1
movq %rax, %r14
movq %rbx, %rdi
xorl %esi, %esi
callq 0x89206
movq %rbx, %rdi
callq 0x8e4c0
movq %r14, %rdi
callq 0x1e660
nop
| _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5parseIRS9_EESD_OT_St8functionIFbiNS0_6detail13parse_event_tERSD_EEbb:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0E8h
mov ebp, r8d
mov r14d, ecx
mov r13, rdx
mov r12, rsi
mov rbx, rdi
mov byte ptr [rdi], 0
mov qword ptr [rdi+8], 0
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, rbx
mov esi, 1
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov r15, [r12]
mov r12, [r12+8]
mov rdi, rsp
mov rsi, r13
call _ZNSt8functionIFbiN8nlohmann16json_abi_v3_11_36detail13parse_event_tERNS1_10basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES6_IhSaIhEEvEEEEC2ERKSJ_; std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &)>::function(std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &)> const&)
add r12, r15
movzx r8d, r14b
movzx r9d, bpl
lea rdi, [rsp+118h+var_F8]
mov rcx, rsp
mov rsi, r15
mov rdx, r12
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6parserINS0_6detail22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcS9_EEEEEENSF_6parserISD_T_EESO_St8functionIFbiNSF_13parse_event_tERSD_EEbb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>(nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>,std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&)>,bool,bool)
lea rdi, [rsp+118h+var_F8]; int
mov esi, 1
mov rdx, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail6parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE5parseEbRSF_; nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::parse(bool,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&)
lea r14, [rsp+118h+var_D0]
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEED2Ev; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::~lexer()
mov rax, [r14-18h]
test rax, rax
jz short loc_AFCAB
lea rdi, [rsp+118h+var_F8]
mov rsi, rdi
mov edx, 3
call rax
loc_AFCAB:
mov rax, [rsp+118h+var_108]
test rax, rax
jz short loc_AFCC2
mov rdi, rsp
mov rsi, rdi
mov edx, 3
call rax
loc_AFCC2:
mov rax, rbx
add rsp, 0E8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
jmp short loc_AFD06
jmp short loc_AFD06
mov r14, rax
lea rdi, [rsp+118h+var_F8]
call _ZN8nlohmann16json_abi_v3_11_36detail6parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEED2Ev; nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::~parser()
jmp short loc_AFCED
mov r14, rax
loc_AFCED:
mov rax, [rsp+118h+var_108]
test rax, rax
jz short loc_AFD11
mov rdi, rsp
mov rsi, rdi
mov edx, 3
call rax
jmp short loc_AFD11
loc_AFD06:
mov rdi, rax
call __clang_call_terminate
mov r14, rax
loc_AFD11:
mov rdi, rbx
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, rbx
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rdi, r14
call __Unwind_Resume
| long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::parse<std::string&>(
long long a1,
long long *a2,
long long a3,
unsigned __int8 a4,
unsigned __int8 a5)
{
long long v8; // r15
long long v9; // r12
__int128 v11; // [rsp+0h] [rbp-118h] BYREF
void ( *v12)(__int128 *, __int128 *, long long); // [rsp+10h] [rbp-108h]
int v13[4]; // [rsp+20h] [rbp-F8h] BYREF
void ( *v14)(int *, int *, long long); // [rsp+30h] [rbp-E8h]
_QWORD v15[26]; // [rsp+48h] [rbp-D0h] BYREF
*(_BYTE *)a1 = 0;
*(_QWORD *)(a1 + 8) = 0LL;
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1);
v8 = *a2;
v9 = a2[1];
std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> &)>::function(
&v11,
a3);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>(
(long long)v13,
v8,
v8 + v9,
&v11,
a4,
a5);
nlohmann::json_abi_v3_11_3::detail::parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::parse(
(long long)v13,
1,
(_BYTE *)a1);
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::~lexer(v15);
if ( v14 )
v14(v13, v13, 3LL);
if ( v12 )
v12(&v11, &v11, 3LL);
return a1;
}
| parse<std::__cxx11::string&>:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xe8
MOV EBP,R8D
MOV R14D,ECX
MOV R13,RDX
MOV R12,RSI
MOV RBX,RDI
MOV byte ptr [RDI],0x0
MOV qword ptr [RDI + 0x8],0x0
MOV ESI,0x1
CALL 0x00189206
MOV RDI,RBX
MOV ESI,0x1
CALL 0x00189206
MOV R15,qword ptr [R12]
MOV R12,qword ptr [R12 + 0x8]
LAB_001afc4b:
MOV RDI,RSP
MOV RSI,R13
CALL 0x00188ba8
ADD R12,R15
LAB_001afc59:
MOVZX R8D,R14B
MOVZX R9D,BPL
LEA RDI,[RSP + 0x20]
MOV RCX,RSP
MOV RSI,R15
MOV RDX,R12
CALL 0x00188afc
LAB_001afc74:
LEA RDI,[RSP + 0x20]
MOV ESI,0x1
MOV RDX,RBX
CALL 0x00188c06
LEA R14,[RSP + 0x48]
MOV RDI,R14
CALL 0x001896c6
MOV RAX,qword ptr [R14 + -0x18]
TEST RAX,RAX
JZ 0x001afcab
LAB_001afc9c:
LEA RDI,[RSP + 0x20]
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_001afcab:
MOV RAX,qword ptr [RSP + 0x10]
TEST RAX,RAX
JZ 0x001afcc2
LAB_001afcb5:
MOV RDI,RSP
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_001afcc2:
MOV RAX,RBX
ADD RSP,0xe8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>::parse<std::__cxx11::string&>(std::__cxx11::string&, std::function<bool (int,
nlohmann::json_abi_v3_11_3::detail::parse_event_t,
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>&)>, bool, bool) */
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
* __thiscall
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::parse<std::__cxx11::string&>
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*this,long *param_1,function *param_3,int1 param_4,int1 param_5)
{
long lVar1;
long lVar2;
function<bool(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>&)>
afStack_118 [16];
code *local_108;
parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
local_f8 [16];
code *local_e8;
lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
local_d0 [160];
*this = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x0;
*(int8 *)(this + 8) = 0;
assert_invariant(SUB81(this,0));
assert_invariant(SUB81(this,0));
lVar1 = *param_1;
lVar2 = param_1[1];
/* try { // try from 001afc4b to 001afc55 has its CatchHandler @ 001afd0e */
std::
function<bool(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>&)>
::function(afStack_118,param_3);
/* try { // try from 001afc59 to 001afc73 has its CatchHandler @ 001afcea */
parser<nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
(local_f8,lVar1,lVar2 + lVar1,afStack_118,param_4,param_5);
/* try { // try from 001afc74 to 001afc85 has its CatchHandler @ 001afcdb */
detail::
parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
::parse(local_f8,true,(basic_json *)this);
detail::
lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>
::~lexer(local_d0);
if (local_e8 != (code *)0x0) {
/* try { // try from 001afc9c to 001afcaa has its CatchHandler @ 001afcd9 */
(*local_e8)(local_f8,local_f8,3);
}
if (local_108 != (code *)0x0) {
/* try { // try from 001afcb5 to 001afcc1 has its CatchHandler @ 001afcd7 */
(*local_108)(afStack_118,afStack_118,3);
}
return this;
}
| |
22,171 | cleanup_digest() | eloqsql/storage/perfschema/pfs_digest.cc | void cleanup_digest(void)
{
PFS_FREE_ARRAY(& builtin_memory_digest,
digest_max,
sizeof(PFS_statements_digest_stat),
statements_digest_stat_array);
PFS_FREE_ARRAY(& builtin_memory_digest_tokens,
digest_max,
(pfs_max_digest_length * sizeof(unsigned char)),
statements_digest_token_array);
statements_digest_stat_array= NULL;
statements_digest_token_array= NULL;
} | O0 | cpp | cleanup_digest():
pushq %rbp
movq %rsp, %rbp
movq 0x3da55d(%rip), %rsi # 0x40b5f8
movq 0x3da566(%rip), %rcx # 0x40b608
leaq 0x3d9217(%rip), %rdi # 0x40a2c0
movl $0x200, %edx # imm = 0x200
callq 0x29be0
movq 0x3da53e(%rip), %rsi # 0x40b5f8
leaq 0x3db2b7(%rip), %rax # 0x40c378
movq (%rax), %rdx
shlq $0x0, %rdx
movq 0x3da681(%rip), %rcx # 0x40b750
leaq 0x3d932a(%rip), %rdi # 0x40a400
callq 0x29be0
movq $0x0, 0x3da522(%rip) # 0x40b608
movq $0x0, 0x3da65f(%rip) # 0x40b750
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _Z14cleanup_digestv:
push rbp
mov rbp, rsp
mov rsi, cs:digest_max
mov rcx, cs:statements_digest_stat_array
lea rdi, builtin_memory_digest
mov edx, 200h
call _Z14pfs_free_arrayP24PFS_builtin_memory_classmmPv; pfs_free_array(PFS_builtin_memory_class *,ulong,ulong,void *)
mov rsi, cs:digest_max
lea rax, pfs_max_digest_length
mov rdx, [rax]
shl rdx, 0
mov rcx, cs:_ZL29statements_digest_token_array; statements_digest_token_array
lea rdi, builtin_memory_digest_tokens
call _Z14pfs_free_arrayP24PFS_builtin_memory_classmmPv; pfs_free_array(PFS_builtin_memory_class *,ulong,ulong,void *)
mov cs:statements_digest_stat_array, 0
mov cs:_ZL29statements_digest_token_array, 0; statements_digest_token_array
pop rbp
retn
| long long cleanup_digest(void)
{
long long result; // rax
pfs_free_array((PFS_builtin_memory_class *)&builtin_memory_digest, digest_max, 512LL, statements_digest_stat_array);
result = pfs_free_array(
(PFS_builtin_memory_class *)&builtin_memory_digest_tokens,
digest_max,
pfs_max_digest_length,
(void *)statements_digest_token_array);
statements_digest_stat_array = 0LL;
statements_digest_token_array = 0LL;
return result;
}
| cleanup_digest:
PUSH RBP
MOV RBP,RSP
MOV RSI,qword ptr [0x0050b5f8]
MOV RCX,qword ptr [0x0050b608]
LEA RDI,[0x50a2c0]
MOV EDX,0x200
CALL 0x00129be0
MOV RSI,qword ptr [0x0050b5f8]
LEA RAX,[0x50c378]
MOV RDX,qword ptr [RAX]
SHL RDX,0x0
MOV RCX,qword ptr [0x0050b750]
LEA RDI,[0x50a400]
CALL 0x00129be0
MOV qword ptr [0x0050b608],0x0
MOV qword ptr [0x0050b750],0x0
POP RBP
RET
|
/* WARNING: Unknown calling convention -- yet parameter storage is locked */
/* cleanup_digest() */
void cleanup_digest(void)
{
pfs_free_array((PFS_builtin_memory_class *)builtin_memory_digest,digest_max,0x200,
statements_digest_stat_array);
pfs_free_array((PFS_builtin_memory_class *)builtin_memory_digest_tokens,digest_max,
pfs_max_digest_length,statements_digest_token_array);
statements_digest_stat_array = (void *)0x0;
statements_digest_token_array = (void *)0x0;
return;
}
| |
22,172 | my_thread_global_init | eloqsql/mysys/my_thr_init.c | my_bool my_thread_global_init(void)
{
int pth_ret;
/* Normally this should never be called twice */
DBUG_ASSERT(my_thread_global_init_done == 0);
if (my_thread_global_init_done)
return 0;
my_thread_global_init_done= 1;
/*
THR_KEY_mysys is deleted in my_end() as DBUG libraries are using it even
after my_thread_global_end() is called.
my_thr_key_mysys_exist is used to protect against application like QT
that calls my_thread_global_init() + my_thread_global_end() multiple times
without calling my_init() + my_end().
*/
if (!my_thr_key_mysys_exists &&
(pth_ret= pthread_key_create(&THR_KEY_mysys, NULL)) != 0)
{
fprintf(stderr, "Can't initialize threads: error %d\n", pth_ret);
return 1;
}
my_thr_key_mysys_exists= 1;
/* Mutex used by my_thread_init() and after my_thread_destroy_mutex() */
my_thread_init_internal_mutex();
if (my_thread_init())
return 1;
my_thread_init_common_mutex();
return 0;
} | O3 | c | my_thread_global_init:
cmpb $0x0, 0xb66dd1(%rip) # 0xc089f0
je 0xa1c24
xorl %eax, %eax
retq
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movb $0x1, 0xb66dbf(%rip) # 0xc089f0
leaq 0xb66af4(%rip), %rbx # 0xc0872c
cmpb $0x0, (%rbx)
je 0xa1c5b
movb $0x1, (%rbx)
callq 0xa1a73
callq 0xa1c95
movl %eax, %ecx
movb $0x1, %al
testb %cl, %cl
jne 0xa1c8e
callq 0xa18e6
xorl %eax, %eax
jmp 0xa1c8e
leaq 0xb66d92(%rip), %rdi # 0xc089f4
xorl %esi, %esi
callq 0x29700
testl %eax, %eax
je 0xa1c3d
movq 0x2e233c(%rip), %rcx # 0x383fb0
movq (%rcx), %rdi
leaq 0x3aae9(%rip), %rdx # 0xdc767
movl $0x1, %esi
movl %eax, %ecx
xorl %eax, %eax
callq 0x29200
movb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| my_thread_global_init:
cmp cs:my_thread_global_init_done, 0
jz short loc_A1C24
xor eax, eax
retn
loc_A1C24:
push rbp
mov rbp, rsp
push rbx
push rax
mov cs:my_thread_global_init_done, 1
lea rbx, my_thr_key_mysys_exists
cmp byte ptr [rbx], 0
jz short loc_A1C5B
loc_A1C3D:
mov byte ptr [rbx], 1
call my_thread_init_internal_mutex
call my_thread_init
mov ecx, eax
mov al, 1
test cl, cl
jnz short loc_A1C8E
call my_thread_init_common_mutex
xor eax, eax
jmp short loc_A1C8E
loc_A1C5B:
lea rdi, THR_KEY_mysys
xor esi, esi
call _pthread_key_create
test eax, eax
jz short loc_A1C3D
mov rcx, cs:stderr_ptr
mov rdi, [rcx]
lea rdx, aCanTInitialize; "Can't initialize threads: error %d\n"
mov esi, 1
mov ecx, eax
xor eax, eax
call ___fprintf_chk
mov al, 1
loc_A1C8E:
add rsp, 8
pop rbx
pop rbp
retn
| char my_thread_global_init(void *a1)
{
char result; // al
char v2; // cl
int v3; // eax
if ( my_thread_global_init_done )
return 0;
my_thread_global_init_done = 1;
if ( my_thr_key_mysys_exists || (a1 = &THR_KEY_mysys, (v3 = pthread_key_create(&THR_KEY_mysys, 0LL)) == 0) )
{
my_thr_key_mysys_exists = 1;
my_thread_init_internal_mutex();
v2 = my_thread_init(a1);
result = 1;
if ( !v2 )
{
my_thread_init_common_mutex();
return 0;
}
}
else
{
__fprintf_chk(stderr, 1LL, "Can't initialize threads: error %d\n", v3);
return 1;
}
return result;
}
| my_thread_global_init:
CMP byte ptr [0x00d089f0],0x0
JZ 0x001a1c24
XOR EAX,EAX
RET
LAB_001a1c24:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
MOV byte ptr [0x00d089f0],0x1
LEA RBX,[0xd0872c]
CMP byte ptr [RBX],0x0
JZ 0x001a1c5b
LAB_001a1c3d:
MOV byte ptr [RBX],0x1
CALL 0x001a1a73
CALL 0x001a1c95
MOV ECX,EAX
MOV AL,0x1
TEST CL,CL
JNZ 0x001a1c8e
CALL 0x001a18e6
XOR EAX,EAX
JMP 0x001a1c8e
LAB_001a1c5b:
LEA RDI,[0xd089f4]
XOR ESI,ESI
CALL 0x00129700
TEST EAX,EAX
JZ 0x001a1c3d
MOV RCX,qword ptr [0x00483fb0]
MOV RDI,qword ptr [RCX]
LEA RDX,[0x1dc767]
MOV ESI,0x1
MOV ECX,EAX
XOR EAX,EAX
CALL 0x00129200
MOV AL,0x1
LAB_001a1c8e:
ADD RSP,0x8
POP RBX
POP RBP
RET
|
bool my_thread_global_init(void)
{
char cVar1;
int iVar2;
if (my_thread_global_init_done != '\0') {
return false;
}
my_thread_global_init_done = 1;
if ((my_thr_key_mysys_exists == '\0') &&
(iVar2 = pthread_key_create(&THR_KEY_mysys,(__destr_function *)0x0), iVar2 != 0)) {
__fprintf_chk(*(int8 *)PTR_stderr_00483fb0,1,"Can\'t initialize threads: error %d\n",iVar2
);
return true;
}
my_thr_key_mysys_exists = 1;
my_thread_init_internal_mutex();
cVar1 = my_thread_init();
if (cVar1 == '\0') {
my_thread_init_common_mutex();
}
return cVar1 != '\0';
}
| |
22,173 | inflateEnd | 3fs/build_O3/src/apache-arrow-cpp/cpp/zlib_ep-prefix/src/zlib_ep/inflate.c | int ZEXPORT inflateEnd(strm)
z_streamp strm;
{
struct inflate_state FAR *state;
if (inflateStateCheck(strm))
return Z_STREAM_ERROR;
state = (struct inflate_state FAR *)strm->state;
if (state->window != Z_NULL) ZFREE(strm, state->window);
ZFREE(strm, strm->state);
strm->state = Z_NULL;
Tracev((stderr, "inflate: end\n"));
return Z_OK;
} | O3 | c | inflateEnd:
pushq %rbx
movq %rdi, %rbx
callq 0x8c49
movl %eax, %ecx
movl $0xfffffffe, %eax # imm = 0xFFFFFFFE
testl %ecx, %ecx
jne 0xaaba
movq 0x38(%rbx), %rsi
movq 0x48(%rsi), %rax
testq %rax, %rax
je 0xaaa9
movq 0x50(%rbx), %rdi
movq %rax, %rsi
callq *0x48(%rbx)
movq 0x38(%rbx), %rsi
movq 0x50(%rbx), %rdi
callq *0x48(%rbx)
movq $0x0, 0x38(%rbx)
xorl %eax, %eax
popq %rbx
retq
| inflateEnd:
push rbx
mov rbx, rdi
call inflateStateCheck
mov ecx, eax
mov eax, 0FFFFFFFEh
test ecx, ecx
jnz short loc_AABA
mov rsi, [rbx+38h]
mov rax, [rsi+48h]
test rax, rax
jz short loc_AAA9
mov rdi, [rbx+50h]
mov rsi, rax
call qword ptr [rbx+48h]
mov rsi, [rbx+38h]
loc_AAA9:
mov rdi, [rbx+50h]
call qword ptr [rbx+48h]
mov qword ptr [rbx+38h], 0
xor eax, eax
loc_AABA:
pop rbx
retn
| long long inflateEnd(long long a1)
{
BOOL v1; // ecx
long long result; // rax
long long v3; // rsi
v1 = inflateStateCheck((_QWORD *)a1);
result = 4294967294LL;
if ( !v1 )
{
v3 = *(_QWORD *)(a1 + 56);
if ( *(_QWORD *)(v3 + 72) )
{
(*(void ( **)(_QWORD, _QWORD))(a1 + 72))(*(_QWORD *)(a1 + 80), *(_QWORD *)(v3 + 72));
v3 = *(_QWORD *)(a1 + 56);
}
(*(void ( **)(_QWORD, long long))(a1 + 72))(*(_QWORD *)(a1 + 80), v3);
*(_QWORD *)(a1 + 56) = 0LL;
return 0LL;
}
return result;
}
| inflateEnd:
PUSH RBX
MOV RBX,RDI
CALL 0x00108c49
MOV ECX,EAX
MOV EAX,0xfffffffe
TEST ECX,ECX
JNZ 0x0010aaba
MOV RSI,qword ptr [RBX + 0x38]
MOV RAX,qword ptr [RSI + 0x48]
TEST RAX,RAX
JZ 0x0010aaa9
MOV RDI,qword ptr [RBX + 0x50]
MOV RSI,RAX
CALL qword ptr [RBX + 0x48]
MOV RSI,qword ptr [RBX + 0x38]
LAB_0010aaa9:
MOV RDI,qword ptr [RBX + 0x50]
CALL qword ptr [RBX + 0x48]
MOV qword ptr [RBX + 0x38],0x0
XOR EAX,EAX
LAB_0010aaba:
POP RBX
RET
|
int8 inflateEnd(long param_1)
{
int iVar1;
int8 uVar2;
long lVar3;
iVar1 = inflateStateCheck();
uVar2 = 0xfffffffe;
if (iVar1 == 0) {
lVar3 = *(long *)(param_1 + 0x38);
if (*(long *)(lVar3 + 0x48) != 0) {
(**(code **)(param_1 + 0x48))(*(int8 *)(param_1 + 0x50),*(long *)(lVar3 + 0x48));
lVar3 = *(long *)(param_1 + 0x38);
}
(**(code **)(param_1 + 0x48))(*(int8 *)(param_1 + 0x50),lVar3);
*(int8 *)(param_1 + 0x38) = 0;
uVar2 = 0;
}
return uVar2;
}
| |
22,174 | nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&) | monkey531[P]llama/common/./json.hpp | std::pair<iterator, bool> emplace(const key_type& key, T&& t)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return {it, false};
}
}
Container::emplace_back(key, std::forward<T>(t));
return {std::prev(this->end()), true};
} | O0 | cpp | nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&):
subq $0x68, %rsp
movq %rdi, 0x50(%rsp)
movq %rsi, 0x48(%rsp)
movq %rdx, 0x40(%rsp)
movq 0x50(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0xa2a90
movq %rax, 0x38(%rsp)
movq 0x8(%rsp), %rdi
callq 0xa2ac0
movq %rax, 0x30(%rsp)
leaq 0x38(%rsp), %rdi
leaq 0x30(%rsp), %rsi
callq 0xa2af0
testb $0x1, %al
jne 0xbdb4b
jmp 0xbdba2
movq 0x8(%rsp), %rax
addq $0x18, %rax
movq %rax, (%rsp)
leaq 0x38(%rsp), %rdi
callq 0xbbbe0
movq (%rsp), %rdi
movq %rax, %rsi
movq 0x48(%rsp), %rdx
callq 0xbdc00
testb $0x1, %al
jne 0xbdb79
jmp 0xbdb94
movb $0x0, 0x2f(%rsp)
leaq 0x58(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0x2f(%rsp), %rdx
callq 0xbdc30
jmp 0xbdbf2
jmp 0xbdb96
leaq 0x38(%rsp), %rdi
callq 0xa2b70
jmp 0xbdb27
movq 0x8(%rsp), %rdi
movq 0x48(%rsp), %rsi
movq 0x40(%rsp), %rdx
callq 0xbdc60
movq 0x8(%rsp), %rdi
callq 0xa2ac0
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0xbdcf0
movq %rax, 0x20(%rsp)
movb $0x1, 0x17(%rsp)
leaq 0x58(%rsp), %rdi
leaq 0x20(%rsp), %rsi
leaq 0x17(%rsp), %rdx
callq 0xbdd30
movq 0x58(%rsp), %rax
movb 0x60(%rsp), %dl
addq $0x68, %rsp
retq
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE7emplaceERSH_OSD_:
sub rsp, 68h
mov [rsp+68h+var_18], rdi
mov [rsp+68h+var_20], rsi
mov [rsp+68h+var_28], rdx
mov rdi, [rsp+68h+var_18]
mov [rsp+68h+var_60], rdi
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE5beginEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::begin(void)
mov [rsp+68h+var_30], rax
loc_BDB27:
mov rdi, [rsp+68h+var_60]
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::end(void)
mov [rsp+68h+var_38], rax
lea rdi, [rsp+68h+var_30]
lea rsi, [rsp+68h+var_38]
call _ZN9__gnu_cxxneIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbRKNS_17__normal_iteratorIT_T0_EESR_; __gnu_cxx::operator!=<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>(__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>> const&,__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>> const&)
test al, 1
jnz short loc_BDB4B
jmp short loc_BDBA2
loc_BDB4B:
mov rax, [rsp+68h+var_60]
add rax, 18h
mov [rsp+68h+var_68], rax
lea rdi, [rsp+68h+var_30]
call _ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEptEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator->(void)
mov rdi, [rsp+68h+var_68]
mov rsi, rax
mov rdx, [rsp+68h+var_20]
call _ZNKSt8equal_toIvEclIRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_EEDTeqclsr3stdE7forwardIT_Efp_Eclsr3stdE7forwardIT0_Efp0_EEOSA_OSB_
test al, 1
jnz short loc_BDB79
jmp short loc_BDB94
loc_BDB79:
mov [rsp+68h+var_39], 0
lea rdi, [rsp+68h+var_10]
lea rsi, [rsp+68h+var_30]
lea rdx, [rsp+68h+var_39]
call _ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2IRSM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISR_SS_EEEbE4typeELb1EEEOSR_OSS_
jmp short loc_BDBF2
loc_BDB94:
jmp short $+2
loc_BDB96:
lea rdi, [rsp+68h+var_30]
call _ZN9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEppEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator++(void)
jmp short loc_BDB27
loc_BDBA2:
mov rdi, [rsp+68h+var_60]
mov rsi, [rsp+68h+var_20]
mov rdx, [rsp+68h+var_28]
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE12emplace_backIJRS7_SF_EEERSG_DpOT_; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::emplace_back<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &&)
mov rdi, [rsp+68h+var_60]
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::end(void)
mov [rsp+68h+var_50], rax
mov rdi, [rsp+68h+var_50]
mov esi, 1
call _ZSt4prevIN9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSB_11ordered_mapESt6vectorS8_blmdSaNSB_14adl_serializerESE_IhSaIhEEvEEESE_ISJ_SaISJ_EEEEET_SO_NSt15iterator_traitsISO_E15difference_typeE; std::prev<__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>>(__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>,std::iterator_traits<__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>>::difference_type)
mov [rsp+68h+var_48], rax
mov [rsp+68h+var_51], 1
lea rdi, [rsp+68h+var_10]
lea rsi, [rsp+68h+var_48]
lea rdx, [rsp+68h+var_51]
call _ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2ISM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISQ_SR_EEEbE4typeELb1EEEOSQ_OSR_
loc_BDBF2:
mov rax, [rsp+68h+var_10]
mov dl, [rsp+68h+var_8]
add rsp, 68h
retn
| long long nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::emplace(
long long a1,
long long a2,
long long a3)
{
long long v3; // rax
char v5; // [rsp+17h] [rbp-51h] BYREF
long long v6; // [rsp+18h] [rbp-50h]
long long v7; // [rsp+20h] [rbp-48h] BYREF
char v8; // [rsp+2Fh] [rbp-39h] BYREF
long long v9; // [rsp+30h] [rbp-38h] BYREF
long long i; // [rsp+38h] [rbp-30h] BYREF
long long v11; // [rsp+40h] [rbp-28h]
long long v12; // [rsp+48h] [rbp-20h]
long long v13; // [rsp+50h] [rbp-18h]
long long v14; // [rsp+58h] [rbp-10h] BYREF
v13 = a1;
v12 = a2;
v11 = a3;
for ( i = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::begin(a1);
;
__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator++(&i) )
{
v9 = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::end(a1);
if ( !__gnu_cxx::operator!=<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>(
(long long)&i,
(long long)&v9) )
break;
v3 = __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator->((long long)&i);
if ( (std::equal_to<void>::operator()<std::string const&,std::string const&>(a1 + 24, v3, v12) & 1) != 0 )
{
v8 = 0;
ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2IRSM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISR_SS_EEEbE4typeELb1EEEOSR_OSS_(
&v14,
&i,
&v8);
return v14;
}
}
std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::emplace_back<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(
a1,
v12,
v11);
v6 = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::end(a1);
v7 = std::prev<__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>>(
v6,
1LL);
v5 = 1;
ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2ISM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISQ_SR_EEEbE4typeELb1EEEOSQ_OSR_(
&v14,
&v7,
&v5);
return v14;
}
| __miter_base<__gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const*,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>>>>>:
MOV qword ptr [RSP + -0x10],RDI
MOV RAX,qword ptr [RSP + -0x10]
MOV qword ptr [RSP + -0x8],RAX
MOV RAX,qword ptr [RSP + -0x8]
RET
|
/* __gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const*,
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> > > >
std::__miter_base<__gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const*,
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> > > >
>(__gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const*,
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> > > >) */
int8
std::
__miter_base<__gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const*,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>>>>>
(int8 param_1)
{
return param_1;
}
| |
22,175 | nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&) | monkey531[P]llama/common/./json.hpp | std::pair<iterator, bool> emplace(const key_type& key, T&& t)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return {it, false};
}
}
Container::emplace_back(key, std::forward<T>(t));
return {std::prev(this->end()), true};
} | O1 | cpp | nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r14
movq (%rdi), %rbx
cmpq 0x8(%rdi), %rbx
sete %bpl
je 0x51dda
movq %rbx, %rdi
movq %r12, %rsi
callq 0x50121
testb %al, %al
jne 0x51dd5
addq $0x60, %rbx
cmpq 0x8(%r14), %rbx
jmp 0x51db6
testb %bpl, %bpl
je 0x51df4
movq %r14, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x51e02
movq 0x8(%r14), %rbx
addq $-0x60, %rbx
movb $0x1, %dl
jmp 0x51df6
xorl %edx, %edx
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceERSJ_OSF_:
push rbp
push r15
push r14
push r12
push rbx
mov r15, rdx
mov r12, rsi
mov r14, rdi
mov rbx, [rdi]
cmp rbx, [rdi+8]
loc_51DB6:
setz bpl
jz short loc_51DDA
mov rdi, rbx
mov rsi, r12
call _ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_; nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&)
test al, al
jnz short loc_51DD5
add rbx, 60h ; '`'
cmp rbx, [r14+8]
jmp short loc_51DB6
loc_51DD5:
test bpl, bpl
jz short loc_51DF4
loc_51DDA:
mov rdi, r14
mov rsi, r12
mov rdx, r15
call _ZNSt6vectorISt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES_IhSaIhEEvEEN5minja5ValueEESaISI_EE12emplace_backIJRSF_SH_EEERSI_DpOT_; std::vector<std::pair<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,minja::Value>>::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> const&,minja::Value>(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&,minja::Value &&)
mov rbx, [r14+8]
add rbx, 0FFFFFFFFFFFFFFA0h
mov dl, 1
jmp short loc_51DF6
loc_51DF4:
xor edx, edx
loc_51DF6:
mov rax, rbx
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| long long nlohmann::json_abi_v3_11_3::ordered_map<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>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<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,minja::Value>>>::emplace(
long long a1,
unsigned __int8 *a2,
long long a3,
__m128d a4)
{
unsigned __int8 *v5; // rbx
bool i; // zf
bool v7; // bp
v5 = *(unsigned __int8 **)a1;
for ( i = *(_QWORD *)a1 == *(_QWORD *)(a1 + 8); ; i = v5 == *(unsigned __int8 **)(a1 + 8) )
{
v7 = i;
if ( i )
break;
if ( (unsigned __int8)nlohmann::json_abi_v3_11_3::operator==(v5, a2, a4) )
{
if ( !v7 )
return (long long)v5;
break;
}
v5 += 96;
}
std::vector<std::pair<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,minja::Value>>::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> const&,minja::Value>(
a1,
a2,
a3);
return *(_QWORD *)(a1 + 8) - 96LL;
}
| emplace:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV R15,RDX
MOV R12,RSI
MOV R14,RDI
MOV RBX,qword ptr [RDI]
CMP RBX,qword ptr [RDI + 0x8]
LAB_00151db6:
SETZ BPL
JZ 0x00151dda
MOV RDI,RBX
MOV RSI,R12
CALL 0x00150121
TEST AL,AL
JNZ 0x00151dd5
ADD RBX,0x60
CMP RBX,qword ptr [R14 + 0x8]
JMP 0x00151db6
LAB_00151dd5:
TEST BPL,BPL
JZ 0x00151df4
LAB_00151dda:
MOV RDI,R14
MOV RSI,R12
MOV RDX,R15
CALL 0x00151e02
MOV RBX,qword ptr [R14 + 0x8]
ADD RBX,-0x60
MOV DL,0x1
JMP 0x00151df6
LAB_00151df4:
XOR EDX,EDX
LAB_00151df6:
MOV RAX,RBX
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
/* nlohmann::json_abi_v3_11_3::ordered_map<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>, minja::Value,
std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> >,
std::allocator<std::pair<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, minja::Value> >
>::emplace(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&, minja::Value&&) */
int1 [16] __thiscall
nlohmann::json_abi_v3_11_3::
ordered_map<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>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<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,minja::Value>>>
::emplace(ordered_map<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>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<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,minja::Value>>>
*this,basic_json *param_1,Value *param_2)
{
char cVar1;
int8 extraout_RDX;
int8 uVar2;
basic_json *pbVar3;
bool bVar4;
int1 auVar5 [16];
pbVar3 = *(basic_json **)this;
bVar4 = pbVar3 == *(basic_json **)(this + 8);
do {
if (bVar4) {
LAB_00151dda:
std::
vector<std::pair<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,minja::Value>,std::allocator<std::pair<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,minja::Value>>>
::
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>const&,minja::Value>
((vector<std::pair<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,minja::Value>,std::allocator<std::pair<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,minja::Value>>>
*)this,param_1,param_2);
pbVar3 = (basic_json *)(*(long *)(this + 8) + -0x60);
uVar2 = CONCAT71((int7)((ulong)extraout_RDX >> 8),1);
LAB_00151df6:
auVar5._8_8_ = uVar2;
auVar5._0_8_ = pbVar3;
return auVar5;
}
cVar1 = operator==(pbVar3,param_1);
if (cVar1 != '\0') {
if (!bVar4) {
uVar2 = 0;
goto LAB_00151df6;
}
goto LAB_00151dda;
}
pbVar3 = pbVar3 + 0x60;
bVar4 = pbVar3 == *(basic_json **)(this + 8);
} while( true );
}
| |
22,176 | nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&) | monkey531[P]llama/common/./json.hpp | std::pair<iterator, bool> emplace(const key_type& key, T&& t)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return {it, false};
}
}
Container::emplace_back(key, std::forward<T>(t));
return {std::prev(this->end()), true};
} | O2 | cpp | nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r14
movq (%rdi), %rbx
cmpq 0x8(%r14), %rbx
je 0x45735
movq %rbx, %rdi
movq %r12, %rsi
callq 0x263d8
testb %al, %al
jne 0x4574f
addq $0x30, %rbx
jmp 0x4571a
movq %r14, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x45760
movq 0x8(%r14), %rbx
addq $-0x30, %rbx
movb $0x1, %dl
jmp 0x45751
xorl %edx, %edx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE7emplaceERSH_OSD_:
push r15
push r14
push r12
push rbx
push rax
mov r15, rdx
mov r12, rsi
mov r14, rdi
mov rbx, [rdi]
loc_4571A:
cmp rbx, [r14+8]
jz short loc_45735
mov rdi, rbx
mov rsi, r12
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
test al, al
jnz short loc_4574F
add rbx, 30h ; '0'
jmp short loc_4571A
loc_45735:
mov rdi, r14
mov rsi, r12
mov rdx, r15
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE12emplace_backIJRS7_SF_EEERSG_DpOT_; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::emplace_back<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &&)
mov rbx, [r14+8]
add rbx, 0FFFFFFFFFFFFFFD0h
mov dl, 1
jmp short loc_45751
loc_4574F:
xor edx, edx
loc_45751:
mov rax, rbx
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
| long long nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::emplace(
_QWORD **a1,
_QWORD *a2,
long long a3)
{
_QWORD *i; // rbx
for ( i = *a1; i != a1[1]; i += 6 )
{
if ( std::operator==<char>(i, a2) )
return (long long)i;
}
std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::emplace_back<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(
a1,
a2,
a3);
return (long long)(a1[1] - 6);
}
| |||
22,177 | nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&) | monkey531[P]llama/common/./json.hpp | std::pair<iterator, bool> emplace(const key_type& key, T&& t)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return {it, false};
}
}
Container::emplace_back(key, std::forward<T>(t));
return {std::prev(this->end()), true};
} | O3 | cpp | nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, (%rsp)
movq %rsi, %r12
movq %rdi, %r14
movq (%rdi), %rbx
movq 0x8(%rdi), %r15
cmpq %r15, %rbx
je 0x4a6b4
movq (%r12), %r13
movq 0x8(%r12), %rbp
cmpq %rbp, 0x8(%rbx)
jne 0x4a6ab
testq %rbp, %rbp
je 0x4a6cf
movq (%rbx), %rdi
movq %r13, %rsi
movq %rbp, %rdx
callq 0x186e0
testl %eax, %eax
je 0x4a6cf
addq $0x30, %rbx
cmpq %r15, %rbx
jne 0x4a68e
movq %r14, %rdi
movq %r12, %rsi
movq (%rsp), %rdx
callq 0x4a6e4
movq 0x8(%r14), %rbx
addq $-0x30, %rbx
movb $0x1, %dl
jmp 0x4a6d1
xorl %edx, %edx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE7emplaceERSH_OSD_:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov [rsp+38h+var_38], rdx
mov r12, rsi
mov r14, rdi
mov rbx, [rdi]
mov r15, [rdi+8]
cmp rbx, r15
jz short loc_4A6B4
mov r13, [r12]
mov rbp, [r12+8]
loc_4A68E:
cmp [rbx+8], rbp
jnz short loc_4A6AB
test rbp, rbp
jz short loc_4A6CF
mov rdi, [rbx]
mov rsi, r13
mov rdx, rbp
call _bcmp
test eax, eax
jz short loc_4A6CF
loc_4A6AB:
add rbx, 30h ; '0'
cmp rbx, r15
jnz short loc_4A68E
loc_4A6B4:
mov rdi, r14
mov rsi, r12
mov rdx, [rsp+38h+var_38]
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE12emplace_backIJRS7_SF_EEERSG_DpOT_; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::emplace_back<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &&)
mov rbx, [r14+8]
add rbx, 0FFFFFFFFFFFFFFD0h
mov dl, 1
jmp short loc_4A6D1
loc_4A6CF:
xor edx, edx
loc_4A6D1:
mov rax, rbx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::emplace(
_QWORD *a1,
long long *a2,
long long a3)
{
_QWORD *v3; // rbx
_QWORD *v4; // r15
long long v5; // r13
long long v6; // rbp
v3 = (_QWORD *)*a1;
v4 = (_QWORD *)a1[1];
if ( (_QWORD *)*a1 == v4 )
{
LABEL_7:
std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::emplace_back<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(
a1,
a2,
a3);
return a1[1] - 48LL;
}
else
{
v5 = *a2;
v6 = a2[1];
while ( v3[1] != v6 || v6 && (unsigned int)bcmp(*v3, v5) )
{
v3 += 6;
if ( v3 == v4 )
goto LABEL_7;
}
}
return (long long)v3;
}
| emplace:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV qword ptr [RSP],RDX
MOV R12,RSI
MOV R14,RDI
MOV RBX,qword ptr [RDI]
MOV R15,qword ptr [RDI + 0x8]
CMP RBX,R15
JZ 0x0014a6b4
MOV R13,qword ptr [R12]
MOV RBP,qword ptr [R12 + 0x8]
LAB_0014a68e:
CMP qword ptr [RBX + 0x8],RBP
JNZ 0x0014a6ab
TEST RBP,RBP
JZ 0x0014a6cf
MOV RDI,qword ptr [RBX]
MOV RSI,R13
MOV RDX,RBP
CALL 0x001186e0
TEST EAX,EAX
JZ 0x0014a6cf
LAB_0014a6ab:
ADD RBX,0x30
CMP RBX,R15
JNZ 0x0014a68e
LAB_0014a6b4:
MOV RDI,R14
MOV RSI,R12
MOV RDX,qword ptr [RSP]
CALL 0x0014a6e4
MOV RBX,qword ptr [R14 + 0x8]
ADD RBX,-0x30
MOV DL,0x1
JMP 0x0014a6d1
LAB_0014a6cf:
XOR EDX,EDX
LAB_0014a6d1:
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::string,
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::string const,
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> > > >::emplace(std::__cxx11::string const&,
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector,
std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>&&) */
int1 [16] __thiscall
nlohmann::json_abi_v3_11_3::
ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
::emplace(ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
*this,string *param_1,basic_json *param_2)
{
int8 *puVar1;
void *__s2;
size_t __n;
int iVar2;
int8 extraout_RDX;
int8 uVar3;
int8 *puVar4;
int1 auVar5 [16];
puVar4 = *(int8 **)this;
puVar1 = *(int8 **)(this + 8);
if (puVar4 != puVar1) {
__s2 = *(void **)param_1;
__n = *(size_t *)(param_1 + 8);
do {
if (puVar4[1] == __n) {
if (__n != 0) {
iVar2 = bcmp((void *)*puVar4,__s2,__n);
if (iVar2 != 0) goto LAB_0014a6ab;
}
uVar3 = 0;
goto LAB_0014a6d1;
}
LAB_0014a6ab:
puVar4 = puVar4 + 6;
} while (puVar4 != puVar1);
}
std::
vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
::
emplace_back<std::__cxx11::string_const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
((vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>
*)this,param_1,param_2);
puVar4 = (int8 *)(*(long *)(this + 8) + -0x30);
uVar3 = CONCAT71((int7)((ulong)extraout_RDX >> 8),1);
LAB_0014a6d1:
auVar5._8_8_ = uVar3;
auVar5._0_8_ = puVar4;
return auVar5;
}
| |
22,178 | my_hash_sort_utf32_nopad | eloqsql/strings/ctype-ucs2.c | static void
my_hash_sort_utf32_nopad(CHARSET_INFO *cs, const uchar *s, size_t slen,
ulong *nr1, ulong *nr2)
{
my_wc_t wc;
int res;
const uchar *e= s + slen;
MY_UNICASE_INFO *uni_plane= cs->caseinfo;
register ulong m1= *nr1, m2= *nr2;
while ((res= my_utf32_uni(cs, &wc, (uchar*) s, (uchar*) e)) > 0)
{
my_tosort_utf32(uni_plane, &wc);
MY_HASH_ADD(m1, m2, (uint) (wc >> 24));
MY_HASH_ADD(m1, m2, (uint) (wc >> 16) & 0xFF);
MY_HASH_ADD(m1, m2, (uint) (wc >> 8) & 0xFF);
MY_HASH_ADD(m1, m2, (uint) (wc & 0xFF));
s+= res;
}
*nr1= m1;
*nr2= m2;
} | O3 | c | my_hash_sort_utf32_nopad:
movq (%rcx), %r10
movq (%r8), %rax
cmpq $0x4, %rdx
jl 0xc82c9
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
addq %rsi, %rdx
movq 0x78(%rdi), %rdi
movl $0xff, %r9d
movzbl (%rsi), %ebx
shll $0x18, %ebx
movzbl 0x1(%rsi), %r11d
shll $0x10, %r11d
orl %ebx, %r11d
cmpl $0x10ffff, %r11d # imm = 0x10FFFF
ja 0xc82c3
movzbl 0x2(%rsi), %r14d
shll $0x8, %r14d
movzbl 0x3(%rsi), %ebx
orq %rbx, %r14
orq %r11, %r14
movl $0xfffd, %r11d # imm = 0xFFFD
cmpq (%rdi), %r14
ja 0xc8219
movq 0x8(%rdi), %r11
movl %r14d, %r15d
shrl $0x8, %r15d
movq (%r11,%r15,8), %r15
movq %r14, %r11
testq %r15, %r15
je 0xc8219
leaq (%rbx,%rbx,2), %r11
movl 0x8(%r15,%r11,4), %r11d
movl %r10d, %ebx
andl $0x3f, %ebx
addq %rax, %rbx
movl %r11d, %r14d
shrl $0x18, %r14d
imulq %rbx, %r14
movq %r10, %rbx
shlq $0x8, %rbx
addq %r14, %rbx
xorq %r10, %rbx
movl %ebx, %r10d
andl $0x3f, %r10d
addq %rax, %r10
addq $0x3, %r10
movl %r11d, %r14d
shrl $0x10, %r14d
andl %r9d, %r14d
imulq %r10, %r14
movq %rbx, %r10
shlq $0x8, %r10
addq %r14, %r10
xorq %rbx, %r10
movl %r10d, %ebx
andl $0x3f, %ebx
addq %rax, %rbx
addq $0x6, %rbx
movl %r11d, %r14d
shrl $0x8, %r14d
andl %r9d, %r14d
imulq %rbx, %r14
movq %r10, %rbx
shlq $0x8, %rbx
addq %r14, %rbx
xorq %r10, %rbx
movl %ebx, %r10d
andl $0x3f, %r10d
addq %rax, %r10
addq $0x9, %r10
movzbl %r11b, %r11d
imulq %r10, %r11
movq %rbx, %r10
shlq $0x8, %r10
addq %r11, %r10
xorq %rbx, %r10
addq $0xc, %rax
leaq 0x8(%rsi), %r11
addq $0x4, %rsi
cmpq %rdx, %r11
jbe 0xc81bc
popq %rbx
popq %r14
popq %r15
popq %rbp
movq %r10, (%rcx)
movq %rax, (%r8)
retq
| my_hash_sort_utf32_nopad:
mov r10, [rcx]
mov rax, [r8]
cmp rdx, 4
jl loc_C82C9
push rbp
mov rbp, rsp
push r15
push r14
push rbx
add rdx, rsi
mov rdi, [rdi+78h]
mov r9d, 0FFh
loc_C81BC:
movzx ebx, byte ptr [rsi]
shl ebx, 18h
movzx r11d, byte ptr [rsi+1]
shl r11d, 10h
or r11d, ebx
cmp r11d, offset unk_10FFFF
ja loc_C82C3
movzx r14d, byte ptr [rsi+2]
shl r14d, 8
movzx ebx, byte ptr [rsi+3]
or r14, rbx
or r14, r11
mov r11d, 0FFFDh
cmp r14, [rdi]
ja short loc_C8219
mov r11, [rdi+8]
mov r15d, r14d
shr r15d, 8
mov r15, [r11+r15*8]
mov r11, r14
test r15, r15
jz short loc_C8219
lea r11, [rbx+rbx*2]
mov r11d, [r15+r11*4+8]
loc_C8219:
mov ebx, r10d
and ebx, 3Fh
add rbx, rax
mov r14d, r11d
shr r14d, 18h
imul r14, rbx
mov rbx, r10
shl rbx, 8
add rbx, r14
xor rbx, r10
mov r10d, ebx
and r10d, 3Fh
add r10, rax
add r10, 3
mov r14d, r11d
shr r14d, 10h
and r14d, r9d
imul r14, r10
mov r10, rbx
shl r10, 8
add r10, r14
xor r10, rbx
mov ebx, r10d
and ebx, 3Fh
add rbx, rax
add rbx, 6
mov r14d, r11d
shr r14d, 8
and r14d, r9d
imul r14, rbx
mov rbx, r10
shl rbx, 8
add rbx, r14
xor rbx, r10
mov r10d, ebx
and r10d, 3Fh
add r10, rax
add r10, 9
movzx r11d, r11b
imul r11, r10
mov r10, rbx
shl r10, 8
add r10, r11
xor r10, rbx
add rax, 0Ch
lea r11, [rsi+8]
add rsi, 4
cmp r11, rdx
jbe loc_C81BC
loc_C82C3:
pop rbx
pop r14
pop r15
pop rbp
loc_C82C9:
mov [rcx], r10
mov [r8], rax
retn
| long long my_hash_sort_utf32_nopad(long long a1, unsigned __int8 *a2, long long a3, long long *a4, long long *a5)
{
long long v5; // r10
long long result; // rax
unsigned __int8 *v7; // rdx
unsigned long long *v8; // rdi
long long v9; // r11
long long v10; // rbx
unsigned long long v11; // r14
unsigned int v12; // r11d
long long v13; // r15
long long v14; // r10
long long v15; // r14
unsigned __int8 *v16; // r11
v5 = *a4;
result = *a5;
if ( a3 >= 4 )
{
v7 = &a2[a3];
v8 = *(unsigned long long **)(a1 + 120);
do
{
v9 = (*a2 << 24) | (a2[1] << 16);
if ( (unsigned int)v9 > (unsigned int)&unk_10FFFF )
break;
v10 = a2[3];
v11 = v9 | v10 | (a2[2] << 8);
v12 = 65533;
if ( v11 <= *v8 )
{
v13 = *(_QWORD *)(v8[1] + 8LL * ((unsigned int)v11 >> 8));
v12 = v11;
if ( v13 )
v12 = *(_DWORD *)(v13 + 12 * v10 + 8);
}
v14 = v5 ^ ((result + (v5 & 0x3F)) * HIBYTE(v12) + (v5 << 8)) ^ ((result
+ (((unsigned __int8)v5 ^ (unsigned __int8)((result + (v5 & 0x3F)) * HIBYTE(v12))) & 0x3F)
+ 3)
* BYTE2(v12)
+ ((v5 ^ ((result + (v5 & 0x3F)) * HIBYTE(v12)
+ (v5 << 8))) << 8));
v15 = (result + (v14 & 0x3F) + 6) * BYTE1(v12);
v5 = v14 ^ (v15 + (v14 << 8)) ^ ((result + (((unsigned __int8)v14 ^ (unsigned __int8)v15) & 0x3F) + 9)
* (unsigned __int8)v12
+ ((v14 ^ (v15 + (v14 << 8))) << 8));
result += 12LL;
v16 = a2 + 8;
a2 += 4;
}
while ( v16 <= v7 );
}
*a4 = v5;
*a5 = result;
return result;
}
| my_hash_sort_utf32_nopad:
MOV R10,qword ptr [RCX]
MOV RAX,qword ptr [R8]
CMP RDX,0x4
JL 0x001c82c9
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
ADD RDX,RSI
MOV RDI,qword ptr [RDI + 0x78]
MOV R9D,0xff
LAB_001c81bc:
MOVZX EBX,byte ptr [RSI]
SHL EBX,0x18
MOVZX R11D,byte ptr [RSI + 0x1]
SHL R11D,0x10
OR R11D,EBX
CMP R11D,0x10ffff
JA 0x001c82c3
MOVZX R14D,byte ptr [RSI + 0x2]
SHL R14D,0x8
MOVZX EBX,byte ptr [RSI + 0x3]
OR R14,RBX
OR R14,R11
MOV R11D,0xfffd
CMP R14,qword ptr [RDI]
JA 0x001c8219
MOV R11,qword ptr [RDI + 0x8]
MOV R15D,R14D
SHR R15D,0x8
MOV R15,qword ptr [R11 + R15*0x8]
MOV R11,R14
TEST R15,R15
JZ 0x001c8219
LEA R11,[RBX + RBX*0x2]
MOV R11D,dword ptr [R15 + R11*0x4 + 0x8]
LAB_001c8219:
MOV EBX,R10D
AND EBX,0x3f
ADD RBX,RAX
MOV R14D,R11D
SHR R14D,0x18
IMUL R14,RBX
MOV RBX,R10
SHL RBX,0x8
ADD RBX,R14
XOR RBX,R10
MOV R10D,EBX
AND R10D,0x3f
ADD R10,RAX
ADD R10,0x3
MOV R14D,R11D
SHR R14D,0x10
AND R14D,R9D
IMUL R14,R10
MOV R10,RBX
SHL R10,0x8
ADD R10,R14
XOR R10,RBX
MOV EBX,R10D
AND EBX,0x3f
ADD RBX,RAX
ADD RBX,0x6
MOV R14D,R11D
SHR R14D,0x8
AND R14D,R9D
IMUL R14,RBX
MOV RBX,R10
SHL RBX,0x8
ADD RBX,R14
XOR RBX,R10
MOV R10D,EBX
AND R10D,0x3f
ADD R10,RAX
ADD R10,0x9
MOVZX R11D,R11B
IMUL R11,R10
MOV R10,RBX
SHL R10,0x8
ADD R10,R11
XOR R10,RBX
ADD RAX,0xc
LEA R11,[RSI + 0x8]
ADD RSI,0x4
CMP R11,RDX
JBE 0x001c81bc
LAB_001c82c3:
POP RBX
POP R14
POP R15
POP RBP
LAB_001c82c9:
MOV qword ptr [RCX],R10
MOV qword ptr [R8],RAX
RET
|
void my_hash_sort_utf32_nopad(long param_1,byte *param_2,long param_3,ulong *param_4,long *param_5)
{
byte *pbVar1;
long lVar2;
long lVar3;
byte *pbVar4;
ulong uVar5;
uint uVar6;
ulong uVar7;
ulong uVar8;
uVar5 = *param_4;
lVar3 = *param_5;
if (3 < param_3) {
pbVar4 = param_2 + param_3;
do {
uVar6 = (uint)param_2[1] << 0x10 | (uint)*param_2 << 0x18;
if (0x10ffff < uVar6) break;
uVar8 = (ulong)CONCAT11(param_2[2],param_2[3]) | (ulong)uVar6;
uVar7 = 0xfffd;
if ((uVar8 <= **(ulong **)(param_1 + 0x78)) &&
(lVar2 = *(long *)((*(ulong **)(param_1 + 0x78))[1] + (uVar8 >> 8) * 8), uVar7 = uVar8,
lVar2 != 0)) {
uVar7 = (ulong)*(uint *)(lVar2 + 8 + (ulong)param_2[3] * 0xc);
}
uVar5 = uVar5 * 0x100 + (uVar7 >> 0x18) * ((ulong)((uint)uVar5 & 0x3f) + lVar3) ^ uVar5;
uVar5 = uVar5 * 0x100 +
(ulong)((uint)(uVar7 >> 0x10) & 0xff) * ((ulong)((uint)uVar5 & 0x3f) + lVar3 + 3) ^
uVar5;
uVar5 = uVar5 * 0x100 +
(ulong)((uint)(uVar7 >> 8) & 0xff) * ((ulong)((uint)uVar5 & 0x3f) + lVar3 + 6) ^ uVar5
;
uVar5 = uVar5 * 0x100 + (uVar7 & 0xff) * ((ulong)((uint)uVar5 & 0x3f) + lVar3 + 9) ^ uVar5;
lVar3 = lVar3 + 0xc;
pbVar1 = param_2 + 8;
param_2 = param_2 + 4;
} while (pbVar1 <= pbVar4);
}
*param_4 = uVar5;
*param_5 = lVar3;
return;
}
| |
22,179 | break_str_into_lines(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, unsigned long) | monkey531[P]llama/common/arg.cpp | static std::vector<std::string> break_str_into_lines(std::string input, size_t max_char_per_line) {
std::vector<std::string> result;
std::istringstream iss(input);
std::string line;
auto add_line = [&](const std::string& l) {
if (l.length() <= max_char_per_line) {
result.push_back(l);
} else {
std::istringstream line_stream(l);
std::string word, current_line;
while (line_stream >> word) {
if (current_line.length() + !current_line.empty() + word.length() > max_char_per_line) {
if (!current_line.empty()) result.push_back(current_line);
current_line = word;
} else {
current_line += (!current_line.empty() ? " " : "") + word;
}
}
if (!current_line.empty()) result.push_back(current_line);
}
};
while (std::getline(iss, line)) {
add_line(line);
}
return result;
} | O0 | cpp | break_str_into_lines(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, unsigned long):
subq $0x208, %rsp # imm = 0x208
movq %rsi, 0x20(%rsp)
movq %rdi, 0x10(%rsp)
movq %rdi, %rax
movq %rax, 0x18(%rsp)
movq %rdi, 0x200(%rsp)
movq %rsi, 0x1f8(%rsp)
movq %rdx, 0x1f0(%rsp)
movb $0x0, 0x1ef(%rsp)
callq 0x63190
movq 0x20(%rsp), %rsi
leaq 0x68(%rsp), %rdi
movl $0x8, %edx
callq 0x5a800
jmp 0x68e64
leaq 0x38(%rsp), %rdi
callq 0x5a5e0
movq 0x10(%rsp), %rax
leaq 0x1f0(%rsp), %rcx
movq %rcx, 0x28(%rsp)
movq %rax, 0x30(%rsp)
leaq 0x68(%rsp), %rdi
leaq 0x38(%rsp), %rsi
callq 0x5a8d0
movq %rax, 0x8(%rsp)
jmp 0x68e9b
movq 0x8(%rsp), %rdi
movq (%rdi), %rax
movq -0x18(%rax), %rax
addq %rax, %rdi
callq 0x5a620
movb %al, 0x7(%rsp)
jmp 0x68eb5
movb 0x7(%rsp), %al
testb $0x1, %al
jne 0x68ebf
jmp 0x68f06
leaq 0x28(%rsp), %rdi
leaq 0x38(%rsp), %rsi
callq 0x82650
jmp 0x68ed0
jmp 0x68e85
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
jmp 0x68f43
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x60(%rsp)
movl %eax, 0x5c(%rsp)
leaq 0x38(%rsp), %rdi
callq 0x5b588
leaq 0x68(%rsp), %rdi
callq 0x5a9b0
jmp 0x68f43
movb $0x1, 0x1ef(%rsp)
leaq 0x38(%rsp), %rdi
callq 0x5b588
leaq 0x68(%rsp), %rdi
callq 0x5a9b0
testb $0x1, 0x1ef(%rsp)
jne 0x68f36
movq 0x10(%rsp), %rdi
callq 0x631d0
movq 0x18(%rsp), %rax
addq $0x208, %rsp # imm = 0x208
retq
movq 0x10(%rsp), %rdi
callq 0x631d0
movq 0x60(%rsp), %rdi
callq 0x5aba0
nopw (%rax,%rax)
| _ZL20break_str_into_linesNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEm:
sub rsp, 208h
mov [rsp+208h+var_1E8], rsi
mov [rsp+208h+var_1F8], rdi
mov rax, rdi
mov [rsp+208h+var_1F0], rax
mov [rsp+208h+var_8], rdi
mov [rsp+208h+var_10], rsi
mov [rsp+208h+var_18], rdx
mov [rsp+208h+var_19], 0
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EEC2Ev; std::vector<std::string>::vector(void)
mov rsi, [rsp+208h+var_1E8]
lea rdi, [rsp+208h+var_1A0]
mov edx, 8
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEEC1ERKNS_12basic_stringIcS2_S3_EESt13_Ios_Openmode; std::istringstream::basic_istringstream(std::string const&,std::_Ios_Openmode)
jmp short $+2
loc_68E64:
lea rdi, [rsp+208h+var_1D0]
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev; std::string::basic_string(void)
mov rax, [rsp+208h+var_1F8]
lea rcx, [rsp+208h+var_18]
mov [rsp+208h+var_1E0], rcx
mov [rsp+208h+var_1D8], rax
loc_68E85:
lea rdi, [rsp+208h+var_1A0]
lea rsi, [rsp+208h+var_1D0]
call __ZSt7getlineIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::getline<char,std::char_traits<char>,std::allocator<char>>(std::istream &,std::string &)
mov [rsp+208h+var_200], rax
jmp short $+2
loc_68E9B:
mov rdi, [rsp+208h+var_200]
mov rax, [rdi]
mov rax, [rax-18h]
add rdi, rax
call __ZNKSt9basic_iosIcSt11char_traitsIcEEcvbEv; std::ios::operator bool(void)
mov [rsp+208h+var_201], al
jmp short $+2
loc_68EB5:
mov al, [rsp+208h+var_201]
test al, 1
jnz short loc_68EBF
jmp short loc_68F06
loc_68EBF:
lea rdi, [rsp+208h+var_1E0]
lea rsi, [rsp+208h+var_1D0]
call _ZZL20break_str_into_linesNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEmENK3$_0clERKS4_; break_str_into_lines(std::string,ulong)::$_0::operator()(std::string const&)
jmp short $+2
loc_68ED0:
jmp short loc_68E85
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
jmp short loc_68F43
mov rcx, rax
mov eax, edx
mov [rsp+arg_58], rcx
mov [rsp+arg_54], eax
lea rdi, [rsp+arg_30]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+arg_60]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev; std::istringstream::~istringstream()
jmp short loc_68F43
loc_68F06:
mov [rsp+208h+var_19], 1
lea rdi, [rsp+208h+var_1D0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+208h+var_1A0]
call __ZNSt7__cxx1119basic_istringstreamIcSt11char_traitsIcESaIcEED1Ev; std::istringstream::~istringstream()
test [rsp+208h+var_19], 1
jnz short loc_68F36
mov rdi, [rsp+208h+var_1F8]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
loc_68F36:
mov rax, [rsp+208h+var_1F0]
add rsp, 208h
retn
loc_68F43:
mov rdi, [rsp+arg_8]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, [rsp+arg_58]
call __Unwind_Resume
| long long break_str_into_lines(long long a1, long long a2, long long a3)
{
int v3; // edx
int v4; // ecx
int v5; // r8d
int v6; // r9d
int v8; // [rsp+0h] [rbp-208h]
_QWORD *v9; // [rsp+8h] [rbp-200h]
long long *v10; // [rsp+10h] [rbp-1F8h]
long long v11; // [rsp+18h] [rbp-1F0h]
char v12; // [rsp+20h] [rbp-1E8h]
_QWORD *v13; // [rsp+28h] [rbp-1E0h] BYREF
long long i; // [rsp+30h] [rbp-1D8h]
_DWORD v15[4]; // [rsp+38h] [rbp-1D0h] BYREF
long long v16; // [rsp+48h] [rbp-1C0h]
char v17; // [rsp+50h] [rbp-1B8h]
int v18; // [rsp+58h] [rbp-1B0h]
int v19; // [rsp+60h] [rbp-1A8h]
int v20; // [rsp+68h] [rbp-1A0h] BYREF
char v21; // [rsp+70h] [rbp-198h]
int v22; // [rsp+78h] [rbp-190h]
int v23; // [rsp+80h] [rbp-188h]
int v24; // [rsp+88h] [rbp-180h]
char v25; // [rsp+90h] [rbp-178h]
char v26; // [rsp+1EFh] [rbp-19h]
_QWORD v27[3]; // [rsp+1F0h] [rbp-18h] BYREF
v12 = a2;
v10 = (long long *)a1;
v11 = a1;
v27[2] = a1;
v27[1] = a2;
v27[0] = a3;
v26 = 0;
std::vector<std::string>::vector(a1);
std::istringstream::basic_istringstream(&v20, a2, 8LL);
std::string::basic_string(v15);
v13 = v27;
for ( i = a1;
;
break_str_into_lines(std::string,unsigned long)::$_0::operator()(
(unsigned int)&v13,
(unsigned int)v15,
v3,
v4,
v5,
v6,
v8,
(_DWORD)v9,
(_DWORD)v10,
v11,
v12,
(_DWORD)v13,
i,
v15[0],
v15[2],
v16,
v17,
v18,
v19,
v20,
v21,
v22,
v23,
v24,
v25) )
{
v9 = (_QWORD *)std::getline<char,std::char_traits<char>,std::allocator<char>>(&v20, v15);
if ( (std::ios::operator bool((char *)v9 + *(_QWORD *)(*v9 - 24LL)) & 1) == 0 )
break;
}
v26 = 1;
std::string::~string(v15);
std::istringstream::~istringstream(&v20);
if ( (v26 & 1) == 0 )
std::vector<std::string>::~vector(v10);
return v11;
}
| __unguarded_insertion_sort<llama_token_data*,__gnu_cxx::__ops::_Iter_comp_iter<main::$_1>>:
SUB RSP,0x38
MOV qword ptr [RSP + 0x28],RDI
MOV qword ptr [RSP + 0x20],RSI
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x18],RAX
LAB_00168e28:
MOV RAX,qword ptr [RSP + 0x18]
CMP RAX,qword ptr [RSP + 0x20]
JZ 0x00168e65
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP + 0x8],RAX
MOV AL,byte ptr [RSP + 0x37]
MOV byte ptr [RSP + 0x16],AL
CALL 0x00168f00
MOV RDI,qword ptr [RSP + 0x8]
CALL 0x00168e70
MOV RAX,qword ptr [RSP + 0x18]
ADD RAX,0xc
MOV qword ptr [RSP + 0x18],RAX
JMP 0x00168e28
LAB_00168e65:
ADD RSP,0x38
RET
|
/* WARNING: Unknown calling convention -- yet parameter storage is locked */
/* void std::__unguarded_insertion_sort<llama_token_data*,
__gnu_cxx::__ops::_Iter_comp_iter<main::$_1> >(llama_token_data*, llama_token_data*,
__gnu_cxx::__ops::_Iter_comp_iter<main::$_1>) */
void std::__unguarded_insertion_sort<llama_token_data*,__gnu_cxx::__ops::_Iter_comp_iter<main::__1>>
(long param_1,long param_2)
{
int8 local_20;
for (local_20 = param_1; local_20 != param_2; local_20 = local_20 + 0xc) {
__gnu_cxx::__ops::__val_comp_iter<main::__1>();
__unguarded_linear_insert<llama_token_data*,__gnu_cxx::__ops::_Val_comp_iter<main::__1>>
(local_20);
}
return;
}
| |
22,180 | ggml_graph_compute_secondary_thread | monkey531[P]llama/ggml/src/ggml-cpu/ggml-cpu.c | static thread_ret_t ggml_graph_compute_secondary_thread(void* data) {
struct ggml_compute_state * state = (struct ggml_compute_state *) data;
struct ggml_threadpool * threadpool = state->threadpool;
ggml_thread_apply_priority(threadpool->prio);
if (ggml_thread_cpumask_is_valid(state->cpumask)) {
ggml_thread_apply_affinity(state->cpumask);
}
while (true) {
// Check if we need to sleep
while (threadpool->pause) {
GGML_PRINT_DEBUG("thread #%d inside pause loop\n", state->ith);
ggml_mutex_lock_shared(&threadpool->mutex);
if (threadpool->pause) {
ggml_cond_wait(&threadpool->cond, &threadpool->mutex);
}
GGML_PRINT_DEBUG("thread #%d resuming after wait\n", state->ith);
ggml_mutex_unlock_shared(&threadpool->mutex);
}
// This needs to be checked for after the cond_wait
if (threadpool->stop) break;
// Check if there is new work
// The main thread is the only one that can dispatch new work
ggml_graph_compute_check_for_work(state);
if (state->pending) {
state->pending = false;
ggml_graph_compute_thread(state);
}
}
return (thread_ret_t) 0;
} | O3 | c | ggml_graph_compute_secondary_thread:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq 0x210(%rdi), %r14
movl 0xe0(%r14), %edi
callq 0x206b4
cmpb $0x0, 0x8(%rbx)
je 0x20681
leaq 0x8(%rbx), %rdi
callq 0x20749
leaq 0x28(%r14), %r15
movb 0xc9(%r14), %al
testb $0x1, %al
je 0x204fd
movq %r14, %rdi
callq 0x87e0
movb 0xc9(%r14), %al
testb $0x1, %al
je 0x204f3
movq %r15, %rdi
movq %r14, %rsi
callq 0x8840
movq %r14, %rdi
callq 0x83d0
jmp 0x204ca
movb 0xc8(%r14), %al
testb $0x1, %al
jne 0x20675
movq 0x210(%rbx), %r12
movl 0xdc(%r12), %ecx
movb 0x20c(%rbx), %al
cmpl %ecx, 0x218(%rbx)
jge 0x205bb
testb $0x1, %al
jne 0x205bb
movl 0xe4(%r12), %eax
shlq $0x11, %rax
xorl %ecx, %ecx
movq 0x210(%rbx), %rdx
movb 0xc8(%rdx), %sil
testb $0x1, %sil
jne 0x205b5
movb 0xc9(%rdx), %sil
testb $0x1, %sil
jne 0x205b5
movl 0x68(%rdx), %edx
cmpl 0x208(%rbx), %edx
jne 0x20578
movb 0x20c(%rbx), %sil
jmp 0x2059c
movq 0x210(%rbx), %rsi
movl 0xdc(%rsi), %esi
cmpl %esi, 0x218(%rbx)
setl %sil
setl 0x20c(%rbx)
movl %edx, 0x208(%rbx)
testb $0x1, %sil
jne 0x205b5
cmpq %rax, %rcx
jae 0x205b5
pause
incq %rcx
cmpb $0x1, 0x20c(%rbx)
jne 0x20543
movb 0x20c(%rbx), %al
testb $0x1, %al
je 0x205c4
mfence
jmp 0x205dd
movq %r12, %rdi
callq 0x87e0
cmpb $0x0, 0x20c(%rbx)
je 0x205fe
movq %r12, %rdi
callq 0x83d0
cmpb $0x1, 0x20c(%rbx)
jne 0x204ca
movb $0x0, 0x20c(%rbx)
movq %rbx, %rdi
callq 0xb3d3
jmp 0x204ca
leaq 0x28(%r12), %r13
movq 0x210(%rbx), %rax
movb 0xc8(%rax), %cl
testb $0x1, %cl
jne 0x205d5
movb 0xc9(%rax), %cl
testb $0x1, %cl
jne 0x205d5
movl 0x68(%rax), %eax
cmpl 0x208(%rbx), %eax
jne 0x20636
testb $0x1, 0x20c(%rbx)
je 0x2065c
jmp 0x205d5
movq 0x210(%rbx), %rcx
movl 0xdc(%rcx), %ecx
cmpl %ecx, 0x218(%rbx)
setl 0x20c(%rbx)
movl %eax, 0x208(%rbx)
jl 0x205d5
movq %r13, %rdi
movq %r12, %rsi
callq 0x8840
cmpb $0x1, 0x20c(%rbx)
jne 0x20603
jmp 0x205d5
xorl %eax, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq $-0x1, %rax
cmpq $0x1fe, %rax # imm = 0x1FE
je 0x204c6
leaq 0x1(%rax), %rcx
cmpb $0x1, 0xa(%rbx,%rax)
movq %rcx, %rax
jne 0x20688
cmpq $0x1fe, %rcx # imm = 0x1FE
jbe 0x204bd
jmp 0x204c6
| ggml_graph_compute_secondary_thread:
push r15
push r14
push r13
push r12
push rbx
mov rbx, rdi
mov r14, [rdi+210h]
mov edi, [r14+0E0h]
call ggml_thread_apply_priority
cmp byte ptr [rbx+8], 0
jz loc_20681
loc_204BD:
lea rdi, [rbx+8]
call ggml_thread_apply_affinity
loc_204C6:
lea r15, [r14+28h]
loc_204CA:
mov al, [r14+0C9h]
test al, 1
jz short loc_204FD
mov rdi, r14
call _pthread_mutex_lock
mov al, [r14+0C9h]
test al, 1
jz short loc_204F3
mov rdi, r15
mov rsi, r14
call _pthread_cond_wait
loc_204F3:
mov rdi, r14
call _pthread_mutex_unlock
jmp short loc_204CA
loc_204FD:
mov al, [r14+0C8h]
test al, 1
jnz loc_20675
mov r12, [rbx+210h]
mov ecx, [r12+0DCh]
mov al, [rbx+20Ch]
cmp [rbx+218h], ecx
jge loc_205BB
test al, 1
jnz loc_205BB
mov eax, [r12+0E4h]
shl rax, 11h
xor ecx, ecx
loc_20543:
mov rdx, [rbx+210h]
mov sil, [rdx+0C8h]
test sil, 1
jnz short loc_205B5
mov sil, [rdx+0C9h]
test sil, 1
jnz short loc_205B5
mov edx, [rdx+68h]
cmp edx, [rbx+208h]
jnz short loc_20578
mov sil, [rbx+20Ch]
jmp short loc_2059C
loc_20578:
mov rsi, [rbx+210h]
mov esi, [rsi+0DCh]
cmp [rbx+218h], esi
setl sil
setl byte ptr [rbx+20Ch]
mov [rbx+208h], edx
loc_2059C:
test sil, 1
jnz short loc_205B5
cmp rcx, rax
jnb short loc_205B5
pause
inc rcx
cmp byte ptr [rbx+20Ch], 1
jnz short loc_20543
loc_205B5:
mov al, [rbx+20Ch]
loc_205BB:
test al, 1
jz short loc_205C4
mfence
jmp short loc_205DD
loc_205C4:
mov rdi, r12
call _pthread_mutex_lock
cmp byte ptr [rbx+20Ch], 0
jz short loc_205FE
loc_205D5:
mov rdi, r12
call _pthread_mutex_unlock
loc_205DD:
cmp byte ptr [rbx+20Ch], 1
jnz loc_204CA
mov byte ptr [rbx+20Ch], 0
mov rdi, rbx
call ggml_graph_compute_thread
jmp loc_204CA
loc_205FE:
lea r13, [r12+28h]
loc_20603:
mov rax, [rbx+210h]
mov cl, [rax+0C8h]
test cl, 1
jnz short loc_205D5
mov cl, [rax+0C9h]
test cl, 1
jnz short loc_205D5
mov eax, [rax+68h]
cmp eax, [rbx+208h]
jnz short loc_20636
test byte ptr [rbx+20Ch], 1
jz short loc_2065C
jmp short loc_205D5
loc_20636:
mov rcx, [rbx+210h]
mov ecx, [rcx+0DCh]
cmp [rbx+218h], ecx
setl byte ptr [rbx+20Ch]
mov [rbx+208h], eax
jl loc_205D5
loc_2065C:
mov rdi, r13
mov rsi, r12
call _pthread_cond_wait
cmp byte ptr [rbx+20Ch], 1
jnz short loc_20603
jmp loc_205D5
loc_20675:
xor eax, eax
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
loc_20681:
mov rax, 0FFFFFFFFFFFFFFFFh
loc_20688:
cmp rax, 1FEh
jz loc_204C6
lea rcx, [rax+1]
cmp byte ptr [rbx+rax+0Ah], 1
mov rax, rcx
jnz short loc_20688
cmp rcx, 1FEh
jbe loc_204BD
jmp loc_204C6
| long long ggml_graph_compute_secondary_thread(long long a1)
{
long long v1; // r14
long long v2; // r12
char v3; // al
unsigned long long v4; // rax
unsigned long long v5; // rcx
long long v6; // rdx
int v7; // edx
char v8; // si
long long v9; // rax
int v10; // eax
bool v11; // cc
long long v13; // rax
unsigned long long v14; // rcx
v1 = *(_QWORD *)(a1 + 528);
ggml_thread_apply_priority(*(unsigned int *)(v1 + 224));
if ( *(_BYTE *)(a1 + 8) )
{
LABEL_2:
ggml_thread_apply_affinity(a1 + 8);
}
else
{
v13 = -1LL;
while ( v13 != 510 )
{
v14 = v13 + 1;
if ( *(_BYTE *)(a1 + v13++ + 10) == 1 )
{
if ( v14 <= 0x1FE )
goto LABEL_2;
goto LABEL_3;
}
}
}
while ( 1 )
{
LABEL_3:
while ( (*(_BYTE *)(v1 + 201) & 1) != 0 )
{
pthread_mutex_lock(v1);
if ( (*(_BYTE *)(v1 + 201) & 1) != 0 )
pthread_cond_wait(v1 + 40, v1);
pthread_mutex_unlock(v1);
}
if ( (*(_BYTE *)(v1 + 200) & 1) != 0 )
return 0LL;
v2 = *(_QWORD *)(a1 + 528);
v3 = *(_BYTE *)(a1 + 524);
if ( *(_DWORD *)(a1 + 536) < *(_DWORD *)(v2 + 220) && (v3 & 1) == 0 )
{
v4 = (unsigned long long)*(unsigned int *)(v2 + 228) << 17;
v5 = 0LL;
do
{
v6 = *(_QWORD *)(a1 + 528);
if ( (*(_BYTE *)(v6 + 200) & 1) != 0 || (*(_BYTE *)(v6 + 201) & 1) != 0 )
break;
v7 = *(_DWORD *)(v6 + 104);
if ( v7 == *(_DWORD *)(a1 + 520) )
{
v8 = *(_BYTE *)(a1 + 524);
}
else
{
v8 = *(_DWORD *)(a1 + 536) < *(_DWORD *)(*(_QWORD *)(a1 + 528) + 220LL);
*(_BYTE *)(a1 + 524) = v8;
*(_DWORD *)(a1 + 520) = v7;
}
if ( (v8 & 1) != 0 )
break;
if ( v5 >= v4 )
break;
_mm_pause();
++v5;
}
while ( *(_BYTE *)(a1 + 524) != 1 );
v3 = *(_BYTE *)(a1 + 524);
}
if ( (v3 & 1) != 0 )
{
_mm_mfence();
}
else
{
pthread_mutex_lock(v2);
if ( !*(_BYTE *)(a1 + 524) )
{
do
{
v9 = *(_QWORD *)(a1 + 528);
if ( (*(_BYTE *)(v9 + 200) & 1) != 0 || (*(_BYTE *)(v9 + 201) & 1) != 0 )
break;
v10 = *(_DWORD *)(v9 + 104);
if ( v10 == *(_DWORD *)(a1 + 520) )
{
if ( (*(_BYTE *)(a1 + 524) & 1) != 0 )
break;
}
else
{
v11 = *(_DWORD *)(a1 + 536) < *(_DWORD *)(*(_QWORD *)(a1 + 528) + 220LL);
*(_BYTE *)(a1 + 524) = v11;
*(_DWORD *)(a1 + 520) = v10;
if ( v11 )
break;
}
pthread_cond_wait(v2 + 40, v2);
}
while ( *(_BYTE *)(a1 + 524) != 1 );
}
pthread_mutex_unlock(v2);
}
if ( *(_BYTE *)(a1 + 524) == 1 )
{
*(_BYTE *)(a1 + 524) = 0;
ggml_graph_compute_thread(a1);
}
}
}
| ggml_graph_compute_secondary_thread:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV RBX,RDI
MOV R14,qword ptr [RDI + 0x210]
MOV EDI,dword ptr [R14 + 0xe0]
CALL 0x001206b4
CMP byte ptr [RBX + 0x8],0x0
JZ 0x00120681
LAB_001204bd:
LEA RDI,[RBX + 0x8]
CALL 0x00120749
LAB_001204c6:
LEA R15,[R14 + 0x28]
LAB_001204ca:
MOV AL,byte ptr [R14 + 0xc9]
TEST AL,0x1
JZ 0x001204fd
MOV RDI,R14
CALL 0x001087e0
MOV AL,byte ptr [R14 + 0xc9]
TEST AL,0x1
JZ 0x001204f3
MOV RDI,R15
MOV RSI,R14
CALL 0x00108840
LAB_001204f3:
MOV RDI,R14
CALL 0x001083d0
JMP 0x001204ca
LAB_001204fd:
MOV AL,byte ptr [R14 + 0xc8]
TEST AL,0x1
JNZ 0x00120675
MOV R12,qword ptr [RBX + 0x210]
MOV ECX,dword ptr [R12 + 0xdc]
MOV AL,byte ptr [RBX + 0x20c]
CMP dword ptr [RBX + 0x218],ECX
JGE 0x001205bb
TEST AL,0x1
JNZ 0x001205bb
MOV EAX,dword ptr [R12 + 0xe4]
SHL RAX,0x11
XOR ECX,ECX
LAB_00120543:
MOV RDX,qword ptr [RBX + 0x210]
MOV SIL,byte ptr [RDX + 0xc8]
TEST SIL,0x1
JNZ 0x001205b5
MOV SIL,byte ptr [RDX + 0xc9]
TEST SIL,0x1
JNZ 0x001205b5
MOV EDX,dword ptr [RDX + 0x68]
CMP EDX,dword ptr [RBX + 0x208]
JNZ 0x00120578
MOV SIL,byte ptr [RBX + 0x20c]
JMP 0x0012059c
LAB_00120578:
MOV RSI,qword ptr [RBX + 0x210]
MOV ESI,dword ptr [RSI + 0xdc]
CMP dword ptr [RBX + 0x218],ESI
SETL SIL
SETL byte ptr [RBX + 0x20c]
MOV dword ptr [RBX + 0x208],EDX
LAB_0012059c:
TEST SIL,0x1
JNZ 0x001205b5
CMP RCX,RAX
JNC 0x001205b5
PAUSE
INC RCX
CMP byte ptr [RBX + 0x20c],0x1
JNZ 0x00120543
LAB_001205b5:
MOV AL,byte ptr [RBX + 0x20c]
LAB_001205bb:
TEST AL,0x1
JZ 0x001205c4
MFENCE
JMP 0x001205dd
LAB_001205c4:
MOV RDI,R12
CALL 0x001087e0
CMP byte ptr [RBX + 0x20c],0x0
JZ 0x001205fe
LAB_001205d5:
MOV RDI,R12
CALL 0x001083d0
LAB_001205dd:
CMP byte ptr [RBX + 0x20c],0x1
JNZ 0x001204ca
MOV byte ptr [RBX + 0x20c],0x0
MOV RDI,RBX
CALL 0x0010b3d3
JMP 0x001204ca
LAB_001205fe:
LEA R13,[R12 + 0x28]
LAB_00120603:
MOV RAX,qword ptr [RBX + 0x210]
MOV CL,byte ptr [RAX + 0xc8]
TEST CL,0x1
JNZ 0x001205d5
MOV CL,byte ptr [RAX + 0xc9]
TEST CL,0x1
JNZ 0x001205d5
MOV EAX,dword ptr [RAX + 0x68]
CMP EAX,dword ptr [RBX + 0x208]
JNZ 0x00120636
TEST byte ptr [RBX + 0x20c],0x1
JZ 0x0012065c
JMP 0x001205d5
LAB_00120636:
MOV RCX,qword ptr [RBX + 0x210]
MOV ECX,dword ptr [RCX + 0xdc]
CMP dword ptr [RBX + 0x218],ECX
SETL byte ptr [RBX + 0x20c]
MOV dword ptr [RBX + 0x208],EAX
JL 0x001205d5
LAB_0012065c:
MOV RDI,R13
MOV RSI,R12
CALL 0x00108840
CMP byte ptr [RBX + 0x20c],0x1
JNZ 0x00120603
JMP 0x001205d5
LAB_00120675:
XOR EAX,EAX
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
LAB_00120681:
MOV RAX,-0x1
LAB_00120688:
CMP RAX,0x1fe
JZ 0x001204c6
LEA RCX,[RAX + 0x1]
CMP byte ptr [RBX + RAX*0x1 + 0xa],0x1
MOV RAX,RCX
JNZ 0x00120688
CMP RCX,0x1fe
JBE 0x001204bd
JMP 0x001204c6
|
int8 ggml_graph_compute_secondary_thread(long param_1)
{
ulong uVar1;
char *pcVar2;
uint uVar3;
int iVar4;
int iVar5;
pthread_mutex_t *__mutex;
pthread_mutex_t *__mutex_00;
long lVar6;
ulong uVar7;
byte bVar8;
__mutex = *(pthread_mutex_t **)(param_1 + 0x210);
ggml_thread_apply_priority(*(int4 *)((long)__mutex + 0xe0));
if (*(char *)(param_1 + 8) == '\0') {
uVar7 = 0xffffffffffffffff;
do {
if (uVar7 == 0x1fe) goto LAB_001204c6;
uVar1 = uVar7 + 1;
pcVar2 = (char *)(param_1 + 10 + uVar7);
uVar7 = uVar1;
} while (*pcVar2 != '\x01');
if (0x1fe < uVar1) goto LAB_001204c6;
}
ggml_thread_apply_affinity(param_1 + 8);
LAB_001204c6:
do {
while ((*(byte *)((long)__mutex + 0xc9) & 1) != 0) {
pthread_mutex_lock(__mutex);
if ((*(byte *)((long)__mutex + 0xc9) & 1) != 0) {
pthread_cond_wait((pthread_cond_t *)(__mutex + 1),__mutex);
}
pthread_mutex_unlock(__mutex);
}
if ((__mutex[5].__size[0] & 1U) != 0) {
return 0;
}
__mutex_00 = *(pthread_mutex_t **)(param_1 + 0x210);
bVar8 = *(byte *)(param_1 + 0x20c);
if ((*(int *)(param_1 + 0x218) < *(int *)((long)__mutex_00 + 0xdc)) && ((bVar8 & 1) == 0)) {
uVar3 = *(uint *)((long)__mutex_00 + 0xe4);
uVar7 = 0;
while ((lVar6 = *(long *)(param_1 + 0x210), (*(byte *)(lVar6 + 200) & 1) == 0 &&
((*(byte *)(lVar6 + 0xc9) & 1) == 0))) {
iVar4 = *(int *)(lVar6 + 0x68);
if (iVar4 == *(int *)(param_1 + 0x208)) {
bVar8 = *(byte *)(param_1 + 0x20c);
}
else {
iVar5 = *(int *)(*(long *)(param_1 + 0x210) + 0xdc);
bVar8 = *(int *)(param_1 + 0x218) < iVar5;
*(bool *)(param_1 + 0x20c) = *(int *)(param_1 + 0x218) < iVar5;
*(int *)(param_1 + 0x208) = iVar4;
}
if ((((bVar8 & 1) != 0) || ((ulong)uVar3 << 0x11 <= uVar7)) ||
(uVar7 = uVar7 + 1, *(char *)(param_1 + 0x20c) == '\x01')) break;
}
bVar8 = *(byte *)(param_1 + 0x20c);
}
if ((bVar8 & 1) == 0) {
pthread_mutex_lock(__mutex_00);
if (*(char *)(param_1 + 0x20c) == '\0') {
do {
lVar6 = *(long *)(param_1 + 0x210);
if (((*(byte *)(lVar6 + 200) & 1) != 0) || ((*(byte *)(lVar6 + 0xc9) & 1) != 0)) break;
iVar4 = *(int *)(lVar6 + 0x68);
if (iVar4 == *(int *)(param_1 + 0x208)) {
if ((*(byte *)(param_1 + 0x20c) & 1) != 0) break;
}
else {
iVar5 = *(int *)(*(long *)(param_1 + 0x210) + 0xdc);
*(bool *)(param_1 + 0x20c) = *(int *)(param_1 + 0x218) < iVar5;
*(int *)(param_1 + 0x208) = iVar4;
if (*(int *)(param_1 + 0x218) < iVar5) break;
}
pthread_cond_wait((pthread_cond_t *)(__mutex_00 + 1),__mutex_00);
} while (*(char *)(param_1 + 0x20c) != '\x01');
}
pthread_mutex_unlock(__mutex_00);
}
if (*(char *)(param_1 + 0x20c) == '\x01') {
*(int1 *)(param_1 + 0x20c) = 0;
ggml_graph_compute_thread(param_1);
}
} while( true );
}
| |
22,181 | common_model_params_to_llama(common_params&) | monkey531[P]llama/common/common.cpp | struct llama_model_params common_model_params_to_llama(common_params & params) {
auto mparams = llama_model_default_params();
if (!params.devices.empty()) {
mparams.devices = params.devices.data();
}
if (params.n_gpu_layers != -1) {
mparams.n_gpu_layers = params.n_gpu_layers;
}
mparams.main_gpu = params.main_gpu;
mparams.split_mode = params.split_mode;
mparams.tensor_split = params.tensor_split;
mparams.use_mmap = params.use_mmap;
mparams.use_mlock = params.use_mlock;
mparams.check_tensors = params.check_tensors;
if (params.kv_overrides.empty()) {
mparams.kv_overrides = NULL;
} else {
GGML_ASSERT(params.kv_overrides.back().key[0] == 0 && "KV overrides not terminated with empty key");
mparams.kv_overrides = params.kv_overrides.data();
}
return mparams;
} | O0 | cpp | common_model_params_to_llama(common_params&):
subq $0x18, %rsp
movq %rdi, (%rsp)
movq %rdi, %rax
movq %rax, 0x8(%rsp)
movq %rsi, 0x10(%rsp)
callq 0x5af90
movq 0x10(%rsp), %rdi
addq $0x50, %rdi
callq 0xf7c80
testb $0x1, %al
jne 0xef544
movq 0x10(%rsp), %rdi
addq $0x50, %rdi
callq 0xf7cd0
movq %rax, %rcx
movq (%rsp), %rax
movq %rcx, (%rax)
movq 0x10(%rsp), %rax
cmpl $-0x1, 0x68(%rax)
je 0xef55e
movq (%rsp), %rax
movq 0x10(%rsp), %rcx
movl 0x68(%rcx), %ecx
movl %ecx, 0x8(%rax)
movq (%rsp), %rax
movq 0x10(%rsp), %rcx
movl 0x6c(%rcx), %ecx
movl %ecx, 0x10(%rax)
movq 0x10(%rsp), %rcx
movl 0x270(%rcx), %ecx
movl %ecx, 0xc(%rax)
movq 0x10(%rsp), %rcx
addq $0x70, %rcx
movq %rcx, 0x18(%rax)
movq 0x10(%rsp), %rcx
movb 0xfe9(%rcx), %cl
andb $0x1, %cl
movb %cl, 0x39(%rax)
movq 0x10(%rsp), %rcx
movb 0xfea(%rcx), %cl
andb $0x1, %cl
movb %cl, 0x3a(%rax)
movq 0x10(%rsp), %rcx
movb 0xff0(%rcx), %cl
andb $0x1, %cl
movb %cl, 0x3b(%rax)
movq 0x10(%rsp), %rdi
addq $0xf48, %rdi # imm = 0xF48
callq 0x90630
testb $0x1, %al
jne 0xef5d2
jmp 0xef5e0
movq (%rsp), %rax
movq $0x0, 0x30(%rax)
jmp 0xef637
movq 0x10(%rsp), %rdi
addq $0xf48, %rdi # imm = 0xF48
callq 0x906f0
movsbl 0x4(%rax), %eax
cmpl $0x0, %eax
je 0xef61b
leaq 0x120114(%rip), %rdi # 0x20f715
movl $0x44b, %esi # imm = 0x44B
leaq 0x11ceac(%rip), %rdx # 0x20c4b9
leaq 0x120606(%rip), %rcx # 0x20fc1a
movb $0x0, %al
callq 0x5aec0
movq 0x10(%rsp), %rdi
addq $0xf48, %rdi # imm = 0xF48
callq 0xf7cf0
movq %rax, %rcx
movq (%rsp), %rax
movq %rcx, 0x30(%rax)
movq 0x8(%rsp), %rax
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
| _Z28common_model_params_to_llamaR13common_params:
sub rsp, 18h
mov [rsp+18h+var_18], rdi
mov rax, rdi
mov [rsp+18h+var_10], rax
mov [rsp+18h+var_8], rsi
call _llama_model_default_params
mov rdi, [rsp+18h+var_8]
add rdi, 50h ; 'P'
call _ZNKSt6vectorIP19ggml_backend_deviceSaIS1_EE5emptyEv; std::vector<ggml_backend_device *>::empty(void)
test al, 1
jnz short loc_EF544
mov rdi, [rsp+18h+var_8]
add rdi, 50h ; 'P'
call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE4dataEv; std::vector<ggml_backend_device *>::data(void)
mov rcx, rax
mov rax, [rsp+18h+var_18]
mov [rax], rcx
loc_EF544:
mov rax, [rsp+18h+var_8]
cmp dword ptr [rax+68h], 0FFFFFFFFh
jz short loc_EF55E
mov rax, [rsp+18h+var_18]
mov rcx, [rsp+18h+var_8]
mov ecx, [rcx+68h]
mov [rax+8], ecx
loc_EF55E:
mov rax, [rsp+18h+var_18]
mov rcx, [rsp+18h+var_8]
mov ecx, [rcx+6Ch]
mov [rax+10h], ecx
mov rcx, [rsp+18h+var_8]
mov ecx, [rcx+270h]
mov [rax+0Ch], ecx
mov rcx, [rsp+18h+var_8]
add rcx, 70h ; 'p'
mov [rax+18h], rcx
mov rcx, [rsp+18h+var_8]
mov cl, [rcx+0FE9h]
and cl, 1
mov [rax+39h], cl
mov rcx, [rsp+18h+var_8]
mov cl, [rcx+0FEAh]
and cl, 1
mov [rax+3Ah], cl
mov rcx, [rsp+18h+var_8]
mov cl, [rcx+0FF0h]
and cl, 1
mov [rax+3Bh], cl
mov rdi, [rsp+18h+var_8]
add rdi, 0F48h
call _ZNKSt6vectorI23llama_model_kv_overrideSaIS0_EE5emptyEv; std::vector<llama_model_kv_override>::empty(void)
test al, 1
jnz short loc_EF5D2
jmp short loc_EF5E0
loc_EF5D2:
mov rax, [rsp+18h+var_18]
mov qword ptr [rax+30h], 0
jmp short loc_EF637
loc_EF5E0:
mov rdi, [rsp+18h+var_8]
add rdi, 0F48h
call _ZNSt6vectorI23llama_model_kv_overrideSaIS0_EE4backEv; std::vector<llama_model_kv_override>::back(void)
movsx eax, byte ptr [rax+4]
cmp eax, 0
jz short loc_EF61B
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
mov esi, 44Bh
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aParamsKvOverri; "params.kv_overrides.back().key[0] == 0 "...
mov al, 0
call _ggml_abort
loc_EF61B:
mov rdi, [rsp+18h+var_8]
add rdi, 0F48h
call _ZNSt6vectorI23llama_model_kv_overrideSaIS0_EE4dataEv; std::vector<llama_model_kv_override>::data(void)
mov rcx, rax
mov rax, [rsp+18h+var_18]
mov [rax+30h], rcx
loc_EF637:
mov rax, [rsp+18h+var_10]
add rsp, 18h
retn
| common_params * common_model_params_to_llama(common_params *a1, long long a2)
{
llama_model_default_params();
if ( (std::vector<ggml_backend_device *>::empty(a2 + 80) & 1) == 0 )
*(_QWORD *)a1 = std::vector<ggml_backend_device *>::data(a2 + 80);
if ( *(_DWORD *)(a2 + 104) != -1 )
*((_DWORD *)a1 + 2) = *(_DWORD *)(a2 + 104);
*((_DWORD *)a1 + 4) = *(_DWORD *)(a2 + 108);
*((_DWORD *)a1 + 3) = *(_DWORD *)(a2 + 624);
*((_QWORD *)a1 + 3) = a2 + 112;
*((_BYTE *)a1 + 57) = *(_BYTE *)(a2 + 4073) & 1;
*((_BYTE *)a1 + 58) = *(_BYTE *)(a2 + 4074) & 1;
*((_BYTE *)a1 + 59) = *(_BYTE *)(a2 + 4080) & 1;
if ( (std::vector<llama_model_kv_override>::empty(a2 + 3912) & 1) != 0 )
{
*((_QWORD *)a1 + 6) = 0LL;
}
else
{
if ( *(_BYTE *)(std::vector<llama_model_kv_override>::back(a2 + 3912) + 4) )
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp",
1099LL,
"GGML_ASSERT(%s) failed",
"params.kv_overrides.back().key[0] == 0 && \"KV overrides not terminated with empty key\"");
*((_QWORD *)a1 + 6) = std::vector<llama_model_kv_override>::data(a2 + 3912);
}
return a1;
}
| common_model_params_to_llama:
SUB RSP,0x18
MOV qword ptr [RSP],RDI
MOV RAX,RDI
MOV qword ptr [RSP + 0x8],RAX
MOV qword ptr [RSP + 0x10],RSI
CALL 0x0015af90
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0x50
CALL 0x001f7c80
TEST AL,0x1
JNZ 0x001ef544
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0x50
CALL 0x001f7cd0
MOV RCX,RAX
MOV RAX,qword ptr [RSP]
MOV qword ptr [RAX],RCX
LAB_001ef544:
MOV RAX,qword ptr [RSP + 0x10]
CMP dword ptr [RAX + 0x68],-0x1
JZ 0x001ef55e
MOV RAX,qword ptr [RSP]
MOV RCX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RCX + 0x68]
MOV dword ptr [RAX + 0x8],ECX
LAB_001ef55e:
MOV RAX,qword ptr [RSP]
MOV RCX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RCX + 0x6c]
MOV dword ptr [RAX + 0x10],ECX
MOV RCX,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RCX + 0x270]
MOV dword ptr [RAX + 0xc],ECX
MOV RCX,qword ptr [RSP + 0x10]
ADD RCX,0x70
MOV qword ptr [RAX + 0x18],RCX
MOV RCX,qword ptr [RSP + 0x10]
MOV CL,byte ptr [RCX + 0xfe9]
AND CL,0x1
MOV byte ptr [RAX + 0x39],CL
MOV RCX,qword ptr [RSP + 0x10]
MOV CL,byte ptr [RCX + 0xfea]
AND CL,0x1
MOV byte ptr [RAX + 0x3a],CL
MOV RCX,qword ptr [RSP + 0x10]
MOV CL,byte ptr [RCX + 0xff0]
AND CL,0x1
MOV byte ptr [RAX + 0x3b],CL
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0xf48
CALL 0x00190630
TEST AL,0x1
JNZ 0x001ef5d2
JMP 0x001ef5e0
LAB_001ef5d2:
MOV RAX,qword ptr [RSP]
MOV qword ptr [RAX + 0x30],0x0
JMP 0x001ef637
LAB_001ef5e0:
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0xf48
CALL 0x001906f0
MOVSX EAX,byte ptr [RAX + 0x4]
CMP EAX,0x0
JZ 0x001ef61b
LEA RDI,[0x30f715]
MOV ESI,0x44b
LEA RDX,[0x30c4b9]
LEA RCX,[0x30fc1a]
MOV AL,0x0
CALL 0x0015aec0
LAB_001ef61b:
MOV RDI,qword ptr [RSP + 0x10]
ADD RDI,0xf48
CALL 0x001f7cf0
MOV RCX,RAX
MOV RAX,qword ptr [RSP]
MOV qword ptr [RAX + 0x30],RCX
LAB_001ef637:
MOV RAX,qword ptr [RSP + 0x8]
ADD RSP,0x18
RET
|
/* common_model_params_to_llama(common_params&) */
common_params * common_model_params_to_llama(common_params *param_1)
{
ulong uVar1;
int8 uVar2;
long lVar3;
long in_RSI;
llama_model_default_params();
uVar1 = std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::empty
((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)
(in_RSI + 0x50));
if ((uVar1 & 1) == 0) {
uVar2 = std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::data
((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)
(in_RSI + 0x50));
*(int8 *)param_1 = uVar2;
}
if (*(int *)(in_RSI + 0x68) != -1) {
*(int4 *)(param_1 + 8) = *(int4 *)(in_RSI + 0x68);
}
*(int4 *)(param_1 + 0x10) = *(int4 *)(in_RSI + 0x6c);
*(int4 *)(param_1 + 0xc) = *(int4 *)(in_RSI + 0x270);
*(long *)(param_1 + 0x18) = in_RSI + 0x70;
param_1[0x39] = (common_params)(*(byte *)(in_RSI + 0xfe9) & 1);
param_1[0x3a] = (common_params)(*(byte *)(in_RSI + 0xfea) & 1);
param_1[0x3b] = (common_params)(*(byte *)(in_RSI + 0xff0) & 1);
uVar1 = std::vector<llama_model_kv_override,std::allocator<llama_model_kv_override>>::empty
((vector<llama_model_kv_override,std::allocator<llama_model_kv_override>> *)
(in_RSI + 0xf48));
if ((uVar1 & 1) == 0) {
lVar3 = std::vector<llama_model_kv_override,std::allocator<llama_model_kv_override>>::back
((vector<llama_model_kv_override,std::allocator<llama_model_kv_override>> *)
(in_RSI + 0xf48));
if (*(char *)(lVar3 + 4) != '\0') {
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp",1099,
"GGML_ASSERT(%s) failed",
"params.kv_overrides.back().key[0] == 0 && \"KV overrides not terminated with empty key\""
);
}
uVar2 = std::vector<llama_model_kv_override,std::allocator<llama_model_kv_override>>::data
((vector<llama_model_kv_override,std::allocator<llama_model_kv_override>> *)
(in_RSI + 0xf48));
*(int8 *)(param_1 + 0x30) = uVar2;
}
else {
*(int8 *)(param_1 + 0x30) = 0;
}
return param_1;
}
| |
22,182 | common_model_params_to_llama(common_params&) | monkey531[P]llama/common/common.cpp | struct llama_model_params common_model_params_to_llama(common_params & params) {
auto mparams = llama_model_default_params();
if (!params.devices.empty()) {
mparams.devices = params.devices.data();
}
if (params.n_gpu_layers != -1) {
mparams.n_gpu_layers = params.n_gpu_layers;
}
mparams.main_gpu = params.main_gpu;
mparams.split_mode = params.split_mode;
mparams.tensor_split = params.tensor_split;
mparams.use_mmap = params.use_mmap;
mparams.use_mlock = params.use_mlock;
mparams.check_tensors = params.check_tensors;
if (params.kv_overrides.empty()) {
mparams.kv_overrides = NULL;
} else {
GGML_ASSERT(params.kv_overrides.back().key[0] == 0 && "KV overrides not terminated with empty key");
mparams.kv_overrides = params.kv_overrides.data();
}
return mparams;
} | O2 | cpp | common_model_params_to_llama(common_params&):
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
callq 0x23e60
movq 0x50(%r14), %rax
cmpq 0x58(%r14), %rax
je 0x5556f
movq %rax, (%rbx)
movl 0x68(%r14), %eax
cmpl $-0x1, %eax
je 0x5557b
movl %eax, 0x8(%rbx)
movl 0x6c(%r14), %eax
movl %eax, 0x10(%rbx)
movl 0x270(%r14), %eax
movl %eax, 0xc(%rbx)
leaq 0x70(%r14), %rax
movq %rax, 0x18(%rbx)
movb 0xfe9(%r14), %al
movb %al, 0x39(%rbx)
movb 0xfea(%r14), %al
movb %al, 0x3a(%rbx)
movb 0xff0(%r14), %al
movb %al, 0x3b(%rbx)
movq 0xf48(%r14), %rax
movq 0xf50(%r14), %rcx
cmpq %rcx, %rax
je 0x555ef
cmpb $0x0, -0x104(%rcx)
je 0x555f1
leaq 0x5c75c(%rip), %rdi # 0xb1d31
leaq 0x59941(%rip), %rdx # 0xaef1d
leaq 0x5cc53(%rip), %rcx # 0xb2236
movl $0x44b, %esi # imm = 0x44B
xorl %eax, %eax
callq 0x23e90
xorl %eax, %eax
movq %rax, 0x30(%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| _Z28common_model_params_to_llamaR13common_params:
push r14
push rbx
push rax
mov r14, rsi
mov rbx, rdi
call _llama_model_default_params
mov rax, [r14+50h]
cmp rax, [r14+58h]
jz short loc_5556F
mov [rbx], rax
loc_5556F:
mov eax, [r14+68h]
cmp eax, 0FFFFFFFFh
jz short loc_5557B
mov [rbx+8], eax
loc_5557B:
mov eax, [r14+6Ch]
mov [rbx+10h], eax
mov eax, [r14+270h]
mov [rbx+0Ch], eax
lea rax, [r14+70h]
mov [rbx+18h], rax
mov al, [r14+0FE9h]
mov [rbx+39h], al
mov al, [r14+0FEAh]
mov [rbx+3Ah], al
mov al, [r14+0FF0h]
mov [rbx+3Bh], al
mov rax, [r14+0F48h]
mov rcx, [r14+0F50h]
cmp rax, rcx
jz short loc_555EF
cmp byte ptr [rcx-104h], 0
jz short loc_555F1
lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aParamsKvOverri; "params.kv_overrides.back().key[0] == 0 "...
mov esi, 44Bh
xor eax, eax
call _ggml_abort
loc_555EF:
xor eax, eax
loc_555F1:
mov [rbx+30h], rax
mov rax, rbx
add rsp, 8
pop rbx
pop r14
retn
| common_params * common_model_params_to_llama(common_params *a1, long long a2)
{
long long v2; // rax
int v3; // eax
long long v4; // rax
long long v5; // rcx
llama_model_default_params(a1);
v2 = *(_QWORD *)(a2 + 80);
if ( v2 != *(_QWORD *)(a2 + 88) )
*(_QWORD *)a1 = v2;
v3 = *(_DWORD *)(a2 + 104);
if ( v3 != -1 )
*((_DWORD *)a1 + 2) = v3;
*((_DWORD *)a1 + 4) = *(_DWORD *)(a2 + 108);
*((_DWORD *)a1 + 3) = *(_DWORD *)(a2 + 624);
*((_QWORD *)a1 + 3) = a2 + 112;
*((_BYTE *)a1 + 57) = *(_BYTE *)(a2 + 4073);
*((_BYTE *)a1 + 58) = *(_BYTE *)(a2 + 4074);
*((_BYTE *)a1 + 59) = *(_BYTE *)(a2 + 4080);
v4 = *(_QWORD *)(a2 + 3912);
v5 = *(_QWORD *)(a2 + 3920);
if ( v4 == v5 )
goto LABEL_8;
if ( *(_BYTE *)(v5 - 260) )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp",
1099LL,
"GGML_ASSERT(%s) failed",
"params.kv_overrides.back().key[0] == 0 && \"KV overrides not terminated with empty key\"");
LABEL_8:
v4 = 0LL;
}
*((_QWORD *)a1 + 6) = v4;
return a1;
}
| common_model_params_to_llama:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RSI
MOV RBX,RDI
CALL 0x00123e60
MOV RAX,qword ptr [R14 + 0x50]
CMP RAX,qword ptr [R14 + 0x58]
JZ 0x0015556f
MOV qword ptr [RBX],RAX
LAB_0015556f:
MOV EAX,dword ptr [R14 + 0x68]
CMP EAX,-0x1
JZ 0x0015557b
MOV dword ptr [RBX + 0x8],EAX
LAB_0015557b:
MOV EAX,dword ptr [R14 + 0x6c]
MOV dword ptr [RBX + 0x10],EAX
MOV EAX,dword ptr [R14 + 0x270]
MOV dword ptr [RBX + 0xc],EAX
LEA RAX,[R14 + 0x70]
MOV qword ptr [RBX + 0x18],RAX
MOV AL,byte ptr [R14 + 0xfe9]
MOV byte ptr [RBX + 0x39],AL
MOV AL,byte ptr [R14 + 0xfea]
MOV byte ptr [RBX + 0x3a],AL
MOV AL,byte ptr [R14 + 0xff0]
MOV byte ptr [RBX + 0x3b],AL
MOV RAX,qword ptr [R14 + 0xf48]
MOV RCX,qword ptr [R14 + 0xf50]
CMP RAX,RCX
JZ 0x001555ef
CMP byte ptr [RCX + -0x104],0x0
JZ 0x001555f1
LEA RDI,[0x1b1d31]
LEA RDX,[0x1aef1d]
LEA RCX,[0x1b2236]
MOV ESI,0x44b
XOR EAX,EAX
CALL 0x00123e90
LAB_001555ef:
XOR EAX,EAX
LAB_001555f1:
MOV qword ptr [RBX + 0x30],RAX
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* common_model_params_to_llama(common_params&) */
common_params * common_model_params_to_llama(common_params *param_1)
{
long lVar1;
long in_RSI;
llama_model_default_params();
if (*(long *)(in_RSI + 0x50) != *(long *)(in_RSI + 0x58)) {
*(long *)param_1 = *(long *)(in_RSI + 0x50);
}
if (*(int *)(in_RSI + 0x68) != -1) {
*(int *)(param_1 + 8) = *(int *)(in_RSI + 0x68);
}
*(int4 *)(param_1 + 0x10) = *(int4 *)(in_RSI + 0x6c);
*(int4 *)(param_1 + 0xc) = *(int4 *)(in_RSI + 0x270);
*(long *)(param_1 + 0x18) = in_RSI + 0x70;
param_1[0x39] = *(common_params *)(in_RSI + 0xfe9);
param_1[0x3a] = *(common_params *)(in_RSI + 0xfea);
param_1[0x3b] = *(common_params *)(in_RSI + 0xff0);
lVar1 = *(long *)(in_RSI + 0xf48);
if (lVar1 == *(long *)(in_RSI + 0xf50)) {
lVar1 = 0;
}
else if (*(char *)(*(long *)(in_RSI + 0xf50) + -0x104) != '\0') {
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp",1099,
"GGML_ASSERT(%s) failed",
"params.kv_overrides.back().key[0] == 0 && \"KV overrides not terminated with empty key\""
);
}
*(long *)(param_1 + 0x30) = lVar1;
return param_1;
}
| |
22,183 | line_dbl | corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/pairing.c | static void line_dbl(vec384fp6 line, POINTonE2 *T, const POINTonE2 *Q)
{
vec384x ZZ, A, B, C, D, E, F;
/*
* https://www.hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html#doubling-dbl-2009-alnr
*/
sqr_fp2(A, Q->X); /* A = X1^2 */
sqr_fp2(B, Q->Y); /* B = Y1^2 */
sqr_fp2(ZZ, Q->Z); /* ZZ = Z1^2 */
sqr_fp2(C, B); /* C = B^2 */
add_fp2(D, Q->X, B); /* X1+B */
sqr_fp2(D, D); /* (X1+B)^2 */
sub_fp2(D, D, A); /* (X1+B)^2-A */
sub_fp2(D, D, C); /* (X1+B)^2-A-C */
add_fp2(D, D, D); /* D = 2*((X1+B)^2-A-C) */
mul_by_3_fp2(E, A); /* E = 3*A */
sqr_fp2(F, E); /* F = E^2 */
add_fp2(line[0], E, Q->X); /* 3*A+X1 for line evaluation */
sub_fp2(T->X, F, D);
sub_fp2(T->X, T->X, D); /* X3 = F-2*D */
add_fp2(T->Z, Q->Y, Q->Z);
sqr_fp2(T->Z, T->Z);
sub_fp2(T->Z, T->Z, B);
sub_fp2(T->Z, T->Z, ZZ); /* Z3 = (Y1+Z1)^2-B-ZZ */
mul_by_8_fp2(C, C); /* 8*C */
sub_fp2(T->Y, D, T->X); /* D-X3 */
mul_fp2(T->Y, T->Y, E); /* E*(D-X3) */
sub_fp2(T->Y, T->Y, C); /* Y3 = E*(D-X3)-8*C */
/*
* line evaluation
*/
sqr_fp2(line[0], line[0]);
sub_fp2(line[0], line[0], A);
sub_fp2(line[0], line[0], F); /* (3*A+X1)^2 - X1^2 - 9*A^2 */
lshift_fp2(B, B, 2);
sub_fp2(line[0], line[0], B); /* 6*X1^3 - 4*Y1^2 */
mul_fp2(line[1], E, ZZ); /* 3*X1^2 * Z1^2 */
mul_fp2(line[2], T->Z, ZZ); /* Z3 * Z1^2 */
} | O3 | c | line_dbl:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x2b8, %rsp # imm = 0x2B8
movq %rdx, %r14
movq %rsi, -0x40(%rbp)
movq %rdi, %r15
leaq 0x24393(%rip), %rbx # 0x8cca0
leaq -0x160(%rbp), %rdi
movabsq $-0x760c000300030003, %r12 # imm = 0x89F3FFFCFFFCFFFD
movq %rdx, %rsi
movq %rbx, %rdx
movq %r12, %rcx
callq 0x73ce0
leaq 0x60(%r14), %rsi
movq %rsi, -0x38(%rbp)
leaq -0x100(%rbp), %r13
movq %r13, %rdi
movq %rbx, %rdx
movq %r12, %rcx
callq 0x73ce0
movl $0xc0, %eax
leaq (%r14,%rax), %rsi
movq %rsi, -0x30(%rbp)
leaq -0x280(%rbp), %rdi
movq %rbx, %rdx
movq %r12, %rcx
callq 0x73ce0
leaq -0xa0(%rbp), %rdi
movq %r13, %rsi
movq %rbx, %rdx
movq %r12, %rcx
callq 0x73ce0
leaq -0x2e0(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
movq %r13, %rdx
movq %rbx, %rcx
callq 0x6f720
movq %r12, %rdi
movq %r12, %rsi
movq %rbx, %rdx
movabsq $-0x760c000300030003, %rcx # imm = 0x89F3FFFCFFFCFFFD
callq 0x73ce0
movq %r12, %rdi
movq %r12, %rsi
leaq -0x160(%rbp), %rdx
movq %rbx, %rcx
callq 0x6fe80
movq %r12, %rdi
movq %r12, %rsi
leaq -0xa0(%rbp), %rdx
movq %rbx, %rcx
callq 0x6fe80
movq %r12, %rdi
movq %r12, %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x6f720
leaq -0x220(%rbp), %r13
movq %r13, %rdi
leaq -0x160(%rbp), %rsi
movq %rbx, %rdx
callq 0x6fb60
leaq -0x1c0(%rbp), %rdi
movq %r13, %rsi
movq %rbx, %rdx
movabsq $-0x760c000300030003, %rcx # imm = 0x89F3FFFCFFFCFFFD
callq 0x73ce0
movq %r15, %rdi
movq %r13, %rsi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x6f720
movq -0x40(%rbp), %r13
movq %r13, %rdi
leaq -0x1c0(%rbp), %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x6fe80
movq %r13, %rdi
movq %r13, %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x6fe80
movl $0xc0, %eax
leaq (%rax,%r13), %r14
movq %r14, %rdi
movq -0x38(%rbp), %rsi
movq -0x30(%rbp), %rdx
movq %rbx, %rcx
callq 0x6f720
movq %r14, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movabsq $-0x760c000300030003, %rcx # imm = 0x89F3FFFCFFFCFFFD
callq 0x73ce0
movq %r14, %rdi
movq %r14, %rsi
leaq -0x100(%rbp), %rdx
movq %rbx, %rcx
callq 0x6fe80
movq %r14, %rdi
movq %r14, %rsi
leaq -0x280(%rbp), %rdx
movq %rbx, %rcx
callq 0x6fe80
leaq -0xa0(%rbp), %rdi
movq %rdi, %rsi
movq %rbx, %rdx
callq 0x6fc00
movq %r13, %rdx
addq $0x60, %r13
movq %r13, %rdi
movq %r12, %rsi
movq %rbx, %rcx
callq 0x6fe80
movq %r13, %rdi
movq %r13, %rsi
leaq -0x220(%rbp), %rdx
movq %rbx, %rcx
movabsq $-0x760c000300030003, %r12 # imm = 0x89F3FFFCFFFCFFFD
movq %r12, %r8
callq 0x73ba0
movq %r13, %rdi
movq %r13, %rsi
leaq -0xa0(%rbp), %rdx
movq %rbx, %rcx
callq 0x6fe80
movq %r15, %rdi
movq %r15, %rsi
movq %rbx, %rdx
movq %r12, %r13
movq %r12, %rcx
callq 0x73ce0
movq %r15, %rdi
movq %r15, %rsi
leaq -0x160(%rbp), %rdx
movq %rbx, %rcx
callq 0x6fe80
movq %r15, %rdi
movq %r15, %rsi
leaq -0x1c0(%rbp), %rdx
movq %rbx, %rcx
callq 0x6fe80
movl $0x2, %edx
leaq -0x100(%rbp), %rdi
movq %rdi, %rsi
movq %rdi, %r12
movq %rbx, %rcx
callq 0x6f940
leaq -0xd0(%rbp), %rdi
movl $0x2, %edx
movq %rdi, %rsi
movq %rbx, %rcx
callq 0x6f940
movq %r15, %rdi
movq %r15, %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x6fe80
leaq 0x60(%r15), %rdi
leaq -0x220(%rbp), %rsi
leaq -0x280(%rbp), %r12
movq %r12, %rdx
movq %rbx, %rcx
movq %r13, %r8
callq 0x73ba0
movl $0xc0, %edi
addq %r15, %rdi
movq %r14, %rsi
movq %r12, %rdx
movq %rbx, %rcx
movq %r13, %r8
callq 0x73ba0
addq $0x2b8, %rsp # imm = 0x2B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| line_dbl:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 2B8h
mov r14, rdx
mov [rbp+var_40], rsi
mov r15, rdi
lea rbx, BLS12_381_P
lea rdi, [rbp+var_160]
mov r12, 89F3FFFCFFFCFFFDh
mov rsi, rdx
mov rdx, rbx
mov rcx, r12
call sqr_mont_384x
lea rsi, [r14+60h]
mov [rbp+var_38], rsi
lea r13, [rbp+var_100]
mov rdi, r13
mov rdx, rbx
mov rcx, r12
call sqr_mont_384x
mov eax, 0C0h
lea rsi, [r14+rax]
mov [rbp+var_30], rsi
lea rdi, [rbp+var_280]
mov rdx, rbx
mov rcx, r12
call sqr_mont_384x
lea rdi, [rbp+var_A0]
mov rsi, r13
mov rdx, rbx
mov rcx, r12
call sqr_mont_384x
lea r12, [rbp+var_2E0]
mov rdi, r12
mov rsi, r14
mov rdx, r13
mov rcx, rbx
call add_mod_384x
mov rdi, r12
mov rsi, r12
mov rdx, rbx
mov rcx, 89F3FFFCFFFCFFFDh
call sqr_mont_384x
mov rdi, r12
mov rsi, r12
lea rdx, [rbp+var_160]
mov rcx, rbx
call _sub_mod_384x
mov rdi, r12
mov rsi, r12
lea rdx, [rbp+var_A0]
mov rcx, rbx
call _sub_mod_384x
mov rdi, r12
mov rsi, r12
mov rdx, r12
mov rcx, rbx
call add_mod_384x
lea r13, [rbp+var_220]
mov rdi, r13
lea rsi, [rbp+var_160]
mov rdx, rbx
call mul_by_3_mod_384x
lea rdi, [rbp+var_1C0]
mov rsi, r13
mov rdx, rbx
mov rcx, 89F3FFFCFFFCFFFDh
call sqr_mont_384x
mov rdi, r15
mov rsi, r13
mov rdx, r14
mov rcx, rbx
call add_mod_384x
mov r13, [rbp+var_40]
mov rdi, r13
lea rsi, [rbp+var_1C0]
mov rdx, r12
mov rcx, rbx
call _sub_mod_384x
mov rdi, r13
mov rsi, r13
mov rdx, r12
mov rcx, rbx
call _sub_mod_384x
mov eax, 0C0h
lea r14, [rax+r13]
mov rdi, r14
mov rsi, [rbp+var_38]
mov rdx, [rbp+var_30]
mov rcx, rbx
call add_mod_384x
mov rdi, r14
mov rsi, r14
mov rdx, rbx
mov rcx, 89F3FFFCFFFCFFFDh
call sqr_mont_384x
mov rdi, r14
mov rsi, r14
lea rdx, [rbp+var_100]
mov rcx, rbx
call _sub_mod_384x
mov rdi, r14
mov rsi, r14
lea rdx, [rbp+var_280]
mov rcx, rbx
call _sub_mod_384x
lea rdi, [rbp+var_A0]
mov rsi, rdi
mov rdx, rbx
call mul_by_8_mod_384x
mov rdx, r13
add r13, 60h ; '`'
mov rdi, r13
mov rsi, r12
mov rcx, rbx
call _sub_mod_384x
mov rdi, r13
mov rsi, r13
lea rdx, [rbp+var_220]
mov rcx, rbx
mov r12, 89F3FFFCFFFCFFFDh
mov r8, r12
call mul_mont_384x
mov rdi, r13
mov rsi, r13
lea rdx, [rbp+var_A0]
mov rcx, rbx
call _sub_mod_384x
mov rdi, r15
mov rsi, r15
mov rdx, rbx
mov r13, r12
mov rcx, r12
call sqr_mont_384x
mov rdi, r15
mov rsi, r15
lea rdx, [rbp+var_160]
mov rcx, rbx
call _sub_mod_384x
mov rdi, r15
mov rsi, r15
lea rdx, [rbp+var_1C0]
mov rcx, rbx
call _sub_mod_384x
mov edx, 2
lea rdi, [rbp+var_100]
mov rsi, rdi
mov r12, rdi
mov rcx, rbx
call lshift_mod_384
lea rdi, [rbp+var_D0]
mov edx, 2
mov rsi, rdi
mov rcx, rbx
call lshift_mod_384
mov rdi, r15
mov rsi, r15
mov rdx, r12
mov rcx, rbx
call _sub_mod_384x
lea rdi, [r15+60h]
lea rsi, [rbp+var_220]
lea r12, [rbp+var_280]
mov rdx, r12
mov rcx, rbx
mov r8, r13
call mul_mont_384x
mov edi, 0C0h
add rdi, r15
mov rsi, r14
mov rdx, r12
mov rcx, rbx
mov r8, r13
call mul_mont_384x
add rsp, 2B8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long line_dbl(long long a1, long long a2, long long a3)
{
long long v5; // r13
long long v6; // r14
long long v7; // rdx
_BYTE v9[96]; // [rsp+0h] [rbp-2E0h] BYREF
_BYTE v10[96]; // [rsp+60h] [rbp-280h] BYREF
_BYTE v11[96]; // [rsp+C0h] [rbp-220h] BYREF
_BYTE v12[96]; // [rsp+120h] [rbp-1C0h] BYREF
_BYTE v13[96]; // [rsp+180h] [rbp-160h] BYREF
_BYTE v14[48]; // [rsp+1E0h] [rbp-100h] BYREF
_BYTE v15[48]; // [rsp+210h] [rbp-D0h] BYREF
_BYTE v16[96]; // [rsp+240h] [rbp-A0h] BYREF
long long v17; // [rsp+2A0h] [rbp-40h]
long long v18; // [rsp+2A8h] [rbp-38h]
long long v19; // [rsp+2B0h] [rbp-30h]
v17 = a2;
sqr_mont_384x(v13, a3, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
v18 = a3 + 96;
sqr_mont_384x(v14, a3 + 96, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
v19 = a3 + 192;
sqr_mont_384x(v10, a3 + 192, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
sqr_mont_384x(v16, v14, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
add_mod_384x(v9, a3, v14, &BLS12_381_P);
sqr_mont_384x(v9, v9, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
sub_mod_384x(v9, v9, v13, &BLS12_381_P);
sub_mod_384x(v9, v9, v16, &BLS12_381_P);
add_mod_384x(v9, v9, v9, &BLS12_381_P);
mul_by_3_mod_384x(v11, v13, &BLS12_381_P);
sqr_mont_384x(v12, v11, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
add_mod_384x(a1, v11, a3, &BLS12_381_P);
v5 = v17;
sub_mod_384x(v17, v12, v9, &BLS12_381_P);
sub_mod_384x(v5, v5, v9, &BLS12_381_P);
v6 = v5 + 192;
add_mod_384x(v5 + 192, v18, v19, &BLS12_381_P);
sqr_mont_384x(v5 + 192, v5 + 192, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
sub_mod_384x(v5 + 192, v5 + 192, v14, &BLS12_381_P);
sub_mod_384x(v5 + 192, v5 + 192, v10, &BLS12_381_P);
mul_by_8_mod_384x(v16, v16, &BLS12_381_P);
v7 = v5;
v5 += 96LL;
sub_mod_384x(v5, v9, v7, &BLS12_381_P);
mul_mont_384x(v5, v5, v11, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
sub_mod_384x(v5, v5, v16, &BLS12_381_P);
sqr_mont_384x(a1, a1, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
sub_mod_384x(a1, a1, v13, &BLS12_381_P);
sub_mod_384x(a1, a1, v12, &BLS12_381_P);
lshift_mod_384(v14, v14, 2LL, &BLS12_381_P);
lshift_mod_384(v15, v15, 2LL, &BLS12_381_P);
sub_mod_384x(a1, a1, v14, &BLS12_381_P);
mul_mont_384x(a1 + 96, v11, v10, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
return mul_mont_384x(a1 + 192, v6, v10, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL);
}
| line_dbl:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x2b8
MOV R14,RDX
MOV qword ptr [RBP + -0x40],RSI
MOV R15,RDI
LEA RBX,[0x18cca0]
LEA RDI,[RBP + -0x160]
MOV R12,-0x760c000300030003
MOV RSI,RDX
MOV RDX,RBX
MOV RCX,R12
CALL 0x00173ce0
LEA RSI,[R14 + 0x60]
MOV qword ptr [RBP + -0x38],RSI
LEA R13,[RBP + -0x100]
MOV RDI,R13
MOV RDX,RBX
MOV RCX,R12
CALL 0x00173ce0
MOV EAX,0xc0
LEA RSI,[R14 + RAX*0x1]
MOV qword ptr [RBP + -0x30],RSI
LEA RDI,[RBP + -0x280]
MOV RDX,RBX
MOV RCX,R12
CALL 0x00173ce0
LEA RDI,[RBP + -0xa0]
MOV RSI,R13
MOV RDX,RBX
MOV RCX,R12
CALL 0x00173ce0
LEA R12,[RBP + -0x2e0]
MOV RDI,R12
MOV RSI,R14
MOV RDX,R13
MOV RCX,RBX
CALL 0x0016f720
MOV RDI,R12
MOV RSI,R12
MOV RDX,RBX
MOV RCX,-0x760c000300030003
CALL 0x00173ce0
MOV RDI,R12
MOV RSI,R12
LEA RDX,[RBP + -0x160]
MOV RCX,RBX
CALL 0x0016fe80
MOV RDI,R12
MOV RSI,R12
LEA RDX,[RBP + -0xa0]
MOV RCX,RBX
CALL 0x0016fe80
MOV RDI,R12
MOV RSI,R12
MOV RDX,R12
MOV RCX,RBX
CALL 0x0016f720
LEA R13,[RBP + -0x220]
MOV RDI,R13
LEA RSI,[RBP + -0x160]
MOV RDX,RBX
CALL 0x0016fb60
LEA RDI,[RBP + -0x1c0]
MOV RSI,R13
MOV RDX,RBX
MOV RCX,-0x760c000300030003
CALL 0x00173ce0
MOV RDI,R15
MOV RSI,R13
MOV RDX,R14
MOV RCX,RBX
CALL 0x0016f720
MOV R13,qword ptr [RBP + -0x40]
MOV RDI,R13
LEA RSI,[RBP + -0x1c0]
MOV RDX,R12
MOV RCX,RBX
CALL 0x0016fe80
MOV RDI,R13
MOV RSI,R13
MOV RDX,R12
MOV RCX,RBX
CALL 0x0016fe80
MOV EAX,0xc0
LEA R14,[RAX + R13*0x1]
MOV RDI,R14
MOV RSI,qword ptr [RBP + -0x38]
MOV RDX,qword ptr [RBP + -0x30]
MOV RCX,RBX
CALL 0x0016f720
MOV RDI,R14
MOV RSI,R14
MOV RDX,RBX
MOV RCX,-0x760c000300030003
CALL 0x00173ce0
MOV RDI,R14
MOV RSI,R14
LEA RDX,[RBP + -0x100]
MOV RCX,RBX
CALL 0x0016fe80
MOV RDI,R14
MOV RSI,R14
LEA RDX,[RBP + -0x280]
MOV RCX,RBX
CALL 0x0016fe80
LEA RDI,[RBP + -0xa0]
MOV RSI,RDI
MOV RDX,RBX
CALL 0x0016fc00
MOV RDX,R13
ADD R13,0x60
MOV RDI,R13
MOV RSI,R12
MOV RCX,RBX
CALL 0x0016fe80
MOV RDI,R13
MOV RSI,R13
LEA RDX,[RBP + -0x220]
MOV RCX,RBX
MOV R12,-0x760c000300030003
MOV R8,R12
CALL 0x00173ba0
MOV RDI,R13
MOV RSI,R13
LEA RDX,[RBP + -0xa0]
MOV RCX,RBX
CALL 0x0016fe80
MOV RDI,R15
MOV RSI,R15
MOV RDX,RBX
MOV R13,R12
MOV RCX,R12
CALL 0x00173ce0
MOV RDI,R15
MOV RSI,R15
LEA RDX,[RBP + -0x160]
MOV RCX,RBX
CALL 0x0016fe80
MOV RDI,R15
MOV RSI,R15
LEA RDX,[RBP + -0x1c0]
MOV RCX,RBX
CALL 0x0016fe80
MOV EDX,0x2
LEA RDI,[RBP + -0x100]
MOV RSI,RDI
MOV R12,RDI
MOV RCX,RBX
CALL 0x0016f940
LEA RDI,[RBP + -0xd0]
MOV EDX,0x2
MOV RSI,RDI
MOV RCX,RBX
CALL 0x0016f940
MOV RDI,R15
MOV RSI,R15
MOV RDX,R12
MOV RCX,RBX
CALL 0x0016fe80
LEA RDI,[R15 + 0x60]
LEA RSI,[RBP + -0x220]
LEA R12,[RBP + -0x280]
MOV RDX,R12
MOV RCX,RBX
MOV R8,R13
CALL 0x00173ba0
MOV EDI,0xc0
ADD RDI,R15
MOV RSI,R14
MOV RDX,R12
MOV RCX,RBX
MOV R8,R13
CALL 0x00173ba0
ADD RSP,0x2b8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
void line_dbl(long param_1,long param_2,long param_3)
{
long lVar1;
long lVar2;
long lVar3;
int1 local_2e8 [96];
int1 local_288 [96];
int1 local_228 [96];
int1 local_1c8 [96];
int1 local_168 [96];
int1 local_108 [48];
int1 local_d8 [48];
int1 local_a8 [96];
long local_48;
long local_40;
long local_38;
local_48 = param_2;
sqr_mont_384x(local_168,param_3,BLS12_381_P,0x89f3fffcfffcfffd);
local_40 = param_3 + 0x60;
sqr_mont_384x(local_108,local_40,BLS12_381_P,0x89f3fffcfffcfffd);
local_38 = param_3 + 0xc0;
sqr_mont_384x(local_288,local_38,BLS12_381_P,0x89f3fffcfffcfffd);
sqr_mont_384x(local_a8,local_108,BLS12_381_P,0x89f3fffcfffcfffd);
add_mod_384x(local_2e8,param_3,local_108,BLS12_381_P);
sqr_mont_384x(local_2e8,local_2e8,BLS12_381_P,0x89f3fffcfffcfffd);
sub_mod_384x(local_2e8,local_2e8,local_168,BLS12_381_P);
sub_mod_384x(local_2e8,local_2e8,local_a8,BLS12_381_P);
add_mod_384x(local_2e8,local_2e8,local_2e8,BLS12_381_P);
mul_by_3_mod_384x(local_228,local_168,BLS12_381_P);
sqr_mont_384x(local_1c8,local_228,BLS12_381_P,0x89f3fffcfffcfffd);
add_mod_384x(param_1,local_228,param_3,BLS12_381_P);
lVar2 = local_48;
sub_mod_384x(local_48,local_1c8,local_2e8,BLS12_381_P);
sub_mod_384x(lVar2,lVar2,local_2e8,BLS12_381_P);
lVar1 = lVar2 + 0xc0;
add_mod_384x(lVar1,local_40,local_38,BLS12_381_P);
sqr_mont_384x(lVar1,lVar1,BLS12_381_P,0x89f3fffcfffcfffd);
sub_mod_384x(lVar1,lVar1,local_108,BLS12_381_P);
sub_mod_384x(lVar1,lVar1,local_288,BLS12_381_P);
mul_by_8_mod_384x(local_a8,local_a8,BLS12_381_P);
lVar3 = lVar2 + 0x60;
sub_mod_384x(lVar3,local_2e8,lVar2,BLS12_381_P);
mul_mont_384x(lVar3,lVar3,local_228,BLS12_381_P,0x89f3fffcfffcfffd);
sub_mod_384x(lVar3,lVar3,local_a8,BLS12_381_P);
sqr_mont_384x(param_1,param_1,BLS12_381_P,0x89f3fffcfffcfffd);
sub_mod_384x(param_1,param_1,local_168,BLS12_381_P);
sub_mod_384x(param_1,param_1,local_1c8,BLS12_381_P);
lshift_mod_384(local_108,local_108,2,BLS12_381_P);
lshift_mod_384(local_d8,local_d8,2,BLS12_381_P);
sub_mod_384x(param_1,param_1,local_108,BLS12_381_P);
mul_mont_384x(param_1 + 0x60,local_228,local_288,BLS12_381_P,0x89f3fffcfffcfffd);
mul_mont_384x(param_1 + 0xc0,lVar1,local_288,BLS12_381_P,0x89f3fffcfffcfffd);
return;
}
| |
22,184 | diag | eloqsql/libmariadb/unittest/mytap/tap.c | void
diag(char const *fmt, ...)
{
va_list ap;
va_start(ap, fmt);
fprintf(tapout, "# ");
vfprintf(tapout, fmt, ap);
emit_endl();
va_end(ap);
} | O3 | c | diag:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0xc8, %rsp
movq %rdi, %rbx
leaq -0xe0(%rbp), %rdi
movq %rsi, 0x8(%rdi)
movq %rdx, 0x10(%rdi)
movq %rcx, 0x18(%rdi)
movq %r8, 0x20(%rdi)
movq %r9, 0x28(%rdi)
testb %al, %al
je 0x15046
movaps %xmm0, -0xb0(%rbp)
movaps %xmm1, -0xa0(%rbp)
movaps %xmm2, -0x90(%rbp)
movaps %xmm3, -0x80(%rbp)
movaps %xmm4, -0x70(%rbp)
movaps %xmm5, -0x60(%rbp)
movaps %xmm6, -0x50(%rbp)
movaps %xmm7, -0x40(%rbp)
leaq -0x30(%rbp), %r14
movq %rdi, 0x10(%r14)
leaq 0x10(%rbp), %rax
movq %rax, 0x8(%r14)
movabsq $0x3000000008, %rax # imm = 0x3000000008
movq %rax, (%r14)
movq 0x31f46(%rip), %r15 # 0x46fb0
movq (%r15), %rdi
leaq 0x1f74b(%rip), %rdx # 0x347bf
movl $0x1, %esi
xorl %eax, %eax
callq 0x13740
movq (%r15), %rdi
movl $0x1, %esi
movq %rbx, %rdx
movq %r14, %rcx
callq 0x13150
movq (%r15), %rdi
leaq 0x1f541(%rip), %rdx # 0x345de
movl $0x1, %esi
xorl %eax, %eax
callq 0x13740
addq $0xc8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| diag:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
sub rsp, 0C8h
mov rbx, rdi
lea rdi, [rbp+var_E0]
mov [rdi+8], rsi
mov [rdi+10h], rdx
mov [rdi+18h], rcx
mov [rdi+20h], r8
mov [rdi+28h], r9
test al, al
jz short loc_15046
movaps [rbp+var_B0], xmm0
movaps [rbp+var_A0], xmm1
movaps [rbp+var_90], xmm2
movaps [rbp+var_80], xmm3
movaps [rbp+var_70], xmm4
movaps [rbp+var_60], xmm5
movaps [rbp+var_50], xmm6
movaps [rbp+var_40], xmm7
loc_15046:
lea r14, [rbp+var_30]
mov [r14+10h], rdi
lea rax, [rbp+arg_0]
mov [r14+8], rax
mov rax, 3000000008h
mov [r14], rax
mov r15, cs:stdout_ptr
mov rdi, [r15]
lea rdx, asc_347BF; "# "
mov esi, 1
xor eax, eax
call ___fprintf_chk
mov rdi, [r15]
mov esi, 1
mov rdx, rbx
mov rcx, r14
call ___vfprintf_chk
mov rdi, [r15]
lea rdx, aExecuteTestWit+28h; "\n"
mov esi, 1
xor eax, eax
call ___fprintf_chk
add rsp, 0C8h
pop rbx
pop r14
pop r15
pop rbp
retn
| long long diag(
long long a1,
long long a2,
long long a3,
long long a4,
long long a5,
long long a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
__m128 a12,
__m128 a13,
__m128 a14,
char a15)
{
char v16; // [rsp+0h] [rbp-E0h] BYREF
long long v17; // [rsp+8h] [rbp-D8h]
long long v18; // [rsp+10h] [rbp-D0h]
long long v19; // [rsp+18h] [rbp-C8h]
long long v20; // [rsp+20h] [rbp-C0h]
long long v21; // [rsp+28h] [rbp-B8h]
__m128 v22; // [rsp+30h] [rbp-B0h]
__m128 v23; // [rsp+40h] [rbp-A0h]
__m128 v24; // [rsp+50h] [rbp-90h]
__m128 v25; // [rsp+60h] [rbp-80h]
__m128 v26; // [rsp+70h] [rbp-70h]
__m128 v27; // [rsp+80h] [rbp-60h]
__m128 v28; // [rsp+90h] [rbp-50h]
__m128 v29; // [rsp+A0h] [rbp-40h]
_QWORD v30[6]; // [rsp+B0h] [rbp-30h] BYREF
v22 = a7;
v23 = a8;
v24 = a9;
v25 = a10;
v26 = a11;
v27 = a12;
v28 = a13;
v29 = a14;
v17 = a2;
v18 = a3;
v19 = a4;
v20 = a5;
v21 = a6;
v30[2] = &v16;
v30[1] = &a15;
v30[0] = 0x3000000008LL;
__fprintf_chk(stdout, 1LL, "# ");
__vfprintf_chk(stdout, 1LL, a1, v30);
return __fprintf_chk(stdout, 1LL, "\n");
}
| diag:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0xc8
MOV RBX,RDI
LEA RDI,[RBP + -0xe0]
MOV qword ptr [RDI + 0x8],RSI
MOV qword ptr [RDI + 0x10],RDX
MOV qword ptr [RDI + 0x18],RCX
MOV qword ptr [RDI + 0x20],R8
MOV qword ptr [RDI + 0x28],R9
TEST AL,AL
JZ 0x00115046
MOVAPS xmmword ptr [RBP + -0xb0],XMM0
MOVAPS xmmword ptr [RBP + -0xa0],XMM1
MOVAPS xmmword ptr [RBP + -0x90],XMM2
MOVAPS xmmword ptr [RBP + -0x80],XMM3
MOVAPS xmmword ptr [RBP + -0x70],XMM4
MOVAPS xmmword ptr [RBP + -0x60],XMM5
MOVAPS xmmword ptr [RBP + -0x50],XMM6
MOVAPS xmmword ptr [RBP + -0x40],XMM7
LAB_00115046:
LEA R14,[RBP + -0x30]
MOV qword ptr [R14 + 0x10],RDI
LEA RAX,[RBP + 0x10]
MOV qword ptr [R14 + 0x8],RAX
MOV RAX,0x3000000008
MOV qword ptr [R14],RAX
MOV R15,qword ptr [0x00146fb0]
MOV RDI,qword ptr [R15]
LEA RDX,[0x1347bf]
MOV ESI,0x1
XOR EAX,EAX
CALL 0x00113740
MOV RDI,qword ptr [R15]
MOV ESI,0x1
MOV RDX,RBX
MOV RCX,R14
CALL 0x00113150
MOV RDI,qword ptr [R15]
LEA RDX,[0x1345de]
MOV ESI,0x1
XOR EAX,EAX
CALL 0x00113740
ADD RSP,0xc8
POP RBX
POP R14
POP R15
POP RBP
RET
|
void diag(int8 param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5,int8 param_6,int8 param_7,int8 param_8,
int8 param_9,int8 param_10,int8 param_11,int8 param_12,
int8 param_13,int8 param_14)
{
int *puVar1;
char in_AL;
int1 local_e8 [8];
int8 local_e0;
int8 local_d8;
int8 local_d0;
int8 local_c8;
int8 local_c0;
int8 local_b8;
int8 local_a8;
int8 local_98;
int8 local_88;
int8 local_78;
int8 local_68;
int8 local_58;
int8 local_48;
int8 local_38;
int1 *local_30;
int1 *local_28;
puVar1 = PTR_stdout_00146fb0;
local_28 = local_e8;
if (in_AL != '\0') {
local_b8 = param_1;
local_a8 = param_2;
local_98 = param_3;
local_88 = param_4;
local_78 = param_5;
local_68 = param_6;
local_58 = param_7;
local_48 = param_8;
}
local_30 = &stack0x00000008;
local_38 = 0x3000000008;
local_e0 = param_10;
local_d8 = param_11;
local_d0 = param_12;
local_c8 = param_13;
local_c0 = param_14;
__fprintf_chk(*(int8 *)PTR_stdout_00146fb0,1,&DAT_001347bf);
__vfprintf_chk(*(int8 *)puVar1,1,param_9,&local_38);
__fprintf_chk(*(int8 *)puVar1,1,"\n");
return;
}
| |
22,185 | c4_verify | corpus-core[P]colibri-stateless/src/verifier/verify.c | c4_status_t c4_verify(verify_ctx_t* ctx) {
// make sure the state is clean
if (ctx->state.error) return C4_ERROR;
if (c4_state_get_pending_request(&ctx->state)) return C4_PENDING;
// verify the proof
if (!handle_verification(ctx))
ctx->state.error = bprintf(NULL, "verification for proof of chain %l is not supported", ctx->chain_id);
return (ctx->state.error ? C4_ERROR : (c4_state_get_pending_request(&ctx->state) ? C4_PENDING : C4_SUCCESS));
} | O1 | c | c4_verify:
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
cmpq $0x0, 0x78(%rdi)
je 0x25bd0
retq
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
leaq 0x70(%rdi), %rbx
movq %rbx, %rdi
callq 0x5cf2e
movq %rax, %rcx
movl $0x2, %eax
testq %rcx, %rcx
jne 0x25c38
movq %r14, %rdi
callq 0x26a38
testb %al, %al
jne 0x25c17
movl 0x80(%r14), %edx
leaq 0x5f982(%rip), %rsi # 0x8558c
xorl %edi, %edi
xorl %eax, %eax
callq 0x57769
movq %rax, 0x78(%r14)
cmpq $0x0, 0x78(%r14)
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
jne 0x25c38
movq %rbx, %rdi
callq 0x5cf2e
movq %rax, %rcx
xorl %eax, %eax
testq %rcx, %rcx
setne %al
addl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| c4_verify:
mov eax, 0FFFFFFFFh
cmp qword ptr [rdi+78h], 0
jz short loc_25BD0
retn
loc_25BD0:
push r14
push rbx
push rax
mov r14, rdi
lea rbx, [rdi+70h]
mov rdi, rbx
call c4_state_get_pending_request
mov rcx, rax
mov eax, 2
test rcx, rcx
jnz short loc_25C38
mov rdi, r14
call c4_eth_verify
test al, al
jnz short loc_25C17
mov edx, [r14+80h]
lea rsi, aVerificationFo; "verification for proof of chain %l is n"...
xor edi, edi
xor eax, eax
call bprintf
mov [r14+78h], rax
loc_25C17:
cmp qword ptr [r14+78h], 0
mov eax, 0FFFFFFFFh
jnz short loc_25C38
mov rdi, rbx
call c4_state_get_pending_request
mov rcx, rax
xor eax, eax
test rcx, rcx
setnz al
add eax, eax
loc_25C38:
add rsp, 8
pop rbx
pop r14
retn
| long long c4_verify(long long a1)
{
long long result; // rax
long long pending_request; // rcx
int v3; // ecx
int v4; // r8d
int v5; // r9d
result = 0xFFFFFFFFLL;
if ( !*(_QWORD *)(a1 + 120) )
{
pending_request = c4_state_get_pending_request(a1 + 112);
result = 2LL;
if ( !pending_request )
{
if ( !(unsigned __int8)c4_eth_verify(a1) )
*(_QWORD *)(a1 + 120) = bprintf(
0,
(unsigned int)"verification for proof of chain %l is not supported",
*(_DWORD *)(a1 + 128),
v3,
v4,
v5);
result = 0xFFFFFFFFLL;
if ( !*(_QWORD *)(a1 + 120) )
return 2 * (unsigned int)(c4_state_get_pending_request(a1 + 112) != 0);
}
}
return result;
}
| c4_verify:
MOV EAX,0xffffffff
CMP qword ptr [RDI + 0x78],0x0
JZ 0x00125bd0
RET
LAB_00125bd0:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RDI
LEA RBX,[RDI + 0x70]
MOV RDI,RBX
CALL 0x0015cf2e
MOV RCX,RAX
MOV EAX,0x2
TEST RCX,RCX
JNZ 0x00125c38
MOV RDI,R14
CALL 0x00126a38
TEST AL,AL
JNZ 0x00125c17
MOV EDX,dword ptr [R14 + 0x80]
LEA RSI,[0x18558c]
XOR EDI,EDI
XOR EAX,EAX
CALL 0x00157769
MOV qword ptr [R14 + 0x78],RAX
LAB_00125c17:
CMP qword ptr [R14 + 0x78],0x0
MOV EAX,0xffffffff
JNZ 0x00125c38
MOV RDI,RBX
CALL 0x0015cf2e
MOV RCX,RAX
XOR EAX,EAX
TEST RCX,RCX
SETNZ AL
ADD EAX,EAX
LAB_00125c38:
ADD RSP,0x8
POP RBX
POP R14
RET
|
int c4_verify(long param_1)
{
char cVar1;
int iVar2;
long lVar3;
int8 uVar4;
if (*(long *)(param_1 + 0x78) != 0) {
return -1;
}
lVar3 = c4_state_get_pending_request(param_1 + 0x70);
iVar2 = 2;
if (lVar3 == 0) {
cVar1 = c4_eth_verify(param_1);
if (cVar1 == '\0') {
uVar4 = bprintf(0,"verification for proof of chain %l is not supported",
*(int4 *)(param_1 + 0x80));
*(int8 *)(param_1 + 0x78) = uVar4;
}
iVar2 = -1;
if (*(long *)(param_1 + 0x78) == 0) {
lVar3 = c4_state_get_pending_request(param_1 + 0x70);
iVar2 = (uint)(lVar3 != 0) * 2;
}
}
return iVar2;
}
| |
22,186 | c4_verify | corpus-core[P]colibri-stateless/src/verifier/verify.c | c4_status_t c4_verify(verify_ctx_t* ctx) {
// make sure the state is clean
if (ctx->state.error) return C4_ERROR;
if (c4_state_get_pending_request(&ctx->state)) return C4_PENDING;
// verify the proof
if (!handle_verification(ctx))
ctx->state.error = bprintf(NULL, "verification for proof of chain %l is not supported", ctx->chain_id);
return (ctx->state.error ? C4_ERROR : (c4_state_get_pending_request(&ctx->state) ? C4_PENDING : C4_SUCCESS));
} | O2 | c | c4_verify:
pushq %r15
pushq %r14
pushq %rbx
pushq $-0x1
popq %rbx
cmpq $0x0, 0x78(%rdi)
jne 0x24a58
movq %rdi, %r15
leaq 0x70(%rdi), %r14
movq %r14, %rdi
callq 0x50655
testq %rax, %rax
je 0x24a14
pushq $0x2
popq %rbx
jmp 0x24a58
movq %r15, %rdi
callq 0x25743
testb %al, %al
je 0x24a26
movq 0x78(%r15), %rax
jmp 0x24a41
movl 0x80(%r15), %edx
leaq 0x4fb58(%rip), %rsi # 0x7458c
xorl %edi, %edi
xorl %eax, %eax
callq 0x4b737
movq %rax, 0x78(%r15)
testq %rax, %rax
jne 0x24a58
movq %r14, %rdi
callq 0x50655
xorl %ebx, %ebx
testq %rax, %rax
setne %bl
addl %ebx, %ebx
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
| c4_verify:
push r15
push r14
push rbx
push 0FFFFFFFFFFFFFFFFh
pop rbx
cmp qword ptr [rdi+78h], 0
jnz short loc_24A58
mov r15, rdi
lea r14, [rdi+70h]
mov rdi, r14
call c4_state_get_pending_request
test rax, rax
jz short loc_24A14
push 2
pop rbx
jmp short loc_24A58
loc_24A14:
mov rdi, r15
call c4_eth_verify
test al, al
jz short loc_24A26
mov rax, [r15+78h]
jmp short loc_24A41
loc_24A26:
mov edx, [r15+80h]
lea rsi, aVerificationFo; "verification for proof of chain %l is n"...
xor edi, edi
xor eax, eax
call bprintf
mov [r15+78h], rax
loc_24A41:
test rax, rax
jnz short loc_24A58
mov rdi, r14
call c4_state_get_pending_request
xor ebx, ebx
test rax, rax
setnz bl
add ebx, ebx
loc_24A58:
mov eax, ebx
pop rbx
pop r14
pop r15
retn
| long long c4_verify(long long a1)
{
unsigned int v1; // ebx
int v2; // ecx
int v3; // r8d
int v4; // r9d
long long v5; // rax
v1 = -1;
if ( !*(_QWORD *)(a1 + 120) )
{
if ( c4_state_get_pending_request(a1 + 112) )
{
return 2;
}
else
{
if ( (unsigned __int8)c4_eth_verify(a1) )
{
v5 = *(_QWORD *)(a1 + 120);
}
else
{
v5 = bprintf(
0,
(unsigned int)"verification for proof of chain %l is not supported",
*(_DWORD *)(a1 + 128),
v2,
v3,
v4);
*(_QWORD *)(a1 + 120) = v5;
}
if ( !v5 )
return 2 * (unsigned int)(c4_state_get_pending_request(a1 + 112) != 0);
}
}
return v1;
}
| c4_verify:
PUSH R15
PUSH R14
PUSH RBX
PUSH -0x1
POP RBX
CMP qword ptr [RDI + 0x78],0x0
JNZ 0x00124a58
MOV R15,RDI
LEA R14,[RDI + 0x70]
MOV RDI,R14
CALL 0x00150655
TEST RAX,RAX
JZ 0x00124a14
PUSH 0x2
POP RBX
JMP 0x00124a58
LAB_00124a14:
MOV RDI,R15
CALL 0x00125743
TEST AL,AL
JZ 0x00124a26
MOV RAX,qword ptr [R15 + 0x78]
JMP 0x00124a41
LAB_00124a26:
MOV EDX,dword ptr [R15 + 0x80]
LEA RSI,[0x17458c]
XOR EDI,EDI
XOR EAX,EAX
CALL 0x0014b737
MOV qword ptr [R15 + 0x78],RAX
LAB_00124a41:
TEST RAX,RAX
JNZ 0x00124a58
MOV RDI,R14
CALL 0x00150655
XOR EBX,EBX
TEST RAX,RAX
SETNZ BL
ADD EBX,EBX
LAB_00124a58:
MOV EAX,EBX
POP RBX
POP R14
POP R15
RET
|
int c4_verify(long param_1)
{
char cVar1;
long lVar2;
int iVar3;
iVar3 = -1;
if (*(long *)(param_1 + 0x78) == 0) {
lVar2 = c4_state_get_pending_request(param_1 + 0x70);
if (lVar2 == 0) {
cVar1 = c4_eth_verify(param_1);
if (cVar1 == '\0') {
lVar2 = bprintf(0,"verification for proof of chain %l is not supported",
*(int4 *)(param_1 + 0x80));
*(long *)(param_1 + 0x78) = lVar2;
}
else {
lVar2 = *(long *)(param_1 + 0x78);
}
if (lVar2 == 0) {
lVar2 = c4_state_get_pending_request(param_1 + 0x70);
iVar3 = (uint)(lVar2 != 0) * 2;
}
}
else {
iVar3 = 2;
}
}
return iVar3;
}
| |
22,187 | c4_verify | corpus-core[P]colibri-stateless/src/verifier/verify.c | c4_status_t c4_verify(verify_ctx_t* ctx) {
// make sure the state is clean
if (ctx->state.error) return C4_ERROR;
if (c4_state_get_pending_request(&ctx->state)) return C4_PENDING;
// verify the proof
if (!handle_verification(ctx))
ctx->state.error = bprintf(NULL, "verification for proof of chain %l is not supported", ctx->chain_id);
return (ctx->state.error ? C4_ERROR : (c4_state_get_pending_request(&ctx->state) ? C4_PENDING : C4_SUCCESS));
} | O3 | c | c4_verify:
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
cmpq $0x0, 0x78(%rdi)
je 0x2571d
retq
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
leaq 0x70(%rdi), %rbx
movq %rbx, %rdi
callq 0x589ae
movq %rax, %rcx
movl $0x2, %eax
testq %rcx, %rcx
jne 0x2578c
movq %r14, %rdi
callq 0x26510
testb %al, %al
je 0x2574f
movq 0x78(%r14), %rcx
jmp 0x2576d
movl 0x80(%r14), %edx
leaq 0x5be2f(%rip), %rsi # 0x8158c
xorl %edi, %edi
xorl %eax, %eax
callq 0x53780
movq %rax, %rcx
movq %rax, 0x78(%r14)
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
testq %rcx, %rcx
jne 0x2578c
movq %rbx, %rdi
callq 0x589ae
movq %rax, %rcx
xorl %eax, %eax
testq %rcx, %rcx
setne %al
addl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
| c4_verify:
mov eax, 0FFFFFFFFh
cmp qword ptr [rdi+78h], 0
jz short loc_2571D
retn
loc_2571D:
push r14
push rbx
push rax
mov r14, rdi
lea rbx, [rdi+70h]
mov rdi, rbx
call c4_state_get_pending_request
mov rcx, rax
mov eax, 2
test rcx, rcx
jnz short loc_2578C
mov rdi, r14
call c4_eth_verify
test al, al
jz short loc_2574F
mov rcx, [r14+78h]
jmp short loc_2576D
loc_2574F:
mov edx, [r14+80h]
lea rsi, aVerificationFo; "verification for proof of chain %l is n"...
xor edi, edi
xor eax, eax
call bprintf
mov rcx, rax
mov [r14+78h], rax
loc_2576D:
mov eax, 0FFFFFFFFh
test rcx, rcx
jnz short loc_2578C
mov rdi, rbx
call c4_state_get_pending_request
mov rcx, rax
xor eax, eax
test rcx, rcx
setnz al
add eax, eax
loc_2578C:
add rsp, 8
pop rbx
pop r14
retn
| long long c4_verify(long long a1)
{
long long result; // rax
long long pending_request; // rcx
int v3; // ecx
int v4; // r8d
int v5; // r9d
long long v6; // rcx
result = 0xFFFFFFFFLL;
if ( !*(_QWORD *)(a1 + 120) )
{
pending_request = c4_state_get_pending_request(a1 + 112);
result = 2LL;
if ( !pending_request )
{
if ( (unsigned __int8)c4_eth_verify(a1) )
{
v6 = *(_QWORD *)(a1 + 120);
}
else
{
v6 = bprintf(
0,
(unsigned int)"verification for proof of chain %l is not supported",
*(_DWORD *)(a1 + 128),
v3,
v4,
v5);
*(_QWORD *)(a1 + 120) = v6;
}
result = 0xFFFFFFFFLL;
if ( !v6 )
return 2 * (unsigned int)(c4_state_get_pending_request(a1 + 112) != 0);
}
}
return result;
}
| c4_verify:
MOV EAX,0xffffffff
CMP qword ptr [RDI + 0x78],0x0
JZ 0x0012571d
RET
LAB_0012571d:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RDI
LEA RBX,[RDI + 0x70]
MOV RDI,RBX
CALL 0x001589ae
MOV RCX,RAX
MOV EAX,0x2
TEST RCX,RCX
JNZ 0x0012578c
MOV RDI,R14
CALL 0x00126510
TEST AL,AL
JZ 0x0012574f
MOV RCX,qword ptr [R14 + 0x78]
JMP 0x0012576d
LAB_0012574f:
MOV EDX,dword ptr [R14 + 0x80]
LEA RSI,[0x18158c]
XOR EDI,EDI
XOR EAX,EAX
CALL 0x00153780
MOV RCX,RAX
MOV qword ptr [R14 + 0x78],RAX
LAB_0012576d:
MOV EAX,0xffffffff
TEST RCX,RCX
JNZ 0x0012578c
MOV RDI,RBX
CALL 0x001589ae
MOV RCX,RAX
XOR EAX,EAX
TEST RCX,RCX
SETNZ AL
ADD EAX,EAX
LAB_0012578c:
ADD RSP,0x8
POP RBX
POP R14
RET
|
int c4_verify(long param_1)
{
char cVar1;
int iVar2;
long lVar3;
if (*(long *)(param_1 + 0x78) != 0) {
return -1;
}
lVar3 = c4_state_get_pending_request(param_1 + 0x70);
iVar2 = 2;
if (lVar3 == 0) {
cVar1 = c4_eth_verify(param_1);
if (cVar1 == '\0') {
lVar3 = bprintf(0,"verification for proof of chain %l is not supported",
*(int4 *)(param_1 + 0x80));
*(long *)(param_1 + 0x78) = lVar3;
}
else {
lVar3 = *(long *)(param_1 + 0x78);
}
iVar2 = -1;
if (lVar3 == 0) {
lVar3 = c4_state_get_pending_request(param_1 + 0x70);
iVar2 = (uint)(lVar3 != 0) * 2;
}
}
return iVar2;
}
| |
22,188 | mi_reset | eloqsql/storage/myisam/mi_extra.c | int mi_reset(MI_INFO *info)
{
int error= 0;
MYISAM_SHARE *share=info->s;
DBUG_ENTER("mi_reset");
/*
Free buffers and reset the following flags:
EXTRA_CACHE, EXTRA_WRITE_CACHE, EXTRA_KEYREAD, EXTRA_QUICK
If the row buffer cache is large (for dynamic tables), reduce it
to save memory.
*/
if (info->opt_flag & (READ_CACHE_USED | WRITE_CACHE_USED))
{
info->opt_flag&= ~(READ_CACHE_USED | WRITE_CACHE_USED);
error= end_io_cache(&info->rec_cache);
}
if (share->base.blobs)
mi_alloc_rec_buff(info, -1, &info->rec_buff);
#if defined(HAVE_MMAP) && defined(HAVE_MADVISE)
if (info->opt_flag & MEMMAP_USED)
madvise((char*) share->file_map, share->state.state.data_file_length,
MADV_RANDOM);
#endif
info->opt_flag&= ~(KEY_READ_USED | REMEMBER_OLD_POS);
info->quick_mode=0;
info->lastinx= 0; /* Use first index as def */
info->last_search_keypage= info->lastpos= HA_OFFSET_ERROR;
info->page_changed= 1;
info->update= ((info->update & HA_STATE_CHANGED) | HA_STATE_NEXT_FOUND |
HA_STATE_PREV_FOUND);
DBUG_RETURN(error);
} | O0 | c | mi_reset:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl 0x1c8(%rax), %eax
andl $0x12, %eax
cmpl $0x0, %eax
je 0xade96
movq -0x8(%rbp), %rax
movl 0x1c8(%rax), %ecx
andl $-0x13, %ecx
movl %ecx, 0x1c8(%rax)
movq -0x8(%rbp), %rdi
addq $0x220, %rdi # imm = 0x220
callq 0xe21b0
movl %eax, -0xc(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, 0x188(%rax)
je 0xadebe
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rdx
addq $0x120, %rdx # imm = 0x120
movq $-0x1, %rsi
callq 0xb6da0
movq -0x8(%rbp), %rax
movl 0x1c8(%rax), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0xadeed
movq -0x18(%rbp), %rax
movq 0x270(%rax), %rdi
movq -0x18(%rbp), %rax
movq 0x40(%rax), %rsi
movl $0x1, %edx
callq 0x2a460
movq -0x8(%rbp), %rax
movl 0x1c8(%rax), %ecx
andl $-0x49, %ecx
movl %ecx, 0x1c8(%rax)
movq -0x8(%rbp), %rax
movb $0x0, 0x33b(%rax)
movq -0x8(%rbp), %rax
movl $0x0, 0x1d4(%rax)
movq -0x8(%rbp), %rax
movq $-0x1, 0x170(%rax)
movq -0x8(%rbp), %rax
movq $-0x1, 0x198(%rax)
movq -0x8(%rbp), %rax
movb $0x1, 0x33c(%rax)
movq -0x8(%rbp), %rax
movl 0x1d0(%rax), %ecx
andl $0x1, %ecx
orl $0x10, %ecx
orl $0x20, %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x1d0(%rax)
movl -0xc(%rbp), %eax
movl %eax, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
| mi_reset:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov [rbp+var_C], 0
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_18], rax
mov rax, [rbp+var_8]
mov eax, [rax+1C8h]
and eax, 12h
cmp eax, 0
jz short loc_ADE96
mov rax, [rbp+var_8]
mov ecx, [rax+1C8h]
and ecx, 0FFFFFFEDh
mov [rax+1C8h], ecx
mov rdi, [rbp+var_8]
add rdi, 220h
call end_io_cache
mov [rbp+var_C], eax
loc_ADE96:
mov rax, [rbp+var_18]
cmp dword ptr [rax+188h], 0
jz short loc_ADEBE
mov rdi, [rbp+var_8]
mov rdx, [rbp+var_8]
add rdx, 120h
mov rsi, 0FFFFFFFFFFFFFFFFh
call mi_alloc_rec_buff
loc_ADEBE:
mov rax, [rbp+var_8]
mov eax, [rax+1C8h]
and eax, 20h
cmp eax, 0
jz short loc_ADEED
mov rax, [rbp+var_18]
mov rdi, [rax+270h]
mov rax, [rbp+var_18]
mov rsi, [rax+40h]
mov edx, 1
call _madvise
loc_ADEED:
mov rax, [rbp+var_8]
mov ecx, [rax+1C8h]
and ecx, 0FFFFFFB7h
mov [rax+1C8h], ecx
mov rax, [rbp+var_8]
mov byte ptr [rax+33Bh], 0
mov rax, [rbp+var_8]
mov dword ptr [rax+1D4h], 0
mov rax, [rbp+var_8]
mov qword ptr [rax+170h], 0FFFFFFFFFFFFFFFFh
mov rax, [rbp+var_8]
mov qword ptr [rax+198h], 0FFFFFFFFFFFFFFFFh
mov rax, [rbp+var_8]
mov byte ptr [rax+33Ch], 1
mov rax, [rbp+var_8]
mov ecx, [rax+1D0h]
and ecx, 1
or ecx, 10h
or ecx, 20h
mov rax, [rbp+var_8]
mov [rax+1D0h], ecx
mov eax, [rbp+var_C]
mov [rbp+var_1C], eax
mov eax, [rbp+var_1C]
add rsp, 20h
pop rbp
retn
| long long mi_reset(long long *a1)
{
long long v2; // [rsp+8h] [rbp-18h]
unsigned int v3; // [rsp+14h] [rbp-Ch]
v3 = 0;
v2 = *a1;
if ( (a1[57] & 0x12) != 0 )
{
*((_DWORD *)a1 + 114) &= 0xFFFFFFED;
v3 = end_io_cache(a1 + 68);
}
if ( *(_DWORD *)(v2 + 392) )
mi_alloc_rec_buff(a1, -1LL, a1 + 36);
if ( (a1[57] & 0x20) != 0 )
madvise(*(_QWORD *)(v2 + 624), *(_QWORD *)(v2 + 64), 1LL);
*((_DWORD *)a1 + 114) &= 0xFFFFFFB7;
*((_BYTE *)a1 + 827) = 0;
*((_DWORD *)a1 + 117) = 0;
a1[46] = -1LL;
a1[51] = -1LL;
*((_BYTE *)a1 + 828) = 1;
*((_DWORD *)a1 + 116) = a1[58] & 1 | 0x30;
return v3;
}
| mi_reset:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x1c8]
AND EAX,0x12
CMP EAX,0x0
JZ 0x001ade96
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x1c8]
AND ECX,0xffffffed
MOV dword ptr [RAX + 0x1c8],ECX
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x220
CALL 0x001e21b0
MOV dword ptr [RBP + -0xc],EAX
LAB_001ade96:
MOV RAX,qword ptr [RBP + -0x18]
CMP dword ptr [RAX + 0x188],0x0
JZ 0x001adebe
MOV RDI,qword ptr [RBP + -0x8]
MOV RDX,qword ptr [RBP + -0x8]
ADD RDX,0x120
MOV RSI,-0x1
CALL 0x001b6da0
LAB_001adebe:
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x1c8]
AND EAX,0x20
CMP EAX,0x0
JZ 0x001adeed
MOV RAX,qword ptr [RBP + -0x18]
MOV RDI,qword ptr [RAX + 0x270]
MOV RAX,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RAX + 0x40]
MOV EDX,0x1
CALL 0x0012a460
LAB_001adeed:
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x1c8]
AND ECX,0xffffffb7
MOV dword ptr [RAX + 0x1c8],ECX
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x33b],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x1d4],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x170],-0x1
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x198],-0x1
MOV RAX,qword ptr [RBP + -0x8]
MOV byte ptr [RAX + 0x33c],0x1
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x1d0]
AND ECX,0x1
OR ECX,0x10
OR ECX,0x20
MOV RAX,qword ptr [RBP + -0x8]
MOV dword ptr [RAX + 0x1d0],ECX
MOV EAX,dword ptr [RBP + -0xc]
MOV dword ptr [RBP + -0x1c],EAX
MOV EAX,dword ptr [RBP + -0x1c]
ADD RSP,0x20
POP RBP
RET
|
int4 mi_reset(long *param_1)
{
long lVar1;
int4 local_14;
local_14 = 0;
lVar1 = *param_1;
if ((*(uint *)(param_1 + 0x39) & 0x12) != 0) {
*(uint *)(param_1 + 0x39) = *(uint *)(param_1 + 0x39) & 0xffffffed;
local_14 = end_io_cache(param_1 + 0x44);
}
if (*(int *)(lVar1 + 0x188) != 0) {
mi_alloc_rec_buff(param_1,0xffffffffffffffff,param_1 + 0x24);
}
if ((*(uint *)(param_1 + 0x39) & 0x20) != 0) {
madvise(*(void **)(lVar1 + 0x270),*(size_t *)(lVar1 + 0x40),1);
}
*(uint *)(param_1 + 0x39) = *(uint *)(param_1 + 0x39) & 0xffffffb7;
*(int1 *)((long)param_1 + 0x33b) = 0;
*(int4 *)((long)param_1 + 0x1d4) = 0;
param_1[0x2e] = -1;
param_1[0x33] = -1;
*(int1 *)((long)param_1 + 0x33c) = 1;
*(uint *)(param_1 + 0x3a) = *(uint *)(param_1 + 0x3a) & 1 | 0x30;
return local_14;
}
| |
22,189 | mbedtls_sha512_update_ret | msxemulator/build_O3/_deps/pico_sdk-src/lib/mbedtls/library/sha512.c | int mbedtls_sha512_update_ret(mbedtls_sha512_context *ctx,
const unsigned char *input,
size_t ilen)
{
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
size_t fill;
unsigned int left;
SHA512_VALIDATE_RET(ctx != NULL);
SHA512_VALIDATE_RET(ilen == 0 || input != NULL);
if (ilen == 0) {
return 0;
}
left = (unsigned int) (ctx->total[0] & 0x7F);
fill = 128 - left;
ctx->total[0] += (uint64_t) ilen;
if (ctx->total[0] < (uint64_t) ilen) {
ctx->total[1]++;
}
if (left && ilen >= fill) {
memcpy((void *) (ctx->buffer + left), input, fill);
if ((ret = mbedtls_internal_sha512_process(ctx, ctx->buffer)) != 0) {
return ret;
}
input += fill;
ilen -= fill;
left = 0;
}
while (ilen >= 128) {
if ((ret = mbedtls_internal_sha512_process(ctx, input)) != 0) {
return ret;
}
input += 128;
ilen -= 128;
}
if (ilen > 0) {
memcpy((void *) (ctx->buffer + left), input, ilen);
}
return 0;
} | O3 | c | mbedtls_sha512_update_ret:
testq %rdx, %rdx
je 0x95c81
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq (%rdi), %rcx
movl %ecx, %eax
andl $0x7f, %eax
movq %rcx, %rsi
addq %rdx, %rsi
movq %rsi, (%rdi)
jae 0x95bf8
incq 0x8(%r14)
testl %eax, %eax
je 0x95c37
movl $0x80, %r15d
subl %eax, %r15d
movq %rdx, %r13
subq %r15, %r13
jb 0x95c66
leaq 0x50(%r14), %r12
andl $0x7f, %ecx
leaq (%r14,%rcx), %rdi
addq $0x50, %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0xf3a0
movq %r14, %rdi
movq %r12, %rsi
callq 0x9565e
addq %r15, %rbx
jmp 0x95c3a
movq %rdx, %r13
cmpq $0x80, %r13
jb 0x95c5c
movq %r14, %rdi
movq %rbx, %rsi
callq 0x9565e
subq $-0x80, %rbx
addq $-0x80, %r13
cmpq $0x7f, %r13
ja 0x95c43
xorl %eax, %eax
movq %r13, %rdx
testq %r13, %r13
je 0x95c78
movl %eax, %eax
leaq (%r14,%rax), %rdi
addq $0x50, %rdi
movq %rbx, %rsi
callq 0xf3a0
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
xorl %eax, %eax
retq
| mbedtls_sha512_update_ret:
test rdx, rdx
jz loc_95C81
push r15
push r14
push r13
push r12
push rbx
mov rbx, rsi
mov r14, rdi
mov rcx, [rdi]
mov eax, ecx
and eax, 7Fh
mov rsi, rcx
add rsi, rdx
mov [rdi], rsi
jnb short loc_95BF8
inc qword ptr [r14+8]
loc_95BF8:
test eax, eax
jz short loc_95C37
mov r15d, 80h
sub r15d, eax
mov r13, rdx
sub r13, r15
jb short loc_95C66
lea r12, [r14+50h]
and ecx, 7Fh
lea rdi, [r14+rcx]
add rdi, 50h ; 'P'
mov rsi, rbx
mov rdx, r15
call _memcpy
mov rdi, r14
mov rsi, r12
call mbedtls_internal_sha512_process
add rbx, r15
jmp short loc_95C3A
loc_95C37:
mov r13, rdx
loc_95C3A:
cmp r13, 80h
jb short loc_95C5C
loc_95C43:
mov rdi, r14
mov rsi, rbx
call mbedtls_internal_sha512_process
sub rbx, 0FFFFFFFFFFFFFF80h
add r13, 0FFFFFFFFFFFFFF80h
cmp r13, 7Fh
ja short loc_95C43
loc_95C5C:
xor eax, eax
mov rdx, r13
test r13, r13
jz short loc_95C78
loc_95C66:
mov eax, eax
lea rdi, [r14+rax]
add rdi, 50h ; 'P'
mov rsi, rbx
call _memcpy
loc_95C78:
pop rbx
pop r12
pop r13
pop r14
pop r15
loc_95C81:
xor eax, eax
retn
| long long mbedtls_sha512_update_ret(_QWORD *a1, long long a2, unsigned long long a3)
{
long long v3; // rbx
long long v4; // rcx
long long v5; // rax
bool v6; // cf
unsigned long long v7; // r15
unsigned long long v8; // r13
if ( a3 )
{
v3 = a2;
v4 = *a1;
v5 = *a1 & 0x7FLL;
v6 = __CFADD__(a3, *a1);
*a1 += a3;
if ( v6 )
++a1[1];
if ( (_DWORD)v5 )
{
v7 = (unsigned int)(128 - v5);
v8 = a3 - v7;
if ( a3 < v7 )
{
LABEL_11:
memcpy((char *)a1 + (unsigned int)v5 + 80, v3, a3);
return 0LL;
}
memcpy((char *)a1 + (v4 & 0x7F) + 80, a2, (unsigned int)(128 - v5));
mbedtls_internal_sha512_process((long long)a1, (long long)(a1 + 10));
v3 = v7 + a2;
}
else
{
v8 = a3;
}
if ( v8 >= 0x80 )
{
do
{
mbedtls_internal_sha512_process((long long)a1, v3);
v3 += 128LL;
v8 -= 128LL;
}
while ( v8 > 0x7F );
}
LODWORD(v5) = 0;
a3 = v8;
if ( v8 )
goto LABEL_11;
}
return 0LL;
}
| mbedtls_sha512_update_ret:
TEST RDX,RDX
JZ 0x00195c81
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV RBX,RSI
MOV R14,RDI
MOV RCX,qword ptr [RDI]
MOV EAX,ECX
AND EAX,0x7f
MOV RSI,RCX
ADD RSI,RDX
MOV qword ptr [RDI],RSI
JNC 0x00195bf8
INC qword ptr [R14 + 0x8]
LAB_00195bf8:
TEST EAX,EAX
JZ 0x00195c37
MOV R15D,0x80
SUB R15D,EAX
MOV R13,RDX
SUB R13,R15
JC 0x00195c66
LEA R12,[R14 + 0x50]
AND ECX,0x7f
LEA RDI,[R14 + RCX*0x1]
ADD RDI,0x50
MOV RSI,RBX
MOV RDX,R15
CALL 0x0010f3a0
MOV RDI,R14
MOV RSI,R12
CALL 0x0019565e
ADD RBX,R15
JMP 0x00195c3a
LAB_00195c37:
MOV R13,RDX
LAB_00195c3a:
CMP R13,0x80
JC 0x00195c5c
LAB_00195c43:
MOV RDI,R14
MOV RSI,RBX
CALL 0x0019565e
SUB RBX,-0x80
ADD R13,-0x80
CMP R13,0x7f
JA 0x00195c43
LAB_00195c5c:
XOR EAX,EAX
MOV RDX,R13
TEST R13,R13
JZ 0x00195c78
LAB_00195c66:
MOV EAX,EAX
LEA RDI,[R14 + RAX*0x1]
ADD RDI,0x50
MOV RSI,RBX
CALL 0x0010f3a0
LAB_00195c78:
POP RBX
POP R12
POP R13
POP R14
POP R15
LAB_00195c81:
XOR EAX,EAX
RET
|
int8 mbedtls_sha512_update_ret(ulong *param_1,void *param_2,ulong param_3)
{
ulong uVar1;
uint uVar2;
ulong __n;
if (param_3 == 0) {
return 0;
}
uVar1 = *param_1;
uVar2 = (uint)uVar1 & 0x7f;
*param_1 = uVar1 + param_3;
if (CARRY8(uVar1,param_3)) {
param_1[1] = param_1[1] + 1;
}
if ((uVar1 & 0x7f) != 0) {
__n = (ulong)(0x80 - uVar2);
if (param_3 < __n) goto LAB_00195c66;
memcpy((void *)((long)param_1 + (ulong)((uint)uVar1 & 0x7f) + 0x50),param_2,__n);
mbedtls_internal_sha512_process(param_1,param_1 + 10);
param_2 = (void *)((long)param_2 + __n);
param_3 = param_3 - __n;
}
for (; 0x7f < param_3; param_3 = param_3 - 0x80) {
mbedtls_internal_sha512_process(param_1,param_2);
param_2 = (void *)((long)param_2 + 0x80);
}
uVar2 = 0;
if (param_3 == 0) {
return 0;
}
LAB_00195c66:
memcpy((void *)((long)param_1 + (ulong)uVar2 + 0x50),param_2,param_3);
return 0;
}
| |
22,190 | ma_log_delete | eloqsql/storage/maria/ma_delete.c | my_bool _ma_log_delete(MARIA_PAGE *ma_page, const uchar *key_pos,
uint changed_length, uint move_length,
uint append_length __attribute__((unused)),
enum en_key_debug debug_marker __attribute__((unused)))
{
LSN lsn;
uchar log_data[FILEID_STORE_SIZE + PAGE_STORE_SIZE + 2 + 5+ 2 + 3 + 3 + 6 + 3 + 7];
uchar *log_pos;
LEX_CUSTRING log_array[TRANSLOG_INTERNAL_PARTS + 7];
uint translog_parts, current_size, extra_length;
uint offset= (uint) (key_pos - ma_page->buff);
MARIA_HA *info= ma_page->info;
MARIA_SHARE *share= info->s;
my_off_t page= ma_page->pos / share->block_size;
DBUG_ENTER("_ma_log_delete");
DBUG_PRINT("enter", ("page: %lu offset: %u changed_length: %u move_length: %u append_length: %u page_size: %u",
(ulong) page, offset, changed_length, move_length,
append_length, ma_page->size));
DBUG_ASSERT(share->now_transactional && move_length);
DBUG_ASSERT(offset + changed_length <= ma_page->size);
DBUG_ASSERT(ma_page->org_size - move_length + append_length == ma_page->size);
DBUG_ASSERT(move_length <= ma_page->org_size - share->keypage_header);
/* Store address of new root page */
page_store(log_data + FILEID_STORE_SIZE, page);
log_pos= log_data+ FILEID_STORE_SIZE + PAGE_STORE_SIZE;
current_size= ma_page->org_size;
#ifdef EXTRA_DEBUG_KEY_CHANGES
*log_pos++= KEY_OP_DEBUG;
*log_pos++= debug_marker;
*log_pos++= KEY_OP_DEBUG_2;
int2store(log_pos, ma_page->org_size);
int2store(log_pos+2, ma_page->size);
log_pos+=4;
#endif
/* Store keypage_flag */
*log_pos++= KEY_OP_SET_PAGEFLAG;
*log_pos++= _ma_get_keypage_flag(info->s, ma_page->buff);
log_pos[0]= KEY_OP_OFFSET;
int2store(log_pos+1, offset);
log_pos+= 3;
translog_parts= TRANSLOG_INTERNAL_PARTS + 1;
extra_length= 0;
if (changed_length)
{
if (offset + changed_length >= share->max_index_block_size)
{
changed_length= share->max_index_block_size - offset;
move_length= 0; /* Nothing to move */
current_size= share->max_index_block_size;
}
log_pos[0]= KEY_OP_CHANGE;
int2store(log_pos+1, changed_length);
log_pos+= 3;
log_array[translog_parts].str= ma_page->buff + offset;
log_array[translog_parts].length= changed_length;
translog_parts++;
/* We only have to move things after offset+changed_length */
offset+= changed_length;
}
log_array[TRANSLOG_INTERNAL_PARTS + 0].str= log_data;
log_array[TRANSLOG_INTERNAL_PARTS + 0].length= (uint) (log_pos - log_data);
if (move_length)
{
uint log_length;
if (offset + move_length < share->max_index_block_size)
{
/*
Move down things that is on page.
page_offset in apply_redo_inxed() will be at original offset
+ changed_length.
*/
log_pos[0]= KEY_OP_SHIFT;
int2store(log_pos+1, - (int) move_length);
log_length= 3;
current_size-= move_length;
}
else
{
/* Delete to end of page */
uint tmp= current_size - offset;
current_size= offset;
log_pos[0]= KEY_OP_DEL_SUFFIX;
int2store(log_pos+1, tmp);
log_length= 3;
}
log_array[translog_parts].str= log_pos;
log_array[translog_parts].length= log_length;
translog_parts++;
log_pos+= log_length;
extra_length+= log_length;
}
if (current_size != ma_page->size &&
current_size != share->max_index_block_size)
{
/* Append data that didn't fit on the page before */
uint length= (MY_MIN(ma_page->size, share->max_index_block_size) -
current_size);
uchar *data= ma_page->buff + current_size;
DBUG_ASSERT(length <= append_length);
log_pos[0]= KEY_OP_ADD_SUFFIX;
int2store(log_pos+1, length);
log_array[translog_parts].str= log_pos;
log_array[translog_parts].length= 3;
log_array[translog_parts + 1].str= data;
log_array[translog_parts + 1].length= length;
log_pos+= 3;
translog_parts+= 2;
current_size+= length;
extra_length+= 3 + length;
}
_ma_log_key_changes(ma_page,
log_array + translog_parts,
log_pos, &extra_length, &translog_parts);
/* Remember new page length for future log entires for same page */
ma_page->org_size= current_size;
if (translog_write_record(&lsn, LOGREC_REDO_INDEX,
info->trn, info,
(translog_size_t)
log_array[TRANSLOG_INTERNAL_PARTS].length +
changed_length + extra_length, translog_parts,
log_array, log_data, NULL))
DBUG_RETURN(1);
DBUG_RETURN(0);
} | O3 | c | ma_log_delete:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movl %ecx, %r11d
movl %edx, %r10d
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
movq (%rdi), %rcx
movq 0x10(%rdi), %rbx
subq %rbx, %rsi
movq (%rcx), %r14
movq 0x18(%rdi), %rax
movl 0x7bc(%r14), %r9d
xorl %r8d, %r8d
xorl %edx, %edx
divq %r9
movl %eax, -0x5e(%rbp)
shrq $0x20, %rax
movb %al, -0x5a(%rbp)
movl 0x24(%rdi), %r12d
movb $0xa, -0x59(%rbp)
movl 0x744(%r14), %eax
addl $-0x3, %eax
movb (%rbx,%rax), %al
movb %al, -0x58(%rbp)
movb $0x1, -0x57(%rbp)
movw %si, -0x56(%rbp)
testl %r10d, %r10d
je 0x5a4f6
leal (%rsi,%r10), %r9d
movl 0x7c0(%r14), %edx
movl %edx, %r15d
subl %esi, %r15d
cmpl %edx, %r9d
movl %r15d, %r13d
cmovbl %r10d, %r13d
movl %esi, %eax
addq %rbx, %rax
movq %rax, -0xd0(%rbp)
leaq -0x51(%rbp), %rax
movb $0x3, -0x3(%rax)
movw %r13w, -0x2(%rax)
movq %r13, -0xc8(%rbp)
cmpl %edx, %r9d
jae 0x5a57b
addl %esi, %r13d
movl $0x4, %r9d
movl %r13d, %esi
jmp 0x5a500
leaq -0x54(%rbp), %rax
movl $0x3, %r9d
leaq -0x60(%rbp), %rdx
movq %rdx, -0xe0(%rbp)
movl %eax, %r15d
subl %edx, %r15d
movq %r15, -0xd8(%rbp)
testl %r11d, %r11d
je 0x5a59c
leal (%rsi,%r11), %r8d
movl %r12d, %edx
subl %r11d, %edx
negl %r11d
subl %esi, %r12d
xorl %r15d, %r15d
cmpl 0x7c0(%r14), %r8d
setae %r15b
leal 0x2(%r15,%r15,4), %r8d
cmovbl %r11d, %r12d
cmovael %esi, %edx
movb %r8b, (%rax)
movw %r12w, 0x1(%rax)
movl %r9d, %esi
shll $0x4, %esi
movq %rax, -0x100(%rbp,%rsi)
movq $0x3, -0xf8(%rbp,%rsi)
incl %r9d
addq $0x3, %rax
movl $0x3, %r8d
movl %r10d, %r15d
jmp 0x5a5a2
leaq -0x60(%rbp), %rsi
movq %rsi, -0xe0(%rbp)
movq $0xf, -0xd8(%rbp)
movl $0x4, %r9d
xorl %r8d, %r8d
jmp 0x5a5a2
movl %r10d, %r15d
movl %r12d, %edx
movl 0x20(%rdi), %r10d
cmpl %r10d, %edx
je 0x5a607
movl 0x7c0(%r14), %esi
cmpl %esi, %edx
je 0x5a607
cmpl %esi, %r10d
cmovbl %r10d, %esi
movl %esi, %r10d
subl %edx, %r10d
movl %edx, %edx
addq %rdx, %rbx
movb $0x6, (%rax)
movw %r10w, 0x1(%rax)
movl %r9d, %edx
shll $0x4, %edx
movq %rax, -0x100(%rbp,%rdx)
movq $0x3, -0xf8(%rbp,%rdx)
movq %rbx, -0xf0(%rbp,%rdx)
movq %r10, -0xe8(%rbp,%rdx)
addl $0x2, %r9d
addl %r10d, %r8d
addl $0x3, %r8d
movl %esi, %edx
addl %r15d, %r8d
movl %edx, 0x24(%rdi)
movq 0x8(%rcx), %rdx
leaq -0x100(%rbp), %rax
addl 0x28(%rax), %r8d
subq $0x8, %rsp
leaq -0x60(%rbp), %r10
leaq -0x68(%rbp), %rdi
movl $0xc, %esi
pushq $0x0
pushq %r10
pushq %rax
callq 0x29c84
addq $0x20, %rsp
testb %al, %al
setne %al
movq %fs:0x28, %rcx
cmpq -0x30(%rbp), %rcx
jne 0x5a661
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x29260
| _ma_log_delete:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0D8h
mov r11d, ecx
mov r10d, edx
mov rax, fs:28h
mov [rbp+var_30], rax
mov rcx, [rdi]
mov rbx, [rdi+10h]
sub rsi, rbx
mov r14, [rcx]
mov rax, [rdi+18h]
mov r9d, [r14+7BCh]
xor r8d, r8d
xor edx, edx
div r9
mov [rbp+var_5E], eax
shr rax, 20h
mov [rbp+var_5A], al
mov r12d, [rdi+24h]
mov [rbp+var_59], 0Ah
mov eax, [r14+744h]
add eax, 0FFFFFFFDh
mov al, [rbx+rax]
mov [rbp+var_58], al
mov [rbp+var_57], 1
mov [rbp+var_56], si
test r10d, r10d
jz short loc_5A4F6
lea r9d, [rsi+r10]
mov edx, [r14+7C0h]
mov r15d, edx
sub r15d, esi
cmp r9d, edx
mov r13d, r15d
cmovb r13d, r10d
mov eax, esi
add rax, rbx
mov [rbp+var_D0], rax
lea rax, [rbp+var_51]
mov byte ptr [rax-3], 3
mov [rax-2], r13w
mov [rbp+var_C8], r13
cmp r9d, edx
jnb loc_5A57B
add r13d, esi
mov r9d, 4
mov esi, r13d
jmp short loc_5A500
loc_5A4F6:
lea rax, [rbp+var_54]
mov r9d, 3
loc_5A500:
lea rdx, [rbp+var_60]
mov [rbp+var_E0], rdx
mov r15d, eax
sub r15d, edx
mov [rbp+var_D8], r15
test r11d, r11d
jz short loc_5A59C
lea r8d, [rsi+r11]
mov edx, r12d
sub edx, r11d
neg r11d
sub r12d, esi
xor r15d, r15d
cmp r8d, [r14+7C0h]
setnb r15b
lea r8d, [r15+r15*4+2]
cmovb r12d, r11d
cmovnb edx, esi
mov [rax], r8b
mov [rax+1], r12w
mov esi, r9d
shl esi, 4
mov [rbp+rsi+var_100], rax
mov [rbp+rsi+var_F8], 3
inc r9d
add rax, 3
mov r8d, 3
mov r15d, r10d
jmp short loc_5A5A2
loc_5A57B:
lea rsi, [rbp+var_60]
mov [rbp+var_E0], rsi
mov [rbp+var_D8], 0Fh
mov r9d, 4
xor r8d, r8d
jmp short loc_5A5A2
loc_5A59C:
mov r15d, r10d
mov edx, r12d
loc_5A5A2:
mov r10d, [rdi+20h]
cmp edx, r10d
jz short loc_5A607
mov esi, [r14+7C0h]
cmp edx, esi
jz short loc_5A607
cmp r10d, esi
cmovb esi, r10d
mov r10d, esi
sub r10d, edx
mov edx, edx
add rbx, rdx
mov byte ptr [rax], 6
mov [rax+1], r10w
mov edx, r9d
shl edx, 4
mov [rbp+rdx+var_100], rax
mov [rbp+rdx+var_F8], 3
mov [rbp+rdx+var_F0], rbx
mov [rbp+rdx+var_E8], r10
add r9d, 2
add r8d, r10d
add r8d, 3
mov edx, esi
loc_5A607:
add r8d, r15d
mov [rdi+24h], edx
mov rdx, [rcx+8]
lea rax, [rbp+var_100]
add r8d, [rax+28h]
sub rsp, 8
lea r10, [rbp+var_60]
lea rdi, [rbp+var_68]
mov esi, 0Ch
push 0
push r10
push rax
call translog_write_record
add rsp, 20h
test al, al
setnz al
mov rcx, fs:28h
cmp rcx, [rbp+var_30]
jnz short loc_5A661
add rsp, 0D8h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_5A661:
call ___stack_chk_fail
| bool ma_log_delete(long long a1, int a2, unsigned int a3, int a4)
{
_QWORD *v6; // rcx
long long v7; // rbx
unsigned int v8; // esi
_DWORD *v9; // r14
int v10; // r8d
unsigned long long v11; // rax
unsigned int v12; // r12d
unsigned int v13; // r9d
unsigned int v14; // edx
unsigned int v15; // r15d
long long v16; // r13
char *v17; // rax
int v18; // r9d
unsigned int v19; // r8d
int v20; // r11d
__int16 v21; // r12
bool v22; // cf
char v23; // r8
unsigned int v24; // r10d
unsigned int v25; // esi
long long v26; // r10
_OWORD v28[2]; // [rsp+0h] [rbp-100h] BYREF
__int16 *v29; // [rsp+20h] [rbp-E0h]
long long v30; // [rsp+28h] [rbp-D8h]
long long v31; // [rsp+30h] [rbp-D0h]
long long v32; // [rsp+38h] [rbp-C8h]
char v33[8]; // [rsp+98h] [rbp-68h] BYREF
__int16 v34; // [rsp+A0h] [rbp-60h] BYREF
int v35; // [rsp+A2h] [rbp-5Eh]
char v36; // [rsp+A6h] [rbp-5Ah]
char v37; // [rsp+A7h] [rbp-59h]
char v38; // [rsp+A8h] [rbp-58h]
char v39; // [rsp+A9h] [rbp-57h]
__int16 v40; // [rsp+AAh] [rbp-56h]
char v41; // [rsp+ACh] [rbp-54h] BYREF
__int16 v42; // [rsp+ADh] [rbp-53h]
char v43; // [rsp+AFh] [rbp-51h] BYREF
unsigned long long v44; // [rsp+D0h] [rbp-30h]
v44 = __readfsqword(0x28u);
v6 = *(_QWORD **)a1;
v7 = *(_QWORD *)(a1 + 16);
v8 = a2 - v7;
v9 = **(_DWORD ***)a1;
v10 = 0;
v11 = *(_QWORD *)(a1 + 24) / (unsigned long long)(unsigned int)v9[495];
v35 = v11;
v36 = BYTE4(v11);
v12 = *(_DWORD *)(a1 + 36);
v37 = 10;
v38 = *(_BYTE *)(v7 + (unsigned int)(v9[465] - 3));
v39 = 1;
v40 = v8;
if ( a3 )
{
v13 = v8 + a3;
v14 = v9[496];
v15 = v14 - v8;
v16 = v14 - v8;
if ( v8 + a3 < v14 )
v16 = a3;
v31 = v7 + v8;
v17 = &v43;
v41 = 3;
v42 = v16;
v32 = v16;
if ( v13 >= v14 )
{
v29 = &v34;
v30 = 15LL;
v18 = 4;
v10 = 0;
goto LABEL_14;
}
v18 = 4;
v8 += v16;
}
else
{
v17 = &v41;
v18 = 3;
}
v29 = &v34;
v30 = (unsigned int)v17 - (unsigned int)&v34;
if ( a4 )
{
v19 = v8 + a4;
v14 = v12 - a4;
v20 = -a4;
v21 = v12 - v8;
v22 = v19 < v9[496];
v23 = 5 * (v19 >= v9[496]) + 2;
if ( v22 )
v21 = v20;
else
v14 = v8;
*v17 = v23;
*(_WORD *)(v17 + 1) = v21;
*(_QWORD *)((char *)v28 + (unsigned int)(16 * v18)) = v17;
*(_QWORD *)((char *)v28 + (unsigned int)(16 * v18++) + 8) = 3LL;
v17 += 3;
v10 = 3;
v15 = a3;
}
else
{
v15 = a3;
v14 = v12;
}
LABEL_14:
v24 = *(_DWORD *)(a1 + 32);
if ( v14 != v24 )
{
v25 = v9[496];
if ( v14 != v25 )
{
if ( v24 < v25 )
v25 = *(_DWORD *)(a1 + 32);
v26 = v25 - v14;
*v17 = 6;
*(_WORD *)(v17 + 1) = v25 - v14;
*(_QWORD *)((char *)v28 + (unsigned int)(16 * v18)) = v17;
*(_QWORD *)((char *)v28 + (unsigned int)(16 * v18) + 8) = 3LL;
*(_QWORD *)((char *)&v28[1] + (unsigned int)(16 * v18)) = v14 + v7;
*(_QWORD *)((char *)&v28[1] + (unsigned int)(16 * v18) + 8) = v26;
v18 += 2;
v10 += v26 + 3;
v14 = v25;
}
}
*(_DWORD *)(a1 + 36) = v14;
return (unsigned __int8)translog_write_record(
(unsigned long long)v33,
&byte_9[3],
v6[1],
v6,
(unsigned int)v30 + v15 + v10,
v18,
v28,
&v34,
0LL) != 0;
}
| _ma_log_delete:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0xd8
MOV R11D,ECX
MOV R10D,EDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
MOV RCX,qword ptr [RDI]
MOV RBX,qword ptr [RDI + 0x10]
SUB RSI,RBX
MOV R14,qword ptr [RCX]
MOV RAX,qword ptr [RDI + 0x18]
MOV R9D,dword ptr [R14 + 0x7bc]
XOR R8D,R8D
XOR EDX,EDX
DIV R9
MOV dword ptr [RBP + -0x5e],EAX
SHR RAX,0x20
MOV byte ptr [RBP + -0x5a],AL
MOV R12D,dword ptr [RDI + 0x24]
MOV byte ptr [RBP + -0x59],0xa
MOV EAX,dword ptr [R14 + 0x744]
ADD EAX,-0x3
MOV AL,byte ptr [RBX + RAX*0x1]
MOV byte ptr [RBP + -0x58],AL
MOV byte ptr [RBP + -0x57],0x1
MOV word ptr [RBP + -0x56],SI
TEST R10D,R10D
JZ 0x0015a4f6
LEA R9D,[RSI + R10*0x1]
MOV EDX,dword ptr [R14 + 0x7c0]
MOV R15D,EDX
SUB R15D,ESI
CMP R9D,EDX
MOV R13D,R15D
CMOVC R13D,R10D
MOV EAX,ESI
ADD RAX,RBX
MOV qword ptr [RBP + -0xd0],RAX
LEA RAX,[RBP + -0x51]
MOV byte ptr [RAX + -0x3],0x3
MOV word ptr [RAX + -0x2],R13W
MOV qword ptr [RBP + -0xc8],R13
CMP R9D,EDX
JNC 0x0015a57b
ADD R13D,ESI
MOV R9D,0x4
MOV ESI,R13D
JMP 0x0015a500
LAB_0015a4f6:
LEA RAX,[RBP + -0x54]
MOV R9D,0x3
LAB_0015a500:
LEA RDX,[RBP + -0x60]
MOV qword ptr [RBP + -0xe0],RDX
MOV R15D,EAX
SUB R15D,EDX
MOV qword ptr [RBP + -0xd8],R15
TEST R11D,R11D
JZ 0x0015a59c
LEA R8D,[RSI + R11*0x1]
MOV EDX,R12D
SUB EDX,R11D
NEG R11D
SUB R12D,ESI
XOR R15D,R15D
CMP R8D,dword ptr [R14 + 0x7c0]
SETNC R15B
LEA R8D,[R15 + R15*0x4 + 0x2]
CMOVC R12D,R11D
CMOVNC EDX,ESI
MOV byte ptr [RAX],R8B
MOV word ptr [RAX + 0x1],R12W
MOV ESI,R9D
SHL ESI,0x4
MOV qword ptr [RBP + RSI*0x1 + -0x100],RAX
MOV qword ptr [RBP + RSI*0x1 + -0xf8],0x3
INC R9D
ADD RAX,0x3
MOV R8D,0x3
MOV R15D,R10D
JMP 0x0015a5a2
LAB_0015a57b:
LEA RSI,[RBP + -0x60]
MOV qword ptr [RBP + -0xe0],RSI
MOV qword ptr [RBP + -0xd8],0xf
MOV R9D,0x4
XOR R8D,R8D
JMP 0x0015a5a2
LAB_0015a59c:
MOV R15D,R10D
MOV EDX,R12D
LAB_0015a5a2:
MOV R10D,dword ptr [RDI + 0x20]
CMP EDX,R10D
JZ 0x0015a607
MOV ESI,dword ptr [R14 + 0x7c0]
CMP EDX,ESI
JZ 0x0015a607
CMP R10D,ESI
CMOVC ESI,R10D
MOV R10D,ESI
SUB R10D,EDX
MOV EDX,EDX
ADD RBX,RDX
MOV byte ptr [RAX],0x6
MOV word ptr [RAX + 0x1],R10W
MOV EDX,R9D
SHL EDX,0x4
MOV qword ptr [RBP + RDX*0x1 + -0x100],RAX
MOV qword ptr [RBP + RDX*0x1 + -0xf8],0x3
MOV qword ptr [RBP + RDX*0x1 + -0xf0],RBX
MOV qword ptr [RBP + RDX*0x1 + -0xe8],R10
ADD R9D,0x2
ADD R8D,R10D
ADD R8D,0x3
MOV EDX,ESI
LAB_0015a607:
ADD R8D,R15D
MOV dword ptr [RDI + 0x24],EDX
MOV RDX,qword ptr [RCX + 0x8]
LEA RAX,[RBP + -0x100]
ADD R8D,dword ptr [RAX + 0x28]
SUB RSP,0x8
LEA R10,[RBP + -0x60]
LEA RDI,[RBP + -0x68]
MOV ESI,0xc
PUSH 0x0
PUSH R10
PUSH RAX
CALL 0x00129c84
ADD RSP,0x20
TEST AL,AL
SETNZ AL
MOV RCX,qword ptr FS:[0x28]
CMP RCX,qword ptr [RBP + -0x30]
JNZ 0x0015a661
ADD RSP,0xd8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0015a661:
CALL 0x00129260
|
bool _ma_log_delete(long *param_1,long param_2,uint param_3,int param_4)
{
uint uVar1;
long *plVar2;
long lVar3;
long lVar4;
int1 auVar5 [16];
char cVar6;
char *pcVar7;
uint uVar8;
uint uVar9;
ulong uVar10;
int iVar11;
int iVar12;
short sVar13;
uint uVar14;
long in_FS_OFFSET;
bool bVar15;
long local_108 [4];
int1 *local_e8;
ulong local_e0;
long local_d8 [13];
int1 local_70 [8];
int1 local_68 [2];
int4 local_66;
int1 local_62;
int1 local_61;
int1 local_60;
int1 local_5f;
int2 local_5e;
char local_5c;
int2 local_5b;
char local_59 [33];
long local_38;
local_38 = *(long *)(in_FS_OFFSET + 0x28);
plVar2 = (long *)*param_1;
lVar3 = param_1[2];
uVar10 = param_2 - lVar3;
uVar14 = (uint)uVar10;
lVar4 = *plVar2;
iVar11 = 0;
auVar5._8_8_ = 0;
auVar5._0_8_ = param_1[3];
auVar5 = auVar5 / ZEXT416(*(uint *)(lVar4 + 0x7bc));
local_66 = auVar5._0_4_;
local_62 = auVar5[4];
uVar9 = *(uint *)((long)param_1 + 0x24);
local_61 = 10;
local_60 = *(int1 *)(lVar3 + (ulong)(*(int *)(lVar4 + 0x744) - 3));
local_5f = 1;
local_5e = (int2)uVar10;
if (param_3 == 0) {
pcVar7 = &local_5c;
iVar12 = 3;
}
else {
uVar8 = *(uint *)(lVar4 + 0x7c0);
local_d8[1] = (long)(uVar8 - uVar14);
if (uVar14 + param_3 < uVar8) {
local_d8[1] = (long)param_3;
}
local_d8[0] = (uVar10 & 0xffffffff) + lVar3;
pcVar7 = local_59;
local_5c = '\x03';
local_5b = (int2)local_d8[1];
if (uVar8 <= uVar14 + param_3) {
local_e0 = 0xf;
iVar12 = 4;
iVar11 = 0;
uVar9 = uVar8;
param_3 = uVar8 - uVar14;
goto LAB_0015a5a2;
}
uVar14 = (int)local_d8[1] + uVar14;
iVar12 = 4;
}
local_e0 = (ulong)(uint)((int)pcVar7 - (int)local_68);
if (param_4 != 0) {
uVar8 = uVar9 - param_4;
sVar13 = -(short)param_4;
bVar15 = *(uint *)(lVar4 + 0x7c0) <= uVar14 + param_4;
if (bVar15) {
uVar8 = uVar14;
sVar13 = (short)uVar9 - (short)uVar14;
}
*pcVar7 = bVar15 * '\x05' + '\x02';
*(short *)(pcVar7 + 1) = sVar13;
*(char **)((long)local_108 + (ulong)(uint)(iVar12 << 4)) = pcVar7;
*(int8 *)((long)local_108 + (ulong)(uint)(iVar12 << 4) + 8) = 3;
iVar12 = iVar12 + 1;
pcVar7 = pcVar7 + 3;
iVar11 = 3;
uVar9 = uVar8;
}
LAB_0015a5a2:
local_e8 = local_68;
uVar14 = *(uint *)(param_1 + 4);
uVar8 = uVar9;
if ((uVar9 != uVar14) && (uVar1 = *(uint *)(lVar4 + 0x7c0), uVar9 != uVar1)) {
uVar8 = uVar1;
if (uVar14 < uVar1) {
uVar8 = uVar14;
}
uVar14 = uVar8 - uVar9;
*pcVar7 = '\x06';
*(short *)(pcVar7 + 1) = (short)uVar14;
uVar10 = (ulong)(uint)(iVar12 << 4);
*(char **)((long)local_108 + uVar10) = pcVar7;
*(int8 *)((long)local_108 + uVar10 + 8) = 3;
*(ulong *)((long)local_108 + uVar10 + 0x10) = lVar3 + (ulong)uVar9;
*(ulong *)((long)local_108 + uVar10 + 0x18) = (ulong)uVar14;
iVar12 = iVar12 + 2;
iVar11 = iVar11 + uVar14 + 3;
}
*(uint *)((long)param_1 + 0x24) = uVar8;
cVar6 = translog_write_record
(local_70,0xc,plVar2[1],plVar2,iVar11 + param_3 + (int)local_e0,iVar12,local_108
,local_68,0);
if (*(long *)(in_FS_OFFSET + 0x28) == local_38) {
return cVar6 != '\0';
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
22,191 | get_length_arg | eloqsql/strings/my_vsnprintf.c | static const char *get_length_arg(const char *fmt, ARGS_INFO *args_arr,
size_t *arg_count, size_t *length, uint *flags)
{
fmt= get_length(fmt+1, length, flags);
*arg_count= MY_MAX(*arg_count, *length);
(*length)--;
DBUG_ASSERT(*fmt == '$' && *length < MAX_ARGS);
args_arr[*length].arg_type= 'd';
args_arr[*length].have_longlong= 0;
return fmt+1;
} | O0 | c | get_length_arg:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq -0x8(%rbp), %rdi
addq $0x1, %rdi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
callq 0x732a0
movq %rax, -0x8(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq -0x20(%rbp), %rcx
cmpq (%rcx), %rax
jbe 0x750b2
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0x750bd
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movq -0x20(%rbp), %rax
movq (%rax), %rcx
addq $-0x1, %rcx
movq %rcx, (%rax)
jmp 0x750d8
movq -0x10(%rbp), %rax
movq -0x20(%rbp), %rcx
movq (%rcx), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movb $0x64, (%rax)
movq -0x10(%rbp), %rax
movq -0x20(%rbp), %rcx
movq (%rcx), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movl $0x0, 0x4(%rax)
movq -0x8(%rbp), %rax
addq $0x1, %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| get_length_arg:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov [rbp+var_28], r8
mov rdi, [rbp+var_8]
add rdi, 1
mov rsi, [rbp+var_20]
mov rdx, [rbp+var_28]
call get_length
mov [rbp+var_8], rax
mov rax, [rbp+var_18]
mov rax, [rax]
mov rcx, [rbp+var_20]
cmp rax, [rcx]
jbe short loc_750B2
mov rax, [rbp+var_18]
mov rax, [rax]
mov [rbp+var_30], rax
jmp short loc_750BD
loc_750B2:
mov rax, [rbp+var_20]
mov rax, [rax]
mov [rbp+var_30], rax
loc_750BD:
mov rcx, [rbp+var_30]
mov rax, [rbp+var_18]
mov [rax], rcx
mov rax, [rbp+var_20]
mov rcx, [rax]
add rcx, 0FFFFFFFFFFFFFFFFh
mov [rax], rcx
jmp short $+2
loc_750D8:
mov rax, [rbp+var_10]
mov rcx, [rbp+var_20]
mov rcx, [rcx]
shl rcx, 5
add rax, rcx
mov byte ptr [rax], 64h ; 'd'
mov rax, [rbp+var_10]
mov rcx, [rbp+var_20]
mov rcx, [rcx]
shl rcx, 5
add rax, rcx
mov dword ptr [rax+4], 0
mov rax, [rbp+var_8]
add rax, 1
add rsp, 30h
pop rbp
retn
| unsigned __int8 * get_length_arg(long long a1, long long a2, long long *a3, long long *a4, _DWORD *a5)
{
long long v6; // [rsp+0h] [rbp-30h]
unsigned __int8 *length; // [rsp+28h] [rbp-8h]
length = get_length((unsigned __int8 *)(a1 + 1), a4, a5);
if ( *a3 <= (unsigned long long)*a4 )
v6 = *a4;
else
v6 = *a3;
*a3 = v6;
--*a4;
*(_BYTE *)(32 * *a4 + a2) = 100;
*(_DWORD *)(32 * *a4 + a2 + 4) = 0;
return length + 1;
}
| get_length_arg:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV qword ptr [RBP + -0x28],R8
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x1
MOV RSI,qword ptr [RBP + -0x20]
MOV RDX,qword ptr [RBP + -0x28]
CALL 0x001732a0
MOV qword ptr [RBP + -0x8],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV RCX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RCX]
JBE 0x001750b2
MOV RAX,qword ptr [RBP + -0x18]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x30],RAX
JMP 0x001750bd
LAB_001750b2:
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x30],RAX
LAB_001750bd:
MOV RCX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RAX]
ADD RCX,-0x1
MOV qword ptr [RAX],RCX
JMP 0x001750d8
LAB_001750d8:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RCX]
SHL RCX,0x5
ADD RAX,RCX
MOV byte ptr [RAX],0x64
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RCX]
SHL RCX,0x5
ADD RAX,RCX
MOV dword ptr [RAX + 0x4],0x0
MOV RAX,qword ptr [RBP + -0x8]
ADD RAX,0x1
ADD RSP,0x30
POP RBP
RET
|
long get_length_arg(long param_1,long param_2,ulong *param_3,ulong *param_4,int8 param_5)
{
long lVar1;
int8 local_38;
lVar1 = get_length(param_1 + 1,param_4,param_5);
if (*param_4 < *param_3) {
local_38 = *param_3;
}
else {
local_38 = *param_4;
}
*param_3 = local_38;
*param_4 = *param_4 - 1;
*(int1 *)(param_2 + *param_4 * 0x20) = 100;
*(int4 *)(param_2 + *param_4 * 0x20 + 4) = 0;
return lVar1 + 1;
}
| |
22,192 | end_simple_key_cache | eloqsql/mysys/mf_keycache.c | static
void end_simple_key_cache(SIMPLE_KEY_CACHE_CB *keycache, my_bool cleanup)
{
DBUG_ENTER("end_simple_key_cache");
DBUG_PRINT("enter", ("key_cache: %p", keycache));
if (!keycache->key_cache_inited)
DBUG_VOID_RETURN;
if (keycache->disk_blocks > 0)
{
if (keycache->block_mem)
{
my_large_free((uchar*) keycache->block_mem, keycache->allocated_mem_size);
keycache->block_mem= NULL;
my_free(keycache->block_root);
keycache->block_root= NULL;
}
keycache->disk_blocks= -1;
/* Reset blocks_changed to be safe if flush_all_key_blocks is called */
keycache->blocks_changed= 0;
}
DBUG_PRINT("status", ("used: %lu changed: %lu w_requests: %lu "
"writes: %lu r_requests: %lu reads: %lu",
keycache->blocks_used, keycache->global_blocks_changed,
(ulong) keycache->global_cache_w_requests,
(ulong) keycache->global_cache_write,
(ulong) keycache->global_cache_r_requests,
(ulong) keycache->global_cache_read));
/*
Reset these values to be able to detect a disabled key cache.
See Bug#44068 (RESTORE can disable the MyISAM Key Cache).
*/
keycache->blocks_used= 0;
keycache->blocks_unused= 0;
if (cleanup)
{
mysql_mutex_destroy(&keycache->cache_lock);
keycache->key_cache_inited= keycache->can_be_used= 0;
KEYCACHE_DEBUG_CLOSE;
}
DBUG_VOID_RETURN;
} | O3 | c | end_simple_key_cache:
cmpb $0x0, (%rdi)
je 0x57b42
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %r14d
movq %rdi, %rbx
cmpl $0x0, 0x48(%rdi)
jle 0x57af2
movq 0xa8(%rbx), %rdi
testq %rdi, %rdi
je 0x57ae3
movq 0x10(%rbx), %rsi
callq 0x63443
xorl %r15d, %r15d
movq %r15, 0xa8(%rbx)
movq 0xa0(%rbx), %rdi
callq 0x5d26a
movq %r15, 0xa0(%rbx)
movl $0xffffffff, 0x48(%rbx) # imm = 0xFFFFFFFF
movq $0x0, 0x60(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x50(%rbx)
testb %r14b, %r14b
je 0x57b38
leaq 0xc0(%rbx), %r14
movq 0x100(%rbx), %rdi
testq %rdi, %rdi
je 0x57b29
leaq 0x2dc348(%rip), %rax # 0x333e60
movq (%rax), %rax
callq *0x48(%rax)
movq $0x0, 0x100(%rbx)
movq %r14, %rdi
callq 0x28430
xorl %eax, %eax
movb %al, 0x3(%rbx)
movb %al, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| end_simple_key_cache:
cmp byte ptr [rdi], 0
jz locret_57B42
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov r14d, esi
mov rbx, rdi
cmp dword ptr [rdi+48h], 0
jle short loc_57AF2
mov rdi, [rbx+0A8h]
test rdi, rdi
jz short loc_57AE3
mov rsi, [rbx+10h]
call my_large_free
xor r15d, r15d
mov [rbx+0A8h], r15
mov rdi, [rbx+0A0h]
call my_free
mov [rbx+0A0h], r15
loc_57AE3:
mov dword ptr [rbx+48h], 0FFFFFFFFh
mov qword ptr [rbx+60h], 0
loc_57AF2:
xorps xmm0, xmm0
movups xmmword ptr [rbx+50h], xmm0
test r14b, r14b
jz short loc_57B38
lea r14, [rbx+0C0h]
mov rdi, [rbx+100h]
test rdi, rdi
jz short loc_57B29
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+48h]
mov qword ptr [rbx+100h], 0
loc_57B29:
mov rdi, r14
call _pthread_mutex_destroy
xor eax, eax
mov [rbx+3], al
mov [rbx], al
loc_57B38:
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
locret_57B42:
retn
| long long end_simple_key_cache(long long a1, char a2)
{
long long v3; // rdi
long long result; // rax
long long v5; // rdi
if ( *(_BYTE *)a1 )
{
if ( *(int *)(a1 + 72) > 0 )
{
v3 = *(_QWORD *)(a1 + 168);
if ( v3 )
{
my_large_free(v3, *(_QWORD *)(a1 + 16));
*(_QWORD *)(a1 + 168) = 0LL;
result = my_free(*(_QWORD *)(a1 + 160));
*(_QWORD *)(a1 + 160) = 0LL;
}
*(_DWORD *)(a1 + 72) = -1;
*(_QWORD *)(a1 + 96) = 0LL;
}
*(_OWORD *)(a1 + 80) = 0LL;
if ( a2 )
{
v5 = *(_QWORD *)(a1 + 256);
if ( v5 )
{
((void ( *)(long long))PSI_server[9])(v5);
*(_QWORD *)(a1 + 256) = 0LL;
}
pthread_mutex_destroy(a1 + 192);
result = 0LL;
*(_BYTE *)(a1 + 3) = 0;
*(_BYTE *)a1 = 0;
}
}
return result;
}
| end_simple_key_cache:
CMP byte ptr [RDI],0x0
JZ 0x00157b42
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV R14D,ESI
MOV RBX,RDI
CMP dword ptr [RDI + 0x48],0x0
JLE 0x00157af2
MOV RDI,qword ptr [RBX + 0xa8]
TEST RDI,RDI
JZ 0x00157ae3
MOV RSI,qword ptr [RBX + 0x10]
CALL 0x00163443
XOR R15D,R15D
MOV qword ptr [RBX + 0xa8],R15
MOV RDI,qword ptr [RBX + 0xa0]
CALL 0x0015d26a
MOV qword ptr [RBX + 0xa0],R15
LAB_00157ae3:
MOV dword ptr [RBX + 0x48],0xffffffff
MOV qword ptr [RBX + 0x60],0x0
LAB_00157af2:
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x50],XMM0
TEST R14B,R14B
JZ 0x00157b38
LEA R14,[RBX + 0xc0]
MOV RDI,qword ptr [RBX + 0x100]
TEST RDI,RDI
JZ 0x00157b29
LEA RAX,[0x433e60]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x48]
MOV qword ptr [RBX + 0x100],0x0
LAB_00157b29:
MOV RDI,R14
CALL 0x00128430
XOR EAX,EAX
MOV byte ptr [RBX + 0x3],AL
MOV byte ptr [RBX],AL
LAB_00157b38:
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
LAB_00157b42:
RET
|
void end_simple_key_cache(char *param_1,char param_2)
{
if (*param_1 != '\0') {
if (0 < *(int *)(param_1 + 0x48)) {
if (*(long *)(param_1 + 0xa8) != 0) {
my_large_free(*(long *)(param_1 + 0xa8),*(int8 *)(param_1 + 0x10));
param_1[0xa8] = '\0';
param_1[0xa9] = '\0';
param_1[0xaa] = '\0';
param_1[0xab] = '\0';
param_1[0xac] = '\0';
param_1[0xad] = '\0';
param_1[0xae] = '\0';
param_1[0xaf] = '\0';
my_free(*(int8 *)(param_1 + 0xa0));
param_1[0xa0] = '\0';
param_1[0xa1] = '\0';
param_1[0xa2] = '\0';
param_1[0xa3] = '\0';
param_1[0xa4] = '\0';
param_1[0xa5] = '\0';
param_1[0xa6] = '\0';
param_1[0xa7] = '\0';
}
param_1[0x48] = -1;
param_1[0x49] = -1;
param_1[0x4a] = -1;
param_1[0x4b] = -1;
param_1[0x60] = '\0';
param_1[0x61] = '\0';
param_1[0x62] = '\0';
param_1[99] = '\0';
param_1[100] = '\0';
param_1[0x65] = '\0';
param_1[0x66] = '\0';
param_1[0x67] = '\0';
}
param_1[0x50] = '\0';
param_1[0x51] = '\0';
param_1[0x52] = '\0';
param_1[0x53] = '\0';
param_1[0x54] = '\0';
param_1[0x55] = '\0';
param_1[0x56] = '\0';
param_1[0x57] = '\0';
param_1[0x58] = '\0';
param_1[0x59] = '\0';
param_1[0x5a] = '\0';
param_1[0x5b] = '\0';
param_1[0x5c] = '\0';
param_1[0x5d] = '\0';
param_1[0x5e] = '\0';
param_1[0x5f] = '\0';
if (param_2 != '\0') {
if (*(long *)(param_1 + 0x100) != 0) {
(**(code **)(PSI_server + 0x48))();
param_1[0x100] = '\0';
param_1[0x101] = '\0';
param_1[0x102] = '\0';
param_1[0x103] = '\0';
param_1[0x104] = '\0';
param_1[0x105] = '\0';
param_1[0x106] = '\0';
param_1[0x107] = '\0';
}
pthread_mutex_destroy((pthread_mutex_t *)(param_1 + 0xc0));
param_1[3] = '\0';
*param_1 = '\0';
}
}
return;
}
| |
22,193 | test_if_hard_path | eloqsql/mysys/my_getwd.c | int test_if_hard_path(register const char *dir_name)
{
if (dir_name[0] == FN_HOMELIB && dir_name[1] == FN_LIBCHAR)
return (home_dir != NullS && test_if_hard_path(home_dir));
if (dir_name[0] == FN_LIBCHAR)
return (TRUE);
#ifdef FN_DEVCHAR
return (strchr(dir_name,FN_DEVCHAR) != 0);
#else
return FALSE;
#endif
} | O3 | c | test_if_hard_path:
pushq %rbp
movq %rsp, %rbp
leaq 0xb69177(%rip), %rax # 0xc078d8
movq (%rax), %rax
movb (%rdi), %cl
cmpb $0x7e, %cl
jne 0x9e77d
cmpb $0x2f, 0x1(%rdi)
jne 0x9e77d
movq %rax, %rdi
testq %rax, %rax
jne 0x9e764
xorl %eax, %eax
jmp 0x9e785
xorl %eax, %eax
cmpb $0x2f, %cl
sete %al
popq %rbp
retq
| test_if_hard_path:
push rbp
mov rbp, rsp
lea rax, home_dir
mov rax, [rax]
loc_9E764:
mov cl, [rdi]
cmp cl, 7Eh ; '~'
jnz short loc_9E77D
cmp byte ptr [rdi+1], 2Fh ; '/'
jnz short loc_9E77D
mov rdi, rax
test rax, rax
jnz short loc_9E764
xor eax, eax
jmp short loc_9E785
loc_9E77D:
xor eax, eax
cmp cl, 2Fh ; '/'
setz al
loc_9E785:
pop rbp
retn
| _BOOL8 test_if_hard_path(_BYTE *a1)
{
while ( *a1 == 126 && a1[1] == 47 )
{
a1 = (_BYTE *)home_dir;
if ( !home_dir )
return 0LL;
}
return *a1 == 47;
}
| test_if_hard_path:
PUSH RBP
MOV RBP,RSP
LEA RAX,[0xd078d8]
MOV RAX,qword ptr [RAX]
LAB_0019e764:
MOV CL,byte ptr [RDI]
CMP CL,0x7e
JNZ 0x0019e77d
CMP byte ptr [RDI + 0x1],0x2f
JNZ 0x0019e77d
MOV RDI,RAX
TEST RAX,RAX
JNZ 0x0019e764
XOR EAX,EAX
JMP 0x0019e785
LAB_0019e77d:
XOR EAX,EAX
CMP CL,0x2f
SETZ AL
LAB_0019e785:
POP RBP
RET
|
bool test_if_hard_path(char *param_1)
{
while ((*param_1 == '~' && (param_1[1] == '/'))) {
param_1 = home_dir;
if (home_dir == (char *)0x0) {
return false;
}
}
return *param_1 == '/';
}
| |
22,194 | StartTree::BoundingMatrix<float, StartTree::NJMatrix<float>>::cluster(unsigned long, unsigned long) | iqtree3/utils/bionj2.cpp | virtual void cluster(size_t a, size_t b) {
size_t clusterA = rowToCluster[a];
size_t clusterB = rowToCluster[b];
size_t clusterMoved = rowToCluster[n-1];
clusterToRow[clusterA] = notMappedToRow;
clusterTotals[clusterA] = -infiniteDistance;
clusterToRow[clusterB] = notMappedToRow;
clusterTotals[clusterB] = -infiniteDistance;
size_t clusterC = clusters.size(); //cluster # of new cluster
super::cluster(a,b);
if (b<n) {
clusterToRow[clusterMoved] = static_cast<int>(b);
}
clusterToRow.emplace_back(a);
clusterTotals.emplace_back(rowTotals[a]);
scaledClusterTotals.emplace_back(rowTotals[a] / (T)( n - 1.0 ) );
scaledMaxEarlierClusterTotal.emplace_back(0.0);
//Mirror row rearrangement done on the D (distance) matrix
//(and possibly also on the V (variance estimate) matrix),
//onto the S and I matrices.
entriesSorted.removeRowOnly(b);
entryToCluster.removeRowOnly(b);
//Recalculate cluster totals.
for (size_t wipe = 0; wipe<clusterC; ++wipe) {
clusterTotals[wipe] = -infiniteDistance;
//A trick. This way we don't need to check if clusters
//are still "live" in the inner loop of getRowMinimum().
//When we are "subtracting" cluster totals to calculate
//entries in Q, they will come out so big they won't be
//considered as candidates for neighbour join.
//If we didn't do this we'd have to check, all the time,
//when calculating entries in Q, if clusters are still
//"live" (have corresponding rows in the D matrix).
}
for (size_t r = 0; r<n; ++r) {
size_t cluster = rowToCluster[r];
clusterTotals[cluster] = rowTotals[r];
}
sortRow(a, clusterC);
} | O3 | cpp | StartTree::BoundingMatrix<float, StartTree::NJMatrix<float>>::cluster(unsigned long, unsigned long):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq %rsi, 0x10(%rsp)
movq 0x8(%rdi), %rax
movq 0x30(%rdi), %rcx
movq (%rcx,%rsi,8), %rdx
movq (%rcx,%r14,8), %rsi
movq -0x8(%rcx,%rax,8), %rax
movq %rax, 0x20(%rsp)
leaq 0xc8(%rdi), %r12
movq 0xc8(%rdi), %rax
movl $0xffffffff, %ecx # imm = 0xFFFFFFFF
movl %ecx, (%rax,%rdx,4)
movq 0xe0(%rdi), %rdi
movabsq $-0x3897ed0640000000, %r13 # imm = 0xC76812F9C0000000
movq %r13, (%rdi,%rdx,8)
movl %ecx, (%rax,%rsi,4)
movq %r13, (%rdi,%rsi,8)
movq 0x48(%rbx), %rbp
movq 0x50(%rbx), %rax
movq %rax, 0x18(%rsp)
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x25ae8
cmpq %r14, 0x8(%rbx)
jbe 0x252b2
movq (%r12), %rax
movq 0x20(%rsp), %rcx
movl %r14d, (%rax,%rcx,4)
movq 0xd0(%rbx), %rsi
cmpq 0xd8(%rbx), %rsi
je 0x252d2
movl %r15d, (%rsi)
addq $0x4, %rsi
movq %rsi, 0xd0(%rbx)
jmp 0x252e5
leaq 0x10(%rsp), %r15
movq %r12, %rdi
movq %r15, %rdx
callq 0x1f7c4
movq (%r15), %r15
shlq $0x3, %r15
addq 0x28(%rbx), %r15
leaq 0xe0(%rbx), %r12
movq 0xe8(%rbx), %rsi
cmpq 0xf0(%rbx), %rsi
je 0x2531a
movsd (%r15), %xmm0
movsd %xmm0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0xe8(%rbx)
jmp 0x25333
movq %r12, %rdi
movq %r15, %rdx
callq 0x27cb8
movq 0x28(%rbx), %rax
movq 0x10(%rsp), %rcx
movsd (%rax,%rcx,8), %xmm0
movsd 0x8(%rbx), %xmm1
unpcklps 0x6381(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1]
subpd 0x6389(%rip), %xmm1 # 0x2b6d0
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2 # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
addsd 0x6435(%rip), %xmm2 # 0x2b790
divsd %xmm2, %xmm0
movsd %xmm0, 0x8(%rsp)
movq 0x100(%rbx), %rsi
cmpq 0x108(%rbx), %rsi
je 0x25386
movsd %xmm0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x100(%rbx)
jmp 0x25397
leaq 0xf8(%rbx), %rdi
leaq 0x8(%rsp), %rdx
callq 0x27d98
movq 0x18(%rsp), %r15
subq %rbp, %r15
movq $0x0, 0x8(%rsp)
movq 0x118(%rbx), %rsi
cmpq 0x120(%rbx), %rsi
je 0x253cc
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x118(%rbx)
jmp 0x253dd
leaq 0x110(%rbx), %rdi
leaq 0x8(%rsp), %rdx
callq 0x27d98
sarq $0x6, %r15
movq 0x170(%rbx), %rax
movq 0x190(%rbx), %rcx
movq -0x8(%rcx,%rax,8), %xmm0
movq %xmm0, (%rcx,%r14,8)
movq 0x188(%rbx), %rcx
movq -0x8(%rcx,%rax,8), %rdx
movq %rdx, (%rcx,%r14,8)
movq 0x188(%rbx), %rcx
xorl %edx, %edx
movq %rdx, -0x8(%rcx,%rax,8)
decq %rax
movq %rax, 0x170(%rbx)
movq 0x1a0(%rbx), %rax
movq 0x1c0(%rbx), %rcx
movl -0x4(%rcx,%rax,4), %esi
movl %esi, (%rcx,%r14,4)
movq 0x1b8(%rbx), %rcx
movq -0x8(%rcx,%rax,8), %rsi
movq %rsi, (%rcx,%r14,8)
movq 0x1b8(%rbx), %rcx
movq %rdx, -0x8(%rcx,%rax,8)
decq %rax
movq %rax, 0x1a0(%rbx)
cmpq %rbp, 0x18(%rsp)
je 0x25507
cmpq $0x1, %r15
movq %r15, %rdx
adcq $0x0, %rdx
movq (%r12), %rax
leaq 0x1(%rdx), %rcx
andq $-0x2, %rcx
decq %rdx
movq %rdx, %xmm0
pshufd $0x44, %xmm0, %xmm0 # xmm0 = xmm0[0,1,0,1]
movdqa 0x624a(%rip), %xmm1 # 0x2b6e0
xorl %edx, %edx
movdqa 0x6050(%rip), %xmm2 # 0x2b4f0
pxor %xmm2, %xmm0
pcmpeqd %xmm3, %xmm3
movdqa 0x6290(%rip), %xmm4 # 0x2b740
movdqa %xmm1, %xmm5
pxor %xmm2, %xmm5
movdqa %xmm5, %xmm6
pcmpgtd %xmm0, %xmm6
pcmpeqd %xmm0, %xmm5
pshufd $0xf5, %xmm5, %xmm7 # xmm7 = xmm5[1,1,3,3]
pand %xmm6, %xmm7
pshufd $0xf5, %xmm6, %xmm5 # xmm5 = xmm6[1,1,3,3]
por %xmm7, %xmm5
movd %xmm5, %esi
notl %esi
testb $0x1, %sil
je 0x254e6
movq %r13, (%rax,%rdx,8)
pxor %xmm3, %xmm5
pextrw $0x4, %xmm5, %esi
testb $0x1, %sil
je 0x254fa
movq %r13, 0x8(%rax,%rdx,8)
addq $0x2, %rdx
paddq %xmm4, %xmm1
cmpq %rdx, %rcx
jne 0x254b0
movq 0x8(%rbx), %rax
testq %rax, %rax
je 0x25538
movq 0x28(%rbx), %rcx
movq 0x30(%rbx), %rdx
movq 0xe0(%rbx), %rsi
xorl %edi, %edi
movq (%rdx,%rdi,8), %r8
movq (%rcx,%rdi,8), %xmm0
movq %xmm0, (%rsi,%r8,8)
incq %rdi
cmpq %rdi, %rax
jne 0x25521
movq 0x10(%rsp), %rsi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x273fa
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
| _ZN9StartTree14BoundingMatrixIdNS_11BIONJMatrixIdEEE7clusterEmm:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r14, rdx
mov r15, rsi
mov rbx, rdi
mov [rsp+58h+var_48], rsi
mov rax, [rdi+8]
mov rcx, [rdi+30h]
mov rdx, [rcx+rsi*8]
mov rsi, [rcx+r14*8]
mov rax, [rcx+rax*8-8]
mov [rsp+58h+var_38], rax
lea r12, [rdi+0C8h]
mov rax, [rdi+0C8h]
mov ecx, 0FFFFFFFFh
mov [rax+rdx*4], ecx
mov rdi, [rdi+0E0h]
mov r13, 0C76812F9C0000000h
mov [rdi+rdx*8], r13
mov [rax+rsi*4], ecx
mov [rdi+rsi*8], r13
mov rbp, [rbx+48h]
mov rax, [rbx+50h]
mov [rsp+58h+var_40], rax
mov rdi, rbx
mov rsi, r15
mov rdx, r14
call _ZN9StartTree11BIONJMatrixIdE7clusterEmm; StartTree::BIONJMatrix<double>::cluster(ulong,ulong)
cmp [rbx+8], r14
jbe short loc_252B2
mov rax, [r12]
mov rcx, [rsp+58h+var_38]
mov [rax+rcx*4], r14d
loc_252B2:
mov rsi, [rbx+0D0h]
cmp rsi, [rbx+0D8h]
jz short loc_252D2
mov [rsi], r15d
add rsi, 4
mov [rbx+0D0h], rsi
jmp short loc_252E5
loc_252D2:
lea r15, [rsp+58h+var_48]
mov rdi, r12
mov rdx, r15
call _ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRmEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_; std::vector<int>::_M_realloc_insert<ulong &>(__gnu_cxx::__normal_iterator<int *,std::vector<int>>,ulong &)
mov r15, [r15]
loc_252E5:
shl r15, 3
add r15, [rbx+28h]
lea r12, [rbx+0E0h]
mov rsi, [rbx+0E8h]
cmp rsi, [rbx+0F0h]
jz short loc_2531A
movsd xmm0, qword ptr [r15]
movsd qword ptr [rsi], xmm0
add rsi, 8
mov [rbx+0E8h], rsi
jmp short loc_25333
loc_2531A:
mov rdi, r12
mov rdx, r15
call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double &>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &)
mov rax, [rbx+28h]
mov rcx, [rsp+58h+var_48]
movsd xmm0, qword ptr [rax+rcx*8]
loc_25333:
movsd xmm1, qword ptr [rbx+8]
unpcklps xmm1, cs:xmmword_2B6C0
subpd xmm1, cs:xmmword_2B6D0
movapd xmm2, xmm1
unpckhpd xmm2, xmm1
addsd xmm2, xmm1
addsd xmm2, cs:qword_2B790
divsd xmm0, xmm2
movsd [rsp+58h+var_50], xmm0
mov rsi, [rbx+100h]
cmp rsi, [rbx+108h]
jz short loc_25386
movsd qword ptr [rsi], xmm0
add rsi, 8
mov [rbx+100h], rsi
jmp short loc_25397
loc_25386:
lea rdi, [rbx+0F8h]
lea rdx, [rsp+58h+var_50]
call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&)
loc_25397:
mov r15, [rsp+58h+var_40]
sub r15, rbp
mov [rsp+58h+var_50], 0
mov rsi, [rbx+118h]
cmp rsi, [rbx+120h]
jz short loc_253CC
mov qword ptr [rsi], 0
add rsi, 8
mov [rbx+118h], rsi
jmp short loc_253DD
loc_253CC:
lea rdi, [rbx+110h]
lea rdx, [rsp+58h+var_50]
call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&)
loc_253DD:
sar r15, 6
mov rax, [rbx+170h]
mov rcx, [rbx+190h]
movq xmm0, qword ptr [rcx+rax*8-8]
movq qword ptr [rcx+r14*8], xmm0
mov rcx, [rbx+188h]
mov rdx, [rcx+rax*8-8]
mov [rcx+r14*8], rdx
mov rcx, [rbx+188h]
xor edx, edx
mov [rcx+rax*8-8], rdx
dec rax
mov [rbx+170h], rax
mov rax, [rbx+1A0h]
mov rcx, [rbx+1C0h]
mov esi, [rcx+rax*4-4]
mov [rcx+r14*4], esi
mov rcx, [rbx+1B8h]
mov rsi, [rcx+rax*8-8]
mov [rcx+r14*8], rsi
mov rcx, [rbx+1B8h]
mov [rcx+rax*8-8], rdx
dec rax
mov [rbx+1A0h], rax
cmp [rsp+58h+var_40], rbp
jz loc_25507
cmp r15, 1
mov rdx, r15
adc rdx, 0
mov rax, [r12]
lea rcx, [rdx+1]
and rcx, 0FFFFFFFFFFFFFFFEh
dec rdx
movq xmm0, rdx
pshufd xmm0, xmm0, 44h ; 'D'
movdqa xmm1, cs:xmmword_2B6E0
xor edx, edx
movdqa xmm2, cs:xmmword_2B4F0
pxor xmm0, xmm2
pcmpeqd xmm3, xmm3
movdqa xmm4, cs:xmmword_2B740
loc_254B0:
movdqa xmm5, xmm1
pxor xmm5, xmm2
movdqa xmm6, xmm5
pcmpgtd xmm6, xmm0
pcmpeqd xmm5, xmm0
pshufd xmm7, xmm5, 0F5h
pand xmm7, xmm6
pshufd xmm5, xmm6, 0F5h
por xmm5, xmm7
movd esi, xmm5
not esi
test sil, 1
jz short loc_254E6
mov [rax+rdx*8], r13
loc_254E6:
pxor xmm5, xmm3
pextrw esi, xmm5, 4
test sil, 1
jz short loc_254FA
mov [rax+rdx*8+8], r13
loc_254FA:
add rdx, 2
paddq xmm1, xmm4
cmp rcx, rdx
jnz short loc_254B0
loc_25507:
mov rax, [rbx+8]
test rax, rax
jz short loc_25538
mov rcx, [rbx+28h]
mov rdx, [rbx+30h]
mov rsi, [rbx+0E0h]
xor edi, edi
loc_25521:
mov r8, [rdx+rdi*8]
movq xmm0, qword ptr [rcx+rdi*8]
movq qword ptr [rsi+r8*8], xmm0
inc rdi
cmp rax, rdi
jnz short loc_25521
loc_25538:
mov rsi, [rsp+58h+var_48]
mov rdi, rbx
mov rdx, r15
call _ZN9StartTree14BoundingMatrixIdNS_11BIONJMatrixIdEEE7sortRowEmm; StartTree::BoundingMatrix<double,StartTree::BIONJMatrix<double>>::sortRow(ulong,ulong)
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long StartTree::BoundingMatrix<double,StartTree::BIONJMatrix<double>>::cluster(
_QWORD *a1,
long long a2,
unsigned long long a3)
{
long long v4; // r15
long long v6; // rcx
long long v7; // rdx
long long v8; // rsi
long long *v9; // r12
long long v10; // rax
long long v11; // rdi
long long v12; // rbp
_DWORD *v13; // rsi
double *v14; // r15
_QWORD *v15; // rsi
double v16; // xmm0_8
__m128d v17; // xmm1
double v18; // xmm0_8
double *v19; // rsi
long long v20; // r15
_QWORD *v21; // rsi
long long v22; // r15
long long v23; // rax
long long v24; // rax
long long v25; // rdx
long long v26; // rax
unsigned long long v27; // rcx
__m128i v28; // xmm0
__m128i si128; // xmm1
long long v30; // rdx
__m128i v31; // xmm2
__m128i v32; // xmm0
__m128i v33; // xmm4
__m128i v34; // xmm5
__m128i v35; // xmm6
__m128i v36; // xmm5
long long v37; // rax
long long v38; // rcx
long long v39; // rdx
long long v40; // rsi
long long i; // rdi
double v43; // [rsp+8h] [rbp-50h] BYREF
long long v44; // [rsp+10h] [rbp-48h] BYREF
long long v45; // [rsp+18h] [rbp-40h]
long long v46; // [rsp+20h] [rbp-38h]
v4 = a2;
v44 = a2;
v6 = a1[6];
v7 = *(_QWORD *)(v6 + 8 * a2);
v8 = *(_QWORD *)(v6 + 8 * a3);
v46 = *(_QWORD *)(v6 + 8LL * a1[1] - 8);
v9 = a1 + 25;
v10 = a1[25];
*(_DWORD *)(v10 + 4 * v7) = -1;
v11 = a1[28];
*(_QWORD *)(v11 + 8 * v7) = 0xC76812F9C0000000LL;
*(_DWORD *)(v10 + 4 * v8) = -1;
*(_QWORD *)(v11 + 8 * v8) = 0xC76812F9C0000000LL;
v12 = a1[9];
v45 = a1[10];
StartTree::BIONJMatrix<double>::cluster(a1, v4, a3);
if ( a1[1] > a3 )
*(_DWORD *)(*v9 + 4 * v46) = a3;
v13 = (_DWORD *)a1[26];
if ( v13 == (_DWORD *)a1[27] )
{
std::vector<int>::_M_realloc_insert<unsigned long &>(v9, (long long)v13, &v44);
v4 = v44;
}
else
{
*v13 = v4;
a1[26] = v13 + 1;
}
v14 = (double *)(a1[5] + 8 * v4);
v15 = (_QWORD *)a1[29];
if ( v15 == (_QWORD *)a1[30] )
{
std::vector<double>::_M_realloc_insert<double &>(a1 + 28, v15, v14);
v16 = *(double *)(a1[5] + 8 * v44);
}
else
{
v16 = *v14;
*v15 = *(_QWORD *)v14;
a1[29] = v15 + 1;
}
v17 = _mm_sub_pd(
(__m128d)_mm_unpacklo_ps((__m128)(unsigned long long)a1[1], (__m128)xmmword_2B6C0),
(__m128d)xmmword_2B6D0);
v18 = v16 / (_mm_unpackhi_pd(v17, v17).m128d_f64[0] + v17.m128d_f64[0] + -1.0);
v43 = v18;
v19 = (double *)a1[32];
if ( v19 == (double *)a1[33] )
{
std::vector<double>::_M_realloc_insert<double>(a1 + 31, v19, &v43);
}
else
{
*v19 = v18;
a1[32] = v19 + 1;
}
v20 = v45 - v12;
v43 = 0.0;
v21 = (_QWORD *)a1[35];
if ( v21 == (_QWORD *)a1[36] )
{
std::vector<double>::_M_realloc_insert<double>(a1 + 34, v21, &v43);
}
else
{
*v21 = 0LL;
a1[35] = v21 + 1;
}
v22 = v20 >> 6;
v23 = a1[46];
*(_QWORD *)(a1[50] + 8 * a3) = *(_QWORD *)(a1[50] + 8 * v23 - 8);
*(_QWORD *)(a1[49] + 8 * a3) = *(_QWORD *)(a1[49] + 8 * v23 - 8);
*(_QWORD *)(a1[49] + 8 * v23 - 8) = 0LL;
a1[46] = v23 - 1;
v24 = a1[52];
*(_DWORD *)(a1[56] + 4 * a3) = *(_DWORD *)(a1[56] + 4 * v24 - 4);
*(_QWORD *)(a1[55] + 8 * a3) = *(_QWORD *)(a1[55] + 8 * v24 - 8);
*(_QWORD *)(a1[55] + 8 * v24 - 8) = 0LL;
a1[52] = v24 - 1;
if ( v45 != v12 )
{
v25 = (v22 == 0) + v22;
v26 = a1[28];
v27 = (v25 + 1) & 0xFFFFFFFFFFFFFFFELL;
v28 = _mm_shuffle_epi32((__m128i)(unsigned long long)(v25 - 1), 68);
si128 = _mm_load_si128((const __m128i *)&xmmword_2B6E0);
v30 = 0LL;
v31 = _mm_load_si128(xmmword_2B4F0);
v32 = _mm_xor_si128(v28, v31);
v33 = _mm_load_si128((const __m128i *)&xmmword_2B740);
do
{
v34 = _mm_xor_si128(si128, v31);
v35 = _mm_cmpgt_epi32(v34, v32);
v36 = _mm_or_si128(
_mm_shuffle_epi32(v35, 245),
_mm_and_si128(_mm_shuffle_epi32(_mm_cmpeq_epi32(v34, v32), 245), v35));
if ( (~_mm_cvtsi128_si32(v36) & 1) != 0 )
*(_QWORD *)(v26 + 8 * v30) = 0xC76812F9C0000000LL;
if ( (_mm_extract_epi16(_mm_xor_si128(v36, (__m128i)-1LL), 4) & 1) != 0 )
*(_QWORD *)(v26 + 8 * v30 + 8) = 0xC76812F9C0000000LL;
v30 += 2LL;
si128 = _mm_add_epi64(si128, v33);
}
while ( v27 != v30 );
}
v37 = a1[1];
if ( v37 )
{
v38 = a1[5];
v39 = a1[6];
v40 = a1[28];
for ( i = 0LL; i != v37; ++i )
*(_QWORD *)(v40 + 8LL * *(_QWORD *)(v39 + 8 * i)) = *(_QWORD *)(v38 + 8 * i);
}
return StartTree::BoundingMatrix<double,StartTree::BIONJMatrix<double>>::sortRow(a1, v44, v22);
}
| cluster:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
MOV qword ptr [RSP + 0x10],RSI
MOV RAX,qword ptr [RDI + 0x8]
MOV RCX,qword ptr [RDI + 0x30]
MOV RDX,qword ptr [RCX + RSI*0x8]
MOV RSI,qword ptr [RCX + R14*0x8]
MOV RAX,qword ptr [RCX + RAX*0x8 + -0x8]
MOV qword ptr [RSP + 0x20],RAX
LEA R12,[RDI + 0xc8]
MOV RAX,qword ptr [RDI + 0xc8]
MOV ECX,0xffffffff
MOV dword ptr [RAX + RDX*0x4],ECX
MOV RDI,qword ptr [RDI + 0xe0]
MOV R13,-0x3897ed0640000000
MOV qword ptr [RDI + RDX*0x8],R13
MOV dword ptr [RAX + RSI*0x4],ECX
MOV qword ptr [RDI + RSI*0x8],R13
MOV RBP,qword ptr [RBX + 0x48]
MOV RAX,qword ptr [RBX + 0x50]
MOV qword ptr [RSP + 0x18],RAX
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R14
CALL 0x00125ae8
CMP qword ptr [RBX + 0x8],R14
JBE 0x001252b2
MOV RAX,qword ptr [R12]
MOV RCX,qword ptr [RSP + 0x20]
MOV dword ptr [RAX + RCX*0x4],R14D
LAB_001252b2:
MOV RSI,qword ptr [RBX + 0xd0]
CMP RSI,qword ptr [RBX + 0xd8]
JZ 0x001252d2
MOV dword ptr [RSI],R15D
ADD RSI,0x4
MOV qword ptr [RBX + 0xd0],RSI
JMP 0x001252e5
LAB_001252d2:
LEA R15,[RSP + 0x10]
MOV RDI,R12
MOV RDX,R15
CALL 0x0011f7c4
MOV R15,qword ptr [R15]
LAB_001252e5:
SHL R15,0x3
ADD R15,qword ptr [RBX + 0x28]
LEA R12,[RBX + 0xe0]
MOV RSI,qword ptr [RBX + 0xe8]
CMP RSI,qword ptr [RBX + 0xf0]
JZ 0x0012531a
MOVSD XMM0,qword ptr [R15]
MOVSD qword ptr [RSI],XMM0
ADD RSI,0x8
MOV qword ptr [RBX + 0xe8],RSI
JMP 0x00125333
LAB_0012531a:
MOV RDI,R12
MOV RDX,R15
CALL 0x00127cb8
MOV RAX,qword ptr [RBX + 0x28]
MOV RCX,qword ptr [RSP + 0x10]
MOVSD XMM0,qword ptr [RAX + RCX*0x8]
LAB_00125333:
MOVSD XMM1,qword ptr [RBX + 0x8]
UNPCKLPS XMM1,xmmword ptr [0x0012b6c0]
SUBPD XMM1,xmmword ptr [0x0012b6d0]
MOVAPD XMM2,XMM1
UNPCKHPD XMM2,XMM1
ADDSD XMM2,XMM1
ADDSD XMM2,qword ptr [0x0012b790]
DIVSD XMM0,XMM2
MOVSD qword ptr [RSP + 0x8],XMM0
MOV RSI,qword ptr [RBX + 0x100]
CMP RSI,qword ptr [RBX + 0x108]
JZ 0x00125386
MOVSD qword ptr [RSI],XMM0
ADD RSI,0x8
MOV qword ptr [RBX + 0x100],RSI
JMP 0x00125397
LAB_00125386:
LEA RDI,[RBX + 0xf8]
LEA RDX,[RSP + 0x8]
CALL 0x00127d98
LAB_00125397:
MOV R15,qword ptr [RSP + 0x18]
SUB R15,RBP
MOV qword ptr [RSP + 0x8],0x0
MOV RSI,qword ptr [RBX + 0x118]
CMP RSI,qword ptr [RBX + 0x120]
JZ 0x001253cc
MOV qword ptr [RSI],0x0
ADD RSI,0x8
MOV qword ptr [RBX + 0x118],RSI
JMP 0x001253dd
LAB_001253cc:
LEA RDI,[RBX + 0x110]
LEA RDX,[RSP + 0x8]
CALL 0x00127d98
LAB_001253dd:
SAR R15,0x6
MOV RAX,qword ptr [RBX + 0x170]
MOV RCX,qword ptr [RBX + 0x190]
MOVQ XMM0,qword ptr [RCX + RAX*0x8 + -0x8]
MOVQ qword ptr [RCX + R14*0x8],XMM0
MOV RCX,qword ptr [RBX + 0x188]
MOV RDX,qword ptr [RCX + RAX*0x8 + -0x8]
MOV qword ptr [RCX + R14*0x8],RDX
MOV RCX,qword ptr [RBX + 0x188]
XOR EDX,EDX
MOV qword ptr [RCX + RAX*0x8 + -0x8],RDX
DEC RAX
MOV qword ptr [RBX + 0x170],RAX
MOV RAX,qword ptr [RBX + 0x1a0]
MOV RCX,qword ptr [RBX + 0x1c0]
MOV ESI,dword ptr [RCX + RAX*0x4 + -0x4]
MOV dword ptr [RCX + R14*0x4],ESI
MOV RCX,qword ptr [RBX + 0x1b8]
MOV RSI,qword ptr [RCX + RAX*0x8 + -0x8]
MOV qword ptr [RCX + R14*0x8],RSI
MOV RCX,qword ptr [RBX + 0x1b8]
MOV qword ptr [RCX + RAX*0x8 + -0x8],RDX
DEC RAX
MOV qword ptr [RBX + 0x1a0],RAX
CMP qword ptr [RSP + 0x18],RBP
JZ 0x00125507
CMP R15,0x1
MOV RDX,R15
ADC RDX,0x0
MOV RAX,qword ptr [R12]
LEA RCX,[RDX + 0x1]
AND RCX,-0x2
DEC RDX
MOVQ XMM0,RDX
PSHUFD XMM0,XMM0,0x44
MOVDQA XMM1,xmmword ptr [0x0012b6e0]
XOR EDX,EDX
MOVDQA XMM2,xmmword ptr [0x0012b4f0]
PXOR XMM0,XMM2
PCMPEQD XMM3,XMM3
MOVDQA XMM4,xmmword ptr [0x0012b740]
LAB_001254b0:
MOVDQA XMM5,XMM1
PXOR XMM5,XMM2
MOVDQA XMM6,XMM5
PCMPGTD XMM6,XMM0
PCMPEQD XMM5,XMM0
PSHUFD XMM7,XMM5,0xf5
PAND XMM7,XMM6
PSHUFD XMM5,XMM6,0xf5
POR XMM5,XMM7
MOVD ESI,XMM5
NOT ESI
TEST SIL,0x1
JZ 0x001254e6
MOV qword ptr [RAX + RDX*0x8],R13
LAB_001254e6:
PXOR XMM5,XMM3
PEXTRW ESI,XMM5,0x4
TEST SIL,0x1
JZ 0x001254fa
MOV qword ptr [RAX + RDX*0x8 + 0x8],R13
LAB_001254fa:
ADD RDX,0x2
PADDQ XMM1,XMM4
CMP RCX,RDX
JNZ 0x001254b0
LAB_00125507:
MOV RAX,qword ptr [RBX + 0x8]
TEST RAX,RAX
JZ 0x00125538
MOV RCX,qword ptr [RBX + 0x28]
MOV RDX,qword ptr [RBX + 0x30]
MOV RSI,qword ptr [RBX + 0xe0]
XOR EDI,EDI
LAB_00125521:
MOV R8,qword ptr [RDX + RDI*0x8]
MOVQ XMM0,qword ptr [RCX + RDI*0x8]
MOVQ qword ptr [RSI + R8*0x8],XMM0
INC RDI
CMP RAX,RDI
JNZ 0x00125521
LAB_00125538:
MOV RSI,qword ptr [RSP + 0x10]
MOV RDI,RBX
MOV RDX,R15
CALL 0x001273fa
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* StartTree::BoundingMatrix<double, StartTree::BIONJMatrix<double> >::cluster(unsigned long,
unsigned long) */
void __thiscall
StartTree::BoundingMatrix<double,StartTree::BIONJMatrix<double>>::cluster
(BoundingMatrix<double,StartTree::BIONJMatrix<double>> *this,ulong param_1,ulong param_2)
{
long lVar1;
long lVar2;
int4 *puVar3;
double *pdVar4;
int8 *puVar5;
long lVar6;
long lVar7;
ulong uVar8;
double *pdVar9;
long lVar10;
ulong uVar11;
int1 auVar12 [16];
int1 auVar13 [16];
int1 auVar14 [16];
int1 auVar15 [16];
double local_50;
ulong local_48;
long local_40;
long local_38;
lVar1 = *(long *)(this + 0x30);
lVar10 = *(long *)(lVar1 + param_1 * 8);
lVar2 = *(long *)(lVar1 + param_2 * 8);
local_38 = *(long *)(lVar1 + -8 + *(long *)(this + 8) * 8);
lVar1 = *(long *)(this + 200);
*(int4 *)(lVar1 + lVar10 * 4) = 0xffffffff;
lVar6 = *(long *)(this + 0xe0);
*(int8 *)(lVar6 + lVar10 * 8) = 0xc76812f9c0000000;
*(int4 *)(lVar1 + lVar2 * 4) = 0xffffffff;
*(int8 *)(lVar6 + lVar2 * 8) = 0xc76812f9c0000000;
lVar1 = *(long *)(this + 0x48);
local_40 = *(long *)(this + 0x50);
local_48 = param_1;
BIONJMatrix<double>::cluster((BIONJMatrix<double> *)this,param_1,param_2);
if (param_2 < *(ulong *)(this + 8)) {
*(int *)(*(long *)(this + 200) + local_38 * 4) = (int)param_2;
}
puVar3 = *(int4 **)(this + 0xd0);
if (puVar3 == *(int4 **)(this + 0xd8)) {
std::vector<int,std::allocator<int>>::_M_realloc_insert<unsigned_long&>
((vector<int,std::allocator<int>> *)(this + 200),puVar3,&local_48);
param_1 = local_48;
}
else {
*puVar3 = (int)param_1;
*(int4 **)(this + 0xd0) = puVar3 + 1;
}
pdVar9 = (double *)(param_1 * 8 + *(long *)(this + 0x28));
pdVar4 = *(double **)(this + 0xe8);
if (pdVar4 == *(double **)(this + 0xf0)) {
std::vector<double,std::allocator<double>>::_M_realloc_insert<double&>
((vector<double,std::allocator<double>> *)(this + 0xe0),pdVar4,pdVar9);
local_50 = *(double *)(*(long *)(this + 0x28) + local_48 * 8);
}
else {
local_50 = *pdVar9;
*pdVar4 = local_50;
*(double **)(this + 0xe8) = pdVar4 + 1;
}
auVar13._0_8_ = (double)CONCAT44((int4)DAT_0012b6c0,(int)*(int8 *)(this + 8));
auVar13._8_4_ = (int)((ulong)*(int8 *)(this + 8) >> 0x20);
auVar13._12_4_ = DAT_0012b6c0._4_4_;
local_50 = local_50 /
((auVar13._8_8_ - _UNK_0012b6d8) + (auVar13._0_8_ - _DAT_0012b6d0) + _DAT_0012b790);
pdVar4 = *(double **)(this + 0x100);
if (pdVar4 == *(double **)(this + 0x108)) {
std::vector<double,std::allocator<double>>::_M_realloc_insert<double>
((vector<double,std::allocator<double>> *)(this + 0xf8),pdVar4,&local_50);
}
else {
*pdVar4 = local_50;
*(double **)(this + 0x100) = pdVar4 + 1;
}
lVar10 = local_40 - lVar1;
local_50 = 0.0;
puVar5 = *(int8 **)(this + 0x118);
if (puVar5 == *(int8 **)(this + 0x120)) {
std::vector<double,std::allocator<double>>::_M_realloc_insert<double>
((vector<double,std::allocator<double>> *)(this + 0x110),puVar5,&local_50);
}
else {
*puVar5 = 0;
*(int8 **)(this + 0x118) = puVar5 + 1;
}
uVar11 = lVar10 >> 6;
lVar10 = *(long *)(this + 0x170);
*(int8 *)(*(long *)(this + 400) + param_2 * 8) =
*(int8 *)(*(long *)(this + 400) + -8 + lVar10 * 8);
*(int8 *)(*(long *)(this + 0x188) + param_2 * 8) =
*(int8 *)(*(long *)(this + 0x188) + -8 + lVar10 * 8);
*(int8 *)(*(long *)(this + 0x188) + -8 + lVar10 * 8) = 0;
*(long *)(this + 0x170) = lVar10 + -1;
lVar10 = *(long *)(this + 0x1a0);
*(int4 *)(*(long *)(this + 0x1c0) + param_2 * 4) =
*(int4 *)(*(long *)(this + 0x1c0) + -4 + lVar10 * 4);
*(int8 *)(*(long *)(this + 0x1b8) + param_2 * 8) =
*(int8 *)(*(long *)(this + 0x1b8) + -8 + lVar10 * 8);
*(int8 *)(*(long *)(this + 0x1b8) + -8 + lVar10 * 8) = 0;
*(long *)(this + 0x1a0) = lVar10 + -1;
lVar2 = _UNK_0012b748;
lVar10 = _DAT_0012b740;
auVar13 = _DAT_0012b4f0;
if (local_40 != lVar1) {
lVar6 = uVar11 + (uVar11 == 0);
lVar1 = *(long *)(this + 0xe0);
lVar7 = lVar6 + -1;
auVar12._8_4_ = (int)lVar7;
auVar12._0_8_ = lVar7;
auVar12._12_4_ = (int)((ulong)lVar7 >> 0x20);
uVar8 = 0;
auVar12 = auVar12 ^ _DAT_0012b4f0;
auVar14 = _DAT_0012b6e0;
do {
auVar15 = auVar14 ^ auVar13;
if ((bool)(~(auVar15._4_4_ == auVar12._4_4_ && auVar12._0_4_ < auVar15._0_4_ ||
auVar12._4_4_ < auVar15._4_4_) & 1)) {
*(int8 *)(lVar1 + uVar8 * 8) = 0xc76812f9c0000000;
}
if ((auVar15._12_4_ != auVar12._12_4_ || auVar15._8_4_ <= auVar12._8_4_) &&
auVar15._12_4_ <= auVar12._12_4_) {
*(int8 *)(lVar1 + 8 + uVar8 * 8) = 0xc76812f9c0000000;
}
uVar8 = uVar8 + 2;
lVar7 = auVar14._8_8_;
auVar14._0_8_ = auVar14._0_8_ + lVar10;
auVar14._8_8_ = lVar7 + lVar2;
} while ((lVar6 + 1U & 0xfffffffffffffffe) != uVar8);
}
lVar1 = *(long *)(this + 8);
if (lVar1 != 0) {
lVar10 = *(long *)(this + 0x28);
lVar2 = *(long *)(this + 0x30);
lVar6 = *(long *)(this + 0xe0);
lVar7 = 0;
do {
*(int8 *)(lVar6 + *(long *)(lVar2 + lVar7 * 8) * 8) =
*(int8 *)(lVar10 + lVar7 * 8);
lVar7 = lVar7 + 1;
} while (lVar1 != lVar7);
}
sortRow(this,local_48,uVar11);
return;
}
| |
22,195 | my_wc_mb_filename | eloqsql/strings/ctype-utf8.c | static int
my_wc_mb_filename(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t wc, uchar *s, uchar *e)
{
int code;
static const char hex[]= "0123456789abcdef";
if (s >= e)
return MY_CS_TOOSMALL;
if (wc < 128 && filename_safe_char[wc])
{
*s= (uchar) wc;
return 1;
}
if (s + 3 > e)
return MY_CS_TOOSMALL3;
*s++= MY_FILENAME_ESCAPE;
if ((wc >= 0x00C0 && wc <= 0x05FF && (code= uni_0C00_05FF[wc - 0x00C0])) ||
(wc >= 0x1E00 && wc <= 0x1FFF && (code= uni_1E00_1FFF[wc - 0x1E00])) ||
(wc >= 0x2160 && wc <= 0x217F && (code= uni_2160_217F[wc - 0x2160])) ||
(wc >= 0x24B0 && wc <= 0x24EF && (code= uni_24B0_24EF[wc - 0x24B0])) ||
(wc >= 0xFF20 && wc <= 0xFF5F && (code= uni_FF20_FF5F[wc - 0xFF20])))
{
*s++= (code / 80) + 0x30;
*s++= (code % 80) + 0x30;
return 3;
}
/* Non letter */
if (s + 4 > e)
return MY_CS_TOOSMALL5;
*s++= hex[(wc >> 12) & 15];
*s++= hex[(wc >> 8) & 15];
*s++= hex[(wc >> 4) & 15];
*s++= hex[(wc) & 15];
return 5;
} | O3 | c | my_wc_mb_filename:
pushq %rbp
movq %rsp, %rbp
movl $0xffffff9b, %eax # imm = 0xFFFFFF9B
cmpq %rcx, %rdx
jae 0x58de2
cmpq $0x7f, %rsi
ja 0x58d42
leaq 0x2843c1(%rip), %rax # 0x2dd0f0
cmpb $0x0, (%rsi,%rax)
je 0x58d42
movb %sil, (%rdx)
movl $0x1, %eax
jmp 0x58de2
leaq 0x3(%rdx), %rdi
movl $0xffffff99, %eax # imm = 0xFFFFFF99
cmpq %rcx, %rdi
ja 0x58de2
movb $0x40, (%rdx)
leaq -0xc0(%rsi), %rax
cmpq $0x53f, %rax # imm = 0x53F
ja 0x58d7a
leaq 0x287923(%rip), %rax # 0x2e0690
movzwl -0x180(%rax,%rsi,2), %eax
testw %ax, %ax
jne 0x58dbd
movq %rsi, %rax
andq $-0x200, %rax # imm = 0xFE00
cmpq $0x1e00, %rax # imm = 0x1E00
jne 0x58d9f
leaq 0x2873be(%rip), %rax # 0x2e0150
movzwl -0x3c00(%rax,%rsi,2), %eax
testw %ax, %ax
jne 0x58dbd
movq %rsi, %rax
andq $-0x20, %rax
cmpq $0x2160, %rax # imm = 0x2160
jne 0x58de4
leaq 0x28779b(%rip), %rax # 0x2e0550
movzwl -0x42c0(%rax,%rsi,2), %eax
movzwl %ax, %ecx
imull $0xcccd, %ecx, %ecx # imm = 0xCCCD
shrl $0x16, %ecx
leal 0x30(%rcx), %esi
movb %sil, 0x1(%rdx)
shll $0x4, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
addb $0x30, %al
movb %al, 0x2(%rdx)
movl $0x3, %eax
popq %rbp
retq
leaq -0x24b0(%rsi), %rax
cmpq $0x3f, %rax
ja 0x58e0f
leaq -0x24ea(%rsi), %rax
cmpq $-0x34, %rax
jb 0x58e3d
leaq 0x28778b(%rip), %rax # 0x2e0590
movzwl -0x4960(%rax,%rsi,2), %eax
jmp 0x58dbd
leaq -0xff20(%rsi), %rax
cmpq $0x3f, %rax
ja 0x58e3d
movabsq $-0x7fffffe07ffffff, %rdi # imm = 0xF8000001F8000001
btq %rax, %rdi
jb 0x58e3d
leaq 0x2877dd(%rip), %rax # 0x2e0610
movzwl -0x1fe40(%rax,%rsi,2), %eax
jmp 0x58dbd
leaq 0x5(%rdx), %rdi
movl $0xffffff97, %eax # imm = 0xFFFFFF97
cmpq %rcx, %rdi
ja 0x58de2
movl %esi, %eax
shrl $0xc, %eax
andl $0xf, %eax
leaq 0x2882b6(%rip), %rcx # 0x2e1110
movb (%rax,%rcx), %al
movb %al, 0x1(%rdx)
movl %esi, %eax
shrl $0x8, %eax
andl $0xf, %eax
movb (%rax,%rcx), %al
movb %al, 0x2(%rdx)
movl %esi, %eax
shrl $0x4, %eax
andl $0xf, %eax
movb (%rax,%rcx), %al
movb %al, 0x3(%rdx)
andl $0xf, %esi
movb (%rsi,%rcx), %al
movb %al, 0x4(%rdx)
movl $0x5, %eax
jmp 0x58de2
| my_wc_mb_filename:
push rbp
mov rbp, rsp
mov eax, 0FFFFFF9Bh
cmp rdx, rcx
jnb loc_58DE2
cmp rsi, 7Fh
ja short loc_58D42
lea rax, filename_safe_char
cmp byte ptr [rsi+rax], 0
jz short loc_58D42
mov [rdx], sil
mov eax, 1
jmp loc_58DE2
loc_58D42:
lea rdi, [rdx+3]
mov eax, 0FFFFFF99h
cmp rdi, rcx
ja loc_58DE2
mov byte ptr [rdx], 40h ; '@'
lea rax, [rsi-0C0h]
cmp rax, 53Fh
ja short loc_58D7A
lea rax, uni_0C00_05FF
movzx eax, word ptr [rax+rsi*2-180h]
test ax, ax
jnz short loc_58DBD
loc_58D7A:
mov rax, rsi
and rax, 0FFFFFFFFFFFFFE00h
cmp rax, 1E00h
jnz short loc_58D9F
lea rax, uni_1E00_1FFF
movzx eax, word ptr [rax+rsi*2-3C00h]
test ax, ax
jnz short loc_58DBD
loc_58D9F:
mov rax, rsi
and rax, 0FFFFFFFFFFFFFFE0h
cmp rax, 2160h
jnz short loc_58DE4
lea rax, uni_2160_217F
movzx eax, word ptr [rax+rsi*2-42C0h]
loc_58DBD:
movzx ecx, ax
imul ecx, 0CCCDh
shr ecx, 16h
lea esi, [rcx+30h]
mov [rdx+1], sil
shl ecx, 4
lea ecx, [rcx+rcx*4]
sub eax, ecx
add al, 30h ; '0'
mov [rdx+2], al
mov eax, 3
loc_58DE2:
pop rbp
retn
loc_58DE4:
lea rax, [rsi-24B0h]
cmp rax, 3Fh ; '?'
ja short loc_58E0F
lea rax, [rsi-24EAh]
cmp rax, 0FFFFFFFFFFFFFFCCh
jb short loc_58E3D
lea rax, uni_24B0_24EF
movzx eax, word ptr [rax+rsi*2-4960h]
jmp short loc_58DBD
loc_58E0F:
lea rax, [rsi-0FF20h]
cmp rax, 3Fh ; '?'
ja short loc_58E3D
mov rdi, 0F8000001F8000001h
bt rdi, rax
jb short loc_58E3D
lea rax, uni_FF20_FF5F
movzx eax, word ptr [rax+rsi*2-1FE40h]
jmp short loc_58DBD
loc_58E3D:
lea rdi, [rdx+5]
mov eax, 0FFFFFF97h
cmp rdi, rcx
ja short loc_58DE2
mov eax, esi
shr eax, 0Ch
and eax, 0Fh
lea rcx, my_wc_mb_filename_hex; "0123456789abcdef"
mov al, [rax+rcx]
mov [rdx+1], al
mov eax, esi
shr eax, 8
and eax, 0Fh
mov al, [rax+rcx]
mov [rdx+2], al
mov eax, esi
shr eax, 4
and eax, 0Fh
mov al, [rax+rcx]
mov [rdx+3], al
and esi, 0Fh
mov al, [rsi+rcx]
mov [rdx+4], al
mov eax, 5
jmp loc_58DE2
| long long my_wc_mb_filename(long long a1, unsigned long long a2, _BYTE *a3, unsigned long long a4)
{
long long result; // rax
unsigned __int16 v5; // ax
unsigned long long v6; // rdi
result = 4294967195LL;
if ( (unsigned long long)a3 < a4 )
{
if ( a2 <= 0x7F && filename_safe_char[a2] )
{
*a3 = a2;
return 1LL;
}
result = 4294967193LL;
if ( (unsigned long long)(a3 + 3) <= a4 )
{
*a3 = 64;
if ( a2 - 192 <= 0x53F )
{
v5 = uni_0C00_05FF[a2 - 192];
if ( v5 )
goto LABEL_12;
}
if ( (a2 & 0xFFFFFFFFFFFFFE00LL) == 0x1E00 )
{
v5 = uni_1E00_1FFF[a2 - 7680];
if ( v5 )
goto LABEL_12;
}
if ( (a2 & 0xFFFFFFFFFFFFFFE0LL) == 0x2160 )
{
v5 = uni_2160_217F[a2 - 8544];
LABEL_12:
a3[1] = v5 / 0x50u + 48;
a3[2] = v5 % 0x50u + 48;
return 3LL;
}
if ( a2 - 9392 > 0x3F )
{
if ( a2 - 65312 <= 0x3F )
{
v6 = 0xF8000001F8000001LL;
if ( !_bittest64((const long long *)&v6, a2 - 65312) )
{
v5 = uni_FF20_FF5F[a2 - 65312];
goto LABEL_12;
}
}
}
else if ( a2 - 9450 >= 0xFFFFFFFFFFFFFFCCLL )
{
v5 = uni_24B0_24EF[a2 - 9392];
goto LABEL_12;
}
result = 4294967191LL;
if ( (unsigned long long)(a3 + 5) <= a4 )
{
a3[1] = my_wc_mb_filename_hex[(unsigned __int16)a2 >> 12];
a3[2] = my_wc_mb_filename_hex[((unsigned int)a2 >> 8) & 0xF];
a3[3] = my_wc_mb_filename_hex[(unsigned __int8)a2 >> 4];
a3[4] = my_wc_mb_filename_hex[a2 & 0xF];
return 5LL;
}
}
}
return result;
}
| my_wc_mb_filename:
PUSH RBP
MOV RBP,RSP
MOV EAX,0xffffff9b
CMP RDX,RCX
JNC 0x00158de2
CMP RSI,0x7f
JA 0x00158d42
LEA RAX,[0x3dd0f0]
CMP byte ptr [RSI + RAX*0x1],0x0
JZ 0x00158d42
MOV byte ptr [RDX],SIL
MOV EAX,0x1
JMP 0x00158de2
LAB_00158d42:
LEA RDI,[RDX + 0x3]
MOV EAX,0xffffff99
CMP RDI,RCX
JA 0x00158de2
MOV byte ptr [RDX],0x40
LEA RAX,[RSI + -0xc0]
CMP RAX,0x53f
JA 0x00158d7a
LEA RAX,[0x3e0690]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x180]
TEST AX,AX
JNZ 0x00158dbd
LAB_00158d7a:
MOV RAX,RSI
AND RAX,-0x200
CMP RAX,0x1e00
JNZ 0x00158d9f
LEA RAX,[0x3e0150]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x3c00]
TEST AX,AX
JNZ 0x00158dbd
LAB_00158d9f:
MOV RAX,RSI
AND RAX,-0x20
CMP RAX,0x2160
JNZ 0x00158de4
LEA RAX,[0x3e0550]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x42c0]
LAB_00158dbd:
MOVZX ECX,AX
IMUL ECX,ECX,0xcccd
SHR ECX,0x16
LEA ESI,[RCX + 0x30]
MOV byte ptr [RDX + 0x1],SIL
SHL ECX,0x4
LEA ECX,[RCX + RCX*0x4]
SUB EAX,ECX
ADD AL,0x30
MOV byte ptr [RDX + 0x2],AL
MOV EAX,0x3
LAB_00158de2:
POP RBP
RET
LAB_00158de4:
LEA RAX,[RSI + -0x24b0]
CMP RAX,0x3f
JA 0x00158e0f
LEA RAX,[RSI + -0x24ea]
CMP RAX,-0x34
JC 0x00158e3d
LEA RAX,[0x3e0590]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x4960]
JMP 0x00158dbd
LAB_00158e0f:
LEA RAX,[RSI + -0xff20]
CMP RAX,0x3f
JA 0x00158e3d
MOV RDI,-0x7fffffe07ffffff
BT RDI,RAX
JC 0x00158e3d
LEA RAX,[0x3e0610]
MOVZX EAX,word ptr [RAX + RSI*0x2 + -0x1fe40]
JMP 0x00158dbd
LAB_00158e3d:
LEA RDI,[RDX + 0x5]
MOV EAX,0xffffff97
CMP RDI,RCX
JA 0x00158de2
MOV EAX,ESI
SHR EAX,0xc
AND EAX,0xf
LEA RCX,[0x3e1110]
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x1],AL
MOV EAX,ESI
SHR EAX,0x8
AND EAX,0xf
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x2],AL
MOV EAX,ESI
SHR EAX,0x4
AND EAX,0xf
MOV AL,byte ptr [RAX + RCX*0x1]
MOV byte ptr [RDX + 0x3],AL
AND ESI,0xf
MOV AL,byte ptr [RSI + RCX*0x1]
MOV byte ptr [RDX + 0x4],AL
MOV EAX,0x5
JMP 0x00158de2
|
int8
my_wc_mb_filename(int8 param_1,ulong param_2,int1 *param_3,int1 *param_4)
{
ushort uVar1;
if (param_4 <= param_3) {
return 0xffffff9b;
}
if ((param_2 < 0x80) && (filename_safe_char[param_2] != '\0')) {
*param_3 = (char)param_2;
return 1;
}
if (param_4 < param_3 + 3) {
return 0xffffff99;
}
*param_3 = 0x40;
if (((0x53f < param_2 - 0xc0) ||
(uVar1 = *(ushort *)(uni_1E00_1FFF + param_2 * 2 + 0x3c0), uVar1 == 0)) &&
(((param_2 & 0xfffffffffffffe00) != 0x1e00 ||
(uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1f780), uVar1 == 0)))) {
if ((param_2 & 0xffffffffffffffe0) == 0x2160) {
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1f4c0);
}
else if (param_2 - 0x24b0 < 0x40) {
if (param_2 - 0x24ea < 0xffffffffffffffcc) {
LAB_00158e3d:
if (param_4 < param_3 + 5) {
return 0xffffff97;
}
param_3[1] = "0123456789abcdef"[(uint)(param_2 >> 0xc) & 0xf];
param_3[2] = "0123456789abcdef"[(uint)(param_2 >> 8) & 0xf];
param_3[3] = "0123456789abcdef"[(uint)(param_2 >> 4) & 0xf];
param_3[4] = "0123456789abcdef"[(uint)param_2 & 0xf];
return 5;
}
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x1ee60);
}
else {
if ((0x3f < param_2 - 0xff20) || ((0xf8000001f8000001U >> (param_2 - 0xff20 & 0x3f) & 1) != 0)
) goto LAB_00158e3d;
uVar1 = *(ushort *)(unicode_to_jisx0212_eucjp + param_2 * 2 + 0x3a00);
}
}
param_3[1] = (char)(uVar1 / 0x50) + '0';
param_3[2] = (char)uVar1 + (char)(uVar1 / 0x50 << 4) * -5 + '0';
return 3;
}
| |
22,196 | copy_typelib | eloqsql/mysys/typelib.c | TYPELIB *copy_typelib(MEM_ROOT *root, const TYPELIB *from)
{
TYPELIB *to;
uint i;
if (!from)
return NULL;
if (!(to= (TYPELIB*) alloc_root(root, sizeof(TYPELIB))))
return NULL;
if (!(to->type_names= (const char **)
alloc_root(root, (sizeof(char *) + sizeof(int)) * (from->count + 1))))
return NULL;
to->type_lengths= (unsigned int *)(to->type_names + from->count + 1);
to->count= from->count;
if (from->name)
{
if (!(to->name= strdup_root(root, from->name)))
return NULL;
}
else
to->name= NULL;
for (i= 0; i < from->count; i++)
{
if (!(to->type_names[i]= strmake_root(root, from->type_names[i],
from->type_lengths[i])))
return NULL;
to->type_lengths[i]= from->type_lengths[i];
}
to->type_names[to->count]= NULL;
to->type_lengths[to->count]= 0;
return to;
} | O0 | c | copy_typelib:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x105054
movq $0x0, -0x8(%rbp)
jmp 0x1051d1
movq -0x10(%rbp), %rdi
movl $0x20, %esi
callq 0xf2470
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
jne 0x105079
movq $0x0, -0x8(%rbp)
jmp 0x1051d1
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movl (%rax), %eax
addl $0x1, %eax
movl %eax, %eax
imulq $0xc, %rax, %rsi
callq 0xf2470
movq -0x20(%rbp), %rcx
movq %rax, 0x10(%rcx)
cmpq $0x0, %rax
jne 0x1050ac
movq $0x0, -0x8(%rbp)
jmp 0x1051d1
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x18(%rbp), %rax
movl (%rax), %eax
shlq $0x3, %rax
addq %rax, %rcx
addq $0x8, %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x18(%rbp), %rax
movl (%rax), %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x8(%rax)
je 0x105112
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rsi
callq 0xf2ce0
movq -0x20(%rbp), %rcx
movq %rax, 0x8(%rcx)
cmpq $0x0, %rax
jne 0x105110
movq $0x0, -0x8(%rbp)
jmp 0x1051d1
jmp 0x10511e
movq -0x20(%rbp), %rax
movq $0x0, 0x8(%rax)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq -0x18(%rbp), %rcx
cmpl (%rcx), %eax
jae 0x10519e
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rsi
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movl -0x24(%rbp), %ecx
movl (%rax,%rcx,4), %eax
movl %eax, %edx
callq 0xf2d20
movq -0x20(%rbp), %rcx
movq 0x10(%rcx), %rcx
movl -0x24(%rbp), %edx
movq %rax, (%rcx,%rdx,8)
cmpq $0x0, %rax
jne 0x105177
movq $0x0, -0x8(%rbp)
jmp 0x1051d1
movq -0x18(%rbp), %rax
movq 0x18(%rax), %rax
movl -0x24(%rbp), %ecx
movl (%rax,%rcx,4), %edx
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movl -0x24(%rbp), %ecx
movl %edx, (%rax,%rcx,4)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x105125
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x20(%rbp), %rcx
movl (%rcx), %ecx
movq $0x0, (%rax,%rcx,8)
movq -0x20(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x20(%rbp), %rcx
movl (%rcx), %ecx
movl $0x0, (%rax,%rcx,4)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| copy_typelib:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
cmp [rbp+var_18], 0
jnz short loc_105054
mov [rbp+var_8], 0
jmp loc_1051D1
loc_105054:
mov rdi, [rbp+var_10]
mov esi, 20h ; ' '
call alloc_root
mov [rbp+var_20], rax
cmp rax, 0
jnz short loc_105079
mov [rbp+var_8], 0
jmp loc_1051D1
loc_105079:
mov rdi, [rbp+var_10]
mov rax, [rbp+var_18]
mov eax, [rax]
add eax, 1
mov eax, eax
imul rsi, rax, 0Ch
call alloc_root
mov rcx, [rbp+var_20]
mov [rcx+10h], rax
cmp rax, 0
jnz short loc_1050AC
mov [rbp+var_8], 0
jmp loc_1051D1
loc_1050AC:
mov rax, [rbp+var_20]
mov rcx, [rax+10h]
mov rax, [rbp+var_18]
mov eax, [rax]
shl rax, 3
add rcx, rax
add rcx, 8
mov rax, [rbp+var_20]
mov [rax+18h], rcx
mov rax, [rbp+var_18]
mov ecx, [rax]
mov rax, [rbp+var_20]
mov [rax], ecx
mov rax, [rbp+var_18]
cmp qword ptr [rax+8], 0
jz short loc_105112
mov rdi, [rbp+var_10]
mov rax, [rbp+var_18]
mov rsi, [rax+8]
call strdup_root
mov rcx, [rbp+var_20]
mov [rcx+8], rax
cmp rax, 0
jnz short loc_105110
mov [rbp+var_8], 0
jmp loc_1051D1
loc_105110:
jmp short loc_10511E
loc_105112:
mov rax, [rbp+var_20]
mov qword ptr [rax+8], 0
loc_10511E:
mov [rbp+var_24], 0
loc_105125:
mov eax, [rbp+var_24]
mov rcx, [rbp+var_18]
cmp eax, [rcx]
jnb short loc_10519E
mov rdi, [rbp+var_10]
mov rax, [rbp+var_18]
mov rax, [rax+10h]
mov ecx, [rbp+var_24]
mov rsi, [rax+rcx*8]
mov rax, [rbp+var_18]
mov rax, [rax+18h]
mov ecx, [rbp+var_24]
mov eax, [rax+rcx*4]
mov edx, eax
call strmake_root
mov rcx, [rbp+var_20]
mov rcx, [rcx+10h]
mov edx, [rbp+var_24]
mov [rcx+rdx*8], rax
cmp rax, 0
jnz short loc_105177
mov [rbp+var_8], 0
jmp short loc_1051D1
loc_105177:
mov rax, [rbp+var_18]
mov rax, [rax+18h]
mov ecx, [rbp+var_24]
mov edx, [rax+rcx*4]
mov rax, [rbp+var_20]
mov rax, [rax+18h]
mov ecx, [rbp+var_24]
mov [rax+rcx*4], edx
mov eax, [rbp+var_24]
add eax, 1
mov [rbp+var_24], eax
jmp short loc_105125
loc_10519E:
mov rax, [rbp+var_20]
mov rax, [rax+10h]
mov rcx, [rbp+var_20]
mov ecx, [rcx]
mov qword ptr [rax+rcx*8], 0
mov rax, [rbp+var_20]
mov rax, [rax+18h]
mov rcx, [rbp+var_20]
mov ecx, [rcx]
mov dword ptr [rax+rcx*4], 0
mov rax, [rbp+var_20]
mov [rbp+var_8], rax
loc_1051D1:
mov rax, [rbp+var_8]
add rsp, 30h
pop rbp
retn
| char * copy_typelib(_QWORD **a1, unsigned int *a2)
{
char *v2; // rax
long long v3; // rax
char *v4; // rax
unsigned int i; // [rsp+Ch] [rbp-24h]
char *v7; // [rsp+10h] [rbp-20h]
if ( !a2 )
return 0LL;
v7 = alloc_root(a1, 32LL);
if ( !v7 )
return 0LL;
v2 = alloc_root(a1, 12LL * (*a2 + 1));
*((_QWORD *)v7 + 2) = v2;
if ( !v2 )
return 0LL;
*((_QWORD *)v7 + 3) = 8LL * *a2 + *((_QWORD *)v7 + 2) + 8;
*(_DWORD *)v7 = *a2;
if ( *((_QWORD *)a2 + 1) )
{
v3 = strdup_root((long long)a1, *((_QWORD *)a2 + 1));
*((_QWORD *)v7 + 1) = v3;
if ( !v3 )
return 0LL;
}
else
{
*((_QWORD *)v7 + 1) = 0LL;
}
for ( i = 0; i < *a2; ++i )
{
v4 = strmake_root(a1, *(_QWORD *)(*((_QWORD *)a2 + 2) + 8LL * i), *(unsigned int *)(*((_QWORD *)a2 + 3) + 4LL * i));
*(_QWORD *)(*((_QWORD *)v7 + 2) + 8LL * i) = v4;
if ( !v4 )
return 0LL;
*(_DWORD *)(*((_QWORD *)v7 + 3) + 4LL * i) = *(_DWORD *)(*((_QWORD *)a2 + 3) + 4LL * i);
}
*(_QWORD *)(*((_QWORD *)v7 + 2) + 8LL * *(unsigned int *)v7) = 0LL;
*(_DWORD *)(*((_QWORD *)v7 + 3) + 4LL * *(unsigned int *)v7) = 0;
return v7;
}
| |||
22,197 | copy_typelib | eloqsql/mysys/typelib.c | TYPELIB *copy_typelib(MEM_ROOT *root, const TYPELIB *from)
{
TYPELIB *to;
uint i;
if (!from)
return NULL;
if (!(to= (TYPELIB*) alloc_root(root, sizeof(TYPELIB))))
return NULL;
if (!(to->type_names= (const char **)
alloc_root(root, (sizeof(char *) + sizeof(int)) * (from->count + 1))))
return NULL;
to->type_lengths= (unsigned int *)(to->type_names + from->count + 1);
to->count= from->count;
if (from->name)
{
if (!(to->name= strdup_root(root, from->name)))
return NULL;
}
else
to->name= NULL;
for (i= 0; i < from->count; i++)
{
if (!(to->type_names[i]= strmake_root(root, from->type_names[i],
from->type_lengths[i])))
return NULL;
to->type_lengths[i]= from->type_lengths[i];
}
to->type_names[to->count]= NULL;
to->type_lengths[to->count]= 0;
return to;
} | O3 | c | copy_typelib:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rsi, %rsi
je 0xacb93
movq %rsi, %r14
movq %rdi, %r15
movl $0x20, %esi
callq 0xa1a8f
testq %rax, %rax
je 0xacb93
movq %rax, %rbx
movl (%r14), %eax
incl %eax
shlq $0x2, %rax
leaq (%rax,%rax,2), %rsi
movq %r15, %rdi
callq 0xa1a8f
movq %rax, 0x10(%rbx)
testq %rax, %rax
je 0xacb93
movl (%r14), %ecx
leaq (%rax,%rcx,8), %rax
addq $0x8, %rax
movq %rax, 0x18(%rbx)
movl (%r14), %eax
movl %eax, (%rbx)
movq 0x8(%r14), %rsi
testq %rsi, %rsi
je 0xacba1
movq %r15, %rdi
callq 0xa1e2a
movq %rax, 0x8(%rbx)
testq %rax, %rax
jne 0xacba9
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq $0x0, 0x8(%rbx)
cmpl $0x0, (%r14)
je 0xacbf2
xorl %r12d, %r12d
movq 0x10(%r14), %rax
movq 0x18(%r14), %rcx
movq (%rax,%r12,8), %rsi
movl (%rcx,%r12,4), %edx
movq %r15, %rdi
callq 0xa1e51
movq 0x10(%rbx), %rcx
movq %rax, (%rcx,%r12,8)
testq %rax, %rax
je 0xacb93
movq 0x18(%r14), %rax
movl (%rax,%r12,4), %eax
movq 0x18(%rbx), %rcx
movl %eax, (%rcx,%r12,4)
incq %r12
movl (%r14), %eax
cmpq %rax, %r12
jb 0xacbb2
movq 0x10(%rbx), %rax
movl (%rbx), %ecx
movq $0x0, (%rax,%rcx,8)
movq 0x18(%rbx), %rax
movl (%rbx), %ecx
movl $0x0, (%rax,%rcx,4)
jmp 0xacb95
| copy_typelib:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
test rsi, rsi
jz short loc_ACB93
mov r14, rsi
mov r15, rdi
mov esi, 20h ; ' '
call alloc_root
test rax, rax
jz short loc_ACB93
mov rbx, rax
mov eax, [r14]
inc eax
shl rax, 2
lea rsi, [rax+rax*2]
mov rdi, r15
call alloc_root
mov [rbx+10h], rax
test rax, rax
jz short loc_ACB93
mov ecx, [r14]
lea rax, [rax+rcx*8]
add rax, 8
mov [rbx+18h], rax
mov eax, [r14]
mov [rbx], eax
mov rsi, [r14+8]
test rsi, rsi
jz short loc_ACBA1
mov rdi, r15
call strdup_root
mov [rbx+8], rax
test rax, rax
jnz short loc_ACBA9
loc_ACB93:
xor ebx, ebx
loc_ACB95:
mov rax, rbx
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_ACBA1:
mov qword ptr [rbx+8], 0
loc_ACBA9:
cmp dword ptr [r14], 0
jz short loc_ACBF2
xor r12d, r12d
loc_ACBB2:
mov rax, [r14+10h]
mov rcx, [r14+18h]
mov rsi, [rax+r12*8]
mov edx, [rcx+r12*4]
mov rdi, r15
call strmake_root
mov rcx, [rbx+10h]
mov [rcx+r12*8], rax
test rax, rax
jz short loc_ACB93
mov rax, [r14+18h]
mov eax, [rax+r12*4]
mov rcx, [rbx+18h]
mov [rcx+r12*4], eax
inc r12
mov eax, [r14]
cmp r12, rax
jb short loc_ACBB2
loc_ACBF2:
mov rax, [rbx+10h]
mov ecx, [rbx]
mov qword ptr [rax+rcx*8], 0
mov rax, [rbx+18h]
mov ecx, [rbx]
mov dword ptr [rax+rcx*4], 0
jmp short loc_ACB95
| char * copy_typelib(long long a1, unsigned int *a2)
{
char *v3; // rax
char *v4; // rbx
char *v5; // rax
long long v6; // rsi
long long v7; // rax
long long v9; // r12
char *v10; // rax
if ( !a2 )
return 0LL;
v3 = alloc_root(a1, 32LL);
if ( !v3 )
return 0LL;
v4 = v3;
v5 = alloc_root(a1, 12LL * (*a2 + 1));
*((_QWORD *)v4 + 2) = v5;
if ( !v5 )
return 0LL;
*((_QWORD *)v4 + 3) = &v5[8 * *a2 + 8];
*(_DWORD *)v4 = *a2;
v6 = *((_QWORD *)a2 + 1);
if ( v6 )
{
v7 = strdup_root(a1, v6);
*((_QWORD *)v4 + 1) = v7;
if ( !v7 )
return 0LL;
}
else
{
*((_QWORD *)v4 + 1) = 0LL;
}
if ( !*a2 )
{
LABEL_13:
*(_QWORD *)(*((_QWORD *)v4 + 2) + 8LL * *(unsigned int *)v4) = 0LL;
*(_DWORD *)(*((_QWORD *)v4 + 3) + 4LL * *(unsigned int *)v4) = 0;
return v4;
}
v9 = 0LL;
while ( 1 )
{
v10 = strmake_root(a1, *(_QWORD *)(*((_QWORD *)a2 + 2) + 8 * v9), *(unsigned int *)(*((_QWORD *)a2 + 3) + 4 * v9));
*(_QWORD *)(*((_QWORD *)v4 + 2) + 8 * v9) = v10;
if ( !v10 )
return 0LL;
*(_DWORD *)(*((_QWORD *)v4 + 3) + 4 * v9) = *(_DWORD *)(*((_QWORD *)a2 + 3) + 4 * v9);
if ( ++v9 >= (unsigned long long)*a2 )
goto LABEL_13;
}
}
| copy_typelib:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
TEST RSI,RSI
JZ 0x001acb93
MOV R14,RSI
MOV R15,RDI
MOV ESI,0x20
CALL 0x001a1a8f
TEST RAX,RAX
JZ 0x001acb93
MOV RBX,RAX
MOV EAX,dword ptr [R14]
INC EAX
SHL RAX,0x2
LEA RSI,[RAX + RAX*0x2]
MOV RDI,R15
CALL 0x001a1a8f
MOV qword ptr [RBX + 0x10],RAX
TEST RAX,RAX
JZ 0x001acb93
MOV ECX,dword ptr [R14]
LEA RAX,[RAX + RCX*0x8]
ADD RAX,0x8
MOV qword ptr [RBX + 0x18],RAX
MOV EAX,dword ptr [R14]
MOV dword ptr [RBX],EAX
MOV RSI,qword ptr [R14 + 0x8]
TEST RSI,RSI
JZ 0x001acba1
MOV RDI,R15
CALL 0x001a1e2a
MOV qword ptr [RBX + 0x8],RAX
TEST RAX,RAX
JNZ 0x001acba9
LAB_001acb93:
XOR EBX,EBX
LAB_001acb95:
MOV RAX,RBX
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_001acba1:
MOV qword ptr [RBX + 0x8],0x0
LAB_001acba9:
CMP dword ptr [R14],0x0
JZ 0x001acbf2
XOR R12D,R12D
LAB_001acbb2:
MOV RAX,qword ptr [R14 + 0x10]
MOV RCX,qword ptr [R14 + 0x18]
MOV RSI,qword ptr [RAX + R12*0x8]
MOV EDX,dword ptr [RCX + R12*0x4]
MOV RDI,R15
CALL 0x001a1e51
MOV RCX,qword ptr [RBX + 0x10]
MOV qword ptr [RCX + R12*0x8],RAX
TEST RAX,RAX
JZ 0x001acb93
MOV RAX,qword ptr [R14 + 0x18]
MOV EAX,dword ptr [RAX + R12*0x4]
MOV RCX,qword ptr [RBX + 0x18]
MOV dword ptr [RCX + R12*0x4],EAX
INC R12
MOV EAX,dword ptr [R14]
CMP R12,RAX
JC 0x001acbb2
LAB_001acbf2:
MOV RAX,qword ptr [RBX + 0x10]
MOV ECX,dword ptr [RBX]
MOV qword ptr [RAX + RCX*0x8],0x0
MOV RAX,qword ptr [RBX + 0x18]
MOV ECX,dword ptr [RBX]
MOV dword ptr [RAX + RCX*0x4],0x0
JMP 0x001acb95
|
uint * copy_typelib(int8 param_1,uint *param_2)
{
uint *puVar1;
long lVar2;
ulong uVar3;
if ((param_2 != (uint *)0x0) && (puVar1 = (uint *)alloc_root(param_1,0x20), puVar1 != (uint *)0x0)
) {
lVar2 = alloc_root(param_1,(ulong)(*param_2 + 1) * 0xc);
*(long *)(puVar1 + 4) = lVar2;
if (lVar2 != 0) {
*(ulong *)(puVar1 + 6) = lVar2 + (ulong)*param_2 * 8 + 8;
*puVar1 = *param_2;
if (*(long *)(param_2 + 2) == 0) {
puVar1[2] = 0;
puVar1[3] = 0;
}
else {
lVar2 = strdup_root(param_1);
*(long *)(puVar1 + 2) = lVar2;
if (lVar2 == 0) {
return (uint *)0x0;
}
}
if (*param_2 != 0) {
uVar3 = 0;
do {
lVar2 = strmake_root(param_1,*(int8 *)(*(long *)(param_2 + 4) + uVar3 * 8),
*(int4 *)(*(long *)(param_2 + 6) + uVar3 * 4));
*(long *)(*(long *)(puVar1 + 4) + uVar3 * 8) = lVar2;
if (lVar2 == 0) {
return (uint *)0x0;
}
*(int4 *)(*(long *)(puVar1 + 6) + uVar3 * 4) =
*(int4 *)(*(long *)(param_2 + 6) + uVar3 * 4);
uVar3 = uVar3 + 1;
} while (uVar3 < *param_2);
}
*(int8 *)(*(long *)(puVar1 + 4) + (ulong)*puVar1 * 8) = 0;
*(int4 *)(*(long *)(puVar1 + 6) + (ulong)*puVar1 * 4) = 0;
return puVar1;
}
}
return (uint *)0x0;
}
| |
22,198 | my_caseup_str_mb | eloqsql/strings/ctype-mb.c | size_t my_caseup_str_mb(CHARSET_INFO * cs, char *str)
{
register uint32 l;
register const uchar *map= cs->to_upper;
char *str_orig= str;
while (*str)
{
/* Pointing after the '\0' is safe here. */
if ((l= my_ismbchar(cs, str, str + cs->mbmaxlen)))
str+= l;
else
{
*str= (char) map[(uchar)*str];
str++;
}
}
return (size_t) (str - str_orig);
} | O0 | c | my_caseup_str_mb:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq 0x50(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
cmpb $0x0, (%rax)
je 0x48e97
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x10(%rbp), %rdx
movq -0x8(%rbp), %rax
movl 0x9c(%rax), %eax
addq %rax, %rdx
callq 0x48eb0
movl %eax, -0x14(%rbp)
cmpl $0x0, %eax
je 0x48e75
movl -0x14(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
jmp 0x48e95
movq -0x20(%rbp), %rax
movq -0x10(%rbp), %rcx
movzbl (%rcx), %ecx
movb (%rax,%rcx), %cl
movq -0x10(%rbp), %rax
movb %cl, (%rax)
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x48e34
movq -0x10(%rbp), %rax
movq -0x28(%rbp), %rcx
subq %rcx, %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| my_caseup_str_mb:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_8]
mov rax, [rax+50h]
mov [rbp+var_20], rax
mov rax, [rbp+var_10]
mov [rbp+var_28], rax
loc_48E34:
mov rax, [rbp+var_10]
cmp byte ptr [rax], 0
jz short loc_48E97
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rdx, [rbp+var_10]
mov rax, [rbp+var_8]
mov eax, [rax+9Ch]
add rdx, rax
call my_ismbchar_0
mov [rbp+var_14], eax
cmp eax, 0
jz short loc_48E75
mov ecx, [rbp+var_14]
mov rax, [rbp+var_10]
mov ecx, ecx
add rax, rcx
mov [rbp+var_10], rax
jmp short loc_48E95
loc_48E75:
mov rax, [rbp+var_20]
mov rcx, [rbp+var_10]
movzx ecx, byte ptr [rcx]
mov cl, [rax+rcx]
mov rax, [rbp+var_10]
mov [rax], cl
mov rax, [rbp+var_10]
add rax, 1
mov [rbp+var_10], rax
loc_48E95:
jmp short loc_48E34
loc_48E97:
mov rax, [rbp+var_10]
mov rcx, [rbp+var_28]
sub rax, rcx
add rsp, 30h
pop rbp
retn
| _BYTE * my_caseup_str_mb(long long a1, _BYTE *a2)
{
long long v3; // [rsp+10h] [rbp-20h]
unsigned int v4; // [rsp+1Ch] [rbp-14h]
_BYTE *v5; // [rsp+20h] [rbp-10h]
v5 = a2;
v3 = *(_QWORD *)(a1 + 80);
while ( *v5 )
{
v4 = my_ismbchar_0(a1, v5, &v5[*(unsigned int *)(a1 + 156)]);
if ( v4 )
{
v5 += v4;
}
else
{
*v5 = *(_BYTE *)(v3 + (unsigned __int8)*v5);
++v5;
}
}
return (_BYTE *)(v5 - a2);
}
| my_caseup_str_mb:
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 + -0x8]
MOV RAX,qword ptr [RAX + 0x50]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x28],RAX
LAB_00148e34:
MOV RAX,qword ptr [RBP + -0x10]
CMP byte ptr [RAX],0x0
JZ 0x00148e97
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x9c]
ADD RDX,RAX
CALL 0x00148eb0
MOV dword ptr [RBP + -0x14],EAX
CMP EAX,0x0
JZ 0x00148e75
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x10],RAX
JMP 0x00148e95
LAB_00148e75:
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x10]
MOVZX ECX,byte ptr [RCX]
MOV CL,byte ptr [RAX + RCX*0x1]
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x10]
ADD RAX,0x1
MOV qword ptr [RBP + -0x10],RAX
LAB_00148e95:
JMP 0x00148e34
LAB_00148e97:
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RBP + -0x28]
SUB RAX,RCX
ADD RSP,0x30
POP RBP
RET
|
long my_caseup_str_mb(long param_1,byte *param_2)
{
long lVar1;
uint uVar2;
byte *local_18;
lVar1 = *(long *)(param_1 + 0x50);
local_18 = param_2;
while (*local_18 != 0) {
uVar2 = my_ismbchar(param_1,local_18,local_18 + *(uint *)(param_1 + 0x9c));
if (uVar2 == 0) {
*local_18 = *(byte *)(lVar1 + (ulong)*local_18);
local_18 = local_18 + 1;
}
else {
local_18 = local_18 + uVar2;
}
}
return (long)local_18 - (long)param_2;
}
| |
22,199 | minja::split(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&) | llama.cpp/common/minja/minja.hpp | static std::vector<std::string> split(const std::string & s, const std::string & sep) {
std::vector<std::string> result;
size_t start = 0;
size_t end = s.find(sep);
while (end != std::string::npos) {
result.push_back(s.substr(start, end - start));
start = end + sep.length();
end = s.find(sep, start);
}
result.push_back(s.substr(start));
return result;
} | O3 | cpp | minja::split(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq (%rdx), %rsi
movq 0x8(%rdx), %rcx
xorl %ebp, %ebp
movq %r14, %rdi
xorl %edx, %edx
callq 0x21670
cmpq $-0x1, %rax
je 0xb2b30
movq %rax, %r12
xorl %ebp, %ebp
leaq 0x8(%rsp), %r13
movq %r12, %rcx
subq %rbp, %rcx
movq %r13, %rdi
movq %r14, %rsi
movq %rbp, %rdx
callq 0x22300
movq %rbx, %rdi
movq %r13, %rsi
callq 0x76334
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0xb2b0f
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x211a0
movq (%r15), %rsi
movq 0x8(%r15), %rcx
movq %r12, %rbp
addq %rcx, %rbp
movq %r14, %rdi
movq %rbp, %rdx
callq 0x21670
movq %rax, %r12
cmpq $-0x1, %rax
jne 0xb2ad4
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
movq %rbp, %rdx
movq $-0x1, %rcx
callq 0x22300
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x76334
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xb2b6f
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x211a0
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
jmp 0xb2ba0
jmp 0xb2b8e
movq %rax, %r14
jmp 0xb2bb2
movq %rax, %r14
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0xb2bb2
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x211a0
movq %rbx, %rdi
callq 0x2a4f6
movq %r14, %rdi
callq 0x21c10
| _ZN5minjaL5splitERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 28h
mov r15, rdx
mov r14, rsi
mov rbx, rdi
xorps xmm0, xmm0
movups xmmword ptr [rdi], xmm0
mov qword ptr [rdi+10h], 0
mov rsi, [rdx]
mov rcx, [rdx+8]
xor ebp, ebp
mov rdi, r14
xor edx, edx
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEPKcmm; std::string::find(char const*,ulong,ulong)
cmp rax, 0FFFFFFFFFFFFFFFFh
jz short loc_B2B30
mov r12, rax
xor ebp, ebp
lea r13, [rsp+58h+var_50]
loc_B2AD4:
mov rcx, r12
sub rcx, rbp
mov rdi, r13
mov rsi, r14
mov rdx, rbp
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong)
mov rdi, rbx
mov rsi, r13
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&)
mov rdi, [rsp+58h+var_50]; void *
lea rax, [rsp+58h+var_40]
cmp rdi, rax
jz short loc_B2B0F
mov rsi, [rsp+58h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_B2B0F:
mov rsi, [r15]
mov rcx, [r15+8]
mov rbp, r12
add rbp, rcx
mov rdi, r14
mov rdx, rbp
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEPKcmm; std::string::find(char const*,ulong,ulong)
mov r12, rax
cmp rax, 0FFFFFFFFFFFFFFFFh
jnz short loc_B2AD4
loc_B2B30:
lea rdi, [rsp+58h+var_50]
mov rsi, r14
mov rdx, rbp
mov rcx, 0FFFFFFFFFFFFFFFFh
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong)
lea rsi, [rsp+58h+var_50]
mov rdi, rbx
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&)
lea rax, [rsp+58h+var_40]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_B2B6F
mov rsi, [rsp+58h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_B2B6F:
add rsp, 28h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r14, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]
jmp short loc_B2BA0
jmp short $+2
loc_B2B8E:
mov r14, rax
jmp short loc_B2BB2
mov r14, rax
mov rdi, [rsp+arg_0]; void *
lea rax, [rsp+arg_10]
loc_B2BA0:
cmp rdi, rax
jz short loc_B2BB2
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_B2BB2:
mov rdi, rbx
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector()
mov rdi, r14
call __Unwind_Resume
| void minja::split(long long a1, long long a2, _QWORD *a3)
{
long long v4; // rbp
long long v5; // rax
long long v6; // r12
long long v7; // rcx
void *v8[2]; // [rsp+8h] [rbp-50h] BYREF
_QWORD v9[8]; // [rsp+18h] [rbp-40h] BYREF
*(_OWORD *)a1 = 0LL;
*(_QWORD *)(a1 + 16) = 0LL;
v4 = 0LL;
v5 = std::string::find(a2, *a3, 0LL, a3[1]);
if ( v5 != -1 )
{
v6 = v5;
v4 = 0LL;
do
{
std::string::substr(v8, a2, v4, v6 - v4);
std::vector<std::string>::emplace_back<std::string>(a1, v8);
if ( v8[0] != v9 )
operator delete(v8[0], v9[0] + 1LL);
v7 = a3[1];
v4 = v7 + v6;
v6 = std::string::find(a2, *a3, v7 + v6, v7);
}
while ( v6 != -1 );
}
std::string::substr(v8, a2, v4, -1LL);
std::vector<std::string>::emplace_back<std::string>(a1, v8);
if ( v8[0] != v9 )
operator delete(v8[0], v9[0] + 1LL);
}
| split:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV R15,RDX
MOV R14,RSI
MOV RBX,RDI
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI],XMM0
MOV qword ptr [RDI + 0x10],0x0
MOV RSI,qword ptr [RDX]
MOV RCX,qword ptr [RDX + 0x8]
XOR EBP,EBP
MOV RDI,R14
XOR EDX,EDX
CALL 0x00121670
CMP RAX,-0x1
JZ 0x001b2b30
MOV R12,RAX
XOR EBP,EBP
LEA R13,[RSP + 0x8]
LAB_001b2ad4:
MOV RCX,R12
SUB RCX,RBP
LAB_001b2ada:
MOV RDI,R13
MOV RSI,R14
MOV RDX,RBP
CALL 0x00122300
LAB_001b2ae8:
MOV RDI,RBX
MOV RSI,R13
CALL 0x00176334
MOV RDI,qword ptr [RSP + 0x8]
LEA RAX,[RSP + 0x18]
CMP RDI,RAX
JZ 0x001b2b0f
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001211a0
LAB_001b2b0f:
MOV RSI,qword ptr [R15]
MOV RCX,qword ptr [R15 + 0x8]
MOV RBP,R12
ADD RBP,RCX
MOV RDI,R14
MOV RDX,RBP
CALL 0x00121670
MOV R12,RAX
CMP RAX,-0x1
JNZ 0x001b2ad4
LAB_001b2b30:
LEA RDI,[RSP + 0x8]
MOV RSI,R14
MOV RDX,RBP
MOV RCX,-0x1
CALL 0x00122300
LAB_001b2b47:
LEA RSI,[RSP + 0x8]
MOV RDI,RBX
CALL 0x00176334
LAB_001b2b54:
LEA RAX,[RSP + 0x18]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x001b2b6f
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001211a0
LAB_001b2b6f:
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* minja::split(std::__cxx11::string const&, std::__cxx11::string const&) */
void __thiscall minja::split(minja *this,string *param_1,string *param_2)
{
long lVar1;
long *local_50 [2];
long local_40 [2];
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
*(int8 *)(this + 0x10) = 0;
lVar1 = std::__cxx11::string::find((char *)param_1,*(ulong *)param_2,0);
if (lVar1 != -1) {
do {
/* try { // try from 001b2ada to 001b2ae7 has its CatchHandler @ 001b2b8e */
std::__cxx11::string::substr((ulong)local_50,(ulong)param_1);
/* try { // try from 001b2ae8 to 001b2af2 has its CatchHandler @ 001b2b93 */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<std::__cxx11::string>
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)this,
(string *)local_50);
if (local_50[0] != local_40) {
operator_delete(local_50[0],local_40[0] + 1);
}
lVar1 = std::__cxx11::string::find
((char *)param_1,*(ulong *)param_2,lVar1 + *(long *)(param_2 + 8));
} while (lVar1 != -1);
}
/* try { // try from 001b2b30 to 001b2b46 has its CatchHandler @ 001b2b8c */
std::__cxx11::string::substr((ulong)local_50,(ulong)param_1);
/* try { // try from 001b2b47 to 001b2b53 has its CatchHandler @ 001b2b7e */
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::
emplace_back<std::__cxx11::string>
((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)this,
(string *)local_50);
if (local_50[0] != local_40) {
operator_delete(local_50[0],local_40[0] + 1);
}
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.